/* 🌌 Estilos del Ecosistema .agent — Glassmorphism & Cyberpunk Premium */

/* 🎨 Variables y Paleta de Colores Curada */
:root {
    --bg-dark: #05070f;
    --bg-surface: rgba(18, 22, 45, 0.75);
    --bg-surface-active: rgba(30, 36, 75, 0.9);
    --border-color: rgba(255, 255, 255, 0.12);
    --border-color-glow: rgba(0, 242, 254, 0.6);
    
    /* Neones HSL */
    --neon-cyan: #00f2fe;
    --neon-purple: #8e2de2;
    --neon-purple-light: #4a00e0;
    --neon-pink: #ff007f;
    --neon-green: #39ff14;
    
    /* Texto - Alta Visibilidad para Charlas/Presentaciones */
    --text-primary: #ffffff;
    --text-secondary: #f1f5f9; /* Mucho más claro y visible (slate-100) */
    --text-muted: #cbd5e1;     /* Mucho más claro que el anterior (slate-300) */
    
    /* Tipografía */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Space Grotesk', sans-serif;
}

/* 🌀 Control de Desplazamiento y Scroll Snapping (Solo en Escritorio / Laptops) */
@media (min-width: 992px) {
    html {
        scroll-behavior: smooth;
        scroll-snap-type: y proximity; /* Más fluido y natural, evita la sensación de lentitud o bloqueo forzado */
        overflow-y: scroll;
        height: 100%;
    }

    .fullscreen-section {
        min-height: 100vh;
        height: 100vh; /* Pantalla completa exacta */
        display: flex;
        flex-direction: column; /* Flujo vertical para control de márgenes */
        align-items: center;
        justify-content: flex-start; /* Alinea los contenidos arriba para que comiencen debajo del header flotante */
        scroll-snap-align: start;
        scroll-snap-stop: always;
        position: relative;
        box-sizing: border-box;
        padding: 3rem 1rem 3.5rem 1rem; /* Permite que el recuadro suba e ingrese por debajo del header flotante */
        scroll-margin-top: 2rem; /* Sincronizado para anclajes con superposición */
        overflow: hidden;
    }

    /* 🪐 El Hero se mantiene perfectamente centrado verticalmente */
    #hero.fullscreen-section {
        justify-content: center;
    }

    /* 🎯 Evita que my-auto empuje las filas principales hacia abajo en escritorio */
    .fullscreen-section > .row {
        margin-top: 0 !important;
        margin-bottom: auto !important;
    }

    /* 📁 El Explorador (Sección 2) se mantiene estrictamente fijo en pantalla completa */
    #explorer.fullscreen-section {
        overflow: hidden !important;
    }

    /* 🖥️ Ajustes de Proporciones y Alturas en Pantallas Grandes para la Sección 2 */
    #explorer .explorer-container {
        height: 58vh;
        min-height: 480px;
    }

    #explorer .explorer-panel {
        height: 100% !important;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
    }

    /* 🌀 Scroll inteligente y sutil solo para el bloque de contenidos internos del panel derecho */
    #explorer .dynamic-scroll-content {
        max-height: calc(58vh - 100px) !important;
        overflow-y: auto !important;
        padding-right: 0.5rem;
    }

    #explorer .explorer-tree {
        flex-grow: 1;
        padding-right: 1rem;
    }

    #explorer #dynamic-pane .explorer-panel > div:first-child {
        flex-shrink: 0;
    }

    #explorer #dynamic-pane .code-window {
        flex-grow: 1;
        display: flex;
        flex-direction: column;
        min-height: 0;
        margin-top: 1rem;
    }

    #explorer #dynamic-pane .code-body {
        flex-grow: 1;
        overflow-y: auto;
        max-height: calc(58vh - 280px) !important;
        min-height: 180px;
    }
}

