/* ===========================================================================
   Project Summit — Marketing site · V4 "Momentum"
   Built on the Summit Design System. One ember accent per screen.
   Light + dark (data-theme). Shared shell + home + page utilities.
   Instrument Serif & JetBrains Mono are self-hosted (woff2) via the @font-face below.
   =========================================================================== */

/* ── Self-hosted webfonts + flag icons ────────────────────────────── */
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/instrument-serif-italic-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/instrument-serif-italic-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/instrument-serif-normal-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/instrument-serif-normal-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/jetbrains-mono-normal-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/jetbrains-mono-normal-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/jetbrains-mono-normal-700-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/jetbrains-mono-normal-700-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* flag icons (self-hosted subset of flag-icons) */
.fi { position: relative; display: inline-block; width: 1.3333em; line-height: 1em; background-size: contain; background-position: 50%; background-repeat: no-repeat; }
.fi::before { content: "\00a0"; }
.fi-gb { background-image: url("../img/flags/gb.svg"); }
.fi-es { background-image: url("../img/flags/es.svg"); }
.fi-es-ct { background-image: url("../img/flags/es-ct.svg"); }

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Color · Light (paper) */
  --bg:          #F6F1E8;
  --bg-soft:     #EFE7D6;
  --card:        #FFFFFF;
  --ink:         #1F1A14;
  --ink-soft:    rgba(31,26,20,0.60);
  --ink-faint:   rgba(31,26,20,0.38);
  --ink-hair:    rgba(31,26,20,0.10);
  --accent:      #D66A2D;
  --accent-2:    #D66A2D;
  --accent-soft: rgba(214,106,45,0.10);
  --accent-line: rgba(214,106,45,0.30);
  /* Text sitting ON an accent background. Deliberately DARK, and deliberately
     the same value in both themes — inverting the text is what fixes this, not
     lightening the accent, because the accent is a fixed brand colour.
     Measured (WCAG 2.1): 5.34:1 on #D66A2D (light), 6.97:1 on #E8834A (dark).
     Both pass AA. What it replaces failed everywhere: #fff was 3.52:1 on the
     light accent and 2.70:1 on the dark one, and #F5EEE0 was 3.05:1.
     This is #14110D, the existing --header-bg / dark --bg, so it adds a role,
     not a colour. NOT redeclared under [data-theme="dark"] on purpose: it is
     theme-invariant by design and a second declaration would only invite drift.
     Unrelated to --accent-on-paper text at 3.13:1 — see
     .impeccable/deferred-contrast.md. */
  --on-accent:   #14110D;
  --header-bg:   #14110D;
  --header-ink:  #F5EEE0;
  --footer-bg:   #14110D;

  /* Service brands */
  --strava:    #FC5200;
  --intervals: #0073FF;
  --health:    #FB2851;

  /* Type families */
  --font-ui:      -apple-system, "SF Pro Text", "SF Pro", "Inter", system-ui, sans-serif;
  --font-display: -apple-system, "SF Pro Display", "SF Pro", "Inter", system-ui, sans-serif;
  --font-serif:   "Instrument Serif", "Times New Roman", Georgia, serif;
  --font-mono:    "JetBrains Mono", "SF Mono", ui-monospace, Menlo, monospace;

  /* Radius */
  --r-data: 2px; --r-chip: 8px; --r-button: 14px; --r-card: 18px; --r-hero: 24px; --r-pill: 999px;

  /* Elevation (light) */
  --e1: 0 1px 2px rgba(0,0,0,0.03);
  --e2: 0 1px 2px rgba(0,0,0,0.03), 0 6px 16px rgba(0,0,0,0.10);
  --e3: 0 4px 0 rgba(0,0,0,0.05), 0 28px 60px rgba(31,26,20,0.22);
  --phone-shadow: 0 0 0 2px rgba(20,17,13,0.9), 0 2px 4px rgba(31,26,20,0.05), 0 18px 50px -10px rgba(31,26,20,0.28);

  --m-quick:      220ms cubic-bezier(.2,.8,.2,1);
  --m-transition: 340ms cubic-bezier(.2,.8,.2,1);

  /* Vibe-tunable */
  --content-max: 960px;
  --wash-opacity: 0.30;
  --section-pad: 88px;

  --phone-ratio: 1206 / 2622;
}

[data-theme="dark"] {
  --bg:          #14110D;
  --bg-soft:     #1E1A15;
  --card:        #1C1813;
  --ink:         #F5EEE0;
  --ink-soft:    rgba(245,238,224,0.62);
  --ink-faint:   rgba(245,238,224,0.38);
  --ink-hair:    rgba(245,238,224,0.10);
  --accent:      #E8834A;
  --accent-2:    #E8834A;
  --accent-soft: rgba(232,131,74,0.14);
  --accent-line: rgba(232,131,74,0.32);
  --header-bg:   #0F0C09;
  --footer-bg:   #0F0C09;
  --e1: none;
  --e2: none;
  --e3: 0 0 0 1px rgba(245,238,224,0.07), 0 28px 60px rgba(0,0,0,0.5);
  --phone-shadow: 0 0 0 2px #000, 0 18px 50px -10px rgba(0,0,0,0.6);
}

html { scroll-behavior: smooth; }

body {
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-weight: 400;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color var(--m-transition), color var(--m-transition);
}

/* Brand wash — single radial, top-right, outside frame */
body::before {
  content: '';
  position: fixed; inset: 0;
  pointer-events: none; z-index: 0;
  background: radial-gradient(ellipse 60% 50% at 100% -8%,
              rgba(214,106,45,var(--wash-opacity)) 0%, transparent 62%);
}

img { display: block; max-width: 100%; }
a { color: inherit; }

/* ── Shared atoms ─────────────────────────────────────────────────── */
.wrap { max-width: var(--content-max); margin: 0 auto; padding-left: 48px; padding-right: 48px; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink-faint);
}
.eyebrow .ember { color: var(--accent); }

