:root {
  color-scheme: light;
  --surface-0: #f4f3f0;
  --surface-1: #fcfcfb;
  --text-primary: #0b0b0b;
  --text-secondary: #52514e;
  --muted: #898781;
  --grid: #e1e0d9;
  --border: rgba(11, 11, 11, 0.1);
  --accent: #2a78d6;
  --accent-ink: #ffffff;
  --series-1: #2a78d6;
  --series-1-wash: rgba(42, 120, 214, 0.1);
  /* Heart rate zones 1 to 5: distinct hues (owner's choice, 2026-10-24; sky blue, green, purple, yellow, red; passes the
     CVD and normal-vision checks in both modes); gray for minutes with no heart rate detail */
  --zone-1: #3d9be0; --zone-2: #2e9e4f; --zone-3: #8e5bd0; --zone-4: #e3b21c; --zone-5: #d1342b; --zone-none: #d3d2cb;
  --danger: #c0392b;
  --good: #1f7a3a;
  --radius: 10px;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --surface-0: #121211;
    --surface-1: #1a1a19;
    --text-primary: #ffffff;
    --text-secondary: #c3c2b7;
    --muted: #898781;
    --grid: #2c2c2a;
    --border: rgba(255, 255, 255, 0.1);
    --accent: #3987e5;
    --accent-ink: #0b0b0b;
    --series-1: #3987e5;
    --series-1-wash: rgba(57, 135, 229, 0.12);
    --zone-1: #5aaef0; --zone-2: #3fb862; --zone-3: #a77ef0; --zone-4: #f0c43a; --zone-5: #ec5a4f; --zone-none: #3d3d3a;
    --danger: #e66767;
    --good: #4cbf6b;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --surface-0: #121211;
  --surface-1: #1a1a19;
  --text-primary: #ffffff;
  --text-secondary: #c3c2b7;
  --muted: #898781;
  --grid: #2c2c2a;
  --border: rgba(255, 255, 255, 0.1);
  --accent: #3987e5;
  --accent-ink: #0b0b0b;
  --series-1: #3987e5;
  --series-1-wash: rgba(57, 135, 229, 0.12);
    --zone-1: #5aaef0; --zone-2: #3fb862; --zone-3: #a77ef0; --zone-4: #f0c43a; --zone-5: #ec5a4f; --zone-none: #3d3d3a;
  --danger: #e66767;
  --good: #4cbf6b;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--surface-0); color: var(--text-primary); line-height: 1.45; }
h1, h2 { margin: 0; font-weight: 600; }
h1 { font-size: 1.05rem; }
h2 { font-size: 1rem; margin-bottom: 12px; }
.muted { color: var(--text-secondary); }
.small { font-size: 0.85rem; }
code { font-size: 0.85em; }

.top { position: sticky; top: 0; z-index: 2; background: var(--surface-1); border-bottom: 1px solid var(--border);
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; padding: 10px 16px; }
.top nav { display: flex; flex-wrap: wrap; gap: 2px; max-width: 100%; }
.top nav a { color: var(--text-secondary); text-decoration: none; padding: 6px 9px; border-radius: 999px; font-size: 0.92rem; }
.top nav a[aria-current="page"] { background: var(--accent); color: var(--accent-ink); }
.top h1 .title-link { color: inherit; text-decoration: none; }
.account-name { font-weight: 400; color: var(--text-secondary); }
/* "‹ Home" and the section's name are for phones only (below). */
.back-home, .view-title { display: none; }
/* The notch and home bar of an iPhone running it from the home screen (viewport-fit=cover) */
.top { padding-top: max(10px, env(safe-area-inset-top)); padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }

/* Home: a tile per section */
.home-tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-bottom: 16px; }
@media (min-width: 640px) { .home-tiles { grid-template-columns: repeat(4, 1fr); } }
.home-tile { position: relative; display: flex; flex-direction: column; gap: 2px; min-height: 104px; padding: 14px;
  background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); color: var(--text-primary); text-decoration: none; }