/* 📱 Comportamiento Fluido e Ilimitado en Móviles y Tablets */
@media (max-width: 1024px) {
    html {
        scroll-snap-type: none !important; /* Desactivar snapping */
        height: auto;
    }

    .fullscreen-section,
    #explorer.fullscreen-section,
    #skills-education.fullscreen-section,
    #agent-workflow.fullscreen-section {
        min-height: auto !important;
        height: auto !important; /* Altura natural basada en el contenido */
        display: block !important; /* Desactivar flexbox rígido */
        padding: 3.5rem 1.2rem 3rem 1.2rem !important; /* Permite superposición responsiva debajo del header flotante */
        scroll-margin-top: 2.5rem; /* Sincronizado para anclajes con superposición */
        scroll-snap-align: none !important;
        overflow: visible !important; /* IMPORTANTE: Muestra el desborde para que no se oculte nada en móvil/tablets */
    }

    /* 🪐 Ajuste Premium para la Portada (Sección 1) en Celulares y Tablets */
    #hero.fullscreen-section {
        padding-top: 8rem !important; /* Espacio generoso para evitar que el header tape el título o el badge */
        padding-bottom: 5rem !important;
        min-height: 85vh !important; /* Ocupa gran parte de la pantalla para presentarse como una portada majestuosa */
        display: flex !important;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }

    /* 📁 Adaptaciones Específicas del Explorador (Sección 2) para Celulares y Tablets */
    #explorer .explorer-container {
        min-height: auto;
    }

    #explorer .explorer-container .explorer-panel {
        height: auto !important;
        min-height: auto !important;
    }

    #explorer .explorer-tree-col {
        border-right: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.15) !important;
        padding-right: 0 !important;
        padding-bottom: 1.5rem !important;
        margin-bottom: 1.5rem !important;
    }

    #explorer .explorer-tree {
        border-right: none !important;
        border-bottom: none !important;
        padding-right: 0 !important;
        padding-bottom: 0 !important;
    }

    #explorer #dynamic-pane .code-body {
        max-height: 350px !important; /* Mantiene el visor de código con scroll interno compacto */
    }

    /* Fluidez total para que en móvil crezca de forma natural sin scroll de envoltura */
    #explorer .dynamic-scroll-content {
        height: auto !important;
        overflow: visible !important;
    }
}

/* 🪐 Configuración General y Fondos */
body {
    background-color: var(--bg-dark);
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(142, 45, 226, 0.22) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(0, 242, 254, 0.18) 0%, transparent 40%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 1.2rem; /* Letra base ligeramente más grande */
    line-height: 1.8;
    min-height: 100vh;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #ffffff;
}

p, li, span, code {
    /* Aseguramos máxima legibilidad en contrastes oscuros */
    text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}

/* 🚀 Sobrescribir colores de Bootstrap de baja visibilidad */
.text-secondary {
    color: var(--text-secondary) !important; /* Blanco slate de alta visibilidad */
}

.text-muted {
    color: var(--text-muted) !important; /* Gris slate claro de alta visibilidad */
}

.glass-card p {
    color: var(--text-secondary);
    font-size: 1.25rem; /* Letra de descripción más grande para el proyector */
    line-height: 1.8;
}

.lead {
    font-size: 1.5rem;
    font-weight: 400;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

/* ✨ Efecto de Texto en Degradado */
.gradient-text {
    background: linear-gradient(135deg, var(--neon-cyan) 0%, #ffffff 50%, var(--neon-purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

/* 🧪 Tarjetas con Efecto de Cristal (Glassmorphism) */
.glass-card {
    background: var(--bg-surface);
    backdrop-filter: blur(10px) saturate(180%); /* Optimizado de 20px a 10px para un rendimiento de scroll ultra-rápido de 60/120fps */
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    box-shadow: 0 10px 40px 0 rgba(0, 0, 0, 0.5);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent);
    pointer-events: none;
    z-index: 1;
}

.glass-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 242, 254, 0.45);
    box-shadow: 0 15px 50px 0 rgba(0, 242, 254, 0.25);
}

/* 📁 Explorador de Directorios Interactivo */
.explorer-container {
    min-height: 520px;
}

.explorer-tree {
    border-right: 1px solid var(--border-color);
    padding-right: 1.5rem;
    position: relative;
}

/* Línea de guía vertical jerárquica (VS Code Style) */
.explorer-tree::before {
    content: '';
    position: absolute;
    top: 36px;
    left: 21px;
    bottom: 22px;
    width: 2px;
    background: rgba(0, 242, 254, 0.15); /* Guía brillante */
    border-radius: 4px;
}

