/* ==========================================================================
   Tap-Pay Agent Portal — OnSight's design, in Tap-Pay colours.

   Greg, 2026-10-07: "I want the entire thing to replicate OnSight - Same type
   of menu, flow, text, look. Everything." This file is that, for the desktop
   portal: one layer loaded AFTER css/app.css that redraws the shell (the
   topbar, the Dock, the Menu, the account menu), the page pattern (page head,
   tiles, cards, tabs, tables, badges, empty states, dialogs, toasts) and the
   type scale the way OnSight's app/css/app.css v2 (2026-09-23) draws them.

   Every rule here was read off OnSight's stylesheet; the values are OnSight's.
   What is Tap-Pay's is the colour: the brand tokens (--ink, --crimson,
   --accent, --danger, --steel, --mist, --hair) are NOT redefined, so the
   crimson still acts, danger still warns, and a white-label ISO's brand still
   flows through brand() at boot. tests/onsight_shell.mjs pins that.

   WHERE ONSIGHT'S NAVY APPEARS IN OUR INK
   OnSight's dock is a pale column (--rail-bg #F7F9FC) with navy-tinted text.
   Ours is the same pale column with ink-tinted text, and the accent (crimson)
   marks the place you are on, exactly where OnSight's Carolina blue would.
   ========================================================================== */

:root {
  /* ---- Page and surfaces ---------------------------------------------- */
  --page: #FFFFFF;
  --surface: #FFFFFF;
  --surface-line: var(--hair);
  --surface-line-hover: rgba(16, 24, 32, .28);
  --r-surface: 14px;
  --band: #F4F6F8;                /* OnSight's --band, in our slate */
  --tint: rgba(187, 32, 49, .10); /* OnSight's --tint (accent at 16%) — ours at 10%, crimson is louder than blue */

  /* A hairline that holds on a white page: ONE weight for every card, table
     and divider (OnSight v2). The old #DDE3E9 was drawn for a slate field. */
  --hair:      #D3DAE1;
  --hair-soft: #E6EAEE;
  --hair-strong: rgba(16, 24, 32, .34);

  /* Surfaces are flat. Shadow is for what floats. */
  --elev-surface: 0 0 #0000;
  --elev-raised:  0 1px 2px rgba(16, 24, 32, .06), 0 12px 32px -8px rgba(16, 24, 32, .24);
  --elev-overlay: 0 2px 6px rgba(16, 24, 32, .08), 0 28px 64px -16px rgba(16, 24, 32, .36);
  --shadow-sm:   0 0 #0000;
  --shadow-card: 0 0 #0000;
  --aura:        0 0 #0000;
  --shadow-pop:  var(--elev-raised);

  /* Glass is chrome only, and on a white page it is a whisper of ink. */
  --glass-bg:   rgba(16, 24, 32, .035);
  --glass-brd:  rgba(16, 24, 32, .12);
  --glass-blur: blur(18px) saturate(150%);
  --compact-menu-bg:   rgba(240, 242, 244, .96);
  --compact-menu-line: rgba(16, 24, 32, .12);

  /* ---- Type scale (OnSight) -------------------------------------------- */
  --fs-body:  1.0625rem;   /* 17px */
  --fs-label: .9375rem;    /* 15px */
  --fs-badge: .875rem;     /* 14px */
  --fs-field: var(--fs-body);
  --font: var(--f-body);

  /* ---- Motion (OnSight) ------------------------------------------------ */
  --t-press: 90ms; --t-quick: 150ms; --t-base: 240ms; --t-slow: 320ms;
  --ease-out: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ease-spring: cubic-bezier(0.32, 0.72, 0, 1);

  /* ---- The selected pill and the dock ---------------------------------- */
  --pill-on-bg:   color-mix(in srgb, var(--accent) 12%, var(--surface));
  --pill-on-line: var(--accent);
  --pill-on-ink:  var(--ink);
  --rail-bg:    #F7F8FA;
  --rail-ink:   rgba(16, 24, 32, .66);
  --rail-hover: rgba(16, 24, 32, .05);
  --dock-w: 104px;
  --topbar: 64px;
}
@media (prefers-reduced-motion: reduce) {
  :root { --t-press: 0ms; --t-quick: 0ms; --t-base: 0ms; --t-slow: 0ms; }
  .view > * { animation: none; }
}

/* ---- Generated: OnSight has nothing a person reads under 14px (foundation-ease: "nothing under 13px"; labels 15, body 17). ---- */
/* Every app.css rule that set 12–13.5px now reads at --fs-label; 10–11.5px at --fs-badge. Chrome and eyebrows are excluded. */
.mail__head,
.mail__subject,
.mail__open,
.stub__lines,
.lane__empty,
.dealcard__biz,
.dealcard__contact,
.dealcard__vol,
.launch__name,
.launch__hint,
.cal-col__empty,
.cal-cell__num,
.cal-row__time,
.calblk__n,
.undated,
.sl,
.whopays,
.kit__q,
.kit__meta,
.kit__note,
.menu__item,
.suggest__name,
.suggest__none,
.tl-item__body,
.taskrow__title,
.acc__a,
.kb-card__sum,
.ann__body,
.funnel-row__name,
.funnel-row__val,
.copyline,
.signote,
.seal,
.steps__t,
.fieldbar__hint,
.fieldbar__k,
.fieldbox__x,
.kvgrid,
.trail { font-size: var(--fs-label); }
.field > label,
.label,
.heat__h,
.heat__k,
.dealcard__age,
.pill__label,
.dash__sparkcap,
.dash__sparkkey,
.launch__count,
.delta,
.cal-chip,
.cal-chip__time,
.cal-col__dow,
.cal-dow span,
.cal-cell__more,
.cal-rail__dow,
.rday,
.calhr__t,
.calblk__s,
.bin__p,
.bin__k,
.stockpill,
.sl__d,
.sheet__k,
.sheet__once,
.stamp__k,
.stamp__t,
.kit__tag,
.sn,
.kit__gap,
.step__seq,
.step__name,
.suggest__meta,
.tl-item__meta,
.kb-card__dur,
.kb-card__cat,
.chart text,
.steps__n,
.docpage__no,
.fieldbox__label,
.kvgrid__k { font-size: var(--fs-badge); }

/* ---- Page and type -------------------------------------------------------- */

body {
  background: var(--page);
  background-attachment: scroll;
  font-size: var(--fs-body);
  line-height: 1.55;
}
.glass, .solid { box-shadow: none; }

/* OnSight has no eyebrow in a page head; the title is an h1 inside the page.
   Where the portal still draws an eyebrow (section heads, tiles), it is a
   plain small label, not a letterspaced slogan. */
