/* ==========================================================================
   Proyecto G7: El Profesor Particular Asíncrono - Hoja de Estilos Responsiva
   Archivo: estilos2026.css
   Autores: César Emiliano Cuña y Luis Gonzalo Vazquez Cancelo
   Institución: Ce.R.P. del Norte / UTEC - Feria RoboPampa Octubre 2026
   ========================================================================== */

:root {
    --bg-dark: #0f172a;        /* slate-900 */
    --bg-darker: #020617;      /* slate-950 */
    --bg-card: rgba(30, 41, 59, 0.75); /* slate-800 glass */
    --text-main: #e2e8f0;      /* slate-200 */
    --text-muted: #94a3b8;     /* slate-400 */
    --neon-sky: #38bdf8;       /* sky-400 */
    --neon-cyan: #06b6d4;      /* cyan-500 */
    --neon-emerald: #10b981;   /* emerald-500 */
    --neon-purple: #a855f7;    /* purple-500 */
    --neon-amber: #f59e0b;     /* amber-500 */
}

/* ==========================================================================
   1. RESETEO BASE Y ESTRUCTURA GENERAL DE LA APLICACIÓN
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
}

body.app-layout {
    display: flex;
    flex-direction: column;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
}

/* Área principal donde cargan las 7 secciones */
.main-content-area {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 1.25rem;
    position: relative;
    scroll-behavior: smooth;
}

@media (min-width: 640px) {
    .main-content-area {
        padding: 2rem;
    }
}

/* ==========================================================================
   2. SISTEMA RESPONSIVO: ESCRITORIO (>= 1024px) VS. MÓVIL/TABLET (< 1024px)
   ========================================================================== */

/* Vista Desktop (Pantallas grandes) */
@media (min-width: 1024px) {
    body.app-layout {
        flex-direction: row;
    }

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

    .sidebar-backdrop {
        display: none !important;
    }

    .sidebar-panel {
        position: relative !important;
        transform: translateX(0) !important;
        width: 18rem; /* w-72 */
        flex-shrink: 0;
    }

    .close-drawer-btn {
        display: none !important;
    }
}

/* Vista Tablet y Celular (Menú Hamburguesa Desplegable) */
@media (max-width: 1023px) {
    .mobile-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0.75rem 1rem;
        background-color: #0f172a;
        border-bottom: 1px solid #1e293b;
        z-index: 30;
        flex-shrink: 0;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
    }

    .sidebar-panel {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        width: 18rem;
        max-width: 85vw;
        z-index: 50;
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 8px 0 30px rgba(0, 0, 0, 0.6);
    }

    /* Clase activada por robopapa2026.js al abrir el menú hamburguesa */
    .sidebar-panel.sidebar-open {
        transform: translateX(0) !important;
    }

    .sidebar-backdrop {
        position: fixed;
        inset: 0;
        background-color: rgba(2, 6, 23, 0.8);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        z-index: 40;
        display: none;
        opacity: 0;
        transition: opacity 0.25s ease;
    }

    .sidebar-backdrop.backdrop-open {
        display: block !important;
        opacity: 1;
    }

    .close-drawer-btn {
        position: absolute;
        top: 0.85rem;
        right: 0.85rem;
        color: #94a3b8;
        background: rgba(30, 41, 59, 0.9);
        border: 1px solid #334155;
        border-radius: 0.5rem;
        padding: 0.35rem 0.65rem;
        cursor: pointer;
        transition: all 0.2s ease;
    }

    .close-drawer-btn:hover {
        color: #ffffff;
        border-color: var(--neon-sky);
    }
}

/* ==========================================================================
   3. MENÚ LATERAL (SIDEBAR) Y BOTONES DE NAVEGACIÓN SPA
   ========================================================================== */
.sidebar-panel {
    background-color: #0f172a;
    border-right: 1px solid #1e293b;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    user-select: none;
}

.hamburger-btn {
    color: var(--text-main);
    background-color: #1e293b;
    border: 1px solid #334155;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.hamburger-btn:hover,
.hamburger-btn:focus {
    color: var(--neon-sky);
    border-color: var(--neon-sky);
    outline: none;
}

.nav-link {
    border-left: 4px solid transparent;
    background: transparent;
    border-top: none;
    border-right: none;
    border-bottom: none;
    cursor: pointer;
    transition: all 0.25s ease;
    text-decoration: none;
}

.nav-link:hover {
    background-color: rgba(30, 41, 59, 0.6);
    color: #ffffff;
}

.nav-link.active {
    background-color: rgba(14, 165, 233, 0.18);
    border-left: 4px solid var(--neon-sky);
    color: var(--neon-sky) !important;
    font-weight: 600;
}

/* ==========================================================================
   4. EFECTOS GLASSMORPHISM, BORDES NEÓN Y LOGOTIPOS
   ========================================================================== */
.glass {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(56, 189, 248, 0.2);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.35);
}

.logo-glow {
    filter: drop-shadow(0 0 12px rgba(56, 189, 248, 0.35));
    transition: transform 0.3s ease;
}

.neon-glow {
    transition: all 0.3s ease;
}

.neon-glow:hover {
    box-shadow: 0 0 18px rgba(56, 189, 248, 0.35);
    transform: translateY(-2px);
}

.neon-border {
    border-color: var(--neon-sky) !important;
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.22);
}

.neon-border-success {
    border: 2px solid var(--neon-emerald);
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.4), inset 0 0 10px rgba(16, 185, 129, 0.2);
}

.neon-text {
    color: #22d3ee;
    text-shadow: 0 0 8px rgba(34, 211, 238, 0.6);
}

/* Estado seleccionado para las tarjetas de temas del Paso 1 */
.tema-card {
    transition: all 0.25s ease;
}

.tema-card.selected {
    border-color: var(--neon-sky) !important;
    background: rgba(14, 165, 233, 0.16);
    box-shadow: 0 0 18px rgba(56, 189, 248, 0.38);
    transform: translateY(-2px);
}

/* ==========================================================================
   5. FORMULARIOS, RADIO BUTTONS, AUDIO Y BOTÓN ORCID
   ========================================================================== */

/* Resaltado dinámico al marcar un radio button en la rúbrica */
input[type="radio"]:checked + span {
    color: var(--neon-sky);
    font-weight: 700;
    text-shadow: 0 0 6px rgba(56, 189, 248, 0.4);
}

audio#audio-demo {
    height: 42px;
    border-radius: 0.5rem;
    background-color: #020617;
}

/* Botón de enlace a ORCID (Luis Gonzalo Vazquez Cancelo) */
.orcid-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.75rem;
    font-weight: 700;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    background-color: rgba(16, 185, 129, 0.15);
    color: #6ee7b7;
    padding: 0.45rem 0.85rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(16, 185, 129, 0.45);
    text-decoration: none;
    transition: all 0.2s ease;
}

.orcid-btn:hover {
    background-color: #059669;
    color: #ffffff;
    border-color: #10b981;
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.45);
}

/* ==========================================================================
   6. VISIBILIDAD DE SECCIONES Y ANIMACIONES
   ========================================================================== */
.hidden-section,
.hidden-step {
    display: none !important;
}

.fade-in {
    animation: fadeIn 0.4s ease-in-out forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.transition-all-custom {
    transition: all 0.3s ease;
}

/* ==========================================================================
   7. BARRA DE DESPLAZAMIENTO (SCROLLBAR) PERSONALIZADA
   ========================================================================== */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--neon-sky);
}