@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@600;700;800&display=swap');

:root{color-scheme:light;--bg:#f4f6f9;--surface:#fff;--surface-2:#f8fafc;--surface-3:#eef2f7;--text:#111827;--muted:#64748b;--line:#dfe5ec;--accent:#f97316;--accent-2:#fb923c;--accent-soft:#fff0e5;--green:#10b981;--green-soft:#e7f9f2;--yellow:#f59e0b;--yellow-soft:#fff7df;--red:#ef4444;--red-soft:#feeeee;--cyan:#06b6d4;--violet:#8b5cf6;--sidebar:#111827;--sidebar-text:#cbd5e1;--sidebar-active:#1f2937;--shadow:0 20px 60px rgba(15,23,42,.08);--radius:18px;--radius-sm:12px;--topbar:76px}
[data-theme="dark"]{color-scheme:dark;--bg:#090b0e;--surface:#0f1217;--surface-2:#13171d;--surface-3:#191e26;--text:#f8fafc;--muted:#8792a5;--line:#242a33;--accent:#ff7417;--accent-2:#ff933f;--accent-soft:#2c180d;--green:#22c58b;--green-soft:#0d2b22;--yellow:#f7b731;--yellow-soft:#2d230d;--red:#fb5d66;--red-soft:#32151a;--cyan:#23c4df;--violet:#9b78ff;--sidebar:#0b0d10;--sidebar-text:#929baa;--sidebar-active:#15191f;--shadow:0 20px 70px rgba(0,0,0,.28)}
*{box-sizing:border-box}html{font-size:16px}body{margin:0;background:var(--bg);color:var(--text);font:400 1rem/1.5 'DM Sans',sans-serif}button,input,select,textarea{font:inherit}button,a{touch-action:manipulation}a{color:inherit;text-decoration:none}h1,h2,h3,strong,b{font-family:'Manrope',sans-serif}h1,h2,h3,p{margin-top:0}h1{font-size:clamp(1.65rem,3vw,2.35rem);line-height:1.12;margin-bottom:.45rem;letter-spacing:-.04em}h2{font-size:1.12rem;margin-bottom:.2rem;letter-spacing:-.02em}h3{font-size:.98rem}small{color:var(--muted)}.muted{color:var(--muted)}.eyebrow{display:block;color:var(--accent);font-size:.73rem;font-weight:800;letter-spacing:.13em;margin-bottom:.55rem}.app-shell{min-height:100vh}.sidebar{position:fixed;inset:0 auto 0 0;width:262px;background:var(--sidebar);color:var(--sidebar-text);border-right:1px solid #20242b;z-index:50;display:flex;flex-direction:column;padding:20px 16px}.brand{display:flex;align-items:center;gap:11px;padding:4px 9px 22px;color:#fff}.brand-mark{display:grid;place-items:center;width:39px;height:39px;border-radius:12px;background:linear-gradient(145deg,var(--accent-2),var(--accent));box-shadow:0 9px 24px rgba(249,115,22,.25);font:800 1.25rem 'Manrope'}.brand>span:last-child{display:flex;flex-direction:column;line-height:1.12}.brand strong{font-size:1.02rem}.brand small{font-size:.66rem;color:#7f8999;margin-top:4px}.brand-large .brand-mark{width:50px;height:50px;font-size:1.5rem}.sidebar nav{overflow:auto;padding-right:3px}.nav-section{padding:19px 12px 8px;color:#596475;font-size:.67rem;font-weight:800;letter-spacing:.14em}.sidebar nav a{display:flex;align-items:center;gap:13px;padding:11px 12px;border-radius:10px;font-weight:600;font-size:.9rem;margin:2px 0;transition:.16s ease}.sidebar nav a>span{display:grid;place-items:center;width:20px;color:#6e7888;font-size:1.1rem}.sidebar nav a:hover{color:#fff;background:#12161b}.sidebar nav a.active{color:#fff;background:var(--sidebar-active);box-shadow:inset 3px 0 var(--accent)}.sidebar nav a.active>span{color:var(--accent)}.sidebar footer{margin-top:auto;padding-top:16px;border-top:1px solid #20252d}.system-online{display:flex;align-items:center;gap:10px;padding:9px}.system-online i,.connection-pill i,.connection-status i{width:8px;height:8px;border-radius:50%;background:var(--green);box-shadow:0 0 0 4px rgba(16,185,129,.12)}.system-online span{display:flex;flex-direction:column}.system-online strong{color:#dbe3ed;font-size:.8rem}.system-online small{font-size:.68rem}.sidebar-close{display:none}.main-shell{margin-left:262px;min-height:100vh}.topbar{height:var(--topbar);position:sticky;top:0;z-index:40;background:color-mix(in srgb,var(--surface) 90%,transparent);backdrop-filter:blur(18px);border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 28px}.topbar-left{display:flex;align-items:center;gap:12px}.topbar-left>div{display:flex;flex-direction:column}.topbar-title{font:700 1rem 'Manrope'}.topbar-left small{font-size:.72rem}.topbar-actions{display:flex;align-items:center;gap:10px}.icon-button{width:40px;height:40px;border:1px solid var(--line);background:var(--surface-2);color:var(--text);border-radius:11px;display:grid;place-items:center;cursor:pointer;font-size:1.05rem}.mobile-menu{display:none}.connection-pill{height:39px;padding:0 14px;border:1px solid var(--line);background:var(--surface-2);color:var(--muted);border-radius:11px;display:flex;gap:9px;align-items:center;font-size:.78rem}.user-menu{position:relative}.user-menu>button{border:0;background:transparent;color:var(--text);display:flex;align-items:center;gap:10px;padding:4px 6px;cursor:pointer;text-align:left}.user-menu>button>span:nth-child(2){display:flex;flex-direction:column}.user-menu strong{font-size:.78rem}.user-menu small{font-size:.68rem;text-transform:capitalize}.avatar{width:38px;height:38px;border-radius:12px;background:var(--accent-soft);color:var(--accent);display:grid;place-items:center;font:800 .9rem 'Manrope'}.user-popover{display:none;position:absolute;right:0;top:52px;background:var(--surface);border:1px solid var(--line);border-radius:12px;box-shadow:var(--shadow);min-width:170px;padding:7px}.user-popover.open{display:block}.user-popover a{display:block;padding:9px 11px;border-radius:8px;font-size:.85rem}.user-popover a:hover{background:var(--surface-3)}.content-area{padding:30px;max-width:1680px;margin:auto}.page-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin:4px 0 24px}.page-heading p{color:var(--muted);margin:0}.button{border:1px solid transparent;min-height:43px;padding:0 17px;border-radius:11px;font-weight:800;font-size:.86rem;display:inline-flex;align-items:center;justify-content:center;gap:10px;cursor:pointer;transition:.18s ease}.button:hover{transform:translateY(-1px)}.button:disabled{opacity:.45;cursor:not-allowed;transform:none}.button.primary{background:linear-gradient(135deg,var(--accent-2),var(--accent));color:#fff;box-shadow:0 10px 24px rgba(249,115,22,.2)}.button.secondary{background:var(--surface-3);border-color:var(--line);color:var(--text)}.button.ghost{background:transparent;border-color:var(--line);color:var(--text)}.button.small{min-height:34px;padding:0 11px;font-size:.75rem;border-radius:9px}.button.wide{width:100%}.panel{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);box-shadow:0 1px 0 rgba(255,255,255,.02);padding:22px}.stats-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:15px;margin-bottom:18px}.stats-grid.compact{grid-template-columns:repeat(3,minmax(0,1fr));max-width:1000px}.stat-card{position:relative;overflow:hidden;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:21px;min-height:142px;display:flex;flex-direction:column;justify-content:center}.stat-card::before{content:"";position:absolute;right:-38px;top:-44px;width:110px;height:110px;border-radius:50%;background:var(--surface-3)}.stat-card.accent::before{background:var(--accent-soft)}.stat-card.warning::before{background:var(--yellow-soft)}.stat-card>span{color:var(--muted);font-size:.7rem;font-weight:800;letter-spacing:.1em}.stat-card strong{font-size:1.75rem;letter-spacing:-.05em;margin:6px 0}.stat-card small{font-size:.76rem}.dashboard-grid{display:grid;grid-template-columns:1.45fr .8fr;gap:16px}.chart-card{min-height:355px}.panel-head{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:18px}.panel-head p{margin:0;color:var(--muted);font-size:.78rem}.panel-head a{color:var(--accent);font-weight:700;font-size:.78rem}.live-dot{color:var(--green);font-size:.72rem}.line-chart{height:260px;display:flex;flex-direction:column;justify-content:flex-end}.line-chart svg{width:100%;height:220px;overflow:visible}.grid-line{fill:none;stroke:var(--line);stroke-width:1;stroke-dasharray:4 7}.chart-area{fill:url(#area)}.chart-line{fill:none;stroke:var(--accent);stroke-width:3;stroke-linecap:round}.chart-labels{display:flex;justify-content:space-between;color:var(--muted);font-size:.67rem}.top-list{list-style:none;margin:0;padding:0}.top-list li{display:grid;grid-template-columns:35px 1fr auto;align-items:center;gap:10px;padding:12px 0;border-bottom:1px solid var(--line)}.top-list li:last-child{border-bottom:0}.rank{color:var(--accent);font:800 .75rem 'Manrope'}.top-list div{display:flex;flex-direction:column;min-width:0}.top-list strong{font-size:.82rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.top-list small{font-size:.68rem}.top-list b{font-size:.78rem}.stock-list>div{margin:14px 0}.stock-list>div>div{display:flex;justify-content:space-between;gap:12px;font-size:.78rem}.stock-list span{color:var(--muted)}progress{appearance:none;width:100%;height:6px;border:0;border-radius:8px;overflow:hidden;background:var(--surface-3)}progress::-webkit-progress-bar{background:var(--surface-3)}progress::-webkit-progress-value{background:var(--accent);border-radius:8px}progress::-moz-progress-bar{background:var(--accent)}.activity-list>div{display:flex;gap:11px;padding:12px 0;border-bottom:1px solid var(--line)}.activity-list>div:last-child{border:0}.activity-icon{width:34px;height:34px;border-radius:10px;background:var(--surface-3);display:grid;place-items:center;color:var(--muted)}.activity-list p{display:flex;flex-wrap:wrap;gap:4px;margin:0;font-size:.78rem}.activity-list p small{display:block;width:100%;font-size:.67rem}.empty-inline{padding:25px;text-align:center;color:var(--muted);font-size:.82rem}.empty-state{text-align:center;display:grid;place-items:center;min-height:330px;max-width:800px;margin:40px auto}.empty-icon{width:62px;height:62px;border-radius:20px;background:var(--accent-soft);color:var(--accent);display:grid;place-items:center;font-size:1.8rem;margin-bottom:16px}.empty-state p{color:var(--muted);max-width:500px}.table-panel{padding:0;overflow:hidden}.table-panel .panel-head{padding:18px 20px;margin:0;border-bottom:1px solid var(--line)}.table-wrap{width:100%;overflow:auto}table{width:100%;border-collapse:collapse;min-width:750px}th{text-align:left;padding:12px 18px;color:var(--muted);font-size:.67rem;letter-spacing:.08em;text-transform:uppercase;background:var(--surface-2)}td{padding:14px 18px;border-top:1px solid var(--line);font-size:.82rem}td strong,td small{display:block}td small{font-size:.68rem;margin-top:2px}tr:hover td{background:color-mix(in srgb,var(--surface-3) 45%,transparent)}.table-search{height:40px;width:250px;padding:0 13px;border:1px solid var(--line);border-radius:10px;background:var(--surface-2);color:var(--text);outline:none}.table-search.large{width:min(420px,100%)}.table-search:focus,input:focus,select:focus,textarea:focus{border-color:var(--accent);box-shadow:0 0 0 3px rgba(249,115,22,.12)}.status,.role-pill,.version-badge{display:inline-flex;align-items:center;width:max-content;padding:5px 9px;border-radius:99px;background:var(--surface-3);font-size:.67rem;font-weight:800;text-transform:capitalize}.status.active,.status.success{background:var(--green-soft);color:var(--green)}.status.trial{background:var(--yellow-soft);color:var(--yellow)}.status.suspended{background:var(--red-soft);color:var(--red)}.status.closed{color:var(--muted)}.role-pill{color:var(--violet);background:color-mix(in srgb,var(--violet) 13%,transparent)}.actions{display:flex;gap:6px}.actions form{margin:0}.text-warning{color:var(--yellow)!important}.text-danger{color:var(--red)!important}.text-success{color:var(--green)!important}.chip-group{display:flex;gap:7px}.chip{padding:7px 10px;border-radius:9px;background:var(--surface-3);font-size:.72rem}.chip.active{background:var(--accent-soft);color:var(--accent)}dialog{border:0;padding:0;background:transparent;color:var(--text);max-width:calc(100vw - 30px)}dialog::backdrop{background:rgba(2,6,12,.72);backdrop-filter:blur(5px)}.dialog-card{width:min(560px,calc(100vw - 30px));max-height:88vh;overflow:auto;background:var(--surface);border:1px solid var(--line);border-radius:20px;padding:23px;box-shadow:0 30px 90px rgba(0,0,0,.35)}.dialog-card.wide{width:min(760px,calc(100vw - 30px))}.dialog-head{display:flex;justify-content:space-between;gap:20px;margin-bottom:20px}.dialog-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:22px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.span-2{grid-column:span 2}.form-row{display:grid;grid-template-columns:2fr 1fr;gap:12px}.dialog-card label,.installer-form label,.login-form label,.customer-select,.checkout-dialog label{display:flex;flex-direction:column;gap:6px;color:var(--muted);font-size:.74rem;font-weight:700;margin-bottom:13px}.dialog-card input,.dialog-card select,.dialog-card textarea,.installer-form input,.login-form input,.customer-select select,.checkout-dialog input,.checkout-dialog select{width:100%;height:44px;border:1px solid var(--line);border-radius:10px;background:var(--surface-2);color:var(--text);padding:0 12px;outline:none}.dialog-card textarea{height:85px;padding-top:10px;resize:vertical}.dialog-card small,.installer-form small{font-size:.66rem}.check-label{flex-direction:row!important;align-items:center;margin-top:20px}.check-label input{width:18px;height:18px}.dialog-card hr{border:0;border-top:1px solid var(--line);margin:18px 0}.alert{border:1px solid var(--line);border-radius:11px;padding:12px 14px;margin:12px 0;font-size:.8rem}.alert.success{background:var(--green-soft);border-color:color-mix(in srgb,var(--green) 25%,transparent);color:var(--green)}.alert.danger{background:var(--red-soft);border-color:color-mix(in srgb,var(--red) 25%,transparent);color:var(--red)}.alert.warning{background:var(--yellow-soft);border-color:color-mix(in srgb,var(--yellow) 25%,transparent);color:var(--yellow)}.toast-alert{position:fixed;right:24px;top:89px;z-index:100;width:min(400px,calc(100vw - 48px));box-shadow:var(--shadow);display:flex;justify-content:space-between;align-items:center}.toast-alert button{background:transparent;border:0;color:inherit;font-size:1.1rem;cursor:pointer}.shift-banner{display:flex;justify-content:space-between;margin-bottom:18px}.report-grid,.updater-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.payment-bars>div{margin-bottom:20px}.payment-bars header{display:flex;justify-content:space-between;font-size:.8rem}.payment-bars small{font-size:.66rem}.payment-bars progress{margin:8px 0}.version-badge{background:var(--accent-soft);color:var(--accent);padding:8px 12px}.upload-panel{text-align:center}.update-icon{width:66px;height:66px;border-radius:21px;background:var(--accent-soft);color:var(--accent);display:grid;place-items:center;font-size:2rem;margin:0 auto 15px}.upload-panel>p{color:var(--muted);font-size:.84rem}.drop-zone{border:1px dashed color-mix(in srgb,var(--accent) 55%,var(--line));background:var(--accent-soft);border-radius:14px;padding:25px!important;display:grid!important;place-items:center;cursor:pointer}.drop-zone input{display:none}.drop-zone strong{color:var(--text);font-size:.86rem}.drop-icon{display:grid;place-items:center;width:48px;height:36px;border-radius:8px;background:var(--accent);color:#fff;font:800 .72rem 'Manrope';margin-bottom:10px}.update-history>div{display:grid;grid-template-columns:38px 1fr auto;gap:12px;padding:14px 0;border-bottom:1px solid var(--line);align-items:center}.update-status{width:34px;height:34px;border-radius:11px;background:var(--green-soft);color:var(--green);display:grid;place-items:center;font-weight:900}.update-history p{display:flex;flex-direction:column;margin:0}.update-history p strong{font-size:.8rem}.update-history p span,.update-history p small{font-size:.68rem;color:var(--muted)}

/* POS */
.pos-page .content-area{padding:0;max-width:none;height:calc(100vh - var(--topbar));overflow:hidden}.pos-shell{display:grid;grid-template-columns:minmax(0,1fr) 420px;height:100%;background:var(--bg)}.pos-catalog{padding:18px 20px;overflow:auto}.pos-toolbar{display:flex;gap:10px;align-items:center}.pos-search{flex:1;position:relative}.pos-search>span{position:absolute;left:14px;top:9px;font-size:1.2rem;color:var(--muted)}.pos-search input{width:100%;height:46px;border:1px solid var(--line);background:var(--surface);color:var(--text);border-radius:12px;padding:0 48px 0 40px;outline:none}.pos-search kbd{position:absolute;right:12px;top:11px;border:1px solid var(--line);background:var(--surface-3);padding:3px 7px;border-radius:6px;color:var(--muted);font-size:.7rem}.scanner-button{background:var(--surface);border-color:var(--line);color:var(--text)}.scanner-button span{color:var(--accent)}.connection-status{display:flex;align-items:center;gap:8px;font-size:.72rem;color:var(--green);white-space:nowrap}.shift-warning{display:flex;align-items:center;justify-content:space-between;margin-top:12px}.category-strip{display:flex;gap:8px;overflow:auto;padding:16px 1px 12px;scrollbar-width:none}.category-pill{border:1px solid var(--line);background:var(--surface);color:var(--muted);height:37px;border-radius:99px;padding:0 13px;white-space:nowrap;font-size:.74rem;font-weight:700;cursor:pointer}.category-pill b{margin-left:5px;font-size:.66rem}.category-pill.active{background:var(--accent);border-color:var(--accent);color:#fff}.product-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;padding-bottom:30px}.product-card{min-height:102px;border:1px solid var(--line);background:var(--surface);color:var(--text);border-radius:14px;padding:12px;display:grid;grid-template-columns:44px 1fr auto;gap:11px;text-align:left;cursor:pointer;transition:.16s ease}.product-card:hover{border-color:var(--accent);transform:translateY(-2px);box-shadow:0 12px 28px rgba(0,0,0,.08)}.product-card:disabled{opacity:.48;cursor:not-allowed;transform:none}.product-avatar{width:44px;height:44px;border-radius:12px;background:color-mix(in srgb,var(--product-color) 15%,var(--surface-3));color:var(--product-color);display:grid;place-items:center;font:800 1rem 'Manrope'}.product-info{min-width:0;display:flex;flex-direction:column}.product-info>small{font-size:.61rem}.product-info>strong{font-size:.78rem;line-height:1.25;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;margin:2px 0 6px}.stock-badge{width:max-content;font-size:.61rem;color:var(--green);background:var(--green-soft);padding:2px 6px;border-radius:5px}.stock-badge.low{color:var(--yellow);background:var(--yellow-soft)}.product-price{font:800 .8rem 'Manrope';color:var(--accent);white-space:nowrap}.product-price small{display:block;font:400 .6rem 'DM Sans';text-align:right}.cart-panel{background:var(--surface);border-left:1px solid var(--line);display:flex;flex-direction:column;min-height:0}.cart-panel>header{display:flex;align-items:center;justify-content:space-between;padding:18px;border-bottom:1px solid var(--line)}.customer-select{margin:12px 16px 0}.customer-select select{height:40px}.cart-items{flex:1;overflow:auto;padding:10px 16px}.cart-empty{height:100%;display:grid;place-items:center;align-content:center;color:var(--muted);text-align:center}.cart-empty>span{font-size:2rem;color:var(--line)}.cart-empty strong{font-size:.86rem;margin-top:8px}.cart-empty small{font-size:.7rem}.cart-item{display:grid;grid-template-columns:1fr auto;gap:8px;padding:12px 0;border-bottom:1px solid var(--line)}.cart-item header{display:flex;flex-direction:column}.cart-item header strong{font-size:.78rem}.cart-item header small{font-size:.64rem}.cart-item-price{font:800 .79rem 'Manrope'}.cart-item-controls{grid-column:1/-1;display:flex;align-items:center;justify-content:space-between}.qty-controls{display:flex;align-items:center;border:1px solid var(--line);border-radius:9px;overflow:hidden}.qty-controls button{width:31px;height:30px;border:0;background:var(--surface-3);color:var(--text);cursor:pointer}.qty-controls input{width:54px;height:30px;border:0;border-inline:1px solid var(--line);background:var(--surface);color:var(--text);text-align:center;outline:none}.remove-item{border:0;background:transparent;color:var(--red);font-size:.7rem;cursor:pointer}.cart-summary{border-top:1px solid var(--line);padding:14px 18px}.cart-summary>div{display:flex;justify-content:space-between;margin:5px 0;font-size:.78rem}.link-button{border:0;background:transparent;color:var(--accent);cursor:pointer}.cart-summary .cart-total{font-size:1rem;border-top:1px dashed var(--line);padding-top:11px;margin-top:11px}.cart-total strong{font-size:1.5rem;color:var(--accent);letter-spacing:-.04em}.cart-actions{display:grid;grid-template-columns:1fr 1.5fr;gap:9px;padding:0 18px 18px}.checkout-button span{background:rgba(255,255,255,.2);padding:2px 6px;border-radius:5px;font-size:.65rem}.scanner-dialog{width:min(620px,calc(100vw - 30px))}.scanner-viewport{position:relative;overflow:hidden;border-radius:15px;background:#050608;aspect-ratio:4/3}.scanner-viewport video{width:100%;height:100%;object-fit:cover}.scanner-frame{position:absolute;left:13%;right:13%;top:32%;height:36%;border:2px solid var(--accent);border-radius:16px;box-shadow:0 0 0 999px rgba(0,0,0,.38)}.scanner-viewport p{position:absolute;bottom:14px;left:0;right:0;color:#fff;text-align:center;font-size:.76rem}.checkout-total{display:flex;justify-content:space-between;align-items:center;padding:18px;background:var(--accent-soft);border-radius:14px;margin-bottom:17px}.checkout-total strong{font-size:1.65rem;color:var(--accent)}.payment-methods{display:grid;grid-template-columns:repeat(3,1fr);gap:7px;margin:8px 0 16px}.payment-method{height:39px;border:1px solid var(--line);background:var(--surface-2);color:var(--text);border-radius:9px;cursor:pointer;font-size:.72rem;font-weight:700}.payment-method.active{border-color:var(--accent);background:var(--accent-soft);color:var(--accent)}.change-box{display:flex;justify-content:space-between;padding:12px 0;border-top:1px solid var(--line);margin-top:5px}.change-box strong{color:var(--green)}

/* Login + installer */
.login-body,.installer-body{min-height:100vh;background:var(--bg)}.login-shell{min-height:100vh;display:grid;grid-template-columns:1.15fr .85fr}.login-visual{background:radial-gradient(circle at 75% 80%,rgba(249,115,22,.25),transparent 30%),linear-gradient(145deg,#111820,#090b0e);padding:clamp(30px,6vw,90px);color:#fff;display:flex;flex-direction:column;justify-content:space-between}.login-visual h1{font-size:clamp(2.7rem,6vw,5.8rem);letter-spacing:-.07em;margin:12px 0}.login-visual p{color:#a4afbd;font-size:1.1rem}.login-badges{display:flex;flex-wrap:wrap;gap:20px;color:#adb7c5;font-size:.76rem}.login-badges span::first-letter{color:var(--green)}.login-card{position:relative;width:min(470px,calc(100% - 40px));margin:auto;padding:30px}.login-card h2{font-size:1.7rem}.floating{position:absolute;right:0;top:0}.login-form{margin-top:26px}.login-help{text-align:center;color:var(--muted);font-size:.72rem;margin-top:18px}.installer-shell{width:min(1200px,calc(100% - 32px));margin:35px auto}.installer-brand{display:flex;align-items:center;gap:10px;margin-bottom:28px}.installer-brand>div:last-child{display:flex;flex-direction:column}.installer-brand span:last-child{color:var(--muted);font-size:.72rem}.installer-grid{display:grid;grid-template-columns:.8fr 1.2fr;gap:18px}.installer-copy{background:linear-gradient(160deg,var(--surface),var(--surface-2));padding:36px}.installer-copy h1{font-size:2.4rem}.installer-copy>p{color:var(--muted)}.requirements{margin-top:30px}.requirement{display:flex;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid var(--line);font-size:.8rem}.requirement span{width:24px;height:24px;border-radius:8px;display:grid;place-items:center}.requirement.ok span{background:var(--green-soft);color:var(--green)}.requirement.fail span{background:var(--red-soft);color:var(--red)}.installer-form{padding:30px}.form-section-title{font-size:.68rem;font-weight:800;letter-spacing:.1em;color:var(--accent);margin:20px 0 10px}

.pos-notice{position:fixed;z-index:200;left:50%;bottom:25px;transform:translateX(-50%);background:var(--green);color:#fff;padding:12px 18px;border-radius:12px;box-shadow:var(--shadow);font-weight:700;font-size:.8rem}.pos-notice.warning{background:var(--yellow);color:#231900}.pos-notice.danger{background:var(--red)}.sidebar-overlay{display:none}.hide{display:none!important}@media(max-width:1280px){.product-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.pos-shell{grid-template-columns:minmax(0,1fr) 390px}.scanner-button{font-size:0}.scanner-button span{font-size:1rem}.dashboard-grid{grid-template-columns:1fr 1fr}.stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:900px){:root{--topbar:66px}.sidebar{transform:translateX(-102%);transition:.22s ease}.sidebar.open{transform:translateX(0)}.sidebar-close{display:block;position:absolute;right:12px;top:12px;background:transparent;border:0;color:#fff;font-size:1.4rem}.sidebar-overlay{position:fixed;inset:0;background:rgba(0,0,0,.55);z-index:45}.sidebar.open~.main-shell+.sidebar-overlay{display:block}.main-shell{margin-left:0}.mobile-menu{display:grid}.topbar{padding:0 15px}.content-area{padding:20px}.user-menu>button>span:nth-child(2),.user-menu>button>b,.connection-pill span{display:none}.dashboard-grid,.report-grid,.updater-grid{grid-template-columns:1fr}.pos-page .topbar{display:none}.pos-page .content-area{height:100vh}.pos-shell{grid-template-columns:1fr;height:100vh}.pos-catalog{padding:12px}.cart-panel{position:fixed;z-index:35;left:0;right:0;bottom:0;height:52vh;border:1px solid var(--line);border-radius:20px 20px 0 0;box-shadow:0 -20px 55px rgba(0,0,0,.3);transform:translateY(calc(100% - 78px));transition:.25s ease}.cart-panel.open{transform:translateY(0)}.cart-panel>header{cursor:pointer}.pos-catalog{padding-bottom:92px}.product-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.product-card{grid-template-columns:38px 1fr}.product-avatar{width:38px;height:38px}.product-price{grid-column:2}.login-shell{grid-template-columns:1fr}.login-visual{display:none}.installer-grid{grid-template-columns:1fr}.installer-copy{padding:25px}.installer-copy h1{font-size:1.9rem}}@media(max-width:560px){.topbar-actions>.button{display:none}.page-heading{align-items:flex-start;flex-direction:column}.page-heading .button{width:100%}.stats-grid,.stats-grid.compact{grid-template-columns:1fr 1fr}.stat-card{min-height:120px;padding:16px}.stat-card strong{font-size:1.35rem}.product-grid{grid-template-columns:1fr}.pos-toolbar{flex-wrap:wrap}.pos-search{flex-basis:calc(100% - 55px)}.scanner-button{width:45px;padding:0}.connection-status{display:none}.form-grid,.form-row{grid-template-columns:1fr}.span-2{grid-column:auto}.payment-methods{grid-template-columns:repeat(2,1fr)}.installer-shell{margin:16px auto}.panel{border-radius:15px}.login-card{padding:20px}.toast-alert{right:12px;top:76px;width:calc(100vw - 24px)}}@media print{.sidebar,.topbar,.page-heading .button{display:none!important}.main-shell{margin:0}.content-area{padding:0}.panel{box-shadow:none}}
/* Settings form shares the same control language as dialogs. */
.settings-form label{display:flex;flex-direction:column;gap:6px;color:var(--muted);font-size:.74rem;font-weight:700;margin-bottom:13px}.settings-form input,.settings-form select,.settings-form textarea{width:100%;height:44px;border:1px solid var(--line);border-radius:10px;background:var(--surface-2);color:var(--text);padding:0 12px;outline:none}.settings-form textarea{height:85px;padding-top:10px;resize:vertical}

/* Superadmin commercial console */
.plan-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.plan-card{display:flex;flex-direction:column;min-height:285px}.plan-card h2{font-size:1.35rem;margin-top:18px}.plan-card>p{color:var(--muted);font-size:.8rem;min-height:42px}.plan-card>strong{font-size:1.8rem;color:var(--accent);margin:7px 0}.plan-card>strong small{font:500 .72rem 'DM Sans';color:var(--muted)}.plan-card ul{list-style:none;padding:0;margin:12px 0}.plan-card li{border-top:1px solid var(--line);padding:8px 0;color:var(--muted);font-size:.78rem}.plan-card li::before{content:'✓';color:var(--green);margin-right:8px}.plan-card footer{margin-top:auto;font-size:.7rem;color:var(--muted)}.quick-actions{display:flex;flex-direction:column}.quick-actions>a{display:flex;align-items:center;gap:12px;padding:13px;border:1px solid var(--line);border-radius:12px;margin-bottom:9px;background:var(--surface-2)}.quick-actions>a>span{width:36px;height:36px;border-radius:10px;display:grid;place-items:center;background:var(--accent-soft);color:var(--accent);font-weight:800}.quick-actions>a>div{display:flex;flex-direction:column}.quick-actions strong{font-size:.8rem}.quick-actions small{font-size:.67rem}.announcement-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.announcement-card header{display:flex;justify-content:space-between;align-items:center}.announcement-card h2{margin-top:18px}.announcement-card p{color:var(--muted);font-size:.85rem;white-space:normal}.health-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:16px}.health-card{display:flex;align-items:center;gap:12px;padding:17px}.health-card>div{display:flex;flex-direction:column}.health-card strong{font-size:.8rem}.health-icon{width:38px;height:38px;border-radius:11px;display:grid;place-items:center;font-weight:900}.health-icon.ok{background:var(--green-soft);color:var(--green)}.health-icon.fail{background:var(--red-soft);color:var(--red)}.big-metric{display:block;font-size:2rem;color:var(--accent);margin-top:12px}
@media(max-width:1100px){.plan-grid,.health-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:700px){.plan-grid,.health-grid,.announcement-grid{grid-template-columns:1fr}}

/* Catálogo maestro e inventario trazable */
.barcode-control{display:grid;grid-template-columns:minmax(0,1fr) 46px;gap:8px}.barcode-control .camera-button{width:46px;height:44px;border-color:color-mix(in srgb,var(--accent) 55%,var(--line));background:var(--accent-soft);color:var(--accent);font-size:1.15rem}.dialog-card [data-master-status][data-state="found"]{color:var(--green)}.dialog-card [data-master-status][data-state="missing"]{color:var(--yellow)}.dialog-card [data-master-status][data-state="error"]{color:var(--red)}.dialog-card [data-master-status][data-state="loading"]{color:var(--accent)}.heading-actions{display:flex;gap:9px;flex-wrap:wrap}.inventory-products{margin-bottom:16px}.inventory-products .status.trial{background:var(--yellow-soft);color:var(--yellow)}
.product-cell{display:flex;align-items:center;gap:10px;min-width:190px;max-width:340px}.product-cell>span:last-child{display:flex;min-width:0;flex-direction:column}.product-cell>.product-thumb{display:block!important;width:44px!important;height:44px!important;min-width:44px!important;max-width:44px!important;min-height:44px!important;max-height:44px!important;flex:0 0 44px!important;border-radius:10px;border:1px solid var(--line);background:var(--surface-3);object-fit:cover!important;object-position:center!important}.product-thumb.placeholder{display:grid!important;place-items:center;color:var(--accent);font-weight:900}.inventory-products .product-cell>.product-thumb{width:40px!important;height:40px!important;min-width:40px!important;max-width:40px!important;min-height:40px!important;max-height:40px!important;flex-basis:40px!important}.product-avatar{overflow:hidden}.product-avatar img{display:block;width:100%!important;height:100%!important;max-width:100%!important;object-fit:cover!important;object-position:center!important}.dialog-card input[type="file"]{height:auto;padding:10px}.image-preview-wrap{display:flex;align-items:center;gap:12px;padding:12px;border:1px dashed var(--line);border-radius:12px;background:var(--surface-2);color:var(--muted);font-size:.72rem}.image-preview{width:92px;height:92px;max-width:92px;border-radius:14px;border:1px solid var(--line);object-fit:cover;object-position:center;background:var(--surface-3)}
@media(max-width:560px){.heading-actions{width:100%}.heading-actions .button{flex:1}.barcode-control{grid-template-columns:minmax(0,1fr) 46px}}

/* Cobro legible y guiado */
.checkout-dialog{width:min(620px,calc(100vw - 30px))}.checkout-dialog [hidden]{display:none!important}.checkout-total{padding:22px}.checkout-total span{font:800 1rem 'Manrope',sans-serif}.checkout-total strong{font-size:2.15rem}.checkout-operation{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:-5px 0 17px;padding:10px 12px;border:1px solid var(--line);border-radius:10px;background:var(--surface-2)}.checkout-operation span{color:var(--muted);font-size:.78rem;font-weight:700}.checkout-operation strong{font-size:.86rem;color:var(--text);text-align:right}.checkout-dialog label{font-size:.86rem}.checkout-dialog #payment-amount{height:56px;font:800 1.4rem 'Manrope',sans-serif}.checkout-dialog #checkout-customer{height:48px}.checkout-dialog label>small{font-size:.7rem;font-weight:500}.change-box{padding:16px 0}.change-box span{font:800 1rem 'Manrope',sans-serif}.change-box strong{font-size:1.5rem}

.credit-customer-picker{margin-bottom:14px}.credit-customer-picker>label{margin-bottom:7px}.credit-customer-picker>small{display:block;margin-top:7px;color:var(--muted);font-size:.7rem}.credit-customer-results{display:grid;gap:6px;max-height:220px;overflow:auto}.credit-customer-results button{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;padding:10px 12px;border:1px solid var(--line);border-radius:9px;background:var(--surface-2);color:var(--text);cursor:pointer;text-align:left}.credit-customer-results button:hover{border-color:var(--accent);background:var(--accent-soft)}.credit-customer-results button strong{font-size:.78rem}.credit-customer-results button span{color:var(--accent);font-size:.7rem;font-weight:800}.credit-customer-empty{padding:12px;border:1px dashed var(--line);border-radius:9px;color:var(--muted);font-size:.75rem;text-align:center}.credit-customer-selected{padding:10px 12px;border:1px solid color-mix(in srgb,var(--green) 30%,var(--line));border-radius:9px;background:var(--green-soft);color:var(--green);font-size:.78rem;font-weight:800}

/* Caja móvil: escaneo continuo, confirmación del producto y carrito en flujo */
.cart-panel>header h2{display:flex;align-items:center;gap:9px}.cart-count{display:inline-grid;place-items:center;min-width:25px;height:25px;padding:0 7px;border-radius:99px;background:var(--accent-soft);color:var(--accent);font:800 .72rem 'Manrope',sans-serif}.scan-product-review{margin-top:13px;padding:14px;border:1px solid color-mix(in srgb,var(--accent) 42%,var(--line));border-radius:15px;background:var(--surface-2)}.scan-product-review[hidden]{display:none!important}.scan-product-main{display:grid;grid-template-columns:58px minmax(0,1fr) auto;gap:12px;align-items:center}.scan-product-image{display:grid;place-items:center;width:58px;height:58px;border-radius:13px;overflow:hidden;background:var(--accent-soft);color:var(--accent);font:900 1.4rem 'Manrope',sans-serif}.scan-product-image img{display:block;width:100%;height:100%;object-fit:cover;object-position:center}.scan-product-main>div{display:flex;min-width:0;flex-direction:column}.scan-product-main small{color:var(--green);font-weight:800}.scan-product-main strong{font-size:.92rem;line-height:1.25}.scan-product-main span{color:var(--muted);font-size:.68rem}.scan-product-main>b{color:var(--accent);font-size:1.05rem}.scan-product-controls{display:grid;grid-template-columns:auto auto 1fr;align-items:center;gap:12px;margin:15px 0}.scan-product-controls>span{color:var(--muted);font-size:.75rem;font-weight:700}.scan-qty input{width:58px}.scan-line-total{display:flex;align-items:flex-end;justify-content:flex-end;gap:8px}.scan-line-total span{color:var(--muted);font-size:.72rem}.scan-line-total strong{color:var(--accent);font-size:1.25rem}.scan-add-button{min-height:49px}.scan-secondary-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:9px}

@media(max-width:900px){
  .pos-page .content-area{height:auto;min-height:100vh;overflow:visible;padding:0 0 max(22px,env(safe-area-inset-bottom))}
  .pos-shell{display:flex;flex-direction:column;height:auto;min-height:100vh;overflow:visible}
  .pos-catalog{overflow:visible;padding:12px 12px 18px}
  .pos-toolbar{position:sticky;top:0;z-index:20;padding:7px 0 9px;background:color-mix(in srgb,var(--bg) 94%,transparent);backdrop-filter:blur(12px)}
  .pos-catalog .product-grid{padding-bottom:8px}
  .cart-panel,.cart-panel.open{position:static;z-index:auto;display:flex;height:auto;min-height:0;margin:0 12px 16px;border:1px solid var(--line);border-radius:20px;box-shadow:none;transform:none}
  .cart-panel>header{cursor:default;scroll-margin-top:72px}
  .cart-items{flex:none;min-height:145px;max-height:none;overflow:visible}
  .cart-empty{min-height:145px}
  .cart-actions{padding-bottom:18px}
  #checkout-dialog[open]{position:static;inset:auto;display:block;width:auto;max-width:none;max-height:none;margin:0 12px 26px;padding:0;overflow:visible;background:transparent;scroll-margin-top:72px}
  #checkout-dialog>.checkout-dialog{width:100%;max-height:none;border-radius:20px}
  #checkout-dialog::backdrop{display:none}
}

@media(max-width:560px){
  #scanner-dialog[open]{position:fixed;inset:0;display:block;width:100vw;max-width:none;height:100dvh;max-height:none;margin:0;padding:0;overflow:hidden}
  #scanner-dialog>.scanner-dialog{width:100%;height:100%;max-height:none;padding:16px 16px max(20px,env(safe-area-inset-bottom));border-radius:0;overflow-y:auto}
  #scanner-dialog .dialog-head{position:sticky;top:-16px;z-index:4;margin:-16px -16px 12px;padding:16px;background:color-mix(in srgb,var(--surface) 94%,transparent);backdrop-filter:blur(12px)}
  #scanner-dialog .scanner-viewport{aspect-ratio:4/3;max-height:42vh}
  .scan-product-main{grid-template-columns:54px minmax(0,1fr)}
  .scan-product-main>b{grid-column:2;font-size:1.2rem}
  .scan-product-controls{grid-template-columns:auto auto;gap:10px}
  .scan-line-total{grid-column:1/-1;justify-content:space-between;padding-top:10px;border-top:1px solid var(--line)}
  .scan-line-total strong{font-size:1.45rem}
  .scan-secondary-actions{grid-template-columns:1fr}
  .cart-actions{grid-template-columns:1fr}
  .cart-actions .button{min-height:50px}
  #checkout-dialog>.checkout-dialog{padding:18px}
  .checkout-total strong{font-size:2rem}
  .payment-methods{grid-template-columns:repeat(3,1fr)}
}

/* Caja centrada en la venta: el catálogo solo aparece al buscar. */
.sale-processing{pointer-events:none;opacity:.75}
.scanner-button>span{display:inline-flex;align-items:center;justify-content:center}
.pos-page .topbar{display:flex}
.pos-page .content-area{height:auto;min-height:calc(100dvh - var(--topbar));overflow:visible;padding:0 0 24px}
.pos-shell{display:flex;flex-direction:column;height:auto;min-height:calc(100dvh - var(--topbar));max-width:980px;margin:auto}
.pos-catalog{overflow:visible;padding:16px 20px 12px}
.pos-catalog .category-strip{display:none}
.pos-catalog .product-grid{display:none;padding:0;grid-template-columns:repeat(2,minmax(0,1fr));max-height:340px;overflow:auto}
.searching-products .product-grid{display:grid}
.pos-search-feedback{font-size:.8rem;color:var(--muted);margin:12px 0 10px}
.pos-search-feedback[hidden]{display:none}
.pos-shell .cart-panel,.pos-shell .cart-panel.open{position:static;height:auto;min-height:420px;border:1px solid var(--line);border-radius:20px;box-shadow:none;transform:none;margin:0 20px 20px;z-index:auto}
.cart-panel>header{padding:20px;cursor:default}
.cart-panel>header h2{font-size:1.65rem}
.cart-help{font-size:.8rem;color:var(--muted);padding:14px 20px 0;margin:0}
.cart-items{flex:1;overflow:visible;padding:10px 20px;min-height:160px}
.cart-empty{min-height:160px}
.cart-item{grid-template-columns:64px minmax(0,1fr) auto;gap:12px;padding:16px 0;align-items:start}
.cart-product-image{display:grid;place-items:center;width:64px;height:64px;overflow:hidden;border:1px solid var(--line);border-radius:13px;background:var(--surface-2);color:var(--accent);font-size:1.5rem;font-weight:800}
.cart-product-image img{display:block;width:100%;height:100%;object-fit:contain;object-position:center}
.cart-item header strong{font-size:1rem;line-height:1.35;overflow-wrap:anywhere}
.cart-item header small{font-size:.72rem;margin:4px 0}
.cart-unit-price{font-size:.88rem;font-weight:800;color:var(--muted)}
.cart-item-price{display:flex;flex-direction:column;text-align:right}
.cart-item-price small{font:500 .7rem 'DM Sans',sans-serif}
.cart-item-price strong{font-size:1.2rem;color:var(--accent)}
.cart-item-controls{grid-column:2/-1;gap:12px}
.cart-quantity{display:flex;gap:12px;align-items:center}
.cart-quantity>span{font-size:.8rem;color:var(--muted)}
.qty-controls button{width:44px;height:44px;font-size:1.25rem}
.qty-controls input{width:64px;height:44px;font-size:1.05rem;font-weight:800}
.remove-item{min-height:44px;padding:0 10px;border-radius:9px;background:var(--red-soft);font-size:.78rem}
.cart-panel .customer-select{margin:16px 20px 0;font-size:.8rem}
.cart-panel .customer-select select{height:48px;font-size:.86rem}
.cart-summary{padding:18px 20px}
.cart-summary>div{font-size:.95rem}
.cart-summary .cart-total{font-size:1.25rem}
.cart-total strong{font-size:2rem}
.cart-actions{padding:0 20px 20px;grid-template-columns:1fr 2fr}
.cart-actions .button{min-height:52px;font-size:.95rem}
/* El contenedor Android aporta su propia cabecera y navegación segura. */
.yllapos-native .sidebar,.yllapos-native .topbar,.yllapos-native .sidebar-overlay{display:none!important}
.yllapos-native .main-shell{margin-left:0}
.yllapos-native .pos-page .content-area,.yllapos-native .pos-shell{min-height:calc(100dvh - 20px)}
.yllapos-native .pos-search kbd,.yllapos-native .checkout-button span{display:none}
.yllapos-native .pos-search input{padding-right:12px}
.yllapos-native .toast-alert{top:12px}
@media(max-width:560px){
  .pos-catalog{padding:12px 12px 10px}
  .pos-shell .cart-panel,.pos-shell .cart-panel.open{margin:0 12px 16px;min-height:calc(100dvh - 200px)}
  .pos-catalog .product-grid{grid-template-columns:1fr;max-height:260px}
  .pos-toolbar{flex-wrap:nowrap}
  .pos-search{min-width:0;flex-basis:auto}
  .scanner-button{flex:0 0 48px;height:48px}
  .cart-panel>header,.cart-summary{padding:16px}
  .cart-panel>header h2{font-size:1.4rem}
  .cart-help{padding:12px 16px 0;font-size:.75rem}
  .cart-items{padding:8px 16px}
  .cart-item{grid-template-columns:52px minmax(0,1fr);gap:10px}
  .cart-product-image{width:52px;height:60px;grid-row:span 2}
  .cart-item header strong{font-size:.94rem}
  .cart-item-price{grid-column:2;flex-direction:row;justify-content:space-between;align-items:center;text-align:left}
  .cart-item-price strong{font-size:1.15rem}
  .cart-item-controls{grid-column:1/-1}
  .cart-quantity{gap:8px}
  .cart-panel .customer-select{margin:12px 16px 0}
  .cart-actions{grid-template-columns:1fr 1.6fr;padding:0 16px 18px;gap:8px}
  .cart-actions .button{font-size:.84rem;padding:0 10px}
  .cart-total strong{font-size:1.9rem}
}
@media(max-width:360px){.cart-quantity>span{display:none}}
