/* ═══════════════════════════════════════════════════
   DG SPORT — CSS Design System
   Aesthetic: Luxury Motorsport — carbon black / racing red / white text
   Fonts: Bebas Neue (display) + Outfit (body)
═══════════════════════════════════════════════════ */

/* ─── CUSTOM PROPERTIES ─────────────────────────── */
:root {
  --bg-dark:       #080808;
  --bg-mid:        #111111;
  --bg-light:      #F2EEE8;
  --accent:        #E8001D;
  --text-on-dark:  #F2EEE8;
  --text-muted:    rgba(242, 238, 232, 0.45);
  --text-dim:      rgba(242, 238, 232, 0.7);
  --font-display:  'Bebas Neue', sans-serif;
  --font-body:     'Outfit', sans-serif;
  --ease-out:      cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out:   cubic-bezier(0.76, 0, 0.24, 1);
}

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

html { scroll-behavior: auto; font-size: 16px; }

body {
  font-family: var(--font-body);
  background: var(--bg-dark);
  color: var(--text-on-dark);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { text-decoration: none; color: inherit; }
img, video { display: block; max-width: 100%; }

/* ─── LOADER ─────────────────────────────────────── */
#loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg-dark);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  transition: opacity 0.6s var(--ease-out), visibility 0.6s;
}

#loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-brand {
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 4.5rem);
  letter-spacing: 0.4em;
  color: var(--text-on-dark);
}

.loader-bar-wrap {
  width: min(280px, 60vw);
  height: 1px;
  background: rgba(242, 238, 232, 0.12);
  overflow: hidden;
}

#loader-bar {
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 0.1s linear;
}

#loader-percent {
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.2em;
  color: var(--text-muted);
}

/* ─── SITE HEADER ────────────────────────────────── */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 4vw;
  transition: background 0.4s var(--ease-out);
}

.site-header.scrolled {
  background: rgba(8, 8, 8, 0.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.header-logo {
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.1em;
  color: var(--text-on-dark);
}

.header-logo .accent { color: var(--accent); }

.header-nav {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.header-nav a {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s;
}

.header-nav a:hover { color: var(--text-on-dark); }

.nav-cta {
  padding: 0.55rem 1.4rem !important;
  border: 1px solid var(--accent) !important;
  color: var(--accent) !important;
  border-radius: 2px;
  font-weight: 600 !important;
  transition: background 0.2s, color 0.2s !important;
}

.nav-cta:hover {
  background: var(--accent) !important;
  color: var(--text-on-dark) !important;
}

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 1px;
  background: var(--text-on-dark);
}

/* ─── HERO STANDALONE ────────────────────────────── */
.hero-standalone {
  position: relative;
  height: 100vh;
  background: var(--bg-dark);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 6vw 10vh;
  z-index: 10;
  overflow: hidden;
}

.hero-content { position: relative; z-index: 2; }

.section-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.2rem;
}

.hero-heading {
  font-family: var(--font-display);
  font-size: clamp(6rem, 18vw, 15rem);
  line-height: 0.9;
  color: var(--text-on-dark);
  display: flex;
  flex-direction: column;
}

.hero-heading .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(60px);
}

.hero-heading .accent-word { color: var(--accent); }

.hero-tagline {
  margin-top: 1.5rem;
  font-size: clamp(0.9rem, 1.5vw, 1.1rem);
  font-weight: 300;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-muted);
  opacity: 0;
}

.scroll-indicator {
  position: absolute;
  bottom: 8vh;
  right: 6vw;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  opacity: 0;
  animation: fadeInUp 0.8s var(--ease-out) 1.8s forwards;
}

.scroll-text {
  font-size: 0.6rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-muted);
  writing-mode: vertical-rl;
}

.scroll-arrow {
  width: 20px;
  color: var(--text-muted);
  animation: arrowBounce 2s ease-in-out infinite;
}

.scroll-arrow svg { width: 100%; }

.hero-bg-grain {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  background-size: 256px 256px;
  opacity: 0.6;
  pointer-events: none;
  z-index: 1;
}

/* ─── CANVAS WRAP ────────────────────────────────── */
.canvas-wrap {
  position: fixed;
  inset: 0;
  z-index: 5;
  clip-path: circle(0% at 50% 50%);
  will-change: clip-path;
}

