/* Inter als variable Schrift, lokal ausgeliefert (kein Google-Fonts-Abruf,
   damit keine IP-Adressen an Dritte gehen). Ein Font-File deckt 100–900 ab. */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("assets/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("assets/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --ink: #14202f;
  --muted: #5d6a78;
  --line: rgba(20, 32, 47, 0.14);
  --paper: #f8fbf9;
  --white: #ffffff;
  --mint: #dff5eb;
  --teal: #008b8b;
  /* --teal erreicht auf --paper nur 3,98:1 und ist damit für Text zu hell.
     --teal-text ist die abgedunkelte Variante für Fließtext-Auszeichnungen (5,7:1). */
  --teal-text: #00706f;
  --blue: #2457a6;
  --coral: #ef7d5b;
  --lime: #b9dc61;
  --darklinkgreen: #006868;
  --shadow: 0 24px 70px rgba(22, 39, 60, 0.14);
  --radius: 8px;
  /* Höhe der fixierten Kopfzeile – hält Ankersprünge unter dem Header frei. */
  --header-offset: 90px;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
}

/* Ohne diesen Offset landen alle Ankersprünge (#mission, #module, …)
   unter der fixierten Kopfzeile. */
:where(section, article)[id],
main[id] {
  scroll-margin-top: var(--header-offset);
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(180deg, rgba(223, 245, 235, 0.7) 0, rgba(248, 251, 249, 0) 420px),
    var(--paper);
}

body.nav-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
  /* Unverzichtbar, seit die Bilder width/height-Attribute tragen: ohne dies
     gewinnt der Attributwert als Höhe, sobald das CSS nur die Breite setzt –
     das Bild wird dann vertikal auseinandergezogen. Regeln, die bewusst eine
     feste Höhe vorgeben (.partner-grid img, .brand-logo …), sind spezifischer
     und überschreiben das hier. */
  height: auto;
}

a {
  color: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.sr-only,
.skip-link {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link:focus {
  z-index: 1000;
  top: 12px;
  left: 12px;
  width: auto;
  height: auto;
  padding: 12px 14px;
  clip: auto;
  background: var(--ink);
  color: var(--white);
  border-radius: var(--radius);
}

.site-header.show-logo .brand {
  opacity: 1;
  transform: scale(1);
}

.site-header {
  position: fixed;
  z-index: 100;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px clamp(18px, 4vw, 56px);
  transition:
    background 200ms ease,
    box-shadow 200ms ease,
    padding 200ms ease;
}

.site-header.is-scrolled {
  padding-block: 8px;
  background: rgba(248, 251, 249, 0.92);
  box-shadow: 0 10px 36px rgba(20, 32, 47, 0.1);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  min-width: 0;
  opacity: 0;
  transform: scale(0.85);
  transition:
    opacity .3s ease,
    transform .3s ease;
}

/* Auf den Rechtsseiten gibt es keinen Hero, aus dem das Logo „auftauchen“
   könnte – dort ist die Marke von Anfang an sichtbar. */
.site-header.is-static .brand {
  opacity: 1;
  transform: none;
}

.brand-logo {
  width: 46px;
  height: 46px;
  object-fit: contain;
  padding: 4px;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 8px 22px rgba(20, 32, 47, 0.08);
}

.brand strong,
.brand small {
  display: block;
}

.brand small {
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.1;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 1);
}

.site-nav a {
  border-radius: 999px;
  padding: 10px 14px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
  transition:
    color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--ink);
  background: var(--mint);
  transform: translateY(-1px);
}

.site-nav .nav-cta {
  color: var(--white);
  background: var(--ink);
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--white);
}

.nav-toggle span:not(.sr-only) {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: var(--ink);
}

.hero {
  position: relative;
  min-height: 400px;
  /* Kein max-height: zusammen mit overflow: hidden hat das bei schmalen
     Fenstern die Überschrift und den Button abgeschnitten, sobald die
     Unterzeile auf drei Zeilen umbrach. */
  display: flex;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
  overflow: hidden;
  padding: 96px clamp(20px, 6vw, 84px) 120px;
  background: linear-gradient(135deg, #eefbf4 -20%, #f9fbff 46%, #fff8f3 200%);
}

.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.78;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
}

.hero-logo-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

/* Untertitel zur h1 – trägt die Optik der früheren h3, ohne die
   Überschriftenebene h2 zu überspringen. */
