:root {
    --page:#f6f7f9; --surface:#fff; --surface-muted:#f5f7fb; --ink:#161c2d;
    --ink-soft:#394255; --muted:#5e687b; --border:#dce3eb; --primary:#2463d3;
    --primary-dark:#184da9; --primary-soft:#eaf1fc; --success:#176844; --success-soft:#e5f5ed;
    --warning:#86510a; --warning-soft:#fff3db; --danger:#a33047; --danger-soft:#fdecef;
    --info:#23598f; --info-soft:#e9f3ff; --radius:14px; --sidebar:226px;
    --shadow:0 2px 4px #141f3709,0 12px 30px -18px #141f372e;
}
* { box-sizing:border-box }
[hidden] { display:none!important }
html { scroll-padding-top:84px; scroll-padding-bottom:84px }
body { margin:0; background:var(--page); color:var(--ink-soft); font:14px/1.45 Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif }
body:not(.print)::before { content:""; position:fixed; inset:0 0 auto; height:5px; z-index:12; background:linear-gradient(90deg,#2463d3,#4c7fe0,#36a1c3) }
a { color:var(--primary); text-underline-offset:3px }
:where(a,button,input,select,textarea,summary,[tabindex]):focus-visible { outline:3px solid #7fa7ec; outline-offset:2px }
.skip-link { position:fixed; top:8px; left:10px; z-index:14; transform:translateY(-160%); background:#fff; padding:10px }
.skip-link:focus { transform:none }
.sidebar { position:fixed; inset:5px auto 0 0; z-index:9; width:var(--sidebar); background:#fff; border-right:1px solid var(--border); padding:18px 14px 12px; display:flex; flex-direction:column; overflow:auto }
.brand-row { display:flex; justify-content:space-between; align-items:center }
.brand { display:flex; gap:10px; align-items:center; padding:6px 9px 17px; color:var(--ink); text-decoration:none; font-size:17px; font-weight:750; letter-spacing:-.03em }
.brand .brand-mark { display:grid; place-items:center; width:32px; height:32px; border-radius:9px; background:linear-gradient(145deg,#4b83e5,#2463d3); color:#fff; box-shadow:0 3px 9px #2463d344 }
.brand small { display:block; font-size:10px; font-weight:550; letter-spacing:.02em }
.nav-toggle { display:none }
nav { display:grid; gap:3px }
nav a,nav summary { display:block; min-height:38px; padding:9px 11px; border-radius:9px; font-size:13px; color:var(--muted); text-decoration:none; font-weight:620 }
nav summary { display:list-item }
nav details { margin:0 }
nav details a { margin-left:9px; padding-left:14px; font-size:12px }
nav a:hover,nav summary:hover { background:var(--surface-muted); color:var(--ink) }
nav a[aria-current] { background:var(--primary-soft); color:var(--primary-dark); font-weight:750 }
.aside-note { margin:auto 0 0; padding:14px 8px 3px; color:var(--muted); font-size:11px }
main { margin-left:var(--sidebar); min-width:0 }
.topbar { position:sticky; top:5px; z-index:7; min-height:61px; display:flex; align-items:center; gap:14px; padding:9px 26px; background:#fff; border-bottom:1px solid var(--border) }
.workspace-location { color:var(--ink); font-size:13px; font-weight:700; margin-right:auto }
.topbar label { display:flex; gap:8px; align-items:center }
.topbar select { max-width:270px }
.content { max-width:1550px; margin:auto; padding:23px 26px 46px }
.page-head { margin:0 0 16px }
h1 { margin:0; color:var(--ink); font-size:26px; line-height:1.2; letter-spacing:-.045em; font-weight:740 }
h2 { margin:0 0 9px; font-size:16px; color:var(--ink); letter-spacing:-.02em }
h3 { margin:14px 0 6px; font-size:13px; color:var(--ink) }
.subtitle,.muted,small { color:var(--muted) }
.subtitle { margin:4px 0 0; font-size:13px }
p { margin:7px 0 11px }
.card { min-width:0; padding:14px 16px; margin-bottom:11px; border:1px solid var(--border); border-radius:var(--radius); background:var(--surface); box-shadow:var(--shadow) }
.metrics { display:grid; grid-template-columns:repeat(auto-fit,minmax(135px,1fr)); gap:11px; margin:10px 0 14px }
.metrics .card { margin:0; padding:13px 15px }
.metrics span { display:block; font-size:12px; color:var(--muted) }
.metrics strong { display:block; color:var(--ink); margin-top:4px; font-size:22px; letter-spacing:-.035em; font-variant-numeric:tabular-nums }
.columns { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:11px }
.bar,.fields,.action-bar,.inline,.save-bar { display:flex; flex-wrap:wrap; align-items:end; gap:8px 10px }
.bar { margin-bottom:10px }
.bar h2 { margin:0 auto 0 0 }
.fields { margin:8px 0 }
.action-bar { align-items:center; position:sticky; top:66px; z-index:5; box-shadow:0 3px 8px #17203912 }
.action-bar small { margin-left:7px }
.save-bar { position:sticky; z-index:4; bottom:0; align-items:center; background:#fff; border-top:1px solid var(--border); padding:8px 0; margin-top:6px }
.line { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; padding:8px 0; border-bottom:1px solid var(--border) }
.line small,.row-item small { display:block }
label { display:grid; gap:3px; font-size:12px; color:#414b5e; font-weight:650; min-width:0 }
label:has([type=checkbox]) { display:flex; align-items:center }
input,select,textarea,button,.button { font:inherit; font-size:13px; min-height:36px; border-radius:8px }
input,select,textarea { border:1px solid #cbd3df; background:#fff; color:var(--ink); padding:6px 8px; max-width:100%; min-width:0 }
input[readonly] { background:var(--surface-muted); color:var(--muted) }
textarea { min-width:min(270px,100%); min-height:70px; resize:vertical }
input[type=checkbox] { min-height:0; accent-color:var(--primary) }
summary { cursor:pointer; font-weight:650 }
.table-wrap { overflow:auto; max-width:100% }
table { width:100%; border-collapse:separate; border-spacing:0; text-align:left }
th,td { padding:8px 10px; border-bottom:1px solid var(--border); vertical-align:middle; overflow-wrap:anywhere }
th { background:#fafbfd; color:#536076; white-space:nowrap; font-size:11px; font-weight:750; letter-spacing:.035em; text-transform:uppercase }
td { font-size:13px }
td small { display:block; margin-top:3px }
tr:hover td { background:#fbfcfe }
.register-scroll { max-height:61vh }
.register-scroll th { position:sticky; top:0; z-index:2 }
.register-scroll :is(th,td):first-child { position:sticky; left:0; min-width:120px; background:#fff; z-index:1; box-shadow:1px 0 var(--border) }
.register-scroll th:first-child { z-index:3; background:#fafbfd }
.register-tools { align-items:end }
.register-tools [data-count] { padding-bottom:7px; color:var(--muted); font-size:12px }
.money { white-space:nowrap; text-align:right; font-variant-numeric:tabular-nums }
.empty-note { color:var(--muted); padding:14px 0 0 }
.notice a { color:inherit; font-weight:700 }
.crumb { display:flex; flex-wrap:wrap; align-items:center; gap:5px 8px; margin:0 0 8px; font-size:12px }
.return-link { margin-left:auto }
.print { margin:25px auto; max-width:950px; padding:16px; background:#fff }
.print h1 { margin-top:14px }
.source-data { white-space:pre-wrap; overflow-wrap:anywhere }
.import-context { display:flex; flex-wrap:wrap; gap:5px 16px; align-items:center; border-left:3px solid var(--primary); font-size:13px }
.grid-tools,.grid-options { display:flex; flex-wrap:wrap; gap:6px 15px; align-items:center; margin-bottom:6px }
.grid-tools p { margin:2px auto 2px 0 }
.compact-editor { width:100%; min-width:0 }
.grid-group { padding:6px 8px; background:var(--primary-soft); color:var(--ink); border-radius:6px; margin:9px 0 0 }
.compact-row { display:grid; align-items:center; gap:6px 8px; padding:7px 2px; border-bottom:1px solid var(--border); min-width:0 }
.compact-row input:not([type=checkbox]) { width:100%; min-height:32px; padding:4px 6px; font-variant-numeric:tabular-nums }
.compact-row .row-item,.compact-row .row-value { min-width:0; overflow-wrap:anywhere }
.row-value { font-size:12px; font-variant-numeric:tabular-nums }
.row-value small { display:block; font-size:11px }


.client-row { grid-template-columns:minmax(135px,1.5fr) minmax(135px,1fr) minmax(105px,.85fr) 54px 112px }
.grid-extra { grid-column:1/-1; display:flex; flex-wrap:wrap; align-items:center; gap:7px 13px; padding:6px 8px; background:var(--surface-muted); border-radius:6px }
.row-reason,.row-extra { margin:0 }
.row-reason summary,.row-extra summary { color:var(--primary-dark); font-size:12px; padding:5px 6px; white-space:nowrap }
.row-reason summary:has([data-required]) { color:var(--danger) }
.row-reason[open] { display:contents }
.row-reason textarea { grid-column:1/-1; width:100%; min-height:54px; background:#fafaff }
.row-extra[open] { grid-column:1/-1; padding:6px 8px; background:var(--surface-muted); border-radius:6px }
.compact-row .row-reason:not([open]) { justify-self:end }
.changed { background:var(--primary-soft)!important }
.mobile-grid-toggle { display:none }
@media(max-width:1150px) {
    :root { --sidebar:190px }
    .content,.topbar { padding-left:17px; padding-right:17px }
}
@media(max-width:1000px) {
    .compact-row { grid-template-columns:repeat(2,minmax(0,1fr)); gap:7px 11px; padding:10px 0 }
    .compact-row .row-item { grid-column:1/-1 }
    .compact-row .row-reason:not([open]) { justify-self:start }
    .mobile-grid-toggle { display:inline-flex }
    .comparison-grid { overflow:auto }
    .comparison-grid .row-item { grid-column:auto }
}
@media(max-width:760px) {
    html { scroll-padding-top:12px }
    .sidebar { position:static; width:auto; padding:9px 12px 5px; border-right:0; border-bottom:1px solid var(--border) }
    .brand { padding:5px 2px 8px }
    .nav-toggle { display:inline-flex }

    .aside-note { display:none }
    main { margin:0 }
    .topbar { position:static; flex-wrap:wrap; gap:7px 10px; padding:8px 12px }
    .workspace-location { display:none }
    .topbar label { display:grid; gap:2px }
    .topbar select { max-width:min(200px,55vw) }
    .content { padding:16px 11px 30px }
    .columns { grid-template-columns:minmax(0,1fr) }
    .card { padding:11px }
    .action-bar { position:static }
    button,.button,input:not([type=checkbox]),select,.compact-row input:not([type=checkbox]) { min-height:44px }
    .row-reason summary,.row-extra summary { display:flex; align-items:center; gap:4px; min-height:44px }
    .metrics { grid-template-columns:repeat(2,minmax(0,1fr)) }
    h1 { font-size:23px }
}
@media print {
    .sidebar,.topbar,.skip-link,button { display:none!important }
    main { margin:0 }
    body { background:#fff }
    .card { box-shadow:none; break-inside:avoid }
    .table-wrap { overflow:visible }
}


.sov-table td { vertical-align:middle }
.sov-table .sov-edit-row > td { background:var(--surface-muted); padding:12px 14px }
.sov-edit-row section { scroll-margin-top:75px }
.sov-edit-row h3 { margin:0 0 8px }
.sov-inline-form { display:grid; grid-template-columns:repeat(auto-fit,minmax(145px,1fr)); gap:8px 12px; align-items:end }
.sov-inline-form :is(input:not([type=checkbox]),select) { width:100% }
.sov-inline-actions,.sov-impact { grid-column:1/-1 }
.sov-inline-actions { display:flex; gap:8px }
@media(max-width:760px) {
    .sov-inline-form { width:min(70vw,480px); grid-template-columns:repeat(2,minmax(0,1fr)) }
}

.claim-detail-section { margin-top:10px; padding-top:7px; border-top:1px solid var(--border) }
.claim-detail-section h3:first-child { margin-top:3px }

.claim-editor,.head-editor { position:relative }
.claim-editor {
    --assessment-columns:minmax(125px,1.5fr) repeat(3,minmax(90px,1fr)) minmax(68px,.7fr)
        minmax(90px,1fr) minmax(68px,.7fr) repeat(2,minmax(90px,1fr)) minmax(67px,.7fr)
        repeat(2,minmax(90px,1fr)) minmax(54px,.65fr) 96px;
    overflow-x:auto;
}
.head-editor {
    --head-columns:minmax(150px,1.8fr) repeat(2,minmax(76px,1fr)) minmax(70px,.7fr) repeat(2,minmax(90px,1fr)) 62px 96px;
    overflow-x:auto;
}
.claim-grid-head,.head-grid-head {
    display:grid;
    align-items:center;
    gap:6px;
    padding:6px 2px;
    font-size:11px;
    font-weight:750;
    background:var(--surface-muted);
    color:var(--ink-soft);
}
.claim-row,.claim-grid-head { grid-template-columns:var(--assessment-columns); min-width:1280px; gap:6px }
.head-row,.head-grid-head { grid-template-columns:var(--head-columns); min-width:720px; gap:6px }
.claim-row .row-reason summary { white-space:normal }
.sr-only,.claim-row > label > span,.claim-row > .row-value > small,.head-row > label > span,.head-row > .row-value > small {
    position:absolute;
    width:1px;
    height:1px;
    padding:0;
    overflow:hidden;
    clip-path:inset(50%);
    white-space:nowrap;
}
.claim-row input { min-width:0; text-align:right }
.claim-row .row-value,.head-row .row-value { font-variant-numeric:tabular-nums }
.claim-row .phone-difference { display:none }
.sov-reference-group { padding:8px 0; margin:5px 0 }
@media(min-width:761px) {
    input:not([type=checkbox]),select,button,.button { min-height:32px; padding-top:4px; padding-bottom:4px }
    th,td { padding-top:6px; padding-bottom:6px }
}
@media(max-width:1000px) {
    .claim-editor:not(.comparison-grid) .claim-grid-head,.head-grid-head { display:none }
    .claim-editor:not(.comparison-grid) .claim-row,.head-row { grid-template-columns:repeat(2,minmax(0,1fr)); min-width:0 }
    .claim-editor:not(.comparison-grid) .claim-row > label > span,
    .claim-editor:not(.comparison-grid) .claim-row > .row-value > small,
    .head-row > label > span,.head-row > .row-value > small {
        position:static;
        width:auto;
        height:auto;
        overflow:visible;
        clip-path:none;
        white-space:normal;
    }
    .claim-editor:not(.comparison-grid) .claim-row .phone-difference:not(:empty) { display:block }
    .claim-editor:not(.comparison-grid) .claim-row .grid-empty { display:none }
    .comparison-grid .claim-row .row-item { grid-column:auto }
}

.claim-context{display:flex;flex-wrap:wrap;gap:.6rem 1.65rem;margin:0 0 1rem;padding:.85rem 1rem;background:#fff;border:1px solid #e0e6ea;border-radius:.5rem}
.claim-context dt{font-size:.78rem;color:#475569}
.claim-context dd{margin:0;font-weight:600}
.claim-tabs[hidden],[data-claim-tabs] [role="tabpanel"][hidden]{display:none}

tfoot th,tfoot td,.grid-subtotal{background:#eef5f5;border-top:2px solid #c3d7d9;font-weight:700}
tfoot td small,.grid-subtotal em{display:block;color:#475569;font-size:.7rem;font-weight:500;font-style:normal}
.grid-subtotal[hidden]{display:none}
@media(max-width:900px){
    .claim-editor:not(.comparison-grid) .grid-subtotal > strong,.head-editor .grid-subtotal > strong{grid-column:1/-1}
    .head-editor .grid-subtotal > .grid-empty{display:none}
}

/* Shared financial alignment and section bands (prototype v27). */
.money, input[inputmode="decimal"], input[type="number"],
.claim-row > .row-value, .head-row > .row-value,
.claim-grid-head > :nth-child(n+2):nth-child(-n+13),
.head-grid-head > :nth-child(n+2):nth-child(-n+6) {
    text-align:right;
    font-variant-numeric:tabular-nums;
}
table:has([data-total-column="1"]) thead th:nth-child(2),
table:has([data-total-column="2"]) thead th:nth-child(3),
table:has([data-total-column="3"]) thead th:nth-child(4),
table:has([data-total-column="4"]) thead th:nth-child(5),
table:has([data-total-column="5"]) thead th:nth-child(6),
table:has([data-total-column="6"]) thead th:nth-child(7),
.sov-table thead th:nth-child(3), .sov-table tbody tr[id] > td:nth-child(3),
.assessment-comparison :is(th,td):nth-child(n+2):nth-child(-n+5),
.forecast-table :is(th,td):last-child {
    text-align:right;
    font-variant-numeric:tabular-nums;
}
.grid-group, .grid-subtotal, .claim-grid-head, .head-grid-head, tfoot tr > * {
    border-radius:0;
}
.grid-group, .grid-subtotal, tfoot tr > * {
    padding-block:6px;
    font-size:.875rem;
}
.grid-group, .grid-subtotal > strong, tfoot th { padding-inline-start:10px }
.grid-subtotal > strong, tfoot th, tfoot td, .grid-subtotal { font-weight:600 }
.claim-action-bar { margin-block-end:1rem }
.claim-header-details { margin-block-end:1rem }
@media(max-width:700px) {
    .claim-action-bar { position:sticky; top:0 }
}

.claim-tabs { flex-wrap:wrap }
.claim-grid-head, .head-grid-head { padding-inline:2px }
.claim-editor, .head-editor, .register-scroll { scrollbar-width:auto }
.fields > label, .inline > label, .sov-inline-form > label { max-width:100%; overflow-wrap:anywhere }
.fields :is(input,select,textarea), .sov-inline-form :is(input,select,textarea) { width:100% }
.fields input[type=checkbox], .sov-inline-form input[type=checkbox] { width:auto; flex:none }
.client-row [name^="clientPercent"], .client-row [name^="clientLine"] { text-align:right }
@media(max-width:760px) {
    .topbar { flex-wrap:wrap; gap:6px 12px }
    .topbar form { min-width:0; max-width:100% }
    .topbar select { min-width:0 }
}

.table-wrap :is(th,td) { padding-inline:5px; border-inline-end:1px solid var(--border) }
.table-wrap :is(th,td):last-child { border-inline-end:0 }
.claim-row .row-reason[open] { grid-column:1/-1; padding-inline:5px }
.claim-row .row-reason textarea { display:block; width:100%; min-width:0 }
.schedule-actions {
    position:sticky; bottom:10px; z-index:6; display:flex; flex-wrap:wrap; align-items:center;
    justify-content:flex-end; gap:8px; padding:10px; margin-top:12px;
    border:1px solid var(--border); border-radius:12px; background:var(--surface); box-shadow:0 3px 18px #161c2d20;
}
.schedule-actions form { margin:0 }
.schedule-actions :is(button,.button) { min-height:40px }
body:has(.schedule-actions) .content { padding-bottom:110px }
#claim-draft-form .save-bar button { display:none }
@media(max-width:760px) {
    .schedule-actions { bottom:4px; justify-content:start }
    .schedule-actions :is(button,.button) { min-height:44px }
}
@media print { .schedule-actions { display:none } }

.head-editor { --head-columns:minmax(155px,1.8fr) repeat(2,minmax(85px,1fr)) minmax(70px,.7fr) minmax(90px,1fr) 96px }
@media(min-width:1001px) { .head-row,.head-grid-head { min-width:620px } }

.register-scroll th.register-money { text-align:right; font-variant-numeric:tabular-nums }
.register-preferences { margin-block:8px }
.register-scroll tr > :first-child { position:sticky; inset-inline-start:0; z-index:1; background:var(--surface) }
.register-scroll thead tr > :first-child { z-index:3; background:var(--surface-muted) }
.register-scroll tfoot tr > :first-child { background:var(--surface-muted) }

.table-tools { gap:.65rem; align-items:end; margin:.55rem 0; }
nav[aria-label="Register scope"] { display:flex; flex-wrap:wrap; }

.column-filter-trigger { margin-inline-start:.3rem; vertical-align:middle; min-width:1.35rem; }
.column-filter-active { color:var(--primary); outline:1px solid currentColor; }
.column-filter-panel { position:fixed; inset:auto; margin:0; box-sizing:border-box; width:240px; padding:.75rem; border:1px solid var(--border); background:#fff; color:#172033; overflow:auto; }
.column-filter-panel:not(:popover-open) { display:none; }
.column-filter-panel:popover-open { display:grid; gap:.25rem; }
.column-filter-panel > button { justify-self:end; }
.column-filter-panel label { min-width:0; }
.column-filter-panel input { width:100%; margin-top:.3rem; }
@media (max-width:760px) {
  .column-filter-trigger { min-width:2rem; min-height:2rem; }
  .column-filter-panel > button { min-height:2.75rem; }
  .column-filter-panel input { min-height:2.75rem; font-size:16px; }
}
/* Blueprint v39: one shared FlyonUI/Tabulator register pattern. */
.register-toolbar,.register-left,.register-right{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.register-toolbar{justify-content:space-between;margin:12px 0}.register-left,.register-right{align-items:end;min-width:0}.register-right{margin-inline-start:auto}
.register-toolbar label{display:grid;gap:3px;font-size:12px}.register-toolbar :is(input,select,button){min-height:34px;height:34px;margin:0}.register-toolbar input[type=search]{width:210px;max-width:100%}
.register-toolbar [data-register-message]{font-size:12px}
.register:has(.alpha-multiselect),.tabulator-panel{overflow:visible}.alpha-multiselect{position:relative;min-width:110px}.alpha-select-toggle{width:100%;max-width:210px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.alpha-select-options{position:absolute;z-index:100;background:var(--surface);border:1px solid var(--border);border-radius:9px;box-shadow:var(--shadow);padding:8px;min-width:240px;max-width:calc(100vw - 24px);max-height:300px;overflow:auto;right:0}.alpha-select-options.hidden{display:none}.alpha-select-option{cursor:pointer;padding:7px}.alpha-select-option:hover,.alpha-select-option:focus{background:var(--primary-soft)}.alpha-select-option-row{display:flex;gap:10px;justify-content:space-between}.alpha-selected-check{visibility:hidden}.selected .alpha-selected-check{visibility:visible}.alpha-select-option.disabled{opacity:.6;pointer-events:none}
.alpha-columns .alpha-select-toggle{font-size:0}.alpha-columns .alpha-select-toggle>*{display:none}.alpha-columns .alpha-select-toggle::after{content:'Columns';font-size:12px}
.app-footer{padding:16px 24px;color:var(--muted);font-size:12px;border-top:1px solid var(--border)}
[popover]:not(:popover-open){display:none!important}
@media(max-width:760px){.register-left,.register-right{width:100%}.register-right{justify-content:flex-end;margin-inline-start:0}.register-toolbar :is(input,select,button){min-height:44px;height:44px}.register-scroll{max-width:100%}.alpha-select-options{min-width:220px}.app-footer{padding:16px 12px}}
.alpha-status .alpha-select-toggle{font-size:0}.alpha-status .alpha-select-toggle>*{display:none}.alpha-status .alpha-select-toggle::after{content:attr(data-caption);font-size:12px}

/* v39 library component layout adapters, independent from financial calculations. */
.metrics.stats{display:grid;grid-auto-flow:row;background:transparent;box-shadow:none;overflow:visible}.metrics .stat{min-width:0;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:15px;box-shadow:var(--shadow)}.metrics .stat-value{font-size:22px}.metrics .stat-title{white-space:normal}
.notice.alert{display:flex;flex-wrap:wrap;gap:6px;min-height:0;margin:0 0 11px;padding:10px 12px}.claim-tabs.tabs{flex-wrap:wrap;margin-bottom:16px}.claim-tabs .tab.active{color:var(--primary);border-bottom:2px solid currentColor}
.column-filter-panel{position:absolute;inset:auto;top:anchor(bottom);left:anchor(left);position-try-fallbacks:flip-block,flip-inline;max-width:calc(100vw - 16px);max-height:calc(100vh - 16px);overflow:auto}.sidebar .menu{display:block;width:100%;padding:0}.sidebar .menu.hidden{display:none}
@media(min-width:761px){#workspace-nav{height:auto!important;display:block!important;overflow:visible!important}}
@media(max-width:760px){.column-filter-panel{position:fixed;left:50%;top:50%;transform:translate(-50%,-50%)}.sidebar .menu.hidden{display:none!important}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition-duration:0s!important;animation-duration:0s!important}}
/* v39 Tabulator uses the shared theme while owning rows, headers and paging. */
.alpha-tabulator.tabulator{max-width:100%;border:1px solid var(--border);border-radius:8px;background:var(--surface);font:inherit;font-size:12px}
.alpha-tabulator .tabulator-header,.alpha-tabulator .tabulator-header .tabulator-col{background:var(--surface-muted);color:var(--ink-soft);border-color:var(--border)}
.alpha-tabulator .tabulator-row{background:var(--surface);border-bottom:1px solid var(--border)}.alpha-tabulator .tabulator-row:hover{background:var(--primary-soft)}
.alpha-tabulator .tabulator-cell{border-color:var(--border);white-space:normal}.alpha-tabulator .tabulator-cell small{display:block}.alpha-tabulator .tabulator-header-filter input{width:100%;min-height:30px;font:inherit}
.alpha-tabulator .tabulator-footer{background:var(--surface-muted);border-color:var(--border);color:var(--ink-soft)}.alpha-tabulator .tabulator-footer .tabulator-page{color:var(--primary-dark);background:var(--surface);min-height:32px}.alpha-tabulator .tabulator-page.active{background:var(--primary);color:white}
.alpha-tabulator .tabulator-calcs{background:var(--surface-muted);font-weight:650}.alpha-tabulator .tabulator-cell:focus-visible{outline:2px solid var(--primary);outline-offset:-2px}
@media(max-width:760px){.alpha-tabulator .tabulator-footer .tabulator-footer-contents{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end}.alpha-tabulator .tabulator-page{min-height:44px}}
.register-scroll:has(.alpha-tabulator){overflow:visible;max-height:none}.alpha-tabulator .tabulator-frozen{background:var(--surface)}

/* V39 visual system: blue navigation, consistent actions and shared table borders. */
:root,[data-theme="light"] {
    --color-primary:#2463d3; --color-primary-content:#fff;
    --color-secondary:#64748b; --color-secondary-content:#fff;
    --color-accent:#2463d3; --color-accent-content:#fff;
}
.btn,.button { min-height:34px; border-radius:7px; font-weight:650; box-shadow:none; text-transform:none }
.btn:not(.btn-primary):not(.btn-error):not(.btn-success):not(.btn-warning):not(.btn-info):not(.btn-ghost),
button:not(.btn) { border:1px solid #cbd5e1; background:#fff; color:#475569 }
.btn:not(.btn-primary):not(.btn-error):not(.btn-success):not(.btn-warning):not(.btn-info):not(.btn-ghost):hover,
button:not(.btn):hover { border-color:#aebccc; background:#f8fafc; color:#1e293b }
.btn.btn-primary { border-color:var(--primary); background:var(--primary); color:#fff }
.btn.btn-primary:hover { border-color:var(--primary-dark); background:var(--primary-dark) }
.btn.btn-secondary.btn-soft { border-color:#dce3eb; background:#f1f5f9; color:#334155 }
.btn.btn-secondary.btn-soft:hover { border-color:#cbd5e1; background:#e8eef5; color:#1e293b }
.btn.btn-ghost { border-color:transparent; background:transparent; color:var(--ink-soft) }
.metrics { grid-template-columns:repeat(auto-fit,minmax(min(100%,155px),1fr)); gap:9px }
.metrics strong { font-size:clamp(17px,1.65vw,22px); overflow-wrap:anywhere }
.table-wrap :is(th,td) { border-color:var(--border) }
.register-toolbar { gap:8px; padding:10px; border:1px solid var(--border); border-radius:9px; background:#f8fafc }
.register-left,.register-right { gap:7px }
.register-right { justify-content:flex-end }
.register-toolbar label { color:#536076; font-weight:650 }
.register-toolbar input[type="search"] { width:210px }
.register-toolbar select { border-color:#cbd5e1; border-radius:7px }
.alpha-tabulator.tabulator { border-color:var(--border); border-radius:9px }
.alpha-tabulator .tabulator-header,.alpha-tabulator .tabulator-header .tabulator-col,
.alpha-tabulator .tabulator-cell,.alpha-tabulator .tabulator-row { border-color:var(--border) }
@media(max-width:760px) {
    .register-toolbar { padding:9px; background:#fff }
    .register-left,.register-right { justify-content:stretch }
    .register-toolbar label { flex:1; min-width:0 }
    .register-toolbar input[type="search"] { width:100% }
}

/* Keep server-rendered controls and Tabulator controls visually identical. */
.register-toolbar { align-items:end; gap:8px; }
.register-toolbar .register-left,.register-toolbar .register-right { align-items:end; gap:7px; }
.register-toolbar [data-register-sort] { width:145px; min-width:145px; }
.register-toolbar [data-period] { width:126px; }
.register-toolbar .alpha-status,.register-toolbar .alpha-columns { position:relative; width:132px; min-width:132px; }
.register-toolbar .alpha-columns { width:128px; min-width:128px; }
.register-toolbar .alpha-status select[data-filter],
.register-toolbar .alpha-columns select[data-register-columns] {
    width:100%; min-width:0; padding-right:30px; border:1px solid #cbd5e1; border-radius:7px;
    background:#fff; color:var(--ink); appearance:none;
}
.register-toolbar .alpha-status:not(:has(.alpha-select-toggle))::after,
.register-toolbar .alpha-columns:not(:has(.alpha-select-toggle))::after {
    content:""; position:absolute; right:12px; bottom:13px; width:7px; height:7px;
    border-right:1.5px solid #64748b; border-bottom:1.5px solid #64748b;
    transform:rotate(45deg); pointer-events:none;
}
.register-toolbar .alpha-columns:not(:has(.alpha-select-toggle))::before {
    content:attr(data-caption); position:absolute; left:10px; right:30px; bottom:9px;
    overflow:hidden; color:var(--ink); font-size:13px; line-height:16px; white-space:nowrap;
    text-overflow:ellipsis; pointer-events:none;
}
.register-toolbar .alpha-columns:not(:has(.alpha-select-toggle)) select[data-register-columns] { color:transparent; }
.register-toolbar .alpha-columns:not(:has(.alpha-select-toggle)) select[data-register-columns] option { color:var(--ink); }
.register-toolbar .alpha-multiselect { position:relative; display:block; width:100%; min-width:0; }
.register-toolbar .alpha-select-toggle {
    position:relative; display:flex; align-items:center; justify-content:space-between; width:100%; max-width:none;
    min-height:34px; height:34px; padding:6px 29px 6px 9px; overflow:hidden;
    border:1px solid #cbd5e1; border-radius:7px; background:#fff; color:var(--ink); box-shadow:none;
    font:inherit; font-size:13px; text-align:left; text-transform:none; white-space:nowrap;
}
.register-toolbar .alpha-select-toggle>* { display:none; }
.register-toolbar .alpha-select-toggle::before { content:attr(data-caption); overflow:hidden; text-overflow:ellipsis; }
.register-toolbar .alpha-select-toggle::after {
    content:""; position:absolute; right:11px; top:12px; width:7px; height:7px;
    border-right:1.5px solid #64748b; border-bottom:1.5px solid #64748b; transform:rotate(45deg);
}
.register-toolbar .alpha-status:has(.alpha-select-toggle)::after,
.register-toolbar .alpha-columns:has(.alpha-select-toggle)::after { display:none; }
.register-toolbar .alpha-select-options { z-index:30; border-color:var(--border); background:var(--surface); color:var(--ink); }

/* Tabulator adopts the same widths, density, casing, borders and subtotal surface as the HTML fallback. */
.alpha-tabulator.tabulator {
    width:100%; max-width:100%; border:1px solid var(--border); border-radius:9px; overflow:hidden;
    background:var(--surface); color:var(--ink-soft); font-family:inherit; font-size:13px; line-height:1.45;
}
.alpha-tabulator .tabulator-header {
    border-bottom:1px solid var(--border); background:#fafbfd; color:#536076;
    font-size:11px; font-weight:750; letter-spacing:.035em; text-transform:uppercase;
}
.alpha-tabulator .tabulator-header .tabulator-col { border-right:1px solid var(--border); background:transparent; }
.alpha-tabulator .tabulator-header .tabulator-col:last-child { border-right:0; }
.alpha-tabulator .tabulator-header .tabulator-col .tabulator-col-content { padding:6px 5px; }
.alpha-tabulator .tabulator-header .tabulator-col .tabulator-col-title { white-space:nowrap; }
.alpha-tabulator .tabulator-tableholder,.alpha-tabulator .tabulator-table { white-space:normal; background:var(--surface); }
.alpha-tabulator .tabulator-row { min-height:35px; border-bottom:1px solid var(--border); background:var(--surface); }
.alpha-tabulator .tabulator-row:nth-child(even) { background:var(--surface); }
.alpha-tabulator .tabulator-row .tabulator-cell {
    display:inline-flex; align-items:center; min-height:35px; padding:6px 5px; border-right:1px solid var(--border); vertical-align:middle;
    color:var(--ink-soft); line-height:1.45; white-space:normal; overflow-wrap:anywhere;
}
.alpha-tabulator .tabulator-cell small { display:block; margin-top:3px; font-size:80%; }
.alpha-tabulator .tabulator-row .tabulator-cell:last-child { border-right:0; }
.alpha-tabulator .tabulator-row:hover,.alpha-tabulator .tabulator-row.tabulator-selected { background:var(--surface); }
.alpha-tabulator .tabulator-header .tabulator-frozen-left { border-right:1px solid var(--border); }
.alpha-tabulator .tabulator-frozen { background:var(--surface); }
.alpha-tabulator .tabulator-row.tabulator-calcs,.alpha-tabulator .tabulator-row.tabulator-calcs .tabulator-cell {
    border-color:#c3d7d9; border-top:2px solid #c3d7d9; background:#eef5f5!important; color:var(--ink-soft); font-weight:600;
}
.alpha-tabulator .tabulator-footer { border-top:1px solid var(--border); background:var(--surface-muted); color:var(--muted); }
.alpha-tabulator .tabulator-footer .tabulator-page { min-width:28px; min-height:32px; border:1px solid var(--border); border-radius:6px; background:var(--surface); color:var(--primary-dark); }
.alpha-tabulator .tabulator-footer .tabulator-page.active { border-color:#b9cef1; background:var(--primary); color:#fff; }
.alpha-tabulator .tabulator-footer .tabulator-page-size { min-height:32px; border:1px solid var(--border); border-radius:6px; background:var(--surface); color:var(--ink); }
.alpha-tabulator .tabulator-placeholder .tabulator-placeholder-contents { color:var(--muted); font-size:13px; font-weight:500; }
.register-scroll:has(.alpha-tabulator) { overflow:auto; max-height:61vh; }
.register-scroll:has(.alpha-tabulator) .alpha-tabulator .tabulator-tableholder { overflow:visible; }
.register-scroll:has(.alpha-tabulator) .alpha-tabulator .tabulator-header { position:sticky; top:0; z-index:4; }
@media(max-width:760px) {
    .register-toolbar { display:grid; grid-template-columns:minmax(0,1fr); align-items:stretch; }
    .register-toolbar .register-left,.register-toolbar .register-right {
        display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); align-items:end; width:100%; min-width:0;
    }
    .register-toolbar .register-left > label:first-child { grid-column:1/-1; }
    .register-toolbar .register-left > label,
    .register-toolbar .register-right > label { width:100%; min-width:0; }
    .register-toolbar .register-left > label select,
    .register-toolbar .register-right > label select { width:100%; min-width:0; }
    .register-toolbar .register-left > label input[type="search"] { width:100%; }
    .register-toolbar .register-left > [data-clear] { grid-column:1/-1; justify-self:end; }
    .register-toolbar .register-right > [data-register-save],
    .register-toolbar .register-right > [data-register-reset] { width:100%; }
    .register-toolbar .register-right > [data-register-message] { grid-column:1/-1; }
    .register-toolbar [data-register-sort] { width:100%; min-width:0; }
    .register-toolbar .alpha-status,.register-toolbar .alpha-columns { width:100%; min-width:0; }
    .register-toolbar .alpha-select-toggle { min-height:44px; height:44px; }
    .register-toolbar .alpha-select-toggle::after { top:17px; }
    .register-toolbar .alpha-status:not(:has(.alpha-select-toggle))::after,
    .register-toolbar .alpha-columns:not(:has(.alpha-select-toggle))::after { bottom:17px; }
    .register-toolbar .alpha-columns:not(:has(.alpha-select-toggle))::before { bottom:13px; }
    .alpha-tabulator .tabulator-footer .tabulator-footer-contents { display:flex; flex-wrap:wrap; gap:8px; justify-content:flex-end; }
    .alpha-tabulator .tabulator-footer .tabulator-page { min-height:44px; }
}
