:root {
  color-scheme: dark;
  --bg: #050508;
  --bg-soft: #0c0b14;
  --panel: rgba(16, 14, 27, 0.9);
  --panel-strong: #141122;
  --line: rgba(110, 98, 168, 0.34);
  --line-strong: rgba(110, 98, 168, 0.56);
  --text: #f6f3ff;
  --muted: #b4abc9;
  --pink: #ff3ed7;
  --pink-soft: #ff8ff0;
  --blue: #35a8ff;
  --blue-soft: #8bd5ff;
  --violet: #845dff;
  --green: #37d39a;
  --amber: #ffcc66;
  --danger: #ff6b86;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.archive-banner {
  position: relative;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.78rem max(1.25rem, calc((100vw - 1180px) / 2));
  border-bottom: 1px solid rgba(255, 204, 102, 0.48);
  color: #fff6dc;
  background: linear-gradient(90deg, rgba(75, 52, 5, 0.96), rgba(35, 16, 35, 0.98));
}

.archive-banner div {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.8rem;
  align-items: baseline;
}

.archive-banner strong {
  color: var(--amber);
}

.archive-banner span {
  color: #d9d0bd;
  font-size: 0.82rem;
}

.archive-banner a {
  flex: 0 0 auto;
  color: var(--amber);
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

@media (max-width: 700px) {
  .archive-banner {
    align-items: flex-start;
    flex-direction: column;
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(255, 62, 215, 0.18), transparent 28%),
    radial-gradient(circle at top right, rgba(53, 168, 255, 0.16), transparent 24%),
    linear-gradient(180deg, #090810 0%, #040407 100%);
}

a {
  color: inherit;
}

code {
  font-family: "SFMono-Regular", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  color: var(--blue-soft);
}

.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;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 80px;
  padding: 14px clamp(18px, 4vw, 64px);
  background: rgba(6, 5, 11, 0.85);
  border-bottom: 1px solid rgba(132, 93, 255, 0.24);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}

.brand-logo {
  width: 56px;
  height: 56px;
  padding: 4px;
  object-fit: contain;
  background: rgba(7, 6, 15, 0.96);
  border: 1px solid rgba(110, 98, 168, 0.28);
  border-radius: 8px;
  box-shadow:
    0 0 24px rgba(255, 62, 215, 0.35),
    0 0 32px rgba(53, 168, 255, 0.22);
}

.brand-text {
  display: grid;
  gap: 2px;
}

.brand-text strong {
  color: var(--text);
  font-size: 1.04rem;
}

.brand-text small {
  color: var(--blue-soft);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.5vw, 28px);
}

.site-nav a {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--pink-soft);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.nav-toggle span:not(.sr-only) {
  display: block;
  width: 100%;
  height: 2px;
  margin: 4px 0;
  background: var(--text);
}

.hero,
.content-band {
  padding: clamp(56px, 8vw, 96px) clamp(18px, 4vw, 64px);
}

.hero {
  padding-top: clamp(6px, 1.2vw, 12px);
  padding-bottom: clamp(56px, 8vw, 96px);
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(280px, 0.88fr);
  align-items: start;
  gap: clamp(32px, 6vw, 84px);
  min-height: calc(100vh - 80px);
}

.hero-copy,
.hero-side {
  align-self: start;
}

.hero-copy {
  margin-top: -2px;
}

.hero-copy > .eyebrow {
  margin-top: 12px;
  margin-bottom: 12px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--pink-soft);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2,
h3,
p,
ul,
ol {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(2.8rem, 8vw, 6.2rem);
  line-height: 0.95;
}

.hero-sats-line,
.hero-subline {
  display: block;
}

.hero-subline {
  margin-top: 0.22em;
  color: var(--muted);
  font-size: clamp(1.28rem, 3vw, 2.1rem);
  font-weight: 700;
  line-height: 1.04;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(2rem, 5vw, 4.4rem);
  line-height: 0.95;
}

h3 {
  margin-bottom: 10px;
  font-size: clamp(1.16rem, 2.2vw, 1.56rem);
}

.hero-text,
.section-heading p,
.score-note,
.prize-panel p,
.rules-list p,
.rules-list li,
.mini-table,
.site-footer,
.status-strip span {
  color: var(--muted);
}

.hero-text {
  max-width: 720px;
  margin-bottom: 26px;
  font-size: clamp(1.08rem, 2.2vw, 1.34rem);
  line-height: 1.62;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 28px;
}

