/* ============================================================
   MEDLEY — Design tokens
   Pulled from the iOS app:
     teal: SundrieTheme.teal  •  beige: SundrieTheme.beige
     mesh palette: AppLockView gradient + ScanView teal family
     signal palette: SignalsView (goodForYou / watchOut / processing / cost)
   ============================================================ */

:root {
  /* Brand */
  --teal: #003F3B;
  --teal-700: #0a5757;
  --teal-600: #14807a;
  --teal-500: #29a894;
  --sand: #d9b366;
  --sand-soft: #e8cc8f;
  --ag-green: #4a8826;       /* clean kelly green for accents on cream */
  --ag-green-soft: #b8d978;  /* fresh light green for use on dark teal */

  /* Surfaces */
  --beige: #F4F2EC;
  --beige-deep: #ECE7DC;
  --card: #FFFFFF;
  --card-soft: #FAF7EF;
  --line: rgba(15, 28, 26, 0.08);
  --line-strong: rgba(15, 28, 26, 0.14);

  /* Ink */
  --ink: #0E1815;
  --ink-2: #2A3835;
  --ink-3: #5C6B68;
  --ink-4: #8A9794;

  /* Signal palette (matches SignalsView.swift) */
  --sig-good: #10B783;
  --sig-watch: #F59E0A;
  --sig-processing: #EF5959;
  --sig-cost: #3B82F6;

  /* Type */
  --display: "Instrument Serif", "Cormorant Garamond", "Georgia", serif;
  --sans: "Geist", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;

  /* Radii */
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 22px;
  --r-xl: 28px;
  --r-2xl: 36px;

  /* Density */
  --section-y: 72px;
  --container-pad: 32px;
}

[data-density="compact"] { --section-y: 96px; }

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--beige);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; padding: 0; }
::selection { background: var(--teal-500); color: white; }

/* ─── Layout ─────────────────────────────────────────────── */

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 var(--container-pad);
}
.container--narrow { max-width: 980px; }

section.section { padding: var(--section-y) 0; position: relative; }
section.section--tight { padding: calc(var(--section-y) * 0.55) 0; }
section.section--snug-top { padding-top: calc(var(--section-y) * 0.5); }
section.section--snug-bottom { padding-bottom: calc(var(--section-y) * 0.5); }

/* Offset anchor targets so the fixed nav doesn't sit on top of them */
html { scroll-behavior: smooth; }
:where(#features, #signals, #how, #faq, #join, #waitlist) { scroll-margin-top: 96px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.eyebrow::before {
  content: "";
  width: 20px; height: 1px;
  background: currentColor;
  opacity: 0.5;
}
.eyebrow.on-teal { color: rgba(255,255,255,.7); }

/* ─── Typography ─────────────────────────────────────────── */

.h-display, h1, h2, h3 {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 0.98;
  text-wrap: balance;
  margin: 0;
}

.h-display em, h1 em, h2 em, h3 em {
  font-style: italic;
  font-weight: 400;
}

h1.display { font-size: clamp(56px, 8.5vw, 128px); }
h2.section { font-size: clamp(42px, 5.5vw, 84px); }
h3.feature { font-size: clamp(34px, 4vw, 58px); }
.h-card     { font-size: clamp(22px, 1.8vw, 28px); font-weight: 400; line-height: 1.1; }

.lede {
  font-size: clamp(17px, 1.35vw, 21px);
  line-height: 1.45;
  color: var(--ink-2);
  max-width: 56ch;
  text-wrap: pretty;
}
.lede.on-teal { color: rgba(255,255,255,.78); }

.small-cap {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ─── Buttons ─────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 24px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 15px;
  letter-spacing: -0.005em;
  transition: transform .25s cubic-bezier(.2,.7,.2,1), background .2s, color .2s, box-shadow .2s, border-color .2s;
  white-space: nowrap;
  border: 1px solid transparent;
}
.btn:hover { transform: translateY(-1px); }

.btn--primary  { background: var(--ink); color: var(--beige); }
.btn--primary:hover { background: #000; }

.btn--white    { background: white; color: var(--teal); }
.btn--white:hover { background: var(--beige); }

.btn--ghost    { color: white; border-color: rgba(255,255,255,.28); background: rgba(255,255,255,.04); }
.btn--ghost:hover { background: rgba(255,255,255,.12); }

.btn--ink-outline { border-color: var(--line-strong); color: var(--ink); background: transparent; }
.btn--ink-outline:hover { background: rgba(15,28,26,.05); }

.btn--lg { padding: 18px 28px; font-size: 16px; }

/* ─── Nav ────────────────────────────────────────────────── */

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 80;
  padding: 22px 0;
  transition: background .35s, backdrop-filter .35s, padding .25s, border-color .35s, color .35s;
  border-bottom: 1px solid transparent;
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

/* Default (top of page, over teal) — fully transparent */
.nav--on-teal { color: white; }
.nav--on-teal .wordmark { color: white; }
.nav--on-teal .nav__links a { color: rgba(255,255,255,.78); }
.nav--on-teal .nav__cta { background: white; color: var(--teal); }
.nav--on-teal .nav__cta:hover { background: var(--beige); }

/* Scrolled over teal — dark teal scrim so hero content can't bleed through */
.nav--on-teal.nav--scrolled {
  background: rgba(0, 50, 46, 0.62);
  backdrop-filter: saturate(160%) blur(22px);
  -webkit-backdrop-filter: saturate(160%) blur(22px);
  border-bottom-color: rgba(255,255,255,0.08);
  padding: 12px 0;
}

/* Scrolled over light surfaces — cream scrim */
.nav--scrolled:not(.nav--on-teal) {
  background: rgba(244, 242, 236, 0.82);
  backdrop-filter: saturate(160%) blur(20px);
  -webkit-backdrop-filter: saturate(160%) blur(20px);
  border-bottom-color: var(--line);
  padding: 12px 0;
  color: var(--ink);
}
.nav--scrolled:not(.nav--on-teal) .wordmark { color: var(--ink); }
.nav--scrolled:not(.nav--on-teal) .nav__links a { color: var(--ink-2); }
.nav--scrolled:not(.nav--on-teal) .nav__cta { background: var(--ink); color: var(--beige); }

.wordmark {
  font-family: "Georgia", "Times New Roman", serif;
  font-weight: 700;
  font-size: 34px;
  letter-spacing: -0.02em;
  color: var(--ink);
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
}
.wordmark::after {
  /* Echoes the iOS app icon's "m." lockup — always matches the wordmark colour. */
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: currentColor;
  align-self: flex-end;
  margin-bottom: 6px;
  flex-shrink: 0;
}

.nav__links {
  display: flex;
  gap: 36px;
  font-size: 14px;
  font-weight: 500;
}
.nav__links a { transition: opacity .15s; }
.nav__links a:hover { opacity: 0.6; }

.nav__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px 10px 20px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--beige);
  font-size: 14px;
  font-weight: 500;
  transition: background .2s, color .2s;
}

/* Hamburger toggle — shown only on small screens */
.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  padding: 10px;
  margin-right: -10px;
  background: transparent;
  border: 0;
  cursor: pointer;
  color: inherit;
}
.nav__toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform .25s ease, opacity .2s ease;
}
.nav__menu-cta { display: none; }

