/* ===== Custom Styles for Rural Roots Farmers Market ===== */

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

/* Nav scroll state */
#nav.scrolled {
  background: rgba(253, 252, 250, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(6, 95, 70, 0.1);
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.06);
}

#nav.scrolled .logo-text {
  color: rgb(2, 44, 34);
}

/* Scroll reveal animations */
.scroll-reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Mobile menu transition */
#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 0;
}

#mobile-menu.open {
  max-height: 400px;
  opacity: 1;
}

/* Button hover effects */
a, button {
  -webkit-tap-highlight-color: transparent;
}

/* Focus styles */
:focus-visible {
  outline: 2px solid rgb(5, 150, 105);
  outline-offset: 2px;
}

/* Image loading placeholder */
img {
  background-color: rgb(209, 250, 229);
}

/* Selection color */
::selection {
  background-color: rgb(110, 231, 183);
  color: rgb(2, 44, 34);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .scroll-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* High contrast mode */
@media (prefers-contrast: high) {
  .scroll-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Large screen adjustments */
@media (min-width: 1024px) {
  .hero-headline {
    font-size: 3.75rem;
    line-height: 1.05;
  }
}

/* Print styles */
@media print {
  #nav,
  #mobile-menu,
  .scroll-indicator {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
  }

  a {
    color: #000;
  }
}
