/* ============ Self-hosted fonts (no external requests to Google) ============ */
@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 400;
  font-display: optional;
  src: url("/assets/fonts/barlow-400.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 500;
  font-display: optional;
  src: url("/assets/fonts/barlow-500.woff2") format("woff2");
}
@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 600;
  font-display: optional;
  src: url("/assets/fonts/barlow-600.woff2") format("woff2");
}
@font-face {
  font-family: "Rajdhani";
  font-style: normal;
  font-weight: 500;
  font-display: optional;
  src: url("/assets/fonts/rajdhani-500.woff2") format("woff2");
}
@font-face {
  font-family: "Rajdhani";
  font-style: normal;
  font-weight: 600;
  font-display: optional;
  src: url("/assets/fonts/rajdhani-600.woff2") format("woff2");
}
@font-face {
  font-family: "Rajdhani";
  font-style: normal;
  font-weight: 700;
  font-display: optional;
  src: url("/assets/fonts/rajdhani-700.woff2") format("woff2");
}


/* ============ Void Crown Racing — Design Tokens ============ */
:root {
  --c-bg: #0a0a0c;
  --c-bg-alt: #131316;
  --c-bg-card: #17171b;
  --c-steel: #9ea3a8;
  --c-steel-light: #d7d9db;
  --c-red: #c41e2a;
  --c-red-dark: #6e0f16;
  --c-red-bright: #e63946;
  --c-amber: #f2a33c;
  --c-text: #ececea;
  --c-text-muted: #9e9d9b;
  --c-border: rgba(255, 255, 255, 0.08);

  --font-display: "Rajdhani", sans-serif;
  --font-body: "Barlow", sans-serif;

  --container-w: 1180px;
  --radius: 6px;
}

