/* Creators · Vatar Admin prototype. Vatar DS tokens, light theme, the Support shell (white panes, hairlines, .b buttons).
   Local sizes marked "DS gap". */
:root {
  --row: 13.5px;  /* DS gap: dense dashboard text */
  --tiny: 12px;   /* DS gap: meta text */
  --top-h: 56px; --tabs-h: 44px; --rail-w: 76px;
  --drawer-w: 480px; --queue-w: 380px; --panel-w: 560px;
  --pad: var(--space-6);
  --line: var(--color-text-primary);
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--color-bg-canvas); color: var(--color-text-primary); font-family: var(--font-family-body); font-size: var(--row); line-height: 1.45; -webkit-font-smoothing: antialiased; overflow: hidden; }
/* fix pass 1 (type B9, B10): no system monospace, nothing heavier than 600 */
code { font-family: var(--font-family-body); font-size: var(--font-size-12); color: var(--color-text-secondary); font-variant-numeric: tabular-nums; }
b, strong { font-weight: var(--font-weight-semibold); }
/* fix pass 1 (polish N1): no default tap flash; :active states give the feedback */
a, button, summary, [role="button"], [tabindex] { -webkit-tap-highlight-color: transparent; }
svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex: none; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--color-text-link); }
kbd { font: 500 11px/1 var(--font-family-body); padding: 3px 5px; border: 1px solid var(--color-border-default); border-radius: var(--radius-xs); background: var(--color-bg-canvas); color: var(--color-text-secondary); }
.num, time, td.n, .n { font-feature-settings: var(--font-feature-tabular); font-variant-numeric: tabular-nums; }
:focus-visible { outline: var(--focus-ring-width) solid var(--focus-ring-color); outline-offset: var(--focus-ring-offset); }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
* { scrollbar-width: none; } *::-webkit-scrollbar { display: none; }
.muted { color: var(--color-text-secondary); } .faint { color: var(--color-text-tertiary); }
.tiny { font-size: var(--tiny); }

