/* SolidNote – Webseite
 * Alle Farben, Größen, Abstände und Bewegungswerte stehen in :root.
 * Weiter unten wird nur noch mit var(--…) gearbeitet.
 */
:root {
  /* Flächen */
  --bg: #050507;
  --bg-2: #0b0c10;
  --surface: #131419;
  --surface-2: #1b1c22;
  --line: #25262d;
  --line-strong: #3a3b44;

  /* Text */
  --fg: #f5f5f7;
  --fg-2: #c7c7cc;
  --muted: #a1a1aa;
  --meta: #8b8b94;

  /* Marke – Logo-Violett. Für Text auf Dunkel die helle Stufe nehmen. */
  --brand: #535fab;
  --brand-hover: #616dbd;
  --brand-active: #4a5599;
  --brand-text: #aab2f2;
  --on-brand: #ffffff;
  --brand-soft: rgba(83, 95, 171, 0.16);

  /* Status */
  --success: #6ee7a0;
  --danger: #fca5a5;
  --danger-line: #b4505a;

  /* Gerät */
  --editor-gutter: #252b36;  /* Rand neben dem Papier im SolidNote-Editor */
  --circuit-bg: #1b1e22;     /* Hintergrund der Schaltungsansicht (Rand neben dem Video) */
  --doc-page-w: 92.56%;      /* Papierbreite im Editor (1666 von 1800 px) */
  --doc-inset: 5.9cqw;       /* Abstand oben/unten, damit Seite 1 und das Ende frei von den Leisten stehen */
  --doc-page-gap: 1.33cqw;   /* Abstand zwischen zwei Seiten */
  --alu-1: #45464d;
  --alu-2: #2c2d33;
  --alu-3: #1d1e22;
  --bezel: #08080a;

  /* Schrift */
  --font-display: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-body: "SF Pro Text", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: "SF Mono", ui-monospace, Menlo, Monaco, Consolas, monospace;
  --font-hand: "Noteworthy", "Bradley Hand", "Segoe Print", "Comic Neue", cursive;

  --t-xs: 13px;
  --t-sm: 15px;
  --t-base: 17px;
  --t-lg: 21px;
  --t-xl: clamp(24px, 2.4vw, 32px);
  --t-2xl: clamp(34px, 4.6vw, 60px);
  --t-3xl: clamp(46px, 7.4vw, 108px);
  --t-say: clamp(28px, 4vw, 52px);

  --lh-body: 1.55;
  --lh-tight: 1.04;
  --track-display: -0.025em;

  /* Abstände (8er-Raster) */
  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-5: 24px;
  --s-6: 32px;
  --s-7: 48px;
  --s-8: 64px;
  --s-9: 96px;
  --s-10: 128px;
  --s-11: 160px;

  --section-y: var(--s-11);
  --gutter: 32px;
  --max: 1200px;
  --nav-h: 56px;

  /* Radien */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 980px;

  /* Bewegung */
  --m-fast: 150ms;
  --m-base: 240ms;
  --m-slow: 400ms;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in: cubic-bezier(0.55, 0, 0.75, 0.2);

  --focus: 0 0 0 3px var(--bg), 0 0 0 6px var(--brand-text);
}

@media (max-width: 1023px) {
  :root { --section-y: var(--s-10); --gutter: 24px; }
}
@media (max-width: 639px) {
  :root { --section-y: var(--s-9); --gutter: 20px; }
}

