:root {
    --primary-color: #ffcc00; /* Oro vibrante */
    --secondary-color: #0a0a0a; /* Negro profundo */
    --text-color: #ffffff;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --accent-gradient: linear-gradient(135deg, #ffcc00, #ff9900);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: var(--secondary-color);
    color: var(--text-color);
    background-image: none;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/fondo/fondo1.png') center/cover fixed;
    filter: brightness(0.4);
    z-index: -1;
}

/* Glassmorphism Header */
nav {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1200px;
    padding: 15px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: rgba(10, 10, 10, 0.7);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.scrolled nav {
    top: 10px;
    width: 95%;
    background: rgba(10, 10, 10, 0.9);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

/* Nav structure */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-top {
    display: flex;
    align-items: center;
}

.nav-bottom {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* User greeting desktop */
.user-greeting {
    font-size: 0.8rem;
    text-align: right;
}

.user-greeting span {
    display: block;
    opacity: 0.6;
}

.user-greeting .user-name {
    opacity: 1;
    font-weight: 700;
    color: var(--primary-color);
}

/* Nav icons */
.nav-icon {
    color: white;
    text-decoration: none;
    font-size: 1.2rem;
}

.nav-icon.nav-logout {
    color: #ff4d4d;
}

/* Cart Icon styles */
.cart-icon {
    background: var(--glass-bg);
    padding: 10px 20px;
    border-radius: 50px;
    border: 1px solid var(--glass-border);
    cursor: pointer;
    display: flex;
    align-items: center;
}

.cart-icon i {
    color: var(--primary-color);
}

.cart-icon #cart-count {
    color: white;
    font-weight: 700;
    margin-left: 8px;
}

/* Responsive para móvil */
@media (max-width: 768px) {
    nav {
        flex-direction: column !important;
        padding: 10px 15px !important;
        width: 95% !important;
        top: 10px !important;
        border-radius: 20px !important;
        gap: 6px !important;
    }
    
    nav .nav-top {
        width: 100%;
        justify-content: center;
    }
    
    nav .nav-bottom {
        width: 100%;
        justify-content: center;
        gap: 10px !important;
        flex-wrap: nowrap;
    }
    
    nav .nav-icon {
        font-size: 1rem !important;
    }
    
    nav .cart-icon {
        padding: 6px 12px !important;
    }
    
    nav .cart-icon #cart-count {
        margin-left: 4px;
        font-size: 0.8rem;
    }
    
    nav .logo {
        font-size: 1.1rem !important;
    }
    
    nav .user-greeting {
        display: none !important;
    }
    
    nav .user-name-mobile {
        display: inline-block !important;
        font-size: 0.75rem;
        color: var(--primary-color);
        font-weight: 700;
        max-width: 50px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .pv-link-text { display: none !important; }
}

@media (min-width: 769px) {
    nav {
        flex-direction: row !important;
    }
    
    nav .user-name-mobile {
        display: none !important;
    }
}

/* Revolucionario Hero */
.hero {
    height: 100vh;
    background: none;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    clip-path: none;
}

@media (max-width: 768px) {
    .hero {
        height: 50vh;
        min-height: 260px;
    }

    .hero::before {
        background-attachment: scroll !important;
        /* Mantener el zoom pero más sutil en mobile */
        animation: slowZoomMobile 15s infinite alternate;
        transform: scale(1.05);
    }

    body::before {
        background-attachment: scroll !important;
    }
}

@keyframes slowZoomMobile {
    from { transform: scale(1.0); }
    to   { transform: scale(1.08); }
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/fondo/fondo1.png') center/cover fixed;
    filter: brightness(0.3) saturate(1.2);
    z-index: -1;
    transform: scale(1.1);
    animation: slowZoom 20s infinite alternate;
}

@keyframes slowZoom {
    from { transform: scale(1); }
    to { transform: scale(1.15); }
}

.hero h1 {
    font-size: clamp(3rem, 12vw, 7rem);
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 900;
    line-height: 0.9;
    margin-bottom: 20px;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.5));
}

/* Featured Offers Horizontal Scroll */
.offers-section {
    padding: 40px 0;
    background: transparent;
}

.offers-container {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 20px;
    padding: 10px 30px 20px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.offers-container::-webkit-scrollbar { display: none; }

/* Offer Cards - mismo tamaño */
.offer-card {
    min-width: 280px;
    width: 280px;
    min-height: 380px;
    height: auto;
    flex-shrink: 0;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 20px;
    overflow: visible;
    position: relative;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
}

.offer-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.4);
    border-color: var(--primary-color);
}

.offer-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    opacity: 0.85;
    flex-shrink: 0;
}

/* ── STARBURST BADGE ── */
.offer-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 90px;
    height: 90px;
    z-index: 10;
}

.offer-badge-inner {
    width: 90px;
    height: 90px;
    background: #FFE000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    clip-path: polygon(
        50% 0%, 61% 15%, 79% 9%, 76% 27%,
        97% 28%, 87% 43%, 100% 55%, 84% 61%,
        90% 80%, 72% 78%, 65% 97%, 50% 86%,
        35% 97%, 28% 78%, 10% 80%, 16% 61%,
        0% 55%, 13% 43%, 3% 28%, 24% 27%,
        21% 9%, 39% 15%
    );
    filter: drop-shadow(0 4px 10px rgba(0,0,0,0.45));
    gap: 2px;
}

