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

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
        animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
    }
    50% {
        transform: translateY(-5px);
        animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
    }
}

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

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

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

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

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

/* Animation Classes */
.animate-fade-in-up {
    animation: fadeInUp 1s ease-out;
    animation-fill-mode: both;
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.animate-bounce {
    animation: bounce 1s infinite;
}

.animate-slide-in-left {
    animation: slideInFromLeft 0.8s ease-out;
    animation-fill-mode: both;
}

.animate-slide-in-right {
    animation: slideInFromRight 0.8s ease-out;
    animation-fill-mode: both;
}

.animate-scale-in {
    animation: scaleIn 0.6s ease-out;
    animation-fill-mode: both;
}

.animate-rotate-in {
    animation: rotateIn 0.8s ease-out;
    animation-fill-mode: both;
}

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

/* Hover Animations */
.hover-scale {
    transition: transform 0.3s ease;
}

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

.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

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

.hover-glow:hover {
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.3);
}

/* Text Shadow Effects */
.text-shadow-sm {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.text-shadow {
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.text-shadow-lg {
    text-shadow: 0 10px 15px rgba(0, 0, 0, 0.1), 0 4px 6px rgba(0, 0, 0, 0.05);
}

/* Backdrop Blur Effects */
.backdrop-blur-sm {
    backdrop-filter: blur(4px);
}

.backdrop-blur {
    backdrop-filter: blur(8px);
}

.backdrop-blur-lg {
    backdrop-filter: blur(16px);
}

/* 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; }

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

.animate-spin {
    animation: spin 1s linear infinite;
}

/* Intersection Observer Animations */
.observe-fade {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.observe-fade.in-view {
    opacity: 1;
    transform: translateY(0);
}

.observe-slide-left {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.observe-slide-left.in-view {
    opacity: 1;
    transform: translateX(0);
}

.observe-slide-right {
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.observe-slide-right.in-view {
    opacity: 1;
    transform: translateX(0);
}

.observe-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.observe-scale.in-view {
    opacity: 1;
    transform: scale(1);
}

/* Mobile-specific Animations */
@media (max-width: 767px) {
    .animate-fade-in-up,
    .animate-slide-in-left,
    .animate-slide-in-right {
        animation-duration: 0.6s;
    }
    
    .animate-bounce {
        animation-duration: 1.5s;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .animate-pulse,
    .animate-bounce,
    .animate-float {
        animation: none !important;
    }
}

/* Performance Optimizations */
.animate-fade-in-up,
.animate-slide-in-left,
.animate-slide-in-right,
.animate-scale-in,
.animate-rotate-in {
    will-change: transform, opacity;
}

.card-hover,
.hover-scale,
.hover-lift {
    will-change: transform;
}

/* Custom Easing Functions */
.ease-bounce {
    transition-timing-function: cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.ease-smooth {
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.ease-sharp {
    transition-timing-function: cubic-bezier(0.4, 0, 0.6, 1);
}