/* Custom styles for Alexander's Salon */

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

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

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

.menu-line {
  display: block;
}

#menu-btn.active .menu-line:nth-child(1) {
  transform: rotate(45deg) translate(4px, 4px);
}
#menu-btn.active .menu-line:nth-child(2) {
  opacity: 0;
}
#menu-btn.active .menu-line:nth-child(3) {
  transform: rotate(-45deg) translate(4px, -4px);
  width: 5px;
}

/* Mobile link transitions */
.mobile-link {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
}

#mobile-menu.open .mobile-link {
  opacity: 1;
  transform: translateY(0);
}

#mobile-menu.open .mobile-link:nth-child(1) { transition-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { transition-delay: 0.25s; }

/* Scroll reveal animations */
.reveal {
  opacity: 1;
  transform: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
}

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(30px);
  }

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

  .reveal.delay-100 { transition-delay: 0.1s; }
  .reveal.delay-200 { transition-delay: 0.2s; }
  .reveal.delay-300 { transition-delay: 0.3s; }
  .reveal.delay-400 { transition-delay: 0.4s; }
}

/* Back to top button */
#back-to-top.visible {
  opacity: 1;
  pointer-events: all;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #FAF6F0;
}
::-webkit-scrollbar-thumb {
  background: #DFC8B0;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #C4704B;
}

/* Input autofill styling */
input:-webkit-autofill,
textarea:-webkit-autofill,
select:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 30px #FAF6F0 inset !important;
}

/* Selection color */
::selection {
  background: #C4704B;
  color: #FDFCFA;
}

/* Focus visible for accessibility */
:focus-visible {
  outline: 2px solid #C4704B;
  outline-offset: 2px;
}

/* Gallery hover overlay fix */
.group:hover .group-hover\:scale-105 {
  transform: scale(1.05);
}

/* Ensure form select has arrow */
select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%239B7960' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.75rem center;
  background-repeat: no-repeat;
  background-size: 1.25em 1.25em;
  padding-right: 2.5rem;
}

/* Prevent content flash on load */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
