/* Selbst gehostete Schriften (keine externen Requests) */
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 600 800;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/archivo-600-800-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;
}
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 600 800;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/archivo-600-800-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: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(../fonts/ibm-plex-mono-500-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;
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(../fonts/ibm-plex-mono-500-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: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/ibm-plex-sans-400-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;
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/ibm-plex-sans-400-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: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 500;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/ibm-plex-sans-500-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;
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 500;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/ibm-plex-sans-500-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: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 600;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/ibm-plex-sans-600-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;
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 600;
  font-stretch: 100%;
  font-display: swap;
  src: url(../fonts/ibm-plex-sans-600-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;
}

/* ==========================================================================
   Frankenberger IT-Consulting — Designsystem
   --------------------------------------------------------------------------
   Aufbau dieser Datei:
     01  Tokens (hell + dunkel)
     02  Reset & Basis
     03  Typografie
     04  Layout (Shell, Sections, Raster)
     05  Buttons & Links
     06  Header, Navigation, Theme-Schalter
     07  Kommandopalette
     08  Hero & Seitenkopf
     09  Inhaltsbausteine (Karten, Fakten, Zeitstrahl, FAQ, Zitat, Laufband)
     10  Sonderbausteine (Datenschutz-Check, Anfahrtsrechner)
     11  Formular
     12  Footer & Rechtstexte
     13  Bewegung
     14  Utilities, Reduced Motion, Druck

   Farben: Marineblau als Grund, Türkis (aus dem Logo) als einzige Signalfarbe.
   Alle Flächen laufen über semantische Tokens — das Dunkelthema tauscht nur
   diese Tokens aus, keine Komponente kennt eine feste Farbe.
   ========================================================================== */

/* ==========================================================================
   01  Tokens
   ========================================================================== */

:root {
  color-scheme: light;

  /* Markenfarben — in beiden Themes identisch */
  --brand-ink: #08131d;
  --brand-deep: #0d1e2c;
  --teal-900: #05323c;
  --teal-800: #084857;
  --teal-700: #0b5f70;
  --teal-600: #0c7186;
  --teal-500: #1bb4ce;
  --teal-400: #45c9de;
  --teal-300: #86dfec;
  --teal-100: #ddf2f7;

  /* Flächen */
  --bg: #f3f6f8;
  --bg-sunken: #e7edf1;
  --bg-elev: #ffffff;
  --bg-invert: #08131d;
  --bg-invert-elev: #102437;

  /* Text */
  --text: #101f2c;
  --text-soft: #47606f;
  --text-faint: #566c7c;
  --text-invert: #f2f7fa;
  --text-invert-soft: rgba(235, 244, 249, 0.72);
  --text-invert-faint: rgba(235, 244, 249, 0.48);

  /* Akzent — getrennt nach Fläche und Schrift, damit Kontrast stimmt */
  --accent: #0b6478;
  --accent-hover: #084857;
  --accent-vivid: #1bb4ce;
  --accent-wash: #e4f4f8;
  --accent-on-dark: #58d2e6;

  /* Linien & Schatten */
  --line: #dbe3e9;
  --line-strong: #c2ced8;
  --line-invert: rgba(255, 255, 255, 0.13);
  --shadow-sm: 0 1px 2px rgba(8, 19, 29, 0.05), 0 2px 8px rgba(8, 19, 29, 0.04);
  --shadow-md: 0 2px 6px rgba(8, 19, 29, 0.06), 0 14px 34px rgba(8, 19, 29, 0.08);
  --shadow-lg: 0 4px 12px rgba(8, 19, 29, 0.07), 0 30px 70px rgba(8, 19, 29, 0.14);

  /* Glaseffekt in Kopfzeile und Palette */
  --glass: rgba(255, 255, 255, 0.78);
  --glass-line: rgba(8, 19, 29, 0.08);

  /* Maße */
  --shell: 1240px;
  --shell-narrow: 780px;
  --gutter: clamp(20px, 5vw, 56px);
  --section-y: clamp(76px, 9vw, 136px);
  --r-xs: 4px;
  --r-sm: 8px;
  --r-md: 16px;
  --r-lg: 26px;
  --r-full: 999px;
  --header-h: 74px;

  /* Schrift */
  --font-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-sans: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* Bewegung */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --t-fast: 0.18s;
  --t-base: 0.32s;
  --t-slow: 0.7s;
}

/* Dunkelthema — greift automatisch nach Systemeinstellung, solange der
   Besucher nicht selbst umgeschaltet hat (dann steht data-theme am <html>). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { color-scheme: dark; }
}

:root[data-theme="dark"] { color-scheme: dark; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #070f16;
    --bg-sunken: #040a10;
    --bg-elev: #0e1b26;
    --bg-invert: #0e1b26;
    --bg-invert-elev: #16293a;

    --text: #e7f0f6;
    --text-soft: #9fb4c2;
    --text-faint: #758c9c;

    --accent: #58d2e6;
    --accent-hover: #86dfec;
    --accent-wash: rgba(27, 180, 206, 0.12);

    --line: rgba(255, 255, 255, 0.11);
    --line-strong: rgba(255, 255, 255, 0.2);

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 2px 6px rgba(0, 0, 0, 0.4), 0 14px 34px rgba(0, 0, 0, 0.36);
    --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.45), 0 30px 70px rgba(0, 0, 0, 0.5);

    --glass: rgba(10, 21, 30, 0.76);
    --glass-line: rgba(255, 255, 255, 0.1);
  }
}

:root[data-theme="dark"] {
  --bg: #070f16;
  --bg-sunken: #040a10;
  --bg-elev: #0e1b26;
  --bg-invert: #0e1b26;
  --bg-invert-elev: #16293a;

  --text: #e7f0f6;
  --text-soft: #9fb4c2;
  --text-faint: #758c9c;

  --accent: #58d2e6;
  --accent-hover: #86dfec;
  --accent-wash: rgba(27, 180, 206, 0.12);

  --line: rgba(255, 255, 255, 0.11);
  --line-strong: rgba(255, 255, 255, 0.2);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 2px 6px rgba(0, 0, 0, 0.4), 0 14px 34px rgba(0, 0, 0, 0.36);
  --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.45), 0 30px 70px rgba(0, 0, 0, 0.5);

  --glass: rgba(10, 21, 30, 0.76);
  --glass-line: rgba(255, 255, 255, 0.1);
}

/* ==========================================================================
   02  Reset & Basis
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color var(--t-base) var(--ease), color var(--t-base) var(--ease);
}

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

img { height: auto; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--t-fast) var(--ease);
}

a:hover { color: var(--accent-hover); }

button { font: inherit; color: inherit; }

::selection {
  background: var(--accent-vivid);
  color: var(--brand-ink);
}

:focus-visible {
  outline: 2px solid var(--accent-vivid);
  outline-offset: 3px;
  border-radius: var(--r-xs);
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  transform: translateY(-160%);
  padding: 12px 20px;
  border-radius: var(--r-sm);
  background: var(--brand-ink);
  color: #fff;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  transition: transform var(--t-base) var(--ease);
}

.skip-link:focus-visible {
  transform: translateY(0);
  color: #fff;
}

/* Feine Körnung über der ganzen Seite — nimmt Farbflächen das Digitale.
   Rein dekorativ, als Data-URI eingebettet (kein zusätzlicher Request). */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.032;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

:root[data-theme="dark"] body::after { opacity: 0.05; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) body::after { opacity: 0.05; }
}

/* ==========================================================================
   03  Typografie
   ========================================================================== */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  margin: 0;
  line-height: 1.07;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

p { margin: 0; }

.d-xl {
  font-size: clamp(2.8rem, 7.4vw, 5.6rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.95;
}

.d-l {
  font-size: clamp(2.05rem, 4.3vw, 3.4rem);
  font-weight: 700;
  letter-spacing: -0.032em;
  line-height: 1.03;
}

.d-m {
  font-size: clamp(1.5rem, 2.4vw, 2.05rem);
  font-weight: 700;
  letter-spacing: -0.022em;
}

.d-s {
  font-size: clamp(1.18rem, 1.7vw, 1.4rem);
  font-weight: 700;
  letter-spacing: -0.015em;
}

.lede {
  font-size: clamp(1.09rem, 1.35vw, 1.27rem);
  line-height: 1.6;
  color: var(--text-soft);
  max-width: 60ch;
  text-wrap: pretty;
}

/* Kleines Label über jeder Überschrift */
.meta {
  font-family: var(--font-mono);
  font-size: 0.71rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 0.65em;
  margin: 0;
}

.meta::before {
  content: "";
  width: 24px;
  height: 1px;
  background: currentColor;
  opacity: 0.55;
  flex: none;
}

.meta--plain::before { display: none; }

.prose p + p { margin-top: 1.05em; }
.prose strong { font-weight: 600; color: var(--text); }

/* Handschriftartige Signatur unter Fließtext */
.signature {
  font-family: var(--font-display);
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  display: grid;
  gap: 4px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.signature span {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* ==========================================================================
   04  Layout
   ========================================================================== */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
  position: relative;
  z-index: 2;
}

.shell--narrow { max-width: var(--shell-narrow); }

.sec {
  position: relative;
  padding-block: var(--section-y);
}

.sec--tight { padding-block: clamp(52px, 6vw, 84px); }
.sec--flush-top { padding-top: 0; }

.sec--sunken { background: var(--bg-sunken); }
.sec--elev { background: var(--bg-elev); }

.sec--dark {
  background: var(--brand-ink);
  color: var(--text-invert);
  isolation: isolate;
}

.sec--dark h1,
.sec--dark h2,
.sec--dark h3,
.sec--dark h4 { color: var(--text-invert); }

.sec--dark .lede,
.sec--dark p { color: var(--text-invert-soft); }

.sec--dark .meta { color: var(--accent-on-dark); }
.sec--dark a { color: var(--accent-on-dark); }
.sec--dark a:hover { color: var(--teal-300); }

/* Abschnittskopf: Überschrift links, Einleitung rechts */
.sec-head {
  display: grid;
  gap: clamp(20px, 3vw, 46px);
  align-items: end;
  margin-bottom: clamp(38px, 5vw, 68px);
}

@media (min-width: 900px) {
  .sec-head {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  }
}

.sec-head > div:first-child { display: grid; gap: 16px; justify-items: start; }

/* Zweispaltiges Text/Bild-Layout */
.split {
  display: grid;
  gap: clamp(36px, 5vw, 76px);
  align-items: center;
}

@media (min-width: 940px) {
  .split { grid-template-columns: minmax(0, 1fr) minmax(0, 0.88fr); }
  .split--flip > :first-child { order: 2; }
}

.split-copy { display: grid; gap: 22px; justify-items: start; }

/* Versetzt gestapelte Bilder */
.stack {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(2, 1fr);
}

.stack figure {
  margin: 0;
  overflow: hidden;
  border-radius: var(--r-md);
  box-shadow: var(--shadow-md);
}

.stack figure img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform var(--t-slow) var(--ease);
}

.stack figure:hover img { transform: scale(1.04); }
.stack figure:first-child { margin-top: clamp(20px, 5vw, 56px); }
.stack figure:last-child { margin-bottom: clamp(20px, 5vw, 56px); }

/* ==========================================================================
   05  Buttons & Links
   ========================================================================== */

.btn {
  --btn-bg: var(--brand-ink);
  --btn-fg: #ffffff;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  padding: 0.85em 1.5em;
  border: 1px solid transparent;
  border-radius: var(--r-full);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--font-sans);
  font-size: 0.97rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.2;
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-base) var(--ease),
              background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease),
              border-color var(--t-fast) var(--ease);
}

