
:root{
  --bg:#f4f7fb;
  --surface:#ffffff;
  --surface-soft:#eef3f9;
  --text:#122b46;
  --muted:#5a708a;
  --line:#d7e1ec;
  --primary:#123d72;
  --primary-strong:#0f315c;
  --primary-soft:#dfeaf6;
  --shadow:0 12px 30px rgba(18,43,70,.08);
  --radius:28px;
  --radius-sm:18px;
  --container:1360px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  background:linear-gradient(180deg,#f5f8fb 0%,#eef3f8 100%);
  color:var(--text);
  line-height:1.6;
}
img{max-width:100%;display:block}
a{color:inherit;text-decoration:none}
button{font:inherit}
.container{width:min(var(--container),calc(100% - 2rem));margin:0 auto}
.narrow{width:min(760px,100%);margin:0 auto}
.section{padding:4.5rem 0}
.section-soft{background:rgba(255,255,255,.45)}
.site-header{
  position:sticky;top:0;z-index:100;
  backdrop-filter:saturate(160%) blur(10px);
  background:rgba(245,248,251,.84);
  border-bottom:1px solid rgba(215,225,236,.8);
}
.navbar{
  min-height:84px;
  display:flex;align-items:center;justify-content:space-between;gap:1.25rem;
}
.brand{display:flex;align-items:center;gap:.85rem;min-width:0;flex:0 1 335px}
.brand-logo{width:72px;height:64px;padding:4px;border-radius:18px;background:#fff;box-shadow:0 10px 24px rgba(18,43,70,.12);object-fit:contain;object-position:center;flex:0 0 72px}
.brand-text{display:flex;flex-direction:column;gap:.1rem;min-width:0}
.brand-text strong{font-size:1.05rem;line-height:1.15;letter-spacing:-.02em}
.brand-text span{font-size:.84rem;color:var(--muted)}
.nav-links{display:flex;align-items:center;gap:.15rem;flex-wrap:wrap;justify-content:flex-end;flex:1 1 auto}
.nav-links a{
  padding:.72rem .85rem;border-radius:999px;
  color:var(--muted);font-weight:600;transition:.2s ease;font-size:.96rem;
}
.nav-links a:hover,.nav-links a.active{background:var(--primary-soft);color:var(--primary)}
.nav-toggle{display:none;border:0;background:none;padding:.25rem}
.nav-toggle span,.nav-toggle span::before,.nav-toggle span::after{
  display:block;width:24px;height:2px;background:var(--primary);border-radius:2px;position:relative;content:"";
}
.nav-toggle span::before{position:absolute;top:-7px}
.nav-toggle span::after{position:absolute;top:7px}

.hero{padding:3.4rem 0 2.2rem}
.hero-grid,.page-hero-grid{display:grid;grid-template-columns:1.05fr .95fr;gap:2rem;align-items:center}
.hero-copy h1,.page-hero h1{font-size:clamp(2.3rem,4vw,4.5rem);line-height:1.05;margin:.35rem 0 1rem;letter-spacing:-.03em}
.hero-copy p,.page-hero p{font-size:1.12rem;color:var(--muted);max-width:62ch;margin:0}
.hero-kicker,.eyebrow,.badge,.term-date,.step-number{
  display:inline-flex;align-items:center;justify-content:center;
  border-radius:999px;font-weight:700;
}
.hero-kicker,.eyebrow,.badge{
  background:var(--primary-soft);color:var(--primary);
  padding:.42rem .82rem;font-size:.88rem;letter-spacing:.01em
}
.hero-actions,.center-actions{display:flex;gap:.9rem;flex-wrap:wrap;margin-top:1.6rem}
.btn{
  display:inline-flex;align-items:center;justify-content:center;
  padding:.92rem 1.35rem;border-radius:999px;border:1px solid transparent;
  cursor:pointer;transition:.2s ease;font-weight:700
}
.btn:hover{transform:translateY(-1px)}
.btn-primary{background:var(--primary);color:#fff}
.btn-primary:hover{background:var(--primary-strong)}
.btn-secondary{background:var(--surface);color:var(--primary);border-color:var(--line)}
.btn-secondary:hover{border-color:#b7c8dc}
.text-link{font-weight:700;color:var(--primary)}
.hero-facts{
  margin-top:1.45rem;display:flex;flex-wrap:wrap;gap:.7rem
}
.hero-facts span{
  padding:.5rem .75rem;background:rgba(255,255,255,.75);border:1px solid var(--line);border-radius:999px;color:var(--muted);font-size:.93rem
}
.hero-media,.page-visual,.media-panel,.teaser-image{
  min-height:420px;border-radius:36px;background-size:cover;background-position:center;
  box-shadow:var(--shadow);position:relative;overflow:hidden;background-color:var(--surface-soft)
}
.hero-media::after,.page-visual::after,.media-panel::after,.teaser-image::after{
  content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(18,43,70,.02) 0%,rgba(18,43,70,.12) 100%);
}
.section-head{display:grid;gap:.55rem;margin-bottom:1.6rem}
.section-head .eyebrow,.page-hero .eyebrow{justify-self:start}
.page-hero{padding:2.4rem 0 1.2rem}
.page-hero + .section{padding-top:1.5rem}
.section-head h2{font-size:clamp(1.7rem,3vw,2.6rem);line-height:1.12;margin:0;letter-spacing:-.02em}
.section-head p{margin:0;color:var(--muted);max-width:64ch}
.section-head.split{grid-template-columns:1fr auto;align-items:end}
.card-grid{display:grid;gap:1.2rem}
.card-grid.three{grid-template-columns:repeat(3,1fr)}
.card-grid.two{grid-template-columns:repeat(2,1fr)}
.feature-card,.step-card,.term-card,.price-card,.info-panel,.contact-card{
  background:rgba(255,255,255,.84);border:1px solid rgba(215,225,236,.9);border-radius:32px;padding:1.55rem;box-shadow:var(--shadow)
}
.feature-card h3,.step-card h3,.term-card h3,.price-card h3,.info-panel h3,.contact-card h3{margin:.2rem 0 .5rem;font-size:1.35rem;line-height:1.2}
.feature-card p,.step-card p,.term-card p,.price-card p,.info-panel p,.contact-card p{margin:0;color:var(--muted)}
.map-card{background:rgba(255,255,255,.84);border:1px solid rgba(215,225,236,.9);border-radius:32px;padding:1.1rem;box-shadow:var(--shadow)}
.map-frame{width:100%;height:360px;border:0;border-radius:24px;background:var(--surface-soft)}
.map-note{margin:.9rem 0 0;color:var(--muted);font-size:.95rem}
.steps-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:1.1rem}
.step-number{
  width:2.2rem;height:2.2rem;background:var(--primary-soft);color:var(--primary);font-size:1rem;margin-bottom:.9rem
}
.term-date{
  background:#f0f5fb;color:var(--primary);padding:.42rem .76rem;font-size:.88rem;margin-bottom:.95rem
}
.teaser-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1.25rem}
.teaser-card{
  display:flex;flex-direction:column;background:var(--surface);border:1px solid var(--line);border-radius:34px;overflow:hidden;box-shadow:var(--shadow);min-height:100%
}
.teaser-card.tall{}
.teaser-image{min-height:0;height:240px;flex:0 0 240px;border-radius:0}
.teaser-content{padding:1.35rem;display:flex;flex-direction:column;gap:.75rem;flex:1}
.teaser-content h3{margin:0;font-size:1.45rem}
.teaser-content p{margin:0;color:var(--muted)}
.teaser-content .btn{align-self:flex-start;margin-top:auto}
.media-split{display:grid;grid-template-columns:1fr 1fr;gap:1.5rem;align-items:center}
.media-copy h2{font-size:clamp(1.8rem,3vw,2.8rem);line-height:1.12;margin:.35rem 0 1rem}
.media-copy p{margin:0 0 1rem;color:var(--muted)}
.bullet-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:1rem}
.bullet-item{
  background:rgba(255,255,255,.8);border:1px solid var(--line);border-radius:24px;padding:1rem 1.1rem;font-weight:600;color:var(--text)
}
.price-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1rem}
.price-card p{font-size:1.1rem;color:var(--primary);font-weight:700}
.note-box{
  margin-top:1rem;background:var(--primary-soft);color:var(--primary);padding:1rem 1.1rem;border-radius:22px;font-weight:700
}
.contact-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1rem}
.contact-name{font-weight:700;color:var(--text)!important}
.contact-meta{display:grid;gap:.35rem;margin-top:.9rem}
.contact-meta span,.contact-meta a{color:var(--muted);font-size:.95rem}
.contact-meta.muted{color:var(--muted)}
.info-panel{min-height:100%}
.legal h2{font-size:1.2rem;margin:1.8rem 0 .55rem}
.legal p{color:var(--muted);margin:0}
.footer{padding:1.6rem 0 2.2rem}
.footer-inner{
  border-top:1px solid rgba(215,225,236,.9);
  padding-top:1rem;display:flex;align-items:center;justify-content:space-between;gap:1rem;flex-wrap:wrap
}
.footer-title{font-weight:800}
.footer-brand p{margin:.2rem 0 0;color:var(--muted);font-size:.95rem}
.footer-links{display:flex;gap:1rem;flex-wrap:wrap}
.footer-links a{color:var(--muted);font-weight:600}
.form-modal{
  position:fixed;inset:0;background:rgba(9,26,47,.45);display:none;align-items:center;justify-content:center;padding:1rem;z-index:120
}
.form-modal.open{display:flex}
.form-shell{
  width:min(100%,680px);background:var(--surface);border-radius:32px;box-shadow:0 30px 90px rgba(0,0,0,.2);padding:1.5rem
}
.form-head{display:flex;justify-content:space-between;gap:1rem;align-items:flex-start;margin-bottom:1rem}
.form-head h3{margin:.35rem 0 0;font-size:1.55rem}
.small{margin:.35rem 0 0;color:var(--muted)}
.icon-btn{border:0;background:#f0f5fb;color:var(--primary);width:2.6rem;height:2.6rem;border-radius:999px;cursor:pointer}
.form-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:.9rem}
.field{display:grid;gap:.42rem}
.field.full{grid-column:1/-1}
.field label{font-weight:700;font-size:.95rem}
.field input,.field textarea,.field select{
  border:1px solid var(--line);border-radius:18px;padding:.9rem 1rem;background:#fff;color:var(--text)
}
.field textarea{min-height:118px;resize:vertical}
.choice-row{display:flex;gap:.55rem;flex-wrap:wrap}
.choice-row input{position:absolute;opacity:0;pointer-events:none}
.choice-row label{
  padding:.8rem 1rem;border:1px solid var(--line);border-radius:999px;background:#fff;cursor:pointer;font-weight:600;color:var(--muted)
}
.choice-row input:checked + label{
  background:var(--primary-soft);border-color:#bfd2ea;color:var(--primary)
}
.form-actions{display:flex;justify-content:flex-end;gap:.8rem;margin-top:1.1rem}
.form-status{margin-top:1rem;color:var(--muted)}
@media (max-width: 1120px){
  .card-grid.three,.teaser-grid,.contact-grid,.price-grid,.steps-grid{grid-template-columns:repeat(2,1fr)}
}
@media (max-width: 900px){
  .nav-toggle{display:block}
  .nav-links{display:none;position:absolute;top:84px;left:1rem;right:1rem;background:rgba(245,248,251,.98);border:1px solid var(--line);border-radius:24px;padding:.6rem;box-shadow:var(--shadow)}
  .nav-links.open{display:grid}
  .nav-links a{padding:.9rem 1rem;border-radius:18px}
  .hero-grid,.page-hero-grid,.media-split,.card-grid.two,.card-grid.three,.teaser-grid,.steps-grid,.bullet-grid,.contact-grid,.price-grid,.form-grid{grid-template-columns:1fr}
  .section-head.split{grid-template-columns:1fr}
  .hero-media,.page-visual,.media-panel,.teaser-image{min-height:280px}
  .navbar{align-items:center}
}
@media (max-width: 560px){
  .container{width:min(var(--container),calc(100% - 1rem))}
  .site-header{position:sticky}
  .navbar{min-height:74px;gap:1rem}
  .brand-logo{width:54px;height:50px;padding:3px;border-radius:15px;flex-basis:54px}
  .brand-text strong{font-size:1rem}
  .brand-text span{font-size:.76rem}
  .hero{padding-top:2rem}
  .section{padding:3.2rem 0}
  .feature-card,.step-card,.term-card,.price-card,.info-panel,.contact-card{border-radius:26px;padding:1.25rem}
  .form-shell{padding:1.1rem;border-radius:24px}
}

