/* deno-baby.app — one stylesheet. Colour tokens come from the app (Nest/DesignSystem/Palette.swift, design brief §3.1).
   Radii follow the brief (24 hero card, 16 cards, 12 tiles, 999 pills). Flat colour only: no gradients, no shadows in dark. */

@font-face {
  font-family: "Nunito";
  src: url("/assets/fonts/Nunito-Variable.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light dark;
  --bg: #FAF8F5;          /* bg.base */
  --surface: #FFFFFF;     /* bg.surface */
  --elevated: #F1EEEA;    /* bg.elevated */
  --rim: #E6E1DA;         /* rim */
  --text: #1C1B22;        /* text.primary */
  --text2: #6B6874;       /* text.secondary */
  --feed: #B06F2C;        /* accent.feed (amber) */
  --diaper: #3A8470;      /* accent.diaper (sage) */
  --sleep: #5652B0;       /* accent.sleep (indigo) */
  --growth: #B0566A;      /* accent.growth (rose) */
  --journal: #8A7232;     /* accent.journal (gold) */
  --pad: #F4E2B2;         /* the hero's round pad: butter by day */
  --night-bg: #12141B;    /* the night band is always the dark ground */
  --night-surface: #1A1D27;
  --night-rim: #2C3142;
  --night-text: #EEF0F5;
  --night-text2: #A2A8B8;
  --shadow: 0 1px 2px rgba(60, 40, 30, .06), 0 8px 24px rgba(60, 40, 30, .06);
  --radius-hero: 24px;
  --radius-card: 16px;
  --radius-tile: 12px;
  --gutter: 20px;
  --font: "Nunito", ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12141B;
    --surface: #1A1D27;
    --elevated: #232736;
    --rim: #2C3142;
    --text: #EEF0F5;
    --text2: #A2A8B8;
    --feed: #EBAC6C;
    --diaper: #84C2AE;
    --sleep: #9C98E0;
    --growth: #E0939E;
    --journal: #D8BE82;
    --pad: #232736;       /* bg.elevated: blue-ink by night */
    --night-bg: #0E0F13;
    --night-surface: #161820;
    --night-rim: #23262F;
    --shadow: none;
  }
}

@media (max-width: 480px) { :root { --gutter: 16px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 16px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-wrap: break-word;
  font-variant-numeric: tabular-nums;
}
img, canvas, svg { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--journal); outline-offset: 3px; border-radius: 8px; }
h1, h2, h3 { font-weight: 800; line-height: 1.12; letter-spacing: -0.015em; margin: 0; text-wrap: balance; }
p { margin: 0 0 12px; }
p:last-child { margin-bottom: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -48px; background: var(--text); color: var(--bg); padding: 10px 14px; border-radius: 999px; z-index: 10; text-decoration: none; font-weight: 700; }
.skip:focus { top: 12px; }
.wrap { max-width: 1120px; margin: 0 auto; padding-inline: var(--gutter); }
.muted { color: var(--text2); }

/* ---------- header / footer ---------- */
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 850; font-size: 22px; letter-spacing: -0.01em; text-decoration: none; }
.brand svg { width: 34px; height: 34px; flex: none; }
.nav { display: flex; gap: 4px 18px; flex-wrap: wrap; justify-content: flex-end; }
.nav a { text-decoration: none; font-weight: 700; color: var(--text2); padding: 6px 2px; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
@media (max-width: 420px) { .nav { gap: 2px 14px; font-size: 15px; } .nav .nav-extra { display: none; } }

.site-footer { border-top: 1px solid var(--rim); padding-block: 32px 44px; color: var(--text2); font-size: 15px; }
.site-footer .wrap { display: grid; gap: 14px; }
.footer-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.footer-links a { color: var(--text2); font-weight: 700; text-decoration: none; }
.footer-links a:hover { color: var(--text); text-decoration: underline; }
.footer-note { max-width: 70ch; margin: 0; }

/* ---------- buttons, pills ---------- */
.pill { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--rim); background: var(--surface); color: var(--text); border-radius: 999px; padding: 6px 14px; font: 700 14px/1.2 var(--font); min-height: 36px; cursor: pointer; }
.pill[hidden] { display: none; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 12px 22px; border-radius: 999px; background: var(--text); color: var(--bg); font-weight: 800; text-decoration: none; }
.btn:hover { text-decoration: none; opacity: .92; }

