/* Club Coach — Look B · Night Run */
:root {
  --ground: #0e1116;
  --surface: #171b22;
  --surface-2: #1d222b;
  --line: #262c35;
  --line-2: #3a424d;
  --text: #f2f4f7;
  --text-2: #c3c9d1;
  --muted: #9aa3ae;
  --volt: #d4ff3a;
  --on-volt: #0e1116;
  --z4: #ffb35c;
  --z5: #ff7a59;
  --flame: #ff9a3d;
  --accent: #d4ff3a;
  --accent-line: #d4ff3a;
  --graphic: #d4ff3a;
  --demo-back: #5b6470;
  --glass: rgba(14, 17, 22, .9);
  --glass-2: rgba(23, 27, 34, .96);
  --ground-0: rgba(14, 17, 22, 0);
  --placeholder: #6f7883;
  --line-3: #4a535f;
  --z2bg: #2b3440;
  --shadow: rgba(0, 0, 0, .45);
  --r-sm: 10px;
  --r: 12px;
  --r-lg: 16px;
  --display: 'Saira Condensed', 'Bahnschrift', 'Arial Narrow', sans-serif;
  --body: 'IBM Plex Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-l: env(safe-area-inset-left, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --tabbar-h: 64px;
  color-scheme: dark;
}

/* Light scheme: follows the phone unless the runner picks one in Settings */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
  --ground: #f2f4f6;
  --surface: #ffffff;
  --surface-2: #e9edf1;
  --line: #dde2e8;
  --line-2: #c3cad3;
  --line-3: #a9b2bd;
  --text: #0e1116;
  --text-2: #353e4a;
  --muted: #5b6470;
  --volt: #d4ff3a;
  --on-volt: #0e1116;
  --accent: #476000;
  --accent-line: #8cb000;
  --graphic: #6a8a00;
  --demo-back: #a9b2bd;
  --z4: #a84f05;
  --z5: #bf3a10;
  --flame: #c9480f;
  --glass: rgba(242, 244, 246, .92);
  --glass-2: rgba(255, 255, 255, .96);
  --ground-0: rgba(242, 244, 246, 0);
  --placeholder: #7c8590;
  --z2bg: #e1e6ec;
  --shadow: rgba(14, 17, 22, .14);
  color-scheme: light;
  }
}
:root[data-theme="light"] {
  --ground: #f2f4f6;
  --surface: #ffffff;
  --surface-2: #e9edf1;
  --line: #dde2e8;
  --line-2: #c3cad3;
  --line-3: #a9b2bd;
  --text: #0e1116;
  --text-2: #353e4a;
  --muted: #5b6470;
  --volt: #d4ff3a;
  --on-volt: #0e1116;
  --accent: #476000;
  --accent-line: #8cb000;
  --graphic: #6a8a00;
  --demo-back: #a9b2bd;
  --z4: #a84f05;
  --z5: #bf3a10;
  --flame: #c9480f;
  --glass: rgba(242, 244, 246, .92);
  --glass-2: rgba(255, 255, 255, .96);
  --ground-0: rgba(242, 244, 246, 0);
  --placeholder: #7c8590;
  --z2bg: #e1e6ec;
  --shadow: rgba(14, 17, 22, .14);
  color-scheme: light;
}
:root[data-theme="dark"] { color-scheme: dark; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--ground); }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--ground);
  color: var(--text);
  font: 400 16px/1.5 var(--body);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--accent); text-underline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
[hidden] { display: none !important; }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
h1:focus-visible, h1[tabindex]:focus { outline: none; }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.mono { font-family: var(--mono); font-weight: 500; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; display: flex; justify-content: center; }
.opt { color: var(--muted); font-weight: 400; text-transform: none; letter-spacing: 0; font-size: 12px; margin-left: 4px; }

.ic { width: 22px; height: 22px; flex: none; }

/* ------------------------------------------------------------ layout */
.screen {
  max-width: 560px;
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
  padding-top: var(--safe-t);
  padding-bottom: calc(var(--tabbar-h) + var(--safe-b) + 24px);
  position: relative;
}
.screen.no-tabs { padding-bottom: calc(var(--safe-b) + 32px); }
.screen.has-cta { padding-bottom: calc(var(--safe-b) + 112px); }
.content {
  padding: 8px calc(16px + var(--safe-r)) 0 calc(16px + var(--safe-l));
}

.boot { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; }
.boot .bib { animation: pulse 1.2s ease-in-out infinite alternate; }
@keyframes pulse { from { opacity: .55; transform: scale(.97); } to { opacity: 1; transform: scale(1); } }
.noscript { padding: 24px; text-align: center; }