/* ── Shell (same as Support) ── */
.app { display: flex; height: 100vh; height: 100dvh; }
.rail { width: var(--rail-w); flex: none; display: flex; flex-direction: column; gap: 2px; padding: var(--space-3) var(--space-2); background: var(--color-bg-canvas); border-right: 1px solid var(--color-border-subtle); overflow-y: auto; }
.rail__brand { display: grid; place-items: center; height: 44px; margin-bottom: var(--space-3); }
.rail__brand img { display: block; border-radius: var(--radius-xs); }
.rail a { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 2px; border-radius: var(--radius-sm); color: var(--color-text-secondary); text-decoration: none; font-size: 11px; font-weight: var(--font-weight-medium); }
.rail a svg { width: 20px; height: 20px; }
.rail a:hover { background: var(--color-bg-surface); color: var(--color-text-primary); }
.rail a[aria-current] { background: var(--color-bg-brand); color: var(--color-text-accent); }
.rail .badge { position: absolute; top: 6px; right: 16px; width: 8px; height: 8px; border-radius: 50%; background: var(--color-status-danger-solid); border: 2px solid var(--color-bg-canvas); }
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.top { height: var(--top-h); flex: none; display: flex; align-items: center; gap: var(--space-4); padding: 0 var(--pad); border-bottom: 1px solid var(--color-border-subtle); }
.top__menu { display: none; width: 36px; height: 36px; border: 0; background: none; border-radius: var(--radius-sm); cursor: pointer; place-items: center; }
.top__title { margin: 0; font-family: var(--font-family-display); font-size: 18px; font-weight: var(--font-weight-semibold); }
.role { margin-left: auto; font-size: var(--tiny); color: var(--color-text-secondary); white-space: nowrap; }
.role b { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.top__avatar { display: block; flex: none; width: 32px; height: 32px; border-radius: 50%; object-fit: cover; border: 1px solid var(--color-border-subtle); background: var(--color-bg-surface); }

/* Tabs + period picker */
.tabsbar { flex: none; display: flex; align-items: center; gap: var(--space-3); padding: 0 var(--pad) 0 calc(var(--pad) - var(--space-3)); border-bottom: 1px solid var(--color-border-subtle); }
.tabs { display: flex; gap: var(--space-1); overflow-x: auto; min-width: 0; flex: 1; }
.tab { position: relative; display: inline-flex; align-items: center; gap: 6px; height: var(--tabs-h); padding: 0 var(--space-3); color: var(--color-text-secondary); white-space: nowrap; font-weight: var(--font-weight-medium); text-decoration: none; }
.tab:hover { color: var(--color-text-primary); }
.tab[aria-current="page"] { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.tab[aria-current="page"]::after { content: ""; position: absolute; left: var(--space-3); right: var(--space-3); bottom: -1px; height: 2px; border-radius: 2px; background: var(--color-text-primary); }
.tab .num { min-width: 20px; height: 20px; padding: 0 6px; border-radius: var(--radius-pill); display: inline-grid; place-items: center; font-size: 11px; background: var(--color-bg-surface); color: var(--color-text-secondary); }
.tab .tagp { font-size: 11px; padding: 1px 6px; border-radius: var(--radius-xs); border: 1px dashed var(--color-border-strong); color: var(--color-text-secondary); font-weight: var(--font-weight-medium); }
.period { flex: none; }

/* ── Buttons (admin .b set, from Support) ── */
.b { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; padding: 0 14px; border-radius: var(--radius-sm); border: 1px solid transparent; font-size: var(--row); font-weight: var(--font-weight-medium); line-height: 1; white-space: nowrap; cursor: pointer; text-decoration: none; transition: background-color var(--motion-duration-fast) var(--motion-easing-standard), border-color var(--motion-duration-fast) var(--motion-easing-standard); }
.b svg { width: 16px; height: 16px; }
.b kbd { margin-left: 2px; padding: 2px 4px; font-size: var(--font-size-11); background: transparent; border-color: currentColor; color: inherit; opacity: .7; }
/* Primary (18 Nov): the DS's one filled style, Vatar lilac (light: lilac-700 / 800 hover / 900 pressed, white label 7.88:1).
   Colour-only transition, 140ms ease-out; offset focus ring so it reads off the lilac; disabled is a flat neutral. */
.b--primary { background: var(--color-action-primary-bg); color: var(--color-action-primary-text); transition: background-color var(--motion-duration-press) var(--motion-easing-out), color var(--motion-duration-press) var(--motion-easing-out); }
@media (hover: hover) and (pointer: fine) { .b--primary:not(:disabled):hover { background: var(--color-action-primary-bg-hover); } }
.b--primary:not(:disabled):active { background: var(--color-action-primary-bg-pressed); }
.b--primary:focus-visible { outline: var(--focus-ring-width) solid var(--focus-ring-color); outline-offset: 2px; }
.b--primary kbd { opacity: 1; border-color: var(--color-alpha-white-35); color: color-mix(in srgb, var(--color-action-primary-text) 85%, transparent); }
/* Destructive confirm (reject, disqualify, mark invalid): solid danger red, white label 6.0:1. DS has no danger hover/pressed step, so it deepens with a mix. */
.b--danger-solid { background: var(--color-status-danger-solid); color: var(--color-status-danger-on-solid); transition: background-color var(--motion-duration-press) var(--motion-easing-out); }
@media (hover: hover) and (pointer: fine) { .b--danger-solid:not(:disabled):hover { background: color-mix(in srgb, var(--color-status-danger-solid) 88%, var(--color-text-primary)); } }
.b--danger-solid:not(:disabled):active { background: color-mix(in srgb, var(--color-status-danger-solid) 78%, var(--color-text-primary)); }
.b--danger-solid:focus-visible { outline: var(--focus-ring-width) solid var(--color-status-danger-solid); outline-offset: 2px; }
.b--secondary { background: var(--color-bg-canvas); color: var(--color-text-primary); border-color: var(--color-border-default); }
.b--secondary:hover { background: var(--color-bg-surface); border-color: var(--color-border-strong); }
.b--ghost { background: none; color: var(--color-text-secondary); }
.b--ghost:hover { background: var(--color-bg-surface); color: var(--color-text-primary); }
.b--icon { width: 34px; padding: 0; }
.b--sm { height: 28px; padding: 0 10px; font-size: var(--tiny); }
.b:active:not(:disabled) { transform: translateY(1px); }
.b:disabled { background: var(--color-bg-surface); color: var(--color-text-disabled); border-color: transparent; cursor: not-allowed; }
.b--primary:disabled, .b--danger-solid:disabled { background: var(--color-action-primary-bg-disabled); color: var(--color-action-primary-text-disabled); }
.b:disabled kbd { border-color: currentColor; color: inherit; opacity: .55; }
.b--danger { color: var(--color-status-danger-fg); }
.link { border: 0; background: none; padding: 0; color: var(--color-text-link); cursor: pointer; text-decoration: underline; text-underline-offset: 2px; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); }
.link:hover { text-decoration-color: currentColor; }

/* Segmented control, chips, select-ish */
.seg { display: inline-flex; border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); overflow: hidden; }
.seg button { height: 32px; padding: 0 12px; border: 0; background: none; cursor: pointer; color: var(--color-text-secondary); white-space: nowrap; font-weight: var(--font-weight-medium); }
.seg button + button { border-left: 1px solid var(--color-border-default); }
.seg button[aria-pressed="true"] { background: var(--color-bg-surface); color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.seg .n { color: var(--color-text-tertiary); font-weight: var(--font-weight-regular); margin-left: 4px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); background: var(--color-bg-canvas); cursor: pointer; white-space: nowrap; color: var(--color-text-secondary); font-weight: var(--font-weight-medium); }
.chip:hover { border-color: var(--color-border-strong); color: var(--color-text-primary); }
.chip[aria-pressed="true"] { border-color: var(--color-text-primary); color: var(--color-text-primary); background: var(--color-bg-surface); }
.chip svg { width: 14px; height: 14px; }
.sel { height: 34px; padding: 0 30px 0 12px; border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); background: var(--color-bg-canvas) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center / 14px; appearance: none; cursor: pointer; font-weight: var(--font-weight-medium); }
.search { display: flex; align-items: center; gap: var(--space-2); height: 34px; padding: 0 var(--space-3); border: 1px solid var(--color-border-control); border-radius: var(--radius-sm); color: var(--color-text-tertiary); min-width: 220px; }
.search:focus-within { border-color: var(--color-text-primary); box-shadow: 0 0 0 3px var(--color-alpha-black-8); }   /* 18 Nov: neutral input focus */
.search input { border: 0; outline: 0; background: none; width: 100%; color: var(--color-text-primary); }

/* Status and Not set */
.st { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 7px; border-radius: var(--radius-xs); font-size: var(--tiny); font-weight: var(--font-weight-medium); white-space: nowrap; }
.st::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.st.plain::before { display: none; }
.st.accent { background: var(--color-bg-brand); color: var(--color-text-accent); }
.st.ok { background: var(--color-status-success-bg); color: var(--color-status-success-fg); }
.st.warn { background: var(--color-status-warning-bg); color: var(--color-status-warning-fg); }
.st.info { background: var(--color-status-info-bg); color: var(--color-status-info-fg); }
.st.bad { background: var(--color-status-danger-bg); color: var(--color-status-danger-fg); }
.st.neutral { background: var(--color-bg-surface); color: var(--color-text-secondary); }
.st.ink { background: var(--color-bg-inverse); color: var(--color-text-inverse); }
/* Standing (17 Nov): solids for final or paused states, tints for where a ranked creator stands. The seat tint is the one that pops;
   the pool (120+ rows) is a half-strength green so it stays quiet. */
