:root {
  --bg: #07080a;
  --bg-soft: #101216;
  --panel: #171a20;
  --panel-strong: #20242c;
  --line: rgba(255, 255, 255, 0.13);
  --text: #f6f7f9;
  --muted: #b8c0cc;
  --soft: #78818f;
  --red: #e21d2f;
  --red-dark: #9f1020;
  --steel: #7ea0b8;
  --gold: #d6a84f;
  --green: #7fb069;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
  --font-body: "Barlow", Arial, sans-serif;
  --font-display: "Rajdhani", "Barlow", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

body.menu-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

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

button {
  font: inherit;
}

.sr-only,
.skip-link {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link:focus {
  z-index: 10000;
  width: auto;
  height: auto;
  margin: 0;
  clip: auto;
  top: 1rem;
  left: 1rem;
  padding: 0.75rem 1rem;
  background: var(--text);
  color: var(--bg);
}

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1.25rem;
  min-height: 76px;
  padding: 0.8rem clamp(1rem, 3vw, 2.5rem);
  border-bottom: 1px solid transparent;
  transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.site-header.scrolled {
  background: rgba(7, 8, 10, 0.88);
  border-color: var(--line);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

.brand img {
  width: 150px;
  height: auto;
}

.site-nav {
  display: flex;
  justify-content: center;
  gap: clamp(0.75rem, 2vw, 1.75rem);
}

.site-nav a,
.header-cta,
.language-switch button {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0;
}

.site-nav a {
  position: relative;
  font-size: 0.9rem;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  transform: scaleX(0);
  transform-origin: center;
  background: var(--red);
  transition: transform 180ms ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--text);
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
}

.language-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-width: 88px;
  padding: 3px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.06);
}

.language-switch button {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.language-switch button.active {
  background: var(--text);
  color: var(--bg);
}

.header-cta {
  padding: 0 1rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
}

.header-cta:hover,
.header-cta:focus-visible {
  border-color: rgba(226, 29, 47, 0.7);
  color: var(--text);
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.6rem;
  cursor: pointer;
}

.menu-button span:not(.sr-only) {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--text);
}

.hero {
  position: relative;
  min-height: 92svh;
  display: flex;
  align-items: end;
  padding: 7.5rem clamp(1rem, 5vw, 5rem) clamp(2.5rem, 6vw, 5rem);
  isolation: isolate;
  overflow: hidden;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(7, 8, 10, 0.92) 0%, rgba(7, 8, 10, 0.68) 42%, rgba(7, 8, 10, 0.28) 100%),
    linear-gradient(180deg, rgba(7, 8, 10, 0.45) 0%, rgba(7, 8, 10, 0.8) 100%),
    url("../img/onyx_background_1.png") center / cover no-repeat;
  transform: scale(1.02);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  z-index: -1;
  height: 36%;
  background: linear-gradient(180deg, transparent, var(--bg));
}

.hero-content {
  width: min(860px, 100%);
}

.eyebrow {
  margin: 0 0 0.85rem;
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font-display);
  line-height: 0.98;
  letter-spacing: 0;
}

h1 {
  max-width: 780px;
  font-size: clamp(4.2rem, 12vw, 9rem);
  text-transform: uppercase;
}

h2 {
  font-size: clamp(2.4rem, 5vw, 4.8rem);
  max-width: 980px;
}

h3 {
  font-size: 1.45rem;
}

.hero-copy {
  width: min(660px, 100%);
  margin: 1.3rem 0 0;
  color: var(--muted);
  font-size: clamp(1.08rem, 2vw, 1.35rem);
}

.hero-actions,
.cta-band,
.hero-facts {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.9rem;
}

.hero-actions {
  margin-top: 2rem;
}

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.85rem 1.15rem;
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 800;
  text-transform: uppercase;
  cursor: pointer;
}

.button-icon {
  width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  color: currentColor;
  font-size: 1.1rem;
  line-height: 1;
}

.button.primary {
  background: linear-gradient(135deg, var(--red), var(--red-dark));
  border-color: transparent;
  box-shadow: 0 16px 32px rgba(226, 29, 47, 0.24);
}

