.hero,
.page-hero {
  position: relative;
  overflow: hidden;
  background: var(--black);
  color: #fff;
}

.hero-home {
  min-height: 640px;
  display: grid;
  align-items: center;
}

.hero-slider,
.hero-slide,
.hero-slider::after {
  position: absolute;
  inset: 0;
}

.hero-slider {
  overflow: hidden;
}

.hero-slider::after {
  content: "";
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.58) 46%, rgba(0, 0, 0, 0.22)),
    linear-gradient(180deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.44));
  z-index: 2;
}

.hero-slide {
  background: var(--hero-image) center / cover no-repeat;
  opacity: 0;
  transform: scale(1.03);
  transition: opacity 1.1s ease, transform 7s ease;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1.08);
}

.hero-home::after {
  content: none;
  position: absolute;
  z-index: 3;
  inset: auto 0 0;
  height: 8px;
  background: var(--yellow);
}

.hero-content {
  position: relative;
  z-index: 4;
  display: grid;
  grid-template-columns: minmax(0, 760px) minmax(280px, 360px);
  gap: 42px;
  align-items: end;
  padding: 92px 0 76px;
}

.hero-copy {
  max-width: 780px;
}

.hero-lead,
.page-hero p {
  max-width: 720px;
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.86);
}

.page-hero {
  --page-hero-image: url("../img/hero-real-paddock-lineup-2026.webp");
  --page-hero-position: center;
  padding: 96px 0 76px;
  background-image:
    linear-gradient(105deg, rgba(8, 8, 8, 0.9), rgba(8, 8, 8, 0.66) 54%, rgba(255, 212, 41, 0.2)),
    var(--page-hero-image);
  background-position: center, var(--page-hero-position);
  background-size: auto, cover;
  background-repeat: no-repeat;
}

.route-public-sale-rental .page-hero,
.route-public-sale-rental-submit .page-hero,
.route-members-announcement-new .page-hero,
.route-members-announcement-edit .page-hero,
.route-announcement-member-required .page-hero {
  --page-hero-image: url("../img/hero-real-dijon-pack-2026.webp");
  --page-hero-position: center 46%;
}

.route-members-dashboard .page-hero,
.route-members-login .page-hero,
.route-members-register .page-hero,
.route-members-profile .page-hero,
.route-members-onboarding .page-hero,
.route-members-forgot-password .page-hero,
.route-members-reset-password .page-hero,
.route-members-activate-account .page-hero {
  --page-hero-image: url("../img/hero-real-paddock-lineup-2026.webp");
  --page-hero-position: center 48%;
}

.route-members-race-entries-new .page-hero,
.route-members-race-entry-edit .page-hero {
  --page-hero-image: url("../img/hero-real-race-pack-2026.webp");
  --page-hero-position: center 52%;
}

.route-public-prepare-season .page-hero {
  --page-hero-image: url("../img/hero-real-race-pack-2026.webp");
  --page-hero-position: center 52%;
}

.route-members-parts-quote-new .page-hero,
.route-members-parts-quote-detail .page-hero,
.route-members-parts-quote-edit .page-hero,
.route-members-parts-quote-archives .page-hero {
  --page-hero-image: url("../img/hero-real-corner-pack-2026.webp");
  --page-hero-position: center;
}

.route-public-contact .page-hero {
  --page-hero-image: url("../img/hero-real-paddock-lineup-2026.webp");
  --page-hero-position: center 45%;
}

.route-public-infos .page-hero,
.route-public-legal .page-hero,
.route-error .page-hero {
  --page-hero-image: url("../img/hero-real-track-duel-2026.webp");
  --page-hero-position: center;
}

.route-public-merch .page-hero {
  --page-hero-image: url("../img/hero-real-corner-pack-2026.webp");
  --page-hero-position: center;
}

.page-hero-404 {
  min-height: min(78vh, 760px);
  display: grid;
  align-items: start;
  padding-top: clamp(42px, 7vh, 76px);
  padding-bottom: clamp(150px, 20vh, 220px);
}

.page-hero-404::before,
.page-hero-video {
  position: absolute;
  inset: 0;
}

.page-hero-404::before {
  content: "";
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(102deg, rgba(0, 19, 38, 0.68), rgba(0, 19, 38, 0.42) 32%, rgba(0, 80, 179, 0.16) 58%, rgba(255, 75, 75, 0.05)),
    linear-gradient(180deg, rgba(0, 19, 38, 0.04), rgba(0, 19, 38, 0.24));
}

.page-hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 1;
}

.page-hero-404 > .container {
  max-width: 820px;
  margin-left: max(20px, calc((100vw - 1160px) / 2));
}

.error-return {
  padding: 18px 0 22px;
  background: #001326;
  border-top: 3px solid #ffd700;
}

.error-return .container {
  display: flex;
  justify-content: flex-start;
}

.page-hero::after {
  content: none;
  position: absolute;
  inset: auto 0 0;
  height: 8px;
  background: var(--yellow);
  z-index: 3;
}

.page-hero > .container {
  position: relative;
  z-index: 4;
  isolation: isolate;
}

.hero-content,
.challenge-hero-content,
.result-hero-grid,
.page-hero > .container {
  isolation: isolate;
}

.hero-content::before,
.challenge-hero-content::before,
.result-hero-grid::before,
.page-hero > .container::before {
  content: none;
}

.hero-copy h1,
.challenge-hero-content h1,
.result-hero-copy h1,
.page-hero h1 {
  text-shadow: 0 14px 42px rgba(0, 0, 0, 0.34);
}

.challenge-hero {
  min-height: 560px;
  display: grid;
  align-items: center;
  padding: 0;
  background: #111;
}

