/* IronLog — Weekly check-in (body.js). Bump ?v= on both body tags in ironlog.html when this changes.
   Colors are theme tokens only. The camera reuses Fuel's scanner tokens (--fuel-scan-*,
   defined for every theme in fuel.css). Lift = green, cardio = --cardio, Fuel = accent,
   supps = --supp, as everywhere else. */

/* ── Progress › Body ── */
.bd-hd { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding-bottom: 10px; border-bottom: 1px solid var(--border); margin-bottom: 10px; }
.bd-hd b { font-size: 12px; font-weight: 800; letter-spacing: .8px; text-transform: uppercase; color: var(--text2); } /* the kit's section title (.sec-t in ironlog.html) */
/* the title's line is the divider: the first row under it drops its own */
.bd-hd + *, .bd-hd + * > :first-child { border-top: 0; }
.bd-hd > span { font-size: 12px; color: var(--text2); }
.bd-link { background: none; border: none; padding: 0; font: inherit; font-size: 13px; font-weight: 600; color: var(--accent); cursor: pointer; }
.bd-center { text-align: center; }
.bd-good { color: var(--green); font-weight: 600; }
.bd-due { background: linear-gradient(0deg, var(--accent-faint), var(--accent-faint)), var(--bg2); border-color: var(--accent); }
.bd-due-top { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.bd-due-top b { display: block; font-size: 15px; }
.bd-due-ic { width: 42px; height: 42px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.bd-next { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 12px; padding: 8px 8px 8px 14px; background: var(--bg2); border: var(--card-bw, 1px) solid var(--card-border, var(--border)); box-shadow: var(--card-shadow); border-radius: var(--radius); font-size: 13px; color: var(--text2); }
.bd-big { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.bd-big b { font-size: 34px; font-weight: 700; letter-spacing: -.5px; font-variant-numeric: tabular-nums; }
.bd-big span { color: var(--text2); font-size: 15px; font-weight: 600; }
.bd-big em { margin-left: auto; font-style: normal; font-size: 13px; font-weight: 600; color: var(--text2); }
.bd-big em.good { color: var(--green); }
.bd-bar { height: 6px; border-radius: 3px; background: var(--bg3); overflow: hidden; margin: 8px 0 6px; }
.bd-bar i { display: block; height: 100%; background: var(--primary); border-radius: 3px; }
.bd-goal-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.bd-pace { display: inline-flex; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--bg3); color: var(--text2); }
.bd-pace.ok { background: var(--green-soft); color: var(--green); }
.bd-pace.warn { background: var(--red-soft); color: var(--red); }
.bd-pill { display: inline-flex; font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); }
.bd-chart { margin-top: 12px; }
.bd-chart svg { width: 100%; height: auto; display: block; }
.bd-chart text { font-size: 10px; fill: var(--text3); }
.bd-chart .g { stroke: var(--chart-grid); stroke-width: 1; }
.bd-chart .plan { stroke: var(--text3); stroke-width: 1.2; stroke-dasharray: 3 3; }
.bd-chart .dot { fill: var(--text3); opacity: .75; }
.bd-chart .avg { fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; }
.bd-chart .end { fill: var(--accent); stroke: var(--bg2); stroke-width: 2; }
.bd-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 11px; color: var(--text2); margin-top: 6px; }
.bd-legend i { display: inline-block; width: 10px; height: 3px; border-radius: 2px; background: var(--accent); vertical-align: 3px; margin-right: 5px; }
.bd-legend i.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--text3); vertical-align: 1px; }
.bd-legend i.plan { background: none; border-top: 1.5px dashed var(--text3); height: 0; }
.bd-goal-foot { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.bd-bfline { display: flex; align-items: baseline; gap: 8px; width: 100%; margin-top: 12px; padding: 10px 0 0; border: 0; border-top: 1px solid var(--border); background: none; color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.bd-bfline > span { font-size: 13px; color: var(--text2); }
.bd-bfline b { font-size: 17px; }
.bd-bfline em { flex: 1; min-width: 0; font-style: normal; font-size: 12px; color: var(--text2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-bfline i { font-style: normal; color: var(--text3); }
.bd-goal-foot .btn svg { flex-shrink: 0; }
.bd-thumbs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px; }
.bd-thumbs::-webkit-scrollbar { display: none; }
.bd-thumbs .bd-th { flex: 0 0 calc((100% - 18px) / 4); }
.bd-th { position: relative; aspect-ratio: 3 / 4; border-radius: 8px; overflow: hidden; background: var(--bg3); border: none; padding: 0; cursor: pointer; }
.bd-th img, .bd-ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bd-th em, .bd-ph em { position: absolute; left: 0; right: 0; bottom: 0; font-style: normal; font-size: 10px; font-weight: 600; text-align: center; padding: 12px 0 4px; color: var(--fuel-scan-fg); background: linear-gradient(transparent, var(--fuel-scan-scrim)); }
.bd-th.blur img { filter: blur(9px) saturate(.6); transform: scale(1.15); }
.bd-photos-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; min-height: 18px; }
.bd-n { font-weight: 500; color: var(--text2); font-size: 13px; }
.bd-unblur { display: inline-flex; align-items: center; gap: 5px; border: 1px solid var(--border); background: var(--bg3); color: var(--text2); border-radius: 99px; padding: 5px 11px; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; flex-shrink: 0; }
.bd-unblur.on { background: var(--accent-soft); border-color: transparent; color: var(--accent); }
.bd-photo-acts { display: flex; gap: 8px; margin-top: 10px; }
.bd-photo-acts .btn:first-child { flex: 1; min-width: 0; }
.bd-row { gap: 12px; padding: 10px 16px; }
.bd-row-th { width: 34px; aspect-ratio: 3 / 4; border-radius: 6px; overflow: hidden; background: var(--bg3); flex-shrink: 0; }
.bd-row-th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bd-row-th.blur img { filter: blur(5px) saturate(.6); transform: scale(1.2); }
.bd-delta { font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--red-soft); color: var(--red); white-space: nowrap; flex-shrink: 0; font-variant-numeric: tabular-nums; }
.bd-delta.good { background: var(--green-soft); color: var(--green); }
.bd-fold-ic { color: var(--text3); display: flex; flex-shrink: 0; }
.bd-fold-ic svg { transition: transform .15s; }
.bd-fold.open .bd-fold-ic svg { transform: rotate(90deg); }
.bd-nest { border-top: 1px solid var(--border); background: var(--bg); padding-left: 12px; }
.bd-nest > .pg-row:first-child { border-top: none; }
.bd-all-ctl { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin: 6px 0 4px; }
/* One card per month, header sticky inside it (clip, not hidden: hidden breaks sticky). No full-width --bg band: it showed as a stripe over scene themes. */
.bd-mcard { overflow: hidden; overflow: clip; }
.bd-mcard:not(.bd-list) { padding: 0 12px 12px; }
.bd-month { position: sticky; top: 0; z-index: 2; background: var(--bg2); display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 12px 2px 8px; }
.bd-list .bd-month { padding: 12px 16px 6px; }
.bd-month b { font-size: 15px; }
.bd-month span { font-size: 12px; color: var(--text2); font-variant-numeric: tabular-nums; }
.bd-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.bd-th.none { display: flex; align-items: center; justify-content: center; border: 1px dashed var(--border); background: none; }
.bd-th.none span { font-size: 10px; color: var(--text3); }
.bd-list { padding: 0; overflow: hidden; }
.bd-list.bd-mcard { overflow: clip; }
.bd-list .pg-row svg { color: var(--text3); flex-shrink: 0; }

/* ── Fuel date-row chip ── */
.bd-chip { display: inline-flex; align-items: center; gap: 5px; height: 30px; padding: 0 11px; border-radius: 15px; border: 1px solid var(--accent); background: var(--accent-faint); color: var(--accent); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; white-space: nowrap; margin-left: auto; }
.bd-chip svg { width: 15px; height: 15px; flex-shrink: 0; }
.bd-chip .bd-ic-scale { width: 17px; height: 17px; } /* filled scale: reads at chip size where the outline didn't */
/* Fuel's chip line (fuel.css .fu-chiprow) with the weigh-in / check-in chip and two more:
   supps / burned drop their words (water.css shortens the water chip with all four). */
.fu-chiprow:has(.bd-chip):has(:is(.wa-wrap, .sp-chip-wrap, .fu-burn-wrap) ~ :is(.wa-wrap, .sp-chip-wrap, .fu-burn-wrap)) :is(.sp-chip, .fu-burn) { padding: 0 9px; gap: 4px; }
.fu-chiprow:has(.bd-chip):has(:is(.wa-wrap, .sp-chip-wrap, .fu-burn-wrap) ~ :is(.wa-wrap, .sp-chip-wrap, .fu-burn-wrap)) :is(.sp-chip > span, .fu-burn > span) { display: none; }

/* ── Weigh-in ── */
.bd-wi { display: flex; align-items: center; gap: 8px; }
.bd-wi input { flex: 1; min-width: 0; font-size: 22px; font-weight: 700; text-align: center; font-variant-numeric: tabular-nums; }
.bd-wi > span { color: var(--text2); font-weight: 600; }
.bd-wi-inline { margin-top: 12px; }
.bd-wi-inline input { font-size: 15px; font-weight: 500; text-align: left; }
.bd-wi-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--border); font-size: 14px; }
.bd-wi-row span { flex: 1; color: var(--text2); }
.bd-wi-row b { font-variant-numeric: tabular-nums; }
.bd-wi-row .btn-icon { padding: 6px; }
.bd-wi-row .btn-icon svg { width: 14px; height: 14px; }

