/* ==========================================================================
   VN Animation - Demo
   Aufbau: 1 Grundlagen | 2 Kopf/Hero | 3 Abschnitte | 4 Staffelung (Bausteine)
           5 Beim Scrollen (Bausteine) | 6 Einstellungen | 7 Wissen/Fuss
           8 Laufzeit-Zustaende (Staffelung + Scroll) | 9 Handy
   Hinweis: Anfangszustaende der Animation gelten NUR, wenn anim.js die
   Klasse "vn-anim" gesetzt hat. Ohne JavaScript oder mit "Bewegung
   reduzieren" bleibt alles im Endzustand sichtbar.
   ========================================================================== */

/* ---------- 1 Grundlagen ---------- */

:root {
  --ink: #0d1117;
  --ink-2: #161c25;
  --ink-3: #212a36;
  --paper: #f5f1e8;
  --paper-2: #ebe5d6;
  --slate: #1a2230;
  --amber: #f2a65a;
  --amber-deep: #b4540b;
  --text-dark: #e9edf2;
  --muted-dark: #a3afbd;
  --muted-light: #566170;
  --font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Roboto, Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, "SFMono-Regular", Menlo, monospace;
  --ease-out: cubic-bezier(0.22, 0.8, 0.26, 1);
  --ease-pop: cubic-bezier(0.34, 1.7, 0.5, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 76px;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--ink);
  overflow-x: clip;
}

img {
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

p {
  margin: 0;
}

a {
  color: inherit;
}

code {
  font-family: var(--mono);
  font-size: 0.88em;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.1em 0.4em;
  border-radius: 6px;
}

:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 3px;
}

.wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 40px);
}

.vn-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.noscript {
  margin: 0;
  padding: 12px 16px;
  background: var(--amber);
  color: var(--ink);
  text-align: center;
  font-weight: 600;
}

/* ---------- 2 Kopf, Fortschritt, Schwebefeld, Hero ---------- */

.progress {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 70;
  height: 4px;
  background: rgba(255, 255, 255, 0.12);
}

.vn-anim .progress {
  display: block;
}

.progress i {
  display: block;
  height: 100%;
  background: var(--amber);
  transform-origin: 0 50%;
  transform: scaleX(var(--page, 0));
}

.top {
  position: fixed;
  top: 4px;
  left: 0;
  right: 0;
  z-index: 60;
  height: 56px;
  background: rgba(13, 17, 23, 0.78);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #fff;
}

.top-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 40px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
}

.brand small {
  font-weight: 600;
  color: var(--muted-dark);
}

.brand-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 4px rgba(242, 166, 90, 0.25);
}

.top-nav {
  display: flex;
  gap: clamp(14px, 2.4vw, 30px);
}

.top-nav a {
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--muted-dark);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}

.top-nav a:hover {
  color: #fff;
  border-bottom-color: var(--amber);
}

.debug {
  display: none;
  position: fixed;
  right: 14px;
  bottom: 14px;
  z-index: 80;
  align-items: center;
  gap: 8px;
  padding: 7px 8px 7px 14px;
  border-radius: 999px;
  background: rgba(13, 17, 23, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  font-size: 0.82rem;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.6);
}

.vn-anim .debug {
  display: flex;
}

.debug b {
  display: inline-block;
  min-width: 3.2ch;
  text-align: right;
  color: var(--amber);
}

.debug-close,
.debug-open {
  font: inherit;
  color: inherit;
  cursor: pointer;
  border: 0;
}

.debug-close {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  line-height: 1;
  font-size: 1rem;
  padding: 0;
}

.debug-close:hover {
  background: rgba(255, 255, 255, 0.24);
}

.debug-open {
  display: none;
  position: fixed;
  right: 14px;
  bottom: 14px;
  z-index: 80;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(13, 17, 23, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 0.8rem;
  font-weight: 700;
  place-items: center;
  opacity: 0.7;
}

.debug-open:hover {
  opacity: 1;
}

body.debug-off .debug {
  display: none;
}

.vn-anim body.debug-off .debug-open {
  display: grid;
}

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: 130px 0 90px;
  color: #fff;
  background: #0a0e13 url("img/hero.jpg") center / cover no-repeat;
  isolation: isolate;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 20% 30%, rgba(8, 11, 16, 0.2), rgba(8, 11, 16, 0.78) 70%),
    linear-gradient(180deg, rgba(8, 11, 16, 0.5), rgba(8, 11, 16, 0.82));
}

