:root {
  --bg: #f3f6f4;
  --surface: #ffffff;
  --surface-2: #e9efec;
  --text: #14211c;
  --muted: #5d6f68;
  --line: #dbe4df;
  --accent: #0f8f6a;
  --accent-ink: #ffffff;
  --accent-soft: #d9f1e8;
  --warn: #b45309;
  --warn-soft: #fdf0dc;
  --danger: #c0392b;
  --shadow: 0 1px 2px rgba(20, 33, 28, .06), 0 4px 14px rgba(20, 33, 28, .05);
  --tab-h: 62px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1411;
    --surface: #161e1a;
    --surface-2: #1f2a25;
    --text: #e8f0ec;
    --muted: #94a69e;
    --line: #26332d;
    --accent: #2bc796;
    --accent-ink: #06231a;
    --accent-soft: #14352a;
    --warn: #f0b155;
    --warn-soft: #33270f;
    --danger: #ff7a6b;
    --shadow: none;
  }
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; overflow-x: hidden; max-width: 100%; touch-action: manipulation; overscroll-behavior-x: none; }
body {
  overflow-x: hidden; max-width: 100vw; overscroll-behavior-x: none; overscroll-behavior-y: none;
  -webkit-touch-callout: none; touch-action: manipulation;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  padding-bottom: calc(var(--tab-h) + env(safe-area-inset-bottom) + 16px);
}
button { font: inherit; color: inherit; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; font-size: 16px; } /* 16px stops iOS zooming into fields */
button, .tabs, .top, .seg, .chip, .cell { -webkit-user-select: none; user-select: none; }
img, svg, canvas { max-width: 100%; }
main, .card { min-width: 0; overflow-wrap: anywhere; }

