/* 就练 · web
   Editorial sports layout: warm paper canvas, ink-black hero, Keep's light_green as the single accent,
   condensed numerals (Barlow Semi Condensed) for every figure. Planning pages are light; the training
   page switches to a dark "stage" so the numbers carry across a room. Signature details:
   the tempo line in the hero, the per-rep segment track, and the breathing ring during rest. */

@font-face { font-family: "Num"; src: url(fonts/barlow-sc-600.woff2) format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Num"; src: url(fonts/barlow-sc-700.woff2) format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Num"; src: url(fonts/barlow-sc-800.woff2) format("woff2"); font-weight: 800; font-display: swap; }

:root {
  --green: #24c789;
  --green-d: #12936a;
  --green-l: #7fdcb3;
  --green-soft: #e6f7ef;
  --amber: #f2a93b;
  --ink: #131614;
  --ink-2: #3a3f3c;
  --muted: #6b716d;
  --faint: #a1a6a2;
  --line: #e3e5e0;
  --line-2: #eef0ec;
  --paper: #f4f5f1;
  --panel: #fff;
  --hover: #f3f4f0;
  --danger: #df3f45;
  --hero: #0e1210;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --num: "Num", Bahnschrift, "DIN Alternate", system-ui, sans-serif;
  --wrap: 1240px;
  --r: 14px;
  --shadow: 0 1px 2px rgba(19, 22, 20, .04), 0 8px 24px -16px rgba(19, 22, 20, .12);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink); font-size: 14.5px; line-height: 1.55;
  font-family: "Segoe UI Variable Text", "Segoe UI", -apple-system, "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", "Noto Sans SC", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  transition: background-color .5s var(--ease), color .5s var(--ease);
}
::selection { background: var(--green-l); color: #131614; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; border-radius: 6px; }
svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
kbd { font-family: var(--num); font-size: 11px; font-weight: 700; color: var(--muted); background: #fff; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 0 5px; line-height: 17px; display: inline-block; min-width: 20px; text-align: center; }
.num { font-family: var(--num); font-variant-numeric: tabular-nums; }

/* page transitions (View Transitions API; browsers without it just swap) */
::view-transition-old(root) { animation: vt-out .16s ease both; }
::view-transition-new(root) { animation: vt-in .4s var(--ease) both; }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; transform: translateY(10px); } }