.hero-in {
  position: relative;
}

.kicker {
  margin-bottom: 18px;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--acc, var(--amber));
}

.kicker-hero span {
  display: inline-block;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #ffd9b3;
}

.hero-title {
  max-width: 14ch;
  font-size: clamp(2.8rem, 9.4vw, 7.4rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.035em;
}

.hero-title em {
  font-style: normal;
  color: var(--amber);
}

.lead {
  max-width: 62ch;
  font-size: clamp(1.08rem, 1.6vw, 1.3rem);
  line-height: 1.6;
}

.hero-sub {
  margin-top: clamp(22px, 3vw, 36px);
}

.hero-sub .lead {
  color: #dbe3ec;
  max-width: 54ch;
}

.hero-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

.hint {
  margin-top: 44px;
  font-size: 0.95rem;
  font-weight: 600;
  color: #c9d3de;
}

.hint-arrow {
  display: inline-block;
  color: var(--amber);
}

.vn-anim .hint-arrow {
  animation: vn-bob 1.6s ease-in-out infinite;
}

@keyframes vn-bob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(6px);
  }
}

/* Knoepfe */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  border: 2px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

.btn-primary {
  background: var(--amber);
  color: var(--ink);
}

.btn-primary:hover {
  background: #ffbd7e;
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.12);
}

.btn-solid {
  background: var(--ink);
  color: #fff;
}

.btn-outline {
  border-color: var(--ink);
  color: var(--ink);
}

.btn-soft {
  background: #fbe4cd;
  color: #7a3606;
}

/* ---------- 3 Abschnitte ---------- */

.sec {
  padding: clamp(72px, 10vw, 140px) 0;
}

.sec-light {
  --acc: var(--amber-deep);
  --line: rgba(13, 17, 23, 0.14);
  --muted: var(--muted-light);
  background: var(--paper);
  color: var(--ink);
}

.sec-dark {
  --acc: var(--amber);
  --line: rgba(255, 255, 255, 0.12);
  --muted: var(--muted-dark);
  padding-bottom: clamp(40px, 6vw, 80px);
  background: var(--ink);
  color: var(--text-dark);
}

.sec-slate {
  --acc: var(--amber);
  --line: rgba(255, 255, 255, 0.12);
  --muted: var(--muted-dark);
  background: var(--slate);
  color: var(--text-dark);
}

.sec-head h2 {
  font-size: clamp(2.5rem, 7vw, 5.2rem);
  font-weight: 800;
  letter-spacing: -0.035em;
}

.sec-head .lead {
  margin-top: 22px;
  color: var(--muted);
}

.sec-head .lead strong {
  color: inherit;
}

.sec-light .sec-head .lead strong {
  color: var(--ink);
}

.sec-dark .sec-head .lead strong,
.sec-slate .sec-head .lead strong {
  color: #fff;
}

.note {
  max-width: 62ch;
  margin-top: 18px;
  padding: 14px 18px;
  border-left: 3px solid var(--acc);
  background: rgba(255, 255, 255, 0.05);
  font-size: 0.98rem;
  color: var(--muted);
}

.demo-num {
  margin-bottom: 8px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--acc);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.chips li {
  padding: 6px 13px;
  border-radius: 999px;
  background: rgba(13, 17, 23, 0.07);
  border: 1px solid rgba(13, 17, 23, 0.1);
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.35;
}

.chips-dark li {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.14);
  color: #dfe5ee;
}

