/* Custom styles and animations */

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

/* Hero reveal animations - only for above-the-fold, run immediately */
.reveal-hero {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-hero:nth-child(1) { transition-delay: 0.1s; }
.reveal-hero:nth-child(2) { transition-delay: 0.2s; }
.reveal-hero:nth-child(3) { transition-delay: 0.3s; }
.reveal-hero:nth-child(4) { transition-delay: 0.4s; }
.reveal-hero:nth-child(5) { transition-delay: 0.5s; }

.reveal-hero.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll reveal for below-fold sections */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Floating animation */
@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(2deg); }
}

@keyframes float-delay {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(-2deg); }
}

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

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

/* Navbar scroll state */
.navbar-scrolled {
    background: rgba(255, 255, 255, 0.92) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(197, 235, 211, 0.4);
    box-shadow: 0 1px 20px rgba(30, 58, 95, 0.06);
}

/* Mobile link hover */
.mobile-link:active {
    background: #e1f5e9 !important;
}

/* Subtle hover lift for cards */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(24px);
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .reveal-hero {
        opacity: 1;
        transform: none;
    }
    
    .scroll-reveal {
        opacity: 1;
        transform: none;
    }
    
    .animate-float, .animate-float-delay {
        animation: none;
    }
}
