/* =====================================================================
   MPZ Pirna – Einheitliches Design für Buttons und klickbare Kacheln (V07_61)
   Wird auf ALLEN Seiten (inkl. Admin) NACH styles.css geladen und vereinheitlicht
   bewusst nur Buttons, Kacheln und Schwebe-Buttons. Gilt auch für Inhalte, die
   Mitarbeitende früher im Editor gespeichert haben (z. B. alte grüne Buttons).
   ===================================================================== */
:root{
  --mpz-btn:#173f73;          /* MPZ-Blau = einheitliche Button-Farbe */
  --mpz-btn-hover:#0f2d55;
  --mpz-btn-text:#fff;
  --mpz-tile-bg:#eef7fd;
  --mpz-tile-border:#d8e2ea;
  --mpz-tile-border-hover:#d8e2ea;
  --mpz-tile-shadow:none;
  --mpz-tile-shadow-hover:0 10px 24px rgba(23,63,115,.08);
  --mpz-focus:0 0 0 3px #fff,0 0 0 6px #173f73;
}

/* ---------- 1. Buttons: ein Schema für alle ---------- */
.btn,
.btn-primary,.btn-green,a.btn-green,button.btn-green,
.btn-blue,
.contact-form button[type="submit"],
.mpz-fb-send,
.assistant-search-row button,
.v35-kpi i{
  display:inline-flex;align-items:center;justify-content:center;gap:.45em;
  min-height:48px;padding:0 22px;border-radius:10px;
  font-weight:700;font-size:15px;line-height:1.2;letter-spacing:0;text-transform:none;
  text-decoration:none!important;cursor:pointer;
  border:2px solid var(--mpz-btn);
  background:var(--mpz-btn)!important;color:var(--mpz-btn-text)!important;
  transition:background-color .15s ease,border-color .15s ease,transform .15s ease,box-shadow .15s ease;
}
.btn:hover,.btn-primary:hover,.btn-green:hover,.btn-blue:hover,
.contact-form button[type="submit"]:hover,.mpz-fb-send:hover,.assistant-search-row button:hover{
  background:var(--mpz-btn-hover)!important;border-color:var(--mpz-btn-hover);color:#fff!important;transform:translateY(-1px);
  box-shadow:0 6px 16px rgba(23,63,115,.22);
}
.btn:focus-visible,.btn-blue:focus-visible,.contact-form button[type="submit"]:focus-visible{outline:none;box-shadow:var(--mpz-focus)}
.btn:disabled,.btn[aria-disabled="true"]{opacity:.55;cursor:not-allowed;transform:none;box-shadow:none}