/* ------------------------------------------------------------ brand */
.bib {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 40px;
  height: 29px;
  border-radius: 7px;
  background: var(--volt);
  color: var(--on-volt);
  font: italic 800 17px/1 var(--display);
  letter-spacing: .02em;
  padding-right: 1px;
}
.bib i { position: absolute; width: 4px; height: 4px; border-radius: 50%; background: var(--ground); }
.bib i:nth-child(1) { top: 4px; left: 4px; }
.bib i:nth-child(2) { top: 4px; right: 4px; }
.bib i:nth-child(3) { bottom: 4px; left: 4px; }
.bib i:nth-child(4) { bottom: 4px; right: 4px; }
.bib-lg { width: 64px; height: 46px; border-radius: 10px; font-size: 28px; }
.bib-lg i { width: 6px; height: 6px; }
.bib-lg i:nth-child(1), .bib-lg i:nth-child(2) { top: 6px; }
.bib-lg i:nth-child(3), .bib-lg i:nth-child(4) { bottom: 6px; }
.bib-lg i:nth-child(1), .bib-lg i:nth-child(3) { left: 6px; }
.bib-lg i:nth-child(2), .bib-lg i:nth-child(4) { right: 6px; }

.logo { display: inline-flex; align-items: center; gap: 10px; }
.wordmark { font: italic 800 21px/1 var(--display); text-transform: uppercase; letter-spacing: .02em; color: var(--text); }
.wordmark-lg { font-size: 34px; }

/* ------------------------------------------------------------ top bar */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 60px;
  padding: 6px calc(10px + var(--safe-r)) 6px calc(16px + var(--safe-l));
  margin-top: calc(-1 * var(--safe-t));
  padding-top: calc(6px + var(--safe-t));
  background: var(--glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.topbar:has(.icon-btn:first-child) { padding-left: calc(6px + var(--safe-l)); }
.brand { text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; border-radius: 8px; }
.topbar-title { font: 700 18px/1 var(--display); text-transform: uppercase; letter-spacing: .06em; color: var(--text-2); }
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--text-2);
  flex: none;
}
.icon-btn:hover:not(:disabled) { background: var(--surface); color: var(--text); }
.icon-btn:disabled { opacity: .35; }
.icon-btn.small { width: 44px; height: 44px; }
.icon-btn.small .ic { width: 18px; height: 18px; }
.icon-spacer { width: 44px; height: 44px; flex: none; }

/* ------------------------------------------------------------ tab bar */
.tabbar {
  position: fixed;
  z-index: 30;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 560px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding: 0 var(--safe-r) var(--safe-b) var(--safe-l);
  background: var(--glass-2);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
}
.tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: var(--tabbar-h);
  color: var(--muted);
  text-decoration: none;
  font: 600 11px/1 var(--body);
  letter-spacing: .06em;
  text-transform: uppercase;
  position: relative;
}
.tab .ic { width: 24px; height: 24px; }
.tab[aria-current="page"] { color: var(--accent); }
.tab[aria-current="page"]::before {
  content: '';
  position: absolute;
  top: 0;
  left: 30%;
  right: 30%;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--volt);
}
.tab:focus-visible { outline-offset: -4px; }

