@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700&family=Inter:wght@400;500;600;700&display=swap');

/* ---------- Design tokens ---------- */
:root {
  --font-display: 'Rajdhani', sans-serif;
  --font-body: 'Inter', sans-serif;

  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 24px;
  --space-lg: 40px;
  --space-xl: 64px;
  --space-2xl: 96px;
  --space-3xl: 140px;

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 24px;

  --container: 1240px;

  --dur-fast: 150ms;
  --dur-base: 250ms;
  --dur-slow: 400ms;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);

  --z-nav: 100;
  --z-overlay: 200;
  --z-toast: 300;
}

/* ---------- Theme: Ignition (default) — dark, red/orange/amber, aggressive ---------- */
:root,
[data-theme="ignition"] {
  --bg: #0b0b0c;
  --bg-elevated: #141415;
  --surface: #1b1b1d;
  --surface-2: #232325;
  --text: #f5f4f2;
  --text-muted: #a3a1a0;
  --border: rgba(255, 255, 255, 0.09);
  --accent: #ef4b1e;
  --accent-2: #ffb100;
  --accent-3: #7a0d0d;
  --scale-8: #7a0d0d;
  --scale-10: #ffb100;
  --accent-gradient: linear-gradient(100deg, #7a0d0d 0%, #e63312 48%, #ffb100 100%);
  --on-accent: #fff9f0;
  --glow: rgba(230, 51, 18, 0.35);
  --scheme: dark;
}

[data-theme="mint"] {
  --bg: #ffffff;
  --bg-elevated: #f6f9f9;
  --surface: #eef4f4;
  --surface-2: #e3edee;
  --text: #12242a;
  --text-muted: #55686d;
  --border: rgba(18, 36, 42, 0.1);
  --accent: #0f7a7a;
  --accent-2: #1f9e9e;
  --accent-3: #0a3d62;
  --scale-8: #0a3d62;
  --scale-10: #8ff5c9;
  --accent-gradient: linear-gradient(100deg, #0a3d62 0%, #1f9e9e 48%, #8ff5c9 100%);
  --on-accent: #ffffff;
  --glow: rgba(31, 158, 158, 0.28);
  --scheme: light;
}

[data-theme="earth"] {
  --bg: #ede0c8;
  --bg-elevated: #f3e9d3;
  --surface: #e2d3b0;
  --surface-2: #d8c69c;
  --text: #1a120c;
  --text-muted: #5c4c3a;
  --border: rgba(26, 18, 12, 0.12);
  --accent: #6b4226;
  --accent-2: #8a5a34;
  --accent-3: #2b1a12;
  --scale-8: #2b1a12;
  --scale-10: #c9a66b;
  --accent-gradient: linear-gradient(100deg, #2b1a12 0%, #6b4226 48%, #c9a66b 100%);
  --on-accent: #f6ead2;
  --glow: rgba(107, 66, 38, 0.25);
  --scheme: light;
}

[data-theme="grayscale"] {
  --bg: #fafafa;
  --bg-elevated: #f2f2f2;
  --surface: #eaeaea;
  --surface-2: #dedede;
  --text: #1c1c1c;
  --text-muted: #5f5f5f;
  --border: rgba(28, 28, 28, 0.12);
  --accent: #3d3d3d;
  --accent-2: #6e6e6e;
  --accent-3: #1c1c1c;
  --scale-8: #1c1c1c;
  --scale-10: #bdbdbd;
  --accent-gradient: linear-gradient(100deg, #1c1c1c 0%, #6e6e6e 48%, #bdbdbd 100%);
  --on-accent: #fafafa;
  --glow: rgba(60, 60, 60, 0.2);
  --scheme: light;
}

[data-theme="sneaker"] {
  --bg: #f5f1e6;
  --bg-elevated: #faf7ee;
  --surface: #ece4d2;
  --surface-2: #e2d7bd;
  --text: #2b1a12;
  --text-muted: #6c5a48;
  --border: rgba(43, 26, 18, 0.12);
  --accent: #1a7f8f;
  --accent-2: #e8434f;
  --accent-3: #ffcf3d;
  --scale-8: #4a7f8c;
  --scale-10: #ffcf3d;
  --accent-gradient: linear-gradient(100deg, #4a7f8c 0%, #1fb3a3 40%, #e8434f 70%, #ffcf3d 100%);
  --on-accent: #fff5e6;
  --glow: rgba(31, 179, 163, 0.25);
  --scheme: light;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--dur-slow) var(--ease-in-out), color var(--dur-slow) var(--ease-in-out);
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; margin: 0; letter-spacing: 0.01em; }
p { margin: 0; }

:focus-visible {
  outline: 3px solid var(--accent-2);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 1000;
  background: var(--accent);
  color: var(--on-accent);
  padding: 12px 20px;
  border-radius: var(--radius-sm);
}
.skip-link:focus { left: var(--space-sm); top: var(--space-sm); }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-sm);
}
@media (min-width: 768px) { .container { padding-inline: var(--space-lg); } }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow::before {
  content: '';
  width: 28px;
  height: 3px;
  background: var(--accent-gradient);
  border-radius: 2px;
}

.section-heading {
  font-size: clamp(28px, 4.5vw, 44px);
  line-height: 1.1;
  text-transform: uppercase;
  margin-block: var(--space-sm) var(--space-md);
}

.section-lede {
  max-width: 60ch;
  color: var(--text-muted);
  font-size: clamp(15px, 1.6vw, 17px);
}

section { position: relative; padding-block: var(--space-2xl); }
@media (max-width: 640px) { section { padding-block: var(--space-xl); } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  min-height: 48px;
  padding: 0 28px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out), background var(--dur-base) var(--ease-out);
  cursor: pointer;
}
.btn:active { transform: scale(0.97); }

.btn-primary {
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: 0 8px 24px -8px var(--glow);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 32px -8px var(--glow); }

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }

