/* Ondula — ondula.app
   Tokens mirror the app theme (ondula_mobile/src/constants/theme.ts). */

:root {
  --bg: #F3F5F2;
  --surface: #FFFFFF;
  --surface-alt: #E8EDE7;
  --text: #12201A;
  --text-2: #5D6B63;
  --line: #D6DED5;
  --accent: #F2602F;
  --accent-ink: #B5461D;           /* accent for small text: 4.9:1 on --bg */
  --accent-soft: rgba(242, 96, 47, 0.12);
  --level: #2E7D67;
  --level-ink: #276B58;
  --level-soft: rgba(46, 125, 103, 0.14);
  --water: #3E86D1;
  --grain: #E8D4A8;
  --card-border: transparent;
  --shadow: 0 1px 2px rgba(18, 32, 26, 0.05), 0 10px 28px rgba(18, 32, 26, 0.07);
  --shadow-lg: 0 2px 6px rgba(18, 32, 26, 0.05), 0 24px 60px rgba(18, 32, 26, 0.12);
  --panel: #12201A;
  --panel-text: #EAF1EC;
  --panel-2: #A9B8AF;
  --panel-line: rgba(234, 241, 236, 0.12);
  --badge-bg: #12201A;
  --badge-text: #FFFFFF;
  --header-bg: rgba(243, 245, 242, 0.82);

  --font-display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --font-body: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 22px;
  --radius-sm: 14px;
  --gutter: clamp(16px, 4vw, 40px);
  --section: clamp(64px, 7.5vw, 112px);
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0D1311;
    --surface: #151D1A;
    --surface-alt: #1E2824;
    --text: #EAF1EC;
    --text-2: #93A39A;
    --line: #27332E;
    --accent: #FF7A4D;
    --accent-ink: #FF8A62;
    --accent-soft: rgba(255, 122, 77, 0.16);
    --level: #5CC3A4;
    --level-ink: #5CC3A4;
    --level-soft: rgba(92, 195, 164, 0.16);
    --water: #6AA8E8;
    --grain: #6E6146;
    --card-border: #27332E;
    --shadow: 0 0 0 1px rgba(255, 255, 255, 0.04);
    --shadow-lg: 0 0 0 1px rgba(255, 255, 255, 0.05), 0 24px 60px rgba(0, 0, 0, 0.45);
    --panel: #151D1A;
    --panel-text: #EAF1EC;
    --panel-2: #93A39A;
    --panel-line: rgba(234, 241, 236, 0.08);
    --badge-bg: #EAF1EC;
    --badge-text: #0D1311;
    --header-bg: rgba(13, 19, 17, 0.82);
  }
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.6 var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0 0 1em; text-wrap: pretty; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3 {
  font-family: var(--font-display);
  margin: 0;
  text-wrap: balance;
  overflow-wrap: break-word;
  hyphens: auto;
}
h1 { font-weight: 800; font-size: clamp(2.6rem, 1.4rem + 4.6vw, 5rem); line-height: 1; letter-spacing: -0.022em; }
h2 { font-weight: 800; font-size: clamp(2rem, 1.25rem + 2.7vw, 3.25rem); line-height: 1.05; letter-spacing: -0.02em; }
.nw { white-space: nowrap; hyphens: none; }
h3 { font-weight: 700; font-size: 1.32rem; line-height: 1.2; letter-spacing: -0.012em; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: var(--gutter); }
.wrap-narrow { max-width: 800px; }
.muted { color: var(--text-2); }
.small { font-size: 0.875rem; }
.fine { font-size: 0.875rem; line-height: 1.55; color: var(--text-2); }
.lead { font-size: clamp(1.075rem, 1rem + 0.35vw, 1.25rem); line-height: 1.55; color: var(--text-2); max-width: 34em; }
.i { width: 1.15em; height: 1.15em; flex: none; }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--text); color: var(--bg); padding: 10px 16px; border-radius: 10px;
  font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 12px; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  margin: 0 0 18px;
  font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--accent-ink);
}
.eyebrow::before { content: ""; width: 22px; height: 2px; border-radius: 2px; background: currentColor; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--header-bg);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
}
.header-inner { display: flex; align-items: center; gap: 24px; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.logo-mark { width: 32px; height: 32px; }
.lm-bg { fill: var(--accent); }
.lm-arc { stroke: #fff; }
.lm-dot { fill: #fff; }
.brand-name { font-family: var(--font-display); font-weight: 800; font-size: 1.4rem; letter-spacing: -0.03em; }
.main-nav { margin-left: auto; }
.main-nav ul { display: flex; gap: 4px; }
.main-nav a {
  display: block; padding: 8px 12px; border-radius: 999px;
  font-size: 0.9375rem; font-weight: 550; color: var(--text-2); text-decoration: none;
  transition: color .15s, background-color .15s;
}
.main-nav a:hover { color: var(--text); background: var(--surface-alt); }

.lang-switch { position: relative; }
.lang-switch summary {
  list-style: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  height: 40px; padding: 0 12px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: 0.875rem; font-weight: 650; color: var(--text);
}
.lang-switch summary::-webkit-details-marker { display: none; }
.lang-switch .i-chev { width: 14px; height: 14px; transition: transform .2s; }
.lang-switch[open] .i-chev { transform: rotate(180deg); }
.lang-switch ul {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 168px;
  padding: 6px; border-radius: 16px; background: var(--surface);
  border: 1px solid var(--line); box-shadow: var(--shadow-lg);
}
.lang-switch li a {
  display: block; padding: 10px 12px; border-radius: 10px;
  text-decoration: none; font-size: 0.9375rem; font-weight: 550;
}
.lang-switch li a:hover { background: var(--surface-alt); }
.lang-switch li a[aria-current="page"] { color: var(--accent-ink); }
.lang-switch li a[aria-current="page"]::after { content: " ✓"; }

@media (max-width: 920px) {
  .main-nav { display: none; }
  .lang-switch { margin-left: auto; }
}

/* ---------- store badges ---------- */
.store-badges { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.store-badge {
  display: inline-flex; align-items: center; gap: 12px;
  height: 56px; padding: 0 22px 0 16px; border-radius: 14px;
  background: var(--badge-bg); color: var(--badge-text);
  text-decoration: none; line-height: 1.1;
  transition: transform .2s ease, box-shadow .2s ease;
}
.store-badge:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.store-badge .i { width: 26px; height: 26px; }
.store-badge span { display: flex; flex-direction: column; }
.store-badge small { font-size: 0.72rem; font-weight: 500; opacity: 0.8; }
.store-badge strong { white-space: nowrap; font-family: var(--font-display); font-size: 1.2rem; font-weight: 700; letter-spacing: -0.01em; }

/* ---------- hero ---------- */
.hero { position: relative; overflow-x: clip; padding-block: clamp(40px, 6vw, 88px) clamp(16px, 3vw, 40px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero-copy .eyebrow {
  text-transform: none; letter-spacing: 0; font-weight: 600; font-size: 0.875rem;
  color: var(--text-2); background: var(--surface); border: 1px solid var(--line);
  padding: 6px 14px 6px 10px; border-radius: 999px; margin-bottom: 28px;
}
.hero-copy .eyebrow::before { display: none; }
.eyebrow-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.hero h1 { max-width: 11ch; }
.hero .lead { margin-top: 24px; }
.hero-note { display: flex; gap: 8px; align-items: flex-start; margin: 22px 0 0; font-size: 0.875rem; color: var(--text-2); }
.hero-note .i { margin-top: 2px; }

.hero-visual { position: relative; display: grid; place-items: center; padding: 24px 0 120px; }
.hero-stage { position: relative; width: 290px; transform: translateX(10px); }
.hero-orbit {
  position: absolute; width: 118%; max-width: none; aspect-ratio: 1; left: 50%; top: 50%;
  transform: translate(-50%, -50%); pointer-events: none;
}
.hero-orbit circle { stroke: var(--line); stroke-width: 1.2; }
.hero-orbit .orbit-accent { stroke: var(--accent); stroke-width: 3; stroke-linecap: round; transform-origin: 300px 300px; animation: orbit 90s linear infinite; }
@keyframes orbit { to { transform: rotate(360deg); } }

.today-card {
  position: relative; z-index: 1; width: 100%;
  background: var(--surface); border: 1px solid var(--card-border);
  border-radius: 30px; padding: 22px 22px 18px; box-shadow: var(--shadow-lg);
}
.tc-head { display: flex; justify-content: space-between; align-items: center; }
.tc-greet { font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; letter-spacing: -0.02em; }
.pill { font-size: 0.8125rem; font-weight: 650; padding: 4px 10px; border-radius: 999px; background: var(--level-soft); color: var(--level-ink); }
.week-strip { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin: 16px 0 4px; }
.wd { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 0.75rem; font-weight: 600; color: var(--text-2); }
.wd i { width: 6px; height: 6px; border-radius: 50%; background: var(--line); }
.wd.is-today span { color: var(--text); }
.wd.is-today i { background: var(--text); }
.wd.is-dose span { color: var(--accent-ink); }
.wd.is-dose i { background: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.tc-ring { position: relative; width: 220px; margin: 10px auto 6px; }
.ring-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.ring-value { font-family: var(--font-display); font-weight: 800; font-size: 2.6rem; letter-spacing: -0.03em; line-height: 1; }
.ring-caption { margin-top: 6px; font-size: 0.8125rem; color: var(--text-2); max-width: 9.5em; line-height: 1.3; }
.tc-next { display: flex; justify-content: center; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; margin: 8px 0 0; font-size: 0.875rem; }
.tc-next span { color: var(--text-2); }

.ring-track { stroke: var(--surface-alt); }
.ring-progress { stroke: var(--level); }
.ring-tick { fill: var(--surface); opacity: 0.9; }
.ring-hero .ring-progress { animation: ring-in 1.6s cubic-bezier(.2, .7, .2, 1) .25s both; }
@keyframes ring-in { from { stroke-dasharray: 0 100; } }

.float-card {
  position: absolute; z-index: 2;
  background: var(--surface); border: 1px solid var(--card-border);
  border-radius: 20px; padding: 16px 18px; box-shadow: var(--shadow-lg);
}
.fc-label { display: block; font-size: 0.75rem; font-weight: 650; color: var(--text-2); }
.fc-value { display: block; margin-top: 2px; font-size: 0.95rem; font-weight: 700; }
.fc-note { display: block; margin-top: 6px; font-size: 0.7rem; color: var(--text-2); }
.fc-level { left: -180px; top: calc(100% - 64px); width: 216px; }
.fc-level .mini-chart { width: 100%; height: auto; margin-top: 10px; overflow: visible; }
.fc-nutrition { left: calc(100% - 36px); top: 128px; width: 200px; display: grid; gap: 12px; }
.bar-row { display: grid; grid-template-columns: 1fr auto; row-gap: 6px; align-items: baseline; }
.bar-val { font-size: 0.8125rem; font-weight: 700; }
.bar { grid-column: 1 / -1; height: 8px; border-radius: 99px; background: var(--surface-alt); overflow: hidden; }
.bar-fill { display: block; height: 100%; border-radius: inherit; transform-origin: left; animation: bar-in 1.2s cubic-bezier(.2, .7, .2, 1) .5s both; }
.bar-protein { width: 65%; background: var(--accent); }
.bar-water { width: 62%; background: var(--water); }
@keyframes bar-in { from { transform: scaleX(0); } }

.lc-area { fill: var(--level-soft); }
.lc-line { stroke: var(--level); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; }
.hero .lc-line { animation: draw 1.8s cubic-bezier(.3, .6, .2, 1) .4s both; }
@keyframes draw { from { stroke-dashoffset: 1; } }
.lc-future { stroke: var(--level); stroke-width: 2.4; stroke-dasharray: 3 6; stroke-linecap: round; opacity: 0.75; }
.lc-now { fill: var(--surface); stroke: var(--level); stroke-width: 3; }
.lc-grid { stroke: var(--line); stroke-width: 1; stroke-dasharray: 2 5; }
.lc-base { stroke: var(--line); stroke-width: 1.5; }
.lc-nowline { stroke: var(--text-2); stroke-width: 1.2; stroke-dasharray: 3 4; }
.lc-dose line { stroke: var(--line); stroke-width: 1.5; }
.lc-dose circle { fill: var(--accent); }
.lc-text { font: 600 17px var(--font-body); fill: var(--text-2); }
.lc-text-now { fill: var(--text); }

/* ---------- sections ---------- */
.section { padding-block: var(--section); }
.section-head { margin-bottom: clamp(36px, 5vw, 64px); }
.split { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(24px, 5vw, 80px); align-items: end; }
.split h2 { max-width: 13ch; }

.steps { counter-reset: step; display: grid; gap: 10px; margin-top: 24px; }
.steps li {
  counter-increment: step; display: flex; align-items: center; gap: 14px;
  font-weight: 600; font-size: 0.975rem;
}
.steps li::before {
  content: counter(step); flex: none;
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: var(--surface); border: 1px solid var(--line);
  font-family: var(--font-display); font-weight: 800; font-size: 0.875rem; color: var(--accent-ink);
}

/* ---------- feature bento ---------- */
.bento { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 20px; }
.card {
  background: var(--surface); border: 1px solid var(--card-border);
  border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 14px; display: flex; flex-direction: column; min-width: 0;
}
.card-body { padding: 22px 14px 12px; }
.card-body h3 { margin-bottom: 10px; }
.card-body p { color: var(--text-2); margin: 0; }
.f-dose { grid-column: span 7; }
.f-level { grid-column: span 5; }
.f-nutrition { grid-column: span 5; }
.f-progress { grid-column: span 7; }
.f-export { grid-column: span 12; display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); align-items: center; }
.f-export .card-body { padding: 24px 28px; }

.illo {
  position: relative; background: var(--bg); border-radius: 16px;
  padding: 22px; min-height: 236px; overflow: hidden;
}

.illo-dose { display: flex; align-items: center; gap: 24px; }
.ring-small { width: 132px; flex: none; }
.ring-small .ring-progress { stroke: var(--accent); }
.ring-small .ring-tick { fill: var(--bg); }
.ring-small .ring-track { stroke: var(--surface-alt); }
.sites { flex: 1; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; min-width: 0; }
.site {
  position: relative; display: flex; flex-direction: column; gap: 2px; min-width: 0;
  padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface);
  font-size: 0.875rem; font-weight: 600;
}
.site span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site em { font-style: normal; font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.site.is-next { border-color: var(--accent); background: var(--accent-soft); }
.site.is-next em { color: var(--accent-ink); }
.site.is-last { background: var(--surface-alt); border-color: transparent; color: var(--text-2); }

.illo-level svg { width: 100%; height: auto; overflow: visible; }

.illo-plate { display: flex; align-items: center; }
.illo-plate svg { width: min(260px, 72%); height: auto; }
.vf { stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; }
.plate { fill: var(--surface); stroke: var(--line); stroke-width: 1.5; }
.plate-rim { stroke: var(--line); stroke-width: 1.2; }
.food-protein { fill: var(--accent); opacity: 0.88; }
.food-protein-line { stroke: rgba(255, 255, 255, 0.55); stroke-width: 2.2; stroke-linecap: round; }
.food-green { fill: var(--level); }
.food-grain { fill: var(--grain); }
.scan-chip {
  position: absolute; right: 18px; bottom: 18px;
  display: flex; flex-direction: column; gap: 2px;
  background: var(--surface); border: 1px solid var(--card-border); border-radius: 16px;
  padding: 12px 14px; box-shadow: var(--shadow-lg); min-width: 132px;
}
.scan-chip .tag {
  align-self: flex-start; margin-bottom: 4px; padding: 2px 8px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent-ink); font-size: 0.6875rem; font-weight: 700;
}
.scan-chip strong { font-family: var(--font-display); font-size: 1.1rem; font-weight: 800; letter-spacing: -0.01em; }
.scan-chip span:last-child { font-size: 0.8125rem; color: var(--text-2); }

.illo-progress { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: stretch; }
.mini-label { display: block; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-2); }
.trend { background: var(--surface); border-radius: 14px; padding: 14px 16px; display: flex; flex-direction: column; justify-content: space-between; gap: 12px; }
.trend svg { width: 100%; height: auto; overflow: visible; }
.goal { stroke: var(--level); stroke-width: 1.5; stroke-dasharray: 4 5; opacity: 0.7; }
.trend-line { stroke: var(--text); stroke-width: 3; stroke-linecap: round; }
.trend-dot { fill: var(--accent); stroke: var(--surface); stroke-width: 2.5; }
.cycle { background: var(--surface); border-radius: 14px; padding: 14px 16px; }
.cycle-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 12px; align-items: center; }
.legend { display: inline-flex; align-items: center; gap: 6px; font-size: 0.75rem; color: var(--text-2); font-weight: 600; }
.legend .fx + * { margin-right: 6px; }
.legend .fx:not(:first-child) { margin-left: 6px; }
.cycle-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin-top: 14px; }
.cycle-days li { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.fx-dots { height: 64px; width: 100%; display: flex; flex-direction: column-reverse; align-items: center; justify-content: flex-start; gap: 4px; border-radius: 10px; background: var(--bg); padding: 8px 0; }
.cycle-days b { font-size: 0.75rem; color: var(--text-2); font-weight: 650; }
.fx { display: inline-block; border-radius: 50%; flex: none; }
.fx-n { background: var(--accent); }
.fx-f { background: var(--level); }
.fx.s1 { width: 9px; height: 9px; }
.fx.s2 { width: 14px; height: 14px; }

.illo-export { min-height: 0; display: flex; flex-direction: column; gap: 14px; }
.file-chip {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px 6px 8px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line);
  font: 600 0.8125rem ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.file-chip .i { width: 18px; height: 18px; color: var(--accent-ink); }
.csv { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 0; background: var(--surface); border-radius: 12px; overflow: hidden; font-size: 0.8125rem; }
.csv th, .csv td { text-align: left; padding: 9px 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; border-bottom: 1px solid var(--line); }
.csv tr:last-child td { border-bottom: 0; }
.csv th { font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-2); background: var(--surface-alt); }
.csv td:first-child { font-weight: 650; }
.csv .sk i { display: block; height: 8px; width: 80%; border-radius: 4px; background: var(--surface-alt); }

/* ---------- medications ---------- */
.meds-grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.meds-copy { position: sticky; top: 108px; }
.meds-copy h2 { max-width: 14ch; margin-bottom: 20px; }
.meds-panel { background: var(--surface); border: 1px solid var(--card-border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 10px 28px 28px; }
.med-list li {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px;
  padding: 20px 0; border-bottom: 1px solid var(--line);
}
.med-name { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; letter-spacing: -0.015em; }
.med-rhythm { display: inline-flex; align-items: center; gap: 12px; font-size: 0.9375rem; color: var(--text-2); font-weight: 550; }
.rhythm { width: 76px; height: 12px; }
.rhythm .off { fill: none; stroke: var(--line); stroke-width: 1.4; }
.rhythm-weekly .on { fill: var(--accent); }
.rhythm-daily .on { fill: var(--level); }
.brands { margin: 24px 0 8px; font-size: 0.9375rem; font-weight: 600; }
.meds-panel .fine { margin: 0; }

/* ---------- privacy ---------- */
.privacy-panel {
  position: relative; overflow: hidden; isolation: isolate;
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(32px, 5vw, 72px); align-items: center;
  background: var(--panel); color: var(--panel-text);
  border: 1px solid var(--card-border);
  border-radius: 32px; padding: clamp(32px, 6vw, 80px);
}
.privacy-panel .eyebrow { color: #FF9A73; }
@media (prefers-color-scheme: dark) {
  .privacy-panel { background: radial-gradient(120% 90% at 100% 0%, rgba(92, 195, 164, 0.10), transparent 60%), var(--panel); }
}
.privacy-panel h2 { max-width: 13ch; }
.privacy-panel .lead { color: var(--panel-2); margin-top: 22px; }
.text-link { display: inline-flex; align-items: center; gap: 8px; font-weight: 650; color: #FF9A73; text-underline-offset: 4px; }
.text-link:hover { text-decoration-thickness: 2px; }
.privacy-points { display: grid; gap: 4px; }
.privacy-points li { display: flex; gap: 14px; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid var(--panel-line); font-size: 1.025rem; font-weight: 550; }
.privacy-points li:last-child { border-bottom: 0; }
.privacy-points .i { width: 28px; height: 28px; padding: 5px; border-radius: 50%; background: rgba(92, 195, 164, 0.16); color: #5CC3A4; }
.privacy-orbit { position: absolute; z-index: -1; width: 520px; right: -170px; top: -190px; pointer-events: none; }
.privacy-orbit circle { stroke: var(--panel-line); stroke-width: 1.2; }

/* ---------- pricing ---------- */
.pricing-grid { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: clamp(32px, 6vw, 96px); align-items: center; }
.pricing-copy h2 { margin-bottom: 18px; }
.pricing-copy .lead { color: var(--text); font-weight: 500; }
.pricing-copy .fine { max-width: 34em; margin-top: 18px; }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.plan { background: var(--surface); border: 1px solid var(--card-border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 28px; }
.plan h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.plan-mark { width: 26px; height: 26px; }
.plan li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; font-size: 0.975rem; }
.plan li .i { margin-top: 3px; color: var(--level-ink); }
.plan-pro { border: 2px solid var(--accent); }
.plan-pro li .i { color: var(--accent-ink); }

/* ---------- faq ---------- */
.faq-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.faq-head { position: sticky; top: 108px; }
.faq-head h2 { margin-bottom: 18px; }
.faq-head a { color: var(--accent-ink); font-weight: 650; text-underline-offset: 3px; overflow-wrap: anywhere; }
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: 22px 4px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary h3 { font-size: 1.15rem; }
.faq-item summary .i {
  width: 32px; height: 32px; padding: 7px; border-radius: 50%; flex: none;
  background: var(--surface); border: 1px solid var(--line); transition: transform .25s ease, background-color .2s;
}
.faq-item summary:hover .i { background: var(--surface-alt); }
.faq-item[open] summary .i { transform: rotate(45deg); }
.faq-a { padding: 0 52px 24px 4px; color: var(--text-2); }
.faq-a p { margin: 0; }
.faq-a a { color: var(--accent-ink); font-weight: 600; text-underline-offset: 3px; }

/* ---------- cta ---------- */
.cta { padding-top: 0; }
.cta-panel {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 40px; align-items: center;
  background: var(--surface); border: 1px solid var(--card-border); border-radius: 32px; box-shadow: var(--shadow);
  padding: clamp(32px, 6vw, 72px);
}
.cta-panel h2 { max-width: 15ch; margin-bottom: 16px; }
.cta-panel .store-badges { margin-top: 28px; }
.ring-cta { width: 280px; }
.ring-cta .ring-progress { stroke: var(--accent); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 56px 32px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1.3fr 1fr; gap: 32px; }
.footer-tagline { margin-top: 14px; color: var(--text-2); max-width: 22em; }
.footer-col li { padding: 4px 0; }
.footer-col a { text-decoration: none; font-weight: 550; }
.footer-col a:hover { text-decoration: underline; text-underline-offset: 3px; }
.footer-label { margin: 0 0 6px; font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-2); }
.mail { display: inline-flex; align-items: center; gap: 8px; overflow-wrap: anywhere; }
.footer-langs a[aria-current="page"] { color: var(--accent-ink); }
.footer-base {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 32px; margin-top: 40px; padding-top: 24px;
  background: linear-gradient(var(--line), var(--line)) top center / calc(100% - 2 * var(--gutter)) 1px no-repeat;
}
.footer-base .fine { margin: 0; max-width: 60em; }

/* ---------- legal + 404 ---------- */
.legal { padding-block: 48px 96px; }
.back-link { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 28px; color: var(--text-2); text-decoration: none; font-weight: 600; }
.back-link .i { transform: rotate(180deg); }
.back-link:hover { color: var(--text); }
.prose h1 { font-size: clamp(2.2rem, 1.6rem + 2.6vw, 3.4rem); margin-bottom: 12px; }
.prose h2 { font-size: 1.45rem; letter-spacing: -0.015em; margin: 2.2em 0 0.6em; }
.prose p, .prose li { color: var(--text); line-height: 1.7; }
.prose p:first-of-type em { color: var(--text-2); font-style: normal; font-size: 0.9375rem; }
.prose ul { list-style: disc; padding-left: 1.3em; margin-bottom: 1em; }
.prose a { color: var(--accent-ink); text-underline-offset: 3px; }

.not-found { padding-block: clamp(56px, 10vw, 140px); }
.nf-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 48px; }
.ring-404 { width: 200px; }
.ring-404 .ring-progress { stroke: var(--accent); }
.not-found h1 { font-size: clamp(2.4rem, 1.6rem + 3vw, 3.8rem); margin-bottom: 14px; }
.button {
  display: inline-flex; align-items: center; gap: 10px; margin-top: 12px;
  height: 52px; padding: 0 22px; border-radius: 14px;
  background: var(--badge-bg); color: var(--badge-text); text-decoration: none; font-weight: 650;
}
.nf-langs { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 20px; font-size: 0.9375rem; }
.nf-langs a { color: var(--text-2); }

/* ---------- responsive ---------- */
@media (min-width: 961px) and (max-width: 1320px) {
  .hero-stage { transform: translateX(6px) scale(0.86); }
}

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hero h1 { max-width: 12ch; }
  .hero-visual { min-height: 0; padding: 32px 0 24px; }
  .hero-stage { width: min(100%, 340px); transform: none; display: flex; flex-direction: column; }
  .today-card { padding-bottom: 52px; }
  .hero-orbit { width: 640px; }
  .float-card { position: relative; inset: auto; }
  .fc-nutrition { order: 2; align-self: flex-end; width: 76%; margin: -38px -6px 0 0; }
  .fc-level { order: 3; align-self: flex-start; width: 84%; margin: 12px 0 0 -6px; }

  .split, .meds-grid, .pricing-grid, .faq-grid, .privacy-panel { grid-template-columns: minmax(0, 1fr); }
  .split h2, .meds-copy h2, .privacy-panel h2 { max-width: 16ch; }
  .meds-copy, .faq-head { position: static; }

  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .f-dose, .f-progress, .f-export { grid-column: span 2; }
  .f-level, .f-nutrition { grid-column: span 1; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 720px) {
  .bento { grid-template-columns: minmax(0, 1fr); }
  .f-dose, .f-progress, .f-export, .f-level, .f-nutrition { grid-column: auto; }
  .f-export { grid-template-columns: minmax(0, 1fr); }
  .f-export .card-body { padding: 22px 14px 12px; }
  .f-export .illo { order: -1; }
  .illo { padding: 18px; min-height: 0; }
  .illo-dose { flex-direction: column; align-items: stretch; }
  .ring-small { width: 112px; align-self: center; }
  .illo-progress { grid-template-columns: minmax(0, 1fr); }
  .illo-plate { min-height: 220px; }
  .plans { grid-template-columns: minmax(0, 1fr); }
  .cta-panel { grid-template-columns: minmax(0, 1fr); }
  .ring-cta { display: none; }
  .faq-a { padding-right: 4px; }
}

@media (max-width: 420px) {
  body { font-size: 16px; }
  .today-card { padding: 18px 16px 52px; }
  .tc-ring { width: 200px; }
  .ring-value { font-size: 2.3rem; }
  .store-badges { gap: 10px; }
  .store-badge { flex: 1 1 140px; gap: 10px; padding: 0 12px; }
  .store-badge strong { font-size: 1.05rem; }
  .scan-chip { right: 12px; bottom: 12px; min-width: 0; }
  .illo-plate svg { width: 68%; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .csv th, .csv td { padding: 8px; }
  .csv th:nth-child(3), .csv td:nth-child(3) { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