.home-tile:hover { border-color: var(--accent); }
.home-tile:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.home-tile:active { background: var(--surface-0); }
.home-tile .tile-icon { width: 44px; height: 44px; margin-bottom: 8px; border-radius: 22%; display: block; }
.tile-name { font-weight: 600; font-size: 1rem; }
.tile-desc { font-size: 0.8rem; color: var(--text-secondary); line-height: 1.3; }
.tile-badge { position: absolute; top: 10px; right: 10px; font-size: 0.72rem; font-weight: 600; padding: 2px 8px; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink); }
.sync.home-sync { justify-content: space-between; flex-wrap: wrap; font-size: 0.9rem; }
.sync.home-sync button { min-height: 40px; padding: 6px 14px; font-size: 0.95rem; }
.home-settings { display: flex; flex-direction: column; gap: 14px; }
/* Settings, Data feeds */
.feed-choices { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.feed-choice { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--text-primary); }
.feed-choice input { width: 18px; height: 18px; margin: 0; flex: none; }
.feed { border-top: 1px solid var(--grid); }
.feed:empty { display: none; }
.feed h3 { font-size: 0.95rem; margin: 12px 0 4px; }
.token-once { background: var(--surface-0); border: 1px solid var(--accent); border-radius: 8px; padding: 10px; margin: 8px 0; }
.token-once .token { display: block; word-break: break-all; user-select: all; font-size: 0.85rem; padding: 6px 0; }
a.button { display: inline-block; padding: 8px 14px; border-radius: 8px; background: var(--accent); color: var(--accent-ink); text-decoration: none; }
a.button.ghost { background: transparent; color: var(--text-primary); border: 1px solid var(--border); }
/* Users (administrators) */
.user-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; padding: 10px 0; border-bottom: 1px solid var(--grid); }
.user-row.pending { border-left: 3px solid var(--accent); padding-left: 10px; }
.user-row .actions { margin: 0; }
.user-row.paused { border-left: 3px solid var(--border); padding-left: 10px; }
.user-facts { flex: 1 1 280px; min-width: 0; display: flex; flex-direction: column; gap: 2px; overflow-wrap: anywhere; }
.user-controls { flex: 1 1 240px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.owner-key-form { display: flex; flex-direction: column; gap: 6px; max-width: 360px; padding: 8px 10px; border: 1px solid var(--accent); border-radius: 8px; }
.owner-key-form p { margin: 0; }
.home-settings .demo-toggle { margin: 0; }
.home-settings .account { justify-content: space-between; flex-wrap: wrap; }
.block { display: block; }
.instance-banner .short { display: none; }


main { max-width: 760px; margin: 0 auto; padding: 16px; padding-bottom: max(16px, env(safe-area-inset-bottom)); }
.card { background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; }
/* Phones: no tab bar. Home shows the title; a section shows "‹ Home" and its name in one slim row. */
@media (max-width: 720px) {
  .top { flex-wrap: nowrap; gap: 8px; padding-top: max(6px, env(safe-area-inset-top)); padding-bottom: 6px; min-height: 48px; }
  .top nav { display: none; }
  .top h1 { font-size: 1.05rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  body:not([data-view="home"]) .top h1 { display: none; }
  body:not([data-view="home"]) .back-home { display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px 0 4px;
    margin-left: -4px; color: var(--accent); text-decoration: none; font-size: 1rem; font-weight: 500; }
  body:not([data-view="home"]) .view-title { display: block; font-weight: 600; font-size: 1.05rem; }
  .instance-banner { padding: 6px 12px; font-size: 0.8rem; }
  .instance-banner .long { display: none; }
  .instance-banner .short { display: inline; }
  main { padding-left: 12px; padding-right: 12px; }
  .card { padding: 14px; margin-bottom: 12px; }
  h2 { font-size: 0.98rem; }
}

label { display: block; font-size: 0.9rem; color: var(--text-secondary); margin: 10px 0; }
input, textarea, select { display: block; width: 100%; margin-top: 4px; font: inherit; color: var(--text-primary);
  background: var(--surface-0); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; }
input[type="date"] { width: auto; display: inline-block; margin-left: 6px; }
textarea { resize: vertical; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
details summary { cursor: pointer; color: var(--text-secondary); font-size: 0.9rem; margin: 8px 0; }

button { font: inherit; border: 1px solid transparent; border-radius: 8px; padding: 8px 14px; cursor: pointer;
  background: var(--accent); color: var(--accent-ink); }
button.ghost { background: transparent; color: var(--text-primary); border-color: var(--border); }
button.danger { color: var(--danger); }
button:disabled { opacity: 0.5; cursor: default; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; }
.status { font-size: 0.85rem; color: var(--text-secondary); }
.status.error { color: var(--danger); }
.status.ok { color: var(--good); }
.zone-ladder { list-style: none; padding: 0; margin: 4px 0 0; display: flex; flex-wrap: wrap; gap: 4px 16px; color: var(--text-secondary); }
label [data-zone-default] { display: block; margin-top: 2px; }

.dayline { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.dayline label { margin: 0; }
.daynav { display: flex; align-items: center; gap: 6px; }
.daynav input { width: auto; }
.daynav button { min-height: 44px; }
.daynav button.icon { min-width: 44px; padding: 0; font-size: 1.4rem; line-height: 1; }
.sync { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; }
.sync button { padding: 4px 10px; font-size: 0.85rem; }

/* 1 to 10 scales: tap a number, tap it again to clear */
.scale { margin: 10px 0; }
.scale-label { font-size: 0.9rem; color: var(--text-secondary); margin-bottom: 4px; display: flex; justify-content: space-between; }
.scale-buttons { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; }
.scale-buttons button { padding: 8px 0; background: var(--surface-0); color: var(--text-primary); border-color: var(--border); min-width: 0; }
.scale-buttons button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

.counters { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.counter { display: flex; align-items: center; justify-content: space-between; gap: 6px; background: var(--surface-0);
  border: 1px solid var(--border); border-radius: 8px; padding: 6px 8px; }
.counter span.name { font-size: 0.9rem; }
.counter .n { min-width: 2ch; text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; }
.counter button { width: 32px; height: 32px; padding: 0; background: transparent; color: var(--text-primary); border-color: var(--border); }

.filters { display: flex; gap: 6px; margin-bottom: 12px; }
.filters button { background: transparent; color: var(--text-primary); border-color: var(--border); padding: 6px 12px; }
.filters button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.charts { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .charts { grid-template-columns: 1fr 1fr; } }
.chart-card { background: var(--surface-1); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 12px 8px; min-width: 0; }
.chart-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.chart-head h3 { margin: 0; font-size: 0.92rem; font-weight: 600; }
.chart-head .latest { font-size: 0.85rem; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.chart { position: relative; width: 100%; height: 150px; margin-top: 6px; }
.chart svg { display: block; width: 100%; height: 100%; overflow: visible; }
.chart .grid line { stroke: var(--grid); stroke-width: 1; }
.chart .axis text { fill: var(--muted); font-size: 11px; }
.chart .line { fill: none; stroke: var(--series-1); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: var(--series-1-wash); stroke: none; }
.chart .dot { fill: var(--series-1); stroke: var(--surface-1); stroke-width: 2; }
.chart .bar { fill: var(--series-1); }
.chart .bar.hover { opacity: 0.75; }
.chart .dot.partial, .chart .dot.out, .chart .bar.partial { fill: var(--danger); }
.chart .bar.seg.z1 { fill: var(--zone-1); } .chart .bar.seg.z2 { fill: var(--zone-2); } .chart .bar.seg.z3 { fill: var(--zone-3); }
.chart .bar.seg.z4 { fill: var(--zone-4); } .chart .bar.seg.z5 { fill: var(--zone-5); } .chart .bar.seg.znd { fill: var(--zone-none); }
.zone-filters { display: flex; flex-wrap: wrap; gap: 0 12px; }
.zone-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 6px 0; padding: 0; font-size: 0.8rem; color: var(--text-secondary); }
.zone-legend li { display: flex; align-items: center; gap: 6px; }
.zone-legend .swatch { width: 12px; height: 12px; border-radius: 3px; flex: none; }
.swatch.z1 { background: var(--zone-1); } .swatch.z2 { background: var(--zone-2); } .swatch.z3 { background: var(--zone-3); }
.swatch.z4 { background: var(--zone-4); } .swatch.z5 { background: var(--zone-5); } .swatch.znd { background: var(--zone-none); }
/* The Usage card (Users screen): done, failed and skipped segments, and plain bar lists for device, location and source. */
.chart .bar.seg.u-ok { fill: var(--good); } .chart .bar.seg.u-fail { fill: var(--danger); } .chart .bar.seg.u-skip { fill: var(--zone-none); }
.swatch.u-ok { background: var(--good); } .swatch.u-fail { background: var(--danger); } .swatch.u-skip { background: var(--zone-none); }
.usage-charts { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 720px) { .usage-charts { grid-template-columns: 1fr 1fr; } }
.usage-charts h3, .usage-bars h3 { margin: 8px 0 2px; font-size: 0.95rem; }
.usage-charts .chart { min-height: 140px; }
.bar-list { list-style: none; margin: 4px 0; padding: 0; }
.bar-list li { display: grid; grid-template-columns: minmax(0, 11rem) 1fr 3rem; gap: 8px; align-items: center; font-size: 0.88rem; padding: 2px 0; }
.bar-list .bar-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-list .bar-track { height: 10px; border-radius: 4px; background: var(--grid); overflow: hidden; }
.bar-list .bar-fill { display: block; height: 100%; border-radius: 4px; background: var(--series-1); }
.bar-list .bar-count { text-align: right; font-variant-numeric: tabular-nums; }
.zones-card table td, .zones-card table th { text-align: right; padding: 2px 6px; border-bottom: 1px solid var(--grid); font-variant-numeric: tabular-nums; }
.zones-card table td:first-child, .zones-card table th:first-child { text-align: left; }
.zones-card table { width: 100%; border-collapse: collapse; font-size: 0.82rem; }
.chart .range-line { stroke: var(--text-secondary); stroke-width: 1; stroke-dasharray: 3 3; }
.chart-legend { margin: 4px 0 8px; }
.chart .crosshair { stroke: var(--muted); stroke-width: 1; }
/* Targets: a dashed line in ink (not a series color) labelled "target", and a light band for a healthy span */
.chart .target-line { stroke: var(--text-secondary); stroke-width: 1.5; stroke-dasharray: 5 4; }
.chart .target-band { fill: var(--grid); opacity: 0.55; }
.chart .target-label { fill: var(--text-secondary); font-size: 10px; }
.target-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 2px 0 4px; }
.target-row .target-why { flex-basis: 100%; margin: 0; }
.target-row .target-why summary { font-size: 0.82rem; color: var(--text-secondary); cursor: pointer; }
.target-row .target-why p { margin: 2px 0; }
.target-row .target-edit input { width: 7em; margin: 0 0 0 4px; display: inline-block; }
.profile-card summary { cursor: pointer; }
.profile-card form { margin-top: 8px; }
.chart .empty { fill: var(--muted); font-size: 12px; }
.chart-card details { margin-top: 4px; }
.chart-card table { width: 100%; border-collapse: collapse; font-size: 0.82rem; font-variant-numeric: tabular-nums; }
.chart-card td, .chart-card th { text-align: left; padding: 2px 6px; border-bottom: 1px solid var(--grid); }
.table-scroll { max-height: 220px; overflow: auto; }

.tooltip { position: fixed; z-index: 5; pointer-events: none; background: var(--surface-1); color: var(--text-primary);
  border: 1px solid var(--border); border-radius: 8px; padding: 6px 8px; font-size: 0.82rem; box-shadow: 0 4px 12px rgba(0,0,0,0.12);
  font-variant-numeric: tabular-nums; white-space: nowrap; }
.tooltip .t-date { color: var(--text-secondary); }

.review h3 { margin: 18px 0 6px; font-size: 0.98rem; }
.review ul { padding-left: 20px; margin: 6px 0; }
.review .meta { color: var(--text-secondary); font-size: 0.85rem; }

.section-card .row { display: grid; grid-template-columns: 90px 1fr; gap: 12px; }
.section-card textarea { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 0.85rem; min-height: 180px; }
.section-card .check { display: flex; align-items: center; gap: 8px; }
.section-card .check input { width: auto; display: inline; margin: 0; }
.section-card.sensitive { border-color: var(--danger); }
.badge { font-size: 0.75rem; border: 1px solid var(--danger); color: var(--danger); border-radius: 999px; padding: 1px 8px; margin-left: 8px; }
#preview pre { white-space: pre-wrap; word-break: break-word; font-size: 0.85rem; background: var(--surface-0); padding: 12px;
  border-radius: 8px; max-height: 420px; overflow: auto; margin: 0; }
.empty-state { color: var(--text-secondary); text-align: center; padding: 32px 16px; }

/* Meds */
.section-title { font-size: 0.95rem; margin: 20px 0 10px; color: var(--text-secondary); font-weight: 600; }
.section-title:first-child { margin-top: 0; }
fieldset.timings { border: 1px solid var(--border); border-radius: 8px; margin: 10px 0; padding: 8px 10px; }
fieldset.timings legend { font-size: 0.9rem; color: var(--text-secondary); padding: 0 4px; }
fieldset.timings .opts { display: flex; flex-wrap: wrap; gap: 6px; }
fieldset.timings label { display: inline-flex; align-items: center; gap: 6px; margin: 0; padding: 6px 10px; border: 1px solid var(--border);
  border-radius: 999px; color: var(--text-primary); background: var(--surface-0); cursor: pointer; }
fieldset.timings input { width: auto; margin: 0; display: inline; }
fieldset.timings label:has(input:checked) { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
/* Dose or ingredients (Meds tab forms), and the Combine panel's item picker: the same chip choices as the timings */
fieldset.regimen, fieldset.combine-picks { border: 1px solid var(--border); border-radius: 8px; margin: 10px 0; padding: 8px 10px; display: grid; gap: 8px; }
fieldset.regimen legend, fieldset.combine-picks legend { font-size: 0.9rem; color: var(--text-secondary); padding: 0 4px; }
fieldset.regimen .opts, fieldset.combine-picks .opts { display: flex; flex-wrap: wrap; gap: 6px; }
fieldset.regimen .opts label, fieldset.combine-picks .opts label { display: inline-flex; align-items: center; gap: 6px; margin: 0; padding: 6px 10px;
  border: 1px solid var(--border); border-radius: 999px; color: var(--text-primary); background: var(--surface-0); cursor: pointer; }
fieldset.regimen .opts input, fieldset.combine-picks .opts input { width: auto; margin: 0; display: inline; }
fieldset.regimen .opts label:has(input:checked), fieldset.combine-picks .opts label:has(input:checked) { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.ingredient-rows { display: grid; gap: 6px; }
.ingredient-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) auto; gap: 6px; align-items: center; }
.ingredient-row input { margin: 0; }
.ingredients { display: grid; gap: 6px; justify-items: start; }
.combine-preview ul { margin: 4px 0; padding-left: 20px; }
/* Meds tab: weekly check-off bars (height = share taken; an outlined box = not logged) */
.checkoffs { margin: 6px 0; }
.checkoff-bars { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 3px; height: 28px; max-width: 320px; align-items: end; }
.checkoff-bar { position: relative; height: 100%; border-radius: 3px; background: var(--series-1-wash); overflow: hidden; }
.checkoff-bar .fill { position: absolute; left: 0; right: 0; bottom: 0; background: var(--series-1); border-radius: 3px 3px 0 0; min-height: 2px; }
.checkoff-bar.unlogged { background: none; border: 1px dashed var(--muted); }
.checkoff-table summary { cursor: pointer; font-size: 0.85rem; color: var(--text-secondary); margin-top: 4px; }
.checkoff-table table { border-collapse: collapse; font-size: 0.85rem; margin-top: 4px; }
.checkoff-table th, .checkoff-table td { padding: 2px 10px 2px 0; text-align: left; border-bottom: 1px solid var(--grid); }

/* Today tab: an item's ingredients on their own line under its name */
.dose .ingredients-line { display: block; font-size: 0.85rem; }
label.check { display: flex; align-items: center; gap: 8px; }
label.check input { width: auto; display: inline; margin: 0; }
.statement { border-left: 3px solid var(--danger); padding: 4px 12px; margin: 8px 0 12px; }
.statement p { margin: 0 0 8px; }
.med-card .head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 10px; }
.med-card .head h3 { margin: 0; font-size: 1rem; }
.pill { font-size: 0.75rem; border: 1px solid var(--border); color: var(--text-secondary); border-radius: 999px; padding: 1px 8px; }
.pill.rx { border-color: var(--accent); color: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0; }
.chip { font-size: 0.8rem; background: var(--surface-0); border: 1px solid var(--border); border-radius: 999px; padding: 2px 8px; }
.med-card .meta { font-size: 0.85rem; color: var(--text-secondary); margin: 2px 0; }
.med-card .inline-form { border-top: 1px solid var(--border); margin-top: 12px; padding-top: 4px; }
.impact table { width: 100%; border-collapse: collapse; font-size: 0.85rem; font-variant-numeric: tabular-nums; margin-top: 8px; }
.impact th, .impact td { text-align: right; padding: 4px 6px; border-bottom: 1px solid var(--grid); }
.impact th:first-child, .impact td:first-child { text-align: left; }
.impact .n { color: var(--muted); font-size: 0.75rem; }
.impact .what { font-weight: 600; }
.impact .note { font-size: 0.82rem; color: var(--text-secondary); margin: 4px 0 0; }
.table-wide { overflow-x: auto; }
.impact .n { display: block; }
.pill { white-space: nowrap; }
.dose-group { margin: 8px 0 12px; }
.dose-slot { font-size: 0.82rem; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 4px; }
label.dose { margin: 0; padding: 8px 4px; border-bottom: 1px solid var(--grid); color: var(--text-primary); font-size: 0.95rem; }
label.dose input { width: 20px; height: 20px; }
.dose-history { margin: 6px 0 0; font-size: 0.85rem; }
.dose-history summary { margin: 4px 0; }
.dose-history ul { margin: 4px 0; padding-left: 18px; color: var(--text-secondary); }
.dose-history strong { color: var(--text-primary); font-weight: 600; }
.note-text { white-space: pre-wrap; font-style: italic; }

/* Labs */
.lab-panel table { width: 100%; border-collapse: collapse; font-size: 0.88rem; font-variant-numeric: tabular-nums; }
.lab-panel th, .lab-panel td { text-align: right; padding: 6px 8px; border-bottom: 1px solid var(--grid); white-space: nowrap; }
.lab-panel th:first-child, .lab-panel td:first-child { text-align: left; white-space: normal; }
.lab-panel th { font-weight: 600; color: var(--text-secondary); font-size: 0.8rem; }
.lab-panel td.from-app { font-style: italic; }
button.link { background: none; border: none; padding: 0; color: var(--text-primary); text-align: left; font: inherit; cursor: pointer; text-decoration: underline; text-decoration-color: var(--grid); text-underline-offset: 3px; }
.lab-panel { min-width: 0; }
.lab-detail-slot:not(:empty) { border-top: 1px solid var(--border); margin-top: 12px; padding-top: 8px; }
.lab-detail-head { display: flex; justify-content: space-between; align-items: center; }
.lab-detail-head h3 { margin: 0; font-size: 0.95rem; }
.lab-history { list-style: none; padding: 0; margin: 8px 0; font-size: 0.85rem; }
.lab-history li { padding: 6px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; border-bottom: 1px solid var(--grid); }
.lab-actions { display: inline-flex; gap: 6px; }
.small-btn { padding: 2px 8px; font-size: 0.8rem; }
.lab-detail .actions input { width: 160px; margin: 0; }
.lab-edit { flex-basis: 100%; border-top: 1px solid var(--grid); margin-top: 4px; padding-top: 4px; }
.review-warnings { border: 1px solid var(--danger); border-radius: 8px; padding: 8px 12px; margin: 8px 0; font-size: 0.85rem; }
.review-warnings ul { margin: 4px 0 0; padding-left: 18px; }

/* Training volume */
.training-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.training-head h2 { margin: 0; }
.training-head .filters { margin: 0; }
.tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin: 8px 0 4px; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(4, 1fr); } }
.tile { background: var(--surface-0); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; min-width: 0; }
.tile-label { font-size: 0.8rem; color: var(--text-secondary); }
.tile-value { font-size: 1.15rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.tile-delta { font-size: 0.75rem; color: var(--text-secondary); }
h3.sub { font-size: 0.9rem; margin: 14px 0 6px; color: var(--text-secondary); font-weight: 600; }
.plain-list { list-style: none; padding: 0; margin: 0; font-size: 0.85rem; font-variant-numeric: tabular-nums; }
.plain-list li { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-bottom: 1px solid var(--grid); }
/* One grid for the whole list so every bar starts and ends at the same place. */
#training-exercises { display: grid; grid-template-columns: minmax(90px, 1fr) 2fr auto; align-items: center; gap: 6px 8px; font-size: 0.85rem; }
#training-exercises > p { grid-column: 1 / -1; }
.ex-row { display: contents; }
.ex-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ex-bar-track { height: 10px; background: var(--surface-0); border-radius: 4px; overflow: hidden; }
.ex-bar { height: 100%; background: var(--series-1); border-radius: 0 4px 4px 0; }
.ex-value { color: var(--text-secondary); font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 480px) {
  #training-exercises { grid-template-columns: 1fr auto; grid-auto-flow: row dense; row-gap: 2px; }
  .ex-bar-track { grid-column: 1 / -1; margin-bottom: 6px; }
}
.plain-list li strong { white-space: nowrap; }
.training-head .filters { flex-wrap: wrap; gap: 4px; }
.training-head .filters button { padding: 5px 10px; font-size: 0.9rem; }
.tooltip .t-detail { color: var(--text-secondary); font-size: 0.78rem; }
.program-card h2 { margin: 0 0 8px; }
.program-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 8px; }
.program-track { margin: 10px 0 4px; }
.program-title .badge { border-color: var(--text-secondary); color: var(--text-secondary); margin-left: 0; }

