/* =======================================
   Fuente accesible y tipografía base
======================================= */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');
html {
    scroll-behavior: smooth;
}

.section-anchor {
    display: block;
    height: 240px; /* ajusta si tu banner cambia */
    margin-top: -240px;
    visibility: hidden;
    pointer-events: none;
}



body {
    font-family: 'Poppins', Arial, sans-serif;
}

/* =======================================
   Estilos base y fondo
======================================= */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;

    background: linear-gradient(
        135deg,
        #4b6cb7 0%,
        #6a4dbb 50%,
        #8a63d2 100%
    );
    color: #ffffff;
    min-height: 100vh;
}

/* Contenedor principal */
main {
    max-width: 900px;
    margin: 6rem auto 3rem auto;
    padding: 1.5rem;
    background-color: rgba(0, 0, 0, 0.35);
    border-radius: 12px;
}


.page-header {
    text-align: center;
    padding: 6rem 1rem 1rem;
}

.page-header h1 {
    font-size: 2.6rem;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 3px 3px 10px rgba(0,0,0,0.4);
    margin: 0;
}

/* ================================
   TITULOS PREMIUM PARA SECCIONES
================================ */

.page-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 5rem;
    padding: 2rem 1rem;
}

/* Caja glass detrás del título */
.title-wrapper {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    padding: 1.5rem 2rem;
    border-radius: 18px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.25);
    text-align: center;
    max-width: 900px;
    width: 90%;
    border: 1px solid rgba(255,255,255,0.20);
}

/* Título visual con degradado */
.title-wrapper h1 {
    margin: 0;
    font-size: 3rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 1px;

    /* Degradado suave en el texto */
    background: linear-gradient(90deg, #fff 0%, #ffdf70 50%, #ffe9a6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;

    text-shadow: 0px 0px 12px rgba(255,255,255,0.25);
}

/* Barra luminosa debajo */
.title-wrapper::after {
    content: "";
    display: block;
    height: 4px;
    width: 55%;
    margin: 1rem auto 0;
    border-radius: 4px;

    background: linear-gradient(90deg, #ffcc00, #ffe680);
    box-shadow: 0 0 12px rgba(255,204,0,0.7);
}

/* ================================
   TABLA DE CONTENIDOS FLOTANTE
================================ */

.toc {
    position: sticky;
    top: 140px; /* para que no choque con tu nav */
    margin-left: 2rem;
    padding: 1.5rem;
    width: 230px;

    /* Glass effect */
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.18);

    /* Sombra premium */
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}

.toc-title {
    margin-top: 0;
    font-size: 1.35rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1rem;
    text-align: left;
}

/* Lista */
.toc-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.toc-list li {
    margin-bottom: 0.9rem;
}

/* Enlaces del TOC */
.toc-list a {
    text-decoration: none;
    color: #ffcc00;
    font-weight: 600;
    font-size: 1rem;
    transition: 
        color 0.25s ease,
        padding-left 0.25s ease;
}

.toc-list a:hover {
    color: #ffffff;
    padding-left: 6px;
}


/* ================================
   TOC AVANZADO PREMIUM
================================ */

.toc-advanced {
    position: sticky;
    top: 140px;
    margin-left: 2rem;
    width: 260px;
    z-index: 50;
}

/* Botón colapsable en móvil */
.toc-toggle {
    display: none;
    width: 100%;
    background: rgba(0,0,0,0.4);
    color: #fff;
    padding: 0.8rem 1rem;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.4);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
}

/* Panel principal */
.toc-panel {
    margin-top: 1rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.18);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);

    position: relative;
}

/* Lista */
.toc-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.toc-list li {
    margin-bottom: 1rem;
}

/* Enlaces */
.toc-list a {
    display: flex;
    align-items: center;
    gap: 0.6rem;

    text-decoration: none;
    color: #ffcc00;
    font-weight: 600;
    font-size: 1.05rem;

    padding: 5px 0;
    position: relative;
    transition: all 0.25s ease;
}

.toc-list a:hover {
    color: #ffffff;
}

/* Iconos */
.toc-icon {
    font-size: 1.2rem;
}

/* ================================
   SUBRAYADO ANIMADO PREMIUM
================================ */

