:root {
  --ink: #f4f1e8;
  --muted: #a7aa9b;
  --muted-strong: #c3c6b7;
  --ground: #10110d;
  --ground-soft: #151711;
  --panel: #1a1c15;
  --panel-lift: #21241a;
  --line: rgba(242, 234, 207, 0.13);
  --line-strong: rgba(242, 234, 207, 0.24);
  --ember: #ff6b35;
  --ember-light: #ff9b54;
  --gold: #f5c451;
  --acid: #c8f169;
  --danger: #ff8174;
  --shell: 1180px;
  --radius-lg: 24px;
  --radius-md: 16px;
  --shadow: 0 24px 90px rgba(0, 0, 0, 0.36);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background:
    radial-gradient(circle at 78% 5%, rgba(255, 107, 53, 0.11), transparent 29rem),
    radial-gradient(circle at 9% 21%, rgba(200, 241, 105, 0.06), transparent 24rem),
    var(--ground);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.012) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.012) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 75%);
  content: "";
  pointer-events: none;
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

code {
  color: #f5d694;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.9em;
}

.shell {
  width: min(calc(100% - 40px), var(--shell));
  margin-inline: auto;
}

.sr-only {
  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 {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  color: var(--ground);
  background: var(--acid);
  border-radius: 8px;
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  width: min(calc(100% - 40px), var(--shell));
  min-height: 90px;
  margin-inline: auto;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  gap: 11px;
  align-items: center;
  width: max-content;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: var(--ground);
  background: var(--gold);
  border: 1px solid #ffd879;
  border-radius: 12px;
  box-shadow: inset 0 -3px 0 rgba(73, 47, 0, 0.25);
  font-size: 18px;
}

.brand > span:last-child {
  display: grid;
  line-height: 1.1;
}

.brand strong {
  font-size: 14px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.brand small {
  margin-top: 4px;
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.header-nav {
  display: flex;
  gap: 30px;
  align-items: center;
  color: var(--muted-strong);
  font-size: 13px;
}

.header-nav a,
footer a {
  transition: color 160ms ease;
}

.header-nav a:hover,
footer a:hover {
  color: var(--ink);
}

.site-header > .button {
  justify-self: end;
}

.button {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 21px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 750;
  line-height: 1;
  transition:
    transform 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease,
    color 160ms ease;
}

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

.button:focus-visible,
.icon-button:focus-visible,
.copy-button:focus-visible,
.header-nav a:focus-visible,
.resource-row a:focus-visible,
footer a:focus-visible {
  outline: 3px solid rgba(200, 241, 105, 0.55);
  outline-offset: 4px;
}

.button-primary {
  color: #241208;
  background: var(--ember);
  border-color: #ff8d64;
  box-shadow: inset 0 -4px 0 rgba(91, 25, 2, 0.3), 0 14px 34px rgba(255, 107, 53, 0.18);
}

.button-primary:hover {
  background: #ff7b49;
}

.button-secondary,
.button-ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.035);
  border-color: var(--line-strong);
}

.button-secondary:hover,
.button-ghost:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.34);
}

.button-compact {
  min-height: 40px;
  padding-inline: 15px;
  font-size: 12px;
}

.eyebrow {
  display: flex;
  gap: 9px;
  align-items: center;
  color: var(--acid);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.live-dot,
.status-dot {
  width: 7px;
  height: 7px;
  background: var(--acid);
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(200, 241, 105, 0.09);
  animation: pulse 2.2s ease-in-out infinite;
}

.arena-strip {
  overflow: hidden;
  color: var(--ground);
  background: var(--acid);
  border-block: 1px solid #e2ff9f;
}

.arena-strip-inner {
  display: flex;
  gap: 22px;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.arena-strip-inner i {
  opacity: 0.45;
  font-style: normal;
}

.arena-strip-inner strong {
  padding: 4px 9px;
  color: var(--acid);
  background: var(--ground);
  border-radius: 5px;
}

.section {
  padding-block: 118px;
  scroll-margin-top: 18px;
}

.leaderboard-section {
  padding-top: clamp(72px, 8vw, 96px);
}

.section-heading h2,
.cta-panel h2 {
  margin: 12px 0 0;
  font-size: clamp(42px, 5vw, 62px);
  letter-spacing: -0.055em;
  line-height: 1;
}

.section-heading p {
  max-width: 570px;
  margin: 18px 0 0;
  color: var(--muted);
}

.split-heading,
.quickstart-heading,
.playbook-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.62fr);
  gap: 60px;
  align-items: end;
}

