@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;600;700&family=Playfair+Display:ital,wght@0,400;0,700;1,400&family=Dancing+Script:wght@400;700&display=swap');

:root {
    --primary: #D4AF37; /* Dorado */
    --secondary: #1A1A1A; /* Negro profundo */
    --accent: #F4F1EA; /* Crema suave */
    --text: #333333;
    --white: #FFFFFF;
    --gray: #F8F9FA;
    --transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 10px 30px rgba(0,0,0,0.1);
    --glass: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.3);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--gray);
}
::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: #b8952d;
}

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

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--text);
    background-color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, .luxury-font {
    font-family: 'Playfair Display', serif;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* Header & Navigation */
header {
    background: var(--glass);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 1rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border-bottom: 1px solid var(--glass-border);
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--secondary);
}

.logo span {
    color: var(--primary);
}

nav ul {
    display: flex;
    gap: 2rem;
}

nav ul li a {
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

nav ul li a:hover {
    color: var(--primary);
}

.nav-icons {
    display: flex;
    gap: 1.5rem;
    font-size: 1.2rem;
}

.cart-icon {
    position: relative;
    display: flex;
    align-items: center;
}

#cart-count {
    background: var(--primary);
    color: var(--white);
    font-size: 0.65rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    position: absolute;
    top: -8px;
    right: -10px;
    border: 2px solid var(--white);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.wishlist-icon {
    position: relative;
    display: flex;
    align-items: center;
}

#wishlist-count {
    background: #e74c3c;
    color: var(--white);
    font-size: 0.65rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    position: absolute;
    top: -8px;
    right: -10px;
    border: 2px solid var(--white);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
/* Notificaciones */
.cart-notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--secondary);
    color: var(--white);
    padding: 1rem 2rem;
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    transform: translateY(100px);
    transition: transform 0.3s ease;
    z-index: 9999;
    border-left: 5px solid var(--primary);
}
.cart-notification.show {
    transform: translateY(0);
}

/* Hero Carousel */
.hero-carousel {
    position: relative;
    height: 90vh;
    width: 100%;
    overflow: hidden;
}

.carousel-inner {
    height: 100%;
    width: 100%;
}

.carousel-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0 10%;
    background-size: cover;
    background-position: center;
}

.carousel-item.active {
    opacity: 1;
    visibility: visible;
}

.carousel-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0,0,0,0.6), rgba(0,0,0,0.2));
}

.carousel-content {
    position: relative;
    z-index: 10;
    color: var(--white);
    max-width: 700px;
    transform: translateY(30px);
    transition: all 0.8s ease 0.3s;
    opacity: 0;
}

.carousel-item.active .carousel-content {
    transform: translateY(0);
    opacity: 1;
}

.script-font {
    font-family: 'Dancing Script', cursive;
    font-size: 3.5rem;
    color: var(--white);
    line-height: 1;
    margin-bottom: -10px;
    display: block;
}

.carousel-content h1 {
    font-size: 4.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.carousel-content p {
    text-transform: uppercase;
    letter-spacing: 4px;
    font-weight: 500;
    margin-bottom: 2.5rem;
}

/* Controls */
.carousel-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 15px;
    z-index: 20;
}

.dot {
    width: 12px;
    height: 12px;
    border: 2px solid var(--white);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background: var(--primary);
    border-color: var(--primary);
    width: 30px;
    border-radius: 10px;
}

.btn {
    padding: 1rem 2.5rem;
    background: var(--primary);
    color: var(--white);
    border: none;
    cursor: pointer;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.2);
    transition: var(--transition);
}

.btn:hover::after {
    left: 0;
}

/* Products Grid */
.section-title {
    text-align: center;
    margin: 4rem 0;
}

.section-title h2 {
    font-size: 2.5rem;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--primary);
}

.products-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2.5rem;
    padding: 0 5% 4rem;
}

.product-card {
    background: var(--white);
    transition: var(--transition);
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.product-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 3/4;
    background: #f9f9f9;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}

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

.product-overlay {
    position: absolute;
    bottom: -60px;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    padding: 2rem 1rem 1rem;
    transition: var(--transition);
    display: flex;
    justify-content: center;
}

.product-card:hover .product-overlay {
    bottom: 0;
}

.wishlist-btn-overlay {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 35px;
    height: 35px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: 0.3s;
    z-index: 15;
    opacity: 0;
    transform: translateY(-10px);
}

.product-card:hover .wishlist-btn-overlay {
    opacity: 1;
    transform: translateY(0);
}

.wishlist-btn-overlay:hover {
    color: #e74c3c;
    transform: scale(1.1) !important;
}

.wishlist-btn-overlay.active {
    color: #e74c3c;
    opacity: 1;
    transform: translateY(0);
}

.product-info {
    padding: 1.5rem;
    text-align: center;
}

.product-category {
    font-size: 0.75rem;
    color: var(--primary);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1.5px;
    margin-bottom: 0.5rem;
    display: block;
}

.product-name {
    font-size: 1rem;
    margin: 0.5rem 0;
    font-weight: 600;
    color: var(--secondary);
    min-height: 2.4rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-price {
    color: var(--secondary);
    font-weight: 700;
    font-size: 1.1rem;
    margin-top: 0.5rem;
}

/* Featured Products Section */
.featured-products {
    background: #fff;
    padding: 2rem 0 6rem;
}


/* --- SISTEMA DE NAVEGACIÓN --- */

/* 1. Navegación Desktop (PC) */
.desktop-nav {
    display: block;
}

.desktop-nav ul {
    display: flex;
    gap: 2.5rem;
}

.desktop-nav ul li a {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 1px;
    color: var(--secondary);
}

.desktop-nav ul li a:hover {
    color: var(--primary);
}

/* 2. Menú Móvil (Sidebar) - OCULTO POR DEFECTO */
#main-nav {
    display: none;
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100vh;
    background: var(--white);
    transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100000;
    padding: 5rem 2rem;
    box-shadow: 10px 0 30px rgba(0,0,0,0.2);
}

#main-nav.active {
    left: 0;
    display: block;
}