/* Activity */
.activity-grid { display: grid; grid-template-columns: minmax(220px, 1fr) 2fr; gap: 12px; align-items: start; }
@media (max-width: 720px) { .activity-grid { grid-template-columns: 1fr; } }
.activity-list { display: flex; flex-direction: column; gap: 2px; max-height: 480px; overflow-y: auto; padding: 8px; }
.activity-list a { display: flex; gap: 8px; align-items: baseline; padding: 6px 8px; border-radius: 8px; color: inherit; text-decoration: none; }
.activity-list a:hover { background: var(--surface-0); }
.activity-list a.on { background: var(--surface-0); outline: 1px solid var(--series-1); }
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--text-secondary); transform: translateY(-1px); }
.dot.ok { background: var(--series-1); }
.dot.running { background: var(--series-1); animation: pulse 1.2s ease-in-out infinite; }
.dot.error, .dot.failed { background: var(--danger); }
@keyframes pulse { 50% { opacity: 0.3; } }
@media (prefers-reduced-motion: reduce) { .dot.running { animation: none; } }
.activity-head { margin-bottom: 8px; }
.activity-output .plain-list { margin-bottom: 8px; }
/* Scheduled jobs (Activity tab): one line per job, newest run first */
.job-list { list-style: none; margin: 0 0 8px; padding: 0; }
.activity-more > summary { font-size: 1rem; font-weight: 600; color: var(--text-primary); margin: 0; }
.activity-more[open] > summary { margin-bottom: 8px; }
.job-list li { display: flex; gap: 8px; align-items: baseline; padding: 4px 0; border-bottom: 1px solid var(--grid); overflow-wrap: anywhere; }
.activity-grid > * { min-width: 0; }
.tiles.three { grid-template-columns: repeat(3, 1fr); }
.spend-table-wrap { overflow-x: auto; }
.spend-tables { display: grid; gap: 12px; grid-template-columns: 1fr; margin: 8px 0; }
@media (min-width: 720px) { .spend-tables { grid-template-columns: 3fr 2fr; align-items: start; } }
table.spend-table { border-collapse: collapse; width: 100%; font-size: 0.88rem; font-variant-numeric: tabular-nums; }
table.spend-table caption { text-align: left; font-weight: 600; padding-bottom: 4px; }
table.spend-table th, table.spend-table td { padding: 4px 8px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--grid); }
table.spend-table th[scope="row"], table.spend-table thead th:first-child { text-align: left; font-weight: 500; }
table.calls th, table.calls td { white-space: nowrap; padding: 4px 8px; text-align: right; }
table.calls th:nth-child(-n+3), table.calls td:nth-child(-n+3) { text-align: left; }

