/* =========================================================================
   FGV Musikschule Speichersdorf – Stylesheet
   Design: "Musik aus dem Fichtelgebirge"
   Modern & klar, aber gut lesbar fuer aeltere Vereinsmitglieder:
   - grosse Basisschrift (18px), hohe Kontraste (WCAG AA+)
   - Waldgruen/Naturtoene des Fichtelgebirges, warmes Gold als Akzent
   - grosse Klickflaechen, ruhige Layouts
   ========================================================================= */

/* ---------- Design-Tokens ---------- */
:root {
  /* Farbwelt Fichtelgebirge */
  --c-primary: #1f5233;        /* Waldgruen */
  --c-primary-600: #2c6e45;    /* helleres Tannengruen */
  --c-primary-700: #163d26;    /* dunkler Wald */
  --c-accent: #c88a2d;         /* warmes Gold/Bernstein (Blechblas!) */
  --c-accent-soft: #e8aa4a;
  --c-ink: #1c2420;            /* fast schwarz, gruenstichig */
  --c-muted: #4e5d55;          /* dunkel genug fuer gute Lesbarkeit */
  --c-line: #dde5df;
  --c-bg: #ffffff;
  --c-bg-soft: #f3f7f4;        /* helles Naturgruen-Weiss */
  --c-bg-deep: #122b1b;        /* Nachtwald (dunkle Sektion) */
  --c-danger: #a23b32;

  /* Typografie: gross & klar */
  --font-head: "Avenir Next", "Segoe UI", Frutiger, Corbel, Verdana, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --fs-base: 1.125rem;         /* 18px – bewusst gross */

  /* Layout */
  --maxw: 1160px;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 3px rgba(22, 61, 38, .08), 0 3px 10px rgba(22, 61, 38, .06);
  --shadow-md: 0 10px 30px rgba(22, 61, 38, .14);
  --space: clamp(3.2rem, 7vw, 6rem);
  --header-h: 76px;
}