/* Türkiser Schleier, der beim Überfahren von links einläuft */
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--accent-vivid);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--t-base) var(--ease);
}

.btn:hover {
  color: var(--brand-ink);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn:hover::before { transform: scaleX(1); }
.btn:active { transform: translateY(0); }

.btn .arrow {
  width: 15px;
  height: 15px;
  flex: none;
  transition: transform var(--t-base) var(--ease);
}

.btn:hover .arrow { transform: translateX(4px); }

.btn--accent {
  --btn-bg: var(--accent-vivid);
  --btn-fg: var(--brand-ink);
}

.btn--accent::before { background: var(--brand-ink); }
.btn--accent:hover { color: #fff; }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--text);
  border-color: var(--line-strong);
}

.btn--ghost::before { background: var(--text); }
.btn--ghost:hover { color: var(--bg); border-color: var(--text); }

.btn--ghost-light {
  --btn-bg: rgba(255, 255, 255, 0.07);
  --btn-fg: #ffffff;
  border-color: rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(8px);
}

.btn--ghost-light::before { background: #ffffff; }
.btn--ghost-light:hover { color: var(--brand-ink); border-color: #ffffff; }

.btn--sm { padding: 0.6em 1.05em; font-size: 0.88rem; }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

/* Textlink mit nachlaufendem Pfeil */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-weight: 600;
  font-size: 0.97rem;
  color: var(--accent);
  padding-bottom: 3px;
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-size: 0% 1.5px;
  background-position: left bottom;
  transition: background-size var(--t-base) var(--ease), color var(--t-fast) var(--ease);
}

.link-arrow:hover { background-size: 100% 1.5px; }

.link-arrow svg {
  width: 15px;
  height: 15px;
  flex: none;
  transition: transform var(--t-base) var(--ease);
}
.link-arrow:hover svg { transform: translateX(4px); }

/* ==========================================================================
   06  Header, Navigation, Theme-Schalter
   ========================================================================== */

/* Ladefortschritt am oberen Rand */
.scroll-line {
  position: fixed;
  inset: 0 0 auto 0;
  height: 2px;
  z-index: 120;
  background: linear-gradient(90deg, var(--accent-vivid), var(--teal-300));
  transform: scaleX(var(--progress, 0));
  transform-origin: left center;
  pointer-events: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: transparent;
  transition: background-color var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease),
              backdrop-filter var(--t-base) var(--ease);
}

.site-header.is-stuck {
  background: var(--glass);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  box-shadow: 0 1px 0 var(--glass-line), var(--shadow-sm);
}

/* Auf Seiten mit dunklem Hero steht die Navigation zunächst auf dem Bild */
.site-header--over { color: #fff; }
.site-header--over .nav-link { color: rgba(255, 255, 255, 0.82); }
.site-header--over .nav-link:hover,
.site-header--over .nav-link[aria-current="page"] { color: #fff; }
.site-header--over .icon-btn { color: #fff; border-color: rgba(255, 255, 255, 0.26); }
.site-header--over .nav-toggle span { background: #fff; }
.site-header--over.is-stuck { color: var(--text); }
.site-header--over.is-stuck .nav-link { color: var(--text-soft); }
.site-header--over.is-stuck .nav-link:hover,
.site-header--over.is-stuck .nav-link[aria-current="page"] { color: var(--text); }
.site-header--over.is-stuck .icon-btn { color: var(--text); border-color: var(--line-strong); }
.site-header--over.is-stuck .nav-toggle span { background: var(--text); }

.nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 40px);
  min-height: var(--header-h);
}

.brand {
  display: block;
  flex: none;
  margin-right: auto;
  transition: opacity var(--t-fast) var(--ease);
}

.brand img { width: clamp(158px, 17vw, 208px); height: auto; }
.brand:hover { opacity: 0.78; }

/* Das Logo ist dunkel gezeichnet — auf dunklem Grund wird es aufgehellt */
.site-header--over .brand img,
.sec--dark .brand img,
.site-footer .brand img { filter: brightness(0) invert(1); }

.site-header--over.is-stuck .brand img { filter: none; }

:root[data-theme="dark"] .site-header .brand img { filter: brightness(0) invert(1); }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .site-header .brand img { filter: brightness(0) invert(1); }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.6vw, 22px);
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  position: relative;
  display: block;
  padding: 8px 4px;
  font-size: 0.97rem;
  font-weight: 500;
  color: var(--text-soft);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 4px;
  right: 4px;
  bottom: 2px;
  height: 1.5px;
  background: var(--accent-vivid);
  transform: scaleX(0);
  transform-origin: right center;
  transition: transform var(--t-base) var(--ease);
}

.nav-link:hover,
.nav-link[aria-current="page"] { color: var(--text); }

.nav-link:hover::after,
.nav-link[aria-current="page"]::after {
  transform: scaleX(1);
  transform-origin: left center;
}

.nav-end {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}

/* Runde Icon-Schaltflächen: Suche, Thema, Menü */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-full);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease),
              transform var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}