.toc-underline {
    position: absolute;
    height: 3px;
    width: 0;
    left: 0;
    bottom: 8px;

    background: linear-gradient(90deg, #ffcc00, #ffe680);
    border-radius: 4px;

    transition: all 0.3s cubic-bezier(.25, .8, .25, 1);
}

/* ================================
   ACTIVO (ScrollSpy)
================================ */

.active-toc {
    color: #ffffff !important;
    text-shadow: 0 0 10px rgba(255, 204, 0, 0.8);
}

/* ================================
   RESPONSIVE
================================ */

@media (max-width: 900px) {

    .toc-advanced {
        position: static;
        width: 100%;
        margin: 1rem 0;
    }

    .toc-toggle {
        display: block;
    }

    .toc-panel {
        display: none;
    }

    .toc-panel.open {
        display: block;
    }

    .toc-list {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }
}

/* ================================
   BANNER ILUSTRATIVO
================================ */

.banner-accesibilidad {
    width: 100%;
    display: flex;
    justify-content: center;
    margin: 2rem 0 3rem;
}

.banner-accesibilidad img {
    width: 80%;
    max-width: 1100px;
    border-radius: 20px;

    /* Glass-style overlay */
    box-shadow: 0 10px 30px rgba(0,0,0,0.35);
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(8px);

    /* Suavizar bordes */
    border: 1px solid rgba(255,255,255,0.18);
}

/* ================================
   MENÚ DE GUÍAS – Layout de dos columnas con contenido
================================ */

/* Layout de dos columnas */
.guia-layout {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
}

/* La tabla de contenidos */
.toc {
    flex: 0 0 250px; /* ancho fijo */
}

/* El contenido principal */
#contenido {
    flex: 1; /* se expande */
}

@media (max-width: 900px) {
    .guia-layout {
        flex-direction: column;
    }

    .toc {
        width: 100%;
        margin-bottom: 1.5rem;
    }
}


/* ================================
   RESPONSIVE – Vista móvil
================================ */

@media (max-width: 900px) {
    .toc {
        position: static;
        width: 100%;
        margin: 1rem ;
    }

    .toc-list {
        display: flex;
        gap: 1.5rem;
        flex-wrap: wrap;
    }

    .toc-list li {
        margin-bottom: 0;
    }
}


/* =======================================
   HERO (sección principal superior)
======================================= */

.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
    padding: 3.5rem 1rem 2rem 1rem;
    gap: 1rem;
}

/* Título principal del Hero */
.hero-title {
    font-size: 2.4rem;
    font-weight: 700;
    margin: 0;
    color: #ffffff;
    text-shadow: 2px 2px 6px rgba(0,0,0,0.45);
}

/* Subtítulo descriptivo */
.hero-subtitle {
    max-width: 750px;
    font-size: 1.15rem;
    font-weight: 400;
    margin: 0.5rem 0 1rem;
    color: #f5f5f5;
    line-height: 1.6;
}


/* Botón accesible */
.hero-button {
    background-color: #ffcc00;
    color: #000000;
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    display: inline-block;
    margin-top: 0.5rem;
    transition: background 0.3s ease, transform 0.2s ease;
}

.hero-button:hover {
    background-color: #ffe066;
    transform: scale(1.05);
}

.hero-button:focus {
    outline: 3px solid #ffffff;
    outline-offset: 4px;
}


/* =======================================
   Skip link
======================================= */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #ffcc00;
    color: #000000;
    padding: 0.5rem 1rem;
    z-index: 100;
    text-decoration: none;
    font-weight: bold;
}

.skip-link:focus {
    top: 0.5rem;
}


/* =======================================
   Logo (Glass Effect)
======================================= */
.logo {
    width: 130px;
    height: auto;
    border-radius: 18px;
    padding: 10px;

    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(4px);

    box-shadow: 0 4px 12px rgba(0,0,0,0.25);

    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.logo:hover,
.logo:focus {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0,0,0,0.30);
    outline: none;
}


/* =======================================
   Navegación
======================================= */



/* Contenedor del menú (ya lo tienes) */


/* --- SLIDER PREMIUM --- */
.nav-menu {
    position: relative;
}

.nav-underline {
    position: absolute;
    bottom: -3px;
    height: 3px;
    background-color: #ffcc00;
    width: 0;
    left: 0;
    border-radius: 2px;
    transition: all 0.35s cubic-bezier(.25, .8, .25, 1);
}

/* Para los links */
.nav-menu a {
    position: relative;
    padding-bottom: 6px; /* espacio para la barra */
}

/* Clave para activar visualmente */
.active-link {
    font-weight: bold;
    color: #ffffff;
}


/* =======================================
   NAVEGACIÓN PRINCIPAL MODERNA + GLASS
======================================= */

.nav-bar {
    position: fixed; /* navegación tipo sticky */
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999;

    display: flex;
    justify-content: space-between;
    align-items: center;

    padding: 0.6rem 1.5rem;

    /* Barra glass semitransparente */
    background: rgba(20, 20, 45, 0.55);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);

    box-shadow: 0 2px 15px rgba(0,0,0,0.2);
}

