@font-face {
  font-family: "Outfit";
  font-weight: 300 800;
  font-display: swap;
  src: url("../assets/fonts/outfit-variable.woff2") format("woff2");
}
@font-face {
  font-family: "Playfair Display";
  font-weight: 700 900;
  font-display: swap;
  src: url("../assets/fonts/playfair-display-variable.woff2") format("woff2");
}
@font-face {
  font-family: "Playfair Display";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("../assets/fonts/playfair-display-italic-variable.woff2") format("woff2");
}

/* Farben wie crazysun.de */
:root {
  --o: #F76B1C;
  --o-text: #C2410C;      /* Orange für kleine Schrift/Fokus: 4,9:1 auf Creme (WCAG AA), --o hat nur 2,8:1 */
  --o-big: #E35A0E;       /* Orange für große Schrift (h2 em, Prozentwerte): ≥ 3:1 auf Weiß/Creme */
  --cream: #FFF7EE;
  --ink: #1A0E05;
  --mid: #7A5C45;
  --dim: #866A55;         /* vorher #B09A88 (2,5:1) → 4,7:1 auf Creme */
  --line: rgba(122, 92, 69, .16);
  --field-bd: rgba(122, 92, 69, .5);   /* Feldrahmen deutlicher als --line (vorher .16) */
  --grad: linear-gradient(135deg, #F76B1C, #F9A825);
  --glass-bg: rgba(255, 255, 255, .62);
  --glass-bd: rgba(255, 255, 255, .85);
  --glass-sh: 0 8px 32px rgba(247, 107, 28, .12), inset 0 1px 0 rgba(255, 255, 255, .9);

  --serif: "Playfair Display", Georgia, serif;
  --sans: "Outfit", system-ui, sans-serif;
  --gutter: clamp(16px, 5vw, 64px);
  --radius: 28px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  min-height: 100vh;
  font-family: var(--sans); font-size: 16px; line-height: 1.6; color: var(--ink);
  background:
    radial-gradient(60vmax 50vmax at -10% 8%, rgba(249, 168, 37, .38), transparent 60%),
    radial-gradient(55vmax 45vmax at 110% 40%, rgba(247, 107, 28, .2), transparent 60%),
    radial-gradient(50vmax 40vmax at 0% 95%, rgba(255, 179, 0, .16), transparent 60%),
    var(--cream);
  -webkit-font-smoothing: antialiased;
}
body.no-scroll { overflow: hidden; }
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
button, input { font: inherit; color: inherit; }
h1, h2 { font-family: var(--serif); font-weight: 900; line-height: 1.04; letter-spacing: -.02em; text-wrap: balance; }
h2 em { font-style: italic; font-weight: 700; color: var(--o-big); }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Tastatur-Fokus überall sichtbar (Maus-Klicks zeigen keinen Rahmen) */
:focus-visible { outline: 3px solid var(--o-text); outline-offset: 3px; }
.link:focus-visible, .legal a:focus-visible { border-radius: 4px; }

/* Glas-Karte ohne backdrop-filter: dahinter liegt nur der ruhige Creme-Verlauf, die Unschärfe war unsichtbar, kostete aber beim Scrollen */
.card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-bd);
  border-radius: var(--radius);
  box-shadow: var(--glass-sh);
}