.serif-it { font-family: var(--font-serif); font-style: italic; font-weight: 400; }

.section { position: relative; z-index: 1; padding-top: var(--section-pad); padding-bottom: var(--section-pad); }
.section + .section { border-top: 1px solid var(--ink-hair); }

.section-head { margin-bottom: 44px; }
.section-head .eyebrow { margin-bottom: 18px; }
.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  font-weight: 800; line-height: 1.08;
  letter-spacing: -0.03em; color: var(--ink);
  max-width: 18ch; text-wrap: balance;
}
.section-title em { font-style: italic; font-family: var(--font-serif); font-weight: 400; color: var(--accent); }
.section-sub { font-size: 16px; color: var(--ink-soft); max-width: 46ch; margin-top: 16px; line-height: 1.7; }

/* ── App Store badge (official Apple lockups) ─────────────────────────
   The badge is an <img> of Apple's official SVG; app.js swaps the file by
   language (en/es/ca) and colour (white on dark surfaces / dark mode, black
   otherwise). These rules only size it. */
.appstore { display: inline-flex; text-decoration: none; transition: transform var(--m-quick); }
.appstore:hover { transform: translateY(-2px); }
.appstore-img { height: 52px; width: auto; display: block; }
.appstore--sm .appstore-img { height: 40px; }

/* Availability badge */
.avail {
  display: inline-flex; align-items: center; gap: 12px;
}
.avail .avail-text { font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-soft); line-height: 1.4; }
.avail .avail-text b { color: var(--ink); }

/* Live launch pill */
.livepill {
  display: inline-flex; align-items: center; gap: 9px;
  height: 34px; padding: 0 16px 0 13px;
  background: var(--accent-soft); border: 1px solid var(--accent-line);
  border-radius: var(--r-pill);
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent);
}
.livepill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 var(--accent); animation: pulse 2.4s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(214,106,45,0.5);} 70%{ box-shadow: 0 0 0 8px rgba(214,106,45,0);} 100%{ box-shadow:0 0 0 0 rgba(214,106,45,0);} }

/* ── Phone bezel ──────────────────────────────────────────────────── */
.phone {
  position: relative;
  aspect-ratio: var(--phone-ratio);
  border-radius: 13.5%/6.2%;
  background: #14110D;
  box-shadow: var(--phone-shadow);
  overflow: hidden;
}
.phone::before {
  content: ''; position: absolute; top: 1.3%; left: 50%; transform: translateX(-50%);
  width: 31%; height: 4.2%; background: #14110D; border-radius: 999px; z-index: 2;
}
.phone img { width: 100%; height: 100%; object-fit: cover; }

/* =====================================================================
   HEADER
   ===================================================================== */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--header-bg);
  border-bottom: 1px solid rgba(245,238,224,0.10);
}
.nav-progress { position: absolute; bottom: -1px; left: 0; height: 2px; width: 0%; background: var(--accent); transition: width 0.1s linear; z-index: 101; }
.nav {
  max-width: 1180px; margin: 0 auto; padding: 13px 48px;
  display: flex; align-items: center; gap: 22px;
}
.nav-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; margin-right: auto; }
.nav-logo { width: 30px; height: 30px; border-radius: 7px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.nav-name { font-family: var(--font-display); font-size: 25px; font-weight: 900; letter-spacing: -0.04em; color: var(--header-ink); }
.nav-name .dot { color: var(--accent); }

.nav-links { display: flex; align-items: center; gap: 26px; list-style: none; }
.nav-links a { font-size: 13px; font-weight: 400; letter-spacing: 0.01em; color: rgba(245,238,224,0.55); text-decoration: none; transition: color 0.15s; }
.nav-links a:hover, .nav-links a.active { color: var(--header-ink); }

.nav-tools { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }

/* ── "More" dropdown ── */
.nav-more { position: relative; flex-shrink: 0; }
.nav-more-btn {
  display: flex; align-items: center; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 0;
  font-family: var(--font-ui); font-size: 13px; font-weight: 400; letter-spacing: 0.01em;
  color: rgba(245,238,224,0.55); transition: color 0.15s;
}
.nav-more-btn:hover { color: var(--header-ink); }
.nav-more-btn svg { transition: transform 0.2s; }
.nav-more.open .nav-more-btn { color: var(--header-ink); }
.nav-more.open .nav-more-btn svg { transform: rotate(180deg); }
.nav-more-dropdown {
  display: none; position: absolute; top: calc(100% + 12px); left: 50%; transform: translateX(-50%);
  background: #2A241C; border: 1px solid rgba(245,238,224,0.12);
  border-radius: 10px; overflow: hidden; min-width: 180px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.30); z-index: 200;
}
.nav-more.open .nav-more-dropdown { display: block; }
.nav-more-option {
  display: block; width: 100%; padding: 11px 18px;
  font-family: var(--font-ui); font-size: 13px; font-weight: 400;
  color: rgba(245,238,224,0.60); text-decoration: none;
  border-bottom: 1px solid rgba(245,238,224,0.06);
  transition: background 0.15s, color 0.15s;
}
.nav-more-option:last-child { border-bottom: none; }
.nav-more-option:hover { background: rgba(245,238,224,0.06); color: var(--header-ink); }
.nav-more-option.active { color: var(--accent); }