/* ---------- Reset / Basis ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--c-ink);
  background: var(--c-bg);
  line-height: 1.7;
  font-size: var(--fs-base);
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; display: block; }

a { color: var(--c-primary-600); text-underline-offset: 3px; }
a:hover { color: var(--c-primary); }

h1, h2, h3 { font-family: var(--font-head); line-height: 1.18; color: var(--c-primary-700); font-weight: 700; }
h2 { font-size: clamp(1.85rem, 1.3rem + 2vw, 2.7rem); }
h3 { font-size: 1.3rem; }

ul { padding-left: 1.1rem; }

:focus-visible {
  outline: 3px solid var(--c-accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 12px; top: -60px;
  background: var(--c-primary);
  color: #fff;
  padding: 12px 18px;
  border-radius: 8px;
  z-index: 1000;
  transition: top .15s ease;
}
.skip-link:focus { top: 12px; color: #fff; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

/* ---------- Layout-Helfer ---------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1rem, 4vw, 2rem);
}

.section { padding-block: var(--space); }
.section--soft { background: var(--c-bg-soft); }
.section--deep { background: var(--c-bg-deep); color: #d9e6dd; }
.section--deep h2, .section--deep h3 { color: #fff; }

.section__head { max-width: 62ch; margin-bottom: clamp(1.8rem, 3vw, 2.8rem); }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-size: .85rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--c-primary-600);
  margin-bottom: .6rem;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 3px;
  border-radius: 2px;
  background: var(--c-accent);
}
.lead { color: var(--c-muted); font-size: 1.12em; }
.section--deep .lead { color: #b9cfc0; }
.section--deep .eyebrow { color: var(--c-accent-soft); }

/* ---------- Buttons: gross, eindeutig ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  font: inherit;
  font-weight: 700;
  line-height: 1;
  padding: 1rem 1.7rem;
  min-height: 52px;               /* grosse Touch-/Klickflaeche */
  border-radius: 12px;
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform .12s ease, background-color .15s ease, color .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--c-accent); color: #241503; }
.btn--primary:hover { background: var(--c-accent-soft); color: #241503; box-shadow: var(--shadow-md); }
.btn--ghost { background: #fff; color: var(--c-primary); border-color: var(--c-line); }
.btn--ghost:hover { border-color: var(--c-primary); background: var(--c-bg-soft); }
.btn--on-dark { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.4); }
.btn--on-dark:hover { background: rgba(255,255,255,.22); color: #fff; }

/* ---------- Header / Navigation ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .95);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--c-line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
}
.nav__brand { display: inline-flex; align-items: center; }
.nav__brand img { height: 46px; width: auto; }
.nav__list {
  display: flex;
  align-items: center;
  gap: .2rem;
  list-style: none;
  margin: 0; padding: 0;
}
.nav__list a {
  display: inline-block;
  padding: .65rem .85rem;
  border-radius: 10px;
  color: var(--c-ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
}
.nav__list a:hover { background: var(--c-bg-soft); color: var(--c-primary); }
.nav__list .btn { color: #241503; padding: .7rem 1.2rem; min-height: 44px; }
.nav__list .btn:hover { color: #241503; }

.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 50px; height: 50px;
  padding: 0;
  background: transparent;
  border: 2px solid var(--c-line);
  border-radius: 12px;
  cursor: pointer;
}
.nav__toggle span {
  display: block;
  width: 24px; height: 3px;
  border-radius: 2px;
  margin-inline: auto;
  background: var(--c-ink);
  transition: transform .2s ease, opacity .2s ease;
}
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

@media (max-width: 920px) {
  .nav__toggle { display: flex; }
  .nav__list {
    position: absolute;
    left: 0; right: 0;
    top: var(--header-h);
    flex-direction: column;
    align-items: stretch;
    gap: .15rem;
    background: #fff;
    border-bottom: 1px solid var(--c-line);
    box-shadow: var(--shadow-md);
    padding: .8rem clamp(1rem, 4vw, 2rem) 1.3rem;
    display: none;
  }
  .nav__list.is-open { display: flex; }
  .nav__list a { padding: .95rem .7rem; font-size: 1.12rem; }
  .nav__list .btn { justify-content: center; margin-top: .4rem; }
}

/* ---------- Hero: Fichtelgebirge ---------- */
.hero {
  position: relative;
  background:
    linear-gradient(180deg, rgba(18, 43, 27, .88) 0%, rgba(31, 82, 51, .82) 60%, rgba(22, 61, 38, .94) 100%),
    var(--c-primary-700);
  color: #eef5ef;
  overflow: hidden;
}
/* Bergsilhouette unten im Hero */
.hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 110px;
  background: url("../assets/img/berge.svg") bottom center / cover no-repeat;
  pointer-events: none;
}
.hero__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
  padding-block: clamp(3.5rem, 8vw, 7rem) clamp(5rem, 10vw, 8.5rem);
}
.hero h1 {
  color: #fff;
  font-size: clamp(2.2rem, 1.4rem + 3.6vw, 3.9rem);
  margin-bottom: 1.1rem;
  letter-spacing: -.01em;
}
.hero h1 em { font-style: normal; color: var(--c-accent-soft); }
.hero p { color: #d5e4d8; font-size: 1.16em; max-width: 50ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 2rem; }
.hero__media {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(255,255,255,.18);
}
.hero__media img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 3 / 2; }
.hero__badges { display: flex; flex-wrap: wrap; gap: 1.6rem; margin-top: 2rem; }
.hero__badge { display: flex; flex-direction: column; }
.hero__badge b { font-family: var(--font-head); font-size: 1.7rem; color: var(--c-accent-soft); }
.hero__badge span { font-size: .92em; color: #b9cfc0; }

@media (max-width: 860px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__media { order: -1; }
}

/* FGV-Wurzeln-Band unter dem Hero */
.roots {
  background: var(--c-bg-soft);
  border-bottom: 1px solid var(--c-line);
  padding-block: 1.1rem;
}
.roots .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: .6rem 2.2rem;
  text-align: center;
  font-size: .98em;
  color: var(--c-muted);
}
.roots b { color: var(--c-primary-700); }
.roots .ic { font-size: 1.25em; margin-right: .35rem; }

