/* Admin additions on top of the portal's app.css; everything else is the portal's own grammar. */
.brand, .me { gap: 10px; text-decoration: none; }
.brand .tagline { font-size: 12px; font-weight: 500; color: var(--faint); padding-left: 10px; border-left: 1px solid var(--line); }
.nums { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 20px; }
.nums > div { padding: 14px 0; border-top: 1px solid var(--line); }
.nums > div:nth-child(-n+2) { border-top: 0; }
.nums b { display: block; font-size: 26px; line-height: 32px; font-weight: 500; letter-spacing: -.02em; color: var(--ink); font-variant-numeric: tabular-nums; }
.nums small { display: block; font-size: 13px; color: var(--faint); }
.nums .k { font-size: 13px; color: var(--muted); }
.row .why { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.word { flex: none; width: 76px; font-size: 13px; font-weight: 500; color: var(--ink); }
.word.need { color: var(--acc); }
.bottom-tabs a svg { width: 20px; height: 20px; }

/* sign-in and refusal screens: the portal's sign-in card on the same ground */
/* Sign-in: one centred glass card on the admin ground, logo above, the usual pattern for an internal sign-in page. */
.signin { background: none; color: var(--ink); display: grid; place-items: center; padding: 24px 16px; overflow: auto; }
.signin .stack { width: min(440px, 100%); display: grid; justify-items: center; gap: 28px; }
.signin .top { position: static; height: 28px; filter: none; }
:root[data-theme="dark"] .signin .top, :root:not([data-theme]) .signin .top { filter: invert(1) brightness(2); }
.si-card { position: relative; inset: auto; transform: none; width: 100%; padding: 44px 40px 32px; border-radius: 28px; text-align: center;
  color: var(--ink); animation: rise .5s var(--ease-arrive) both;
  background: linear-gradient(180deg, rgba(255,255,255,.12), rgba(255,255,255,.03) 55%), rgba(18,19,22,.42);
  -webkit-backdrop-filter: blur(44px) saturate(1.8); backdrop-filter: blur(44px) saturate(1.8);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.22), inset 0 0 0 1px rgba(255,255,255,.08), 0 2px 6px rgba(0,0,0,.18), 0 30px 80px rgba(0,0,0,.40); }
:root[data-theme="light"] .si-card {
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.62) 60%), rgba(255,255,255,.35);
  box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(0,0,0,.05), 0 2px 6px rgba(0,0,0,.06), 0 30px 80px -20px rgba(0,0,0,.18); }
