:root {
  --bg: #fbfbf8;
  --surface: #ffffff;
  --ink: #07090a;
  --muted: #545b58;
  --line: rgba(7, 9, 10, 0.1);
  --line-strong: rgba(7, 9, 10, 0.16);
  --green: #0aaa2f;
  --green-bright: #19c53d;
  --green-soft: #ecfaef;
  --blue: #1478ff;
  --purple: #7c2bd6;
  --dark: #080d0b;
  --dark-soft: #101613;
  --shadow: 0 18px 50px rgba(7, 9, 10, 0.09);
  --max-width: 1410px;
  --radius: 10px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Instrument Sans", Arial, sans-serif;
  background: var(--bg);
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

.site-header,
.landing-shell {
  width: min(var(--max-width), calc(100% - 1.25rem));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1.5rem;
  min-height: 60px;
  padding: 0.55rem 1rem;
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 10px 10px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 24px rgba(7, 9, 10, 0.06);
  backdrop-filter: blur(14px);
}

.brand,
.site-header__actions,
.site-nav,
.proof-row,
.race-meta,
.hero-card__foot,
.access-band ul {
  display: flex;
  align-items: center;
}

.brand {
  gap: 0.75rem;
  font-weight: 900;
  letter-spacing: 0;
  white-space: nowrap;
}

.brand__flag {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 10px);
  grid-template-rows: repeat(3, 10px);
  gap: 2px;
  width: 34px;
  height: 34px;
  transform: rotate(2deg);
}

.brand__flag i {
  display: block;
  background: var(--green);
}

.brand__flag i:nth-child(1) {
  grid-column: 2;
  grid-row: 1;
}

.brand__flag i:nth-child(2) {
  grid-column: 1;
  grid-row: 2;
}

.brand__flag i:nth-child(3) {
  grid-column: 3;
  grid-row: 2;
}

.brand__flag i:nth-child(4) {
  grid-column: 2;
  grid-row: 3;
}

.brand__flag i:nth-child(5) {
  grid-column: 1;
  grid-row: 3;
}

.brand__name {
  font-size: 1.55rem;
  line-height: 1;
}

.brand__name strong {
  color: var(--green);
}

.site-nav {
  justify-content: center;
  gap: clamp(1.5rem, 4vw, 4rem);
  font-size: 0.95rem;
  font-weight: 800;
}

.site-header__actions {
  gap: 1.5rem;
}

.login-link {
  font-weight: 800;
  font-size: 0.95rem;
}

.site-header__cta,
.access-band__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 1.35rem;
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-weight: 900;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.16);
}

.landing-shell {
  padding: 1rem 0 0;
}

.hero-section {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(520px, 1fr);
  gap: clamp(1.5rem, 5vw, 5.2rem);
  align-items: start;
}

.hero-copy {
  padding: 2rem 0 0;
}

.hero-copy h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(3rem, 4.8vw, 4.65rem);
  line-height: 1.02;
  letter-spacing: 0;
  font-weight: 900;
}

.hero-swoosh {
  width: min(530px, 86%);
  height: 8px;
  margin: 0.25rem 0 1.35rem;
  border-radius: 999px;
  background: var(--green);
  transform: rotate(-2deg);
  transform-origin: left center;
}

.hero-copy p {
  max-width: 610px;
  margin: 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.55;
}

.series-switcher {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: min(600px, 100%);
  margin-top: 1.6rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}

.series-pill {
  position: relative;
  appearance: none;
  min-height: 54px;
  border: 0;
  border-right: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 900;
  text-transform: uppercase;
  cursor: pointer;
}

.series-pill:last-child {
  border-right: 0;
}

.series-pill::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 18px;
  margin-right: 0.55rem;
  vertical-align: -4px;
  border-radius: 5px;
  border: 3px solid currentColor;
}

.series-pill[aria-selected="true"] {
  color: var(--green);
}

.series-pill[aria-selected="true"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  background: var(--green);
}

.series-pill:nth-child(2) {
  color: var(--blue);
}

.series-pill:nth-child(2)[aria-selected="true"]::after {
  background: var(--blue);
}

.series-pill:nth-child(3) {
  color: var(--purple);
}