/* ── Language switcher (flag dropdown) ── */
.lang-switcher { position: relative; flex-shrink: 0; }
.lang-selected {
  display: flex; align-items: center; gap: 6px;
  background: none; border: 1px solid rgba(245,238,224,0.20);
  border-radius: 8px; padding: 7px 10px; cursor: pointer;
  font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: 0.12em;
  color: var(--header-ink); transition: border-color 0.15s;
}
.lang-selected:hover { border-color: rgba(245,238,224,0.45); }
.lang-selected svg { transition: transform 0.2s; }
.lang-switcher.open .lang-selected svg { transform: rotate(180deg); }
.lang-dropdown {
  display: none; position: absolute; top: calc(100% + 8px); right: 0;
  background: #2A241C; border: 1px solid rgba(245,238,224,0.12);
  border-radius: 10px; overflow: hidden; min-width: 132px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.30); z-index: 200;
}
.lang-switcher.open .lang-dropdown { display: block; }
.lang-option {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 10px 14px; border: none; background: none; cursor: pointer; text-align: left;
  font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: 0.10em;
  color: rgba(245,238,224,0.50); transition: background 0.15s, color 0.15s;
}
.lang-option:hover { background: rgba(245,238,224,0.06); color: var(--header-ink); }
.lang-option.active { color: var(--accent); }
.lang-option .fi { width: 18px; height: 14px; border-radius: 2px; flex-shrink: 0; }
.theme-toggle {
  width: 38px; height: 38px; border-radius: var(--r-pill);
  border: 1px solid rgba(245,238,224,0.2); background: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center; color: var(--header-ink);
  transition: border-color 0.15s, background 0.15s;
}
.theme-toggle:hover { border-color: rgba(245,238,224,0.45); background: rgba(245,238,224,0.06); }
.theme-toggle svg { width: 17px; height: 17px; }
.theme-toggle .i-moon { display: none; }
[data-theme="dark"] .theme-toggle .i-sun { display: none; }
[data-theme="dark"] .theme-toggle .i-moon { display: block; }

.nav-hamburger { display: none; flex-direction: column; gap: 5px; width: 40px; height: 40px; background: none; border: none; cursor: pointer; align-items: center; justify-content: center; }
.nav-hamburger span { display: block; width: 22px; height: 2px; background: var(--header-ink); border-radius: 2px; transition: transform 0.2s, opacity 0.2s; }
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-mobile { display: none; flex-direction: column; background: var(--header-bg); padding: 4px 24px 22px; }
.nav-mobile.open { display: flex; }
.nav-mobile a { font-size: 16px; color: rgba(245,238,224,0.62); text-decoration: none; padding: 13px 0; border-bottom: 1px solid rgba(245,238,224,0.08); }
.nav-mobile a:hover, .nav-mobile a.active { color: var(--header-ink); }
.nav-mobile-foot { display: flex; margin-top: 16px; padding-top: 20px; border-top: 1px solid rgba(245,238,224,0.08); }
.nav-mobile-foot .appstore { align-self: flex-start; }
.nav-mobile-foot .appstore-img { height: 46px; }

/* =====================================================================
   HERO — shared scaffold
   ===================================================================== */
.hero { position: relative; z-index: 1; overflow: hidden; }
.hero-eyebrow { margin-bottom: 22px; }
.hero-headline {
  font-family: var(--font-display);
  font-weight: 900; line-height: 1.04; letter-spacing: -0.04em;
  color: var(--ink); text-wrap: balance;
}
.hero-headline .drop {
  display: block; font-family: var(--font-serif); font-style: italic; font-weight: 400;
  color: var(--accent); letter-spacing: -0.02em;
}
.hero-sub { font-size: 17px; color: var(--ink-soft); line-height: 1.7; }
.hero-actions { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }

.fade-up { opacity: 1; transform: none; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: no-preference) {
  .fade-up { opacity: 0; transform: translateY(16px); animation: fadeUp 0.6s cubic-bezier(.2,.8,.2,1) forwards; }
}

/* Hero stage cascade — opacity only, so it never clobbers the phones'
   rotate()/translate() fan transforms. Each child sets its own --pop-delay. */
.hero-pop { opacity: 1; }
@keyframes heroPop { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: no-preference) {
  .hero-pop { opacity: 0; animation: heroPop 0.62s cubic-bezier(.2,.8,.2,1) forwards; animation-delay: var(--pop-delay, 0s); }
}

/* Stage container lifts as a unit (transform only — keeps child opacity free
   for the per-element cascade above). */
.hero-rise { transform: none; }
@keyframes heroRise { from { transform: translateY(22px); } to { transform: none; } }
@media (prefers-reduced-motion: no-preference) {
  .hero-rise { animation: heroRise 0.6s cubic-bezier(.2,.8,.2,1) forwards; animation-delay: 0.26s; }
}

/* Callouts slide in from their nearest edge (--co-from) — quick, with a slight
   overshoot/rebound — once the phones have settled. */
.hp-callout.co-in { opacity: 1; }
@keyframes coIn {
  from { opacity: 0; transform: translateX(var(--co-from, -28px)); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .hp-callout.co-in {
    opacity: 0;
    animation: coIn 0.44s cubic-bezier(.34,1.56,.64,1) forwards;
    animation-delay: var(--pop-delay, 0s);
  }
}

/* ── Scroll reveal ──────────────────────────────────────────────────
   Staggered reveal as a section enters the viewport. The visible
   end-state is the base style; we only animate FROM hidden when motion
   is allowed, so reduced-motion + no-JS always show content. */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(34px); }
  .reveal.is-visible {
    opacity: 1; transform: none;
    transition: opacity 0.46s cubic-bezier(.2,.8,.2,1), transform 0.46s cubic-bezier(.2,.8,.2,1);
    transition-delay: calc(var(--reveal-i, 0) * 90ms);
  }
}

/* Hero (Product is the only direction) */
#hero-product { display: block; }