@media (max-width: 1280px){
  .navbar{gap:.85rem}
  .brand{flex-basis:300px}
  .brand-logo{width:62px;height:56px;flex-basis:62px;border-radius:16px}
  .nav-links a{padding:.62rem .62rem;font-size:.88rem}
}


.download-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1rem}
.download-card{
  background:rgba(255,255,255,.84);border:1px solid rgba(215,225,236,.9);
  border-radius:28px;padding:1.25rem;box-shadow:var(--shadow);display:grid;gap:.55rem
}
.download-card h3{margin:0;font-size:1.15rem;line-height:1.2}
.download-card p{margin:0;color:var(--muted)}
.download-card .btn{justify-self:start;margin-top:.4rem}
.price-table{
  width:100%;border-collapse:separate;border-spacing:0;background:rgba(255,255,255,.86);
  border:1px solid var(--line);border-radius:28px;overflow:hidden;box-shadow:var(--shadow)
}
.price-table th,.price-table td{padding:1rem;border-bottom:1px solid var(--line);text-align:left}
.price-table tr:last-child td{border-bottom:0}
.price-table th{background:#edf4fb;color:var(--primary)}
.notice-card{
  background:var(--primary-soft);color:var(--primary);border-radius:28px;padding:1.3rem;
  border:1px solid #bfd2ea;display:grid;gap:.45rem
}
.notice-card h3{margin:0;font-size:1.25rem}
.notice-card p{margin:0;color:var(--primary)}
.mini-meta{display:flex;flex-wrap:wrap;gap:.6rem;margin-top:1rem}
.mini-meta span{padding:.45rem .7rem;border-radius:999px;background:#fff;border:1px solid var(--line);color:var(--muted);font-size:.92rem}
.simple-list{display:grid;gap:.7rem;margin:0;padding:0;list-style:none}
.simple-list li{background:rgba(255,255,255,.75);border:1px solid var(--line);border-radius:20px;padding:.9rem 1rem}
@media (max-width: 1120px){
  .download-grid{grid-template-columns:repeat(2,1fr)}
}
@media (max-width: 900px){
  .download-grid{grid-template-columns:1fr}
  .price-table{font-size:.95rem}
}


.gallery-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:1.25rem;
}
.gallery-card{
  background:rgba(255,255,255,.84);
  border:1px solid rgba(215,225,236,.9);
  border-radius:34px;
  overflow:hidden;
  box-shadow:var(--shadow);
  min-width:0;
}
.gallery-card-wide{
  max-width:980px;
  margin:0 auto;
}
.gallery-stage{
  position:relative;
  aspect-ratio:16/10;
  background:var(--surface-soft);
  overflow:hidden;
}
.gallery-stage img{
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
  transition:opacity .24s ease;
}
.gallery-empty{
  position:absolute;
  inset:0;
  display:grid;
  place-items:center;
  padding:1.25rem;
  text-align:center;
  color:var(--muted);
  background:linear-gradient(135deg,#f7faff,#eaf1f8);
}
.gallery-empty code{
  display:inline-block;
  padding:.15rem .35rem;
  border-radius:.45rem;
  background:#fff;
  color:var(--primary);
}
.gallery-content{
  display:flex;
  justify-content:space-between;
  gap:1rem;
  align-items:flex-end;
  padding:1.25rem;
}
.gallery-content h3{
  margin:0 0 .35rem;
  font-size:1.3rem;
  line-height:1.2;
}
.gallery-content p{
  margin:0;
  color:var(--muted);
}
.gallery-controls{
  display:flex;
  align-items:center;
  gap:.6rem;
  flex:0 0 auto;
}
.gallery-controls button{
  width:2.35rem;
  height:2.35rem;
  border:1px solid var(--line);
  border-radius:999px;
  background:#fff;
  color:var(--primary);
  cursor:pointer;
  font-size:1.35rem;
  line-height:1;
  font-weight:800;
}
.gallery-controls button:hover{
  border-color:#b7c8dc;
  transform:translateY(-1px);
}
.gallery-controls span{
  min-width:3.6rem;
  color:var(--muted);
  font-size:.9rem;
  text-align:center;
}
@media (max-width:900px){
  .gallery-grid{grid-template-columns:1fr}
  .gallery-content{align-items:flex-start;flex-direction:column}
}


/* Kompakte Galerien auf den Themenseiten */
.gallery-section{
  padding-top:3rem;
}
.gallery-section .section-head{
  max-width:760px;
  margin-left:auto;
  margin-right:auto;
}
.gallery-card-wide{
  max-width:760px;
  margin:0 auto;
}
.gallery-stage{
  aspect-ratio:16/9;
  max-height:430px;
}
.gallery-empty{
  font-size:.95rem;
  line-height:1.5;
}
.gallery-content{
  padding:1rem 1.1rem;
}
.gallery-content h3{
  font-size:1.15rem;
}
.gallery-content p{
  font-size:.95rem;
}
@media (max-width:900px){
  .gallery-card-wide{
    max-width:100%;
  }
  .gallery-stage{
    max-height:none;
  }
}


/* Formular Datenschutz und Spam Schutz */
.hp-field{
  position:absolute;
  left:-9999px;
  width:1px;
  height:1px;
  overflow:hidden;
}
.form-privacy{
  margin:.4rem 0 0;
  color:var(--muted);
  font-size:.9rem;
  line-height:1.45;
}
.form-privacy a{
  color:var(--primary);
  font-weight:700;
  text-decoration:underline;
}

/* FAQ */
.faq-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:1rem;
}

/* Google Maps 2 Klick */
.map-consent{
  min-height:360px;
  display:grid;
  place-items:center;
  gap:.8rem;
  text-align:center;
  padding:2rem;
  border-radius:24px;
  background:linear-gradient(135deg,#f7faff,#eaf1f8);
}
.map-consent h3{
  margin:0;
  font-size:1.35rem;
}
.map-consent p{
  max-width:620px;
  margin:0;
  color:var(--muted);
}
.map-consent .btn{
  margin:.2rem;
}

/* Fehlerseite */
.error-page{
  min-height:60vh;
  display:grid;
  align-items:center;
}
.error-box{
  max-width:760px;
  margin:0 auto;
  text-align:center;
  background:rgba(255,255,255,.84);
  border:1px solid rgba(215,225,236,.9);
  border-radius:34px;
  padding:2rem;
  box-shadow:var(--shadow);
}

@media (max-width:900px){
  .faq-grid{
    grid-template-columns:1fr;
  }
}

/* Datenschutzoptimierte Google Maps Abfrage */
.map-actions{
  display:flex;
  gap:.75rem;
  flex-wrap:wrap;
  justify-content:center;
  margin-top:.2rem;
}
.map-consent .map-note{
  margin-top:.45rem;
  font-size:.9rem;
}
.map-consent .map-note a{
  color:var(--primary);
  font-weight:700;
  text-decoration:underline;
}

/* Kompakte Google Maps Abfrage */
.map-consent{
  min-height:260px;
  padding:1.6rem;
}
.map-consent h3{
  font-size:1.25rem;
}
.map-consent p{
  max-width:520px;
}
.map-consent .map-note{
  margin-top:.25rem;
}


/* Flexible Bausteine aus dem Admin Sitebuilder */
.text-grid{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:1rem}
.text-box{grid-column:span 12;background:rgba(255,255,255,.78);border:1px solid var(--line);border-radius:28px;padding:1.25rem;box-shadow:var(--shadow)}
.text-box.plain{background:transparent;border:0;box-shadow:none;padding:.25rem 0}
.text-box.soft{background:var(--primary-soft);color:var(--primary);border-color:#bfd2ea}
.text-box.width-third{grid-column:span 4}.text-box.width-half{grid-column:span 6}.text-box.width-two-third{grid-column:span 8}.text-box.width-full{grid-column:span 12}
.text-box.align-center{text-align:center}.text-box.align-right{text-align:right}
.text-box.size-small{font-size:.95rem}.text-box.size-large{font-size:1.12rem}
.text-box h3{margin:0 0 .55rem;font-size:1.25rem;line-height:1.2}.text-box.size-large h3{font-size:1.55rem}
.text-box p{margin:0;color:var(--muted);line-height:1.65}.text-box.soft p{color:var(--primary)}
.image-text{display:grid;grid-template-columns:1fr 1fr;gap:1.5rem;align-items:center}.image-text.reverse .image-text-media{order:-1}
.image-text-copy{background:rgba(255,255,255,.78);border:1px solid var(--line);border-radius:30px;padding:1.45rem;box-shadow:var(--shadow)}
.image-text-copy h2{margin:.25rem 0 .75rem}.image-text-copy p{color:var(--muted);line-height:1.65}
.image-text-media{min-height:360px;border-radius:34px;background-size:cover;background-position:center;box-shadow:var(--shadow);border:1px solid var(--line)}
.accordion-list{display:grid;gap:.75rem}.accordion-item{background:#fff;border:1px solid var(--line);border-radius:22px;box-shadow:var(--shadow);overflow:hidden}
.accordion-item summary{cursor:pointer;padding:1rem 1.15rem;font-weight:900;color:var(--primary)}
.accordion-item p{margin:0;padding:0 1.15rem 1.15rem;color:var(--muted);line-height:1.6}
@media (max-width:900px){
  .text-box.width-third,.text-box.width-half,.text-box.width-two-third,.text-box.width-full{grid-column:span 12}
  .image-text{grid-template-columns:1fr}.image-text.reverse .image-text-media{order:0}.image-text-media{min-height:260px}
}


/* Logo sichtbarer und sauber freigestellt */
.brand-logo{
  background:#fff;
  padding:7px;
  border-radius:20px;
  border:1px solid rgba(208,224,240,.95);
  box-shadow:0 12px 28px rgba(16,39,62,.14);
  object-fit:contain;
  object-position:center;
  filter:drop-shadow(0 2px 2px rgba(16,39,62,.10));
}
.site-footer .footer-admin-link{
  display:inline-flex;
  align-items:center;
  gap:.35rem;
  color:inherit;
  opacity:.72;
  text-decoration:none;
  font-size:.92rem;
}
.site-footer .footer-admin-link:hover{
  opacity:1;
  text-decoration:underline;
}


/* Galerie Mosaik: mehrere Bilder nebeneinander */
.gallery-card-wide{
  max-width:1040px;
}
.gallery-mosaic-stage{
  aspect-ratio:auto;
  min-height:360px;
  max-height:none;
  padding:.75rem;
}
.gallery-mosaic-grid{
  display:grid;
  grid-template-columns:2fr 1fr 1fr;
  grid-template-rows:170px 170px;
  gap:.65rem;
  width:100%;
  height:100%;
}
.gallery-mosaic-item{
  border:0;
  padding:0;
  border-radius:22px;
  overflow:hidden;
  background:#eaf1f8;
  cursor:pointer;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.4);
}
.gallery-mosaic-item:first-child{
  grid-row:span 2;
}
.gallery-mosaic-item img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transition:transform .25s ease, opacity .25s ease;
}
.gallery-mosaic-item:hover img{
  transform:scale(1.035);
}
@media (max-width:900px){
  .gallery-mosaic-stage{
    min-height:0;
  }
  .gallery-mosaic-grid{
    grid-template-columns:1fr 1fr;
    grid-template-rows:220px 140px 140px;
  }
  .gallery-mosaic-item:first-child{
    grid-column:span 2;
    grid-row:span 1;
  }
}
@media (max-width:560px){
  .gallery-mosaic-grid{
    grid-template-columns:1fr;
    grid-template-rows:none;
  }
  .gallery-mosaic-item,
  .gallery-mosaic-item:first-child{
    grid-column:auto;
    grid-row:auto;
    min-height:210px;
  }
}


/* Sicherer HTML Block aus dem Mini CMS */
.html-block-content{
  background:#fff;
  border:1px solid var(--line);
  border-radius:28px;
  padding:1.25rem;
  box-shadow:var(--shadow);
  color:var(--muted);
  line-height:1.65;
}
.html-block-content img{
  max-width:100%;
  height:auto;
  border-radius:22px;
}
.html-block-content table{
  width:100%;
  border-collapse:collapse;
  overflow:hidden;
  border-radius:18px;
}
.html-block-content th,
.html-block-content td{
  border:1px solid var(--line);
  padding:.75rem;
}


/* UI Fix: Admin Link im Footer dezent */
.site-footer .footer-admin-link{
  display:inline-flex;
  align-items:center;
  gap:.35rem;
  opacity:.42;
  text-decoration:none;
  font-size:.86rem;
}
.site-footer .footer-admin-link:hover{
  opacity:.9;
  text-decoration:underline;
}
.site-footer .footer-admin-link::before{
  content:"";
  width:.42rem;
  height:.42rem;
  border-radius:999px;
  background:currentColor;
  opacity:.55;
}

/* Logo Schärfe */
.brand-logo{filter:none !important; image-rendering:auto; transform:translateZ(0);}


/* Final Logo Fix */
.brand .brand-logo,
.brand-logo{
  width:96px !important;
  height:58px !important;
  flex:0 0 96px !important;
  padding:0 !important;
  background:transparent !important;
  border:0 !important;
  border-radius:0 !important;
  box-shadow:none !important;
  object-fit:contain !important;
  object-position:center !important;
  filter:none !important;
  image-rendering:auto !important;
}
.brand{
  gap:1rem !important;
}
@media(max-width:720px){
  .brand .brand-logo,
  .brand-logo{
    width:76px !important;
    height:48px !important;
    flex-basis:76px !important;
  }
}


/* Termine Seitenkopf ruhiger und linksbündig */
body:has(a[href="/termine"].active) .page-hero,
body.termine-page .page-hero{
  text-align:left;
  align-items:flex-start;
}
body:has(a[href="/termine"].active) .page-hero .section-eyebrow,
body.termine-page .page-hero .section-eyebrow{
  margin-left:0;
  margin-right:auto;
}
body:has(a[href="/termine"].active) .page-hero h1,
body.termine-page .page-hero h1{
  max-width:760px;
  font-size:clamp(3rem, 6vw, 5.4rem);
}
body:has(a[href="/termine"].active) .page-hero p,
body.termine-page .page-hero p{
  max-width:720px;
  margin-left:0;
  margin-right:auto;
}


/* Rich Text Ausgabe */
.rich-text{
  color:inherit;
  line-height:1.65;
}
.rich-text p{
  margin:.45rem 0;
}
.rich-text ul,
.rich-text ol{
  margin:.6rem 0 .85rem 1.25rem;
  padding:0;
}
.rich-text li{
  margin:.25rem 0;
}
.rich-text h3,
.rich-text h4{
  margin:1rem 0 .45rem;
  line-height:1.2;
  color:var(--ink, #10273e);
}
.rich-text blockquote{
  margin:.8rem 0;
  padding:.85rem 1rem;
  border-left:4px solid var(--brand, #236bd3);
  background:rgba(35,107,211,.08);
  border-radius:14px;
}
.rich-text a{
  color:var(--brand, #236bd3);
  font-weight:800;
  text-decoration:underline;
  text-underline-offset:.15em;
}
.rt-size-small{font-size:.9em}
.rt-size-normal{font-size:1em}
.rt-size-large{font-size:1.18em}
.rt-size-xlarge{font-size:1.38em;line-height:1.35}
.rt-color-navy{color:#10273e}
.rt-color-accent{color:#236bd3}
.rt-color-muted{color:#64748b}
.rt-color-green{color:#16703a}
.rt-color-red{color:#b42318}
.rt-note-inline,
.rt-small-info{
  display:inline-block;
  padding:.25rem .45rem;
  border-radius:.7rem;
  background:#eaf3ff;
  color:#123d72;
  font-weight:800;
}
.image-caption{
  font-size:.9rem;
  color:#64748b;
  margin-top:.55rem;
}
.image-text-media.img-size-small{min-height:220px}
.image-text-media.img-size-medium{min-height:320px}
.image-text-media.img-size-large{min-height:430px}
.image-text-media.img-size-full{min-height:520px}


/* Editor Fix: Inline Styles aus dem Admin */
.rich-text span[style],
.hero-lead span[style],
.section-lead span[style],
h1 span[style],
h2 span[style],
h3 span[style]{
  display:inline;
}

/* Zusatzfelder aus dem visuellen Editor */
.section-extra-grid{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:1rem;margin-top:1rem}
.section-extra{grid-column:span 12;border-radius:28px;padding:1.25rem;background:rgba(255,255,255,.78);border:1px solid var(--line);box-shadow:var(--shadow)}
.section-extra.plain{background:transparent;border:0;box-shadow:none;padding:.2rem 0}
.section-extra.soft{background:var(--primary-soft);color:var(--primary);border-color:#bfd2ea}
.section-extra.width-third{grid-column:span 4}.section-extra.width-half{grid-column:span 6}.section-extra.width-two-third{grid-column:span 8}.section-extra.width-full{grid-column:span 12}
.section-extra.align-center{text-align:center}.section-extra.align-right{text-align:right}
.section-extra.size-small{font-size:.95rem}.section-extra.size-large{font-size:1.12rem}
.section-extra h3{margin:0 0 .5rem;font-size:1.35rem;line-height:1.2}.section-extra.kind-heading h3{font-size:clamp(1.45rem,2.3vw,2rem);letter-spacing:-.02em}
.section-extra .rich-text{color:var(--muted)}.section-extra.soft .rich-text{color:var(--primary)}
@media(max-width:760px){.section-extra.width-third,.section-extra.width-half,.section-extra.width-two-third,.section-extra.width-full{grid-column:span 12}}
.section-elements{display:flex;flex-direction:column;align-items:flex-start;gap:.65rem;width:100%}
.section-elements .hero-actions{margin-top:.95rem}.section-elements .hero-facts{margin-top:.75rem}
.section-elements-section .section-extra{width:100%;max-width:100%;margin-top:.35rem}
.section-elements-section .section-extra.width-half{width:min(50%,680px)}
.section-elements-section .section-extra.width-third{width:min(33.333%,440px)}
.section-elements-section .section-extra.width-two-third{width:min(66.666%,880px)}
.section-elements-section .section-extra.width-full{width:100%}
.section-elements-section .section-extra.align-center{align-self:center;text-align:center}
.section-elements-section .section-extra.align-right{align-self:flex-end;text-align:right}
.section-elements-hero .section-extra,.section-elements-page_hero .section-extra,.section-elements-simple_hero .section-extra{width:100%;max-width:100%;margin-top:.35rem}
@media(max-width:760px){.section-elements-section .section-extra.width-half,.section-elements-section .section-extra.width-third,.section-elements-section .section-extra.width-two-third{width:100%}}

/* Compact public website rhythm
   Reduces spacing and oversized elements without changing content, colors, or layout intent. */
:root{
  --container:1280px;
  --shadow:0 9px 24px rgba(18,43,70,.075);
  --radius:24px;
  --radius-sm:16px;
}
body{line-height:1.55;}
.container{width:min(var(--container),calc(100% - 2rem));}
.navbar{min-height:72px;gap:.9rem;}
.brand{flex-basis:300px;gap:.8rem !important;}
.brand .brand-logo,.brand-logo{width:88px !important;height:52px !important;flex-basis:88px !important;}
.brand-text strong{font-size:1rem;line-height:1.1;}
.brand-text span{font-size:.78rem;}
.nav-links a{padding:.52rem .62rem;font-size:.88rem;white-space:nowrap;}
.hero{padding:2.45rem 0 1.45rem;}
.hero-grid,.page-hero-grid{gap:1.55rem;grid-template-columns:1.05fr .95fr;}
.hero-copy h1,.page-hero h1{font-size:clamp(2.1rem,3.55vw,3.95rem);line-height:1.06;margin:.28rem 0 .8rem;}
.hero-copy p,.page-hero p,.hero-lead,.section-lead{font-size:1.02rem;line-height:1.55;max-width:58ch;}
.hero-kicker,.eyebrow,.badge{padding:.32rem .68rem;font-size:.8rem;}
.hero-actions,.center-actions{gap:.65rem;margin-top:1.1rem;}
.btn{padding:.72rem 1.05rem;font-size:.94rem;}
.hero-facts{margin-top:1rem;gap:.52rem;}
.hero-facts span{padding:.38rem .62rem;font-size:.85rem;}
.hero-media,.page-visual,.media-panel{min-height:340px;border-radius:28px;}
.section{padding:3rem 0;}
.section-head{gap:.42rem;margin-bottom:1.15rem;}
.section-head h2{font-size:clamp(1.55rem,2.35vw,2.25rem);line-height:1.12;}
.section-head p,.section-lead{font-size:.98rem;}
.page-hero{padding:1.8rem 0 .8rem;}
.page-hero + .section{padding-top:1rem;}
.card-grid{gap:.9rem;}
.feature-card,.step-card,.term-card,.price-card,.info-panel,.contact-card{border-radius:24px;padding:1.15rem;}
.feature-card h3,.step-card h3,.term-card h3,.price-card h3,.info-panel h3,.contact-card h3{font-size:1.18rem;margin:.1rem 0 .35rem;}
.feature-card p,.step-card p,.term-card p,.price-card p,.info-panel p,.contact-card p,.rich-text{line-height:1.55;}
.steps-grid{gap:.85rem;}
.step-number{width:2rem;height:2rem;font-size:.92rem;margin-bottom:.65rem;}
.term-date{padding:.34rem .62rem;font-size:.8rem;margin-bottom:.65rem;}
.teaser-grid{gap:.9rem;}
.teaser-card{border-radius:26px;}
.teaser-image{height:200px;flex-basis:200px;}
.teaser-content{padding:1.05rem;gap:.55rem;}
.teaser-content h3{font-size:1.22rem;}
.media-split,.image-text{gap:1.1rem;}
.media-copy h2{font-size:clamp(1.55rem,2.45vw,2.3rem);margin:.25rem 0 .65rem;}
.media-copy p{margin-bottom:.75rem;}
.bullet-grid,.price-grid,.contact-grid,.download-grid{gap:.8rem;}
.bullet-item,.download-card{border-radius:20px;padding:.85rem 1rem;}
.map-card{border-radius:24px;padding:.9rem;}
.map-frame{height:320px;border-radius:20px;}
.note-box{margin-top:.75rem;padding:.85rem 1rem;border-radius:18px;}
.footer{padding:1.15rem 0 1.6rem;}
.footer-inner{padding-top:.85rem;}
.form-shell{border-radius:26px;padding:1.25rem;}
.field input,.field textarea,.field select{border-radius:16px;padding:.78rem .9rem;}
.choice-row label{padding:.68rem .9rem;}
.gallery-section{padding-top:2rem;}
.gallery-card-wide{max-width:960px;}
.gallery-mosaic-stage{min-height:300px;padding:.65rem;}
.gallery-mosaic-grid{grid-template-rows:145px 145px;gap:.55rem;}
.gallery-mosaic-item{border-radius:18px;}
.html-block-content{border-radius:22px;padding:1rem;}
.text-grid,.section-extra-grid{gap:.8rem;}
.text-box,.section-extra{border-radius:22px;padding:1rem;}
.text-box h3,.section-extra h3{font-size:1.15rem;margin-bottom:.4rem;}
.image-text-copy{border-radius:24px;padding:1.15rem;}
.image-text-media{min-height:310px;border-radius:26px;}
.image-text-media.img-size-small{min-height:200px;}
.image-text-media.img-size-medium{min-height:290px;}
.image-text-media.img-size-large{min-height:380px;}
.image-text-media.img-size-full{min-height:460px;}
.accordion-list{gap:.6rem;}
.accordion-item{border-radius:18px;}
.accordion-item summary{padding:.85rem 1rem;}
.accordion-item p{padding:0 1rem 1rem;}
body:has(a[href="/termine"].active) .page-hero h1,
body.termine-page .page-hero h1{font-size:clamp(2.05rem,4vw,3.6rem);}
@media (max-width:900px){
  .navbar{min-height:68px;}
  .nav-links{top:72px;}
  .hero{padding-top:1.65rem;}
  .section{padding:2.35rem 0;}
  .hero-media,.page-visual,.media-panel{min-height:260px;}
  .hero-copy h1,.page-hero h1{font-size:clamp(1.9rem,7.5vw,3rem);}
  .brand .brand-logo,.brand-logo{width:74px !important;height:46px !important;flex-basis:74px !important;}
}
@media (max-width:560px){
  .container{width:min(var(--container),calc(100% - 1rem));}
  .section{padding:2rem 0;}
  .hero{padding:1.35rem 0 1rem;}
  .hero-actions,.center-actions{gap:.5rem;}
  .btn{width:auto;min-height:0;padding:.68rem .9rem;}
  .hero-facts span{font-size:.82rem;}
  .feature-card,.step-card,.term-card,.price-card,.info-panel,.contact-card{padding:1rem;border-radius:22px;}
}

/* Compact mobile correction: keep the original one-column mobile layout. */
@media (max-width:900px){
  .hero-grid,
  .page-hero-grid,
  .media-split,
  .image-text{
    grid-template-columns:1fr !important;
  }
}


/* KSC v19: kompakt, aber wieder etwas breiter und ohne Navigationsumbruch */
@media (min-width: 901px){
  .container{width:min(1280px,calc(100% - 2rem));}
  .navbar{min-height:72px;gap:.9rem;}
  .brand{flex:0 0 320px;}
  .nav-links{flex-wrap:nowrap;gap:.05rem;}
  .nav-links a{white-space:nowrap;padding:.52rem .62rem;font-size:.88rem;}
}
@media (min-width: 1500px){
  .container{width:min(1320px,calc(100% - 2rem));}
  .hero-copy h1,.page-hero h1{font-size:clamp(2.15rem,3.35vw,4rem);}
}
@media (max-width: 1220px) and (min-width: 901px){
  .brand{flex-basis:275px;}
  .brand-text strong{font-size:.96rem;}
  .brand-text span{font-size:.78rem;}
  .nav-links a{font-size:.82rem;padding:.46rem .48rem;}
}

/* v37: Mobile Formular Modal */
.form-shell,
.form-shell *{
  box-sizing:border-box;
}
.form-modal{
  overflow-y:auto;
  -webkit-overflow-scrolling:touch;
}
.form-required-note{
  margin:.15rem 0 .75rem;
  color:var(--muted);
  font-size:.9rem;
  line-height:1.45;
}
.required-mark{
  color:#b91c1c;
  font-weight:800;
}
.form-consent{
  display:grid;
  grid-template-columns:auto 1fr;
  gap:.65rem;
  align-items:start;
  margin:.95rem 0 0;
  color:var(--muted);
  font-size:.92rem;
  line-height:1.45;
}
.form-consent input{
  width:1.1rem;
  height:1.1rem;
  margin:.15rem 0 0;
}
.form-consent a{
  color:var(--primary);
  font-weight:700;
  text-decoration:underline;
}
.field input,
.field textarea,
.field select{
  width:100%;
  max-width:100%;
  box-sizing:border-box;
  font:inherit;
}
.form-actions .btn{
  white-space:nowrap;
}

@media (max-width:700px){
  .form-modal{
    align-items:flex-start;
    justify-content:center;
    padding:max(.75rem,env(safe-area-inset-top)) .75rem max(.75rem,env(safe-area-inset-bottom));
  }
  .form-shell{
    width:100%;
    max-width:100%;
    max-height:calc(100dvh - 1.5rem);
    overflow-y:auto;
    border-radius:22px;
    padding:1rem;
  }
  .form-head{
    gap:.75rem;
    margin-bottom:.75rem;
  }
  .form-head h3{
    font-size:1.28rem;
    line-height:1.18;
  }
  .small{
    font-size:.92rem;
    line-height:1.4;
  }
  .icon-btn{
    width:2.35rem;
    height:2.35rem;
    flex:0 0 auto;
  }
  .form-grid{
    grid-template-columns:1fr;
    gap:.75rem;
  }
  .field{
    gap:.35rem;
  }
  .field label{
    font-size:.9rem;
  }
  .field input,
  .field textarea,
  .field select{
    min-height:44px;
    border-radius:14px;
    padding:.74rem .85rem;
    font-size:16px;
  }
  .field textarea{
    min-height:92px;
    max-height:180px;
  }
  .choice-row{
    display:grid;
    grid-template-columns:1fr;
    gap:.5rem;
  }
  .choice-row label{
    width:100%;
    border-radius:16px;
    padding:.72rem .85rem;
  }
  .form-consent{
    font-size:.88rem;
    gap:.55rem;
  }
  .form-privacy{
    font-size:.85rem;
  }
  .form-actions{
    display:grid;
    grid-template-columns:1fr;
    gap:.65rem;
    margin-top:.95rem;
  }
  .form-actions .btn{
    width:100%;
    min-height:44px;
    justify-content:center;
  }
  .form-status{
    font-size:.9rem;
    line-height:1.4;
  }
}

@media (max-width:380px){
  .form-modal{
    padding:.5rem;
  }
  .form-shell{
    max-height:calc(100dvh - 1rem);
    padding:.85rem;
    border-radius:18px;
  }
  .form-head h3{
    font-size:1.18rem;
  }
}

/* v38: Galerie breiter, mobil stabil, Bildansicht */
.gallery-section .container{
  width:min(1280px,calc(100% - 2rem));
}
.gallery-section .section-head{
  max-width:860px;
}
.gallery-card-wide{
  max-width:1180px;
}
.gallery-mosaic-stage{
  min-height:0;
  padding:.75rem;
}
.gallery-mosaic-grid{
  height:auto;
  min-height:clamp(320px,34vw,440px);
  grid-template-columns:minmax(0,2fr) minmax(0,1fr) minmax(0,1fr);
  grid-template-rows:minmax(150px,1fr) minmax(150px,1fr);
  align-items:stretch;
}
.gallery-mosaic-item{
  min-width:0;
  min-height:0;
  appearance:none;
  -webkit-appearance:none;
}
.gallery-mosaic-item:focus-visible,
.gallery-controls button:focus-visible,
.gallery-lightbox button:focus-visible{
  outline:3px solid rgba(35,107,211,.35);
  outline-offset:3px;
}
.gallery-mosaic-item::after{
  content:'Bild ansehen';
  position:absolute;
  left:.65rem;
  bottom:.65rem;
  padding:.32rem .55rem;
  border-radius:999px;
  background:rgba(16,39,62,.72);
  color:#fff;
  font-size:.78rem;
  font-weight:800;
  opacity:0;
  transform:translateY(.25rem);
  transition:opacity .2s ease, transform .2s ease;
  pointer-events:none;
}
.gallery-mosaic-item:hover::after,
.gallery-mosaic-item:focus-visible::after{
  opacity:1;
  transform:translateY(0);
}
.gallery-lightbox-open{
  overflow:hidden;
}
.gallery-lightbox{
  position:fixed;
  inset:0;
  z-index:1000;
  display:none;
  align-items:center;
  justify-content:center;
  padding:clamp(.75rem,2vw,1.5rem);
}
.gallery-lightbox.is-open{
  display:flex;
}
.gallery-lightbox-backdrop{
  position:absolute;
  inset:0;
  background:rgba(8,23,38,.86);
  backdrop-filter:blur(8px);
}
.gallery-lightbox-panel{
  position:relative;
  z-index:1;
  width:min(1180px,100%);
  max-height:calc(100dvh - 2rem);
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto;
  align-items:center;
  gap:.75rem;
}
.gallery-lightbox-figure{
  margin:0;
  min-width:0;
  border-radius:28px;
  overflow:hidden;
  background:#fff;
  box-shadow:0 24px 80px rgba(0,0,0,.35);
}
.gallery-lightbox-figure img{
  display:block;
  width:100%;
  max-height:calc(100dvh - 8rem);
  object-fit:contain;
  background:#06192b;
}
.gallery-lightbox-figure figcaption{
  display:flex;
  justify-content:space-between;
  gap:1rem;
  padding:.85rem 1rem;
  color:var(--muted);
  font-size:.95rem;
}
.gallery-lightbox-figure figcaption strong{
  color:var(--primary);
  white-space:nowrap;
}
.gallery-lightbox-close,
.gallery-lightbox-nav{
  border:1px solid rgba(255,255,255,.28);
  background:rgba(255,255,255,.92);
  color:var(--primary);
  border-radius:999px;
  cursor:pointer;
  font-weight:900;
  box-shadow:0 12px 30px rgba(0,0,0,.22);
}
.gallery-lightbox-close{
  position:absolute;
  top:-.35rem;
  right:-.35rem;
  width:2.75rem;
  height:2.75rem;
  font-size:1.65rem;
  line-height:1;
  z-index:2;
}
.gallery-lightbox-nav{
  width:3rem;
  height:3rem;
  font-size:2rem;
  line-height:1;
}
.gallery-lightbox-nav[hidden]{
  display:none;
}
@media (max-width:900px){
  .gallery-section .container{
    width:min(100% - 1rem,1280px);
  }
  .gallery-card-wide{
    max-width:100%;
  }
  .gallery-mosaic-stage{
    padding:.55rem;
  }
  .gallery-mosaic-grid{
    grid-template-columns:1fr 1fr;
    grid-template-rows:auto;
    min-height:0;
    height:auto;
    gap:.5rem;
  }
  .gallery-mosaic-item{
    aspect-ratio:4/3;
    min-height:0;
    border-radius:16px;
  }
  .gallery-mosaic-item:first-child{
    grid-column:1 / -1;
    grid-row:auto;
    aspect-ratio:16/10;
  }
  .gallery-content{
    align-items:flex-start;
    gap:.9rem;
  }
  .gallery-controls{
    width:100%;
    justify-content:flex-end;
  }
}
@media (max-width:560px){
  .gallery-section .section-head{
    margin-bottom:.9rem;
  }
  .gallery-section .section-head h2{
    font-size:clamp(1.55rem,7vw,2.1rem);
  }
  .gallery-card{
    border-radius:24px;
  }
  .gallery-content{
    padding:.9rem;
  }
  .gallery-mosaic-item::after{
    display:none;
  }
  .gallery-lightbox{
    padding:.6rem;
  }
  .gallery-lightbox-panel{
    grid-template-columns:1fr;
    gap:.55rem;
  }
  .gallery-lightbox-nav{
    position:absolute;
    top:50%;
    transform:translateY(-50%);
    width:2.6rem;
    height:2.6rem;
    font-size:1.7rem;
    z-index:2;
  }
  .gallery-lightbox-prev{
    left:.35rem;
  }
  .gallery-lightbox-next{
    right:.35rem;
  }
  .gallery-lightbox-close{
    top:.35rem;
    right:.35rem;
  }
  .gallery-lightbox-figure{
    border-radius:22px;
  }
  .gallery-lightbox-figure img{
    max-height:calc(100dvh - 7rem);
  }
  .gallery-lightbox-figure figcaption{
    padding:.75rem .85rem;
    font-size:.88rem;
  }
}

/* v39: Ruhigere Galerie ohne automatisches Umstellen */
.gallery-section .container{
  width:min(1360px,calc(100% - 2rem));
}
.gallery-card-wide{
  max-width:1280px;
}
.gallery-mosaic-stage{
  padding:.75rem;
  overflow:hidden;
  background:linear-gradient(135deg,#f7faff,#eaf1f8);
}
.gallery-mosaic-grid{
  display:grid;
  grid-template-columns:minmax(0,2fr) minmax(0,1fr) minmax(0,1fr);
  grid-template-rows:clamp(170px,17vw,260px) clamp(170px,17vw,260px);
  gap:.7rem;
  width:100%;
  height:auto;
  min-height:0;
}
.gallery-mosaic-item{
  position:relative;
  display:block;
  width:100%;
  min-width:0;
  min-height:0;
  border:0;
  padding:0;
  border-radius:22px;
  overflow:hidden;
  background:#eaf1f8;
}
.gallery-mosaic-item:first-child{
  grid-row:span 2;
}
.gallery-mosaic-item img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
}
.gallery-controls span{
  min-width:4.7rem;
}
@media (max-width:900px){
  .gallery-section .container{
    width:min(100% - 1rem,1280px);
  }
  .gallery-mosaic-stage{
    padding:.55rem;
  }
  .gallery-mosaic-grid{
    grid-template-columns:1fr 1fr;
    grid-template-rows:none;
    gap:.55rem;
  }
  .gallery-mosaic-item,
  .gallery-mosaic-item:first-child{
    grid-column:auto;
    grid-row:auto;
    aspect-ratio:4/3;
  }
  .gallery-mosaic-item:first-child{
    grid-column:1 / -1;
    aspect-ratio:16/10;
  }
}
@media (max-width:560px){
  .gallery-mosaic-grid{
    grid-template-columns:1fr;
    gap:.55rem;
  }
  .gallery-mosaic-item,
  .gallery-mosaic-item:first-child{
    grid-column:auto;
    grid-row:auto;
    aspect-ratio:4/3;
    min-height:0;
    border-radius:16px;
  }
  .gallery-content{
    padding:.9rem;
  }
  .gallery-controls{
    width:100%;
    justify-content:space-between;
  }
}

/* v41: Galeriehöhe stabilisieren
   Die Galerie bleibt breit, wächst aber nicht mehr unkontrolliert in die Höhe.
   Das Raster behält feste Bildflächen, damit beim automatischen Wechsel nichts springt. */
.gallery-card-wide{
  width:min(100%,1120px);
  max-width:min(1120px,calc(100vw - 2rem));
  margin-inline:auto;
  overflow:hidden;
}
.gallery-mosaic-stage{
  height:clamp(340px,36vw,520px);
  min-height:0;
  max-height:520px;
  padding:.65rem;
  overflow:hidden;
}
.gallery-mosaic-grid{
  height:100%;
  min-height:0;
  grid-template-columns:minmax(0,2fr) minmax(0,1fr) minmax(0,1fr);
  grid-template-rows:minmax(0,1fr) minmax(0,1fr);
  align-items:stretch;
}
.gallery-mosaic-item,
.gallery-mosaic-item:first-child{
  min-height:0;
  height:100%;
}
.gallery-mosaic-item img{
  width:100%;
  height:100%;
  object-fit:cover;
}
@media (max-width:900px){
  .gallery-card-wide{
    max-width:calc(100vw - 1rem);
  }
  .gallery-mosaic-stage{
    height:auto;
    max-height:none;
    padding:.55rem;
  }
  .gallery-mosaic-grid{
    height:auto;
    min-height:0;
    grid-template-columns:1fr 1fr;
    grid-template-rows:auto;
    gap:.5rem;
  }
  .gallery-mosaic-item{
    aspect-ratio:4 / 3;
    height:auto;
  }
  .gallery-mosaic-item:first-child{
    grid-column:1 / -1;
    grid-row:auto;
    aspect-ratio:16 / 10;
    height:auto;
  }
}
@media (max-width:560px){
  .gallery-mosaic-stage{
    padding:.45rem;
  }
  .gallery-mosaic-grid{
    grid-template-columns:1fr;
  }
  .gallery-mosaic-item,
  .gallery-mosaic-item:first-child{
    grid-column:auto;
    grid-row:auto;
    aspect-ratio:4 / 3;
    min-height:0;
    height:auto;
  }
}

