/* Startseite als Folien-Rundgang (Nils 09.11.2026).
   Gilt nur für index.html (body.deck-page). Mit JavaScript (html.js-deck)
   liegen die Folien nebeneinander und werden geblättert; ohne JavaScript
   stehen sie untereinander wie eine normale Seite. */

:root {
  --deck-bar-h: 56px;
  --deck-head-h: 68px;
  /* Höhe, die ein Screen neben dem Text höchstens einnehmen darf */
  --shot-h: calc(100dvh - var(--deck-head-h) - var(--deck-bar-h) - 150px);
}

body.home.deck-page::before {
  display: none;
}

/* ── Grundgerüst ─────────────────────────────────────────────── */

.slide {
  position: relative;
  padding: clamp(24px, 5vh, 64px) clamp(20px, 5vw, 80px);
  background:
    radial-gradient(circle at 86% 14%, rgba(81, 57, 223, 0.13), transparent 34rem),
    radial-gradient(circle at 6% 92%, rgba(226, 119, 232, 0.07), transparent 30rem),
    var(--bg);
}

.slide:nth-child(even) {
  background:
    radial-gradient(circle at 10% 16%, rgba(81, 57, 223, 0.12), transparent 34rem),
    radial-gradient(circle at 92% 88%, rgba(226, 119, 232, 0.06), transparent 30rem),
    var(--panel);
}

html[data-theme="light"] .slide:nth-child(even) {
  background:
    radial-gradient(circle at 10% 16%, rgba(81, 57, 223, 0.07), transparent 34rem),
    var(--panel-2);
}

.slide > * {
  position: relative;
  z-index: 1;
}

.s-split,
.s-stack,
.s-two {
  width: 100%;
  margin-inline: auto;
}

.s-split {
  display: grid;
  grid-template-columns: minmax(300px, 0.8fr) minmax(0, 1.45fr);
  gap: clamp(28px, 4vw, 72px);
  align-items: center;
  max-width: 1680px;
}

.s-stack {
  max-width: 1240px;
}

.s-two {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(28px, 4vw, 72px);
  align-items: start;
  max-width: 1400px;
}

