/* Layout idea: one column, one question per screen, a top-down matcha bowl as the only big picture.
   Palette: celadon paper, deep matcha ink, whisk-foam lime for highlights, three price-line colours. */
:root {
  --bg: #F1F5EA;
  --surface: #FFFFFF;
  --surface2: #E4EDD8;
  --ink: #15221A;
  --muted: #566858;
  --line: #CFDBC1;
  --brand: #2E5B2A;
  --brand-ink: #FFFFFF;
  --foam: #C5E05A;
  --danger: #B3402B;
  --h-floor: #3E8E41;
  --h-max: #D99A1E;
  --h-ceil: #CF4B36;
  --shadow: 0 6px 24px rgba(31, 58, 36, .10);
  --f-display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --f-body: "Figtree", "Avenir Next", "Segoe UI", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0D1610; --surface: #16241B; --surface2: #1E3223; --ink: #E7EFE0; --muted: #98AC9A;
    --line: #2B4130; --brand: #A5D060; --brand-ink: #0D1610; --foam: #C5E05A; --danger: #F08A72;
    --h-floor: #6CC070; --h-max: #F2B84B; --h-ceil: #F07F6B; --shadow: 0 6px 24px rgba(0, 0, 0, .35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0D1610; --surface: #16241B; --surface2: #1E3223; --ink: #E7EFE0; --muted: #98AC9A;
  --line: #2B4130; --brand: #A5D060; --brand-ink: #0D1610; --foam: #C5E05A; --danger: #F08A72;
  --h-floor: #6CC070; --h-max: #F2B84B; --h-ceil: #F07F6B; --shadow: 0 6px 24px rgba(0, 0, 0, .35);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; padding-inline: 16px; background: var(--bg); color: var(--ink);
  font: 400 17px/1.45 var(--f-body); -webkit-font-smoothing: antialiased; min-height: 100%;
}
button { font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; }
h1, h2, h3, p { margin: 0; }
:focus-visible { outline: 3px solid var(--foam); outline-offset: 2px; }
[hidden] { display: none !important; }

.shell { max-width: 720px; margin: 0 auto; padding-block: 0 130px; min-height: 100vh; }
.shell.wide { max-width: 980px; }

/* ---------- top bar ---------- */
.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--bg); padding-block: 10px 6px; }
.top-row { display: flex; align-items: center; gap: 10px; min-height: 40px; }
button.back { width: 40px; height: 40px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); display: grid; place-items: center; cursor: pointer; flex: none; }
button.back[disabled] { opacity: 0; pointer-events: none; }
.phase { font: 600 14px var(--f-body); color: var(--muted); letter-spacing: .02em; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.langs { display: flex; gap: 4px; flex: none; }
.langs button { border: 2px solid transparent; background: transparent; border-radius: 99px; padding: 4px 9px; font: 600 13px var(--f-body); color: var(--muted); cursor: pointer; }
.langs button[aria-pressed="true"] { border-color: var(--brand); color: var(--ink); background: var(--surface); }
.prog { height: 6px; border-radius: 99px; background: var(--surface2); overflow: hidden; margin-top: 8px; }
.prog > i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--brand), var(--foam)); border-radius: 99px; transition: width .5s cubic-bezier(.2, .8, .2, 1); }