.download-button-shell {
  position: relative;
  display: inline-flex;
  align-items: flex-start;
}

.primary-button,
.secondary-button,
.ghost-button,
.mode-button,
.primary-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 18px;
  border-radius: 8px;
  font-weight: 800;
  text-decoration: none;
}

.primary-button,
.primary-pill {
  color: #07050d;
  background: linear-gradient(135deg, var(--pink) 0%, var(--blue-soft) 100%);
  box-shadow: 0 0 24px rgba(255, 62, 215, 0.24);
}

.primary-button.is-coming-soon {
  opacity: 0.84;
  pointer-events: none;
  filter: saturate(0.7);
}

.coming-soon-chip {
  position: absolute;
  top: -9px;
  right: -8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px 10px;
  color: #fffdf6;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: linear-gradient(135deg, rgba(255, 95, 76, 0.96) 0%, rgba(255, 62, 215, 0.92) 100%);
  border: 1px solid rgba(255, 244, 214, 0.42);
  border-radius: 999px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.24);
  z-index: 2;
  pointer-events: none;
}

.secondary-button,
.mode-button {
  color: var(--text);
  background: rgba(18, 16, 31, 0.78);
  border: 1px solid var(--line);
}

.secondary-button {
  color: #07050d;
  background: linear-gradient(135deg, var(--blue-soft) 0%, var(--pink-soft) 100%);
  border: 0;
  box-shadow: 0 0 24px rgba(53, 168, 255, 0.24);
}

.ghost-button {
  color: var(--blue-soft);
  background: transparent;
  border: 1px solid rgba(139, 213, 255, 0.28);
}

.hero-meta,
.status-strip,
.members-layout,
.score-grid,
.prize-grid,
.integration-grid {
  display: grid;
  gap: 18px;
}

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

.hero-meta article,
.status-strip article,
.score-card,
.prize-panel,
.integration-card,
.leaderboard-panel,
.metric-stack article,
.submission-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.hero-meta article,
.status-strip article,
.score-card,
.prize-panel,
.integration-card,
.metric-stack article {
  padding: 22px;
}

.hero-meta span,
.status-strip strong,
.prize-topline span {
  display: block;
}

.hero-meta span,
.status-strip span,
.prize-topline span,
.metric-label {
  margin-bottom: 8px;
  color: var(--blue-soft);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.hero-meta strong,
.status-strip strong,
.metric-value {
  color: var(--text);
  font-size: 1.15rem;
}

.hero-meta p,
.metric-note {
  margin-bottom: 0;
  line-height: 1.55;
}

.hero-visual {
  display: grid;
  place-items: start center;
  align-content: start;
  min-height: 0;
}

.hero-visual img {
  display: block;
  width: min(100%, 430px);
  height: auto;
  margin-top: -26px;
  filter: drop-shadow(0 0 36px rgba(255, 62, 215, 0.3));
}

.hero-side {
  display: grid;
  gap: 18px;
}

.hero-board-preview {
  padding: 22px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.hero-board-list {
  display: grid;
  gap: 10px;
}

.hero-board-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(110, 98, 168, 0.18);
}

.hero-board-item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.hero-board-item strong {
  font-size: 0.98rem;
}

.hero-board-item span {
  color: var(--muted);
  font-size: 0.92rem;
}

.content-band.alt {
  background: rgba(7, 6, 15, 0.72);
}

.section-heading {
  max-width: 860px;
  margin-bottom: 30px;
}

.leaderboard-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(300px, 0.7fr);
  gap: 18px;
}