.split-heading > div:last-child {
  align-self: center;
  justify-self: end;
}

.board-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.data-status {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 39px;
  padding: 0 14px;
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 10px;
}

.data-status.is-cached .status-dot {
  background: var(--gold);
  box-shadow: 0 0 0 5px rgba(245, 196, 81, 0.09);
  animation: none;
}

.data-status.is-error .status-dot {
  background: var(--danger);
  box-shadow: 0 0 0 5px rgba(255, 129, 116, 0.08);
  animation: none;
}

.icon-button {
  display: grid;
  width: 40px;
  height: 40px;
  padding: 0;
  place-items: center;
  color: var(--ink);
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  border-radius: 50%;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background-color 160ms ease;
}

.icon-button:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: var(--line-strong);
  transform: rotate(25deg);
}

.icon-button:disabled {
  cursor: wait;
  opacity: 0.55;
}

.score-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: 0;
  overflow: hidden;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}

.score-cards article {
  display: grid;
  min-height: 142px;
  padding: 24px;
  background: var(--panel);
}

.score-cards span,
.score-cards small {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.score-cards strong {
  align-self: end;
  margin-top: 14px;
  font-size: 31px;
  letter-spacing: -0.04em;
  line-height: 1;
}

.score-cards small {
  margin-top: 7px;
  color: #74786a;
  letter-spacing: 0.05em;
}

.history-heading,
.history-footer {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
}

.history-heading h3 {
  margin: 7px 0 0;
  font-size: 24px;
  letter-spacing: -0.035em;
}

.history-key {
  display: flex;
  gap: 9px;
  align-items: center;
  color: var(--muted-strong);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.history-key span {
  width: 24px;
  height: 3px;
  background: var(--acid);
  border-radius: 999px;
  box-shadow: 0 0 14px rgba(200, 241, 105, 0.45);
}

.history-canvas-wrap {
  position: relative;
  height: 320px;
  margin-top: 26px;
}

#score-history {
  display: block;
  width: 100%;
  height: 100%;
}

.history-summary {
  margin: 4px 0 0;
  color: var(--muted-strong);
  font-size: 11px;
}

.history-footer {
  padding-top: 14px;
  margin-top: 13px;
  color: #777b6c;
  border-top: 1px solid var(--line);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 8px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.history-footer span:nth-child(2) {
  text-align: center;
}

.frontier-hero {
  display: grid;
  grid-template-rows: auto auto minmax(300px, 1fr) auto auto;
  min-height: calc(100svh - 90px);
  padding: clamp(40px, 5vw, 62px) 0 28px;
  margin-top: 0;
  margin-bottom: 0;
  scroll-margin-top: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.frontier-hero:focus-visible {
  outline: 3px solid rgba(200, 241, 105, 0.55);
  outline-offset: 5px;
}

.frontier-heading {
  align-items: flex-end;
}

.frontier-copy {
  max-width: 730px;
}

.frontier-heading h1 {
  margin: 11px 0 0;
  font-size: clamp(44px, 5.7vw, 72px);
  letter-spacing: -0.06em;
  line-height: 0.96;
}

.frontier-copy > p {
  max-width: 610px;
  margin: 15px 0 0;
  color: var(--muted-strong);
  font-size: 15px;
}

.frontier-record {
  display: grid;
  min-width: 250px;
  padding-left: 28px;
  border-left: 1px solid var(--line-strong);
}

.frontier-record span,
.frontier-record small,
.frontier-deadline span {
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.frontier-record strong {
  margin-top: 5px;
  color: var(--acid);
  font-size: clamp(38px, 4.6vw, 58px);
  letter-spacing: -0.055em;
  line-height: 1;
}

.frontier-record small {
  margin-top: 7px;
  overflow: hidden;
  color: var(--ember-light);
  text-overflow: ellipsis;
  text-transform: none;
  white-space: nowrap;
}

.frontier-toolbar,
.frontier-toolbar-actions {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
}

.frontier-toolbar {
  margin-top: 24px;
}

.frontier-toolbar .icon-button,
.frontier-toolbar .button {
  min-width: 44px;
  min-height: 44px;
}

.frontier-deadline {
  display: grid;
  margin: 0;
  line-height: 1.25;
  text-align: right;
}

.frontier-deadline time {
  margin-top: 4px;
  color: var(--ink);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.frontier-hero .history-canvas-wrap {
  height: clamp(300px, 43vh, 470px);
  margin-top: 18px;
}

.frontier-hero .history-summary {
  margin-top: 7px;
}

.leaderboard-panel {
  margin-top: 18px;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 18px 55px rgba(0, 0, 0, 0.19);
}

.board-pagination {
  display: flex;
  gap: 20px;
  align-items: center;
  justify-content: space-between;
  min-height: 62px;
  padding: 10px 12px 10px 20px;
  background: rgba(255, 255, 255, 0.018);
  border-bottom: 1px solid var(--line);
}

.board-pagination[hidden] {
  display: none;
}

.board-pagination > p {
  flex: 0 0 auto;
  margin: 0;
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.board-page-tabs {
  display: flex;
  gap: 6px;
  max-width: 100%;
  padding: 2px;
  overflow-x: auto;
  scrollbar-color: var(--line-strong) transparent;
  scrollbar-width: thin;
}

.board-page-tab {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0 11px;
  color: var(--muted-strong);
  cursor: pointer;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--line);
  border-radius: 9px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  white-space: nowrap;
  transition:
    color 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease,
    transform 160ms ease;
}

.board-page-tab:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

.board-page-tab[aria-current="page"] {
  color: var(--ground);
  background: var(--acid);
  border-color: #e2ff9f;
}

.board-page-tab:focus-visible {
  outline: 3px solid rgba(200, 241, 105, 0.55);
  outline-offset: 2px;
}

.table-scroll {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
}

th,
td {
  padding: 18px 20px;
  text-align: left;
}

th {
  height: 52px;
  color: #777b6c;
  background: rgba(255, 255, 255, 0.018);
  border-bottom: 1px solid var(--line);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

tbody tr {
  transition: background-color 160ms ease;
}

tbody tr:not(:last-child) td {
  border-bottom: 1px solid var(--line);
}

tbody tr:hover {
  background: rgba(255, 255, 255, 0.025);
}

td {
  color: var(--muted-strong);
  font-size: 13px;
}

.rank-cell {
  width: 68px;
}

.rank-badge {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
}

.leader-row .rank-badge {
  color: #583900;
  background: var(--gold);
  border-color: #ffe28e;
  box-shadow: inset 0 -3px 0 rgba(92, 61, 0, 0.18);
}

.worker-cell {
  min-width: 180px;
}

.worker-name {
  display: block;
  color: var(--ink);
  font-weight: 750;
}

.runner-meta {
  display: inline-flex;
  margin-top: 4px;
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
}

.xp-cell strong {
  color: var(--acid);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 19px;
}

.xp-cell small {
  margin-left: 4px;
  color: var(--muted);
  font-size: 9px;
  text-transform: uppercase;
}

.seed-bars {
  display: flex;
  gap: 5px;
  align-items: end;
  width: 108px;
  height: 28px;
}

.seed-bar {
  position: relative;
  flex: 1;
  height: 100%;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
}

.seed-bar > span {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  min-height: 3px;
  background: var(--ember);
  border-radius: inherit;
}

.seed-values {
  display: flex;
  gap: 7px;
  margin-top: 5px;
  color: #777b6c;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 8px;
}

.proof-code {
  display: inline-block;
  max-width: 104px;
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  text-overflow: ellipsis;
  vertical-align: middle;
  white-space: nowrap;
}

.loading-row td,
.empty-row td {
  height: 100px;
  color: var(--muted);
  text-align: center;
}

.baseline-row {
  background: rgba(245, 196, 81, 0.025);
}

.baseline-row .rank-badge {
  color: var(--gold);
  background: rgba(245, 196, 81, 0.07);
  border-color: rgba(245, 196, 81, 0.18);
  box-shadow: none;
}

.board-footer {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  min-height: 63px;
  padding: 12px 20px;
  border-top: 1px solid var(--line);
}

.board-footer p {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
}

.board-footer p span {
  margin-inline: 5px;
}

.board-footer a {
  color: var(--muted-strong);
  font-size: 11px;
  font-weight: 700;
}

.board-footer a:hover {
  color: var(--ink);
}

.warning-note {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-top: 18px;
  padding: 18px 20px;
  color: #d5c9ad;
  background: rgba(245, 196, 81, 0.055);
  border: 1px solid rgba(245, 196, 81, 0.14);
  border-radius: var(--radius-md);
}

.warning-note > span {
  color: var(--gold);
}

.warning-note p {
  margin: 0;
  font-size: 12px;
}

.quickstart-section {
  background:
    radial-gradient(circle at 90% 18%, rgba(255, 107, 53, 0.08), transparent 30rem),
    var(--ground-soft);
  border-block: 1px solid var(--line);
}

.quickstart-heading > p,
.playbook-heading > p,
.submit-heading > p {
  align-self: end;
  justify-self: end;
}

.steps {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  padding: 0;
  margin: 62px 0 0;
  list-style: none;
}

.step-card {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 18px;
  min-height: 310px;
  padding: 26px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease;
}

.step-card:hover {
  background: var(--panel-lift);
  border-color: var(--line-strong);
  transform: translateY(-3px);
}

.step-number {
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  color: var(--ember-light);
  background: rgba(255, 107, 53, 0.07);
  border: 1px solid rgba(255, 107, 53, 0.16);
  border-radius: 14px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 12px;
}

.step-content {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.step-label,
.priority-label {
  color: var(--acid);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.step-card h3,
.play-card h3,
.experiment-ladder h3 {
  margin: 8px 0 8px;
  font-size: 23px;
  letter-spacing: -0.035em;
  line-height: 1.15;
}

.step-card p,
.play-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.command-block {
  position: relative;
  display: flex;
  min-height: 82px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 15px;
  margin-top: auto;
  overflow-x: auto;
  background: #0c0d0a;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 11px;
}

.command-block code {
  padding-right: 56px;
  color: #cdd5bc;
  font-size: 10px;
  line-height: 1.7;
  white-space: nowrap;
}

.copy-button {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 5px 8px;
  color: var(--muted);
  cursor: pointer;
  background: #181a14;
  border: 1px solid var(--line);
  border-radius: 6px;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.copy-button:hover {
  color: var(--ink);
  border-color: var(--line-strong);
}

.copy-button.is-copied {
  color: var(--acid);
}

.resource-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-top: 18px;
}

.resource-row a {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  gap: 12px;
  align-items: center;
  min-height: 82px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition:
    background-color 160ms ease,
    border-color 160ms ease,
    transform 160ms ease;
}

.resource-row a:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--line-strong);
  transform: translateY(-2px);
}

.resource-row a > span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: var(--ground);
  background: var(--acid);
  border-radius: 9px;
  font-weight: 900;
}

.resource-row a div {
  display: grid;
}

.resource-row strong {
  font-size: 12px;
}

.resource-row small {
  color: var(--muted);
  font-size: 9px;
}

.resource-row i {
  color: var(--muted);
  font-style: normal;
}

.submit-section {
  scroll-margin-top: 18px;
}

.submit-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.62fr);
  gap: 60px;
  align-items: end;
}

.submit-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding: 0;
  margin: 62px 0 0;
  list-style: none;
}

.submit-step {
  position: relative;
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  gap: 18px;
  min-height: 350px;
  padding: 26px;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}

.submit-step-featured {
  background:
    radial-gradient(circle at 100% 0%, rgba(200, 241, 105, 0.1), transparent 21rem),
    var(--panel-lift);
  border-color: rgba(200, 241, 105, 0.22);
}

.submit-step-number {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: var(--acid);
  background: rgba(200, 241, 105, 0.07);
  border: 1px solid rgba(200, 241, 105, 0.16);
  border-radius: 13px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
}

.submit-step > div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.submit-step h3,
.agent-manifest h3 {
  margin: 8px 0;
  font-size: 23px;
  letter-spacing: -0.035em;
  line-height: 1.15;
}

.submit-step p,
.agent-manifest p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.command-block-tall {
  min-height: 122px;
  margin-top: auto;
}

.command-comment {
  color: #7f846f;
}

.agent-manifest {
  display: flex;
  gap: 34px;
  align-items: center;
  justify-content: space-between;
  padding: 26px 28px;
  margin-top: 16px;
  background: rgba(200, 241, 105, 0.045);
  border: 1px solid rgba(200, 241, 105, 0.16);
  border-radius: var(--radius-lg);
}

.agent-manifest > div {
  max-width: 760px;
}

.agent-manifest .button {
  flex: 0 0 auto;
}

.agent-manifest-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
}

.playbook-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 62px;
}