.hero-tagline {
  margin-top: 15px;
  margin-bottom: 0;
  color: var(--ink);
  font-size: clamp(1.35rem, 2vw, 2rem);
  font-weight: 700;
  line-height: 1.16;
}

/* Höhe war an die Schriftgröße der h1 gekoppelt und damit nur so hoch wie die
   Versalhöhe von „BAKI“ – neben dem zwei- bis vierzeiligen Untertitel wirkte
   das Logo verloren. Jetzt an der Höhe des gesamten Textblocks orientiert. */
.hero-logo {
  height: clamp(72px, 12vw, 140px);
  width: auto;
  object-fit: contain;
  border-radius: var(--radius);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--teal-text);
  font-size: clamp(0.95rem, 1vw, 1.08rem);
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(2.55rem, 5.6vw, 3.6rem);
  line-height: 0.98;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 22px;
  font-size: clamp(1.5rem, 3.1vw, 2rem); /*statt 3.6rem*/
  line-height: 1.06;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 16px;
  font-size: clamp(1.35rem, 2vw, 2rem);
  line-height: 1.16;
  letter-spacing: 0;
}

p {
  color: var(--muted);
  font-size: clamp(1rem, 1.04vw, 1.1rem);
  line-height: 1.68;
}

/* Quellenverweise [1], [2, 3] im Fließtext */
.footnote-ref {
  text-decoration: none;
}

.hero-actions {
  display: flex;
  justify-content: center;
  margin-top: 3rem;
  width: 100%;
  gap: 12px;
}

.hero-actions .button {
  width: min(550px, 80%);
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 14px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-weight: 850;
  text-decoration: none;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(20, 32, 47, 0.14);
}

.button-primary {
  border-color: var(--ink);
  color: var(--white);
  background: var(--ink);
}

.button-secondary {
  background: rgba(255, 255, 255, 0.7);
}

.footer-divider {
  margin: auto 9%;   /* margin-top ersetzt das alte margin-top am hero-footer */
  border-top: 1px solid var(--line);
  margin-top: 32px;
}

.hero-footer {
  position: static;
  z-index: 3;
  margin: auto 9%;
  bottom: 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
  align-items: center;
  /*border-top: 1px solid var(--line);
  padding-top: 16px;*/
  margin-top: 32px;
}

.hero-footer a {
  display: grid;
  place-items: center;
  max-width: 470px;
  min-height: 62px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.72);
  transition:
    transform 180ms ease,
    box-shadow 180ms ease;
}

.hero-footer a:hover,
.hero-footer a:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(20, 32, 47, 0.12);
}

.hero-footer img {
  width: 100%;
  max-height: 48px;
  object-fit: contain;
}

.section,
.audience-section,
.contact-section {
  padding: clamp(62px, 2vw, 132px) clamp(20px, 6vw, 84px);
}

.section-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.92fr);
  gap: clamp(36px, 6vw, 76px);
  align-items: center;
}

/* --> text soll bis zur mitte gehen.
.section-copy {
  max-width: 780px;
}*/
.section-copy a,
.mission-section a {
  color: var(--darklinkgreen);
  font-weight: 800;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

mark {
  padding: 0.1em 0.28em;
  border-radius: 4px;
  color: var(--ink);
  background: linear-gradient(180deg, transparent 44%, rgba(185, 220, 97, 0.56) 44%);
}

.context-cards {
  display: grid;
  gap: 14px;
}

.context-cards article {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 10px 34px rgba(20, 32, 47, 0.07);
}

.context-cards h3 {
  font-size: 1rem;
  font-weight: 600;
}

.context-cards strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1.16rem;
  line-height: 1.25;
}

.context-cards p {
  margin-bottom: 0;
  font-size: 0.96rem;
  line-height: 1.55;
}

.section-heading {
  max-width: 880px;
  margin-bottom: 42px;
}

.module-tabs {
  display: inline-flex;
  gap: 6px;
  margin-bottom: 20px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
}

