/* slowdawnapp.com
   The app's night-to-dawn palette (Shared/Design/SkyPalette.swift). No web fonts, no third-party
   requests: Apple devices get New York and SF; everything else falls back gracefully. */

:root {
  --night: #070B1F;
  --deep: #0B1026;
  --navy: #141B3D;
  --indigo: #2A2F6B;
  --dusk: #5B4B8A;
  --peach: #FFB27A;
  --gold: #F4C27A;
  --mist: #CFE6F7;
  --text: #F1F3FA;
  --soft: #C3C9DF;
  --muted: #8F97B6;
  --line: rgba(207, 230, 247, 0.12);
  --card: rgba(26, 33, 73, 0.55);
  --serif: ui-serif, "New York", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: system-ui, -apple-system, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --rounded: ui-rounded, "SF Pro Rounded", system-ui, -apple-system, sans-serif;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--deep);
  color: var(--text);
  font: 17px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--peach); text-decoration-color: rgba(255, 178, 122, 0.4); text-underline-offset: 3px; }
a:hover { color: var(--gold); text-decoration-color: currentColor; }
img, video { max-width: 100%; height: auto; display: block; }

.wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding-left: max(24px, env(safe-area-inset-left, 0px));
  padding-right: max(24px, env(safe-area-inset-right, 0px));
}
.narrow { max-width: 760px; }

/* ---------- Type ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.015em; text-wrap: balance; margin: 0; }
h1 { font-size: clamp(42px, 6.4vw, 76px); line-height: 1.02; }
h2 { font-size: clamp(32px, 4.2vw, 50px); line-height: 1.08; }
h3 { font-size: 23px; line-height: 1.25; }
h1 em, h2 em { font-style: italic; color: var(--peach); }
p { margin: 0; text-wrap: pretty; }
.eyebrow {
  font: 600 13px/1 var(--sans); letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 18px;
}
.lede { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.6; color: var(--soft); max-width: 36ch; }
.muted { color: var(--muted); }

/* ---------- Header ---------- */
.top {
  position: absolute; inset: 0 0 auto; z-index: 5;
  padding-top: env(safe-area-inset-top, 0px);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 22px; }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--text); text-decoration: none; font: 600 19px/1 var(--rounded); letter-spacing: -0.01em; }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.top nav { display: flex; gap: 26px; font-size: 15px; }
.top nav a { color: var(--soft); text-decoration: none; }
.top nav a:hover, .top nav a[aria-current] { color: var(--text); }