/* ---- Product hero ---- */
#hero-product { padding-top: 70px; padding-bottom: 84px; text-align: center; }
#hero-product .hero-eyebrow { margin-bottom: 22px; }
#hero-product .hp-top { display: flex; flex-direction: column; align-items: center; }
#hero-product .hero-headline { font-size: clamp(2.4rem, 5.4vw, 4rem); margin-bottom: 24px; max-width: 17ch; }
#hero-product .hero-sub { max-width: 50ch; margin: 0 auto 32px; }
#hero-product .hero-actions { justify-content: center; margin-bottom: 56px; }
.hp-stage { position: relative; display: flex; justify-content: center; align-items: flex-end; gap: 0; }
.hp-stage .phone { width: 222px; transition: transform var(--m-transition); }
.hp-stage .hp-center { width: 272px; z-index: 3; }
.hp-stage .hp-side { display: block; }
.hp-stage .hp-side:first-child { transform: rotate(-7deg) translateY(20px); margin-right: -46px; z-index: 1; }
.hp-stage .hp-center + .hp-side { transform: rotate(7deg) translateY(20px); margin-left: -46px; z-index: 2; }
.hp-stage:hover .hp-side:first-child { transform: rotate(-9deg) translateY(12px) translateX(-14px); }
.hp-stage:hover .hp-center + .hp-side { transform: rotate(9deg) translateY(12px) translateX(14px); }
.hp-callout {
  position: absolute; display: flex; flex-direction: column; gap: 4px;
  padding: 12px 16px; background: var(--card); border: 1px solid var(--ink-hair);
  border-radius: var(--r-button); box-shadow: var(--e2); max-width: 190px; z-index: 5;
}
.hp-callout .co-label { font-family: var(--font-mono); font-size: 9px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
.hp-callout .co-text { font-size: 12px; color: var(--ink); line-height: 1.4; font-weight: 500; }
.hp-callout.co1 { top: 8%; left: 2%; }
.hp-callout.co2 { top: 44%; right: 0%; }
.hp-callout.co3 { bottom: 10%; left: 0%; }

/* =====================================================================
   SHOWCASE — real screenshots carousel
   ===================================================================== */
.showcase-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 40px; }
.carousel-arrows { display: flex; gap: 8px; }
.carousel-arrow {
  width: 44px; height: 44px; border-radius: var(--r-pill);
  border: 1px solid var(--ink-hair); background: var(--card); color: var(--ink);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.carousel-arrow:hover { background: var(--bg-soft); border-color: var(--ink-faint); }
.carousel-arrow svg { width: 18px; height: 18px; }
.carousel-track {
  display: flex; gap: 22px; overflow-x: auto; scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch; padding: 6px 0 26px; scrollbar-width: none; cursor: grab;
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-track:active { cursor: grabbing; }
.carousel-item { flex-shrink: 0; scroll-snap-align: center; width: 268px; display: flex; flex-direction: column; gap: 20px; }
.carousel-item .phone { width: 268px; }
.cap { text-align: left; padding-left: 4px; }
.cap-eyebrow { font-family: var(--font-mono); font-size: 10px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); margin-bottom: 5px; }
.cap-title { font-family: var(--font-display); font-size: 14px; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); }
.carousel-dots { display: flex; justify-content: center; gap: 6px; margin-top: 26px; }
.carousel-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-hair); transition: 0.2s; }
.carousel-dot.active { background: var(--accent); transform: scale(1.4); }

/* =====================================================================
   HOW IT THINKS / NUTRITION — split blocks
   ===================================================================== */
.split-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--ink-hair); border: 1px solid var(--ink-hair); border-radius: var(--r-data); overflow: hidden; }
.split-block { background: var(--bg); padding: 40px 36px; transition: background 0.2s; }
.split-block:hover { background: var(--card); }
.split-icon { width: 30px; height: 30px; color: var(--accent); margin-bottom: 18px; stroke-width: 1.6; }
.split-label { font-family: var(--font-mono); font-size: 10px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }
.split-title { font-family: var(--font-display); font-size: 1.25rem; font-weight: 800; line-height: 1.18; letter-spacing: -0.02em; margin-bottom: 12px; color: var(--ink); }
.split-desc { font-size: 14.5px; color: var(--ink-soft); line-height: 1.7; }
.split-link { display: inline-block; margin-top: 14px; font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); text-decoration: none; }
.split-link:hover { text-decoration: underline; }
.badge-beta { display: inline-block; font-family: var(--font-mono); font-size: 9px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); border: 1px solid var(--accent-line); border-radius: 4px; padding: 1px 6px; margin-left: 8px; vertical-align: middle; position: relative; top: -2px; }

/* =====================================================================
   FREE TIER panel
   Card treatment (not another grid) so the offer reads as an offer and not
   as a third feature list on the same page. Tokens only — dark mode follows.
   ===================================================================== */
.free-panel { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items: start; background: var(--card); border: 1px solid var(--accent-line); border-radius: var(--r-card); padding: 44px 40px; box-shadow: var(--e1); }
.free-title { font-family: var(--font-display); font-size: clamp(1.7rem, 3vw, 2.2rem); font-weight: 900; line-height: 1.1; letter-spacing: -0.03em; margin: 14px 0 18px; color: var(--ink); text-wrap: balance; }
.free-title em { font-style: italic; font-family: var(--font-serif); font-weight: 400; color: var(--accent); }
.free-sub { font-size: 14.5px; color: var(--ink-soft); line-height: 1.7; max-width: 46ch; }
.free-actions { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-top: 28px; }
.free-actions .split-link { margin-top: 0; }
.free-note { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; color: var(--ink-faint); margin-top: 16px; }
.free-list { list-style: none; }
.free-list li { font-size: 15px; color: var(--ink-soft); padding: 15px 0; border-bottom: 1px solid var(--ink-hair); display: flex; align-items: flex-start; gap: 13px; line-height: 1.55; }
.free-list li:first-child { padding-top: 0; }
.free-list li:last-child { border-bottom: none; }
.free-list li strong { color: var(--ink); font-weight: 700; }
.free-list li svg { width: 17px; height: 17px; color: var(--accent); flex-shrink: 0; margin-top: 3px; stroke-width: 2.2; }
/* Proof shots — their own full-width row under both panel columns, so the
   offer reads text-first and the captures back it up rather than compete
   with it. Stays 3-across on mobile: at that size they read as "there is a
   real screen behind this claim", which is the whole job. */
.free-shots { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; padding-top: 40px; border-top: 1px solid var(--ink-hair); }
.free-shot { display: flex; flex-direction: column; align-items: center; gap: 15px; }
.free-shot .phone { width: 100%; max-width: 200px; }
/* min() so the caption can never be wider than its grid column — a bare 26ch
   overflows the track once the columns get narrow. */
