/* @ekm-tags: style, billing */
/*
 * EKM Billing — "My work" + step-by-step guide. "Dark & quiet" visual direction (approved 2026-10-27).
 *
 * All color comes from SEMANTIC tokens that alias onto the portal's live theme layer (the --c-*
 * variables applyTheme() writes onto <html>, plus the html[data-dark] flag), so billing follows each
 * user's chosen theme automatically. The accent follows the theme's own accent (used sparingly: thin
 * underlines, progress, one primary button per task). Only status colors have fixed dark/light
 * reference values (they must read the same in every theme). Everything is scoped under .bc-scope so
 * nothing leaks into the rest of the portal.
 *
 * Rules honored: 1px hairlines (not nested boxes), max one card level, 12px cards / 8px buttons,
 * tabular Inter numerals, status as dot+text only, 150–200ms ease-out, prefers-reduced-motion,
 * visible focus rings, >=44px primary targets, body >=15px / labels >=14px.
 */

/* ---------------------------------------------------------------- tokens */
.bc-scope {
  /* Legacy --bc-* names now ALIAS the billing design tokens (css/ekm-billing-tokens.css), so every
     Command Center rule adopts the design-system palette and fonts in light and dark — with NO raw hex
     in this file. All hex lives only in the token definitions. (BC_Visual_Design_System.md is SoT.) */
  --bc-bg: var(--bg);
  --bc-surface: var(--surface);
  --bc-surface-2: var(--surface-2);
  --bc-line: var(--line);
  --bc-line-strong: var(--line-strong);
  --bc-control-border: var(--control-border);
  --bc-chip: var(--surface-2);
  --bc-text: var(--text);
  --bc-text-2: var(--text-2);
  --bc-muted: var(--muted);
  --bc-faint: var(--faint);
  --bc-label: var(--label);
  --bc-accent: var(--accent);
  --bc-accent-soft: var(--accent-tint);
  --bc-on-accent: var(--accent-on);

  /* status → design semantic tokens; both themes handled by the token file (no overrides needed here) */
  --bc-urgent-text: var(--danger);  --bc-urgent-dot: var(--danger);
  --bc-late-text: var(--warning);   --bc-late-dot: var(--warning);
  --bc-ok-text: var(--success);     --bc-ok-dot: var(--success);

  --bc-font: var(--font-ui);
  --bc-num: var(--font-ui);
  --bc-display: var(--font-display);

  --bc-r-card: var(--r-card);
  --bc-r-btn: var(--r-control);
  --bc-r-chip: var(--r-control);

  --bc-s1: 4px; --bc-s2: 8px; --bc-s3: 16px; --bc-s4: 24px; --bc-s5: 40px;
  --bc-motion: 150ms;
  --bc-ease: ease-out;

  font-family: var(--bc-font);
  color: var(--bc-text);
  background: var(--bc-bg);
}

.bc-scope *, .bc-scope *::before, .bc-scope *::after { box-sizing: border-box; }
.bc-num { font-family: var(--bc-num); font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- layout */
.bc-root { max-width: none; margin: 0; padding: var(--bc-s4) 32px var(--bc-s5); font-size: 15px; line-height: 1.45; }  /* full-width billing work screen, 32px page gutter (§5) */

/* sticky slim header + sub-nav; translucent blur when scrolled */
.bc-top { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bc-bg) 82%, transparent); backdrop-filter: saturate(140%) blur(10px); -webkit-backdrop-filter: saturate(140%) blur(10px); border-bottom: 1px solid transparent; transition: border-color var(--bc-motion) var(--bc-ease), background var(--bc-motion) var(--bc-ease); }
.bc-top.is-scrolled { border-bottom-color: var(--bc-line); }
.bc-subnav { max-width: 920px; margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: 0 var(--bc-s4); padding: 10px var(--bc-s3); }   /* wraps (never scrolls sideways) when a role sees every link, e.g. the owner's Reconciliation */
.bc-subnav a { color: var(--bc-muted); text-decoration: none; font-size: 15px; padding: 10px 0; border-bottom: 2px solid transparent; transition: color var(--bc-motion) var(--bc-ease), border-color var(--bc-motion) var(--bc-ease); white-space: nowrap; }
.bc-subnav a:hover { color: var(--bc-text); }
.bc-subnav a.is-active { color: var(--bc-text); border-bottom-color: var(--bc-accent); font-weight: 600; }
.bc-subnav .bc-right { margin-left: auto; }
.bc-fresh { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--bc-muted); }

/* ---------------------------------------------------------------- type scale */
.bc-h1 { font-family: var(--bc-display); font-size: 30px; line-height: 1.1; font-weight: 400; letter-spacing: -.005em; margin: 0; }
.bc-h2 { font-family: var(--bc-display); font-size: 24px; line-height: 1.15; font-weight: 400; margin: 0; }
.bc-task-title { font-size: 24px; font-weight: 600; letter-spacing: -.01em; margin: 0; }
.bc-sec-label { font-size: 14px; font-weight: 500; color: var(--bc-muted); margin: var(--bc-s5) 0 var(--bc-s2); }
.bc-sec-label:first-of-type { margin-top: var(--bc-s4); }
.bc-sec-note { font-size: 14px; color: var(--bc-muted); font-weight: 400; }
.bc-money-figure { font-family: var(--bc-display); font-size: 28px; line-height: 1.1; font-weight: 400; font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- greeting + progress */
.bc-greet { margin: var(--bc-s2) 0 var(--bc-s4); }
.bc-greet .sub { color: var(--bc-muted); font-size: 15px; margin-top: 4px; }
.bc-progress { height: 4px; background: var(--surface-3); margin-top: 14px; overflow: hidden; }  /* square ends (§6.11) */
.bc-progress > i { display: block; height: 100%; width: 0; background: var(--bc-accent); transition: width 220ms var(--bc-ease); }
.bc-progress-label { font-size: 14px; color: var(--bc-muted); margin-top: 6px; }

/* ---------------------------------------------------------------- status dot + text */
.bc-dot { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 500; }
.bc-dot::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--bc-ok-dot); flex: none; }
.bc-dot.is-urgent { color: var(--bc-urgent-text); } .bc-dot.is-urgent::before { background: var(--bc-urgent-dot); }
.bc-dot.is-late { color: var(--bc-late-text); } .bc-dot.is-late::before { background: var(--bc-late-dot); }
.bc-dot.is-ok { color: var(--bc-ok-text); } .bc-dot.is-ok::before { background: var(--bc-ok-dot); }

