/* Kcaly landing (landing-d), design pass 3, 28 Oct 2026. See README.md for the reasoning. */

@font-face { font-family: "Satoshi"; src: url("../fonts/satoshi.woff2") format("woff2"); font-weight: 300 900; font-display: swap; }
@font-face { font-family: "Rubik"; src: url("../fonts/rubik.woff2") format("woff2"); font-weight: 300 900; font-display: swap; }

/* Colours come from the kiwi: the dark of its skin, the cream of its core, one lime accent from the app's progress bar. */
:root {
  --font: "Satoshi", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --rubik: "Rubik", var(--font);   /* the Kcaly wordmark and the app's own UI only */

  --forest-0: #0c110a;
  --forest-1: #15200f;
  --forest-2: #1d2a17;
  --cream: #f3f2ea;
  --cream-2: #d9dbcf;
  --cream-muted: #9ea494;
  --paper: #f4f3ee;
  --paper-2: #e8e7e0;
  --white: #fbfbf8;
  --ink: #10140d;
  --muted: #565b51;
  --lime: #a5d63c;
  --blue: #007aff;

  --m: clamp(20px, 3.4vw, 48px);
  --gap: clamp(112px, 12vw, 200px);
  --t-hero: clamp(60px, 7.4vw, 132px);
  --t-h2: clamp(40px, 5.2vw, 84px);
  --t-state: clamp(22px, 1.9vw, 30px);
  --t-body: clamp(17px, 1.2vw, 19px);
  --t-small: 15px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; } /* with html set, body's clip below applies to body itself instead of being handed to the viewport, so foods bleeding off the edges can't widen the page */
html.lenis, html.lenis body { height: auto; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 500 var(--t-body)/1.5 var(--font); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
h2 { font: 800 var(--t-h2)/.98 var(--font); letter-spacing: -.04em; text-wrap: balance; }
h3 { font: 700 21px/1.15 var(--font); letter-spacing: -.015em; }
a { color: inherit; }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 999px; text-decoration: none; }
.skip:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 6px; }
.wrap { padding: 0 var(--m); max-width: 1600px; margin: 0 auto; position: relative; z-index: 2; }
.lede { font-size: var(--t-body); line-height: 1.55; max-width: 32em; }
.pin { position: sticky; top: 0; height: 100svh; display: flex; align-items: center; overflow: hidden; z-index: 2; padding-top: 56px; }
.pin > .wrap { width: 100%; }


/* ---- buttons: one shape, fully round ------------------------------------ */
.btn { display: inline-flex; align-items: center; gap: 10px; height: 56px; padding: 0 26px; border-radius: 999px; font: 700 16px/1 var(--font); text-decoration: none; white-space: nowrap; transition: transform .25s var(--ease), background-color .25s, color .25s; }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: #262b22; transform: translateY(-2px); }
.btn-light { background: var(--cream); color: var(--forest-0); }
.btn-light:hover { background: #fff; transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn svg { width: 20px; height: 20px; margin-top: -3px; }

/* ---- nav: one glass bar ------------------------------------------------ */
.nav { position: fixed; z-index: 50; top: 14px; left: var(--m); right: var(--m); height: 60px; display: flex; align-items: center; gap: 28px; padding: 0 10px 0 14px; border-radius: 999px;
  background: rgba(251, 251, 248, .64); -webkit-backdrop-filter: blur(22px) saturate(1.6); backdrop-filter: blur(22px) saturate(1.6); /* taste-skill-ignore: the one sticky bar */
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .7), 0 12px 32px rgba(16, 20, 13, .08); transition: background-color .4s, color .4s, box-shadow .4s; } /* taste-skill-ignore: the one sticky bar */
.nav.on-dark { background: rgba(21, 29, 18, .5); color: var(--cream); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .09), 0 12px 32px rgba(0, 0, 0, .25); } /* taste-skill-ignore: the one sticky bar */
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 800 23px/1 var(--rubik); letter-spacing: -.02em; }
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.nav-links { display: flex; gap: 26px; margin-left: auto; }
.nav-links a { text-decoration: none; font: 600 15px/1 var(--font); opacity: .82; transition: opacity .2s; }
.nav-links a:hover { opacity: 1; }
.nav-cta { height: 42px; padding: 0 18px; font-size: 15px; }
.nav.on-dark .nav-cta { background: var(--cream); color: var(--forest-0); }