.st.g-dq { background: var(--color-status-danger-solid); color: var(--color-status-danger-on-solid); }
.st.g-sus { background: var(--color-bg-inverse); color: var(--color-text-inverse); }
.st.g-cert { background: var(--color-bg-brand-strong); color: var(--color-text-on-accent); }
.st.g-miss { background: var(--color-status-danger-bg); color: var(--color-status-danger-fg); }
.st.g-seat { background: var(--color-lilac-100); color: var(--color-text-accent); }   /* the one that pops */
.st.g-near { background: var(--color-status-warning-bg); color: var(--color-status-warning-fg); }
.st.g-pool { background: color-mix(in srgb, var(--color-status-success-bg) 45%, var(--color-bg-canvas)); color: var(--color-status-success-fg); }
.st.g-pool::before { opacity: .55; }
/* Softer (17 Nov): one radius step up, no border, medium weight, 10px sides. */
.st[class*="g-"] { padding: 0 10px; border-radius: var(--radius-sm); font-weight: var(--font-weight-medium); box-shadow: none; }
.st.live::before { animation: pulse 1.6s var(--motion-easing-standard) infinite; }
@keyframes pulse { 50% { opacity: .25; } }
.notset { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border: 1px dashed var(--color-border-strong); border-radius: var(--radius-xs); font-size: 11px; font-weight: var(--font-weight-medium); color: var(--color-text-secondary); white-space: nowrap; vertical-align: 1px; }
.proposed { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border-radius: var(--radius-xs); background: var(--color-status-info-bg); color: var(--color-status-info-fg); font-size: 11px; font-weight: var(--font-weight-medium); }
.sample { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border-radius: var(--radius-xs); background: var(--color-status-warning-bg); color: var(--color-status-warning-fg); font-size: 11px; font-weight: var(--font-weight-semibold); }

/* ── Workspace: page + docked drawer ── */
.ws { flex: 1; min-height: 0; display: flex; }
.page { flex: 1; min-width: 0; overflow: auto; container-type: inline-size; container-name: page; }
.pad { padding: var(--space-6) var(--pad) var(--space-12); }
.ph { display: flex; align-items: flex-start; gap: var(--space-4); }
.ph h1 { margin: 0; font-family: var(--font-family-display); font-size: 22px; line-height: 1.2; font-weight: var(--font-weight-semibold); letter-spacing: -0.01em; }
.ph .acts { margin-left: auto; display: flex; gap: var(--space-2); flex: none; }
.lede { margin: var(--space-2) 0 0; max-width: 72ch; color: var(--color-text-secondary); font-size: 14px; }
.lede b { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.fresh { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-3); margin: var(--space-4) 0 var(--space-4); font-size: var(--tiny); color: var(--color-text-secondary); }
.fresh .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--color-text-tertiary); }
.fresh .link { color: var(--color-text-primary); font-weight: var(--font-weight-medium); }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }
.toolbar .end { margin-left: auto; display: flex; gap: var(--space-2); }
.legend { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-4); margin: var(--space-3) 0 var(--space-2); font-size: var(--tiny); color: var(--color-text-secondary); }
.legend .wk { vertical-align: -2px; }

