:root {
    --primary: #c82333; /* Rojo italiano */
    --secondary: #28a745; /* Verde italiano */
    --accent: #ffc107; /* Amarillo dorado */
    --dark: #1a1a2e; /* Fondo oscuro */
    --darker: #16213e; /* Fondo oscuro más profundo */
    --light: #f8f9fa; /* Texto claro */
    --text-dark: #343a40; /* Texto oscuro para elementos claros */
    --neon-pink: #e63946; /* Rojo neón */
    --neon-blue: #457b9d; /* Azul oscuro */
    --neon-purple: #a8dadc; /* Azul claro */
    --neon-green: #2a9d8f; /* Verde azulado */
    --neon-yellow: #f4a261; /* Naranja */
    --moon-glow: #fdfd96; /* Brillo de luna más cálido */
    --star-color: #ffffff;
    --shooting-star: #f4d35e; /* Estrella fugaz dorada */
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Fondo nocturno con estrellas */
body {
    font-family: 'Georgia', serif; /* Fuente más clásica */
    background: transparent;
    color: white;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
}

/* Fondo nocturno con gradiente */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0d0d0d 0%, #1c1c2e 25%, #2c2c4e 50%, #3c3c6e 75%, #4c4c8e 100%); /* Gradiente más oscuro y cálido */
    z-index: -3;
}

/* Campo de estrellas */
.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    pointer-events: none;
}

.star {
    position: absolute;
    background: var(--star-color);
    border-radius: 50%;
    animation: twinkle 3s infinite;
}

.star.small {
    width: 1px;
    height: 1px;
}

.star.medium {
    width: 2px;
    height: 2px;
}

.star.large {
    width: 3px;
    height: 3px;
    box-shadow: 0 0 6px var(--star-color);
}

@keyframes twinkle {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* Estrellas fugaces */
.shooting-star {
    position: fixed;
    width: 2px;
    height: 2px;
    background: var(--shooting-star);
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
    box-shadow: 0 0 10px var(--shooting-star), 0 0 20px var(--shooting-star);
}

.shooting-star::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--shooting-star));
    transform: translateX(100%);
}

@keyframes shoot {
    0% {
        transform: translateX(-100px) translateY(-100px);
        opacity: 1;
    }
    100% {
        transform: translateX(100vw) translateY(100vh);
        opacity: 0;
    }
}

/* Luna llena animada */
.moon {
    position: fixed;
    width: 120px;
    height: 120px;
    background: radial-gradient(circle at 30% 30%, #fff, #fdfd96, #ffeb3b); /* Luna más cálida */
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
    box-shadow: 
        0 0 30px var(--moon-glow),
        0 0 60px var(--moon-glow),
        0 0 90px rgba(253, 253, 150, 0.3); /* Brillo de luna más cálido */
    animation: moonMove 60s linear infinite;
}

.moon::before {
    content: '';
    position: absolute;
    top: 10%;
    left: 15%;
    width: 15px;
    height: 15px;
    background: rgba(200, 200, 200, 0.3);
    border-radius: 50%;
}

.moon::after {
    content: '';
    position: absolute;
    top: 60%;
    left: 70%;
    width: 8px;
    height: 8px;
    background: rgba(200, 200, 200, 0.2);
    border-radius: 50%;
}

@keyframes moonMove {
    0% {
        top: 10%;
        left: -120px;
        transform: scale(0.8);
    }
    25% {
        top: 5%;
        left: 25%;
        transform: scale(1);
    }
    50% {
        top: 8%;
        left: 50%;
        transform: scale(1.1);
    }
    75% {
        top: 12%;
        left: 75%;
        transform: scale(1);
    }
    100% {
        top: 15%;
        left: calc(100% + 120px);
        transform: scale(0.8);
    }
}

/* Header mejorado */
header {
    background: rgba(28, 28, 46, 0.9); /* Fondo más oscuro */
    backdrop-filter: blur(10px);
    padding: 15px 5%;
    border-bottom: 3px solid var(--accent);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    display: grid;
    grid-template-columns: 20% 60% 20%;
    align-items: center;
    position: relative;
}

.header-logo {
    height: 60px;
    transition: all 0.3s ease;
    justify-self: center;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
}

.header-logo:hover {
    transform: rotate(10deg) scale(1.1);
    filter: drop-shadow(0 0 15px var(--accent));
}

.header-center {
    text-align: center;
    padding: 0 10px;
}

.header-right {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-self: end;
    gap: 10px;
}

.side-logo {
    height: 30px;
    margin: 5px 0;
    transition: all 0.3s ease;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.2));
}

