/* ============================================
   ANIMATIONS & TRANSITIONS
   ============================================ */

/* Scroll Animation Base Styles */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* Hero Section Animations */
.hero-badge,
.hero-text-modern h1,
.hero-text-modern p,
.hero-cta-group,
.trust-bar,
.hero-image-modern {
    opacity: 0;
    transform: translateY(20px);
}

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

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

/* Card Hover Animations */
.course-card-modern,
.why-card-modern,
.feature-card,
.success-card,
.faculty-card,
.gallery-item {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.course-card-modern:hover,
.why-card-modern:hover,
.feature-card:hover,
.success-card:hover,
.faculty-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(10, 36, 99, 0.15);
}

.gallery-item:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 35px rgba(10, 36, 99, 0.2);
}

/* Button Hover Animations */
.btn-primary-large,
.btn-secondary-large,
.btn-outline-large {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary-large::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-primary-large:hover::before {
    left: 100%;
}

.btn-primary-large:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(255, 107, 53, 0.4);
}

.btn-secondary-large:hover,
.btn-outline-large:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(10, 36, 99, 0.2);
}

/* Testimonial Carousel Smooth Transitions */
.testimonials-container {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Navigation Link Hover */
.nav-links a {
    position: relative;
    transition: color 0.3s ease;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

/* Floating Action Buttons Animation */
.fab-whatsapp,
.fab-call {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.fab-whatsapp:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.4);
}

.fab-call:hover {
    transform: scale(1.1) rotate(-5deg);
    box-shadow: 0 10px 25px rgba(255, 107, 53, 0.4);
}

/* Pulse Animation for Important Elements */
@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

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

/* Gradient Animation for Hero Text */
.gradient-text {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color), var(--primary-color));
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% center;
    }

    50% {
        background-position: 100% center;
    }
}

/* Loading State Animation */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }

    100% {
        background-position: 1000px 0;
    }
}

.loading-shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 1000px 100%;
    animation: shimmer 2s infinite;
}

/* Smooth Page Transitions */
html {
    scroll-behavior: smooth;
}

/* Form Input Focus Animations */
input:focus,
textarea:focus,
select:focus {
    transform: scale(1.01);
    transition: all 0.3s ease;
}

/* Number Counter Animation (for statistics) */
.trust-number,
.success-rank {
    display: inline-block;
    transition: transform 0.3s ease;
}

.trust-item:hover .trust-number {
    transform: scale(1.15);
    color: var(--primary-color);
}

/* Stagger Animation Delays */
.course-grid-modern>*:nth-child(1) {
    animation-delay: 0s;
}

.course-grid-modern>*:nth-child(2) {
    animation-delay: 0.1s;
}

.course-grid-modern>*:nth-child(3) {
    animation-delay: 0.2s;
}

.course-grid-modern>*:nth-child(4) {
    animation-delay: 0.3s;
}

.course-grid-modern>*:nth-child(5) {
    animation-delay: 0.4s;
}

.course-grid-modern>*:nth-child(6) {
    animation-delay: 0.5s;
}

/* Mobile Menu Slide Animation */
.nav-links.active {
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
    }

    to {
        transform: translateX(0);
    }
}

/* Section Header Animation */
.section-header {
    opacity: 0;
    transform: translateY(20px);
}

.section-header.animate-in {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.6s ease-out;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}