#canvas { width: 100%; height: 100%; display: block; }

/* ─── DARK OVERLAY ───────────────────────────────── */
#dark-overlay {
  position: fixed;
  inset: 0;
  z-index: 6;
  background: var(--bg-dark);
  opacity: 0;
  pointer-events: none;
  will-change: opacity;
}

/* ─── MARQUEE ────────────────────────────────────── */
.marquee-wrap {
  position: fixed;
  bottom: 6vh;
  left: 0; right: 0;
  z-index: 8;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  will-change: opacity;
}

.marquee-text {
  font-family: var(--font-display);
  font-size: clamp(8vw, 12vw, 14vw);
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(242, 238, 232, 0.18);
  line-height: 1;
  will-change: transform;
}

/* ─── SCROLL CONTAINER ───────────────────────────── */
#scroll-container {
  position: relative;
  height: 900vh;
  z-index: 7;
}

/* ─── SCROLL SECTIONS ────────────────────────────── */
.scroll-section {
  position: absolute;
  left: 0; right: 0;
  display: flex;
  align-items: center;
  pointer-events: none;
  opacity: 0;
}

.scroll-section.visible {
  pointer-events: auto;
  opacity: 1;
}

.align-left  { padding-left: 5vw;  padding-right: 55vw; justify-content: flex-start; }
.align-right { padding-left: 55vw; padding-right: 5vw;  justify-content: flex-end; }

.align-left .section-inner,
.align-right .section-inner { max-width: 38vw; }

.section-content .section-inner { padding: 2rem 0; }

.section-heading {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 5.5rem);
  line-height: 0.9;
  color: var(--text-on-dark);
  margin-bottom: 1.5rem;
}

.section-body {
  font-size: clamp(0.9rem, 1.2vw, 1rem);
  font-weight: 300;
  line-height: 1.8;
  color: var(--text-dim);
  margin-bottom: 1.8rem;
  max-width: 34ch;
}

.section-link {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: gap 0.2s;
}

.section-link:hover { gap: 1rem; }

/* ─── STATS SECTION ──────────────────────────────── */
.section-stats { justify-content: center; align-items: center; }

.stats-grid {
  display: flex;
  gap: clamp(3rem, 8vw, 8rem);
  align-items: flex-end;
  z-index: 7;
  position: relative;
}

.stat {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.stat-value-wrap {
  display: flex;
  align-items: baseline;
  gap: 0.2rem;
  line-height: 1;
}

.stat-number {
  font-family: var(--font-display);
  font-size: clamp(4rem, 8vw, 7rem);
  color: var(--text-on-dark);
  line-height: 1;
}

.stat-suffix {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.5vw, 3rem);
  color: var(--accent);
  line-height: 1;
}

.stat-label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ─── CTA SECTION ────────────────────────────────── */
.cta-heading { color: var(--text-on-dark) !important; }

.cta-button {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-on-dark);
  background: var(--accent);
  padding: 1rem 2.5rem;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
  margin-bottom: 1rem;
}

