/* BILLING — NEW VIEW (Billing Run Overhaul §3/§7, P1-a 2026-10-02). Everything here is scoped to `#panel-accounting.acc-new`
 * (billingLayout.js sets the class only when the user picked New), so Classic is untouched — byte for byte
 * (test-billing-classic-byte-identical). The run itself is drawn by components/workRun.js (css/work-run.css); this sheet
 * only hides Classic's tab rails under New and sizes the Billing columns. Skin B: tokens only, square corners. */

/* Under New the stage strip replaces the Work | A/R | More rail and the lifecycle pills; the filter row and search stay. */
#panel-accounting.acc-new #emr-bill-groups,
#panel-accounting.acc-new #emr-bill-tabs { display: none; }

/* The run inside #acc-body */
#panel-accounting.acc-new .bill-run { border: 1px solid var(--border); background: var(--bg); }
#panel-accounting.acc-new .bill-run .run-table { table-layout: auto; }
#panel-accounting.acc-new .bill-run .run-td-lane { max-width: 260px; overflow: hidden; text-overflow: ellipsis; }
#panel-accounting.acc-new .bill-run .run-td-pw { white-space: nowrap; }
#panel-accounting.acc-new .bill-run .run-td-next { white-space: nowrap; }
#panel-accounting.acc-new .bill-run .emr-bill-pager { border-top: 1px solid var(--border); }

/* STICKY STAGES (Ed 2026-10-03, every New view): the strip sticks to the top of #acc-body (the billing scroll area). The
   6 px shadow covers that container's top padding so no row shows through above the strip. */
#panel-accounting.acc-new .bill-run > .run-strip { position: sticky; top: 0; z-index: 6; box-shadow: 0 -6px 0 var(--bg); }

/* COLOURS (Ed 2026-10-03: "billing new also does not have colors") — the same ink tokens as Orders New, theme-aware:
   each stage chip and its strip count carry the stage's ink; paperwork ✓ green / ✗ red; the est (not invoiced) amount
   stays muted. */
#panel-accounting.acc-new .bill-run .run-chip.tone-ready    { color: var(--ink-violet, var(--ink-info)); }
#panel-accounting.acc-new .bill-run .run-chip.tone-ready::before    { background: var(--ink-violet, var(--ink-info)); border-color: var(--ink-violet, var(--ink-info)); }
#panel-accounting.acc-new .bill-run .run-chip.tone-invoiced { color: var(--ink-info); }
#panel-accounting.acc-new .bill-run .run-chip.tone-invoiced::before { background: var(--ink-info); border-color: var(--ink-info); }
#panel-accounting.acc-new .bill-run .run-chip.tone-pre      { color: var(--text3); }
/* the strip tiles and next steps take the shared status inks (work-run.css); Billing's one difference: an invoice is
   mid-pipeline here (blue), where Orders' "Invoiced" is done (green) */
#panel-accounting.acc-new .bill-run .tone-invoiced { --run-ink: var(--ink-info); }
#panel-accounting.acc-new .bill-run .run-pw          { color: var(--ink-ok); font-weight: 700; }
#panel-accounting.acc-new .bill-run .run-pw.is-miss  { color: var(--ink-bad); }
