/* Ravelwise: the app's own variable names, each mapped onto a token in tokens.css (loaded first). No hex here: both
   themes (OS preference and [data-theme]) follow tokens.css. */
:root {
  /* grounds and text */
  --bg: var(--surface-100); --panel: var(--surface-000); --panel-2: var(--surface-100); --well: var(--surface-200);
  --fg: var(--ink); --muted: var(--ink-muted); --faint: var(--ink-muted); --grid: var(--line);
  /* the UI accent is ink (primary buttons, the current series, selected things); accent text is marigold-ink */
  --accent: var(--ink); --accent-fg: var(--ink-inverse); --accent-soft: var(--line); --link: var(--marigold-ink);
  /* charts: usual range and comparison are neutral (slate), the forecast and events are marigold */
  --band: var(--line); --band-strong: var(--line-strong); --expected: var(--slate);
  --forecast: var(--marigold); --forecast-band: var(--marigold-soft); --period-bg: var(--surface-100);
  --event: var(--marigold); --event-ink: var(--marigold-ink); --event-bg: var(--marigold-soft);
  /* states: good/bad tints (up-soft/down-soft) with up/down text; marigold-soft only for things that need an answer */
  --ok-bg: var(--up-soft); --ok-fg: var(--up); --warn-bg: var(--marigold-soft); --warn-fg: var(--marigold-ink);
  --bad-bg: var(--down-soft); --bad-fg: var(--down);
  --chip: var(--surface-200); --shadow: none; --pop-shadow: var(--shadow-card);
  /* type scale (px): body 15, body-sm 13, label 12, title 17, headline 28, figure-xl 36 */
  --fs-xs: 12px; --fs-sm: 13px; --fs-md: 15px; --fs-lg: 17px; --fs-xl: 28px; --fs-num: 36px;
  /* spacing (4px base) and shape */
  --s1: var(--space-1); --s2: var(--space-2); --s3: var(--space-3); --s4: var(--space-4); --s5: var(--space-6); --s6: var(--space-8);
  --r: var(--radius-lg); --r-sm: var(--radius-md);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { color-scheme: dark; } }
:root[data-theme="dark"] { color-scheme: dark; }
/* the logo has a light and a reversed file: show the one for the theme */
.logo-dark { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .logo-light { display: none; } :root:not([data-theme="light"]) .logo-dark { display: inline-block; } }
:root[data-theme="dark"] .logo-light { display: none; } :root[data-theme="dark"] .logo-dark { display: inline-block; }

/* base */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 var(--fs-md)/24px var(--font-sans);
  font-variant-numeric: tabular-nums; overflow-wrap: break-word; -webkit-font-smoothing: antialiased; }
a { color: var(--fg); text-decoration: underline; text-decoration-color: var(--line-strong); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
/* headlines: Fraunces for the page title and the one headline in a card; everything else is Geist */
h1 { font: 500 var(--fs-xl)/34px var(--font-display); letter-spacing: -.01em; margin: 0 0 var(--s2); }
h2 { font: 600 var(--fs-lg)/24px var(--font-sans); margin: var(--s6) 0 var(--s3); }
h3 { font: 600 var(--fs-md)/22px var(--font-sans); margin: 0 0 var(--s2); }
.sub { color: var(--muted); margin: 0 0 var(--s5); max-width: 72ch; }
.muted { color: var(--muted); } .small { font-size: var(--fs-sm); line-height: 20px; } .xs { font-size: var(--fs-xs); line-height: 16px; }
.up { color: var(--up); } .down { color: var(--down); }
td.num, span.num, div.num, .mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.nowrap { white-space: nowrap; }
.label, .eyebrow { font: 600 var(--fs-xs)/16px var(--font-sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
summary { cursor: pointer; color: var(--muted); }
summary:hover { color: var(--fg); }
details[open] > summary { margin-bottom: var(--s2); }
/* links that lead to evidence or the next step: ghost buttons in marigold-ink */
.go, .section-head a, .feed-act a, .card-foot a { color: var(--link); font-weight: 600; text-decoration: none; }
.go:hover, .section-head a:hover, .feed-act a:hover, .card-foot a:hover { text-decoration: underline; }

/* header */
header.top { display: flex; align-items: center; gap: var(--s4); padding: var(--s2) var(--s5); background: var(--panel); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; min-height: 56px; }
header.top .brand { display: inline-flex; align-items: center; flex: none; text-decoration: none; padding: 4px 0; }
header.top .brand img { height: 24px; width: auto; display: block; }
header.top .brand img.logo-dark { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) header.top .brand img.logo-light { display: none; } :root:not([data-theme="light"]) header.top .brand img.logo-dark { display: block; } }
:root[data-theme="dark"] header.top .brand img.logo-light { display: none; } :root[data-theme="dark"] header.top .brand img.logo-dark { display: block; }
header.top nav { display: flex; gap: 2px; align-items: center; }
header.top nav a { padding: 6px 10px; border-radius: var(--r-sm); color: var(--muted); white-space: nowrap; font-size: var(--fs-sm); font-weight: 500; text-decoration: none; }
header.top nav a:hover { color: var(--fg); background: var(--chip); }
header.top nav a.on { background: var(--chip); color: var(--fg); font-weight: 600; }
header.top details.more { position: relative; }
header.top details.more summary { list-style: none; cursor: pointer; padding: 6px 10px; border-radius: var(--r-sm); color: var(--muted); font-size: var(--fs-sm); font-weight: 500; white-space: nowrap; }
header.top details.more summary::-webkit-details-marker { display: none; }
header.top details.more summary::after { content: " ▾"; font-size: .8em; }
header.top details.more.on summary, header.top details.more summary:hover { background: var(--chip); color: var(--fg); }
header.top details.more .menu { position: absolute; top: calc(100% + 4px); left: 0; min-width: 190px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 4px; display: grid; box-shadow: var(--pop-shadow); z-index: 10; }
header.top details.more .menu a { padding: 7px 10px; }
header.top select { margin-left: auto; }
main { max-width: 1180px; margin: 0 auto; padding: var(--s6) var(--s5) var(--s16, 64px); }

/* layout */
.grid { display: grid; gap: var(--s4); grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.grid.wide { grid-template-columns: repeat(auto-fill, minmax(min(340px, 100%), 1fr)); gap: var(--s5); }
.tiles { display: grid; gap: var(--s4); grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); }
.row { display: flex; gap: var(--s2) var(--s3); align-items: center; flex-wrap: wrap; }
.stack > * + * { margin-top: var(--s3); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s3); margin: var(--s12, 48px) 0 var(--s4); flex-wrap: wrap; }
.section-head h2 { margin: 0; }
.section-head a { font-size: var(--fs-sm); }

/* cards: radius-lg with a line border; no shadow (shadow-card is for the Why card and popovers) */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: var(--s5); min-width: 0; }
.card > h3:first-child { margin-top: 0; }
.card.quiet { background: var(--panel-2); }
.card.attention { border-left: 3px solid var(--event); }
.card-foot { margin: var(--s3) 0 0; font-size: var(--fs-sm); }