.challenge-hero::before,
.challenge-hero::after,
.challenge-hero-media,
.challenge-hero-slide {
  position: absolute;
  inset: 0;
}

.challenge-hero::before {
  content: "";
  z-index: 2;
  background:
    linear-gradient(90deg, rgba(8, 8, 8, 0.72), rgba(8, 8, 8, 0.42) 48%, rgba(255, 212, 41, 0.2)),
    linear-gradient(180deg, rgba(8, 8, 8, 0.16), rgba(8, 8, 8, 0.6));
}

.challenge-hero::after {
  content: none;
  z-index: 3;
  top: auto;
  height: 8px;
  background: var(--yellow);
}

.challenge-hero-media {
  overflow: hidden;
}

.challenge-hero-slide {
  background: var(--hero-image) center / cover no-repeat;
  opacity: 0;
  transform: scale(1.03);
  transition: opacity 1.1s ease, transform 7s ease;
}

.challenge-hero-slide.is-active {
  opacity: 1;
  transform: scale(1.08);
}

.challenge-hero-content {
  position: relative;
  z-index: 4;
  padding: 96px 0 76px;
}

.challenge-hero-content h1 {
  max-width: 940px;
}

.challenge-hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  max-width: 840px;
  margin-top: 34px;
}

.challenge-hero-stats span {
  min-height: 102px;
  padding: 18px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.92);
  color: var(--black);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.14);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.challenge-hero-stats .stat-icon {
  width: 28px;
  height: 28px;
  margin-bottom: 12px;
  color: var(--yellow-dark);
}

.challenge-hero-stats span:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 52px rgba(0, 0, 0, 0.2);
}

.challenge-hero-stats span:hover .stat-icon {
  animation: iconKick 0.42s ease;
}

.challenge-hero-stats strong,
.challenge-hero-stats small {
  display: block;
}

.challenge-hero-stats strong {
  font-family: "Changa One", Impact, sans-serif;
  font-size: 2.15rem;
  line-height: 1;
}

.challenge-hero-stats small {
  margin-top: 8px;
  color: var(--muted);
  font-weight: 900;
  text-transform: uppercase;
}

.result-hero {
  min-height: 540px;
  display: grid;
  align-items: center;
  padding: 0;
  background: #121212;
}

.result-hero::before,
.result-hero::after,
.result-hero-media {
  position: absolute;
  inset: 0;
}

.result-hero::before {
  content: "";
  z-index: 2;
  background:
    linear-gradient(90deg, rgba(8, 8, 8, 0.78), rgba(8, 8, 8, 0.38) 55%, rgba(255, 212, 41, 0.24)),
    linear-gradient(180deg, rgba(8, 8, 8, 0.08), rgba(8, 8, 8, 0.64));
}

.result-hero::after {
  content: none;
  z-index: 3;
  top: auto;
  height: 8px;
  background: var(--yellow);
}

.result-hero-media {
  background: url("../img/hero-real-dijon-pack-2026.webp") center / cover no-repeat;
  transform: scale(1.02);
  animation: heroPhotoZoom 14s ease-in-out infinite alternate;
}

.result-hero-grid {
  position: relative;
  z-index: 4;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(340px, 0.75fr);
  gap: 54px;
  align-items: center;
  padding: 92px 0 72px;
}

.result-hero-copy h1 {
  max-width: 760px;
}

.result-visual {
  position: relative;
  display: grid;
  gap: 16px;
  justify-items: end;
}

.result-board-stack {
  position: relative;
  width: min(100%, 460px);
}

.result-board {
  width: 100%;
  padding: 18px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  color: var(--black);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 24px 58px rgba(0, 0, 0, 0.26);
  opacity: 0;
  visibility: hidden;
  position: absolute;
  inset: 0;
  pointer-events: none;
  transform: translateY(12px) rotate(-1deg) scale(0.98);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.result-board.is-active {
  position: relative;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) rotate(-1deg) scale(1);
  animation: resultFloat 5s ease-in-out infinite;
}

.result-board-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  padding: 4px 2px 14px;
  border-bottom: 2px solid var(--black);
  font-weight: 900;
  text-transform: uppercase;
}

.result-board-head strong {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 62px;
  min-height: 36px;
  border-radius: var(--radius);
  background: var(--yellow);
}

.result-row {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 12px;
  align-items: center;
  margin-top: 10px;
  padding: 12px;
  border-radius: var(--radius);
  background: var(--surface-soft);
  transform-origin: left center;
  animation: resultRowIn 0.7s ease both;
}

.result-row:nth-child(3) {
  animation-delay: 0.12s;
}

.result-row:nth-child(4) {
  animation-delay: 0.24s;
}

.result-row span {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--black);
  color: #fff;
  font-weight: 900;
}

.result-row.is-first span {
  background: var(--yellow);
  color: var(--black);
}

.result-row strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.result-row em {
  color: var(--red);
  font-style: normal;
  font-weight: 900;
}

.result-progress {
  height: 8px;
  margin-top: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: #dedbd0;
}

.result-progress span {
  display: block;
  width: 68%;
  height: 100%;
  border-radius: inherit;
  background: var(--yellow);
  animation: resultProgress 2.4s ease-in-out infinite alternate;
}

.result-badge {
  width: min(100%, 310px);
  padding: 16px 18px;
  border-radius: var(--radius);
  background: var(--yellow);
  color: var(--black);
  box-shadow: 0 18px 42px rgba(255, 212, 41, 0.24);
  animation: resultBadge 4.8s ease-in-out infinite;
}

.result-badge strong,
.result-badge span {
  display: block;
}

.result-badge span {
  color: rgba(8, 8, 8, 0.68);
  font-weight: 800;
}