/* ── Check-in: camera ── */
#bd-flow:empty, #bd-cmp:empty { display: none; }
.bd-cam { position: fixed; inset: 0; z-index: 160; background: var(--fuel-scan-bg); color: var(--fuel-scan-fg); overflow: hidden; }
.bd-frame { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(100vw, 75vh); aspect-ratio: 3 / 4; overflow: hidden; background: var(--fuel-scan-bg); }
.bd-frame video, .bd-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.bd-frame.mirror video { transform: scaleX(-1); }
.bd-last-ov { opacity: .5; pointer-events: none; }
.bd-last-ov.slide { opacity: 1; }
.bd-last-ov[hidden] { display: none; }
.bd-guide { position: absolute; inset: 6% 12%; border: 1px dashed var(--fuel-scan-fg); opacity: .35; border-radius: 10px; pointer-events: none; }
/* Last week's head / feet lines (live and Line up); draggable handles on Your lines */
.bd-line { position: absolute; left: 0; right: 0; height: 0; border-top: 2px dashed var(--accent2); pointer-events: none; z-index: 1; }
.bd-line em { position: absolute; right: 8px; top: 4px; font-style: normal; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent2); background: var(--fuel-scan-scrim); padding: 2px 6px; border-radius: 5px; }
.bd-line-feet em { top: auto; bottom: 4px; }
.bd-line-ed { pointer-events: none; }
.bd-gh { position: absolute; right: 8px; top: -17px; height: 34px; padding: 0 12px; border: none; border-radius: 17px; background: var(--primary); color: var(--on-accent); font: inherit; font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; display: inline-flex; align-items: center; gap: 6px; cursor: ns-resize; touch-action: none; pointer-events: auto; }
.bd-gh::before { content: ''; position: absolute; inset: -10px -8px; }
/* Corner thumbnail of last week on the camera */
.bd-thumb { position: absolute; left: 12px; top: calc(max(14px, env(safe-area-inset-top)) + 128px); width: 72px; height: 116px; padding: 0; border: 2px solid var(--fuel-scan-fg); border-radius: 10px; overflow: hidden; background: var(--fuel-scan-scrim); cursor: pointer; z-index: 2; }
.bd-thumb.on { border-color: var(--accent); }
.bd-thumb img { display: block; width: 100%; height: 96px; object-fit: cover; }
.bd-thumb span { display: flex; align-items: center; justify-content: center; height: 20px; font-size: 10px; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; color: var(--fuel-scan-fg); background: var(--fuel-scan-scrim); }
/* Line up / Your lines: the whole shot, moved and zoomed inside the 3:4 frame */
.bd-al { touch-action: none; user-select: none; -webkit-user-select: none; }
.bd-al.pan { cursor: grab; }
.bd-frame img.bd-src { inset: auto; object-fit: fill; max-width: none; pointer-events: none; transform-origin: center; }
/* The slider line: a 56 px strip you drag (same look as Compare's .bd-wipe-h); elsewhere drags move the shot */
.bd-al-h { position: absolute; top: 0; bottom: 0; width: 56px; margin-left: -28px; z-index: 1; touch-action: none; cursor: ew-resize; background: linear-gradient(var(--fuel-scan-fg), var(--fuel-scan-fg)) center / 2px 100% no-repeat; }
.bd-al-h::after { content: '‹ ›'; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; border-radius: 50%; background: var(--fuel-scan-fg); color: var(--fuel-scan-bg); font-size: 15px; font-weight: 700; line-height: 40px; text-align: center; white-space: nowrap; transition: transform .12s ease-out; }
.bd-al-h.on::after { transform: translate(-50%, -50%) scale(1.12); }
.bd-al-h:focus-visible { outline: none; }
.bd-al-h:focus-visible::after { box-shadow: 0 0 0 3px var(--accent); }
.bd-al-tag { position: absolute; left: 10px; bottom: 24%; font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; padding: 4px 8px; border-radius: 6px; background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); pointer-events: none; }
.bd-al-tag.r { left: auto; right: 10px; }
.bd-al-row { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.bd-al-undo { height: 44px; border-radius: 22px; border: none; padding: 0 16px; background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); font: inherit; font-size: 14px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.bd-al-undo:disabled { opacity: .35; cursor: default; }
.bd-al-sp { flex: 1; }
.bd-al-z { width: 44px; height: 44px; border-radius: 22px; border: none; background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); font: inherit; font-size: 22px; font-weight: 600; line-height: 1; cursor: pointer; }
.bd-count { position: absolute; top: 45%; left: 50%; transform: translate(-50%, -50%); font-size: 110px; font-weight: 800; line-height: 1; color: var(--fuel-scan-fg); text-shadow: 0 4px 24px var(--fuel-scan-scrim); pointer-events: none; }
.bd-count[hidden] { display: none; }
.bd-flash { position: absolute; inset: 0; background: var(--fuel-scan-fg); opacity: 0; pointer-events: none; }
.bd-flash.go { animation: bd-flash .35s ease-out; }
@keyframes bd-flash { from { opacity: .85; } to { opacity: 0; } }
.bd-cam-top { position: absolute; left: 0; right: 0; top: 0; padding: max(14px, env(safe-area-inset-top)) 14px 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; z-index: 2; }
.bd-cam-btn { width: 40px; height: 40px; border-radius: 20px; border: none; background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; }
.bd-cam-step { font-size: 13px; font-weight: 600; background: var(--fuel-scan-scrim); padding: 7px 12px; border-radius: 99px; }
.bd-cam-next { height: 40px; border: none; border-radius: 20px; padding: 0 14px; background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.bd-poses { position: absolute; top: calc(max(14px, env(safe-area-inset-top)) + 52px); left: 50%; transform: translateX(-50%); display: flex; gap: 4px; background: var(--fuel-scan-scrim); border-radius: 99px; padding: 4px; z-index: 2; }
.bd-poses button { border: none; background: none; color: var(--fuel-scan-fg); opacity: .8; font: inherit; font-size: 13px; font-weight: 600; padding: 7px 14px; border-radius: 99px; cursor: pointer; display: inline-flex; gap: 6px; align-items: center; }
.bd-poses button.on { background: var(--fuel-scan-fg); color: var(--fuel-scan-bg); opacity: 1; }
.bd-poses button.done::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.bd-hint { position: absolute; top: calc(max(14px, env(safe-area-inset-top)) + 100px); left: 16px; right: 16px; text-align: center; z-index: 2; pointer-events: none; }
.bd-hint { font-size: 12.5px; text-shadow: 0 1px 3px var(--fuel-scan-scrim); }
.bd-hint b { color: var(--accent2); }
.bd-cam-bot { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 24px max(26px, calc(env(safe-area-inset-bottom) + 14px)); background: linear-gradient(transparent, var(--fuel-scan-scrim) 40%); z-index: 2; }
.bd-cam-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; justify-items: center; }
.bd-cam-row2 { display: flex; justify-content: space-between; margin-top: 10px; }
.bd-opt { display: flex; flex-direction: column; align-items: center; gap: 4px; font: inherit; font-size: 11px; color: var(--fuel-scan-fg); background: none; border: none; cursor: pointer; }
.bd-opt span { width: 46px; height: 46px; border-radius: 50%; background: var(--fuel-scan-scrim); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; }
.bd-opt.on span { background: var(--fuel-scan-fg); color: var(--fuel-scan-bg); }
.bd-opt:disabled { opacity: .45; cursor: default; }
.bd-shutter { width: 78px; height: 78px; border-radius: 50%; border: 4px solid var(--fuel-scan-fg); background: none; padding: 4px; cursor: pointer; }
.bd-shutter i { display: block; width: 100%; height: 100%; border-radius: 50%; background: var(--fuel-scan-fg); }
.bd-mini { display: inline-flex; align-items: center; gap: 6px; background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); border: none; border-radius: 99px; padding: 8px 12px; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.bd-mini svg { width: 16px; height: 16px; }
.bd-shot-acts { display: flex; gap: 10px; }
.bd-shot-acts .btn { flex: 1; padding: 13px; }
.bd-cam-ghostbtn { background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); }

