#app[data-view=customers] .page-title,#app[data-view=customers] main>footer {display:none}
#app[data-view=customers] .summary-width {max-width:1300px}
.legacy-customer-search {font-family:'Segoe UI',Tahoma,sans-serif;--primary:#1a73e8;--text-light:#6b7280;--border:#e5e7eb}
.legacy-customer-search .card {padding:0;border-radius:12px;background:white;box-shadow:0 1px 3px #0000000a;border:1px solid #e5e7eb}
.legacy-customer-search .card-header {padding:16px 20px;border-bottom:1px solid #e5e7eb}
.legacy-customer-search h3 {font-size:1rem;color:#1f2937}
.legacy-customer-search .card-body {padding:20px}
.legacy-customer-search .filter-group {display:flex;flex-direction:column;gap:4px}
.legacy-customer-search label {font-size:.8rem;font-weight:600;color:#6b7280;display:block}
#toolbar .legacy-customer-search input,#toolbar .legacy-customer-search select {max-width:none;width:100%;border:1px solid #e5e7eb;border-radius:8px;line-height:normal}
.legacy-customer-results {font-family:'Segoe UI',Tahoma,sans-serif}
.customer-result-count {margin-bottom:16px;color:#6b7280;font-size:.9rem}
.customer-fallback {background:#fef3e2;color:#b45309;padding:2px 8px;border-radius:12px;font-size:.75rem;margin-left:6px}
.customer-result-card {background:white;border-radius:12px;padding:20px;border:1px solid #e5e7eb}
.customer-result-card th {font-size:.8rem;background:#f8f9fa;font-weight:600}
.customer-result-card td {font-size:.85rem;padding:10px 12px}
.customer-result-card .edit-record {background:#f59e0b;color:white;border:0}
.customer-result-card .success {background:#0d904f;color:white;border:0}
.customer-result-card td:last-child {white-space:nowrap;text-align:center}
.customer-detail-link {padding:0;border:0;background:none;text-align:left;color:inherit;font:inherit}
.legacy-customer-empty {padding:40px;text-align:center;background:white;border-radius:12px;color:#b45309}
.customer-result-card tr:has(.customer-expired) {opacity:.7}
.customer-result-card .table-card {border:0;border-radius:0}
.customer-exports {margin-top:14px;color:#6b7280;font-size:12px}
.customer-exports button {margin-top:8px;font-size:12px}
.legacy-customer-search .fa-search::before {content:'⌕';color:#1a73e8;font-style:normal}
.legacy-customer-search button .fa-search::before {color:white}
.legacy-customer-search .fa-times-circle::before {content:'⊗';font-style:normal}
.customer-search-panel{padding:22px;background:#fff;border:1px solid #e5e7eb;border-radius:14px;margin-bottom:18px}
.customer-search-panel h2{font-size:20px;margin-bottom:4px}.customer-search-line{display:flex;align-items:flex-end;gap:10px;margin:18px 0}.customer-query{flex:1}
.customer-filter-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.customer-search-panel label{font-size:11px;color:#64748b}
.customer-result-card{padding:0;overflow:hidden}.customer-result-card td{max-width:260px;white-space:normal;overflow-wrap:anywhere}.customer-result-card td:first-child{min-width:190px}
.cs-secondary{display:block;font-size:11px;color:#758197;margin-top:4px}.cs-actions{display:flex;gap:5px;flex-wrap:wrap;min-width:150px}.customer-detail-link{color:#1769c2;font-weight:600}
.customer-result-card mark{background:#fff1b3;color:inherit;border-radius:3px;padding:1px 0}.customer-search-empty{padding:50px 20px;text-align:center;color:#64748b;background:#fff;border:1px dashed #dce3ec;border-radius:12px}.customer-search-empty h3{margin-bottom:8px}
#modal.record-modal.customer-drawer{position:fixed;inset:0 0 0 auto;margin:0;width:min(680px,96vw);height:100dvh;max-height:100dvh;border-radius:16px 0 0 16px;animation:customer-drawer-in 220ms ease-out}
#modal.customer-drawer .detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}#modal.customer-drawer .detail-actions{gap:6px}#modal.customer-drawer .detail-actions button{font-size:12px}
@keyframes customer-drawer-in{from{transform:translateX(100%)}to{transform:translateX(0)}}
@media(max-width:1000px){.customer-filter-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:520px){.customer-search-panel{padding:14px}.customer-search-line{flex-wrap:wrap}.customer-query{flex-basis:100%}#modal.customer-drawer .detail-grid{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){#modal.record-modal.customer-drawer{animation:none}}

/* Keep long customer names and policy numbers inside their own columns. */
.customer-result-card table{min-width:1100px;table-layout:auto}
.customer-result-card td:nth-child(2),.customer-result-card td:nth-child(3){min-width:150px}
.customer-result-card td:nth-child(4),.customer-result-card td:nth-child(5){min-width:120px}
.customer-result-card td:nth-child(6){min-width:140px}
.customer-detail-link{max-width:100%;white-space:normal;overflow-wrap:anywhere;line-height:1.6}
.customer-result-card .num,.customer-result-card .badge{white-space:nowrap}

/* Search controls share the expiry filter's spacing and interaction states. */
.customer-search-panel{padding:0;overflow:hidden;box-shadow:0 2px 4px #16253b04}
.customer-search-heading{display:flex;align-items:center;gap:12px;padding:22px 24px 0}
.customer-search-heading h2{font-size:18px;color:#23354e}.customer-search-heading p{font-size:12px;margin-top:3px}
.customer-search-icon{display:grid;place-items:center;flex:none;width:42px;height:42px;border-radius:12px;background:#eaf2ff;color:#1976ed;font-size:26px}
.customer-search-line{padding:0 24px;margin:20px 0 22px;gap:10px}.customer-search-line>button{min-height:44px;white-space:nowrap;padding:10px 18px;font-size:13px}
.customer-search-panel label{gap:8px;font-size:12px;font-weight:600;color:#52627a;min-width:0}
#toolbar .customer-search-panel input,#toolbar .customer-search-panel select{height:44px;min-width:0;border:1px solid #cbd5e1;border-radius:10px;background:#f8fafc;padding:10px 12px;color:#263b55;font-size:13px;font-weight:400;transition:border-color .15s,box-shadow .15s}
#toolbar .customer-search-panel input:hover,#toolbar .customer-search-panel select:hover{border-color:#94a3b8}
#toolbar .customer-search-panel input:focus,#toolbar .customer-search-panel select:focus{outline:none;border-color:#1976ed;background:#fff;box-shadow:0 0 0 3px #1976ed20}
#toolbar .customer-query input{background:#fff;font-size:15px;height:48px;padding:12px 14px}
.customer-filter-section{border-top:1px solid #e9eef5;padding:18px 24px 20px}.customer-filter-section h3{font-size:12px;color:#52627a;margin-bottom:14px}
.customer-date-section{background:#fafbfd}.customer-date-hint{font-size:11px;color:#8994a5;margin-top:12px}
.customer-result-count{background:#eaf2ff;border:1px solid #dce9fc;border-radius:10px;padding:12px 16px;font-size:13px;color:#52627a}.customer-result-count strong{color:#1262cc}
#toolbar .customer-search-panel select{cursor:pointer}
#toolbar .customer-search-panel option{padding:12px 14px;color:#334155;background:#fff;font-size:13px;line-height:1.6}
@supports (appearance:base-select){
 #toolbar .customer-search-panel select,#toolbar .customer-search-panel select::picker(select){appearance:base-select}
 #toolbar .customer-search-panel select{display:flex;align-items:center;justify-content:space-between;gap:10px}
 #toolbar .customer-search-panel select::picker-icon{color:#64748b;flex:none;transition:transform .15s}
 #toolbar .customer-search-panel select:open::picker-icon{transform:rotate(180deg)}
 #toolbar .customer-search-panel select::picker(select){margin-top:7px;padding:6px;border:1px solid #dce4ee;border-radius:12px;background:#fff;box-shadow:0 10px 28px #19355224;min-width:anchor-size(width);max-height:300px;overflow:auto}
 #toolbar .customer-search-panel option{display:flex;align-items:center;gap:12px;min-height:44px;border-radius:7px;cursor:pointer;white-space:normal}
 #toolbar .customer-search-panel option:hover,#toolbar .customer-search-panel option:focus{background:#f1f5fb;outline:none}
 #toolbar .customer-search-panel option:checked{background:#eaf2ff;color:#1262cc;font-weight:600}
 #toolbar .customer-search-panel option::checkmark{color:#1976ed;margin-inline-start:auto;order:1}
}
@media(max-width:720px){.customer-search-heading{padding:18px 16px 0}.customer-search-line{padding:0 16px;flex-wrap:wrap}.customer-query{flex-basis:100%}.customer-filter-section{padding:16px}.customer-search-heading h2{font-size:17px}}
@media(max-width:520px){.customer-search-panel{padding:0}.customer-filter-grid{grid-template-columns:1fr}.customer-search-line>button{flex:1}.customer-search-heading{align-items:flex-start}}

/* Keep the everyday search compact; secondary controls are opt-in. */
.customer-search-heading{padding:16px 20px 0;gap:10px}.customer-search-heading h2{font-size:16px}.customer-search-heading p{display:none}
.customer-search-icon{width:32px;height:32px;border-radius:9px;font-size:23px}
.customer-search-line{padding:0 20px;margin:12px 0 16px;gap:8px}
#toolbar .customer-query input{height:42px;font-size:14px;padding:9px 12px}.customer-search-line>button{min-height:42px;padding:8px 14px}
.customer-advanced-filters{border-top:1px solid #e9eef5}
.customer-advanced-filters>summary{cursor:pointer;padding:11px 20px;font-size:12px;font-weight:600;color:#52627a;background:#fafbfd}
.customer-advanced-filters>summary:hover{background:#f0f5fc}.customer-advanced-filters>summary:focus-visible{outline:2px solid #1976ed;outline-offset:-3px}
.customer-filter-summary-hint{margin-left:12px;color:#8994a5;font-size:11px;font-weight:400}
.customer-filter-count{display:inline-block;margin-left:8px;border-radius:12px;padding:1px 8px;background:#eaf2ff;color:#1262cc;font-size:11px}
.customer-advanced-filters .customer-filter-section{padding:14px 20px}.customer-advanced-filters .customer-filter-section h3{margin-bottom:10px}
@media(max-width:520px){.customer-search-line{padding:0 16px}.customer-search-heading{padding:14px 16px 0}.customer-filter-summary-hint{display:none}.customer-advanced-filters>summary{padding:11px 16px}}

.customer-result-card .cs-actions{display:grid;gap:6px;width:108px;min-width:108px;text-align:left}
.customer-result-card .cs-actions button{margin:0;min-height:34px;padding:6px 9px;font-size:11px;border-radius:7px;line-height:1.5;white-space:nowrap;transition:background .15s,border-color .15s}
.customer-result-card .cs-action-main{display:flex;align-items:center;gap:7px;width:100%;background:#edf4ff;border:1px solid #cedff7;color:#1764bf;font-weight:600}
.cs-action-chevron{margin-left:auto;font-size:17px;line-height:1}
.cs-actions-secondary{display:grid;grid-template-columns:1fr 1fr;gap:6px}
.customer-result-card .cs-actions-secondary button{display:flex;justify-content:center;align-items:center;gap:5px;background:#fff;color:#52627a;border:1px solid #dce3ed}
.customer-result-card .cs-actions-secondary .cs-action-renew{color:#14805a;border-color:#cde6dc;background:#f6fcf9}
.customer-result-card .cs-actions button:hover{filter:none;background:#e6effc;border-color:#8bb4ec}
.customer-result-card .cs-actions button:focus-visible{outline:2px solid #1976ed;outline-offset:2px}

.customer-result-card .cs-actions-secondary button{min-height:28px;padding:3px 8px;font-size:15px}
.customer-result-card .cs-action-main{padding:5px 7px;gap:4px;font-size:10px;min-height:30px}
