/* ============================================
   ADESA INTERNATIONAL — Custom Styles
   ============================================ */

/* Base */
html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
}

/* Selection color */
::selection {
  background-color: #7B2D3B;
  color: #FDF8F4;
}

/* Navigation */
.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #7B2D3B;
  transition: width 0.3s ease;
}

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

/* Header scroll state */
#site-header.scrolled {
  background-color: rgba(253, 248, 244, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

#site-header.scrolled .font-serif,
#site-header.scrolled p:first-of-type {
  color: #7B2D3B;
}

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

.mobile-nav-link {
  position: relative;
}

/* Scroll reveal animations */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

/* Staggered delays for grid items */
.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; }
.reveal-delay-5 { transition-delay: 0.5s; }
.reveal-delay-6 { transition-delay: 0.6s; }

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

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

  img, .group img {
    transition: none;
  }

  img:hover, .group:hover img {
    transform: none;
  }
}

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

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

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

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

::-webkit-scrollbar-thumb:hover {
  background: #a01624;
}

/* Image aspect ratio utilities */
.aspect-\[4\/5\] {
  aspect-ratio: 4 / 5;
}

.aspect-\[4\/3\] {
  aspect-ratio: 4 / 3;
}

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

/* Print styles */
@media print {
  #site-header,
  #mobile-menu,
  .reveal {
    display: none !important;
  }

  body {
    background: white !important;
    color: black !important;
  }

  a {
    color: black !important;
  }
}