.audience-tabs {
  display: inline-flex;
  gap: 6px;
  margin-bottom: 20px;
  padding: 6px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.tab-button {
  min-width: 138px;
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  color: var(--muted);
  background: transparent;
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

.tab-button.is-active {
  color: var(--white);
  background: var(--ink);
}

/* Beide Reiter liegen übereinander in derselben Rasterzelle. Die Zelle wird
   damit so hoch wie der längere Inhalt – das hält die Panels gleich hoch,
   ohne die frühere feste min-height von 520px zu raten. */
.module-panels {
  display: grid;
}

.audience-panels {
  position: relative;
}

.audience-panels .button-primary,
.audience-panels .button-secondary {
  flex: 1 1 0px;
  font-size: 0.96rem;
}

.module-panel {
  /* Nicht display: none – der inaktive Reiter muss zur Höhe der Zelle
     beitragen. visibility: hidden nimmt ihn trotzdem aus Vorlese- und
     Tab-Reihenfolge. */
  grid-area: 1 / 1;
  visibility: hidden;
  display: grid;
  grid-template-columns: minmax(260px, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(26px, 5vw, 68px);
  align-items: center;
  padding: clamp(20px, 4vw, 42px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(223, 245, 235, 0.58)),
    var(--white);
  box-shadow: var(--shadow);
}

.module-panel.is-active {
  visibility: visible;
}

.video-section {
  background: #eef7f3;
}

.video-frame {
  overflow: hidden;
  max-width: 980px;
  margin-inline: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ink);
  box-shadow: var(--shadow);
}

.video-frame video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--ink);
}

.module-media {
  display: grid;
  place-items: center;
  min-height: 330px;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0); /* transparent */
}

.module-media img {
  width: min(300px, 72%);
  filter: drop-shadow(0 24px 24px rgba(20, 32, 47, 0.18));
  animation: float 5s ease-in-out infinite;
}

.module-kicker {
  margin-bottom: 10px;
  color: var(--teal-text);
  font-size: 1.1rem;
  font-weight: 900;
  text-transform: uppercase;
}

.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: clamp(28px, 5vw, 64px);
  padding: 0;
  list-style: none;
  position: relative;
}

/* Mittellinie */
.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, transparent, var(--teal) 8%, var(--teal) 92%);
  transform: translateX(-50%);
}

.timeline::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -10px;

  width: 12px;
  height: 12px;

  border-right: 2px solid var(--teal);
  border-bottom: 2px solid var(--teal);

  transform: translateX(-50%) rotate(45deg);
}

