/* LIGHT: warm paper, not a pure-white canvas. */
:root{color-scheme:light}
:root[data-theme="light"]{--muted:#687461}
[data-theme="light"] .panel,[data-theme="light"] .stat,[data-theme="light"] .photo,[data-theme="light"] .login{background:#fafbf7}
.theme-picker{display:flex;align-items:center;gap:8px;white-space:nowrap}
.theme-picker select{width:auto;min-height:34px;padding:6px 28px 6px 10px;font-size:12px;border-radius:7px;background:transparent}
.theme-picker .theme-label{font-size:11px;color:var(--muted)}
.login>.theme-picker{justify-content:flex-end;margin-bottom:20px}
/* DARK: neutral black/charcoal surfaces; readable muted text, no white panels. */
:root[data-theme="dark"]{color-scheme:dark;background:#090909;color:#ededed;--green:#d8d8d8;--muted:#b8b8b8;--line:#363636;--cream:#090909;--gold:#d1ad77}
[data-theme="dark"] body{background:#090909;color:#ededed}
[data-theme="dark"] button{background:#252525;color:#ededed;border-color:#505050}
[data-theme="dark"] button:hover{background:#333333;border-color:#777777}
[data-theme="dark"] button.primary{background:#d6d6d6;border-color:#d6d6d6;color:#111111}
[data-theme="dark"] button.primary:hover{background:#eeeeee}
[data-theme="dark"] button.ghost{background:transparent;border-color:transparent;color:#d0d0d0}
[data-theme="dark"] button.ghost:hover{background:#292929}
[data-theme="dark"] button.danger,[data-theme="dark"] .dangertext{color:#edb09b}
[data-theme="dark"] a{color:#d0d0d0}
[data-theme="dark"] .sidebar{background:#101010}
[data-theme="dark"] .navlabel,[data-theme="dark"] .eyebrow{color:#aaaaaa}
[data-theme="dark"] .nav button{background:transparent;color:#cccccc;border:0}
[data-theme="dark"] .nav button:hover{background:#252525}
[data-theme="dark"] .nav button.active{background:#d6d6d6;color:#111111}
[data-theme="dark"] .nav .count{background:#11111124;color:inherit}
[data-theme="dark"] .sidefoot{border-color:#363636;color:#aaaaaa}
[data-theme="dark"] .topbar,[data-theme="dark"] .dialogfoot{background:#141414;color:#bdbdbd}
[data-theme="dark"] .topbar strong{color:#eeeeee}
[data-theme="dark"] .avatar{background:#303030;color:#e0e0e0}
[data-theme="dark"] .stat,[data-theme="dark"] .panel,[data-theme="dark"] .photo,[data-theme="dark"] .login{background:#181818}
[data-theme="dark"] .stat .label{color:#cccccc}
[data-theme="dark"] .panelhead,[data-theme="dark"] .flow,[data-theme="dark"] td,[data-theme="dark"] .issue{border-bottom-color:#363636}
[data-theme="dark"] .hero{background:#202020;color:#eeeeee;border:1px solid #404040}
[data-theme="dark"] .hero .eyebrow,[data-theme="dark"] .hero .sub{color:#c4c4c4}
[data-theme="dark"] .hero button{background:#dddddd;color:#111111}
[data-theme="dark"] .hero button:hover{background:#eeeeee}
[data-theme="dark"] .hero button.ghost{background:#ffffff09;color:#dddddd}
[data-theme="dark"] .pill{background:#303030;color:#dddddd}
[data-theme="dark"] .pill.warn{background:#453b27;color:#e8ca90}
[data-theme="dark"] .pill.gray{background:#303030;color:#cccccc}
[data-theme="dark"] .pill.blue{background:#293d45;color:#b0d6e6}
[data-theme="dark"] .notice{background:#332f23;border-color:#63543b;color:#e4c99b}
[data-theme="dark"] .notice.neutral{background:#222222;border-color:#444444;color:#dddddd}
[data-theme="dark"] .notice.error,[data-theme="dark"] .formerror{background:#402d26;border-color:#6e473a;color:#f0bcaa}
[data-theme="dark"] .flow .num{background:#292929;border-color:#444444;color:#cccccc}
[data-theme="dark"] .flow p,[data-theme="dark"] .issue p,[data-theme="dark"] .timeline p,[data-theme="dark"] .footnote{color:#b8b8b8}
[data-theme="dark"] .empty{color:#b8b8b8}
[data-theme="dark"] .empty strong{color:#dddddd}
[data-theme="dark"] .empty .icon{color:#bbbbbb}
[data-theme="dark"] th{background:#222222;color:#d0d0d0}
[data-theme="dark"] td{color:#e0e0e0}
[data-theme="dark"] td strong{color:#f1f1f1}
[data-theme="dark"] td small{color:#bdbdbd}
[data-theme="dark"] tr:hover td{background:#242424}
[data-theme="dark"] .tabs button{background:transparent;color:#bdbdbd}
[data-theme="dark"] .tabs button.active{background:#353535;color:#eeeeee}
[data-theme="dark"] label.field{color:#cccccc}
[data-theme="dark"] input,[data-theme="dark"] select,[data-theme="dark"] textarea{background:#101010;border-color:#505050;color:#eeeeee}
[data-theme="dark"] input::placeholder,[data-theme="dark"] textarea::placeholder{color:#999999}
[data-theme="dark"] input:focus,[data-theme="dark"] select:focus,[data-theme="dark"] textarea:focus{outline-color:#cccccc;border-color:#cccccc}
[data-theme="dark"] input[readonly]{background:#252525;color:#d0d0d0}
[data-theme="dark"] input[type="checkbox"]{accent-color:#d6d6d6}
[data-theme="dark"] dialog,[data-theme="dark"] .dialoghead{background:#181818;color:#ededed}
[data-theme="dark"] dialog{box-shadow:0 24px 100px #0008}
[data-theme="dark"] dialog::backdrop{background:#000000b3}
[data-theme="dark"] .photo img{background:#181818}
[data-theme="dark"] .reviewimage{background:#101010}
[data-theme="dark"] .shiftrow{background:#202020;border-color:#444444}
[data-theme="dark"] .tipcalc{background:#292929;color:#dddddd;border:1px solid #505050}
[data-theme="dark"] .linkbutton{background:transparent;border:0;color:#dddddd}
[data-theme="dark"] .timeline{border-color:#444444}
[data-theme="dark"] .statement{background:#181818;border-color:#444444}
[data-theme="dark"] .statement .line{border-color:#3c3c3c}
[data-theme="dark"] .statement .total{background:#303030;color:#eeeeee}
[data-theme="dark"] #toast{background:#dddddd;color:#111111;box-shadow:0 8px 30px #0005}
[data-theme="dark"] .loading{color:#cccccc}
[data-theme="dark"] .theme-picker select{background:#222222}
[data-theme="dark"] :focus-visible{outline-color:#dddddd}
[data-theme="dark"] ::selection{background:#555555;color:#fff}
[data-theme="dark"]{scrollbar-color:#666666 #101010}
/* Keep documents legible on paper. PNG export uses its own light canvas. */
@media print{html[data-theme],html[data-theme] body{background:#fff;color:#25372d}html[data-theme] .statement{background:#fffef9;border-color:#cdd5c2}html[data-theme] .statement *{color:#25372d!important}html[data-theme] .statement .total{background:#eaf0df}.theme-picker{display:none}}
@media(max-width:760px){.topright{gap:8px}.theme-picker .theme-label{display:none}.theme-picker select{max-width:130px;min-height:32px;font-size:11px}.topbar{min-height:51px;height:auto;gap:10px;padding-top:7px;padding-bottom:7px}.topright .avatar{display:none}}

/* Readability: no browser zoom needed; dense financial tables remain scrollable. */
:root{font-size:16px}.content{max-width:1920px}.nav button{font-size:16px}.sub,.notice,label.field,.footnote,.stat .label,.stat .sub{font-size:14px}h2{font-size:20px}h3{font-size:16px}table{font-size:16px}th{font-size:14px;font-weight:600}td small{font-size:14px;line-height:1.6}button.small,.pill,.tabs button,.linkbutton{font-size:14px}.theme-picker select{font-size:14px}.theme-picker .theme-label{font-size:13px}.payroll-page table{font-size:18px;min-width:1420px}.payroll-page th{font-size:15px}.payroll-page td{padding:20px 18px}.payroll-page td small{font-size:14px}.payroll-page button.small{font-size:15px;min-height:38px}.payroll-page input[type=checkbox]{width:20px;height:20px}.remit-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}.remit-field{padding:18px;border:1px solid var(--line);border-radius:9px}.remit-field>strong{display:block;font-size:29px;margin:13px 0;font-variant-numeric:tabular-nums}.remit-field p{margin:0}.tablewrap{scrollbar-width:auto}
@media(max-width:760px){.nav button{font-size:14px}.remit-grid{grid-template-columns:1fr}.theme-picker select{font-size:13px}.payroll-page td{padding:16px}.topbar{flex-wrap:wrap}.topright{margin-left:auto}}

/* Clipboard/drop uploads: quiet, readable in either theme. */
.photo-dropzone{display:flex;align-items:center;gap:22px;padding:26px 28px;border:1px dashed #a9b6a0;background:#edf1e8;border-radius:12px;margin-bottom:12px;transition:background .15s,border-color .15s}
.photo-dropzone h2{font-size:20px;margin:0 0 10px}.photo-dropzone p{font-size:16px;line-height:1.8;margin:0 0 6px}.photo-upload-icon{display:grid;place-items:center;width:62px;height:62px;flex-shrink:0;background:#dce6d5;border-radius:14px;color:#304d3c}.photo-upload-icon .icon{width:29px;height:29px}
.photo-dropzone kbd{font:600 14px "Segoe UI",sans-serif;padding:3px 7px;border:1px solid #bac6b2;border-bottom-width:3px;border-radius:5px;background:#fafbf7;color:#304d3c}.photo-dropzone.dragover{background:#dce8d4;border:2px solid #526f43;padding:25px 27px}
.photo-upload-status{font-size:14px;line-height:1.8;margin:0 0 20px;color:var(--muted);overflow-wrap:anywhere}.photo-upload-status:empty{display:none}
[data-theme="dark"] .photo-dropzone{background:#151515;border-color:#555}[data-theme="dark"] .photo-upload-icon{background:#292929;color:#ddd}[data-theme="dark"] .photo-dropzone kbd{background:#272727;color:#eee;border-color:#606060}[data-theme="dark"] .photo-dropzone.dragover{background:#292929;border-color:#ccc}
@media(max-width:760px){.photo-dropzone{padding:18px;gap:12px;align-items:flex-start}.photo-upload-icon{width:40px;height:40px;border-radius:9px}.photo-upload-icon .icon{width:23px;height:23px}.photo-dropzone h2{font-size:18px}.photo-dropzone p{font-size:14px}.photo-dropzone.dragover{padding:17px}}

/* Saved payment composition above the prominent final amount. */
.payroll-page .amount-due{min-width:205px;max-width:300px;font-variant-numeric:tabular-nums}
.payroll-page .amount-due .amount-breakdown{display:block;font-size:14px;font-weight:400;line-height:1.5;white-space:normal;margin:0 0 6px;color:var(--muted)}
[data-theme="dark"] .payroll-page .amount-due .amount-breakdown{color:#bdbdbd}
.payroll-page .amount-due>strong{display:block;white-space:nowrap}