/* ---------------------------------------------------------------- the one card level */
.bc-card { background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: var(--bc-s4); }
.bc-card.is-later { background: transparent; border-style: dashed; border-color: var(--bc-line-strong); }

/* focused "Right now" task card (§4) */
.bc-task .bc-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; font-size: 14px; color: var(--bc-muted); }
.bc-task .bc-meta .sep { color: var(--bc-line-strong); }
.bc-task .bc-task-title { margin: 10px 0 12px; }
.bc-facts { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 15px; padding-bottom: var(--bc-s3); }
.bc-facts .k { color: var(--bc-muted); }
.bc-facts .v { color: var(--bc-text); font-weight: 500; }

/* definition rows separated by hairlines (label col ~170px) */
.bc-def { border-top: 1px solid var(--bc-line); display: grid; grid-template-columns: 170px 1fr; gap: var(--bc-s3); padding: var(--bc-s3) 0; }
.bc-def .k { color: var(--bc-muted); font-size: 14px; }
.bc-def .v { font-size: 15px; }
.bc-def ol { margin: 0; padding-left: 18px; } .bc-def ol li { margin: 3px 0; }
.bc-task-foot { border-top: 1px solid var(--bc-line); padding-top: var(--bc-s3); display: flex; align-items: center; gap: var(--bc-s4); flex-wrap: wrap; }

/* up-next compact rows (no buttons — keep focus on #1) */
.bc-row { display: flex; align-items: center; gap: var(--bc-s3); padding: 14px var(--bc-s3); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); background: var(--bc-surface); cursor: pointer; transition: border-color var(--bc-motion) var(--bc-ease), transform var(--bc-motion) var(--bc-ease); }
.bc-row + .bc-row { margin-top: var(--bc-s2); }
.bc-row:hover { border-color: var(--bc-line-strong); }
.bc-row:active { transform: translateY(1px); }
.bc-row .num { font-family: var(--bc-num); color: var(--bc-muted); width: 20px; flex: none; text-align: right; }
.bc-row .body { flex: 1; min-width: 0; }
.bc-row .title { font-weight: 500; }
.bc-row .issue { font-size: 14px; color: var(--bc-muted); margin-top: 2px; }
.bc-row .right { display: flex; align-items: center; gap: var(--bc-s3); flex: none; font-size: 14px; color: var(--bc-muted); }

/* money-at-a-glance + aging */
.bc-money-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--bc-s4); }
.bc-money-grid .k { font-size: 14px; color: var(--bc-muted); }
.bc-money-grid .expl { font-size: 14px; color: var(--bc-muted); margin-top: 4px; }
.bc-money-grid a { color: var(--bc-accent); text-decoration: none; } .bc-money-grid a:hover { text-decoration: underline; }
.bc-aging { margin-top: var(--bc-s4); border-top: 1px solid var(--bc-line); padding-top: var(--bc-s3); }
.bc-aging-bar { display: flex; height: 8px; overflow: hidden; background: var(--surface-3); margin: var(--bc-s2) 0; }  /* square ends */
.bc-aging-bar > span { display: block; height: 100%; }
.bc-aging-bar > span:nth-child(1) { background: var(--bc-ok-dot); }
.bc-aging-bar > span:nth-child(2) { background: var(--bc-late-dot); }
.bc-aging-bar > span:nth-child(3) { background: color-mix(in srgb, var(--bc-late-dot) 55%, var(--bc-urgent-dot)); }
.bc-aging-bar > span:nth-child(4) { background: var(--bc-urgent-dot); }
.bc-aging-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14px; color: var(--bc-muted); }
.bc-aging-legend b { color: var(--bc-text); font-family: var(--bc-num); font-variant-numeric: tabular-nums; }

/* footer help */
.bc-help { margin-top: var(--bc-s5); border-top: 1px solid var(--bc-line); padding-top: var(--bc-s3); display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: var(--bc-s4); font-size: 14px; color: var(--bc-muted); }
.bc-help a { color: var(--bc-accent); text-decoration: none; } .bc-help a:hover { text-decoration: underline; }

/* ---------------------------------------------------------------- buttons + links */
.bc-btn { font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; border-radius: var(--bc-r-btn); padding: 11px 18px; min-height: 44px; border: 1px solid var(--bc-accent); background: var(--bc-accent); color: var(--bc-on-accent); transition: filter var(--bc-motion) var(--bc-ease), transform var(--bc-motion) var(--bc-ease); }
.bc-btn:hover { filter: brightness(1.06); }
.bc-btn:active { transform: translateY(1px); }
.bc-btn.is-secondary { background: transparent; color: var(--bc-text); border-color: var(--bc-line-strong); }
.bc-btn.is-secondary:hover { border-color: var(--bc-text); filter: none; }
/* Primary uses the design accent (dark theme resolves it to the lightened aubergine with dark text,
   so it reads as clearly active in both themes — no theme-specific override needed). */
.bc-btn:disabled, .bc-btn[disabled] { opacity: .45; cursor: not-allowed; filter: none; }
.bc-link { background: none; border: 0; padding: 0; font: inherit; font-size: 14px; color: var(--bc-accent); cursor: pointer; text-decoration: none; }
.bc-link:hover { text-decoration: underline; }
.bc-quiet { background: none; border: 0; padding: 0; font: inherit; font-size: 14px; color: var(--bc-muted); cursor: pointer; }
.bc-quiet:hover { color: var(--bc-text); }

/* focus rings */
.bc-scope :focus-visible { outline: 2px solid var(--bc-accent); outline-offset: 2px; border-radius: 4px; }

