/* Reset y Variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --secondary-color: #f59e0b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --dark-color: #1f2937;
    --light-color: #f9fafb;
    --border-color: #e5e7eb;
    --text-primary: #111827;
    --text-secondary: #6b7280;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Modo Oscuro - Versión mejorada y explícita */
[data-theme="dark"] {
    --primary-color: #3b82f6;
    --secondary-color: #f59e0b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --dark-color: #111827;
    --light-color: #1f2937;
    --border-color: #374151;
    --text-primary: #f9fafb;
    --text-secondary: #d1d5db;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
}

/* Estilos directos para modo oscuro (fallback) - VERSIÓN MEJORADA */
body[data-theme="dark"] {
    background-color: #1f2937 !important;
    color: #f9fafb !important;
}

/* Agregar soporte para clase .dark-mode (como en la prueba que funciona) */
body.dark-mode {
    background-color: #1f2937 !important;
    color: white !important;
}

body[data-theme="dark"] .container,
body.dark-mode .container {
    background-color: #1f2937 !important;
}

body[data-theme="dark"] h1,
body[data-theme="dark"] h2,
body[data-theme="dark"] h3,
body[data-theme="dark"] h4,
body[data-theme="dark"] h5,
body[data-theme="dark"] h6,
body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3,
body.dark-mode h4,
body.dark-mode h5,
body.dark-mode h6 {
    color: #f9fafb !important;
}

body[data-theme="dark"] p,
body.dark-mode p {
    color: #d1d5db !important;
}