/* ------------------------------------------------------------ type */
.display {
  font: italic 800 34px/1 var(--display);
  text-transform: uppercase;
  letter-spacing: .005em;
  margin: 14px 0 8px;
}
.display.small { font-size: 28px; margin: 0; }
.lede { color: var(--text-2); font-size: 16px; margin-bottom: 18px; }
.section-title {
  font: italic 800 22px/1 var(--display);
  text-transform: uppercase;
  margin: 26px 0 12px;
}
.label {
  display: block;
  font: 600 12px/1.3 var(--body);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.hint { color: var(--muted); font-size: 14px; margin-top: 8px; }
.fine { color: var(--muted); font-size: 13px; margin-top: 22px; }
.form-error { color: var(--z5); font-size: 14px; font-weight: 500; min-height: 0; margin-top: 10px; }
.form-error:empty { margin: 0; }
.link-btn { background: none; border: 0; color: var(--text-2); text-decoration: underline; text-underline-offset: 3px; min-height: 44px; padding: 0 8px; }

/* ------------------------------------------------------------ buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 0 18px;
  border-radius: var(--r);
  border: 1px solid transparent;
  font: 600 16px/1.2 var(--body);
  text-decoration: none;
  transition: background-color .15s, border-color .15s, transform .08s;
}
.btn:active:not(:disabled) { transform: scale(.985); }
.btn.block { display: flex; width: 100%; }
.btn.small { min-height: 36px; padding: 0 14px; font-size: 14px; border-radius: 999px; }
.btn .ic { width: 20px; height: 20px; }
.btn.primary { background: var(--volt); color: var(--on-volt); font-weight: 700; }
.btn.primary:hover:not(:disabled) { background: #e0ff6b; }
.btn.secondary { background: var(--surface); color: var(--text); border-color: var(--line-2); }
.btn.secondary:hover:not(:disabled) { border-color: var(--muted); }
.btn.danger { background: transparent; color: var(--z5); border-color: var(--z5); }
.btn.danger:hover:not(:disabled) { background: rgba(255, 122, 89, .1); }
.btn:disabled { opacity: .45; }
.btn.on-volt { background: var(--on-volt); color: var(--accent); }
.btn.on-volt:focus-visible { outline-color: var(--on-volt); }

.cta-bar {
  position: fixed;
  z-index: 25;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 560px;
  padding: 24px calc(16px + var(--safe-r)) calc(14px + var(--safe-b)) calc(16px + var(--safe-l));
  background: linear-gradient(to bottom, var(--ground-0), var(--ground) 40%);
}

/* ------------------------------------------------------------ chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: var(--surface);
  color: var(--text-2);
  font: 500 15px/1.2 var(--body);
  transition: background-color .12s, border-color .12s, color .12s;
}
.chip:hover:not(:disabled) { border-color: var(--muted); color: var(--text); }
.chip.on { background: var(--volt); border-color: var(--accent-line); color: var(--on-volt); font-weight: 600; }
.chip.small { min-height: 36px; padding: 0 14px; font-size: 14px; margin: 4px 0 6px; }
.chip:disabled { opacity: .45; }

.pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 30px;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  color: var(--text-2);
  font-size: 13px;
  font-weight: 500;
}
.pill b { color: var(--text); font-weight: 700; }
.pill-volt { border-color: var(--accent-line); color: var(--accent); }
.pill-z4 { border-color: rgba(255, 179, 92, .5); color: var(--z4); }
.pill-z4 b { color: var(--z4); }
.pill-z5 { border-color: rgba(255, 122, 89, .55); color: var(--z5); }
.pill-z5 b { color: var(--z5); }
.pill-pts { background: var(--volt); color: var(--on-volt); border-color: var(--accent-line); font-size: 13px; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--line);
  color: var(--text-2);
  font: 600 11px/1.2 var(--body);
  letter-spacing: .06em;
  text-transform: uppercase;
  white-space: nowrap;
}
.tag .ic { width: 13px; height: 13px; }
.tag.small { font-size: 12px; padding: 2px 6px; }
.tag-volt { background: var(--volt); color: var(--on-volt); }
.tag-done { background: rgba(212, 255, 58, .14); color: var(--accent); }
.tag-holiday { background: rgba(212, 255, 58, .12); color: var(--accent); }
.tag-busy { background: rgba(255, 179, 92, .14); color: var(--z4); }
.tag-race { background: rgba(255, 122, 89, .15); color: var(--z5); }

/* ------------------------------------------------------------ forms */
.stack > * + * { margin-top: 16px; }
.field { margin-bottom: 22px; }
.stack .field { margin-bottom: 0; }
.input {
  display: block;
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-2);
  background: var(--surface);
  color: var(--text);
  font-size: 16px;
  appearance: none;
  -webkit-appearance: none;
}
.input::placeholder { color: var(--placeholder); }
.input:hover { border-color: var(--line-3); }
.input:focus-visible { outline: 2px solid var(--accent); outline-offset: 0; border-color: transparent; border-radius: var(--r-sm); }
.input[type="date"] { min-width: 0; } /* picker follows :root color-scheme */
.input[type="date"]::-webkit-date-and-time-value { text-align: left; }
.input[type="number"] { -moz-appearance: textfield; }
.input::-webkit-outer-spin-button, .input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.input-row { display: flex; gap: 8px; }
.input-row .input { flex: 1; min-width: 0; }
.input-row .btn { flex: none; min-height: 50px; padding: 0 14px; font-size: 15px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.grid-2 .field { margin-bottom: 14px; }

.seg {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  margin: 22px 0 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
}
.seg-btn {
  min-height: 44px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text-2);
  font-weight: 600;
}
.seg-btn.on { background: var(--volt); color: var(--on-volt); }

/* ------------------------------------------------------------ cards */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 16px;
  margin: 14px 0;
}
.card p + p { margin-top: 8px; }
.card > p:not(.hint):not(.form-error) { color: var(--text-2); }
.card .btn.block { margin-top: 14px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.card-title { font: italic 800 20px/1.1 var(--display); text-transform: uppercase; }
.info-card, .warn-card { display: flex; gap: 12px; align-items: flex-start; }
.info-card .ic { color: var(--accent); margin-top: 1px; }
.warn-card { border-color: rgba(255, 179, 92, .45); }
.warn-card p { color: var(--z4) !important; }
.empty { text-align: center; padding: 28px 16px; }
.note-card .label { color: var(--accent); }
.niggle { border-color: rgba(255, 122, 89, .4); }
.niggle .label { color: var(--z5); }

/* ------------------------------------------------------------ auth */
.auth { padding-top: calc(28px + var(--safe-t)); }
.auth-brand { display: flex; align-items: center; gap: 12px; }
.auth-hero {
  margin: 22px 0 18px;
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  aspect-ratio: 4 / 3;
  max-height: 300px;
  width: 100%;
  background: var(--surface);
  position: relative;
}
.auth-hero img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.auth-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(14,17,22,.65), rgba(14,17,22,0) 45%); }
.auth-title { font-size: 36px; line-height: .98; margin: 0; }
.center-stack { padding-top: 18vh; text-align: center; }
.center-stack .auth-brand { justify-content: center; margin-bottom: 8px; }
.center-stack .btn { margin-top: 18px; }