/* ---------------------------------------------------------------- step / focus mode (§5) */
.bc-focusmode .bc-step-head { display: flex; align-items: center; gap: var(--bc-s4); font-size: 14px; color: var(--bc-muted); flex-wrap: wrap; }
.bc-focusmode .bc-step-head .mid { color: var(--bc-muted); }
.bc-seg { display: flex; gap: 6px; margin: var(--bc-s3) 0 6px; }
.bc-seg > i { flex: 1; height: 6px; border-radius: 999px; background: var(--bc-chip); transition: background var(--bc-motion) var(--bc-ease); }
.bc-seg > i.is-done { background: color-mix(in srgb, var(--bc-accent) 55%, transparent); }
.bc-seg > i.is-current { background: var(--bc-accent); }
.bc-steps-layout { display: grid; grid-template-columns: 220px 1fr; gap: var(--bc-s4); margin-top: var(--bc-s4); align-items: start; }
.bc-steplist { list-style: none; margin: 0; padding: 0; }
.bc-steplist li { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: var(--bc-r-btn); cursor: pointer; color: var(--bc-muted); transition: background var(--bc-motion) var(--bc-ease), color var(--bc-motion) var(--bc-ease); }
.bc-steplist li:hover { background: var(--bc-chip); }
.bc-steplist li .circle { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--bc-line-strong); display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-family: var(--bc-num); flex: none; }
.bc-steplist li.is-current { color: var(--bc-text); } .bc-steplist li.is-current .circle { border-color: var(--bc-accent); color: var(--bc-accent); }
.bc-steplist li.is-done { color: var(--bc-text); } .bc-steplist li.is-done .circle { border-color: var(--bc-ok-dot); color: var(--bc-ok-text); }
.bc-steplist li .state { margin-left: auto; font-size: 12px; color: var(--bc-muted); }
.bc-stepcard .srow { border-top: 1px solid var(--bc-line); display: grid; grid-template-columns: 150px 1fr; gap: var(--bc-s3); padding: var(--bc-s3) 0; }
.bc-stepcard .srow:first-child { border-top: 0; }
.bc-stepcard .srow .k { color: var(--bc-muted); font-size: 14px; }
.bc-stepcard .srow ol { margin: 0; padding-left: 18px; }
.bc-donewhen { color: var(--bc-ok-text); display: inline-flex; gap: 8px; align-items: flex-start; }
.bc-donewhen::before { content: "✓"; font-weight: 700; }
.bc-note { margin-top: var(--bc-s3); border: 1px solid color-mix(in srgb, var(--bc-late-dot) 45%, var(--bc-line)); border-radius: var(--bc-r-btn); padding: 12px 14px; font-size: 14px; color: var(--bc-text); background: color-mix(in srgb, var(--bc-late-dot) 8%, transparent); }
.bc-note b { color: var(--bc-late-text); }
/* "Being confirmed for our account" badge + reference tables (coding / denial-reason) */
.bc-confirming { display: inline-block; margin-top: 8px; font-size: 12px; font-weight: 600; line-height: 1.3; letter-spacing: .01em; color: var(--bc-late-text); border-left: 2px solid currentColor; padding: 1px 0 1px 8px; }
.bc-codetable { width: 100%; border-collapse: collapse; font-size: 14px; margin-top: 4px; }
.bc-codetable th { text-align: left; font-weight: 600; color: var(--bc-muted); font-size: 13px; padding: 6px 10px; border-bottom: 1px solid var(--bc-line); }
.bc-codetable td { padding: 6px 10px; border-bottom: 1px solid var(--bc-line); vertical-align: top; }
.bc-codetable tr:last-child td { border-bottom: 0; }
/* exact Tebra click paths + the two charge-entry paths */
.bc-clicks { margin: 8px 0 0; padding-left: 20px; }
.bc-clicks li { margin: 4px 0; }
.bc-path { margin-top: 12px; border-top: 1px solid var(--bc-line); padding-top: 10px; }
.bc-path:first-of-type { border-top: 0; }
.bc-path-label { font-weight: 600; font-size: 14px; }
.bc-pathwarn { margin-top: 10px; font-size: 13px; font-weight: 600; color: var(--bc-urgent-text); background: color-mix(in srgb, var(--bc-urgent-dot) 10%, transparent); border: 1px solid color-mix(in srgb, var(--bc-urgent-dot) 35%, var(--bc-line)); border-radius: var(--bc-r-btn); padding: 8px 12px; }
.bc-stepfoot { margin-top: var(--bc-s4); display: flex; align-items: center; gap: var(--bc-s3); flex-wrap: wrap; }
.bc-stepfoot .bc-right { margin-left: auto; display: flex; align-items: center; gap: var(--bc-s3); }

/* confirmation card before any save */
.bc-confirm { border: 1px solid var(--bc-line-strong); border-radius: var(--bc-r-card); padding: var(--bc-s4); background: var(--bc-surface); }
.bc-confirm .lede { font-size: 16px; }
.bc-confirm .warn { margin-top: 10px; font-size: 14px; color: var(--bc-muted); }
.bc-confirm .bc-stepfoot { margin-top: var(--bc-s4); }

/* done state */
.bc-done-check { width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: color-mix(in srgb, var(--bc-ok-dot) 16%, transparent); color: var(--bc-ok-text); font-size: 20px; font-weight: 700; }

/* ---------------------------------------------------------------- skeleton loading */
.bc-skel { border-radius: 8px; background: linear-gradient(90deg, var(--bc-chip) 25%, color-mix(in srgb, var(--bc-chip) 50%, var(--bc-surface)) 37%, var(--bc-chip) 63%); background-size: 400% 100%; animation: bc-shimmer 1.4s ease infinite; }
.bc-skel.line { height: 14px; margin: 8px 0; } .bc-skel.line.sm { width: 40%; } .bc-skel.line.lg { width: 80%; }
.bc-skel.title { height: 26px; width: 60%; margin: 10px 0 16px; }
.bc-skel.card { height: 150px; margin-top: var(--bc-s3); }
@keyframes bc-shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

/* empty state */
.bc-empty { text-align: center; padding: var(--bc-s5) var(--bc-s3); color: var(--bc-muted); }
.bc-empty .big { font-size: 20px; color: var(--bc-text); font-weight: 600; margin-bottom: 6px; }

/* enter / leave motion */
.bc-animate-in { animation: bc-in var(--bc-motion) var(--bc-ease) both; }
@keyframes bc-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.bc-leaving { animation: bc-out 220ms var(--bc-ease) forwards; }
@keyframes bc-out { to { opacity: 0; transform: translateX(14px); height: 0; margin: 0; padding-top: 0; padding-bottom: 0; } }

/* keyboard-shortcuts panel */
.bc-kbd { position: fixed; right: 20px; bottom: 20px; background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: var(--bc-s3) var(--bc-s4); font-size: 14px; color: var(--bc-text); box-shadow: 0 6px 24px rgba(0,0,0,.18); z-index: 20; }
.bc-kbd h4 { margin: 0 0 8px; font-size: 14px; }
.bc-kbd kbd { font-family: var(--bc-num); background: var(--bc-chip); border-radius: 4px; padding: 1px 6px; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 760px) {
  .bc-steps-layout { grid-template-columns: 1fr; }
  .bc-def, .bc-stepcard .srow { grid-template-columns: 1fr; gap: 4px; }
  .bc-subnav { gap: var(--bc-s3); overflow-x: auto; flex-wrap: nowrap; }
}

