:root{
  --forest:#0c2c21;
  --forest2:#173a2c;
  --green:#314d31;
  --cream:#f6f1e8;
  --paper:#fbf8f2;
  --gold:#c3964c;
  --orange:#b85e16;
  --brown:#6f381a;
  --olive:#56562a;
  --ink:#18271f;
  --muted:#626861;
  --line:#ddd5c8;
  --white:#fff;
  --shadow:0 18px 52px rgba(8,36,25,.13);
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--paper);color:var(--ink);font-family:Arial,Helvetica,sans-serif;line-height:1.5}
img{display:block;max-width:100%}
a{text-decoration:none;color:inherit}
button,input,textarea{font:inherit}
.container{width:min(1320px,calc(100% - 48px));margin:auto}

/* HEADER */
.site-header{position:sticky;top:0;z-index:50;background:#f8f4ec;border-bottom:1px solid rgba(0,0,0,.06)}
.header-inner{height:88px;display:flex;align-items:center;gap:30px}
.brand{display:flex;align-items:center;gap:12px;min-width:300px}
.brand img{width:260px;height:78px;object-fit:contain;object-position:left center}
.brand-fallback{display:none}
.main-nav{display:flex;align-items:center;gap:28px;margin-left:auto}
.main-nav a{font-size:.77rem;font-weight:850;color:#272b28;padding:34px 0;white-space:nowrap}
.main-nav a:hover{color:#a6531c}
.header-cta{background:var(--orange);color:#fff;padding:13px 20px;border-radius:7px;font-size:.78rem;font-weight:900;white-space:nowrap}
.menu-toggle{display:none;border:0;background:none;font-size:1.7rem;margin-left:auto}

/* HERO */
.hero{position:relative;min-height:520px;background:url("/assets/hero.jpg") right center/cover no-repeat;color:#fff;display:flex;align-items:center;overflow:hidden}
.hero-shade{position:absolute;inset:0;background:linear-gradient(90deg,rgba(8,27,20,.97) 0%,rgba(8,27,20,.95) 31%,rgba(8,27,20,.62) 48%,rgba(8,27,20,.08) 72%)}
.hero-inner{position:relative;padding:70px 0}
.eyebrow,.section-kicker{margin:0 0 9px;color:#c99c5a;letter-spacing:.2em;font-size:.72rem;font-weight:900}
.hero h1{margin:0;max-width:600px;font:500 clamp(3.2rem,6vw,5.8rem)/.96 Georgia,"Times New Roman",serif;letter-spacing:-.025em}
.hero-subtitle{margin:20px 0 15px;color:#e2bd82;letter-spacing:.21em;font-size:.82rem;font-weight:850}
.hero-text{max-width:500px;margin:0;color:#eef1ed;font-size:1rem}
.hero-actions{display:flex;gap:20px;margin-top:25px;flex-wrap:wrap}
.btn{display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:7px;padding:13px 21px;font-size:.8rem;font-weight:900;cursor:pointer}
.btn.primary{background:var(--orange);color:#fff}
.btn.secondary{color:#fff;background:rgba(9,31,23,.45);border:1px solid rgba(255,255,255,.65)}
.btn.orange{background:var(--orange);color:#fff}

/* BENEFITS */
.benefits{background:#f3eee5;border-bottom:1px solid #e5ded3}
.benefits-grid{display:grid;grid-template-columns:repeat(5,1fr)}
.benefit{min-height:90px;padding:18px 22px;display:grid;grid-template-columns:48px 1fr;align-items:center;gap:10px;position:relative}
.benefit:not(:last-child):after{content:"";position:absolute;right:0;top:19px;bottom:19px;width:1px;background:#d9d0c1}
.benefit-icon{
  width:48px;
  height:48px;
  display:flex;
  align-items:center;
  justify-content:center;
  text-align:center;
}
.benefit-icon img{
  display:block;
  width:42px;
  height:42px;
  object-fit:contain;
}
.benefit h3{margin:0 0 3px;font-size:.88rem}
.benefit p{margin:0;color:#73736e;font-size:.72rem}

/* MIDDLE */
.middle-section{position:relative;background:#faf7f1;min-height:390px;overflow:hidden}
.middle-layout{display:grid;grid-template-columns:360px 1fr;gap:55px;padding-top:28px;padding-bottom:28px}
.middle-copy h2{margin:0 0 15px;font:500 2.8rem/1.05 Georgia,"Times New Roman",serif}
.middle-copy>p:not(.section-kicker){margin:0;color:#555a55;font-size:.92rem}
.middle-copy .btn{margin-top:19px}

.cards{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
.info-card{background:#fff;box-shadow:0 6px 18px rgba(22,42,31,.05);overflow:hidden}
.card-image-button{display:block;width:100%;height:158px;padding:0;border:0;background:none;cursor:pointer;overflow:hidden}
.card-image-button img{width:100%;height:100%;object-fit:cover;transition:transform .25s ease}
.card-image-button:hover img{transform:scale(1.03)}
.card-body{min-height:155px;text-align:center;color:#fff;padding:18px 18px 15px}
.green-card{background:linear-gradient(180deg,#183d2c,#0d2a20)}
.brown-card{background:linear-gradient(180deg,#80421e,#603015)}
.olive-card{background:linear-gradient(180deg,#626030,#49471f)}
.card-icon{display:flex;justify-content:center;align-items:center;min-height:32px;margin:2px 0 6px}
.card-icon img{display:block;width:28px;height:28px;object-fit:contain}
.card-body h3{margin:4px 0 6px;letter-spacing:.12em;font-size:.88rem}
.card-body p{min-height:40px;margin:0;color:#ece8df;font-size:.8rem}
.card-more{margin-top:9px;background:none;border:0;color:#e6bf7b;font-size:.72rem;font-weight:850;cursor:pointer}

/* Full-width overlay over the entire light middle section */
.middle-overlay{
  position:absolute;inset:0;z-index:10;
  background:rgba(249,246,239,.985);
  padding:0;
}
.middle-overlay[hidden]{display:none}
.overlay-inner{
  width:min(1040px,calc(100% - 48px));height:100%;margin:auto;
  display:flex;flex-direction:column;justify-content:center;align-items:flex-start;
  padding:42px 0;
}
.overlay-inner h2{margin:0 0 18px;font:500 clamp(2.4rem,5vw,4.2rem)/1 Georgia,"Times New Roman",serif;color:#173127}
.overlay-textbox{
  width:100%;max-width:950px;min-height:145px;
  background:#fff;border:1px solid #d9d1c5;border-left:5px solid var(--orange);
  padding:24px 26px;margin-bottom:22px;
  box-shadow:0 12px 35px rgba(30,45,36,.07);
  font:1.02rem/1.7 Georgia,"Times New Roman",serif;color:#3c433e
}

/* CLOSING */
.closing{position:relative;min-height:170px;background:url("/assets/abschluss.jpg") center/cover no-repeat;display:flex;align-items:center}
.closing-shade{position:absolute;inset:0;background:rgba(50,33,19,.14)}
.closing-inner{position:relative;text-align:center}
.closing blockquote{margin:0;font:italic 1.65rem/1.18 Georgia,"Times New Roman",serif;color:#402c1d}

/* CONTACT */
.contact{background:#0d2b20;color:#fff;padding:74px 0}
.contact-grid{display:grid;grid-template-columns:.75fr 1.25fr;gap:58px}
.contact h2{margin:0 0 13px;font:500 2.8rem Georgia,"Times New Roman",serif}
.contact p{color:#c9d4cd}
.contact-data{display:grid;gap:6px;margin-top:25px}
.contact-data div{display:grid;grid-template-columns:85px 1fr;border-top:1px solid rgba(255,255,255,.12);padding:10px 0}
.contact-data b{color:#e6bd78}
.contact-form{background:#fff;color:#1b2921;border-radius:15px;padding:26px;display:grid;gap:14px;box-shadow:var(--shadow)}
.form-row{display:grid;grid-template-columns:1fr 1fr;gap:13px}
label{display:grid;gap:6px;font-size:.8rem;font-weight:800}
input,textarea{width:100%;border:1px solid #d5d0c6;border-radius:8px;padding:12px;outline:none}
input:focus,textarea:focus{border-color:#b26a27;box-shadow:0 0 0 3px rgba(178,106,39,.14)}
.form-message{min-height:20px;margin:0!important;font-size:.82rem;color:#2b7148!important}
.form-message.error{color:#a13939!important}
.honeypot{position:absolute!important;left:-9999px!important;width:1px!important;height:1px!important;overflow:hidden!important}

@media(max-width:1100px){
  .brand{min-width:245px}.brand img{width:230px}
  .main-nav{gap:17px}.main-nav a{font-size:.7rem}
  .benefits-grid{grid-template-columns:repeat(3,1fr)}
  .benefit:nth-child(3):after{display:none}
  .middle-layout{grid-template-columns:310px 1fr;gap:30px}
}
@media(max-width:900px){
  .site-header{height:auto}
  .header-inner{height:78px}
  .menu-toggle{display:block}
  .header-cta{display:none}
  .main-nav{display:none;position:absolute;top:78px;left:18px;right:18px;background:#f8f4ec;padding:15px;box-shadow:0 20px 50px rgba(0,0,0,.15);flex-direction:column;align-items:flex-start;gap:0}
  .main-nav.open{display:flex}
  .main-nav a{padding:8px 0}
  .hero{min-height:560px}
  .benefits-grid{grid-template-columns:1fr 1fr}
  .benefit:nth-child(3):after{display:block}
  .benefit:nth-child(2n):after{display:none}
  .middle-layout{grid-template-columns:1fr}
  .cards{grid-template-columns:repeat(3,1fr)}
  .middle-section{min-height:690px}
  .contact-grid{grid-template-columns:1fr}
}
@media(max-width:640px){
  .container{width:min(100% - 28px,1320px)}
  .brand{min-width:auto}.brand img{width:195px;height:65px}
  .hero{min-height:590px}
  .hero-shade{background:rgba(8,27,20,.62)}
  .hero h1{font-size:3.35rem}
  .benefits-grid,.cards{grid-template-columns:1fr}
  .benefit:after{left:0!important;right:0!important;top:auto!important;bottom:0!important;height:1px!important;width:auto!important;display:block!important}
  .middle-section{min-height:1180px}
  .middle-copy h2{font-size:2.35rem}
  .card-image-button{height:190px}
  .form-row{grid-template-columns:1fr}
  .overlay-inner{justify-content:flex-start;padding-top:45px;overflow:auto}
}


/* GALLERY SLIDER – VERSION 1.3
   Die Galerie übernimmt den KOMPLETTEN hellen Mittelbereich – einschließlich
   des bisherigen Bereichs „Mehr als nur ein Jagdschein“.
   Die Fotos behalten die Höhe und das Seitenverhältnis der normalen Kartenbilder. */
.gallery-view{
  position:absolute;
  inset:0;
  z-index:9;
  background:#faf7f1;
  overflow:hidden;
}
.gallery-view[hidden]{display:none}
.gallery-inner{
  height:100%;
  display:flex;
  flex-direction:column;
  gap:18px;
  padding-top:22px;
  padding-bottom:24px;
}
.gallery-heading{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  grid-template-areas:
    "kicker position"
    "title back"
    "intro back";
  column-gap:28px;
  align-items:center;
  min-width:0;
}
.gallery-heading .section-kicker{grid-area:kicker;margin-bottom:4px}
.gallery-heading h2{
  grid-area:title;
  margin:0;
  font:500 2.35rem/1.05 Georgia,"Times New Roman",serif;
  color:#173127;
}
.gallery-heading p:not(.section-kicker){
  grid-area:intro;
  margin:6px 0 0;
  color:#555a55;
  font-size:.88rem;
  max-width:820px;
}
.gallery-position{
  grid-area:position;
  justify-self:end;
  margin:0;
  font-weight:900;
  color:#8d5928;
}
.gallery-back{
  grid-area:back;
  justify-self:end;
  align-self:center;
  margin:0;
  white-space:nowrap;
}
.gallery-slider-column{
  width:100%;
  min-width:0;
  align-self:stretch;
}
.gallery-slider-shell{
  position:relative;
  width:100%;
  padding:0;
}
.gallery-viewport{
  width:100%;
  overflow-x:auto;
  scroll-behavior:smooth;
  scroll-snap-type:x mandatory;
  overscroll-behavior-x:contain;
  scrollbar-width:none;
  cursor:grab;
  touch-action:pan-y;
}
.gallery-viewport::-webkit-scrollbar{display:none}
.gallery-viewport.dragging{
  cursor:grabbing;
  scroll-behavior:auto;
  scroll-snap-type:none;
  user-select:none;
}
/* Die Breite orientiert sich an den drei normalen Kartenbildern (ca. 294 px bei voller Desktopbreite).
   Dadurch passen im gesamten Mittelbereich vier Bilder nebeneinander, ohne sie größer zu ziehen. */
.gallery-track{
  display:grid;
  grid-auto-flow:column;
  grid-auto-columns:min(294px, calc((100% - 36px)/4));
  gap:12px;
  min-width:max-content;
}
.gallery-card{
  position:relative;
  height:158px;
  aspect-ratio:1.86 / 1;
  scroll-snap-align:start;
  background:#fff;
  box-shadow:0 6px 18px rgba(22,42,31,.08);
  overflow:hidden;
  min-width:0;
}
.gallery-card button{
  display:block;
  width:100%;
  height:158px;
  padding:0;
  border:0;
  background:none;
  cursor:pointer;
  overflow:hidden;
}
.gallery-card img{
  width:100%;
  height:100%;
  object-fit:cover;
  transition:transform .22s ease;
}
.gallery-card button:hover img{transform:scale(1.03)}
.gallery-card-copy{
  pointer-events:none;
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  padding:28px 12px 10px;
  color:#fff;
  background:linear-gradient(180deg,rgba(7,25,18,0),rgba(7,25,18,.82));
}
.gallery-card h3{
  margin:0 0 2px;
  font:600 .92rem Georgia,"Times New Roman",serif;
  color:#fff;
  text-shadow:0 1px 3px rgba(0,0,0,.5);
}
.gallery-card p{
  margin:0;
  color:#f0f2ef;
  font-size:.68rem;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  text-shadow:0 1px 3px rgba(0,0,0,.55);
}
.gallery-arrow{
  position:absolute;
  z-index:3;
  top:79px;
  transform:translateY(-50%);
  width:34px;
  height:52px;
  border:1px solid rgba(255,255,255,.65);
  background:rgba(255,255,255,.94);
  color:#75411d;
  border-radius:7px;
  font-size:1.8rem;
  cursor:pointer;
  box-shadow:0 7px 22px rgba(20,40,30,.16);
}
.gallery-arrow.left{left:8px}
.gallery-arrow.right{right:8px}
.gallery-arrow:disabled{opacity:.35;cursor:default}
.gallery-empty{
  height:158px;
  display:grid;
  place-items:center;
  padding:20px;
  text-align:center;
  border:1px dashed #cabdaa;
  background:#fff;
  color:#77716a;
}
.gallery-empty[hidden]{display:none}

.gallery-lightbox{position:fixed;inset:0;z-index:100;background:rgba(4,18,13,.92);display:grid;grid-template-columns:70px 1fr 70px;align-items:center;padding:35px;color:#fff}
.gallery-lightbox[hidden]{display:none}
.gallery-lightbox figure{margin:0;justify-self:center;max-width:min(1100px,90vw);max-height:90vh;display:flex;flex-direction:column;align-items:center}
.gallery-lightbox img{max-width:100%;max-height:76vh;object-fit:contain;box-shadow:0 18px 70px rgba(0,0,0,.4)}
.gallery-lightbox figcaption{width:100%;display:grid;gap:4px;padding-top:12px;text-align:center}
.gallery-lightbox figcaption strong{font:600 1.3rem Georgia,"Times New Roman",serif;color:#eed09d}
.gallery-lightbox figcaption span{color:#d6ddd8}
.lightbox-close{position:absolute;right:22px;top:18px;width:44px;height:44px;border:0;border-radius:50%;background:#fff;color:#173127;font-size:2rem;cursor:pointer}
.lightbox-arrow{width:48px;height:68px;border:1px solid #ffffff55;background:#ffffff13;color:#fff;border-radius:8px;font-size:2.4rem;cursor:pointer}
.lightbox-arrow.left{justify-self:start}.lightbox-arrow.right{justify-self:end}

@media(max-width:1100px){
  .gallery-track{grid-auto-columns:calc((100% - 36px)/4)}
}
@media(max-width:900px){
  .gallery-inner{overflow:auto;gap:16px}
  .gallery-heading{
    grid-template-columns:1fr auto;
    grid-template-areas:
      "kicker position"
      "title title"
      "intro intro"
      "back back";
  }
  .gallery-heading h2{font-size:2.15rem}
  .gallery-back{justify-self:start;margin-top:6px}
  .gallery-track{grid-auto-columns:calc((100% - 24px)/3)}
}
@media(max-width:640px){
  .gallery-inner{padding-top:24px;padding-bottom:24px}
  .gallery-heading{grid-template-columns:1fr;grid-template-areas:"kicker" "title" "intro" "position" "back"}
  .gallery-position{justify-self:start;margin-top:5px}
  .gallery-heading h2{font-size:2rem}
  .gallery-track{grid-auto-columns:100%}
  .gallery-card,.gallery-card button,.gallery-empty{height:190px}
  .gallery-card{aspect-ratio:auto}
  .gallery-arrow{top:95px}
  .gallery-lightbox{grid-template-columns:42px 1fr 42px;padding:22px 8px}
  .lightbox-arrow{width:36px;height:58px}
}

/* GALLERY V1.4 – Bilder füllen die komplette Höhe der normalen Karten.
   Eine Galerie-Kachel ist jetzt so hoch wie Bild + Textbereich der drei
   Ausbildungskarten. Titel/Beschreibung liegen nur noch als Overlay auf dem Foto. */
.middle-section.gallery-open{
  min-height:500px;
}
.gallery-card{
  height:313px;
  aspect-ratio:auto;
}
.gallery-card button{
  height:100%;
}
.gallery-card img{
  width:100%;
  height:100%;
  object-fit:cover;
}
.gallery-card-copy{
  padding:72px 16px 15px;
  background:linear-gradient(180deg,rgba(7,25,18,0),rgba(7,25,18,.88));
}
.gallery-card h3{
  font-size:1.05rem;
  margin-bottom:4px;
}
.gallery-card p{
  font-size:.76rem;
}
.gallery-arrow{
  top:50%;
}
.gallery-empty{
  height:313px;
}

@media(max-width:900px){
  .middle-section.gallery-open{min-height:690px}
}
@media(max-width:640px){
  .middle-section.gallery-open{min-height:1180px}
  .gallery-card,.gallery-card button,.gallery-empty{height:330px}
  .gallery-arrow{top:165px}
}


/* CONTACT V1.5 – Kontaktformular ersetzt bei Aufruf den kompletten hellen Mittelbereich.
   Im normalen Seitenzustand ist der Kontaktbereich vollständig ausgeblendet. */
.contact-view{
  position:absolute;
  inset:0;
  z-index:9;
  background:#faf7f1;
  overflow:auto;
}
.contact-view[hidden]{display:none}
.contact-view-inner{
  min-height:100%;
  display:grid;
  grid-template-columns:minmax(300px,.78fr) minmax(460px,1.22fr);
  gap:52px;
  align-items:center;
  padding-top:28px;
  padding-bottom:28px;
}
.contact-heading h2{
  margin:0 0 14px;
  font:500 clamp(2.35rem,4.5vw,3.5rem)/1.05 Georgia,"Times New Roman",serif;
  color:#173127;
}
.contact-heading>p:not(.section-kicker){
  margin:0;
  color:#555a55;
  max-width:520px;
}
.contact-view .contact-data{
  display:grid;
  gap:0;
  margin-top:22px;
  color:#34423a;
}
.contact-view .contact-data div{
  display:grid;
  grid-template-columns:82px 1fr;
  gap:12px;
  border-top:1px solid #ddd5c8;
  padding:9px 0;
}
.contact-view .contact-data b{color:#98511f}
.contact-back{margin-top:20px}
.contact-view .contact-form{
  background:#fff;
  color:#1b2921;
  border:1px solid #ded6c9;
  border-radius:14px;
  padding:24px;
  display:grid;
  gap:13px;
  box-shadow:0 14px 38px rgba(22,42,31,.10);
}
.middle-section.contact-open{min-height:545px}

@media(max-width:900px){
  .middle-section.contact-open{min-height:780px}
  .contact-view-inner{
    grid-template-columns:1fr;
    gap:24px;
    align-items:start;
    padding-top:28px;
    padding-bottom:28px;
  }
  .contact-heading h2{font-size:2.35rem}
}
@media(max-width:640px){
  .middle-section.contact-open{min-height:980px}
  .contact-view-inner{padding-top:22px;padding-bottom:22px}
  .contact-view .contact-form{padding:17px}
}


/* V7: Alle "Zurück zur Hauptseite"-Buttons kompakter */
.gallery-back,
.contact-back,
#overlayBack{
  padding:7px 11px;
  font-size:.62rem;
  border-radius:4px;
  min-height:0;
  line-height:1.1;
  white-space:nowrap;
}

/* Kurse: gleicher Mittelbereich, responsiver Kalender */
.courses-overlay{overflow:hidden}
.courses-inner{box-sizing:border-box;justify-content:flex-start;min-height:0;overflow:hidden;padding-top:22px;padding-bottom:20px}
.courses-inner h2{font-size:clamp(1.6rem,3vw,2.7rem);margin-bottom:12px}
.courses-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:20px;width:100%;flex:1;min-height:0;overflow:auto;margin-bottom:14px}
.courses-calendar,.courses-list{background:white;border:1px solid #ded6c9;padding:18px;min-width:0}
.calendar-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:15px;text-transform:capitalize}
.calendar-head button{border:1px solid #ddd;background:#f6f2e9;border-radius:5px;padding:4px 14px;font-size:1.5rem;cursor:pointer}
.calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:5px;text-align:center}
.calendar-grid .weekday{font-weight:700;font-size:.8rem;padding:7px 0}
.calendar-day{border:1px solid transparent;background:#f5f3ee;border-radius:5px;min-height:38px;cursor:pointer;color:#243c2d}
.calendar-day.marked{background:#315e3e;color:white;font-weight:700}
.calendar-day.today{outline:2px solid #b87937;outline-offset:-2px}
.calendar-hint{font-size:.8rem;color:#666}
.courses-list{overflow-y:auto}
.courses-list h3{margin:0 0 10px}
.course-entry{padding:10px 0;border-top:1px solid #ddd;display:grid;gap:3px}
.course-entry time{color:#99612c;font-size:.83rem;font-weight:700}
.course-entry p{margin:0;white-space:pre-wrap;overflow-wrap:anywhere}
.course-entry.selected{background:#f7ecd6}
#coursesBack{flex-shrink:0}
@media(max-width:700px){.courses-inner{padding:14px 0}.courses-layout{grid-template-columns:1fr}.courses-calendar,.courses-list{padding:12px}.calendar-day{min-height:32px}}

.middle-overlay:not(.courses-overlay){overflow:hidden}
.middle-overlay:not(.courses-overlay) .overlay-inner{box-sizing:border-box;justify-content:flex-start;min-height:0;overflow:hidden;padding-top:24px;padding-bottom:24px}
.middle-overlay:not(.courses-overlay) .overlay-textbox{box-sizing:border-box;flex:1 1 auto;min-height:0;overflow-y:auto;overflow-wrap:anywhere;white-space:pre-wrap;margin-bottom:14px}
.middle-overlay:not(.courses-overlay) #overlayBack{flex-shrink:0}

/* Korrektur 18.11.: Vollstaendiger Monatskalender ohne Scrollen */
.middle-section:has(#coursesOverlay:not([hidden])){min-height:650px}
#coursesOverlay .courses-inner{height:100%;min-height:0;padding-top:18px;padding-bottom:16px}
#coursesOverlay .courses-inner h2{font-size:clamp(1.5rem,2.5vw,2.35rem);margin-bottom:10px}
#coursesOverlay .courses-layout{overflow:visible;min-height:0;flex:1;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:16px;margin-bottom:12px}
#coursesOverlay .courses-calendar{overflow:visible;padding:14px}
#coursesOverlay .courses-list{min-height:0;overflow-y:auto;padding:14px}
#coursesOverlay .calendar-head{margin-bottom:8px}
#coursesOverlay .calendar-grid{gap:4px}
#coursesOverlay .calendar-grid .weekday{padding:4px 0}
#coursesOverlay .calendar-day{min-height:36px;padding:4px 0}
#coursesOverlay .calendar-hint{margin-top:8px}
@media(max-width:700px){
 .middle-section:has(#coursesOverlay:not([hidden])){min-height:950px}
 #coursesOverlay .courses-layout{grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(150px,1fr);gap:10px}
 #coursesOverlay .courses-calendar,#coursesOverlay .courses-list{padding:10px}
 #coursesOverlay .calendar-day{min-height:32px}
}


/* Über uns: volle Mittelbreite, zwei unabhängig scrollbare Textbereiche */
.middle-section:has(#aboutOverlay:not([hidden])) { min-height: 590px; }
.about-overlay { overflow: hidden; }
.about-overlay .about-inner {
  box-sizing: border-box; justify-content: flex-start; align-items: stretch;
  padding: 20px 0; gap: 12px; min-height: 0;
}
.about-inner h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); margin: 0; }
.about-inner .section-kicker { margin: 0; }
.about-sections { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(0, 2.3fr); gap: 14px; flex: 1; min-height: 0; }
.about-panel { min-width: 0; min-height: 0; display: flex; flex-direction: column; background: #fff; border: 1px solid #ddd6c9; border-radius: 10px; padding: 16px; }
.about-panel h3 { margin: 0 0 12px; font: 600 1.25rem Georgia,serif; color: #173127; }
.about-text { overflow-y: auto; overflow-wrap: anywhere; white-space: pre-wrap; flex: 1; min-height: 0; line-height: 1.55; }
.about-inner #aboutBack { align-self: flex-start; flex-shrink: 0; }
@media(max-width: 800px) {
  .middle-section:has(#aboutOverlay:not([hidden])) { min-height: 880px; }
  .about-sections { grid-template-columns: 1fr; overflow-y: auto; }
  .about-panel { min-height: 180px; }
  .about-text { max-height: 240px; }
}
