

/*
 * Two themes (3 Dec 2026): Daylight, the default ("A in Daylight"), and Dark, the admin's
 * earlier palette. tt_theme picks one (lib/theme.ts); the root layout puts it on <html> as
 * data-theme. The @theme block below is Daylight; :root[data-theme="dark"] overrides the
 * same tokens, so every utility and rule follows without knowing which theme it is in.
 *
 * Values and names match the affiliate portal's (apps/portal/app/globals.css). Blue is money,
 * focus and the one main button. Three meaning colors carry state, always with their word:
 * ok (on goal, ready, paid), wait (below goal, waiting, clearing), warn (needs you, look,
 * held). The word uses the plain token, which clears 4.5:1 on every ground up to surface-3;
 * dots and bars use the -dot shade. Admin density is tables and facts lines, not stat cards.
 */
:root {
  --color-ground: #F2F4F7;
  --color-surface: #FFFFFF;
  --color-surface-2: #EEF1F5;
  --color-surface-3: #E3E7EC;
  --color-line: #E1E4E9;
  --color-fg: #12151A;
  --color-fg-2: #4A515C;
  --color-fg-3: #5C6470;
  --color-accent: #2F5BDB;
  --color-accent-fill: #3761E0;
  --color-ok: #18734B;
  --color-ok-dot: #1F8A5B;
  --color-wait: #925600;
  --color-wait-dot: #B26A00;
  --color-warn: #BA3328;
  --color-warn-dot: #D33A2C;
  --color-wash-money: #EAF0FF;
  --color-wash-ok: #E4F3EA;
  --color-wash-wait: #FFF3DC;
  --color-wash-warn: #FDECEA;
  /* Text and icons on an fg fill (the selected chip, the toast, tooltips). */
  --color-ink: #FFFFFF;
  /* The dimmer behind a panel. */
  --color-scrim: rgba(18, 21, 26, .32);
  --color-paper: #F6F1E7;
  --color-mark-neutral: #3A4452;

  --font-display: "Big Shoulders Display", "Archivo Narrow", "Arial Narrow", Impact, sans-serif;
  --font-sans: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;

  --radius-mark: 5px;
  --radius-chip: 8px;
  --radius-control: 9px;
  --radius-input: 10px;
  --radius-tile: 12px;
  --radius-card: 16px;

  --shadow-ambient: 0 1px 2px rgba(18, 21, 26, .05), 0 6px 20px rgba(18, 21, 26, .06);
  --shadow-lift: 0 2px 6px rgba(18, 21, 26, .08), 0 12px 32px rgba(18, 21, 26, .12);
  --shadow-panel: -12px 0 40px rgba(18, 21, 26, .14);
  --ease-out: cubic-bezier(.2, .8, .2, 1);
}

:root { color-scheme: light; }

/* Dark: the admin's palette before Daylight, with the same three meaning colors lifted for a dark ground. */
:root[data-theme="dark"] {
  color-scheme: dark;
  --color-ground: #0F1114;
  --color-surface: #171A1F;
  --color-surface-2: #1F242B;
  --color-surface-3: #272D36;
  --color-line: #2A3039;
  --color-fg: #ECECEA;
  --color-fg-2: #A6ABB3;
  --color-fg-3: #8E949E;
  /* Lighter than the old #4D7CFF, which measured 4.2:1 as text on surface-2. */
  --color-accent: #6F94FF;
  --color-accent-fill: #3761E0;
  --color-ok: #4CC38A;
  --color-ok-dot: #3FAF7A;
  --color-wait: #E8A23B;
  --color-wait-dot: #D99A2B;
  --color-warn: #FF6B57;
  --color-warn-dot: #FF6B57;
  --color-wash-money: #1B2540;
  --color-wash-ok: #142A20;
  --color-wash-wait: #2E2410;
  --color-wash-warn: #33191A;
  --color-ink: #111111;
  --color-scrim: rgba(0, 0, 0, .55);
  --shadow-ambient: 0 8px 24px rgba(0, 0, 0, .45);
  --shadow-lift: 0 20px 40px rgba(0, 0, 0, .45);
  --shadow-panel: -12px 0 40px rgba(0, 0, 0, .5);
}

html, body {
  background: var(--color-ground);
  color: var(--color-fg);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--color-accent); color: #fff; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; border-radius: 8px; }

/* Display tier: compressed caps for headings and big figures only. */
.display { font-family: var(--font-display); font-weight: 700; text-transform: uppercase; letter-spacing: .03em; line-height: 1; }
.poster  { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; letter-spacing: .01em; line-height: .95; }

/* Money and durations count; counts do not (Tabular Money Rule). */
.tabular { font-variant-numeric: tabular-nums lining-nums; }

/* Label tier: 11px caps grotesk. */
.label { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); }
.state { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

/* The hairline is the only border. */
.hairline-t { border-top: 1px solid var(--color-line); }
.hairline-b { border-bottom: 1px solid var(--color-line); }
.hairline-r { border-right: 1px solid var(--color-line); }
.dashed { border: 1px dashed var(--color-line); }

/* Dense tables: hairline rows, no zebra, right-aligned figures. */
table.dense { width: 100%; border-collapse: collapse; }
table.dense th { text-align: left; padding: 8px 10px; font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); border-bottom: 1px solid var(--color-line); white-space: nowrap; }
table.dense td { padding: 9px 10px; border-bottom: 1px solid var(--color-line); vertical-align: middle; }
table.dense tr:last-child td { border-bottom: 0; }
table.dense td.num, table.dense th.num { text-align: right; font-variant-numeric: tabular-nums lining-nums; }
table.dense tr.row-link { cursor: pointer; }
table.dense tr.row-link:hover td { background: var(--color-surface-2); }

/* Controls */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: var(--radius-tile); font-weight: 600; font-size: 13.5px; transition: transform 150ms var(--ease-out), background 150ms var(--ease-out), filter 150ms; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--color-accent-fill); color: #fff; }
.btn-primary:hover { filter: brightness(.94); }
.btn-ghost { background: var(--color-surface); color: var(--color-fg); box-shadow: inset 0 0 0 1px var(--color-line); }
.btn-ghost:hover { background: var(--color-surface-2); }
.btn-quiet { display: inline-flex; align-items: center; min-height: 28px; background: transparent; color: var(--color-fg-2); text-decoration: underline; text-underline-offset: 3px; padding: 0 4px; }
.btn-quiet:hover { color: var(--color-fg); }
.btn-danger { background: var(--color-surface); color: var(--color-warn); box-shadow: inset 0 0 0 1px var(--color-line); }
.btn-danger:hover { background: var(--color-surface-2); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.input, .select, .textarea { width: 100%; background: var(--color-surface); color: var(--color-fg); border: 0; border-radius: var(--radius-input); padding: 9px 12px; font: inherit; box-shadow: inset 0 0 0 1px var(--color-line); }
.input:focus, .select:focus, .textarea:focus { box-shadow: inset 0 0 0 1px var(--color-accent); outline: none; }
.textarea { min-height: 72px; resize: vertical; line-height: 1.45; }
.select { appearance: none; }

.pill { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; background: var(--color-surface-2); color: var(--color-fg-2); font-size: 12px; font-weight: 600; white-space: nowrap; }
.pill-ok { background: var(--color-surface-3); color: var(--color-fg); }
.pill-warn { color: var(--color-warn); }
.chip { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: var(--radius-chip); background: var(--color-surface-3); color: var(--color-fg-2); font-size: 12.5px; font-weight: 600; }
.chip-on { background: var(--color-fg); color: var(--color-ink); }

.card { background: var(--color-surface); border-radius: var(--radius-card); }
.card-2 { background: var(--color-surface-2); border-radius: var(--radius-tile); }

.mark { display: inline-flex; align-items: center; justify-content: center; border-radius: var(--radius-mark); color: #fff; font-family: var(--font-display); font-weight: 700; line-height: 1; text-transform: lowercase; flex: none; }

/* Nav rail */
.nav-item { display: flex; align-items: center; gap: 10px; height: 38px; padding: 0 12px; border-radius: var(--radius-input); color: var(--color-fg-2); font-weight: 600; font-size: 13.5px; }
.nav-item:hover { background: var(--color-surface); color: var(--color-fg); }
.nav-item[aria-current="page"] { background: var(--color-surface); color: var(--color-accent); }
.nav-count { margin-left: auto; height: 17px; min-width: 17px; padding: 0 5px; border-radius: 999px; background: var(--color-surface-3); color: var(--color-fg); font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }

/* Right panel (the sheet at a desk) */
.panel { position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100vw); background: var(--color-surface-2); box-shadow: var(--shadow-panel); overflow-y: auto; z-index: 30; animation: panel-in 380ms var(--ease-out); }
.scrim { position: fixed; inset: 0; background: var(--color-scrim); z-index: 20; animation: fade-in 250ms var(--ease-out); }
@keyframes panel-in { from { transform: translateX(24px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

.why { font-size: 12.5px; color: var(--color-fg-3); line-height: 1.45; }

.mono { font-family: var(--font-mono); font-size: 12px; word-break: break-all; }
.empty { border: 1px dashed var(--color-line); border-radius: var(--radius-tile); padding: 16px; color: var(--color-fg-2); font-size: 13.5px; line-height: 1.45; }

.scroll-thin { scrollbar-width: thin; scrollbar-color: var(--color-surface-3) transparent; }

/*
 * Publisher admin (<slug>.tellatribe.com; prototype design/bll/admin.html).
 * Same tokens as the staff admin; a wider rail that carries the publisher's
 * own mark and address, and the Users & roles table and role matrix.
 */
.ico { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.pub-app { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; }
.pub-rail { position: sticky; top: 0; height: 100vh; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--color-surface-3) transparent; padding: 20px 14px; border-right: 1px solid var(--color-line); display: flex; flex-direction: column; gap: 18px; }
.pub-id { display: flex; align-items: center; gap: 10px; padding: 6px 8px 14px; border-bottom: 1px solid var(--color-line); min-width: 0; }
.pub-id b { display: block; font-size: 13.5px; font-weight: 600; line-height: 1.2; }
.pub-id small { display: block; font-size: 12px; color: var(--color-fg-3); }
.pub-nav { display: flex; flex-direction: column; gap: 14px; }
.pub-navgroup { display: flex; flex-direction: column; gap: 1px; }
.pub-navh { font-size: 12px; font-weight: 600; color: var(--color-fg-3); padding: 0 12px 4px; }
.pub-nav a { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 12px; border-radius: var(--radius-input); color: var(--color-fg-2); font-weight: 600; font-size: 13.5px; transition: background 150ms var(--ease-out), color 150ms var(--ease-out); }
.pub-nav a:hover { background: var(--color-surface); color: var(--color-fg); }
.pub-nav a[aria-current="page"] { background: var(--color-surface); color: var(--color-accent); }
.pub-nav .count { margin-left: auto; font-size: 11px; font-weight: 700; color: var(--color-fg-3); font-variant-numeric: lining-nums; }
.pub-nav a[aria-current="page"] .count { color: var(--color-fg-2); }
.pub-nav .pill-beta { height: 18px; padding: 0 7px; font-size: 10.5px; letter-spacing: .02em; }
.pub-railfoot { margin-top: auto; font-size: 12px; color: var(--color-fg-3); line-height: 1.5; padding: 0 8px; min-width: 0; }
.wordmark { font-family: var(--font-display); font-weight: 700; font-size: 20px; letter-spacing: .03em; text-transform: uppercase; color: var(--color-fg-2); }
.pub-menu { display: none; }
.pub-main { padding: 26px 36px 64px; max-width: 1500px; width: 100%; min-width: 0; }

.pub-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 6px; flex-wrap: wrap; }
.pub-h1 { font-family: var(--font-display); font-weight: 700; font-size: 34px; letter-spacing: .03em; text-transform: uppercase; margin: 0; line-height: 1; }
.pub-sub { color: var(--color-fg-3); font-size: 13px; font-weight: 600; margin: 4px 0 0; }
.pub-lead { color: var(--color-fg-2); font-size: 14.5px; margin: 6px 0 22px; max-width: 70ch; line-height: 1.5; }
.pub-tabs { display: flex; gap: 6px; margin-bottom: 12px; flex-wrap: wrap; }
.pub-foot { margin-top: 40px; font-size: 12px; color: var(--color-fg-3); line-height: 1.6; max-width: 90ch; }
.host-pill { display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 12px; border-radius: 999px; background: var(--color-surface); font-size: 13px; color: var(--color-fg-2); }
.host-pill b { color: var(--color-fg); font-weight: 600; }

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label { font-size: 13px; font-weight: 600; color: var(--color-fg); }
.invite .hint { grid-column: 1 / -1; margin: 0; }
.field .err, .invite .err { font-size: 12.5px; color: var(--color-warn); font-weight: 600; }
.in { width: 100%; background: var(--color-surface-2); color: var(--color-fg); border: 0; border-radius: var(--radius-input); padding: 10px 12px; font: inherit; font-size: 14px; box-shadow: inset 0 0 0 1px var(--color-line); caret-color: var(--color-accent); }
.in:focus { outline: none; box-shadow: inset 0 0 0 1.5px var(--color-accent); }
.sel { appearance: none; background: var(--color-surface-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%234A515C' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center; color: var(--color-fg); border: 0; border-radius: var(--radius-control); padding: 7px 30px 7px 10px; font: inherit; font-size: 13px; box-shadow: inset 0 0 0 1px var(--color-line); }
:root[data-theme="dark"] .sel { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23A6ABB3' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); }
.sel:focus { outline: none; box-shadow: inset 0 0 0 1.5px var(--color-accent); }
.sel:disabled { opacity: .75; cursor: not-allowed; }

.invite { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) 200px auto; gap: 10px; align-items: end; background: var(--color-surface); border-radius: var(--radius-card); padding: 16px; margin-bottom: 14px; }
.tablewrap { background: var(--color-surface); border-radius: var(--radius-card); overflow-x: auto; }
.utable { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.utable th { text-align: left; font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); padding: 10px 12px; border-bottom: 1px solid var(--color-line); white-space: nowrap; }
.utable td { padding: 10px 12px; border-bottom: 1px solid var(--color-line); vertical-align: middle; }
.utable tr:last-child td { border-bottom: 0; }
.who2 { display: flex; align-items: center; gap: 10px; min-width: 0; }
.who2 b { display: block; font-weight: 600; }
.who2 span.addr { display: block; font-size: 12.5px; color: var(--color-fg-3); overflow-wrap: anywhere; }
.av { width: 32px; height: 32px; border-radius: 50%; background: var(--color-surface-3); display: grid; place-items: center; font-size: 12px; font-weight: 700; color: var(--color-fg-2); flex: none; }

.rmatrix { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 760px; }
.rmatrix th, .rmatrix td { padding: 10px 12px; border-bottom: 1px solid var(--color-line); text-align: center; }
.rmatrix th:first-child, .rmatrix td:first-child { text-align: left; position: sticky; left: 0; background: var(--color-surface); z-index: 1; }
.rmatrix thead th { font-size: 12.5px; font-weight: 700; vertical-align: bottom; }
.rmatrix thead th .holders { display: block; font-size: 11.5px; font-weight: 500; color: var(--color-fg-3); margin-top: 2px; }
.rmatrix td .pdesc { display: block; font-size: 12px; color: var(--color-fg-3); margin-top: 2px; }
.rmatrix tr:last-child td { border-bottom: 0; }
.rmatrix input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--color-accent); }
.rmatrix .yes { color: var(--color-fg); display: inline-block; }
.rmatrix .no { color: var(--color-surface-3); }
.rmatrix th.custom { background: var(--color-surface-2); }
.rmatrix td.custom { background: var(--color-surface-2); }

.toast { position: fixed; right: 28px; bottom: 28px; background: var(--color-fg); color: var(--color-ink); padding: 10px 14px; border-radius: var(--radius-tile); font-weight: 600; font-size: 13.5px; box-shadow: var(--shadow-ambient); z-index: 40; animation: toast-in 300ms var(--ease-out); max-width: min(480px, calc(100vw - 32px)); }
.toast-warn { background: var(--color-surface-3); color: var(--color-warn); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ── View as (0047): the switcher, the banner every switched view carries, the affiliate view ── */
.viewbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: -10px 0 18px; min-height: 36px; }
.viewbar.on { position: sticky; top: 0; z-index: 9; margin: 0 -36px 20px; padding: 10px 36px; background: color-mix(in srgb, var(--color-accent) 14%, var(--color-ground)); border-bottom: 1px solid color-mix(in srgb, var(--color-accent) 45%, var(--color-line)); }
.pub-main > .viewbar.on:first-child { margin-top: -26px; }
.viewing { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13.5px; color: var(--color-fg-2); min-width: 0; }
.viewing b { color: var(--color-fg); font-weight: 600; }
.viewing-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--color-accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--color-accent) 30%, transparent); flex: none; }
.viewing-back { color: var(--color-fg); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; padding: 6px 2px; }
.viewing-back:hover { color: var(--color-accent); }
.viewing-note, .viewing-scope { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--color-fg-3); }
.viewing-note { margin-left: 4px; }
.viewing-err { margin: 0 0 14px; padding: 10px 14px; border-radius: var(--radius-tile); background: var(--color-surface); color: var(--color-warn); font-size: 13.5px; font-weight: 600; }
.viewing-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 40; margin: 0; padding: 10px 16px; border-radius: var(--radius-tile); background: var(--color-surface-3); color: var(--color-fg); font-size: 13.5px; font-weight: 600; box-shadow: var(--shadow-ambient); animation: viewing-toast 3.2s var(--ease-out) forwards; }
@keyframes viewing-toast { 0% { opacity: 0; translate: 0 6px; } 8%, 85% { opacity: 1; translate: 0 0; } 100% { opacity: 0; } }
.in-view [data-preview-off] { cursor: not-allowed; }
.modeswitch { display: inline-flex; align-items: center; gap: 2px; height: 36px; padding: 3px; border-radius: 999px; background: var(--color-surface-2); }
.modeswitch > * { display: inline-flex; align-items: center; height: 30px; padding: 0 14px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--color-fg-3); text-decoration: none; }
.modeswitch > [aria-current] { background: var(--color-surface-3); color: var(--color-fg); }
.modeswitch > a:hover { color: var(--color-fg); }
.modeswitch > a:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 1px; }
.viewas { position: relative; margin-left: auto; }
.viewas summary { list-style: none; cursor: pointer; gap: 6px; }
.viewas summary::-webkit-details-marker { display: none; }
.viewas[open] summary { background: var(--color-surface-3); }
.viewas-panel { position: absolute; right: 0; top: 42px; z-index: 20; width: min(360px, calc(100vw - 32px)); max-height: calc(100vh - 120px); overflow-y: auto; background: var(--color-surface-2); border-radius: var(--radius-card); padding: 6px; box-shadow: var(--shadow-ambient); }
.viewas-group { margin: 8px 12px 2px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--color-fg-3); }
.viewas-panel ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.viewas-opt { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; text-align: left; padding: 9px 12px; border-radius: var(--radius-input); color: var(--color-fg); }
.viewas-opt b { font-size: 13.5px; font-weight: 600; }
.viewas-opt small { font-size: 12px; color: var(--color-fg-3); line-height: 1.4; }
.viewas-opt:hover:not([disabled]) { background: var(--color-surface-3); }
.viewas-opt[aria-current="true"] b { color: var(--color-accent); }
.viewas-opt[disabled] { opacity: .5; cursor: not-allowed; }