/* ---------- Buttons ---------- */
.btn, .dock {
  align-items: center; justify-content: center;
  min-height: 56px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--grad); color: #fff; font-weight: 700; font-size: 17px; text-decoration: none;
  touch-action: manipulation;
}
.btn {
  display: inline-flex; gap: 8px; padding: 0 32px;
  box-shadow: 0 10px 28px -8px rgba(247, 107, 28, .55);
  transition: transform .15s, box-shadow .2s;
}
.btn:hover { box-shadow: 0 14px 34px -8px rgba(247, 107, 28, .7); }
.btn:active { transform: scale(.97); }
.btn.big { min-height: 62px; min-width: 240px; font-size: 18px; }
.btn.ghost { background: rgba(255, 255, 255, .7); color: var(--ink); border: 1.5px solid rgba(247, 107, 28, .3); box-shadow: none; }
.btn[disabled] { opacity: .65; cursor: default; }
/* Kein Würfeltag (landing.js setzt .wait + disabled): als Hinweis lesbar statt blass-orange */
.btn.wait, .btn.wait:hover { opacity: 1; background: #fff; color: var(--o-text); border: 1.5px dashed rgba(194, 65, 12, .45); box-shadow: none; transform: none; }
.link { border: 0; background: none; padding: 0; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Kopfzeile ---------- */
.top {
  position: sticky; z-index: 20; top: 0;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: max(10px, env(safe-area-inset-top)) max(var(--gutter), env(safe-area-inset-right)) 10px max(var(--gutter), env(safe-area-inset-left));
  background: rgba(255, 247, 238, .78);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, .7);
}
.logo { display: block; border-radius: 6px; }
.logo img { width: 116px; }
/* Kein dunkles Feld (wie crazysun.de): außerhalb der Würfeltage hell mit orangem Rand */
.days {
  padding: 8px 14px; border-radius: 999px;
  background: #fff; color: var(--o-text); border: 1.5px solid rgba(247, 107, 28, .35);
  font-size: 13px; font-weight: 600; white-space: nowrap;
}
.days.live { background: var(--grad); color: #fff; border-color: transparent; }
.days.live::before {
  content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 8px; border-radius: 50%;
  background: #fff; vertical-align: 1px; animation: blink 1.6s ease-in-out infinite;
}

/* ---------- Einstieg: Hand + Würfel ---------- */
.hero { position: relative; padding: 0 var(--gutter) 48px; overflow-x: clip; scroll-margin-top: 70px; }
.hand {
  position: relative; z-index: 3; pointer-events: none; mix-blend-mode: multiply;   /* weißer Fotohintergrund verschwindet */
  width: 150%; margin-left: -8%;                     /* Hand ragt rechts aus dem Bild */
  aspect-ratio: 1400 / 791; container-type: inline-size;
}
.hand img { position: absolute; inset: 0; width: 100%; height: 100%; transition: transform .6s cubic-bezier(.2, .8, .2, 1); }
.hand-b { opacity: 0; }
.released .hand-a { opacity: 0; }
.released .hand-b { opacity: 1; }
.released .hand img { transform: translate(1.5%, -3%) rotate(-2deg); }

/* Stelle des Würfels im Foto (Mitte 38,55 % / 75,67 %, Kante ≈ 16,5 % der Bildbreite) */
.die-anchor { position: absolute; left: 38.55%; top: 75.67%; width: 16.5%; aspect-ratio: 1; translate: -50% -50%; }
/* 3D-Würfel: eine Zeichenfläche über dem ganzen Einstieg */
.die3d { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 4; pointer-events: none; visibility: hidden; }
.released .die3d { visibility: visible; }

.hero-copy { position: relative; z-index: 2; margin-top: -4%; text-align: center; transition: opacity .25s, transform .25s; }
.rolling .hero-copy { opacity: 0; transform: translateY(10px); }
.eyebrow { font-size: 12.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--o); }
h1 { margin-top: 8px; font-size: clamp(40px, 11.5vw, 76px); }
.lead { margin: 14px auto 0; max-width: 34ch; font-size: 16.5px; color: var(--mid); }
.lead strong { color: var(--ink); font-weight: 600; }
.hero-copy .btn { margin-top: 22px; width: 100%; max-width: 380px; }
.trust { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 16px; margin-top: 16px; list-style: none; font-size: 13.5px; color: var(--mid); }
.trust li::before { content: "✓"; margin-right: 6px; color: var(--o); font-weight: 700; }

/* Landeplatz, Ergebnis, Formular */
.play { position: relative; z-index: 2; text-align: center; max-width: 520px; margin: 0 auto; }
.landing { position: relative; height: 150px; scroll-margin-top: 84px; }
.shadow {
  position: absolute; left: 50%; bottom: 14px; width: 110px; height: 16px; translate: -50% 0;
  border-radius: 50%; background: rgba(122, 60, 20, .32); filter: blur(8px); opacity: 0;
}
.touch .shadow, .landed .shadow { opacity: 1; transition: opacity .3s; }
.result {
  font-family: var(--serif); font-weight: 900; font-size: clamp(28px, 7.5vw, 40px); line-height: 1.12;
  opacity: 0; transform: translateY(12px); transition: opacity .5s, transform .5s;
}
.landed .result { opacity: 1; transform: none; }
.play .form, .play #toThanks { margin-top: 22px; }
.form { padding: 24px 20px; display: grid; gap: 14px; text-align: left; animation: pop .6s .15s cubic-bezier(.2, .9, .3, 1.2) both; }
.form .step { text-align: center; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--dim); }
.form-intro { text-align: center; color: var(--mid); margin-top: -6px; }
.field { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
.field input {
  width: 100%; min-height: 52px; padding: 0 16px; border-radius: 16px;
  border: 1.5px solid var(--line); background: #fff; font-size: 16px; font-weight: 400;
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus { outline: none; border-color: var(--o); box-shadow: 0 0 0 4px rgba(247, 107, 28, .15); }
[aria-invalid="true"] { border-color: #C2410C !important; }
.hint { margin-top: -4px; font-size: 13px; color: var(--mid); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.check { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; font-size: 13px; line-height: 1.5; color: var(--mid); cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: 1px; accent-color: var(--o); }
.check .link { color: var(--ink); font-size: inherit; }
.error { min-height: 1em; font-size: 14px; font-weight: 600; color: #C2410C; text-align: center; }
.error:empty { display: none; }
.form .btn { width: 100%; }

/* ---------- So geht's ---------- */
.how { padding: 24px var(--gutter) 56px; max-width: 1120px; margin: 0 auto; }
.how h2 { font-size: clamp(32px, 8.5vw, 52px); text-align: center; }
.steps { margin-top: 26px; display: grid; gap: 12px; list-style: none; counter-reset: s; }
.steps li { counter-increment: s; position: relative; padding: 18px 20px 18px 74px; border-radius: 22px; background: var(--glass-bg); border: 1px solid var(--glass-bd); box-shadow: var(--glass-sh); }
.steps li::before {
  content: counter(s); position: absolute; left: 18px; top: 50%; translate: 0 -50%;
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: var(--grad); color: #fff; font: 900 20px var(--serif);
}
.steps b { display: block; font-size: 16px; }
.steps span { display: block; font-size: 14px; color: var(--mid); }

.table-title { margin-top: 40px; text-align: center; font-size: 20px; font-weight: 700; }
.table { margin-top: 14px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; list-style: none; }
.table li { padding: 16px 8px; border-radius: 22px; background: #fff; border: 1px solid var(--line); text-align: center; }
.table li.best { background: var(--grad); border-color: transparent; color: #fff; box-shadow: 0 12px 28px -10px rgba(247, 107, 28, .6); }
.table .pips { display: block; font-size: 12.5px; font-weight: 600; color: var(--mid); }
.table li.best .pips { color: rgba(255, 255, 255, .9); }
.table .pct { display: block; margin-top: 2px; font: 900 34px/1.1 var(--serif); color: var(--o); }
.table li.best .pct { color: #fff; }

.stamp { margin-top: 20px; padding: 20px; display: grid; gap: 14px; }
.stamp p { font-size: 14.5px; color: var(--mid); }
.stamp b { color: var(--ink); }
.stamp-dots { display: grid; grid-template-columns: repeat(10, 1fr); gap: 6px; }
.stamp-dots i { aspect-ratio: 1; border-radius: 50%; border: 1.5px dashed rgba(247, 107, 28, .45); }
.stamp-dots i.on { border: 0; background: var(--grad); }
.stamp-dots i.gift { border-style: solid; background: rgba(249, 168, 37, .18); }

/* ---------- Studio ---------- */
.studio { padding: 0 var(--gutter) 56px; max-width: 1120px; margin: 0 auto; display: grid; gap: 24px; }
.studio-img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 70%; border-radius: var(--radius); }
.studio h2 { font-size: clamp(32px, 8.5vw, 52px); }
.addr { margin-top: 12px; font-size: 16px; }
.hours { margin-top: 14px; list-style: none; display: grid; font-size: 14.5px; color: var(--mid); max-width: 340px; }
.hours li { display: flex; justify-content: space-between; padding: 7px 0; border-bottom: 1px solid var(--line); }
.hours li.action { color: var(--ink); font-weight: 600; }
.hours li.action span:first-child::after { content: " · Würfeltag"; color: var(--o); }
.studio .btn { margin-top: 22px; }

/* ---------- Fußzeile ---------- */
.foot { padding: 32px var(--gutter) 110px; font-size: 13px; color: var(--mid); text-align: center; border-top: 1px solid var(--line); }
.foot details { max-width: 640px; margin: 0 auto; text-align: left; }
.foot summary { cursor: pointer; font-weight: 600; color: var(--ink); text-align: center; }
.foot details p { margin-top: 10px; }
.legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; margin-top: 20px; }
.legal a, .legal .link { color: var(--mid); font-size: 13px; text-decoration: underline; text-underline-offset: 3px; }
.copy { margin-top: 10px; color: var(--dim); }

/* Fester Button unten (mobil) */
.dock {
  position: fixed; z-index: 15; left: 16px; right: 16px; bottom: max(16px, env(safe-area-inset-bottom));
  min-height: 56px; display: grid; place-items: center; border-radius: 999px;
  background: var(--grad); color: #fff; font-weight: 700; font-size: 17px; text-decoration: none;
  box-shadow: 0 14px 30px -10px rgba(247, 107, 28, .7);
  transition: opacity .3s, translate .3s;
}
.dock.hide, .dock.busy { opacity: 0; translate: 0 20px; pointer-events: none; }

/* ---------- Bestätigungsseite ---------- */
.thanks { max-width: 520px; margin: 0 auto; padding: 20px var(--gutter) 40px; display: grid; gap: 16px; }
.thanks-page .foot { padding-bottom: 40px; }
.testmode { padding: 10px 14px; border-radius: 14px; background: #FFF3C4; color: #7A5200; font-size: 13.5px; font-weight: 600; text-align: center; }
.coupon { overflow: hidden; padding: 0; animation: pop .6s cubic-bezier(.2, .9, .3, 1.2) both; }
.coupon-top { position: relative; padding: 22px 24px 20px; background: var(--grad); color: #fff; }
.coupon-label { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; opacity: .92; }
.coupon-value { font-family: var(--serif); font-weight: 900; font-size: 88px; line-height: 1; margin-top: 4px; }
.coupon-value small { font-size: .5em; margin-left: 4px; }
.coupon-top.neutral .coupon-value { font-size: 56px; }
.coupon-eyes { position: absolute; right: 24px; bottom: 22px; font-size: 14px; }
.coupon-eyes b { font-size: 20px; }
.coupon-bottom { padding: 22px 24px 24px; border-top: 2px dashed rgba(247, 107, 28, .3); background: #fff; }
.coupon-bottom h1 { font-size: clamp(28px, 7.5vw, 36px); }
.thanks-text { margin-top: 10px; color: var(--mid); font-size: 16px; }
.when { padding: 20px 24px; text-align: center; }
.when-label { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--dim); }
.when-days { margin-top: 2px; font: 900 32px/1.15 var(--serif); color: var(--o); }
.when-next { margin-top: 6px; font-weight: 600; }
.when-hint { margin-top: 6px; font-size: 14px; color: var(--mid); }
.where { padding: 20px 24px 24px; }
.where .addr { margin-top: 0; }
.where .btn { margin-top: 18px; width: 100%; }

/* ---------- Impressum / Datenschutz ---------- */
.modal {
  position: fixed; z-index: 50; inset: 0; padding: 16px;
  display: grid; place-items: center; background: rgba(26, 14, 5, .45);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.modal-box {
  position: relative; width: min(640px, 100%); max-height: 86vh; overflow: auto;
  padding: 28px 22px 24px; border-radius: 24px; background: #fff; outline: none;
}
.modal-close {
  position: sticky; top: 0; float: right; width: 40px; height: 40px; margin: -12px -8px 0 0;
  border: 0; border-radius: 50%; background: var(--cream); font-size: 24px; line-height: 1; cursor: pointer;
}
.modal-body h2 { font-size: 28px; margin-bottom: 12px; }
.modal-body h3 { margin-top: 18px; font-size: 15px; }
.modal-body p { margin-top: 6px; font-size: 14.5px; color: var(--mid); }

/* ---------- Desktop ---------- */
@media (min-width: 900px) {
  .logo img { width: 140px; }
  .hero {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); column-gap: 32px; align-items: center;
    min-height: calc(100svh - 70px); padding: 24px 0 64px max(var(--gutter), calc((100% - 1200px) / 2));
  }
  .hand { grid-column: 2; grid-row: 1; width: 128%; margin: 0; align-self: center; }
  .hero-copy, .play { grid-column: 1; grid-row: 1; }
  .hero-copy { margin: 0; text-align: left; }
  .lead { margin-left: 0; font-size: 18.5px; }
  .hero-copy .btn { width: auto; }
  .trust { justify-content: flex-start; }
  .play { margin: 0; max-width: 480px; }
  .landing { height: 190px; }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .table { max-width: 640px; margin-left: auto; margin-right: auto; }
  .stamp { max-width: 640px; margin-left: auto; margin-right: auto; }
  .studio { grid-template-columns: 1fr 1fr; align-items: center; gap: 56px; }
  .studio-img { aspect-ratio: 4 / 5; max-height: 640px; }
  .foot { padding-bottom: 40px; }
  .dock { display: none; }
}

@keyframes pop { from { opacity: 0; transform: translateY(16px) scale(.96); } }
@keyframes blink { 50% { opacity: .35; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .days.live::before, .form, .coupon { animation: none; }
  .hand img, .hero-copy, .result { transition: none; }
}
