/* Custom styles beyond Tailwind */

html {
    scroll-behavior: smooth;
}

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

/* Navbar scroll effect */
nav.scrolled {
    box-shadow: 0 1px 20px rgba(31, 69, 32, 0.08);
}

/* Subtle entrance animations for below-fold sections */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    }

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

/* Ensure reduced motion is respected */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
    html {
        scroll-behavior: auto;
    }
    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f5f3ee;
}
::-webkit-scrollbar-thumb {
    background: #c5dbc5;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #97be97;
}

/* Form focus ring animation */
input:focus, textarea:focus {
    box-shadow: 0 0 0 3px rgba(61, 122, 61, 0.15);
}

/* Smooth image loading */
img {
    loading: lazy;
    will-change: transform;
}

/* Selection color */
::selection {
    background-color: #c5dbc5;
    color: #1f4520;
}