/* ---------------------------------------------------------------- reduced motion */
@media (prefers-reduced-motion: reduce) {
  .bc-scope *, .bc-scope *::before, .bc-scope *::after {
    animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important;
  }
}

/* ================================================================ Guided billing (demo-matched .gb-*) */
.bc-scope { --bc-accent-soft: color-mix(in srgb, var(--bc-accent) 14%, transparent); }
.bc-root.gb { max-width: 1180px; }

/* chips (demo tones → portal status tokens) */
/* Status "pills" replaced by the design-system 2px left-rule (no pill shapes, no fills). */
.bc-scope .chip { display: inline-block; border-left: 2px solid currentColor; padding: 1px 0 1px 8px; font-size: 12px; font-weight: 600; line-height: 1.3; letter-spacing: .01em; white-space: nowrap; background: none; border-radius: 0; }
.chip.t-plum { color: var(--accent); }
.chip.t-amber { color: var(--warning); }
.chip.t-red { color: var(--danger); }
.chip.t-green { color: var(--success); }
.chip.t-blue { color: var(--info); }
.chip.t-grey { color: var(--muted); }

/* hello + dayline */
.gb-eyebrow { font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--bc-muted); }
.gb-hello { margin-bottom: var(--bc-s3); }
.gb-hello-row { display: flex; align-items: center; justify-content: space-between; gap: var(--bc-s3); flex-wrap: wrap; }
.gb-hello .sub { color: var(--bc-muted); font-size: 15px; margin-top: 4px; }
.gb-dayline { background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: var(--bc-s3); }
.gb-dayline-top { display: flex; justify-content: space-between; align-items: baseline; gap: var(--bc-s3); font-size: 16px; }
.gb-stats { display: flex; gap: var(--bc-s4); flex-wrap: wrap; margin-top: 10px; font-size: 14px; color: var(--bc-muted); }
.gb-stats b { color: var(--bc-text); font-family: var(--bc-num); }

/* grid */
.gb-grid { display: grid; grid-template-columns: minmax(0,1fr) 320px; gap: var(--bc-s4); margin-top: var(--bc-s4); align-items: start; }
.gb-main { display: flex; flex-direction: column; gap: var(--bc-s4); }

/* now card */
.gb-now { background: var(--bc-surface); border: 1px solid var(--bc-accent); border-radius: var(--bc-r-card); padding: var(--bc-s4); box-shadow: 0 0 0 3px var(--bc-accent-soft); }
.gb-now.bc-empty { border-color: var(--bc-line); box-shadow: none; }
.gb-now-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.gb-meta { color: var(--bc-muted); font-size: 14px; }
.gb-now-title { font-family: var(--bc-display); font-size: 24px; line-height: 1.15; font-weight: 400; margin: 12px 0; letter-spacing: -.005em; }
.gb-why { margin: 0; }
.gb-why .bc-def { grid-template-columns: 150px 1fr; }
.gb-now-foot { display: flex; align-items: center; gap: var(--bc-s3); flex-wrap: wrap; border-top: 1px solid var(--bc-line); padding-top: var(--bc-s3); margin-top: var(--bc-s2); }
.gb-why .sep, .gb-now-title .sep { color: var(--bc-muted); }

/* lanes */
.gb-lane { }
.gb-lane-head { display: flex; align-items: baseline; gap: 10px; margin: 0 0 8px; flex-wrap: wrap; }
.gb-lane-head h3 { font-size: 15px; font-weight: 700; margin: 0; }
.gb-rule { font-size: 13px; color: var(--bc-muted); }
.gb-rows { display: flex; flex-direction: column; gap: var(--bc-s2); }
.gb-row { display: grid; grid-template-columns: 28px minmax(0,1fr) auto 18px; align-items: center; gap: var(--bc-s3); width: 100%; text-align: left; background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: 14px var(--bc-s3); cursor: pointer; font: inherit; color: inherit; transition: border-color var(--bc-motion) var(--bc-ease), transform var(--bc-motion) var(--bc-ease); }
.gb-row:hover { border-color: var(--bc-line-strong); }
.gb-row:active { transform: translateY(1px); }
.gb-row-n { font-family: var(--bc-num); color: var(--bc-muted); text-align: right; }
.gb-row-main { min-width: 0; }
.gb-row-t { display: block; font-weight: 600; }
.gb-row-m { display: block; font-size: 13px; color: var(--bc-muted); margin-top: 2px; }
.gb-row-reason { display: block; font-size: 14px; margin-top: 3px; }
.gb-row-side { display: flex; align-items: center; gap: 10px; }
.gb-due { font-size: 13px; }
.gb-row-chev { color: var(--bc-muted); font-size: 20px; }

