/* Safari One Kenya - Animations */

/* Fade Animations */
.animate-fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-fade-up.animated {
    opacity: 1;
    transform: translateY(0);
}

.animate-fade-up.delay-1 {
    transition-delay: 0.2s;
}

.animate-fade-up.delay-2 {
    transition-delay: 0.4s;
}

.animate-fade-up.delay-3 {
    transition-delay: 0.6s;
}

/* Stagger Animation for Grids */
.destinations-grid .destination-card,
.packages-grid .package-card,
.blog-grid .blog-card,
.testimonials-grid .testimonial-card,
.features-grid .feature-card,
.values-grid .value-card,
.highlights-grid .highlight-card {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.6s ease forwards;
}

.destinations-grid .destination-card:nth-child(1),
.packages-grid .package-card:nth-child(1),
.blog-grid .blog-card:nth-child(1),
.testimonials-grid .testimonial-card:nth-child(1),
.features-grid .feature-card:nth-child(1),
.values-grid .value-card:nth-child(1),
.highlights-grid .highlight-card:nth-child(1) {
    animation-delay: 0.1s;
}

.destinations-grid .destination-card:nth-child(2),
.packages-grid .package-card:nth-child(2),
.blog-grid .blog-card:nth-child(2),
.testimonials-grid .testimonial-card:nth-child(2),
.features-grid .feature-card:nth-child(2),
.values-grid .value-card:nth-child(2),
.highlights-grid .highlight-card:nth-child(2) {
    animation-delay: 0.2s;
}

.destinations-grid .destination-card:nth-child(3),
.packages-grid .package-card:nth-child(3),
.blog-grid .blog-card:nth-child(3),
.testimonials-grid .testimonial-card:nth-child(3),
.features-grid .feature-card:nth-child(3),
.values-grid .value-card:nth-child(3),
.highlights-grid .highlight-card:nth-child(3) {
    animation-delay: 0.3s;
}

.destinations-grid .destination-card:nth-child(4),
.packages-grid .package-card:nth-child(4),
.testimonials-grid .testimonial-card:nth-child(4),
.features-grid .feature-card:nth-child(4),
.values-grid .value-card:nth-child(4),
.highlights-grid .highlight-card:nth-child(4) {
    animation-delay: 0.4s;
}

.destinations-grid .destination-card:nth-child(n+5),
.packages-grid .package-card:nth-child(n+5),
.blog-grid .blog-card:nth-child(n+4),
.features-grid .feature-card:nth-child(n+5),
.values-grid .value-card:nth-child(n+5) {
    animation-delay: 0.5s;
}

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

/* Hover Animations */
.package-card,
.destination-card,
.blog-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Button Hover Effect */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

/* Image Zoom Effect */
.card-image {
    overflow: hidden;
}

.card-image img {
    transition: transform 0.5s ease;
}

.destination-card:hover .card-image img,
.package-card:hover .card-image img,
.blog-card:hover .card-image img {
    transform: scale(1.05);
}

/* Newsletter Modal Animation */
.newsletter-modal {
    animation: fadeIn 0.3s ease;
}

.newsletter-modal-content {
    animation: slideUp 0.3s ease;
}

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

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

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

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