/* Base & Utilities */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #F5F0E8;
}
::-webkit-scrollbar-thumb {
    background: #8fb88f;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #4a7a4a;
}

/* Reveal Animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* Hero Animations */
@keyframes slide-up {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-slide-up {
    animation: slide-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0;
}

.animate-slide-up-delay {
    animation: slide-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.15s forwards;
    opacity: 0;
}

.animate-slide-up-delayed {
    animation: slide-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
    opacity: 0;
}

.animate-slide-up-delayed-alt {
    animation: slide-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.45s forwards;
    opacity: 0;
}

/* Float Animations */
@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(3deg); }
}

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

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

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

/* Navbar Scroll State */
.nav-scrolled {
    background: rgba(253, 252, 250, 0.92) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    box-shadow: 0 1px 0 rgba(45, 90, 61, 0.08), 0 4px 24px rgba(45, 90, 61, 0.06) !important;
}

.nav-scrolled .nav-link {
    color: #2D5A3D !important;
}

.nav-scrolled .nav-link:hover {
    background: rgba(45, 90, 61, 0.08) !important;
}

/* Mobile Menu */
.mobile-menu-open {
    opacity: 1 !important;
    pointer-events: all !important;
}

/* Smooth image loading */
img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Selection color */
::selection {
    background: #dce8df;
    color: #1c3a27;
}

/* Focus styles */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #4a7a4a;
    outline-offset: 2px;
    border-radius: 4px;
}

/* 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 {
        opacity: 1;
        transform: none;
    }
}