@media (max-width: 820px) {
  /* Hide the inline links + the bar CTA; show the hamburger instead */
  .nav__toggle { display: inline-flex; }
  .nav__cta { display: none; }

  /* The links become a dropdown panel under the bar */
  .nav__links {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 24px 18px;
    background: var(--beige);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 24px 44px rgba(15, 28, 26, 0.16);
    /* Closed: slid up + faded out, and not interactive */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-14px);
    pointer-events: none;
    transition: opacity .28s ease, transform .34s cubic-bezier(.2,.8,.2,1), visibility .28s;
  }
  .nav.is-open .nav__links {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
  }
  .nav__links a {
    color: var(--ink) !important;
    font-size: 16px;
    font-weight: 500;
    padding: 14px 4px;
    border-bottom: 1px solid var(--line);
    /* Each item cascades in when the menu opens */
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity .3s ease, transform .35s cubic-bezier(.2,.8,.2,1);
  }
  .nav.is-open .nav__links a { opacity: 1; transform: translateY(0); }
  .nav.is-open .nav__links a:nth-child(1) { transition-delay: .06s; }
  .nav.is-open .nav__links a:nth-child(2) { transition-delay: .11s; }
  .nav.is-open .nav__links a:nth-child(3) { transition-delay: .16s; }
  .nav.is-open .nav__links a:nth-child(4) { transition-delay: .21s; }
  .nav.is-open .nav__links a:nth-child(5) { transition-delay: .26s; }
  .nav__links a:hover { opacity: 1; color: var(--teal) !important; }

  /* Waitlist CTA at the bottom of the open menu.
     Selector is .nav__links a.nav__menu-cta so its colour beats the
     .nav__links a rule above (same !important, higher specificity). */
  .nav__links a.nav__menu-cta {
    display: block;
    margin-top: 14px;
    text-align: center;
    background: var(--ink);
    color: var(--beige) !important;
    border-radius: 999px;
    padding: 12px !important;
    border-bottom: 0 !important;
    font-weight: 600;
    font-size: 14px;
  }

  /* Hamburger morphs into an X when open */
  .nav.is-open .nav__toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav.is-open .nav__toggle span:nth-child(2) { opacity: 0; transform: scaleX(0); }
  .nav.is-open .nav__toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* ─── Mesh gradient surface ──────────────────────────────── */

.mesh {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: var(--teal);
  isolation: isolate;
}
.mesh__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.mesh__grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.18;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.65 0'/></filter><rect width='220' height='220' filter='url(%23n)'/></svg>");
}
.mesh__vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 100% 80% at 50% 100%, rgba(0,20,18,0.50), transparent 70%),
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(0,30,28,0.32), transparent 65%);
}

/* ─── Hero variant: cream (LIVE) ─────────────────────────── */

.hero--cream {
  background:
    radial-gradient(ellipse 60% 50% at 85% 25%, rgba(217, 179, 102, 0.42) 0%, transparent 55%),
    radial-gradient(ellipse 55% 50% at 12% 75%, rgba(217, 179, 102, 0.28) 0%, transparent 55%),
    var(--beige);
  color: var(--ink);
}
.hero--cream::after {
  content: "";
  position: absolute; inset: 0;
  opacity: 0.30;
  mix-blend-mode: multiply;
  pointer-events: none;
  z-index: 1;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.92' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.1 0 0 0 0 0.08 0 0 0 0 0.06 0 0 0 0.4 0'/></filter><rect width='220' height='220' filter='url(%23n)'/></svg>");
}
.hero--cream .eyebrow { color: var(--ink-3); }
.hero.hero--cream h1 { color: var(--teal); }
.hero.hero--cream h1 em { color: var(--sand); font-style: italic; }
.hero.hero--cream .lede { color: var(--teal); }
.hero--cream .hero__waitlist {
  background: white;
  border: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(40, 30, 20, 0.06);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.hero--cream .hero__waitlist:focus-within { border-color: var(--teal); }
.hero--cream .hero__waitlist input { color: var(--ink); }
.hero--cream .hero__waitlist input::placeholder { color: var(--ink-4); }
.hero--cream .hero__waitlist .btn--white { background: var(--ink); color: white; }
.hero--cream .hero__waitlist .btn--white:hover { background: #000; }
.hero--cream .hero__sub { color: var(--ink-3); }
.hero--cream .hero__sub .dot { background: var(--teal); }
.hero--cream .hero__chip { background: white; box-shadow: 0 20px 44px rgba(40, 30, 20, 0.16); }
.hero--cream .hero__phone-wrap::before {
  content: "";
  position: absolute;
  width: 560px; height: 560px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(217, 179, 102, 0.42) 0%, transparent 65%);
  filter: blur(20px);
  z-index: 0;
  pointer-events: none;
}
/* Stack the phone above the halo, but DON'T override the chips' position:absolute */
.hero--cream .hero__phone-wrap .phone { position: relative; z-index: 1; }

/* ─── Phone (screenshot variant) ────────────────────────── */
/* Sized for iPhone 15/16 Pro Max screenshots (1320×2868 ≈ 2.17:1).
   width 340 → inner 326 → inner height 708 → outer height 722. */
.phone--screenshot {
  width: 340px;
  height: 722px;
  border-radius: 52px;
  padding: 7px;
}
.phone--screenshot .phone__screen { border-radius: 45px; background: #003F3B; }
.phone--screenshot .phone__screen img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.phone--screenshot .phone__notch,
.phone--screenshot .phone__status,
.phone--screenshot .phone__tabbar,
.phone--screenshot .phone__body { display: none; }

/* ─── Hero ───────────────────────────────────────────────── */

.hero {
  position: relative;
  min-height: 100vh;
  color: white;
  overflow: hidden;
  padding: 160px 0 100px;
  display: flex;
  align-items: center;
}
.hero__inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 60px;
  align-items: center;
  width: 100%;
}
.hero__copy { max-width: 720px; }
.hero h1 {
  margin: 24px 0 28px;
  color: white;
}
.hero h1 em { color: var(--sand-soft); }

.hero .lede { color: rgba(255,255,255,.78); max-width: 48ch; }

.hero__waitlist {
  margin-top: 40px;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 480px;
  padding: 6px 6px 6px 22px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transition: border-color .2s, background .2s;
}
.hero__waitlist:focus-within { border-color: rgba(255,255,255,.45); background: rgba(255,255,255,.12); }
.hero__waitlist input {
  flex: 1;
  background: transparent;
  border: 0;
  outline: 0;
  font: inherit;
  color: white;
  font-size: 15px;
  padding: 14px 0;
}
.hero__waitlist input::placeholder { color: rgba(255,255,255,.5); }

/* Inline waitlist validation message — an on-brand white pill that reads on
   both the cream hero and the dark closer band. Replaces the browser's
   native validation popup (the forms use noValidate). */
.waitlist-error {
  display: flex;
  width: fit-content;
  max-width: 100%;
  margin: 14px auto 0;
  align-items: center;
  gap: 9px;
  padding: 9px 16px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid rgba(245, 158, 10, 0.40);
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.3;
  box-shadow: 0 10px 26px rgba(15, 28, 26, 0.14);
  animation: waitlistErrIn .26s cubic-bezier(.2,.8,.2,1);
}
.waitlist-error[hidden] { display: none; }
.waitlist-error::before {
  content: "!";
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--sig-watch);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}
@keyframes waitlistErrIn {
  from { opacity: 0; transform: translateY(-6px) scale(.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.hero__sub {
  margin-top: 22px;
  display: flex;
  gap: 22px;
  font-size: 12px;
  color: rgba(255,255,255,.55);
  letter-spacing: 0.02em;
}
.hero__sub span { display: inline-flex; align-items: center; gap: 7px; }
.hero__sub .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--sand); }

.hero__phone-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1600px;
}
.hero__phone-wrap .phone { transform: rotate(-3deg); }

.hero__chip {
  position: absolute;
  background: rgba(255,255,255,.96);
  color: var(--teal);
  border-radius: 18px;
  padding: 14px 18px;
  box-shadow: 0 18px 40px rgba(0, 20, 20, 0.30);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
  z-index: 3;
  letter-spacing: -0.005em;
}
.hero__chip .dot { width: 8px; height: 8px; border-radius: 50%; }
.hero__chip strong { font-weight: 600; }

.hero__chip--scan   { top: 10%; right: -24px; animation: float 6.2s ease-in-out infinite; }
.hero__chip--saved  { bottom: 16%; left: -36px; animation: float 7.5s ease-in-out infinite reverse; }
.hero__chip--signal { top: 50%; right: -56px; animation: float 8s ease-in-out infinite 0.4s; }

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50%      { transform: translateY(-12px) rotate(1deg); }
}

@media (max-width: 980px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__phone-wrap { order: 2; margin-top: 40px; }
  .hero { padding-top: 130px; min-height: auto; }
  .hero__chip--scan { right: 4px; }
  .hero__chip--saved { left: 4px; }
  .hero__chip--signal { right: -10px; }
}

/* ─── Phone mockup ──────────────────────────────────────── */