/* ============ Reset ============ */
*, *::before, *::after { box-sizing: border-box; }
html { scrollbar-gutter: stable; }
html, body { margin: 0; padding: 0; }
body {
  background:
    repeating-linear-gradient(115deg, rgba(196, 30, 42, 0.05) 0px, rgba(196, 30, 42, 0.05) 2px, transparent 2px, transparent 40px),
    radial-gradient(ellipse 70% 40% at 50% 0%, rgba(196, 30, 42, 0.16), transparent 65%),
    var(--c-bg);
  background-attachment: fixed;
  color: var(--c-text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--c-steel-light);
  margin: 0 0 0.5em;
}
p { margin: 0 0 1em; color: var(--c-text-muted); }
.container {
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============ Buttons ============ */
.btn {
  position: relative;
  display: inline-block;
  overflow: hidden;
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.85em 2em;
  border-radius: var(--radius);
  border: 1px solid var(--c-red);
  transition: all 0.2s ease;
}
.btn::after {
  content: "";
  position: absolute;
  top: 0; left: -60%;
  width: 40%; height: 100%;
  background: linear-gradient(115deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg);
  transition: left 0.5s ease;
}
.btn:hover::after { left: 130%; }
.btn--primary {
  background: linear-gradient(135deg, var(--c-red), var(--c-red-dark));
  color: #fff;
  box-shadow: 0 0 0 rgba(196, 30, 42, 0);
}
.btn--primary:hover {
  box-shadow: 0 0 28px rgba(230, 57, 70, 0.6);
  transform: translateY(-2px);
}
.btn--ghost {
  background: transparent;
  color: var(--c-steel-light);
  border-color: var(--c-border);
}
.btn--ghost:hover {
  border-color: var(--c-red);
  color: #fff;
  box-shadow: 0 0 20px rgba(196, 30, 42, 0.3);
  transform: translateY(-2px);
}

/* ============ Header / Nav ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 12, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--c-border);
  transition: background 0.3s ease, backdrop-filter 0.3s ease;
}
.site-header.is-scrolled {
  background: rgba(6, 6, 7, 0.97);
  backdrop-filter: blur(14px);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  transition: height 0.3s ease;
}
.site-header.is-scrolled .site-header__inner { height: 58px; }
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand__logo {
  height: 48px;
  width: auto;
  transition: height 0.3s ease, filter 0.3s ease, transform 0.3s ease;
}
.site-header.is-scrolled .brand__logo { height: 36px; }
.brand:hover .brand__logo {
  filter: drop-shadow(0 0 14px rgba(196, 30, 42, 0.7));
  transform: scale(1.08);
}
.brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 1.15rem;
  color: var(--c-steel-light);
}
.brand__name em {
  font-style: normal;
  color: var(--c-red-bright);
}
.main-nav ul { display: flex; gap: 0.35rem; }
.main-nav a {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  color: var(--c-text-muted);
  padding: 0.6em 1.15em;
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
  background: transparent;
  transition: color 0.2s ease, background 0.25s ease;
}
.main-nav a:hover, .main-nav a.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--c-red), var(--c-red-dark));
}
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--c-steel-light);
}

/* ============ Hero ============ */
@keyframes crestBreathe {
  0%, 100% { transform: scale(0.985); filter: drop-shadow(0 0 22px rgba(196, 30, 42, 0.4)); }
  50% { transform: scale(1.015); filter: drop-shadow(0 0 34px rgba(196, 30, 42, 0.6)); }
}
.hero {
  position: relative;
  padding: 7rem 0 5rem;
  text-align: center;
  overflow: hidden;
  background: radial-gradient(ellipse 65% 55% at 50% 0%, rgba(196, 30, 42, 0.28), transparent 70%);
}
.hero--home {
  padding: 3rem 0 6.5rem;
}
.hero--home .container { position: relative; z-index: 2; }
.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.hero__video-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(ellipse 65% 55% at 50% 0%, rgba(196, 30, 42, 0.35), transparent 70%),
    linear-gradient(180deg, rgba(10, 10, 12, 0.55) 0%, rgba(10, 10, 12, 0.75) 55%, var(--c-bg) 96%);
}
@keyframes heroReveal {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
.hero__reveal {
  opacity: 0;
  animation: heroReveal 0.7s cubic-bezier(0.2, 0.7, 0.3, 1) forwards;
}

@keyframes tileReveal {
  0% {
    opacity: 0;
    transform: translateY(55px) scale(0.82);
    filter: blur(9px);
    box-shadow: 0 0 0 rgba(196, 30, 42, 0);
  }
  55% {
    opacity: 1;
    transform: translateY(-6px) scale(1.035);
    filter: blur(0);
    box-shadow: 0 0 36px rgba(196, 30, 42, 0.55);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
    box-shadow: 0 0 0 rgba(196, 30, 42, 0);
  }
}
.tile-reveal {
  opacity: 0;
}
.tile-reveal.is-visible {
  animation: tileReveal 0.85s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@media (prefers-reduced-motion: reduce) {
  .tile-reveal { opacity: 1; animation: none; }
}
.hero__crest-wrap {
  position: relative;
  width: fit-content;
  margin: 0 auto 1rem;
}
.hero__crest {
  position: relative;
  z-index: 1;
  display: block;
  height: clamp(280px, 38vw, 550px);
  width: auto;
  animation: crestBreathe 4s ease-in-out infinite;
}
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  color: #fff;
  max-width: 900px;
  margin-inline: auto;
  text-shadow: 0 0 30px rgba(196, 30, 42, 0.35);
}
.hero p.lead {
  max-width: 640px;
  margin: 1.2rem auto 2rem;
  font-size: 1.1rem;
}
.hero__actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ============ Sections ============ */
section { padding: 5rem 0; }
.section--alt { background: rgba(255, 255, 255, 0.025); }
.section__head { text-align: center; max-width: 700px; margin: 0 auto 3rem; }
.section__head .kicker {
  display: block;
  color: var(--c-red-bright);
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.12em;
  font-size: 0.85rem;
  margin-bottom: 0.6em;
}

/* ============ Grid / Cards ============ */
.grid {
  display: grid;
  gap: 1.75rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.grid--three { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 860px) {
  .grid--three { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .grid--three { grid-template-columns: 1fr; }
}
.grid--two { grid-template-columns: repeat(2, 1fr); gap: 2.25rem; }
@media (max-width: 720px) {
  .grid--two { grid-template-columns: 1fr; }
}
.card {
  background: var(--c-bg-card);
  border: 1px solid var(--c-border);
  border-top: 3px solid var(--c-red);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.card:hover {
  transform: translateY(-5px);
  border-top-color: var(--c-red-bright);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4), 0 0 24px rgba(196, 30, 42, 0.2);
}
.card h3 { color: #fff; font-size: 1.15rem; }

/* Member cards */
.member-card { text-align: center; padding: 0; overflow: hidden; }
.member-card__photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: top center;
  display: block;
  background: var(--c-bg-alt);
}
.member-card__body { padding: 1.5rem 1.25rem 1.75rem; }
.member-card h3 { margin-bottom: 0.2em; }
.member-card .roles {
  color: var(--c-red-bright);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* News cards */
.news-card { padding: 0; overflow: hidden; }
.news-card__image {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  display: block;
}
.news-card .date,
.news-card h3,
.news-card__excerpt,
.news-card__more {
  margin-left: 1.75rem;
  margin-right: 1.75rem;
}
.news-card .date { margin-top: 1.75rem; }
.news-card__more { margin-bottom: 1.75rem; }
.news-card .date {
  color: var(--c-red-bright);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
}
.news-card h3 { color: #fff; margin-top: 0.3em; }
.news-card__excerpt { color: var(--c-text-muted); }
.news-card__more {
  display: inline-block;
  margin-top: 0.5rem;
  color: var(--c-steel-light);
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  border-bottom: 1px solid var(--c-red);
}

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 3.5rem;
  flex-wrap: wrap;
}
.pagination__status {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--c-text-muted);
  font-size: 0.9rem;
}

/* Audience cards (Home) */
.audience-card { text-align: center; }

/* Icon badges — angled shield-cut, shared by audience + feature cards */
.icon-badge {
  --size: 64px;
  width: var(--size); height: var(--size);
  margin: 0 auto 1.25rem;
  background: linear-gradient(150deg, var(--c-red), var(--c-red-dark));
  clip-path: polygon(50% 0%, 100% 22%, 100% 78%, 50% 100%, 0% 78%, 0% 22%);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 0 rgba(230, 57, 70, 0);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}
.icon-badge svg { width: 55%; height: 55%; color: #fff; }
.icon-badge--sm { --size: 52px; }
.card:hover .icon-badge {
  box-shadow: 0 0 22px rgba(230, 57, 70, 0.55);
  transform: scale(1.08) rotate(3deg);
}

/* Sponsor grid */
.sponsor-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 2rem;
  align-items: center;
}
.sponsor-grid img {
  filter: grayscale(1) brightness(1.4);
  opacity: 0.75;
  transition: all 0.2s ease;
  margin: 0 auto;
}
.sponsor-grid img:hover { filter: none; opacity: 1; }

/* Partners — big, unboxed presentation */
.partners-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 4rem;
}
.partner-item { text-align: center; max-width: 420px; margin: 0 auto; }
.partner-item__logo-wrap {
  position: relative;
  width: fit-content;
  margin: 0 auto 1.75rem;
}
.partner-item__logo-wrap::before {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 75%;
  aspect-ratio: 1 / 1;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(196, 30, 42, 0.45), transparent 70%);
  filter: blur(20px);
  z-index: 0;
}
.partner-item__logo {
  position: relative;
  z-index: 1;
  max-height: 190px;
  width: auto;
  filter: drop-shadow(0 0 20px rgba(196, 30, 42, 0.4));
  transition: transform 0.25s ease, filter 0.25s ease;
}
.partner-item:hover .partner-item__logo {
  transform: scale(1.06);
  filter: drop-shadow(0 0 32px rgba(230, 57, 70, 0.65));
}

/* Countdown (Next Race) */
.countdown {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  margin: 2.5rem 0 0;
  flex-wrap: wrap;
}
.countdown__unit {
  background: var(--c-bg-card);
  border: 1px solid var(--c-border);
  border-top: 3px solid var(--c-red);
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
  min-width: 88px;
  text-align: center;
}
.countdown__value {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2.2rem;
  color: #fff;
  text-shadow: 0 0 20px rgba(196, 30, 42, 0.5);
  line-height: 1;
}
.countdown__label {
  display: block;
  margin-top: 0.4em;
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
  color: var(--c-text-muted);
}
.countdown__live {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.6rem;
  color: var(--c-red-bright);
  text-shadow: 0 0 20px rgba(230, 57, 70, 0.6);
}
.partner-item h3 {
  color: #fff;
  font-size: 1.5rem;
  margin-bottom: 0.6em;
}
.partner-item p { text-align: center; }
.sponsor-cta {
  text-align: center;
  margin-top: 3rem;
  padding: 3rem;
  border: 1px dashed var(--c-border);
  border-radius: var(--radius);
}

/* Article (single news page) */
.article {
  max-width: 760px;
  margin: 0 auto;
  padding: 4rem 24px;
}
.article .date {
  color: var(--c-red-bright);
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.05em;
}
.article h1 { margin-top: 0.4em; }
.article__body p { color: var(--c-text); }

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}
.contact-info h3 { color: #fff; }
.contact-info a { color: var(--c-red-bright); }
form.contact-form { display: grid; gap: 1rem; }
.contact-form label {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  color: var(--c-text-muted);
  margin-bottom: 0.4em;
}
.contact-form input,
.contact-form textarea {
  width: 100%;
  background: var(--c-bg-card);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 0.8em 1em;
  color: var(--c-text);
  font-family: var(--font-body);
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--c-red);
}

