/* ============================================================
   SAYA — marketing site
   Design system derived 1:1 from the app ("Evening Glow"):
   docs/design_guidelines.md + lib/constants/app_design_constants.dart
   ============================================================ */

/* ---------- Fonts (self-hosted variable fonts, GDPR) ---------- */
@font-face { font-family: 'Rubik'; font-weight: 300 900; font-style: normal; font-display: swap; src: url('../fonts/rubik-var.woff2') format('woff2'); }
@font-face { font-family: 'Plus Jakarta Sans'; font-weight: 200 800; font-style: normal; font-display: swap; src: url('../fonts/jakarta-var.woff2') format('woff2'); }

/* ---------- Tokens ---------- */
:root {
  /* app theme tokens */
  --navy: #1A284D;         /* primary (light theme) */
  --navy-2: #384E86;       /* primary (dark theme)  */
  --terracotta: #E6A78B;   /* secondary             */
  --peach: #EDBEA8;        /* tertiary              */
  --ink: #101323;          /* primaryText light     */
  --slate: #64748B;        /* secondaryText light   */
  --paper: #F6F6F8;        /* primaryBackground     */
  --card: #FFFFFF;         /* secondaryBackground   */
  --night: #0D0F1B;        /* dark primaryBackground */
  --night-2: #12182D;      /* dark secondaryBackground */
  --moon-1: #FBFCFE;       /* dark primaryText      */
  --moon-2: #BDCCEC;       /* dark secondaryText    */

  /* logo brand accents (sampled from SAYA mark) */
  --teal: #54A8A6;
  --teal-deep: #2D6189;
  --sun-1: #ED5F48;
  --sun-2: #F68F58;
  --sun-3: #FBB464;

  /* data colors (ChartColors) */
  --pos: #27AE60;
  --neg: #E74C3C;
  --hrv: #B71C1C;
  --deep-sleep: #1A3A5C;
  --light-sleep: #4A7BA7;
  --rem: #E8A020;
  --score-good: #34C759;
  --score-fair: #FFD700;
  --score-warn: #FF9500;
  --score-bad: #FF3B30;
  --score-top: #1B7F3B;

  /* chronotype palette */
  --ct-1: #F6A623; --ct-2: #E49A3D; --ct-3: #C9A24E; --ct-4: #4FA67A;
  --ct-5: #4A8FB0; --ct-6: #3F6EA5; --ct-7: #34406E;

  /* shadows (FFShadows, 10% black) */
  --sh-sm: 0 1px 3px rgba(0,0,0,.10);
  --sh-md: 0 3px 6px rgba(0,0,0,.10);
  --sh-lg: 0 8px 15px rgba(0,0,0,.10);
  --sh-xl: 0 16px 25px rgba(0,0,0,.10);

  /* type */
  --f-display: 'Rubik', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-body: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* current theme (night default; sections override) */
  --t1: var(--moon-1);
  --t2: var(--moon-2);
  --surface: rgba(18, 24, 45, .85);        /* glass on night-2 */
  --hairline: rgba(251, 252, 254, .16);
  --accent: var(--terracotta);

  --nav-h: 72px;
  --radius: 12px;
  --ease-out: cubic-bezier(.22, .8, .3, 1);
}

/* light sections flip the theme tokens */
.on-light {
  --t1: var(--ink);
  --t2: var(--slate);
  --surface: rgba(255, 255, 255, .85);
  --hairline: rgba(16, 19, 35, .10);
  color: var(--t1); /* re-declare so inherited text picks up the scoped token */
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--t1);
  background: var(--night);
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--f-display); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--terracotta); outline-offset: 3px; border-radius: 4px; }
::selection { background: rgba(230, 167, 139, .35); }

.container { width: min(1120px, 92vw); margin-inline: auto; }
.section { position: relative; padding: clamp(72px, 10vw, 128px) 0; }