#main-nav ul {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

#main-nav ul li a {
    font-size: 1.1rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--secondary);
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* --- RESPONSIVE DESIGN --- */

@media (max-width: 992px) {
    header {
        padding: 1rem 5%;
    }

    .desktop-nav {
        display: none; /* Ocultar menú PC en móviles */
    }

    .menu-btn {
        display: block !important;
        order: 1;
        position: relative;
        z-index: 100001;
    }

    .logo {
        order: 2;
        margin: 0 auto;
        text-align: center;
    }

    .nav-icons {
        order: 3;
        display: flex;
        justify-content: flex-end;
    }

    .carousel-content h1 {
        font-size: 2.5rem;
    }

    .products-container {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: 1rem;
    }

    .footer-content {
        grid-template-columns: 1fr !important;
        text-align: center;
    }
}

@media (max-width: 576px) {
    .carousel-content h1 {
        font-size: 2rem;
    }
}


/* WhatsApp Float Button */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 25px;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
    z-index: 999999 !important; /* Por encima de TODO */
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: var(--transition);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    background-color: #128c7e;
    color: #FFF;
}

.wa-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff3b30;
    color: white;
    font-size: 10px;
    font-weight: 900;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
    40% {transform: translateY(-5px);}
    60% {transform: translateY(-3px);}
}

.whatsapp-float {
    animation: whatsapp-float 3s ease-in-out infinite;
    transition: all 0.3s ease;
}

@keyframes whatsapp-float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

.whatsapp-float::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: #25d366;
    border-radius: 50%;
    z-index: -1;
    animation: whatsapp-pulse-smooth 2s infinite;
}

@keyframes whatsapp-pulse-smooth {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Animación de pulso finalizada */


/* Botón de Rastreo con Pulso */
.nav-track {
    color: var(--primary) !important;
    font-weight: 800 !important;
    position: relative;
    animation: track-pulse 2s infinite;
    background: rgba(212, 175, 55, 0.1);
    padding: 5px 15px !important;
    border-radius: 50px;
    border: 1px solid var(--primary);
}

@keyframes track-pulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.4); }
    70% { transform: scale(1.05); box-shadow: 0 0 0 10px rgba(212, 175, 55, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(212, 175, 55, 0); }
}

/* --- SEARCH OVERLAY PREMIUM --- */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: none;
    flex-direction: column;
    animation: fadeIn 0.4s ease;
}

.search-overlay.active {
    display: flex;
}

.search-header {
    padding: 4rem 5%;
    border-bottom: 1px solid #eee;
}

.search-input-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    display: flex;
    align-items: center;
}

.search-input-icon {
    position: absolute;
    left: 0;
    font-size: 2rem;
    color: var(--primary);
}

#search-input {
    width: 100%;
    padding: 1.5rem 4rem;
    border: none;
    background: transparent;
    font-size: 2.5rem;
    font-family: 'Playfair Display', serif;
    outline: none;
    color: var(--secondary);
}

.search-close-btn {
    position: absolute;
    right: 0;
    background: none;
    border: none;
    font-size: 3rem;
    cursor: pointer;
    color: #999;
    transition: 0.3s;
}

.search-close-btn:hover {
    color: var(--secondary);
    transform: rotate(90deg);
}

.search-results-container {
    flex: 1;
    overflow-y: auto;
    padding: 4rem 5%;
}

.search-results-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.search-placeholder {
    text-align: center;
    padding: 5rem 0;
    color: #bbb;
}

.search-placeholder i {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    color: var(--primary);
    opacity: 0.5;
}

.search-placeholder p {
    font-size: 1.2rem;
    letter-spacing: 1px;
}

.search-item {
    display: flex;
    gap: 1.5rem;
    padding: 1.5rem;
    border-radius: 20px;
    background: var(--gray);
    cursor: pointer;
    transition: 0.3s;
    align-items: center;
}

.search-item:hover {
    background: white;
    box-shadow: var(--shadow);
    transform: translateY(-5px);
}

.search-item-img {
    width: 80px;
    height: 100px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
}

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

.search-item-info {
    flex: 1;
}

.search-item-cat {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--primary);
    font-weight: 700;
}

.search-item-name {
    font-size: 1.1rem;
    margin: 5px 0;
    font-family: 'Montserrat', sans-serif;
}

.search-item-price {
    font-weight: 700;
    color: var(--secondary);
}

.search-item-price .old {
    text-decoration: line-through;
    color: #999;
    font-size: 0.85rem;
    margin-left: 10px;
    font-weight: 400;
}

.search-loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    font-size: 1.2rem;
    color: var(--primary);
}

.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    font-size: 1.2rem;
    color: #999;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 768px) {
    #search-input { font-size: 1.5rem; padding: 1rem 3rem; }
    .search-input-icon { font-size: 1.5rem; }
    .search-close-btn { font-size: 2rem; }
}