/* metric tile (MetricTile): eyebrow naming the metric and its window, figure-xl value, sparkline, delta + comparison */
.tile { display: grid; gap: var(--s2); align-content: start; color: inherit; position: relative; padding: var(--s4) var(--s5) var(--s4) var(--s4); text-decoration: none; }
a.tile:hover { border-color: var(--line-strong); }
.tile .label { font: 600 var(--fs-xs)/16px var(--font-sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.tile .label .dim { font-weight: 600; }
.tile .value { font: 500 var(--fs-num)/40px var(--font-mono); letter-spacing: -.02em; font-variant-numeric: tabular-nums; color: var(--fg); }
.tile .delta { font-size: var(--fs-sm); line-height: 20px; color: var(--muted); }
.tile .state { align-self: flex-start; }
.tile .spark { display: block; width: 100%; height: 32px; overflow: visible; }
.spark polyline { fill: none; stroke: var(--ink); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.spark .dot { fill: none; stroke: var(--marigold); stroke-width: 6; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.tile .usual { font-size: var(--fs-xs); color: var(--muted); }

/* chips and status */
.chip { display: inline-block; font-size: var(--fs-xs); line-height: 20px; padding: 0 8px; border-radius: var(--radius-pill); background: var(--chip); color: var(--muted); white-space: nowrap; vertical-align: 1px; font-weight: 500; text-decoration: none; }
.card .chip, .chips .chip { white-space: normal; }
.chips .chip, .list .what, .flag a { overflow-wrap: anywhere; }
.chip.ok { background: var(--ok-bg); color: var(--ok-fg); } .chip.warn { background: var(--warn-bg); color: var(--warn-fg); } .chip.bad { background: var(--bad-bg); color: var(--bad-fg); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.count { display: inline-block; min-width: 1.6em; padding: 0 6px; border-radius: var(--radius-pill); background: var(--chip); font: 600 var(--fs-sm)/20px var(--font-mono); text-align: center; }
.count.hot { background: var(--warn-bg); color: var(--warn-fg); }
/* Annotation chip: a marigold dot on marigold-soft, for changes (events) */
.anno { display: inline-flex; align-items: center; gap: var(--s2); background: var(--marigold-soft); color: var(--ink); border-radius: var(--radius-pill); padding: 2px 10px 2px 6px; font-size: var(--fs-sm); line-height: 20px; }
.anno::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--marigold); box-shadow: 0 0 0 2px var(--surface-000); }
.anno.pending::before { background: transparent; box-shadow: inset 0 0 0 2px var(--marigold); }

/* tables: Geist labels, Geist Mono figures */
table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); line-height: 20px; }
th, td { text-align: left; padding: var(--s2) var(--s3); border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child > td { border-bottom: 0; }
th { color: var(--muted); font-weight: 600; font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .06em; }
td.num, th.num { text-align: right; white-space: nowrap; }
.table-wrap { overflow-x: auto; }
.card.table-wrap { padding: var(--s2) var(--s4); }

/* lists inside cards */
.list { list-style: none; margin: 0; padding: 0; }
.list > li { padding: var(--s3) 0; border-bottom: 1px solid var(--line); display: flex; gap: var(--s3); align-items: flex-start; }
.list > li:last-child { border-bottom: 0; }
.list .when { color: var(--muted); font: 500 var(--fs-sm)/20px var(--font-mono); min-width: 4.2em; white-space: nowrap; padding-top: 2px; }
.list .what { flex: 1; min-width: 0; }
.list .acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }

/* forms and buttons (Button): ink primary, secondary with a line-strong border, ghost in marigold-ink */
form.inline { display: inline; }
input, select, textarea, button { font: inherit; color: var(--fg); }
input[type=text], input[type=number], input[type=email], input[type=url], input[type=date], input[type=month], input[type=password], input[type=search], select, textarea {
  background: var(--panel); border: 1px solid var(--line-strong); border-radius: var(--r-sm); padding: 7px 10px; max-width: 100%; min-height: 40px; font-size: var(--fs-sm); }
textarea { width: 100%; min-height: 80px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 1px; }
button, .btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--s2); background: transparent; border: 1px solid var(--line-strong); border-radius: var(--r-sm);
  padding: 8px 14px; min-height: 40px; cursor: pointer; color: var(--fg); font: 600 14px/20px var(--font-sans); text-decoration: none; }
button:hover, .btn:hover { background: var(--well); }
button:focus-visible, .btn:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
button.primary, .btn.primary { background: var(--ink); border-color: var(--ink); color: var(--ink-inverse); }
button.primary:hover, .btn.primary:hover { background: var(--ink); opacity: .88; }
button.accent, .btn.accent { background: var(--marigold); border-color: var(--marigold); color: var(--on-marigold); }
button.accent:hover, .btn.accent:hover { background: var(--marigold); opacity: .9; }
button.ghost, .btn.ghost { background: transparent; border-color: transparent; color: var(--link); padding-inline: var(--s2); }
button.small, .btn.small { padding: 4px 12px; min-height: 32px; font-size: var(--fs-sm); }
.field { display: flex; flex-direction: column; gap: var(--s1); margin-bottom: var(--s3); } .field label { font-size: var(--fs-sm); color: var(--muted); font-weight: 500; }
.big-tap { width: 100%; min-height: 48px; font-size: 16px; }
.reply-top { margin-bottom: var(--s1); }

/* tabs (filter pills) */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 var(--s4); align-items: center; }
.tabs a { padding: 4px 12px; border-radius: var(--radius-pill); background: transparent; border: 1px solid var(--line); color: var(--fg); font-size: var(--fs-sm); line-height: 22px; white-space: nowrap; text-decoration: none; }
.tabs a:hover { background: var(--well); }
.tabs a.on { background: var(--ink); border-color: var(--ink); color: var(--ink-inverse); }
.tabs .sep { width: 1px; height: 18px; background: var(--line-strong); margin: 0 4px; }

/* charts: a surface-200 well, no gridlines, one line-strong baseline, labels on the axes */
[data-chart] { background: var(--well); border-radius: var(--r-sm); padding: var(--s3) var(--s3) var(--s1); }
.card > [data-chart]:first-child { margin: 0; }
.tip { display: none; position: absolute; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 8px 10px; font-size: var(--fs-xs); pointer-events: none;
  box-shadow: var(--pop-shadow); max-width: 240px; z-index: 3; line-height: 1.45; }
svg text.axis { fill: var(--muted); font: 500 11px var(--font-mono); font-variant-numeric: tabular-nums; }
svg text.sel-label { fill: var(--fg); font: 600 11px var(--font-mono); }
svg .tick-hit { cursor: pointer; }
.legend { display: flex; gap: var(--s1) var(--s4); font-size: var(--fs-xs); color: var(--muted); flex-wrap: wrap; margin-top: var(--s3); }
.legend i { display: inline-block; width: 16px; height: 2px; vertical-align: middle; margin-right: 6px; border-radius: 1px; }
.legend i.cur { background: var(--ink); height: 2px; }
.legend i.cmp { background: none; border-top: 2px dashed var(--slate); height: 0; }
.legend i.fc { background: none; border-top: 2px dashed var(--forecast); height: 0; }
.legend i.pin { width: 10px; height: 10px; border-radius: 50%; background: var(--marigold); }
.legend i.dot { width: 8px; height: 8px; border-radius: 50%; background: linear-gradient(90deg, var(--up) 50%, var(--down) 50%); }
.legend i.band { height: 10px; background: var(--band); }
.legend i.fband { height: 10px; background: var(--forecast-band); }
.legend .long { display: inline; }
@media (max-width: 640px) { .legend .long { display: none; } }

/* overview: what needs you */
.needs { display: grid; gap: var(--s4); grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); }
.needs h3 { display: flex; align-items: center; gap: var(--s2); }
.needs .all-clear { color: var(--muted); margin: 0; }

/* timeline day panel */
.day-head { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); flex-wrap: wrap; margin: var(--s6) 0 var(--s3); }
.day-head h2 { margin: 0; }
.day-nav { display: flex; gap: 6px; }

/* flags grouped by day */
.day-group { margin-bottom: var(--s4); }
.day-group > h3 { font: 600 var(--fs-xs)/16px var(--font-sans); color: var(--muted); margin: 0 0 var(--s2); text-transform: uppercase; letter-spacing: .06em; }
.flag { padding: var(--s3) 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: var(--s2) var(--s4); align-items: start; }
.flag:last-child { border-bottom: 0; }
.flag .cands { font-size: var(--fs-sm); color: var(--muted); margin-top: var(--s1); }
.flag .acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.fold > summary { padding: var(--s2) 0; font-size: var(--fs-sm); }

/* levers */
.lever { display: flex; flex-direction: column; gap: var(--s1); }
.lever .lever-head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s2); }
.lever .lever-head h3 { margin: 0; }
.lever .big { font: 500 30px/36px var(--font-mono); letter-spacing: -.02em; margin-top: var(--s2); }
.lever .big .unit { font-size: var(--fs-md); font-weight: 500; color: var(--muted); letter-spacing: 0; }
.lever .headline { font-size: var(--fs-sm); color: var(--fg); }
.lever .sure { font-size: var(--fs-sm); color: var(--muted); display: flex; align-items: center; gap: 6px; }
.lever .sure .meter { display: inline-flex; gap: 2px; }
.lever .sure .meter i { width: 6px; height: 12px; border-radius: 2px; background: var(--line); }
.lever .sure .meter i.on { background: var(--ink); }
.lever details { margin-top: var(--s2); font-size: var(--fs-sm); }
.lever details p { margin: 0 0 6px; }
.range { position: relative; height: 10px; background: var(--chip); border-radius: 99px; margin: var(--s3) 0 var(--s1); }
.range .iqr { position: absolute; top: 0; bottom: 0; background: var(--line-strong); border-radius: 99px; }
.range .med { position: absolute; top: -3px; width: 3px; height: 16px; background: var(--ink); border-radius: 2px; }
.range .zero { position: absolute; top: -3px; width: 1px; height: 16px; background: var(--muted); }
.glossary dt { font-weight: 650; } .glossary dd { margin: 0 0 var(--s2); color: var(--muted); }