/* ─── Basis ─────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + var(--s-4));
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: var(--t-base);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: var(--brand-text); text-decoration: none; }
a:hover { color: var(--fg); }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--r-sm); }

.skip {
  position: absolute;
  top: var(--s-2);
  left: var(--s-2);
  z-index: 100;
  padding: var(--s-2) var(--s-4);
  background: var(--fg);
  color: var(--bg);
  border-radius: var(--r-sm);
  transform: translateY(-200%);
}
.skip:focus-visible { transform: none; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-block: var(--section-y); }

.eyebrow {
  display: block;
  font-size: var(--t-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brand-text);
}
.h-display {
  font-family: var(--font-display);
  font-size: var(--t-3xl);
  font-weight: 700;
  line-height: var(--lh-tight);
  letter-spacing: var(--track-display);
  text-wrap: balance;
}
.h-section {
  font-family: var(--font-display);
  font-size: var(--t-2xl);
  font-weight: 650;
  line-height: 1.08;
  letter-spacing: var(--track-display);
  text-wrap: balance;
}
.h-card {
  font-family: var(--font-display);
  font-size: var(--t-xl);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.lead {
  font-size: var(--t-lg);
  line-height: 1.5;
  color: var(--fg-2);
  max-width: 34em;
  text-wrap: pretty;
}
.copy {
  color: var(--muted);
  max-width: 38em;
  text-wrap: pretty;
}
.copy + .copy { margin-top: var(--s-4); }
.muted { color: var(--muted); }
.mono { font-family: var(--font-mono); }
.nowrap { white-space: nowrap; }

/* ─── Buttons ───────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  min-height: 48px;
  padding: 12px 24px;
  border: 0;
  border-radius: var(--r-pill);
  font-size: var(--t-base);
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
  text-decoration: none;
  transition: background-color var(--m-fast) var(--ease-out), transform var(--m-fast) var(--ease-out), box-shadow var(--m-fast) var(--ease-out);
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--brand); color: var(--on-brand); }
.btn-primary:hover { background: var(--brand-hover); color: var(--on-brand); }
.btn-primary:active { background: var(--brand-active); }
.btn-ghost { background: transparent; color: var(--fg); box-shadow: inset 0 0 0 1px var(--line-strong); }
.btn-ghost:hover { color: var(--fg); box-shadow: inset 0 0 0 1px var(--fg-2); }
.btn-sm { min-height: 36px; padding: 8px 16px; font-size: var(--t-sm); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn[aria-disabled="true"], .btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ─── Navigation ────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  transition: background-color var(--m-base) var(--ease-out), box-shadow var(--m-base) var(--ease-out);
}
.nav.is-solid {
  background: rgba(5, 5, 7, 0.78);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
  backdrop-filter: saturate(160%) blur(18px);
  box-shadow: 0 1px 0 var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  height: var(--nav-h);
}
.brand {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  color: var(--fg);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--t-base);
  letter-spacing: -0.01em;
}
.brand:hover { color: var(--fg); }
.brand svg { width: 22px; height: auto; }
.nav-links { display: flex; align-items: center; gap: var(--s-5); }
.nav-links a { color: var(--muted); font-size: var(--t-sm); }
.nav-links a:hover { color: var(--fg); }
.nav-links a {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  transition: color var(--m-fast) var(--ease-out);
}
/* aktuelle Seite: hellere Schrift plus Strich darunter, nicht nur Farbe */
.nav-links a[aria-current="page"] { color: var(--fg); }
.nav-links a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  height: 2px;
  border-radius: 1px;
  background: var(--brand-text);
}
.nav-end { display: flex; align-items: center; gap: var(--s-3); }
.nav-toggle {
  display: none;
  place-content: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 1px;
  background: var(--fg);
  transition: transform var(--m-base) var(--ease-out);
}
.nav.is-open .nav-toggle span:first-child { transform: translateY(4px) rotate(45deg); }
.nav.is-open .nav-toggle span:last-child { transform: translateY(-4px) rotate(-45deg); }
@media (max-width: 860px) {
  .nav-toggle { display: grid; }
  .nav-links {
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    display: grid;
    gap: 0;
    padding: var(--s-2) var(--gutter) var(--s-5);
    background: rgba(5, 5, 7, 0.96);
    -webkit-backdrop-filter: saturate(160%) blur(18px);
    backdrop-filter: saturate(160%) blur(18px);
    box-shadow: 0 1px 0 var(--line);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity var(--m-fast) var(--ease-in), transform var(--m-fast) var(--ease-in), visibility 0s linear var(--m-fast);
  }
  .nav.is-open .nav-links {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition: opacity var(--m-base) var(--ease-out), transform var(--m-base) var(--ease-out), visibility 0s;
  }
  .nav.is-open { background: rgba(5, 5, 7, 0.96); }
  .nav-links a { min-height: 52px; font-size: var(--t-lg); color: var(--fg-2); border-bottom: 1px solid var(--line); }
  .nav-links a[aria-current="page"]::after { left: auto; right: 0; top: 50%; bottom: auto; width: 8px; height: 8px; border-radius: 50%; transform: translateY(-50%); }
}
@media (max-width: 420px) { .nav-end .btn-sm { padding-inline: 12px; } }

