/**
 * === SPRINT 2.2: MEJORAS UI/UX - JERARQUÍA VISUAL ===
 * Archivo: sprint22_visual.css
 * Tareas: 2.2.1 (poster), 2.2.2 (scroll indicator), 
 *         2.2.4 (project cards), 2.2.5 (pause button)
 */

/* --- 2.2.2: Indicador de scroll en hero --- */
.hero-scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.hero-scroll-indicator:hover {
    opacity: 1;
    text-decoration: none;
}

.scroll-mouse {
    width: 26px;
    height: 42px;
    border: 2px solid rgba(255, 255, 255, 0.7);
    border-radius: 13px;
    display: flex;
    justify-content: center;
    padding-top: 8px;
}

.scroll-wheel {
    width: 4px;
    height: 10px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 2px;
    animation: scrollWheelAnim 1.8s ease-in-out infinite;
}

@keyframes scrollWheelAnim {
    0% {
        transform: translateY(0);
        opacity: 1;
    }

    50% {
        transform: translateY(8px);
        opacity: 0.3;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.scroll-arrow {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    animation: scrollArrowAnim 1.8s ease-in-out infinite;
}

@keyframes scrollArrowAnim {
    0% {
        transform: translateY(0);
        opacity: 0.5;
    }

    50% {
        transform: translateY(6px);
        opacity: 1;
    }

    100% {
        transform: translateY(0);
        opacity: 0.5;
    }
}

@media (max-width: 767.98px) {
    .hero-scroll-indicator {
        bottom: 25px;
    }

    .scroll-mouse {
        width: 22px;
        height: 36px;
    }
}

/* --- 2.2.5: Botón de pausa global videos (WCAG 2.2.2) --- */
.video-pause-toggle {
    position: absolute;
    bottom: 40px;
    right: 20px;
    z-index: 10;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.5);
    background: rgba(0, 0, 0, 0.4);
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.video-pause-toggle:hover {
    background: rgba(0, 0, 0, 0.7);
    border-color: rgba(255, 255, 255, 0.8);
    transform: scale(1.1);
}

.video-pause-toggle.paused {
    border-color: rgba(255, 200, 0, 0.8);
    background: rgba(0, 0, 0, 0.6);
}

.video-pause-toggle.paused i::before {
    content: "\f04b";
}

@media (max-width: 767.98px) {
    .video-pause-toggle {
        bottom: 60px;
        right: 12px;
        width: 36px;
        height: 36px;
        font-size: 12px;
    }
}

/* --- 2.2.4: Normalizar alturas de cards de proyectos --- */
.project-grid {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
}

.project-grid .col-12.col-md-6 {
    display: flex;
}

.project-grid .project-card {
    height: 100%;
    min-height: 0;
}

.projects-section .project-card {
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: flex;
    flex-direction: column;
}

.projects-section .project-card .card-body,
.projects-section .project-card>.d-flex {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.projects-section .project-card .project-points {
    flex-grow: 1;
}

.projects-section .project-card .actions-project-container {
    margin-top: auto;
}

/* Truncar bullets a 2 líneas para uniformidad */
.projects-section .project-points li {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
    margin-bottom: 0.35rem;
}

/* Reduced motion: desactivar animaciones scroll indicator */
@media (prefers-reduced-motion: reduce) {

    .scroll-wheel,
    .scroll-arrow {
        animation: none;
    }

    .hero-scroll-indicator {
        opacity: 1;
    }
}