/* Demo mode: drinking data is hidden on screen (see demo.js). */
.demo-toggle { display: flex; align-items: flex-start; gap: 10px; font-size: 0.95rem; color: var(--text-primary); }
.demo-toggle input { width: 20px; height: 20px; margin: 2px 0 0; flex: none; }
body.demo #drinking { display: none; }
body.demo .demo-toggle { color: var(--accent); font-weight: 600; }

/* Lift progress */
.lift { border-bottom: 1px solid var(--grid); }
.lift > summary { display: grid; grid-template-columns: minmax(120px, 1.2fr) auto; gap: 2px 12px; padding: 8px 0; cursor: pointer; list-style: none; }
.lift > summary::-webkit-details-marker { display: none; }
.lift-name { font-weight: 600; }
.lift-status { text-align: right; white-space: nowrap; font-size: 0.9rem; }
.lift-detail { grid-column: 1 / -1; }
.lift.regressing .lift-status { color: var(--danger); }
.lift.progressing .lift-status { color: var(--series-1); }
.lifts-idle { margin-top: 10px; }

/* Next program (Program Advisor) */
.advisor-weights { display: grid; gap: 6px; margin-bottom: 12px; }
.weight-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; }
.weight-label { font-size: 0.9rem; }
.weight-row .filters { margin: 0; }
.weight-row .filters button { min-width: 44px; min-height: 36px; padding: 4px 8px; }
.advisor-weights > .ghost { justify-self: start; padding: 4px 10px; font-size: 0.85rem; }
.advisor-pick { padding: 10px 0; border-top: 1px solid var(--grid); }
.advisor-pick .program-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; }
.advisor-total { font-variant-numeric: tabular-nums; color: var(--text-secondary); }
.badge.neutral { border-color: var(--border); color: var(--text-secondary); margin-left: 0; }
.scores { display: grid; gap: 4px; margin: 8px 0; }
.score-row { display: grid; grid-template-columns: 5.5em 1fr 2.5em; align-items: center; gap: 8px; font-size: 0.85rem; }
.score-row.off { opacity: 0.45; }
.score-value { text-align: right; font-variant-numeric: tabular-nums; }
.reasons { margin: 4px 0 0; padding-left: 1.1em; }
.reasons .flag { color: var(--danger); list-style: none; margin-left: -1.1em; }
.table-scroll.wide { max-height: none; overflow-x: auto; }
.table-scroll.wide table { min-width: 520px; }
.advisor-card table { width: 100%; border-collapse: collapse; font-size: 0.82rem; font-variant-numeric: tabular-nums; }
.advisor-card th, .advisor-card td { padding: 4px 6px; border-bottom: 1px solid var(--grid); text-align: right; }
.advisor-card th:first-child, .advisor-card td:first-child { text-align: left; }
.score-row .ex-bar-track { grid-column: auto; margin-bottom: 0; } /* the phone rule for volume bars spans the row */