/* event page: analysis results as rows that stack on mobile */
.results { display: grid; gap: 0; }
.res { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr) minmax(0, 1.2fr) minmax(0, 1.3fr) auto; gap: var(--s3); padding: var(--s3) 0; border-bottom: 1px solid var(--line); align-items: start; }
.res:last-child { border-bottom: 0; }
.res.head { color: var(--muted); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .04em; font-weight: 600; padding: var(--s1) 0; }
.res .eff { font-weight: 650; }
@media (max-width: 640px) {
  .res { grid-template-columns: 1fr 1fr; gap: var(--s1) var(--s3); }
  .res.head { display: none; }
  .res > .m { grid-column: 1 / -1; }
  .res > [data-l]::before { content: attr(data-l); display: block; font-size: var(--fs-xs); color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
}

/* misc */
.flash { background: var(--ok-bg); color: var(--ok-fg); padding: 10px 14px; border-radius: var(--r-sm); margin-bottom: var(--s4); }
.reply { max-width: 520px; margin: 0 auto; }
.reply .card { padding: 18px; }
pre.mail { white-space: pre-wrap; font: 13px/1.5 var(--font-mono); background: var(--chip); padding: var(--s3); border-radius: var(--r-sm); overflow-x: auto; }
.foot { margin-top: var(--s6); padding-top: var(--s3); border-top: 1px solid var(--line); font-size: var(--fs-xs); color: var(--muted); }

/* mobile */
@media (max-width: 640px) {
  :root { --fs-num: 28px; --fs-xl: 24px; }
  main { padding: var(--s5) var(--s4) 48px; }
  header.top { padding: 6px var(--s3); gap: var(--s2); overflow-x: auto; position: static; scrollbar-width: none; }
  header.top::-webkit-scrollbar { display: none; }
  header.top details.more .menu { position: fixed; top: 60px; left: 8px; right: 8px; }
  header.top select { margin-left: var(--s2); max-width: 140px; }
  h2 { margin-top: var(--s5); }
  .section-head, .day-head { margin-top: var(--s5); }
  .tiles { grid-template-columns: 1fr 1fr; gap: var(--s3); }
  .tile { padding: var(--s3); }
  .tile .value { line-height: 32px; }
  th, td { padding: 6px 5px; }
  .card { padding: var(--s4); }
  .flag { grid-template-columns: 1fr; }
  .flag .acts { justify-content: flex-start; }
  /* tables that become stacked rows */
  table.stack, table.stack tbody, table.stack tr, table.stack td { display: block; width: 100%; }
  table.stack tr:first-child:has(th) { display: none; }
  table.stack tr { padding: var(--s2) 0; border-bottom: 1px solid var(--line); }
  table.stack tr:last-child { border-bottom: 0; }
  table.stack td { border: 0; padding: 2px 0; text-align: left; }
  table.stack td.num { text-align: left; }
  table.stack td.inline-sm { display: inline-block; width: auto; margin-right: var(--s2); }
}
.answer p { margin: 0 0 10px; line-height: 1.6; }
table.weeks td { padding: 3px 6px; border: 0; }
.wbar { position: relative; height: 12px; background: var(--chip); border-radius: 99px; }
.wbar .zero { position: absolute; left: 50%; top: -2px; bottom: -2px; width: 1px; background: var(--muted); }
.wbar .pos, .wbar .neg { position: absolute; top: 2px; height: 8px; border-radius: 4px; opacity: .45; }
.wbar .pos { background: var(--up); } .wbar .neg { background: var(--down); }
.wbar .clear { opacity: 1; }
tr.muted .wbar span { opacity: .2; }
.syncbar { max-width: 1180px; margin: 10px auto 0; padding: 0 16px; display: flex; flex-direction: column; gap: 6px; }
.syncitem { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: var(--fs-sm); padding: 8px 12px; border-radius: var(--r-sm); background: var(--chip); border: 1px solid var(--line); }
.syncitem .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); flex: none; }
.syncitem.running .dot, .syncitem.queued .dot { background: var(--accent); animation: syncpulse 1.2s ease-in-out infinite; }
.syncitem.ready { background: var(--ok-bg); color: var(--ok-fg); } .syncitem.ready .dot { background: var(--up); }
.syncitem.error, .syncitem.action { background: var(--warn-bg); color: var(--warn-fg); } .syncitem.error .dot { background: var(--down); }
.syncitem a { margin-left: auto; font-weight: 600; }
.syncprog { flex: 1 1 120px; max-width: 220px; height: 6px; background: var(--line); border-radius: 99px; overflow: hidden; }
.syncprog span { display: block; height: 100%; background: var(--accent); transition: width .4s; }
@keyframes syncpulse { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .syncitem .dot { animation: none !important; } }
.syncitem a { margin-left: auto; }
.syncx { margin: 0 0 0 auto; } .syncitem a + .syncx { margin-left: 4px; }
.syncx button { background: none; border: 0; padding: 2px 8px; font-size: 18px; line-height: 1; color: inherit; opacity: .6; cursor: pointer; min-height: 32px; min-width: 32px; }
.syncx button:hover { opacity: 1; }

/* attribution */
.attr-headline p { margin: 0; font-size: var(--fs-md); }
.warn-edge { border-left: 3px solid var(--warn-fg); background: var(--warn-bg); margin-bottom: var(--s3); }
.bad-edge { border-left: 3px solid var(--bad-fg); background: var(--bad-bg); margin-bottom: var(--s3); }
.attr table { min-width: 760px; }
.attr th.grp { text-align: center; border-bottom: 1px solid var(--line); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.attr .sticky { position: sticky; left: 0; background: var(--panel); z-index: 1; text-align: left; }
.attr tr.nodir th, .attr tr.nodir td { color: var(--muted); }
.attr tfoot th, .attr tfoot td { border-top: 1px solid var(--line-strong); font-weight: 600; }
.delta-chip { display: inline-block; min-width: 3ch; padding: 0 8px; border-radius: var(--radius-sm); border: 1px solid var(--line); font: 500 var(--fs-sm)/20px var(--font-mono); font-variant-numeric: tabular-nums; }
.delta-chip.pos { background: var(--up-soft); border-color: transparent; color: var(--up); }
.delta-chip.neg { background: var(--panel); color: var(--muted); }
.attr td.bars { min-width: 150px; }
.attr .bar { display: block; height: 6px; border-radius: 3px; margin: 2px 0; min-width: 1px; }
.bar.lt, .sw.lt { background: var(--slate); }
.bar.lnd, .sw.lnd { background: var(--accent); }
.sw { display: inline-block; width: 9px; height: 9px; border-radius: 2px; vertical-align: -1px; margin: 0 2px 0 6px; }
table.compact td, table.compact th { padding: 5px 8px; font-size: var(--fs-sm); }
.camp { overflow-wrap: break-word; }
.attr-pair { display: grid; gap: var(--s4); grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); }
.attr-pair .card { min-width: 0; overflow-x: auto; }
.attr tbody th, .attr tfoot th { text-transform: none; font-size: inherit; color: var(--fg); font-weight: 500; letter-spacing: 0; }
.attr tbody tr.nodir th { color: var(--muted); }
.attr .chip { white-space: nowrap; }
.card.table-wrap.attr { padding-left: 0; padding-right: 0; }
.attr th:first-child, .attr td:first-child { padding-left: var(--s3); }
.attr th:last-child, .attr td:last-child { padding-right: var(--s3); }
.attr .sticky { box-shadow: 1px 0 0 var(--line); }
table.channels td { vertical-align: top; }
@media (max-width: 700px) {
  .wide-only { display: none; } .attr table { min-width: 560px; }
  .attr-pair { grid-template-columns: minmax(0, 1fr); }
  table.channels, table.channels tbody { display: block; }
  table.channels tr { display: grid; grid-template-columns: 1fr auto auto; gap: 4px 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
  table.channels tr:first-child { display: none; }
  table.channels td { border: 0; padding: 0; }
  table.channels td:last-child { grid-column: 1 / -1; }
  header.top { flex-wrap: nowrap; overflow-x: auto; }
  header.top nav { flex-wrap: nowrap; }
  header.top form.acct { display: none; }
  .onb-rail li:not(.on) a { padding-right: 4px; font-size: 0; gap: 0; }
  .onb-rail li:not(.on) .dot { font-size: 11px; }
}
tr.doubt td { background: var(--warn-bg); }
form.inline { display: inline-flex; gap: 6px; align-items: center; margin: 0; }
a.button { display: inline-flex; align-items: center; gap: var(--s2); padding: 9px 16px; border-radius: var(--r-sm); border: 1px solid var(--line-strong); background: transparent; color: var(--fg); font: 600 14px/20px var(--font-sans); text-decoration: none; }
a.button.primary { background: var(--ink); border-color: var(--ink); color: var(--ink-inverse); }
a.button:hover { background: var(--well); } a.button.primary:hover { background: var(--ink); opacity: .88; }

/* onboarding */
.onb-narrow { max-width: 860px; }
.onb-rail { list-style: none; padding: 0; margin: 0 0 var(--s5); display: flex; flex-wrap: wrap; gap: 4px 6px; counter-reset: s; }
.onb-rail a { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border-radius: 99px; background: var(--chip); color: var(--muted); font-size: var(--fs-sm); }
.onb-rail a:hover { text-decoration: none; color: var(--fg); }
.onb-rail .dot { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--panel); font-size: 11px; font-weight: 650; }
.onb-rail .is-done .dot { background: var(--ok-bg); color: var(--ok-fg); }
.onb-rail .on a { background: var(--fg); color: var(--panel); }
.onb-rail .on .dot { color: var(--on-marigold); background: var(--marigold); }
.onb-guess { font: 500 var(--fs-xl)/34px var(--font-display); letter-spacing: -.01em; margin: 4px 0 8px; }
form.vstack { display: grid; gap: var(--s3); }
fieldset { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; }
fieldset legend { margin-bottom: 4px; color: var(--muted); }
label.opt { font-size: var(--fs-sm); display: flex; flex-basis: 100%; gap: 6px; align-items: center; }
button.link { background: none; border: 0; color: var(--link); padding: 0; min-height: 0; font: inherit; font-weight: 600; cursor: pointer; }
button.link:hover { text-decoration: underline; }
.progress { height: 6px; background: var(--chip); border-radius: 3px; overflow: hidden; margin: var(--s3) 0; }
.progress.indeterminate i { display: block; height: 100%; width: 30%; background: var(--accent); border-radius: 3px; animation: onb-slide 1.4s ease-in-out infinite; }
@keyframes onb-slide { from { transform: translateX(-100%); } to { transform: translateX(340%); } }
@media (prefers-reduced-motion: reduce) { .progress.indeterminate i { animation: none; width: 100%; opacity: .4; } }

