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

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

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

/* Scroll down indicator animation */
@keyframes scrollDown {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(200%); }
}

.animate-scroll-down {
  animation: scrollDown 1.5s ease-in-out infinite;
}

/* Navbar styles */
#navbar {
  background: transparent;
  transition: background 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
  background: rgba(253, 252, 248, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 20px rgba(45, 90, 61, 0.08);
}

.nav-logo-text {
  transition: color 0.4s ease;
}

#navbar.scrolled .nav-logo-text {
  color: #2D5A3D;
}

.nav-link {
  position: relative;
}

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

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

#navbar.scrolled .nav-link {
  color: #2D5A3D;
}

#navbar.scrolled .nav-link:hover {
  color: #3d7a3d;
}

/* Mobile menu */
.mobile-link {
  position: relative;
}

/* Form focus styles */
input:focus,
textarea:focus {
  box-shadow: 0 0 0 3px rgba(95, 160, 95, 0.15);
}

/* Smooth image loading */
img {
  opacity: 1;
  transition: opacity 0.3s ease;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #FAF8F2;
}

::-webkit-scrollbar-thumb {
  background: #bdd5be;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #8fbf8f;
}

/* Selection color */
::selection {
  background: #dce8de;
  color: #1c3926;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .scroll-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .animate-scroll-down { animation: none; }
}