.eyebrow { font-size: .8125rem; letter-spacing: .04em; font-weight: 600; color: var(--steel); text-transform: none; }
.h1, h1.h1 { font-size: 1.75rem; font-weight: 700; letter-spacing: -.01em; line-height: 1.2; }
.h2 { font-size: 1.125rem; letter-spacing: 0; line-height: 1.3; }
.h3 { font-size: 1.0625rem; letter-spacing: 0; }
.small { font-size: var(--fs-label); }
.tiny  { font-size: var(--fs-badge); }
.muted-2 { color: var(--ui-secondary, #5E6E7B); }
.hint { font-size: var(--fs-label); color: var(--steel); }

/* ---- Buttons: 44px, flat, OnSight's shape ------------------------------- */

.btn {
  height: 44px; min-height: 44px;
  padding: 10px 18px;
  border-radius: 11px;
  font-size: 1rem; font-weight: 600; letter-spacing: 0;
  transition: background-color var(--t-quick) var(--ease-out), border-color var(--t-quick) var(--ease-out), color var(--t-quick) var(--ease-out);
}
.btn svg { width: 18px; height: 18px; }
.btn--primary { box-shadow: none; }
.btn--ink { background: var(--accent); }
.btn--ink:hover { background: var(--accent-dark); }
.btn--ghost { background: var(--ui-surface, #fff); border-color: var(--hair-strong); color: var(--ink); backdrop-filter: none; -webkit-backdrop-filter: none; }
.btn--ghost:hover { background: var(--band); border-color: var(--hair-strong); }
.btn--quiet { color: var(--steel); }
.btn--danger { background: var(--ui-surface, #fff); color: var(--danger); border-color: var(--danger); }
.btn--danger:hover { background: var(--danger-lt); }
.btn--sm { height: 36px; min-height: 36px; padding: 0 14px; font-size: var(--fs-label); position: relative; }
.btn--sm::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 44px; transform: translateY(-50%); }
.btn--sm svg { width: 16px; height: 16px; }
.btn--icon { width: 44px; }
.btn--sm.btn--icon { width: 36px; }

/* ---- Fields ----------------------------------------------------------- */

.field { gap: 4px; }
/* A form grid's rows breathe the same 16px as the panel body around them.
   app.css has 14px; next to the panel's 16px column gap the two read as one
   uneven rhythm on Add an account (Greg, 2026-10-06). */
.grid-2 { gap: 16px; }
.field > label, .label {
  font-size: var(--fs-field); font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--steel);
}
.input, .select, .textarea {
  min-height: 44px; padding: 10px 12px; font-size: 1.0625rem; line-height: 1.25;
  /* background-COLOR, never the shorthand: the shorthand would wipe the
     select's chevron (css/selects.css draws it as a background-image). */
  border-radius: 11px; border-color: var(--ui-control-edge, rgba(16, 24, 32, .16)); background-color: var(--ui-surface, rgba(255, 255, 255, .88));
}
.input:focus, .select:focus, .textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3.5px var(--tint); }
.search svg { width: 18px; height: 18px; left: 13px; }
.search .input { padding-left: 40px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---- The page head (OnSight ui.page) ---------------------------------- */

.page__head { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; flex-wrap: wrap; }
.page__head h1 { margin: 0; }
.page__titles { min-width: 0; }
.page__actions { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.company-picker { width: auto; min-width: 210px; max-width: 100%; }
@media (max-width: 560px) {
  .page__actions:has(.company-picker) {
    flex: 1 1 100%; min-width: 0; max-width: 100%; margin-left: 0;
  }
  .page__actions .company-picker {
    width: 100%; min-width: 0; max-width: 100%;
  }
}
.page__back {
  display: inline-flex; align-items: center; gap: 4px; min-height: 44px;
  margin: -12px 0 -8px -2px; padding: 0 2px;
  font-size: 1.0625rem; font-weight: 500; color: var(--ui-link, var(--accent)); text-decoration: none;
}
.page__sub { margin: 4px 0 0; color: var(--steel); }

/* ---- Surfaces: cards, panels, tiles ------------------------------------ */

.panel, .stats, .deck {
  background: var(--surface); border: 1px solid var(--surface-line); border-radius: var(--r-surface);
  box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none;
}
.panel__head { padding: 16px 20px; border-bottom: 1px solid var(--hair); }
.panel__body { padding: 20px; }
.panel__foot { padding: 14px 20px; border-top: 1px solid var(--hair); }
/* The statement review places a hold count and an action beside this heading.
   Let long agent names wrap instead of squeezing into the action. */
.review-equipment-holds > .panel__head { flex-wrap: wrap; min-width: 0; }
.review-equipment-holds > .panel__head > .grow,
.review-equipment-holds > .panel__head > .tiny { min-width: 0; overflow-wrap: anywhere; }
.review-equipment-holds > .panel__head > .btn {
  min-width: 0; max-width: 100%; height: auto; margin-left: auto;
  white-space: normal; text-align: center;
}
.stat { padding: 18px 20px; border-right: 1px solid var(--hair); }
.stat__val { font-size: 1.5rem; }
.stat__sub { font-size: var(--fs-body); color: var(--mute, var(--steel)); }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; }
.tiles + * { margin-top: 14px; }
.tiles + .tiles { margin-top: 22px; }
.tiles + .tabs, .tiles + .toolbar { margin-top: 20px; }
.tiles:empty { display: none; }
.tile {
  --h: var(--steel);
  background: var(--surface); border: 1px solid var(--surface-line); border-radius: var(--r-surface);
  padding: 14px 16px; box-shadow: none; isolation: auto;
}
.tile::after { display: none; }
.tile .eyebrow { font-size: var(--fs-body); color: var(--steel); font-weight: 600; letter-spacing: 0; }
.tile__n { font-family: var(--f-body); font-size: 1.5rem; font-weight: 600; letter-spacing: -.01em; margin-top: 3px; }
.tile__s { font-size: var(--fs-body); color: var(--ui-secondary, #5E6E7B); margin-top: 2px; }
.tile--plain .tile__n, .tile--flat .tile__n { color: var(--ink); }
.tile--acct .tile__n { color: var(--ink); }
a.tile { transition: border-color var(--t-quick) var(--ease-out); }
a.tile:hover { border-color: var(--surface-line-hover); }
a.tile:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3.5px var(--tint); }

/* The universal spacing OnSight keeps in one place. */
.panel + .panel { margin-top: 14px; }
.panel + .tabs, .tbl__scroll + .tabs { margin-top: 14px; }
.chip + .sub, .chip + .hint, .chip + p { margin-top: 6px; }

/* ---- Tabs and pills ----------------------------------------------------- */

.tabs { gap: 8px; margin-bottom: 14px; }
.tab {
  min-height: 44px; min-width: 44px; display: inline-flex; align-items: center; justify-content: center;
  padding: 6px 13px; border-radius: 99px;
  font-size: var(--fs-label); font-weight: 500; color: var(--steel); background: var(--ui-surface, #fff); border: 1px solid var(--hair);
}
.tab:hover { color: var(--ink); background: var(--band); }
.tab.is-on { background: var(--pill-on-bg); border-color: var(--pill-on-line); color: var(--pill-on-ink); font-weight: 600; }
.tab.is-on .tab__count { color: var(--steel); }
.tab__count { font-size: var(--fs-badge); }

/* ---- Tables: hairline header, 56px rows -------------------------------- */

.tbl { font-size: var(--fs-body); }
.tbl th {
  padding: 14px 16px; font-size: var(--fs-label); font-weight: 600; letter-spacing: 0; text-transform: none;
  color: var(--ink-2); background: transparent; border-bottom: 1px solid var(--surface-line);
}
.tbl th:first-child, .tbl th:last-child { border-radius: 0; }
.tbl th.is-sortable:hover { color: var(--ink); background: var(--band); }
.tbl td { padding: 12px 16px; height: 56px; border-bottom: 1px solid var(--surface-line); }
.tbl tbody tr:nth-child(even) { background: transparent; }
.tbl tbody tr.is-clickable:hover { background: var(--band); }
.tbl tfoot td { font-size: var(--fs-label); }

/* ---- Badges and chips ----------------------------------------------------- */

.badge { height: auto; padding: 3px 10px; font-size: var(--fs-badge); font-weight: 600; letter-spacing: 0; line-height: 1.35; }
.chip { height: 34px; padding: 0 12px; font-size: var(--fs-badge); font-weight: 600; background: var(--band); color: var(--ink-2); border-color: transparent; }
.chip--sm { height: 28px; padding: 0 10px; }

/* ---- Empty states (OnSight ui.empty v2) ---------------------------------- */

.empty { background: var(--ui-surface, #fff); border: 1px solid var(--hair); border-radius: var(--r); padding: 40px; text-align: center; color: var(--steel); }
.empty > svg { width: 48px; height: 48px; color: var(--ink-2); margin: 0 auto 14px; }
.empty__title { font-size: 1.125rem; font-weight: 700; color: var(--ink); }
.empty__body { margin-top: 6px; font-size: var(--fs-body); color: var(--steel); max-width: 48ch; }

/* ---- Dialogs, menus, toasts ----------------------------------------------- */

.scrim { background: rgba(16, 24, 32, .5); }
.modal { width: min(480px, calc(100vw - 44px)); border-radius: var(--r-lg); box-shadow: var(--elev-overlay); }
.modal--wide { width: min(760px, calc(100vw - 44px)); }
.modal__head { padding: 16px 18px; border-bottom: 1px solid var(--hair); }
.modal__head .h2 { font-size: 1.125rem; }
.modal__head .eyebrow { display: none; }
.modal__body { padding: 18px; }
.modal__foot { padding: 14px 18px; border-top: 1px solid var(--hair); background: var(--paper); flex-wrap: wrap; gap: 8px;
  /* The foot carries its own paper background, so it keeps the dialog's bottom corners (Greg, 2026-10-30: rounded on top, square below). */
  border-radius: 0 0 var(--r-lg) var(--r-lg); }
/* A long action label must stay inside the foot on a narrow screen (review 2026-11-16: the bank change's
   "Send account ending in 6789" sat 1.5px past the left edge at 320 wide). Only a button wider than the foot
   is affected: it wraps its words and grows taller instead, as the ISO360 import row does. */
@media (max-width: 480px) {
  .modal__foot > .btn { max-width: 100%; min-width: 0; height: auto; min-height: 44px; padding-top: 9px; padding-bottom: 9px; white-space: normal; text-align: center; }
}
/* Dialog controls and drawer headings need a full touch/focus box; compact
   buttons in tables keep their existing density outside these containers. */
.modal .btn--sm, .drawer__head .btn--sm { height: 44px; min-height: 44px; }
.modal .btn--sm.btn--icon, .drawer__head .btn--sm.btn--icon { width: 44px; min-width: 44px; }
/* Outbox message reads exposed long subjects/recipients/tokens and a doubled
   panel gap: keep wrapping local and let its existing 12px flex gap own spacing. */
.outbox-message .modal__head .grow { min-width: 0; }
.outbox-message .modal__head .h2 { overflow-wrap: anywhere; }
.outbox-message__panels > .panel + .panel { margin-top: 0; }
.outbox-message__value { min-width: 0; flex-shrink: 1; overflow-wrap: anywhere; }
.outbox-message__text { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 12.5px; line-height: 1.65; }
.outbox-message__open {
  display: block; width: 100%; max-width: 100%; min-width: 0; min-height: 44px; padding: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left;
  color: var(--ink); background: transparent; border: 0; font: inherit; font-weight: 600; cursor: pointer;
}
.outbox-message__open:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 3px; }
.drawer { box-shadow: var(--elev-overlay); }
.menu { border-radius: var(--r); box-shadow: var(--elev-raised); background: var(--compact-menu-bg); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur); }
.menu__item { min-height: 44px; font-size: var(--fs-body); }

.toast {
  background: var(--ui-raised, var(--ink-2)); color: #fff; padding: 12px 16px; border-radius: 12px;
  font-size: var(--fs-body); line-height: 1.4; box-shadow: 0 6px 20px rgba(16, 24, 32, .22);
  min-width: 0; max-width: min(440px, calc(100vw - 36px));
}
.toast--err { background: var(--danger-lt); color: var(--danger); border: 1px solid var(--danger); }
.toast--err svg { color: var(--danger); }
.toast__sub { font-size: var(--fs-label); color: rgba(255, 255, 255, .85); }
.toast--err .toast__sub { color: inherit; }
/* .65 white on the toast's grey (app.css) read at about 3:1; the Undo toast's
   second line carries what the old "Are you sure?" used to warn about, so it
   has to be readable — .85 clears 4.5:1 (found on the Undo toasts, 2026-10-06). */

/* A toast that offers Undo — six seconds, then it goes. Every reversible
   delete in the portal uses it (T.undoToast); confirms stay for money and sending. */
.toast--action { align-items: center; }
.toast__undo { flex: none; min-height: 44px; padding: 0 12px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .5);
               background: transparent; color: #fff; font: inherit; font-size: var(--fs-label); font-weight: 700; cursor: pointer; }
.toast__undo:hover { background: var(--ui-surface, rgba(255, 255, 255, .14)); }
.toast__undo:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* ---- The pipeline board ------------------------------------------------- */

.lane { background: var(--band); border-color: var(--hair); }
.lane__name  { font-size: var(--fs-label); }
.lane__count, .lane__sum { font-size: var(--fs-badge); }
.dealcard { box-shadow: none; }

/* ==========================================================================
   THE SHELL — topbar + Dock, in place of the rail
   ========================================================================== */

.shell { display: block; }
.rail, .rail__scrim, .menu-btn, .railtip { display: none; }
.has-dock .main { margin-left: var(--dock-w); min-height: 100vh; min-height: 100dvh; transition: margin-left var(--t-base) var(--ease-out); }
.dock-collapsed .main { margin-left: 78px; }
.view { padding: 26px; max-width: none; }
.view:focus { outline: none; }

/* ---- Topbar: the mark, the company, Find, + New, your name -------------- */

.topbar {
  height: auto; min-height: var(--topbar);
  padding: 12px 26px; gap: 14px;
  background: var(--ui-surface, rgba(255, 255, 255, .86)); border-bottom: 1px solid var(--hair);
  backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur);
  position: sticky; top: 0; z-index: 30;
}
.topbar__title { display: none; }
.topbar__brand { display: block; flex: 0 0 auto; line-height: 0; position: relative; }
.topbar__brand img { display: block; height: 34px; width: auto; }
.topbar__biz { display: flex; align-items: center; gap: 8px; min-width: 0; flex: 0 1 auto; }
.topbar__biz b { font-size: 1.125rem; line-height: 1.2; overflow: hidden; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.topbar__brand + .topbar__biz { padding-left: 14px; border-left: 1px solid var(--hair); }
.topbar__tools { margin-left: auto; display: flex; align-items: center; gap: 10px; min-width: 200px; flex: 0 5 520px; }
.topbar__tools + .topbar__org { margin-left: 6px; }
.topbar__biz + .topbar__org { margin-left: auto; }
.topbar__org {
  display: flex; align-items: center; gap: 10px; color: inherit; margin: -6px -10px; padding: 6px 10px;
  border: 0; border-radius: 10px; background: transparent; font: inherit; cursor: pointer; min-height: 44px; position: relative;
}
/* House imports and Form Library exposed full-portal overflow from long names.
   Let the existing Account label wrap without hiding or abbreviating it. */
.topbar__org b { font-size: 1.125rem; white-space: normal; overflow-wrap: anywhere; }
/* A long company label must not squeeze a short Account name into fragments. */
@media (min-width: 901px) { .topbar__org { min-width: 12ch; } }
.topbar__org:hover, .topbar__org[aria-expanded="true"] { background: var(--band); }
.topbar__org:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.topbar__chev { color: var(--steel); font-size: .875rem; }

.topfind { position: relative; flex: 1 1 auto; min-width: 0; display: flex; align-items: center; }
.topfind__icon { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--steel); display: flex; pointer-events: none; }
.topfind__box {
  width: 100%; min-height: 44px; padding: 8px 40px 8px 42px; border-radius: 99px;
  background: var(--ui-surface, #fff); border: 1px solid var(--hair-strong); font-size: 1.0625rem; color: var(--ink);
}
.topfind__box::placeholder { color: var(--ui-secondary, #5E6E7B); }
.topfind__box:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3.5px var(--tint); }
.topfind__key {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  font: 600 .8125rem/1 var(--f-mono); color: var(--steel); border: 1px solid var(--hair); border-radius: 6px; padding: 3px 6px; background: var(--band);
}
.topnew { flex: none; display: inline-flex; align-items: center; gap: 6px; }
.topnew > span:first-child { font-size: 1.375rem; line-height: 1; font-weight: 500; }
/* The processor's notices (G8): the "+ New" button's shape, with the house badge for the unread count. */
.topnotices { flex: none; display: flex; align-items: center; }
.topnotices[hidden] { display: none; }
.topnotices__btn svg { width: 18px; height: 18px; color: var(--steel); flex: none; }
.topnotices__count { margin-left: 2px; padding: 1px 8px; }
.menu.menu--notices { overflow-y: auto; overscroll-behavior: contain; max-width: min(560px, calc(100vw - 16px)); }
.menu.menu--notices .menu__item:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }

/* ---- The account menu under your name ----------------------------------- */

.orgmenu {
  position: fixed; z-index: 70; min-width: 250px; max-width: min(340px, calc(100vw - 24px));
  background: var(--compact-menu-bg); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-brd); border-radius: var(--r); box-shadow: var(--elev-raised); padding: 4px 0;
  animation: pop .13s ease;
}
.orgmenu__who { padding: 10px 12px 12px; }
.orgmenu__who b { display: block; }
.orgmenu__who span { display: block; margin-top: 2px; font-size: var(--fs-label); color: var(--ui-secondary, #5E6E7B); }
.orgmenu__section { display: flex; flex-direction: column; padding: 4px 0; border-top: 1px solid var(--hair); }
.orgmenu__item {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 8px 12px;
  background: none; border: 0; color: var(--ink); font: inherit; text-align: left; text-decoration: none; cursor: pointer;
}
.orgmenu__item:hover, .orgmenu__item:focus-visible { background: var(--band); outline: 0; }
.orgmenu__item--danger { color: var(--danger); }
.compact-menu__icon { display: inline-grid; place-items: center; flex: 0 0 18px; width: 18px; color: var(--ui-link, var(--accent-dark)); font-size: 1.0625rem; line-height: 1; }

/* ---- The Dock ------------------------------------------------------------- */

.dock {
  position: fixed; inset: 0 auto 0 0; z-index: 58; width: var(--dock-w);
  display: flex; flex-direction: column; align-items: stretch; gap: 6px; overflow: visible;
  padding: calc(14px + env(safe-area-inset-top, 0px)) 6px calc(14px + env(safe-area-inset-bottom, 0px));
  background: var(--rail-bg); box-shadow: inset -1px 0 0 var(--hair);
  transition: width var(--t-base) var(--ease-out);
}
.dock__head { position: relative; flex: 0 0 auto; display: flex; flex-direction: column; align-items: stretch; }
.dock__sep { flex: 0 0 1px; margin: 4px 8px; background: var(--hair); }
.dock__places {
  display: flex; flex-direction: column; align-items: stretch; gap: 6px; flex: 1 1 auto; min-height: 0;
  overflow-y: auto; overflow-x: hidden; scrollbar-width: none;
}
.dock__places::-webkit-scrollbar { display: none; }
.dock__places.has-more {
  -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 44px), transparent);
          mask-image: linear-gradient(to bottom, #000 calc(100% - 44px), transparent);
}
.dockitem {
  position: relative; display: flex; flex: 0 0 auto; flex-direction: column; align-items: center; gap: 4px;
  width: 100%; min-width: 0; min-height: 68px; padding: 10px 4px 8px; border: 0; border-radius: 12px; background: transparent;
  color: var(--rail-ink); font: 500 .875rem/1.15 var(--font); text-decoration: none; cursor: pointer; text-align: center;
  transition: background-color var(--t-quick) var(--ease-out), color var(--t-quick) var(--ease-out);
}
.dockitem__icon { font-size: 1.375rem; line-height: 1; display: inline-flex; }
.dockitem__icon svg { width: 24px; height: 24px; }
.dockitem__label { text-wrap: balance; overflow-wrap: normal; hyphens: manual; }
.dockitem:hover, .dockitem:focus-visible { background: var(--rail-hover); color: var(--ink); }
.dockitem:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.dockitem.is-on { background: transparent; color: var(--ink); font-weight: 600; }
.dockitem.is-on .dockitem__icon { color: var(--ui-link, var(--accent)); }
.dockitem.is-on::before { content: ""; position: absolute; left: -6px; top: 10px; bottom: 10px; width: 3px; border-radius: 0 3px 3px 0; background: var(--accent); }
.dockitem--all .dockitem__icon { color: var(--ui-link, var(--accent-dark)); }
.dockitem__badge {
  position: absolute; top: 6px; right: 10px; min-width: 18px; height: 18px; padding: 0 5px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--danger); color: #fff; border-radius: 9px; font: 700 .75rem/1 var(--font);
}
.dock__more {
  flex: 0 0 auto; min-height: 44px; margin: 0; padding: 6px 4px; border: 0; border-radius: 12px;
  background: var(--rail-hover); color: var(--ink); font: 600 .875rem/1.1 var(--font); cursor: pointer; white-space: normal;
}
.dock__more:hover { background: rgba(16, 24, 32, .09); }
.docksay { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* The ‹ tab hanging off the column's edge, level with Menu. */
.dock__toggle {
  position: absolute; z-index: 1; left: calc(100% + 6px); top: 50%; margin-top: -14px;
  display: grid; place-items: center; width: 16px; height: 28px; min-width: 0; min-height: 0; padding: 0;
  border: 1px solid var(--hair); border-left: 0; border-radius: 0 8px 8px 0; background: var(--rail-bg);
  color: var(--steel); font-size: 1.0625rem; line-height: 1; cursor: pointer; transition: left .18s ease;
}
.dock__toggle::after { content: ""; position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; transform: translate(-50%, -50%); }
.dock__toggle:hover, .dock__toggle:focus-visible { color: var(--ink); }
.dock__toggle:focus-visible { outline: 2px solid var(--accent); }
.dock__toggleicon { display: block; transition: transform .18s ease; }
.dock-collapsed .dock { width: 78px; padding-left: 4px; padding-right: 4px; }
.dock-collapsed .dockitem { min-height: 56px; padding: 10px 2px 8px; }
.dock-collapsed .dockitem__label { display: none; }
.dock-collapsed .dockitem.is-on::before { left: -4px; }
.dock-collapsed .dock__toggleicon { transform: rotate(180deg); }

/* ---- The Menu dialog: every place, grouped, with ☆ pins ------------------- */

.modal--places { width: min(1180px, calc(100vw - 44px)); height: min(640px, calc(100vh - 44px)); max-height: calc(100vh - 44px); }
.modal--places .modal__body { flex: 1; min-height: 0; overflow-y: auto; }
.dockboard__search { display: block; width: 100%; min-height: 44px; margin-bottom: 14px; }
.dockboard__groups { columns: 160px; column-gap: 14px; padding: 1px; }
@media (min-width: 1100px) { .dockboard__groups { columns: 5 170px; } }
.dockgroup { min-width: 0; break-inside: avoid; margin: 0 0 14px; }
.dockgroup:last-child { margin-bottom: 0; }
.dockgroup__head { display: flex; align-items: center; gap: 6px; margin: 0 0 6px; font-size: var(--fs-badge); font-weight: 600; color: var(--ui-secondary, #5E6E7B); }
.dockgroup__list { display: flex; flex-direction: column; gap: 2px; }
.dockplace { display: flex; align-items: center; gap: 6px; border-radius: var(--r-sm); }
.dockplace:hover { background: var(--band); }
.dockplace__go { display: flex; flex: 1 1 auto; min-width: 0; align-items: center; gap: 9px; padding: 7px 8px; min-height: 44px; color: var(--ink); text-decoration: none; }
.dockplace__icon { flex: 0 0 20px; color: var(--ui-link, var(--accent-dark)); display: inline-flex; }
.dockplace__icon svg { width: 20px; height: 20px; }
.dockplace__label { overflow-wrap: anywhere; text-wrap: balance; line-height: 1.25; }
.dockplace__pin {
  flex: 0 0 auto; width: 34px; height: 34px; min-width: 0; min-height: 0; padding: 0; border: 0; border-radius: 50%;
  background: transparent; color: var(--steel); font-size: 1.25rem; cursor: pointer; position: relative;
}
.dockplace__pin::after { content: ""; position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; transform: translate(-50%, -50%); }
.dockplace__pin:hover, .dockplace__pin.is-on { color: var(--amber); background: var(--amber-lt); }
.dockboard__hint { margin-right: auto; align-self: center; color: var(--steel); font-size: var(--fs-label); }
.dockboard__none { color: var(--steel); padding: 20px 4px; }

/* ---- Sign in: one centred card, as OnSight does it ------------------------- */

.login { grid-template-columns: 1fr; background: var(--page); }
.login__aside { display: none; }
.login__form { justify-content: center; padding: 40px 20px; }
.login__card { width: 100%; min-width: 0; max-width: 420px; padding: 32px 30px 28px; background: var(--ui-surface, #fff); border: 1px solid var(--hair); border-radius: var(--r-lg); }
.login__card .h1, .login__card .h2 { font-size: 1.5rem; }
.login__portal { text-align: center; font-size: 1.375rem; font-weight: 700; letter-spacing: .01em; color: var(--ink); margin: 0 0 30px; }
.login__title { margin: 0 0 14px; }
/* The lockup. The old sign-in carried the WHITE logo on a navy side panel;
   this layer hides that panel (above), and the logo vanished with it (Greg,
   2026-10-06: "there is no Tap-Pay Solutions logo when signing into the
   agent portal", then "make the logo the stackable logo and nice and large
   and centered above the login credentials"). One rule puts the stacked
   logo, large and centered, at the top of every door card — sign in,
   verify it is you, reset — so none can lose it again. */
.login__card::before {
  content: ""; display: block; height: 132px; margin: 4px auto 26px;
  background: url("../assets/logo-stacked.png") center / contain no-repeat;
}

/* Keep the normal CAPTCHA's 300px width inside the card on ordinary phones.
   When the content column drops below 300px, captcha.js selects the provider's
   compact widget instead of letting its intrinsic width push the page sideways. */
@media (max-width: 420px) {
  .login__form { padding-left: 16px; padding-right: 16px; }
  .login__card { padding-left: 22px; padding-right: 22px; }
  /* Keep the provider's default 300px widget from setting the card's min-content
     width. captcha.js measures this bounded slot and selects compact mode when
     the actual available space is narrower. */
  .login__form, .login__card, .login__card form, .login__card .field,
  .login__captcha { min-width: 0; }
  .login__captcha { width: 100%; max-width: 100%; }
}
@media (max-width: 359px) {
  .login__form { padding-left: 12px; padding-right: 12px; }
  .login__card { padding-left: 16px; padding-right: 16px; }
}

/* ---- Narrow windows ---------------------------------------------------------
   Phones are redirected to mobile.html before any of this draws; this is a
   narrow desktop window. The dock folds to its icon strip and the Find box
   steps out of the way of the name. */
@media (max-width: 900px) {
  .has-dock .main { margin-left: 78px; }
  .dock { width: 78px; padding-left: 4px; padding-right: 4px; }
  .dockitem { min-height: 56px; padding: 10px 2px 8px; }
  .dockitem__label { display: none; }
  .dockitem.is-on::before { left: -4px; }
  .dock__toggle { display: none; }
  .topbar { padding: 10px 14px; flex-wrap: wrap; }
  .topbar__tools { display: none; }
  /* Match the sibling rule above: the hidden tools still precede Account.
     Keep its wrapped row right-aligned so the existing menu stays on screen. */
  .topbar__tools + .topbar__org { max-width: 100%; margin-left: auto; }
  .view { padding: 16px; }

  /* Settings contains long referral text, forms and optional install-hour
     controls. A plain `1fr` track still has an automatic min-content floor;
     cap this screen's collapsed split and its children at the available width. */
  .split--profile { grid-template-columns: minmax(0, 1fr); }
  .split--profile > .col,
  .split--profile .panel,
  .split--profile .panel__body { min-width: 0; }
  .split--profile .grid-2 { grid-template-columns: minmax(0, 1fr); }

  /* The full new-account screen contains two nested form/pricing grids. Once
     the page split collapses, keep their automatic min-content floors from
     widening the narrow viewport; the separate quick-add modal is unchanged. */
  .account-new-page {
    min-width: 0;
    grid-template-columns: minmax(0, 1fr);
  }
  .account-new-page > .col,
  .account-new-page .panel,
  .account-new-page .panel__body,
  .account-new-page .panel__body--flush,
  .account-new-page form,
  .account-new-page .grid-2 > * { min-width: 0; }
  .account-new-page .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .account-new-page .panel__foot { min-width: 0; flex-wrap: wrap; }
  .account-new-page .panel__foot > .grow,
  .account-new-page .panel__foot > .save-feedback {
    flex-basis: 100%; min-width: 0; margin-left: 0; overflow-wrap: anywhere;
  }
  .account-new-page a[href="#/knowledge"] {
    min-width: 0; max-width: 100%; height: auto; min-height: 44px;
    white-space: normal; overflow-wrap: anywhere;
  }

  .referral-page { min-width: 0; grid-template-columns: minmax(0, 1fr); }
  .referral-page > *,
  .referral-page .panel,
  .referral-page .panel__body,
  .referral-page form,
  .referral-page .grid-2 > * { min-width: 0; }
  .referral-page .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .referral-page .panel__foot { flex-wrap: wrap; }
  .referral-page .panel__foot > .grow { flex-basis: 100%; min-width: 0; }
  .referral-page .copyline { min-width: 0; flex-wrap: wrap; }
  .referral-page .copyline .grow.truncate {
    flex-basis: 100%; min-width: 0; white-space: normal;
    overflow: visible; overflow-wrap: anywhere; text-overflow: clip;
  }
  .referral-page .leader { flex-wrap: wrap; }
  .referral-page .leader__dots { display: none; }
  .referral-page .leader__val { max-width: 100%; overflow-wrap: anywhere; }

  /* Keep the full submission URL readable when the card narrows. */
  .split--profile .copyline { min-width: 0; }
  .split--profile .copyline .grow.truncate {
    min-width: 0; overflow: visible; overflow-wrap: anywhere;
    text-overflow: clip; white-space: normal;
  }
  .split--profile .copyline > .btn { flex: none; }
  .split--profile .taskrow > .grow { min-width: 0; }
}

@media (max-width: 520px) {
  .review-equipment-holds > .panel__head > .btn {
    flex: 1 1 100%; margin-left: 0;
  }
  /* Company cards on Admin → Agents keep their heading controls inside the
     card. Their account tables retain their own horizontal scroll wrapper. */
  .admin-agent-company > .panel__head {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .admin-agent-company > .panel__head > .grow {
    flex: 1 1 100%;
    min-width: 0;
  }
  .admin-agent-company > .panel__head > .row {
    flex: 0 1 auto;
    flex-wrap: wrap;
    min-width: 0;
    max-width: 100%;
  }
  .admin-agent-company > .panel__head > .row > .btn {
    min-width: 0;
    max-width: 100%;
  }

  /* Settings security and connection controls keep their full labels while
     wrapping inside the collapsed panel instead of widening the page. */
  .split--profile .panel__body > div > .btn {
    max-width: 100%; min-width: 0; height: auto; white-space: normal;
    justify-content: flex-start; text-align: left;
  }
  .split--profile .panel__body > .row.gap-12 { flex-wrap: wrap; }
  .split--profile .panel__body > .row.gap-12 > .btn {
    min-width: 0; max-width: 100%; white-space: normal;
  }

  /* Small Settings cards must wrap long mailbox addresses and help copy. Keep
     the support icon/action in its flex row and let the email text use the
     available width. */
  .split--profile .panel__body > .small.muted {
    min-width: 0; overflow-wrap: anywhere;
  }
  .split--profile .panel__body > a[href^="mailto:"] {
    min-width: 0; max-width: 100%; overflow-wrap: anywhere;
  }
  .split--profile .panel__foot { min-width: 0; flex-wrap: wrap; }
  .split--profile .panel__foot > .grow {
    min-width: 0; overflow-wrap: anywhere;
  }

  /* The install-hours editor uses native time inputs in a fixed-width flex
     row. Give the day label its own line, then keep both complete controls in
     bounded grid tracks on narrow phones. */
  .split--profile .panel__body .row:has(> label > input[type="checkbox"]) {
    display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center; gap: 8px;
  }
  .split--profile .panel__body .row:has(> label > input[type="checkbox"]) > label {
    grid-column: 1 / -1; max-width: 100%;
  }
  .split--profile .panel__body .row:has(> label > input[type="checkbox"]) > input[type="time"] {
    width: 100%; min-width: 0; max-width: 100%;
  }
}

@media (max-width: 640px) {
  /* Agreement values such as role names and membership dates stack cleanly
     when the Settings column is narrower than a dotted leader can support. */
  .settings-terms .leader {
    display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px;
  }
  .settings-terms .leader__dots { display: none; }
  .settings-terms .leader__val {
    min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere;
  }
  .settings-terms .panel__body > p.tiny.muted-2 { min-width: 0; overflow-wrap: anywhere; }
}

/* ==========================================================================
   THE PAGE PATTERN — what app.css drew in ink, OnSight draws on white
   ========================================================================== */

/* The dashboard's "one thing that needs a decision" was an ink slab with a
   crimson edge. OnSight has no dark slabs: it is a white card with the accent
   edge, and the figure in the accent. */
.callout { background: var(--surface); color: var(--ink); border: 1px solid var(--hair); border-left: 4px solid var(--accent); box-shadow: none; }
.callout__q { font-size: var(--fs-body); letter-spacing: 0; }
.callout__n { font-family: var(--f-body); font-size: 1.5rem; letter-spacing: -.01em; color: var(--ui-link, var(--accent)); }
.callout__by { font-family: var(--f-body); font-size: var(--fs-label); font-weight: 500; letter-spacing: 0; text-transform: none; color: var(--steel); }
.callout__ghost { color: var(--tint); }
.callout .btn--ink-ghost, .idhead .btn--ink-ghost { background: var(--ui-surface, #fff); border-color: var(--hair-strong); color: var(--ink); }

/* The big residual figure: the body face, tabular, as OnSight's hero figure. */
.dash__n { font-family: var(--f-body); font-size: 2.25rem; letter-spacing: -.02em; }
.dash__sub { font-size: var(--fs-label); margin-top: 6px; }
.dashcard { box-shadow: none; border-radius: var(--r-surface); }
.todo { min-height: 44px; padding: 8px 10px; align-items: center; }
.todo__n { font-family: var(--f-body); font-size: 1.375rem; letter-spacing: -.01em; }
.todo__d { font-family: var(--f-body); font-size: var(--fs-label); color: var(--steel); }
.todo__go { font-size: var(--fs-label); min-height: 44px; display: inline-flex; align-items: center; }
.morebar { font-size: var(--fs-body); }
.morebar > span { font-family: var(--f-body); font-size: var(--fs-label); letter-spacing: 0; text-transform: none; color: var(--steel); }

/* The account record's identity band: a white card, not an ink one. */
.idhead { background: var(--surface); color: var(--ink); border: 1px solid var(--hair); box-shadow: none; }
.idhead .eyebrow { color: var(--steel); }
.idhead__who { font-size: 1.75rem; letter-spacing: -.01em; }
.idhead__actions { flex: none; }
.idhead__meta { font-size: var(--fs-label); color: var(--steel); }
.idhead__meta a { color: var(--steel); }
.idhead__meta a:hover { color: var(--ink); }
.idhead__meta .mono { color: var(--ink); }
.idhead__facts { border-top-color: var(--hair); font-size: var(--fs-label); color: var(--ink); }
.idhead__fact-label { color: var(--steel); font-size: 12px; }
.idhead__fact-val { color: var(--ink); }
a.idhead__fact-val { color: var(--ui-link, var(--accent)); }
a.idhead__fact-val:hover { color: var(--ink); text-decoration: underline; }

/* Account Record: keep merchant identity readable beside compact contact and
   navigation actions; wrap the actions before they consume the name's width. */
.idhead__summary { min-width: 0; flex: 1 1 280px; }
.idhead__who, .idhead__meta { overflow-wrap: anywhere; }
.idhead__controls { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; min-width: 0; max-width: 100%; }
.idhead__contact { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; max-width: 100%; }
.idhead__contact .btn, .idhead__actions .btn { min-height: 44px; }
.idhead__actions .btn--icon { min-width: 44px; }

/* Account Record Identity: three full-width fact groups keep saved Sales
   estimates apart from merchant/contact facts and the existing quote panel. */
.account-identity__groups { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.account-identity__group { min-width: 0; padding: 16px; background: var(--band); border: 1px solid var(--hair); border-radius: var(--r-sm); }
.account-identity__group-title { margin: 0 0 12px; color: var(--ink); font-size: 1rem; line-height: 1.25; }

@media (max-width: 520px) {
  /* Long merchant emails and reach-out labels belong to this account header;
     keep them readable inside the record without changing shared controls. */
  .idhead__meta { min-width: 0; }
  .idhead__meta a[href^="mailto:"] {
    min-width: 0; max-width: 100%; overflow-wrap: anywhere;
  }
  .idhead__facts { gap: 6px 12px; }
  .idhead__facts a[href^="mailto:"] {
    min-width: 0; max-width: 100%; overflow-wrap: anywhere;
  }
  .idhead__actions { flex: 0 1 auto; flex-wrap: wrap; min-width: 0; max-width: 100%; }
  .idhead__actions .btn {
    min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere;
  }
  /* Account Record: the icon's 44px phone target must survive action wrapping. */
  .idhead__actions .btn--icon { width: 44px; min-width: 44px; }
  .idhead__controls { width: 100%; align-items: flex-start; }
  .idhead__contact { justify-content: flex-start; }
  .account-identity__group { padding: 14px; }
  .idhead ~ .rc-acts .btn {
    min-width: 0; max-width: 100%; height: auto; white-space: normal;
    text-align: center; overflow-wrap: anywhere;
  }
}

/* Selected pills: a tint of the accent with its line, never a solid ink slab. */
.chip.is-on, .tab--empty.is-on, .fieldbar__k.is-on { background: var(--pill-on-bg); border-color: var(--pill-on-line); color: var(--pill-on-ink); }
.badge--ink { background: var(--band); color: var(--ink); }
.kb-card__thumb { background: var(--band); }
.kb-card:hover { box-shadow: none; transform: none; border-color: var(--surface-line-hover); }
.avatar { background: var(--band); color: var(--ink); font-size: .875rem; }
.avatar--sm { font-size: .75rem; }

/* Section heads (App.sectionHead): the eyebrow above a title reads as a
   quiet label, and the title at OnSight's h2 size. */
.sect__h .h2, .panel__head .h2 { font-size: 1.125rem; }

/* ---- The pipeline board: flat lanes on a white page ----------------------
   app.css floats glass lanes on a painted "aurora" field. OnSight has no
   field: the lanes are a band with a hairline, the cards are white with a
   hairline, and the page behind them is the page. Same for the frosted
   accounts ledger and the quiet variant. */
.aurora, .quietaura .aurora { background: none; border: 0; border-radius: 0; padding: 0; overflow: visible; }
.board--aurora .lane, .quietaura .board--aurora .lane {
  background: var(--band); border: 1px solid var(--hair); box-shadow: none;
  backdrop-filter: none; -webkit-backdrop-filter: none;
}
.board--aurora .lane.is-over { background: var(--pill-on-bg); border-color: var(--accent); }
.board--aurora .lane--lost { background: var(--paper); }
.board--aurora .dealcard, .board--aurora .lane--lost .dealcard {
  background: var(--surface); border: 1px solid var(--hair); box-shadow: none;
}
.board--aurora .lane__empty { border-color: var(--hair); color: var(--steel); }
.frostpanel {
  background: var(--surface); border: 1px solid var(--hair); box-shadow: none;
  backdrop-filter: none; -webkit-backdrop-filter: none;
}
.frostpanel .tbl th { background: transparent; color: var(--ink-2); }
.frostpanel .tbl td { border-bottom: 1px solid var(--hair-soft); }
.frostpanel .tbl tbody tr:nth-child(even) { background: transparent; }
.frostpanel .tbl tbody tr.is-clickable:hover { background: var(--band); }
.frostpanel .pager, .frostpanel .panel__foot, .frostpanel .panel__head { border-color: var(--hair); }
.deck { box-shadow: none; }

/* Page-head actions are full buttons, as OnSight's are (min 44px), even
   where a view still asks for the compact size it used in the old topbar. */
.page__actions .btn--sm { height: 44px; min-height: 44px; padding: 0 18px; font-size: 1rem; }
.page__actions .btn--sm svg { width: 18px; height: 18px; }

/* Money is tabular in the body face, as OnSight sets it — not a monospace
   face. Codes (a MID) keep .mono. */
.num, .tile__n, .stat__val, .dash__n, .todo__n, .callout__n { font-family: var(--f-body); letter-spacing: 0; font-variant-numeric: tabular-nums; }

/* ---- Moving a pin: the pin lifts where it stands, a dashed gap holds its place -- */
.dockitem.is-lifting {
  position: fixed; z-index: 70; pointer-events: none; margin: 0;
  background: var(--surface); color: var(--ink); box-shadow: var(--elev-raised);
}
.dockitem--gap { border: 1.5px dashed var(--hair-strong); background: var(--rail-hover); min-height: 0; padding: 0; }
.dock__places.is-arranging { overflow-y: hidden; }
body.is-moving-pin { user-select: none; -webkit-user-select: none; cursor: grabbing; }
.dockitem[data-pin] { touch-action: pan-y; cursor: grab; }

/* Shared desktop button depth from Greg's approved public reference. Keep the
   variant background and existing hit targets; the translucent gradient adds
   light without replacing semantic colors or the global focus-visible outline. */
@media (min-width: 1200px) {
  /* Forgot password exposed the dark lower edge on transparent actions.
     Quiet controls keep their existing flat hover and keyboard treatment. */
  .btn:not(.btn--quiet) {
    --btn-depth-glow: color-mix(in srgb, var(--ink) 18%, transparent);
    background-image: linear-gradient(180deg, transparent 0%, rgba(0,0,0,.06) 100%);
    transition: background-color var(--t-quick) var(--ease-out), border-color var(--t-quick) var(--ease-out), color var(--t-quick) var(--ease-out), box-shadow var(--t-quick) var(--ease-out), transform .08s ease;
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,.34),
      inset 0 -1px 0 rgba(0,0,0,.20),
      0 1px 2px rgba(16,24,32,.16),
      0 7px 16px -9px var(--btn-depth-glow);
  }
  .btn--primary { --btn-depth-glow: color-mix(in srgb, var(--accent) 30%, transparent); }
  .btn--ink { --btn-depth-glow: color-mix(in srgb, var(--accent) 28%, transparent); }
  .btn--ghost, .btn--quiet, .btn--ink-ghost { --btn-depth-glow: color-mix(in srgb, var(--ink) 16%, transparent); }
  .btn--danger, .btn--danger-solid { --btn-depth-glow: color-mix(in srgb, var(--danger) 28%, transparent); }

  /* Variant hover rules use background shorthand; restore the common light
     layer afterward while leaving each variant's computed background-color. */
  .btn:not(.btn--quiet):hover { background-image: linear-gradient(180deg, transparent 0%, rgba(0,0,0,.06) 100%); }

  .btn:not(.btn--quiet):not(:disabled):not([aria-disabled="true"]):not([aria-busy="true"]):active {
    background-image: linear-gradient(180deg, rgba(0,0,0,.09), rgba(255,255,255,.05));
    box-shadow:
      inset 0 1px 2px rgba(0,0,0,.22),
      inset 0 -1px 0 rgba(255,255,255,.28),
      0 1px 2px rgba(16,24,32,.14);
  }
  .btn:disabled,
  .btn[aria-disabled="true"],
  .btn[aria-busy="true"] {
    background-image: none;
    box-shadow: none;
    transform: none;
  }
}

/* Private synthetic monthly review. The normal Residuals page is unchanged;
   this interior has no navigation entry while September posting is dark. */
.bulk-workspace { display: grid; gap: 16px; min-width: 0; }
.bulk-workspace > .panel + .panel { margin-top: 0; }
.bulk-workspace__banner {
  padding: 14px 16px; border: 1px solid var(--hair); border-left: 4px solid var(--accent);
  border-radius: var(--radius, 10px); background: var(--band); font-weight: 600;
}
.bulk-workspace__status { min-height: 22px; color: var(--ink-2); overflow-wrap: anywhere; }
.bulk-workspace__toolbar { display: flex; align-items: end; flex-wrap: wrap; gap: 12px; min-width: 0; }
.bulk-workspace__toolbar label { display: grid; gap: 6px; min-width: min(100%, 280px); }
.bulk-workspace__stats { display: grid; gap: 16px; min-width: 0; }
.bulk-workspace__stat {
  display: grid; gap: 6px; min-width: 0; padding: 16px;
  border: 1px solid var(--hair); border-radius: var(--radius, 10px); background: var(--surface);
}
.bulk-workspace__stat > span, .bulk-workspace__stat > small { color: var(--ink-2); }
.bulk-workspace__stat > strong { font-size: 1.125rem; overflow-wrap: anywhere; }
.bulk-workspace__panel, .bulk-workspace__body { min-width: 0; }
.bulk-workspace__body { display: grid; gap: 16px; }
.bulk-workspace__body > p { margin: 0; }
.bulk-workspace__rows { display: grid; gap: 12px; min-width: 0; }
.bulk-workspace__row {
  display: flex; justify-content: space-between; flex-wrap: wrap;
  gap: 8px 16px; min-width: 0; padding: 12px 0; border-bottom: 1px solid var(--hair);
}
.bulk-workspace__row:last-child { border-bottom: 0; padding-bottom: 0; }
.bulk-workspace__wrap { min-width: 0; overflow-wrap: anywhere; }
.bulk-workspace__decision, .bulk-workspace__candidate {
  display: grid; gap: 12px; min-width: 0; padding: 16px;
  border: 1px solid var(--hair); border-radius: var(--radius, 10px);
}
.bulk-workspace__decision-text, .bulk-workspace__candidate-title { min-width: 0; }
.bulk-workspace__decision-text p { margin: 6px 0 0; overflow-wrap: anywhere; }
.bulk-workspace__reason, .bulk-workspace__candidate label { display: grid; gap: 6px; min-width: 0; }
.bulk-workspace__reason textarea, .bulk-workspace__candidate textarea,
.bulk-workspace__candidate select { width: 100%; min-width: 0; }
.bulk-workspace__sources { display: flex; gap: 8px 16px; flex-wrap: wrap; min-width: 0; }
.bulk-workspace__sources label { display: inline-flex; align-items: center; gap: 8px; }
.bulk-workspace__ledger { min-width: 620px; }
.bulk-workspace__ledger td, .bulk-workspace__ledger th { overflow-wrap: anywhere; }
.bulk-workspace__ledger .right { font-variant-numeric: tabular-nums; white-space: nowrap; }
.bulk-workspace__hold-reason { display: block; white-space: normal; color: var(--ink-2); overflow-wrap: anywhere; }
@media (min-width: 1200px) {
  .bulk-workspace__stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .bulk-workspace__decision { grid-template-columns: minmax(0, 1fr) minmax(220px, .8fr) auto; align-items: center; }
  .bulk-workspace__candidate { grid-template-columns: minmax(0, 1fr) minmax(200px, .65fr); align-items: start; }
  .bulk-workspace__candidate .bulk-workspace__sources { grid-column: 1 / -1; }
}

/* Approved monthly-close interior. These rules are scoped to its unmounted
   presentation and leave the legacy Residuals screens intact. */
.monthly-close { gap: 16px; }
.monthly-close__head, .monthly-close__head-actions, .monthly-close__source-status,
.monthly-close__ledger-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; }
.monthly-close__head > div, .monthly-close__ledger-head > *, .monthly-close__decision > * { min-width: 0; }
.monthly-close__head h2, .monthly-close__head p { margin: 0; }
.monthly-close__head p { margin-top: 5px; }
.monthly-close__head-actions { justify-content: flex-end; flex-wrap: wrap; }
.monthly-close__action { display: grid; gap: 5px; min-width: 0; }
.monthly-close__disabled { max-width: 220px; overflow-wrap: anywhere; }
.monthly-close__summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; min-width: 0; }
.monthly-close__tile { display: grid; gap: 6px; min-width: 0; padding: 14px 16px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); background: var(--surface); }
.monthly-close__tile strong { font-size: 1.125rem; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
/* Unassigned line under the summary tiles: the workspace grid gap (16px) is the only spacing, as for every other child. */
.monthly-close__unassigned { margin: 0; overflow-wrap: anywhere; }
.monthly-close__panel, .monthly-close__body { min-width: 0; }
.monthly-close__body { display: grid; gap: 14px; }
.monthly-close__body > p { margin: 0; }
.monthly-close__source-status { flex-wrap: wrap; }
.monthly-close__decision-list { display: grid; gap: 10px; min-width: 0; }
.monthly-close__decision { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 8px 12px; padding: 12px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); min-width: 0; }
.monthly-close__decision p { margin: 5px 0 0; }
.monthly-close__hold-reason { display: block; margin-top: 4px; color: var(--steel); overflow-wrap: anywhere; }
.monthly-close__reconciliation { display: grid; gap: 8px; min-width: 0; }
.monthly-close__metric { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--hair); min-width: 0; }
.monthly-close__metric > * { min-width: 0; overflow-wrap: anywhere; }
.monthly-close__metric b { font-variant-numeric: tabular-nums; white-space: nowrap; }
.monthly-close__ledger { min-width: 1120px; }
.monthly-close__ledger th, .monthly-close__ledger td { vertical-align: top; overflow-wrap: anywhere; }
.monthly-close__ledger .right { white-space: nowrap; font-variant-numeric: tabular-nums; }
/* Monthly close: compact action labels and collapsed evidence keep ledger rows scannable. */
.monthly-close__row-actions { display: grid; gap: 8px; min-width: 180px; }
.monthly-close__payee-kind { display: block; margin-top: 3px; }
.monthly-close__notice-detail { display: block; margin-top: 3px; }
.monthly-close__state-label, .monthly-close__notice-state { white-space: nowrap; }
.monthly-close__quick-actions { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 8px; min-width: 0; }
.monthly-close__quick-actions > .monthly-close__action { display: grid; gap: 4px; justify-items: start; }
.monthly-close__row-actions > .monthly-close__action .btn { max-width: 100%; }
.monthly-close__status-control, .monthly-close__hold-control { display: grid; gap: 6px; min-width: 0; }
.monthly-close__status-control > label { margin: 0; }
.monthly-close__status-control select { width: 100%; min-width: 0; }
.monthly-close__payment-entry { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; margin-top: 2px; padding: 8px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); background: var(--surface-2, var(--surface)); min-width: 0; }
.monthly-close__payment-entry[hidden] { display: none; }
.monthly-close__payment-entry > small, .monthly-close__payment-entry > button { grid-column: 1 / -1; }
.monthly-close__field { display: grid; gap: 5px; min-width: 0; color: var(--ink-2); font-size: .78rem; }
.monthly-close__payment-entry input { width: 100%; min-width: 0; }
.monthly-close__state { color: var(--steel); }
@media (min-width: 1200px) {
  .monthly-close__summary { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .monthly-close__decision { grid-template-columns: minmax(0, 1fr) auto; }
}
@media (max-width: 900px) {
  .monthly-close__head, .monthly-close__ledger-head { align-items: flex-start; flex-direction: column; }
  .monthly-close__head-actions { justify-content: flex-start; }
  .monthly-close__payment-entry { grid-template-columns: minmax(0, 1fr); }
  .monthly-close__payment-entry > small, .monthly-close__payment-entry > button { grid-column: auto; }
}
/* Monthly residuals page: the month picker, the files that arrived, and the
   approved monthly-close interior below them. One gap rules the page: 16px
   between panels, 12px between controls, 8px between a row's parts. */
.month-page { gap: 16px; }
.month-page__panel, .month-page__files, .month-page__start { min-width: 0; }
.month-page__toolbar, .month-page__files-head, .month-page__start-fields, .month-page__toolbar-actions { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; min-width: 0; }
.month-page__files-head { align-items: center; }
.month-page__toolbar-actions { justify-content: flex-end; align-items: center; }
.month-page__start { display: grid; gap: 12px; border-top: 1px solid var(--hair); }
.month-page__start > p { margin: 0; }
.month-page__start-fields { justify-content: flex-start; }
.month-page__start-fields > label { flex: 1 1 240px; }
.month-page__field { display: grid; gap: 5px; min-width: 0; color: var(--ink-2); font-size: .78rem; }
.month-page__field select, .month-page__field input { width: 100%; min-width: 0; }
/* Monthly merchant review: controls wrap with the same 12px toolbar gap. */
.month-page__review-controls { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); align-items: end; gap: 12px; margin-block: 12px; }
.month-page__month { min-width: 220px; }
.month-page__files { display: grid; gap: 12px; }
.month-page__files > p { margin: 0; }
.month-page__file-input { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.month-page__drop { display: grid; gap: 4px; justify-items: center; text-align: center; padding: 18px 16px; border: 1.5px dashed var(--hair); border-radius: var(--radius, 10px); color: var(--ink-2); cursor: pointer; }
.month-page__drop:hover, .month-page__drop:focus-visible, .month-page__drop.is-over { border-color: var(--accent, var(--ink)); background: var(--surface-2, var(--surface)); }
.month-page__file-list { display: grid; gap: 8px; min-width: 0; }
/* Selecting several saved files to remove (Greg, 2026-10-30: "on the left hand side of the name in the pill, bold outline, easy to identify").
   The tick box is its own column at the far left of the file pill: a bold 2px outline that fills with the brand colour and a white check when
   ticked, a 44px click area around it, a dash when only some are ticked, and a ticked pill is tinted and outlined so the selection reads at a glance. */
.month-page__file.month-page__file--selectable { grid-template-columns: auto minmax(0, 1fr) auto; }
.month-page__tick { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-width: 44px; min-height: 44px; margin: -8px 0 -8px -10px; cursor: pointer; }
.month-page__tick--all { min-width: 0; margin: 0; font-weight: 600; padding-right: 6px; }
.month-page__tick input { appearance: none; -webkit-appearance: none; display: grid; place-content: center; flex: none; width: 24px; height: 24px; margin: 0;
  border: 2px solid var(--ink); border-radius: 6px; background: var(--surface, #fff); cursor: pointer; }
.month-page__tick input::after { content: ""; width: 12px; height: 6px; border: solid #fff; border-width: 0 0 3px 3px; transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.month-page__tick input:hover { border-color: var(--accent); }
.month-page__tick input:checked, .month-page__tick input:indeterminate { background: var(--accent); border-color: var(--accent); }
.month-page__tick input:checked::after { opacity: 1; }
.month-page__tick input:indeterminate::after { opacity: 1; height: 0; border-width: 0 0 3px 0; transform: none; }
.month-page__tick input:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
.month-page__file.month-page__file.is-selected { border-color: var(--accent); background: var(--accent-tint, var(--surface-2, var(--surface))); box-shadow: inset 0 0 0 1px var(--accent); }
.month-page__selectbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 2px 2px 6px; }
.month-page__selectbar .month-page__count { color: var(--ink-2); }
.month-page__file { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px 12px; padding: 10px 12px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); min-width: 0; }
.month-page__file-name { display: grid; gap: 3px; min-width: 0; }
.month-page__file-name > * { overflow-wrap: anywhere; }
.month-page__file--pending .month-page__source, .month-page__file--pending .month-page__note, .month-page__file--pending .month-page__row-actions { grid-column: 1 / -1; }
.month-page__source { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; min-width: 0; }
.month-page__note { margin: 0; color: var(--ink-2); overflow-wrap: anywhere; }
/* The column picker for a layout the page has not seen (Monthly residuals, 2026-10-20):
   it spans the pending row like the label boxes and spaces its own parts. */
.month-page__file--pending .month-page__columns { grid-column: 1 / -1; }
.month-page__columns { display: grid; gap: 12px; min-width: 0; }
.month-page__row-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
/* Remove a saved file (design A, 2026-10-24): the question opens under its
   file across the row, parted by the row's own hairline; a removed file stays
   listed, muted and struck through, with who removed it and when. */
.month-page__file > .month-page__confirm { grid-column: 1 / -1; }
.month-page__confirm { display: grid; gap: 8px; padding-top: 8px; border-top: 1px solid var(--hair); min-width: 0; }
.month-page__confirm > .month-page__row-actions { justify-content: flex-start; }
.month-page__file--removed { border-style: dashed; color: var(--ink-2); }
.month-page__file--removed s { color: var(--ink-2); overflow-wrap: anywhere; }
/* Held actions (design A, 2026-10-25): under a held card's reason and
   merchant lines, across the card, parted by the same 8px rhythm as the
   Files and Check rows. A note line takes the room; its button sits beside. */
.month-page__file > .month-page__hold-actions { grid-column: 1 / -1; }
.month-page__hold-actions { display: grid; gap: 8px; min-width: 0; }
.month-page__hold-action { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-width: 0; }
.month-page__hold-action > .month-page__note { flex: 1 1 240px; min-width: 0; }
/* At phone width the action's own words wrap inside the card rather than
   pushing past its edge (measured at 375px: the one-line button was 268px
   in a 260px card); the 44px touch height stays the minimum. */
@media (max-width: 560px) {
  .month-page__hold-action > .btn { max-width: 100%; height: auto; min-height: 44px; white-space: normal; text-align: left; }
}
.month-page__hold-actions > .month-page__note s { color: var(--ink-2); }
.month-page__pending { display: grid; gap: 8px; }
.month-page__pending > h4 { margin: 0; }
.month-page__error { margin: 0; color: var(--red, #B42318); }
.month-page__intent .panel__body { display: grid; gap: 12px; }
.month-page__intent p { margin: 0; }
/* Panel two: the merchants that need an owner (step 2 §5). The files panel's
   rhythm: 16px between provider groups, 12px between cards and between a
   card's parts, 8px between pills and between a row's facts. Every gap is a
   grid/flex gap here; nothing on the screen carries a margin of its own. */
.month-page__merchants { display: grid; gap: 16px; min-width: 0; }
.month-page__merchants > p { margin: 0; }
.month-page__notice { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; min-width: 0; }
.month-page__group, .month-page__card-list, .month-page__decided { display: grid; gap: 12px; min-width: 0; }
.month-page__group-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; min-width: 0; }
.month-page__subhead { margin: 0; font-size: var(--fs-label); font-weight: 700; overflow-wrap: anywhere; }
.month-page__card { display: grid; gap: 12px; padding: 12px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); min-width: 0; }
/* Assign-all reads as a different kind of card: an accent edge, same box. */
.month-page__card--agent { box-shadow: inset 3px 0 0 var(--accent, var(--ink)); }
/* Name left, reason badge right; on a phone the badge wraps under the name
   instead of squeezing it to a word per line (found on "owner no longer payable"). */
.month-page__card-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 8px 12px; min-width: 0; }
.month-page__card-head > .month-page__file-name { flex: 1 1 200px; }
.month-page__card-facts { display: flex; flex-wrap: wrap; gap: 8px 16px; color: var(--ink-2); min-width: 0; }
.month-page__card-facts b { color: var(--ink); font-variant-numeric: tabular-nums; }
.month-page__pills { display: flex; flex-wrap: wrap; gap: 8px; min-width: 0; }
.month-page__card-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; min-width: 0; }
.month-page__program { display: flex; align-items: center; min-height: 44px; color: var(--ink); font-size: var(--fs-label); }
.month-page__preview { margin: 0; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
/* Step 5: the population the month is built on. The toolbar's second row
   (the copy in use and its two buttons), the import panel and the copies
   list keep the page's rhythm: 12px between a panel's parts and between
   controls, 8px between a step's parts and between progress rows, 3px
   inside a copy's lines (as in a file row). Gaps only; no margins. */
.month-page__population { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; min-width: 0; border-top: 1px solid var(--hair); }
.month-page__population-text { margin: 0; color: var(--ink-2); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.month-page__import, .month-page__inventory { display: grid; gap: 12px; min-width: 0; }
.month-page__import > p, .month-page__inventory > p { margin: 0; }
.month-page__steps { display: grid; gap: 12px; margin: 0; padding: 0; min-width: 0; }
.month-page__step { display: grid; gap: 8px; min-width: 0; }
.month-page__command { display: block; padding: 8px 12px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); background: var(--surface-2, var(--surface)); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .82rem; overflow-wrap: anywhere; }
.month-page__import-actions { justify-content: flex-start; }
.month-page__progress { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; min-width: 0; }
/* The row count never breaks ("84 / rows" at 768px); the name wraps instead. */
.month-page__progress-row > :last-child { white-space: nowrap; }
.month-page__progress-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding: 6px 10px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); font-variant-numeric: tabular-nums; min-width: 0; }
.month-page__import-done { display: grid; gap: 8px; min-width: 0; }
.month-page__import-done > p { margin: 0; overflow-wrap: anywhere; }
.month-page__copy { display: grid; gap: 3px; padding: 10px 12px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); min-width: 0; }
.month-page__copy > * { overflow-wrap: anywhere; }
/* A remembered portfolio label being changed (step 5 q7): amber, not red. */
.month-page__label-warning { color: var(--amber, #B54708); }
@media (max-width: 900px) {
  .month-page__toolbar, .month-page__files-head, .month-page__population { align-items: flex-start; flex-direction: column; }
  .month-page__toolbar-actions { justify-content: flex-start; }
  .month-page__file { grid-template-columns: minmax(0, 1fr); }
  .month-page__file.month-page__file--selectable { grid-template-columns: auto minmax(0, 1fr); }
  .month-page__file.month-page__file--selectable > .month-page__row-actions { grid-column: 2; justify-content: flex-start; }
}
/* Monthly residuals in three steps (Greg, 2026-10-20). Built for a first-time
   user: 17px reading text, 44px controls, one primary action per step. The same
   gaps as above: 16px between panels, 12px between controls, 8px inside a row. */
.month-page { font-size: 17px; }
.month-page .btn, .month-page .tab, .month-page .input, .month-page select { min-height: 44px; }
.month-page .small, .month-page .tiny { font-size: 15px; }
.month-page__copyline, .month-page__prepared, .month-page__group-bar, .month-page__actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; min-width: 0; }
.month-page__copyline { justify-content: space-between; border-top: 1px solid var(--hair); }
.month-page__copyline > p { margin: 0; flex: 1 1 260px; color: var(--ink-2); overflow-wrap: anywhere; }
/* The population line draws its own top rule; one rule per row, not two. */
.month-page__copyline > .month-page__population { flex: 1 1 260px; border-top: 0; padding: 0; }
.month-page__stepstrip { gap: 8px; min-width: 0; }
.month-page__stepstrip .tab[disabled] { opacity: .5; cursor: default; }
.month-page__actions { justify-content: flex-end; border-top: 1px solid var(--hair); }
.month-page__actions-gap { flex: 1 1 0; }
.month-page__hint { margin: 0; color: var(--ink-2); }
/* Design A (Greg's answered sheet, 2026-10-30): a file that landed carries a green check at the head of its
   name and its row count in the side column; the totals strip under the list is a moving bar while they are
   worked out; Check ends on an Everyone line and Post on a Total line, both parted from the list by a rule.
   Every gap here is a grid/flex gap; nothing carries a margin of its own. */
.month-page__landed { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; background: var(--green-soft, rgba(31, 122, 77, .14)); color: var(--green, #1F7A4D); font-weight: 700; font-size: 13px; line-height: 1; flex: none; }
.month-page__rows { white-space: nowrap; }
.month-page__progress { display: grid; gap: 6px; min-width: 0; }
.month-page__progress-words { color: var(--ink-2); }
.month-page__progress-bar { display: block; height: 6px; border-radius: 99px; background: var(--hair); overflow: hidden; }
.month-page__progress-bar > i { display: block; width: 38%; height: 100%; border-radius: 99px; background: var(--accent); animation: month-page-working 1.4s ease-in-out infinite; }
@keyframes month-page-working { from { transform: translateX(-100%); } to { transform: translateX(290%); } }
@media (prefers-reduced-motion: reduce) { .month-page__progress-bar > i { animation: none; width: 100%; opacity: .55; } }
.month-page__sum { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; min-width: 0; padding-top: 12px; border-top: 2px solid var(--hair-strong, var(--hair)); }
.month-page__post-actions { border-top: 0; }
.month-page__clear { display: grid; gap: 12px; justify-items: start; }
.month-page__clear > p { margin: 0; }
.month-page__posting { display: grid; gap: 12px; min-width: 0; }
.month-page__payments { display: grid; gap: 12px; min-width: 0; }
.month-page__group-bar { justify-content: space-between; }
.month-page__prepared { justify-content: space-between; border-bottom: 1px solid var(--hair); }
.month-page__person { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 8px 12px; padding: 10px 12px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); min-width: 0; }
.month-page__amount { font-variant-numeric: tabular-nums; font-weight: 600; text-align: right; white-space: nowrap; }
/* Change from last month (2026-10-30, q4): one small line under the person; a change over 30% tints the row amber until approved. */
.month-page__change { display: block; margin-top: 2px; }
.month-page__change--flag { color: var(--amber); font-weight: 600; }
.month-page__person--flag { border-color: var(--amber); background: var(--amber-lt); }
/* Post's lasting word once a post landed (2026-10-30): the green check and one line, same air as the other panel parts. */
.month-page__posted { display: flex; align-items: flex-start; gap: 12px; }
.month-page__roster, .month-page__rostergroup { display: grid; gap: 12px; min-width: 0; }
.month-page__more { border-top: 1px solid var(--hair); padding: 12px; min-width: 0; }
.month-page__more > summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--ink-2); }
.month-page__more[open] > summary { margin-bottom: 12px; }
@media (max-width: 900px) {
  .month-page__actions { justify-content: stretch; }
  .month-page__actions > .btn { flex: 1 1 0; }
  .month-page__actions-gap { display: none; }
  .month-page__person { grid-template-columns: minmax(0, 1fr) auto; }
  .month-page__person > .btn, .month-page__person > .badge { grid-column: 1 / -1; }
}

.month-page__additional-payee { display: grid; gap: 12px; min-width: 0; margin: 0; padding: 12px; border: 1px solid var(--hair); border-radius: var(--radius, 10px); }