.series-pill:nth-child(3)[aria-selected="true"]::after {
  background: var(--purple);
}

.proof-row {
  justify-content: space-between;
  gap: 1rem;
  width: min(620px, 100%);
  margin-top: 1.45rem;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.25;
}

.proof-row span {
  position: relative;
  max-width: 12rem;
  padding-left: 1.8rem;
}

.proof-row span::before,
.access-band li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.05rem;
  width: 17px;
  height: 17px;
  border: 2px solid var(--green);
  border-radius: 50%;
}

.proof-row span::after,
.access-band li::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 6px;
  width: 7px;
  height: 4px;
  border-left: 2px solid var(--green);
  border-bottom: 2px solid var(--green);
  transform: rotate(-45deg);
}

.hero-card {
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--shadow);
}

.hero-card__head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  padding: 1.05rem 1.35rem 0.85rem;
}

.track-mark {
  width: 78px;
  height: 56px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at center, white 0 16%, transparent 17%),
    conic-gradient(#ed3131 0 16%, #153d90 0 32%, #fff 0 36%, #153d90 0 54%, #ed3131 0 70%, #fff 0 74%, #153d90 0 100%);
}

.hero-card h2 {
  margin: 0;
  font-size: clamp(1.35rem, 2vw, 1.78rem);
  line-height: 1.05;
}

.hero-card__head p {
  margin: 0.25rem 0 0;
  color: var(--muted);
  font-weight: 700;
}

.contest-badge {
  min-width: 112px;
  padding: 0.85rem 0.95rem;
  border-radius: 8px;
  background: var(--green-soft);
  color: var(--green);
  text-align: center;
  font-size: 0.82rem;
  font-weight: 900;
}

.contest-badge span,
.contest-badge strong {
  display: block;
}

.race-meta {
  gap: 1.4rem;
  padding: 0 1.35rem 0.85rem;
  color: var(--muted);
  font-weight: 700;
}

.race-meta span {
  position: relative;
}

.race-meta span + span::before {
  content: "";
  position: absolute;
  left: -0.75rem;
  top: 0.1rem;
  width: 1px;
  height: 1rem;
  background: var(--line-strong);
}

.lineup-table {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.lineup-table__head,
.lineup-row {
  display: grid;
  grid-template-columns: 52px minmax(190px, 1fr) 74px 92px 92px 100px;
  align-items: center;
  gap: 0.75rem;
}

.lineup-table__head {
  min-height: 40px;
  padding: 0 1.35rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.73rem;
  font-weight: 900;
  text-transform: uppercase;
}

.lineup-row {
  min-height: 48px;
  padding: 0 1.35rem;
  border-bottom: 1px solid var(--line);
  font-weight: 800;
}

.lineup-row:last-child {
  border-bottom: 0;
}

.lineup-row__driver {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 0.75rem;
  align-items: center;
}

.driver-number {
  display: grid;
  place-items: center;
  width: 34px;
  height: 30px;
  border-radius: 7px;
  background: #eef0ee;
}

.driver-name {
  display: block;
  min-height: 9px;
  border-radius: 999px;
  background: #e4e6e7;
  font-size: 0;
}

.lineup-row__points {
  color: var(--green);
}

.hero-card__foot {
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.35rem;
  color: var(--muted);
  font-weight: 700;
}

.hero-card__foot a,
.feature-card a {
  color: var(--green);
  font-weight: 900;
}

.hero-card__foot a::after,
.feature-card a::after,
.access-band__cta::after {
  content: " ->";
}

.product-section {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(460px, 0.9fr);
  gap: 2rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.product-copy h2 {
  margin: 0 0 1.3rem;
  font-size: 1.45rem;
  line-height: 1.2;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.6rem;
}

.feature-card {
  min-height: 196px;
  padding: 1.15rem;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fff;
}

.feature-icon {
  width: 36px;
  height: 36px;
  margin-bottom: 1rem;
  color: var(--green);
  border: 4px solid var(--green);
  border-radius: 6px;
}

.feature-icon--rules {
  border-radius: 999px;
  height: 26px;
}

.feature-icon--signals {
  border: 0;
  display: grid;
  grid-template-columns: repeat(3, 7px);
  gap: 4px;
  align-items: end;
}

.feature-icon--signals::before,
.feature-icon--signals::after,
.feature-icon--signals {
  background: linear-gradient(var(--green), var(--green)) left bottom / 7px 12px no-repeat,
    linear-gradient(var(--green), var(--green)) center bottom / 7px 22px no-repeat,
    linear-gradient(var(--green), var(--green)) right bottom / 7px 31px no-repeat;
}

.feature-card h3 {
  margin: 0;
  font-size: 1.18rem;
}

.feature-card p {
  margin: 0.7rem 0 1.35rem;
  color: var(--muted);
  font-size: 0.93rem;
  line-height: 1.55;
}

.logic-panel {
  align-self: end;
  min-height: 264px;
  padding: 1.25rem;
  border-radius: 10px;
  background: var(--dark);
  color: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow);
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
}

.logic-panel__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.2rem;
  color: #70f07d;
  font-size: 0.88rem;
  font-weight: 900;
  text-transform: uppercase;
}

