/* ============================================
   California Lounge — Custom Styles
   ============================================ */

/* ---------- Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

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

::selection {
  background: rgba(212, 160, 74, 0.25);
  color: #f5f0f6;
}

/* ---------- Navbar ---------- */
#navbar {
  background: transparent;
}

#navbar.scrolled {
  background: rgba(26, 11, 20, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(212, 160, 74, 0.1);
}

.nav-link {
  position: relative;
}

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

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

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

#mobile-menu.open .mobile-nav-link {
  animation: fadeDown 0.4s ease forwards;
  opacity: 0;
}

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

@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Menu toggle animation */
.menu-toggle.active .menu-line:nth-child(1) {
  transform: translateY(4px) rotate(45deg);
}
.menu-toggle.active .menu-line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.menu-toggle.active .menu-line:nth-child(3) {
  transform: translateY(-4px) rotate(-45deg);
  width: 1.25rem;
}

/* ---------- Scroll Dot ---------- */
@keyframes scroll-dot {
  0%   { top: 0; opacity: 1; }
  100% { top: 1.5rem; opacity: 0; }
}

.scroll-dot {
  animation: scroll-dot 1.4s ease-in-out infinite;
}

/* ---------- Card Elevate ---------- */
.card-elevate {
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.5s ease, border-color 0.5s ease;
}

.card-elevate:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4), 0 8px 24px rgba(0, 0, 0, 0.3);
}

/* ---------- Reveal Animations (progressive enhancement) ---------- */
.reveal-up,
.reveal-left,
.reveal-right {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: no-preference) {
  .reveal-up {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1), transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1), transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1), transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .reveal-up.visible,
  .reveal-left.visible,
  .reveal-right.visible {
    opacity: 1;
    transform: none;
  }
}

/* ---------- Form ---------- */
select option {
  background: #3a1a2e;
  color: #e8dfe8;
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #1a0b14;
}
::-webkit-scrollbar-thumb {
  background: #4A233A;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #6b2f6b;
}

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