/* Ragnar Mission Control — design system.
   Tokens are Reed's Ragnar funnel (funnel-mvps/ragnar-site + ragnar-ads*, extracted 2026-09-23):
   black-and-white industrial editorial. Ink #0B0B0B ground, raised #161616, white type, greys
   #A8A8A8 / #6E6E6E, hairlines #3A3A3A. Archivo 800 at 118% width, uppercase, for display; Archivo
   700 wide-tracked labels with a square bullet; Inter body. Square corners, no shadows, no accent
   colour: emphasis is black/white inversion. Colour appears ONLY where it carries data meaning
   (won / at risk / unknown), and even then muted. See docs/brand-tokens.md for the mapping. */

:root {
  /* funnel → mission control */
  --ink: #0b0b0b;            /* funnel --ink: every dark section */
  --ink-2: #161616;          /* funnel --ink-2: raised panel on black */
  --ink-3: #1d1d1d;          /* hover on a raised panel */
  --paper: #ffffff;          /* funnel --paper */
  --bone: #f2f2f0;           /* funnel --bone */
  --bg: var(--ink);
  --bg-2: var(--ink-2);
  --rail: var(--ink);
  --surface: var(--ink-2);
  --surface-2: var(--ink-3);
  --surface-solid: var(--ink-2);
  --modal: #101010;
  --line: rgba(255, 255, 255, 0.12);   /* funnel hairline on black is .18; .12 keeps dense tables calm */
  --line-2: #3a3a3a;                    /* funnel grey hairline */
  --line-3: rgba(255, 255, 255, 0.18);  /* funnel hairline on black, exact */
  --text: #ffffff;
  --text-2: #d9d9d9;
  --dim: #a8a8a8;            /* funnel body-on-black grey + first line of two-tone headlines */
  --muted: #8a8a8a;          /* funnel muted #6E6E6E is for large editorial type; small data text needs ≥4.5:1, so #8A8A8A (5.24:1 on #161616, 5.7:1 on #0B0B0B) */
  --faint: #6e6e6e;          /* funnel muted grey: decoration only (never information) */
  --brand: #ffffff;          /* the funnel's only "accent" is white */
  --brand-ink: #ffffff;
  --brand-soft: rgba(255, 255, 255, 0.07);
  --brand-line: rgba(255, 255, 255, 0.55);
  /* data-meaning colours (not in the funnel; used sparingly, muted) */
  --ok: #4fbf8a;
  --ok-soft: rgba(79, 191, 138, 0.10);
  --warn: #e0a846;
  --warn-soft: rgba(224, 168, 70, 0.10);
  --bad: #e06a5f;
  --bad-soft: rgba(224, 106, 95, 0.10);
  --violet: #a8a8a8;
  --violet-soft: rgba(255, 255, 255, 0.06);
  --r-card: 0;
  --r-ctl: 0;
  --shadow: none;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --display: 'Archivo', 'Inter', system-ui, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font: 14px/1.55 var(--font);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: 'cv11', 'ss01';
}
/* the funnel's film grain on dark sections (SVG fractal noise, 5.5%) */
body::before {
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: 0.055;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* no z-index here: a stacking context on .shell would trap the mobile menu (z 50) under the scrim (z 40).
   position alone paints the shell above the grain, by tree order. */
.shell, .login { position: relative; }
button, input, select { font: inherit; color: inherit; }
a { color: var(--text); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--text); }
:focus-visible { outline: 2px solid var(--paper); outline-offset: 2px; }
.num { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* labels: funnel .kick — Archivo 700, 112% width, .24em, uppercase, square bullet */
.kick {
  font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; letter-spacing: 0.24em;
  text-transform: uppercase; color: var(--muted);
}

/* ── App shell ─────────────────────────────────────────────────────────── */
.shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100vh;
  background: linear-gradient(90deg, transparent 247px, var(--line-2) 247px, var(--line-2) 248px, transparent 248px); }
@media (max-width: 960px) { .shell { background: none; } }
.rail {
  position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column;
  background: var(--rail); border-right: 1px solid var(--line-2); padding: 24px 16px 16px;
}
.brand { display: block; padding: 2px 8px 20px; border-bottom: 1px solid var(--line-2); margin-bottom: 14px; text-decoration: none; }
.brand img { display: block; width: 140px; height: auto; }
.brand .kick { display: block; margin-top: 12px; color: var(--dim); }
.nav { display: flex; flex-direction: column; gap: 1px; }
.nav .kick { padding: 14px 10px 6px; }
.nav a {
  display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-left: 2px solid transparent;
  color: var(--dim); font-weight: 500; text-decoration: none; transition: background 0.15s, color 0.15s;
}
.nav a svg { width: 17px; height: 17px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: square; stroke-linejoin: miter; }
.nav a:hover { background: var(--ink-2); color: var(--text); }
.nav a.on { color: var(--text); background: var(--ink-2); border-left-color: var(--paper); font-weight: 600; }
.nav a .step {
  margin-left: auto; font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; color: var(--muted);
  border: 1px solid var(--line-2); padding: 0 6px; line-height: 16px;
}
.nav a.on .step { color: var(--ink); background: var(--paper); border-color: var(--paper); }
.rail-foot { margin-top: auto; border-top: 1px solid var(--line-2); padding-top: 14px; display: flex; align-items: center; gap: 10px; }
.avatar {
  width: 32px; height: 32px; display: grid; place-items: center; flex: none;
  background: var(--paper); color: var(--ink); font-family: var(--display); font-stretch: 118%; font-weight: 800; font-size: 13px; text-transform: uppercase;
}
.who { min-width: 0; line-height: 1.25; }
.who b { display: block; font-size: 13px; text-transform: capitalize; }
.who span { font-size: 11.5px; color: var(--muted); }
.icon-btn {
  margin-left: auto; display: grid; place-items: center; width: 34px; height: 34px;
  background: transparent; border: 1px solid var(--line-2); color: var(--dim); cursor: pointer; transition: 0.15s;
}
.icon-btn:hover { color: var(--ink); border-color: var(--paper); background: var(--paper); }
.icon-btn svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: square; }

.main { min-width: 0; padding: 30px 36px 48px; }
.wrap { max-width: 1260px; margin: 0 auto; }
.topbar { display: none; }