.play-card {
  position: relative;
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 17px;
  min-height: 250px;
  padding: 26px;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}

.play-card-featured {
  grid-column: span 2;
  grid-template-columns: 74px minmax(0, 1fr);
  min-height: 306px;
  padding: 34px;
  background:
    radial-gradient(circle at 88% 12%, rgba(200, 241, 105, 0.11), transparent 25rem),
    var(--panel-lift);
  border-color: rgba(200, 241, 105, 0.2);
}

.play-index {
  position: absolute;
  right: 20px;
  bottom: -33px;
  color: rgba(255, 255, 255, 0.027);
  font-size: 150px;
  font-weight: 900;
  line-height: 1;
  pointer-events: none;
}

.play-icon {
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  color: var(--ember-light);
  background: rgba(255, 107, 53, 0.07);
  border: 1px solid rgba(255, 107, 53, 0.15);
  border-radius: 14px;
  font-size: 21px;
}

.play-card-featured .play-icon {
  width: 64px;
  height: 64px;
  color: var(--ground);
  background: var(--acid);
  border-color: #e2ff9f;
  font-size: 26px;
}

.play-card h3 {
  margin-top: 9px;
}

.play-card-copy {
  position: relative;
  z-index: 1;
  max-width: 750px;
}

.play-card ul {
  display: grid;
  gap: 8px;
  padding: 0;
  margin: 24px 0 0;
  color: var(--muted-strong);
  font-size: 12px;
  list-style: none;
}