/* aside */
.gb-aside { display: flex; flex-direction: column; gap: var(--bc-s3); }
.gb-card-h { font-size: 14px; font-weight: 700; margin-bottom: 10px; }
.gb-wait { border-top: 1px solid var(--bc-line); padding: 8px 0; font-size: 14px; }
.gb-wait:first-of-type { border-top: 0; padding-top: 0; }
.gb-wait .t { font-weight: 600; } .gb-wait .m, .gb-wait .d { display: block; font-size: 13px; color: var(--bc-muted); }
.gb-rhythm { list-style: none; margin: 0; padding: 0; counter-reset: r; }
.gb-rhythm li { counter-increment: r; position: relative; padding: 8px 0 8px 26px; border-top: 1px solid var(--bc-line); }
.gb-rhythm li:first-child { border-top: 0; }
.gb-rhythm li::before { content: counter(r); position: absolute; left: 0; top: 8px; width: 18px; height: 18px; border-radius: 50%; background: var(--bc-accent-soft); color: var(--bc-accent); font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.gb-rhythm b { display: block; font-size: 14px; } .gb-rhythm span { font-size: 13px; color: var(--bc-muted); }
.gb-shield { margin-top: 4px; }
.gb-oldmoney { font-size: 15px; }

/* ---------------- guided task screen ---------------- */
.gb-task { max-width: 1180px; }
.gb-back { display: inline-block; margin-bottom: var(--bc-s3); }
.gb-facts { display: flex; align-items: center; gap: var(--bc-s4); flex-wrap: wrap; background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: var(--bc-s3); }
.gb-who { display: flex; align-items: center; gap: 12px; }
.gb-av { width: 40px; height: 40px; border-radius: 50%; background: var(--bc-accent-soft); color: var(--bc-accent); font-weight: 700; display: flex; align-items: center; justify-content: center; font-family: var(--bc-num); }
.gb-who-name { display: block; font-weight: 700; } .gb-who-sub { display: block; font-size: 13px; color: var(--bc-muted); }
.gb-fact-grid { display: flex; gap: var(--bc-s4); flex-wrap: wrap; margin-left: auto; }
.gb-fact { display: flex; flex-direction: column; } .gb-fact .k { font-size: 12px; color: var(--bc-muted); } .gb-fact .v { font-weight: 600; }
.gb-titlebar { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--bc-s3); flex-wrap: wrap; margin-top: var(--bc-s3); }
.gb-titlebar .sub { color: var(--bc-muted); font-size: 14px; margin-top: 4px; }
.gb-seg { display: flex; gap: 6px; margin: var(--bc-s3) 0; }
.gb-seg i { flex: 1; height: 6px; border-radius: 999px; background: var(--bc-chip); transition: background var(--bc-motion) var(--bc-ease); }
.gb-seg i.on { background: color-mix(in srgb, var(--bc-accent) 55%, transparent); } .gb-seg i.cur { background: var(--bc-accent); }
.gb-desk { display: grid; grid-template-columns: 200px minmax(0,1fr) 300px; gap: var(--bc-s4); align-items: start; }
.gb-steps-col { position: sticky; top: 70px; }
.gb-steps { list-style: none; margin: 0; padding: 0; }
.gb-steps li { display: flex; gap: 10px; padding: 9px; border-radius: var(--bc-r-btn); color: var(--bc-muted); cursor: pointer; }
.gb-steps li:not(.disabled):hover { background: var(--bc-chip); }
.gb-steps li.disabled { cursor: default; opacity: .6; }
.gb-steps .c { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--bc-line-strong); display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-family: var(--bc-num); flex: none; }
.gb-steps li.cur { color: var(--bc-text); } .gb-steps li.cur .c { border-color: var(--bc-accent); color: var(--bc-accent); }
.gb-steps li.done { color: var(--bc-text); } .gb-steps li.done .c { border-color: var(--bc-ok-dot); color: var(--bc-ok-text); }
.gb-steps .l { font-size: 14px; } .gb-steps .ss { display: block; font-size: 12px; color: var(--bc-muted); }
.gb-stepcard { background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: var(--bc-s4); }
.gb-where { margin-bottom: 8px; }
.gb-sys { font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--bc-accent); }
.gb-step-title { font-size: 20px; font-weight: 700; margin: 0 0 12px; }
.gb-block h3 { font-size: 14px; margin: 0 0 6px; } .gb-do { font-size: 15px; }
.gb-donewhen { margin-top: var(--bc-s3); color: var(--bc-ok-text); font-size: 15px; }
.gb-donewhen b { color: var(--bc-ok-text); }
.gb-watch { margin-top: 10px; border: 1px solid color-mix(in srgb, var(--bc-late-dot) 45%, var(--bc-line)); background: color-mix(in srgb, var(--bc-late-dot) 8%, transparent); border-radius: var(--bc-r-btn); padding: 10px 12px; font-size: 14px; }
.gb-watch b { color: var(--bc-late-text); }
.gb-whyd { margin-top: var(--bc-s3); font-size: 14px; } .gb-whyd summary { cursor: pointer; color: var(--bc-accent); font-weight: 600; }
.gb-whyd > div { margin-top: 8px; color: var(--bc-muted); }
.gb-foot { display: flex; align-items: center; gap: var(--bc-s3); flex-wrap: wrap; border-top: 1px solid var(--bc-line); padding-top: var(--bc-s3); margin-top: var(--bc-s4); }
.gb-offramps { display: flex; gap: var(--bc-s3); flex-wrap: wrap; margin-top: var(--bc-s3); }
.gb-field { margin-top: var(--bc-s3); } .gb-field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.req { color: var(--bc-urgent-text); font-weight: 600; font-size: 12px; }
.gb-input { width: 100%; font: inherit; font-size: 15px; padding: 10px 12px; border: 1px solid var(--bc-line-strong); border-radius: var(--bc-r-btn); background: var(--bc-bg); color: var(--bc-text); }

/* record side + two-source timeline */
.gb-record-side { position: sticky; top: 70px; display: flex; flex-direction: column; gap: var(--bc-s3); }
.gb-timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.gb-timeline li { display: flex; gap: 12px; padding: 7px 0; position: relative; }
.gb-timeline li::before { content: ""; position: absolute; left: 6px; top: 20px; bottom: -7px; width: 2px; background: var(--bc-line); }
.gb-timeline li:last-child::before { display: none; }
.gb-timeline .dot { width: 14px; height: 14px; border-radius: 50%; flex: none; margin-top: 2px; border: 2px solid var(--bc-line-strong); background: var(--bc-surface); z-index: 1; }
.gb-timeline li.verified .dot { background: var(--bc-ok-dot); border-color: var(--bc-ok-dot); }
.gb-timeline li.manual .dot { background: var(--bc-surface); border-color: var(--bc-ok-dot); box-shadow: inset 0 0 0 2px var(--bc-ok-dot); }
.gb-timeline li.na { opacity: .55; }
.gb-timeline li.problem .dot { background: var(--bc-urgent-dot); border-color: var(--bc-urgent-dot); box-shadow: none; }
.gb-timeline li.problem .ms { color: var(--bc-urgent-text); }
.gb-legend .dot.problem { background: var(--bc-urgent-dot); border: none; }
.gb-hello-actions { display: flex; gap: var(--bc-s2); flex-wrap: wrap; align-items: center; }
.gb-timeline .ms { display: block; font-size: 14px; font-weight: 600; } .gb-timeline .d { display: block; font-size: 12px; color: var(--bc-muted); }
.gb-legend { display: flex; gap: var(--bc-s3); margin-top: 10px; font-size: 12px; color: var(--bc-muted); }
.gb-legend .dot { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 5px; vertical-align: -1px; }
.gb-legend .dot.verified { background: var(--bc-ok-dot); } .gb-legend .dot.manual { background: var(--bc-surface); border: 2px solid var(--bc-ok-dot); }
.gb-kv > div { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-top: 1px solid var(--bc-line); font-size: 14px; }
.gb-kv > div:first-child { border-top: 0; } .gb-kv .k { color: var(--bc-muted); } .gb-kv .v { font-weight: 600; text-align: right; }