/* ---------- Feature-Karten (Ueber uns) ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.3rem;
  margin-top: 2rem;
}
.feature {
  background: #fff;
  border: 1px solid var(--c-line);
  border-top: 4px solid var(--c-primary-600);
  border-radius: var(--radius);
  padding: 1.6rem 1.5rem;
  box-shadow: var(--shadow-sm);
}
.feature .ic {
  display: grid; place-items: center;
  width: 54px; height: 54px;
  border-radius: 14px;
  background: var(--c-bg-soft);
  font-size: 1.7rem;
  line-height: 1;
}
.feature h3 { margin: .9rem 0 .4rem; }
.feature p { color: var(--c-muted); font-size: .98em; }

/* ---------- Faecher-Grid ---------- */
.subjects {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 1rem;
}
.subject {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: #fff;
  border: 1px solid var(--c-line);
  border-radius: var(--radius-sm);
  padding: 1.35rem 1rem 1.2rem;
  box-shadow: var(--shadow-sm);
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
  min-height: 11.5rem;
}
.subject:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--c-primary-600); }
.subject .ic {
  flex: none;
  display: grid; place-items: center;
  width: 54px; height: 54px;
  border-radius: 50%;
  background: var(--c-bg-soft);
  font-size: 1.55rem;
  margin-bottom: .85rem;
}
.subject__text {
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .2rem;
  flex: 1;
}
.subject b {
  display: block;
  font-size: 1em;
  line-height: 1.3;
  color: var(--c-primary-700);
  /* Einheitliche Hoehe fuer 1–2 Zeilen */
  min-height: 2.6em;
  overflow-wrap: anywhere;
  hyphens: auto;
}
.subject small {
  display: block;
  color: var(--c-muted);
  font-size: .84em;
  line-height: 1.35;
}
.subject--paused { opacity: .72; border-style: dashed; background: var(--c-bg-soft); }
.subject--paused .subject__hint {
  display: block;
  color: var(--c-danger);
  font-weight: 700;
  margin-top: .25rem;
  font-size: .78em;
  line-height: 1.3;
}

/* ---------- Lehrer-Karten ---------- */
.teachers {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.3rem;
}
.teacher {
  background: #fff;
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
}
.teacher__head { display: flex; gap: 1rem; align-items: flex-start; margin-bottom: .9rem; }
.teacher__head .avatar {
  flex: none;
  width: 56px; height: 56px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--c-primary);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.15rem;
}
.teacher__head h3 { margin-bottom: .4rem; font-size: 1.2rem; }
.teacher__bio { color: var(--c-muted); font-size: .96em; }
.teacher__hint { margin-top: .6rem; font-size: .9em; color: var(--c-danger); font-style: italic; }
.tags { display: flex; flex-wrap: wrap; gap: .4rem; }
.tag {
  display: inline-block;
  font-size: .78em;
  font-weight: 700;
  padding: .25rem .65rem;
  border-radius: 999px;
  background: var(--c-bg-soft);
  color: var(--c-primary);
  border: 1px solid var(--c-line);
}

/* ---------- Termine ---------- */
.events { display: grid; gap: 1rem; }

/* hidden-Attribut darf nicht von display:grid ueberschrieben werden */
[hidden] { display: none !important; }

/* Termine: nur ein Zustand gleichzeitig sichtbar */
#termine-app[data-state="consent"] [data-role="loading"],
#termine-app[data-state="consent"] [data-role="upcoming"],
#termine-app[data-state="consent"] [data-role="past-wrap"],
#termine-app[data-state="consent"] [data-role="empty"],
#termine-app[data-state="consent"] [data-role="error"] {
  display: none !important;
}
#termine-app[data-state="loading"] [data-role="consent"],
#termine-app[data-state="loading"] [data-role="upcoming"],
#termine-app[data-state="loading"] [data-role="past-wrap"],
#termine-app[data-state="loading"] [data-role="empty"],
#termine-app[data-state="loading"] [data-role="error"] {
  display: none !important;
}
#termine-app[data-state="ready"] [data-role="consent"],
#termine-app[data-state="ready"] [data-role="loading"],
#termine-app[data-state="ready"] [data-role="empty"],
#termine-app[data-state="ready"] [data-role="error"],
#termine-app[data-state="error"] [data-role="consent"],
#termine-app[data-state="error"] [data-role="loading"],
#termine-app[data-state="error"] [data-role="upcoming"],
#termine-app[data-state="error"] [data-role="past-wrap"],
#termine-app[data-state="error"] [data-role="empty"] {
  display: none !important;
}

