/* ============================================
   OPTIMANCER — BASE STYLESHEET
   Royal Protocol Color Palette
   Shared across all funnel pages
   ============================================ */

/* ---------- CUSTOM PROPERTIES ---------- */
:root {
  --deep-purple: #1A0A2E;
  --lighter-purple: #2D1B4E;
  --rich-gold: #D4AF37;
  --gold-light: #E8C84A;
  --white: #FFFFFF;
  --warm-coral: #E8634A;
  --coral-hover: #F07A63;
  --soft-lavender: #C8B8E8;
  --near-black: #0D0519;

  --glass-bg: rgba(26, 10, 46, 0.55);
  --glass-border: rgba(212, 175, 55, 0.3);
  --glass-border-hover: rgba(212, 175, 55, 0.6);
  --glass-border-strong: rgba(212, 175, 55, 0.5);
  --coral-glow: rgba(232, 99, 74, 0.4);
  --text-body: rgba(255, 255, 255, 0.88);
  --text-muted: rgba(255, 255, 255, 0.6);

  --font-display: 'DM Sans', sans-serif;
  --font-body: 'Inter', 'DM Sans', sans-serif;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 180ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: 350ms cubic-bezier(0.16, 1, 0.3, 1);

  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-padding-top: 2rem;
}

body {
  font-family: var(--font-body);
  background: var(--near-black);
  color: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100dvh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--rich-gold);
  text-decoration: none;
  transition: color 0.2s var(--ease-smooth);
}

a:hover {
  color: var(--gold-light);
}

input, button, textarea, select { font: inherit; color: inherit; }
h1, h2, h3, h4, h5, h6 { text-wrap: balance; line-height: 1.15; font-family: var(--font-display); }
p, li, figcaption { text-wrap: pretty; }
button { cursor: pointer; background: none; border: none; }
ul[role="list"] { list-style: none; }

::selection {
  background: rgba(212, 175, 55, 0.3);
  color: var(--white);
}

:focus-visible {
  outline: 2px solid var(--rich-gold);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- LAYOUT ---------- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.container--narrow {
  max-width: 680px;
}

/* ---------- GLASS CARD ---------- */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 32px;
  transition: border-color 0.3s var(--ease-smooth), box-shadow 0.3s var(--ease-smooth);
}

.glass-card:hover {
  border-color: var(--glass-border-hover);
  box-shadow: 0 0 40px rgba(212, 175, 55, 0.08);
}

.glass-card--form {
  background: rgba(26, 10, 46, 0.72);
  padding: 40px 36px;
}

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.08em;
  padding: 16px 40px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
  transition: all 0.3s var(--ease-smooth);
  position: relative;
  overflow: hidden;
}

.btn--coral {
  background: var(--warm-coral);
  color: var(--white);
  box-shadow: 0 4px 24px rgba(232, 99, 74, 0.35);
}

.btn--coral:hover {
  background: var(--coral-hover);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(232, 99, 74, 0.5);
}

.btn--coral:active {
  transform: translateY(0);
}

.btn--pulse {
  animation: pulse-glow 2.5s ease-in-out infinite;
}

.btn--pulse:hover {
  animation: none;
}

@keyframes pulse-glow {
  0%, 100% {
    box-shadow: 0 4px 24px rgba(232, 99, 74, 0.35);
  }
  50% {
    box-shadow: 0 4px 40px rgba(232, 99, 74, 0.6), 0 0 60px rgba(232, 99, 74, 0.2);
  }
}

/* Standalone CTA button (replay page style) */
.btn-cta {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--white);
  background: var(--warm-coral);
  padding: 18px 48px;
  border-radius: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(232, 99, 74, 0.4);
  cursor: pointer;
  border: none;
  text-decoration: none;
}

.btn-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 30px rgba(232, 99, 74, 0.6);
  background: #ec7560;
  color: var(--white);
}

/* ---------- SECTION SHARED ---------- */
.section {
  position: relative;
  padding: 100px 0;
  overflow: hidden;
}