.phone {
  width: 320px;
  height: 660px;
  background: linear-gradient(180deg, #1a1a1a, #0a0a0a);
  border-radius: 48px;
  padding: 8px;
  box-shadow:
    0 50px 100px -20px rgba(0, 30, 28, 0.55),
    0 18px 36px -8px rgba(0, 30, 28, 0.30),
    inset 0 0 0 1px rgba(255,255,255,0.06),
    inset 0 1px 0 rgba(255,255,255,0.10);
  position: relative;
  flex-shrink: 0;
}
.phone__screen {
  width: 100%;
  height: 100%;
  border-radius: 40px;
  overflow: hidden;
  position: relative;
  background: var(--beige);
}
.phone__notch {
  position: absolute;
  top: 14px; left: 50%;
  transform: translateX(-50%);
  width: 100px; height: 28px;
  background: #000;
  border-radius: 14px;
  z-index: 5;
}
.phone__status {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 50px;
  padding: 17px 28px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 600;
  z-index: 4;
  color: var(--ink);
}
.phone__status.dark { color: white; }
.phone__status .icons { display: flex; gap: 4px; align-items: center; }

.phone__body {
  position: absolute;
  inset: 50px 0 14px;
  padding: 14px;
  overflow: hidden;
}

.phone__tabbar {
  position: absolute;
  bottom: 14px;
  left: 14px;
  right: 14px;
  height: 56px;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 22px;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-around;
  color: var(--ink-3);
  z-index: 3;
}
.phone__tabbar .tab { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 9px; font-weight: 600; letter-spacing: 0.02em; }
.phone__tabbar .tab svg { width: 20px; height: 20px; }
.phone__tabbar .tab.active { color: var(--teal); }

/* ─── Marquee ────────────────────────────────────────────── */

.marquee {
  background: var(--beige);
  padding: 28px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  position: relative;
  z-index: 4;
}
.marquee__track {
  display: flex;
  gap: 80px;
  white-space: nowrap;
  animation: marquee 60s linear infinite;
  font-family: var(--display);
  font-size: 26px;
  letter-spacing: -0.015em;
  color: var(--ink-2);
  font-weight: 400;
  width: max-content;
}
.marquee__track span { display: inline-flex; align-items: center; gap: 80px; }
.marquee__track span::after {
  content: "\2726"; /* ✦ four-pointed star — CSS escape is encoding-proof */
  color: var(--sand);
  opacity: 0.85;
  font-size: 18px;
}
.marquee__track em { color: var(--ink-3); font-style: italic; }
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ─── Problem section ────────────────────────────────────── */

/* Highlighted clause inside the problem lede — soft gold underline */
.problem .lede .hl {
  background-image: linear-gradient(transparent 64%, rgba(217, 179, 102, 0.42) 64%, rgba(217, 179, 102, 0.42) 94%, transparent 94%);
  background-repeat: no-repeat;
  padding: 0 2px;
  color: var(--ink);
  font-weight: 500;
}

/* Sources attribution line under the stat cards */
.problem__sources {
  margin: 28px 0 0;
  font-size: 12.5px;
  letter-spacing: 0.005em;
  color: var(--ink-4);
  line-height: 1.55;
}
.problem__sources a {
  color: var(--ink-3);
  text-decoration: underline;
  text-decoration-color: rgba(15, 28, 26, 0.20);
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
  transition: color 0.15s, text-decoration-color 0.15s;
}
.problem__sources a:hover {
  color: var(--teal);
  text-decoration-color: var(--teal);
}

.problem { background: var(--beige); }
.section-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
  margin-bottom: 64px;
}
.section-head .right { padding-top: 18px; }
@media (max-width: 920px) {
  .section-head { grid-template-columns: 1fr; gap: 28px; margin-bottom: 44px; }
  .section-head .right { padding-top: 0; }
}

/* Problem section: lede sits under the heading on the left, receipt
   takes the right column — balanced heights, vertically centered  */
.problem .section-head {
  gap: 56px;
  align-items: center;
  grid-template-columns: 1fr 1.1fr;
  margin-bottom: 56px;
}
.problem .section-head .right { padding-top: 0; }
@media (max-width: 920px) {
  .problem .section-head { gap: 36px; grid-template-columns: 1fr; }
}

/* ─── Receipt fragment (the unread receipt in your pocket) ────── */
.receipt-fragment {
  margin: 0;
  position: relative;
  width: 100%;
  max-width: 100%;
}
.receipt-fragment__paper {
  background: #FBFAF4;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 32px 38px 28px;
  box-shadow:
    0 1px 0 rgba(15,28,26,.04),
    0 24px 48px -28px rgba(15,28,26,.22),
    0 8px 20px -12px rgba(15,28,26,.10);
  transform: rotate(-1deg);
  transform-origin: 50% 100%;
  position: relative;
  /* Torn receipt: clean sawtooth bottom edge that tiles at any width */
  --th: 14px;
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  -webkit-mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - var(--th)) no-repeat,
    linear-gradient(45deg, #0000 50%, #000 50.5%) bottom / var(--th) var(--th) repeat-x,
    linear-gradient(-45deg, #0000 50%, #000 50.5%) bottom / var(--th) var(--th) repeat-x;
  mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - var(--th)) no-repeat,
    linear-gradient(45deg, #0000 50%, #000 50.5%) bottom / var(--th) var(--th) repeat-x,
    linear-gradient(-45deg, #0000 50%, #000 50.5%) bottom / var(--th) var(--th) repeat-x;
  padding-bottom: 30px;
}
.receipt-fragment__paper::before {
  /* faint paper texture / vertical thermal striations */
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(90deg, rgba(15,28,26,.018) 0 1px, transparent 1px 3px);
  border-radius: inherit;
  opacity: .8;
}
.receipt-fragment__head {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.receipt-fragment__store {
  font-family: var(--display);
  font-size: 22px;
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.receipt-fragment__meta {
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.receipt-fragment__rule {
  height: 1px;
  background: var(--line-strong);
  margin: 14px 0 12px;
}
.receipt-fragment__rule--dashed {
  background: none;
  border-top: 1px dashed var(--line-strong);
  height: 0;
  margin: 14px 0 10px;
}
.receipt-fragment__items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.receipt-fragment__items li {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 12px;
  font-size: 13.5px;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}
.receipt-fragment__items li .price {
  color: var(--ink);
  font-weight: 500;
  text-align: right;
}
.receipt-fragment__ellipsis {
  font-style: italic;
  color: var(--ink-4) !important;
  font-size: 12px !important;
  grid-template-columns: 1fr !important;
  margin-top: 2px;
}
.receipt-fragment__total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-family: var(--display);
  font-size: 22px;
  letter-spacing: -0.015em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.receipt-fragment__footer {
  margin-top: 10px;
  text-align: center;
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-4);
}

@media (max-width: 920px) {
  .receipt-fragment { margin-left: 0; max-width: 100%; }
  .receipt-fragment__paper { transform: rotate(-0.6deg); }
}

.problem__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
@media (max-width: 920px) { .problem__grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px) { .problem__grid { grid-template-columns: 1fr; } }

.problem__card {
  /* App-style teal gradient whose glow centre follows the cursor (--mx/--my set by JS) */
  background: radial-gradient(130% 130% at var(--mx, 46%) var(--my, 28%), #2ab89d 0%, #0f6f64 46%, #06413c 100%);
  border-radius: var(--r-lg);
  padding: 30px 28px;
  border: 1px solid rgba(255,255,255,.12);
  min-height: 240px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  box-shadow: 0 26px 50px -26px rgba(0,40,36,.5);
  transition: transform .25s, box-shadow .25s;
}
.problem__card:hover { transform: translateY(-3px); box-shadow: 0 30px 58px -22px rgba(0,40,36,.6); }
.problem__card .num {
  font-family: var(--display);
  font-size: 44px;
  color: #fff;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1;
}
/* Visually-heavier tokens like "3 → 1" step down so they read as the same mass */
.problem__card .num--small {
  font-size: 34px;
  letter-spacing: -0.01em;
}
.problem__card h3 {
  font-size: 24px;
  line-height: 1.1;
  margin-bottom: 8px;
  color: #fff;
}
.problem__card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255,255,255,.84);
}

/* ─── Feature rows (Lifesum style) ────────────────────────── */

.features { background: var(--beige); }
.features .container { display: flex; flex-direction: column; gap: 0; }

.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 80px;
  padding: 60px 0;
  border-top: 1px solid var(--line);
}
.feature-row:first-of-type { border-top: 0; }
.feature-row--flip .feature-row__visual { order: -1; }
.feature-row__copy { max-width: 520px; }
.feature-row__copy .eyebrow { margin-bottom: 18px; }
.feature-row__copy h3 { margin-bottom: 20px; }
.feature-row__copy p  { color: var(--ink-2); margin: 0 0 24px; font-size: 17px; }
.feature-row__bullets { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.feature-row__bullets li {
  position: relative;
  padding-left: 18px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink-2);
}
/* Keep the coloured label as one unit so it never breaks mid-word
   (e.g. "Watch-outs" splitting at the hyphen on narrow screens). */
.feature-row__bullets li strong { white-space: nowrap; }
.feature-row__bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 6px; height: 6px;
  background: var(--teal);
  border-radius: 50%;
}

.feature-row__visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  min-height: 600px;
}
.feature-row__visual .phone:not(.phone--pair) {
  transform: scale(0.92);
  position: relative;
  z-index: 1;
  /* Hover animation re-enabled — phones in the Features section respond on hover */
  transition: transform 0.6s cubic-bezier(.2, .7, .2, 1);
}
.feature-row:hover .feature-row__visual .phone:not(.phone--pair) {
  transform: scale(0.97) translateY(-10px) rotate(-2deg);
}