/* ─── 3D-iPad ───────────────────────────────────────────────────── */
.stage {
  position: relative;
  perspective: 2000px;
  perspective-origin: 50% 30%;
}
.device {
  --dw: min(86vw, 1040px);
  position: relative;
  width: var(--dw);
  margin-inline: auto;
  transform-style: preserve-3d;
  will-change: transform;
}
.device-body {
  position: relative;
  padding: calc(var(--dw) * 0.03);
  background: var(--bezel);
  border-radius: calc(var(--dw) * 0.05);
  box-shadow:
    inset 0 0 0 calc(var(--dw) * 0.0022) var(--alu-1),
    inset 0 0 0 calc(var(--dw) * 0.004) var(--alu-3);
  transform: translateZ(0.5px);
}
.slab {
  position: absolute;
  inset: 0;
  border-radius: calc(var(--dw) * 0.05);
  background: var(--alu-2);
  transform: translateZ(calc(var(--i) * var(--dw) * -0.0016));
  pointer-events: none;
}
.slab:nth-child(-n + 3) { background: var(--alu-1); }
.slab:last-of-type { background: var(--alu-3); }
.device-screen {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--dw) * 0.022);
  background: #000;
}
.glare {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at var(--gx, 30%) var(--gy, 20%), rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0) 48%);
  mix-blend-mode: screen;
}
.cam {
  position: absolute;
  top: calc(var(--dw) * 0.011);
  left: 50%;
  width: calc(var(--dw) * 0.008);
  height: calc(var(--dw) * 0.008);
  margin-left: calc(var(--dw) * -0.004);
  border-radius: 50%;
  background: #15161b;
  box-shadow: inset 0 0 0 1px #24252c;
}
.stage-shadow {
  width: calc(var(--dw, 86vw) * 0.8);
  height: 80px;
  margin: calc(var(--s-6) * -1) auto 0;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(83, 95, 171, 0.32), rgba(83, 95, 171, 0));
  filter: blur(18px);
  pointer-events: none;
}

/* ─── Hero ──────────────────────────────────────────────────────── */
.hero {
  position: relative;
  padding-top: calc(var(--nav-h) + var(--s-9));
  padding-bottom: var(--s-9);
  text-align: center;
  overflow: clip;
}
.hero-copy { display: grid; justify-items: center; gap: var(--s-5); }
.hero .lead { margin-inline: auto; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: 6px 14px;
  border-radius: var(--r-pill);
  font-size: var(--t-xs);
  font-weight: 500;
  color: var(--fg-2);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}
.badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  flex: none;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--s-3);
  margin-top: var(--s-2);
}
.hero-note { font-size: var(--t-xs); color: var(--meta); }
.hero-intro > * {
  opacity: 0;
  transform: translateY(16px);
  animation: rise var(--m-slow) var(--ease-out) forwards;
}
.hero-intro > :nth-child(2) { animation-delay: 80ms; }
.hero-intro > :nth-child(3) { animation-delay: 160ms; }
.hero-intro > :nth-child(4) { animation-delay: 240ms; }
.hero-intro > :nth-child(5) { animation-delay: 320ms; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ─── Statement (Wörter leuchten beim Scrollen auf) ─────────────── */
.say {
  font-family: var(--font-display);
  font-size: var(--t-say);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.02em;
  max-width: 22em;
  text-wrap: pretty;
}
.say .w { opacity: var(--o, 1); transition: opacity var(--m-fast) linear; }
.say em { font-style: normal; color: var(--brand-text); }

/* ─── Kapitel-Layout ────────────────────────────────────────────── */
.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: var(--s-9);
  align-items: center;
}
.split-text { display: grid; gap: var(--s-5); align-content: start; }
@media (max-width: 960px) {
  .split { grid-template-columns: minmax(0, 1fr); gap: var(--s-7); }
}
.points { display: grid; gap: var(--s-3); margin-top: var(--s-2); }
.points li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--s-3);
  color: var(--fg-2);
}
.points li::before {
  content: "";
  width: 6px;
  height: 6px;
  margin-top: 0.65em;
  border-radius: 50%;
  background: var(--brand-text);
}

.hint { font-size: var(--t-sm); color: var(--meta); }

/* ─── Wanderndes iPad ────────────────────────────────────────────
 * Ein festes Gerät hinter dem Inhalt. Position, Größe und Drehung
 * berechnet site.js aus den .slot-Platzhaltern der Abschnitte.
 * Aktiv ab 768 px Breite und ohne „Bewegung reduzieren“ (html.travel-on). */