/* ── Check-in: numbers, compare (full-screen pages in app colors) ── */
.bd-page { position: fixed; inset: 0; z-index: 160; background: var(--bg); color: var(--text); overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
#bd-cmp .bd-page { z-index: 150; }
.bd-page-in { max-width: 560px; margin: 0 auto; padding: max(14px, env(safe-area-inset-top)) 16px max(24px, calc(env(safe-area-inset-bottom) + 16px)); }
.bd-topbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; min-height: 36px; }
.bd-topbar button:not(.seg-sm button) { background: none; border: none; padding: 4px 0; font: inherit; font-size: 14px; font-weight: 600; color: var(--text2); cursor: pointer; }
.bd-topbar b { font-size: 15px; }
.bd-topbar-tab { margin-bottom: 2px; }
.bd-title { font-size: 22px; font-weight: 700; margin: 4px 0 2px; }
.bd-steps { display: flex; gap: 6px; margin: 4px 0 14px; }
.bd-steps i { flex: 1; height: 4px; border-radius: 2px; background: var(--accent); }
.bd-lbl { font-size: 11px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--text2); margin-bottom: 6px; }
.bd-opt-l { font-size: 11px; color: var(--text3); font-weight: 500; text-transform: none; letter-spacing: 0; margin-left: 4px; }
.bd-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin-top: 10px; }
.bd-days div { text-align: center; font-size: 10px; color: var(--text3); }
.bd-days b { display: block; font-size: 12px; color: var(--text); font-weight: 600; margin-top: 2px; font-variant-numeric: tabular-nums; }
/* A past week's check-in: the days are buttons that pick the weight box's day */
.bd-days.pick button { font: inherit; text-align: center; font-size: 10px; color: var(--text3); background: var(--bg3); border: 1px solid transparent; border-radius: 8px; padding: 6px 0; min-height: 44px; cursor: pointer; }
.bd-days.pick button.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
.bd-days.pick + .bd-wi, .bd-days.pick ~ .bd-wi { margin-top: 10px; }
.bd-days .none b { color: var(--text3); }
.bd-stepper { display: flex; align-items: center; gap: 8px; }
.bd-stepper button { width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--border); background: var(--bg3); color: var(--text); font: inherit; font-size: 22px; cursor: pointer; }
.bd-stepper output { flex: 1; text-align: center; font-size: 24px; font-weight: 700; font-variant-numeric: tabular-nums; }
.bd-stepper output small { font-size: 13px; color: var(--text2); font-weight: 600; margin-left: 3px; }
.bd-feel { display: grid; grid-template-columns: 68px minmax(0, 1fr); align-items: center; column-gap: 10px; padding: 6px 0; }
.bd-feel > span { font-size: 14px; font-weight: 600; }
.bd-scale { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 5px; }
.bd-scale button { height: 36px; border-radius: 8px; border: 1px solid var(--border); background: var(--bg3); color: var(--text2); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.bd-scale button.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.bd-scale-l { grid-column: 2; display: flex; justify-content: space-between; font-size: 10px; color: var(--text3); margin-top: 3px; }
.bd-page textarea { width: 100%; resize: none; font: inherit; font-size: 15px; }
.bd-finish { padding: 14px; margin-top: 4px; }

/* ── Your week ── */
.bd-pair-card { padding: 8px; }
.bd-pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 6px; }
.bd-pair.one { grid-template-columns: minmax(0, 320px); justify-content: center; }
.bd-ph { position: relative; aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; background: var(--bg3); }
.bd-ph em { top: 8px; bottom: auto; left: 8px; right: auto; padding: 3px 8px; border-radius: 99px; background: var(--fuel-scan-scrim); }
.bd-ph.none { display: flex; align-items: center; justify-content: center; color: var(--text3); font-size: 12px; cursor: default; }
.bd-pair-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; padding: 8px 6px 2px; }
.bd-2col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.bd-num { font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; display: block; }
.bd-feelline { margin-top: 10px; }
.bd-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 12px; }
.bd-tile { background: var(--bg2); border: var(--card-bw) solid var(--card-border); box-shadow: var(--card-shadow); border-radius: var(--radius); padding: 12px; min-width: 0; text-align: left; font: inherit; color: var(--text); cursor: pointer; display: flex; flex-direction: column; }
.bd-tile:disabled { cursor: default; }
.bd-tile-h { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--text2); margin-bottom: 6px; }
.bd-tile-h i { width: 22px; height: 22px; border-radius: 6px; display: flex; align-items: center; justify-content: center; }
.bd-tile b { font-size: 19px; font-variant-numeric: tabular-nums; }
.bd-tile small { font-size: 12px; color: var(--text2); margin-top: 2px; line-height: 1.35; }
.ic-lift { background: var(--green-soft); color: var(--green); }
.ic-cardio { background: var(--cardio-soft); color: var(--cardio); }
.ic-fuel { background: var(--accent-soft); color: var(--accent); }
.ic-supp { background: var(--supp-soft); color: var(--supp); }
.bd-dots { display: flex; gap: 3px; margin-top: 8px; }
.bd-dots i { flex: 1; height: 5px; border-radius: 3px; background: var(--bg4); }
.bd-dots i.lift { background: var(--green); }
.bd-dots i.cardio { background: var(--cardio); }
.bd-stood { padding-left: 18px; margin: 0; }
.bd-stood li { margin: 0 0 8px; font-size: 13.5px; line-height: 1.45; }
.bd-stood li:last-child { margin-bottom: 0; }
.bd-stood b { font-weight: 600; }
.bd-review-acts { display: flex; justify-content: center; gap: 10px; margin: 4px 0 8px; }