/* ─── Dual-phone layout (Lookup feature row) ─────────────── */
.feature-row__visual--pair { min-height: 600px; overflow: visible; }
.phone-pair {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 600px;
  perspective: 1800px;
}
.phone--pair {
  /* Override the base .phone with smaller dimensions so two fit side-by-side */
  width: 232px;
  height: 478px;
  border-radius: 38px;
  padding: 6px;
  position: absolute;
  transition: transform 0.55s cubic-bezier(.2, .7, .2, 1);
}
.phone--pair .phone__screen { border-radius: 32px; }
.phone--pair .phone__notch {
  width: 80px; height: 22px;
  top: 8px;
  border-radius: 0 0 14px 14px;
}
.phone--pair .phone__status {
  top: 14px;
  padding: 0 18px;
  font-size: 11px;
}
.phone--pair .phone__body { inset: 36px 0 10px; }
.phone--pair .mui--scan {
  padding: 28px 16px;
  border-radius: 32px;
}
.phone--pair .mui--scan .scan-title { font-size: 17px; margin-top: 12px; }
.phone--pair .mui--scan .scan-hint  { font-size: 10px; margin-top: 6px; }
.phone--pair .mui--scan .frame {
  width: 160px !important;
  height: 130px !important;
  margin-top: 30px !important;
  margin-left: auto;
  margin-right: auto;
}
.phone--pair .mui--scan .frame::before,
.phone--pair .mui--scan .frame::after,
.phone--pair .mui--scan .frame .c2,
.phone--pair .mui--scan .frame .c3 { width: 20px; height: 20px; }

/* Animated horizontal scan line over the barcode */
.phone--pair .scan-line {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 130px;
  height: 1.5px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.85), transparent);
  box-shadow: 0 0 8px rgba(255,255,255,.6);
  transform: translate(-50%, 0);
  animation: scanline 2.4s cubic-bezier(.4, 0, .6, 1) infinite;
  pointer-events: none;
}
@keyframes scanline {
  0%   { transform: translate(-50%, -55px); opacity: 0; }
  10%  { opacity: 1; }
  50%  { transform: translate(-50%, 55px);  opacity: 1; }
  60%  { opacity: 0; }
  100% { transform: translate(-50%, -55px); opacity: 0; }
}

/* Left phone — tilted slightly back, lower, behind */
.phone--pair-l {
  transform: translateX(-92px) translateY(20px) rotate(-6deg) scale(0.96);
  z-index: 1;
}
/* Right phone — tilted forward, higher, in front */
.phone--pair-r {
  transform: translateX(92px) translateY(-20px) rotate(5deg) scale(1);
  z-index: 2;
  box-shadow:
    0 30px 60px -25px rgba(0,0,0,.45),
    0 12px 24px -12px rgba(0,0,0,.30);
}

/* Hover — fan-outward pair pushes noticeably further apart and lifts */
.feature-row:hover .phone-pair:not(.phone-pair--lookup) .phone--pair-l {
  transform: translateX(-128px) translateY(8px) rotate(-12deg) scale(0.96);
}
.feature-row:hover .phone-pair:not(.phone-pair--lookup) .phone--pair-r {
  transform: translateX(128px) translateY(-36px) rotate(10deg) scale(1.04);
}

/* ─── 02 Lookup variant ──────────────────────────────────── */
/* Diagonal cascade — both phones lean the SAME way at a gentle angle,
   with a vertical stagger so they read as one flowing composition
   rather than two phones facing each other. Open and dynamic, not closed. */
.phone-pair--lookup .phone--pair-l {
  /* Scanner behind: pushed up and to the left, smaller, parallel tilt */
  transform: translateX(-110px) translateY(-44px) rotate(-4deg) scale(0.90);
  z-index: 1;
  box-shadow:
    0 22px 44px -22px rgba(0,0,0,.34),
    0 10px 20px -12px rgba(0,0,0,.22);
}
.phone-pair--lookup .phone--pair-r {
  /* Result in front: pushed down and to the right, larger, same direction tilt */
  transform: translateX(74px) translateY(36px) rotate(-4deg) scale(1.02);
  z-index: 2;
  box-shadow:
    0 36px 72px -28px rgba(0,0,0,.50),
    0 14px 28px -14px rgba(0,0,0,.32);
}

/* Hover — diagonal cascade extends further with more pronounced separation */
.feature-row:hover .phone-pair--lookup .phone--pair-l {
  transform: translateX(-140px) translateY(-72px) rotate(-8deg) scale(0.88);
}
.feature-row:hover .phone-pair--lookup .phone--pair-r {
  transform: translateX(102px) translateY(60px) rotate(0deg) scale(1.06);
}

/* Hover tilt removed — phones stay still */

/* Float card positions for the dual-phone arrangement */
.float-card--pair-left {
  position: absolute;
  top: 12%;
  left: -3%;
  z-index: 3;
}
.float-card--pair-right {
  position: absolute;
  bottom: 8%;
  right: -3%;
  z-index: 3;
}

