/* ========================================
   CHUUHOU TECHNOLOGY - Animations
   Rich Animation Effects
   ======================================== */

/* ========================================
   Scroll Animations
   ======================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(60px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-60px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

@keyframes slideInUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* ========================================
   Interactive Animations
   ======================================== */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(0, 212, 255, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 30px 10px rgba(0, 212, 255, 0.2);
    }
}

@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(0, 212, 255, 0.6),
                    0 0 60px rgba(124, 77, 255, 0.3);
    }
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

@keyframes borderGlow {
    0%, 100% {
        border-color: rgba(0, 212, 255, 0.3);
    }
    50% {
        border-color: rgba(0, 212, 255, 0.8);
    }
}

/* ========================================
   Particle Animations
   ======================================== */
@keyframes particleFloat {
    0%, 100% {
        transform: translateY(0) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) translateX(20px);
        opacity: 0;
    }
}

@keyframes particleDrift {
    0%, 100% {
        transform: translate(0, 0);
    }
    25% {
        transform: translate(10px, -10px);
    }
    50% {
        transform: translate(20px, 0);
    }
    75% {
        transform: translate(10px, 10px);
    }
}

/* ========================================
   Text Animations
   ======================================== */
@keyframes textReveal {
    0% {
        clip-path: inset(0 100% 0 0);
    }
    100% {
        clip-path: inset(0 0 0 0);
    }
}

@keyframes typewriter {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}

/* ========================================
   Background Animations
   ======================================== */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes meshGradient {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(30px, -30px) scale(1.1);
    }
    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }
}

@keyframes orbFloat {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    25% {
        transform: translate(50px, -50px) scale(1.1);
    }
    50% {
        transform: translate(100px, 0) scale(1);
    }
    75% {
        transform: translate(50px, 50px) scale(0.9);
    }
}

/* ========================================
   Loading Animations
   ======================================== */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

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

/* ========================================
   Card Animations
   ======================================== */
@keyframes cardHover {
    0% {
        transform: translateY(0) rotateX(0);
    }
    100% {
        transform: translateY(-10px) rotateX(5deg);
    }
}

@keyframes cardFlip {
    0% {
        transform: perspective(1000px) rotateY(0);
    }
    100% {
        transform: perspective(1000px) rotateY(180deg);
    }
}

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

/* ========================================
   Reveal Classes
   ======================================== */
.reveal {
    opacity: 0;
    transform: translateY(60px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.reveal-left {
    opacity: 0;
    transform: translateX(-60px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(60px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-right.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-scale.active {
    opacity: 1;
    transform: scale(1);
}

/* ========================================
   Staggered Animations
   ======================================== */
.stagger-1 { transition-delay: 0.1s !important; }
.stagger-2 { transition-delay: 0.2s !important; }
.stagger-3 { transition-delay: 0.3s !important; }
.stagger-4 { transition-delay: 0.4s !important; }
.stagger-5 { transition-delay: 0.5s !important; }
.stagger-6 { transition-delay: 0.6s !important; }

/* ========================================
   Hover Effects
   ======================================== */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.hover-glow {
    transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.4);
}

.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

.hover-brightness {
    transition: filter 0.3s ease;
}

.hover-brightness:hover {
    filter: brightness(1.1);
}

/* ========================================
   Particle Background
   ======================================== */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 10px;
    height: 10px;
    background: rgba(0, 212, 255, 0.3);
    border-radius: 50%;
    animation: particleFloat linear infinite;
}

.particle:nth-child(1) { left: 10%; animation-duration: 20s; animation-delay: 0s; }
.particle:nth-child(2) { left: 20%; animation-duration: 25s; animation-delay: 2s; }
.particle:nth-child(3) { left: 30%; animation-duration: 30s; animation-delay: 4s; }
.particle:nth-child(4) { left: 40%; animation-duration: 22s; animation-delay: 1s; }
.particle:nth-child(5) { left: 50%; animation-duration: 28s; animation-delay: 3s; }
.particle:nth-child(6) { left: 60%; animation-duration: 24s; animation-delay: 5s; }
.particle:nth-child(7) { left: 70%; animation-duration: 26s; animation-delay: 2s; }
.particle:nth-child(8) { left: 80%; animation-duration: 32s; animation-delay: 0s; }
.particle:nth-child(9) { left: 90%; animation-duration: 20s; animation-delay: 4s; }
.particle:nth-child(10) { left: 5%; animation-duration: 27s; animation-delay: 1s; }

/* ========================================
   Line Animation
   ======================================== */
.line-animate {
    position: relative;
    overflow: hidden;
}

.line-animate::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #00d4ff, #7c4dff);
    transition: width 0.5s ease;
}

.line-animate:hover::after {
    width: 100%;
}

/* ========================================
   Morphing Animation
   ======================================== */
@keyframes morph {
    0%, 100% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }
    50% {
        border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
    }
}

.morph {
    animation: morph 8s ease-in-out infinite;
}

/* ========================================
   Cursor Animation
   ======================================== */
.cursor-follower {
    position: fixed;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(0, 212, 255, 0.5);
    border-radius: 50%;
    pointer-events: none;
    transition: transform 0.1s ease;
    z-index: 9999;
}

.cursor-dot {
    position: fixed;
    width: 8px;
    height: 8px;
    background: #00d4ff;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
}

/* ========================================
   Loading Screen
   ======================================== */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0a0e17;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-content {
    text-align: center;
}

.loader-spinner {
    width: 60px;
    height: 60px;
    border: 3px solid rgba(0, 212, 255, 0.1);
    border-top-color: #00d4ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

.loader-text {
    font-size: 1.2rem;
    color: #00d4ff;
    font-weight: 600;
}

/* ========================================
   Parallax Classes
   ======================================== */
.parallax-slow {
    transform: translateY(calc(var(--scroll) * 0.3));
}

.parallax-medium {
    transform: translateY(calc(var(--scroll) * 0.5));
}

.parallax-fast {
    transform: translateY(calc(var(--scroll) * 0.8));
}

/* ========================================
   Glitch Effect
   ======================================== */
@keyframes glitch {
    0% {
        transform: translate(0);
    }
    20% {
        transform: translate(-3px, 3px);
    }
    40% {
        transform: translate(-3px, -3px);
    }
    60% {
        transform: translate(3px, 3px);
    }
    80% {
        transform: translate(3px, -3px);
    }
    100% {
        transform: translate(0);
    }
}

.glitch:hover {
    animation: glitch 0.3s ease infinite;
}

/* ========================================
   Water Effect
   ======================================== */
@keyframes wave {
    0%, 100% {
        transform: translateX(0) translateY(0);
    }
    25% {
        transform: translateX(5px) translateY(-5px);
    }
    50% {
        transform: translateX(0) translateY(0);
    }
    75% {
        transform: translateX(-5px) translateY(5px);
    }
}

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

/* ========================================
   Video Background Overlay
   ======================================== */
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, 
        rgba(10, 14, 23, 0.8) 0%, 
        rgba(10, 14, 23, 0.4) 50%, 
        rgba(10, 14, 23, 0.9) 100%);
}

