/* Base & Typography */
html {
  scroll-behavior: smooth;
}

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

/* Reveal animations — progressive enhancement, hidden by default for reduced motion */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  }

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

  /* Stagger children */
  .reveal-delay-1 { transition-delay: 0.1s; }
  .reveal-delay-2 { transition-delay: 0.2s; }
  .reveal-delay-3 { transition-delay: 0.3s; }
  .reveal-delay-4 { transition-delay: 0.4s; }
}

/* Navbar scroll state */
.navbar-scrolled {
  background: rgba(254, 253, 248, 0.95) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(6, 78, 59, 0.08);
}

/* Mobile menu transitions */
.mobile-menu-open {
  opacity: 1 !important;
  pointer-events: all !important;
}

/* Custom selection color */
::selection {
  background: #064e3b;
  color: #fefdf8;
}

/* Smooth image loading */
img {
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

/* Subtle scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #fdf9ee;
}
::-webkit-scrollbar-thumb {
  background: #065f46;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #047857;
}

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