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

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

::selection {
    background-color: #b5cfb5;
    color: #1a301a;
}

/* ── Scroll Reveal ─────────────────────────────────────── */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* ── Nav ───────────────────────────────────────────────── */
#site-header {
    background: rgba(253, 252, 250, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(45, 82, 45, 0.08);
}

#site-header.scrolled {
    background: rgba(253, 252, 250, 0.95);
    box-shadow: 0 1px 20px rgba(45, 82, 45, 0.08);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #4a7e4a;
    border-radius: 1px;
    transition: width 0.25s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* ── Mobile Menu ───────────────────────────────────────── */
#mobile-menu {
    animation: slideDown 0.25s ease-out;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.mobile-link {
    position: relative;
    display: block;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background: #d9e6d9;
    transition: width 0.25s ease;
}

.mobile-link:hover::after {
    width: 100%;
}

/* ── Buttons ───────────────────────────────────────────── */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #4a7e4a;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ── Form ──────────────────────────────────────────────── */
input::placeholder,
textarea::placeholder {
    color: #a8b5a8;
}

/* ── Reduced Motion ────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ── Print ─────────────────────────────────────────────── */
@media print {
    #site-header, #mobile-menu { display: none; }
    body { background: white; color: black; }
    a { color: black; text-decoration: underline; }
}