/* ── header ──────────────────────────────────────────────── */
.site { position: sticky; top: 0; z-index: 30; background: rgba(244, 245, 241, .82); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .3s, background-color .5s var(--ease); }
.site.scrolled { border-bottom-color: var(--line); }
.site-in { max-width: var(--wrap); margin: 0 auto; height: 64px; padding: 0 28px; display: flex; align-items: center; gap: 40px; }
.logo { display: flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 700; letter-spacing: .5px; }
.logo img { width: 30px; height: 30px; border-radius: 9px; transition: transform .5s var(--spring); }
.logo:hover img { transform: rotate(-12deg) scale(1.06); }
.nav { position: relative; display: flex; height: 100%; gap: 6px; }
.nav a { display: flex; align-items: center; padding: 0 14px; color: var(--muted); font-weight: 500; transition: color .2s; }
.nav a:hover, .nav a.on { color: var(--ink); }
.nav-ink { position: absolute; bottom: 12px; height: 3px; border-radius: 2px; background: var(--green); left: 0; width: 0; transition: left .45s var(--ease), width .45s var(--ease); }
.site-act { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.site-act .hint { color: var(--muted); font-size: 13px; }
.site.training .nav { visibility: hidden; }

/* ── buttons ─────────────────────────────────────────────── */
.btn { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 999px; font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden;
  background: #131614; color: #fff; transition: background .2s, box-shadow .25s, transform .2s var(--ease), color .2s; isolation: isolate; }
.btn::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: radial-gradient(120px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, .25), transparent 60%); opacity: 0; transition: opacity .25s; z-index: -1; pointer-events: none; }
.btn:hover::after { opacity: 1; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 20px -10px rgba(19, 22, 20, .45); }
.btn:active { transform: translateY(0) scale(.98); }
.btn.go { background: var(--green); color: #06251a; }
.btn.go:hover { box-shadow: 0 10px 26px -10px rgba(36, 199, 137, .75); }
.btn.lg { height: 48px; padding: 0 24px; font-size: 15px; }
.btn.line { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.btn.line:hover { background: var(--panel); box-shadow: inset 0 0 0 1px var(--faint), 0 6px 16px -10px rgba(19, 22, 20, .3); }
.btn.ghost { background: transparent; color: var(--muted); }
.btn.ghost:hover { color: var(--ink); background: var(--hover); box-shadow: none; }
.btn.danger { background: var(--danger); color: #fff; }
.btn kbd { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .28); color: inherit; }
.btn.go kbd { background: rgba(6, 37, 26, .1); border-color: rgba(6, 37, 26, .2); }
.btn.line kbd, .btn.ghost kbd { background: var(--panel); border-color: var(--line); color: var(--muted); }
.btn svg { width: 16px; height: 16px; flex: none; }
.link { color: var(--green-d); font-weight: 600; font-size: 13px; background-image: linear-gradient(currentColor, currentColor); background-size: 0 1px; background-repeat: no-repeat; background-position: 0 100%; transition: background-size .3s var(--ease); }
.link:hover { background-size: 100% 1px; }

/* ── scaffolding ─────────────────────────────────────────── */
.page { max-width: var(--wrap); margin: 0 auto; padding: 22px 28px 80px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); }
.panel-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px 12px; }
.panel-h h3 { margin: 0; font-size: 13px; font-weight: 600; color: var(--muted); letter-spacing: .3px; }
.panel-b { padding: 4px 20px 18px; }
.cols { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
.stack { display: grid; gap: 24px; }
.reveal { animation: reveal .7s var(--ease) both; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes reveal { from { opacity: 0; transform: translateY(18px); } }
.section-t { display: flex; align-items: baseline; gap: 14px; margin: 44px 0 16px; }
.section-t h2 { margin: 0; font-size: 22px; letter-spacing: .2px; }
.section-t span { color: var(--muted); }

/* ── hero ────────────────────────────────────────────────── */
.hero { position: relative; overflow: hidden; border-radius: 22px; background: var(--hero); color: #f1f4f2; padding: 40px 44px 0; isolation: isolate; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background:
  radial-gradient(600px 300px at 85% 10%, rgba(36, 199, 137, .22), transparent 70%),
  radial-gradient(500px 260px at 0% 100%, rgba(36, 199, 137, .08), transparent 70%); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: end; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; color: rgba(241, 244, 242, .62); letter-spacing: .4px; }
.eyebrow i { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(36, 199, 137, .18); animation: live 2.4s ease-in-out infinite; }
@keyframes live { 50% { box-shadow: 0 0 0 8px rgba(36, 199, 137, 0); } }
.hero h1 { margin: 18px 0 14px; font-size: clamp(34px, 4.4vw, 58px); line-height: 1.1; font-weight: 700; letter-spacing: -.5px; }
.hero h1 em { font-style: normal; color: var(--green); }
.hero h1 .word { display: inline-block; animation: word .9s var(--ease) both; animation-delay: calc(var(--i) * 90ms + 120ms); }
@keyframes word { from { opacity: 0; transform: translateY(26px) rotate(2deg); filter: blur(6px); } }
.hero .lede { margin: 0; color: rgba(241, 244, 242, .7); font-size: 15px; animation: reveal .8s var(--ease) .35s both; }
.hero .lede b { color: #fff; font-family: var(--num); font-size: 19px; font-weight: 700; margin: 0 3px; }
.hero .acts { display: flex; gap: 12px; margin: 28px 0 0; flex-wrap: wrap; animation: reveal .8s var(--ease) .45s both; }
.hero .btn.line { color: #f1f4f2; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2); }
.hero .btn.line:hover { background: rgba(255, 255, 255, .06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .35); }
.hero .btn.line kbd { background: transparent; border-color: rgba(255, 255, 255, .25); color: rgba(255, 255, 255, .7); }
.glyph { position: relative; width: 320px; height: 260px; margin-right: -8px; pointer-events: none; }
.glyph b { position: absolute; right: 0; bottom: -46px; font-family: var(--num); font-weight: 800; font-size: 330px; line-height: 1; color: transparent; -webkit-text-stroke: 1.5px rgba(241, 244, 242, .16); letter-spacing: -6px; animation: glyph 1.2s var(--ease) both .1s; }
@keyframes glyph { from { opacity: 0; transform: translateY(40px) scale(.96); } }
.tempo { position: absolute; left: -30px; bottom: 64px; width: 360px; height: 120px; overflow: visible; }
.tempo path { stroke: var(--green); stroke-width: 2.5; fill: none; stroke-dasharray: 900; stroke-dashoffset: 900; animation: draw-line 2.4s var(--ease) .4s forwards; filter: drop-shadow(0 0 6px rgba(36, 199, 137, .55)); }
.tempo .rider { fill: #fff; filter: drop-shadow(0 0 6px rgba(36, 199, 137, .9)); offset-path: path("M0 80 L60 80 L78 80 L92 20 L108 104 L122 54 L134 80 L200 80 L218 80 L232 20 L248 104 L262 54 L274 80 L360 80"); animation: ride 3.2s linear 2.6s infinite; opacity: 0; }
@keyframes draw-line { to { stroke-dashoffset: 0; } }
@keyframes ride { 0% { offset-distance: 0%; opacity: 0; } 8% { opacity: 1; } 92% { opacity: 1; } 100% { offset-distance: 100%; opacity: 0; } }
.hero-week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); margin: 38px -44px 0; border-top: 1px solid rgba(255, 255, 255, .08); }
.hero-week > div { padding: 16px 18px 18px; border-left: 1px solid rgba(255, 255, 255, .06); position: relative; transition: background .3s; animation: reveal .7s var(--ease) both; animation-delay: calc(var(--i) * 50ms + 500ms); }
.hero-week > div:first-child { border-left: 0; padding-left: 44px; }
.hero-week > div:hover { background: rgba(255, 255, 255, .03); }
.hero-week small { display: block; color: rgba(241, 244, 242, .45); font-size: 12px; letter-spacing: .3px; }
.hero-week .today small { color: var(--green); font-weight: 600; }
.hero-week .today::before { content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 2px; background: var(--green); box-shadow: 0 0 12px rgba(36, 199, 137, .7); }
.hero-week .t { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 13px; font-weight: 600; white-space: nowrap; color: rgba(241, 244, 242, .92); min-height: 24px; }
.hero-week .t i { min-width: 24px; height: 24px; padding: 0 4px; border-radius: 7px; display: grid; place-content: center; font-style: normal; font-family: var(--num); font-weight: 800; font-size: 13px; flex: none; }
.hero-week .done i { background: var(--green); color: #06251a; }
.hero-week .off i { background: rgba(255, 255, 255, .12); color: rgba(255, 255, 255, .7); }
.hero-week .plan i { box-shadow: inset 0 0 0 1.5px rgba(36, 199, 137, .7); color: var(--green); }
.hero-week .plan { color: rgba(241, 244, 242, .55); font-weight: 500; }
.hero-week .t span { overflow: hidden; text-overflow: ellipsis; }

/* today's check-in, inside the hero */
.checkin { margin: 22px 0 0; max-width: 560px; animation: reveal .8s var(--ease) .55s both; }
.checkin > * + * { margin-top: 10px; }
.checkin summary { display: flex; align-items: center; gap: 10px; list-style: none; cursor: pointer; padding: 10px 14px; border-radius: 14px; background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1); transition: background .2s; }
.checkin summary::-webkit-details-marker { display: none; }
.checkin summary:hover { background: rgba(255, 255, 255, .08); }
.checkin summary span { color: rgba(241, 244, 242, .5); font-size: 13px; }
.checkin summary b { font-size: 14px; color: #f1f4f2; }
.checkin summary small { margin-left: auto; color: rgba(241, 244, 242, .4); font-size: 12px; }
.checkin summary svg { width: 16px; height: 16px; stroke: rgba(241, 244, 242, .5); stroke-width: 2; fill: none; transition: transform .3s var(--ease); flex: none; }
.checkin[open] summary svg { transform: rotate(90deg); }
.checkin[open] > .ck-row:first-of-type { margin-top: 14px; }
.ck-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ck-row > span { width: 64px; color: rgba(241, 244, 242, .5); font-size: 13px; flex: none; }
.ck-chip { height: 36px; padding: 0 14px; border-radius: 999px; font-size: 13px; font-weight: 600; color: rgba(241, 244, 242, .82); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); transition: background .2s, color .2s, box-shadow .2s; }
.ck-chip:hover { background: rgba(255, 255, 255, .06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .3); }
.ck-chip.on { background: var(--green); color: #06251a; box-shadow: none; }
.ck-say { display: flex; gap: 8px; }
.ck-say input { flex: 1; min-width: 0; height: 38px; padding: 0 14px; border-radius: 999px; border: 0; background: rgba(255, 255, 255, .07); color: #f1f4f2; font: inherit; font-size: 14px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); }
.ck-say input::placeholder { color: rgba(241, 244, 242, .38); }
.ck-say input:focus { outline: none; box-shadow: inset 0 0 0 1px var(--green), 0 0 0 4px rgba(36, 199, 137, .16); }
.ck-say .btn { background: rgba(255, 255, 255, .12); }
.ck-say .btn:disabled { opacity: .6; }
.ck-note { margin: 0; color: var(--green-l); font-size: 13px; }
.ah-row { border-top: 1px solid var(--line-2); }
.ah-row:first-child { border-top: 0; }
.ah-head { width: 100%; display: flex; align-items: center; gap: 16px; padding: 18px 22px; text-align: left; transition: background .2s; }
button.ah-head:hover { background: var(--hover); }
.ah-when { width: 92px; flex: none; }
.ah-when b { display: block; font-size: 16px; }
.ah-when small { color: var(--faint); font-size: 12px; }
.ah-day { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ah-day i { width: 28px; height: 28px; border-radius: 8px; display: grid; place-content: center; font-style: normal; font-family: var(--num); font-weight: 800; font-size: 13px; background: var(--green-soft); color: var(--green-d); flex: none; }
.ah-day i + i { margin-left: -4px; }
.ah-day i.off { background: var(--hover); color: var(--muted); }
.ah-min { color: var(--muted); font-size: 13px; white-space: nowrap; }
.ah-head .chev { width: 18px; height: 18px; stroke: var(--faint); stroke-width: 2; fill: none; transition: transform .3s var(--ease); flex: none; }
.ah-row.open .chev { transform: rotate(90deg); }
.ah-row.open > .ah-head { background: var(--hover); }
.ah-row.done .ah-day i { background: var(--green); color: #06251a; }
.ah-row.done .ah-min { color: var(--green-d); font-weight: 600; }
.ah-acts, .ah-extra { display: flex; align-items: center; gap: 14px; padding: 14px 22px; color: var(--muted); font-size: 13px; }
.ah-acts span, .ah-extra span { flex: 1; }
.ah-extra { padding-top: 0; }
.ah-body .restday { padding: 18px 22px 8px; line-height: 1.8; }
.bars { height: 118px; }
.bars .v { font-style: normal; font-family: var(--num); font-weight: 700; font-size: 12.5px; color: var(--ink-2); margin-bottom: 4px; line-height: 1; }
.bars .v.mute { color: var(--faint); font-weight: 600; }
.grid.days .session + .session { margin-top: 8px; }
.grid.days .session .sub-note { margin-left: 8px; }
.grid.days .rm-log { display: inline-grid; width: 26px; height: 26px; margin-left: 4px; vertical-align: middle; }
.grid.days .rm-log svg { width: 13px; height: 13px; }
.grid.days .c-dur b { font-size: 19px; }
@media (max-width: 640px) {
  .ah-head { gap: 10px; padding: 15px 16px; }
  .ah-when { width: 58px; }
  .ah-acts, .ah-extra { flex-direction: column; align-items: stretch; padding: 12px 16px; }
  .grid.days .session .sub-note { display: block; margin: 2px 0 0; }
  .grid.days .session { position: relative; padding-right: 30px; }
  .grid.days .rm-log { position: absolute; top: 0; right: 0; margin: 0; }
}
.finish .more { margin: 0 0 14px; color: var(--muted); font-size: 14px; animation: reveal .7s var(--ease) .4s both; }
@media (max-width: 640px) { .ck-row > span { width: 100%; } }

.banner { display: flex; align-items: center; gap: 14px; padding: 14px 16px 14px 20px; margin: 0 0 20px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); box-shadow: var(--shadow); animation: reveal .6s var(--ease) both; }
.banner .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 5px rgba(242, 169, 59, .18); flex: none; }
.banner p { margin: 0; flex: 1; }
.banner p span { color: var(--muted); margin-left: 6px; }

/* ── plan table ──────────────────────────────────────────── */
.tabs { position: relative; display: flex; gap: 4px; padding: 0 10px; border-bottom: 1px solid var(--line-2); overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { display: flex; align-items: center; gap: 8px; padding: 16px 12px 14px; color: var(--muted); font-weight: 500; white-space: nowrap; transition: color .2s; }
.tabs a b { font-family: var(--num); font-weight: 800; font-size: 15px; }
.tabs a:hover, .tabs a.on { color: var(--ink); }
.tabs a .dot { width: 6px; height: 6px; border-radius: 3px; background: var(--green); }
.tab-ink { position: absolute; bottom: 0; height: 2px; background: var(--ink); left: 0; width: 0; transition: left .45s var(--ease), width .45s var(--ease); }
.plan-head { display: flex; align-items: flex-end; gap: 28px; padding: 24px 22px 22px; flex-wrap: wrap; }
.plan-head .ttl small { display: block; font-family: var(--num); font-weight: 700; letter-spacing: 2.5px; color: var(--green-d); font-size: 12px; }
.plan-head h2 { margin: 4px 0 2px; font-size: 26px; letter-spacing: .2px; }
.plan-head p { margin: 0; color: var(--muted); }
.facts { display: flex; gap: 30px; margin-left: auto; }
.facts div { text-align: right; }
.facts b { display: block; font-family: var(--num); font-size: 32px; font-weight: 700; line-height: 1; }
.facts span { color: var(--muted); font-size: 12px; }

table.grid { width: 100%; border-collapse: collapse; table-layout: fixed; }
.grid th { text-align: left; font-weight: 500; color: var(--faint); font-size: 12px; letter-spacing: .3px; padding: 10px 12px; border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); white-space: nowrap; }
.grid td { padding: 14px 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.grid tbody tr { transition: background .2s; animation: reveal .6s var(--ease) both; animation-delay: calc(var(--i, 0) * 50ms + 120ms); }
.grid tbody tr:last-child td { border-bottom: 0; }
.grid tbody tr:hover { background: var(--hover); }
.grid .c-idx { width: 60px; padding-left: 22px; }
.grid .c-idx span { display: inline-grid; place-content: center; width: 28px; height: 28px; border-radius: 8px; background: var(--hover); font-family: var(--num); font-weight: 800; font-size: 13px; color: var(--muted); transition: background .25s, color .25s, transform .35s var(--spring); }
.grid tr:hover .c-idx span { background: #131614; color: #fff; transform: rotate(-6deg); }
.grid .c-num { width: 104px; text-align: right; padding-right: 16px; padding-left: 4px; white-space: nowrap; }
.grid th.c-num { text-align: right; }
.grid .c-mode { width: 104px; color: var(--ink-2); white-space: nowrap; font-size: 13px; }
.grid .mode-sub { display: block; color: var(--faint); font-size: 12px; }
.grid .name { font-weight: 600; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grid .note { color: var(--faint); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.grid .unit { color: var(--faint); font-size: 12px; margin-left: 2px; }
.stepper { display: inline-flex; align-items: center; }
.stepper button { width: 20px; height: 20px; border-radius: 50%; display: grid; place-content: center; color: var(--muted); opacity: 0; transform: scale(.6); transition: opacity .2s, transform .3s var(--spring), background .15s, color .15s; font-size: 15px; line-height: 1; }
.stepper button:hover { background: #131614; color: #fff; }
tr:hover .stepper button, .stepper:focus-within button { opacity: 1; transform: none; }
.cell { width: 40px; height: 30px; border: 1px solid transparent; border-radius: 8px; background: transparent; padding: 0 2px; text-align: center;
  font-family: var(--num); font-weight: 700; font-size: 18px; transition: border-color .15s, background .15s, box-shadow .2s; -moz-appearance: textfield; }
.cell::-webkit-outer-spin-button, .cell::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.cell:hover { border-color: var(--line); background: var(--panel); }
.cell:focus { border-color: var(--green); background: var(--panel); outline: none; box-shadow: 0 0 0 4px rgba(36, 199, 137, .16); }
.cell.saved { animation: saved .9s var(--ease); }
@keyframes saved { 0% { background: var(--green-soft); border-color: var(--green); transform: scale(1.12); } }
.dash-text { font-family: var(--num); font-weight: 700; font-size: 18px; color: var(--faint); }
.table-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 22px; border-top: 1px solid var(--line-2); color: var(--muted); font-size: 13px; }
.restday { padding: 30px 22px 34px; color: var(--ink-2); line-height: 2; font-size: 15px; }

/* ── side widgets ────────────────────────────────────────── */
.kpis { display: grid; grid-template-columns: 1fr 1fr; padding: 0 20px; }
.kpis b { display: block; font-family: var(--num); font-size: 42px; font-weight: 700; line-height: 1; letter-spacing: -.5px; }
.kpis span { color: var(--muted); font-size: 12px; }
.bars { display: grid; grid-template-columns: repeat(7, 1fr); align-items: end; gap: 8px; height: 100px; padding: 20px 20px 0; }
.bars .col { position: relative; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; }
.bars .col::before { content: ""; position: absolute; inset: 0 -4px; }
.bars .bar { width: min(100%, 22px); border-radius: 4px 4px 0 0; background: var(--green); transform-origin: bottom; animation: grow-y .8s var(--ease) both; animation-delay: calc(var(--i) * 60ms + 200ms); transition: background .2s; }
.bars .bar.zero { background: var(--line); height: 2px !important; border-radius: 1px; }
.bars .col:hover .bar { background: var(--green-d); }
.bars .col:hover .bar.zero { background: var(--faint); }
@keyframes grow-y { from { transform: scaleY(0); } }
.bars-x { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; padding: 8px 20px 18px; border-top: 1px solid var(--line-2); font-size: 11.5px; color: var(--faint); text-align: center; }
.bars-x .today { color: var(--ink); font-weight: 700; }
.heat { display: grid; grid-auto-flow: column; grid-template-rows: repeat(7, 1fr); grid-auto-columns: 1fr; gap: 3px; }
.heat i { aspect-ratio: 1; border-radius: 3px; background: var(--line-2); transition: transform .2s var(--spring), box-shadow .2s; }
.heat i:hover { transform: scale(1.35); box-shadow: 0 0 0 2px var(--panel), 0 2px 8px rgba(0, 0, 0, .2); position: relative; z-index: 1; }
.heat i.l1 { background: #a6e6ca; }
.heat i.l2 { background: #5ed3a4; }
.heat i.l3 { background: var(--green); }
.heat i.l4 { background: var(--green-d); }
.heat i.off { background: #dfe2dc; }
.heat i.future { background: transparent; pointer-events: none; }
.legend { display: flex; justify-content: space-between; align-items: center; gap: 4px; margin-top: 10px; color: var(--faint); font-size: 11.5px; }
.legend span { display: inline-flex; align-items: center; gap: 3px; }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.feed { list-style: none; margin: 0; padding: 0 0 6px; }
.feed li { display: flex; align-items: center; gap: 12px; padding: 11px 20px; transition: background .2s; }
.feed li:hover { background: var(--hover); }
.feed .badge { width: 32px; height: 32px; border-radius: 10px; display: grid; place-content: center; font-family: var(--num); font-weight: 800; background: var(--green-soft); color: var(--green-d); flex: none; }
.feed .badge.off { background: var(--hover); color: var(--muted); }
.feed .t { flex: 1; min-width: 0; }
.feed .t b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed .t span { color: var(--faint); font-size: 12px; }
.feed em { font-style: normal; font-family: var(--num); font-weight: 700; font-size: 15px; color: var(--ink-2); }
.empty { padding: 26px 20px 30px; color: var(--muted); text-align: center; }

#tip { position: fixed; z-index: 70; pointer-events: none; background: #131614; color: #fff; font-size: 12px; padding: 6px 10px; border-radius: 8px; white-space: nowrap;
  transform: translate(-50%, calc(-100% - 10px)) scale(.92); opacity: 0; transition: opacity .15s, transform .2s var(--ease); left: 0; top: 0; }
#tip.show { opacity: 1; transform: translate(-50%, calc(-100% - 10px)); }
#tip b { font-family: var(--num); font-size: 13px; margin-left: 4px; }

/* ── history ─────────────────────────────────────────────── */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin: 18px 0 26px; }
.page-head h1 { margin: 0; font-size: clamp(32px, 3.6vw, 48px); letter-spacing: -.3px; line-height: 1.1; animation: reveal .7s var(--ease) both; }
.page-head p { margin: 8px 0 0; color: var(--muted); animation: reveal .7s var(--ease) .08s both; }
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); margin-bottom: 24px; }
.stat-row div { padding: 22px 24px; }
.stat-row div + div { border-left: 1px solid var(--line-2); }
.stat-row b { display: block; font-family: var(--num); font-size: 46px; font-weight: 700; line-height: 1; letter-spacing: -.5px; }
.stat-row b.g { color: var(--green-d); }
.stat-row span { display: block; margin-top: 8px; color: var(--muted); font-size: 12.5px; }
.grid .c-date { width: 200px; color: var(--ink-2); white-space: nowrap; padding-left: 22px; }
.grid .c-dur { width: 120px; text-align: right; font-family: var(--num); font-weight: 700; font-size: 17px; padding-right: 22px; }
.pill-tag { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; white-space: nowrap; }
.pill-tag i { width: 26px; height: 26px; border-radius: 8px; display: grid; place-content: center; font-style: normal; font-family: var(--num); font-weight: 800; font-size: 13px; background: var(--green-soft); color: var(--green-d); flex: none; }
.pill-tag.off i { background: var(--hover); color: var(--muted); }
.sub-note { color: var(--faint); font-size: 12px; margin-left: 10px; }

/* ── settings ────────────────────────────────────────────── */
.form { display: grid; gap: 24px; max-width: 900px; }
.field { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px; padding: 18px 22px; border-top: 1px solid var(--line-2); align-items: center; }
.field b { font-weight: 600; }
.field p { margin: 3px 0 0; color: var(--muted); font-size: 12.5px; }
.seg { position: relative; display: inline-flex; padding: 3px; border-radius: 999px; background: var(--hover); box-shadow: inset 0 0 0 1px var(--line-2); }
.seg button { position: relative; z-index: 1; padding: 6px 16px; border-radius: 999px; color: var(--muted); font-weight: 500; transition: color .25s; }
.seg button.on { color: var(--ink); font-weight: 600; }
.seg .knob { position: absolute; top: 3px; bottom: 3px; border-radius: 999px; background: var(--panel); box-shadow: 0 1px 3px rgba(19, 22, 20, .14); transition: left .45s var(--ease), width .45s var(--ease); }
.toggle { display: inline-flex; align-items: center; gap: 12px; color: var(--muted); }
.toggle i { width: 42px; height: 24px; border-radius: 12px; background: #cfd3cc; position: relative; transition: background .25s; }
.toggle i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 9px; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); transition: transform .35s var(--spring), width .2s; }
.toggle:active i::after { width: 22px; }
.toggle.on i { background: var(--green); }
.toggle.on i::after { transform: translateX(18px); }
.toggle.on:active i::after { transform: translateX(14px); }
.keys-table { display: grid; grid-template-columns: max-content 1fr; gap: 12px 18px; align-items: center; color: var(--ink-2); padding: 18px 22px; border-top: 1px solid var(--line-2); }
.keys-table kbd { justify-self: start; }

/* ── training: dark stage ────────────────────────────────── */
body.dark { --panel: #141917; --line: #232a26; --line-2: #1c2220; --ink: #eef2ef; --ink-2: #c9d0cb; --muted: #8a938d; --faint: #5f6863; --hover: #1b211e;
  --shadow: 0 1px 0 rgba(255, 255, 255, .02); background: #0a0d0c; }
body.dark .site { background: rgba(10, 13, 12, .78); }
body.dark kbd { background: #1b211e; border-color: #2b332f; color: #9aa39e; }
body.dark .btn { background: #eef2ef; color: #0a0d0c; }
body.dark .btn.go { background: var(--green); color: #06251a; }
body.dark .btn.line { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px #2b332f; }
body.dark .btn.line:hover { background: #1b211e; }
body.dark .btn.ghost { background: transparent; color: var(--muted); }
body.dark .btn.ghost:hover { background: #1b211e; color: var(--ink); }
body.dark .btn kbd { background: rgba(0, 0, 0, .1); border-color: rgba(0, 0, 0, .18); color: inherit; }
body.dark .btn.line kbd, body.dark .btn.ghost kbd { background: #1b211e; border-color: #2b332f; color: #9aa39e; }
body.dark .logo img { box-shadow: 0 0 0 1px #232a26; }
.train { max-width: var(--wrap); margin: 0 auto; padding: 18px 28px 40px; display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 24px; align-items: start; }
.crumbs { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13.5px; }
.crumbs a { transition: color .2s; }
.crumbs a:hover { color: var(--ink); }
.crumbs .sep { color: var(--faint); }
.crumbs b { color: var(--ink); font-weight: 600; }
.crumbs .right { margin-left: auto; font-family: var(--num); font-weight: 700; font-size: 15px; color: var(--ink-2); letter-spacing: .5px; }
.progress { grid-column: 1 / -1; position: relative; height: 4px; border-radius: 2px; background: #1c2220; }
.progress i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; border-radius: 2px; background: var(--green); box-shadow: 0 0 12px rgba(36, 199, 137, .6); transition: width .3s linear; }
.stage { position: relative; min-height: min(640px, calc(100vh - 210px)); display: flex; flex-direction: column; overflow: hidden; border-radius: 22px; }
.stage::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(700px 420px at 50% 45%, rgba(36, 199, 137, .08), transparent 70%); transition: opacity .6s; }
.stage.paused::before { background: radial-gradient(700px 420px at 50% 45%, rgba(242, 169, 59, .07), transparent 70%); }
.stage-h { position: relative; display: flex; align-items: center; gap: 14px; padding: 22px 26px 0; }
.stage-h h2 { margin: 0; font-size: 24px; white-space: nowrap; letter-spacing: .3px; }
.stage-h span { color: var(--muted); white-space: nowrap; }
.chip { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; padding: 5px 12px; border-radius: 999px; background: rgba(36, 199, 137, .12); color: var(--green); white-space: nowrap; }
.chip i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; animation: live 2s ease-in-out infinite; }
.chip.paused { background: rgba(242, 169, 59, .14); color: var(--amber); }
.chip.paused i { animation: none; }
.chip.rest { background: rgba(255, 255, 255, .06); color: var(--ink-2); }
.stage-b { position: relative; flex: 1; display: grid; place-content: center; justify-items: center; text-align: center; padding: 20px 26px; }
.big { position: relative; font-family: var(--num); font-weight: 800; font-size: clamp(150px, 19vw, 290px); line-height: 1; letter-spacing: -4px; font-variant-numeric: tabular-nums; height: 1em; overflow: hidden; display: flex; justify-content: center; min-width: 1.2em; }
.big.time { font-size: clamp(100px, 12.5vw, 190px); letter-spacing: -2px; }
.big .v { display: block; }
.big .v.in { animation: roll-in .45s var(--ease) both; }
.big .v.out { position: absolute; left: 0; right: 0; top: 0; animation: roll-out .45s var(--ease) both; }
@keyframes roll-in { from { transform: translateY(60%); opacity: 0; filter: blur(4px); } }
@keyframes roll-out { to { transform: translateY(-60%); opacity: 0; filter: blur(4px); } }
.big-unit { margin-top: 10px; font-size: 18px; color: var(--muted); }
.big-cue { margin-top: 8px; font-size: 16px; color: var(--green); font-weight: 600; min-height: 26px; letter-spacing: .5px; }
.track { position: relative; margin: 0 26px 26px; display: flex; gap: 4px; height: 8px; }
.track i { flex: 1; border-radius: 4px; background: #212824; overflow: hidden; position: relative; }
.track i b { position: absolute; inset: 0; width: 0; background: var(--green); border-radius: 4px; }
.track i.done b { width: 100%; }
.track i.done:last-child b, .track i.flash b { animation: seg-flash .5s ease; }
@keyframes seg-flash { 0% { box-shadow: 0 0 14px rgba(36, 199, 137, .9); } }
.count3 { position: absolute; inset: 0; display: grid; place-content: center; pointer-events: none; z-index: 2; }
.count3 b { font-family: var(--num); font-weight: 800; font-size: clamp(200px, 26vw, 360px); line-height: 1; color: var(--green); text-shadow: 0 0 60px rgba(36, 199, 137, .35); animation: pop .95s var(--ease) both; }
@keyframes pop { 0% { opacity: 0; transform: scale(1.7); filter: blur(10px); } 30% { opacity: 1; transform: scale(1); filter: blur(0); } 78% { opacity: 1; } 100% { opacity: 0; transform: scale(.88); filter: blur(4px); } }
.ring { position: relative; width: min(360px, 44vh); aspect-ratio: 1; margin: 0 auto; }
.ring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.ring .trk { stroke: #1f2622; stroke-width: 6; }
.ring .prog { stroke: url(#ringGrad); stroke-width: 6; transition: stroke-dashoffset .3s linear; filter: drop-shadow(0 0 8px rgba(36, 199, 137, .5)); }
.ring .breath { position: absolute; inset: 14%; border-radius: 50%; background: radial-gradient(circle, rgba(36, 199, 137, .2), rgba(36, 199, 137, .04) 70%); box-shadow: inset 0 0 0 1px rgba(36, 199, 137, .28);
  animation: breathe 8s ease-in-out infinite; animation-delay: var(--bd, 0s); }
@keyframes breathe { 0%, 100% { transform: scale(.76); } 50% { transform: scale(1); } }
.ring .val { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring .val b { font-family: var(--num); font-weight: 800; font-size: min(116px, 13vh); line-height: 1; color: var(--ink); letter-spacing: -2px; font-variant-numeric: tabular-nums; }
.ring .val span { margin-top: 8px; color: var(--green); font-weight: 600; letter-spacing: 4px; font-size: 14px; }
.next-up { margin: 30px auto 0; display: inline-flex; align-items: center; gap: 14px; padding: 12px 20px 12px 12px; border-radius: 16px; background: #1a201d; text-align: left; }
.next-up i { width: 42px; height: 42px; border-radius: 12px; display: grid; place-content: center; font-style: normal; font-family: var(--num); font-weight: 800; font-size: 18px; background: var(--green); color: #06251a; }
.next-up small { display: block; color: var(--muted); font-size: 12px; }
.next-up b { font-size: 17px; }
.paused-b .pz { font-family: var(--num); font-weight: 800; font-size: clamp(110px, 12vw, 170px); line-height: 1; color: var(--amber); letter-spacing: -2px; }
.paused-b p { margin: 20px 0 0; font-size: 19px; color: var(--ink-2); }
.paused-b small { display: block; margin-top: 6px; color: var(--muted); }
.ctrl { position: relative; display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-top: 1px solid var(--line-2); flex-wrap: wrap; }
.ctrl .grow { flex: 1; }
.notice { position: relative; margin: 16px 26px 0; padding: 10px 14px; border-radius: 10px; background: rgba(242, 169, 59, .12); color: var(--amber); font-size: 13px; }
.flow ol { list-style: none; margin: 0; padding: 4px 0 10px; }
.flow li { position: relative; display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; padding: 12px 20px; align-items: start; transition: background .3s; }
.flow li::before { content: ""; position: absolute; left: 34px; top: 42px; bottom: -12px; width: 1px; background: var(--line); }
.flow li:last-child::before { display: none; }
.flow li.cur { background: rgba(36, 199, 137, .07); }
.flow li .n { position: relative; z-index: 1; width: 28px; height: 28px; border-radius: 50%; display: grid; place-content: center; font-family: var(--num); font-weight: 800; font-size: 13px; background: var(--hover); color: var(--muted); transition: background .3s, color .3s; }
.flow li.done .n { background: var(--green); color: #06251a; }
.flow li.cur .n { background: var(--panel); color: var(--green); box-shadow: inset 0 0 0 2px var(--green); }
.flow li b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.flow li.done b { color: var(--muted); }
.flow .meta { color: var(--muted); font-size: 12px; }
.flow .sets { display: flex; gap: 4px; margin-top: 8px; flex-wrap: wrap; }
.flow .sets i { width: 20px; height: 5px; border-radius: 3px; background: var(--line); transition: background .3s; }
.flow .sets i.done { background: var(--green); }
.flow .sets i.cur { background: var(--green-l); animation: blink 1.4s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .35; } }
.shortcut-list { display: grid; grid-template-columns: max-content 1fr; gap: 10px 14px; padding: 2px 20px 18px; color: var(--muted); font-size: 13px; align-items: center; }
.shortcut-list kbd { justify-self: start; }

/* ── finish ──────────────────────────────────────────────── */
.finish { position: relative; max-width: 780px; margin: 56px auto; padding: 0 28px; text-align: center; }
.burst { position: relative; width: 140px; height: 140px; margin: 0 auto 24px; }
.burst .ok { position: absolute; inset: 28px; border-radius: 50%; background: var(--green); color: #06251a; display: grid; place-content: center; animation: ok-in .6s var(--spring) both; box-shadow: 0 18px 40px -16px rgba(36, 199, 137, .8); }
.burst .ok svg { width: 40px; height: 40px; stroke-width: 3; }
.burst .ok path { stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw-line .5s var(--ease) .35s forwards; }
.burst i { position: absolute; left: 50%; top: 50%; width: 3px; height: 14px; margin: -7px 0 0 -1.5px; border-radius: 2px; background: var(--green); opacity: 0;
  transform: rotate(var(--a)) translateY(-30px); animation: spark .9s var(--ease) .3s both; }
.burst i:nth-child(odd) { background: var(--amber); height: 9px; }
@keyframes spark { 0% { opacity: 0; transform: rotate(var(--a)) translateY(-34px) scaleY(.3); } 30% { opacity: 1; } 100% { opacity: 0; transform: rotate(var(--a)) translateY(-78px) scaleY(1); } }
@keyframes ok-in { from { transform: scale(.2); opacity: 0; } }
.finish h1 { margin: 0; font-size: clamp(36px, 4.4vw, 56px); letter-spacing: -.3px; animation: reveal .7s var(--ease) .2s both; }
.finish .lede { color: var(--muted); margin: 10px 0 0; animation: reveal .7s var(--ease) .28s both; }
.finish .stat-row { margin: 38px 0 30px; grid-template-columns: repeat(3, 1fr); text-align: left; animation: reveal .7s var(--ease) .36s both; }
.finish .acts { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; animation: reveal .7s var(--ease) .44s both; }

/* ── modal + toast ───────────────────────────────────────── */
.scrim { position: fixed; inset: 0; z-index: 50; background: rgba(10, 13, 12, .42); backdrop-filter: blur(3px); display: grid; place-items: center; animation: fade .2s ease both; padding: 16px; }
@keyframes fade { from { opacity: 0; } }
.modal { width: min(440px, 100%); background: #fff; color: #131614; border-radius: 18px; box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .45); animation: modal-in .35s var(--spring) both; overflow: hidden; }
@keyframes modal-in { from { opacity: 0; transform: translateY(14px) scale(.96); } }
.modal h3 { margin: 0; padding: 24px 24px 6px; font-size: 18px; }
.modal p { margin: 0; padding: 0 24px 22px; color: #6b716d; }
.modal .acts { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 18px; border-top: 1px solid #eef0ec; background: #fafbf8; }
.modal .btn { background: #131614; color: #fff; }
.modal .btn.line { background: transparent; color: #131614; box-shadow: inset 0 0 0 1px #e3e5e0; }
.modal .btn.danger { background: var(--danger); color: #fff; }
#toast { position: fixed; left: 50%; bottom: 28px; z-index: 60; display: flex; align-items: center; gap: 10px; transform: translate(-50%, 24px); opacity: 0; pointer-events: none;
  background: #131614; color: #fff; padding: 10px 18px 10px 12px; border-radius: 999px; font-size: 13px; box-shadow: 0 12px 30px -12px rgba(0, 0, 0, .5); transition: opacity .25s, transform .45s var(--spring); }
#toast::before { content: ""; width: 18px; height: 18px; border-radius: 50%; background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2306251a' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 12px no-repeat; }
#toast.show { opacity: 1; transform: translate(-50%, 0); }
#toast.show.act { pointer-events: auto; }
#toast button { margin: -4px -8px -4px 4px; padding: 4px 8px; border-radius: 999px; color: var(--green); font-weight: 600; }
#toast button:hover { background: rgba(255, 255, 255, .1); }
#toast.err::before { background: var(--danger) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.5' stroke-linecap='round'%3E%3Cpath d='M12 6v7M12 18v.01'/%3E%3C/svg%3E") center / 12px no-repeat; }

/* ── responsive ──────────────────────────────────────────── */
@media (max-width: 1100px) {
  .cols, .train { grid-template-columns: minmax(0, 1fr); }
  .glyph { width: 240px; }
  .glyph b { font-size: 250px; }
  .tempo { width: 300px; }
}
@media (max-width: 860px) {
  .hero { padding: 30px 26px 0; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .glyph { display: none; }
  .hero-week { margin: 28px -26px 0; }
  .hero-week > div { padding: 12px 8px 14px; }
  .hero-week > div:first-child { padding-left: 26px; }
  .hero-week .t span { display: none; }
  .facts { margin-left: 0; }
  .grid .c-mode { display: none; }
  .stat-row { grid-template-columns: 1fr 1fr; }
  .stat-row div:nth-child(3) { border-left: 0; }
  .stat-row div:nth-child(n+3) { border-top: 1px solid var(--line-2); }
  .finish .stat-row { grid-template-columns: repeat(3, 1fr); }
  .finish .stat-row div:nth-child(3) { border-left: 1px solid var(--line-2); border-top: 0; }
}
@media (max-width: 640px) {
  .site-in { gap: 14px; padding: 0 16px; }
  .site-act .hint, .site-act kbd { display: none; }
  .nav a { padding: 0 9px; }
  .page, .train { padding: 14px 14px 56px; }
  .hero { border-radius: 18px; padding: 26px 20px 0; }
  .hero-week { margin: 24px -20px 0; }
  .hero-week > div:first-child { padding-left: 12px; }
  .hero .acts .btn { flex: 1; }
  .field { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  table.plan colgroup, table.plan thead { display: none; }
  table.plan, table.plan tbody { display: block; }
  table.plan tr { display: grid; grid-template-columns: 44px repeat(4, minmax(0, 1fr)); align-items: center; padding: 10px 8px; border-bottom: 1px solid var(--line-2); }
  table.plan td { border: 0; padding: 4px; width: auto; text-align: center; }
  table.plan td.c-idx { grid-row: span 2; padding-left: 6px; }
  table.plan td:nth-child(2) { grid-column: 2 / -1; text-align: left; }
  .grid .c-date { width: 118px; }
  .stage { border-radius: 18px; min-height: 500px; }
  .stage-h { flex-wrap: wrap; padding: 18px 18px 0; }
  .ctrl .btn.lg { flex: 1; }
  .facts { gap: 22px; }
}
@media (hover: none), (max-width: 640px) { .stepper button { display: none; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
  ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
}

/* ── refinements after review ───────────────────────────── */
.logo span, .nav a { white-space: nowrap; }
.grid th.c-dur { font-family: inherit; font-size: 12px; font-weight: 500; }
.heat-wide { margin-bottom: 24px; }
.heat-wide .heat { gap: 4px; }
.heat-wide .heat i { border-radius: 4px; }
@media (max-width: 640px) {
  .logo span { display: none; }
  .site-in { gap: 10px; }
  .hero-week .dt { display: none; }
  .hero-week small { text-align: center; }
  .hero-week .t { justify-content: center; }
  .section-t { flex-wrap: wrap; gap: 4px 12px; margin-top: 32px; }
  table.plan td.c-num::after { content: attr(data-l); display: block; font-size: 11px; color: var(--faint); margin-top: -2px; }
  .table-foot { flex-direction: column; align-items: flex-start; }
  .heat-wide .heat { gap: 2px; }
  .heat-wide .heat i { border-radius: 2px; }
}

@media (max-width: 640px) {
  .ctrl .btn.lg { flex: 1 1 100%; }
  .train > .stack > .panel:last-child { display: none; }
}
@media (hover: none) { .btn kbd, .site-act kbd, .hero kbd { display: none; } .train > .stack > .panel:last-child { display: none; } }
.grid th.c-mode { color: var(--faint); font-size: 12px; }
/* figures that tick or count up keep their width, like the app's NumTxt (tnum) */
.crumbs .right, .kpis b, .stat-row b, .facts b, .feed em, .bars .v, .grid .c-dur, .hero .lede b, .cell, .count3 b, .tabs a b,
.kring .val b, .macro > b, .w-now b, .res em, .res-sum > b, .ledger-k li b, .grid.items .c-k, .meal-h em .num { font-variant-numeric: tabular-nums; }
/* card-header links get a ~40px tap area without moving */
.panel-h .link { padding: 10px 12px; margin: -10px -12px; background-origin: content-box; background-clip: content-box; }
.more-days { display: block; width: 100%; padding: 14px 0; border-top: 1px solid var(--line-2); border-radius: 0 0 var(--r) var(--r); color: var(--green-d); font-weight: 600; font-size: 13.5px; text-align: center; transition: background .2s; }
.more-days:hover { background: var(--hover); }

/* ── food: energy hero, meals, coach, weight, recognition ──
   Same hero, panels, steppers and motion as the plan page; the ring is the rest-timer ring. */
.food-hero .hero-grid { grid-template-columns: minmax(0, 1fr) 232px; align-items: center; }
.food-hero h1 em { font-family: var(--num); font-weight: 800; letter-spacing: -1px; margin: 0 .08em; }
.kring { position: relative; width: 232px; aspect-ratio: 1; margin: -6px 0; animation: glyph 1.1s var(--ease) both .15s; }
.kring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.kring .trk { stroke: rgba(255, 255, 255, .08); stroke-width: 12; fill: none; }
.kring .prog { stroke: url(#kGrad); stroke-width: 12; fill: none; stroke-linecap: round; transition: stroke-dashoffset 1.4s var(--ease) .25s; filter: drop-shadow(0 0 10px rgba(36, 199, 137, .45)); }
.kring .prog.over { stroke: var(--amber); filter: drop-shadow(0 0 10px rgba(242, 169, 59, .45)); }
.kring .val { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.kring .val b { font-family: var(--num); font-weight: 800; font-size: 64px; line-height: 1; letter-spacing: -1.5px; }
.kring .val span { margin-top: 4px; color: rgba(241, 244, 242, .55); font-size: 12.5px; letter-spacing: .5px; }
.macros { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; margin: 26px 0 0; animation: reveal .8s var(--ease) .5s both; }
.macro { display: grid; grid-template-columns: 1fr auto; align-items: baseline; row-gap: 8px; }
.macro > span { color: rgba(241, 244, 242, .6); font-size: 13px; }
.macro > b { font-family: var(--num); font-size: 22px; font-weight: 700; }
.macro > b small { font-size: 13px; color: rgba(241, 244, 242, .45); font-weight: 600; }
.macro i { grid-column: 1 / -1; height: 6px; border-radius: 3px; background: rgba(255, 255, 255, .08); overflow: hidden; }
.macro i b { display: block; height: 100%; width: 0; border-radius: 3px; background: var(--green); transition: width 1.2s var(--ease) .45s; }
.macro.f i b { background: var(--amber); }
.macro.c i b { background: var(--green-l); }
.food-hero .acts { margin-top: 26px; }
.food-hero .lede .nw { white-space: nowrap; }
.hero-week .low i { box-shadow: inset 0 0 0 1.5px rgba(242, 169, 59, .8); color: var(--amber); }
.hero-week .none i { background: rgba(255, 255, 255, .06); color: rgba(255, 255, 255, .35); }
.hero-week .none { color: rgba(241, 244, 242, .4); font-weight: 500; }
.hero-week .t span small { font-family: var(--num); color: rgba(241, 244, 242, .4); font-weight: 600; }
.hero-week .done span, .hero-week .low span { font-family: var(--num); font-size: 14px; }

/* meals */
.meal { padding: 6px 0 12px; border-top: 1px solid var(--line-2); animation: reveal .6s var(--ease) both; animation-delay: calc(var(--i, 0) * 70ms + 100ms); }
.meal-h { display: flex; align-items: center; gap: 12px; padding: 12px 16px 6px 22px; }
.slot-tag { width: 32px; height: 32px; border-radius: 10px; display: grid; place-content: center; background: var(--green-soft); color: var(--green-d); font-weight: 700; flex: none; }
.meal-h .t { flex: 1; min-width: 0; }
.meal-h .t b { display: block; font-weight: 600; }
.meal-h .t span { color: var(--faint); font-size: 12px; }
.meal-h em { font-style: normal; color: var(--muted); font-size: 13px; }
.meal-h em .num { font-weight: 700; font-size: 20px; color: var(--ink); margin-right: 2px; }
.icon-btn { width: 32px; height: 32px; border-radius: 50%; display: grid; place-content: center; color: var(--faint); transition: background .2s, color .2s, transform .3s var(--spring); flex: none; }
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn:hover { background: var(--hover); color: var(--danger); transform: rotate(90deg); }
.grid.items td { padding: 8px 12px; border: 0; }
.grid.items tbody tr:hover { background: var(--hover); }
.grid.items td:first-child { padding-left: 66px; }
.grid.items .name { font-size: 14.5px; font-weight: 500; }
.grid.items .c-g { width: 128px; white-space: nowrap; text-align: right; }
.grid.items .c-k { width: 64px; text-align: right; font-weight: 700; font-size: 16px; }
.grid.items .c-m { width: 196px; color: var(--faint); font-size: 12px; white-space: nowrap; padding-right: 22px; text-align: right; }
.grid.items .cell { width: 52px; }
@media (hover: none), (max-width: 640px) { .grid.items .cell { text-align: right; padding-right: 2px; } }
.ai-note { position: relative; margin: 6px 22px 2px 66px; padding: 8px 12px 8px 30px; border-radius: 10px; background: var(--green-soft); color: var(--green-d); font-size: 13px; }
.ai-note::before { content: ""; position: absolute; left: 12px; top: 14px; width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(36, 199, 137, .2); }
.food-empty { display: grid; justify-items: center; gap: 14px; padding: 34px 20px 38px; text-align: center; color: var(--muted); border-top: 1px solid var(--line-2); }
.food-empty p { margin: 0; line-height: 1.8; }
.plate { position: relative; width: 84px; height: 84px; border-radius: 50%; background: var(--hover); box-shadow: inset 0 0 0 10px var(--panel), inset 0 0 0 11px var(--line); }
.plate i { position: absolute; inset: 26px; border-radius: 50%; border: 2px dashed var(--faint); animation: spin 12s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.usual { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 14px 22px 18px; border-top: 1px solid var(--line-2); }
.usual > span { color: var(--muted); font-size: 12.5px; margin-right: 4px; }
.food-chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px 0 8px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); font-size: 13px; font-weight: 500; transition: background .2s, box-shadow .2s, transform .2s var(--ease); }
.food-chip svg { width: 14px; height: 14px; color: var(--green-d); }
.food-chip small { color: var(--faint); font-family: var(--num); font-size: 12px; }
.food-chip:hover { background: var(--panel); box-shadow: inset 0 0 0 1px var(--green), 0 6px 14px -10px rgba(36, 199, 137, .7); transform: translateY(-1px); }

/* coach */
.ledger { display: flex; gap: 3px; height: 14px; margin: 2px 20px 0; }
.ledger i { min-width: 6px; border-radius: 4px; transform-origin: left; animation: grow-x .9s var(--ease) both; animation-delay: calc(var(--i) * 90ms + 250ms); transition: filter .2s; }
.ledger i:hover { filter: brightness(1.1) saturate(1.2); }
@keyframes grow-x { from { transform: scaleX(0); } }
.k-bmr { background: #3a3f3c; }
.k-life { background: #a1a6a2; }
.k-train { background: var(--green-l); }
.k-plus { background: var(--green); }
.ledger-k { list-style: none; margin: 14px 0 0; padding: 0 20px; }
.ledger-k li { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto; gap: 10px; align-items: baseline; padding: 6px 0; }
.ledger-k li i { width: 10px; height: 10px; border-radius: 3px; transform: translateY(1px); }
.ledger-k li span { font-size: 13.5px; }
.ledger-k li small { display: block; color: var(--faint); font-size: 11.5px; line-height: 1.4; }
.ledger-k li b { font-size: 17px; font-weight: 700; }
.ledger-k .sum { grid-template-columns: minmax(0, 1fr) auto; border-top: 1px solid var(--line-2); margin-top: 6px; padding-top: 10px; }
.ledger-k .sum span { font-weight: 600; }
.ledger-k .sum b { font-size: 24px; color: var(--green-d); }
.tips { list-style: none; margin: 10px 0 0; padding: 12px 20px 4px; border-top: 1px solid var(--line-2); }
.tips li { position: relative; padding: 5px 0 5px 18px; color: var(--ink-2); font-size: 13.5px; animation: reveal .6s var(--ease) both; animation-delay: calc(var(--i) * 80ms + 400ms); }
.tips li::before { content: ""; position: absolute; left: 2px; top: 13px; width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.tips li:first-child { font-weight: 600; color: var(--ink); }
.macro-goal { padding: 8px 20px 18px; color: var(--muted); font-size: 12.5px; }
.macro-goal b { color: var(--ink); font-size: 15px; }

/* weight */
.w-now { display: flex; align-items: baseline; gap: 8px; padding: 0 20px; }
.w-now b { font-size: 42px; font-weight: 700; line-height: 1; letter-spacing: -.5px; }
.w-now span { color: var(--muted); font-size: 12.5px; }
.sub-note b.ok { color: var(--green-d); }
.sub-note b.warn { color: var(--amber); }
svg.w-line { display: block; width: calc(100% - 24px); height: 100px; margin: 14px 12px 0; overflow: visible; }
.w-line .area { fill: url(#wFill); stroke: none; animation: fade 1s ease .5s both; }
.w-line .ln { stroke: var(--green); stroke-width: 2.5; fill: none; vector-effect: non-scaling-stroke; stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw-line 1.4s var(--ease) .2s forwards; }
.w-line circle { fill: var(--panel); stroke: var(--green); stroke-width: 2; vector-effect: non-scaling-stroke; transition: r .2s var(--spring); }
.w-line circle:hover { r: 5; }
div.w-line.empty { margin: 12px 20px 0; padding: 26px 0; text-align: center; color: var(--faint); font-size: 12.5px; border: 1px dashed var(--line); border-radius: 10px; }
.w-axis { display: flex; justify-content: space-between; padding: 4px 20px 0; color: var(--faint); font-size: 11px; }
.w-in { display: flex; align-items: center; gap: 6px; padding: 14px 20px 4px; }
.w-in .cell { width: 64px; height: 38px; border-color: var(--line); background: var(--panel); }
.w-in .btn { margin-left: auto; }
.w-hint { margin: 6px 20px 16px; color: var(--faint); font-size: 12px; }
.notes-text { padding: 0 20px 18px; color: var(--ink-2); font-size: 13.5px; line-height: 1.75; white-space: pre-wrap; }
.notes-empty { margin: 0; padding: 0 20px 18px; color: var(--muted); font-size: 13px; line-height: 1.7; }

/* intake bars: bar per day with a tick for that day's target */
.bars.kcal .bar.low { background: var(--amber); }
.bars.kcal .col:hover .bar.low { background: #d98f22; }
.bars .goal { position: absolute; left: 50%; width: min(100%, 30px); height: 2px; transform: translateX(-50%); background: var(--ink); border-radius: 1px; opacity: .55; animation: fade .6s ease both; animation-delay: calc(var(--i) * 60ms + 600ms); }

/* settings */
.body-in { display: flex; gap: 18px; flex-wrap: wrap; }
.body-in label { display: inline-flex; align-items: center; gap: 4px; }
.body-in .cell { width: 64px; height: 38px; border-color: var(--line); background: var(--panel); }
.body-in .cell.wide { width: 76px; }
.ai-state { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); }
.ai-state i { width: 8px; height: 8px; border-radius: 50%; background: var(--faint); }
.ai-state.on { color: var(--green-d); font-weight: 600; }
.ai-state.on i { background: var(--green); box-shadow: 0 0 0 4px rgba(36, 199, 137, .18); animation: live 2.4s ease-in-out infinite; }

/* recognition modal */
.modal.scan { width: min(560px, 100%); max-height: calc(100vh - 32px); overflow-y: auto; }
.modal .shot { position: relative; margin: 4px 24px 0; border-radius: 14px; overflow: hidden; background: #0e1210; aspect-ratio: 16 / 10; }
.modal .shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.modal .shot.done { aspect-ratio: 16 / 7; }
.modal.settled .res li, .modal.settled .shot { animation: none; }
.shot.scanning img { filter: saturate(.7) brightness(.8); }
.shot .beam { position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--green); box-shadow: 0 0 18px 4px rgba(36, 199, 137, .65); animation: beam 1.8s var(--ease) infinite alternate; }
.shot .beam::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 70px; background: linear-gradient(to top, rgba(36, 199, 137, .28), transparent); }
@keyframes beam { from { top: 0; } to { top: 100%; } }
.shot .grid-fx { position: absolute; inset: 0; background-image: linear-gradient(rgba(127, 220, 179, .12) 1px, transparent 1px), linear-gradient(90deg, rgba(127, 220, 179, .12) 1px, transparent 1px); background-size: 28px 28px; animation: fade .6s ease both; }
.modal p.scan-st { display: flex; align-items: center; gap: 10px; padding: 16px 24px 20px; margin: 0; }
.modal p.scan-err { padding: 16px 24px 22px; color: var(--danger); }
.dots { display: inline-flex; gap: 4px; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: blink 1.2s ease-in-out infinite; }
.dots i:nth-child(2) { animation-delay: .15s; }
.dots i:nth-child(3) { animation-delay: .3s; }
.res { list-style: none; margin: 14px 0 0; padding: 0 12px; }
.res li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto 52px 32px; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 10px; animation: reveal .5s var(--ease) both; animation-delay: calc(var(--i) * 70ms + 80ms); transition: background .2s; }
.res li:hover { background: #f3f4f0; }
.res .n { min-width: 0; }
.res .n b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.res .n small { display: block; color: #a1a6a2; font-size: 11.5px; }
.res .n small.unsure { display: inline-block; color: var(--amber); margin-right: 6px; }
.res em { font-style: normal; text-align: right; font-weight: 700; font-size: 17px; }
.res .stepper button { opacity: 1; transform: none; }
.res .cell { width: 54px; }
.modal .unit, .grid .unit { color: #a1a6a2; font-size: 12px; }
.res-sum { display: flex; align-items: baseline; gap: 8px; margin: 6px 24px 0; padding: 12px 0 4px; border-top: 1px solid #eef0ec; color: #6b716d; font-size: 13px; }
.res-sum > b { font-size: 34px; font-weight: 800; color: #131614; line-height: 1; letter-spacing: -.5px; }
.res-sum span b { color: #131614; font-size: 15px; }
.modal .ai-note { margin: 12px 24px 0; }
.slot-pick { display: flex; align-items: center; gap: 12px; padding: 16px 24px 20px; color: #6b716d; font-size: 13px; flex-wrap: wrap; }
.modal .seg { background: #f3f4f0; box-shadow: inset 0 0 0 1px #eef0ec; }
.modal .seg .knob { background: #fff; }
.modal .seg button { color: #6b716d; }
.modal .seg button.on { color: #131614; }
.modal .btn.go { background: var(--green); color: #06251a; }
.modal .btn:disabled { opacity: .8; cursor: progress; }
.ta { padding: 0 24px 20px; }
.ta textarea { width: 100%; resize: vertical; min-height: 88px; border: 1px solid #e3e5e0; border-radius: 12px; padding: 12px 14px; font: inherit; color: #131614; background: #fff; transition: border-color .15s, box-shadow .2s; }
.ta textarea:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 4px rgba(36, 199, 137, .16); }

@media (max-width: 1100px) { .food-hero .hero-grid { grid-template-columns: minmax(0, 1fr) 200px; } .kring { width: 200px; } }
@media (max-width: 860px) {
  .food-hero .hero-grid { grid-template-columns: minmax(0, 1fr) 150px; }
  .kring { width: 150px; }
  .kring .val b { font-size: 44px; }
  .grid.items .c-m { display: none; }
}
@media (max-width: 640px) {
  .food-hero h1 { font-size: 30px; }
  .food-hero .hero-grid { grid-template-columns: minmax(0, 1fr) 108px; gap: 12px; }
  .kring { width: 108px; margin: 0; }
  .kring .trk, .kring .prog { stroke-width: 14; }
  .kring .val b { font-size: 32px; }
  .kring .val span { font-size: 11px; }
  .macros { gap: 14px; margin-top: 20px; }
  .macro { grid-template-columns: 1fr; }
  .macro > b { font-size: 18px; }
  .macro > b small { display: block; font-size: 11px; }
  .hero-week .t span { display: none; }
  .meal-h { padding-left: 14px; }
  .grid.items td:first-child { padding-left: 14px; }
  .grid.items .c-g { width: 96px; padding: 8px 4px; }
  .ai-note { margin-left: 14px; margin-right: 14px; }
  .res li { grid-template-columns: minmax(0, 1fr) auto auto 44px 28px; gap: 2px; padding: 8px; }
  .res .stepper button { display: none; }
  .modal .shot { margin: 4px 16px 0; }
}

/* review card after a meal is saved: the model's comment, then where today stands (auto-hides after 8 s) */
#review { position: fixed; left: 50%; bottom: 24px; z-index: 60; width: min(460px, calc(100% - 32px)); padding: 14px 16px 16px; border-radius: 18px; overflow: hidden;
  background: #131614; color: #fff; box-shadow: 0 24px 50px -18px rgba(0, 0, 0, .55); cursor: pointer;
  transform: translate(-50%, 140%); opacity: 0; pointer-events: none; transition: transform .5s var(--spring), opacity .25s; }
#review.show { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
#review .rv-h { display: flex; align-items: center; gap: 10px; }
#review .rv-h b { flex: 1; font-size: 14px; font-weight: 600; }
#review .rv-ok { width: 20px; height: 20px; border-radius: 50%; flex: none; background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2306251a' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 12px no-repeat; }
#review .rv-x { display: grid; color: rgba(255, 255, 255, .45); }
#review .rv-x svg { width: 16px; height: 16px; }
#review .rv-note { margin: 10px 0 0 30px; color: rgba(255, 255, 255, .78); font-size: 13.5px; line-height: 1.6; }
#review .rv-status { margin: 6px 0 0 30px; color: var(--green-l); font-size: 13.5px; font-weight: 600; }
#review .rv-bar { position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: var(--green); transform-origin: left; opacity: .6; }
#review.show .rv-bar { animation: rv-time 8s linear both; }
@keyframes rv-time { to { transform: scaleX(0); } }
.meal.fresh { animation: reveal .6s var(--ease) both, fresh 2.4s ease .4s; }
@keyframes fresh { 0% { background: var(--green-soft); } 100% { background: transparent; } }
@media (max-width: 640px) { #review { bottom: 16px; } }

/* records page: 体重 and 饮食 tabs */
.page-head .seg { margin-bottom: 6px; }
.w-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 16px 20px 18px; }
.w-stats.six { grid-template-columns: repeat(3, 1fr); row-gap: 20px; padding: 22px 24px; }
.w-stats b { display: block; font-size: 20px; font-weight: 700; line-height: 1.1; }
.w-stats span { display: block; margin-top: 4px; color: var(--faint); font-size: 12px; }
.w-stats.six b { font-size: 26px; }
svg.w-line.big { height: 190px; }
.w-line circle.on { fill: var(--green); }
.w-line circle { cursor: pointer; }
.w-list { list-style: none; margin: 0; padding: 0 0 6px; }
.w-list li { display: flex; align-items: center; gap: 12px; padding: 12px 20px; border-top: 1px solid var(--line-2); }
.w-list li > span { flex: 1; color: var(--ink-2); font-size: 14px; }
.w-list li > span small { display: block; color: var(--faint); font-size: 11.5px; }
.w-list li > b { font-size: 17px; }
.w-list li > b small { color: var(--faint); font-size: 12px; font-weight: 400; }
.w-list li > em { width: 56px; text-align: right; font-style: normal; font-size: 13px; }
.w-list .ok { color: var(--green-d); } .w-list .warn { color: var(--amber); } .w-list .mute { color: var(--faint); }
.w-list.rows li { cursor: pointer; transition: background .2s; }
.w-list.rows li:hover, .w-list.rows li.sel { background: var(--hover); }
.w-list.rows li > span { flex: 0 0 90px; }
.w-list.rows li > b { flex: 1; }
.w-list.rows .link { padding: 4px 6px; color: var(--faint); font-weight: 500; }
.bars.fourteen, .bars-x.fourteen { grid-template-columns: repeat(14, 1fr); gap: 4px; }
.bars.fourteen { height: 120px; }
.bars.fourteen .bar { width: 100%; }
.bars.fourteen .goal { position: absolute; left: 0; right: 0; height: 0; border-top: 1px solid var(--faint); opacity: .5; }
.fdays .fday { border-top: 1px solid var(--line-2); }
.fday summary { display: flex; align-items: center; gap: 14px; padding: 13px 20px; cursor: pointer; list-style: none; transition: background .2s; }
.fday summary::-webkit-details-marker { display: none; }
.fday summary:hover, .fday[open] summary { background: var(--hover); }
.fday .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); flex: none; }
.fday .dot.low { background: var(--amber); } .fday .dot.now { background: var(--green); opacity: .4; }
.fday .d { width: 110px; font-weight: 500; font-size: 14.5px; }
.fday .d small, .fday .p small { display: block; color: var(--faint); font-size: 11.5px; font-weight: 400; }
.fday .k { flex: 1; } .fday .k b { font-size: 16px; } .fday .k small { color: var(--faint); font-size: 12px; }
.fday .pbar { display: block; height: 4px; margin-top: 5px; border-radius: 2px; background: var(--line-2); overflow: hidden; }
.fday .pbar b { display: block; height: 100%; border-radius: 2px; background: var(--green); }
.fday .pbar b.low { background: var(--amber); } .fday .pbar b.now { background: var(--green); opacity: .4; }
.fday .p { text-align: right; } .fday .p b { font-size: 14px; } .fday .p b.ok { color: var(--green-d); }
.fday-b { padding: 4px 20px 16px; background: var(--hover); }
.fday-b .w-stats { padding: 8px 0 6px; grid-template-columns: repeat(3, 1fr); }
.fday-b .w-stats b { font-size: 16px; }
.fday-t { margin: 8px 0 4px; color: var(--muted); font-size: 12px; }
.fmeal { margin-top: 12px; }
.fmeal-h { display: flex; gap: 10px; align-items: baseline; }
.fmeal-h b { font-size: 13.5px; } .fmeal-h span { flex: 1; color: var(--faint); font-size: 11.5px; } .fmeal-h em { font-style: normal; font-size: 14px; }
.fitem { display: flex; justify-content: space-between; gap: 12px; margin-top: 3px; color: var(--ink-2); font-size: 13px; }
.fitem .num { color: var(--faint); font-size: 12px; }
@media (max-width: 720px) {
  .w-stats { grid-template-columns: repeat(2, 1fr); }
  .w-stats.six { grid-template-columns: repeat(2, 1fr); }
  .fday .d { width: 84px; }
}

/* a redraw in place (range, selection) doesn't replay the entrance */
.page.still .reveal, .page.still .page-head h1, .page.still .bars .bar, .page.still .w-line .ln, .page.still .w-line .area { animation: none; }
.page.still .w-line .ln { stroke-dashoffset: 0; }
