/* ═══════════════════════════════════════════════════════════════
   FF Haderswörth — Stylesheet
   Abschnittsweise Navigation, dazwischen bricht Feuer aus.
   ═══════════════════════════════════════════════════════════════ */

/* ---------- Design Tokens ---------- */
:root {
  --red:     #d31423;
  --red-600: #b0121f;
  --red-300: #ff5b4d;
  --amber:   #ffb020;
  --water:   #8ccdff;

  --bg:      #ffffff;
  --bg-soft: #f5f6f9;
  --ink:     #10141c;
  --ink-2:   #3d465a;
  --ink-3:   #6b7590;
  --line:    #dfe3ec;
  --card:    #ffffff;
  --shadow:    0 1px 2px rgba(16,20,28,.05), 0 14px 34px -14px rgba(16,20,28,.2);
  --shadow-lg: 0 2px 4px rgba(16,20,28,.06), 0 34px 68px -26px rgba(16,20,28,.3);

  --night:   #0b0e15;

  --r-sm: 10px;
  --r:    16px;
  --r-lg: 24px;
  --r-xl: 32px;

  --wrap: 1140px;
  --pad: clamp(18px, 4.5vw, 40px);
  --top-h: 74px;

  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Barlow Condensed", "Inter", system-ui, sans-serif;
  --ease: cubic-bezier(.22,.68,.36,1);
}

html[data-theme="dark"] {
  --bg:      #0b0e15;
  --bg-soft: #10161f;
  --ink:     #eef1f8;
  --ink-2:   #b9c2d6;
  --ink-3:   #8892ab;
  --line:    rgba(255,255,255,.11);
  --card:    #151c2a;
  --shadow:    0 1px 2px rgba(0,0,0,.5), 0 18px 42px -18px rgba(0,0,0,.75);
  --shadow-lg: 0 2px 6px rgba(0,0,0,.5), 0 44px 84px -34px rgba(0,0,0,.9);
}

/* ---------- Basis ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.08; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; }
li { list-style: none; }
button { font: inherit; }
figure { margin: 0; }

:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; border-radius: 4px; }

.skiplink {
  position: fixed; top: -100px; left: 16px; z-index: 300;
  background: var(--red); color: #fff; padding: 12px 20px;
  border-radius: 0 0 var(--r-sm) var(--r-sm); font-weight: 600; text-decoration: none;
}
.skiplink:focus { top: 0; }

.srlive {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 22px; border: 1px solid transparent; border-radius: 999px;
  background: var(--red); color: #fff;
  font-weight: 600; font-size: .95rem; text-decoration: none;
  cursor: pointer; white-space: nowrap;
  transition: transform .18s var(--ease), box-shadow .25s var(--ease), background .2s, border-color .2s, color .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn--lg { padding: 14px 28px; font-size: 1rem; }
.btn--block { width: 100%; }
.btn--primary {
  background: linear-gradient(180deg, var(--red-300), var(--red));
  box-shadow: 0 4px 14px -4px rgba(211,20,35,.6);
}
.btn--primary:hover { box-shadow: 0 12px 28px -8px rgba(211,20,35,.75); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--red); color: var(--red); }
.btn--alarm { position: relative; padding-left: 34px; box-shadow: 0 4px 14px -4px rgba(211,20,35,.55); }

.pulse {
  position: absolute; left: 16px; top: 50%; translate: 0 -50%;
  width: 8px; height: 8px; border-radius: 50%; background: #fff;
}
.pulse::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.85); animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { transform: scale(.6); opacity: 1; }
  70%, 100% { transform: scale(1.9); opacity: 0; }
}

/* ---------- Kopfzeile ---------- */
.top {
  position: fixed; inset: 0 0 auto 0; z-index: 120;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid var(--line);
}
.top__inner {
  display: flex; align-items: center; gap: 18px;
  width: min(100% - 2 * var(--pad), 1400px); margin-inline: auto;
  min-height: var(--top-h);
}
.top__progress { height: 2px; background: var(--line); }
.top__progress span {
  display: block; height: 100%; width: 11%;
  background: linear-gradient(90deg, var(--amber), var(--red));
  transition: width .5s var(--ease);
}

.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; margin-right: auto; }
/* Das Wappen ist hochkant — Höhe vorgeben, Breite folgt dem Seitenverhältnis */
.brand__mark { height: 42px; width: auto; filter: drop-shadow(0 3px 8px rgba(0,0,0,.35)); }
.brand__txt { display: grid; line-height: 1.14; }
.brand__name { font-family: var(--display); font-weight: 700; font-size: 1.38rem; text-transform: uppercase; }
.brand__sub { font-size: .68rem; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-3); font-weight: 600; }

.topnav { display: flex; gap: 4px; }
.topnav a {
  padding: 8px 13px; border-radius: 999px; text-decoration: none;
  font-weight: 500; font-size: .93rem; color: var(--ink-2);
  transition: color .2s, background .2s;
}
.topnav a:hover { color: var(--ink); background: var(--bg-soft); }
.topnav a.is-active { color: var(--red); background: color-mix(in srgb, var(--red) 11%, transparent); font-weight: 600; }

.top__actions { display: flex; align-items: center; gap: 9px; }

.iconbtn {
  width: 40px; height: 40px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 50%;
  background: transparent; color: var(--ink-2); cursor: pointer;
  transition: color .2s, border-color .2s;
}
.iconbtn:hover { color: var(--red); border-color: var(--red); }
.iconbtn .ic { width: 18px; height: 18px; }
.ic--sun { fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; }
.ic--moon { fill: currentColor; display: none; }
html[data-theme="dark"] .ic--sun { display: none; }
html[data-theme="dark"] .ic--moon { display: block; }