.timeline li {
  position: relative;
  width: 44%;
  padding: 10px;
  margin: -15px;
  border: 1px solid var(--line);
  border-color: rgba(0, 139, 139, 0.45);
  border-radius: var(--radius);
  background: var(--white);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

/* Ungerade: links */
.timeline li:nth-child(odd) {
  align-self: flex-start;
  margin-left: 0;
}

/* Gerade: rechts */
.timeline li:nth-child(even) {
  align-self: flex-end;
  margin-right: 0;
}

/* Pfeil-Connector zum Mittelpunkt (odd → rechts) */
.timeline li:nth-child(odd)::after {
  content: '';
  position: absolute;
  top: 50%;
  right: -13%;
  width: 13%;
  height: 2px;
  background: var(--teal);
  transform: translateY(-50%);
}

/* Pfeil-Connector zum Mittelpunkt (even → links) */
.timeline li:nth-child(even)::after {
  content: '';
  position: absolute;
  top: 50%;
  left: -13%;
  width: 13%;
  height: 2px;
  background: var(--teal);
  transform: translateY(-50%);
}

/* Kein Zahlen-Span mehr nötig – kann im HTML entfernt werden */
.timeline span {
  display: none;
}

.timeline strong {
  display: block;
  /* margin-bottom: 12px; -> weg, wenn p erst eingeblendet wird */
  font-size: 1.18rem;
}

/* Die Beschreibung wird beim Hereinscrollen eingeblendet – aber nur über
   opacity/transform, nicht über die Höhe. Eine Höhenanimation (früher
   max-height, dann grid-template-rows) hatte zwei Nachteile: sie wird nicht
   in allen Browsern zuverlässig interpoliert, und sie verändert die
   Seitenhöhe während des Scrollens, wodurch Ankersprünge daneben landen.
   Der Platz ist jetzt von Anfang an reserviert. */
.timeline-detail {
  opacity: 0;
  transform: translateY(-4px);
  transition:
    opacity 500ms ease 400ms,
    transform 500ms ease 400ms;
}

.timeline-detail > p {
  margin: 5px 0 0;
  font-size: 0.96rem;
  line-height: 1.55;
}

.timeline li.is-visible .timeline-detail {
  opacity: 1;
  transform: none;
}

.audience-section {
  color: var(--white);
  background:
    linear-gradient(120deg, rgba(20, 32, 47, 0.97), rgba(26, 106, 113, 0.92)),
    var(--ink);
}

.audience-section .section-heading p,
.audience-section .eyebrow,
.audience-panel p {
  color: rgba(255, 255, 255, 0.78);
}

.audience-section .tab-button,
.contact-section .tab-button {
  color: rgba(255, 255, 255, 0.74);
}

.audience-section .tab-button.is-active,
.contact-section .tab-button.is-active {
  color: var(--ink);
  background: var(--white);
}

.audience-panel {
  display: none;
  grid-template-columns: minmax(0, 0.95fr) minmax(300px, 1.05fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: start;
  padding: clamp(22px, 4vw, 42px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.18);
}

.audience-panel.is-active {
  display: grid;
}

.audience-panel .button-primary,
.contact-section .button-primary {
  border-color: var(--white);
  color: var(--ink);
  background: var(--white);
}

.audience-panel .button-secondary {
  border-color: rgba(255, 255, 255, 0.4);
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.benefit-list {
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.09);
}

.benefit-list h4 {
  margin-top: 0;
  margin-bottom: 16px;
  color: var(--mint);
}

.benefit-list ul {
  display: grid;
  gap: 13px;
  margin: 0;
  padding-left: 20px;
}

.benefit-list li {
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.55;
}

.accordion {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  box-shadow: 0 18px 50px rgba(20, 32, 47, 0.08);
}

.accordion button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 62px;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 18px 22px;
  color: var(--ink);
  background: var(--white);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

/* Rein dekoratives Zeichen – den Zustand sagt aria-expanded an. */
.accordion button::after {
  content: "+";
  font-size: 1.4rem;
  line-height: 1;
}

.accordion button[aria-expanded="true"]::after {
  content: "\2013";
}

/* grid-template-rows: 0fr → 1fr statt max-height, damit längere Antworten
   nicht an einer geratenen Maximalhöhe abgeschnitten werden. */
.accordion-panel {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  padding: 0 22px;
  transition:
    grid-template-rows .4s ease,
    opacity .4s ease,
    padding .4s ease;
}

.accordion-panel > * {
  overflow: hidden;
  min-height: 0;
  margin-bottom: 0;
}

.accordion button[aria-expanded="true"] + .accordion-panel {
  grid-template-rows: 1fr;
  opacity: 1;
  padding: 20px 22px;
}

/* Geschlossene Panels bekommen zusätzlich [inert] (siehe script.js): das nimmt
   sie aus Vorlese- und Tab-Reihenfolge, ohne – anders als [hidden] – die
   Aufklapp-Animation zu unterbinden. */
.accordion-panel[inert] {
  pointer-events: none;
}

.team-card a,
.contact-inner a {
  color: var(--darklinkgreen);
  font-weight: 850;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, 40%);
  gap: 18px;
  justify-content: center;
}

.team-card {
  display: flex;
  flex-direction: column; /* damit text nicht abgeschnitten wird.*/
  overflow: hidden;
  max-width: 470px; /*damit die Boxen nicht weiter als die neu skalierten bilder werden*/
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 16px 42px rgba(20, 32, 47, 0.08);
}

.team-card-link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.team-card img {
  /*width: 100%; orginal Skalierte bilder. hight ränder wurde abgeschnitten.
  height: 250px;*/
  height: min(100%, 250px);
  width: min(100%, 470px);
  object-fit: cover;
}

.team-card div {
  padding: 28px;
}

.partner-section {
  background: #ffffff;
}

.partner-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: center;
}

.partner-grid img {
  width: 100%;
  height: 124px;
  object-fit: contain;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 10px 30px rgba(20, 32, 47, 0.06);
}

.partner-grid .partner-feature {
  grid-column: 1 / -1;
  height: 150px;
}

.partner-feature img {
  height: 100%;
}

.contact-section {
  color: var(--white);
  background:
    linear-gradient(120deg, rgba(20, 32, 47, 0.97), rgba(26, 106, 113, 0.92)),
    var(--ink);
}

/* button wirklich in der mitte zentrieren, nicht nur die box.
.contact-inner {
  max-width: 920px;
}*/
.contact-section .eyebrow,
.contact-section p {
  color: rgba(255, 255, 255, 0.78);
}