.free-shot figcaption { font-size: 13px; line-height: 1.5; color: var(--ink-soft); text-align: center; max-width: min(26ch, 100%); }

/* =====================================================================
   FEATURES grid
   ===================================================================== */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--ink-hair); border: 1px solid var(--ink-hair); border-radius: var(--r-data); overflow: hidden; }
.feature-card { background: var(--bg); padding: 34px 30px; transition: background 0.2s; }
.feature-card:hover { background: var(--card); }
.feature-num { font-family: var(--font-mono); font-size: 10px; font-weight: 700; letter-spacing: 0.14em; color: var(--accent); margin-bottom: 18px; }
.feature-title { font-family: var(--font-display); font-size: 1.12rem; font-weight: 800; line-height: 1.2; letter-spacing: -0.02em; margin-bottom: 11px; color: var(--ink); }
.feature-desc { font-size: 14px; color: var(--ink-soft); line-height: 1.7; }
/* Same grid, four columns — used by #getting-started's 4 numbered steps. */
.features-grid--steps { grid-template-columns: repeat(4, 1fr); }

/* =====================================================================
   WHO FOR
   ===================================================================== */
.whofor-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 56px; align-items: start; }
.whofor-title { font-family: var(--font-display); font-size: clamp(1.7rem, 3vw, 2.2rem); font-weight: 900; line-height: 1.1; letter-spacing: -0.03em; margin-bottom: 18px; color: var(--ink); }
.whofor-title em { font-style: italic; font-family: var(--font-serif); font-weight: 400; color: var(--accent); }
.whofor-sub { font-size: 14.5px; color: var(--ink-soft); line-height: 1.7; }
.whofor-list { list-style: none; }
.whofor-list li { font-size: 15px; color: var(--ink-soft); padding: 15px 0; border-bottom: 1px solid var(--ink-hair); display: flex; align-items: flex-start; gap: 13px; line-height: 1.55; }
.whofor-list li:first-child { padding-top: 0; }
.whofor-list li svg { width: 17px; height: 17px; color: var(--accent); flex-shrink: 0; margin-top: 3px; stroke-width: 2.2; }

/* =====================================================================
   INTEGRATIONS
   ===================================================================== */
.integrations-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.integ-card { background: var(--card); border: 1px solid var(--ink-hair); border-radius: var(--r-card); padding: 26px 24px; display: flex; flex-direction: column; gap: 14px; transition: transform var(--m-quick), box-shadow var(--m-quick); box-shadow: var(--e1); }
.integ-card:hover { transform: translateY(-3px); box-shadow: var(--e2); }
.integ-mark { width: 44px; height: 44px; border-radius: var(--r-chip); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.integ-mark svg { width: 24px; height: 24px; }
.integ-role { font-family: var(--font-mono); font-size: 9px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-faint); }
.integ-name { font-family: var(--font-display); font-size: 1.05rem; font-weight: 800; letter-spacing: -0.01em; color: var(--ink); }
.integ-desc { font-size: 13.5px; color: var(--ink-soft); line-height: 1.6; }
.integ-row-2 { display: flex; gap: 16px; margin-top: 16px; }
.integ-mini { flex: 1; background: var(--card); border: 1px solid var(--ink-hair); border-radius: var(--r-card); padding: 18px 22px; display: flex; align-items: center; gap: 14px; }
.integ-mini .integ-mark { width: 36px; height: 36px; }
.integ-mini .integ-mark svg { width: 19px; height: 19px; }
.integ-mini-name { font-family: var(--font-display); font-weight: 800; font-size: 0.98rem; color: var(--ink); letter-spacing: -0.01em; }
.integ-mini-role { font-family: var(--font-mono); font-size: 9px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); margin-top: 2px; }

/* Featured integration (headline launch feature, e.g. Hammerhead Karoo direct).
   Mirrors .integ-card's column layout/padding so its content left-aligns with
   the cards in the grid below — only full-width + accent border set it apart. */