/* ─── Product detail mini screen ─────────────────────────── */
.mui--detail {
  background: #FBFAF4;
  height: 100%;
  width: 100%;
  padding: 12px 12px 10px;
  border-radius: 32px;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: hidden;
}
.detail__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ink-3);
  font-size: 10px;
  letter-spacing: 0.04em;
}
.detail__back, .detail__heart {
  display: grid; place-items: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(15,28,26,.05);
  color: var(--ink);
}
.detail__crumb {
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-4);
}
.detail__hero {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 6px 4px 0;
}
.detail__jar {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: linear-gradient(160deg, #f3efe2 0%, #e8e0c8 100%);
  border: 1px solid rgba(15,28,26,.06);
  display: grid;
  place-items: center;
  font-size: 26px;
  margin-bottom: 6px;
  box-shadow: 0 8px 16px -10px rgba(15,28,26,.18);
}
.detail__name {
  font-family: var(--display);
  font-size: 16px;
  letter-spacing: -0.01em;
  line-height: 1.05;
  color: var(--ink);
  white-space: nowrap;
}
.detail__sub {
  font-size: 9.5px;
  color: var(--ink-3);
  letter-spacing: 0.01em;
}
.detail__score {
  position: relative;
  margin: 2px auto 0;
  width: 130px;
  text-align: center;
}
.detail__arc {
  width: 130px;
  height: 76px;
  display: block;
}
.detail__num {
  position: absolute;
  inset: 14px 0 auto 0;
  font-family: var(--display);
  font-size: 36px;
  letter-spacing: -0.02em;
  color: var(--sig-good);
  line-height: 1;
}
.detail__label {
  font-size: 8.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-top: 4px;
}
.detail__nutri {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  margin-top: 4px;
}
.detail__nutri > div {
  background: white;
  border: 1px solid rgba(15,28,26,.06);
  border-radius: 9px;
  padding: 7px 4px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.detail__nutri .n-val {
  font-family: var(--display);
  font-size: 15px;
  color: var(--ink);
  line-height: 1;
  letter-spacing: -0.01em;
}
.detail__nutri .n-val small {
  font-size: 9px;
  color: var(--ink-3);
  margin-left: 1px;
}
.detail__nutri .n-key {
  font-size: 8px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.detail__pills {
  display: flex;
  flex-wrap: nowrap;
  gap: 4px;
  justify-content: center;
  margin-top: auto;
  padding-top: 6px;
  padding-bottom: 4px;
}
.detail__pills .mui__pill {
  font-size: 8.5px;
  padding: 3px 7px;
  white-space: nowrap;
}

/* ─── Scan-receipt peek (the wisp of receipt inside the scan frame) ─── */
.scan-receipt-peek {
  position: absolute;
  inset: 14px 14px 14px 14px;
  background: #FBFAF4;
  border-radius: 4px;
  padding: 10px 12px 8px;
  font-family: var(--display);
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 4px;
  box-shadow:
    0 0 0 1px rgba(255,255,255,.10),
    0 12px 24px rgba(0,0,0,.45);
  opacity: 0.92;
}
.scan-receipt-peek .srp__head {
  text-align: center;
  font-size: 10px;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--line-strong);
}
.scan-receipt-peek .srp__line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-family: var(--sans);
  font-size: 8.5px;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.005em;
  line-height: 1.25;
}
.scan-receipt-peek .srp__line--muted {
  color: var(--ink-4);
  font-style: italic;
  margin-top: 2px;
  padding-top: 4px;
  border-top: 1px dashed var(--line-strong);
}

/* ─── Sorted result screen (right phone in 01 Scan) ──────── */
.mui--sorted {
  background: #FBFAF4;
  height: 100%;
  width: 100%;
  padding: 12px 12px 10px;
  border-radius: 32px;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: hidden;
}
.sorted__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ink-3);
}
.sorted__back, .sorted__heart {
  display: grid; place-items: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(15,28,26,.05);
  color: var(--ink);
}
.sorted__heart { background: rgba(16,183,131,.12); color: var(--sig-good); }
.sorted__crumb {
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-4);
}
.sorted__head {
  text-align: center;
  padding: 2px 0 6px;
  border-bottom: 1px solid var(--line);
}
.sorted__title {
  font-family: var(--display);
  font-size: 16px;
  letter-spacing: -0.01em;
  color: var(--ink);
  line-height: 1.05;
}
.sorted__meta {
  font-size: 10px;
  color: var(--ink-3);
  letter-spacing: 0.02em;
  margin-top: 3px;
  font-variant-numeric: tabular-nums;
}
.sorted__meta strong { color: var(--ink); font-weight: 600; }

.sorted__sig {
  display: flex;
  gap: 6px;
}
.sorted__sig-item {
  flex: 1;
  background: white;
  border: 1px solid rgba(15,28,26,.06);
  border-radius: 9px;
  padding: 6px 7px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 9px;
  letter-spacing: 0.005em;
  color: var(--ink-2);
}
.sorted__sig-item strong {
  font-size: 12px;
  color: var(--ink);
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: -0.01em;
  margin-right: 2px;
}
.sorted__sig-item .dot { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }

.sorted__cats {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 2px;
  overflow: hidden;
}
.sorted__cat-head {
  font-family: var(--display);
  font-style: italic;
  font-size: 11px;
  color: var(--teal);
  letter-spacing: 0.005em;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 3px;
}
.sorted__cat-head::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, var(--line-strong), transparent);
}
.sorted__cat-head span {
  font-family: var(--sans);
  font-style: normal;
  font-size: 8.5px;
  color: var(--ink-4);
  font-weight: 500;
  background: rgba(15,28,26,.04);
  padding: 1px 6px;
  border-radius: 999px;
  letter-spacing: 0.02em;
}
.sorted__item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 10.5px;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.005em;
  padding: 2px 0;
}
.sorted__item .p { color: var(--ink); font-weight: 500; }

@media (max-width: 920px) {
  .feature-row__visual--pair { min-height: 520px; }
  .phone-pair { min-height: 520px; }
  .phone--pair-l { transform: translateX(-72px) translateY(16px) rotate(-5deg) scale(0.82); }
  .phone--pair-r { transform: translateX(72px) translateY(-16px) rotate(4deg) scale(0.86); }

  /* 02 Lookup diagonal cascade on tablet */
  .phone-pair--lookup .phone--pair-l { transform: translateX(-90px) translateY(-38px) rotate(-4deg) scale(0.76); }
  .phone-pair--lookup .phone--pair-r { transform: translateX(60px) translateY(28px) rotate(-4deg) scale(0.88); }
}
@media (max-width: 560px) {
  .phone--pair-l { transform: translateX(-58px) translateY(14px) rotate(-5deg) scale(0.66); }
  .phone--pair-r { transform: translateX(58px) translateY(-14px) rotate(4deg) scale(0.70); }
  .float-card--pair-left  { top: 18%; left: -8%; }
  .float-card--pair-right { bottom: 18%; right: -8%; }

  /* 02 Lookup diagonal cascade on phone */
  .phone-pair--lookup .phone--pair-l { transform: translateX(-72px) translateY(-30px) rotate(-4deg) scale(0.62); }
  .phone-pair--lookup .phone--pair-r { transform: translateX(46px) translateY(22px) rotate(-4deg) scale(0.72); }
}
.feature-row__visual .float-card {
  position: absolute;
  z-index: 3;
  white-space: nowrap;
  background: var(--card);
  border-radius: var(--r-md);
  padding: 14px 16px;
  box-shadow: 0 16px 36px -10px rgba(0,30,28,.18);
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
}

@media (max-width: 920px) {
  .feature-row { grid-template-columns: 1fr; gap: 36px; padding: 50px 0; }
  .feature-row--flip .feature-row__visual { order: 0; }
  .feature-row__visual { min-height: 540px; }
}

/* ─── Signals deep-dive (dark band) ──────────────────────── */

.signals-dive {
  background: var(--teal);
  color: white;
  position: relative;
  overflow: hidden;
}
.signals-dive::before {
  content: "";
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(circle at 20% 30%, var(--teal-600) 0%, transparent 45%),
    radial-gradient(circle at 80% 70%, var(--teal-500) 0%, transparent 45%),
    radial-gradient(circle at 60% 20%, var(--sand) 0%, transparent 30%);
  filter: blur(60px);
  opacity: 0.55;
  z-index: 0;
}
.signals-dive .container { position: relative; z-index: 1; }
.signals-dive h2 { color: white; }
.signals-dive .lede { color: rgba(255,255,255,.78); }
.signals-dive .signal-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin-top: 64px;
}
@media (max-width: 720px) { .signals-dive .signal-grid { grid-template-columns: 1fr; } }

.signal-card {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: var(--r-lg);
  padding: 32px 30px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: background .25s, border-color .25s;
}
.signal-card:hover { background: rgba(255,255,255,.10); border-color: rgba(255,255,255,.18); }
.signal-card__icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 20px;
}
.signal-card h4 {
  font-family: var(--display);
  font-size: 28px;
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin: 0;
  color: white;
}
.signal-card p {
  font-size: 14px;
  line-height: 1.5;
  margin: 0;
  color: rgba(255,255,255,.7);
}

/* ─── "Part" intro band (between Problem and Features) ────── */
.part-intro {
  background: var(--beige);
  padding: 0 0 calc(var(--section-y) * 0.4);
}
.part-intro__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: end;
  padding-top: calc(var(--section-y) * 0.65);
  border-top: 1px solid var(--line);
}
@media (max-width: 920px) {
  .part-intro__inner { grid-template-columns: 1fr; gap: 28px; }
}

.part-marker {
  display: inline-flex;
  align-items: baseline;
  gap: 14px;
  font-family: var(--display);
  font-size: clamp(28px, 2.6vw, 38px);
  letter-spacing: -0.015em;
  line-height: 1;
  color: var(--ink);
  margin-bottom: 20px;
}
.part-marker .num {
  font-size: clamp(64px, 7vw, 96px);
  color: var(--teal);
  letter-spacing: -0.03em;
}
.part-marker em {
  font-style: italic;
  color: var(--ink-3);
  font-size: clamp(20px, 1.6vw, 24px);
  margin-left: auto;
}

/* Aisle (teal band) part intro variant — solid teal so it flows seamlessly
   into the features--dark block right below it (no double-mesh seam). */