.burger {
  display: none; width: 42px; height: 42px; border: 1px solid var(--line);
  border-radius: 12px; background: transparent; cursor: pointer; position: relative;
}
.burger span, .burger span::before, .burger span::after {
  position: absolute; left: 50%; translate: -50% 0;
  width: 19px; height: 2px; border-radius: 2px; background: var(--ink);
  transition: transform .3s var(--ease), opacity .2s;
}
.burger span { top: 50%; margin-top: -1px; }
.burger span::before { content: ""; top: -7px; left: 0; translate: 0 0; }
.burger span::after  { content: ""; top: 7px;  left: 0; translate: 0 0; }
.burger[aria-expanded="true"] span { background: transparent; }
.burger[aria-expanded="true"] span::before { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span::after  { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Menü (mobil) ---------- */
.drawer {
  position: fixed; inset: var(--top-h) 0 auto 0; z-index: 119;
  background: var(--bg); border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  max-height: calc(100dvh - var(--top-h)); overflow-y: auto;
  animation: slideDown .28s var(--ease);
}
@keyframes slideDown { from { opacity: 0; transform: translateY(-12px); } }
.drawer nav {
  display: grid; gap: 2px; padding: 12px 0 26px;
  width: min(100% - 2 * var(--pad), 1400px); margin-inline: auto;
}
.drawer a {
  padding: 13px 4px; text-decoration: none; font-weight: 600; font-size: 1.02rem;
  border-bottom: 1px solid var(--line);
}
.drawer .btn { margin-top: 14px; border-bottom: 0; }

/* ---------- Abschnitts-Leiste (rechts) ---------- */
.rail { display: none; }
.counter { display: none; }

/* ---------- Szenen: Grundzustand = normale, scrollbare Seite ---------- */
.scene { padding: clamp(64px, 9vw, 110px) 0; }
.scene:first-of-type { padding-top: calc(var(--top-h) + 48px); }
.scene:nth-of-type(even) { background: var(--bg-soft); }
.scene__inner { width: min(100% - 2 * var(--pad), var(--wrap)); margin-inline: auto; }

/* ---------- Szenen im Vollbild-Modus (nur mit JavaScript) ---------- */
html.fp, html.fp body { height: 100%; overflow: hidden; }
html.fp .scene {
  position: fixed; inset: 0; z-index: 1;
  display: grid; align-content: center;
  padding: calc(var(--top-h) + clamp(14px, 3vh, 34px)) 0 clamp(52px, 8vh, 88px);
  background: var(--bg);
  opacity: 0; visibility: hidden; pointer-events: none;
}
html.fp .scene:nth-of-type(even) { background: var(--bg); }
html.fp .scene.is-active { opacity: 1; visibility: visible; pointer-events: auto; z-index: 2; }
html.fp .scene__inner {
  max-height: 100%; overflow-y: auto; overscroll-behavior: contain;
  scrollbar-width: thin;
}
/* Inhalt fährt herein, während der Feuerwehrmann die Flammen niederschlägt.
   --in-delay setzt das Skript: 500 ms mit Feuer, 0 ms ohne. */
html.fp .scene.is-active .scene__inner > * {
  animation: riseIn .6s var(--ease) both;
  animation-delay: var(--in-delay, 0ms);
}
html.fp .scene.is-active .scene__inner > *:nth-child(2) { animation-delay: calc(var(--in-delay, 0ms) + 70ms); }
html.fp .scene.is-active .scene__inner > *:nth-child(3) { animation-delay: calc(var(--in-delay, 0ms) + 140ms); }
html.fp .scene.is-active .scene__inner > *:nth-child(4) { animation-delay: calc(var(--in-delay, 0ms) + 210ms); }
/* Bewusst nach OBEN versetzt: eine Verschiebung nach unten würde den
   Abschnitt während der Animation scrollbar machen und das Mausrad abfangen. */
@keyframes riseIn { from { opacity: 0; transform: translateY(-14px); } }

/* ═══════════════════════════════════════════════════════════════
   Startbild: das Feuerwehrhaus liegt hinter dem ersten Abschnitt
   ═══════════════════════════════════════════════════════════════ */
.scene--hero {
  /* Der Abschnitt bleibt immer dunkel — hell auf Foto wäre nicht lesbar.
     Über die Tokens ziehen Kacheln, Knöpfe und Kennzahlen automatisch mit. */
  --bg: #0a0d13;
  --ink: #ffffff;
  --ink-2: #ccd4e4;
  --ink-3: #98a3ba;
  --line: rgba(255,255,255,.17);
  color: var(--ink);
  position: relative;      /* im Vollbild-Modus überschreibt html.fp .scene das mit fixed */
  isolation: isolate;
}
.scene--hero .scene__bg {
  position: absolute; inset: 0; z-index: 0; overflow: hidden; background: #0a0d13;
}
.scene--hero .scene__bg img {
  width: 100%; height: 100%; object-fit: cover; object-position: 58% 58%;
  transform: scale(1.06);
}
.scene--hero.is-active .scene__bg img { animation: heroDrift 30s ease-in-out infinite alternate; }
@keyframes heroDrift {
  from { transform: scale(1.05) translate3d(0, 0, 0); }
  to   { transform: scale(1.14) translate3d(-1.5%, -1%, 0); }
}
/* Abdunkeln: links kräftig für den Text, rechts bleibt das Haus sichtbar */
.scene--hero .scene__bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(102deg,
      rgba(8,10,15,.95) 0%, rgba(8,10,15,.9) 30%,
      rgba(8,10,15,.66) 56%, rgba(8,10,15,.44) 100%),
    linear-gradient(180deg,
      rgba(8,10,15,.82) 0%, rgba(8,10,15,.28) 26%,
      rgba(8,10,15,.35) 68%, rgba(8,10,15,.85) 100%),
    radial-gradient(ellipse 70% 55% at 78% 72%, rgba(211,20,35,.16), transparent 70%);
}
.scene--hero .scene__inner { position: relative; z-index: 1; }
/* Die Kennzahlen sitzen auf dem Foto — leicht durchscheinend statt deckend */
.scene--hero .stats { background: rgba(255,255,255,.16); backdrop-filter: blur(6px); }
.scene--hero .stats li { background: rgba(10,13,19,.62); }

/* ---------- Typografie-Bausteine ---------- */
.kicker {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 16px 7px 12px; border-radius: 999px;
  background: color-mix(in srgb, var(--ink) 5%, transparent); border: 1px solid var(--line);
  font-size: .74rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-3); margin-bottom: clamp(12px, 2.4vh, 22px);
}
.kicker__dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--red);
  animation: pulse 2.4s infinite;
}
.xxl { display: grid; gap: 2px; margin-bottom: clamp(12px, 2.2vh, 20px); }
.xxl__sm {
  font-family: var(--display); font-weight: 600; text-transform: uppercase;
  letter-spacing: .2em; font-size: clamp(.85rem, 2vw, 1.2rem); color: var(--red);
}
.xxl__lg {
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  font-size: clamp(2.9rem, 10.5vw, 7rem); line-height: .9; letter-spacing: -.015em;
}
.lead { max-width: 60ch; font-size: clamp(1rem, 1.8vw, 1.18rem); color: var(--ink-2); margin-bottom: clamp(16px, 3vh, 28px); }
.row { display: flex; flex-wrap: wrap; gap: 12px; }

