/* ── Base & Reset ── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; }
body { margin: 0; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

/* ── Scroll Reveal (progressive enhancement) ── */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  }
  .reveal[data-reveal] {
    opacity: 0;
    transform: translateY(24px);
  }
  .reveal-left[data-reveal] {
    opacity: 0;
    transform: translateX(-24px);
  }
  .reveal-right[data-reveal] {
    opacity: 0;
    transform: translateX(24px);
  }
}

/* ── Floating Card Animations ── */
@media (prefers-reduced-motion: no-preference) {
  .floating-card {
    animation: float-slow 6s ease-in-out infinite;
  }
  .floating-card-2 {
    animation: float-slow-2 7s ease-in-out infinite;
  }
  .floating-card-3 {
    animation: float-slow-3 5.5s ease-in-out infinite;
  }
  .floating-card-4 {
    animation: float-slow-4 6.5s ease-in-out infinite;
  }
}

@keyframes float-slow {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}
@keyframes float-slow-2 {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-8px); }
}
@keyframes float-slow-3 {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
}
@keyframes float-slow-4 {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-9px); }
}

/* ── Nav Link Underline ── */
.nav-link {
  position: relative;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition: all 0.25s ease;
  transform: translateX(-50%);
}
.nav-link:hover::after {
  width: 60%;
}

/* ── Amenity Card Hover ── */
.amenity-card {
  transition: transform 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}
.amenity-card:hover {
  transform: translateY(-4px);
}

/* ── Lodging Card Hover ── */
.lodging-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.lodging-card:hover {
  transform: translateY(-4px);
}

/* ── Gallery Item Hover ── */
.gallery-item {
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease;
}
.gallery-item:hover {
  transform: scale(1.02);
}

/* ── Mobile Menu Animation ── */
#mobile-menu {
  transition: max-height 0.35s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.25s ease;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
}
#mobile-menu.open {
  max-height: 500px;
  opacity: 1;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f3f0e4; }
::-webkit-scrollbar-thumb { background: #a5cca9; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #74b078; }

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

/* ── Header scroll state ── */
header.scrolled .bg-cream-50\/80 {
  background: rgba(253, 252, 248, 0.95);
  box-shadow: 0 1px 12px rgba(26, 77, 46, 0.08);
}

/* ── Form Input Focus ── */
input:focus, textarea:focus {
  box-shadow: 0 0 0 3px rgba(45, 122, 58, 0.15);
}

/* ── Selection ── */
::selection {
  background: #a5cca9;
  color: #0f2e1a;
}
