/* ===== RESET & BASE ===== */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
}

img, svg {
  display: block;
  max-width: 100%;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

a {
  text-decoration: none;
  color: inherit;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #FDF8F0;
}
::-webkit-scrollbar-thumb {
  background: #1B5E20;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #154a1a;
}

/* ===== SELECTION ===== */
::selection {
  background: #1B5E20;
  color: #FDF8F0;
}

/* ===== DECORATIVE BLOBS ===== */
.blob {
  z-index: 0;
  pointer-events: none;
}

.blob--green {
  background: #1B5E20;
}

.blob--cream {
  background: #F3E5C8;
}

/* ===== NAVIGATION ===== */
#site-header {
  background: transparent;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

#site-header.scrolled {
  background: rgba(253, 248, 240, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(27, 94, 32, 0.1);
}

.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: #1B5E20;
  transition: all 0.2s ease;
  transform: translateX(-50%);
}

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

.nav-link:hover {
  color: #1B5E20;
}

/* ===== MOBILE MENU ===== */
#mobile-menu {
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

#mobile-menu.open {
  opacity: 1;
  visibility: visible;
}

.mobile-nav-link {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

#mobile-menu.open .mobile-nav-link {
  opacity: 1;
  transform: translateY(0);
}

#mobile-menu.open .mobile-nav-link:nth-child(1) { transition-delay: 0.05s; }
#mobile-menu.open .mobile-nav-link:nth-child(2) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-nav-link:nth-child(3) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-nav-link:nth-child(4) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-nav-link:nth-child(5) { transition-delay: 0.25s; }

/* ===== SCROLL ANIMATIONS ===== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  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; }

/* ===== ACTIVE NAV HIGHLIGHT ===== */
.nav-link.active {
  color: #1B5E20;
}

.nav-link.active::after {
  width: 60%;
}

/* ===== FORM FOCUS STATES ===== */
input:focus, textarea:focus {
  box-shadow: 0 0 0 3px rgba(27, 94, 32, 0.1);
}

/* ===== RESPONSIVE TWEAKS ===== */
@media (max-width: 640px) {
  h1, .font-display {
    word-break: keep-all;
  }
}

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