.replay {
  display: none;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.vn-anim .replay {
  display: inline-flex;
}

.replay:hover {
  background: var(--ink);
  color: #fff;
}

/* ---------- 4 Staffelung (Bausteine) ---------- */

.demo {
  padding: clamp(40px, 6vw, 72px) 0;
  border-top: 1px solid var(--line);
}

.demo:first-of-type {
  margin-top: clamp(40px, 6vw, 72px);
}

.demo-head {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 24px clamp(24px, 5vw, 72px);
  align-items: end;
  margin-bottom: 28px;
}

.demo-head h3 {
  font-size: clamp(1.6rem, 3.2vw, 2.3rem);
  font-weight: 800;
}

.demo-head p:not(.demo-num) {
  margin-top: 10px;
  max-width: 52ch;
  color: var(--muted-light);
}

.demo-side {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
}

.stage-box {
  padding: clamp(18px, 3vw, 36px);
  overflow: hidden;
  border-radius: 24px;
  background: #fff;
  box-shadow:
    0 1px 0 rgba(13, 17, 23, 0.05),
    0 28px 60px -34px rgba(60, 40, 0, 0.32);
}

.stage-box.dark {
  background: var(--ink);
  color: #fff;
}

/* a) Karten */

.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.card {
  overflow: hidden;
  border-radius: 16px;
  background: var(--paper);
}

.card img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.card h4 {
  padding: 16px 18px 0;
  font-size: 1.25rem;
}

.card p {
  padding: 6px 18px 20px;
  font-size: 0.95rem;
  color: var(--muted-light);
}

/* b) Liste */

.check-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 15px 0;
  border-bottom: 1px solid rgba(13, 17, 23, 0.1);
  font-size: clamp(1.02rem, 2vw, 1.25rem);
  font-weight: 600;
}

.check-list li:last-child {
  border-bottom: 0;
}

.tick {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #dff3e6;
}

.tick svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: #1c8a4b;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* c) Buchstaben */

.big-letters {
  max-width: 20ch;
  font-size: clamp(2.1rem, 6.4vw, 4.8rem);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.03em;
  color: #fff;
}

/* d) Raster */

.wave {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(8px, 1.4vw, 14px);
  max-width: 640px;
  margin: 0 auto;
}

.wave img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 14px;
}

/* e) Knoepfe */

.btn-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  padding: clamp(10px, 3vw, 30px) 0;
}

/* f) Kacheln */