/* Data check warnings on the Today tab (stale or missing Apple Health days, partial days) */
.data-checks { list-style: none; margin: 0 0 12px; padding: 8px 12px; border: 1px solid var(--border); border-left: 3px solid var(--danger);
  border-radius: 8px; font-size: 0.88rem; display: grid; gap: 4px; }

/* Reviews tab: the week list beside the selected review (a collapsed list above it on a phone) */
.review-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 16px; align-items: start; }
.review-list { position: sticky; top: 12px; padding: 12px; max-height: calc(100vh - 24px); overflow-y: auto; }
.review-list-title { font-size: 0.95rem; margin: 0 0 8px; }
.review-list-phone { display: none; }
.review-picks { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.review-pick { width: 100%; display: flex; flex-wrap: nowrap; align-items: baseline; gap: 4px; text-align: left;
  background: none; border: 0; border-radius: 6px; padding: 6px 8px; color: var(--text-primary); font: inherit; font-size: 0.88rem; cursor: pointer; }
.review-pick:hover { background: var(--grid); }
.review-pick[aria-current] { font-weight: 600; background: var(--grid); }
.review-pick .check { width: 1em; flex: none; }
.review-pick .label { flex: 1; min-width: 0; }
@media (max-width: 720px) {
  .review-layout { grid-template-columns: 1fr; }
  .review-list { position: static; max-height: none; padding: 8px 12px; }
  .review-list-title { display: none; }
  .review-list-phone { display: block; }
  .review-list-phone summary { cursor: pointer; font-weight: 600; padding: 6px 0; color: var(--text-primary); }
  .review-list-phone .review-picks { margin-top: 6px; }
  .review-pick { min-height: 44px; }
}

/* Called for vs logged (Training tab) */
.adherence-pick { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 0.9rem; }
.adherence-pick select { max-width: 100%; }
.usual-changes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 8px 0 12px; }
.usual-changes h3 { font-size: 0.88rem; margin: 0 0 4px; }
.usual-changes ul { margin: 0; padding-left: 18px; font-size: 0.85rem; }
.adherence-week { border-top: 1px solid var(--grid); padding: 6px 0; }
.adherence-week > summary { cursor: pointer; font-weight: 600; padding: 4px 0; }
.adherence-session { margin: 6px 0 6px 12px; }
.adherence-session > summary { cursor: pointer; padding: 2px 0; }
.adherence-session .session-line { display: block; margin: 0 0 0 18px; color: var(--text-secondary); }
.adherence-table { border-collapse: collapse; width: 100%; font-size: 0.85rem; margin: 6px 0 8px; }
.adherence-table th, .adherence-table td { text-align: left; padding: 4px 8px; border-bottom: 1px solid var(--grid); vertical-align: top; }
@media (max-width: 720px) {
  .usual-changes { grid-template-columns: 1fr; }
  .adherence-session { margin-left: 0; }
  .adherence-table thead { display: none; }
  .adherence-table tr { display: block; border-bottom: 1px solid var(--grid); padding: 4px 0; }
  .adherence-table td { display: block; border: 0; padding: 2px 4px; }
  .adherence-table td::before { content: attr(data-label) ": "; color: var(--text-secondary); }
}