/* ---------- hero ---------- */
.hero { padding-block: 24px 56px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 32px 48px; align-items: center; }
.eyebrow { font-weight: 800; color: var(--text2); font-size: 15px; margin-bottom: 14px; letter-spacing: .01em; }
.hero h1 { font-size: clamp(42px, 6.4vw, 74px); line-height: 1.02; letter-spacing: -0.03em; }
.lead { font-size: clamp(18px, 2vw, 21px); color: var(--text2); margin-top: 20px; max-width: 34em; }
.store { display: grid; gap: 10px; margin-top: 28px; justify-items: start; }
.store-soon { display: inline-flex; align-items: center; gap: 10px; border-radius: 999px; padding: 12px 20px 12px 16px; background: var(--text); color: var(--bg); font-weight: 800; font-size: 17px; }
.store-soon svg { width: 20px; height: 20px; }
.store-note { color: var(--text2); font-size: 15px; margin: 0; }
.promises { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 0; padding: 0; list-style: none; }
.promises li { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--rim); background: var(--surface); border-radius: 999px; padding: 6px 13px 6px 10px; font-weight: 700; font-size: 14px; }
.promises svg { width: 16px; height: 16px; color: var(--diaper); }

.bub-stage { position: relative; margin: 0; display: grid; justify-items: center; }
.bub-pad { position: relative; width: min(100%, 440px); aspect-ratio: 1; border-radius: 50%; background: var(--pad); }
.bub-pad .stage { position: absolute; inset: 4% 4% 0 4%; width: 92%; height: 96%; padding: 0; border: 0; background: none; cursor: pointer; border-radius: 50%; touch-action: manipulation; }
.bub-pad canvas { width: 100%; height: 100%; }
.bub-tools { margin-top: 12px; min-height: 36px; }
@media (max-width: 820px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .bub-stage { order: -1; }
  .bub-pad { width: min(78%, 320px); }
  .hero { padding-top: 8px; }
}

/* ---------- sections ---------- */
.section { padding-block: 64px; }
.section + .section { border-top: 1px solid var(--rim); }
.section-head { max-width: 40em; margin-bottom: 32px; }
.section-head h2 { font-size: clamp(30px, 4vw, 44px); margin-bottom: 14px; }
.section-head p { color: var(--text2); font-size: 18px; }
.kicker { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 15px; margin-bottom: 12px; }
.kicker svg { width: 18px; height: 18px; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px 64px; align-items: center; }
.split.flip > :first-child { order: 2; }
@media (max-width: 820px) { .split, .split.flip { grid-template-columns: minmax(0, 1fr); } .split.flip > :first-child { order: 0; } .section { padding-block: 52px; } }

.list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.list li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 12px; align-items: start; }
.list svg { width: 22px; height: 22px; margin-top: 3px; }
.list b { font-weight: 800; }
.note { color: var(--text2); font-size: 15px; margin-top: 18px; }

/* ---------- phone shots ---------- */
.phone { margin: 0 auto; width: min(100%, 300px); border-radius: 44px; padding: 8px; background: var(--surface); border: 1px solid var(--rim); box-shadow: var(--shadow); }
.phone img { width: 100%; height: auto; border-radius: 36px; background: var(--bg); }
.phone-pair { display: flex; justify-content: center; gap: 20px; }
.phone-pair .phone { width: min(48%, 280px); }
@media (max-width: 480px) { .phone { border-radius: 36px; padding: 6px; } .phone img { border-radius: 30px; } .phone-pair { gap: 10px; } .phone-pair .phone { width: 50%; } }
figcaption.cap { text-align: center; color: var(--text2); font-size: 14px; margin-top: 12px; }