.team-lead {
  display: block;
  margin-bottom: 10px;
  color: var(--ink);
  font-weight: 850;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 15px clamp(20px, 6vw, 44px);
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer p,
.site-footer ol {
  margin: 0;
  /* 0.72rem entsprach ~11,5 px und lag damit unter der Lesbarkeitsgrenze. */
  font-size: 0.8rem;
  line-height: 1.6;
}

.footer-links {
  min-width: 168px;
}

.footer-credits {
  max-width: 44ch;
}

.site-footer div {
  display: flex;
  gap: 16px;
}

.site-footer a {
  color: var(--muted);
  font-weight: 800;
}

/* Einheitlicher Fokusindikator. Der doppelte Ring (dunkel auf hell) bleibt
   auf dem hellen Papier wie auf den dunklen Sektionen sichtbar. */
:where(a, button, [tabindex]:not([tabindex="-1"]), video, summary):focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  box-shadow: 0 0 0 6px var(--white);
}

.audience-section :focus-visible:not([tabindex="-1"]),
.contact-section :focus-visible:not([tabindex="-1"]) {
  outline-color: var(--white);
  box-shadow: 0 0 0 6px var(--ink);
}

/* Ankersprünge setzen tabindex="-1" auf den Zielabschnitt und fokussieren ihn,
   damit Tastaturnutzende dort weitertabben statt wieder am Seitenanfang.
   Sichtbar sein muss dieser Fokus nicht: solche Elemente sind nicht antabbbar,
   also keine per Tastatur bedienbaren Bedienelemente – ein Rahmen um den
   halben Abschnitt wäre nur störend. Gleiche Praxis wie bei Sprungmarken.

   Bewusst nur outline und kein `box-shadow: none`: der Ring aus box-shadow
   kommt ausschliesslich aus den beiden Regeln darüber, und die schliessen
   tabindex="-1" bereits aus. Ein pauschales box-shadow: none würde dagegen
   echte Schatten mitreissen – die fokussierte Kopfzeile verlöre ihren
   Schlagschatten, solange der Fokus auf ihr liegt. */
[tabindex="-1"]:focus,
[tabindex="-1"]:focus-visible {
  outline: none;
}

/* Schwebender „Zum Seitenanfang“-Knopf. Nur auf schmalen Bildschirmen, wo der
   Weg zurück nach oben lang ist – auf dem Desktop steht die Kopfzeile ohnehin
   dauerhaft zur Verfügung. [hidden] wird per JS gesetzt (siehe script.js). */
.to-top {
  display: none;
  position: fixed;
  z-index: 90;
  right: 16px;
  /* env(): über der Gestenleiste von iPhones ohne Home-Button. */
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  width: 48px;
  height: 48px;
  padding: 0;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--white);
  background: var(--ink);
  box-shadow: 0 10px 28px rgba(20, 32, 47, 0.28);
  cursor: pointer;
  opacity: 0;
  transform: translateY(8px) scale(0.9);
  transition:
    opacity 200ms ease,
    transform 200ms ease;
}

.to-top svg {
  width: 22px;
  height: 22px;
}

.to-top.is-shown {
  opacity: 1;
  transform: none;
}

.to-top[hidden] {
  display: none;
}