/* home feed */
.feed { display: grid; gap: var(--s4); }
/* a feed card is a compact Why card: one Fraunces line (what), the why in plain text, the next step on marigold-soft */
.feed-card { display: grid; gap: var(--s3); }
.feed-card .eyebrow { display: flex; align-items: center; gap: var(--s2); }
.feed-card .eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); }
.feed-card.tone-bad .eyebrow::before { background: var(--down); } .feed-card.tone-ok .eyebrow::before { background: var(--up); }
.feed-card.tone-warn .eyebrow::before { background: var(--marigold); } .feed-card.tone-info .eyebrow::before { background: var(--slate); }
.feed-card h3 { margin: 0; font: 500 22px/28px var(--font-display); letter-spacing: -.01em; }
.feed-card p { margin: 0; }
.feed-card .why-text { color: var(--muted); max-width: 80ch; }
.feed-act { font-size: var(--fs-sm); line-height: 22px; background: var(--marigold-soft); color: var(--ink); border-radius: var(--r-sm); padding: var(--s2) var(--s4); }
.feed-act b { font-weight: 600; }
.feed-act a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--marigold-ink); }
.plan-steps { padding-left: 20px; display: grid; gap: var(--s3); }
.plan-steps li > span { display: block; margin-top: 4px; }

/* plan */
svg.stack { width: 100%; height: 200px; display: block; }
.stack-axis { display: grid; grid-template-columns: repeat(12, 1fr); font-size: var(--fs-xs); color: var(--muted); text-align: center; margin-top: 4px; }
.lever-card .big { font: 500 24px/30px var(--font-mono); margin: 2px 0 6px; }
input.num-in { width: 8.5em; text-align: right; font-variant-numeric: tabular-nums; }
.legend.sq i { height: 10px; width: 10px; }
.auth { max-width: 420px; margin: 6vh auto 0; }
.auth form .field input { width: 100%; }
header.top form.acct { gap: 8px; white-space: nowrap; }
.sub-conn { border-top: 1px solid var(--line); padding-top: var(--s2); margin-top: var(--s3); }
.affix { display: inline-flex; align-items: stretch; max-width: 100%; }
.affix input { border-top-right-radius: 0; border-bottom-right-radius: 0; min-width: 0; flex: 1 1 12em; }
.affix-end { display: inline-flex; align-items: center; padding: 0 10px; border: 1px solid var(--line-strong); border-left: 0; border-radius: 0 var(--r-sm) var(--r-sm) 0; background: var(--chip); color: var(--muted); font-size: var(--fs-sm); white-space: nowrap; }
.onb-progress { margin: 0 0 var(--s5); }
.onb-progress-head { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; margin-bottom: 6px; }
.onb-progress-head .xs { margin-left: auto; }
.onb-bar { position: relative; height: 6px; background: var(--chip); border-radius: 3px; overflow: hidden; margin-bottom: 10px; }
.onb-bar i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--line-strong); }
.onb-bar b { position: absolute; top: 0; bottom: 0; background: var(--accent); }
.onb-rail li.locked > span { opacity: .45; cursor: not-allowed; }
.onb-rail li > span { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border-radius: 99px; background: var(--chip); color: var(--muted); font-size: var(--fs-sm); }
.onb-rail li.on > span { background: var(--fg); color: var(--panel); }