.termine__consent {
  border: 2px dashed var(--c-line);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
  text-align: center;
  background: #fff;
  max-width: 36rem;
  margin: 0 auto;
}
.termine__consent p {
  color: var(--c-muted);
  margin-bottom: 1.1rem;
  line-height: 1.55;
}
.termine__consent .consent__privacy {
  margin-top: .85rem;
  margin-bottom: 0;
  font-size: .82em;
}
.termine__consent .consent__privacy a {
  color: var(--c-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.event {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1.3rem;
  align-items: start;
  background: #fff;
  border: 1px solid var(--c-line);
  border-left: 5px solid var(--c-primary-600);
  border-radius: var(--radius-sm);
  padding: 1.2rem 1.4rem;
  box-shadow: var(--shadow-sm);
}
.event--next { border-left-color: var(--c-accent); background: #fffcf4; }
.event__date { font-family: var(--font-head); }
.event__date .d { font-size: 1.2em; font-weight: 800; color: var(--c-primary-700); }
.event__date .t { display: block; color: var(--c-muted); font-size: .92em; }
.event__body h3 { font-size: 1.2rem; margin-bottom: .2rem; }
.event__meta { color: var(--c-muted); font-size: .96em; }
.badge {
  display: inline-block;
  font-size: .74em;
  font-weight: 800;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: #4a3103;
  background: var(--c-accent-soft);
  padding: .25rem .6rem;
  border-radius: 999px;
  margin-bottom: .45rem;
}
@media (max-width: 600px) {
  .event { grid-template-columns: 1fr; gap: .45rem; }
}

.state {
  border: 2px dashed var(--c-line);
  border-radius: var(--radius-sm);
  padding: 1.5rem;
  color: var(--c-muted);
  background: #fff;
}
.state--error { border-color: #ecc8c4; background: #fdf4f3; color: #7c241f; }

.skeleton {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1.3rem;
  background: #fff;
  border: 1px solid var(--c-line);
  border-radius: var(--radius-sm);
  padding: 1.2rem 1.4rem;
}
.skeleton .ln {
  height: 15px;
  border-radius: 7px;
  background: linear-gradient(90deg, #edf3ee 25%, #dde5df 37%, #edf3ee 63%);
  background-size: 400% 100%;
  animation: shimmer 1.3s ease infinite;
  margin: 6px 0;
}
.skeleton .ln.w60 { width: 60%; }
.skeleton .ln.w40 { width: 40%; }
@keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

details.past { margin-top: 1.5rem; }
details.past > summary {
  cursor: pointer;
  font-weight: 700;
  font-size: 1.05em;
  color: var(--c-primary);
  padding: .7rem 0;
  list-style: none;
}
details.past > summary::-webkit-details-marker { display: none; }
details.past > summary::before { content: "\25B8  "; }
details.past[open] > summary::before { content: "\25BE  "; }
details.past .events { margin-top: .9rem; }
details.past .event { border-left-color: var(--c-line); opacity: .85; }

/* ---------- Anmeldung: Schritte + Downloads ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.3rem;
  counter-reset: step;
  margin-bottom: 2.2rem;
}
.step {
  background: #fff;
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  padding: 1.7rem 1.5rem 1.4rem;
  box-shadow: var(--shadow-sm);
}
.step::before {
  counter-increment: step;
  content: counter(step);
  display: grid; place-items: center;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: var(--c-primary);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.25rem;
  margin-bottom: .9rem;
}
.step h3 { margin-bottom: .35rem; }
.step p { color: var(--c-muted); font-size: .98em; }

.downloads {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
}
.dl {
  display: flex;
  align-items: center;
  gap: .95rem;
  background: #fff;
  border: 2px solid var(--c-line);
  border-radius: var(--radius-sm);
  padding: 1.15rem 1.25rem;
  text-decoration: none;
  color: var(--c-ink);
  transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.dl:hover { border-color: var(--c-primary); transform: translateY(-2px); box-shadow: var(--shadow-sm); color: var(--c-ink); }
.dl .ic { font-size: 1.6rem; }
.dl b { display: block; }
.dl small { color: var(--c-muted); }

/* ---------- Ansprechpartner ---------- */
.people {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.3rem;
}
.person {
  background: #fff;
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  padding: 1.7rem;
  box-shadow: var(--shadow-sm);
}
.person .avatar {
  width: 60px; height: 60px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--c-primary);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.35rem;
  margin-bottom: 1rem;
}
.person h3 { margin-bottom: .2rem; }
.person .role { color: var(--c-accent); font-weight: 700; font-size: .95em; margin-bottom: .7rem; }
.person a { font-size: 1.05em; }

/* ---------- Kontakt ---------- */
.contact {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
}
.contact__list { list-style: none; padding: 0; display: grid; gap: 1.15rem; }
.contact__list li { display: flex; gap: 1rem; align-items: flex-start; }
.contact__list .ic {
  flex: none;
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  font-size: 1.3rem;
}
.contact__list a { color: #fff; }
.contact__list .label { display: block; font-size: .82em; color: #9dbba6; letter-spacing: .06em; text-transform: uppercase; font-weight: 700; }
.contact__list .value { font-size: 1.1em; }

.map {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.06);
  min-height: 300px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 1.6rem;
}
.map iframe { width: 100%; height: 100%; min-height: 340px; border: 0; display: block; }
.map__consent p { color: #d5e4d8; margin-bottom: 1.1rem; max-width: 42ch; }
.map__consent .consent__privacy {
  margin-top: .85rem;
  margin-bottom: 0;
  font-size: .82em;
  max-width: none;
}
.map__consent .consent__privacy a {
  color: #9dbba6;
  text-decoration: underline;
  text-underline-offset: 2px;
}

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

/* ---------- Chronik-Teaser ---------- */
.chronik-teaser {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.1rem;
  background: var(--c-bg-soft);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  padding: 1.5rem 1.7rem;
  margin-top: 2.2rem;
}
.chronik-teaser p { color: var(--c-muted); max-width: 54ch; margin: 0; }

/* ---------- Chronik-Timeline ---------- */
.timeline {
  position: relative;
  --tl-line: 0.625rem;   /* Position der vertikalen Linie */
  --tl-year: 4.75rem;    /* Breite der Jahres-Spalte */
  padding-left: 1.5rem;  /* Platz fuer Linie + Marker */
}

/* Vertikale Linie links */
.timeline::before {
  content: "";
  position: absolute;
  left: var(--tl-line);
  top: 0;
  bottom: 0;
  width: 3px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--c-line);
}

.timeline__item {
  display: grid;
  grid-template-columns: var(--tl-year) minmax(0, 1fr);
  gap: 0 1.25rem;
  align-items: start;
  margin-bottom: 1.4rem;
  position: relative;
}

.timeline__item:last-child { margin-bottom: 0; }

.timeline__year {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--c-accent);
  text-align: right;
  padding-right: .25rem;
  padding-top: .9rem;
  line-height: 1.2;
  white-space: nowrap;
}

.timeline__marker {
  position: absolute;
  left: calc(-1.5rem + var(--tl-line));
  top: 1rem;
  width: 14px;
  height: 14px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: var(--c-primary);
  border: 3px solid #fff;
  box-shadow: 0 0 0 2px var(--c-primary);
  z-index: 1;
}

.timeline__body {
  min-width: 0; /* wichtig: verhindert Schrumpfen der Text-Spalte */
  background: #fff;
  border: 1px solid var(--c-line);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.3rem;
  box-shadow: var(--shadow-sm);
}

.timeline__body p {
  color: var(--c-muted);
  margin: 0;
  overflow-wrap: break-word;
  word-break: normal;
}

@media (max-width: 640px) {
  .timeline {
    --tl-year: 3.75rem;
    padding-left: 1.25rem;
  }
  .timeline__item { gap: 0 .9rem; }
  .timeline__year { font-size: 1rem; padding-top: .85rem; }
  .timeline__marker { width: 12px; height: 12px; border-width: 2px; top: .9rem; }
  .timeline__body { padding: 1rem 1.1rem; }
}

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  background: var(--c-bg-deep);
  color: #a8c2b0;
  padding-block: 3rem 1.8rem;
}
/* Bergsilhouette oben am Footer */
.site-footer::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: -58px;
  height: 60px;
  background: url("../assets/img/berge-footer.svg") bottom center / cover no-repeat;
  pointer-events: none;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}
.site-footer a { color: #cfe2d4; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer h4 { color: #fff; font-size: .88em; letter-spacing: .12em; text-transform: uppercase; margin-bottom: .9rem; }
.footer__nav { list-style: none; padding: 0; display: grid; gap: .55rem; }
.footer__brand img { height: 48px; filter: brightness(0) invert(1); opacity: .92; margin-bottom: .9rem; }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,.14);
  padding-top: 1.3rem;
  display: flex;
  flex-wrap: wrap;
  gap: .6rem 1.5rem;
  justify-content: space-between;
  font-size: .92em;
}

/* ---------- Rechts-/Unterseiten ---------- */
.legal { padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.legal .container { max-width: 860px; }
.legal h1 { font-size: clamp(1.9rem, 1.3rem + 2.2vw, 2.7rem); margin-bottom: 1.5rem; color: var(--c-primary-700); }
.legal h2 { font-size: 1.4rem; margin-top: 2.1rem; margin-bottom: .6rem; }
.legal p, .legal li { color: #35443b; }
.legal address { font-style: normal; }
.back-link { display: inline-block; margin-bottom: 1.5rem; font-weight: 700; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .features, .steps, .downloads { grid-template-columns: 1fr; }
  .people { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; gap: 1.5rem; }
}

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