.btn-sm { min-height: 40px; padding: 0 20px; font-size: 14px; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed;
  inset-block-start: 0;
  inset-inline: 0;
  z-index: var(--z-nav);
  padding-block: var(--space-sm);
  transition: background-color var(--dur-base) var(--ease-out), padding var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out);
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
  padding-block: 10px;
  /* Keep the blurred header on a stable compositing layer so it doesn't
     re-flash while the hero slideshow crossfades behind it on mobile. */
  transform: translateZ(0);
}

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.brand-logo {
  height: 56px;
  width: auto;
  flex-shrink: 0;
  transition: opacity var(--dur-base) var(--ease-out);
}

.nav-row > a:first-child { flex-shrink: 0; }

.nav-links {
  display: none;
  align-items: center;
  gap: var(--space-lg);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.nav-links a {
  position: relative;
  padding-block: 4px;
  color: var(--text);
  opacity: 0.85;
  transition: opacity var(--dur-fast);
}
.nav-links a::after {
  content: '';
  position: absolute;
  left: 0; right: 100%;
  bottom: -2px;
  height: 2px;
  background: var(--accent-gradient);
  transition: right var(--dur-base) var(--ease-out);
}
.nav-links a:hover { opacity: 1; }
.nav-links a:hover::after { right: 0; }

@media (min-width: 900px) {
  .nav-links { display: flex; }
}

.nav-actions { display: flex; align-items: center; gap: var(--space-sm); }

@media (max-width: 899px) {
  .nav-actions > .theme-switcher { display: none; }
}

/* Theme switcher */
.theme-switcher {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 80%, transparent);
}
.theme-swatch {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid transparent;
  padding: 0;
  transition: transform var(--dur-fast) var(--ease-out), border-color var(--dur-fast);
  position: relative;
}
.theme-swatch:hover { transform: scale(1.15); }
.theme-swatch[aria-checked="true"] {
  border-color: var(--text);
}
.theme-swatch[aria-checked="true"]::after {
  content: '';
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  border: 1.5px solid var(--text);
  opacity: 0.5;
}
.swatch-ignition { background: linear-gradient(135deg, #7a0d0d, #e63312, #ffb100); }
.swatch-mint { background: linear-gradient(135deg, #0a3d62, #1f9e9e, #8ff5c9); }
.swatch-earth { background: linear-gradient(135deg, #2b1a12, #6b4226, #c9a66b); }
.swatch-grayscale { background: linear-gradient(135deg, #1c1c1c, #6e6e6e, #bdbdbd); }
.swatch-sneaker { background: linear-gradient(135deg, #1fb3a3, #e8434f, #ffcf3d); }

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  align-items: center;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--dur-base) var(--ease-out), opacity var(--dur-base) var(--ease-out);
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
@media (min-width: 900px) { .nav-toggle { display: none; } }

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-nav) - 1);
  background: var(--bg);
  padding: 100px var(--space-sm) var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  transform: translateY(-8px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out), visibility var(--dur-base);
}
.mobile-menu.is-open {
  opacity: 1;
  transform: translateY(0);
  visibility: visible;
  pointer-events: auto;
}
.mobile-menu ul { display: flex; flex-direction: column; gap: var(--space-md); }
.mobile-menu a {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  text-transform: uppercase;
}
@media (min-width: 900px) { .mobile-menu { display: none; } }

.mobile-menu-theme { display: flex; flex-direction: column; gap: var(--space-sm); }
.mobile-menu-theme .theme-switcher {
  align-self: flex-start;
  padding: 8px;
  gap: 10px;
}
.mobile-menu-theme .theme-swatch { width: 30px; height: 30px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  overflow: hidden;
  padding-top: 160px;
  isolation: isolate;
}

.hero-promo-slot {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  padding-block: var(--space-lg) var(--space-xl);
}
.hero-promo-slot .container { width: 100%; }

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--bg);
}
.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
  background: var(--accent-gradient);
  transition: opacity var(--dur-slow);
  will-change: transform;
}
.hero-glow.g1 { width: 620px; height: 620px; top: -220px; right: -160px; }
.hero-glow.g2 { width: 420px; height: 420px; bottom: -160px; left: -120px; opacity: 0.3; }

.hero-lines {
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(-7deg, transparent 0 68px, var(--border) 68px 69px);
  mask-image: linear-gradient(to bottom, transparent, black 30%, black 70%, transparent);
  opacity: 0.6;
}

.hero-grid {
  display: grid;
  gap: var(--space-lg);
  align-items: start;
}
@media (min-width: 960px) {
  .hero-grid { grid-template-columns: 1.1fr 0.9fr; }
}

.hero-title {
  font-size: clamp(40px, 7.2vw, 88px);
  line-height: 0.98;
  text-transform: uppercase;
  margin-block: var(--space-sm);
}
.hero-title .accent-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-copy {
  max-width: 52ch;
  color: var(--text-muted);
  font-size: clamp(16px, 1.8vw, 19px);
  margin-bottom: var(--space-lg);
}

.hero-ctas { display: flex; flex-wrap: wrap; gap: var(--space-sm); }

.hero-visual {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(160deg, var(--surface), var(--surface-2));
  overflow: hidden;
}
.hero-visual::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--accent-gradient);
  opacity: 0.12;
}
.hero-visual .ring {
  position: absolute;
  border: 1.5px dashed var(--border);
  border-radius: 50%;
  animation: spin 22s linear infinite;
}
.hero-visual .ring.r1 { width: 78%; height: 78%; top: 11%; left: 11%; }
.hero-visual .ring.r2 { width: 96%; height: 96%; top: 2%; left: 2%; animation-direction: reverse; animation-duration: 34s; }
@keyframes spin { to { transform: rotate(360deg); } }

.hero-feature {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: var(--space-md);
}
.hero-feature-badge {
  align-self: flex-start;
  background: var(--accent);
  color: var(--on-accent);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: var(--space-sm);
}
.hero-feature-media {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  overflow: hidden;
  border-radius: var(--radius-md);
}
.hero-feature-media svg { width: 46%; height: 46%; color: var(--accent); }
.hero-feature-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-feature-body { margin-top: var(--space-sm); }
.hero-feature-cat {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.hero-feature-name {
  font-size: clamp(19px, 2.2vw, 23px);
  text-transform: uppercase;
  margin-block: 6px 8px;
}
.hero-feature-desc {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: var(--space-md);
}

/* On mobile/tablet the fixed 4:5 box crushed the product image once the
   text was stacked in one column — let the card grow and give the image a
   dependable height instead. */
@media (max-width: 959px) {
  .hero-visual { aspect-ratio: auto; }
  .hero-feature-media { flex: none; height: 300px; }
}

.scroll-cue {
  position: absolute;
  bottom: var(--space-lg);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.scroll-cue .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: bob 1.8s var(--ease-in-out) infinite;
}
@keyframes bob { 0%,100% { transform: translateY(0); opacity: 1; } 50% { transform: translateY(10px); opacity: 0.4; } }

/* ---------- Scroll band ---------- */
.scroll-band {
  height: 56px;
  border-block: 1px solid var(--border);
  background-image: var(--accent-gradient);
  background-size: 300% 100%;
  background-position: 0% 0%;
  background-repeat: no-repeat;
  transition: background-color var(--dur-slow) var(--ease-in-out);
}

/* ---------- Reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Promo slideshow ---------- */
.promo-shell { position: relative; }

.promo-slideshow {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
}
@media (max-width: 640px) { .promo-slideshow { aspect-ratio: 4 / 5; } }

.promo-slides { position: relative; width: 100%; height: 100%; isolation: isolate; }
.promo-slide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  background: linear-gradient(150deg, var(--surface-2), var(--bg-elevated));
  opacity: 0;
  transition: opacity 0.6s var(--ease-in-out);
  pointer-events: none;
  /* Pin each slide to its own stable GPU layer so the crossfade doesn't churn
     compositing layers — that layer churn caused screen-wide flicker on mobile. */
  transform: translateZ(0);
  backface-visibility: hidden;
  will-change: opacity;
}
.promo-slide.is-active { opacity: 1; pointer-events: auto; }
.promo-slide::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--accent-gradient);
  opacity: 0.14;
}
.promo-slide-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  z-index: 0;
  transform: translateZ(0);
  backface-visibility: hidden;
}
.promo-slide.has-photo::before { display: none; }
.promo-slide.has-photo::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0) 45%, rgba(0, 0, 0, 0.65) 100%);
  z-index: 1;
}
.promo-slide-icon {
  position: relative;
  width: 88px;
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--accent);
}
.promo-slide-icon svg { width: 40px; height: 40px; }
.promo-slide-caption {
  position: relative;
  z-index: 2;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(18px, 2.4vw, 26px);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--text);
}
.promo-slide.has-photo {
  justify-content: flex-start;
  align-items: flex-start;
  padding: var(--space-lg);
}
.promo-slide.has-photo .promo-slide-caption {
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
}

