header.site-header { display: none !important; }

#header-editorial {
    position: fixed; top: 0; left: 0; 
    width: 100vw; max-width: 100%; box-sizing: border-box; 
    z-index: 9999; background-color: transparent; 
    padding: 35px 0 20px 0;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

#header-editorial.scrolled {
    background-color: #131313 !important;
    box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.15);
}

.menu-editorial-aislado {
    display: flex; justify-content: center; align-items: center; 
    gap: 25px; 
    overflow-x: auto; white-space: nowrap; -webkit-overflow-scrolling: touch;
    width: 100%; box-sizing: border-box; padding: 0 20px;
}
.menu-editorial-aislado::-webkit-scrollbar { display: none; }
.menu-editorial-aislado { -ms-overflow-style: none; scrollbar-width: none; }

/* REGLA BASE: Forzar estilo y color oscuro en páginas claras */
#header-editorial .menu-editorial-aislado a {
    display: flex !important;
    align-items: center !important;
    gap: 25px !important;
    font-family: inherit !important;
    font-style: italic !important;
    font-weight: 500 !important;
    letter-spacing: 0.02em !important;
    color: #1a1a1a !important; /* Texto oscuro por defecto */
    text-decoration: none !important;
    transition: color 0.3s ease, opacity 0.3s ease !important;
}

#header-editorial .menu-editorial-aislado a:hover {
    opacity: 0.6 !important;
}

#header-editorial .menu-editorial-aislado a::before {
    content: "//" !important;
    font-style: normal !important;
    opacity: 0.4 !important;
}

/* REGLA EXCEPCIÓN: Color claro en páginas oscuras O al hacer scroll */
#header-editorial.tema-oscuro .menu-editorial-aislado a,
#header-editorial.scrolled .menu-editorial-aislado a {
    color: #F4EFE6 !important;
}

/* =========================================
   OPTIMIZACIÓN MÓVIL
========================================= */
@media (max-width: 768px) {
    #header-editorial {
        padding-top: 30px !important;
        padding-bottom: 12px !important;
    }
    .menu-editorial-aislado {
        justify-content: flex-start !important; 
        padding: 0 20px !important;
        gap: 15px !important;
    }
    #header-editorial .menu-editorial-aislado a {
        font-size: 16px !important;
        gap: 12px !important;
    }

    #header-editorial::after {
        content: "desliza ←→";
        display: block; text-align: center; font-size: 10px;
        font-style: italic; letter-spacing: 0.05em; margin-top: 8px;
        color: rgba(26, 26, 26, 0.4) !important;
        animation: animacionDesliza 2.5s ease-in-out infinite;
    }
    #header-editorial.scrolled::after,
    #header-editorial.tema-oscuro::after {
        color: rgba(244, 239, 230, 0.4) !important; 
    }
}

@keyframes animacionDesliza {
    0%, 100% { transform: translateX(-4px); }
    50% { transform: translateX(4px); }
}