:root{--action-blue:#2187fa;--action-green:#198754;--action-red:#dc3545}
button{border-radius:6px!important;font-family:Arial,sans-serif!important;font-size:13px!important;font-weight:600!important;box-shadow:none!important;cursor:pointer}
button:where(:not(.nav button):not(.settings-nav button):not(.report-sidebar button):not(.tab):not(.tabs button):not(.company-switch-btn)){min-height:38px;border:1px solid var(--action-blue)!important;background:var(--action-blue)!important;color:#fff!important;padding:8px 16px!important}
button:hover{filter:brightness(.94)}button:focus-visible{outline:2px solid #19324a;outline-offset:3px}button:disabled{opacity:.45;cursor:not-allowed;filter:none}
button.action-in,.invoice-editor button.action-in{background:var(--action-green)!important;border-color:var(--action-green)!important;color:#fff!important}
button.action-out,.invoice-editor button.action-out{background:var(--action-red)!important;border-color:var(--action-red)!important;color:#fff!important}
button.close,.invoice-editor button.close,button.iconbutton,.sale-line button{min-width:32px!important;width:32px!important;height:32px!important;min-height:32px!important;padding:0!important;display:inline-flex;align-items:center;justify-content:center}
.nav button,.settings-nav button,.report-sidebar button{min-height:38px}.nav button.active,.settings-nav button.active,.report-sidebar button.active{background:#eaf2fa!important;color:#18588f!important}
.access-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.access-heading p{font-size:12px;color:#778796}.access-banner{padding:12px 16px;background:#edf4ff;border:1px solid #cbdcf0;border-radius:6px;color:#335676;font-size:12px;margin:16px 0;line-height:1.6}.access-counts{display:flex;gap:14px;margin:18px 0}.access-counts>div{background:#f5f8fb;border:1px solid #e2e8ef;padding:12px 20px;border-radius:6px}.access-counts b{font-size:22px;display:block}.access-counts span{font-size:11px;color:#627488}.access-tag{display:inline-block;padding:4px 8px;border-radius:4px;background:#eaf2fa;color:#18588f;margin:2px;font-size:11px}.access-state{color:#198754;font-size:11px;font-weight:700}.access-state.inactive{color:#dc3545}.access-modal{max-width:760px!important;width:calc(100% - 30px)!important}.access-modal .form{max-height:75vh;overflow:auto}.access-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.access-grid label>span{display:block;font-size:11px;color:#627488;margin:0 0 6px}.access-grid input,.access-grid select{width:100%;padding:10px;border:1px solid #ccd3db;border-radius:6px}.access-matrix{width:100%;margin:16px 0;border-collapse:collapse}.access-matrix th,.access-matrix td{padding:9px 12px;border-bottom:1px solid #e2e8ef;text-align:left;font-size:12px}.access-matrix th:not(:first-child),.access-matrix td:not(:first-child){text-align:center;width:90px}.access-matrix input{accent-color:#2187fa;width:16px;height:16px}.access-error{color:#b42318;font-size:12px;min-height:18px;white-space:pre-wrap}.access-login{max-width:600px;margin:50px auto;padding:28px}.access-login h1{font-size:24px}.access-login input{width:100%}.access-account{font-size:11px;margin:10px 0;color:#627488}.access-readonly{display:inline-block;margin-left:8px;background:#fff3cd;color:#795900;padding:4px 8px;border-radius:4px;font-size:11px}.access-legend{display:flex;gap:14px;font-size:11px;color:#627488;margin-top:12px}.access-legend i{display:inline-block;width:8px;height:8px;border-radius:50%;margin-right:5px}.access-modal .modal-foot{display:flex;justify-content:space-between;gap:12px}.access-presets{display:flex;flex-wrap:wrap;gap:8px;margin-top:16px}@media(max-width:650px){.access-grid{grid-template-columns:1fr}.access-heading{flex-wrap:wrap}.access-counts{flex-wrap:wrap}.access-matrix td,.access-matrix th{padding:8px 4px}}
/* Override the older app's successive button themes with one shared style. */
#view button,#modalroot button,.topbar button{border-radius:6px!important;font:600 13px Arial,sans-serif!important;box-shadow:none!important;transform:none!important;min-height:38px!important;padding:8px 16px!important;border:1px solid var(--action-blue)!important;background:var(--action-blue)!important;color:#fff!important}
#view .settings-nav button,#view .report-sidebar button,#view .tabs button{background:#f5f8fb!important;color:#335676!important;border-color:#e2e8ef!important}
#view .settings-nav button.active,#view .report-sidebar button.active,#view .tabs button.active{background:#eaf2fa!important;color:#18588f!important;border-color:#bcd4ed!important}
#view button.action-in,#modalroot button.action-in{background:var(--action-green)!important;border-color:var(--action-green)!important}
#view button.action-out,#modalroot button.action-out{background:var(--action-red)!important;border-color:var(--action-red)!important}
#view button.close,#modalroot button.close,.topbar button.iconbutton,#view .sale-line button.line-remove{width:32px!important;min-width:32px!important;height:32px!important;min-height:32px!important;padding:0!important}
.access-modal .modal-foot{position:sticky;bottom:0;background:white;padding:12px 0;margin-top:10px;border-top:1px solid #e2e8ef;z-index:2}
.bulk-stock-editor .sale-form{display:flex;flex-direction:column;min-height:calc(100vh - 80px)}.bulk-stock-editor h2{margin:0 0 5px}.bulk-stock-fields{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px;margin-bottom:30px}.bulk-stock-fields .field span{font-size:11px;color:#627488;margin-bottom:6px}.bulk-stock-fields input,.bulk-stock-fields select{width:100%;height:42px;padding:9px;border:1px solid #ccd3db;border-radius:6px}.bulk-stock-table{overflow-x:auto}.bulk-stock-table table{width:100%;border-collapse:collapse}.bulk-stock-table th{background:#edf4ff;color:#335676}.bulk-stock-table td,.bulk-stock-table th{padding:12px;border:1px solid #e2e8ef;text-align:left}.bulk-stock-table th:first-child{width:45px}.bulk-stock-table select{width:100%;min-width:220px;border:1px solid #ccd3db;border-radius:6px;padding:10px}.bulk-stock-table input{width:130px;padding:10px;border:1px solid #ccd3db;border-radius:6px}.bulk-stock-add{display:flex;align-items:center;gap:20px;margin:15px 0;color:#778796;font-size:12px}.bulk-stock-editor .sale-actions{margin-top:auto;display:flex;justify-content:space-between;background:white;padding:16px 0;border-top:1px solid #e2e8ef;position:sticky;bottom:0}.bulk-stock-editor #bulk-stock-error{margin:10px 0}.bulk-stock-editor .modal-head{z-index:10}@media(max-width:700px){.bulk-stock-fields{grid-template-columns:1fr 1fr}.bulk-stock-editor .sale-form{padding:16px}}

/* Product suggestions must not inherit the compact remove-button size. */
#view .line-results,#modalroot .line-results{position:absolute;left:0;right:0;top:100%;z-index:80;background:#fff;border:1px solid #dce5ec;border-radius:8px;max-height:300px;overflow:auto;box-shadow:0 8px 24px #19324a20}
#view .line-results .line-result,#modalroot .line-results .line-result{display:flex!important;align-items:center;justify-content:space-between;gap:16px;width:100%!important;min-width:0!important;height:auto!important;min-height:68px!important;padding:12px 14px!important;text-align:left;background:#fff!important;color:#19324a!important;border:0!important;border-bottom:1px solid #e7edf2!important;border-radius:0!important;white-space:normal!important}
#view .line-result>span:first-child,#modalroot .line-result>span:first-child{display:flex;flex-direction:column;gap:5px;min-width:0}
.line-result-name{display:block;font-weight:700;line-height:1.4;overflow-wrap:anywhere}.line-result-meta{display:block;font-size:11px;line-height:1.5;color:#758796}.line-result-price{display:block;flex-shrink:0;text-align:right;font-weight:700;line-height:1.5}.line-result-price small{display:block;font-size:10px;font-weight:400}.line-results-empty{padding:14px;color:#758796}
#view .line-results .line-result:hover,#view .line-results .line-result:focus,#modalroot .line-results .line-result:hover{background:#edf5ff!important}