.icon-btn:hover {
  border-color: var(--accent-vivid);
  color: var(--accent);
  transform: translateY(-1px);
}

.icon-btn svg { width: 18px; height: 18px; flex: none; }

/* Suchschalter zeigt auf großen Screens das Tastenkürzel */
.search-btn { width: auto; padding-inline: 14px; }
.search-btn kbd {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 2px 6px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-xs);
  color: var(--text-faint);
}

@media (max-width: 1080px) {
  .search-btn { width: 40px; padding-inline: 0; }
  .search-btn kbd { display: none; }
}

/* Der Theme-Schalter blendet je nach Zustand Sonne oder Mond ein */
.theme-btn .icon-moon { display: none; }
:root[data-theme="dark"] .theme-btn .icon-moon { display: block; }
:root[data-theme="dark"] .theme-btn .icon-sun { display: none; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-btn .icon-moon { display: block; }
  :root:not([data-theme="light"]) .theme-btn .icon-sun { display: none; }
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-full);
  background: transparent;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 1.6px;
  width: 100%;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--t-base) var(--ease), opacity var(--t-fast) var(--ease);
}

body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(6.6px) rotate(45deg); }
body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-6.6px) rotate(-45deg); }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-end .btn { display: none; }

  .nav-links {
    position: fixed;
    inset: var(--header-h) 0 0 0;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    padding: 0 var(--gutter) 12vh;
    background: var(--bg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity var(--t-base) var(--ease), transform var(--t-base) var(--ease),
                visibility var(--t-base);
  }

  body.nav-open { overflow: hidden; }

  body.nav-open .nav-links {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav-link {
    font-family: var(--font-display);
    font-size: clamp(1.9rem, 8vw, 2.7rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text);
    padding: 10px 0;
    opacity: 0;
    transform: translateY(14px);
  }

  body.nav-open .nav-link {
    opacity: 1;
    transform: none;
    transition: opacity 0.4s var(--ease) calc(var(--i, 0) * 0.055s + 0.08s),
                transform 0.5s var(--ease) calc(var(--i, 0) * 0.055s + 0.08s);
  }

  .nav-link::after { display: none; }
  .nav-link[aria-current="page"] { color: var(--accent); }

  /* Im offenen Menü ist der Grund immer hell/dunkel nach Theme, nie das Bild.
     Auch die Kopfzeile selbst legt ihre Über-dem-Bild-Darstellung ab, sonst
     bliebe ein dunkler Streifen über der hellen Menüfläche stehen. */
  .site-header--over .nav-link,
  .site-header--over .nav-link:hover { color: var(--text); }
  .site-header--over .nav-link[aria-current="page"] { color: var(--accent); }

  /* backdrop-filter erzeugt einen eigenen Positionierungskontext für fixe
     Elemente — ohne diese Zeilen würde sich das Menü (position: fixed) bei
     bereits gescrollter, „angehefteter" Kopfzeile nur auf deren eigene,
     wenige Pixel hohe Fläche beziehen statt auf den ganzen Bildschirm.
     backdrop-filter muss dabei sofort wegfallen statt auszublenden — sonst
     bleibt der Positionierungskontext für die Dauer der Überblendung aktiv
     und das Menü baut sich erst klein auf, bevor es an die richtige Stelle
     springt. Background-Farbe und Schatten dürfen weiter sanft übergehen. */
  body.nav-open .site-header {
    background: var(--bg);
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    transition: background-color var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease);
  }

  body.nav-open .site-header--over { color: var(--text); }
  body.nav-open .site-header--over .icon-btn { color: var(--text); border-color: var(--line-strong); }
  body.nav-open .site-header--over .nav-toggle span { background: var(--text); }
  body.nav-open .site-header--over .brand img { filter: none; }

  /* Im Dunkelthema bleibt das Logo hell — dort passt die Umkehrung weiter. */
  :root[data-theme="dark"] body.nav-open .site-header--over .brand img {
    filter: brightness(0) invert(1);
  }
}

@media (max-width: 860px) and (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) body.nav-open .site-header--over .brand img {
    filter: brightness(0) invert(1);
  }
}

/* ==========================================================================
   07  Kommandopalette  (⌘K / Strg+K)
   ========================================================================== */

.palette {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: grid;
  align-items: start;
  justify-items: center;
  padding: clamp(60px, 12vh, 140px) var(--gutter) var(--gutter);
  background: rgba(8, 19, 29, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-base) var(--ease), visibility var(--t-base);
}

.palette.is-open { opacity: 1; visibility: visible; }

.palette-box {
  width: min(620px, 100%);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  transform: translateY(-14px) scale(0.98);
  transition: transform var(--t-base) var(--ease);
}

.palette.is-open .palette-box { transform: none; }

.palette-field {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.palette-field svg { width: 18px; height: 18px; color: var(--text-faint); flex: none; }

.palette-field input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1.05rem;
  padding: 0;
}

.palette-field input:focus { outline: none; }
.palette-field input::placeholder { color: var(--text-faint); }

