/* ==========================================
   1. FUENTES Y VARIABLES GLOBALES
   ========================================== */
@font-face {
    font-family: 'Acumin';
    src: url('../fonts/tu-archivo-acumin.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* ==========================================
   2. ESTRUCTURA BASE (DESKTOP TRANSPARENTE)
   ========================================== */
header.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 99999;
    background-color: transparent;
    padding: 22px 40px;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    box-sizing: border-box;
    font-family: 'Acumin', sans-serif !important;
}

header.site-header .header-inner {
    max-width: 1600px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

/* --- Identidad / Brand (Logo + Slogan) --- */
header.site-header .header-brand {
    display: flex;
    align-items: center;
}

header.site-header .brand-link {
    display: flex;
    align-items: center;
    text-decoration: none !important;
    gap: 12px;
}

/* Tamaño del Logo en Desktop (Aumentado ligeramente) */
header.site-header .brand-logo {
    height: 34px !important;
    width: auto !important;
    max-width: 220px !important;
    object-fit: contain !important;
    flex-shrink: 0 !important;
    transition: opacity 0.3s ease;
}

/* Visibilidad Mutua de Logos */
header.site-header .logo-initial {
    display: block !important;
}

header.site-header .logo-scrolled {
    display: none !important;
}

header.site-header .brand-divider {
    color: #ffffff;
    font-size: 20px;
    font-weight: 300;
    opacity: 0.8;
    transition: color 0.3s ease;
}

header.site-header .brand-slogan {
    color: #ffffff;
    font-size: 16px;
    font-weight: 400;
    letter-spacing: -0.2px;
    white-space: nowrap;
    transition: color 0.3s ease;
}

/* --- Navegación Principal --- */
header.site-header .header-nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

header.site-header .nav-menu {
    display: flex;
    align-items: center;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    gap: 14px;
}

header.site-header .nav-menu a {
    color: #ffffff;
    text-decoration: none !important;
    font-size: 15px;
    font-weight: 400;
    transition: color 0.3s ease, opacity 0.2s ease;
}

header.site-header .nav-menu a:hover {
    opacity: 0.75;
}

header.site-header .nav-menu .sep {
    color: #ffffff;
    opacity: 0.5;
    font-size: 14px;
    pointer-events: none;
    transition: color 0.3s ease;
}

/* --- Botón Contacto (#EB0618) --- */
header.site-header .btn-contacto {
    background-color: #EB0618 !important;
    color: #ffffff !important;
    padding: 7px 20px !important;
    border-radius: 50px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    display: inline-block;
    transition: transform 0.2s ease, background-color 0.2s ease !important;
}

header.site-header .btn-contacto:hover {
    background-color: #c40413 !important;
    transform: scale(1.04);
}

/* --- Redes Sociales --- */
header.site-header .header-social {
    display: flex;
    align-items: center;
    gap: 10px;
}

header.site-header .header-social a {
    color: #ffffff;
    font-size: 16px;
    text-decoration: none !important;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease, opacity 0.2s ease, transform 0.2s ease;
}

header.site-header .header-social a:hover {
    opacity: 0.8;
    transform: translateY(-2px);
}

header.site-header .soc-sep {
    color: #ffffff;
    opacity: 0.5;
    font-size: 14px;
    pointer-events: none;
    transition: color 0.3s ease;
}

/* ==========================================
   3. ESTADO FIJO EN SCROLL (.is-scrolled)
   ========================================== */
header.site-header.is-scrolled {
    background-color: #ffffff !important;
    padding: 14px 40px !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
}

/* Cambio de Logos en Scroll */
header.site-header.is-scrolled .logo-initial {
    display: none !important;
}

header.site-header.is-scrolled .logo-scrolled {
    display: block !important;
}

/* Transición a Azul Corporativo para Textos e Íconos */
header.site-header.is-scrolled .nav-menu a,
header.site-header.is-scrolled .nav-menu .sep,
header.site-header.is-scrolled .brand-divider,
header.site-header.is-scrolled .brand-slogan,
header.site-header.is-scrolled .header-social a,
header.site-header.is-scrolled .soc-sep {
    color: #2222FF !important;
    opacity: 1 !important;
}

/* Persistencia Blanca del Botón Contacto */
header.site-header.is-scrolled .btn-contacto,
header.site-header.is-scrolled .nav-menu .btn-contacto {
    color: #ffffff !important;
    background-color: #EB0618 !important;
}

/* ==========================================
   4. ADAPTACIÓN RESPONSIVE (MÓVIL < 1100px)
   ========================================== */
header.site-header .nav-toggle {
    display: none;
}

@media (max-width: 1100px) {
    header.site-header {
        padding: 12px 16px !important;
    }

    header.site-header .header-inner {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100% !important;
    }

    header.site-header .header-brand {
        display: flex !important;
        align-items: center !important;
        flex: 1 !important;
        min-width: 0 !important;
    }

    header.site-header .brand-link {
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        text-decoration: none !important;
    }

    /* Tamaños en Móvil (Logo Aumentado) */
    header.site-header .brand-logo {
        height: 24px !important;
        width: auto !important;
        max-width: 140px !important;
        flex-shrink: 0 !important;
    }

    /* Visibilidad de Separador y Slogan en Móvil Inicial */
    header.site-header .brand-link span.brand-divider.force-show-mobile,
    header.site-header .brand-link span.brand-slogan.force-show-mobile {
        display: inline-block !important;
        visibility: visible !important;
        opacity: 1 !important;
        color: #ffffff !important;
    }

    header.site-header .brand-link span.brand-divider.force-show-mobile {
        font-size: 15px !important;
        font-weight: 300 !important;
        line-height: 1 !important;
        flex-shrink: 0 !important;
    }

    header.site-header .brand-link span.brand-slogan.force-show-mobile {
        font-size: 13px !important;
        font-weight: 400 !important;
        white-space: nowrap !important;
        line-height: 1 !important;
        letter-spacing: -0.2px !important;
    }

    /* OCULTAR Separador y Slogan en Scroll Móvil */
    header.site-header.is-scrolled .brand-link span.brand-divider.force-show-mobile,
    header.site-header.is-scrolled .brand-link span.brand-slogan.force-show-mobile {
        display: none !important;
    }

    /* Botón Hamburguesa */
    header.site-header .nav-toggle {
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
        width: 24px !important;
        height: 18px !important;
        background: transparent !important;
        border: none !important;
        cursor: pointer !important;
        z-index: 100001 !important;
        flex-shrink: 0 !important;
        margin-left: 10px !important;
    }

    header.site-header .nav-toggle span {
        width: 100% !important;
        height: 2.5px !important;
        background-color: #ffffff !important;
        border-radius: 2px !important;
        transition: transform 0.3s ease, opacity 0.3s ease, background-color 0.3s ease !important;
    }

    header.site-header.is-scrolled .nav-toggle span {
        background-color: #2222FF !important;
    }

    header.site-header .nav-toggle.active span {
        background-color: #ffffff !important;
    }

    header.site-header .nav-toggle.active span:nth-child(1) { transform: translateY(7.5px) rotate(45deg) !important; }
    header.site-header .nav-toggle.active span:nth-child(2) { opacity: 0 !important; }
    header.site-header .nav-toggle.active span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg) !important; }

    /* Menú Fullscreen Desplegable (Móvil) */
    header.site-header .header-nav {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100vh !important;
        background-color: #2222FF !important;
        flex-direction: column !important;
        justify-content: center !important;
        opacity: 0 !important;
        visibility: hidden !important;
        transition: all 0.3s ease !important;
        z-index: 100000 !important;
        gap: 28px !important;
    }

    header.site-header .header-nav.active {
        opacity: 1 !important;
        visibility: visible !important;
    }

    header.site-header .nav-menu {
        flex-direction: column !important;
        gap: 18px !important;
        text-align: center !important;
    }

    header.site-header .nav-menu a {
        font-size: 1.6rem !important;
        font-weight: bold !important;
    }

    header.site-header .nav-menu .sep, 
    header.site-header .soc-sep {
        display: none !important;
    }

    header.site-header .btn-contacto {
        font-size: 1.2rem !important;
        padding: 10px 28px !important;
    }

    header.site-header .header-social {
        gap: 20px !important;
    }

    header.site-header .header-social a {
        font-size: 22px !important;
    }

    /* Contraste en Menú Desplegable Abierto */
    header.site-header.is-scrolled .header-nav.active .nav-menu a,
    header.site-header .header-nav.active .nav-menu a,
    header.site-header.is-scrolled .header-nav.active .header-social a,
    header.site-header .header-nav.active .header-social a {
        color: #ffffff !important;
        opacity: 1 !important;
    }
}