/* Demo interactiva POS InsertIT - Estilos */
.demo-shell {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 64px);
}
.demo-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 10px 16px;
    background: rgba(245,158,11,0.12);
    border-bottom: 1px solid rgba(245,158,11,0.2);
    font-size: 0.82rem;
    color: var(--lv2-warning);
    flex-wrap: wrap;
}
.demo-banner a {
    color: var(--lv2-accent-2);
    font-weight: 600;
    text-decoration: none;
}
.demo-banner a:hover { text-decoration: underline; }
.demo-reset {
    padding: 4px 12px;
    background: rgba(239,68,68,0.15);
    border: 1px solid rgba(239,68,68,0.3);
    border-radius: 14px;
    color: var(--lv2-danger);
    font-size: 0.75rem;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s;
}
.demo-reset:hover { background: rgba(239,68,68,0.25); }

.demo-workspace {
    display: flex;
    flex: 1;
    overflow: hidden;
}
.demo-sidebar {
    width: 180px;
    background: rgba(255,255,255,0.02);
    border-right: 1px solid rgba(255,255,255,0.06);
    display: flex;
    flex-direction: column;
    padding: 12px 8px;
    gap: 4px;
}
.demo-sidebar button {
    padding: 10px 14px;
    border: none;
    border-radius: var(--lv2-radius-sm);
    background: transparent;
    color: var(--lv2-muted);
    cursor: pointer;
    text-align: left;
    font-size: 0.85rem;
    font-weight: 500;
    transition: background 0.2s, color 0.2s;
    font-family: inherit;
}
.demo-sidebar button:hover { background: var(--lv2-surface); color: var(--lv2-text); }
.demo-sidebar button.is-active { background: rgba(14,165,233,0.15); color: var(--lv2-accent-2); font-weight: 700; }

.demo-content {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.demo-module { display: none; }
.demo-module.is-active { display: block; }

/* Module: Venta */
.demo-sale-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 20px;
    height: 100%;
}
.demo-catalog {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    align-content: start;
}
.demo-catalog-btn {
    padding: 16px 12px;
    background: var(--lv2-surface);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--lv2-radius-sm);
    color: var(--lv2-text);
    cursor: pointer;
    text-align: center;
    transition: transform 0.15s, border-color 0.15s, background 0.15s;
    font-family: inherit;
}
.demo-catalog-btn:hover { border-color: var(--lv2-accent); transform: translateY(-2px); background: rgba(14,165,233,0.08); }
.demo-catalog-btn .demo-prod-icon { font-size: 1.4rem; display: block; margin-bottom: 4px; }
.demo-catalog-btn .demo-prod-name { font-size: 0.8rem; font-weight: 600; }
.demo-catalog-btn .demo-prod-price { font-size: 0.85rem; color: var(--lv2-accent-2); font-weight: 700; margin-top: 4px; }
.demo-catalog-btn .demo-prod-stock { font-size: 0.68rem; color: var(--lv2-muted); margin-top: 2px; }
.demo-catalog-btn.is-low-stock { opacity: 0.6; }

.demo-ticket-panel {
    background: var(--lv2-surface);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--lv2-radius);
    padding: 20px;
    display: flex;
    flex-direction: column;
}
.demo-ticket-title {
    font-weight: 800;
    font-size: 1rem;
    color: var(--lv2-text);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.demo-ticket-items { flex: 1; overflow-y: auto; margin-bottom: 12px; }
.demo-ticket-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    font-size: 0.85rem;
}
.demo-ticket-row span { color: var(--lv2-text-dim); }
.demo-ticket-row strong { color: var(--lv2-text); font-size: 0.85rem; }
.demo-ticket-row button {
    padding: 2px 8px;
    background: rgba(239,68,68,0.15);
    border: none;
    border-radius: 6px;
    color: var(--lv2-danger);
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 700;
}
.demo-qty-controls {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.demo-qty-controls button {
    padding: 0 6px;
    background: var(--lv2-surface-2);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 4px;
    color: var(--lv2-text);
    cursor: pointer;
    font-size: 0.75rem;
    min-width: 24px;
}
.demo-ticket-total {
    display: flex;
    justify-content: space-between;
    padding: 14px 0;
    border-top: 2px solid rgba(255,255,255,0.12);
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--lv2-text);
}
.demo-ticket-empty { text-align: center; color: var(--lv2-muted); padding: 40px 0; font-size: 0.9rem; }
.demo-btn-checkout {
    width: 100%;
    padding: 14px;
    background: var(--lv2-accent-gradient);
    color: #fff;
    border: none;
    border-radius: var(--lv2-radius-sm);
    font-weight: 800;
    font-size: 1rem;
    cursor: pointer;
    transition: opacity 0.2s;
    font-family: inherit;
}
.demo-btn-checkout:hover { opacity: 0.9; }
.demo-btn-checkout:disabled { opacity: 0.4; cursor: not-allowed; }