.travel {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  perspective: 2200px;
  perspective-origin: 50% 50%;
  overflow: hidden;
}
html.travel-on .travel { display: block; }
main, .foot { position: relative; z-index: 1; }
.travel .device {
  --dw: 1000px;
  position: absolute;
  top: 0;
  left: 0;
  transform-origin: 50% 50%;
  will-change: transform;
}
.device-body { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.device-back {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: calc(var(--dw) * 0.05);
  background-color: #2b2c31;
  background-image:
    radial-gradient(120% 90% at 30% 20%, rgba(255, 255, 255, 0.06), rgba(0, 0, 0, 0) 60%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.012) 0 1px, rgba(0, 0, 0, 0.012) 1px 3px);
  box-shadow:
    inset 0 0 0 calc(var(--dw) * 0.0025) #4b4d55,
    inset 0 0 calc(var(--dw) * 0.02) rgba(0, 0, 0, 0.55);
  transform: translateZ(calc(var(--dw) * -0.0232)) rotateY(180deg);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
/* Lichtreflex, der beim Drehen über die Rückseite wandert (--sheen setzt site.js) */
.back-sheen {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0) 35%, rgba(255, 255, 255, 0.09) 48%, rgba(255, 255, 255, 0) 62%);
  background-size: 300% 100%;
  background-position: calc(var(--sheen, 0.5) * 100%) 0;
  pointer-events: none;
}
/* Kameramodul wie beim iPad Pro: erhabener Block, zwei Linsen, LiDAR, Blitz, Mikrofon */
.back-cam {
  position: absolute;
  top: calc(var(--dw) * 0.03);
  left: calc(var(--dw) * 0.03);
  width: calc(var(--dw) * 0.115);
  height: calc(var(--dw) * 0.115);
  border-radius: calc(var(--dw) * 0.03);
  background: linear-gradient(145deg, #34353b, #1d1e22);
  box-shadow:
    inset 0 0 0 calc(var(--dw) * 0.0015) #55575f,
    0 calc(var(--dw) * 0.003) calc(var(--dw) * 0.008) rgba(0, 0, 0, 0.6);
}
.back-cam i { position: absolute; border-radius: 50%; }
.lens {
  width: calc(var(--dw) * 0.042);
  height: calc(var(--dw) * 0.042);
  background: radial-gradient(circle at 38% 35%, #3b4a66 0 12%, #0b0d12 30%, #050608 62%, #2a2b30 64%, #121317 72%);
  box-shadow: 0 0 0 calc(var(--dw) * 0.0022) #3d3f46, 0 0 0 calc(var(--dw) * 0.004) #111215;
}
.lens-wide  { top: calc(var(--dw) * 0.011); left: calc(var(--dw) * 0.011); }
.lens-ultra { bottom: calc(var(--dw) * 0.011); left: calc(var(--dw) * 0.011); }
.lidar {
  top: calc(var(--dw) * 0.016); right: calc(var(--dw) * 0.016);
  width: calc(var(--dw) * 0.024); height: calc(var(--dw) * 0.024);
  background: radial-gradient(circle, #1a1b20 0 40%, #0b0c0f 60%);
  box-shadow: 0 0 0 calc(var(--dw) * 0.0015) #3d3f46;
}
.flash {
  bottom: calc(var(--dw) * 0.02); right: calc(var(--dw) * 0.02);
  width: calc(var(--dw) * 0.014); height: calc(var(--dw) * 0.014);
  background: radial-gradient(circle at 40% 40%, #f3ead6, #b9ad92 70%);
}
.mic {
  top: 50%; right: calc(var(--dw) * 0.008);
  width: calc(var(--dw) * 0.004); height: calc(var(--dw) * 0.004);
  background: #0b0c0f;
}
/* eingelassenes, leicht spiegelndes Logo */
.back-logo {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 11%;
  height: auto;
  transform: translate(-50%, -50%);
  fill: #3a3c44;
  filter: drop-shadow(0 calc(var(--dw) * -0.0008) 0 rgba(255, 255, 255, 0.09)) drop-shadow(0 calc(var(--dw) * 0.001) 0 rgba(0, 0, 0, 0.6));
}
/* Smart Connector an der unteren Längskante */
.back-connector {
  position: absolute;
  bottom: calc(var(--dw) * 0.012);
  left: 50%;
  display: flex;
  gap: calc(var(--dw) * 0.006);
  transform: translateX(-50%);
}
.back-connector i {
  width: calc(var(--dw) * 0.006);
  height: calc(var(--dw) * 0.006);
  border-radius: 50%;
  background: #1a1b1f;
  box-shadow: inset 0 0 0 1px #5c5e66;
}

/* App-Screenshots auf dem Display (assets/screens/, siehe docs/screenshots.md) */
.device-screen { aspect-ratio: var(--screen-ratio, 2420 / 1668); container-type: inline-size; }
.scr {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity var(--m-slow) var(--ease-out);
}
.scr.is-active { opacity: 1; }
.scr img { display: none; width: 100%; height: 100%; object-fit: contain; background: #0c0e12; }
.scr.has-img img { display: block; }
.scr.has-img .scr-ph { display: none; }
.scr-ph {
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 1.6cqw;
  height: 100%;
  padding: 4cqw;
  background: #0c0e12;
  text-align: center;
}
.scr-ph svg { width: 7cqw; height: auto; fill: var(--brand); }
.scr-title { font-family: var(--font-display); font-size: 4.2cqw; font-weight: 650; color: var(--fg); letter-spacing: -0.02em; }
.scr-file { font-family: var(--font-mono); font-size: 1.8cqw; color: var(--meta); }

/* Dokument auf dem Display, aufgebaut wie der SolidNote-Editor:
   dunkler Rand, Papier fast bildschirmbreit, die schwebenden Leisten darüber.
   Maße stammen aus dem 1800 × 1240-Screenshot (1cqw = 18 px dort).
   site.js verschiebt nur .doc-strip (transform) und setzt die Seitenzahl. */
.scr-doc { overflow: hidden; background: var(--editor-gutter); }
.doc-strip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--doc-page-gap);
  padding-block: var(--doc-inset);
  will-change: transform;
}
.scr-doc .doc-page {
  display: block;
  flex: none;
  width: var(--doc-page-w);
  height: auto;
  object-fit: contain;
  background: #fff;
}
.scr-doc .doc-ui {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  background: none;
  pointer-events: none;
  filter: drop-shadow(0 0.22cqw 0.9cqw rgba(0, 0, 0, 0.14));
}
.doc-count {
  position: absolute;
  left: 95.9%;   /* Mitte der Seitenzahl im Screenshot: 1726 / 1800 */
  top: 95.1%;    /* 1179 / 1240 */
  transform: translate(-50%, -50%);
  font-family: var(--font-body);
  font-size: 1.22cqw;  /* 22 px im Screenshot */
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.01em;
  color: #000;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* Video aus der App auf dem Display (Schritt „Handschrift → Mathe“) */
.scr-video { overflow: hidden; background: var(--video-bg, var(--editor-gutter)); }
.scr-video video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: var(--video-bg, var(--editor-gutter));
}

/* Platzhalter, auf denen das iPad „landet“ */
.slot { position: relative; width: 100%; aspect-ratio: 1000 / 708; }
.hero-slot { width: min(86vw, 1040px); margin: var(--s-9) auto 0; }
.hero-static { display: none; }
html:not(.travel-on) .hero-static { display: block; }
html:not(.travel-on) .hero-static .device { --dw: min(86vw, 1040px); transform: rotateX(10deg); }
html:not(.travel-on) .slot:not(.hero-slot) { display: none; }

.with-slot {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: var(--s-9);
  align-items: center;
}
.with-slot.slot-left { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }
.say-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.beta-slot { width: min(36vw, 440px); margin-bottom: var(--s-6); }
.fb-slot { max-width: 420px; margin-top: var(--s-7); }
html:not(.travel-on) .with-slot { grid-template-columns: minmax(0, 1fr); }

/* Tour: Text links, Platzhalter rechts */
.tour-head { display: grid; gap: var(--s-4); max-width: 46em; }
.tour { display: grid; margin-top: var(--s-7); }
.tour-step {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: var(--s-9);
  align-items: center;
  min-height: 82vh;
  opacity: 0.3;
  transition: opacity var(--m-slow) var(--ease-out);
}
.tour-step.is-active { opacity: 1; }
.tour-text { display: grid; gap: var(--s-3); }
.tour-text .n { font-family: var(--font-mono); font-size: var(--t-xs); color: var(--brand-text); }
.tour-text h3 {
  font-family: var(--font-display);
  font-size: clamp(32px, 3.6vw, 52px);
  font-weight: 650;
  line-height: 1.06;
  letter-spacing: var(--track-display);
  text-wrap: balance;
}
.tour-text p { max-width: 30em; color: var(--muted); text-wrap: pretty; }
/* Feature-Text: Kernaussage oben, Details in kurzen Absätzen darunter */
.tour-copy { display: grid; gap: var(--s-3); margin-top: var(--s-1); }
.tour-text .tour-lead {
  max-width: 24em;
  font-size: var(--t-lg);
  line-height: 1.4;
  font-weight: 500;
  color: var(--fg);
  letter-spacing: -0.01em;
}
.tour-text .tour-copy p:not(.tour-lead) { font-size: var(--t-base); line-height: var(--lh-body); }
.tour-text .tour-copy strong { color: var(--fg-2); font-weight: 600; }
.tour-text .tour-lead-next { margin-top: var(--s-3); } /* zweite Zwischenüberschrift: etwas Luft zum Absatz davor */
.step-screen { display: none; --dw: 600px; border-radius: var(--r-md); box-shadow: 0 0 0 1px var(--line-strong); }
html:not(.travel-on) .tour-step {
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-5);
  min-height: 0;
  opacity: 1;
  padding-block: var(--s-7);
  border-top: 1px solid var(--line);
}
html:not(.travel-on) .step-screen { display: block; max-width: 760px; }

/* ─── Handschrift → Mathe ───────────────────────────────────────── */
.paper {
  position: relative;
  padding: var(--s-6);
  border-radius: var(--r-lg);
  background: #f7f7f9;
  color: #1d1d1f;
  background-image:
    linear-gradient(#e3e3e8 1px, transparent 1px),
    linear-gradient(90deg, #e3e3e8 1px, transparent 1px);
  background-size: 24px 24px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}
.paper-hand {
  font-family: var(--font-hand);
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.3;
  color: #1d1d1f;
}
.paper-hand.is-answer { color: #2f3fb0; opacity: var(--ans, 0); transition: opacity var(--m-slow) var(--ease-out); }
.lasso {
  display: inline-block;
  padding: 2px 14px;
  border-radius: 999px;
  outline: 2px dashed rgba(83, 95, 171, var(--lasso, 0));
  outline-offset: 4px;
}
.plot {
  margin-top: var(--s-5);
  border-radius: var(--r-md);
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #d2d2d7;
}
.plot svg { width: 100%; height: auto; }
.steps3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-4);
  margin-top: var(--s-2);
}
.steps3 li {
  display: grid;
  gap: var(--s-1);
  padding: var(--s-4);
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}
.steps3 .n { font-family: var(--font-mono); font-size: var(--t-xs); color: var(--brand-text); }
.steps3 .t { font-weight: 600; color: var(--fg); }
.steps3 .d { font-size: var(--t-sm); color: var(--muted); }
@media (max-width: 639px) { .steps3 { grid-template-columns: minmax(0, 1fr); } }

/* ─── Kallix-Karte ──────────────────────────────────────────────── */
.flip {
  display: block;
  width: 100%;
  max-width: 520px;
  margin-inline: auto;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  perspective: 1400px;
  border-radius: var(--r-xl);
}
.flip-inner {
  display: grid;
  transform-style: preserve-3d;
  transition: transform var(--m-slow) var(--ease-out);
}
.flip.is-flipped .flip-inner { transform: rotateY(180deg); }
.flip-face {
  grid-area: 1 / 1;
  display: grid;
  align-content: space-between;
  gap: var(--s-6);
  min-height: 300px;
  padding: var(--s-6);
  border-radius: var(--r-xl);
  text-align: left;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
.flip-front { background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line-strong); }
.flip-back { background: var(--brand); color: var(--on-brand); transform: rotateY(180deg); }
.flip-label { font-size: var(--t-xs); font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.8; }
.flip-q { font-family: var(--font-display); font-size: clamp(22px, 2.4vw, 28px); font-weight: 600; line-height: 1.25; }
.flip-a { font-size: var(--t-base); line-height: 1.5; }
.flip-a .mono { display: block; margin-top: var(--s-3); font-size: var(--t-lg); }
.flip-foot { font-size: var(--t-sm); opacity: 0.8; }

/* ─── Kleine Spalten ────────────────────────────────────────────── */
.cols4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s-6);
  margin-top: var(--s-8);
  padding-top: var(--s-6);
  border-top: 1px solid var(--line);
}
.cols4 h3 { font-size: var(--t-base); font-weight: 600; margin-bottom: var(--s-2); }
.cols4 p { font-size: var(--t-sm); color: var(--muted); }
@media (max-width: 960px) { .cols4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .cols4 { grid-template-columns: minmax(0, 1fr); } }

/* ─── Beta ──────────────────────────────────────────────────────── */
.beta {
  display: grid;
  justify-items: center;
  gap: var(--s-5);
  text-align: center;
}
.beta-mark { width: 88px; height: auto; margin-bottom: var(--s-3); }
.beta-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-5);
  width: 100%;
  max-width: 820px;
  margin-top: var(--s-6);
  text-align: left;
  counter-reset: st;
}
.beta-steps li { display: grid; gap: var(--s-1); padding-top: var(--s-4); border-top: 1px solid var(--line-strong); }
.beta-steps li::before {
  counter-increment: st;
  content: "0" counter(st);
  font-family: var(--font-mono);
  font-size: var(--t-xs);
  color: var(--brand-text);
}
.beta-steps strong { font-weight: 600; }
.beta-steps span { font-size: var(--t-sm); color: var(--muted); }
@media (max-width: 680px) { .beta-steps { grid-template-columns: minmax(0, 1fr); } }
/* Preisoptionen im Abschnitt „Bald verfügbar“: zwei Spalten, ohne Nummern */
.beta-prices { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 640px; }
.beta-prices li::before { content: none; }
@media (max-width: 680px) { .beta-prices { grid-template-columns: minmax(0, 1fr); } }