/* ---------- Hero: night sky warming at the horizon ---------- */
.hero {
  position: relative; z-index: 1;
  background:
    radial-gradient(90% 55% at 72% 100%, rgba(255, 178, 122, 0.30), transparent 62%),
    radial-gradient(60% 40% at 72% 100%, rgba(244, 194, 122, 0.22), transparent 60%),
    linear-gradient(180deg, var(--night) 0%, #0D1433 38%, #262D63 74%, #4A3B78 100%);
}
.hero::before {
  /* a few faint stars, high in the sky */
  content: ""; position: absolute; inset: 0 0 45% 0; pointer-events: none; opacity: 0.55;
  background-image:
    radial-gradient(1.2px 1.2px at 12% 22%, #fff, transparent),
    radial-gradient(1px 1px at 28% 12%, #fff, transparent),
    radial-gradient(1.4px 1.4px at 41% 30%, #fff, transparent),
    radial-gradient(1px 1px at 57% 9%, #fff, transparent),
    radial-gradient(1.2px 1.2px at 66% 26%, #fff, transparent),
    radial-gradient(1px 1px at 83% 14%, #fff, transparent),
    radial-gradient(1.3px 1.3px at 92% 34%, #fff, transparent),
    radial-gradient(1px 1px at 6% 48%, #fff, transparent),
    radial-gradient(1px 1px at 35% 52%, #fff, transparent);
}
.hero::after {
  /* the horizon glow fades into the night of the next section instead of stopping at a line */
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; pointer-events: none;
  background: linear-gradient(180deg, rgba(11, 16, 38, 0), var(--deep));
}
.hero-grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center;
  padding-top: calc(120px + env(safe-area-inset-top, 0px));
  padding-bottom: 0;
}
.hero-grid > * { min-width: 0; }
.hero-copy { padding-bottom: 96px; }
.hero h1 { margin-bottom: 26px; }
.hero .lede { margin-bottom: 36px; }

.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.store {
  display: inline-flex; flex-direction: column; align-items: flex-start; gap: 3px;
  padding: 11px 22px; border-radius: 14px; max-width: 100%;
  background: #000; color: #fff; text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.28);
  line-height: 1.15;
}
.store svg { width: 24px; height: 24px; flex: none; }
.store span { display: block; font-size: 12px; letter-spacing: 0.02em; opacity: 0.75; }
.store strong { display: block; font: 600 18px/1.2 var(--sans); overflow-wrap: anywhere; }
.store:hover { color: #fff; border-color: rgba(255, 255, 255, 0.6); }
.cta-note { font-size: 15px; color: var(--soft); line-height: 1.5; }

/* ---------- Phone ---------- */
.phone {
  position: relative; width: min(100%, 330px); aspect-ratio: 1320 / 2868; max-width: 100%;
  border-radius: 54px; padding: 10px;
  background: linear-gradient(160deg, #3a3f5c, #14182c 40%, #23283f);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.08) inset,
    0 40px 80px -20px rgba(0, 0, 0, 0.6),
    0 0 120px -10px rgba(255, 178, 122, 0.25);
}
.phone > img, .phone > video {
  width: 100%; height: 100%; object-fit: cover; border-radius: 45px; background: var(--deep);
}
.hero .phone { justify-self: center; align-self: end; margin-bottom: -150px; width: min(100%, 350px); z-index: 2; }
.hero + section { padding-top: clamp(84px, 11vw, 140px); }
@media (min-width: 901px) { .hero + section .section-head { max-width: 560px; } }

/* ---------- Sections ---------- */
section { padding-block: clamp(84px, 11vw, 140px); }
/* One continuous night sky under every section: no seams between them. */
main { background: linear-gradient(180deg, var(--deep) 0%, var(--navy) 30%, #10173A 65%, var(--navy) 100%); }
.band, .band-alt { background: transparent; }
.section-head { max-width: 720px; margin-bottom: 56px; }
.section-head p { margin-top: 18px; font-size: 19px; color: var(--soft); max-width: 58ch; }
.center { text-align: center; margin-left: auto; margin-right: auto; }
.center p { margin-left: auto; margin-right: auto; }

/* Three steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; counter-reset: step; }
.step { border-top: 1px solid var(--line); padding-top: 26px; min-width: 0; }
.step::before {
  counter-increment: step; content: counter(step, decimal-leading-zero);
  display: block; font: 500 15px/1 var(--rounded); color: var(--peach); letter-spacing: 0.06em; margin-bottom: 18px;
}
.step h3 { margin-bottom: 10px; }
.step p { color: var(--soft); }

/* Scenarios */
.scenes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.scene {
  background: var(--card); border: 1px solid var(--line); border-radius: 22px;
  padding: 26px 26px 24px; min-width: 0;
  display: flex; flex-direction: column; gap: 10px;
  backdrop-filter: blur(6px);
}
.scene h3 { font-size: 21px; }
.scene p { color: var(--soft); font-size: 16px; }
.reason {
  margin-top: auto; align-self: flex-start;
  display: inline-block;
  padding: 8px 14px; border-radius: 14px;
  background: rgba(7, 11, 31, 0.6); border: 1px solid var(--line);
  font: 500 14px/1.3 var(--rounded); color: var(--mist);
}
.reason b { font-weight: 600; color: var(--peach); font-variant-numeric: tabular-nums; margin-right: 8px; }

/* Feature rows */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 7vw, 110px); align-items: center; }
.feature > * { min-width: 0; }
.feature .phone { justify-self: center; width: min(100%, 320px); }
.feature.flip .feature-copy { order: 2; }
.feature-copy h2 { margin-bottom: 22px; }
.feature-copy p { color: var(--soft); font-size: 18px; max-width: 44ch; }
.feature-copy p + p { margin-top: 14px; }
.tick-list { list-style: none; padding: 0; margin: 26px 0 0; display: grid; gap: 12px; }
.tick-list li { position: relative; padding-left: 30px; color: var(--soft); }
.tick-list li::before {
  content: ""; position: absolute; left: 2px; top: 0.55em; width: 12px; height: 12px; border-radius: 50%;
  background: radial-gradient(circle at 50% 60%, var(--gold), var(--peach));
  box-shadow: 0 0 12px rgba(255, 178, 122, 0.6);
}

/* Promise band: science + privacy */
.promises { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.promise { min-width: 0; }
.promise h3 { font-size: 22px; margin-bottom: 10px; }
.promise p { color: var(--soft); font-size: 16px; }
.promise .src { margin-top: 12px; font-size: 13px; color: var(--muted); }
.promise .src a { color: var(--muted); }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; max-width: 860px; margin: 0 auto; }
.plan { background: var(--card); border: 1px solid var(--line); border-radius: 24px; padding: 34px; }
.plan.pro { border-color: rgba(255, 178, 122, 0.45); background: linear-gradient(180deg, rgba(255, 178, 122, 0.08), rgba(26, 33, 73, 0.55) 45%); }
.plan h3 { font-family: var(--rounded); font-weight: 600; font-size: 20px; letter-spacing: 0; }
.price { font: 500 46px/1.1 var(--serif); margin: 14px 0 4px; letter-spacing: -0.02em; }
.price small { font: 400 16px/1 var(--sans); color: var(--muted); letter-spacing: 0; }
.plan .alt { color: var(--muted); font-size: 15px; }
.plan .tick-list { margin-top: 22px; }
.trial-note { text-align: center; color: var(--muted); font-size: 15px; margin-top: 26px; }

/* Final call */
.finale {
  text-align: center; position: relative; overflow: hidden;
  background:
    radial-gradient(70% 80% at 50% 120%, rgba(255, 178, 122, 0.38), transparent 60%),
    linear-gradient(180deg, var(--navy) 0%, #262D63 60%, #5B4B8A 100%);
}
.finale h2 { font-size: clamp(36px, 5vw, 60px); margin-bottom: 18px; }
.finale p { color: var(--soft); font-size: 19px; margin: 0 auto 34px; max-width: 40ch; }
.finale .cta-row { justify-content: center; }
.sun {
  width: 120px; height: 60px; margin: 0 auto 36px; border-radius: 120px 120px 0 0;
  background: radial-gradient(circle at 50% 100%, #FFD9A8, var(--peach) 55%, rgba(255, 178, 122, 0) 72%);
  filter: blur(0.3px);
}

/* Footer */
footer { background: var(--night); border-top: 1px solid var(--line); padding-block: 40px calc(40px + env(safe-area-inset-bottom, 0px)); font-size: 14px; color: var(--muted); }
footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
footer nav { display: flex; gap: 22px; flex-wrap: wrap; }
footer a { color: var(--soft); text-decoration: none; }
footer a:hover { color: var(--text); }
.copy-mail { user-select: all; color: var(--soft); }

/* Long-form pages (privacy, support) */
.page-head {
  background: linear-gradient(180deg, var(--night), var(--navy));
  padding-top: calc(130px + env(safe-area-inset-top, 0px)); padding-bottom: 56px;
}
.page-head h1 { font-size: clamp(38px, 5.4vw, 60px); }
.page-head p:not(.eyebrow) { margin-top: 16px; color: var(--soft); font-size: 19px; max-width: 56ch; }
.doc { background: var(--navy); padding-block: 56px 110px; }
.doc h2 { font-size: 27px; margin: 52px 0 12px; }
.doc h2:first-child { margin-top: 0; }
.doc p, .doc li { color: #D6DBEC; }
.doc p + p { margin-top: 14px; }
.doc ul { padding-left: 22px; display: grid; gap: 10px; margin: 14px 0 0; }
.summary { background: var(--card); border: 1px solid var(--line); border-left: 3px solid var(--peach); border-radius: 16px; padding: 22px 26px; }

details { border-bottom: 1px solid var(--line); }
details summary {
  cursor: pointer; list-style: none; padding: 20px 0;
  display: flex; justify-content: space-between; align-items: baseline; gap: 20px;
  font: 500 19px/1.4 var(--sans); color: var(--text);
}
details summary::-webkit-details-marker { display: none; }
details summary::after { content: "+"; color: var(--peach); font: 300 26px/1 var(--sans); flex: none; transition: transform .2s; }
details[open] summary::after { transform: rotate(45deg); }
details > div { padding: 0 0 22px; color: #D6DBEC; max-width: 62ch; }
details > div p + p { margin-top: 10px; }
.faq-group { margin-top: 48px; }
.faq-group:first-child { margin-top: 0; }
.faq-group h2 { font-size: 15px; font-family: var(--sans); font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); margin: 0 0 6px; }
.contact-card { margin-top: 56px; background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 30px; }
.contact-card h2 { margin: 0 0 10px; font-size: 26px; }
.contact-card .mail { font: 500 22px/1.3 var(--rounded); color: var(--text); user-select: all; margin-top: 12px; }

/* Gentle reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 1s ease, transform 1s ease; }
.reveal.shown { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Narrow screens ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; padding-top: calc(104px + env(safe-area-inset-top, 0px)); }
  .hero-copy { padding-bottom: 0; }
  .hero .phone { width: min(78%, 320px); margin-bottom: -120px; }
  .hero + section { padding-top: 170px; }
  .steps, .scenes, .promises { grid-template-columns: 1fr; }
  .scenes { gap: 14px; }
  .feature { grid-template-columns: 1fr; }
  .feature.flip .feature-copy { order: 0; }
  .feature .phone { width: min(78%, 300px); }
  .plans { grid-template-columns: 1fr; }
}
@media (min-width: 620px) and (max-width: 900px) {
  .scenes { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
  .top nav { gap: 16px; font-size: 14px; }
  .top nav .hide-sm { display: none; }
  .plan { padding: 26px; }
  .phone { border-radius: 44px; padding: 8px; }
  .phone > img, .phone > video { border-radius: 37px; }
}
