/* ================================
   MÓDULO: HEADER
   Estilos exclusivos del header
   ================================ */

/* Reset específico del módulo */
.header,
.header * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Container principal del header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.4s ease;
    background: transparent;
    padding: 1.5rem 0;
}

/* Header con fondo cuando hace scroll */
.header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding: 1rem 0;
}

/* Container interno */
.header__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

/* Logo */
.header__logo h1 {
    font-family: 'Georgia', serif;
    font-size: 1.8rem;
    font-weight: 600;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
}

.header.scrolled .header__logo h1 {
    color: #A67B5B;
    text-shadow: none;
}

/* Navegación */
.header__nav {
    flex: 1;
    display: flex;
    justify-content: center;
}

.header__list {
    display: flex;
    list-style: none;
    gap: 2.5rem;
    align-items: center;
}

.header__link {
    font-family: 'Arial', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    color: #fff;
    text-decoration: none;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 0;
}

.header__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: #E07856;
    transition: width 0.3s ease;
}

.header__link:hover::after {
    width: 100%;
}

.header.scrolled .header__link {
    color: #3E2723;
    text-shadow: none;
}

.header.scrolled .header__link:hover {
    color: #A67B5B;
}

/* Botón WhatsApp */
.header__whatsapp {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: #25D366;
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    font-family: 'Arial', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.header__whatsapp span {
    font-size: 1.2rem;
}

.header__whatsapp:hover {
    background: #20BA5A;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

/* Botón toggle para móvil */
.header__toggle {
    display: none;
    flex-direction: column;
    gap: 0.4rem;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.header__toggle span {
    width: 28px;
    height: 3px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s ease;
    box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.header.scrolled .header__toggle span {
    background: #3E2723;
    box-shadow: none;
}

/* Toggle activo (X) */
.header__toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.header__toggle.active span:nth-child(2) {
    opacity: 0;
}

.header__toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* ================================
   RESPONSIVE: TABLET
   ================================ */
@media screen and (max-width: 968px) {
    .header__container {
        padding: 0 1.5rem;
    }

    .header__list {
        gap: 1.5rem;
    }

    .header__link {
        font-size: 0.95rem;
    }

    .header__whatsapp {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
}

/* ================================
   RESPONSIVE: MÓVIL
   ================================ */
@media screen and (max-width: 768px) {
    .header__toggle {
        display: flex;
    }

    .header__nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        padding: 6rem 2rem 2rem;
        transition: right 0.4s ease;
        box-shadow: -5px 0 20px rgba(0, 0, 0, 0.1);
    }

    .header__nav.show {
        right: 0;
    }

    .header__list {
        flex-direction: column;
        gap: 2rem;
        align-items: flex-start;
    }

    .header__link {
        font-size: 1.1rem;
        color: #3E2723;
        text-shadow: none;
    }

    .header__link::after {
        background: #E07856;
    }

    .header__whatsapp {
        padding: 0.7rem 1.3rem;
        font-size: 0.9rem;
    }

    .header__logo h1 {
        font-size: 1.5rem;
    }
}

@media screen and (max-width: 480px) {
    .header__container {
        padding: 0 1rem;
    }

    .header__logo h1 {
        font-size: 1.3rem;
    }

    .header__whatsapp {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
    }

    .header__whatsapp span {
        font-size: 1rem;
    }

    .header__nav {
        width: 80%;
    }
}