/* ---------- screens & transitions ---------- */
.stage { display: grid; padding-top: 18px; }
.screen { grid-area: 1 / 1; min-width: 0; animation: inFwd .42s cubic-bezier(.2, .8, .2, 1) both; }
.screen.back { animation-name: inBack; }
.screen.fade { animation-name: fadeIn; }
.screen.leave { animation: outFwd .2s ease both; pointer-events: none; }
.screen.leave.back { animation-name: outBack; }
@keyframes inFwd { from { opacity: 0; transform: translateX(34px); } to { opacity: 1; transform: none; } }
@keyframes inBack { from { opacity: 0; transform: translateX(-34px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes outFwd { to { opacity: 0; transform: translateX(-26px); } }
@keyframes outBack { to { opacity: 0; transform: translateX(26px); } }

.h1 { font: 800 clamp(34px, 8.5vw, 58px)/1.02 var(--f-display); letter-spacing: -.02em; text-wrap: balance; }
.h2 { font: 700 clamp(25px, 6vw, 34px)/1.12 var(--f-display); letter-spacing: -.01em; text-wrap: balance; }
.lead { color: var(--muted); font-size: 18px; max-width: 54ch; text-wrap: pretty; }
.small { font-size: 14px; color: var(--muted); }
.stack { display: grid; gap: 14px; }
.stack-l { display: grid; gap: 22px; }

/* ---------- welcome ---------- */
.hero { display: grid; justify-items: center; text-align: center; gap: 14px; padding-top: 6px; }
.swirl { width: min(58vw, 230px); height: auto; filter: drop-shadow(0 14px 24px rgba(31, 58, 36, .22)); }
.swirl .spin { transform-origin: 100px 100px; animation: spin 22s linear infinite; }
.swirl .bub { animation: pulse 3.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%, 100% { opacity: .35; transform: scale(.85); } 50% { opacity: .8; transform: scale(1.12); } }
.langpick { display: grid; gap: 10px; width: 100%; max-width: 420px; margin-top: 8px; }
.langpick .small { text-align: center; }
.big-btn { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; padding: 16px 20px; min-height: 58px; border-radius: 18px; border: 2px solid var(--line); background: var(--surface); font: 700 19px var(--f-display); cursor: pointer; transition: transform .15s, border-color .15s, box-shadow .15s; }
.big-btn:hover { border-color: var(--brand); box-shadow: var(--shadow); }
.big-btn:active { transform: scale(.98); }
.big-btn span.code { font: 700 13px var(--f-body); color: var(--muted); }

/* ---------- inputs & options ---------- */
.field { display: flex; gap: 10px; }
.stack-l > *, .stack > * { min-width: 0; }
.input { flex: 1; min-width: 0; width: 100%; font: 600 20px var(--f-body); padding: 16px 18px; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); color: var(--ink); }
.input:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 4px color-mix(in srgb, var(--foam) 45%, transparent); }
.icon-btn { flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 0 16px; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); cursor: pointer; font: 600 15px var(--f-body); }
.icon-btn:hover { border-color: var(--brand); }
.icon-btn svg.die { transition: transform .4s; }
.icon-btn:active svg.die { transform: rotate(180deg); }
.opts { display: grid; gap: 10px; }
.opt { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 16px 18px; min-height: 58px; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); font: 600 17px/1.3 var(--f-body); cursor: pointer; transition: border-color .15s, background .15s, transform .15s; }
.opt:hover { border-color: var(--brand); }
.opt:active { transform: scale(.985); }
.opt[aria-pressed="true"] { border-color: var(--brand); background: var(--surface2); }
.opt .dot { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; transition: all .2s; }
.opt[aria-pressed="true"] .dot { background: var(--brand); border-color: var(--brand); }
.opt .dot svg { opacity: 0; transform: scale(.4); transition: all .2s; color: var(--brand-ink); }
.opt[aria-pressed="true"] .dot svg { opacity: 1; transform: none; }

/* ---------- intro cards ---------- */
.fan { position: relative; height: 150px; margin: 4px auto 6px; width: min(100%, 360px); }
.fan img { position: absolute; top: 0; width: 120px; height: 120px; object-fit: contain; background: #fff; border-radius: 18px; box-shadow: var(--shadow); border: 2px solid var(--line); padding: 6px; }
.fan img:nth-child(1) { left: 6%; transform: rotate(-9deg); animation: bob 5s ease-in-out infinite; }
.fan img:nth-child(2) { left: 50%; margin-left: -60px; top: 12px; z-index: 2; animation: bob 5s ease-in-out -1.6s infinite; }
.fan img:nth-child(3) { right: 6%; transform: rotate(9deg); animation: bob 5s ease-in-out -3.2s infinite; }
@keyframes bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -7px; } }
.steps { display: grid; gap: 10px; counter-reset: s; }
.steps li { list-style: none; display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 16px; background: var(--surface); border: 2px solid var(--line); font-weight: 600; }
.steps li::before { counter-increment: s; content: counter(s); flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; font: 800 16px var(--f-display); }
.steps { padding: 0; margin: 0; }