.side-logo:hover {
    transform: scale(1.1);
    filter: drop-shadow(0 0 10px var(--accent));
}

.title {
    font-family: 'Italiana', serif; /* Fuente italiana */
    font-size: clamp(1.8rem, 4vw, 3rem);
    margin: 0;
    color: white;
    font-weight: 800;
    letter-spacing: 1px;
    text-shadow: 
        0 0 5px var(--primary),
        0 0 10px var(--secondary),
        0 0 15px var(--accent); /* Colores italianos */
    animation: titleGlow 6s linear infinite;
}

@keyframes titleGlow {
    0% { text-shadow: 0 0 5px var(--primary), 0 0 10px var(--secondary), 0 0 15px var(--accent); }
    25% { text-shadow: 0 0 5px var(--secondary), 0 0 10px var(--accent), 0 0 15px var(--primary); }
    50% { text-shadow: 0 0 5px var(--accent), 0 0 10px var(--primary), 0 0 15px var(--secondary); }
    75% { text-shadow: 0 0 5px var(--primary), 0 0 10px var(--secondary), 0 0 15px var(--accent); }
    100% { text-shadow: 0 0 5px var(--secondary), 0 0 10px var(--accent), 0 0 15px var(--primary); }
}

.subtitle {
    font-size: clamp(1rem, 2vw, 1.5rem);
    margin: 5px 0 0;
    color: var(--light);
    font-style: italic;
    animation: subtitleGlow 5s infinite alternate;
}

@keyframes subtitleGlow {
    0% { color: var(--light); text-shadow: 0 0 5px rgba(255, 255, 255, 0.5); }
    100% { color: var(--accent); text-shadow: 0 0 10px rgba(255, 190, 11, 0.7); }
}

