/* sweatsheet coach dashboard — same mat-it tokens as the app, desktop-first layout */

:root {
  /* Colours shared with the app: shared/tokens.css. Only the dashboard's own below. */
  --text-2: #3d3c5c;
  --good: #11845b;
  --good-soft: #e3f5ec;
  --warn: #a35a00;
  --warn-soft: #fff1dc;
  --radius: 18px;
  --radius-sm: 12px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --text-2: #c9c8e4;
    --good: #4ade9b;
    --good-soft: #12301f;
    --warn: #ffb44d;
    --warn-soft: #3a2a10;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.45 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", Roboto, sans-serif;
  font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
button:disabled { opacity: .4; cursor: default; }
a { color: var(--accent); }
h1, h2, h3, p { margin: 0; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }

/* ---------- frame ---------- */
.topbar {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 12px max(16px, calc((100vw - 1240px) / 2));
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--brand-navy); font-weight: 800; font-size: 17px; letter-spacing: -.02em; }
.brand b { color: var(--accent); }
.who { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--muted); }
.main { max-width: 1240px; margin: 0 auto; padding: 24px 16px 64px; display: flex; flex-direction: column; gap: 20px; }
.plan-bar { padding: 9px max(16px, calc((100vw - 1240px) / 2)); background: var(--accent-soft); color: var(--text); font-size: 13px; text-align: center; }
.plan-bar a { font-weight: 600; }
.plan-bar.warn { background: var(--warn-soft); color: var(--warn); }
.plan-bar.warn a { color: inherit; }
.access-ended { display: flex; flex-direction: column; gap: 14px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.page-head h1 { font-size: 28px; letter-spacing: -.02em; }
.page-head p { margin-top: 4px; }
.card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; }
.card h2 { font-size: 16px; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.grid { display: grid; gap: 16px; }
.cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 1100px) { .cols-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px) { .cols-5, .cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cols-3, .cols-2 { grid-template-columns: 1fr; } }