/* Missing weekly review notice (Today and Reviews tabs) */
.review-notice { margin: 0 0 12px; padding: 10px 12px; border: 1px solid var(--border); border-left: 3px solid var(--danger);
  border-radius: 8px; font-size: 0.9rem; display: grid; gap: 6px; }
.review-notice p { margin: 0; }
.review-notice .actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }

/* Next program chat */
.advisor-chat { margin-top: 16px; border-top: 1px solid var(--grid); padding-top: 8px; }
.chat-thread { display: grid; gap: 10px; margin: 8px 0; }
.chat-entry { border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px; }
.chat-entry.owner { background: var(--surface-0); }
.chat-head { display: flex; flex-wrap: wrap; gap: 6px; align-items: baseline; }
.chat-head .link { margin-left: auto; }
.chat-body p { margin: 6px 0; }
.chat-physician { border-left: 3px solid var(--border); padding-left: 8px; margin-top: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* The demo instance's banner */
.instance-banner { margin: 0; padding: 8px 16px; text-align: center; font-size: 0.88rem; background: var(--surface-0);
  border-bottom: 1px solid var(--border); }

/* One-day dose and slot adjustments on the Today tab */
.dose-row { display: grid; grid-template-columns: 1fr auto auto; column-gap: 12px; align-items: center; border-bottom: 1px solid var(--grid); }
.dose-row label.dose { border-bottom: none; }
.dose-row.adjusted label.dose { border-left: 3px solid var(--accent); padding-left: 8px; }
.dose-adjust, .dose-skip { padding: 8px 4px; min-height: 44px; }
.dose-row.skipped label.dose > span { color: var(--text-secondary); }
.dose-editor { grid-column: 1 / -1; padding: 8px 0 12px; }
.dose-editor .actions { margin-top: 4px; }

/* Labs: reference range column, out-of-range marks (text and arrow, not color alone), range editor */
.lab-range { white-space: nowrap; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.lab-out { font-weight: 700; font-style: italic; color: var(--danger); }
.lab-out .range-mark { font-weight: 400; font-size: 0.8rem; white-space: nowrap; }
.lab-range-editor { margin-top: 8px; border-top: 1px solid var(--grid); padding-top: 6px; }
.lab-range-editor .actions label { display: inline-flex; align-items: center; gap: 4px; }
.lab-range-editor .actions input { width: 6.5em; margin: 0; }

/* Signed-in account (google mode) */
.account { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; color: var(--text-secondary); }
/* The public read-only demo: hide the controls that would change data (the server refuses them anyway). */
body.read-only form button[type="submit"], body.read-only button.danger, body.read-only #sync-now,
body.read-only .actions button:not([data-range]):not([data-vview]):not([data-zview]):not([data-zgroup]),
body.read-only #add-section { display: none !important; }
body.read-only #supplement-accept-row { display: none !important; }

/* Programs (phase 5): the user's own catalog and its builder */
.program-more { margin: 10px 0; }
.program-more summary { cursor: pointer; color: var(--accent); }
.program-more textarea, .program-more input[type="file"] { width: 100%; margin: 6px 0; }
fieldset.phase-box { border: 1px solid var(--border); border-radius: 8px; margin: 12px 0; padding: 8px 10px; display: grid; gap: 8px; min-width: 0; }
fieldset.phase-box legend { font-size: 0.9rem; color: var(--text-secondary); padding: 0 4px; }
.workout-box { border-left: 3px solid var(--grid); padding-left: 8px; display: grid; gap: 6px; }
.workout-box .row-head { display: flex; gap: 6px; align-items: center; }
.workout-box .row-head input { flex: 1; min-width: 0; font-weight: 600; }
.exercise-row { display: grid; grid-template-columns: minmax(0, 1fr) 4.2em 5.2em auto; gap: 6px; align-items: center; }
.exercise-row input { margin: 0; min-width: 0; }
button.icon { padding: 4px 10px; min-width: 0; }
button.small-button { justify-self: start; padding: 4px 10px; font-size: 0.9rem; }
body.read-only .program-more, body.read-only #program-builder { display: none !important; }
@media (max-width: 720px) {
  .exercise-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; padding-bottom: 4px; border-bottom: 1px dashed var(--grid); }
  .exercise-row input:first-child { grid-column: 1 / -1; }
  fieldset.phase-box { padding: 8px 6px; }
}

/* Help and the demo's Request access (phase 6) */
.help-answer { margin-top: 10px; padding: 10px 12px; border-left: 3px solid var(--accent); background: var(--surface-0); border-radius: 6px; }
.help-answer p { margin: 0 0 8px; }
.help-answer p:last-child { margin-bottom: 0; }
#help-question { width: 100%; }
.instance-banner #request-access { font-weight: 600; white-space: nowrap; }

/* Log workout (Training) */
.set-row { display: grid; grid-template-columns: 3.4em minmax(0, 1fr) minmax(0, 1fr) auto; gap: 6px; align-items: center; }
.set-row input { margin: 0; min-width: 0; }
fieldset.phase-box .row-head { display: flex; gap: 6px; align-items: center; }
fieldset.phase-box .row-head input { flex: 1; min-width: 0; font-weight: 600; margin: 0; }
.recent-workout { padding: 6px 0; border-bottom: 1px solid var(--grid); }
body.read-only #log-workout-card { display: none !important; }

/* Excel Workout Log (Settings) */
.excel-box { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--grid); }
.excel-box h4 { margin: 0 0 6px; }
.excel-upload input[type="file"] { max-width: 100%; }
body.read-only .excel-upload { display: none !important; }