body[data-theme="dark"] .header-nav,
body.dark-mode .header-nav,
body[data-theme="dark"] .header-nav > .container,
body.dark-mode .header-nav > .container {
    background-color: var(--header-bg-dark, #1f2937) !important;
    background-image: none !important;
}

body[data-theme="dark"] .header-nav,
body.dark-mode .header-nav {
    border-bottom-color: var(--header-border-dark, #374151) !important;
}

body[data-theme="dark"] .header-nav .logo h1,
body.dark-mode .header-nav .logo h1 {
    color: var(--header-logo-dark, #f9fafb) !important;
}

body[data-theme="dark"] .categories-nav,
body.dark-mode .categories-nav {
    background-color: var(--header-bg-dark, #1f2937) !important;
}

body[data-theme="dark"] .category-link,
body.dark-mode .category-link {
    color: var(--header-link-dark, #d1d5db) !important;
    background-color: var(--header-link-bg-dark, #374151) !important;
}

body[data-theme="dark"] .category-link:hover,
body[data-theme="dark"] .category-link.active,
body.dark-mode .category-link:hover,
body.dark-mode .category-link.active {
    background-color: var(--header-link-active-bg-dark, #4b5563) !important;
    color: var(--header-link-active-dark, #f9fafb) !important;
}

body[data-theme="dark"] .promo-banner,
body.dark-mode .promo-banner {
    background: linear-gradient(135deg, #374151, #4b5563) !important;
}

body[data-theme="dark"] .promo-banner.promo-banner--bg-image,
body.dark-mode .promo-banner.promo-banner--bg-image {
    background-color: #374151 !important;
    background-image: var(--promo-bg-image) !important;
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

body[data-theme="dark"] .product-card,
body.dark-mode .product-card {
    background-color: #374151 !important;
    border-color: #4b5563 !important;
    color: #f9fafb !important;
}

body[data-theme="dark"] .product-title,
body.dark-mode .product-title {
    color: #f9fafb !important;
}

body[data-theme="dark"] .product-description,
body.dark-mode .product-description {
    color: #d1d5db !important;
}

body[data-theme="dark"] .product-price,
body.dark-mode .product-price {
    color: #10b981 !important;
}

body[data-theme="dark"] .add-to-cart-btn,
body.dark-mode .add-to-cart-btn {
    background-color: #3b82f6 !important;
    color: white !important;
}

body[data-theme="dark"] .add-to-cart-btn:hover,
body.dark-mode .add-to-cart-btn:hover {
    background-color: #2563eb !important;
}

body[data-theme="dark"] .footer,
body.dark-mode .footer {
    background-color: #111827 !important;
    color: #d1d5db !important;
}

body[data-theme="dark"] .theme-toggle,
body.dark-mode .theme-toggle {
    background: #3b82f6 !important;
}

body[data-theme="dark"] .floating-cart-btn,
body[data-theme="dark"] .floating-waiter-btn,
body[data-theme="dark"] .floating-whatsapp-btn,
body[data-theme="dark"] .floating-maps-btn,
body.dark-mode .floating-cart-btn,
body.dark-mode .floating-waiter-btn,
body.dark-mode .floating-whatsapp-btn,
body.dark-mode .floating-maps-btn {
    background-color: #374151 !important;
    color: #f9fafb !important;
}

body[data-theme="dark"] .floating-cart-btn:hover,
body[data-theme="dark"] .floating-waiter-btn:hover,
body[data-theme="dark"] .floating-whatsapp-btn:hover,
body[data-theme="dark"] .floating-maps-btn:hover,
body.dark-mode .floating-cart-btn:hover,
body.dark-mode .floating-waiter-btn:hover,
body.dark-mode .floating-whatsapp-btn:hover,
body.dark-mode .floating-maps-btn:hover {
    background-color: #4b5563 !important;
}

body[data-theme="dark"] .floating-whatsapp-btn,
body.dark-mode .floating-whatsapp-btn {
    background-color: #059669 !important;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--light-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: var(--transition);
}

/* Toggle de Modo Oscuro — en el header (no fixed encima de la hamburguesa) */
.theme-toggle {
    position: relative;
    top: auto;
    right: auto;
    background: var(--primary-color);
    border: none;
    border-radius: 50%;
    width: 2.5rem;
    height: 2.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
    flex: 0 0 auto;
    margin-left: auto;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.theme-toggle:hover {
    transform: scale(1.06);
    box-shadow: var(--shadow-md);
}

.theme-toggle svg {
    width: 1.15rem;
    height: 1.15rem;
    color: white;
    transition: var(--transition);
}

.theme-toggle .sun-icon {
    display: block;
}

.theme-toggle .moon-icon {
    display: none;
}

[data-theme="dark"] .theme-toggle .sun-icon,
body.dark-mode .theme-toggle .sun-icon {
    display: none;
}

[data-theme="dark"] .theme-toggle .moon-icon,
body.dark-mode .theme-toggle .moon-icon {
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header de Navegación */
.header-nav,
.header-nav > .container {
    background-color: var(--header-bg, var(--light-color));
    background-image: none;
}

.header-nav {
    position: var(--header-position, sticky);
    top: 0;
    border-bottom: 1px solid var(--header-border, var(--border-color));
    z-index: 100;
    box-shadow: var(--header-shadow, var(--shadow-sm));
    transition: var(--transition);
}

.header-nav .logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}

.header-nav .logo:hover {
    color: var(--primary-color);
}

.category-nav {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) transparent;
}

.category-nav::-webkit-scrollbar {
    height: 6px;
}

.category-nav::-webkit-scrollbar-track {
    background: transparent;
}

.category-nav::-webkit-scrollbar-thumb {
    background-color: var(--border-color);
    border-radius: 3px;
}

.category-item {
    list-style: none;
    white-space: nowrap;
}

.category-link {
    display: block;
    padding: 0.75rem 1.5rem;
    color: var(--header-link, var(--text-secondary));
    text-decoration: none;
    border-radius: var(--radius-lg);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.category-link:hover,
.category-link.active {
    color: var(--header-link-active, var(--primary-color));
    background: var(--header-link-active-bg, rgba(37, 99, 235, 0.1));
}

.category-link.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.header-nav .container {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 1rem;
    gap: 0.75rem;
}

.header-nav .logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.header-nav-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    width: 100%;
    position: relative;
}

/* Hamburguesa categorías: solo visible en responsive */
.categories-hamburger {
    display: none;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid var(--border-color);
    background: var(--light-color);
    color: var(--text-primary);
    border-radius: var(--radius-md);
    padding: 0.4rem 0.65rem;
    cursor: pointer;
    flex: 0 0 auto;
    margin-left: 0.35rem;
    transition: var(--transition);
}

.categories-hamburger:hover,
.categories-hamburger[aria-expanded="true"] {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.categories-hamburger-box {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
    width: 18px;
    height: 14px;
}

.categories-hamburger-line {
    display: block;
    height: 2px;
    width: 100%;
    background: currentColor;
    border-radius: 1px;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.categories-hamburger[aria-expanded="true"] .categories-hamburger-line:nth-child(1) {
    transform: translateY(5px) rotate(45deg);
}

.categories-hamburger[aria-expanded="true"] .categories-hamburger-line:nth-child(2) {
    opacity: 0;
}

.categories-hamburger[aria-expanded="true"] .categories-hamburger-line:nth-child(3) {
    transform: translateY(-5px) rotate(-45deg);
}

.categories-hamburger-text {
    font-size: 0.8rem;
    font-weight: 600;
    max-width: 7.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--header-logo, var(--primary-color));
    white-space: nowrap;
}

.categories-nav {
    flex: 1;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

/* Toolbar buscador + ordenar (debajo de categorías) */
.catalog-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1.25rem;
    width: 100%;
    padding: 0.35rem 0 0.15rem;
    border-top: 1px solid var(--header-border, var(--border-color));
}

.catalog-search-wrap {
    flex: 1 1 auto;
    min-width: 180px;
    max-width: 420px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 0.4rem 0.75rem;
    min-height: 2.5rem;
    height: 2.5rem;
    max-height: 2.75rem;
    box-sizing: border-box;
    transition: var(--transition);
}

.catalog-search-wrap:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.catalog-search-icon {
    color: var(--text-secondary);
    display: flex;
    flex-shrink: 0;
    align-items: center;
    line-height: 0;
}

.catalog-search-input {
    flex: 1 1 auto;
    border: none;
    background: transparent;
    color: var(--text-primary);
    font-size: 0.95rem;
    outline: none;
    min-width: 0;
    min-height: 0;
    height: 1.5rem;
    line-height: 1.5rem;
    padding: 0;
    margin: 0;
    -webkit-appearance: none;
    appearance: none;
}

.catalog-search-input::-webkit-search-decoration,
.catalog-search-input::-webkit-search-cancel-button,
.catalog-search-input::-webkit-search-results-button,
.catalog-search-input::-webkit-search-results-decoration {
    -webkit-appearance: none;
}

.catalog-search-input::placeholder {
    color: var(--text-secondary);
}

.catalog-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 0 0 auto;
}

.catalog-offers-btn {
    display: inline-flex;
    align-items: center;
    height: 1.85rem;
    padding: 0 0.65rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--light-color);
    color: var(--text-primary);
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    white-space: nowrap;
}

.catalog-offers-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.catalog-offers-btn.is-active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

.catalog-offers-empty {
    margin: 1.5rem 0;
    text-align: center;
    color: var(--text-secondary);
}

.catalog-sort {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 0 0 auto;
}

.catalog-sort-label {
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 500;
}

.catalog-sort-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: none;
    background: transparent;
    color: var(--primary-color);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0.25rem 0.15rem;
}

.catalog-sort-trigger:hover {
    opacity: 0.85;
}

.catalog-sort-caret {
    transition: transform 0.2s ease;
}

.catalog-sort.is-open .catalog-sort-caret {
    transform: rotate(180deg);
}

.catalog-sort-menu {
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 0;
    min-width: 200px;
    margin: 0;
    padding: 0.35rem 0;
    list-style: none;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 40;
}

body[data-theme="dark"] .catalog-sort-menu,
body.dark-mode .catalog-sort-menu {
    background: #1f2937;
}

.catalog-sort-menu[hidden] {
    display: none !important;
}

.catalog-sort-menu li {
    padding: 0.65rem 1rem 0.65rem 1.15rem;
    cursor: pointer;
    color: var(--text-primary);
    font-size: 0.95rem;
    border-left: 3px solid transparent;
    border-bottom: 1px solid var(--border-color);
}

.catalog-sort-menu li:last-child {
    border-bottom: none;
}

.catalog-sort-menu li:hover {
    background: rgba(37, 99, 235, 0.06);
}

.catalog-sort-menu li.is-active {
    color: var(--primary-color);
    font-weight: 600;
    border-left-color: var(--primary-color);
}

@media (max-width: 768px) {
    .header-nav-top {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 0.5rem;
        flex: 0 0 auto;
    }

    .header-nav-top .logo {
        flex: 1 1 auto;
        min-width: 0;
        order: 1;
    }

    .header-nav-top .theme-toggle {
        margin-left: 0.25rem;
        width: 2.25rem;
        height: 2.25rem;
        order: 2;
    }

    .categories-hamburger {
        display: inline-flex;
        order: 3;
        margin-left: 0.25rem;
    }

    .header-nav-top .categories-nav {
        display: none;
        flex: 0 0 auto;
        width: 100%;
        order: 4;
        overflow: visible;
        margin-top: 0.15rem;
    }

    .header-nav-top.is-categories-open .categories-nav {
        display: block;
    }

    .header-nav-top .categories-list {
        flex-direction: column;
        align-items: stretch;
        white-space: normal;
        gap: 0.25rem;
        padding: 0.35rem;
        background: #fff;
        border: 1px solid var(--border-color);
        border-radius: var(--radius-md);
        box-shadow: var(--shadow-md);
        max-height: min(55vh, 320px);
        overflow-y: auto;
    }

    body[data-theme="dark"] .header-nav-top .categories-list,
    body.dark-mode .header-nav-top .categories-list {
        background: #1f2937;
    }

    .header-nav-top .category-link {
        width: 100%;
        text-align: left;
        white-space: normal;
    }

    .catalog-toolbar {
        flex-direction: column;
        align-items: stretch;
        flex: 0 0 auto;
        gap: 0.45rem;
        padding: 0.25rem 0 0;
    }

    .catalog-search-wrap {
        flex: 0 0 auto;
        width: 100%;
        max-width: none;
        min-width: 0;
        height: 2.4rem;
        min-height: 2.4rem;
        max-height: 2.4rem;
        padding: 0.3rem 0.65rem;
    }

    .catalog-search-input {
        font-size: 0.875rem;
        height: 1.35rem;
        line-height: 1.35rem;
    }

    .catalog-toolbar-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .catalog-sort {
        justify-content: flex-end;
        width: auto;
        flex: 0 1 auto;
        min-height: 0;
    }

    .catalog-sort-menu {
        left: 0;
        right: auto;
        width: 100%;
    }

    /* Solo WhatsApp + carrito; ocultar teléfono (mesero) y ubicación */
    .floating-waiter-btn,
    .floating-maps-btn {
        display: none !important;
    }

    .floating-cart-btn,
    .floating-whatsapp-btn {
        width: 3rem;
        height: 3rem;
        right: 1rem;
    }

    /* Mantener posición actual (antes de quitar mapa/teléfono) */
    .floating-cart-btn {
        bottom: 4.5rem;
    }

    .floating-whatsapp-btn {
        bottom: 8rem;
    }
}

.categories-nav::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
}

.categories-list {
    display: flex;
    gap: 0.5rem;
    list-style: none;
    white-space: nowrap;
    padding: 0.5rem 0;
}

.category-link {
    display: block;
    padding: 0.75rem 1.5rem;
    background: var(--light-color);
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 500;
    font-size: 0.875rem;
    transition: var(--transition);
    border: 1px solid transparent;
    white-space: nowrap;
}

.category-link:hover,
.category-link.active {
    background: var(--primary-color);
    color: white;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Banner Promocional / Carrusel ofertas item_price — layout mockup */
.promo-banner {
    background: linear-gradient(135deg, var(--secondary-color), #ea580c 55%, #dc2626);
    color: white;
    padding: 0;
    text-align: left;
    position: relative;
    overflow: hidden;
}

/* Fondo por imagen de tenant (carrusel_{sid}.png); si no hay archivo, queda el degradado */
.promo-banner--bg-image {
    background-color: var(--secondary-color);
    background-image: var(--promo-bg-image);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.promo-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.18), transparent);
    animation: shimmer 3s infinite;
    pointer-events: none;
}

@keyframes shimmer {
    100% { left: 100%; }
}

.promo-carousel {
    position: relative;
    z-index: 1;
    max-width: 64rem;
    margin: 0 auto;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    container-type: inline-size;
    container-name: promo;
}

.promo-slides {
    position: relative;
    min-height: 18rem;
}

.promo-slide {
    display: none;
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 0;
    animation: promoFade 0.4s ease;
    min-height: 18rem;
    position: relative;
    overflow: hidden;
}

.promo-slide.is-active {
    display: grid;
}

.promo-slide--own-bg {
    background-color: var(--secondary-color);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.promo-slide-visual {
    position: relative;
    z-index: 1;
    display: block;
    width: 100%;
    min-height: 14rem;
    height: 100%;
    overflow: hidden;
    background: transparent;
}

/* Marca de agua: 80% del carrusel, independiente del tamaño de la imagen */
.promo-watermark {
    position: absolute;
    left: 50%;
    top: 46%;
    transform: translate(-50%, -50%);
    width: 80%;
    max-width: 80%;
    margin: 0;
    padding: 0;
    text-align: center;
    font-size: clamp(1.35rem, 9cqi, 4.75rem);
    font-weight: 800;
    letter-spacing: 0.04em;
    line-height: 1;
    color: transparent;
    -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.28);
    text-stroke: 1.5px rgba(255, 255, 255, 0.28);
    white-space: nowrap;
    overflow: visible;
    pointer-events: none;
    user-select: none;
    z-index: 0;
}

.promo-product-img {
    position: relative;
    z-index: 1;
    display: block;
    width: 100%;
    height: 100%;
    min-height: 14rem;
    object-fit: contain;
    object-position: center;
    filter: none;
    box-shadow: none;
}

.promo-slide-body {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 0.4rem;
    width: 100%;
    text-align: left;
    padding: 1.1rem 1.25rem 1.25rem;
}

@keyframes promoFade {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.promo-badge {
    display: inline-block;
    background: rgba(255,255,255,0.22);
    padding: 0.3rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    backdrop-filter: blur(10px);
}

.promo-title,
.promo-banner h2.promo-title {
    font-size: clamp(1.15rem, 3.5vw, 1.65rem);
    font-weight: 800;
    margin: 0;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 0.01em;
}

.promo-product-name {
    margin: 0;
    opacity: 0.92;
    font-size: 0.95rem;
    font-weight: 500;
}

.promo-prices {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.15rem;
}

.promo-price-old {
    text-decoration: line-through;
    opacity: 0.72;
    font-size: 0.95rem;
}

.promo-price-now {
    font-size: clamp(1.35rem, 4vw, 1.75rem);
    font-weight: 800;
}

.promo-validity {
    margin: 0.1rem 0 0;
    font-size: 0.8rem;
    opacity: 0.88;
}

/* Variantes en banner: mismo patrón card, contraste sobre naranja */
.product-variants--promo {
    margin: 0.35rem 0 0.15rem;
    width: 100%;
}

.product-variants--promo .product-unit {
    background: rgba(255, 255, 255, 0.22);
    color: #fff;
}

.product-variants--promo .color-swatch {
    border: 2px solid rgba(255, 255, 255, 0.85);
    cursor: pointer;
    padding: 0;
}

.product-variants--promo .color-swatch.is-selected {
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px rgba(0, 0, 0, 0.25);
}

.product-variants--promo .size-chip {
    border: 1.5px solid #fff;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    box-shadow: none;
    cursor: pointer;
}

.product-variants--promo .size-chip.is-selected {
    background: #fff;
    color: #c2410c;
}

.promo-cart-actions {
    margin-top: 0.5rem;
}

.promo-banner .add-to-cart-btn--icon {
    background: #fff;
    border-color: transparent;
    color: var(--text-primary, #111);
    width: 2.75rem;
    height: 2.75rem;
}

.promo-banner .add-to-cart-btn--icon:hover {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

.promo-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 0.65rem 1rem 1rem;
}

.promo-nav {
    width: 2.15rem;
    height: 2.15rem;
    border: 1.5px solid rgba(255,255,255,0.55);
    background: transparent;
    color: white;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.25rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.promo-nav:hover {
    background: rgba(255,255,255,0.2);
}

.promo-dots {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.promo-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    border: none;
    padding: 0;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: width 0.2s ease, background 0.2s ease;
}

.promo-dot.is-active {
    background: white;
    width: 1.15rem;
    border-radius: 9999px;
}

@media (min-width: 768px) {
    .promo-slides {
        min-height: 20rem;
    }

    .promo-slide {
        min-height: 20rem;
    }

    .promo-slide.is-active {
        grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    }

    .promo-slide-visual {
        min-height: 20rem;
        align-self: stretch;
    }

    .promo-product-img {
        min-height: 20rem;
        position: absolute;
        inset: 0;
        z-index: 1;
    }

    .promo-watermark {
        top: 48%;
        font-size: clamp(1.75rem, 8.5cqi, 5.25rem);
    }

    .promo-slide-visual {
        position: relative;
        z-index: 1;
    }

    .promo-slide-body {
        padding: 1.5rem 1.75rem;
    }

    .promo-controls {
        justify-content: flex-start;
        padding-left: calc(53% + 0.5rem);
    }
}

.promo-content {
    position: relative;
    z-index: 1;
}

.promo-banner p {
    font-size: inherit;
    opacity: inherit;
}

/* Subcategorías */
.subcategories-container {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.subcategories-title {
    color: #333;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 10px;
    text-align: center;
}

.subcategories-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
}

.subcategory-item {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 12px 16px;
    text-align: center;
    text-decoration: none;
    color: #333;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.subcategory-item:hover {
    background: #f0f0f0;
    color: #333;
    transform: translateY(-2px);
}

.subcategory-link.active {
    background: #007bff;
    color: white;
    border-radius: 6px;
}

/* Main Content */
.main-content {
    padding: 3rem 0;
}

.category-section {
    margin-bottom: 4rem;
}

.section-header {
    text-align: center;
    margin-bottom: 2rem;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    position: relative;
}

.section-divider {
    width: 60px;
    height: 3px;
    background: var(--primary-color);
    margin: 0 auto;
    border-radius: 2px;
}

/* Grid de Productos - Responsive */
.products-grid {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: 1fr; /* Móvil: 1 columna */
}

/* Tablet: 2 columnas */
@media (min-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop: 4 columnas */
@media (min-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Tarjeta de Producto */
.product-card {
    background: var(--light-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid var(--border-color);
    cursor: pointer;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.product-image-container {
    position: relative;
    aspect-ratio: 16/12;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--border-color, #e5e7eb);
    cursor: pointer;
}

.product-image,
.product-image-container img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    transition: var(--transition);
}

.product-card:hover .product-image,
.product-card:hover .product-image-container img {
    transform: scale(1.05);
}

.promo-badge-card {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: var(--danger-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 700;
    box-shadow: var(--shadow-md);
    z-index: 2;
}

.product-content {
    padding: 1.25rem;
}

.product-name {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.product-description {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    /* Fallback para navegadores que no soportan -webkit-line-clamp */
    line-clamp: 2;
    display: -moz-box;
    -moz-box-orient: vertical;
}

.product-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.product-price {
    display: flex;
    align-items: baseline;
    font-weight: 700;
    color: var(--text-primary);
}

.product-price-block {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.product-qty-price {
    line-height: 1.2;
    color: var(--text-secondary);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 11rem;
}

.product-qty-price--card {
    font-size: 0.7rem;
    letter-spacing: 0.01em;
}

.product-qty-price--detail {
    font-size: 0.95rem;
    margin-top: 0.35rem;
    color: var(--primary-color);
    max-width: none;
    white-space: normal;
}

.product-qty-price-list {
    margin: 0.5rem 0 0;
    padding-left: 1.1rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.product-qty-price-list li {
    margin-bottom: 0.2rem;
}

.product-detail-offer {
    margin: 0.35rem 0 0.75rem;
}

.product-detail-offer-badge {
    display: inline-block;
    background: #ef4444;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 0.2rem 0.55rem;
    border-radius: var(--radius-sm, 4px);
}

.product-detail-offer-price {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.45rem;
    margin-top: 0.35rem;
}

.product-detail-offer-price .offer-was {
    text-decoration: line-through;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.product-detail-offer-price .offer-now {
    color: #ef4444;
    font-weight: 700;
    font-size: 1.1rem;
}

.product-detail-offer-price .offer-dates {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.product-detail-wholesale {
    margin: 0.65rem 0 1rem;
    padding: 0.65rem 0.75rem;
    background: var(--light-color, #f9fafb);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm, 6px);
}

.wholesale-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.35rem;
}

.product-detail-wholesale .product-qty-price-list {
    margin: 0;
    padding-left: 1rem;
    list-style: disc;
}

.product-detail-wholesale li {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem;
}

.wholesale-rule {
    font-weight: 600;
    color: var(--text-secondary);
}

.wholesale-price {
    font-weight: 700;
    color: var(--primary-color);
}

/* Variantes: color / talla / unidad */
.product-variants {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    margin: 0.5rem 0 0.65rem;
}

.product-variants--card {
    margin-top: 0.4rem;
    margin-bottom: 0.25rem;
}

.product-unit {
    display: inline-flex;
    align-self: flex-start;
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
    background: var(--border-color);
    padding: 0.1rem 0.4rem;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.variant-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
}

.color-swatch {
    width: 1.1rem;
    height: 1.1rem;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.15);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
    display: inline-block;
    flex: 0 0 auto;
}

.product-variants--detail .color-swatch {
    width: 1.35rem;
    height: 1.35rem;
}

.size-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 0.3rem;
    border-radius: 50%;
    border: 1.5px solid #fff;
    box-shadow: 0 0 0 1px var(--border-color);
    background: var(--light-color);
    color: var(--text-primary);
    font-size: 0.65rem;
    font-weight: 700;
    line-height: 1;
    flex: 0 0 auto;
}

.product-variants--detail .size-chip {
    min-width: 1.6rem;
    height: 1.6rem;
    font-size: 0.72rem;
}

.qty-price-oferta {
    color: #ef4444;
    font-weight: 700;
    font-size: 0.85em;
}

/* Carrusel multimedia detalle producto */
.product-detail-media {
    width: 100%;
}

.detail-media-carousel {
    width: 100%;
}

.detail-media-stage {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    max-height: 22rem;
    background: var(--border-color);
    border-radius: var(--radius-md, 8px);
    overflow: hidden;
}

.detail-media-slide {
    display: none;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
}

.detail-media-slide.is-active {
    display: flex;
}

.detail-media-slide img,
.detail-media-slide video,
.detail-media-slide iframe {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 0;
}

.detail-media-slide video,
.detail-media-slide iframe {
    object-fit: contain;
    background: #111;
}

.detail-media-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 2.25rem;
    height: 2.25rem;
    border: none;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    color: var(--text-primary);
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.detail-media-prev { left: 0.5rem; }
.detail-media-next { right: 0.5rem; }

.detail-media-thumbs {
    display: flex;
    gap: 0.4rem;
    margin-top: 0.65rem;
    overflow-x: auto;
    padding-bottom: 0.15rem;
}

.detail-media-thumb {
    flex: 0 0 auto;
    width: 3.25rem;
    height: 3.25rem;
    padding: 0;
    border: 2px solid transparent;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    background: var(--border-color);
}

.detail-media-thumb.is-active {
    border-color: var(--primary-color);
}

.detail-media-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.detail-media-thumb.is-video {
    display: flex;
    align-items: center;
    justify-content: center;
}

.detail-media-thumb-label {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-secondary);
}

.price-symbol {
    font-size: 0.875rem;
    margin-right: 0.125rem;
    color: var(--text-secondary);
}

.price-value {
    font-size: 1.25rem;
}

.product-detail-btn,
.add-to-cart-btn--icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.product-detail-btn:hover,
.add-to-cart-btn--icon:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: scale(1.05);
}

.add-to-cart-btn--icon.added {
    background: var(--success-color);
    border-color: var(--success-color);
    color: white;
}

.product-actions--compact {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.product-actions--compact .quantity-controls {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

/* Footer */
.footer {
    background: var(--dark-color);
    color: white;
    padding: 3rem 0 2rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 768px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

.footer-section h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: white;
}

.footer-section p {
    color: rgba(255,255,255,0.7);
    margin-bottom: 0.5rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background: rgba(255,255,255,0.1);
    color: white;
    border-radius: var(--radius-md);
    text-decoration: none;
    transition: var(--transition);
}

.social-link:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

/* Botones Flotantes: mapa → carrito → WhatsApp → mesero (arriba) */
.floating-cart-btn,
.floating-waiter-btn,
.floating-whatsapp-btn,
.floating-maps-btn {
    position: fixed;
    right: 2rem;
    width: 3.5rem;
    height: 3.5rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    box-shadow: var(--shadow-lg);
    cursor: pointer;
    transition: var(--transition);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.floating-maps-btn {
    bottom: 2rem;
    background: var(--primary-color);
}

.floating-cart-btn {
    bottom: 6rem;
}

.floating-whatsapp-btn {
    bottom: 10rem;
    background: var(--success-color);
}

.floating-waiter-btn {
    bottom: 14rem;
    background: var(--primary-color);
}

.floating-cart-btn:hover,
.floating-waiter-btn:hover,
.floating-whatsapp-btn:hover,
.floating-maps-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
    color: white;
}

.cart-count {
    position: absolute;
    top: -0.25rem;
    right: -0.25rem;
    background: var(--danger-color);
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.125rem 0.375rem;
    border-radius: 9999px;
    min-width: 1.25rem;
    text-align: center;
}

/* Responsive Header */
@media (max-width: 768px) {
    .header-nav .container {
        flex-direction: column;
        gap: 0.5rem;
        padding: 0.65rem 0.75rem;
    }
    
    .logo h1 {
        font-size: 1.25rem;
    }
    
    .categories-nav {
        width: 100%;
        flex: 0 0 auto;
    }
    
    .promo-title,
    .promo-banner h2.promo-title {
        font-size: 1.1rem;
    }

    .promo-slides,
    .promo-slide {
        min-height: 0;
    }

    .promo-slide-visual,
    .promo-product-img {
        min-height: 12rem;
    }

    .promo-controls {
        justify-content: center;
        padding-left: 1rem;
    }

    .promo-slide-body {
        align-items: flex-start;
        text-align: left;
    }

    .promo-validity {
        font-size: 0.75rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .floating-cart-btn,
    .floating-waiter-btn,
    .floating-whatsapp-btn,
    .floating-maps-btn {
        width: 3rem;
        height: 3rem;
        right: 1rem;
    }

    .floating-maps-btn {
        bottom: 1rem;
    }
    
    .floating-cart-btn {
        bottom: 4.5rem;
    }

    .floating-whatsapp-btn {
        bottom: 8rem;
    }
    
    .floating-waiter-btn {
        bottom: 11.5rem;
    }

    /* Responsive: ocultar teléfono + ubicación (reglas refuerzo) */
    .floating-waiter-btn,
    .floating-maps-btn {
        display: none !important;
    }
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles */
button:focus-visible,
a:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Estilos adicionales para MVC */

/* Estados de productos */
.product-card.unavailable {
    opacity: 0.6;
    pointer-events: none;
}

.product-card.unavailable .product-image,
.product-card.unavailable .product-image-container img,
.product-card.unavailable:hover .product-image,
.product-card.unavailable:hover .product-image-container img {
    filter: grayscale(100%);
    transform: none;
}

.product-card.featured {
    border: 2px solid var(--secondary-color);
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.3);
}

/* Badges adicionales */
.unavailable-badge {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    background: #6b7280;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 700;
    z-index: 2;
}

.featured-badge {
    position: absolute;
    bottom: 0.75rem;
    left: 0.75rem;
    background: var(--secondary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 700;
    z-index: 2;
}

/* Estado vacío */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: var(--radius-lg);
    margin: 2rem 0;
}

.empty-state-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.retry-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.retry-btn:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

/* Estado de error */
.error-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: var(--light-color);
}

.error-content {
    text-align: center;
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    max-width: 500px;
}

.error-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.error-content p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.back-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.back-btn:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

/* Indicadores de carga */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: loading-shimmer 1.5s infinite;
}

@keyframes loading-shimmer {
    100% { left: 100%; }
}

/* Tooltip para información adicional */
[data-tooltip] {
    position: relative;
}

[data-tooltip]:hover::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--dark-color);
    color: white;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    white-space: nowrap;
    z-index: 1000;
    margin-bottom: 0.25rem;
}

/* Responsive para badges adicionales */
@media (max-width: 768px) {
    .featured-badge {
        font-size: 0.625rem;
        padding: 0.2rem 0.5rem;
    }
    
    .unavailable-badge {
        font-size: 0.625rem;
        padding: 0.2rem 0.5rem;
    }
    
    .empty-state {
        padding: 2rem 1rem;
    }
    
    .empty-state-icon {
        font-size: 3rem;
    }
    
    .error-content {
        padding: 2rem;
        margin: 1rem;
    }
}

/* Animaciones para transiciones suaves */
.product-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-link {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.floating-cart-btn,
.floating-waiter-btn,
.floating-whatsapp-btn,
.floating-maps-btn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Sistema de Notificaciones */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: var(--radius-md);
    color: white;
    font-weight: 500;
    z-index: 10000;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    box-shadow: var(--shadow-lg);
    max-width: 300px;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

.notification-success {
    background: linear-gradient(135deg, var(--success-color), #059669);
}

.notification-error {
    background: linear-gradient(135deg, var(--danger-color), #dc2626);
}

.notification-warning {
    background: linear-gradient(135deg, var(--secondary-color), #d97706);
}

.notification-info {
    background: linear-gradient(135deg, var(--primary-color), #1d4ed8);
}

/* Modo oscuro para notificaciones */
[data-theme="dark"] .notification {
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.6);
}

/* Controles de cantidad y botones de carrito */
.product-actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 0.25rem;
    transition: var(--transition);
}

body[data-theme="dark"] .quantity-controls,
body.dark-mode .quantity-controls {
    background: #374151;
    border-color: #4b5563;
}

.quantity-btn {
    background: var(--primary-color);
    border: none;
    border-radius: var(--radius-sm);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: white;
}

.quantity-btn:hover {
    background: var(--primary-color);
    transform: scale(1.05);
}

.quantity-btn:disabled {
    background: var(--text-secondary);
    cursor: not-allowed;
    transform: scale(1);
}

.quantity-display {
    min-width: 30px;
    text-align: center;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.add-to-cart-btn {
    background: var(--success-color);
    border: none;
    border-radius: var(--radius-md);
    padding: 0.5rem 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: var(--transition);
    color: white;
    font-weight: 500;
    font-size: 0.875rem;
    width: 100%;
}

.add-to-cart-btn:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.add-to-cart-btn:active {
    transform: translateY(0);
}

.add-to-cart-btn.added {
    background: var(--success-color);
    animation: addedToCart 0.6s ease;
}

@keyframes addedToCart {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.add-to-cart-btn .btn-text {
    transition: var(--transition);
}

/* Estilos para modo oscuro */
body[data-theme="dark"] .add-to-cart-btn,
body.dark-mode .add-to-cart-btn {
    background: var(--success-color);
}

body[data-theme="dark"] .add-to-cart-btn:hover,
body.dark-mode .add-to-cart-btn:hover {
    background: #059669;
}

/* Responsive */
@media (max-width: 640px) {
    .product-actions {
        gap: 0.75rem;
    }
    
    .add-to-cart-btn {
        padding: 0.75rem;
        font-size: 0.9rem;
    }
    
    .quantity-btn {
        width: 32px;
        height: 32px;
    }
    
    .quantity-display {
        min-width: 35px;
        font-size: 1rem;
    }
}

/* Indicador de API source */
body[data-api-source="fallback"] .promo-banner {
    background: linear-gradient(135deg, #6b7280, #4b5563);
}

body[data-api-source="fallback"] .promo-banner.promo-banner--bg-image {
    background-color: #6b7280;
    background-image: var(--promo-bg-image);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

body[data-api-source="fallback"] .promo-banner::before {
    display: none;
}

/* Modal del Carrito de Compras */
.cart-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
}

.cart-modal .modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.cart-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--light-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    width: 95%;
    max-width: 800px;
    max-height: 95vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.cart-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    background: var(--light-color);
}

.cart-modal-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.cart-modal-title svg {
    color: var(--primary-color);
}

.cart-modal-close {
    background: none;
    border: none;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
}

.cart-modal-close:hover {
    background: var(--border-color);
    color: var(--text-primary);
}

.cart-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 1.5rem;
    min-height: 400px;
}

.cart-items-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cart-item {
    display: grid;
    grid-template-columns: 80px 1fr auto auto auto;
    gap: 1rem;
    align-items: center;
    padding: 1rem;
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.cart-item:hover {
    box-shadow: var(--shadow-md);
}

.cart-item-image {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    background: var(--border-color);
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    min-width: 0;
}

.cart-item-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-category {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.cart-item-price {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
    color: var(--primary-color);
    font-weight: 600;
}

.cart-price-was {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: line-through;
    margin-left: 0.35rem;
}

.cart-qty-price-hint {
    margin: 0.35rem 0 0;
    font-size: 0.75rem;
    color: var(--text-secondary);
    line-height: 1.3;
}

.cart-qty-price-hint.is-applied {
    color: var(--primary-color);
    font-weight: 600;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--border-color);
    border-radius: var(--radius-sm);
    padding: 0.25rem;
}

.cart-item-quantity .quantity-btn {
    width: 28px;
    height: 28px;
    border: none;
    background: var(--light-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.cart-item-quantity .quantity-btn:hover:not(:disabled) {
    background: var(--primary-color);
    color: white;
}

.cart-item-quantity .quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.cart-item-quantity .quantity-display {
    min-width: 30px;
    text-align: center;
    font-weight: 600;
    color: var(--text-primary);
}

.cart-item-subtotal {
    text-align: right;
}

.subtotal-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.subtotal-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.cart-item-remove {
    background: none;
    border: none;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    color: var(--danger-color);
    transition: var(--transition);
}

.cart-item-remove:hover {
    background: rgba(239, 68, 68, 0.1);
}

.cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    text-align: center;
    color: var(--text-secondary);
}

.cart-empty svg {
    margin-bottom: 1rem;
    opacity: 0.3;
}

.cart-empty p {
    font-size: 1.125rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.cart-empty small {
    font-size: 0.875rem;
    opacity: 0.7;
}

/* Información de Entrega */
.cart-delivery-info {
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    height: fit-content;
    position: sticky;
    top: 0;
}

.delivery-info-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-color);
}

.delivery-info-title::before {
    content: "📍";
    font-size: 1.125rem;
}

.delivery-form {
    display: grid;
    gap: 0.875rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.form-group label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.form-input {
    padding: 0.625rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    font-size: 0.8125rem;
    transition: var(--transition);
    background: white;
    color: var(--text-primary);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.1);
}

.form-input::placeholder {
    color: var(--text-secondary);
    opacity: 0.6;
    font-size: 0.75rem;
}

.form-textarea {
    resize: vertical;
    min-height: 60px;
    font-family: inherit;
}

/* Modal verificación OTP pedido */
.order-verify-modal {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.order-verify-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
}

.order-verify-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 24rem);
    background: var(--bg-color, #fff);
    color: var(--text-primary, #111);
    border-radius: 0.75rem;
    padding: 1.5rem 1.25rem 1.25rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
}

.order-verify-close {
    position: absolute;
    top: 0.5rem;
    right: 0.75rem;
    border: none;
    background: transparent;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    color: var(--text-secondary, #666);
}

.order-verify-dialog h3 {
    margin: 0 1.5rem 0.75rem 0;
    font-size: 1.15rem;
}

.order-verify-hint {
    margin: 0 0 1rem;
    font-size: 0.9rem;
    line-height: 1.4;
    color: var(--text-secondary, #555);
}

.order-verify-preview {
    margin: 0 0 0.75rem;
    padding: 0.5rem 0.75rem;
    background: rgba(234, 179, 8, 0.15);
    border-radius: 0.375rem;
    font-size: 0.85rem;
}

.order-verify-dialog label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.order-verify-input {
    width: 100%;
    text-align: center;
    font-size: 1.5rem !important;
    letter-spacing: 0.35em;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.order-verify-error {
    color: #b91c1c;
    font-size: 0.85rem;
    margin: 0 0 0.75rem;
}

.order-verify-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
}

@media (max-width: 480px) {
    .order-verify-actions {
        flex-direction: column-reverse;
    }

    .order-verify-actions .btn {
        width: 100%;
    }
}

.cart-modal-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--light-color);
}

.cart-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.cart-total {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.cart-total-label {
    font-size: 1rem;
    color: var(--text-secondary);
}

.cart-total-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.cart-count {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.cart-actions {
    display: flex;
    gap: 1rem;
}

.cart-actions .btn {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.cart-actions .btn-secondary {
    background: var(--border-color);
    color: var(--text-primary);
}

.cart-actions .btn-secondary:hover {
    background: var(--text-secondary);
    color: white;
}

.cart-actions .btn-primary {
    background: var(--primary-color);
    color: white;
}

.cart-actions .btn-primary:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Responsive para el modal del carrito */
@media (max-width: 768px) {
    .cart-modal-content {
        width: 95%;
        max-width: 95vw;
        max-height: 95vh;
    }
    
    .cart-modal-body {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 1rem;
    }
    
    .cart-delivery-info {
        position: static;
        border: 1px solid var(--border-color);
        border-radius: var(--radius-md);
        padding: 1rem;
    }
    
    .cart-item {
        grid-template-columns: 60px 1fr;
        gap: 0.75rem;
    }
    
    .cart-item-image {
        width: 60px;
        height: 60px;
        grid-row: span 2;
    }
    
    .cart-item-quantity {
        grid-column: span 2;
        justify-content: center;
    }
    
    .cart-item-subtotal {
        grid-column: span 2;
        text-align: center;
    }
    
    .cart-item-remove {
        position: absolute;
        top: 0.5rem;
        right: 0.5rem;
    }
    
    .cart-item {
        position: relative;
        padding: 1rem 2.5rem 1rem 1rem;
    }
    
    .cart-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .cart-modal-header {
        padding: 1rem;
    }
    
    .cart-modal-title {
        font-size: 1.125rem;
    }
    
    .cart-modal-body {
        padding: 0.75rem;
    }
    
    .cart-item {
        padding: 0.75rem 2rem 0.75rem 0.75rem;
    }
    
    .cart-modal-footer {
        padding: 1rem;
    }
    
    .cart-summary {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
        margin-bottom: 0.75rem;
    }
    
    .cart-total-value {
        font-size: 1.25rem;
    }
}

@media (max-width: 320px) {
    .cart-summary {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .cart-delivery-info {
        padding: 0.75rem;
    }
    
    .delivery-info-title {
        font-size: 0.9375rem;
        margin-bottom: 0.75rem;
    }
    
    .form-input {
        padding: 0.5rem;
        font-size: 0.75rem;
    }
    
    .form-textarea {
        min-height: 60px;
    }
}

/* Optimización para impresión */
@media print {
    .product-card {
        break-inside: avoid;
        page-break-inside: avoid;
    }
    
    .main-content {
        padding: 0;
    }
}
