:root{--bg:#f4f6fa;--card:#fff;--ink:#18212f;--muted:#637083;--border:#e3e8f0;--primary:#2358d8;--primary2:#1747bf;--danger:#ba2b38;--success:#157347;--sidebar:#0f172a;--sidebar-text:#d8e0ee;--radius:14px;font-family:Inter,Arial,sans-serif}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink)}a{color:var(--primary);text-decoration:none}.sidebar{position:fixed;top:0;left:0;bottom:0;width:235px;background:var(--sidebar);color:#fff;padding:24px 16px;display:flex;flex-direction:column}.brand{font-weight:800;font-size:22px;letter-spacing:.04em;margin:0 8px 25px}.brand span{font-size:12px;display:block;color:#93c5fd;margin-top:5px}.sidebar nav{display:grid;gap:4px;overflow:auto}.sidebar nav a{color:var(--sidebar-text);padding:10px 12px;border-radius:9px;font-size:14px}.sidebar nav a:hover{background:#1e293b;color:#fff}.logout{margin-top:auto}.logout button{width:100%;background:#1e293b;color:#fff;border:0;padding:11px;border-radius:9px;cursor:pointer}.app{margin-left:235px;padding:0 30px 34px}.guest{max-width:440px;margin:90px auto}.topbar{height:62px;display:flex;align-items:center;justify-content:flex-end;gap:14px;border-bottom:1px solid var(--border);margin-bottom:26px}.topbar small{color:var(--muted)}h1{font-size:28px;margin:0 0 5px}h2{font-size:18px;margin:0 0 17px}h3{font-size:15px;margin:20px 0 8px}.page-header{display:flex;justify-content:space-between;align-items:start;gap:20px;margin-bottom:22px}.page-header p,.muted{color:var(--muted);margin:5px 0}.card{background:var(--card);border:1px solid var(--border);border-radius:var(--radius);padding:22px;margin-bottom:20px;box-shadow:0 1px 2px rgba(15,23,42,.03)}.narrow{max-width:490px}.metrics{display:grid;grid-template-columns:repeat(4,1fr);gap:16px;margin-bottom:22px}.metrics.two{grid-template-columns:repeat(2,minmax(250px,360px))}.metrics article{background:var(--card);border:1px solid var(--border);border-radius:var(--radius);padding:19px}.metrics span{display:block;color:var(--muted);font-size:13px;margin-bottom:10px}.metrics strong{font-size:25px}.grid-2{display:grid;grid-template-columns:1fr 1.35fr;gap:20px;align-items:start}.form-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:16px}.span2{grid-column:span 2}.stack{display:grid;gap:15px}label{display:grid;gap:6px;color:#344054;font-size:13px;font-weight:600}input,select,textarea{width:100%;border:1px solid #ccd5e1;border-radius:8px;padding:10px 11px;background:#fff;font:inherit;color:var(--ink)}input:focus,select:focus{outline:2px solid #bfdbfe;border-color:var(--primary)}label small{font-weight:400;color:var(--muted)}.checkbox{display:flex;align-items:center;gap:8px;padding-top:28px}.checkbox input{width:auto}.actions{grid-column:span 2;margin-top:8px;display:flex;gap:9px}.button,button{display:inline-flex;align-items:center;justify-content:center;border:1px solid #cbd5e1;background:#fff;color:var(--ink);padding:10px 15px;border-radius:8px;font-size:14px;cursor:pointer}.primary{border-color:var(--primary);background:var(--primary);color:#fff}.primary:hover{background:var(--primary2)}.danger-btn{border-color:var(--danger);background:var(--danger);color:#fff}.filters{display:flex;gap:10px;align-items:end;margin-bottom:15px}.filters input{min-width:260px}.table-wrap{overflow:auto}table{width:100%;border-collapse:collapse;font-size:14px}th{font-size:12px;text-transform:uppercase;letter-spacing:.03em;color:var(--muted);text-align:left;padding:0 10px 12px}td{padding:13px 10px;border-top:1px solid var(--border);vertical-align:middle}.danger{color:var(--danger);font-weight:700}.alert{padding:12px 15px;border-radius:9px;margin-bottom:18px}.alert.success{background:#d1fae5;color:var(--success)}.alert.error{background:#fee2e2;color:var(--danger)}.login-card{background:#fff;border:1px solid var(--border);border-radius:18px;padding:35px;box-shadow:0 12px 32px rgba(15,23,42,.08)}.pos-grid{display:grid;grid-template-columns:1.25fr .9fr;gap:20px}.product-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;max-height:560px;overflow:auto;margin-top:14px}.product-grid button{display:grid;justify-content:start;text-align:left;gap:5px;padding:12px}.product-grid small{color:var(--muted)}.cart-line{display:grid;grid-template-columns:1fr 72px 90px 28px;gap:8px;align-items:center;padding:9px 0;border-bottom:1px solid var(--border)}.cart-line input{padding:7px}.cart-line button{padding:5px;color:var(--danger);border:0}.total{font-size:17px;text-align:right;margin:18px 0}.inline-form{display:flex;align-items:center;gap:5px}.inline-form input{width:100px;padding:7px}.inline-form select{width:130px;padding:7px}.inline-form button{padding:7px 10px}.tables-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(155px,1fr));gap:15px}.table-card{background:#fff;border:1px solid var(--border);border-radius:14px;padding:22px;color:var(--ink);display:grid;gap:8px}.table-card span,.table-card small{color:var(--muted)}.table-card.busy{border-color:#f59e0b;background:#fffbeb}@media(max-width:980px){.sidebar{position:static;width:100%;height:auto}.app{margin:0;padding:16px}.metrics,.grid-2,.pos-grid{grid-template-columns:1fr}.product-grid{grid-template-columns:repeat(2,1fr)}}
.permission-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:16px 0}.check-row{display:flex;align-items:start;gap:8px;background:#f8fafc;padding:10px;border-radius:8px}.check-row input{width:auto;margin-top:3px}.check-row small{display:block;color:var(--muted);font-weight:400}@media(max-width:980px){.permission-grid{grid-template-columns:1fr}}
.ticket{max-width:360px;margin:20px auto;font-size:13px}.ticket header{text-align:center}.ticket table td{padding:7px 0}.ticket td:last-child{text-align:right}@media print{.sidebar,.topbar,.no-print,.alert{display:none!important}.app,.guest{margin:0;padding:0}.ticket{border:0;box-shadow:none;margin:0;width:78mm}}

.nav-heading{display:block;color:#64748b;font-size:11px;text-transform:uppercase;letter-spacing:.08em;padding:13px 12px 4px}.alert.info{background:#e0f2fe;color:#075985}.alert.warning{background:#fff7ed;color:#9a3412}.wide{width:100%}.thumb{width:42px;height:42px;object-fit:cover;border-radius:8px}.table-note{display:block;color:var(--muted);margin-top:4px;max-width:250px}.product-preview img{max-width:120px;max-height:120px;border-radius:12px;border:1px solid var(--border)}textarea{resize:vertical}.product-photo{height:50px;display:flex;align-items:center;font-size:30px}.product-photo img{height:50px;width:50px;object-fit:cover;border-radius:10px}.product-grid button{align-content:start}.sale-summary{background:#f8fafc;border-radius:10px;padding:12px;margin-top:16px}.sale-summary p{display:flex;justify-content:space-between;margin:7px 0}.sale-summary .total{font-size:18px;border-top:1px solid var(--border);padding-top:9px}.cart-line.sale-line{grid-template-columns:1fr 72px 92px 105px 28px}.cart-line.sale-line small{display:block;color:var(--muted)}.purchase-line{display:grid;grid-template-columns:1fr 70px 100px 74px 105px 28px;gap:7px;align-items:center;padding:9px 0;border-bottom:1px solid var(--border)}.purchase-line input{padding:7px}.report-nav{display:flex;gap:7px;flex-wrap:wrap}.open-cashes{display:flex;gap:12px;flex-wrap:wrap}.open-cashes article{border:1px solid var(--border);border-radius:10px;padding:12px 15px;display:grid;gap:4px}.open-cashes span,.open-cashes small{color:var(--muted)}.person-icon{font-size:30px}.table-card.busy strong{font-size:18px}.bar-row{display:grid;grid-template-columns:1fr auto;gap:7px;margin:12px 0}.bar-row div{grid-column:1 / 3;height:8px;background:var(--primary);border-radius:4px}@media(max-width:980px){.cart-line.sale-line,.purchase-line{grid-template-columns:1fr 74px 90px 28px}.purchase-line b{grid-column:1 / 3}}
.nav-group{border-radius:9px;margin:2px 0}.nav-group summary{cursor:pointer;list-style:none;color:#e2e8f0;padding:10px 12px;font-size:14px;font-weight:600}.nav-group summary::-webkit-details-marker{display:none}.nav-group summary:after{content:'▾';float:right;color:#94a3b8}.nav-group:not([open]) summary:after{content:'›'}.nav-group[open]{background:rgba(30,41,59,.7);padding-bottom:5px}.nav-group a{margin-left:10px;padding:8px 12px!important;font-size:13px!important}.sidebar-legal{font-size:10px;color:#93a4bb;border-top:1px solid #1e293b;margin:14px 8px 10px;padding-top:12px;line-height:1.45}.sidebar-legal strong{color:#d8e0ee;font-size:11px}.sidebar-legal small{display:block;margin-top:4px}.inline-form{display:inline-flex}.report-actions{display:flex;gap:8px;flex-wrap:wrap}.report-sheet{background:#fff}.report-title-print{display:none}.legal-box{background:#f8fafc;border:1px solid var(--border);border-radius:10px;padding:14px;margin-bottom:18px}.legal-box strong{display:block;margin-bottom:4px}.legal-box small{color:var(--muted)}
@media print{.sidebar,.topbar,.no-print,.alert,.page-header .report-actions,.filters{display:none!important}.app{margin:0;padding:0}.report-sheet,.card{border:0;box-shadow:none;padding:0}.report-title-print{display:block;margin-bottom:18px}body{background:#fff;font-size:11px}table{font-size:11px}th,td{padding:7px 5px}.ticket{width:78mm}.page-header{margin-bottom:12px}.page-header p{display:none}}

/* Menú lateral acordeón - versión 2.2.1 */
.sidebar{width:260px;padding:24px 14px 18px;overflow:hidden}
.app{margin-left:260px}
.sidebar nav.sidebar-nav{display:block;flex:1;min-height:0;overflow-y:auto;overflow-x:hidden;padding:0 4px 6px 0;scrollbar-width:thin;scrollbar-color:#64748b transparent}
.sidebar nav.sidebar-nav::-webkit-scrollbar{width:7px}
.sidebar nav.sidebar-nav::-webkit-scrollbar-thumb{background:#64748b;border-radius:8px}
.sidebar nav.sidebar-nav::-webkit-scrollbar-track{background:transparent}
.sidebar nav a{display:block;width:100%;white-space:normal;overflow-wrap:break-word}
.sidebar nav .nav-single{margin:2px 0 5px;font-weight:500}
.nav-group{display:block;border-radius:10px;margin:3px 0;background:transparent;overflow:hidden}
.nav-group summary{display:flex;align-items:center;justify-content:space-between;gap:10px;cursor:pointer;list-style:none;color:#e2e8f0;padding:11px 12px;font-size:14px;font-weight:650;user-select:none}
.nav-group summary::-webkit-details-marker{display:none}
.nav-group summary:after{content:'+';float:none;color:#94a3b8;font-size:19px;font-weight:400;line-height:1}
.nav-group[open] summary:after{content:'−'}
.nav-group[open]{background:rgba(30,41,59,.78);padding-bottom:7px}
.nav-group[open] summary{color:#fff}
.nav-group a{display:block!important;margin:1px 7px 1px 11px!important;width:calc(100% - 18px)!important;padding:8px 11px!important;font-size:13px!important;border-radius:8px}
.sidebar nav a.active,.nav-group a.active{color:#fff;background:#2358d8;font-weight:600}
.nav-group:has(a.active){background:rgba(30,41,59,.78)}
.sidebar-legal{flex:none;margin:12px 8px 10px}
.logout{flex:none;margin-top:0}
@media(max-width:980px){.sidebar{width:100%;padding:18px 14px;overflow:visible}.sidebar nav.sidebar-nav{overflow:visible;max-height:none}.app{margin-left:0}}
/* Ticket fiscal ampliado - versión 2.3.1 */
.tax-config{box-shadow:none;margin:0;padding:16px}.ticket-detailed{max-width:385px}.ticket-detailed header strong{display:block;margin-top:10px;font-size:12px}.ticket-items th{padding:5px 0}.ticket-totals p,.ticket-row{display:flex;justify-content:space-between;margin:7px 0}.ticket-grand{font-size:17px;border-top:1px solid var(--border);padding-top:9px}.ticket-row.pending{font-weight:700}.ticket-footer{text-align:center;margin:18px 0}.ticket-actions{display:grid;gap:8px}.ticket-actions form button,.ticket-actions a,.ticket-actions button{width:100%}

/* Tratamiento tributario 2.3.1 */
.tax-note{font-size:12px;color:var(--muted)}

/* Caja rápida y reportes operativos - versión 2.4 */
.pos-counter{display:grid;grid-template-columns:minmax(620px,1.65fr) minmax(320px,.78fr);gap:20px;align-items:start}
.counter-main{min-height:calc(100vh - 130px)}.counter-toolbar{display:flex;justify-content:space-between;align-items:start;gap:18px;margin-bottom:16px}.counter-toolbar h2{margin-bottom:7px}.shortcut-note{display:block;color:var(--muted)}kbd{display:inline-block;background:#eef2ff;border:1px solid #c7d2fe;color:#3730a3;border-radius:5px;padding:2px 6px;font-size:11px;font-weight:700}.counter-total{text-align:right;min-width:185px}.counter-total span{display:block;color:var(--muted);font-size:12px;text-transform:uppercase}.counter-total strong{display:block;font-size:28px;color:var(--primary);margin-top:4px}.barcode-box{font-size:16px;margin-bottom:10px}.barcode-box input{font-size:19px;padding:14px 15px;border-width:2px}.catalog-results{display:none;margin:8px 0 16px;padding:8px;background:#f8fafc;border:1px solid var(--border);border-radius:10px}.catalog-results.visible{display:block}.compact-grid{max-height:182px;grid-template-columns:repeat(3,1fr);margin-top:0}.compact-grid button{padding:9px}.invoice-lines{height:calc(100vh - 310px);min-height:410px;border:1px solid var(--border);border-radius:10px;margin-top:16px}.invoice-table{font-size:14px}.invoice-table thead{position:sticky;top:0;background:#f8fafc;z-index:1}.invoice-table th{padding:13px 10px}.invoice-table td input{padding:7px;min-width:72px}.invoice-table .cart-empty td{text-align:center;color:var(--muted);padding:44px}.line-remove{color:var(--danger);border:0;padding:4px 8px;background:transparent;font-size:18px}.counter-payment{position:sticky;top:20px}.daily-ticket{max-width:520px;margin:0 auto;font-family:"Courier New",monospace;font-size:13px;line-height:1.45}.daily-ticket header{text-align:center;margin-bottom:16px}.daily-ticket .divider{border-top:1px dashed #1f2937;margin:13px 0}.daily-ticket p{display:flex;justify-content:space-between;margin:5px 0}.daily-ticket p.single{display:block}.daily-ticket strong.grand{font-size:17px}.report-menu{display:flex;gap:7px;flex-wrap:wrap;margin-bottom:18px}.report-menu a{font-size:13px}.report-menu a.selected{background:var(--primary);border-color:var(--primary);color:#fff}.fiscal-warning{font-size:12px;color:#92400e;background:#fffbeb;border:1px solid #fde68a;border-radius:9px;padding:11px;margin:13px 0}.rest-search-panel{background:#f8fafc;border:1px solid var(--border);border-radius:10px;padding:12px}.rest-search-panel input{margin-bottom:8px}.rest-results{display:grid;gap:6px;max-height:205px;overflow:auto}.rest-product-add{display:none;justify-content:space-between;text-align:left;padding:9px 10px}.selected-product{display:block;margin:8px 0;color:var(--primary);font-weight:600}
@media(max-width:1150px){.pos-counter{grid-template-columns:1fr}.counter-payment{position:static}.invoice-lines{height:auto;min-height:350px}}
@media print{.daily-ticket{border:0;box-shadow:none;padding:0;max-width:78mm}.report-menu,.fiscal-warning{display:none!important}}
/* Administración y continuidad - versión 2.5 */
.license-mini{display:grid;gap:3px;margin:10px 7px;padding:10px 11px;border-radius:10px;text-decoration:none;font-size:11px}.license-mini.on{background:#052e25;color:#a7f3d0;border:1px solid #065f46}.license-mini.off{background:#3f1018;color:#fecdd3;border:1px solid #9f1239}.license-mini small{color:inherit}.pill{display:inline-block;padding:5px 8px;background:#e0e7ff;border-radius:14px;font-size:12px}.activation-screen{max-width:620px;margin:30px auto;text-align:center;padding:38px}.activation-screen h1{font-size:32px}.activation-until{font-size:21px;color:var(--primary);font-weight:700}.activation-screen dl{display:grid;grid-template-columns:1fr 1fr;text-align:left;gap:10px;padding:20px;background:#f8fafc;border-radius:12px;margin:22px 0}.activation-screen dt{color:var(--muted)}.activation-screen dd{font-weight:700}.out-stock{opacity:.56;border-color:#fca5a5!important}.out-stock:after{content:'AGOTADO';display:block;color:#b91c1c;font-size:11px;font-weight:700;margin-top:6px}.stock-warning{background:#fef2f2;color:#b91c1c;border:1px solid #fecaca;padding:10px;border-radius:9px;margin-top:8px}
.invoice-table tr.selected-line{background:#eef2ff}
/* Identidad, tiquete y activación - KORELYX POS 2.5.1 */
.brand-preview{display:block;max-height:72px;max-width:190px;object-fit:contain;margin-top:10px;border:1px solid var(--border);border-radius:9px;padding:7px;background:#fff}.maker-preview{display:block;max-height:74px;max-width:250px;object-fit:contain;margin-top:10px;border-radius:9px}.maker-box{display:flex;align-items:center;gap:18px}.maker-box img{width:210px;max-height:72px;object-fit:contain}.maker-box small{display:block}.maker-license img{display:block;max-width:270px;max-height:78px;margin:0 auto 10px}.maker-license small{display:block;color:var(--muted);margin-bottom:16px}.maker-panel{display:flex;align-items:center;gap:24px}.maker-panel img{max-width:265px;max-height:74px;object-fit:contain}.maker-panel p{color:var(--muted);margin:6px 0}.ticket-logo{display:block;max-height:68px;max-width:200px;margin:0 auto 8px;object-fit:contain}.ticket-brand{font-size:12px;letter-spacing:1.5px;font-weight:700;color:var(--primary);margin:3px 0 7px}.ticket-fiscal-state{display:block;margin-top:4px;color:#9a3412;font-size:11px}.ticket-qualities{text-align:center;font-size:11px;color:#475569;font-weight:600}.ticket-items td small:first-child{color:#64748b}.ticket-footer{white-space:normal}
@media(max-width:760px){.maker-box,.maker-panel{display:block}.maker-box img,.maker-panel img{margin-bottom:12px}}
/* Restaurante móvil y corrección de recursos - KORELYX POS 2.5.3 */
.mobile-menu-toggle{display:none;border:1px solid var(--border);background:#fff;color:#0f172a;border-radius:9px;padding:8px 12px;font-size:22px;line-height:1;margin-right:12px}
.restaurant-workspace{display:grid;grid-template-columns:minmax(470px,1.35fr) minmax(330px,.85fr);gap:18px;align-items:start}
.restaurant-title h1{margin-bottom:4px}.restaurant-search-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}.restaurant-search-head h2{margin:0}.rest-auto{margin:10px 0 4px!important}.rest-error{display:block;padding:9px;color:#b91c1c;background:#fef2f2;border:1px solid #fecaca;border-radius:8px}.category-chips{display:flex;gap:7px;overflow-x:auto;padding:15px 0 11px;scrollbar-width:thin}.chip{white-space:nowrap;background:#fff;border:1px solid var(--border);border-radius:999px;padding:8px 13px;color:#334155;font-weight:600}.chip.selected{background:var(--primary);border-color:var(--primary);color:#fff}.restaurant-product-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;max-height:48vh;overflow-y:auto;padding:3px}.menu-product-card{border:1px solid var(--border);background:#fff;border-radius:12px;padding:9px;display:grid;gap:5px;text-align:left;min-height:154px;transition:border .16s,box-shadow .16s}.menu-product-card:hover,.menu-product-card.chosen{border-color:var(--primary);box-shadow:0 0 0 2px rgba(35,88,216,.14)}.menu-product-card img,.product-no-image{width:100%;height:67px;border-radius:8px;object-fit:cover;background:#eef2ff;display:flex;align-items:center;justify-content:center;font-size:28px}.menu-product-card b{font-size:13px;line-height:1.2}.menu-product-card small{color:var(--muted);font-size:11px}.menu-product-card strong{color:var(--primary);font-size:14px}.menu-product-card:disabled{cursor:not-allowed}.restaurant-add-bar{margin-top:14px;display:grid;grid-template-columns:100px 1fr auto;align-items:end;gap:9px}.restaurant-add-bar button{height:44px}.restaurant-consumption{position:sticky;top:18px}.consumption-header{display:flex;justify-content:space-between;gap:10px;align-items:center;border-bottom:1px solid var(--border);padding-bottom:13px;margin-bottom:13px}.consumption-header h2{margin:0}.rest-total{font-size:22px;color:var(--primary)}.restaurant-order-lines{display:grid;gap:8px;max-height:40vh;overflow:auto;margin-bottom:14px}.order-card{display:flex;justify-content:space-between;align-items:start;gap:10px;background:#f8fafc;border-radius:10px;padding:10px}.order-card small{display:block;color:var(--muted);margin-top:4px}.order-card .kitchen-note{color:#92400e}.empty-order{text-align:center;color:var(--muted);padding:25px 8px}.restaurant-cancel{margin-top:9px}.rest-product-result{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px;background:#fff;border:1px solid var(--border);border-radius:9px;text-align:left;width:100%}.rest-product-result span{display:grid;gap:3px}.rest-product-result small{color:var(--muted)}
@media(max-width:1040px){.restaurant-workspace{grid-template-columns:1fr}.restaurant-consumption{position:static}.restaurant-product-grid{max-height:none}}
@media(max-width:760px){body{font-size:14px}.mobile-menu-toggle{display:inline-flex;align-items:center}.topbar{position:sticky;top:0;z-index:30;background:#fff;padding:12px 14px}.sidebar{position:fixed;left:0;top:0;bottom:0;height:100vh;width:min(84vw,290px)!important;z-index:80;transform:translateX(-105%);transition:transform .2s ease;overflow:hidden!important}.menu-open .sidebar{transform:translateX(0)}.menu-open:after{content:'';position:fixed;z-index:70;inset:0;background:rgba(15,23,42,.45)}.app{margin-left:0!important;padding:14px!important}.page-header.restaurant-title{display:flex;gap:10px;align-items:start}.page-header.restaurant-title h1{font-size:23px}.restaurant-catalog,.restaurant-consumption{padding:13px}.restaurant-product-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.menu-product-card{min-height:143px;padding:8px}.restaurant-add-bar{grid-template-columns:88px 1fr}.restaurant-add-bar button{grid-column:1 / 3;height:52px;font-size:16px}.rest-search-panel input{font-size:17px;height:50px}.restaurant-bill-form button,.restaurant-cancel button{height:52px;font-size:16px}.rest-total{font-size:20px}}
/* Mejoras operativas 2.5.6 */
.sidebar nav a.active{background:linear-gradient(90deg,var(--primary),#1d4ed8);color:#fff!important;font-weight:800;box-shadow:inset 4px 0 0 #93c5fd,0 6px 14px rgba(37,99,235,.25)}
.nav-group:has(a.active){background:rgba(35,88,216,.22);border:1px solid rgba(147,197,253,.35)}
.nav-group:has(a.active)>summary{color:#fff;background:rgba(30,64,175,.55);border-radius:9px}
.force-close-box{margin-top:10px;border-top:1px dashed var(--border);padding-top:10px}.force-close-box input{font-size:12px;padding:8px}.force-close-box button{font-size:12px;padding:8px}.select-search{margin-bottom:6px;background:#f8fafc;border-width:2px}.ticket-actions{display:flex;flex-wrap:wrap;gap:8px;align-items:center}.tax-chip{display:inline-block;padding:4px 7px;border-radius:999px;background:#eef2ff;color:#1d4ed8;font-size:11px;font-weight:700}
/* Restaurante Pro 1.0.5 - comandas separadas, cliente y pre-cuenta */
.inline-form{display:inline-flex;margin:0}.primary-like{background:var(--primary)!important;color:#fff!important;border-color:var(--primary)!important}.restaurant-top-actions{display:flex;flex-wrap:wrap;gap:8px;align-items:center;justify-content:flex-end}.rest-pro-title{align-items:flex-start}.rest-pro-workspace{grid-template-columns:minmax(560px,1.45fr) minmax(380px,.85fr)}.rest-pro-catalog,.rest-pro-consumption{border:1px solid #dbe5f3;box-shadow:0 10px 26px rgba(15,23,42,.06)}.dest-badge{display:inline-flex!important;align-items:center;gap:4px;width:max-content;padding:3px 7px;border-radius:999px;font-size:10px!important;font-weight:800;text-transform:uppercase;letter-spacing:.02em}.dest-cocina{background:#fff7ed!important;color:#9a3412!important}.dest-barra{background:#ecfeff!important;color:#155e75!important}.dest-cafeteria{background:#fef3c7!important;color:#92400e!important}.dest-ninguno{background:#f1f5f9!important;color:#475569!important}.restaurant-mini-status{display:flex;flex-wrap:wrap;gap:6px;margin:-3px 0 12px}.status-pill{display:inline-flex;align-items:center;border-radius:999px;background:#eef2ff;color:#1d4ed8;font-size:11px;font-weight:800;padding:4px 8px}.status-pendiente{background:#f1f5f9!important;color:#475569!important}.status-enviado{background:#dbeafe!important;color:#1d4ed8!important}.status-listo{background:#dcfce7!important;color:#047857!important}.status-entregado{background:#e0e7ff!important;color:#3730a3!important}.status-cancelado{background:#fee2e2!important;color:#b91c1c!important}.rest-line{border-left:4px solid transparent}.rest-line.state-pendiente{border-left-color:#94a3b8}.rest-line.state-enviado{border-left-color:#2563eb}.rest-line.state-listo{border-left-color:#16a34a}.line-side{display:grid;gap:7px;justify-items:end}.small-btn{font-size:12px;padding:7px 10px;border-radius:8px}.quick-customer{border:1px dashed var(--border);border-radius:10px;padding:10px;background:#f8fafc}.quick-customer summary{font-weight:800;cursor:pointer}.compact-customer{margin-top:10px}.command-sent-card .grid-3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.command-sent-box{padding:16px;border:1px solid var(--border);border-radius:14px;background:#f8fafc}.kitchen-board{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:16px}.kitchen-ticket{background:#fff;border:1px solid var(--border);border-radius:18px;box-shadow:0 12px 24px rgba(15,23,42,.07);overflow:hidden}.kitchen-ticket header{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;padding:15px 16px;background:linear-gradient(135deg,#eff6ff,#f8fafc);border-bottom:1px solid var(--border)}.kitchen-ticket header h2{margin:0;font-size:25px}.kitchen-ticket header strong{font-size:20px;color:var(--primary)}.kitchen-lines{display:grid;gap:8px;padding:12px}.kitchen-line{display:flex;justify-content:space-between;gap:10px;padding:12px;border-radius:12px;background:#f8fafc}.kitchen-line b{font-size:16px}.kitchen-line small{display:block;color:var(--muted);margin-top:4px}.kitchen-line.status-listo{background:#ecfdf5;border:1px solid #bbf7d0}.command-print,.prebill-print{max-width:80mm;margin:0 auto;font-family:"Courier New",monospace;background:#fff;color:#111;padding:8px}.command-print header,.prebill-print header{text-align:center}.command-print h1,.prebill-print h1{font-size:20px;margin:0 0 6px}.command-print p,.prebill-print p{margin:3px 0}.divider{border-top:1px dashed #111;margin:10px 0}.command-print-line{padding:8px 0;border-bottom:1px dashed #999}.command-print-line strong{display:block;font-size:16px}.command-print-line small{display:block;font-size:13px;margin-top:4px}.prebill-line,.prebill-total{display:flex;justify-content:space-between;gap:8px}.prebill-total{font-size:18px}.prebill-print footer,.command-print footer{text-align:center;font-size:11px;margin-top:10px}.barcode-status{display:block;margin-top:5px}
@media(max-width:1040px){.rest-pro-workspace{grid-template-columns:1fr}.restaurant-top-actions{justify-content:flex-start}.command-sent-card .grid-3{grid-template-columns:1fr}}
@media print{body{background:#fff!important}.sidebar,.topbar,.page-header,.app>.alert,.no-print{display:none!important}.app{margin:0!important;padding:0!important}.card{box-shadow:none;border:0}.command-print,.prebill-print{max-width:78mm;width:78mm}.command-print *,.prebill-print *{color:#000!important}}
/* Restaurante Pro 1.0.6 - estaciones, parrilla y alerta de mesa */
.station-chips{display:flex;gap:7px;overflow-x:auto;padding:13px 0 4px;scrollbar-width:thin}.station-chip{font-weight:800}.dest-parrilla{background:#fee2e2!important;color:#991b1b!important}.command-panel-action{margin:0 0 12px}.command-main-btn{font-weight:900}.table-card{position:relative}.table-alert-dot,.table-ready-dot{position:absolute;right:13px;top:13px;width:13px;height:13px;border-radius:999px;box-shadow:0 0 0 3px rgba(255,255,255,.9)}.table-alert-dot{background:#dc2626;animation:pulse-alert 1.2s infinite}.table-ready-dot{right:31px;background:#16a34a}.table-alert-text{color:#b91c1c!important;font-weight:800}.table-ready-text{color:#047857!important;font-weight:800}@keyframes pulse-alert{0%{box-shadow:0 0 0 0 rgba(220,38,38,.38)}70%{box-shadow:0 0 0 8px rgba(220,38,38,0)}100%{box-shadow:0 0 0 0 rgba(220,38,38,0)}}.print-note{margin-top:14px}.command-sent-box.dest-parrilla{border-color:#fecaca;background:#fff1f2}.command-sent-box.dest-cocina{border-color:#fed7aa;background:#fff7ed}.command-sent-box.dest-barra{border-color:#a5f3fc;background:#ecfeff}.command-sent-box.dest-cafeteria{border-color:#fde68a;background:#fffbeb}.rest-tables-grid .table-card.has-alert{border-color:#f87171;background:#fff7f7}.rest-tables-grid .table-card.has-ready{border-color:#86efac}.wide{width:100%}
/* Restaurante Pro 1.0.7 - semáforo de mesas y servicio voluntario */
.tables-legend{display:flex;flex-wrap:wrap;gap:14px;align-items:center;padding:12px 16px;margin-bottom:16px}.tables-legend span{display:inline-flex;align-items:center;gap:7px;font-size:13px;font-weight:800;color:#334155}.legend-dot{width:12px;height:12px;border-radius:999px;display:inline-block}.legend-dot.red{background:#dc2626}.legend-dot.orange{background:#f97316}.legend-dot.green{background:#16a34a}.legend-dot.blue{background:#2563eb}.rest-tables-pro107 .table-card{min-height:190px;border-width:2px;overflow:hidden}.rest-table-state:before{content:'';position:absolute;left:0;top:0;bottom:0;width:7px}.rest-table-state.state-free{background:#fff;border-color:#dbe5f3}.rest-table-state.state-free:before{background:#cbd5e1}.rest-table-state.state-active{background:linear-gradient(135deg,#eff6ff,#fff);border-color:#60a5fa}.rest-table-state.state-active:before{background:#2563eb}.rest-table-state.state-needs-send{background:linear-gradient(135deg,#fff1f2,#fff7ed);border-color:#ef4444;box-shadow:0 12px 26px rgba(220,38,38,.13)}.rest-table-state.state-needs-send:before{background:#dc2626}.rest-table-state.state-preparing{background:linear-gradient(135deg,#fff7ed,#fffbeb);border-color:#fb923c;box-shadow:0 12px 26px rgba(249,115,22,.13)}.rest-table-state.state-preparing:before{background:#f97316}.rest-table-state.state-ready{background:linear-gradient(135deg,#ecfdf5,#f0fdf4);border-color:#22c55e;box-shadow:0 12px 26px rgba(22,163,74,.13)}.rest-table-state.state-ready:before{background:#16a34a}.table-status-badge{position:absolute;right:12px;top:11px;border-radius:999px;padding:4px 9px;font-size:11px;font-weight:900;color:#fff}.table-status-badge.state-needs-send{background:#dc2626}.table-status-badge.state-preparing{background:#f97316}.table-status-badge.state-ready{background:#16a34a}.table-status-badge.state-active{background:#2563eb}.table-prep-dot{position:absolute;right:51px;top:43px;width:13px;height:13px;border-radius:999px;background:#f97316;box-shadow:0 0 0 3px rgba(255,255,255,.9)}.rest-tables-pro107 .table-alert-dot{right:13px;top:43px}.rest-tables-pro107 .table-ready-dot{right:32px;top:43px}.table-state-counts{display:grid;gap:3px}.table-preparing-text{color:#c2410c!important;font-weight:900}.table-active-text{color:#2563eb!important;font-weight:900}.service-box{border:1px solid #dbeafe;background:linear-gradient(135deg,#f8fbff,#eef6ff);border-radius:14px;padding:14px;display:grid;gap:10px}.service-box h3{margin:0}.service-box p{margin:0;color:#475569;font-size:12px}.service-options{display:grid;gap:7px}.service-choice{display:flex;align-items:center;gap:8px;border:1px solid #dbe5f3;background:#fff;border-radius:10px;padding:9px;font-weight:800}.service-choice input{width:auto}.compact-service{grid-template-columns:1fr 1fr;gap:10px}.service-summary{background:#fff;border:1px solid #dbe5f3;border-radius:12px;padding:10px;display:grid;gap:6px}.service-summary p{display:flex;justify-content:space-between;gap:10px;margin:0!important;color:#1e293b}.service-pay-total{border-top:1px dashed #cbd5e1;padding-top:7px;font-size:16px}.service-pay-total strong{color:#2358d8}.rest-bill-pro button.primary{height:46px;font-weight:900}.state-pendiente .status-pill,.status-pendiente{background:#fee2e2!important;color:#b91c1c!important}.rest-line.state-pendiente{border-left-color:#dc2626;background:#fff7f7}.rest-line.state-enviado{border-left-color:#f97316;background:#fff7ed}.rest-line.state-listo{border-left-color:#16a34a;background:#f0fdf4}.status-enviado{background:#ffedd5!important;color:#c2410c!important}.rest-filtered-out{display:none!important}
@media(max-width:760px){.compact-service{grid-template-columns:1fr}.tables-legend{gap:8px}.table-status-badge{position:static;width:max-content}.rest-tables-pro107 .table-alert-dot,.rest-tables-pro107 .table-ready-dot,.table-prep-dot{top:14px}}

/* Restaurante Pro 1.0.8 - unión de mesas, cancelación controlada y modo restaurante */
.rest-merge-panel{display:flex;justify-content:space-between;gap:16px;align-items:flex-start;margin-bottom:16px;border-left:6px solid #2563eb;background:linear-gradient(135deg,#eff6ff,#ffffff)}
.rest-merge-panel h2{margin:0 0 4px}.linked-tables{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}.table-merge-chip{display:inline-flex;align-items:center;gap:6px;padding:7px 10px;border-radius:999px;background:#e0f2fe;color:#075985;font-weight:800;font-size:12px}.table-merge-chip.main{background:#dcfce7;color:#166534}.merge-details{min-width:min(360px,100%)}.merge-details summary{cursor:pointer;font-weight:900;color:#1d4ed8}.merge-table-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:8px;margin:10px 0}.merge-table-list label{background:#f8fafc;border:1px solid #e2e8f0;border-radius:12px;padding:9px 10px;font-weight:800}.joined-table-label{display:inline-block;margin-top:4px;padding:4px 8px;border-radius:999px;background:#fef3c7;color:#92400e;font-style:normal;font-size:11px;font-weight:900}.restaurant-cancel-box{margin-top:16px;padding:14px;border-radius:16px;background:#fff7ed;border:1px solid #fed7aa}.restaurant-cancel-box h3{margin-top:0;color:#9a3412}.restaurant-cancel textarea{width:100%;resize:vertical}.danger-btn{background:#b91c1c!important;color:#fff!important;border-color:#b91c1c!important}.danger-btn:hover{filter:brightness(.95)}
body.restaurant-only .sidebar .brand{background:linear-gradient(135deg,#7c2d12,#dc2626,#f59e0b);color:#fff}
body.restaurant-only .nav-group[open]>summary{color:#f59e0b}
@media(max-width:900px){.rest-merge-panel{display:block}.merge-details{margin-top:12px}}

/* KORELYX Restaurante Pro 1.0.8.5 - Fase 1 UX Tablet / Smartphone
   Mejora visual solamente: menú lateral ocultable, consumo lateral deslizable,
   barra inferior fija y botones táctiles. No cambia ventas, inventario ni caja. */
:root{--rest-bottom-bar-h:72px;--rest-mobile-shadow:0 18px 48px rgba(15,23,42,.22)}
.mobile-menu-toggle{display:inline-flex;align-items:center;justify-content:center;min-width:42px;height:42px;border-radius:14px;font-size:20px;font-weight:900;background:#fff;border:1px solid #dbe5f3;box-shadow:0 8px 20px rgba(15,23,42,.06)}
.topbar{position:sticky;top:0;z-index:55;background:rgba(244,246,250,.92);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
body.sidebar-collapsed .sidebar{transform:translateX(-100%)}
body.sidebar-collapsed .app{margin-left:0}
.sidebar{transition:transform .22s ease, box-shadow .22s ease}.app{transition:margin-left .22s ease}
body.sidebar-collapsed .mobile-menu-toggle{background:#2358d8;color:#fff;border-color:#2358d8}

.restaurant-title.rest-pro-title{position:sticky;top:62px;z-index:42;background:rgba(244,246,250,.94);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);padding:10px 0 12px;margin-bottom:12px;border-bottom:1px solid rgba(203,213,225,.65)}
.restaurant-title.rest-pro-title h1{font-size:clamp(24px,3vw,34px);line-height:1;margin:0}.restaurant-title.rest-pro-title p{font-size:13px;margin-top:6px}.restaurant-top-actions{gap:8px}.restaurant-top-actions .button,.restaurant-top-actions button{min-height:42px;border-radius:13px;font-weight:800;white-space:nowrap}.restaurant-top-actions{overflow-x:auto;padding-bottom:3px;scrollbar-width:thin}.command-main-btn{box-shadow:0 10px 22px rgba(37,99,235,.18)}

.rest-ux-toggle-consumption{display:none}.rest-ux-consumption-close{display:none}.rest-ux-floating{display:none}.rest-ux-bottom-bar{display:none}.rest-ux-backdrop{display:none}
.rest-pro-catalog{min-width:0}.rest-pro-consumption{min-width:0}.restaurant-product-grid{scrollbar-width:thin}.menu-product-card{touch-action:manipulation}.menu-product-card b{font-size:clamp(12px,1.9vw,14px)}.menu-product-card img,.product-no-image{min-height:62px}.category-chips{gap:8px}.chip{min-height:38px;display:inline-flex;align-items:center;justify-content:center;touch-action:manipulation}
.rest-search-panel input{min-height:48px}.restaurant-add-bar input{min-height:46px}.restaurant-add-bar button{border-radius:14px;font-weight:900}.restaurant-cash-actions a,.restaurant-cash-actions button{min-height:46px;border-radius:14px;font-weight:900}.restaurant-mini-status{gap:8px}.status-pill{font-size:12px;padding:5px 9px}.order-card{border-radius:14px}.service-box{border-radius:18px}.service-choice{min-height:44px}.service-choice input{width:18px;height:18px}

@media(min-width:1101px){
  body:not(.sidebar-collapsed) .mobile-menu-toggle{opacity:.92}
  .rest-pro-consumption{max-height:calc(100vh - 94px);overflow:auto}
}

@media(max-width:1180px){
  body{padding-bottom:var(--rest-bottom-bar-h)}
  .sidebar{position:fixed!important;left:0!important;top:0!important;bottom:0!important;height:100vh!important;width:min(86vw,315px)!important;z-index:120!important;transform:translateX(-105%);overflow:hidden!important;box-shadow:none}
  body.menu-open .sidebar{transform:translateX(0);box-shadow:var(--rest-mobile-shadow)}
  body.menu-open:after{content:'';position:fixed;z-index:105;inset:0;background:rgba(15,23,42,.48);backdrop-filter:blur(1px)}
  .app{margin-left:0!important;padding:14px 16px calc(var(--rest-bottom-bar-h) + 18px)!important}
  .topbar{height:56px;margin-bottom:14px;padding:8px 12px;border-radius:0 0 18px 18px;box-shadow:0 8px 22px rgba(15,23,42,.05)}
  .topbar{justify-content:space-between}.topbar strong{margin-left:auto}.topbar small{display:none}
  .restaurant-title.rest-pro-title{top:56px;display:grid;grid-template-columns:1fr;gap:10px;padding:10px 0;margin-bottom:10px}.restaurant-title.rest-pro-title .actions{grid-column:auto;margin:0}.restaurant-top-actions{justify-content:flex-start;flex-wrap:nowrap}.restaurant-top-actions .button,.restaurant-top-actions button{font-size:13px;padding:9px 11px}.restaurant-top-actions a[href*="comandas?area"]{display:none}.restaurant-top-actions a[href$="/restaurante/mesas"]{display:none}
  .rest-pro-workspace{display:block!important}.rest-pro-catalog{padding:14px!important;border-radius:18px}.restaurant-search-head{margin-bottom:8px}.restaurant-search-head h2{font-size:18px}.restaurant-product-grid{grid-template-columns:repeat(3,minmax(0,1fr));max-height:none;overflow:visible;gap:10px}.menu-product-card{min-height:142px;border-radius:16px;padding:10px}.menu-product-card img,.product-no-image{height:62px}.restaurant-add-bar{position:sticky;bottom:calc(var(--rest-bottom-bar-h) + 8px);z-index:35;background:rgba(255,255,255,.96);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border:1px solid #dbeafe;border-radius:18px;padding:10px;box-shadow:0 14px 35px rgba(15,23,42,.12)}
  .rest-collapsible-action{margin-bottom:10px!important;border-radius:18px!important}.rest-collapsible-summary{padding:12px 14px}.rest-collapsible-summary small{display:none}
  .rest-pro-consumption{position:fixed!important;right:0;top:0;bottom:0;width:min(94vw,440px);z-index:145;margin:0!important;border-radius:22px 0 0 22px!important;transform:translateX(108%);transition:transform .24s ease;overflow:auto!important;box-shadow:var(--rest-mobile-shadow);padding:16px!important;background:#fff}.rest-pro-consumption.is-open,body.rest-consumption-open .rest-pro-consumption{transform:translateX(0)}
  .rest-ux-backdrop{display:none;position:fixed;z-index:135;inset:0;background:rgba(15,23,42,.48);backdrop-filter:blur(1px)}body.rest-consumption-open .rest-ux-backdrop{display:block}
  .rest-ux-consumption-close{display:inline-flex;position:sticky;top:0;z-index:5;margin:0 0 10px auto;width:100%;height:44px;border:0;border-radius:14px;background:#0f172a;color:#fff;font-weight:900}.rest-ux-toggle-consumption{display:inline-flex}.rest-ux-floating{display:flex;position:fixed;right:14px;bottom:calc(var(--rest-bottom-bar-h) + 14px);z-index:75;gap:8px;align-items:center;border:0;border-radius:999px;background:#0f172a;color:#fff;box-shadow:0 14px 32px rgba(15,23,42,.28);padding:12px 14px;font-weight:900}.rest-ux-floating small{display:block;color:#cbd5e1;font-weight:700}.rest-ux-floating .amount{color:#fff;font-size:16px}
  .rest-ux-bottom-bar{display:grid;grid-template-columns:1fr auto auto auto;gap:8px;align-items:center;position:fixed;left:0;right:0;bottom:0;z-index:90;min-height:var(--rest-bottom-bar-h);background:rgba(255,255,255,.96);backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px);border-top:1px solid #dbe5f3;box-shadow:0 -12px 35px rgba(15,23,42,.14);padding:10px 12px}.rest-ux-bottom-info{display:grid;gap:2px;min-width:0}.rest-ux-bottom-info b{font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.rest-ux-bottom-info small{font-size:12px;color:#64748b}.rest-ux-bottom-bar button,.rest-ux-bottom-bar a{min-height:44px;border-radius:14px;padding:9px 12px;font-weight:900}.rest-ux-bottom-bar .primary{box-shadow:0 10px 22px rgba(37,99,235,.2)}
}

@media(max-width:820px){
  .app{padding:12px 12px calc(var(--rest-bottom-bar-h) + 18px)!important}.restaurant-title.rest-pro-title h1{font-size:25px}.restaurant-title.rest-pro-title p{font-size:12px}.restaurant-top-actions .button,.restaurant-top-actions button{min-height:40px;font-size:12px}
  .restaurant-product-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.menu-product-card{min-height:146px}.restaurant-add-bar{grid-template-columns:92px 1fr!important;gap:8px}.restaurant-add-bar button{grid-column:1 / 3;height:50px}.category-chips{padding:10px 0 8px}.chip{padding:8px 12px;font-size:13px}.card{padding:15px}.rest-search-panel input{font-size:16px}.rest-pro-consumption{width:min(96vw,430px)}.service-options{grid-template-columns:1fr}.compact-service{grid-template-columns:1fr!important}
}

@media(max-width:520px){
  :root{--rest-bottom-bar-h:78px}.restaurant-title.rest-pro-title{top:54px}.restaurant-title.rest-pro-title p{display:none}.restaurant-top-actions{display:none}.restaurant-product-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.menu-product-card{min-height:135px;padding:8px}.menu-product-card img,.product-no-image{height:54px}.menu-product-card small:last-child{display:none}.dest-badge{font-size:9px!important}.restaurant-add-bar{bottom:calc(var(--rest-bottom-bar-h) + 6px);grid-template-columns:78px 1fr!important}.restaurant-add-bar input{min-height:42px}.rest-auto{font-size:12px}.restaurant-catalog .alert.info{font-size:13px;padding:10px}.rest-ux-bottom-bar{grid-template-columns:1fr repeat(3,44px);gap:7px;padding:9px}.rest-ux-bottom-bar button,.rest-ux-bottom-bar a{width:44px;min-width:44px;padding:0;font-size:0}.rest-ux-bottom-bar button::first-letter,.rest-ux-bottom-bar a::first-letter{font-size:18px}.rest-ux-bottom-bar .rest-ux-text{display:none}.rest-ux-bottom-info b{font-size:14px}.rest-ux-bottom-info small{font-size:11px}.rest-ux-floating{display:none}.rest-pro-consumption{width:100vw;border-radius:18px 18px 0 0!important;top:7vh}.consumption-header{position:sticky;top:0;background:#fff;z-index:4}.order-card{display:grid;grid-template-columns:1fr;gap:7px}.line-side{justify-items:start}.restaurant-cancel-box{padding:12px}.service-box{padding:12px}
}


/* KORELYX Restaurante Pro 1.0.8.6.1 - Compact UX for tablet/celular
   Ajuste visual: tarjetas y mesas más compactas, menos altura, mejor tactilidad. */
@media(max-width:1180px){
  .rest-pro-catalog{padding:12px!important}
  .restaurant-search-head h2{font-size:17px!important}
  .restaurant-search-head{margin-bottom:6px!important}
  .restaurant-product-grid{grid-template-columns:repeat(auto-fit,minmax(138px,1fr))!important;gap:8px!important}
  .menu-product-card{min-height:120px!important;padding:8px!important;gap:4px!important;border-radius:14px!important}
  .menu-product-card img,.product-no-image{height:50px!important;min-height:50px!important;border-radius:10px!important}
  .menu-product-card b{font-size:12px!important;line-height:1.12!important}
  .menu-product-card strong{font-size:13px!important}
  .menu-product-card small{font-size:10px!important;line-height:1.12!important}
  .category-chips{padding:8px 0 6px!important;gap:6px!important}
  .chip{min-height:34px!important;padding:7px 11px!important;font-size:12px!important}
  .restaurant-add-bar{padding:8px!important;gap:8px!important;bottom:calc(var(--rest-bottom-bar-h) + 6px)!important}
  .restaurant-add-bar input,.restaurant-add-bar textarea,.restaurant-add-bar select{min-height:42px!important;font-size:14px!important}
  .restaurant-add-bar button{height:44px!important;font-size:14px!important}
}
@media(max-width:820px){
  .restaurant-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
  .menu-product-card{min-height:112px!important;padding:8px!important}
  .menu-product-card img,.product-no-image{height:44px!important;min-height:44px!important}
  .restaurant-add-bar{grid-template-columns:84px 1fr!important}
}
@media(max-width:520px){
  .menu-product-card{min-height:106px!important;padding:7px!important}
  .menu-product-card img,.product-no-image{height:40px!important;min-height:40px!important}
  .restaurant-product-grid{gap:7px!important}
  .chip{padding:6px 10px!important;font-size:11px!important}
  .restaurant-add-bar{grid-template-columns:74px 1fr!important}
  .restaurant-add-bar button{height:42px!important}
}


/* KORELYX Restaurante Pro 1.0.8.7 - Fase 3 Roles + Flujo final
   Ajuste visual/controlado: guía de rol, acciones más claras y vista app por perfil. */
.rest-role-guide{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 12px;padding:12px 14px;border-radius:18px;border:1px solid #dbe5f3;background:#fff;box-shadow:0 10px 24px rgba(15,23,42,.06)}
.rest-role-guide div{display:grid;gap:2px}.rest-role-guide strong{font-size:15px}.rest-role-guide small{color:#64748b;font-size:12px;line-height:1.25}.rest-role-guide-mesero{border-color:#fde68a;background:linear-gradient(135deg,#fffbeb,#fff)}.rest-role-guide-cajero{border-color:#bfdbfe;background:linear-gradient(135deg,#eff6ff,#fff)}
.rest-role-tabs.rest-role-mesero .rest-tab-btn[data-rest-tab="cobro"]{background:#fffbeb;border-color:#fde68a;color:#78350f}.rest-role-tabs.rest-role-cajero .rest-tab-btn[data-rest-tab="cobro"]{background:#eff6ff;border-color:#bfdbfe;color:#1d4ed8}.rest-role-tabs .rest-tab-btn.is-active[data-rest-tab="cobro"]{background:linear-gradient(135deg,#2563eb,#0ea5e9)!important;color:#fff!important;border-color:#2563eb!important}
.rest-bill-pro{border:1px solid #bfdbfe;border-radius:18px;padding:14px;background:linear-gradient(135deg,#f8fbff,#ffffff)}.rest-bill-pro h3:first-of-type{margin-top:0}.waiter-no-bill{box-shadow:0 12px 26px rgba(245,158,11,.12)}.waiter-no-bill h3{margin-top:0}.restaurant-cash-actions .button{min-height:46px;font-weight:900;border-radius:14px}
@media(max-width:1180px){
  .rest-role-guide{position:sticky;top:118px;z-index:68;margin-bottom:10px;padding:10px 12px}.rest-role-guide small{display:none}.rest-role-guide .button{min-height:40px;border-radius:13px;white-space:nowrap}.rest-role-guide strong{font-size:14px}
  .rest-pro-workspace.rest-role-mesero[data-rest-active-tab="cobro"] .restaurant-mini-status{display:none!important}
  .rest-pro-workspace.rest-role-cajero[data-rest-active-tab="cobro"] .restaurant-mini-status{display:flex!important}
}
@media(max-width:640px){
  .rest-role-guide{top:104px;border-radius:14px}.rest-role-guide{gap:8px}.rest-role-guide .button{padding:8px 10px;font-size:12px}.rest-role-guide strong{font-size:13px}
  .rest-tab-btn[data-rest-tab="cobro"] b{font-size:10px!important}
}


/* KORELYX Restaurante Pro 1.0.8.8 - Actualización viva + UX táctil compacta */
.kx-live-sound{position:fixed;right:16px;bottom:92px;z-index:180;border:0;border-radius:999px;background:#111827;color:#fff;font-weight:900;padding:10px 13px;box-shadow:0 14px 30px rgba(15,23,42,.26)}
.kx-live-sound.is-on{background:#047857}.kx-live-sound small{display:block;font-weight:700;color:#d1fae5;font-size:10px}.rest-scan-toggle{border:1px solid #dbe5f3;background:#eef2ff;color:#1d4ed8;font-weight:900;cursor:pointer}.rest-scan-panel{transition:max-height .22s ease,opacity .22s ease,margin .22s ease}
@media(max-width:1180px){
  .rest-scan-panel{display:none}.rest-scan-panel.is-open,body.rest-scanner-open .rest-scan-panel{display:block}.restaurant-search-head{gap:10px}.rest-scan-toggle{min-height:36px;border-radius:999px;padding:7px 12px;white-space:nowrap}.restaurant-product-grid{grid-template-columns:repeat(auto-fit,minmax(132px,1fr))!important;gap:8px!important}.menu-product-card{min-height:116px!important;padding:8px!important;gap:4px!important}.menu-product-card img,.product-no-image{height:46px!important;min-height:46px!important}.menu-product-card b{font-size:12px!important;line-height:1.1!important}.menu-product-card small{font-size:10px!important;line-height:1.1!important}.menu-product-card strong{font-size:13px!important}.category-chips{padding:8px 0 6px!important}.chip{min-height:33px!important;padding:7px 10px!important;font-size:12px!important}.restaurant-add-bar{padding:8px!important;gap:8px!important}.restaurant-add-bar input{min-height:42px!important}.restaurant-add-bar button{height:44px!important}
}
@media(max-width:760px){
  .restaurant-product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}.menu-product-card{min-height:104px!important}.menu-product-card img,.product-no-image{height:38px!important;min-height:38px!important}.dest-badge{font-size:9px!important;padding:2px 6px!important}.restaurant-add-bar{grid-template-columns:74px 1fr!important}.restaurant-add-bar button{grid-column:1 / 3!important}.kx-live-sound{right:10px;bottom:88px;padding:9px 11px;font-size:12px}
}
/* Mesas compactas */
@media(max-width:1180px){.rest-tables-pro1082{grid-template-columns:repeat(auto-fit,minmax(132px,1fr))!important;gap:10px!important}.rest-tables-pro1082 .rest-table-state{min-height:138px!important;padding:14px 12px!important;gap:5px!important}.rest-tables-pro1082 .person-icon{font-size:22px!important}.table-status-badge-pro{font-size:9px!important;padding:4px 7px!important;max-width:82px!important;line-height:1.05!important}.table-state-counts-pro small{font-size:11px!important}.rest-tables-pro1082 .rest-table-state strong{font-size:14px!important}.tables-legend-pro{padding:9px 11px!important;gap:9px!important}.tables-legend-pro span{font-size:11px!important}}
@media(max-width:520px){.rest-tables-pro1082{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}.rest-tables-pro1082 .rest-table-state{min-height:124px!important;padding:11px 9px!important}.rest-tables-pro1082 .rest-table-state b{font-size:14px!important}.rest-tables-pro1082 .rest-table-state small{font-size:10px!important}}

/* KORELYX Restaurante Pro 1.0.8.8.1 - Selección táctil / despacho rápido */
.kx-touch-order-backdrop{display:none;position:fixed;inset:0;z-index:190;background:rgba(15,23,42,.48);backdrop-filter:blur(2px)}
.kx-touch-order-sheet{display:none;position:fixed;left:50%;bottom:14px;z-index:200;transform:translateX(-50%);width:min(94vw,520px);background:#fff;border:1px solid #dbe5f3;border-radius:24px;box-shadow:0 24px 70px rgba(15,23,42,.28);padding:18px;color:#18212f}
.kx-touch-order-sheet.is-open,.kx-touch-order-backdrop.is-open{display:block}
.kx-touch-order-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:12px}
.kx-touch-order-title{display:grid;gap:3px}.kx-touch-order-title strong{font-size:19px;line-height:1.15}.kx-touch-order-title small{color:#637083;font-weight:800}.kx-touch-order-close{border:0;background:#f1f5f9;width:38px;height:38px;border-radius:999px;font-size:20px;font-weight:900;color:#334155;padding:0}
.kx-touch-order-fields{display:grid;grid-template-columns:100px 1fr;gap:10px;margin:12px 0}.kx-touch-order-fields label{font-weight:900;color:#334155}.kx-touch-order-fields input{min-height:52px;font-size:17px;border-radius:14px}.kx-touch-order-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:12px}.kx-touch-order-actions button{min-height:52px;border-radius:16px;font-size:16px;font-weight:900}.kx-touch-order-hint{background:#eff6ff;color:#075985;padding:10px 12px;border-radius:14px;font-size:13px;font-weight:700}.kx-touch-selected-card{outline:3px solid rgba(37,99,235,.35)!important;box-shadow:0 0 0 5px rgba(37,99,235,.12)!important}
@media(min-width:1181px){.kx-touch-order-sheet,.kx-touch-order-backdrop{display:none!important}}
@media(max-width:520px){.kx-touch-order-sheet{left:8px;right:8px;bottom:8px;width:auto;transform:none;border-radius:20px;padding:14px}.kx-touch-order-fields{grid-template-columns:82px 1fr}.kx-touch-order-title strong{font-size:17px}.kx-touch-order-actions button{font-size:14px}}

/* KORELYX POS 1.1.0 - compras con lote y cierre de caja controlado */
.purchase-line-lote{grid-template-columns:1fr 74px 98px 76px 108px 30px}
.purchase-lote-box{grid-column:1 / -1;display:grid;grid-template-columns:1fr 1fr;gap:8px;background:#f8fafc;border:1px dashed #cbd5e1;border-radius:10px;padding:9px;margin-top:4px}
.purchase-lote-box small{grid-column:1 / -1}.table-preparing-text-pro{color:#c2410c!important;font-weight:900!important}.table-active-text-pro{color:#2563eb!important;font-weight:900!important}
@media(max-width:760px){.purchase-line-lote{grid-template-columns:1fr 72px 30px}.purchase-line-lote input[title="Costo sin IVA"],.purchase-line-lote input[title="IVA compra %"],.purchase-line-lote span{grid-column:auto}.purchase-lote-box{grid-template-columns:1fr}}


/* KORELYX POS 1.1.0.1 - lotes visibles en compras */
.purchase-lote-guide{background:#fff7ed;border:1px solid #fed7aa;color:#9a3412;border-radius:12px;padding:11px 13px;font-size:13px;line-height:1.35}
.purchase-lote-box-visible{grid-column:1 / -1;display:grid!important;grid-template-columns:1fr 1fr;gap:9px;background:#f8fafc;border:1px dashed #94a3b8;border-radius:12px;padding:11px;margin-top:6px}
.purchase-lote-box-visible.required-lote{background:#fff7ed;border-color:#fb923c}
.purchase-lote-box-visible small{grid-column:1 / -1;font-weight:800}.purchase-lote-required{color:#c2410c!important}
.purchase-lote-box-visible label{display:grid;gap:5px;font-size:12px;font-weight:900;color:#334155}.purchase-lote-box-visible input{min-height:42px;background:#fff}
@media(max-width:760px){.purchase-lote-box-visible{grid-template-columns:1fr}.purchase-lote-guide{font-size:12px}}
