:root{--nav:#17243a;--nav2:#203451;--accent:#1d9bf0;--ok:#14804a;--warn:#b7791f;--bad:#c53030;--bg:#f3f6fa;--card:#fff;--text:#1f2937;--muted:#667085;--line:#d9e0e8;--shadow:0 8px 25px rgba(30,45,65,.08)}*{box-sizing:border-box}body{margin:0;font:14px/1.4 Inter,Segoe UI,Arial,sans-serif;background:var(--bg);color:var(--text)}button,input,select,textarea{font:inherit}.splash,.loginWrap{min-height:100vh;display:grid;place-items:center;text-align:center}.logoMark{width:64px;height:64px;border-radius:17px;background:linear-gradient(145deg,#1e9bf0,#2856d9);color:#fff;display:grid;place-items:center;font-size:26px;font-weight:800;margin:auto;box-shadow:var(--shadow)}.loginCard{width:min(440px,92vw);background:#fff;border:1px solid var(--line);border-radius:18px;padding:28px;box-shadow:var(--shadow);text-align:left}.loginCard h1{text-align:center;margin:12px 0 3px}.loginCard .sub{text-align:center;color:var(--muted);margin-bottom:22px}.field{display:flex;flex-direction:column;gap:5px;margin:10px 0}.field label{font-size:12px;font-weight:700;color:#475467}.field input,.field select,.field textarea,.toolbar input,.toolbar select{width:100%;border:1px solid #cbd5e1;border-radius:8px;padding:9px 10px;background:#fff;color:#111827}.field textarea{min-height:80px;resize:vertical}.btn{border:0;border-radius:8px;padding:9px 14px;font-weight:700;cursor:pointer;background:#e9eef5;color:#20304a}.btn.primary{background:var(--accent);color:#fff}.btn.ok{background:var(--ok);color:#fff}.btn.danger{background:var(--bad);color:#fff}.btn.small{padding:6px 9px;font-size:12px}.btn.block{width:100%}.error{background:#fff0f0;color:#a61b1b;border:1px solid #ffcaca;padding:9px 11px;border-radius:8px;margin:10px 0}.notice{background:#edf7ff;color:#174e78;border:1px solid #b8dcf7;padding:10px 12px;border-radius:9px;margin:10px 0}.shell{display:grid;grid-template-columns:245px 1fr;min-height:100vh}.sidebar{background:var(--nav);color:#dce6f3;position:sticky;top:0;height:100vh;overflow:auto}.brand{padding:18px 17px;border-bottom:1px solid rgba(255,255,255,.09);display:flex;align-items:center;gap:11px}.brand .logoMark{width:38px;height:38px;border-radius:10px;margin:0;font-size:16px}.brand strong{display:block;color:#fff}.brand small{color:#94a3b8}.menu{padding:10px}.menu button{width:100%;border:0;background:transparent;color:#cbd5e1;text-align:left;padding:10px 11px;border-radius:7px;cursor:pointer}.menu button:hover,.menu button.active{background:var(--nav2);color:#fff}.menu .groupHead{display:flex;justify-content:space-between;font-weight:700;margin-top:3px}.submenu{display:none;padding-left:10px}.submenu.open{display:block}.submenu button{font-size:13px;padding:8px 10px}.main{min-width:0}.topbar{height:64px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 22px;position:sticky;top:0;z-index:10}.topbar h2{margin:0;font-size:18px}.topbar .who{display:flex;align-items:center;gap:12px;color:var(--muted)}.content{padding:20px;max-width:1600px;margin:auto}.cards{display:grid;grid-template-columns:repeat(4,minmax(160px,1fr));gap:14px}.card{background:var(--card);border:1px solid var(--line);border-radius:12px;box-shadow:var(--shadow);padding:16px}.metric .value{font-size:26px;font-weight:800;margin:4px 0}.metric .label{color:var(--muted);font-size:12px}.section{background:#fff;border:1px solid var(--line);border-radius:12px;box-shadow:var(--shadow);margin-top:16px}.sectionHead{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:13px 15px;border-bottom:1px solid var(--line)}.sectionHead h3{margin:0;font-size:15px}.sectionBody{padding:15px}.toolbar{display:flex;gap:8px;align-items:end;flex-wrap:wrap}.toolbar .field{margin:0;min-width:140px}.grid2{display:grid;grid-template-columns:1fr 1fr;gap:14px}.grid3{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.tableWrap{overflow:auto}table{width:100%;border-collapse:collapse;font-size:13px}th,td{padding:9px 8px;border-bottom:1px solid #e7ecf1;text-align:left;white-space:nowrap}th{font-size:11px;text-transform:uppercase;color:#667085;background:#f8fafc;position:sticky;top:0}.status{display:inline-flex;padding:3px 7px;border-radius:999px;font-size:11px;font-weight:800;background:#edf2f7}.status.AUTORIZADO{background:#dcfce7;color:#166534}.status.PENDIENTE_SRI,.status.PENDIENTE_ENVIO,.status.POR_PROCESAR{background:#fef3c7;color:#92400e}.status.DEVUELTA,.status.ERROR_SRI,.status.NO{background:#fee2e2;color:#991b1b}.modalBg{position:fixed;inset:0;background:rgba(14,22,35,.56);display:grid;place-items:center;padding:20px;z-index:100}.modal{width:min(950px,96vw);max-height:92vh;overflow:auto;background:#fff;border-radius:14px;box-shadow:0 25px 70px rgba(0,0,0,.25)}.modalHead{display:flex;justify-content:space-between;align-items:center;padding:14px 17px;border-bottom:1px solid var(--line)}.modalHead h3{margin:0}.modalBody{padding:17px}.modalFoot{padding:13px 17px;border-top:1px solid var(--line);display:flex;justify-content:flex-end;gap:8px}.permGrid{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}.check{display:flex;align-items:center;gap:6px;border:1px solid #e2e8f0;padding:7px;border-radius:7px}.invoiceWork{display:grid;grid-template-columns:1fr 280px;gap:14px}.itemsTable input,.itemsTable select{padding:6px;width:100%;min-width:80px}.totalsBox{background:#f8fafc;border:1px solid var(--line);border-radius:10px;padding:14px;height:max-content;position:sticky;top:80px}.totalRow{display:flex;justify-content:space-between;padding:5px 0}.totalRow.grand{font-size:20px;font-weight:900;border-top:1px solid var(--line);margin-top:7px;padding-top:10px}.masterTabs{display:flex;gap:7px;flex-wrap:wrap;margin-bottom:12px}.masterTabs .btn.active{background:var(--nav2);color:#fff}.muted{color:var(--muted)}.code{font-family:Consolas,monospace;background:#f1f5f9;padding:2px 5px;border-radius:5px}.hero{background:linear-gradient(120deg,#17243a,#284f7a);color:#fff;border-radius:15px;padding:20px;margin-bottom:16px}.hero h2{margin:0 0 5px}.mobileMenu{display:none}@media(max-width:900px){.shell{grid-template-columns:1fr}.sidebar{position:fixed;left:-260px;width:245px;z-index:50;transition:.2s}.sidebar.open{left:0}.mobileMenu{display:inline-block}.cards{grid-template-columns:1fr 1fr}.grid2,.grid3,.invoiceWork{grid-template-columns:1fr}.totalsBox{position:static}.permGrid{grid-template-columns:1fr 1fr}}@media(max-width:520px){.cards{grid-template-columns:1fr}.content{padding:12px}.topbar{padding:0 12px}.permGrid{grid-template-columns:1fr}}
/* v5.2.0 parity commercial */
.dashboardFilters{background:#fff;border:1px solid var(--line);border-radius:12px;padding:12px;margin-bottom:14px;box-shadow:var(--shadow)}
.barList{display:flex;flex-direction:column;gap:9px}.barRow{display:grid;grid-template-columns:minmax(100px,180px) 1fr minmax(80px,110px);gap:9px;align-items:center}.barLabel{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}.barTrack{height:12px;background:#e8eef5;border-radius:999px;overflow:hidden}.barTrack span{display:block;height:100%;background:linear-gradient(90deg,#1d9bf0,#2c65da);border-radius:999px}.barValue{text-align:right;font-size:12px;font-weight:800}.systemStatus{display:flex;flex-wrap:wrap;gap:16px}.systemStatus span{background:#f8fafc;border:1px solid var(--line);border-radius:8px;padding:9px 11px}.numPos{color:#12743f;font-weight:800}.numNeg{color:#b42318;font-weight:800}
@media(max-width:700px){.barRow{grid-template-columns:90px 1fr 72px}}
.companyLogo{width:42px;height:42px;object-fit:contain;border-radius:9px;background:#fff;padding:3px}.logoPreview{max-width:220px;max-height:120px;object-fit:contain;border:1px solid var(--line);border-radius:10px;background:#fff;padding:8px;margin:8px 0 12px}

/* v5.2.3 */
.emptyState{padding:34px;text-align:center;color:#667085;background:#f8fafc;border:1px dashed #d0d5dd;border-radius:10px}.emptyState b{display:block;color:#344054;margin-bottom:6px}

/* v5.3.1 - Retenciones estilo formulario completo */
.retentionPage{max-width:1500px;margin:0 auto}.retentionActions{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:10px}.retBadge{display:inline-flex;min-width:20px;height:20px;border-radius:999px;align-items:center;justify-content:center;background:#20b486;color:#fff;font-size:11px;margin-left:4px}.retentionSection{border-radius:8px}.retentionHead h3{color:#6958ed;font-size:17px}.retentionGrid2{display:grid;grid-template-columns:1fr 1fr;gap:18px}.retentionGrid3{display:grid;grid-template-columns:1.35fr 1.35fr .9fr;gap:18px}.retTaxGrid{display:grid;grid-template-columns:repeat(4,1fr);gap:18px}.inputAction{display:grid;grid-template-columns:1fr 44px}.inputAction input{border-radius:8px 0 0 8px!important}.retSearchBtn{border:0;background:#f6b43c;color:#fff;font-size:22px;font-weight:900;border-radius:0 8px 8px 0;cursor:pointer}.sequence3{display:grid;grid-template-columns:1fr 1fr 1.4fr}.sequence3 input{border-radius:0!important;border-right:0!important}.sequence3 input:first-child{border-radius:8px 0 0 8px!important}.sequence3 input:last-child{border-radius:0 8px 8px 0!important;border-right:1px solid #cbd5e1!important}.retHint{min-height:18px;font-size:12px;margin-top:3px}.retOk{color:#137a46;font-weight:700}.retWarn{color:#b42318;font-weight:700}.retLookup{margin-top:10px;border:1px dashed #cdd6e2;border-radius:8px;padding:8px 12px;background:#fafcff}.retLookup summary{cursor:pointer;font-weight:700;color:#475467}.retLookupAction{justify-content:flex-end}.retentionDetailGrid{display:grid;grid-template-columns:1.05fr 1.55fr 1.55fr;gap:10px}.retPanel{border:1px solid #e0e6ee;border-radius:8px;padding:10px;background:#fff;min-width:0}.retPanel h4{margin:0 0 8px;color:#343b48;font-size:16px}.retEntry{display:grid;grid-template-columns:.8fr 1.45fr .55fr auto;gap:0;align-items:end}.retEntry .field{margin:0}.retEntry input,.retEntry select{border-radius:0}.retEntry .field:first-child input{border-radius:8px 0 0 8px}.retMiniBtns{display:flex;height:38px;align-items:stretch}.retMiniBtns button{width:38px;border:0;color:#fff;font-size:19px;font-weight:900;cursor:pointer}.retPlus{background:#7665ee}.retMinus{background:#ef6464;border-radius:0 8px 8px 0}.retTable{margin-top:10px;min-height:165px}.retTable table{font-size:12px}.retTable th{text-transform:none;font-size:12px;background:#fff;border-bottom:2px solid #dbe2ea}.retTable tfoot td{font-weight:800;background:#f7f8fa}.retEmpty{text-align:center;padding:36px 6px;font-size:16px;font-weight:800;color:#344054}.retIdentity .field{margin:8px 0}.retCodeField select{min-width:0}.retPct input{text-align:center}
@media(max-width:1100px){.retentionDetailGrid{grid-template-columns:1fr}.retTaxGrid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:760px){.retentionGrid2,.retentionGrid3,.retTaxGrid{grid-template-columns:1fr}.retEntry{grid-template-columns:1fr}.retEntry input,.retEntry select,.retEntry .field:first-child input{border-radius:8px!important}.retMiniBtns{margin-top:6px}.retMiniBtns button{border-radius:8px;margin-right:5px}}

/* v5.3.2 - Proformas completas */
.status.ABIERTA{background:#dbeafe;color:#1d4ed8}.status.CONVERTIDA{background:#dcfce7;color:#166534}.status.ANULADA{background:#fee2e2;color:#991b1b}
.quoteDetail{margin-top:10px}.quoteItems select{min-width:260px}.quoteItems input{min-width:86px}.quoteSummary{display:grid;grid-template-columns:1fr 260px;gap:14px;align-items:start}.quoteTotals{position:static;margin-top:10px}.notice.success{background:#ecfdf3;border-color:#abefc6;color:#067647}.emptyState{padding:28px;text-align:center;color:var(--muted)}.emptyState b{display:block;color:var(--text);margin-bottom:5px}
@media(max-width:900px){.quoteSummary{grid-template-columns:1fr}.quoteItems select{min-width:220px}}


/* v5.3.5 - buscadores escribibles + catálogo visual de productos */
.selectedPartyBox{min-height:38px;border:1px solid var(--line);border-radius:8px;padding:8px 10px;background:#f8fafc}.productThumb{width:56px;height:56px;object-fit:cover;border-radius:8px;border:1px solid var(--line);cursor:zoom-in;background:#fff}.productThumbEmpty{display:grid;place-items:center;width:56px;height:56px;border:1px dashed #cbd5e1;border-radius:8px;color:#98a2b3;font-size:10px;text-align:center}.productExcerpt{max-width:360px;white-space:normal;color:#667085;font-size:12px;margin-top:3px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.productEditGrid{display:grid;grid-template-columns:minmax(0,1fr) 260px;gap:18px}.productPhotoEditor{border-left:1px solid var(--line);padding-left:16px}.productPhotoPreview{height:220px;border:1px dashed #cbd5e1;border-radius:12px;background:#f8fafc;display:grid;place-items:center;overflow:hidden;margin:8px 0 12px}.productPhotoPreview img{width:100%;height:100%;object-fit:contain;cursor:zoom-in}.productNoPhoto{color:#98a2b3;font-weight:700;text-align:center;padding:28px}.productInfoLayout{display:grid;grid-template-columns:300px minmax(0,1fr);gap:22px}.productInfoPhoto img{width:100%;max-height:420px;object-fit:contain;border:1px solid var(--line);border-radius:12px;cursor:zoom-in;background:#f8fafc}.productInfoPhoto small{display:block;text-align:center;color:var(--muted);margin-top:6px}.productInfoFacts{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.productInfoFacts>div{background:#f8fafc;border:1px solid var(--line);border-radius:8px;padding:9px}.productInfoFacts b,.productInfoFacts span{display:block}.productInfoFacts b{font-size:11px;color:#667085;text-transform:uppercase}.productTextBlock{margin-top:12px;border-top:1px solid var(--line);padding-top:12px;white-space:normal;line-height:1.45}.productSearchCell{min-width:310px}.productSearchCell>input{min-width:300px}.pickedProductMeta{display:flex;align-items:center;gap:7px;margin-top:5px;color:#667085;font-size:11px;white-space:normal}.pickedProductMeta img{width:34px;height:34px;object-fit:cover;border-radius:6px;border:1px solid var(--line);cursor:zoom-in}.linkBtn{border:0;background:none;padding:0;color:#1d4ed8;text-decoration:underline;cursor:pointer;font-size:11px}.imageViewer{position:fixed;inset:0;background:rgba(0,0,0,.82);z-index:1000;display:grid;place-items:center;padding:24px}.imageViewerBox{position:relative;max-width:96vw;max-height:94vh;color:#fff;text-align:center}.imageViewerBox img{display:block;max-width:94vw;max-height:86vh;object-fit:contain;border-radius:10px;background:#fff}.imageViewerClose{position:absolute;right:-10px;top:-10px;width:38px;height:38px;border-radius:999px;border:0;background:#fff;color:#111;font-size:20px;cursor:pointer;box-shadow:0 4px 18px #0008}
@media(max-width:900px){.productEditGrid,.productInfoLayout{grid-template-columns:1fr}.productPhotoEditor{border-left:0;border-top:1px solid var(--line);padding-left:0;padding-top:14px}.productInfoFacts{grid-template-columns:1fr 1fr}.productSearchCell,.productSearchCell>input{min-width:230px}}
@media(max-width:520px){.productInfoFacts{grid-template-columns:1fr}}

/* v5.3.6 - autocompletado real de productos mientras se escribe */
.productSuggestMenu{position:fixed;z-index:10050;max-height:390px;overflow:auto;background:#fff;border:1px solid #b8c4d4;border-radius:10px;box-shadow:0 16px 42px rgba(15,23,42,.24);padding:5px}.productSuggestItem{width:100%;border:0;border-bottom:1px solid #eef2f6;background:#fff;padding:8px;display:grid;grid-template-columns:48px minmax(0,1fr);gap:9px;text-align:left;align-items:center;cursor:pointer;border-radius:7px;color:#1f2937}.productSuggestItem:last-child{border-bottom:0}.productSuggestItem:hover,.productSuggestItem.active{background:#eaf5ff;outline:1px solid #8ac7f4}.productSuggestItem img,.productSuggestNoPhoto{width:48px;height:48px;border-radius:7px;border:1px solid #d8e0e9;background:#f8fafc}.productSuggestItem img{object-fit:cover}.productSuggestNoPhoto{display:grid;place-items:center;font-size:8px;font-weight:800;color:#98a2b3;text-align:center}.productSuggestText{min-width:0;display:flex;flex-direction:column;gap:2px}.productSuggestText b{white-space:normal;line-height:1.25}.productSuggestText small{color:#667085;white-space:normal;line-height:1.25}.productSuggestEmpty{padding:14px;color:#667085;text-align:center}.productSearchCell>input:focus{border-color:#1d9bf0;box-shadow:0 0 0 3px rgba(29,155,240,.12);outline:none}
@media(max-width:600px){.productSuggestMenu{max-width:calc(100vw - 16px)!important}.productSuggestItem{grid-template-columns:42px minmax(0,1fr)}.productSuggestItem img,.productSuggestNoPhoto{width:42px;height:42px}}

/* v5.4.3 - menú lateral retráctil + diseño móvil responsivo */
html,body{max-width:100%;overflow-x:hidden}.shell{transition:grid-template-columns .22s ease}.sidebar{width:245px;transition:transform .22s ease,box-shadow .22s ease;will-change:transform}.shell.sidebar-collapsed{grid-template-columns:0 minmax(0,1fr)}.shell.sidebar-collapsed .sidebar{transform:translateX(-102%);pointer-events:none}.main{width:100%;max-width:100%;overflow:hidden}.brand{position:relative}.brandText{min-width:0}.brandText strong,.brandText small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.menuToggle{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;min-width:42px;min-height:40px;font-size:18px}.sideClose{display:none;margin-left:auto;width:38px;height:38px;border:0;border-radius:8px;background:rgba(255,255,255,.09);color:#fff;font-size:17px;cursor:pointer}.sidebarBackdrop{display:none;position:fixed;inset:0;border:0;background:rgba(15,23,42,.48);z-index:45;padding:0}.topbar h2{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.topbar .who{min-width:0;max-width:42%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tableWrap{max-width:100%;-webkit-overflow-scrolling:touch}.modalBg{overscroll-behavior:contain}.masterTabs{-webkit-overflow-scrolling:touch}
@media(max-width:900px){
 body.sidebar-open{overflow:hidden}.shell,.shell.sidebar-collapsed{display:block;min-height:100dvh}.sidebar,.shell.sidebar-collapsed .sidebar{position:fixed;left:0;top:0;width:min(82vw,300px);height:100dvh;z-index:50;transform:translateX(-105%);pointer-events:auto;box-shadow:none;overflow-y:auto;overscroll-behavior:contain}.sidebar.open{transform:translateX(0);box-shadow:12px 0 36px rgba(15,23,42,.28)}.sidebarBackdrop.open{display:block}.sideClose{display:inline-flex;align-items:center;justify-content:center}.brand{padding:14px 13px}.brand .logoMark{flex:0 0 auto}.menu{padding:8px}.menu button{min-height:43px;padding:10px}.main{min-height:100dvh}.topbar{height:auto;min-height:58px;padding:8px 12px;gap:9px}.topbar h2{flex:1;font-size:16px}.topbar .who{max-width:34%;font-size:12px}.content{width:100%;padding:14px}.hero{padding:16px;border-radius:12px}.hero h2{font-size:19px}.masterTabs{flex-wrap:nowrap;overflow-x:auto;padding-bottom:4px;margin-left:-2px;margin-right:-2px}.masterTabs .btn{flex:0 0 auto;white-space:nowrap}.section{max-width:100%}.sectionHead{flex-wrap:wrap;align-items:flex-start}.sectionBody{padding:13px}.toolbar{align-items:stretch}.toolbar .field{flex:1 1 180px}.modalBg{padding:8px;align-items:end}.modal{width:100%;max-width:100%;max-height:96dvh;border-radius:15px 15px 0 0}.modalHead{padding:12px 14px;position:sticky;top:0;background:#fff;z-index:2}.modalBody{padding:13px}.modalFoot{padding:10px 13px;position:sticky;bottom:0;background:#fff;z-index:2;flex-wrap:wrap}.modalFoot .btn{min-height:40px}.tableWrap table{min-width:680px}.cards{gap:10px}.grid2,.grid3,.invoiceWork{gap:10px}.systemStatus{gap:8px}.systemStatus span{width:100%}
}
@media(max-width:640px){
 .topbar .who{display:none}.topbar{grid-template-columns:auto minmax(0,1fr)}.content{padding:10px}.cards{grid-template-columns:1fr}.toolbar{display:grid;grid-template-columns:1fr}.toolbar .field,.toolbar>.btn{width:100%;min-width:0}.sectionHead{padding:11px 12px}.sectionHead>.btn{max-width:100%}.sectionBody{padding:11px}.hero{margin-bottom:12px}.hero div{font-size:12px;line-height:1.45}.masterTabs{gap:5px}.masterTabs .btn{padding:8px 11px}.field input,.field select,.field textarea,.toolbar input,.toolbar select{font-size:16px}.btn{min-height:40px}.btn.small{min-height:34px}.permGrid{grid-template-columns:1fr}.modalFoot{display:grid;grid-template-columns:1fr 1fr}.modalFoot .btn:only-child{grid-column:1/-1}.tableWrap{margin-left:-2px;margin-right:-2px}.tableWrap table{min-width:620px}th,td{padding:8px 7px}.quoteSummary{grid-template-columns:1fr}.productSearchCell,.productSearchCell>input{min-width:220px}.barRow{grid-template-columns:82px minmax(90px,1fr) 68px;gap:6px}.barLabel,.barValue{font-size:11px}
}
@media(max-width:420px){
 .sidebar,.shell.sidebar-collapsed .sidebar{width:88vw}.brand{gap:8px}.brand .logoMark,.companyLogo{width:36px;height:36px}.topbar{padding:7px 8px}.content{padding:8px}.card{padding:13px}.metric .value{font-size:23px}.modalBg{padding:0}.modal{border-radius:12px 12px 0 0}.modalFoot{grid-template-columns:1fr}.tableWrap table{min-width:580px}
}


/* v5.4.4 - responsive móvil real + tablas en tarjetas */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}body{min-width:0}.main,.content,.section,.sectionBody,.card,.toolbar,.grid2,.grid3,.invoiceWork,.retentionPage,.retentionGrid2,.retentionGrid3,.retTaxGrid,.retentionDetailGrid,.retPanel,.quoteSummary,.productEditGrid,.productInfoLayout{min-width:0}img,svg,canvas,video{max-width:100%}.content{overflow:visible}.main{overflow:visible}.sectionHead>div{max-width:100%;display:flex;gap:8px;flex-wrap:wrap}.notice,.error,.code{overflow-wrap:anywhere;word-break:break-word}.sidebar{padding-bottom:env(safe-area-inset-bottom)}.topbar{padding-top:env(safe-area-inset-top)}
.tableWrap{width:100%;max-width:100%;overflow-x:auto;overflow-y:visible;overscroll-behavior-x:contain}.tableWrap table{max-width:none}.mobile-card-table td .btn{margin:2px}.mobile-card-table td:last-child{white-space:normal}.mobile-scroll-table{min-width:max-content}
@media(max-width:900px){
 .shell,.shell.sidebar-collapsed{width:100%;max-width:100vw}.main{width:100%;max-width:100vw}.content{max-width:100vw}.sidebar,.shell.sidebar-collapsed .sidebar{padding-top:env(safe-area-inset-top)}
 .grid2,.grid3,.invoiceWork,.retentionGrid2,.retentionGrid3,.retTaxGrid,.retentionDetailGrid,.quoteSummary,.productEditGrid,.productInfoLayout{grid-template-columns:minmax(0,1fr)!important}
 .retTaxGrid{gap:10px}.retEntry{grid-template-columns:minmax(0,1fr)!important;gap:7px}.sequence3{grid-template-columns:1fr 1fr 1.25fr}.productPhotoEditor{min-width:0}.productInfoPhoto{max-width:420px;width:100%;margin:0 auto}
 .topbar{padding-left:max(10px,env(safe-area-inset-left));padding-right:max(10px,env(safe-area-inset-right))}.content{padding-left:max(12px,env(safe-area-inset-left));padding-right:max(12px,env(safe-area-inset-right));padding-bottom:max(16px,env(safe-area-inset-bottom))}
 .sectionHead{align-items:center}.sectionHead h3{flex:1 1 180px}.sectionHead>.btn,.sectionHead>div>.btn{max-width:100%}
 .tableWrap table.mobile-card-table{display:block;min-width:0!important;width:100%!important;border-collapse:separate;border-spacing:0;background:transparent}.mobile-card-table thead{display:none}.mobile-card-table tbody{display:grid;width:100%;gap:10px}.mobile-card-table tr{display:block;background:#fff;border:1px solid var(--line);border-radius:11px;padding:7px 10px;box-shadow:0 2px 10px rgba(30,45,65,.05)}.mobile-card-table td{display:grid;grid-template-columns:minmax(92px,35%) minmax(0,1fr);gap:9px;align-items:start;width:100%;padding:8px 2px;border-bottom:1px solid #edf1f5;white-space:normal!important;overflow-wrap:anywhere}.mobile-card-table td:last-child{border-bottom:0}.mobile-card-table td::before{content:attr(data-label);font-size:10px;line-height:1.25;font-weight:800;text-transform:uppercase;letter-spacing:.025em;color:#667085}.mobile-card-table td:empty::after{content:'—';color:#98a2b3}.mobile-card-table td:last-child>div{display:flex!important;gap:5px!important;flex-wrap:wrap!important}.mobile-card-table td:last-child .btn{flex:1 1 auto;min-width:88px;white-space:normal}
 .tableWrap table.mobile-scroll-table{min-width:680px!important}.itemsTable.mobile-scroll-table,.quoteItems.mobile-scroll-table{min-width:760px!important}
}
@media(max-width:640px){
 body{font-size:13px}.loginWrap{padding:max(14px,env(safe-area-inset-top)) 10px max(14px,env(safe-area-inset-bottom))}.loginCard{width:100%;max-width:430px;padding:20px 16px;border-radius:14px}
 .topbar{min-height:54px;position:sticky;top:0}.menuToggle{min-width:44px;min-height:44px;padding:8px 11px}.topbar h2{font-size:15px;line-height:1.2}.content{padding-top:10px}.hero{padding:14px}.hero h2{font-size:18px}.card{border-radius:10px}.metric .value{font-size:21px;overflow-wrap:anywhere}.section{border-radius:10px;margin-top:12px}.sectionHead{padding:10px}.sectionBody{padding:10px}
 .masterTabs{margin:0 -4px 10px;padding:0 4px 5px;scroll-snap-type:x proximity}.masterTabs .btn{scroll-snap-align:start;min-height:38px}
 .toolbar,.retentionActions{width:100%}.toolbar .field,.toolbar>.btn,.retentionActions>.btn{width:100%;max-width:none}.field{min-width:0}.field input,.field select,.field textarea,.toolbar input,.toolbar select{min-width:0;max-width:100%;font-size:16px}.field input[type=file]{font-size:13px}.btn{max-width:100%;white-space:normal}.btn.small{font-size:12px;padding:7px 9px}
 .sequence3{grid-template-columns:1fr!important;gap:6px}.sequence3 input{border:1px solid #cbd5e1!important;border-radius:8px!important}.inputAction{grid-template-columns:minmax(0,1fr) 44px}.retEntry input,.retEntry select{border-radius:8px}.retSearchBtn{border-radius:0 8px 8px 0}
 .barRow{grid-template-columns:minmax(74px,32%) minmax(70px,1fr) minmax(58px,22%);gap:5px}.barLabel{white-space:normal;line-height:1.2}.barValue{white-space:nowrap}.systemStatus span{overflow-wrap:anywhere}
 .productSearchCell,.productSearchCell>input{min-width:0!important;width:100%!important}.pickedProductMeta{align-items:flex-start}.productSuggestMenu{left:8px!important;right:8px!important;width:auto!important;max-width:none!important}.imageViewer{padding:10px}.imageViewerClose{right:2px;top:2px}
 .modalBg{padding-top:max(4px,env(safe-area-inset-top));padding-left:max(0px,env(safe-area-inset-left));padding-right:max(0px,env(safe-area-inset-right));padding-bottom:0}.modal{max-height:calc(100dvh - env(safe-area-inset-top));}.modalBody{overflow-wrap:anywhere}.modalFoot{padding-bottom:max(10px,env(safe-area-inset-bottom))}
 .mobile-card-table td{grid-template-columns:minmax(82px,34%) minmax(0,1fr);gap:7px;padding:7px 1px}.mobile-card-table td:last-child{display:block}.mobile-card-table td:last-child::before{display:block;margin-bottom:7px}.mobile-card-table td:last-child .btn{width:100%;margin:3px 0}.tableWrap table.mobile-scroll-table{min-width:620px!important}.itemsTable.mobile-scroll-table,.quoteItems.mobile-scroll-table{min-width:700px!important}
}
@media(max-width:420px){
 .content{padding-left:max(7px,env(safe-area-inset-left));padding-right:max(7px,env(safe-area-inset-right))}.sidebar,.shell.sidebar-collapsed .sidebar{width:min(90vw,330px)}.brandText strong{font-size:13px}.brandText small{font-size:11px}.hero{border-radius:9px}.masterTabs .btn{padding:7px 9px;font-size:12px}.cards{gap:8px}.card{padding:11px}.sectionBody{padding:8px}.mobile-card-table tr{padding:6px 8px}.mobile-card-table td{grid-template-columns:1fr;gap:3px}.mobile-card-table td::before{margin-bottom:1px}.tableWrap table.mobile-scroll-table{min-width:580px!important}.itemsTable.mobile-scroll-table,.quoteItems.mobile-scroll-table{min-width:660px!important}
}

/* v5.4.6 - importador masivo de productos */
.productHeadActions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}.productHead{gap:12px}.productHead h3{margin-right:auto}@media(max-width:700px){.productHead{align-items:stretch!important;flex-direction:column}.productHeadActions{display:grid;grid-template-columns:1fr}.productHeadActions .btn{width:100%;min-height:44px}}

/* v5.4.7 - factura adaptable en laptop/escritorio sin alterar la vista móvil */
.invoiceWork>div{min-width:0}.invoiceWork .section,.invoiceWork .tableWrap{min-width:0}
@media(min-width:901px){
 .invoiceWork .itemsTable:not(.quoteItems){width:100%!important;min-width:0!important;table-layout:fixed}
 .invoiceWork .itemsTable:not(.quoteItems) th,.invoiceWork .itemsTable:not(.quoteItems) td{padding:8px 6px;min-width:0}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(1),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(1){width:25%}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(2),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(2){width:8%}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(3),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(3){width:9%}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(4),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(4){width:8%}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(5),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(5){width:9%}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(6),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(6){width:11%}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(7),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(7){width:12%}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(8),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(8){width:9%;text-align:right}
 .invoiceWork .itemsTable:not(.quoteItems) th:nth-child(9),.invoiceWork .itemsTable:not(.quoteItems) td:nth-child(9){width:52px;text-align:center}
 .invoiceWork .itemsTable:not(.quoteItems) input,.invoiceWork .itemsTable:not(.quoteItems) select{width:100%!important;min-width:0!important;max-width:100%;padding:6px 7px}
 .invoiceWork .productSearchCell,.invoiceWork .productSearchCell>input{width:100%!important;min-width:0!important;max-width:100%}
 .invoiceWork .pickedProductMeta{min-width:0;flex-wrap:wrap}.invoiceWork .pickedProductMeta span{white-space:normal}
}
@media(min-width:901px) and (max-width:1450px){
 .invoiceWork{grid-template-columns:minmax(0,1fr)!important}
 .invoiceWork>.totalsBox{position:static;width:100%}
}


/* v5.4.32 - identidad visual general DiomFact */
.appLogo{width:64px;height:64px;object-fit:contain;border-radius:17px;display:block;margin:auto;box-shadow:var(--shadow);background:#fff}
.splashLogo{width:82px;height:82px;border-radius:22px}
.brand .appLogo{width:38px;height:38px;border-radius:10px;margin:0;flex:0 0 auto;box-shadow:none;background:#fff}
@media(max-width:420px){.brand .appLogo{width:36px;height:36px}.splashLogo{width:72px;height:72px}}


/* v5.4.33 - Experiencia web solo navegador, inspirada en SaaS de facturacion modernos */
.browserLogin{min-height:100vh;display:grid;grid-template-columns:minmax(520px,1.15fr) minmax(420px,.85fr);background:#f6f8fc}
.browserIntro{position:relative;overflow:hidden;display:flex;flex-direction:column;justify-content:space-between;padding:42px 6vw 30px;color:#fff;background:radial-gradient(circle at 15% 15%,rgba(37,158,255,.35),transparent 36%),linear-gradient(145deg,#071a3c 0%,#0b2d68 52%,#0a5bc4 100%)}
.browserIntro:after{content:"";position:absolute;width:420px;height:420px;border:1px solid rgba(255,255,255,.12);border-radius:50%;right:-170px;bottom:-170px;box-shadow:0 0 0 75px rgba(255,255,255,.035),0 0 0 150px rgba(255,255,255,.025)}
.browserBrand{position:relative;z-index:1;display:flex;align-items:center;gap:13px;font-size:22px;font-weight:900;letter-spacing:-.4px}.browserBrandLogo{width:58px;height:58px;object-fit:contain;border-radius:15px;box-shadow:0 14px 30px rgba(0,0,0,.2)}
.browserHeroCopy{position:relative;z-index:1;max-width:760px;margin:50px 0}.browserEyebrow,.loginEyebrow{font-size:11px;font-weight:900;letter-spacing:1.8px}.browserEyebrow{color:#7fe6ff}.browserHeroCopy h1{font-size:clamp(38px,4.5vw,66px);line-height:1.02;letter-spacing:-2.4px;margin:14px 0 18px}.browserHeroCopy h1 span{color:#8be7ff}.browserHeroCopy>p{max-width:650px;font-size:17px;line-height:1.65;color:#d9e9ff;margin:0 0 28px}
.browserFlow{display:flex;align-items:center;gap:10px;margin:18px 0 30px}.browserFlow div{display:flex;align-items:center;gap:8px;white-space:nowrap}.browserFlow b{width:27px;height:27px;border-radius:50%;display:grid;place-items:center;background:#fff;color:#0b3f88;font-size:12px}.browserFlow span{font-size:12px;font-weight:800}.browserFlow i{height:1px;min-width:18px;flex:1;background:rgba(255,255,255,.3)}
.browserFeatureGrid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.browserFeatureGrid>div{padding:15px;border:1px solid rgba(255,255,255,.14);background:rgba(255,255,255,.075);backdrop-filter:blur(8px);border-radius:14px}.browserFeatureGrid strong{display:block;font-size:13px}.browserFeatureGrid small{display:block;color:#c7dbf7;margin-top:5px;line-height:1.45}.browserIntroFoot{position:relative;z-index:1;display:flex;gap:10px;flex-wrap:wrap;color:#b9cee9;font-size:11px}
.browserAccess{display:grid;place-items:center;padding:38px}.browserLoginCard{width:min(470px,100%);padding:36px;border:1px solid #e1e7ef;border-radius:22px;box-shadow:0 28px 70px rgba(31,50,81,.13)}.browserLoginCard h1{text-align:left;font-size:31px;letter-spacing:-.8px;margin:8px 0 4px}.browserLoginCard .sub{text-align:left;margin-bottom:24px}.loginEyebrow{color:#1769cf}.loginLogoMobile{display:none}.browserLoginCard .field{margin:14px 0}.browserLoginCard .field label{font-size:12px}.browserLoginCard .field input{padding:12px 13px;border-radius:10px;border-color:#cfd8e6;outline:none}.browserLoginCard .field input:focus{border-color:#2a7be4;box-shadow:0 0 0 3px rgba(42,123,228,.12)}.browserLoginBtn{margin-top:7px;padding:12px 14px;border-radius:10px;background:linear-gradient(135deg,#0b63ce,#168ee8)!important;box-shadow:0 10px 20px rgba(17,112,215,.2)}
.browserSecurity{display:flex;gap:10px;align-items:flex-start;margin-top:18px;padding:12px;border-radius:11px;background:#f3f8ff;border:1px solid #dceafb}.browserSecurity>span{font-size:18px}.browserSecurity b,.browserSecurity small{display:block}.browserSecurity b{font-size:12px;color:#27466c}.browserSecurity small{font-size:11px;color:#6b7e96;margin-top:3px;line-height:1.4}.browserSupportLine{text-align:center;color:#8795a8;font-size:11px;margin-top:18px}
.browserQuickActions{display:grid;grid-template-columns:repeat(4,minmax(150px,1fr));gap:12px;margin:0 0 14px}.browserQuickActions button{position:relative;text-align:left;border:1px solid #dce4ee;background:#fff;border-radius:14px;padding:14px 14px 13px;cursor:pointer;box-shadow:0 7px 22px rgba(34,55,88,.055);transition:.16s ease}.browserQuickActions button:hover{transform:translateY(-2px);border-color:#a8cef4;box-shadow:0 12px 26px rgba(34,55,88,.09)}.browserQuickActions button>span{display:grid;place-items:center;width:35px;height:35px;border-radius:10px;background:#edf6ff;color:#146ed0;font-size:19px;margin-bottom:9px}.browserQuickActions b,.browserQuickActions small{display:block}.browserQuickActions b{font-size:13px;color:#1d2d43}.browserQuickActions small{font-size:11px;color:#77869a;margin-top:3px}
/* Pulido visual del portal de navegador */
.topbar{height:66px;box-shadow:0 1px 0 rgba(15,35,60,.02)}.section,.card,.dashboardFilters{border-color:#e1e7ef;box-shadow:0 6px 22px rgba(31,50,81,.055)}.btn.primary{background:linear-gradient(135deg,#0b69d5,#168fe8)}.menu button{border-radius:9px}.sidebar{background:linear-gradient(180deg,#0a1d3c,#102b52)}.brand{min-height:74px}.content{padding-top:18px}
@media(max-width:1100px){.browserLogin{grid-template-columns:1fr 470px}.browserIntro{padding-left:4vw;padding-right:4vw}.browserHeroCopy h1{font-size:44px}.browserFeatureGrid{grid-template-columns:1fr}.browserFlow{flex-wrap:wrap}.browserFlow i{display:none}.browserQuickActions{grid-template-columns:1fr 1fr}}
@media(max-width:820px){.browserLogin{display:block;background:#eef4fb}.browserIntro{min-height:auto;padding:24px 22px 30px}.browserBrandLogo{width:48px;height:48px}.browserHeroCopy{margin:35px 0 12px}.browserHeroCopy h1{font-size:36px;letter-spacing:-1.3px}.browserHeroCopy>p{font-size:15px}.browserFeatureGrid,.browserIntroFoot{display:none}.browserAccess{padding:0 15px 28px;margin-top:-2px}.browserLoginCard{border-radius:18px;padding:25px}.browserQuickActions{grid-template-columns:1fr 1fr}}
@media(max-width:520px){.browserIntro{padding:20px 16px 27px}.browserBrand span{font-size:19px}.browserHeroCopy{margin:26px 0 8px}.browserHeroCopy h1{font-size:31px}.browserHeroCopy>p{font-size:14px;margin-bottom:18px}.browserFlow{gap:8px}.browserFlow div{gap:5px}.browserFlow b{width:23px;height:23px}.browserFlow span{font-size:10px}.browserAccess{padding:0 10px 18px}.browserLoginCard{padding:22px 18px}.browserLoginCard h1{font-size:27px}.browserQuickActions{gap:8px}.browserQuickActions button{padding:12px}.browserQuickActions b{font-size:12px}}
/* v5.4.35 · Editor de portada web */
.lpEditorHead{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:16px}.lpEditorHead h3{margin:0 0 5px}.lpEditorGrid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.lpEditSection{margin-bottom:16px}.lpEditSection .sectionHead{align-items:center;gap:12px;flex-wrap:wrap}.lpEditSection h4{margin:20px 0 10px}.lpToggle{margin:0}.lpColorRow{display:grid;grid-template-columns:54px 1fr;gap:8px;align-items:center}.lpColorRow input[type=color]{width:54px;height:42px;padding:2px;border:1px solid #d8e1ee;border-radius:9px;background:#fff}.lpImageBox{display:grid;grid-template-columns:180px 1fr;gap:16px;align-items:center;margin:8px 0 14px}.lpImagePreview{width:180px;height:120px;border:1px dashed #c9d6e7;border-radius:12px;background:#f7faff;display:grid;place-items:center;overflow:hidden;color:#8896aa}.lpImagePreview img{display:block;width:100%;height:100%;object-fit:cover}.lpImageBox input[type=file]{display:block;max-width:100%;margin-bottom:8px}.lpRepeater{display:grid;gap:12px;margin-top:16px}.lpRepeatCard{border:1px solid #dce6f2;border-radius:14px;padding:16px;background:#fbfdff}.lpRepeatTop{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.lpRepeatTop>div{display:flex;align-items:center;gap:6px;flex-wrap:wrap}.lpGalleryEditor{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin-top:15px}.lpGalleryItem{border:1px solid #dce6f2;border-radius:14px;padding:12px;background:#fbfdff}.lpGalleryItem .lpImageBox{display:block}.lpGalleryItem .lpImagePreview{width:100%;height:150px;margin-bottom:8px}.lpStickySave{position:sticky;bottom:12px;z-index:20;margin:16px 0 0 auto;width:max-content;max-width:100%;padding:9px;border-radius:13px;background:rgba(255,255,255,.94);box-shadow:0 8px 30px rgba(15,37,75,.18);border:1px solid #dce6f2;display:flex;gap:8px;backdrop-filter:blur(12px)}@media(max-width:900px){.lpEditorGrid{grid-template-columns:1fr}.lpGalleryEditor{grid-template-columns:1fr 1fr}.lpEditorHead{display:block}.lpEditorHead .actions{margin-top:12px}}@media(max-width:560px){.lpImageBox{grid-template-columns:1fr}.lpImagePreview{width:100%;height:180px}.lpGalleryEditor{grid-template-columns:1fr}.lpRepeatTop{align-items:flex-start;flex-direction:column}.lpStickySave{width:100%}.lpStickySave .btn{flex:1}}


/* =========================================================
   DiomFact 5.6 · Professional Business UI
   Capa visual progresiva: no cambia reglas fiscales ni API.
   ========================================================= */
:root{--df-navy:#0b1830;--df-navy-2:#102744;--df-blue:#1976e9;--df-blue-soft:#edf5ff;--df-cyan:#24b7e9;--df-green:#1ca46f;--df-orange:#e89920;--df-surface:#f5f7fb;--df-radius:14px;--df-shadow:0 10px 35px rgba(20,39,70,.07)}
body{background:var(--df-surface);letter-spacing:.005em}.dfShell{grid-template-columns:264px minmax(0,1fr);background:var(--df-surface)}.dfSidebar{background:linear-gradient(180deg,#08172c 0%,#0d2340 52%,#0b1d35 100%);border-right:1px solid rgba(255,255,255,.05);overflow-x:hidden}.dfBrand{padding:16px 14px;min-height:78px;background:rgba(255,255,255,.02)}.dfBrand .companyLogo,.dfBrand .appLogo{width:42px;height:42px;border-radius:12px;object-fit:contain;background:#fff;padding:3px}.dfBrand .brandText{min-width:0;flex:1}.dfBrand .brandText strong{font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dfBrand .brandText small{font-size:10px;color:#8ea6c4}.versionPill{font-size:9px;font-weight:900;padding:3px 6px;border-radius:999px;background:rgba(43,183,234,.16);color:#6fdcff;border:1px solid rgba(111,220,255,.2)}.workspaceBadge{margin:10px 12px 6px;padding:10px 11px;border:1px solid rgba(255,255,255,.07);background:rgba(255,255,255,.035);border-radius:11px;display:flex;gap:9px;align-items:center}.workspaceBadge b,.workspaceBadge small{display:block}.workspaceBadge b{font-size:11px;color:#e7eef8}.workspaceBadge small{font-size:9px;color:#8ea6c4;margin-top:2px}.workspaceDot{width:8px;height:8px;border-radius:50%;background:#f2a43b;box-shadow:0 0 0 4px rgba(242,164,59,.09)}.workspaceDot.ready{background:#34c58c;box-shadow:0 0 0 4px rgba(52,197,140,.1)}
.dfMenu{padding:8px 9px 80px}.dfMenu button,.sidebarFoot button{display:flex;align-items:center;gap:9px}.dfMenu .navRoot{font-weight:800;margin-bottom:5px}.dfMenu .navIco,.sidebarFoot .navIco{width:25px;height:25px;border-radius:7px;display:grid;place-items:center;background:rgba(255,255,255,.045);font-style:normal;font-weight:900;flex:0 0 25px}.dfMenu button.active .navIco{background:rgba(255,255,255,.16)}.dfMenu button.active{background:linear-gradient(90deg,rgba(25,118,233,.86),rgba(36,183,233,.34));box-shadow:inset 3px 0 #62d7ff,0 7px 20px rgba(0,0,0,.08)}.dfMenu .groupHead{margin-top:8px;padding:8px 9px;color:#8fa7c6;text-transform:uppercase;letter-spacing:.08em;font-size:10px}.dfMenu .groupHead:hover{background:rgba(255,255,255,.035)}.groupName{display:flex;align-items:center;gap:7px}.groupName i{font-style:normal;color:#5f7fa5}.groupName b{font-size:10px}.groupHead .chev{font-size:12px}.dfMenu .submenu{padding-left:5px}.dfMenu .submenu button{font-size:12px;padding:7px 9px}.dfMenu .submenu .navIco{width:23px;height:23px;flex-basis:23px;font-size:11px}.sidebarFoot{position:sticky;bottom:0;margin-top:auto;padding:9px;background:linear-gradient(180deg,rgba(8,23,44,0),#08172c 28%);display:grid;gap:4px}.sidebarFoot button{width:100%;border:0;background:transparent;color:#9fb0c7;padding:8px 10px;border-radius:9px;cursor:pointer;text-align:left}.sidebarFoot button:hover{background:rgba(255,255,255,.06);color:#fff}
.dfTopbar{height:72px;padding:0 20px;background:rgba(255,255,255,.94);backdrop-filter:blur(12px);border-bottom:1px solid #e6ebf2;box-shadow:0 3px 18px rgba(25,45,80,.035)}.topbarLeft{display:flex;align-items:center;gap:12px;min-width:0}.topbarLeft>div{min-width:0}.topbarLeft h2{font-size:17px;line-height:1.15}.topbarLeft small{display:block;color:#8591a3;font-size:10px;margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.topbarActions{display:flex;align-items:center;gap:10px}.topQuickSale{height:38px;border:0;border-radius:10px;background:#0f73df;color:#fff;padding:0 13px;display:flex;gap:7px;align-items:center;cursor:pointer;box-shadow:0 7px 18px rgba(15,115,223,.18)}.topQuickSale span{font-size:17px}.topQuickSale b{font-size:11px}.userChip{display:flex;align-items:center;gap:8px;padding:5px 8px 5px 5px;border:1px solid #e6ebf2;border-radius:12px;background:#fff}.userAvatar{width:32px;height:32px;border-radius:9px;background:linear-gradient(135deg,#102b52,#1c82df);color:#fff;display:grid;place-items:center;font-size:11px;font-weight:900}.userChip b,.userChip small{display:block}.userChip b{font-size:11px}.userChip small{font-size:9px;color:#8b96a5}.dfContent{max-width:1760px;padding:20px 22px 34px}
.sidebar-collapsed.dfShell{grid-template-columns:76px minmax(0,1fr)}.sidebar-collapsed .dfBrand{justify-content:center}.sidebar-collapsed .dfBrand .brandText,.sidebar-collapsed .versionPill,.sidebar-collapsed .workspaceBadge,.sidebar-collapsed .dfMenu .navLabel,.sidebar-collapsed .sidebarFoot .navLabel,.sidebar-collapsed .groupName b,.sidebar-collapsed .groupHead .chev{display:none}.sidebar-collapsed .dfBrand .companyLogo,.sidebar-collapsed .dfBrand .appLogo{width:40px;height:40px}.sidebar-collapsed .dfMenu button,.sidebar-collapsed .sidebarFoot button{justify-content:center;padding-left:7px;padding-right:7px}.sidebar-collapsed .dfMenu .groupHead{justify-content:center}.sidebar-collapsed .groupName i{font-size:13px}.sidebar-collapsed .submenu{padding-left:0}
.dashboardLoading{height:320px;display:grid;place-items:center;align-content:center;gap:12px;color:#718096}.loadingPulse{width:38px;height:38px;border-radius:50%;border:4px solid #dfe8f4;border-top-color:#1976e9;animation:dfspin .8s linear infinite}@keyframes dfspin{to{transform:rotate(360deg)}}.dashboardHero{position:relative;overflow:hidden;display:flex;justify-content:space-between;align-items:center;gap:20px;padding:22px 24px;border-radius:18px;background:radial-gradient(circle at 88% 18%,rgba(43,190,235,.34),transparent 29%),linear-gradient(115deg,#0a1d3b,#123b68 58%,#126bbd);color:#fff;box-shadow:0 16px 36px rgba(12,39,74,.16);margin-bottom:14px}.dashboardHero:after{content:"";position:absolute;width:180px;height:180px;border:1px solid rgba(255,255,255,.08);border-radius:50%;right:110px;top:-92px}.dashboardHero .eyebrow{font-size:9px;font-weight:900;letter-spacing:.15em;color:#70d9ff}.dashboardHero h1{font-size:24px;margin:4px 0 4px;letter-spacing:-.025em}.dashboardHero h1 span{font-weight:400;color:#c4d9ee}.dashboardHero p{margin:0;color:#aecaE7;font-size:12px}.heroActions{display:flex;gap:8px;position:relative;z-index:1}.heroAction{border:1px solid rgba(255,255,255,.18);background:rgba(255,255,255,.07);color:#fff;border-radius:10px;padding:10px 13px;font-weight:800;cursor:pointer}.heroAction.primary{background:#fff;color:#0c4f91;border-color:#fff}.dashboardFilterRow{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:14px 0}.filterTitle b,.filterTitle small{display:block}.filterTitle b{font-size:14px}.filterTitle small{font-size:10px;color:#8994a5;margin-top:2px}.dashboardFilters{margin:0;box-shadow:none!important;padding:6px 7px;border-radius:11px!important;display:flex;align-items:flex-end}.dashboardFilters .field{min-width:132px}.dashboardFilters .field label{font-size:9px}.dashboardFilters input{padding:7px 9px!important}.premiumQuick{grid-template-columns:repeat(4,minmax(0,1fr));margin-bottom:14px}.premiumQuick button{min-height:74px;border:1px solid #e3e9f1;background:#fff;border-radius:13px;padding:12px;display:grid;grid-template-columns:38px 1fr auto;align-items:center;gap:10px;text-align:left;box-shadow:0 7px 24px rgba(25,45,75,.045);transition:.18s}.premiumQuick button:hover{transform:translateY(-2px);border-color:#bfd8f5;box-shadow:0 12px 28px rgba(25,80,150,.09)}.premiumQuick .quickIcon{width:38px;height:38px;border-radius:11px;background:#edf5ff;color:#1674d8;display:grid;place-items:center;font-size:18px;font-weight:900}.premiumQuick b,.premiumQuick small{display:block}.premiumQuick b{font-size:12px;color:#1e2a3b}.premiumQuick small{font-size:9px;color:#8a95a5;margin-top:3px}.premiumQuick button>i{font-style:normal;color:#a6b0bd}.premiumMetrics{gap:12px}.premiumMetrics .metric{border:1px solid #e4e9f0;border-radius:14px;box-shadow:0 7px 24px rgba(25,45,75,.045);padding:15px 16px}.metricTop{display:flex;align-items:center;justify-content:space-between;color:#7e8a9a;font-size:9px;font-weight:900;letter-spacing:.07em}.metricTop i{font-style:normal;width:28px;height:28px;border-radius:8px;background:#eff5fc;color:#1474dc;display:grid;place-items:center;font-size:13px}.premiumMetrics .value{font-size:24px!important;letter-spacing:-.035em;color:#142033;margin:8px 0 4px!important}.metricFoot{font-size:9px;color:#9aa4b1}.salesMetric .metricTop i{background:#e8f9f2;color:#12885a}.alertMetric .metricTop i{background:#fff3df;color:#bd7410}.alertMetric .value{color:#a96206}.dashboardGrid{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(280px,.45fr);gap:14px}.analyticsGrid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.dfContent .section{border-radius:14px;border-color:#e4e9f0;box-shadow:0 8px 28px rgba(24,43,70,.045)}.dfContent .sectionHead{padding:13px 15px}.dfContent .sectionHead h3{font-size:13px}.dfContent .sectionHead small{display:block;font-size:9px;color:#939daa;margin-top:2px}.sectionLink{border:0;background:transparent;color:#1976e9;font-size:10px;font-weight:800;cursor:pointer}.statusStack{display:grid;gap:9px}.statusStack>div{display:grid;grid-template-columns:10px 1fr auto;gap:8px;align-items:center;padding:9px 10px;background:#f8fafc;border:1px solid #edf0f4;border-radius:9px}.statusStack b{font-size:10px}.statusStack small{font-size:9px;color:#8792a2}.statusLight{width:7px;height:7px;border-radius:50%;background:#e99b2e;box-shadow:0 0 0 3px rgba(233,155,46,.09)}.statusLight.on{background:#24a973;box-shadow:0 0 0 3px rgba(36,169,115,.09)}.barTrack{background:#edf1f6!important;height:7px!important;border-radius:999px!important}.barTrack span{background:linear-gradient(90deg,#176ed1,#22a9e7)!important;border-radius:999px!important}.barLabel{font-size:10px}.barValue{font-size:10px;font-weight:800;color:#506075}
.invoiceScreen{overflow:visible}.invoiceHeader{padding:16px 18px!important;background:linear-gradient(90deg,#fbfdff,#f4f8fd);border-radius:14px 14px 0 0}.invoiceHeader h3{font-size:18px!important;margin:1px 0 2px!important}.invoiceHeader small{font-size:10px;color:#8793a3}.invoiceEyebrow{font-size:8px;font-weight:900;letter-spacing:.13em;color:#1976e9}.invoiceScreen>.sectionBody>.notice{border-radius:10px}.invoiceDetailSection{border:1px solid #e5eaf1!important;background:#fff}.invoiceDetailSection .sectionHead{background:#f8fafc}.invoiceTotals{border:0;background:linear-gradient(180deg,#0e2948,#123b62);color:#fff;border-radius:14px;box-shadow:0 14px 32px rgba(10,38,71,.18);padding:15px}.invoiceTotals .totalsBadge{font-size:8px;font-weight:900;letter-spacing:.13em;color:#72d6ff;margin-bottom:8px}.invoiceTotals .field label{color:#c6d4e3}.invoiceTotals select,.invoiceTotals input{background:rgba(255,255,255,.98)}.invoiceTotals .totalRow{color:#d7e2ed}.invoiceTotals .totalRow b{color:#fff}.invoiceTotals .totalRow.grand{border-top-color:rgba(255,255,255,.16);font-size:22px}.invoiceTotals .check{border-color:rgba(255,255,255,.13);background:rgba(255,255,255,.04);color:#e8f0f8}.invoiceTotals .btn.primary{background:linear-gradient(135deg,#1e94ee,#24b3e7);box-shadow:0 8px 20px rgba(27,160,230,.21)}.itemsTable tbody tr:hover{background:#f7fbff}.itemsTable th{background:#f4f7fb;color:#637083}.field input:focus,.field select:focus,.field textarea:focus,.toolbar input:focus,.toolbar select:focus{outline:none;border-color:#6ca9eb;box-shadow:0 0 0 3px rgba(25,118,233,.09)}
@media(max-width:1100px){.premiumQuick{grid-template-columns:1fr 1fr}.dashboardGrid{grid-template-columns:1fr}.topQuickSale{display:none}}
@media(max-width:900px){.dfShell{grid-template-columns:1fr}.dfSidebar{width:264px;left:-280px}.dfTopbar{height:66px;padding:0 12px}.dfContent{padding:14px}.userChip>div{display:none}.dashboardHero{align-items:flex-start;flex-direction:column}.dashboardFilterRow{align-items:flex-start;flex-direction:column}.dashboardFilters{width:100%}.analyticsGrid{grid-template-columns:1fr}.premiumMetrics{grid-template-columns:1fr 1fr!important}}
@media(max-width:560px){.premiumQuick,.premiumMetrics{grid-template-columns:1fr!important}.dashboardHero{padding:18px}.dashboardHero h1{font-size:20px}.heroActions{width:100%;flex-direction:column}.heroAction{width:100%}.dashboardFilters{display:grid;grid-template-columns:1fr 1fr}.dashboardFilters .btn{grid-column:1/-1}.topbarLeft small{max-width:180px}.userChip{border:0;padding:0}.invoiceHeader{align-items:flex-start!important}.invoiceWork{gap:10px}}

/* === DiomFact v5.6.0 · Professional Business UI === */
.dfIcon{display:block;flex:0 0 auto}.navIco .dfIcon,.groupName .dfIcon{margin:auto}.groupName i{display:grid;place-items:center}.topQuickSale span,.heroAction{display:flex;align-items:center;gap:7px}.heroAction .dfIcon{flex:0 0 auto}.premiumQuick button>i{display:grid;place-items:center}.premiumQuick .quickIcon .dfIcon,.metricTop i .dfIcon{margin:auto}
.moduleLauncher{margin:0 0 14px;background:#fff;border:1px solid #e4e9f0;border-radius:15px;box-shadow:0 8px 28px rgba(24,43,70,.04);padding:14px}.moduleLauncherHead{display:flex;align-items:center;justify-content:space-between;margin-bottom:11px}.moduleLauncherHead b,.moduleLauncherHead small{display:block}.moduleLauncherHead b{font-size:13px;color:#182638}.moduleLauncherHead small{font-size:9px;color:#8d98a7;margin-top:2px}.moduleGrid{display:grid;grid-template-columns:repeat(8,minmax(105px,1fr));gap:9px}.moduleTile{min-height:100px;border:1px solid #e7ebf1;border-radius:12px;background:#fff;padding:12px 10px;cursor:pointer;text-align:left;display:flex;flex-direction:column;justify-content:center;gap:5px;transition:.18s;position:relative;overflow:hidden}.moduleTile:before{content:"";position:absolute;inset:0 auto 0 0;width:3px;background:var(--tile,#1d79dc)}.moduleTile>span{width:34px;height:34px;border-radius:10px;display:grid;place-items:center;background:color-mix(in srgb,var(--tile,#1d79dc) 10%,white);color:var(--tile,#1d79dc)}.moduleTile b{font-size:11px;color:#1f2d40}.moduleTile small{font-size:8.5px;line-height:1.25;color:#8793a3}.moduleTile:hover{transform:translateY(-2px);border-color:color-mix(in srgb,var(--tile,#1d79dc) 35%,#e7ebf1);box-shadow:0 10px 24px rgba(25,50,85,.08)}.tone-blue{--tile:#176ed1}.tone-violet{--tile:#7c5ce7}.tone-cyan{--tile:#1098ad}.tone-green{--tile:#159a6d}.tone-amber{--tile:#c17b13}.tone-rose{--tile:#c84f73}.tone-slate{--tile:#53657d}.tone-indigo{--tile:#4f63d9}

.posCatalogPanel{border:1px solid #e4e9f0;background:linear-gradient(180deg,#fbfdff,#f7f9fc);border-radius:14px;margin:13px 0;padding:14px}.posCatalogHead{display:flex;justify-content:space-between;align-items:flex-end;gap:14px;margin-bottom:12px}.posCatalogHead h3{margin:2px 0 2px;font-size:14px}.posCatalogHead small{font-size:9px;color:#8995a5}.posCatalogFilters{display:flex;align-items:center;gap:8px}.posSearch{height:36px;min-width:260px;display:flex;align-items:center;gap:7px;border:1px solid #dce3ec;background:#fff;border-radius:9px;padding:0 10px;color:#7c8a9d}.posSearch input{border:0!important;box-shadow:none!important;padding:0!important;min-width:0;width:100%;background:transparent}.posCatalogFilters select{height:36px;border:1px solid #dce3ec;background:#fff;border-radius:9px;padding:0 9px;color:#4a596d}.posCatalogGrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(145px,1fr));gap:9px;max-height:350px;overflow:auto;padding:2px 3px 3px 1px}.posProductCard{border:1px solid #e2e8f0;background:#fff;border-radius:12px;padding:8px;min-height:190px;display:flex;flex-direction:column;gap:8px;text-align:left;cursor:pointer;transition:.16s;position:relative}.posProductCard:hover:not(:disabled){transform:translateY(-2px);border-color:#aad0f6;box-shadow:0 10px 24px rgba(28,91,157,.09)}.posProductPhoto{height:102px;border-radius:9px;overflow:hidden;background:#f2f6fa;display:grid;place-items:center;color:#7d8ca0}.posProductPhoto img{width:100%;height:100%;object-fit:cover}.posProductPhoto.noPhoto{background:linear-gradient(145deg,#eef4fa,#f7f9fc)}.posProductInfo{display:flex;flex-direction:column;min-width:0;flex:1}.posProductInfo>b{font-size:10.5px;line-height:1.25;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:27px;color:#223044}.posProductInfo>small{font-size:8px;color:#8d98a8;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:2px}.posProductBottom{display:flex;justify-content:space-between;align-items:flex-end;gap:5px;margin-top:auto;padding-top:8px}.posProductBottom strong{font-size:13px;color:#0b69c7}.posProductBottom em{font-style:normal;font-size:7.5px;border-radius:999px;padding:3px 5px;background:#e8f7f0;color:#16845d;white-space:nowrap}.posProductCard.lowStock .posProductBottom em{background:#fff0dd;color:#ad670b}.posProductCard.outOfStock{opacity:.58;cursor:not-allowed}.posProductCard.outOfStock .posProductBottom em{background:#ffe6e6;color:#b32d2d}.posCatalogEmpty{grid-column:1/-1;padding:28px;text-align:center;color:#8b96a5;border:1px dashed #d7dee8;border-radius:10px;background:#fff}

.bankHero{position:relative;overflow:hidden;display:flex;justify-content:space-between;align-items:center;gap:18px;padding:20px 22px;border-radius:16px;background:linear-gradient(115deg,#0b2340,#174a6f 60%,#126b8f);color:#fff;box-shadow:0 14px 34px rgba(12,39,74,.14);margin-bottom:13px}.bankHero:after{content:"";position:absolute;width:190px;height:190px;border:1px solid rgba(255,255,255,.08);border-radius:50%;right:90px;top:-110px}.bankHero h2{margin:3px 0 3px;font-size:22px}.bankHero p{margin:0;color:#b9d3e3;font-size:10px}.bankHero .invoiceEyebrow{color:#6ee0ff}.bankHeroActions{display:flex;gap:7px;z-index:1}.bankHeroActions .btn{display:flex;align-items:center;gap:6px;background:rgba(255,255,255,.1);border-color:rgba(255,255,255,.2);color:#fff}.bankHeroActions .btn.primary{background:#fff;color:#155476;border-color:#fff}.bankMetrics{margin-bottom:13px}.bankLayout{display:grid;grid-template-columns:minmax(260px,.34fr) minmax(0,.66fr);gap:13px}.bankAccounts{display:grid;gap:8px}.bankAccountCard{width:100%;border:1px solid #e4e9f0;background:#fff;border-radius:12px;padding:11px;display:grid;grid-template-columns:38px minmax(0,1fr) auto;grid-template-areas:"icon text balance" "icon text status";gap:2px 9px;text-align:left;cursor:pointer;transition:.16s}.bankAccountCard:hover{border-color:#bfd7ef;box-shadow:0 8px 20px rgba(25,70,115,.07)}.bankAccountIcon{grid-area:icon;width:38px;height:38px;border-radius:10px;background:#eaf4fc;color:#1373b8;display:grid;place-items:center}.bankAccountText{grid-area:text;min-width:0}.bankAccountText b,.bankAccountText small{display:block}.bankAccountText b{font-size:10.5px;color:#26354a}.bankAccountText small{font-size:8px;color:#8b96a5;margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.bankAccountCard>strong{grid-area:balance;text-align:right;font-size:12px;color:#173a58}.bankAccountCard>em{grid-area:status;text-align:right;font-size:7px;font-style:normal;color:#17815b}.bankAccountCard.archived{opacity:.58}.bankAccountCard.archived>em{color:#8793a3}.bankLayout .sectionHead .actions{display:flex;align-items:center;gap:6px}.bankLayout .sectionHead select{height:31px;border:1px solid #dce3ec;border-radius:8px;background:#fff;padding:0 8px;font-size:9px}.bankAmount{font-weight:850;white-space:nowrap}.bankAmount.positive{color:#14804a}.bankAmount.negative{color:#b94646}.reconcileBadge,.sourceBadge{display:inline-flex;align-items:center;border-radius:999px;padding:4px 7px;font-size:7.5px;font-weight:800;white-space:nowrap}.reconcileBadge.done{background:#e7f7f0;color:#16805a}.reconcileBadge.pending{background:#fff0dc;color:#a7630d}.sourceBadge{background:#eef3f8;color:#65758a}.bankImportPreview{margin-top:12px}.bankImportPreview .tableWrap{margin-top:8px;max-height:230px}.errorInline{color:#b42318;font-weight:700}.num{text-align:right}

@media(max-width:1380px){.moduleGrid{grid-template-columns:repeat(4,minmax(120px,1fr))}.bankLayout{grid-template-columns:1fr}.posCatalogGrid{grid-template-columns:repeat(auto-fill,minmax(135px,1fr))}}
@media(max-width:900px){.moduleGrid{grid-template-columns:repeat(2,minmax(0,1fr))}.posCatalogHead{align-items:stretch;flex-direction:column}.posCatalogFilters{width:100%}.posSearch{min-width:0;flex:1}.bankHero{align-items:flex-start;flex-direction:column}.bankHeroActions{width:100%;flex-wrap:wrap}.bankHeroActions .btn{flex:1;justify-content:center}.bankLayout .sectionHead{align-items:flex-start;gap:8px}.bankLayout .sectionHead .actions{width:100%;flex-wrap:wrap}.bankLayout .sectionHead select{flex:1}}
@media(max-width:560px){.moduleGrid{grid-template-columns:1fr 1fr}.moduleTile{min-height:92px}.posCatalogFilters{display:grid;grid-template-columns:1fr}.posCatalogGrid{grid-template-columns:1fr 1fr;max-height:430px}.posProductCard{min-height:168px}.posProductPhoto{height:82px}.bankHeroActions{display:grid;grid-template-columns:1fr;width:100%}.bankAccountCard{grid-template-columns:34px minmax(0,1fr);grid-template-areas:"icon text" "balance balance" "status status"}.bankAccountCard>strong,.bankAccountCard>em{text-align:left;margin-left:43px}.bankLayout .sectionHead .actions{display:grid;grid-template-columns:1fr 1fr}.bankLayout .sectionHead .actions .btn{grid-column:1/-1}}