.datetime {
    font-size: 0.9rem;
    color: var(--light);
    margin-top: 5px;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

/* Navegación mejorada */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 5%;
    background: rgba(28, 28, 46, 0.95); /* Fondo más oscuro */
    backdrop-filter: blur(15px);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-links {
    display: flex;
    list-style: none;
    flex-wrap: wrap;
    justify-content: center;
}

.nav-links li {
    margin: 5px 10px;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 8px 15px;
    border-radius: 25px;
    transition: all 0.3s ease;
    position: relative;
    white-space: nowrap;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-links a:hover {
    background: linear-gradient(45deg, var(--primary), var(--accent)); /* Colores italianos */
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(200, 35, 51, 0.3); /* Sombra roja */
}

.social-icons {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
}

.social-icons a {
    color: white;
    margin: 0 8px;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    padding: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
}

.social-icons a:hover {
    color: var(--accent);
    transform: translateY(-3px) scale(1.1);
    background: rgba(255, 193, 7, 0.2); /* Sombra amarilla */
    box-shadow: 0 5px 15px rgba(255, 193, 7, 0.3);
}

.cart-icon {
    position: relative;
    margin-left: 15px;
    padding: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.cart-icon:hover {
    background: rgba(200, 35, 51, 0.2); /* Sombra roja */
    transform: scale(1.1);
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: linear-gradient(45deg, var(--primary), #e63946); /* Rojo */
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
    box-shadow: 0 2px 10px rgba(200, 35, 51, 0.5); /* Sombra roja */
}

.admin-btn {
    background: linear-gradient(45deg, var(--primary), #e63946); /* Rojo */
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    margin-left: 15px;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(200, 35, 51, 0.3); /* Sombra roja */
}

.admin-btn:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 6px 20px rgba(200, 35, 51, 0.4); /* Sombra roja */
}

/* Contenido principal */
.main-content {
    flex: 1;
    width: 100%;
    max-width: 1800px;
    margin: 20px auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* Categorías mejoradas */
.categories {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
}

.category {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 12px 20px;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-weight: 500;
    position: relative;
    overflow: hidden;
    font-size: clamp(0.8rem, 2vw, 1rem);
    white-space: nowrap;
}

.category:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.category.active {
    background: linear-gradient(45deg, var(--accent), #f4a261); /* Amarillo a naranja */
    color: var(--text-dark); /* Texto oscuro */
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 193, 7, 0.4); /* Sombra amarilla */
}

/* Grid de productos mejorado */
.products-grid {
    display: grid;
    gap: 25px;
    margin-top: 30px;
    grid-template-columns: repeat(5, 1fr);
}

@media (max-width: 1599px) and (min-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 1199px) and (min-width: 900px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 899px) and (min-width: 600px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 599px) {
    .products-grid {
        grid-template-columns: 1fr;
    }
}

/* Tarjetas de producto mejoradas */
.product-card {
    background: rgba(28, 28, 46, 0.8); /* Fondo más oscuro */
    backdrop-filter: blur(15px);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    position: relative;
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.product-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    border-color: var(--accent);
}

.product-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(255, 193, 7, 0.1), transparent); /* Sombra amarilla */
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.product-card:hover::before {
    opacity: 1;
}

.product-media-container {
    width: 100%;
    height: 280px;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.product-media {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    filter: brightness(0.9);
}

.product-card:hover .product-media {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.product-info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-title {
    font-size: clamp(1rem, 1.2vw, 1.2rem);
    margin: 0 0 15px;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
    color: white;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.product-price {
    font-size: clamp(1.2rem, 1.5vw, 1.4rem);
    color: var(--accent);
    font-weight: bold;
    margin-bottom: 15px;
    text-shadow: 0 0 10px rgba(255, 193, 7, 0.5); /* Sombra amarilla */
    animation: priceGlow 3s infinite alternate;
}

@keyframes priceGlow {
    0% { text-shadow: 0 0 10px rgba(255, 193, 7, 0.5); }
    100% { text-shadow: 0 0 20px rgba(255, 193, 7, 0.8); }
}

.product-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.add-to-cart {
    background: linear-gradient(45deg, var(--accent), #f4a261); /* Amarillo a naranja */
    color: var(--text-dark);
    border: none;
    padding: 12px 18px;
    border-radius: 25px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    flex-grow: 1;
    margin-right: 10px;
    white-space: nowrap;
    font-size: clamp(0.8rem, 1vw, 1rem);
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3); /* Sombra amarilla */
}

.add-to-cart:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.5); /* Sombra amarilla */
}

.wishlist-btn {
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    padding: 10px;
    border-radius: 50%;
    backdrop-filter: blur(10px);
}

.wishlist-btn:hover {
    color: var(--primary);
    transform: scale(1.2);
    background: rgba(200, 35, 51, 0.2); /* Sombra roja */
}

.media-controls {
    position: absolute;
    bottom: 15px;
    left: 15px;
    display: flex;
    gap: 10px;
    z-index: 2;
}

.media-btn {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    color: white;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.media-btn:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

/* Footer mejorado */
footer {
    background: rgba(28, 28, 46, 0.95); /* Fondo más oscuro */
    backdrop-filter: blur(15px);
    padding: 40px 5% 20px;
    margin-top: 50px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h3 {
    color: var(--accent);
    margin-bottom: 15px;
    font-size: 1.2rem;
    text-shadow: 0 0 10px rgba(255, 193, 7, 0.3); /* Sombra amarilla */
}

.contact-info, .branches {
    list-style: none;
}

.contact-info li, .branches li {
    margin-bottom: 10px;
    color: var(--light);
}

.contact-link {
    color: var(--light);
    text-decoration: none;
    transition: all 0.3s ease;
}

.contact-link:hover {
    color: var(--accent);
    text-shadow: 0 0 5px rgba(255, 193, 7, 0.5); /* Sombra amarilla */
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--light);
}

/* Responsive design mejorado */
@media (max-width: 768px) {
    header {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 15px;
    }
    
    .header-right {
        justify-self: center;
    }
    
    nav {
        flex-direction: column;
        gap: 15px;
    }
    
    .moon {
        width: 80px;
        height: 80px;
    }
}

@media (max-width: 480px) {
    .categories {
        gap: 8px;
    }
    
    .category {
        padding: 8px 12px;
        font-size: 0.8rem;
    }
    
    .products-grid {
        gap: 15px;
    }
}

/* Animaciones adicionales */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-card {
    animation: fadeInUp 0.6s ease forwards;
}

.product-card:nth-child(even) {
    animation-delay: 0.1s;
}

.product-card:nth-child(3n) {
    animation-delay: 0.2s;
}

/* Efectos de partículas adicionales */
.particle {
    position: fixed;
    pointer-events: none;
    z-index: -1;
}

.particle::before {
    content: '';
    position: absolute;
    width: 2px;
    height: 2px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    animation: float 6s infinite ease-in-out;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
        opacity: 0.5;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 1;
    }
}