/* ─── Feedback ──────────────────────────────────────────────────── */
.fb-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr);
  gap: var(--s-9);
  align-items: start;
}
@media (max-width: 960px) { .fb-grid { grid-template-columns: minmax(0, 1fr); gap: var(--s-7); } }
.form {
  display: grid;
  gap: var(--s-5);
  padding: var(--s-6);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}
@media (max-width: 639px) { .form { padding: var(--s-5); } }
.seg {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-1);
  padding: var(--s-1);
  border-radius: var(--r-md);
  background: var(--bg-2);
  box-shadow: inset 0 0 0 1px var(--line);
}
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: var(--s-2) var(--s-3);
  border-radius: var(--r-sm);
  font-size: var(--t-sm);
  font-weight: 500;
  color: var(--muted);
  cursor: pointer;
  transition: background-color var(--m-fast) var(--ease-out), color var(--m-fast) var(--ease-out);
}
.seg label:hover { color: var(--fg); }
.seg input:checked + label { background: var(--surface-2); color: var(--fg); box-shadow: inset 0 0 0 1px var(--line-strong); }
.seg input:focus-visible + label { box-shadow: var(--focus); }
.row2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-4); }
@media (max-width: 639px) { .row2 { grid-template-columns: minmax(0, 1fr); } }
.field { display: grid; gap: var(--s-2); }
.field > label { font-size: var(--t-sm); font-weight: 500; color: var(--fg-2); }
.field .req { color: var(--brand-text); }
.field .opt { color: var(--meta); font-weight: 400; }
.field input, .field textarea, .field select {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: var(--bg-2);
  color: var(--fg);
  font-size: var(--t-base);
  line-height: 1.4;
  transition: border-color var(--m-fast) var(--ease-out), box-shadow var(--m-fast) var(--ease-out);
}
.field textarea { min-height: 128px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: var(--meta); }
.field input:hover, .field textarea:hover, .field select:hover { border-color: var(--meta); }
.field input:focus-visible, .field textarea:focus-visible, .field select:focus-visible {
  border-color: var(--brand-text);
  box-shadow: 0 0 0 3px var(--brand-soft);
  border-radius: var(--r-sm);
}
.field-help { font-size: var(--t-xs); color: var(--meta); }
.field-error {
  display: none;
  font-size: var(--t-sm);
  color: var(--danger);
}
.field.is-invalid input, .field.is-invalid textarea { border-color: var(--danger-line); }
.field.is-invalid .field-error { display: flex; gap: var(--s-2); }
.field-error svg { width: 16px; height: 16px; flex: none; margin-top: 3px; }
.check { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: var(--s-3); align-items: start; font-size: var(--t-sm); color: var(--muted); }
.check input { width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--brand); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
[data-only][hidden] { display: none; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-4); }
.status {
  display: none;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--s-3);
  padding: var(--s-4);
  border-radius: var(--r-md);
  font-size: var(--t-sm);
}
.status.is-on { display: grid; }
.status svg { width: 20px; height: 20px; margin-top: 1px; }
.status-ok { background: rgba(110, 231, 160, 0.08); color: var(--success); box-shadow: inset 0 0 0 1px rgba(110, 231, 160, 0.3); }
.status-err { background: rgba(252, 165, 165, 0.08); color: var(--danger); box-shadow: inset 0 0 0 1px rgba(252, 165, 165, 0.3); }
.status p { color: var(--fg-2); }
.status strong { display: block; color: inherit; }
.spinner {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: var(--on-brand);
  animation: spin 800ms linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Footer ────────────────────────────────────────────────────── */
.foot { padding-block: var(--s-8); border-top: 1px solid var(--line); font-size: var(--t-sm); color: var(--meta); }
.foot-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-5); }
.foot-links { display: flex; flex-wrap: wrap; gap: var(--s-5); }
.foot-links a { color: var(--muted); }
.foot-links a:hover { color: var(--fg); }