.cta-button:hover { background: #cc0018; transform: translateY(-2px); }

.section-note {
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ─── POST-CANVAS EYEBROW ────────────────────────── */
.section-eyebrow {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

.post-heading {
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 7vw, 6rem);
  line-height: 0.95;
  color: var(--text-on-dark);
  margin-bottom: 5rem;
}

.post-heading em { font-style: normal; color: var(--accent); }

/* ─── CIRCUITS ───────────────────────────────────── */
.testimonials-section {
  background: var(--bg-dark);
  padding: 10rem 6vw;
  border-top: 1px solid rgba(242, 238, 232, 0.06);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr 1fr;
  gap: 3rem;
  align-items: start;
}

.testimonial {
  padding: 2.5rem;
  border-top: 2px solid rgba(242, 238, 232, 0.1);
}

.testimonial-featured {
  border-top-color: var(--accent);
  background: rgba(232, 0, 29, 0.04);
  padding: 3rem;
}

.testimonial-quote {
  font-family: var(--font-display);
  font-size: 6rem;
  line-height: 0.5;
  color: var(--accent);
  opacity: 0.35;
  margin-bottom: 1.5rem;
}

.circuit-flag {
  font-size: 3rem !important;
  opacity: 1 !important;
  line-height: 1.2 !important;
}

.testimonial-text {
  font-size: clamp(0.9rem, 1.2vw, 1rem);
  font-weight: 300;
  line-height: 1.75;
  color: var(--text-dim);
  margin-bottom: 2rem;
}

.testimonial-featured .testimonial-text { color: rgba(242, 238, 232, 0.85); }

.author-name {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text-on-dark);
}

.author-title {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.circuits-more {
  margin-top: 4rem;
  padding-top: 2.5rem;
  border-top: 1px solid rgba(242, 238, 232, 0.07);
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.circuits-more > span {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  flex-shrink: 0;
}

.circuits-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.circuit-tag {
  font-size: 0.78rem;
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  padding: 0.4rem 0.9rem;
  border: 1px solid rgba(242, 238, 232, 0.12);
  transition: border-color 0.2s, color 0.2s;
  cursor: default;
}

.circuit-tag:hover { border-color: var(--accent); color: var(--text-on-dark); }

/* ─── SERVICES ───────────────────────────────────── */
.pricing-section {
  background: var(--bg-mid);
  padding: 10rem 6vw;
  border-top: 1px solid rgba(242, 238, 232, 0.06);
}

.pricing-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr 1fr;
  gap: 1.5rem;
  align-items: stretch;
}

.pricing-card {
  padding: 3rem 2.5rem;
  border: 1px solid rgba(242, 238, 232, 0.1);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: relative;
  transition: border-color 0.3s;
}

.pricing-card:hover { border-color: rgba(242, 238, 232, 0.25); }

.pricing-card-featured {
  border-color: var(--accent);
  background: rgba(232, 0, 29, 0.04);
}

.pricing-card-featured:hover { border-color: var(--accent); }

.pricing-badge {
  position: absolute;
  top: -1px;
  left: 2.5rem;
  background: var(--accent);
  color: var(--text-on-dark);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  padding: 0.3rem 0.8rem;
}

.pricing-tier {
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 0.15em;
  color: var(--text-muted);
}

.pricing-icon {
  width: 44px;
  height: 44px;
  color: var(--accent);
  opacity: 0.6;
}

.pricing-icon svg { width: 100%; height: 100%; }

.pricing-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex: 1;
}

.pricing-features li {
  font-size: 0.88rem;
  font-weight: 300;
  color: var(--text-dim);
  padding-left: 1rem;
  position: relative;
}

.pricing-features li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--accent);
  opacity: 0.5;
}

.pricing-cta {
  display: block;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 1rem;
  background: var(--accent);
  color: var(--text-on-dark);
  transition: background 0.2s;
}

.pricing-cta:hover { background: #cc0018; }

.pricing-cta-secondary {
  background: transparent;
  border: 1px solid rgba(242, 238, 232, 0.2);
  color: var(--text-dim);
}

.pricing-cta-secondary:hover {
  background: rgba(242, 238, 232, 0.05);
  border-color: rgba(242, 238, 232, 0.45);
}

/* ─── PARTNERS ───────────────────────────────────── */
.partners-section {
  margin-top: 5rem;
  padding-top: 3rem;
  border-top: 1px solid rgba(242, 238, 232, 0.06);
  text-align: center;
}

.partners-label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.partners-row {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem 2rem;
}

.partner-name {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2vw, 1.6rem);
  letter-spacing: 0.1em;
  color: rgba(242, 238, 232, 0.2);
  transition: color 0.3s;
}

.partner-name:hover { color: rgba(242, 238, 232, 0.6); }

.partner-sep { color: var(--accent); opacity: 0.35; font-size: 1rem; }

/* ─── FAQ ────────────────────────────────────────── */
.faq-section {
  background: var(--bg-dark);
  padding: 10rem 6vw;
  border-top: 1px solid rgba(242, 238, 232, 0.06);
}

.faq-list { max-width: 860px; }

.faq-item { border-bottom: 1px solid rgba(242, 238, 232, 0.09); overflow: hidden; }
.faq-item:first-child { border-top: 1px solid rgba(242, 238, 232, 0.09); }

.faq-question {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  padding: 1.75rem 0;
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.4vw, 1.05rem);
  font-weight: 500;
  color: var(--text-on-dark);
  text-align: left;
  transition: color 0.2s;
}

.faq-question:hover { color: var(--accent); }