/* Logo dentro de la navegación */
.nav-logo img {
    width: 55px;
    height: auto;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.15);
    padding: 5px;
    backdrop-filter: blur(3px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    transition: transform 0.3s ease;
}

.nav-logo img:hover {
    transform: scale(1.07);
}

/* Menú principal */
.nav-menu {
    list-style: none;
    display: flex;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
}

.nav-menu a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: opacity 0.2s ease;
}

.nav-menu a:hover {
    opacity: 0.8;
}

/* Página actual */


/* Focus accesible */
.nav-menu a:focus {
    outline: 3px solid #ffcc00;
    outline-offset: 4px;
}

/* Responsivo */
@media (max-width: 900px) {
    .nav-menu {
        gap: 1rem;
    }

    .nav-logo img {
        width: 48px;
    }
}



/* =======================================
   Sección ¿Qué es accesibilidad web?
======================================= */

.accesibilidad {
    max-width: 1000px;
    margin: 3rem auto;
    padding: 1.5rem;
    text-align: center;
}

.accesibilidad-descripcion {
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0.5rem auto 2rem;
    line-height: 1.6;
}

/* Contenedor de tarjetas */
.cards-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    margin-top: 2rem;
}

/* Tarjeta estilo glass */
.glass-card {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(6px);
    border-radius: 18px;
    padding: 1.5rem;
    width: 280px;

    box-shadow: 0 4px 16px rgba(0,0,0,0.25);

    text-align: center;

    transition: transform 0.30s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.35);
}

/* Icono accesible */
.card-icon {
    width: 80px;
    height: auto;
    background: rgba(255, 255, 255, 0.20);
    padding: 12px;
    border-radius: 12px;

    box-shadow: 0 3px 8px rgba(0,0,0,0.25);
}

/* Titulos de tarjetas */
.glass-card h3 {
    font-size: 1.4rem;
    margin-top: 0.8rem;
}


/* =======================================
   Cards informativas del index
======================================= */
h2 {
    margin-top: 0;
}

.section-card {
    background-color: rgba(15, 15, 40, 0.7);
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}

/* =======================================
   Accesibilidad: Focus visible
======================================= */
a:focus,
button:focus,
input:focus,
textarea:focus {
    outline: 3px solid #ffcc00;
    outline-offset: 3px;
}


/* =======================================
   Footer
======================================= */
footer {
    text-align: center;
    padding: 1rem;
    font-size: 0.9rem;
}


/* =======================================
   Sección A: Errores comunes
======================================= */

.errores {
    max-width: 1000px;
    margin: 3rem auto;
    padding: 1.5rem;
    text-align: center;
}

.errores-descripcion {
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0.5rem auto 2rem;
    line-height: 1.6;
}

.errores-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
}

.error-card {
    width: 280px;
    padding: 1.5rem;
    border-radius: 18px;
    background: rgba(255, 50, 50, 0.25); /* rojo accesible */
    backdrop-filter: blur(6px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
    text-align: center;
    transition: transform 0.2s ease;
}

.error-card:hover {
    transform: translateY(-6px);
}


/* =======================================
   Sección B: Recursos oficiales
======================================= */

.recursos {
    max-width: 1000px;
    margin: 3rem auto;
    padding: 1.5rem;
    text-align: center;
}

.recursos-descripcion {
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0.5rem auto 2rem;
    line-height: 1.6;
}

.recursos-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
}

.recurso-card {
    width: 280px;
    padding: 1.5rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.20);
    backdrop-filter: blur(6px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
    transition: transform 0.3s ease;
    text-align: center;
}

.recurso-card:hover {
    transform: translateY(-6px);
}

.recurso-card h3 {
    font-size: 1.3rem;
}

.recurso-link {
    display: inline-block;
    margin-top: 0.8rem;
    padding: 0.6rem 1.2rem;
    background-color: #ffcc00;
    color: #000000;
    text-decoration: none;
    font-weight: 600;
    border-radius: 8px;
    transition: background 0.2s ease;
}

.recurso-link:hover {
    background: #ffe066;
}

/* =====================================================================
   HERO ESTILO DREAMHOST (2 columnas)
===================================================================== */

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: center;
    max-width: 1200px;
    margin: 3rem auto;
    padding: 2rem 3rem;
}

/* Columna izquierda */
.hero-text {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.2;
    margin: 0;
    text-shadow: 2px 2px 6px rgba(0,0,0,0.45);
}

