/* ===== 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(212, 160, 51, 0.3);
  color: #f0f4f8;
}

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

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

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #d4a033, #1fa87e);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #e4b542, #3abf96);
}

/* ===== Animations ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes floatDelayed {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(-25px, 25px) scale(1.08); }
  66% { transform: translate(15px, -15px) scale(0.92); }
}

@keyframes pulseSlow {
  0%, 100% { opacity: 0.1; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 0.18; transform: translate(-50%, -50%) scale(1.1); }
}

@keyframes scrollLine {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

.animate-fade-in-up {
  animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.animate-fade-in {
  animation: fadeIn 1s ease both;
}

.hero-orb {
  animation: float 8s ease-in-out infinite;
}

.hero-orb:nth-child(3) {
  animation: floatDelayed 10s ease-in-out infinite;
}

.hero-orb:nth-child(4) {
  animation: pulseSlow 6s ease-in-out infinite;
}

.scroll-line {
  animation: scrollLine 2s ease-in-out infinite;
}

/* ===== Reveal Animations (progressive enhancement) ===== */
@media (prefers-reduced-motion: no-preference) {
  .reveal-section {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  }

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

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

/* Reduced motion: show everything */
@media (prefers-reduced-motion: reduce) {
  .reveal-section {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ===== Service Cards ===== */
.service-card {
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(212, 160, 51, 0.03) 0%, transparent 50%, rgba(31, 168, 126, 0.03) 100%);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.service-card:hover::before {
  opacity: 1;
}

/* ===== CTA Buttons ===== */
.cta-primary {
  position: relative;
  overflow: hidden;
}

.cta-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}

.cta-primary:hover::before {
  transform: translateX(100%);
}

.cta-secondary {
  position: relative;
}

.cta-secondary::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #d4a033, #3abf96);
  transition: all 0.4s ease;
  transform: translateX(-50%);
}

.cta-secondary:hover::after {
  width: 80%;
}

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

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: linear-gradient(90deg, #d4a033, #3abf96);
  transition: width 0.3s ease;
}

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

/* Navbar scroll state */
.navbar-scrolled {
  background: rgba(10, 16, 32, 0.95) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px) !important;
  box-shadow: 0 1px 0 rgba(212, 160, 51, 0.1), 0 4px 30px rgba(0, 0, 0, 0.3);
}

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

#bar1.open {
  transform: rotate(45deg) translate(4px, 4px);
}

#bar2.open {
  opacity: 0;
}

#bar3.open {
  transform: rotate(-45deg) translate(4px, -4px);
  width: 1.5rem;
}

/* ===== Gold Shimmer on Headlines ===== */
.text-transparent.bg-clip-text {
  background-clip: text;
  -webkit-background-clip: text;
}

/* ===== Form Focus States ===== */
input:focus, select:focus, textarea:focus {
  outline: none;
}

input::placeholder, textarea::placeholder {
  color: #4a6090;
}

/* ===== Map Filter ===== */
iframe[title*="location"] {
  border-radius: 4px;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .font-serif {
    line-height: 1.2;
  }
}