/* checklists (account checks / finish my day) */
.gb-checklist { padding: 4px var(--bc-s3); }
.gb-check-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--bc-line); }
.gb-check-row:first-child { border-top: 0; }
.gb-check-main { flex: 1; } .gb-check-main b { display: block; }
.bc-review-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.bc-table-wrap { overflow-x: auto; margin-top: 8px; }
.bc-scope .bc-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.bc-scope .bc-table th { text-align: left; font-weight: 600; color: var(--bc-muted); border-bottom: 1px solid var(--bc-line); padding: 8px 10px; white-space: nowrap; }
.bc-scope .bc-table td { border-bottom: 1px solid var(--bc-line); padding: 8px 10px; vertical-align: top; }
.bc-scope .bc-review-table td:last-child { width: 1%; white-space: nowrap; }
.bc-scope .bc-table td:last-child { white-space: nowrap; }
/* No-Response row: payer status from Stedi (plan §11) — Tebra status, then the 2px left-rule payer line(s). Lines wrap
   inside the cell (the base .chip is nowrap) so the table never scrolls sideways. */
.bc-scope .bc-payer-status { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; margin-top: 6px; }
.bc-scope .bc-payer-status .bc-payer-tebra { font-size: 13px; }
.bc-scope .bc-payer-status .chip.bc-payer-line { white-space: normal; }
/* No-Response list (owner request 2026-10-31): eight columns. Patient (name only), DOS, Payer (who the claim waits on
   underneath), "Primary paid", Balance, Days (waiting + left to file share a cell), "Reason" (payer status underneath)
   and "Next step" (the payers' where-to-check hints, the last follow-up and the Record follow-up button underneath).
   Text wraps inside its cell, between words only, and each column keeps a floor width, so the table needs about 840px
   at its narrowest with short names and about 890px with a long one-word surname and payer ("Balasubramanian",
   "UnitedHealthcare"). The switch is on the room the LIST actually has (a container query on the wrap), not the
   window: below 900px of list width each claim stacks into a block with every value beside its column name
   (data-label), so nothing is ever cut off or scrolls sideways. In the portal shell with the nav rail open that is a
   table from a 1280px window up (list ~920px) and stacked at 1024px (list ~680px) and on a phone. Browsers without
   container queries stack at 760px. The 900px is only the no-script baseline: how wide the table must be depends on
   the names in it (a longer one-word surname or payer), so js/ekm-billing-command.js also stacks it (bc-nr-stacked on
   the wrap) whenever the table, laid out as a table, would be wider than the list. */
.bc-scope .bc-nr-wrap { container-type: inline-size; container-name: bcnr; --bc-nr-label: clamp(96px, 28%, 168px); }
.bc-scope .bc-nr-table th { white-space: normal; vertical-align: bottom; }
.bc-scope .bc-nr-table th, .bc-scope .bc-nr-table td { padding-left: 8px; padding-right: 8px; }
/* Names never break inside a word: a cell wraps only between words (break-word does not shrink a column below its
   longest word, so a long surname or payer name widens its column instead of splitting). Only the free-text
   where-to-check hints may break a very long token (a URL), so one can never push the table wider than the list. */
.bc-scope .bc-nr-table td { overflow-wrap: break-word; }
.bc-scope .bc-nr-table .bc-nr-where { overflow-wrap: anywhere; }
.bc-scope .bc-nr-table .chip { white-space: normal; }
.bc-scope .bc-nr-table .bc-nr-dos, .bc-scope .bc-nr-table .bc-nr-balance, .bc-scope .bc-nr-table .bc-nr-keep { white-space: nowrap; }
.bc-scope .bc-nr-table .bc-nr-patient { min-width: 92px; }
.bc-scope .bc-nr-table .bc-nr-payer { min-width: 104px; }
.bc-scope .bc-nr-table .bc-nr-days { min-width: 92px; }
.bc-scope .bc-nr-table .bc-nr-reason { min-width: 136px; }
.bc-scope .bc-nr-table .bc-nr-next { min-width: 180px; }
.bc-scope .bc-nr-table td:last-child { white-space: normal; }
.bc-scope .bc-nr-table .bc-btn { font-size: 14px; padding: 6px 12px; line-height: 1.25; margin-top: 8px; }
.bc-scope .bc-nr-days-wait, .bc-scope .bc-nr-days-left { display: block; }
.bc-scope .bc-nr-days-left { margin-top: 2px; }
.bc-scope .bc-nr-reason-text { display: block; font-weight: 600; }
.bc-scope .bc-nr-next-text { display: block; }
.bc-scope .bc-nr-waiting, .bc-scope .bc-nr-where, .bc-scope .bc-nr-escalate, .bc-scope .bc-nr-lastfu { display: block; margin-top: 4px; font-size: 13px; }
.bc-scope .bc-nr-urgent { color: var(--danger); font-weight: 700; }
.bc-scope .bc-nr-lastfu-hidden { color: var(--warning); }
/* stacked because the table would scroll sideways with these names (the script's measurement; same look as below) */
.bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table, .bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table tbody, .bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table tr { display: block; width: 100%; }
.bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table tr { padding: 10px 0; border-bottom: 1px solid var(--bc-line); }
.bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table td { display: grid; grid-template-columns: var(--bc-nr-label) minmax(0, 1fr); column-gap: 12px; width: 100%; min-width: 0; padding: 4px 0; border-bottom: 0; }
.bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table td::before { content: attr(data-label); font-size: 12px; font-weight: 600; line-height: 1.5; color: var(--bc-muted); }
.bc-scope .bc-nr-wrap.bc-nr-stacked .bc-nr-table .bc-nr-v { min-width: 0; }
@container bcnr (max-width: 899.98px) {
  .bc-scope .bc-nr-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .bc-scope .bc-nr-table, .bc-scope .bc-nr-table tbody, .bc-scope .bc-nr-table tr { display: block; width: 100%; }
  .bc-scope .bc-nr-table tr { padding: 10px 0; border-bottom: 1px solid var(--bc-line); }
  .bc-scope .bc-nr-table td { display: grid; grid-template-columns: var(--bc-nr-label) minmax(0, 1fr); column-gap: 12px; width: 100%; min-width: 0; padding: 4px 0; border-bottom: 0; }
  .bc-scope .bc-nr-table td::before { content: attr(data-label); font-size: 12px; font-weight: 600; line-height: 1.5; color: var(--bc-muted); }
  .bc-scope .bc-nr-table .bc-nr-v { min-width: 0; }
}
@supports not (container-type: inline-size) {
  @media (max-width: 760px) {
    .bc-scope .bc-nr-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    .bc-scope .bc-nr-table, .bc-scope .bc-nr-table tbody, .bc-scope .bc-nr-table tr { display: block; width: 100%; }
    .bc-scope .bc-nr-table tr { padding: 10px 0; border-bottom: 1px solid var(--bc-line); }
    .bc-scope .bc-nr-table td { display: grid; grid-template-columns: 38% minmax(0, 1fr); column-gap: 12px; width: 100%; min-width: 0; padding: 4px 0; border-bottom: 0; }
    .bc-scope .bc-nr-table td::before { content: attr(data-label); font-size: 12px; font-weight: 600; line-height: 1.5; color: var(--bc-muted); }
  }
}
.bc-scope .bc-payer-unavailable { margin: 0 0 14px; padding: 10px 16px; border: 1px solid var(--bc-line); border-left: 3px solid var(--warning); border-radius: 5px; background: var(--warning-tint); color: var(--warning); font-size: 14px; font-weight: 600; }
/* Claim status — needs review (claim-status PR 1): one stacked block per claim, wraps at any width (no sideways scroll) */
.bc-scope .bc-csr { margin: 0 0 18px; }
.bc-scope .bc-csr-intro { margin: 0 0 8px; }
.bc-scope .bc-csr-item { margin: 0 0 8px; padding: 10px 14px; border: 1px solid var(--bc-line); border-left: 3px solid var(--warning); border-radius: 5px; font-size: 14px; overflow-wrap: break-word; }
.bc-scope .bc-csr-item > div + div { margin-top: 4px; }
.bc-scope .bc-csr-why { font-weight: 600; }
.gb-check-dot { width: 12px; height: 12px; border-radius: 50%; flex: none; }
.gb-check-dot.yes { background: var(--bc-ok-dot); } .gb-check-dot.no { background: var(--bc-late-dot); }