/* ---------- triads / product cards ---------- */
.triad { display: grid; gap: 12px; }
.prod { position: relative; display: grid; grid-template-columns: 86px minmax(0, 1fr); gap: 12px; align-items: start; padding: 12px; border-radius: 18px; border: 2px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; width: 100%; transition: border-color .2s, opacity .25s, transform .2s, box-shadow .2s; }
.prod:hover { border-color: var(--brand); }
.prod[aria-pressed="true"] { border-color: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--foam) 55%, transparent); transform: scale(1.01); }
.prod.dim { opacity: .5; }
.prod .ph { width: 86px; height: 86px; border-radius: 12px; background: #fff; object-fit: contain; }
.prod .nm { font: 700 17px/1.2 var(--f-display); }
.prod .nm small { display: block; font: 500 14px var(--f-body); color: var(--muted); margin-top: 2px; }
.tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.tag { font: 600 12.5px/1 var(--f-body); padding: 5px 8px; border-radius: 99px; background: var(--surface2); color: var(--ink); }
.tag.warn { background: color-mix(in srgb, var(--h-max) 24%, var(--surface)); }
.more { margin-top: 8px; font-size: 14px; color: var(--muted); display: grid; gap: 3px; }
.more b { color: var(--ink); font-weight: 600; }
.toggle { margin-top: 6px; border: 0; background: none; color: var(--brand); font: 700 14px var(--f-body); padding: 6px 0; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.badge { position: absolute; top: 10px; right: 10px; width: 26px; height: 26px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; opacity: 0; transform: scale(.3); transition: all .25s cubic-bezier(.3, 1.6, .5, 1); }
.prod[aria-pressed="true"] .badge { opacity: 1; transform: none; }
.why { display: grid; gap: 12px; animation: inFwd .4s cubic-bezier(.2, .8, .2, 1) both; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 10px 15px; min-height: 44px; border-radius: 99px; border: 2px solid var(--line); background: var(--surface); font: 600 15px var(--f-body); cursor: pointer; transition: all .15s; }
.chip:hover { border-color: var(--brand); }
.chip:active { transform: scale(.96); }
.chip[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
@media (min-width: 760px) {
  .shell.wide .triad { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .shell.wide .prod { grid-template-columns: 1fr; justify-items: center; text-align: center; padding: 18px 14px; }
  .shell.wide .prod .ph { width: 160px; height: 160px; }
  .shell.wide .tags { justify-content: center; }
  .shell.wide .more { text-align: left; }
}

/* ---------- tokens ---------- */
.tokenbar { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 66px); z-index: 10; display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 16px; background: var(--brand); color: var(--brand-ink); font-weight: 700; box-shadow: var(--shadow); }
.tokenbar .pile { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.tokenbar .pile i { width: 14px; height: 14px; border-radius: 50%; background: var(--brand-ink); opacity: .22; transition: opacity .2s, transform .2s; }
.tokenbar .pile i.on { opacity: 1; background: var(--foam); }
.arow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 14px; align-items: center; padding: 14px; border-radius: 18px; background: var(--surface); border: 2px solid var(--line); }
.arow h3 { font: 700 18px/1.2 var(--f-display); }
.arow p { font-size: 14px; color: var(--muted); }
.step { display: flex; align-items: center; gap: 8px; }
.step button { width: 42px; height: 42px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); cursor: pointer; display: grid; place-items: center; font-size: 22px; font-weight: 700; line-height: 1; }
.step button:hover:not([disabled]) { border-color: var(--brand); }
.step button:active:not([disabled]) { transform: scale(.9); }
.step button[disabled] { opacity: .3; cursor: default; }
.step output { min-width: 26px; text-align: center; font: 800 22px var(--f-display); font-variant-numeric: tabular-nums; }
.tk { grid-column: 1 / -1; display: flex; gap: 5px; }
.tk i { flex: 1; max-width: 34px; height: 10px; border-radius: 99px; background: var(--surface2); transition: background .2s, transform .25s cubic-bezier(.3, 1.6, .5, 1); }
.tk i.on { background: var(--brand); transform: scaleY(1.35); }

/* ---------- rating bars ---------- */
.rhead { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 14px; align-items: center; }
.rhead .ph { width: 96px; height: 96px; border-radius: 16px; background: #fff; object-fit: contain; border: 2px solid var(--line); }
.rrow { display: grid; gap: 8px; padding: 12px 14px 14px; border-radius: 18px; background: var(--surface); border: 2px solid var(--line); transition: border-color .2s; }
.rrow.set { border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); }
.rrow .top2 { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.rrow h3 { font: 700 17px/1.2 var(--f-display); }
.rrow output { font: 800 22px var(--f-display); font-variant-numeric: tabular-nums; min-width: 2ch; text-align: right; color: var(--brand); }
.rate { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 3px; height: 46px; touch-action: pan-y; cursor: pointer; user-select: none; -webkit-user-select: none; }
.rate i { border-radius: 8px; background: var(--surface2); transition: background .15s, transform .15s; }
.rate i.on { background: var(--brand); }
.rate i.cur { transform: scaleY(1.12); background: var(--foam); box-shadow: 0 0 0 2px var(--brand); }
.rscale { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); }

/* ---------- price line ---------- */
.ruler { position: relative; height: 112px; margin: 18px 22px 6px; touch-action: pan-y; user-select: none; -webkit-user-select: none; cursor: pointer; }
.rtrack { position: absolute; left: 0; right: 0; top: 56px; height: 16px; border-radius: 99px; background: linear-gradient(90deg, #8DC96B, #E7C85A 55%, #E58A6E); opacity: .55; }
.rband { position: absolute; top: 52px; height: 24px; border-radius: 99px; background: color-mix(in srgb, var(--brand) 35%, transparent); border: 2px solid var(--brand); transition: left .12s, width .12s; }
.rticks { position: absolute; left: 0; right: 0; top: 84px; height: 22px; }
.rticks span { position: absolute; transform: translateX(-50%); font: 600 12px var(--f-body); color: var(--muted); font-variant-numeric: tabular-nums; }
.rticks span::before { content: ""; position: absolute; left: 50%; top: -10px; width: 2px; height: 6px; background: var(--line); transform: translateX(-50%); }
.hd { position: absolute; top: 42px; width: 44px; height: 44px; margin-left: -22px; border-radius: 50%; border: 4px solid var(--surface); background: var(--c); box-shadow: 0 3px 10px rgba(0, 0, 0, .3); cursor: grab; touch-action: pan-y; padding: 0; transition: left .12s, transform .15s; }
.hd.drag { cursor: grabbing; transform: scale(1.15); transition: transform .15s; }
.hd.sel { box-shadow: 0 0 0 4px color-mix(in srgb, var(--c) 40%, transparent), 0 3px 10px rgba(0, 0, 0, .3); }
.hd .hv { position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); background: var(--c); color: #fff; font: 800 15px var(--f-display); padding: 3px 9px; border-radius: 10px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.hd[data-k="floor"] { --c: var(--h-floor); } .hd[data-k="max"] { --c: var(--h-max); } .hd[data-k="ceil"] { --c: var(--h-ceil); }
.mrow { display: grid; grid-template-columns: 14px minmax(0, 1fr) auto auto; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; width: 100%; }
.mrow[aria-pressed="true"] { border-color: var(--c); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 25%, transparent); }
.mrow i.sw { width: 14px; height: 14px; border-radius: 50%; background: var(--c); }
.mrow .lb { font-weight: 600; font-size: 15.5px; line-height: 1.25; }
.mrow output { font: 800 19px var(--f-display); min-width: 4.5ch; text-align: right; font-variant-numeric: tabular-nums; }
.mrow output.empty { font: 500 13px var(--f-body); color: var(--muted); }
.mrow .nudge { display: flex; gap: 4px; }
.mrow .nudge span { width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; font-weight: 700; background: var(--bg); }
.mrow .nudge span.off { opacity: .25; }
.mrow[data-k="floor"] { --c: var(--h-floor); } .mrow[data-k="max"] { --c: var(--h-max); } .mrow[data-k="ceil"] { --c: var(--h-ceil); }

/* ---------- done ---------- */
.dbars { display: grid; gap: 10px; }
.dbar { display: grid; grid-template-columns: minmax(0, 118px) minmax(0, 1fr) 2.2ch; gap: 10px; align-items: center; font-size: 14.5px; font-weight: 600; }
.dbar .tr { height: 14px; border-radius: 99px; background: var(--surface2); overflow: hidden; }
.dbar .tr i { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--brand), var(--foam)); transition: width 1s cubic-bezier(.2, .8, .2, 1); }
.dbar b { font-variant-numeric: tabular-nums; text-align: right; }
.card { padding: 18px; border-radius: 22px; background: var(--surface); border: 2px solid var(--line); display: grid; gap: 14px; }
.wrange { display: grid; grid-template-columns: minmax(0, 118px) minmax(0, 1fr) auto; gap: 10px; align-items: center; font-size: 14.5px; font-weight: 600; }
.wrange .tr { position: relative; height: 14px; border-radius: 99px; background: var(--surface2); }
.wrange .tr i { position: absolute; top: 0; height: 100%; border-radius: 99px; background: color-mix(in srgb, var(--brand) 45%, transparent); }
.wrange .tr b { position: absolute; top: -3px; width: 20px; height: 20px; margin-left: -10px; border-radius: 50%; background: var(--h-max); border: 3px solid var(--surface); }
.wrange output { font: 800 16px var(--f-display); font-variant-numeric: tabular-nums; }
.status { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--muted); }
.status button { border: 2px solid var(--danger); background: none; color: var(--danger); font-weight: 700; padding: 10px 14px; border-radius: 12px; cursor: pointer; }
canvas.confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 50; }