.si-card .h { font-size: 44px; line-height: 48px; }
.si-card .h .acc { color: var(--acc); }
.si-card .sub { margin: 14px 0 32px; color: var(--muted); }
.si-card .btn.quiet { width: 100%; margin-top: 0; color: var(--ink); background: var(--field); box-shadow: inset 0 0 0 1px var(--line); }
.si-card .fine { margin: 24px 0 0; font-size: 12px; line-height: 18px; color: var(--faint); }
/* Google's own button styling (neutral surface, full-colour G), per Google's sign-in branding guidelines. */
.g-btn { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; height: 52px; padding: 0 20px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.28); background: #121316; color: rgba(255,255,255,.90); font: 500 15px/1 var(--font-sans); cursor: pointer; transition: background .15s, box-shadow .15s; }
.g-btn:hover { background: #232329; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.g-btn:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }
:root[data-theme="light"] .g-btn { border-color: rgba(0,0,0,.14); background: #fff; color: #111; }
:root[data-theme="light"] .g-btn:hover { background: #f5f5f7; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.signin footer { position: static; justify-content: center; color: var(--faint); }
@media (max-width: 640px) {
  .si-card { padding: 32px 22px 24px; border-radius: 24px; animation-name: rise; }
  .si-card .h { font-size: 36px; line-height: 40px; }
}
/* Phone: four tabs plus More (the portal's bar is six columns wide). */
@media (max-width: 760px) { .bottom-tabs { grid-template-columns: repeat(5, 1fr); } }
.row .mono svg { width: 18px; height: 18px; }
.nums.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.nums.four > div:nth-child(-n+4) { border-top: 0; }
@media (max-width: 760px) { .nums.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } .nums.four > div:nth-child(n+3) { border-top: 1px solid var(--line); } }
/* Cost page: vendor sparks, month chart, money columns. Colours from the chart tokens. */
.cost-row { gap: 14px; align-items: center; }
.cost-row .cn { flex: none; width: 84px; text-align: right; font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }
.cost-row .cn.strong { color: var(--ink); font-weight: 500; }
.cost-row.head { padding-top: 0; padding-bottom: 6px; }
/* Gate E Benchmarks drawer (T-323): a fixed-width trend, the latest value, and when it was measured. */
.bench-row .cxc.sp.mini, .bench-row .gt-first { flex: none; width: 120px; height: 30px; padding-top: 0; margin: 0; }
.bench-row .gt-first { display: flex; align-items: center; justify-content: flex-end; height: auto; }
.bench-row .cn.when { width: 190px; }
.cost-row.head .cn, .spark.lbl i { font-size: 12px; color: var(--faint); font-style: normal; }
.spark { flex: none; display: flex; align-items: flex-end; gap: 2px; width: 150px; height: 28px; }
.spark.lbl { height: auto; align-items: center; }
.spark.lbl i { background: none; text-align: center; height: auto; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 14px 0 4px; font-size: 12px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
@media (max-width: 760px) {
  .cost-row .spark, .cost-row .mini { display: none; }
  .cost-row { flex-wrap: nowrap; }
  .cost-row .grow { min-width: 0; }
  .cost-row.v .cn:nth-last-child(2) { display: none; }
  .cost-row .cn { width: 64px; font-size: 13px; }
}
.blk .sect .seg { margin-left: auto; }
.seg.sm button { height: 30px; padding: 0 12px; font-size: 13px; }
/* Expense ledger */
.cost-row.exp .dt { flex: none; width: 52px; font-size: 13px; color: var(--faint); font-variant-numeric: tabular-nums; }
.needw { color: var(--acc); }

/* ---------- Look v2 (4 Nov 2026): a skyline that changes daily behind real Connectry glass ----------
   Six approved skylines (no people, so glass never sits on a face), one per day (admin.js sets --city).
   Light: the photo faded far back under a pale veil. Dark: the photo under the app icon's gradient, blue high right,
   warm low left, deeper than the portal's. Rail and stage are glass with the design system's lens; panels stay tonal. */
:root { --city: url("img/city/1.jpg"); }
:root[data-theme="light"] .ambient {
  background: radial-gradient(120% 90% at 70% 0%, rgba(245,245,247,.55), rgba(245,245,247,.86) 70%), var(--city) center / cover no-repeat, var(--bg); }
:root[data-theme="dark"] .ambient, :root:not([data-theme]) .ambient {
  background:
    radial-gradient(85% 75% at 100% 0%, rgba(74,111,165,.56), transparent 70%),
    radial-gradient(75% 70% at 0% 100%, rgba(255,217,176,.16), transparent 70%),
    linear-gradient(160deg, rgba(14,15,17,.58) 0%, rgba(14,15,17,.70) 55%, rgba(5,5,5,.80) 100%),
    var(--city) center / cover no-repeat, #0e0f11; }
.ambient::after { background: none; }
.ambient { animation: cityin 1.2s cubic-bezier(.2,.7,.2,1) both; }
@keyframes cityin { from { opacity: 0 } }
/* The lens: plain chain first (Safari), then the convex map where it is supported. */
.rail.glass, .stage.glass, .bottom-tabs {
  -webkit-backdrop-filter: blur(18px) saturate(1.7) brightness(1.04);
  backdrop-filter: blur(18px) saturate(1.7) brightness(1.04);
  backdrop-filter: url(#lens) blur(18px) saturate(1.7) brightness(1.04); }
:root[data-theme="light"] .rail.glass, :root[data-theme="light"] .stage.glass {
  background: linear-gradient(180deg, var(--glass-tint-top, rgba(255,255,255,.40)), var(--glass-tint-bottom, rgba(255,255,255,.26))); }
:root[data-theme="dark"] .rail.glass, :root[data-theme="dark"] .stage.glass {
  background: linear-gradient(180deg, rgba(18,19,22,.62), rgba(14,15,17,.70)); }
:root[data-theme="dark"] .stage.glass { background: linear-gradient(180deg, rgba(18,19,22,.46), rgba(14,15,17,.58)); }

/* Overview: environment health strips and the spend spark on Key numbers */
.health { display: grid; gap: 14px; }
.hl { text-decoration: none; color: inherit; border-radius: 8px; }
.hl:hover { background: var(--panel-hover); }
.stackcol { display: grid; gap: 20px; align-content: start; }
.hl { display: grid; grid-template-columns: 84px minmax(0,1fr) auto; gap: 14px; align-items: center; font-size: 13px; }
.hl > span:first-child { color: var(--ink); font-weight: 500; }
.hl small { color: var(--faint); font-variant-numeric: tabular-nums; }

/* Grader labels (P6): one answer at a time, five letter buttons, an optional note, a 40-dot jump grid. Phone first.
   Spacing is tight on purpose: at 1440 by 900 one answer, the five choices, the note and Previous / Next fit one view. */
/* --g is the unit for every gap on the page: it follows the window height, 10px at 900 tall, 14px at 1000, 6 to 18px. */
.sh-head:has(.p6-count), .p6-case { --g: clamp(6px, calc((100vh - 614px) * .035), 18px); }
.p6-count { font-size: 15px; color: var(--muted); font-variant-numeric: tabular-nums; }
.p6-count b { font-size: 26px; font-weight: 500; color: var(--ink); letter-spacing: -.02em; }
.sh-head:has(.p6-count) { padding-bottom: calc(var(--g) * 1.5); }
.sh-head:has(.p6-count) .ttl { grid-column: 1 / -1; grid-row: 1; }
.sh-head:has(.p6-count) .act { grid-column: 11 / 13; grid-row: 1; align-self: start; }
.sh-head:has(.p6-count) .h1 { font-size: 32px; line-height: 38px; }
.sh-head:has(.p6-count) .lead { margin-top: 6px; max-width: none; font-size: 15px; line-height: 22px; }
main:has(.p6-case) { padding-top: calc(var(--g) * 1.8); padding-bottom: 22px; }
.blk.p6-case { padding: calc(var(--g) * 1.5) 22px calc(var(--g) * 1.6); gap: 0; align-self: start; }
.p6-pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 28px; align-items: start; }
.p6-case .sect { display: flex; align-items: center; justify-content: flex-start; gap: 6px 12px; flex-wrap: wrap; margin-bottom: 0; }
.p6-nav { display: flex; gap: 8px; margin-left: auto; }
.p6-nav .btn { height: 32px; }
.p6-case .sect + .p6-f .p6-k { margin-top: calc(var(--g) * .9); }
.p6-status:empty { display: none; }
.p6-status { margin: 0; font-size: 13px; color: var(--muted); }
.p6-status.err { color: var(--danger); }
.p6-k { display: block; margin: calc(var(--g) * 1.3) 0 calc(var(--g) * .35); font-size: 13px; line-height: 18px; font-weight: 500; color: var(--muted); }
.p6-v { font-size: 15px; line-height: 22px; color: var(--ink); overflow-wrap: anywhere; }
.p6-f.q .p6-v { font-size: 18px; line-height: 26px; font-weight: 500; }
.p6-f.ans { margin-top: calc(var(--g) * 1.2); padding: 0 0 0 12px; border-left: 3px solid var(--acc); }
.p6-f.ans .p6-k { margin-top: 0; color: var(--acc); }
.p6-case > .fine { margin: 0; }
.p6-mem { align-items: flex-start; }
.p6-case .p6-mem { padding-top: calc(var(--g) * .55); padding-bottom: calc(var(--g) * .55); min-height: 0; }
.p6-mem .t { overflow-wrap: anywhere; }
.p6-mem.other { padding-left: 10px; border-left: 3px solid var(--warn); background: color-mix(in srgb, var(--warn) 14%, transparent); border-radius: 8px; }
.p6-forbid { margin: 0 0 2px; font-size: 13px; line-height: 18px; font-weight: 600; color: var(--ink); }
.p6-void { margin: 0 0 calc(var(--g) * .8); padding: 8px 12px; border-radius: 10px; font-size: 13px; line-height: 18px; color: var(--ink); background: var(--field); box-shadow: inset 0 0 0 1px var(--line); }
.p6-n { flex: none; width: 24px; padding-top: 2px; font-size: 13px; color: var(--faint); font-variant-numeric: tabular-nums; }
.p6-pick { display: grid; gap: calc(var(--g) * .6); margin-top: calc(var(--g) * 1.6); }
.p6-opt { display: flex; align-items: center; gap: 12px; width: 100%; min-height: calc(26px + var(--g) * 1.3); padding: 2px 14px; border: 0; border-radius: 14px; text-align: left; cursor: pointer;
  font: inherit; color: var(--ink); background: var(--field); box-shadow: inset 0 0 0 1px var(--line); transition: background .15s, box-shadow .15s; }
.p6-opt:hover { background: var(--panel-hover); }
.p6-opt:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
.p6-opt b { flex: none; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 999px; font-size: 14px; font-weight: 600; background: var(--line); color: var(--ink); }
.p6-opt .t { display: block; font-size: 15px; line-height: 19px; font-weight: 500; }
.p6-opt .s { display: block; font-size: 12px; line-height: 16px; color: var(--faint); }
.p6-opt[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--acc); }
.p6-opt[aria-pressed="true"] b { background: var(--acc); color: var(--on-ink); }
.p6-opt[disabled] { opacity: var(--opacity-disabled); cursor: default; }
.p6-note-head { display: flex; align-items: baseline; justify-content: space-between; gap: 4px 16px; flex-wrap: wrap; }
.p6-note-head .fine { margin: 0; font-variant-numeric: tabular-nums; }
.p6-note-row { display: flex; align-items: flex-start; gap: 10px; }
.p6-note-row .btn { flex: none; }
.p6-note textarea.field { flex: 1; min-width: 0; height: auto; min-height: 34px; max-height: 160px; padding: 6px 12px; font: 14px/20px var(--font-sans); color: var(--ink); resize: vertical; field-sizing: content; }
.p6-dots { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; margin-top: 14px; }
.p6-dot { height: 32px; border: 0; border-radius: 10px; cursor: pointer; font: 500 12px/1 var(--font-sans); font-variant-numeric: tabular-nums;
  color: var(--muted); background: var(--field); box-shadow: inset 0 0 0 1px var(--line); }
.p6-dot.done { color: var(--ink); background: var(--line); box-shadow: none; }
.p6-dot[aria-current="true"] { box-shadow: inset 0 0 0 2px var(--acc); color: var(--ink); }
@media (min-width: 761px) {
  .p6-case .p6-mem p { display: inline; }
  .p6-case .p6-mem .s { margin-right: 6px; }
}
@media (min-width: 1100px) {
  .sh-body:has(.p6-case) > .main { grid-column: 1 / 10; }
  .sh-body:has(.p6-case) > .aside { grid-column: 10 / 13; }
}
@media (max-width: 760px) {
  .p6-opt { min-height: 48px; padding: 4px 12px; }
  .p6-dots { grid-template-columns: repeat(10, minmax(0, 1fr)); }
  .sh-head:has(.p6-count) .ttl, .sh-head:has(.p6-count) .act { grid-column: 1 / -1; grid-row: auto; }
}

/* ---------- Look v3 (8 Nov 2026): data first ----------
   Every page opens with a strip of headline numbers (label, value, trend, context), then charts whose titles ask the
   question they answer, then detail tables. Status colour only for meaning, always beside its word. Panels stay tonal;
   glass stays on the shell only. One type scale: 12 label, 13 small, 14 body, 15 section, 30 value, 40 page title. */
.kpis { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); padding: 18px 0 16px; }
.kpi { display: flex; flex-direction: column; gap: 4px; min-width: 0; padding: 2px 22px 0; border-left: 1px solid var(--line); }
.kpi:first-child { border-left: 0; }
.kpi .lbl { font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.kpi .val { font-size: 30px; line-height: 36px; font-weight: 500; letter-spacing: -.02em; color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi .val.none { font-size: 20px; line-height: 36px; font-weight: 400; color: var(--faint); letter-spacing: 0; }
.kpi .ctx { font-size: 13px; line-height: 18px; color: var(--muted); font-variant-numeric: tabular-nums; }
.dl { font-weight: 500; }
.dl.good { color: var(--ok); }
.dl.bad { color: var(--danger); }
.dl.flat { color: var(--muted); }
/* State: a dot and its word. good, watch, bad from the portal's status tokens; idle is grey. */
.st { flex: none; display: inline-flex; align-items: center; gap: 7px; min-width: 96px; font-size: 13px; line-height: 18px; font-weight: 500; color: var(--ink); white-space: nowrap; }
.st i { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--chart-step-1); }
.st.good i { background: var(--s-ok); }
.st.watch i { background: var(--s-warn); }
.st.bad i { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='4'%3E%3Cpath d='M-1 1l2-2M0 4l4-4M3 5l2-2' stroke='white' stroke-opacity='.45' stroke-width='1.2'/%3E%3C/svg%3E"), var(--s-danger); }
.st.active i { background: var(--chart-accent); }
.st.idle { color: var(--muted); font-weight: 400; }
.legend .st { min-width: 0; font-size: 12px; font-weight: 400; color: var(--muted); }
.row .r.num { font-size: 15px; color: var(--ink); font-variant-numeric: tabular-nums; }
.row .r.fills { color: var(--faint); }
.empty-row .grow .s { color: var(--muted); }
/* Health and progress bars carry the same meaning as the dots. */
.sh-body > .kpis { grid-column: 1 / -1; }
/* Rows keep their content height; a tall window leaves space below instead of stretching every panel. */
.sh-body { align-content: start; }
@media (max-width: 960px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 18px; padding: 16px 0 14px; }
  .kpi { padding: 0 16px; }
  .kpi:nth-child(odd) { border-left: 0; }
}
@media (max-width: 760px) {
  .kpi { padding: 0 12px; }
  .kpi .val { font-size: 26px; line-height: 32px; }
  .st { min-width: 0; }
  .row > .st { align-self: flex-start; padding-top: 2px; }
}

/* ---------- Board (8 Nov 2026): four columns of cards, a sheet to edit one. Cards are tonal, the sheet is the one glass overlay. ---------- */
.sh-head .act { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.bwrap { grid-column: 1 / -1; min-width: 0; }
.board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; align-items: start; }
.bcol { min-width: 0; padding: 14px 12px 12px; border-radius: 20px; background: var(--panel); box-shadow: var(--panel-shadow); }
.bhead { display: flex; align-items: baseline; gap: 8px; padding: 0 6px 10px; }
.bhead h2 { font-size: 15px; line-height: 20px; font-weight: 500; }
.bhead em, .bcolseg em { font-style: normal; color: var(--faint); font-variant-numeric: tabular-nums; }
.blist { display: grid; gap: 8px; min-height: 48px; }
.bcard { display: grid; gap: 10px; width: 100%; padding: 12px 14px; border: 0; border-radius: 14px; text-align: left; cursor: grab;
  font: inherit; color: var(--ink); background: var(--field); box-shadow: inset 0 0 0 1px var(--line); transition: background .15s, box-shadow .15s; }
.bcard:hover { background: var(--panel-hover); }
.bcard:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
.bcard .bt { font-size: 14px; line-height: 20px; overflow-wrap: anywhere; }
.bcard .bm { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; font-size: 12px; line-height: 16px; color: var(--muted); }
.bcard .bm .st { min-width: 0; font-size: 12px; gap: 5px; }
.bcard .bm .st i { width: 6px; height: 6px; }
.bcard .who { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 10px; font-weight: 600; letter-spacing: .02em; color: var(--ink); background: var(--line); }
.bcard .who.none { color: var(--faint); }
.bcard .tag { padding: 1px 8px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
.bcard .bid { margin-left: auto; color: var(--faint); font-variant-numeric: tabular-nums; }
.due.soon { color: var(--warn); font-weight: 500; }
.due.late { color: var(--danger); font-weight: 500; }
.lowp { color: var(--faint); }
.bempty { padding: 8px 6px 4px; font-size: 13px; color: var(--faint); }
.bghost { opacity: .35; }
.bdrag { box-shadow: 0 12px 30px rgba(0,0,0,.18); }
.bwrap > .fine { margin-top: 14px; }
.bcolseg { display: none; }
/* Sheet colour from the portal's own .modal.brainpop; rendered outside the stage so it covers the tab bar. */
.modal.brainpop.bmodal { width: min(560px, 100%); max-height: calc(100dvh - 40px); overflow: auto; padding: 24px; gap: 14px; }
.bmhead { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.bf { display: grid; gap: 6px; }
.bf > span { font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.bf select.field { -webkit-appearance: none; appearance: none; cursor: pointer; }
.bgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.bnotes { font-family: var(--font-sans); font-size: 14px; min-height: 110px; }
.bhist { display: grid; gap: 4px; margin: 0; padding: 10px 0 0; border-top: 1px solid var(--line); list-style: none; font-size: 12px; line-height: 18px; color: var(--muted); }
.bhist b { font-weight: 500; color: var(--ink); }
.bhist span { color: var(--faint); }
.berr { font-size: 13px; color: var(--danger); }
.bmodal .acts { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.bmodal .acts .grow { flex: 1; }
@media (max-width: 1100px) { .board { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .bcolseg { display: flex; width: 100%; margin-bottom: 12px; overflow-x: auto; }
  .bcolseg button { flex: 1; white-space: nowrap; }
  .board { grid-template-columns: 1fr; }
  .bcol { display: none; }
  .bcol.on { display: block; }
  .bcard { cursor: pointer; }
  .sh-head .act { justify-content: flex-start; }
  .bgrid { grid-template-columns: 1fr 1fr; gap: 10px; }
}

/* Board: avatars and ticket chips used by the person cards and the drawer. */
.who.big { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 600; color: var(--ink); background: var(--line); }
.tag.tlink { flex: none; padding: 1px 8px; border: 0; border-radius: 999px; font: 500 12px/18px var(--font-sans); color: var(--muted); background: none; box-shadow: inset 0 0 0 1px var(--line); cursor: pointer; }
.tag.tlink:hover { color: var(--ink); }

/* ---------- Charts v2.2 (9 Nov 2026): SVG from cx-chart.js, two data colours, one glass tooltip ----------
   Proposal for the design system: knowledge/design/proposals/CHART-KIT-2026-11.md (Fabian reviews, board T-13).
   Status tones are their own tokens: warning and danger differ in lightness (colour-blind ΔE above 21), danger is hatched. */
:root {
  --c-accent: var(--blue-light, #7fa3d6); --c-comp: #6e6f78; --c-grid: rgba(255,255,255,.07); --c-base: rgba(245,245,247,.42);
  --c-band: rgba(255,255,255,.045); --c-area: rgba(127,163,214,.14); --c-ring: #1c1d21;
  --s-ok: #7cc896; --s-warn: #f5c95a; --s-danger: #e5534b; --s-idle: #4a4b52;
  --tip-top: rgba(36,37,42,.62); --tip-bottom: rgba(24,25,29,.72); --tip-rim: rgba(255,255,255,.14); --tip-line: rgba(255,255,255,.10);
  --tip-shadow: 0 18px 48px rgba(0,0,0,.5), 0 2px 6px rgba(0,0,0,.3);
}
:root[data-theme="light"] {
  --c-accent: var(--chart-accent); --c-comp: var(--chart-comparison); --c-grid: var(--chart-grid); --c-base: rgba(29,29,31,.55);
  --c-band: rgba(0,0,0,.035); --c-area: rgba(74,111,165,.10); --c-ring: #fff;
  --s-ok: #2f7d4f; --s-warn: #d39b1f; --s-danger: #b42318; --s-idle: var(--chart-step-1);
  --tip-top: rgba(255,255,255,.74); --tip-bottom: rgba(255,255,255,.62); --tip-rim: rgba(255,255,255,.95); --tip-line: rgba(0,0,0,.07);
  --tip-shadow: 0 18px 48px rgba(0,0,0,.16), 0 2px 6px rgba(0,0,0,.06);
}
.cxc { min-width: 0; margin-top: 6px; }
.cxc.sp { height: 34px; margin-top: auto; padding-top: 8px; box-sizing: content-box; }
.cxc.segs { margin: 0; }
svg.cx { display: block; overflow: visible; outline: none; touch-action: pan-y; cursor: crosshair; }
svg.cx:focus-visible { outline: 2px solid var(--blue); outline-offset: 4px; border-radius: 6px; }
.cx .grid { stroke: var(--c-grid); stroke-width: 1; } .cx .grid.base { stroke: var(--c-base); }
.cx .ax { font: 500 12px var(--font-sans); fill: var(--faint); font-variant-numeric: tabular-nums; }
.cx .val { font: 500 13px var(--font-sans); fill: var(--ink); font-variant-numeric: tabular-nums; }
.cx .lbl { font: 400 13px var(--font-sans); fill: var(--muted); }
.cx .m.accent { fill: var(--c-accent); } .cx .m.comp { fill: var(--c-comp); } .cx .m.outline { fill: none; stroke: var(--c-base); stroke-width: 1.5; }
.cx .m.ok { fill: var(--s-ok); } .cx .m.warn { fill: var(--s-warn); } .cx .m.danger { fill: url(#cx-hatch); } .cx .m.idle { fill: var(--s-idle); }
.cx .track { fill: var(--c-grid); }
.cx .band, .cx .hit { fill: transparent; } .cx .col.on .band { fill: var(--c-band); }
.cx .m, .cx .val { transition: opacity .16s ease; }
.cx.hovering .col:not(.on) .m, .cx.hovering .col:not(.on) .val { opacity: .38; }
.cx .ln { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; } .cx .ln.accent { stroke: var(--c-accent); } .cx .ln.comp { stroke: var(--c-comp); } .cx .ln.dash { stroke-dasharray: 4 4; }
.cx .area.accent { fill: var(--c-area); }
.cx .xh { stroke: var(--c-base); stroke-width: 1; stroke-dasharray: 2 3; opacity: 0; }
.cx .dot { opacity: 0; stroke: var(--c-ring); stroke-width: 2; } .cx .dot.accent { fill: var(--c-accent); } .cx .dot.comp { fill: var(--c-comp); }
.cx .dot.last { opacity: 1; stroke-width: 1.5; }
.cx.xon .xh, .cx.xon .dot { opacity: 1; } .cx.xon .dot.last { opacity: 0; }
svg.mini { flex: none; width: 150px; height: 28px; }
svg.mini rect { fill: var(--c-accent); } svg.mini.alt rect { fill: var(--c-comp); } svg.mini rect:hover { opacity: .7; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 14px 0 4px; font-size: 12px; color: var(--muted); }
.sw { display: inline-block; flex: none; width: 10px; height: 10px; border-radius: 3px; }
.sw.accent { background: var(--c-accent); } .sw.comp { background: var(--c-comp); } .sw.outline { box-shadow: inset 0 0 0 1.5px var(--c-base); }
.sw.ok { background: var(--s-ok); } .sw.warn { background: var(--s-warn); } .sw.idle { background: var(--s-idle); } .sw.none { background: none; }
.sw.danger { background: repeating-linear-gradient(135deg, var(--s-danger) 0 2px, color-mix(in srgb, var(--s-danger) 55%, var(--c-ring)) 2px 4px); }
.sw.line { width: 14px; height: 2px; border-radius: 1px; background: var(--c-comp); } .sw.line.accent { background: var(--c-accent); }
/* The one glass in a data view: the tooltip, a lens over the chart it explains. */
.cx-tip { position: fixed; left: 0; top: 0; z-index: 80; min-width: 200px; max-width: 280px; padding: 12px 14px 10px; border-radius: 12px; pointer-events: none;
  background: linear-gradient(180deg, var(--tip-top), var(--tip-bottom));
  -webkit-backdrop-filter: blur(16px) saturate(1.7); backdrop-filter: blur(16px) saturate(1.7);
  box-shadow: inset 0 1px 0 var(--tip-rim), inset 0 0 0 1px var(--tip-line), var(--tip-shadow);
  opacity: 0; transition: opacity .14s ease, transform .08s ease-out; font-size: 13px; color: var(--muted); }
.cx-tip.on { opacity: 1; }
.cx-tip p { margin: 0; }
.cx-tt { font-size: 12px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); margin-bottom: 8px !important; }
.cx-tr, .cx-tf { display: flex; align-items: center; gap: 8px; padding: 3px 0; }
.cx-tr span, .cx-tf span { flex: 1; } .cx-tr b, .cx-tf b { font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; }
.cx-tr.dim { color: var(--faint); } .cx-tr.dim b { color: var(--muted); font-weight: 400; }
.cx-tf { border-top: 1px solid var(--tip-line); margin-top: 6px !important; padding-top: 7px; }
@media (prefers-reduced-motion: reduce) { .cx-tip, .cx .m { transition: none; } }

/* Agent page (T-49): kind tabs, then a split view, list on the left and the reader on the right. */
.agent { padding: 16px 0 0; overflow: hidden; }
.atabs { display: flex; margin: 0 18px 12px; max-width: calc(100% - 36px); overflow-x: auto; scrollbar-width: none; }
.atabs button { flex: none; }
.atabs button em { font-style: normal; color: var(--faint); font-size: 12px; margin-left: 4px; font-variant-numeric: tabular-nums; }
.asplit { display: grid; grid-template-columns: minmax(280px, 380px) minmax(0, 1fr); border-top: 1px solid var(--line); height: min(78vh, 900px); }
.aside-list { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); }
.afilt { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.afilt .field { height: 36px; font-size: 14px; }
.afilt .seg { align-self: flex-start; }
/* No overscroll-behavior here: at the top or bottom of the list the wheel must carry on to the page. */
.alist { flex: 1; overflow-y: auto; }
/* Folder headers: click to open or close; Review folder marks every open item in it at once. */
.agrp { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; background: var(--pop); border-bottom: 1px solid var(--line); }
.agrp.sub { position: static; background: none; }
.agrp-t { display: flex; flex: 1; min-width: 0; align-items: center; gap: 6px; padding: 9px 8px 9px calc(10px + var(--d, 0) * 16px); border: 0; background: none; color: var(--muted); font: 500 12px/17px var(--font-sans); text-align: left; cursor: pointer; }
.agrp-t:hover { color: var(--ink); }
.agrp-t .grow { min-width: 0; overflow-wrap: anywhere; }
.agrp-t em { flex: none; font-style: normal; font-weight: 400; color: var(--faint); font-variant-numeric: tabular-nums; }
.achev { flex: none; color: var(--faint); transition: transform .15s ease; }
.agrp.open .achev { transform: rotate(90deg); }
.agrp-r, .alink { flex: none; border: 0; background: none; padding: 6px 10px; color: var(--acc); font: 500 12px/17px var(--font-sans); cursor: pointer; border-radius: 8px; }
.agrp-r:hover, .alink:hover { background: var(--panel-hover); }
.alink { align-self: flex-start; padding: 4px 8px; margin-left: -8px; }
.alink[disabled] { opacity: .5; cursor: default; }
.arow2 { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.arow2 .alink { margin-left: 0; }
.abatch { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; background: var(--field); border-bottom: 1px solid var(--line); }
.afilt .abatch { margin: 0 -14px -12px; border-top: 1px solid var(--line); border-bottom: 0; }
.abatch .s { font-size: 13px; line-height: 19px; color: var(--muted); overflow-wrap: anywhere; }
.abatch .s b { font-weight: 500; color: var(--ink); }
.abatch .field { height: 34px; font-size: 13px; }
.abtns { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.abtns .rvb { height: 30px; padding: 0 12px; font-size: 13px; }
.abtns .rvb.good { box-shadow: inset 0 0 0 1.5px var(--s-ok); }
.abtns .rvb.watch { box-shadow: inset 0 0 0 1.5px var(--s-warn); }
.abtns .rvb.bad { box-shadow: inset 0 0 0 1.5px var(--s-danger); }
.aundo { font-size: 13px; color: var(--muted); }
.aundo .alink { margin-left: 2px; }
/* About card: the agent's profile from the registry, the same layout for every agent. */
.aprof { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 8px 32px; }
.aprof .akv { margin: 4px 0 0; border-bottom: 0; padding-bottom: 0; }
.acan { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding-top: 16px; }
.acan .label { font-size: 12px; color: var(--faint); margin-bottom: 6px; }
.aplist { margin: 0; padding-left: 18px; font-size: 13px; line-height: 19px; color: var(--ink); }
.aplist li + li { margin-top: 5px; }
.anotes { margin-top: 12px; }
/* Folded to one line: name, purpose (cut off), account and owner, Details. On a phone it wraps instead. */
.afold { flex-direction: row; align-items: baseline; gap: 4px 14px; padding: 12px 22px; }
.afold h2 { flex: none; font-size: 15px; line-height: 20px; font-weight: 500; }
.afold-p { flex: 0 1 auto; min-width: 35%; font-size: 14px; line-height: 20px; color: var(--body); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.afold-m { flex: 0 1 auto; min-width: 0; font-size: 13px; line-height: 20px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.afold .alink { align-self: center; margin: -4px -8px -4px auto; }
.aabout-card .sect .alink { align-self: center; margin: -4px -8px -4px 0; }
/* Review progress: one line at the top of the review panel, in place of a row of numbers. */
.aprog { margin: 0 18px 12px; }
.aprog p { margin-top: 8px; font-size: 13px; line-height: 19px; color: var(--muted); font-variant-numeric: tabular-nums; }
.aprog p b { font-weight: 500; color: var(--ink); }
.btn em.bn { font-style: normal; margin-left: 6px; opacity: .7; font-variant-numeric: tabular-nums; }
/* Fix and drop list. */
.afix .anote-r { margin: 6px 0 4px; font-size: 14px; line-height: 20px; color: var(--ink); white-space: pre-wrap; overflow-wrap: anywhere; }
.arow { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 14px; border: 0; border-bottom: 1px solid var(--line); background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.arow:hover { background: var(--panel-hover); }
.arow.on { background: var(--active); box-shadow: inset 3px 0 0 var(--acc); }
.arow .grow { min-width: 0; }
.arow .t { display: block; font-size: 14px; line-height: 19px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.arow .s { display: block; font-size: 12px; line-height: 17px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.arow .st { min-width: 0; font-size: 12px; }
.adot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 7px; vertical-align: 1px; background: var(--s-warn); }
.adot.bad { background: var(--s-danger); }
.apad { padding: 16px 14px; }
.aread { min-width: 0; overflow-y: auto; padding: 18px 22px 28px; }
.aread.empty { display: grid; place-items: center; text-align: center; }
.ahead { display: flex; gap: 12px; align-items: flex-start; }
.ahead h2 { font-size: 20px; line-height: 26px; font-weight: 500; overflow-wrap: anywhere; }
.ahead .label { font-size: 12px; color: var(--faint); }
.ahead .s { font-size: 13px; color: var(--muted); margin-top: 2px; overflow-wrap: anywhere; }
.aback { display: none; }
.rvbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 14px 0 10px; }
.rvb { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px; border-radius: 999px; border: 0; background: var(--field); color: var(--ink); font: 500 14px/1 var(--font-sans); cursor: pointer; box-shadow: inset 0 0 0 1px var(--line); }
.rvb kbd { font: 500 11px/1 var(--font-sans); color: var(--faint); }
.rvb[aria-pressed="true"].good { box-shadow: inset 0 0 0 2px var(--s-ok); }
.rvb[aria-pressed="true"].watch { box-shadow: inset 0 0 0 2px var(--s-warn); }
.rvb[aria-pressed="true"].bad { box-shadow: inset 0 0 0 2px var(--s-danger); }
.aread .anote { width: 100%; font: 14px/20px var(--font-sans); min-height: 64px; resize: vertical; font-size: 14px; line-height: 20px; padding: 10px 12px; }
.aabout { margin: 12px 0 0; font-size: 14px; line-height: 21px; color: var(--muted); }
.akv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; margin: 14px 0; padding: 12px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 13px; line-height: 19px; }
.akv span { color: var(--faint); }
.akv b { font-weight: 400; color: var(--ink); overflow-wrap: anywhere; }
.atext, .amd pre { margin: 12px 0 0; padding: 12px 14px; border-radius: 12px; background: var(--field); font: 12.5px/1.55 var(--font-mono); white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink); }
.amd { margin-top: 12px; font-size: 15px; line-height: 24px; color: var(--ink); overflow-wrap: anywhere; }
.amd h3 { font-size: 19px; line-height: 26px; font-weight: 500; margin: 18px 0 6px; }
.amd h4, .amd h5, .amd h6 { font-size: 15px; font-weight: 500; margin: 14px 0 4px; }
.amd p, .amd blockquote { margin: 0 0 10px; }
.amd blockquote { padding-left: 12px; border-left: 2px solid var(--line); color: var(--muted); }
.amd ul, .amd ol { margin: 0 0 10px; padding-left: 22px; }
.amd code { font: 13px var(--font-mono); padding: 1px 5px; border-radius: 6px; background: var(--field); }
.amd pre.fm, .amd pre.tbl { font-size: 12px; color: var(--muted); }
.amd .wl { color: var(--acc); }
.amd a { color: var(--acc); }
@media (max-width: 900px) {
  .aprof, .acan { grid-template-columns: 1fr; }
  .afold { flex-wrap: wrap; row-gap: 2px; padding: 8px 16px 10px; }
  .afold-p { flex-basis: 100%; order: 3; white-space: normal; }
  .afold-m { flex-basis: 100%; order: 4; white-space: normal; }
  .asplit { grid-template-columns: minmax(0, 1fr); height: auto; }
  .aside-list { border-right: 0; }
  .alist { max-height: 70vh; }
  .asplit .aread.empty { display: none; }
  .asplit.picked .aside-list { display: none; }
  .aback { display: inline-flex; }
  .aread { padding: 16px; }
}

/* AI services tab (v2, one screen like Cost): service detail sits in the drawer. */
.ai-more .row .s { margin: 0 0 2px; }
.ai-red { color: var(--danger); font-weight: 500; }
.ai-chip { margin: 0 0 12px; }
.ai-li .st { min-width: 92px; }
.ai-li .grow { min-width: 0; }
.ai-li .s { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-li .s.wrap { white-space: normal; }
.ai .main .sect { align-items: center; }
/* State donut: status colours, not the series ramp. */
.cx .m.ok { fill: var(--s-ok); } .cx .m.warn { fill: var(--s-warn); } .cx .m.idle { fill: var(--s-idle); } .cx .m.danger { fill: var(--s-danger); }
/* OpenAI panels refresh in place inside #oai, in the drawer. */
.oai { display: flex; flex-direction: column; gap: 14px; }
.oai > .kpis { --n: 2 !important; row-gap: 10px; }

/* ---------- Rail v2 (Noland 13 Nov 2026): five groups, and a rail that folds to icons ----------
   One width transition on the rail (220 ms, the DS arrive curve); the stage is a flex sibling, so it follows in the
   same frame with no jump. Labels fade and clip and never wrap. Charts hold still while it moves (cx.refit after).
   Open or shut lives on <html data-rail>, so a re-render never replays it. */
:root { --rail-w: 264px; --rail-shut: 62px; --rail-dur: 220ms; }
:root[data-rail="shut"] { --rail-w: var(--rail-shut); }
@media (max-width: 1180px) { :root:not([data-rail="shut"]) { --rail-w: 232px; } }
@media (min-width: 761px) {
  .frame { display: flex; }
  .frame > .rail { position: relative; flex: none; width: var(--rail-w); transition: width var(--rail-dur) var(--ease-arrive); will-change: width; contain: layout paint; }
  .frame > .stage { flex: 1 1 0; }
}
.rail .rscroll { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; margin: 0 -12px; padding: 4px 12px 0; scrollbar-width: none; }
.rail .rscroll::-webkit-scrollbar { display: none; }
.rail .rlabel { padding: 12px 10px 4px; height: 32px; white-space: nowrap; position: relative; }
.rail .rlabel:first-child { padding-top: 6px; height: 26px; }
.rail .rnav a { position: relative; height: 34px; white-space: nowrap; }
.rail .rt { min-width: 0; overflow: hidden; text-overflow: clip; white-space: nowrap; }
.brand { position: relative; flex: none; white-space: nowrap; }
.brand .rail-mark { position: absolute; left: 7px; top: 50%; width: 24px; height: 24px; margin-top: -12px; border-radius: 7px; opacity: 0; visibility: hidden; }
/* Fade out quickly, fade in once the rail has room again. */
.rail .rt, .rail .rlabel span, .brand .word, .brand .tagline, .rail .badge {
  transition: opacity 160ms var(--ease-arrive) 60ms, visibility 0s linear 0s; }
.brand .rail-mark { transition: opacity 120ms var(--ease-arrive), visibility 0s linear 120ms; }
:root[data-rail="shut"] .rail .rt, :root[data-rail="shut"] .rail .rlabel span, :root[data-rail="shut"] .brand .word,
:root[data-rail="shut"] .brand .tagline {
  opacity: 0; visibility: hidden; transition: opacity 100ms var(--ease-arrive), visibility 0s linear 100ms; }
:root[data-rail="shut"] .brand .rail-mark { opacity: 1; visibility: visible; transition: opacity 160ms var(--ease-arrive) 80ms, visibility 0s; }
/* Shut: each group label becomes a short hairline at the same height, so no icon moves up or down. */
.rail .rlabel::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 9px; height: 1px; background: var(--line-2); opacity: 0; transition: opacity 160ms var(--ease-arrive); }
.rail .rlabel:first-child::after { display: none; }
:root[data-rail="shut"] .rail .rlabel::after { opacity: 1; }
/* Shut: the Overview count becomes a dot on its icon. */
:root[data-rail="shut"] .rail .badge { position: absolute; top: 6px; left: 23px; min-width: 0; width: 8px; height: 8px; padding: 0; font-size: 0; box-shadow: 0 0 0 2px var(--rail); }
.rail .me { transition: padding var(--rail-dur) var(--ease-arrive); }
:root[data-rail="shut"] .rail .me { padding-left: 5px; }
/* The edge control: sits on the rail's right edge and travels with it. */
.rail-edge { position: absolute; z-index: 3; top: 50%; margin-top: -13px; left: calc(12px + var(--rail-w) - 13px); width: 26px; height: 26px; padding: 0; border: 0; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer; color: var(--muted); background: var(--rail); -webkit-backdrop-filter: blur(18px) saturate(1.6); backdrop-filter: blur(18px) saturate(1.6);
  box-shadow: inset 0 0 0 1px var(--line-2), 0 4px 12px -4px var(--scrim);
  opacity: .75; transition: left var(--rail-dur) var(--ease-arrive), opacity .15s, color .15s; }
.rail-edge svg { transition: transform var(--rail-dur) var(--ease-arrive); }
:root[data-rail="shut"] .rail-edge svg { transform: rotate(180deg); }
.frame:hover .rail-edge, .rail-edge:focus-visible { opacity: 1; }
.rail-edge:hover { color: var(--ink); }
.rail-edge:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
.rail-tip { position: fixed; z-index: 70; transform: translateY(-50%); padding: 5px 10px; border-radius: 8px; pointer-events: none; white-space: pre;
  font-size: 12px; font-weight: 500; line-height: 16px; color: var(--ink); background: var(--rail); -webkit-backdrop-filter: blur(18px) saturate(1.6); backdrop-filter: blur(18px) saturate(1.6);
  box-shadow: inset 0 0 0 1px var(--line-2), 0 6px 18px -6px var(--scrim);
  animation: tipin 120ms var(--ease-arrive); }
.rail-tip[hidden] { display: none; }
@keyframes tipin { from { opacity: 0; transform: translate(-4px, -50%); } }
/* While the rail moves, charts keep their size and clip; they redraw once at the end. */
.rail-moving .cxc { overflow: hidden; }
.mgroup { margin: 12px 0 2px; font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.mgroup:first-child { margin-top: 2px; }
.crumb span { color: var(--faint); }
@media (max-width: 760px) { .rail-edge { display: none; } }
@media (prefers-reduced-motion: reduce) {
  .frame > .rail, .rail-edge, .rail-edge svg, .rail .rt, .rail .rlabel span, .rail .rlabel::after, .brand .word, .brand .rail-mark, .brand .tagline, .rail .me, .rail-tip { transition: none; animation: none; }
}

/* ---------- Board v3 (Noland 13 Nov 2026): one screen. KPIs, a card per person, what needs a decision, the kanban
   behind a button. The long text lives in the person drawer. Fits 1440 by 900 without scrolling. ---------- */
.sh-body.exec { row-gap: 14px; }
main:has(> .sh-body.exec) { padding-top: 22px; padding-bottom: 24px; }
.sh-head.compact { padding-bottom: 14px; align-items: center; }
.sh-head.compact .ttl { grid-column: 1 / 6; }
.sh-head.compact .act { grid-column: 6 / 13; }
.sh-head.compact .h1 { font-size: 34px; line-height: 40px; }
.exec > .kpis { padding: 12px 0 10px; }
.exec .kpi .val { font-size: 28px; line-height: 34px; }
.pcards { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); gap: 16px; }
.pcard { display: flex; flex-direction: column; gap: 10px; min-width: 0; padding: 16px 18px 14px; border-radius: 20px; background: var(--panel); box-shadow: var(--panel-shadow);
  cursor: pointer; text-align: left; transition: box-shadow .15s, transform .2s var(--ease-arrive); }
.pcard:hover { box-shadow: var(--panel-shadow), inset 0 0 0 1px var(--line-2); }
.pcard:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
.pcard:active { transform: scale(.995); }
.phead { display: flex; align-items: center; gap: 12px; }
.phead b { display: block; font-size: 16px; line-height: 20px; font-weight: 500; color: var(--ink); }
.phead small { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--faint); }
.phead .open-ic { color: var(--faint); transform: rotate(180deg); display: grid; }
.pcard:hover .open-ic { color: var(--ink); }
.ldot { width: 7px; height: 7px; border-radius: 50%; background: var(--live); }
/* Board v4 (Noland 22 Nov 2026): what needs you, bugs beside it, a slim card per person; lists below behind a click. */
.kpis button.kpi { border: 0; border-left: 1px solid var(--line); background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; border-radius: 0; }
.kpis button.kpi:first-child { border-left: 0; }
.kpis button.kpi:hover .val { color: var(--acc); }
.kpis button.kpi:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; border-radius: 8px; }
.bmid { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 16px; align-items: stretch; }
.bmid > .blk { min-width: 0; }
.bmid .sect h2 em, .pblk .sect h2 em { font-style: normal; font-weight: 400; color: var(--faint); margin-left: 8px; font-size: 13px; }
.bmid .sect { align-items: center; }
.nrows { display: flex; flex-direction: column; }
.nrow { display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 0 8px; margin: 0 -8px; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: none;
  font: 400 14px/20px var(--font-sans); color: var(--body); text-align: left; cursor: pointer; }
.nrow:hover { background: var(--panel-hover); color: var(--ink); }
.nrow:focus-visible { outline: 2px solid var(--acc); outline-offset: -2px; border-radius: 8px; }
.nrow .bid, .brow .bid { flex: none; width: 46px; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.nrow .nt, .brow .nt { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nrow .nwho { flex: none; width: 56px; font-size: 13px; color: var(--muted); }
.nrow .nage, .nrow .due { flex: none; width: 76px; text-align: right; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.nrow .nage.old { color: var(--danger); font-weight: 500; }
.bugsp { background: var(--field); }
.sevbar { display: flex; gap: 2px; height: 8px; margin: 2px 0 6px; border-radius: 999px; overflow: hidden; background: var(--chart-step-2); }
.sevbar i { display: block; min-width: 6px; }
.sevbar .sv-critical { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='4'%3E%3Cpath d='M-1 1l2-2M0 4l4-4M3 5l2-2' stroke='white' stroke-opacity='.45' stroke-width='1.2'/%3E%3C/svg%3E"), var(--s-danger); }
.sevbar .sv-high { background: var(--s-danger); }
.sevbar .sv-medium { background: var(--s-warn); }
.sevbar .sv-low { background: var(--chart-step-1); }
.sevkey { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 0 0 8px; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.sevkey .on { color: var(--ink); font-weight: 500; }
.brows { display: flex; flex-direction: column; }
.brow { display: flex; flex-direction: column; gap: 6px; padding: 10px 8px; margin: 0 -8px; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: none;
  font: 400 14px/20px var(--font-sans); color: var(--ink); text-align: left; cursor: pointer; }
.brow:hover { background: var(--panel-hover); }
.brow:focus-visible { outline: 2px solid var(--acc); outline-offset: -2px; border-radius: 8px; }
.brow-t { display: flex; align-items: center; gap: 10px; min-width: 0; font-weight: 500; }
.brow-m { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.brow-m .st { min-width: 0; font-size: 12px; }
.chip { padding: 1px 8px; border-radius: 999px; font-size: 12px; line-height: 18px; color: var(--muted); box-shadow: inset 0 0 0 1px var(--line-2); white-space: nowrap; }
.pblk { grid-column: 1 / -1; }
.pblk .sect { display: flex; align-items: center; padding: 0 2px 10px; }
.pblk .sect h2 { margin: 0; font-size: 16px; line-height: 22px; font-weight: 500; }
.pblk .sect .btn { margin-left: auto; }
.pcard.slim { gap: 6px; padding: 14px 16px 12px; border-radius: 16px; }
.pcard.slim .phead { gap: 8px; }
.pcard.slim .phead b { display: inline; font-size: 15px; }
.ldot.off { background: var(--chart-step-1); }
.pnow1 { margin: 0; font-size: 14px; line-height: 20px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pnow1.idle { color: var(--faint); }
.pwip { margin: 0; font-size: 12px; line-height: 16px; color: var(--muted); font-variant-numeric: tabular-nums; }
.pwip b { font-weight: 500; color: var(--ink); }
.pwip .warn { color: var(--danger); font-weight: 500; }
.pcard .fresh.bad { margin: 0; font-size: 12px; color: var(--danger); font-weight: 500; }
.tickets .thead .seg.kseg { margin-left: 0; }
.bmsg { margin: 0 18px 10px; font-size: 13px; color: var(--ink); }
.gsum { margin: 0 0 4px; font-size: 15px; line-height: 22px; color: var(--ink); }
.gtext { margin: 0; font-size: 14px; line-height: 21px; color: var(--body); white-space: pre-wrap; overflow-wrap: anywhere; }
.gea { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.gea h3 { margin: 0 0 4px; }
.gev { margin: 0; padding: 10px 12px; border-radius: 10px; background: var(--field); font: 12px/18px ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--body); white-space: pre-wrap; overflow-wrap: anywhere; max-height: 220px; overflow: auto; }
.glinks { flex-wrap: wrap; }
.glink { display: inline-flex; align-items: center; gap: 2px; }
.glink .tag { padding: 1px 8px; border-radius: 999px; font-size: 12px; box-shadow: inset 0 0 0 1px var(--line); color: var(--muted); text-decoration: none; }
.gx { width: 22px; height: 22px; border: 0; border-radius: 999px; background: none; color: var(--faint); cursor: pointer; font-size: 14px; line-height: 1; }
.gx:hover { color: var(--ink); background: var(--panel-hover); }
.gadd { display: inline-flex; gap: 6px; }
.gadd .field { width: 150px; }
.gmodal { max-height: calc(100vh - 48px); overflow: auto; }
.gmodal textarea.field { min-height: 64px; font: 400 14px/20px var(--font-sans); }
.bgrid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 1000px) { .bmid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) {
  .pcards { grid-template-columns: minmax(0, 1fr); }
  .nrow .nwho { display: none; }
  .gea, .bgrid.two { grid-template-columns: minmax(0, 1fr); }
}
/* Tickets (Noland 13 Nov 2026): the list with a reader beside it, the Agents page grammar. No drawer, nothing stacked. */
.pcard.on { box-shadow: var(--panel-shadow), inset 0 0 0 2px var(--acc); }
.tickets .thead { display: flex; padding: 0 18px 12px; align-items: center; gap: 12px; }
.tickets .thead .seg { margin-left: auto; }
.tickets .asplit { grid-template-columns: minmax(300px, 460px) minmax(0, 1fr); }
.tickets .afilt .seg.sm button { padding: 0 10px; }
.tickets .thead h2 em, .tickets .seg em { font-style: normal; font-weight: 400; color: var(--faint); margin-left: 6px; font-variant-numeric: tabular-nums; }
.tickets .afilt .seg { max-width: 100%; overflow-x: auto; }
.tgrp .agrp-t { cursor: default; }
.trow .due { flex: none; font-size: 12px; }
.tnav { display: flex; gap: 6px; flex: none; }
.tread .label { font-variant-numeric: tabular-nums; }
.tprops { align-items: center; }
.tprops b { display: flex; align-items: center; gap: 10px; min-width: 0; }
.tprops .field { height: 32px; max-width: 220px; padding: 0 10px; font-size: 14px; }
.tprops select.field { -webkit-appearance: none; appearance: none; cursor: pointer; padding-right: 10px; }
.tprops .none { color: var(--faint); }
.tnotes { margin-top: 14px; }
.tnotes .sect { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tnotes h3 { font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.tnotes .amd { margin-top: 6px; }
.tnotes .bhist { margin-top: 6px; border-top: 0; padding-top: 0; }
.tedit { display: grid; gap: 12px; margin-top: 14px; }
.tedit .bnotes { min-height: 220px; resize: vertical; font: 14px/21px var(--font-sans); }
.tedit .acts { display: flex; align-items: center; gap: 8px; }
.tedit .acts .grow, .tfoot .grow { flex: 1; }
.tfoot { display: flex; align-items: center; gap: 8px; margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--line); }
.tread .fine { margin-top: 10px; }
.tread .fine.stale { color: var(--danger); font-weight: 500; }
.tread .ahead .who.big { margin-top: 2px; }
.tcolbar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 0 18px 12px; }
.tcolbar .fine { margin: 0; }
.tickets .board, .tickets > .bcolseg, .tickets > .fine { margin-left: 18px; margin-right: 18px; }
.tickets > .fine { margin-bottom: 16px; }
.dsec { padding: 14px 0 6px; border-top: 1px solid var(--line); }
.dsec:first-child { border-top: 0; }
.dsec h3 { margin-bottom: 6px; font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.dsec h3 em { font-style: normal; margin-left: 6px; }
.dnow { font-size: 16px; line-height: 23px; color: var(--ink); overflow-wrap: anywhere; }
.xrow { display: flex; align-items: flex-start; gap: 10px; width: 100%; padding: 8px 8px; margin: 0 -8px; width: calc(100% + 16px); border: 0; border-radius: 10px; background: none;
  font: inherit; text-align: left; color: inherit; text-decoration: none; }
a.xrow, button.xrow { cursor: pointer; }
a.xrow:hover, button.xrow:hover { background: var(--panel-hover); }
.xrow b { display: block; font-size: 14px; line-height: 20px; font-weight: 400; color: var(--ink); overflow-wrap: anywhere; }
.xrow small { display: block; font-size: 12px; line-height: 17px; color: var(--faint); }
@media (max-width: 1180px) { .dec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 980px) { .pcards { grid-template-columns: minmax(0, 1fr); } .ptix { min-height: 0; } }
@media (max-width: 760px) {
  .tnav { display: none; }
  .tprops .field { max-width: 100%; }
  .dec-grid { grid-template-columns: minmax(0, 1fr); }
  .sh-head.compact .ttl, .sh-head.compact .act { grid-column: 1 / -1; }
  .sh-head.compact .act { flex-wrap: wrap; justify-content: flex-start; margin-top: 12px; }
  .sh-head.compact .act .seg { max-width: 100%; overflow-x: auto; }
}
/* Timeline (Noland 13 Nov 2026): tickets over time at #/board/timeline. One lane per owner, bars from added to done,
   history ticks, a due diamond, a today line. Chart and status tokens only; the chart scrolls sideways, never the page. */
.seg a.btl-link { display: inline-flex; align-items: center; height: 30px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--muted); text-decoration: none; white-space: nowrap; text-transform: none; letter-spacing: normal; }
.seg a.btl-link:hover { color: var(--ink); }
.btl-back { flex: none; margin-left: auto; text-transform: none; letter-spacing: normal; }
.btl-legend { margin: 0 0 0 auto; }
.btl-key { display: inline-block; flex: none; }
.btl-key.due { width: 8px; height: 8px; transform: rotate(45deg); background: var(--c-ring); box-shadow: inset 0 0 0 1.5px var(--ink); }
.btl-key.hist { width: 2px; height: 10px; border-radius: 1px; background: var(--c-base); }
.btl-key.now { width: 2px; height: 12px; background: var(--acc); }
.btl-key.plan { width: 14px; height: 8px; border-radius: 3px; box-shadow: inset 0 0 0 1.5px var(--c-accent); }
.btl-scroll { --lw: 300px; overflow-x: auto; overscroll-behavior-x: contain; margin: 0 0 4px; border-top: 1px solid var(--line); }
.btl-chart { min-width: calc(var(--lw) + 520px); padding-bottom: 6px; overflow: clip; }
.btl-row { position: relative; display: grid; grid-template-columns: var(--lw) minmax(0, 1fr); align-items: center; width: 100%; min-height: 32px; padding: 0; border: 0; background: none;
  font: inherit; text-align: left; color: inherit; }
button.btl-row { cursor: pointer; border-radius: 8px; }
button.btl-row:hover { background: var(--panel-hover); }
button.btl-row:focus-visible { outline: 2px solid var(--acc); outline-offset: -2px; }
.btl-lbl { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 0 12px 0 18px; font-size: 13px; line-height: 18px; }
.btl-lbl .bid { flex: none; font-variant-numeric: tabular-nums; color: var(--faint); }
.btl-t { min-width: 0; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--ink); }
.btl-lbl .due { flex: none; font-size: 12px; }
.btl-lane { position: relative; display: block; height: 32px; margin-right: 18px; }
.btl-g { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--c-grid); }
.btl-now { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--acc); z-index: 2; }
.btl-axis { min-height: 30px; }
.btl-axis .btl-lane { height: 30px; }
.btl-tk { position: absolute; top: 8px; padding-left: 4px; font-size: 11px; line-height: 14px; color: var(--faint); white-space: nowrap; font-variant-numeric: tabular-nums; }
.btl-tk.now { top: 8px; transform: translateX(-100%); padding: 0 6px 0 4px; color: var(--ink); font-weight: 500; background: var(--c-ring); border-radius: 4px; z-index: 3; }
.btl-grp { min-height: 34px; border-top: 1px solid var(--line); }
.btl-grp .btl-lane { height: 34px; }
.btl-grp b { font-size: 12px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.btl-grp em { font-style: normal; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.btl-bar { position: absolute; top: 10px; height: 12px; min-width: 4px; border-radius: 4px; z-index: 1; }
.btl-bar.cut { border-top-left-radius: 0; border-bottom-left-radius: 0; }
.btl-bar.open { background: var(--c-accent); }
.btl-bar.done { background: var(--c-comp); }
.btl-plan { position: absolute; top: 10px; height: 12px; border: 1.5px dashed var(--c-accent); border-left: 0; border-radius: 0 4px 4px 0; box-sizing: border-box; z-index: 1; }
.btl-plan.beyond { border-right: 0; border-radius: 0; }
.btl-far { position: absolute; right: 0; top: 7px; padding: 0 4px; border-radius: 4px; font-size: 11px; line-height: 18px; color: var(--ink); background: var(--c-ring); white-space: nowrap; z-index: 3; }
.btl-bar.late { background: repeating-linear-gradient(135deg, var(--s-danger) 0 2px, color-mix(in srgb, var(--s-danger) 55%, var(--c-ring)) 2px 4px); }
.btl-h { position: absolute; top: 9px; height: 14px; width: 2px; margin-left: -1px; border-radius: 1px; background: var(--c-ring); z-index: 2; }
.btl-h.out { background: var(--c-base); }
.btl-due { position: absolute; top: 12px; width: 8px; height: 8px; margin-left: -4px; transform: rotate(45deg); background: var(--c-ring); box-shadow: inset 0 0 0 1.5px var(--ink); z-index: 3; }
.btl-due.late { box-shadow: inset 0 0 0 2px var(--s-danger); }
.btl > .fine { margin: 6px 18px 16px; }
/* Phone: each row stacks, the title on top (it stays put while the bars scroll), the bar under it. */
@media (max-width: 760px) {
  .btl-legend { margin: 0; }
  .btl-scroll { --lw: 0px; }
  .btl-chart { min-width: max(100%, calc(var(--days) * var(--pxd, 26px))); }
  .btl-row { grid-template-columns: minmax(0, 1fr); }
  .btl-lbl { position: sticky; left: 0; width: min(100%, calc(100vw - 64px)); padding: 6px 12px 0; }
  .btl-axis .btl-lbl { display: none; }
  .btl-lane { margin: 0 12px; height: 26px; }
  .btl-bar, .btl-plan { top: 7px; } .btl-far { top: 4px; } .btl-h { top: 6px; } .btl-due { top: 9px; }
  .btl-grp .btl-lbl { padding-top: 10px; }
}
/* Set here, not in markup: the site's CSP (style-src 'self') drops style attributes. */
.svg-defs { position: absolute; }
.hatch-fg { fill: var(--danger); }
.hatch-bg { fill: var(--c-ring); }

/* ---------- Cost v3 (Noland 13 Nov 2026): one screen, donuts, a drawer for every record ----------
   Fits 1440 by 900 without scrolling. No inline style attributes anywhere (the site's CSP drops them). */
.sh-body.cost { row-gap: 14px; grid-auto-rows: max-content; }
.sh-body.cost > * { min-height: min-content; }
main:has(> .sh-body.cost) { padding: 22px 28px 20px; }
.cost > .kpis { padding: 6px 0 4px; }
.sh-head.inline { padding-bottom: 12px; }
.sh-head.inline .ttl { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 16px; }
.sh-head.inline .lead { margin: 0; font-size: 15px; line-height: 22px; }
.cost .kpi .val { font-size: 28px; line-height: 34px; }
button.kpi { appearance: none; border-top: 0; border-right: 0; border-bottom: 0; border-radius: 0; background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; transition: background .15s; }
button.kpi:first-child { border-left: 0; }
button.kpi:hover { background: var(--panel-hover); }
button.kpi:focus-visible { outline: 2px solid var(--acc); outline-offset: -2px; border-radius: 12px; }
.cost .kpi:hover .val { color: var(--ink); }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Donut row */
.dnrow { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; padding: 0; background: none; box-shadow: none; }
.dpan { padding: 14px 14px 10px 16px; min-width: 0; }
.dpan .sect { align-items: center; margin-bottom: 10px; min-height: 28px; }
.h2b { display: inline-flex; align-items: center; gap: 2px; min-width: 0; margin: 0 0 0 -4px; padding: 3px 4px; border: 0; border-radius: 8px; background: none; color: var(--ink); font: inherit; cursor: pointer; text-align: left; }
.h2b h2 { font-size: 15px; line-height: 20px; font-weight: 500; }
.h2b svg { flex: none; color: var(--faint); transition: transform .2s var(--ease-arrive), color .15s; }
.h2b:hover svg { color: var(--ink); transform: translateX(2px); }
.h2b:focus-visible { outline: 2px solid var(--acc); outline-offset: 1px; }
.dwrap { display: grid; grid-template-columns: 108px minmax(0, 1fr); gap: 14px; align-items: center; }
.cxc.dn { width: 108px; height: 108px; margin: 0; }
svg.cx .dtot { font: 500 16px var(--font-sans); fill: var(--ink); font-variant-numeric: tabular-nums; }
svg.cx .dlab { font: 400 11px var(--font-sans); fill: var(--muted); }
.cxc.dn svg.cx { cursor: pointer; }
.cx circle.track { fill: none; stroke: var(--c-grid); }
.dleg { display: grid; gap: 1px; min-width: 0; align-content: center; }
.lg-row { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto 28px; align-items: center; gap: 7px; height: 26px; margin: 0 -8px; padding: 0 8px; border: 0; border-radius: 8px; background: none;
  color: var(--body); font: 400 13px/18px var(--font-sans); text-align: left; cursor: pointer; transition: background .15s; }
.lg-row:hover, .lg-row.on { background: var(--panel-hover); color: var(--ink); }
.lg-row:focus-visible { outline: 2px solid var(--acc); outline-offset: 1px; }
.lg-row .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-row .am { font-weight: 500; color: var(--ink); text-align: right; font-variant-numeric: tabular-nums; }
.lg-row .pc { font-size: 12px; color: var(--faint); text-align: right; font-variant-numeric: tabular-nums; }
.dnfoot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 8px 0 2px; min-height: 26px; font-size: 13px; line-height: 18px; color: var(--faint); }
.dnfoot .dn-note { font-size: 12px; }
.dnfoot b { font-weight: 500; color: var(--ink); }
.seg.xs { padding: 2px; }
.seg.xs button { height: 24px; padding: 0 10px; font-size: 12px; }
.dpan .sect .seg { flex: none; }

/* Donut colours: the largest slice is the accent, the rest step down one ramp toward the comparison grey (the kit's two data colours). */
.cx .m.s0, .sw.s0 { fill: var(--c-accent); background: var(--c-accent); }
.cx .m.s1, .sw.s1 { fill: color-mix(in srgb, var(--c-accent) 70%, var(--c-comp)); background: color-mix(in srgb, var(--c-accent) 70%, var(--c-comp)); }
.cx .m.s2, .sw.s2 { fill: color-mix(in srgb, var(--c-accent) 38%, var(--c-comp)); background: color-mix(in srgb, var(--c-accent) 38%, var(--c-comp)); }
.cx .m.s3, .sw.s3 { fill: var(--c-comp); background: var(--c-comp); }
.cx .m.s4, .sw.s4 { fill: color-mix(in srgb, var(--c-comp) 62%, var(--c-ring)); background: color-mix(in srgb, var(--c-comp) 62%, var(--c-ring)); }
.cx .m.s5 { fill: none; stroke: var(--c-base); stroke-width: 1.5; pointer-events: all; }
.sw.s5 { background: none; box-shadow: inset 0 0 0 1.5px var(--c-base); }

/* Months outside the chosen period step back, so the chart shows the year and the period together. */
.cx .col.mute .m, .cx .col.mute .val { opacity: .38; }
.cx .col.mute.on .m { opacity: 1; }
.legend .lg-note { margin-left: auto; color: var(--faint); }

/* What needs you */
.cost .aside.blk { padding-bottom: 10px; }
.att { width: calc(100% + 20px); border: 0; background: none; font: inherit; color: inherit; text-align: left; align-items: flex-start; }
.cost .row.att { gap: 10px; padding-top: 6px; padding-bottom: 6px; min-height: 48px; }
.att .st { min-width: 72px; padding-top: 1px; }
.cost .main > .legend { flex: none; margin-top: auto; padding-top: 10px; }
.att .grow { min-width: 0; }
.att .t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att .why { -webkit-line-clamp: 1; }
.allclear { display: grid; gap: 8px; padding: 12px 0 18px; }
.allclear p { margin: 0; font-size: 14px; line-height: 20px; color: var(--muted); }
.afoot { margin-top: auto; padding-top: 6px; border-top: 1px solid var(--line); }
.afoot .alink { display: inline-flex; align-items: center; gap: 4px; margin: 0 -6px; padding: 4px 6px; border: 0; border-radius: 8px; background: none; color: var(--muted); font: 500 13px var(--font-sans); cursor: pointer; }
.afoot .alink:hover { color: var(--ink); }
.afoot .alink:focus-visible { outline: 2px solid var(--acc); outline-offset: 1px; }

/* The drawer: from the right, over a scrim, solid like the sheets. Esc and the scrim close it. */
.dr-scrim { position: fixed; inset: 0; z-index: 60; background: var(--scrim); }
.dr { position: fixed; z-index: 61; top: 12px; right: 12px; bottom: 12px; width: min(580px, calc(100vw - 24px)); display: flex; flex-direction: column; min-height: 0; border-radius: 22px;
  background: linear-gradient(var(--pop), var(--pop)), var(--bg); box-shadow: var(--rim), var(--lift); }
.dr.enter { animation: drin .3s var(--ease-arrive); }
.dr-scrim.enter { animation: drfade .22s ease; }
@keyframes drin { from { opacity: 0; transform: translateX(28px); } }
@keyframes drfade { from { opacity: 0; } }
.dr-head { display: flex; align-items: flex-start; gap: 12px; padding: 22px 20px 14px 26px; border-bottom: 1px solid var(--line); }
.dr-tt { flex: 1; min-width: 0; }
.dr-tt .lbl { font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.dr-tt h2 { margin: 2px 0 0; font-size: 24px; line-height: 30px; font-weight: 500; letter-spacing: -.02em; color: var(--ink); }
.dr-tot { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 12px; margin: 6px 0 0; }
.dr-tot b { font-size: 20px; line-height: 26px; font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; }
.dr-tot span { font-size: 13px; color: var(--muted); }
.dr-body { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 4px 26px 28px; }
.dr-sec { padding-top: 18px; }
.dr-sec h3, .dr-h h3 { margin: 0 0 6px; font-size: 15px; line-height: 20px; font-weight: 500; color: var(--ink); }
.dr-sec h3 em { font-style: normal; font-weight: 400; color: var(--faint); margin-left: 6px; }
.dr-sec .fine { margin: 0 0 8px; }
.dr-sec .fine.pad { padding: 14px 0; }
.dr-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.dr-h h3 { margin: 0; }
.dr-tabs { margin-top: 14px; max-width: 100%; overflow-x: auto; }
.dr-q { margin: 4px 0 8px; }
.dr-q .field.search { height: 38px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 10px; }
.chips button { height: 28px; padding: 0 12px; border: 0; border-radius: 999px; background: var(--field); box-shadow: inset 0 0 0 1px var(--line); color: var(--muted); font: 500 12px var(--font-sans); cursor: pointer; white-space: nowrap; }
.chips button:hover { color: var(--ink); }
.chips button[aria-pressed="true"] { background: var(--active); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2); }
.chips button:focus-visible, .dr .seg button:focus-visible, .dr .icon-btn:focus-visible { outline: 2px solid var(--acc); outline-offset: 1px; }
.dr .icon-btn { width: 36px; height: 36px; }
.dr .rows .row { min-height: 0; }
.cost-row.br { width: 100%; border-left: 0; border-right: 0; border-bottom: 0; background: none; font: inherit; color: inherit; text-align: left; }
.cost-row.br[aria-current="true"] .t { font-weight: 500; color: var(--ink); }
.cost-row.br[aria-current="true"]::before { content: ""; flex: none; width: 3px; align-self: stretch; margin: -2px 0 -2px -10px; border-radius: 2px; background: var(--c-accent); }
.dr .cost-row .cn { width: 72px; }
.dr .cost-row.exp .cn { width: 84px; }
.dr .cxc.sp.mini { width: 96px; height: 34px; padding-top: 0; margin: 0; }
.dr .spark.lbl { width: 96px; justify-content: center; font-size: 12px; color: var(--faint); }
.dr .nums b { font-size: 22px; line-height: 28px; }

@media (max-width: 1180px) {
  .dnrow { grid-template-columns: minmax(0, 1fr); }
  .dwrap { grid-template-columns: 132px minmax(0, 1fr); }
  .cxc.dn { width: 132px; height: 132px; }
}
@media (max-width: 960px) {
  .cost .main, .cost .aside { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  main:has(> .sh-body.cost) { padding: 16px 16px 20px; }
  .cost > .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 8px; }
  .cost button.kpi:nth-child(odd) { border-left: 0; }
  .cost button.kpi:nth-child(even) { border-left: 1px solid var(--line); }
  .cost .kpi { padding: 6px 12px; }
  .cost .kpi .val { font-size: 24px; line-height: 30px; }
  .sh-head.inline .act .seg { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); width: 100%; overflow: visible; }
  .sh-head.inline .act .seg button { padding: 0 4px; font-size: 12px; }
  .dwrap { grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 14px; }
  .dwrap .dleg { width: 100%; justify-self: stretch; }
  .cxc.dn { width: 172px; height: 172px; }
  .dpan .sect { flex-wrap: wrap; }
  .dr { inset: 0; width: auto; border-radius: 0; }
  .dr-head { padding: 18px 12px 12px 18px; }
  .dr-body { padding: 4px 18px 28px; }
  .dr .cost-row .cn, .dr .cost-row.exp .cn { width: 64px; font-size: 13px; }
  .dr .cost-row.v .cxc { display: none; }
  .dr .cost-row.v .spark.lbl { display: none; }
  .legend .lg-note { margin-left: 0; flex-basis: 100%; }
}
@media (prefers-reduced-motion: reduce) { .dr.enter, .dr-scrim.enter { animation: none; } .h2b svg { transition: none; } }
@media (max-width: 1100px) {
  .sh-head.inline .ttl, .sh-head.inline .act { grid-column: 1 / -1; }
  .sh-head.inline .act { justify-content: flex-start; margin-top: 12px; }
  .sh-head.inline .act .seg { max-width: 100%; overflow-x: auto; }
}

/* Upkeep section on Archy's agent page: lists sit in drawers (details), closed unless something needs a look. */
.updr { border-top: 1px solid var(--line); padding: 4px 0; }
.updr > summary { display: flex; align-items: center; gap: 8px; padding: 10px 0; font: 500 14px/20px var(--font-sans); color: var(--ink); cursor: pointer; list-style: none; }
.updr > summary::-webkit-details-marker { display: none; }
.updr > summary::before { content: ''; width: 7px; height: 7px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(-45deg); transition: transform .15s; }
.updr[open] > summary::before { transform: rotate(45deg); }
.updr > summary em { font-style: normal; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
.xpost { padding: 10px 0; border-top: 1px solid var(--line); }
.xpost:first-child { border-top: 0; }
.xpost .wrapt { white-space: normal; overflow-wrap: anywhere; }
@media (prefers-reduced-motion: reduce) { .updr > summary::before { transition: none; } }

/* Gate E scorecard: one row per measure, status and numbers in a grid; lists in drawers like the Upkeep section. */
.gt { display: grid; }
.gt-row { display: grid; grid-template-columns: 100px minmax(0, 1.5fr) 112px 160px 76px 104px minmax(0, 1fr); align-items: center; column-gap: 14px; padding: 7px 0; border-top: 1px solid var(--line); }
.gt-row .st { min-width: 0; }
.gt-h { padding: 8px 0; border-top: 0; font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.gt-name { min-width: 0; }
.gt-name .t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gt-note { margin: 10px 0 0; }
.gt-name .s { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gt-bar { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.gt-val { font-size: 15px; font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gt-mar { font-size: 13px; font-variant-numeric: tabular-nums; color: var(--muted); }
.gt-mar.red { color: var(--s-danger); }
.gt-sp .cxc.sp.mini { width: 96px; height: 34px; padding-top: 0; margin: 0; }
.gt-first { font-size: 12px; color: var(--faint); }
.gt-src { min-width: 0; display: grid; font-size: 13px; line-height: 18px; color: var(--muted); }
.gt-src small { font-size: 12px; color: var(--faint); }
.gt-run { font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
@media (max-width: 1180px) {
  .gt-h { display: none; }
  .gt-row { grid-template-columns: 96px minmax(0, 1fr) auto; row-gap: 4px; }
  .gt-bar, .gt-mar, .gt-sp, .gt-src { grid-column: 2 / -1; }
}
.bugsp { display: flex; flex-direction: column; }
.bugsp .bfoot { margin-top: auto; padding-top: 10px; }