/* ==== HERO: words left, the phone right; pinned for three steps (main.js settles on one) ==== */
.hero { position: relative; height: 370vh; background: var(--forest-0); color: var(--cream); } /* three steps of one screen each, then a 70vh buffer after Snap */
.hero-pin { position: sticky; top: 0; height: 100svh; min-height: 640px; overflow: hidden; z-index: 2; }
.hero-grid { position: relative; z-index: 2; height: 100%; max-width: 1600px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: center; gap: clamp(24px, 4vw, 72px); padding: 92px var(--m) 28px; }
.hero-copy { padding-left: clamp(0px, 3vw, 56px); position: relative; z-index: 3; }
.hero-title { display: grid; font: 900 var(--t-hero)/.94 var(--font); letter-spacing: -.045em; margin-bottom: clamp(28px, 3.4vw, 48px); }
.hl { color: rgba(243, 242, 234, .2); transition: color .6s var(--ease); justify-self: start; }
.hl:hover { color: rgba(243, 242, 234, .42); }
.hl.on { color: var(--cream); }
.hero-lede { font-size: clamp(18px, 1.35vw, 21px); line-height: 1.5; color: var(--cream-2); max-width: 25em; margin-bottom: clamp(28px, 3vw, 40px); }
.hero-cta { display: flex; }
.hero-now { margin-top: 22px; min-height: 24px; }
.hero-step { position: relative; flex: 1; min-height: 1.5em; color: var(--cream-muted); font-size: var(--t-small); }
.hero-step span { position: absolute; left: 0; top: 0; white-space: nowrap; opacity: 0; transform: translateY(6px); transition: opacity .16s, transform .16s; }
.hero-step span.on { opacity: 1; transform: none; transition: opacity .4s .16s, transform .4s .16s var(--ease); } /* the old line is gone before the new one arrives */
.hero-stage { position: relative; height: 100%; display: grid; align-items: center; justify-items: center; } /* the phone centred, so its foods get even room on both sides */
.hero-phone { position: relative; z-index: 2; height: min(78svh, 820px); aspect-ratio: 1350 / 2760; }
.hero-phone .phone { position: relative; z-index: 1; width: 100%; height: 100%; }
/* The foods of the meal being logged, beside the phone (never over it). main.js places them. */
.hero-foods { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
/* Three layers per food: the outer one is placed and moved by main.js; .c holds the centring and the turn in CSS
   (percentages GSAP never touches, so they stay right whenever the image loads); the image breathes on its own. */
.hf { position: absolute; left: var(--x); top: var(--y); width: var(--w); height: 0; transform-origin: 0 0; }
.hf .c, .pf .c { display: block; transform: translate(-50%, -50%) rotate(var(--r)); }
.hf img { width: 100%; height: auto; filter: drop-shadow(0 22px 22px rgba(0, 0, 0, .5)); will-change: transform; } /* taste-skill-ignore: cast shadow of a real object */

/* ==== LOOKUP (pinned, light): the card comes apart ======================= */
.lookup { position: relative; height: 160vh; background: var(--paper); color: var(--ink); }
.lookup-grid { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(32px, 5vw, 96px); align-items: center; }
.lookup-copy h2 { margin-bottom: 28px; }
.inspect { margin-top: 36px; max-width: 34em; min-height: 300px; position: relative; }
.ins-empty { color: var(--muted); font-size: var(--t-small); }
/* The panel: one food from the card, its record, the maths as one even line, and where its energy comes from.
   The food itself rests on the panel's lower corner. */
.ins-on { position: relative; background: var(--white); border-radius: 30px; padding: 26px 30px 30px; box-shadow: 0 1px 0 rgba(16, 20, 13, .06), 0 30px 60px -30px rgba(16, 20, 13, .38); transform-origin: 30% 100%; } /* taste-skill-ignore: a panel that floats over the page */
.ins-food { position: absolute; right: -40px; bottom: -46px; width: 156px; height: auto; filter: drop-shadow(0 20px 18px rgba(40, 30, 10, .28)); pointer-events: none; } /* taste-skill-ignore: cast shadow of a real object */
.ins-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.ins-name { font: 800 clamp(28px, 2.4vw, 36px)/1.05 var(--font); letter-spacing: -.03em; }
.ins-close { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--paper-2); font-size: 22px; line-height: 1; cursor: pointer; transition: background-color .2s; }
.ins-close:hover { background: #dddcd4; }
.ins-rec { margin: 8px 0 22px; color: var(--muted); font-size: var(--t-small); line-height: 1.4; max-width: 26em; }
/* grams × kcal in 100 g = kcal: three cells of one height on one line */
.ins-eq { display: flex; align-items: center; gap: 10px; }
.ins-ctl { display: flex; align-items: center; height: 56px; gap: 2px; background: var(--paper); border-radius: 999px; padding: 6px; flex: none; }
.ins-ctl button { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--white); font: 700 22px/1 var(--font); cursor: pointer; transition: background-color .2s, transform .15s; box-shadow: 0 1px 2px rgba(0, 0, 0, .08); } /* taste-skill-ignore: a pressable control */
.ins-ctl button:hover { background: #fff; }
.ins-ctl button:active { transform: scale(.9); }
.ins-g { min-width: 72px; text-align: center; font: 800 20px/1 var(--font); font-variant-numeric: tabular-nums; }
.ins-op { font: 700 20px/1 var(--font); color: var(--muted); flex: none; }
.ins-cell { display: grid; align-content: center; justify-items: center; height: 56px; padding: 0 16px; border-radius: 999px; background: var(--paper); flex: none; }
.ins-cell b { font: 800 20px/1 var(--font); font-variant-numeric: tabular-nums; }
.ins-cell small { margin-top: 4px; font: 600 11px/1 var(--font); color: var(--muted); letter-spacing: .01em; }
.ins-res { background: #e3efcf; padding: 0 20px; transform-origin: 50% 50%; }
.ins-res b, .ins-res small { color: #3f7a0c; }
.ins-res b { font-size: 24px; font-weight: 900; }
.ins-bar { display: flex; gap: 3px; height: 8px; margin-top: 24px; max-width: calc(100% - 96px); }
.ins-bar i { flex: var(--w, .33) 1 0; min-width: 0; border-radius: 4px; }
.ins-bar .p, .ins-mac .p i { background: #ff3b30; } .ins-bar .c, .ins-mac .c i { background: #ff9500; } .ins-bar .f, .ins-mac .f i { background: #007aff; }
.ins-mac { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 12px; font-size: var(--t-small); color: var(--muted); max-width: calc(100% - 96px); }
.ins-mac span { display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.ins-mac i { width: 8px; height: 8px; border-radius: 50%; }
.ins-mac b { color: var(--ink); font-weight: 800; font-variant-numeric: tabular-nums; }
.lookup-stage { position: relative; display: grid; justify-items: center; }
.xwrap { perspective: 2400px; width: 100%; display: grid; place-items: center; min-height: 700px; }
/* The app's dark meal card (UIKit LogMealCardView), drawn at --k × its point size, with its own spacing kept. */
.xcard { --k: 1.72; position: relative; width: calc(346px * var(--k)); transform-style: preserve-3d; font-family: -apple-system, "SF Pro Text", system-ui, "Helvetica Neue", Arial, sans-serif; }
.xcard .xl { position: relative; transform-style: preserve-3d; will-change: transform; }
.xcard .x-base { position: absolute; inset: 0; border-radius: calc(22px * var(--k)); background: #2e2e2e; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16), 0 70px 90px -40px rgba(16, 20, 13, .55); } /* taste-skill-ignore: copy of the app UI */
.xcard .x-in { position: relative; padding: calc(9px * var(--k)) calc(12px * var(--k)) calc(12px * var(--k)); transform-style: preserve-3d; }
.xcard .x-hd { display: flex; align-items: center; gap: calc(8px * var(--k)); height: calc(28px * var(--k)); color: #fff; }
.xcard .x-hd b { font-weight: 700; font-size: calc(16px * var(--k)); line-height: 1; margin-right: auto; }
.xcard .x-hd .src { font-weight: 600; font-size: calc(8px * var(--k)); line-height: 1; color: rgba(235, 235, 245, .3); letter-spacing: .3px; }
.xcard .x-hd .det { font-weight: 800; font-size: calc(11px * var(--k)); line-height: 1; color: #636366; letter-spacing: .4px; }
.xcard .x-sep { height: 1px; margin: calc(6px * var(--k)) 0; background: rgba(255, 255, 255, .1); } /* taste-skill-ignore: copy of the app UI */
.xcard .x-energy { display: flex; align-items: center; height: calc(104px * var(--k)); border-radius: calc(15px * var(--k)); background: #1a1a1a; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14), 0 30px 40px -18px rgba(0, 0, 0, .6); color: #fff; } /* taste-skill-ignore: copy of the app UI */
.xcard .x-energy .kc { flex: 1; display: flex; align-items: center; justify-content: center; }
.xcard .x-energy .kc div { display: flex; flex-direction: column; align-items: center; }
.xcard .x-energy .kc b { font-weight: 900; font-size: calc(46px * var(--k)); line-height: 1; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.xcard .x-energy .kc small { font-weight: 800; font-size: calc(13px * var(--k)); line-height: 1; color: rgba(235, 235, 245, .6); margin-top: calc(2px * var(--k)); }
.xcard .x-energy .kc img { width: calc(25px * var(--k)); margin-bottom: calc(14px * var(--k)); }
.xcard .x-energy .mac { width: calc(142px * var(--k)); margin-right: calc(10px * var(--k)); display: grid; gap: calc(9px * var(--k)); }
.xcard .x-energy .mac span { display: flex; align-items: center; height: calc(20px * var(--k)); }
.xcard .x-energy .mac .mi { width: calc(19px * var(--k)); height: calc(19px * var(--k)); margin-right: calc(7px * var(--k)); }
.xcard .x-energy .mac b { font-weight: 600; font-size: calc(17px * var(--k)); line-height: 1; min-width: calc(44px * var(--k)); font-variant-numeric: tabular-nums; }
.xcard .x-energy .mac small { font-weight: 800; font-size: calc(9px * var(--k)); line-height: 1; color: rgba(235, 235, 245, .3); letter-spacing: .5px; margin-left: calc(5px * var(--k)); }
.xcard .x-energy .kc.wide b { font-size: calc(36px * var(--k)); letter-spacing: -1.5px; } /* four digits: the app shrinks the number to fit */
.xcard .x-chips { --lift: 0; display: grid; grid-template-columns: 1fr 1fr; gap: calc((6px + 5px * var(--lift)) * var(--k)) calc((7px + 3px * var(--lift)) * var(--k)); margin-top: calc((6px + 30px * var(--lift)) * var(--k)); transform-style: preserve-3d; }
.xchip { position: relative; display: flex; align-items: center; height: calc(25px * var(--k)); padding: 0 calc(5px * var(--k)) 0 calc(8px * var(--k)); border: 0; text-align: left; cursor: pointer; border-radius: calc(8px * var(--k)); background: #1f1f1f; color: #fff; box-shadow: 0 20px 26px -14px rgba(0, 0, 0, .6); transition: background-color .25s, box-shadow .25s; will-change: transform; } /* taste-skill-ignore: copy of the app UI */
.xchip .ck { width: calc(12px * var(--k)); height: calc(12px * var(--k)); margin-right: calc(7px * var(--k)); color: #30d158; display: grid; flex: none; }
.xchip .ck svg { width: 100%; height: 100%; }
.xchip .nm { font-weight: 400; font-size: calc(14px * var(--k)); line-height: 1; margin-right: auto; white-space: nowrap; }
.xchip em { font-weight: 700; font-size: calc(11px * var(--k)); line-height: 1; font-style: normal; color: rgba(235, 235, 245, .6); background: #333336; padding: calc(4px * var(--k)) calc(8px * var(--k)); border-radius: calc(10px * var(--k)); font-variant-numeric: tabular-nums; }
.xchip:hover { background: #262626; }
.xchip.sel { background: #26301a; box-shadow: inset 0 0 0 calc(1.5px * var(--k)) var(--lime), 0 20px 26px -14px rgba(0, 0, 0, .6); } /* taste-skill-ignore: copy of the app UI */
.xchip:focus { outline: none; }
.xchip:focus-visible { box-shadow: inset 0 0 0 calc(1.5px * var(--k)) #fff, 0 20px 26px -14px rgba(0, 0, 0, .6); } /* taste-skill-ignore: copy of the app UI */
.xchips-odd .xchip:last-child { grid-column: 1 / -1; }

/* ==== SOURCES: exactly one screen, the food committed to its corners ======= */
.sources { position: relative; min-height: 100svh; display: flex; align-items: center; background: var(--forest-1); color: var(--cream); padding: 120px 0; }
.sources-grid { max-width: 1240px; display: grid; grid-template-columns: 5fr 6fr; gap: clamp(32px, 5vw, 96px); align-items: center; }
.sources h2 { max-width: 9em; margin-bottom: 28px; }
.statement { font: 500 var(--t-state)/1.32 var(--font); letter-spacing: -.012em; max-width: 22em; color: var(--cream-2); }
.src-list { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(8px, 1vw, 14px); }
.src-list li { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.src-list b { font: 800 clamp(26px, 2.6vw, 44px)/1.08 var(--font); letter-spacing: -.035em; }
.src-list span { font-size: var(--t-small); font-weight: 600; color: var(--cream-muted); white-space: nowrap; }
.src-list .src-more b { color: var(--lime); }

/* ==== DAY (pinned): the header opens into the label in layers ============== */
.day { position: relative; height: 260vh; background: var(--white); }
.day-grid { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(32px, 5vw, 96px); align-items: center; }
.day-copy h2 { margin-bottom: 28px; max-width: 9em; }
.day-macros { margin-top: 40px; display: grid; gap: 12px; }
.dm { display: flex; align-items: center; gap: 20px; font: 900 clamp(40px, 4vw, 64px)/1 var(--font); letter-spacing: -.04em; }
.dm .dm-food { width: clamp(64px, 5.8vw, 96px); height: clamp(64px, 5.8vw, 96px); object-fit: contain; flex: none; filter: drop-shadow(0 12px 14px rgba(40, 30, 10, .18)); } /* taste-skill-ignore: cast shadow of a real object */
.dm b { font-weight: 900; font-variant-numeric: tabular-nums; min-width: 2.2ch; }
.dm span { font: 600 var(--t-body)/1 var(--font); color: var(--muted); letter-spacing: 0; margin-top: .9em; }
.dm.p b { color: #e5372c; } .dm.c b { color: #e58200; } .dm.f b { color: #0a6fe0; }
.day-stage { display: grid; justify-items: center; }
.lwrap { perspective: 2200px; width: 100%; display: grid; justify-items: center; }
.lcard { --k: 1.1; --u: 1; --R: calc(22px * var(--k)); position: relative; width: calc(388px * var(--k)); transform-style: preserve-3d; transform-origin: 50% 20%; font-family: "Rubik", -apple-system, system-ui, sans-serif; font-size: calc(13px * var(--k)); color: #000; }
/* One sheet. No filter on .lcard (a filter flattens 3D); the soft drop under it is a separate element that grows with the sheet. */
.lc-shadow { position: absolute; inset: 0 0 calc((1 - var(--u)) * var(--bh, 0px)) 0; border-radius: var(--R); box-shadow: 0 50px 70px -30px rgba(40, 30, 10, .3), 0 2px 6px rgba(40, 30, 10, .05); } /* taste-skill-ignore: copy of the app UI */
.ly { position: relative; background: #fff; padding: 0 calc(16px * var(--k)); }
/* The header is a rounded card on its own while the label is closed; its lower corners square off as the label opens. */
.ly0 { border-radius: var(--R) var(--R) calc(var(--R) * max(0, 1 - var(--u) * 40)) calc(var(--R) * max(0, 1 - var(--u) * 40)); padding-top: calc(14px * var(--k)); padding-bottom: calc(4px * var(--k)); }
/* --u opens the label downward out of the header: 0 closed, 1 open. */
.lbody { clip-path: inset(0 -2px calc((1 - var(--u)) * 100%) -2px); }
.lcard.unroll { --u: 0; }
.ly3 { border-radius: 0 0 var(--R) var(--R); padding-bottom: calc(16px * var(--k)); }
.lc-r1 { display: flex; align-items: center; height: calc(36px * var(--k)); position: relative; }
.lc-r1 .wm { font: 800 calc(31px * var(--k))/1 var(--rubik); letter-spacing: -.5px; }
.lc-r1 .today { position: absolute; left: 50%; transform: translateX(-50%); height: calc(34px * var(--k)); padding: 0 calc(20px * var(--k)); border-radius: 99px; display: grid; place-items: center; background: rgba(120, 120, 128, .1); color: rgba(60, 60, 67, .6); font: 600 calc(15px * var(--k))/1 var(--rubik); letter-spacing: .4px; }
.lc-r1 .streak { margin-left: auto; display: flex; align-items: center; gap: 3px; color: #f28c28; font: 700 calc(19px * var(--k))/1 var(--rubik); }
.lc-r1 .streak img { width: calc(22px * var(--k)); height: calc(25px * var(--k)); }
.lc-r2 { display: flex; align-items: center; gap: calc(10px * var(--k)); margin-top: calc(13px * var(--k)); }
.lc-r2 .bar { flex: 1; height: calc(20px * var(--k)); border-radius: 999px; background: #e5e5ea; position: relative; overflow: hidden; }
.lc-r2 .bar i { position: absolute; inset: 0 auto 0 0; width: calc(var(--p, 0) * 100%); border-radius: 999px; background: linear-gradient(90deg, rgb(26, 191, 77), rgb(115, 217, 38)); } /* taste-skill-ignore: copy of the app UI */
.lc-r2 b { font: 800 calc(24px * var(--k))/1 var(--rubik); font-variant-numeric: tabular-nums; }
.lc-r2 small { font: 700 calc(10px * var(--k))/1 var(--rubik); color: rgba(60, 60, 67, .3); margin-top: .7em; }
.lc-r3 { display: flex; justify-content: space-between; margin: calc(14px * var(--k)) 0 calc(4px * var(--k)); }
.lc-r3 span { display: flex; align-items: center; gap: calc(7px * var(--k)); }
.lc-r3 .mi { width: calc(19px * var(--k)); height: calc(19px * var(--k)); }
.lc-r3 b { font: 800 calc(19px * var(--k))/1 var(--rubik); font-variant-numeric: tabular-nums; }
.lc-r3 small { font: 700 calc(10px * var(--k))/1 var(--rubik); color: rgba(60, 60, 67, .3); margin-top: .3em; }
.lc-more { overflow: hidden; }
.lc-more > div { padding-top: calc(6px * var(--k)); }
.nl-rule { height: calc(2px * var(--k)); background: #000; margin: calc(4px * var(--k)) 0; }
.nl-thin { height: 1px; background: rgba(60, 60, 67, .29); margin: calc(3px * var(--k)) 0; } /* taste-skill-ignore: copy of the app UI */
.nl-row { display: flex; justify-content: space-between; align-items: center; padding: calc(2px * var(--k)) 0; font-weight: 500; }
.nl-row.major { font-weight: 700; font-size: calc(14px * var(--k)); padding: calc(4px * var(--k)) 0; }
.nl-row.major span { display: flex; align-items: center; gap: calc(8px * var(--k)); }
.nl-row.major span::before { content: ""; width: calc(4px * var(--k)); height: calc(16px * var(--k)); border-radius: 2px; background: var(--c); }
.nl-row.sub { padding-left: calc(14px * var(--k)); }
.nl-row b { font-weight: 700; font-variant-numeric: tabular-nums; }
.nl-cap { font: 800 calc(11px * var(--k))/1 var(--rubik); color: rgba(60, 60, 67, .6); margin: calc(10px * var(--k)) 0 calc(6px * var(--k)); }
.nl-meal { display: grid; grid-template-columns: calc(58px * var(--k)) 1fr auto; gap: calc(6px * var(--k)); align-items: center; padding: calc(4px * var(--k)) 0; font-size: calc(12px * var(--k)); }
.nl-meal time { color: rgba(60, 60, 67, .3); font-weight: 500; }
.nl-meal span { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.nl-meal b { font-weight: 700; color: rgba(60, 60, 67, .6); }
.nl-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: calc(6px * var(--k)); }
.nl-total span { font: 800 calc(11px * var(--k))/1 var(--rubik); color: rgba(60, 60, 67, .6); }
.nl-total b { font: 800 calc(22px * var(--k))/1 var(--rubik); }
.nl-total b small { font-size: .55em; font-weight: 700; margin-left: 4px; }
.nl-tri { display: flex; gap: calc(3px * var(--k)); height: calc(5px * var(--k)); margin-top: calc(8px * var(--k)); }
.nl-tri i { height: 100%; border-radius: 3px; flex: var(--w) 1 0; }
.nl-tri .f { background: #007aff; } .nl-tri .c { background: #ff9500; } .nl-tri .p { background: #ff3b30; }
.nl-micro { display: grid; grid-template-columns: 1fr 1fr; column-gap: calc(18px * var(--k)); margin-top: calc(4px * var(--k)); }
.nl-micro div { display: flex; justify-content: space-between; padding: calc(3px * var(--k)) 0; font-size: calc(12px * var(--k)); color: rgba(60, 60, 67, .6); font-weight: 500; }
.nl-micro b { color: #000; font-weight: 700; }

/* ==== GOALS (dark) ============================================================ */
.goals { background: var(--forest-0); color: var(--cream); padding: var(--gap) 0; position: relative; }
.goals .lede { color: var(--cream-2); }
.goals-grid { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(32px, 5vw, 96px); align-items: center; }
.goals-copy h2 { margin-bottom: 28px; max-width: 8em; }
.goals-board { --k: 1.18; font-family: -apple-system, "SF Pro Text", system-ui, sans-serif; color: #fff; display: grid; gap: calc(12px * var(--k)); max-width: calc(402px * var(--k) * 1.45); }
.gb-head { display: flex; align-items: center; justify-content: space-between; }
.gb-head h3 { font-weight: 700; font-size: calc(26px * var(--k)); line-height: 1; letter-spacing: 0; font-family: inherit; }
.gb-streak { display: flex; align-items: center; gap: 6px; padding: calc(6px * var(--k)) calc(12px * var(--k)); border-radius: 999px; background: #1c1c1e; font-weight: 700; font-size: calc(14px * var(--k)); line-height: 1; }
.gb-streak img { width: calc(14px * var(--k)); }
.gb-streak small { font-weight: 500; color: rgba(235, 235, 245, .6); font-size: 1em; }
.gb-row { display: grid; grid-template-columns: 1fr 1fr; gap: calc(12px * var(--k)); }
.gb-card { background: #1c1c1e; border-radius: calc(20px * var(--k)); padding: calc(16px * var(--k)); }
.gb-weight { text-align: center; display: grid; gap: calc(8px * var(--k)); align-content: center; }
.gb-weight small { color: rgba(235, 235, 245, .6); font-size: calc(12px * var(--k)); font-weight: 600; }
.gb-weight .v { font: 800 calc(36px * var(--k))/1 var(--rubik); }
.gb-weight .v span { font-size: .45em; color: rgba(235, 235, 245, .6); margin-left: 3px; }
.gb-weight .gbar { height: calc(8px * var(--k)); border-radius: 99px; background: #2c2c2e; overflow: hidden; }
.gb-weight .gbar i { display: block; height: 100%; width: calc(var(--p) * 100%); background: #30d158; border-radius: 99px; }
.gb-weight .log { margin-top: calc(4px * var(--k)); height: calc(36px * var(--k)); border-radius: calc(12px * var(--k)); background: #2c2c2e; display: grid; place-items: center; font-weight: 700; font-size: calc(14px * var(--k)); }
.gb-trend { display: grid; gap: calc(10px * var(--k)); }
.gb-trend .t-h { display: flex; justify-content: space-between; align-items: center; }
.gb-trend .t-h b { font-weight: 700; font-size: calc(18px * var(--k)); line-height: 1; }
.seg { display: flex; padding: 3px; border-radius: 999px; background: #2c2c2e; font-size: calc(12px * var(--k)); font-weight: 600; }
.seg span { padding: calc(4px * var(--k)) calc(10px * var(--k)); border-radius: 999px; color: rgba(235, 235, 245, .6); }
.seg span.on { background: #fff; color: #000; }
.gb-trend svg { width: 100%; height: calc(96px * var(--k)); overflow: visible; }
.gb-trend .wl { fill: none; stroke: #30d158; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.gb-trend .wg { fill: none; stroke: rgba(235, 235, 245, .3); stroke-dasharray: 4 5; stroke-width: 1.5; }
.gb-trend .wd { fill: #30d158; }
.gb-intake .i-h { display: flex; align-items: baseline; gap: 8px; margin-bottom: calc(10px * var(--k)); }
.gb-intake .i-h b { font: 800 calc(22px * var(--k))/1 var(--rubik); }
.gb-intake .i-h small { color: rgba(235, 235, 245, .6); font-size: calc(12px * var(--k)); font-weight: 500; }
.gb-intake .legend { margin-left: auto; display: flex; gap: 10px; font-size: calc(11px * var(--k)); color: rgba(235, 235, 245, .6); }
.gb-intake .legend i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 4px; }
.gb-bars { display: grid; grid-template-columns: auto repeat(7, 1fr); gap: calc(10px * var(--k)); align-items: end; height: calc(170px * var(--k)); }
.gb-bars .axis { height: 100%; display: flex; flex-direction: column; justify-content: space-between; font-size: calc(10px * var(--k)); color: rgba(235, 235, 245, .4); text-align: right; padding-bottom: calc(18px * var(--k)); }
.gb-bar { height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: stretch; }
.gb-bar .stk { display: flex; flex-direction: column-reverse; border-radius: 4px 4px 2px 2px; overflow: hidden; transform-origin: bottom; }
.gb-bar .stk i { display: block; }
.gb-bar .stk .p { background: #ff453a; } .gb-bar .stk .c { background: #ff9f0a; } .gb-bar .stk .f { background: #0a84ff; }
.gb-bar small { margin-top: 6px; text-align: center; font-size: calc(10px * var(--k)); color: rgba(235, 235, 245, .4); height: calc(12px * var(--k)); }

/* ==== MORE: tiles in the app's own card language (grey card, white panel inside) ==== */
.more { padding: var(--gap) 0; background: var(--paper); position: relative; }
.more h2 { margin-bottom: clamp(40px, 5vw, 64px); }
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 14px; }
.tile { position: relative; border-radius: 28px; background: var(--paper-2); padding: 24px; overflow: hidden; display: flex; flex-direction: column; gap: 20px; }
.tile .t-copy h3 { margin-bottom: 8px; }
.tile .t-copy p { color: var(--ink); font-size: 16px; line-height: 1.45; max-width: 30em; }
.panel { margin-top: auto; background: #fff; border-radius: 18px; }
.t-foods { grid-column: span 5; }
.t-scan { grid-column: span 4; }
.t-scan .t-photo { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 30%; }
.t-widget { grid-column: span 3; }
.t-health, .t-lang, .t-private { grid-column: span 4; }
.t-offline { grid-column: span 12; display: grid; grid-template-columns: 6fr 6fr; align-items: center; gap: 24px; }
.t-offline .t-wide { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 18px; }
.t-offline .t-copy { padding: 0 clamp(8px, 4vw, 64px); }
.t-offline h3 { font-size: clamp(24px, 2.4vw, 38px); letter-spacing: -.03em; }
.t-offline .t-copy p { font-size: var(--t-body); }
.foods-ui { padding: 12px; font-family: -apple-system, system-ui, sans-serif; }
.foods-ui .seg { background: #eeeef0; margin-bottom: 8px; display: inline-flex; }
.foods-ui .seg span { color: rgba(60, 60, 67, .6); font-size: 13px; padding: 6px 14px; }
.foods-ui .seg span.on { background: #fff; color: #000; box-shadow: 0 1px 3px rgba(0, 0, 0, .12); } /* taste-skill-ignore: copy of the app UI */
.foods-ui ul { list-style: none; margin: 0; padding: 0; }
.foods-ui li { display: grid; grid-template-columns: 1fr auto; padding: 10px 4px; }
.foods-ui li + li { box-shadow: 0 -1px 0 rgba(60, 60, 67, .12); } /* taste-skill-ignore: copy of the app UI */
.foods-ui li b { font-size: 15px; font-weight: 600; }
.foods-ui li small { grid-row: 2; font-size: 13px; color: rgba(60, 60, 67, .6); }
.foods-ui li em { grid-row: 1 / 3; grid-column: 2; align-self: center; font-style: normal; font-weight: 700; font-size: 14px; }
.widget { margin-top: auto; align-self: center; width: 164px; height: 164px; border-radius: 36px; background: #fff; padding: 16px; font-family: -apple-system, system-ui, sans-serif; }
.wg-ring { position: relative; width: 78px; height: 78px; display: grid; place-items: center; align-content: center; }
.wg-ring svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.wg-ring circle { fill: none; stroke: #e5e5ea; stroke-width: 7; }
.wg-ring .v { stroke: #34c759; stroke-linecap: round; stroke-dasharray: 64 100; }
.wg-ring b { font: 800 19px/1 var(--rubik); position: relative; }
.wg-ring small { font-size: 10px; color: rgba(60, 60, 67, .6); font-weight: 600; position: relative; }
.widget ul { list-style: none; margin: 8px 0 0; padding: 0; display: flex; justify-content: space-between; }
.widget li { display: flex; align-items: center; gap: 3px; font: 700 12px/1 var(--rubik); }
.widget li .mi { width: 13px; height: 13px; }
.lang-ui { padding: 18px; display: flex; justify-content: flex-end; min-height: 84px; align-items: center; overflow: hidden; }
.lang-bub { background: #007aff; color: #fff; font: 400 17px/1.3 -apple-system, system-ui, sans-serif; padding: 9px 15px; border-radius: 19px; white-space: nowrap; }
.tog { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 18px; font: 500 16px/1 -apple-system, system-ui, sans-serif; cursor: pointer; }
.tog input { position: absolute; opacity: 0; pointer-events: none; }
.tog i { width: 51px; height: 31px; border-radius: 16px; background: #e9e9ea; position: relative; transition: background-color .25s; flex: none; }
.tog i::after { content: ""; position: absolute; left: 2px; top: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; box-shadow: 0 3px 8px rgba(0, 0, 0, .15); transition: transform .25s var(--ease); } /* taste-skill-ignore: copy of the app UI */
.tog input:checked + i { background: #34c759; }
.tog input:checked + i::after { transform: translateX(20px); }
.tog input:focus-visible + i { outline: 3px solid var(--blue); outline-offset: 3px; }



/* ==== FOOD ON THE PAGE: a few pieces, each with its own place and its own way in (main.js, data-in) ====
   --x / --y place the centre in the section (y 0 is the line with the section above), --w width, --r turn,
   --d depth (0.8 far, 1.25 near): the nearer, the bigger and softer its cast and the faster it drifts. */
.fx { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.pf { position: absolute; left: var(--x); top: var(--y); width: var(--w); height: 0; transform-origin: 0 0; will-change: transform; }
.pf img { width: 100%; height: auto; filter: drop-shadow(calc(4px * var(--d)) calc(8px + 16px * var(--d)) calc(10px + 16px * var(--d)) rgba(12, 18, 8, calc(.16 + .18 * var(--d)))); } /* taste-skill-ignore: cast shadow of a real object */

/* ==== GET: the next meal comes together beside the line ==================== */
.get { position: relative; background: var(--forest-0); color: var(--cream); padding: clamp(140px, 15vw, 240px) 0; }
.get-grid { display: grid; grid-template-columns: 6fr 6fr; gap: 32px; align-items: center; }
.get-copy { display: grid; gap: 32px; }
.get h2 { max-width: 8.5em; }
.get-side { display: grid; gap: 22px; justify-items: start; }
.get-side p { font-size: var(--t-body); color: var(--cream-2); }
.get-meal { position: relative; width: min(44vw, 660px); justify-self: center; padding-top: 70px; }
/* One composed breakfast, seen from above; the sentence that logs it sits on its upper edge as the app's own bubble. */
.gm-plate { width: 100%; height: auto; filter: drop-shadow(0 40px 46px rgba(0, 0, 0, .55)); will-change: transform; } /* taste-skill-ignore: cast shadow of a real object */
.gm-bub { position: absolute; left: -4%; top: 0; max-width: 21em; text-wrap: balance; padding: 11px 17px 12px; border-radius: 21px 21px 6px 21px; background: #007aff; color: #fff; font: 400 clamp(16px, 1.3vw, 20px)/1.3 -apple-system, system-ui, sans-serif; z-index: 2; transform-origin: 100% 100%; } /* the app's own message bubble */
.store-badge { display: inline-block; border-radius: 12px; transition: transform .25s var(--ease); }
.store-badge img { width: 180px; height: auto; }
.store-badge:hover { transform: translateY(-2px); }
/* Pre-launch notify form (same /api/leads/capture endpoint the old page used); hidden by /js/launch.js once live. */
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.get-side > p:first-child { max-width: 30em; }
.notify { display: flex; flex-wrap: wrap; gap: 10px; width: 100%; max-width: 560px; }
.notify input { flex: 1 1 170px; min-width: 0; height: 56px; padding: 0 22px; border-radius: 999px; border: 1px solid rgba(243, 242, 234, .22); background: rgba(243, 242, 234, .07); color: var(--cream); font: 500 16px/1 var(--font); transition: border-color .2s, background-color .2s; }
.notify input::placeholder { color: var(--cream-muted); }
.notify input:focus { outline: none; border-color: var(--lime); background: rgba(243, 242, 234, .11); }
.notify .btn { flex: none; border: 0; cursor: pointer; }
.notify .btn:disabled { opacity: .6; cursor: default; }
.get-side .notify-status:empty { display: none; }
.get-side .notify-status { color: var(--cream); font-weight: 700; }
.get-side .notify-note { font-size: var(--t-small); color: var(--cream-muted); }
.notify-note a { color: var(--cream-2); }

/* ==== FOOTER =============================================================== */
.foot { background: var(--forest-0); color: var(--cream); padding: 0 0 36px; overflow: hidden; position: relative; }
.foot-word { font: 800 clamp(120px, 27vw, 520px)/.8 var(--rubik); letter-spacing: -.05em; margin: 0 0 clamp(48px, 5vw, 80px) -.04em; }
.foot-row { display: grid; grid-template-columns: 6fr 6fr; gap: var(--m); align-items: start; }
.foot-reach { list-style: none; margin: 0; padding: 0; font: 700 clamp(24px, 2.4vw, 36px)/1.2 var(--font); }
.foot-reach a, .foot-links a { text-decoration: none; }
.foot-reach a:hover, .foot-links a:hover { text-decoration: underline; text-underline-offset: 4px; }
.foot-links { list-style: none; margin: 0; padding: 0; display: flex; gap: 28px; justify-content: flex-end; font-size: var(--t-small); }
.legal { margin-top: clamp(56px, 7vw, 96px); font-size: 13px; line-height: 1.5; color: var(--cream-muted); max-width: 75ch; }

/* The app's macro glyphs are template images; it tints them in code. Same here. */
.mi { display: inline-block; width: 19px; height: 19px; flex: none; background: var(--mi-c); -webkit-mask: var(--mi) center / contain no-repeat; mask: var(--mi) center / contain no-repeat; }
.mi-p { --mi: url("../img/ui/drumstick.svg"); --mi-c: var(--red, #ff3b30); }
.mi-c { --mi: url("../img/ui/wheat.svg"); --mi-c: var(--orange, #ff9500); }
.mi-f { --mi: url("../img/ui/avocado.svg"); --mi-c: #007aff; }
.scr .mi-f { --mi-c: var(--blue); }
.xcard .mi-p, .goals-board .mi-p { --mi-c: #ff453a; } .xcard .mi-c, .goals-board .mi-c { --mi-c: #ff9f0a; } .xcard .mi-f, .goals-board .mi-f { --mi-c: #0a84ff; }


/* ==== TABLET AND PHONE ======================================================== */
@media (max-width: 1100px) {
  .nav-links { display: none; }
  .nav-cta { margin-left: auto; }
  .lookup-grid, .goals-grid, .day-grid, .sources-grid { grid-template-columns: 1fr; }
  .lookup, .day { height: auto; }
  .lookup .pin, .day .pin { position: relative; height: auto; padding: var(--gap) 0; }
  .t-foods, .t-scan { grid-column: span 6; }
  .t-widget, .t-health, .t-lang, .t-private { grid-column: span 12; }
}
@media (max-width: 900px) {
  .hero { height: 370vh; }
  .hero-grid { grid-template-columns: 1fr; grid-template-rows: auto 1fr auto; padding: 80px var(--m) 18px; gap: 10px; align-items: start; }
  .hero-copy { display: contents; }
  .hero-title { grid-row: 1; font-size: clamp(36px, 10vw, 60px); margin: 0; }
  .hero-stage { grid-row: 2; justify-items: center; align-items: center; min-height: 0; }
  .hero-phone { height: min(100%, 106vw); width: auto; margin: 0; } /* fills its row (52vw wide at most), so on short screens it shrinks instead of covering the text */
  .hero-lede { grid-row: 3; font-size: 16px; margin: 0 0 12px; }
  .hero-cta { grid-row: 4; }
  .hero-now { grid-row: 5; margin-top: 4px; }
  .hero-step { display: none; }
  .btn-store { height: 48px; }
}
@media (max-width: 760px) {
  .nav { top: 10px; height: 54px; }
  .xwrap { min-height: 460px; }
  .xcard { --k: .88; }
  .lcard { --k: .84 !important; }
  .lwrap, .xwrap { overflow: visible; }
  .day-stage, .lookup-stage { max-width: 100%; }
  .goals-board { --k: .82; }
  .bento { grid-template-columns: 1fr; }
  .tile { grid-column: 1 / -1 !important; }
  .t-offline { grid-template-columns: 1fr; }
  .get-grid { grid-template-columns: 1fr; }
  .foot-row { grid-template-columns: 1fr; }
  .foot-links { justify-content: flex-start; }
  .src-list li { flex-direction: column; gap: 2px; }
  .pf { width: calc(var(--w) * 1.9); }
  .pf.wide-only { display: none; } /* these would sit on the text of a narrow screen */
  .get-meal { width: 86vw; }
  .notify input { flex-basis: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .hl, .hero-step span { transition: none; }
}