/* ─── Einblenden beim Scrollen ──────────────────────────────────── */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity var(--m-slow) var(--ease-out), transform var(--m-slow) var(--ease-out); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ─── Rechtliche Seiten ─────────────────────────────────────────── */
.legal { padding-top: calc(var(--nav-h) + var(--s-9)); padding-bottom: var(--s-10); }
.legal-inner { max-width: 760px; }
.legal h1 { font-family: var(--font-display); font-size: var(--t-2xl); font-weight: 650; letter-spacing: var(--track-display); line-height: 1.1; margin-bottom: var(--s-6); }
.legal h2 { font-family: var(--font-display); font-size: var(--t-lg); font-weight: 600; margin-top: var(--s-7); margin-bottom: var(--s-3); }
.legal p, .legal li { color: var(--fg-2); }
.legal p + p { margin-top: var(--s-3); }
.legal ul { display: grid; gap: var(--s-2); margin-top: var(--s-3); padding-left: var(--s-5); list-style: disc; }
.todo {
  padding: 1px 6px;
  border-radius: 4px;
  background: rgba(234, 179, 8, 0.16);
  color: #fde68a;
  font-family: var(--font-mono);
  font-size: 0.9em;
}
.note {
  margin-bottom: var(--s-6);
  padding: var(--s-4) var(--s-5);
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line-strong);
  color: var(--fg-2);
  font-size: var(--t-sm);
}