.promo-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: color-mix(in srgb, var(--bg) 55%, transparent);
  border: 1px solid var(--border);
  color: var(--text);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background var(--dur-fast), color var(--dur-fast), transform var(--dur-fast) var(--ease-out), border-color var(--dur-fast);
  z-index: 2;
  transform: translateY(-50%) translateZ(0);
}
.promo-arrow:hover { background: var(--accent); color: var(--on-accent); border-color: transparent; transform: translateY(-50%) scale(1.08); }
.promo-arrow svg { width: 20px; height: 20px; }
.promo-arrow-prev { left: var(--space-md); }
.promo-arrow-next { right: var(--space-md); }

/* Mobile flicker fix: on Chromium-based mobile browsers, elements with
   backdrop-filter re-rasterise a large screen region every frame while the
   slideshow crossfades behind them, which reads as a screen-wide flicker.
   Drop the blur on phones and use solid backgrounds instead — visually
   near-identical at this size, but no re-sampling means no flicker. */
@media (max-width: 768px) {
  .site-header.is-scrolled {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: var(--bg);
  }
  .promo-arrow {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: color-mix(in srgb, var(--bg) 82%, transparent);
  }
}

.promo-dots {
  position: absolute;
  bottom: var(--space-md);
  left: var(--space-md);
  display: flex;
  gap: 8px;
  z-index: 2;
}
.promo-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  border: none;
  padding: 0;
  transition: background var(--dur-fast), transform var(--dur-fast) var(--ease-out);
}
.promo-dot.is-active { background: var(--accent); transform: scale(1.3); }