.faq-icon {
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 0.35s var(--ease-out);
  line-height: 1;
}

.faq-item.open .faq-icon { transform: rotate(45deg); }

.faq-answer { height: 0; overflow: hidden; }

.faq-answer p {
  font-size: 0.92rem;
  font-weight: 300;
  line-height: 1.8;
  color: var(--text-dim);
  padding-bottom: 1.75rem;
  max-width: 65ch;
}

/* ─── FOOTER ─────────────────────────────────────── */
.site-footer {
  background: #030303;
  border-top: 3px solid var(--accent);
  padding: 6rem 6vw 3rem;
}

.footer-top {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 5rem;
  margin-bottom: 5rem;
  align-items: start;
}

.footer-logo {
  font-family: var(--font-display);
  font-size: 2.2rem;
  letter-spacing: 0.08em;
  color: var(--text-on-dark);
  margin-bottom: 0.75rem;
}

.footer-logo .accent { color: var(--accent); }

.footer-tagline {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.footer-contact-info {
  margin-top: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.footer-contact-info p {
  font-size: 0.82rem;
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.5;
}

.footer-contact-info a { color: var(--text-muted); transition: color 0.2s; }
.footer-contact-info a:hover { color: var(--accent); }

.footer-links { display: flex; gap: 4rem; }

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-col-title {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-on-dark);
  margin-bottom: 0.5rem;
}

.footer-col a {
  font-size: 0.85rem;
  font-weight: 300;
  color: var(--text-muted);
  transition: color 0.2s;
}

.footer-col a:hover { color: var(--text-on-dark); }

.footer-social { min-width: 140px; }

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.social-link {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(242, 238, 232, 0.12);
  color: var(--text-muted);
  transition: border-color 0.2s, color 0.2s;
}

.social-link:hover { border-color: var(--accent); color: var(--accent); }
.social-link svg { width: 16px; height: 16px; }

.footer-booking-cta { margin-top: 1.5rem; }

.footer-booking-btn {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid rgba(232, 0, 29, 0.4);
  padding: 0.65rem 1.1rem;
  transition: background 0.2s, color 0.2s;
}

.footer-booking-btn:hover {
  background: var(--accent);
  color: var(--text-on-dark);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(242, 238, 232, 0.06);
}

.footer-copy {
  font-size: 0.72rem;
  color: rgba(242, 238, 232, 0.22);
}

.footer-legal { display: flex; gap: 2rem; }

.footer-legal a {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: rgba(242, 238, 232, 0.22);
  transition: color 0.2s;
}

.footer-legal a:hover { color: rgba(242, 238, 232, 0.6); }

/* ─── KEYFRAMES ──────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes arrowBounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(6px); }
}

/* ─── TABLET ─────────────────────────────────────── */
@media (max-width: 1024px) {
  .testimonials-grid { grid-template-columns: 1fr 1fr; }
  .testimonials-grid .testimonial:last-child { grid-column: 1 / -1; }
  .pricing-grid { grid-template-columns: 1fr; max-width: 480px; }
  .footer-top { grid-template-columns: 1fr; gap: 3rem; }
  .footer-links { flex-wrap: wrap; gap: 2.5rem; }
}

/* ─── MOBILE ─────────────────────────────────────── */
@media (max-width: 768px) {
  #scroll-container { height: 580vh; }

  .align-left, .align-right {
    padding: 0 6vw;
    justify-content: flex-start;
    align-items: flex-end;
  }

  .align-left .section-inner,
  .align-right .section-inner {
    max-width: 100%;
    background: rgba(8, 8, 8, 0.82);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    padding: 1.5rem;
    border-left: 2px solid var(--accent);
  }

  .section-heading { font-size: clamp(2.5rem, 10vw, 4rem); }
  .hero-heading { font-size: clamp(4.5rem, 20vw, 8rem); }
  .stats-grid { flex-direction: column; gap: 2.5rem; align-items: center; }
  .testimonials-grid { grid-template-columns: 1fr; }
  .header-nav { display: none; }
  .menu-toggle { display: flex; }
  .marquee-text { font-size: 18vw; }
  .post-heading { font-size: clamp(2.8rem, 10vw, 4rem); }
  .footer-links { flex-direction: column; gap: 2rem; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
  .circuits-more { flex-direction: column; align-items: flex-start; }
}