.tree-node {
    cursor: pointer;
    padding: 0.65rem 1rem;
    border-radius: 8px;
    margin-bottom: 0.35rem;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    position: relative;
    border: 1px solid transparent;
}

.tree-node i {
    width: 20px;
    font-size: 1.15rem;
    margin-right: 0.6rem;
    transition: all 0.25s ease;
}

.tree-node.file-node {
    margin-left: 1.8rem; /* Desplazamiento jerárquico claro */
}

/* Conectores horizontales sutiles para cada carpeta */
.tree-node.file-node::before {
    content: '';
    position: absolute;
    left: -16px;
    top: 50%;
    width: 12px;
    height: 2px;
    background: rgba(0, 242, 254, 0.15);
}

.tree-node:hover {
    background: rgba(255, 255, 255, 0.04);
    color: white;
    border-color: rgba(255, 255, 255, 0.05);
}

.tree-node:hover i {
    transform: scale(1.15);
    color: var(--neon-cyan);
}

/* Estado Activo: Cápsula Cyberpunk Vibrante */
.tree-node.active-folder {
    background: rgba(0, 242, 254, 0.08) !important;
    color: #ffffff !important;
    border-color: rgba(0, 242, 254, 0.3) !important;
    box-shadow: 0 0 15px rgba(0, 242, 254, 0.15);
    font-weight: 600;
}

.tree-node.active-folder i {
    color: var(--neon-cyan) !important;
    text-shadow: 0 0 8px rgba(0, 242, 254, 0.6);
}

/* Flecha indicadora a la derecha cuando está activa */
.tree-node.active-folder::after {
    content: '➔';
    position: absolute;
    right: 12px;
    font-size: 0.8rem;
    color: var(--neon-cyan);
    opacity: 0.8;
    animation: slideArrow 1.5s infinite alternate;
}

@keyframes slideArrow {
    0% { transform: translateX(0); }
    100% { transform: translateX(4px); }
}

/* 🧬 Tarjetas Detalladas de Módulos (Grid) */
.module-badge {
    background: rgba(0, 242, 254, 0.12);
    color: var(--neon-cyan);
    border: 1px solid rgba(0, 242, 254, 0.3);
    font-size: 0.85rem; /* Más grande */
    padding: 0.4rem 1.1rem;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    display: inline-block;
    margin-bottom: 1rem;
    text-shadow: 0 0 5px rgba(0, 242, 254, 0.3);
}