/* Zweit-Buttons (z. B. „Abbrechen“): gleiches Blau, nur als Umriss */
.btn.btn-outline,.btn-outline{
  background:#fff!important;color:var(--mpz-btn)!important;border:2px solid var(--mpz-btn)!important;
}
.btn.btn-outline:hover,.btn-outline:hover{background:#eef4fb!important;color:var(--mpz-btn-hover)!important;border-color:var(--mpz-btn-hover)!important}

/* Auf dunkelblauem Hintergrund: umgekehrt (weiß mit blauer Schrift), damit der Button sichtbar bleibt */
.booking-box .btn,.booking-box a.btn,
.service-experience-stage .btn,.site-footer .btn,.mpz-on-dark .btn{
  background:#fff!important;color:var(--mpz-btn)!important;border-color:#fff!important;
}
.booking-box .btn:hover,.service-experience-stage .btn:hover,.mpz-on-dark .btn:hover{background:#e8f0f9!important;color:var(--mpz-btn-hover)!important}

/* Ehemalige Textlinks in Kacheln/Boxen werden zu (kleineren) blauen Buttons */
.showroom-photo-card-body > span:last-child,
.showroom-grid > article > a,
.offer-grid > article > a,
.quick-start-card em,
.topic-arrow,
.contact-service-v22 > a,
.advice-card > a,
.mpz-tile-cta{
  display:inline-flex!important;align-items:center;gap:.4em;align-self:flex-start;
  min-height:40px;padding:0 16px;margin-top:auto;border-radius:10px;
  background:var(--mpz-btn)!important;color:#fff!important;border:2px solid var(--mpz-btn);
  font-style:normal;font-weight:700;font-size:14px;line-height:1.2;text-decoration:none!important;
  transition:background-color .15s ease;
}
.showroom-grid > article > a:hover,.offer-grid > article > a:hover,.contact-service-v22 > a:hover,.advice-card > a:hover{background:var(--mpz-btn-hover)!important}

/* Schwebe-Buttons unten (Chat-Assistent + Feedback) */
.mpz-assistant-launch-v41,.mpz-feedback-btn{
  background:var(--mpz-btn)!important;color:#fff!important;border:2px solid #fff!important;
  box-shadow:0 8px 24px rgba(23,63,115,.28)!important;
}
.mpz-assistant-launch-v41:hover,.mpz-feedback-btn:hover{background:var(--mpz-btn-hover)!important}
.mpz-assistant-launch-v41:focus-visible,.mpz-feedback-btn:focus-visible{outline:none;box-shadow:var(--mpz-focus)!important}

/* ---------- 2. Klickbare Kacheln: ein Muster für alle ----------
   Vorlage (Vorgabe MPZ): Team-Kachel auf der Kontaktseite – hellblauer Grund, feine Linie, 14px Rundung;
   Symbol/Bild, Titel, kurzer Text, unten blauer Button.
   Reine Info-Kacheln (nicht klickbar) bekommen KEINEN Hover-Effekt und keinen Button. */
.mpz-tile,
.quick-start-card,
.showroom-grid > article,
.showroom-photo-card,
.offer-grid > article,
.tech-category.is-clickable,
.lernsax-workshop-card,
.feature-card,
.lernsax-highlight,
.news-card,
.contact-quick-v22{
  position:relative;display:flex;flex-direction:column;gap:10px;
  background:var(--mpz-tile-bg)!important;border:1px solid var(--mpz-tile-border)!important;border-radius:14px!important;
  box-shadow:var(--mpz-tile-shadow);color:inherit;text-align:left;
  transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease;
}
.mpz-tile,.quick-start-card,.showroom-grid > article,.offer-grid > article,.tech-category.is-clickable,.feature-card,.lernsax-highlight,.contact-quick-v22{padding:20px!important}
.mpz-tile:hover,.quick-start-card:hover,.showroom-grid > article:hover,.showroom-photo-card:hover,.offer-grid > article:hover,
.tech-category.is-clickable:hover,.lernsax-workshop-card:hover,.feature-card:hover,.lernsax-highlight:hover,.news-card:hover,.contact-quick-v22:hover{
  transform:translateY(-2px)!important;border-color:var(--mpz-tile-border-hover)!important;box-shadow:var(--mpz-tile-shadow-hover)!important;
}
.mpz-tile:focus-visible,.quick-start-card:focus-visible,.showroom-photo-card:focus-visible,.tech-category.is-clickable:focus-visible,
.lernsax-workshop-card:focus-visible,.feature-card:focus-visible,.news-card:focus-visible,.contact-quick-v22:focus-visible{outline:none;box-shadow:var(--mpz-focus)!important}
.mpz-tile h3,.quick-start-card b,.showroom-grid > article h3,.showroom-photo-card h3,.offer-grid > article b,
.tech-category.is-clickable h3,.lernsax-workshop-card h3,.feature-card h3,.news-card h3{color:#173f73;font-size:20px;line-height:1.3;margin:0}
.mpz-tile p,.quick-start-card small,.showroom-grid > article p,.showroom-photo-card p,.offer-grid > article p,.tech-category.is-clickable p{color:#526779;font-size:15px;line-height:1.5;margin:0}
.showroom-photo-card{overflow:hidden;padding:0!important}
.showroom-photo-card img{border-radius:0}
.showroom-photo-card-body{display:flex;flex-direction:column;gap:8px;padding:18px 20px 20px!important;flex:1}
.quick-start-card > span:last-child{display:flex;flex-direction:column;gap:8px;flex:1}
.offer-grid > article,.showroom-grid > article{height:100%}
/* Symbol oben links (wie Showroom-Kachel) */
.mpz-tile-icon,.showroom-icon,.quick-start-icon{
  display:inline-grid;place-items:center;width:44px;height:44px;border-radius:12px;
  background:#fff;border:1px solid var(--mpz-tile-border);color:#3a6e1e;font-weight:800;font-size:16px;flex:none;
}

/* Reine Info-Kacheln: einheitlich ruhig, ohne Klick-Anmutung */
.lernsax-card,.advice-card,.info-card,.team-card{
  background:var(--mpz-tile-bg)!important;border:1px solid var(--mpz-tile-border)!important;border-radius:14px!important;
}
.lernsax-card{box-shadow:none!important;transform:none!important;cursor:default}
.lernsax-card:hover{transform:none!important;box-shadow:none!important;border-color:var(--mpz-tile-border)!important}
.lernsax-card > span:first-child{background:#fff!important;color:#3a6e1e!important;border:1px solid var(--mpz-tile-border)}

/* Grüne Akzentleisten an klickbaren Kacheln entfernen (Muster ist jetzt einheitlich) */
.tech-category.is-clickable::before,.tech-category.is-clickable::after{display:none!important}

@media (prefers-reduced-motion:reduce){
  .btn,.mpz-tile,.quick-start-card,.showroom-photo-card,.tech-category.is-clickable,.feature-card,.news-card{transition:none!important}
  .btn:hover,.mpz-tile:hover,.quick-start-card:hover,.showroom-photo-card:hover,.tech-category.is-clickable:hover,.feature-card:hover,.news-card:hover{transform:none!important}
}

/* ---------- 3. Pop-up (Technikverleih + Fortbildungen) ---------- */
.mpz-modal{position:fixed;inset:0;z-index:200;display:flex;align-items:center;justify-content:center;padding:16px}
.mpz-modal[hidden]{display:none!important}
.mpz-modal-backdrop{position:absolute;inset:0;background:rgba(15,37,66,.55);backdrop-filter:blur(2px)}
.mpz-modal-dialog{position:relative;width:min(760px,100%);max-height:calc(100dvh - 32px);overflow:auto;-webkit-overflow-scrolling:touch;
  background:#fff;border-radius:20px;box-shadow:0 30px 80px rgba(10,30,60,.35);padding:28px 28px 24px}
.mpz-modal-close{position:sticky;top:0;float:right;margin:-8px -8px 0 12px;width:44px;height:44px;border-radius:50%;border:0;
  background:#eef4fb;color:#173f73;font-size:24px;line-height:1;cursor:pointer;z-index:2}
.mpz-modal-close:hover{background:#dce8f5}
.mpz-modal-close:focus-visible{outline:none;box-shadow:var(--mpz-focus)}
.mpz-modal-kicker{display:block;color:#3a6e1e;font-weight:800;font-size:13px;letter-spacing:.04em;text-transform:uppercase;margin-bottom:6px}
.mpz-modal h2{margin:0 0 12px;color:#173f73;font-size:28px;line-height:1.2}
.mpz-modal p,.mpz-modal li{color:#2f475c;font-size:16px;line-height:1.6}
.mpz-modal-gallery{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px;margin:16px 0}
.mpz-modal-gallery img{width:100%;height:150px;object-fit:contain;background:#f4f7fa;border-radius:12px;border:1px solid #e3eaf1}
.mpz-modal-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:20px}
body.mpz-modal-open{overflow:hidden}
@media (max-width:600px){
  .mpz-modal{padding:0;align-items:flex-end}
  .mpz-modal-dialog{border-radius:20px 20px 0 0;max-height:92dvh;padding:22px 18px calc(18px + env(safe-area-inset-bottom))}
  .mpz-modal h2{font-size:23px}
  .mpz-modal-actions .btn{width:100%}
}

/* ---------- 4. Technikverleih ---------- */
.loan-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:14px!important;margin-top:22px}
.loan-grid .tech-category{border-top:1px solid var(--mpz-tile-border)!important;cursor:pointer}
.loan-grid .tech-category h3{font-size:18px}
.loan-grid .mpz-tile-icon svg{width:24px;height:24px}
.tile-detail{display:none}
html.mpz-inline-editing .tile-detail{display:block;margin-top:10px;padding:12px;border:1px dashed #9fb6cc;border-radius:12px;background:#f7fafc}
html.mpz-inline-editing .loan-grid{align-items:start}
.loan-grid>*,.loan-grid .tile-detail{min-width:0}
html.mpz-inline-editing .tile-detail .mpz-modal-gallery{grid-template-columns:repeat(auto-fill,minmax(100px,1fr))}
html.mpz-inline-editing .loan-grid .mpz-tile-cta{margin-top:12px!important}
html.mpz-inline-editing .tile-detail::before{content:"Pop-up-Inhalt (nur im Bearbeitungsmodus sichtbar)";display:block;font-size:12px;font-weight:700;color:#5d7387;margin-bottom:6px}
html.mpz-inline-editing .tech-category.is-clickable{cursor:default}
.loan-detail ul,.loan-detail ol{padding-left:20px;margin:8px 0 12px}
.loan-detail li{margin:6px 0}
.mesax-box{margin-top:24px;padding:22px;border-radius:18px;background:#eef5fb;border:1px solid #d6e4f0;display:flex;flex-direction:column;gap:14px}
.mesax-box h3{margin:2px 0 6px;color:#173f73;font-size:20px}
.mesax-box p{margin:0;color:#3e566b}
.mesax-box-actions{display:flex;flex-wrap:wrap;gap:10px}
@media(max-width:560px){.loan-grid{grid-template-columns:1fr!important}.mesax-box-actions .btn{width:100%}}

/* ---------- 5. Kartenschild (Über uns / Kontakt) – als echter, bearbeitbarer Text ---------- */
.map-frame{position:relative}
.map-place-label{position:absolute;left:52.2%;top:20px;margin-top:16.5%;transform:translateX(-50%);max-width:52%;
  background:#dceefb;border:2px solid #173f73;border-radius:8px;padding:4px 8px;text-align:center;
  color:#173f73;font-weight:700;font-size:12px;line-height:1.25;box-shadow:0 2px 8px rgba(23,63,115,.12);pointer-events:none;z-index:1}
html.mpz-inline-editing .map-place-label{pointer-events:auto;outline:2px dashed #76bf2d;outline-offset:2px}
.map-place-label small{display:block;font-weight:600;font-size:10px;color:#3e566b}

/* ---------- 6. Fortbildungen: Terminliste ---------- */
.termine-grid{display:grid;gap:12px;margin-top:20px}
.termine-month{margin:14px 0 2px;color:#173f73;font-size:17px;letter-spacing:.01em}
.termine-month:first-child{margin-top:0}
.termin-card{flex-direction:row!important;align-items:stretch;gap:16px!important;width:100%;padding:16px!important;cursor:pointer;font:inherit}
.termin-date{flex:none;width:64px;border-radius:12px;background:#e8f3df;color:#3a6e1e;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:8px 0}
.termin-date b{font-size:26px;line-height:1;font-weight:800}
.termin-date span{font-size:12px;font-weight:800;letter-spacing:.08em;margin-top:3px}
.termin-body{display:flex;flex-direction:column;align-items:flex-start;gap:6px;min-width:0;flex:1}
.termin-title{color:#173f73;font-weight:800;font-size:18px;line-height:1.3}
.termin-meta{color:#526779;font-size:14px;line-height:1.45}
.termin-body .mpz-tile-cta{margin-top:6px}
.termin-badge{display:inline-block;font-size:12px;font-weight:800;border-radius:999px;padding:3px 10px;line-height:1.4}
.termin-badge.is-next{background:#173f73;color:#fff}
.termin-badge.is-past{background:#e3e7eb;color:#4c5a66}
.termin-card.is-past{background:#f1f3f5!important;border-color:#e1e5e9!important;box-shadow:none!important}
.termin-card.is-past .termin-date{background:#dde2e6;color:#5d6973}
.termin-card.is-past .termin-title{color:#4c5a66}
.termin-card.is-past .termin-meta{color:#6b7782}
.termine-empty,.termine-loading{padding:20px;border-radius:16px;background:#f4f7fa;color:#526779;display:flex;flex-direction:column;gap:4px}
.termine-empty b{color:#173f73}
.schilf-contact{margin-top:14px}
.schilf-contact a{color:#173f73;font-weight:700;text-decoration:underline}
/* Pop-up: Details + Anmeldung */
.termin-facts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px 16px;margin:4px 0 16px;padding:14px 16px;background:#f4f8fb;border-radius:14px}
.termin-facts div{min-width:0}
.termin-facts dt{font-size:12px;font-weight:800;color:#5d7387;text-transform:uppercase;letter-spacing:.05em}
.termin-facts dd{margin:2px 0 0;color:#17344f;font-weight:700}
.termin-desc{margin:0 0 18px;color:#2f475c;line-height:1.65}
.termin-desc-empty{color:#6b7f90;font-style:italic}
.termin-form h3{margin:6px 0 12px;color:#173f73;font-size:20px}
.termin-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px 14px}
.termin-form-grid label{display:flex;flex-direction:column;gap:6px;font-weight:700;font-size:14px;color:#17344f}
.termin-form-grid label.full{grid-column:1/-1}
.termin-form-grid input,.termin-form-grid textarea{font:inherit;font-weight:400;font-size:16px;padding:12px 14px;border:1px solid #c9d6e2;border-radius:10px;background:#fff;color:#17344f;min-height:48px}
.termin-form-grid input:focus,.termin-form-grid textarea:focus{outline:none;border-color:#173f73;box-shadow:0 0 0 3px rgba(23,63,115,.15)}
.termin-form-grid .optional{font-weight:400;color:#6b7f90;font-size:13px}
.termin-consent{flex-direction:row!important;align-items:flex-start;gap:10px!important;font-weight:400!important;line-height:1.5}
.termin-consent input{min-height:0;width:22px;height:22px;flex:none;margin-top:1px;accent-color:#173f73}
.termin-consent a{color:#173f73;text-decoration:underline}
.termin-form .btn{margin-top:16px}
.termin-form-error{margin:12px 0 0;color:#a1261b;font-weight:700}
.termin-success,.termin-past-note{display:flex;flex-direction:column;gap:6px;padding:16px 18px;border-radius:14px;margin-top:6px}
.termin-success{background:#e8f3df;border:1px solid #bfdca5;color:#28501a}
.termin-success b{font-size:17px}
.termin-past-note{background:#f1f3f5;border:1px solid #e1e5e9;color:#4c5a66}
.termin-past-note a{color:#173f73;font-weight:700}
@media(max-width:600px){
  .termin-card{gap:12px!important;padding:14px!important}
  .termin-date{width:54px}.termin-date b{font-size:22px}
  .termin-title{font-size:16px}
  .termin-facts,.termin-form-grid{grid-template-columns:1fr}
  .termin-form .btn{width:100%}
}
/* Kontaktformular: ehrliche Statusmeldung */
.contact-send-status{margin:10px 0 0;padding:10px 12px;border-radius:10px;font-weight:700}
.contact-send-status.is-ok{background:#e8f3df;color:#28501a}
.contact-send-status.is-error{background:#fbe4e1;color:#8a2016}

/* Dialogfenster (mpz-dialog: Bearbeitungsmodus + Administration) ebenfalls im einheitlichen Blau */
.mpz-modal-ok{background:#173f73!important;color:#fff!important}
.mpz-modal-ok.mpz-modal-danger{background:#9a2116!important}
.mpz-modal-cancel{background:#eef4fb!important}
.mpz-modal-field input{min-height:44px}


/* Lange Wörter/Adressen (z. B. E-Mail-Adressen, Fachbegriffe) brechen auf dem Handy um statt seitlich zu scrollen */
main p,main li,main a,main td,main th,main dd,main dt,main h1,main h2,main h3,main h4{overflow-wrap:break-word;hyphens:auto}
main table{max-width:100%}

/* Showroom-Spalte auf „Technik & Verleih“ wie die Verleih-Spalte weiß, damit die hellblauen Kacheln darin gut erkennbar sind */
.tech-column.showroom{background:#fff!important;border-color:var(--mpz-tile-border)!important}

/* Info-Kacheln exakt wie die Team-Kachel: ohne grünen Deko-Punkt, gleiche Innenabstände und Schriftgrößen */
.advice-card,.info-card,.lernsax-card,.team-card{padding:20px!important;box-shadow:none!important}
.advice-card .dot,.info-card .dot,.contact-card .dot,.mpz-tile .dot{display:none!important}
.advice-card h3,.info-card h3,.lernsax-card h3,.team-card h3{color:#173f73;font-size:20px;margin:0 0 6px}
.advice-card p,.info-card p{font-size:15px;line-height:1.5}
.showroom-photo-card{box-shadow:none!important}
.showroom-photo-card:hover{box-shadow:var(--mpz-tile-shadow-hover)!important}
.contact-form button[type="submit"]{white-space:nowrap;padding:0 22px}
