:root{--primary:#2563eb;--primary-2:#1d4ed8;--bg:#f4f7fb;--panel:#fff;--text:#0f172a;--muted:#64748b;--border:#dbe5f1;--soft:#eef4fb;--success:#10b981;--danger:#ef4444;--warning:#f59e0b;--shadow:0 18px 50px rgba(15,23,42,.08);--radius:20px;--sidebar:260px}
:root[data-theme=dark]{--bg:#09111f;--panel:#111b2e;--text:#e7edf8;--muted:#94a3b8;--border:#263552;--soft:#16233a;--shadow:0 18px 50px rgba(0,0,0,.25)}
*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif;color:var(--text);background:var(--bg)}button,input,select,textarea{font:inherit}button,a{transition:.18s ease}a{color:var(--primary);text-decoration:none}h1,h2,h3,h4,p{margin-top:0}.muted{color:var(--muted)}
.btn{border:0;border-radius:12px;padding:12px 18px;font-weight:750;cursor:pointer;background:var(--soft);color:var(--text);display:inline-flex;align-items:center;justify-content:center;gap:8px}.btn:hover{transform:translateY(-1px);filter:brightness(.98)}.btn:disabled{opacity:.55;cursor:not-allowed;transform:none}.btn.primary{background:var(--primary);color:#fff;box-shadow:0 10px 24px color-mix(in srgb,var(--primary) 25%,transparent)}.btn.success{background:var(--success);color:#fff}.btn.danger{background:var(--danger);color:#fff}.btn.warning{background:#fff7e7;color:#9a5c00;border:1px solid #f7d58e}.btn.ghost{background:var(--soft);border:1px solid var(--border)}.btn.wide{width:100%}.btn.large{padding:15px 24px;font-size:16px}.icon-btn{border:0;background:var(--soft);width:40px;height:40px;border-radius:12px;cursor:pointer;font-size:20px;color:var(--text)}.icon-btn.danger{color:var(--danger);background:#fff0f1}.mini{border:0;border-radius:9px;padding:8px 11px;background:var(--soft);font-weight:700;cursor:pointer}.mini.warning{background:#fff6df;color:#9a6200}.mini.danger{background:#fff0f1;color:#d92d3c}.mini:disabled{opacity:.4;cursor:not-allowed}
.input{width:100%;border:1px solid var(--border);background:var(--panel);color:var(--text);padding:12px 14px;border-radius:12px;outline:0;min-height:46px}.input:focus{border-color:var(--primary);box-shadow:0 0 0 3px color-mix(in srgb,var(--primary) 14%,transparent)}textarea.input{min-height:95px;resize:vertical}.form-field{display:flex;flex-direction:column;gap:7px}.form-field>span{font-size:13px;font-weight:750;color:var(--muted)}.form-grid{display:grid;gap:14px;margin:14px 0}.form-grid.two{grid-template-columns:repeat(2,minmax(0,1fr))}.form-grid.three{grid-template-columns:repeat(3,minmax(0,1fr))}.form-grid.four{grid-template-columns:repeat(4,minmax(0,1fr))}.span2{grid-column:span 2}.span3{grid-column:span 3}
.app-shell{min-height:100vh;display:grid;grid-template-columns:var(--sidebar) minmax(0,1fr)}.sidebar{position:fixed;inset:0 auto 0 0;width:var(--sidebar);background:#0c1930;color:#fff;display:flex;flex-direction:column;z-index:30;overflow:auto}.sidebar-brand{display:flex;align-items:center;gap:12px;padding:22px 18px;border-bottom:1px solid rgba(255,255,255,.08)}.sidebar-logo{width:48px;height:48px;border-radius:14px;background:#fff;display:flex;align-items:center;justify-content:center;overflow:hidden}.sidebar-logo img{max-width:100%;max-height:100%;object-fit:contain}.sidebar-brand strong{display:block;font-size:16px}.sidebar-brand small{color:#9eb2d3}.sidebar nav{padding:14px;display:flex;flex-direction:column;gap:6px;flex:1}.nav-link{color:#d8e2f2;display:flex;align-items:center;gap:12px;padding:12px 13px;border-radius:12px;font-weight:700;font-size:14px}.nav-link:hover{background:rgba(255,255,255,.07);color:#fff}.nav-link.active{background:rgba(255,255,255,.14);color:#fff;box-shadow:inset 3px 0 0 #4d88ff}.nav-icon{width:21px;text-align:center;font-size:17px}.sidebar-foot{padding:16px;border-top:1px solid rgba(255,255,255,.08)}.license-mini{display:flex;gap:9px;align-items:center;padding:10px;border-radius:12px;background:rgba(255,255,255,.06);margin-bottom:9px}.license-mini b,.license-mini small{display:block}.license-mini small{color:#9eb2d3;font-size:11px}.status-dot{width:9px;height:9px;border-radius:50%;background:#16c784;box-shadow:0 0 0 4px rgba(22,199,132,.12);display:inline-block}.logout{display:block;color:#ffb5b5;font-weight:700;padding:10px}.content{grid-column:2;min-width:0}.topbar{height:88px;padding:18px 32px;background:color-mix(in srgb,var(--bg) 84%,transparent);backdrop-filter:blur(14px);position:sticky;top:0;z-index:20;border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;gap:20px}.topbar h1{font-size:25px;margin-bottom:3px}.topbar p{margin:0;color:var(--muted);font-size:13px}.top-actions{display:flex;align-items:center;gap:10px}.user-pill{background:var(--panel);border:1px solid var(--border);padding:9px 13px;border-radius:14px;min-width:170px}.user-pill b,.user-pill small{display:block}.user-pill small{font-size:11px;color:var(--muted)}.notification-btn{position:relative;border:1px solid var(--border);background:var(--panel);border-radius:13px;width:44px;height:44px;cursor:pointer}.notification-btn span{position:absolute;right:-4px;top:-4px;background:var(--danger);color:#fff;font-size:10px;min-width:18px;height:18px;border-radius:20px;display:grid;place-items:center}.hamburger{display:none;border:0;background:var(--panel);font-size:22px;width:44px;height:44px;border-radius:12px}.page-content{padding:26px 32px 50px}.mobile-shade{display:none}
.page-toolbar{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:18px}.page-toolbar h2{margin-bottom:5px}.page-toolbar p{color:var(--muted);margin:0}.page-toolbar>div:last-child{display:flex;gap:9px;flex-wrap:wrap}.card{background:var(--panel);border:1px solid var(--border);border-radius:var(--radius);padding:20px;box-shadow:var(--shadow);margin-bottom:18px;min-width:0}.card-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:16px}.card-head h2{font-size:19px;margin-bottom:4px}.card-head p{color:var(--muted);margin:0;font-size:13px}.eyebrow{text-transform:uppercase;letter-spacing:.1em;font-size:11px;font-weight:850;color:var(--primary)}.hero-strip,.backup-hero,.mobile-inventory-hero{background:linear-gradient(135deg,#0c1930,#1d4ed8);color:#fff;border-radius:24px;padding:25px 28px;display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:20px;box-shadow:0 22px 50px rgba(29,78,216,.22)}.hero-strip h2,.backup-hero h2,.mobile-inventory-hero h2{font-size:27px;margin:5px 0}.hero-strip p,.backup-hero p,.mobile-inventory-hero p{margin:0;color:#c9daf8}.hero-actions{display:flex;gap:10px}.hero-strip .btn.ghost,.backup-hero .btn.ghost,.mobile-inventory-hero .btn.ghost{background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.2);color:#fff}
.kpi-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:14px;margin-bottom:18px}.kpi{background:var(--panel);border:1px solid var(--border);border-radius:18px;padding:18px;box-shadow:var(--shadow);min-height:126px;position:relative;overflow:hidden}.kpi:after{content:"";position:absolute;width:84px;height:84px;border-radius:50%;right:-27px;top:-28px;background:color-mix(in srgb,var(--primary) 10%,transparent)}.kpi span{display:block;text-transform:uppercase;font-size:11px;letter-spacing:.06em;color:var(--muted);font-weight:850}.kpi strong{display:block;font-size:25px;margin:12px 0 4px}.kpi small{color:var(--muted)}.kpi.warning strong,.danger-text{color:var(--danger)}.good{color:var(--success)}.dashboard-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}.dashboard-grid .card{margin:0}.dashboard-grid .span2{grid-column:span 2}.line-chart{height:270px;background:linear-gradient(180deg,var(--soft),transparent);border-radius:16px;padding:10px}.line-chart svg{width:100%;height:225px;overflow:visible}.chart-labels{display:flex;justify-content:space-between;color:var(--muted);font-size:10px;padding:0 15px}.payment-summary>div{margin:13px 0}.payment-summary span,.payment-summary b{display:inline-block}.payment-summary b{float:right}.payment-summary i{display:block;height:8px;background:var(--soft);border-radius:10px;overflow:hidden;margin-top:7px}.payment-summary em{display:block;height:100%;background:linear-gradient(90deg,var(--primary),#60a5fa);border-radius:10px}.alert-row{display:flex;align-items:center;gap:10px;padding:10px;border-bottom:1px solid var(--border)}.alert-row>span{width:10px;height:10px;border-radius:50%;background:var(--warning)}.alert-row.danger>span{background:var(--danger)}.alert-row.info>span{background:var(--primary)}.alert-row b,.alert-row small{display:block}.alert-row small{color:var(--muted);margin-top:2px}.activity-row{display:flex;align-items:center;gap:10px;padding:9px 0;border-bottom:1px solid var(--border)}.activity-row .avatar{width:36px;height:36px;border-radius:11px;background:var(--soft);display:grid;place-items:center;font-weight:800}.activity-row b,.activity-row small{display:block}.activity-row small{color:var(--muted);font-size:11px}
.table-wrap{width:100%;overflow:auto;border:1px solid var(--border);border-radius:14px}.table-wrap table{width:100%;border-collapse:collapse;min-width:760px}.table-wrap th{text-align:left;padding:13px 12px;background:var(--soft);font-size:11px;text-transform:uppercase;letter-spacing:.05em;color:var(--muted)}.table-wrap td{padding:13px 12px;border-top:1px solid var(--border);vertical-align:middle}.table-wrap tr:hover td{background:color-mix(in srgb,var(--soft) 45%,transparent)}.empty-cell{text-align:center;color:var(--muted);padding:25px!important}.row-actions{display:flex;gap:6px;flex-wrap:wrap}.status{display:inline-flex;padding:6px 9px;border-radius:99px;font-size:11px;font-weight:800;background:var(--soft)}.status.completed,.status.publish{background:#dcfce8;color:#087443}.status.cancelled{background:#fee2e2;color:#b42318}.status.warning{background:#fff1cc;color:#946200}.status.liquidation{background:#f3e8ff;color:#7e22ce}.product-cell{display:flex;align-items:center;gap:10px}.thumb{width:42px;height:42px;border-radius:10px;background:var(--soft);display:grid;place-items:center;overflow:hidden}.thumb img{width:100%;height:100%;object-fit:cover}.product-cell b,.product-cell small{display:block}.product-cell small{color:var(--muted);font-size:11px}.filter-row{display:grid;grid-template-columns:minmax(240px,1fr) 220px;gap:10px;margin-bottom:14px}
/* Terminal */
.terminal-shell{height:100vh;display:grid;grid-template-columns:minmax(0,1fr) minmax(440px,1fr);gap:12px;padding:12px;background:var(--bg);overflow:hidden}.terminal-products,.cart-panel{background:var(--panel);border:1px solid var(--border);border-radius:20px;min-height:0}.terminal-products{display:grid;grid-template-rows:auto auto auto minmax(0,1fr) auto;padding:14px}.terminal-head{display:flex;justify-content:space-between;align-items:center;gap:12px}.terminal-head h1{font-size:22px;margin-bottom:2px}.terminal-head p{margin:0;color:var(--muted);font-size:12px}.terminal-head>div:last-child{display:flex;gap:7px;flex-wrap:wrap;justify-content:flex-end}.terminal-tools{display:grid;grid-template-columns:minmax(0,1fr) 230px;gap:9px;margin:13px 0}.product-grid{min-height:0;overflow:auto;display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));align-content:start;gap:10px;padding:1px 3px 10px}.product-card{position:relative;border:1px solid var(--border);background:var(--panel);color:var(--text);border-radius:16px;padding:11px;text-align:left;cursor:pointer;min-height:168px;display:flex;flex-direction:column;overflow:hidden}.product-card:hover{border-color:var(--primary);box-shadow:0 12px 28px color-mix(in srgb,var(--primary) 15%,transparent);transform:translateY(-2px)}.product-card.low{border-color:#fdba74}.product-image{height:66px;background:var(--soft);border-radius:12px;display:grid;place-items:center;overflow:hidden;margin-bottom:9px}.product-image img{width:100%;height:100%;object-fit:contain}.product-placeholder{font-size:30px;color:#64748b}.product-info h3{font-size:14px;line-height:1.15;margin:0 0 6px}.product-info span,.product-info small,.product-info em{display:block;font-size:11px;color:var(--muted);font-style:normal}.product-info b{display:block;margin-top:7px;font-size:17px}.product-info em{color:#b45309;margin-top:4px}.corner-badge{position:absolute;right:6px;top:6px;background:#7e22ce;color:#fff;border-radius:20px;padding:4px 7px;font-size:9px;font-weight:800;z-index:2}.hotkeys{display:flex;gap:7px;flex-wrap:wrap;border-top:1px solid var(--border);padding-top:10px}.hotkeys span{background:var(--soft);padding:7px 10px;border-radius:99px;font-size:11px;color:var(--muted)}.hotkeys b{color:var(--primary)}.sales-badge{display:inline-grid;place-items:center;min-width:22px;height:22px;padding:0 6px;background:var(--primary);color:#fff;border-radius:999px;font-size:11px;font-weight:800;margin-left:6px}.cart-panel{display:flex;flex-direction:column;padding:14px;overflow:hidden}.cart-head{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.cart-head h2{font-size:21px}.cart-meta{display:flex;gap:8px;flex-wrap:wrap;margin-top:6px}.cart-meta span{background:var(--soft);border:1px solid var(--border);border-radius:999px;padding:5px 10px;font-size:11px;color:var(--muted);font-weight:700}.cart-columns{display:grid;grid-template-columns:minmax(0,1fr) 126px 96px 38px;gap:10px;padding:10px 10px 7px;margin-top:10px;border-bottom:1px solid var(--border);color:var(--muted);font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.06em}.cart-columns span:nth-child(2),.cart-columns span:nth-child(3){text-align:center}.cart-items{flex:1;overflow:auto;min-height:150px;margin:0 0 10px;padding-right:4px;border-bottom:1px solid var(--border)}.cart-item{display:grid;grid-template-columns:minmax(0,1fr) 126px 96px 38px;align-items:center;gap:10px;padding:10px 10px;margin:10px 0;border:1px solid var(--border);border-radius:16px;background:var(--panel)}.cart-item.active-last{border-color:var(--primary);box-shadow:0 0 0 3px color-mix(in srgb,var(--primary) 15%, transparent),0 10px 24px rgba(37,99,235,.12)}.cart-item-main{display:grid;gap:6px;min-width:0}.cart-item-title{display:flex;align-items:flex-start;gap:9px}.cart-line-number{flex:0 0 25px;height:25px;border-radius:8px;background:var(--soft);border:1px solid var(--border);display:grid!important;place-items:center;color:var(--primary)!important;font-size:11px!important;font-weight:900}.cart-item-title>div{min-width:0}.cart-item-title h4{font-size:14px;line-height:1.15;margin:0 0 4px}.cart-item-title span{font-size:11px;color:var(--muted);display:block;word-break:break-word}.cart-item-price{font-size:12px;color:var(--text);font-weight:700}.cart-item-price small{font-size:10px;color:var(--muted);font-weight:600}.cart-item-price em{display:block;color:#b42318;font-style:normal;font-size:10px;margin-top:3px}.cart-qty-wrap{display:grid;grid-template-columns:32px minmax(0,1fr) 32px;gap:6px;align-items:center}.qty-btn{border:1px solid var(--border);background:var(--soft);border-radius:10px;height:36px;font-weight:900;cursor:pointer;color:var(--text)}.qty-btn:hover{border-color:var(--primary);color:var(--primary)}.cart-item .input{padding:8px;min-height:38px;text-align:center}.cart-line-total{text-align:right}.cart-line-total b{display:block;font-size:15px}.cart-line-total small{font-size:10px;color:var(--muted);display:block;margin-top:4px;white-space:nowrap}.cart-summary>label{display:block;font-size:12px}.cart-summary>label .input{margin-top:5px}.summary-line,.summary-total{display:flex;justify-content:space-between;align-items:center;margin-top:10px}.summary-line span{color:var(--muted)}.summary-total{font-size:22px;margin:12px 0}.cart-summary{position:sticky;bottom:0;background:linear-gradient(180deg,color-mix(in srgb,var(--panel) 72%,transparent),var(--panel) 18px);padding-top:10px}.recent-sales{margin-top:12px;max-height:150px;overflow:auto}.recent-sales h3{font-size:13px}.recent-sales>div{display:grid;grid-template-columns:1fr auto auto auto;gap:7px;align-items:center;padding:6px 0;font-size:11px}.recent-sales button{border:0;background:var(--soft);border-radius:7px;padding:5px;cursor:pointer}.recent-sales-modal{display:flex;flex-direction:column;gap:10px;max-height:70vh;overflow:auto;padding-right:4px}.recent-sale-card{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:10px;padding:12px;border:1px solid var(--border);border-radius:16px;background:var(--soft)}.recent-sale-card.wide .recent-sale-main b{display:block;font-size:15px}.recent-sale-card.wide .recent-sale-main small{display:block;color:var(--muted);font-size:12px;margin-top:4px}.recent-sale-total{text-align:right}.recent-sale-total b{display:block}.recent-sale-total small{display:block;color:#b45309;font-size:11px;margin-top:4px}.recent-sale-actions{display:flex;gap:8px;flex-wrap:wrap}.recent-sale-actions button{border:1px solid var(--border);background:#fff;border-radius:10px;padding:8px 12px;cursor:pointer}.recent-sale-actions button:hover{border-color:var(--primary);color:var(--primary)}.edit-banner{display:flex;align-items:center;gap:12px;background:#fff7d6;border:1px solid #f8d570;color:#7c5600;padding:9px 11px;border-radius:12px;margin-top:10px}.edit-banner span{font-size:12px;flex:1}.edit-banner button{border:0;background:transparent;color:#7c5600;font-weight:800}.empty-state{grid-column:1/-1;text-align:center;padding:50px 15px;color:var(--muted)}.empty-state.compact{padding:30px 10px}.cart-panel.collapsed .cart-items,.cart-panel.collapsed .recent-sales{display:none}
/* Modals */
.modal-backdrop{position:fixed;inset:0;background:rgba(5,12,25,.7);backdrop-filter:blur(7px);z-index:100;display:flex;align-items:center;justify-content:center;padding:18px}.modal-card{background:var(--panel);border:1px solid var(--border);border-radius:24px;padding:20px;width:min(100%,560px);max-height:92vh;overflow:auto;box-shadow:0 30px 90px rgba(0,0,0,.32)}.modal-card.small{width:min(100%,440px)}.modal-card.medium{width:min(100%,720px)}.modal-card.large{width:min(100%,900px)}.modal-card.xlarge{width:min(100%,1080px)}.modal-card.checkout{width:min(100%,650px)}.modal-card.success{width:min(100%,520px);text-align:center}.modal-head{display:flex;justify-content:space-between;gap:16px;margin-bottom:16px}.modal-head h2{margin:3px 0 5px}.modal-head p{margin:0;color:var(--muted)}.modal-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:18px;flex-wrap:wrap}.modal-actions.left{justify-content:flex-start}.modal-actions.center{justify-content:center}.checkout-total{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-bottom:14px}.checkout-total>div,.payment-result>div{background:var(--soft);border-radius:16px;padding:15px}.checkout-total span,.payment-result span{display:block;color:var(--muted);font-size:12px}.checkout-total b{font-size:25px}.payment-result{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:14px}.payment-result b{font-size:20px}.success-icon{width:78px;height:78px;border-radius:50%;background:#d9f9eb;color:#079461;display:grid;place-items:center;font-size:38px;font-weight:900;margin:5px auto 15px}.success-content h2{font-size:29px;margin:6px 0}.success-content>p{color:var(--muted)}.success-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;margin:16px 0}.success-grid>div{background:var(--soft);border-radius:13px;padding:12px}.success-grid span,.success-grid b{display:block}.success-grid span{font-size:11px;color:var(--muted)}.invoice-detail{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:14px 0}.invoice-detail>div{background:var(--soft);padding:12px;border-radius:13px}.invoice-detail span,.invoice-detail b{display:block}.invoice-detail span{font-size:11px;color:var(--muted)}.invoice-grand{display:flex;justify-content:flex-end;align-items:center;gap:20px;font-size:22px;padding-top:15px}.substitute-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px}.return-items{display:flex;flex-direction:column;gap:8px;max-height:330px;overflow:auto}.return-item{display:grid;grid-template-columns:minmax(0,1fr) 90px 140px;gap:10px;align-items:center;border:1px solid var(--border);padding:11px;border-radius:13px}.return-item>label:first-child{display:flex;align-items:center;gap:10px}.return-item b,.return-item small,.return-item em{display:block}.return-item small{color:var(--muted)}.return-item em{color:var(--danger);font-style:normal}.return-item.blocked{opacity:.6;background:var(--soft)}
/* Scanner */
.scanner-box{height:300px;background:#020617;border-radius:18px;overflow:hidden;position:relative;margin-bottom:14px}.scanner-box video{width:100%;height:100%;object-fit:cover}.scan-line{position:absolute;left:12%;right:12%;top:50%;height:2px;background:#42f5a7;box-shadow:0 0 18px #42f5a7;animation:scan 2s ease-in-out infinite}.scanner-status{position:absolute;left:12px;right:12px;bottom:12px;background:rgba(0,0,0,.62);color:#fff;padding:9px 12px;border-radius:10px;text-align:center;font-size:12px}@keyframes scan{0%,100%{transform:translateY(-75px)}50%{transform:translateY(75px)}}
/* Product editor */
.product-editor{display:grid;grid-template-columns:180px minmax(0,1fr);gap:16px}.image-uploader{border:1px dashed var(--border);border-radius:16px;padding:12px;height:max-content}.image-preview{height:150px;background:var(--soft);border-radius:13px;display:grid;place-items:center;overflow:hidden;margin-bottom:10px;color:var(--muted)}.image-preview img{width:100%;height:100%;object-fit:contain}.file-btn{position:relative;overflow:hidden;width:100%}.file-btn input{position:absolute;inset:0;opacity:0;cursor:pointer}.option-grid,.switch-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:9px;margin:15px 0}.option-grid label,.switch-row{background:var(--soft);border-radius:12px;padding:11px;font-size:13px;display:flex;align-items:center;gap:8px}.switch-row input{accent-color:var(--primary)}
/* Login */
.login-page{min-height:100vh;display:grid;grid-template-columns:1.15fr .85fr;background:#071225}.login-visual{position:relative;overflow:hidden;background:radial-gradient(circle at 20% 20%,rgba(59,130,246,.36),transparent 30%),linear-gradient(130deg,#0f2c5f,#071225)}.login-visual:before,.login-visual:after{content:"";position:absolute;inset:0;background-image:linear-gradient(90deg,rgba(255,255,255,.035) 1px,transparent 1px),linear-gradient(rgba(255,255,255,.025) 1px,transparent 1px);background-size:64px 64px;transform:perspective(800px) rotateX(58deg) scale(1.5);transform-origin:center bottom}.login-visual:after{inset:12% 6% 0;background:linear-gradient(135deg,transparent 0 20%,rgba(255,255,255,.06) 20% 22%,transparent 22% 40%,rgba(255,255,255,.04) 40% 42%,transparent 42%);filter:blur(.2px)}.visual-overlay{position:absolute;inset:0;background:linear-gradient(90deg,transparent,rgba(7,18,37,.35))}.visual-copy{position:absolute;left:8%;right:8%;bottom:10%;z-index:2;color:#fff;max-width:720px}.visual-copy h1{font-size:clamp(37px,5vw,68px);line-height:1.02;margin:12px 0}.visual-copy p{font-size:18px;color:#c9d8f0;max-width:630px}.visual-pills{display:flex;gap:9px;flex-wrap:wrap;margin-top:25px}.visual-pills span{border:1px solid rgba(255,255,255,.22);background:rgba(255,255,255,.09);padding:9px 13px;border-radius:99px}.login-panel{display:flex;align-items:center;justify-content:center;padding:40px;background:#071225}.login-card{background:#fff;color:#0f172a;width:min(100%,500px);padding:34px;border-radius:28px;box-shadow:0 35px 100px rgba(0,0,0,.36);position:relative}.login-brand{display:flex;gap:12px;align-items:center}.brand-logo{width:54px;height:54px;border-radius:15px;background:#f3f6fb;display:grid;place-items:center;overflow:hidden}.brand-logo.large{width:90px;height:90px;margin:auto}.brand-logo img{max-width:100%;max-height:100%;object-fit:contain}.login-brand h2{margin-bottom:3px}.login-brand small{color:#64748b}.login-heading{margin:30px 0 18px}.login-heading .status-dot{margin-right:7px}.login-heading small{color:#64748b}.login-heading h1{font-size:31px;margin:10px 0 5px}.login-heading p{color:#64748b}.login-card .form-field{margin-bottom:13px}.pass-toggle{position:absolute;right:45px;top:424px;border:0;background:transparent;color:#2563eb;font-weight:700;cursor:pointer}.login-row{display:flex;justify-content:space-between;align-items:center;margin:10px 0 18px;font-size:13px}.login-security{text-align:center;color:#94a3b8;font-size:11px;margin:18px 0 0}.license-page{min-height:100vh;display:grid;place-items:center;background:radial-gradient(circle at top left,#2f6bef,#071225 55%);padding:20px}.license-card{width:min(100%,500px);background:#fff;color:#0f172a;border-radius:28px;padding:34px;text-align:center;box-shadow:0 35px 100px rgba(0,0,0,.35)}.license-card .form-field{text-align:left;margin:18px 0}.badge{display:inline-block;background:#eaf1ff;color:#1d4ed8;border-radius:99px;padding:7px 10px;font-weight:800;font-size:11px;margin-top:15px}.license-note{color:#64748b;font-size:12px;margin-top:16px}
/* Settings, receipts, miscellaneous */
.settings-tabs{display:flex;gap:7px;overflow:auto;margin-bottom:12px}.settings-tabs button{border:1px solid var(--border);background:var(--panel);padding:10px 14px;border-radius:11px;color:var(--text);font-weight:750;white-space:nowrap}.settings-tabs button.active{background:var(--primary);color:#fff;border-color:var(--primary)}.business-logo-row{display:flex;gap:15px;align-items:center;margin-bottom:15px}.logo-preview{width:100px;height:100px}.info-box,.warning-box{border-radius:14px;padding:13px 15px;margin:13px 0;background:#eaf2ff;color:#24519e}.warning-box{background:#fff5db;color:#825a00}.warning-box p{margin:4px 0}.invoice-layout{display:grid;grid-template-columns:1.1fr .9fr;gap:18px}.receipt-preview{width:300px;max-width:100%;margin:auto;border:1px dashed #9ca3af;background:#fff;color:#111;padding:18px;font:12px ui-monospace,Consolas,monospace}.receipt-preview img{max-width:100px;max-height:50px;display:block;margin:auto}.receipt-preview h3{text-align:center;margin:5px}.receipt-preview>small{display:block;text-align:center}.receipt-preview div{display:flex;justify-content:space-between}.preview-total{font-size:18px}.feature-list>div{display:flex;justify-content:space-between;gap:15px;padding:13px 0;border-bottom:1px solid var(--border)}.feature-list b,.feature-list span{display:block}.feature-list span{color:var(--muted);text-align:right}.backup-hero,.mobile-inventory-hero{margin-bottom:18px}.drop-file{display:block;border:1px dashed var(--border);border-radius:14px;padding:30px;text-align:center;background:var(--soft);margin:15px 0;cursor:pointer}.drop-file input{display:none}.button-grid{display:flex;gap:9px;flex-wrap:wrap}.cash-summary{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.cash-summary>div{background:var(--soft);border-radius:13px;padding:13px}.cash-summary span,.cash-summary b{display:block}.cash-summary span{font-size:11px;color:var(--muted)}.notification-list{display:flex;flex-direction:column;gap:9px}.notification{border-left:4px solid var(--primary);background:var(--soft);padding:12px;border-radius:10px}.notification.warning{border-color:var(--warning)}.notification.danger{border-color:var(--danger)}.notification p{margin:3px 0;color:var(--muted)}
.toast{position:fixed;right:18px;bottom:18px;z-index:300;background:#0f172a;color:#fff;border-radius:14px;padding:13px 16px;display:flex;gap:9px;align-items:center;box-shadow:0 20px 55px rgba(0,0,0,.3);opacity:0;transform:translateY(15px)}.toast.show{opacity:1;transform:none}.toast span{width:24px;height:24px;border-radius:50%;display:grid;place-items:center;background:#19b77b}.toast.bad span{background:var(--danger)}
@media print{.sidebar,.topbar,.page-toolbar,.btn,.settings-tabs{display:none!important}.content{grid-column:1}.page-content{padding:0}.card{box-shadow:none;border:0}.app-shell{display:block}}
@media(max-width:1180px){:root{--sidebar:230px}.kpi-grid{grid-template-columns:repeat(3,1fr)}.terminal-shell{grid-template-columns:minmax(0,1fr) 420px}.product-grid{grid-template-columns:repeat(auto-fill,minmax(135px,1fr))}.form-grid.four{grid-template-columns:repeat(2,1fr)}}
@media(max-width:900px){.app-shell{display:block}.sidebar{transform:translateX(-102%);transition:.25s ease}.sidebar.open{transform:none}.content{grid-column:1}.hamburger{display:block}.mobile-shade.show{display:block;position:fixed;inset:0;background:rgba(0,0,0,.45);z-index:25}.topbar{padding:14px 18px}.topbar .top-actions>.btn,.user-pill small{display:none}.user-pill{min-width:auto}.page-content{padding:18px}.kpi-grid{grid-template-columns:repeat(2,1fr)}.dashboard-grid{grid-template-columns:1fr}.dashboard-grid .span2{grid-column:auto}.invoice-layout{grid-template-columns:1fr}.terminal-shell{display:flex;flex-direction:column;height:auto;min-height:100vh;overflow:auto}.terminal-products{min-height:72vh}.cart-panel{min-height:70vh}.product-editor{grid-template-columns:1fr}.image-uploader{display:grid;grid-template-columns:120px 1fr;gap:10px}.image-preview{height:120px}.login-page{grid-template-columns:1fr}.login-visual{min-height:42vh}.visual-copy{bottom:7%}.visual-copy h1{font-size:37px}.login-panel{padding:22px}.pass-toggle{top:auto;bottom:188px}.form-grid.three{grid-template-columns:repeat(2,1fr)}.span3{grid-column:span 2}.hero-strip,.backup-hero,.mobile-inventory-hero{align-items:flex-start;flex-direction:column}}
@media(max-width:600px){.topbar h1{font-size:20px}.notification-btn{display:none}.page-toolbar{align-items:flex-start;flex-direction:column}.page-toolbar>div:last-child{width:100%}.page-toolbar .btn{flex:1}.kpi-grid{grid-template-columns:1fr 1fr;gap:9px}.kpi{padding:14px;min-height:112px}.kpi strong{font-size:19px}.hero-strip h2,.backup-hero h2,.mobile-inventory-hero h2{font-size:22px}.hero-actions{width:100%;display:grid;grid-template-columns:1fr}.form-grid.two,.form-grid.three,.form-grid.four{grid-template-columns:1fr}.span2,.span3{grid-column:auto}.filter-row{grid-template-columns:1fr}.modal-backdrop{padding:8px;align-items:flex-end}.modal-card{border-radius:22px 22px 10px 10px;max-height:94vh;padding:16px}.checkout-total,.payment-result,.success-grid,.invoice-detail{grid-template-columns:1fr}.return-item{grid-template-columns:1fr}.product-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.product-card{min-height:155px;padding:8px}.product-image{height:52px}.terminal-products{padding:8px;border-radius:0}.terminal-head{align-items:flex-start}.terminal-head>div:last-child{flex-wrap:wrap;justify-content:flex-end}.terminal-tools{grid-template-columns:1fr}.hotkeys{position:sticky;bottom:0;background:var(--panel);z-index:4;overflow:auto;flex-wrap:nowrap}.hotkeys span{white-space:nowrap}.cart-panel{border-radius:0}.cart-item{grid-template-columns:minmax(0,1fr) 1fr 72px 34px}.cart-qty-wrap{grid-template-columns:28px minmax(0,1fr) 28px}.cart-item b{font-size:12px}.cart-head{align-items:flex-start}.recent-sales>div{grid-template-columns:1fr auto auto}.recent-sales>div button:last-child{display:none}.login-visual{min-height:38vh}.visual-copy h1{font-size:28px}.visual-copy p{font-size:14px}.visual-pills span{font-size:11px;padding:6px 9px}.login-card{padding:23px;border-radius:22px}.login-heading h1{font-size:25px}.pass-toggle{right:32px}.cash-summary{grid-template-columns:1fr}.option-grid,.switch-grid{grid-template-columns:1fr}.image-uploader{grid-template-columns:1fr}.image-preview{height:150px}.scanner-box{height:250px}}

/* Barcode automation 23.1 */
.automation-hero{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:14px 0 18px}.automation-hero>div{background:linear-gradient(145deg,var(--soft),var(--panel));border:1px solid var(--border);border-radius:15px;padding:14px}.automation-hero b,.automation-hero span{display:block}.automation-hero b{font-size:11px;color:var(--muted);text-transform:uppercase;letter-spacing:.06em}.automation-hero span{font-size:20px;font-weight:850;margin-top:4px}.barcode-result-list,.label-preview-list{display:grid;grid-template-columns:repeat(auto-fill,minmax(155px,1fr));gap:10px;max-height:360px;overflow:auto;margin:15px 0}.barcode-result-list>div,.label-preview-list>div{background:#fff;color:#111;border:1px solid #dce3ec;border-radius:14px;padding:10px;text-align:center;display:flex;flex-direction:column;gap:5px;align-items:center}.ean13{width:100%;height:78px;display:block}.barcode-result-list b,.label-preview-list b{font-size:12px;max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.label-preview-list small{font-weight:800}.barcode-fallback{font:700 12px ui-monospace,monospace;padding:20px 5px}.category-prefix-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(190px,1fr));gap:10px;margin:12px 0 18px}.compact-prefix{background:var(--soft);border:1px solid var(--border);border-radius:13px;padding:10px}.compact-prefix .input{background:var(--panel);font-family:ui-monospace,monospace;font-weight:800;letter-spacing:.15em}.modal-actions.center{justify-content:center}
@media(max-width:700px){.automation-hero{grid-template-columns:1fr}.barcode-result-list,.label-preview-list{grid-template-columns:repeat(2,minmax(0,1fr))}.category-prefix-grid{grid-template-columns:1fr 1fr}}
@media(max-width:440px){.barcode-result-list,.label-preview-list,.category-prefix-grid{grid-template-columns:1fr}}

/* v23.2 QR de factura y etiqueta inmediata */
.qr-image{display:block;width:130px;height:130px;object-fit:contain;background:#fff;border:1px solid #e2e8f0;border-radius:12px;padding:6px}
.invoice-qr-panel{display:flex;align-items:center;gap:18px;margin:18px 0;padding:16px;border:1px solid #bfdbfe;background:#eff6ff;border-radius:18px}.invoice-qr-panel p{margin:5px 0 12px;color:#475569}.product-save-label{width:min(320px,100%);margin:18px auto;padding:16px;border:1px dashed #94a3b8;border-radius:16px;background:#fff;display:flex;flex-direction:column;align-items:center}.product-save-label svg{width:240px;max-width:100%;height:105px}.product-save-label b{margin-top:5px}.product-save-label small{color:#475569}.modal-actions .savePrintProduct{min-width:210px}
@media(max-width:640px){.invoice-qr-panel{align-items:flex-start;flex-direction:column}.qr-image{width:112px;height:112px}.modal-actions .savePrintProduct{min-width:0;width:100%}}

/* v23.3 UX refinements */
.search-hint{margin:-4px 0 10px;color:var(--muted);font-size:12px;background:var(--soft);border:1px solid var(--border);border-radius:12px;padding:9px 12px}
.empty-state.enhanced{display:grid;gap:10px;justify-items:center;align-content:center;min-height:280px;background:linear-gradient(180deg,var(--soft),transparent);border:1px dashed color-mix(in srgb,var(--primary) 35%,var(--border));border-radius:20px;padding:30px}
.empty-state.enhanced p{margin:0;max-width:460px;font-size:13px}
.empty-illustration{width:72px;height:72px;border-radius:999px;display:grid;place-items:center;background:rgba(37,99,235,.10);font-size:34px;color:var(--primary)}
.inline-barcode,.invoice-barcode-panel{margin-top:14px;padding:10px;border-radius:16px;background:var(--soft);border:1px solid var(--border)}
.inline-barcode svg,.invoice-barcode-panel svg{width:100%;height:auto;max-width:220px;display:block;margin:auto}
.invoice-qr-panel{display:grid;grid-template-columns:150px 1fr;gap:16px;align-items:center;background:var(--soft);border:1px solid var(--border);border-radius:18px;padding:14px;margin-top:16px}
.invoice-qr-panel .btn{margin-top:10px}
.product-card{transition:transform .18s ease, box-shadow .18s ease,border-color .18s ease}
.product-card .product-info span{word-break:break-word}
.login-visual{background:
  linear-gradient(90deg,rgba(7,18,37,.12),rgba(7,18,37,.35)),
  radial-gradient(circle at 18% 20%,rgba(59,130,246,.34),transparent 28%),
  linear-gradient(130deg,#0f2c5f,#071225)}
.login-visual .visual-overlay{background:linear-gradient(90deg,rgba(7,18,37,.12),rgba(7,18,37,.42))}
.login-visual::marker{content:''}
.login-visual .visual-copy:before{content:'';position:absolute;inset:auto auto -36px -20px;width:220px;height:140px;border-radius:26px;background:linear-gradient(180deg,rgba(255,255,255,.10),rgba(255,255,255,.03));filter:blur(.2px);box-shadow:220px -60px 0 0 rgba(255,255,255,.06),430px -10px 0 0 rgba(255,255,255,.05)}
@media(max-width:600px){.invoice-qr-panel{grid-template-columns:1fr}.search-hint{font-size:11px}}

/* ===============================
   v23.4 Realtime Media & UX
   =============================== */
@keyframes dlFadeUp{from{opacity:0;transform:translateY(18px)}to{opacity:1;transform:none}}
@keyframes dlScaleIn{from{opacity:0;transform:scale(.96)}to{opacity:1;transform:scale(1)}}
@keyframes dlFloat{0%,100%{transform:translate3d(0,0,0)}50%{transform:translate3d(0,-12px,0)}}
@keyframes dlPulse{0%,100%{opacity:.45;transform:scale(1)}50%{opacity:.8;transform:scale(1.08)}}
@keyframes dlShimmer{0%{background-position:200% 0}100%{background-position:-200% 0}}
@keyframes dlSpin{to{transform:rotate(360deg)}}

.login-page{background:#061126;overflow:hidden}
.login-visual{background-image:linear-gradient(90deg,rgba(4,12,29,.24),rgba(4,12,29,.58)),url('login-market.svg');background-size:cover;background-position:center;isolation:isolate}
.login-visual:before{content:"";position:absolute;inset:0;background:radial-gradient(circle at 22% 14%,rgba(59,130,246,.30),transparent 34%),linear-gradient(180deg,transparent 45%,rgba(2,8,23,.64));z-index:0}
.login-visual:after{content:"";position:absolute;inset:auto 0 0;height:180px;background:linear-gradient(transparent,rgba(2,8,23,.56));z-index:0}
.visual-overlay{z-index:0;background:linear-gradient(90deg,rgba(4,12,29,.05),rgba(4,12,29,.30))}
.market-glow{position:absolute;border-radius:999px;filter:blur(25px);opacity:.28;z-index:0;animation:dlPulse 7s ease-in-out infinite}
.market-glow.one{width:260px;height:260px;left:8%;top:12%;background:#3b82f6}
.market-glow.two{width:220px;height:220px;right:8%;bottom:10%;background:#14b8a6;animation-delay:-3s}
.visual-copy{z-index:2;animation:dlFadeUp .75s ease both}
.visual-copy .eyebrow{display:inline-flex;align-items:center;gap:8px;padding:8px 12px;border:1px solid rgba(255,255,255,.18);border-radius:999px;background:rgba(15,23,42,.46);backdrop-filter:blur(10px)}
.visual-copy .eyebrow span{width:8px;height:8px;border-radius:50%;background:#34d399;box-shadow:0 0 0 5px rgba(52,211,153,.15)}
.visual-copy h1{text-shadow:0 14px 35px rgba(0,0,0,.32);letter-spacing:-.045em}
.visual-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;max-width:620px;margin-top:24px}
.visual-stats>div{padding:14px 16px;border:1px solid rgba(255,255,255,.15);border-radius:16px;background:rgba(15,23,42,.42);backdrop-filter:blur(12px)}
.visual-stats b,.visual-stats span{display:block}.visual-stats b{font-size:20px}.visual-stats span{font-size:12px;color:#cbd5e1;margin-top:2px}
.login-panel{position:relative;background:linear-gradient(160deg,#08152d,#061126)}
.login-card{animation:dlScaleIn .58s cubic-bezier(.2,.8,.2,1) both;border:1px solid rgba(255,255,255,.7);box-shadow:0 35px 100px rgba(0,0,0,.38),0 0 0 1px rgba(255,255,255,.08)}
.login-card:before{content:"";position:absolute;inset:0 0 auto;height:5px;border-radius:28px 28px 0 0;background:linear-gradient(90deg,#2563eb,#38bdf8,#14b8a6)}
.login-brand .brand-logo{box-shadow:0 10px 28px rgba(37,99,235,.16)}
.login-brand .brand-logo img,.license-card .brand-logo img{width:100%;height:100%;padding:6px;object-fit:contain}
.license-status-line{display:flex;align-items:center;gap:7px;color:#64748b}
.password-wrap{position:relative}.password-wrap .form-field{margin-bottom:0}.password-wrap .input{padding-right:78px}
.pass-toggle{position:absolute;right:10px;bottom:9px;top:auto;border:0;background:#eef4ff;color:#1d4ed8;font-weight:800;border-radius:9px;padding:8px 10px;cursor:pointer}
.pass-toggle:hover{background:#dbeafe}
.login-submit,.license-submit{display:flex;align-items:center;justify-content:center;gap:12px;min-height:48px;box-shadow:0 12px 28px rgba(37,99,235,.24)}
.login-submit i,.license-submit i{font-style:normal;font-size:19px;transition:.2s}.login-submit:hover i,.license-submit:hover i{transform:translateX(4px)}
.login-submit.loading i,.license-submit.loading i{width:16px;height:16px;border:2px solid rgba(255,255,255,.45);border-top-color:white;border-radius:50%;font-size:0;animation:dlSpin .7s linear infinite}

.license-page{position:relative;display:grid;place-items:center;overflow:hidden;background:radial-gradient(circle at 15% 12%,#2563eb 0,transparent 32%),radial-gradient(circle at 86% 86%,#0f766e 0,transparent 28%),#061126}
.license-orb{position:absolute;border-radius:50%;filter:blur(3px);opacity:.22;animation:dlFloat 8s ease-in-out infinite}
.license-orb.orb1{width:380px;height:380px;background:#60a5fa;left:-120px;top:-100px}.license-orb.orb2{width:300px;height:300px;background:#2dd4bf;right:-80px;bottom:-80px;animation-delay:-4s}
.license-shell{position:relative;z-index:2;width:min(1080px,calc(100% - 36px));display:grid;grid-template-columns:1fr 480px;border:1px solid rgba(255,255,255,.13);border-radius:30px;background:rgba(10,24,51,.72);box-shadow:0 40px 120px rgba(0,0,0,.38);backdrop-filter:blur(18px);overflow:hidden;animation:dlScaleIn .65s ease both}
.license-side{padding:54px;color:#fff;background:linear-gradient(150deg,rgba(37,99,235,.22),rgba(6,17,38,.12))}
.license-brand{display:flex;align-items:center;gap:11px;font-weight:800;margin-bottom:72px}.license-brand img{width:42px;height:42px;background:white;border-radius:12px;padding:5px}.license-side h1{font-size:46px;line-height:1.03;letter-spacing:-.04em;margin:14px 0}.license-side p{color:#cbd5e1;font-size:16px;line-height:1.6;max-width:520px}
.activation-steps{display:grid;gap:12px;margin-top:34px}.activation-steps div{display:flex;align-items:center;gap:12px;color:#94a3b8}.activation-steps b{width:34px;height:34px;border-radius:50%;display:grid;place-items:center;border:1px solid rgba(255,255,255,.16);background:rgba(255,255,255,.06)}.activation-steps .active{color:white}.activation-steps .active b{background:#2563eb;border-color:#60a5fa;box-shadow:0 0 0 6px rgba(37,99,235,.15)}
.license-card{width:auto;min-height:100%;border-radius:0;padding:46px 42px;display:flex;flex-direction:column;justify-content:center;animation:dlFadeUp .65s ease .08s both}
.license-card h2{font-size:30px;margin:14px 0 4px}.license-card>p{color:#64748b;margin:0 0 10px}.domain-chip{border:1px solid #dbe5f2;background:#f8fafc;border-radius:13px;padding:12px 14px;font-weight:700;color:#334155;margin:6px 0 16px;word-break:break-word}.license-card .badge{align-self:center}.license-card .brand-logo.large{box-shadow:0 14px 34px rgba(37,99,235,.16)}

.modal-card{animation:dlScaleIn .22s ease both}
.card,.kpi,.product-card,.page-toolbar,.hero-strip,.backup-hero,.mobile-inventory-hero{animation:dlFadeUp .32s ease both}
.card:nth-child(2),.kpi:nth-child(2){animation-delay:.03s}.card:nth-child(3),.kpi:nth-child(3){animation-delay:.06s}.card:nth-child(4),.kpi:nth-child(4){animation-delay:.09s}
.btn{transition:transform .16s ease,box-shadow .16s ease,background .16s ease,border-color .16s ease}.btn:hover{transform:translateY(-1px)}
.toast{box-shadow:0 18px 50px rgba(15,23,42,.22)}

.image-uploader.modern{align-self:start;padding:14px;border:1px solid var(--border);border-radius:18px;background:linear-gradient(180deg,var(--soft),var(--panel));min-width:220px}
.image-uploader.modern .image-preview{position:relative;height:220px;border:1px dashed color-mix(in srgb,var(--primary) 35%,var(--border));background:var(--panel);border-radius:15px;overflow:hidden;margin-bottom:10px}
.image-uploader.modern .image-preview>img{width:100%;height:100%;object-fit:contain;display:block;background:white}
.upload-empty{height:100%;display:grid;place-items:center;align-content:center;text-align:center;color:var(--muted);gap:5px}.upload-empty b{font-size:40px}.upload-empty span{font-weight:800;color:var(--text)}.upload-empty small{font-size:11px}
.upload-status{font-size:11px;color:var(--muted);margin-top:8px;text-align:center;min-height:17px}
.upload-progress{position:absolute;inset:auto 10px 10px;background:rgba(15,23,42,.88);color:white;border-radius:10px;padding:9px 10px;display:none;align-items:center;gap:8px}.upload-progress.active{display:flex}.upload-progress i{width:16px;height:16px;border:2px solid rgba(255,255,255,.35);border-top-color:white;border-radius:50%;animation:dlSpin .75s linear infinite}.upload-progress span{font-size:11px}
.upload-saved{position:absolute;right:10px;bottom:10px;background:#dcfce7;color:#166534;border-radius:999px;padding:7px 10px;font-size:11px;font-weight:800;box-shadow:0 8px 22px rgba(22,101,52,.14)}
.saved-product-image{width:110px;height:110px;object-fit:contain;background:white;border:1px solid var(--border);border-radius:16px;padding:7px;margin:8px auto;display:block}
.product-cell .thumb img,.product-card .product-image img{animation:dlScaleIn .25s ease both}
.product-cell .thumb{overflow:hidden}.product-cell .thumb img{width:100%;height:100%;object-fit:contain;background:white}
.product-card .product-image{background:linear-gradient(180deg,#f8fafc,#eef4fb);border:1px solid #e2e8f0}
.product-placeholder{font-size:31px;filter:saturate(.9)}

.live-dot{font-size:9px;color:#047857;background:#d1fae5;padding:4px 7px;border-radius:999px;margin-left:6px;vertical-align:middle;letter-spacing:.05em}.live-dot:before{content:"";display:inline-block;width:6px;height:6px;border-radius:50%;background:#10b981;margin-right:5px;box-shadow:0 0 0 4px rgba(16,185,129,.12);animation:dlPulse 1.5s infinite}
.preview-code{display:grid;place-items:center;gap:8px;margin:12px 0}.preview-code .qr-image{width:90px;height:90px}.mini-barcode svg{width:145px;height:auto}.receipt-preview{overflow:hidden}

@media(max-width:900px){.license-shell{grid-template-columns:1fr;max-width:620px}.license-side{display:none}.license-card{border-radius:28px}.visual-stats{grid-template-columns:1fr 1fr 1fr}.login-visual{min-height:46vh}}
@media(max-width:600px){.visual-stats{grid-template-columns:1fr 1fr}.visual-stats>div:last-child{grid-column:1/-1}.login-visual{min-height:42vh}.license-shell{width:calc(100% - 18px)}.license-card{padding:30px 22px}.image-uploader.modern{min-width:0;width:100%}.image-uploader.modern .image-preview{height:180px}.product-editor{gap:14px}.login-row{align-items:flex-start;gap:8px;flex-direction:column}.login-row a{align-self:flex-end}.visual-copy{left:6%;right:6%}}

/* v23.5 — Professional sales, cash and responsive polish */
.login-page{grid-template-columns:minmax(0,1.02fr) minmax(430px,.98fr)}
.visual-copy{left:7%;right:7%;bottom:8%;max-width:620px}
.visual-copy h1{font-size:clamp(38px,4.15vw,56px);line-height:1.02;max-width:610px;margin:12px 0 10px}
.visual-copy p{font-size:16px;line-height:1.55;max-width:580px}
.visual-stats{max-width:560px;margin-top:18px}.visual-stats>div{padding:12px 14px}.visual-stats b{font-size:17px}
.visual-pills{margin-top:16px}.visual-pills span{padding:7px 11px;font-size:12px}
.login-panel{padding:28px}.login-card{width:min(100%,470px);padding:30px 32px}.login-heading{margin:23px 0 16px}.login-heading h1{font-size:28px}.login-heading p{font-size:14px}
.password-wrap .input{padding-right:54px}.pass-toggle{width:36px;height:36px;display:grid;place-items:center;right:7px;bottom:6px;padding:0;font-size:16px;line-height:1}

.modal-card.xlarge{width:min(1180px,calc(100vw - 34px));padding:22px 24px}
.product-editor{grid-template-columns:240px minmax(0,1fr);gap:28px;align-items:start}
.product-editor>.form-grid{width:100%;min-width:0;grid-template-columns:repeat(3,minmax(0,1fr));column-gap:14px;row-gap:13px}
.product-editor .form-field{min-width:0}.product-editor .input{width:100%;min-width:0}
.image-uploader.modern{width:100%;min-width:0;position:sticky;top:0;z-index:1;padding:14px}
.image-uploader.modern .image-preview{height:210px;margin:0 0 11px}
.image-uploader.modern .image-preview>img{padding:8px;object-fit:contain;object-position:center;background:#fff}
.upload-empty{padding:18px;text-align:center}.upload-empty b{font-size:34px}.upload-empty span{font-size:15px}.upload-empty small{line-height:1.4}
.upload-status{font-size:11px;line-height:1.4;min-height:32px;margin-top:8px}
.sticky-actions{position:sticky;bottom:-20px;z-index:8;margin:18px -4px -20px;padding:14px 4px 5px;background:linear-gradient(180deg,rgba(255,255,255,0),var(--panel) 24%);border-top:1px solid var(--border)}

.product-grid{grid-template-columns:repeat(auto-fill,minmax(162px,1fr));gap:11px}
.product-card{min-height:190px;padding:10px;border-radius:17px}
.product-image{height:88px;padding:7px;margin-bottom:9px;background:#fff;border:1px solid #e5eaf2}
.product-image img{width:100%;height:100%;max-width:100%;max-height:100%;object-fit:contain;object-position:center;display:block}
.product-placeholder{font-size:34px;filter:grayscale(.15)}
.product-info h3{font-size:14px;min-height:32px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.product-info span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.product-info b{font-size:18px;margin-top:auto;padding-top:6px}
.thumb{width:48px;height:48px;padding:4px;background:#fff}.thumb img{object-fit:contain;object-position:center}
.saved-product-image{width:150px;height:150px;object-fit:contain;padding:10px}

.recent-sales{max-height:210px}.recent-sales h3{display:flex;align-items:center;gap:8px;margin-bottom:8px}
#recentSalesList{display:flex;flex-direction:column;gap:7px}
.recent-sale-card{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:8px;align-items:center;padding:9px;border:1px solid var(--border);border-radius:12px;background:var(--soft)}
.recent-sale-card>div:first-child b,.recent-sale-card>div:first-child small{display:block}.recent-sale-card small{font-size:10px;color:var(--muted)}
.recent-sale-total{text-align:right}.recent-sale-total b,.recent-sale-total small{display:block}.recent-sale-total small{color:#b45309}
.recent-sale-actions{display:flex;gap:5px}.recent-sale-actions button{font-size:10px;padding:6px 7px;border:1px solid var(--border);background:var(--panel)}

.toolbar-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.money-stack b,.money-stack small,.status-stack span{display:block}.money-stack small{color:#b45309;margin-top:3px}.status-stack{display:flex;flex-direction:column;gap:4px;align-items:flex-start}
.cash-kpi-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px;margin-bottom:18px}.cash-kpi-grid article{background:var(--panel);border:1px solid var(--border);border-radius:16px;padding:15px}.cash-kpi-grid span,.cash-kpi-grid b{display:block}.cash-kpi-grid span{font-size:11px;color:var(--muted)}.cash-kpi-grid b{font-size:20px;margin-top:5px}.cash-kpi-grid article.primary{border-color:color-mix(in srgb,var(--primary) 55%,var(--border));background:color-mix(in srgb,var(--primary) 8%,var(--panel))}.cash-kpi-grid article.danger{border-color:#fecaca;background:#fff7f7}.cash-summary.advanced{grid-template-columns:repeat(3,minmax(0,1fr));margin:14px 0}.open-cash-panel{max-width:430px}.cash-close-preview{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-bottom:15px}.cash-close-preview>div{background:var(--soft);padding:13px;border-radius:13px}.cash-close-preview span,.cash-close-preview b{display:block}.cash-close-preview span{font-size:11px;color:var(--muted)}.cash-close-preview b{font-size:19px;margin-top:4px}
.cash-live-strip{display:grid;grid-template-columns:repeat(4,minmax(0,1fr)) auto;align-items:center;gap:8px;margin:0 0 18px;padding:12px;background:linear-gradient(135deg,#0f172a,#1e3a8a);color:#fff;border-radius:17px;box-shadow:0 18px 45px rgba(15,23,42,.16)}.cash-live-strip>div{padding:8px 11px;border-right:1px solid rgba(255,255,255,.12)}.cash-live-strip span,.cash-live-strip b{display:block}.cash-live-strip span{font-size:10px;color:#bfdbfe}.cash-live-strip b{font-size:17px;margin-top:3px}.cash-live-strip a{color:#fff;font-weight:800;text-decoration:none;padding:10px}

.invoice-qr-panel{display:grid;grid-template-columns:170px minmax(0,1fr);gap:18px;align-items:center}.invoice-qr-panel>.qr-image{width:160px;height:160px;background:#fff;padding:7px;border-radius:13px}.invoice-barcode-panel{max-width:300px}.invoice-barcode-panel svg{width:100%;height:115px}.inline-barcode svg{max-width:270px;height:105px}
.hotkeys{align-items:center}.hotkeys span{border:1px solid var(--border)}

@media(max-width:1100px){.cash-kpi-grid{grid-template-columns:repeat(3,1fr)}.product-editor{grid-template-columns:210px minmax(0,1fr);gap:20px}.product-editor>.form-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.login-page{grid-template-columns:1fr 480px}.visual-copy h1{font-size:42px}}
@media(max-width:900px){.login-page{grid-template-columns:1fr}.login-visual{min-height:360px}.visual-copy{position:relative;left:auto;right:auto;bottom:auto;padding:55px 34px 34px}.visual-copy h1{font-size:38px}.product-editor{grid-template-columns:1fr}.image-uploader.modern{position:relative;display:grid;grid-template-columns:180px minmax(0,1fr);gap:12px;align-items:center}.image-uploader.modern .image-preview{height:150px;grid-row:1/4}.cash-kpi-grid{grid-template-columns:repeat(2,1fr)}.cash-live-strip{grid-template-columns:repeat(2,1fr)}.cash-live-strip a{grid-column:1/-1}.invoice-qr-panel{grid-template-columns:1fr;text-align:center}.invoice-qr-panel>.qr-image{margin:auto}.invoice-barcode-panel{margin:auto}.recent-sale-card{grid-template-columns:1fr auto}.recent-sale-actions{grid-column:1/-1;justify-content:flex-end}}
@media(max-width:600px){.login-visual{min-height:330px}.visual-copy{padding:34px 22px 25px}.visual-copy h1{font-size:29px;line-height:1.06}.visual-copy p{font-size:13px}.visual-stats{display:none}.login-panel{padding:12px}.login-card{padding:23px 20px}.login-heading h1{font-size:24px}.modal-card.xlarge{width:100%;padding:16px}.product-editor>.form-grid{grid-template-columns:1fr}.image-uploader.modern{display:block}.image-uploader.modern .image-preview{height:190px}.product-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.product-card{min-height:176px}.product-image{height:76px}.cash-kpi-grid{grid-template-columns:1fr 1fr}.cash-summary.advanced,.cash-close-preview{grid-template-columns:1fr}.cash-live-strip{grid-template-columns:1fr 1fr}.sticky-actions{bottom:-16px;margin-bottom:-16px}.toolbar-actions{width:100%}.toolbar-actions .btn{flex:1}.invoice-qr-panel>.qr-image{width:150px;height:150px}}

/* v23.6 — visualización completa de imágenes y reportes estables */
.product-grid{grid-template-columns:repeat(auto-fill,minmax(168px,1fr));gap:11px}
.product-card{min-height:224px;padding:10px}
.product-image{height:116px!important;min-height:116px;padding:6px!important;background:#fff!important;border:1px solid #dfe7f2!important;border-radius:14px;overflow:hidden}
.product-image img{width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;object-fit:contain!important;object-position:center!important;display:block!important;animation:none!important;transform:none!important}
.product-placeholder{font-size:38px}
.product-info h3{min-height:33px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.product-info span{min-height:15px}
.sync-stamp{font-size:11px;color:var(--muted);padding:7px 10px;background:var(--soft);border-radius:999px;white-space:nowrap}
.report-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;margin-bottom:14px;padding:24px;border-radius:22px;background:linear-gradient(135deg,#0f172a,#1e3a8a 62%,#2563eb);color:#fff;box-shadow:0 18px 50px rgba(15,23,42,.16)}
.report-hero h2{font-size:28px;max-width:700px;margin:7px 0}.report-hero p{margin:0;color:#bfdbfe}.report-hero .eyebrow{color:#93c5fd}
.report-date-range{display:grid;grid-template-columns:150px 150px auto;gap:9px;align-items:end;padding:12px;background:rgba(255,255,255,.1);border:1px solid rgba(255,255,255,.16);border-radius:16px;backdrop-filter:blur(10px)}
.report-date-range label{font-size:10px;color:#dbeafe;font-weight:800}.report-date-range .input{margin-top:5px;background:#fff;color:#0f172a;min-height:42px}
.report-toolbar{display:flex;justify-content:space-between;align-items:center;gap:14px;margin-bottom:14px;background:var(--panel);border:1px solid var(--border);border-radius:16px;padding:9px 11px}
.report-tabs{display:flex;gap:5px;overflow:auto}.report-tabs button{border:0;background:transparent;color:var(--muted);font-weight:800;padding:9px 13px;border-radius:10px;white-space:nowrap;cursor:pointer}.report-tabs button.active{background:var(--primary);color:#fff;box-shadow:0 8px 20px color-mix(in srgb,var(--primary) 22%,transparent)}
.report-kpi-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin-bottom:14px}.report-kpi-grid article{background:var(--panel);border:1px solid var(--border);border-radius:17px;padding:15px;box-shadow:0 8px 24px rgba(15,23,42,.04)}.report-kpi-grid article.primary{background:color-mix(in srgb,var(--primary) 8%,var(--panel));border-color:color-mix(in srgb,var(--primary) 35%,var(--border))}.report-kpi-grid article.danger{background:#fff7f7;border-color:#fecaca}.report-kpi-grid span,.report-kpi-grid b,.report-kpi-grid small{display:block}.report-kpi-grid span{font-size:10px;color:var(--muted);font-weight:850;text-transform:uppercase;letter-spacing:.04em}.report-kpi-grid b{font-size:21px;margin:7px 0 4px}.report-kpi-grid small{font-size:10px;color:var(--muted)}
.report-grid{display:grid;grid-template-columns:1.5fr 1fr;gap:14px}.report-wide{grid-row:span 2}
.report-bars{height:270px;display:flex;align-items:stretch;gap:6px;padding:18px 5px 0;border-bottom:1px solid var(--border);overflow-x:auto}.report-bar-col{min-width:28px;flex:1;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:7px}.report-bar-values{height:225px;width:100%;display:flex;justify-content:center;align-items:flex-end;gap:3px}.report-bar-values i{display:block;width:min(14px,42%);border-radius:8px 8px 2px 2px;min-height:2px;transition:height .25s ease}.report-bar-values i.sales{background:linear-gradient(180deg,#60a5fa,#2563eb)}.report-bar-values i.returns{background:linear-gradient(180deg,#fda4af,#ef4444)}.report-bar-col>span{font-size:9px;color:var(--muted);white-space:nowrap}.report-legend{display:flex;gap:15px;justify-content:flex-end;margin-top:10px;font-size:11px;color:var(--muted)}.report-legend i{display:inline-block;width:9px;height:9px;border-radius:3px;margin-right:5px}.report-legend i.sales{background:#2563eb}.report-legend i.returns{background:#ef4444}
.report-health{display:grid;grid-template-columns:1fr 1fr;gap:9px}.report-health>div{background:var(--soft);border-radius:13px;padding:13px}.report-health span,.report-health b{display:block}.report-health span{font-size:10px;color:var(--muted)}.report-health b{font-size:21px;margin-top:5px}
@media(max-width:1180px){.report-kpi-grid{grid-template-columns:repeat(3,1fr)}.report-grid{grid-template-columns:1fr}.report-wide{grid-row:auto}}
@media(max-width:900px){.report-hero{align-items:flex-start;flex-direction:column}.report-date-range{width:100%}.report-toolbar{align-items:flex-start;flex-direction:column}.report-toolbar .toolbar-actions{width:100%;flex-wrap:wrap}}
@media(max-width:600px){.product-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.product-card{min-height:210px}.product-image{height:104px!important;min-height:104px}.report-date-range{grid-template-columns:1fr 1fr}.report-date-range .btn{grid-column:1/-1}.report-kpi-grid{grid-template-columns:1fr 1fr}.report-kpi-grid b{font-size:17px}.report-hero{padding:18px}.report-hero h2{font-size:22px}.report-bars{height:230px}.report-bar-values{height:185px}}

/* v23.7 — precios visibles y centro profesional de etiquetas */
.terminal-products{grid-template-rows:auto auto auto auto minmax(0,1fr) auto!important}
.product-grid{padding-bottom:38px!important;align-items:start}
.product-card{min-height:238px!important;height:238px!important;overflow:hidden!important}
.product-image{height:112px!important;min-height:112px!important;flex:0 0 112px!important}
.product-info{display:flex!important;flex-direction:column!important;flex:1!important;min-height:0!important;overflow:hidden!important}
.product-info h3{min-height:34px!important;margin-bottom:5px!important}
.product-info span,.product-info small{flex:0 0 auto}
.product-info b{margin-top:auto!important;padding-top:6px!important;font-size:18px!important;line-height:1.05!important;color:var(--text)!important;background:var(--panel)!important;position:relative!important;z-index:2!important}
.product-info em{flex:0 0 auto}

.labels-hero{display:flex;align-items:center;justify-content:space-between;gap:22px;padding:24px;border-radius:22px;background:linear-gradient(135deg,#0f172a,#1e3a8a 62%,#2563eb);color:white;box-shadow:0 18px 50px rgba(15,23,42,.16);margin-bottom:16px}
.labels-hero h2{font-size:28px;max-width:730px;margin:7px 0}.labels-hero p{margin:0;color:#bfdbfe}.labels-hero .eyebrow{color:#93c5fd}.labels-hero-actions{display:flex;gap:8px;flex-wrap:wrap}.labels-hero .btn.ghost{color:white;border-color:rgba(255,255,255,.25);background:rgba(255,255,255,.08)}
.label-workspace{display:grid;grid-template-columns:250px minmax(0,1fr) 310px;gap:14px;align-items:start}
.label-control-panel,.label-products-panel,.label-live-preview{background:var(--panel);border:1px solid var(--border);border-radius:18px;box-shadow:var(--shadow);padding:16px}
.label-control-panel{position:sticky;top:92px}.label-live-preview{position:sticky;top:92px}.label-control-panel h3,.label-live-preview h3{margin-top:0}
.label-switches{display:grid;gap:9px;margin:14px 0}.label-switches label{display:flex;align-items:center;gap:8px;font-size:13px;background:var(--soft);border-radius:11px;padding:9px 10px}
.label-format-note{display:grid;gap:3px;background:#eff6ff;color:#1e3a8a;border:1px solid #bfdbfe;border-radius:12px;padding:11px;margin-top:12px}.label-format-note span{font-size:11px;color:#475569}
.label-count{display:flex;align-items:center;justify-content:space-between;border-top:1px solid var(--border);padding-top:13px;margin-top:13px}.label-count b{font-size:24px;color:var(--primary)}
.label-filter-row{display:grid;grid-template-columns:minmax(0,1fr) 190px auto auto;gap:8px;margin-bottom:13px}
.label-products-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:9px;max-height:calc(100vh - 250px);overflow:auto;padding:2px}
.label-product-option{position:relative;display:grid;grid-template-columns:auto 58px minmax(0,1fr);align-items:center;gap:10px;padding:10px;border:1px solid var(--border);border-radius:14px;background:var(--panel);cursor:pointer;transition:.16s ease}
.label-product-option:hover,.label-product-option.selected{border-color:var(--primary);box-shadow:0 9px 22px color-mix(in srgb,var(--primary) 13%,transparent)}.label-product-option.selected{background:color-mix(in srgb,var(--primary) 6%,var(--panel))}
.label-product-option>input{width:17px;height:17px}.label-product-thumb{width:58px;height:58px;border-radius:11px;background:#fff;border:1px solid var(--border);overflow:hidden;display:grid;place-items:center}.label-product-thumb img{width:100%;height:100%;object-fit:contain}.label-product-thumb .product-placeholder{font-size:24px}
.label-product-option b,.label-product-option span,.label-product-option small{display:block}.label-product-option b{font-size:13px;line-height:1.15;margin-bottom:4px}.label-product-option span,.label-product-option small{font-size:10px;color:var(--muted)}
.label-preview-stage{min-height:330px;border:1px dashed color-mix(in srgb,var(--primary) 35%,var(--border));border-radius:16px;background:linear-gradient(180deg,#f8fafc,#eef4fb);display:grid;place-items:center;padding:20px;position:relative;overflow:auto}
.preview-dimensions{position:absolute;left:10px;top:10px;font-size:10px;font-weight:800;background:white;border:1px solid #dbe5f2;border-radius:999px;padding:5px 8px;color:#475569}
.label-preview-stage .print-label,.label-preview-list .print-label{width:210px;min-height:130px;height:auto!important;background:#fff;padding:12px;border-radius:10px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;color:#111;box-shadow:0 14px 36px rgba(15,23,42,.12)}
.label-preview-stage .print-label.with-border,.label-preview-list .print-label.with-border{outline:1px solid #cbd5e1;outline-offset:-1px}.label-preview-stage .label-barcode svg,.label-preview-list .label-barcode svg{width:100%;height:80px}.label-preview-stage .label-product-image{width:70px;height:55px;object-fit:contain}.label-preview-stage .label-product-name{font-size:13px}.label-preview-stage .label-price{font-size:20px}.label-preview-stage .label-readable{font-size:10px}.label-preview-stage .label-business{font-size:11px}

@media(max-width:1250px){.label-workspace{grid-template-columns:230px minmax(0,1fr)}.label-live-preview{grid-column:1/-1;position:relative;top:auto}.label-preview-stage{min-height:240px}}
@media(max-width:900px){.labels-hero{align-items:flex-start;flex-direction:column}.label-workspace{grid-template-columns:1fr}.label-control-panel,.label-live-preview{position:relative;top:auto}.label-filter-row{grid-template-columns:1fr 1fr}.label-products-grid{max-height:none}}
@media(max-width:600px){.product-card{min-height:218px!important;height:218px!important}.product-image{height:96px!important;min-height:96px!important;flex-basis:96px!important}.product-info b{font-size:16px!important}.labels-hero{padding:18px}.labels-hero h2{font-size:22px}.labels-hero-actions{width:100%}.labels-hero-actions .btn{flex:1}.label-filter-row{grid-template-columns:1fr}.label-products-grid{grid-template-columns:1fr}.label-preview-stage{min-height:220px}}

/* v23.7.1 label integrity */
.label-code-status{display:inline-flex!important;margin-top:7px;padding:4px 7px;border-radius:999px;font-size:10px;font-style:normal;font-weight:800}
.label-code-status.ok{background:#dcfce7;color:#166534}
.label-code-status.bad{background:#fee2e2;color:#991b1b}
.label-product-option.has-code-error{border-color:#fca5a5;background:linear-gradient(180deg,#fff,#fff7f7)}
.print-label.invalid-code{border-color:#ef4444!important}
.barcode-warning{min-height:42px;display:grid;place-items:center;padding:8px;border:1px dashed #ef4444;border-radius:8px;color:#991b1b;font-weight:800;font-size:10px;text-align:center}
.labels-hero-actions{display:flex;gap:8px;flex-wrap:wrap}

@media(max-width:600px){.cart-meta{margin-top:4px}.cart-item{padding:9px 8px;gap:8px}.cart-item-title h4{font-size:13px}.cart-line-total b{font-size:13px}}

.hotkey-help-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:16px}.hotkey-help-grid>div{display:flex;align-items:center;gap:12px;padding:12px;border:1px solid var(--border);border-radius:14px;background:var(--soft)}.hotkey-help-grid kbd{min-width:92px;text-align:center;padding:7px 9px;border-radius:9px;background:#0f172a;color:#fff;font:800 12px ui-monospace,Consolas,monospace;box-shadow:inset 0 -2px 0 rgba(255,255,255,.12)}.hotkey-help-grid span{font-size:13px;color:var(--text)}
.cart-panel .cart-summary{border-top:1px solid var(--border);padding-top:12px}.cart-panel .summary-total{padding:8px 0;border-top:1px dashed var(--border)}
@media(max-width:1180px){.terminal-shell{grid-template-columns:minmax(0,55%) minmax(390px,45%)}.cart-columns{grid-template-columns:minmax(0,1fr) 112px 88px 36px}.cart-item{grid-template-columns:minmax(0,1fr) 112px 88px 36px}}
@media(max-width:900px){.cart-columns{display:none}.hotkey-help-grid{grid-template-columns:1fr}}

/* v23.8 Operations Control Suite */
.ops-kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:16px}.ops-kpi-grid article{background:var(--panel);border:1px solid var(--border);border-radius:18px;padding:16px;box-shadow:0 8px 24px rgba(15,23,42,.04)}.ops-kpi-grid article span{display:block;color:var(--muted);font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.04em}.ops-kpi-grid article b{display:block;font-size:24px;margin-top:7px}.ops-kpi-grid article small{display:block;color:var(--muted);font-size:11px;margin-top:5px}.ops-kpi-grid article.primary{border-color:color-mix(in srgb,var(--primary) 35%,var(--border));background:color-mix(in srgb,var(--primary) 6%,var(--panel))}.ops-kpi-grid article.warning{border-color:#fcd34d;background:#fffbeb}.ops-kpi-grid article.danger{border-color:#fecaca;background:#fff7f7}.ops-kpi-grid article.completed{border-color:#bbf7d0;background:#f0fdf4}.filter-row.four{grid-template-columns:minmax(220px,1.5fr) repeat(3,minmax(150px,1fr))}.filter-row.five{grid-template-columns:minmax(220px,1.5fr) repeat(4,minmax(130px,1fr))}.purchase-calculator{display:flex;justify-content:space-between;align-items:center;margin:16px 0;padding:16px 18px;border-radius:16px;background:var(--soft);border:1px solid var(--border)}.purchase-calculator span{color:var(--muted);font-weight:700}.purchase-calculator b{font-size:24px}.loading-panel{min-height:180px;display:grid;place-items:center;color:var(--muted)}.status.pending{background:#eef2ff;color:#3730a3}.card.span2{grid-column:span 2}.dashboard-grid .span2{min-width:0}.table-wrap{overflow:auto}.table-wrap table{min-width:900px}.cash-kpi-grid article.warning{background:#fffbeb}.cash-kpi-grid article.completed{background:#f0fdf4}.modal-card.xlarge .cash-kpi-grid{grid-template-columns:repeat(5,1fr)}
@media(max-width:1100px){.ops-kpi-grid{grid-template-columns:repeat(2,1fr)}.filter-row.five,.filter-row.four{grid-template-columns:repeat(2,1fr)}.modal-card.xlarge .cash-kpi-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:700px){.ops-kpi-grid{grid-template-columns:1fr 1fr}.filter-row.five,.filter-row.four{grid-template-columns:1fr}.card.span2{grid-column:auto}.modal-card.xlarge .cash-kpi-grid{grid-template-columns:1fr 1fr}.ops-kpi-grid article b{font-size:19px}}

/* v24 Restaurante & Bar */
.restaurant-terminal{grid-template-columns:minmax(0,56%) minmax(440px,44%)}
.restaurant-context{display:grid;grid-template-columns:1.15fr 1.25fr 1fr 90px;gap:9px;align-items:end;margin:12px 0 0;padding:10px;border:1px solid var(--border);border-radius:16px;background:linear-gradient(135deg,var(--soft),var(--panel))}
.restaurant-context label{display:grid;gap:5px}.restaurant-context label>span,.context-table-btn>span{font-size:10px;text-transform:uppercase;letter-spacing:.06em;color:var(--muted);font-weight:800}
.context-table-btn{min-height:62px;border:1px solid var(--border);background:var(--panel);border-radius:12px;padding:9px 12px;text-align:left;cursor:pointer;color:var(--text)}.context-table-btn:hover{border-color:var(--primary)}.context-table-btn span,.context-table-btn b{display:block}.context-table-btn b{font-size:15px;margin-top:5px}.guests-field .input{text-align:center}
.restaurant-product .product-image{height:92px}.restaurant-product .product-info h3{font-size:15px;margin-top:4px}.restaurant-product .product-info b{font-size:18px}.station-tag{display:inline-flex!important;width:max-content;background:#ecfdf5;color:#047857!important;border-radius:99px;padding:3px 7px;font-size:9px!important;font-weight:800;text-transform:uppercase}
.restaurant-cart .cart-items{margin-bottom:6px}.restaurant-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:10px 0}.btn.kitchen{background:#f59e0b;color:#fff;border-color:#f59e0b}.btn.kitchen:hover{background:#d97706}.order-notes{border:1px solid var(--border);border-radius:13px;margin:6px 0;background:var(--soft)}.order-notes summary{cursor:pointer;padding:9px 11px;font-size:12px;font-weight:800}.order-notes textarea{margin:0 9px 9px;min-height:58px;width:calc(100% - 18px);resize:vertical}
.service-quick{display:flex;gap:9px;flex-wrap:wrap;margin-bottom:16px}.service-quick button{border:1px solid var(--border);background:var(--soft);border-radius:12px;padding:11px 16px;font-weight:800;cursor:pointer;color:var(--text)}.service-quick button:hover{border-color:var(--primary);color:var(--primary)}
.table-area{margin:16px 0}.table-area h3{margin:0 0 9px;font-size:14px}.table-map{display:grid;grid-template-columns:repeat(auto-fill,minmax(135px,1fr));gap:10px}.restaurant-table{position:relative;min-height:105px;border:2px solid var(--border);border-radius:18px;padding:12px;background:var(--panel);text-align:left;cursor:pointer;color:var(--text);display:flex;flex-direction:column;justify-content:space-between}.restaurant-table span,.restaurant-table small,.restaurant-table i{display:block}.restaurant-table span{font-size:16px;font-weight:900}.restaurant-table small{font-size:11px;color:var(--muted);margin-top:4px}.restaurant-table i{font-size:10px;font-style:normal;color:var(--muted)}.restaurant-table.free{border-color:#86efac;background:#f0fdf4}.restaurant-table.occupied{border-color:#60a5fa;background:#eff6ff}.restaurant-table.kitchen{border-color:#fbbf24;background:#fffbeb}.restaurant-table.ready{border-color:#c084fc;background:#faf5ff}.restaurant-table:hover{transform:translateY(-2px);box-shadow:0 12px 28px rgba(15,23,42,.10)}
.restaurant-admin-grid{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(330px,.85fr);gap:16px}.restaurant-admin-grid .span2{grid-column:auto}.table-legend{display:flex;gap:7px;flex-wrap:wrap}.table-legend span{padding:5px 9px;border-radius:99px;font-size:10px;font-weight:800}.table-legend .free{background:#dcfce7;color:#166534}.table-legend .occupied{background:#dbeafe;color:#1d4ed8}.table-legend .kitchen{background:#fef3c7;color:#92400e}.table-legend .ready{background:#f3e8ff;color:#7e22ce}.table-map.admin{grid-template-columns:repeat(auto-fill,minmax(145px,1fr))}.restaurant-table.admin{padding:0;overflow:hidden}.restaurant-table.admin .table-open{border:0;background:transparent;color:inherit;text-align:left;padding:12px;width:100%;flex:1;cursor:pointer}.restaurant-table.admin>div{padding:0 10px 10px}.command-list{display:flex;flex-direction:column;gap:10px;max-height:720px;overflow:auto}.command-card{border:1px solid var(--border);border-left:5px solid var(--primary);border-radius:16px;padding:12px;background:var(--panel)}.command-card.kitchen{border-left-color:#f59e0b}.command-card.ready{border-left-color:#a855f7}.command-card header,.command-card footer{display:flex;justify-content:space-between;gap:10px;align-items:center}.command-card header small{display:block;color:var(--muted);font-size:10px;margin-top:3px}.command-card header>span{font-size:10px;font-weight:900;text-transform:uppercase;background:var(--soft);padding:5px 8px;border-radius:99px}.command-items{margin:10px 0;padding:8px 0;border-top:1px dashed var(--border);border-bottom:1px dashed var(--border)}.command-items div{display:flex;gap:8px;font-size:12px;margin:4px 0}.command-items small{color:var(--muted)}.command-card footer>div{display:flex;gap:5px;flex-wrap:wrap}.restaurant-hero{background:linear-gradient(135deg,#fff7ed,#fffbeb)}[data-theme="dark"] .restaurant-hero{background:linear-gradient(135deg,#2a1705,#261d0a)}
@media(max-width:1150px){.restaurant-terminal{grid-template-columns:minmax(0,54%) minmax(410px,46%)}.restaurant-context{grid-template-columns:1fr 1fr}.restaurant-admin-grid{grid-template-columns:1fr}}
@media(max-width:900px){.restaurant-terminal{display:flex}.restaurant-context{grid-template-columns:1fr 1fr}.restaurant-cart{min-height:78vh}.restaurant-admin-grid{display:block}.restaurant-admin-grid>.card{margin-bottom:14px}}
@media(max-width:600px){.restaurant-context{grid-template-columns:1fr}.restaurant-actions{grid-template-columns:1fr}.table-map{grid-template-columns:repeat(2,minmax(0,1fr))}.restaurant-product .product-image{height:76px}}

/* v24.1 — POS restaurante legible + caja sincronizada */
.restaurant-terminal{grid-template-columns:minmax(0,55%) minmax(430px,45%)}
.restaurant-terminal .terminal-products{grid-template-rows:auto auto auto auto minmax(0,1fr) auto}
.restaurant-terminal .product-grid{grid-template-columns:repeat(auto-fill,minmax(168px,1fr));gap:11px;padding-bottom:14px}
.restaurant-product{min-height:205px;padding:10px;overflow:hidden}
.restaurant-product .product-image{height:86px;margin-bottom:8px;background:#f8fafc;border:1px solid var(--border)}
.restaurant-product .product-image img{width:100%;height:100%;object-fit:contain;object-position:center}
.restaurant-product .product-info{display:flex;flex-direction:column;min-height:96px;flex:1}
.restaurant-product .product-info h3{font-size:14px;line-height:1.18;min-height:34px;margin:4px 0 5px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.restaurant-product .product-info span,.restaurant-product .product-info small{font-size:10.5px;line-height:1.35}
.restaurant-product .product-info b{font-size:17px;line-height:1.1;margin-top:auto;padding-top:7px;color:var(--text)}
.station-tag{font-size:9px!important;padding:3px 7px;line-height:1.2}
.restaurant-context{padding:9px;gap:8px}
.restaurant-context label>span,.context-table-btn>span{font-size:10px;line-height:1.2;color:#52637a}
.context-table-btn b{font-size:13px;line-height:1.25;white-space:normal;overflow-wrap:anywhere}
.restaurant-cart .cart-columns{grid-template-columns:minmax(0,1fr) 118px 92px 36px}
.restaurant-cart .cart-item{grid-template-columns:minmax(0,1fr) 118px 92px 36px;padding:9px;margin:8px 0}
.restaurant-cart .cart-item-title h4{font-size:13.5px;line-height:1.2}
.restaurant-cart .cart-item-title span{font-size:10px;line-height:1.3}
.restaurant-cart .cart-item-price{font-size:11px}
.restaurant-cart .cart-items{min-height:180px}
.restaurant-cart .cart-summary{padding-top:8px}
.restaurant-cart .summary-total{font-size:21px;margin:9px 0}
.restaurant-actions .btn,.restaurant-cart #checkout{min-height:47px}
#terminalCashStatus{font-weight:800;color:var(--primary)}
.cash-kpi-grid article,.ops-kpi-grid article{overflow:hidden}
.cash-kpi-grid article b,.ops-kpi-grid article b{overflow-wrap:anywhere}
.cash-live-strip{border:1px solid var(--border)}
.cash-summary.advanced>div{min-height:78px}
.cash-close-preview>div{min-width:0}

@media(max-width:1180px){
  .restaurant-terminal{grid-template-columns:minmax(0,53%) minmax(400px,47%)}
  .restaurant-terminal .product-grid{grid-template-columns:repeat(auto-fill,minmax(155px,1fr))}
  .restaurant-product{min-height:198px}
}
@media(max-width:900px){
  .restaurant-terminal{display:flex}
  .restaurant-product{min-height:190px}
  .restaurant-cart .cart-items{min-height:280px}
}
@media(max-width:600px){
  .restaurant-terminal .product-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .restaurant-product{min-height:176px;padding:8px}
  .restaurant-product .product-image{height:70px}
  .restaurant-product .product-info h3{font-size:13px;min-height:31px}
  .restaurant-product .product-info b{font-size:16px}
  .restaurant-cart .cart-columns{display:none}
  .restaurant-cart .cart-item{grid-template-columns:minmax(0,1fr) 104px 72px 34px;gap:6px}
}

/* =====================================================
   v24.2 — Restaurante: legibilidad, mesas y POS completo
   ===================================================== */
.restaurant-hero{
  background:#10233f;
  color:#fff;
  border:1px solid #1e3a5f;
  box-shadow:0 14px 36px rgba(15,35,63,.18);
  padding:24px 28px;
}
.restaurant-hero:before{content:none}
.restaurant-hero .eyebrow{color:#93c5fd}
.restaurant-hero h2{color:#fff;font-size:26px;line-height:1.15;margin:6px 0 7px}
.restaurant-hero p{color:#dbeafe;font-size:14px;line-height:1.45}
.restaurant-hero .hero-actions{align-items:center;flex-wrap:wrap}
.restaurant-hero .btn.ghost{background:#fff;color:#0f2748;border-color:#dbe5f1}
.restaurant-hero .btn.primary{background:#2563eb;color:#fff}
.restaurant-kpis .kpi:after{display:none}
.restaurant-kpis .kpi{min-height:118px;padding:17px 18px;border-radius:16px;box-shadow:0 8px 24px rgba(15,23,42,.055)}
.restaurant-kpis .kpi strong{font-size:27px;margin:10px 0 3px}
.restaurant-admin-grid{grid-template-columns:minmax(0,1.55fr) minmax(340px,.85fr);align-items:start}
.restaurant-admin-grid>.card{box-shadow:0 10px 30px rgba(15,23,42,.06)}
.table-map.admin{grid-template-columns:repeat(auto-fill,minmax(175px,1fr));gap:12px}
.restaurant-table.admin{
  min-height:128px;
  border:1px solid var(--border);
  border-left-width:6px;
  border-radius:16px;
  background:var(--panel);
  box-shadow:0 6px 18px rgba(15,23,42,.045);
}
.restaurant-table.admin.free{border-left-color:#22c55e;background:#f7fff9}
.restaurant-table.admin.occupied{border-left-color:#ef4444;background:#fff8f8}
.restaurant-table.admin.kitchen{border-left-color:#f59e0b;background:#fffaf0}
.restaurant-table.admin.ready{border-left-color:#8b5cf6;background:#faf8ff}
.restaurant-table.admin .table-open{display:block;padding:14px 14px 10px;min-height:92px}
.table-title-row{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:9px}
.table-title-row>b{font-size:16px;line-height:1.15}
.table-status-badge{display:inline-flex;align-items:center;border-radius:999px;padding:5px 8px;font-size:10px;font-weight:850;white-space:nowrap}
.table-status-badge.free{background:#dcfce7;color:#166534}
.table-status-badge.occupied{background:#fee2e2;color:#b42318}
.table-status-badge.kitchen{background:#fef3c7;color:#92400e}
.table-status-badge.ready{background:#ede9fe;color:#6d28d9}
.restaurant-table.admin .table-open>small{font-size:12px;color:var(--text);font-weight:700;margin-top:0}
.restaurant-table.admin .table-open>i{font-size:10.5px;color:var(--muted);margin-top:6px}
.table-card-actions{padding:0 12px 11px!important;display:flex;justify-content:flex-end}
.command-list{gap:11px}
.command-card{box-shadow:0 5px 16px rgba(15,23,42,.04)}

/* POS de restaurante: contenido completo, sin tarjetas cortadas */
.restaurant-terminal{
  grid-template-columns:minmax(0,57%) minmax(430px,43%);
  gap:10px;
  padding:10px;
}
.restaurant-terminal .terminal-products,
.restaurant-terminal .restaurant-cart{border-radius:17px}
.restaurant-terminal .terminal-products{padding:12px}
.restaurant-terminal .terminal-head h1{font-size:21px}
.restaurant-terminal .terminal-head p{font-size:11.5px;line-height:1.35}
.restaurant-terminal .terminal-head>div:last-child{gap:6px}
.restaurant-terminal .terminal-head .btn{padding:10px 13px;font-size:12px;border-radius:10px}
.restaurant-context{grid-template-columns:1.05fr 1.15fr .95fr 82px;padding:9px;gap:8px;border-radius:14px;margin-top:10px}
.restaurant-context .input,.context-table-btn{min-height:43px;padding:10px 11px}
.restaurant-terminal .terminal-tools{grid-template-columns:minmax(0,1fr) 210px;margin:10px 0 8px}
.restaurant-terminal .search-hint{padding:7px 10px;margin:0 0 8px;font-size:10.5px}
.restaurant-terminal .product-grid{
  grid-template-columns:repeat(auto-fill,minmax(155px,1fr));
  gap:9px;
  padding:1px 3px 10px;
}
.restaurant-product{
  min-height:187px;
  max-height:205px;
  padding:9px;
  border-radius:14px;
}
.restaurant-product .product-image{
  height:72px;
  flex:0 0 72px;
  margin-bottom:7px;
  border-radius:10px;
  background:#f8fafc;
}
.restaurant-product .product-image img{object-fit:contain;object-position:center;width:100%;height:100%}
.restaurant-product .product-info{min-height:88px;display:flex;flex-direction:column}
.restaurant-product .product-info h3{
  font-size:13.5px;
  line-height:1.18;
  min-height:32px;
  margin:4px 0;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.restaurant-product .product-info span,
.restaurant-product .product-info small{font-size:10px;line-height:1.25}
.restaurant-product .product-info b{font-size:16.5px;line-height:1.1;margin-top:auto;padding-top:5px;white-space:nowrap}
.station-tag{font-size:8px!important;padding:3px 6px}
.restaurant-cart{padding:12px}
.restaurant-cart .cart-head h2{font-size:21px;margin-bottom:3px}
.restaurant-cart .cart-meta span{font-size:10px;padding:4px 8px}
.restaurant-cart #customer{min-height:43px;padding:10px 12px}
.restaurant-cart .cart-columns{
  grid-template-columns:minmax(0,1fr) 108px 90px 34px;
  padding:9px 8px 7px;
  font-size:9.5px;
}
.restaurant-cart .cart-items{min-height:180px;margin:5px 0;overflow:auto}
.restaurant-cart .cart-item{
  grid-template-columns:minmax(0,1fr) 108px 90px 34px;
  gap:7px;
  padding:8px;
  margin:7px 0;
  border-radius:13px;
}
.restaurant-cart .cart-item-title h4{font-size:13px;line-height:1.18;margin-bottom:3px}
.restaurant-cart .cart-item-title span{font-size:9.5px;line-height:1.25}
.restaurant-cart .cart-item-price{font-size:10.5px}
.restaurant-cart .cart-qty-wrap{grid-template-columns:28px minmax(42px,1fr) 28px;gap:4px}
.restaurant-cart .qty-btn{height:33px;border-radius:8px}
.restaurant-cart .cart-item .input{min-height:33px;height:33px;padding:5px 4px}
.restaurant-cart .cart-line-total b{font-size:13.5px;white-space:nowrap}
.restaurant-cart .cart-line-total small{font-size:8px}
.restaurant-cart .order-notes{margin:5px 0}
.restaurant-cart .order-notes summary{padding:8px 10px;font-size:11px}
.restaurant-cart .cart-summary>label{font-size:11px}
.restaurant-cart .cart-summary>label .input{min-height:42px;padding:9px 11px}
.restaurant-cart .summary-line{font-size:13px;margin-top:8px}
.restaurant-cart .summary-total{font-size:21px;margin:9px 0}
.restaurant-actions{gap:7px;margin:8px 0}
.restaurant-actions .btn,.restaurant-cart #checkout{min-height:44px;padding:10px 12px;font-size:13px;border-radius:11px}
.restaurant-terminal .hotkeys{gap:5px;padding-top:8px}
.restaurant-terminal .hotkeys span{font-size:9.5px;padding:6px 8px}

@media(max-width:1200px){
  .restaurant-terminal{grid-template-columns:minmax(0,54%) minmax(410px,46%)}
  .restaurant-terminal .product-grid{grid-template-columns:repeat(auto-fill,minmax(145px,1fr))}
  .restaurant-product{min-height:180px}
  .restaurant-admin-grid{grid-template-columns:1fr}
}
@media(max-width:900px){
  .restaurant-terminal{display:flex;padding:0}
  .restaurant-terminal .terminal-products,.restaurant-terminal .restaurant-cart{border-radius:0}
  .restaurant-cart{min-height:72vh}
  .restaurant-admin-grid{display:block}
}
@media(max-width:600px){
  .restaurant-hero{padding:20px;border-radius:18px}
  .restaurant-hero h2{font-size:22px}
  .restaurant-hero .hero-actions{width:100%;display:grid;grid-template-columns:1fr}
  .table-map.admin{grid-template-columns:repeat(2,minmax(0,1fr))}
  .restaurant-terminal .product-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .restaurant-product{min-height:172px;max-height:none}
  .restaurant-product .product-image{height:66px;flex-basis:66px}
  .restaurant-cart .cart-columns{display:none}
  .restaurant-cart .cart-item{grid-template-columns:minmax(0,1fr) 100px 70px 32px}
}

/* v24.3 impresión POS-50 */
.printer-profile{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px;border:1px solid var(--border);background:linear-gradient(135deg,var(--soft),var(--panel));border-radius:16px;margin:10px 0 16px}
.printer-profile h3{margin:4px 0 5px}.printer-profile p{margin:0;color:var(--muted);max-width:640px;font-size:13px;line-height:1.45}
.printer-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:14px 0}
.printer-status{display:inline-flex;align-items:center;min-height:38px;padding:8px 12px;border:1px solid var(--border);border-radius:10px;background:var(--soft);color:var(--muted);font-size:12px;font-weight:700}
.printer-help{line-height:1.5}.printer-switches{margin:12px 0}.printer-diagnostic{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:14px 0}.printer-diagnostic>div{padding:13px;border:1px solid var(--border);border-radius:13px;background:var(--soft)}.printer-diagnostic span,.printer-diagnostic b{display:block}.printer-diagnostic span{font-size:11px;color:var(--muted);margin-bottom:5px}.printer-diagnostic b{font-size:13px}
@media(max-width:700px){.printer-profile{align-items:flex-start;flex-direction:column}.printer-diagnostic{grid-template-columns:1fr}.printer-actions .btn{flex:1 1 180px}}