/* ========================================
   Animated Border
   ======================================== */
@keyframes animatedBorder {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.animated-border {
    position: relative;
    background: linear-gradient(90deg, #00d4ff, #7c4dff, #00d4ff);
    background-size: 200% 100%;
    animation: animatedBorder 3s linear infinite;
    padding: 2px;
}

.animated-border-inner {
    background: #0a0e17;
    border-radius: inherit;
}

/* ========================================
   Marquee Animation
   ======================================== */
@keyframes marquee {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.marquee {
    animation: marquee 30s linear infinite;
}

.marquee-content {
    display: flex;
    animation: marquee 30s linear infinite;
}

/* ========================================
   3D Transform Effects
   ======================================== */
.perspective-1000 {
    perspective: 1000px;
}

.preserve-3d {
    transform-style: preserve-3d;
}

.backface-hidden {
    backface-visibility: hidden;
}

/* ========================================
   Text Gradient Animation
   ======================================== */
@keyframes gradientText {
    0%, 100% {
        background-position: 0% center;
    }
    50% {
        background-position: 100% center;
    }
}

.gradient-text-animated {
    background: linear-gradient(90deg, #00d4ff, #7c4dff, #00d4ff);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientText 3s linear infinite;
}

/* ========================================
   Number Counter Animation
   ======================================== */
.counter {
    display: inline-block;
}

.counter-value {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, #00d4ff 0%, #7c4dff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.counter-value::before {
    content: attr(data-count);
    position: absolute;
}

/* ========================================
   Split Text Animation
   ======================================== */
.split-text .char {
    display: inline-block;
    opacity: 0;
    transform: translateY(50px);
    animation: charReveal 0.5s ease forwards;
}

@keyframes charReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   Page Transitions
   ======================================== */
.page-transition {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0a0e17;
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 0.5s ease;
}

.page-transition.active {
    transform: translateY(0);
}

/* ========================================
   Scroll Progress Bar
   ======================================== */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, #00d4ff, #7c4dff);
    z-index: 10001;
    transition: width 0.1s ease;
}

/* ========================================
   Magnetic Button Effect
   ======================================== */
.magnetic {
    transition: transform 0.3s ease;
}

.magnetic:hover {
    transform: scale(1.1);
}

/* ========================================
   Smooth Scroll Indicator
   ======================================== */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

.scroll-indicator svg {
    width: 30px;
    height: 30px;
    color: #00d4ff;
}

/* ========================================
   Image Reveal Effect
   ======================================== */
.image-reveal {
    position: relative;
    overflow: hidden;
}

.image-reveal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0a0e17;
    z-index: 1;
    transform: translateX(0);
    transition: transform 1s ease;
}

.image-reveal.revealed::before {
    transform: translateX(100%);
}

/* ========================================
   Notification Badge
   ======================================== */
@keyframes badgePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.badge {
    position: relative;
}

.badge::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    width: 10px;
    height: 10px;
    background: #00d4ff;
    border-radius: 50%;
    animation: badgePulse 2s infinite;
}
