/* Display preferences only: no ledger, authentication or export changes. */
:root{--surface:#fff;--sidebar:#fafbfe;--hover:#edf2f8;--featured:#eaf0f8;--header:#f8fafe;--warning-bg:#fcf5e8;--error-bg:#fff1ef;--primary:#203b60;--primary-hover:#142944}
:root[data-effective-theme=dark]{--ink:#e6edf7;--muted:#a9b8cd;--accent:#aac6ed;--accent-soft:#233b5b;--paper:#0b1524;--line:#34445b;--white:#152337;--surface:#152337;--sidebar:#101d30;--hover:#22344c;--featured:#1b304a;--header:#1b2b41;--amber:#efd097;--danger:#f29b92;--warning-bg:#332b1c;--error-bg:#382325;--primary:#3b6495;--primary-hover:#4a78ad}
@media(prefers-color-scheme:dark){:root:not([data-effective-theme]){--ink:#e6edf7;--muted:#a9b8cd;--accent:#aac6ed;--accent-soft:#233b5b;--paper:#0b1524;--line:#34445b;--white:#152337;--surface:#152337;--sidebar:#101d30;--hover:#22344c;--featured:#1b304a;--header:#1b2b41;--amber:#efd097;--danger:#f29b92;--warning-bg:#332b1c;--error-bg:#382325;--primary:#3b6495;--primary-hover:#4a78ad;color-scheme:dark}}
body{background:var(--paper);color:var(--ink)}
.sidebar{background:var(--sidebar)}.topbar,.kpi,.panel,dialog,.login-card{background:var(--surface);border-color:var(--line)}
.demo-strip{background:var(--accent-soft);color:var(--ink)}nav a{color:var(--muted)}nav a:hover,.button:hover{background:var(--hover)}
.kpi.featured{background:var(--featured);border-color:var(--line)}th{background:var(--header)}td{border-color:var(--line)}
.button,.search,.year-control select,.field input,.field select,.field textarea,.list-tools select,.list-tools input[type=date],.theme-control select{background:var(--surface);border-color:var(--line);color:var(--ink)}
.button.primary{background:var(--primary);color:#fff;border-color:var(--primary)}.button.primary:hover{background:var(--primary-hover)}
.badge{background:var(--accent-soft);color:var(--accent)}.badge.archived{background:var(--header);color:var(--muted)}.badge.amber,.notice.warning{background:var(--warning-bg);color:var(--amber);border-color:var(--line)}
.notice{background:var(--featured)}.notice.error,.form-error{background:var(--error-bg);color:var(--danger)}
.display-tools{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.theme-control{display:flex;align-items:center;gap:6px;font-size:11px;color:var(--muted)}.theme-control select{padding:6px 8px;border:1px solid var(--line);border-radius:6px;max-width:155px;font-size:11px;min-height:32px}
.privacy-eye svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.7}.privacy-eye[aria-pressed=true]{background:var(--accent-soft)}.dialog-display-actions{display:flex;align-items:center;gap:12px}
.login-card>.display-tools{justify-content:flex-end;margin-bottom:20px}.topbar{height:auto;min-height:70px;gap:16px;padding-block:12px}.account-tools{flex-wrap:wrap;justify-content:flex-end}.account-tools .display-tools span{max-width:none}
:root[data-amounts=hidden] .chart svg{visibility:hidden}.chart-privacy{display:grid;place-items:center;height:250px;color:var(--muted);font-size:13px}
:root[data-amounts=hidden] #field-import_text,:root[data-amounts=hidden] #field-document_text{-webkit-text-security:disc}
@media(max-width:1100px){.topbar{align-items:flex-start}.account-tools{gap:8px}.display-tools{gap:6px}}
@media(max-width:780px){.topbar{flex-wrap:wrap;min-height:60px}.account-tools{width:100%;justify-content:flex-start}.breadcrumb{padding-top:3px}.display-tools{gap:8px}.privacy-eye{min-height:34px}.dialog-display-actions{flex-wrap:wrap;justify-content:flex-end}.theme-control select{max-width:145px}}
@media print{:root{--ink:#17273d;--muted:#536275;--accent:#203b60;--accent-soft:#e8eef7;--paper:#fff;--line:#cdd5df;--surface:#fff;--featured:#eaf0f8;--header:#f8fafe;--warning-bg:#fcf5e8;--amber:#7a5412}.display-tools{display:none!important}}

/* Keyboard-accessible column sorting, inherited light/dark palette. */
.table-sort {font:inherit;letter-spacing:inherit;text-transform:inherit;color:inherit;background:none;border:0;padding:0;cursor:pointer;display:inline-flex;align-items:center;gap:.3rem;text-align:inherit;}
th.numeric .table-sort {justify-content:flex-end;}
.table-sort:hover {text-decoration:underline;}
.table-sort:focus-visible {outline:2px solid currentColor;outline-offset:5px;border-radius:2px;}
.sort-direction {opacity:.6;white-space:nowrap;}
th[aria-sort=ascending] .sort-direction,th[aria-sort=descending] .sort-direction {opacity:1;}
@media print {.sort-direction {display:none;}}