.play-card li::before {
  margin-right: 9px;
  color: var(--acid);
  content: "↳";
}

.play-card-caution .play-icon {
  color: var(--danger);
  background: rgba(255, 129, 116, 0.06);
  border-color: rgba(255, 129, 116, 0.15);
}

.play-card-caution .priority-label {
  color: var(--danger);
}

.experiment-ladder {
  display: grid;
  grid-template-columns: 0.7fr 1.3fr;
  gap: 42px;
  align-items: center;
  padding: 30px;
  margin-top: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}

.experiment-ladder ol {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.experiment-ladder ol::before {
  position: absolute;
  top: 11px;
  right: 10%;
  left: 10%;
  height: 1px;
  background: var(--line-strong);
  content: "";
}

.experiment-ladder li {
  position: relative;
  display: grid;
  min-width: 0;
  text-align: center;
}

.experiment-ladder li::before {
  width: 9px;
  height: 9px;
  margin: 7px auto 13px;
  background: var(--ember);
  border: 4px solid var(--panel);
  border-radius: 50%;
  box-shadow: 0 0 0 1px var(--line-strong);
  content: "";
}

.experiment-ladder li span {
  color: var(--muted);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 8px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.experiment-ladder li strong {
  margin-top: 3px;
  font-size: 12px;
}

.experiment-ladder li small {
  margin-top: 3px;
  overflow: hidden;
  color: #777b6c;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.autoresearch-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 42px;
  align-items: center;
  padding: 34px;
  margin-top: 16px;
  scroll-margin-top: 24px;
  background:
    radial-gradient(circle at 4% 0%, rgba(255, 107, 53, 0.13), transparent 22rem),
    radial-gradient(circle at 100% 100%, rgba(200, 241, 105, 0.08), transparent 25rem),
    var(--panel-lift);
  border: 1px solid rgba(255, 107, 53, 0.2);
  border-radius: var(--radius-lg);
}

.autoresearch-copy h3 {
  max-width: 520px;
  margin: 11px 0 12px;
  font-size: 31px;
  letter-spacing: -0.045em;
  line-height: 1.08;
}

.autoresearch-copy p {
  max-width: 580px;
  margin: 0;
  color: var(--muted-strong);
  font-size: 13px;
}

.autoresearch-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 25px;
}

.autoresearch-principles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.autoresearch-principles li {
  display: grid;
  grid-template-columns: 35px minmax(0, 1fr);
  gap: 11px;
  min-height: 96px;
  padding: 16px;
  background: rgba(12, 13, 10, 0.54);
  border: 1px solid var(--line);
  border-radius: 13px;
}

.autoresearch-principles li > span {
  color: var(--ember-light);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.autoresearch-principles li div {
  display: grid;
  align-content: start;
}

.autoresearch-principles strong {
  font-size: 12px;
}

.autoresearch-principles small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.45;
}

.cta-panel {
  position: relative;
  display: flex;
  gap: 36px;
  align-items: flex-end;
  justify-content: space-between;
  min-height: 310px;
  padding: 45px;
  margin-top: 74px;
  overflow: hidden;
  background: var(--ember);
  border: 1px solid #ff946d;
  border-radius: 30px;
  box-shadow: 0 28px 75px rgba(255, 107, 53, 0.15);
}

.cta-panel::after {
  position: absolute;
  top: -132px;
  right: -85px;
  width: 360px;
  height: 360px;
  border: 65px solid rgba(80, 24, 3, 0.1);
  border-radius: 50%;
  content: "";
}

.cta-panel > div,
.cta-panel > a {
  position: relative;
  z-index: 1;
}

.cta-panel .eyebrow {
  color: #482008;
}

.cta-panel h2 {
  max-width: 780px;
  color: #1d1009;
}

.cta-panel p {
  margin: 17px 0 0;
  color: rgba(37, 17, 6, 0.73);
}

.cta-panel .button-primary {
  flex: 0 0 auto;
  color: var(--ink);
  background: var(--ground);
  border-color: rgba(255, 255, 255, 0.17);
  box-shadow: none;
}

footer {
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 24px;
  align-items: center;
  min-height: 120px;
}

.footer-inner > p {
  color: var(--muted);
  font-size: 10px;
}

.footer-inner > div:last-child {
  display: flex;
  gap: 20px;
  justify-self: end;
  color: var(--muted-strong);
  font-size: 11px;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.55;
    transform: scale(0.85);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

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

  .header-nav {
    display: none;
  }

  .score-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .split-heading,
  .quickstart-heading,
  .playbook-heading,
  .submit-heading,
  .experiment-ladder,
  .autoresearch-panel {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .quickstart-heading > p,
  .playbook-heading > p,
  .submit-heading > p {
    justify-self: start;
  }

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

  .submit-steps {
    grid-template-columns: 1fr;
  }

  .experiment-ladder ol {
    margin-top: 12px;
  }
}

@media (max-width: 720px) {
  .shell,
  .site-header {
    width: min(calc(100% - 28px), var(--shell));
  }

  .site-header {
    min-height: 76px;
  }

  .site-header > .button {
    font-size: 0;
  }

  .site-header > .button span {
    font-size: 13px;
  }

  .arena-strip-inner {
    justify-content: flex-start;
    overflow-x: auto;
  }

  .section {
    padding-block: 88px;
  }

  .leaderboard-section {
    padding-top: 64px;
  }

  .section-heading h2,
  .cta-panel h2 {
    font-size: 42px;
  }

  .split-heading > div:last-child {
    justify-self: start;
  }

  .score-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .board-pagination {
    gap: 10px;
    align-items: stretch;
    flex-direction: column;
    padding: 14px 16px;
  }

  .board-page-tabs {
    width: 100%;
  }

  .board-page-tab {
    min-height: 44px;
  }

  .frontier-hero {
    min-height: calc(100svh - 76px);
    padding: 34px 0 22px;
    margin-top: 0;
    margin-bottom: 0;
  }

  .frontier-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .frontier-record {
    grid-template-columns: 1fr auto;
    width: 100%;
    padding: 18px 0 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .frontier-record strong {
    grid-row: span 2;
  }

  .frontier-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .frontier-toolbar-actions {
    width: 100%;
  }

  .frontier-hero .history-canvas-wrap {
    height: clamp(280px, 42vh, 360px);
  }

  .history-canvas-wrap {
    height: 280px;
  }

  .steps,
  .playbook-grid {
    grid-template-columns: 1fr;
  }

  .play-card-featured {
    grid-column: auto;
    grid-template-columns: 56px 1fr;
    min-height: 0;
    padding: 26px;
  }

  .play-card-featured .play-icon {
    width: 50px;
    height: 50px;
  }

  .step-card,
  .play-card {
    min-height: 0;
  }

  .submit-step {
    min-height: 0;
  }

  .command-block {
    margin-top: 28px;
  }

  .experiment-ladder {
    padding: 24px 20px;
  }

  .experiment-ladder ol {
    grid-template-columns: repeat(2, 1fr);
    gap: 22px 8px;
  }

  .experiment-ladder ol::before {
    display: none;
  }

  .cta-panel {
    min-height: 390px;
    flex-direction: column;
    align-items: flex-start;
    padding: 34px 26px;
  }

  .agent-manifest {
    align-items: flex-start;
    flex-direction: column;
  }

  .agent-manifest-actions {
    flex-wrap: wrap;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    padding-block: 34px;
  }

  .footer-inner > p {
    margin: 0;
  }

  .footer-inner > div:last-child {
    justify-self: start;
  }
}

@media (max-width: 480px) {
  .step-card,
  .play-card,
  .play-card-featured,
  .submit-step {
    grid-template-columns: 1fr;
  }

  .step-card {
    padding: 22px;
  }

  .autoresearch-panel {
    padding: 24px 20px;
  }

  .autoresearch-principles {
    grid-template-columns: 1fr;
  }

  .autoresearch-actions,
  .autoresearch-actions .button,
  .agent-manifest-actions,
  .agent-manifest-actions .button {
    width: 100%;
  }

  .board-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .history-heading,
  .history-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .frontier-hero {
    padding: 30px 0 20px;
  }

  .frontier-heading h1 {
    font-size: clamp(39px, 12vw, 54px);
  }

  .frontier-record {
    display: grid;
  }

  .frontier-toolbar-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .frontier-deadline {
    text-align: left;
  }

  .frontier-toolbar-actions .button {
    width: 100%;
  }

  .history-canvas-wrap {
    height: 250px;
  }

  .history-footer span:nth-child(2) {
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
