:root {
  --font-display: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-sans: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Space Mono', Consolas, monospace;

  --bg-obsidian: #0A0B0E;
  --bg-card: #12141A;
  --bg-card-hover: #181B24;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-gold: rgba(232, 197, 135, 0.3);
  --gold-primary: #E8C587;
  --gold-hover: #F5D89F;
  --gold-glow: rgba(232, 197, 135, 0.25);
  --text-primary: #F5F5F7;
  --text-secondary: #D1D5DB;
  --text-muted: #9E9EAD;
}

body {
  background-color: var(--bg-obsidian);
  color: var(--text-primary);
  font-family: var(--font-sans);
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--gold-primary);
  color: #000000;
}

/* Custom Sleek Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: #0A0B0E;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold-primary);
}

/* Typographic Flow & Modern Geometric Hierarchy */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  text-wrap: balance;
  letter-spacing: -0.028em;
}

p {
  text-wrap: pretty;
}

.font-display {
  font-family: var(--font-display);
  letter-spacing: -0.028em;
}

.font-serif {
  /* Alias to modern display for backwards compatibility */
  font-family: var(--font-display);
  letter-spacing: -0.028em;
}

.font-mono {
  font-family: var(--font-mono);
  font-feature-settings: 'tnum' 1, 'zero' 1;
  font-variant-numeric: tabular-nums;
}

.tnum {
  font-variant-numeric: tabular-nums;
  font-feature-settings: 'tnum' 1;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.20em;
  color: var(--gold-primary);
}

/* Accessible Focus Indicators (Obsidian Luxe Gold Rim) */
:focus-visible {
  outline: 2px solid var(--gold-primary);
  outline-offset: 3px;
}

/* Precise Section Anchoring with Fixed Navigation Clearance */
section[id],
div[id="director-packs"] {
  scroll-margin-top: 5.5rem;
}

/* Clean Obsidian Panels — Crisp, 100% Native DPI, Zero Raster Blur */
.glass-panel {
  background: rgba(18, 20, 26, 0.96);
  border: 1px solid var(--border-subtle);
}

.glass-panel-gold {
  background: rgba(24, 21, 16, 0.94);
  border: 1px solid var(--border-gold);
}

.glass-dock {
  background: rgba(14, 16, 22, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
}

/* Button & Pill Accents */
.btn-gold {
  background: linear-gradient(135deg, #E8C587 0%, #D4AF37 100%);
  color: #0A0B0E;
  font-weight: 600;
  transition: transform 0.15s ease, background 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 4px 20px rgba(232, 197, 135, 0.25);
  user-select: none;
}

.btn-gold:hover {
  background: linear-gradient(135deg, #F5D89F 0%, #E8C587 100%);
  box-shadow: 0 6px 28px rgba(232, 197, 135, 0.4);
  transform: translateY(-1px);
}

.btn-gold:active {
  transform: scale(0.97) translateY(0);
  box-shadow: 0 2px 10px rgba(232, 197, 135, 0.2);
  transition: transform 120ms cubic-bezier(0.2, 0, 0, 1);
}

.checkpoint-pill,
.director-pack-pill {
  transition: transform 0.15s ease, background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.checkpoint-pill:active,
.director-pack-pill:active {
  transform: scale(0.95);
  transition: transform 120ms cubic-bezier(0.2, 0, 0, 1);
}

/* Gold Gradient Text */
.text-gradient-gold {
  background: linear-gradient(135deg, #FFFFFF 0%, #F5F5F7 50%, #E8C587 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Lens Split Comparison Slider */
.slider-container {
  position: relative;
  overflow: hidden;
  user-select: none;
  touch-action: pan-y;
}

.slider-before {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10;
  isolation: isolate;
  overflow: hidden;
  will-change: clip-path;
}

.slider-after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 20;
  isolation: isolate;
  overflow: hidden;
  will-change: clip-path;
}

.slider-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, rgba(232, 197, 135, 0.2), #E8C587, rgba(232, 197, 135, 0.2));
  cursor: ew-resize;
  z-index: 50;
  box-shadow: 0 0 16px rgba(232, 197, 135, 0.8);
}

.slider-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  background: #0A0B0E;
  border: 2px solid #E8C587;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #E8C587;
  box-shadow: 0 0 20px rgba(232, 197, 135, 0.5);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.slider-handle:hover .slider-button,
.slider-handle:active .slider-button {
  transform: translate(-50%, -50%) scale(1.1);
  box-shadow: 0 0 30px rgba(232, 197, 135, 0.8);
}


/* Ambient Background Radial Glows (Living Atmosphere) */
@keyframes ambient-drift-gold {
  0%, 100% {
    transform: scale(1) translate(0, 0);
    opacity: 0.85;
  }
  50% {
    transform: scale(1.1) translate(28px, -18px);
    opacity: 1;
  }
}

@keyframes ambient-drift-blue {
  0%, 100% {
    transform: scale(1) translate(0, 0);
    opacity: 0.8;
  }
  50% {
    transform: scale(1.12) translate(-24px, 22px);
    opacity: 1;
  }
}

.ambient-glow-gold {
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(232, 197, 135, 0.08) 0%, rgba(10, 11, 14, 0) 70%);
  pointer-events: none;
  border-radius: 50%;
  filter: blur(60px);
  animation: ambient-drift-gold 22s infinite ease-in-out;
  will-change: transform;
}

.ambient-glow-blue {
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(45, 127, 249, 0.05) 0%, rgba(10, 11, 14, 0) 70%);
  pointer-events: none;
  border-radius: 50%;
  filter: blur(80px);
  animation: ambient-drift-blue 26s infinite ease-in-out;
  will-change: transform;
}

/* Feature 02: Generative Camera Motion (60 FPS Ken Burns Drift) */
@keyframes ken-burns-drift {
  0% {
    transform: scale(1.08) translate(0%, 0%);
  }
  50% {
    transform: scale(1.24) translate(-3.5%, -2.5%);
  }
  100% {
    transform: scale(1.15) translate(3%, 2%);
  }
}

.ken-burns-preview {
  animation: ken-burns-drift 6.5s cubic-bezier(0.4, 0, 0.2, 1) infinite alternate;
  will-change: transform;
  transform-origin: center center;
}

/* Phone Mockup Styling — iPhone 18 Pro Max Titanium Architecture */
.iphone-frame {
  height: 94%;
  aspect-ratio: 9 / 19.5;
  max-height: 560px;
  min-width: 170px;
  max-width: 270px;
  border: 4px solid #232632;
  border-radius: 32px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9), inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  overflow: hidden;
  background: #000000;
}

@media (min-width: 640px) {
  .iphone-frame {
    height: 94%;
    border: 6px solid #232632;
    border-radius: 38px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), inset 0 0 0 2px rgba(255, 255, 255, 0.12);
  }
}