.module-icon {
    font-size: 2.6rem;
    margin-bottom: 1.2rem;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

/* 🔌 Botones Neón */
.neon-btn {
    background: transparent;
    border: 2px solid var(--neon-cyan); /* Borde más grueso */
    color: var(--neon-cyan);
    padding: 0.9rem 2.2rem; /* Más grande */
    border-radius: 50px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    transition: all 0.3s ease;
    box-shadow: 0 0 15px rgba(0, 242, 254, 0.15);
    font-size: 0.95rem;
}

.neon-btn:hover {
    background: var(--neon-cyan);
    color: var(--bg-dark);
    box-shadow: 0 0 30px rgba(0, 242, 254, 0.5);
    transform: translateY(-3px);
}

.neon-btn-purple {
    border-color: var(--neon-purple);
    color: var(--neon-purple);
    box-shadow: 0 0 15px rgba(142, 45, 226, 0.15);
}

.neon-btn-purple:hover {
    background: var(--neon-purple);
    color: white;
    box-shadow: 0 0 30px rgba(142, 45, 226, 0.5);
}

/* 💡 Visor de Código Emulado */
.code-window {
    background: #06080e;
    border-radius: 14px;
    border: 1px solid var(--border-color);
    font-family: 'Fira Code', 'Courier New', Courier, monospace;
    font-size: 0.92rem; /* Más grande y legible */
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.code-header {
    background: rgba(255, 255, 255, 0.04);
    padding: 0.7rem 1.2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.code-dots span {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 6px;
}

.code-dot-red { background-color: #ff5f56; }
.code-dot-yellow { background-color: #ffbd2e; }
.code-dot-green { background-color: #27c93f; }

.code-body {
    padding: 1.5rem;
    margin: 0;
    color: #f8fafc;
    max-height: 400px;
    overflow-y: auto;
    line-height: 1.5;
}

/* 🎬 🎬 MODO PRESENTACIÓN (SLIDE SYSTEM FULLSCREEN) 🎬 🎬 */
.presentation-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at center, #0e1124 0%, #04050a 100%);
    z-index: 9999;
    display: none; /* Se activa vía JS */
    align-items: center;
    justify-content: center;
    padding: 2rem;
    animation: fadeIn 0.3s ease-out;
}

.presentation-active {
    display: flex !important;
    overflow: hidden;
}

.slide-deck {
    width: 100%;
    max-width: 1400px; /* Incrementado para ocupar casi todo el ancho de la pantalla */
    height: 100%;
    max-height: 85vh; /* Incrementado para ocupar casi toda la altura de la pantalla */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

.slide-card {
    background: rgba(18, 22, 45, 0.8);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 2px solid rgba(0, 242, 254, 0.25);
    border-radius: 24px;
    padding: 1.5rem 2rem 2.2rem 2rem; /* Relleno compacto para dar el 100% de prioridad y espacio a la imagen */
    flex-grow: 1;
    display: none; /* Se maneja dinámicamente */
    flex-direction: column;
    justify-content: flex-start; /* Lleva la cabecera arriba y deja el resto a la imagen */
    align-items: center;
    box-shadow: 0 0 50px rgba(0, 242, 254, 0.15);
    transform: scale(0.95);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    opacity: 0;
    box-sizing: border-box;
    height: 100%;
}

.slide-card.active-slide {
    display: flex;
    transform: scale(1);
    opacity: 1;
}

/* Tipografía de las diapositivas */
.slide-card h2 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.slide-card p {
    font-size: 1.5rem;
    color: #e2e8f0;
    line-height: 1.8;
}

.slide-card ul {
    font-size: 1.35rem;
    color: #f1f5f9;
    margin-top: 1.5rem;
    line-height: 2;
}

.slide-card li i {
    color: var(--neon-cyan);
    margin-right: 0.8rem;
}

/* Navegación de Diapositivas en el medio de la pantalla */
.presentation-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    width: 100%;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    pointer-events: none; /* Permite clicks pasantes en el medio */
    z-index: 10;
}

.slide-btn {
    background: rgba(18, 22, 45, 0.9);
    border: 2px solid var(--neon-cyan);
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(0, 242, 254, 0.4);
    transition: all 0.3s ease;
    pointer-events: auto; /* Reactiva clicks en los botones */
}

.slide-btn:hover {
    background: var(--neon-cyan);
    color: var(--bg-dark);
    transform: scale(1.1);
    box-shadow: 0 0 30px rgba(0, 242, 254, 0.7);
    border-color: var(--neon-cyan);
}

#btn-prev-slide {
    position: absolute;
    left: -80px; /* Sacado fuera de la tarjeta a la izquierda */
}

#btn-next-slide {
    position: absolute;
    right: -80px; /* Sacado fuera de la tarjeta a la derecha */
}

.slide-progress {
    position: absolute;
    bottom: -50px; /* Colocado discretamente debajo de la diapositiva */
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--font-mono);
    font-size: 1.2rem;
    font-weight: 700;
    color: white;
    background: rgba(10, 13, 30, 0.85);
    padding: 0.5rem 1.5rem;
    border-radius: 100px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 5px 15px rgba(0,0,0,0.5);
    pointer-events: auto;
}

.close-presentation-btn {
    position: absolute;
    top: 2rem;
    right: 2rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.6rem 1.4rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 10005;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.close-presentation-btn:hover {
    background: var(--neon-pink);
    border-color: var(--neon-pink);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(255, 0, 127, 0.5);
}

.slide-progress {
    color: var(--text-secondary);
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 600;
}

/* 🎛️ Contenedor de Detalle Dinámico */
.detail-pane {
    animation: fadeIn 0.4s ease-out;
}

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

/* 📱 Personalizaciones Responsive */
@media (max-width: 1024px) {
    .explorer-tree {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        padding-right: 0;
        padding-bottom: 1.5rem;
        margin-bottom: 1.5rem;
    }
    .slide-card {
        padding: 2rem;
        overflow-y: auto !important; /* Permitir scroll si el contenido es alto en pantallas chicas */
    }
    .slide-card h2 {
        font-size: 2.2rem;
    }
    .slide-card p {
        font-size: 1.15rem;
    }
    /* Maximizar altura del frame de imagen ocupando casi toda la pantalla */
    .gallery-img-frame {
        height: 55vh !important;
    }
    /* Convertir botón cerrar en un círculo minimalista premium en móviles */
    .close-presentation-btn {
        top: 1rem !important;
        right: 1rem !important;
        padding: 0 !important;
        width: 44px !important;
        height: 44px !important;
        border-radius: 50% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    /* Controles de diapositivas adaptados */
    .slide-btn {
        width: 48px !important;
        height: 48px !important;
        font-size: 1.2rem !important;
    }
    .presentation-controls {
        position: absolute !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        margin-top: 0 !important;
    }
    #btn-prev-slide {
        left: 10px !important;
    }
    #btn-next-slide {
        right: 10px !important;
    }
    .slide-progress {
        bottom: -35px !important;
        font-size: 1rem !important;
        padding: 0.3rem 1.2rem !important;
    }
}

/* 📱 Ajustes ultra-compactos para móviles pequeños */
@media (max-width: 576px) {
    .slide-card {
        padding: 1.2rem !important;
    }
    .slide-card h2 {
        font-size: 1.8rem !important;
    }
    .gallery-img-frame {
        height: 48vh !important;
    }
    .presentation-overlay {
        padding: 0.8rem !important;
    }
    .slide-btn {
        width: 44px !important;
        height: 44px !important;
        font-size: 1.1rem !important;
    }
    .presentation-controls {
        position: absolute !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        margin-top: 0 !important;
    }
    #btn-prev-slide {
        left: 5px !important;
    }
    #btn-next-slide {
        right: 5px !important;
    }
    .slide-progress {
        bottom: -25px !important;
        font-size: 0.85rem !important;
        padding: 0.2rem 1rem !important;
    }
}

