/* ============================================================
   ComBack - App Cliente (userapp) - CSS de 'menu_public' (standalone)
   Consolida los <style> inline puros (orden de documento). ?v=asset_version.
   ============================================================ */

        /* T99: @font-face AUTO-ALOJADOS (Playfair Display + Inter, subsets latin
           y latin-ext) sirviendo desde /static/fonts. Reemplazan el CDN de Google
           Fonts para eliminar el flash de fuente. El navegador baja solo el subset
           que use (para espanol = latin; latin-ext queda de respaldo). */
        @font-face{font-family:'Inter';font-style:normal;font-weight:400;font-display:swap;src:url('/static/fonts/inter-400-latin-ext.woff2') format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;}
        @font-face{font-family:'Inter';font-style:normal;font-weight:400;font-display:swap;src:url('/static/fonts/inter-400-latin.woff2') format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}
        @font-face{font-family:'Inter';font-style:normal;font-weight:500;font-display:swap;src:url('/static/fonts/inter-500-latin-ext.woff2') format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;}
        @font-face{font-family:'Inter';font-style:normal;font-weight:500;font-display:swap;src:url('/static/fonts/inter-500-latin.woff2') format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}
        @font-face{font-family:'Inter';font-style:normal;font-weight:600;font-display:swap;src:url('/static/fonts/inter-600-latin-ext.woff2') format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;}
        @font-face{font-family:'Inter';font-style:normal;font-weight:600;font-display:swap;src:url('/static/fonts/inter-600-latin.woff2') format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}
        @font-face{font-family:'Inter';font-style:normal;font-weight:700;font-display:swap;src:url('/static/fonts/inter-700-latin-ext.woff2') format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;}
        @font-face{font-family:'Inter';font-style:normal;font-weight:700;font-display:swap;src:url('/static/fonts/inter-700-latin.woff2') format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}
        @font-face{font-family:'Playfair Display';font-style:normal;font-weight:600;font-display:swap;src:url('/static/fonts/playfair-display-600-latin-ext.woff2') format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;}
        @font-face{font-family:'Playfair Display';font-style:normal;font-weight:600;font-display:swap;src:url('/static/fonts/playfair-display-600-latin.woff2') format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}
        @font-face{font-family:'Playfair Display';font-style:normal;font-weight:700;font-display:swap;src:url('/static/fonts/playfair-display-700-latin-ext.woff2') format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;}
        @font-face{font-family:'Playfair Display';font-style:normal;font-weight:700;font-display:swap;src:url('/static/fonts/playfair-display-700-latin.woff2') format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}
        @font-face{font-family:'Playfair Display';font-style:normal;font-weight:800;font-display:swap;src:url('/static/fonts/playfair-display-800-latin-ext.woff2') format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;}
        @font-face{font-family:'Playfair Display';font-style:normal;font-weight:800;font-display:swap;src:url('/static/fonts/playfair-display-800-latin.woff2') format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;}
        /* ===== COLOR SYSTEM ===== */
        :root {
            /* T37: paleta refrescada — morado var(--cb-primary) dominante */
            --bg-page: #FAFAF8;
            --bg-card: #ffffff;
            --bg-tertiary: #F2F2F7;
            --text-primary: #2D2D2D;
            --text-secondary: #888;
            --text-muted: #999;
            --text-light: #ccc;
            --border-color: #E8E8E8;
            --border-light: #f0f0f0;
            --shadow-sm: 0 2px 12px rgba(0,0,0,0.04);
            --shadow-md: 0 4px 20px rgba(0,0,0,0.06);
            --shadow-lg: 0 20px 60px rgba(0,0,0,0.12);
            --header-bg: #ffffff;
            --header-border: #eeeeee;
            --pill-active-bg: #2D2D2D;
            --pill-active-color: #fff;
            --no-img-bg: #f5f0eb;
            --no-img-bg2: #e8e0d8;
            --no-img-color: #d5ccc3;
            --arrow-bg: #fff;
            --arrow-color: #333;
            --footer-color: #bbb;
        }

        [data-theme="dark"] {
            --bg-page: #000000;
            --bg-card: #1C1C1E;
            --bg-tertiary: #2C2C2E;
            --text-primary: #F5F5F7;
            --text-secondary: #98989D;
            --text-muted: #636366;
            --text-light: #48484A;
            --border-color: #38383A;
            --border-light: #2C2C2E;
            --shadow-sm: 0 2px 12px rgba(0,0,0,0.3);
            --shadow-md: 0 4px 20px rgba(0,0,0,0.4);
            --shadow-lg: 0 20px 60px rgba(0,0,0,0.5);
            --header-bg: #1C1C1E;
            --header-border: #38383A;
            --pill-active-bg: var(--cb-support);
            --pill-active-color: #fff;
            --no-img-bg: #2C2C2E;
            --no-img-bg2: #38383A;
            --no-img-color: #636366;
            --arrow-bg: #2C2C2E;
            --arrow-color: #F5F5F7;
            --footer-color: #636366;
        }

        @media (prefers-color-scheme: dark) {
            :root:not([data-theme="light"]) {
                --bg-page: #000000;
                --bg-card: #1C1C1E;
                --bg-tertiary: #2C2C2E;
                --text-primary: #F5F5F7;
                --text-secondary: #98989D;
                --text-muted: #636366;
                --text-light: #48484A;
                --border-color: #38383A;
                --border-light: #2C2C2E;
                --shadow-sm: 0 2px 12px rgba(0,0,0,0.3);
                --shadow-md: 0 4px 20px rgba(0,0,0,0.4);
                --shadow-lg: 0 20px 60px rgba(0,0,0,0.5);
                --header-bg: #1C1C1E;
                --header-border: #38383A;
                --pill-active-bg: var(--cb-support);
                --pill-active-color: #fff;
                --no-img-bg: #2C2C2E;
                --no-img-bg2: #38383A;
                --no-img-color: #636366;
                --arrow-bg: #2C2C2E;
                --arrow-color: #F5F5F7;
                --footer-color: #636366;
            }
        }

        * { margin:0; padding:0; box-sizing:border-box; }
        body {
            font-family: 'Inter', -apple-system, sans-serif;
            background: var(--bg-page);
            color: var(--text-primary);
            -webkit-font-smoothing: antialiased;
            overflow-x: hidden;
            transition: background 0.3s, color 0.3s;
        }

        /* ---- Header ---- */
        /* T36: si hay balance ribbon visible (body.cb-has-balance-ribbon), el header
           sticky se baja para no taparlo. Si no hay ribbon, queda en top: 0. */
        body { --cb-ribbon-h: 0px; }
        body.cb-has-balance-ribbon { --cb-ribbon-h: 56px; }
        @media (max-width: 480px) {
            body.cb-has-balance-ribbon { --cb-ribbon-h: 54px; }
        }
        .site-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 16px 40px;
            background: var(--header-bg);
            border-bottom: 1px solid var(--header-border);
            position: sticky;
            top: var(--cb-ribbon-h);
            z-index: 200;
            transition: background 0.3s;
        }

        /* T36: balance ribbon sticky encima del header de categorias */
        .cb-balance-ribbon {
            position: sticky;
            top: 0;
            z-index: 201;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            padding: 10px 16px;
            min-height: 56px;
            background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
            color: #fff;
            font-weight: 700;
            font-size: 0.92rem;
            box-shadow: 0 4px 14px rgba(216,27,96,0.28);
            animation: cbRibbonPulse 2.4s ease-in-out infinite;
        }
        .cb-balance-ribbon .ribbon-icon { font-size: 1.1rem; }
        .cb-balance-ribbon .ribbon-amount {
            font-weight: 900;
            font-size: 1rem;
            background: rgba(255,255,255,0.18);
            padding: 2px 10px;
            border-radius: 10px;
        }
        .cb-balance-ribbon .ribbon-msg {
            font-weight: 600;
            opacity: 0.95;
        }
        /* Barra clickable + boton "Redimir" (abre directo el QR del comercio) */
        .cb-balance-ribbon.cb-ribbon-clickable {
            text-decoration: none;
            cursor: pointer;
        }
        .cb-balance-ribbon.cb-ribbon-clickable:active { transform: scale(0.99); }
        .cb-balance-ribbon .cb-ribbon-redeem-btn {
            background: #fff;
            color: var(--cb-magenta-dark);
            font-weight: 800;
            padding: 5px 14px;
            border-radius: 14px;
            font-size: 0.82rem;
            display: inline-flex;
            align-items: center;
            gap: 6px;
            box-shadow: 0 2px 8px rgba(0,0,0,0.22);
            white-space: nowrap;
            margin-left: 4px;
        }
        /* Distribucion de la barra de REGISTRO/returning: gancho a la izquierda,
           boton empujado a la derecha (dejando aire para el hamburguesa). Antes
           iba todo centrado y se veia apretado. */
        .cb-balance-ribbon.cb-register-ribbon {
            justify-content: flex-start;
            gap: 12px;
            padding-left: 18px;
            padding-right: 64px;   /* espacio para el hamburguesa arriba-derecha */
        }
        .cb-register-ribbon .ribbon-icon { flex-shrink: 0; }
        .cb-register-ribbon .ribbon-amount,
        .cb-register-ribbon .cb-ret-greet { min-width: 0; }
        .cb-register-ribbon .cb-ribbon-redeem-btn {
            margin-left: auto;
            flex-shrink: 0;
        }
        /* Barra de registro adaptativa: si el dispositivo YA estuvo logueado
           (html.cb-returning) mostramos "Ingresar"; si no, "Registrarme". */
        .cb-register-ribbon .cb-only-ret { display: none; }
        html.cb-returning .cb-register-ribbon .cb-only-new { display: none; }
        html.cb-returning .cb-register-ribbon .cb-only-ret { display: inline; }
        html.cb-returning .cb-register-ribbon i.cb-only-ret { display: inline-block; }
        /* Estado "returning": saludo por nombre + % en dos lineas. */
        html.cb-returning .cb-register-ribbon .cb-ret-greet {
            display: inline-flex;
            flex-direction: column;
            justify-content: center;
            line-height: 1.12;
            min-width: 0;
            overflow: hidden;
        }
        .cb-ret-greet .cb-ret-hello {
            font-weight: 800;
            font-size: 0.92rem;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
        .cb-ret-greet .cb-ret-rate {
            font-size: 0.72rem;
            font-weight: 700;
            opacity: 0.92;
        }
        .cb-ret-greet .cb-ret-rate i { font-size: 0.66rem; margin-right: 2px; }
        .cb-balance-ribbon.is-low {
            background: linear-gradient(135deg, #f0ad4e 0%, #ec971f 50%, #d58512 100%);
        }
        @keyframes cbRibbonPulse {
            0%, 100% { box-shadow: 0 4px 14px rgba(216,27,96,0.28); }
            50%      { box-shadow: 0 6px 22px rgba(216,27,96,0.55), 0 0 0 4px rgba(255,45,146,0.18); }
        }
        .cb-balance-ribbon.is-low { animation: cbRibbonPulseOrange 2.4s ease-in-out infinite; }
        @keyframes cbRibbonPulseOrange {
            0%, 100% { box-shadow: 0 4px 14px rgba(240,173,78,0.28); }
            50%      { box-shadow: 0 6px 22px rgba(240,173,78,0.55), 0 0 0 4px rgba(240,173,78,0.18); }
        }
        @media (prefers-reduced-motion: reduce) {
            .cb-balance-ribbon { animation: none; }
        }
        @media (max-width: 480px) {
            .cb-balance-ribbon { font-size: 0.78rem; padding: 8px 10px; min-height: 54px; gap: 6px; }
            .cb-balance-ribbon .ribbon-amount { font-size: 0.88rem; padding: 2px 8px; }
            .cb-balance-ribbon .cb-ribbon-prefix { display: none; }
        }
        @media (max-width: 360px) {
            .cb-balance-ribbon .cb-ribbon-cta { display: none; }
        }

        .header-left {
            display: flex;
            align-items: center;
            gap: 12px;
        }
        .btn-home {
            width: 36px; height: 36px;
            border-radius: 50%;
            background: var(--bg-tertiary);
            border: none;
            color: var(--text-secondary);
            font-size: 0.95rem;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            text-decoration: none;
            transition: all 0.2s;
            flex-shrink: 0;
        }
        .btn-home:hover { background: var(--cb-orange); color: #fff; }
        .site-header .brand {
            display: flex;
            align-items: center;
            gap: 12px;
            text-decoration: none;
            color: var(--text-primary);
        }
        .site-header .brand-logo {
            width: 40px; height: 40px;
            border-radius: 50%;
            background: var(--cb-orange);
            display: flex;
            align-items: center;
            justify-content: center;
            overflow: hidden;
        }
        .site-header .brand-logo img { width: 100%; height: 100%; object-fit: contain; }
        .site-header .brand-logo span { color: #fff; font-weight: 700; font-size: 1.1rem; }
        .site-header .brand-name { font-weight: 700; font-size: 1.1rem; }
        .site-header .brand-tagline { font-size: 0.75rem; color: var(--text-muted); }

        /* Category pills - wrapper con flechas en los extremos */
        .cat-pills-wrap {
            position: relative;
            display: flex;
            align-items: center;
            min-width: 0;
            flex: 1;
        }
        /* T32: Indicador animado en el borde derecho cuando hay overflow scroll.
           Combina fade gradient + chevron rebotando para invitar a swipear. */
        .cat-pills-wrap.has-overflow::after {
            content: '\f054'; /* fa-chevron-right */
            font-family: 'Font Awesome 5 Free';
            font-weight: 900;
            position: absolute;
            right: 0;
            top: 50%;
            transform: translateY(-50%);
            width: 40px;
            height: 100%;
            display: flex;
            align-items: center;
            justify-content: flex-end;
            padding-right: 6px;
            color: var(--cb-orange, var(--cb-support));
            font-size: 0.95rem;
            background: linear-gradient(to right,
                transparent 0%,
                var(--header-bg, rgba(20,20,24,0.92)) 60%);
            pointer-events: none;
            animation: cbCatNudge 1.4s ease-in-out infinite;
            z-index: 1;
        }
        @keyframes cbCatNudge {
            0%, 100% { transform: translate(0, -50%); opacity: 0.55; }
            50% { transform: translate(6px, -50%); opacity: 1; }
        }
        /* Cuando el usuario ya scrolleo hasta el final, ocultamos el indicador */
        .cat-pills-wrap.scrolled-end::after { display: none; }
        .cat-pills {
            display: flex;
            gap: 8px;
            overflow-x: auto;
            scrollbar-width: none;
            -webkit-user-select: none;
            user-select: none;
            scroll-behavior: smooth;
            min-width: 0;
            flex: 1;
            padding-right: 28px; /* espacio para el indicador animado */
        }
        .cat-pills::-webkit-scrollbar { display: none; }
        /* T37: pills mas grandes y llamativos. */
        .cat-pill {
            padding: 12px 28px;
            border-radius: 28px;
            font-size: 0.95rem;
            font-weight: 700;
            cursor: pointer;
            border: 2px solid transparent;
            /* Gradiente rosa-morado sutil en inactivo */
            background: linear-gradient(135deg,
                rgba(255,45,146,0.10),
                rgba(155,89,182,0.10));
            color: var(--text-primary, #2D2D2D);
            white-space: nowrap;
            transition: all 0.25s cubic-bezier(.25,.46,.45,.94);
            text-decoration: none;
            -webkit-user-drag: none;
            box-shadow: 0 2px 6px rgba(0,0,0,0.07);
            letter-spacing: 0.2px;
        }

        /* Botones flecha (solo desktop con hover) */
        .cat-arrow {
            position: relative;
            flex-shrink: 0;
            width: 36px;
            height: 36px;
            border-radius: 50%;
            background: var(--bg-card);
            border: 2px solid var(--border-color);
            color: var(--text-primary);
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            font-size: 0.9rem;
            transition: all 0.2s;
            opacity: 0;
            visibility: hidden;
            z-index: 2;
            margin: 0 4px;
            box-shadow: 0 2px 10px rgba(0,0,0,0.18);
        }
        .cat-arrow.visible { opacity: 1; visibility: visible; }
        .cat-arrow:hover {
            background: var(--pill-active-bg);
            color: var(--pill-active-color);
            border-color: var(--pill-active-bg);
            transform: scale(1.08);
        }
        .cat-arrow:disabled {
            opacity: 0;
            visibility: hidden;
            cursor: default;
        }
        /* En mobile (sin hover, touch) ocultamos las flechas - el swipe es natural */
        @media (hover: none), (max-width: 768px) {
            .cat-arrow { display: none; }
        }
        /* Estado "agarrando" del drag */
        .cat-pills.is-grabbing { cursor: grabbing !important; }
        /* T32/T37: Estado activo/hover con gradiente rosa-morado vibrante.
           Sombra grande y un poco mas grande para destacar como pill activo. */
        .cat-pill:hover, .cat-pill.active {
            background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
            color: #fff !important;
            border-color: transparent;
            text-decoration: none;
            box-shadow: 0 6px 20px rgba(111, 66, 193, 0.45);
            transform: translateY(-2px) scale(1.04);
        }
        .cat-pill.active {
            font-weight: 800;
            /* Pequena animacion al activarse */
            animation: cbPillPop 0.35s ease-out;
        }
        @keyframes cbPillPop {
            0%   { transform: translateY(-2px) scale(1.0); }
            50%  { transform: translateY(-2px) scale(1.08); }
            100% { transform: translateY(-2px) scale(1.04); }
        }

        /* ---- Featured / Showcase ---- */
        .showcase {
            max-width: 1200px;
            margin: 0 auto;
            padding: 40px 40px 20px;
        }
        .showcase-grid {
            display: grid;
            grid-template-columns: 1fr 1fr 340px;
            gap: 40px;
            align-items: center;
            min-height: 420px;
        }

        .featured-img-wrap {
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .featured-img {
            width: 100%;
            max-width: 380px;
            aspect-ratio: 1;
            border-radius: 24px;
            object-fit: cover;
            box-shadow: var(--shadow-lg);
            transition: transform 0.5s cubic-bezier(.25,.46,.45,.94);
        }
        .featured-img.no-image {
            background: linear-gradient(135deg, var(--no-img-bg), var(--no-img-bg2));
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .featured-img.no-image i { font-size: 4rem; color: var(--no-img-color); }
        .nav-arrow {
            position: absolute;
            top: 50%;
            transform: translateY(-50%);
            width: 44px; height: 44px;
            border-radius: 50%;
            background: var(--arrow-bg);
            border: none;
            box-shadow: var(--shadow-md);
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.1rem;
            color: var(--arrow-color);
            transition: all 0.2s;
            z-index: 10;
        }
        .nav-arrow:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.15); transform: translateY(-50%) scale(1.05); }
        .nav-arrow.prev { left: -10px; }
        .nav-arrow.next { right: -10px; }

        .featured-info { padding: 20px 0; }
        .featured-label {
            text-transform: uppercase;
            font-size: 0.7rem;
            font-weight: 700;
            letter-spacing: 3px;
            color: var(--text-muted);
            margin-bottom: 12px;
        }
        .featured-name {
            font-family: 'Playfair Display', serif;
            font-size: 2.8rem;
            font-weight: 700;
            line-height: 1.1;
            color: var(--text-primary);
            margin-bottom: 12px;
        }
        .featured-tagline { font-size: 1rem; color: var(--text-secondary); }

        /* Detail panel */
        .detail-panel {
            background: var(--bg-card);
            border-radius: 16px;
            padding: 32px;
            box-shadow: var(--shadow-md);
            border: 1px solid var(--border-light);
        }
        .detail-name {
            font-family: 'Playfair Display', serif;
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--text-primary);
            margin-bottom: 8px;
        }
        /* T37: precio destacado como BADGE blanco sobre fondo de marca */
        .detail-price {
            display: inline-block;
            font-size: 1.4rem;
            font-weight: 800;
            color: #ffffff;
            background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
            padding: 8px 18px;
            border-radius: 14px;
            margin-bottom: 12px;
            box-shadow: 0 4px 14px rgba(111, 66, 193, 0.35);
            letter-spacing: 0.3px;
        }
        .detail-desc {
            font-size: 0.9rem;
            color: var(--text-secondary);
            line-height: 1.6;
            margin-bottom: 20px;
        }
        .detail-meta {
            display: flex;
            gap: 16px;
            padding-top: 16px;
            border-top: 1px solid var(--border-light);
        }
        .detail-meta-item {
            display: flex;
            align-items: center;
            gap: 6px;
            font-size: 0.8rem;
            color: var(--text-muted);
        }
        .detail-meta-item i { color: var(--cb-orange); }

        /* ---- Product Carousel ---- */
        .carousel-section {
            max-width: 1200px;
            margin: 0 auto;
            padding: 10px 40px 30px;
        }
        .carousel-track {
            display: flex;
            gap: 24px;
            overflow-x: auto;
            padding: 10px 0 20px;
            scrollbar-width: none;
            scroll-behavior: smooth;
            -webkit-user-select: none;
            user-select: none;
        }
        .carousel-track::-webkit-scrollbar { display: none; }
        .thumb-item {
            flex-shrink: 0;
            width: 110px;
            cursor: pointer;
            text-align: center;
            transition: transform 0.3s;
        }
        .thumb-item:hover { transform: translateY(-4px); }
        .thumb-item.active .thumb-img { border-color: var(--cb-orange); box-shadow: 0 4px 16px rgba(113,104,252,0.3); }
        .thumb-img {
            width: 100px; height: 100px;
            border-radius: 50%;
            overflow: hidden;
            margin: 0 auto 8px;
            border: 3px solid transparent;
            transition: all 0.3s;
            background: var(--no-img-bg);
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .thumb-img img { width: 100%; height: 100%; object-fit: cover; }
        .thumb-img .no-img { color: var(--no-img-color); font-size: 1.3rem; }
        .thumb-name {
            font-size: 0.78rem;
            font-weight: 600;
            color: var(--text-secondary);
            line-height: 1.3;
        }
        .thumb-item.active .thumb-name { color: var(--cb-orange); }

        /* ---- Category Sections ---- */
        .sections-wrap {
            max-width: 1200px;
            margin: 0 auto;
            /* T35: padding-top mas chico ahora que no hay showcase arriba */
            padding: 28px 40px 80px;
        }
        .section-divider {
            display: flex;
            align-items: center;
            gap: 16px;
            /* T35: primera categoria sin margin-top extra */
            margin: 28px 0 24px;
        }
        .cat-section:first-child .section-divider { margin-top: 0; }
        .section-divider h2 {
            font-family: 'Playfair Display', serif;
            font-size: 1.6rem;
            font-weight: 700;
            white-space: nowrap;
            color: var(--text-primary);
        }
        .section-divider .line { flex: 1; height: 1px; background: var(--border-color); }
        .section-divider .count {
            font-size: 0.8rem;
            color: var(--text-muted);
            white-space: nowrap;
        }

        /* Grid products */
        .products-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
            gap: 20px;
        }
        .grid-card {
            background: var(--bg-card);
            border-radius: 16px;
            overflow: hidden;
            box-shadow: var(--shadow-sm);
            border: 1px solid var(--border-light);
            transition: all 0.3s;
            cursor: pointer;
        }
        .grid-card:hover {
            transform: translateY(-4px);
            box-shadow: 0 8px 30px rgba(0,0,0,0.08);
        }
        .grid-card-img {
            width: 100%;
            height: 200px;
            background: var(--no-img-bg);
            display: flex;
            align-items: center;
            justify-content: center;
            overflow: hidden;
        }
        .grid-card-img img { width: 100%; height: 100%; object-fit: cover; }
        .grid-card-img .no-img { font-size: 2.5rem; color: var(--no-img-color); }
        .grid-card-body { padding: 16px 20px; }
        .grid-card-name {
            font-weight: 700;
            font-size: 1rem;
            margin-bottom: 4px;
            color: var(--text-primary);
        }
        .grid-card-desc {
            font-size: 0.82rem;
            /* Descripcion del producto. Antes iba var(--text-secondary) + opacity
               0.85 -> se veia doble-apagada (gris opaco). La subimos a un blanco
               mas nitido en dark y un gris mas solido en light, sin opacidad. */
            color: #5f5f66;              /* light mode: gris legible y solido */
            margin-bottom: 10px;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
            line-height: 1.4;
        }
        [data-theme="dark"] .grid-card-desc { color: #E3E3E8; }
        @media (prefers-color-scheme: dark) {
            :root:not([data-theme="light"]) .grid-card-desc { color: #E3E3E8; }
        }
        /* T37: precio como BADGE blanco sobre gradiente de marca — bien resaltante */
        .grid-card-price {
            display: inline-block;
            font-size: 1.05rem;
            font-weight: 800;
            color: #ffffff !important;
            background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
            padding: 6px 14px;
            border-radius: 12px;
            box-shadow: 0 3px 10px rgba(111, 66, 193, 0.35);
            letter-spacing: 0.3px;
            margin-top: 4px;
        }

        /* T35 Skeleton: placeholder con shimmer mientras carga la categoria */
        .grid-card.cat-skel {
            min-height: 320px;
            cursor: default;
            border: 1px solid var(--border-light);
            background: linear-gradient(90deg,
                var(--no-img-bg, #f0f0f0) 0%,
                rgba(255,255,255,0.55) 50%,
                var(--no-img-bg, #f0f0f0) 100%);
            background-size: 200% 100%;
            animation: cbSkelShimmer 1.4s ease-in-out infinite;
            pointer-events: none;
        }
        .grid-card.cat-skel:hover { transform: none; box-shadow: var(--shadow-sm); }
        @keyframes cbSkelShimmer {
            0%   { background-position: 200% 0; }
            100% { background-position: -200% 0; }
        }
        .cat-section.lazy-error .cat-count-placeholder {
            color: #d32f2f;
        }
        .cat-section.lazy-error .grid-card.cat-skel {
            animation: none;
            background: #fff3f3;
        }

        /* ---- Footer ---- */
        .menu-footer {
            text-align: center;
            padding: 30px 20px 40px;
            color: var(--footer-color);
            font-size: 0.8rem;
        }

        /* ---- Empty ---- */
        .empty-menu {
            text-align: center;
            padding: 100px 20px;
            color: var(--text-muted);
        }
        .empty-menu i { font-size: 4rem; margin-bottom: 20px; opacity: 0.2; display: block; }

        /* ---- Responsive ---- */
        @media (max-width: 1024px) {
            .showcase-grid { grid-template-columns: 1fr 1fr; }
            .detail-panel { display: none; }
            .featured-name { font-size: 2.2rem; }
        }
        @media (max-width: 768px) {
            .site-header { padding: 12px 20px; flex-wrap: wrap; gap: 12px; }
            .cat-pills { width: 100%; order: 3; }
            .showcase { padding: 24px 20px 10px; }
            .showcase-grid {
                grid-template-columns: 1fr;
                gap: 20px;
                min-height: auto;
            }
            .featured-img-wrap { order: 1; }
            .featured-img { max-width: 260px; margin: 0 auto; display: block; }
            .featured-info { order: 2; text-align: center; }
            .featured-name { font-size: 1.8rem; }
            .detail-panel { display: block; order: 3; }
            .carousel-section { padding: 0 20px 20px; }
            .thumb-item { width: 90px; }
            .thumb-img { width: 80px; height: 80px; }
            .sections-wrap { padding: 10px 20px 60px; }
            .products-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
            .nav-arrow.prev { left: 5px; }
            .nav-arrow.next { right: 5px; }
        }
        @media (max-width: 480px) {
            .featured-img { max-width: 220px; }
            .featured-name { font-size: 1.5rem; }
            /* T35: en celular dejamos 2 columnas (no 1) por pedido. Cards mas compactos. */
            .products-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
            .grid-card { border-radius: 12px; }
            .grid-card-img { height: 130px; }
            .grid-card-body { padding: 10px 12px 12px; }
            .grid-card-name { font-size: 0.88rem; line-height: 1.25; margin-bottom: 4px; }
            .grid-card-desc { font-size: 0.72rem; margin-bottom: 6px; line-height: 1.35; }
            /* T37: badge precio mas compacto en celular */
            .grid-card-price { font-size: 0.85rem; padding: 4px 10px; border-radius: 10px; }
            /* T37: pills mas compactos en celular */
            .cat-pill { padding: 9px 18px; font-size: 0.85rem; }
            .sections-wrap { padding: 10px 12px 60px; }
            .section-divider { margin: 28px 0 16px; gap: 10px; }
            .section-divider h2 { font-size: 1.2rem; }
            .section-divider .count { font-size: 0.7rem; }
        }

        /* ====================================================
           T35: Modal detalle de producto (click en card grid)
           ==================================================== */
        .prod-modal {
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.72);
            z-index: 10000;
            display: none;
            align-items: center;
            justify-content: center;
            padding: 16px;
            backdrop-filter: blur(4px);
            -webkit-backdrop-filter: blur(4px);
        }
        .prod-modal.show { display: flex; animation: pmFadeIn 0.18s ease-out; }
        @keyframes pmFadeIn { from { opacity: 0; } to { opacity: 1; } }
        .prod-modal-content {
            background: var(--bg-card, #fff);
            border-radius: 20px;
            max-width: 560px;
            width: 100%;
            max-height: 92vh;
            overflow-y: auto;
            position: relative;
            box-shadow: 0 24px 60px rgba(0,0,0,0.32);
            animation: pmSlide 0.22s cubic-bezier(.2,.8,.3,1);
        }
        @keyframes pmSlide { from { transform: translateY(20px); opacity: 0.5; } to { transform: translateY(0); opacity: 1; } }
        .prod-modal-close {
            position: absolute;
            top: 12px;
            left: 12px;   /* T46: cambiado a izquierda — el boton "Ingresar"
                            sticky a la derecha tapaba la X */
            width: 36px;
            height: 36px;
            border-radius: 50%;
            border: none;
            background: rgba(0,0,0,0.55);
            color: #fff;
            font-size: 1.4rem;
            line-height: 1;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 2;
            transition: background 0.15s;
        }
        .prod-modal-close:hover { background: rgba(0,0,0,0.78); }
        .prod-modal-img {
            width: 100%;
            aspect-ratio: 16/10;
            background: var(--no-img-bg, #f0f0f0);
            display: flex;
            align-items: center;
            justify-content: center;
            overflow: hidden;
            border-top-left-radius: 20px;
            border-top-right-radius: 20px;
        }
        .prod-modal-img img { width: 100%; height: 100%; object-fit: cover; }
        .prod-modal-img i { font-size: 4rem; color: var(--no-img-color, #ccc); }
        .prod-modal-body {
            padding: 22px 26px 28px;
        }
        .prod-modal-cat {
            text-transform: uppercase;
            font-size: 0.7rem;
            font-weight: 700;
            letter-spacing: 2px;
            color: var(--text-muted, #888);
            margin-bottom: 8px;
        }
        .prod-modal-name {
            font-family: 'Playfair Display', serif;
            font-size: 1.7rem;
            font-weight: 700;
            color: var(--text-primary);
            margin: 0 0 12px;
            line-height: 1.15;
        }
        /* T37: precio en modal como BADGE blanco resaltante */
        .prod-modal-price {
            display: inline-block;
            font-size: 1.4rem;
            font-weight: 800;
            color: #ffffff;
            background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
            padding: 8px 18px;
            border-radius: 14px;
            margin-bottom: 16px;
            box-shadow: 0 4px 14px rgba(111, 66, 193, 0.35);
            letter-spacing: 0.3px;
        }
        .prod-modal-desc {
            font-size: 0.95rem;
            color: var(--text-secondary);
            line-height: 1.6;
            margin: 0;
            white-space: pre-wrap;  /* respeta saltos de linea reales */
        }
        /* Descripciones de producto (destacado + modal) mas nitidas en dark,
           igual que las tarjetas del grid. */
        [data-theme="dark"] .detail-desc,
        [data-theme="dark"] .prod-modal-desc { color: #E3E3E8; }
        @media (prefers-color-scheme: dark) {
            :root:not([data-theme="light"]) .detail-desc,
            :root:not([data-theme="light"]) .prod-modal-desc { color: #E3E3E8; }
        }
        /* T98: [INACTIVO EN CLIENTE] estilos de la barra de nivel de picante.
           Hoy el cliente muestra solo el icono 🌶️ (pedido de los jefes); se
           conservan para reactivar la barra a futuro. NIVEL 0-5, amarillo->rojo. */
        .cb-spice { display:inline-flex; gap:2px; vertical-align:middle; margin-left:6px; }
        .cb-spice i { width:5px; height:12px; border-radius:2px; background:#d9d9d9; display:inline-block; }
        [data-theme="dark"] .cb-spice i { background:#4a4a4a; }
        @media (prefers-color-scheme: dark) {
            :root:not([data-theme="light"]) .cb-spice i { background:#4a4a4a; }
        }
        .cb-spice i:nth-child(1) { --sc:#FFD24D; }
        .cb-spice i:nth-child(2) { --sc:#FFA53A; }
        .cb-spice i:nth-child(3) { --sc:#FF7A2E; }
        .cb-spice i:nth-child(4) { --sc:#F5502E; }
        .cb-spice i:nth-child(5) { --sc:#E01E1E; }
        .cb-spice-1 i:nth-child(-n+1),
        .cb-spice-2 i:nth-child(-n+2),
        .cb-spice-3 i:nth-child(-n+3),
        .cb-spice-4 i:nth-child(-n+4),
        .cb-spice-5 i:nth-child(-n+5) { background:var(--sc); }
        /* T98: fila propia bajo el TITULO en las cards -> icono ají + barra.
           Siempre en su renglon (no en linea con el nombre) para simetria. */
        .cb-spice-row { display:flex; align-items:center; gap:5px; margin:2px 0 8px; }
        .cb-spice-row .cb-spice { margin-left:0; }
        .cb-spice-ico { font-size:0.95rem; line-height:1; }
        /* T98: [INACTIVO EN CLIENTE] cabecera del modal en 2 columnas (nombre +
           barra de picante). Hoy el modal muestra solo el icono 🌶️ junto al
           nombre; se conserva por si se reactiva la barra de nivel a futuro. */
        .prod-modal-headrow { display:flex; align-items:flex-start; gap:12px; margin-bottom:14px; }
        .prod-modal-headrow .prod-modal-name { flex:1 1 0; min-width:0; margin:0; }
        .prod-modal-spice {
            flex:0 0 auto;
            display:flex; flex-direction:column; align-items:flex-end; gap:3px;
            margin:0; padding-top:5px;
        }
        .prod-modal-spice .pms-top { display:flex; align-items:center; gap:6px; }
        .prod-modal-spice .pms-ico { font-size:1.05rem; line-height:1; }
        .prod-modal-spice .pms-label { font-weight:600; font-size:0.8rem; color:var(--text-muted, #8a8a8a); letter-spacing:0.2px; white-space:nowrap; }
        @media (max-width: 480px) {
            .prod-modal { padding: 0; align-items: flex-end; }
            .prod-modal-content {
                max-width: 100%;
                max-height: 90vh;
                border-radius: 20px 20px 0 0;
                animation: pmSlideUp 0.25s cubic-bezier(.2,.8,.3,1);
            }
            @keyframes pmSlideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
            .prod-modal-img { border-radius: 20px 20px 0 0; aspect-ratio: 4/3; }
            .prod-modal-name { font-size: 1.4rem; }
            .prod-modal-body { padding: 18px 20px 26px; }
        }
        /* Pre-cover instantaneo al volver por navegacion interna: tapa la carta
           DESDE EL PRIMER FRAME (el overlay real, con la moneda, esta al final
           del body y toma el relevo apenas monta — mismo color, sin corte). */
        /* Fondo del root = color del tema, para que el frame en blanco del
           navegador durante el cambio de pagina no se vea (evita el 2do destello). */
        html { background: var(--bg-page, #000); }
        html.cb-navloading::before {
            content: "";
            position: fixed;
            inset: 0;
            background: var(--bg-page, #000);
            z-index: 100000;
        }
        /* Landing "Cargando…" (mismo que abajo) — en el HEAD para que el div,
           que ahora va al INICIO del body, quede estilizado desde el 1er frame. */
        .cb-loading-overlay {
            position: fixed; inset: 0;
            background: var(--bg-page, #000);
            z-index: 100000;
            display: none; align-items: center; justify-content: center;
        }
        .cb-loading-overlay.active { display: flex; animation: cbLoadFade 0.15s ease-out; }
        @keyframes cbLoadFade { from { opacity: 0; } to { opacity: 1; } }
        .cb-loading-box {
            background: var(--bg-card, #fff); border-radius: 18px; padding: 26px 32px;
            display: flex; flex-direction: column; align-items: center; gap: 14px;
            box-shadow: 0 20px 60px rgba(0,0,0,0.4);
        }
        .cb-loading-spinner { position: relative; width: 54px; height: 54px; display: flex; align-items: center; justify-content: center; }
        .cb-loading-spinner .cb-loading-ring {
            position: absolute; inset: 0;
            border: 4px solid var(--border-color, #e0e0e0); border-top-color: var(--cb-primary);
            border-radius: 50%; animation: cbLoadSpin 0.8s linear infinite;
        }
        @keyframes cbLoadSpin { to { transform: rotate(360deg); } }
        .cb-loading-spinner .cb-loading-coin {
            width: 28px; height: 28px; border-radius: 50%;
            background: radial-gradient(circle at 32% 28%, #FFE9A8, #FFC107 58%, #E67E00 100%);
            box-shadow: inset 0 -2px 4px rgba(0,0,0,0.30), inset 0 2px 2px rgba(255,255,255,0.5);
            display: flex; align-items: center; justify-content: center;
            color: var(--cb-primary); font-weight: 900; font-family: Arial, sans-serif; font-size: 17px;
            animation: cbLoadCoinSpin 2.6s ease-in-out infinite;
        }
        .cb-loading-spinner .cb-loading-coin::before { content: '$'; line-height: 1; }
        @keyframes cbLoadCoinSpin { 0% { transform: rotateY(0deg); } 100% { transform: rotateY(360deg); } }
        @media (prefers-reduced-motion: reduce) {
            .cb-loading-spinner .cb-loading-ring, .cb-loading-spinner .cb-loading-coin { animation: none; }
        }
        .cb-loading-text { font-weight: 700; color: var(--text-primary, #1D1D1F); font-size: 0.95rem; }
    

/* ---------- bloque ---------- */

    /* --- Boton hamburguesa (arriba-derecha) --- */
    .cb-menu-hamb {
        position: fixed;
        top: calc(env(safe-area-inset-top, 0px) + 12px);
        right: 14px;
        width: 44px; height: 44px;
        border-radius: 50%;
        background: rgba(0,0,0,0.55);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        color: #fff;
        border: none;
        font-size: 1.15rem;
        cursor: pointer;
        display: flex; align-items: center; justify-content: center;
        z-index: 1003;
        box-shadow: 0 4px 12px rgba(0,0,0,0.28);
        transition: top 0.25s ease, background 0.2s;
    }
    .cb-menu-hamb:hover { background: rgba(0,0,0,0.75); }

    /* --- Panel desplegable del hamburguesa --- */
    .cb-menu-drawer {
        position: fixed;
        top: calc(env(safe-area-inset-top, 0px) + 64px);
        right: 14px;
        min-width: 214px;
        background: var(--bg-card, #fff);
        border-radius: 16px;
        box-shadow: 0 12px 40px rgba(0,0,0,0.28);
        padding: 8px;
        z-index: 1004;
        opacity: 0; visibility: hidden;
        transform: translateY(-8px);
        transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s, top 0.25s ease;
    }
    .cb-menu-drawer.open { opacity: 1; visibility: visible; transform: translateY(0); }
    .cb-menu-drawer a {
        display: flex; align-items: center; gap: 12px;
        padding: 12px 14px;
        border-radius: 10px;
        text-decoration: none;
        color: var(--text-primary, #1D1D1F);
        font-size: 0.92rem; font-weight: 600;
        transition: background 0.15s, color 0.15s;
    }
    .cb-menu-drawer a:hover { background: var(--bg-tertiary, #eee); color: var(--cb-primary); }
    .cb-menu-drawer a i { width: 20px; text-align: center; color: var(--cb-primary); font-size: 1rem; }
    .cb-menu-drawer .cb-drawer-sep { height: 1px; background: var(--border-color, #eee); margin: 6px 6px; }

    /* Backdrop invisible para cerrar al tocar afuera */
    .cb-menu-drawer-backdrop { position: fixed; inset: 0; background: transparent; z-index: 1002; display: none; }
    .cb-menu-drawer-backdrop.open { display: block; }

    /* --- Boton flotante "Ingresa ya!" (DEBAJO del hamburguesa) --- */
    .cb-menu-cta-ingresar {
        position: fixed;
        top: calc(env(safe-area-inset-top, 0px) + 64px);
        right: 14px;
        z-index: 1001;
        display: inline-flex; align-items: center; justify-content: flex-start;
        width: 44px; height: 44px; padding: 0;
        background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
        color: #fff; border-radius: 24px;
        font-size: 0.9rem; font-weight: 800; text-decoration: none;
        box-shadow: 0 6px 18px rgba(0,0,0,0.4), 0 0 0 3px rgba(255,255,255,0.95);
        letter-spacing: 0.3px; overflow: hidden; white-space: nowrap;
        animation: cbMenuCtaCycle 8s ease-in-out infinite;
        isolation: isolate;
        transition: top 0.25s ease;
    }
    .cb-menu-cta-ingresar:hover, .cb-menu-cta-ingresar:focus {
        color: #fff; text-decoration: none;
        background: linear-gradient(135deg, #C2185B 0%, #AD1457 50%, #6A1B9A 100%);
    }
    .cb-menu-cta-ingresar i { flex-shrink: 0; width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; font-size: 1.1rem; }
    .cb-menu-cta-ingresar span {
        display: inline-block; opacity: 0; max-width: 0; padding-right: 0;
        transition: opacity 0.3s ease; overflow: hidden;
        animation: cbMenuCtaText 8s ease-in-out infinite;
    }
    @keyframes cbMenuCtaCycle {
        0%, 10%   { width: 44px; box-shadow: 0 6px 18px rgba(0,0,0,0.4), 0 0 0 3px rgba(255,255,255,0.95); }
        18%, 35%  { width: 165px; box-shadow: 0 8px 26px rgba(216,27,96,0.65), 0 0 0 3px rgba(255,255,255,0.95); }
        45%, 100% { width: 44px; box-shadow: 0 6px 18px rgba(0,0,0,0.4), 0 0 0 3px rgba(255,255,255,0.95); }
    }
    @keyframes cbMenuCtaText {
        0%, 14%   { opacity: 0; max-width: 0; padding-right: 0; }
        18%, 35%  { opacity: 1; max-width: 130px; padding-right: 14px; }
        42%, 100% { opacity: 0; max-width: 0; padding-right: 0; }
    }
    @media (prefers-reduced-motion: reduce) {
        .cb-menu-cta-ingresar { animation: none; width: auto; padding: 0 14px 0 0; }
        .cb-menu-cta-ingresar span { animation: none; opacity: 1; max-width: 130px; padding-right: 4px; }
    }
    @media (min-width: 769px) {
        .cb-menu-hamb, .cb-menu-drawer, .cb-menu-cta-ingresar { right: 24px; }
    }

    /* Al pegarse el header de categorias, bajamos hamburguesa + CTA para que
       no choquen con el (el header sticky mide ~56px). */
    body.cb-header-stuck .cb-menu-hamb { top: calc(env(safe-area-inset-top, 0px) + 70px); }
    body.cb-header-stuck .cb-menu-drawer,
    body.cb-header-stuck .cb-menu-cta-ingresar { top: calc(env(safe-area-inset-top, 0px) + 122px); }

    /* Cliente logueado (barra de saldo visible): el hamburguesa se alinea al
       MISMO nivel que la barra "$… Redimir" para que se vea simetrico. La barra
       mide 48px (44 en movil) y el boton 44px -> lo centramos en ella. */
    body.cb-has-balance-ribbon .cb-menu-hamb { top: calc(env(safe-area-inset-top, 0px) + 6px); }
    body.cb-has-balance-ribbon .cb-menu-drawer { top: calc(env(safe-area-inset-top, 0px) + 58px); }
    @media (max-width: 480px) {
        body.cb-has-balance-ribbon .cb-menu-hamb { top: calc(env(safe-area-inset-top, 0px) + 5px); }
        body.cb-has-balance-ribbon .cb-menu-drawer { top: calc(env(safe-area-inset-top, 0px) + 57px); }
    }

    /* ===== T-QR (DEMO): atajo ACUMULAR — 2 variantes para elegir en reunion ===== */
    /* Variante FLOTANTE (?acum=float): boton flotante abajo-izquierda */
    .cb-acum-fab {
        position: fixed;
        left: 14px;
        bottom: calc(env(safe-area-inset-bottom, 0px) + 16px);
        z-index: 1001;
        display: inline-flex; align-items: center; gap: 8px;
        padding: 12px 18px;
        border-radius: 26px;
        background: linear-gradient(135deg, #FFB300, #FF8F00);
        color: #fff; font-weight: 800; font-size: 0.9rem;
        text-decoration: none;
        box-shadow: 0 6px 18px rgba(255,143,0,0.5), 0 0 0 3px rgba(255,255,255,0.9);
    }
    .cb-acum-fab i { font-size: 1.05rem; }

    /* Variante PAR (?acum=pair): los dos botones ARRIBA, dentro de la barra de
       saldo (donde estaba Redimir). Saldo a la izquierda, chips a la derecha. */
    .cb-balance-ribbon.cb-ribbon-pair {
        justify-content: flex-start;
        gap: 8px;
        padding-right: 62px;  /* espacio para el hamburguesa (arriba-derecha) */
    }
    /* Bloque de saldo: etiqueta "Tu saldo" arriba + monto abajo, para que NO se
       lea "$30.000 Acumular" de corrido (confundia). El monto queda claramente
       identificado como saldo. */
    .cb-ribbon-balance {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        min-width: 0;
        flex-shrink: 1;
    }
    .cb-ribbon-balance-txt {
        display: inline-flex;
        flex-direction: column;
        line-height: 1.05;
        min-width: 0;
    }
    .cb-ribbon-balance-label {
        font-size: 0.62rem;
        font-weight: 700;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        opacity: 0.82;
    }
    .cb-ribbon-pair .ribbon-amount {
        background: none;
        padding: 0;
        font-size: 1rem;
        font-weight: 800;
    }
    .cb-ribbon-pair .cb-ribbon-actions {
        margin-left: auto;
        display: inline-flex;
        gap: 6px;
        flex-shrink: 0;
    }
    .cb-ribbon-chip {
        display: inline-flex; align-items: center; gap: 5px;
        background: #fff;
        padding: 6px 12px;
        border-radius: 13px;
        font-weight: 800;
        font-size: 0.78rem;
        text-decoration: none;
        box-shadow: 0 2px 8px rgba(0,0,0,0.22);
        white-space: nowrap;
    }
    .cb-ribbon-chip.cb-chip-acum { color: #E65100; }
    .cb-ribbon-chip.cb-chip-redeem { color: var(--cb-magenta-dark); }
    @media (max-width: 380px) {
        .cb-ribbon-pair .ribbon-amount { font-size: 0.92rem; }
        .cb-ribbon-balance-label { font-size: 0.58rem; }
        .cb-balance-ribbon.cb-ribbon-pair { gap: 6px; }
        .cb-ribbon-chip { padding: 6px 9px; font-size: 0.74rem; gap: 4px; }
        /* En pantallas chicas el chip Acumular muestra solo "📷 10%" para dejar
           sitio a Redimir + hamburguesa sin desbordar. */
        .cb-chip-verb { display: none; }
    }

/* ---------- bloque ---------- */

    .cb-welcome {
        position: relative;
        width: 100%;
        /* T-QR: la portada ocupa EXACTO el alto del dispositivo. 100dvh se adapta
           solo a la barra del navegador movil ("se acomoda siempre al dispositivo").
           Layout en columna -> la FOTO de portada pega a sangre en el borde superior
           (el hamburguesa flotante queda encima de ella) y "Desliza para ver el menu"
           se ancla al borde inferior. Al ser flex-column ademas, "Siguenos" y el
           nivel (Cliente VIP/Regular/…) caen cada uno en su propia fila (antes iban
           en la misma linea). Se aplica logueado y no. */
        min-height: 100vh;
        min-height: 100dvh;
        display: flex;
        flex-direction: column;
        align-items: center;
        background: var(--bg-page, #1a1a1a);
        color: var(--text-primary, #fff);
        text-align: center;
        padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 14px);
    }
    .cb-welcome-cover {
        position: relative;
        width: 100%;
        /* La foto llega hasta la MITAD del dispositivo (50dvh). El logo solapa su
           borde inferior, asi que queda tambien sobre la linea media. Pega arriba a
           sangre (sin margin-top:auto); el hamburguesa flotante va encima. */
        height: 50vh;
        height: 50dvh;
        flex-shrink: 0;
        overflow: hidden;
        background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
    }
    .cb-welcome-cover::after {
        content: '';
        position: absolute;
        bottom: 0; left: 0; right: 0; height: 80px;
        background: linear-gradient(transparent, var(--bg-page, #1a1a1a));
        pointer-events: none;
    }
    .cb-welcome-cover img {
        width: 100%; height: 100%;
        object-fit: cover; display: block;
    }
    /* T32: Wrapper del logo con halo rosa-morado + lineas fading.
       El halo es un semi-circulo glow detras de la mitad inferior del logo,
       acompanado de dos lineas horizontales que salen del centro hacia los
       lados y se desvanecen antes de llegar a los bordes. Esto da identidad
       ComBack a cualquier logo, sin importar los colores del comercio. */
    .cb-welcome-logo-wrap {
        position: relative;
        margin: -80px auto 14px;
        width: 140px;
        /* Reservamos altura: 140 logo + 30 extra para que el halo no rompa el flow */
        height: 170px;
        z-index: 2;
        /* Permite que ::before/::after se vean fuera del logo */
        overflow: visible;
    }
    /* Semi-circulo de glow rosa-morado detras del logo (mitad inferior) */
    .cb-welcome-logo-wrap::before {
        content: '';
        position: absolute;
        left: 50%;
        bottom: 14px;
        width: 170px;
        height: 100px; /* solo mitad inferior */
        transform: translateX(-50%);
        border-radius: 0 0 100px 100px;
        background: radial-gradient(ellipse at center top,
            rgba(111, 66, 193, 0.55) 0%,
            rgba(111, 66, 193, 0.35) 35%,
            rgba(255, 45, 146, 0.25) 65%,
            transparent 85%);
        filter: blur(6px);
        pointer-events: none;
        z-index: 0;
    }
    /* Lineas horizontales que salen del centro EXACTO del logo y se desvanecen.
       wrap height = 170px, logo height = 140px → centro del logo a 70px del top
       = 170-70 = 100px desde el bottom del wrap. */
    .cb-welcome-logo-wrap::after {
        content: '';
        position: absolute;
        left: 50%;
        bottom: 100px; /* centro vertical del logo */
        width: 90vw;
        max-width: 520px;
        height: 2px;
        transform: translateX(-50%);
        background: linear-gradient(90deg,
            transparent 0%,
            rgba(111, 66, 193, 0.35) 25%,
            rgba(255, 45, 146, 0.65) 50%,
            rgba(111, 66, 193, 0.35) 75%,
            transparent 100%);
        filter: blur(0.8px);
        pointer-events: none;
        z-index: 0;
    }
    .cb-welcome-logo {
        position: relative;
        margin: 0 auto;
        width: 140px; height: 140px;
        border-radius: 50%;
        background: #1a1a1a;
        border: 4px solid var(--bg-page, #1a1a1a);
        box-shadow: 0 8px 30px rgba(0,0,0,0.4),
                    0 0 0 1px rgba(255, 45, 146, 0.25); /* anillo sutil rosa */
        display: flex; align-items: center; justify-content: center;
        overflow: hidden;
        z-index: 2; /* sobre el halo y la linea */
    }
    .cb-welcome-logo img { width: 100%; height: 100%; object-fit: cover; }
    .cb-welcome-logo span { color: #fff; font-weight: 800; font-size: 3rem; }
    /* Logo RECTANGULAR (horizontal/vertical): el contenedor se ajusta EXACTO al
       logo (fit-content) y redondeamos las esquinas con overflow hidden -> esquinas
       limpias, SIN el borde claro (que salia por las bandas transparentes del
       contain). Sin marco ni fondo extra.
       Dinamico y universal: cualquier comercio con logo no-cuadrado. */
    .cb-welcome-logo-wrap.logo-rect { width: auto; min-width: 140px; height: auto; }
    .cb-welcome-logo-wrap.logo-rect .cb-welcome-logo {
        display: block;
        width: fit-content;
        max-width: 240px;
        height: auto;
        margin: 0 auto;
        background: transparent;
        border: none;
        box-shadow: none;
        border-radius: 16px;   /* esquinas sutiles */
        overflow: hidden;
    }
    .cb-welcome-logo-wrap.logo-rect .cb-welcome-logo img {
        width: auto;
        height: auto;
        max-width: 240px;
        max-height: 150px;
        object-fit: contain;
        display: block;
    }
    /* El haz de luz (halo + linea) SOLO cuadra con logos redondos/cuadrados.
       En rectangulares lo ocultamos para que no se vea forzado. */
    .cb-welcome-logo-wrap.logo-rect::before,
    .cb-welcome-logo-wrap.logo-rect::after {
        display: none;
    }

    /* Bloque inferior: nombre, redes, mensaje y boton. Ocupa (flex:1) el ~40%
       restante bajo la foto+logo y centra ahi su contenido, conservando el mismo
       estilo/espaciado de siempre. El indicador "Desliza…" queda debajo, al borde. */
    .cb-welcome-info {
        flex: 1 1 auto;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 100%;
    }
    .cb-welcome-name {
        font-family: 'Playfair Display', serif;
        font-weight: 800;
        font-size: 1.6rem;
        color: var(--text-primary);
        margin: 0 0 4px;
        letter-spacing: 0.5px;
    }
    .cb-welcome-branch {
        font-size: 0.85rem;
        color: var(--text-secondary, #888);
        margin-bottom: 10px;
    }
    .cb-welcome-social {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 6px 14px;
        background: rgba(0,200,150,0.12);
        border-radius: 20px;
        color: #25D366;
        text-decoration: none;
        font-size: 0.85rem;
        font-weight: 700;
        margin-bottom: 10px;
    }
    .cb-welcome-social:hover { color: #25D366; text-decoration: none; opacity: 0.85; }

    .cb-welcome-pill {
        display: inline-block;
        font-size: 0.72rem;
        font-weight: 800;
        letter-spacing: 1px;
        text-transform: uppercase;
        color: var(--text-muted, #999);
        margin-bottom: 10px;
    }
    .cb-welcome-message {
        max-width: 380px;
        margin: 0 auto 8px;
        padding: 0 18px;
    }
    .cb-welcome-message h2 {
        font-family: 'Playfair Display', serif;
        font-size: 1.45rem;
        font-weight: 800;
        line-height: 1.25;
        color: var(--text-primary);
        margin: 0 0 6px;
    }
    .cb-welcome-message .cb-rate {
        background: linear-gradient(135deg, var(--cb-primary) 60%, var(--cb-magenta) 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }
    .cb-welcome-sub {
        max-width: 380px;
        margin: 0 auto 14px;
        padding: 0 22px;
        font-size: 0.92rem;
        color: var(--text-secondary, #aaa);
        line-height: 1.5;
    }
    .cb-welcome-fine {
        max-width: 380px;
        margin: 0 auto;
        padding: 0 22px;
        font-size: 0.78rem;
        color: var(--text-muted, #666);
        line-height: 1.4;
    }
    .cb-welcome-vip-crown {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 4px 14px;
        background: linear-gradient(135deg, #FFD700, #FFA000);
        color: #1a1a1a;
        font-size: 0.72rem;
        font-weight: 800;
        letter-spacing: 1px;
        border-radius: 20px;
        margin-bottom: 10px;
        text-transform: uppercase;
    }
    .cb-welcome-balance {
        /* T36: stack vertical — siempre en su propia linea, centrado, mas prominente */
        display: block;
        width: max-content;
        max-width: 90%;
        margin: 12px auto 4px;
        padding: 10px 22px;
        background: linear-gradient(135deg, rgba(111,66,193,0.16) 60%, rgba(255,45,146,0.16) 100%);
        color: var(--cb-primary);
        border-radius: 16px;
        font-weight: 800;
        font-size: 1.1rem;
        box-shadow: 0 4px 14px rgba(111,66,193,0.18);
        border: 1.5px solid rgba(111,66,193,0.18);
    }

    .cb-welcome-scroll-indicator {
        /* Anclado al borde inferior del dispositivo: el margin-top:auto absorbe el
           espacio libre y, junto con el de .cb-welcome-cover, centra la imagen+logo
           en la mitad de la pantalla. */
        margin-top: auto;
        cursor: pointer;
        /* Bloque a todo el ancho, en su propia linea (no inline junto al boton) */
        display: flex;
        width: 100%;
        flex-direction: column;
        align-items: center;
        color: var(--text-muted, #888);
        font-size: 0.75rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 1px;
        opacity: 0.85;
        animation: cbWelcomeBounce 2s ease-in-out infinite;
    }
    .cb-welcome-scroll-indicator:hover { color: var(--cb-primary); }
    .cb-welcome-scroll-indicator i {
        margin-top: 4px;
        font-size: 1.1rem;
    }
    @keyframes cbWelcomeBounce {
        0%, 100% { transform: translateY(0); }
        50% { transform: translateY(6px); }
    }
    @media (prefers-reduced-motion: reduce) {
        .cb-welcome-scroll-indicator { animation: none; }
    }
    /* T-QR: CTA de registro en la portada (reemplaza los 2 labels grises).
       Sutil pero visible: mas pequeno, sin pulso, sombra suave. */
    .cb-welcome-register-btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        margin-top: 6px;
        margin-bottom: 8px;
        padding: 11px 22px;
        border-radius: 24px;
        background: linear-gradient(135deg, var(--cb-primary), var(--cb-magenta-dark));
        color: #fff;
        font-weight: 700;
        font-size: 0.92rem;
        text-decoration: none;
        letter-spacing: 0.2px;
        box-shadow: 0 4px 14px rgba(111,66,193,0.3);
        transition: transform 0.15s, box-shadow 0.15s;
    }
    .cb-welcome-register-btn:hover {
        color: #fff;
        text-decoration: none;
        transform: translateY(-1px);
        box-shadow: 0 6px 18px rgba(111,66,193,0.42);
    }
    .cb-welcome-register-btn i { font-size: 1rem; opacity: 0.95; }
    @media (min-width: 769px) {
        .cb-welcome-cover { height: 50vh; height: 50dvh; }
        .cb-welcome-logo-wrap { width: 160px; height: 195px; margin-top: -90px; }
        .cb-welcome-logo { width: 160px; height: 160px; }
        .cb-welcome-logo-wrap::before {
            width: 200px; height: 115px; bottom: 17px;
            border-radius: 0 0 110px 110px;
        }
        /* Desktop: wrap 195px, logo 160px → centro a 80px del top = 115px del bottom */
        .cb-welcome-logo-wrap::after { bottom: 115px; max-width: 640px; }
        .cb-welcome-name { font-size: 1.9rem; }
        .cb-welcome-message h2 { font-size: 1.7rem; }
    }

/* ---------- bloque ---------- */

    .cb-menu-popup-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.75);
        z-index: 9990;
        display: none;
        align-items: center;
        justify-content: center;
        padding: 20px;
    }
    .cb-menu-popup-overlay.active { display: flex; animation: cbPopupFade 0.3s ease-out; }
    @keyframes cbPopupFade { from { opacity: 0; } to { opacity: 1; } }
    .cb-menu-popup-card {
        background: var(--bg-card, #fff);
        border-radius: 18px;
        max-width: 420px;
        width: 100%;
        overflow: hidden;
        box-shadow: 0 20px 60px rgba(0,0,0,0.4);
        position: relative;
        animation: cbPopupSlide 0.3s ease-out;
    }
    @keyframes cbPopupSlide {
        from { transform: scale(0.92) translateY(20px); opacity: 0; }
        to { transform: scale(1) translateY(0); opacity: 1; }
    }
    .cb-menu-popup-card img { width: 100%; max-height: 380px; object-fit: cover; display: block; }
    .cb-menu-popup-body { padding: 18px 20px; text-align: center; }
    .cb-menu-popup-body h3 {
        font-family: 'Playfair Display', serif;
        font-size: 1.3rem;
        margin: 0 0 6px;
        color: var(--text-primary, #2D2D2D);
    }
    .cb-menu-popup-body p { color: var(--text-secondary, #888); font-size: 0.88rem; margin: 0; }
    .cb-menu-popup-close {
        position: absolute;
        top: 10px; right: 10px;
        width: 34px; height: 34px;
        border-radius: 50%;
        background: rgba(0,0,0,0.55);
        color: #fff;
        border: none;
        cursor: pointer;
        font-size: 1.1rem;
    }

/* ---------- bloque ---------- */

    .cb-loading-overlay {
        position: fixed;
        inset: 0;
        /* Fondo OPACO (color de pagina segun tema) para tapar por completo el
           contenido detras mientras carga. */
        background: var(--bg-page, #000);
        z-index: 100000;
        display: none;
        align-items: center;
        justify-content: center;
    }
    .cb-loading-overlay.active { display: flex; animation: cbLoadFade 0.15s ease-out; }
    @keyframes cbLoadFade { from { opacity: 0; } to { opacity: 1; } }
    .cb-loading-box {
        background: var(--bg-card, #fff);
        border-radius: 18px;
        padding: 26px 32px;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 14px;
        box-shadow: 0 20px 60px rgba(0,0,0,0.4);
    }
    .cb-loading-spinner {
        position: relative;
        width: 54px; height: 54px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    /* Anillo que gira (rapido) */
    .cb-loading-spinner .cb-loading-ring {
        position: absolute;
        inset: 0;
        border: 4px solid var(--border-color, #e0e0e0);
        border-top-color: var(--cb-primary);
        border-radius: 50%;
        animation: cbLoadSpin 0.8s linear infinite;
    }
    @keyframes cbLoadSpin { to { transform: rotate(360deg); } }
    /* Moneda dorada al centro, girando LENTO (personalidad) */
    .cb-loading-spinner .cb-loading-coin {
        width: 28px; height: 28px;
        border-radius: 50%;
        background: radial-gradient(circle at 32% 28%, #FFE9A8, #FFC107 58%, #E67E00 100%);
        box-shadow:
            inset 0 -2px 4px rgba(0,0,0,0.30),
            inset 0 2px 2px rgba(255,255,255,0.5);
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--cb-primary);
        font-weight: 900;
        font-family: Arial, sans-serif;
        font-size: 17px;
        animation: cbLoadCoinSpin 2.6s ease-in-out infinite;
    }
    .cb-loading-spinner .cb-loading-coin::before { content: '$'; line-height: 1; }
    @keyframes cbLoadCoinSpin {
        0%   { transform: rotateY(0deg); }
        100% { transform: rotateY(360deg); }
    }
    @media (prefers-reduced-motion: reduce) {
        .cb-loading-spinner .cb-loading-ring,
        .cb-loading-spinner .cb-loading-coin { animation: none; }
    }
    .cb-loading-text { font-weight: 700; color: var(--text-primary, #1D1D1F); font-size: 0.95rem; }
    /* Desvanecido SUAVE del landing cuando la pagina ya cargo (idea del usuario:
       landing al frente, la pagina carga detras, y al terminar se funde suave). */
    .cb-loading-overlay { transition: opacity 0.4s ease; }
    .cb-loading-overlay.cb-fade-out { opacity: 0; pointer-events: none; }
