/* Ayllu ERP design system */
:root{--ink:#1f2937;--muted:#6b7280;--line:#e2e8f0;--surface:#fff;--canvas:#f5f7fa;--brand:#1772e4;--brand-hover:#125db8;--brand-light:#eaf3ff;--success:#16a34a;--warning:#d97706;--danger:#dc2626;--radius:10px;--shadow:0 1px 2px rgba(15,23,42,.04),0 5px 18px rgba(15,23,42,.035)}
*{box-sizing:border-box}html{font-size:15px}body{margin:0;background:var(--canvas);color:var(--ink);font-family:Inter,"Segoe UI",Roboto,system-ui,sans-serif;-webkit-font-smoothing:antialiased}h1{font-size:1.75rem;font-weight:720;letter-spacing:-.035em}h2{font-size:1.1rem;font-weight:700}.app-shell{min-height:100vh;display:flex}.sidebar{position:sticky;top:0;width:256px;height:100vh;flex:0 0 256px;padding:20px 14px;background:#111827;color:#e5e7eb;display:flex;flex-direction:column;transition:width 180ms ease,flex-basis 180ms ease}.brand{color:#fff;text-decoration:none;display:flex;align-items:center;gap:11px;font-weight:700;flex:1}.brand:hover{color:#fff}.brand-mark{display:grid;place-items:center;width:34px;height:34px;flex:0 0 34px;border-radius:9px;background:var(--brand);box-shadow:0 5px 18px rgba(23,114,228,.25)}.brand-copy{display:flex;flex-direction:column;line-height:1.1;white-space:nowrap}.brand-copy small{color:#9ca3af;font-size:.68rem;margin-top:4px}.sidebar-toggle{position:absolute;right:10px;top:18px;width:36px;height:36px;border:0;border-radius:8px;background:transparent;color:#9ca3af}.sidebar-toggle:hover{background:#1f2937;color:#fff}.menu-filter{display:flex;align-items:center;gap:.55rem;margin:1.25rem 0 .75rem;padding:.58rem .7rem;color:#9ca3af;background:#1f2937;border:1px solid #374151;border-radius:8px}.menu-filter:focus-within{border-color:#60a5fa;box-shadow:0 0 0 3px rgba(23,114,228,.18)}.menu-filter input{min-width:0;width:100%;border:0;outline:0;color:#fff;background:transparent;font-size:.84rem}.menu-filter input::placeholder{color:#8b95a5}.menu-container{max-height:calc(100vh - 150px);overflow-y:auto;scrollbar-width:thin}.side-link{position:relative;color:#cbd5e1;border-radius:8px;padding:.68rem .72rem;display:flex;align-items:center;gap:.78rem;font-size:.88rem;white-space:nowrap}.side-link i{width:20px;text-align:center}.side-link:hover,.side-link:focus-visible{color:#fff;background:#1f2937}.side-link.active{color:#fff;background:rgba(23,114,228,.21)}.side-link.active:before{content:"";position:absolute;left:-14px;width:3px;height:22px;background:#60a5fa;border-radius:0 3px 3px 0}.main-shell{min-width:0;flex:1}.topbar{position:sticky;top:0;height:68px;background:rgba(255,255,255,.95);backdrop-filter:blur(10px);border-bottom:1px solid var(--line);padding:0 30px;display:flex;align-items:center;gap:14px;z-index:20}.topbar-spacer{flex:1}.global-search{width:min(500px,46vw);display:flex;align-items:center;gap:10px;border:1px solid var(--line);border-radius:9px;padding:8px 11px;background:#f9fafb;color:var(--muted)}.global-search:focus-within{background:#fff;border-color:#79aef0;box-shadow:0 0 0 3px rgba(23,114,228,.12)}.global-search input{border:0;outline:0;background:transparent;width:100%;font-size:.86rem}.global-search kbd{border:1px solid var(--line);border-bottom-width:2px;border-radius:5px;background:#fff;color:var(--muted);font-size:.68rem;padding:4px 6px}.company-chip{align-items:center;gap:7px;padding:7px 10px;border:1px solid var(--line);border-radius:8px;color:var(--muted);font-size:.74rem;background:#fff}.company-chip strong{color:var(--ink)}.icon-button{width:38px;height:38px;display:grid;place-items:center;border:1px solid var(--line);border-radius:9px;background:#fff;color:#667085}.notification-button{position:relative}.notification-dot{position:absolute;top:8px;right:8px;width:6px;height:6px;border-radius:50%;background:var(--danger);border:1px solid #fff}.user-button{border:0;border-radius:9px;padding:4px 6px;background:transparent;display:flex;align-items:center;gap:9px}.user-button:hover{background:#f9fafb}.user-button strong,.user-button small{display:block;font-size:.78rem}.user-button small{color:var(--muted)}.avatar{width:34px;height:34px;display:grid;place-items:center;border-radius:9px;background:var(--brand-light);color:var(--brand);font-size:.72rem;font-weight:800}.content-area{padding:30px 32px 48px;max-width:1600px}.eyebrow{color:var(--brand);font-size:.68rem;font-weight:750;letter-spacing:.11em;margin:0 0 7px}.btn{min-height:40px;border-radius:8px;font-weight:600;font-size:.86rem;padding:.52rem .9rem;transition:all 180ms ease}.btn-sm{min-height:34px;padding:.35rem .65rem}.btn-primary{background:var(--brand);border-color:var(--brand)}.btn-primary:hover,.btn-primary:focus{background:var(--brand-hover);border-color:var(--brand-hover)}.btn-outline-primary{color:var(--brand);border-color:#a9cbee}.btn-outline-primary:hover{background:var(--brand-light);border-color:#79aef0;color:var(--brand-hover)}.form-label{margin-bottom:6px;color:#374151;font-size:.78rem;font-weight:650}.form-control,.form-select{min-height:42px;border-color:#cfd8e5;border-radius:8px;color:var(--ink);font-size:.88rem}.form-control:focus,.form-select:focus,.form-check-input:focus,.btn:focus-visible{border-color:#61a0ed;box-shadow:0 0 0 3px rgba(23,114,228,.18)!important}.form-check-input:checked{background-color:var(--brand);border-color:var(--brand)}.metric-card,.table-card,.form-card,.empty-state{background:#fff;border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}.metric-card{min-height:156px;padding:19px;display:flex;flex-direction:column;gap:8px;transition:transform 180ms ease}.metric-card:hover{transform:translateY(-2px)}.metric-card small,.metric-card span:last-child{color:var(--muted)}.metric-card strong{font-size:1.8rem;letter-spacing:-.04em}.metric-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:9px}.blue{color:var(--brand);background:var(--brand-light)}.green{color:var(--success);background:#ecfdf3}.violet{color:#7c3aed;background:#f3e8ff}.orange{color:var(--warning);background:#fff7ed}.empty-state{padding:44px 24px;text-align:center}.empty-state>i{display:grid;place-items:center;width:48px;height:48px;margin:0 auto 14px;border-radius:12px;color:var(--brand);background:var(--brand-light);font-size:1.35rem}.empty-state p{max-width:600px;margin:0 auto;color:var(--muted)}.table-card{overflow:hidden}.table-card .table{--bs-table-bg:transparent;margin:0}.table-card thead{position:sticky;top:0;z-index:2}.table-card th{background:#f8fafc;color:#64748b;font-size:.7rem;text-transform:uppercase;letter-spacing:.055em;white-space:nowrap}.table-card td,.table-card th{padding:13px 16px;vertical-align:middle;border-color:#edf1f5}.table-card tbody tr:nth-child(even){background:#fbfcfd}.table-card tbody tr:hover{background:#f1f7fe}.table-card code{padding:3px 6px;border-radius:5px;background:#f1f5f9;color:#334155}.form-card{padding:24px;overflow:visible}.badge{padding:.4em .62em;border-radius:6px}.text-bg-success{background:#dcfce7!important;color:#166534!important}.text-bg-warning{background:#ffedd5!important;color:#9a3412!important}.text-bg-danger{background:#fee2e2!important;color:#991b1b!important}.text-bg-primary{background:var(--brand-light)!important;color:var(--brand-hover)!important}.alert{border-radius:9px}.breadcrumb a{color:var(--brand);text-decoration:none}.login-card{max-width:440px;margin:5vh auto;background:#fff;border:1px solid var(--line);border-radius:14px;padding:32px;box-shadow:0 18px 48px rgba(15,23,42,.08)}.dashboard-panel{height:100%;padding:20px;background:#fff;border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}.panel-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px}.panel-title h2{margin:0}.quick-actions{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}.quick-action{padding:14px;border:1px solid var(--line);border-radius:9px;color:var(--ink);text-decoration:none;display:flex;align-items:center;gap:10px;font-size:.82rem;font-weight:650}.quick-action i{color:var(--brand)}.quick-action:hover{border-color:#a9cbee;background:var(--brand-light);color:var(--brand-hover)}.activity-item{display:flex;gap:12px;padding:12px 0;border-bottom:1px solid #eef2f6}.activity-item:last-child{border:0}.activity-item i{color:var(--brand)}.activity-item strong,.activity-item small{display:block}.activity-item small{color:var(--muted);margin-top:3px}.progress-thin{height:6px}.permission-option:has(input:checked){border-color:#79aef0;background:var(--brand-light)}.side-link[hidden]{display:none!important}
body.sidebar-collapsed .sidebar{width:76px;flex-basis:76px}body.sidebar-collapsed .brand-copy,body.sidebar-collapsed .menu-filter input,body.sidebar-collapsed .side-link span{display:none}body.sidebar-collapsed .menu-filter,body.sidebar-collapsed .side-link{justify-content:center}body.sidebar-collapsed .sidebar-toggle{display:none}
@media(max-width:991px){.sidebar{display:none}.topbar{padding:0 16px}.content-area{padding:24px 18px 40px}.global-search{width:auto;flex:1}.global-search kbd{display:none}}
@media(max-width:767px){html{font-size:14px}.content-area{padding:20px 14px 32px}.notification-button{display:grid}.form-card{padding:18px}.quick-actions{grid-template-columns:1fr}.login-card{margin:2vh auto;padding:24px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{transition-duration:.01ms!important}}

.skip-link{position:fixed;left:-10000px;top:12px;z-index:9999;padding:10px 14px;border-radius:8px;background:#fff;color:var(--brand);box-shadow:0 8px 24px rgba(15,23,42,.16);font-weight:600}.skip-link:focus{left:12px}

/* Organized sidebar navigation */
.sidebar{width:272px;flex-basis:272px;padding:18px 14px 14px;overflow:visible}.sidebar-header{height:44px;display:flex;align-items:center;padding:0 6px}.brand-mark{width:36px;height:36px;flex-basis:36px;border-radius:10px}.brand-copy strong{font-size:1rem;letter-spacing:-.01em}.sidebar-toggle{display:grid!important;place-items:center;right:-12px;top:76px;width:25px;height:25px;border:1px solid #d5dce6;border-radius:50%;background:#fff;color:#64748b;box-shadow:0 3px 10px rgba(15,23,42,.13);z-index:40}.sidebar-toggle:hover{background:var(--brand);border-color:var(--brand);color:#fff}.menu-filter{margin:18px 2px 14px;min-height:40px}.menu-container{max-height:none;flex:1;margin:0 -4px;padding:0 4px 12px;overflow-y:auto}.sidebar-nav{display:flex;flex-direction:column;gap:13px}.menu-section{margin:0}.menu-section-label{margin:0 0 5px;padding:0 10px;color:#6f7b8f;font-size:.65rem;font-weight:750;line-height:1.6;letter-spacing:.11em;text-transform:uppercase}.side-link{min-height:40px;padding:.58rem .72rem;border:1px solid transparent}.side-link.active{background:rgba(23,114,228,.18);box-shadow:inset 0 0 0 1px rgba(96,165,250,.1)}.side-link.active:before{left:-10px}.sidebar-footer{display:flex;align-items:center;gap:10px;min-height:55px;margin-top:4px;padding:12px 10px 0;border-top:1px solid #273244}.sidebar-footer-copy{display:flex;min-width:0;flex-direction:column;line-height:1.2}.sidebar-footer-copy strong{color:#d1d5db;font-size:.72rem;font-weight:650}.sidebar-footer-copy small{margin-top:4px;color:#7f8a9b;font-size:.66rem}.status-dot{width:8px;height:8px;flex:0 0 8px;border-radius:50%;background:#22c55e;box-shadow:0 0 0 3px rgba(34,197,94,.12)}
.menu-container,.mobile-navigation .offcanvas-body{scrollbar-width:thin;scrollbar-color:#3b4b63 transparent;overscroll-behavior:contain}.menu-container{scrollbar-gutter:stable}.menu-container::-webkit-scrollbar,.mobile-navigation .offcanvas-body::-webkit-scrollbar{width:8px}.menu-container::-webkit-scrollbar-track,.mobile-navigation .offcanvas-body::-webkit-scrollbar-track{border-radius:999px;background:rgba(255,255,255,.025)}.menu-container::-webkit-scrollbar-thumb,.mobile-navigation .offcanvas-body::-webkit-scrollbar-thumb{min-height:48px;border:2px solid #111827;border-radius:999px;background:#3b4b63}.menu-container::-webkit-scrollbar-thumb:hover,.mobile-navigation .offcanvas-body::-webkit-scrollbar-thumb:hover{background:#58708f}.menu-container::-webkit-scrollbar-thumb:active,.mobile-navigation .offcanvas-body::-webkit-scrollbar-thumb:active{background:var(--brand)}.menu-container::-webkit-scrollbar-corner,.mobile-navigation .offcanvas-body::-webkit-scrollbar-corner{background:transparent}body.sidebar-collapsed .menu-container::-webkit-scrollbar{width:6px}body.sidebar-collapsed .menu-container::-webkit-scrollbar-thumb{border-width:1px}
body.sidebar-collapsed .sidebar{width:80px;flex-basis:80px;padding-left:12px;padding-right:12px}body.sidebar-collapsed .sidebar-header{justify-content:center;padding:0}body.sidebar-collapsed .brand{justify-content:center}body.sidebar-collapsed .brand-copy,body.sidebar-collapsed .menu-filter input,body.sidebar-collapsed .side-link span,body.sidebar-collapsed .menu-section-label,body.sidebar-collapsed .sidebar-footer-copy{display:none}body.sidebar-collapsed .menu-filter{justify-content:center;margin-left:4px;margin-right:4px;padding:9px}body.sidebar-collapsed .sidebar-nav{gap:8px}body.sidebar-collapsed .menu-section{padding-top:8px;border-top:1px solid #273244}body.sidebar-collapsed .menu-section:first-child{padding-top:0;border-top:0}body.sidebar-collapsed .side-link{justify-content:center;padding:.58rem}body.sidebar-collapsed .side-link.active:before{left:-12px}body.sidebar-collapsed .sidebar-footer{justify-content:center}
.mobile-navigation{width:min(320px,88vw);background:#111827;color:#fff}.mobile-navigation .offcanvas-header{padding:18px;border-bottom:1px solid #273244}.mobile-navigation .offcanvas-header h5{display:flex;align-items:center;gap:11px;margin:0;font-size:1rem}.mobile-navigation .offcanvas-header h5>span:last-child{display:flex;flex-direction:column}.mobile-navigation .offcanvas-header small{margin-top:3px;color:#9ca3af;font-size:.66rem;font-weight:400}.mobile-navigation .btn-close{filter:invert(1);opacity:.8}.mobile-navigation .offcanvas-body{padding:14px}.mobile-menu{display:flex;flex-direction:column;gap:14px}.mobile-menu .side-link.active:before{left:-14px}.menu-filter-mobile{margin:0 0 18px;background:#1f2937;border-color:#374151}.menu-filter-mobile input{color:#fff}
@media(max-width:991px){.sidebar{display:none}.mobile-navigation .menu-section-label{display:block}.mobile-navigation .side-link span{display:inline}}

/* Refined sidebar collapse control */
.sidebar-toggle{right:14px;top:20px;width:32px;height:32px;border:1px solid #374151;border-radius:8px;background:#1b2535;color:#aeb7c5;box-shadow:none;transition:background-color 180ms ease,border-color 180ms ease,color 180ms ease,transform 180ms ease}.sidebar-toggle:hover,.sidebar-toggle:focus-visible{background:var(--brand);border-color:var(--brand);color:#fff;transform:translateX(-1px);outline:0}.sidebar-toggle i{font-size:.78rem;line-height:1}
body.sidebar-collapsed .sidebar-toggle{display:grid!important;right:-13px;top:76px;width:27px;height:27px;border-color:#d5dce6;border-radius:50%;background:#fff;color:#64748b;box-shadow:0 3px 12px rgba(15,23,42,.16)}body.sidebar-collapsed .sidebar-toggle:hover,body.sidebar-collapsed .sidebar-toggle:focus-visible{background:var(--brand);border-color:var(--brand);color:#fff;transform:translateX(1px)}body.sidebar-collapsed 


/* Customers workspace */
.customer-page-header{display:flex;flex-wrap:wrap;align-items:flex-end;justify-content:space-between;gap:24px;margin-bottom:24px}.page-icon{display:grid;place-items:center;width:46px;height:46px;flex:0 0 46px;border:1px solid #cfe1f8;border-radius:12px;background:var(--brand-light);color:var(--brand);font-size:1.25rem}.customer-primary-actions{display:flex;align-items:center;gap:10px}.customer-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:14px;padding:16px;background:#fff;border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}.customer-search{display:flex;align-items:center;gap:10px;width:min(700px,100%)}.search-control{position:relative;display:flex;align-items:center;flex:1;min-width:220px}.search-control>i{position:absolute;left:14px;color:#8390a2;pointer-events:none}.search-control input{width:100%;height:42px;padding:0 42px;border:1px solid #cfd8e5;border-radius:8px;outline:0;color:var(--ink);background:#fff;font-size:.88rem;transition:border-color 180ms ease,box-shadow 180ms ease}.search-control input:focus{border-color:#61a0ed;box-shadow:0 0 0 3px rgba(23,114,228,.14)}.search-control input::placeholder{color:#98a2b3}.search-clear{position:absolute;right:13px;display:grid;place-items:center;width:24px;height:24px;border-radius:6px;color:#7b8798;text-decoration:none}.search-clear:hover{background:#eef2f6;color:var(--ink)}.btn-excel{color:#177245;border:1px solid #a8d5bd;background:#f2fbf6}.btn-excel:hover,.btn-excel:focus{color:#0f5c36;border-color:#7fc39e;background:#e6f7ed}.customer-results-summary{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:10px;padding:0 2px;color:#475569;font-size:.82rem}.customer-results-summary small{color:var(--muted)}.customer-table-card{box-shadow:var(--shadow)}.customer-name-cell{display:flex;align-items:center;gap:11px;min-width:220px}.customer-name-cell>div{min-width:0}.customer-name-cell strong,.customer-name-cell small{display:block}.customer-name-cell small{margin-top:3px;color:var(--muted);font-size:.74rem}.customer-initial{display:grid;place-items:center;width:34px;height:34px;flex:0 0 34px;border-radius:9px;background:#eef4fb;color:#35638f;font-size:.78rem;font-weight:750}.contact-cell{display:flex;flex-direction:column;gap:4px;min-width:190px;font-size:.8rem}.contact-cell span{display:flex;align-items:center;gap:7px}.contact-cell i{width:14px;color:#8290a3}.status-pill{display:inline-flex;align-items:center;gap:6px;padding:5px 8px;border-radius:999px;font-size:.72rem;font-weight:650;white-space:nowrap}.status-pill.success{color:#166534;background:#e7f8ed}.status-pill.warning{color:#9a5412;background:#fff4df}.btn-icon-action{display:inline-grid;place-items:center;width:34px;padding:0;color:#516071;border:1px solid #d7dee8;background:#fff}.btn-icon-action:hover{color:var(--brand);border-color:#9dc3f0;background:var(--brand-light)}.table-empty-state{display:flex;flex-direction:column;align-items:center;padding:46px 20px;color:var(--muted);text-align:center}.table-empty-state>span{display:grid;place-items:center;width:46px;height:46px;margin-bottom:12px;border-radius:12px;background:var(--brand-light);color:var(--brand);font-size:1.25rem}.table-empty-state strong{color:var(--ink);font-size:.95rem}.table-empty-state p{margin:5px 0 14px}.table-pagination{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:14px 16px;border-top:1px solid var(--line);background:#fbfcfd}.table-pagination p{margin:0;color:var(--muted);font-size:.78rem}.pagination{gap:4px}.page-link{display:grid;place-items:center;min-width:34px;height:34px;padding:0 8px;border:1px solid transparent!important;border-radius:7px!important;color:#536173;background:transparent;font-size:.78rem;font-weight:600}.page-link:hover{color:var(--brand);background:var(--brand-light)}.page-item.active .page-link{color:#fff;background:var(--brand)}.page-item.disabled .page-link{color:#aab2bf;background:transparent}.customer-table-card .table tbody tr{height:62px}
.customer-list-table{width:100%;table-layout:fixed}.customer-list-table th:nth-child(1){width:14%}.customer-list-table th:nth-child(2){width:29%}.customer-list-table th:nth-child(3){width:21%}.customer-list-table th:nth-child(4){width:25%}.customer-list-table th:nth-child(5){width:11%;white-space:nowrap}.customer-list-table td{overflow-wrap:anywhere}.customer-list-table .customer-name-cell,.customer-list-table .contact-cell{min-width:0}.customer-list-table .customer-name-cell strong,.customer-list-table .customer-name-cell small,.customer-list-table .contact-cell span{overflow-wrap:anywhere}.customer-list-table .grid-actions{min-width:74px;white-space:nowrap}
@media(max-width:1366px){.customer-list-table th,.customer-list-table td{padding:.55rem .5rem}.customer-list-table .customer-name-cell{gap:8px}.customer-list-table .customer-initial{width:30px;height:30px;flex-basis:30px;font-size:.72rem}.customer-list-table .customer-name-cell small,.customer-list-table .contact-cell{font-size:.72rem}.customer-list-table .contact-cell{gap:3px}.customer-list-table .contact-cell span{gap:5px}.customer-list-table .grid-actions{gap:4px}.customer-list-table .btn-icon-action{width:32px}}
@media(max-width:767px){.customer-page-header{align-items:stretch}.customer-primary-actions{width:100%}.customer-primary-actions .btn{flex:1}.customer-toolbar{align-items:stretch;flex-direction:column}.customer-search{width:100%}.btn-excel{width:100%}.customer-results-summary{align-items:flex-start;flex-direction:column;gap:3px}.table-pagination{align-items:flex-start;flex-direction:column}.pagination{flex-wrap:wrap}.customer-table-card .table{min-width:760px}}

/* Customer read-only detail */
.grid-actions{display:flex;align-items:center;justify-content:flex-end;gap:6px}.btn-icon-action.view{color:#1d6cb8;border-color:#bdd5ee;background:#f5f9fd}.btn-icon-action.view:hover{color:#fff;border-color:var(--brand);background:var(--brand)}.customer-detail-header{align-items:center}.detail-hero{display:flex;align-items:center;gap:16px;margin-bottom:18px;padding:18px 20px;border:1px solid #cfe1f8;border-radius:var(--radius);background:linear-gradient(90deg,#f5f9ff,#fff);box-shadow:var(--shadow)}.detail-avatar{display:grid;place-items:center;width:54px;height:54px;flex:0 0 54px;border-radius:14px;background:var(--brand);color:#fff;font-size:1.2rem;font-weight:750}.detail-hero h2{margin:0 0 7px;font-size:1.12rem}.detail-badges{display:flex;flex-wrap:wrap;gap:7px}.detail-badges span{display:inline-flex;align-items:center;gap:6px;padding:4px 8px;border-radius:6px;background:#eef2f6;color:#546172;font-size:.72rem;font-weight:600}.detail-badges span.located{color:#166534;background:#e7f8ed}.detail-card{padding:22px;background:#fff;border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}.detail-card-title{display:flex;align-items:center;gap:11px;margin-bottom:20px;padding-bottom:15px;border-bottom:1px solid #edf1f5}.detail-card-title>span{display:grid;place-items:center;width:34px;height:34px;border-radius:9px;background:var(--brand-light);color:var(--brand)}.detail-card-title h2,.detail-card-title p{margin:0}.detail-card-title p{margin-top:3px;color:var(--muted);font-size:.74rem}.detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px 24px;margin:0}.detail-grid.single{grid-template-columns:1fr}.detail-grid-address{grid-template-columns:repeat(3,minmax(0,1fr))}.detail-grid .wide{grid-column:span 2}.detail-grid div{min-width:0}.detail-grid dt{margin-bottom:5px;color:#778396;font-size:.7rem;font-weight:700;letter-spacing:.035em;text-transform:uppercase}.detail-grid dd{margin:0;color:var(--ink);font-size:.88rem;overflow-wrap:anywhere}.detail-observation{margin:0;color:#465366;line-height:1.65;white-space:pre-line}@media(max-width:767px){.customer-detail-header{align-items:stretch}.customer-detail-header>.btn{width:100%}.detail-grid,.detail-grid-address{grid-template-columns:1fr}.detail-grid .wide{grid-column:auto}}

/* Premium customer action hierarchy */
.customer-primary-actions{gap:8px}.action-button{display:inline-flex;align-items:center;justify-content:center;gap:9px;height:42px;padding:0 15px;border-radius:9px;font-size:.84rem;font-weight:650;letter-spacing:-.005em;transition:transform 180ms ease,box-shadow 180ms ease,background-color 180ms ease,border-color 180ms ease,color 180ms ease}.action-button i{display:grid;place-items:center;width:20px;height:20px;font-size:.9rem}.action-map{border:1px solid #d3dbe6;background:#fff;color:#465568;box-shadow:0 1px 2px rgba(15,23,42,.03)}.action-map i{color:var(--brand)}.action-map:hover,.action-map:focus-visible{border-color:#a9c8ec;background:#f7faff;color:#244d78;box-shadow:0 4px 12px rgba(15,23,42,.06);transform:translateY(-1px)}.action-create{border:1px solid var(--brand);background:var(--brand);color:#fff;box-shadow:0 4px 12px rgba(23,114,228,.2)}.action-create:hover,.action-create:focus-visible{border-color:var(--brand-hover);background:var(--brand-hover);color:#fff;box-shadow:0 6px 16px rgba(18,93,184,.24);transform:translateY(-1px)}.action-button:active{transform:translateY(0);box-shadow:none}.customer-toolbar{min-height:74px;padding:14px 16px}.customer-search{width:min(760px,100%)}.search-control{height:44px;border:1px solid #cfd8e5;border-radius:10px;background:#fff;box-shadow:inset 0 1px 2px rgba(15,23,42,.025);transition:border-color 180ms ease,box-shadow 180ms ease}.search-control:focus-within{border-color:#6aa6ec;box-shadow:0 0 0 3px rgba(23,114,228,.12)}.search-control>i.search-leading-icon{left:15px;color:#7f8da0}.search-control input{height:42px;padding:0 164px 0 43px;border:0;border-radius:9px;background:transparent;box-shadow:none}.search-control input:focus{border:0;box-shadow:none}.search-clear{right:116px}.search-submit{position:absolute;right:4px;top:4px;bottom:4px;display:inline-flex;align-items:center;justify-content:center;gap:7px;min-width:104px;padding:0 14px;border:0;border-radius:7px;background:var(--brand);color:#fff;font-size:.8rem;font-weight:650;transition:background-color 180ms ease,box-shadow 180ms ease}.search-submit:hover,.search-submit:focus-visible{background:var(--brand-hover);box-shadow:0 3px 9px rgba(18,93,184,.2);outline:0}.search-submit:active{box-shadow:none}.customer-utility-actions{display:flex;align-items:center;padding-left:16px;border-left:1px solid var(--line)}.btn-excel{display:inline-flex;align-items:center;justify-content:center;gap:9px;height:42px;padding:0 14px;border:1px solid #d1d9e4;border-radius:9px;background:#fff;color:#465568;font-size:.82rem;font-weight:650;box-shadow:0 1px 2px rgba(15,23,42,.03);transition:transform 180ms ease,box-shadow 180ms ease,border-color 180ms ease,background-color 180ms ease,color 180ms ease}.btn-excel i{color:#18864b;font-size:1rem}.btn-excel:hover,.btn-excel:focus-visible{border-color:#9dcbb1;background:#f3fbf6;color:#116239;box-shadow:0 4px 12px rgba(22,163,74,.08);transform:translateY(-1px)}.btn-excel:active{transform:translateY(0);box-shadow:none}
@media(max-width:900px){.customer-toolbar{align-items:stretch;flex-direction:column}.customer-search{width:100%}.customer-utility-actions{justify-content:flex-end;padding:12px 0 0;border-top:1px solid var(--line);border-left:0}}
@media(max-width:575px){.customer-primary-actions{display:grid;grid-template-columns:1fr 1fr}.search-control input{padding-right:112px}.search-submit{min-width:42px;width:42px;padding:0}.search-submit span{display:none}.search-clear{right:52px}.customer-utility-actions .btn-excel{width:100%}}

/* Shared premium module screens */
.module-page-header{display:flex;flex-wrap:wrap;align-items:flex-end;justify-content:space-between;gap:24px;margin-bottom:24px}.module-title{display:flex;align-items:center;gap:14px}.module-title h1,.module-title p{margin:0}.module-title p{margin-top:5px;color:var(--muted)}.module-context-bar{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:14px;padding:14px 16px;border:1px solid var(--line);border-radius:var(--radius);background:#fff;box-shadow:var(--shadow)}.module-context-item{display:flex;align-items:center;gap:11px}.module-context-item>span{display:grid;place-items:center;width:34px;height:34px;border-radius:9px;background:var(--brand-light);color:var(--brand)}.module-context-item small,.module-context-item strong{display:block}.module-context-item small{color:var(--muted);font-size:.68rem}.module-context-item strong{margin-top:2px;font-size:.83rem}.module-context-count{display:flex;align-items:baseline;gap:7px;color:var(--muted);font-size:.76rem}.module-context-count strong{color:var(--ink);font-size:1rem}.module-table-card tbody tr{height:62px}.record-primary{display:flex;align-items:center;gap:11px;min-width:210px}.record-primary>div{min-width:0}.record-primary strong,.record-primary small{display:block}.record-primary small{margin-top:3px;color:var(--muted);font-size:.72rem}.record-icon,.record-avatar{display:grid;place-items:center;width:34px;height:34px;flex:0 0 34px;border-radius:9px;background:#eef4fb;color:#35638f}.record-icon.accounting{color:#6d4bb8;background:#f3effb}.record-avatar{font-size:.76rem;font-weight:750}.numeric-cell{font-variant-numeric:tabular-nums;font-weight:600}.invoice-total-value,.invoice-total-breakdown{color:var(--ink)!important}.invoice-total-value{font-size:1rem;font-weight:700}.invoice-total-breakdown{font-size:.72rem;font-weight:500}.status-pill.neutral{color:#596577;background:#eef1f5}.level-chip{display:inline-grid;place-items:center;min-width:30px;height:26px;padding:0 7px;border-radius:6px;background:var(--brand-light);color:var(--brand-hover);font-size:.74rem;font-weight:700}.type-chip{display:inline-flex;padding:4px 7px;border-radius:6px;background:#f2f4f7;color:#536173;font-size:.74rem;font-weight:600}.btn-icon-action.danger{color:#b42318}.btn-icon-action.danger:hover{border-color:#f0aaa5;background:#fff1f0;color:#d92d20}.grid-actions form{margin:0}.module-search-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:12px;padding:14px 16px;border:1px solid var(--line);border-radius:var(--radius);background:#fff;box-shadow:var(--shadow)}.module-company-label{display:flex;align-items:center;gap:7px;padding-left:16px;border-left:1px solid var(--line);color:var(--muted);font-size:.74rem;white-space:nowrap}.module-company-label i{color:var(--brand)}.module-company-label strong{color:var(--ink)}.module-results-summary{margin:0 2px 10px;color:#536173;font-size:.8rem}.seller-chip{display:inline-flex;align-items:center;gap:4px;padding:4px 7px;border-radius:6px;background:var(--brand-light);color:var(--brand-hover);font-size:.73rem;font-weight:650}.guid-code{display:inline-block;max-width:210px;overflow:hidden;text-overflow:ellipsis;vertical-align:middle;white-space:nowrap}
.route-header-actions{display:flex;align-items:center;gap:9px}.route-saved-status{display:inline-flex;align-items:center;gap:6px;padding:7px 10px;border-radius:8px;background:#e9f8ee;color:#166534;font-size:.74rem;font-weight:650}.route-config-card{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;margin-bottom:16px;padding:16px 18px;border:1px solid var(--line);border-radius:var(--radius);background:#fff;box-shadow:var(--shadow)}.route-config-heading{display:flex;align-items:center;gap:11px;min-width:205px}.route-config-heading>span{display:grid;place-items:center;width:34px;height:34px;border-radius:9px;background:var(--brand-light);color:var(--brand)}.route-config-heading h2,.route-config-heading p{margin:0}.route-config-heading p{margin-top:3px;color:var(--muted);font-size:.72rem}.route-config-fields{display:grid;grid-template-columns:180px minmax(280px,1fr) auto;align-items:end;gap:12px;flex:1}.route-clear-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;height:42px;border:1px solid #d2dae5;background:#fff;color:#526072}.route-clear-button:hover{border-color:#bdc8d6;background:#f7f9fb;color:#27364a}.route-workspace{display:grid;grid-template-columns:minmax(0,1fr) 360px;gap:16px}.route-map-card,.route-sidebar{overflow:hidden;border:1px solid var(--line);border-radius:var(--radius);background:#fff;box-shadow:var(--shadow)}.workspace-card-header{display:flex;align-items:center;justify-content:space-between;gap:16px;height:68px;padding:0 18px;border-bottom:1px solid var(--line)}.workspace-card-header h2,.workspace-card-header p{margin:0}.workspace-card-header p{margin-top:3px;color:var(--muted);font-size:.72rem}.map-legend{display:inline-flex;align-items:center;gap:7px;color:var(--muted);font-size:.7rem}.map-legend i{width:9px;height:9px;border-radius:50%;background:var(--brand);box-shadow:0 0 0 3px var(--brand-light)}.route-map{height:calc(68vh - 68px);min-height:500px}.route-sidebar{display:flex;flex-direction:column;max-height:68vh}.route-list-header{display:flex;align-items:center;justify-content:space-between;min-height:78px;padding:15px 17px;border-bottom:1px solid var(--line)}.route-list-header h2{margin:0}.selected-counter{display:flex;align-items:center;gap:5px;padding:6px 9px;border-radius:8px;background:var(--brand-light);color:var(--brand)}.selected-counter strong{font-size:.9rem}.selected-counter small{font-size:.66rem}.route-list{overflow-y:auto}.route-stop{display:grid;grid-template-columns:32px minmax(0,1fr) auto;gap:11px;align-items:center;padding:12px 14px;border-bottom:1px solid #edf1f5}.route-stop strong,.route-stop small{display:block}.route-stop strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:.82rem}.route-stop small{margin-top:3px;font-size:.68rem}.route-order{display:grid;place-items:center;width:30px;height:30px;border-radius:8px;background:var(--brand);color:#fff;font-size:.75rem;font-weight:700}.route-pin{width:18px;height:18px;border:3px solid #fff;border-radius:50%;background:var(--brand);box-shadow:0 2px 7px rgba(15,23,42,.35)}.route-pin.selected{background:var(--danger);transform:scale(1.18)}.route-empty-state{display:flex;flex:1;flex-direction:column;align-items:center;justify-content:center;padding:36px 24px;color:var(--muted);text-align:center}.route-empty-state>span{display:grid;place-items:center;width:46px;height:46px;margin-bottom:12px;border-radius:12px;background:var(--brand-light);color:var(--brand);font-size:1.2rem}.route-empty-state strong{color:var(--ink)}.route-empty-state p{max-width:230px;margin:5px 0 0;font-size:.76rem}.route-save-footer{margin-top:auto;padding:14px;border-top:1px solid var(--line);background:#fbfcfd}.route-result-card{display:flex;align-items:center;gap:12px;margin-top:16px;padding:14px 16px;border:1px solid #bee3ca;border-radius:var(--radius);background:#f2fbf5}.route-result-card>span{display:grid;place-items:center;width:36px;height:36px;border-radius:9px;background:#dff5e7;color:#16803e}.route-result-card small,.route-result-card strong,.route-result-card p{display:block;margin:0}.route-result-card small{color:#42815a;font-size:.64rem;font-weight:750;letter-spacing:.06em}.route-result-card strong{margin-top:3px;color:#1d4930}.route-result-card p{margin-top:2px;color:#587565;font-size:.72rem}
@media(max-width:1100px){.route-config-card{align-items:stretch;flex-direction:column}.route-config-fields{width:100%}.route-workspace{grid-template-columns:1fr}.route-map{height:56vh;min-height:430px}.route-sidebar{max-height:none;min-height:430px}}
@media(max-width:767px){.module-page-header{align-items:stretch}.module-page-header>.action-button{width:100%}.module-context-bar{align-items:flex-start;flex-direction:column}.module-search-toolbar{align-items:stretch;flex-direction:column}.module-company-label{padding:10px 0 0;border-top:1px solid var(--line);border-left:0}.route-header-actions{align-items:stretch;flex-direction:column}.route-config-fields{grid-template-columns:1fr}.workspace-card-header{align-items:flex-start;flex-direction:column;height:auto;padding:14px}.route-map{height:52vh;min-height:380px}.route-page-header{align-items:stretch}.route-header-actions .action-button{width:100%}}

/* Standardized list filters */
.search-control select{position:absolute;right:112px;top:4px;bottom:4px;width:132px;padding:0 28px 0 10px;border:0;border-left:1px solid var(--line);background:#fff;color:#526072;font-size:.8rem;outline:0}
.search-control:has(select) input{padding-right:262px}
.route-filter-toolbar .customer-search{width:100%}
.route-filter-grid{display:grid;grid-template-columns:minmax(230px,1fr) 145px 145px 210px auto;gap:10px;width:100%;align-items:center}
.route-filter-grid .search-control input{padding-right:16px}
.route-filter-grid>.search-submit{position:static;height:44px;min-width:108px}
.visits-filter-toolbar .customer-search{width:100%}
.visits-filter-grid{display:grid;grid-template-columns:minmax(280px,1fr) 155px 155px auto auto;gap:10px;width:100%;align-items:center}
.visits-filter-grid .search-control input{padding-right:16px}
.visits-filter-grid>.search-submit{position:static;height:44px;min-width:108px}
.visits-clear-button{display:inline-flex;align-items:center;justify-content:center;gap:7px;height:44px;padding:0 14px;border:1px solid #d1d9e4;border-radius:9px;background:#fff;color:#526072;font-size:.8rem;font-weight:650;white-space:nowrap}
.visits-clear-button:hover,.visits-clear-button:focus-visible{border-color:#b9c5d4;background:#f7f9fb;color:#27364a}
.detail-hero .customer-detail-avatar{display:grid;place-items:center;width:54px;height:54px;flex:0 0 54px;border-radius:14px;background:var(--brand);color:#fff;font-size:1.25rem}
.detail-hero small,.detail-grid small{display:block;margin-bottom:5px;color:#778396;font-size:.7rem;font-weight:700;letter-spacing:.035em;text-transform:uppercase}
.detail-hero h2{margin:0 0 8px}.detail-grid strong{font-size:.88rem;overflow-wrap:anywhere}
@media(max-width:1100px){.route-filter-grid{grid-template-columns:1fr 1fr}.route-filter-grid .search-control{grid-column:1/-1}.route-filter-grid>.search-submit{width:100%}}
@media(max-width:1200px){.visits-filter-toolbar{align-items:stretch;flex-direction:column}.visits-filter-toolbar .customer-utility-actions{justify-content:flex-end;padding:12px 0 0;border-top:1px solid var(--line);border-left:0}.visits-filter-grid{grid-template-columns:1fr 1fr}.visits-filter-grid .search-control{grid-column:1/-1}.visits-filter-grid>.search-submit,.visits-filter-grid>.visits-clear-button{width:100%}}
@media(max-width:650px){.search-control:has(select){height:auto;display:grid;padding-top:44px}.search-control:has(select) input{position:absolute;top:0;padding-right:112px}.search-control select{left:8px;right:116px;top:47px;bottom:auto;width:calc(100% - 124px);height:36px;border-left:0}.search-control:has(select) .search-submit{top:47px;bottom:auto;height:36px}.route-filter-grid{grid-template-columns:1fr}.route-filter-grid>*{grid-column:1!important}}
@media(max-width:650px){.visits-filter-grid{grid-template-columns:1fr}.visits-filter-grid>*{grid-column:1!important}.visits-filter-grid>.search-submit span{display:inline}.visits-filter-toolbar .customer-utility-actions .btn-excel{width:100%}}

/* Visitas a clientes: conservar las acciones accesibles al recorrer datos amplios. */
.customer-visits-table th:last-child,.customer-visits-table td:last-child{position:sticky;right:0;min-width:92px}
.customer-visits-table th:last-child{z-index:4;background:#f8fafc;box-shadow:-8px 0 12px -10px rgba(15,23,42,.55)}
.customer-visits-table td:last-child{z-index:1;background:var(--surface);box-shadow:-8px 0 12px -10px rgba(15,23,42,.55)}
.customer-visits-table tbody tr:nth-child(even) td:last-child{background:#fbfcfd}
.customer-visits-table tbody tr:hover td:last-child{background:#f1f7fe}
html[data-theme=dark] .customer-visits-table th:last-child{background:#111b2c}
html[data-theme=dark] .customer-visits-table td:last-child{background:#111b2c}
html[data-theme=dark] .customer-visits-table tbody tr:nth-child(even) td:last-child{background:#142036}
html[data-theme=dark] .customer-visits-table tbody tr:hover td:last-child{background:#18243a}


/* Pedidos de clientes */
.order-filter-toolbar .customer-search{width:100%}
.order-filter-grid{display:grid;grid-template-columns:minmax(220px,1fr) 145px 145px 150px 150px auto;gap:10px;width:100%;align-items:center}
.order-filter-grid .search-control input{padding-right:16px}
.order-filter-grid>.search-submit{position:static;height:44px;min-width:108px}
.order-lines-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:18px 20px;border-bottom:1px solid var(--line)}
.order-lines-heading h2,.order-lines-heading p{margin:0}.order-lines-heading h2{font-size:1rem}.order-lines-heading p{margin-top:4px;color:var(--muted);font-size:.76rem}
.order-items-card{padding:0;overflow:hidden}.order-master-card{padding:22px}.order-edit-table{margin:0}.order-edit-table td{padding-top:10px;padding-bottom:10px}.order-edit-table tfoot td{padding:14px 12px;background:#f8fafc;border-top:1px solid var(--line)}
.form-actions-sticky{position:sticky;bottom:0;z-index:5;display:flex;justify-content:flex-end;gap:10px;margin-top:20px;padding:14px 16px;border:1px solid var(--line);border-radius:10px;background:rgba(255,255,255,.96);box-shadow:0 -4px 18px rgba(15,23,42,.06);backdrop-filter:blur(8px)}
.invoice-filter-grid{display:grid;grid-template-columns:minmax(200px,1.2fr) 130px 130px 145px 155px auto;gap:10px;width:100%;align-items:center}
.invoice-filter-grid .search-control input{padding-right:16px}
.invoice-filter-grid>.search-submit{position:static;height:44px;min-width:108px}
@media(max-width:1200px){.invoice-filter-grid{grid-template-columns:1fr 1fr}.invoice-filter-grid .search-control{grid-column:1/-1}.invoice-filter-grid>.search-submit{width:100%}}
@media(max-width:650px){.invoice-filter-grid{grid-template-columns:1fr}.invoice-filter-grid>*{grid-column:1!important}}
@media(max-width:1100px){.order-filter-grid{grid-template-columns:1fr 1fr}.order-filter-grid .search-control{grid-column:1/-1}.order-filter-grid>.search-submit{width:100%}}
@media(max-width:650px){.order-filter-grid{grid-template-columns:1fr}.order-filter-grid>*{grid-column:1!important}.order-lines-heading{align-items:stretch;flex-direction:column}.order-lines-heading .btn{width:100%}.form-actions-sticky .btn{flex:1}}

/* Listados comerciales: priorizar controles y acciones en equipos 1280 x 720. */
@media(max-width:1366px){
    .topbar{padding-right:22px;padding-left:22px}
    .content-area{width:100%;padding:24px 24px 36px}
    .module-page-header{gap:16px;margin-bottom:18px}
    .order-filter-toolbar{align-items:stretch;flex-direction:column}
    .order-filter-toolbar .customer-utility-actions{justify-content:flex-end;padding:12px 0 0;border-top:1px solid var(--line);border-left:0}
    .order-filter-grid,.invoice-filter-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
    .order-filter-grid .search-control,.invoice-filter-grid .search-control{grid-column:1/-1}
    .order-filter-grid>.search-submit,.invoice-filter-grid>.search-submit{width:100%}
    .responsive-list-table{width:100%;table-layout:fixed}
    .responsive-list-table td{overflow-wrap:anywhere}
    .responsive-list-table .record-primary{min-width:0;gap:8px}
    .responsive-list-table .record-primary strong,.responsive-list-table .record-primary small{overflow-wrap:anywhere}
    .responsive-list-table .grid-actions{min-width:0;gap:4px;flex-wrap:wrap}
    .responsive-list-table .btn-icon-action{width:32px}
    .responsive-list-table th,.responsive-list-table td{padding:.55rem .5rem}
    .quotation-list-table th:nth-child(1){width:8%}
    .quotation-list-table th:nth-child(2){width:13%}
    .quotation-list-table th:nth-child(3){width:24%}
    .quotation-list-table th:nth-child(4){width:7%}
    .quotation-list-table th:nth-child(5){width:10%}
    .quotation-list-table th:nth-child(6){width:13%}
    .quotation-list-table th:nth-child(7){width:9%}
    .quotation-list-table th:nth-child(8){width:8%}
    .quotation-list-table th:nth-child(9){width:8%}
    .pedido-list-table th:nth-child(1){width:9%}
    .pedido-list-table th:nth-child(2){width:14%}
    .pedido-list-table th:nth-child(3){width:13%}
    .pedido-list-table th:nth-child(4){width:8%}
    .pedido-list-table th:nth-child(5){width:25%}
    .pedido-list-table th:nth-child(6){width:8%}
    .pedido-list-table th:nth-child(7){width:9%}
    .pedido-list-table th:nth-child(8){width:14%}
    .invoice-list-table th:nth-child(1){width:12%}
    .invoice-list-table th:nth-child(2){width:13%}
    .invoice-list-table th:nth-child(3){width:21%}
    .invoice-list-table th:nth-child(4){width:13%}
    .invoice-list-table th:nth-child(5){width:10%}
    .invoice-list-table th:nth-child(6){width:8%}
    .invoice-list-table th:nth-child(7){width:10%}
    .invoice-list-table th:nth-child(8){width:13%}
}
@media(max-width:900px){
    .order-filter-grid,.invoice-filter-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:650px){
    .order-filter-grid,.invoice-filter-grid{grid-template-columns:1fr}
    .order-filter-grid>*,.invoice-filter-grid>*{grid-column:1!important}
}


/* Selectores remotos para catálogos grandes */
/* Facturación: mantener las acciones visibles también en teléfonos. */
@media(max-width:650px){
    .invoice-list-table th:last-child,.invoice-list-table td:last-child{position:sticky;right:0;min-width:112px;box-shadow:-8px 0 12px -10px rgba(15,23,42,.55)}
    .invoice-list-table th:last-child{z-index:3;background:var(--surface)}
    .invoice-list-table td:last-child{z-index:1;background:var(--surface)}
    .invoice-list-table .grid-actions{justify-content:flex-end;flex-wrap:wrap}
}
.remote-select{position:relative;min-width:260px}.remote-select-control{position:relative;display:flex;align-items:center;height:42px;border:1px solid #cfd8e5;border-radius:8px;background:#fff;transition:border-color 180ms ease,box-shadow 180ms ease}.remote-select-control:focus-within{border-color:#61a0ed;box-shadow:0 0 0 3px rgba(23,114,228,.14)}.remote-select-control>i{position:absolute;left:13px;color:#8390a2;pointer-events:none}.remote-query{width:100%;height:40px;padding:0 42px;border:0;border-radius:8px;background:transparent;color:var(--ink);font-size:.85rem;outline:0}.remote-query::placeholder{color:#98a2b3}.remote-clear{position:absolute;right:7px;display:grid;place-items:center;width:28px;height:28px;padding:0;border:0;border-radius:6px;background:transparent;color:#8390a2}.remote-clear:hover{background:#eef2f6;color:var(--ink)}.remote-results{position:absolute;z-index:40;top:calc(100% + 6px);left:0;right:0;max-height:280px;overflow:auto;padding:5px;border:1px solid #d7dee8;border-radius:9px;background:#fff;box-shadow:0 14px 32px rgba(15,23,42,.14)}.remote-option{display:block;width:100%;padding:9px 10px;border:0;border-radius:6px;background:transparent;color:#344054;font-size:.8rem;text-align:left}.remote-option:hover,.remote-option:focus{background:var(--brand-light);color:var(--brand-hover);outline:0}.remote-message{padding:14px 10px;color:var(--muted);font-size:.8rem;text-align:center}.order-edit-table td:has(.remote-select){overflow:visible}
.remote-select{position:relative;min-width:260px}.remote-select-control{position:relative;display:flex;align-items:center;height:42px;border:1px solid #cfd8e5;border-radius:8px;background:#fff;transition:border-color 180ms ease,box-shadow 180ms ease}.remote-select-control:focus-within{border-color:#61a0ed;box-shadow:0 0 0 3px rgba(23,114,228,.14)}.remote-select-control>i{position:absolute;left:13px;color:#8390a2;pointer-events:none}.remote-query{width:100%;height:40px;padding:0 42px;border:0;border-radius:8px;background:transparent;color:var(--ink);font-size:.85rem;outline:0}.remote-query::placeholder{color:#98a2b3}.remote-clear{position:absolute;right:7px;display:grid;place-items:center;width:28px;height:28px;padding:0;border:0;border-radius:6px;background:transparent;color:#8390a2}.remote-clear:hover{background:#eef2f6;color:var(--ink)}.remote-results{position:absolute;z-index:40;top:calc(100% + 6px);left:0;right:0;max-height:280px;overflow:auto;padding:5px;border:1px solid #d7dee8;border-radius:9px;background:#fff;box-shadow:0 14px 32px rgba(15,23,42,.14)}.remote-option{display:block;width:100%;padding:9px 10px;border:0;border-radius:6px;background:transparent;color:#344054;font-size:.8rem;text-align:left}.remote-option>span,.remote-option-detail{display:block}.remote-option-detail{margin-top:3px;color:#768397;font-size:.7rem;font-weight:500}.remote-option:hover,.remote-option:focus,.remote-option.is-active{background:var(--brand-light);color:var(--brand-hover);outline:0}.remote-message{padding:14px 10px;color:var(--muted);font-size:.8rem;text-align:center}.remote-suggestion-label{padding:7px 10px 5px;color:#64748b;font-size:.7rem;font-weight:700;letter-spacing:.03em;text-transform:uppercase}.order-edit-table td:has(.remote-select){overflow:visible}

/* Corrección de visibilidad para buscadores dentro del detalle de pedidos */
.order-items-card{overflow:visible}
.order-items-card>.table-responsive{overflow:visible}
.order-items-card .order-edit-table{position:relative}
.order-items-card .remote-select{z-index:1}
.order-items-card .remote-select:focus-within{z-index:50}
.order-items-card .remote-results{z-index:1055;max-height:min(340px,45vh)}
.remote-select.remote-results-upward .remote-results{top:auto;bottom:calc(100% + 6px)}
.remote-query::-webkit-search-cancel-button,.remote-query::-webkit-search-decoration{-webkit-appearance:none;appearance:none;display:none}
@media(max-width:767px){.order-items-card>.table-responsive{overflow-x:auto;overflow-y:visible}.order-items-card .order-edit-table{min-width:680px}}

/* Atajos y búsqueda avanzada de cotizaciones */
.quotation-shortcuts{display:flex;flex-wrap:wrap;align-items:center;gap:8px 16px;padding:9px 20px;border-bottom:1px solid var(--line);background:#f8fbff;color:#526276;font-size:.76rem}.quotation-shortcuts>i{color:var(--brand)}.quotation-shortcuts span{white-space:nowrap}.quotation-shortcuts kbd{padding:2px 5px;border-radius:4px;background:#e7eef8;color:#334155;font-family:inherit;font-size:.7rem;font-weight:700;box-shadow:none}.quotation-item-search-results{border:1px solid var(--line);border-radius:8px}.quotation-item-search-results table{min-width:760px}.quotation-item-search-results thead th{white-space:nowrap}.quotation-item-search-results tbody tr.advanced-result-active>*{background:var(--brand-light)!important;color:var(--brand-hover)}@media(max-width:767px){.quotation-shortcuts{padding:9px 14px;gap:7px 12px}.quotation-shortcuts span{white-space:normal}}
html[data-theme=dark] .quotation-shortcuts{background:#101b2b;color:#b6c3d3}html[data-theme=dark] .quotation-shortcuts kbd{background:#26364d;color:#dce7f4}

/* Mapa exclusivo de una hoja de ruta programada */
.route-view-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:16px}.route-view-summary>div{display:flex;align-items:center;gap:11px;padding:14px 16px;border:1px solid var(--line);border-radius:var(--radius);background:#fff;box-shadow:var(--shadow)}.route-view-summary>div>span{display:grid;place-items:center;width:36px;height:36px;flex:0 0 36px;border-radius:9px;background:var(--brand-light);color:var(--brand)}.route-view-summary small,.route-view-summary strong{display:block}.route-view-summary small{color:var(--muted);font-size:.68rem}.route-view-summary strong{margin-top:2px;font-size:.82rem}.route-view-workspace{display:grid;grid-template-columns:minmax(0,1fr) 360px;gap:16px}.route-view-map{height:calc(72vh - 68px);min-height:520px}.route-view-sidebar{max-height:72vh}.route-view-list{flex:1}.route-view-stop{width:100%;border:0;border-bottom:1px solid #edf1f5;background:#fff;color:var(--ink);text-align:left;transition:background-color 160ms ease}.route-view-stop:hover,.route-view-stop:focus,.route-view-stop.active{background:var(--brand-light);outline:0}.route-view-stop>i{color:#92a0b2}.route-numbered-pin{display:grid;place-items:center;width:32px;height:32px;border:3px solid #fff;border-radius:50% 50% 50% 6px;background:var(--brand);color:#fff;font-size:.74rem;font-weight:800;box-shadow:0 3px 10px rgba(15,23,42,.35);transform:rotate(-45deg)}.route-numbered-pin::first-line{transform:rotate(45deg)}
@media(max-width:1100px){.route-view-workspace{grid-template-columns:1fr}.route-view-map{height:56vh;min-height:430px}.route-view-sidebar{max-height:none}.route-view-list{max-height:420px}}
@media(max-width:767px){.route-view-summary{grid-template-columns:1fr}}

.route-numbered-pin>span{transform:rotate(45deg)}

/* Dark theme: light mode remains the default design above. */
html[data-theme=dark]{color-scheme:dark;--ink:#e6edf7;--muted:#9aa8bc;--line:#2a384c;--surface:#111b2c;--canvas:#0b1120;--brand:#3b82f6;--brand-hover:#2563eb;--brand-light:#172c49;--success:#4ade80;--warning:#fbbf24;--danger:#f87171;--shadow:0 1px 2px rgba(0,0,0,.24),0 8px 24px rgba(0,0,0,.16);--bs-body-color:var(--ink);--bs-body-bg:var(--canvas);--bs-border-color:var(--line);--bs-secondary-color:var(--muted);--bs-secondary-bg:#172235;--bs-tertiary-bg:#182438;--bs-emphasis-color:#f8fafc}
html[data-theme=dark] body{background:var(--canvas);color:var(--ink)}
html[data-theme=dark] .topbar{background:rgba(11,17,32,.94)}
html[data-theme=dark] .global-search,html[data-theme=dark] .user-button:hover{background:#111b2c}
html[data-theme=dark] .global-search:focus-within{background:#152135}
html[data-theme=dark] .global-search input{color:var(--ink)}
html[data-theme=dark] input::placeholder,html[data-theme=dark] textarea::placeholder{color:#75849a;opacity:1}
html[data-theme=dark] .global-search kbd,html[data-theme=dark] .company-chip,html[data-theme=dark] .icon-button{background:#111b2c;color:#aab7c9}
html[data-theme=dark] .icon-button:hover,html[data-theme=dark] .icon-button:focus-visible{border-color:#45617f;background:#1a2940;color:#fff}
html[data-theme=dark] .theme-toggle{color:#fbbf24}
html[data-theme=dark] .notification-dot{border-color:#111b2c}
html[data-theme=dark] .dropdown-menu{--bs-dropdown-bg:#111b2c;--bs-dropdown-link-color:var(--ink);--bs-dropdown-link-hover-color:#fff;--bs-dropdown-link-hover-bg:#1a2940;--bs-dropdown-border-color:var(--line)}
html[data-theme=dark] .sidebar{background:#080e1a}
html[data-theme=dark] .menu-filter,html[data-theme=dark] .side-link:hover,html[data-theme=dark] .side-link:focus-visible{background:#172235}
html[data-theme=dark] .menu-filter,html[data-theme=dark] .sidebar-toggle{border-color:#2c3b51}
html[data-theme=dark] body.sidebar-collapsed .sidebar-toggle{border-color:#34445b;background:#111b2c;color:#aab7c9}
html[data-theme=dark] .mobile-navigation{background:#080e1a}
html[data-theme=dark] .metric-card,html[data-theme=dark] .table-card,html[data-theme=dark] .form-card,html[data-theme=dark] .empty-state,html[data-theme=dark] .login-card,html[data-theme=dark] .dashboard-panel,html[data-theme=dark] .customer-toolbar,html[data-theme=dark] .module-context-bar,html[data-theme=dark] .module-search-toolbar,html[data-theme=dark] .route-config-card,html[data-theme=dark] .route-map-card,html[data-theme=dark] .route-sidebar,html[data-theme=dark] .route-view-summary>div{background:var(--surface)}
html[data-theme=dark] .form-label{color:#c7d2e1}
html[data-theme=dark] .form-control,html[data-theme=dark] .form-select,html[data-theme=dark] .search-control,html[data-theme=dark] .search-control input,html[data-theme=dark] .search-control select,html[data-theme=dark] .remote-select-control,html[data-theme=dark] .remote-query{border-color:#34445b;background:#0e1728;color:var(--ink)}
html[data-theme=dark] .form-control:disabled,html[data-theme=dark] .form-select:disabled{background:#172235;color:#7f8da2}
html[data-theme=dark] .form-check-input{border-color:#506079;background-color:#111b2c}
html[data-theme=dark] .search-clear:hover,html[data-theme=dark] .remote-clear:hover{background:#223149;color:var(--ink)}
html[data-theme=dark] .remote-results{border-color:var(--line);background:#111b2c;box-shadow:0 16px 36px rgba(0,0,0,.35)}
html[data-theme=dark] .remote-option{color:#d7e0ed}
html[data-theme=dark] .remote-option:hover,html[data-theme=dark] .remote-option:focus{background:var(--brand-light);color:#bfdbfe}
html[data-theme=dark] .table{--bs-table-color:var(--ink);--bs-table-bg:transparent;--bs-table-border-color:var(--line)}
html[data-theme=dark] .table-card th{background:#172235;color:#9fb0c6}
html[data-theme=dark] .table-card td,html[data-theme=dark] .table-card th,html[data-theme=dark] .route-stop,html[data-theme=dark] .route-view-stop{border-color:#243247}
html[data-theme=dark] .table-card tbody tr:nth-child(even){background:#131e30}
html[data-theme=dark] .table-card tbody tr:hover{background:#182a43}
html[data-theme=dark] .table-card code{background:#1b2940;color:#bfdbfe}
html[data-theme=dark] .table-pagination,html[data-theme=dark] .route-save-footer,html[data-theme=dark] .order-edit-table tfoot td{background:#0f192a}
html[data-theme=dark] .page-link{color:#aab7c9}
html[data-theme=dark] .btn-icon-action,html[data-theme=dark] .btn-excel,html[data-theme=dark] .route-clear-button,html[data-theme=dark] .visits-clear-button{border-color:#3a4a60;background:#111b2c;color:#b8c4d4}
html[data-theme=dark] .btn-icon-action:hover,html[data-theme=dark] .btn-excel:hover,html[data-theme=dark] .route-clear-button:hover,html[data-theme=dark] .visits-clear-button:hover{border-color:#52749b;background:#1a2940;color:#fff}
html[data-theme=dark] .quick-action{color:var(--ink)}
html[data-theme=dark] .activity-item{border-color:#243247}
html[data-theme=dark] .operational-item{border-color:#2b3d56;background:#111b2c;color:var(--ink)}
html[data-theme=dark] .operational-item:hover{border-color:#3d6798;background:#172a43;color:var(--ink)}
html[data-theme=dark] .operational-item.needs-attention{border-color:#865d1b;background:#241b0c}
html[data-theme=dark] .operational-item.needs-attention:hover{border-color:#b47a20;background:#30230d}
html[data-theme=dark] .operational-note{border-color:#243247}
html[data-theme=dark] .blue,html[data-theme=dark] .avatar,html[data-theme=dark] .customer-initial,html[data-theme=dark] .record-icon,html[data-theme=dark] .record-avatar{background:#172c49;color:#93c5fd}
html[data-theme=dark] .green{background:#123322;color:#6ee7a0}
html[data-theme=dark] .violet,html[data-theme=dark] .record-icon.accounting{background:#2a2042;color:#c4b5fd}
html[data-theme=dark] .orange{background:#392711;color:#fcd34d}
html[data-theme=dark] .status-pill.success,html[data-theme=dark] .text-bg-success{background:#123322!important;color:#86efac!important}
html[data-theme=dark] .status-pill.warning,html[data-theme=dark] .text-bg-warning{background:#3a2812!important;color:#fcd34d!important}
html[data-theme=dark] .text-bg-danger{background:#3d1d24!important;color:#fca5a5!important}
html[data-theme=dark] .text-bg-primary{background:var(--brand-light)!important;color:#93c5fd!important}
html[data-theme=dark] .status-pill.neutral,html[data-theme=dark] .type-chip{background:#202c3e;color:#b5c1d1}
html[data-theme=dark] .level-chip,html[data-theme=dark] .seller-chip{background:var(--brand-light);color:#93c5fd}
html[data-theme=dark] .permission-option:has(input:checked){border-color:#3b82f6;background:#172c49}
html[data-theme=dark] .customer-results-summary,html[data-theme=dark] .module-results-summary,html[data-theme=dark] .detail-hero small,html[data-theme=dark] .detail-grid small{color:#9aa8bc}
html[data-theme=dark] .route-saved-status,html[data-theme=dark] .route-result-card{border-color:#285c3c;background:#123322;color:#86efac}
html[data-theme=dark] .route-result-card>span{background:#18442b;color:#86efac}
html[data-theme=dark] .route-result-card small,html[data-theme=dark] .route-result-card strong,html[data-theme=dark] .route-result-card p{color:#a7d7b7}
html[data-theme=dark] .route-view-stop{background:var(--surface);color:var(--ink)}
html[data-theme=dark] .route-view-stop:hover,html[data-theme=dark] .route-view-stop:focus,html[data-theme=dark] .route-view-stop.active{background:var(--brand-light)}
html[data-theme=dark] .form-actions-sticky{background:rgba(17,27,44,.96);box-shadow:0 -5px 20px rgba(0,0,0,.2)}
html[data-theme=dark] .skip-link{background:#111b2c;color:#93c5fd}
html[data-theme=dark] .modal-content{background:var(--surface);color:var(--ink)}
html[data-theme=dark] .leaflet-tile-pane{filter:brightness(.7) contrast(1.15) saturate(.72)}
html[data-theme=dark] .leaflet-control-zoom a,html[data-theme=dark] .leaflet-control-attribution,html[data-theme=dark] .leaflet-popup-content-wrapper,html[data-theme=dark] .leaflet-popup-tip{background:#111b2c;color:var(--ink)}

/* Catálogo geográfico jerárquico */
.geo-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-bottom:18px}.geo-summary article{display:flex;align-items:center;gap:12px;padding:16px 18px;border:1px solid var(--line);border-radius:var(--radius);background:var(--surface);box-shadow:var(--shadow)}.geo-summary-icon{display:grid;place-items:center;width:42px;height:42px;border-radius:11px;background:var(--brand-light);color:var(--brand);font-size:1.05rem}.geo-summary strong,.geo-summary small{display:block}.geo-summary strong{font-size:1.25rem;line-height:1}.geo-summary small{margin-top:5px;color:var(--muted);font-size:.73rem}.geo-explorer{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;align-items:start}.geo-panel{min-width:0;overflow:hidden;border:1px solid var(--line);border-radius:var(--radius);background:var(--surface);box-shadow:var(--shadow)}.geo-panel-header{display:flex;align-items:center;justify-content:space-between;min-height:72px;padding:14px 16px;border-bottom:1px solid var(--line)}.geo-panel-header>div{display:flex;align-items:center;gap:10px;min-width:0}.geo-panel-header h2,.geo-panel-header small{display:block;margin:0}.geo-panel-header h2{font-size:.92rem;font-weight:750}.geo-panel-header small{max-width:210px;margin-top:3px;overflow:hidden;color:var(--muted);font-size:.67rem;text-overflow:ellipsis;white-space:nowrap}.geo-step{display:grid;place-items:center;width:28px;height:28px;flex:0 0 28px;border-radius:8px;background:var(--brand);color:#fff;font-size:.7rem;font-weight:800}.geo-filter{position:relative;margin:12px}.geo-filter i{position:absolute;top:50%;left:12px;color:var(--muted);font-size:.8rem;transform:translateY(-50%)}.geo-filter input{width:100%;height:38px;padding:0 12px 0 34px;border:1px solid var(--line);border-radius:8px;background:var(--canvas);color:var(--ink);font-size:.76rem;outline:0}.geo-filter input:focus{border-color:var(--brand);box-shadow:0 0 0 3px rgba(23,114,228,.12)}.geo-list{max-height:58vh;min-height:180px;overflow:auto;padding:0 8px 8px}.geo-record{position:relative;margin-bottom:6px;border:1px solid transparent;border-radius:9px;transition:border-color 150ms ease,background-color 150ms ease}.geo-record:hover{border-color:var(--line);background:var(--canvas)}.geo-record.active{border-color:rgba(23,114,228,.35);background:var(--brand-light)}.geo-record-main{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:10px;min-height:64px;padding:9px 70px 9px 9px;color:inherit;text-decoration:none}.geo-record-main.static{padding-right:70px}.geo-code{display:grid;place-items:center;min-width:42px;height:32px;padding:0 8px;border-radius:7px;background:var(--canvas);color:var(--brand);font-family:var(--bs-font-monospace);font-size:.68rem;font-weight:750}.geo-record-copy{min-width:0}.geo-record-copy strong,.geo-record-copy small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.geo-record-copy strong{font-size:.78rem}.geo-record-copy small{margin-top:3px;color:var(--muted);font-size:.63rem}.status-dot-label{display:inline-flex;align-items:center;gap:5px;font-size:.61rem;font-weight:700}.status-dot-label::before{width:6px;height:6px;border-radius:50%;content:""}.status-dot-label.active{color:#16834b}.status-dot-label.active::before{background:#22a861}.status-dot-label.inactive{color:var(--muted)}.status-dot-label.inactive::before{background:#98a2b3}.geo-record-actions{position:absolute;z-index:2;top:50%;right:8px;display:flex;gap:3px;transform:translateY(-50%)}.geo-record-actions form{display:inline-flex}.geo-record-actions .btn{width:28px;height:28px}.geo-empty{display:grid;place-items:center;min-height:180px;padding:25px;color:var(--muted);text-align:center}.geo-empty>i{margin-bottom:10px;font-size:1.6rem}.geo-empty strong{color:var(--ink);font-size:.8rem}.geo-empty p{max-width:220px;margin:5px 0 0;font-size:.7rem}.geo-empty.compact{min-height:100px}.geo-form-header{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-bottom:22px}.geo-form-header h1{margin:0;font-size:1.6rem}.geo-form-header p{margin:6px 0 0;color:var(--muted);font-size:.8rem}.geo-header-code{padding:8px 12px;border-radius:8px;background:var(--brand-light);color:var(--brand);font-family:var(--bs-font-monospace);font-size:.75rem;font-weight:800}.geo-form-card{max-width:920px}.form-section-heading{display:flex;align-items:center;gap:12px;margin-bottom:8px}.form-section-heading>span{display:grid;place-items:center;width:38px;height:38px;border-radius:10px;background:var(--brand-light);color:var(--brand)}.form-section-heading h2,.form-section-heading p{margin:0}.form-section-heading h2{font-size:1rem}.form-section-heading p{margin-top:3px;color:var(--muted);font-size:.7rem}.geo-active-switch{display:grid;grid-template-columns:auto 1fr;column-gap:9px;align-items:center;padding:12px 14px 12px 42px;border:1px solid var(--line);border-radius:9px;width:100%}.geo-active-switch .form-check-input{grid-row:1/3;margin-left:-28px}.geo-active-switch label{font-weight:700}.geo-active-switch small{color:var(--muted);font-size:.65rem}.geo-parent-context,.geo-context-path{display:flex;align-items:center;gap:12px;max-width:920px;margin-bottom:14px;padding:13px 16px;border:1px solid rgba(23,114,228,.2);border-radius:var(--radius);background:var(--brand-light)}.geo-parent-context>span,.geo-context-path>div>span{display:grid;place-items:center;width:34px;height:34px;float:left;margin-right:10px;border-radius:9px;background:#fff;color:var(--brand)}.geo-parent-context>div,.geo-context-path>div{min-width:0}.geo-parent-context small,.geo-parent-context strong,.geo-context-path small,.geo-context-path strong{display:block}.geo-parent-context small,.geo-context-path small{color:var(--muted);font-size:.62rem}.geo-parent-context strong,.geo-context-path strong{font-size:.76rem}.geo-parent-context code,.geo-context-path code{font-size:.62rem}.geo-context-path{gap:18px}.geo-context-path>div{flex:1}.geo-context-path>i{color:var(--muted)}
@media(max-width:1200px){.geo-explorer{grid-template-columns:1fr 1fr}.geo-panel:last-child{grid-column:1/-1}.geo-panel:last-child .geo-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px;max-height:42vh}}
@media(max-width:767px){.geo-summary{grid-template-columns:1fr}.geo-explorer{grid-template-columns:1fr}.geo-panel:last-child{grid-column:auto}.geo-panel:last-child .geo-list{display:block;max-height:58vh}.geo-list{max-height:46vh}.geo-form-header{align-items:flex-start;flex-direction:column}.geo-context-path{align-items:stretch;flex-direction:column}.geo-context-path>i{transform:rotate(90deg);align-self:center}.form-actions-sticky{gap:8px}.form-actions-sticky .btn{flex:1}.status-dot-label{display:none}}
html[data-theme=dark] .geo-summary article,html[data-theme=dark] .geo-panel{background:var(--surface)}html[data-theme=dark] .geo-filter input,html[data-theme=dark] .geo-code{background:#0e1728}html[data-theme=dark] .geo-record:hover{background:#172235}html[data-theme=dark] .geo-record.active{border-color:#315f94;background:var(--brand-light)}html[data-theme=dark] .geo-parent-context>span,html[data-theme=dark] .geo-context-path>div>span{background:#111b2c}

/* Formulario de clientes */
.customer-form,.customer-form-header{max-width:none}.customer-form-flow{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:1rem}.customer-form-flow>.customer-form-card{margin-top:0!important}.customer-form-card{padding:22px 24px}.customer-form-general{grid-column:span 7;order:1}.customer-form-contact{grid-column:span 5;order:2}.customer-form-observations,.customer-form-location,.customer-form-emails,.customer-form-commercial,.customer-form-accounting{grid-column:1/-1}.customer-form-observations{order:3}.customer-form-location{order:4}.customer-form-emails{order:5}.customer-form-commercial{order:6}.customer-form-accounting{order:7}.customer-form-card .form-section-heading{margin-bottom:16px;padding-bottom:15px;border-bottom:1px solid var(--line)}.customer-form-alert:empty{display:none}.customer-form-alert ul{margin:8px 0 0}.required-mark{margin-left:3px;color:var(--danger);font-weight:800}.field-help{display:block;margin-top:6px;color:var(--muted);font-size:.69rem;line-height:1.4}.field-validation{display:block;min-height:0;margin-top:5px;font-size:.7rem}.field-validation:empty{display:none}.locked-input,.input-with-icon{position:relative}.locked-input i{position:absolute;top:50%;right:13px;color:#8995a7;transform:translateY(-50%)}.locked-input .form-control{padding-right:40px;background:#f5f7fa;color:#526071}.input-with-icon>i{position:absolute;z-index:2;top:50%;left:13px;color:#8390a2;transform:translateY(-50%)}.input-with-icon .form-control{padding-left:39px}.location-select-status{display:flex;align-items:center;gap:8px;min-height:36px;padding:8px 11px;border-radius:8px;background:var(--brand-light);color:#466581;font-size:.7rem}.location-select-status i{color:var(--brand)}.location-empty-state{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;min-height:42px;border:1px dashed #cad4e1;border-radius:8px;color:var(--muted);font-size:.74rem}.character-counter{margin:6px 2px 0 auto;color:var(--muted);font-variant-numeric:tabular-nums;white-space:nowrap}.customer-form textarea{resize:vertical}.customer-form .form-actions-sticky{max-width:none}
@media(max-width:767px){.customer-form-header .customer-primary-actions{grid-template-columns:1fr}.customer-form-flow{display:flex;flex-direction:column}.customer-form-general{order:1}.customer-form-contact{order:2}.customer-form-observations{order:3}.customer-form-location{order:4}.customer-form-emails{order:5}.customer-form-commercial{order:6}.customer-form-accounting{order:7}.customer-form-card{padding:18px}.customer-form-card .form-section-heading{align-items:flex-start}.customer-form .form-actions-sticky{position:static;display:grid;grid-template-columns:1fr}.customer-form .form-actions-sticky .btn{width:100%}}
html[data-theme=dark] .locked-input .form-control{background:#172235;color:#aab7c9}html[data-theme=dark] .location-select-status{background:var(--brand-light);color:#b9cbe0}html[data-theme=dark] .location-empty-state{border-color:#3a4a60}

/* Gestión de usuarios */
.security-page-header,.security-user-form{max-width:1120px}.security-form-card{padding:22px 24px}.security-form-card .form-section-heading{margin-bottom:16px;padding-bottom:15px;border-bottom:1px solid var(--line)}.security-form-card .form-section-heading>div{flex:1}.optional-label{margin-bottom:6px;padding:2px 7px;border-radius:999px;background:#f1f4f8;color:var(--muted);font-size:.62rem;font-weight:700}.role-counter{width:auto!important;height:auto!important;padding:5px 8px!important;border-radius:999px!important;font-size:.64rem;font-weight:700;white-space:nowrap}.security-role-option{display:flex;align-items:center;gap:10px;min-height:58px;padding:10px 12px;border:1px solid var(--line);border-radius:9px;cursor:pointer}.security-role-option .form-check-input{flex:0 0 auto;margin:0}.security-role-option span,.security-role-option strong,.security-role-option small{display:block}.security-role-option strong{font-size:.76rem}.security-role-option small{margin-top:3px;color:var(--muted);font-size:.62rem}.security-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:16px}.security-summary>div{display:flex;align-items:center;gap:11px;padding:14px 16px;border:1px solid var(--line);border-radius:var(--radius);background:var(--surface);box-shadow:var(--shadow)}.security-summary>div>span{display:grid;place-items:center;width:36px;height:36px;flex:0 0 36px;border-radius:9px}.security-summary strong,.security-summary small{display:block}.security-summary strong{font-size:1.05rem}.security-summary small{margin-top:2px;color:var(--muted);font-size:.68rem}.security-users-card tbody tr{min-height:72px}.security-user-primary small{display:flex;align-items:center;gap:6px}.security-user-primary small i{width:12px;color:#8b98aa}.identity-chip{display:inline-flex;align-items:center;gap:7px;padding:5px 8px;border-radius:7px;background:var(--brand-light);color:var(--brand-hover);font-size:.72rem;font-weight:650}.missing-value{color:var(--muted);font-size:.72rem;font-style:italic}.security-role-list{display:flex;flex-wrap:wrap;gap:5px}.security-users-card .grid-actions{min-width:150px}.security-user-form .form-actions-sticky{max-width:1120px}
@media(max-width:767px){.security-summary{grid-template-columns:1fr}.security-form-card{padding:18px}.security-form-card .form-section-heading{align-items:flex-start;flex-wrap:wrap}.role-counter{margin-left:50px}.security-user-form .form-actions-sticky{position:static;display:grid;grid-template-columns:1fr}.security-user-form .form-actions-sticky .btn{width:100%}.security-users-card .table{min-width:860px}}
html[data-theme=dark] .optional-label{background:#202c3e}html[data-theme=dark] .security-summary>div{background:var(--surface)}html[data-theme=dark] .security-role-option{border-color:var(--line)}html[data-theme=dark] .identity-chip{background:var(--brand-light);color:#93c5fd}

/* Route geographic customer picker */
.route-customer-picker{margin-bottom:16px;padding:16px 18px;border:1px solid var(--line);border-radius:var(--radius);background:#fff;box-shadow:var(--shadow)}
.route-picker-heading{display:flex;align-items:center;gap:11px;margin-bottom:14px}.route-picker-heading>span{display:grid;place-items:center;width:34px;height:34px;flex:0 0 34px;border-radius:9px;background:var(--brand-light);color:var(--brand)}.route-picker-heading h2,.route-picker-heading p{margin:0}.route-picker-heading p{margin-top:3px;color:var(--muted);font-size:.72rem}
.route-picker-grid{display:grid;grid-template-columns:minmax(135px,.8fr) minmax(150px,1fr) minmax(150px,1fr) minmax(260px,1.7fr) auto;align-items:end;gap:12px}.route-picker-grid .action-button{height:42px;white-space:nowrap}.route-picker-help{display:flex;align-items:center;gap:7px;margin-top:11px;color:var(--muted);font-size:.72rem}.route-picker-help i{color:var(--brand)}
.route-location-status{display:inline-flex!important;align-items:center;gap:4px;width:max-content;margin-top:5px!important;padding:2px 6px;border-radius:999px;font-size:.61rem!important;font-weight:700}.route-location-status.located{background:#e9f8ee;color:#166534}.route-location-status.unlocated{background:#fff4df;color:#9a5b00}
html[data-theme=dark] .route-customer-picker{background:var(--surface)}html[data-theme=dark] .route-location-status.located{background:#143321;color:#86efac}html[data-theme=dark] .route-location-status.unlocated{background:#3a2a10;color:#facc77}
@media(max-width:1200px){.route-picker-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.route-customer-field{grid-column:span 2}}
@media(max-width:767px){.route-picker-grid{grid-template-columns:1fr}.route-customer-field{grid-column:auto}.route-picker-grid .action-button{width:100%}}
/* Dark theme card and nested component corrections */
html[data-theme=dark] .detail-card,
html[data-theme=dark] .card{
    border-color:var(--line);
    background:var(--surface);
    color:var(--ink);
}
html[data-theme=dark] .detail-hero{
    border-color:#29496e;
    background:linear-gradient(90deg,#12243c,var(--surface));
}
html[data-theme=dark] .detail-card-title{
    border-color:var(--line);
}
html[data-theme=dark] .detail-grid dt,
html[data-theme=dark] .detail-observation{
    color:#b7c3d4;
}
html[data-theme=dark] .detail-badges span,
html[data-theme=dark] .text-bg-light{
    background:#202c3e!important;
    color:#c7d2e1!important;
}
html[data-theme=dark] .detail-badges span.located{
    background:#123322!important;
    color:#86efac!important;
}
html[data-theme=dark] .status-pill.danger{
    background:#3d1d24;
    color:#fca5a5;
}
html[data-theme=dark] .nav-tabs{
    --bs-nav-tabs-border-color:var(--line);
    --bs-nav-tabs-link-hover-border-color:#34445b #34445b var(--line);
    --bs-nav-tabs-link-active-color:var(--ink);
    --bs-nav-tabs-link-active-bg:var(--surface);
    --bs-nav-tabs-link-active-border-color:var(--line) var(--line) var(--surface);
}
html[data-theme=dark] .nav-tabs .nav-link{
    color:#aab7c9;
}
html[data-theme=dark] .nav-tabs .nav-link:hover,
html[data-theme=dark] .nav-tabs .nav-link:focus{
    color:#fff;
}
html[data-theme=dark] .action-map,
html[data-theme=dark] .btn-outline-secondary{
    border-color:#3a4a60;
    background:var(--surface);
    color:#b8c4d4;
}
html[data-theme=dark] .action-map:hover,
html[data-theme=dark] .action-map:focus-visible,
html[data-theme=dark] .btn-outline-secondary:hover,
html[data-theme=dark] .btn-outline-secondary:focus-visible{
    border-color:#52749b;
    background:#1a2940;
    color:#fff;
}

/* Authentication workspace */
.auth-page{min-height:100vh;background:#f5f7fb;overflow-x:hidden}.auth-shell{min-height:100vh;display:grid;grid-template-columns:minmax(480px,1.08fr) minmax(460px,.92fr)}.auth-brand-panel{position:relative;display:flex;min-height:100vh;padding:clamp(38px,5vw,76px);overflow:hidden;color:#fff;background:linear-gradient(145deg,#071426 0%,#0d2b52 52%,#125db8 100%)}.auth-brand-panel::before{position:absolute;inset:0;content:"";opacity:.18;background-image:linear-gradient(rgba(255,255,255,.07) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.07) 1px,transparent 1px);background-size:52px 52px;mask-image:linear-gradient(to bottom,transparent 4%,#000 30%,#000 75%,transparent 100%)}.auth-brand-glow{position:absolute;border-radius:50%;filter:blur(2px);pointer-events:none}.auth-brand-glow-one{top:-160px;right:-100px;width:420px;height:420px;background:rgba(51,148,255,.2)}.auth-brand-glow-two{bottom:-220px;left:-140px;width:480px;height:480px;background:rgba(29,203,183,.12)}.auth-brand-glow-three{top:45%;right:10%;width:300px;height:300px;background:rgba(192,132,252,.08)}.auth-brand-inner{position:relative;z-index:1;width:min(100%,720px);margin:auto;display:flex;min-height:min(760px,calc(100vh - 100px));flex-direction:column;justify-content:center}.auth-brand{position:absolute;top:0;left:0;display:flex;align-items:center;gap:13px}.auth-brand-mark{display:grid;place-items:center;width:44px;height:44px;flex:0 0 44px;border:1px solid rgba(255,255,255,.24);border-radius:13px;color:#fff;background:rgba(255,255,255,.13);box-shadow:0 12px 28px rgba(2,8,23,.18);font-size:1.15rem}.auth-brand-name{display:flex;flex-direction:column;color:#fff;font-size:1.03rem;font-weight:750;letter-spacing:-.01em}.auth-brand-name small{margin-top:2px;color:#afc7e7;font-size:.67rem;font-weight:500;letter-spacing:.04em}.auth-brand-copy{max-width:650px}.auth-kicker{margin:0 0 16px;color:#7dd3fc;font-size:.7rem;font-weight:800;letter-spacing:.16em}.auth-brand-copy h1{max-width:620px;margin:0;font-size:clamp(2.25rem,3.4vw,3.85rem);font-weight:760;line-height:1.08;letter-spacing:-.045em}.auth-brand-copy>p:last-child{max-width:570px;margin:22px 0 0;color:#c7d8ed;font-size:clamp(.94rem,1.2vw,1.08rem);line-height:1.7}.auth-route-visual,.auth-erp-hub{position:relative;height:240px;margin:22px 0 12px}.auth-erp-hub .hub-connections{position:absolute;inset:0;width:100%;height:100%;overflow:visible}.hub-line{stroke:rgba(114,217,255,.35);stroke-width:2;stroke-dasharray:4 6}.hub-center-glow{fill:rgba(23,114,228,.28)}.hub-center-node{fill:#38bdf8;stroke:#fff;stroke-width:3}.erp-module-pill{position:absolute;display:inline-flex;align-items:center;gap:7px;padding:7px 13px;border:1px solid rgba(255,255,255,.18);border-radius:999px;background:rgba(8,25,50,.78);box-shadow:0 8px 24px rgba(2,8,23,.28);backdrop-filter:blur(8px);color:#f0f7ff;font-size:.74rem;font-weight:650;transition:transform 200ms ease,background-color 200ms ease}.erp-module-pill:hover{transform:scale(1.05);background:rgba(23,114,228,.35);border-color:rgba(125,211,252,.4)}.erp-module-pill i{font-size:.86rem;color:#7dd3fc}.pill-accounting i{color:#a7f3d0}.pill-logistics i{color:#fde047}.pill-sales i{color:#93c5fd}.pill-imports i{color:#f472b6}.pill-production i{color:#fb923c}.pill-hr i{color:#c084fc}.op-card-one{left:4%;bottom:-10px}.op-card-two{right:0;top:-10px}.op-card-one i{color:#86efac;background:rgba(34,197,94,.16)}.op-card-two i{color:#93c5fd;background:rgba(59,130,246,.16)}.auth-route-visual svg{position:absolute;inset:0;width:100%;height:100%;overflow:visible}.route-line{fill:none;stroke:#72d9ff;stroke-width:3;stroke-linecap:round;stroke-dasharray:8 10}.route-line-shadow{stroke:rgba(96,165,250,.18);stroke-width:15;stroke-dasharray:none}.route-halo{fill:rgba(125,211,252,.16)}.route-node{fill:#c7f2ff;stroke:#1772e4;stroke-width:3}.route-halo-active{fill:rgba(52,211,153,.16)}.route-node-active{fill:#6ee7b7;stroke:#0f766e}.route-card{position:absolute;display:flex;align-items:center;gap:10px;min-width:178px;padding:11px 13px;border:1px solid rgba(255,255,255,.15);border-radius:12px;background:rgba(5,20,43,.72);box-shadow:0 14px 32px rgba(2,8,23,.2);backdrop-filter:blur(10px)}.route-card i{display:grid;place-items:center;width:31px;height:31px;border-radius:999px;color:#a5ecff;background:rgba(56,189,248,.14)}.route-card span{display:flex;flex-direction:column;color:#f8fbff;font-size:.75rem;font-weight:700}.route-card small{margin-top:3px;color:#9eb6d3;font-size:.64rem;font-weight:500}.route-card-one{left:6%;bottom:4px}.route-card-two{right:0;top:16px}.route-card-two i{color:#86efac;background:rgba(34,197,94,.14)}.auth-benefits{display:flex;flex-wrap:wrap;gap:12px 22px;margin:12px 0 0;padding:0;list-style:none;color:#dbeafe;font-size:.78rem;font-weight:600}.auth-benefits li{display:flex;align-items:center;gap:7px}.auth-benefits i{display:grid;place-items:center;width:20px;height:20px;border-radius:50%;color:#86efac;background:rgba(34,197,94,.14);font-size:.82rem}.auth-form-panel{position:relative;display:flex;min-height:100vh;padding:56px clamp(30px,5vw,78px) 76px;align-items:center;justify-content:center;background:radial-gradient(circle at 100% 0,rgba(23,114,228,.08),transparent 34%),var(--canvas)}.auth-content{width:min(100%,480px)}.auth-content .login-card{width:100%;max-width:none;margin:0;padding:42px;border-color:rgba(203,213,225,.82);border-radius:20px;box-shadow:0 24px 70px rgba(15,23,42,.11)}.session-expired-alert{width:min(100%,480px);margin:0 auto 16px}.login-mobile-brand{display:none}.login-heading h1{margin:0 0 10px;font-size:2rem}.login-heading .text-secondary{margin:0;line-height:1.55}.login-form{margin-top:30px}.login-form .alert:empty{display:none}.login-input-group{border-radius:10px;transition:box-shadow 180ms ease}.login-input-group:focus-within{border-radius:10px;box-shadow:0 0 0 3px rgba(23,114,228,.14)}.login-input-group .input-group-text{min-width:44px;justify-content:center;border-color:#cfd8e5;border-right:0;border-radius:10px 0 0 10px;color:#7b8798;background:#f8fafc}.login-input-group .form-control,.login-input-group .form-select{min-height:46px}.login-input-group .input-group-text+.form-control,.login-input-group .input-group-text+.form-select{border-left:0}.login-input-group .form-control:focus,.login-input-group .form-select:focus{box-shadow:none!important}.login-input-group .password-toggle{min-width:46px;border-color:#cfd8e5;border-radius:0 10px 10px 0;color:#64748b;background:#fff}.login-input-group .password-toggle:hover{color:var(--brand);background:var(--brand-light)}.login-remember{margin:20px 0 24px}.login-remember .form-check-label{color:var(--muted);font-size:.8rem}.login-submit{display:flex;width:100%;min-height:48px;align-items:center;justify-content:center;gap:10px;border-radius:10px;box-shadow:0 10px 24px rgba(23,114,228,.2)}.login-submit i{transition:transform 180ms ease}.login-submit:hover i{transform:translateX(3px)}.login-security-note{display:flex;align-items:center;justify-content:center;gap:7px;margin-top:24px;padding-top:20px;border-top:1px solid #edf1f5;color:#8390a2;font-size:.7rem}.login-security-note i{color:#16a34a}.auth-footer{position:absolute;right:0;bottom:24px;left:0;color:#94a3b8;text-align:center;font-size:.68rem}.auth-footer i{color:#16a34a}
html[data-theme=dark] .auth-form-panel{background:radial-gradient(circle at 100% 0,rgba(23,114,228,.12),transparent 34%),var(--canvas)}html[data-theme=dark] .login-input-group .input-group-text,html[data-theme=dark] .login-input-group .password-toggle{border-color:#34445b;background:#111b2c;color:#9fb0c6}html[data-theme=dark] .login-security-note{border-color:#243247}
@media(max-width:1100px){.auth-shell{grid-template-columns:minmax(430px,.9fr) minmax(440px,1.1fr)}.auth-brand-panel{padding:42px}.auth-brand-copy h1{font-size:2.55rem}.route-card{transform:scale(.92)}.auth-benefits{gap:10px 14px}}
@media(max-width:899px){.auth-shell{display:block}.auth-brand-panel{display:none}.auth-form-panel{min-height:100vh;padding:50px 24px 68px}.login-mobile-brand{display:flex;align-items:center;justify-content:center;gap:11px;margin:0 auto 22px;color:var(--ink);font-size:1rem;font-weight:750}.login-mobile-brand .auth-brand-mark{width:40px;height:40px;flex-basis:40px;border:0;background:var(--brand)}.login-mobile-brand>span:last-child{display:flex;flex-direction:column}.login-mobile-brand small{margin-top:2px;color:var(--muted);font-size:.64rem;font-weight:500}.auth-content .login-card{padding:36px}.auth-footer{bottom:20px}}
@media(max-width:575px){.auth-form-panel{align-items:flex-start;padding:28px 16px 60px}.auth-content .login-card{padding:27px 22px;border-radius:16px}.login-mobile-brand{justify-content:flex-start;width:100%;margin-bottom:20px}.login-heading h1{font-size:1.75rem}.login-form{margin-top:24px}.auth-footer{bottom:16px}.session-expired-alert{margin-bottom:12px}}
@media(max-height:720px) and (min-width:900px){.auth-brand-panel,.auth-form-panel{padding-top:32px;padding-bottom:46px}.auth-brand-inner{min-height:calc(100vh - 64px)}.auth-route-visual{height:150px;margin-top:12px}.auth-content .login-card{padding:30px 36px}.login-form{margin-top:22px}.auth-footer{bottom:14px}}
/* Notification center */
.notification-dropdown{position:relative}
.notification-badge{position:absolute;top:-6px;right:-7px;min-width:19px;height:19px;padding:0 5px;border:2px solid #fff;border-radius:10px;background:var(--danger);color:#fff;font-size:.65rem;font-weight:800;line-height:15px;text-align:center}
.notification-menu{width:min(390px,calc(100vw - 24px));padding:0;overflow:hidden;border:1px solid var(--line);border-radius:12px;box-shadow:0 18px 46px rgba(15,23,42,.16)}
.notification-menu-header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px;border-bottom:1px solid var(--line)}
.notification-menu-header strong,.notification-menu-header small{display:block}.notification-menu-header small{margin-top:2px;color:var(--muted);font-size:.72rem}
.notification-menu-header button{padding:0;border:0;background:transparent;color:var(--brand);font-size:.72rem;font-weight:650}
.notification-list{max-height:390px;overflow-y:auto}
.notification-item{display:flex;gap:11px;padding:13px 16px;border-bottom:1px solid var(--line);color:var(--ink);text-decoration:none}
.notification-item:hover{background:#f8fafc;color:var(--ink)}
.notification-item.unread{background:var(--brand-light)}
.notification-item-icon{display:grid;place-items:center;width:34px;height:34px;flex:0 0 34px;border-radius:9px;background:#eaf3ff;color:var(--brand)}
.notification-item-copy{min-width:0}.notification-item-copy strong,.notification-item-copy small{display:block}
.notification-item-copy strong{font-size:.82rem}.notification-item-copy small{margin-top:3px;color:var(--muted);font-size:.72rem}
.notification-item-copy .message{white-space:normal}.notification-item-copy .date{font-size:.66rem}
.notification-empty{padding:34px 18px;text-align:center;color:var(--muted)}
.notification-empty i,.notification-empty strong,.notification-empty small{display:block}.notification-empty i{margin-bottom:8px;font-size:1.4rem}.notification-empty strong{color:var(--ink)}.notification-empty small{margin-top:4px}
.notification-toasts{z-index:1090}.notification-toasts .toast{position:relative;background:rgba(255,255,255,.96);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border:1px solid #dce4ee;border-left:4px solid var(--brand,#1772e4);border-radius:12px;box-shadow:0 12px 32px -4px rgba(15,23,42,.12),0 4px 12px -2px rgba(15,23,42,.06);overflow:hidden;transition:transform 220ms ease,box-shadow 220ms ease}.notification-toasts .toast:hover{box-shadow:0 16px 40px -4px rgba(15,23,42,.16),0 6px 16px -2px rgba(15,23,42,.08);transform:translateY(-2px)}.notification-toasts .toast-header{display:flex;align-items:center;padding:12px 14px 4px;background:transparent;border-bottom:0;color:var(--ink,#1e293b)}.notification-toasts .toast-icon-badge{display:grid;place-items:center;width:26px;height:26px;margin-right:10px;border-radius:7px;background:var(--brand-light,#eaf3ff);color:var(--brand,#1772e4);font-size:.78rem;flex-shrink:0}.notification-toasts .toast-title{font-size:.84rem;font-weight:700;color:var(--ink,#0f172a);letter-spacing:-.01em}.notification-toasts .toast-body{padding:2px 14px 12px 50px;font-size:.81rem;line-height:1.45;color:#475569}.notification-toasts .btn-close{font-size:.7rem;opacity:.6;padding:6px;margin:-4px -4px 0 0;transition:opacity 150ms ease}.notification-toasts .btn-close:hover{opacity:1}
.notification-settings-form .permission-option{height:100%}
html[data-theme=dark] .notification-menu{background:#111b2c}html[data-theme=dark] .notification-item:hover{background:#18243a}html[data-theme=dark] .notification-item.unread{background:rgba(23,114,228,.16)}html[data-theme=dark] .notification-badge{border-color:#111b2c}html[data-theme=dark] .notification-toasts .toast{background:rgba(17,27,44,.94);border-color:#27374d;border-left-color:#3b82f6;box-shadow:0 14px 38px rgba(0,0,0,.45)}html[data-theme=dark] .notification-toasts .toast-title{color:#f1f5f9}html[data-theme=dark] .notification-toasts .toast-body{color:#94a3b8}html[data-theme=dark] .notification-toasts .toast-icon-badge{background:rgba(23,114,228,.22);color:#60a5fa}html[data-theme=dark] .notification-toasts .btn-close{filter:invert(1) grayscale(100%) brightness(200%)}

/* Roles and Permissions editor */
.permissions-container{display:flex;flex-direction:column;gap:20px}
.permissions-toolbar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:14px;padding:16px;background:#fff;border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}
.permissions-search-wrap{flex:1;min-width:280px;position:relative;display:flex;align-items:center}
.permissions-search-wrap>i{position:absolute;left:14px;color:#8390a2;pointer-events:none}
.permissions-search-wrap input{width:100%;height:42px;padding:0 40px 0 42px;border:1px solid #cfd8e5;border-radius:9px;outline:0;color:var(--ink);background:#fff;font-size:.88rem;transition:border-color 180ms ease,box-shadow 180ms ease}
.permissions-search-wrap input:focus{border-color:#61a0ed;box-shadow:0 0 0 3px rgba(23,114,228,.14)}
.permissions-search-clear{position:absolute;right:10px;display:grid;place-items:center;width:24px;height:24px;border:0;border-radius:6px;background:transparent;color:#7b8798;cursor:pointer}
.permissions-search-clear:hover{background:#eef2f6;color:var(--ink)}
.permissions-actions{display:flex;align-items:center;flex-wrap:wrap;gap:8px}
.permission-counter-chip{display:inline-flex;align-items:center;gap:7px;padding:6px 12px;border-radius:8px;background:var(--brand-light);color:var(--brand);font-size:.82rem;font-weight:700}
.permission-counter-chip i{font-size:.92rem}
.permission-module-card{background:#fff;border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow);overflow:hidden;transition:border-color 180ms ease}
.permission-module-card.is-empty{display:none}
.permission-module-header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 18px;background:#f8fafc;border-bottom:1px solid var(--line)}
.permission-module-title{display:flex;align-items:center;gap:10px;font-size:.95rem;font-weight:700;color:var(--ink)}
.permission-module-icon{display:grid;place-items:center;width:34px;height:34px;border-radius:9px;background:var(--brand-light);color:var(--brand);font-size:1rem}
.permission-module-badge{padding:3px 8px;border-radius:6px;background:#e2e8f0;color:#475569;font-size:.72rem;font-weight:650}
.permission-module-actions{display:flex;align-items:center;gap:8px}
.permission-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(290px,1fr));gap:12px;padding:16px}
.permission-tile{position:relative;display:flex;align-items:flex-start;gap:11px;padding:13px 15px;border:1px solid #cfd8e5;border-radius:9px;background:#fff;cursor:pointer;user-select:none;transition:all 160ms ease}
.permission-tile:hover{border-color:#93c5fd;background:#f8fafc;transform:translateY(-1px);box-shadow:0 3px 8px rgba(15,23,42,.04)}
.permission-tile:has(input:checked){border-color:#60a5fa;background:var(--brand-light);box-shadow:0 2px 6px rgba(23,114,228,.08)}
.permission-tile.is-disabled{opacity:.65;cursor:not-allowed;pointer-events:none}
.permission-tile input[type=checkbox]{margin-top:3px;width:18px;height:18px;accent-color:var(--brand);cursor:pointer;flex:0 0 18px}
.permission-tile-content{display:flex;flex-direction:column;gap:3px;min-width:0;flex:1}
.permission-tile-name{font-size:.84rem;font-weight:650;color:var(--ink);line-height:1.3}
.permission-tile-sub{font-size:.72rem;color:var(--muted);display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.permission-action-badge{display:inline-flex;align-items:center;padding:2px 6px;border-radius:4px;font-size:.66rem;font-weight:750;letter-spacing:.02em;text-transform:uppercase}
.action-view{background:#e0f2fe;color:#0369a1}
.action-create{background:#dcfce7;color:#15803d}
.action-edit{background:#fef3c7;color:#b45309}
.action-delete{background:#fee2e2;color:#b91c1c}
.action-manage{background:#f3e8ff;color:#6b21a8}
.action-audit{background:#e0e7ff;color:#3730a3}

html[data-theme=dark] .permissions-toolbar,html[data-theme=dark] .permission-module-card{background:var(--surface);border-color:var(--line)}
html[data-theme=dark] .permissions-search-wrap input{background:#0e1728;border-color:#34445b;color:var(--ink)}
html[data-theme=dark] .permissions-search-clear:hover{background:#1e293b;color:var(--ink)}
html[data-theme=dark] .permission-module-header{background:#172235;border-color:var(--line);color:var(--ink)}
html[data-theme=dark] .permission-module-title{color:var(--ink)}
html[data-theme=dark] .permission-module-badge{background:#27374d;color:#94a3b8}
html[data-theme=dark] .permission-tile{background:#0e1728;border-color:#2a384c}
html[data-theme=dark] .permission-tile:hover{background:#172235;border-color:#3b82f6}
html[data-theme=dark] .permission-tile:has(input:checked){background:#172c49;border-color:#3b82f6}
html[data-theme=dark] .action-view{background:#0c4a6e;color:#7dd3fc}
html[data-theme=dark] .action-create{background:#14532d;color:#86efac}
html[data-theme=dark] .action-edit{background:#78350f;color:#fde047}
html[data-theme=dark] .action-delete{background:#7f1d1d;color:#fca5a5}

/* Global Module Search Palette */
.global-search{position:relative}
.module-search-results{position:absolute;top:calc(100% + 8px);left:0;right:0;width:max(100%,380px);max-height:380px;overflow-y:auto;background:#fff;border:1px solid var(--line);border-radius:12px;box-shadow:0 16px 40px rgba(15,23,42,.16);z-index:1050;padding:6px}
.module-search-results.is-empty{padding:18px 14px;text-align:center;color:var(--muted);font-size:.84rem}
.module-search-group-label{padding:6px 10px 4px;font-size:.66rem;font-weight:750;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}
.module-search-item{display:flex;align-items:center;gap:11px;padding:9px 12px;border-radius:8px;color:var(--ink);text-decoration:none;transition:background-color 150ms ease,color 150ms ease;cursor:pointer}
.module-search-item:hover,.module-search-item.is-selected{background:var(--brand-light);color:var(--brand-hover);outline:0}
.module-search-icon{display:grid;place-items:center;width:32px;height:32px;border-radius:8px;background:rgba(23,114,228,.08);color:var(--brand);font-size:.95rem;flex-shrink:0}
.module-search-item.is-selected .module-search-icon{background:var(--brand);color:#fff}
.module-search-content{display:flex;flex-direction:column;min-width:0;flex:1}
.module-search-title{font-size:.86rem;font-weight:650;line-height:1.2}
.module-search-section{font-size:.72rem;color:var(--muted);margin-top:2px}
.module-search-enter{font-size:.78rem;color:var(--muted);opacity:.7}

html[data-theme=dark] .module-search-results{background:var(--surface);border-color:var(--line);box-shadow:0 16px 40px rgba(0,0,0,.45)}
html[data-theme=dark] .module-search-item:hover,html[data-theme=dark] .module-search-item.is-selected{background:#172c49;color:#60a5fa}
html[data-theme=dark] .module-search-icon{background:rgba(59,130,246,.15);color:#60a5fa}

/* Agenda Module Enhancements */
.compact-stat-card{min-height:72px!important;padding:12px 14px!important;display:flex!important;flex-direction:row!important;align-items:center!important;gap:12px!important}
.compact-stat-card .metric-icon{width:40px;height:40px;flex:0 0 40px;font-size:1.15rem;margin:0}
.compact-stat-card small{display:block;margin-bottom:2px;font-size:.7rem;font-weight:700;letter-spacing:.03em;text-transform:uppercase}
.compact-stat-card strong{font-size:1.45rem;line-height:1;margin:0}

.calendar-day-card{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);overflow:hidden}
.calendar-day-header{padding:10px 14px;background:var(--bs-secondary-bg,#f8fafc);border-bottom:1px solid var(--line);color:var(--ink)}
.calendar-day-header.is-today{background:var(--brand-light);color:var(--brand-hover);border-color:#a9cbee}
.agenda-event-card{padding:10px 12px;border:1px solid var(--line);border-radius:8px;background:var(--surface);color:var(--ink);margin-bottom:8px;transition:all 180ms ease}
.agenda-event-card:hover{border-color:var(--brand);box-shadow:var(--shadow)}
.agenda-event-card.status-completed{opacity:.85;border-left:4px solid var(--success)}
.agenda-event-card.status-overdue{border-left:4px solid var(--danger)}
.agenda-event-card.status-pending{border-left:4px solid var(--warning)}

html[data-theme=dark] .calendar-day-header{background:#172235;border-color:var(--line);color:var(--ink)}
html[data-theme=dark] .calendar-day-header.is-today{background:#1e3a8a;color:#93c5fd}
html[data-theme=dark] .agenda-event-card{background:#0e1728;border-color:#2a384c;color:var(--ink)}
.agenda-details-modal .modal-header,.agenda-details-modal .modal-footer{border-color:var(--line)}
.agenda-details-modal dt{color:var(--muted);font-size:.78rem}
.agenda-details-modal dd{color:var(--ink)}
.agenda-details-completion{border-color:#b9dec8!important;background:#f3fbf6}
html[data-theme=dark] .agenda-details-modal .modal-header,html[data-theme=dark] .agenda-details-modal .modal-footer{border-color:#2a384c}
html[data-theme=dark] .agenda-details-modal .btn-close{filter:invert(1) grayscale(100%) brightness(200%)}
html[data-theme=dark] .agenda-details-modal dt{color:#aebbd0}
html[data-theme=dark] .agenda-details-modal .text-secondary{color:#aebbd0!important}
html[data-theme=dark] .agenda-details-completion{border-color:#285c3c!important;background:#123322;color:#d2eadb}
html[data-theme=dark] .agenda-details-completion h6,html[data-theme=dark] .agenda-details-completion dd{color:#e0f4e7}

/* Overdue task theme styling */
.table-card tbody tr.row-overdue{background:#fff5f5;color:var(--ink)}
.table-card tbody tr.row-overdue:hover{background:#fee2e2}
.agenda-event-card.status-overdue{border-left:4px solid var(--danger);background:#fff9f9}

html[data-theme=dark] .table-card tbody tr.row-overdue{background:#2a1619;color:var(--ink)}
html[data-theme=dark] .table-card tbody tr.row-overdue:hover{background:#3b1c21}
html[data-theme=dark] .agenda-event-card.status-overdue{background:#211215;border-color:#4a2027;border-left-color:var(--danger)}
.status-pill.danger{color:#b42318;background:#fff0ef}
.status-pill.info{color:#1d4ed8;background:#eaf2ff}
.readonly-field,.form-control[readonly],.form-control:disabled,.form-select:disabled{background-color:#f1f5f9!important;border-color:#cbd5e1!important;color:#475569!important;opacity:1;cursor:not-allowed}
.readonly-field:focus,.form-control[readonly]:focus{box-shadow:none!important}
#quotation-customer-available{color:#15803d!important}
html[data-theme=dark] #quotation-customer-available{color:#86efac!important}
.form-check-input:disabled,.form-check-input:disabled~.form-check-label{opacity:1;cursor:not-allowed}
.form-check-input:disabled{background-color:#e2e8f0;border-color:#94a3b8}
.form-check-input:disabled:checked{background-color:#64748b;border-color:#64748b}
html[data-theme=dark] .readonly-field,html[data-theme=dark] .form-control[readonly],html[data-theme=dark] .form-control:disabled,html[data-theme=dark] .form-select:disabled{background-color:#202c3e!important;border-color:#34445b!important;color:#b5c1d1!important}
html[data-theme=dark] .form-check-input:disabled{background-color:#202c3e;border-color:#64748b}
html[data-theme=dark] .form-check-input:disabled:checked{background-color:#64748b;border-color:#94a3b8}
.readonly-select .remote-select-control{border-color:#cbd5e1;background:#f1f5f9;box-shadow:none;cursor:not-allowed}
.readonly-select .remote-select-control:focus-within{border-color:#cbd5e1;box-shadow:none}
.readonly-select .remote-query{color:#475569;cursor:not-allowed}
.readonly-select .remote-clear{cursor:not-allowed}
html[data-theme=dark] .readonly-select .remote-select-control{border-color:#34445b;background:#202c3e}
html[data-theme=dark] .readonly-select .remote-query{color:#b5c1d1}

/* Minimal login presentation panel */
.auth-brand-panel>.auth-brand-glow,.auth-brand-panel>.auth-brand-inner{display:none}
.auth-minimal-panel{position:relative;z-index:1;display:flex;width:min(100%,620px);min-height:min(680px,calc(100vh - 110px));margin:auto;flex-direction:column;color:#e6edf6}
.auth-minimal-header{display:flex;align-items:center;gap:12px;color:#fff;font-size:1rem;font-weight:750;letter-spacing:-.01em}.auth-minimal-header>span:last-child{display:flex;flex-direction:column}.auth-minimal-header small{margin-top:3px;color:#9eb3cc;font-size:.67rem;font-weight:500;letter-spacing:.04em}
.auth-minimal-mark{display:grid;place-items:center;width:42px;height:42px;border:1px solid rgba(191,219,254,.26);border-radius:11px;color:#dbeafe;background:rgba(255,255,255,.07);font-size:1rem}
.auth-minimal-content{width:min(100%,510px);margin:auto 0}.auth-minimal-kicker{margin:0 0 15px;color:#93c5fd;font-size:.68rem;font-weight:800;letter-spacing:.15em}.auth-minimal-content h1{margin:0;color:#fff;font-size:clamp(2.2rem,3.2vw,3.45rem);font-weight:720;line-height:1.13;letter-spacing:-.045em}
.auth-minimal-content>p:not(.auth-minimal-kicker){max-width:470px;margin:20px 0 0;color:#b9c9dc;font-size:1rem;line-height:1.7}.auth-minimal-divider{width:52px;height:2px;margin:30px 0 20px;background:#60a5fa}.auth-minimal-list{display:grid;gap:10px;margin:0;padding:0;list-style:none;color:#d9e5f2;font-size:.81rem;font-weight:600}
.auth-minimal-list li{display:flex;align-items:center;gap:9px}.auth-minimal-list i{color:#7dd3fc;font-size:1rem}.auth-minimal-footer{display:flex;align-items:center;gap:7px;color:#94a9c0;font-size:.7rem}.auth-minimal-footer i{color:#86efac;font-size:.82rem}
@media(max-width:899px){.auth-minimal-panel{display:none}}

/* Agenda filters */
.agenda-filter-grid{display:grid;grid-template-columns:minmax(260px,1.45fr) 148px 148px 190px 190px auto;gap:10px;width:100%;align-items:center}.agenda-filter-grid.with-user-filter{grid-template-columns:minmax(260px,1.45fr) 148px 148px 190px 190px 210px auto}.agenda-filter-grid>*{min-width:0}.agenda-search-control input{padding-right:16px}.agenda-filter-grid .form-control,.agenda-filter-grid .form-select{width:100%;height:44px}.agenda-filter-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;white-space:nowrap}.agenda-filter-actions .action-button{height:44px}.agenda-filter-actions .btn-group{display:flex}.agenda-filter-actions .btn-group .btn{height:44px;white-space:nowrap}
@media(max-width:1480px){.agenda-filter-grid,.agenda-filter-grid.with-user-filter{grid-template-columns:repeat(6,minmax(0,1fr))}.agenda-search-field{grid-column:1/-1}.agenda-filter-actions{grid-column:span 2}.agenda-filter-grid.with-user-filter .agenda-filter-actions{grid-column:1/-1;justify-content:flex-end}.agenda-filter-actions .action-button{padding-right:12px;padding-left:12px}.agenda-filter-actions .btn-group .btn{padding-right:10px;padding-left:10px}}
@media(max-width:1100px){.agenda-filter-grid,.agenda-filter-grid.with-user-filter{grid-template-columns:repeat(2,minmax(0,1fr))}.agenda-search-field,.agenda-filter-actions{grid-column:1/-1}.agenda-filter-actions{justify-content:flex-end}}
@media(max-width:700px){.agenda-filter-actions{justify-content:space-between}.agenda-filter-actions .action-button{flex:1}.agenda-filter-actions .btn-group{flex:1}.agenda-filter-actions .btn-group .btn{flex:1}}
@media(max-width:420px){.agenda-filter-grid,.agenda-filter-grid.with-user-filter{grid-template-columns:1fr}.agenda-filter-actions{flex-direction:column}.agenda-filter-actions .action-button,.agenda-filter-actions .btn-group{width:100%}}



/* Login presentation panel: ambient network composition */
.auth-brand-panel{isolation:isolate;background:radial-gradient(circle at 78% 15%,rgba(42,149,255,.25),transparent 32%),radial-gradient(circle at 9% 88%,rgba(23,201,183,.16),transparent 35%),linear-gradient(132deg,#071426 0%,#0b2446 52%,#123d73 100%)}
.auth-brand-panel::before{z-index:-1;opacity:.26;background-size:56px 56px}
.auth-ambient-network,.auth-ambient-network svg{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}.auth-ambient-network{z-index:-1;overflow:hidden}.network-path{fill:none;stroke:url(#networkStroke);stroke-width:1.4}.network-path-primary{stroke-dasharray:7 13;animation:network-drift 24s linear infinite}.network-path-secondary{stroke-dasharray:4 16;animation:network-drift 31s linear infinite reverse}.network-path-tertiary{opacity:.7;stroke-dasharray:3 18;animation:network-drift 28s linear infinite}.network-nodes{fill:#b7ebff;opacity:.55;filter:drop-shadow(0 0 5px rgba(117,221,255,.55));animation:network-breathe 8s ease-in-out infinite}
.auth-orb,.auth-outline-shape{position:absolute;z-index:-1;display:block;pointer-events:none}.auth-orb{border-radius:50%;filter:blur(1px)}.auth-orb-top{top:-180px;right:-165px;width:455px;height:455px;background:radial-gradient(circle,rgba(84,172,255,.27),rgba(84,172,255,0) 69%);animation:orb-float 18s ease-in-out infinite}.auth-orb-bottom{bottom:-230px;left:-205px;width:510px;height:510px;background:radial-gradient(circle,rgba(27,205,184,.17),rgba(27,205,184,0) 68%);animation:orb-float 21s ease-in-out infinite reverse}.auth-outline-shape{right:-112px;bottom:58px;width:285px;height:285px;border:1px solid rgba(161,224,255,.15);border-radius:47% 53% 64% 36% / 42% 40% 60% 58%;transform:rotate(18deg);box-shadow:inset 0 0 46px rgba(85,180,255,.05);animation:shape-turn 35s linear infinite}
.auth-minimal-panel{z-index:1;width:min(100%,570px);min-height:min(700px,calc(100vh - 110px))}.auth-minimal-header{gap:13px}.auth-minimal-mark{border-color:rgba(183,232,255,.28);background:linear-gradient(145deg,rgba(117,211,255,.2),rgba(255,255,255,.06));box-shadow:0 12px 32px rgba(2,8,23,.2)}.auth-minimal-content{max-width:500px}.auth-minimal-kicker{color:#8edcff}.auth-minimal-content h1{text-wrap:balance;text-shadow:0 4px 28px rgba(1,10,27,.25)}.auth-minimal-content>p:not(.auth-minimal-kicker){color:#c3d3e7}.auth-minimal-divider{width:58px;background:linear-gradient(90deg,#66d9ff,#74edcf);box-shadow:0 0 18px rgba(102,217,255,.42)}.auth-minimal-list{gap:11px}.auth-minimal-list i{display:grid;place-items:center;width:20px;height:20px;border:1px solid rgba(126,233,207,.27);border-radius:50%;background:rgba(40,196,168,.1);font-size:.77rem}.auth-minimal-footer{color:#adc1d7}
@keyframes network-drift{to{stroke-dashoffset:-180px}}@keyframes network-breathe{50%{opacity:.82}}@keyframes orb-float{50%{transform:translate3d(-12px,18px,0) scale(1.04)}}@keyframes shape-turn{to{transform:rotate(378deg)}}@media(prefers-reduced-motion:reduce){.network-path,.network-nodes,.auth-orb,.auth-outline-shape{animation:none!important}}
/* Ayllu ERP logo */
.ayllu-logo{display:block;width:27px;height:27px;overflow:visible;color:#1772e4}.ayllu-logo path{fill:none;stroke:currentColor;stroke-width:3.3;stroke-linecap:round}.ayllu-logo circle{fill:currentColor}.auth-minimal-mark .ayllu-logo,.auth-brand-mark .ayllu-logo{color:#75d9ff;filter:drop-shadow(0 2px 5px rgba(90,205,255,.25))}.login-mobile-brand .ayllu-logo{width:25px;height:25px;color:#fff}
.brand-mark .ayllu-logo{width:24px;height:24px;color:#fff;filter:drop-shadow(0 1px 2px rgba(7,20,38,.18))}
.dashboard-date{margin:-7px 0 15px;color:var(--muted);font-size:.76rem;text-transform:capitalize}.dashboard-date i{margin-right:5px;color:var(--brand)}.operational-summary{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.operational-item{display:grid;grid-template-columns:36px minmax(0,1fr) auto;align-items:center;gap:10px;padding:12px;border:1px solid var(--line);border-radius:9px;color:var(--ink);text-decoration:none;transition:background 180ms ease,border-color 180ms ease}.operational-item:hover{border-color:#a9cbee;background:var(--brand-light);color:var(--ink)}.operational-item.needs-attention{border-color:#fed7aa;background:#fffaf5}.operational-item strong,.operational-item small{display:block}.operational-item strong{font-size:1.25rem;line-height:1.1}.operational-item small{margin-top:3px;color:var(--muted);font-size:.72rem}.operational-arrow{color:var(--brand);font-size:1.2rem}.operational-note{display:flex;align-items:center;gap:7px;margin:16px 0 0;padding-top:14px;border-top:1px solid #eef2f6;color:var(--muted);font-size:.78rem}.operational-note .bi-check-circle-fill{color:var(--success)}.operational-note .bi-exclamation-circle-fill{color:var(--warning)}
@media(max-width:575px){.operational-summary{grid-template-columns:1fr}}

/* Facturas y cruces de anticipos en el detalle de cobros */
.collection-invoice-count,.collection-advance-count{display:inline-grid;place-items:center;min-width:22px;height:22px;padding:0 6px;border-radius:6px;background:var(--brand-light);color:var(--brand);font-size:.7rem;font-weight:750;vertical-align:middle}
.collection-invoice-list{display:grid;gap:12px;padding:16px}
.collection-invoice-item{min-width:0;overflow:hidden;border:1px solid var(--line);border-radius:10px;background:var(--surface)}
.collection-invoice-heading{display:grid;grid-template-columns:36px minmax(0,1fr) auto minmax(130px,auto);align-items:center;gap:12px;padding:16px}
.collection-invoice-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:9px;background:var(--brand-light);color:var(--brand)}
.collection-invoice-identity{min-width:0}.collection-invoice-identity small,.collection-invoice-amount small,.collection-advance-identity small{display:block;color:var(--muted);font-size:.72rem}.collection-invoice-identity a,.collection-invoice-identity strong,.collection-advance-identity a,.collection-advance-identity strong{display:block;overflow-wrap:anywhere;font-size:.9rem;font-weight:700}.collection-invoice-origin{padding:5px 9px;border-radius:999px;background:var(--brand-light);color:var(--brand);font-size:.72rem;font-weight:650;white-space:nowrap}.collection-invoice-amount{text-align:right}.collection-invoice-amount strong{display:block;font-variant-numeric:tabular-nums}
.collection-advance-details{border-top:1px solid var(--line)}.collection-advance-details summary{display:flex;align-items:center;gap:10px;min-height:48px;padding:11px 16px 11px 64px;background:#f8fbff;color:var(--brand);cursor:pointer;list-style:none;font-size:.8rem;font-weight:650}.collection-advance-details summary::-webkit-details-marker{display:none}.collection-advance-details summary:hover{background:var(--brand-light)}.collection-advance-details summary:focus-visible{outline:2px solid var(--brand);outline-offset:-3px}.collection-advance-summary-label{display:inline-flex;align-items:center;gap:7px;min-width:0}.collection-advance-summary-total{margin-left:auto;color:var(--ink);font-variant-numeric:tabular-nums}.collection-advance-chevron{transition:transform 160ms ease}.collection-advance-details[open] .collection-advance-chevron{transform:rotate(180deg)}
.collection-advance-list{margin:0 16px 14px 52px;padding:0 0 0 12px;border-left:1px solid var(--line);list-style:none}.collection-advance-row{display:grid;grid-template-columns:20px minmax(0,1fr) auto;align-items:center;gap:10px;min-height:54px;padding:9px 10px;color:var(--ink)}.collection-advance-row+.collection-advance-row{border-top:1px solid var(--line)}.collection-advance-branch{color:var(--brand)}.collection-advance-value{font-variant-numeric:tabular-nums;white-space:nowrap}.collection-invoice-no-advances{margin:0;padding:10px 16px 12px 64px;border-top:1px solid var(--line);color:var(--muted);font-size:.78rem}
html[data-theme=dark] .collection-advance-details summary{background:#132238}html[data-theme=dark] .collection-advance-details summary:hover{background:var(--brand-light)}
@media(max-width:650px){.collection-invoice-heading{grid-template-columns:36px minmax(0,1fr);gap:8px 12px}.collection-invoice-amount,.collection-invoice-origin{grid-column:2;text-align:left}.collection-invoice-amount{grid-row:2}.collection-invoice-origin{grid-row:3;justify-self:start}.collection-advance-details summary{padding-left:16px}.collection-advance-list{margin-left:18px}.collection-invoice-no-advances{padding-left:16px}}

.notification-push-settings { padding: .75rem 1rem; border-bottom: 1px solid var(--line); }