/* Modal cobro */
.demo-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 300;
    background: rgba(0,0,0,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
}
.demo-modal {
    background: var(--lv2-bg-2);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--lv2-radius-lg);
    padding: 28px 24px;
    min-width: 360px;
    max-width: 90vw;
    box-shadow: var(--lv2-shadow-lg);
}
.demo-modal h3 {
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--lv2-text);
    margin: 0 0 16px;
}
.demo-payment-options {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}
.demo-payment-options button {
    flex: 1;
    padding: 14px;
    background: var(--lv2-surface);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--lv2-radius-sm);
    color: var(--lv2-text);
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: border-color 0.2s, background 0.2s;
    font-family: inherit;
}
.demo-payment-options button:hover { border-color: var(--lv2-accent); background: rgba(14,165,233,0.08); }
.demo-modal-actions { display: flex; gap: 10px; }
.demo-modal-actions button {
    flex: 1;
    padding: 10px;
    border-radius: var(--lv2-radius-sm);
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.85rem;
}
.demo-btn-cancel { background: var(--lv2-surface-2); border: 1px solid rgba(255,255,255,0.08); color: var(--lv2-text); }

/* Animacion exito */
.demo-success-overlay {
    position: fixed;
    inset: 0;
    z-index: 400;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: demoFadeIn 0.3s ease;
}
.demo-success-box {
    background: var(--lv2-bg-2);
    border: 1px solid var(--lv2-success);
    border-radius: var(--lv2-radius-lg);
    padding: 32px;
    text-align: center;
    animation: demoPopup 0.4s var(--lv2-easing);
}
.demo-success-box .demo-check {
    font-size: 3rem;
    margin-bottom: 12px;
}
.demo-success-box strong {
    display: block;
    font-size: 1.2rem;
    color: var(--lv2-text);
}
.demo-success-box span {
    font-size: 0.9rem;
    color: var(--lv2-muted);
}
@keyframes demoFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes demoPopup { from { transform: scale(0.85); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* Module: Inventario */
.demo-inv-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}
.demo-inv-table th {
    text-align: left;
    padding: 10px;
    color: var(--lv2-muted);
    font-weight: 600;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.demo-inv-table td {
    padding: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.03);
    color: var(--lv2-text-dim);
}
.demo-inv-table td strong { color: var(--lv2-text); }
.demo-stock-bar {
    width: 80px;
    height: 6px;
    background: rgba(255,255,255,0.06);
    border-radius: 3px;
    overflow: hidden;
}
.demo-stock-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.4s;
}

/* Module: Caja */
.demo-cashbox-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: var(--lv2-radius-sm);
    margin-bottom: 20px;
    font-weight: 700;
    font-size: 0.9rem;
}
.demo-cashbox-status.is-open { background: rgba(16,185,129,0.12); color: var(--lv2-success); }
.demo-cashbox-status.is-closed { background: rgba(239,68,68,0.12); color: var(--lv2-danger); }
.demo-cb-actions { display: flex; gap: 10px; margin-bottom: 20px; }
.demo-cb-summary {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}
.demo-cb-card {
    background: var(--lv2-surface);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: var(--lv2-radius-sm);
    padding: 16px;
    text-align: center;
}
.demo-cb-card strong {
    display: block;
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--lv2-accent-2);
}
.demo-cb-card span {
    font-size: 0.75rem;
    color: var(--lv2-muted);
}