/* Arrange tiles, goals, feedback */
.tile-arrange { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 4px 0 12px; }
/* "On this page" on Training and Health: wraps on a phone, never scrolls sideways */
.jump-links { display: flex; flex-wrap: wrap; align-items: center; gap: 0 14px; margin: 0 0 14px; }
.jump-links button.link { padding: 6px 0; }
.jump-links select { max-width: 100%; }
.charts-title { margin: 24px 0 8px; }
[tabindex="-1"]:focus { outline: none; }
body.arranging .home-tile { outline: 2px dashed var(--accent); outline-offset: -2px; }
.tile-move { display: flex; gap: 6px; margin-top: 8px; }
.tile-move button { padding: 6px 12px; }
.feedback-item { border-bottom: 1px solid var(--grid); padding: 8px 0; }
.feedback-item.new summary strong::before { content: '● '; color: var(--accent); }
.feedback-item.done { opacity: 0.75; }
.pre-wrap { white-space: pre-wrap; overflow-wrap: anywhere; }
#prompt-builder label input { width: 100%; }
body.read-only #tile-arrange #arrange-tiles { display: inline-block !important; }
body.read-only #feedback-card, body.read-only #prompt-builder { display: none !important; }

/* Arrange on the Training and Health tabs */
.card-move { display: flex; gap: 6px; justify-content: flex-end; margin: -4px 0 6px; }
.card-move button { padding: 4px 12px; }
body.arranging-training #view-training > .card, body.arranging-health #view-health > .card, body.arranging-health .chart-card { outline: 2px dashed var(--accent); outline-offset: -2px; }