/* ---------- bottom bar ---------- */
.bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 28px 16px calc(14px + env(safe-area-inset-bottom, 0px)); background: linear-gradient(to bottom, color-mix(in srgb, var(--bg) 0%, transparent), var(--bg) 42%); pointer-events: none; }
.bar-in { max-width: 720px; margin: 0 auto; display: flex; gap: 10px; align-items: center; pointer-events: auto; }
.shell.wide ~ .bar .bar-in, .bar.wide .bar-in { max-width: 980px; }
.cta { flex: 1; min-height: 58px; border-radius: 18px; border: 0; background: var(--brand); color: var(--brand-ink); font: 800 19px var(--f-display); cursor: pointer; transition: transform .15s, opacity .2s, box-shadow .2s; box-shadow: 0 8px 22px color-mix(in srgb, var(--brand) 35%, transparent); }
.cta:active:not([disabled]) { transform: scale(.98); }
.cta[disabled] { opacity: .35; box-shadow: none; cursor: default; }
.hint { font-size: 13.5px; color: var(--muted); text-align: center; }
.debug { margin-top: 30px; padding: 12px; border-radius: 12px; background: var(--surface2); font: 12px/1.4 ui-monospace, Menlo, monospace; white-space: pre-wrap; word-break: break-all; }

@media (min-width: 760px) {
  body { font-size: 18px; }
  .prod .nm { font-size: 18px; }
}
@media (max-width: 380px) {
  .prod { grid-template-columns: 72px minmax(0, 1fr); }
  .prod .ph { width: 72px; height: 72px; }
  .dbar, .wrange { grid-template-columns: minmax(0, 92px) minmax(0, 1fr) auto; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ---------- v2: story, crash course, explained facts ---------- */
.gloss { flex: none; width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--brand); background: var(--surface); color: var(--brand); font: 800 17px var(--f-display); cursor: pointer; }
.gloss:hover { background: var(--brand); color: var(--brand-ink); }
.ico { display: inline-grid; place-items: center; flex: none; color: var(--brand); }
.info { flex: none; margin-left: auto; width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--muted); color: var(--muted); font: italic 700 11px/13px Georgia, serif; text-align: center; }