/* Module: Reportes */
.demo-report-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 24px;
}
.demo-report-card {
    background: var(--lv2-surface);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: var(--lv2-radius-sm);
    padding: 18px;
    text-align: center;
}
.demo-report-card strong { display: block; font-size: 1.5rem; font-weight: 800; color: var(--lv2-accent-2); }
.demo-report-card span { font-size: 0.75rem; color: var(--lv2-muted); }
.demo-bars-chart { display: flex; align-items: flex-end; gap: 12px; height: 180px; padding: 10px 0; }
.demo-bars-chart > div { flex: 1; text-align: center; }
.demo-bars-chart > div > div { background: var(--lv2-accent-gradient); border-radius: 6px 6px 0 0; margin: 0 auto 6px; width: 100%; max-width: 60px; transition: height 0.6s var(--lv2-easing); }
.demo-bars-chart > div > span { font-size: 0.7rem; color: var(--lv2-muted); }

/* Tutorial tooltips */
.demo-tour-overlay {
    position: fixed;
    inset: 0;
    z-index: 500;
    background: rgba(0,0,0,0.6);
}
.demo-tour-box {
    position: fixed;
    z-index: 501;
    background: var(--lv2-bg-2);
    border: 1px solid var(--lv2-accent);
    border-radius: var(--lv2-radius);
    padding: 20px;
    max-width: 320px;
    box-shadow: var(--lv2-shadow-lg);
    animation: demoPopup 0.3s var(--lv2-easing);
}
.demo-tour-box h4 { margin: 0 0 8px; font-size: 0.95rem; color: var(--lv2-accent-2); }
.demo-tour-box p { margin: 0 0 14px; font-size: 0.82rem; color: var(--lv2-text-dim); }
.demo-tour-buttons { display: flex; gap: 8px; }
.demo-tour-btn {
    padding: 6px 14px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.8rem;
    cursor: pointer;
    border: none;
    font-family: inherit;
}
.demo-tour-btn-primary { background: var(--lv2-accent-gradient); color: #fff; }
.demo-tour-btn-skip { background: transparent; color: var(--lv2-muted); }

/* Responsive demo */
@media (max-width: 768px) {
    .demo-sidebar { width: 80px; }
    .demo-sidebar button { padding: 10px 8px; font-size: 0.72rem; text-align: center; }
    .demo-sale-layout { grid-template-columns: 1fr; }
    .demo-catalog { grid-template-columns: repeat(3, 1fr); }
    .demo-ticket-panel { max-height: 40vh; }
    .demo-cb-summary { grid-template-columns: repeat(2, 1fr); }
    .demo-report-cards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 420px) {
    .demo-catalog { grid-template-columns: repeat(2, 1fr); }
}

/* =====================================================================
 * === demo light theme ===
 * ===================================================================== */

.demo-banner {
    background: rgba(79,70,229,.06);
    border-color: rgba(79,70,229,.12);
    color: var(--lv2-text-dim);
}
.demo-banner a { color: var(--lv2-accent); }
.demo-reset { background: rgba(239,68,68,.06); border-color: rgba(239,68,68,.15); color: var(--lv2-danger); }
.demo-reset:hover { background: rgba(239,68,68,.12); }

.demo-sidebar { background: var(--lv2-bg-1); border-color: var(--lv2-border); }
.demo-sidebar button { color: var(--lv2-muted); }
.demo-sidebar button:hover { background: var(--lv2-bg-2); color: var(--lv2-text); }
.demo-sidebar button.is-active { background: rgba(79,70,229,.08); color: var(--lv2-accent); border-bottom: 2px solid var(--lv2-accent); border-radius: 0; }

.demo-catalog-btn { background: var(--lv2-surface); border-color: var(--lv2-border); color: var(--lv2-text); box-shadow: var(--lv2-shadow-sm); }
.demo-catalog-btn:hover { border-color: var(--lv2-accent); box-shadow: var(--lv2-shadow); background: var(--lv2-surface); }
.demo-catalog-btn .demo-prod-icon { color: var(--lv2-accent); }
.demo-catalog-btn .demo-prod-icon svg { width: 28px; height: 28px; display: block; margin: 0 auto; }
.demo-catalog-btn .demo-prod-price { color: var(--lv2-accent); }
.demo-catalog-btn.is-low-stock { opacity: 0.55; }

.demo-ticket-panel { background: var(--lv2-surface); border-color: var(--lv2-border); box-shadow: var(--lv2-shadow-sm); }
.demo-ticket-title { color: var(--lv2-text); border-color: var(--lv2-border); }
.demo-ticket-row { border-color: var(--lv2-border); }
.demo-ticket-row button { background: var(--lv2-danger-soft); color: var(--lv2-danger); }
.demo-qty-controls button { background: var(--lv2-bg-1); border-color: var(--lv2-border); color: var(--lv2-text); }
.demo-ticket-total { border-color: var(--lv2-border); }
.demo-btn-checkout { background: var(--lv2-accent); }
.demo-btn-checkout:hover { background: #4338ca; }

.demo-modal-overlay { background: rgba(15,23,42,.4); }
.demo-modal { background: var(--lv2-surface); border-color: var(--lv2-border); }
.demo-payment-options button { background: var(--lv2-bg-1); border-color: var(--lv2-border); color: var(--lv2-text); }
.demo-payment-options button:hover { border-color: var(--lv2-accent); background: rgba(79,70,229,.06); }
.demo-btn-cancel { background: var(--lv2-bg-1); border-color: var(--lv2-border); color: var(--lv2-text); }

.demo-success-box { background: var(--lv2-surface); border-color: var(--lv2-success); }

.demo-inv-table th { color: var(--lv2-muted); border-color: var(--lv2-border); }
.demo-inv-table td { border-color: var(--lv2-border); color: var(--lv2-text-dim); }
.demo-stock-bar { background: var(--lv2-bg-2); }

.demo-cashbox-status.is-open { background: var(--lv2-success-soft); color: var(--lv2-success); }
.demo-cashbox-status.is-closed { background: var(--lv2-danger-soft); color: var(--lv2-danger); }
.demo-cb-card { background: var(--lv2-surface); border-color: var(--lv2-border); box-shadow: var(--lv2-shadow-sm); }
.demo-cb-card strong { color: var(--lv2-accent); }

.demo-report-card { background: var(--lv2-surface); border-color: var(--lv2-border); box-shadow: var(--lv2-shadow-sm); }
.demo-report-card strong { color: var(--lv2-accent); }
.demo-bars-chart > div > div { background: var(--lv2-accent); }

.demo-tour-overlay { background: rgba(15,23,42,.3); }
.demo-tour-box { background: var(--lv2-surface); border-color: var(--lv2-accent); }
.demo-tour-btn-primary { background: var(--lv2-accent); }
.demo-tour-btn-skip { color: var(--lv2-muted); }

/* =====================================================================
 * Demo polish 20260525: clearer sale flow, richer products, mobile fit.
 * ===================================================================== */
body.is-demo {
    overflow-x: hidden;
}

body.is-demo .lv2-main,
body.is-demo .demo-shell,
body.is-demo .demo-workspace,
body.is-demo .demo-content,
body.is-demo .demo-sale-layout,
body.is-demo .demo-sale-main {
    min-width: 0;
}

body.is-demo .demo-shell {
    background:
        radial-gradient(620px 260px at 24% 0%, rgba(79,70,229,.08), transparent 64%),
        linear-gradient(180deg, #fff 0%, #f8fafc 100%);
}

body.is-demo .demo-banner {
    position: relative;
    z-index: 2;
}

body.is-demo .demo-workspace {
    background: transparent;
}

body.is-demo .demo-sidebar {
    width: 172px;
    gap: 6px;
    padding: 14px 10px;
}

body.is-demo .demo-sidebar button {
    display: flex;
    align-items: center;
    gap: 9px;
    min-height: 42px;
    border: 1px solid transparent;
    border-radius: 10px;
    transition: background-color .16s ease, color .16s ease, border-color .16s ease, transform .16s ease;
}

body.is-demo .demo-sidebar button:hover {
    transform: translateX(1px);
}

body.is-demo .demo-sidebar button.is-active {
    border-bottom: 1px solid rgba(79,70,229,.18);
    border-color: rgba(79,70,229,.18);
    border-radius: 10px;
}

body.is-demo .demo-content {
    padding: 18px;
}

body.is-demo .demo-sale-layout {
    grid-template-columns: minmax(0, 1fr) minmax(318px, 378px);
    gap: 18px;
    align-items: start;
}

body.is-demo .demo-sale-main {
    display: grid;
    gap: 12px;
}

body.is-demo .demo-sale-callout {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
    background: #fff;
    border: 1px solid rgba(79,70,229,.16);
    border-radius: 16px;
    box-shadow: 0 8px 22px -18px rgba(15,23,42,.28);
}

body.is-demo .demo-sale-callout div {
    display: grid;
    gap: 3px;
}

body.is-demo .demo-sale-callout strong {
    color: var(--lv2-text);
    font-size: .92rem;
}

body.is-demo .demo-sale-callout span {
    color: var(--lv2-muted);
    font-size: .8rem;
    line-height: 1.45;
}

body.is-demo .demo-sale-callout button {
    flex: 0 0 auto;
    border: 0;
    border-radius: 999px;
    padding: 9px 14px;
    background: var(--lv2-accent);
    color: #fff;
    font: inherit;
    font-size: .78rem;
    font-weight: 800;
    cursor: pointer;
    transition: background-color .16s ease, transform .16s ease;
}

body.is-demo .demo-sale-callout button:hover {
    background: #4338ca;
    transform: translateY(-1px);
}

body.is-demo .demo-sale-callout.is-open {
    border-color: rgba(22,163,74,.22);
    background: linear-gradient(180deg, #fff 0%, var(--lv2-success-soft) 180%);
}

body.is-demo .demo-sale-callout.is-open strong {
    color: var(--lv2-success);
}

body.is-demo .demo-catalog {
    grid-template-columns: repeat(auto-fit, minmax(148px, 1fr));
    gap: 12px;
}

body.is-demo .demo-catalog-btn {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 10px;
    min-height: 156px;
    padding: 13px;
    overflow: hidden;
    text-align: left;
    border-radius: 16px;
    border-color: var(--lv2-border);
    background:
        linear-gradient(180deg, rgba(255,255,255,.98), rgba(255,255,255,.90)),
        var(--demo-cat-soft, #eef2ff);
    box-shadow: 0 8px 22px -20px rgba(15,23,42,.3);
    transform: translateZ(0);
    transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
}

body.is-demo .demo-catalog-btn::before {
    content: "";
    position: absolute;
    inset: 0;
    border-top: 3px solid var(--demo-cat, var(--lv2-accent));
    opacity: .9;
    pointer-events: none;
}

body.is-demo .demo-catalog-btn:hover {
    border-color: color-mix(in srgb, var(--demo-cat, var(--lv2-accent)) 38%, var(--lv2-border));
    box-shadow: 0 14px 30px -22px rgba(15,23,42,.38);
    transform: translateY(-2px);
}

body.is-demo .demo-catalog-btn:active {
    transform: translateY(0);
}

body.is-demo .demo-catalog-btn:focus-visible {
    outline: 2px solid var(--demo-cat, var(--lv2-accent));
    outline-offset: 3px;
}

body.is-demo .demo-prod-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

body.is-demo .demo-prod-icon {
    width: 46px;
    height: 46px;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    margin: 0 !important;
    color: var(--demo-cat, var(--lv2-accent)) !important;
    background: var(--demo-cat-soft, var(--lv2-primary-soft));
    border: 1px solid color-mix(in srgb, var(--demo-cat, var(--lv2-accent)) 18%, transparent);
    border-radius: 14px;
}

body.is-demo .demo-prod-icon svg {
    width: 25px !important;
    height: 25px !important;
    margin: 0 !important;
}

body.is-demo .demo-prod-cat {
    max-width: 78px;
    padding: 5px 8px;
    border-radius: 999px;
    background: var(--demo-cat-soft, var(--lv2-primary-soft));
    color: var(--demo-cat, var(--lv2-accent));
    font-size: .66rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body.is-demo .demo-prod-name {
    display: block;
    min-height: 2.4em;
    color: var(--lv2-text);
    font-size: .92rem !important;
    font-weight: 800 !important;
    line-height: 1.2;
    word-break: normal;
    overflow-wrap: anywhere;
}

body.is-demo .demo-prod-bottom {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
}

body.is-demo .demo-prod-price {
    color: var(--demo-cat, var(--lv2-accent)) !important;
    font-size: .98rem !important;
    font-weight: 900 !important;
    margin: 0 !important;
}

body.is-demo .demo-prod-stock {
    margin: 0 !important;
    padding: 4px 7px;
    border-radius: 999px;
    background: var(--lv2-bg-1);
    color: var(--lv2-muted);
    font-size: .68rem !important;
    font-weight: 700;
    white-space: nowrap;
}

body.is-demo .demo-catalog-btn.is-low-stock {
    opacity: 1;
    border-color: rgba(217,119,6,.28);
}

body.is-demo .demo-catalog-btn.is-low-stock .demo-prod-stock {
    background: #fef3c7;
    color: var(--lv2-warning);
}

body.is-demo .demo-catalog-btn.is-out-stock {
    opacity: .68;
    cursor: not-allowed;
    filter: grayscale(.18);
}

body.is-demo .demo-catalog-btn.is-out-stock .demo-prod-stock {
    background: var(--lv2-danger-soft);
    color: var(--lv2-danger);
}

body.is-demo .demo-catalog-btn.is-added {
    animation: demoAdded .34s ease;
}

body.is-demo .demo-catalog-btn.is-added::after {
    content: "Agregado";
    position: absolute;
    right: 12px;
    bottom: 12px;
    padding: 5px 8px;
    border-radius: 999px;
    background: var(--lv2-success);
    color: #fff;
    font-size: .68rem;
    font-weight: 900;
    pointer-events: none;
}

body.is-demo .demo-ticket-panel {
    position: sticky;
    top: 84px;
    min-width: 0;
    max-height: calc(100vh - 150px);
    border-radius: 18px;
}

body.is-demo .demo-ticket-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

body.is-demo .demo-ticket-items {
    scrollbar-width: thin;
}

body.is-demo .demo-ticket-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto 28px;
    gap: 8px;
    align-items: center;
    padding: 10px 0;
}

body.is-demo .demo-ticket-product {
    display: grid;
    gap: 2px;
    min-width: 0;
}

body.is-demo .demo-ticket-product span {
    color: var(--lv2-text);
    font-weight: 800;
    line-height: 1.2;
}

body.is-demo .demo-ticket-product small {
    color: var(--lv2-muted);
    font-size: .72rem;
}

body.is-demo .demo-ticket-row strong {
    white-space: nowrap;
}

body.is-demo .demo-qty-controls {
    border: 1px solid var(--lv2-border);
    border-radius: 999px;
    padding: 2px;
    background: var(--lv2-bg-1);
}

body.is-demo .demo-qty-controls button {
    width: 24px;
    height: 24px;
    min-width: 24px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: #fff;
}

body.is-demo .demo-qty-controls span {
    min-width: 18px;
    color: var(--lv2-text);
    font-size: .78rem;
    font-weight: 800;
    text-align: center;
}

body.is-demo .demo-remove-item {
    width: 28px;
    height: 28px;
    padding: 0;
    border-radius: 999px;
}

body.is-demo .demo-ticket-total {
    align-items: baseline;
}

body.is-demo .demo-ticket-total span {
    color: var(--lv2-muted);
    font-size: .84rem;
}

body.is-demo .demo-ticket-total strong {
    color: var(--lv2-text);
    font-size: 1.24rem;
}

body.is-demo .demo-btn-checkout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--lv2-accent);
    box-shadow: 0 12px 26px -18px rgba(79,70,229,.55);
    transition: background-color .16s ease, transform .16s ease, opacity .16s ease;
}

body.is-demo .demo-btn-checkout:not(:disabled):hover {
    transform: translateY(-1px);
}

body.is-demo .demo-inv-product-icon {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;
    color: var(--demo-cat, var(--lv2-accent));
    background: var(--demo-cat-soft, var(--lv2-primary-soft));
    border-radius: 10px;
    vertical-align: middle;
}

body.is-demo .demo-inv-product-icon svg {
    width: 18px;
    height: 18px;
}

body.is-demo .demo-report-card,
body.is-demo .demo-cb-card {
    transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}

body.is-demo .demo-report-card:hover,
body.is-demo .demo-cb-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px -22px rgba(15,23,42,.32);
}

body.is-demo .demo-bars-chart > div > div {
    background: linear-gradient(180deg, var(--lv2-accent), #818cf8);
}

.demo-toast {
    position: fixed;
    left: 50%;
    bottom: 22px;
    z-index: 800;
    max-width: min(420px, calc(100vw - 28px));
    padding: 11px 14px;
    border: 1px solid rgba(79,70,229,.18);
    border-radius: 999px;
    background: rgba(255,255,255,.98);
    color: var(--lv2-text);
    box-shadow: 0 16px 34px -24px rgba(15,23,42,.4);
    font-size: .84rem;
    font-weight: 800;
    text-align: center;
    opacity: 0;
    transform: translate(-50%, 8px);
    transition: opacity .18s ease, transform .18s ease;
}

.demo-toast.is-visible {
    opacity: 1;
    transform: translate(-50%, 0);
}

@keyframes demoAdded {
    0% { transform: translateY(0) scale(1); }
    45% { transform: translateY(-2px) scale(1.015); }
    100% { transform: translateY(0) scale(1); }
}

@media (max-width: 900px) {
    body.is-demo .demo-sale-layout {
        grid-template-columns: 1fr;
    }

    body.is-demo .demo-ticket-panel {
        position: static;
        max-height: none;
    }
}

@media (max-width: 768px) {
    body.is-demo .lv2-topbar {
        min-height: 58px;
        padding-inline: 12px;
    }

    body.is-demo .lv2-topbar nav {
        gap: 8px !important;
    }

    body.is-demo .lv2-topbar nav a:not(.lv2-btn) {
        font-size: 0 !important;
        width: 38px;
        height: 38px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 999px;
        background: var(--lv2-bg-1);
    }

    body.is-demo .lv2-topbar nav .lv2-btn {
        padding: 8px 10px !important;
        font-size: .72rem !important;
    }

    body.is-demo .demo-shell {
        height: auto;
        min-height: calc(100vh - 58px);
    }

    body.is-demo .demo-workspace {
        align-items: stretch;
    }

    body.is-demo .demo-sidebar {
        width: 74px;
        padding: 10px 6px;
    }

    body.is-demo .demo-sidebar button {
        flex-direction: column;
        justify-content: center;
        gap: 4px;
        min-height: 58px;
        padding: 8px 4px;
        font-size: .66rem;
        line-height: 1.1;
    }

    body.is-demo .demo-sidebar button .lv2-icon {
        width: 1.15rem;
        height: 1.15rem;
    }

    body.is-demo .demo-content {
        padding: 12px;
    }

    body.is-demo .demo-sale-callout {
        align-items: stretch;
        flex-direction: column;
    }

    body.is-demo .demo-sale-callout button {
        width: 100%;
    }

    body.is-demo .demo-catalog {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    body.is-demo .demo-catalog-btn {
        min-height: 150px;
        padding: 11px;
    }

    body.is-demo .demo-prod-icon {
        width: 40px;
        height: 40px;
        border-radius: 12px;
    }

    body.is-demo .demo-prod-cat {
        max-width: 68px;
        padding-inline: 7px;
    }

    body.is-demo .demo-prod-name {
        font-size: .84rem !important;
    }

    body.is-demo .demo-prod-bottom {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    body.is-demo .demo-ticket-row {
        grid-template-columns: minmax(0, 1fr) auto 28px;
    }

    body.is-demo .demo-ticket-row > strong {
        grid-column: 1 / 2;
        grid-row: 2;
    }

    body.is-demo .demo-inv-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    body.is-demo .demo-report-cards,
    body.is-demo .demo-cb-summary {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    body.is-demo .lv2-topbar-brand span {
        display: none;
    }

    body.is-demo .lv2-topbar nav .lv2-btn {
        width: 40px;
        height: 38px;
        padding: 0 !important;
        font-size: 0 !important;
    }

    body.is-demo .demo-catalog {
        grid-template-columns: minmax(0, 1fr);
    }

    body.is-demo .demo-catalog-btn {
        min-height: 138px;
    }
}

@media (max-width: 420px) {
    body.is-demo .demo-sidebar {
        width: 68px;
    }
}

@media (prefers-reduced-motion: reduce) {
    body.is-demo .demo-sidebar button,
    body.is-demo .demo-sale-callout button,
    body.is-demo .demo-catalog-btn,
    body.is-demo .demo-btn-checkout,
    body.is-demo .demo-report-card,
    body.is-demo .demo-cb-card,
    .demo-toast {
        transition: none;
    }

    body.is-demo .demo-catalog-btn.is-added {
        animation: none;
    }
}