/* 🖱️ Personalización de Barra de Desplazamiento */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--neon-cyan);
}

/* 🖼️ Galería Premium en Diapositivas del Modo Charla */
.gallery-card {
    border-radius: 20px;
    background: rgba(5, 7, 15, 0.8) !important;
    width: 100%;
    flex-grow: 1; /* Ocupa todo el espacio vertical disponible */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    max-width: 100% !important;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), border-color 0.3s, box-shadow 0.3s;
}

/* Contenedor del Plano 1 (Brillo Cyan) */
.gallery-card.cyan-glow {
    border: 1px solid rgba(0, 242, 254, 0.35) !important;
}
.gallery-card.cyan-glow:hover {
    transform: scale(1.005);
    border-color: rgba(0, 242, 254, 0.8) !important;
    box-shadow: 0 0 25px rgba(0, 242, 254, 0.2);
}

/* Contenedor del Plano 2 (Brillo Púrpura) */
.gallery-card.purple-glow {
    border: 1px solid rgba(142, 45, 226, 0.35) !important;
}
.gallery-card.purple-glow:hover {
    transform: scale(1.005);
    border-color: rgba(142, 45, 226, 0.8) !important;
    box-shadow: 0 0 25px rgba(142, 45, 226, 0.2);
}

/* Marco oscurecido y centrado de la Imagen */
.gallery-img-frame {
    border-radius: 12px;
    overflow: hidden;
    background: transparent; /* Fondo transparente para máxima fidelidad visual */
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
}

.gallery-img-frame img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain; /* Ajuste fluido inteligente que respeta relaciones rectangular/cuadrada */
    border-radius: 8px;
}

/* 🧭 BARRA DE NAVEGACIÓN FLOTANTE Y GLASSMORPHIC */
html {
    scroll-behavior: smooth;
}

.floating-navbar {
    position: fixed;
    top: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    width: 90%;
    max-width: 800px;
    background: rgba(10, 13, 30, 0.75);
    backdrop-filter: blur(12px); /* Optimizado de 25px a 12px para maximizar fps durante el scroll */
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 100px;
    padding: 0.6rem 2rem;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.6);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.nav-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.nav-brand {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.3rem;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links {
    display: flex;
    gap: 0.4rem;
}

.nav-item {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-decoration: none;
    padding: 0.5rem 1.2rem;
    border-radius: 50px;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    border: 1px solid transparent;
}

.nav-item i {
    transition: transform 0.3s;
}

.nav-item:hover {
    color: white;
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.05);
}