.offer-badge-label {
    font-size: 0.58rem;
    font-weight: 900;
    color: #cc0000;
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1;
}

.offer-badge-price {
    font-size: 0.88rem;
    font-weight: 900;
    color: #cc0000;
    line-height: 1;
    text-align: center;
}
    color: #cc0000;
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1;
}

.offer-badge-price {
    font-size: 0.78rem;
    font-weight: 900;
    color: #cc0000;
    line-height: 1;
    text-align: center;
}

.offer-content {
    padding: 14px 16px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.offer-content h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #fff;
    line-height: 1.3;
}

.offer-content p {
    color: var(--primary-color);
    font-weight: 700;
}

/* Fecha de vencimiento en verde */
.offer-vence {
    font-size: 0.72rem;
    color: #22c55e !important;
    font-weight: 600;
    margin: 4px 0 10px;
}

.hero-btns {
    display: flex;
    gap: 20px;
}

.btn {
    padding: 15px 30px;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 50px;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--secondary-color);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(241, 196, 15, 0.4);
}

.btn-whatsapp {
    background-color: #25d366;
    color: white;
}

/* Menu Section */
.menu-section {
    padding: 80px 20px;
    max-width: 1200px;
    margin: 0 auto;
    background: transparent;
}

.section-title {
    text-align: center;
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 50px;
}

.categories-nav {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
    overflow-x: auto;
    padding-bottom: 5px;
    position: relative;
    z-index: 100;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

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

/* Modern Category Pills */
.category-btn {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 4px 14px;
    border-radius: 100px;
    color: white;
    font-weight: 500;
    font-size: 0.8rem;
    transition: 0.3s;
    cursor: pointer;
    user-select: none;
    position: relative;
    z-index: 100;
    pointer-events: auto;
    white-space: nowrap;
}

.category-btn.active {
    background: var(--accent-gradient);
    color: black;
    border: none;
    box-shadow: 0 5px 20px rgba(255, 204, 0, 0.4);
}

/* Grid Design Upgrade */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    padding: 20px;
}

.product-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: 0.3s;
    position: relative;
}

.product-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 10px 30px rgba(241, 196, 15, 0.1);
}

.product-img-wrapper {
    position: relative;
    height: 200px;
    overflow: hidden;
    border-radius: 20px 20px 0 0;
}

.product-img {
    height: 100%;
    width: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.product-card:hover .product-img {
    transform: scale(1.1);
}

.price-tag {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0,0,0,0.9);
    backdrop-filter: blur(5px);
    padding: 8px 20px;
    border-radius: 50px;
    color: var(--primary-color);
    font-weight: 800;
    font-size: 1.3rem;
    border: 2px solid var(--primary-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.product-info {
    padding: 20px;
}

.product-name {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.product-price {
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 20px;
}

.add-to-cart {
    width: 100%;
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border: none;
    padding: 12px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.3s;
}

.add-to-cart:hover {
    background-color: var(--accent-color);
}

/* WhatsApp Order Button */
.whatsapp-order-btn {
    width: 100%;
    background-color: #25d366;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.whatsapp-order-btn:hover {
    background-color: #128c7e;
}

.whatsapp-order-btn:disabled {
    background: #444;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Cart Overlay */
.cart-overlay {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 400px;
    height: 100vh;
    background-color: #111;
    z-index: 1000;
    padding: 20px;
    box-shadow: -5px 0 15px rgba(0,0,0,0.5);
    transition: right 0.4s ease-in-out;
    overflow-y: scroll;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}

.cart-overlay.active {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.close-cart {
    font-size: 2rem;
    cursor: pointer;
    color: var(--primary-color);
}

.cart-items {
    margin-bottom: 20px;
    min-height: 50px;
}

/* Cart item styles */
.cart-item {
    flex-shrink: 0;
}

.cart-item h4 {
    margin: 0 0 5px 0;
    font-size: 1rem;
}

.cart-item p {
    margin: 0;
}

.cart-footer {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #333;
    padding-bottom: 100px;
    flex-shrink: 0;
}

/* Cart Delivery Buttons */
.cart-delivery-options {
    display: flex;
    gap: 8px;
}

.cart-delivery-btn {
    flex: 1;
    padding: 10px;
    border-radius: 10px;
    border: 2px solid #333;
    background: #1a1a1a;
    color: #fff;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.3s ease;
    font-family: inherit;
}

.cart-delivery-btn:hover {
    border-color: #555;
    background: #222;
}

.cart-delivery-btn.active {
    border-color: var(--primary-color) !important;
    background: rgba(255,204,0,0.15) !important;
    color: var(--primary-color) !important;
}

.cart-delivery-btn i {
    margin-right: 5px;
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    .hero-btns {
        flex-direction: column;
    }

    /* Carrito en móvil - ajustes de scroll */
    .cart-overlay {
        max-width: 100%;
        padding: 15px;
        padding-bottom: 120px;
        height: 100vh;
        height: -webkit-fill-available;
    }

    .cart-items {
        max-height: none;
    }

    .cart-footer {
        padding-bottom: 100px;
    }
}