.palette-esc {
  font-family: var(--font-mono);
  font-size: 0.67rem;
  letter-spacing: 0.06em;
  padding: 3px 7px;
  border: 1px solid var(--line);
  border-radius: var(--r-xs);
  color: var(--text-faint);
  flex: none;
}

.palette-list {
  list-style: none;
  margin: 0;
  padding: 8px;
  max-height: min(48vh, 400px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.palette-list li + li { margin-top: 2px; }

.palette-item {
  display: flex;
  align-items: center;
  gap: 13px;
  width: 100%;
  padding: 11px 12px;
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  text-align: left;
  color: var(--text);
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease);
}

.palette-item:hover,
.palette-item.is-active { background: var(--accent-wash); }

.palette-item .p-icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: none;
  border-radius: var(--r-sm);
  background: var(--bg-sunken);
  color: var(--accent);
}

.palette-item .p-icon svg { width: 16px; height: 16px; }

.palette-item b {
  display: block;
  font-weight: 600;
  font-size: 0.97rem;
  line-height: 1.3;
}

.palette-item small {
  display: block;
  font-size: 0.83rem;
  color: var(--text-faint);
  line-height: 1.4;
}

.palette-empty {
  padding: 26px 16px;
  text-align: center;
  color: var(--text-faint);
  font-size: 0.93rem;
}

.palette-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 11px 18px;
  border-top: 1px solid var(--line);
  background: var(--bg-sunken);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  color: var(--text-faint);
}

/* ==========================================================================
   08  Hero & Seitenkopf
   ========================================================================== */

.hero {
  position: relative;
  margin-top: calc(var(--header-h) * -1);
  padding-top: calc(var(--header-h) + clamp(72px, 13vh, 150px));
  padding-bottom: clamp(40px, 6vw, 72px);
  background: var(--brand-ink);
  color: var(--text-invert);
  overflow: hidden;
  isolation: isolate;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -3;
  overflow: hidden;
}

.hero-bg img {
  width: 100%;
  height: 118%;
  object-fit: cover;
  object-position: center 35%;
  opacity: 0.3;
  transform: translateY(calc(var(--par, 0px) * -1)) scale(1.06);
  will-change: transform;
}

/* Verlauf, der den Text vom Bild trennt */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(180deg, rgba(8, 19, 29, 0.92) 0%, rgba(8, 19, 29, 0.6) 40%, rgba(8, 19, 29, 0.97) 100%),
    linear-gradient(100deg, rgba(8, 19, 29, 0.95) 8%, rgba(8, 19, 29, 0.3) 70%);
}

/* Zwei weiche Lichtflecken in Türkis — geben Tiefe ohne Bilddatei */
.hero-glow {
  position: absolute;
  z-index: -1;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  opacity: 0.5;
}

.hero-glow--a {
  width: min(52vw, 620px);
  aspect-ratio: 1;
  top: -14%;
  right: -8%;
  background: radial-gradient(circle, rgba(27, 180, 206, 0.6), transparent 66%);
  animation: drift-a 22s var(--ease-in-out) infinite alternate;
}

.hero-glow--b {
  width: min(42vw, 480px);
  aspect-ratio: 1;
  bottom: -18%;
  left: -6%;
  background: radial-gradient(circle, rgba(12, 113, 134, 0.7), transparent 66%);
  animation: drift-b 27s var(--ease-in-out) infinite alternate;
}

@keyframes drift-a {
  to { transform: translate3d(-7%, 9%, 0) scale(1.12); }
}

@keyframes drift-b {
  to { transform: translate3d(9%, -8%, 0) scale(1.15); }
}

/* Feines Raster über dem Hero — zitiert Netzwerk/Infrastruktur */
.hero-grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.28;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 68px 68px;
  mask-image: radial-gradient(ellipse 75% 60% at 50% 40%, #000 20%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 75% 60% at 50% 40%, #000 20%, transparent 78%);
}

/* Fehlerseite: gleicher Hero, nur ohne Hintergrundbild */
.hero--404 {
  min-height: 78vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--brand-ink);
}

.hero--404::before {
  background: linear-gradient(160deg, rgba(8, 19, 29, 0.2), rgba(8, 19, 29, 0.85));
}

.hero--404 .fact dd a { color: var(--text-invert); }
.hero--404 .fact dd a:hover { color: var(--accent-on-dark); }

.hero-inner {
  display: grid;
  gap: clamp(30px, 4vw, 52px);
  padding-bottom: clamp(44px, 6vw, 80px);
}

.hero h1,
.hero h2 { color: var(--text-invert); }

.hero-copy { display: grid; gap: 24px; justify-items: start; max-width: 21ch; }
.hero-copy .lede { color: var(--text-invert-soft); max-width: 54ch; }
.hero-copy .meta { color: var(--accent-on-dark); }

@media (min-width: 800px) {
  .hero-copy { max-width: none; }
  .hero-copy .d-xl { max-width: 13ch; }
}

/* Türkis hervorgehobenes Wort in der Hauptzeile */
.hl {
  position: relative;
  color: var(--accent-vivid);
  white-space: nowrap;
}

.hl::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.06em;
  height: 0.075em;
  background: currentColor;
  opacity: 0.32;
  transform: scaleX(0);
  transform-origin: left center;
  animation: underline-in 0.9s var(--ease) 0.9s forwards;
}

@keyframes underline-in { to { transform: scaleX(1); } }

/* Kennzahlenleiste unter dem Hero */
.facts {
  display: grid;
  gap: 1px;
  margin: 0;
  background: var(--line-invert);
  border-top: 1px solid var(--line-invert);
  border-bottom: 1px solid var(--line-invert);
}

@media (min-width: 720px) {
  .facts { grid-template-columns: repeat(3, 1fr); }
}

.fact {
  display: grid;
  gap: 8px;
  align-content: start;
  padding: clamp(22px, 3vw, 32px) clamp(18px, 2.4vw, 30px);
  background: var(--brand-ink);
  transition: background-color var(--t-base) var(--ease);
}

.fact:hover { background: var(--bg-invert-elev); }

.fact dt {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-on-dark);
}

.fact dd {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.18rem, 1.9vw, 1.45rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-invert);
  line-height: 1.2;
}

.fact small {
  font-size: 0.86rem;
  line-height: 1.45;
  color: var(--text-invert-faint);
}

/* Erreichbarkeits-Punkt */
.avail {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: inherit;
}

.avail .dot {
  position: relative;
  width: 9px;
  height: 9px;
  flex: none;
  border-radius: 50%;
  background: var(--text-faint);
}

.avail[data-state="open"] .dot { background: #34d399; }
.avail[data-state="soon"] .dot { background: #fbbf24; }
.avail[data-state="closed"] .dot { background: #94a3b8; }

/* Nur im Zustand „jetzt erreichbar“ pulsiert der Punkt */
.avail[data-state="open"] .dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1.5px solid #34d399;
  animation: ping 2.1s var(--ease-in-out) infinite;
}

@keyframes ping {
  0% { transform: scale(0.7); opacity: 0.9; }
  75%, 100% { transform: scale(1.7); opacity: 0; }
}

/* Seitenkopf der Unterseiten */
.page-hero {
  position: relative;
  margin-top: calc(var(--header-h) * -1);
  padding-top: calc(var(--header-h) + clamp(58px, 11vh, 118px));
  padding-bottom: clamp(38px, 6vw, 72px);
  background: var(--bg-sunken);
  overflow: hidden;
  isolation: isolate;
}

.page-hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -55%;
  right: -12%;
  width: min(58vw, 640px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-wash), transparent 68%);
  pointer-events: none;
}