.nav-item:hover i {
    transform: scale(1.15);
}

.nav-item.active-nav {
    color: var(--bg-dark) !important;
    background: var(--neon-cyan);
    border-color: var(--neon-cyan);
    box-shadow: 0 0 15px rgba(0, 242, 254, 0.4);
    font-weight: 700;
}

.nav-item.active-nav i {
    color: var(--bg-dark);
}

/* Adaptación responsiva para móviles */
@media (max-width: 768px) {
    .floating-navbar {
        top: 1rem;
        padding: 0.5rem 1rem;
    }
    .nav-brand {
        display: none; /* Oculta logo en pantallas chicas para dar más espacio a los botones */
    }
    .nav-container {
        justify-content: center;
    }
    .nav-links {
        width: 100%;
        justify-content: space-around;
    }
    .nav-item {
        padding: 0.4rem 0.9rem;
        font-size: 0.8rem;
    }
}

/* 🏷️ Títulos de Tarjetas de Características (Standout) */
.feature-title {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.01em;
    margin-bottom: 0.75rem;
    display: inline-block;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.col-md-4:hover .feature-title {
    color: var(--neon-cyan) !important;
    text-shadow: 0 0 10px rgba(0, 242, 254, 0.4);
}

/* 🛣️ Estilos de la Sección de Flujo (Workflow) */
.workflow-card {
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    backdrop-filter: blur(10px);
}
.workflow-card:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.04) !important;
    border-color: rgba(0, 242, 254, 0.25) !important;
    box-shadow: 0 10px 30px rgba(0, 242, 254, 0.08);
}
.step-badge-top {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-dark);
    border: 1px solid rgba(255, 255, 255, 0.15);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    color: white;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    z-index: 2;
    transition: all 0.3s;
}
.workflow-card:hover .step-badge-top {
    border-color: var(--neon-cyan);
    color: var(--neon-cyan);
    box-shadow: 0 0 10px rgba(0, 242, 254, 0.3);
}

/* Conectores visuales para pantallas grandes (Timeline style) */
@media (min-width: 992px) {
    .workflow-step {
        position: relative;
    }
    .workflow-step:not(:last-child)::after {
        content: '➔';
        position: absolute;
        right: -12px;
        top: 50%;
        transform: translateY(-50%);
        font-size: 1.5rem;
        color: rgba(0, 242, 254, 0.3);
        pointer-events: none;
        z-index: 10;
        animation: pulseConnector 2s infinite alternate;
    }
}

@keyframes pulseConnector {
    0% { opacity: 0.3; transform: translate(-2px, -50%); }
    100% { opacity: 0.8; transform: translate(2px, -50%); }
}

@media (max-width: 1024px) {
    .workflow-steps-container {
        padding-top: 1.5rem;
    }
    .workflow-step {
        margin-bottom: 1.5rem;
    }
}

/* 🏷️ Workflow Badges para máxima visibilidad */
.workflow-badge {
    display: inline-block;
    padding: 0.35rem 1.1rem;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.85rem;
    border: 1px solid transparent;
}

.workflow-badge.badge-cyan {
    background: rgba(0, 242, 254, 0.12) !important;
    color: #00f2fe !important;
    border-color: rgba(0, 242, 254, 0.35) !important;
    text-shadow: 0 0 5px rgba(0, 242, 254, 0.4);
}

.workflow-badge.badge-yellow {
    background: rgba(255, 189, 46, 0.12) !important;
    color: #ffbd2e !important;
    border-color: rgba(255, 189, 46, 0.35) !important;
    text-shadow: 0 0 5px rgba(255, 189, 46, 0.4);
}

.workflow-badge.badge-red {
    background: rgba(255, 0, 127, 0.12) !important;
    color: #ff007f !important;
    border-color: rgba(255, 0, 127, 0.35) !important;
    text-shadow: 0 0 5px rgba(255, 0, 127, 0.4);
}

.workflow-badge.badge-green {
    background: rgba(57, 255, 20, 0.12) !important;
    color: #39ff14 !important;
    border-color: rgba(57, 255, 20, 0.35) !important;
    text-shadow: 0 0 5px rgba(57, 255, 20, 0.4);
}
