/*
Theme Name: Schmidinger
Description: Neues Design für Elektro Schmidinger – Onepager mit Öffnungszeiten und Flugblatt aus dem Plugin „Wartung Schmidinger“.
Version: 1.1.2
Requires at least: 6.0
Requires PHP: 7.4
Author: Elektro Schmidinger
Text Domain: schmidinger
*/

@font-face { font-family: 'Plus Jakarta Sans'; font-style: normal; font-weight: 200 800; font-display: swap; src: url('assets/fonts/plus-jakarta-sans.woff2') format('woff2'); }
@font-face { font-family: 'DM Sans'; font-style: normal; font-weight: 100 1000; font-display: swap; src: url('assets/fonts/dm-sans.woff2') format('woff2'); }

:root {
  --accent: #1F5FBF;
  --accent-dark: #164A96;
  --ink: #12213A;
  --text: #3D4A5C;
  --muted: #556274;
  --line: #E3E8EF;
  --border: #C9D3DF;
  --surface: #F3F6FA;
  --placeholder: #DCE3EC;
  --dot: #A7AFBA;
  --display: 'Plus Jakarta Sans', system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; background: #FFFFFF; color: var(--ink); font-family: 'DM Sans', system-ui, sans-serif; font-size: 17px; line-height: 1.6; }
a { color: var(--accent); }
a:hover { color: var(--accent-dark); }
input, textarea, button { font: inherit; }
img { max-width: 100%; }

.wrap { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.bg-surface { background: var(--surface); }
.eyebrow { font-size: 14px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
h1, h2 { margin: 0; font-family: var(--display); font-weight: 800; letter-spacing: -0.025em; line-height: 1.1; }
h2 { font-size: clamp(2rem, 3.6vw, 2.8rem); }
p { margin: 0; color: var(--text); }
.stack { display: flex; flex-direction: column; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; font-weight: 600; font-size: 17px; padding: 15px 24px; border-radius: 12px; text-decoration: none; border: 0; }
.btn-primary { background: var(--accent); color: #FFFFFF; }
.btn-primary:hover { background: var(--accent-dark); color: #FFFFFF; }
.btn-ghost { background: #FFFFFF; color: var(--ink); border: 1px solid var(--border); padding: 14px 24px; }
.btn-ghost:hover { color: var(--ink); border-color: var(--ink); }
.btn-dark { background: var(--ink); color: #FFFFFF; }
.btn-sm { font-size: 15px; padding: 12px 16px; border-radius: 10px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 10; background: rgba(255,255,255,0.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.site-header .wrap { padding-top: 14px; padding-bottom: 14px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.logo:hover { color: var(--ink); }
.logo-text { display: flex; flex-direction: column; line-height: 1.05; }
.logo-small { font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.logo-big { font-family: var(--display); font-weight: 800; font-size: 24px; letter-spacing: -0.02em; }
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 24px; font-weight: 500; font-size: 16px; }
.nav a { color: var(--ink); text-decoration: none; padding: 10px 0; }
.nav a:hover { color: var(--accent); }
.nav .nav-phone { display: inline-flex; align-items: center; gap: 8px; background: var(--accent); color: #FFFFFF; padding: 11px 18px; border-radius: 999px; font-weight: 600; }
.nav .nav-phone:hover { background: var(--accent-dark); color: #FFFFFF; }
.menu-toggle { display: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--border); background: #FFFFFF; color: var(--ink); align-items: center; justify-content: center; cursor: pointer; padding: 0; }
.menu-toggle .icon-close { display: none; }
.menu-toggle[aria-expanded="true"] .icon-open { display: none; }
.menu-toggle[aria-expanded="true"] .icon-close { display: block; }
.header-call { display: none; width: 44px; height: 44px; border-radius: 50%; background: var(--accent); color: #FFFFFF; align-items: center; justify-content: center; }
.header-call:hover { color: #FFFFFF; background: var(--accent-dark); }

/* Hero */
.hero { padding-top: 72px; padding-bottom: 80px; display: flex; flex-wrap: wrap; align-items: center; gap: 56px; }
.hero-copy { flex: 1 1 460px; min-width: 0; gap: 24px; }
.hero h1 { font-size: clamp(2.4rem, 5vw, 3.9rem); line-height: 1.05; letter-spacing: -0.03em; }
.hero-lead { font-size: 20px; max-width: 34rem; }
.status { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; background: #FFFFFF; border: 1px solid #DCE3EC; padding: 6px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--muted); }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.status.is-open { color: #15803D; }
.status.is-closed { color: #B45309; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.checks { display: flex; flex-wrap: wrap; gap: 10px 28px; padding-top: 8px; font-size: 15px; color: var(--text); }
.checks span { display: inline-flex; align-items: center; gap: 8px; }

.prospekt-col { flex: 1 1 380px; min-width: 0; display: flex; justify-content: center; }
.prospekt-card { width: 100%; max-width: 340px; background: #FFFFFF; border-radius: 20px; padding: 18px; box-shadow: 0 1px 2px rgba(18,33,58,0.06), 0 24px 48px -16px rgba(18,33,58,0.22); }
.prospekt-head { display: flex; justify-content: space-between; align-items: center; padding: 4px 4px 14px; }
.prospekt-head strong { font-family: var(--display); font-size: 18px; }
.badge { font-size: 13px; font-weight: 600; color: #FFFFFF; background: #C2410C; padding: 4px 10px; border-radius: 999px; }
.prospekt-cover { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.prospekt-cover img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; object-position: top; border-radius: 10px; border: 1px solid var(--line); }
.prospekt-actions { display: flex; gap: 10px; padding-top: 14px; }
.prospekt-actions > * { flex: 1; }

.kicker { align-self: flex-start; font-size: 15px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); padding-bottom: 10px; border-bottom: 2px solid var(--accent); }

/* Tradition */
.tradition { background: var(--ink); color: #FFFFFF; }
.tradition p { color: #C8D2E0; }
.tradition h2 { font-size: clamp(2.2rem, 4.2vw, 3.3rem); }
.eyebrow-light { color: #9DBCF0; }
.placeholder.placeholder-dark { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.28); color: #C8D2E0; }

/* Sortiment */
.section { padding-top: 96px; padding-bottom: 96px; }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 40px; }
.section-head .stack { gap: 10px; max-width: 40rem; }
.section-head p { max-width: 28rem; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.tile { display: flex; flex-direction: column; gap: 14px; padding: 24px; border: 1px solid var(--line); border-radius: 16px; transition: border-color .15s, transform .15s; }
.tile:hover { border-color: var(--accent); transform: translateY(-2px); }
.tile span { font-family: var(--display); font-weight: 700; font-size: 19px; }
.tile svg { stroke: var(--accent); }

/* Service-Band */
.service-head { display: flex; flex-direction: column; gap: 10px; margin-top: 96px; margin-bottom: 32px; }
.service { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); background: var(--surface); border-radius: 20px; overflow: hidden; }
.service > div { display: flex; flex-direction: column; gap: 8px; padding: 36px 32px; border-right: 1px solid var(--line); }
.service > div:last-child { border-right: 0; }
.service .num { font-family: var(--display); font-size: 15px; font-weight: 700; color: var(--accent); }
.service .title { font-family: var(--display); font-weight: 700; font-size: 22px; }
.service .desc { color: var(--text); font-size: 16px; }

/* Über uns */
.split { display: flex; flex-wrap: wrap; align-items: center; gap: 56px; }
.split > * { flex: 1 1 420px; min-width: 0; }
.placeholder { border-radius: 20px; background: var(--placeholder); border: 2px dashed var(--dot); display: flex; align-items: center; justify-content: center; text-align: center; color: var(--muted); font-weight: 600; padding: 24px; }
.photo { aspect-ratio: 4 / 3; }
.about { gap: 20px; }
.signature { font-family: var(--display); font-weight: 700; }

/* Marken */
.brands { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.brands li { display: flex; align-items: center; justify-content: center; text-align: center; height: 88px; padding: 0 22px; border: 1px solid var(--line); border-radius: 14px; background: #FFFFFF; transition: border-color .15s; }
.brands li:hover { border-color: var(--border); }
.brands img { display: block; max-width: 100%; max-height: 34px; width: auto; height: auto; filter: grayscale(1); opacity: .75; transition: filter .2s, opacity .2s; }
.brands li:hover img { filter: none; opacity: 1; }
.brands .wordmark { font-family: var(--display); font-weight: 800; font-size: 24px; letter-spacing: -0.02em; color: var(--text); opacity: .85; }

/* Besuch */
.visit { display: flex; flex-wrap: wrap; gap: 32px; }
.hours-card { flex: 1 1 400px; min-width: 0; background: #FFFFFF; border-radius: 20px; padding: 36px; gap: 22px; }
.hours-card h2 { font-size: 32px; }
.hours { width: 100%; border-collapse: collapse; font-size: 17px; }
.hours th, .hours td { padding: 11px 12px; border-bottom: 1px solid var(--line); }
.hours th { text-align: left; font-weight: 600; }
.hours td { text-align: right; font-variant-numeric: tabular-nums; }
.hours tr.closed { color: var(--muted); }
.hours tr.today { background: #EAF1FC; color: var(--accent); font-weight: 600; }
.map-col { flex: 1 1 480px; min-width: 0; gap: 16px; }
.map { flex: 1; min-height: 320px; flex-direction: column; gap: 14px; }
.address-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; background: #FFFFFF; border-radius: 16px; padding: 22px 26px; }
.address-bar address { font-style: normal; display: flex; flex-direction: column; }

/* Kontakt */
.contact { display: flex; flex-wrap: wrap; gap: 56px; }
.contact-info { flex: 1 1 340px; min-width: 0; gap: 24px; }
.contact-info .stack { gap: 10px; }
.contact-link { display: flex; align-items: center; gap: 14px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); }
.contact-link:hover { border-color: var(--accent); color: var(--ink); }
.contact-link small { display: block; font-size: 14px; color: var(--muted); }
.contact-link strong { font-weight: 600; }
.form-card { flex: 1 1 520px; min-width: 0; background: var(--surface); border-radius: 20px; padding: 36px; }
.form { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; }
.form label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 15px; }
.form .full { grid-column: 1 / -1; }
.form input[type=text], .form input[type=tel], .form input[type=email], .form textarea { padding: 13px 14px; border: 1px solid var(--border); border-radius: 10px; background: #FFFFFF; font-size: 16px; font-weight: 400; color: var(--ink); }
.form input:focus, .form textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.form textarea { resize: vertical; }
.form .consent { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 400; color: var(--text); }
.form .consent input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }
.form-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; }
.form-foot small { font-size: 13px; color: var(--muted); }
.success { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; padding: 24px 0; }
.success strong { font-family: var(--display); font-weight: 800; font-size: 26px; }
[hidden] { display: none !important; }

/* Footer */
.site-footer { background: var(--ink); color: #C8D2E0; }
.site-footer a { color: #C8D2E0; }
.site-footer a:hover { color: #FFFFFF; }
.footer-grid { padding-top: 56px; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; }
.footer-grid .stack { gap: 6px; }
.footer-grid .head { font-weight: 600; color: #FFFFFF; }
.footer-brand { font-family: var(--display); font-weight: 800; font-size: 22px; color: #FFFFFF; }
.footer-bottom { margin-top: 32px; padding: 24px 0 32px; border-top: 1px solid rgba(255,255,255,0.14); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 15px; }
.footer-bottom nav { display: flex; gap: 24px; }

/* Prospekt-Dialog */
.viewer { position: fixed; inset: 0; z-index: 50; background: rgba(10,18,32,0.86); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 24px; }
.viewer-top { display: flex; align-items: center; justify-content: space-between; width: 100%; max-width: 640px; color: #FFFFFF; font-family: var(--display); font-weight: 700; font-size: 18px; }
.viewer-body { display: flex; align-items: center; justify-content: center; gap: 16px; width: 100%; max-width: 760px; }
.viewer-body img { display: block; max-height: calc(100vh - 160px); max-width: 100%; min-width: 0; aspect-ratio: 724 / 1024; object-fit: contain; border-radius: 8px; background: #FFFFFF; }
.round { cursor: pointer; flex: none; width: 48px; height: 48px; border-radius: 50%; border: 0; display: flex; align-items: center; justify-content: center; background: #FFFFFF; color: var(--ink); }
.round.light { width: 44px; height: 44px; background: rgba(255,255,255,0.14); color: #FFFFFF; }
.round:disabled { opacity: .35; cursor: default; }

/* Rechtliches */
.legal { max-width: 820px; margin: 0 auto; padding: 72px 24px 96px; display: flex; flex-direction: column; gap: 72px; }
.legal h1 { font-size: clamp(2.2rem, 4vw, 3rem); }
.facts { margin: 28px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); border-top: 1px solid var(--line); }
.facts div { padding: 18px 0; border-bottom: 1px solid var(--line); }
.facts dt { font-size: 14px; color: var(--muted); }
.facts dd { margin: 0; font-weight: 600; }

@media (max-width: 640px) {
  html { scroll-padding-top: 80px; }
  .site-header .wrap { padding-top: 10px; padding-bottom: 10px; gap: 8px; }
  .logo { order: 1; margin-right: auto; }
  .header-call { order: 2; display: inline-flex !important; }
  .menu-toggle { order: 3; display: inline-flex; }
  .nav { order: 4; display: none; width: 100%; flex-direction: column; align-items: stretch; gap: 0; font-size: 18px; padding: 4px 0 6px; }
  .nav.is-open { display: flex; }
  .nav a { padding: 13px 4px; border-top: 1px solid var(--line); }
  .nav .nav-phone { display: none; }
  .hero { padding-top: 48px; }
  .section { padding-top: 64px; padding-bottom: 64px; }
  .hours-card, .form-card { padding: 24px; }
  .service > div { border-right: 0; border-bottom: 1px solid var(--line); }
  .viewer-body .round { position: absolute; bottom: 24px; }
  .viewer-body .round.prev { left: 24px; }
  .viewer-body .round.next { right: 24px; }
}

/* ---------- Ergänzungen für WordPress ---------- */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 100; width: auto; height: auto; clip: auto; background: #FFFFFF; padding: 10px 14px; border-radius: 8px; }
body.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { body.admin-bar .site-header { top: 46px; } }

/* Hinweise aus der Wartung (Urlaub, Sonderöffnung) */
.notice-list { display: flex; flex-direction: column; gap: 8px; }
.ws-notice { margin: 0; background: #FEF3C7; color: #78350F; padding: 10px 14px; border-radius: 10px; font-weight: 600; font-size: 15px; }

/* Karte: erst nach Klick laden (Datenschutz) */
.map-load { flex-direction: column; gap: 14px; cursor: pointer; border: 2px dashed var(--dot); font: inherit; width: 100%; }
.map-load:hover { border-color: var(--accent); color: var(--accent); }
.map-frame { flex: 1; min-height: 320px; border: 0; border-radius: 20px; width: 100%; }

/* Contact Form 7 im Stil der Seite */
.form-card .wpcf7-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; }
.form-card .wpcf7-form > p, .form-card .wpcf7-form > div:not(.wpcf7-response-output) { margin: 0; grid-column: 1 / -1; }
.form-card .wpcf7-form label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 15px; }
.form-card .wpcf7-form-control-wrap { display: block; }
.form-card .wpcf7-form input[type=text], .form-card .wpcf7-form input[type=tel], .form-card .wpcf7-form input[type=email], .form-card .wpcf7-form textarea { width: 100%; padding: 13px 14px; border: 1px solid var(--border); border-radius: 10px; background: #FFFFFF; font-size: 16px; font-weight: 400; color: var(--ink); }
.form-card .wpcf7-form textarea { min-height: 140px; resize: vertical; }
.form-card .wpcf7-form input:focus, .form-card .wpcf7-form textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.form-card .wpcf7-submit { cursor: pointer; border: 0; background: var(--accent); color: #FFFFFF; font-weight: 600; font-size: 17px; padding: 15px 28px; border-radius: 12px; }
.form-card .wpcf7-submit:hover { background: var(--accent-dark); }
.form-card .wpcf7-not-valid-tip { font-size: 14px; color: #B42318; font-weight: 600; margin-top: 4px; }
.form-card .wpcf7-response-output { grid-column: 1 / -1; margin: 0 !important; border-radius: 10px; padding: 12px 14px !important; }
.form-card .wpcf7-spinner { vertical-align: middle; }

/* Normale Seiten (Impressum, Datenschutz, Prospekt …) */
.page-hero { background: var(--surface); }
.page-hero .wrap { padding-top: 64px; padding-bottom: 48px; }
.page-hero h1 { font-size: clamp(2.2rem, 4vw, 3rem); }
.entry { max-width: 820px; margin: 0 auto; padding: 56px 24px 96px; }
.entry > * + * { margin-top: 1.1em; }
.entry h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); margin-top: 1.8em; }
.entry h3 { font-family: var(--display); font-size: 1.25rem; margin: 1.6em 0 0; }
.entry p, .entry li { color: var(--text); }
.entry img { height: auto; border-radius: 10px; }
.entry .wp-block-table table, .entry table { width: 100%; border-collapse: collapse; }
.entry td, .entry th { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.entry-wide { max-width: 1200px; }

/* Drei Generationen */
.generations { list-style: none; margin: 64px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 32px; border-top: 1px solid rgba(255,255,255,0.18); }
.generations li { position: relative; display: flex; flex-direction: column; gap: 6px; padding-top: 28px; }
.generations li::before { content: ""; position: absolute; top: -7px; left: 0; width: 12px; height: 12px; border-radius: 50%; background: #9DBCF0; box-shadow: 0 0 0 4px var(--ink); }
.generations li:last-child::before { background: #FFFFFF; }
.gen-year { font-family: var(--display); font-weight: 800; font-size: 30px; letter-spacing: -0.02em; color: #FFFFFF; }
.gen-title { font-weight: 600; color: #FFFFFF; }
.gen-desc { color: #C8D2E0; font-size: 16px; }
@media (max-width: 640px) { .generations { margin-top: 48px; } }

/* Historisches Flugblatt */
.history-photo { margin: 0; display: flex; flex-direction: column; gap: 12px; }
.history-photo img { display: block; width: 100%; max-width: 480px; height: auto; margin: 0 auto; border-radius: 6px; box-shadow: 0 24px 48px -16px rgba(0,0,0,0.55); transform: rotate(-1.5deg); }
.history-photo figcaption { text-align: center; font-size: 14px; color: #C8D2E0; }

/* Platzhalter, solange kein gültiges Prospekt da ist (Titelseite kommt aus dem Plugin) */
.prospekt-empty .ws-cover { font-size: 17px; font-family: var(--display); }
.prospekt-empty .ws-cover-foot { font-family: 'DM Sans', system-ui, sans-serif; }
.prospekt-empty-note { margin: 0; padding: 14px 4px 0; font-size: 15px; color: var(--text); }
.badge-soon { background: var(--accent); }
.entry .ws-cover { font-family: var(--display); }
.entry .ws-prospekt-empty-text strong { font-family: var(--display); }

/* Häufige Fragen */
.faq-section { padding-top: 0; }
.faq { display: flex; flex-direction: column; gap: 10px; max-width: 860px; }
.faq-item { border: 1px solid var(--line); border-radius: 14px; background: #FFFFFF; }
.faq-item[open] { border-color: var(--border); }
.faq-item summary { cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 20px; font-family: var(--display); font-weight: 700; font-size: 18px; min-height: 44px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: ""; flex: none; width: 10px; height: 10px; border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(45deg); transition: transform .15s; margin-top: -4px; }
.faq-item[open] summary::after { transform: rotate(-135deg); margin-top: 4px; }
.faq-item summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 14px; }
.faq-item p { margin: 0; padding: 0 20px 20px; color: var(--text); }