.dynamic-island {
  width: 76px;
  height: 16px;
  background: #000000;
  border-radius: 12px;
  position: absolute;
  top: 7px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 40;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 640px) {
  .dynamic-island {
    width: 82px;
    height: 18px;
    top: 8px;
    border-radius: 14px;
  }
}

/* Pulsing Badge Indicator */
@keyframes pulse-subtle {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.96); }
}

.pulse-dot {
  animation: pulse-subtle 2.5s infinite ease-in-out;
}

@keyframes modal-shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-8px); }
  40%, 80% { transform: translateX(8px); }
}

.shake-animate {
  animation: modal-shake 0.4s ease-in-out;
}

/* Pricing Cards Interactive Hover & Button Transition */
.pricing-card {
  position: relative;
  border-radius: 1.5rem;
  background: #111319;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 2rem;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.3s ease,
              background 0.3s ease,
              box-shadow 0.3s ease;
  /* overflow is visible so 'Most Popular' badge is never clipped */
}

.pricing-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 140px;
  border-radius: 1.5rem 1.5rem 0 0;
  background: radial-gradient(circle at 50% 0%, rgba(232, 197, 135, 0.15) 0%, transparent 70%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.pricing-card:hover,
.pricing-card:focus-within {
  transform: translateY(-6px);
  border-color: #E8C587;
  background: linear-gradient(180deg, #161924 0%, #10121A 100%);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.7), 0 0 32px rgba(232, 197, 135, 0.22);
}

.pricing-card:hover::before,
.pricing-card:focus-within::before {
  opacity: 1;
}

.pricing-card.is-popular {
  border: 2px solid rgba(232, 197, 135, 0.45);
  background: rgba(24, 21, 16, 0.85);
}

.pricing-card.is-popular .pricing-card-btn {
  background: linear-gradient(135deg, #E8C587 0%, #D4AF37 100%);
  color: #0A0B0E;
  border-color: transparent;
  box-shadow: 0 4px 18px rgba(232, 197, 135, 0.25);
}

.pricing-card.is-popular .pricing-card-btn:hover {
  background: linear-gradient(135deg, #F5D89F 0%, #E8C587 100%);
  box-shadow: 0 6px 26px rgba(232, 197, 135, 0.45);
}

.pricing-card.is-popular:hover,
.pricing-card.is-popular:focus-within {
  border-color: #F5D89F;
  background: linear-gradient(180deg, #1E1A24 0%, #13131D 100%);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.7), 0 0 42px rgba(232, 197, 135, 0.32);
}

/* Pricing Card Buttons: in color of background by default, gold on hover */
.pricing-card-btn {
  width: 100%;
  padding-top: 0.875rem;
  padding-bottom: 0.875rem;
  border-radius: 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: center;
  display: block;
  /* Default unhovered: color of background, subtle border, no animation */
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #D1D5DB;
  transition: background 0.3s ease,
              color 0.3s ease,
              border-color 0.3s ease,
              box-shadow 0.3s ease,
              transform 0.2s ease;
}

/* When the card or button is hovered, button turns gold */
.pricing-card:hover .pricing-card-btn,
.pricing-card:focus-within .pricing-card-btn {
  background: linear-gradient(135deg, #E8C587 0%, #D4AF37 100%);
  color: #0A0B0E;
  border-color: transparent;
  box-shadow: 0 4px 20px rgba(232, 197, 135, 0.3);
}

.pricing-card .pricing-card-btn:hover {
  background: linear-gradient(135deg, #F5D89F 0%, #E8C587 100%);
  box-shadow: 0 6px 28px rgba(232, 197, 135, 0.45);
  transform: translateY(-1px);
}

.pricing-card .pricing-card-btn:active,
.pricing-card-btn:active {
  transform: scale(0.97) translateY(0);
  box-shadow: 0 2px 10px rgba(232, 197, 135, 0.2);
  transition: transform 120ms cubic-bezier(0.2, 0, 0, 1);
}

/* ==========================================================================
   IMPECCABLE MOTION SYSTEM
   ========================================================================== */

/* 1. Modal Dialog Physics (Zero Layout Pop) */
.modal-backdrop {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.22s ease-out, visibility 0.22s;
}

.modal-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.modal-backdrop .modal-card {
  transform: scale(0.95) translateY(12px);
  opacity: 0;
  transition: transform 0.26s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.22s ease-out;
  will-change: transform, opacity;
}

.modal-backdrop.is-open .modal-card {
  transform: scale(1) translateY(0);
  opacity: 1;
}

/* 2. Scroll Reveal Transitions (Clean, Zero Subpixel Blur on Settle) */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1), transform 0.55s cubic-bezier(0.16, 1, 0.3, 1) !important;
  transition-delay: calc(var(--i, 0) * 75ms) !important;
  will-change: opacity, transform;
}

.reveal-on-scroll.is-revealed {
  opacity: 1 !important;
  transform: translateY(0) !important;
  will-change: auto;
}

.reveal-on-scroll.is-revealed:hover {
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease !important;
}

/* 3. Director Pack Dynamic LUT Transitions */
#director-pack-preview {
  transition: filter 0.38s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease;
}

#director-pack-title,
#director-pack-desc {
  transition: opacity 0.14s ease-out;
}

/* 4. Respect User Reduced-Motion Preferences */
@media (prefers-reduced-motion: reduce) {
  .reveal-on-scroll {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .ambient-glow-gold,
  .ambient-glow-blue {
    animation: none !important;
  }
  .pulse-dot {
    animation: none !important;
  }
  .ken-burns-preview {
    animation: none !important;
  }
  .modal-backdrop .modal-card {
    transform: none !important;
    transition: opacity 0.15s ease-out !important;
  }
}

/* 5. Legal Modal Custom Scrollbar & Tab Indicators */
.custom-legal-scrollbar {
  scrollbar-width: thin;
  scrollbar-color: rgba(232, 197, 135, 0.3) rgba(255, 255, 255, 0.02);
}

.custom-legal-scrollbar::-webkit-scrollbar {
  width: 6px;
}

.custom-legal-scrollbar::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.02);
  border-radius: 9999px;
}

.custom-legal-scrollbar::-webkit-scrollbar-thumb {
  background: rgba(232, 197, 135, 0.28);
  border-radius: 9999px;
  border: 1px solid rgba(18, 20, 26, 0.8);
}

.custom-legal-scrollbar::-webkit-scrollbar-thumb:hover {
  background: rgba(232, 197, 135, 0.55);
}

.legal-tab-btn.active {
  background-color: rgba(232, 197, 135, 0.12);
  border-color: rgba(232, 197, 135, 0.4);
  color: #F5D89F;
  box-shadow: 0 0 12px rgba(232, 197, 135, 0.1);
}