/* off-ramp modal */
.bc-modal-back { position: fixed; inset: 0; background: rgba(0,0,0,.45); display: flex; align-items: center; justify-content: center; z-index: 60; padding: var(--bc-s3); }
.bc-modal { background: var(--bc-surface); color: var(--bc-text); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); max-width: 460px; width: 100%; padding: var(--bc-s4); box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.bc-modal-h { font-size: 18px; font-weight: 700; margin-bottom: 10px; }
.bc-modal-body { font-size: 14px; } .bc-modal-body .gb-input { margin-top: 10px; }
.bc-modal-foot { display: flex; align-items: center; margin-top: var(--bc-s4); }

/* responsive */
@media (max-width: 1100px) { .gb-grid { grid-template-columns: 1fr; } .gb-desk { grid-template-columns: 1fr; } .gb-steps-col, .gb-record-side { position: static; } }

/* rewritten-step rows: Start from / What you should see / How to know it's right / If you see something else / screenshot slot */
.gb-startfrom { margin: 0 0 12px; font-size: 14px; background: var(--bc-chip); border-radius: var(--bc-r-btn); padding: 9px 12px; }
.gb-startfrom b { color: var(--bc-muted); font-weight: 700; margin-right: 6px; }
.gb-see { margin-top: var(--bc-s3); }
.gb-see h4, .gb-block h3 { font-size: 14px; margin: 0 0 6px; }
.gb-see ul { margin: 0; padding-left: 20px; } .gb-see li { margin: 4px 0; font-size: 14px; }
.gb-rightwhen { margin-top: 10px; font-size: 14px; display: flex; gap: 8px; align-items: flex-start; }
.gb-rightwhen b { color: var(--bc-ok-text); white-space: nowrap; }
.gb-ifelse { margin-top: 10px; border: 1px solid color-mix(in srgb, var(--bc-urgent-dot) 30%, var(--bc-line)); background: color-mix(in srgb, var(--bc-urgent-dot) 7%, transparent); border-radius: var(--bc-r-btn); padding: 10px 12px; font-size: 14px; }
.gb-ifelse b { color: var(--bc-urgent-text); }
.gb-shot { margin-top: var(--bc-s3); border: 1px dashed var(--bc-line-strong); border-radius: var(--bc-r-btn); padding: 13px; text-align: center; font-size: 13px; color: var(--bc-muted); background: var(--bc-chip); }
.gb-shot::before { content: "\1F4F7"; margin-right: 6px; }
.gb-confirm-notes { margin-top: 10px; }
.gb-confirm-notes ul { margin: 6px 0 0; padding-left: 20px; font-size: 14px; }
.gb-confirm-notes li { margin: 3px 0; color: var(--bc-muted); }
.gb-warnbanner { margin-top: var(--bc-s3); border: 1px solid color-mix(in srgb, var(--bc-urgent-dot) 40%, var(--bc-line)); background: color-mix(in srgb, var(--bc-urgent-dot) 9%, transparent); color: var(--bc-urgent-text); border-radius: var(--bc-r-btn); padding: 12px 14px; font-weight: 600; font-size: 15px; }