.part-intro--dark {
  background: var(--teal);
  color: white;
  position: relative;
  overflow: hidden;
}
.part-intro--dark .container { position: relative; z-index: 1; }
.part-intro--dark .part-intro__inner { border-top-color: rgba(255,255,255,0.10); }
.part-intro--dark .part-marker { color: white; }
.part-intro--dark .part-marker em { color: rgba(255,255,255,.65); }
.part-intro--dark .part-marker .num { color: white; }
.part-intro--dark h2 { color: white; }
.part-intro--dark h2 em { color: var(--sand-soft); }
.part-intro--dark .lede { color: rgba(255,255,255,.78); }

/* Features wrapper variants — keeps the same solid teal so adjacent dark
   sections butt up cleanly. The subtle radial "mesh" lives lower in the
   features band (offset toward the bottom-right) so the join with the
   intro above stays invisible. */
.features--dark {
  background: var(--teal);
  color: white;
  position: relative;
  overflow: hidden;
}
.features--dark::before {
  content: "";
  position: absolute;
  left: -15%; right: -15%;
  top: 25%;
  bottom: -10%;
  background:
    radial-gradient(circle at 80% 70%, #0a5751 0%, transparent 50%),
    radial-gradient(circle at 25% 40%, #0a4f48 0%, transparent 50%);
  filter: blur(80px);
  opacity: 0.55;
  z-index: 0;
  pointer-events: none;
}
.features--dark .container { position: relative; z-index: 1; }
.features--dark .feature-row { border-top-color: rgba(255,255,255,0.10); }
.features--dark .eyebrow { color: rgba(255,255,255,.55); }
.features--dark .feature-row__copy h3 { color: white; }
.features--dark .feature-row__copy h3 em { color: var(--sand-soft); }
.features--dark .feature-row__copy p { color: rgba(255,255,255,.78); }
.features--dark .feature-row__bullets li { color: rgba(255,255,255,.82); }
.features--dark .feature-row__bullets li::before { background: var(--sand); }

/* ─── How it works (tightened) ───────────────────────────── */

.how {
  background: var(--beige);
  padding: calc(var(--section-y) * 0.7) 0;
}
.how--dark {
  background: var(--teal);
  color: white;
  position: relative;
  overflow: hidden;
}
.how--dark::before {
  content: "";
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(circle at 30% 30%, #0d5a51 0%, transparent 45%),
    radial-gradient(circle at 70% 70%, #0a4f48 0%, transparent 45%);
  filter: blur(60px);
  opacity: 0.55;
  z-index: 0;
}
.how--dark .container { position: relative; z-index: 1; }
.how--dark h2 { color: white; }
.how--dark h2 em { color: var(--sand-soft); }
.how--dark .eyebrow { color: rgba(255,255,255,.55); }
.how--dark .step__num { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.15); color: var(--sand-soft); }
.how--dark .step h4 { color: white; }
.how--dark .step p { color: rgba(255,255,255,.7); }
.how--dark .how__steps::before { opacity: 0.35; background: repeating-linear-gradient(to right, rgba(255,255,255,0.5) 0 5px, transparent 5px 10px); }
.how__head { max-width: 640px; margin: 0 auto; text-align: center; }
.how__steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin: 40px auto 0;
  max-width: 980px;
  position: relative;
}
.how__steps::before {
  content: "";
  position: absolute;
  top: 30px;
  left: 14%;
  right: 14%;
  height: 1px;
  background: repeating-linear-gradient(to right, var(--ink-4) 0 5px, transparent 5px 10px);
  opacity: 0.5;
  z-index: 0;
}
@media (max-width: 820px) {
  .how__steps {
    grid-template-columns: 1fr;
    gap: 18px;
    margin-top: 32px;
    max-width: 520px;
  }
  .how__steps::before { display: none; }
  /* Compact step: number circle + title share one line, copy indented
     beneath — instead of a tall stack with the circle floating alone.
     Scoped under .how__steps so it outranks the base .step rule that
     appears later in the file. */
  .how__steps .step {
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 14px;
    row-gap: 6px;
    align-items: center;
  }
  .how__steps .step__num {
    grid-column: 1; grid-row: 1;
    width: 44px; height: 44px;
    font-size: 21px;
  }
  .how__steps .step h4 { grid-column: 2; grid-row: 1; }
  .how__steps .step p  { grid-column: 2; grid-row: 2; max-width: none; }
}

.step {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  z-index: 1;
}
.step__num {
  width: 60px; height: 60px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-size: 28px;
  color: var(--teal);
}
.step h4 {
  font-family: var(--display);
  font-size: clamp(22px, 1.9vw, 26px);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin: 0;
  color: var(--ink);
}
.step p { margin: 0; font-size: 14px; color: var(--ink-3); line-height: 1.55; max-width: 32ch; }

/* ─── Monthly report teaser ──────────────────────────────── */

.report {
  background: var(--beige-deep);
  position: relative;
  overflow: hidden;
}
.report .container { display: grid; grid-template-columns: 1fr 1.1fr; gap: 80px; align-items: center; }
@media (max-width: 920px) { .report .container { grid-template-columns: 1fr; } }

.report__card {
  background: linear-gradient(160deg, #0a3a36 0%, var(--teal) 50%, #00342f 100%);
  border-radius: var(--r-2xl);
  padding: 48px 44px;
  color: white;
  position: relative;
  overflow: hidden;
  min-height: 520px;
  box-shadow: 0 40px 80px -20px rgba(0, 40, 36, 0.35);
}
.report__card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 80% 10%, var(--sand) 0%, transparent 30%),
    radial-gradient(circle at 20% 90%, var(--teal-500) 0%, transparent 40%);
  filter: blur(40px);
  opacity: 0.55;
}
.report__card > * { position: relative; z-index: 1; }
.report__card .small-cap { color: rgba(255,255,255,.55); }
.report__card h4 {
  font-family: var(--display);
  font-size: clamp(36px, 4vw, 52px);
  font-weight: 400;
  margin: 16px 0 28px;
  letter-spacing: -0.02em;
  line-height: 1;
}
.report__card h4 em { color: var(--sand-soft); }
.report__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px 24px;
  margin-top: 36px;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,.16);
}
.report__stat .num {
  font-family: var(--display);
  font-size: 42px;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1;
  color: white;
}
.report__stat .num em { color: var(--sand-soft); font-style: normal; font-size: 22px; opacity: .8; }
.report__stat .label {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 8px;
  display: block;
}
.report__caption {
  margin-top: 36px;
  font-size: 14px;
  color: rgba(255,255,255,.7);
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ─── Privacy band ───────────────────────────────────────── */

.privacy-band {
  background: var(--beige);
  text-align: center;
}
.privacy-band .container { max-width: 880px; }
.privacy-band .privacy__icon {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  margin: 0 auto 36px;
  color: var(--teal);
}
.privacy-band h2 { margin-bottom: 24px; }
.privacy-band .lede { margin: 0 auto; }
.privacy-band__list {
  display: flex;
  justify-content: center;
  gap: 56px;
  margin-top: 56px;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
}
.privacy-band__list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
}
.privacy-band__list li svg { color: var(--teal); width: 18px; height: 18px; }

/* ─── FAQ ─────────────────────────────────────────────────── */

.faq { background: var(--beige); }
.faq .container { display: grid; grid-template-columns: 0.7fr 1fr; gap: 80px; align-items: start; }
@media (max-width: 920px) { .faq .container { grid-template-columns: 1fr; gap: 40px; } }
.faq__list { display: flex; flex-direction: column; }
.faq__item {
  border-top: 1px solid var(--line);
  padding: 28px 0;
}
.faq__item:last-of-type { border-bottom: 1px solid var(--line); }
.faq__q {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  text-align: left;
  font-family: var(--display);
  font-size: clamp(22px, 2vw, 28px);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.faq__q .plus {
  width: 32px; height: 32px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  flex-shrink: 0;
  position: relative;
  transition: transform .3s, background .2s;
}
.faq__q .plus::before, .faq__q .plus::after {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  background: var(--ink);
  border-radius: 2px;
  transform: translate(-50%, -50%);
}
.faq__q .plus::before { width: 12px; height: 1.5px; }
.faq__q .plus::after  { width: 1.5px; height: 12px; transition: transform .3s; }
.faq__item.open .faq__q .plus { background: var(--ink); }
.faq__item.open .faq__q .plus::before { background: white; }
.faq__item.open .faq__q .plus::after  { background: white; transform: translate(-50%, -50%) rotate(90deg); }
.faq__a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .35s cubic-bezier(.2,.7,.2,1);
}
.faq__item.open .faq__a { max-height: 400px; }
.faq__a-inner {
  padding-top: 18px;
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 64ch;
}

