@font-face { font-family: "Geist"; src: url("fonts/geist-normal.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("fonts/geist-mono-normal.woff2") format("woff2"); font-weight: 400 600; font-display: swap; }
:root {
  --ground: #F3F3F1; --s1: #FFFFFF; --s2: #EAEAE6; --s3: #DADAD5; --edge: #D2D2CC;
  --ink: #0C0D0E; --ink2: #4E5358; --ink3: #6E7378;
  --sig: #E8480E; --sig-ink: #FFFFFF; --sig-edge: #B8360A; --sig-dim: rgba(232,72,14,.16); --sig-text: #C23A08;
  --err: #C42B1C;
  --ease-out: cubic-bezier(0.23,1,0.32,1); --drawer: cubic-bezier(0.32,0.72,0,1); --spring: cubic-bezier(0.34,1.5,0.64,1);
  --sans: "Geist", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --tap: 44px;
  --scrim: rgba(12,13,14,.42);
  color-scheme: light;
  --paper: var(--ground); --paper-2: var(--s1);
  --ink-1: var(--ink); --ink-2: var(--ink2); --ink-3: var(--ink3);
  --line: var(--s3); --line-2: var(--s2);
  --green: var(--ink); --green-2: var(--ink); --green-soft: var(--s2);
  --gold: var(--sig); --gold-soft: var(--sig-dim);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #0C0D0E; --s1: #151719; --s2: #1D2023; --s3: #272B2F; --edge: #050606;
    --ink: #EDEEEF; --ink2: #A4A9AE; --ink3: #858B91;
    --sig: #FF5B1F; --sig-ink: #0C0D0E; --sig-edge: #B33A0E; --sig-dim: rgba(255,91,31,.2); --sig-text: #FF7A45;
    --err: #FF8577; --scrim: rgba(0,0,0,.6); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ground: #0C0D0E; --s1: #151719; --s2: #1D2023; --s3: #272B2F; --edge: #050606;
  --ink: #EDEEEF; --ink2: #A4A9AE; --ink3: #858B91;
  --sig: #FF5B1F; --sig-ink: #0C0D0E; --sig-edge: #B33A0E; --sig-dim: rgba(255,91,31,.2); --sig-text: #FF7A45;
  --err: #FF8577; --scrim: rgba(0,0,0,.6); color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--ground); color: var(--ink);
  font-family: var(--sans); font-size: 16px; line-height: 1.5;
  -webkit-text-size-adjust: 100%; -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
a { color: var(--ink); text-decoration-color: var(--sig); text-underline-offset: 3px; text-decoration-thickness: 2px; font-weight: 500; }
:focus-visible { outline: 2px solid var(--sig); outline-offset: 2px; }
button { font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; }
code, kbd, var { font-family: var(--mono); }
var { font-style: italic; }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.press, .card, .row, .next-stop, .reg-mini, .kv-save, .reg-chip, .info, .seg button, .tabs a, .bar-back, .bar-help, .chip {
  transition: transform 140ms var(--ease-out), background-color 160ms ease;
}
.press:active, .card:active, .row:active, .next-stop:active, .reg-mini:active, .kv-save:active, .reg-chip:active,
.info:active, .seg button:active, .tabs a:active, .bar-back:active, .bar-help:active, .chip:active { transform: scale(0.97); }
.btn, .btn-quiet, .ra-act, .alpha button, .reg-toast-open, .sign-btn, input[type="file"]::file-selector-button {
  transition: transform 90ms var(--ease-out), box-shadow 90ms var(--ease-out), background-color 160ms ease, color 160ms ease;
}
#app { max-width: 560px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; position: relative; }
.screen { display: none; padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
.screen.is-active { display: block; animation: enter 220ms var(--ease-out); }
@keyframes enter { from { opacity: 0; transform: translateX(10px); } }
.pad { padding: 0 18px 24px; }
.brand-rail { display: none; }
.homebar { display: flex; align-items: center; justify-content: space-between; height: 56px; padding: calc(env(safe-area-inset-top) + 8px) 18px 0; box-sizing: content-box; }
.word { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 18px; letter-spacing: -0.02em; margin: 0; }
.word svg { width: 30px; height: 30px; border-radius: calc(8px * var(--rk, 1)); flex: none; }
.word svg.wm { width: auto; height: 0.74em; aspect-ratio: 2464 / 630; border-radius: 0 !important; box-shadow: none !important; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .word svg { border-radius: 22.5%; box-shadow: 0 0 0 1.5px #EDEEEF; } }
:root[data-theme="dark"] .word svg { border-radius: 22.5%; box-shadow: 0 0 0 1.5px #EDEEEF; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: var(--tap); padding: 0 14px;
  border: 0; border-radius: 999px; background: var(--s1); color: var(--ink2);
  font-family: var(--mono); font-size: 12px; cursor: pointer;
}
.chip svg { width: 16px; height: 16px; }
.hero { font-size: 36px; line-height: 1.02; letter-spacing: -0.045em; font-weight: 600; margin: 14px 0 10px; max-width: 13ch; }
.lede { font-size: 15px; color: var(--ink2); line-height: 1.45; margin: 0 0 20px; max-width: 40ch; }
.lede b { color: var(--ink); font-weight: 500; }
.resume { display: block; width: 100%; text-align: left; border: 0; cursor: pointer; background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 14px 16px 10px; margin-bottom: 22px; text-decoration: none; color: inherit; font-weight: 400; }
.resume .k { font-size: 13px; color: var(--ink2); display: flex; justify-content: space-between; gap: 12px; }
.resume .v { font-size: 19px; letter-spacing: -0.025em; font-weight: 600; margin-top: 5px; display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.resume .v .num { color: var(--sig-text); font-size: 17px; white-space: nowrap; }
.resume canvas { display: block; width: 100%; height: 46px; margin-top: 4px; }
.grp { font-size: 13px; color: var(--ink2); margin: 0 2px 8px; font-weight: 500; }
.list { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 4px; margin-bottom: 18px; }
.row {
  display: flex; align-items: center; gap: 14px; width: 100%; min-height: 60px; padding: 12px; border-radius: calc(16px * var(--rk, 1));
  border: 0; background: transparent; text-align: left; cursor: pointer; color: inherit; text-decoration: none; font-weight: 400;
}
.row:active { background: var(--s2); }
.row svg.g { flex: none; width: 42px; height: 30px; }
.row .t, .row .d { display: block; }
.row .t { font-size: 16px; font-weight: 500; letter-spacing: -0.015em; line-height: 1.25; }
.row .d { font-family: var(--mono); font-size: 12px; color: var(--ink2); margin-top: 3px; line-height: 1.35; }
.row .go { margin-left: auto; color: var(--ink3); font-size: 22px; line-height: 1; transition: transform 200ms var(--ease-out); padding-left: 6px; }
.row.is-stub .t { color: var(--ink2); }
@media (hover: hover) and (pointer: fine) {
  .row:hover { background: var(--s2); }
  .row:hover .go { transform: translateX(3px); }
}
.about { margin: 26px 2px 8px; font-size: 14px; line-height: 1.6; color: var(--ink2); max-width: 62ch; }
.about p { margin: 0 0 10px; }
.about strong { color: var(--ink); font-weight: 500; }
.muted { color: var(--ink3); font-size: 13px; }
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  max-width: 560px; margin: 0 auto;
  padding: 8px 18px calc(env(safe-area-inset-bottom) + 12px);
  background: var(--ground); display: flex; gap: 6px;
}
.tabs::before { content: ""; position: absolute; left: 0; right: 0; top: -20px; height: 20px; background: linear-gradient(transparent, var(--ground)); pointer-events: none; }
.tabs a {
  flex: 1; height: 54px; border-radius: calc(14px * var(--rk, 1)); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  font-size: 11px; font-weight: 500; color: var(--ink2); text-decoration: none;
}
.tabs a[aria-current="page"] { color: var(--ink); background: var(--s1); }
.tabs svg { width: 20px; height: 20px; }
.tabs .badge { font-family: var(--mono); font-size: 10px; color: var(--sig-text); }
.bar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 8px;
  background: var(--ground);
  padding: calc(8px + env(safe-area-inset-top)) 18px 8px;
}
.bar-back, .bar-help {
  width: var(--tap); height: var(--tap); min-width: var(--tap);
  border: 0; border-radius: calc(14px * var(--rk, 1)); background: var(--s1); color: var(--ink);
  display: grid; place-items: center; cursor: pointer; padding: 0;
}
.bar-back svg { width: 18px; height: 18px; }
.bar-help { font-family: var(--mono); font-size: 16px; font-weight: 600; border-radius: 50%; }
.bar-help-ghost { visibility: hidden; }
.bar-crumb { flex: 1; min-width: 0; font-size: 13px; color: var(--ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-left: 4px; }
.bar-reg {
  min-height: var(--tap); border: 0; border-radius: 999px; background: var(--s1); color: var(--ink2);
  font-family: var(--mono); font-size: 12px; padding: 0 14px; cursor: pointer; white-space: nowrap;
}
.bar-reg:active { transform: scale(0.97); }
.title { font-size: 30px; letter-spacing: -0.04em; font-weight: 600; margin: 6px 18px 16px; line-height: 1.05; }
.section-label { font-size: 13px; font-weight: 500; letter-spacing: 0; color: var(--ink2); margin: 22px 2px 8px; }
.section-label:first-child { margin-top: 4px; }
#sheet-list, #module-list, #tools-list, .class-list { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 4px; margin-bottom: 18px; }
.card {
  display: block; width: 100%; text-align: left; position: relative;
  background: transparent; border: 0; border-radius: calc(16px * var(--rk, 1));
  padding: 14px 44px 14px 14px; margin: 0; cursor: pointer; color: inherit;
}
.card + .card { box-shadow: inset 0 1px 0 var(--s2); }
.card::after { content: "\203A"; position: absolute; right: 16px; top: 50%; transform: translateY(-54%); font-size: 22px; color: var(--ink3); transition: transform 200ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .card:hover { background: var(--s2); } .card:hover::after { transform: translate(3px, -54%); } }
.card-n { font-family: var(--mono); font-size: 12px; color: var(--ink2); }
.card-title { font-weight: 500; font-size: 16px; line-height: 1.25; letter-spacing: -0.015em; margin: 2px 0 3px; }
.card-sub { font-size: 13px; color: var(--ink2); line-height: 1.45; }
.card.is-stub .card-title { color: var(--ink2); }
.pill { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-family: var(--mono); margin-top: 8px; color: var(--ink2); }
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--ink); }
.pill-stub::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--ink3); }
.prompt-card { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 16px 16px 14px; margin-bottom: 10px; }
.prompt-quote { font-weight: 500; font-size: 19px; line-height: 1.3; letter-spacing: -0.02em; margin: 0; }
.prompt-attrib { margin: 8px 0 0; font-size: 13px; color: var(--ink2); }
.rule-note {
  background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 14px 16px 14px 18px;
  font-size: 14px; line-height: 1.5; color: var(--ink2); margin-bottom: 18px;
  box-shadow: inset 3px 0 0 var(--sig);
}
.rule-note strong { display: block; color: var(--ink); font-size: 16px; font-weight: 600; letter-spacing: -0.015em; margin-bottom: 3px; }
.frame-aside { box-shadow: inset 2px 0 0 var(--s3); padding: 2px 0 2px 14px; font-size: 14px; line-height: 1.5; color: var(--ink2); margin: -6px 0 20px; }
.frame-aside p { margin: 0; }
.frame-aside strong { color: var(--ink); font-weight: 500; }
.field { margin-bottom: 14px; }
.field-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; min-height: 28px; }
.field-label { font-size: 14px; font-weight: 500; color: var(--ink); }
.field-label var { font-size: 15px; }
.info {
  position: relative; width: 28px; height: 28px; min-width: 28px; border-radius: 50%; border: 0; padding: 0;
  background: var(--s2); color: var(--ink2); font-family: var(--mono); font-size: 13px; font-weight: 600; cursor: pointer;
  display: grid; place-items: center;
}
.info::after, .kv-save::after, .reg-chip::after, .reg-mini::after { content: ""; position: absolute; inset: -8px; }
input[type="number"], input[type="text"], input[type="email"], select, textarea {
  width: 100%; min-height: 52px; padding: 0 16px;
  font-family: var(--mono); font-size: 18px; font-weight: 500; letter-spacing: -0.02em; color: var(--ink);
  background: var(--s1); border: 0; border-radius: calc(14px * var(--rk, 1));
  box-shadow: inset 0 0 0 1px var(--s3);
  -webkit-appearance: none; appearance: none;
  transition: box-shadow 160ms ease;
}
textarea { padding: 14px 16px; font-size: 16px; line-height: 1.5; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--ink3); }
select {
  font-family: var(--sans); font-size: 16px; padding-right: 38px;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink2) 50%), linear-gradient(135deg, var(--ink2) 50%, transparent 50%);
  background-position: calc(100% - 20px) 23px, calc(100% - 14px) 23px; background-size: 6px 6px, 6px 6px; background-repeat: no-repeat;
}
input:focus, select:focus, textarea:focus { outline: none; box-shadow: inset 0 0 0 2px var(--sig); }
.field-hint { font-size: 13px; color: var(--ink2); margin: 6px 0 0; line-height: 1.45; }
.field-hint code, .rule-note code { background: var(--s2); padding: 1px 5px; border-radius: 5px; font-size: 12px; }
.field-err { font-size: 14px; color: var(--err); margin: 8px 0 0; font-weight: 500; }
.field-err a { color: var(--err); }
input[type="file"] { width: 100%; font: inherit; font-size: 14px; color: var(--ink2); }
input[type="file"]::file-selector-button {
  font: inherit; font-weight: 600; color: var(--ink); background: var(--s1); border: 0; border-radius: calc(12px * var(--rk, 1));
  min-height: var(--tap); padding: 0 16px; margin-right: 12px; cursor: pointer; box-shadow: 0 3px 0 var(--s3);
}
.statement { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 16px 14px 18px; margin: 16px 0 14px; }
.statement-label { font-size: 13px; font-weight: 500; color: var(--ink2); margin-bottom: 12px; }
.stmt-row { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; font-family: var(--mono); font-size: 20px; }
.stmt-row var { font-style: italic; }
select.stmt-op { min-height: 48px; width: auto; min-width: 74px; font-family: var(--mono); font-size: 17px; text-align: center; padding: 0 30px 0 12px; background-position: calc(100% - 17px) 21px, calc(100% - 11px) 21px; }
input.stmt-k { min-height: 48px; width: 66px; text-align: center; font-size: 18px; padding: 0 4px; }
.stmt-tail { flex-basis: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px; }
.stmt-eq { color: var(--ink3); }
.stmt-blank { font-family: var(--mono); color: var(--sig-text); background: var(--sig-dim); border-radius: calc(8px * var(--rk, 1)); padding: 2px 10px; font-size: 18px; }
.seg { display: flex; gap: 4px; background: var(--s2); border-radius: calc(16px * var(--rk, 1)); padding: 4px; margin-bottom: 16px; }
.seg button {
  flex: 1; min-height: var(--tap); border: 0; border-radius: calc(12px * var(--rk, 1)); background: transparent;
  font-size: 14px; font-weight: 500; color: var(--ink2); cursor: pointer; padding: 0 8px; line-height: 1.25;
}
.seg button[aria-pressed="true"] { background: var(--s1); color: var(--ink); box-shadow: 0 2px 0 var(--s3); }
.seg button[data-variant] { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.seg button[data-variant]::before { content: ""; width: 10px; height: 10px; border-radius: 50%; flex: none; box-shadow: inset 0 0 0 1.5px var(--ink3); }
.seg button[data-variant][aria-pressed="true"]::before { background: var(--sig); box-shadow: none; }
.seg-stack { flex-direction: column; }
.seg-stack button { display: block; text-align: left; padding: 10px 12px; }
.seg-sub { display: block; font-family: var(--mono); font-size: 12px; font-weight: 400; color: var(--ink2); margin-top: 3px; }
.pair { display: grid; grid-template-columns: 1fr; gap: 0 12px; }
@media (min-width: 380px) { .pair { grid-template-columns: 1fr 1fr; } }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
@media (max-width: 380px) { .grid2 { grid-template-columns: 1fr; } }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0 10px; }
@media (max-width: 420px) { .grid3 { grid-template-columns: 1fr; } }
.grid2 .section-label, .grid3 .section-label { margin-top: 6px; }
.signed { display: flex; gap: 8px; align-items: stretch; }
.signed input { flex: 1; min-width: 0; }
.sign-btn {
  flex: 0 0 60px; border: 0; border-radius: calc(14px * var(--rk, 1)); background: var(--s1); color: var(--ink);
  font-family: var(--mono); font-size: 17px; font-weight: 600; cursor: pointer; box-shadow: 0 3px 0 var(--s3); margin-bottom: 3px;
}
.sign-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--s3); }
.base-row { display: flex; align-items: center; gap: 8px; }
.base-row input { flex: 1; min-width: 0; }
.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 54px; margin: 6px 0 4px; padding: 0 18px;
  border: 0; border-radius: calc(16px * var(--rk, 1)); background: var(--sig); color: var(--sig-ink);
  font-size: 16px; font-weight: 600; letter-spacing: -0.01em; cursor: pointer;
  box-shadow: 0 4px 0 var(--sig-edge);
}
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--sig-edge); }
.btn:disabled { opacity: .45; cursor: default; transform: none; box-shadow: 0 4px 0 var(--sig-edge); }
.btn-quiet {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: auto; min-height: 48px; padding: 0 18px; margin: 12px 0 4px;
  border: 0; border-radius: calc(14px * var(--rk, 1)); background: var(--s1); color: var(--ink);
  font-size: 15px; font-weight: 500; cursor: pointer; box-shadow: 0 4px 0 var(--s3); text-decoration: none;
}
.btn-quiet:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--s3); }
.result { margin-top: 18px; scroll-margin-top: 76px; display: flex; flex-direction: column; gap: 10px; }
.result-answer { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 16px; }
.result-answer .ra-label { font-size: 13px; color: var(--ink2); font-weight: 500; }
.result-answer .ra-value {
  font-family: var(--mono); font-weight: 500; font-size: 40px; line-height: 1.05; letter-spacing: -0.04em;
  margin-top: 6px; color: var(--ink); word-break: break-word; max-width: 100%;
}
.result-answer .ra-alt { font-size: 13px; color: var(--ink2); margin-top: 8px; line-height: 1.45; }
.ra-actions { display: flex; gap: 8px; margin-top: 14px; }
.ra-act {
  flex: 1; min-height: 48px; border: 0; border-radius: calc(14px * var(--rk, 1)); background: var(--s2); color: var(--ink);
  font-size: 14px; font-weight: 600; cursor: pointer; box-shadow: 0 4px 0 var(--s3); margin-bottom: 4px;
}
.ra-act:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--s3); }
.ra-act[data-save] { background: var(--sig); color: var(--sig-ink); box-shadow: 0 4px 0 var(--sig-edge); }
.ra-act[data-save]:active { box-shadow: 0 1px 0 var(--sig-edge); }
.ra-act:disabled { opacity: .75; }
.result-block { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 14px 16px; }
.rb-label { font-size: 13px; font-weight: 500; color: var(--ink2); margin-bottom: 6px; }
.kv { display: flex; justify-content: space-between; align-items: center; gap: 14px; font-size: 14px; padding: 9px 0; margin: 0; box-shadow: inset 0 -1px 0 var(--s2); }
.kv:last-child { box-shadow: none; }
.kv dt { color: var(--ink2); flex: 1 1 50%; min-width: 9ch; }
.kv dd { margin: 0; font-family: var(--mono); font-size: 15px; font-weight: 500; letter-spacing: -0.02em; color: var(--ink); display: flex; align-items: center; justify-content: flex-end; gap: 8px; flex-wrap: wrap; text-align: right; overflow-wrap: anywhere; }
.kv-save, .reg-chip, .reg-mini {
  position: relative; min-height: 30px; border: 0; border-radius: 999px; background: var(--s2); color: var(--ink2);
  font-family: var(--sans); font-size: 12px; font-weight: 500; padding: 0 11px; cursor: pointer; flex: none; letter-spacing: 0;
}
.kv-save:disabled { opacity: .75; }
.reg-chip { margin-left: auto; }
.kv-block { margin-top: 10px; }
.formula {
  font-family: var(--mono); font-size: 13px; line-height: 1.65; color: var(--ink);
  background: var(--s2); border-radius: calc(14px * var(--rk, 1)); padding: 12px 14px; overflow-x: auto; white-space: pre;
}
.arith > summary { list-style: none; cursor: pointer; min-height: var(--tap); display: flex; align-items: center; justify-content: space-between; font-size: 13px; font-weight: 500; color: var(--ink2); }
.arith > summary::-webkit-details-marker { display: none; }
.arith > summary::after { content: "+"; font-family: var(--mono); font-size: 18px; color: var(--ink3); }
.arith[open] > summary::after { content: "\2212"; }
.reading { font-size: 15px; line-height: 1.55; color: var(--ink); margin: 0; max-width: 62ch; }
.reading + .reading { margin-top: 10px; }
.reading strong { font-weight: 600; }
.reading-judgment { font-size: 14px; line-height: 1.55; color: var(--ink2); margin: 14px 0 0; padding-left: 12px; box-shadow: inset 2px 0 0 var(--sig); }
.work { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 4px 16px; }
.step { display: grid; grid-template-columns: 72px minmax(0, 1fr) 108px; align-items: center; gap: 8px; padding: 12px 0; box-shadow: inset 0 -1px 0 var(--s2); }
.step:last-child { box-shadow: none; }
.step .lab { font-size: 12px; color: var(--ink2); line-height: 1.3; }
.work.sums .step .lab { font-size: 14px; font-weight: 400; color: var(--ink2); }
.step .math { font-family: var(--mono); font-size: 15px; letter-spacing: -0.02em; line-height: 1.3; overflow-wrap: anywhere; }
.step .note { font-size: 12px; line-height: 1.3; color: var(--sig-text); font-weight: 500; padding-left: 10px; box-shadow: inset 2px 0 0 var(--sig-dim); }
.step.big .math { font-size: 19px; font-weight: 500; }
.step.p .math { color: var(--sig-text); }
.work.reveal .step .math { clip-path: inset(0 100% 0 0); }
.work.reveal .step .note { opacity: 0; transform: translateX(-4px); }
.work.reveal .step.in .math { clip-path: inset(0 0 0 0); transition: clip-path 520ms cubic-bezier(.5,0,.2,1); }
.work.reveal .step.in .note { opacity: 1; transform: none; transition: opacity 240ms ease 320ms, transform 320ms var(--ease-out) 320ms; }
@media (max-width: 380px) {
  .step { grid-template-columns: 64px minmax(0, 1fr); }
  .step .note { grid-column: 2; padding-left: 10px; }
}
.plot { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 14px 14px 12px; }
.plot canvas { display: block; width: 100%; height: 140px; }
.plot .cap { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; color: var(--ink2); margin-top: 6px; }
.alpha { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.alpha button {
  min-height: 50px; border: 0; border-radius: calc(14px * var(--rk, 1)); background: var(--s2); color: var(--ink2); cursor: pointer;
  font-family: var(--mono); font-size: 14px; text-align: center; box-shadow: 0 4px 0 var(--s3); margin-bottom: 4px; line-height: 1.2;
}
.alpha button small { display: block; font-family: var(--sans); font-size: 11px; color: var(--ink2); margin-top: 1px; }
.alpha button[aria-pressed="true"] { background: var(--ink); color: var(--ground); box-shadow: 0 4px 0 #000; }
.alpha button[aria-pressed="true"] small { color: var(--ground); opacity: .7; }
.alpha button:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--s3); }
.verdict { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 16px; }
.verdict .vh { font-size: 18px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.25; transition: filter 200ms ease, opacity 200ms ease; }
.verdict .vs { font-size: 14px; color: var(--ink2); margin-top: 6px; line-height: 1.45; }
.verdict.swap .vh { filter: blur(3px); opacity: .3; }
.vdot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 9px; vertical-align: 1px; background: var(--ink3); }
.vdot.sig { background: var(--sig); }
.yours { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 16px; }
.yours .l { font-size: 13px; color: var(--ink2); margin-bottom: 8px; font-weight: 500; }
.yours .w { font-size: 16px; line-height: 1.5; color: var(--ink2); }
.yours .w b { color: var(--ink); font-weight: 600; }
.caret { display: inline-block; width: 2px; height: 1em; background: var(--sig); vertical-align: -2px; animation: caret 1s steps(1) infinite; }
@keyframes caret { 50% { opacity: 0; } }
.tablewrap { overflow-x: auto; margin-top: 4px; }
table.dist { width: 100%; border-collapse: collapse; font-family: var(--mono); font-size: 14px; font-variant-numeric: tabular-nums; }
table.dist th { text-align: left; font-family: var(--sans); font-size: 12px; font-weight: 500; color: var(--ink2); padding: 8px; box-shadow: inset 0 -1px 0 var(--s3); }
table.dist tbody th { box-shadow: inset 0 -1px 0 var(--s2); }
table.dist td { padding: 8px; box-shadow: inset 0 -1px 0 var(--s2); }
table.dist td:first-child { font-family: var(--sans); }
table.dist tr.hit td, table.dist td.hit { background: var(--sig-dim); color: var(--ink); font-weight: 600; }
table.dist tr.hit td:first-child { box-shadow: inset 3px 0 0 var(--sig); }
table.dist tr.given td { background: var(--s2); color: var(--ink2); }
table.dist td.cond-mark { font-family: var(--sans); font-size: 12px; color: var(--ink2); white-space: nowrap; }
table.dist tr.hit td.cond-mark { color: var(--ink); }
table.dist td .exp { display: block; font-family: var(--sans); font-size: 11px; color: var(--ink2); margin-top: 2px; font-weight: 400; }
table.twoby th { white-space: nowrap; }
table.anova-solved td.anova-todo { color: var(--ink3); text-align: center; }
table.anova-solved td.anova-derived { background: var(--sig-dim); }
.rand-table { max-height: 320px; overflow-y: auto; margin-bottom: 12px; }
.curvewrap { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 12px 10px 8px; margin-bottom: 14px; touch-action: none; user-select: none; -webkit-user-select: none; }
.curvewrap svg { display: block; width: 100%; height: auto; }
.curvewrap svg text, .chart text { font-family: var(--mono); }
.curvewrap svg path[stroke="var(--ink-2)"] { stroke: var(--ink); stroke-width: 2.2; }
.curvewrap svg line[stroke="var(--green-2)"] { stroke: var(--sig); stroke-width: 2.5; }
.curvewrap svg circle[fill="var(--green-2)"] { fill: var(--sig); stroke: var(--s1); stroke-width: 3; }
.curve-hint { text-align: center; font-size: 13px; color: var(--ink2); margin: 4px 0 0; }
.chart { width: 100%; height: auto; display: block; margin: 6px 0 4px; }
.chart .ct { font-size: 10px; fill: var(--ink2); }
.chart rect[fill="var(--green-2)"] { fill: var(--ink); opacity: .85; }
.chart circle[fill="var(--green-2)"] { fill: var(--ink); }
.chart line[stroke="var(--gold)"] { stroke: var(--sig); stroke-width: 2.5; }
.chart rect[fill="var(--green-soft)"] { fill: var(--sig-dim); stroke: var(--sig); }
.chart line[stroke="var(--green)"] { stroke: var(--sig); stroke-width: 2.5; }
.data-banner { background: var(--s1); border-radius: calc(16px * var(--rk, 1)); padding: 12px 14px 12px 16px; margin: 0 0 16px; font-size: 14px; line-height: 1.5; color: var(--ink2); box-shadow: inset 3px 0 0 var(--ink); }
.data-banner strong { color: var(--ink); font-weight: 600; }
.data-banner.is-empty { box-shadow: inset 3px 0 0 var(--sig); }
.readout { background: var(--s1); border-radius: calc(14px * var(--rk, 1)); padding: 10px 12px; margin: -4px 0 16px; font-size: 14px; line-height: 1.55; color: var(--ink2); }
.dist-bar { display: flex; align-items: center; gap: 12px; background: var(--s1); border-radius: calc(18px * var(--rk, 1)); padding: 10px 12px 10px 16px; margin-bottom: 16px; }
.dist-bar-text { flex: 1; min-width: 0; }
.dist-bar-label { display: block; font-size: 12px; color: var(--ink2); margin-bottom: 2px; }
.dist-bar-value { display: block; font-size: 15px; font-weight: 600; color: var(--ink); line-height: 1.35; }
.dist-bar .btn-quiet { margin: 0; flex: 0 0 auto; }
.ftest { background: var(--s1); border-radius: calc(22px * var(--rk, 1)); padding: 14px 16px; margin: 16px 0 0; }
.ftest p { margin: 8px 0 0; font-size: 14px; color: var(--ink2); line-height: 1.5; }
.ftest strong { color: var(--ink); font-weight: 600; }
.secalc { background: var(--s1); border-radius: calc(18px * var(--rk, 1)); padding: 4px 14px; margin: 8px 0 16px; }
.secalc summary { cursor: pointer; min-height: var(--tap); display: flex; align-items: center; font-weight: 500; }
.secalc-out { font-family: var(--mono); font-size: 15px; margin: 10px 0; }
.rescard-lite { background: var(--s1); border-radius: calc(18px * var(--rk, 1)); padding: 14px 16px; margin-top: 12px; box-shadow: inset 3px 0 0 var(--err); }
.rescard-lite ul { margin: 6px 0 10px; padding-left: 20px; }
.next-stops { display: grid; gap: 6px; margin-top: 12px; }
.next-stop { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; min-height: var(--tap); padding: 12px 14px; background: var(--s2); border-radius: calc(14px * var(--rk, 1)); text-decoration: none; }
.next-stop .ns-name { font-size: 15px; font-weight: 600; color: var(--ink); }
.next-stop .ns-when { font-size: 13px; color: var(--ink2); font-weight: 400; }
.cond-event { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 16px 14px 18px; margin: 0 0 14px; }
.cond-event-head { font-size: 17px; font-weight: 600; letter-spacing: -0.015em; margin-bottom: 4px; }
.cond-event-blurb { font-size: 14px; line-height: 1.45; color: var(--ink2); margin: 0 0 12px; }
.cond-event .stmt-row { margin-top: 12px; }
.reg-list { list-style: none; margin: 12px 0 0; padding: 0; }
.reg-list li { background: var(--s1); border-radius: calc(18px * var(--rk, 1)); padding: 12px 14px; margin-bottom: 8px; }
.drawer .reg-list li { background: var(--s2); }
.reg-row { display: block; }
.reg-val { display: block; font-family: var(--mono); font-size: 20px; font-weight: 500; letter-spacing: -0.03em; color: var(--ink); }
.reg-name { display: block; font-size: 14px; color: var(--ink2); margin-top: 2px; }
.reg-from { display: block; font-size: 12px; color: var(--ink2); margin-top: 2px; font-family: var(--mono); }
.reg-row-acts { display: flex; gap: 6px; align-items: center; margin-top: 10px; flex-wrap: wrap; }
.reg-mini { min-height: 34px; background: var(--s2); }
.drawer .reg-mini { background: var(--s1); }
.reg-mini-go { background: var(--sig) !important; color: var(--sig-ink); }
.reg-rename-input { flex: 1 1 100%; min-height: 44px; font-family: var(--sans); font-size: 15px; letter-spacing: 0; }
.reg-row-acts.is-renaming .reg-rename-input { margin-bottom: 6px; }
.stub-flag { display: inline-flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: 12px; color: var(--ink2); margin-bottom: 12px; }
.stub-flag::before { content: ""; width: 8px; height: 8px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--ink3); }
.stub-lead { font-weight: 600; font-size: 22px; letter-spacing: -0.03em; line-height: 1.2; margin: 0 0 14px; }
.stub-list { margin: 0; padding: 14px 16px 14px 34px; font-size: 15px; line-height: 1.6; color: var(--ink); background: var(--s1); border-radius: calc(20px * var(--rk, 1)); }
.stub-list li { margin-bottom: 5px; }
.stub-note { margin-top: 16px; font-size: 14px; line-height: 1.55; color: var(--ink2); }
.sess-fresh-wrap { margin: 28px 0 8px; }
.sess-note { display: block; margin-top: 10px; font-size: 13px; line-height: 1.5; color: var(--ink2); }
.scrim { position: fixed; inset: 0; background: var(--scrim); z-index: 40; animation: fadein 200ms ease-out; }
@keyframes fadein { from { opacity: 0; } }
.drawer {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; max-width: 560px; margin: 0 auto;
  max-height: 86vh; max-height: 86dvh; background: var(--s1); border-radius: 26px 26px 0 0;
  box-shadow: 0 -12px 40px rgba(0,0,0,.18); display: flex; flex-direction: column;
  animation: sheetup 320ms var(--drawer);
}
@keyframes sheetup { from { transform: translateY(100%); } }
.drawer-grab { width: 40px; height: 5px; border-radius: 99px; background: var(--s3); margin: 8px auto 0; }
.drawer-head { display: flex; align-items: center; gap: 8px; padding: 8px 8px 8px 20px; }
.drawer-head h2 { flex: 1; margin: 0; font-size: 20px; font-weight: 600; letter-spacing: -0.03em; }
.drawer-close { width: var(--tap); height: var(--tap); border: 0; border-radius: 50%; background: var(--s2); color: var(--ink); font-size: 22px; line-height: 1; cursor: pointer; margin-right: 6px; }
.drawer-body { overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 6px 20px calc(28px + env(safe-area-inset-bottom)); font-size: 15px; line-height: 1.6; }
.drawer-body h3 { font-size: 15px; font-weight: 600; margin: 20px 0 6px; letter-spacing: -0.01em; }
.drawer-body h3:first-child { margin-top: 4px; }
.drawer-body p { margin: 0 0 11px; }
.drawer-body ul { margin: 0 0 11px; padding-left: 20px; }
.drawer-body li { margin-bottom: 5px; }
.drawer-body code { font-size: 13px; background: var(--s2); padding: 1px 6px; border-radius: 6px; }
.worked { background: var(--s2); border-radius: calc(16px * var(--rk, 1)); padding: 14px 16px; font-size: 14px; line-height: 1.55; box-shadow: inset 3px 0 0 var(--sig); }
.worked p { margin: 0 0 8px; }
.worked p:last-child { margin: 0; }
.drawer .worked code { background: var(--s1); }
.reg-toast {
  position: fixed; left: 50%; bottom: calc(86px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  z-index: 60; display: flex; align-items: center; gap: 12px;
  background: var(--ink); color: var(--ground); border-radius: calc(16px * var(--rk, 1)); padding: 8px 8px 8px 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25); font-size: 14px; width: max-content; max-width: calc(100vw - 32px);
  animation: toastin 260ms var(--ease-out);
}
@keyframes toastin { from { opacity: 0; transform: translate(-50%, 8px); } }
.reg-toast-open { min-height: 40px; border: 0; border-radius: calc(12px * var(--rk, 1)); background: var(--sig); color: var(--sig-ink); font-size: 14px; font-weight: 600; padding: 0 16px; cursor: pointer; }
.rand-seq { font-size: 20px !important; line-height: 1.4 !important; letter-spacing: -0.02em; }
.rand-flips { font-family: var(--mono); font-size: 13px; color: var(--ink2); line-height: 1.6; word-break: break-word; margin: 12px 0; }
.fb-boxes { display: grid; grid-template-columns: 1fr; gap: 6px; }
@media (min-width: 520px) { .fb-boxes { grid-template-columns: 1fr 1fr; } }
.fb-box { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 10px 14px; border-radius: calc(14px * var(--rk, 1)); background: var(--s1); font-size: 15px; cursor: pointer; transition: background-color 160ms ease; }
.fb-box input { width: 20px; height: 20px; margin: 0; accent-color: var(--sig); flex: 0 0 auto; }
.fb-box:has(input:checked) { background: var(--sig-dim); }
.qr-card { padding: 18px; text-align: center; background: #FFFFFF; border-radius: calc(22px * var(--rk, 1)); }
.qr-box { width: min(100%, 320px); margin: 0 auto; background: #FFFFFF; }
.qr-box svg { display: block; width: 100%; height: auto; }
.qr-caption { font-family: var(--mono); font-size: 15px; color: #0C0D0E; margin: 12px 0 4px; word-break: break-word; }
.qr-card .field-hint { color: #4E5358; }
.sh-two { margin: 0 0 16px; background: var(--s1); border-radius: calc(18px * var(--rk, 1)); padding: 0 14px; }
.sh-two[open] { padding-bottom: 4px; }
.sh-two summary { cursor: pointer; font-weight: 500; min-height: var(--tap); display: flex; align-items: center; }
.stage { position: relative; height: 188px; border-radius: calc(22px * var(--rk, 1)); background: var(--s1); overflow: hidden; }
.stage canvas.gl { position: absolute; left: 0; top: 0; width: 46%; height: 100%; }
.stage .coin2d { position: absolute; left: 0; top: 0; width: 46%; height: 100%; display: grid; place-items: center; }
.stage .coin2d i { width: 92px; height: 92px; border-radius: 50%; background: var(--sig); display: grid; place-items: center; font-style: normal; font-family: var(--sans); font-weight: 700; font-size: 42px; color: #0C0D0E; box-shadow: inset 0 0 0 7px rgba(0,0,0,.14); }
.tally { position: absolute; right: 14px; top: 14px; bottom: 14px; left: 46%; display: flex; flex-direction: column; justify-content: center; gap: 12px; }
.tally .hd { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; color: var(--ink2); margin-bottom: 5px; }
.tally .hd b { font-family: var(--mono); font-size: 24px; color: var(--ink); font-weight: 500; letter-spacing: -0.03em; }
.dots { display: grid; grid-template-columns: repeat(13, 1fr); gap: 3px; }
.dots i { aspect-ratio: 1; border-radius: 50%; background: var(--s2); transition: background-color 120ms ease, transform 240ms var(--spring); }
.dots i.on { background: var(--ink); }
.dots.h i.on { background: var(--sig); }
.flipN { position: absolute; left: 14px; top: 12px; font-family: var(--mono); font-size: 12px; color: var(--ink2); }
.unitN { position: absolute; left: 14px; bottom: 12px; font-family: var(--mono); font-size: 11px; color: var(--ink2); }
.collect-cam { position: relative; width: 100%; margin: 0 0 12px; border-radius: calc(24px * var(--rk, 1)); overflow: hidden; background: #07080A; aspect-ratio: 4 / 3.4; }
.collect-cam video { width: 100%; height: 100%; object-fit: cover; display: block; }
.collect-aim { position: absolute; inset: 0; pointer-events: none; transition: transform 300ms var(--spring); }
.collect-cam.hit .collect-aim { transform: scale(0.92); }
.collect-aim i { position: absolute; width: 30px; height: 30px; border: 3px solid #FF5B1F; }
.collect-aim .c1 { top: 18%; left: 22%; border-right: 0; border-bottom: 0; border-radius: calc(10px * var(--rk, 1)) 0 0 0; }
.collect-aim .c2 { top: 18%; right: 22%; border-left: 0; border-bottom: 0; border-radius: 0 10px 0 0; }
.collect-aim .c3 { bottom: 18%; left: 22%; border-right: 0; border-top: 0; border-radius: 0 0 0 10px; }
.collect-aim .c4 { bottom: 18%; right: 22%; border-left: 0; border-top: 0; border-radius: 0 0 10px 0; }
.collect-cam .tag { position: absolute; left: 14px; right: 14px; bottom: 12px; display: flex; justify-content: space-between; gap: 10px; font-size: 13px; color: #EDEEEF; }
.collect-cam .live { display: flex; align-items: center; gap: 7px; }
.collect-cam .live i { width: 8px; height: 8px; border-radius: 50%; background: #FF5B1F; animation: blink 1.6s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .25; } }
.collect-status { min-height: 1.4em; font-weight: 500; color: var(--ink); margin: 4px 2px 12px; }
.count { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 4px 2px 10px; }
.count .big { font-family: var(--mono); font-size: 46px; letter-spacing: -0.05em; line-height: 1; }
.count .k { font-size: 13px; color: var(--ink2); text-align: right; line-height: 1.4; }
.ticks { display: grid; grid-template-columns: repeat(24, 1fr); gap: 3px; margin-bottom: 14px; }
.ticks i { height: 16px; border-radius: 3px; background: var(--s2); transition: background-color 300ms ease, transform 300ms var(--spring); }
.ticks i.on { background: var(--sig); }
.ticks i.pop { transform: scaleY(1.4); }
.crowd { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.crowd span { min-height: 38px; padding: 0 12px 0 4px; border-radius: 999px; background: var(--s1); display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; }
.crowd span i { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 11px; font-weight: 600; background: var(--s2); color: var(--ink); }
.crowd span em { font-style: normal; font-family: var(--mono); font-size: 12px; color: var(--ink2); }
.crowd span.new i { background: var(--sig); color: var(--sig-ink); }
.crowd span.new { animation: popin 520ms var(--spring); }
@keyframes popin { from { transform: scale(.7); opacity: 0; } }
.collect-photo { display: flex !important; margin: 10px 0 16px; cursor: pointer; }
.collect-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.collect-acts .btn-quiet { flex: 1; margin-top: 4px; }
.stagger > * { animation: rise 420ms var(--ease-out) both; }
.stagger > *:nth-child(2) { animation-delay: 40ms; } .stagger > *:nth-child(3) { animation-delay: 80ms; }
.stagger > *:nth-child(4) { animation-delay: 120ms; } .stagger > *:nth-child(5) { animation-delay: 160ms; }
.stagger > *:nth-child(6) { animation-delay: 200ms; } .stagger > *:nth-child(7) { animation-delay: 240ms; }
.stagger > *:nth-child(n+8) { animation-delay: 280ms; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
.result > * { animation: rise 360ms var(--ease-out) both; }
.result > *:nth-child(2) { animation-delay: 50ms; } .result > *:nth-child(3) { animation-delay: 100ms; }
.result > *:nth-child(4) { animation-delay: 150ms; } .result > *:nth-child(n+5) { animation-delay: 200ms; }
.result.quiet > * { animation: none; }
@media (min-width: 1100px) {
  .brand-rail {
    display: flex; flex-direction: column; position: fixed; top: 0; bottom: 0; left: 0; width: 400px;
    background: var(--s1); padding: 44px 44px 40px;
  }
  .rail-lockup svg { width: 190px; height: auto; display: block; }
  .rail-line { font-size: 38px; font-weight: 600; line-height: 1.04; letter-spacing: -0.045em; margin: auto 0 0; max-width: 11ch; }
  .rail-line span { color: var(--sig-text); }
  .rail-note { color: var(--ink2); font-size: 15px; line-height: 1.55; margin: 18px 0 0; max-width: 32ch; }
  .rail-glyph { width: 100%; height: 120px; margin-top: 28px; }
  #app { margin-left: calc(400px + (100vw - 400px - 560px) / 2); margin-right: 0; }
  .tabs, .drawer { left: calc(400px + (100vw - 400px - 560px) / 2); right: auto; width: 560px; margin: 0; }
  .reg-toast { left: calc(400px + (100vw - 400px) / 2); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-delay: 0ms !important; transition-duration: 1ms !important; transition-delay: 0ms !important; }
  .caret, .collect-cam .live i { animation: none !important; }
}
#out > .stage { margin-top: 18px; }
#out > .stage + .result { margin-top: 10px; }
input::placeholder, textarea::placeholder { font-family: var(--sans); font-size: 15px; letter-spacing: 0; }
input[type="text"], input[type="email"] { font-family: var(--sans); font-size: 17px; letter-spacing: -0.01em; }
@font-face { font-family: "Fraunces"; src: url("fonts/fraunces-normal.woff2") format("woff2"); font-weight: 400 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url("fonts/fraunces-italic.woff2") format("woff2"); font-weight: 400 700; font-style: italic; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-normal.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Archivo"; src: url("fonts/archivo-normal.woff2") format("woff2"); font-weight: 400 900; font-stretch: 62% 125%; font-display: swap; }
:root[data-skin="a"] {
  --ground: #F3F3F1; --s1: #FFFFFF; --s2: #EAEAE7; --s3: #DCDCD8; --edge: #CFCFCA;
  --ink: #0C0D0E; --ink2: #50555A; --ink3: #6E7378;
  --sig: #E8480E; --sig-ink: #FFFFFF; --sig-edge: #B8360A; --sig-dim: rgba(232,72,14,.15); --sig-text: #C23A08;
  --err: #C42B1C; --rk: 0.7; --spring: var(--ease-out);
}
@media (prefers-color-scheme: dark) {
  :root[data-skin="a"]:not([data-theme="light"]) {
    --ground: #0C0D0E; --s1: #141618; --s2: #1B1E21; --s3: #24282C; --edge: #050606;
    --ink: #EDEEEF; --ink2: #A4A9AE; --ink3: #858B91;
    --sig: #FF5B1F; --sig-ink: #0C0D0E; --sig-edge: #B33A0E; --sig-dim: rgba(255,91,31,.2); --sig-text: #FF7A45; --err: #FF8577;
  }
}
:root[data-skin="a"][data-theme="dark"] {
  --ground: #0C0D0E; --s1: #141618; --s2: #1B1E21; --s3: #24282C; --edge: #050606;
  --ink: #EDEEEF; --ink2: #A4A9AE; --ink3: #858B91;
  --sig: #FF5B1F; --sig-ink: #0C0D0E; --sig-edge: #B33A0E; --sig-dim: rgba(255,91,31,.2); --sig-text: #FF7A45; --err: #FF8577;
}
:root[data-skin="a"] .hero, :root[data-skin="a"] .title { letter-spacing: -0.05em; }
:root[data-skin="b"] {
  --ground: #F6F5F1; --s1: #FFFFFF; --s2: #EDEBE4; --s3: #E0DDD3; --edge: #D3CFC3;
  --ink: #15203B; --ink2: #4A5470; --ink3: #656D84;
  --sig: #D3392A; --sig-ink: #FFFFFF; --sig-edge: #A82A1E; --sig-dim: rgba(211,57,42,.13); --sig-text: #B32A1D;
  --err: #A8261B; --grid: rgba(21,32,59,.06);
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Fraunces", Georgia, serif;
  --rk: 0.28; --spring: cubic-bezier(.5,0,.2,1); --ease-out: cubic-bezier(.6,0,.3,1);
}
@media (prefers-color-scheme: dark) {
  :root[data-skin="b"]:not([data-theme="light"]) {
    --ground: #10172A; --s1: #18213A; --s2: #1F2944; --s3: #2A3552; --edge: #0A0F1D;
    --ink: #EEEADF; --ink2: #B7B9C2; --ink3: #8C92A5;
    --sig: #FF7A5C; --sig-ink: #10172A; --sig-edge: #C9563D; --sig-dim: rgba(255,122,92,.18); --sig-text: #FF8C70;
    --err: #FF8577; --grid: rgba(238,234,223,.05);
  }
}
:root[data-skin="b"][data-theme="dark"] {
  --ground: #10172A; --s1: #18213A; --s2: #1F2944; --s3: #2A3552; --edge: #0A0F1D;
  --ink: #EEEADF; --ink2: #B7B9C2; --ink3: #8C92A5;
  --sig: #FF7A5C; --sig-ink: #10172A; --sig-edge: #C9563D; --sig-dim: rgba(255,122,92,.18); --sig-text: #FF8C70;
  --err: #FF8577; --grid: rgba(238,234,223,.05);
}
:root[data-skin="b"] body {
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 24px 24px;
}
:root[data-skin="b"] .hero, :root[data-skin="b"] .title, :root[data-skin="b"] .rule-note strong,
:root[data-skin="b"] .prompt-quote, :root[data-skin="b"] .row .t, :root[data-skin="b"] .rail-line {
  font-family: "Fraunces", Georgia, serif; font-weight: 560; letter-spacing: -0.02em;
}
:root[data-skin="b"] .num, :root[data-skin="b"] .ra-value { font-variant-numeric: tabular-nums lining-nums; letter-spacing: 0; }
:root[data-skin="b"] .reading-judgment, :root[data-skin="b"] .step .note { font-family: "Fraunces", Georgia, serif; font-style: italic; }
:root[data-skin="c"] {
  --ground: #F1F1EE; --s1: #FFFFFF; --s2: #E8E8E3; --s3: #D6D6CF; --edge: #0B1020;
  --ink: #0B1020; --ink2: #4B5064; --ink3: #5E6378;
  --sig: #1F45FF; --sig-ink: #FFFFFF; --sig-edge: #1230C4; --sig-dim: rgba(31,69,255,.13); --sig-text: #1F45FF;
  --err: #D63A1A;
  --sans: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Archivo", ui-monospace, monospace;
  --rk: 1.2; --spring: cubic-bezier(0.34,1.56,0.64,1);
}
@media (prefers-color-scheme: dark) {
  :root[data-skin="c"]:not([data-theme="light"]) {
    --ground: #0B1020; --s1: #151B31; --s2: #1D2441; --s3: #2A3256; --edge: #000000;
    --ink: #F4F4F0; --ink2: #B5B9C8; --ink3: #8D92A6;
    --sig: #C6F135; --sig-ink: #0B1020; --sig-edge: #98BE14; --sig-dim: rgba(198,241,53,.16); --sig-text: #C6F135;
    --err: #FF8A6E;
  }
}
:root[data-skin="c"][data-theme="dark"] {
  --ground: #0B1020; --s1: #151B31; --s2: #1D2441; --s3: #2A3256; --edge: #000000;
  --ink: #F4F4F0; --ink2: #B5B9C8; --ink3: #8D92A6;
  --sig: #C6F135; --sig-ink: #0B1020; --sig-edge: #98BE14; --sig-dim: rgba(198,241,53,.16); --sig-text: #C6F135;
  --err: #FF8A6E;
}
:root[data-skin="c"] .hero, :root[data-skin="c"] .title, :root[data-skin="c"] .rail-line {
  font-weight: 900; font-stretch: 125%; letter-spacing: -0.02em;
}
:root[data-skin="c"] .num, :root[data-skin="c"] .ra-value { font-variant-numeric: tabular-nums; letter-spacing: 0; }
:root[data-skin="c"] .list, :root[data-skin="c"] #sheet-list, :root[data-skin="c"] #module-list,
:root[data-skin="c"] #tools-list, :root[data-skin="c"] .result-answer { box-shadow: 0 4px 0 var(--s3); }
:root[data-skin="c"] .row:active, :root[data-skin="c"] .card:active { transform: scale(0.95); transition-timing-function: var(--spring); }
.homebar-r { display: flex; gap: 8px; align-items: center; }
.chip.gear { padding: 0 12px; text-decoration: none; font-weight: 400; }
.set-group { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 6px 16px; margin-bottom: 18px; }
.set-row { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 10px 0; }
.set-row + .set-row { box-shadow: inset 0 1px 0 var(--s2); }
.set-row .set-t { display: block; font-size: 16px; font-weight: 500; letter-spacing: -0.015em; }
.set-row .set-d { display: block; font-size: 13px; color: var(--ink2); margin-top: 2px; line-height: 1.45; }
.set-row > span { flex: 1; }
.tag-preview { display: inline-block; font-family: var(--mono); font-size: 11px; font-weight: 500; color: var(--sig-text); background: var(--sig-dim); border-radius: 999px; padding: 2px 8px; margin-left: 6px; vertical-align: 2px; }
.switch { position: relative; flex: none; width: 52px; height: 32px; border-radius: 999px; border: 0; background: var(--s3); cursor: pointer; transition: background-color 180ms var(--ease-out); }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%; background: #FFFFFF; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform 220ms var(--spring); }
.switch[aria-checked="true"] { background: var(--sig); }
.switch[aria-checked="true"]::after { transform: translateX(20px); }
.skins { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
.skin-card { border: 0; text-align: left; cursor: pointer; background: var(--s1); color: var(--ink); border-radius: calc(18px * var(--rk, 1)); padding: 12px; box-shadow: inset 0 0 0 1.5px var(--s2); transition: transform 140ms var(--ease-out), box-shadow 160ms ease; font: inherit; }
.skin-card:active { transform: scale(0.97); }
.skin-card[aria-pressed="true"] { box-shadow: inset 0 0 0 2.5px var(--sig); }
.skin-card .sw { display: flex; height: 38px; border-radius: 10px; overflow: hidden; margin-bottom: 9px; }
.skin-card .sw i { flex: 1; }
.skin-card .sk-n { display: block; font-size: 15px; font-weight: 600; letter-spacing: -0.015em; }
.skin-card .sk-d { display: block; font-size: 12px; color: var(--ink2); margin-top: 2px; line-height: 1.35; }
.pt-tools { display: flex; flex-wrap: wrap; gap: 0 8px; margin: -6px 0 6px; }
.pt-tools .btn-quiet { font-size: 14px; min-height: 44px; padding: 0 14px; margin-top: 8px; }
.pt-file { cursor: pointer; }
.vchips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.vchip {
  min-height: var(--tap); padding: 0 16px; border: 0; border-radius: 999px; cursor: pointer;
  background: var(--s1); color: var(--ink); font-family: var(--mono); font-size: 14px; letter-spacing: -0.01em;
  box-shadow: inset 0 0 0 1.5px var(--s3);
  transition: transform 140ms var(--spring), background-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}
.vchip:active { transform: scale(0.95); }
.vchip[aria-pressed="true"], .vchip[aria-checked="true"] { background: var(--sig); color: var(--sig-ink); box-shadow: 0 3px 0 var(--sig-edge); }
.vchip.inter { font-size: 13px; }
.ctab-wrap { overflow-x: auto; margin: 2px -4px 10px; -webkit-overflow-scrolling: touch; }
table.ctab { width: 100%; border-collapse: collapse; font-size: 13px; }
table.ctab th, table.ctab td { padding: 8px 5px; text-align: right; white-space: nowrap; box-shadow: inset 0 -1px 0 var(--s2); font-size: 12px; }
table.ctab tbody th { position: sticky; left: 0; background: var(--s1); }
table.ctab thead th { color: var(--ink2); font-weight: 500; font-size: 12px; }
table.ctab tbody th { text-align: left; font-weight: 500; font-family: var(--mono); font-size: 13px; }
table.ctab td { font-family: var(--mono); letter-spacing: -0.02em; white-space: pre-line; }
table.ctab td:last-child { font-size: 12px; line-height: 1.35; color: var(--ink2); }
.pt-details { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 0 16px; margin-bottom: 14px; }
.pt-details > summary { min-height: 52px; display: flex; align-items: center; cursor: pointer; font-size: 14px; font-weight: 500; list-style: none; }
.pt-details > summary::-webkit-details-marker { display: none; }
.pt-details > summary::after { content: "+"; margin-left: auto; color: var(--ink3); font-size: 18px; }
.pt-details[open] > summary::after { content: "\2212"; }
.pt-details[open] { padding-bottom: 12px; }
.mstats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 14px 0 10px; }
.ms { background: var(--s1); border-radius: calc(18px * var(--rk, 1)); padding: 12px 12px 10px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ms-l { font-size: 12px; color: var(--ink2); }
.ms-v { font-size: 22px; font-weight: 500; letter-spacing: -0.03em; color: var(--ink); }
.ms-d { font-family: var(--mono); font-size: 12px; color: var(--ink3); min-height: 16px; }
.ms-d.up { color: var(--sig-text); }
.ms-d.down { color: var(--ink2); }
.ms-d.up::before { content: "\25B2 "; font-size: 9px; }
.ms-d.down::before { content: "\25BC "; font-size: 9px; }
.mformula { background: var(--s1); border-radius: calc(16px * var(--rk, 1)); padding: 12px 14px; font-size: 14px; line-height: 1.45; overflow-wrap: anywhere; margin-bottom: 8px; box-shadow: inset 3px 0 0 var(--sig); }
.mhist { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 4px; }
.mh { display: block; width: 100%; text-align: left; border: 0; background: transparent; color: inherit; cursor: pointer; padding: 10px 12px; border-radius: calc(14px * var(--rk, 1)); font: inherit; transition: background-color 160ms ease, transform 140ms var(--ease-out); }
.mh + .mh { box-shadow: inset 0 1px 0 var(--s2); }
.mh:active { transform: scale(0.98); background: var(--s2); }
.mh.now { background: var(--sig-dim); }
.mh-f { display: block; font-size: 14px; font-weight: 500; overflow-wrap: anywhere; }
.mh-s { display: block; font-size: 12px; color: var(--ink2); margin-top: 3px; }
@media (hover: hover) and (pointer: fine) { .mh:hover { background: var(--s2); } }
:root { --m1: #5D6778; --m2: #1F7F76; --m3: #4554C2; --m4: #8E43A3; --m5: #946D0A; --m6: #2E7D32; --m7: #9A5230; --mc-ink: #FFFFFF; }
:root[data-theme="dark"] { --m1: #8A94A6; --m2: #4FB3A9; --m3: #7C8CF0; --m4: #C77DDB; --m5: #E2B33C; --m6: #6CC070; --m7: #D98F6A; --mc-ink: #0C0D0E; }
.mchip {
  display: inline-grid; place-items: center; flex: none; min-width: 34px; height: 24px; padding: 0 7px;
  border-radius: 7px; background: var(--mc, var(--s3)); color: var(--mc-ink);
  font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: 0; vertical-align: middle;
}
.mchip-pro, .mchip-q { background: var(--s3); color: var(--ink); }
.title .mchip { height: 28px; font-size: 13px; margin-right: 4px; transform: translateY(-3px); }
.menu-btn {
  display: inline-flex; align-items: center; gap: 6px; min-height: var(--tap); min-width: var(--tap); padding: 0 12px;
  border: 0; border-radius: 999px; background: var(--s1); color: var(--ink); cursor: pointer;
  font-family: var(--mono); font-size: 12px; font-weight: 600; flex: none;
}
.menu-btn svg { width: 18px; height: 18px; }
.bar .menu-btn span { display: none; }
.homebar .word { margin-right: auto; margin-left: 10px; }
.drawer.is-menu .drawer-body { padding-top: 0; }
.modmenu-list { display: flex; flex-direction: column; gap: 2px; }
.mm-row { display: flex; align-items: center; gap: 12px; min-height: 50px; padding: 6px 10px; border-radius: 14px; color: var(--ink); text-decoration: none; font-weight: 500; }
.mm-row:active, .mm-row.is-here { background: var(--s2); }
.mm-row .mm-t { flex: 1; font-size: 15px; letter-spacing: -0.01em; line-height: 1.25; }
.mm-row em { font-style: normal; font-family: var(--mono); font-size: 11px; color: var(--ink3); }
.mm-row.is-stub .mm-t { color: var(--ink2); }
.mm-sep { height: 1px; background: var(--s3); margin: 6px 4px; }
@media (hover: hover) and (pointer: fine) { .mm-row:hover { background: var(--s2); } }
.home-hero { font-size: 30px; margin: 4px 0 14px; max-width: none; }
.paths { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 18px; }
.path {
  display: flex; flex-direction: column; justify-content: space-between; gap: 6px; min-height: 96px; padding: 12px;
  background: var(--s1); border-radius: calc(18px * var(--rk, 1)); color: var(--ink); text-decoration: none;
  box-shadow: inset 0 -3px 0 var(--sig);
}
.path b { font-size: 15px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; }
.path span { font-size: 11.5px; color: var(--ink2); line-height: 1.3; }
.path:active { transform: scale(0.97); }
.mod-strip { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-bottom: 18px; }
.mod-tile {
  display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 10px; border: 0; cursor: pointer; text-align: left;
  background: var(--s1); border-radius: calc(14px * var(--rk, 1)); color: var(--ink); text-decoration: none; font: inherit;
  box-shadow: inset 4px 0 0 var(--mc, var(--sig));
}
.mod-tile .mt-n { font-family: var(--mono); font-size: 12px; font-weight: 700; min-width: 34px; height: 24px; display: grid; place-items: center; border-radius: 7px; background: var(--mc, var(--sig)); color: var(--mc-ink); }
.mod-class .mt-n { background: var(--sig); color: var(--sig-ink); padding: 0 6px; }
.mod-tile .mt-t { font-size: 14px; font-weight: 500; letter-spacing: -0.01em; line-height: 1.2; }
.mod-tile.is-stub .mt-t { color: var(--ink2); }
.mod-tile:active { transform: scale(0.97); }
.home .resume { margin-bottom: 10px; }
.home-about { margin: 6px 2px 0; }
.linkish { background: none; border: 0; padding: 8px 0; color: var(--ink2); font: inherit; font-size: 13px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.qchips { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 12px; scrollbar-width: none; position: sticky; top: 60px; z-index: 5; background: var(--ground); }
.qchips::-webkit-scrollbar { display: none; }
.qchips button { flex: none; min-height: 40px; padding: 0 14px; border: 0; border-radius: 999px; background: var(--s1); color: var(--ink); font-family: var(--mono); font-size: 13px; font-weight: 600; cursor: pointer; box-shadow: inset 0 -3px 0 var(--mc, var(--s3)); }
.qchips button[aria-pressed="true"] { background: var(--mc, var(--ink)); color: var(--mc-ink); }
.qchips button[data-qm="all"][aria-pressed="true"] { background: var(--ink); color: var(--ground); }
.qgroup-h { margin: 6px 2px 8px; font-size: 14px; font-weight: 600; }
.qgroup-h a, .qgroup-h { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.qgroup-h em { margin-left: auto; font-style: normal; font-family: var(--mono); font-size: 11px; color: var(--ink2); font-weight: 400; }
.qrow .mchip { margin-right: 2px; }
.region-pick { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; margin-bottom: 12px; }
.region-pick button {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px 6px; border: 0; cursor: pointer;
  background: var(--s1); border-radius: calc(14px * var(--rk, 1)); color: var(--ink2); font: inherit; font-size: 13px; font-weight: 500;
  box-shadow: inset 0 0 0 1.5px transparent;
}
.region-pick button[aria-pressed="true"] { color: var(--ink); box-shadow: inset 0 0 0 2px var(--sig); }
.region-pick svg.mini-curve { width: 100%; max-width: 76px; height: auto; display: block; }
.area-keys { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.area-keys button { min-height: 36px; padding: 0 12px; border: 0; border-radius: 999px; background: var(--s2); color: var(--ink); font-family: var(--mono); font-size: 12px; cursor: pointer; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.chip-t { min-height: 40px; padding: 0 14px; border: 0; border-radius: 999px; background: var(--s1); color: var(--ink); font-size: 14px; font-weight: 500; cursor: pointer; }
.chip-t[aria-pressed="true"] { background: var(--ink); color: var(--ground); }
.lv-frow { display: flex; gap: 6px; margin-bottom: 6px; }
.lv-frow input { flex: 1; min-width: 0; }
.lv-type, .lv-x { flex: none; min-width: 44px; min-height: 44px; border: 0; border-radius: 12px; background: var(--s2); color: var(--ink); font-family: var(--mono); font-size: 12px; cursor: pointer; padding: 0 10px; }
.lv-x { font-size: 20px; }
.lv-range { display: flex; gap: 10px; flex-wrap: wrap; }
.lv-range label { display: flex; align-items: center; gap: 6px; color: var(--ink2); font-size: 14px; }
.lv-range input { width: 88px; min-height: 44px; }
.hist-replay { margin-top: 8px; }
.live-ov-data .hist-replay { margin-top: 10px; }
.live-hist .lh-bar.lh-mine { stroke: var(--ink); stroke-width: 2.5; }
.live-hist .lh-you { fill: var(--ink); font-size: 12px; font-weight: 700; transition: opacity .2s; }
.live-hist.lh-moving .lh-you, .live-hist.lh-wait .lh-you { opacity: 0; }
.join-class { margin-top: 12px; }
.join-class .join-q-k { display: block; margin-bottom: 6px; }
.live-ov-share { color: var(--ink2); margin: 8px 0 0; }
.lv-fallback { margin-top: 22px; color: var(--ink2); font-size: 14px; }
.lv-fallback summary { cursor: pointer; min-height: 40px; display: flex; align-items: center; }
.live-top { display: grid; grid-template-columns: 1fr; gap: 10px; }
.live-qr { display: grid; grid-template-columns: 132px 1fr; gap: 14px; align-items: center; text-align: left; padding: 14px; }
.live-qr .qr-box { width: 132px; }
.live-code span { display: block; font-size: 12px; color: #4E5358; }
.live-code b { display: block; font-family: var(--mono); font-size: 34px; letter-spacing: 0.04em; color: #0C0D0E; line-height: 1.1; margin: 2px 0 6px; white-space: nowrap; }
.live-code em { display: block; font-style: normal; font-size: 12px; color: #4E5358; line-height: 1.35; }
.live-full { grid-column: 1 / -1; margin: 0; width: 100%; background: #EAEAE6; color: #0C0D0E; box-shadow: 0 3px 0 #D2D2CC; }
.live-count { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; padding: 4px 4px 0; }
.live-count b { font-family: var(--mono); font-size: 40px; color: var(--sig-text); line-height: 1; }
.live-count span { font-size: 15px; color: var(--ink); }
.live-count em { margin-left: auto; font-style: normal; font-family: var(--mono); font-size: 12px; color: var(--ink2); }
.live-graph { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 12px; margin-top: 0; }
.live-hist { width: 100%; height: auto; display: block; }
.live-hist text { font-family: var(--mono); }
.live-hist .lh-n { font-size: 11px; fill: var(--ink); font-weight: 600; }
.live-hist .lh-x { font-size: 11px; fill: var(--ink2); }
.live-hist { touch-action: manipulation; -webkit-tap-highlight-color: transparent; border-radius: 6px; }
.live-hist:focus { outline: none; }
.live-hist:focus-visible { outline: 2px solid var(--sig); outline-offset: 4px; }
.live-hist .lh-bar { transition: opacity 160ms ease; }
.live-hist[data-sel] .lh-bar:not(.lh-on) { opacity: .42; }
.live-hist .lh-n { transition: opacity 180ms ease; }
.live-hist .lh-col.lh-on { fill: var(--sig-dim); }
.live-hist .lh-up { animation: lh-flash 900ms ease-out 1; }
@keyframes lh-flash { 0% { fill: #FFD0BC; } 100% { fill: var(--sig); } }
.lh-wait .lh-bar { transform: scaleY(0); transform-box: fill-box; transform-origin: 50% 100%; }
.lh-wait .lh-n { opacity: 0; }
@media print, (prefers-reduced-motion: reduce) { .lh-wait .lh-bar { transform: none; } .lh-wait .lh-n { opacity: 1; } }
.lh-tip { margin: 4px 0 0; min-height: 1.5em; font-family: var(--mono); font-size: 13px; line-height: 1.5; color: var(--ink2); overflow-wrap: anywhere; }
.lh-tip.on { color: var(--ink); }
.d-shape { background: var(--s1); border-radius: calc(14px * var(--rk, 1)); padding: 10px 12px 8px; margin: -6px 0 16px; }
.d-shape-k { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 13px; color: var(--ink2); margin-bottom: 2px; }
.d-shape-k b { font-family: var(--mono); font-weight: 600; color: var(--ink); font-size: 12px; white-space: nowrap; }
.live-overlay .lh-tip { color: #A4A9AE; font-size: clamp(14px, 1.6vw, 20px); }
.live-empty { padding: 34px 10px; text-align: center; color: var(--ink2); font-size: 14px; }
.live-stats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; }
.live-stats div { text-align: center; }
.live-stats span { display: block; font-size: 11px; color: var(--ink2); }
.live-stats b { display: block; font-family: var(--mono); font-size: 13px; font-weight: 600; }
.live-actions { display: flex; flex-wrap: wrap; gap: 0 8px; }
.live-actions .btn-quiet { margin-top: 10px; }
.live-prompt { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 14px; margin-top: 0; }
.lp-q { font-size: 17px; font-weight: 600; letter-spacing: -0.015em; margin: 0; line-height: 1.3; }
.lp-n { margin: 0; color: var(--ink2); font-size: 14px; }
.lp-n b { color: var(--sig-text); font-family: var(--mono); }
.lp-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; }
.lp-list li { background: var(--s2); border-radius: 12px; padding: 8px 10px; font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.lp-list li span { display: block; font-family: var(--mono); font-size: 11px; color: var(--ink2); }
.lv-check { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 14px; color: var(--ink2); min-height: 40px; }
.live-table { margin-top: 18px; }
.live-table summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; font-size: 14px; font-weight: 500; }
.live-end { margin-top: 18px; color: var(--err); }
.live-overlay { position: fixed; inset: 0; z-index: 60; background: #0C0D0E; color: #EDEEEF; padding: 24px; overflow: auto; }
.live-ov-x { position: absolute; top: 14px; right: 14px; width: 48px; height: 48px; border: 0; border-radius: 50%; background: #272B2F; color: #EDEEEF; font-size: 26px; cursor: pointer; }
.live-ov-grid { display: grid; grid-template-columns: 1fr; gap: 24px; align-items: center; min-height: 100%; }
@media (min-width: 900px), (orientation: landscape) and (min-width: 600px) { .live-ov-grid { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); } }
.live-ov-qr { background: #FFFFFF; color: #0C0D0E; border-radius: 24px; padding: 20px; text-align: center; }
.live-ov-qr svg { width: min(100%, 60vh); height: auto; display: block; margin: 0 auto; }
.live-ov-qr p { margin: 10px 0 4px; font-size: clamp(16px, 2.2vw, 22px); }
.live-ov-code { font-family: var(--mono); font-size: clamp(44px, 7vw, 88px); letter-spacing: 0.05em; display: block; }
.live-ov-data h3 { font-size: clamp(20px, 2.6vw, 30px); margin: 0 0 10px; }
.live-ov-n { font-size: clamp(18px, 2.4vw, 26px); margin: 0; }
.live-ov-n b { font-family: var(--mono); font-size: clamp(48px, 7vw, 96px); color: #FF7A45; }
.live-overlay .live-hist .lh-n { font-size: 13px; fill: #EDEEEF; }
.live-overlay .live-hist .lh-x { font-size: 13px; fill: #A4A9AE; }
.live-overlay .live-hist rect.lh-bar { fill: #FF5B1F; }
.live-ov-data .live-hist { max-height: calc(100vh / var(--z) - 230px); min-height: 180px; }
.live-ov-qr svg { width: min(100%, calc(56vh / var(--z))); }
.live-overlay .live-hist .lh-col.lh-on { fill: rgba(255,91,31,.2); }
.jn-code { font-family: var(--mono); font-size: 28px; letter-spacing: 0.12em; text-transform: uppercase; text-align: center; }
.join-head { background: var(--s1); border-radius: calc(18px * var(--rk, 1)); padding: 12px 14px; margin-bottom: 4px; }
.join-head span { display: block; font-family: var(--mono); font-size: 12px; color: var(--ink2); }
.join-head b { display: block; font-size: 20px; letter-spacing: -0.02em; margin-top: 2px; }
.join-form { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 14px; }
.join-ok { color: var(--sig-text); font-weight: 500; margin: 4px 0 0; min-height: 1em; }
.join-q { background: var(--s1); border-radius: calc(20px * var(--rk, 1)); padding: 14px; box-shadow: inset 0 0 0 2px var(--sig); }
.join-q-k { font-family: var(--mono); font-size: 11px; color: var(--sig-text); text-transform: uppercase; letter-spacing: 0.06em; }
.join-q textarea, .join-form input { width: 100%; }
.homebar .gear { display: none; }
:root[data-text="lg"] body { zoom: 1.15; }
:root[data-text="xl"] body { zoom: 1.3; }
.set-row-stack { flex-wrap: wrap; }
.set-row-stack .seg { flex: 1 1 100%; }
.seg .ts-base { font-size: 14px; }
.seg .ts-lg { font-size: 17px; }
.seg .ts-xl { font-size: 20px; }
:root[data-contrast="high"] {
  --ground: #FFFFFF; --s1: #FFFFFF; --s2: #E4E4E0; --s3: #B9B9B3; --edge: #0C0D0E;
  --ink: #000000; --ink2: #1E2124; --ink3: #33373B;
  --sig: #C23A08; --sig-ink: #FFFFFF; --sig-edge: #8A2905; --sig-text: #9E2F06; --err: #A3180B;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"])[data-contrast="high"] {
    --ground: #000000; --s1: #0E0F10; --s2: #24282C; --s3: #4A5056; --edge: #FFFFFF;
    --ink: #FFFFFF; --ink2: #E6E8EA; --ink3: #CDD1D5;
    --sig: #FF6A2E; --sig-ink: #000000; --sig-edge: #FF9A70; --sig-text: #FF9A70; --err: #FFA79C;
  }
}
:root[data-theme="dark"][data-contrast="high"] {
  --ground: #000000; --s1: #0E0F10; --s2: #24282C; --s3: #4A5056; --edge: #FFFFFF;
  --ink: #FFFFFF; --ink2: #E6E8EA; --ink3: #CDD1D5;
  --sig: #FF6A2E; --sig-ink: #000000; --sig-edge: #FF9A70; --sig-text: #FF9A70; --err: #FFA79C;
}
:root[data-contrast="high"] .list, :root[data-contrast="high"] .set-group, :root[data-contrast="high"] .card,
:root[data-contrast="high"] .result, :root[data-contrast="high"] input, :root[data-contrast="high"] .seg { box-shadow: inset 0 0 0 1.5px var(--s3); }
:root[data-contrast="high"] a, :root[data-contrast="high"] .num { font-weight: 600; }
:root:not([data-text="xl"]) .seg-alt button { white-space: nowrap; }
.pw-curve { display: block; width: 100%; height: auto; max-width: 460px; margin-top: 6px; }
.iv-row { flex-wrap: wrap; cursor: default; }
.iv-link { font-family: var(--mono); word-break: break-all; }
.iv-acts { display: flex; gap: 8px; margin-left: auto; }
:root { --z: 1; --rail: 400px; --col: 560px; }
:root[data-text="lg"] { --z: 1.15; }
:root[data-text="xl"] { --z: 1.3; }
#out, #cout { scroll-margin-top: 84px; }
@media (min-width: 1280px) {
  :root { --col: 640px; }
  #app { max-width: var(--col); }
  .tabs, .drawer { max-width: var(--col); }
}
@media (min-width: 1100px) {
  #app { margin-left: calc(var(--rail) + (100vw / var(--z) - var(--rail) - var(--col)) / 2); }
  .tabs, .drawer { left: calc(var(--rail) + (100vw / var(--z) - var(--rail) - var(--col)) / 2); width: var(--col); }
  .reg-toast { left: calc(var(--rail) + (100vw / var(--z) - var(--rail)) / 2); }
}
@media (min-width: 1100px) and (max-width: 1279.98px) {
  :root[data-text="lg"] .brand-rail, :root[data-text="xl"] .brand-rail { display: none; }
  :root[data-text="lg"] #app, :root[data-text="xl"] #app { margin-left: auto; margin-right: auto; }
  :root[data-text="lg"] .tabs, :root[data-text="lg"] .drawer,
  :root[data-text="xl"] .tabs, :root[data-text="xl"] .drawer { left: 0; right: 0; width: auto; margin: 0 auto; }
  :root[data-text="lg"] .reg-toast, :root[data-text="xl"] .reg-toast { left: 50%; }
}
@media (min-width: 1280px) and (max-width: 1439.98px) {
  :root[data-text="xl"] .brand-rail { display: none; }
  :root[data-text="xl"] #app { margin-left: auto; margin-right: auto; }
  :root[data-text="xl"] .tabs, :root[data-text="xl"] .drawer { left: 0; right: 0; width: auto; margin: 0 auto; }
  :root[data-text="xl"] .reg-toast { left: 50%; }
}
@media (min-width: 1680px) {
  :root { --z: 1.2; } body { zoom: 1.2; }
  :root[data-text="lg"] { --z: 1.38; } :root[data-text="lg"] body { zoom: 1.38; }
  :root[data-text="xl"] { --z: 1.56; } :root[data-text="xl"] body { zoom: 1.56; }
}
@media (min-width: 2240px) {
  :root { --z: 1.5; } body { zoom: 1.5; }
  :root[data-text="lg"] { --z: 1.725; } :root[data-text="lg"] body { zoom: 1.725; }
  :root[data-text="xl"] { --z: 1.95; } :root[data-text="xl"] body { zoom: 1.95; }
}
.mod-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mod-tile { min-width: 0; }
@media (max-width: 600px) {
  :root[data-text="lg"] .homebar .menu-btn span, :root[data-text="xl"] .homebar .menu-btn span,
  :root[data-text="lg"] .homebar [data-theme-label], :root[data-text="xl"] .homebar [data-theme-label] { display: none; }
  :root[data-text="lg"] .homebar, :root[data-text="xl"] .homebar { padding-left: 14px; padding-right: 14px; }
  :root[data-text="lg"] .homebar .chip, :root[data-text="xl"] .homebar .chip { padding: 0 12px; }
  :root[data-text="xl"] .step { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  :root[data-text="xl"] .step .note { padding-left: 10px; }
  :root[data-text="xl"] .mod-class .mt-n { font-size: 11px; padding: 0 4px; }
}
:root[data-theme="light"]:not([data-contrast="high"]) { --sig-ink: #0C0D0E; }
.paths { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.path { min-width: 0; overflow-wrap: break-word; }
@media (max-width: 600px) {
  :root[data-text="xl"] .paths { grid-template-columns: minmax(0, 1fr); }
  :root[data-text="xl"] .path { min-height: 0; }
}
@media (max-width: 420px) {
  :root[data-text="xl"] .mod-strip { grid-template-columns: minmax(0, 1fr); }
}
#app { min-height: calc(100vh / var(--z)); min-height: calc(100dvh / var(--z)); }
.bz-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
:root[data-text="xl"] .bz-pair { grid-template-columns: 1fr; }
.reg-pred { margin-bottom: 14px; }
.hist-block { margin: 4px 0 14px; }
.hist-desc { margin: 6px 0 2px; }
.hist-ctl { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; margin-top: 10px; }
.hist-rule { flex: 1 1 190px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hist-k { font-size: 13px; color: var(--ink2); }
.hist-rule select { min-height: 48px; font-size: 15px; }
.hist-bars { flex: 1 1 240px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hs-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.hist-step { display: flex; align-items: center; gap: 8px; min-width: 0; background: var(--s2); border-radius: calc(16px * var(--rk, 1)); padding: 4px; }
.hs-range { flex: 1; min-width: 0; height: 48px; margin: 0; background: transparent; -webkit-appearance: none; appearance: none; cursor: pointer; accent-color: var(--sig); }
.hs-range:disabled { opacity: .4; cursor: default; }
.hs-range::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: color-mix(in srgb, var(--ink2) 40%, transparent); }
.hs-range::-moz-range-track { height: 6px; border-radius: 3px; background: color-mix(in srgb, var(--ink2) 40%, transparent); }
.hs-range::-webkit-slider-thumb { -webkit-appearance: none; width: 28px; height: 28px; margin-top: -11px; border-radius: 50%; background: var(--sig); border: 3px solid var(--s1); box-shadow: 0 1px 3px rgba(0,0,0,.35); }
.hs-range::-moz-range-thumb { width: 24px; height: 24px; border-radius: 50%; background: var(--sig); border: 3px solid var(--s1); }
.hs-range:focus-visible { outline: 2px solid var(--sig); outline-offset: 2px; border-radius: 8px; }
.hs-btn {
  width: 48px; height: 48px; flex: none; border: 0; border-radius: calc(12px * var(--rk, 1)); background: var(--s1);
  color: var(--ink); font-size: 24px; font-weight: 600; line-height: 1; cursor: pointer; box-shadow: 0 2px 0 var(--s3);
}
.hs-btn:active:not(:disabled) { transform: scale(0.96); }
.hs-btn:disabled { opacity: .4; cursor: default; box-shadow: none; }
.hs-read { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; justify-content: flex-end; min-width: 0; line-height: 1.25; }
.hs-read b { font-size: 16px; font-weight: 600; color: var(--ink); }
.hs-read > span { font-size: 13px; color: var(--ink2); }
.seg-groups button { padding: 8px; }
.grp-addons { margin-top: 2px; }
.addon-shelf { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: 8px; margin-bottom: 18px; }
.addon-card {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; min-width: 0;
  padding: 14px 14px 12px; border-radius: calc(18px * var(--rk, 1)); text-decoration: none; color: var(--ink);
  background: linear-gradient(180deg, var(--s1), var(--s2)); box-shadow: inset 0 0 0 1px var(--s3), inset 0 3px 0 var(--sig);
}
.ad-badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px 3px 7px; border-radius: 999px;
  background: var(--ink); color: var(--ground); font-family: var(--mono); font-size: 11px; font-weight: 600; letter-spacing: .02em;
}
.ad-badge.is-open { background: var(--sig-dim); color: var(--ink); padding-left: 9px; }
.ad-ico { width: 12px; height: 12px; flex: none; }
.ad-t { font-size: 16px; font-weight: 600; line-height: 1.25; }
.ad-d { font-size: 13px; color: var(--ink2); line-height: 1.4; }
.ad-go { margin-top: auto; padding-top: 4px; font-size: 13px; font-weight: 600; color: var(--sig-text); }
@media (hover: hover) and (pointer: fine) { .addon-card:hover { box-shadow: inset 0 0 0 1px var(--ink3), inset 0 3px 0 var(--sig); } }
.mchip-addon { background: var(--ink); color: var(--ground); }
.addon-preview .ad-badge { margin-bottom: 10px; }
.ad-lead { font-size: 17px; line-height: 1.45; margin: 0 0 16px; max-width: 34rem; }
.ad-how { font-size: 15px; line-height: 1.5; color: var(--ink2); margin: 0 0 14px; max-width: 34rem; }
.hist-block [data-hist-reset] { display: inline-flex; align-items: center; min-height: 44px; padding: 0 2px; }
.lite-lock { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; padding: 2px 8px 2px 6px; border-radius: 999px;
  font-size: 12px; font-weight: 600; line-height: 1.4; color: var(--ink2); background: var(--s2); border: 1px solid var(--edge); vertical-align: middle; white-space: nowrap; }
.lite-lock svg { width: 12px; height: 12px; flex: none; color: var(--sig-text, var(--sig)); }
.card-title .lite-lock { margin: 0 0 0 6px; }
.row .lite-lock { display: inline-flex; }
.mod-tile.is-locked { position: relative; padding-right: 36px; }
.mod-tile.is-locked .mt-t { color: var(--ink2); }
.tile-lock { position: absolute; top: 8px; right: 8px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  background: var(--s2); color: var(--sig-text, var(--sig)); }
.tile-lock svg { width: 12px; height: 12px; }
.lite-band { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: center; margin: 0 0 18px; padding: 14px 16px;
  border-radius: calc(16px * var(--rk, 1)); background: var(--s1); border: 1px solid var(--edge); box-shadow: inset 4px 0 0 var(--sig); color: var(--ink); text-decoration: none; }
.lite-band b { font-size: 16px; }
.lite-band span:not(.go) { grid-column: 1; font-size: 14px; color: var(--ink2); }
.lite-band .go { grid-row: 1 / span 2; grid-column: 2; font-size: 22px; color: var(--ink2); }
.unlock { max-width: 36rem; }
.unlock-from { margin: 0 0 10px; color: var(--ink2); font-size: 14px; }
.unlock-act { display: flex; flex-direction: column; gap: 10px; margin: 16px 0 6px; }
.unlock-act .btn, .unlock-act .btn-quiet { width: 100%; min-height: 48px; justify-content: center; text-align: center; }
.unlock-act .btn:disabled { opacity: .55; }
:root {
  --elev-1: 0 1px 0 rgba(255,255,255,.9) inset, 0 1px 2px rgba(12,13,14,.05), 0 6px 18px -6px rgba(12,13,14,.10);
  --elev-2: 0 1px 0 rgba(255,255,255,.9) inset, 0 2px 4px rgba(12,13,14,.05), 0 18px 40px -14px rgba(12,13,14,.20);
  --glass: rgba(243,243,241,.72); --glass-edge: rgba(12,13,14,.08);
  --card-grad: linear-gradient(180deg, #FFFFFF 0%, #FAFAF8 100%);
  --paper-rule: rgba(12,13,14,.045);
  --glow: rgba(232,72,14,.28);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --elev-1: 0 1px 0 rgba(255,255,255,.06) inset, 0 0 0 1px rgba(255,255,255,.035), 0 8px 24px -10px rgba(0,0,0,.7);
    --elev-2: 0 1px 0 rgba(255,255,255,.08) inset, 0 0 0 1px rgba(255,255,255,.05), 0 24px 48px -18px rgba(0,0,0,.85);
    --glass: rgba(18,20,22,.70); --glass-edge: rgba(255,255,255,.07);
    --card-grad: linear-gradient(180deg, #1A1D20 0%, #141618 100%);
    --paper-rule: rgba(255,255,255,.035);
    --glow: rgba(255,91,31,.34);
  }
}
:root[data-theme="dark"] {
  --elev-1: 0 1px 0 rgba(255,255,255,.06) inset, 0 0 0 1px rgba(255,255,255,.035), 0 8px 24px -10px rgba(0,0,0,.7);
  --elev-2: 0 1px 0 rgba(255,255,255,.08) inset, 0 0 0 1px rgba(255,255,255,.05), 0 24px 48px -18px rgba(0,0,0,.85);
  --glass: rgba(18,20,22,.70); --glass-edge: rgba(255,255,255,.07);
  --card-grad: linear-gradient(180deg, #1A1D20 0%, #141618 100%);
  --paper-rule: rgba(255,255,255,.035);
  --glow: rgba(255,91,31,.34);
}
html { overscroll-behavior: none; -webkit-tap-highlight-color: transparent; }
a, button, summary, label, select, [role="button"], .row, .card, .chip, .path, .mod-tile, .tabs a { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
button, .btn, .btn-quiet, .chip, .tabs, .bar, .homebar, .path, .mod-tile, .seg, .row, .card, .lite-band, summary, .qchips, .hero-card {
  -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
}
img, svg { -webkit-user-drag: none; -webkit-touch-callout: none; }
body { background: var(--ground) radial-gradient(120% 60% at 85% -10%, var(--sig-dim), transparent 60%) no-repeat fixed; }
.bar, .homebar {
  background: var(--glass);
  -webkit-backdrop-filter: saturate(180%) blur(22px); backdrop-filter: saturate(180%) blur(22px);
}
.homebar { position: sticky; top: 0; z-index: 20; margin: 0 -0px; padding-bottom: 8px; }
.bar { box-shadow: 0 1px 0 var(--glass-edge); }
.bar-back, .bar-help, .chip, .bar-reg { background: var(--s1); box-shadow: var(--elev-1); }
.tabs {
  left: 12px; right: 12px; bottom: calc(env(safe-area-inset-bottom) + 6px);
  max-width: 520px; padding: 6px; border-radius: 28px; gap: 2px;
  background: var(--glass);
  -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px);
  box-shadow: var(--elev-2), 0 0 0 0.5px var(--glass-edge);
}
.tabs::before { display: none; }
.tabs a { height: 52px; border-radius: 22px; font-size: 10.5px; letter-spacing: .01em; }
.tabs a[aria-current="page"] { color: var(--sig-text); background: var(--s1); box-shadow: var(--elev-1); }
.tabs a[aria-current="page"] svg { stroke-width: 2.3; }
.screen { padding-bottom: calc(110px + env(safe-area-inset-bottom)); }
.title { font-size: 34px; font-weight: 700; letter-spacing: -0.035em; line-height: 1.06; margin: 10px 18px 18px; }
.hero.home-hero { font-size: 34px; font-weight: 700; letter-spacing: -0.04em; line-height: 1.04; margin: 10px 0 10px; text-wrap: balance; }
.title { text-wrap: balance; }
.lede { font-size: 16px; }
.path, .mod-tile, .list, .resume, .result-block, .work, .stub-list, .curvewrap, .card, .lite-band, .result-answer {
  background: var(--card-grad); box-shadow: var(--elev-1);
}
.path { box-shadow: var(--elev-1); position: relative; overflow: hidden; border-radius: 20px; min-height: 104px; padding: 14px 12px 12px; }
.path::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 0; height: 3px; border-radius: 3px 3px 0 0; background: var(--sig); }
.mod-tile { box-shadow: var(--elev-1); border-radius: 16px; min-height: 56px; }
.mod-tile .mt-n { box-shadow: 0 1px 0 rgba(255,255,255,.25) inset, 0 2px 6px -2px var(--mc, var(--sig)); }
.lite-band { border-radius: 20px; }
.grp, .section-label { text-transform: uppercase; letter-spacing: .08em; font-size: 11.5px; font-weight: 600; color: var(--ink3); }
.hero-card {
  display: block; position: relative; overflow: hidden; margin: 4px 0 20px; padding: 16px 16px 16px;
  border-radius: 26px; color: var(--ink); text-decoration: none; font-weight: 400;
  background: radial-gradient(90% 80% at 90% 0%, var(--sig-dim), transparent 70%), var(--card-grad);
  box-shadow: var(--elev-2);
}
.hc-k { display: flex; justify-content: space-between; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ink3); }
.hc-k .num { text-transform: none; letter-spacing: 0; color: var(--sig-text); }
.hc-svg { display: block; width: 100%; height: 124px; margin: 8px 0 6px; overflow: visible; }
.hc-line { fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; animation: hc-draw 1100ms cubic-bezier(.65,0,.35,1) 120ms forwards; vector-effect: non-scaling-stroke; }
.hc-axis { stroke: var(--s3); stroke-width: 1; vector-effect: non-scaling-stroke; }
.hc-cut { stroke: var(--sig); stroke-width: 2.4; stroke-linecap: round; vector-effect: non-scaling-stroke; opacity: 0; animation: hc-fade 400ms ease 900ms forwards; }
.hc-body { opacity: 0; animation: hc-fade 700ms ease 500ms forwards; }
.hc-slice { opacity: 0; transform-origin: 100% 100%; transform: scaleY(.2); animation: hc-grow 700ms var(--spring) 950ms forwards; filter: drop-shadow(0 -6px 14px var(--glow)); }
.hc-v { display: flex; align-items: center; gap: 14px; }
.hc-big { font-size: 40px; font-weight: 600; letter-spacing: -0.05em; color: var(--sig-text); line-height: 1; }
.hc-cap { font-size: 13.5px; line-height: 1.4; color: var(--ink2); }
@keyframes hc-draw { to { stroke-dashoffset: 0; } }
@keyframes hc-fade { to { opacity: 1; } }
@keyframes hc-grow { to { opacity: 1; transform: none; } }
path[fill="url(#sp-hatch)"] { fill: url(#sp-tail); }
.curvewrap { border-radius: 24px; padding: 14px 12px 10px; background: radial-gradient(80% 70% at 70% 0%, var(--sig-dim), transparent 70%), var(--card-grad); }
.curvewrap svg path[stroke="var(--ink-2)"] { stroke-width: 2.6; stroke-linecap: round; }
.curvewrap svg circle[fill="var(--green-2)"] { filter: drop-shadow(0 2px 6px var(--glow)); }
.chart rect[fill="var(--green-2)"] { fill: var(--ink); opacity: .9; }
.btn {
  background: linear-gradient(180deg, color-mix(in srgb, var(--sig) 88%, #fff) 0%, var(--sig) 55%, color-mix(in srgb, var(--sig) 90%, #000) 100%);
  box-shadow: 0 4px 0 var(--sig-edge), 0 14px 28px -10px var(--glow), 0 1px 0 rgba(255,255,255,.35) inset;
  border-radius: 18px; font-weight: 600; letter-spacing: -0.01em; min-height: 54px;
}
.btn:active { box-shadow: 0 1px 0 var(--sig-edge), 0 6px 14px -8px var(--glow), 0 1px 0 rgba(255,255,255,.3) inset; }
.result-answer { border-radius: 24px; padding: 18px; box-shadow: var(--elev-2), inset 0 3px 0 var(--sig); animation: ra-in 520ms var(--spring) both; }
.result-answer .ra-value { text-shadow: 0 0 24px var(--glow); }
@keyframes ra-in { from { opacity: 0; transform: translateY(14px) scale(.97); } }
.result-block { border-radius: 22px; animation: ra-in 520ms var(--spring) 80ms both; }
.work {
  border-radius: 22px; padding: 6px 16px;
  background-image: repeating-linear-gradient(180deg, transparent 0 23px, var(--paper-rule) 23px 24px), var(--card-grad);
  box-shadow: var(--elev-1), inset 3px 0 0 var(--sig-dim);
}
.step { box-shadow: inset 0 -1px 0 var(--paper-rule); }
.step .math { font-variant-numeric: tabular-nums; }
.step.big .math, .step.p .math { font-size: 20px; }
.seg { background: var(--s2); border-radius: 14px; padding: 3px; box-shadow: inset 0 1px 2px rgba(0,0,0,.06); }
.seg button { border-radius: 11px; }
.seg button[aria-pressed="true"] { background: var(--s1); box-shadow: 0 3px 8px -2px rgba(0,0,0,.18), 0 0 0 .5px var(--glass-edge); color: var(--ink); }
input[type="number"], input[type="text"], input[type="email"], select, textarea {
  background: var(--s1); box-shadow: inset 0 0 0 1px var(--s3), inset 0 2px 4px rgba(0,0,0,.04); border-radius: 16px;
}
input:focus, select:focus, textarea:focus { box-shadow: inset 0 0 0 2px var(--sig), 0 0 0 5px var(--sig-dim); }
.ul-hero { display: grid; place-items: center; margin: 2px 0 18px; }
.ul-hero svg { width: 96px; height: 96px; border-radius: 22.5%; box-shadow: 0 24px 50px -16px var(--glow), 0 0 0 1px var(--glass-edge); animation: ra-in 700ms var(--spring) both; }
.ul-buybox { margin: 18px 0 22px; display: flex; flex-direction: column; gap: 10px; }
.ul-buybox .btn { width: 100%; justify-content: center; text-align: center; }
.ul-buybox .field-hint { text-align: center; }
.unlock .stub-list { list-style: none; padding: 6px 16px; }
.unlock .stub-list li { position: relative; padding: 11px 0 11px 30px; margin: 0; box-shadow: inset 0 -1px 0 var(--paper-rule); }
.unlock .stub-list li:last-child { box-shadow: none; }
.unlock .stub-list li::before { content: ""; position: absolute; left: 2px; top: 14px; width: 16px; height: 16px; border-radius: 50%;
  background: conic-gradient(var(--sig) 0 30%, var(--ink3) 30% 100%); opacity: .9; }
.unlock .ad-lead { text-align: center; font-size: 17px; line-height: 1.45; }
.unlock-from { text-align: center; }
.drawer { box-shadow: 0 -20px 60px -20px rgba(0,0,0,.45); }
.scrim { -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
@media (prefers-reduced-motion: reduce) {
  .hc-line { stroke-dashoffset: 0; animation: none; } .hc-body, .hc-cut, .hc-slice { opacity: 1; transform: none; animation: none; }
  .result-answer, .result-block, .ul-hero svg { animation: none; }
}
@media (min-width: 700px) and (max-width: 1099.98px) {
  #app { max-width: 720px; }
  .tabs { max-width: 560px; }
  .pad { padding: 0 28px 28px; }
  .bar, .homebar { padding-left: 28px; padding-right: 28px; }
  .title { margin-left: 28px; margin-right: 28px; font-size: 40px; }
  .hero.home-hero { font-size: 44px; }
  .hc-svg { height: 170px; }
  .mod-strip { grid-template-columns: repeat(4, 1fr); }
}
.live-hist .lh-bar { fill: var(--ink); fill-opacity: .82; }
.live-hist .lh-bar.lh-mine { fill: var(--sig); fill-opacity: 1; stroke: none; filter: drop-shadow(0 -4px 10px var(--glow)); }
.live-hist .lh-you { fill: var(--sig-text); font-size: 13px; letter-spacing: .02em; }