/* ------------------------------------------------------------ onboarding */
.ob-head {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: calc(8px + var(--safe-t)) calc(16px + var(--safe-r)) 8px calc(6px + var(--safe-l));
  margin-top: calc(-1 * var(--safe-t));
  background: var(--glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.progress { flex: 1; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--graphic); border-radius: 3px; }
.step-count { color: var(--text-2); font-size: 14px; min-width: 40px; text-align: right; }
.ob .display { margin-top: 10px; }

.race-tiles { display: grid; gap: 10px; }
.race-tile {
  display: grid;
  gap: 8px;
  padding: 12px 12px 14px;
  border-radius: var(--r-lg);
  background: var(--surface);
  border: 1px solid var(--line);
  transition: border-color .15s;
}
.race-tile.filled { border-color: var(--accent-line); }
.race-dist { font: italic 800 24px/1 var(--display); text-transform: uppercase; color: var(--text); }
.race-tile.filled .race-dist { color: var(--accent); }
.race-inputs { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 8px; }
.mini { display: block; min-width: 0; }
.mini > span { display: block; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.mini .input { min-height: 46px; padding: 0 10px; background: var(--ground); font-size: 16px; }

.row-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 56px;
  padding: 0 16px;
  border-radius: var(--r-lg);
  border: 1px dashed var(--line-2);
  background: transparent;
  color: var(--text-2);
  font-weight: 600;
  text-align: left;
}
.row-btn:disabled { cursor: not-allowed; }
.row-btn .soon { margin-left: auto; }
.soon {
  font: 600 11px/1 var(--body);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--line-2);
  border-radius: 999px;
  padding: 5px 8px;
}

.ring-wrap { display: flex; flex-direction: column; align-items: center; margin: 8px 0 6px; }
.ring { width: 168px; height: 168px; }
.ring-num { font: italic 800 40px/1 var(--display); fill: var(--text); }
.ring-lbl { font: 600 11px/1 var(--body); letter-spacing: .14em; fill: var(--muted); }
.ring-cap { color: var(--text-2); font-size: 14px; text-align: center; margin-top: 8px; }
.pred-list { margin-top: 14px; border-top: 1px solid var(--line); }
.pred-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 4px 14px;
  padding: 14px 8px;
  border-bottom: 1px solid var(--line);
  position: relative;
}
.pred-dist { font: italic 800 22px/1 var(--display); text-transform: uppercase; }
.pred-time { font-size: 18px; color: var(--text); text-align: right; }
.pred-pace { font-size: 14px; color: var(--muted); text-align: right; min-width: 82px; }
.pred-row.hl { background: rgba(212, 255, 58, .07); border-radius: 10px; border-bottom-color: transparent; box-shadow: inset 3px 0 0 var(--accent-line); }
.pred-row.hl .pred-dist, .pred-row.hl .pred-time { color: var(--accent); }
.pred-row .tag { grid-column: 1; justify-self: start; background: var(--volt); color: var(--on-volt); }

.day-toggles { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; }
.day-toggle {
  width: 100%;
  min-width: 0;
  height: 48px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: var(--surface);
  color: var(--text-2);
  font: 700 17px/1 var(--display);
}
.day-toggle.on { background: var(--volt); border-color: var(--accent-line); color: var(--on-volt); }

.stepper { display: flex; align-items: center; gap: 8px; }
.step-btn {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  flex: none;
  border-radius: var(--r);
  border: 1px solid var(--line-2);
  background: var(--surface);
  color: var(--text);
}
.step-val { position: relative; flex: 1; }
.step-val .input { text-align: center; font-size: 20px; padding-right: 40px; padding-left: 40px; }
.step-val .unit { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 14px; pointer-events: none; }