.button.ghost {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.hero-facts {
  margin: 2.4rem 0 0;
  padding: 0;
}

.hero-facts div {
  min-width: 150px;
  padding: 0.85rem 1rem;
  border-left: 2px solid var(--red);
  background: rgba(255, 255, 255, 0.07);
}

.hero-facts div:nth-child(3) {
  border-left-color: var(--gold);
}

.hero-facts dt {
  color: var(--soft);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.hero-facts dd {
  margin: 0.1rem 0 0;
  font-size: 1.1rem;
  font-weight: 800;
}

.status-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-block: 1px solid var(--line);
  background: var(--bg-soft);
}

.status-strip > div {
  min-height: 86px;
  display: grid;
  align-content: center;
  gap: 0.2rem;
  padding: 1rem clamp(1rem, 4vw, 3rem);
  border-right: 1px solid var(--line);
}

.status-strip span {
  color: var(--soft);
  font-weight: 800;
  text-transform: uppercase;
}

.status-strip strong {
  font-size: clamp(1.1rem, 2vw, 1.5rem);
}

.copy-chip {
  width: fit-content;
  border: 1px solid rgba(126, 160, 184, 0.5);
  background: rgba(126, 160, 184, 0.12);
  color: var(--text);
  padding: 0.4rem 0.7rem;
  cursor: pointer;
  font-weight: 800;
}

.soon-trigger {
  position: relative;
}

.soon-trigger::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.16), transparent);
  transform: translateX(-100%);
  transition: transform 260ms ease, opacity 260ms ease;
  pointer-events: none;
}

.soon-trigger:hover::before,
.soon-trigger:focus-visible::before {
  opacity: 1;
  transform: translateX(100%);
}

.launch-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin: 0;
  padding: 0 clamp(1rem, 5vw, 5rem) clamp(1rem, 3vw, 2rem);
  background: linear-gradient(180deg, var(--bg), var(--bg-soft));
}

.launch-board > div {
  min-height: 112px;
  display: grid;
  align-content: center;
  gap: 0.35rem;
  padding: 1.2rem;
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025)),
    var(--panel);
}

.launch-board span {
  color: var(--soft);
  font-weight: 800;
  text-transform: uppercase;
}

.launch-board strong {
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 2.6vw, 2.2rem);
  line-height: 1;
}

.section {
  padding: clamp(4rem, 8vw, 7rem) clamp(1rem, 5vw, 5rem);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 2.1fr);
  gap: 2rem;
  align-items: start;
  margin-bottom: clamp(2rem, 5vw, 4rem);
}

.intro-grid,
.rules-grid,
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.intro-grid article,
.rules-grid article,
.stats-grid div,
.join-panel,
.steps li,
.paths > div {
  background: var(--panel);
}

.intro-grid article {
  min-height: 260px;
  padding: clamp(1.4rem, 3vw, 2rem);
}

.intro-grid article:first-child {
  grid-column: span 2;
}

.intro-grid p,
.faction-card p,
.steps p,
.rules-grid p,
.join-panel p,
.site-footer p {
  color: var(--muted);
  margin: 0.8rem 0 0;
}

.life {
  background: var(--bg-soft);
}

.faction-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.faction-card {
  min-height: 420px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
}

.faction-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  padding: 1.2rem;
  background: radial-gradient(circle, rgba(226, 29, 47, 0.18), rgba(255, 255, 255, 0.03) 58%, transparent 70%);
}

.faction-card div {
  padding: 1.2rem;
}

.paths {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin-top: 1rem;
  background: var(--line);
  border: 1px solid var(--line);
}

.paths > div {
  padding: 1.4rem;
}

.paths p {
  margin: 0.65rem 0 0;
  color: var(--muted);
}

.experience-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1rem;
}

.experience-row article {
  min-height: 210px;
  padding: 1.3rem;
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(226, 29, 47, 0.08), rgba(126, 160, 184, 0.055)),
    var(--panel);
}

.experience-row span {
  display: inline-flex;
  margin-bottom: 1rem;
  color: var(--gold);
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
}

.experience-row p {
  margin: 0.8rem 0 0;
  color: var(--muted);
}

.join-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(280px, 0.8fr);
  gap: 1rem;
  align-items: start;
}

.steps {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  margin: 0;
  padding: 0;
  background: var(--line);
  border: 1px solid var(--line);
  list-style: none;
}

.steps li {
  min-height: 235px;
  padding: 1.5rem;
}

.steps span {
  display: inline-block;
  margin-bottom: 1.5rem;
  color: var(--red);
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
}

.join-panel {
  position: sticky;
  top: 96px;
  padding: 1.5rem;
  border: 1px solid var(--line);
}

.join-panel a {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.75rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  font-weight: 800;
}