.promo-info-box {
  position: absolute;
  right: var(--space-lg);
  bottom: -28px;
  max-width: 280px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  box-shadow: 0 20px 44px -18px rgba(0, 0, 0, 0.45);
  z-index: 3;
  transition: opacity 0.2s var(--ease-out);
}
.promo-info-eyebrow {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 6px;
}
.promo-info-text { font-size: 14px; color: var(--text-muted); white-space: pre-line; }

@media (max-width: 640px) {
  .promo-info-box { right: var(--space-sm); left: var(--space-sm); max-width: none; bottom: -24px; }
  .promo-dots { top: var(--space-sm); bottom: auto; left: var(--space-sm); }
}

/* ---------- Categories ---------- */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: var(--space-md);
  margin-top: var(--space-xl);
}
.category-card {
  position: relative;
  padding: var(--space-lg) var(--space-md);
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: transform var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out);
}
.category-card::before {
  content: '';
  position: absolute; inset: 0;
  background: var(--accent-gradient);
  opacity: 0;
  transition: opacity var(--dur-base) var(--ease-out);
}
.category-card:hover {
  transform: translateY(-6px);
  border-color: transparent;
  box-shadow: 0 20px 40px -20px var(--glow);
}
.category-card:hover::before { opacity: 0.1; }
.category-icon {
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  color: var(--accent);
  margin-bottom: var(--space-md);
  position: relative;
}
.category-icon svg { width: 28px; height: 28px; }
.category-card h3 { font-size: 20px; text-transform: uppercase; margin-bottom: 8px; position: relative; }
.category-card p { color: var(--text-muted); font-size: 14px; position: relative; margin-bottom: var(--space-sm); }
.category-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}
.category-link svg { width: 14px; height: 14px; transition: transform var(--dur-fast) var(--ease-out); }
.category-card:hover .category-link svg { transform: translateX(4px); }

