/* Base styles and custom properties */
:root {
  --color-charcoal-950: #11110d;
  --color-charcoal-900: #1e1e18;
  --color-charcoal-800: #2a2a23;
  --color-charcoal-700: #33332b;
  --color-charcoal-600: #404036;
  --color-charcoal-500: #525246;
  --color-charcoal-400: #737366;
  --color-charcoal-300: #a8a89e;
  --color-charcoal-200: #d1d1ca;
  --color-charcoal-100: #e8e8e4;
  --color-charcoal-50: #f6f6f4;
  --color-coral-600: #c85a3c;
  --color-coral-400: #ee754e;
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-sans: 'Inter', system-ui, sans-serif;
}

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

body {
  overflow-x: hidden;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--color-charcoal-950);
}
::-webkit-scrollbar-thumb {
  background: var(--color-charcoal-700);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-charcoal-600);
}

/* Selection color */
::selection {
  background: var(--color-coral-600);
  color: var(--color-charcoal-50);
}

/* Reveal animations — progressive enhancement via .js-active */
.reveal {
  opacity: 1;
  transform: none;
  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);
}

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(32px);
    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);
  }

  .reveal:nth-child(2) { transition-delay: 0.1s; }
  .reveal:nth-child(3) { transition-delay: 0.2s; }
  .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Stat cards hover */
.stat-card {
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.4s ease;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* Room cards */
.room-card {
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.room-card:hover {
  transform: translateY(-6px);
}

/* Navbar scroll state */
#navbar.scrolled {
  background: rgba(17, 17, 13, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

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

#mobile-menu.open .mobile-link {
  animation: fadeUp 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
  opacity: 0;
}

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

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hamburger animation */
.menu-line {
  transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), opacity 0.3s ease;
}

#menu-toggle.active .menu-line:nth-child(1) {
  transform: translateY(4px) rotate(45deg);
}
#menu-toggle.active .menu-line:nth-child(2) {
  opacity: 0;
}
#menu-toggle.active .menu-line:nth-child(3) {
  transform: translateY(-4px) rotate(-45deg);
  width: 1.5rem;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--color-coral-400);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Print styles */
@media print {
  #navbar, #mobile-menu, .stat-card { display: none; }
  body { background: white; color: black; }
}
