/* ========================================
   HEADER UNIFICADO - FUENTE DE VERDAD: BROWNIES & GALLETAS
   Todos los headers deben ser idénticos pixel por pixel
   ======================================== */

/* Header Principal */
.minimal-header {
    background: #d1b5d7;
    padding: 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(200, 165, 216, 0.15);
    backdrop-filter: blur(10px);
    height: 88px;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 40px;
    flex: 1;
}

/* Logo */
.logo-container {
    height: 76px;
    width: auto;
    transition: none;
    position: relative;
    z-index: 1001;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    padding: 0;
}

.logo-container:hover {
    transform: none;
}

.logo-img {
    height: 100%;
    width: auto;
    object-fit: contain;
    margin: 0;
    padding: 0;
}

/* Navegación */
.minimal-nav {
    display: flex;
    gap: 44px;
    align-items: center;
    flex: 1;
    list-style: none;
    margin: 0;
    padding: 0;
}

.header-social-icons {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-left: 10px;
}

.header-social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    text-decoration: none;
}

.header-social-link:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

/* Nav Items */
.nav-item {
    color: white;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.75rem;
    letter-spacing: 0.8px;
    transition: all 0.3s ease;
    position: relative;
    padding: 3px 10px;
    border-radius: 25px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
}

.nav-item::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: white;
    transition: width 0.3s ease;
}

.nav-item:hover {
    color: white;
    background-color: rgba(255, 255, 255, 0.2);
}

.nav-item:hover::before {
    width: 80%;
}

.nav-item.active {
    color: white;
    background-color: rgba(255, 255, 255, 0.25);
    font-weight: 600;
}

.nav-item.active::before {
    width: 80%;
}

/* Contact Dropdown */
.contact-dropdown {
    position: relative;
    display: inline-block;
    list-style: none;
    margin-left: -15px;
}

.contact-dropdown-btn {
    background: linear-gradient(135deg, #F9B58C 0%, #F4A67C 100%);
    backdrop-filter: blur(10px);
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 0.9rem;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(249, 181, 140, 0.3);
}

.contact-dropdown-btn:hover {
    background: linear-gradient(135deg, #F4A67C 0%, #F09964 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 181, 140, 0.4);
}

.dropdown-arrow {
    transition: transform 0.3s ease;
}

.contact-dropdown-btn[aria-expanded="true"] .dropdown-arrow {
    transform: rotate(180deg);
}

.contact-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(200, 165, 216, 0.2);
    padding: 8px;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 1000;
    list-style: none;
    margin: 0;
}

.contact-dropdown-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.contact-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #4A3C52;
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    font-weight: 500;
}

.contact-dropdown-item:hover {
    background: rgba(200, 165, 216, 0.1);
    transform: translateX(5px);
}

.whatsapp-item:hover {
    background: rgba(37, 211, 102, 0.1);
}

.instagram-item:hover {
    background: linear-gradient(135deg, rgba(249, 148, 51, 0.1), rgba(188, 24, 136, 0.1));
}

.tiktok-item:hover {
    background: rgba(0, 0, 0, 0.05);
}

.contact-dropdown-item svg {
    flex-shrink: 0;
}

/* Menu Toggle (Hamburger) */
.menu-toggle-minimal {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1002;
    transition: all 0.3s ease;
}

.menu-toggle-minimal .hamburger {
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 3px 0;
    transition: all 0.3s ease;
    border-radius: 3px;
}

.menu-toggle-minimal[aria-expanded="true"] .hamburger:nth-child(1) {
    transform: rotate(45deg) translateY(9px);
}

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

.menu-toggle-minimal[aria-expanded="true"] .hamburger:nth-child(3) {
    transform: rotate(-45deg) translateY(-9px);
}

/* ========================================
   RESPONSIVE - MOBILE
   ======================================== */
@media (max-width: 768px) {
    /* Header móvil - Altura moderada */
    .minimal-header {
        height: 70px;
    }

    /* Header Container - Grid con 3 columnas: [Hamburguesa] [Logo] [Contacto] */
    .header-container {
        padding: 0 15px;
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        gap: 10px;
    }

    /* Hamburguesa - Primera columna (izquierda) */
    .menu-toggle-minimal {
        display: flex;
        grid-column: 1;
        order: -1;
        margin-right: 10px;
    }

    /* Header Left - Columna central con logo */
    .header-left {
        grid-column: 2;
        display: flex;
        justify-content: center;
        gap: 0;
    }

    /* Logo - Centrado */
    .logo-container {
        height: 55px;
        width: auto;
    }

    /* Nav - Oculto hasta que se active */
    .minimal-nav:not(.active) {
        display: none;
    }

    /* Botón Contacto - Tercera columna (derecha) */
    .contact-dropdown {
        display: flex;
        grid-column: 3;
        margin-left: 10px;
        margin-right: 0;
    }

    .contact-dropdown-btn {
        padding: 6px 12px;
        font-size: 0.75rem;
    }

    /* Menú de navegación (dropdown desde el header) */
    .minimal-nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        gap: 0;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
        z-index: 999;
        padding: 15px 20px;
        box-shadow: 0 10px 40px rgba(200, 165, 216, 0.2);
        border-radius: 0 0 15px 15px;
    }

    .minimal-nav.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .nav-item {
        font-size: 1rem;
        padding: 12px 20px;
        width: 100%;
        text-align: center;
        color: #4A3C52;
        background: transparent;
        border-radius: 10px;
        transform: none;
        opacity: 1;
        transition: all 0.3s ease;
        box-shadow: none;
        text-shadow: none;
    }

    .minimal-nav.active .nav-item {
        transform: translateY(0);
        opacity: 1;
    }

    /* Remover delays de animación para dropdown */
    .minimal-nav.active .nav-item:nth-child(1),
    .minimal-nav.active .nav-item:nth-child(2),
    .minimal-nav.active .nav-item:nth-child(3) {
        transition-delay: 0s;
    }

    .minimal-nav.active .header-social-icons {
        transform: translateY(0);
        opacity: 1;
        transition-delay: 0s;
    }

    .header-social-icons {
        transform: none;
        opacity: 1;
        transition: all 0.3s ease;
        margin-left: 0;
        margin-top: 15px;
        justify-content: center;
        padding-top: 10px;
        border-top: 1px solid rgba(200, 165, 216, 0.2);
    }

    .header-social-link {
        width: 40px;
        height: 40px;
        background: rgba(200, 165, 216, 0.1);
        box-shadow: none;
    }

    .nav-item:hover {
        background: rgba(200, 165, 216, 0.1);
        transform: translateX(5px);
        color: #4A3C52;
    }

    .nav-item.active {
        background: rgba(249, 181, 140, 0.2);
        color: #4A3C52;
        font-weight: 600;
    }
}

@media (max-width: 480px) {
    /* Header para móviles pequeños */
    .minimal-header {
        height: 65px;
    }

    /* Logo proporcional */
    .logo-container {
        height: 50px;
        width: auto;
    }

    /* Botón contacto más pequeño */
    .contact-dropdown-btn {
        padding: 5px 10px;
        font-size: 0.7rem;
    }

    /* Items del menú */
    .nav-item {
        font-size: 1.2rem;
        padding: 12px 30px;
        width: 90%;
    }

    /* Header con padding */
    .header-container {
        padding: 0 12px;
    }
}