.cal-list { display: grid; gap: 8px; margin-bottom: 6px; }
.cal-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 4px 8px 12px;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--line);
}
.cal-main { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.cal-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-dates { color: var(--muted); font-size: 13px; }
.add-card .chips { margin-bottom: 16px; }

.ztable { border-top: 1px solid var(--line); margin-bottom: 8px; }
.zrow {
  display: grid;
  grid-template-columns: 52px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
}
.zname { color: var(--text-2); }
.zval { color: var(--text); font-size: 15px; text-align: right; }
.zpill {
  display: inline-flex;
  justify-content: center;
  padding: 4px 0;
  border-radius: 6px;
  font: italic 800 15px/1 var(--display);
  background: var(--line);
  color: var(--text-2);
}
.zpill.z2 { background: var(--z2bg); color: var(--text); }
.zpill.z3 { background: rgba(212, 255, 58, .16); color: var(--accent); }
.zpill.z4 { background: rgba(255, 179, 92, .18); color: var(--z4); }
.zpill.z5 { background: rgba(255, 122, 89, .2); color: var(--z5); }
.zpill.zg { background: var(--volt); color: var(--on-volt); font-size: 13px; }
.zrow.goal .zname, .zrow.goal .zval { color: var(--accent); }

/* ------------------------------------------------------------ today */
.countdown { color: var(--text-2); font-size: 15px; margin: 2px 0 6px; }
.countdown .mono { color: var(--accent); }
.daynav { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; margin: 4px -6px; }
.daynav-label { display: flex; flex-direction: column; align-items: center; text-align: center; }
.dn-day { font: italic 800 20px/1.1 var(--display); text-transform: uppercase; letter-spacing: .02em; }
.dn-date { color: var(--muted); font-size: 13px; }

.hero { padding: 18px 0 4px; }
.kicker { font: 600 12px/1.2 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.km-big {
  font: italic 800 clamp(96px, 30vw, 140px)/.86 var(--display);
  color: var(--accent);
  letter-spacing: -.02em;
  margin: 10px 0 6px -4px;
  font-variant-numeric: tabular-nums;
}
.km-big.rest { color: var(--text-2); font-size: clamp(80px, 25vw, 112px); }
.km-unit { font-size: .26em; color: var(--text-2); margin-left: 8px; letter-spacing: .02em; font-style: italic; text-transform: uppercase; }
.session-title { font: italic 800 30px/1.02 var(--display); text-transform: uppercase; margin-top: 4px; }
.meta { color: var(--muted); font-size: 14px; margin-top: 4px; }
.detail { color: var(--text-2); margin-top: 14px; }

.effort { display: flex; align-items: flex-end; gap: 10px; margin-top: 14px; }
.effort-lbl { font: 600 12px/1 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-bottom: 2px; }
.bars { display: flex; align-items: flex-end; gap: 4px; }
.bar { width: 14px; border-radius: 3px; background: var(--line-2); }
.bar.on { background: var(--graphic); }
.bar.on.e4 { background: var(--z4); }
.bar.on.e5 { background: var(--z5); }
.effort-val { color: var(--text); font-size: 15px; }

.coach-card { display: flex; gap: 14px; align-items: flex-start; }
.avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 2px var(--accent-line); border: 2px solid var(--ground); }
.coach-name { font: italic 800 15px/1 var(--display); text-transform: uppercase; letter-spacing: .06em; color: var(--accent); margin: 2px 0 6px; }
.coach-card p { color: var(--text) !important; }

.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.action-col { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.actions .btn { font-size: 15px; padding: 0 10px; white-space: nowrap; }
.soon-note { font-size: 12px; color: var(--muted); text-align: center; }
.done-toggle {
  margin-top: 12px;
  min-height: 56px;
  background: transparent;
  border: 2px solid var(--accent-line);
  color: var(--accent);
  font-weight: 700;
}
.done-toggle .ic { width: 22px; height: 22px; }
.done-toggle.on { background: var(--volt); color: var(--on-volt); }

.checklist li { border-top: 1px solid var(--line); }
.checklist li:first-child { border-top: 0; }
.check-input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.check {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 6px 2px;
  cursor: pointer;
}
.box {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  border: 2px solid var(--line-2);
  color: transparent;
}
.box .ic { width: 18px; height: 18px; stroke-width: 2.6; }
.check-input:checked + .check .box { background: var(--volt); border-color: var(--accent-line); color: var(--on-volt); }
.check-input:checked + .check .ex-name { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--line-2); }
.check-input:focus-visible + .check { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: var(--r-sm); }
.check-input:focus-visible + .check .box { border-color: var(--accent); }
.consent-field { position: relative; }
.check.consent { grid-template-columns: 28px 1fr; min-height: 44px; }
.consent-text { color: var(--text); font-weight: 500; }
.consent-field .hint { margin-top: 6px; }
.field-error { color: var(--z5); font-weight: 500; }
.ph-firm { color: var(--muted); font-size: 14px; margin-left: 6px; }
.ex-name { color: var(--text); }
.ex-reps { color: var(--text-2); font-size: 13px; text-align: right; }

/* ------------------------------------------------------------ week */
.weeknav { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; margin: 10px -6px 4px; }
.weeknav-label { text-align: center; display: flex; flex-direction: column; gap: 4px; }
.weeknav-label .muted { font-size: 13px; }
.km-card { padding: 14px 16px; }
.km-line { display: flex; align-items: baseline; gap: 8px; margin-bottom: 10px; }
.km-done { font-size: 28px; color: var(--accent); }
.km-of { color: var(--text-2); font-size: 14px; }
.meter { display: block; height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--graphic); border-radius: 4px; }
.meter.thin { height: 4px; margin-top: 8px; width: 100%; }

.strip { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; margin: 4px 0 14px; }
.strip-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-height: 74px;
  padding: 8px 0;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--line);
  text-decoration: none;
  color: var(--text);
}
.strip-day.today { border-color: var(--accent-line); }
.strip-day.done { background: rgba(212, 255, 58, .1); }
.sd-dow { font-size: 11px; font-weight: 600; color: var(--muted); }
.sd-num { font-size: 16px; }
.sd-mark { height: 16px; display: grid; place-items: center; color: var(--accent); }
.sd-mark .ic { width: 16px; height: 16px; stroke-width: 2.6; }
.sd-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--line-2); }