/* ---------- two taps ---------- */
.taps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.tap { background: var(--surface); border: 1px solid var(--rim); border-radius: var(--radius-card); padding: 20px; display: grid; gap: 14px; align-content: start; }
.tap h3 { font-size: 22px; display: flex; align-items: center; gap: 10px; }
.tap h3 svg { width: 26px; height: 26px; }
.tap p { color: var(--text2); font-size: 16px; }
.steps { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 14px; font-weight: 800; }
.steps span { border-radius: 999px; padding: 5px 11px; background: var(--elevated); }
.steps .first { background: var(--text); color: var(--bg); }
.steps i { font-style: normal; color: var(--text2); font-weight: 600; }
.t-feed { color: var(--feed); } .t-diaper { color: var(--diaper); } .t-sleep { color: var(--sleep); } .t-growth { color: var(--growth); } .t-journal { color: var(--journal); }
@media (max-width: 820px) { .taps { grid-template-columns: minmax(0, 1fr); } }

/* ---------- patterns quote ---------- */
.quote { margin: 0 0 18px; padding: 18px 20px; border-radius: var(--radius-card); background: var(--surface); border: 1px solid var(--rim); font-size: 19px; font-weight: 700; line-height: 1.45; }
.quote span { display: block; position: relative; padding-left: 16px; }
.quote span::before { content: ""; position: absolute; left: 0; top: .2em; bottom: .2em; width: 4px; border-radius: 4px; background: var(--journal); opacity: .5; }

/* ---------- journal card ---------- */
.shot-card { margin: 0; border-radius: var(--radius-hero); overflow: hidden; border: 1px solid var(--rim); background: var(--surface); box-shadow: var(--shadow); }
.shot-card img { width: 100%; height: auto; }