.tiles {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.tile {
  display: grid;
  place-items: center;
  aspect-ratio: 1.25;
  border-radius: 16px;
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  font-weight: 800;
  background: var(--ink);
  color: #fff;
}

.tile:nth-child(4n + 2) {
  background: var(--amber);
  color: var(--ink);
}

.tile:nth-child(4n + 3) {
  background: #2f6f73;
}

.tile:nth-child(4n) {
  background: var(--paper-2);
  color: var(--ink);
}

/* ---------- 5 Beim Scrollen (Bausteine) ---------- */

.chap {
  padding: clamp(90px, 14vw, 190px) 0 clamp(50px, 8vw, 120px);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.chap:first-of-type {
  margin-top: clamp(30px, 5vw, 60px);
}

.chap-head {
  padding-bottom: clamp(28px, 4vw, 48px);
}

.chap-head h3 {
  max-width: 22ch;
  font-size: clamp(1.8rem, 4.4vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.chap-head p:not(.demo-num) {
  max-width: 58ch;
  margin-top: 14px;
  color: var(--muted-dark);
}

.chap-head .chips {
  margin-top: 20px;
}

/* a) Zoom (ohne JS: Bild, darunter der Text) */

.zoom-stage {
  position: relative;
  background: #06090d;
}

.zoom-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.zoom-text {
  padding: 28px clamp(20px, 6vw, 80px) 40px;
  color: #fff;
}

.zoom-text h4 {
  font-size: clamp(1.8rem, 5vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.zoom-text p {
  max-width: 46ch;
  margin-top: 12px;
  font-size: clamp(1rem, 1.7vw, 1.25rem);
  color: #d6dde6;
}

/* b) Text-Highlight */

.reveal-wrap {
  padding-top: 8vh;
  padding-bottom: 30vh;
}

.reveal {
  max-width: 22em;
  font-size: clamp(1.65rem, 4.3vw, 3.2rem);
  font-weight: 700;
  line-height: 1.26;
  letter-spacing: -0.02em;
  color: #f6f8fb;
}

.vn-w {
  display: inline-block;
}

.vn-split .vn-w {
  white-space: nowrap;
}

/* c) Einfahren */

.slide-row {
  overflow: hidden;
  padding: clamp(24px, 4vw, 56px) 0;
}

.slide-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: clamp(20px, 4vw, 64px);
  align-items: center;
}

.slide-grid-rev {
  grid-template-columns: 1fr 1.25fr;
}

.slide-grid-rev .slide-fig {
  order: 2;
}

.slide-fig {
  margin: 0;
}

.slide-fig img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 22px;
}

.slide-text h4 {
  font-size: clamp(1.7rem, 3.6vw, 2.6rem);
  font-weight: 800;
}

.slide-text p {
  margin-top: 12px;
  max-width: 34ch;
  color: var(--muted-dark);
}

/* d) Horizontale Galerie (ohne JS: von Hand seitwaerts wischen) */

.hs-stage {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 28px;
  padding: 24px 0;
  background: #090d12;
}

.hs-track {
  display: flex;
  gap: clamp(14px, 2vw, 28px);
  padding: 0 clamp(16px, 6vw, 90px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}

.hs-card {
  flex: 0 0 auto;
  width: min(80vw, 640px);
  margin: 0;
  scroll-snap-align: start;
}

.hs-card img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 22px;
}

.hs-card figcaption {
  margin-top: 14px;
  font-size: 1.05rem;
  font-weight: 600;
  color: #dfe5ee;
}

.hs-card figcaption b {
  margin-right: 8px;
  color: var(--amber);
  font-variant-numeric: tabular-nums;
}

.hs-bar {
  display: none;
  height: 3px;
  margin: 0 clamp(16px, 6vw, 90px);
  background: rgba(255, 255, 255, 0.14);
}

.hs-bar i {
  display: block;
  height: 100%;
  background: var(--amber);
  transform-origin: 0 50%;
  transform: scaleX(var(--p, 0));
}

/* e) Zeitleiste */

.tl {
  position: relative;
  max-width: 820px;
  margin: 0 auto;
  padding: 24px 0 24px 76px;
}

.tl-svg {
  position: absolute;
  left: 0;
  top: 0;
  width: 40px;
  height: 100%;
  overflow: visible;
}

.tl-track {
  stroke: rgba(255, 255, 255, 0.14);
  stroke-width: 3;
}

.tl-line {
  stroke: var(--amber);
  stroke-width: 3;
  stroke-linecap: round;
}

.tl-head {
  display: none;
  position: absolute;
  left: 10px;
  top: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 6px rgba(242, 166, 90, 0.25);
}

.vn-anim .tl-head {
  display: block;
  will-change: transform;
}

.tl-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.tl-list li {
  position: relative;
  padding-bottom: clamp(48px, 9vh, 96px);
}

.tl-list li:last-child {
  padding-bottom: 0;
}

.tl-dot {
  position: absolute;
  left: -64px;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 0 5px var(--ink), 0 0 0 7px rgba(242, 166, 90, 0.5);
}

.tl-list time {
  display: block;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--amber);
}

.tl-list h4 {
  margin-top: 4px;
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 800;
}

.tl-list p {
  max-width: 48ch;
  margin-top: 8px;
  color: var(--muted-dark);
}

/* f) Zaehler */

.counters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding: clamp(24px, 5vw, 60px) 0;
  text-align: center;
}

.counter {
  padding: clamp(24px, 4vw, 44px) 12px;
  border-radius: 24px;
  background: var(--ink-2);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.counter-num {
  display: block;
  font-size: clamp(2.8rem, 8.5vw, 6.4rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  color: #fff;
}

.counter-label {
  display: block;
  margin-top: 14px;
  color: var(--muted-dark);
}

/* g) Parallax */

.px {
  position: relative;
  height: min(92vh, 840px);
  overflow: hidden;
  background: #2a1a24;
  isolation: isolate;
}

.px::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 4;
  height: 5%;
  background: #0b0e14;
}

.px-layer {
  position: absolute;
  left: 0;
  right: 0;
  transform: translate3d(0, calc((var(--r, 0.5) - 0.5) * var(--depth, 0) * 300px * var(--s, 1)), 0);
}

.vn-anim .px-layer {
  will-change: transform;
}

.px-layer svg {
  display: block;
  width: 100%;
  height: 100%;
}

.px-sky {
  top: -24%;
  height: 150%;
  z-index: 0;
}

.px-sky img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.px-far {
  bottom: -14%;
  height: 66%;
  z-index: 1;
  fill: #6a4660;
}

.px-mid {
  bottom: -16%;
  height: 60%;
  z-index: 2;
  fill: #46334f;
}

.px-fog {
  bottom: 6%;
  height: 46%;
  z-index: 2;
  background:
    radial-gradient(ellipse 60% 50% at 25% 70%, rgba(255, 224, 190, 0.5), rgba(255, 224, 190, 0)),
    radial-gradient(ellipse 55% 45% at 78% 60%, rgba(255, 224, 190, 0.42), rgba(255, 224, 190, 0));
}

.px-trees2 {
  bottom: -12%;
  height: 48%;
  z-index: 3;
  fill: #241f33;
}

.px-trees1 {
  bottom: -14%;
  height: 44%;
  z-index: 3;
  fill: #0b0e14;
}

.px-title {
  top: 12%;
  z-index: 5;
  padding: 0 clamp(16px, 4vw, 40px);
  text-align: center;
  color: #fff;
  text-shadow: 0 3px 28px rgba(0, 0, 0, 0.55);
}

.px-title h4 {
  font-size: clamp(2rem, 6vw, 4.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.px-title p {
  margin-top: 10px;
  font-size: clamp(1rem, 1.8vw, 1.3rem);
}

/* h) Kombination */

.kcards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(12px, 2vw, 22px);
}

.kcard {
  overflow: hidden;
  border-radius: 20px;
  background: var(--ink-2);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.kcard img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.kcard h4 {
  padding: 16px 18px 0;
  font-size: 1.3rem;
}

.kcard p {
  padding: 4px 18px 20px;
  font-size: 0.95rem;
  color: var(--muted-dark);
}

/* ---------- 6 Einstellungen (Attrappe + Live) ---------- */

.ei-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(300px, 1fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: start;
  margin-top: clamp(36px, 5vw, 64px);
}

.live-box,
.probe-box {
  padding: clamp(18px, 3vw, 30px);
  overflow: hidden;
  border-radius: 24px;
  background: #fff;
  box-shadow:
    0 1px 0 rgba(13, 17, 23, 0.05),
    0 28px 60px -34px rgba(60, 40, 0, 0.32);
}

.live-title {
  margin-bottom: 18px;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber-deep);
}

.live-row {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.lt {
  display: grid;
  place-items: center;
  aspect-ratio: 0.8;
  border-radius: 14px;
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-weight: 800;
  background: var(--ink);
  color: #fff;
}

.lt:nth-child(2n) {
  background: var(--amber);
  color: var(--ink);
}

.lt:nth-child(3n) {
  background: #2f6f73;
  color: #fff;
}

.live-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 22px;
}

.ei-between {
  margin: clamp(28px, 4vw, 48px) 0;
  padding-left: 18px;
  border-left: 3px solid var(--amber-deep);
  color: var(--muted-light);
}

.probe-area {
  display: grid;
  min-height: 120vh;
  place-items: center;
}

.probe-clip {
  display: flex;
  justify-content: center;
  width: 100%;
  padding: 24px 0;
  overflow: hidden;
}

.probe {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: min(300px, 80%);
  min-height: 150px;
  padding: 22px 24px;
  border-radius: 20px;
  background: linear-gradient(135deg, #f2a65a, #e8793a);
  color: #1d1006;
  box-shadow: 0 20px 40px -20px rgba(180, 84, 11, 0.7);
}

.probe b {
  font-size: 1.4rem;
}

/* Attrappe der Eigenschaften-Leiste */

.vnp {
  position: sticky;
  top: 80px;
  overflow: hidden;
  border-radius: 18px;
  background: #12171f;
  color: #dfe5ee;
  font-size: 0.92rem;
  box-shadow: 0 30px 70px -30px rgba(10, 8, 0, 0.7);
}

.vnp-bar {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px 18px 14px;
  background: #0c1016;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.vnp-title {
  font-size: 1.02rem;
  font-weight: 800;
  color: #fff;
}

.vnp-tag {
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(242, 166, 90, 0.16);
  border: 1px dashed rgba(242, 166, 90, 0.6);
  font-size: 0.74rem;
  font-weight: 700;
  line-height: 1.35;
  color: #ffcf9f;
}

.vnp-tabs {
  display: flex;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.vnp-tabs span {
  flex: 1;
  padding: 10px 4px;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 600;
  color: #7f8b99;
  border-bottom: 2px solid transparent;
}

.vnp-tabs .on {
  color: #fff;
  border-bottom-color: var(--amber);
}

.vnp-group {
  margin: 0;
  padding: 14px 18px 8px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.vnp-group legend {
  float: left;
  width: 100%;
  margin-bottom: 8px;
  padding: 0;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
}

.vnp-row {
  display: grid;
  clear: both;
  grid-template-columns: 72px minmax(0, 1fr) 58px;
  align-items: center;
  gap: 10px;
  min-height: 38px;
}

.vnp-row > span {
  color: #aeb9c6;
}

.vnp-row output {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: #fff;
}

.vnp-row select {
  grid-column: 2 / 4;
}

.vnp select {
  width: 100%;
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: #1b222d;
  color: #fff;
  font: inherit;
}

.vnp input[type="range"] {
  width: 100%;
  min-width: 0;
  margin: 0;
  accent-color: var(--amber);
}

.pathbar {
  clear: both;
  margin: 8px 0 8px;
  padding: 12px;
  border-radius: 10px;
  background: #0c1016;
}

.pb-label {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.78rem;
  color: #aeb9c6;
}

.pb-label b {
  color: #fff;
  font-variant-numeric: tabular-nums;
}

.pb-sub {
  margin-top: 8px;
  font-size: 0.72rem;
  color: #7f8b99;
}

.pb-track {
  position: relative;
  height: 10px;
  margin-top: 8px;
  overflow: hidden;
  border-radius: 6px;
  background: #1b222d;
}

.pb-band {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 10%;
  width: 50%;
  background: rgba(242, 166, 90, 0.35);
  border-left: 2px solid var(--amber);
  border-right: 2px solid var(--amber);
}

.pb-fill {
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 0;
  right: 0;
  border-radius: 3px;
  background: #fff;
  transform-origin: 0 50%;
  transform: scaleX(0);
}

.vnp-switch {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px 4px;
  cursor: pointer;
  font-weight: 600;
}

.vnp-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.sw {
  position: relative;
  flex: 0 0 auto;
  width: 42px;
  height: 24px;
  border-radius: 999px;
  background: #3a4452;
  transition: background 0.2s;
}

.sw::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s;
}

.vnp-switch input:checked + .sw {
  background: var(--amber);
}

.vnp-switch input:checked + .sw::after {
  transform: translateX(18px);
}

.vnp-switch input:focus-visible + .sw {
  outline: 3px solid #fff;
  outline-offset: 2px;
}

.vnp-hint {
  padding: 6px 18px 18px 72px;
  font-size: 0.8rem;
  line-height: 1.45;
  color: #8e9aa8;
}

/* ---------- 7 Wissen, Fuss ---------- */

.know {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-top: clamp(36px, 5vw, 60px);
}

.know-card {
  padding: clamp(22px, 3vw, 34px);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.know-card h3 {
  font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  font-weight: 800;
}

.know-card p {
  margin-top: 12px;
  color: #c4cdd8;
}

.know-card a {
  color: var(--amber);
}

.know-wide {
  grid-column: 1 / -1;
}

.know-status {
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(242, 166, 90, 0.12);
  color: #ffd9b3 !important;
}

.know-status b {
  color: #fff;
}

.code {
  margin: 18px 0 0;
  padding: 18px 20px;
  overflow-x: auto;
  border-radius: 14px;
  background: #0b0f15;
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--mono);
  font-size: 0.86rem;
  line-height: 1.6;
  color: #cfe3ff;
}

.code code {
  padding: 0;
  background: none;
  font-size: inherit;
}

.foot {
  padding: 64px 0 110px;
  background: #080b10;
  color: var(--muted-dark);
}

.foot-in {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
}

.foot-main {
  font-size: clamp(1.3rem, 3vw, 1.9rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
}

.foot-sub {
  max-width: 70ch;
  font-size: 0.95rem;
}

.reduced-note {
  display: none;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(242, 166, 90, 0.14);
  color: #ffd9b3;
}

.vn-reduced .reduced-note {
  display: block;
}

.foot-top {
  margin-top: 10px;
}

/* ---------- 8 Laufzeit-Zustaende ---------- */

/* 8a Staffelung: Anfangszustand, Effekte, Kurven */

.vn-anim [data-stagger] {
  --vn-ease: var(--ease-out);
  --vn-from: translate3d(0, 28px, 0);
}

.vn-anim [data-stagger-effect="fade"] {
  --vn-from: none;
}

.vn-anim [data-stagger-effect="fade-up"] {
  --vn-from: translate3d(0, 32px, 0);
}

.vn-anim [data-stagger-effect="fade-down"] {
  --vn-from: translate3d(0, -32px, 0);
}

.vn-anim [data-stagger-effect="slide-left"] {
  --vn-from: translate3d(-46px, 0, 0);
}

.vn-anim [data-stagger-effect="slide-right"] {
  --vn-from: translate3d(64px, 0, 0);
}

.vn-anim [data-stagger-effect="zoom"] {
  --vn-from: scale(0.55);
}

.vn-anim [data-stagger-effect="pop"] {
  --vn-from: scale(0.4);
  --vn-ease: var(--ease-pop);
}

.vn-anim [data-stagger-ease="overshoot"] {
  --vn-ease: var(--ease-pop);
}

.vn-anim [data-stagger-ease="soft"] {
  --vn-ease: cubic-bezier(0.4, 0, 0.2, 1);
}

.vn-anim [data-stagger-ease="linear"] {
  --vn-ease: linear;
}

/* Bis anim.js das Element vorbereitet hat: unsichtbar (nach 2,5 s von selbst sichtbar) */
.vn-anim [data-stagger]:not(.is-ready) {
  visibility: hidden;
  animation: vn-show 0s 2.5s forwards;
}

@keyframes vn-show {
  to {
    visibility: visible;
  }
}

.vn-anim .vn-si {
  opacity: 0;
  transform: var(--vn-from);
  transition:
    opacity var(--vn-dur, 600ms) var(--vn-ease) var(--vn-delay, 0ms),
    transform var(--vn-dur, 600ms) var(--vn-ease) var(--vn-delay, 0ms);
}

.vn-anim .is-in .vn-si {
  opacity: 1;
  transform: none;
}

.vn-anim .is-reset .vn-si {
  transition: none;
}

.vn-anim .is-playing .vn-si {
  will-change: transform, opacity;
}

/* 8b Scroll: Anheften */

.vn-anim [data-pin] {
  height: calc(var(--vn-pin, 3) * 100vh);
  height: calc(var(--vn-pin, 3) * 100svh);
}

.vn-anim [data-pin="auto"] {
  height: calc(var(--vn-hmax, 0) * 1px + 100vh);
  height: calc(var(--vn-hmax, 0) * 1px + 100svh);
}

.vn-anim [data-pin] > .vn-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
}

/* 8c Scroll: Bewegungen (alles ueber --p / --r, nur transform und opacity) */

.vn-anim [data-scroll="zoom"] .zoom-frame {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 34px;
  transform: scale(calc(1 - (1 - var(--p, 0)) * 0.62 * var(--s, 1)));
  will-change: transform;
}

.vn-anim [data-scroll="zoom"] .zoom-frame img {
  height: 100%;
  object-fit: cover;
  transform: scale(calc(1 + (1 - var(--p, 0)) * 0.3 * var(--s, 1)));
}

.vn-anim [data-scroll="zoom"] .zoom-text {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding-top: 140px;
  padding-bottom: clamp(36px, 9vh, 90px);
  background: linear-gradient(to top, rgba(4, 6, 9, 0.86), rgba(4, 6, 9, 0));
  opacity: calc((var(--p, 0) - 0.78) * 4.5);
  transform: translate3d(0, calc((1 - var(--p, 0)) * 36px), 0);
}

.vn-anim .vn-rw {
  opacity: 0.16;
}

.vn-anim [data-scroll="slide-left"] {
  opacity: calc(var(--p, 0) * 3);
  transform: translate3d(calc((1 - var(--p, 0)) * -115% * var(--s, 1)), 0, 0);
}

.vn-anim [data-scroll="slide-right"] {
  opacity: calc(var(--p, 0) * 3);
  transform: translate3d(calc((1 - var(--p, 0)) * 115% * var(--s, 1)), 0, 0);
}

.vn-anim [data-scroll="fade"] {
  opacity: var(--p, 0);
  transform: translate3d(0, calc((1 - var(--p, 0)) * 40px * var(--s, 1)), 0);
}

.vn-anim [data-scroll="grow"] {
  opacity: calc(var(--p, 0) * 2.5);
  transform: scale(calc(1 - (1 - var(--p, 0)) * 0.7 * var(--s, 1)));
}

.vn-anim [data-scroll="hscroll"] .hs-track {
  width: max-content;
  overflow: visible;
  scroll-snap-type: none;
  transform: translate3d(calc(var(--p, 0) * var(--vn-hmax, 0) * -1px), 0, 0);
  will-change: transform;
}

.vn-anim .hs-bar {
  display: block;
}

.vn-anim .tl-list li {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  transition:
    opacity 0.45s var(--ease-out),
    transform 0.45s var(--ease-out);
}

.vn-anim .tl-list li.is-on {
  opacity: 1;
  transform: none;
}

.vn-anim .tl-dot {
  transform: scale(0);
  transition: transform 0.5s var(--ease-pop) 0.05s;
}

.vn-anim .tl-list li.is-on .tl-dot {
  transform: scale(1);
}

.vn-anim [data-scroll="stagger"] > * {
  opacity: var(--p, 0);
  transform: translate3d(0, calc((1 - var(--p, 0)) * 90px * var(--s, 1)), 0) scale(calc(0.93 + 0.07 * var(--p, 0)));
}

/* ---------- 9 Tablet und Handy ---------- */

@media (max-width: 960px) {
  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kcards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .demo-head {
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
  }

  .ei-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .ei-left {
    display: contents;
  }

  .live-box {
    order: 1;
  }

  .vnp {
    order: 2;
    position: static;
  }

  .ei-between {
    order: 3;
    margin: 8px 0 0;
  }

  .probe-box {
    order: 4;
  }
}

@media (max-width: 720px) {
  body {
    font-size: 1rem;
  }

  .top-nav {
    display: none;
  }

  .hero {
    padding-top: 110px;
  }

  .slide-grid,
  .slide-grid-rev {
    grid-template-columns: minmax(0, 1fr);
  }

  .slide-grid-rev .slide-fig {
    order: 0;
  }

  .tiles {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .live-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .lt {
    aspect-ratio: 1.3;
  }

  .counters {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .know {
    grid-template-columns: minmax(0, 1fr);
  }

  .tl {
    padding-left: 60px;
  }

  .tl-dot {
    left: -50px;
  }

  .px {
    height: min(80vh, 640px);
  }

  .debug {
    right: 8px;
    bottom: 8px;
    padding: 5px 6px 5px 11px;
    font-size: 0.72rem;
  }

  .debug-close {
    width: 20px;
    height: 20px;
    font-size: 0.9rem;
  }

  .debug-open {
    right: 8px;
    bottom: 8px;
    width: 28px;
    height: 28px;
    font-size: 0.7rem;
  }

  .btn {
    padding: 0 22px;
  }
}

@media (max-width: 480px) {
  .kcards {
    gap: 10px;
  }

  .kcard h4 {
    padding: 12px 12px 0;
    font-size: 1.05rem;
  }

  .kcard p {
    padding: 4px 12px 14px;
    font-size: 0.85rem;
  }

  .vnp-row {
    grid-template-columns: 64px minmax(0, 1fr) 52px;
  }
}