.aview { display: grid; grid-template-columns: minmax(280px, 380px) minmax(0, 1fr); gap: 36px; align-items: start; }
.aview-search { display: flex; gap: 8px; margin-bottom: 12px; }
.aview-list { list-style: none; margin: 0; padding: 4px; background: var(--color-surface); border-radius: var(--radius-card); max-height: 560px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--color-surface-3) transparent; }
.aview-list a { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 12px; border-radius: var(--radius-input); min-width: 0; }
.aview-list a:hover { background: var(--color-surface-2); }
.aview-list a[aria-current="true"] { background: var(--color-surface-3); box-shadow: inset 2px 0 0 var(--color-accent); }
.aview-list b { display: block; font-size: 13.5px; font-weight: 600; }
.aview-list small { display: block; font-size: 12px; color: var(--color-fg-3); }
.aview-amt { flex: none; font-size: 13px; color: var(--color-fg-2); }
.aview-stage { display: flex; flex-direction: column; align-items: center; position: sticky; top: 76px; }
.phone { position: relative; width: 390px; height: min(844px, calc(100vh - 150px)); min-height: 560px; padding: 40px 12px 14px; border-radius: 54px; background: #050607; box-shadow: 0 0 0 1px var(--color-line), 0 0 0 8px var(--color-surface), var(--shadow-lift); }
.phone iframe { display: block; width: 100%; height: 100%; border: 0; border-radius: 10px 10px 40px 40px; background: var(--color-ground); }
.phone-notch { position: absolute; top: 13px; left: 50%; width: 96px; height: 16px; transform: translateX(-50%); border-radius: 999px; background: #050607; z-index: 1; pointer-events: none; }
@media (max-width: 1080px) {
  .aview { grid-template-columns: 1fr; }
  .aview-stage { position: static; }
}

@media (max-width: 760px) {
  .pub-app { grid-template-columns: 1fr; }
  .pub-rail { position: sticky; top: 0; z-index: 10; height: auto; flex-direction: row; align-items: center; justify-content: space-between; padding: 10px 16px; background: var(--color-ground); border-right: 0; border-bottom: 1px solid var(--color-line); gap: 12px; overflow: visible; }
  .pub-id { border: 0; padding: 0; }
  .pub-id small, .pub-desk-nav, .pub-railfoot { display: none; }
  .pub-menu { display: block; position: relative; }
  .pub-menu summary { list-style: none; cursor: pointer; }
  .pub-menu summary::-webkit-details-marker { display: none; }
  .pub-menu-panel { position: absolute; right: 0; top: 44px; width: min(280px, calc(100vw - 32px)); max-height: calc(100vh - 72px); overflow-y: auto; background: var(--color-surface); border-radius: var(--radius-card); padding: 8px; box-shadow: var(--shadow-ambient); }
  .pub-main { padding: 18px max(16px, env(safe-area-inset-right, 0px)) 56px max(16px, env(safe-area-inset-left, 0px)); }
  .viewbar { margin: 0 0 14px; }
  .viewbar.on { top: 57px; margin: 0 -16px 16px; padding: 8px 16px; }
  .pub-main > .viewbar.on:first-child { margin-top: -18px; }
  .viewing-note { display: none; }
  .phone { width: 100%; height: 78vh; min-height: 0; padding: 0; border-radius: var(--radius-card); background: none; box-shadow: 0 0 0 1px var(--color-line); }
  .phone iframe { border-radius: var(--radius-card); }
  .phone-notch { display: none; }
  .pub-top { flex-direction: column; align-items: flex-start; gap: 10px; }
  .pub-h1 { font-size: 30px; }
  .invite { grid-template-columns: 1fr; }
  .utable thead { display: none; }
  .utable, .utable tbody, .utable tr, .utable td { display: block; width: 100%; }
  .utable tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px 10px; padding: 12px 14px; border-bottom: 1px solid var(--color-line); }
  .utable tr:last-child { border-bottom: 0; }
  .utable td { border: 0; padding: 0; width: auto; }
  .utable td:nth-child(1) { grid-column: 1 / -1; }
  .utable td:nth-child(2) { grid-column: 1; grid-row: 2; }
  .utable td.act { grid-column: 2; grid-row: 2; }
  .utable td:nth-child(3), .utable td:nth-child(4) { grid-row: 3; font-size: 12.5px; }
  .utable td:nth-child(4) { text-align: right; }
  .utable td:nth-child(3) .state { font-size: 10.5px; }
  .toast { left: 16px; right: 16px; bottom: 16px; }
}


/*
 * Publisher desk screens (W5: Brief, First 90 days, Top 10, Affiliates,
 * Approvals, Teams, Orders, Buyers, Sync health, Settings), ported from the
 * prototype design/bll/admin.html and scoped under .desk so nothing here
 * reaches the staff admin or Users & roles.
 */
.desk .money { color: var(--color-accent); }
.desk .warn { color: var(--color-warn); }
.desk .f2 { color: var(--color-fg-2); }
.desk .f3 { color: var(--color-fg-3); }
.desk .num { font-variant-numeric: lining-nums; }
.desk .tab { font-variant-numeric: tabular-nums lining-nums; }
.desk .top { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 22px; flex-wrap: wrap; }
.desk .date { font-family: var(--font-display); font-weight: 700; font-size: 26px; letter-spacing: .03em; text-transform: uppercase; line-height: 1; }
.desk .seg { display: inline-flex; background: var(--color-surface); border-radius: 11px; padding: 3px; }
.desk .seg a { height: 32px; padding: 0 14px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--color-fg-2); display: inline-flex; align-items: center; transition: background 200ms var(--ease-out), color 200ms var(--ease-out); }
.desk .seg a[aria-current="true"] { background: var(--color-surface-3); color: var(--color-fg); }
.desk .facts { display: flex; gap: 22px; flex-wrap: wrap; font-size: 13px; color: var(--color-fg-2); }
.desk .facts b { color: var(--color-fg); font-weight: 600; }
.desk .grid2 { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 40px; align-items: start; }
.desk .headline { font-family: var(--font-display); font-weight: 700; font-size: 46px; line-height: .98; letter-spacing: .005em; text-transform: uppercase; text-wrap: balance; margin: 0; max-width: 20ch; }
.desk .headline .money { font-weight: 800; }
.desk .today { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin: 16px 0 0; font-size: 17px; color: var(--color-fg-2); }
.desk .today .lbl { font-family: var(--font-display); font-weight: 700; font-size: 15px; letter-spacing: .04em; text-transform: uppercase; color: var(--color-fg); }
.desk .today .money { font-weight: 700; }
.desk .sub { font-size: 15px; color: var(--color-fg-2); margin: 14px 0 0; max-width: 62ch; line-height: 1.5; }
.desk .sub .num { color: var(--color-fg); }
.desk h2.sec { font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: .03em; text-transform: uppercase; margin: 0; line-height: 1; }
.desk .sechead { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin: 40px 0 12px; flex-wrap: wrap; }
.desk .sechead .f3 { font-size: 12.5px; }
.desk .moves { list-style: none; margin: 0; padding: 0; background: var(--color-surface); border-radius: var(--radius-card); overflow: hidden; }
.desk .move { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 15px 16px 15px 14px; border-top: 1px solid var(--color-line); }
.desk .move:first-child { border-top: 0; }
.desk .move .ic { width: 30px; height: 30px; border-radius: 9px; background: var(--color-surface-2); display: grid; place-items: center; color: var(--color-fg-2); }
.desk .move p { margin: 0; }
.desk .move .what { font-size: 14.5px; font-weight: 600; line-height: 1.35; }
.desk .move .why { font-size: 13px; color: var(--color-fg-3); margin-top: 3px; line-height: 1.45; }
.desk .move .who { color: var(--color-fg-2); }
.desk .side { position: sticky; top: 20px; display: flex; flex-direction: column; gap: 14px; }
.desk .board { background: var(--color-surface); border-radius: var(--radius-card); padding: 16px 6px 8px; }
.desk .board header { display: flex; align-items: center; justify-content: space-between; padding: 0 10px 10px; }
.desk .board ol { list-style: none; margin: 0; padding: 0; }
.desk .board .lrow { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 10px; align-items: center; width: 100%; padding: 8px 10px; border-radius: 10px; transition: background 150ms var(--ease-out); }
.desk .board a.lrow:hover { background: var(--color-surface-2); }
.desk .rk { font-family: var(--font-display); font-weight: 700; font-size: 18px; color: var(--color-fg-3); text-align: right; }
.desk .board .nm { display: block; font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.desk .board .meta { display: block; font-size: 12px; color: var(--color-fg-3); }
.desk .board .amt { text-align: right; font-size: 13.5px; }
/* "See the full list" under the Top 10 (Dec 1, 2026): opens /leaderboard for the same period. */
.desk .board .board-all { display: flex; align-items: center; justify-content: center; min-height: 44px; margin: 6px 4px 2px; border-radius: 10px; font-size: 13.5px; font-weight: 600; color: var(--color-fg); text-decoration: none; background: var(--color-surface-2); transition: background 150ms var(--ease-out); }
.desk .board .board-all:hover { background: var(--color-surface-3); }

/* The full Top 10 (/leaderboard). Header cells are sort buttons; on a phone a Sort select stands in for them. */
.desk .lb-q { flex: 1 1 260px; max-width: 420px; }
.desk .lb-sortm { display: none; }
.desk .lb-count { font-size: 12.5px; margin-left: auto; }
.desk .lb-th { all: unset; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; font: inherit; color: inherit; letter-spacing: inherit; text-transform: inherit; }
.desk .lb-th:hover, .desk .lb-th.on { color: var(--color-fg); }
.desk .lb-th:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; border-radius: 4px; }
.desk .lb-arrow { display: inline-block; min-width: 9px; }
.desk .lb-th2 { display: inline-flex; gap: 14px; }
.desk .lb-th2 .lb-th:first-child { min-width: 12px; }
.desk .lb-table td { white-space: nowrap; }
.desk .lb-table td:first-child { white-space: normal; min-width: 220px; }
.desk .lb-rank { display: inline-block; min-width: 26px; color: var(--color-fg-3); font-family: var(--font-display); font-size: 16px; }
.desk .lb-name { font-weight: 600; color: var(--color-fg); text-decoration: none; }
.desk a.lb-name:hover { text-decoration: underline; text-underline-offset: 3px; }
.desk .lb-meta { display: block; margin-left: 26px; font-size: 12px; color: var(--color-fg-3); }
.desk .lb-share { display: block; font-size: 11.5px; color: var(--color-fg-3); }
@media (max-width: 760px) {
  .desk .lb-sortm { display: block; flex: 1 1 160px; }
  .desk .lb-q { max-width: none; }
  .desk .lb-count { margin-left: 0; }
  .desk .lb-table td:first-child { min-width: 0; }
  .desk .lb-table td.lb-e { grid-column: 1 / -1; display: flex; justify-content: space-between; }
}
.desk .board .amt small { display: block; font-size: 11.5px; color: var(--color-fg-3); }
.desk .share { padding: 12px 16px 4px; border-top: 1px solid var(--color-line); margin: 8px 10px 0; font-size: 12.5px; color: var(--color-fg-2); line-height: 1.5; }
.desk .bar { display: flex; height: 6px; border-radius: 3px; overflow: hidden; background: var(--color-surface-3); margin: 8px 0 6px; }
.desk .bar i { display: block; height: 100%; }
.desk .note { font-size: 12px; color: var(--color-fg-3); line-height: 1.5; padding: 0 4px; }
.desk .bands { display: flex; flex-direction: column; gap: 22px; }
.desk .band { background: var(--color-surface); border-radius: var(--radius-card); padding: 16px 16px 6px; }
.desk .bandhead { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: end; margin-bottom: 6px; }
.desk .bandhead h3 { font-family: var(--font-display); font-weight: 700; font-size: 20px; letter-spacing: .03em; text-transform: uppercase; margin: 0; line-height: 1; }
.desk .bandfacts { display: flex; gap: 18px; font-size: 12.5px; color: var(--color-fg-2); flex-wrap: wrap; justify-content: flex-end; }
.desk .bandfacts b { color: var(--color-fg); font-weight: 600; }
.desk .bandsum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.desk .bandsum a { background: var(--color-surface); border-radius: var(--radius-tile); padding: 14px; display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--color-fg-2); transition: background 150ms var(--ease-out); }
.desk .bandsum a:hover { background: var(--color-surface-2); }
.desk .bandsum b { color: var(--color-fg); font-weight: 600; }
.desk .bandsum .t { font-family: var(--font-display); font-weight: 700; font-size: 17px; letter-spacing: .03em; text-transform: uppercase; color: var(--color-fg); }
.desk .cols, .desk .rrow { display: grid; grid-template-columns: minmax(150px, 1.1fr) minmax(200px, 2.2fr) 150px 64px 110px; gap: 14px; align-items: center; }
.desk .cols { padding: 10px 8px 6px; border-bottom: 1px solid var(--color-line); }
.desk .cols span { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); }
.desk .cols .r, .desk .rrow .r { text-align: right; }
.desk .rrow { width: 100%; text-align: left; padding: 9px 8px; border-bottom: 1px solid var(--color-line); transition: background 150ms var(--ease-out); }
.desk a.rrow:hover { background: var(--color-surface-2); }
.desk a.rrow.on { background: var(--color-surface-2); box-shadow: inset 0 0 0 2px var(--color-accent); border-radius: 10px; }
.desk .rows > .rrow:last-child { border-bottom: 0; }
.desk .rrow .nm { display: block; font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.desk .rrow .meta { display: block; font-size: 12px; color: var(--color-fg-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.desk .track { position: relative; height: 22px; }
.desk .track .base { position: absolute; left: 0; right: 0; top: 10px; height: 2px; background: var(--color-surface-3); border-radius: 1px; }
.desk .track .lived { position: absolute; left: 0; top: 10px; height: 2px; background: var(--color-fg-3); border-radius: 1px; transform-origin: left center; animation: desk-draw 900ms var(--ease-out) both; }
.desk .track .z { position: absolute; top: 6px; width: 1px; height: 10px; background: var(--color-line); }
.desk .track .o { position: absolute; top: 5px; width: 2px; height: 12px; background: var(--color-accent); border-radius: 1px; transform: translateX(-1px); }
.desk .track .first { position: absolute; top: 5px; width: 12px; height: 12px; margin-left: -6px; transform: rotate(45deg) scale(.82); background: var(--color-accent); border-radius: 2px; }
.desk .track .now { position: absolute; top: 5px; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--color-ground); box-shadow: inset 0 0 0 2px var(--color-fg); }
/* Hovering today's circle says how long since they signed up (Dec 1, 2026). A 28px invisible ring makes it easy to hit. */
.desk .track .now[data-tip]::before { content: ""; position: absolute; inset: -8px; border-radius: 50%; }
.desk .track .now[data-tip]::after { content: attr(data-tip); position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); white-space: nowrap;
  background: var(--color-fg); color: var(--color-ink); font-size: 12px; font-weight: 600; line-height: 1; padding: 6px 8px; border-radius: 6px;
  box-shadow: var(--shadow-ambient); opacity: 0; pointer-events: none; transition: opacity .12s; z-index: 5; }
.desk .track .now[data-tip]:hover::after { opacity: 1; }
@keyframes desk-draw { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.desk .status { font-size: 12.5px; white-space: nowrap; }
.desk .nowrap { white-space: nowrap; }
.desk .more { display: flex; justify-content: space-between; align-items: center; padding: 10px 8px 8px; font-size: 12.5px; color: var(--color-fg-3); }
.desk .more a { display: inline-flex; align-items: center; min-height: 32px; padding: 0 6px; color: var(--color-fg-2); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.desk .legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 12px; color: var(--color-fg-3); align-items: center; margin: -2px 0 14px; }
.desk .legend i { display: inline-block; vertical-align: middle; margin-right: 6px; }
.desk .chips { display: flex; gap: 6px; flex-wrap: wrap; }
.desk .foot { margin-top: 40px; font-size: 12px; color: var(--color-fg-3); line-height: 1.6; max-width: 90ch; }
.desk .pfig { font-family: var(--font-display); font-weight: 800; font-size: 40px; line-height: 1; margin-top: 18px; }
.desk .pfig small { display: block; font-family: var(--font-sans); font-weight: 400; font-size: 13px; color: var(--color-fg-2); margin-top: 6px; text-transform: none; }
.desk dl.kv { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 8px 14px; margin: 0; font-size: 13.5px; }
.desk dl.kv dt { color: var(--color-fg-3); }
.desk dl.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.desk .panelcard { background: var(--color-surface); border-radius: var(--radius-card); padding: 18px; }
.desk .panelcard h2 { font-family: var(--font-display); font-weight: 700; font-size: 20px; letter-spacing: .03em; text-transform: uppercase; margin: 0 0 12px; line-height: 1; }
.desk .two { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.desk .stack { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.desk .flag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px; background: var(--color-surface-2); color: var(--color-warn); font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.desk .flagrow { display: flex; gap: 4px; flex-wrap: wrap; }
/* Social accounts (0057): one .move per network, its buttons together on the right. */
.desk .social .what { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.desk .social .ic { overflow: hidden; }
.desk .social .social-mono { font-size: 11.5px; font-weight: 700; letter-spacing: .02em; }
.desk .social .social-av { width: 30px; height: 30px; object-fit: cover; }
.desk .social .acts { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
/* Email and SMS (0059): the campaign list, the email frame, results, flows, the Omnisend key. */
.desk .mailtabs { margin-top: 8px; }
.desk .mailfilters { display: flex; gap: 10px 22px; flex-wrap: wrap; margin-top: 18px; }
.desk .mailtable td:first-child { max-width: 420px; }
.desk .mailname { display: block; font-weight: 600; font-size: 14px; line-height: 1.35; }
.desk a.mailname:hover { text-decoration: underline; text-underline-offset: 3px; }
.desk .mailsub { display: block; font-size: 12.5px; color: var(--color-fg-2); line-height: 1.4; margin-top: 2px; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.desk .mailmeta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.desk .mailout { display: inline-flex; align-items: center; min-height: 28px; font-size: 12.5px; font-weight: 600; color: var(--color-fg-2); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.desk .mailout:hover { color: var(--color-fg); }
.desk .mailpager { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 12px; }
.desk .mailback { margin: 0 0 10px; font-size: 13px; }
.desk .mailback a { color: var(--color-fg-2); display: inline-flex; min-height: 32px; align-items: center; }
.desk .mailback a:hover { color: var(--color-fg); }
.desk .mailgrid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.desk .mailfacts { background: var(--color-surface); border-radius: var(--radius-card); padding: 16px; }
.desk .mailresults { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.desk .mailstat { background: var(--color-surface); border-radius: var(--radius-tile); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.desk .mailstat .k { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); }
.desk .mailstat b { font-family: var(--font-display); font-weight: 700; font-size: 24px; line-height: 1; }
.desk .mailstat .f3 { font-size: 12px; }
.desk .mailstat-note { grid-column: 1 / -1; }
.desk .mailpiece { margin-top: 8px; }
.desk .mailframe { background: #fff; border-radius: var(--radius-card); overflow: hidden; max-width: 760px; box-shadow: inset 0 0 0 1px var(--color-line); }
.desk .mailframe iframe { display: block; width: 100%; height: min(1100px, 82vh); border: 0; background: #fff; }
.desk .smsbox { display: flex; flex-direction: column; gap: 8px; max-width: 420px; }
.desk .smsbubble { margin: 0; background: var(--color-surface-2); border-radius: 18px 18px 18px 6px; padding: 12px 14px; font-size: 14.5px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.desk .mailsteps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.desk .mailstep details { background: var(--color-surface); border-radius: var(--radius-card); padding: 4px 16px 16px; }
.desk .mailstep summary { display: flex; gap: 12px; align-items: center; cursor: pointer; min-height: 52px; list-style: none; }
.desk .mailstep summary::-webkit-details-marker { display: none; }
.desk .mailstep summary b { display: block; font-size: 14px; font-weight: 600; }
.desk .mailstep-n { width: 28px; height: 28px; border-radius: 50%; background: var(--color-surface-2); display: grid; place-items: center; font-size: 12.5px; font-weight: 700; color: var(--color-fg-2); flex: none; }
.desk .mailstep details[open] summary { margin-bottom: 10px; }
.desk .mailconn { margin-top: 8px; max-width: 760px; }
.desk .mailkey { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 10px; align-items: center; background: var(--color-surface); border-radius: var(--radius-card); padding: 16px; }
.desk .mailkey label { grid-column: 1 / -1; font-size: 13px; font-weight: 600; }
.desk .mailkey-help { grid-column: 1 / -1; line-height: 1.5; }
.desk .flaglist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.desk .flaglist li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: baseline; font-size: 13px; color: var(--color-fg-2); line-height: 1.45; }
.desk .callout { border-radius: var(--radius-tile); background: var(--color-surface-2); padding: 12px 14px; font-size: 13.5px; line-height: 1.5; color: var(--color-fg-2); }
.desk .callout b { color: var(--color-fg); }
.desk .callout.warn-c { box-shadow: inset 3px 0 0 var(--color-warn); }
.desk .pending { border: 1px dashed var(--color-line); border-radius: var(--radius-tile); padding: 10px 12px; font-size: 12.5px; color: var(--color-fg-3); line-height: 1.5; }
.desk .totals { display: flex; gap: 28px; flex-wrap: wrap; align-items: baseline; background: var(--color-surface); border-radius: var(--radius-card); padding: 14px 18px; margin-bottom: 14px; }
.desk .totals .big { font-family: var(--font-display); font-weight: 800; font-size: 30px; line-height: 1; }
.desk .totals .lb { display: block; font-size: 12px; color: var(--color-fg-3); margin-top: 4px; }
.desk .toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.desk .toolbar .in { max-width: 320px; padding: 8px 12px; }
/* Affiliates: the search-or-ask box, the chips showing what it did, and sortable headers (2 Dec 2026). */
.desk .ask { position: relative; display: flex; gap: 8px; align-items: center; margin-bottom: 10px; max-width: 720px; }
.desk .ask .in { padding: 10px 12px 10px 36px; }
.desk .ask .btn { height: 40px; }
.desk .ask-i { position: absolute; left: 11px; top: 50%; width: 16px; height: 16px; transform: translateY(-50%); fill: var(--color-accent); pointer-events: none; }
.desk .qline { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; font-size: 12.5px; }
.desk .qline p { margin: 0; }
.desk .qasked { color: var(--color-fg-3); }
.desk .qasked q { color: var(--color-fg-2); }
.desk .qnote { color: var(--color-fg-2); }
.desk .qchips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.desk .qchip { display: inline-flex; align-items: center; gap: 6px; min-height: 28px; padding: 0 8px 0 10px; border-radius: var(--radius-chip); background: color-mix(in srgb, var(--color-accent) 16%, var(--color-surface-3)); color: var(--color-fg); font-size: 12.5px; font-weight: 600; }
.desk .qchip svg { width: 12px; height: 12px; stroke: currentColor; stroke-width: 1.6; fill: none; opacity: .7; }
.desk .qchip:hover svg { opacity: 1; }
.desk .qclear { display: inline-flex; align-items: center; min-height: 28px; padding: 0 6px; color: var(--color-fg-3); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.desk .utable th .sortby { display: inline-flex; align-items: center; gap: 4px; color: inherit; text-transform: inherit; letter-spacing: inherit; }
.desk .utable th .sortby svg { width: 10px; height: 10px; fill: currentColor; opacity: .35; }
.desk .utable th .sortby:hover { color: var(--color-fg); }
.desk .utable th .sortby:hover svg { opacity: .7; }
.desk .utable th .sortby.on { color: var(--color-fg); }
.desk .utable th .sortby.on svg { opacity: 1; fill: var(--color-accent); }
.desk .sort-m { display: none; }
.desk .codecard { background: var(--color-surface); border-radius: var(--radius-card); padding: 16px 18px; margin-bottom: 14px; display: flex; flex-direction: column; gap: 14px; }
.desk .codelike { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 6px; padding: 12px 16px; font-size: 12.5px; }
.desk .codehead { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; font-size: 12.5px; }
.desk .codehead h2 { margin: 0; font-size: 20px; }
.desk .codename { font-family: var(--font-mono); letter-spacing: .02em; }
.desk .codeowners { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 24px; }
.desk .codeowners .label { margin-bottom: 6px; }
.desk .codeowner { display: flex; flex-direction: column; gap: 2px; padding: 6px 0; font-size: 12.5px; }
.desk .codeowner + .codeowner { border-top: 1px solid var(--color-line); }
.desk .codeuse { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--color-line); padding-top: 12px; }
.desk .coderange { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px; }
.desk .coderange label { display: flex; flex-direction: column; gap: 3px; font-size: 12px; }
.desk .coderange .in { width: auto; padding: 7px 10px; font-size: 13px; }
.desk .codetotals { background: var(--color-surface-2); margin: 0; }
.desk .codenote { margin: 0; font-size: 12.5px; line-height: 1.5; }
.desk .cell2 b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 30ch; }
.desk .cell2 span { display: block; font-size: 12.5px; color: var(--color-fg-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 34ch; }
.desk .utable td.num, .desk .utable th.num { text-align: right; font-variant-numeric: tabular-nums lining-nums; white-space: nowrap; }
.desk .cards { display: flex; flex-direction: column; gap: 12px; }
.desk .req { background: var(--color-surface); border-radius: var(--radius-card); padding: 16px 18px; display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; }
.desk .req h3 { margin: 0; font-size: 15px; font-weight: 600; }
.desk .req .meta { font-size: 12.5px; color: var(--color-fg-3); margin-top: 3px; }
.desk .req .change { margin-top: 10px; font-size: 13.5px; color: var(--color-fg-2); line-height: 1.5; }
.desk .req .change b { color: var(--color-fg); font-weight: 600; }
.desk .req .reason { margin-top: 8px; font-size: 13.5px; line-height: 1.5; border-left: 2px solid var(--color-line); padding-left: 10px; color: var(--color-fg); }
.desk .req form { display: flex; flex-direction: column; gap: 8px; }
.desk .req .acts { display: flex; gap: 8px; flex-wrap: wrap; }
.desk details.form { background: var(--color-surface); border-radius: var(--radius-card); }
.desk details.form > summary { list-style: none; cursor: pointer; padding: 14px 18px; display: flex; justify-content: space-between; align-items: center; gap: 12px; font-weight: 600; }
.desk details.form > summary::-webkit-details-marker { display: none; }
.desk details.form > summary span { font-size: 12.5px; color: var(--color-fg-3); font-weight: 500; }
.desk details.form[open] > summary { border-bottom: 1px solid var(--color-line); }
.desk details.form form { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 12px; }
/* Collateral: the "Create a new post" bar (16 Nov 2026). The three kinds of post as a fanned stack of cards. */
.desk details.newpost { scroll-margin-top: 24px; }
.desk details.newpost > summary { justify-content: flex-start; gap: 16px; padding: 16px 18px; }
.desk details.newpost > summary .np-art { position: relative; flex: none; width: 98px; height: 54px; }
.desk details.newpost > summary .np-card { position: absolute; top: 5px; display: grid; place-items: center; width: 38px; height: 46px; border-radius: 10px; background: var(--color-surface-2); box-shadow: inset 0 0 0 1px var(--color-line); color: var(--color-fg-2); transition: transform 200ms var(--ease-out); }
.desk details.newpost > summary .np-video { left: 2px; transform: rotate(-8deg); }
.desk details.newpost > summary .np-script { left: 58px; transform: rotate(8deg); }
.desk details.newpost > summary .np-image { left: 30px; top: 0; z-index: 1; background: var(--color-surface-3); color: var(--color-accent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--color-accent) 45%, var(--color-line)), var(--shadow-ambient); }
.desk details.newpost > summary:hover .np-video { transform: rotate(-15deg) translateX(-3px); }
.desk details.newpost > summary:hover .np-script { transform: rotate(15deg) translateX(3px); }
.desk details.newpost > summary:hover .np-image { transform: translateY(-2px); }
.desk details.newpost > summary .np-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.desk details.newpost > summary .np-text b { font-size: 15px; font-weight: 600; color: var(--color-fg); }
.desk details.newpost > summary .np-text > span { font-size: 12.5px; color: var(--color-fg-3); font-weight: 500; line-height: 1.4; }
.desk details.newpost > summary .np-plus { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 999px; background: var(--color-accent-fill); color: #fff; transition: transform 200ms var(--ease-out), background 150ms var(--ease-out); }
.desk details.newpost > summary .np-plus .ico { stroke-width: 2; }
.desk details.newpost[open] > summary .np-plus { transform: rotate(45deg); background: var(--color-surface-2); color: var(--color-fg-2); }
.desk .opt .opt-ico { display: grid; place-items: center; color: var(--color-fg-3); }
.desk .opt:has(input:checked) .opt-ico { color: var(--color-accent); }
/* An empty section's "Create new" sits inside the dashed box. */
.desk .empty-create { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 12px 12px 16px; }
.btn-sm { height: 32px; padding: 0 12px; gap: 6px; font-size: 13px; border-radius: var(--radius-control); }
.btn-sm .ico { width: 16px; height: 16px; stroke-width: 2; }
@media (max-width: 760px) {
  .desk details.newpost { scroll-margin-top: 76px; }
  .desk details.newpost > summary { gap: 12px; padding: 14px; }
  .desk details.newpost > summary .np-art { width: 84px; height: 48px; transform: scale(.85); transform-origin: left center; }
}
.desk .row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.desk .field .hint { font-size: 12.5px; color: var(--color-fg-3); line-height: 1.45; }
.desk textarea.in { min-height: 70px; resize: vertical; line-height: 1.45; }
.desk .opts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.desk .opt { display: flex; gap: 10px; align-items: flex-start; border-radius: var(--radius-tile); background: var(--color-surface-2); padding: 12px; box-shadow: inset 0 0 0 1px var(--color-line); cursor: pointer; }
.desk .opt:has(input:checked) { background: var(--color-surface); box-shadow: inset 0 0 0 2px var(--color-accent); }
.desk .opt input { accent-color: var(--color-accent); margin-top: 2px; }
.desk .opt b { display: block; font-size: 13.5px; }
.desk .opt .d { display: block; font-size: 12.5px; color: var(--color-fg-3); line-height: 1.4; margin-top: 2px; }
.desk .xitem { background: var(--color-surface); border-radius: var(--radius-card); padding: 16px 18px; display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 20px; }
.desk .xitem .k { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--color-warn); }
.desk .xitem h3 { margin: 4px 0 0; font-size: 15px; font-weight: 600; }
.desk .xitem p { margin: 6px 0 0; font-size: 13.5px; color: var(--color-fg-2); line-height: 1.5; }
.desk .xitem form { display: flex; flex-direction: column; gap: 8px; }
.desk .demo-bar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 12.5px; color: var(--color-fg-3); margin: -8px 0 18px; padding: 8px 12px; border-radius: var(--radius-tile); border: 1px dashed var(--color-line); }
.desk .demo-bar a { color: var(--color-fg-2); font-weight: 600; }
.desk .demo-bar a[aria-current="true"] { color: var(--color-fg); text-decoration: underline; text-underline-offset: 3px; }

/* Messaging (0044; prototype b04-01…04): the Message panel, the group panel, the activity timeline. */
.desk .msg { margin-top: 18px; background: var(--color-surface); border-radius: var(--radius-card); padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.panel .msg { background: var(--color-surface); }
.desk .msghead { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.desk .msghead h3 { font-family: var(--font-display); font-weight: 700; font-size: 20px; letter-spacing: .03em; text-transform: uppercase; margin: 0; line-height: 1; }
.desk .msg .seg button { height: 32px; padding: 0 12px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--color-fg-2); display: inline-flex; align-items: center; gap: 6px; transition: background 200ms var(--ease-out), color 200ms var(--ease-out); }
.desk .msg .seg button .ico { width: 15px; height: 15px; }
.desk .msg .seg button[aria-pressed="true"] { background: var(--color-surface-3); color: var(--color-fg); }
.desk .msg .sel.big { width: 100%; padding: 10px 34px 10px 12px; font-size: 14px; border-radius: var(--radius-input); }
.desk .msg .to { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13.5px; color: var(--color-fg-2); }
.desk .msg .to b { color: var(--color-fg); font-weight: 600; }
.desk .msg textarea.in.tall { min-height: 112px; }
.desk .msg .hint { font-size: 12.5px; color: var(--color-fg-3); line-height: 1.45; }
.desk .msg .err { font-size: 12.5px; color: var(--color-warn); font-weight: 600; line-height: 1.45; }
.desk .msgfoot { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.desk .msgfoot .f3 { font-size: 12.5px; line-height: 1.4; }
.desk .offnote { margin: 0; border: 1px dashed var(--color-line); border-radius: var(--radius-tile); padding: 12px 14px; font-size: 13.5px; color: var(--color-fg-2); line-height: 1.5; }
.desk .okline { display: flex; gap: 10px; align-items: center; background: var(--color-surface-2); border-radius: var(--radius-tile); padding: 12px 14px; font-size: 13.5px; color: var(--color-fg-2); }
.desk .okline .ck { width: 26px; height: 26px; border-radius: 50%; background: var(--color-accent-fill); color: #fff; display: grid; place-items: center; flex: none; }
.desk .okline .ck .ico { width: 16px; height: 16px; }
.desk .okline b { color: var(--color-fg); font-weight: 600; }
.desk .recip { display: flex; align-items: baseline; gap: 10px; margin-top: 18px; }
.desk .recip b { font-family: var(--font-display); font-weight: 800; font-size: 44px; line-height: 1; }
.desk .recip span { color: var(--color-fg-2); font-size: 14px; }
.desk .preview { background: var(--color-surface-2); border-radius: var(--radius-tile); padding: 12px 14px; font-size: 13.5px; line-height: 1.5; color: var(--color-fg-2); }
.desk .preview .label { display: block; margin-bottom: 6px; font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); }
.desk .preview b { color: var(--color-fg); font-weight: 600; }
.desk .bulk { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--color-surface-2); border-radius: var(--radius-tile); padding: 8px 8px 8px 14px; margin-bottom: 10px; font-size: 13.5px; }
.desk .bulk b { font-weight: 600; }
.desk .bulk .r { margin-left: auto; display: flex; gap: 6px; }
.desk .bulk .btn { height: 32px; }
.desk .ptabs2 { display: flex; gap: 6px; margin: 18px 0 4px; }
.desk .phead { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.desk .phead h2 { font-family: var(--font-display); font-weight: 700; font-size: 34px; letter-spacing: .01em; text-transform: uppercase; margin: 0; line-height: 1; }
.desk .phead p { margin: 6px 0 0; font-size: 13.5px; color: var(--color-fg-2); }
.desk .pbody { padding: 28px 28px 32px; }
.desk .tl { list-style: none; margin: 14px 0 0; padding: 0; position: relative; }
.desk .tl::before { content: ""; position: absolute; left: 15px; top: 8px; bottom: 8px; width: 1px; background: var(--color-line); }
.desk .tl li { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 12px; padding: 10px 0; position: relative; }
.desk .tl .dot { width: 32px; height: 32px; border-radius: 50%; background: var(--color-surface-3); display: grid; place-items: center; color: var(--color-fg-2); position: relative; z-index: 1; }
.desk .tl .dot .ico { width: 16px; height: 16px; }
.desk .tl .dot.acc { background: var(--color-accent-fill); color: #fff; }
.desk .tl .when { font-size: 12px; color: var(--color-fg-3); }
.desk .tl .what { font-size: 14px; font-weight: 600; margin-top: 1px; }
.desk .tl .body { font-size: 13.5px; color: var(--color-fg-2); margin-top: 6px; background: var(--color-surface); border-radius: 10px; padding: 9px 11px; line-height: 1.45; white-space: pre-line; }
.desk .tl .meta { font-size: 12.5px; color: var(--color-fg-3); margin-top: 5px; }

/* Collateral (W10): the publisher's videos, images and teleprompter scripts. */
.desk .hint { font-size: 12.5px; color: var(--color-fg-3); line-height: 1.45; }
.desk .pieces { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.desk .piece { background: var(--color-surface); border-radius: var(--radius-card); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.desk .piece-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.desk .piece h3 { margin: 4px 0 0; font-size: 15px; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.desk .piece .meta { margin: 0; font-size: 12.5px; color: var(--color-fg-3); line-height: 1.45; }
.desk .piece .meta b { color: var(--color-fg); font-weight: 600; }
.desk .piece-act { margin-top: auto; padding-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.desk .pstate { display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; white-space: nowrap; background: var(--color-surface-2); color: var(--color-fg-2); }
.desk .pstate-approved { color: var(--color-accent); box-shadow: inset 0 0 0 1px var(--color-accent); background: transparent; }
.desk .pstate-retired, .desk .pstate-expired { color: var(--color-fg-3); }
.desk .confirm { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--color-fg); line-height: 1.4; cursor: pointer; }
.desk .confirm input { accent-color: var(--color-accent); margin-top: 2px; flex: none; }
.desk .claims { list-style: none; margin: 10px 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; }
.desk .claims .flag { margin-right: 6px; }
.desk .ced { display: flex; flex-direction: column; gap: 14px; }
.desk .ced .acts { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.desk .ced code, .desk .pub-foot code { font-size: 12px; background: var(--color-surface-2); border-radius: 4px; padding: 0 4px; }
.desk .drop { display: flex; flex-direction: column; gap: 8px; border: 1px dashed var(--color-line); border-radius: var(--radius-tile); padding: 12px 14px; }
.desk .drop input[type="file"] { font-size: 13px; max-width: 100%; }
.desk .approve { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--color-line); }
.desk .vbody { display: flex; flex-direction: column; gap: 10px; }
.desk .prompter { font-size: 16px; line-height: 1.6; color: var(--color-fg); white-space: pre-line; }
.desk .preview { white-space: pre-line; }
.desk .vmedia { display: block; width: 100%; max-height: 420px; object-fit: contain; border-radius: var(--radius-tile); background: var(--color-surface-2); }
.desk .vmedia-none { display: grid; place-items: center; height: 140px; font-size: 12.5px; color: var(--color-fg-3); }
.desk .vlist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; font-size: 13px; }
.desk .vlist li { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 2px 10px; color: var(--color-fg-2); }
.desk .vlist li .f3 { grid-column: 2; font-size: 12.5px; }
/* Invitations (W9): the switch, saved lists, the filter row, the portal column and the invite panel. */
.desk .inv-switch { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; background: var(--color-surface); border-radius: var(--radius-card); padding: 14px 18px; margin-bottom: 14px; }
.desk .inv-switch.is-paused { box-shadow: inset 3px 0 0 var(--color-warn); }
.desk .inv-switch.is-on { box-shadow: inset 3px 0 0 var(--color-accent); }
.desk .inv-switch-l { display: flex; gap: 12px; align-items: flex-start; min-width: 0; flex: 1 1 420px; }
.desk .inv-switch-l p { font-size: 13.5px; color: var(--color-fg-2); line-height: 1.45; max-width: 76ch; }
.desk .inv-dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 4px; flex: none; }
.desk .is-paused .inv-dot { background: var(--color-warn); }
.desk .is-on .inv-dot { background: var(--color-accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--color-accent) 18%, transparent); }
.desk .inv-state { font-family: var(--font-display); font-weight: 800; font-size: 22px; letter-spacing: .03em; text-transform: uppercase; margin-left: 6px; }
.desk .is-paused .inv-state { color: var(--color-warn); }
.desk .inv-switch-r { display: flex; align-items: center; gap: 10px; }
.desk .inv-turn { position: relative; }
.desk .inv-turn > summary { list-style: none; cursor: pointer; }
.desk .inv-turn > summary::-webkit-details-marker { display: none; }
.desk .inv-turn-form { position: absolute; right: 0; top: 44px; z-index: 15; width: 320px; display: flex; flex-direction: column; gap: 10px; background: var(--color-surface-2); border-radius: var(--radius-tile); padding: 14px; box-shadow: var(--shadow-ambient); }
.desk .inv-turn-form .hint { font-size: 12px; color: var(--color-fg-3); }
.desk .inv-selfclaim { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; background: var(--color-surface); border-radius: var(--radius-card); padding: 12px 18px; margin: -6px 0 14px; }
.desk .inv-selfclaim p { max-width: 86ch; line-height: 1.45; margin-top: 2px; }
.desk .inv-selfclaim .inv-on { color: var(--color-accent); font-weight: 700; margin-left: 4px; }
.desk .inv-selfclaim .inv-off { color: var(--color-warn); font-weight: 700; margin-left: 4px; }
.desk .inv-lists { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.desk .inv-lists .label { margin-right: 4px; }
.desk .inv-draft { display: inline-flex; align-items: center; gap: 4px; }
.desk .inv-filters { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.desk .inv-filters .in { max-width: 240px; padding: 7px 12px; font-size: 13px; }
.desk .inv-f { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--color-fg-2); font-weight: 600; }
.desk .inv-check { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--color-fg-2); font-weight: 600; padding: 0 4px; }
.desk .inv-check input, .desk .inv-table input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--color-accent-fill); }
.desk .inv-table th.ck, .desk .inv-table td.ck { width: 34px; padding-right: 0; }
.desk .inv-table tr[aria-selected="true"] td { background: color-mix(in srgb, var(--color-accent) 7%, transparent); }
.desk .inv-table .state { font-size: 10.5px; }
.desk .inv-rank { font-weight: 700; color: var(--color-fg); }
.desk .inv-portal { display: flex; flex-direction: column; line-height: 1.3; }
.desk .inv-portal b { font-size: 12.5px; font-weight: 700; }
.desk .inv-portal span { font-size: 12px; color: var(--color-fg-3); }
.desk .inv-portal.is-off b { color: var(--color-fg-3); }
.desk .inv-portal.is-on b { color: var(--color-accent); }
.desk .inv-portal.is-ok b { color: var(--color-fg); }
.desk .inv-portal.is-warn b { color: var(--color-warn); }
.desk .inv-acts { display: inline-flex; gap: 2px; white-space: nowrap; }
.desk .inv-acts button[disabled] { opacity: .45; cursor: not-allowed; }
.desk .inv-skips { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 3px; font-size: 13px; color: var(--color-fg-2); }
.desk .inv-skips b { color: var(--color-fg); font-weight: 600; }
.desk .inv-panel { width: min(620px, 100vw); }
.desk .inv-panel .inv-text { min-height: 210px; }
.desk .inv-preview .inv-subj { font-weight: 600; color: var(--color-fg); margin-bottom: 8px; }
.desk .inv-preview .inv-body { white-space: pre-wrap; }
.desk .inv-preview .inv-link { color: var(--color-accent); font-weight: 600; }
.desk .inv-save { display: flex; gap: 8px; }
.desk .inv-save .in { flex: 1; }
.desk button.scrim { border: 0; cursor: default; }

@media (max-width: 1180px) {
  .desk .grid2 { grid-template-columns: 1fr; }
  .desk .side { position: static; }
  .desk .cols, .desk .rrow { grid-template-columns: minmax(140px, 1.2fr) minmax(140px, 2fr) 140px 56px 100px; }
  .desk .two { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .desk .top { flex-direction: column; align-items: flex-start; gap: 12px; }
  .desk .headline { font-size: 34px; }
  .desk .move { grid-template-columns: 30px minmax(0, 1fr); }
  .desk .move .btn { grid-column: 2; justify-self: start; }
  .desk .social .acts { grid-column: 2; justify-content: flex-start; }
  .desk .social .acts .btn { grid-column: auto; }
  .desk .mailgrid { grid-template-columns: 1fr; }
  .desk .mailresults { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .desk .mailtable td:first-child { max-width: none; }
  .desk .mailframe { margin: 0 -16px; border-radius: 0; }
  .desk .mailframe iframe { height: 78vh; }
  .desk .mailkey { grid-template-columns: 1fr; }
  .desk .mailkey .btn { justify-self: start; }
  .desk .cols { display: none; }
  .desk .rrow { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "who sales" "track track" "stat stat"; gap: 6px 12px; padding: 12px 4px; }
  .desk .rrow > .who { grid-area: who; } .desk .rrow > .track { grid-area: track; } .desk .rrow > .status { grid-area: stat; }
  .desk .rrow > .orders { display: none; } .desk .rrow > .sales { grid-area: sales; }
  .desk .bandhead { grid-template-columns: 1fr; } .desk .bandfacts { justify-content: flex-start; }
  .desk .bandsum { grid-template-columns: 1fr; }
  .desk dl.kv { grid-template-columns: 110px minmax(0, 1fr); }
  .desk .req, .desk .xitem { grid-template-columns: 1fr; }
  .desk .pieces { grid-template-columns: 1fr; }
  .desk .piece-act .btn { flex: 1; }
  .desk .row2, .desk .opts { grid-template-columns: 1fr; }
  .desk .toolbar .in { max-width: none; }
  .desk .ask .btn { padding: 0 12px; }
  .desk .sort-m { display: flex; align-items: center; gap: 8px; width: 100%; font-size: 12.5px; }
  .desk .sort-m .in { flex: 1; padding: 8px 10px; font-size: 13.5px; }
  .desk .codecard { padding: 14px; }
  .desk .codeowners { grid-template-columns: 1fr; }
  .desk .coderange label { flex: 1 1 130px; }
  .desk .coderange .in { width: 100%; }
  .desk .codetotals { gap: 18px; padding: 12px 14px; }
  .desk .codetotals .big { font-size: 24px; }
  .desk .msgfoot { flex-direction: column; align-items: stretch; }
  .desk .pbody { padding: 20px 16px 28px; }
  .desk .mtable thead { display: none; }
  .desk .mtable, .desk .mtable tbody, .desk .mtable tr, .desk .mtable td { display: block; width: 100%; }
  .desk .mtable tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 12px 14px; border-bottom: 1px solid var(--color-line); }
  .desk .mtable tr:last-child { border-bottom: 0; }
  .desk .mtable td { border: 0; padding: 0; width: auto; font-size: 12.5px; color: var(--color-fg-2); }
  .desk .mtable td:first-child { grid-column: 1; font-size: 13.5px; color: var(--color-fg); }
  .desk .mtable td.lead2 { grid-column: 2; grid-row: 1; text-align: right; font-size: 13.5px; color: var(--color-fg); }
  .desk .mtable td.hide-m { display: none; }
  .desk .mtable td.num:not(.lead2) { text-align: left; }
  .desk .mtable td[data-l]::before { content: attr(data-l) " "; color: var(--color-fg-3); }
  /* Flags get their own line: in the auto column, three pills squeezed the name to a sliver. */
  .desk .mtable td:has(> .flagrow) { grid-column: 1 / -1; }
  .desk .mtable td:empty { display: none; }
  .desk .mtable td.wide-m { grid-column: 1 / -1; }
  .desk .inv-table input[type="checkbox"] { width: 24px; height: 24px; }
  .desk .cell2 b, .desk .cell2 span { max-width: none; white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* A screen streaming in behind the rail ((app)/loading.tsx). Still, not shimmering. */
.pub-loading { display: grid; gap: 12px; max-width: 820px; padding-top: 6px; }
.pub-loading i { display: block; height: 14px; border-radius: 6px; background: var(--color-surface-2); }
.pub-loading i:first-child { height: 30px; width: 38%; margin-bottom: 10px; }
.pub-loading i:last-child { width: 62%; }

/* ── Automations (0061): the workflow list and the canvas ─────────────────
 * The canvas sits on the ground like a table does; boxes are surface tiles.
 * The accent stays on focus (the selected box, the primary action); a box
 * with something to fix carries the warn word "!", never a warn fill. */
.autonew { display: flex; align-items: flex-end; gap: 10px; max-width: 620px; margin-bottom: 8px; }
.autonew .field { flex: 1; }
.autocrumb { margin-bottom: 10px; }
.autoed { display: flex; flex-direction: column; gap: 12px; }
.autobar { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.autobar-name { display: flex; flex-direction: column; gap: 6px; min-width: 0; flex: 1; }
.autoname { background: transparent; border: 0; color: var(--color-fg); font-family: var(--font-display); font-weight: 700; font-size: 30px; letter-spacing: .03em; text-transform: uppercase; line-height: 1; padding: 2px 0; width: 100%; max-width: 720px; border-radius: 6px; }
.autoname:hover:not([readonly]) { box-shadow: inset 0 -1px 0 var(--color-line); }
.autoname:focus { outline: none; box-shadow: inset 0 -2px 0 var(--color-accent); }
.autobar-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 13px; }
.autodirty { color: var(--color-warn); font-size: 12.5px; font-weight: 600; }
.autobar-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.autonote { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--color-surface-2); border-radius: var(--radius-tile); padding: 10px 14px; font-size: 13.5px; color: var(--color-fg); }
.autonote.is-err { color: var(--color-warn); }

.autogrid { display: grid; grid-template-columns: 196px minmax(0, 1fr) 330px; gap: 12px; height: calc(100vh - 230px); min-height: 560px; }
.autopal, .autoinspect { background: var(--color-surface); border-radius: var(--radius-card); padding: 14px; overflow-y: auto; }
.autopal { display: flex; flex-direction: column; gap: 6px; }
.autopal-hint { font-size: 12px; line-height: 1.4; margin: 0 0 6px; }
.autopal-btn { display: flex; align-items: center; gap: 8px; text-align: left; background: var(--color-surface-2); color: var(--color-fg); border-radius: var(--radius-control); padding: 9px 10px; font-weight: 600; font-size: 13px; transition: background 150ms var(--ease-out); }
.autopal-btn:hover { background: var(--color-surface-3); }
.autopal-btn::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--color-mark-neutral); flex: none; }
.autopal-btn.k-send_email::before, .autopal-btn.k-send_text::before { border-radius: 999px; background: var(--color-fg-2); }
.autopal-btn.k-wait::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--color-fg-3); border-radius: 999px; }
.autopal-btn.k-branch::before, .autopal-btn.k-split::before { transform: rotate(45deg); background: var(--color-fg-3); }
.autoissues { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.autoissues .btn-quiet { text-align: left; font-size: 12.5px; color: var(--color-warn); text-decoration: none; padding: 2px 0; line-height: 1.35; min-height: 0; }
.autoissues .btn-quiet:hover { text-decoration: underline; }

.autoflow { background: var(--color-ground); border-radius: var(--radius-card); box-shadow: inset 0 0 0 1px var(--color-line); overflow: hidden; min-height: 0; }
.autoflow .react-flow {
  --xy-background-color: var(--color-ground);
  --xy-background-pattern-color: var(--color-surface-3);
  --xy-edge-stroke: var(--color-fg-3);
  --xy-edge-stroke-selected: var(--color-accent);
  --xy-edge-stroke-width: 1.5;
  --xy-connectionline-stroke: var(--color-accent);
  --xy-edge-label-background-color: var(--color-surface-2);
  --xy-edge-label-color: var(--color-fg);
  --xy-controls-button-background-color: var(--color-surface-2);
  --xy-controls-button-background-color-hover: var(--color-surface-3);
  --xy-controls-button-color: var(--color-fg);
  --xy-controls-button-border-color: var(--color-line);
  --xy-selection-background-color: color-mix(in srgb, var(--color-accent) 8%, transparent);
  --xy-selection-border: 1px dotted var(--color-accent);
  background: var(--color-ground);
}
.autoflow .react-flow__edge-textbg { rx: 6px; }
.autoflow .react-flow__edge-text { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.autoflow .react-flow__controls { box-shadow: none; border-radius: var(--radius-control); overflow: hidden; }

.autonode { width: 228px; background: var(--color-surface); border-radius: var(--radius-tile); padding: 10px 12px 12px; box-shadow: inset 0 0 0 1px var(--color-line), var(--shadow-ambient); color: var(--color-fg); cursor: grab; }
.autonode.k-trigger { background: var(--color-surface-3); }
.autonode.is-sel { box-shadow: inset 0 0 0 2px var(--color-accent), var(--shadow-ambient); }
.autonode-kind { display: flex; align-items: center; justify-content: space-between; font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); margin-bottom: 4px; }
.autonode-flag { color: var(--color-warn); font-size: 13px; letter-spacing: 0; }
.autonode-what { font-size: 13.5px; line-height: 1.3; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.autonode-stat { margin-top: 6px; font-size: 11.5px; color: var(--color-fg-2); font-variant-numeric: tabular-nums lining-nums; }
.autonode .autohandle { width: 11px; height: 11px; background: var(--color-surface-3); border: 2px solid var(--color-fg-3); }
.autonode .autohandle:hover, .autonode .autohandle.connectingto { border-color: var(--color-accent); }
.autohandle-label { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--color-fg-2); pointer-events: none; white-space: nowrap; }

.autoinspect-body, .autoinspect-empty { display: flex; flex-direction: column; gap: 12px; }
.autoinspect-empty p { margin: 0; font-size: 13px; line-height: 1.5; }
.autoinspect .textarea { resize: vertical; min-height: 90px; line-height: 1.45; }
.autoinspect p.f3 { margin: 0; font-size: 12px; line-height: 1.45; }
.autoprob { list-style: none; margin: 0; padding: 0; color: var(--color-warn); font-size: 12.5px; font-weight: 600; display: flex; flex-direction: column; gap: 2px; }
.automerge { display: flex; flex-wrap: wrap; gap: 6px; }
.automerge .chip { height: 24px; font-family: var(--font-mono); font-size: 11.5px; cursor: pointer; }
.automerge .chip:hover { background: var(--color-mark-neutral); color: #fff; }
.autocheck { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; line-height: 1.4; cursor: pointer; }
.autocheck input { margin-top: 2px; accent-color: var(--color-accent-fill); }
.autorow { display: flex; gap: 10px; align-items: center; }
.autorow .field { flex: 1; }
.autorow input[type="range"] { flex: 1; accent-color: var(--color-accent-fill); }

@media (max-width: 1180px) {
  .autogrid { grid-template-columns: minmax(0, 1fr); height: auto; }
  .autoflow { height: 560px; }
  .autopal { flex-direction: row; flex-wrap: wrap; }
  .autopal .label, .autopal-hint, .autoissues { width: 100%; }
}

/* The embedded view (0064): framed by a publisher's own admin, so no rail and tight edges. */
.embedframe { min-height: 100vh; padding: 20px 22px 28px; }
.embedframe .autogrid { height: calc(100vh - 190px); }
.embedrefused { max-width: 560px; padding-top: 40px; }

/* ── Favorites pages (0074): rules, can't feature, the template grid and editor ── */
.desk .fav-h3 { margin: 0 0 2px; font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--color-fg-3); }
.desk .fav-rules { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.desk .fav-rule-col { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.desk .fav-switchrow { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; font-size: 13.5px; line-height: 1.4; }
.desk .fav-switchrow input { flex: none; width: 34px; height: 20px; margin: 1px 0 0; appearance: none; border-radius: 999px; background: var(--color-surface-3); box-shadow: inset 0 0 0 1px var(--color-line); position: relative; cursor: pointer; transition: background 150ms var(--ease-out); }
.desk .fav-switchrow input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--color-fg-2); transition: transform 150ms var(--ease-out), background 150ms var(--ease-out); }
.desk .fav-switchrow input:checked { background: var(--color-accent-fill); box-shadow: none; }
.desk .fav-switchrow input:checked::after { transform: translateX(14px); background: #fff; }
.desk .fav-switchrow input:disabled { cursor: not-allowed; opacity: .6; }
.desk .fav-switchrow b { display: block; font-weight: 600; }
.desk .fav-switchrow .d { display: block; font-size: 12.5px; color: var(--color-fg-3); }
.desk .fav-save { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding-top: 14px; border-top: 1px solid var(--color-line); }
.desk .fav-save .btn { height: 40px; }

.desk .fav-thumb { flex: none; width: 40px; height: 40px; border-radius: 9px; object-fit: contain; background: #fff; }
.desk .fav-xlist { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 8px; }
.desk .fav-xlist li { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 7px 8px 7px 7px; border-radius: var(--radius-tile); background: var(--color-surface-2); font-size: 13.5px; font-weight: 600; }
.desk .fav-xlist .fav-x { height: 32px; padding: 0 10px; color: var(--color-fg-2); }
.desk .fav-xlist .fav-x span { font-size: 17px; line-height: 1; }
.desk .fav-xsearch { display: flex; flex-direction: column; gap: 8px; max-width: 620px; }
.desk .fav-xmatches { grid-template-columns: 1fr; }
.desk .fav-xmatches li { background: var(--color-surface); box-shadow: inset 0 0 0 1px var(--color-line); }
.desk .fav-xmatches li.f3 { font-weight: 400; box-shadow: none; background: none; padding-left: 2px; }

.desk .fav-sechead { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.desk .fav-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 14px; }
.desk .fav-card { display: flex; flex-direction: column; border-radius: var(--radius-card); background: var(--color-surface); overflow: hidden; min-width: 0; }
.desk .fav-card.is-off .fav-swatch { filter: grayscale(.7) brightness(.7); }
.desk .fav-swatch { position: relative; height: 104px; overflow: hidden; }
.desk .fav-swatch img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.desk .fav-swatch img + .fav-swatch-greet { text-shadow: 0 1px 2px rgba(0, 0, 0, .45); }
.desk .fav-swatch svg { position: absolute; right: 4px; top: 0; width: 76px; height: 76px; opacity: .9; }
.desk .fav-swatch-greet { position: absolute; left: 12px; bottom: 22px; right: 70px; font-size: 13px; font-weight: 700; line-height: 1.2; }
.desk .fav-swatch-ground { position: absolute; left: 0; right: 0; bottom: 0; height: 12px; }
/* 0146 Gallery: a template card is a small room (wall, the occasion's greeting, two plinths). */
.desk .fav-room { height: 116px; }
.desk .fav-room-img { position: absolute; inset: 0 0 auto; height: 52px; width: 100%; object-fit: cover; }
.desk .fav-room-occ { position: absolute; left: 12px; top: 12px; max-width: calc(100% - 24px); padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.desk .fav-room-pl { position: absolute; left: 12px; bottom: 12px; width: 44%; height: 46px; }
.desk .fav-room-pl2 { left: auto; right: 12px; width: 38%; }
.desk .fav-card-b { display: flex; flex-direction: column; gap: 10px; padding: 12px; flex: 1; }
.desk .fav-card-b b { font-size: 14px; }
.desk .fav-own { height: 18px; margin-left: 6px; padding: 0 7px; font-size: 10.5px; vertical-align: 1px; }
.desk .fav-card-act { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; }
.desk .fav-card-act .btn { height: 32px; }
.desk .fav-switch { display: inline-flex; align-items: center; gap: 8px; }
.desk .fav-switch input { width: 34px; height: 20px; margin: 0; appearance: none; border-radius: 999px; background: var(--color-surface-3); box-shadow: inset 0 0 0 1px var(--color-line); position: relative; cursor: pointer; }
.desk .fav-switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--color-fg-2); transition: transform 150ms var(--ease-out); }
.desk .fav-switch input:checked { background: var(--color-accent-fill); box-shadow: none; }
.desk .fav-switch input:checked::after { transform: translateX(14px); background: #fff; }
.desk .fav-card-new a { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 6px; height: 100%; min-height: 190px; padding: 18px; border-radius: var(--radius-card); box-shadow: inset 0 0 0 1px var(--color-line); background: transparent; transition: background 150ms var(--ease-out); }
.desk .fav-card-new { background: transparent; border: 1px dashed var(--color-line); }
.desk .fav-card-new a:hover { background: var(--color-surface); }
.desk .fav-plus { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--color-accent-fill); color: #fff; font-size: 20px; font-weight: 600; margin-bottom: 4px; }

.desk .fav-editor { display: grid; grid-template-columns: minmax(320px, 400px) minmax(0, 1fr); gap: 24px; align-items: start; }
.desk .fav-form { display: flex; flex-direction: column; gap: 14px; }
.desk .fav-when { display: grid; grid-template-columns: 1fr; gap: 8px; }
.desk .fav-color { display: flex; gap: 8px; align-items: center; }
.desk .fav-color input[type="color"] { flex: none; width: 40px; height: 40px; padding: 0; border: 0; border-radius: var(--radius-input); background: none; cursor: pointer; }
.desk .fav-color input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.desk .fav-color input[type="color"]::-webkit-color-swatch { border: 1px solid var(--color-line); border-radius: var(--radius-input); }
.desk .fav-color .in { font-family: var(--font-mono); text-transform: uppercase; }
.desk .fav-himg { display: block; width: 100%; height: 96px; border-radius: var(--radius-tile); object-fit: cover; position: relative; overflow: hidden; }
.desk .fav-himg-empty svg { position: absolute; right: 6px; top: 0; width: 84px; height: 84px; opacity: .9; }
.desk .fav-preview-col { position: sticky; top: 16px; min-width: 0; }
.desk .fav-preview { background: var(--color-surface); border-radius: var(--radius-card); padding: 14px; }
.desk .fav-preview-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.desk .fav-preview .seg button { height: 32px; padding: 0 14px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--color-fg-2); transition: background 200ms var(--ease-out), color 200ms var(--ease-out); }
.desk .fav-preview .seg button[aria-pressed="true"] { background: var(--color-surface-3); color: var(--color-fg); }
.desk .fav-preview .seg { background: var(--color-surface-2); }
.desk .fav-stage { display: flex; gap: 20px; align-items: flex-start; justify-content: center; min-height: 200px; }
.desk .fav-stage-desktop, .desk .fav-stage-both { justify-content: flex-start; }
.desk .fav-desk { flex: none; border-radius: 12px; overflow: hidden; box-shadow: 0 0 0 1px var(--color-line), var(--shadow-lift); background: #fff; }
.desk .fav-desk-bar { display: flex; gap: 6px; align-items: center; height: 28px; padding: 0 12px; background: #E9E6E0; }
.desk .fav-desk-bar i { width: 9px; height: 9px; border-radius: 50%; background: #C9C4BB; }
.desk .fav-stage .phone { box-shadow: 0 0 0 1px var(--color-line), var(--shadow-lift); }
.desk .fav-archive { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; max-width: 400px; margin-top: 18px; padding: 14px 16px; border-radius: var(--radius-card); box-shadow: inset 0 0 0 1px var(--color-line); }

@media (max-width: 1180px) {
  .desk .fav-rules { grid-template-columns: 1fr 1fr; }
  .desk .fav-editor { grid-template-columns: minmax(0, 1fr); }
  .desk .fav-preview-col { position: static; }
  .desk .fav-archive { max-width: none; }
}
@media (max-width: 760px) {
  .desk .fav-rules { grid-template-columns: 1fr; }
  .desk .fav-xlist { grid-template-columns: 1fr; }
  .desk .fav-preview { padding: 10px; }
  .desk .fav-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .desk .fav-swatch { height: 84px; }
  .desk .fav-swatch svg { width: 56px; height: 56px; }
  .desk .fav-swatch-greet { right: 10px; bottom: 18px; font-size: 12px; }
  .desk .fav-card-b { padding: 10px; gap: 8px; }
  .desk .fav-card-b b { font-size: 13.5px; }
  .desk .fav-card-new a { min-height: 150px; padding: 14px; }
  .desk .fav-card-act .btn { padding: 0 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .desk .fav-switchrow input, .desk .fav-switchrow input::after, .desk .fav-switch input::after { transition: none; }
}

/*
 * The Brief in Daylight (3 Dec 2026, "A in Daylight", Room to Breathe layout; mockup briefA(1)).
 * One sentence, the moves as quiet rows, a Program health card, Learn and the Top 10 as one row each.
 * State words carry a dot in the fill color and the word in the darker text color: never color alone.
 */
.desk.brief .brief-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 40px; align-items: start; }
.desk.brief .brief-main { min-width: 0; display: flex; flex-direction: column; }
.desk.brief .brief-top { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.desk.brief .brief-date { font-size: 13.5px; color: var(--color-fg-3); font-weight: 600; }
.desk.brief .brief-headline { font-family: var(--font-display); font-weight: 800; font-size: 54px; line-height: .95; letter-spacing: .005em; text-transform: uppercase; text-wrap: balance; margin: 14px 0 0; }
.desk.brief .brief-sub { font-size: 15px; color: var(--color-fg-2); margin: 12px 0 0; max-width: 64ch; line-height: 1.55; }
.desk.brief .brief-sub b { color: var(--color-fg); font-weight: 600; }
.desk.brief .brief-sec { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 34px 0 10px; flex-wrap: wrap; }
.desk.brief .brief-sec h2 { font-size: 15px; font-weight: 700; margin: 0; }
.desk.brief .brief-sec span { font-size: 13px; color: var(--color-fg-3); }
.desk.brief .brief-list { background: var(--color-surface); border-radius: var(--radius-card); overflow: hidden; }
.desk.brief .brief-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 14px 18px; min-height: 60px; }
.desk.brief .brief-list > * + *, .desk.brief .brief-more > .brief-row, .desk.brief .brief-fold + * { border-top: 1px solid var(--color-line); }
.desk.brief .brief-what { display: block; font-size: 14.5px; font-weight: 600; line-height: 1.35; }
.desk.brief .brief-why { display: block; font-size: 13px; color: var(--color-fg-3); line-height: 1.45; margin-top: 2px; }
.desk.brief .brief-row .btn { height: 36px; font-size: 13.5px; }
.desk.brief .brief-more > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: center; min-height: 46px; font-size: 13.5px; font-weight: 600; color: var(--color-fg-2); border-top: 1px solid var(--color-line); }
.desk.brief .brief-more > summary::-webkit-details-marker { display: none; }
.desk.brief .brief-more > summary:hover { color: var(--color-fg); background: var(--color-surface-2); }
.desk.brief .brief-more[open] > summary { display: none; }
.desk.brief .brief-state { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; vertical-align: 1px; }
.desk.brief .brief-state i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.desk.brief .brief-state.warn { color: var(--color-warn); }
.desk.brief .brief-state.warn i { background: var(--color-warn-dot); }
.desk.brief .brief-state.ok { color: var(--color-ok); }
.desk.brief .brief-state.ok i { background: var(--color-ok-dot); }
.desk.brief .brief-state.wait { color: var(--color-wait); }
.desk.brief .brief-state.wait i { background: var(--color-wait-dot); }
.desk.brief .lnk { color: var(--color-fg-2); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.desk.brief .lnk:hover { color: var(--color-fg); }

.desk.brief .brief-side { display: flex; flex-direction: column; gap: 22px; min-width: 0; position: sticky; top: 20px; }
.desk.brief .brief-card { background: var(--color-surface); border-radius: var(--radius-card); padding: 18px; display: flex; flex-direction: column; gap: 18px; }
.desk.brief .brief-cardh { font-size: 15px; font-weight: 700; margin: 0; }
.desk.brief .meter-top { display: flex; justify-content: space-between; gap: 10px; font-size: 13.5px; }
.desk.brief .meter-top b { font-weight: 600; }
.desk.brief .meter-top span { color: var(--color-fg-3); font-variant-numeric: lining-nums; white-space: nowrap; }
.desk.brief .meter-bar { position: relative; height: 8px; border-radius: 4px; background: var(--color-surface-3); margin-top: 7px; }
.desk.brief .meter-bar i { display: block; height: 100%; border-radius: 4px; background: var(--color-fg-2); }
.desk.brief .meter-bar i.fill-ok { background: var(--color-ok-dot); }
.desk.brief .meter-bar i.fill-wait { background: var(--color-wait-dot); }
.desk.brief .meter-bar em { position: absolute; top: -3px; bottom: -3px; width: 2px; margin-left: -1px; background: var(--color-fg); border-radius: 1px; }
.desk.brief .meter-note { margin: 7px 0 0; font-size: 12.5px; color: var(--color-fg-3); line-height: 1.45; }
.desk.brief .daily svg { display: block; margin-top: 8px; }
.desk.brief .daily-bar { fill: var(--color-fg-3); opacity: .55; }
.desk.brief .daily-bar:hover, .desk.brief .daily-today:hover { opacity: 1; }
.desk.brief .daily-today { fill: var(--color-accent); }
.desk.brief .daily-base { stroke: var(--color-line); }
.desk.brief .daily-axis { display: flex; justify-content: space-between; margin-top: 4px; font-size: 12px; color: var(--color-fg-3); }

.desk.brief .brief-row.brief-link { grid-template-columns: 30px minmax(0, 1fr) auto; gap: 12px; padding: 12px 14px; transition: background 150ms var(--ease-out); }
.desk.brief .brief-row.brief-link:hover { background: var(--color-surface-2); }
.desk.brief .brief-gl { width: 30px; height: 30px; border-radius: 9px; background: var(--color-surface-2); display: grid; place-items: center; color: var(--color-fg-2); }
.desk.brief .chev { width: 14px; height: 14px; color: var(--color-fg-3); transition: transform 200ms var(--ease-out); }
.desk.brief .brief-review { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; color: var(--color-fg-3); white-space: nowrap; }
.desk.brief .brief-fold > summary { list-style: none; cursor: pointer; }
.desk.brief .brief-fold > summary::-webkit-details-marker { display: none; }
.desk.brief .brief-fold[open] .brief-review .chev { transform: rotate(90deg); }
.desk.brief .learn-list { list-style: none; margin: 0; padding: 4px 10px 6px; border-top: 1px solid var(--color-line); }
.desk.brief .learn-list li { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 7px 4px; }
.desk.brief .learn-list .nm { display: block; font-weight: 600; font-size: 13px; }
.desk.brief .learn-list .meta { display: block; font-size: 12px; color: var(--color-fg-3); }
.desk.brief .learn-list .amt { text-align: right; font-size: 13px; }
.desk.brief .learn-list .amt small { display: block; font-size: 11.5px; color: var(--color-fg-3); }
.desk.brief .brief-fold .note { padding: 0 14px 12px; }

@media (max-width: 1180px) {
  .desk.brief .brief-grid { grid-template-columns: 1fr; gap: 30px; }
  .desk.brief .brief-side { position: static; }
}
@media (max-width: 760px) {
  .desk.brief .brief-headline { font-size: 38px; }
  .desk.brief .brief-row { grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 14px 16px; }
  .desk.brief .brief-row .btn { justify-self: start; }
  .desk.brief .brief-row.brief-link { grid-template-columns: 30px minmax(0, 1fr) auto; }
  .desk.brief .brief-review { font-size: 0; }
}

/* The Daylight / Dark switch (3 Dec 2026). */
.theme-toggle { display: inline-grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: var(--radius-input); color: var(--color-fg-2); background: transparent; transition: background 150ms var(--ease-out), color 150ms var(--ease-out); }
.theme-toggle:hover { background: var(--color-surface); color: var(--color-fg); }
.pub-theme-m { display: none; }
@media (max-width: 760px) {
  .pub-theme-m { display: inline-grid; margin-left: auto; }
}

/* Staff admin on a phone (ADMIN-11). The rail is 208px and the page had 32px a side, which left about 118px
   at 390px. Below 768px the rail becomes a header: wordmark and theme, every screen in one row that scrolls
   sideways (Audit and Settings after a hairline), then who is signed in; the page gets the full width.
   Plain CSS after the Tailwind import, so it wins over the utilities on the same elements. */
@media (max-width: 767px) {
  .staff-shell { display: flex; flex-direction: column; }
  .staff-shell > .staff-main { flex: 1; width: 100%; }
  .staff-rail { position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--color-line); padding: 10px 12px 8px; }
  .staff-rail .staff-brand { margin-bottom: 6px; padding-left: 4px; }
  .staff-rail .staff-links { display: flex; align-items: center; gap: 2px; overflow-x: auto; scrollbar-width: none; margin: 0 -12px; padding: 0 12px; }
  .staff-rail .staff-links::-webkit-scrollbar { display: none; }
  .staff-rail .staff-nav, .staff-rail .staff-more { flex-direction: row; flex: none; gap: 2px; }
  .staff-rail .staff-more { border-top: 0; border-left: 1px solid var(--color-line); margin: 0 0 0 4px; padding: 0 0 0 6px; }
  .staff-rail .nav-item { flex: none; height: 34px; white-space: nowrap; }
  .staff-rail .staff-me { margin-top: 6px; padding: 0 4px; display: flex; flex-wrap: wrap; align-items: center; column-gap: 12px; }
  .staff-rail .staff-me > * { margin: 0; }
  .staff-main { padding: 16px; }
}

/*
 * Payout planner (0151, 3 Dec 2026). One headline, inputs beside answers, then full-width comparisons. Chart colors
 * are their own tokens (identity, not state): each case keeps its color everywhere, and the first-order bar's parts
 * are listed with amounts in the key, so nothing is read from color alone. The series values were checked for
 * color-vision separation on both grounds; text never wears a series color.
 */
.planner {
  --pl-expected: #2a78d6; --pl-cautious: #eb6834; --pl-strong: #1baf7a;
  --pl-keep: #1baf7a; --pl-comm: #3761E0; --pl-over: #eb6834; --pl-disc: #6250d6; --pl-cost: #eda100; --pl-fees: #e87ba4;
  --pl-ink: #12151A; --pl-ink-strong: #FFFFFF;
  --pl-up: #2a78d6; --pl-down: #e34948;
}
:root[data-theme="dark"] .planner {
  --pl-expected: #3987e5; --pl-cautious: #d95926; --pl-strong: #199e70;
  --pl-keep: #199e70; --pl-comm: #3987e5; --pl-over: #d95926; --pl-disc: #9085e9; --pl-cost: #c98500; --pl-fees: #d55181;
  --pl-ink: #111111; --pl-ink-strong: #111111;
  --pl-up: #3987e5; --pl-down: #e66767;
}
.pl { display: flex; flex-direction: column; gap: 14px; }
.pl .panelcard { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.pl .panelcard h2 { margin: 0; }
.pl-bar { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; }
.pl-plans { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.pl-chip { height: 32px; font-size: 13.5px; cursor: pointer; }
.pl-save { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.pl-state { font-size: 13px; color: var(--color-fg-3); }
.pl-state.err { color: var(--color-warn); font-weight: 600; }
.pl-head { gap: 10px !important; padding: 22px !important; }
.pl-pill { align-self: flex-start; font-size: 13px; font-weight: 700; border-radius: var(--radius-chip); padding: 4px 10px; }
.pl-pill.ok { color: var(--color-ok); background: var(--color-wash-ok); }
.pl-pill.wait { color: var(--color-wait); background: var(--color-wash-wait); }
.pl-pill.warn { color: var(--color-warn); background: var(--color-wash-warn); }
.pl-big { font-family: var(--font-display); font-weight: 800; font-size: 60px; line-height: .95; }
.pl-sub { margin: 0; font-size: 14.5px; line-height: 1.5; color: var(--color-fg-2); max-width: 78ch; }
.pl-sub b, .pl-lead b { color: var(--color-fg); font-weight: 600; }
.pl-warns { margin: 2px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 4px; }
.pl-warns li { font-size: 13.5px; color: var(--color-warn); font-weight: 600; }
.pl-lead { margin: 0; font-size: 13.5px; color: var(--color-fg-2); line-height: 1.5; max-width: 90ch; }
.pl-split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 14px; align-items: start; }
.pl-inputs, .pl-answers { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.pl-rows { display: flex; flex-direction: column; gap: 10px; }
.pl-row { display: grid; grid-template-columns: minmax(0, 1fr) 176px; gap: 4px 14px; align-items: center; }
.pl-row > label { font-size: 13.5px; color: var(--color-fg); min-width: 0; }
.pl-hint { display: block; font-size: 12.5px; color: var(--color-fg-3); line-height: 1.4; margin: 0; }
.pl-ctl { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pl-ctl .in, .pl-ctl .sel { flex: 1 1 auto; min-width: 0; width: 100%; }
.pl-row .in { padding: 7px 10px; }
.pl-num { text-align: right; }
.pl-unit { flex: none; width: 30px; font-size: 12.5px; color: var(--color-fg-3); }
.pl-remove { align-self: flex-start; color: var(--color-warn); }
.pl-cases { border-top: 1px solid var(--color-line); padding-top: 12px; }
.pl-cases summary, .pl-table summary { cursor: pointer; font-size: 13.5px; font-weight: 600; color: var(--color-fg); }
.pl-cases[open] summary { margin-bottom: 6px; }
.pl-casetable { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 13.5px; }
.pl-casetable th { text-align: left; font-weight: 400; color: var(--color-fg); padding: 5px 8px 5px 0; }
.pl-casetable thead th { font-size: 12px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--color-fg-3); }
.pl-casetable td { padding: 5px 0 5px 8px; width: 118px; }
.pl-casetable .in { padding: 6px 8px; }

.pl-first { display: flex; flex-direction: column; gap: 12px; }
.pl-seg { display: flex; gap: 2px; height: 28px; width: 100%; }
.pl-seg > span { display: flex; align-items: center; padding-left: 6px; border-radius: 4px; font-size: 12px; font-weight: 700; color: var(--pl-ink); overflow: hidden; white-space: nowrap; min-width: 0; }
.pl-seg > span.pl-s-comm, .pl-seg > span.pl-s-disc { color: var(--pl-ink-strong); }
.pl-seg > span:focus-visible, .pl-trk:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
.pl-s-keep { background: var(--pl-keep); } .pl-s-comm { background: var(--pl-comm); } .pl-s-over { background: var(--pl-over); }
.pl-s-disc { background: var(--pl-disc); } .pl-s-cost { background: var(--pl-cost); } .pl-s-fees { background: var(--pl-fees); }
.pl-key { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 22px; font-size: 13.5px; }
.pl-key li { display: grid; grid-template-columns: 12px minmax(0, 1fr) auto; gap: 8px; align-items: center; color: var(--color-fg-2); }
.pl-key i, .pl-legend i { width: 12px; height: 12px; border-radius: 3px; display: block; flex: none; }
.pl-key b { color: var(--color-fg); font-weight: 600; }
.pl .neg, .pl-key b.neg { color: var(--color-warn); }

.pl-facts { display: grid; grid-template-columns: minmax(0, 1fr) auto; margin: 0; }
.pl-facts dt, .pl-facts dd { margin: 0; padding: 8px 0; border-top: 1px solid var(--color-line); font-size: 13.5px; }
.pl-facts dt:first-of-type, .pl-facts dt:first-of-type + dd { border-top: 0; padding-top: 0; }
.pl-facts dt { color: var(--color-fg-2); padding-right: 16px; }
.pl-facts dd { font-weight: 600; text-align: right; color: var(--color-fg); max-width: 300px; }
.pl-facts dd span { display: block; font-weight: 400; font-size: 12.5px; color: var(--color-fg-3); }
.pl-facts .em { font-weight: 700; color: var(--color-fg); background: var(--color-wash-money); }
.pl-facts dt.em { padding-left: 10px; border-radius: 8px 0 0 8px; }
.pl-facts dd.em { padding-right: 10px; border-radius: 0 8px 8px 0; }

.pl-scroll { overflow-x: auto; }
.pl-grid, .pl-months { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.pl-grid th, .pl-grid td, .pl-months th, .pl-months td { text-align: right; padding: 10px 12px; border-top: 1px solid var(--color-line); vertical-align: top; }
.pl-grid thead th, .pl-months thead th { border-top: 0; font-size: 12px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--color-fg-3); white-space: nowrap; }
.pl-grid th:first-child, .pl-months th:first-child { text-align: left; padding-left: 0; }
.pl-grid { min-width: 860px; }
.pl-grid thead th { white-space: normal; max-width: 130px; }
.pl-grid tbody th { font-weight: 400; }
.pl-grid tbody th span, .pl-grid td span { display: block; font-size: 12.5px; color: var(--color-fg-3); }
.pl-grid td b { display: block; font-weight: 700; color: var(--color-fg); white-space: nowrap; }
.pl-grid td span { white-space: nowrap; }
.pl-grid td.neg b { color: var(--color-warn); }
.pl-grid tr.on th, .pl-grid tr.on td { background: var(--color-wash-money); }
.pl-grid tr.on th:first-child { box-shadow: inset 3px 0 0 var(--color-accent-fill); padding-left: 10px; }
.pl-rowbtn { font: inherit; font-weight: 700; color: var(--color-fg); background: none; border: 0; padding: 0; cursor: pointer; text-align: left; }
.pl-rowbtn:hover { text-decoration: underline; text-underline-offset: 3px; }
.pl-months { min-width: 760px; font-size: 13px; }
.pl-months th, .pl-months td { padding: 6px 10px; white-space: nowrap; }
.pl-months tbody th { font-weight: 600; color: var(--color-fg-2); }
.pl-table { border-top: 1px solid var(--color-line); padding-top: 12px; }
.pl-table[open] summary { margin-bottom: 8px; }

.pl-chart { position: relative; }
.pl-chart svg { display: block; width: 100%; height: auto; touch-action: pan-y; }
.pl-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 12.5px; color: var(--color-fg-2); }
.pl-legend span { display: inline-flex; align-items: center; gap: 6px; }
.pl-c-expected { --c: var(--pl-expected); } .pl-c-cautious { --c: var(--pl-cautious); } .pl-c-strong { --c: var(--pl-strong); }
i.pl-c-expected, i.pl-c-cautious, i.pl-c-strong { background: var(--c); }
.pl-line { fill: none; stroke: var(--c); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.pl-dot { fill: var(--c); stroke: var(--color-surface); stroke-width: 2; }
.pl-gridline { stroke: var(--color-line); stroke-width: 1; }
.pl-zero { stroke: var(--color-fg-3); stroke-width: 1; }
.pl-cross { stroke: var(--color-fg-3); stroke-width: 1; stroke-dasharray: 3 3; }
.pl-tick { fill: var(--color-fg-3); font-size: 11.5px; font-family: var(--font-sans); }
.pl-end { fill: var(--color-fg); font-size: 12px; font-weight: 600; font-family: var(--font-sans); }
.pl-tip { position: absolute; top: 4px; transform: translateX(12px); pointer-events: none; background: var(--color-fg); color: var(--color-ink); border-radius: 8px; padding: 8px 10px; font-size: 12.5px; line-height: 1.5; display: flex; flex-direction: column; white-space: nowrap; z-index: 2; }
.pl-tip[data-side="left"] { transform: translateX(calc(-100% - 12px)); }
.pl-tip span { display: flex; align-items: center; gap: 6px; }
.pl-tip i { width: 10px; height: 10px; border-radius: 2px; display: block; }

.pl-tor { display: flex; flex-direction: column; gap: 8px; font-size: 13.5px; }
.pl-trow { display: grid; grid-template-columns: minmax(140px, 230px) minmax(0, 1fr) 190px; gap: 4px 14px; align-items: center; }
.pl-tname { color: var(--color-fg-2); min-width: 0; }
.pl-trk { position: relative; height: 18px; background: linear-gradient(var(--color-line), var(--color-line)) center / 1px 100% no-repeat; }
.pl-trk i { position: absolute; top: 3px; height: 12px; border-radius: 4px; display: block; }
.pl-d-up { background: var(--pl-up); } .pl-d-down { background: var(--pl-down); }
.pl-tval { text-align: right; color: var(--color-fg); font-weight: 600; white-space: nowrap; }
.planner .foot { margin-top: 10px; }

@media (max-width: 1080px) {
  .pl-split { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .pl-big { font-size: 44px; }
  .pl-row { grid-template-columns: minmax(0, 1fr) 132px; }
  .pl-key { grid-template-columns: minmax(0, 1fr); }
  .pl-facts { grid-template-columns: minmax(0, 1fr); }
  .pl-facts dt { padding: 8px 0 0; }
  .pl-facts dd { text-align: left; border-top: 0; padding: 0 0 8px; max-width: none; }
  .pl-facts dt.em, .pl-facts dd.em { padding-left: 10px; padding-right: 10px; border-radius: 0; }
  .pl-trow { grid-template-columns: minmax(0, 1fr) auto; }
  .pl-trow .pl-trk { grid-column: 1 / -1; grid-row: 2; }
  .pl-tor { gap: 14px; }
  .pl-casetable td { width: 96px; }
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
button { font: inherit; border: 0; cursor: pointer; }
h1, h2, p { margin: 0; }
.sample-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; justify-content: space-between; margin-bottom: 26px; }
.sample-tag { font-size: 13px; font-weight: 600; color: var(--color-wait); background: var(--color-wash-wait); border-radius: var(--radius-chip); padding: 5px 10px; }
.sample-wrap { max-width: 1180px; margin: 0 auto; padding: 26px max(16px, env(safe-area-inset-right, 0px)) 64px max(16px, env(safe-area-inset-left, 0px)); }
.sample-wrap .pub-lead { margin-bottom: 22px; }