/* ---------- pregnancy fruit ---------- */
.fruit-card { background: var(--surface); border: 1px solid var(--rim); border-radius: var(--radius-hero); padding: 20px; display: grid; gap: 14px; justify-items: center; text-align: center; }
.fruit-canvas { width: min(100%, 300px); aspect-ratio: 1; border-radius: 50%; background: var(--elevated); touch-action: manipulation; }
.fruit-week { font-size: 30px; font-weight: 850; letter-spacing: -0.02em; }
.fruit-line { color: var(--text2); margin: 0; min-height: 1.6em; }
.weeks { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.weeks button { border: 1px solid var(--rim); background: var(--bg); color: var(--text); border-radius: 999px; padding: 7px 13px; min-height: 40px; min-width: 44px; font: 700 15px/1 var(--font); cursor: pointer; }
.weeks button[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.weeks-label { font-size: 14px; color: var(--text2); margin: 0; }

/* ---------- night band (always the dark ground, like night mode) ---------- */
.band-night { background: var(--night-bg); color: var(--night-text); border-top: 0 !important; }
.band-night .section-head p, .band-night .muted, .band-night .note { color: var(--night-text2); }
.band-night .phone { background: var(--night-surface); border-color: var(--night-rim); box-shadow: none; }
.band-night .phone img { background: #0B0B0D; }
.night-row { display: flex; align-items: center; gap: 16px; margin-top: 24px; }
.night-bub { width: 104px; height: 104px; flex: none; border-radius: 50%; background: var(--night-surface); border: 1px solid var(--night-rim); }
.night-bub canvas { width: 100%; height: 100%; }
.band-night .list svg { color: var(--night-text2); }
.band-night + .section { border-top: 0; }

/* ---------- watch ---------- */
.watches { display: flex; justify-content: center; gap: 18px; flex-wrap: wrap; }
.watch { margin: 0; width: min(46%, 208px); border-radius: 46px; padding: 12px; background: #0B0B0D; border: 1px solid var(--rim); }
.watch img { width: 100%; height: auto; border-radius: 34px; }

/* ---------- privacy ---------- */
.privacy-band { background: var(--surface); border-top: 1px solid var(--rim); border-bottom: 1px solid var(--rim); }
.privacy-band + .section { border-top: 0; }
.privacy-hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 24px 56px; align-items: end; margin-bottom: 36px; }
.privacy-hero h2 { font-size: clamp(36px, 5.4vw, 62px); letter-spacing: -0.03em; }
.privacy-hero p { font-size: 19px; color: var(--text2); }
.label-card { border: 1px solid var(--rim); border-radius: var(--radius-card); padding: 18px 20px; background: var(--bg); }
.label-card .label-k { font-size: 14px; font-weight: 800; color: var(--text2); margin-bottom: 4px; }
.label-card .label-v { font-size: 26px; font-weight: 850; display: flex; align-items: center; gap: 10px; }
.label-card .label-v svg { width: 26px; height: 26px; color: var(--diaper); }
.label-card p { font-size: 15px; color: var(--text2); margin-top: 6px; }
.promise-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; list-style: none; margin: 0; padding: 0; }
.promise-grid li { border: 1px solid var(--rim); border-radius: var(--radius-card); padding: 20px; background: var(--bg); }
.promise-grid svg { width: 28px; height: 28px; color: var(--diaper); margin-bottom: 12px; }
.promise-grid h3 { font-size: 20px; margin-bottom: 6px; }
.promise-grid p { color: var(--text2); font-size: 16px; }
.privacy-more { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; }
.privacy-more a { font-weight: 800; }
@media (max-width: 900px) { .promise-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .privacy-hero { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .promise-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- pro ---------- */
.pro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px 56px; align-items: start; }
.pro-card { border: 1px solid var(--rim); border-radius: var(--radius-hero); background: var(--surface); padding: 24px; box-shadow: var(--shadow); }
.pro-card h3 { font-size: 24px; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.pro-card .list { gap: 16px; }
.pro-foot { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--rim); color: var(--text2); font-size: 15px; }
.free-list { columns: 2 180px; column-gap: 24px; padding-left: 20px; margin: 16px 0 0; color: var(--text2); }
.free-list li { margin-bottom: 6px; break-inside: avoid; }
@media (max-width: 820px) { .pro { grid-template-columns: minmax(0, 1fr); } }

/* ---------- closing ---------- */
.closing { text-align: center; padding-block: 64px 40px; }
.closing h2 { font-size: clamp(30px, 4vw, 44px); margin-bottom: 12px; }
.closing p { color: var(--text2); }
.closing .store { justify-items: center; }
.crawl { margin: 28px auto 0; max-width: 760px; height: 132px; cursor: pointer; }
.crawl canvas { width: 100%; height: 100%; }

/* ---------- documents (privacy, terms, support, 404) ---------- */
.doc { max-width: 760px; margin: 0 auto; padding: 28px var(--gutter) 72px; }
.doc h1 { font-size: clamp(36px, 6vw, 52px); letter-spacing: -0.025em; margin-bottom: 10px; }
.doc .meta { color: var(--text2); margin-bottom: 28px; }
.doc h2 { font-size: 24px; margin: 40px 0 12px; padding-top: 22px; border-top: 1px solid var(--rim); scroll-margin-top: 16px; }
.doc h3 { font-size: 19px; margin: 22px 0 6px; }
.doc ul, .doc ol { padding-left: 22px; margin: 0 0 14px; }
.doc li { margin-bottom: 8px; }
.doc .card { background: var(--surface); border: 1px solid var(--rim); border-radius: var(--radius-card); padding: 18px 20px; margin: 22px 0; }
.doc .card h2 { margin-top: 0; padding-top: 0; border-top: 0; font-size: 20px; }
.doc .lead { margin-top: 0; margin-bottom: 20px; }
.faq details { border: 1px solid var(--rim); border-radius: var(--radius-card); background: var(--surface); margin: 0 0 10px; }
.faq summary { cursor: pointer; padding: 16px 48px 16px 20px; font-weight: 800; font-size: 18px; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 22px; top: 50%; width: 10px; height: 10px; border-right: 2px solid var(--text2); border-bottom: 2px solid var(--text2); transform: translateY(-70%) rotate(45deg); }
.faq details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq .a { padding: 0 20px 18px; color: var(--text); }
.faq .a p, .faq .a li { color: var(--text2); }
.faq h2 { border-top: 0; padding-top: 0; margin-top: 36px; }
.mailbox { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; background: var(--surface); border: 1px solid var(--rim); border-radius: var(--radius-card); padding: 18px 20px; margin: 8px 0 28px; }
.mailbox a { font-size: 20px; font-weight: 850; }
.path { font-weight: 800; color: var(--text); white-space: nowrap; }

/* small helpers (no inline styles: the CSP allows only this stylesheet) */
.inline-icon svg { display: inline; width: 20px; height: 20px; vertical-align: -4px; margin-right: 4px; }
.phone-below { margin-top: 32px; }
.privacy-intro { margin-top: 16px; }
