/* Unified style (2026-11): the food log look applied app-wide.
   Loaded last, so it evens out older pages without touching their logic.
   Rules: 600/700 weights, 13-14px body, 15px section titles, neutral tiles
   with coloured glyphs, hairline-separated inset lists, soft grey secondary
   buttons (no black outlines), colour only in data, one dark hero per screen.
   Mockups: https://claude.ai/artifact/AopidB8r3ZFouZ95CLDKFm */
:root {
  --u-tile: var(--n-tile); --u-hair: var(--n-hair); --u-seg: var(--n-seg); --u-faint: var(--n-faint);
  --u-card: 0 1px 2px rgba(var(--n-ink-rgb), 0.04), 0 8px 24px rgba(var(--n-ink-rgb), 0.07);
  --u-blue: #3b82f6; --u-violet: #8b5cf6; --u-amber: #f59e0b;
}
:root[data-theme="dark"] {
  --u-tile: var(--d-tile); --u-hair: var(--d-hair); --u-seg: var(--d-seg); --u-faint: #6f747c;
  --u-card: 0 1px 2px rgba(0, 0, 0, 0.3), 0 10px 30px rgba(0, 0, 0, 0.25);
}

/* ---------- type ---------- */
h1, h2, h3 { font-weight: 700; }
.page-head { padding: 4px 2px 14px; text-align: center; }
.page-head h1 { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; }
.page-head p { font-size: 12px; font-weight: 600; margin-top: 2px; }
.page-head + .segmented, .page-head + .train-switch { display: flex; margin: 0 auto 14px; max-width: 360px; }
.dash-greeting { padding: 4px 2px 14px; text-align: center; }
.dash-greeting-kicker { order: 2; font-size: 12px; font-weight: 600; color: var(--muted); text-transform: none; letter-spacing: 0; margin: 2px 0 0; }
.dash-greeting { display: flex; flex-direction: column; align-items: center; }
.dash-greeting-title { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
.panel h2, .hm-section-head h2, .hl-section { font-size: 15px; font-weight: 700; letter-spacing: -0.01em; }
.panel h3 { font-size: 14.5px; font-weight: 700; }
.hm-section-head { margin: 0 2px 8px; }
.hm-section { margin-bottom: 18px; }
.card-link-title { font-size: 14.5px; font-weight: 700; }
.stat-value, .chart-total, .hero-stats b, .act-stats b, .pb-value { font-weight: 700; }
.chart-total { font-size: 26px; }
.link { font-size: 12px; font-weight: 600; }
.muted.small, .small.muted { font-size: 11.5px; }

/* ---------- cards ---------- */
.panel { padding: 16px; border-radius: 24px; box-shadow: var(--u-card); margin-bottom: 12px; }
.stat-card { box-shadow: var(--u-card); }
.card-link { padding: 14px 16px; gap: 12px; }
.card-link:hover { box-shadow: 0 0 0 1.5px var(--accent), var(--u-card); }
.hero-dark { padding: 18px; border-radius: 24px; background: radial-gradient(circle 200px at 100% 0%, rgba(var(--acc-400-rgb), 0.22), transparent 70%), var(--n-hero); box-shadow: 0 16px 32px -16px rgba(var(--n-ink-rgb), 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.06); margin-bottom: 12px; }
.hero-tag { border: 0; padding: 0; font-size: 10.5px; font-weight: 600; letter-spacing: 0.07em; color: var(--acc-400); }
.hero-title { font-size: 20px; font-weight: 700; margin-top: 6px; }
.hero-sub { font-size: 12.5px; color: var(--n-line); margin-top: 2px; }
.hero-stats { margin: 14px 0 2px; }
.hero-stats b { font-size: 16px; }
.hero-stats span { font-size: 11px; color: var(--n-faint2); }
.hero-actions { margin-top: 14px; gap: 8px; }

/* Coloured stat tiles become plain cards; colour stays in the label icon. */
.stat-card.tile { background: var(--panel); color: var(--text); box-shadow: var(--u-card); }
.stat-card.tile::after { display: none; }
.stat-card.tile .stat-label { color: var(--muted); }
.stat-card.tile.tile-dark { background: var(--n-hero); color: #fff; }
.stat-card.tile.tile-dark .stat-label { color: var(--n-faint2); }
.tile-green .stat-label .ico { color: var(--accent); }
.tile-blue .stat-label .ico { color: var(--u-blue); }
.stat-card { min-height: 0; padding: 14px 16px; }
.stat-value { font-size: 20px; }

/* Icon tiles: neutral background, coloured glyph. */
.icon-tile { background: var(--u-tile); color: var(--text); box-shadow: none; }
.icon-tile.green { background: var(--u-tile); color: var(--accent); box-shadow: none; }
.icon-tile.blue { background: var(--u-tile); color: var(--u-blue); }
.icon-tile.grey { background: var(--u-tile); color: var(--muted); }
.icon-tile.dark { background: var(--u-tile); color: var(--text); }
.icon-tile.sm, .act-row .icon-tile, .pb-item .icon-tile { width: 32px; height: 32px; border-radius: 10px; }
.icon-tile.sm .ico, .act-row .icon-tile .ico { width: 16px; height: 16px; }
.hero-dark .icon-tile, .fd-dark .icon-tile { background: rgba(255, 255, 255, 0.08); color: var(--acc-400); }

/* ---------- buttons, chips, segmented ---------- */
.btn { font-weight: 600; }
.btn-ghost { background: var(--u-tile); border: 0; color: var(--text); }
.btn-ghost:hover { background: var(--u-seg); color: var(--text); }
.btn-outline-light { background: rgba(255, 255, 255, 0.08); border: 0; color: #fff; }
.btn-outline-light:hover { background: rgba(255, 255, 255, 0.14); }
.badge { font-weight: 600; font-size: 11px; }
.segmented { background: var(--u-seg); padding: 3px; }
.panel .segmented { background: var(--u-tile); }
.segmented button, .segmented .seg { font-size: 12px; font-weight: 600; padding: 6px 12px; }
.segmented button.active, .segmented .seg.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(var(--n-ink-rgb), 0.1); }
.train-switch .seg { flex: 1; text-align: center; }

/* ---------- inset lists (food log style) ---------- */
.u-ins { background: var(--u-tile); border-radius: 16px; overflow: hidden; }
.u-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; width: 100%; background: none; border: 0; font: inherit; color: inherit; text-align: left; text-decoration: none; cursor: pointer; }
.u-ins > .u-row + .u-row, .u-list > .u-row + .u-row { border-top: 1px solid var(--u-hair); }
.u-list > .u-row { padding: 10px 2px; }
.u-ins .icon-tile { background: var(--panel); }
.u-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.u-name { font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.u-meta { font-size: 11.5px; font-weight: 500; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.u-val { font-size: 13.5px; font-weight: 700; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; display: flex; flex-direction: column; align-items: flex-end; gap: 1px; }
.u-val small { font-size: 10.5px; font-weight: 600; color: var(--muted); }
.u-time { width: 38px; flex-shrink: 0; font-size: 11px; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums; }
.u-chev { width: 14px; height: 14px; color: var(--u-faint); flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.u-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.u-stats > div { display: flex; flex-direction: column; gap: 3px; padding: 0 10px; }
.u-stats > div:first-child { padding-left: 0; }
.u-stats > div + div { border-left: 1px solid var(--u-hair); }
.u-stats span { font-size: 11px; font-weight: 600; color: var(--muted); }
.u-stats b { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.u-stats b small { font-size: 11px; font-weight: 600; color: var(--muted); margin-left: 1px; }
.u-hair { height: 1px; background: var(--u-hair); margin: 12px 0; }

/* Activity rows everywhere: compact, neutral. */
.act-list { gap: 0; margin-top: 4px; }
.act-row, .hist-row { gap: 10px; padding: 10px 2px; border-radius: 0; }
.act-list > .act-row + .act-row { border-top: 1px solid var(--u-hair); }
.act-row:hover, .hist-row:hover { background: none; }
.act-title { font-size: 13.5px; font-weight: 600; }
.act-meta { font-size: 11.5px; margin-top: 1px; }
.act-stats { gap: 12px; }
.act-stats > div { min-width: 34px; }
.act-stats b { font-size: 13.5px; }
.act-stats span { font-size: 10.5px; }

/* Personal bests: inset list. */
.pb-list { gap: 0; margin-top: 0; background: var(--u-tile); border-radius: 16px; overflow: hidden; }
.pb-item { background: none; border-radius: 0; padding: 10px 12px; gap: 10px; }
.pb-item + .pb-item { border-top: 1px solid var(--u-hair); }
.pb-item .icon-tile { background: var(--panel); }
.pb-item .pb-text { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "label value" "meta value"; align-items: center; column-gap: 8px; }
.pb-text > div:nth-child(1) { grid-area: label; font-size: 13.5px; font-weight: 600; color: var(--text) !important; }
.pb-text > .pb-value { grid-area: value; font-size: 13.5px; }
.pb-text > div:nth-child(3) { grid-area: meta; font-size: 11.5px; }

/* ---------- top bar on phones: compact ---------- */
@media (max-width: 600px) {
  .topbar { padding: 10px 0 6px; }
  .brand-mark { width: 30px; height: 30px; border-radius: 10px; }
  .brand-title { font-size: 14px; font-weight: 700; }
  .brand-sub { display: none; }
  .conn-status { padding: 5px 10px 5px 8px; font-size: 12px; }
  #themeToggleBtn { padding: 5px 10px; font-size: 12px; }
}

/* ---------- Home ---------- */
.hm-food-top .fd-home { margin-bottom: 12px; }
.hm-timeline, .hm-recent, .hm-bests { padding: 12px; }
.hm-recent { padding: 4px 16px; }
.hm-timeline .hm-tl-row { padding: 10px 12px; gap: 10px; border-radius: 0; }
.hm-timeline .hm-tl-row.is-planned .u-name { color: var(--muted); }
.hm-weekcard { padding: 16px; }
.hm-weekcard .chart-head { margin-bottom: 10px; }
/* Habits: one card, rows split by hairlines. */
.hm-habits { background: var(--panel); border-radius: 24px; box-shadow: var(--u-card); padding: 2px 16px; gap: 0; }
.hm-habits > .panel, .hm-habits > .hm-habit { background: none; box-shadow: none !important; border-radius: 0; padding: 12px 0 !important; margin: 0; }
.hm-habits > * + * { border-top: 1px solid var(--u-hair); }
.hm-habit-ring { width: 48px !important; }
.hm-habit-ring b { font-size: 12px; font-weight: 700; }
.hm-steps-num b { font-size: 17px; font-weight: 700; }
.hm-h75-chip { background: var(--u-tile) !important; color: var(--text) !important; box-shadow: none !important; font-weight: 600; }
.hm-h75-chip.dark { background: var(--n-hero) !important; color: #fff !important; }
.hm-chip { font-weight: 600; }
.hm-ring-label { font-size: 12px; font-weight: 600; }
.hm-ring-dial b { font-weight: 700; }
.pb-item .pb-text { flex: 1; min-width: 0; }
.hm-trio b { font-size: 20px; }
.hm-mon-value { font-size: 20px; margin: 6px 0 4px; }
.hm-gauge b { font-size: 18px; }
.hm-energy-head > b { font-size: 18px; }
.hm-ld .tl-g-val { font-size: 24px; }
.hm-ld-s { font-size: 15px; }
.hm-status-big { font-size: 15px; }
.chart-kicker { font-size: 12px; font-weight: 600; }

/* ---------- Workouts ---------- */
.wo-day-strip { justify-content: space-between; gap: 2px; }
.wo-day-chip-wrap { width: auto; flex: 1; }
.wo-day-letter { font-size: 10.5px; font-weight: 600; }
.wo-day-num { font-size: 12.5px; font-weight: 600; }
.wo-day-letter.today, .wo-day-num.today { color: var(--text); font-weight: 700; }
.wo-day-icon { width: 30px; height: 30px; border-radius: 50%; border: 1.5px dashed var(--u-hair); background: none; display: flex; align-items: center; justify-content: center; color: var(--u-faint); }
.wo-day-icon .ico { width: 14px; height: 14px; }
.wo-day-icon.rest { border-style: solid; border-color: transparent; background: var(--u-tile); }
.wo-day-icon.rest.future { background: none; border: 1.5px dashed var(--u-hair); }
.wo-day-icon.has-activity { background: var(--accent-soft); border: 0; color: var(--accent-dark); }
.wo-recent-ins { margin: 10px 0 0; }
.wo-start-list { margin-top: 10px; }
.wo-start-list .u-row { padding: 8px 8px 8px 12px; }
.wo-routine-carousel { gap: 10px; }
.wo-routine-card { border: 0 !important; background: var(--u-tile); border-radius: 18px; box-shadow: none; padding: 14px; }
.wo-routine-card-icon { width: 32px; height: 32px; border-radius: 10px; background: var(--panel); display: flex !important; align-items: center; justify-content: center; font-size: 11px !important; font-weight: 700; color: var(--text); margin-bottom: 14px !important; }
.wo-routine-card-icon .ico { width: 16px; height: 16px; }
.wo-routine-card-name { font-size: 13.5px; font-weight: 600; }
.wo-tile-icon { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 10px; background: var(--u-tile); font-size: 11px; font-weight: 700; color: var(--muted); flex-shrink: 0; }
.date-tile { width: 36px; height: 38px; border-radius: 10px; background: var(--u-tile); }
.date-tile b { font-size: 14px; }
.date-tile span { font-size: 9.5px; font-weight: 600; }
.hist-row .card-link-arrow { width: 14px; height: 14px; color: var(--u-faint); }
#workoutHistoryList .hist-row + .hist-row { border-top: 1px solid var(--u-hair); }
.mini-stats { border-top: 1px solid var(--u-hair); padding-top: 12px; gap: 0; }
.mini-stats > div { padding: 0 10px; }
.mini-stats > div:first-child { padding-left: 0; }
.mini-stats > div + div { border-left: 1px solid var(--u-hair); }
.mini-stats b { font-size: 17px; }
.mini-stats span { font-size: 11px; font-weight: 600; }
.show-more { width: 100%; margin-top: 8px; justify-content: center; }
.panel > p.muted, .panel > .muted:only-child { font-size: 13px; line-height: 1.5; }
.wo-routines-head h2 { margin: 0; }
.wo-routines-head .btn { min-height: 34px; padding: 0 12px; font-size: 12.5px; }

/* ---------- Plans ---------- */
.pl-emoji { background: var(--u-tile); box-shadow: none; color: var(--text); font-size: 12px; font-weight: 700; letter-spacing: 0.02em; border-radius: 12px; }
.pl-emoji.lg { font-size: 14px; border-radius: 14px; }
.pl-emoji.xl { font-size: 17px; border-radius: 18px; }
.pl-hero .pl-emoji { background: rgba(255,255,255,0.1); box-shadow: none; color: #fff; }
.pl-cmp-head .pl-emoji { font-size: 11px; }
.pl-card { border-top: 0; box-shadow: var(--u-card); padding: 16px; gap: 8px; }
.pl-card:hover { box-shadow: 0 0 0 1.5px var(--u-hair), var(--u-card); }
.pl-card.is-rec { box-shadow: 0 0 0 1.5px var(--acc-500), var(--u-card); background: var(--panel); }
.pl-card-title h3 { font-size: 14.5px; }
.pl-card-split { font-size: 11.5px; font-weight: 500; }
.pl-card-desc { font-size: 12.5px; color: var(--muted); opacity: 1; }
.pl-card-actions .btn { min-height: 34px; font-size: 12.5px; }
.pl-ribbon { background: var(--accent-soft); color: var(--accent-dark); }
.pl-cmp-head { border-top: 0; background: var(--u-tile); }
.pl-hero { background: var(--n-hero); }
.pl-hero-title { font-size: 22px; }
.pl-hero-desc { font-size: 13px; }
.pl-quiz-icon, .pl-cta-icon { width: 40px; height: 40px; border-radius: 12px; background: var(--u-tile); color: var(--accent-dark); }
.pl-quiz-icon .ico, .pl-cta-icon .ico { width: 20px; height: 20px; }
.pl-cta { padding: 14px 16px; }
.pl-cta-main b { font-size: 14.5px; }
.pl-cta-main .small { font-size: 11.5px; }
.pl-rec-rank { background: var(--u-tile); color: var(--text); }
.pl-src-ai, .pl-src-mixed { background: var(--u-tile); color: var(--muted); }

/* Progress list as an inset list */
.prog-list { gap: 0; background: var(--u-tile); border-radius: 18px; padding: 0 14px; }
.prog-row, .prog-row:hover { background: none; border-radius: 0; padding: 11px 0; }
.prog-row + .prog-row { border-top: 1px solid var(--u-hair); }
.prog-row-name { font-size: 13.5px; font-weight: 600; }
.prog-row-meta { font-size: 11.5px; font-weight: 500; }
.prog-stat b { font-size: 14px; }
.prog-stat span { font-size: 10.5px; font-weight: 500; }
.prog-row-next { font-size: 11.5px; font-weight: 600; }
@media (max-width: 560px) { .prog-row { padding: 11px 0; } }
.prog-empty { background: var(--u-tile); border-radius: 18px; }
.hist-row .date-tile { background: var(--panel); }
.pl-section-head h2 { font-size: 15px; }
.pl-section-head p { font-size: 11.5px; }
.pl-tag { background: var(--u-tile); font-size: 11px; font-weight: 600; color: var(--muted); }
.pl-facts { font-size: 11.5px; font-weight: 500; }
.pl-facts b { font-size: 13.5px; }
.pl-quiz-headtext h2 { font-size: 14.5px; }
.pl-quiz-headtext p { font-size: 11.5px; }
.pl-myplan .pl-emoji { width: 32px; height: 32px; font-size: 11px; border-radius: 10px; }
.pl-quiz { background: var(--panel); box-shadow: var(--u-card); }

/* ---------- Cardio ---------- */
.cd-hero-dark { background: var(--n-hero); color: #fff; box-shadow: 0 18px 40px rgba(var(--n-ink-rgb),.22); flex-wrap: wrap; }
.cd-hero-dark .cd-hero-sub, .cd-hero-dark .cd-hero-keys { color: var(--n-faint2); }
.cd-hero-dark .cd-hero-value { font-size: 28px; font-weight: 700; color: #fff; }
.cd-eyebrow { font-size: 10.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--acc-400); }
.cd-hero-dark .dr .dr-track { stroke: var(--d-raise); }
.cd-hero-dark .dr .dr-halo { stroke: var(--d-raise); }
.cd-hero-dark .dr .dr-face, .cd-hero-dark .dr .dr-knob { fill: var(--n-hero); }
.cd-hero-dark .dr .dr-goal { fill: #fff; }
.cd-hero-dark .dr .dr-avg { fill: var(--n-hero); }
.cd-hero-dark .dr-in b { color: #fff; }
.cd-hero-dark .dr-in span { color: var(--n-faint2); }
.cd-hero-dark .dr .dr-fill { filter: drop-shadow(0 0 5px rgba(var(--acc-400-rgb),.6)); }
.cd-hero-stats { flex-basis: 100%; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0,1fr); border-top: 1px solid rgba(255,255,255,.08); padding-top: 12px; margin-top: 4px; }
.cd-hero-stats > div { display: flex; flex-direction: column; gap: 2px; padding: 0 10px; }
.cd-hero-stats > div:first-child { padding-left: 0; }
.cd-hero-stats > div + div { border-left: 1px solid rgba(255,255,255,.08); }
.cd-hero-stats span { font-size: 11px; font-weight: 600; color: var(--n-faint2); }
.cd-hero-stats b { font-size: 15px; font-weight: 700; }
.cd-hero-empty { flex-basis: 100%; margin: 0; font-size: 12px; color: var(--n-faint2); }
.cd-tiles .stat-card .cd-spark-tile .l { stroke: var(--acc-500); }
.cd-tiles .stat-card .cd-spark-tile .a { fill: rgba(var(--acc-500-rgb),.12); }
.cd-tiles .stat-card .cd-spark-tile circle { fill: var(--panel); stroke: var(--acc-500); }
.cd-tiles .stat-card .cd-dots i { background: var(--u-hair); }
.cd-tiles .stat-card .cd-dots i.on { background: var(--acc-500); }
.cd-tiles .stat-card .cd-delta { background: var(--u-tile); color: var(--muted); }
.cd-tile-note { color: var(--muted); }
.cd-plan-days { background: var(--u-tile); border-radius: 18px; padding: 0 12px; gap: 0; }
.cd-plan-day { padding: 8px 0; border: 0; background: none; }
.cd-plan-day + .cd-plan-day { border-top: 1px solid var(--u-hair); }
.cd-plan-dayname { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.cd-session { font-size: 12px; font-weight: 600; background: var(--panel); border: 0; box-shadow: none; }
.cd-add-mini { background: none; border: 1.5px dashed var(--u-hair); color: var(--u-faint); }
.cd-zone-range { font-size: 30px; font-weight: 700; }
.cd-sub { font-size: 14.5px; font-weight: 700; }
.cd-recent { margin-top: 8px; }
.cd-recent .u-name .cd-z2-badge { font-size: 10px; padding: 1px 6px; vertical-align: 1px; }
.cd-footnote { font-size: 11.5px; }
.cd-cal-more summary { cursor: pointer; font-size: 12.5px; font-weight: 600; color: var(--accent-dark); padding: 10px 0 2px; list-style: none; }
.cd-cal-more summary::-webkit-details-marker { display: none; }
.cd-cal-legend { font-size: 11px; }
.cd-next-num b { font-size: 30px; }
.cd-eff { background: var(--u-tile); box-shadow: none; border: 0; }
.cd-eff-value { font-size: 22px; }
.cd-hero-dark { gap: 16px; }
.cd-hero-dark .cd-hero-text { flex: 1 1 0; min-width: 0; }
.cd-hero-dark .cd-hero-sub { font-size: 12px; }
.cd-hero-dark .cd-hero-keys { font-size: 11px; flex-direction: column; gap: 3px; }
@media (max-width: 560px) { .cd-hero-dark .cd-hero-ring .dr { width: 112px; } .cd-hero-dark .cd-hero-ring .dr-in b { font-size: 22px; } .cd-hero-dark .cd-hero-value { font-size: 24px; } }
.cd-plan-day { padding: 6px 0; }
.cd-add-mini { width: 26px; height: 26px; }

/* ---------- Health ---------- */
.hl-today { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 900px) { .hl-today { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.hl-tile { border: 0; box-shadow: var(--u-card); border-radius: 22px; padding: 14px; }
.hl-tile:hover:not([disabled]) { border-color: transparent; box-shadow: 0 0 0 1.5px var(--u-hair), var(--u-card); }
.hl-tile .hl-card-title { font-size: 11.5px; font-weight: 600; }
.hl-tile-main { font-size: 18px; }
.hl-tile-sub { font-size: 11px; font-weight: 500; }
.hl-tile .hl-ring .dr, .hl-tile .dr { width: 44px; }
.hl-tile-hero { grid-column: 1 / -1; background: var(--n-hero); color: #fff; padding: 18px; box-shadow: 0 18px 40px rgba(var(--n-ink-rgb),.22); }
.hl-tile-hero .hl-card-title { color: var(--acc-400); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; }
.hl-tile-hero .hl-tile-main { font-size: 26px; }
.hl-tile-hero .hl-tile-main .good { color: var(--acc-400); text-shadow: 0 0 18px rgba(var(--acc-400-rgb),.45); }
.hl-tile-hero .hl-tile-sub { color: var(--n-faint2); font-size: 12px; }
.hl-tile-hero .dr { width: 88px !important; }
.hl-tile-hero .dr .dr-track, .hl-tile-hero .dr .dr-halo { stroke: var(--d-raise); }
.hl-tile-hero .dr .dr-face, .hl-tile-hero .dr .dr-knob, .hl-tile-hero .dr .dr-avg { fill: var(--n-hero); }
.hl-tile-hero .dr .dr-goal { fill: #fff; }
.hl-tile-hero .dr .dr-fill { filter: drop-shadow(0 0 5px rgba(var(--acc-400-rgb),.6)); }
.hl-tile-hero .dr-in b { color: #fff; font-size: 22px; }
.hl-tabs { background: var(--u-seg); border-radius: 999px; padding: 3px; gap: 2px; margin: 0 0 14px; }
.hl-tab { border: 0; background: none; font-size: 12.5px; font-weight: 600; padding: 7px 12px; }
.hl-tab.active, :root[data-theme="dark"] .hl-tab.active { background: var(--panel); color: var(--text); border: 0; box-shadow: 0 1px 3px rgba(var(--n-ink-rgb),.1); }
.hl-readout b { font-size: 26px; }
.hl-card { border: 0; box-shadow: var(--u-card); border-radius: 24px; padding: 16px; }
.hl-card-title { font-size: 14.5px; color: var(--text); }
.hl-value { font-size: 26px; }
.hl-value .muted { font-size: 18px; }
.hl-section { margin-top: 22px; }
.hl-kv { gap: 0; background: var(--u-tile); border-radius: 14px; padding: 2px 12px; }
.hl-kv > div { padding: 7px 0; font-size: 12.5px; }
.hl-kv > div + div { border-top: 1px solid var(--u-hair); }
.hl-kv b { font-weight: 600; }
.hl-card-more { all: unset; box-sizing: border-box; cursor: pointer; display: inline-flex; align-items: center; gap: 2px; margin-top: 8px; font-size: 12px; font-weight: 600; color: var(--accent-dark); }
.hl-card-more .u-chev { width: 14px; height: 14px; stroke: currentColor; }
.hl-toolbar .btn { min-height: 30px; font-size: 12px; }
.hl-tile-hero ~ .hl-tile:last-child:nth-child(even) { grid-column: 1 / -1; }

/* ---------- 75 Hard ---------- */
.h75-head h1 { font-size: 24px; }
.h75-tile.green, .h75-tile.grey, .h75-tile.blue, .h75-tile.amber, .h75-tile.purple, .h75-tile.indigo { background: var(--u-tile); }
.h75-tile { width: 36px; height: 36px; border-radius: 11px; }
.h75-tile .h75-ico { width: 18px; height: 18px; }
.h75-pill.blue, .h75-pill.amber, .h75-pill.purple,
:root[data-theme="dark"] .h75-pill.blue, :root[data-theme="dark"] .h75-pill.amber, :root[data-theme="dark"] .h75-pill.purple { background: var(--u-tile); color: var(--text); }
.h75-pill { height: 32px; padding: 0 12px; font-size: 12.5px; font-weight: 600; }
:root[data-theme="dark"] .h75-tile.green, :root[data-theme="dark"] .h75-tile.blue, :root[data-theme="dark"] .h75-tile.amber, :root[data-theme="dark"] .h75-tile.purple, :root[data-theme="dark"] .h75-tile.indigo { background: var(--u-tile); }
.h75-task-text b { font-size: 13.5px; font-weight: 600; }
.h75-task-text > span { font-size: 11.5px; font-weight: 500; }
.h75-attempt-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--u-hair); padding-top: 12px; }
.h75-attempt-stats .h75-stat { background: none !important; color: var(--text) !important; padding: 0 8px; border-radius: 0; min-height: 0; box-shadow: none; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.h75-attempt-stats .h75-stat:first-child { padding-left: 0; }
.h75-attempt-stats .h75-stat + .h75-stat { border-left: 1px solid var(--u-hair); }
.h75-attempt-stats .h75-stat span { font-size: 11px; font-weight: 600; color: var(--muted) !important; }
.h75-attempt-stats .h75-stat b { font-size: 18px; font-weight: 700; color: var(--text) !important; }
.h75-attempt-stats .h75-stat b em { font-size: 12px; font-style: normal; color: var(--muted); }
.h75-attempt-stats .h75-stat small { font-size: 10.5px; color: var(--muted) !important; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Account ---------- */
.profile-hero { flex-direction: row; text-align: left; align-items: center; flex-wrap: wrap; gap: 14px; padding: 16px; }
.profile-hero .avatar-badge.xl { width: 56px; height: 56px; font-size: 19px; margin: 0; box-shadow: 0 0 0 3px var(--panel), 0 0 0 4.5px var(--accent); }
.profile-name { font-size: 18px; }
.profile-stats { margin-top: 0; max-width: none; background: none; border-top: 1px solid var(--u-hair); border-radius: 0; padding: 12px 0 0; flex-basis: 100%; }
.profile-stats > div { border-left-color: var(--u-hair); align-items: center; }
.profile-stats b { font-size: 16px; }
.profile-stats span { font-size: 11px; font-weight: 500; }
.hl-set { margin-top: 4px; }
.hl-set .u-row { text-decoration: none; color: inherit; width: 100%; }
.hl-set .u-name .pill { font-size: 10.5px; padding: 2px 8px; margin-left: 4px; vertical-align: 1px; }
.hl-set-date { font: inherit; font-size: 12.5px; font-weight: 600; border: 0; background: var(--panel); border-radius: 10px; padding: 6px 8px; color: var(--text); max-width: 140px; }
.hl-danger-link { all: unset; cursor: pointer; display: block; margin-top: 12px; font-size: 12.5px; font-weight: 600; color: var(--danger); }

.chip-scroll { background: var(--u-seg); border-radius: 999px; padding: 3px; gap: 2px; width: fit-content; max-width: 100%; }
.chip-scroll .chip { border: 0; background: none; font-size: 12.5px; font-weight: 600; padding: 7px 12px; color: var(--muted); }
.chip-scroll .chip.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(var(--n-ink-rgb),.1); }
.ov-stats, .ov-stats { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; gap: 0; row-gap: 0 !important; border-top: 1px solid var(--u-hair); border-bottom: 1px solid var(--u-hair); padding: 12px 0; margin-top: 14px; }
.ov-stats > div { align-items: flex-start; text-align: left; padding: 0 10px; gap: 1px; }
.ov-stats > div:first-child { padding-left: 0; }
.ov-stats > div + div { border-left: 1px solid var(--u-hair); }
.ov-stats b { font-size: 17px; margin-top: 0; }
.ov-stats span:last-child { font-size: 11px; font-weight: 500; }
.subtabs { background: var(--u-seg); }
.subtab { font-weight: 600; }
.subtab.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(var(--n-ink-rgb),.1); }
.chip-row .chip { border: 0; background: var(--u-tile); font-weight: 600; font-size: 12.5px; }
.chip-row .chip.selected { background: var(--text); color: var(--panel); }
.profile-id { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.activity-search-input { border: 0; background: var(--u-tile); border-radius: 12px; font-size: 13px; }

/* ---------- Slide-up sheets: one scale ---------- */
.vs-title, .wo-sheet-body .wo-live-title { font-size: 20px; letter-spacing: -0.015em; }
.h75-sh-head h2, .h75-day-nav h2 { font-size: 18px; }
.mo-hero-val { font-size: 44px; }
.mo-hero-sub { font-size: 18px; }
.mo-ring-mid b, .st-gauge-mid b, .mo-half-val { font-size: 40px; }
.en-batt-val { font-size: 40px; }
.en-batt-val small { font-size: 18px; }
.en-tile b, .st-mini-val, .mo-big { font-size: 22px; }
.st-trend-val { font-size: 24px; }
.mo-dark-val { font-size: 32px; }
.tl-big { font-size: 36px; }
.tl-g-val { font-size: 32px; }
.hm-sheet-value { font-size: 34px; }
.hm-sheet-ring .hm-ring-dial b, .sp-ring .dr-in b { font-size: 30px; }
.h75-ring-big .dr-in b { font-size: 36px; }
.h75-stat b { font-size: 22px; }
.hl-gauge-value { font-size: 32px; }
.hl-status-big { font-size: 18px; }
.recap-hero-value { font-size: 44px; }
.fd-hero b, .fd-pace-val b { font-size: 32px; }
.fd-dial .dr-in b { font-size: 36px; }
.vs-item-title { font-size: 13.5px; font-weight: 600; }
.wo-sheet-body .btn-outline, .view-sheet-body .btn-outline { background: var(--u-tile); border-color: transparent; color: var(--text); }
.fd-btn-outline { background: var(--u-tile); border-color: transparent !important; box-shadow: none; }

/* ---------- Live workout ---------- */
.wo-live-hero { background: var(--n-hero); color: #fff; border-radius: 24px; padding: 18px; margin-bottom: 14px; box-shadow: 0 18px 40px rgba(var(--n-ink-rgb),.22); }
.wo-live-hero-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.wo-live-hero-id { min-width: 0; }
.wo-live-eyebrow { font-size: 10.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--acc-400); }
.wo-live-hero .wo-live-title { color: #fff; margin: 2px 0 0; }
.wo-live-timer { font-size: 30px; font-weight: 700; color: var(--acc-400); text-shadow: 0 0 18px rgba(var(--acc-400-rgb),.5); font-variant-numeric: tabular-nums; }
.wo-live-sub { margin: 8px 0 10px; font-size: 12px; color: var(--n-faint2); }
.wo-live-hero .progress, .wo-live-hero .progress-bar { background: var(--d-raise); }
.wo-live-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.wo-live-btns .btn { min-height: 40px; }
.wo-add-set, .wo-ex-add-set { background: var(--u-tile); border: 0; }
.pl-wday.is-training { background: var(--u-tile); box-shadow: none; }
.pl-wday { background: var(--u-tile); }
.pl-wday + .pl-wday { margin-top: 0; }
.pl-wday-name { font-size: 13.5px; font-weight: 600; }
.pl-wday-focus { font-size: 11.5px; }
.pl-day.is-training { box-shadow: var(--u-card); }
.pl-day.is-training .pl-day-dow { background: var(--u-tile); }
.pl-day-name { font-size: 13.5px; font-weight: 600; }
.wo-live-hero .progress-track { background: var(--d-raise); }
.wo-live-hero .progress-track { border: 0; height: 6px; }
.wo-live-btns .btn { justify-content: center; }
.wo-live-timer { font-family: inherit; letter-spacing: -0.02em; }

/* ================= Home, matched to the mockup ================= */
/* Header: avatar left, title + date centred, calendar right. Top bar hidden on phone Home. */
.dash-head { display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; gap: 8px; margin: 4px 0 14px; }
.dash-head .dash-greeting { margin: 0; padding: 0; }
.dash-avatar, .dash-round { width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.dash-avatar .avatar-badge { width: 40px; height: 40px; font-size: 14px; }
.dash-round { background: var(--panel); box-shadow: var(--u-card); color: var(--text); }
.dash-round .ico { width: 18px; height: 18px; }
.dash-greeting-title { font-size: 22px !important; }
.dash-greeting-kicker { font-size: 12px !important; font-weight: 500 !important; text-transform: none !important; letter-spacing: 0 !important; color: var(--muted); order: 2; }
.dash-greeting { display: flex; flex-direction: column; align-items: center; }
@media (max-width: 760px) {
  /* The bottom tab bar lives inside .topbar, so hide only the brand row, never the bar itself */
  body:has(#view-dashboard.active) .topbar > :not(.tabs) { display: none; }
}

/* Cards share one rhythm */
#homeRoot { gap: 12px; }
#homeRoot .hm-section { margin-top: 6px; }
#homeRoot .hm-section-head { margin-bottom: 8px; }
#homeRoot .hm-section-head .link { font-size: 12px; font-weight: 600; background: none; border: 0; padding: 0; cursor: pointer; color: var(--accent-dark); font-family: inherit; }

/* Daily overview: 64px rings, dividers, one-line coaching */
.hm-overview { padding: 16px; }
.hm-overview .hm-rings { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
.hm-overview .hm-ring { padding: 0 4px; gap: 4px; }
.hm-overview .hm-ring + .hm-ring { border-left: 1px solid var(--u-hair); }
.hm-overview .hm-ring-dial, .hm-overview .hm-ring-dial .dr { width: 64px !important; height: 64px; }
.hm-overview .hm-ring-dial b { font-size: 15px !important; }
.hm-overview .hm-ring-dial b small { font-size: 9px; }
.hm-overview .hm-ring-label { font-size: 12px; font-weight: 600; color: var(--text); margin-top: 4px; }
.hm-overview .hm-ring-sub { font-size: 10.5px; font-weight: 500; margin-top: -2px; }
.hm-overview .hm-ring-sub.muted { color: var(--muted); }
.hm-overview .hm-coach { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; padding: 10px 12px; background: var(--u-tile); border-radius: 14px; }
.hm-overview .hm-coach .ico { width: 16px; height: 16px; color: var(--acc-500); flex-shrink: 0; margin-top: 2px; }
.hm-overview .hm-coach p { margin: 0; font-size: 12.5px; line-height: 1.45; font-weight: 500; }
.hm-overview .hm-coach p b { font-weight: 600; }
.hm-overview .hm-coach p span { color: var(--muted); }

/* Food: one compact row */
.fd-home2 { display: flex; align-items: center; gap: 14px; padding: 14px 16px; }
.fd-home2-ring { flex-shrink: 0; text-decoration: none; color: inherit; }
.fd-home2-ring .dr { width: 64px; }
.fd-home2-ring .dr-in b { font-size: 14px; font-weight: 700; }
.fd-home2-ring .dr-in span { font-size: 9px; color: var(--muted); font-weight: 500; margin-top: 1px; }
.fd-home2-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 7px; text-decoration: none; color: inherit; }
.fd-home2-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.fd-home2-top b { font-size: 14.5px; font-weight: 700; }
.fd-home2-left { font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.fd-home2-left small { font-size: 10.5px; font-weight: 600; color: var(--muted); margin-left: 3px; }
.fd-home2-m { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.fd-home2-mac { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.fd-home2-mac > span { font-size: 10.5px; color: var(--muted); font-weight: 500; white-space: nowrap; }
.fd-home2-mac b { color: var(--text); font-weight: 700; }
.fd-home2-bar { display: block; height: 5px; border-radius: 5px; background: var(--u-hair); overflow: hidden; }
.fd-home2-bar > i { display: block; height: 100%; border-radius: 5px; }
.fd-home2-add { width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--u-tile); color: var(--text); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.fd-home2-add svg { width: 16px; height: 16px; }

/* Today's plan hero */
.hm-plan { padding: 18px; }
.hm-plan .hero-title { font-size: 20px; margin-top: 6px; }
.hm-plan .hero-sub { font-size: 12px; margin-top: 2px; }
.hm-plan-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 2px; }
.hm-plan-chip { font-size: 11.5px; font-weight: 600; padding: 5px 10px; border-radius: 999px; background: rgba(255,255,255,.08); color: #e5e7eb; }
.hm-plan-chip.up { color: var(--acc-400); }
.hm-plan .hero-actions { margin-top: 14px; }

/* Small two-up cards (stress & energy) */
.hm-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.hm-sm-card { all: unset; box-sizing: border-box; cursor: pointer; display: flex; flex-direction: column; gap: 8px; padding: 14px; background: var(--panel); border-radius: 22px; box-shadow: var(--u-card); min-width: 0; }
.hm-sl { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.hm-mid { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.hm-mid small { font-size: 11px; font-weight: 600; color: var(--muted); margin-left: 3px; letter-spacing: 0; }
.hm-xs { font-size: 10.5px; font-weight: 500; color: var(--muted); }
.hm-sm-row { display: flex; align-items: center; justify-content: space-between; gap: 6px; min-height: 44px; }
.hm-mini-ring .t { stroke: var(--u-hair); }
.hm-sbars { display: flex; align-items: flex-end; gap: 2px; height: 22px; }
.hm-sbars i { flex: 1; border-radius: 2px; }
.hm-bbar { position: relative; height: 22px; display: flex; align-items: center; }
.hm-bbar-track { width: 100%; height: 5px; border-radius: 5px; background: linear-gradient(90deg, #f87171, #fbbf24 35%, var(--acc-400) 75%); }
.hm-bbar-knob { position: absolute; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--panel); border: 2.5px solid var(--text); box-shadow: 0 2px 6px rgba(0,0,0,.2); }
.hm-bbar-peak { position: absolute; top: 2px; bottom: 2px; width: 1.5px; background: var(--text); opacity: .35; }

/* Training load: one card, two columns */
.hm-ld-card { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 14px 16px; gap: 0; }
.hm-ld-col { all: unset; box-sizing: border-box; cursor: pointer; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hm-ld-col + .hm-ld-col { border-left: 1px solid var(--u-hair); padding-left: 16px; }
.hm-ld-col:first-child { padding-right: 16px; }
.hm-ld-v { display: flex; align-items: baseline; gap: 6px; }
.hm-ld-v > span:last-child { font-size: 12.5px; font-weight: 600; }

/* Thin range bar with a dot */
.hm-hr { position: relative; height: 10px; width: 100%; }
.hm-hr-track { position: absolute; left: 0; right: 0; top: 2.5px; height: 5px; border-radius: 5px; background: var(--u-hair); }
.hm-hr-band { position: absolute; top: 2.5px; height: 5px; border-radius: 5px; }
.hm-hr-dot { position: absolute; top: 0.5px; width: 9px; height: 9px; margin-left: -4.5px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 2px var(--panel), 0 0 6px var(--c); }
.hm-hr-dot.ring { top: -0.5px; width: 11px; height: 11px; margin-left: -5.5px; background: var(--panel); border: 2.5px solid var(--c); box-shadow: none; box-sizing: border-box; }

/* White list cards (health monitor, habits) */
.hm-list { padding: 4px 16px; }
.hm-list .u-row { padding: 11px 0; border-radius: 0; background: none; width: 100%; text-decoration: none; color: inherit; }
.hm-list .u-row + .u-row { border-top: 1px solid var(--u-hair); }
.hm-list .icon-tile.sm { background: var(--u-tile); }
.hm-mon-row .hm-hr { width: 64px; flex-shrink: 0; }
.hm-mon-val { min-width: 54px; flex-direction: row !important; align-items: baseline !important; justify-content: flex-end; gap: 2px !important; }
.hm-list .u-val small { font-size: 10.5px; }
.hm-list .u-val { flex-direction: row; align-items: baseline; gap: 2px; }
.hm-mini-ring { flex-shrink: 0; }
.fd-home2-m { gap: 8px; }
.fd-home2-mac > span { font-size: 10px; overflow: hidden; text-overflow: clip; }
.hm-grid2 { align-items: stretch; }
.hm-sm-card .hm-xs { margin-top: auto; }

/* Home week chart: compact */
#homeChart .chart-kicker { font-size: 11.5px; font-weight: 600; color: var(--muted); text-transform: none; letter-spacing: 0; }
#homeChart .chart-total { font-size: 28px; margin-top: 2px; }
#homeChart .bchart { padding-left: 0; margin-top: 10px; }
#homeChart .bchart-tick span { display: none; }
#homeChart .bchart-tick { border-color: transparent; }
#homeChart .bchart-bubble { display: none; }
#homeChart .segmented button { padding: 5px 10px; font-size: 11.5px; }
.hm-recent.hm-list .u-row { cursor: pointer; }
.hm-recent .u-val small { display: block; }
.hm-list .u-val { flex-direction: column; align-items: flex-end; }
.hm-list .u-val small { margin-left: 0; }

.fd-home2-mac { gap: 3px; }
.fd-home2-mac > span:last-child { color: var(--muted); }
.hm-overview .hm-rings { padding: 0; margin: 0; }
.hm-overview .hm-ring { min-height: 0; }
.hm-list .u-val { flex-direction: row; align-items: baseline; }
.hm-list .u-val.hm-rv { flex-direction: column; align-items: flex-end; gap: 1px; }
.hm-rv small { margin-left: 2px; }
.hm-overview { overflow: visible; } .hm-overview .hm-ring { gap: 2px; }
.hm-rv > span { white-space: nowrap; } .hm-rv > span small { display: inline !important; }

/* ================= Shared page header (mockup) ================= */
.ph-head { display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; gap: 8px; margin: 4px 0 14px; }
.ph-mid { display: flex; flex-direction: column; align-items: center; min-width: 0; text-align: center; }
.ph-mid h1 { margin: 0; font-size: 22px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
.ph-mid p { margin: 1px 0 0; font-size: 12px; font-weight: 500; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.ph-rb { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--panel); color: var(--text); box-shadow: var(--u-card); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; }
.ph-rb .ico { width: 18px; height: 18px; }
.ph-rb[hidden] { display: none; }
.ph-av { width: 40px; height: 40px; border-radius: 50%; display: inline-flex; text-decoration: none; }
.ph-av .avatar-badge { width: 40px; height: 40px; font-size: 14px; }
.ph-av:empty { background: var(--u-tile); }
@media (max-width: 760px) {
  .topbar { padding: 0 !important; margin: 0 !important; min-height: 0 !important; border: 0 !important; background: none !important; box-shadow: none !important; }
  .topbar > :not(.tabs) { display: none !important; }
  .content { padding-top: 12px; }
}

/* ================= Workouts, matched to the mockup ================= */
.wo-week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin: 0 0 12px; }
.wo-wk-day { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 0; border-radius: 18px; min-width: 0; }
.wo-wk-day[data-wo-sess] { cursor: pointer; }
.wo-wk-day.is-today { background: var(--panel); box-shadow: var(--u-card); }
.wo-wk-d { font-size: 10.5px; font-weight: 600; color: var(--muted); }
.wo-wk-day.is-today .wo-wk-d, .wo-wk-day.is-today .wo-wk-l { color: var(--text); font-weight: 700; }
.wo-wk-l { font-size: 10.5px; font-weight: 600; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 2px; }
.wo-wk-l.muted { color: var(--muted); }
.wo-wk-dot { width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; }
.wo-wk-dot .ico { width: 15px; height: 15px; }
.wo-wk-dot.done { background: var(--acc-100); color: var(--acc-700); }
.wo-wk-dot.act { background: var(--acc-100); color: var(--acc-700); }
.wo-wk-dot.rest { background: var(--panel); color: var(--n-faint); }
.wo-wk-day.is-today .wo-wk-dot.rest { background: var(--u-tile); }
.wo-wk-dot.today { border: 2px solid var(--acc-500); box-shadow: 0 0 10px rgba(var(--acc-400-rgb),.5); }
.wo-wk-dot.plan { border: 1.5px dashed #cfd3d8; }
:root[data-theme="dark"] .wo-wk-dot.done, :root[data-theme="dark"] .wo-wk-dot.act { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
:root[data-theme="dark"] .wo-wk-dot.plan { border-color: #3a3f46; }

.wo-hero { padding: 18px; position: relative; overflow: hidden; margin-bottom: 12px; }
.wo-hero .hero-title { font-size: 20px; margin-top: 6px; }
.wo-hero .hero-sub { font-size: 12px; margin-top: 2px; }
.wo-hx { background: rgba(255,255,255,.05); border-radius: 14px; margin: 12px 0 14px; cursor: pointer; }
.wo-hx-row { display: flex; align-items: center; gap: 8px; padding: 8px 12px; }
.wo-hx-row + .wo-hx-row { border-top: 1px solid rgba(255,255,255,.06); }
.wo-hx-name { flex: 1; min-width: 0; font-size: 12.5px; font-weight: 600; color: #f3f4f6; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wo-hx-t { font-size: 11px; color: #9ca3af; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wo-chip { font-size: 10.5px; font-weight: 600; padding: 2px 6px; border-radius: 999px; background: rgba(255,255,255,.08); color: #d1d5db; white-space: nowrap; }
.wo-chip.up { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
.wo-chip.down { background: rgba(251,146,60,.15); color: #fb923c; }
.wo-hero .hero-actions { margin-top: 0; }
.wo-other { margin-bottom: 12px; }

.wo-vol { padding: 16px; }
.wo-vol-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.wo-vol-l { display: flex; flex-direction: column; gap: 4px; }
.wo-big { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.wo-big small { font-size: 13px; font-weight: 600; color: var(--muted); margin-left: 3px; }
.wo-delta { font-size: 11px; font-weight: 600; }
.wo-delta.up { color: var(--acc-700); } .wo-delta.down { color: #c2410c; }
:root[data-theme="dark"] .wo-delta.up { color: var(--acc-400); } :root[data-theme="dark"] .wo-delta.down { color: #fb923c; }
.wo-vol .segmented { width: 110px; flex-shrink: 0; }
.wo-vol .segmented button { padding: 5px 10px; font-size: 11.5px; }
.wo-cols { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 6px; height: 80px; margin-top: 14px; }
.wo-cols > div { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; min-width: 0; }
.wo-cols i { display: block; width: 100%; max-width: 22px; border-radius: 6px; background: var(--u-hair); }
.wo-cols i.on { background: var(--text); }
.wo-cols small { font-size: 9.5px; color: var(--muted); font-weight: 500; }
.wo-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; border-top: 1px solid var(--u-hair); margin-top: 12px; padding-top: 12px; }
.wo-stats > div { display: flex; flex-direction: column; gap: 2px; }
.wo-stats b { font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }

.wo-routines { padding: 12px; }
.wo-rt-list .u-row { cursor: pointer; }
.wo-letter { width: 36px; height: 36px; border-radius: 12px; background: var(--n-ink); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; flex-shrink: 0; }
:root[data-theme="dark"] .wo-letter { background: #f3f4f6; color: var(--n-ink); }
.wo-count { font-size: 11px; font-weight: 700; min-width: 22px; height: 22px; padding: 0 6px; box-sizing: border-box; border-radius: 999px; background: var(--panel); color: var(--text); display: inline-flex; align-items: center; justify-content: center; }
.wo-adds { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.wo-add { display: inline-flex; align-items: center; gap: 6px; border: 0; border-radius: 999px; padding: 8px 14px; background: var(--u-tile); color: var(--text); font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; }
.wo-add .ico { width: 15px; height: 15px; }
#generateRoutineBtn .ico { color: var(--acc-500); }

.wo-prog .prog-body { padding: 4px 16px; }
.wo-prog .prog-list { display: block; }
.wo-prog .prog-row { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 0; cursor: pointer; }
.wo-prog .prog-row + .prog-row { border-top: 1px solid var(--u-hair); }
.wo-prog .prog-spark { width: 64px; height: 24px; flex-shrink: 0; }
.wo-prog .prog-val { min-width: 50px; justify-content: flex-end; }
.wo-prog .prog-settings > summary { display: none; }
.wo-prog .prog-settings[open] { margin-top: 10px; padding: 14px 16px; background: var(--panel); border-radius: 22px; box-shadow: var(--u-card); }
.wo-prog .prog-empty { padding: 10px 0; }
.wo-hist .wo-empty { padding: 10px 0; margin: 0; }
.wo-hist .u-val { flex-direction: row; align-items: baseline; }
#view-workouts > .hm-section { margin-top: 18px; }
#view-workouts .hm-section-head .link { font-size: 12px; font-weight: 600; background: none; border: 0; padding: 0; cursor: pointer; color: var(--accent-dark); font-family: inherit; }
.wo-prog .prog-list { background: none; padding: 0; border-radius: 0; box-shadow: none; }

/* ================= Health, matched to the mockup ================= */
.hl-hero { padding: 18px; margin-bottom: 12px; cursor: pointer; }
.hl-hero-in { display: flex; gap: 16px; align-items: center; }
.hl-hero-ring { position: relative; width: 112px; height: 112px; flex-shrink: 0; }
.hl-hero-num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.hl-hero-num b { font-size: 28px; font-weight: 700; color: #fff; text-shadow: 0 0 14px rgba(var(--acc-400-rgb),.45); font-variant-numeric: tabular-nums; }
.hl-hero-num span { font-size: 10.5px; color: var(--n-faint2); font-weight: 500; }
.hl-hero-r { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.hl-hero-f { display: grid; grid-template-columns: minmax(0, 1fr) 64px 22px; gap: 5px 8px; align-items: center; font-size: 10.5px; }
.hl-hero-f > span { color: var(--n-faint2); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hl-hero-f > b { text-align: right; font-weight: 600; color: #f3f4f6; font-variant-numeric: tabular-nums; }
.hl-hero-bar { height: 4px; border-radius: 4px; background: rgba(255,255,255,.1); overflow: hidden; }
.hl-hero-bar i { display: block; height: 100%; border-radius: 4px; }
.hl-hero-note { margin-top: 12px; font-size: 11.5px; color: var(--n-faint2); line-height: 1.4; }

.hl-trends { padding: 16px; }
.hl-trends .hl-tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; background: var(--u-seg); border-radius: 999px; padding: 3px; margin-bottom: 14px; }
.hl-trends .hl-tabs::-webkit-scrollbar { display: none; }
.hl-trends .hl-tab { flex: 0 0 auto; border: 0; background: none; border-radius: 999px; padding: 6px 11px; font: inherit; font-size: 12px; font-weight: 600; color: var(--muted); cursor: pointer; white-space: nowrap; }
.hl-trends .hl-tab.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.hl-trends .hl-trend-head { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "avg range" "read read"; align-items: end; gap: 4px 10px; margin-bottom: 8px; }
.hl-avg { grid-area: avg; display: flex; flex-direction: column; gap: 2px; }
.hl-avg span { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.hl-avg b { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.hl-trends .hl-range { grid-area: range; width: 132px; }
.hl-trends .hl-range button { padding: 5px 8px; font-size: 11.5px; }
.hl-trends .hl-readout { grid-area: read; font-size: 11.5px; }
.hl-trends .hl-readout b { font-size: 12.5px; }
.hl-trends .hl-trend-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; border-top: 1px solid var(--u-hair); margin-top: 12px; padding-top: 12px; }
.hl-trends .hl-trend-stats > div { display: flex; flex-direction: column; gap: 2px; background: none; padding: 0; }
.hl-trends .hl-trend-stats span { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.hl-trends .hl-trend-stats b { font-size: 16px; font-weight: 700; }

.hl-rc-grid { margin-bottom: 12px; }
.hl-rc .hl-spark { width: 100%; height: 36px; }
.hl-rc-st { font-size: 10.5px; font-weight: 600; color: var(--muted); }
.hl-rc-st.good { color: var(--acc-700); } .hl-rc-st.warn { color: #b45309; }
:root[data-theme="dark"] .hl-rc-st.good { color: var(--acc-400); } :root[data-theme="dark"] .hl-rc-st.warn { color: #fbbf24; }
#healthRoot .hl-sleep { margin-bottom: 0; }
#healthRoot .hl-sleep .hl-kv { background: var(--u-tile); border-radius: 14px; padding: 4px 12px; display: block; margin-top: 12px; }
#healthRoot .hl-sleep .hl-kv > div { display: flex; justify-content: space-between; padding: 7px 0; background: none; font-size: 12.5px; }
#healthRoot .hl-sleep .hl-kv > div + div { border-top: 1px solid var(--u-hair); }
#healthRoot .hl-sleep .hl-kv span { color: var(--text); font-weight: 600; font-size: 12.5px; }
#healthRoot .hl-sleep .hl-stack { height: 10px; border-radius: 10px; gap: 2px; }
.hl-brow { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 0; cursor: pointer; }
div.hl-brow { cursor: default; }
.hm-list .hl-brow + .hl-brow { border-top: 1px solid var(--u-hair); }
.hl-bspark { width: 60px; height: 22px; flex-shrink: 0; display: inline-flex; }
.hl-bspark .hl-spark { width: 60px; height: 22px; }
.hl-brow .u-val { min-width: 58px; justify-content: flex-end; flex-direction: row; align-items: baseline; gap: 2px; }
.hl-acts-head { margin-top: 6px; }
#healthRoot > .hm-section { margin-top: 18px; }
#healthRoot .hm-section-head .link { font-size: 12px; font-weight: 600; background: none; border: 0; padding: 0; cursor: pointer; color: var(--accent-dark); font-family: inherit; text-decoration: none; }
.ph-rb.is-spinning .ico { animation: ph-spin 1s linear infinite; }
@keyframes ph-spin { to { transform: rotate(360deg); } }
#healthRoot .hl-trends .hl-plot svg { height: 130px; }
.hl-trends .hl-readout { display: flex; align-items: baseline; gap: 6px; flex-direction: row; }
.hl-trends .hl-readout > * { font-size: 11.5px; }

/* ================= 75 Hard, matched to the mockup ================= */
.h75-ph { margin-bottom: 14px; }
.h75-dk { text-align: center; padding: 22px 18px; margin-bottom: 12px; }
.h75-dk-ring { position: relative; width: 168px; height: 168px; margin: 0 auto; }
.h75-dk-num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.h75-dk-num b { font-size: 44px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; color: #fff; text-shadow: 0 0 16px rgba(var(--acc-400-rgb),.45); font-variant-numeric: tabular-nums; }
.h75-dk-num span { font-size: 11px; color: var(--n-faint2); margin-top: 4px; }
.h75-dk .h75-hero-text { margin-top: 10px; }
.h75-dk .h75-big { font-size: 16px; font-weight: 700; color: #fff; }
.h75-dk .h75-hero-text .muted { font-size: 12px; color: var(--n-faint2); }
.h75-dk .h75-stats3 { text-align: left; border-top: 1px solid rgba(255,255,255,.08); margin-top: 14px; padding-top: 12px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; background: none; }
.h75-dk .h75-stats3 > div { display: flex; flex-direction: column-reverse; gap: 2px; background: none; padding: 0; }
.h75-dk .h75-stats3 span { font-size: 11px; color: var(--n-faint2); font-weight: 600; }
.h75-dk .h75-stats3 b { font-size: 17px; color: #fff; font-weight: 700; }
.h75-dk .h75-stats3 b small { color: var(--n-faint2); font-size: 11px; }
/* evening variant: dark, amber ring, inset task list */
.h75-dk.h75-evening { text-align: left; background: var(--n-hero); border: 0; }
.h75-dk.h75-evening .h75-big { font-size: 18px; }
.h75-dk.h75-evening .dr .t, .h75-dk.h75-evening .dr-track { stroke: var(--d-raise); }
.h75-dk.h75-evening .dr-in b { color: #fff; }
.h75-dk.h75-evening .dr-in span { color: var(--n-faint2); }
.h75-dk.h75-evening .h75-evening-note { color: var(--n-faint2); font-size: 11px; }
.h75-dk .h75-ins { background: rgba(255,255,255,.05); }
.h75-dk .h75-ins .h75-task + .h75-task { border-top-color: rgba(255,255,255,.06); }
.h75-dk .h75-ins .h75-task-text b { color: #f3f4f6; }
.h75-dk .h75-ins .h75-task-text span { color: var(--n-faint2); }
.h75-dk .h75-ins .h75-tile { background: rgba(255,255,255,.08); }
/* one inset list instead of six boxes */
.h75-ins { background: var(--u-tile); border-radius: 16px; padding: 0 12px; margin-top: 12px; }
.h75-ins .h75-task { background: none !important; box-shadow: none !important; border: 0; border-radius: 0; margin: 0; padding: 0; }
.h75-ins .h75-task + .h75-task { border-top: 1px solid var(--u-hair); }
.h75-ins .h75-task-main { padding: 10px 0; background: none; }
.h75-ins .h75-tile { width: 34px; height: 34px; border-radius: 11px; background: var(--panel); }
.h75-ins .h75-task-text b { font-size: 13.5px; }
.h75-ins .h75-task-text > span { font-size: 11.5px; }
.h75-today-t { display: flex; align-items: baseline; gap: 8px; }
.h75-today-t h2 { margin: 0; }
/* compact 75-day map: 15 across, no numbers */
#h75Page .h75-map { grid-template-columns: repeat(15, minmax(0, 1fr)); gap: 4px; }
#h75Page .h75-map .h75-cell { aspect-ratio: 1; height: auto; min-height: 0; border-radius: 5px; font-size: 0; padding: 0; border-width: 0; }
#h75Page .h75-map .h75-cell.future { background: var(--u-hair); }
#h75Page .h75-map .h75-cell.milestone { background: var(--panel); box-shadow: inset 0 0 0 1.5px #c4c8ce; }
#h75Page .h75-map .h75-cell.is-today { background: var(--panel); box-shadow: inset 0 0 0 2px var(--text); }
#h75Page .h75-map .h75-cell.done { background: var(--acc-500); }
.h75-dk-ring.sm { width: 96px; height: 96px; margin: 0; flex-shrink: 0; }
.h75-dk-ring.sm svg { width: 96px; height: 96px; }
.h75-dk-ring.sm .h75-dk-num b { font-size: 22px; text-shadow: 0 0 12px rgba(251,191,36,.45); }
.h75-dk-ring.sm .h75-dk-num span { font-size: 9.5px; margin-top: 2px; }
.h75-dk.h75-evening .h75-evening-top { display: flex; align-items: center; gap: 16px; }
.h75-ins .h75-pill { background: var(--panel); box-shadow: var(--u-card); }
.h75-dk .h75-ins .h75-pill { background: #fff; color: var(--n-ink); }
.h75-dk .h75-ins .h75-bar { background: rgba(255,255,255,.1); }

/* ================= Account, matched to the mockup ================= */
.ac-hero { padding: 18px; margin-bottom: 18px; }
.ac-hero-id { display: flex; align-items: center; gap: 14px; }
.ac-av .avatar-badge { width: 56px; height: 56px; font-size: 18px; box-shadow: 0 0 0 2px var(--n-hero), 0 0 0 3.5px var(--acc-400), 0 0 18px rgba(var(--acc-400-rgb),.45); }
.ac-name { font-size: 18px; font-weight: 700; color: #fff; }
.ac-since { font-size: 12px; color: var(--n-faint2); margin-top: 2px; }
.ac-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; border-top: 1px solid rgba(255,255,255,.08); margin-top: 14px; padding-top: 12px; }
.ac-stats > div { display: flex; flex-direction: column; gap: 2px; }
.ac-stats span { font-size: 11px; color: var(--n-faint2); font-weight: 600; }
.ac-stats b { font-size: 17px; font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.ac-stats b.glow { color: var(--acc-400); text-shadow: 0 0 12px rgba(var(--acc-400-rgb),.5); }
#view-members .hm-section-head .link { font-size: 12px; font-weight: 600; background: none; border: 0; padding: 0; cursor: pointer; color: var(--accent-dark); font-family: inherit; }
.ac-acts { padding: 16px; }
.ac-search { display: flex; align-items: center; gap: 8px; height: 38px; border-radius: 999px; background: var(--u-tile); padding: 0 14px; margin-bottom: 12px; color: var(--muted); }
.ac-search .ico { width: 15px; height: 15px; flex-shrink: 0; }
.ac-search input { flex: 1; border: 0; background: none; outline: none; font: inherit; font-size: 13px; color: var(--text); padding: 0; min-width: 0; box-shadow: none; }
.ac-seg { display: flex; gap: 2px; background: var(--u-seg); border-radius: 999px; padding: 3px; margin-bottom: 14px; overflow-x: auto; scrollbar-width: none; }
.ac-seg::-webkit-scrollbar { display: none; }
.ac-seg .chip { flex: 1 0 auto; border: 0; background: none; border-radius: 999px; padding: 6px 12px; font-size: 12px; font-weight: 600; color: var(--muted); box-shadow: none; }
.ac-seg .chip.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.ac-wk { display: flex; flex-direction: column; gap: 4px; }
.ac-acts .wo-cols { height: 78px; margin-top: 12px; }
.ac-acts .wo-cols small { display: none; }
.ac-hair { height: 1px; background: var(--u-hair); margin: 14px 0 12px; }
.ac-month { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 6px 0 4px; }
.ac-acts .act-list .act-row { padding-left: 0; padding-right: 0; }
.ac-more { width: 100%; margin-top: 10px; border: 0; border-radius: 999px; padding: 10px; background: var(--u-tile); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.ac-trends { padding: 16px; }
.ac-trends .subtabs { display: flex; gap: 2px; background: var(--u-seg); border-radius: 999px; padding: 3px; margin-bottom: 12px; border: 0; }
.ac-trends .subtab { flex: 1; border: 0; background: none; border-radius: 999px; padding: 6px 10px; font-size: 12px; font-weight: 600; color: var(--muted); }
.ac-trends .subtab.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); border: 0; }
.ac-trends .chip-row .chip { font-size: 12px; padding: 5px 11px; }
.ac-trends > .analytics-pane > p.muted { display: none; }
.ac-trends .subtabs { width: 100%; box-sizing: border-box; }
.ac-trends .subtab { white-space: nowrap; }
.ac-trends .chip-row { display: flex; gap: 2px; background: var(--u-seg); border-radius: 999px; padding: 3px; margin-bottom: 12px; flex-wrap: nowrap; overflow-x: auto; }
.ac-trends .chip-row .chip { flex: 1 0 auto; border: 0; background: none; color: var(--muted); box-shadow: none; border-radius: 999px; }
.ac-trends .chip-row .chip.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }

/* ================= Cardio, matched to the mockup ================= */
#cardioRoot .cd-hero { display: block; margin-bottom: 12px; }
.cd-zcard { padding: 16px; margin-bottom: 18px; }
.cd-zc-top { display: flex; justify-content: space-between; align-items: baseline; }
.cd-zc-top b { font-size: 15px; }
.cd-zc-top .link, .cd-wp ~ .link, #cardioRoot .hm-section-head .link { font-size: 12px; font-weight: 600; background: none; border: 0; padding: 0; cursor: pointer; color: var(--accent-dark); font-family: inherit; text-decoration: none; }
.cd-zc-mid { display: flex; align-items: center; justify-content: space-between; margin: 6px 0 12px; }
.cd-zc-range { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.cd-zc-range small { font-size: 12px; color: var(--muted); font-weight: 600; margin-left: 4px; }
.cd-zc-chip { font-size: 11px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: var(--u-tile); }
.cd-zc-bar { position: relative; height: 8px; border-radius: 8px; background: linear-gradient(90deg, #bfdbfe, var(--acc-300) 40%, #fde68a 70%, #fca5a5); }
.cd-zc-band { position: absolute; top: -2px; bottom: -2px; background: var(--acc-500); border-radius: 4px; box-shadow: 0 0 8px rgba(var(--acc-500-rgb),.6); }
.cd-zc-bar u { position: absolute; top: -5px; width: 2px; height: 18px; margin-left: -1px; background: var(--text); border-radius: 2px; text-decoration: none; }
.cd-zc-ends { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--muted); margin-top: 6px; }
.cd-zcard .cd-zone-form > summary { display: none; }
.cd-zcard .cd-zone-form[open] { margin-top: 12px; }
.cd-wp { padding: 12px; }
.cd-wp .u-row { cursor: pointer; gap: 10px; }
.cd-wp-d { width: 30px; font-size: 11.5px; font-weight: 600; color: var(--muted); flex-shrink: 0; }
.cd-wp-row.is-today .cd-wp-d, .cd-wp-row.is-today .u-name { font-weight: 700; color: var(--text); }
.cd-wp-row.is-rest .u-name { color: var(--muted); font-weight: 500; }
.cd-wp-tick { width: 20px; height: 20px; border-radius: 50%; background: var(--acc-500); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.cd-wp-tick svg { width: 12px; height: 12px; fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.cd-wp-today { font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--acc-100); color: var(--acc-700); }
:root[data-theme="dark"] .cd-wp-today { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
.cd-end { padding: 16px; display: flex; flex-direction: column; gap: 4px; }
.cd-end .wo-cols small { display: none; }
.cd-end .wo-cols i.on { background: var(--acc-500); box-shadow: 0 4px 10px -4px rgba(var(--acc-500-rgb),.8); }
.cd-end-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cd-end-stats b small { font-size: 11px; color: var(--muted); font-weight: 600; }
#cardioRoot > .hm-section { margin-top: 0; }
.cd-zcard .cd-zone-form:not([open]) { display: none; }
.cd-zcard .cd-zone-form { background: none; border: 0; padding: 0; }
@media (max-width: 760px) {
  .segmented.train-switch { display: flex; width: 100%; box-sizing: border-box; margin-bottom: 14px; }
  .segmented.train-switch .seg { flex: 1; text-align: center; }
}

/* ================= Plans, matched to the mockup ================= */
#plansRoot .pl-quiz:not(.open) { padding: 14px 16px; }
#plansRoot .pl-quiz:not(.open) .pl-quiz-head { align-items: center; }
#plansRoot .pl-quiz:not(.open) .pl-quiz-headtext h2 { font-size: 14.5px; margin: 0; }
#plansRoot .pl-quiz:not(.open) .pl-quiz-headtext p { margin: 2px 0 0; font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#plansRoot .pl-quiz:not(.open) .pl-quiz-headtext { min-width: 0; flex: 1; }
#plansRoot .pl-quiz:not(.open) [data-pl-quiz-toggle] { flex-shrink: 0; width: auto; }
.pl-head2 { margin-top: 18px; }
.pl-head2 .link { font-size: 12px; font-weight: 600; background: none; border: 0; padding: 0; cursor: pointer; color: var(--accent-dark); font-family: inherit; }
.pl-head2 .link:disabled { color: var(--muted); cursor: default; }
.pl-filter { display: flex; gap: 2px; background: var(--u-seg); border-radius: 999px; padding: 3px; margin-bottom: 12px; }
.pl-filter button { flex: 1; border: 0; background: none; border-radius: 999px; padding: 6px 8px; font: inherit; font-size: 12px; font-weight: 600; color: var(--muted); cursor: pointer; }
.pl-filter button.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
#plansRoot .pl-grid { display: flex; flex-direction: column; gap: 10px; }
.pl-card.pl-card2 { position: relative; display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 22px; background: var(--panel); box-shadow: var(--u-card); border: 0; }
.pl-card2.is-current { box-shadow: 0 0 0 1.5px var(--acc-500), var(--u-card); }
.pl-card2 .pl-emoji { width: 38px; height: 38px; border-radius: 12px; flex-shrink: 0; font-size: 11px; font-weight: 700; }
.pl-c2-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.pl-c2-top { display: flex; align-items: center; gap: 8px; }
.pl-c2-top h3 { margin: 0; font-size: 14.5px; font-weight: 700; flex: 1; min-width: 0; }
.pl-c2-cur { font-size: 10.5px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: var(--acc-100); color: var(--acc-700); white-space: nowrap; }
:root[data-theme="dark"] .pl-c2-cur { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
.pl-c2-check { position: relative; z-index: 2; width: 20px; height: 20px; border-radius: 6px; border: 1.5px solid #cfd3d8; background: var(--panel); color: #fff; font-size: 12px; line-height: 1; padding: 0; cursor: pointer; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; }
.pl-c2-check.on { background: var(--acc-500); border-color: var(--acc-500); }
.pl-c2-meta { font-size: 11.5px; color: var(--muted); font-weight: 500; }
.pl-c2-desc { margin: 2px 0 4px; font-size: 12px; line-height: 1.45; color: var(--text); opacity: .8; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pl-card2 .pl-tags { margin: 0; }
.pl-card2 .pl-tag { font-size: 10.5px; padding: 3px 8px; background: var(--u-tile); }
.pl-more { width: 100%; border: 0; border-radius: 999px; padding: 11px; background: var(--u-tile); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
#plansRoot .pl-card.pl-card2 { flex-direction: row; }
#plansRoot .pl-quiz:not(.open) [data-pl-quiz-toggle] { padding: 7px 14px; font-size: 12.5px; }
.plh-hero { padding: 18px; margin-bottom: 12px; }
.plh-in { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.plh-wk { width: 84px; height: 84px; border-radius: 50%; flex-shrink: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 6px solid var(--d-raise); box-shadow: inset 0 0 0 2px rgba(var(--acc-400-rgb),.0); position: relative; }
.plh-wk::after { content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 3px solid transparent; border-top-color: var(--acc-400); border-right-color: var(--acc-400); filter: drop-shadow(0 0 5px rgba(var(--acc-400-rgb),.7)); }
.plh-wk span { font-size: 10.5px; color: var(--n-faint2); }
.plh-wk b { font-size: 24px; color: var(--acc-400); font-weight: 700; line-height: 1; }
.plh-t { min-width: 0; }
.plh-hero .hero-title { font-size: 19px; margin-top: 4px; }
.plh-hero .hero-sub { font-size: 12px; }

/* ================= Slide-ups, matched to the mockup ================= */
.view-sheet:has(.sh2-head) .wo-sheet-min { display: none; }
.sh2-head { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; }
.sh2-t { flex: 1; min-width: 0; }
.sh2-t h2 { margin: 0; font-size: 18px; font-weight: 700; letter-spacing: -0.01em; }
.sh2-t p { margin: 1px 0 0; font-size: 12px; color: var(--muted); font-weight: 500; }
.sh2-rb { width: 38px; height: 38px; border-radius: 50%; border: 0; background: var(--panel); box-shadow: var(--u-card); color: var(--text); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; padding: 0; }
.sh2-rb .ico { width: 16px; height: 16px; }
.sh2-hero { padding: 16px 18px; margin-bottom: 12px; }
.sh2-hero-top { display: flex; gap: 10px; align-items: flex-start; }
.sh2-hero-l { flex: 1; min-width: 0; }
.sh2-mchips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.sh2-mchips span { font-size: 11.5px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.08); color: #e5e7eb; }
.sh2-mchips span.on { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
.sh2-fig { width: 58px; flex-shrink: 0; }
.sh2-fig .mm-map { display: block; margin: 0; }
.sh2-fig .mm-map figure { margin: 0; }
.sh2-fig .mm-map figure + figure, .sh2-fig figcaption { display: none; }
.sh2-fig .mm-fig { width: 58px; height: auto; }
.sh2-hero .mm-skin, .sh2-hero .mm-fig path:not([data-region]) { fill: #2b2f34; }
.sh2-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; border-top: 1px solid rgba(255,255,255,.08); margin-top: 14px; padding-top: 12px; }
.sh2-stats > div { display: flex; flex-direction: column; gap: 2px; }
.sh2-stats > div + div { border-left: 1px solid rgba(255,255,255,.08); padding-left: 10px; }
.sh2-stats span { font-size: 11px; color: var(--n-faint2); font-weight: 600; }
.sh2-stats b { font-size: 17px; font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.sh2-stats b small { font-size: 11px; color: var(--n-faint2); margin-left: 1px; }
.sh2-card { background: var(--panel); border-radius: 22px; box-shadow: var(--u-card); padding: 14px 16px; margin-bottom: 12px; }
.sh2-card-h { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.sh2-card-h b { font-size: 15px; }
.sh2-link { font-size: 12px; font-weight: 600; color: var(--accent-dark); }
.sh2-num { width: 28px; height: 28px; border-radius: 9px; background: var(--panel); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0; }
.sh2-chip { font-size: 10.5px; font-weight: 600; padding: 3px 8px; border-radius: 999px; background: var(--panel); color: var(--text); white-space: nowrap; }
.sh2-chip.up { background: var(--acc-100); color: var(--acc-700); }
.sh2-chip.down { background: #ffedd5; color: #c2410c; }
:root[data-theme="dark"] .sh2-chip.up { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
:root[data-theme="dark"] .sh2-chip.down { background: rgba(251,146,60,.15); color: #fb923c; }
.sh2-kv { padding: 4px 16px; }
.sh2-kv > div { display: flex; justify-content: space-between; gap: 10px; padding: 11px 0; font-size: 13px; }
.sh2-kv > div + div { border-top: 1px solid var(--u-hair); }
.sh2-kv span { font-weight: 600; }
.sh2-kv b { font-weight: 500; color: var(--muted); text-align: right; }
.sh2-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 4px 0 8px; }
.sh2-actions .btn { width: 100%; justify-content: center; border-radius: 999px; }
.vs-content .mm-card { margin-bottom: 12px; }
.view-sheet-body > .vs-content > .sh2-head:first-child { padding-right: 0; }

/* progress slide-up */
.prog-hero-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.prog-hero-v { font-size: 40px; font-weight: 700; letter-spacing: -0.03em; color: var(--acc-400); text-shadow: 0 0 16px rgba(var(--acc-400-rgb),.45); line-height: 1.05; margin-top: 4px; font-variant-numeric: tabular-nums; }
.prog-hero-v small { font-size: 14px; color: var(--n-faint2); margin-left: 3px; text-shadow: none; }
.prog-hero-ch { font-size: 11px; font-weight: 600; padding: 4px 9px; border-radius: 999px; background: rgba(var(--acc-400-rgb),.12); color: var(--acc-400); white-space: nowrap; }
.prog-hero-ch.down { background: rgba(251,146,60,.12); color: #fb923c; }
.prog-hero .prog-metric { margin: 10px 0 4px; }
.prog-hero .segmented { background: rgba(255,255,255,.06); width: 180px; }
.prog-hero .segmented button { color: var(--n-faint2); font-size: 11.5px; padding: 5px 10px; }
.prog-hero .segmented button.active { background: rgba(255,255,255,.12); color: #fff; box-shadow: none; }
.prog-hero .prog-chart { margin-top: 6px; }
.prog-hero .prog-chart-axis { display: none; }
.prog-hero .prog-line { stroke: var(--acc-400); filter: drop-shadow(0 0 4px rgba(var(--acc-400-rgb),.6)); }
.prog-hero .prog-fill-top { stop-color: rgba(var(--acc-400-rgb),.25); }
.prog-hero .prog-fill-bottom { stop-color: rgba(var(--acc-400-rgb),0); }
.prog-hero .prog-chart-labels span { color: var(--n-faint2); }
.prog-hero .prog-chart-dots span { background: var(--n-hero); border-color: var(--acc-400); }
.prog-hero .prog-chart-bubble { background: #fff; color: var(--n-ink); }
.prog-ns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.prog-ns > div { display: flex; flex-direction: column; gap: 2px; }
.prog-ns > div + div { border-left: 1px solid var(--u-hair); padding-left: 10px; }
.prog-ns span { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.prog-ns b { font-size: 17px; font-weight: 700; }
.prog-ns b small { font-size: 11px; color: var(--muted); margin-left: 2px; }
.prog-ns-why { margin: 12px 0 0; padding: 10px 12px; border-radius: 14px; background: var(--u-tile); font-size: 12px; line-height: 1.45; color: var(--muted); }
.prog-hist .u-row { padding: 10px 0; background: none; border-radius: 0; }
.prog-hist .u-row + .u-row { border-top: 1px solid var(--u-hair); }
.prog-hist .u-val { flex-direction: row; align-items: baseline; gap: 2px; }
.view-sheet-body > .vs-content.prog-detail-sheet > :first-child, .view-sheet-body > .vs-content > .prog-detail-sheet > :first-child { padding-right: 0; }
.prog-hero .prog-chart-bubble { background: #fff !important; color: var(--n-ink) !important; }

/* activity slide-up */
.act-hero-top { display: flex; justify-content: space-between; align-items: flex-start; }
.act-hero-tags { display: flex; align-items: center; gap: 6px; }
.act-hero .icon-tile { background: rgba(255,255,255,.08); }
.act-hr { position: relative; height: 8px; border-radius: 8px; background: linear-gradient(90deg, #93c5fd, var(--acc-400) 35%, #fbbf24 65%, #f97316 85%, #ef4444); margin: 8px 0 6px; }
.act-hr i { position: absolute; top: -4px; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%; box-sizing: border-box; }
.act-hr-avg { background: var(--panel); border: 3px solid var(--text); }
.act-hr-max { background: var(--panel); border: 2px dashed var(--muted); }
.act-hr-ends { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--muted); }
.act-counts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
a.ac-more.act-open { display: block; text-align: center; text-decoration: none; box-sizing: border-box; }
.act-links { display: flex; justify-content: center; gap: 22px; margin: 12px 0 4px; }
.act-links .link { background: none; border: 0; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--accent-dark); cursor: pointer; padding: 0; }
.act-note { text-align: center; }

/* Health detail slide-ups (monitor, stress, energy, load): left title, dark hero */
.view-sheet-body .st-head { display: block; text-align: left; padding-right: 50px; margin-bottom: 10px; }
.view-sheet-body .st-head .vs-title { font-size: 18px; font-weight: 700; text-align: left; }
.view-sheet-body .st-head .st-datenav { justify-content: flex-start; margin: 2px 0 0; }
.view-sheet-body .st-head .st-datenav span { font-size: 12px; color: var(--muted); font-weight: 500; }
.view-sheet-body .mo-hero { background: var(--n-hero); color: #f3f4f6; align-items: flex-start; text-align: left; position: relative; overflow: hidden; box-shadow: 0 10px 30px rgba(var(--n-ink-rgb),.18); }
.view-sheet-body .mo-hero::before { content: ''; position: absolute; right: -40px; top: -60px; width: 200px; height: 200px; border-radius: 50%; background: radial-gradient(circle, rgba(var(--acc-400-rgb),.2), rgba(var(--acc-400-rgb),0) 70%); pointer-events: none; }
.view-sheet-body .mo-hero-val { color: var(--acc-400); text-shadow: 0 0 18px rgba(var(--acc-400-rgb),.45); }
.view-sheet-body .mo-hero-val small, .view-sheet-body .mo-hero .muted, .view-sheet-body .mo-hero .mo-hero-sub small { color: var(--n-faint2); text-shadow: none; }
.view-sheet-body .mo-hero .mo-hero-sub { color: #fff; }
.view-sheet-body .mo-hero .mo-pill.good { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
.view-sheet-body .mo-hero .mo-pill.warn { background: rgba(251,146,60,.15); color: #fb923c; }
.view-sheet-body .mo-hero .mo-pill.muted { background: rgba(255,255,255,.08); color: #d1d5db; }
.view-sheet-body .mo-hero .mo-range, .view-sheet-body .mo-hero .mo-center { max-width: none; text-align: left; }
.view-sheet-body .mo-hero .mo-range-track { background: rgba(255,255,255,.08); box-shadow: none; }
.view-sheet-body .mo-hero .mo-range-track b { background: var(--n-hero); }
.view-sheet-body .mo-hero .mo-range-labels span, .view-sheet-body .mo-hero text { color: var(--n-faint2); fill: var(--n-faint2); }
.view-sheet-body .mo-hero svg text { fill: var(--n-faint2); }
.view-sheet-body .mo-hero > * { position: relative; }
.view-sheet-body .mo-hero.mo-empty { background: var(--panel); color: var(--text); }
.view-sheet-body .mo-hero.mo-empty::before { display: none; }
.view-sheet-body .st-head, .view-sheet-body > .vs-content > .st-head:first-child { padding-left: 0 !important; }
.view-sheet-body .st-coach p { font-size: 13px; line-height: 1.45; }
.view-sheet-body .st-coach .st-coach-title { font-size: 12px; }
.view-sheet-body :is(.st-sheet, .en-sheet, .mo-sheet) > .st-head:first-child { padding: 0 50px 0 0; }
.view-sheet-body :is(.st-sheet, .en-sheet) > .st-head:first-child .st-info-btn { right: 50px; }
/* checks slide-up */
.ck-hero-k { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #a78bfa; }
.view-sheet-body .ck-list { background: var(--panel); border-radius: 22px; box-shadow: var(--u-card); padding: 10px; }
.view-sheet-body .ck-list .ck-row { background: var(--u-tile); border-radius: 0; margin: 0; }
.view-sheet-body .ck-list .ck-row:first-child { border-radius: 14px 14px 0 0; }
.view-sheet-body .ck-list .ck-row:last-child { border-radius: 0 0 14px 14px; }
.view-sheet-body .ck-list .ck-row:only-child { border-radius: 14px; }
.view-sheet-body .ck-list .ck-row + .ck-row { border-top: 1px solid var(--u-hair); }

/* plan preview slide-up */
.plp-hero .plp-desc { margin: 8px 0 0; font-size: 12.5px; line-height: 1.45; color: #d1d5db; }
.plp-glow { color: var(--acc-400) !important; text-shadow: 0 0 12px rgba(var(--acc-400-rgb),.5); }
.plp-rec { margin-top: 12px; padding: 10px 12px; border-radius: 12px; background: rgba(255,255,255,.06); font-size: 12px; color: #d1d5db; }
.plp-rec b { color: var(--acc-400); }
.plp-week { padding: 0 12px; }
.plp-week .pl-wday { display: flex; align-items: center; gap: 12px; padding: 10px 0; background: none; border: 0; border-radius: 0; margin: 0; box-shadow: none; }
.plp-week .pl-wday + .pl-wday { border-top: 1px solid var(--u-hair); }
.plp-week .pl-wday-dow { width: 30px; font-size: 11.5px; font-weight: 600; color: var(--muted); flex-shrink: 0; }
.plp-week .pl-wday-main { flex: 1; min-width: 0; }
.plp-week .pl-wday-name { font-size: 13.5px; font-weight: 600; }
.plp-week .pl-wday-focus { font-size: 11.5px; color: var(--muted); }
.plp-week .pl-wday:not(.is-training) .pl-wday-name { color: var(--muted); font-weight: 500; }
.plp-week .pl-wday:not(.is-training) .pl-wday-focus { display: none; }
.plp-week .pl-style { font-size: 10.5px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--panel); color: var(--text); text-transform: capitalize; border: 0; }
.plp-gen { display: block; }
.plp-lbl { font-size: 11.5px; font-weight: 600; color: var(--muted); margin: 4px 0 8px; }
.plp-days { display: grid !important; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; margin-bottom: 12px; }
.plp-days .pl-daybtn { height: 38px; border-radius: 12px; border: 0; background: var(--u-tile); color: var(--muted); font-weight: 700; font-size: 13px; padding: 0; box-shadow: none; }
.plp-days .pl-daybtn.on { background: var(--n-hero); color: var(--acc-400); }
:root[data-theme="dark"] .plp-days .pl-daybtn.on { background: #f3f4f6; color: var(--acc-700); }
.plp-rows { margin-bottom: 12px; }
.plp-rows .u-row { cursor: pointer; }
.plp-rows select { border: 0; background: none; font: inherit; font-size: 12.5px; color: var(--muted); text-align: right; padding: 0 4px; box-shadow: none; width: auto; max-width: 55%; }
.plp-go { margin: 4px 0 14px; display: flex; flex-direction: column; gap: 8px; text-align: center; }
.plp-go .btn { width: 100%; justify-content: center; border-radius: 999px; }
.plp-more > summary { display: flex; justify-content: space-between; align-items: baseline; cursor: pointer; list-style: none; }
.plp-more > summary::-webkit-details-marker { display: none; }
.plp-more[open] > summary { margin-bottom: 10px; }
.plp-more .pl-meta { background: none; box-shadow: none; padding: 0; }
.plp-rows .u-row { padding-top: 8px; padding-bottom: 8px; min-height: 0; }
.plp-gen .pl-chip { font-size: 12px; padding: 6px 12px; }

/* ================= Live workout, matched to the mockup ================= */
.lv-head { display: grid; grid-template-columns: 64px 1fr 64px; align-items: center; gap: 8px; margin: 0 0 12px; }
.lv-head .ph-mid h1 { font-size: 20px; }
.lv-finish { justify-self: end; border: 0; border-radius: 999px; padding: 8px 14px; background: var(--acc-500); color: #fff; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; box-shadow: 0 6px 16px -6px rgba(var(--acc-500-rgb),.8); }
.lv-hero { padding: 16px 18px; margin-bottom: 12px; }
.lv-hero-in { display: flex; gap: 16px; align-items: center; }
.lv-ring { position: relative; width: 108px; height: 108px; flex-shrink: 0; }
.lv-ring-in { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.lv-ring-in span { font-size: 10.5px; color: var(--n-faint2); }
.lv-ring-in b { font-size: 20px; color: var(--acc-400); text-shadow: 0 0 12px rgba(var(--acc-400-rgb),.5); }
.lv-hero-r { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.lv-timer { font-size: 32px; font-weight: 700; color: #fff; letter-spacing: -0.02em; line-height: 1.1; }
.lv-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.lv-stats > div + div { border-left: 1px solid rgba(255,255,255,.08); padding-left: 10px; }
.lv-stats span { display: block; font-size: 11px; color: var(--n-faint2); font-weight: 600; }
.lv-stats b { font-size: 17px; color: #fff; font-weight: 700; }
.lv-stats b small { font-size: 11px; color: var(--n-faint2); margin-left: 1px; }
.lv-bar { height: 5px; border-radius: 5px; background: rgba(255,255,255,.1); margin-top: 14px; overflow: hidden; }
.lv-bar i { display: block; height: 100%; background: var(--acc-500); border-radius: 5px; box-shadow: 0 0 8px rgba(var(--acc-400-rgb),.7); }
.lv-rest { border-radius: 16px; margin-bottom: 12px; }
.lv-current { padding: 14px 16px; }
.lv-current .workout-exercise-block { border: 0; padding: 0; margin: 0; background: none; box-shadow: none; }
.lv-legend { margin-top: 10px; font-size: 12px; color: var(--muted); }
.lv-legend > summary { cursor: pointer; font-weight: 600; }
.lv-list { padding: 10px; }
.lv-list .lv-row { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; cursor: pointer; }
.lv-list .lv-row + .lv-row { border-top: 1px solid var(--u-hair); }
.lv-list .lv-row.is-done .u-name { color: var(--muted); }
.lv-list .lv-row.is-done .sh2-num { background: var(--acc-500); color: #fff; }
.lv-list .u-ins { padding: 0; }
.lv-next-h { margin-top: 18px; }
.lv-add { display: flex; gap: 8px; align-items: center; margin-top: 10px; }
.lv-add .ac-search { flex: 1; margin: 0; }
.lv-discard { display: block; margin: 14px auto 20px; border: 0; background: none; color: #dc2626; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
#woSheet .wo-sheet-min { left: 16px; right: auto; }
.lv-current .workout-sets-table .scroll-pick-display { background: var(--u-tile); border: 0; box-shadow: none; border-radius: 12px; font-weight: 600; }
.lv-current .workout-sets-table tr.workout-set-done .scroll-pick-display { background: var(--acc-100); color: var(--acc-700); }
:root[data-theme="dark"] .lv-current .workout-sets-table tr.workout-set-done .scroll-pick-display { background: rgba(var(--acc-400-rgb),.15); color: var(--acc-400); }
.lv-current .workout-sets-table th { font-size: 10.5px; font-weight: 600; color: var(--muted); text-transform: none; letter-spacing: 0; }
.lv-current .wo-prev { background: var(--u-tile); border: 0; }

/* Account: connections and app settings as a settings list */
.ac-kick { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 18px 4px 8px; }
#view-members .panel.ac-set { padding: 14px 16px; margin-bottom: 0; border-radius: 18px; }
#view-members .panel.ac-set > h2:first-child { display: none; }
.ac-app-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 14px; font-weight: 600; }
.ac-theme { width: 150px; }
.ac-theme button { padding: 6px 10px; font-size: 12.5px; }

/* ================= Slide-up headers: centred like the page headers =================
   Title and its subtitle or date pager sit in the middle, the round close button on
   the right and any info / edit button on the left, so every sheet reads the same. */
.sh2-head { display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; gap: 8px; }
.sh2-head .sh2-t { grid-column: 2; grid-row: 1; text-align: center; }
.sh2-head .sh2-rb[data-vs-dismiss] { grid-column: 3; grid-row: 1; justify-self: end; }
.sh2-head .sh2-rb:not([data-vs-dismiss]) { grid-column: 1; grid-row: 1; justify-self: start; }
.sh2-t p { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.view-sheet-body .st-head,
.view-sheet-body > .vs-content > .st-head:first-child,
.view-sheet-body :is(.st-sheet, .en-sheet, .mo-sheet) > .st-head:first-child { display: block; text-align: center; padding: 0 50px !important; min-height: 40px; margin-bottom: 12px; }
.view-sheet-body .st-head .vs-title { text-align: center; }
.view-sheet-body .st-head .st-datenav { display: flex; justify-content: center; margin: 4px 0 0; }
.view-sheet-body .st-head .st-nav { width: 28px; height: 28px; box-shadow: none; background: var(--u-tile); }
.view-sheet-body .st-head .st-nav svg { width: 15px; height: 15px; }
.view-sheet-body .st-head .st-info-btn,
.view-sheet-body :is(.st-sheet, .en-sheet) > .st-head:first-child .st-info-btn { left: 0; right: auto; top: 0; width: 40px; height: 40px; box-shadow: var(--u-card); }
/* Detail heroes keep their content centred, the way the ring and gauge sit */
.view-sheet-body .mo-hero { align-items: center; text-align: center; }
.view-sheet-body .mo-hero .mo-range, .view-sheet-body .mo-hero .mo-center { text-align: center; width: 100%; }
/* Past workout sheet: title centred, recap on the left, the sheet's own close on the right */
.wo-past-head .sh2-rb#recapWorkoutBtn { grid-column: 1; }
.sh2-head.wo-past-head > .sh2-rb[data-lv-min] { grid-column: 3; grid-row: 1; justify-self: end; }
.wo-past-head [data-lv-min] svg, .wo-past-head #recapWorkoutBtn svg { width: 17px; height: 17px; }
#woSheet:has(.wo-past-head) .wo-sheet-min { display: none; }
#woSheet.viewing .wo-sheet-min { left: auto; right: 16px; }
/* Home, 75 Hard and food sheets: the same centred header */
.view-sheet-body .vs-head { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 50px; min-height: 40px; justify-content: center; margin-bottom: 12px; }
.view-sheet-body .vs-head .vs-head-text { display: flex; flex-direction: column; align-items: center; }
.view-sheet-body .vs-head .vs-title { font-size: 18px; font-weight: 700; text-align: center; margin: 0; }
.view-sheet-body .vs-head .muted { font-size: 12px; }
.h75-sh-head { align-items: center; text-align: center; padding: 0 50px; min-height: 40px; justify-content: center; }
.h75-sh-head .muted { font-size: 12px; }
.fd-sh-head:not(.between), .fd-sheet > .fd-sh-head:not(.between):first-child { position: relative; justify-content: center; text-align: center; padding: 0 50px; min-height: 40px; }
.fd-sh-head:not(.between) > div { align-items: center; }
.fd-sh-head:not(.between) > .fd-round { position: absolute; left: 0; top: 0; }
.fd-sh-head h2 { font-size: 18px; }
.fd-sh-head .muted { font-size: 12px; }
/* Readiness and effort sheets: the status line under the ring sits centred too */
.view-sheet-body .hm-status-big { text-align: center; }
.view-sheet-body .hm-status-big { display: flex; justify-content: center; width: fit-content; margin-left: auto; margin-right: auto; }

/* ================= Live workout: header and exercise card, matched to the mockup ================= */
#woSheet:has(.lv-head) .wo-sheet-min { display: none; }
.lv-head { grid-template-columns: 40px 1fr auto; min-height: 40px; }
.lv-head .lv-min { width: 40px; height: 40px; }
.lv-head .lv-min svg { width: 18px; height: 18px; }
.lv-finish { height: 40px; padding: 0 16px; }
.lv-ex-head { display: flex !important; align-items: center; gap: 12px; margin: 0 0 12px !important; flex-wrap: nowrap !important; }
.lv-ex-tile { width: 40px; height: 40px; border-radius: 12px; background: var(--u-tile); flex-shrink: 0; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; }
.lv-ex-tile .wo-thumb { width: 100%; height: 100%; object-fit: cover; border-radius: 0; margin: 0; }
.lv-ex-tile .wo-tile-icon { width: auto; height: auto; background: none; font-size: 12px; font-weight: 700; color: var(--muted); }
.lv-ex-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.lv-ex-t strong { font-size: 15px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lv-ex-t span { font-size: 11.5px; color: var(--muted); font-weight: 500; }
.lv-ex-more { width: 36px; height: 36px; background: var(--u-tile); box-shadow: none; }
.lv-ex-more svg { width: 18px; height: 18px; fill: currentColor; }
.lv-target { background: var(--u-tile); border-radius: 14px; padding: 10px 12px; margin: 0 0 12px; display: flex; flex-direction: column; gap: 4px; }
.lv-target .prog-live { margin: 0; padding: 0; background: none; border: 0; box-shadow: none; }
.lv-target .prog-live-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.lv-target .prog-chip { background: var(--panel); border-radius: 999px; padding: 3px 10px; font-size: 11.5px; font-weight: 600; border: 0; box-shadow: none; }
.lv-target .prog-target { font-size: 12.5px; font-weight: 600; color: var(--text); }
.lv-target .prog-target-label { color: var(--muted); font-weight: 500; }
.lv-target .prog-reason, .lv-target .prog-hint, .lv-last { font-size: 11.5px; line-height: 1.4; color: var(--muted); margin: 0; padding: 0; background: none; border: 0; text-align: left; }
.lv-ex .wu-line { margin: 0 0 8px; padding: 0 2px; background: none; border: 0; font-size: 11.5px; }
.lv-ex .wu-stats { color: var(--muted); }
.lv-current .workout-sets-table { width: 100%; border-collapse: separate; border-spacing: 0 6px; margin: 0 0 4px; }
.lv-current .workout-sets-table th { padding: 0 4px 2px; text-align: center; }
.lv-current .workout-sets-table th:first-child { text-align: left; }
.lv-current .workout-sets-table td { padding: 0 3px; border: 0; vertical-align: middle; }
.lv-current .workout-sets-table tr { border: 0; background: none; }
.lv-current .workout-sets-table .scroll-pick-display { height: 40px; display: flex; align-items: center; justify-content: center; font-size: 15px; }
.lv-current .workout-sets-table tr.workout-set-done .scroll-pick-display { background: var(--acc-100); }
.lv-current .set-type { min-width: 26px; height: 22px; border-radius: 7px; background: var(--u-tile); display: inline-flex; align-items: center; justify-content: center; border: 0; }
.lv-current .set-type-label { font-size: 11px; font-weight: 700; }
.lv-current .set-type-warmup { background: #fff7ed; color: #c2410c; }
:root[data-theme="dark"] .lv-current .set-type-warmup { background: rgba(251,146,60,.15); color: #fb923c; }
.lv-current .btn-set-done { width: 32px; height: 32px; border-radius: 50%; border: 1.5px solid var(--u-hair); background: var(--panel); color: transparent; padding: 0; display: inline-flex; align-items: center; justify-content: center; box-shadow: none; }
.lv-current .btn-set-done svg { width: 18px; height: 18px; }
.lv-current .btn-set-done.done { background: var(--acc-500); border-color: var(--acc-500); color: #fff; box-shadow: 0 0 10px rgba(var(--acc-500-rgb),.45); }
.lv-ex-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.lv-pill { height: 40px; border-radius: 999px; border: 0; background: var(--u-tile); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer; padding: 0 12px; width: 100%; margin: 0; }
.lv-pill svg { width: 15px; height: 15px; }
.lv-pill.on { background: var(--text); color: var(--panel); }
.lv-current .lv-legend { margin-top: 10px; padding: 10px 12px; border-radius: 14px; background: var(--u-tile); }
.lv-current .lv-legend .set-type-legend { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; }

/* ================= Finished workout sheet ================= */
.ps-hero-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.ps-big { font-size: 30px; font-weight: 700; color: var(--acc-400); text-shadow: 0 0 16px rgba(var(--acc-400-rgb),.45); letter-spacing: -0.02em; line-height: 1.1; margin-top: 4px; }
.ps-big small { font-size: 13px; color: var(--n-faint2); text-shadow: none; font-weight: 600; margin-left: 3px; letter-spacing: 0; }
.ps-pct { text-align: right; display: flex; flex-direction: column; }
.ps-pct b { font-size: 18px; color: #fff; font-weight: 700; }
.ps-pct span { font-size: 11px; color: var(--n-faint2); }
.ps-hero .sh2-stats { margin-top: 14px; }
.ps-hero.is-abandoned .hero-tag { color: #fb923c; }
.ps-hero.is-abandoned .ps-big { color: #fff; text-shadow: none; }
.ps-muscles > * { margin-bottom: 12px; }
.ps-ex-h { margin: 6px 2px 8px; display: flex; align-items: baseline; justify-content: space-between; }
.ps-ex-h h2 { font-size: 15px; margin: 0; }
.ps-list { padding: 4px 14px; }
.ps-ex { padding: 12px 0; }
.ps-ex + .ps-ex { border-top: 1px solid var(--u-hair); }
.ps-ex-head { display: flex; align-items: center; gap: 12px; }
.ps-ex-head .lv-ex-t strong { font-size: 14px; }
.ps-best { display: flex; flex-direction: column; align-items: flex-end; flex-shrink: 0; }
.ps-best b { font-size: 15px; font-weight: 700; }
.ps-best small { font-size: 10.5px; color: var(--muted); }
.ps-sets { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0 52px; }
.ps-set { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px 5px 6px; border-radius: 999px; background: var(--u-tile); font-size: 12px; font-weight: 600; color: var(--muted); }
.ps-set i { font-style: normal; font-size: 10px; font-weight: 700; min-width: 18px; height: 18px; border-radius: 6px; background: var(--panel); display: inline-flex; align-items: center; justify-content: center; color: var(--muted); }
.ps-set em { font-style: normal; font-size: 10.5px; font-weight: 500; color: var(--muted); }
.ps-set.is-done { color: var(--text); }
.ps-set.is-done i { background: var(--acc-500); color: #fff; }
.ps-set.set-warmup.is-done i { background: #fb923c; }
.ps-link { margin: 8px 0 0 52px; font-size: 11.5px; color: var(--muted); }

.lv-timer { font-family: inherit; font-variant-numeric: tabular-nums; }

/* Activity sheet: route and splits */
.act-detail:empty { display: none; }
.act-route-wrap { padding: 8px; }
.act-route-wrap.act-loading { padding: 18px 14px; text-align: center; }
.act-route { display: block; width: 100%; height: auto; border-radius: 14px; background: #15171c; }
.act-route-shadow { fill: none; stroke: rgba(var(--acc-500-rgb), .25); stroke-width: 9; stroke-linecap: round; stroke-linejoin: round; }
.act-route-line { fill: none; stroke: var(--acc-400, var(--accent)); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.act-route-start { fill: #fff; stroke: var(--accent); stroke-width: 3; }
.act-route-end { fill: #15171c; stroke: #fff; stroke-width: 3; }
.act-route-key { display: flex; gap: 14px; padding: 8px 6px 2px; font-size: 11px; color: var(--muted); }
.act-route-key i { display: inline-block; width: 9px; height: 9px; margin-right: 5px; border-radius: 50%; vertical-align: -1px; }
.act-route-key i.s { background: #fff; border: 2px solid var(--accent); }
.act-route-key i.e { background: #15171c; border: 2px solid var(--muted); }
.act-splits { display: grid; gap: 6px; }
.act-split { display: grid; grid-template-columns: 34px 1fr 46px 30px 34px; align-items: center; gap: 8px; font-size: 12px; }
.act-split b { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.act-split-n { color: var(--muted); font-variant-numeric: tabular-nums; }
.act-split-x { text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; }
.act-split-bar { height: 8px; border-radius: 99px; background: var(--u-tile, #f1f2f4); overflow: hidden; }
.act-split-bar i { display: block; height: 100%; border-radius: 99px; background: rgba(var(--acc-500-rgb), .45); }
.act-split.best .act-split-bar i { background: var(--accent); }
.act-split.best b { color: var(--accent-dark, var(--accent)); }
.act-split-head { font-size: 10px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.act-split-head b { font-weight: 600; color: var(--muted); }
:root[data-theme="dark"] .act-split-bar { background: rgba(255, 255, 255, .08); }
:root[data-theme="dark"] .act-split.best b { color: var(--acc-400); }

/* Settings → Reminders */
#nudgesPanel .nu-row + .nu-row { margin-top: 8px; }
#nudgesPanel .nu-foot { margin: 10px 2px 0; }
#nudgesPanel .nu-bed { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 8px 2px 0; font-size: 14px; font-weight: 600; }
#nudgesPanel .nu-bed input { font: inherit; font-weight: 700; padding: 6px 10px; border-radius: 10px; border: 1px solid var(--border); background: var(--panel-2); color: var(--text); }
#nudgesPanel .nu-bed + .nu-row { margin-top: 8px; }

/* Offline queue */
.asc-offline { position: fixed; left: 50%; top: calc(env(safe-area-inset-top, 0px) + 10px); transform: translateX(-50%); z-index: 9000; max-width: calc(100vw - 32px); padding: 8px 14px; border-radius: 99px; background: #1f2937; color: #fff; font-size: 12px; font-weight: 600; box-shadow: 0 6px 20px rgba(0, 0, 0, .2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.asc-offline::before { content: ''; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: #f59e0b; vertical-align: 0; }
.asc-offline[hidden], .asc-offline-toast[hidden] { display: none; }
.asc-offline-toast { position: fixed; left: 50%; bottom: calc(env(safe-area-inset-bottom, 0px) + 110px); transform: translateX(-50%); z-index: 9000; width: max-content; max-width: calc(100vw - 32px); padding: 12px 16px; border-radius: 16px; background: #111827; color: #fff; font-size: 13px; line-height: 1.4; box-shadow: 0 8px 24px rgba(0, 0, 0, .25); }

/* Settings → Your data (CSV export) */
.ex-panel > p { margin: 0 2px 10px; line-height: 1.45; }
.ex-list { background: var(--u-tile); border-radius: 16px; overflow: hidden; }
.ex-row { display: flex; flex-direction: column; gap: 2px; padding: 11px 40px 11px 14px; color: inherit; text-decoration: none; position: relative; }
.ex-row + .ex-row { border-top: 1px solid var(--u-hair); }
.ex-row b { font-size: 14px; }
.ex-row span { font-size: 12px; color: var(--muted); }
.ex-row::after { content: ''; position: absolute; right: 16px; top: 50%; width: 9px; height: 9px; margin-top: -7px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); }

/* Safety net: a text-link button never falls back to the browser's grey box. */
:where(button.link) { background: none; border: 0; padding: 0; font: inherit; font-weight: 600; color: var(--accent-dark); cursor: pointer; }

/* Press feel (same easing as the tour): things you tap shrink a touch and
   spring back. Cards scale; list rows just tint, since a row shrinking inside
   its list looks broken. */
.btn, button.panel, a.panel, .card-link, .hl-tile, .standing-card, .hm-ring, .hm-tl-row, .ch-card, .qs-tpl, .qs-step, .fab, .tu-btn, .ac-more, .fd-chip {
  transition: transform .22s cubic-bezier(.2, .8, .2, 1), opacity .15s ease, background-color .15s ease, box-shadow .2s ease;
}
.btn:active:not(:disabled), .tu-btn:active, .ac-more:active, .fd-chip:active { transform: scale(.96); transition-duration: .08s; }
button.panel:active, a.panel:active, .card-link:active, .hl-tile:active:not([disabled]), .standing-card:active, .ch-card:active { transform: scale(.98); transition-duration: .1s; }
:where(a.u-row, button.u-row) { transition: background-color .15s ease; }
:where(a.u-row, button.u-row):active { background-color: rgba(var(--n-ink-rgb), .05); }
:root[data-theme="dark"] :where(a.u-row, button.u-row):active { background-color: rgba(255, 255, 255, .05); }
@media (prefers-reduced-motion: reduce) {
  .btn:active, .tu-btn:active, .ac-more:active, .fd-chip:active, button.panel:active, a.panel:active, .card-link:active, .hl-tile:active, .standing-card:active, .ch-card:active { transform: none; }
}

/* Scroll picker: type-a-value row (tap to type any weight, − / + nudge by one step) */
.scroll-pick-type { display: flex; align-items: center; gap: 8px; margin-top: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--u-hair); }
.scroll-pick-nudge { flex: 0 0 auto; width: 44px; height: 44px; border: 0; border-radius: 12px; background: var(--u-tile); color: var(--text); font-size: 22px; font-weight: 600; line-height: 1; cursor: pointer; }
.scroll-pick-nudge:active { transform: scale(.94); }
.scroll-pick-entry { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; height: 44px; padding: 0 12px; border-radius: 12px; background: var(--u-tile); }
.scroll-pick-entry:focus-within { box-shadow: 0 0 0 2px var(--acc-500, var(--emphasis)); }
.scroll-pick-entry input { flex: 1 1 auto; min-width: 0; width: 100%; border: 0; background: transparent; color: var(--text); font-size: 17px; font-weight: 600; text-align: center; outline: none; padding: 0; box-shadow: none; }
.scroll-pick-entry i { font-style: normal; color: var(--muted); font-size: 14px; margin-left: 4px; }
.scroll-pick-entry i:empty { display: none; }
.scroll-pick-set { flex: 0 0 auto; height: 44px; padding: 0 16px; border-radius: 12px; }
.scroll-pick-hint { min-height: 0; font-size: 12px; color: var(--danger, #d33); text-align: center; margin-top: 4px; }
.scroll-pick-hint:empty { display: none; }