.integ-featured { display: flex; flex-direction: column; gap: 14px; background: var(--card); border: 1px solid var(--accent-line); border-radius: var(--r-card); padding: 26px 24px; margin-bottom: 16px; box-shadow: var(--e1); }
.integ-featured-body { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.integ-featured-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.integ-new { font-family: var(--font-mono); font-size: 9px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: var(--r-data); padding: 3px 8px; }
.integ-featured .integ-desc { max-width: 70ch; }

/* =====================================================================
   FINAL CTA
   ===================================================================== */
.final-cta { position: relative; overflow: hidden; }
.final-cta .wrap { position: relative; z-index: 1; }
.cta-inner { display: block; }
.cta-text { max-width: 640px; }
.cta-title { font-family: var(--font-display); font-size: clamp(2rem, 4.4vw, 3.2rem); font-weight: 900; line-height: 1.02; letter-spacing: -0.035em; margin-bottom: 20px; color: var(--ink); text-wrap: balance; }
.cta-title em { font-style: italic; font-family: var(--font-serif); font-weight: 400; color: var(--accent); }
.cta-body { font-size: 16px; color: var(--ink-soft); margin-bottom: 32px; line-height: 1.7; max-width: 44ch; }
.cta-actions { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
/* Human-support reassurance under the final CTA. Small and quiet on purpose —
   it answers "will anyone actually be there?", it is not a headline. */
.support-line { font-size: 13.5px; line-height: 1.7; color: var(--ink-faint); margin-top: 22px; max-width: 52ch; }
.support-line a { color: var(--accent); text-decoration: none; }
.support-line a:hover { text-decoration: underline; }
.cta-aside { display: flex; flex-direction: column; align-items: center; gap: 22px; }
.cta-qr { width: 150px; height: 150px; border-radius: var(--r-card); background: var(--card); border: 1px solid var(--ink-hair); display: flex; align-items: center; justify-content: center; box-shadow: var(--e2); }
.cta-qr-label { font-family: var(--font-mono); font-size: 10px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); text-align: center; max-width: 18ch; line-height: 1.6; }

/* =====================================================================
   FAQ ACCORDION — shared component (native <details>/<summary>)
   Used by faq.html (full list, inside .faq-category) and by the home
   page's condensed #faq-home block. The page-specific chrome around it
   (.faq-body / .faq-category / .faq-cat-label / .faq-cta on faq.html,
   .faq-home-* here) stays with its page; only the item itself is shared.
   ===================================================================== */
.faq-item { border-bottom: 1px solid var(--ink-hair); }

.faq-question {
  display: flex; align-items: center; justify-content: space-between;
  gap: 20px; padding: 22px 0; cursor: pointer;
  list-style: none; user-select: none;
}
.faq-question::-webkit-details-marker { display: none; }

.faq-q-text {
  font-family: var(--font-display); font-size: 1rem; font-weight: 700;
  letter-spacing: -0.01em; color: var(--ink); line-height: 1.3;
  transition: color 0.15s;
}

.faq-icon {
  width: 24px; height: 24px; flex-shrink: 0;
  border-radius: 50%; border: 1px solid var(--ink-hair);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-size: 16px; font-weight: 300;
  transition: transform 0.2s, background 0.2s;
}

details[open] .faq-icon { transform: rotate(45deg); background: var(--accent-soft); }
details[open] .faq-question .faq-q-text { color: var(--accent); }

.faq-answer {
  padding: 0 0 24px;
  font-size: 15px; color: var(--ink-soft); line-height: 1.8;
  max-width: 680px;
}
.faq-answer p { margin-bottom: 10px; }
.faq-answer p:last-child { margin-bottom: 0; }
.faq-answer strong { font-weight: 600; color: var(--ink); }
.faq-answer a { color: var(--accent); text-decoration: none; }
.faq-answer a:hover { text-decoration: underline; }

.faq-tag {
  display: inline-block;
  font-family: var(--font-mono); font-size: 9px; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  padding: 2px 8px; border-radius: 4px; margin-left: 8px;
  vertical-align: middle; position: relative; top: -2px;
}
.faq-tag--roadmap {
  background: var(--accent-soft); color: var(--accent);
  border: 1px solid var(--accent-line);
}

/* Home page condensed FAQ (#faq-home): the shared items in a bordered
   card, matching the .free-panel / .features-grid surface treatment. */
.faq-home-list { border-top: 1px solid var(--ink-hair); }
.faq-home-list .faq-item:last-child { border-bottom: none; }
.faq-home-more { margin-top: 26px; }
.faq-home-more .split-link { margin-top: 0; }

/* =====================================================================
   PAGE HEADER + PROSE — shared by inner pages (about / roadmap / faq /
   terms / privacy / ambassadors). Bespoke components live in each page's
   own scoped <style> block, but all read these shared tokens.
   ===================================================================== */
.page-header { position: relative; z-index: 1; max-width: var(--content-max); margin: 0 auto; padding: 84px 48px 56px; }
.page-eyebrow { font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); margin-bottom: 20px; }
.page-title { font-family: var(--font-display); font-size: clamp(2rem, 4.4vw, 3rem); font-weight: 900; line-height: 1.06; letter-spacing: -0.035em; color: var(--ink); text-wrap: balance; max-width: 20ch; }
.page-title em { font-style: italic; font-family: var(--font-serif); font-weight: 400; color: var(--accent); }
.page-title .dot { color: var(--accent); }
.page-sub { font-size: 17px; color: var(--ink-soft); line-height: 1.7; max-width: 54ch; margin-top: 18px; }
.page-meta { font-family: var(--font-mono); font-size: 12px; color: var(--ink-faint); letter-spacing: 0.04em; margin-top: 18px; }
.page-section { position: relative; z-index: 1; max-width: var(--content-max); margin: 0 auto; padding: 0 48px 40px; }

/* =====================================================================
   FOOTER
   ===================================================================== */
