/* ========================================
   ADVANCED ANIMATIONS & EFFECTS
   ======================================== */

/* Animated Background Gradient */
@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.animated-bg {
    background: linear-gradient(-45deg, #0b1220, #1a2332, #0b1220, #162030);
    background-size: 400% 400%;
    animation: gradient-shift 15s ease infinite;
}

/* Floating Animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

.float-animation {
    animation: float 6s ease-in-out infinite;
}

/* Pulse Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.pulse-animation {
    animation: pulse 2s ease-in-out infinite;
}

/* Glow Effect */
@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(0, 168, 232, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(0, 168, 232, 0.6);
    }
}

.glow-effect {
    animation: glow 3s ease-in-out infinite;
}

/* Slide In from Left */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide-in-left {
    animation: slideInLeft 0.8s ease-out;
}

/* Slide In from Right */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide-in-right {
    animation: slideInRight 0.8s ease-out;
}

/* Fade In Up */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Scale In */
@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.scale-in {
    animation: scaleIn 0.5s ease-out;
}

/* Rotate In */
@keyframes rotateIn {
    from {
        opacity: 0;
        transform: rotate(-10deg) scale(0.9);
    }
    to {
        opacity: 1;
        transform: rotate(0) scale(1);
    }
}

.rotate-in {
    animation: rotateIn 0.7s ease-out;
}

/* Particles Background */
.particles-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    background: rgba(0, 168, 232, 0.3);
    border-radius: 50%;
    animation: particle-float 20s infinite;
}

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

/* Data Flow Animation */
@keyframes dataFlow {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
        opacity: 0;
    }
}

.data-flow {
    animation: dataFlow 3s ease-in-out infinite;
}

/* Number Counter Animation */
@keyframes countUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.count-up {
    animation: countUp 1s ease-out;
}

/* Shimmer Effect */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.shimmer {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    background-size: 1000px 100%;
    animation: shimmer 3s infinite;
}

/* Hover Effects for Cards */
.card-hover-effect {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.card-hover-effect::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 122, 0, 0.1),
        transparent
    );
    transition: left 0.5s;
}

.card-hover-effect:hover::before {
    left: 100%;
}

.card-hover-effect:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

/* Image Hover Zoom */
.image-hover-zoom {
    overflow: hidden;
}

.image-hover-zoom img {
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.image-hover-zoom:hover img {
    transform: scale(1.1);
}

/* 3D Tilt Effect */
.tilt-effect {
    transform-style: preserve-3d;
    transition: transform 0.3s ease;
}

.tilt-effect:hover {
    transform: perspective(1000px) rotateX(5deg) rotateY(5deg);
}

/* Loading Skeleton */
@keyframes skeleton-loading {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

.skeleton {
    background: linear-gradient(
        90deg,
        #f0f0f0 0px,
        #e0e0e0 40px,
        #f0f0f0 80px
    );
    background-size: 200px 100%;
    animation: skeleton-loading 1.5s infinite;
}

/* Typing Effect */
@keyframes typing {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

@keyframes blink {
    50% {
        border-color: transparent;
    }
}

.typing-effect {
    overflow: hidden;
    border-right: 2px solid #ff7a00;
    white-space: nowrap;
    animation: typing 3.5s steps(40, end), blink 0.75s step-end infinite;
}

/* Progress Bar Animation */
@keyframes progress {
    from {
        width: 0%;
    }
}

.progress-bar {
    animation: progress 2s ease-out forwards;
}

/* Bounce In */
@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.bounce-in {
    animation: bounceIn 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Flip Animation */
@keyframes flip {
    from {
        transform: perspective(400px) rotateY(0);
    }
    to {
        transform: perspective(400px) rotateY(360deg);
    }
}

.flip-animation {
    animation: flip 2s ease-in-out infinite;
}

/* Wave Animation */
@keyframes wave {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.wave-animation {
    animation: wave 2s ease-in-out infinite;
}

/* Stagger Animation Delays */
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }
.stagger-6 { animation-delay: 0.6s; }

/* Parallax Effect */
.parallax {
    transition: transform 0.3s ease-out;
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #ff7a00, #00a8e8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Neon Glow Text */
.neon-text {
    text-shadow: 
        0 0 10px rgba(0, 168, 232, 0.8),
        0 0 20px rgba(0, 168, 232, 0.6),
        0 0 30px rgba(0, 168, 232, 0.4);
}

/* Underline Animation */
.animated-underline {
    position: relative;
    display: inline-block;
}

.animated-underline::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: #ff7a00;
    transition: width 0.3s ease;
}

.animated-underline:hover::after {
    width: 100%;
}

/* Button Ripple Effect */
.ripple-effect {
    position: relative;
    overflow: hidden;
}

.ripple-effect::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.ripple-effect:active::after {
    width: 300px;
    height: 300px;
}

/* Reveal on Scroll */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Smooth Transitions */
.smooth-transition {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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


/* Hero Zoom Animation */
@keyframes heroZoom {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.15);
    }
}

/* COMENTADO: Este pseudo-elemento tapaba el video del hero
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(10, 25, 47, 0.95), rgba(0, 188, 212, 0.1)),
                url('/industrial/assets/images/hero-main.jpg');
    background-size: cover;
    background-position: center;
    animation: heroZoom 20s ease-in-out infinite alternate;
    z-index: 0;
}

.hero > * {
    position: relative;
    z-index: 1;
}
*/

/* Hero Image Zoom Animation */
@keyframes hero-zoom {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.1);
    }
}

.hero-image-zoom {
    animation: hero-zoom 20s ease-in-out infinite alternate;
}
