/* Base & utilities */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f0f5ef;
}
::-webkit-scrollbar-thumb {
    background: #aed0a8;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #7fbf7f;
}

/* Selection */
::selection {
    background: #aed0a8;
    color: #1d4620;
}

/* Scroll reveal animations — progressive enhancement */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 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; }
.reveal-delay-4 { transition-delay: 0.4s; }

@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* Nav active state */
.nav-link.active {
    color: #2e7232;
    background: #f0f5ef;
}

/* Image loading placeholder */
img {
    background-color: #d5e3d1;
}

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