
:root{font-family:Inter,Arial,sans-serif;color:#17263a;background:#f4f7fb;font-size:15px}*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button{cursor:pointer}button:disabled{cursor:wait;opacity:.55}a{color:inherit}header{background:#fff;border-bottom:1px solid #dbe4ee;padding:16px 24px;display:flex;gap:12px;align-items:center;justify-content:space-between}.brand{display:flex;align-items:center;gap:12px}.stamp{background:#173654;color:white;width:44px;height:44px;border-radius:12px;display:grid;place-items:center;font-weight:800}.brand h1{font-size:18px;margin:0}.muted{color:#61758d;font-size:13px}.layout{display:grid;grid-template-columns:214px 1fr;min-height:calc(100vh - 77px)}nav{background:#142941;color:#c0cfdd;padding:22px 12px;display:flex;flex-direction:column;gap:8px}nav button{border:0;background:transparent;color:inherit;text-align:left;padding:12px;border-radius:8px;font-weight:600}nav button.active{background:#2c4c6d;color:#fff}main{min-width:0;padding:24px;max-width:1600px}h2{font-size:27px;margin:0 0 6px}h3{margin:0 0 10px;font-size:17px}.heading{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:20px}.btn{background:#147b67;color:white;border:0;border-radius:8px;padding:11px 16px;font-weight:700;white-space:nowrap}.secondary{background:#e8eef6;color:#203954;border:1px solid #d2ddeb}.danger{color:#a32e37;border:1px solid #eeb9be;background:#fff2f3}.notice{background:#eef6fd;border:1px solid #c5def1;color:#25456a;padding:12px 15px;border-radius:9px;margin-bottom:14px}.error{background:#fff1f1;color:#a41b2b;border-color:#eac1c4}.cards{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin:16px 0}.card,.panel{border:1px solid #dde6ef;background:#fff;border-radius:14px;padding:18px;box-shadow:0 3px 12px #17314f08}.card .number{font-size:24px;font-weight:750;margin:8px 0}.filter{display:flex;gap:12px;align-items:end;flex-wrap:wrap;margin-bottom:15px}.filter label{font-weight:600;font-size:13px;color:#50627a;display:grid;gap:7px;min-width:145px;flex:1}.filter input,.filter select{width:100%;padding:10px;background:white;border:1px solid #cbd7e5;border-radius:8px;color:#21334a}.panel{margin-bottom:18px;min-width:0}.scroll{overflow:auto;max-height:55vh}.scroll table{border-collapse:collapse;min-width:100%;font-size:13px}th,td{white-space:nowrap;text-align:left;padding:12px 11px;border-bottom:1px solid #e3e9f1}th{position:sticky;top:0;background:#edf3f8;z-index:1;color:#37516c;font-size:12px}tbody tr:hover{background:#f7fafc}.num{text-align:right;font-variant-numeric:tabular-nums}.pill{display:inline-block;font-size:12px;font-weight:700;border-radius:20px;padding:5px 9px;background:#edf2f8;color:#47627b}.green{background:#e3f5ec;color:#176840}.amber{background:#fff1dc;color:#9b6117}.barline{display:grid;grid-template-columns:120px 1fr 100px;gap:10px;align-items:center;margin:10px 0}.track{background:#edf2f7;border-radius:6px;overflow:hidden;height:17px}.bar{height:100%;background:#3b82b6;border-radius:6px}.bar.mc{background:#8053ad}.actions{display:flex;gap:7px;flex-wrap:wrap}.hidden{display:none!important}.foot{padding:12px 0;color:#66788d;font-size:12px}.jobform input{margin:4px 0;padding:8px;border:1px solid #bdccd7;border-radius:6px}.jobform select{padding:8px;border:1px solid #bdccd7;border-radius:6px}.right{text-align:right}.zero{color:#8797aa}.loader{padding:30px;text-align:center;color:#50647d}@media(max-width:900px){.layout{grid-template-columns:1fr}nav{flex-direction:row;overflow-x:auto;padding:8px}nav button{white-space:nowrap}.cards{grid-template-columns:repeat(2,1fr)}main{padding:14px}.heading{align-items:flex-start}header{padding:12px}.brand h1{font-size:16px}}@media(max-width:480px){.cards{grid-template-columns:1fr 1fr}.card{padding:12px}.card .number{font-size:20px}.filter{display:grid;grid-template-columns:1fr 1fr}.heading{flex-direction:column}.hide-sm{display:none}.barline{grid-template-columns:90px 1fr 72px}}

.tracker-cell{border:0;background:none;color:inherit;font:inherit;font-weight:inherit;text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:3px;padding:0;cursor:pointer}.red{background:#fee2e2;color:#9f1239}.subtle{color:#67798b}.linkbtn{background:none;border:0;color:#155f87;font-weight:700;text-align:left;padding:3px 0;text-decoration:underline;text-underline-offset:3px}.stack{display:grid;gap:10px}.customer-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin:15px 0}.customer-grid label{display:grid;gap:6px;font-weight:600;color:#50627a;font-size:13px}.customer-grid input{width:100%;padding:11px;border:1px solid #cbd7e5;border-radius:7px}.docpaper{max-width:850px;margin:0 auto;background:#fff;border:1px solid #e2e6eb;padding:42px;box-shadow:0 3px 14px #27384f0b;color:#26313b}.invoice-head{display:flex;justify-content:space-between;gap:20px;align-items:start;margin-bottom:38px}.invoice-title{font-size:35px;letter-spacing:1.8px;font-weight:400;color:#172334}.invoice-meta{display:flex;justify-content:space-between;gap:20px;align-items:end;margin:24px 0}.invoice-table{border-collapse:collapse;width:100%;font-size:13px}.invoice-table th{position:static;background:#25384a;color:#fff}.invoice-table td{white-space:normal}.invoice-table td:first-child{width:30px}.invoice-totals{margin:22px 0 38px auto;max-width:370px}.invoice-totals div{display:flex;justify-content:space-between;padding:11px 13px}.invoice-balance{background:#eaf1f6;font-weight:800}.receipt{white-space:pre-wrap;line-height:1.7;margin:0;font:14px/1.7 Arial,sans-serif}.tracking-sheet{background:#fff;color:#243649;padding:18px;border:1px solid #d8e2ea;border-radius:10px}.tracking-sheet table{border-collapse:collapse;width:100%;font-size:12px}.tracking-sheet th,.tracking-sheet td{padding:9px 8px;white-space:nowrap}.tracking-sheet th{position:static;background:#eaf1f6}.tracking-sheet td.red{background:#ffd7dc;color:#9c1427;font-weight:800}.tracking-sheet td.green{background:#e1f4e9;color:#216543}.tracking-sheet td.amber{background:#fff0ce;color:#916218}.tracking-sheet td.zero{background:#f5f7fa}.tracking-sheet .scroll{max-height:none}.share-mode .layout{display:block;min-height:0}.share-mode header,.share-mode nav,.share-mode .no-share{display:none}.share-mode main{padding:12px;max-width:none}.share-mode .tracking-sheet{border:0;padding:8px}.legend{display:flex;gap:10px;flex-wrap:wrap;margin:12px 0}.legend span{font-size:12px;padding:5px 9px;border-radius:5px}.portalcards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:15px}.portalcard{border:1px solid #d9e4ed;padding:16px;border-radius:10px;background:#fff}.portalcard b{display:block;margin-bottom:6px}.receipt-controls{margin-bottom:16px}.docpaper h3{color:#172334}.note{font-size:12px;color:#52677e;line-height:1.5}.customer-summary{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.number{font-variant-numeric:tabular-nums}.compact-table td,.compact-table th{padding:8px 9px}.share-mode .share-exit{margin-bottom:12px}.caption-small{font-size:11px;color:#566e84}@media(max-width:700px){.portalcards,.customer-grid{grid-template-columns:1fr}.docpaper{padding:22px}.invoice-head,.invoice-meta{gap:10px;flex-wrap:wrap}.invoice-title{font-size:27px}.invoice-table th,.invoice-table td{padding:8px 5px;font-size:11px}.tracking-sheet{padding:8px}.tracking-sheet td,.tracking-sheet th{padding:6px 5px}}@media print{body{background:white!important}header,nav,.no-print,.heading,.filter,.notice,.share-exit,.receipt-controls{display:none!important}.layout{display:block}main{padding:0;max-width:none}.docpaper,.tracking-sheet{border:0;box-shadow:none;max-width:none;padding:18px}.scroll{overflow:visible!important;max-height:none!important}.tracking-sheet .heading{display:flex!important}.tracking-sheet table{font-size:10px}.tracking-sheet th,.tracking-sheet td{padding:5px}.red,.green,.amber,.invoice-table th,.invoice-balance{print-color-adjust:exact;-webkit-print-color-adjust:exact}tr{break-inside:avoid}}

.portal-tabs{display:flex;flex-wrap:wrap;gap:8px;margin:14px 0}.portal-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px;background:#f1f5f9;border-radius:10px;margin-bottom:12px;flex-wrap:wrap}.portal-link{text-decoration:none;display:inline-block}.provider-frame{width:100%;height:720px;border:1px solid #d4e0eb;border-radius:8px;background:#fff}.portal-placeholder{padding:55px 20px;text-align:center;color:#657a91;background:#f7f9fc;border:1px dashed #c8d6e5;border-radius:10px}.share-mode .tracking-sheet .scroll{overflow:auto}.share-mode .tracking-sheet table{min-width:100%}.caption-small{white-space:normal}.share-mode .tracking-sheet td{padding:8px 10px}.portal-panel .notice{font-size:13px}

.two-portals{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;max-width:640px}.two-portals .btn{padding:13px 24px;font-size:16px;text-align:center}.auto-explainer p{line-height:1.55;color:#50627a;margin:0}.auto-explainer .heading{margin-bottom:10px}.portal-bar .caption-small{overflow-wrap:anywhere}.portal-panel .notice strong{font-size:13px}
.source-sheet{border:1px solid #d7d4df;margin:16px 0 22px;overflow:hidden}.source-title{background:#311d70;color:#e8be20;font:700 18px Georgia,serif;padding:11px 10px}.source-period{background:#f2eff7;padding:7px 10px;font-size:12px;border-bottom:1px solid #d7d4df}.source-sheet table{font:12px Arial,sans-serif;min-width:100%;border-collapse:collapse}.source-sheet th{background:#311d70;color:#fff;text-align:center;padding:6px 8px;font-size:12px;border:1px solid #49388b}.source-sheet td{border:1px solid #d9d9df;padding:5px 8px;text-align:center}.source-sheet td:first-child{text-align:left;min-width:220px}.source-sheet tbody tr:nth-child(odd){background:#f3f3f5}.source-sheet .negative{color:#d60000}.source-sheet .scroll{max-height:62vh}.account-editor select,.account-editor input{min-width:120px;width:100%;padding:8px;border:1px solid #cbd7e5;border-radius:6px}.credit-row{max-width:740px}.tracking-sheet td.amber{background:#fff0ce;color:#805600}.unknown{background:#eceff3;color:#667080}.portalcard .portal-link{display:inline-block;text-decoration:none}
.receipt-backdrop{position:fixed;inset:0;z-index:100;background:#17263a66;display:flex;align-items:center;justify-content:center;padding:18px}.receipt-modal{background:#fff;border-radius:20px;max-width:560px;width:100%;max-height:92vh;overflow:auto;padding:24px;box-shadow:0 16px 64px #12233440}.receipt-modal h2{font-size:22px;font-weight:600;margin:0}.receipt-modal .receipt-box{background:#f6f8fa;border:1px solid #dce4eb;border-radius:8px;padding:16px;margin:16px 0;overflow-wrap:anywhere}.receipt-modal .close{border:0;background:transparent;color:#50627a;font-size:24px;padding:0 7px;cursor:pointer}.receipt-modal .modal-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:20px}.receipt-modal .actions{align-items:center}.receipt-modal .receipt{font-size:14px;line-height:1.45}.tracker-cell:focus-visible,.linkbtn:focus-visible{outline:2px solid #147b67;outline-offset:3px}.overview-sheet td:nth-child(2){text-align:left;min-width:130px}.overview-sheet td:last-child{font-weight:700}.overview-sheet .source-title{text-align:center}.overview-sheet .source-period{display:flex;gap:16px;flex-wrap:wrap;align-items:center}.tracking-sheet .caption-small{font-size:10px;margin-top:6px;line-height:1.35}.tracking-sheet td.zero{color:#536a80}.tracking-sheet th{min-width:116px}@media print{.receipt-backdrop{display:none!important}}
.payment-editor{border-top:1px solid #dce4eb;margin-top:20px;padding-top:18px}.payment-editor .filter{gap:10px}.payment-editor input[type=date]{min-width:130px}.customer-status-choices{display:grid;gap:8px;margin:12px 0}.customer-status-choices label{font-size:13px}.no-bill .number{font-size:28px;color:#36536b}.upload-tabs{margin:16px 0}.upload-drop{border:1px dashed #9bb5c3;background:#f5fafb;padding:18px;border-radius:10px;margin:12px 0}.upload-drop input{max-width:100%}.upload-drop p{margin:7px 0 12px}.upload-panel .notice p{margin:5px 0 0}.vault-password{display:inline-block;min-width:82px;overflow-wrap:anywhere;font-family:monospace;user-select:text}.vault-reveal{margin:4px 0}.history-invoice{white-space:nowrap}@media print{body.vault-page #page{display:none!important}}.et-clock{font-size:16px;font-weight:750;color:#173654;font-variant-numeric:tabular-nums;margin:4px 0}.filter label.unpaid-toggle{display:flex;align-items:center;flex:0 0 auto;min-width:0;gap:8px;padding:10px 0;height:42px;white-space:nowrap}.filter label.unpaid-toggle input,.filter .customer-choice input{width:16px;height:16px;padding:0;margin:0;accent-color:#147b67;flex-shrink:0}.customer-picker{flex:2;min-width:230px;position:relative}.customer-picker summary{cursor:pointer;padding:10px;border:1px solid #cbd7e5;border-radius:8px;background:#fff;color:#21334a;list-style:none}.customer-picker summary::after{content:' ▾';float:right}.customer-picker .picker-menu{border:1px solid #cbd7e5;padding:10px;background:white;border-radius:8px;margin-top:6px;max-height:260px;overflow:auto}.filter .customer-choice{display:flex;gap:8px;align-items:center;padding:7px 3px;font-weight:400;min-width:0}.filter .picker-caption{display:block;margin-bottom:7px;font-weight:600;color:#50627a;font-size:13px}.selected-tags{display:flex;flex-wrap:wrap;gap:4px;margin-top:6px}.selected-tags button{border:1px solid #cbd7e5;background:#edf3f8;padding:4px 8px;border-radius:16px;color:#21334a;font-size:12px}.export-note{font-size:12px;color:#61758d;margin-top:8px}
/* V13: keep invoice filters aligned; the customer list floats above the tracker. */
.invoice-filter{display:grid;grid-template-columns:minmax(180px,1fr) minmax(240px,2fr) auto;align-items:start;gap:12px;position:relative}
.invoice-filter>label:first-child,.invoice-filter>.customer-picker{min-width:0}
.invoice-filter #trackMonth,.invoice-filter .customer-picker summary{height:42px}
.invoice-filter .customer-picker{min-width:0}
.invoice-filter .customer-picker summary{display:flex;align-items:center;justify-content:space-between;gap:8px;white-space:nowrap;overflow:hidden}
.invoice-filter .customer-picker details{position:relative}
.invoice-filter .customer-picker .picker-menu{position:absolute;top:calc(100% + 5px);left:0;right:0;z-index:60;max-height:none;overflow:visible;margin:0;box-shadow:0 12px 30px #17263a29;border:1px solid #bdcce0;border-radius:10px;padding:12px;background:#fff}
.invoice-filter .picker-list{max-height:220px;overflow-y:auto;overscroll-behavior:contain;padding:2px 4px 2px 0;scrollbar-gutter:stable}
.invoice-filter .picker-menu .actions{margin:8px 0}
.invoice-filter .customer-choice{border-radius:5px}
.invoice-filter .customer-choice:hover{background:#edf3f8}
.invoice-filter label.unpaid-toggle{margin-top:22px;align-self:start}
.invoice-filter .selected-tags:empty{display:none}
@media(max-width:850px){.invoice-filter{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.invoice-filter label.unpaid-toggle{margin-top:0}}
@media(max-width:520px){.invoice-filter{grid-template-columns:minmax(0,1fr)}.invoice-filter .picker-list{max-height:180px}}

/* V15: space the validation result and show the parsed store records, not a file-only grid. */
.upload-preview{margin-top:20px}
.upload-preview>.notice{margin-bottom:20px;padding:14px 16px}
.upload-preview>.notice p{margin:5px 0 0}
.upload-preview-title{display:flex;justify-content:space-between;gap:12px;align-items:baseline;flex-wrap:wrap;margin:20px 0 12px}
.preview-file{border:1px solid #d6e0eb;border-radius:12px;background:#f9fbfd;margin:12px 0 18px;overflow:hidden}
.preview-file>summary{cursor:pointer;padding:14px 16px;background:#edf3f8;color:#203954;font-weight:700;line-height:1.5;overflow-wrap:anywhere}
.preview-file>summary .caption-small{font-weight:500;display:inline}
.preview-file-totals{display:flex;gap:10px 22px;padding:12px 16px;flex-wrap:wrap;font-size:13px;color:#50627a;border-bottom:1px solid #dbe4ee}
.preview-file-totals strong{color:#17263a}
/* V16: a compact source-style grid with one row for each parsed store. */
.preview-file .preview-scroll{overflow:auto;max-height:65vh;background:#fff}
.preview-file .preview-table{border-collapse:collapse;min-width:100%;font:11px/1.4 Arial,sans-serif;white-space:nowrap}
.preview-file .preview-table th{position:sticky;top:0;z-index:2;background:#311d70;color:#fff;border:1px solid #49388b;padding:7px 6px;text-align:center;white-space:normal;min-width:74px;font-size:11px;vertical-align:middle}
.preview-file .preview-table td{padding:5px 7px;border:1px solid #d9d9df;white-space:nowrap;vertical-align:middle}
.preview-file .preview-table tbody tr:nth-child(odd){background:#f3f3f5}
.preview-file .preview-table td:first-child,.preview-file .preview-table td:nth-child(2){text-align:left}
.preview-file .preview-table th:first-child{min-width:180px;position:sticky;left:0;z-index:3}
.preview-file .preview-table td:first-child{position:sticky;left:0;z-index:1;background:white;font-weight:600}
.preview-file .preview-table tbody tr:nth-child(odd) td:first-child{background:#f3f3f5}
.preview-file .preview-table th:nth-child(2){min-width:110px}
.preview-file .preview-table th:last-child{min-width:112px}
.preview-file .preview-table .num{font-variant-numeric:tabular-nums;text-align:right}
.preview-file .preview-table .negative{color:#c40000}
.preview-file .preview-table .bill-due{font-weight:700}
.preview-file .preview-table .pill{font-size:10px;padding:3px 6px;font-weight:600}
.preview-file .preview-table .review-row td{background:#fff6df}
.preview-file .preview-table tr.review-row td:first-child{background:#fff6df}
.preview-table-note{padding:9px 14px;border-top:1px solid #dbe4ee;font-size:12px;color:#50627a;margin:0}
/* V16: bulk payment controls only in the selected customer's invoice history. */
.bulk-payment-bar{border:1px solid #dce4ee;border-radius:9px;background:#f6f9fc;padding:12px 15px;margin:12px 0 14px;display:flex;align-items:end;gap:14px;flex-wrap:wrap}
.bulk-payment-bar label{display:grid;gap:5px;font-size:12px;font-weight:600;color:#50627a}
.bulk-payment-bar input[type=date]{padding:8px;border:1px solid #cbd7e5;border-radius:7px;background:white;font:inherit;color:#21334a}
.bulk-payment-bar .bulk-summary{flex:1;min-width:160px;font-size:13px}
.bulk-payment-bar .bulk-summary strong{display:block;margin-bottom:4px}
.customer-history .select-payment{width:44px;min-width:44px;text-align:center}
.customer-history input[type=checkbox]{width:16px;height:16px;accent-color:#147b67;vertical-align:middle}
.customer-history .history-invoice{font-size:12px;padding:7px 10px}

/* V17: supplied company mark and consistent in-app confirmation dialog. */
.brand-logo{width:58px;height:58px;object-fit:contain;border-radius:50%;background:#050505;flex-shrink:0}
.layout{min-height:calc(100vh - 91px)}
.confirm-dialog{width:min(470px,calc(100vw - 32px));max-width:470px;padding:0;border:1px solid #d9e3ed;border-radius:19px;background:#fff;color:#17263a;box-shadow:0 20px 70px #14294147;font:inherit}
.confirm-dialog::backdrop{background:#12233575;backdrop-filter:blur(2px)}
.confirm-content{padding:26px 26px 22px}
.confirm-icon{width:48px;height:48px;border-radius:14px;display:grid;place-items:center;background:#e5f5ee;color:#147b67;font-size:26px;font-weight:800;margin-bottom:16px}
.confirm-dialog.is-danger .confirm-icon{background:#feecee;color:#b42335}
.confirm-dialog h2{font-size:22px;line-height:1.25;margin:0 0 11px;font-weight:750}
.confirm-dialog p{font-size:14px;line-height:1.6;color:#50627a;margin:0;white-space:pre-line;overflow-wrap:anywhere}
.confirm-footer{border-top:1px solid #e3eaf1;padding:15px 24px;display:flex;justify-content:flex-end;align-items:center;gap:10px;background:#f8fafc;border-radius:0 0 19px 19px}
.confirm-footer .btn{min-width:94px}
.confirm-footer .confirm-danger{background:#b42335;color:#fff;border:1px solid #b42335}
.confirm-dialog button:focus-visible{outline:2px solid #147b67;outline-offset:3px}
@media(max-width:520px){.brand-logo{width:48px;height:48px}.confirm-content{padding:22px}.confirm-footer{padding:14px 20px}}
@media print{.confirm-dialog{display:none!important}}
/* Approved brand, standalone authentication. */
body.auth-pending > header,body.auth-pending > .layout,body.auth-pending > #logout {display:none!important}
.auth-screen{min-height:100dvh;display:grid;place-items:center;background:radial-gradient(ellipse at 50% 10%,#243c51,#101e2f 68%);padding:24px;box-sizing:border-box}
body:not(.auth-pending) .auth-screen{display:none}
.auth-card{display:flex;flex-direction:column;gap:10px;width:100%;max-width:410px;background:#fff;border-radius:16px;padding:32px 34px;box-shadow:0 18px 70px #06111f80;box-sizing:border-box}
.auth-logo{width:92px;height:92px;object-fit:contain;align-self:center;border-radius:50%;margin-bottom:6px}
.auth-eyebrow{font-weight:700;letter-spacing:1.8px;font-size:10px;color:#9a7835;text-align:center;margin-top:3px}
.auth-card h1{text-align:center;color:#52647b;font-size:16px;font-weight:500;margin:1px 0 -4px}
.auth-card h2{text-align:center;font-size:24px;color:#14273a;margin:0;line-height:1.25}
.auth-caption{font-size:13px;color:#67788b;text-align:center;margin:0 0 16px}
.auth-card label{font-size:13px;font-weight:600;color:#31475b;margin-top:5px}
.auth-card input{width:100%;box-sizing:border-box;height:43px;border:1px solid #cbd5df;border-radius:7px;padding:11px 13px;font-size:14px;background:white}
.auth-card input:focus{outline:2px solid #178574;outline-offset:1px}
.auth-submit{height:44px;background:#117967;color:white;border:0;border-radius:7px;font-weight:700;font-size:14px;margin-top:10px;cursor:pointer}
.auth-submit:disabled{opacity:.65;cursor:wait}
.auth-footer{border-top:1px solid #e5eaf0;padding-top:15px;text-align:center;font-size:11px;color:#718196;margin-top:10px}
#login-error{color:#9f1825;background:#fff1f1;border-radius:6px;padding:10px;font-size:12px;margin:0}
.auth-logout{position:fixed;bottom:12px;left:13px;z-index:100;border:1px solid #557084;border-radius:7px;color:white;background:#192f44;padding:8px 12px;cursor:pointer;font-size:12px}
@media(max-width:480px){.auth-card{padding:25px 22px}.auth-card h2{font-size:22px}}
@media print{#logout,.auth-screen{display:none!important}}
.admin-fields [hidden]{display:none!important}.admin-fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:14px;align-items:end}.admin-form .actions{margin-top:16px}.admin-actions-cell{display:table-cell;vertical-align:middle}.admin-actions{display:flex;align-items:center;gap:7px;flex-wrap:wrap;min-height:24px}.admin-actions .muted{line-height:1.4}.admin-actions .btn{padding:8px 12px;font-size:13px}.admin-form h3{margin-bottom:5px}.admin-form .caption-small{margin-top:12px}

/* File library: compact folders and documents, with a separate preview. */
.file-crumbs{display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:14px 12px;background:#f4f7fa;border:1px solid #dce4ed;border-radius:8px;margin:16px 0;color:#74839a}
.file-crumb,.file-item{border:0;background:transparent;color:#17675e;text-align:left;cursor:pointer;font:inherit}
.file-crumb{padding:3px 4px;font-weight:600}.file-crumb:hover,.file-item:hover{text-decoration:underline}
.file-toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:10px;margin:0 0 18px}
.file-form{display:flex;align-items:flex-end;gap:10px;padding:14px;background:#f4f7fa;border:1px solid #dce4ed;border-radius:8px;margin:0 0 18px;flex-wrap:wrap}
.file-form label{display:grid;gap:6px;min-width:200px;flex:1;font-size:13px}.file-form input{padding:9px;border:1px solid #cbd5e1;border-radius:6px;background:#fff}
.file-table table{min-width:720px}.file-table td{padding:12px 10px}.file-item{display:flex;align-items:center;gap:12px;max-width:400px;overflow-wrap:anywhere}.file-icon{display:inline-flex;width:36px;height:34px;border-radius:7px;align-items:center;justify-content:center;flex-shrink:0;font-size:10px;font-weight:700}
.file-icon.folder{background:#fbefd4;color:#af760b;font-size:21px}.file-icon.document{background:#e4f0ed;color:#17675e}
.file-actions{white-space:nowrap}.file-actions .btn{margin:0 4px 0 0;font-size:12px;padding:6px 9px}
.file-empty{text-align:center;padding:54px 20px}.file-empty h3{margin:10px 0 8px}.file-empty-icon{font-size:36px;color:#bb8b3b}.file-notice{margin:12px 0 18px}
.file-preview-panel{margin-top:18px;scroll-margin-top:12px}.file-preview-tools{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:15px 0;flex-wrap:wrap}
.file-preview-grid{max-height:470px;overflow:auto;border:1px solid #dbe4ee}.file-preview-grid td{white-space:nowrap;min-width:75px}.file-preview-grid th{color:#53677c;min-width:40px;text-align:center;background:#edf2f7}
.file-text{white-space:pre-wrap;overflow-wrap:anywhere;background:#f4f7fa;padding:15px;border-radius:8px;max-height:470px;overflow:auto}

/* V18.4 — reliable small-screen navigation, accessible controls and responsive file lists. */
.nav-wrap{min-width:0;background:#142941}
.nav-wrap nav{height:100%}
.mobile-nav-toggle,.nav-backdrop,.drawer-header{display:none}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
nav button:focus-visible,.mobile-nav-toggle:focus-visible,.file-item:focus-visible,.file-crumb:focus-visible{outline:2px solid #44c7b0;outline-offset:2px}
.file-table{max-width:100%}.file-table table{min-width:760px}
.file-actions .danger{font-weight:700}
.file-panel .heading>div,.file-preview-panel .heading>div{min-width:0;overflow-wrap:anywhere}
.file-form input{min-width:0;width:100%}
.share-mode .nav-wrap{display:none}
@media screen and (max-width:900px){
 .layout{grid-template-columns:minmax(0,1fr);align-content:start;min-height:calc(100dvh - 77px)}
 /* Mobile: a genuine off-canvas left sidebar, not a horizontal navigation bar. */
 body.mobile-drawer-open{overflow:hidden}
 .layout{display:block}
 .nav-wrap{position:fixed;top:0;bottom:0;left:0;z-index:85;width:min(300px,calc(100vw - 40px));max-width:100%;min-width:0;display:flex;flex-direction:column;background:#142941;color:#eef5fc;box-shadow:8px 0 30px #0b1f3a40;transform:translateX(-100%);visibility:hidden;pointer-events:none;transition:transform .22s ease,visibility .22s;overscroll-behavior:contain}
 .nav-wrap.open{transform:translateX(0);visibility:visible;pointer-events:auto}
 .nav-backdrop{display:block;position:fixed;inset:0;z-index:84;background:#10243d8a;border:0;padding:0;opacity:0;visibility:hidden;pointer-events:none;transition:opacity .22s ease,visibility .22s}
 body.mobile-drawer-open .nav-backdrop{opacity:1;visibility:visible;pointer-events:auto}
 .drawer-header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:22px 17px 19px;border-bottom:1px solid #ffffff1d;flex:0 0 auto}
 .drawer-header strong{display:block;font-size:18px;color:#fff;line-height:1.3}
 .drawer-header small{display:block;font-size:12px;color:#a6bbcf;margin-top:5px;text-transform:uppercase;letter-spacing:.08em}
 .drawer-close{display:grid;place-items:center;width:42px;height:42px;flex:0 0 42px;font-size:25px;line-height:1;color:#fff;border:1px solid #47617c;border-radius:8px;background:#203a55}
 .mobile-nav-toggle{display:grid;place-items:center;flex:0 0 42px;width:42px;height:44px;padding:0;border:1px solid #dbe3eb;border-radius:9px;background:#f1f5f9;color:#142941;font-weight:700}
 .mobile-menu-icon{display:grid;gap:4px;width:19px}
 .mobile-menu-icon i{display:block;height:2px;background:#203e59;border-radius:2px}
 .nav-wrap nav{height:auto;flex:1 1 auto;min-height:0;display:flex;flex-direction:column;gap:5px;padding:16px 12px;overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}
 .nav-wrap nav button{flex:0 0 auto;display:block;width:100%;white-space:normal;overflow-wrap:anywhere;min-height:48px;padding:13px 14px;font-size:14px;line-height:1.35;text-align:left}
 .nav-wrap nav button.active{box-shadow:inset 3px 0 #63c9b6;background:#294964;color:#fff}
 .drawer-close:focus-visible{outline:2px solid #44c7b0;outline-offset:2px}
 .share-mode .nav-backdrop{display:none!important}
 @media(prefers-reduced-motion:reduce){.nav-wrap,.nav-backdrop{transition:none}}
 header{position:sticky;top:0;z-index:70;padding:12px;gap:10px;align-items:center;box-shadow:0 2px 8px #27364b10}
 header .brand{min-width:0;gap:9px;flex:1 1 auto}
 header .brand h1{font-size:16px;line-height:1.25}
 header .brand .muted{font-size:11px;line-height:1.3}
 header .right{display:flex;flex-direction:column;align-items:flex-end;min-width:0;gap:3px;flex-shrink:0}
 header .right #identity{font-size:12px}
 header .right #synctime{font-size:10px;max-width:170px;overflow-wrap:anywhere}
 .et-clock{font-size:13px;margin:0}
 .auth-logout{position:static;color:#29445e;background:#edf3f8;border:1px solid #d2ddeb;min-height:32px;padding:5px 11px;margin-top:3px}
 main{width:100%;min-width:0;padding:14px}
 .panel,.card,.filter,.heading,.tracking-sheet,.docpaper{min-width:0;max-width:100%}
 .filter label,.customer-picker,.filter input,.filter select,.customer-grid>label{min-width:0}
 .actions button,.actions .btn,.file-toolbar .btn{min-height:42px;white-space:normal}
 .two-portals{grid-template-columns:repeat(2,minmax(0,1fr))}
 .two-portals .btn{white-space:normal;overflow-wrap:anywhere;padding:12px}
 .scroll,.preview-scroll{max-width:100%;overscroll-behavior-x:contain}
 .file-table{max-height:none;overflow:visible}
 .file-table table,.file-table tbody{display:block;width:100%;min-width:0}
 .file-table thead{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
 .file-table tbody tr{display:flex;flex-wrap:wrap;align-items:center;gap:5px 12px;border:1px solid #dae4ec;border-radius:10px;padding:12px;margin:8px 0;background:#fff}
 .file-table td{border:0;padding:0;white-space:normal;min-width:0;overflow-wrap:anywhere}
 .file-table td:first-child{width:100%}
 .file-item{max-width:100%;width:100%;padding:3px 0;min-height:44px}
 .file-table .file-type,.file-table .file-size,.file-table .file-date{color:#53677c;font-size:12px}
 .file-table .file-size::before{content:"Size: ";font-weight:600}
 .file-table .file-date::before{content:"Uploaded: ";font-weight:600}
 .file-table .file-meta-empty{display:none}
 .file-actions{display:flex;flex-wrap:wrap;gap:8px;width:100%;margin-top:6px;padding-top:9px!important;border-top:1px solid #e3eaf0!important}
 .file-actions .btn{margin:0;min-height:40px;padding:8px 12px;flex:1;min-width:76px}
 .file-toolbar{gap:8px}.file-toolbar .caption-small{width:100%}.file-crumbs{padding:10px;gap:5px}
 .file-crumb{max-width:100%;overflow-wrap:anywhere;min-height:38px;text-align:left}
 .file-preview-grid{max-height:60dvh}.file-preview-grid th{position:sticky;left:0;z-index:2}
}
@media screen and (max-width:520px){
 header{padding:9px;gap:7px}
 .mobile-nav-toggle{width:38px;flex-basis:38px;height:42px}
 header .brand{gap:6px}
 header .brand-logo{width:34px;height:34px}
 header .brand h1{font-size:14px}
 header .brand .muted{font-size:10px}
 header .right #synctime{display:none}
 header .right #identity{font-size:11px}
 .et-clock{font-size:12px}
 main{padding:10px}
 h2{font-size:23px}h3{font-size:16px}
 .heading{align-items:stretch;gap:10px;margin-bottom:14px}
 .heading>button{align-self:flex-start}
 .panel{padding:13px;border-radius:12px}
 .cards{gap:8px;grid-template-columns:repeat(2,minmax(0,1fr))}
 .card .number{font-size:clamp(16px,4.5vw,20px);overflow-wrap:anywhere}
 .filter{grid-template-columns:minmax(0,1fr);gap:11px}
 .invoice-filter,.admin-fields{grid-template-columns:minmax(0,1fr)}
 .file-form{gap:8px;padding:10px}.file-form label{min-width:0;width:100%;flex-basis:100%}
 .file-form .btn{flex:1;min-height:42px}
 .file-empty{padding:34px 12px}
 .receipt-backdrop{padding:10px}.receipt-modal{padding:17px;max-height:92dvh}
 .receipt-modal .actions .btn{flex:1}
 .docpaper{padding:14px}
 .invoice-head,.invoice-meta{flex-direction:column;align-items:stretch;margin-bottom:18px}
 .docpaper .invoice-table{table-layout:fixed;font-size:10px}
 .invoice-table th,.invoice-table td{overflow-wrap:anywhere;white-space:normal;padding:6px 3px}
 .invoice-table td:first-child{width:22px}
 .invoice-totals div{padding:8px;gap:8px}
 .confirm-footer{padding:12px 15px}
 .confirm-footer .btn{min-height:44px}
}
@media print{.nav-wrap,.nav-backdrop,.mobile-nav-toggle{display:none!important}}

/* V18.6: shared dropdown controls, responsive action iconography. */
:root{
 --dropdown-bg:#fff;--dropdown-border:#cbd7e5;--dropdown-text:#21334a;
 --dropdown-height:42px;--dropdown-radius:8px;
 --dropdown-chevron:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23536578' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
select:not([multiple]),.customer-picker details>summary,.invoice-filter .customer-picker details>summary{
 appearance:none;-webkit-appearance:none;box-sizing:border-box;
 height:var(--dropdown-height);min-height:var(--dropdown-height);max-width:100%;
 border:1px solid var(--dropdown-border);border-radius:var(--dropdown-radius);
 background:var(--dropdown-bg) var(--dropdown-chevron) no-repeat right 12px center/16px 16px;
 color:var(--dropdown-text);font-family:inherit;font-size:14px;font-weight:400;line-height:1.35;
 padding:0 38px 0 12px;box-shadow:none;cursor:pointer;
}
.customer-picker details>summary{display:flex;align-items:center;list-style:none}
.customer-picker summary::-webkit-details-marker{display:none}
.customer-picker summary::after{content:none}
select:not([multiple]):not(:disabled):hover,.customer-picker details>summary:hover{border-color:#8ca6bc}
select:not([multiple]):focus-visible,.customer-picker details>summary:focus-visible{border-color:#147b67;outline:2px solid #147b67;outline-offset:2px}
select:not([multiple]):disabled{background-color:#f1f4f7;color:#78899b;cursor:not-allowed;opacity:.8}
.invoice-filter .customer-picker .picker-menu{border:1px solid var(--dropdown-border);border-radius:var(--dropdown-radius);background:var(--dropdown-bg)}
.action-icon{display:none;flex-shrink:0}
.action-icon-button:focus-visible{outline:2px solid #147b67;outline-offset:2px}
@media screen and (max-width:900px){
 select:not([multiple]),.customer-picker details>summary,.invoice-filter .customer-picker details>summary{font-size:16px;min-height:44px;height:44px}
 .invoice-filter #trackMonth{height:44px}
 .invoice-filter .customer-picker .customer-choice{min-height:44px}
 .action-icon-button{display:inline-flex;align-items:center;justify-content:center;gap:7px}
 .action-icon-button .action-icon{display:block;width:18px;height:18px}
 .btn.row-action-icon,.file-actions .btn.row-action-icon,.admin-actions .btn.row-action-icon{
  width:44px;height:44px;min-width:44px;min-height:44px;flex:0 0 44px;padding:0;justify-content:center;gap:0
 }
 .row-action-icon .action-label{display:none}
 .row-action-icon .action-icon{width:20px;height:20px}
 .vault-remove.row-action-icon{color:#a32e37}
}
@media(forced-colors:active){
 select:not([multiple]){appearance:auto;-webkit-appearance:auto;background-image:none;padding-right:12px}
 .customer-picker details>summary{background-image:none}
 .customer-picker summary::after{content:' ▾'}
}

/* V18.7 — consistent compact controls and faster mobile interaction. */
.control-icon{display:block;width:20px;height:20px;flex:0 0 20px}
.page-heading{display:block;min-width:0}
.heading-title{display:flex;align-items:center;gap:10px;min-width:0;margin-bottom:4px}
.heading-title h2{margin:0;min-width:0;overflow-wrap:anywhere}
.heading-title .refresh-icon{display:grid;place-items:center;flex:0 0 36px;width:36px;height:36px;padding:0;border-radius:8px;color:#203954;background:#edf3f8}
.refresh-icon:focus-visible,.export-menu summary:focus-visible,.export-options button:focus-visible,.portal-link:focus-visible{outline:2px solid #147b67;outline-offset:2px}
.refresh-icon:disabled .control-icon{animation:refresh-spin .9s linear infinite}
@keyframes refresh-spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.refresh-icon:disabled .control-icon{animation:none}}
.export-menu{position:relative;display:inline-block;max-width:100%;align-self:flex-start}
.export-menu>summary{list-style:none;display:flex;align-items:center;gap:9px;padding:0 38px 0 12px;height:var(--dropdown-height);min-height:var(--dropdown-height);border:1px solid var(--dropdown-border);border-radius:var(--dropdown-radius);background:var(--dropdown-bg) var(--dropdown-chevron) no-repeat right 12px center/16px 16px;color:var(--dropdown-text);font-size:14px;font-weight:600;cursor:pointer;white-space:nowrap;user-select:none}
.export-menu>summary::-webkit-details-marker{display:none}
.export-menu>summary:hover{border-color:#8ca6bc}
.export-menu[open]>summary{border-color:#147b67}
.export-options{position:absolute;top:calc(100% + 5px);left:0;z-index:65;min-width:155px;max-width:calc(100vw - 34px);border:1px solid var(--dropdown-border);border-radius:var(--dropdown-radius);box-shadow:0 8px 24px #17263a24;background:#fff;padding:5px}
.export-options button{font:inherit;text-align:left;display:block;width:100%;min-height:38px;padding:8px 12px;border:0;border-radius:5px;background:transparent;color:var(--dropdown-text);white-space:nowrap;font-size:14px}
.export-options button:not(:disabled):hover{background:#eef4f8;color:#147b67}
.export-options button:disabled{opacity:.55;cursor:not-allowed}
.picker-list .customer-choice[hidden],#trackSearchEmpty[hidden]{display:none!important}
#portalPanel .two-portals{max-width:none;gap:12px}
#portalPanel .portalcard{display:flex;flex-direction:column;justify-content:space-between;align-items:start;gap:12px;min-width:0;padding:14px}
.portal-info,.portal-url{min-width:0;max-width:100%;overflow-wrap:anywhere;word-break:normal}
.portal-url{font-size:12px;line-height:1.45;margin-top:4px}
#portalPanel .portal-link{display:inline-flex;justify-content:center;align-items:center;gap:7px;max-width:100%;padding:9px 12px;font-size:13px;white-space:normal}

@media screen and (max-width:900px){
 .nav-wrap nav button.active{box-shadow:none}
 .heading-title .refresh-icon{flex-basis:44px;width:44px;height:44px;min-height:44px}
 .heading-title{gap:8px}
 .export-menu>summary{height:44px;min-height:44px;font-size:14px}
 .export-options button{min-height:44px}
 #portalPanel .two-portals{grid-template-columns:minmax(0,1fr);gap:8px}
 #portalPanel .portalcard{display:grid;grid-template-columns:minmax(0,1fr) 44px;align-items:center;gap:10px;padding:11px 12px}
 #portalPanel .portalcard b{margin:0;font-size:14px}
 #portalPanel .portal-link{width:44px;height:44px;min-width:44px;padding:0;align-self:center}
 #portalPanel .portal-link span{display:none}
 .upload-panel .upload-tabs{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:12px 0}
 .upload-panel .upload-tabs .btn,.upload-panel .actions .btn{min-height:44px;font-size:13px;padding:8px 10px;line-height:1.3;white-space:normal;word-break:normal;overflow-wrap:anywhere}
 .upload-panel .upload-drop{padding:12px;margin:10px 0}
 .upload-panel .notice{padding:10px 12px}
 .upload-panel .upload-drop input{width:100%;max-width:100%;min-width:0}
 .upload-panel .upload-drop input::file-selector-button{max-width:100%;border:1px solid #cbd7e5;border-radius:7px;background:#edf3f8;color:#203954;font:inherit;font-size:13px;padding:7px 10px;margin-right:8px}
}
@media screen and (max-width:520px){
 .page-heading{display:block;margin-bottom:14px}
 .page-heading .heading-title{justify-content:space-between}
 .source-panel>.heading>.actions{align-items:center}
 .source-panel .actions .btn{font-size:13px;padding:10px 12px;min-height:44px}
 .source-panel .export-options{left:0;right:auto}
}

/* Keep export menus within the page at all phone widths. */
.source-panel .export-options{left:auto;right:0}
.upload-tabs .upload-tab{display:flex;align-items:center;justify-content:center;gap:6px}
.upload-tabs .upload-tab .control-icon{width:18px;height:18px;flex-basis:18px}
@media screen and (max-width:900px){
 .source-panel>.heading{flex-direction:column;align-items:stretch}
 .source-panel .export-options{left:0;right:auto}
 .upload-tabs .upload-report-suffix{display:none}
 .upload-panel .upload-tabs .upload-tab{padding:7px 8px;white-space:nowrap}
 .nav-wrap{transition:transform .12s ease,visibility .12s}
 .nav-backdrop{transition:opacity .12s ease,visibility .12s}
}
@media screen and (max-width:900px) and (prefers-reduced-motion:reduce){.nav-wrap,.nav-backdrop{transition:none}}

/* V18.8: compact invoice tracker controls and screenshot toolbar. */
.invoice-filter-tail{display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0}
.invoice-actions-menu{display:none}
.invoice-actions-menu>summary{gap:0;min-width:108px}
.invoice-actions-menu .export-options{right:0;left:auto;min-width:188px}
.invoice-actions-menu .export-options button{display:flex;align-items:center;gap:9px}
.invoice-actions-menu .export-options .control-icon{width:17px;height:17px;flex-basis:17px}
.tracker-message{display:block;font-size:12px;line-height:1.4;margin-top:8px}
.tracker-message:empty{display:none}
.tracking-heading{margin:0 0 12px;align-items:flex-start}
.tracking-totals{text-align:right;display:flex;flex-direction:column;gap:4px}
.share-actions{display:flex;align-items:center;gap:8px;flex-wrap:nowrap}
.share-actions .share-action{display:inline-flex;align-items:center;justify-content:center;gap:7px;padding:9px 12px;min-height:40px;white-space:nowrap}
.share-actions .share-icon{width:40px;min-width:40px;height:40px;padding:0;flex:0 0 40px}
.share-actions .share-action:focus-visible{outline:2px solid #147b67;outline-offset:2px}
@media screen and (max-width:900px){
 .invoice-filter-tail{grid-column:1/-1;align-items:center;justify-content:space-between}
 .invoice-filter-tail label.unpaid-toggle{margin:0;min-height:44px}
 .invoice-filter .invoice-actions-menu{display:block}
 .invoice-desktop-actions{display:none}
 .tracking-heading{display:flex;flex-direction:column;align-items:flex-start;gap:7px}
 .tracking-totals{display:flex;flex-direction:row;align-items:center;flex-wrap:wrap;text-align:left;font-size:13px;gap:5px 10px}
 .tracking-totals .muted{font-size:12px}
 .tracking-sheet .legend{flex-wrap:nowrap;overflow-x:auto;gap:4px;padding:2px 0 4px;margin:8px 0 10px;scrollbar-width:thin}
 .tracking-sheet .legend span{flex:0 0 auto;white-space:nowrap;font-size:clamp(9px,2.45vw,11px);padding:4px 4px}
 .share-actions{gap:6px}
 .share-actions .share-action{min-height:44px;font-size:13px;line-height:1.3;padding:8px 10px}
 .share-actions .share-icon{width:44px;min-width:44px;height:44px;flex:0 0 44px;padding:0}
}
@media screen and (max-width:360px){
 .tracking-sheet .legend{gap:2px;margin-inline:-4px}
 .tracking-sheet .legend span{font-size:9px;letter-spacing:-.26px;padding:4px 2px}
 .share-actions .share-action:not(.share-icon){padding:8px;font-size:12px;gap:5px}
}

/* Email/password sign-in and user-initiated recovery. */
.auth-credentials{display:flex;flex-direction:column;gap:8px}
.auth-credentials[hidden],.auth-recover[hidden],.auth-status[hidden]{display:none!important}
.auth-status{font-size:12px;line-height:1.45;color:#176840;background:#e9f6ef;border:1px solid #cde9da;border-radius:7px;padding:10px;margin:0}
.auth-recover{background:transparent;border:0;color:#147b67;font-weight:600;font-size:13px;padding:8px;align-self:center}
.auth-recover:hover{text-decoration:underline}
.auth-recover:focus-visible{outline:2px solid #147b67;outline-offset:2px;border-radius:4px}

/* Customer creation and account linking use the existing form design. */
.customer-directory-actions{margin:0 0 14px;flex-wrap:wrap}
.customer-section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:12px}
.customer-section-head h3{margin:0}
.customer-create-panel .customer-grid{margin-bottom:14px}
.customer-account-toggle{display:flex;align-items:center;gap:9px;margin:12px 0}
.customer-account-toggle input{width:auto;min-width:16px;height:16px;min-height:0}
.customer-account-fields{border:0;padding:0;margin:0;min-width:0}
.customer-account-fields[hidden]{display:none}
.customer-create-panel .actions{margin-top:12px}
@media screen and (max-width:600px){.customer-directory-actions .btn{min-height:44px}.customer-create-panel .customer-grid{grid-template-columns:1fr}.customer-section-head .btn{min-height:44px}}

/* V18.10: polished desktop selectors, usable archive space and pinned names. */
@media screen and (min-width:901px){
 .desktop-select-wrap{width:100%;min-width:0;position:relative;display:block}
 .desktop-select-native{display:none!important}
 .desktop-select-trigger{width:100%;height:42px;min-height:42px;border:1px solid #cbd7e5;border-radius:8px;padding:0 36px 0 13px;font-family:inherit;line-height:1.35;font-size:14px;font-weight:500;color:#21334a;background:#fff var(--dropdown-chevron) no-repeat right 12px center/16px 16px;text-align:left;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;cursor:pointer;transition:border-color .13s,box-shadow .13s}
 .desktop-select-trigger:hover:not(:disabled){border-color:#91aabd;background-color:#f9fbfd}
 .desktop-select-trigger:focus-visible,.desktop-select-trigger[aria-expanded=true]{outline:2px solid #147b67;outline-offset:2px;border-color:#147b67}
 .desktop-select-trigger:disabled{color:#8798aa;background-color:#f1f4f7;cursor:not-allowed}
 .desktop-select-menu{position:fixed;z-index:180;padding:5px;background:white;border:1px solid #cbd7e5;border-radius:10px;box-shadow:0 10px 30px #17263a25;overflow:auto;overscroll-behavior:contain}
 .desktop-select-option{display:flex;align-items:center;justify-content:space-between;width:100%;padding:10px 12px;min-height:38px;gap:12px;border:0;border-radius:6px;font-family:inherit;font-size:13px;color:#21334a;background:transparent;text-align:left;cursor:pointer}
 .desktop-select-option[aria-selected=true]{background:#eaf5f1;color:#107363;font-weight:650}
 .desktop-select-option:focus,.desktop-select-option:hover:not(:disabled){background:#edf3f8;outline:none}
 .desktop-select-option:disabled{opacity:.45;cursor:default}
 .desktop-select-tick{color:#147b67;font-weight:700}
 .account-editor .desktop-select-wrap{min-width:130px}
 .file-table{width:100%}.file-table table{width:100%;min-width:760px}
 .file-table th:first-child{width:43%}.file-table th:last-child{width:1%}
 .file-table .file-item{max-width:none;width:100%;text-align:left}.file-table td{vertical-align:middle}.file-actions{white-space:nowrap}
}
.invoice-document-actions{margin-bottom:22px;align-items:center;row-gap:10px}
.invoice-auto-status{font-size:12px;color:#147b67;line-height:1.4;padding:5px 0}
.tracking-sheet table{border-collapse:separate;border-spacing:0}
.tracking-sheet thead th:first-child,.tracking-sheet tbody td:first-child{position:sticky;left:0;z-index:3;min-width:156px;background:#fff;box-shadow:2px 0 4px #17263a10;border-right:1px solid #d5e0e8}
.tracking-sheet thead th:first-child{background:#eaf1f6;z-index:4}
.tracking-sheet tbody td:first-child{font-weight:600;color:#233449}
@media(max-width:520px){.tracking-sheet thead th:first-child,.tracking-sheet tbody td:first-child{min-width:125px;max-width:154px;white-space:normal}}
@media print{.tracking-sheet thead th:first-child,.tracking-sheet tbody td:first-child{position:static;box-shadow:none}.invoice-auto-status{display:none}}
.auth-password-wrap{position:relative;width:100%}
.auth-password-wrap input{width:100%;padding-right:49px!important}
.auth-password-toggle{position:absolute;right:5px;top:50%;transform:translateY(-50%);height:36px;width:38px;display:grid;place-items:center;border:0;border-radius:6px;background:transparent;color:#52677e;cursor:pointer}
.auth-password-toggle:hover{background:#eef3f7;color:#147b67}
.auth-password-toggle:focus-visible{outline:2px solid #147b67;outline-offset:1px}
.auth-eye-slash{display:none}.auth-password-toggle[aria-pressed=true] .auth-eye-slash{display:block}

/* Explorer-style file list, original app palette and compact controls. */
.explorer-controls{display:flex;align-items:center;gap:8px;margin-left:auto}
.explorer-controls label{display:flex;align-items:center;gap:7px;font-size:12px;font-weight:600;color:#53677c}
.explorer-controls select,.explorer-controls .desktop-select-wrap{min-width:110px}
.explorer-controls .desktop-select-trigger{height:38px;min-height:38px}
.file-name-stack{min-width:0;display:flex;flex-direction:column;gap:2px;text-align:left}
.file-name-stack strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%}
.file-name-stack small{display:none;font-size:11px;color:#61758d;font-weight:400}
.file-table .file-item{min-width:0;overflow:hidden;gap:9px}
.file-table .file-icon{width:29px;height:29px;flex:0 0 29px;border-radius:5px}
.file-table .file-icon.folder{background:#fff3d4;color:#bd8611}
.file-table .file-icon.document{font-size:9px;font-weight:800}
.file-table .file-ext-pdf{background:#fdf0f1;color:#b73640}
.file-table .file-ext-xls,.file-table .file-ext-xlsx,.file-table .file-ext-csv{background:#e5f4ec;color:#167855}
.file-table .explorer-group td{padding:11px 8px 5px;background:#f7fafc;color:#52677e;font-weight:700;font-size:12px;border-bottom:0}
.file-table .explorer-list-view{width:100%}
.file-table.explorer-list-view th:nth-child(n+2):nth-child(-n+4),.file-table.explorer-list-view tr:not(.explorer-group) td:nth-child(n+2):nth-child(-n+4){display:none}
.file-table.explorer-list-view th:first-child{width:auto}
.file-table.explorer-list-view .file-name-stack small{display:block}
@media screen and (min-width:901px){
 .file-table table{table-layout:fixed}.file-table th:first-child{width:40%}
 .file-table th:nth-child(2){width:20%}.file-table th:nth-child(3){width:15%}.file-table th:nth-child(4){width:8%}.file-table th:last-child{width:17%}
 .file-table .file-item{white-space:nowrap;max-width:100%}.file-table .file-actions .btn{padding:6px 8px;margin-right:3px;font-size:11px}
 .file-table.explorer-list-view th:first-child{width:77%}.file-table.explorer-list-view th:last-child{width:23%}
}
@media screen and (max-width:900px){
 .file-toolbar .explorer-controls{margin-left:0;flex:1 1 100%;justify-content:flex-start}
 .file-toolbar .file-upload-limit{display:none}
 .explorer-controls label{flex:1;min-width:0}
 .explorer-controls select{min-width:0;width:100%;font-size:13px}
 .file-panel .file-table tbody tr.explorer-folder,.file-panel .file-table tbody tr.explorer-file{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:6px;border:0;border-bottom:1px solid #e1e8ee;border-radius:0;padding:7px 0;margin:0;min-height:54px}
 .file-panel .file-table td.file-name-cell{width:auto;min-width:0;overflow:hidden}
 .file-panel .file-table .file-item{width:100%;max-width:100%;min-width:0;padding:0;gap:6px}
 .file-panel .file-table .file-name-stack strong{font-size:12px}
 .file-panel .file-table .file-icon{width:26px;height:26px;flex-basis:26px}
 .file-panel .file-table td.file-date,.file-panel .file-table td.file-size,.file-panel .file-table td.file-type{display:none}
 .file-panel .file-table .file-actions{grid-column:2;display:flex;align-items:center;justify-content:flex-end;flex-wrap:nowrap;gap:4px;margin:0;padding:0!important;border:0!important;width:auto}
 .file-panel .file-table .file-actions .btn.row-action-icon{flex:0 0 36px;width:36px;min-width:36px;min-height:36px;height:36px;margin:0;padding:0}
 .file-panel .file-table .file-actions .btn.row-action-icon svg{width:17px;height:17px}

 .file-panel .file-table .explorer-file .file-name-stack small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:10px}
 .file-panel .file-table tbody tr.explorer-group{display:block;margin:5px 0 0;padding:0;border:0;border-radius:0;background:#f3f7fa}
 .file-panel .file-table .explorer-group td{display:block;padding:7px 8px;width:100%}
}

@media screen and (min-width:401px) and (max-width:900px){.file-panel .file-table .file-actions .btn.row-action-icon{flex-basis:44px;width:44px;min-width:44px;min-height:44px;height:44px}}

/* Holding reports: compact accordions, accessible editing, full-width scrollable tables. */
.holding-toolbar,.holding-editor{margin-bottom:16px}
.holding-controls{display:flex;align-items:flex-end;justify-content:space-between;gap:14px;margin-bottom:12px}
.holding-controls label{flex:1 1 260px;max-width:430px}
.holding-controls .btn{flex-shrink:0;white-space:nowrap;min-height:42px}
.holding-form-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:15px;margin-top:8px}
.holding-form-grid label{min-width:0}
.holding-form-grid input,.holding-form-grid select{width:100%;min-width:0}
.holding-calculated{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:18px 0 12px}
.holding-calculated>div{padding:14px;border:1px solid #d7e4e8;border-radius:8px;background:#f0f7f6;display:flex;flex-direction:column;gap:5px;color:#2a5c57}
.holding-calculated span{font-size:12px;font-weight:600}
.holding-calculated strong{font-size:21px;font-variant-numeric:tabular-nums;color:#117565;overflow-wrap:anywhere}
.holding-form-actions{margin-top:16px}
.holding-form-error:not(:empty){margin-top:10px;color:#ad2534;font-size:13px;line-height:1.45}
.holding-notice{margin-top:12px}
.holding-groups{display:flex;flex-direction:column;gap:10px;min-width:0}
.holding-group{background:white;border:1px solid #d8e3ed;border-radius:10px;overflow:hidden;min-width:0}
.holding-group>summary{display:flex;align-items:center;gap:10px;list-style:none;cursor:pointer;background:#eaf1f6;padding:14px 16px;min-height:50px;color:#19344c}
.holding-group>summary::-webkit-details-marker{display:none}
.holding-group>summary:focus-visible{outline:2px solid #147b67;outline-offset:-3px}
.holding-group>summary strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.holding-chevron{font-size:17px;line-height:1;transition:transform .16s;display:inline-block;flex-shrink:0}
.holding-group[open] .holding-chevron{transform:rotate(90deg)}
.holding-count{font-size:12px;color:#5b7185;margin-left:auto;white-space:nowrap}
.holding-group-content{padding:13px 15px}
.holding-group-actions{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:12px}
.holding-copy{display:inline-flex;align-items:center;gap:7px;white-space:nowrap}
.holding-table-scroll{width:100%;max-width:100%;overflow-x:auto;overscroll-behavior-x:contain}
.holding-report-table{width:100%;min-width:790px;border-spacing:0;white-space:nowrap;font-variant-numeric:tabular-nums}
.holding-report-table th,.holding-report-table td{padding:10px 12px}
.holding-report-table th{background:#eaf1f6}
.holding-report-table td:nth-child(3),.holding-report-table td:nth-child(4){background:#e7f4f7;color:#17687a}
.holding-report-table tr:nth-child(even) td:not(:nth-child(3)):not(:nth-child(4)){background:#f7f9fb}
.holding-report-table th:first-child,.holding-report-table td:first-child{position:sticky;left:0;z-index:1;background:#fff;border-right:1px solid #dce5ec}
.holding-report-table th:first-child{background:#eaf1f6;z-index:2}
.holding-action-heading,.holding-row-action{text-align:right}
.holding-copy-status{min-height:0;margin:8px 0 0}
.holding-copy-status:empty{display:none}
.holding-empty{text-align:center;padding:28px 12px;color:#5b7185}
@media screen and (max-width:900px){
 .holding-form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
 .holding-form-grid label:first-child{grid-column:1/-1}
 .holding-group>summary{padding:12px 13px}
 .holding-group-content{padding:10px}
 .holding-report-table{min-width:700px;font-size:12px}
 .holding-report-table th,.holding-report-table td{padding:9px 8px}
 .holding-report-table th:first-child,.holding-report-table td:first-child{max-width:142px;white-space:normal;min-width:130px}
}
@media screen and (max-width:420px){
 .holding-controls{gap:8px}
 .holding-controls label{min-width:0}
 .holding-controls .btn{padding:9px 11px;font-size:12px}
 .holding-calculated{gap:8px;margin-top:14px}
 .holding-calculated>div{padding:10px}
 .holding-calculated strong{font-size:18px}
 .holding-copy{font-size:12px;padding:7px 9px;min-height:40px}
 .holding-group-actions .muted{font-size:12px}
}

/* V18.12 — single-row file controls and an embedded, private PDF preview. */
.file-toolbar{display:flex;flex-wrap:nowrap;align-items:center;gap:8px;margin-bottom:7px}
.file-toolbar .file-toolbar-main{display:inline-flex;align-items:center;justify-content:center;gap:7px;white-space:nowrap;min-width:0;min-height:42px}
.file-toolbar .file-toolbar-main .control-icon{flex-shrink:0;width:18px;height:18px}
.file-sort-menu{flex:0 0 auto;margin-left:auto;align-self:center}
.file-sort-menu>summary{width:42px;min-width:42px;height:42px;min-height:42px;padding:0;justify-content:center;background:#fff;gap:0}
.file-sort-menu>summary .control-icon{width:20px;height:20px;flex-shrink:0}
.file-sort-menu .export-options{left:auto;right:0;min-width:170px}
.file-sort-options button{display:flex;align-items:center;justify-content:space-between;gap:12px}
.file-sort-options button[aria-pressed=true]{color:#117565;background:#eef7f4;font-weight:650}
.file-sort-options .control-icon{width:16px;height:16px}
.file-toolbar-meta{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:14px;min-width:0}
.file-toolbar-meta .muted{font-size:11px;overflow-wrap:anywhere}
.file-table.explorer-single-list .file-name-stack small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.file-table.explorer-single-list .file-name-stack{flex:1;min-width:0}
.file-table.explorer-single-list tr.explorer-folder,.file-table.explorer-single-list tr.explorer-file{cursor:pointer}
.file-table.explorer-single-list tr.explorer-folder:hover,.file-table.explorer-single-list tr.explorer-file:hover{background:#f0f6fb}
.file-table.explorer-single-list .file-item{width:100%;max-width:none}
.file-table.explorer-single-list .file-actions{text-align:right}
.file-table.explorer-single-list .file-name-cell{min-width:0}
@media screen and (min-width:901px){
 .file-table.explorer-single-list table{width:100%;min-width:0;table-layout:fixed}
 .file-table.explorer-single-list th:first-child{width:auto}
 .file-table.explorer-single-list th:last-child{width:188px;text-align:right}
 .file-table.explorer-single-list .file-actions .btn{margin-left:3px;margin-right:0}
}
.file-preview-dialog{width:min(960px,calc(100vw - 28px));max-width:calc(100vw - 28px);height:min(900px,calc(100dvh - 28px));max-height:calc(100dvh - 28px);padding:0;border:1px solid #d8e3ed;border-radius:14px;background:#fff;color:#17263a;box-shadow:0 18px 65px #14294155;overflow:hidden}
.file-preview-dialog[open]{display:flex;flex-direction:column}
.file-preview-dialog::backdrop{background:#12233585;backdrop-filter:blur(2px)}
.file-preview-header{flex:0 0 auto;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 17px;border-bottom:1px solid #dce6ed;background:#fff}
.file-preview-heading{flex:1;min-width:0}
.file-preview-heading h3{font-size:15px;margin:0 0 3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.file-preview-heading .muted{font-size:11px}
.file-preview-actions{display:flex;align-items:center;gap:7px;flex-shrink:0}
.file-preview-icon{width:42px;height:42px;display:grid;place-items:center;border:1px solid #d4dfeb;border-radius:8px;background:#edf3f8;color:#28475c;cursor:pointer}
.file-preview-icon:hover{background:#e0ede9;color:#117565}
.file-preview-icon:focus-visible{outline:2px solid #147b67;outline-offset:2px}
.file-preview-body{flex:1;min-height:0;min-width:0;overflow:auto;padding:15px;background:#f3f6f9;overscroll-behavior:contain}
.file-pdf-pages{display:flex;flex-direction:column;align-items:center;gap:14px;min-width:0;width:100%}
.file-pdf-pages canvas{display:block;max-width:100%;height:auto;background:#fff;box-shadow:0 2px 12px #17263a20}
.pdf-preview-state{font-size:12px;line-height:1.4;color:#52677e;text-align:center;padding:2px 0 11px}
.pdf-preview-error,.file-preview-message{padding:14px;color:#8e2934;background:#fff;border:1px solid #e0e7ed;border-radius:7px;overflow-wrap:anywhere}
.pdf-more{align-self:center;margin:7px}
@media screen and (max-width:900px){
 .file-toolbar{gap:6px}
 .file-toolbar .file-toolbar-main{min-height:42px;padding:9px 11px;gap:6px;white-space:nowrap;font-size:12px}
 .file-toolbar .file-toolbar-main .control-icon{width:16px;height:16px}
 .file-toolbar .file-sort-menu{margin-left:auto}
 .file-toolbar-meta .file-upload-limit{display:none}
 .file-table.explorer-single-list .file-name-stack small{font-size:10px}
 .file-preview-dialog{width:calc(100vw - 16px);max-width:calc(100vw - 16px);height:calc(100dvh - 16px);max-height:calc(100dvh - 16px);border-radius:12px}
 .file-preview-header{padding:10px;gap:7px}
 .file-preview-heading h3{font-size:13px}
 .file-preview-icon{height:40px;width:40px}
 .file-preview-body{padding:8px}
}
@media screen and (max-width:360px){
 .file-toolbar{gap:4px}
 .file-toolbar .file-toolbar-main{padding:8px 7px;gap:4px;font-size:11px}
 .file-toolbar .file-toolbar-main .control-icon{width:14px;height:14px}
 .file-sort-menu>summary{height:42px;width:40px;min-width:40px}
}
@media print{.file-preview-dialog{display:none!important}}

/* Keep phone viewports steady while typing; retain manual pinch zoom. */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
@media screen and (max-width:900px){
 html,body{width:100%;max-width:100%;overflow-x:clip}
 .layout{width:100%;max-width:100%;grid-template-columns:minmax(0,1fr)}
 main,#page,.panel,.scroll,.holding-groups,.holding-group-content{min-width:0;max-width:100%}
 .auth-screen{width:100%;max-width:100%;grid-template-columns:minmax(0,1fr);padding:16px;min-width:0}
 .auth-card{width:100%;min-width:0;max-width:410px}
 input:not([type=checkbox]):not([type=radio]):not([type=range]),select,textarea{font-size:16px!important;min-width:0;max-width:100%;box-sizing:border-box}
 .auth-card input{font-size:16px!important}
 .holding-form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
 .holding-form-grid label{display:grid;grid-template-columns:minmax(0,1fr);min-width:0}
 .holding-form-grid input[type=date]{min-width:0;width:100%;max-width:100%;height:44px;padding:8px 10px;box-sizing:border-box;display:block}
 .holding-form-grid input[type=date]::-webkit-date-and-time-value{text-align:left;min-width:0;margin:0}
 .holding-form-grid input[type=date]::-webkit-calendar-picker-indicator{margin:0}
}
@media screen and (max-width:540px){
 .holding-form-grid{gap:13px 10px}
 .holding-form-grid label{font-size:13px}
 .holding-form-grid input[type=date]{height:46px}
 .auth-card{padding:23px 18px}
}

/* Holding Reports — consistent form controls and responsive selection/table layout. */
.holding-controls label,.holding-form-grid label{display:grid;grid-template-columns:minmax(0,1fr);gap:7px;min-width:0;color:#50627a;font-size:13px;font-weight:600;line-height:1.4}
.holding-controls input,.holding-form-grid input,.holding-form-grid select{display:block;width:100%;min-width:0;max-width:100%;height:42px;min-height:42px;padding:10px 12px;box-sizing:border-box;border:1px solid #cbd7e5;border-radius:8px;background:#fff;color:#21334a;line-height:1.35;font-family:inherit;font-size:14px;font-weight:400;outline:none}
.holding-controls input::placeholder,.holding-form-grid input::placeholder{color:#8593a5}
.holding-controls input:focus,.holding-form-grid input:focus,.holding-form-grid select:focus{border-color:#168673;box-shadow:0 0 0 3px #1686731a}
.holding-form-grid input[type=date]{appearance:auto;min-inline-size:0;padding-inline:10px}
.holding-form-grid input[type=date]::-webkit-date-and-time-value{text-align:left;min-width:0;margin:0}
.holding-form-grid .desktop-select,.holding-form-grid .desktop-select-trigger{min-width:0;max-width:100%;width:100%}
.holding-calculated>div{min-width:0;overflow-wrap:anywhere}
.holding-group[hidden],.holding-no-match[hidden],.holding-selection[hidden]{display:none!important}
.holding-selection{display:flex;flex-wrap:wrap;align-items:center;gap:9px;margin-top:14px;padding-top:12px;border-top:1px solid #e1e8ef}
.holding-selection>span{font-weight:600;color:#345169;margin-right:auto}
.holding-select-all{display:inline-flex;align-items:center;gap:8px;min-height:36px;color:#50627a;font-size:13px;cursor:pointer}
.holding-select-all input,.holding-row-check{width:17px;height:17px;min-width:17px;margin:0;accent-color:#147b67;cursor:pointer;vertical-align:middle}
.holding-report-table{min-width:900px}
.holding-report-table td:nth-child(3){background:inherit;color:inherit}
.holding-report-table td:nth-child(4),.holding-report-table td:nth-child(5){background:#e7f4f7;color:#17687a}
.holding-report-table tr:nth-child(even) td:not(:nth-child(4)):not(:nth-child(5)){background:#f7f9fb}
.holding-report-table th:first-child,.holding-report-table td:first-child{width:42px;min-width:42px;max-width:42px;text-align:center;padding:8px}
.holding-row-buttons{display:flex;align-items:center;justify-content:flex-end;gap:6px}
.holding-delete.btn{color:#a83440;background:#fff2f2;border-color:#e9c7cb}
.holding-delete.btn:hover:not(:disabled){background:#fbe3e5;border-color:#d79ba3}
.drawer-footer{display:none}
@media screen and (max-width:900px){
 #logout{display:none!important}
 .drawer-footer{display:flex;flex:0 0 auto;padding:12px 12px max(14px,env(safe-area-inset-bottom));border-top:1px solid #ffffff1d}
 .drawer-signout{display:flex;align-items:center;gap:11px;width:100%;padding:13px 14px;min-height:48px;border:0;border-radius:8px;background:transparent;color:#eef5fc;font:inherit;font-size:14px;text-align:left;cursor:pointer}
 .drawer-signout:hover,.drawer-signout:focus-visible{background:#294964}
 .drawer-signout[hidden]{display:none}
 .holding-toolbar,.holding-editor{min-width:0;width:100%}
 .holding-controls{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:end;gap:10px}
 .holding-controls label{max-width:none;width:100%}
 .holding-form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
 .holding-form-grid label:first-child{grid-column:1/-1}
 .holding-controls input,.holding-form-grid input,.holding-form-grid select{height:46px;min-height:46px;font-size:16px!important}
 .holding-group-actions{flex-wrap:wrap;align-items:center;gap:8px}
 .holding-group-content,.holding-table-scroll{width:100%;max-width:100%;min-width:0;box-sizing:border-box}
 .holding-report-table{min-width:790px}
 .holding-row-buttons .btn{flex-shrink:0}
}
@media screen and (max-width:540px){
 .holding-calculated{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .holding-controls{grid-template-columns:minmax(0,1fr);gap:10px}
 .holding-controls .btn{justify-self:end;font-size:13px;min-height:42px}
 .holding-selection{gap:7px}
 .holding-selection>span{flex-basis:100%}
 .holding-selection .btn{min-height:40px;font-size:12px;padding:8px 10px}
 .holding-group-actions{gap:7px}
 .holding-select-all{font-size:12px}
 .holding-copy{font-size:12px}
}
@media screen and (max-width:340px){.holding-calculated{grid-template-columns:minmax(0,1fr)}}

/* V18.14: searchable customer field, bounded phone date controls and invoice renaming. */
.holding-customer-field{display:grid;gap:7px;min-width:0}
.holding-customer-picker{position:relative;min-width:0;width:100%}
.holding-customer-input{position:relative;display:flex;align-items:center;min-width:0;width:100%}
.holding-customer-input input{padding-right:42px}
.holding-customer-input button{position:absolute;right:1px;top:1px;bottom:1px;width:39px;display:grid;place-items:center;border:0;background:transparent;border-radius:7px;color:#546b82}
.holding-customer-input button:focus-visible{outline:2px solid #168673;outline-offset:-3px}
.holding-customer-input button[aria-expanded=true] .control-icon{transform:rotate(180deg)}
.holding-form-grid input[type=hidden]{display:none}
#holdingCustomerOptions{position:absolute;z-index:15;top:calc(100% + 5px);left:0;right:0;min-width:0;max-height:240px;overflow-y:auto;overscroll-behavior:contain;padding:5px;background:#fff;border:1px solid #cbd7e5;border-radius:9px;box-shadow:0 8px 22px #17364d21}
#holdingCustomerOptions[hidden],.holding-customer-option[hidden],.holding-picker-empty[hidden]{display:none!important}
.holding-customer-option{display:block;width:100%;border:0;background:#fff;text-align:left;padding:10px 11px;min-height:39px;border-radius:6px;color:#20394c;font-size:14px;line-height:1.4;overflow-wrap:anywhere}
.holding-customer-option[aria-selected=true]{font-weight:600;background:#e8f5f0;color:#127460}
.holding-customer-option.active,.holding-customer-option:hover{background:#eaf1f6}
.holding-picker-empty{padding:12px 10px;color:#65788b;font-size:13px}
.holding-date-control{position:relative;display:block;width:100%;min-width:0;max-width:100%;box-sizing:border-box}
.holding-date-display{display:none}
.holding-form-actions{justify-content:flex-end;flex-wrap:nowrap}
.file-invoice-rename-form{align-items:flex-end}
.file-invoice-rename-form label{min-width:0}
.file-rename-field{position:relative;min-width:0}
.file-rename-field input{width:100%;min-width:0;padding-right:44px;min-height:42px}
.file-rename-field>span{position:absolute;right:12px;top:50%;transform:translateY(-50%);color:#62768b;font-size:13px;pointer-events:none}
.file-rename-actions{display:flex;justify-content:flex-end;gap:8px;align-items:center}
@media screen and (max-width:900px){
 .holding-form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 10px;align-items:start}
 .holding-form-grid>.holding-customer-field,.holding-form-grid>.holding-skill-field{grid-column:1/-1}
 .holding-form-grid>.holding-date-field,.holding-form-grid>.holding-money-field{grid-column:auto;min-width:0}
 .holding-customer-input input,.holding-form-grid>.holding-money-field input,.holding-form-grid>.holding-skill-field input{height:44px;min-height:44px;min-width:0;width:100%}
 .holding-date-control{height:44px;min-height:44px;border:1px solid #cbd7e5;border-radius:8px;background:#fff;overflow:hidden;isolation:isolate}
 .holding-date-control:focus-within{border-color:#168673;box-shadow:0 0 0 3px #1686731a}
 .holding-date-display{display:flex;align-items:center;justify-content:space-between;gap:4px;position:absolute;inset:0;padding:0 8px;pointer-events:none;color:#21334a;font-size:14px;font-weight:400;white-space:nowrap;line-height:1.25;font-variant-numeric:tabular-nums}
 .holding-date-display>span{min-width:0;overflow:hidden;text-overflow:ellipsis}
 .holding-date-display svg{flex:0 0 17px;width:17px;height:17px;color:#536c83}
 .holding-date-control input[type=date]{position:absolute;inset:0;opacity:0;z-index:1;width:100%;inline-size:100%;min-width:0;min-inline-size:0;max-width:100%;height:100%;min-height:0;padding:0;margin:0;border:0;box-shadow:none;overflow:hidden;appearance:none;-webkit-appearance:none;cursor:pointer}
 .holding-date-control input[type=date]::-webkit-calendar-picker-indicator{position:absolute;inset:0;width:100%;height:100%;margin:0;padding:0;cursor:pointer}
 .holding-form-actions .btn{min-height:44px;flex:0 0 auto}
 .holding-customer-option{font-size:14px;min-height:44px}
 .file-invoice-rename-form{display:grid;grid-template-columns:minmax(0,1fr);gap:10px}
 .file-rename-actions{justify-content:flex-end}
}
@media screen and (max-width:540px){
 .holding-form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:13px 10px}
 .holding-form-grid>.holding-customer-field,.holding-form-grid>.holding-skill-field{grid-column:1/-1}
 .holding-form-grid>.holding-date-field,.holding-form-grid>.holding-money-field{grid-column:auto}
 .holding-date-display{font-size:13px;padding:0 7px;gap:3px}
 .holding-date-display svg{flex-basis:15px;width:15px;height:15px}
 .holding-form-actions{gap:8px}
 .holding-form-actions .btn{padding:10px 13px}
 .file-panel .file-table .explorer-file:has(.file-rename-invoice) .file-actions .btn.row-action-icon{flex-basis:34px;width:34px;min-width:34px;min-height:36px;height:36px}
}

@media screen and (min-width:901px){.file-table.explorer-single-list:has(.file-rename-invoice) th:last-child{width:266px}}

/* Customer payment method: simple inline editor alongside account management. */
.customer-section-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-shrink:0;max-width:100%}
.customer-section-actions .btn{white-space:nowrap}
.customer-mop-current{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:0 0 14px;font-size:13px;overflow-wrap:anywhere}
.customer-mop-current strong{color:#253e53;min-width:0}
.customer-mop-current #mopResult{color:#147b67}
.customer-mop-form{display:flex;align-items:flex-end;gap:12px;padding:14px;background:#f3f7fa;border:1px solid #dce5ec;border-radius:9px;margin:0 0 16px;min-width:0}
.customer-mop-form label{display:grid;gap:6px;flex:1 1 260px;min-width:0;max-width:460px;color:#50627a;font-size:13px;font-weight:600}
.customer-mop-form input{display:block;max-width:100%;min-width:0;width:100%;height:42px;padding:10px 12px;border:1px solid #cbd7e5;border-radius:8px;background:#fff;color:#21334a;font:inherit;font-size:14px;font-weight:400}
.customer-mop-form input:focus{border-color:#168673;outline:none;box-shadow:0 0 0 3px #1686731a}
.customer-mop-actions{display:flex;justify-content:flex-end;align-items:center;gap:8px}
@media screen and (max-width:600px){
 .customer-section-actions{flex-wrap:nowrap;gap:6px}
 .customer-section-actions .btn{padding:9px 11px;font-size:12px;min-height:44px}
 .customer-mop-form{display:grid;grid-template-columns:minmax(0,1fr);gap:10px;padding:12px}
 .customer-mop-form label{max-width:none}
 .customer-mop-form input{height:44px}
 .customer-mop-actions .btn{min-height:44px}
}

/* Compact, accessible upload guide matching the dashboard's action styling. */
.heading-title .upload-guide-trigger{display:grid;place-items:center;flex:0 0 36px;width:36px;height:36px;padding:0;border-radius:8px;color:#147967;background:#edf6f3;border:1px solid #c9e2d9}
.upload-guide-trigger:focus-visible,.guide-close:focus-visible{outline:2px solid #147b67;outline-offset:2px}
.upload-guide-dialog{width:min(720px,calc(100vw - 28px));max-width:720px;max-height:calc(100dvh - 30px);margin:auto;padding:0;border:1px solid #d5e0e9;border-radius:16px;background:#fff;color:#172c42;box-shadow:0 22px 65px #10273c42;overflow:auto;overscroll-behavior:contain}
.upload-guide-dialog::backdrop{background:rgba(17,35,52,.58);backdrop-filter:blur(2px)}
.upload-guide-header{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;padding:22px 24px 16px;border-bottom:1px solid #e5ecf1}
.upload-guide-kicker{display:block;color:#147967;font-size:11px;font-weight:800;letter-spacing:.09em;margin-bottom:5px}
.upload-guide-header h2{font-size:21px;line-height:1.25;margin:0 0 6px;overflow-wrap:anywhere}
.upload-guide-header p{margin:0;font-size:12px}
.guide-close{display:grid;place-items:center;flex:0 0 36px;width:36px;height:36px;padding:0;border-radius:9px}
.upload-guide-body{padding:18px 24px 16px}
.upload-guide-video{display:block;width:100%;max-width:100%;height:auto;aspect-ratio:16/9;border-radius:10px;background:#162b42;border:1px solid #d5e0e9;overflow:hidden}
.upload-guide-body h3{font-size:16px;margin:19px 0 10px}
.upload-guide-steps{margin:0;padding:0 0 0 22px;display:grid;gap:10px;font-size:14px;line-height:1.55}
.upload-guide-steps li::marker{font-weight:700;color:#147967}
.upload-guide-note{margin:14px 0 0;padding:10px 12px;border-radius:7px;background:#edf6f3;line-height:1.5}
.upload-guide-footer{display:flex;justify-content:flex-end;padding:14px 24px;border-top:1px solid #e5ecf1;background:#f7fafc}
@media screen and (max-width:600px){
 .heading-title .upload-guide-trigger{flex-basis:42px;width:42px;height:42px}
 .upload-guide-dialog{width:calc(100vw - 20px);max-height:calc(100dvh - 20px)}
 .upload-guide-header{padding:16px 15px 13px;gap:8px}.upload-guide-header h2{font-size:18px}
 .guide-close{height:44px;width:44px;flex-basis:44px}
 .upload-guide-body{padding:14px 15px}.upload-guide-steps{gap:9px;font-size:14px}
 .upload-guide-footer{padding:12px 15px}.upload-guide-footer .btn{min-height:44px}
}
@media print{.upload-guide-dialog,.upload-guide-trigger{display:none!important}}