/* Placeholder / empty state */
.empty-state {
  text-align: center;
  padding: 3rem;
  border: 1px dashed var(--c-border);
  border-radius: var(--radius);
  color: var(--c-text-muted);
}

/* ============ Footer ============ */
.site-footer {
  background: #060607;
  border-top: 1px solid var(--c-border);
  padding-top: 2rem;
}
.site-footer__social ul {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  padding-bottom: 2rem;
}
.site-footer__social a {
  color: var(--c-text-muted);
  transition: color 0.2s ease;
}
.site-footer__social a:hover { color: var(--c-red-bright); }
.site-footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--c-border);
  padding: 1.5rem 24px;
  font-size: 0.85rem;
  color: var(--c-text-muted);
  flex-wrap: wrap;
  gap: 0.5rem;
}
.site-footer__bottom a { transition: color 0.2s ease; }
.site-footer__bottom a:hover { color: var(--c-red-bright); }

/* ============ Responsive ============ */
@media (max-width: 860px) {
  .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .main-nav {
    position: absolute;
    top: 76px; left: 0; right: 0;
    background: var(--c-bg-alt);
    border-bottom: 1px solid var(--c-border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }
  .main-nav.is-open { max-height: 420px; }
  .main-nav ul { flex-direction: column; gap: 0; padding: 1rem 24px; }
  .main-nav a { display: block; padding: 0.9em 0.25em; clip-path: none; border-bottom: 1px solid var(--c-border); }
  .hero { padding: 4rem 0 3rem; }
  section { padding: 3.5rem 0; }
}