/* status pattern (templates/_status.html) */
.st { position: relative; display: inline-flex; vertical-align: middle; }
.st-btn { display: inline-flex; align-items: center; gap: 6px; padding: 2px 8px 2px 4px; border: 0; border-radius: 99px; background: transparent; color: inherit; font: inherit; cursor: pointer; }
.st-compact .st-btn { padding: 4px; }
.st-btn:hover, .st-btn[aria-expanded="true"] { background: var(--chip); }
.st-btn:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.st-ico { width: 18px; height: 18px; flex: none; }
.st-syncing .st-ico, .st-pending.st-syncing > .st-ico { color: var(--accent); }
.st-computing .st-ico, .st-pending.st-computing > .st-ico { color: var(--accent); }
.st-queued .st-ico, .st-pending.st-queued > .st-ico { color: var(--muted); }
.st-ready .st-ico { color: var(--up); }
.st-error .st-ico, .st-pending.st-error > .st-ico { color: var(--down); }
.st-spin { transform-origin: 10px 10px; animation: st-rot 1.1s linear infinite; }
@keyframes st-rot { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .st-spin { animation: none; } }
.st-tip { position: absolute; z-index: 20; top: calc(100% + 6px); right: 0; width: max-content; max-width: min(320px, 86vw); padding: 10px 12px; background: var(--panel); color: var(--fg); border: 1px solid var(--line-strong); border-radius: var(--r-sm); box-shadow: var(--pop-shadow); font-size: var(--fs-sm); display: grid; gap: 4px; text-align: left; white-space: normal; }
.st-tip[hidden] { display: none; }
.st-tip-head { display: inline-flex; align-items: center; gap: 6px; }
.st-tip-line a { white-space: nowrap; }
.st-tip ul { margin: 2px 0 0; padding-left: 0; list-style: none; display: grid; gap: 6px; }
.st-tip li { display: flex; gap: 6px; align-items: flex-start; }
.st-tip li .st-ico { width: 16px; height: 16px; margin-top: 1px; }
.st-pending { display: flex; gap: 12px; align-items: flex-start; }
.st-pending > .st-ico { width: 28px; height: 28px; margin-top: 2px; }
.st-pending p { margin: 4px 0 0; }
.st-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--muted); margin: 0 0 var(--s4); }
.st-legend span { display: inline-flex; gap: 5px; align-items: center; }
.st-legend .st-ico { width: 16px; height: 16px; }
.st-legend span:nth-child(-n+2) .st-ico { color: var(--accent); } .st-legend span:nth-child(4) .st-ico { color: var(--up); } .st-legend span:nth-child(5) .st-ico { color: var(--down); }
header.top .hdr-status { margin-left: auto; display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 32px; }
header.top .hdr-status + select { margin-left: 0; }
.st-teach { border-top: 1px solid var(--line); margin-top: var(--s3); padding-top: var(--s3); }
.st-teach p { margin: 0 0 6px; }
.st-teach .st-legend { margin: 0; }
/* the whole card is the link (its heading's link stretches over it) */
.feed-card { position: relative; }
.feed-card a.stretch { color: inherit; text-decoration: none; }
.feed-card a.stretch::after { content: ""; position: absolute; inset: 0; border-radius: var(--r); }
.feed-card a.stretch:hover { text-decoration: underline; }
.feed-card .feed-act a { position: relative; z-index: 1; }
.section-head .st { margin-left: 8px; font-size: var(--fs-sm); font-weight: 400; }
header.top .menu-signout { display: none; border-top: 1px solid var(--line); margin-top: 4px; padding-top: 4px; }
header.top .menu-signout button { padding: 7px 10px; text-align: left; width: 100%; }
@media (max-width: 700px) { header.top .menu-signout { display: block; } }
/* card hover and keyboard focus cover the whole card */
.feed-card:has(a.stretch:hover) { border-color: var(--line-strong); }
.feed-card a.stretch:focus-visible { outline: none; }
.feed-card a.stretch:focus-visible::after { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
@media (max-width: 700px) { header.top .hdr-status .st-tip { position: fixed; top: 52px; right: 8px; left: auto; } }

/* date period picker (templates/_period.html) */
.period { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; margin: 0 0 var(--s4); }
.period select { min-width: 0; }
.period-custom { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.period-custom[hidden] { display: none; }
.period-span { flex-basis: 100%; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.dlt { font-weight: 600; font-variant-numeric: tabular-nums; }
.dlt.good { color: var(--up); background: var(--up-soft); border-color: transparent; } .dlt.bad { color: var(--down); background: var(--down-soft); border-color: transparent; } .dlt.flat { color: var(--muted); }
.tile-note { font-size: var(--fs-xs); color: var(--event-ink); margin: 0; line-height: 16px; }

/* tag chooser */
.tag-cols { display: grid; gap: var(--s3); grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); }
.tag-col { margin: 0; }
.tag-col legend { padding: 0 4px; }
.tag-list { max-height: 360px; overflow-y: auto; display: grid; gap: 2px; padding-right: 4px; }
.tag-row { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; padding: 4px 6px; border-radius: var(--r-sm); font-size: var(--fs-sm); cursor: pointer; }
.tag-row:hover { background: var(--chip); }
.tag-name { overflow-wrap: anywhere; }
.tag-num { color: var(--muted); font-size: var(--fs-xs); white-space: nowrap; font-variant-numeric: tabular-nums; }
.seg-row th, .seg-row td { background: var(--well); }

/* the shared date bar under the header */
.datebar { position: sticky; top: 57px; z-index: 4; background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px var(--s5); display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; }
.datebar .period { margin: 0; }
.datebar .period-span { flex-basis: auto; }
.datebar-note { flex-basis: 100%; }
@media (max-width: 700px) { .datebar { position: static; padding: 8px var(--s3); } .datebar .period-span { flex-basis: 100%; } }

/* pacing panel */
.pacing { margin-bottom: var(--s4); }
.pacing-head { display: flex; flex-wrap: wrap; gap: var(--s3) var(--s6); align-items: flex-end; margin-bottom: var(--s3); }
.pacing-value { font: 500 var(--fs-num)/40px var(--font-mono); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.pacing-value.soft { color: var(--muted); }
.pacing-rows { display: grid; gap: 10px; }
.pacing-row { display: grid; grid-template-columns: 150px minmax(120px, 1fr) minmax(200px, auto); gap: 6px 14px; align-items: center; }
.pacing-track { position: relative; height: 10px; border-radius: 5px; background: var(--chip); }
.pacing-track .fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 5px; max-width: 100%; }
.pacing-track .fill.ahead { background: var(--ink); } .pacing-track .fill.behind { background: var(--ink); }
.pacing-track .now { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--fg); transform: translateX(-1px); }
.pacing-track .end { position: absolute; top: -2px; bottom: -2px; width: 2px; background: var(--muted); opacity: .6; transform: translateX(-1px); }
.pacing-nums { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
@media (max-width: 700px) { .pacing-row { grid-template-columns: 1fr; gap: 4px; } }
.pacing-note { grid-column: 1 / -1; }

/* confirmations (_status.html notice): toast + a stamp beside the form you used + a busy button */
.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 60; display: grid; gap: 8px; width: min(400px, calc(100vw - 32px)); pointer-events: none; }
.toast { pointer-events: auto; position: relative; overflow: hidden; display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: start;
  padding: 12px 12px 14px 14px; border-radius: var(--r-sm); background: var(--panel); color: var(--fg);
  border: 1px solid var(--line); border-left: 4px solid var(--nt); box-shadow: var(--pop-shadow);
  animation: nt-in .32s cubic-bezier(.2,.9,.3,1.2) both; }
.toast.nt-saved { --nt: var(--up); } .toast.nt-removed { --nt: var(--muted); } .toast.nt-queued { --nt: var(--event); } .toast.nt-error { --nt: var(--down); }
.toast.is-leaving { animation: nt-out .25s ease-in both; }
.nt-ico { width: 28px; height: 28px; color: var(--nt); }
.nt-ring { stroke-dasharray: 60; stroke-dashoffset: 60; animation: nt-draw .45s ease-out .05s forwards; }
.nt-draw { stroke-dasharray: 24; stroke-dashoffset: 24; animation: nt-draw .3s ease-out .4s forwards; }
.toast.nt-saved .nt-ico { animation: nt-pop .3s ease-out .65s both; }
.nt-body { display: grid; gap: 2px; min-width: 0; }
.nt-title { font-weight: 650; }
.nt-detail { font-size: .9em; color: var(--muted); }
.nt-close { border: 0; background: none; color: var(--muted); font-size: 20px; line-height: 1; padding: 0 4px; cursor: pointer; }
.nt-close:hover { color: var(--fg); }
.nt-timer { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--nt); opacity: .35; transform-origin: left; animation: nt-timer 7s linear forwards; }
.toast:hover .nt-timer, .toast:focus-within .nt-timer { animation-play-state: paused; }
@keyframes nt-in { from { opacity: 0; transform: translateY(12px) scale(.98); } }
@keyframes nt-out { to { opacity: 0; transform: translateY(8px); } }
@keyframes nt-draw { to { stroke-dashoffset: 0; } }
@keyframes nt-pop { 50% { transform: scale(1.15); } }
@keyframes nt-timer { to { transform: scaleX(0); } }
@media (max-width: 600px) { .toasts { left: 16px; right: 16px; width: auto; } }
.inline-notice { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: var(--r-sm); margin-bottom: var(--s4); }
.inline-notice.nt-error { --nt: var(--down); background: var(--bad-bg); color: var(--bad-fg); }
.inline-notice .nt-ico { width: 22px; height: 22px; flex: none; }
/* the stamp next to the button you pressed */
.saved-stamp { display: inline-flex; align-items: center; gap: 5px; margin-left: 10px; font-size: .85em; font-weight: 600; color: var(--nt, var(--up)); animation: nt-in .3s ease-out both; }
.saved-stamp svg { width: 16px; height: 16px; }
.saved-stamp .nt-ring, .saved-stamp .nt-draw { animation-delay: .1s; }
form.just-saved { animation: nt-glow 1.6s ease-out; border-radius: var(--r-sm); }
@keyframes nt-glow { from { box-shadow: 0 0 0 3px color-mix(in srgb, var(--nt, var(--up)) 45%, transparent); } to { box-shadow: 0 0 0 3px transparent; } }
/* a button whose form is on its way */
button.is-busy { position: relative; opacity: .85; cursor: progress; }
button.is-busy::before { content: ""; display: inline-block; width: .9em; height: .9em; margin-right: 6px; vertical-align: -1px; border-radius: 50%;
  border: 2px solid currentColor; border-right-color: transparent; animation: st-rot .8s linear infinite; }
@media (prefers-reduced-motion: reduce) {
  .toast, .toast.is-leaving, .saved-stamp, form.just-saved, .toast.nt-saved .nt-ico { animation: none; }
  .nt-ring, .nt-draw { animation: none; stroke-dashoffset: 0; }
  .nt-timer { display: none; } button.is-busy::before { animation: none; }
}

/* big drop question (Home) */
.bigdrop { margin-bottom: var(--s4); border-left: 4px solid var(--event); }
.bigdrop h2 { margin: 2px 0 6px; }
.bd-kicker { display: flex; align-items: center; gap: 6px; margin: 0; color: var(--event-ink); font-weight: 600; }
.bd-kicker svg { width: 18px; height: 18px; }
.bd-choices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 8px 0 10px; }
.bd-choices form { display: contents; }
.choice { display: grid; gap: 4px; align-content: start; text-align: left; padding: 12px 14px; border-radius: var(--r-sm); border: 1px solid var(--line-strong);
  background: var(--panel); color: var(--fg); cursor: pointer; font: inherit; }
.choice span { font-size: .88em; color: var(--muted); font-weight: 400; }
.choice:hover, .choice:focus-visible { border-color: var(--event); box-shadow: 0 0 0 3px var(--event-bg); }
.bd-spike { align-items: flex-end; margin: 6px 0; }
@media (max-width: 700px) { .bd-choices { grid-template-columns: 1fr; } }
.bd-more > summary { list-style: none; height: 100%; box-sizing: border-box; }
.bd-more > summary::-webkit-details-marker { display: none; }
.bd-more[open] { grid-column: 1 / -1; }                       /* opened: the follow-up takes the whole row */
.bd-more[open] > summary { height: auto; border-color: var(--event); box-shadow: 0 0 0 3px var(--event-bg); }
.bd-next { margin-top: 8px; padding: 12px 14px; border: 1px solid var(--event); border-radius: var(--r-sm); background: var(--event-bg); }
.bd-next p { margin: 0 0 8px; }
.bd-next-edit { margin-top: 6px; }
.moves-form { gap: 6px; flex-wrap: wrap; align-items: center; }
.moves-form input[type=date] { width: 9.5em; }