.logic-list {
  display: grid;
  gap: 0;
}

.logic-rule {
  display: grid;
  grid-template-columns: 36px 118px minmax(0, 1fr);
  gap: 0.9rem;
  align-items: baseline;
  min-height: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.84rem;
  line-height: 1.45;
}

.logic-rule__num {
  color: rgba(168, 255, 178, 0.72);
}

.logic-rule__key {
  color: #77f184;
  font-weight: 900;
  text-transform: uppercase;
}

.access-band {
  display: grid;
  grid-template-columns: auto minmax(280px, 1fr) auto auto;
  gap: 2rem;
  align-items: center;
  margin-top: 1rem;
  padding: 1.45rem 2.4rem;
  border-radius: 10px 10px 0 0;
  background: var(--dark);
  color: #fff;
}

.brand__flag--large {
  transform: scale(1.15) rotate(2deg);
}

.access-band h2 {
  margin: 0;
  font-size: 1.85rem;
  line-height: 1.15;
}

.access-band ul {
  gap: 2rem;
  margin: 0;
  padding: 0;
  list-style: none;
  color: rgba(255, 255, 255, 0.82);
}

.access-band li {
  position: relative;
  padding-left: 1.8rem;
  white-space: nowrap;
}

.access-band__cta {
  min-width: 240px;
  min-height: 56px;
  font-size: 1.05rem;
}

[hidden] {
  display: none !important;
}

@media (max-width: 1120px) {
  .site-nav {
    display: none;
  }

  .site-header {
    grid-template-columns: auto auto;
  }

  .hero-section,
  .product-section,
  .access-band {
    grid-template-columns: 1fr;
  }

  .feature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .site-header,
  .landing-shell {
    width: calc(100% - 1rem);
  }

  .site-header {
    border-radius: 0 0 10px 10px;
    gap: 0.75rem;
  }

  .brand__name {
    font-size: 1rem;
  }

  .login-link {
    display: none;
  }

  .site-header__cta {
    min-height: 38px;
    padding: 0 0.75rem;
    font-size: 0.82rem;
  }

  .landing-shell {
    padding-top: 1rem;
  }

  .hero-copy {
    padding-top: 1rem;
  }

  .hero-copy h1 {
    font-size: clamp(2.7rem, 12.5vw, 4rem);
  }

  .series-switcher,
  .feature-grid {
    grid-template-columns: 1fr;
  }

  .proof-row {
    display: grid;
    grid-template-columns: 1fr;
  }

  .hero-card {
    overflow-x: auto;
  }

  .hero-card__head {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .contest-badge {
    grid-column: 1 / -1;
    width: fit-content;
  }

  .race-meta {
    display: grid;
    gap: 0.55rem;
  }

  .race-meta span + span::before {
    display: none;
  }

  .lineup-table {
    min-width: 760px;
  }

  .hero-card__foot,
  .access-band ul {
    align-items: start;
    flex-direction: column;
  }

  .product-section {
    margin-top: 2rem;
  }

  .logic-rule {
    grid-template-columns: 28px 92px minmax(0, 1fr);
    font-size: 0.76rem;
  }

  .access-band {
    padding: 1.25rem;
    gap: 1rem;
  }

  .access-band__cta {
    width: 100%;
  }
}