.head { max-width: 66ch; margin-bottom: clamp(16px, 3.2vh, 44px); }
.head--center { margin-inline: auto; text-align: center; }
.eyebrow {
  font-size: .75rem; font-weight: 700; letter-spacing: .18em;
  text-transform: uppercase; color: var(--red); margin: 0 0 12px;
}
.head h2, .duo h2 {
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  font-size: clamp(1.8rem, 4.4vw, 3rem); line-height: 1.02; margin-bottom: clamp(8px, 1.6vh, 14px);
}
.lede { font-size: clamp(.98rem, 1.5vw, 1.1rem); color: var(--ink-2); margin: 0; }
.lede a { color: var(--red); font-weight: 700; }
.muted { color: var(--ink-3); font-size: .87rem; }
.link { display: inline-block; margin-top: 6px; color: var(--red); font-weight: 600; font-size: .9rem; text-decoration: none; }

/* ---------- Kennzahlen ---------- */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line);
  border-radius: var(--r-lg); overflow: hidden; margin-top: clamp(16px, 3vh, 40px);
}
.stats li { background: var(--bg); padding: clamp(14px, 2.4vh, 24px) 10px; text-align: center; }
.stats b {
  display: block; font-family: var(--display); font-weight: 700;
  font-size: clamp(1.9rem, 5vw, 3rem); line-height: 1; font-variant-numeric: tabular-nums;
}
.stats span {
  display: block; margin-top: 6px; font-size: .7rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3);
}

.hint {
  display: inline-flex; align-items: center; gap: 10px; margin: clamp(12px, 2.2vh, 28px) 0 0;
  font-size: .85rem; color: var(--ink-3);
}
.hint__ico {
  position: relative; flex: none; width: 20px; height: 30px;
  border: 2px solid currentColor; border-radius: 999px; opacity: .75;
}
.hint__ico::after {
  content: ""; position: absolute; left: 50%; top: 6px; translate: -50% 0;
  width: 3px; height: 6px; border-radius: 2px; background: currentColor;
  animation: hintDot 1.8s infinite;
}
@keyframes hintDot { 0%{opacity:0;transform:translate(-50%,0)} 30%{opacity:1} 100%{opacity:0;transform:translate(-50%,10px)} }

/* ---------- Raster ---------- */
.grid { display: grid; gap: clamp(12px, 1.6vw, 20px); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }

/* ---------- Kachel ---------- */
.tile {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: clamp(18px, 2.4vh, 26px) 22px;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
}
.tile:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); border-color: transparent; }
.tile__ico {
  display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 14px;
  border-radius: 13px; background: color-mix(in srgb, var(--red) 11%, transparent); color: var(--red);
}
.tile__ico svg { width: 23px; height: 23px; fill: currentColor; }
.tile h3 { font-size: 1.08rem; margin-bottom: 7px; }
.tile p { margin: 0; color: var(--ink-2); font-size: .92rem; }

/* ---------- Bild + Text ---------- */
.duo {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(24px, 4vw, 56px); align-items: center;
}
.duo__media { position: relative; border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-lg); }
.duo__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.duo__media figcaption {
  position: absolute; left: 14px; bottom: 14px;
  padding: 7px 14px; border-radius: 999px;
  background: rgba(11,14,21,.74); backdrop-filter: blur(8px);
  color: #fff; font-size: .78rem; font-weight: 600;
}
.duo__body .lede { margin-bottom: 18px; }
/* Fehlt das Mannschaftsfoto, nimmt der Text die volle Breite ein */
.duo--nomedia { grid-template-columns: 1fr; max-width: 74ch; }
.duo__media[hidden] { display: none; }

.ticks { display: grid; gap: 9px; margin: 0 0 22px; }
.ticks li { position: relative; padding-left: 30px; color: var(--ink-2); font-size: .94rem; }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: .34em;
  width: 18px; height: 18px; border-radius: 50%;
  background: color-mix(in srgb, var(--red) 15%, transparent);
}
.ticks li::after {
  content: ""; position: absolute; left: 5.5px; top: .58em;
  width: 7px; height: 4px; border-left: 2px solid var(--red); border-bottom: 2px solid var(--red);
  transform: rotate(-45deg);
}

