/* ── Base & Utilities ── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; -webkit-font-smoothing: antialiased; }

/* ── Navbar scroll state ── */
#navbar {
  background: transparent;
  transition: background 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
}
#navbar.scrolled {
  background: rgba(254, 254, 248, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 20px rgba(42, 74, 43, 0.08);
  padding: 0;
}
#navbar.scrolled .font-serif { color: #1e301d; }
#navbar.scrolled .menu-line { background: #2d4a2b; }

/* ── Mobile menu ── */
.menu-line { transition: transform 0.3s ease, opacity 0.3s ease; }
#menuBtn.active .menu-line:nth-child(1) { transform: translateY(6px) rotate(45deg); }
#menuBtn.active .menu-line:nth-child(2) { opacity: 0; }
#menuBtn.active .menu-line:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.mobile-link { display: block; padding: 8px 0; border-radius: 8px; }
.mobile-link:hover { background: rgba(58, 98, 53, 0.06); }

/* ── Scroll-reveal (progressive enhancement) ── */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
  }
  .reveal.visible {
    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; }
}

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

/* ── Subtle pattern for hero background ── */
.hero-pattern {
  background-image: radial-gradient(circle at 1px 1px, rgba(58, 98, 53, 0.05) 1px, transparent 0);
  background-size: 24px 24px;
}