.page-hero-inner { display: grid; gap: 20px; justify-items: start; }

/* Brotkrumen */
.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  list-style: none;
  margin: 0 0 4px;
  padding: 0;
  font-family: var(--font-mono);
  font-size: 0.71rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.crumbs li { display: flex; align-items: center; gap: 8px; }
.crumbs li + li::before { content: "/"; opacity: 0.5; }
.crumbs a { color: var(--text-faint); }
.crumbs a:hover { color: var(--accent); }
.crumbs [aria-current] { color: var(--text); }

/* ==========================================================================
   09  Inhaltsbausteine
   ========================================================================== */

/* --- Werte-Raster ------------------------------------------------------- */

.values {
  display: grid;
  gap: clamp(18px, 2vw, 26px);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 262px), 1fr));
}

.value {
  position: relative;
  display: grid;
  gap: 13px;
  align-content: start;
  padding: clamp(24px, 3vw, 34px);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  isolation: isolate;
  transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease),
              border-color var(--t-base) var(--ease);
}

/* Lichtkegel folgt dem Mauszeiger (Koordinaten kommen aus main.js) */
.value::before,
.card::before,
.ref::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), var(--accent-wash), transparent 62%);
  transition: opacity var(--t-base) var(--ease);
}

.value:hover,
.ref:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}

.value:hover::before,
.card:hover::before,
.ref:hover::before { opacity: 1; }

.value-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: var(--r-sm);
  background: var(--accent-wash);
  color: var(--accent);
  margin-bottom: 4px;
  transition: transform var(--t-base) var(--ease);
  will-change: transform;
}

/* Die Rotation ist bewusst raus: Bei einem so kleinen Icon mit dünnen
   Strichen (siehe .value-icon svg) berechnet der Browser während einer
   Drehung die Kantenglättung jeden Frame neu — das sah beim Verlassen des
   Hovers wie ein Wackeln aus, unabhängig von der Bildwiederholrate. */
.value:hover .value-icon { transform: scale(1.08); }
.value-icon svg { width: 21px; height: 21px; }

.value h3 { font-size: 1.13rem; letter-spacing: -0.018em; }
.value p { font-size: 0.97rem; color: var(--text-soft); }

/* Nummerierte Variante für „Warum“-Abschnitte */
.value--numbered .value-num {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  color: var(--accent);
}

/* --- Bildkarten --------------------------------------------------------- */

.cards {
  display: grid;
  gap: clamp(18px, 2vw, 26px);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 262px), 1fr));
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  isolation: isolate;
  transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease),
              border-color var(--t-base) var(--ease);
}

.sec--dark .card {
  background: var(--bg-invert-elev);
  border-color: var(--line-invert);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--line-strong);
}

.card-media { overflow: hidden; background: var(--bg-sunken); }

.card-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform var(--t-slow) var(--ease), filter var(--t-slow) var(--ease);
}

.card:hover .card-media img { transform: scale(1.06); }

.card-body {
  display: grid;
  gap: 9px;
  align-content: start;
  padding: clamp(20px, 2.4vw, 28px);
  flex: 1;
}

.card-body h3 { font-size: 1.1rem; letter-spacing: -0.018em; }
.card-body p { font-size: 0.96rem; color: var(--text-soft); }
.sec--dark .card-body p { color: var(--text-invert-soft); }

/* Stichpunkte mit Haken unter dem Kartentext */
.ticks {
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
  display: grid;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.sec--dark .ticks { border-color: var(--line-invert); }

.ticks li {
  position: relative;
  padding-left: 25px;
  font-size: 0.91rem;
  line-height: 1.45;
  color: var(--text-faint);
}

/* Haken als reines CSS — kein zusätzliches Markup, kein Bild */
.ticks li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0.42em;
  width: 9px;
  height: 5px;
  border-left: 1.8px solid var(--accent);
  border-bottom: 1.8px solid var(--accent);
  transform: rotate(-45deg);
}

/* Kleines Kennzeichen oben auf der Karte */
.card-tag {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: var(--r-full);
  background: rgba(8, 19, 29, 0.72);
  color: #fff;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

/* --- Referenzkarten ----------------------------------------------------- */

.ref {
  position: relative;
  display: grid;
  gap: 12px;
  align-content: start;
  padding: clamp(26px, 3vw, 38px);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  isolation: isolate;
  transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease),
              border-color var(--t-base) var(--ease);
}

.ref h3 { font-size: 1.28rem; }
.ref p { color: var(--text-soft); font-size: 0.97rem; }
.ref .link-arrow { margin-top: 4px; justify-self: start; }

.ref-year {
  font-family: var(--font-mono);
  font-size: 0.69rem;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* --- Kennzahlen --------------------------------------------------------- */

.stats {
  display: grid;
  gap: clamp(20px, 3vw, 34px);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr));
  padding-top: clamp(26px, 3vw, 38px);
  border-top: 1px solid var(--line);
}

.sec--dark .stats { border-color: var(--line-invert); }

.stat { display: grid; gap: 5px; }

.stat b {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3.1vw, 2.45rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1;
  color: var(--text);
}

.sec--dark .stat b { color: var(--text-invert); }

/* Nur die Bildunterschrift treffen, nicht das <span data-count> im <b> darüber */
.stat > span {
  font-size: 0.88rem;
  line-height: 1.4;
  color: var(--text-faint);
}

.stats--compact { border-top: 0; padding-top: 0; gap: 20px; }
.stats--compact .stat b { font-size: clamp(1.3rem, 2.1vw, 1.6rem); }

/* --- Zeitstrahl / Ablauf ------------------------------------------------ */

.steps {
  position: relative;
  display: grid;
  gap: clamp(26px, 3.4vw, 42px);
  padding-left: clamp(30px, 4vw, 52px);
}

/* Graue Grundlinie … */
.steps::before {
  content: "";
  position: absolute;
  left: clamp(9px, 1.2vw, 15px);
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--line);
  border-radius: 2px;
}

/* … und der türkise Teil, der beim Scrollen mitwächst (--fill aus main.js) */
.steps::after {
  content: "";
  position: absolute;
  left: clamp(9px, 1.2vw, 15px);
  top: 8px;
  width: 2px;
  height: calc((100% - 16px) * var(--fill, 0));
  background: linear-gradient(180deg, var(--accent-vivid), var(--accent));
  border-radius: 2px;
  transition: height 0.18s linear;
}

.step { position: relative; display: grid; gap: 9px; }

.step::before {
  content: "";
  position: absolute;
  left: calc(clamp(30px, 4vw, 52px) * -1 + clamp(4px, 0.75vw, 10px));
  top: 7px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--line-strong);
  transition: border-color var(--t-base) var(--ease), background-color var(--t-base) var(--ease),
              transform var(--t-base) var(--ease);
}

.step.is-active::before {
  border-color: var(--accent-vivid);
  background: var(--accent-vivid);
  transform: scale(1.25);
}

.step-num {
  font-family: var(--font-mono);
  font-size: 0.71rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  color: var(--text-faint);
  transition: color var(--t-base) var(--ease);
}