.eyebrow {
  font-family: var(--f-display); font-weight: 500; font-size: .8125rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--accent);
  display: flex; align-items: center; gap: 10px; margin-bottom: 14px;
}
.eyebrow::before { content: ''; width: 26px; height: 1.5px; background: var(--accent); border-radius: 1px; }
.h-xl { font-size: clamp(2.6rem, 6vw, 4.4rem); font-weight: 700; letter-spacing: -.02em; }
.h-lg { font-size: clamp(1.9rem, 3.6vw, 2.6rem); font-weight: 700; }
.h-md { font-size: clamp(1.35rem, 2.4vw, 1.6rem); font-weight: 500; }
.lead { font-size: clamp(1.1rem, 1.8vw, 1.3rem); color: var(--t2); max-width: 34em; }
.muted { color: var(--t2); }
.small { font-size: .875rem; }

/* ============================================================
   SKY ENGINE — four fixed layers, crossfaded by scroll (JS)
   ============================================================ */
.sky { position: fixed; inset: 0; z-index: -2; pointer-events: none; }
.sky__layer { position: absolute; inset: 0; opacity: 0; transition: none; will-change: opacity; }
.sky__layer--dusk {
  opacity: 1;
  background:
    radial-gradient(120% 70% at 50% 108%, rgba(246, 143, 88, .28) 0%, rgba(230, 167, 139, .10) 34%, transparent 62%),
    linear-gradient(180deg, #0D0F1B 0%, #131A36 44%, #1A284D 78%, #35395E 100%);
}
.sky__layer--night {
  background:
    radial-gradient(90% 55% at 82% -8%, rgba(56, 78, 134, .35) 0%, transparent 60%),
    linear-gradient(180deg, #0A0C16 0%, #0D0F1B 55%, #101529 100%);
}
.sky__layer--dawn {
  background:
    radial-gradient(120% 75% at 50% 112%, rgba(246, 143, 88, .55) 0%, rgba(237, 190, 168, .30) 38%, transparent 66%),
    linear-gradient(180deg, #101529 0%, #1A284D 34%, #4A527E 62%, #B98A7C 86%, #EDBEA8 100%);
}
.sky__layer--day { background: linear-gradient(180deg, #F1E7E0 0%, #F6F6F8 40%, #F6F6F8 100%); }

/* aurora blobs — OnboardingGlow: blur >= 60, warm/cool alphas, 20-30s drift */
.aurora { position: absolute; border-radius: 50%; filter: blur(72px); will-change: transform; }
.aurora--warm { background: var(--terracotta); opacity: .16; }
.aurora--peach { background: var(--peach); opacity: .14; }
.aurora--cool { background: var(--navy-2); opacity: .22; }
.aurora--teal { background: var(--teal); opacity: .12; }
.aurora--a { width: 44vw; height: 44vw; top: -12vw; right: -10vw; animation: drift-a 26s ease-in-out infinite alternate; }
.aurora--b { width: 36vw; height: 36vw; bottom: -14vw; left: -8vw; animation: drift-b 30s ease-in-out infinite alternate; }
.aurora--c { width: 28vw; height: 28vw; top: 30%; left: 38%; animation: drift-a 22s ease-in-out infinite alternate-reverse; }
@keyframes drift-a { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(-6vw, 4vw, 0) scale(1.12); } }
@keyframes drift-b { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(5vw, -4vw, 0) scale(1.08); } }

/* star field (inside night layers) */
.stars { position: absolute; inset: 0; overflow: hidden; }
.stars span {
  position: absolute; width: 2px; height: 2px; border-radius: 50%;
  background: #FBFCFE; opacity: .7; animation: twinkle 4s ease-in-out infinite;
}
.stars span:nth-child(3n) { animation-delay: 1.3s; width: 1.5px; height: 1.5px; }
.stars span:nth-child(4n) { animation-delay: 2.2s; opacity: .45; }
.stars span:nth-child(5n) { animation-delay: 3.1s; width: 2.5px; height: 2.5px; }
@keyframes twinkle { 0%, 100% { opacity: .15; } 50% { opacity: .8; } }

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: center;
  transition: background .4s var(--ease-out), box-shadow .4s var(--ease-out), backdrop-filter .4s var(--ease-out);
}
.nav.is-scrolled {
  background: rgba(13, 15, 27, .72);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(251,252,254,.08), var(--sh-md);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; width: min(1200px, 94vw); margin-inline: auto; }
.nav__brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-family: var(--f-display); font-weight: 700; font-size: 1.25rem; letter-spacing: .06em; color: #FBFCFE; }
.nav__brand img { width: 34px; height: 34px; border-radius: 9px; box-shadow: var(--sh-sm); }
.nav__links { display: flex; align-items: center; gap: 26px; font-family: var(--f-display); font-weight: 500; font-size: .95rem; }
.nav__links a { text-decoration: none; color: #BDCCEC; transition: color .25s; }
.nav__links a:hover { color: #FBFCFE; }
.nav__cta {
  padding: 9px 18px; border-radius: 25px; color: #FBFCFE !important;
  background: linear-gradient(180deg, #22345F, #1A284D);
  border: 1px solid rgba(251,252,254,.14);
  transition: box-shadow .3s, transform .3s;
}
.nav__cta:hover { box-shadow: 0 0 15px rgba(230,167,139,.35); transform: translateY(-1px); }
.lang-switch { display: flex; align-items: center; gap: 2px; font-size: .85rem; border: 1px solid rgba(251,252,254,.18); border-radius: 25px; padding: 3px; }
.lang-switch a { text-decoration: none; padding: 3px 10px; border-radius: 25px; color: #BDCCEC; }
.lang-switch a.is-active { background: rgba(251,252,254,.14); color: #FBFCFE; }
.nav__burger { display: none; }

/* ============================================================
   BUTTONS / FORMS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--f-display); font-weight: 500; font-size: 1.02rem;
  padding: 15px 30px; border-radius: 25px; border: 0; cursor: pointer;
  text-decoration: none; transition: transform .3s var(--ease-out), box-shadow .3s var(--ease-out), filter .3s;
}
.btn--hero {
  color: #FBFCFE;
  background: linear-gradient(180deg, #24356390 0%, #1A284D 0%), linear-gradient(180deg, #253764, #1A284D);
  background: linear-gradient(180deg, #253764, #1A284D);
  box-shadow: 0 0 15px rgba(26, 40, 77, .25), var(--sh-md);
  border: 1px solid rgba(251, 252, 254, .12);
}
.btn--hero:hover { transform: translateY(-2px); box-shadow: 0 0 22px rgba(230, 167, 139, .45), var(--sh-lg); }
.btn--dawn {
  color: #fff;
  background: linear-gradient(180deg, var(--sun-2), var(--sun-1));
  box-shadow: 0 0 15px rgba(237, 95, 72, .30), var(--sh-md);
}
.btn--dawn:hover { transform: translateY(-2px); box-shadow: 0 0 24px rgba(237, 95, 72, .5), var(--sh-lg); }
.btn--ghost { color: var(--t1); background: transparent; border: 1.5px solid var(--hairline); }
.btn--ghost:hover { border-color: var(--terracotta); box-shadow: 0 0 12px rgba(230,167,139,.25); }

.waitlist { max-width: 520px; }
.waitlist__row { display: flex; gap: 10px; }
.waitlist input[type="email"] {
  flex: 1; min-width: 0;
  font: 500 1rem var(--f-body); color: var(--t1);
  padding: 15px 20px; border-radius: 25px;
  background: var(--surface);
  border: 1.5px solid var(--hairline);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  transition: border-color .3s, box-shadow .3s;
}
.waitlist input[type="email"]::placeholder { color: var(--t2); }
.waitlist input[type="email"]:focus { outline: none; border-color: var(--terracotta); box-shadow: 0 0 12px rgba(230, 167, 139, .30); }
.waitlist__hint { font-size: .8125rem; color: var(--t2); margin-top: 10px; }
.waitlist__hint a { color: inherit; }
.waitlist__msg { margin-top: 12px; font-weight: 600; font-size: .95rem; display: none; }
.waitlist__msg.is-ok { display: block; color: var(--pos); }
.waitlist__msg.is-err { display: block; color: var(--neg); }
.hp-field { position: absolute; left: -5000px; opacity: 0; pointer-events: none; }

/* ============================================================
   GLASS CARDS
   ============================================================ */
.glass {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  box-shadow: var(--sh-lg);
}
.glass--blur { -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }

/* ============================================================
   HERO
   ============================================================ */
.hero { min-height: 100svh; display: flex; align-items: center; padding: calc(var(--nav-h) + 48px) 0 64px; }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero__moon { position: absolute; top: calc(var(--nav-h) + 3vh); right: 8vw; width: 68px; height: 68px; pointer-events: none; filter: drop-shadow(0 0 18px rgba(84, 168, 166, .55)); }
.hero h1 { margin-bottom: 20px; }
.hero .lead { margin-bottom: 34px; }
.hero__aside { position: relative; display: flex; justify-content: center; }
.hero__meta { display: flex; gap: 22px; margin-top: 30px; flex-wrap: wrap; }
.hero__meta div { font-size: .85rem; color: var(--moon-2); display: flex; align-items: center; gap: 8px; }
.hero__meta svg { width: 16px; height: 16px; flex: none; }

.scroll-cue {
  position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%);
  width: 26px; height: 42px; border: 1.5px solid rgba(251,252,254,.35); border-radius: 14px;
}
.scroll-cue::after {
  content: ''; position: absolute; left: 50%; top: 8px; width: 3px; height: 8px;
  border-radius: 2px; background: var(--terracotta); transform: translateX(-50%);
  animation: cue 2.2s ease-in-out infinite;
}
@keyframes cue { 0% { opacity: 0; top: 7px; } 35% { opacity: 1; } 100% { opacity: 0; top: 22px; } }

/* ---------- Phone frame ---------- */
.phone {
  width: min(320px, 78vw);
  border-radius: 44px;
  padding: 12px;
  background: linear-gradient(160deg, #2A3050, #12182D 60%, #1E2440);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .55), inset 0 1px 1px rgba(255,255,255,.14);
  position: relative;
}
.phone__screen { border-radius: 34px; background: var(--paper); overflow: hidden; position: relative; }
.phone__notch {
  position: absolute; top: 20px; left: 50%; transform: translateX(-50%);
  width: 86px; height: 22px; border-radius: 12px; background: #0A0C16; z-index: 3;
}
.phone--float { animation: float 7s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(0) rotate(0.001deg); } 50% { transform: translateY(-12px) rotate(0.001deg); } }
.phone__glow {
  position: absolute; inset: -12%; z-index: -1; border-radius: 50%;
  background: radial-gradient(50% 50% at 50% 55%, rgba(84,168,166,.30) 0%, rgba(230,167,139,.16) 45%, transparent 72%);
  filter: blur(30px);
  animation: ringpulse 1.6s ease-in-out infinite;
}

/* ---------- In-phone app UI (light app world, app-faithful) ---------- */
.app { font-family: var(--f-body); color: var(--ink); font-size: 12px; line-height: 1.45; }
.app__status { display: flex; justify-content: space-between; padding: 12px 20px 4px; font: 600 11px var(--f-body); color: var(--ink); }
.app__title { font: 700 17px var(--f-display); text-align: center; padding: 10px 0 8px; background: #fff; box-shadow: var(--sh-sm); position: relative; z-index: 2; }
.app__tabs { display: flex; justify-content: space-around; background: #fff; padding: 8px 12px 0; font: 500 12.5px var(--f-display); color: var(--slate); box-shadow: var(--sh-sm); }
.app__tabs span { padding-bottom: 7px; }
.app__tabs .is-on { color: var(--ink); font-weight: 700; border-bottom: 2.5px solid var(--navy); }
.app__body { padding: 14px 12px 0; display: grid; gap: 10px; background: var(--paper); }
.app__nav { display: flex; justify-content: space-around; align-items: center; background: #fff; border-radius: 16px 16px 0 0; margin-top: 12px; padding: 9px 0 10px; box-shadow: 0 -2px 8px rgba(0,0,0,.06); }
.app__nav div { display: grid; justify-items: center; gap: 2px; font: 500 9px var(--f-body); color: #9AA1B5; }
.app__nav .is-on { color: var(--navy); }
.app__nav svg { width: 17px; height: 17px; }

.acard { background: #fff; border-radius: 12px; box-shadow: var(--sh-md); padding: 12px; }
.acard__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.acard__title { font: 500 12.5px var(--f-display); color: var(--ink); display: flex; align-items: center; gap: 7px; }
.acard__chip { font: 500 9.5px var(--f-display); padding: 3px 8px; border-radius: 25px; background: #FFF7DA; color: #8A6D00; }
.icon-dot { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: rgba(26, 40, 77, .08); }
.icon-dot svg { width: 13px; height: 13px; }

/* score ring (gauge radius 45 / stroke 10, app-canonical) */
.ring-wrap { display: grid; place-items: center; padding: 6px 0 2px; position: relative; }
.ring-glow { position: absolute; width: 128px; height: 128px; border-radius: 50%; background: radial-gradient(50% 50%, rgba(52, 199, 89, .18) 0%, transparent 70%); animation: ringpulse 1.6s ease-in-out infinite; }
@keyframes ringpulse { 0%, 100% { transform: scale(1); opacity: .85; } 50% { transform: scale(1.08); opacity: 1; } }
.ring { transform: rotate(-90deg); }
.ring__track { fill: none; stroke: #EAECF2; stroke-width: 10; }
.ring__val { fill: none; stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 1.2s var(--ease-out); }
.ring-num { position: absolute; text-align: center; }
.ring-num b { display: block; font: 700 30px/1 var(--f-display); color: var(--ink); }
.ring-num span { font: 500 9.5px var(--f-display); color: var(--slate); letter-spacing: .06em; text-transform: uppercase; }

.comp { display: grid; gap: 7px; margin-top: 8px; }
.comp__row { display: grid; grid-template-columns: 86px 1fr 30px; align-items: center; gap: 8px; font: 500 10.5px var(--f-body); color: var(--slate); }
.comp__bar { height: 5px; border-radius: 3px; background: #EAECF2; overflow: hidden; }
.comp__bar i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, var(--terracotta), var(--peach)); transform-origin: left; transform: scaleX(0); transition: transform 1s var(--ease-out); }
.comp__row b { text-align: right; font: 600 10.5px var(--f-body); color: var(--ink); }
.is-in .comp__bar i { transform: scaleX(1); }

/* charts inside app cards */
.chart-svg { width: 100%; height: auto; }
.chart-svg .grid-l { stroke: #EAECF2; stroke-width: 1; }
.chart-svg .axis-t { font: 500 8px var(--f-body); fill: var(--slate); }
.chart-svg .lbl { font: 600 9px var(--f-display); }
.draw-line { fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.is-in .draw-line { animation: draw 1.6s var(--ease-out) forwards; }
@keyframes draw { from { stroke-dashoffset: var(--len, 900); } to { stroke-dashoffset: 0; } }
.fade-area { opacity: 0; transition: opacity .9s ease .9s; }
.is-in .fade-area { opacity: 1; }
.pulse-dot { animation: dotpulse 2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes dotpulse { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.7); opacity: .55; } }

/* ============================================================
   TRUST STRIP
   ============================================================ */
.trust { padding: 26px 0; border-block: 1px solid rgba(251, 252, 254, .08); }
.trust__row { display: flex; align-items: center; justify-content: center; gap: clamp(18px, 4vw, 54px); flex-wrap: wrap; font: 500 .85rem var(--f-display); color: var(--moon-2); letter-spacing: .04em; }
.trust__row span { display: flex; align-items: center; gap: 9px; }
.trust__row svg { width: 17px; height: 17px; opacity: .85; }

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 44px; }
.step { padding: 26px 24px; }
.step__no { font: 700 .8rem var(--f-display); letter-spacing: .12em; color: var(--terracotta); margin-bottom: 12px; display: block; }
.step h3 { font-size: 1.2rem; margin-bottom: 8px; }
.step p { color: var(--t2); font-size: .95rem; margin: 0; }

/* ============================================================
   NIGHT TIMELINE (acts) — thread + feature blocks
   ============================================================ */
.acts { position: relative; }
.thread { position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; transform: translateX(-50%); }
.thread svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.thread line { stroke: url(#threadGrad); stroke-width: 2.5; }
.thread .thread__bg { stroke: rgba(251, 252, 254, .10); }

.act { position: relative; padding: clamp(56px, 8vw, 96px) 0; }
.act__marker {
  position: relative; z-index: 2;
  width: fit-content; margin: 0 auto clamp(36px, 5vw, 64px);
  display: flex; align-items: center; gap: 10px;
  font: 500 .9rem var(--f-display); letter-spacing: .1em;
  color: var(--moon-2);
  background: rgba(18, 24, 45, .85); border: 1px solid var(--hairline);
  padding: 8px 18px; border-radius: 25px; box-shadow: var(--sh-md);
}
.on-light .act__marker { background: rgba(255,255,255,.85); color: var(--slate); }
.act__marker b { color: var(--t1); font-weight: 700; letter-spacing: .02em; }
.act__marker .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--terracotta); box-shadow: 0 0 10px var(--terracotta); }

.feature { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 6vw, 84px); align-items: center; padding: clamp(30px, 4vw, 52px) 0; }
.feature__copy { max-width: 30em; }
.feature__copy .h-lg { margin-bottom: 16px; }
.feature__copy p { color: var(--t2); }
.feature__fact {
  margin-top: 20px; padding: 13px 16px; border-radius: var(--radius);
  border: 1px solid var(--hairline); background: rgba(251, 252, 254, .05);
  font-size: .875rem; color: var(--t2); display: flex; gap: 10px; align-items: flex-start;
}
.on-light .feature__fact { background: rgba(16, 19, 35, .04); }
.feature__fact svg { width: 16px; height: 16px; flex: none; margin-top: 3px; color: var(--teal); }
.feature__fact b { color: var(--t1); }
.feature--flip .feature__copy { order: 2; justify-self: start; }
.feature--flip .feature__visual { order: 1; }
.feature__visual { display: flex; justify-content: center; }
.mock { width: min(430px, 100%); padding: 18px; position: relative; }
.mock--pad { padding: 22px; }

/* habit chips (M4) */
.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  font: 500 10.5px var(--f-display); color: var(--ink);
  border: 1.5px solid #E3E5EC; border-radius: 25px; padding: 5px 11px; background: #fff;
  transition: border-color .4s, background .4s, box-shadow .4s;
}
.chip svg { width: 11px; height: 11px; opacity: 0; transform: scale(.4); transition: opacity .3s, transform .3s; }
.chip.is-sel { border-color: var(--terracotta); background: rgba(230, 167, 139, .12); box-shadow: 0 0 12px rgba(230, 167, 139, .20); }
.chip.is-sel svg { opacity: 1; transform: scale(1); color: #B4593A; }

/* correlation bars (M4) */
.corr { display: grid; gap: 9px; }
.corr__row { display: grid; grid-template-columns: 1fr 92px; gap: 10px; align-items: center; font: 500 10.5px var(--f-body); color: var(--ink); }
.corr__lbl small { display: block; color: var(--slate); font-size: 9px; }
.corr__meter { position: relative; height: 7px; border-radius: 4px; background: #EAECF2; }
.corr__meter i {
  position: absolute; top: 0; bottom: 0; border-radius: 4px;
  transform: scaleX(0); transition: transform .9s var(--ease-out);
}
.corr__meter i.neg { right: 50%; transform-origin: right; background: var(--neg); }
.corr__meter i.pos { left: 50%; transform-origin: left; background: var(--pos); }
.corr__meter::after { content: ''; position: absolute; left: 50%; top: -2px; bottom: -2px; width: 1.5px; background: #C9CDD8; }
.is-in .corr__meter i { transform: scaleX(1); }
.corr__val { font-weight: 700; text-align: right; }
.corr__val.neg { color: var(--neg); }
.corr__val.pos { color: var(--pos); }

/* timing rows (M5, mirrors the app's "Your ideal timing" card) */
.timing { display: grid; gap: 4px; }
.timing__row { display: flex; align-items: center; gap: 11px; padding: 8px 4px; border-bottom: 1px solid #F0F1F5; font: 500 11.5px var(--f-body); color: var(--ink); }
.timing__row:last-child { border-bottom: 0; }
.timing__icon { width: 30px; height: 30px; border-radius: 50%; flex: none; display: grid; place-items: center; background: rgba(26, 40, 77, .07); }
.timing__icon.is-night { background: var(--navy); color: #fff; }
.timing__icon svg { width: 15px; height: 15px; }
.timing__row b { margin-left: auto; font: 700 13px var(--f-display); color: var(--ink); white-space: nowrap; }
.timing__row small { color: var(--slate); display: block; font-size: 9.5px; }

/* chronotype (M6) */
.ct-scale { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin: 14px 0 6px; }
.ct-seg { height: 10px; border-radius: 5px; opacity: .28; transition: opacity .5s, transform .5s; }
.ct-seg.is-on { opacity: 1; transform: scaleY(1.35); }
.ct-labels { display: flex; justify-content: space-between; font: 500 9px var(--f-body); color: var(--slate); margin-bottom: 12px; }
.ct-animal { display: flex; align-items: center; gap: 13px; padding-top: 6px; }
.ct-animal__glyph {
  width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; font-size: 30px;
  background: radial-gradient(60% 60%, rgba(237, 190, 168, .55) 0%, rgba(237, 190, 168, .12) 75%);
  box-shadow: 0 0 20px rgba(237, 190, 168, .45);
}
.ct-animal b { font: 700 15px var(--f-display); color: var(--ink); display: block; }
.ct-animal small { color: var(--slate); font-size: 10px; }

/* ============================================================
   DAWN CTA (light world)
   ============================================================ */
.dawn { text-align: center; }
.dawn .h-xl { margin-bottom: 16px; }
.dawn .lead { margin-inline: auto; margin-bottom: 36px; }
.dawn .waitlist { margin-inline: auto; }
.dawn__sun { width: 74px; height: 74px; margin: 0 auto 26px; filter: drop-shadow(0 0 22px rgba(246, 143, 88, .6)); }

/* science teaser */
.sci-teaser { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.sci-teaser__card { padding: 26px; }
.sci-list { list-style: none; padding: 0; margin: 18px 0 26px; display: grid; gap: 12px; }
.sci-list li { display: flex; gap: 12px; align-items: flex-start; color: var(--t2); }
.sci-list svg { width: 18px; height: 18px; flex: none; margin-top: 4px; color: var(--teal); }
.sci-list b { color: var(--t1); }

/* ============================================================
   FOOTER
   ============================================================ */
.footer { background: #0B0E1A; border-top: 1px solid rgba(251, 252, 254, .08); padding: 56px 0 34px; color: var(--moon-2); font-size: .9rem; }
.footer a { color: var(--moon-2); text-decoration: none; }
.footer a:hover { color: #FBFCFE; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 34px; margin-bottom: 38px; }
.footer__brand { display: flex; align-items: center; gap: 11px; font: 700 1.15rem var(--f-display); color: #FBFCFE; letter-spacing: .06em; margin-bottom: 12px; }
.footer__brand img { width: 30px; height: 30px; border-radius: 8px; }
.footer h4 { font: 500 .85rem var(--f-display); letter-spacing: .1em; text-transform: uppercase; color: #7C89AD; margin-bottom: 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.footer__legal { border-top: 1px solid rgba(251, 252, 254, .08); padding-top: 22px; display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; font-size: .8rem; color: #7C89AD; }

/* ============================================================
   REVEALS
   ============================================================ */
.rv { opacity: 0; transform: translateY(26px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
.rv.is-in { opacity: 1; transform: none; }
.rv-d1 { transition-delay: .1s; } .rv-d2 { transition-delay: .2s; } .rv-d3 { transition-delay: .3s; }

/* ============================================================
   SCIENCE PAGE
   ============================================================ */
.page-head { padding: calc(var(--nav-h) + 64px) 0 40px; }
.article { display: grid; grid-template-columns: 220px 1fr; gap: clamp(28px, 5vw, 72px); align-items: start; }
.article__toc { position: sticky; top: calc(var(--nav-h) + 24px); font-family: var(--f-display); font-size: .9rem; display: grid; gap: 4px; }
.article__toc a { text-decoration: none; color: var(--t2); padding: 7px 12px; border-left: 2px solid var(--hairline); transition: color .25s, border-color .25s; }
.article__toc a:hover, .article__toc a.is-here { color: var(--t1); border-color: var(--terracotta); }
.article__body { max-width: 46em; }
.article__body h2 { font-size: clamp(1.6rem, 2.8vw, 2.1rem); margin: 2.2em 0 .6em; scroll-margin-top: calc(var(--nav-h) + 24px); }
.article__body h2:first-of-type { margin-top: 0; }
.article__body h3 { font-size: 1.2rem; margin: 1.8em 0 .5em; }
.article__body figure { margin: 1.8em 0; }
.article__body figcaption { font-size: .82rem; color: var(--t2); margin-top: 10px; }
.callout { border-left: 3px solid var(--teal); background: rgba(84, 168, 166, .08); border-radius: 0 var(--radius) var(--radius) 0; padding: 16px 20px; margin: 1.6em 0; font-size: .95rem; }
.refs { font-size: .85rem; color: var(--t2); }
.refs li { margin-bottom: .6em; }

/* ============================================================
   LEGAL PAGES
   ============================================================ */
.legal-body { max-width: 46em; }
.legal-body h2 { font-size: 1.35rem; margin-top: 2em; }
.legal-body h3 { font-size: 1.1rem; margin-top: 1.5em; }
.notice {
  border: 1.5px dashed var(--terracotta); border-radius: var(--radius);
  background: rgba(230, 167, 139, .08); padding: 14px 18px; font-size: .9rem; margin: 1.4em 0;
}
.placeholder { background: rgba(230, 167, 139, .18); border-radius: 4px; padding: 1px 6px; font-weight: 600; }
/* Markdown-sourced legal pages: render the leading "Hinweis" blockquote as the notice box */
.legal-body blockquote {
  margin: 1.4em 0; padding: 14px 18px; font-size: .9rem;
  border: 1.5px dashed var(--terracotta); border-radius: var(--radius);
  background: rgba(230, 167, 139, .08);
}
.legal-body blockquote p { margin: 0; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 960px) {
  .hero__grid, .sci-teaser { grid-template-columns: 1fr; }
  .hero { padding-top: calc(var(--nav-h) + 24px); }
  .hero__aside { order: 2; margin-top: 44px; }
  .hero__moon { width: 46px; height: 46px; right: 6vw; }
  .steps { grid-template-columns: 1fr; }
  .feature, .feature--flip .feature__copy, .feature--flip .feature__visual { display: block; }
  .feature { padding-left: 44px; }
  .feature__visual { margin-top: 28px; justify-content: flex-start; }
  .thread { left: 14px; transform: none; }
  .act__marker { margin-left: 44px; margin-right: 0; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .article { grid-template-columns: 1fr; }
  .article__toc { position: static; display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
  .article__toc a { border-left: 0; border: 1px solid var(--hairline); border-radius: 25px; padding: 6px 14px; }
  .nav__links { display: none; }
  .nav__burger {
    display: grid; place-items: center; width: 42px; height: 42px;
    background: transparent; border: 1px solid rgba(251,252,254,.2); border-radius: 12px; color: #FBFCFE; cursor: pointer;
  }
  .nav__menu {
    position: fixed; top: var(--nav-h); left: 0; right: 0; z-index: 49;
    display: none; padding: 18px 4vw 26px;
    background: rgba(13, 15, 27, .96); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(251,252,254,.1);
  }
  .nav__menu.is-open { display: grid; gap: 4px; }
  .nav__menu a { padding: 13px 8px; text-decoration: none; color: #E7ECFA; font: 500 1.05rem var(--f-display); border-bottom: 1px solid rgba(251,252,254,.07); }
}
@media (min-width: 961px) { .nav__menu { display: none !important; } }
@media (max-width: 560px) {
  .waitlist__row { flex-direction: column; }
  .footer__grid { grid-template-columns: 1fr; gap: 24px; }
  .feature { padding-left: 34px; }
  .act__marker { margin-left: 34px; font-size: .8rem; }
  .thread { left: 10px; }
}

/* ============================================================
   REDUCED MOTION — decorative motion off, content intact
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .aurora, .stars span, .phone--float, .phone__glow, .ring-glow, .pulse-dot, .scroll-cue::after { animation: none !important; }
  .rv { opacity: 1; transform: none; transition: none; }
  .draw-line { animation: none !important; stroke-dashoffset: 0 !important; }
  .fade-area { opacity: 1; transition: none; }
  .comp__bar i, .corr__meter i { transform: scaleX(1); transition: none; }
  .ring__val { transition: none; }
}