/* ─── Footer / final CTA ─────────────────────────────────── */

.cta-final {
  background: var(--teal);
  color: white;
  position: relative;
  overflow: hidden;
  text-align: center;
}
.cta-final .mesh { z-index: 0; }
.cta-final .container { position: relative; z-index: 2; }
.cta-final h2 {
  color: white;
  font-size: clamp(56px, 8vw, 120px);
  line-height: 0.96;
  letter-spacing: -0.025em;
}
.cta-final h2 em { color: var(--sand-soft); }
.cta-final .lede { color: rgba(255,255,255,.78); margin: 28px auto 40px; }
.cta-final .hero__waitlist { margin: 0 auto; }
.cta-final .hero__sub { justify-content: center; }

.footer {
  background: var(--ink);
  color: rgba(255,255,255,.7);
  padding: 100px 0 50px;
  font-size: 14px;
}
.footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 50px;
  padding-bottom: 64px;
  border-bottom: 1px solid rgba(255,255,255,.10);
}
@media (max-width: 820px) { .footer__top { grid-template-columns: 1fr 1fr; gap: 36px; } }
@media (max-width: 540px) { .footer__top { grid-template-columns: 1fr; } }
.footer__brand .wordmark { color: white; font-size: 32px; }
.footer__brand p { margin: 18px 0 0; color: rgba(255,255,255,.55); max-width: 36ch; line-height: 1.5; }
.footer__col h5 {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,.45);
  margin: 6px 0 22px;
}
.footer__col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.footer__col a { color: rgba(255,255,255,.78); transition: color .15s; }
.footer__col a:hover { color: white; }
.footer__bottom {
  padding-top: 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 13px;
  color: rgba(255,255,255,.45);
}
.footer__bottom .wordmark--small {
  font-family: var(--display);
  font-size: 14px;
  color: rgba(255,255,255,.45);
}

/* ─── Phone screen content (mock UI) ─────────────────────── */

.mui {
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ink);
  height: 100%;
  display: flex;
  flex-direction: column;
}
.mui__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  padding: 0 2px;
}
.mui__greeting { font-family: var(--display); font-size: 22px; line-height: 1.05; color: var(--ink); letter-spacing: -0.015em; }
.mui__greeting em { color: var(--teal); }
.mui__avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--teal); display: grid; place-items: center; color: white; font-weight: 600; font-size: 12px; }

.mui__card {
  background: var(--card);
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 1px 2px rgba(15,28,26,.04), 0 6px 18px rgba(15,28,26,.05);
}
.mui__card + .mui__card { margin-top: 12px; }

.mui__row { display: flex; align-items: center; gap: 10px; }
.mui__row + .mui__row { margin-top: 12px; padding-top: 12px; border-top: 1px solid rgba(15,28,26,.06); }

.mui__pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.mui__pill .dot { width: 6px; height: 6px; border-radius: 50%; }

/* Budget circle */
.mui__budget {
  display: flex;
  align-items: center;
  gap: 16px;
}
.mui__budget-ring {
  width: 88px; height: 88px;
  border-radius: 50%;
  background: conic-gradient(var(--teal) 0% 62%, rgba(15,28,26,.08) 62% 100%);
  display: grid;
  place-items: center;
  position: relative;
}
.mui__budget-ring::before {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  background: white;
}
.mui__budget-ring-text {
  position: relative;
  text-align: center;
  font-family: var(--display);
  line-height: 1;
}
.mui__budget-ring-text .big { font-size: 18px; color: var(--ink); }
.mui__budget-ring-text .small { font-size: 9px; color: var(--ink-3); margin-top: 2px; display: block; font-family: var(--sans); letter-spacing: 0.04em; text-transform: uppercase; font-weight: 500; }

.mui__budget-info { flex: 1; }
.mui__budget-info .label { font-size: 10px; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 500; }
.mui__budget-info .spend { font-family: var(--display); font-size: 26px; color: var(--ink); line-height: 1.05; margin-top: 4px; }
.mui__budget-info .bar { height: 4px; background: rgba(15,28,26,.08); border-radius: 2px; margin-top: 12px; overflow: hidden; }
.mui__budget-info .bar > span { display: block; height: 100%; background: var(--teal); border-radius: 2px; width: 62%; }

/* Receipt item rows */
.mui__receipt {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.mui__receipt-icon {
  width: 32px; height: 32px;
  border-radius: 10px;
  background: rgba(0, 63, 59, 0.08);
  color: var(--teal);
  display: grid;
  place-items: center;
}
.mui__receipt-text { flex: 1; }
.mui__receipt-text .t { font-size: 12px; font-weight: 600; color: var(--ink); }
.mui__receipt-text .s { font-size: 10px; color: var(--ink-3); margin-top: 2px; }
.mui__receipt .amt { font-family: var(--display); font-size: 18px; color: var(--ink); }

/* Signal preview */
.mui__signal {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
}
.mui__signal-ic {
  width: 28px; height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.mui__signal-text { flex: 1; }
.mui__signal-text .t { font-size: 12px; font-weight: 600; color: var(--ink); }
.mui__signal-text .s { font-size: 10px; color: var(--ink-3); margin-top: 2px; }

/* Scan screen */
.mui--scan {
  background: linear-gradient(180deg, #0a5757 0%, #14807a 50%, #29a894 100%);
  color: white;
  height: 100%;
  margin: -14px;
  padding: 60px 20px 100px;
  position: relative;
  overflow: hidden;
}
.mui--scan::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 20%, rgba(217,179,102,.4) 0%, transparent 40%),
    radial-gradient(circle at 70% 80%, rgba(41,168,148,.6) 0%, transparent 40%);
  filter: blur(40px);
}
.mui--scan > * { position: relative; }
.mui--scan .frame {
  width: 220px;
  height: 280px;
  margin: 30px auto;
  position: relative;
  border-radius: 18px;
}
.mui--scan .frame::before,
.mui--scan .frame::after {
  content: "";
  position: absolute;
  width: 28px; height: 28px;
  border: 2px solid white;
}
.mui--scan .frame::before { top: 0; left: 0; border-right: 0; border-bottom: 0; border-top-left-radius: 8px; }
.mui--scan .frame::after  { bottom: 0; right: 0; border-left: 0; border-top: 0; border-bottom-right-radius: 8px; }
.mui--scan .frame .c2, .mui--scan .frame .c3 {
  position: absolute;
  width: 28px; height: 28px;
  border: 2px solid white;
}
.mui--scan .frame .c2 { top: 0; right: 0; border-left: 0; border-bottom: 0; border-top-right-radius: 8px; }
.mui--scan .frame .c3 { bottom: 0; left: 0; border-right: 0; border-top: 0; border-bottom-left-radius: 8px; }
.mui--scan .scan-title { font-family: var(--display); font-size: 24px; text-align: center; letter-spacing: -0.015em; }
.mui--scan .scan-hint { text-align: center; margin-top: 10px; font-size: 12px; color: rgba(255,255,255,.7); }
.mui--scan .scan-shutter {
  width: 64px; height: 64px;
  border-radius: 50%;
  border: 3px solid white;
  background: rgba(255,255,255,.15);
  margin: 30px auto 0;
  position: relative;
}
.mui--scan .scan-shutter::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: white;
}

/* Supplies grid */
.mui__supplies {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.mui__supply {
  background: var(--card);
  border-radius: 14px;
  padding: 12px 12px 14px;
  box-shadow: 0 1px 2px rgba(15,28,26,.04), 0 4px 12px rgba(15,28,26,.04);
}
.mui__supply .emoji { font-size: 26px; line-height: 1; margin-bottom: 6px; }
.mui__supply .name { font-size: 11px; font-weight: 600; color: var(--ink); }
.mui__supply .qty { font-size: 10px; color: var(--ink-3); margin-top: 2px; }
.mui__supply.low { background: rgba(245, 158, 10, 0.12); }
.mui__supply.low .name { color: #8a5a00; }

/* ─── Tweaks panel placeholder (mounted by tweaks-panel.jsx) ── */
#tweaks-root { position: fixed; bottom: 24px; right: 24px; z-index: 100; }

/* ─── Utility ────────────────────────────────────────────── */

.fade-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1);
}
.fade-up.in { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .fade-up { transition: none; opacity: 1; transform: none; }
  .marquee__track, .hero__chip { animation: none !important; }
  html.js-reveal .feature-row__visual { opacity: 1 !important; transform: none !important; }
}