/* ── Page header: two-tone funnel headline ────────────────────────────── */
.phead { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; padding-bottom: 20px; border-bottom: 1px solid var(--line-2); }
.phead .t { min-width: 0; flex: 1 1 320px; }
.phead .kick { color: var(--dim); display: inline-flex; align-items: center; gap: 10px; }
.phead .kick::before { content: ''; width: 7px; height: 7px; background: var(--paper); flex: none; }
h1 {
  font-family: var(--display); font-stretch: 118%; font-weight: 800; text-transform: uppercase;
  letter-spacing: -0.005em; font-size: 32px; line-height: 0.98; margin: 10px 0 10px;
}
h1 .g { color: var(--dim); }
.lede { color: var(--dim); margin: 0; max-width: 740px; }
.tools { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.rnote { font-size: 12px; color: var(--muted); max-width: 340px; }
.rnote:empty { display: none; }
.rnote.ok { color: var(--ok); }
.rnote.warn { color: var(--warn); }
.rnote.bad { color: var(--bad); }

.seg { display: inline-flex; border: 1px solid var(--line-2); flex-wrap: wrap; }
.seg button {
  border: 0; background: transparent; color: var(--dim); padding: 7px 11px;
  font-size: 12px; font-weight: 500; cursor: pointer; white-space: nowrap; transition: 0.15s;
}
.seg button + button { border-left: 1px solid var(--line-2); }
.seg button:hover { color: var(--text); background: var(--ink-2); }
.seg button.on { background: var(--paper); color: var(--ink); font-weight: 700; }
.seg button .c { opacity: 0.6; margin-left: 5px; font-weight: 600; }

.select {
  appearance: none; -webkit-appearance: none; background: var(--ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%23a8a8a8' stroke-width='1.8' stroke-linecap='square'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5'/%3E%3C/svg%3E") no-repeat right 10px center;
  border: 1px solid var(--line-2); padding: 7px 30px 7px 11px; font-size: 12.5px; cursor: pointer; max-width: 220px; border-radius: 0;
}
.select:hover, .select:focus { border-color: var(--paper); outline: none; }
.select.set { border-color: var(--paper); color: var(--text); }
.select option { background: var(--ink-2); }
.search {
  background: var(--ink); border: 1px solid var(--line-2); padding: 7px 11px 7px 32px; font-size: 12.5px; width: 220px; border-radius: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none' stroke='%23a8a8a8' stroke-width='1.8' stroke-linecap='square'%3E%3Ccircle cx='6' cy='6' r='4.5'/%3E%3Cpath d='m9.5 9.5 3 3'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: 11px center; -webkit-appearance: none;
}
.search::placeholder { color: var(--muted); }
.search:hover, .search:focus { border-color: var(--paper); outline: none; }

.pill {
  display: inline-flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--dim);
  border: 1px solid var(--line-2); padding: 7px 10px; white-space: nowrap;
}
.dot { width: 7px; height: 7px; background: var(--ok); flex: none; }
.dot.warn { background: var(--warn); }
.dot.bad { background: var(--bad); }

/* buttons: funnel .btn — Archivo 800, 112%, uppercase, tracked, square, 2px border */
.btn {
  display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line-2); background: transparent;
  color: var(--text); padding: 7px 12px; cursor: pointer; transition: 0.15s;
  font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase;
}
.btn:hover { border-color: var(--paper); background: var(--paper); color: var(--ink); }
.btn:disabled { opacity: 0.4; cursor: default; }
.btn:disabled:hover { background: transparent; color: var(--text); border-color: var(--line-2); }
.btn svg { width: 13px; height: 13px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: square; }
.btn.spin svg { animation: spin 0.9s linear infinite; }
.btn.primary { background: var(--paper); border: 2px solid var(--paper); color: var(--ink); }
.btn.primary:hover { background: transparent; color: var(--paper); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Cards & sections: funnel card = hairline + 4px top edge ───────────── */
.card { background: var(--ink-2); border: 1px solid var(--line-2); padding: 20px; }
.card.edge, .sec.card { border-top: 3px solid var(--paper); }
.card h2, .sec-h h2 {
  font-family: var(--display); font-stretch: 112%; font-weight: 800; text-transform: uppercase;
  font-size: 13px; letter-spacing: 0.06em; margin: 0;
}
.card .sub, .sec-h .sub { color: var(--dim); font-size: 12.5px; margin: 5px 0 0; }
.sec { margin-top: 30px; }
.sec-h { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.sec-h .t { flex: 1 1 280px; min-width: 0; }
.grid { display: grid; gap: 12px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.span2 { grid-column: span 2; }

/* ── Relay race (Tyler's four legs) ────────────────────────────────────── */
.relay { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; position: relative; border: 1px solid var(--line-2); }
.leg {
  position: relative; text-align: left; background: var(--ink-2); border: 0; color: inherit;
  padding: 18px 20px; cursor: pointer; transition: 0.15s; min-width: 0;
}
.leg + .leg { border-left: 1px solid var(--line-2); }
.leg:hover { background: var(--ink-3); }
.leg .n { font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; letter-spacing: 0.24em; color: var(--muted); text-transform: uppercase; }
.leg .name { font-family: var(--display); font-stretch: 118%; font-weight: 800; text-transform: uppercase; font-size: 15px; letter-spacing: 0; margin: 8px 0 12px; line-height: 1.05; }
.leg .big { font-family: var(--display); font-stretch: 112%; font-size: 34px; font-weight: 800; line-height: 1; }
.leg .cap { color: var(--dim); font-size: 12px; margin-top: 8px; }
.leg .who-leg { color: var(--text-2); font-size: 11.5px; margin-top: 10px; }
.leg .who-leg b { font-weight: 600; }
.leg .meta { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.leg .meta .badge { white-space: normal; line-height: 1.3; }
.leg.upstream { background: repeating-linear-gradient(135deg, rgba(255,255,255,0.018) 0 8px, transparent 8px 16px), var(--ink); }
.leg.upstream .big { color: var(--dim); }
.leg::after {
  content: ''; position: absolute; right: -9px; top: 50%; width: 16px; height: 16px; margin-top: -8px; z-index: 2;
  background: var(--paper);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' fill='none' stroke='%230b0b0b' stroke-width='2' stroke-linecap='square'%3E%3Cpath d='M3.5 2 6.5 5 3.5 8'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: center;
}
.leg:last-child::after { display: none; }
.boundary { display: flex; align-items: center; gap: 10px; margin: 10px 0 0; color: var(--muted); font-size: 11.5px; }
.boundary::before { content: ''; height: 1px; flex: 0 0 25%; background: var(--line-2); }
.boundary::after { content: ''; height: 1px; flex: 1; background: var(--line-2); }

/* ── Needs attention ───────────────────────────────────────────────────── */
.attn { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid var(--line-2); border-top: 3px solid var(--paper); background: var(--ink-2); }
.attn-i { padding: 16px 18px; min-width: 0; border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 8px; }
.attn-i:nth-child(3n) { border-right: 0; }
.attn-i .h { display: flex; align-items: baseline; gap: 10px; }
.attn-i .h .v { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 26px; line-height: 1; }
.attn-i .h .v.zero { color: var(--muted); }
.attn-i .h .l { font-family: var(--display); font-stretch: 112%; font-weight: 700; font-size: 10.5px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-2); }
.attn-i .d { color: var(--muted); font-size: 11.5px; }
.attn-i ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.attn-i li button {
  width: 100%; display: flex; gap: 10px; align-items: baseline; justify-content: space-between; text-align: left;
  background: transparent; border: 0; border-top: 1px solid var(--line); padding: 7px 0; color: var(--text); cursor: pointer; font-size: 12.5px;
}
.attn-i li button:hover { color: var(--paper); background: var(--ink-3); }
.attn-i li button span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.attn-i li button span:last-child { color: var(--dim); font-size: 11.5px; white-space: nowrap; flex: none; }
.attn-i .more { background: transparent; border: 0; color: var(--dim); font-size: 11.5px; padding: 6px 0 0; cursor: pointer; text-align: left; text-decoration: underline; text-underline-offset: 3px; }
.attn-i .more:hover { color: var(--text); }
.attn-i.hot { background: linear-gradient(180deg, var(--warn-soft), transparent 70%); }

/* ── KPI chain ─────────────────────────────────────────────────────────── */
.chain { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line-2); }
.chain .kpi { border: 0; border-right: 1px solid var(--line-2); }
.chain .kpi:last-child { border-right: 0; }
.kpi {
  position: relative; text-align: left; background: var(--ink-2); border: 1px solid var(--line-2);
  padding: 14px 14px 13px; cursor: pointer; transition: 0.15s; color: inherit; min-width: 0; display: flex; flex-direction: column;
}
.kpi:hover { background: var(--ink-3); box-shadow: inset 0 3px 0 var(--paper); }
div.kpi { cursor: default; }
div.kpi:hover { background: var(--ink-2); box-shadow: none; }
.kpi .lab { font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; color: var(--dim); letter-spacing: 0.14em; text-transform: uppercase; min-height: 28px; line-height: 1.35; }
.kpi .val { font-family: var(--display); font-stretch: 112%; font-size: 30px; font-weight: 800; line-height: 1; margin: 10px 0 10px; }
.kpi .foot { margin-top: auto; font-size: 11px; color: var(--muted); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.kpi .rule { font-size: 10px; color: var(--muted); letter-spacing: 0.08em; text-transform: uppercase; margin-top: 6px; }
.kpi.na { background: var(--ink); }
.kpi .val.bad { color: var(--bad); }
.kpi .val.sm { font-size: 20px; line-height: 1.2; }
.kpi .val.dim { font-size: 16px; color: var(--muted); }
.kpi .track { margin: 0 0 10px; }
.kpi.na .val { font-family: var(--font); font-size: 12.5px; font-weight: 600; color: var(--muted); line-height: 1.3; margin: 10px 0; }
.kpi .ix { position: absolute; top: 12px; right: 12px; font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; color: var(--muted); }
.kpi.hero { background: var(--paper); color: var(--ink); }
.kpi.hero .lab, .kpi.hero .foot, .kpi.hero .ix, .kpi.hero .rule { color: #3a3a3a; }
.kpi.hero:hover { background: var(--bone); box-shadow: none; }
.chain-note { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px; color: var(--muted); font-size: 12px; }
.chain-note b { color: var(--text-2); font-weight: 600; }

.stat { display: flex; flex-direction: column; gap: 5px; }
.stat .v { font-family: var(--display); font-stretch: 112%; font-size: 32px; font-weight: 800; line-height: 1.02; }
.stat .l { color: var(--dim); font-size: 12.5px; }
.stat .x { color: var(--muted); font-size: 11.5px; }

/* ── Badges: square tags ───────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: 5px; font-family: var(--display); font-stretch: 112%; font-size: 9.5px; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; padding: 2px 7px; border: 1px solid var(--line-2); color: var(--dim); white-space: nowrap; line-height: 16px;
}
.badge.ok { color: var(--ok); border-color: rgba(79,191,138,0.4); }
.badge.warn { color: var(--warn); border-color: rgba(224,168,70,0.45); }
.badge.bad { color: var(--bad); border-color: rgba(224,106,95,0.45); }
.badge.brand { color: var(--ink); background: var(--paper); border-color: var(--paper); }
.badge.violet { color: var(--text-2); border-color: var(--line-3); border-style: dashed; }
.badge.plain { font-family: var(--font); font-stretch: 100%; text-transform: none; letter-spacing: 0; font-weight: 500; font-size: 11.5px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips .badge.plain { white-space: nowrap; }

/* ── Bars (stage boards, source lists) ─────────────────────────────────── */
.stages { display: flex; flex-direction: column; gap: 1px; }
.stage {
  display: grid; grid-template-columns: minmax(0, 230px) minmax(0, 1fr) 64px; gap: 12px; align-items: center;
  padding: 8px 10px; cursor: pointer; border: 0; border-left: 2px solid transparent; background: transparent; color: inherit; text-align: left; width: 100%;
}
.stage:hover { background: var(--ink-3); }
.stage.on { background: var(--ink-3); border-left-color: var(--paper); }
.stage .nm { font-size: 12.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stage .nm i { font-style: normal; color: var(--muted); margin-right: 8px; font-size: 11px; font-family: var(--display); font-stretch: 112%; font-weight: 700; }
.stage .ct { text-align: right; font-family: var(--display); font-stretch: 112%; font-weight: 800; }
.stage.zero .nm, .stage.zero .ct { color: var(--muted); }
/* Overview · Where the numbers come from (2026-11-17): KPI chips, a bar per channel, then the table with sources one click down. */
.bd-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 10px; }
.bd-chip { border: 1px solid var(--line-2); background: transparent; color: var(--text-2); padding: 6px 10px; font-size: 12.5px; cursor: pointer; }
.bd-chip.on { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.bd-chip .num { font-weight: 700; margin-left: 4px; }
.bd-chart { display: flex; flex-direction: column; gap: 2px; }
.bd-bar { display: grid; grid-template-columns: minmax(0, 160px) minmax(0, 1fr) 96px; gap: 12px; align-items: center; padding: 8px 10px; border: 0; background: transparent; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.bd-bar:hover { background: var(--ink-3); }
.bd-val { text-align: right; }
/* KPI panel, chart first (2026-11-17). */
.kp-top h3 { margin: 14px 0 2px; font-size: 13px; }
.kp-num { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 4px 0 6px; }
.kp-num > .num { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 40px; line-height: 1; }
.ok-t { color: var(--ok, #3fb37f); font-weight: 700; }
.bad-t { color: var(--bad, #e5675f); font-weight: 700; }
.bd-bar.on { background: var(--ink-3); outline: 1px solid var(--paper); }
.kp-list > summary { cursor: pointer; padding: 10px 0; list-style: revert; }
.kp-def > summary { cursor: pointer; padding: 6px 0; color: var(--text-2); list-style: revert; }
tr.bd-src td { background: rgba(255,255,255,0.02); }
tr.bd-src td:first-child { padding-left: 28px; }
.track { height: 8px; background: rgba(255,255,255,0.06); overflow: hidden; display: flex; }
.track > span { display: block; height: 100%; background: var(--paper); min-width: 0; }
.track > span.won { background: var(--ok); }
.track > span.lost { background: var(--bad); opacity: 0.75; }
.track > span.unk { background: var(--warn); }
.track > span.grey { background: #3a3a3a; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 11.5px; color: var(--dim); margin-top: 12px; }
.legend i { display: inline-block; width: 8px; height: 8px; margin-right: 6px; vertical-align: 0; }
.legend .b { background: var(--paper); } .legend .o { background: var(--ok); } .legend .r { background: var(--bad); } .legend .w { background: var(--warn); }

.srcs { display: flex; flex-direction: column; gap: 4px; }
.src { display: grid; grid-template-columns: minmax(0, 170px) minmax(0, 1fr) 100px; gap: 12px; align-items: center; padding: 5px 6px; }
button.src { width: 100%; background: transparent; border: 0; border-left: 2px solid transparent; color: inherit; text-align: left; cursor: pointer; }
button.src:hover { background: var(--ink-3); border-left-color: var(--paper); }
.src .nm { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.src .ct { text-align: right; font-size: 12.5px; color: var(--dim); }
.src .ct b { color: var(--text); font-weight: 700; }
.src.unknown .nm { color: var(--warn); font-weight: 700; }

/* ── Tables ────────────────────────────────────────────────────────────── */
.table-card { padding: 0; overflow: hidden; }
.table-head { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 14px 16px; border-bottom: 1px solid var(--line-2); }
.table-head .t { flex: 1 1 200px; min-width: 0; }
/* an empty-state row stays in view inside a table that scrolls sideways (phones) */
.tscroll td[colspan] .empty { position: sticky; left: 0; max-width: calc(100vw - 32px); }
.tscroll { overflow-x: auto;
  /* scroll hint: a right-edge shade that appears only while more columns are off-screen */
  background: linear-gradient(90deg, var(--ink-2) 30%, rgba(22,22,22,0)) left / 28px 100% no-repeat local,
              linear-gradient(270deg, var(--ink-2) 30%, rgba(22,22,22,0)) right / 28px 100% no-repeat local,
              radial-gradient(farthest-side at 100% 50%, rgba(255,255,255,0.14), transparent) right / 12px 100% no-repeat scroll; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th {
  text-align: left; font-family: var(--display); font-stretch: 112%; font-size: 9.5px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
  padding: 11px 14px; border-bottom: 1px solid var(--line-2); white-space: nowrap; background: var(--ink);
}
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--text); }
th .arr { opacity: 0.35; margin-left: 4px; }
th.sorted { color: var(--text); }
th.sorted .arr { opacity: 1; color: var(--paper); }
td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr { transition: background 0.12s; }
tbody tr.click { cursor: pointer; }
tbody tr.click:hover { background: var(--ink-3); box-shadow: inset 2px 0 0 var(--paper); }
tbody tr:last-child td { border-bottom: 0; }
td .who-c { font-weight: 600; color: var(--text); }
td .sub-c { color: var(--muted); font-size: 11.5px; margin-top: 1px; }
td .why-c { overflow-wrap: anywhere; max-width: 28ch; }
td.r, th.r { text-align: right; }
.unk { color: var(--warn); font-weight: 600; }
.mut { color: var(--muted); }
.pager { display: flex; align-items: center; gap: 10px; justify-content: space-between; padding: 12px 16px; border-top: 1px solid var(--line-2); color: var(--dim); font-size: 12px; flex-wrap: wrap; }
.pager .btns { display: flex; gap: 6px; }

/* ── States ────────────────────────────────────────────────────────────── */
.sk { display: block; background: linear-gradient(90deg, rgba(255,255,255,0.04), rgba(255,255,255,0.08), rgba(255,255,255,0.04)); background-size: 200% 100%; animation: sk 1.3s ease-in-out infinite; }
@keyframes sk { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
.sk.h { height: 110px; } .sk.l { height: 14px; margin: 8px 0; } .sk.t { height: 320px; }
.empty { text-align: center; padding: 40px 20px; color: var(--dim); }
.empty svg { width: 32px; height: 32px; stroke: var(--muted); fill: none; stroke-width: 1.5; margin-bottom: 8px; }
.empty b { display: block; color: var(--text); font-family: var(--display); font-stretch: 112%; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; font-size: 12px; margin-bottom: 6px; }
.alert {
  display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; font-size: 13px;
  border: 1px solid var(--line-2); border-left: 3px solid var(--paper); background: var(--ink-2); color: var(--text-2);
}
.alert svg { width: 17px; height: 17px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: square; margin-top: 1px; }
.alert.warn { border-left-color: var(--warn); background: var(--warn-soft); }
.alert.warn svg { color: var(--warn); }
.alert.bad { border-left-color: var(--bad); background: var(--bad-soft); }
.alert.bad svg { color: var(--bad); }
.alert.info { border-left-color: var(--paper); }
.alert .grow { flex: 1; min-width: 0; }
.alert b { color: #fff; }
.note { color: var(--muted); font-size: 12px; margin-top: 10px; }
.note b { color: var(--dim); }
.defs { color: var(--muted); font-size: 12.5px; margin: 10px 0 0 18px; line-height: 1.55; overflow-wrap: anywhere; }

/* ── Appointments split ────────────────────────────────────────────────── */
.split-h { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.split-h .ic { width: 38px; height: 38px; display: grid; place-items: center; flex: none; }
.split-h .ic svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: square; }
.ic.phone { border: 1px dashed var(--line-3); color: var(--text-2); }
.ic.house { background: var(--paper); color: var(--ink); }
.ic.other { border: 1px solid var(--line-2); color: var(--dim); }
.mini { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; margin-top: 14px; border: 1px solid var(--line-2); }
.mini > div, .mini > button { background: var(--ink); border: 0; border-right: 1px solid var(--line-2); padding: 10px 12px; text-align: left; color: inherit; }
.mini > :last-child { border-right: 0; }
.mini .v { font-family: var(--display); font-stretch: 112%; font-size: 21px; font-weight: 800; }
.mini .l { font-size: 11px; color: var(--dim); }

/* ── Drawer ────────────────────────────────────────────────────────────── */
.scrim { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.66); z-index: 40; opacity: 0; transition: opacity 0.2s; }
.scrim.open { opacity: 1; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(660px, 100vw); z-index: 41; background: var(--modal);
  border-left: 1px solid var(--line-2);
  display: flex; flex-direction: column; transform: translateX(100%); transition: transform 0.24s cubic-bezier(.2,.8,.2,1);
}
.drawer.open { transform: none; }
.dhead { padding: 20px 20px 16px; border-bottom: 1px solid var(--line-2); display: flex; gap: 12px; align-items: flex-start; border-top: 3px solid var(--paper); }
.dhead .t { flex: 1; min-width: 0; }
.dhead h3 { font-family: var(--display); font-stretch: 118%; font-weight: 800; text-transform: uppercase; font-size: 19px; line-height: 1.05; margin: 8px 0 6px; }
.dhead .sub { color: var(--dim); font-size: 12.5px; }
.dbody { flex: 1; overflow-y: auto; padding: 18px 20px 28px; }
.dsec { margin-bottom: 24px; }
.dsec > .kick { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; color: var(--dim); }
.dsec > .kick::before { content: ''; width: 6px; height: 6px; background: var(--paper); }
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line-2); }
.fact { background: var(--ink); padding: 10px 12px; min-width: 0; border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.fact:nth-child(2n) { border-right: 0; }
.fact .l { font-family: var(--display); font-stretch: 112%; font-size: 9.5px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.fact .v { font-size: 13.5px; font-weight: 600; margin-top: 3px; overflow-wrap: anywhere; }
.relaybar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line-2); margin-bottom: 12px; }
.relaybar span { padding: 8px 10px; font-family: var(--display); font-stretch: 112%; font-size: 9.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); border-right: 1px solid var(--line-2); }
.relaybar span:last-child { border-right: 0; }
.relaybar span.done { color: var(--dim); background: var(--ink-2); }
.relaybar span.now { color: var(--ink); background: var(--paper); }
.relaybar span small { display: block; font-family: var(--font); font-stretch: 100%; letter-spacing: 0; text-transform: none; font-weight: 500; font-size: 11px; margin-top: 2px; }
.timeline { position: relative; padding-left: 20px; }
.timeline::before { content: ''; position: absolute; left: 4px; top: 6px; bottom: 6px; width: 1px; background: var(--line-2); }
.tl { position: relative; padding: 4px 0 11px; }
.tl::before { content: ''; position: absolute; left: -20px; top: 9px; width: 9px; height: 9px; background: var(--ink); border: 2px solid var(--paper); }
.tl.ok::before { border-color: var(--ok); background: var(--ok); } .tl.bad::before { border-color: var(--bad); } .tl.warn::before { border-color: var(--warn); } .tl.grey::before { border-color: var(--muted); }
.tl.undated .a { color: var(--muted); font-weight: 500; }
.tl .a { font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.tl .b { font-size: 11.5px; color: var(--muted); overflow-wrap: anywhere; }
.opp { border: 1px solid var(--line-2); padding: 12px 14px; margin-bottom: 8px; background: var(--ink); }
.opp .top { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.opp .top b { font-size: 13px; line-height: 20px; }
.opp .ms { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; font-size: 12px; color: var(--dim); }
.opp .ms span b { color: var(--text-2); font-weight: 600; }
.why { padding: 10px 12px; font-size: 12.5px; margin-bottom: 6px; border: 1px solid var(--line-2); border-left-width: 3px; }
.why.in { border-left-color: var(--ok); background: var(--ok-soft); }
.why.out { border-left-color: var(--warn); background: var(--warn-soft); }
.why b { color: #fff; }
.back { background: transparent; border: 0; color: var(--dim); cursor: pointer; padding: 0; font-size: 12px; display: inline-flex; gap: 4px; align-items: center; }
.back:hover { color: var(--text); text-decoration: underline; }
dl.def { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 8px 14px; margin: 0; font-size: 12.5px; }
dl.def dt { color: var(--muted); }
dl.def dd { margin: 0; color: var(--text-2); }

.foot-meta { margin-top: 38px; padding-top: 14px; border-top: 1px solid var(--line-2); color: var(--muted); font-size: 11.5px; display: flex; gap: 14px; flex-wrap: wrap; }

.toast {
  position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%) translateY(20px); opacity: 0; z-index: 60;
  background: var(--paper); color: var(--ink); padding: 10px 16px; font-size: 12.5px; font-weight: 600; transition: 0.2s; pointer-events: none;
}
.toast.show { opacity: 1; transform: translateX(-50%); }

/* ── Login ─────────────────────────────────────────────────────────────── */
.login-body { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; background: var(--ink); }
.login { width: 100%; max-width: 440px; }
.login .logo { display: block; width: 200px; max-width: 70%; height: auto; margin: 0 auto 28px; }
.login-card { background: var(--ink-2); border: 1px solid var(--line-2); border-top: 3px solid var(--paper); padding: 34px 32px 30px; }
.login-card .kick { display: inline-flex; align-items: center; gap: 10px; color: var(--dim); }
.login-card .kick::before { content: ''; width: 7px; height: 7px; background: var(--paper); }
.login-card h1 { font-size: 30px; margin: 12px 0 8px; text-align: left; }
.login-card .lede { font-size: 13px; margin-bottom: 24px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--dim); margin-bottom: 8px; }
.inp {
  width: 100%; background: var(--ink); border: 1px solid var(--line-2); padding: 13px 14px; font-size: 15px; color: var(--text); border-radius: 0;
  transition: border-color 0.15s;
}
.inp:focus { outline: none; border-color: var(--paper); }
.inp[aria-invalid="true"] { border-color: var(--bad); }
.pw { position: relative; }
.pw .inp { padding-right: 46px; }
.pw button { position: absolute; right: 5px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; background: transparent; color: var(--dim); cursor: pointer; display: grid; place-items: center; }
.pw button:hover { color: var(--text); }
.pw button svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: square; }
.submit { width: 100%; justify-content: center; padding: 18px 20px; font-size: 13px; margin-top: 8px; }
.submit .spinner { width: 15px; height: 15px; border: 2px solid rgba(11,11,11,0.3); border-top-color: var(--ink); border-radius: 50%; animation: spin 0.8s linear infinite; }
.login .alert { margin-bottom: 16px; }
.login-foot { text-align: center; color: var(--muted); font-size: 12px; margin-top: 18px; }

/* ── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 1180px) {
  .chain { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .chain .kpi:nth-child(3n) { border-right: 0; }
  .chain .kpi:nth-child(-n+6) { border-bottom: 1px solid var(--line-2); }
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .attn { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .attn-i:nth-child(3n) { border-right: 1px solid var(--line-2); }
  .attn-i:nth-child(2n) { border-right: 0; }
}
@media (max-width: 960px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .rail { position: fixed; left: 0; top: 0; bottom: 0; width: 264px; z-index: 50; transform: translateX(-100%); transition: transform 0.22s; }
  .rail.open { transform: none; }
  .topbar {
    display: flex; align-items: center; gap: 12px; position: sticky; top: 0; z-index: 30; height: 56px; padding: 0 16px;
    background: var(--ink); border-bottom: 1px solid var(--line-2);
  }
  .topbar img { height: 18px; width: auto; }
  .topbar .kick { margin-left: 2px; }
  .topbar .icon-btn { margin-left: 0; }
  .topbar .sp { flex: 1; }
  .main { padding: 22px 16px 40px; }
  .relay { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .leg:nth-child(3) { border-left: 0; }
  .leg:nth-child(-n+2) { border-bottom: 1px solid var(--line-2); }
  .leg::after { display: none; }
  .g3 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 700px) {
  h1 { font-size: 25px; }
  .g2, .g4 { grid-template-columns: minmax(0, 1fr); }
  .span2 { grid-column: auto; }
  .chain { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chain .kpi, .chain .kpi:nth-child(3n) { border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
  .chain .kpi:nth-child(2n) { border-right: 0; }
  .chain .kpi:nth-last-child(-n+2) { border-bottom: 0; }
  .attn { grid-template-columns: minmax(0, 1fr); }
  .attn-i, .attn-i:nth-child(3n) { border-right: 0; }
  .relaybar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .relaybar span:nth-child(2) { border-right: 0; }
  .relaybar span:nth-child(-n+2) { border-bottom: 1px solid var(--line-2); }
  .stage { grid-template-columns: minmax(0, 1fr) 40px; }
  .stage .track { grid-column: 1 / -1; grid-row: 2; }
  .src { grid-template-columns: minmax(0, 1fr) 90px; }
  .src .track { grid-column: 1 / -1; grid-row: 2; }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .fact { border-right: 0; }
  .search { width: 100%; }
  .table-head .select { flex: 1 1 140px; max-width: none; }
  .phead .tools { width: 100%; }
  .mini { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hide-m { display: none; }
  td, th { padding: 10px 12px; }
  .login-card { padding: 28px 22px 24px; }
  dl.def { grid-template-columns: minmax(0, 1fr); gap: 2px 0; }
  dl.def dd { margin-bottom: 8px; }
}
/* System health (2026-10-08) */
.hl-sec { display: flex; flex-direction: column; gap: 6px; }
.hl-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 10px; }
/* A heading's badge ('Owner: Jarred's operations system', 209 px) is nowrap: on a 320 px phone the row WRAPS it under the
   title instead of pushing the page 46 px sideways; one too wide even for its own line breaks inside its box. */
.hl-head > .badge { max-width: 100%; white-space: normal; }
.hl-head h2 { margin: 0; }
.hl-items { margin: 8px 0 0; display: grid; }
.hl-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 8px 0; border-top: 1px solid var(--line); }
.hl-row dt { color: var(--dim); font-size: 12.5px; display: flex; align-items: center; gap: 7px; min-width: 0; }
.hl-row dd { margin: 0; text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; min-width: 0; }
.hl-row dd b { font-weight: 600; color: var(--text-2); overflow-wrap: anywhere; }
.hl-row dd .nt { color: var(--muted); font-size: 11.5px; max-width: 34ch; overflow-wrap: anywhere; }
.hl-row.is-warn dd b { color: var(--warn); } .hl-row.is-bad dd b { color: var(--bad); }
.dot.none { background: transparent; }
.hl-rej h3 { font-size: 12.5px; color: var(--dim); margin: 12px 0 6px; font-weight: 600; }
.hl-rej ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.hl-rej li { display: flex; align-items: center; gap: 8px; } .hl-rej li span:first-child { flex: 1; min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 700px) { .hl-row { flex-direction: column; gap: 4px; } .hl-row dd { align-items: flex-start; text-align: left; } .hl-row dd .nt { max-width: none; } }
.empty-note { padding: 6px 0; } .empty-note b { display: block; margin-bottom: 4px; }
/* Ads & funnel (2026-10-09) */
.sec-t { font-size: 14px; margin: 22px 0 10px; letter-spacing: .02em; }
.ads-filters { gap: 14px; margin-bottom: 4px; } .ads-filters select { margin-left: 6px; max-width: 220px; background: var(--paper); color: #000; border: 0; padding: 4px 6px; }
.dim { color: var(--dim); }
@media (max-width: 700px) { .ads-filters { flex-direction: column; align-items: flex-start; } .ads-filters select { max-width: 70vw; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* utilities (no inline style attributes: the CSP forbids them) */
.mt10 { margin-top: 10px; } .mt14 { margin-top: 14px; } .mt16 { margin-top: 16px; }
.mb12 { margin-bottom: 12px; } .mb16 { margin-bottom: 16px; } .mb18 { margin-bottom: 18px; }
.gap { display: block; height: 14px; } .gap10 { gap: 10px; }
.segm { margin: 18px 0 12px; }
.para { margin: 14px 0 0; color: var(--text-2); font-size: 13px; }
.minikpi { padding: 10px 12px; cursor: pointer; }
.minikpi:hover { background: var(--ink-3) !important; }
.chain-note svg { vertical-align: -2px; margin-right: 4px; }
.leg { display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; }
.kpi { align-items: stretch; justify-content: flex-start; }
.kpi .lab { padding-right: 16px; }
.kpi .foot .badge { white-space: normal; text-align: left; line-height: 1.3; padding: 3px 7px; }
.cap-name { text-transform: capitalize; }
.team { display: flex; flex-direction: column; gap: 0; margin-top: 12px; }
.team button { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 12px; align-items: center; background: transparent; border: 0; border-top: 1px solid var(--line); padding: 8px 2px; color: inherit; cursor: pointer; text-align: left; font-size: 12.5px; }
.team button:hover { background: var(--ink-3); }
.team .n { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 15px; }
.team .s { color: var(--muted); font-size: 11.5px; }

/* Resolved date range under the preset buttons (2026-10-08): the dates are always shown. */
.rdates { flex-basis: 100%; margin-top: 8px; font-size: 12.5px; color: var(--dim); display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.rdates b { color: var(--text); font-weight: 600; }
.rdates .kick { margin: 0; }
.rcustom { display: inline-flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.rcustom input { background: var(--ink-2); color: var(--text); border: 1px solid var(--line-2); padding: 4px 6px; font: inherit; color-scheme: dark; }
.rcustom .warn-t { color: #E0A846; }

/* Ads & funnel visuals (2026-10-15): money funnel, daily chart, creative thumbnails. SVG geometry is set by attributes,
   never inline styles (CSP). Data colours follow the system: white = money/volume, --ok = Meta-attributed leads. */
.mfunnel { display: grid; grid-template-columns: minmax(0, 1.45fr) repeat(6, minmax(0, 1fr)); gap: 0; padding: 0; }
.mf-step { padding: 16px 14px 14px; border-left: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.mf-step:first-child { border-left: 0; }
.mf-spend { background: var(--paper); color: var(--ink); }
.mf-spend .mf-lab, .mf-spend .mf-foot, .mf-spend .dim { color: #3a3a3a; }
.mf-lab { font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--dim); min-height: 2.9em; line-height: 1.45; }  /* two lines reserved so every value aligns */
.mf-val { font-family: var(--display); font-stretch: 112%; font-size: 26px; font-weight: 800; line-height: 1; white-space: nowrap; }
.mf-spend .mf-val { font-size: 24px; }
.mf-bar { width: 100%; height: 6px; display: block; }
.mf-track { fill: rgba(255, 255, 255, 0.08); } .mf-fill { fill: var(--paper); }
.mf-spend .mf-track { fill: rgba(0, 0, 0, 0.10); } .mf-spend .mf-fill { fill: var(--ink); }
.mf-foot { font-size: 11.5px; color: var(--muted); line-height: 1.35; } .mf-foot b { color: var(--text); font-weight: 700; } .mf-spend .mf-foot b { color: var(--ink); }
.chart { padding: 14px 16px 10px; }
.ch-legend { display: flex; flex-wrap: wrap; gap: 18px; font-size: 12px; color: var(--dim); margin-bottom: 8px; } .ch-legend b { color: var(--text); margin-left: 4px; }
.ch-key { display: inline-block; width: 12px; height: 10px; margin-right: 6px; vertical-align: -1px; }
.ck-bar { background: rgba(255, 255, 255, 0.78); } .ck-line { height: 2px; vertical-align: 3px; background: var(--dim); } .ck-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--ok); }
.ch-svg { display: block; overflow: visible; }
.ch-grid { stroke: rgba(255, 255, 255, 0.10); stroke-width: 1; }
.ch-ax { fill: var(--muted); font-size: 11px; font-family: var(--font); }
.ch-bar { fill: rgba(255, 255, 255, 0.78); }
.ch-line { fill: none; stroke: var(--dim); stroke-width: 2; stroke-linejoin: round; }
.ch-dot { fill: var(--ok); stroke: var(--ink-2); stroke-width: 1.5; }
.ch-hit { fill: transparent; } .ch-hit:hover { fill: rgba(255, 255, 255, 0.06); }
.adthumb { position: relative; display: block; background: var(--ink); border: 1px solid var(--line-2); overflow: hidden; }
.adthumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.adthumb-ph { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--display); font-stretch: 112%; font-size: 9px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--faint); }
.adthumb img + .adthumb-ph { display: none; }
.adthumb.noimg img { display: none; } .adthumb.noimg .adthumb-ph { display: flex; }
.adthumb.sm { width: 44px; height: 44px; }
.adthumb.lg { width: 100%; height: auto; margin: 0; aspect-ratio: 1 / 1; border: 0; border-bottom: 1px solid var(--line-2); }
.creative { padding: 0; display: flex; flex-direction: column; box-shadow: inset 0 3px 0 var(--paper); }
.cr-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 8px; }
.cr-name { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 14px; text-transform: uppercase; letter-spacing: .01em; overflow-wrap: anywhere; }
.cr-sub { font-size: 11.5px; color: var(--muted); margin-top: -6px; }
.cr-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; border-top: 1px solid var(--line); padding-top: 8px; }
.cr-stats span { display: block; font-size: 9px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.cr-stats b { font-family: var(--display); font-stretch: 112%; font-size: 15px; font-weight: 800; }
.creative .badge { align-self: flex-start; }
@media (max-width: 1180px) { .mfunnel { grid-template-columns: repeat(4, minmax(0, 1fr)); } .mf-val { font-size: 22px; } .mf-step:nth-child(5) { border-left: 0; } .mf-step:nth-child(n+5) { border-top: 1px solid var(--line); } }
@media (max-width: 700px) { .mfunnel { grid-template-columns: repeat(2, minmax(0, 1fr)); } .mf-step { border-left: 0; border-top: 1px solid var(--line); } .mf-step:nth-child(even) { border-left: 1px solid var(--line); } .mf-step:nth-child(-n+2) { border-top: 0; } .grid.g4.creatives { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ch-ax { font-size: 20px; } }
/* 320–420 px phones: two creatives per row left each stat 32 px for a 70 px 'GROSS LEADS' label (page 1 px sideways), and
   the spend figure was wider than its funnel cell: one creative per row, smaller funnel numbers. */
@media (max-width: 420px) { .grid.g4.creatives { grid-template-columns: minmax(0, 1fr); } .mf-val, .mf-spend .mf-val { font-size: 18px; } }

/* ── 2026-10-19 Owner view (Loom): KPI goals, your day, the money, visit outcomes ── */
.chain.c8 { grid-template-columns: repeat(8, minmax(0, 1fr)); }
.chain.c7 { grid-template-columns: repeat(7, minmax(0, 1fr)); }   /* channel pages (2026-11-17) */
.chain.c6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }   /* lead manager scoreboard (2026-11-17) */
.chain.c5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.kpi .goal { display: flex; flex-direction: column; gap: 5px; margin: 0 0 6px; }
.kpi .gtrack { display: block; height: 4px; background: var(--line-2); position: relative; overflow: hidden; }
.kpi .gtrack > span { display: block; height: 100%; background: var(--muted); }
.kpi .goal.good .gtrack > span { background: var(--ok); }
.kpi .goal.warn .gtrack > span { background: var(--warn); }
.kpi .goal.bad .gtrack > span { background: var(--bad); }
.kpi .gtxt { font-size: 11px; color: var(--muted); line-height: 1.3; }
.kpi .goal.good .gtxt b { color: var(--ok); } .kpi .goal.warn .gtxt b { color: var(--warn); } .kpi .goal.bad .gtxt b { color: var(--bad); }
.kpi.hero .gtrack { background: #cfcfcf; } .kpi.hero .gtxt { color: #3a3a3a; }
.kpi.hero .goal.good .gtxt b { color: #1d7a50; } .kpi.hero .goal.warn .gtxt b { color: #8a5a00; } .kpi.hero .goal.bad .gtxt b { color: #a8322a; }
.kpi .step { font-size: 10.5px; color: var(--muted); margin-bottom: 6px; letter-spacing: 0.02em; }
.kpi.hero .step { color: #3a3a3a; }
.money .kpi .val.sm { font-family: var(--font); font-size: 15px; font-weight: 700; color: var(--warn); line-height: 1.3; }
.money .kpi.cash { border-top: 3px solid var(--warn); }
button.card.kpi { text-align: left; font: inherit; color: inherit; cursor: pointer; }
.attn.a4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.attn.a4 .attn-i, .attn.a4 .attn-i:nth-child(3n) { border-right: 1px solid var(--line-2); }
.attn.a4 .attn-i:nth-child(4n) { border-right: 0; }
.hk { display: flex; flex-direction: column; margin-top: 12px; border: 1px solid var(--line-2); }
.hk button { display: flex; align-items: baseline; gap: 12px; padding: 11px 12px; background: var(--ink); border: 0; border-bottom: 1px solid var(--line-2); color: var(--text-2); text-align: left; font: inherit; font-size: 13px; cursor: pointer; }
.hk button:last-child { border-bottom: 0; }
.hk button:hover { background: var(--ink-3); color: var(--paper); }
.hk .v { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 18px; min-width: 44px; color: var(--text); }
.dact { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.dact .note { margin: 0; }
.linkish { background: none; border: 0; padding: 0; color: var(--paper); font: inherit; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.oc .kick { display: flex; }
.oc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 4px; }
.oc-b { min-height: 52px; padding: 10px 12px; background: var(--ink); border: 1px solid var(--line-2); color: var(--text); font: inherit; font-size: 14px; font-weight: 600; text-align: left; cursor: pointer; }
.oc-b:hover { border-color: var(--paper); }
.oc-b.on { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.oc-f { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; }
.oc-f span { font-family: var(--display); font-stretch: 112%; font-size: 10px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--dim); }
.oc-f input, .oc-f textarea { background: var(--ink); border: 1px solid var(--line-2); color: var(--text); font: inherit; font-size: 16px; padding: 10px 12px; border-radius: 0; width: 100%; box-sizing: border-box; }
.oc-f input:focus, .oc-f textarea:focus { outline: none; border-color: var(--paper); }
.oc-act { display: flex; align-items: center; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.oc-msg { font-size: 12.5px; color: var(--warn); }
.goal-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
@media (max-width: 1180px) {
  .chain.c8 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .chain.c7 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .chain.c6, .chain.c5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .chain.c8 .kpi, .chain.c8 .kpi:nth-child(3n) { border-right: 1px solid var(--line-2); border-bottom: 0; }
  .chain.c8 .kpi:nth-child(4n) { border-right: 0; }
  .chain.c8 .kpi:nth-child(-n+4) { border-bottom: 1px solid var(--line-2); }
  .attn.a4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .attn.a4 .attn-i:nth-child(odd) { border-right: 1px solid var(--line-2); }
  .attn.a4 .attn-i:nth-child(2n) { border-right: 0; }
}
@media (max-width: 700px) {
  .chain.c8 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chain.c7 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chain.c6, .chain.c5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chain.c8 .kpi, .chain.c8 .kpi:nth-child(4n) { border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
  .chain.c8 .kpi:nth-child(2n) { border-right: 0; }
  .chain.c8 .kpi:nth-last-child(-n+2) { border-bottom: 0; }
  .attn.a4 { grid-template-columns: minmax(0, 1fr); }
  .attn.a4 .attn-i, .attn.a4 .attn-i:nth-child(odd) { border-right: 0; }
  .goal-form { grid-template-columns: minmax(0, 1fr); }
}

/* Overview: this morning's blockers from Jarred's report (one line each) */
.mrb-l { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-direction: column; border-top: 1px solid var(--line-2); }
.mrb-l li { display: flex; align-items: baseline; gap: 10px; padding: 9px 2px; border-bottom: 1px solid var(--line-2); font-size: 13px; color: var(--text-2); min-width: 0; }
.mrb-l li span:last-child { min-width: 0; overflow-wrap: anywhere; }
.mrb-l li b { color: var(--text); font-weight: 600; }
.mrb-l .dot { width: 8px; height: 8px; flex: none; background: var(--muted); transform: translateY(-1px); }
.mrb-l li.bad .dot { background: var(--bad); } .mrb-l li.warn .dot { background: var(--warn); } .mrb-l li.ok .dot { background: var(--ok); }
.mrb .hl-head { flex-wrap: wrap; gap: 8px; }
.mrb .hl-head a.badge { text-decoration: none; white-space: normal; }

/* Visits waiting for your outcome: on a phone only the oldest few show until "Show all" (desktop always shows every row). */
.hl-head.wo-head { flex-wrap: wrap; gap: 8px; }   /* three items in the heading: wrap on a 320 px phone, never push the page sideways */
.wo-n { font-variant-numeric: tabular-nums; }
.wo-oldest { margin: 8px 0 0; font-size: 12.5px; color: var(--text-2); }
.wo-tog { display: none; width: 100%; min-height: 44px; background: transparent; border: 0; border-top: 1px solid var(--line-2); color: var(--text); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.wo-tog:hover { background: var(--ink-3); }
@media (max-width: 700px) {
  table.wo-cut tr.wo-more { display: none; }
  .wo-tog { display: block; }
  /* the Record button must fit a 320 px row (it sat past the edge of the scroll box): tighter cells, long names break, shorter label */
  .wo-sec td { padding: 10px 8px; }
  .wo-sec td:nth-child(2) .who-c, .wo-sec td:nth-child(2) .sub-c { overflow-wrap: anywhere; }   /* seller only: a date never breaks mid-token */
  .wo-sec td.r .btn { padding: 8px 10px; letter-spacing: 0.08em; }
  .wo-long { display: none; }
}

/* Ad → sellers drawer: stacked cards, so nothing scrolls sideways on a phone */
.adl { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.adl-b { width: 100%; text-align: left; background: var(--ink); border: 1px solid var(--line-2); color: var(--text); font: inherit; padding: 10px 12px; cursor: pointer; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.adl-b:hover { border-color: var(--paper); }
.adl-h { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.adl-h b { overflow-wrap: anywhere; }
.adl-d { color: var(--dim); font-size: 12px; }
.adl-l { font-size: 12.5px; color: var(--text-2); overflow-wrap: anywhere; }
.adl-s { font-size: 11.5px; color: var(--muted); overflow-wrap: anywhere; }

/* ── 2026-10-22 Funnel scorecard: conversion health, biggest constraint, stoplights ── */
.constraint { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; margin-bottom: 12px; border: 1px solid var(--line-2); border-left: 4px solid var(--muted); background: var(--ink-2); }
.constraint b { font-size: 15px; color: var(--text); }
.constraint .sub { margin: 0; }
.constraint.good { border-left-color: var(--ok); } .constraint.warn { border-left-color: var(--warn); } .constraint.bad { border-left-color: var(--bad); }
.tlabel { color: var(--warn); letter-spacing: 0.04em; }
table.steps td, table.steps th { white-space: nowrap; }
.lt { font-size: 12px; font-weight: 700; }
.lt.good { color: var(--ok); } .lt.warn { color: var(--warn); } .lt.bad { color: var(--bad); } .lt.none { color: var(--muted); font-weight: 500; }
@media (max-width: 420px) { table.steps td, table.steps th { padding-left: 6px; padding-right: 6px; font-size: 12px; } }
.constraint .gap { margin-top: 4px; font-size: 13px; color: var(--warn); }
/* S#95: "N missing a date · show which" opens those sellers. Buttons that read as links (keyboard: Enter and Space natively). */
.constraint button.gap { height: auto; background: none; border: 0; padding: 0; font: inherit; font-size: 13px; text-align: left; cursor: pointer; color: var(--warn); }
button.lnk { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-decoration: underline; cursor: pointer; }
.wo-why, .wo-next { white-space: normal; }

/* S#31: a KPI whose CRM tracking is known to be off says so in its foot, in the warning colour. */
.kpi .foot .trk { color: var(--warn); font-weight: 600; }

/* S#31: the old daily desk sits folded at the bottom of Needs attention. */
details.olddesk > summary { cursor: pointer; padding: 12px 0; }
/* Coming up (S#34): visits by the day they happen */
.cu-sec .cu-day { font-size: 13px; font-weight: 600; margin: 14px 0 6px; }
.cu-sec tr.cu-x .who-c { text-decoration: line-through; opacity: .6; }
.cu-sec .cu-x .call-card { opacity: .6; }
.cu-sec .cu-x .call-name { text-decoration: line-through; }
.ao-rebook h3 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ao-rebook summary { cursor: pointer; margin: 6px 0; }
/* Missing tracking (S#34) */
.warn-t { color: #E0A846; }

/* channels (S#34): raw Lead Source rows sit under their channel */
.raw-r { padding-left: 14px; color: var(--dim); }
.src .raw-c { grid-column: 1 / -1; font-size: 11px; color: var(--dim); text-align: left; white-space: normal; overflow-wrap: anywhere; }
/* Lead manager queue (S#35): response bands and state counts as plain rows that wrap on a phone. */
.bands { display: grid; gap: 6px; }
.band-row { display: grid; grid-template-columns: minmax(0, 7.5em) minmax(0, 1fr) auto; gap: 8px; align-items: center; font-size: 13px; }
.band-row.two { grid-template-columns: minmax(0, 1fr) auto; }
.band-row > .band-l { min-width: 0; overflow-wrap: anywhere; }
.band-bar { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; }
.band-fill { display: block; height: 100%; background: var(--muted); }
.band-fill.ok { background: var(--ok); }
.band-fill.bad { background: var(--bad); }

/* Call list (S#66): one column of cards, phone first, a big tap target. */
.call-sum { padding: 14px 16px; margin-bottom: 16px; }
.call-sec { margin-top: 22px; }
.call-sec h2 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
/* Lead manager SMS list: unscreened Nurturing replies, folded (2026-11-17). */
.lm-fold summary { cursor: pointer; padding: 12px 0; list-style: revert; }
.lm-fold[open] summary { margin-bottom: 4px; }
.call-list { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 10px; max-width: 720px; }
.call-card { border: 1px solid var(--line, rgba(255,255,255,0.12)); border-radius: 12px; padding: 14px 16px; cursor: pointer; min-width: 0; }
.call-card:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.call-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.call-name { font-size: 1.25rem; line-height: 1.25; overflow-wrap: anywhere; min-width: 0; }
.call-btn { display: flex; justify-content: center; width: 100%; margin: 10px 0 6px; padding: 12px 14px; font-size: 1.05rem; min-height: 48px; box-sizing: border-box; }
.call-nophone { margin: 10px 0 6px; }
.call-why { margin: 4px 0; overflow-wrap: anywhere; }
.call-card .sub-c { overflow-wrap: anywhere; }
/* Not counted: what fixes it (S#66). */
.sub-c.fix { margin-top: 4px; }
.why .fix { margin-top: 6px; }

/* S#97 What needs you today */
.needs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border: 1px solid var(--line-2); border-top: 3px solid var(--paper); background: var(--ink-2); }
.needs-s { padding: 14px 16px; min-width: 0; border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 8px; }
.needs-s:nth-child(2n) { border-right: 0; }
.needs-s:last-child:nth-child(odd) { grid-column: 1 / -1; border-right: 0; }
.needs-s .h { display: flex; align-items: baseline; gap: 10px; }
.needs-s .h .v { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 22px; line-height: 1; }
.needs-s .h .l { font-family: var(--display); font-stretch: 112%; font-weight: 700; font-size: 10.5px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-2); }
.needs-s ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.needs-s .more { background: transparent; border: 0; color: var(--dim); font-size: 11.5px; padding: 4px 0 0; cursor: pointer; text-align: left; text-decoration: underline; text-underline-offset: 3px; }
.needs-i { min-width: 0; overflow-wrap: anywhere; }
.needs-i .needs-who { font-weight: 700; }
@media (max-width: 760px) { .needs { grid-template-columns: minmax(0, 1fr); } .needs-s { border-right: 0; } }
/* appointment outcomes (S#106): in person and phone side by side, stacked on a phone */
.ao-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}
.ao-col h3{margin:4px 0 10px;font-size:15px}
@media (max-width:900px){.ao-grid{grid-template-columns:1fr}}

/* Per-channel goal lights + goals grid (2026-11-17) */
.steps td.gl .dot { display: inline-block; vertical-align: middle; }
.steps td.gl .gl-t { font-size: 11px; color: var(--muted); }
.steps td.gl.warn .gl-t { color: var(--warn); } .steps td.gl.bad .gl-t { color: var(--bad); } .steps td.gl.good .gl-t { color: var(--ok); }
table.steps.cg-grid input { width: 60px; text-align: right; padding-left: 6px; padding-right: 6px; }
table.steps.cg-grid td, table.steps.cg-grid th { padding-left: 6px; padding-right: 6px; }
table.steps.cg-grid td:first-child, table.steps.cg-grid th:first-child { white-space: normal; }
.cg-grid .cg-total td { font-weight: 700; border-top: 1px solid var(--line-2); }
/* N18-03 Meta says vs Ragnar verified */
.mvv .mvv-cpa { margin-top: 10px; }
.mvv .mvv-cpa .lab { display: inline; }
.mvv .mvv-split { margin-top: 6px; }
.mvv code { font-size: 0.85em; word-break: break-all; }
/* N18-01/02 conversion gaps */
.gap-sec { margin-top: 12px; }
.gap-sec > summary { cursor: pointer; padding: 6px 0; }
.gap-card .gap-next { margin-top: 4px; }

/* ── Lead manager: conversion strip, biggest leak, call queue (Tyler 2026-11-20) ── */
.lm-conv .kpi.lm-conv-t { cursor: default; }
.lm-conv .kpi.lm-conv-t:hover { background: var(--ink-2); box-shadow: none; }
.lm-conv .val { font-size: 40px; }
.lm-conv .val.good { color: var(--ok); } .lm-conv .val.warn { color: var(--warn); } .lm-conv .val.bad { color: var(--bad); }
.lm-conv .kpi.loud { box-shadow: inset 0 0 0 2px var(--bad); background: var(--bad-soft); }
.lm-conv .kpi.loud:hover { background: var(--bad-soft); box-shadow: inset 0 0 0 2px var(--bad); }
.lm-goal { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.lm-goal b { color: var(--text); }
.lm-small { font-size: 11px; color: var(--dim); }
.lm-light { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 6px; }
.lm-light.good { color: var(--ok); } .lm-light.warn { color: var(--warn); } .lm-light.bad { color: var(--bad); }
.lm-light .dim { font-weight: 400; letter-spacing: 0; text-transform: none; }
.lm-gap { font-size: 12.5px; text-align: left; color: var(--text); }
button.lm-leak { display: flex; width: 100%; text-align: left; font: inherit; color: inherit; cursor: pointer; margin-top: 14px; font-size: 15px; }
.lm-leak.ok { margin-top: 14px; }
.lm-filters { display: flex; gap: 10px; flex-wrap: wrap; margin: 12px 0; }
.lm-qtiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 4px 0 18px; }
.lm-qt { display: flex; flex-direction: column; gap: 4px; text-align: left; padding: 12px 14px; background: var(--ink-2); border: 1px solid var(--line-2); border-left: 4px solid var(--line-2); color: inherit; font: inherit; cursor: pointer; }
.lm-qt .v { font-family: var(--display); font-size: 26px; font-weight: 800; line-height: 1; }
.lm-qt .l { font-size: 12px; color: var(--muted); }
.lm-qt.bad { border-left-color: var(--bad); } .lm-qt.bad .v { color: var(--bad); }
.lm-qt.warn { border-left-color: var(--warn); } .lm-qt.warn .v { color: var(--warn); }
.lm-qt.zero { opacity: .55; cursor: default; }
.lm-empty { color: var(--dim); font-size: 13px; margin: 6px 0; }
.call-list.lm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none; }
.lm-card .call-name { font-size: 1.4rem; }
.lm-card .call-btn { font-size: 1.05rem; }
.lm-fix { color: var(--text); }
@media (max-width: 900px) { .lm-qtiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } .call-list.lm-grid { grid-template-columns: 1fr; } .lm-conv .val { font-size: 30px; } }
/* In-Person Appointments page (Tyler 2026-11-20 spec, Page 4) */
.kpi .val.good { color: var(--ok); }
.kpi .val.warn { color: var(--warn); }
#ip-top .ip-tiles .kpi .val { font-size: 40px; }
#ip-top .ip-small { font-size: 12px; opacity: .8; }
#ip-top .ip-phone { margin-top: 14px; font-size: 15px; }
#ip-top .ip-link { background: none; border: 0; padding: 0; color: inherit; font: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
#ip-top .ip-link:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
#ip-top .ip-info { margin-left: auto; }
#ip-top .ip-info summary { list-style: none; cursor: pointer; display: inline-flex; opacity: .7; }
#ip-top .ip-info summary::-webkit-details-marker { display: none; }
#ip-top .ip-info[open] p { margin-top: 8px; }
#drawer .call-list { max-width: none; }
/* Cash flow · 4-month view (Overview section 2, Tyler 2026-11-20). Collected is solid, forecast is lighter:
   the bar carries the same "this half is real money, this half is a projection" message as the wording. */
.cf-card { text-align: left; }
.cf-card.cf-now { background: var(--paper); color: var(--ink); }
.cf-card.cf-now .lab, .cf-card.cf-now .foot, .cf-card.cf-now .cf-sub { color: #3a3a3a; }
.cf-card.cf-now:hover { background: var(--bone); box-shadow: none; }
.cf-bar { margin: 10px 0 8px; }
.track > span.cf-pending { background: var(--paper); opacity: 0.32; }
.cf-card.cf-now .track { background: rgba(0,0,0,0.08); }
.cf-card.cf-now .track > span { background: var(--ink); }
.cf-card.cf-now .track > span.cf-pending { background: var(--ink); opacity: 0.28; }
.cf-sub { font-size: 12px; line-height: 1.5; color: var(--muted); margin-bottom: 6px; }
.cf-lag { font-size: 11.5px; line-height: 1.4; color: var(--warn); margin-bottom: 6px; }
.cf-miss { display: flex; width: 100%; text-align: left; margin-top: 14px; cursor: pointer; }
/* Cancel / no-show reasons (In-Person page, Tyler 2026-11-20) */
#ip-reasons .rs-list { display: grid; gap: 6px; margin-top: 10px; max-width: 760px; }
#ip-reasons .rs-row { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(60px, 1fr) 40px; align-items: center; gap: 10px; background: none; border: 0; padding: 6px 4px; color: inherit; font: inherit; text-align: left; cursor: pointer; }
#ip-reasons .rs-row:disabled { cursor: default; opacity: .55; }
#ip-reasons .rs-row:not(:disabled):hover .rs-lab { text-decoration: underline; }
#ip-reasons .rs-row:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
#ip-reasons .rs-bar .warn { background: var(--warn); }
#ip-reasons .rs-n { text-align: right; font-weight: 700; }
@media (max-width: 560px) { #ip-reasons .rs-row { grid-template-columns: minmax(0, 1fr) 40px; } #ip-reasons .rs-bar { display: none; } }
/* ── Appointment health + Today (Tyler, 2026-11-20 spec sections 4 and 5). Two rows of LARGE tiles, in person and phone
   kept apart, each half tagged with whoever owns it; then the day split between Ragnar and Marion. ── */
.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.ah-h { margin: 0 0 8px; }
.ah-row { margin-bottom: 18px; }
.ah-row:last-of-type { margin-bottom: 0; }
.ah-row h3 { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; }
.ah-own { color: var(--muted); font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.ah-tile { display: block; width: 100%; text-align: left; border: 1px solid var(--line-2); border-radius: 10px; }
.ah-tile .lab { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.ah-tile .val { font-size: 1.9rem; }
button.ah-tile { cursor: pointer; font: inherit; color: inherit; background: none; }
button.ah-tile:hover, button.ah-tile:focus-visible { background: var(--line-2); }
button.ah-tile:focus-visible { outline: 2px solid currentColor; outline-offset: -2px; }
.ah-tile .val.good { color: var(--ok); } .ah-tile .val.warn { color: var(--warn); } .ah-tile .val.bad { color: var(--bad); }
/* Today */
.td-sec h3 { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; }
.td-list { list-style: none; margin: 0; padding: 0; }
.td-row { display: flex; align-items: baseline; gap: 12px; width: 100%; padding: 10px 8px; min-height: 48px;
  background: none; border: 0; border-bottom: 1px solid var(--line-2); color: inherit; font: inherit; text-align: left; cursor: pointer; }
.td-row:hover, .td-row:focus-visible { background: var(--line-2); }
.td-row:focus-visible { outline: 2px solid currentColor; outline-offset: -2px; }
.td-time { flex: 0 0 auto; color: var(--text-2, inherit); white-space: nowrap; }
.td-who { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.td-where { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.td-gap { color: var(--muted); font-size: 11px; padding: 2px 8px 6px 0; text-align: right; }
@media (max-width: 1180px) { .g5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 700px) { .g5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ah-tile .val { font-size: 1.6rem; } }
/* What needs you today: count tiles + the person toggle (Overview rebuild spec, 2026-11-20).
   Same look as the section headers below them: display face, uppercase label, big number. */
.needs-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0 0 12px; }
.needs-tile { display: flex; flex-direction: column; gap: 3px; text-align: left; padding: 12px 14px; border: 1px solid var(--line-2); background: var(--ink-2); color: inherit; font: inherit; cursor: pointer; }
.needs-tile:hover { border-color: var(--line-3); }
.needs-tile .v { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 24px; line-height: 1; }
.needs-tile .l { font-family: var(--display); font-stretch: 112%; font-weight: 700; font-size: 10.5px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.needs-tile .by { font-size: 11px; color: var(--faint); }
.needs-tile[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.needs-tile.off { cursor: default; opacity: 0.45; }
.needs-owners { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.needs-who-pick { padding: 6px 12px; border: 1px solid var(--line-2); background: transparent; color: inherit; font: inherit; cursor: pointer; }
.needs-who-pick .num { color: var(--muted); }
.needs-who-pick[aria-pressed="true"] { border-color: var(--accent); background: var(--ink-2); }
.needs-both { color: var(--faint); }
.needs-empty { margin: 8px 0 0; padding: 14px 16px; }

/* Disposition (Contract to Close), Tyler's spec Page 5 2026-11-20: cash tiles coloured by the break-even bands. */
.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 1100px) { .g5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .g5 { grid-template-columns: minmax(0, 1fr); } }
.dispo-cash { text-align: left; cursor: pointer; border-top: 3px solid var(--line); }
.dispo-cash.bad { border-top-color: var(--bad); background: var(--bad-soft); }
.dispo-cash.warn { border-top-color: var(--warn); background: var(--warn-soft); }
.dispo-cash.good { border-top-color: var(--ok); background: var(--ok-soft); }
.dispo-gap { font-size: 13px; font-weight: 600; margin-top: 4px; }
.dispo-gap.bad { color: var(--bad); } .dispo-gap.warn { color: var(--warn); } .dispo-gap.good { color: var(--ok); }
.dispo-warn { color: var(--warn); }
.dispo-goget li.ok .dot { background: var(--ok); }
.dispo-deals { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none; }
@media (max-width: 760px) { .dispo-deals { grid-template-columns: minmax(0, 1fr); } }
.dispo-deal.edge-bad { border-color: var(--bad); }
.dispo-money { font-size: 20px; font-weight: 700; margin: 6px 0 2px; }
.dispo-miss { list-style: none; padding: 0; margin: 6px 0 0; }
.dispo-miss li { padding: 4px 0; }
.dispo-missing { margin-top: 8px; }