/* ─── Unterseiten ───────────────────────────────────────────────── */
.page-head { padding-top: calc(var(--nav-h) + var(--s-9)); }
.page-head-center { text-align: center; padding-bottom: var(--s-8); }
.page-head-center .lead { margin-inline: auto; }
.h-page {
  font-family: var(--font-display);
  font-size: clamp(40px, 5.6vw, 76px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: var(--track-display);
  text-wrap: balance;
}
.section-tight { padding-block: var(--s-8); }
.more-link {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: 44px;
  margin-top: var(--s-3);
  font-weight: 500;
}
.more-link svg { width: 18px; height: 18px; }
#funktionen .hint + .more-link { margin-top: var(--s-2); }

/* Features: Kapitelübersicht und Kapitel */
.chapter-index { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-2); }
.chapter-index a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 16px;
  border-radius: var(--r-pill);
  font-size: var(--t-sm);
  color: var(--fg-2);
  box-shadow: inset 0 0 0 1px var(--line-strong);
  transition: color var(--m-fast) var(--ease-out), box-shadow var(--m-fast) var(--ease-out);
}
.chapter-index a:hover { color: var(--fg); box-shadow: inset 0 0 0 1px var(--fg-2); }
.chapter { min-height: 92vh; display: grid; align-content: center; scroll-margin-top: var(--nav-h); }
.chapter .n { font-family: var(--font-mono); font-size: var(--t-xs); color: var(--meta); }
.chapter .split-text .split-text { gap: var(--s-4); }
.chapter .points li { color: var(--fg-2); }
/* Feature-Name vorne fett, Nutzen dahinter in der Textfarbe */
.chapter .points li strong { color: var(--fg); font-weight: 600; }
.chapter .steps3 { margin-block: var(--s-2); }
.chapter .step-screen { margin-top: var(--s-5); }
html:not(.travel-on) .chapter { min-height: 0; }