.step.is-active .step-num { color: var(--accent); }
.step h3 { font-size: 1.2rem; }
.step p { color: var(--text-soft); max-width: 62ch; font-size: 0.99rem; }

/* --- FAQ ---------------------------------------------------------------- */

.faq {
  display: grid;
  border-top: 1px solid var(--line);
}

.faq-item { border-bottom: 1px solid var(--line); }

.faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
  padding: clamp(19px, 2.2vw, 26px) 0;
  border: 0;
  background: transparent;
  font-family: var(--font-display);
  font-size: clamp(1.03rem, 1.6vw, 1.22rem);
  font-weight: 700;
  letter-spacing: -0.018em;
  line-height: 1.32;
  text-align: left;
  color: var(--text);
  cursor: pointer;
  transition: color var(--t-fast) var(--ease);
}

.faq-q:hover { color: var(--accent); }

.faq-icon {
  position: relative;
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  transition: background-color var(--t-base) var(--ease), border-color var(--t-base) var(--ease),
              transform var(--t-base) var(--ease);
}

.faq-icon::before,
.faq-icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 9px;
  height: 1.6px;
  background: currentColor;
  border-radius: 2px;
  transform: translate(-50%, -50%);
  transition: transform var(--t-base) var(--ease), opacity var(--t-fast) var(--ease);
}

.faq-icon::after { transform: translate(-50%, -50%) rotate(90deg); }

.faq-q[aria-expanded="true"] .faq-icon {
  background: var(--accent-vivid);
  border-color: var(--accent-vivid);
  color: var(--brand-ink);
  transform: rotate(180deg);
}

.faq-q[aria-expanded="true"] .faq-icon::after { opacity: 0; }

.faq-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows var(--t-base) var(--ease);
}

.faq-q[aria-expanded="true"] + .faq-a { grid-template-rows: 1fr; }

.faq-a > div { overflow: hidden; }

.faq-a p {
  padding-bottom: clamp(20px, 2.2vw, 26px);
  color: var(--text-soft);
  max-width: 74ch;
}

/* Ohne JavaScript bleiben alle Antworten offen und lesbar */
html:not(.js) .faq-a { grid-template-rows: 1fr; }
html:not(.js) .faq-icon { display: none; }

/* --- Zitatfläche -------------------------------------------------------- */

.quote {
  position: relative;
  display: grid;
  place-items: center;
  min-height: clamp(300px, 42vw, 430px);
  padding: clamp(40px, 6vw, 78px);
  border-radius: var(--r-lg);
  overflow: hidden;
  isolation: isolate;
  background: var(--brand-ink);
}

.quote img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.34;
  transform: scale(1.04);
  transition: transform 1.2s var(--ease);
}

.quote:hover img { transform: scale(1.09); }

.quote::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(135deg, rgba(8, 19, 29, 0.9), rgba(8, 19, 29, 0.55) 55%, rgba(11, 95, 112, 0.7));
}

.quote blockquote {
  margin: 0;
  max-width: 21ch;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4.1vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.032em;
  line-height: 1.12;
  color: #fff;
  text-align: center;
  text-wrap: balance;
}

.quote cite {
  display: block;
  margin-top: 22px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  font-style: normal;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-on-dark);
}

/* --- Laufband ----------------------------------------------------------- */

.marquee {
  position: relative;
  display: flex;
  overflow: hidden;
  padding-block: 16px;
  background: var(--brand-ink);
  border-block: 1px solid var(--line-invert);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}

.marquee-track {
  display: flex;
  flex: none;
  align-items: center;
  gap: 42px;
  padding-right: 42px;
  animation: marquee 42s linear infinite;
}

.marquee:hover .marquee-track { animation-play-state: paused; }

@keyframes marquee { to { transform: translateX(-100%); } }

.marquee-track span {
  display: inline-flex;
  align-items: center;
  gap: 42px;
  flex: none;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--text-invert-soft);
  white-space: nowrap;
}

.marquee-track span::after {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-vivid);
  flex: none;
}

/* --- Abschluss-Band ----------------------------------------------------- */

.cta-band {
  position: relative;
  background: var(--brand-ink);
  color: var(--text-invert);
  overflow: hidden;
  isolation: isolate;
}

.cta-band::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -40% -10% auto auto;
  width: min(60vw, 660px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(27, 180, 206, 0.32), transparent 66%);
  filter: blur(70px);
  pointer-events: none;
}

.cta-band h2 { color: var(--text-invert); }
.cta-band p { color: var(--text-invert-soft); }
.cta-band .meta { color: var(--accent-on-dark); }

.cta-inner {
  display: grid;
  gap: clamp(28px, 4vw, 54px);
  align-items: center;
}

@media (min-width: 900px) {
  .cta-inner { grid-template-columns: minmax(0, 1.25fr) auto; }
}

.cta-inner > div:first-child { display: grid; gap: 16px; justify-items: start; }

/* ==========================================================================
   10  Sonderbausteine
   ========================================================================== */

/* --- Datenschutz-Check --------------------------------------------------
   Misst im Browser des Besuchers, wie viele Anfragen diese Seite an fremde
   Server stellt, und zeigt das Ergebnis. Die Zahlen kommen aus der
   Performance-API des Browsers, es wird nichts übertragen oder gespeichert. */

.privacy {
  display: grid;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}

@media (min-width: 940px) {
  .privacy { grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); }
}

.privacy-copy { display: grid; gap: 18px; justify-items: start; }

.privacy-panel {
  position: relative;
  padding: clamp(22px, 3vw, 32px);
  border: 1px solid var(--line-invert);
  border-radius: var(--r-md);
  background: var(--bg-invert-elev);
  overflow: hidden;
  isolation: isolate;
}

.privacy-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.4;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 34px 34px;
}

.privacy-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--line-invert);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-invert-faint);
}

.privacy-head .live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-on-dark);
}

.privacy-head .live::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #34d399;
  animation: blink 2.4s var(--ease-in-out) infinite;
}

@keyframes blink { 50% { opacity: 0.25; } }

.privacy-rows { display: grid; gap: 2px; }

.privacy-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 14px;
  padding: 11px 0;
}

.privacy-row + .privacy-row { border-top: 1px solid var(--line-invert); }

.privacy-row dt {
  font-size: 0.94rem;
  color: var(--text-invert-soft);
}

.privacy-row dd {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text-invert);
}

/* Häkchen bzw. Warndreieck neben dem Wert */
.privacy-row dd .mark {
  display: grid;
  place-items: center;
  width: 19px;
  height: 19px;
  flex: none;
  border-radius: 50%;
  background: rgba(52, 211, 153, 0.16);
  color: #34d399;
  font-size: 0.72rem;
  line-height: 1;
}

.privacy-row[data-ok="false"] dd .mark {
  background: rgba(251, 191, 36, 0.16);
  color: #fbbf24;
}

.privacy-note {
  margin-top: 16px;
  padding-top: 15px;
  border-top: 1px solid var(--line-invert);
  font-size: 0.84rem;
  line-height: 1.5;
  color: var(--text-invert-faint);
}

/* Kleine Abzeichen für „0 Cookies“ etc. */
.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  background: var(--bg-elev);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.badge svg { width: 13px; height: 13px; color: var(--accent); flex: none; }