.category-more {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: var(--space-sm);
  border-style: dashed;
}
.category-more-icon {
  position: relative;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--accent-gradient);
  color: var(--on-accent);
  transition: transform var(--dur-base) var(--ease-out);
}
.category-more-icon svg { width: 20px; height: 20px; transition: transform var(--dur-fast) var(--ease-out); }
.category-more:hover .category-more-icon { transform: scale(1.08); }
.category-more:hover .category-more-icon svg { transform: translateX(3px); }
.category-more-label {
  position: relative;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text);
}

/* ---------- Story / split ---------- */
.split {
  display: grid;
  gap: var(--space-xl);
  align-items: center;
}
@media (min-width: 960px) { .split { grid-template-columns: 1fr 1fr; } }
.split.reverse .split-media { order: 2; }
.split-media {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: linear-gradient(150deg, var(--surface), var(--surface-2));
  position: relative;
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.split-media svg { width: 40%; height: 40%; color: var(--accent); opacity: 0.9; }
.split-media img { width: 100%; height: 100%; object-fit: cover; }
.split-media::after {
  content: '';
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(-7deg, transparent 0 30px, var(--border) 30px 31px);
  opacity: 0.5;
}
.story-list { display: flex; flex-direction: column; gap: var(--space-md); margin-top: var(--space-lg); }
.story-item { display: flex; gap: var(--space-sm); }
.story-item .num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  color: var(--accent);
  min-width: 34px;
}
.story-item h4 { font-size: 17px; text-transform: uppercase; margin-bottom: 4px; }
.story-item p { color: var(--text-muted); font-size: 14.5px; }