.hero-subtitle {
    font-size: 1.2rem;
    color: #f0f0f0;
    line-height: 1.6;
}

/* Botón */
.hero-button {
    background-color: #ffcc00;
    color: #000;
    padding: 0.9rem 1.7rem;
    border-radius: 12px;
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: 600;
    width: fit-content;
    transition: 0.3s ease;
}

.hero-button:hover {
    transform: scale(1.05);
    background: #ffe066;
}

/* Columna derecha */
.hero-image-container {
    display: flex;
    justify-content: center;
}

.hero-image {
    width: 95%;
    max-width: 500px;
    border-radius: 24px;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(6px);
    padding: 1rem;
    box-shadow: 0 6px 24px rgba(0,0,0,0.4);
    transition: transform 0.3s ease;
}

.hero-image:hover {
    transform: scale(1.03);
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-text {
        align-items: center;
    }

    .hero-image {
        margin-top: 1rem;
    }
}

/* ===============================
   HERO WRAPPER (FONDO NEGRO)
================================ */

.hero-wrapper {
    width: 100%;
    background: #0d0d0d; /* negro puro visual */
    padding: 4rem 0 3rem 0; /* espaciado del bloque */
    margin-top: 4rem; /* para que no se tape con el nav */
}

.hero-grid {
    max-width: 1200px;
    margin: 0 auto;
}
.hero-title,
.hero-subtitle {
    color: #ffffff;
}
.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* relación 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* CONTENEDOR DE CADA GUÍA */
.guia-card {
    background: rgba(20, 17, 56, 0.55);
    backdrop-filter: blur(18px);
    padding: 2rem;
    border-radius: 18px;
    display: flex;
    gap: 2rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
    margin-bottom: 2.5rem;
    border: 1px solid rgba(255,255,255,0.08);
    animation: fadeIn 0.8s ease;
}

/* ICONOS */
.guia-icon {
    font-size: 3.2rem;
    padding: 1.5rem;
    border-radius: 15px;
    color: white;
    height: fit-content;
}

.visual-icon { background: #6C4BFF; }
.auditiva-icon { background: #FF7B00; }
.motora-icon { background: #008C7A; }

/* TITULOS */
.guia-card h3 {
    font-size: 1.8rem;
    margin-bottom: 0.6rem;
    font-weight: 700;
}

.guia-intro {
    opacity: 0.9;
    margin-bottom: 1rem;
}

/* WRAPPER CONTENIDO */
.guia-content {
    flex: 1;
}

/* ERROR BOX */
.guia-warning {
    background: rgba(255, 186, 0, 0.18);
    border-left: 4px solid #FFBA00;
    padding: 0.8rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

/* EJEMPLO DE CÓDIGO */
.ejemplo-code {
    background: rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 0.5rem;
    font-family: monospace;
    overflow-x: auto;
    margin-bottom: 1rem;
    
}

/* ANIMACIÓN */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   VIDEO CARD PREMIUM (Glass + Glow + Modern)
   Compatible con todo tu diseño actual
============================================================ */

.video-section {
    max-width: 1100px;
    margin: 5rem auto;
    padding: 0 1rem;
}

.video-card {
   
    backdrop-filter: blur(14px);
    border-radius: 18px;
    padding: 1.8rem;
    margin-bottom: 2.5rem;

    border: 1px solid rgba(255,255,255,0.12);
    box-shadow: 0 10px 28px rgba(0,0,0,0.35);

    animation: fadeIn 0.8s ease;

        background: radial-gradient(
        circle at top left,
        rgba(255,255,255,0.18),
        rgba(20,17,56,0.55)
    );
    
}

/* Título del video */
.video-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0 0 0.8rem;
    color: #ffe680;
}

/* Descripción */
.video-description {
    font-size: 1rem;
    opacity: 0.85;
    margin-bottom: 1.2rem;
}

/* Wrapper del video */
.video-frame {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 6px 22px rgba(0,0,0,0.45);
    margin-bottom: 1rem;
    height: 0;
}

.video-frame iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Insignia */
.video-badge {
    display: inline-block;
    padding: 6px 12px;
    background: rgba(255, 204, 0, 0.20);
    border-left: 4px solid #ffcc00;
    border-radius: 8px;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
}

/* Hover suave */
.video-card:hover {
    transform: translateY(-4px);
    transition: 0.3s ease;
    box-shadow: 0 14px 30px rgba(0,0,0,0.45);
}

/* RESPONSIVE */
@media (max-width: 800px) {
    .video-title { font-size: 1.2rem; }
    .video-section { padding: 0 0.2rem; }
}