.site-footer { background: var(--footer-bg); position: relative; z-index: 1; margin-top: 0; }
.footer-inner { max-width: 1180px; margin: 0 auto; padding: 64px 48px 36px; display: grid; grid-template-columns: 2fr 1.1fr 1.1fr; gap: 48px; }
.footer-brand { display: flex; flex-direction: column; gap: 16px; }
.footer-wordmark { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.footer-logo { width: 30px; height: 30px; border-radius: 7px; overflow: hidden; box-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.footer-name { font-family: var(--font-display); font-size: 21px; font-weight: 900; letter-spacing: -0.04em; color: #F5EEE0; }
.footer-name .dot { color: var(--accent); }
.footer-tagline { font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(245,238,224,0.4); }
.footer-desc { font-size: 14px; color: rgba(245,238,224,0.6); line-height: 1.7; max-width: 30ch; }
.footer-col h4 { font-family: var(--font-mono); font-size: 10px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); margin-bottom: 18px; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.footer-col a { font-size: 14px; color: rgba(245,238,224,0.6); text-decoration: none; transition: color 0.15s; display: flex; align-items: center; gap: 8px; }
.footer-col a svg { flex-shrink: 0; opacity: 0.85; }
.footer-col a:hover { color: #F5EEE0; }
.footer-bottom { max-width: 1180px; margin: 0 auto; padding: 20px 48px 34px; border-top: 1px solid rgba(245,238,224,0.1); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.footer-copy { font-family: var(--font-mono); font-size: 11px; color: rgba(245,238,224,0.32); letter-spacing: 0.04em; }
.footer-copy b { color: rgba(245,238,224,0.5); font-weight: 700; }
.footer-made { font-family: var(--font-mono); font-size: 11px; color: rgba(245,238,224,0.32); letter-spacing: 0.04em; }

/* =====================================================================
   VIBE OVERRIDES
   ===================================================================== */
body[data-vibe="product"] { --content-max: 1120px; --wash-opacity: 0.24; --section-pad: 88px; }

/* =====================================================================
   RESPONSIVE
   ===================================================================== */
@media (max-width: 1000px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid--steps { grid-template-columns: repeat(2, 1fr); }
  .integrations-grid { grid-template-columns: 1fr; }
  .cta-inner { grid-template-columns: 1fr; gap: 40px; }
}
@media (max-width: 880px) {
  .nav-links { display: none; }
  .nav-more { display: none; }
  .nav-tools { gap: 10px; }
  .nav-tools .appstore--sm { display: none; }
  .nav-hamburger { display: flex; }

  /* ---- Product hero: overlapping cockpit + callouts become a spec list ---- */
  #hero-product { padding-top: 50px; padding-bottom: 60px; }
  #hero-product .hero-actions { margin-bottom: 40px; }
  #hero-product .hp-stage { flex-wrap: wrap; justify-content: center; gap: 0; }
  #hero-product .hp-stage .hp-side { display: block; width: 112px; }
  #hero-product .hp-stage .hp-center { width: 176px; }
  #hero-product .hp-stage .hp-side:first-child { margin-right: -34px; transform: translateY(10px) rotate(-5deg); z-index: 1; }
  #hero-product .hp-stage .hp-center { z-index: 3; }
  #hero-product .hp-stage .hp-center + .hp-side { margin-left: -34px; transform: translateY(10px) rotate(5deg); z-index: 1; }
  .hp-callout {
    position: static; flex: 0 0 100%; width: 100%; max-width: 440px; margin: 0 auto;
    flex-direction: row; align-items: flex-start; gap: 14px;
    background: transparent; border: none; border-radius: 0; box-shadow: none;
    padding: 14px 2px; border-bottom: 1px solid var(--ink-hair);
  }
  .hp-callout.co1 { margin-top: 28px; border-top: 1px solid var(--ink-hair); }
  .hp-callout .co-label { flex: 0 0 96px; font-size: 10px; }
  .hp-callout .co-text { font-size: 13.5px; }

  .whofor-grid { grid-template-columns: 1fr; gap: 32px; }
  .free-panel { grid-template-columns: 1fr; gap: 32px; padding: 32px 24px; }
  /* Three columns would put each capture at ~88px with a four-line caption
     under it — unreadable both ways. One per row, phone beside its caption,
     keeps the shots legible and the text on two lines. */
  .free-shots { grid-template-columns: 1fr; gap: 22px; padding-top: 28px; }
  .free-shot { flex-direction: row; align-items: center; gap: 18px; }
  .free-shot .phone { flex: 0 0 96px; width: 96px; }
  .free-shot figcaption { text-align: left; max-width: none; }
  .split-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 36px; }
}
@media (max-width: 480px) {
  #hero-product .hp-stage .hp-side { width: 100px; }
  #hero-product .hp-stage .hp-center { width: 162px; }
  #hero-product .hp-stage .hp-side:first-child { margin-right: -30px; }
  #hero-product .hp-stage .hp-center + .hp-side { margin-left: -30px; }
  .hp-callout .co-label { flex-basis: 88px; }
}
@media (max-width: 640px) {
  .wrap { padding-left: 24px; padding-right: 24px; }
  .nav { padding-left: 24px; padding-right: 24px; }
  .page-header { padding-left: 24px; padding-right: 24px; padding-top: 56px; }
  .page-section { padding-left: 24px; padding-right: 24px; }
  :root { --section-pad: 64px; }
  .features-grid { grid-template-columns: 1fr; }
  .features-grid--steps { grid-template-columns: 1fr; }
  .integ-row-2 { flex-direction: column; }
  .integ-mini { min-width: 0; }
  .showcase-top { flex-direction: column; align-items: flex-start; gap: 20px; }
  .footer-inner { grid-template-columns: 1fr; gap: 32px; padding: 48px 24px 30px; }
  .footer-bottom { padding-left: 24px; padding-right: 24px; flex-direction: column; align-items: flex-start; }
  .cta-aside { align-items: flex-start; }
}
/* Narrow phones (iPhone SE and down). The header is the one bar that can't
   reflow: .nav-brand and .nav-tools both refuse to shrink, so below ~370px
   their intrinsic widths plus the nav gap and padding exceed the viewport and
   the whole document scrolls sideways. Nothing is dropped here — the row is
   just tightened until it fits. Must stay AFTER the 640px block above, which
   sets the .nav padding this overrides. */
@media (max-width: 380px) {
  .nav { padding-left: 16px; padding-right: 16px; gap: 12px; }
  .nav-name { font-size: 20px; }
  .nav-logo { width: 26px; height: 26px; }
  .nav-tools { gap: 8px; }
  .lang-selected { padding: 6px 8px; gap: 4px; }
  .theme-toggle { width: 34px; height: 34px; }
  .nav-hamburger { width: 34px; height: 34px; }
}
/* Below any phone screen (the Galaxy Fold cover display reports 280px) even
   the tightened row is ~5px too wide. The wordmark goes and the logo carries
   the brand alone — it is still a link to the home page. */
@media (max-width: 300px) {
  .nav-name { display: none; }
}

/* =====================================================================
   COOKIE CONSENT BANNER
   ===================================================================== */
.consent {
  position: fixed; z-index: 300; left: 16px; right: 16px; bottom: 16px;
  max-width: 720px; margin: 0 auto;
  background: var(--card); color: var(--ink);
  border: 1px solid var(--ink-hair); border-radius: var(--r-card);
  box-shadow: var(--e3);
  padding: 16px 18px;
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
}
.consent-text { font-size: 13.5px; line-height: 1.6; color: var(--ink-soft); flex: 1 1 320px; }
.consent-text a { color: var(--accent); text-decoration: none; }
.consent-text a:hover { text-decoration: underline; }
.consent-actions { display: flex; gap: 10px; flex-shrink: 0; }
.consent-btn {
  font-family: var(--font-ui); font-size: 13px; font-weight: 600;
  border-radius: var(--r-button); padding: 9px 18px; cursor: pointer;
  border: 1px solid var(--ink-hair); background: none; color: var(--ink);
  transition: background 0.15s, border-color 0.15s, opacity 0.15s;
}
.consent-reject:hover { background: var(--bg-soft); border-color: var(--ink-faint); }
.consent-accept { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.consent-accept:hover { opacity: 0.9; }
.footer-cookies {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.04em;
  color: rgba(245,238,224,0.32); background: none; border: none; cursor: pointer; padding: 0;
  text-align: left;
}
.footer-cookies:hover { color: rgba(245,238,224,0.6); }
/* Entry animation. The banner is no longer inserted at DOMContentLoaded — it
   appears after a short delay or on first scroll (see assets/js/consent.js), so
   without this it would just pop in. Slide up from below + fade, gated the same
   way as every other motion in this file: reduced-motion gets it instantly. */
@keyframes consentIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}
/* Deliberately NO `opacity: 0` base and NO `forwards`: the keyframe's own
   `from` does the fade, and the element's natural state is already the `to`
   state. That way an animation that never runs — animations disabled by an
   extension, a broken --m-transition token — leaves the banner fully visible
   instead of invisible-but-present. This is a consent gate; it must fail
   towards being shown. */
@media (prefers-reduced-motion: no-preference) {
  .consent { animation: consentIn var(--m-transition); }
}
@media (max-width: 520px) {
  /* Deliberately a floating card over the content, NOT a bar docked to the
     bottom edge. It was briefly docked; that was reverted on the owner's call:
     the banner sitting over the page is what drives an explicit choice, and no
     choice means no analytics at all — PostHog is never initialised without
     consent. Keep it in front of the content.
     (The sticky App Store CTA further down still has to stand down while this
     is on screen — a floating card at bottom:16px occupies the same corner a
     docked bar would. See html.has-consent in the STICKY MOBILE CTA block.) */
  .consent { flex-direction: column; align-items: stretch; gap: 14px; }
  .consent-text { flex: 0 0 auto; }
  .consent-actions { justify-content: flex-end; }
  /* Kept from the docked version: the desktop 9px padding is only ~35px tall,
     under the 44px touch-target floor. Unrelated to where the banner sits. */
  .consent-btn { min-height: 44px; }
}

/* =====================================================================
   STICKY MOBILE APP STORE CTA  (home — see initStickyCta() in app.js)
   =====================================================================
   Hidden everywhere by default. Only the <=640px block below can show it, and
   only once JS has added .is-visible (hero badge scrolled away AND #download
   not in view). No JS / no IntersectionObserver → it never appears, which is
   the intended failure mode: a permanent bar covering content is worse than
   no bar. Desktop keeps display:none, so its badge never even registers an
   impression. */
.sticky-cta { display: none; }

@media (max-width: 640px) {
  /* Docked edge to edge: unlike the cookie banner it is not asking for a
     decision, so it stays out of the way at the very bottom rather than
     floating over the content. Same --card surface and hairline border, so
     the two still read as one system. They never appear at once. */
  .sticky-cta.is-visible {
    position: fixed; z-index: 200;    /* under the consent banner's 300, over the page */
    left: 0; right: 0; bottom: 0;
    display: flex; align-items: center; justify-content: center; gap: 14px;
    background: var(--card); color: var(--ink);
    border-top: 1px solid var(--ink-hair);
    box-shadow: var(--e3);
    padding: 8px 16px;
    /* Home-indicator clearance. The shorthand above already set an 8px bottom
       padding, so browsers without env()/max() drop this line and keep it —
       the fallback is the preceding declaration, same pattern as .consent. */
    padding-bottom: max(8px, env(safe-area-inset-bottom));
  }
  /* 44px keeps the badge a full touch target while shrinking the bar. */
  .sticky-cta .appstore-img { height: 44px; }
  .sticky-cta .avail-text { font-size: 10px; letter-spacing: 0.06em; }

  /* THE COLLISION: the cookie banner is a floating card pinned to the bottom
     of the viewport (z-index 300, bottom: 16px, 16px insets), so it lands on
     top of this bar. Two stacked things in the bottom corner of a 390px phone
     is unacceptable and the consent gate wins, so consent.js flags <html>
     while its banner is in the DOM (show() adds, remove() clears) and the CTA
     stands down — including when the footer "Cookie settings" link reopens the
     banner later. Written with a class, not :has(): a browser without :has()
     would silently render BOTH, the exact failure this prevents. The selector
     has to out-specify .sticky-cta.is-visible above, hence repeating
     .is-visible rather than using !important. */
  html.has-consent .sticky-cta.is-visible { display: none; }
}
/* Slide up from below + fade. Deliberately NO `opacity: 0` base and NO
   `forwards` — same lesson as .consent above: the keyframe's own `from` does
   the fade and the element's natural state is already the `to` state, so an
   animation that never runs leaves the bar visible instead of
   invisible-but-present. Motion is gated on prefers-reduced-motion. */
@keyframes stickyCtaIn {
  from { opacity: 0; transform: translateY(100%); }
  to   { opacity: 1; transform: none; }
}
@media (max-width: 640px) and (prefers-reduced-motion: no-preference) {
  .sticky-cta.is-visible { animation: stickyCtaIn var(--m-transition); }
}

/* =====================================================================
   LIVE APP STORE RATING BADGE (hero) — hidden until JS confirms a rating
   ===================================================================== */
.rating-badge { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; }
.rating-badge[hidden] { display: none; }            /* beat the inline-flex rule above */
.rating-stars { display: inline-flex; gap: 1px; font-size: 14px; line-height: 1; }
.rating-stars .rstar { color: var(--ink-hair); }    /* empty star */
.rating-stars .rstar.on { color: var(--accent); }   /* filled star */
.rating-text { font-family: var(--font-mono); font-size: 11px; font-weight: 700; letter-spacing: 0.04em; color: var(--ink-soft); }