/* ---------- Racing / events ---------- */
.events-section { background: var(--bg-elevated); border-block: 1px solid var(--border); }
.events-list { display: flex; flex-direction: column; gap: var(--space-sm); margin-top: var(--space-xl); }
.event-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: var(--space-sm);
  align-items: center;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  transition: border-color var(--dur-base), transform var(--dur-base) var(--ease-out);
}
.event-row:hover { border-color: var(--accent); transform: translateX(4px); }
@media (min-width: 720px) {
  .event-row { grid-template-columns: 120px 1fr auto; padding: var(--space-md); }
}
.event-date {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--accent);
  font-size: 13px;
  line-height: 1.25;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.event-name { font-size: 15px; line-height: 1.2; text-transform: uppercase; margin-bottom: 2px; }
.event-loc { color: var(--text-muted); font-size: 13px; }
@media (min-width: 720px) {
  .event-date { font-size: 15px; }
  .event-name { font-size: 18px; }
  .event-loc { font-size: 13.5px; }
}
/* Tighten spacing on phones so the event name keeps as much width as possible */
@media (max-width: 719px) {
  .event-row { gap: 10px; padding-inline: var(--space-sm); }
  .event-details.btn-sm { min-height: 36px; padding: 0 13px; font-size: 12.5px; }
}

/* Scale colour-coding: data-scale="8" (darker), "10" (lighter), "x" keeps the plain surface background */
.event-row[data-scale="8"] {
  border-left: 4px solid var(--scale-8);
  background: color-mix(in srgb, var(--scale-8) 12%, var(--surface));
}
.event-row[data-scale="10"] {
  border-left: 4px solid var(--scale-10);
  background: color-mix(in srgb, var(--scale-10) 12%, var(--surface));
}


/* ---------- Newsletter ---------- */
.newsletter-card {
  border-radius: var(--radius-lg);
  padding: var(--space-xl) var(--space-lg);
  background: linear-gradient(135deg, var(--surface), var(--surface-2));
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  text-align: center;
}
.newsletter-card::before {
  content: '';
  position: absolute;
  width: 400px; height: 400px;
  background: var(--accent-gradient);
  filter: blur(100px);
  opacity: 0.25;
  top: -140px; left: 50%;
  transform: translateX(-50%);
}
.newsletter-card > * { position: relative; }
.newsletter-form {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  justify-content: center;
  max-width: 460px;
  margin: var(--space-md) auto 0;
}
.newsletter-form input[type="email"] {
  flex: 1 1 240px;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 15px;
  font-family: var(--font-body);
}
.newsletter-form input[type="email"]::placeholder { color: var(--text-muted); }
.form-msg { margin-top: var(--space-sm); font-size: 14px; min-height: 20px; }
.form-msg.success { color: var(--accent-2); }
.form-msg.error { color: #ff6b6b; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding-block: var(--space-xl) var(--space-lg);
}
.footer-top {
  display: grid;
  gap: var(--space-xl);
  padding-bottom: var(--space-xl);
}
@media (min-width: 780px) {
  .footer-top { grid-template-columns: 1.3fr repeat(3, 1fr); }
}
.footer-brand p { color: var(--text-muted); font-size: 14px; margin-top: var(--space-sm); max-width: 32ch; }
.footer-socials { display: flex; gap: 10px; margin-top: var(--space-md); }
.social-btn {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--border);
  transition: border-color var(--dur-fast), color var(--dur-fast), transform var(--dur-fast) var(--ease-out);
}
.social-btn svg { width: 18px; height: 18px; }
.social-btn:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.footer-heading {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
  color: var(--text-muted);
}
.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links a { font-size: 14.5px; opacity: 0.9; transition: opacity var(--dur-fast); }
.footer-links a:hover { opacity: 1; color: var(--accent); }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: var(--space-sm);
  align-items: center; justify-content: space-between;
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-muted);
}
.back-to-top {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-display); font-weight: 700; font-size: 13px;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-muted);
  transition: color var(--dur-fast);
}
.back-to-top:hover { color: var(--accent); }
.back-to-top svg { width: 14px; height: 14px; }

/* Utility */
.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