.wlist { display: grid; gap: 8px; }
.wrow {
  display: flex;
  align-items: center;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--line);
}
.wrow.today { border-color: rgba(212, 255, 58, .6); }
.wrow.rest .wrow-title { color: var(--muted); }
.wrow-main { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; min-height: 64px; padding: 10px 4px 10px 12px; text-decoration: none; color: var(--text); border-radius: var(--r); }
.wrow-day { display: flex; flex-direction: column; align-items: center; width: 34px; flex: none; }
.wd { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.wn { font-size: 17px; }
.wrow-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.wrow-title { font-weight: 600; line-height: 1.25; }
.wrow-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--text-2); font-size: 13px; }
.dots { display: inline-flex; gap: 3px; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--line-2); }
.dot.on { background: var(--graphic); }
.dot.on.e4 { background: var(--z4); }
.dot.on.e5 { background: var(--z5); }
.tick {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-right: 8px;
  flex: none;
  border-radius: 50%;
  border: 2px solid var(--line-2);
  background: transparent;
  color: transparent;
}
.tick .ic { width: 20px; height: 20px; stroke-width: 2.6; }
.tick:hover { border-color: var(--accent-line); color: var(--accent-line); }
.tick.on { background: var(--volt); border-color: var(--accent-line); color: var(--on-volt); }
.tick-spacer { width: 52px; flex: none; }

/* ------------------------------------------------------------ plan */
.plan-head .ph-goal { font: italic 800 26px/1.05 var(--display); text-transform: uppercase; }
.plan-head .muted { font-size: 14px; margin-top: 4px; }
.ph-stats { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 14px; }
.ph-stats .label { margin-bottom: 2px; }
.ph-stats .big { font-size: 20px; color: var(--accent); }
.plist { display: grid; gap: 8px; }
.prow {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px 12px 10px;
  border-radius: var(--r);
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
}
.prow.past { opacity: .7; }
.prow.current { border-color: var(--accent-line); box-shadow: inset 0 0 0 1px var(--accent-line); opacity: 1; }
.prow-num { font: italic 800 30px/1 var(--display); color: var(--muted); text-align: center; }
.prow.current .prow-num { color: var(--accent); }
.prow-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.prow-top { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 13px; }
.prow-sum { font-weight: 600; font-size: 14px; line-height: 1.3; }
.prow-long { color: var(--text-2); font-size: 13px; }
.prow-km { display: flex; flex-direction: column; align-items: flex-end; font-size: 18px; }
.prow-km .unit { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.prow-done { font-size: 11px; color: var(--accent); margin-top: 2px; white-space: nowrap; }

/* ------------------------------------------------------------ score */
.score-hero { text-align: center; padding: 22px 0 6px; }
.score-big { font: italic 800 clamp(88px, 28vw, 128px)/.9 var(--display); color: var(--accent); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.level { display: flex; justify-content: center; align-items: center; gap: 10px; margin: 12px 0 14px; }
.level-name { font: italic 800 20px/1 var(--display); text-transform: uppercase; }
.score-hero .meter { max-width: 320px; margin: 0 auto; }
.score-hero .muted { margin-top: 8px; }
.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.stat-grid .card { margin: 0; }
.stat { display: flex; flex-direction: column; gap: 6px; }
.stat-ic { color: var(--muted); }
.stat-ic.flame { color: var(--flame); }
.stat-num { font-size: 30px; line-height: 1; }
.stat-num small { font-size: 16px; color: var(--muted); }
.stat-lbl { color: var(--text-2); font-size: 13px; }
.badges { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 108px;
  padding: 12px 8px;
  border-radius: var(--r);
  border: 1.5px dashed var(--line-2);
  color: var(--muted);
  text-align: center;
  font-size: 13px;
  line-height: 1.25;
}
.badge-ic .ic { width: 28px; height: 28px; }
.badge.earned { border: 1.5px solid var(--accent-line); background: rgba(212, 255, 58, .08); color: var(--text); }
.badge.earned .badge-ic { color: var(--accent); }
.legend-list { display: grid; gap: 12px; margin-top: 6px; }
.legend-list li { display: grid; grid-template-columns: 44px 1fr; gap: 10px; align-items: start; color: var(--text-2); font-size: 14px; }
.pts { color: var(--accent); font-size: 14px; display: inline-flex; }
.pts .ic { width: 20px; height: 20px; }

/* ------------------------------------------------------------ strength */
.routine-key {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: var(--volt);
  color: var(--on-volt);
  font: italic 800 20px/1 var(--display);
  flex: none;
}
.routine .card-head { justify-content: flex-start; }
.ex-list li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.ex-list li:first-child { border-top: 0; }
.ex-list .mono { color: var(--text-2); font-size: 13px; white-space: nowrap; }

/* ------------------------------------------------------------ injury mode */
.today-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.today-head .countdown { margin: 0; min-width: 0; }
.inj-chip { gap: 6px; margin: 0; flex: none; color: var(--text-2); }
.inj-chip .ic { width: 16px; height: 16px; }
.inj-banner {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  margin: 2px 0 10px;
  padding: 0 4px 0 0;
  border: 1px solid color-mix(in srgb, var(--z4) 50%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--z4) 10%, var(--surface));
  color: var(--text);
  font-size: 14px;
}
.inj-banner.ret { border-color: var(--accent-line); background: var(--surface); }
.inj-banner-main {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
  min-height: 44px;
  padding: 0 4px 0 14px;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
}
.inj-banner-main .ic { width: 16px; height: 16px; color: var(--z4); }
.inj-banner.ret .inj-banner-main .ic { color: var(--accent); }
.inj-txt { min-width: 0; line-height: 1.3; padding: 4px 0; } /* wraps to two lines rather than hide the day count */
.inj-txt b { font-weight: 700; }
.inj-back {
  flex: none;
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font: 600 14px/1 var(--body);
  text-decoration: none;
}
.inj-back:hover { border-color: var(--muted); }
.tag-inj { background: color-mix(in srgb, var(--z4) 15%, transparent); color: var(--z4); }
.tag-xt { background: var(--line); color: var(--text-2); }
.kicker-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.xt-label { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; color: var(--accent); font-weight: 600; font-size: 14px; }
.xt-label .ic { width: 18px; height: 18px; }
.ex-how { display: block; color: var(--muted); font-size: 13px; line-height: 1.35; margin-top: 2px; text-decoration: none; }
.ex-list .ex-how { margin-top: 3px; }
.rehab-when { margin: -4px 0 6px; }
.fine-print { color: var(--muted); font-size: 12px; margin-top: 10px; }
.section-title + .fine-print { margin-top: -6px; margin-bottom: 4px; }
.routine.rehab .card-head { gap: 10px; }
.routine.rehab .tag { margin-left: auto; }
.link-btn.inline { min-height: 0; padding: 0; font: inherit; color: var(--accent); }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.set-row span { color: var(--text-2); font-size: 15px; }

.sheet-wrap {
  position: fixed;
  z-index: 80;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: color-mix(in srgb, var(--ground) 70%, transparent);
}
.sheet {
  width: 100%;
  max-width: 560px;
  max-height: calc(100dvh - 24px - var(--safe-t));
  overflow-y: auto;
  padding: 14px calc(16px + var(--safe-r)) calc(18px + var(--safe-b)) calc(16px + var(--safe-l));
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 20px 20px 0 0;
  background: var(--surface);
  box-shadow: 0 -10px 40px var(--shadow);
}
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin: 0 -8px 8px 0; }
.sheet .field { margin-bottom: 16px; }
.sheet .chip { min-height: 40px; padding: 0 14px; font-size: 14px; background: var(--surface-2); }
.sheet .chip.on { background: var(--volt); }
.opt-rows { display: grid; gap: 6px; }
.opt-row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  min-height: 52px;
  padding: 8px 14px;
  border: 1px solid var(--line-2);
  border-radius: var(--r);
  background: var(--surface-2);
  color: var(--text);
  text-align: left;
}
.opt-row:hover { border-color: var(--muted); }
.opt-row.on { border-color: var(--accent-line); box-shadow: inset 0 0 0 1px var(--accent-line); background: var(--surface); }
.opt-row.on .opt-name::before { content: "✓ "; color: var(--accent); }
.opt-name { font-weight: 700; font-size: 15px; }
.opt-sub { color: var(--text-2); font-size: 13px; }
.sheet-note { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 12px; color: var(--text-2); font-size: 13px; line-height: 1.4; }
.sheet-note .ic { width: 18px; height: 18px; color: var(--z4); margin-top: 1px; }
.sheet .consent-field { margin-bottom: 4px; }