/* ── Coach ── */
.bd-coach-hd { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; }
.bd-coach-hd b { display: block; font-size: 15px; }
.bd-coach-av { width: 38px; height: 38px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.bd-coach-off { border-style: dashed; }
.bd-coach-msg { font-size: 14px; line-height: 1.5; }
.bd-coach-msg p { margin: 0 0 8px; }
.bd-coach-wait { display: flex; align-items: center; gap: 10px; color: var(--text2); font-size: 13px; }
.bd-coach-wait i { flex-shrink: 0; box-sizing: border-box; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--accent); border-right-color: transparent; animation: btn-spin .7s linear infinite; }
.bd-coach-err { font-size: 13px; color: var(--red); margin: 8px 0; }
.bd-ch { border: 1px solid var(--border); border-radius: 10px; padding: 12px; margin-bottom: 8px; }
.bd-ch.applied, .bd-ch.done { border-color: var(--green); background: var(--green-faint); }
.bd-ch.declined { opacity: .6; }
.bd-ch-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 4px; }
.bd-ch-top b { font-size: 14px; }
.bd-fromto { font-size: 13px; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.bd-fromto s { color: var(--text3); font-weight: 500; }
/* A change's new value when it's a sentence (an instruction, a superset, a lighter week): its own line */
.bd-ch-to { font-size: 13px; font-weight: 600; line-height: 1.4; margin: -1px 0 4px; overflow-wrap: anywhere; }
/* Which program (and day) a program change lands on: "Push day on Push Pull Legs Upper". */
.bd-ch-where { font-size: 12px; font-weight: 600; color: var(--text2); line-height: 1.35; margin: -1px 0 4px; overflow-wrap: anywhere; }
.bd-ch p { font-size: 12.5px; color: var(--text2); line-height: 1.4; margin: 0 0 10px; }
.bd-ch-acts { display: flex; gap: 6px; align-items: center; }
.bd-alts { display: flex; flex-direction: column; gap: 6px; margin: 0 0 10px; }
.bd-alts-h { font-size: 12px; font-weight: 600; color: var(--text2); }
.bd-alt { display: flex; gap: 10px; align-items: flex-start; text-align: left; width: 100%; padding: 10px 12px; border-radius: 10px;
  border: 1.5px solid var(--border); background: var(--bg3); color: var(--text); font: inherit; cursor: pointer; }
.bd-alt i { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--text3); box-sizing: border-box; flex-shrink: 0; margin-top: 1px; }
.bd-alt.on { border-color: var(--accent); background: var(--accent-faint); }
.bd-alt.on i { border: 5px solid var(--accent); }
.bd-alt span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.bd-alt b { font-size: 13.5px; line-height: 1.3; }
.bd-alt small { font-size: 12px; color: var(--text2); line-height: 1.35; overflow-wrap: anywhere; }
.bd-alts-f { font-size: 11.5px; color: var(--text3); line-height: 1.4; }
.bd-ch-acts .btn { flex: 1; }
.bd-ch-state { font-size: 12px; font-weight: 700; color: var(--text2); margin-right: auto; }
.bd-ch-state.ok { color: var(--green); }
.bd-clamp { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.bd-clamp p { margin: 0; display: inline; }
.bd-clamp p + p::before { content: ' '; }
.bd-qs { border-top: 1px solid var(--border); margin-top: 12px; padding-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.bd-qs-hd { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.bd-qs-hd .subtitle { font-size: 12px; }
.bd-qprev { display: flex; flex-direction: column; gap: 3px; text-align: left; background: var(--bg3); border: none; border-radius: 10px; padding: 10px 12px; font: inherit; color: var(--text); cursor: pointer; }
.bd-qprev b, .bd-qprev span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 13.5px; line-height: 1.4; }
.bd-qprev span { color: var(--text2); }
.bd-sugg { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.bd-sugg::-webkit-scrollbar { display: none; }
.bd-sugg button { flex-shrink: 0; border: 1px solid var(--border); background: var(--bg2); color: var(--text); border-radius: 99px; padding: 7px 12px; font: inherit; font-size: 13px; cursor: pointer; white-space: nowrap; }
/* Conversation sheet */
.bd-chat { position: fixed; left: 0; right: 0; top: 0; height: 100%; z-index: 170; background: var(--bg); color: var(--text); display: flex; flex-direction: column; max-width: 560px; margin: 0 auto; }
.bd-chat-top { padding: max(10px, env(safe-area-inset-top)) 16px 10px; border-bottom: 1px solid var(--border); display: flex; flex-direction: column; gap: 8px; }
.bd-chat-top .bd-topbar { margin: 0; }
.bd-chat-review { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; background: var(--bg2); border: 1px solid var(--border); border-radius: 10px; padding: 7px 10px; font: inherit; font-size: 13px; color: var(--text); cursor: pointer; }
.bd-chat-review span:nth-child(2) { flex: 1; min-width: 0; }
.bd-chat-review i { font-style: normal; color: var(--text3); }
.bd-coach-av.sm { width: 24px; height: 24px; }
.bd-coach-av.sm svg { width: 14px; height: 14px; }
.bd-chat-rtext { max-height: 34vh; overflow-y: auto; font-size: 13.5px; }
.bd-chat-thread { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; padding: 12px 16px; display: flex; flex-direction: column; gap: 8px; }
.bd-chat-thread .bd-msg { font-size: 14.5px; }
.bd-clamp6 { display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.bd-more { align-self: flex-start; background: none; border: none; padding: 0 4px; margin-top: -4px; font: inherit; font-size: 13px; font-weight: 600; color: var(--accent); cursor: pointer; }
.bd-earlier { align-self: center; border: 1px solid var(--border); background: var(--bg2); color: var(--text2); border-radius: 99px; padding: 5px 12px; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.bd-faded { opacity: .5; }
.bd-when { align-self: center; font-size: 11px; font-weight: 600; color: var(--text3); margin: 4px 0 -2px; }
.bd-offtopic { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text3); }
.bd-offtopic::before, .bd-offtopic::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.bd-chat-foot { border-top: 1px solid var(--border); padding: 10px 16px max(12px, env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 8px; }
.bd-chat-foot .bd-ask { margin: 0; }
.bd-thread { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; }
.bd-msg { font-size: 13.5px; line-height: 1.45; padding: 8px 12px; border-radius: 14px; max-width: 88%; }
.bd-msg.user { align-self: flex-end; background: var(--accent-soft); }
.bd-msg.assistant { align-self: flex-start; background: var(--bg3); }
.bd-ask { display: flex; gap: 8px; align-items: center; background: var(--bg3); border: 1px solid var(--border); border-radius: 99px; padding: 4px 4px 4px 14px; margin-top: 12px; }
.bd-ask input { flex: 1; min-width: 0; border: none; background: none; padding: 6px 0; }
.bd-ask button { width: 34px; height: 34px; border-radius: 50%; border: none; background: var(--primary); color: var(--on-accent); font-size: 16px; font-weight: 700; cursor: pointer; flex-shrink: 0; }
.bd-ask button:disabled { opacity: .85; cursor: default; }
.bd-spin { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: btn-spin .7s linear infinite; vertical-align: -2px; }
/* Coach is typing: three dots that rise in turn */
.bd-typing { display: inline-flex; gap: 5px; align-items: center; padding: 12px 14px; }
.bd-typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--text2); animation: bd-dot 1.1s ease-in-out infinite; }
.bd-typing i:nth-child(2) { animation-delay: .15s; }
.bd-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes bd-dot { 0%, 60%, 100% { transform: translateY(0); opacity: .45; } 30% { transform: translateY(-4px); opacity: 1; } }
.bd-coach-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 10px; }
.bd-quota { text-align: right; margin-top: 6px; font-size: 12px; }
.bd-coach-links { display: flex; gap: 14px; flex-shrink: 0; }
.bd-coach-links .bd-link, .bd-coach-foot > .bd-link { white-space: nowrap; }
.bd-cmp-col { border-top: 1px solid var(--border); padding: 12px 0; }
.bd-cmp-col .bd-stood { margin-top: 8px; }
.bd-consent { display: flex; flex-direction: column; gap: 8px; }
.bd-consent h2 { margin: 4px 0 0; }
.bd-consent p { margin: 0; font-size: 14px; line-height: 1.45; }

/* ── Compare ── */
.bd-cmp-mode { display: grid; grid-template-columns: 36px 1fr 36px; align-items: center; justify-items: center; margin: 4px 0 10px; }
.bd-fs-btn { width: 36px; height: 32px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--card-border, var(--border)); border-width: var(--card-bw, 1px); background: var(--bg2); color: var(--text); border-radius: 8px; padding: 0; cursor: pointer; }
.bd-wipe { position: relative; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; background: var(--bg3); margin-bottom: 10px; max-width: 100%; touch-action: pan-y; cursor: ew-resize; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.bd-wipe img { pointer-events: none; -webkit-user-drag: none; }
.bd-wipe-b { will-change: clip-path; }
.bd-wipe.glide .bd-wipe-b, .bd-wipe.glide .bd-wipe-h { transition: clip-path .18s ease-out, transform .18s ease-out; }
.bd-wipe:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.bd-wipe img, .bd-wipe .bd-noimg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.bd-wipe-b { position: absolute; inset: 0; }
/* The handle is a 56 px touch strip (touch-action: none, so a drag on it never scrolls the page) with the 2 px line drawn in its middle; moved by transform. */
.bd-wipe-h { position: absolute; top: 0; bottom: 0; left: -28px; width: 56px; touch-action: none; will-change: transform; background: linear-gradient(var(--fuel-scan-fg), var(--fuel-scan-fg)) center / 2px 100% no-repeat; }
.bd-wipe-h::after { content: '‹ ›'; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; border-radius: 50%; background: var(--fuel-scan-fg); color: var(--fuel-scan-bg); font-size: 15px; font-weight: 700; line-height: 40px; text-align: center; white-space: nowrap; transition: transform .12s ease-out; }
.bd-wipe.drag .bd-wipe-h::after { transform: translate(-50%, -50%) scale(1.12); }
.bd-wipe em, .bd-side em { position: absolute; top: 10px; font-style: normal; font-size: 11px; font-weight: 700; color: var(--fuel-scan-fg); background: var(--fuel-scan-scrim); padding: 3px 8px; border-radius: 99px; pointer-events: none; }
.bd-wipe em.l, .bd-side em.l { left: 10px; }
.bd-wipe em.r { right: 10px; }
.bd-noimg { display: flex; align-items: center; justify-content: center; color: var(--text3); font-size: 13px; background: var(--bg3); }
.bd-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; margin-bottom: 10px; }
.bd-side > div { position: relative; aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; background: var(--bg3); }
.bd-side img, .bd-side .bd-noimg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.bd-weeks { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-bottom: 12px; padding-bottom: 2px; }
.bd-weeks::-webkit-scrollbar { display: none; }
.bd-weeks { position: relative; }
.bd-weeks button { flex: 1 0 52px; border: 1px solid var(--border); background: var(--bg2); color: var(--text2); border-radius: 8px; padding: 6px 0 5px; font: inherit; font-size: 12px; font-weight: 600; line-height: 1.2; cursor: pointer; }
.bd-weeks button small { display: block; font-size: 10px; font-weight: 500; opacity: .8; white-space: nowrap; }
.bd-weeks button.a { border-color: var(--text2); color: var(--text); }
.bd-weeks button.b { border-color: var(--accent); color: var(--accent); background: var(--accent-faint); }
.bd-weeks button { position: relative; }
.bd-weeks button.none { opacity: .5; }
.bd-weeks button i, .bd-sp-strip .bd-th i { position: absolute; top: -1px; left: -1px; font-style: normal; font-size: 9px; font-weight: 800; line-height: 1; padding: 2px 4px; border-radius: 7px 0 6px 0; background: var(--text2); color: var(--bg2); }
.bd-weeks button.b i, .bd-sp-strip .bd-th.sr i { background: var(--accent); color: var(--bg2); }
.bd-sp-strip .bd-th i { top: 0; left: 0; z-index: 1; font-size: 10px; padding: 3px 5px; border-radius: 0 0 6px 0; }
.bd-sp-strip .bd-th.sel.sl { outline-color: var(--text2); }
/* Left / Right: which side the week chips set. */
.bd-cmp-sides { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 8px; }
.bd-cmp-sides button { text-align: left; border: 1px solid var(--card-border, var(--border)); border-width: var(--card-bw, 1px); background: var(--bg2); color: var(--text); border-radius: 10px; padding: 7px 10px; font: inherit; cursor: pointer; min-width: 0; }
.bd-cmp-sides button small { display: block; font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--text3); }
.bd-cmp-sides button b { display: block; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bd-cmp-sides button.on.a { border-color: var(--text2); box-shadow: inset 0 0 0 1px var(--text2); }
.bd-cmp-sides button.on.b { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); background: var(--accent-faint); }
.bd-cmp-sides button.on small { color: inherit; }
.bd-cmp-sides button.b.on small { color: var(--accent); }
.bd-sp .bd-cmp-sides, .card > .bd-cmp-sides { margin: 0 0 10px; }
.bd-diff-hd td { font-size: 11px; font-weight: 700 !important; color: var(--text3) !important; padding-top: 0 !important; }