/* Scroll-reveal for the phone visuals (mobile & tablet): they slide up and
   fade in as they enter the viewport. JS adds .js-reveal (so a no-JS browser
   shows them normally) and .in-view per element. Only opacity + translateY
   are animated — the phone sizes are untouched, so they stay in-bounds. */
@media (max-width: 900px) {
  html.js-reveal .feature-row__visual {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity .6s ease, transform .75s cubic-bezier(.2,.7,.2,1);
    will-change: opacity, transform;
  }
  html.js-reveal .feature-row__visual.in-view {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   MOBILE FIXES — narrow phones (≤ 600px)
   Targets specific overflow + ergonomics issues on real devices.
   ============================================================ */

/* Safety net: never let anything cause horizontal scroll on mobile */
@media (max-width: 600px) {
  html, body { overflow-x: hidden; }
}

/* Nav — clear the iPhone dynamic-island / notch safe area */
@media (max-width: 600px) {
  .nav { padding-top: env(safe-area-inset-top, 0px); }
  .nav__inner { padding-top: 14px; padding-bottom: 14px; } /* keep the container's horizontal gutter */
  .wordmark { font-size: 26px; }
  .nav__cta {
    padding: 9px 14px;
    font-size: 13px;
    gap: 6px;
  }
}

/* Hero waitlist — stack vertically + full-width on phones */
@media (max-width: 600px) {
  .hero__waitlist {
    max-width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 14px;
    border-radius: 22px;
  }
  .hero__waitlist input {
    width: 100%;
    padding: 12px 8px;
    text-align: center;
  }
  .hero__waitlist .btn,
  .hero__waitlist .btn--white {
    width: 100%;
    justify-content: center;
    text-align: center;
    padding: 14px 20px;
    border-radius: 14px;
  }
  .hero__sub { justify-content: center; flex-wrap: wrap; gap: 14px; }
}

/* Cream-hero halo — scale to viewport, never overflow */
@media (max-width: 600px) {
  .hero--cream .hero__phone-wrap::before {
    width: 88vw;
    height: 88vw;
    max-width: 360px;
    max-height: 360px;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
  }
}

/* Hero floating chips — hidden on mobile so they never cover the phone
   screenshot (e.g. the app name). They still float beside the phone on
   desktop, where there's room. */
@media (max-width: 600px) {
  .hero__chip { display: none !important; }
}

/* ─── Phones on mobile — keep every composition, scale to fit ──────
   Earlier this hid the second phone of each pair and blew the single
   phones up to ~85% of the screen. The dual-phone compositions are
   part of the design, so instead we keep BOTH phones and scale each
   arrangement down to a phone-width column. Sizes use viewport-relative
   caps (vw + max) so they shrink smoothly on smaller devices. */
@media (max-width: 600px) {
  .feature-row__visual,
  .feature-row__visual--pair {
    overflow: visible;
    min-height: 0;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 12px;
  }

  /* Single-phone rows: constrain the visual to ~phone width so the
     floating chips hug the phone instead of sitting in the wide margin. */
  .feature-row__visual:not(.feature-row__visual--pair) {
    width: 240px !important;
    max-width: 240px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    position: relative;
  }

  /* Hero screenshot phone — was filling ~85% of the screen width */
  .hero__phone-wrap .phone--screenshot {
    width: min(62vw, 246px);
    height: auto;
    aspect-ratio: 340 / 722;
    padding: 6px;
  }

  /* Single feature phones (points 3–5) — scale down and reclaim the
     empty space the transform leaves so sections stay tight. */
  .feature-row__visual .phone:not(.phone--pair) {
    transform: scale(0.74);
    transform-origin: center;
    margin: -84px 0;
  }
  .feature-row:hover .feature-row__visual .phone:not(.phone--pair) {
    transform: scale(0.74);   /* no grow-on-hover on touch screens */
  }

  /* Dual-phone pairs (points 1–2) — show BOTH, scaled to fit ~340px. */
  .phone-pair {
    position: relative;
    width: 100% !important;
    max-width: 100% !important;
    height: 320px;
    min-height: 0;
    margin: 0 auto !important;
  }
  .phone-pair .phone--pair-l,
  .phone-pair .phone--pair-r { display: block !important; }

  .phone-pair .phone--pair-l {
    transform: translateX(-54px) translateY(12px) rotate(-5deg) scale(0.58);
  }
  .phone-pair .phone--pair-r {
    transform: translateX(54px) translateY(-12px) rotate(4deg) scale(0.62);
  }
  .phone-pair--lookup .phone--pair-l {
    transform: translateX(-60px) translateY(-22px) rotate(-4deg) scale(0.54);
  }
  .phone-pair--lookup .phone--pair-r {
    transform: translateX(40px) translateY(18px) rotate(-4deg) scale(0.60);
  }

  /* Freeze the fan-out hover animation on small screens — on desktop the
     pair spreads apart on hover, which overflowed both edges on mobile.
     Re-state the hover transforms to equal the resting state (these match
     the desktop hover selectors' specificity but win by source order). */
  .feature-row:hover .phone-pair:not(.phone-pair--lookup) .phone--pair-l {
    transform: translateX(-54px) translateY(12px) rotate(-5deg) scale(0.58);
  }
  .feature-row:hover .phone-pair:not(.phone-pair--lookup) .phone--pair-r {
    transform: translateX(54px) translateY(-12px) rotate(4deg) scale(0.62);
  }
  .feature-row:hover .phone-pair--lookup .phone--pair-l {
    transform: translateX(-60px) translateY(-22px) rotate(-4deg) scale(0.54);
  }
  .feature-row:hover .phone-pair--lookup .phone--pair-r {
    transform: translateX(40px) translateY(18px) rotate(-4deg) scale(0.60);
  }

  /* Decorative float-chips clutter the compact pair composition — hide
     them on the smallest screens; keep single-phone float cards inline. */
  .float-card--pair-left,
  .float-card--pair-right { display: none !important; }
  .feature-row__visual .float-card:not(.float-card--pair-left):not(.float-card--pair-right) {
    position: absolute !important;
    z-index: 6;
    display: inline-flex;
    margin: 0 !important;
    font-size: 12px;
    white-space: nowrap;
  }
}

/* Mobile Preview frame — simulates the iPhone dynamic-island safe area.
   Toggled by a class on <html> (the preview frame adds it) because the
   sandbox CSP blocks inline <style> injection into the iframe. */
html.preview-safe-area .nav { padding-top: 44px !important; }

/* ─── Problem cards — compact on mobile ─── */
@media (max-width: 600px) {
  .problem__card {
    padding: 24px 22px;
    min-height: 0;
  }
  .problem__card .num { font-size: 38px; margin-bottom: 18px; }
  .problem__card .num--small { font-size: 30px; }
  .problem__card h3 { font-size: 20px; margin-bottom: 6px; }
  .problem__card p  { font-size: 13.5px; line-height: 1.5; }
  .problem__grid { gap: 12px; }
}

/* ─── Tighten section vertical rhythm on mobile ─── */
@media (max-width: 600px) {
  :root { --section-y: 56px; }
  h2.section { font-size: clamp(34px, 9vw, 48px); line-height: 1.02; }
  .section-head { margin-bottom: 28px !important; }
}

/* ─── Final CTA (dark green) — compact and centered ─── */
@media (max-width: 600px) {
  .cta-final { padding: 64px 0 56px !important; }
  .cta-final h2 { font-size: clamp(40px, 11vw, 60px); line-height: 1.0; }
  .cta-final .lede { margin: 18px auto 26px; font-size: 15px; max-width: 36ch; }
  .footer { padding: 56px 0 32px; }
}

/* ─── Smooth the cream → teal joins so sections flow ─── */
.signals-dive,
.cta-final,
.features--dark,
.part-intro--dark {
  /* Gentle 24px fade in at the top so the cream above eases into teal */
  background-image: linear-gradient(to bottom, rgba(244,242,236,0.10) 0%, transparent 24px);
}

/* Tighten side padding on the smallest phones */
@media (max-width: 380px) {
  .container { padding-left: 18px; padding-right: 18px; }
}