/* ------------------------------------------------------------ fatigue */
.today-head { flex-wrap: wrap; row-gap: 6px; }
.head-chips { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; margin-left: auto; }
.tag-fat { background: color-mix(in srgb, var(--accent-line) 18%, transparent); color: var(--accent); }
.tag-fat .ic { width: 13px; height: 13px; }
.fat-banner { border-color: var(--accent-line); background: var(--surface); }
.fat-banner .inj-banner-main .ic { color: var(--accent); }
.sug-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 6px 8px;
  margin: 2px 0 10px;
  padding: 8px 8px 8px 14px;
  border: 1px solid var(--accent-line);
  border-radius: var(--r);
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
}
.sug-txt { display: flex; align-items: flex-start; gap: 8px; flex: 1 1 200px; margin: 0; line-height: 1.35; }
.sug-txt .ic { flex: none; width: 16px; height: 16px; margin-top: 2px; color: var(--accent); }
.sug-btns { display: flex; gap: 6px; flex: none; }
.feel { margin-top: 10px; }
.feel-h { margin-bottom: 6px; color: var(--text-2); font-size: 13px; font-weight: 600; }
.feel-row { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
.feel-btn {
  min-height: 40px;
  padding: 2px 2px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--text-2);
  font: 600 12px/1.15 var(--body);
}
.feel-btn:hover { border-color: var(--muted); color: var(--text); }
.feel-btn.on { background: var(--volt); border-color: var(--accent-line); color: var(--on-volt); }
.age-input { max-width: 140px; }