/* The demo's way to the real app (Request access) */
.request-card { border: 2px solid var(--accent); }
.request-card h2 { margin-top: 0; }
a.button.request-big { display: inline-block; padding: 12px 20px; font-size: 1.05rem; font-weight: 600; }
.instance-banner .banner-cta { display: inline-block; margin-left: 8px; padding: 3px 10px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-weight: 600; text-decoration: none; white-space: nowrap; }
.instance-banner .banner-cta:hover { filter: brightness(1.08); }
.instance-banner .banner-link { margin-left: 8px; white-space: nowrap; }

/* Home: the setup checklist and the summary (UX roadmap phase 2) */
.home-setup { border-left: 3px solid var(--accent); }
.setup-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 12px; }
.setup-head h2 { margin: 0; }
.setup-head button { margin-left: auto; }
.setup-steps { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 12px; }
.setup-step { padding-top: 10px; border-top: 1px solid var(--border); }
.setup-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.setup-title button { margin-left: auto; }
.setup-mark { width: 1.2em; color: var(--accent); font-weight: 700; }
.setup-step.done .setup-mark { color: var(--good, var(--accent)); }
.setup-step.skipped strong { color: var(--text-secondary); font-weight: 500; }
.setup-step p { margin: 4px 0; }
.setup-ways { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 8px; }
.setup-way .block { display: block; margin-top: 2px; }
.home-summary-list { margin: 0; padding-left: 18px; display: grid; gap: 6px; }
.summary-lines { margin: 4px 0 0; padding-left: 18px; color: var(--text-secondary); font-size: 0.9rem; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Phone layout check (2026-10-30, 320 to 430 px): the day row wraps instead of running off the screen, and controls
   are at least 44 px to tap (Apple's guideline). Expanders and small text links get room without changing how they look. */
.daynav { flex-wrap: wrap; }
@media (max-width: 720px) {
  button, select, main input:not([type="checkbox"]):not([type="radio"]):not([type="range"]) { min-height: 44px; }
  button.icon, .counter button { min-width: 44px; min-height: 44px; }
  .counter button { width: 44px; height: 44px; }
  button.link { min-height: 44px; display: inline-flex; align-items: center; }
  .jump-links button.link { padding: 0; }
  details > summary { padding: 10px 0; }
  .target-row .target-why summary { padding: 10px 0; }
  .checkoff-table summary { padding: 10px 0; }
}