@media (max-width: 720px) {
  .to-top:not([hidden]) {
    display: grid;
  }

  /* Wenn das Menü offen ist, würde der Knopf darüber schweben. */
  body.nav-open .to-top {
    opacity: 0;
    pointer-events: none;
  }
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 600ms ease,
    transform 600ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---###--- Zusätzliche Seiten: Impressum & Datenschutz ---###--- */

ul li {
  margin-bottom: 1rem;
}

/* Platz für die fixierte Kopfzeile, die hier direkt über dem Inhalt sitzt.
   Doppelter Klassenselektor mit Absicht: die Regel muss die spätere
   `.section { padding: 40px 18px }` aus der 720px-Media-Query schlagen,
   sonst rutscht „Rechtliche Informationen“ unter die Kopfzeile. */
.section.legal-page {
  padding-top: clamp(104px, 12vw, 140px);
}

/* Ohne diese Begrenzung laufen die Rechtstexte auf breiten Bildschirmen über
   die volle Fensterbreite – teils über 200 Zeichen pro Zeile. */
.legal-container {
  max-width: 72ch;
  margin-inline: auto;
}

.legal-container h2 {
  margin-top: 2.5rem;
  font-size: clamp(1.35rem, 2.4vw, 1.6rem);
}

.legal-container h3 {
  margin-top: 1.75rem;
  font-size: clamp(1.1rem, 1.8vw, 1.25rem);
}

.legal-container a:not(.button) {
  color: var(--darklinkgreen);
  font-weight: 700;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.back-button {
  display: inline-flex;
  gap: 0.5em;
  align-items: center;
  margin-top: 2.5rem;
  margin-bottom: 2.5rem;
  font-size: 0.92rem;
}

.back-button svg {
  width: 1em;
  height: 1em;
  flex: none;
}

@keyframes float {
  50% {
    transform: translateY(-14px);
  }
}

@media (min-width: 1330px) {
  .footer-divider {
  margin: auto 0;
  margin-top: 32px;
  }

  .hero-footer {
    margin: auto 0%;
    margin-top: 32px;
  }

  .hero-footer a {
    max-width: 100%;
  }

  .team-grid {
    /*grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));*/
    grid-template-columns: 1fr;
  }

  .team-card {
    display: grid;
    /*grid-template-columns: clamp(220px, 50%, 470px) 1fr;*/
    grid-template-columns: 470px 1fr;
    align-items: start;
    max-width: 100%;
    max-height: fit-content;
  }

  .team-card img {
    height: 100%;
    object-fit: cover;
    border-radius: var(--radius) 0 0 var(--radius);
  }
}

@media (max-width: 1020px) {
  .site-nav {
    position: fixed;
    top: 74px;
    left: 18px;
    right: 18px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 14px 16px;
  }

  .nav-toggle {
    display: block;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding-top: 98px;
    padding-bottom: 60px;
  }

  .section-grid,
  .module-panel,
  .audience-panel {
    grid-template-columns: 1fr;
  }

  /* Einspaltig lohnt die Gleichhöhe der beiden Reiter nicht: der kürzere
     bekäme rund 160px Leerraum angehängt. Hier wieder einzeln nach Inhalt,
     der Höhensprung beim Umschalten fällt in einer Spalte kaum auf. */
  .module-panels {
    display: block;
  }

  .module-panel {
    grid-area: auto;
    display: none;
  }

  .module-panel.is-active {
    display: grid;
  }

  .timeline li {
    min-height: 0;
  }
}

@media (max-width: 720px) {
  /* Einspaltige Timeline als linke Schiene. Vorher blieben die Karten auch
     auf dem Handy bei width: 44% (~165px) – der beabsichtigte Umbruch stand
     zwar in der 1020px-Query, griff aber nie, weil dort
     `grid-template-columns` auf einem `display: flex`-Element gesetzt wurde. */
  .timeline::before,
  .timeline::after {
    left: 9px;
  }

  .timeline li,
  .timeline li:nth-child(odd),
  .timeline li:nth-child(even) {
    align-self: stretch;
    width: auto;
    margin: 0 0 14px 34px;
    padding: 12px 14px;
  }

  .timeline li:last-child {
    margin-bottom: 0;
  }

  /* Verbinder zeigt jetzt immer nach links zur Schiene. */
  .timeline li:nth-child(odd)::after,
  .timeline li:nth-child(even)::after {
    left: -25px;
    right: auto;
    width: 25px;
  }

  .footer-divider {
    max-width: 470px;
    margin: auto 0;
    margin-top: 24px;
  }

  .section {
    padding: 40px 18px;
  }

  .site-header {
    padding: 12px 16px;
  }

  .hero {
    min-height: 0;
    padding: 86px 18px 60px;
  }

  
  /* auto statt fester 76px – sonst deckelt die Spalte das größere Logo. */
  .hero-logo-row {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 14px;
  }

  h1 {
    font-size: clamp(2.15rem, 11vw, 3.35rem);
  }

  .legal-container h1 {
    font-size: clamp(2.55rem, 5.6vw, 3.6rem);
    overflow-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
  }

  .hero-footer {
    grid-template-columns: 1fr;
    gap: 10px;
    margin: auto 0;
    margin-top: 24px;
    /*border-top: none;*/
  }

  .team-grid,
.partner-grid {
    grid-template-columns: 1fr;
  }

  .partner-grid .partner-feature {
    grid-column: auto;
    height: 150px;
  }

  .module-tabs,
.audience-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
  }

  .tab-button {
    min-width: 0;
  }

  .module-media {
    min-height: 230px;
  }

  .section,
.audience-section,
.contact-section {
    padding-inline: 18px;
  }

  .site-footer {
    flex-direction: column;
    padding-inline: 18px;
  }
}

@media (max-width: 320px) {
  .hero-logo {
    height: 56px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  /* Wie bei .reveal: Inhalt sofort und unabhängig vom Scroll-Trigger zeigen,
     statt ihn über eine (hier abgeschaltete) Animation einzublenden. */
  .timeline-detail {
    opacity: 1;
    transform: none;
  }
}