/* Header */
.top {
  position: sticky; top: 0; z-index: 10;
  background: var(--accent);
  color: var(--accent-ink);
  padding-top: env(safe-area-inset-top);
}
@media (prefers-color-scheme: dark) { .top { background: #0f2a21; color: var(--text); } }
.top-in { max-width: 640px; margin: 0 auto; padding: 12px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.top h1 { margin: 0; font-size: 19px; letter-spacing: .2px; }
.top p { margin: 0; font-size: 12px; opacity: .85; }
.toast {
  font-size: 13px; background: rgba(0, 0, 0, .25); padding: 6px 10px; border-radius: 999px;
  opacity: 0; transform: translateY(-4px); transition: .2s; pointer-events: none; max-width: 60%;
}
.toast.show { opacity: 1; transform: none; }

main { max-width: 640px; margin: 0 auto; padding: 16px; }

/* Tab bar */
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 10;
  display: flex; justify-content: center;
  background: var(--surface); border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
}
.tabs button {
  flex: 1; max-width: 160px; height: var(--tab-h);
  background: none; border: 0; color: var(--muted);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  font-size: 12px;
}
.tabs button.on { color: var(--accent); font-weight: 600; }
.tabs svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* Cards */
.card { background: var(--surface); border-radius: 18px; box-shadow: var(--shadow); border: 1px solid var(--line); margin-bottom: 14px; overflow: hidden; }
.card-h { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 6px; }
.card-h h2 { margin: 0; font-size: 17px; }
.count { font-size: 13px; color: var(--muted); background: var(--surface-2); padding: 2px 9px; border-radius: 999px; font-variant-numeric: tabular-nums; }
.count.full { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.group-label { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding: 10px 16px 2px; }

/* Date nav + progress */
.datenav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.datenav h2 { margin: 0; font-size: 20px; text-align: center; flex: 1; }
.datenav small { display: block; font-size: 12px; font-weight: 400; color: var(--muted); }
.icon-btn { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); display: grid; place-items: center; font-size: 20px; line-height: 1; }
.icon-btn:disabled { opacity: .35; }
.progress { display: flex; align-items: center; gap: 16px; padding: 16px; }
.ring { width: 84px; height: 84px; flex: none; position: relative; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 9; }
.ring .bg { stroke: var(--surface-2); }
.ring .fg { stroke: var(--accent); stroke-linecap: round; transition: stroke-dashoffset .4s; }
.ring b { position: absolute; inset: 0; display: grid; place-items: center; font-size: 19px; }
.progress h3 { margin: 0 0 2px; font-size: 17px; }
.progress p { margin: 0; color: var(--muted); font-size: 14px; }
.pill { display: inline-block; margin-top: 6px; background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 600; padding: 3px 10px; border-radius: 999px; }

.banner { display: flex; align-items: center; gap: 10px; justify-content: space-between; background: var(--warn-soft); color: var(--warn); border-radius: 14px; padding: 12px 14px; margin-bottom: 14px; font-size: 14px; }
.banner button { background: var(--warn); color: var(--surface); border: 0; padding: 7px 12px; border-radius: 10px; font-weight: 600; white-space: nowrap; }

/* Checklist rows */
.row { display: flex; align-items: center; border-top: 1px solid var(--line); }
.card-h + .row, .group-label + .row { border-top: 0; }
.row .main { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: none; border: 0; text-align: left; }
.chk { width: 26px; height: 26px; flex: none; border-radius: 8px; border: 2px solid var(--line); display: grid; place-items: center; transition: .15s; background: var(--surface); }
.chk svg { width: 16px; height: 16px; stroke: var(--accent-ink); stroke-width: 3; fill: none; stroke-linecap: round; stroke-linejoin: round; opacity: 0; }
[aria-checked="true"] .chk { background: var(--accent); border-color: var(--accent); }
[aria-checked="true"] .chk svg { opacity: 1; }
[aria-checked="mixed"] .chk { background: var(--surface-2); border-color: var(--muted); }
.txt { min-width: 0; }
.t { font-weight: 600; }
.s { color: var(--muted); font-size: 14px; }
[aria-checked="true"] .t { text-decoration: line-through; text-decoration-color: var(--muted); color: var(--muted); }
.chip { margin-right: 12px; flex: none; background: var(--surface-2); border: 1px solid var(--line); color: var(--muted); font-size: 12px; padding: 5px 10px; border-radius: 999px; }
.chip.on { background: var(--accent-soft); color: var(--accent); border-color: transparent; font-weight: 600; }
.expand { width: 44px; align-self: stretch; background: none; border: 0; color: var(--muted); display: grid; place-items: center; }
.expand svg { width: 18px; height: 18px; stroke: currentColor; stroke-width: 2; fill: none; transition: transform .2s; }
.expand[aria-expanded="true"] svg { transform: rotate(180deg); }
.detail { padding: 2px 16px 14px 54px; font-size: 14px; color: var(--muted); }
.detail ul { margin: 0; padding: 0; list-style: none; }
.detail li { display: flex; justify-content: space-between; gap: 12px; padding: 3px 0; }
.detail li span:last-child { white-space: nowrap; }
.macros { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 6px; }
.macros span { background: var(--surface-2); color: var(--text); border-radius: 8px; padding: 3px 8px; font-size: 12px; font-weight: 600; }

details.note { border-top: 1px solid var(--line); padding: 12px 16px; font-size: 14px; color: var(--muted); }
details.note summary { cursor: pointer; font-weight: 600; color: var(--text); }
details.note ul, details.note ol { margin: 8px 0 0; padding-left: 20px; }
details.note li { margin: 4px 0; }
details.note p { margin: 8px 0 0; }

/* Segmented control */
.seg { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; background: var(--surface-2); border-radius: 12px; padding: 4px; margin: 6px 16px 10px; }
.seg button { border: 0; background: none; border-radius: 9px; padding: 8px 2px; font-size: 13px; color: var(--muted); line-height: 1.2; }
.seg button.on { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: var(--shadow); }
.seg small { display: block; font-size: 10px; color: var(--accent); font-weight: 600; }
.rest { padding: 6px 16px 16px; color: var(--muted); }

/* Lift log */
.logp { padding: 2px 16px 14px 54px; display: grid; gap: 8px; justify-items: start; }
.lastl { margin: 0; font-size: 13px; color: var(--muted); }
.setrow { display: flex; align-items: center; gap: 8px; width: 100%; font-size: 14px; color: var(--muted); }
.setrow > span:first-child { width: 42px; }
.input.sm { width: 86px; padding: 9px 8px; text-align: center; }
.setrow .x { color: var(--muted); }
.lift { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 11px 16px; border-top: 1px solid var(--line); }
.lift b { font-weight: 600; }
.lift small { color: var(--muted); grid-column: 1; }
.lift .d { grid-row: 1 / 3; grid-column: 2; align-self: center; font-weight: 700; font-size: 14px; text-align: right; }
.d.up { color: var(--accent); }

/* Photos */
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 4px 16px 14px; }
.ph { position: relative; aspect-ratio: 3 / 4; border: 0; padding: 0; border-radius: 12px; overflow: hidden; background: var(--surface-2); }
.ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ph span { position: absolute; left: 6px; bottom: 6px; background: rgba(0, 0, 0, .6); color: #fff; font-size: 11px; padding: 2px 7px; border-radius: 99px; }
.dayh { padding: 8px 16px 0; font-size: 13px; color: var(--muted); font-weight: 600; }
.cmp { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 4px 16px 14px; }
.cmp figure { margin: 0; }
.cmp img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 12px; display: block; }
.cmp figcaption { font-size: 12px; color: var(--muted); text-align: center; margin-top: 4px; }
.cmp .none { aspect-ratio: 3 / 4; display: grid; place-items: center; background: var(--surface-2); border-radius: 12px; color: var(--muted); font-size: 13px; text-align: center; padding: 8px; }
.viewer { position: fixed; inset: 0; z-index: 30; background: rgba(0, 0, 0, .92); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 16px; }
.viewer img { max-width: 100%; max-height: 72vh; border-radius: 12px; }
.viewer p { color: #fff; margin: 0; }
.viewer .btns { padding: 0; }

/* Heatmap */
.dow, .heat { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.dow { padding: 0 16px; font-size: 12px; color: var(--muted); text-align: center; margin-top: 6px; }
.heat { padding: 8px 16px 16px; }
.cell { aspect-ratio: 1; border-radius: 10px; border: 0; background: var(--surface-2); font-size: 13px; color: var(--text); display: grid; place-items: center; }
.cell.today { outline: 2px solid var(--accent); outline-offset: 1px; }
.cell:disabled { opacity: .35; }
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 12px; text-align: center; box-shadow: var(--shadow); }
.stat b { display: block; font-size: 22px; }
.stat span { font-size: 12px; color: var(--muted); }
.bars { padding: 6px 16px 16px; display: grid; gap: 10px; }
.bar-row { display: grid; grid-template-columns: 90px 1fr 40px; align-items: center; gap: 10px; font-size: 14px; }
.bar { height: 10px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.bar-row em { font-style: normal; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }

/* Forms */
.form { padding: 6px 16px 16px; display: grid; gap: 12px; }
.field { display: grid; gap: 4px; }
.field label { font-size: 13px; color: var(--muted); }
.input { width: 100%; padding: 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); }
.input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn { background: var(--accent); color: var(--accent-ink); border: 0; padding: 12px 16px; border-radius: 12px; font-weight: 600; }
.btn.ghost { background: var(--surface-2); color: var(--text); }
.btn.danger { background: transparent; color: var(--danger); border: 1px solid var(--line); }
.btn:disabled { opacity: .5; }
.btns { display: flex; flex-wrap: wrap; gap: 10px; padding: 0 16px 16px; }
.hint { font-size: 13px; color: var(--muted); padding: 0 16px 14px; margin: 0; }
.hint.warn { color: var(--warn); }

/* Weight */
.chart { padding: 4px 8px 12px; }
.chart svg { width: 100%; height: auto; display: block; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .lbl { fill: var(--muted); font-size: 10px; }
.chart .line { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.chart .dot { fill: var(--surface); stroke: var(--accent); stroke-width: 2.5; }
.wrow { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-top: 1px solid var(--line); }
.wrow b { font-size: 17px; }
.wrow small { color: var(--muted); display: block; }
.delta { font-size: 14px; font-weight: 600; margin-right: 10px; }
.delta.down { color: var(--accent); }
.delta.up { color: var(--warn); }
.link { background: none; border: 0; color: var(--muted); padding: 6px; font-size: 13px; }
.empty { padding: 24px 16px; text-align: center; color: var(--muted); }

/* Settings */
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 16px; border-top: 1px solid var(--line); }
.set-row .l { min-width: 0; }
.set-row .l b { display: block; font-weight: 600; }
.set-row .l small { color: var(--muted); }
.time { width: 128px; padding: 8px 6px; font-size: 16px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); }
.set-row.wrap { flex-wrap: wrap; }
.set-row.wrap .row-ctl { width: 100%; justify-content: space-between; }
.switch { position: relative; width: 46px; height: 28px; flex: none; border-radius: 99px; border: 0; background: var(--surface-2); transition: .2s; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--muted); transition: .2s; }
.switch[aria-checked="true"] { background: var(--accent); }
.switch[aria-checked="true"]::after { transform: translateX(18px); background: var(--accent-ink); }
.row-ctl { display: flex; align-items: center; gap: 10px; }

/* Accounts + routine editor */
body.noauth .tabs { display: none; }
body.noauth { padding-bottom: 24px; }
.auth { max-width: 420px; margin: 0 auto; }
.auth-brand { text-align: center; padding: 18px 8px 4px; }
.auth-brand img { border-radius: 16px; }
.auth-brand h2 { margin: 10px 0 4px; font-size: 24px; }
.auth-brand p { margin: 0; color: var(--muted); font-size: 14px; }
.seg { display: flex; flex-wrap: wrap; }
.seg button { flex: 1 1 auto; min-width: 72px; }
.edit { padding: 12px 16px 14px; border-top: 1px solid var(--line); display: grid; gap: 10px; }
.card-h + .edit { border-top: 0; }
.edit .input { padding: 10px 12px; }
textarea.input { resize: vertical; min-height: 70px; line-height: 1.4; }
.four { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.rt { display: flex; justify-content: flex-end; gap: 4px; }
.rt .link { min-width: 36px; padding: 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.rt .link:disabled { opacity: .35; }
.rt .del { color: var(--danger); }
.exr { display: grid; gap: 8px; padding: 10px; background: var(--bg); border-radius: 12px; border: 1px solid var(--line); }
.sub { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.btn.sm { padding: 9px 12px; font-size: 14px; justify-self: start; }
.chk-line { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--muted); }
.chk-line input { width: 20px; height: 20px; margin-top: 1px; accent-color: var(--accent); flex: none; }
.edit.wkedit { border-top: 8px solid var(--bg); }
.exn { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.exr .rt { padding-top: 2px; }
.exr .rt .del { padding: 8px 12px; }
.rt .link { white-space: nowrap; min-height: 40px; }

/* Friends */
.tabs button { font-size: 11.5px; }
.fr { padding: 14px 16px; border-top: 1px solid var(--line); display: grid; gap: 10px; }
.card-h + .fr { border-top: 0; }
.fr.me { background: color-mix(in srgb, var(--accent) 6%, transparent); }
.fr-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.fr-h b { font-size: 16px; }
.tag { font-size: 11px; color: var(--muted); background: var(--surface-2); padding: 1px 7px; border-radius: 99px; font-weight: 500; margin-left: 4px; }
.stk { font-weight: 700; font-size: 14px; }
.fr-b { display: grid; grid-template-columns: auto 1fr; gap: 10px 16px; align-items: center; }
.big { font-size: 30px; font-weight: 700; line-height: 1; }
.big small { display: block; font-size: 12px; font-weight: 400; color: var(--muted); margin-top: 4px; }
.mbs { display: flex; gap: 10px; align-items: flex-end; height: 46px; }
.mb { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 3px; position: relative; }
.mb i { display: block; width: 100%; max-width: 26px; background: var(--accent); border-radius: 5px 5px 2px 2px; min-height: 3px; opacity: .9; }
.mb span { font-size: 10px; color: var(--muted); }
.wk { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.wk-d { height: 24px; border-radius: 7px; background: var(--surface-2); font-size: 11px; display: grid; place-items: center; color: var(--text); }
.wk-d.none { opacity: .45; }
.fr-a { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.fr-a .del { color: var(--danger); }
.code { margin: 0 16px 12px; padding: 14px; text-align: center; font: 700 24px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .18em; background: var(--surface-2); border-radius: 12px; user-select: all; }
details.card > summary { list-style: none; }
details.card > summary::-webkit-details-marker { display: none; }

/* Coaching */
.tabs button[hidden] { display: none; }
.tabs.seven button { font-size: 10px; min-width: 0; padding-left: 0; padding-right: 0; }
.clientbtn { width: 100%; text-align: left; background: none; border: 0; border-top: 1px solid var(--line); position: relative; display: grid; }
.card-h + .clientbtn { border-top: 0; }
.clientbtn .go { position: absolute; right: 16px; top: 14px; font-size: 13px; color: var(--accent); font-weight: 600; }
.clientbtn .stk { margin-right: 52px; }
.ro { display: flex; gap: 12px; padding: 10px 16px; border-top: 1px solid var(--line); align-items: flex-start; }
.card-h + .ro { border-top: 0; }
.rochk { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line); flex: none; display: grid; place-items: center; margin-top: 1px; }
.rochk svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 3; fill: none; }
.ro.ok .rochk { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.ro .t { font-weight: 600; }
.ro .s { color: var(--muted); font-size: 14px; }
.ro .lg { margin-top: 4px; font-size: 13px; color: var(--accent); font-weight: 600; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Date / time fields must never be wider than their column (iOS gives them an intrinsic width) */
.field, .two > *, .form > * { min-width: 0; }
.input, input[type="date"], input[type="time"], input[type="number"], select { min-width: 0; max-width: 100%; }
input[type="date"].input, input[type="time"].input {
  -webkit-appearance: none; appearance: none; display: block; width: 100%; min-height: 46px; line-height: 1.2; text-align: left;
}
input[type="date"]::-webkit-date-and-time-value { text-align: left; min-width: 0; }
input[type="date"]::-webkit-calendar-picker-indicator { margin-left: 4px; }
@media (max-width: 400px) { .two:has(input[type="date"]) { grid-template-columns: 1fr; } }

/* Colour: brand header, section colours, richer dark mode */
.top { background: linear-gradient(120deg, #0f8f6a 0%, #0b7a86 100%); color: #fff; }
@media (prefers-color-scheme: dark) { .top { background: linear-gradient(120deg, #0d7a5a 0%, #0a5f78 100%); color: #fff; } }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand img { border-radius: 10px; flex: none; box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .25); }
.brand h1 { white-space: nowrap; }
@media (prefers-color-scheme: dark) {
  :root { --bg: #0a1714; --surface: #12211c; --surface-2: #1b2d26; --line: #25392f; --accent-soft: #15402f; }
  .progress { background: linear-gradient(135deg, #12211c 0%, #14332b 100%); }
}
.progress { background: linear-gradient(135deg, var(--surface) 0%, color-mix(in srgb, var(--accent) 9%, var(--surface)) 100%); }
.ring .fg { stroke: url(#rg); }
.sec { border-top: 3px solid var(--sec); }
.sec-supp { --sec: #f0b155; --sec-ink: #3a2600; }
.sec-eat { --sec: #ff8a65; --sec-ink: #3b1305; }
.sec-work { --sec: #7c8cff; --sec-ink: #ffffff; }
.sec-habit { --sec: #2bc796; --sec-ink: #06231a; }
.secico { display: inline-grid; place-items: center; width: 28px; height: 28px; margin-right: 9px; border-radius: 9px; font-size: 16px; line-height: 1; vertical-align: -6px;
  background: color-mix(in srgb, var(--sec) 22%, transparent); }
.sec [aria-checked="true"] .chk { background: var(--sec); border-color: var(--sec); }
.sec [aria-checked="true"] .chk svg { stroke: var(--sec-ink); }
.sec .count.full { background: var(--sec); color: var(--sec-ink); }
.sec .chip.on { background: color-mix(in srgb, var(--sec) 22%, transparent); color: var(--text); }
.sec .seg button.on { background: var(--sec); color: var(--sec-ink); }
.sec .seg small { color: inherit; opacity: .8; }
.tabs button.on svg { stroke-width: 2.2; }

/* Install + reminder prompts */
.promo { display: flex; align-items: center; gap: 12px; padding: 12px 8px 12px 14px; border-radius: 16px; margin-bottom: 12px; color: #fff; background: linear-gradient(120deg, #0f8f6a, #0b7a86); }
.promo.alt { background: linear-gradient(120deg, #7c6cf0, #5b7cf0); }
.promo .pi { font-size: 24px; line-height: 1; flex: none; }
.promo .pt { flex: 1; min-width: 0; display: grid; gap: 1px; }
.promo .pt b { font-size: 15px; }
.promo .pt small { font-size: 12.5px; opacity: .9; line-height: 1.3; }
.promo .pb { flex: none; background: #fff; color: #0b3d36; border: 0; border-radius: 11px; padding: 9px 13px; font-weight: 700; font-size: 14px; white-space: nowrap; }
.promo.alt .pb { color: #2a2a7a; }
.promo .px { flex: none; width: 34px; height: 34px; background: none; border: 0; color: #fff; opacity: .8; font-size: 15px; }
.sheet-bg { position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, .55); display: flex; align-items: flex-end; }
.sheet { background: var(--surface); width: 100%; max-width: 640px; margin: 0 auto; border-radius: 22px 22px 0 0; padding: 18px 18px calc(18px + env(safe-area-inset-bottom)); max-height: 88vh; overflow: auto; border: 1px solid var(--line); }
.sheet-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.sheet-h h2 { margin: 0; font-size: 20px; }
.steps { list-style: none; counter-reset: s; margin: 8px 0 0; padding: 0; display: grid; gap: 14px; }
.steps li { counter-increment: s; display: flex; gap: 12px; align-items: flex-start; line-height: 1.4; }
.steps li::before { content: counter(s); flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-weight: 700; font-size: 14px; }
.shi { width: 18px; height: 18px; stroke: var(--accent); stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round; vertical-align: -4px; }