/* ------------------------------------------------------------ exercise demos */
.ex-list li:has(> .ex-row) { padding: 0; }
.ex-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 52px;
  padding: 10px 0;
  border: 0;
  background: none;
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.ex-row .ex-text { flex: 1; min-width: 0; }
.ex-row .mono { color: var(--text-2); font-size: 13px; white-space: nowrap; }
.ex-row:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: var(--r-sm); }
.ex-play {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid var(--accent-line);
  color: var(--accent);
  transition: background-color .15s, color .15s;
}
.ex-play .ic { width: 14px; height: 14px; margin-left: 1px; }
.ex-row:hover .ex-play, .ex-demo:hover .ex-play { background: var(--volt); border-color: var(--volt); color: var(--on-volt); }
.checklist li { display: flex; align-items: center; gap: 2px; }
.checklist .check { flex: 1; min-width: 0; }
.ex-demo {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  margin-right: -8px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
}
.ex-demo:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }

.demo-sheet .sheet-head { margin-bottom: 4px; }
.demo-fig { margin: 2px 0 10px; border: 1px solid var(--line); border-radius: var(--r); background: var(--ground); overflow: hidden; }
.demo-svg svg { display: block; width: 100%; height: auto; max-height: min(42vh, 360px); aspect-ratio: 5 / 4; }
.demo-live { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; min-height: 24px; }
.demo-phase { color: var(--accent); font-weight: 700; font-size: 16px; }
.demo-count { color: var(--text-2); font-size: 13px; white-space: nowrap; }
.demo-dose { display: flex; justify-content: space-between; gap: 12px; margin: 4px 0 8px; color: var(--text-2); font-size: 14px; }
.demo-pos { color: var(--muted); font-size: 13px; }
.demo-cues { display: grid; gap: 6px; margin: 0 0 14px; padding-left: 20px; color: var(--text); font-size: 15px; line-height: 1.4; }
.demo-ctl { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; }
.demo-ctl .btn { min-height: 48px; padding: 0 8px; font-size: 15px; gap: 6px; }
.demo-ctl .btn .ic { width: 18px; height: 18px; }
.demo-ctl .btn.on { border-color: var(--accent-line); color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent-line); }
.dm-f, .dm-b { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-width: 5.5; }
.dm-f { stroke: var(--graphic); }
.dm-t { stroke-width: 6.5; }
.dm-b { stroke: var(--demo-back); }
.dm-hd { fill: var(--ground); stroke: var(--graphic); stroke-width: 3.5; }
.dm-p { fill: var(--surface-2); stroke: var(--line-3); stroke-width: 1.5; }
.dm-d { fill: none; stroke: var(--line-3); stroke-width: 3; stroke-linecap: round; }
.dm-fl { stroke: var(--line-2); stroke-width: 2; }
.dm-band { fill: none; stroke: var(--muted); stroke-width: 1.5; stroke-linejoin: round; }
.dm-dash { fill: none; stroke: var(--muted); stroke-width: 1.2; stroke-dasharray: 3 3; }
.dm-dbar { stroke: var(--muted); stroke-width: 3; }
.dm-dbe { fill: var(--muted); }
.dm-arw { fill: none; stroke: var(--flame); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }

/* ------------------------------------------------------------ settings */
.acct { margin-bottom: 4px; }
.acct strong { color: var(--text); }
.kv { margin: 16px 0 0; display: grid; gap: 8px; }
.kv div { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; color: var(--text-2); }
.danger-zone { border-color: rgba(255, 122, 89, .35); }
.danger-zone .label { color: var(--z5); }

/* ------------------------------------------------------------ toast, banner, net */
.toast {
  position: fixed;
  z-index: 60;
  left: 50%;
  bottom: calc(var(--tabbar-h) + var(--safe-b) + 14px);
  transform: translate(-50%, 20px);
  max-width: min(520px, calc(100% - 32px));
  padding: 12px 18px;
  border-radius: 12px;
  background: var(--text);
  color: var(--ground);
  font-weight: 600;
  font-size: 15px;
  box-shadow: 0 10px 30px var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s, transform .2s;
}
.toast:empty { display: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.update-banner {
  position: fixed;
  z-index: 70;
  top: calc(8px + var(--safe-t));
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 24px);
  max-width: 536px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 8px 8px 16px;
  border-radius: 14px;
  background: var(--volt);
  color: var(--on-volt);
  font-weight: 700;
  font-size: 15px;
  box-shadow: 0 10px 30px var(--shadow);
}
.update-banner .btn { min-height: 40px; }

.net {
  position: fixed;
  z-index: 40;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(var(--tabbar-h) + var(--safe-b) + 8px);
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--z4);
  color: var(--z4);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

@media (min-width: 600px) {
  .screen { border-left: 1px solid var(--line); border-right: 1px solid var(--line); }
}
@media (max-width: 374px) {
  .display { font-size: 30px; }
  .actions { grid-template-columns: 1fr; }
  .badges { grid-template-columns: repeat(2, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
