/* ============================================= */
/* --- ESTILOS SECCIÓN RESULTADOS (AUTOMÁTICO) --- */
/* ============================================= */

.resultados-container {
    position: relative;
    width: 100%;
    min-height: 100vh; /* Altura normal de pantalla */
    background-color: #050505;
    /*z-index: 5;*/
    overflow: hidden;
	background-image: url('../media/images/backgrounds/background_resultados_previos.png');
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
}

.resultados-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
}

.resultados-content {
    display: flex;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    /* Ajuste para que no tape el header y se desplace a la derecha */
    padding: 120px 20px 80px 100px; 
}

.resultados-left {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* El título aparece siempre desde el inicio */
.res-title {
    max-width: 450px;
    height: auto;
    margin-bottom: 60px;
    opacity: 1;
}

.resultados-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* --- ESTADO INICIAL DE LAS IMÁGENES (OCULTAS) --- */
.res-step {
    opacity: 0;
    transform: translateY(30px); /* Entran desde abajo suavemente */
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform;
}

/* Indentación escalonada */
.res-indent-1 { margin-left: 0; }
.res-indent-2 { margin-left: 60px; }
.res-indent-3 { margin-left: 120px; }
.res-indent-4 { margin-left: 180px; }

.res-item img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

/* --- SECUENCIA AUTOMÁTICA (ACTIVADA POR JS) --- */
/* Usamos delays para que aparezcan una por una */
.section-active .res-step[data-step="1"] { opacity: 1; transform: translateY(0); transition-delay: 0.2s; }
.section-active .res-step[data-step="2"] { opacity: 1; transform: translateY(0); transition-delay: 0.6s; }
.section-active .res-step[data-step="3"] { opacity: 1; transform: translateY(0); transition-delay: 1.0s; }
.section-active .res-step[data-step="4"] { opacity: 1; transform: translateY(0); transition-delay: 1.4s; }
.section-active .res-step[data-step="5"] { opacity: 1; transform: translateY(0); transition-delay: 1.8s; }

.resultados-right {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
	padding-right:100px;
}

.btn-ver-video img {
    height: 65px;
    width: auto;
    transition: transform 0.3s ease;
}

.btn-ver-video:hover img {
    transform: scale(1.05);
}

/* Ajustes Móvil */
@media (max-width: 992px) {
    .resultados-content { padding-left: 20px; padding-top: 100px; flex-direction: column; }
    .res-indent-2, .res-indent-3, .res-indent-4 { margin-left: 20px; }
    .resultados-right { justify-content: center; margin-top: 50px; padding-right:0; }
}

/* ============================================= */
/* --- MODAL DE VIDEO YOUTUBE FUTURISTA --- */
/* ============================================= */

.video-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85); /* Fondo negro semitransparente */
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.video-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* El marco del reproductor */
.video-modal-content {
    position: relative;
    width: 90%;
    max-width: 1000px; /* Tamaño máximo en pantallas grandes */
    background: #050505;
    /* Borde naranja y resplandor estilo ciberpunk */
    border: 1px solid var(--primary-orange, #FF4500);
    border-radius: 12px;
    padding: 8px; /* Un pequeño margen interno */
    box-shadow: 0 0 30px rgba(255, 69, 0, 0.3), 0 20px 50px rgba(0, 0, 0, 0.9);
    transform: scale(0.9);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.video-modal-overlay.active .video-modal-content {
    transform: scale(1);
}

/* Botón cerrar "X" flotando encima del video */
.close-video-btn {
    position: absolute;
    top: -45px;
    right: 0;
    background: transparent;
    border: none;
    color: #ffffff;
    font-size: 2.5rem;
    cursor: pointer;
    transition: color 0.3s, transform 0.3s;
    line-height: 1;
}

.close-video-btn:hover {
    color: var(--primary-orange, #FF4500);
    transform: scale(1.1);
}

/* Contenedor Responsivo para 16:9 */
.video-iframe-container {
    position: relative;
    padding-bottom: 56.25%; /* Ratio matemático exacto para 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
    background: #000;
}

.video-iframe-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Ocultar botón en celulares muy pequeños y acercarlo */
@media (max-width: 600px) {
    .close-video-btn { top: -35px; right: 5px; }
}