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

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

body {
  overflow-x: hidden;
}

::selection {
  background: rgba(212, 160, 52, 0.3);
  color: #fff;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #0c0c12;
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(to bottom, #741c1c, #d4a034);
  border-radius: 4px;
}

/* ===== Navbar ===== */
.nav-scrolled {
  background: rgba(6, 6, 10, 0.92) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}

.nav-scrolled .menu-line {
  background: rgba(255, 255, 255, 0.9) !important;
}

/* ===== Mobile menu ===== */
.mobile-menu-open {
  max-height: 420px !important;
}

.menu-toggle-active .menu-line:nth-child(1) {
  transform: translateY(5px) 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(-5px) rotate(-45deg);
  width: 1.25rem !important;
}

/* ===== Hero floating cards ===== */
@keyframes float-slow {
  0%, 100% { transform: translateY(0px) rotate(3deg); }
  50% { transform: translateY(-12px) rotate(3deg); }
}

@keyframes float-medium {
  0%, 100% { transform: translateY(0px) rotate(-2deg); }
  50% { transform: translateY(-8px) rotate(-2deg); }
}

.floating-card {
  animation: float-slow 5s ease-in-out infinite;
}

.floating-card-2 {
  animation: float-medium 4s ease-in-out infinite;
  animation-delay: 1s;
}

/* ===== Program cards ===== */
.program-card {
  position: relative;
  z-index: 1;
}

.program-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, transparent 40%, rgba(212, 160, 52, 0.15) 100%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

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

/* ===== Feature cards ===== */
.feature-card {
  position: relative;
  z-index: 1;
}

.feature-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(ellipse at top left, rgba(212, 160, 52, 0.04), transparent 60%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.feature-card:hover::after {
  opacity: 1;
}

/* ===== Testimonial cards ===== */
.testimonial-card {
  position: relative;
  z-index: 1;
}

.testimonial-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 2rem;
  right: 2rem;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(212, 160, 52, 0.4), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

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

/* ===== Scroll reveal (below fold only, progressive enhancement) ===== */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  }

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

  .reveal-delay-1 { transition-delay: 0.1s; }
  .reveal-delay-2 { transition-delay: 0.2s; }
  .reveal-delay-3 { transition-delay: 0.3s; }
  .reveal-delay-4 { transition-delay: 0.4s; }
}

/* ===== Gold shimmer on CTA ===== */
@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

.cta-shimmer {
  background-size: 200% auto;
  background-image: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.08) 50%, rgba(255,255,255,0) 100%);
  animation: shimmer 4s linear infinite;
}

/* ===== Input focus ===== */
input:focus, select:focus, textarea:focus {
  border-color: rgba(212, 160, 52, 0.5) !important;
  box-shadow: 0 0 0 3px rgba(212, 160, 52, 0.1) !important;
}

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