.sec--dark .badge {
  background: var(--bg-invert-elev);
  border-color: var(--line-invert);
  color: var(--text-invert-soft);
}

.sec--dark .badge svg { color: var(--accent-on-dark); }

.hero .badge,
.site-footer .badge {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.18);
  color: var(--text-invert-soft);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.hero .badge svg,
.site-footer .badge svg { color: var(--accent-on-dark); }

/* --- Anfahrtsrechner ----------------------------------------------------
   Rechnet die Anfahrtspauschale direkt im Browser aus. Keine Karte, keine
   Adresse, keine Anfrage nach außen — nur ein Schieberegler. */

.calc {
  display: grid;
  gap: clamp(26px, 3.5vw, 46px);
  padding: clamp(26px, 3.6vw, 44px);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-md);
}

@media (min-width: 860px) {
  .calc { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); align-items: center; }
}

.calc-controls { display: grid; gap: 20px; align-content: start; }

.calc-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 0.71rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.calc-label output {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
}

/* Schieberegler in Markenfarben, in beiden Engines gleich */
.calc input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  margin: 0;
  border-radius: var(--r-full);
  background: linear-gradient(90deg, var(--accent-vivid) var(--pct, 25%), var(--line-strong) var(--pct, 25%));
  cursor: pointer;
}

.calc input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg-elev);
  border: 3px solid var(--accent-vivid);
  box-shadow: var(--shadow-sm);
  cursor: grab;
  transition: transform var(--t-fast) var(--ease);
}

.calc input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.14); }

.calc input[type="range"]::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg-elev);
  border: 3px solid var(--accent-vivid);
  box-shadow: var(--shadow-sm);
  cursor: grab;
}

.calc-scale {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  color: var(--text-faint);
}

.calc-hint { font-size: 0.89rem; color: var(--text-faint); line-height: 1.5; }

.calc-result {
  display: grid;
  gap: 6px;
  padding: clamp(22px, 3vw, 30px);
  border-radius: var(--r-md);
  background: var(--brand-ink);
  color: var(--text-invert);
  text-align: center;
}

.calc-result .meta { color: var(--accent-on-dark); justify-self: center; }

.calc-result b {
  font-family: var(--font-display);
  font-size: clamp(2.3rem, 5vw, 3.1rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
  margin-top: 8px;
  font-variant-numeric: tabular-nums;
}

.calc-result small {
  font-size: 0.87rem;
  line-height: 1.45;
  color: var(--text-invert-faint);
}

/* --- Kontaktkacheln ------------------------------------------------------ */

.contact-grid {
  display: grid;
  gap: clamp(16px, 2vw, 22px);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 232px), 1fr));
}

.contact-card {
  position: relative;
  display: grid;
  gap: 10px;
  align-content: start;
  margin: 0;
  padding: clamp(22px, 2.6vw, 30px);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  transition: transform var(--t-base) var(--ease), border-color var(--t-base) var(--ease),
              box-shadow var(--t-base) var(--ease);
}

.contact-card:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}

.contact-card dt {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: 0.69rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.contact-card dt svg { width: 15px; height: 15px; flex: none; }

.contact-card dd {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1rem, 1.5vw, 1.12rem);
  font-weight: 700;
  letter-spacing: -0.018em;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.contact-card dd a { color: var(--text); }
.contact-card dd a:hover { color: var(--accent); }

/* Die E-Mail-Adresse ist deutlich länger als Telefonnummer und WhatsApp —
   etwas kleiner gesetzt, damit die Kachel nicht aus der Reihe tanzt und der
   Umbruch (siehe <wbr> im Markup) sauber hinter dem @ liegt statt mitten im
   Domainnamen. */
.contact-value--email {
  font-size: clamp(0.86rem, 1.25vw, 1rem);
  letter-spacing: -0.008em;
}

/* Kopierschaltfläche in der Kachel */
.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  background: transparent;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
  cursor: pointer;
  justify-self: start;
  transition: color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}

.copy-btn:hover { color: var(--accent); border-color: var(--accent-vivid); }
.copy-btn.is-done { color: #34d399; border-color: #34d399; }
.copy-btn svg { width: 12px; height: 12px; flex: none; }

/* --- Zurück-nach-oben ---------------------------------------------------- */

.to-top {
  position: fixed;
  right: clamp(16px, 3vw, 30px);
  bottom: clamp(16px, 3vw, 30px);
  z-index: 90;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  box-shadow: var(--shadow-md);
  transition: opacity var(--t-base) var(--ease), transform var(--t-base) var(--ease),
              visibility var(--t-base), color var(--t-fast) var(--ease),
              border-color var(--t-fast) var(--ease);
}

.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { color: var(--accent); border-color: var(--accent-vivid); }
.to-top svg { width: 17px; height: 17px; }

/* Kurze Rückmeldung nach dem Kopieren, für Screenreader und Auge */
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  z-index: 160;
  transform: translate(-50%, 18px);
  padding: 11px 20px;
  border-radius: var(--r-full);
  background: var(--brand-ink);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-base) var(--ease), transform var(--t-base) var(--ease),
              visibility var(--t-base);
}

.toast.is-visible { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* ==========================================================================
   11  Formular
   ========================================================================== */

.form-panel {
  padding: clamp(28px, 4vw, 52px);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-md);
}

.form {
  display: grid;
  gap: 20px;
  margin-top: clamp(26px, 3vw, 36px);
}

@media (min-width: 680px) {
  .form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .field--full { grid-column: 1 / -1; }
}

.field { display: grid; gap: 8px; }

.field label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1rem;
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease),
              background-color var(--t-fast) var(--ease);
}

.field textarea { min-height: 156px; resize: vertical; }

.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: var(--accent-vivid);
  background: var(--bg-elev);
  box-shadow: 0 0 0 3px var(--accent-wash);
}

.field input::placeholder,
.field textarea::placeholder { color: var(--text-faint); }

/* Einwilligung vor dem Absenden */
.consent {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--text-soft);
  cursor: pointer;
}

.consent input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 3px 0 0;
  flex: none;
  accent-color: var(--accent-vivid);
  cursor: pointer;
}

.form-note {
  margin-top: 14px;
  font-size: 0.86rem;
  line-height: 1.55;
  color: var(--text-faint);
}

/* Bestätigung nach erfolgreichem Versand (?gesendet=1) */
.form-sent {
  display: none;
  align-items: flex-start;
  gap: 13px;
  margin-bottom: 26px;
  padding: 17px 20px;
  border: 1px solid rgba(52, 211, 153, 0.4);
  border-radius: var(--r-sm);
  background: rgba(52, 211, 153, 0.1);
  color: var(--text);
  font-size: 0.96rem;
  line-height: 1.5;
}

.form-sent.is-visible { display: flex; }
.form-sent svg { width: 20px; height: 20px; color: #34d399; flex: none; margin-top: 2px; }

/* ==========================================================================
   12  Footer & Rechtstexte
   ========================================================================== */

.site-footer {
  position: relative;
  padding-block: clamp(56px, 7vw, 88px) 30px;
  background: var(--brand-ink);
  color: var(--text-invert-soft);
  overflow: hidden;
  isolation: isolate;
}

.site-footer::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: auto auto -50% -10%;
  width: min(60vw, 600px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(27, 180, 206, 0.16), transparent 68%);
  filter: blur(70px);
  pointer-events: none;
}