.passport { display: grid; gap: 8px; grid-column: 1 / -1; min-width: 0; }
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.fact, .taste, .know { display: flex; align-items: center; gap: 8px; text-align: left; border: 0; cursor: pointer; background: var(--surface2); border-radius: 12px; padding: 8px 10px; min-width: 0; }
.fact:hover, .taste:hover, .know:hover { box-shadow: inset 0 0 0 2px var(--brand); }
.fact.warn { background: color-mix(in srgb, var(--h-max) 22%, var(--surface)); }
.taste { background: color-mix(in srgb, var(--foam) 30%, var(--surface)); }
.ft { display: grid; min-width: 0; line-height: 1.2; }
.ft small { font: 600 11.5px var(--f-body); color: var(--muted); }
.ft b { font: 700 14px var(--f-body); overflow-wrap: anywhere; }
.more-facts { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
.more-facts b { color: var(--ink); font-weight: 600; }
.more-facts p { margin: 0; }
.prod.demo { cursor: default; }
.prod.demo:hover { border-color: var(--line); }
.passport .toggle { justify-self: start; margin-top: 0; }

.mission { background: var(--surface); border-radius: 18px; border-left: 6px solid var(--brand); padding: 14px 16px; box-shadow: var(--shadow); }
.mission small { font: 700 13px var(--f-body); color: var(--muted); }
.mission p { font: 700 19px/1.3 var(--f-display); margin-top: 2px; }

.sheet { position: fixed; inset: 0; z-index: 60; background: rgba(8, 20, 12, .5); display: grid; align-items: end; justify-items: center; animation: fadeIn .2s ease both; }
.sheet.out { animation: sheetOut .2s ease both; }
.sheet-panel { width: 100%; max-width: 560px; max-height: 86vh; overflow: auto; background: var(--bg); color: var(--ink); border-radius: 26px 26px 0 0; padding: 12px 20px calc(22px + env(safe-area-inset-bottom, 0px)); display: grid; gap: 14px; animation: sheetUp .32s cubic-bezier(.2, .8, .2, 1) both; }
.sheet.out .sheet-panel { animation: sheetDown .2s ease both; }
.sheet-grab { width: 44px; height: 5px; border-radius: 9px; background: var(--line); justify-self: center; }
.gl-item { display: grid; gap: 6px; background: var(--surface); border-radius: 16px; padding: 14px 16px; }
.gl-item p { margin: 0; font-size: 16px; }
.gl-h { display: flex; align-items: center; gap: 10px; }
.gl-h h3 { font: 700 18px var(--f-display); }
.sheet-foot { display: flex; justify-content: flex-end; }
@keyframes sheetUp { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes sheetDown { to { transform: translateY(40px); opacity: 0; } }
@keyframes sheetOut { to { opacity: 0; } }
@media (min-width: 760px) { .sheet { align-items: center; } .sheet-panel { border-radius: 26px; } }

.dots { display: flex; gap: 6px; }
.dots i { height: 6px; width: 22px; border-radius: 9px; background: var(--surface2); transition: background .3s, width .3s; }
.dots i.done { background: color-mix(in srgb, var(--brand) 45%, var(--surface2)); }
.dots i.on { background: var(--brand); width: 38px; }
.crash-body { display: grid; }
.ccard { background: var(--surface); border-radius: 24px; padding: 22px 20px; display: grid; gap: 14px; box-shadow: var(--shadow); }
.ccard .cin, .cin { animation: inFwd .38s cubic-bezier(.2, .8, .2, 1) both; }
.cin.rev { animation-name: inBack; }
.cico { width: 54px; height: 54px; border-radius: 50%; background: color-mix(in srgb, var(--foam) 45%, var(--surface)); display: grid; place-items: center; }
.cico .ico svg { width: 28px; height: 28px; }
.segs { display: flex; gap: 8px; }
.seg { flex: 1; min-height: 48px; border-radius: 14px; border: 2px solid var(--line); background: var(--surface); font: 700 16px var(--f-body); cursor: pointer; transition: all .15s; }
.seg[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.cups { display: flex; flex-wrap: wrap; gap: 5px; min-height: 22px; }
.cups i { width: 14px; height: 14px; border-radius: 4px 4px 7px 7px; background: linear-gradient(var(--foam), var(--brand)); animation: popIn .3s cubic-bezier(.3, 1.6, .5, 1) both; }
@keyframes popIn { from { transform: scale(0); } to { transform: scale(1); } }
.big-note { font: 800 22px var(--f-display); color: var(--brand); }
.chip.big { min-height: 50px; padding: 12px 20px; font-size: 17px; }
.chip.with-ico { display: inline-flex; align-items: center; gap: 8px; }
.chip.with-ico .ico { color: inherit; }
.chip.seen:not([aria-pressed="true"]) { border-color: color-mix(in srgb, var(--brand) 55%, var(--line)); }
.explain { background: var(--surface2); border-radius: 14px; padding: 14px 16px; min-height: 4.4em; margin: 0; }
.explain.pop { animation: inFwd .3s cubic-bezier(.2, .8, .2, 1) both; }

.rrow .know { width: 100%; margin: 2px 0 8px; font: 500 14px/1.3 var(--f-body); color: var(--ink); }
.rrow .know span:not(.ico) { min-width: 0; overflow-wrap: anywhere; }
.na-btn { border: 2px solid var(--line); background: transparent; color: var(--muted); border-radius: 99px; padding: 4px 12px; font: 600 13px var(--f-body); cursor: pointer; }
.na-btn[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.rrow.na .rate { opacity: .3; }
.cupnote { background: color-mix(in srgb, var(--foam) 28%, var(--surface)); border-radius: 14px; padding: 12px 14px; font-weight: 600; margin: 0; }
@media (prefers-reduced-motion: reduce) { .cups i, .sheet, .sheet-panel, .ccard, .cin, .explain.pop { animation: none !important; } }
@media (min-width: 760px) { .shell.wide .facts { grid-template-columns: 1fr; } .shell.wide .passport { text-align: left; } }

/* ---------- v2.1: mobile polish ---------- */
html { touch-action: manipulation; }
body { min-height: 100dvh; overscroll-behavior-y: none; }
.shell { min-height: 100dvh; }
.top { padding-block: 6px 4px; }
.top-row { min-height: 36px; gap: 8px; }
button.back { width: 36px; height: 36px; }
.gloss { width: 34px; height: 34px; }
.prog { height: 5px; margin-top: 6px; }
.stage { padding-top: 12px; }
.phase { font-size: 13.5px; }
.cta { min-height: 54px; font-size: 18px; }
.bar { padding-top: 20px; }
.fact em { font: 600 11.5px/1.2 var(--f-body); font-style: normal; color: var(--muted); }
.hd.lift .hv { bottom: calc(100% + 34px); }
.hd.lift .hv::after { content: ""; position: absolute; left: 50%; top: 100%; width: 3px; height: 30px; margin-left: -1.5px; background: var(--c); border-radius: 2px; }
.rrow .know .kl { display: grid; gap: 2px; min-width: 0; }
.prod.dim .passport { display: none; }
.prod.dim { padding-block: 8px; }
.step button { width: 46px; height: 46px; }
@media (max-width: 520px) {
  body { padding-inline: 14px; }
  .h1 { font-size: 34px; }
  .prod { grid-template-columns: 70px minmax(0, 1fr); padding: 10px; gap: 8px 10px; }
  .prod .ph { width: 70px; height: 70px; }
  .prod .nm { font-size: 16px; }
  .fact, .taste { padding: 7px 8px; gap: 6px; }
  .ft b { font-size: 13.5px; }
  .ft small { font-size: 11px; }
  .info { width: 14px; height: 14px; font-size: 10px; line-height: 11px; }
  .chip { padding: 9px 13px; font-size: 14.5px; }
  .rate { height: 50px; }
  .ccard { padding: 18px 16px; }
}