.section .container {
  position: relative;
  z-index: 2;
}

.section__bg-image {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.section__bg-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.section__bg-overlay {
  position: absolute;
  inset: 0;
}

.section__bg-overlay--purple {
  background: linear-gradient(
    180deg,
    rgba(26, 10, 46, 0.8) 0%,
    rgba(45, 27, 78, 0.7) 50%,
    rgba(26, 10, 46, 0.85) 100%
  );
}

.section__bg-overlay--dark {
  background: linear-gradient(
    180deg,
    rgba(13, 5, 25, 0.78) 0%,
    rgba(26, 10, 46, 0.72) 50%,
    rgba(13, 5, 25, 0.85) 100%
  );
}

.section__bg-overlay--dark-heavy {
  background: linear-gradient(
    180deg,
    rgba(13, 5, 25, 0.88) 0%,
    rgba(26, 10, 46, 0.78) 50%,
    rgba(13, 5, 25, 0.9) 100%
  );
}

.section__heading {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 700;
  color: var(--rich-gold);
  line-height: 1.2;
  margin-bottom: 48px;
  text-shadow: 0 2px 24px rgba(212, 175, 55, 0.15);
}

.section__heading--center {
  text-align: center;
}

.section__eyebrow {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  color: var(--warm-coral);
  margin-bottom: 12px;
  text-shadow: none;
}

.section__cta {
  text-align: center;
  margin-top: 48px;
}

/* Section headline (sales page style) */
.section-headline {
  font-family: var(--font-display);
  font-size: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  font-weight: 700;
  color: var(--rich-gold);
  text-align: center;
  margin-bottom: 3rem;
  line-height: 1.15;
}

/* ---------- HERO SHARED ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__bg img,
.hero__bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(13, 5, 25, 0.82) 0%,
    rgba(26, 10, 46, 0.68) 40%,
    rgba(45, 27, 78, 0.55) 100%
  );
}

/* ---------- COUNTDOWN SHARED ---------- */
.countdown {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
}

.countdown__block {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 56px;
}

.countdown__label {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--rich-gold);
  margin-bottom: 12px;
  text-transform: uppercase;
}

.countdown__timer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.countdown__unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 56px;
}

.countdown__number {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  color: var(--white);
  line-height: 1;
}

.countdown__text {
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--soft-lavender);
  margin-top: 4px;
}

.countdown__sep {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--rich-gold);
  margin-top: -14px;
}

/* ---------- FORM ELEMENTS ---------- */
.form-privacy {
  font-size: 0.8rem;
  color: var(--soft-lavender);
  text-align: center;
  margin-top: 12px;
  opacity: 0.8;
}

.form-seats {
  font-size: 0.82rem;
  color: var(--warm-coral);
  text-align: center;
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.seats-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--warm-coral);
  display: inline-block;
  animation: blink 1.4s ease-in-out infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

/* ---------- ANIMATIONS ---------- */
.animate-in {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.section-fade {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.section-fade.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- RESPONSIVE — TABLET ---------- */
@media (max-width: 968px) {
  .section {
    padding: 80px 0;
  }
}

/* ---------- RESPONSIVE — MOBILE ---------- */
@media (max-width: 640px) {
  .section {
    padding: 72px 0;
  }

  .glass-card {
    padding: 24px;
  }

  .glass-card--form {
    padding: 28px 20px;
  }

  .section__heading {
    font-size: 1.6rem;
    margin-bottom: 32px;
  }

  .btn {
    padding: 14px 28px;
    font-size: 0.92rem;
  }

  .countdown__number {
    font-size: 1.5rem;
  }

  .countdown__unit {
    min-width: 46px;
  }

  .countdown__block {
    min-width: 46px;
  }

  .countdown__sep {
    font-size: 1.2rem;
  }

  .btn-cta {
    padding: 16px 36px;
    font-size: 1rem;
  }
}