.footer-grid {
  display: grid;
  gap: clamp(30px, 4vw, 52px);
  padding-bottom: clamp(34px, 4vw, 52px);
}

@media (min-width: 760px) {
  .footer-grid { grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr)); }
}

.footer-brand { display: grid; gap: 18px; align-content: start; justify-items: start; max-width: 42ch; }
.footer-brand p { font-size: 0.93rem; line-height: 1.6; color: var(--text-invert-faint); }

.site-footer h2 {
  font-family: var(--font-mono);
  font-size: 0.69rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-on-dark);
  margin-bottom: 16px;
}

.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer li { font-size: 0.93rem; line-height: 1.5; color: var(--text-invert-faint); }

.site-footer a { color: var(--text-invert-soft); }
.site-footer a:hover { color: var(--accent-on-dark); }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 26px;
  padding-top: 24px;
  border-top: 1px solid var(--line-invert);
  font-family: var(--font-mono);
  font-size: 0.71rem;
  letter-spacing: 0.08em;
  color: var(--text-invert-faint);
}

/* Rechtstexte: schmale Spalte, ruhige Typo */
.legal {
  max-width: 76ch;
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text-soft);
}

.legal h2 {
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  margin: 2.2em 0 0.6em;
  color: var(--text);
}

.legal h3 {
  font-size: 1.08rem;
  margin: 1.8em 0 0.5em;
  color: var(--text);
}

.legal h2:first-child,
.legal h3:first-child { margin-top: 0; }

.legal p { margin: 0 0 1.05em; }
.legal ul,
.legal ol { margin: 0 0 1.2em; padding-left: 1.35em; }
.legal li { margin-bottom: 0.45em; }
.legal strong { color: var(--text); font-weight: 600; }
.legal a { overflow-wrap: anywhere; }

.legal table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.4em;
  font-size: 0.94rem;
}

.legal th,
.legal td {
  padding: 11px 14px;
  border: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.legal th { background: var(--bg-sunken); color: var(--text); font-weight: 600; }

/* Inhaltsverzeichnis über langen Rechtstexten */
.toc {
  padding: clamp(20px, 2.6vw, 28px);
  margin-bottom: clamp(30px, 4vw, 46px);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}

.toc h2 {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin: 0 0 14px;
}

.toc ol {
  list-style: none;
  counter-reset: toc;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.toc li { counter-increment: toc; margin: 0; }

.toc a {
  display: flex;
  gap: 11px;
  font-size: 0.95rem;
  color: var(--text-soft);
}

.toc a::before {
  content: counter(toc, decimal-leading-zero);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent);
  flex: none;
  padding-top: 2px;
}

.toc a:hover { color: var(--accent); }

.legal code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  padding: 2px 6px;
  border-radius: var(--r-xs);
  background: var(--bg-sunken);
  color: var(--text);
}

/* Redaktioneller Hinweis am Ende eines Rechtstextes */
.legal-note {
  margin-top: 2.5em;
  padding-top: 1.2em;
  border-top: 1px solid var(--line);
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--text-faint);
}

/* ==========================================================================
   13  Bewegung
   --------------------------------------------------------------------------
   Grundregel: Ohne JavaScript ist alles sofort sichtbar. Die Startzustände
   hängen deshalb an html.js — die Klasse setzt ein Inline-Skript im <head>.
   ========================================================================== */

/* Zeilenweises Einfahren der Hauptüberschrift */
.line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.06em;
  margin-bottom: -0.06em;
}

.js .line > span {
  display: block;
  transform: translateY(105%);
  animation: line-in 0.95s var(--ease) forwards;
  animation-delay: calc(var(--i, 0) * 0.1s + 0.1s);
}

@keyframes line-in { to { transform: translateY(0); } }

/* Elemente, die beim Laden nachziehen */
.js .fade-up {
  opacity: 0;
  transform: translateY(20px);
  animation: fade-up 0.8s var(--ease) forwards;
  animation-delay: calc(var(--i, 0) * 0.09s + 0.25s);
}

@keyframes fade-up {
  to { opacity: 1; transform: none; }
}

/* Elemente, die beim Scrollen einblenden (IntersectionObserver in main.js).
   Bewusst KEIN will-change hier: Auf dieser Seite haben oft 40+ Elemente
   gleichzeitig data-reveal. will-change auf all diesen Elementen dauerhaft
   zu setzen, erzeugt entsprechend viele eigene Ebenen, die über die ganze
   Lebensdauer der Seite bestehen bleiben — das kostet GPU-Speicher, und der
   Browser muss diese Ebenen unter Speicherdruck (v. a. auf dem Handy)
   irgendwann neu anlegen. Genau das sah wie ein wiederholtes Aufblitzen
   des Texts aus, lange nachdem die Einblend-Animation längst vorbei war.
   Bewusst auch KEIN translateY mehr: Der Versatz ließ Überschriften und
   Absätze beim Einblenden sichtbar "rutschen" — reines Opacity-Fade wirkt
   ruhiger und lässt keinen Bewegungs-Eindruck mehr entstehen. */
.js [data-reveal] {
  opacity: 0;
  transition: opacity 0.6s var(--ease);
  transition-delay: calc(var(--i, 0) * 0.075s);
}

.js [data-reveal].is-in { opacity: 1; }

/* Weicher Übergang zwischen den Seiten, wo der Browser ihn unterstützt */
@view-transition { navigation: auto; }

::view-transition-old(root) { animation: vt-out 0.2s var(--ease) both; }
::view-transition-new(root) { animation: vt-in 0.32s var(--ease) both; }

@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; transform: translateY(8px); } }

/* ==========================================================================
   14  Utilities, Reduced Motion, Druck
   ========================================================================== */

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

/* Ohne JavaScript haben Suche, Themenschalter und Zurück-nach-oben keine
   Funktion — sie werden dann gar nicht erst angezeigt. */
html:not(.js) .search-btn,
html:not(.js) .theme-btn,
html:not(.js) .to-top,
html:not(.js) .palette,
html:not(.js) .copy-btn,
html:not(.js) .toast { display: none !important; }

/* Der Anfahrtsrechner braucht JavaScript; ohne zeigt er den festen Hinweis. */
html:not(.js) .calc-result b { font-size: 1.4rem; }

.stack-sm { display: grid; gap: 16px; justify-items: start; }
.stack-md { display: grid; gap: 22px; justify-items: start; }

/* Wer „Bewegung reduzieren“ eingestellt hat, sieht alles sofort und ruhig. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .js .line > span,
  .js .fade-up,
  .js [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }

  .hero-glow--a,
  .hero-glow--b,
  .marquee-track,
  .avail .dot::after,
  .privacy-head .live::before { animation: none !important; }

  .hero-bg img { transform: none !important; }

  @view-transition { navigation: none; }
}

@media print {
  .site-header,
  .site-footer,
  .scroll-line,
  .to-top,
  .palette,
  .marquee,
  .cta-band,
  .skip-link { display: none !important; }

  body { background: #fff; color: #000; }
  body::after { display: none; }

  .sec { padding-block: 18px; }
  .legal { max-width: none; }
  a { color: #000; text-decoration: underline; }
}