/* ---------- Fahrzeuge ---------- */
.veh {
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 0 22px clamp(6px, 1vh, 12px);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.veh:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.veh__media {
  margin: 0 -22px clamp(12px, 2vh, 20px);
  background: #0d1119; overflow: hidden;
}
.veh__media img {
  width: 100%; aspect-ratio: 3 / 2; object-fit: cover; display: block;
  transition: transform .6s var(--ease);
}
.veh:hover .veh__media img { transform: scale(1.05); }
.veh__media[hidden] { display: none; }
.veh__media[hidden] + .veh__top { margin-top: clamp(18px, 2.4vh, 26px); }
.veh__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.veh__tag {
  font-size: .64rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-3); border: 1px solid var(--line); padding: 4px 11px; border-radius: 999px;
}
.veh__code { font-family: var(--display); font-weight: 700; font-size: 1.4rem; color: var(--red); }
.veh h3 { font-size: 1.1rem; margin-bottom: 6px; }
.veh > p { color: var(--ink-2); font-size: .9rem; margin-bottom: clamp(8px, 1.6vh, 14px); }
.spec { margin: 0; border-top: 1px solid var(--line); }
.spec > div { display: flex; justify-content: space-between; gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.spec dt { color: var(--ink-3); font-size: .84rem; }
.spec dd { margin: 0; font-weight: 600; font-size: .87rem; text-align: right; }

/* ---------- Feuerwehrfest ---------- */
.fest {
  display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: clamp(20px, 3vw, 40px);
  background: var(--night); color: #eef1f8;
  border-radius: var(--r-xl); padding: clamp(22px, 3.4vh, 40px);
  margin-bottom: clamp(16px, 2.4vh, 26px);
  position: relative; overflow: hidden; isolation: isolate;
}
.fest::before {
  content: ""; position: absolute; inset: -45% -10% auto auto; width: 70%; aspect-ratio: 1; z-index: -1;
  background: radial-gradient(circle, rgba(211,20,35,.55), transparent 62%); filter: blur(45px);
}
.fest__eyebrow {
  font-size: .72rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase;
  color: var(--amber); margin: 0 0 10px;
}
.fest h3 {
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  font-size: clamp(1.7rem, 4.4vw, 2.8rem); color: #fff; margin-bottom: 10px;
}
.fest__date { font-weight: 600; color: var(--amber); margin-bottom: 16px; font-size: .96rem; }
.fest__times { display: flex; flex-wrap: wrap; gap: 8px; }
.fest__times div {
  display: grid; gap: 1px; padding: 9px 16px; border-radius: var(--r-sm);
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12);
}
.fest__times b { font-family: var(--display); font-size: 1.08rem; color: #fff; }
.fest__times span { font-size: .78rem; color: #a3adc4; }

.fest__side {
  display: flex; flex-direction: column; justify-content: center; text-align: center;
  padding: 18px; border-radius: var(--r-lg);
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12);
}
.cd__lbl, .cd__note { font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: #a3adc4; margin: 0; }
.cd { display: flex; justify-content: center; gap: 7px; margin: 8px 0; }
.cd div { flex: 1; padding: 9px 3px; border-radius: 11px; background: rgba(0,0,0,.3); }
.cd b {
  display: block; font-family: var(--display); font-size: clamp(1.5rem, 3.4vw, 2.2rem);
  line-height: 1; color: #fff; font-variant-numeric: tabular-nums;
}
.cd span { font-size: .62rem; letter-spacing: .1em; text-transform: uppercase; color: #a3adc4; }

/* ---------- Terminliste ---------- */
.dates { display: grid; gap: 10px; }
.dates li {
  display: grid; grid-template-columns: 86px 1fr; align-items: center; gap: 18px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r);
  padding: 14px 20px;
  transition: transform .25s var(--ease), border-color .25s;
}
.dates li:hover { transform: translateX(5px); border-color: color-mix(in srgb, var(--red) 45%, var(--line)); }
.dates__d {
  display: grid; place-items: center; gap: 1px; padding: 9px 4px; border-radius: 13px;
  background: color-mix(in srgb, var(--red) 9%, transparent);
  border: 1px solid color-mix(in srgb, var(--red) 20%, transparent);
}
.dates__d b { font-family: var(--display); font-size: 1.45rem; line-height: 1; color: var(--red); }
.dates__d span { font-size: .66rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.dates h3 { font-size: 1.04rem; margin-bottom: 3px; }
.dates p { margin: 0; color: var(--ink-2); font-size: .89rem; }

/* ---------- Mitmachen ---------- */
.join {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: clamp(18px, 2.4vh, 28px) 24px;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.join:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.join__badge {
  display: inline-block; margin-bottom: 12px; padding: 6px 15px; border-radius: 999px;
  background: linear-gradient(180deg, var(--red-300), var(--red)); color: #fff;
  font-size: .72rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  box-shadow: 0 4px 12px -4px rgba(211,20,35,.6);
}
.join h3 { font-size: clamp(1.1rem, 2vw, 1.32rem); margin-bottom: 8px; }
.join > p { margin: 0 0 14px; color: var(--ink-2); font-size: .95rem; }
.join .ticks { margin-bottom: 0; }

.cta {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 20px; margin-top: clamp(16px, 2.4vh, 26px); padding: clamp(20px, 2.8vh, 32px);
  border-radius: var(--r-xl);
  background: linear-gradient(100deg, color-mix(in srgb, var(--red) 12%, transparent), color-mix(in srgb, var(--amber) 10%, transparent));
  border: 1px solid var(--line);
}
.cta h3 { font-family: var(--display); text-transform: uppercase; font-size: clamp(1.4rem, 3vw, 1.9rem); margin-bottom: 6px; }
.cta p { margin: 0; color: var(--ink-2); }

/* ---------- Bewerbungsformular ---------- */
.cta { align-items: start; }
.cta__text { flex: 1 1 260px; }
.cta__text a { color: var(--red); font-weight: 600; }

.formular { flex: 1 1 380px; display: grid; gap: 10px; min-width: 0; }
.formular__reihe { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.formular__reihe:has(.feld--klein) { grid-template-columns: 1fr 96px; }

.feld { display: grid; gap: 4px; min-width: 0; }
.feld > span {
  font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-3);
}
.feld > span i { font-style: normal; text-transform: none; letter-spacing: 0; font-weight: 500; }
.feld input, .feld textarea {
  width: 100%; font: inherit; font-size: .95rem; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line); border-radius: 10px;
  padding: 9px 12px; transition: border-color .2s, box-shadow .2s;
}
.feld textarea { resize: vertical; min-height: 44px; }
.feld input:focus, .feld textarea:focus {
  outline: none; border-color: var(--red);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--red) 18%, transparent);
}

/* Falle für automatische Eintragungen — für Menschen unsichtbar,
   aber nicht display:none, damit Ausfüllhelfer sie trotzdem finden. */
.honigtopf {
  position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden;
}

.zustimmung { display: flex; gap: 9px; align-items: flex-start; font-size: .82rem; color: var(--ink-2); }
.zustimmung input { margin-top: 3px; accent-color: var(--red); flex: none; }
.zustimmung a { color: var(--red); font-weight: 600; }

.formular__fuss { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.formular__meldung { margin: 0; font-size: .86rem; color: var(--ink-3); }
.formular__meldung--fehler { color: var(--red); font-weight: 600; }
.formular__meldung--erfolg { color: #16a34a; font-weight: 600; }

.dates__leer { color: var(--ink-3); font-size: .92rem; padding: 14px 4px; }

/* Auf breiten Schirmen stehen die beiden Wege links und das Formular
   rechts daneben — sonst wird der Abschnitt zu hoch für einen Bildschirm. */
@media (min-width: 1041px) {
  #mitmachen .scene__inner {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0 clamp(18px, 2.6vw, 30px); align-items: start;
  }
  #mitmachen .head { grid-column: 1 / -1; }
  #mitmachen .grid--2 { grid-template-columns: minmax(0, 1fr); align-content: start; }
  #mitmachen .cta { margin-top: 0; }
}

/* ---------- Infoboxen ---------- */
.box {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: clamp(18px, 2.4vh, 28px) 24px;
}
.box--sm { padding: 20px 22px; }
.box h3 { font-size: 1.06rem; margin-bottom: 14px; }
.box p { font-size: .95rem; margin-bottom: .5em; }
.box a { color: var(--ink); text-decoration: none; font-weight: 600; }
.box a:hover { color: var(--red); }
.box .link { color: var(--red); }

.wlist { display: grid; gap: 9px; counter-reset: w; }
.wlist li { position: relative; padding-left: 38px; color: var(--ink-2); font-size: .92rem; counter-increment: w; }
.wlist li::before {
  content: counter(w); position: absolute; left: 0; top: 0;
  display: grid; place-items: center; width: 25px; height: 25px; border-radius: 50%;
  background: var(--red); color: #fff; font-size: .76rem; font-weight: 700;
}
.wlist b { color: var(--ink); }

.siglist { display: grid; gap: 10px; }
.siglist li { display: flex; gap: 12px; align-items: flex-start; font-size: .9rem; color: var(--ink-2); }
.siglist b { color: var(--ink); }
.sig { flex: none; width: 32px; height: 9px; margin-top: 6px; border-radius: 3px; background: var(--line); }
.sig--probe { background: linear-gradient(90deg, var(--ink-3) 45%, transparent 45%); }
.sig--feuer { background: repeating-linear-gradient(90deg, var(--red) 0 8px, transparent 8px 12px); }
.sig--warn  { background: var(--amber); }
.sig--alarm { background: repeating-linear-gradient(90deg, var(--red) 0 4px, var(--amber) 4px 8px); }
.sig--ende  { background: #16a34a; }

/* ---------- Notrufnummern ---------- */
.nums { display: flex; flex-wrap: wrap; gap: 10px; margin-top: clamp(14px, 2.4vh, 24px); }
.nums a {
  display: flex; align-items: baseline; gap: 8px; padding: 10px 20px; border-radius: 999px;
  background: var(--red); color: #fff; text-decoration: none;
  transition: transform .18s var(--ease), box-shadow .25s var(--ease);
}
.nums li:nth-child(n+2) a { background: var(--card); color: var(--ink); border: 1px solid var(--line); }
.nums a:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.nums b { font-family: var(--display); font-size: 1.3rem; }
.nums span { font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; opacity: .85; }

/* ---------- Personen ---------- */
.pers {
  display: flex; gap: 20px; align-items: center;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 22px 24px;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.pers:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.pers__avatar {
  flex: none; display: grid; place-items: center; width: 70px; height: 70px;
  border-radius: 50%; font-family: var(--display); font-weight: 700; font-size: 1.55rem;
  color: #fff; background: linear-gradient(150deg, var(--red-300), var(--red-600));
  box-shadow: 0 8px 22px -8px rgba(211,20,35,.7);
}
.pers__role { font-size: .7rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--red); margin: 0 0 5px; }
.pers h3 { font-size: 1.08rem; margin-bottom: 10px; }
.pers__links { display: grid; gap: 6px; }
.pers__links a {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none;
  color: var(--ink-2); font-size: .89rem; word-break: break-word; transition: color .2s;
}
.pers__links a:hover { color: var(--red); }
.pers__links svg { flex: none; width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linejoin: round; }

/* ---------- Kontakt ---------- */
.kontakt { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(16px, 2.4vw, 28px); align-items: stretch; }
.kontakt__cards { align-content: start; grid-template-columns: 1fr; }
.mapbox {
  position: relative; min-height: 240px; border-radius: var(--r-lg); overflow: hidden;
  border: 1px solid var(--line); background: var(--bg-soft);
}
.mapbox iframe { display: block; width: 100%; height: 100%; min-height: 240px; border: 0; }
.mapbox__ph {
  position: absolute; inset: 0; display: grid; place-content: center; justify-items: center;
  text-align: center; padding: 26px; gap: 4px;
}
.mapbox__ph svg { width: 36px; height: 36px; fill: var(--red); }
.mapbox__ph h3 { font-size: 1.05rem; }
.mapbox__ph p { max-width: 32ch; font-size: .86rem; color: var(--ink-3); }

.foot {
  display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: space-between;
  margin-top: clamp(16px, 2.4vh, 26px); padding-top: 16px;
  border-top: 1px solid var(--line); font-size: .84rem; color: var(--ink-3);
}
.foot p { margin: 0; }
.foot__links { display: flex; gap: 18px; }
.foot__links a { text-decoration: none; }
.foot__links a:hover { color: var(--red); }

/* ---------- Notruf-Knopf (mobil) ---------- */
.fab {
  display: none; position: fixed; right: 14px; bottom: 14px; z-index: 130;
  align-items: center; gap: 8px; padding: 13px 19px; border-radius: 999px;
  background: var(--red); color: #fff; text-decoration: none;
  font-family: var(--display); font-weight: 700; font-size: 1.2rem;
  box-shadow: 0 10px 30px -8px rgba(211,20,35,.8);
}
.fab svg { width: 19px; height: 19px; fill: currentColor; }

/* ═══════════════════════════════════════════════════════════════
   LÖSCH-EINSATZ BEIM ABSCHNITTSWECHSEL

   Gesamtdauer 1600 ms — alle Prozentwerte hier beziehen sich darauf
   und müssen zu FX_MS / SWAP_MS in app.js passen.
   Der Abschnittswechsel passiert bei 300 ms (≈19 %), also hinter der
   voll aufgezogenen Abdunkelung.
   ═══════════════════════════════════════════════════════════════ */
.fx {
  position: fixed; inset: 0; z-index: 100;
  pointer-events: none; visibility: hidden; overflow: hidden;
  contain: layout paint;
}
.fx.is-on { visibility: visible; }
.fx__defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* Abdunkelung — verdeckt den Abschnittswechsel vollständig */
.fx__scrim { position: absolute; inset: 0; background: #07090e; opacity: 0; }
.fx.is-on .fx__scrim { animation: fxScrim 1600ms linear both; }
@keyframes fxScrim {
  0%        { opacity: 0; }
  13%       { opacity: 1; }
  62%       { opacity: 1; }
  88%, 100% { opacity: 0; }
}

/* Feuerschein auf der Bühne */
.fx__glow {
  position: absolute; left: var(--obj-x, 62%); bottom: -18vh; translate: -50% 0;
  width: 110vw; height: 90vh; opacity: 0;
  background: radial-gradient(ellipse at 50% 72%, rgba(255,124,22,.62), rgba(255,58,10,.2) 40%, transparent 66%);
}
/* Der Feuerschein flackert, statt gleichmäßig zu leuchten */
.fx.is-on .fx__glow { animation: fxGlow 1600ms ease-out both; }
@keyframes fxGlow {
  0%        { opacity: 0; }
  10%       { opacity: .72; }
  16%       { opacity: .98; }
  21%       { opacity: .74; }
  27%       { opacity: 1; }
  33%       { opacity: .8; }
  39%       { opacity: .95; }
  47%       { opacity: .66; }
  56%       { opacity: .74; }
  66%       { opacity: .4; }
  82%, 100% { opacity: 0; }
}

/* ---------- Das brennende Objekt ---------- */
.fx__object {
  position: absolute; left: var(--obj-x, 62%); bottom: 0; translate: -50% 0;
  height: var(--obj-h, 32vh);
  transform-origin: 50% 100%;
  opacity: 0;
}
.fx__object svg {
  height: 100%; width: auto; display: block; overflow: visible;
  filter: drop-shadow(0 18px 34px rgba(0,0,0,.65));
}
.fx.is-on .fx__object { animation: fxObject 1600ms cubic-bezier(.2,.9,.3,1) both; }
@keyframes fxObject {
  0%        { opacity: 0; transform: translateY(38px) scale(.88); }
  9%        { opacity: 1; transform: translateY(4px) scale(.99); }
  15%       { opacity: 1; transform: translateY(-7px) scale(1.025); }
  21%       { opacity: 1; transform: translateY(0) scale(1); }
  80%       { opacity: 1; transform: translateY(0) scale(1); }
  93%, 100% { opacity: 0; transform: translateY(0) scale(.97); }
}

/* Das Objekt zuckt, wenn der Wasserstrahl auftrifft */
.fx.is-on:not(.is-rescue) .fx__object > svg { animation: fxHit 1600ms linear both; }
@keyframes fxHit {
  0%, 35%   { transform: translate(0, 0); }
  37%       { transform: translate(4px, 1px); }
  40%       { transform: translate(-3px, 0); }
  44%       { transform: translate(3px, 1px); }
  49%       { transform: translate(-2px, 0); }
  55%       { transform: translate(1px, 0); }
  62%, 100% { transform: translate(0, 0); }
}

/* Flammen sitzen als SVG-Gruppen auf ihren Ankerpunkten */
.flame { transform-box: fill-box; transform-origin: 50% 100%; }
.fx.is-on .flame { animation: fxDouse 620ms var(--d, 520ms) cubic-bezier(.5,0,.75,0) both; }
/* Getroffene Flamme: kurz aufflackern, dann niedergeschlagen und breit
   auslaufen — nicht einfach nach unten wegschrumpfen. */
@keyframes fxDouse {
  0%        { transform: scaleY(1) scaleX(1); opacity: 1; }
  16%       { transform: scaleY(1.15) scaleX(.9); opacity: 1; }
  34%       { transform: scaleY(.72) scaleX(1.1); opacity: .95; }
  55%       { transform: scaleY(.26) scaleX(1.28); opacity: .78; }
  78%, 100% { transform: scaleY(0) scaleX(1.45); opacity: 0; }
}
.flame__body { transform-box: fill-box; transform-origin: 50% 100%; }
.fx.is-on .flame__body { animation: fxFlicker var(--f, 560ms) ease-in-out infinite alternate; }
@keyframes fxFlicker {
  0%   { transform: scaleY(.93) scaleX(1.04) skewX(4deg); }
  50%  { transform: scaleY(1.12) scaleX(.95) skewX(-4deg); }
  100% { transform: scaleY(1) scaleX(1) skewX(2deg); }
}

/* Funkenflug (Canvas, gezeichnet in app.js) */
.fx__sparks { position: absolute; inset: 0; width: 100%; height: 100%; }

/* ---------- Feuerwehrmann ---------- */
.fx__ff {
  position: absolute; left: 0; bottom: 0;
  height: clamp(148px, 25vh, 235px); aspect-ratio: 140 / 190;
  transform: translateX(-36vw);
  filter: drop-shadow(0 0 26px rgba(0,0,0,.6));
}
.fx.is-on .fx__ff { animation: fxRun 1600ms cubic-bezier(.3,.7,.4,1) both; }
@keyframes fxRun {
  0%, 13% { transform: translateX(-36vw); }
  29%     { transform: translateX(var(--ff-x, 12vw)); }
  80%     { transform: translateX(var(--ff-x, 12vw)); }
  100%    { transform: translateX(-36vw); }
}
.fx__ff > svg { width: 100%; height: 100%; display: block; overflow: visible; }

.ff-legA, .ff-legB { transform-box: fill-box; transform-origin: 50% 4%; }
.fx.is-on .ff-legA { animation: fxLegA 1600ms linear both; }
.fx.is-on .ff-legB { animation: fxLegB 1600ms linear both; }
@keyframes fxLegA {
  0%, 13% { transform: rotate(28deg); }
  17%     { transform: rotate(-22deg); }
  21%     { transform: rotate(26deg); }
  25%     { transform: rotate(-20deg); }
  29%,80% { transform: rotate(-15deg); }
  85%     { transform: rotate(26deg); }
  91%     { transform: rotate(-22deg); }
  100%    { transform: rotate(24deg); }
}
@keyframes fxLegB {
  0%, 13% { transform: rotate(-24deg); }
  17%     { transform: rotate(26deg); }
  21%     { transform: rotate(-22deg); }
  25%     { transform: rotate(24deg); }
  29%,80% { transform: rotate(17deg); }
  85%     { transform: rotate(-22deg); }
  91%     { transform: rotate(26deg); }
  100%    { transform: rotate(-20deg); }
}
.ff-body { transform-box: fill-box; transform-origin: 50% 100%; }
.fx.is-on .ff-body { animation: fxBob 1600ms linear both; }
/* Vorlage beim Laufen, Rückstoß beim Aufdrehen des Strahlrohrs */
@keyframes fxBob {
  0%, 13% { transform: translateY(0) rotate(10deg); }
  17%     { transform: translateY(-4px) rotate(10deg); }
  21%     { transform: translateY(0) rotate(10deg); }
  25%     { transform: translateY(-4px) rotate(10deg); }
  29%     { transform: translateY(0) rotate(4deg); }
  34%     { transform: translateY(0) rotate(0deg); }
  38%     { transform: translateY(0) rotate(-6deg); }
  45%,74% { transform: translateY(0) rotate(-3deg); }
  80%     { transform: translateY(0) rotate(8deg); }
  86%     { transform: translateY(-4px) rotate(10deg); }
  93%     { transform: translateY(0) rotate(10deg); }
  100%    { transform: translateY(-3px) rotate(10deg); }
}

/* Arme schwenken vom Lauf- in den Zielwinkel.
   --aim rechnet app.js aus der Lage des Brandherds aus. */
.ff-arms { transform-box: fill-box; transform-origin: 28% 14%; }
.fx.is-on .ff-arms { animation: fxArms 1600ms cubic-bezier(.22,.68,.36,1) both; }
@keyframes fxArms {
  0%, 28%   { transform: rotate(38deg); }
  33%, 76%  { transform: rotate(var(--aim, -20deg)); }
  84%, 100% { transform: rotate(38deg); }
}

/* ---------- Wasserstrahl ----------
   Der Rahmen dreht sich um die Schulter, damit der Strahl exakt dort
   ansetzt, wo das Strahlrohr nach dem Armschwenk sitzt. */
.fx__jetwrap {
  position: absolute; inset: 0;
  transform-origin: 58.6% 30.5%;
  transform: rotate(var(--aim, -20deg));
}
.fx__jet {
  position: absolute; left: 98.6%; top: 43.4%;
  width: var(--jet-len, 46vw); height: clamp(9px, 1.5vh, 16px);
  transform-origin: 0 50%; transform: scaleX(0); opacity: 0;
  will-change: transform;
}
.fx__jet i {
  position: absolute; inset: 0; border-radius: 999px;
  background: linear-gradient(90deg, rgba(232,248,255,.98), rgba(140,205,255,.6) 38%, rgba(140,205,255,0) 90%);
  filter: blur(2px);
}
.fx__jet i:nth-child(2) { transform: rotate(-4.5deg) scaleY(.7); opacity: .7; }
.fx__jet i:nth-child(3) { transform: rotate(4deg) scaleY(.6); opacity: .55; }
/* Der Strahl pulsiert leicht — Pumpendruck statt starrem Balken */
.fx.is-on .fx__jet i:nth-child(1) { animation: fxJetPulse 170ms ease-in-out infinite alternate; }
@keyframes fxJetPulse {
  from { transform: scaleY(.88); filter: blur(2px) brightness(1); }
  to   { transform: scaleY(1.16); filter: blur(2px) brightness(1.15); }
}
.fx.is-on .fx__jet { animation: fxJet 1600ms ease-out both; }
@keyframes fxJet {
  0%, 33%   { transform: scaleX(0); opacity: 0; }
  38%       { transform: scaleX(1); opacity: 1; }
  74%       { transform: scaleX(1); opacity: 1; }
  79%, 100% { transform: scaleX(1); opacity: 0; }
}

/* Der Schlauch bleibt beim Laufen eingerollt und spannt sich beim Löschen */
.ff-hose { opacity: 0; }
.fx.is-on .ff-hose { animation: fxHose 1600ms ease-out both; }
@keyframes fxHose {
  0%, 30%   { opacity: 0; }
  36%, 76%  { opacity: 1; }
  82%, 100% { opacity: 0; }
}

/* ---------- Wasserdampf ---------- */
.fx__steam { position: absolute; left: var(--obj-x, 62%); bottom: 2vh; translate: -50% 0; width: 46vw; height: 40vh; }
/* Große weiche Dampfmasse — die Feinstruktur kommt vom Canvas */
.fx__steam i {
  position: absolute; bottom: 0; width: 13vw; height: 13vw;
  max-width: 170px; max-height: 170px;
  border-radius: 50%; background: rgba(226,236,247,.34); filter: blur(24px); opacity: 0;
}
.fx__steam i:nth-child(1) { left: 8%; }
.fx__steam i:nth-child(2) { left: 38%; }
.fx__steam i:nth-child(3) { left: 66%; }
.fx.is-on .fx__steam i { animation: fxSteam 1600ms ease-out both; }
.fx.is-on .fx__steam i:nth-child(2) { animation-delay: 80ms; }
.fx.is-on .fx__steam i:nth-child(3) { animation-delay: 160ms; }
@keyframes fxSteam {
  0%, 44%   { opacity: 0; transform: translateY(26px) scale(.5); }
  62%       { opacity: .7; transform: translateY(-18px) scale(1); }
  88%, 100% { opacity: 0; transform: translateY(-84px) scale(1.5); }
}

/* ---------- Katzenrettung: kein Feuer, dafür Leiter und Katze ---------- */
.fx.is-rescue .fx__jet,
.fx.is-rescue .fx__glow,
.fx.is-rescue .fx__steam,
.fx.is-rescue .ff-hose { display: none; }

.ff-ladder { transform-box: fill-box; transform-origin: 18% 100%; opacity: 0; }
.fx.is-on .ff-ladder { animation: fxLadder 1600ms cubic-bezier(.22,.68,.36,1) both; }
@keyframes fxLadder {
  0%, 16%   { opacity: 0; transform: rotate(-9deg) translateY(10px); }
  30%, 86%  { opacity: 1; transform: rotate(0) translateY(0); }
  95%, 100% { opacity: 0; transform: rotate(0) translateY(0); }
}

/* Die Katze klettert Sprosse für Sprosse herunter und landet mit einem
   kleinen Hüpfer — nicht als gleichmäßiges Herabgleiten. */
.ff-cat { transform-box: fill-box; transform-origin: 50% 100%; }
.fx.is-on .ff-cat { animation: fxCat 1600ms linear both; }
@keyframes fxCat {
  0%, 28%   { transform: translate(0, 0) rotate(0deg); }
  32%       { transform: translate(1px, -3px) rotate(-6deg); }   /* zögert */
  37%       { transform: translate(-3px, 9px) rotate(3deg); }
  44%       { transform: translate(-6px, 27px) rotate(-3deg); }
  51%       { transform: translate(-9px, 46px) rotate(3deg); }
  58%       { transform: translate(-12px, 64px) rotate(-3deg); }
  65%       { transform: translate(-15px, 82px) rotate(2deg); }
  71%       { transform: translate(-18px, 97px) rotate(0deg); }
  75%       { transform: translate(-19px, 88px) rotate(0deg); }  /* Hüpfer */
  79%       { transform: translate(-20px, 99px) rotate(0deg); }
  84%       { transform: translate(-20px, 96px) rotate(0deg); }
  89%, 100% { transform: translate(-20px, 99px) rotate(0deg); }
}
/* Schwanzwedeln, sobald sie unten ist */
.ff-cat > path:nth-of-type(2) { transform-box: fill-box; transform-origin: 100% 100%; }
.fx.is-on .ff-cat > path:nth-of-type(2) { animation: fxTail 1600ms ease-in-out both; }
@keyframes fxTail {
  0%, 76% { transform: rotate(0deg); }
  82%     { transform: rotate(-16deg); }
  88%     { transform: rotate(12deg); }
  94%     { transform: rotate(-10deg); }
  100%    { transform: rotate(0deg); }
}
/* Kopfzeile, Notruf-Knopf und Skip-Link liegen über dem Feuer (z-index 100),
   damit der Notruf während der Animation erreichbar bleibt. */

/* ═══════════════════════════════════════════════════════════════
   Rechtstexte (Impressum / Datenschutz)
   ═══════════════════════════════════════════════════════════════ */
.page { padding: calc(var(--top-h) + clamp(40px, 7vw, 80px)) 0 clamp(50px, 8vw, 90px); }
.prose { width: min(100% - 2 * var(--pad), 76ch); margin-inline: auto; }
.prose h1 {
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  font-size: clamp(2.2rem, 6vw, 3.4rem); line-height: 1; margin-bottom: 14px;
}
.prose h2 { font-size: 1.14rem; margin: 36px 0 10px; padding-top: 22px; border-top: 1px solid var(--line); }
.prose p { color: var(--ink-2); }
.prose a { color: var(--red); font-weight: 600; }
.prose b { color: var(--ink); }
.prose .btn { margin-top: 24px; }
.prose .btn--ghost { color: var(--ink); }
.note {
  margin-top: 30px; padding: 18px 20px; border-radius: var(--r);
  background: color-mix(in srgb, var(--amber) 13%, transparent);
  border: 1px solid color-mix(in srgb, var(--amber) 42%, transparent);
  font-size: .91rem; color: var(--ink-2);
}
.note b { color: var(--ink); }

/* ═══════════════════════════════════════════════════════════════
   Abschnitts-Leiste und Zähler (nur im Vollbild-Modus)
   ═══════════════════════════════════════════════════════════════ */
html.fp .rail {
  display: block; position: fixed; right: 18px; top: 50%; translate: 0 -50%; z-index: 118;
}
html.fp .rail ol { display: grid; gap: 12px; }
html.fp .rail button {
  display: flex; align-items: center; gap: 10px; flex-direction: row-reverse;
  background: none; border: 0; padding: 3px; cursor: pointer; color: var(--ink-3);
}
html.fp .rail .dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: color-mix(in srgb, var(--ink) 26%, transparent);
  transition: background .25s, transform .25s var(--ease), box-shadow .25s;
}
html.fp .rail .lbl {
  font-size: .74rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  opacity: 0; translate: 8px 0; transition: opacity .25s, translate .25s var(--ease);
  white-space: nowrap;
}
html.fp .rail button:hover .lbl, html.fp .rail button:focus-visible .lbl { opacity: 1; translate: 0 0; }
html.fp .rail button:hover .dot { background: var(--red); }
html.fp .rail button[aria-current="true"] .dot {
  background: var(--red); transform: scale(1.5); box-shadow: 0 0 0 4px color-mix(in srgb, var(--red) 20%, transparent);
}
html.fp .rail button[aria-current="true"] .lbl { opacity: 1; translate: 0 0; color: var(--red); }

html.fp .counter {
  display: flex; align-items: baseline; gap: 6px;
  position: fixed; left: var(--pad); bottom: 20px; z-index: 118; margin: 0;
  font-family: var(--display); color: var(--ink-3);
}
html.fp .counter b { font-size: 1.5rem; color: var(--red); }
html.fp .counter span { font-size: .95rem; letter-spacing: .08em; }

/* ═══════════════════════════════════════════════════════════════
   Responsive
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 1239px) {
  html.fp .rail { display: none; }
}
@media (max-width: 1040px) {
  .topnav { display: none; }
  .burger { display: block; }
  .kontakt { grid-template-columns: 1fr; }
  .fest { grid-template-columns: 1fr; }
  .duo { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .top__actions .btn--alarm { display: none; }
  .fab { display: inline-flex; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .cta { flex-direction: column; align-items: flex-start; }
  .cta .row { width: 100%; }
  .cta .row .btn { flex: 1; }
  .formular { width: 100%; }
  .formular__reihe { grid-template-columns: 1fr; }
  .formular__reihe:has(.feld--klein) { grid-template-columns: 1fr 96px; }
  .pers { flex-direction: column; align-items: flex-start; }
  .nums a { flex: 1 1 auto; justify-content: center; }
  html.fp .counter { bottom: 14px; font-size: .9rem; }
  html.fp .counter b { font-size: 1.2rem; }
  .duo__media img { aspect-ratio: 16 / 9; }

  /* Kacheln liegen quer, damit ein Abschnitt möglichst auf einen Schirm passt */
  .tile {
    display: grid; grid-template-columns: 42px 1fr; gap: 2px 14px;
    align-items: center; padding: 14px 16px;
  }
  .tile__ico { grid-row: 1 / 3; width: 42px; height: 42px; margin: 0; }
  .tile h3 { font-size: 1rem; margin: 0; align-self: end; }
  .tile p { font-size: .85rem; align-self: start; }

  /* Auf dem Handy rückt der Feuerwehrmann kleiner in die Ecke */
  .fx__ff { height: clamp(110px, 19vh, 168px); }

  .veh { padding: 0 18px 4px; }
  .veh__media { margin: 0 -18px 12px; }
  .veh__media img { aspect-ratio: 16 / 9; }
  .veh > p { font-size: .86rem; }
  .join { padding: 16px 18px; }
  .join__badge { margin-bottom: 8px; }
  .box { padding: 18px 18px; }
  .grid { gap: 10px; }
}

/* ═══════════════════════════════════════════════════════════════
   Reduzierte Bewegung — kein Feuer, keine Animationen
   ═══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .fx { display: none !important; }
}

/* ═══════════════════════════════════════════════════════════════
   Druck — alle Abschnitte untereinander
   ═══════════════════════════════════════════════════════════════ */
@media print {
  html.fp, html.fp body { height: auto; overflow: visible; }
  html.fp .scene {
    position: static; opacity: 1; visibility: visible; page-break-inside: avoid;
    padding: 24pt 0; background: #fff;
  }
  html.fp .scene__inner { max-height: none; overflow: visible; animation: none !important; }
  .top, .drawer, .rail, .counter, .fab, .fx, .mapbox, .hint { display: none !important; }
  body { color: #000; background: #fff; font-size: 11pt; }
  .fest { background: #fff !important; color: #000 !important; }
  .fest h3, .fest__times b, .cd b { color: #000 !important; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; }
}