/* Preise */
.price-slot { width: min(52vw, 620px); margin: var(--s-8) auto 0; }
.price-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-5);
  align-items: stretch;
}
@media (max-width: 860px) { .price-grid { grid-template-columns: minmax(0, 1fr); } }
.price-card {
  display: grid;
  grid-template-rows: auto auto auto 1fr auto;
  gap: var(--s-4);
  padding: var(--s-6);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}
.price-card.is-current { box-shadow: inset 0 0 0 1px var(--brand); }
.price-card .btn { justify-self: start; }
.price-top { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); }
.price-value {
  font-family: var(--font-display);
  font-size: clamp(44px, 5vw, 64px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: var(--track-display);
}
.price-open { color: var(--fg-2); }
.price-sub { color: var(--muted); }
.price-stack { display: grid; gap: var(--s-2); }
.price-was { font-size: var(--t-sm); color: var(--muted); }
.price-was s { text-decoration-thickness: 1px; }
.price-card .price-note { justify-self: start; font-size: var(--t-sm); font-weight: 500; color: var(--fg-2); padding: var(--s-2) var(--s-4); border-radius: 980px; box-shadow: inset 0 0 0 1px var(--line-strong); }
.badge-muted { color: var(--meta); }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-5); margin-top: var(--s-5); }
.facts > div { display: grid; gap: var(--s-2); align-content: start; padding-top: var(--s-4); border-top: 1px solid var(--line-strong); }
.facts dt { font-weight: 600; }
.facts dd { margin: 0; font-size: var(--t-sm); color: var(--muted); }
@media (max-width: 860px) { .facts { grid-template-columns: minmax(0, 1fr); } }

/* ─── Weniger Bewegung ──────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
  .hero-intro > * { opacity: 1; transform: none; }
  .js .reveal { opacity: 1; transform: none; }
}