/* ── Full screen compare: dark in every theme like the camera; the line never scales with the zoom. ── */
.bd-fs { position: fixed; inset: 0; z-index: 170; background: var(--fuel-scan-bg); overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; overscroll-behavior: contain; }
.bd-fs-layer { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.bd-fs-b { will-change: clip-path; }
.bd-fs-pic { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; }
.bd-fs-pic img, .bd-fs-pic .bd-noimg { width: 100%; height: 100%; object-fit: cover; display: block; -webkit-user-drag: none; }
.bd-fs.glide .bd-fs-pic { transition: transform .2s ease-out; }
.bd-fs-h { position: absolute; top: 0; bottom: 0; left: -1px; width: 2px; background: var(--fuel-scan-fg); pointer-events: none; will-change: transform; }
.bd-fs-h::after { content: '‹ ›'; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 44px; height: 44px; border-radius: 50%; background: var(--fuel-scan-fg); color: var(--fuel-scan-bg); font-size: 16px; font-weight: 700; line-height: 44px; text-align: center; white-space: nowrap; transition: transform .12s ease-out; }
.bd-fs.drag .bd-fs-h::after { transform: translate(-50%, -50%) scale(1.12); }
.bd-fs em { position: absolute; bottom: 16px; font-style: normal; font-size: 12px; font-weight: 700; color: var(--fuel-scan-fg); background: var(--fuel-scan-scrim); padding: 4px 10px; border-radius: 99px; pointer-events: none; }
.bd-fs em.l { left: 12px; }
.bd-fs em.r { right: 12px; }
.bd-fs-zoom { position: absolute; top: 18px; left: 50%; transform: translateX(-50%); font-size: 12px; font-weight: 700; color: var(--fuel-scan-fg); background: var(--fuel-scan-scrim); padding: 4px 10px; border-radius: 99px; pointer-events: none; }
.bd-fs-zoom[hidden] { display: none; }
.bd-fs-x { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; border-radius: 50%; border: none; background: var(--fuel-scan-scrim); color: var(--fuel-scan-fg); font-size: 18px; font-weight: 700; cursor: pointer; z-index: 2; }
.bd-diff { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.bd-diff td { padding: 8px 0 8px 8px; border-bottom: 1px solid var(--border); text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.bd-diff tr:last-child td { border-bottom: none; }
.bd-diff td:first-child { text-align: left; color: var(--text2); padding-left: 0; white-space: normal; }
.bd-diff td:last-child { font-weight: 700; }

/* ── Settings sheet ── */
.bd-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.bd-form .input-group input { width: 100%; }
.bd-sw-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--border); cursor: pointer; }
.bd-sw-row b { display: block; font-size: 14px; font-weight: 600; }
.bd-sw-row small { display: block; font-size: 12px; color: var(--text2); margin-top: 2px; }
.modal select { width: 100%; }

/* ── Goals beyond weight (v31) ── */
.bd-main { display: inline-flex; vertical-align: 2px; margin-left: 6px; font-size: 10px; font-weight: 700; letter-spacing: .3px; text-transform: uppercase; padding: 2px 6px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); }
.bd-pace.mid { background: var(--pr-bg); color: var(--pr-text); }
.bd-addgoal { width: 100%; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left; background: var(--bg2); border: var(--card-bw, 1px) dashed var(--card-border, var(--border)); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 12px; font: inherit; color: var(--text2); cursor: pointer; }
.bd-addgoal b { color: var(--accent); font-size: 14px; }
.bd-addgoal span { font-size: 12px; }
.bd-goals { padding: 10px 12px 12px; }
.bd-goals-hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.bd-goals-hd span { font-size: 11px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--text2); }
.bd-goals-hd button { background: none; border: 0; padding: 6px 0 6px 12px; font: inherit; font-size: 13px; font-weight: 600; color: var(--accent); cursor: pointer; }
.bd-gtiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.bd-gtile { display: flex; flex-direction: column; gap: 5px; min-width: 0; text-align: left; background: var(--bg2); border: var(--card-bw, 1px) solid var(--card-border, var(--border)); box-shadow: var(--card-shadow); border-radius: var(--radius); padding: 11px 12px; font: inherit; color: var(--text); cursor: pointer; }
.bd-goals .bd-gtile { background: var(--bg3); border: 0; box-shadow: none; border-radius: 12px; }
.bd-goals .bd-gtile.add { align-items: center; justify-content: center; background: none; border: 1px dashed var(--border); color: var(--accent); }
.bd-gtile-t { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.bd-gtile-t b { font-size: 13.5px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-gtile-s { font-size: 12px; color: var(--text2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bd-gdot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; background: var(--text3); }
.bd-gdot.ok { background: var(--green); } .bd-gdot.mid { background: var(--pr-text); } .bd-gdot.warn { background: var(--red); }
.bd-gbar { display: block; height: 4px; border-radius: 2px; background: var(--bg3); overflow: hidden; }
.bd-gbar i { display: block; height: 100%; border-radius: 2px; }
.bd-topbar .bd-topbar-add { color: var(--accent) !important; }
.bd-glist { padding-block: 4px; }
.bd-gfoot { border-top: 1px solid var(--border); padding: 10px 0 6px; font-size: 12px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.bd-gfoot .bd-link { font-size: 12.5px; white-space: nowrap; }
.bd-grow { display: flex; align-items: center; border-top: 1px solid var(--border); }
#bd-gdrag .bd-grow:first-child, #bd-glist-rows .bd-grow:first-child { border-top: 0; }
.bd-grow-w + #bd-gdrag .bd-grow:first-child, .bd-grow-w + #bd-glist-rows .bd-grow:first-child { border-top: 1px solid var(--border); }
/* A goal row's coach line: two lines at most (the goal page has all of it). */
.bd-grow .bd-cline.sm > span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bd-grow-b { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 12px 0; background: none; border: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.bd-gic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.bd-grow-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.bd-grow-h { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.bd-grow-h b { font-size: 14.5px; margin-right: auto; }
.bd-grow-h .bd-main { margin-left: 0; }
.bd-sigs { display: flex; flex-wrap: wrap; gap: 5px; }
.bd-sigs i { font-style: normal; font-size: 12px; padding: 2px 8px; border-radius: 99px; background: var(--bg3); color: var(--text2); }
.bd-sigs i.ok { background: var(--green-soft); color: var(--green); }
.bd-gpicks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.bd-gpick { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-width: 0; text-align: left; background: var(--bg3); border: 1px solid var(--border); border-radius: 12px; padding: 12px; font: inherit; color: var(--text); cursor: pointer; }
.bd-gpick .bd-gic { width: 32px; height: 32px; margin-bottom: 2px; }
.bd-gpick b { font-size: 14px; }
.bd-gpick span:last-child { font-size: 12px; color: var(--text2); }
.bd-gpick:disabled { opacity: .5; cursor: default; }
.bd-gfocus { width: 100%; margin-top: 10px; background: none; border: 1px dashed var(--border); border-radius: 12px; padding: 12px; font: inherit; font-size: 13px; color: var(--text2); text-align: left; cursor: pointer; }
.bd-gfocus b { color: var(--text); font-weight: 600; }
.bd-ghead { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.bd-ghead h2 { margin: 0; font-size: 19px; }
.bd-flabel { display: block; font-size: 12px; font-weight: 600; color: var(--text2); margin-bottom: 6px; }
.bd-gmeasure { display: flex; width: 100%; }
.bd-gmeasure button { flex: 1; }
.bd-stepper { display: flex; align-items: center; gap: 8px; }
.bd-stepper button { width: 44px; height: 40px; border-radius: 10px; border: 1px solid var(--border); background: var(--bg3); color: var(--text); font: inherit; font-size: 20px; cursor: pointer; }
.bd-stepper output { flex: 1; text-align: center; font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; }
.bd-gnow { display: flex; flex-direction: column; gap: 6px; background: var(--bg3); }
.bd-gnow-row { display: flex; align-items: baseline; justify-content: space-between; }
.bd-gnow-row b { font-size: 20px; font-variant-numeric: tabular-nums; }
.bd-gwait { border-style: dashed; background: none; }
.bd-gwait b { font-size: 14px; }
.bd-gweeks { display: flex; gap: 4px; }
.bd-gweeks span { flex: 1; text-align: center; font-size: 12px; font-weight: 600; padding: 5px 0; border-radius: 6px; background: var(--bg4); color: var(--text2); font-variant-numeric: tabular-nums; }
.bd-gweeks span.hit { background: var(--green-soft); color: var(--green); }
.bd-gweeks span.now { background: none; box-shadow: inset 0 0 0 1.5px var(--accent); color: var(--text); }
.bd-gmass { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.bd-gmass .card { display: flex; flex-direction: column; gap: 2px; }
.bd-gmass b { font-size: 17px; }
.bd-gmass span:last-child:not(.subtitle) { font-size: 12px; color: var(--text2); }
.bd-gmass span.bd-good { color: var(--green); }
.bd-gnow .bd-sigs i:not(.ok) { background: var(--bg4); }
.bd-wi-bf .bd-wi input::placeholder { font-size: 17px; font-weight: 500; }
.bd-wi-bf .bd-wi > span { min-width: 20px; }
.bd-wi > span { min-width: 20px; }
.bd-bfrows .bd-wi-row:first-child { border-top: 0; }
.bd-wi-row em { font-style: normal; font-size: 13px; color: var(--text2); min-width: 56px; text-align: right; }
.bd-wi-row em.other { color: var(--pr-text); }
.bd-chart .ring { fill: none; stroke: var(--pr-text); stroke-width: 2; }
.bd-legend i.ring { width: 8px; height: 8px; border-radius: 50%; background: none; box-shadow: inset 0 0 0 2px var(--pr-text); }
.bd-wi-bf { margin-top: 10px; display: flex; flex-direction: column; gap: 8px; }
.bd-wi-bf .bd-wi > span small { font-size: 11px; font-weight: 500; color: var(--text3); }
.bd-wi-methods { display: flex; flex-wrap: wrap; gap: 6px; }
.bd-wi-methods button { border: 1px solid var(--border); background: var(--bg3); color: var(--text2); border-radius: 99px; padding: 7px 12px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.bd-wi-methods button.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.bd-wi-day { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; font-size: 13px; color: var(--text2); }
.bd-wi-day label { position: relative; font-weight: 600; cursor: pointer; }
.bd-wi-day input { position: absolute; inset: 0; opacity: 0; width: 100%; cursor: pointer; }

@media (prefers-reduced-motion: reduce) { .bd-flash.go, .bd-typing i, .bd-spin { animation: none; } .bd-fold-ic svg { transition: none; } }

/* ── Coach × goals (v32): goal check, scorecard, a coach line per goal ── */
.bd-cline { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; line-height: 1.4; color: var(--text2); background: var(--bg3); border-radius: 10px; padding: 8px 10px; }
.bd-cline svg { width: 15px; height: 15px; flex-shrink: 0; margin-top: 1px; color: var(--accent); }
.bd-cline b { color: var(--text); font-weight: 600; }
.bd-cline.sm { font-size: 12px; padding: 6px 8px; margin-top: 2px; }
.bd-cline.sm svg { width: 13px; height: 13px; }
.bd-gcoach { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.bd-gcoach .bd-ch { margin-bottom: 0; }
.bd-askgoal { display: flex; align-items: center; gap: 8px; width: 100%; border: 1px solid var(--border); border-radius: 99px; background: var(--bg2); padding: 9px 14px; font: inherit; font-size: 13px; color: var(--text2); cursor: pointer; text-align: left; }
.bd-askgoal svg { width: 15px; height: 15px; color: var(--accent); flex-shrink: 0; }
.bd-nudge { display: flex; align-items: center; gap: 10px; width: 100%; margin-bottom: 12px; text-align: left; background: var(--bg2); border: var(--card-bw, 1px) solid var(--card-border, var(--border)); box-shadow: var(--card-shadow); border-radius: var(--radius); padding: 10px 12px; font: inherit; font-size: 13px; line-height: 1.4; color: var(--text2); cursor: pointer; }
.bd-nudge svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--accent); }
.bd-nudge b { color: var(--text); font-weight: 600; }
.bd-nudge > span { flex: 1; min-width: 0; }
.bd-nudge > i { font-style: normal; color: var(--text3); }
.bd-gc-btns { display: flex; gap: 8px; }
.bd-gc-btns .btn { flex: 1; }
.bd-verdicts { display: flex; flex-direction: column; gap: 0; }
.bd-verdicts > .bd-cline { margin-bottom: 4px; }
.bd-verdict { display: flex; flex-direction: column; gap: 6px; padding: 12px 0; border-top: 1px solid var(--border); }
.bd-verdicts > .bd-cline + .bd-verdict, .bd-verdicts > .bd-verdict:first-child { border-top: 0; }
.bd-verdict.gone { opacity: .55; }
.bd-verdict-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.bd-verdict-h b { font-size: 14px; min-width: 0; }
.bd-verdict-h .bd-pace { flex-shrink: 0; }
.bd-verdict p { margin: 0; font-size: 13px; line-height: 1.4; color: var(--text2); }
.bd-fix { display: flex; align-items: center; justify-content: space-between; gap: 8px; background: var(--bg3); border-radius: 10px; padding: 8px 8px 8px 12px; font-size: 13px; }
.bd-fix > span:first-child { flex: 1; min-width: 0; font-weight: 600; }
.bd-fix.applied { background: var(--green-faint); }
.bd-fix.applied .bd-ch-state { margin-right: 0; }
.bd-stale { font-size: 12.5px; font-weight: 600; color: var(--pr-text); background: var(--pr-bg); border-radius: 8px; padding: 6px 10px; margin-bottom: 8px; }
.bd-focus textarea, .modal textarea#bd-cg-focus { width: 100%; resize: none; font: inherit; font-size: 14px; color: var(--text); background: var(--bg3); border: 1px solid var(--border); border-radius: var(--radius-sm, 10px); padding: 9px 11px; outline: none; }
.bd-focus textarea:focus, .modal textarea#bd-cg-focus:focus { border-color: var(--accent); }
.bd-focus .bd-lbl { display: block; }
.bd-gsum { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: var(--bg3); border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; font: inherit; color: var(--text); cursor: pointer; }
.bd-gsum-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.bd-gsum-t b { font-size: 14px; }
.bd-gsum > i { font-style: normal; color: var(--text3); font-size: 18px; }
.bd-steps { display: flex; gap: 5px; margin-bottom: 14px; }
.bd-steps i { flex: 1; height: 4px; border-radius: 4px; background: var(--bg4); }
.bd-steps i.on { background: var(--accent); }
.bd-cg-list { padding-block: 2px; margin-bottom: 6px; }
.bd-cg-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--border); }
.bd-cg-row:first-child { border-top: 0; }
.bd-cg-row b { font-size: 14px; }
.bd-cg-row .bd-gic { width: 32px; height: 32px; }
.bd-score { display: flex; flex-direction: column; margin: 2px 0 4px; }
.bd-score-r { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 3px 8px; align-items: center; padding: 9px 0; border-top: 1px solid var(--border); }
.bd-score-r:first-child { border-top: 0; padding-top: 0; }
.bd-score-r b { font-size: 13.5px; min-width: 0; }
.bd-score-r p { grid-column: 1 / -1; margin: 0; font-size: 12.5px; line-height: 1.4; color: var(--text2); }
.bd-ch-for { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }

/* ── Check-in: photos are an optional tile on the numbers page ── */
.bd-fphotos { width: 100%; display: flex; align-items: center; gap: 12px; text-align: left; font: inherit; color: inherit; cursor: pointer; border-style: dashed; }
.bd-fp-ic { width: 44px; height: 56px; border-radius: 8px; background: var(--bg3); color: var(--text3); display: grid; place-items: center; flex-shrink: 0; }
.bd-fp-ths { display: flex; gap: 4px; flex-shrink: 0; }
.bd-fp-th { position: relative; width: 36px; aspect-ratio: 3 / 4; border-radius: 6px; overflow: hidden; background: var(--bg3); }
.bd-fp-th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bd-fp-th em { position: absolute; left: 0; right: 0; bottom: 0; font-style: normal; font-size: 8px; font-weight: 700; text-align: center; color: var(--fuel-scan-fg); background: var(--fuel-scan-scrim); }
.bd-fp-t { flex: 1; min-width: 0; display: grid; gap: 2px; }
.bd-fp-t b { font-size: 14px; }

/* ── Weekly review: whether a change is inside your limits ── */
.bd-ch-for { display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.bd-scope { font-size: 10px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; padding: 2px 6px; border-radius: 5px; margin-left: auto; }
.bd-scope.ask { background: var(--accent-soft); color: var(--accent); }
.bd-scope.in { background: var(--green-soft); color: var(--green); }

/* ── Body › Photos over a span ── */
.bd-spans { display: flex; margin: 6px 0 8px; }
.bd-spans button { flex: 1; }
.bd-sp-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.bd-sp-pair:has(> :only-child) { grid-template-columns: minmax(0, 60%); justify-content: center; }
.bd-sp-fig { margin: 0; display: grid; gap: 4px; min-width: 0; }
.bd-sp-fig .bd-ph { border: none; padding: 0; width: 100%; cursor: pointer; display: grid; place-items: center; color: var(--text3); font: inherit; font-size: 12px; }
.bd-sp-fig figcaption { font-size: 12px; color: var(--text2); text-align: center; }
.bd-sp-fig figcaption b { color: var(--text); }
.bd-sp-d { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 6px; margin-top: 10px; }
.bd-sp-d div { background: var(--bg3); border-radius: 9px; padding: 6px 8px; display: grid; gap: 1px; }
.bd-sp-d small { font-size: 11px; color: var(--text2); font-weight: 600; }
.bd-sp-d b { font-size: 15px; font-variant-numeric: tabular-nums; }
.bd-sp-strip .bd-th.sel { outline: 2px solid var(--accent); outline-offset: 1px; }
.bd-sp-strip span.bd-th { cursor: default; }

/* ── Goals: Add a goal as the list's last row ── */
.bd-gaddrow { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 0; border: 0; border-top: 1px solid var(--border); background: none; font: inherit; font-size: 14px; font-weight: 700; color: var(--accent); cursor: pointer; text-align: left; }
.bd-gaddrow span { width: 36px; height: 36px; border-radius: 10px; border: 1.5px dashed var(--accent); display: grid; place-items: center; font-size: 19px; font-weight: 600; flex-shrink: 0; }

/* ── One goal page for every goal ── */
.bd-gp-hd { display: flex; gap: 12px; align-items: center; margin: 4px 0 12px; }
.bd-gp-hd .bd-gic { width: 44px; height: 44px; border-radius: 12px; }
.bd-gp-pills .bd-main { margin-left: 0; vertical-align: 0; }
.bd-gp-pills { display: flex; gap: 6px; align-items: center; margin-top: 4px; min-height: 18px; }
.bd-gp-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.bd-gp-coach { display: grid; gap: 10px; }
.bd-gp-coach > #bd-g-coach:empty { display: none; }
.bd-gp-coach .co-planlink, .bd-gp-coach .bd-gcoach { margin-bottom: 0; }
/* Edit goal sits on the page background: card fill + outline so scene themes don't show through. */
.btn.bd-gp-edit { background: var(--bg2); border: var(--card-bw, 1px) solid var(--card-border, var(--border)); box-shadow: var(--card-shadow); margin-bottom: 12px; }
.bd-sigrows { margin-top: 10px; }
.bd-sigrow { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--border); font-size: 13.5px; }

/* ── What the coach needs ── */
.bd-prog { display: flex; gap: 4px; }
.bd-prog i { flex: 1; height: 5px; border-radius: 4px; background: var(--bg3); }
.bd-prog i.y { background: var(--green); }
.bd-needs { display: grid; margin-top: 4px; }
.bd-need { display: flex; gap: 10px; align-items: flex-start; padding: 9px 0; border-top: 1px solid var(--border); }
.bd-need:first-child { border-top: 0; }
.bd-verdict .bd-needs { margin-top: 6px; border-top: 1px solid var(--border); }
.bd-ck { width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; font-size: 11px; font-weight: 800; border: 1.5px solid var(--border); color: transparent; margin-top: 1px; }
.bd-ck.y { background: var(--green); border-color: var(--green); color: var(--on-accent); }
.bd-need-t { flex: 1; min-width: 0; display: grid; gap: 1px; }
.bd-need-t b { font-size: 13.5px; }
.bd-need-t span { font-size: 12px; color: var(--text2); }
.bd-need .bd-link { white-space: nowrap; margin-top: 1px; }
.bd-next-step { margin: 10px 0 2px; }
.bd-ready .bd-hd span { font-variant-numeric: tabular-nums; }

/* ── The goal editor sheet (every goal) ── */
.bd-es-hd { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 12px; }
.bd-es-hd b { display: block; font-size: 19px; font-weight: 800; letter-spacing: -.2px; }
.bd-es-hd span { font-size: 12.5px; color: var(--text2); }
.bd-es-x { width: 30px; height: 30px; border-radius: 50%; border: 0; background: var(--bg3); color: var(--text2); font: inherit; font-size: 13px; cursor: pointer; flex-shrink: 0; }
.bd-es-group { background: var(--bg2); border: 1px solid var(--border); border-radius: 14px; padding: 0 12px; margin-bottom: 12px; }
.bd-es-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--border); font-size: 14px; min-height: 52px; }
.bd-es-group > .bd-es-row:first-child, .bd-es-group > div:first-child > .bd-es-row { border-top: 0; }
.bd-es-row > span { color: var(--text2); }
.bd-es-row small { display: block; font-size: 11.5px; color: var(--text3); font-weight: 500; }
.bd-es-sw { cursor: pointer; }
.bd-es-sw b { color: var(--text); font-size: 14px; font-weight: 600; }
.bd-es-step { display: flex; align-items: center; gap: 6px; }
.bd-es-step button { width: 34px; height: 34px; border-radius: 10px; border: 0; background: var(--bg3); color: var(--text); font: inherit; font-size: 19px; font-weight: 600; cursor: pointer; flex-shrink: 0; }
.bd-es-step input { width: 64px; text-align: right; font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; border: 0; background: none; padding: 4px 0; color: var(--text); }
.bd-es-step small { min-width: 22px; font-size: 12.5px; color: var(--text2); font-weight: 600; }
.bd-es-date { width: auto; max-width: 170px; border: 0; background: none; color: var(--accent); font-weight: 600; text-align: right; padding: 4px 0; }
.bd-es-chips { display: flex; gap: 6px; padding: 0 0 12px; }
.bd-es-chips button { flex: 1; border: 0; border-radius: 99px; padding: 7px 0; background: var(--bg3); color: var(--text2); font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.bd-es-chips button.on { background: var(--accent-soft); color: var(--accent); }
.bd-es-group .seg-sm { flex-shrink: 0; }
.bd-es-note { margin: -4px 2px 12px; }
.bd-es-remove { display: block; width: 100%; margin-top: 10px; border: 0; background: none; color: var(--red); font: inherit; font-size: 14px; font-weight: 600; padding: 8px; cursor: pointer; }
#bd-g-pace .co-pace { margin-bottom: 12px; }
.bd-es-pick { margin-bottom: 12px; }
.bd-es-pick input { width: 100%; }
.bd-es-recent { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; }
.bd-es-recent span { font-size: 11px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; color: var(--text3); width: 100%; }
.bd-es-recent button { border: 1px solid var(--border); background: var(--bg2); color: var(--text2); border-radius: 99px; padding: 5px 10px; font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.autocomplete-item b { color: var(--accent); }

/* Pinch to zoom a large photo (_bodyPinch in body.js): the lifted copy + a dim page behind it. */
.bd-zoom { position: fixed; z-index: 300; object-fit: cover; border-radius: 10px; pointer-events: none; will-change: transform; }
.bd-zoom.out { transition: transform .22s ease-out; }
.bd-zoom-back { position: fixed; inset: 0; z-index: 299; background: var(--backdrop); opacity: 0; pointer-events: none; }
.bd-zoom-back.out { transition: opacity .22s ease-out; }