/* Table */
.tbl { width: 100%; border-collapse: collapse; font-size: var(--row); }
.tbl th { position: sticky; top: 0; z-index: 2; background: var(--color-bg-canvas); text-align: left; font-size: var(--tiny); font-weight: var(--font-weight-medium); color: var(--color-text-secondary); padding: 10px 10px; border-bottom: 1px solid var(--color-border-default); white-space: nowrap; }
.tbl th.r, .tbl td.r { text-align: right; }
.tbl th button { border: 0; background: none; padding: 0; color: inherit; font: inherit; cursor: pointer; display: inline-flex; gap: 4px; align-items: center; }
.tbl th button[aria-pressed="true"] { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.tbl td { padding: 0 10px; height: 44px; border-bottom: 1px solid var(--color-border-subtle); white-space: nowrap; }
.tbl tbody tr { cursor: pointer; }
.tbl tbody tr:hover td { background: var(--color-bg-surface); }
.tbl tbody tr[aria-selected="true"] td { background: var(--color-bg-brand); }
.tbl .rk { width: 52px; text-align: right; font-weight: var(--font-weight-semibold); color: var(--color-text-primary); }
.tbl .rk.none { color: var(--color-text-tertiary); font-weight: var(--font-weight-regular); }
.tbl tr.seat td:first-child { box-shadow: inset 2px 0 0 var(--color-text-accent); }
.tbl tr.grey td { color: var(--color-text-tertiary); }
.tbl tr.grey .who img { filter: grayscale(1); opacity: .6; }
.mv { font-size: var(--tiny); color: var(--color-text-tertiary); display: inline-flex; align-items: center; gap: 2px; }
.mv.up { color: var(--color-text-primary); }
.mv svg { width: 12px; height: 12px; }
.who { display: flex; align-items: center; gap: 10px; min-width: 0; }
.who img, .av { width: 28px; height: 28px; border-radius: 50%; background: var(--color-bg-brand); object-fit: cover; object-position: center 18%; flex: none; }
.who b { font-weight: var(--font-weight-medium); }
.who small { display: block; font-size: 11px; color: var(--color-text-tertiary); line-height: 1.2; }
.score { font-weight: var(--font-weight-semibold); font-size: 14px; }
.prov { color: var(--color-text-tertiary); }
.split { font-size: var(--tiny); color: var(--color-text-tertiary); }
.toline { font-size: var(--tiny); color: var(--color-text-secondary); }
.toline.close { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.flagt { font-size: var(--tiny); color: var(--color-status-warning-fg); display: inline-flex; align-items: center; gap: 4px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
.flagt svg { width: 13px; height: 13px; }
.why { font-size: var(--tiny); color: var(--color-text-primary); display: inline-flex; gap: 6px; align-items: center; }

/* Week marks: one per pilot week */
.wks { display: inline-flex; gap: 3px; }
.wk { width: 12px; height: 12px; border-radius: 3px; border: 1.5px solid var(--color-text-primary); display: inline-block; position: relative; }
.wk.met { border-color: var(--color-bg-brand-strong); background: var(--color-bg-brand-strong); }
.wk.prog { border-color: var(--color-bg-brand-strong); background: linear-gradient(90deg, var(--color-bg-brand-strong) 50%, transparent 50%); }
.wk.miss { border-color: var(--color-status-danger-fg); background: repeating-linear-gradient(135deg, var(--color-status-danger-fg) 0 1.5px, transparent 1.5px 4px); }
.wk.todo { border-style: dashed; border-color: var(--color-border-strong); }

/* The certification line — the one bold element */
.tbl tr.cut td { height: auto; padding: 0; border: 0; cursor: default; background: none !important; }
.cutline { position: relative; display: flex; align-items: center; gap: var(--space-3); padding: 10px 12px; margin: 0; border-top: 2px solid var(--line); background: var(--color-bg-brand); color: var(--color-text-primary); font-size: var(--tiny); }
.cutline b { font-family: var(--font-family-display); font-size: 14px; font-weight: var(--font-weight-semibold); }
.cutline .seats { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; height: 22px; padding: 0 8px; border-radius: var(--radius-xs); background: var(--color-bg-inverse); color: var(--color-text-inverse); font-weight: var(--font-weight-semibold); }
.cutline .r { margin-left: auto; color: var(--color-text-secondary); }
.tbl tr.gap td { height: 36px; color: var(--color-text-tertiary); font-size: var(--tiny); text-align: center; background: var(--color-bg-surface) !important; cursor: default; }

@container page (max-width: 1080px) { .p3 { display: none; } }
@container page (max-width: 760px) { .p2 { display: none; } }
/* Standing is a key column: it stays at 1024; in its table, Provisional goes first instead. Hidden on phones like .p2. */
@container page (max-width: 1080px) { .has-std .p2 { display: none; } }
@container page (max-width: 760px) { .pstd { display: none; } }

/* ── Drawer (docked at 1440, overlays at 1024) ── */
.drawer { width: var(--drawer-w); flex: none; border-left: 1px solid var(--color-border-subtle); background: var(--color-bg-canvas); display: flex; flex-direction: column; min-height: 0; }
.dr__bar { display: flex; align-items: center; gap: var(--space-1); height: 48px; padding: 0 var(--space-3) 0 var(--space-5); border-bottom: 1px solid var(--color-border-subtle); flex: none; }
.dr__bar .t { font-size: var(--tiny); color: var(--color-text-tertiary); margin-right: auto; }
.dr__body { flex: 1; overflow: auto; }
.dr__id { display: flex; gap: var(--space-3); align-items: center; padding: var(--space-5) var(--space-5) 0; }
.dr__id img { width: 56px; height: 56px; border-radius: var(--radius-md); background: var(--color-bg-brand); object-fit: cover; object-position: center 18%; }
.dr__id h2 { margin: 0; font-family: var(--font-family-display); font-size: 18px; font-weight: var(--font-weight-semibold); display: flex; align-items: center; gap: var(--space-2); }
.dr__id p { margin: 2px 0 0; font-size: var(--tiny); color: var(--color-text-secondary); }
.dr__rank { margin: var(--space-3) var(--space-5) 0; font-size: var(--row); }
.dr__rank b { font-weight: var(--font-weight-semibold); }
.note { margin: var(--space-4) var(--space-5) 0; padding: var(--space-3); border-radius: var(--radius-sm); font-size: var(--tiny); display: flex; gap: var(--space-2); }
.note svg { margin-top: 1px; }
.note.warn { background: var(--color-status-warning-bg); color: var(--color-status-warning-fg); }
.note.bad { background: var(--color-status-danger-bg); color: var(--color-status-danger-fg); }
.note.info { background: var(--color-bg-surface); color: var(--color-text-secondary); }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: var(--space-4) var(--space-5) 0; border: 1px solid var(--color-border-subtle); border-radius: var(--radius-sm); }
.stats > div { padding: var(--space-2) var(--space-3); min-width: 0; }
.stats > div + div { border-left: 1px solid var(--color-border-subtle); }
.stats dt { font-size: 11px; color: var(--color-text-tertiary); white-space: nowrap; }
.stats dd { margin: 2px 0 0; font-size: 15px; font-weight: var(--font-weight-semibold); white-space: nowrap; }
.stats dd.soft { color: var(--color-text-secondary); font-weight: var(--font-weight-medium); }
.dr__acts { display: flex; gap: var(--space-2); flex-wrap: wrap; padding: var(--space-4) var(--space-5) 0; }
.subtabs { display: flex; gap: var(--space-1); padding: 0 var(--space-4); margin-top: var(--space-4); border-bottom: 1px solid var(--color-border-subtle); position: sticky; top: 0; background: var(--color-bg-canvas); z-index: 2; }
.subtabs button { position: relative; height: 40px; padding: 0 var(--space-2); border: 0; background: none; cursor: pointer; color: var(--color-text-secondary); font-weight: var(--font-weight-medium); }
.subtabs button[aria-selected="true"] { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.subtabs button[aria-selected="true"]::after { content: ""; position: absolute; left: var(--space-2); right: var(--space-2); bottom: -1px; height: 2px; background: var(--color-text-primary); }
.sec { padding: var(--space-4) var(--space-5); border-bottom: 1px solid var(--color-border-subtle); }
.sec h3 { margin: 0 0 var(--space-3); font-size: var(--row); font-weight: var(--font-weight-semibold); display: flex; align-items: center; gap: var(--space-2); }
.sec h3 .r { margin-left: auto; font-weight: var(--font-weight-regular); font-size: var(--tiny); color: var(--color-text-tertiary); }
.facts { display: grid; grid-template-columns: 116px minmax(0, 1fr); gap: 7px var(--space-3); margin: 0; font-size: var(--tiny); }
.facts dt { color: var(--color-text-tertiary); }
.facts dd { margin: 0; }
.lines { list-style: none; margin: 0; padding: 0; font-size: var(--tiny); }
.lines li { display: flex; align-items: center; gap: var(--space-2); padding: 8px 0; border-top: 1px solid var(--color-border-subtle); }
.lines li:first-child { border-top: 0; padding-top: 0; }
.lines .r { margin-left: auto; text-align: right; white-space: nowrap; color: var(--color-text-secondary); }
.lines b { font-weight: var(--font-weight-medium); font-size: var(--row); }
.spark { display: flex; align-items: flex-end; gap: 6px; height: 54px; }
.spark i { flex: 1; background: var(--color-border-default); border-radius: 3px 3px 0 0; position: relative; }
.spark i.now { background: var(--color-text-primary); }
.spark i span { position: absolute; top: -16px; left: 0; right: 0; text-align: center; font-size: 10px; font-style: normal; color: var(--color-text-tertiary); }

/* ── Queue + detail (Applications, Verification) ── */
.qd { flex: 1; min-width: 0; display: grid; grid-template-columns: var(--queue-w) minmax(0, 1fr); min-height: 0; }
.queue { border-right: 1px solid var(--color-border-subtle); display: flex; flex-direction: column; min-height: 0; }
.queue__head { padding: var(--space-5) var(--space-5) var(--space-3); border-bottom: 1px solid var(--color-border-subtle); }
.queue__head h1 { margin: 0; font-family: var(--font-family-display); font-size: 18px; font-weight: var(--font-weight-semibold); display: flex; align-items: center; gap: var(--space-2); }
.queue__head h1 .b { margin-left: auto; }
.queue__head p { margin: 4px 0 var(--space-3); font-size: var(--tiny); color: var(--color-text-secondary); }
.queue__head .toolbar { margin-top: var(--space-3); }
.qlist { list-style: none; margin: 0; padding: 0; overflow: auto; flex: 1; }
.qi { padding: var(--space-3) var(--space-5); border-bottom: 1px solid var(--color-border-subtle); cursor: pointer; position: relative; }
.qi:hover { background: var(--color-bg-surface); }
.qi[aria-selected="true"] { background: var(--color-bg-brand); }
.qi[aria-selected="true"]::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--color-text-accent); }
.qi .why { font-weight: var(--font-weight-semibold); margin-bottom: 4px; font-size: 11px; }
.qi .l1 { display: flex; align-items: center; gap: var(--space-2); }
.qi .l1 b { font-weight: var(--font-weight-semibold); }
.qi .l1 .r { margin-left: auto; font-size: var(--tiny); color: var(--color-text-secondary); }
.qi .l2 { font-size: var(--tiny); color: var(--color-text-tertiary); margin-top: 2px; }
.qi .prob { font-size: var(--tiny); color: var(--color-status-danger-fg); font-weight: var(--font-weight-medium); margin-top: 3px; }
.qi.done { opacity: .5; }
.horizon { padding: 10px var(--space-5); border-top: 2px solid var(--line); border-bottom: 1px solid var(--color-border-subtle); background: var(--color-bg-surface); font-size: var(--tiny); color: var(--color-text-secondary); }
.horizon b { color: var(--color-text-primary); }
.detail { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.dh { padding: var(--space-4) var(--space-6); border-bottom: 1px solid var(--color-border-subtle); display: flex; align-items: flex-start; gap: var(--space-3); }
.dh h2 { margin: 0; font-family: var(--font-family-display); font-size: 18px; font-weight: var(--font-weight-semibold); display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap; }
.dh h2 .ref { font-family: var(--font-family-body); font-size: var(--tiny); color: var(--color-text-tertiary); font-weight: var(--font-weight-regular); }
.dh p { margin: 4px 0 0; font-size: var(--tiny); color: var(--color-text-secondary); }
.dh .acts { margin-left: auto; display: flex; gap: var(--space-1); flex: none; }
.db { flex: 1; overflow: auto; padding: var(--space-5) var(--space-6) var(--space-8); }
.df { flex: none; display: flex; align-items: center; gap: var(--space-2); padding: var(--space-3) var(--space-6); border-top: 1px solid var(--color-border-subtle); background: var(--color-bg-canvas); }
.df .hint { font-size: var(--tiny); color: var(--color-text-tertiary); margin-right: auto; }
.twocol { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-8); }
.lbl { font-size: var(--tiny); font-weight: var(--font-weight-semibold); color: var(--color-text-secondary); margin: 0 0 var(--space-2); display: flex; align-items: center; gap: var(--space-2); }
.big { font-family: var(--font-family-display); font-size: 36px; font-weight: var(--font-weight-semibold); letter-spacing: -0.02em; line-height: 1; display: flex; align-items: center; gap: var(--space-3); }
.vfield { margin-top: var(--space-5); }
.vfield label { display: block; font-size: var(--tiny); font-weight: var(--font-weight-semibold); margin-bottom: 6px; }
.vfield .box { display: flex; align-items: center; height: 52px; border: 1.5px solid var(--color-text-primary); border-radius: var(--radius-sm); padding: 0 var(--space-3); gap: var(--space-2); }
.vfield .box:focus-within { outline: 1px solid var(--color-text-primary); outline-offset: 0; box-shadow: 0 0 0 4px var(--color-alpha-black-8); }
.vfield input { flex: 1; border: 0; outline: 0; background: none; font-size: 20px; font-weight: var(--font-weight-semibold); font-feature-settings: var(--font-feature-tabular); min-width: 0; }
.vfield input::placeholder { font-size: 14px; font-weight: var(--font-weight-regular); color: var(--color-text-tertiary); }
.effect { margin-top: var(--space-2); font-size: var(--tiny); color: var(--color-text-secondary); min-height: 36px; }
.effect b { color: var(--color-text-primary); }
.effect .cross { display: inline-flex; margin-left: 4px; padding: 1px 6px; border-radius: var(--radius-xs); background: var(--color-bg-inverse); color: var(--color-text-inverse); font-weight: var(--font-weight-semibold); }
.mini { width: 100%; border-collapse: collapse; font-size: var(--tiny); margin-top: var(--space-4); }
.mini th { text-align: right; font-weight: var(--font-weight-medium); color: var(--color-text-tertiary); padding: 6px 8px; border-bottom: 1px solid var(--color-border-default); }
.mini th:first-child, .mini td:first-child { text-align: left; padding-left: 0; }
.mini td { text-align: right; padding: 8px; border-bottom: 1px solid var(--color-border-subtle); font-feature-settings: var(--font-feature-tabular); }
.mini tr.latest td { font-weight: var(--font-weight-semibold); }
.checks { list-style: none; margin: var(--space-3) 0 0; padding: 0; font-size: var(--tiny); }
.checks li { display: flex; gap: var(--space-2); padding: 5px 0; align-items: baseline; }
.checks li::before { content: "·"; color: var(--color-text-tertiary); }

/* Evidence: a mock analytics screenshot, drawn, clearly labelled as sample */
.shot { margin-top: var(--space-3); border: 1px solid var(--color-border-default); border-radius: var(--radius-md); background: var(--color-bg-surface); padding: var(--space-5); display: grid; place-items: center; }
.phone { width: 240px; border-radius: 22px; background: #111; padding: 10px; box-shadow: var(--elevation-raised); }
.phone__in { border-radius: 14px; background: #fff; padding: 14px 14px 18px; color: #111; font-size: 11px; }
.phone__top { display: flex; justify-content: space-between; font-weight: 600; margin-bottom: 12px; color: #444; }
.phone__k { color: #777; font-size: 10px; }
.phone__v { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; margin: 2px 0 10px; }
.phone__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.phone__grid div { background: #f3f3f3; border-radius: 8px; padding: 8px; }
.phone__grid b { display: block; font-size: 14px; }
.phone__bars { display: flex; align-items: flex-end; gap: 3px; height: 40px; margin: 6px 0 12px; }
.phone__bars i { flex: 1; background: #d9d9d9; border-radius: 2px; }
.cap { font-size: var(--tiny); color: var(--color-text-tertiary); margin-top: var(--space-2); }

/* Applications */
.screen { width: 100%; border-collapse: collapse; font-size: var(--tiny); }
.screen th { text-align: left; font-weight: var(--font-weight-medium); color: var(--color-text-tertiary); padding: 6px 0; border-bottom: 1px solid var(--color-border-default); }
.screen td { padding: 9px 0; border-bottom: 1px solid var(--color-border-subtle); vertical-align: top; }
.screen td:first-child { font-weight: var(--font-weight-medium); width: 34%; }
.ex { display: grid; grid-template-columns: repeat(auto-fill, minmax(148px, 1fr)); gap: var(--space-3); }
.ex div { border: 1px solid var(--color-border-subtle); border-radius: var(--radius-sm); overflow: hidden; font-size: var(--tiny); }
.ex .thumb { aspect-ratio: 9 / 12; background: linear-gradient(160deg, var(--color-lilac-100), var(--color-lilac-300)); display: grid; place-items: end start; padding: 8px; color: var(--color-lilac-950); font-weight: var(--font-weight-semibold); }
.ex .thumb.broken { background: var(--color-bg-surface); color: var(--color-text-tertiary); place-items: center; font-weight: var(--font-weight-regular); }
.ex p { margin: 0; padding: 8px; }
.ex p small { display: block; color: var(--color-text-tertiary); }
.quote { margin: 0; padding: var(--space-3) var(--space-4); border-left: 3px solid var(--color-border-strong); background: var(--color-bg-surface); border-radius: 0 var(--radius-xs) var(--radius-xs) 0; font-size: var(--row); }
.block { margin-top: var(--space-6); }

/* Tasks */
.week { margin-top: var(--space-5); border: 1px solid var(--color-border-default); border-radius: var(--radius-md); overflow: hidden; }
.week.live { border-color: var(--color-text-primary); }
.week__h { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-3) var(--space-5); border-bottom: 1px solid var(--color-border-subtle); }
.week__h h2 { margin: 0; font-size: 15px; font-weight: var(--font-weight-semibold); }
.week__h .d { color: var(--color-text-secondary); font-size: var(--tiny); }
.week__h .acts { margin-left: auto; display: flex; gap: var(--space-2); }
.trow { display: grid; grid-template-columns: 140px minmax(0, 1fr) 220px auto; gap: var(--space-4); padding: var(--space-4) var(--space-5); align-items: start; }
.trow + .trow { border-top: 1px solid var(--color-border-subtle); }
.trow .k { font-size: var(--tiny); font-weight: var(--font-weight-semibold); color: var(--color-text-secondary); padding-top: 2px; }
.trow h3 { margin: 0; font-size: 14px; font-weight: var(--font-weight-semibold); }
.trow p { margin: 3px 0 0; font-size: var(--tiny); color: var(--color-text-secondary); }
.trow .meta { font-size: var(--tiny); color: var(--color-text-secondary); display: grid; gap: 3px; }
.trow .meta b { color: var(--color-text-primary); font-weight: var(--font-weight-medium); }
.trow.fb { background: var(--color-bg-surface); }
.bar { height: 6px; border-radius: 3px; background: var(--color-bg-surface); overflow: hidden; margin-top: 4px; }
.bar i { display: block; height: 100%; background: var(--color-text-primary); }

/* Referrals funnel */
.funnel { width: 100%; border-collapse: collapse; margin-top: var(--space-4); }
.funnel th { text-align: right; font-size: var(--tiny); font-weight: var(--font-weight-medium); color: var(--color-text-secondary); padding: 8px 10px; border-bottom: 1px solid var(--color-border-default); }
.funnel th:first-child { text-align: left; }
.funnel td { padding: 10px; border-bottom: 1px solid var(--color-border-subtle); text-align: right; font-feature-settings: var(--font-feature-tabular); vertical-align: middle; }
.funnel td:first-child { text-align: left; width: 34%; }
.funnel td .bar { width: 100%; margin-top: 6px; }
.funnel tr.q td { font-weight: var(--font-weight-semibold); }
.funnel .pct { font-size: var(--tiny); color: var(--color-text-tertiary); margin-left: 6px; }
.h2 { margin: var(--space-10) 0 var(--space-1); font-size: 16px; font-weight: var(--font-weight-semibold); display: flex; align-items: center; gap: var(--space-2); }
.h2 + p { margin: 0; font-size: var(--tiny); color: var(--color-text-secondary); }

/* Payouts */
.steps { list-style: none; margin: var(--space-5) 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid var(--color-border-default); border-radius: var(--radius-md); overflow: hidden; counter-reset: s; }
.steps li { counter-increment: s; padding: var(--space-3) var(--space-4); border-right: 1px solid var(--color-border-subtle); border-bottom: 1px solid var(--color-border-subtle); font-size: var(--tiny); display: flex; gap: var(--space-2); align-items: flex-start; }
.steps li:nth-child(3n) { border-right: 0; }
.steps li:nth-last-child(-n + 3) { border-bottom: 0; }
.steps li::before { content: counter(s); flex: none; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: var(--font-weight-semibold); border: 1.5px dashed var(--color-border-strong); color: var(--color-text-secondary); }
.steps li.ok::before { content: "✓"; background: var(--color-bg-inverse); color: var(--color-text-inverse); border: 0; }
.steps li.now::before { border-style: solid; border-color: var(--color-text-primary); color: var(--color-text-primary); }
.steps li b { display: block; font-size: var(--row); font-weight: var(--font-weight-medium); }
.steps li span { color: var(--color-text-secondary); }
.factsrow { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); margin-top: var(--space-5); border-top: 1px solid var(--color-border-default); border-bottom: 1px solid var(--color-border-default); }
.factsrow > div { padding: var(--space-3) var(--space-4) var(--space-3) 0; }
.factsrow > div + div { padding-left: var(--space-4); border-left: 1px solid var(--color-border-subtle); }
.factsrow dt { font-size: var(--tiny); color: var(--color-text-tertiary); }
.factsrow dd { margin: 4px 0 0; font-size: 18px; font-weight: var(--font-weight-semibold); font-feature-settings: var(--font-feature-tabular); }
.factsrow dd small { font-size: var(--tiny); font-weight: var(--font-weight-regular); color: var(--color-text-secondary); margin-left: 4px; }
.trybudget { display: inline-flex; align-items: center; gap: var(--space-2); font-size: var(--tiny); color: var(--color-text-secondary); }
.trybudget input { width: 140px; height: 32px; padding: 0 10px; border: 1px solid var(--color-border-control); border-radius: var(--radius-sm); font-feature-settings: var(--font-feature-tabular); }

/* Settings */
.set { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: var(--space-8); }
.setnav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; align-self: start; }
.setnav a { padding: 8px 12px; border-radius: var(--radius-sm); color: var(--color-text-secondary); text-decoration: none; font-weight: var(--font-weight-medium); }
.setnav a:hover { background: var(--color-bg-surface); color: var(--color-text-primary); }
.setnav a[aria-current] { background: var(--color-bg-surface); color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.rules td { white-space: normal; height: auto; padding: 12px 10px; vertical-align: top; }
.rules tbody tr { cursor: default; }
.rules td:first-child { font-weight: var(--font-weight-medium); width: 26%; }
.rules td small { display: block; color: var(--color-text-tertiary); font-size: 11px; margin-top: 2px; }
.rules .grp td { background: var(--color-bg-surface) !important; font-size: var(--tiny); font-weight: var(--font-weight-semibold); color: var(--color-text-secondary); padding: 8px 10px; }
.switch { position: relative; width: 36px; height: 20px; border-radius: 10px; background: var(--color-border-strong); border: 0; cursor: pointer; flex: none; transition: background-color var(--motion-duration-fast) var(--motion-easing-standard); }
.switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform var(--motion-duration-fast) var(--motion-easing-standard); }
.switch[aria-checked="true"] { background: var(--color-bg-inverse); }
.switch[aria-checked="true"]::after { transform: translateX(16px); }

/* Dialog, side panel, toast, palette */
dialog { border: 1px solid var(--color-border-default); border-radius: var(--radius-md); padding: 0; box-shadow: var(--elevation-dialog); background: var(--color-bg-canvas); color: var(--color-text-primary); width: min(560px, calc(100vw - 48px)); }
dialog.wide { width: min(680px, calc(100vw - 48px)); }
dialog::backdrop { background: var(--color-overlay-backdrop); }
.dlg__h { padding: var(--space-5) var(--space-6) 0; }
.dlg__h h2 { margin: 0; font-family: var(--font-family-display); font-size: var(--font-size-16); font-weight: var(--font-weight-semibold); }
.dlg__h p { margin: 6px 0 0; color: var(--color-text-secondary); font-size: var(--row); }
.dlg__b { padding: var(--space-4) var(--space-6); max-height: 60vh; overflow: auto; }
.dlg__f { display: flex; gap: var(--space-2); justify-content: flex-end; padding: var(--space-4) var(--space-6); border-top: 1px solid var(--color-border-subtle); }
.dlg__f .hint { margin-right: auto; align-self: center; font-size: var(--tiny); color: var(--color-text-tertiary); }
.field { display: grid; gap: 6px; margin-top: var(--space-4); font-size: var(--tiny); font-weight: var(--font-weight-semibold); }
.field:first-child { margin-top: 0; }
.field input, .field textarea, .field select { font-weight: var(--font-weight-regular); font-size: var(--row); padding: 8px 10px; border: 1px solid var(--color-border-control); border-radius: var(--radius-sm); background: var(--color-bg-canvas); }
.field textarea { min-height: 76px; resize: vertical; }
.field small { font-weight: var(--font-weight-regular); color: var(--color-text-tertiary); }
.cmp { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }
.cmp > div { border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); padding: var(--space-3); font-size: var(--tiny); }
.cmp > div.after { border-color: var(--color-text-primary); }
.cmp h4 { margin: 0 0 4px; font-size: 11px; color: var(--color-text-tertiary); font-weight: var(--font-weight-medium); }
.cmp b { font-size: var(--row); }
.pre { white-space: pre-wrap; font: var(--font-weight-regular) var(--font-size-12)/1.6 var(--font-family-body); font-variant-numeric: tabular-nums; background: var(--color-bg-surface); border-radius: var(--radius-sm); padding: var(--space-3) var(--space-4); margin: 0; max-height: 300px; overflow: auto; }
.panel { position: fixed; top: 0; right: 0; bottom: 0; width: min(var(--panel-w), 94vw); background: var(--color-bg-canvas); border-left: 1px solid var(--color-border-default); box-shadow: var(--elevation-dialog); z-index: 40; display: flex; flex-direction: column; }
.toast { position: fixed; z-index: 60; left: 50%; bottom: var(--space-6); transform: translateX(-50%); display: flex; align-items: center; gap: var(--space-4); padding: var(--space-2) var(--space-2) var(--space-2) var(--space-4); min-height: 44px; background: var(--color-bg-canvas); color: var(--color-text-primary); border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); box-shadow: var(--elevation-raised); font-size: var(--font-size-13); max-width: calc(100vw - 32px); }
.toast:not(:has(button)) { padding-right: var(--space-4); }
.toast button { height: 28px; padding: 0 var(--space-2); border: 0; border-radius: var(--radius-xs); background: none; color: var(--color-text-accent); font: inherit; font-weight: var(--font-weight-semibold); cursor: pointer; transition: background-color var(--motion-duration-fast) var(--motion-easing-out); }
.toast button:hover { background: var(--color-bg-brand); }
.pal { position: fixed; z-index: 70; top: 88px; left: 50%; transform: translateX(-50%); width: min(560px, calc(100vw - 32px)); background: var(--color-bg-canvas); border: 1px solid var(--color-border-default); border-radius: var(--radius-md); box-shadow: var(--elevation-dialog); overflow: hidden; }
.pal input { width: 100%; height: 52px; border: 0; border-bottom: 1px solid var(--color-border-subtle); padding: 0 var(--space-5); outline: 0; font-size: 15px; }
.pal ul { list-style: none; margin: 0; padding: var(--space-1); max-height: 340px; overflow: auto; }
.pal li { display: flex; align-items: center; gap: var(--space-3); padding: 8px var(--space-3); border-radius: var(--radius-xs); cursor: pointer; }
.pal li[aria-selected="true"], .pal li:hover { background: var(--color-bg-surface); }
.pal li .r { margin-left: auto; font-size: var(--tiny); color: var(--color-text-tertiary); }
.scrim { position: fixed; inset: 0; z-index: 65; background: color-mix(in srgb, var(--color-bg-inverse) 18%, transparent); }
.empty { text-align: center; padding: var(--space-16) var(--space-4); color: var(--color-text-secondary); }
.empty h3 { margin: 0 0 4px; color: var(--color-text-primary); font-size: var(--font-size-15); font-weight: var(--font-weight-semibold); }

/* ── Responsive ── */
@media (max-width: 1280px) { :root { --pad: var(--space-5); --drawer-w: 440px; --queue-w: 330px; } .role { display: none; } .top__title { margin-right: auto; } }
@media (max-width: 1180px) { .drawer { position: fixed; right: 0; top: calc(var(--top-h) + var(--tabs-h) + 1px); bottom: 0; z-index: 30; box-shadow: var(--elevation-dialog); } .twocol { grid-template-columns: 1fr; gap: var(--space-5); } .factsrow { grid-template-columns: repeat(3, minmax(0, 1fr)); } .factsrow > div:nth-child(4) { padding-left: 0; border-left: 0; border-top: 1px solid var(--color-border-subtle); } .factsrow > div:nth-child(n+4) { border-top: 1px solid var(--color-border-subtle); } }
@media (max-width: 900px) { .trow { grid-template-columns: 1fr; gap: var(--space-2); } .steps { grid-template-columns: 1fr; } .steps li { border-right: 0 !important; border-bottom: 1px solid var(--color-border-subtle) !important; } .set { grid-template-columns: 1fr; } .setnav { flex-direction: row; overflow-x: auto; position: static; } }
@media (max-width: 760px) { :root { --pad: var(--space-4); --top-h: 52px; }
  .rail { position: fixed; inset: 0 auto 0 0; z-index: 50; box-shadow: var(--elevation-dialog); transform: translateX(-105%); visibility: hidden; transition: transform var(--motion-duration-open) var(--motion-easing-out), visibility 0s linear var(--motion-duration-open); }
  .rail.open { transform: none; visibility: visible; transition: transform var(--motion-duration-open) var(--motion-easing-out); }
  .top__menu { display: grid; } .period { display: none; }
  .qd { grid-template-columns: 1fr; } .qd .detail { display: none; } .qd.show .queue { display: none; } .qd.show .detail { display: flex; }
  .drawer { left: 0; width: auto; top: var(--top-h); }
  .ph { flex-wrap: wrap; } .ph .acts { margin-left: 0; flex-wrap: wrap; }
  .factsrow { grid-template-columns: repeat(2, minmax(0, 1fr)); } .factsrow > div { padding-left: 0 !important; border-left: 0 !important; border-top: 1px solid var(--color-border-subtle); }
  .dh, .db, .df { padding-left: var(--space-4); padding-right: var(--space-4); } .df { flex-wrap: wrap; } .df .hint { flex-basis: 100%; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .stats > div:nth-child(3) { border-left: 0; } .stats > div:nth-child(n+3) { border-top: 1px solid var(--color-border-subtle); }
  .cutline { flex-wrap: wrap; } .cutline .r { margin-left: 0; flex-basis: 100%; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }

/* Fixes after the first browser pass */
.page { overflow-x: hidden; }
[tabindex="-1"]:focus { outline: none; }
@container page (max-width: 1080px) { .flagt span.ft { display: none; } .flagt { max-width: 28px; } }
.main { overflow: hidden; }
.exl li { padding: 10px 0; }
.exl .plat { flex: none; width: 76px; font-size: 11px; font-weight: var(--font-weight-semibold); color: var(--color-text-accent); }
@container page (max-width: 560px) { .p4 { display: none; } .tbl td, .tbl th { padding-left: 6px; padding-right: 6px; } .who small { display: none; } }
@media (max-width: 760px) {
  .ph .acts { width: 100%; } .ph .acts .b { flex: 1 1 auto; padding: 0 10px; }
  .toolbar .seg { max-width: 100%; overflow-x: auto; }
  .toolbar .end { margin-left: 0; width: 100%; } .toolbar .end .search { flex: 1; min-width: 0; } .toolbar .end .sel { flex: none; max-width: 46%; }
  .legend { gap: 4px 10px; }
}

/* 26 Nov · 390: toasts span the phone. left: 50% + translateX shrink-wrapped the toast to half the viewport (195px at 390),
   so the Tasks draft toast wrapped to five lines. Phones pin it 16px from each edge instead. */
@media (max-width: 560px) {
  .toast { left: var(--space-4); right: var(--space-4); transform: none; max-width: none; }
}
/* 26 Nov · 390: the hamburger rail slides in over the dialog scrim; tapping the scrim closes it (app.js #menuBtn). */
.rail-scrim { display: none; }
@media (max-width: 760px) {
  .rail-scrim { display: block; position: fixed; inset: 0; z-index: 49; background: var(--color-scrim-soft); opacity: 0; visibility: hidden; transition: opacity 200ms var(--motion-easing-exit), visibility 0s linear 200ms; }
  .rail.open + .rail-scrim { opacity: 1; visibility: visible; transition: opacity var(--motion-duration-open) var(--motion-easing-out); }
}


/* 26 Nov · tabular figures only where numbers live (Inter tnum also fixes the hyphen width, so never on body text: "Day-7", "top-up").
   Number holders without the .n class get it here; labels and headings stay proportional. */
.dt-n, .ovc-k b, .ovgg-c b, .ovpb-v, .ovr-v, td.r, .dw-figs dd, .p2-wait__i b, .p2-dm__n, .p2-pc__n, .p8__n, .p2-pcard__k b, .rp-k__v, .vwt__n, .qh__m, .dw-of, .sx-al time, .p2-sum, .p2-uc, .tb-sub { font-variant-numeric: tabular-nums; }
