/* ========== BASE & RESET ========== */
*, *::before, *::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  overflow-x: hidden;
}

::selection {
  background: rgba(201, 168, 76, 0.3);
  color: #FDF8E3;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #0A1628;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(to bottom, #C9A84C, #9A7A32);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to bottom, #EDC84A, #B8943F);
}

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

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 50%;
  width: 0;
  height: 1px;
  background: #C9A84C;
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

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

.nav-link:hover {
  color: #F6DF88 !important;
}

/* Navbar scrolled state */
nav.scrolled {
  background: rgba(4, 11, 24, 0.95) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

nav.scrolled .nav-link {
  color: rgba(255, 255, 255, 0.8) !important;
}

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

#mobile-menu.open .mobile-link {
  animation: fadeSlideIn 0.4s ease forwards;
}

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

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

/* Hamburger animation */
.menu-btn.active .menu-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.menu-btn.active .menu-line:nth-child(2) {
  opacity: 0;
}

.menu-btn.active .menu-line:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
  width: 1.25rem;
  margin-right: 0;
}

/* ========== HERO ========== */
.hero-orb {
  animation: orbFloat 8s ease-in-out infinite;
}

.orb-1 {
  animation-delay: 0s;
}

.orb-2 {
  animation-delay: -3s;
}

.orb-3 {
  animation-delay: -5s;
}

@keyframes orbFloat {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(20px, -20px) scale(1.05);
  }
  66% {
    transform: translate(-15px, 15px) scale(0.95);
  }
}

.cta-orb {
  animation: orbFloat 10s ease-in-out infinite;
}

.cta-orb.orb-1 {
  animation-delay: -2s;
}

.cta-orb.orb-2 {
  animation-delay: -6s;
}

/* ========== SERVICE CARDS ========== */
.service-card {
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, rgba(201, 168, 76, 0), transparent);
  transition: all 0.5s ease;
}

.service-card:hover::before {
  background: linear-gradient(to right, transparent, rgba(201, 168, 76, 0.6), transparent);
}

/* ========== GALLERY ========== */
.gallery-item {
  cursor: pointer;
}

/* ========== TESTIMONIAL CARDS ========== */
.testimonial-card {
  position: relative;
  overflow: hidden;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(201, 168, 76, 0.1);
}

/* ========== SCROLL REVEAL ========== */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.reveal[data-delay="0"] { transition-delay: 0s; }
.reveal[data-delay="100"] { transition-delay: 0.1s; }
.reveal[data-delay="200"] { transition-delay: 0.2s; }
.reveal[data-delay="300"] { transition-delay: 0.3s; }
.reveal[data-delay="400"] { transition-delay: 0.4s; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html {
    scroll-behavior: auto;
  }
  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ========== RESPONSIVE ========== */
@media (max-width: 640px) {
  .font-display {
    word-break: keep-all;
  }
}