.panel-soon {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  min-height: 54px;
  margin-top: 0.75rem;
  padding: 0.75rem 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  font-weight: 800;
}

.panel-soon span {
  overflow-wrap: anywhere;
}

.panel-soon strong {
  color: var(--gold);
  font-size: 0.85rem;
  text-transform: uppercase;
}

.join-panel a::after {
  content: "^";
  color: var(--gold);
}

.rules {
  background:
    linear-gradient(180deg, rgba(7, 8, 10, 0.78), rgba(7, 8, 10, 0.98)),
    url("../img/onyx_background_1.png") center / cover fixed;
}

.rules-grid {
  grid-template-columns: repeat(4, 1fr);
}

.rules-grid article {
  min-height: 245px;
  padding: 1.5rem;
}

.community {
  background: var(--bg-soft);
}

.stats-grid div {
  min-height: 150px;
  display: grid;
  align-content: center;
  padding: 1.2rem;
}

.stats-grid strong {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.3vw, 3.5rem);
  line-height: 1;
}

.stats-grid span {
  margin-top: 0.4rem;
  color: var(--muted);
  font-weight: 800;
  text-transform: uppercase;
}

.cta-band {
  justify-content: space-between;
  margin-top: 1rem;
  padding: clamp(1.4rem, 4vw, 2.5rem);
  background: linear-gradient(135deg, rgba(226, 29, 47, 0.18), rgba(126, 160, 184, 0.12));
  border: 1px solid var(--line);
}

.cta-band h2 {
  max-width: 720px;
  font-size: clamp(2rem, 4vw, 3.5rem);
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(120px, 190px) minmax(0, 1fr) minmax(0, 1fr);
  gap: 1.5rem;
  align-items: center;
  padding: 2rem clamp(1rem, 5vw, 5rem);
  border-top: 1px solid var(--line);
  background: #050608;
}

.source-note {
  font-size: 0.9rem;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  z-index: 1100;
  transform: translate(-50%, 140%);
  padding: 0.85rem 1rem;
  background: var(--text);
  color: var(--bg);
  font-weight: 800;
  transition: transform 180ms ease;
}

.toast.show {
  transform: translate(-50%, 0);
}

@media (max-width: 1100px) {
  .site-header {
    grid-template-columns: auto auto 1fr;
  }

  .menu-button {
    display: block;
  }

  .site-nav {
    position: fixed;
    inset: 76px 0 auto 0;
    display: grid;
    justify-content: stretch;
    gap: 0;
    padding: 0.5rem 1rem 1rem;
    background: rgba(7, 8, 10, 0.96);
    border-bottom: 1px solid var(--line);
    transform: translateY(-130%);
    transition: transform 180ms ease;
    backdrop-filter: blur(18px);
  }

  .site-nav.open {
    transform: translateY(0);
  }

  .site-nav a {
    min-height: 52px;
    border-bottom: 1px solid var(--line);
  }

  .header-actions {
    justify-self: end;
  }

  .faction-grid,
  .rules-grid,
  .stats-grid,
  .launch-board,
  .experience-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 820px) {
  .site-header {
    gap: 0.75rem;
  }

  .brand img {
    width: 122px;
  }

  .header-cta {
    display: none;
  }

  .hero {
    min-height: 88svh;
    padding-top: 6.8rem;
  }

  .status-strip,
  .section-heading,
  .intro-grid,
  .paths,
  .join-layout,
  .steps,
  .site-footer,
  .launch-board,
  .experience-row {
    grid-template-columns: 1fr;
  }

  .intro-grid article:first-child {
    grid-column: auto;
  }

  .status-strip > div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .join-panel {
    position: static;
  }
}

@media (max-width: 580px) {
  .site-header {
    min-height: 70px;
    grid-template-columns: auto auto;
  }

  .header-actions {
    grid-column: 1 / -1;
    justify-self: stretch;
  }

  .language-switch {
    width: 100%;
  }

  .site-nav {
    inset-block-start: 118px;
  }

  .hero {
    min-height: 86svh;
    padding-top: 8.7rem;
  }

  h1 {
    font-size: clamp(3.5rem, 18vw, 4.6rem);
  }

  .hero-actions,
  .button {
    width: 100%;
  }

  .hero-facts div,
  .faction-grid,
  .rules-grid,
  .stats-grid {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .faction-card {
    min-height: auto;
  }

  .site-footer img {
    width: 150px;
  }
}