html:not(.js-deck) .slide {
  min-height: calc(100vh - var(--deck-head-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-bottom: 1px solid var(--line);
}

/* ── Folienmodus ─────────────────────────────────────────────── */

html.js-deck,
html.js-deck body {
  height: 100%;
  overflow: hidden;
}

html.js-deck body.deck-page {
  display: flex;
  flex-direction: column;
  height: 100dvh;
}

html.js-deck .site-header {
  position: relative;
  flex: none;
}

html.js-deck .deck {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  overflow: clip; /* Anker-Sprünge des Browsers dürfen den Bereich nicht verschieben */
}

html.js-deck .deck-track {
  display: flex;
  height: 100%;
  transform: translate3d(calc(var(--i, 0) * -100%), 0, 0);
  transition: transform 0.8s cubic-bezier(0.65, 0, 0.35, 1);
  will-change: transform;
}

html.js-deck .slide {
  flex: 0 0 100%;
  width: 100%;
  min-width: 0; /* sonst wächst eine Folie mit breitem Inhalt und die Strecke verrutscht */
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
}

/* Zentriert, solange der Inhalt passt; ist er höher, scrollt die Folie von oben. */
html.js-deck .slide > .s-split,
html.js-deck .slide > .s-stack,
html.js-deck .slide > .s-two {
  margin-block: auto;
}

/* Aufbau je Folie: Elemente mit .b gleiten nacheinander herein. Sichtbar ist
   der Ruhezustand; .is-pre setzt nur kurz den Startpunkt (kein Stillstand
   bei opacity 0, falls ein Hintergrund-Tab Übergänge anhält). */
html.js-deck .b {
  transition:
    opacity 0.6s ease calc(var(--bi, 0) * 80ms + 140ms),
    transform 0.75s cubic-bezier(0.2, 0.7, 0.2, 1) calc(var(--bi, 0) * 80ms + 140ms);
}

html.js-deck .slide.is-pre .b {
  opacity: 0;
  transform: translateY(22px);
  transition: none;
}

/* ── Typografie ──────────────────────────────────────────────── */

.slide h1 {
  max-width: 14ch;
  font-size: clamp(2rem, 3.7vw, 3.75rem);
  line-height: 0.98;
}

.slide h2 {
  max-width: 22ch;
  margin-bottom: 18px;
  font-size: clamp(1.75rem, 2.9vw, 3.05rem);
  line-height: 1.02;
}

.slide .s-copy > p,
.slide .s-two p {
  color: var(--dim);
  font-size: clamp(0.98rem, 1.12vw, 1.1rem);
  line-height: 1.58;
}

.slide .lead {
  max-width: 560px;
}

.slide-hero .lead {
  margin-bottom: 0;
}

.slide-hero .hero-actions {
  margin-top: 24px;
}

.slide a:not(.button):not(.brand) {
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
  text-underline-offset: 3px;
}

.deck-hint {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.deck-hint kbd {
  padding: 1px 6px;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  font: inherit;
  font-size: 0.78rem;
}

html:not(.js-deck) .deck-hint {
  display: none;
}

/* ── Start ───────────────────────────────────────────────────── */

.slide-hero,
.slide-hero:nth-child(odd) {
  background: var(--bg);
}

.slide > .slide-video {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.slide-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(30, 29, 35, 0.9) 0%, rgba(30, 29, 35, 0.66) 46%, rgba(30, 29, 35, 0.5) 100%),
    radial-gradient(circle at 12% 26%, rgba(226, 119, 232, 0.18), transparent 30rem),
    radial-gradient(circle at 82% 16%, rgba(81, 57, 223, 0.16), transparent 36rem);
}

html[data-theme="light"] .slide > .slide-video {
  display: none;
}

html[data-theme="light"] .slide-hero::before {
  background:
    linear-gradient(90deg, rgba(247, 247, 251, 0.92) 0%, rgba(247, 247, 251, 0.76) 46%, rgba(247, 247, 251, 0.62) 100%),
    url("screenshots/hero-bg-production-office-light.webp") center top / cover no-repeat;
}

.slide-hero .proof-strip {
  width: 100%;
  max-width: 1680px;
  margin: clamp(18px, 3vh, 32px) auto 0;
}

/* ── Screens mit Kamerafahrt ─────────────────────────────────── */

.shot {
  min-width: 0;
  margin: 0;
}

.shot-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: var(--ar, 1.6);
  width: min(100%, calc(var(--shot-h) * var(--ar, 1.6)));
  margin-inline: auto;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #09090b;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(81, 57, 223, 0.14);
}

html[data-theme="light"] .shot-frame {
  box-shadow: 0 24px 60px rgba(30, 29, 35, 0.22);
}

.shot-canvas {
  position: absolute;
  inset: 0;
  transform-origin: var(--fx, 50%) var(--fy, 50%);
}

.shot-canvas img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Lichtkegel auf die Stelle, um die es geht */
.shot-ring {
  position: absolute;
  border: 2px solid #e6f88a;
  border-radius: 6px;
  box-shadow: 0 0 0 9999px rgba(9, 9, 11, 0.4), 0 0 28px rgba(230, 248, 138, 0.35);
  opacity: 0;
  pointer-events: none;
}

html:not(.js-deck) .shot-ring {
  display: none;
}

/* Die Folie kommt nah am Ausschnitt an und fährt auf den ganzen Screen zurück;
   der Ring bleibt dort stehen, wo es hingeht. Klick holt den Ausschnitt heran. */
html.js-deck .slide .shot-canvas {
  transform: scale(var(--z, 1.4));
  transition: none;
}

html.js-deck .slide.is-on .shot-canvas {
  transform: none;
  transition: transform 1.8s cubic-bezier(0.3, 0.6, 0.2, 1) 1.1s;
}

html.js-deck .slide.is-on .shot-ring {
  opacity: 1;
  transition: opacity 0.7s ease 2.6s;
}

html.js-deck .slide.is-on .shot.is-nah .shot-canvas {
  transform: scale(var(--z, 1.4));
  transition: transform 0.6s ease;
}

html.js-deck .shot-frame {
  cursor: zoom-in;
}

html.js-deck .shot.is-nah .shot-frame {
  cursor: zoom-out;
}

.shot-frame:focus-visible {
  outline: 2px solid var(--brand-2);
  outline-offset: 3px;
}

.shot figcaption {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 16px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.4;
}

html.js-deck .shot figcaption::after {
  content: "Klick zoomt hinein";
  color: var(--muted);
  opacity: 0.75;
}

html.js-deck .shot.is-nah figcaption::after {
  content: "Klick zeigt den ganzen Screen";
}

/* ── Bausteine ───────────────────────────────────────────────── */

.s-statement {
  max-width: 22ch;
  margin-bottom: clamp(28px, 6vh, 64px);
  font-size: clamp(2.1rem, 4.4vw, 4.4rem);
  line-height: 0.98;
}

.s-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.s-card {
  padding: clamp(20px, 2.4vw, 32px);
  border: 1px solid var(--line);
  background: var(--panel);
}

.slide:nth-child(even) .s-card {
  background: var(--bg);
}

.s-num {
  display: block;
  margin-bottom: 18px;
  color: var(--brand-2);
  font-size: clamp(2.2rem, 3.6vw, 3.4rem);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.s-card p {
  margin: 0;
  color: var(--text);
  font-size: clamp(1.02rem, 1.35vw, 1.28rem);
  line-height: 1.42;
}

.s-statement-wide {
  max-width: 40ch;
  hyphens: manual;
}

.s-cards-2 {
  grid-template-columns: repeat(2, 1fr);
}

.s-card h3 {
  margin: 0 0 12px;
  color: var(--brand-2);
  font-size: clamp(1.3rem, 1.9vw, 1.75rem);
  line-height: 1.15;
}

.s-cards-2 .s-card p {
  font-size: clamp(0.98rem, 1.15vw, 1.12rem);
}

.s-cards-2 .s-list {
  margin-top: 16px;
}

.s-questions {
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
  counter-reset: q;
}

.s-questions li {
  counter-increment: q;
  display: grid;
  grid-template-columns: 2.6rem minmax(0, 0.9fr) minmax(0, 1.35fr);
  gap: 6px 28px;
  align-items: start;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.s-questions li::before {
  content: counter(q, decimal-leading-zero);
  grid-row: span 2;
  color: var(--brand-2);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.5;
}

.s-questions h3 {
  grid-row: span 2;
  margin: 0;
  font-size: clamp(1rem, 1.3vw, 1.22rem);
  line-height: 1.3;
}

.s-questions p {
  margin: 0;
  color: var(--dim);
  font-size: 0.94rem;
  line-height: 1.5;
}

.s-where {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.s-areas {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
}

.s-areas li {
  padding: 14px 16px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
}

.s-areas li:nth-child(2n) {
  border-right: 0;
}

.s-areas li:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.s-areas strong {
  display: block;
  margin-bottom: 4px;
  font-size: 0.95rem;
}

.s-areas span {
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.4;
}

.s-list {
  display: grid;
  gap: 10px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}

.s-list li {
  position: relative;
  padding-left: 26px;
  color: var(--text);
  font-size: clamp(0.95rem, 1.08vw, 1.04rem);
  line-height: 1.45;
}

.s-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.68em;
  width: 14px;
  height: 2px;
  background: var(--brand-2);
}

.s-formula {
  margin: 24px 0 0;
  padding: 16px 18px;
  border: 1px solid var(--line-strong);
  border-left: 3px solid var(--lime);
  background: var(--panel);
  color: var(--text) !important;
  font-size: clamp(1.05rem, 1.5vw, 1.35rem) !important;
  font-weight: 700;
}

.s-formula span,
.s-count {
  color: var(--lime);
}

html[data-theme="light"] .s-formula span,
html[data-theme="light"] .s-count {
  color: var(--brand);
}

.s-count {
  display: inline-block;
  min-width: 1.15ch;
  font-variant-numeric: tabular-nums;
}

.slide .s-note {
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.85rem;
}

/* ── Manifest und Gründer ────────────────────────────────────── */

.deck-track > .slide.slide-manifest:nth-child(n) {
  background-color: var(--lime);
  background-image:
    radial-gradient(circle at 88% 12%, rgba(0, 0, 0, 0.05), transparent 40%),
    radial-gradient(circle at 6% 90%, rgba(0, 0, 0, 0.06), transparent 42%);
  color: #16160e;
}

.s-manifesto {
  max-width: 1080px;
  margin: 0 0 clamp(28px, 6vh, 64px);
  color: #16160e;
  font-size: clamp(1.9rem, 4.3vw, 4.1rem);
  font-weight: 800;
  line-height: 1.03;
  letter-spacing: -0.025em;
}

.s-manifesto .ink-hl {
  text-decoration: underline;
  text-decoration-thickness: 0.09em;
  text-underline-offset: 0.08em;
  text-decoration-color: rgba(22, 22, 14, 0.35);
}

.s-founder {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 24px;
  align-items: center;
  max-width: 960px;
  padding-top: 28px;
  border-top: 1px solid rgba(0, 0, 0, 0.15);
}

.s-founder img {
  width: 112px;
  height: 112px;
  border-radius: 50%;
  object-fit: cover;
}

.s-founder p {
  margin: 0;
  color: rgba(22, 22, 14, 0.78);
  font-size: 0.98rem;
  line-height: 1.55;
}

.s-founder .s-founder-head {
  margin-bottom: 8px;
  color: #16160e;
  font-size: clamp(1.1rem, 1.6vw, 1.4rem);
  font-weight: 800;
  line-height: 1.25;
}

.s-sig {
  display: block;
  margin-top: 28px;
  color: rgba(22, 22, 14, 0.62);
  font-family: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

/* ── Sicherheit, Fragen, Kontakt ─────────────────────────────── */

.s-security {
  display: grid;
  gap: 12px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.s-security li {
  padding: 14px 16px;
  border: 1px solid var(--line);
  background: var(--panel);
}

.slide:nth-child(even) .s-security li {
  background: var(--bg);
}

.s-security strong {
  display: block;
  margin-bottom: 4px;
}

.s-security span {
  color: var(--dim);
  font-size: 0.92rem;
  line-height: 1.5;
}

.slide .faq {
  max-width: none;
  padding: 0;
}

.slide .faq summary {
  padding: 14px 16px;
  font-size: 0.95rem;
}

.slide .faq details p {
  padding: 0 16px 16px;
  font-size: 0.92rem;
}

.slide .s-two.cta {
  max-width: 1400px;
}

.slide .contact-form {
  margin-top: 0;
}

.s-lockup {
  width: min(320px, 70%);
  margin-top: 36px;
  opacity: 0.9;
}

html[data-theme="light"] .s-lockup {
  filter: invert(1);
}

.slide .footer {
  width: 100%;
  max-width: 1400px;
  margin: clamp(32px, 6vh, 64px) auto 0;
  padding: 22px 0 4px;
}

/* ── Leiste unten: Blättern, Fortschritt, Pflichtlinks ───────── */

.deck-bar {
  display: none;
}

html.js-deck .deck-bar {
  position: relative;
  z-index: 20;
  flex: none;
  display: flex;
  align-items: center;
  gap: 14px;
  height: var(--deck-bar-h);
  padding: 0 clamp(12px, 3vw, 40px);
  border-top: 1px solid var(--line);
  background: rgba(30, 29, 35, 0.92);
  backdrop-filter: blur(18px);
  color: var(--muted);
  font-size: 0.85rem;
}

html.js-deck[data-theme="light"] .deck-bar {
  background: rgba(247, 247, 251, 0.94);
}

.deck-progress {
  position: absolute;
  top: -2px;
  left: 0;
  right: 0;
  height: 2px;
}

.deck-progress i {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  transition: width 0.6s ease;
}

.deck-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.18s ease, background-color 0.18s ease;
}

.deck-btn svg {
  width: 18px;
  height: 18px;
}

.deck-btn:hover {
  border-color: rgba(81, 57, 223, 0.6);
  background: rgba(81, 57, 223, 0.14);
}

.deck-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.deck-title {
  flex: 0 1 220px;
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.deck-dots {
  flex: 1;
  display: flex;
  justify-content: center;
  gap: 2px;
}

.deck-dots button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.deck-dots button::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 4px;
  background: var(--line-strong);
  transition: width 0.3s ease, background-color 0.3s ease;
}

.deck-dots button:hover::before {
  background: var(--muted);
}

.deck-dots button[aria-current="true"]::before {
  width: 20px;
  background: var(--brand-2);
}

.deck-btn:focus-visible,
.deck-dots button:focus-visible {
  outline: 2px solid var(--brand-2);
  outline-offset: 2px;
}

.deck-count {
  flex: none;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.deck-legal {
  flex: none;
  display: flex;
  gap: 14px;
  margin-left: 6px;
  font-size: 0.8rem;
}

.deck-legal a:hover {
  color: var(--text);
}

/* ── Schmal: Laptop mit wenig Höhe, Tablet, Handy ────────────── */

@media (max-width: 1100px) {
  .deck-legal {
    display: none;
  }
}

@media (max-width: 860px) {
  :root {
    --shot-h: 62vh;
  }

  .s-split,
  .s-two,
  .s-cards {
    grid-template-columns: 1fr;
  }

  .s-split {
    gap: 28px;
  }

  .s-questions li {
    grid-template-columns: 2.2rem minmax(0, 1fr);
  }

  .s-questions li::before {
    grid-row: span 3;
  }

  .s-questions h3 {
    grid-row: auto;
  }

  .s-founder {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 16px;
  }

  .s-founder img {
    width: 72px;
    height: 72px;
  }

  .deck-dots {
    display: none;
  }

  .deck-title {
    flex: 1;
  }

  .deck-legal {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-left: 0;
    font-size: 0.72rem;
    line-height: 1.35;
  }
}

@media (prefers-reduced-motion: reduce) {
  html.js-deck .deck-track,
  html.js-deck .b,
  html.js-deck .slide.is-on .shot-canvas,
  html.js-deck .slide.is-on .shot-ring {
    transition: none;
  }

  html.js-deck .slide.is-pre .b {
    opacity: 1;
    transform: none;
  }
}