/* Delta: arrow + signed figure with a true minus; colour says good or bad for the business, not direction */
.dlt { display: inline-flex; align-items: center; gap: var(--s1); padding: 0 6px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--panel);
  font: 500 var(--fs-sm)/20px var(--font-mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.dlt.good { color: var(--up); background: var(--up-soft); border-color: transparent; } .dlt.bad { color: var(--down); background: var(--down-soft); border-color: transparent; } .dlt.flat { color: var(--muted); }
.dlt.bare { border: 0; background: none; padding: 0; }

/* Why card: what happened (one sentence), why (ranked causes with share of the change), what to do, how sure */
.why { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-card); padding: var(--s5); display: grid; gap: var(--s5); }
.why-head { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s3); flex-wrap: wrap; }
.why-what { font: 500 28px/34px var(--font-display); letter-spacing: -.01em; margin: 0; max-width: 34ch; }
.why-body { color: var(--muted); margin: 0; max-width: 80ch; }
.why-causes { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s3); max-width: 640px; }
.why-cause { display: grid; grid-template-columns: 56px 1fr; gap: var(--s3); align-items: start; }
.why-share { font: 500 14px/24px var(--font-mono); text-align: right; }
.why-cause .ev { color: var(--muted); font-size: var(--fs-sm); }
.why-bar { height: 4px; border-radius: 2px; background: var(--well); margin-top: 6px; overflow: hidden; }
.why-bar > i { display: block; height: 100%; background: var(--marigold); }
.why-next { background: var(--marigold-soft); border-radius: var(--r-sm); padding: var(--s3) var(--s4); color: var(--ink); font-size: 14px; line-height: 22px; max-width: 640px; }
.why-next p { margin: 0; }
.why-foot { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s3); align-items: center; font-size: var(--fs-sm); line-height: 20px; color: var(--muted); border-top: 1px solid var(--line); padding-top: var(--s3); }
.why-foot details { flex-basis: 100%; }
.conf { display: inline-flex; gap: 3px; vertical-align: middle; margin: 0 4px; }
.conf > i { width: 6px; height: 12px; border-radius: 2px; background: var(--line); }
.conf > i.on { background: var(--ink); }
.why-evidence { display: grid; gap: var(--s5); grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); margin-top: var(--s3); color: var(--fg); }
.why-evidence h4 { margin: 0 0 var(--s1); }
.why-evidence table td { padding: 4px 6px; }
@media (max-width: 640px) { .why { padding: var(--s4); } .why-what { font-size: 24px; line-height: 30px; } }

/* empty states and the sign-in page */
.auth { max-width: 420px; margin: 8vh auto 0; }
.auth .auth-logo { display: block; margin: 0 auto var(--s6); height: 32px; width: auto; }
.auth h1 { text-align: center; }
.auth .sub { text-align: center; margin-inline: auto; }
.empty { text-align: left; max-width: 560px; margin: 6vh auto 0; }
.empty .mark { width: 48px; height: 48px; margin-bottom: var(--s4); }
.mail-preview { border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); }
.legend.sq i.cmp, .legend.sq i.fc { width: 16px; height: 0; }
.flag-why { color: var(--muted); margin: var(--s1) 0 0; max-width: 80ch; }
.flag-why b { color: var(--fg); font-weight: 600; }
.flag .cands .anno { text-decoration: none; }
.bare-brand { max-width: calc(520px + 2 * var(--s5)); margin: 0 auto; padding: var(--s6) var(--s5) 0; }
.bare-brand img { height: 24px; width: auto; }
.reply h1 { font-size: 22px; line-height: 28px; }
.auth > p.small { text-align: center; }
.card.table-wrap > p { padding: 0 var(--s3); }
/* tokens.css defines .headline/.title/.body/.label as type styles; the app's own uses of those names stay Geist */
.lever .headline { font: 400 var(--fs-sm)/20px var(--font-sans); letter-spacing: 0; }
.lever .big .unit { font-family: var(--font-sans); }
.onb-rail a { text-decoration: none; }

/* channel colours (tokens --channel-*): one per channel, fills and swatches only */
.ch-paid_search { --ch: var(--channel-paid-search); } .ch-paid_social { --ch: var(--channel-paid-social); } .ch-display { --ch: var(--channel-display); }
.ch-email { --ch: var(--channel-email); } .ch-sms { --ch: var(--channel-sms); } .ch-affiliate { --ch: var(--channel-affiliate); }
.ch-organic_search { --ch: var(--channel-organic-search); } .ch-organic_social { --ch: var(--channel-organic-social); } .ch-ai { --ch: var(--channel-ai); }
.ch-app { --ch: var(--channel-app); } .ch-referral { --ch: var(--channel-referral); } .ch-other { --ch: var(--channel-other); }
.ch-direct { --ch: var(--channel-direct); } .ch-unknown { --ch: var(--channel-unknown); }
.chsw { display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--ch, var(--line-strong)); margin-right: 6px; vertical-align: 0; flex: none; }
.attr tr[class*="ch-"] .bar.lnd { background: var(--ch, var(--ink)); }
.sw.lnd { background: var(--ink); }
.chip .chsw { width: 8px; height: 8px; margin-right: 4px; }
.feed-card .eyebrow:has(.chsw)::before { display: none; }

/* ---- accounts: sign in, sign up, reset, verification banner, settings shell, team (design/ravelwise-ui) ---- */
:root { --panel-ink: #16171b; --panel-ink-2: #1f2026; --panel-ink-line: #2a2c31; --panel-ink-muted: #a8a39a; --panel-ink-text: #f6f3ec; }
.acct-page { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s6); padding: var(--s6) var(--s4); }
.acct-page .acct-logo { height: 34px; width: auto; }
.acct-card { width: 100%; max-width: 440px; padding: 40px; display: flex; flex-direction: column; gap: 20px; box-shadow: var(--shadow-card); }
.acct-card h1 { font: 500 32px/38px var(--font-display); letter-spacing: -.025em; margin: 0; }
.acct-card .acct-sub, .acct-note { margin: 0; color: var(--muted); font-size: 14px; line-height: 22px; }
.acct-card .field, .acct-split .field { margin: 0; gap: 6px; }
.acct-card .field label, .acct-split .field label { color: var(--fg); font: 600 13px/18px var(--font-sans); }
.acct-card input[type=email], .acct-card input[type=password], .acct-card input[type=text], .acct-split input[type=email], .acct-split input[type=password],
.acct-split input[type=text], .acct-split select { width: 100%; min-height: 44px; padding: 10px 12px; font-size: 15px; }
.acct-hint { font-size: 13px; line-height: 18px; color: var(--muted); }
.btn-block { width: 100%; min-height: 48px; }
.btn-block.primary { font-size: 15px; }
.btn-sso { width: 100%; min-height: 48px; background: var(--panel); border-color: var(--line-strong); gap: 10px; }
.btn-sso[disabled] { cursor: not-allowed; opacity: .6; }
.btn-sso[disabled]:hover { background: var(--panel); }
.email-signin > summary { list-style: none; cursor: pointer; text-align: center; font-size: 14px; font-weight: 600; color: var(--fg);
  text-decoration: underline; text-underline-offset: 3px; min-height: 44px; display: flex; align-items: center; justify-content: center; }