/* ---------- controls ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 999px; background: var(--surface-2); font-weight: 600; font-size: 14px; white-space: nowrap; text-decoration: none; }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.ghost { background: transparent; color: var(--muted); }
.btn.danger { background: transparent; color: var(--danger); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; }
.btn.block { width: 100%; }
.seg { display: inline-grid; grid-auto-flow: column; background: var(--surface-2); border-radius: 12px; padding: 3px; gap: 3px; }
.seg button, .seg a { height: 32px; padding: 0 14px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--muted); }
.seg a { display: inline-flex; align-items: center; text-decoration: none; }
.seg button.on, .seg a.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgb(0 0 0 / .08); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field span { font-size: 13px; font-weight: 600; color: var(--muted); }
.input { height: 44px; width: 100%; padding: 0 14px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface); outline: none; }
.input:focus { border-color: var(--accent); }
.form { display: flex; flex-direction: column; gap: 14px; }

/* ---------- auth ---------- */
.auth { max-width: 420px; margin: 6vh auto 0; display: flex; flex-direction: column; gap: 18px; }
.auth h1 { font-size: 24px; letter-spacing: -.02em; }
.link-btn { align-self: center; font-size: 13px; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.notice { padding: 14px 16px; border-radius: var(--radius-sm); background: var(--warn-soft); color: var(--warn); font-size: 14px; }

/* ---------- stat tiles ---------- */
.tile { display: flex; flex-direction: column; gap: 4px; }
.tile .lbl { font-size: 13px; color: var(--muted); font-weight: 600; }
.tile .val { font-size: 30px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; }
.tile .val small { font-size: 14px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.tile .sub { font-size: 13px; color: var(--muted); }

/* ---------- clients table ---------- */
.table-wrap { overflow-x: auto; margin: 0 -20px -20px; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th:first-child, td:first-child { padding-left: 20px; }
th:last-child, td:last-child { padding-right: 20px; }
tr:last-child td { border-bottom: 0; }
tbody tr.link { cursor: pointer; transition: background .12s; }
tbody tr.link:hover { background: var(--surface-2); }
.num { text-align: right; white-space: nowrap; }
.name strong { display: block; }
.name span { font-size: 13px; color: var(--muted); }
/* The clients overview: a little less room between columns, so all of them fit at 1440 px. */
.clients-table :is(th, td) { padding-left: 12px; padding-right: 12px; }
.clients-table :is(th, td):first-child { padding-left: 20px; }
.clients-table :is(th, td):last-child { padding-right: 20px; }
.meter { display: flex; align-items: center; gap: 8px; justify-content: flex-end; }
.meter .bar { width: 48px; height: 6px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.meter .bar i { display: block; height: 100%; border-radius: inherit; background: var(--c, var(--accent)); }

.flags { display: flex; flex-wrap: wrap; gap: 6px; }
.flag { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: 99px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.flag svg { width: 13px; height: 13px; stroke-width: 2.5; }
.flag.good { background: var(--good-soft); color: var(--good); }
.flag.warn { background: var(--warn-soft); color: var(--warn); }

.invite-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); flex-wrap: wrap; }
.invite-row:first-of-type { border-top: 0; }
.invite-row .row-actions { display: flex; gap: 8px; }
.code { font: 700 16px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .12em; }
.empty { text-align: center; padding: 36px 16px; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 12px; }

/* ---------- client detail ---------- */
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 600; }
.chart { position: relative; height: 170px; display: flex; align-items: stretch; gap: 4px; padding-top: 6px; }
.chart.dense { gap: 2px; }
.chart .col { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; cursor: default; }
.chart .bw { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center; border-radius: 6px; }
.chart .col:hover .bw { background: var(--surface-2); }
.chart .b { width: 100%; max-width: 28px; min-height: 2px; border-radius: 4px 4px 0 0; background: var(--c); }
.chart .b.zero { background: var(--line); }
.chart .d { font-size: 11px; color: var(--muted); height: 14px; white-space: nowrap; }
.chart .goal { position: absolute; left: 0; right: 0; border-top: 1.5px dashed var(--muted); opacity: .5; pointer-events: none; }
.chart .goal span { position: absolute; right: 0; top: -17px; font-size: 11px; color: var(--muted); background: var(--surface); padding-left: 4px; }
.c-kcal { --c: var(--accent); }
.c-protein { --c: var(--protein); }
.c-steps { --c: var(--steps); }
.c-water { --c: var(--water); }
.c-sleep { --c: #6366f1; }


.day { border-top: 1px solid var(--line); }
.day:first-child { border-top: 0; }
.day-head { width: 100%; display: grid; grid-template-columns: 150px 1fr auto auto; gap: 14px; align-items: center; padding: 12px 0; text-align: left; }
.day-head .chev { transition: rotate .15s; color: var(--muted); }
.day.open .day-head .chev { rotate: 90deg; }
.day-body { padding: 0 0 16px 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.meal h4, .wk h4 { margin: 0 0 6px; font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.meal ul, .wk ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; font-size: 14px; }
.meal li, .wk li { display: flex; justify-content: space-between; gap: 12px; }
.meal li span:last-child, .wk li span:last-child { color: var(--muted); white-space: nowrap; }
.comment { font-style: italic; color: var(--text-2); font-size: 13px; }
.macro-line { font-size: 13px; color: var(--muted); }
.day-checkin { grid-column: 1 / -1; }
.day-checkin p + p { margin-top: 4px; }
.routine { padding: 10px 0; border-top: 1px solid var(--line); }
.routine:first-of-type { border-top: 0; }

/* ---------- dialog, tooltip, toast ---------- */
dialog { border: 0; border-radius: 22px; padding: 24px; width: min(460px, calc(100vw - 32px)); background: var(--bg); color: var(--text); box-shadow: 0 20px 60px rgb(0 0 0 / .25); }
dialog::backdrop { background: rgb(0 0 0 / .35); }
.dialog-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.big-code { font: 700 34px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .2em; text-align: center; padding: 18px; border-radius: var(--radius-sm); background: var(--surface); }
.share-row { display: flex; gap: 8px; flex-wrap: wrap; }
.tooltip { position: fixed; z-index: 30; pointer-events: none; background: var(--text); color: var(--bg); padding: 8px 10px; border-radius: 10px; font-size: 13px; line-height: 1.35; white-space: nowrap; box-shadow: 0 6px 20px rgb(0 0 0 / .2); }
.tooltip b { font-weight: 700; }
.toast { position: fixed; left: 50%; bottom: 24px; translate: -50% 20px; opacity: 0; pointer-events: none; background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 999px; font-size: 14px; font-weight: 600; transition: all .25s; z-index: 40; }
.toast.show { translate: -50% 0; opacity: 1; }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 2.5px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; margin: 40px auto; }
@keyframes spin { to { rotate: 360deg; } }
.live { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--good); }

@media (max-width: 640px) {
  .day-head { grid-template-columns: 1fr auto; }
  .day-head .macro-line { grid-column: 1 / -1; order: 3; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }

/* push program */
dialog.wide { width: min(760px, calc(100vw - 32px)); }
.pick { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.check { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }
.flag.wait { background: var(--surface-2); color: var(--muted); }
button.link, a.link { color: var(--accent); text-decoration: underline; }
button.link { font-size: inherit; }

/* ---------- navigation ---------- */
.nav { display: flex; gap: 4px; margin-right: 8px; }
.nav a { padding: 6px 12px; border-radius: 999px; text-decoration: none; color: var(--muted); font-weight: 600; font-size: 14px; }
.nav a.on { background: var(--accent-soft); color: var(--accent); }

/* ---------- program library ---------- */
.program-card { display: flex; flex-direction: column; gap: 12px; }
.program-card h2 { font-size: 17px; }
.routine-names { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.routine-names li { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pick-list { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow: auto; }
.pick-item { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; }
.pick-item input { margin-top: 3px; accent-color: var(--accent); }

/* ---------- builder ---------- */
.builder-head { align-items: center; flex-wrap: wrap; gap: 10px; }
.title-input { font-size: 22px; font-weight: 700; height: 52px; flex: 1 1 320px; max-width: 520px; }
.weeks-pick { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); font-weight: 600; }
.weeks-pick select { width: auto; height: 40px; }
.routine-edit { display: flex; flex-direction: column; gap: 12px; }
.routine-head { display: flex; align-items: center; gap: 8px; }
.routine-name { font-size: 17px; font-weight: 700; max-width: 360px; }
.routine-edit .table-wrap { margin: 0 -20px; }
.ex-table th { padding: 8px 6px; }
.ex-table td { padding: 4px 6px; border-bottom: 0; }
.ex-table th:first-child, .ex-table td:first-child { padding-left: 14px; }
.ex-table .input { height: 36px; padding: 0 10px; font-size: 14px; min-width: 0; }
.ex-table td:nth-child(3), .ex-table td:nth-child(4) { width: 72px; }
.ex-table td:nth-child(5), .ex-table td:nth-child(6), .ex-table td:nth-child(7) { width: 84px; }
.ex-table tr.ex-sub td { padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.ex-table tr.ex-main.is-ss td:first-child { box-shadow: inset 3px 0 0 var(--train); }
.ex-table tr.ex-main.is-ss + tr.ex-sub td:first-child { box-shadow: inset 3px 0 0 var(--train); }
.name-cell { display: flex; gap: 6px; min-width: 260px; }
.name-cell .input:first-child { flex: 1; }
.name-cell .kind { width: 92px; flex: none; }
.center { text-align: center; }
.center input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--accent); }
.move { white-space: nowrap; width: 40px; }
.icon-only { width: 28px; height: 28px; border-radius: 8px; color: var(--muted); font-size: 10px; display: inline-grid; place-items: center; }
.icon-only:hover:not(:disabled) { background: var(--surface-2); color: var(--text); }
.icon-only.danger:hover { color: var(--danger); }
.icon-only svg { width: 15px; height: 15px; }
.ex-table .note { height: 32px; font-size: 13px; color: var(--text-2); background: transparent; border-style: dashed; }
.wk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; margin-top: 8px; }
.wk-cell { display: flex; align-items: center; gap: 4px; padding: 6px 8px; border-radius: 10px; background: var(--surface-2); }
.wk-cell .input { height: 30px; padding: 0 6px; text-align: center; background: var(--surface); }
.wk-cell .input[data-cell=sets] { width: 38px; }
.wk-cell .input[data-cell=reps] { width: 54px; }
.wk-cell .input[data-cell=load] { flex: 1; min-width: 40px; }
.wk-label { font-size: 11px; font-weight: 700; color: var(--muted); width: 24px; }

/* exercise picker */
.ac-pop { position: fixed; z-index: 50; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 12px 32px rgb(2 0 112 / .14); padding: 6px; max-height: 340px; overflow: auto; }
.ac-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 10px; border-radius: 9px; cursor: pointer; font-size: 14px; }
.ac-item b { color: var(--accent); font-weight: 700; }
.ac-item small { font-size: 11px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
.ac-item.on, .ac-item:hover { background: var(--accent-soft); }

.notice-info { padding: 12px 16px; border-radius: var(--radius-sm); background: var(--accent-soft); color: var(--text); font-size: 14px; }

/* ---------- shared helpers ---------- */
.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; }
.spacer { flex: 1; }
fieldset.field { border: 0; padding: 0; margin: 0; min-width: 0; }
fieldset.field legend { padding: 0; margin-bottom: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.field-err { display: block; margin-top: 3px; font-size: 11px; line-height: 1.3; color: var(--danger); white-space: normal; }
.field-err:empty { display: none; }
.input[aria-invalid=true] { border-color: var(--danger); }
/* Touch screens get 44px targets everywhere; mouse users keep the compact desktop layout. */
@media (pointer: coarse) {
  .btn, .btn.sm, .seg button, .seg a, .icon-only, .day-btn, button.link, .link-btn { min-height: 44px; }
  .icon-only { min-width: 44px; }
  .ex-table .input, .wk-cell .input { height: 44px; }
}

/* ---------- builder additions ---------- */
.undo-row { display: inline-flex; gap: 2px; }
.restore { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.day-pick-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.day-pick { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.day-btn { min-width: 44px; height: 32px; padding: 0 8px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 13px; font-weight: 600; }
.day-btn[aria-pressed=true] { background: var(--accent); color: var(--accent-ink); }
.drag { display: inline-grid; place-items: center; width: 18px; height: 28px; color: var(--muted); cursor: grab; touch-action: none; user-select: none; font-size: 12px; letter-spacing: -2px; vertical-align: middle; }
.ex-table tr.dragging td { background: var(--accent-soft); }
.ex-table tr.dragging .drag { cursor: grabbing; }
.ex-table tr.drop-before td { box-shadow: inset 0 2px 0 var(--accent); }
.ex-table tr.drop-after td { box-shadow: inset 0 -2px 0 var(--accent); }
.ex-extra { display: flex; gap: 8px; align-items: flex-start; flex-wrap: wrap; }
.ex-extra .note { flex: 1 1 280px; }
.start-hint { display: inline-flex; align-items: center; gap: 6px; }
.start-hint .ck { width: 64px; }
.start-hint .ck:last-child { width: 84px; } /* fits AMRAP and the pick arrow */
.start-hint .input { height: 32px; font-size: 13px; }
.ex-table .move-to { width: auto; height: 32px; font-size: 13px; color: var(--muted); }
/* Demo video links: a field in the exercise's second row, the play icon lit when one is set. */
.demo-field { display: inline-flex; align-items: flex-start; gap: 2px; flex: 0 1 250px; min-width: 190px; }
.demo-field .ck { flex: 1; min-width: 0; }
.ex-table .demo-field .input { width: 100%; height: 32px; font-size: 13px; color: var(--text-2); background: transparent; border-style: dashed; }
.demo-open { display: inline-grid; place-items: center; width: 28px; height: 32px; flex: none; border-radius: 8px; color: var(--muted); opacity: .45; }
.demo-open svg { width: 13px; height: 13px; }
.demo-open.on { color: var(--accent); opacity: 1; }
.demo-open.on:hover { background: var(--accent-soft); }
.demo-link { display: inline-flex; align-items: center; gap: 3px; margin-left: 8px; padding: 1px 8px 1px 6px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: 12px; font-weight: 600; text-decoration: none; vertical-align: 1px; }
.demo-link svg, .demo-name svg { width: 10px; height: 10px; }
.demo-name { color: inherit; text-decoration: underline dotted; text-underline-offset: 3px; }
.demo-name svg { margin-left: 3px; color: var(--accent); }
@media (pointer: coarse) {
  .ex-table .demo-field .input { height: 44px; }
  .demo-open { width: 44px; height: 44px; }
}
.preview-card .card-head { flex-wrap: wrap; }
.wk-seg { grid-auto-flow: column; overflow-x: auto; max-width: 100%; }
.preview-routine ul { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.preview-routine li { display: flex; flex-direction: column; }
.preview-routine li.ss { padding-left: 10px; box-shadow: inset 3px 0 0 var(--train); }
select.input { padding-right: 8px; }

/* ---------- builder: bars that stay in view (coach/sticky.js sets the offsets) ---------- */
/* The head bar sticks under the top bar; its background runs to the window's edges like the top bar's. */
.builder-head {
  position: sticky; top: var(--builder-top, 0px); z-index: 4;
  margin: -8px 0; padding: 8px 0;
  border-image: linear-gradient(var(--bg), var(--bg)) fill 0 / 0 / 0 100vmax;
}
.builder-head.stuck { border-image: linear-gradient(var(--bg) calc(100% - 1px), var(--line) 0) fill 0 / 0 / 0 100vmax; }
/* A copy of the routine's column headers, outside the table's sideways scroll so it can stick. */
.cols-strip { position: sticky; top: var(--builder-line, 0px); z-index: 3; margin: 0 -20px; background: var(--surface); }
.cols-strip.stuck { box-shadow: 0 10px 12px -12px rgb(2 0 112 / .35); }
.cols-scroll { position: relative; overflow: hidden; }
.cols-strip table { table-layout: fixed; }
/* "Exercise" or the routine's name stays at the left while the table is scrolled sideways. */
.cols-label, .cols-routine { position: sticky; left: 14px; display: inline-block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; vertical-align: bottom; }
.cols-strip.stuck .cols-label, .cols-strip:not(.stuck) .cols-routine { display: none; }
.cols-routine { color: var(--text); font-size: 13px; text-transform: none; letter-spacing: 0; }
/* The table's own header row: no height, still read out and still sizing the columns. */
.cols-strip + .table-wrap thead th { height: 0; padding-block: 0; border-bottom: 0; line-height: 0; color: transparent; }
/* Visually hidden header text is positioned: keep it inside the scrolling box, not past the page edge. */
.routine-edit .table-wrap { position: relative; }
html:has(.builder-head) { scroll-padding-top: calc(var(--builder-stack, 0px) + 8px); }
@media (prefers-color-scheme: dark) { .cols-strip.stuck { box-shadow: 0 10px 12px -12px rgb(0 0 0 / .8); } }
/* Narrow and short screens: only the name and Save stay; block length, undo and preview scroll away. */
@media (max-width: 1000px), (max-height: 500px) {
  .builder-head::after { content: ""; order: 1; flex-basis: 100%; margin-top: -10px; }
  .builder-head .title-input, .builder-head [data-act=save], .builder-head [data-act=push] { order: 2; }
  .builder-head .title-input { flex: 1 1 0; min-width: 0; max-width: none; }
  .builder-head [data-role=saved] { margin-left: auto; }
  .builder-head.stuck > :not(.title-input, [data-act=save], [data-act=push]) { visibility: hidden; } /* under the top bar */
}
@media (min-width: 1001px) { .builder-head .title-input { flex-basis: 240px; } } /* one row from 1000 px */
@media (max-width: 640px), (max-height: 500px) { .builder-head .title-input { height: 44px; font-size: 17px; } }
/* Phones on their side: the column headers scroll along, or the bars would fill half the screen. */
@media (max-height: 500px) { .cols-strip { position: static; } }
/* Phones: the routine's name gets a row of its own above its buttons. */
@media (max-width: 640px) {
  .routine-head { flex-wrap: wrap; }
  .routine-name { flex: 1 1 100%; max-width: none; }
}

/* ---------- client views ---------- */
.head-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.range-row { display: flex; justify-content: flex-end; }
.client-cols { grid-template-columns: 2fr 1fr; }
@media (max-width: 900px) { .client-cols { grid-template-columns: 1fr; } }
.c-train { --c: var(--train); }
.program-line { display: flex; justify-content: space-between; gap: 8px; align-items: center; flex-wrap: wrap; }
.program-line .flags { justify-content: flex-end; }
table.compact { font-size: 14px; }
table.compact th, table.compact td { padding: 6px 8px; }
table.compact th:first-child, table.compact td:first-child { padding-left: 0; }
table.compact th:last-child, table.compact td:last-child { padding-right: 0; }
.goals-table tbody th { text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 500; color: var(--muted); border-bottom: 1px solid var(--line); }
.goals-table tr:last-child th { border-bottom: 0; }
.strike { text-decoration: line-through; }
.textarea-sm { height: auto; min-height: 64px; padding: 10px 12px; resize: vertical; font: inherit; line-height: 1.4; }
.inline-field { display: inline-flex; align-items: center; gap: 8px; }
.inline-field .input { width: auto; height: 36px; }
.wk li .done-col { text-align: right; }
.wk li .flag { margin-top: 3px; }
.wk li.skipped > span:first-child { color: var(--muted); text-decoration: line-through; }
a.tile-link { color: inherit; text-decoration: none; transition: box-shadow .15s; }
a.tile-link:hover { box-shadow: 0 0 0 2px var(--accent-soft), var(--shadow); }
/* workout log */
.week-head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 20px 0 0; padding-bottom: 8px; border-bottom: 1px solid var(--line); font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.week-head span { text-transform: none; letter-spacing: 0; font-weight: 500; }
.card-head + .week-head { margin-top: 4px; }
.week-head + .day { border-top: 0; }
.session-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.session-name { font-weight: 600; }
.session-head .flags { justify-content: flex-end; }
.session-head .flags:empty { display: none; }
/* An opened session: the table lines up under the workout name, feedback beside it. */
.session-body { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; align-items: start; padding: 2px 0 20px 164px; }
.session-table th, .session-table td { padding: 9px 12px; vertical-align: top; }
.session-table th:first-child, .session-table td:first-child { padding-left: 0; }
.session-table th:last-child, .session-table td:last-child { padding-right: 0; }
.session-table thead th { padding-top: 0; }
.session-table .unit { text-transform: none; letter-spacing: 0; font-weight: 500; }
.session-table .plan { color: var(--muted); white-space: nowrap; }
.session-table .num { width: 1%; }
.ex-name { display: block; font-weight: 600; }
.ex-note { display: flex; gap: 5px; margin-top: 3px; font-size: 13px; font-style: italic; color: var(--muted); }
.ex-note svg { width: 13px; height: 13px; margin-top: 3px; flex: none; }
.chips { display: flex; flex-wrap: wrap; gap: 4px; }
.chip { display: inline-flex; align-items: center; height: 24px; padding: 0 8px; border-radius: 7px; background: var(--surface-2); font-size: 13px; font-weight: 600; white-space: nowrap; }
.chip.missed { min-width: 40px; background: none; border: 1.5px dashed color-mix(in srgb, var(--warn) 60%, transparent); }
.session-table .ok { display: inline-grid; color: var(--good); }
.session-table .ok svg { width: 18px; height: 18px; stroke-width: 2.6; }
.session-table .flag + .flag { margin-left: 4px; }
.session-table tr.skipped .ex-name { color: var(--muted); text-decoration: line-through; }
.session-side { display: flex; flex-direction: column; gap: 10px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); }
.session-side h4 { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.session-side .coach-comment { margin-top: 0; background: var(--surface); }
/* Feedback on one exercise: a Comment link under its name, the comments and the form in a row below. */
.ex-comment-btn { display: inline-flex; align-items: center; gap: 4px; margin-top: 3px; text-decoration: none; }
.ex-comment-btn svg { width: 13px; height: 13px; }
.ex-comment-btn:hover, .ex-comment-btn[aria-expanded=true] { color: var(--accent); }
.session-table tr:has(+ .ex-feedback) > td { border-bottom: 0; }
.session-table .ex-feedback > td { padding-top: 0; }
.ex-feedback .coach-comment { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 2px 12px; margin: 0 0 8px; max-width: 640px; }
.ex-feedback .coach-comment p { grid-column: 1 / -1; }
.ex-feedback .coach-comment .about { display: none; }
.ex-feedback .comment-form { max-width: 640px; margin-bottom: 4px; }
.coach-comment .about { font-size: 12px; font-weight: 700; color: var(--accent); }
@media (max-width: 1100px) { .session-body { padding-left: 0; } }
@media (max-width: 900px) { .session-body { grid-template-columns: 1fr; gap: 16px; } }
@media (max-width: 640px) {
  .session-table thead { display: none; }
  .session-table tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; row-gap: 4px; padding: 10px 0; border-bottom: 1px solid var(--line); }
  .session-table tr:last-child { border-bottom: 0; }
  .session-table td { padding: 0 !important; border: 0; }
  .session-table td.num { grid-column: 2; grid-row: 1; width: auto; }
  .session-table td.plan, .session-table td.done { grid-column: 1 / -1; }
  .session-table tr:has(+ .ex-feedback) { border-bottom: 0; padding-bottom: 6px; }
  .session-table tr.ex-feedback, .session-table tr.ex-feedback > td { display: block; padding-top: 0; }
  /* Comment as an icon on the name's line. */
  .session-table td.ex-cell { display: flex; flex-wrap: wrap; align-items: center; column-gap: 8px; }
  .session-table td.num { align-self: center; }
  .ex-cell .ex-name { flex: 1; min-width: 0; }
  .ex-cell .ex-note { flex-basis: 100%; order: 1; }
  .ex-comment-btn { margin: 0; padding: 0 6px; justify-content: center; min-width: 32px; }
  .ex-comment-btn svg { width: 17px; height: 17px; }
  .ex-comment-btn .label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .session-head .session-main, .session-head .flags { grid-column: 1 / -1; order: 3; }
  .session-head .flags { justify-content: flex-start; }
}
.day-feedback { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 10px; border-top: 1px dashed var(--line); padding-top: 12px; }
.day-feedback h4 { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.coach-comment { padding: 10px 12px; border-radius: var(--radius-sm); background: var(--accent-soft); display: flex; flex-direction: column; gap: 4px; margin-top: 8px; }
.coach-comment p { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; }
.coach-comment > span { display: inline-flex; align-items: center; gap: 4px; }
.coach-comment svg { width: 13px; height: 13px; }
.coach-comment .link { align-self: flex-start; }
.comment-form { display: flex; flex-direction: column; gap: 8px; }
.small-spin { margin: 12px auto; }
.who-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 220px; }
/* The coach's logo on a white plate in both themes, as their clients' app shows it (see style.css). */
.who-logo { display: block; height: 32px; width: auto; max-width: 112px; object-fit: contain; padding: 3px 4px; border-radius: 8px; background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.logo-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 20px; }
.logo-plate { display: grid; place-items: center; width: 168px; height: 84px; padding: 8px; border-radius: var(--radius-sm); background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.logo-plate img { display: block; max-width: 152px; max-height: 68px; object-fit: contain; }
.logo-plate .muted { color: #6b6a8a; } /* on the white plate in dark mode too */
.logo-text p { margin-top: 4px; }
.logo-actions { display: flex; gap: 8px; }
@media (max-width: 640px) {
  .logo-row { grid-template-columns: auto minmax(0, 1fr); gap: 12px 16px; }
  .logo-plate { width: 120px; height: 64px; }
  .logo-plate img { max-width: 104px; max-height: 48px; }
  .logo-actions { grid-column: 1 / -1; }
}
.danger-zone { border: 1px solid color-mix(in srgb, var(--danger) 35%, transparent); }
.danger-zone .form { max-width: 460px; }
.btn.danger-solid { background: var(--danger); color: #fff; align-self: flex-start; }
/* The coach's name gives way (…) before the top bar gets wider than the window; next to their logo
   on a narrow window it goes. */
.who, .who-name { min-width: 0; }
@media (max-width: 900px) { .who-logo + .who-name { display: none; } }
/* Phones: logo, tabs and Sign out on one row (the name is kept for screen readers). */
@media (max-width: 640px) {
  .topbar { gap: 8px; }
  .brand span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .who { gap: 2px; }
  .who-name, .who-logo { display: none; }
  .nav { gap: 0; margin: -4px; padding: 4px; min-width: 0; overflow-x: auto; scrollbar-width: none; } /* room for the focus ring */
  .nav a { padding: 6px 10px; white-space: nowrap; }
  .who .btn.sm { padding: 0 10px; }
}

/* ---------- progress charts ---------- */
.chart-title { font-size: 14px; margin-bottom: 2px; }
.figure { margin: 8px 0 0; }
.svg-chart { width: 100%; height: auto; max-height: 260px; display: block; overflow: visible; stroke: none; fill: none; stroke-width: 0; }
.svg-chart .grid { stroke: var(--line); stroke-width: 1; }
.svg-chart .tick { fill: var(--muted); font-size: 11px; }
.svg-chart .line { fill: none; stroke: var(--c, var(--accent)); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.svg-chart .dot { fill: var(--c, var(--accent)); stroke: var(--surface); stroke-width: 2; }
.svg-chart .bar { fill: var(--c, var(--accent)); }
.svg-chart .hit { fill: transparent; }
.svg-chart g:hover .dot { r: 6; }
.svg-chart g:hover .hit { fill: color-mix(in srgb, var(--surface-2) 60%, transparent); }
.chart-table { margin-top: 8px; font-size: 13px; }
.chart-table summary { cursor: pointer; color: var(--accent); font-weight: 600; min-height: 32px; display: flex; align-items: center; }
.chart-table table { font-size: 13px; }
.chart-table th, .chart-table td { padding: 6px 8px; }
@media (forced-colors: active) { .svg-chart .line, .svg-chart .bar, .svg-chart .dot { stroke: CanvasText; fill: CanvasText; } .svg-chart .line { fill: none; } }
/* rep maxes: one row per lift, the estimate set apart from the lifted weights */
.max-wrap { overflow-x: auto; }
.max-table td { font-variant-numeric: tabular-nums; }
.max-table tbody th { text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 600; color: var(--text); white-space: normal; }
.max-table .est { border-left: 1px solid var(--line); padding-left: 12px; }
.max-table td.est { color: var(--muted); }
.max-table tr:last-child th { border-bottom: 0; }
@media (max-width: 640px) {
  table.max-table { font-size: 13px; }
  table.max-table th, table.max-table td { padding: 6px 3px; }
  table.max-table th:first-child { padding-left: 0; }
  table.max-table thead th { font-size: 11px; letter-spacing: 0; }
  table.max-table tbody th { font-size: 13px; }
  table.max-table .est { padding-left: 6px; }
}

/* Google / Facebook sign-in (shared/auth.js) */
.social-login { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 10px; }
.btn.social {
  height: 42px; gap: 10px;
  background: var(--surface); color: var(--text);
  border: 1px solid var(--line);
  box-shadow: 0 1px 2px rgb(2 0 112 / .06);
  transition: transform .1s, border-color .15s, box-shadow .15s, background .15s;
}
.btn.social svg { width: 20px; height: 20px; flex: none; stroke: none; } /* brand logos: no icon stroke */
.btn.social:active { transform: scale(.98); }
.btn.social:disabled { opacity: .6; }
.btn.social:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (hover: hover) {
  .btn.social:hover { border-color: color-mix(in srgb, var(--accent) 40%, var(--line)); box-shadow: 0 3px 12px rgb(2 0 112 / .1); }
}
@media (prefers-color-scheme: dark) {
  .btn.social { background: var(--surface-2); border-color: transparent; box-shadow: none; }
}
.or-line { display: flex; align-items: center; gap: 12px; margin: 2px 0; color: var(--muted); font-size: 12px; letter-spacing: .02em; }
.or-line::before, .or-line::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
[data-role=social]:empty { display: none; }

/* ---------- technique videos ---------- */
svg.fill { fill: currentColor; stroke: none; }
.video-pill { display: inline-flex; align-items: center; gap: 4px; height: 22px; margin-left: 6px; padding: 0 9px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); font-size: 12px; font-weight: 600; vertical-align: 1px; }
.video-pill svg { width: 10px; height: 10px; }
.video-pill:hover { background: var(--accent); color: var(--accent-ink); }
.video-list { list-style: none; margin: 0; padding: 0; }
.video-list li { display: flex; align-items: center; gap: 14px; padding: 10px 0; border-top: 1px solid var(--line); }
.video-list li:first-child { border-top: 0; padding-top: 0; }
.video-thumb { width: 44px; height: 44px; border-radius: 50%; flex: none; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.video-thumb svg { width: 16px; height: 16px; }
.video-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.video-main .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
dialog.video-dialog { width: min(1040px, calc(100vw - 32px)); }
.video-layout { display: grid; grid-template-columns: minmax(0, 3fr) minmax(260px, 2fr); gap: 18px; align-items: start; }
.video-layout video { width: 100%; max-height: 72vh; border-radius: var(--radius-sm); background: #000; }
.video-side { display: flex; flex-direction: column; gap: 12px; }
.video-side h4 { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.video-sets { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0; }
.video-sets dt { color: var(--muted); font-size: 13px; }
.video-sets dd { margin: 0; font-weight: 600; }
@media (max-width: 760px) { .video-layout { grid-template-columns: 1fr; } }

/* ---------- progress photos ---------- */
.photo-cols { grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr); align-items: start; }
@media (max-width: 900px) { .photo-cols { grid-template-columns: minmax(0, 1fr); } }
.photo-controls { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; justify-content: flex-end; }
.compare { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.compare.cols-poses { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.compare figure { margin: 0; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.compare img, .photo-none { display: block; width: 100%; aspect-ratio: 3 / 4; max-height: 72vh; object-fit: contain; border-radius: var(--radius-sm); background: var(--surface-2); }
.photo-none { display: grid; place-items: center; color: var(--muted); font-size: 14px; }
.compare figcaption { font-size: 13px; color: var(--muted); }
.compare figcaption strong { color: var(--text); font-weight: 600; }
.compare-note { margin-top: 12px; }
.checkin { display: flex; flex-direction: column; gap: 8px; padding: 12px 0; border-top: 1px solid var(--line); }
.checkin:first-of-type { border-top: 0; padding-top: 0; }
.checkin-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 14px; }
.checkin-poses { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.checkin-thumb { position: relative; display: block; aspect-ratio: 3 / 4; padding: 0; border-radius: 10px; overflow: hidden; background: var(--surface-2); }
.checkin-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.checkin-thumb span { position: absolute; left: 4px; bottom: 4px; padding: 1px 7px; border-radius: 99px; background: rgb(0 0 0 / .55); color: #fff; font-size: 11px; font-weight: 600; }
.checkin-thumb.none { display: grid; place-items: center; color: var(--muted); font-size: 12px; }
button.checkin-thumb:hover { box-shadow: 0 0 0 2px var(--accent); }
dialog.photo-dialog { width: min(760px, calc(100vw - 32px)); }
.photo-dialog img { display: block; width: 100%; max-height: 78vh; object-fit: contain; border-radius: var(--radius-sm); background: var(--surface-2); }

/* ---------- the coach logs a workout ---------- */
/* Log head: the hint and the Log a workout button on the right, wrapping under the title on a phone. */
.log-head { align-items: center; flex-wrap: wrap; }
.log-head-tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: flex-end; }
/* Logged workouts the client's app hasn't taken yet: laid out like a session row of the log. */
.waiting-row { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto auto; gap: 14px; align-items: center; padding: 12px 0; }
.waiting-row .flags:empty { display: none; }
@media (max-width: 640px) {
  .log-head-tools { justify-content: flex-start; }
  .waiting-row { grid-template-columns: minmax(0, 1fr) auto auto; gap: 4px 8px; }
  .waiting-row .session-main { grid-column: 1 / -1; grid-row: 2; }
  .waiting-row .flags { grid-row: 1; grid-column: 2; }
  .waiting-row .btn { grid-row: 1; grid-column: 3; }
}
/* The dialog: a head, a scrolling body and a footer that stays in view (it can hold a long workout). */
dialog.log-dialog { width: min(720px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; }
dialog.log-dialog[open] { display: flex; flex-direction: column; overflow: hidden; }
.log-dialog .dialog-head { gap: 12px; padding: 20px 24px 0; margin-bottom: 12px; }
.log-dialog .dialog-head h2 { font-size: 18px; min-width: 0; overflow-wrap: anywhere; }
.log-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 0 24px 20px; display: flex; flex-direction: column; gap: 14px; }
.log-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 24px; border-top: 1px solid var(--line); background: var(--bg); }
.log-foot .btn.primary { min-width: 0; }
.log-foot .label { overflow: hidden; text-overflow: ellipsis; }
.log-restored { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.log-restored[hidden] { display: none; }
.log-setup { display: grid; grid-template-columns: minmax(0, 1fr) 110px 160px; gap: 12px; }
.log-exercises { display: flex; flex-direction: column; gap: 10px; }
.log-ex { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface); }
.log-ex-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.log-ex-name { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.log-sets { table-layout: fixed; }
.log-sets th, .log-sets td { padding: 3px 4px; border: 0; }
.log-sets th:first-child, .log-sets td:first-child { padding-left: 0; }
.log-sets th:last-child, .log-sets td:last-child { padding-right: 0; }
.log-sets th { padding-bottom: 2px; font-size: 11px; }
.log-sets .n { width: 40px; color: var(--muted); font-weight: 600; text-align: center; }
.log-sets .tick { width: 52px; text-align: center; }
.log-sets .input { height: 40px; padding: 0 10px; text-align: center; }
.log-sets tr.done .input { border-color: color-mix(in srgb, var(--good) 45%, var(--line)); background: color-mix(in srgb, var(--good-soft) 55%, var(--surface)); }
.log-check { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; border: 1.5px solid var(--line); color: var(--line); }
.log-check:hover { color: var(--good); border-color: var(--good); }
.log-check[aria-pressed=true] { background: var(--good); border-color: var(--good); color: #fff; }
.log-check svg { stroke-width: 2.6; }
.log-add-set { display: inline-block; margin-top: 6px; text-decoration: none; color: var(--accent); font-weight: 600; }
.log-none { text-align: center; padding: 12px 0; }
.log-add { display: flex; gap: 8px; }
.log-add .input { flex: 1; min-width: 0; }
@media (pointer: coarse) {
  .log-sets .input, .log-check { height: 44px; }
  .log-check { width: 44px; }
  .log-add-set { min-height: 44px; display: inline-flex; align-items: center; }
}
@media (max-width: 640px) {
  dialog.log-dialog { width: calc(100vw - 16px); max-height: calc(100dvh - 16px); border-radius: 18px; }
  .log-dialog .dialog-head { padding: 14px 16px 0; }
  .log-body { padding: 0 16px 16px; }
  .log-foot { padding: 10px 16px; }
  .log-foot .btn.primary { flex: 1; }
  .log-setup { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); }
  .log-setup .log-routine { grid-column: 1 / -1; }
  .log-ex { padding: 10px 12px; }
  .log-sets .n { width: 30px; }
  .log-sets .tick { width: 50px; }
}
