﻿:root {
    --primary-color: #7c3aed; /* Morado para acentos importantes */
    --secondary-color: #0f172a; /* Azul marino corporativo */
    --bg-university: #1e40af; /* Azul universitario intenso real para el fondo */
    --card-bg: #ffffff; /* Blanco puro para las tarjetas */
    --text-dark: #0f172a; /* Color oscuro para legibilidad perfecta */
    --text-muted: #334155;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-family: 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-university);
}

/* --- HEADER EN BLOQUES HORIZONTALES Y FONDO BLANCO --- */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #ffffff !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    z-index: 1000;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 15px;
}

.uni-logo {
    height: 70px; /* Tamaño imponente */
    width: auto;
}

.logo-text {
    font-size: 2rem;
    font-weight: 800;
    color: var(--secondary-color);
}

.year-highlight {
    color: var(--primary-color);
}

/* Menú estructurado en línea horizontal continua */
.main-nav ul {
    display: flex !important;
    flex-direction: row !important;
    gap: 30px;
    list-style: none !important;
}

.main-nav a {
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--secondary-color);
    transition: color 0.2s;
}

.main-nav a:hover {
    color: var(--primary-color);
}

/* --- HERO CON TRANSICIÓN DE PALABRAS EN FADE --- */
.hero-section {
    padding: 180px 20px 80px 20px;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 40px;
}

.hero-left {
    flex: 1.2;
    max-width: 55%; /* Límite estricto para proteger el área derecha */
}

.hero-right {
    flex: 0.8;
}

.hero-subtitle {
    color: #fcd34d;
    font-weight: 700;
    display: block;
    margin-bottom: 15px;
}

.hero-title {
    font-size: 2.8rem;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.4;
    margin-bottom: 20px;
}

/* Contenedor estable de la animación */
.animation-wrapper {
    display: inline-block;
    position: relative;
    vertical-align: top;
    min-width: 320px;
    height: 3.5rem;
}

/* Cada palabra en posición absoluta para transiciones fluidas */
.animated-word {
    position: absolute;
    left: 0;
    top: 0;
    color: #fcd34d !important;
    font-weight: 800;
    opacity: 0;
    white-space: nowrap;
    transform: translateY(10px);
    animation: smoothWordChange 9s infinite ease-in-out;
}

/* Tiempos de retraso para el bucle continuo (3s por palabra) */
.word-1 { animation-delay: 0s; }
.word-2 { animation-delay: 3s; }
.word-3 { animation-delay: 6s; }

/* Ciclo de animación: entrada suave, pausa larga de 2.5s para lectura y salida suave */
@keyframes smoothWordChange {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }
    5% {
        opacity: 1;
        transform: translateY(0);
    }
    28% {
        opacity: 1;
        transform: translateY(0);
    }
    33.33% {
        opacity: 0;
        transform: translateY(-10px);
    }
    100% {
        opacity: 0;
    }
}

.hero-description {
    color: #e2e8f0;
    font-size: 1.2rem;
    line-height: 1.6;
    margin-bottom: 30px;
}

.btn-primary {
    background: linear-gradient(135deg, #7c3aed, #4f46e5);
    color: #ffffff;
    border: none;
    padding: 15px 32px;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

/* Desplazamiento preventivo del robot hacia abajo */
.hero-image-wrapper {
    margin-top: 50px;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 30px rgba(0,0,0,0.4);
}

.hero-img {
    width: 100%;
    display: block;
}

/* --- SECCIÓN PONENTES --- */
.speakers-section {
    padding: 80px 20px;
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.section-title {
    font-size: 2.5rem;
    color: white;
    margin-bottom: 10px;
}

.section-subtitle {
    color: #e2e8f0;
    margin-bottom: 40px;
}

.speakers-grid {
    display: flex;
    justify-content: center;
    gap: 35px;
    flex-wrap: wrap;
}

.speaker-card {
    background-color: var(--card-bg);
    border-radius: 16px;
    overflow: hidden;
    width: 320px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.speaker-image {
    height: 240px;
    width: 100%;
}

.speaker-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.speaker-info {
    padding: 20px;
    text-align: left;
}

.speaker-info h3 {
    color: var(--text-dark);
    font-size: 1.3rem;
    margin-bottom: 5px;
}

.speaker-info .specialty {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.95rem;
}

/* --- SECCIÓN REGISTRO Y BENEFICIOS (COLORES OSCUROS INTENSOS) --- */
.registration-section {
    padding: 80px 20px;
}

.registration-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    gap: 40px;
    align-items: stretch; /* Altura simétrica */
}

.form-box {
    flex: 1;
    background-color: var(--card-bg);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.benefits-box {
    flex: 1;
    background-color: var(--card-bg);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Forzar color oscuro en los dos cuadros blancos */
.form-box *, .benefits-box * {
    color: var(--text-dark) !important;
}

.form-tag {
    color: var(--primary-color) !important;
    font-weight: 800;
    display: block;
    margin-bottom: 10px;
}

.form-title, .benefits-title {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 25px;
}

.form-group {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 700;
}

.form-group label i {
    color: var(--primary-color) !important;
}

.form-group input, .form-group select {
    padding: 14px;
    border: 2px solid #cbd5e1;
    border-radius: 10px;
    background-color: #f8fafc;
    font-size: 1rem;
}

.btn-submit {
    width: 100%;
    background: linear-gradient(135deg, #7c3aed, #4f46e5);
    color: white !important;
    border: none;
    padding: 16px;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 15px;
}

/* Estilo de lista distribuida llenando el espacio */
.benefits-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 30px;
    height: 100%;
    justify-content: center;
}

.benefits-list li {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.icon-wrap {
    font-size: 2rem;
}

.benefits-list strong {
    font-size: 1.15rem;
    font-weight: 700;
    display: block;
    margin-bottom: 4px;
}

.benefits-list p {
    color: var(--text-muted) !important;
    line-height: 1.5;
}

/* --- FOOTER --- */
.main-footer {
    background-color: #0f172a;
    color: white;
    padding: 40px 20px;
    text-align: center;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
}

.author-credits {
    font-size: 1.1rem;
    margin-bottom: 15px;
}

.author-credits i {
    color: #fcd34d;
}

.footer-copyright {
    font-size: 0.9rem;
    color: #94a3b8;
}

/* --- RESPONSIVE MÓVIL --- */
@media (max-width: 968px) {
    .hero-container, .registration-container {
        flex-direction: column;
    }
    .hero-left {
        max-width: 100%;
    }
    .animation-wrapper {
        height: auto;
        min-width: 100%;
    }
    .animated-word {
        position: relative;
        opacity: 1 !important;
        transform: none !important;
        animation: none !important;
        display: block;
        margin-bottom: 5px;
    }
    .word-2, .word-3 {
        display: none; /* En celular dejamos fija la primera por espacio */
    }
    .main-nav ul {
        gap: 15px;
    }
    .logo-text {
        font-size: 1.5rem;
    }
    .uni-logo {
        height: 50px;
    }
}