/* ── Custom overrides & enhancements ── */

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

/* Focus visible for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid #0f502b;
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── Scroll reveal (progressive enhancement) ── */
@media (prefers-reduced-motion: no-preference) {
  .scroll-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);
  }
  .scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Default visible state (no-JS fallback) */
.scroll-reveal {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: no-preference) {
  .scroll-reveal {
    opacity: 0;
    transform: translateY(24px);
  }
}

/* ── Navbar scroll state ── */
#site-nav.scrolled {
  box-shadow: 0 1px 12px rgba(9, 49, 28, 0.08);
}

/* ── Selection color ── */
::selection {
  background-color: #0f502b;
  color: #fafaf6;
}