/* scripts + answer fields + result choices + next-preview */
.gb-intro { color: var(--bc-muted); margin: -4px 0 12px; }
.gb-script { border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); margin-top: var(--bc-s3); overflow: hidden; }
.gb-script-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--bc-chip); padding: 10px 12px; font-size: 13px; font-weight: 700; }
.gb-script-text { padding: 12px; font-size: 14px; white-space: pre-wrap; line-height: 1.5; }
.gb-script-text mark { background: var(--bc-accent-soft); color: var(--bc-text); padding: 0 3px; border-radius: 4px; }
.gb-calllog { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 12px 12px; }
.gb-field.wide, .gb-calllog .gb-field.wide { grid-column: 1 / -1; }
.gb-field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.gb-choices-wrap { margin-top: var(--bc-s3); }
.gb-choices-label { font-size: 13px; font-weight: 700; color: var(--bc-muted); margin-bottom: 8px; }
.gb-choices { display: flex; flex-direction: column; gap: 8px; }
.gb-choice { display: grid; grid-template-columns: 20px 1fr 20px; gap: 10px; align-items: start; text-align: left; width: 100%; font: inherit; color: inherit; background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: 12px; cursor: pointer; }
.gb-choice:hover { border-color: var(--bc-line-strong); }
.gb-choice.selected { border-color: var(--bc-accent); background: var(--bc-accent-soft); }
.gb-radio { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--bc-line-strong); margin-top: 2px; }
.gb-choice.selected .gb-radio { border-color: var(--bc-accent); box-shadow: inset 0 0 0 3px var(--bc-accent); }
.gb-choice-main b { display: block; } .gb-choice-main .d { display: block; font-size: 13px; color: var(--bc-muted); margin-top: 2px; }
.gb-choice-key { font-family: var(--bc-num); color: var(--bc-muted); font-size: 12px; text-align: right; }
/* Result preview — full width under the choices (not squeezed inside one choice). */
.gb-next-wrap { margin-top: var(--bc-s3); border: 1px dashed var(--bc-line-strong); border-radius: var(--bc-r-btn); padding: 12px 14px; }
.gb-next-h { font-size: 13px; font-weight: 700; color: var(--bc-muted); margin-bottom: 8px; }
.gb-next-preview { display: grid; grid-template-columns: 120px 1fr; gap: 6px 16px; font-size: 14px; margin: 0; }
.gb-next-preview dt { color: var(--bc-muted); } .gb-next-preview dd { margin: 0; font-weight: 500; }
@media (max-width: 760px) { .gb-next-preview { grid-template-columns: 1fr; gap: 2px; } }
@media (max-width: 760px) { .gb-calllog { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- owner-only access panel (go-live switch) */
/* Rendered inside Roles & Workflows (owner only). Lets the owner turn the Command Center on per person. */
#bc-access-panel { margin-top: var(--bc-s4); }
.bc-access-card { background: var(--bc-surface); border: 1px solid var(--bc-line); border-radius: var(--bc-r-card); padding: 16px 18px; max-width: 560px; }
.bc-access-head { font-size: 15px; font-weight: 700; color: var(--bc-text); }
.bc-access-sub { font-size: 13px; color: var(--bc-muted); margin: 4px 0 12px; }
.bc-access-status { font-size: 13px; color: var(--bc-muted); min-height: 1.1em; margin-bottom: 8px; }
.bc-access-list { display: flex; flex-direction: column; gap: 8px; }
.bc-access-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 10px; border: 1px solid var(--bc-line); border-radius: var(--bc-r-btn); }
.bc-access-email { font-size: 14px; color: var(--bc-text); word-break: break-all; }
.bc-access-toggle { flex: none; min-width: 56px; padding: 6px 14px; border: 1px solid var(--bc-line-strong); border-radius: var(--bc-r-btn); background: var(--bc-chip); color: var(--bc-muted); font-weight: 700; font-size: 13px; cursor: pointer; transition: background var(--bc-motion) var(--bc-ease), color var(--bc-motion) var(--bc-ease); }
.bc-access-toggle.on { background: var(--bc-accent); color: var(--bc-on-accent); border-color: var(--bc-accent); }
.bc-access-toggle:disabled { opacity: .55; cursor: progress; }
.bc-access-row { flex-wrap: wrap; }
.bc-access-email { flex: 1 1 200px; min-width: 0; }
.bc-access-hide { flex: none; min-height: 44px; padding: 6px 12px; border: 1px solid var(--bc-line-strong); border-radius: var(--bc-r-btn); background: var(--bc-chip); color: var(--bc-muted); font-weight: 600; font-size: 13px; cursor: pointer; }
.bc-access-hide.on { border-color: var(--bc-accent); color: var(--bc-text); }
.bc-access-hide:disabled { opacity: .55; cursor: progress; }
.bc-access-fixed { flex: none; font-size: 13px; color: var(--bc-muted); }
.bc-access-empty, .bc-access-err { font-size: 13px; color: var(--bc-muted); }
.bc-access-err { color: var(--bc-urgent-text); }

/* ---------------------------------------------------------------- 3-tab reorganization (Unbilled · Insurance A/R · Patient responsibility) */
.bc-synced { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--bc-muted); margin: 4px 0 14px; }
.bc-synced.is-behind { color: var(--bc-urgent-text); }
.bc-sync-warn { margin-left: 6px; color: var(--bc-urgent-text); font-weight: 700; }
.bc-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--bc-line); margin-bottom: 16px; flex-wrap: wrap; }
.bc-tab { appearance: none; background: none; border: 0; border-bottom: 2px solid transparent; padding: 10px 14px; font: inherit; font-weight: 600; color: var(--bc-muted); cursor: pointer; }
.bc-tab:hover { color: var(--bc-text); }
.bc-tab.is-active { color: var(--bc-text); border-bottom-color: var(--bc-text); }  /* top tab: --text underline (§6.2) */
.bc-tab-count { margin-left: 4px; color: var(--bc-faint); font-weight: 400; font-family: var(--bc-num); font-variant-numeric: tabular-nums; }  /* plain count, not a pill */
.bc-subtabs { display: flex; gap: 18px; border-bottom: 1px solid var(--bc-line-strong); margin: 14px 0; }
.bc-subtab { appearance: none; background: none; border: 0; border-bottom: 2px solid transparent; padding: 8px 2px; font: inherit; font-weight: 600; color: var(--bc-muted); cursor: pointer; }
.bc-subtab.is-active { color: var(--bc-text); border-bottom-color: var(--bc-accent); }
.bc-age-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 10px 0; }
.bc-age-cell { border: 1px solid var(--bc-line); border-radius: var(--bc-r-btn); padding: 10px 12px; }
.bc-age-cell .k { font-size: 12px; color: var(--bc-muted); }
.bc-age-cell .v { font-size: 18px; font-weight: 700; color: var(--bc-text); font-family: var(--bc-num); }
.bc-pr-list { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.bc-pr-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border: 1px solid var(--bc-line); border-radius: var(--bc-r-btn); }
@media (max-width: 760px) { .bc-age-row { grid-template-columns: repeat(2, 1fr); } .bc-pr-row { flex-direction: column; align-items: flex-start; } }
