/* =========================================================
   SCROLL REVEAL ANIMATIONS (HOME)
   - Efecto de aparición fluida conforme el usuario hace scroll
   - Controlado por IntersectionObserver y acelerado por GPU
   ========================================================= */

.scroll-reveal {
    opacity: 0 !important;
    transform: translateY(38px) !important;
    animation: none !important;
    transition: opacity 0.75s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.75s cubic-bezier(0.22, 1, 0.36, 1) !important;
    will-change: opacity, transform;
}

.scroll-reveal.is-revealed {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* Aparición con ligera escala para tarjetas destacadas */
.scroll-reveal--scale {
    transform: translateY(30px) scale(0.97) !important;
}

.scroll-reveal--scale.is-revealed {
    transform: translateY(0) scale(1) !important;
}

/* Suavizado de elementos hijos */
.scroll-reveal-child {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.is-revealed .scroll-reveal-child,
.is-revealed.scroll-reveal-child {
    opacity: 1;
    transform: translateY(0);
}

/* Retrasos escalonados para tarjetas dentro de un contenedor */
.is-revealed .scroll-stagger-1 { transition-delay: 0.08s; }
.is-revealed .scroll-stagger-2 { transition-delay: 0.18s; }
.is-revealed .scroll-stagger-3 { transition-delay: 0.28s; }

/* Accesibilidad: desactivar si el usuario prefiere movimiento reducido */
@media (prefers-reduced-motion: reduce) {
    .scroll-reveal,
    .scroll-reveal--scale,
    .scroll-reveal-child {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
        animation: none !important;
    }
}