.members-layout,
.member-submission-shell {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.member-submission-shell {
  margin-top: 18px;
}

.member-card {
  padding: 22px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.member-form {
  display: grid;
  gap: 14px;
}

.is-hidden,
.text-toggle.is-hidden,
.admin-shell.is-hidden {
  display: none;
}

.member-form label {
  display: grid;
  gap: 8px;
}

.member-form span {
  color: var(--blue-soft);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
}

.member-form input,
.member-form select,
.member-form textarea {
  width: 100%;
  padding: 13px 14px;
  color: var(--text);
  font: inherit;
  background: rgba(8, 7, 15, 0.9);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.member-form input.is-error {
  border-color: var(--pink);
  box-shadow: 0 0 0 1px rgba(255, 62, 215, 0.75), 0 0 18px rgba(255, 62, 215, 0.16);
}

.member-form input.is-success {
  border-color: var(--blue-soft);
  box-shadow: 0 0 0 1px rgba(139, 213, 255, 0.65), 0 0 18px rgba(53, 168, 255, 0.14);
}

.field-status {
  margin: -4px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.field-status.is-error {
  color: var(--pink-soft);
}

.field-status.is-success {
  color: var(--blue-soft);
}

.auth-mode-toggle {
  display: inline-flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.auth-helper-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.text-toggle {
  padding: 0;
  color: var(--blue-soft);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  background: transparent;
  border: 0;
  cursor: pointer;
}

.member-form textarea {
  resize: vertical;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.form-button {
  border: 0;
  cursor: pointer;
}

.member-status,
.member-profile,
.member-entry {
  padding: 18px;
  margin-top: 18px;
  background: rgba(10, 9, 18, 0.82);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.member-status strong,
.member-profile strong,
.member-entry strong {
  display: block;
  margin-bottom: 8px;
}

.member-status p,
.member-profile p,
.member-entry p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

.member-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.member-profile-grid article {
  padding: 14px;
  background: rgba(7, 6, 15, 0.9);
  border: 1px solid rgba(110, 98, 168, 0.2);
  border-radius: 8px;
}

.member-profile-grid span {
  display: block;
  margin-bottom: 8px;
  color: var(--blue-soft);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.member-profile-grid strong {
  margin-bottom: 0;
}

.member-entries {
  display: grid;
  gap: 12px;
}

.admin-shell {
  margin-top: 18px;
}

.admin-card {
  padding: 24px;
}

.admin-status {
  margin-top: 0;
  margin-bottom: 18px;
}

.admin-refresh-button {
  min-height: 40px;
  padding: 10px 14px;
  color: var(--blue-soft);
  background: transparent;
}

.admin-queue {
  display: grid;
  gap: 14px;
}

.admin-review-item {
  padding: 18px;
  background: rgba(10, 9, 18, 0.82);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.admin-review-top,
.admin-review-meta,
.admin-review-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: center;
}

.admin-review-top {
  justify-content: space-between;
  margin-bottom: 10px;
}

.admin-review-top h4 {
  margin: 0;
  font-size: 1rem;
}

.admin-review-meta {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.92rem;
}

.admin-review-reference {
  margin: 0 0 10px;
  word-break: break-word;
}

.admin-review-reference a {
  color: var(--blue-soft);
}

.admin-review-note {
  width: 100%;
  min-height: 88px;
  margin: 0 0 12px;
  padding: 12px 14px;
  color: var(--text);
  font: inherit;
  background: rgba(7, 6, 15, 0.9);
  border: 1px solid var(--line);
  border-radius: 8px;
  resize: vertical;
}

.admin-review-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.admin-review-grid label,
.admin-toggle-grid label {
  display: grid;
  gap: 6px;
}

.admin-review-grid span,
.admin-toggle-grid span {
  color: var(--blue-soft);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.admin-review-grid input,
.admin-toggle-grid input {
  width: 100%;
  padding: 10px 12px;
  color: var(--text);
  font: inherit;
  background: rgba(7, 6, 15, 0.9);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.admin-toggle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.admin-toggle-grid label {
  padding: 12px;
  background: rgba(7, 6, 15, 0.72);
  border: 1px solid rgba(110, 98, 168, 0.24);
  border-radius: 8px;
}

.admin-toggle-grid input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 0;
}

.admin-review-actions button {
  min-height: 38px;
  padding: 9px 13px;
  color: var(--text);
  font: inherit;
  font-weight: 700;
  background: rgba(18, 16, 31, 0.78);
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
}

.admin-review-actions button[data-review-action="verified"] {
  border-color: rgba(55, 211, 154, 0.42);
}

.admin-review-actions button[data-review-action="review"] {
  border-color: rgba(139, 213, 255, 0.42);
}

.admin-review-actions button[data-review-action="rejected"] {
  border-color: rgba(255, 107, 134, 0.42);
}

.leaderboard-panel,
.submission-panel {
  padding: 22px;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.panel-head.compact {
  margin-bottom: 16px;
}

.mode-toggle {
  display: inline-flex;
  gap: 10px;
  flex-wrap: wrap;
}

.mode-button {
  min-height: 42px;
  padding: 10px 14px;
  cursor: pointer;
}

.mode-button.is-active {
  color: #090610;
  background: linear-gradient(135deg, var(--blue-soft), var(--pink-soft));
  border-color: transparent;
}

.leaderboard-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.summary-chip {
  padding: 16px;
  background: rgba(10, 9, 18, 0.9);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.summary-chip span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
}

.summary-chip strong {
  font-size: 1.08rem;
}

.leaderboard-table-wrap {
  overflow-x: auto;
}

.leaderboard-table {
  width: 100%;
  border-collapse: collapse;
}

.leaderboard-table th,
.leaderboard-table td {
  padding: 14px 12px;
  border-bottom: 1px solid rgba(110, 98, 168, 0.2);
  text-align: left;
}

.leaderboard-table th {
  color: var(--blue-soft);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.rank-pill,
.proof-pill,
.submission-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
}

.rank-pill {
  color: #06040d;
  background: linear-gradient(135deg, var(--pink-soft), var(--blue-soft));
}

.proof-pill.verified,
.submission-status.verified {
  color: #07140f;
  background: rgba(55, 211, 154, 0.9);
}

.proof-pill.pending,
.submission-status.pending {
  color: #221300;
  background: rgba(255, 204, 102, 0.9);
}

.proof-pill.review,
.submission-status.review {
  color: #0a0b16;
  background: rgba(139, 213, 255, 0.9);
}

.proof-pill.rejected,
.submission-status.rejected {
  color: #22060f;
  background: rgba(255, 107, 134, 0.9);
}

.metric-stack {
  display: grid;
  gap: 14px;
}

.metric-value {
  display: block;
  margin-bottom: 6px;
}

.metric-note {
  margin-bottom: 0;
  line-height: 1.5;
}

.submission-list {
  display: grid;
  gap: 12px;
}

.submission-item {
  padding: 16px;
  background: rgba(10, 9, 18, 0.82);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.submission-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.submission-item strong {
  display: block;
  margin-bottom: 6px;
}

.submission-item p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.5;
}

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

.score-list,
.rules-list ul,
.rules-list ol {
  padding-left: 18px;
}

.score-list li,
.rules-list li {
  margin-bottom: 10px;
  line-height: 1.55;
}

.score-note,
.prize-panel p,
.rules-list p {
  line-height: 1.65;
}

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

.prize-topline {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.prize-topline strong {
  font-size: 1.8rem;
}

.mini-table {
  width: 100%;
  margin-bottom: 16px;
  border-collapse: collapse;
}

.mini-table td {
  padding: 10px 0;
  border-bottom: 1px solid rgba(110, 98, 168, 0.18);
}

.mini-table td:last-child {
  text-align: right;
  color: var(--text);
  font-weight: 700;
}

.rules-list {
  display: grid;
  gap: 12px;
}

details {
  background: rgba(10, 9, 18, 0.84);
  border: 1px solid var(--line);
  border-radius: 8px;
}

summary {
  cursor: pointer;
  padding: 18px 20px;
  color: var(--text);
  font-weight: 800;
}

summary::marker {
  color: var(--pink-soft);
}

details > p,
details > ul,
details > ol,
details > h3 {
  padding: 0 20px;
}

details > p:last-child,
details > ul:last-child,
details > ol:last-child {
  padding-bottom: 20px;
}

details > h3 {
  margin-top: 12px;
  margin-bottom: 8px;
  color: var(--blue-soft);
  font-size: 1rem;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 28px clamp(18px, 4vw, 64px) 40px;
  border-top: 1px solid rgba(110, 98, 168, 0.18);
}

.site-footer a {
  color: var(--pink-soft);
  font-weight: 800;
  text-decoration: none;
}

@media (max-width: 980px) {
  .hero,
  .leaderboard-layout,
  .members-layout,
  .member-submission-shell,
  .score-grid,
  .prize-grid,
  .integration-grid {
    grid-template-columns: 1fr;
  }

  .hero-meta,
  .form-grid,
  .leaderboard-summary,
  .admin-review-grid,
  .admin-toggle-grid {
    grid-template-columns: 1fr;
  }

  .auth-helper-row {
    flex-direction: column;
  }
}

@media (max-width: 840px) {
  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 78px;
    right: 18px;
    left: 18px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px;
    background: rgba(8, 7, 15, 0.98);
    border: 1px solid var(--line);
    border-radius: 8px;
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 14px 12px;
  }

  .panel-head,
  .prize-topline,
  .site-footer,
  .submission-top {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 560px) {
  .hero-actions,
  .mode-toggle,
  .auth-mode-toggle {
    width: 100%;
  }

  .primary-button,
  .secondary-button,
  .mode-button {
    width: 100%;
  }

  .brand-text small {
    font-size: 0.68rem;
  }
}
