/**
 * Custom animations for WISDOM FOUNDATION Website
 */

/* Animation Classes */
.animate-on-scroll {
    opacity: 0;
    transition: all 0.8s ease;
}

.animated {
    opacity: 1;
}

/* Fade In Animation */
.fade-in {
    opacity: 0;
    animation: fadeIn 1s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Fade In Up Animation */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s ease forwards;
}

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

/* Fade In Down Animation */
.fade-in-down {
    opacity: 0;
    transform: translateY(-30px);
    animation: fadeInDown 1s ease forwards;
}

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

/* Fade In Left Animation */
.fade-in-left {
    opacity: 0;
    transform: translateX(-30px);
    animation: fadeInLeft 1s ease forwards;
}

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

/* Fade In Right Animation */
.fade-in-right {
    opacity: 0;
    transform: translateX(30px);
    animation: fadeInRight 1s ease forwards;
}

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

/* Zoom In Animation */
.zoom-in {
    opacity: 0;
    transform: scale(0.9);
    animation: zoomIn 1s ease forwards;
}

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

/* Zoom Out Animation */
.zoom-out {
    opacity: 0;
    transform: scale(1.1);
    animation: zoomOut 1s ease forwards;
}

@keyframes zoomOut {
    from {
        opacity: 0;
        transform: scale(1.1);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Slide Up Animation */
.slide-up {
    opacity: 0;
    transform: translateY(50px);
    animation: slideUp 1s ease forwards;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Slide Down Animation */
.slide-down {
    opacity: 0;
    transform: translateY(-50px);
    animation: slideDown 1s ease forwards;
}

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

/* Flip Animation */
.flip {
    opacity: 0;
    transform: perspective(400px) rotateY(90deg);
    animation: flip 1s ease forwards;
}

@keyframes flip {
    from {
        opacity: 0;
        transform: perspective(400px) rotateY(90deg);
    }
    to {
        opacity: 1;
        transform: perspective(400px) rotateY(0deg);
    }
}

/* Bounce Animation */
.bounce {
    animation: bounce 1s ease;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-30px);
    }
    60% {
        transform: translateY(-15px);
    }
}

/* Pulse Animation */
.pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Shake Animation */
.shake {
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-10px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(10px);
    }
}

/* Rotate Animation */
.rotate {
    animation: rotate 1s ease;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Delay Classes */
.delay-100 {
    animation-delay: 0.1s;
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-300 {
    animation-delay: 0.3s;
}

.delay-400 {
    animation-delay: 0.4s;
}

.delay-500 {
    animation-delay: 0.5s;
}

.delay-600 {
    animation-delay: 0.6s;
}

.delay-700 {
    animation-delay: 0.7s;
}

.delay-800 {
    animation-delay: 0.8s;
}

.delay-900 {
    animation-delay: 0.9s;
}

.delay-1000 {
    animation-delay: 1s;
}

/* Duration Classes */
.duration-300 {
    animation-duration: 0.3s;
}

.duration-500 {
    animation-duration: 0.5s;
}

.duration-700 {
    animation-duration: 0.7s;
}

.duration-1000 {
    animation-duration: 1s;
}

.duration-1500 {
    animation-duration: 1.5s;
}

.duration-2000 {
    animation-duration: 2s;
}

/* Infinite Animation */
.infinite {
    animation-iteration-count: infinite;
}

/* Apply animations to specific elements */
.section-title {
    animation-delay: 0.2s;
}

.hero-slider h2 {
    animation-delay: 0.3s;
}

.hero-slider p {
    animation-delay: 0.5s;
}

.hero-slider .btn {
    animation-delay: 0.7s;
}

.quick-link-box {
    transition-delay: calc(var(--index) * 0.1s);
}

.team-card {
    transition-delay: calc(var(--index) * 0.1s);
}

.gallery-item {
    transition-delay: calc(var(--index) * 0.1s);
}
