/* assets/css/video.css - Estilos para la sección de Video */

/* ==========================================================================
   Sección de Video - Estilos complementarios a Tailwind
   ========================================================================== */

/* Aspect ratio para mantener proporciones del video */
.aspect-video {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
}

.aspect-video > * {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Animaciones personalizadas */
@keyframes float-up {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-20px) scale(1.05);
    }
}

@keyframes glow-pulse {
    0%, 100% {
        box-shadow: 0 0 20px rgba(147, 51, 234, 0.5);
    }
    50% {
        box-shadow: 0 0 40px rgba(147, 51, 234, 0.8);
    }
}

/* Efectos hover mejorados */
.video-hover-effect {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.video-hover-effect:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px -12px rgba(147, 51, 234, 0.5);
}

/* Gradiente animado para el fondo */
.animated-gradient-bg {
    background: linear-gradient(-45deg, #667eea, #764ba2, #667eea, #764ba2);
    background-size: 400% 400%;
    animation: gradient-shift 15s ease infinite;
}

@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Efecto de brillo para el marco del video */
.video-frame-glow {
    position: relative;
    background: linear-gradient(45deg, #667eea, #764ba2);
    padding: 2px;
    border-radius: 1rem;
    overflow: hidden;
}

.video-frame-glow::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
    }
    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
    }
}

/* Botón de play personalizado */
.custom-play-button {
    position: relative;
    width: 80px;
    height: 80px;
    background: rgba(147, 51, 234, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    animation: pulse-play 2s infinite;
}

.custom-play-button:hover {
    transform: scale(1.1);
    background: rgba(147, 51, 234, 1);
}

.custom-play-button::before {
    content: '';
    position: absolute;
    inset: -20px;
    background: rgba(147, 51, 234, 0.3);
    border-radius: 50%;
    animation: ripple 2s infinite;
}

@keyframes pulse-play {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(147, 51, 234, 0.7);
    }
    50% {
        box-shadow: 0 0 0 20px rgba(147, 51, 234, 0);
    }
}

@keyframes ripple {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }
    100% {
        transform: scale(1.2);
        opacity: 0;
    }
}

/* Iconos flotantes de fondo */
.floating-icon {
    position: absolute;
    opacity: 0.1;
    animation: float-icon 20s infinite ease-in-out;
}

@keyframes float-icon {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    25% {
        transform: translateY(-30px) rotate(90deg);
    }
    50% {
        transform: translateY(0) rotate(180deg);
    }
    75% {
        transform: translateY(30px) rotate(270deg);
    }
}

/* Cards de información con efecto 3D */
.info-card-3d {
    transition: all 0.3s ease;
    transform-style: preserve-3d;
}

.info-card-3d:hover {
    transform: translateY(-10px) rotateX(-10deg);
    box-shadow: 0 20px 40px rgba(147, 51, 234, 0.3);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .custom-play-button {
        width: 60px;
        height: 60px;
    }
    
    .video-frame-glow {
        padding: 1px;
    }
}

/* Blur de fondo para modales de video */
.video-modal-backdrop {
    backdrop-filter: blur(10px);
    background: rgba(0, 0, 0, 0.8);
}

/* Animación de carga para videos */
.video-loading {
    position: relative;
    overflow: hidden;
}

.video-loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    animation: loading-sweep 1.5s infinite;
}

@keyframes loading-sweep {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* Efecto de partículas para el fondo */
.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(147, 51, 234, 0.5);
    border-radius: 50%;
    animation: particle-float 10s infinite;
}

@keyframes particle-float {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) scale(1);
        opacity: 0;
    }
}

/* Mejoras de accesibilidad */
.video-section:focus-within {
    outline: 2px solid #667eea;
    outline-offset: 4px;
}

button:focus-visible,
a:focus-visible {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Optimizaciones de rendimiento */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}