.email-signin > summary::-webkit-details-marker { display: none; }
.email-signin > summary:focus-visible { outline: 2px solid var(--focus, var(--fg)); outline-offset: 2px; border-radius: 6px; }
.email-signin[open] > summary { color: var(--muted); text-decoration: none; }
.email-signin-fields { display: flex; flex-direction: column; gap: 16px; margin-top: 8px; }
.or-rule { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; }
.or-rule::before, .or-rule::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.row-between { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.check-row { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 20px; min-height: 28px; }
.check-row input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--ink); flex: none; }
.acct-foot { font-size: 14px; color: var(--muted); margin: 0; text-align: center; }
.acct-split { min-height: 100vh; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.acct-split .pane-dark { background: var(--panel-ink); color: var(--panel-ink-text); padding: 48px 64px; display: flex; flex-direction: column; gap: 40px; }
.acct-split .pane-dark img { height: 30px; width: auto; align-self: flex-start; }
.acct-split .pane-dark h2 { font: 500 56px/60px var(--font-display); letter-spacing: -.025em; margin: 0; color: var(--panel-ink-text); }
.acct-split .tag-line { font: 500 12px/16px var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--panel-ink-muted); margin: 0; }
.acct-split .tag-line b { color: var(--marigold); font-weight: 500; margin-right: 10px; }
.acct-split .rule { width: 40px; height: 3px; background: var(--marigold); border-radius: 2px; }
.acct-split .why-sample { background: #f6f3ec; color: #16171b; border-radius: var(--r); padding: 24px; display: flex; flex-direction: column; gap: 16px; max-width: 520px; }
.acct-split .why-sample .why-what { font: 500 24px/30px var(--font-display); letter-spacing: -.01em; margin: 0; }
.acct-split .why-sample .tag-line { color: #5e5b55; display: flex; justify-content: space-between; align-items: center; }
.acct-split .why-sample .next { background: #fbe7c3; border-radius: var(--r-sm); padding: 12px 14px; font-size: 14px; line-height: 22px; }
.acct-split .why-sample .dl { font: 500 13px/18px var(--font-mono); color: #0e6b5c; border: 1px solid #ddd6c8; background: #fff; border-radius: 6px; padding: 2px 8px; }
.acct-split .pane-dark .fine { margin-top: auto; font-size: 14px; color: var(--panel-ink-muted); }
.acct-split .pane-form { padding: 48px 96px; display: flex; flex-direction: column; justify-content: center; gap: 28px; }
.acct-split .pane-form h1 { font: 500 36px/42px var(--font-display); letter-spacing: -.02em; margin: 0; }
.acct-split .pane-form .tag-line { color: var(--muted); }
.acct-split .pane-form .tag-line b { color: var(--marigold-ink); }
.acct-split form { display: flex; flex-direction: column; gap: 18px; }
.two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.acct-split.is-narrow-form .pane-form { max-width: 640px; }
@media (max-width: 900px) {
  .acct-split { grid-template-columns: 1fr; }
  .acct-split .pane-dark { padding: 28px 24px; gap: 20px; }
  .acct-split .pane-dark h2 { font-size: 34px; line-height: 38px; }
  .acct-split .pane-dark .why-sample, .acct-split .pane-dark .fine { display: none; }
  .acct-split .pane-form { padding: 28px 24px 40px; }
}
@media (max-width: 480px) { .acct-card { padding: 24px; } .acct-card h1 { font-size: 28px; line-height: 34px; } .two-col { grid-template-columns: 1fr; } }
.legal { max-width: 680px; margin: 6vh auto; display: flex; flex-direction: column; gap: var(--s4); }
.legal .placeholder { background: var(--event-bg); color: var(--event-ink); padding: 10px 12px; border-radius: var(--r-sm); font-size: var(--fs-sm); }
.verify-banner { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; padding: 10px var(--s5); background: var(--event-bg); color: var(--event-ink); font-size: var(--fs-sm); border-bottom: 1px solid var(--line); }
.verify-banner form { display: inline; }
.inline-ok { display: flex; gap: 10px; padding: 10px 12px; border-radius: var(--r-sm); background: var(--ok-bg); color: var(--ok-fg); font-size: 14px; }

/* settings shell */
.set-nav { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 0 0 var(--s6); flex-wrap: wrap; }
.set-nav a, .set-nav span { padding: 10px 14px; color: var(--muted); text-decoration: none; font-weight: 500; min-height: 44px; display: inline-flex; align-items: center; }
.set-nav a[aria-current=page] { color: var(--fg); font-weight: 600; border-bottom: 2px solid var(--fg); margin-bottom: -1px; }
.set-nav span { opacity: .6; }
.team-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: var(--s5); }
.team-head h1 { margin: 0 0 6px; font: 500 36px/42px var(--font-display); letter-spacing: -.02em; }
.team-head .actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.team-table { width: 100%; border-collapse: collapse; }
.team-table th { text-align: left; font: 500 12px/16px var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 12px 16px; border-bottom: 1px solid var(--line); }
.team-table td { padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.team-table tr:last-child td { border-bottom: 0; }
.who { display: flex; gap: 12px; align-items: center; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--surface-200); display: inline-flex; align-items: center; justify-content: center; font: 600 13px var(--font-sans); flex: none; color: var(--ink); }
.avatar.owner { background: var(--marigold); color: var(--on-marigold); }
.who small { display: block; color: var(--muted); font-size: 13px; }
.chip.ink { background: var(--ink); color: var(--ink-inverse); }
.switch { position: relative; display: inline-block; width: 44px; height: 44px; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; width: 100%; height: 100%; cursor: pointer; z-index: 1; }
.switch span { position: absolute; left: 0; top: 10px; width: 44px; height: 24px; border-radius: 12px; background: var(--line-strong); transition: background .15s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--panel); transition: transform .15s; }
.switch input:checked + span { background: var(--up); }
.switch input:checked + span::after { transform: translateX(20px); }
.switch input:focus-visible + span { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.switch input:disabled { cursor: not-allowed; } .switch input:disabled + span { opacity: .5; }
.danger { color: var(--down); }
button.danger, .btn.danger { color: var(--down); }
.invite-panel { display: grid; grid-template-columns: 1fr 160px auto; gap: 12px; align-items: end; border: 2px solid var(--ink); padding: 20px 24px; margin-bottom: var(--s5); }
.invite-panel .field { margin: 0; }
.invite-panel[hidden] { display: none; }
.team-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: start; margin-top: var(--s5); }
.team-cols .tag-line { font: 500 12px/16px var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin: 0 0 12px; }
.pending-row { padding: 16px 20px; display: flex; justify-content: space-between; align-items: center; gap: 16px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.pending-row:last-child { border-bottom: 0; }
.pending-row form { display: inline; }
.matrix td, .matrix th { padding: 10px 12px; font-size: 13px; text-align: center; } .matrix td:first-child, .matrix th:first-child { text-align: left; }
.matrix th { font: 500 12px/16px var(--font-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--line); }
.matrix td { border-bottom: 1px solid var(--line); } .matrix tr:last-child td { border-bottom: 0; }
.team-table select { min-height: 36px; padding: 4px 10px; }
@media (max-width: 900px) { .team-cols { grid-template-columns: 1fr; } .invite-panel { grid-template-columns: 1fr; } .team-table { display: block; overflow-x: auto; } .team-head h1 { font-size: 30px; line-height: 36px; } }
main.plain { max-width: none; padding: 0; }

/* a plan with a history limit says so on pages that read far back */
.hist-note { margin: 0; padding: var(--s2) var(--s5); background: var(--warn-bg); color: var(--warn-fg); font-size: var(--fs-sm); line-height: 20px; border-bottom: 1px solid var(--line); }

/* ---- setup wizard (steps 2 to 7): a dark rail with the seven steps, a pane beside it. Tokens only; the rail stays dark in both themes. */
:root { --rail-bg: var(--ink); --rail-fg: var(--ink-inverse); --rail-muted: color-mix(in srgb, var(--ink-inverse) 66%, var(--ink));
  --rail-on: color-mix(in srgb, var(--ink-inverse) 9%, var(--ink)); --rail-line: color-mix(in srgb, var(--ink-inverse) 22%, var(--ink)); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --rail-bg: var(--surface-200); --rail-fg: var(--ink); --rail-muted: color-mix(in srgb, var(--ink) 66%, var(--surface-200));
  --rail-on: color-mix(in srgb, var(--ink) 9%, var(--surface-200)); --rail-line: color-mix(in srgb, var(--ink) 22%, var(--surface-200)); } }
:root[data-theme="dark"] { --rail-bg: var(--surface-200); --rail-fg: var(--ink); --rail-muted: color-mix(in srgb, var(--ink) 66%, var(--surface-200));
  --rail-on: color-mix(in srgb, var(--ink) 9%, var(--surface-200)); --rail-line: color-mix(in srgb, var(--ink) 22%, var(--surface-200)); }
.wz { display: grid; grid-template-columns: 320px minmax(0, 1fr); min-height: 100vh; }
.wz-rail { background: var(--rail-bg); color: var(--rail-fg); padding: 40px 32px; display: flex; flex-direction: column; gap: 40px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.wz-rail img { height: 28px; width: auto; align-self: flex-start; }
.wz-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.wz-step-in { display: grid; grid-template-columns: 28px 1fr; gap: 12px; align-items: center; min-height: 44px; padding: 8px 12px; border-radius: var(--r-sm); color: var(--rail-muted);
  font-size: 14px; line-height: 20px; text-decoration: none; }
a.wz-step-in:hover { background: var(--rail-on); color: var(--rail-fg); text-decoration: none; }
a.wz-step-in:focus-visible { outline: 2px solid var(--marigold); outline-offset: 0; }
.wz-n { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--rail-line); display: flex; align-items: center; justify-content: center; font: 500 12px var(--font-mono); }
.wz-step--done .wz-step-in, .wz-step--skipped .wz-step-in { color: var(--rail-fg); }
.wz-step--done .wz-n { background: var(--marigold); border-color: var(--marigold); color: var(--on-marigold); }
.wz-step--skipped .wz-n { border-style: dashed; }
.wz-step--current .wz-step-in { background: var(--rail-on); color: var(--rail-fg); font-weight: 600; }
.wz-step--current .wz-n { border-color: var(--rail-fg); }
.wz-railnote { margin-top: auto; display: flex; flex-direction: column; gap: 8px; font-size: 14px; line-height: 20px; color: var(--rail-muted); }
.wz-railnote a { color: var(--marigold); }
.wz-pane { padding: 56px 72px; display: flex; flex-direction: column; gap: 28px; min-width: 0; }
.wz-head { display: flex; flex-direction: column; gap: 12px; max-width: 640px; }
.wz-head p { margin: 0; }
.wz-tag { font: 500 12px/16px var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.wz-tag b { color: var(--event-ink); font-weight: 500; margin-right: 10px; }
.wz h1.wz-title { font: 500 40px/46px var(--font-display); letter-spacing: -.02em; margin: 0; }
.wz-form { display: contents; }
.wz-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; align-items: start; }
.wz-col { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.wz-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-top: 24px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.wz-foot .acts { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.wz button, .wz a.button, .wz .btn { min-height: 44px; padding: 10px 18px; font-size: 15px; }
.wz button.ghost, .wz .btn.ghost { padding-inline: 8px; }
.wz button.small { min-height: 44px; font-size: var(--fs-sm); }
.wz input[type=text], .wz input[type=email], .wz select { min-height: 44px; font-size: 15px; width: 100%; }
.wz .field { margin-bottom: 0; }
.wz .field > label, .wz-label { font: 600 13px/18px var(--font-sans); color: var(--fg); }
.wz .hint { font-size: 13px; line-height: 18px; color: var(--muted); }
.wz button:disabled { cursor: not-allowed; opacity: .55; }
.wz-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); min-width: 0; }
.wz-card--pad { padding: 32px; display: flex; flex-direction: column; gap: 20px; }
.wz-affix { display: flex; align-items: stretch; border: 1px solid var(--line-strong); border-radius: var(--r-sm); background: var(--panel); overflow: hidden; }
.wz-affix input { border: 0 !important; border-radius: 0 !important; min-width: 0; flex: 1; }
.wz-affix .end, .wz-affix .start { display: flex; align-items: center; padding: 0 12px; background: var(--chip); color: var(--muted); font: 500 14px var(--font-mono); white-space: nowrap; }
.wz-affix:focus-within { outline: 2px solid var(--focus-ring); outline-offset: 1px; }
.wz-block { display: block; width: 100%; min-height: 48px !important; }
.wz-status { display: flex; gap: 12px; align-items: center; padding: 14px 16px; background: var(--well); border-radius: var(--r-sm); font-size: 14px; line-height: 20px; flex-wrap: wrap; }
.wz-tiles { display: grid; gap: 2px; background: var(--line); border: 2px solid var(--line); border-radius: var(--r); overflow: hidden; }
.wz-tiles > div { background: var(--panel); padding: 16px 20px; display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; }
.wz-tiles .wz-why { grid-column: 1 / -1; font-size: 13px; color: var(--muted); }
.wz-note { display: flex; gap: 14px; align-items: flex-start; padding: 16px 20px; font-size: 14px; line-height: 22px; }
.wz-note svg { flex-shrink: 0; margin-top: 2px; color: var(--up); }
.wz-sources { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.wz-source { padding: 24px; display: flex; flex-direction: column; gap: 12px; min-height: 196px; }
.wz-source h2 { margin: 0; font: 600 17px/24px var(--font-sans); }
.wz-source .top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.wz-source p { margin: 0; font-size: 14px; line-height: 21px; }
.wz-source .note { font-size: 13px; line-height: 19px; color: var(--warn-fg); }
.wz-source .act { margin-top: auto; }
.wz-count { display: flex; justify-content: space-between; align-items: center; }
.wz-bar { flex: 1; max-width: 420px; height: 6px; border-radius: 3px; background: var(--well); margin-left: 24px; overflow: hidden; }
.wz-bar i { display: block; height: 6px; background: var(--marigold); }
.wz-pick { display: flex; flex-direction: column; gap: 10px; border: 0; margin: 0; padding: 0; }
.wz-pick legend { margin-bottom: 10px; }
.wz-opt { display: flex; justify-content: space-between; align-items: center; gap: 16px; width: 100%; min-height: 64px; padding: 14px 18px; border-radius: var(--r-sm); background: var(--panel);
  border: 1px solid var(--line-strong); cursor: pointer; }
.wz-opt:has(input:checked) { border: 2px solid var(--ink); padding: 13px 17px; }
.wz-opt:has(input:focus-visible) { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.wz-opt input { position: absolute; opacity: 0; pointer-events: none; }
.wz-opt .t { display: flex; flex-direction: column; gap: 2px; }
.wz-opt .t b { font-size: 15px; } .wz-opt .t span { font-size: 13px; color: var(--muted); }
.wz-opt .r { width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; border: 2px solid var(--line-strong); }
.wz-opt:has(input:checked) .r { border: 6px solid var(--ink); }
.wz-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.wz-switchrow { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.wz-switchrow b { font-size: 14px; }
.wz-preview { overflow: hidden; }
.wz-preview > div { padding: 14px 24px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.wz-preview .head { padding: 22px 24px; flex-direction: column; gap: 6px; }
.wz-preview .head .big { font: 500 26px/32px var(--font-display); letter-spacing: -.02em; }
.wz-preview .ask { background: var(--warn-bg); align-items: center; border-bottom: 0; padding: 16px 24px; }
.wz-preview .fake { padding: 8px 16px; border-radius: var(--r-sm); font-weight: 600; font-size: 13px; border: 1px solid var(--line-strong); background: var(--panel); white-space: nowrap; }
.wz-preview .fake.p { background: var(--ink); color: var(--ink-inverse); border-color: var(--ink); }
.wz-well { background: var(--well); border-radius: var(--r); padding: 20px; }
.wz-well svg { display: block; width: 100%; height: auto; }
.wz-well rect { fill: var(--ink); } .wz-well rect.peak { fill: var(--marigold); }
.wz-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.wz-table th { text-align: left; font: 500 12px/16px var(--font-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 12px 16px; border-bottom: 1px solid var(--line); }
.wz-table td { padding: 10px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.wz-table tr:last-child td { border-bottom: 0; }
.wz-teamrow { display: grid; grid-template-columns: 1fr 160px 140px 44px; gap: 12px; align-items: center; }
.wz-teamhead { padding: 0 2px; }
.wz-teamgrid { display: grid; grid-template-columns: 1fr 360px; gap: 40px; align-items: start; }
.wz-seats { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; background: var(--well); border-radius: var(--r-sm); font-size: 14px; gap: 12px; flex-wrap: wrap; }
.wz-roles { padding: 24px; display: flex; flex-direction: column; gap: 14px; font-size: 14px; line-height: 21px; }
.wz-loadrow { padding: 18px 22px; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; align-items: center; }
.wz-loadrow:last-child { border-bottom: 0; }
.wz-loadrow b { font-size: 15px; } .wz-loadrow .hint { grid-column: 1 / -1; }
.wz-loadrow .progress { grid-column: 1 / -1; margin: 0; }
.wz-found { padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.wz-found .what { font: 500 24px/30px var(--font-display); letter-spacing: -.01em; margin: 0; }
.wz-conf { display: inline-flex; gap: 3px; vertical-align: middle; } .wz-conf i { width: 6px; height: 12px; border-radius: 2px; background: var(--line); } .wz-conf i.on { background: var(--ink); }
.wz-verify { background: var(--warn-bg); color: var(--warn-fg); padding: 12px 16px; border-radius: var(--r-sm); font-size: 14px; }
@media (max-width: 1000px) {
  .wz { grid-template-columns: 1fr; }
  .wz-rail { position: static; height: auto; padding: 20px 16px; gap: 16px; }
  .wz-steps { flex-direction: row; flex-wrap: wrap; } .wz-step-in { grid-template-columns: 28px; padding: 8px; font-size: 0; gap: 0; } .wz-step--current .wz-step-in { grid-template-columns: 28px auto; font-size: 14px; gap: 8px; }
  .wz-railnote { margin-top: 0; }
  .wz-pane { padding: 28px 16px; }
  .wz h1.wz-title { font-size: 30px; line-height: 36px; }
  .wz-cols, .wz-teamgrid, .wz-2 { grid-template-columns: 1fr; gap: 24px; } .wz-sources { grid-template-columns: 1fr; }
  .wz-teamrow { grid-template-columns: 1fr 1fr 44px; } .wz-teamrow .email { grid-column: 1 / -1; } .wz-teamhead { display: none; }
}
.wz [hidden] { display: none !important; }
.wz a.button.ghost { background: transparent; border-color: transparent; color: var(--link); padding-inline: var(--s2); font-weight: 600; }
.wz a.button.ghost:hover { background: transparent; text-decoration: underline; }
.wz .chip.ok::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: currentColor; margin-right: 6px; }
.wz .progress.indeterminate i { background: var(--marigold); }
