:root {
  --ink: #f7f5ed;
  --muted: #a9afa6;
  --field: #123d2c;
  --field-deep: #071b14;
  --panel: #10231c;
  --panel-2: #172e25;
  --line: rgba(247, 245, 237, 0.13);
  --lime: #c9ff3d;
  --orange: #ff6b35;
  --gold: #f7c948;
  --danger: #ff5f57;
  --shadow: 0 26px 70px rgba(0, 0, 0, 0.3);
  font-family: "DM Sans", sans-serif;
  color: var(--ink);
  background: var(--field-deep);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 80% 15%, rgba(201, 255, 61, 0.08), transparent 27rem),
    linear-gradient(135deg, #0b241a 0%, #071610 60%, #06130e 100%);
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
}

.grain {
  position: fixed;
  inset: 0;
  opacity: 0.12;
  pointer-events: none;
  z-index: 20;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.22'/%3E%3C/svg%3E");
}

.site-header {
  width: min(1180px, calc(100% - 40px));
  height: 82px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 38px;
  border-bottom: 1px solid var(--line);
}

.brand {
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 900;
  font-size: 31px;
  letter-spacing: -2px;
}

.brand-mark:first-child {
  color: var(--lime);
}

.brand-dash {
  color: var(--muted);
  margin: 0 2px;
}

nav {
  display: flex;
  gap: 24px;
}

.nav-link {
  border: 0;
  padding: 8px 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
}

.nav-link:hover,
.nav-link.active {
  color: var(--ink);
}

.header-tag {
  margin-left: auto;
  color: var(--lime);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.5px;
}

#app {
  width: min(1180px, calc(100% - 40px));
  min-height: calc(100vh - 150px);
  margin: 0 auto;
}

.hero {
  min-height: 690px;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  align-items: center;
  gap: 72px;
  padding: 70px 0;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--lime);
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 3px;
  background: var(--lime);
}

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

h1,
h2,
h3,
.display {
  font-family: "Barlow Condensed", sans-serif;
  text-transform: uppercase;
}

h1 {
  max-width: 720px;
  margin: 18px 0 24px;
  font-size: clamp(68px, 9vw, 126px);
  line-height: 0.79;
  letter-spacing: -5px;
}

h1 span {
  display: block;
  color: var(--lime);
  -webkit-text-stroke: 1px var(--lime);
}

.hero-copy > p {
  max-width: 540px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.65;
}

.format-picker {
  margin-top: 26px;
}

.format-picker > span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}

.format-picker > div {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.format-picker button {
  padding: 13px 15px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 3px;
  background: #1d201e;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
}

.format-picker button strong,
.format-picker button small {
  display: block;
}

.format-picker button strong {
  font-size: 13px;
}

.format-picker button small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.format-picker button:hover,
.format-picker button.active {
  border-color: #63f27b;
}

.format-picker button.active {
  background: rgba(99, 242, 123, 0.1);
  box-shadow: inset 3px 0 #63f27b;
}

.format-picker button.active small {
  color: #9edba8;
}

.mode-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 34px;
}

.game-chips {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mode-button {
  min-height: 116px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: rgba(247, 245, 237, 0.035);
  text-align: left;
  cursor: pointer;
  transition: 180ms ease;
}

.mode-button:hover {
  border-color: var(--lime);
  background: rgba(201, 255, 61, 0.08);
  transform: translateY(-2px);
}

.mode-button strong {
  display: block;
  margin-bottom: 7px;
  font-family: "Barlow Condensed", sans-serif;
  font-size: 25px;
  text-transform: uppercase;
}

.mode-button span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.mode-button.primary {
  background: var(--lime);
  color: #0b1a12;
  border-color: var(--lime);
}

.mode-button.primary span {
  color: #29422d;
}

.stadium-card {
  position: relative;
  min-height: 510px;
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
  background:
    linear-gradient(rgba(8, 34, 24, 0.3), rgba(5, 17, 12, 0.9)),
    repeating-linear-gradient(90deg, transparent 0 48px, rgba(255, 255, 255, 0.08) 49px 50px),
    linear-gradient(160deg, #276644, #0c2d1f);
  box-shadow: var(--shadow);
  transform: rotate(1.5deg);
}

.stadium-card::before,
.stadium-card::after {
  content: "";
  position: absolute;
  left: 10%;
  right: 10%;
  height: 1px;
  background: rgba(255, 255, 255, 0.45);
}

.stadium-card::before {
  top: 23%;
}

.stadium-card::after {
  bottom: 23%;
}

.field-number {
  position: absolute;
  color: rgba(255, 255, 255, 0.18);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 92px;
  font-weight: 900;
}

.field-number.one {
  top: 26px;
  left: 34px;
}

.field-number.two {
  right: 34px;
  bottom: 26px;
  transform: rotate(180deg);
}

.football {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 205px;
  height: 118px;
  border: 4px solid #d2a27c;
  border-radius: 55% 45% 55% 45%;
  background: #7b371e;
  transform: translate(-50%, -50%) rotate(-27deg);
  box-shadow: 0 22px 35px rgba(0, 0, 0, 0.38);
}

.football::after {
  content: "||||||";
  position: absolute;
  top: 37px;
  left: 64px;
  color: #eee1cb;
  font-size: 25px;
  letter-spacing: -5px;
  transform: rotate(90deg);
}

.card-stamp {
  position: absolute;
  right: 22px;
  top: 22px;
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: var(--ink);
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 800;
  letter-spacing: 1px;
}

.card-caption {
  position: absolute;
  left: 26px;
  bottom: 26px;
  max-width: 270px;
  font-family: "Barlow Condensed", sans-serif;
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
  text-transform: uppercase;
}

.game-shell {
  padding: 34px 0 70px;
}

.game-topline,
.draft-head,
.result-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.game-topline {
  margin-bottom: 24px;
}

.round-label {
  color: var(--lime);
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 800;
  letter-spacing: 1.4px;
}

.mode-chip,
.status-chip {
  display: inline-flex;
  align-items: center;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.9px;
  text-transform: uppercase;
}

.game-grid {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 22px;
}

.roster-panel,
.draft-panel,
.rules-card,
.result-card {
  border: 1px solid var(--line);
  background: rgba(16, 35, 28, 0.88);
  box-shadow: var(--shadow);
}

.roster-panel {
  padding: 18px;
}

.panel-kicker {
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}

.roster-slot {
  min-height: 62px;
  margin-bottom: 8px;
  padding: 10px;
  display: grid;
  grid-template-columns: 38px 1fr auto;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
}

.slot-pos {
  color: var(--lime);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 17px;
  font-weight: 900;
}

.slot-name {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.roster-slot.filled .slot-name {
  color: var(--ink);
  font-weight: 700;
}

.slot-score {
  color: var(--gold);
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 800;
}

.draft-panel {
  min-height: 590px;
  padding: 28px;
}

.draft-head h2 {
  margin: 0;
  font-size: clamp(38px, 5vw, 65px);
  line-height: 0.9;
}

.draw-display {
  margin: 28px 0 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.draw-box {
  min-height: 122px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  border: 1px solid var(--line);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.06), transparent);
}

.draw-box small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.draw-box strong {
  font-family: "Barlow Condensed", sans-serif;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1;
  text-transform: uppercase;
}

.reel-box {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.reel-box::before,
.reel-box::after {
  content: "";
  position: absolute;
  z-index: 2;
  left: 0;
  width: 100%;
  height: 26%;
  pointer-events: none;
}

.reel-box::before {
  top: 0;
  background: linear-gradient(to bottom, rgba(16, 19, 16, 0.9), transparent);
}

.reel-box::after {
  bottom: 0;
  background: linear-gradient(to top, rgba(16, 19, 16, 0.9), transparent);
}

.reel-value {
  display: block;
  transform: translateZ(0);
  transition: color 160ms ease, text-shadow 160ms ease;
}

.reel-active {
  border-color: rgba(99, 242, 123, 0.65);
  box-shadow: inset 0 0 28px rgba(99, 242, 123, 0.08);
}

.reel-active .reel-value {
  color: #f6fff7;
  filter: blur(0.45px);
  animation: reel-jolt 90ms linear infinite;
}

.reel-landed {
  border-color: #63f27b;
  animation: reel-lock 420ms ease-out;
}

.reel-landed .reel-value {
  color: #63f27b;
  text-shadow: 0 0 18px rgba(99, 242, 123, 0.28);
}

@keyframes reel-jolt {
  0% { transform: translateY(-5px); opacity: 0.72; }
  50% { transform: translateY(5px); opacity: 1; }
  100% { transform: translateY(-5px); opacity: 0.72; }
}

@keyframes reel-lock {
  0% { transform: scale(1); }
  42% { transform: scale(1.025); box-shadow: inset 0 0 36px rgba(99, 242, 123, 0.2); }
  100% { transform: scale(1); }
}

.spin-zone {
  min-height: 254px;
  display: grid;
  place-items: center;
  border: 1px dashed rgba(247, 245, 237, 0.2);
  background: rgba(0, 0, 0, 0.08);
}

.spin-button,
.solid-button,
.ghost-button {
  border: 0;
  cursor: pointer;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
}

.spin-button {
  width: 166px;
  height: 166px;
  border: 8px solid rgba(201, 255, 61, 0.18);
  border-radius: 50%;
  background: var(--lime);
  color: #0c1b13;
  font-family: "Barlow Condensed", sans-serif;
  font-size: 31px;
  box-shadow: 0 0 0 1px var(--lime), 0 18px 45px rgba(0, 0, 0, 0.32);
  transition: 180ms ease;
}

.spin-button:hover {
  transform: scale(1.035) rotate(-2deg);
}

.spin-button:disabled {
  cursor: wait;
  opacity: 0.78;
  animation: spin-button-pulse 700ms ease-in-out infinite alternate;
}

.draft-panel.is-spinning .player-controls,
.draft-panel.is-spinning .player-toolbar,
.draft-panel.is-spinning .player-grid,
.draft-panel.is-spinning .skip-row {
  pointer-events: none;
  opacity: 0.32;
}

@keyframes spin-button-pulse {
  from { box-shadow: 0 0 0 1px #63f27b, 0 0 12px rgba(99, 242, 123, 0.18); }
  to { box-shadow: 0 0 0 1px #63f27b, 0 0 34px rgba(99, 242, 123, 0.55); }
}

@media (prefers-reduced-motion: reduce) {
  .reel-active .reel-value,
  .reel-landed,
  .spin-button:disabled {
    animation: none;
  }
}

.skip-row {
  margin-top: 14px;
  display: flex;
  justify-content: center;
  gap: 10px;
}

.ghost-button {
  padding: 10px 14px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 11px;
}

.ghost-button:hover:not(:disabled) {
  color: var(--ink);
  border-color: var(--ink);
}

.ghost-button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

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

.player-card {
  position: relative;
  min-height: 170px;
  padding: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  transition: 160ms ease;
}

.player-card:hover:not(:disabled) {
  border-color: var(--lime);
  transform: translateY(-2px);
  background: rgba(201, 255, 61, 0.06);
}

.player-card:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.player-card::after {
  content: attr(data-pos);
  position: absolute;
  right: 5px;
  bottom: -22px;
  color: rgba(255, 255, 255, 0.045);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 104px;
  font-weight: 900;
}

.player-meta {
  color: var(--lime);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.player-card h3 {
  position: relative;
  z-index: 1;
  margin: 8px 0 15px;
  font-size: 28px;
  line-height: 0.95;
}

.stat-line {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  color: var(--muted);
  font-size: 11px;
}

.stat-line strong {
  color: var(--ink);
}

.hidden-stats {
  color: var(--muted);
  font-size: 12px;
  font-style: italic;
}

.pick-hint {
  margin-top: 16px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.position-dialog {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(3, 12, 8, 0.82);
  backdrop-filter: blur(7px);
}

.dialog-card {
  width: min(430px, 100%);
  padding: 28px;
  border: 1px solid var(--lime);
  background: #10231c;
  box-shadow: var(--shadow);
}

.dialog-card h2 {
  margin-bottom: 6px;
  font-size: 44px;
}

.dialog-card p {
  color: var(--muted);
}

.position-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 20px;
}

.solid-button {
  padding: 14px 18px;
  background: var(--lime);
  color: #0b1a12;
}

.solid-button.orange {
  background: var(--orange);
  color: white;
}

.result-wrap {
  padding: 55px 0 80px;
}

.result-card {
  padding: clamp(26px, 5vw, 56px);
}

.record {
  margin: 20px 0 6px;
  color: var(--lime);
  font-family: "Barlow Condensed", sans-serif;
  font-size: clamp(100px, 17vw, 210px);
  font-weight: 900;
  letter-spacing: -8px;
  line-height: 0.75;
}

.result-title {
  margin-bottom: 28px;
  color: var(--muted);
  font-size: 18px;
}

.meter {
  height: 9px;
  margin: 18px 0 34px;
  background: rgba(255, 255, 255, 0.08);
}

.meter > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--orange), var(--gold), var(--lime));
}

.result-roster {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 28px;
}

.result-player {
  padding: 13px;
  border: 1px solid var(--line);
}

.result-player small {
  display: block;
  color: var(--lime);
  font-weight: 800;
}

.result-player strong {
  display: block;
  margin-top: 4px;
  font-family: "Barlow Condensed", sans-serif;
  font-size: 20px;
  text-transform: uppercase;
}

.result-actions {
  display: flex;
  gap: 10px;
}

.rules-page {
  max-width: 850px;
  margin: 0 auto;
  padding: 70px 0 90px;
}

.rules-page h1 {
  font-size: clamp(62px, 10vw, 112px);
}

.rules-intro {
  max-width: 680px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.6;
}

.rules-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 42px;
}

.rules-card {
  padding: 24px;
}

.rules-card .number {
  color: var(--lime);
  font-family: "Barlow Condensed", sans-serif;
  font-size: 36px;
  font-weight: 900;
}

.rules-card h3 {
  margin: 8px 0;
  font-size: 25px;
}

.rules-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 40;
  padding: 13px 17px;
  background: var(--ink);
  color: #0b1a12;
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--shadow);
}

footer {
  width: min(1180px, calc(100% - 40px));
  min-height: 68px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  color: #798078;
  font-size: 11px;
}

@media (max-width: 850px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 26px;
    padding-top: 45px;
  }

  .stadium-card {
    min-height: 390px;
    transform: none;
  }

  .game-grid {
    grid-template-columns: 1fr;
  }

  .roster-panel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .roster-panel .panel-kicker {
    grid-column: 1 / -1;
  }

  .roster-slot {
    margin: 0;
    grid-template-columns: 32px 1fr;
  }

  .slot-score {
    display: none;
  }
}

@media (max-width: 600px) {
  .site-header {
    gap: 20px;
  }

  .header-tag {
    display: none;
  }

  nav {
    margin-left: auto;
    gap: 14px;
  }

  h1 {
    letter-spacing: -3px;
  }

  .mode-grid,
  .player-grid,
  .rules-grid,
  .result-roster {
    grid-template-columns: 1fr;
  }

  .game-topline,
  .draft-head,
  .result-head {
    align-items: flex-start;
  }

  .draft-panel {
    padding: 18px;
  }

  .draw-box {
    min-height: 96px;
    padding: 14px;
  }

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

  .result-actions {
    flex-direction: column;
  }

  footer {
    padding: 18px 0;
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Fixed-height draft workspace */
@media (min-width: 901px) {
  body:has(.game-shell) {
    height: 100vh;
    overflow: hidden;
  }

  body:has(.game-shell) footer {
    display: none;
  }

  .game-shell {
    height: calc(100vh - 78px);
    min-height: 0;
    padding: 0;
    overflow: hidden;
  }

  .game-topline {
    height: 64px;
    min-height: 64px;
    margin: 0;
    padding: 0 max(24px, calc((100vw - 1180px) / 2));
    background: #220029;
    border-bottom: 1px solid rgba(255, 255, 255, 0.13);
  }

  .round-label {
    font-size: 21px;
    letter-spacing: -0.5px;
  }

  .game-grid {
    width: min(1180px, calc(100% - 40px));
    height: calc(100% - 64px);
    padding: 28px 0;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(420px, 0.95fr);
    gap: 34px;
  }

  .draft-panel {
    order: 1;
    min-width: 0;
    height: 100%;
    padding: 0;
    display: flex;
    flex-direction: column;
    background: transparent;
    box-shadow: none;
    overflow: hidden;
  }

  .roster-panel {
    order: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.13);
    background: #2b0034;
  }

  .draft-head {
    min-height: 52px;
  }

  .draft-head h2 {
    font-size: 33px;
    letter-spacing: -1.5px;
  }

  .draft-head .panel-kicker {
    margin-bottom: 3px;
  }

  .draw-display {
    flex: 0 0 auto;
    margin: 12px 0;
    display: flex;
    gap: 9px;
  }

  .draw-box {
    min-height: 58px;
    padding: 10px 14px;
    justify-content: center;
  }

  .draw-box:first-child {
    flex: 1;
  }

  .draw-box:last-child {
    flex: 0 0 132px;
  }

  .draw-box small {
    margin-bottom: 3px;
    font-size: 8px;
  }

  .draw-box strong {
    font-size: 18px;
  }

  .player-toolbar {
    min-height: 42px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #bba9c2;
    font-size: 12px;
  }

  .player-toolbar strong {
    color: #fff;
  }

  .sort-pill {
    padding: 7px 11px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 18px;
    color: #fff;
  }

  .player-grid {
    min-height: 0;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-right: 8px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #7d3489 transparent;
  }

  .player-grid::-webkit-scrollbar {
    width: 6px;
  }

  .player-grid::-webkit-scrollbar-thumb {
    border-radius: 5px;
    background: #7d3489;
  }

  .player-card {
    flex: 0 0 100px;
    min-height: 100px;
    padding: 14px 18px;
    display: grid;
    grid-template-columns: minmax(160px, 1fr) minmax(250px, auto);
    grid-template-rows: auto 1fr;
    align-items: center;
  }

  .player-card .player-meta {
    grid-column: 1;
    align-self: end;
  }

  .player-card h3 {
    grid-column: 1;
    margin: 4px 0 0;
    align-self: start;
    font-size: 20px;
  }

  .player-card .stat-line,
  .player-card .hidden-stats {
    grid-column: 2;
    grid-row: 1 / 3;
    justify-content: flex-end;
    align-self: center;
  }

  .player-card::after {
    right: 10px;
    bottom: -24px;
    font-size: 92px;
  }

  .skip-row {
    flex: 0 0 auto;
    margin-top: 12px;
  }

  .roster-title-row {
    flex: 0 0 66px;
    min-height: 66px;
    background: linear-gradient(100deg, #6f27ff, #1689df);
  }

  .football-field {
    position: relative;
    min-height: 0;
    flex: 1;
    margin: 18px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 10px;
    background:
      linear-gradient(90deg, rgba(4, 245, 255, 0.03), transparent 40%, rgba(111, 39, 255, 0.08)),
      repeating-linear-gradient(90deg, #25002e 0 9.8%, #300039 10% 19.8%);
  }

  .football-field::before {
    content: "";
    position: absolute;
    inset: 7% 6%;
    border: 1px solid rgba(255, 255, 255, 0.24);
  }

  .football-field::after {
    content: "17szn";
    position: absolute;
    top: 50%;
    left: 50%;
    color: rgba(255, 255, 255, 0.055);
    font-size: 84px;
    font-weight: 800;
    transform: translate(-50%, -50%) rotate(-90deg);
  }

  .field-line {
    position: absolute;
    top: 7%;
    bottom: 7%;
    z-index: 1;
    width: 1px;
    border-left: 1px dashed rgba(255, 255, 255, 0.2);
  }

  .line-20 {
    left: 22%;
  }

  .line-40 {
    left: 40%;
  }

  .line-60 {
    left: 60%;
  }

  .line-80 {
    left: 78%;
  }

  .formation-slot {
    position: absolute;
    z-index: 2;
    width: 126px;
    min-height: 72px;
    padding: 9px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: 1px dashed rgba(255, 255, 255, 0.32);
    border-radius: 10px;
    background: rgba(54, 0, 63, 0.88);
    text-align: center;
    transform: translate(-50%, -50%);
  }

  .formation-slot.filled {
    border-style: solid;
    border-color: #04f5ff;
    background: #42064d;
    box-shadow: 0 0 22px rgba(4, 245, 255, 0.08);
  }

  .formation-pos {
    color: #04f5ff;
    font-size: 10px;
    font-weight: 800;
  }

  .formation-slot strong {
    margin: 3px 0;
    overflow: hidden;
    font-size: 12px;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .formation-slot small {
    color: #aa96b1;
    font-size: 9px;
  }

  .formation-qb {
    left: 50%;
    top: 69%;
  }

  .formation-rb {
    left: 50%;
    top: 86%;
  }

  .formation-wr1 {
    left: 17%;
    top: 47%;
  }

  .formation-wr2 {
    left: 83%;
    top: 47%;
  }

  .formation-te {
    left: 36%;
    top: 28%;
  }

  .formation-flex {
    left: 64%;
    top: 28%;
  }

  .spin-zone {
    min-height: 0;
    flex: 1;
  }
}

/* Final EA Sports FC-inspired theme overrides */
:root {
  --ink: #f4f4f0;
  --muted: #a8aaa6;
  --field: #181b19;
  --field-deep: #101310;
  --panel: #191c1a;
  --panel-2: #222522;
  --line: rgba(255, 255, 255, 0.18);
  --lime: #63f27b;
  --orange: #63f27b;
  --gold: #63f27b;
}

body {
  background: #101310;
}

.site-header,
footer {
  background: #171b29;
}

.brand {
  border-color: rgba(255, 255, 255, 0.35);
  border-radius: 4px;
}

.nav-link.active {
  box-shadow: inset 0 -2px #63f27b;
}

.header-tag,
.hero .eyebrow,
.hero h1 span,
.panel-kicker,
.player-meta,
.formation-pos,
.result-player small,
.rules-card .number {
  color: #63f27b;
}

.hero {
  background:
    linear-gradient(90deg, #63f27b 0 8px, transparent 8px),
    linear-gradient(135deg, #181b19 0%, #101310 68%);
}

.hero::after {
  height: 1px;
  background: rgba(255, 255, 255, 0.16);
}

.hero .eyebrow::before {
  background: #63f27b;
}

.mode-button,
.player-card,
.result-player {
  border-color: rgba(255, 255, 255, 0.16);
  border-radius: 3px;
  background: #1d201e;
  box-shadow: none;
}

.mode-button.primary,
.solid-button,
.spin-button {
  border-color: #63f27b;
  border-radius: 3px;
  background: #63f27b;
  color: #101310;
}

.mode-button.primary span {
  color: #2b432f;
}

.mode-button:hover,
.player-card:hover:not(:disabled) {
  border-color: #63f27b;
  background: #242824;
}

.stadium-card {
  border-color: rgba(255, 255, 255, 0.18);
  border-radius: 3px;
  background:
    linear-gradient(rgba(16, 19, 16, 0.15), rgba(16, 19, 16, 0.82)),
    repeating-linear-gradient(90deg, transparent 0 48px, rgba(255, 255, 255, 0.07) 49px 50px),
    linear-gradient(160deg, #26372a, #141814 70%);
}

.card-stamp {
  border-color: #63f27b;
  border-radius: 2px;
  background: #101310;
  color: #63f27b;
}

.game-topline,
.draft-panel,
.roster-panel {
  background: #181b19;
}

.draw-box,
.player-search {
  border-color: rgba(255, 255, 255, 0.18);
  border-radius: 3px;
  background: #202320;
}

.player-search:focus {
  border-color: #63f27b;
}

.position-filters button,
.sort-pill,
.ghost-button {
  border-color: rgba(255, 255, 255, 0.24);
  border-radius: 3px;
}

.position-filters button:hover,
.position-filters button.active {
  border-color: #63f27b;
  background: #63f27b;
  color: #101310;
}

.ghost-button:hover:not(:disabled) {
  border-color: #63f27b;
  color: #63f27b;
}

.player-card::after {
  color: rgba(99, 242, 123, 0.04);
}

.roster-title-row {
  background: #222622;
  border-bottom: 3px solid #63f27b;
}

.roster-title-row .panel-kicker {
  color: #63f27b;
}

.football-field {
  border-color: rgba(255, 255, 255, 0.18);
  border-radius: 2px;
  background:
    linear-gradient(90deg, rgba(99, 242, 123, 0.025), transparent 40%, rgba(99, 242, 123, 0.035)),
    repeating-linear-gradient(90deg, #171a18 0 9.8%, #1d201e 10% 19.8%);
}

.formation-slot {
  border-color: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
  background: rgba(29, 32, 30, 0.94);
}

.formation-slot.filled {
  border-color: #63f27b;
  background: #242824;
}

.spin-zone {
  border-radius: 3px;
  background: linear-gradient(135deg, rgba(99, 242, 123, 0.12), transparent), #1d201e;
}

.dialog-card,
.result-card,
.rules-card {
  border-radius: 3px;
  background: #1b1e1c;
}

.position-dialog {
  background: rgba(10, 12, 10, 0.9);
}

.result-wrap {
  background: #101310;
}

.record {
  color: #63f27b;
}

.meter > span {
  background: #63f27b;
}

.toast {
  border-radius: 2px;
  background: #63f27b;
  color: #101310;
}

@media (min-width: 901px) {
  .draft-panel {
    background: transparent;
  }

  .roster-panel {
    background: #181b19;
  }

  .player-grid {
    scrollbar-color: #63f27b transparent;
  }

  .player-grid::-webkit-scrollbar-thumb {
    background: #63f27b;
  }
}

.player-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.position-filters {
  display: flex;
  gap: 5px;
}

.position-filters button {
  min-width: 38px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 18px;
  background: transparent;
  color: #c7b9cf;
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
}

.position-filters button:hover,
.position-filters button.active {
  border-color: #04f5ff;
  background: #04f5ff;
  color: #17001f;
}

.player-search {
  min-width: 0;
  flex: 1;
  height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 19px;
  outline: 0;
  background: #2b0034;
  color: #fff;
}

.player-search:focus {
  border-color: #04f5ff;
}

.player-search::placeholder {
  color: #9f8ba7;
}

.empty-results {
  padding: 36px 18px;
  border: 1px dashed rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  color: #bba9c2;
  text-align: center;
}

@media (min-width: 901px) {
  .player-controls {
    flex: 0 0 40px;
    margin-top: 2px;
  }
}

@media (max-width: 900px) {
  .player-controls {
    margin: 12px 0 6px;
    flex-wrap: wrap;
  }

  .player-search {
    flex-basis: 100%;
  }
}

/* EA Sports FC ratings-inspired palette */
:root {
  --ink: #f4f4f0;
  --muted: #a8aaa6;
  --field: #181b19;
  --field-deep: #101310;
  --panel: #191c1a;
  --panel-2: #222522;
  --line: rgba(255, 255, 255, 0.18);
  --lime: #63f27b;
  --orange: #63f27b;
  --gold: #63f27b;
  --danger: #ff5f57;
  --shadow: 0 16px 42px rgba(0, 0, 0, 0.28);
}

body {
  background: #101310;
}

.site-header {
  background: #171b29;
}

.site-header::after {
  background: rgba(255, 255, 255, 0.08);
}

.brand {
  border-color: rgba(255, 255, 255, 0.35);
  border-radius: 4px;
}

.nav-link {
  color: #b8bbb7;
}

.nav-link.active {
  box-shadow: inset 0 -2px #63f27b;
}

.header-tag {
  color: #63f27b;
}

.hero {
  background:
    linear-gradient(90deg, rgba(99, 242, 123, 0.96) 0 8px, transparent 8px),
    linear-gradient(135deg, #181b19 0%, #101310 68%);
}

.hero::after {
  height: 1px;
  background: rgba(255, 255, 255, 0.16);
}

.hero .eyebrow,
.hero h1 span {
  color: #63f27b;
}

.hero .eyebrow::before {
  background: #63f27b;
}

.hero-copy > p {
  color: #b8bbb7;
}

.mode-button {
  border-color: rgba(255, 255, 255, 0.18);
  border-radius: 3px;
  background: #1b1e1c;
  box-shadow: none;
}

.mode-button:hover {
  border-color: #63f27b;
  background: #222622;
}

.mode-button span {
  color: #a8aaa6;
}

.mode-button.primary {
  border-color: #63f27b;
  background: #63f27b;
  color: #101310;
}

.mode-button.primary span {
  color: #2b432f;
}

.stadium-card {
  border-color: rgba(255, 255, 255, 0.18);
  border-radius: 3px;
  background:
    linear-gradient(rgba(16, 19, 16, 0.15), rgba(16, 19, 16, 0.82)),
    repeating-linear-gradient(90deg, transparent 0 48px, rgba(255, 255, 255, 0.07) 49px 50px),
    linear-gradient(160deg, #26372a, #141814 70%);
}

.card-stamp {
  border-color: #63f27b;
  border-radius: 2px;
  background: #101310;
  color: #63f27b;
}

.game-topline {
  background: #181b19;
}

.round-label {
  color: #f4f4f0;
}

.mode-chip,
.status-chip {
  border-color: rgba(255, 255, 255, 0.3);
  color: #f4f4f0;
}

.draft-panel,
.roster-panel {
  background: #181b19;
}

.draft-head .panel-kicker,
.panel-kicker {
  color: #63f27b;
}

.draw-box {
  border-color: rgba(255, 255, 255, 0.17);
  border-radius: 3px;
  background: #202320;
}

.player-search {
  border-color: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
  background: #202320;
}

.player-search:focus {
  border-color: #63f27b;
}

.position-filters button {
  border-color: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}

.position-filters button:hover,
.position-filters button.active {
  border-color: #63f27b;
  background: #63f27b;
  color: #101310;
}

.sort-pill,
.ghost-button {
  border-color: rgba(255, 255, 255, 0.25);
  border-radius: 3px;
}

.ghost-button:hover:not(:disabled) {
  border-color: #63f27b;
  color: #63f27b;
}

.player-card {
  border-color: rgba(255, 255, 255, 0.15);
  border-radius: 2px;
  background: #1d201e;
}

.player-card:hover:not(:disabled) {
  border-color: #63f27b;
  background: #242824;
}

.player-meta {
  color: #63f27b;
}

.player-card::after {
  color: rgba(99, 242, 123, 0.04);
}

.roster-title-row {
  background: #222622;
  border-bottom: 3px solid #63f27b;
}

.roster-title-row .panel-kicker {
  color: #63f27b;
}

.football-field {
  border-color: rgba(255, 255, 255, 0.18);
  border-radius: 2px;
  background:
    linear-gradient(90deg, rgba(99, 242, 123, 0.025), transparent 40%, rgba(99, 242, 123, 0.035)),
    repeating-linear-gradient(90deg, #171a18 0 9.8%, #1d201e 10% 19.8%);
}

.football-field::after {
  color: rgba(99, 242, 123, 0.045);
}

.formation-slot {
  border-color: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
  background: rgba(29, 32, 30, 0.94);
}

.formation-slot.filled {
  border-color: #63f27b;
  background: #242824;
  box-shadow: 0 0 18px rgba(99, 242, 123, 0.08);
}

.formation-pos,
.result-player small {
  color: #63f27b;
}

.solid-button {
  border-radius: 3px;
  background: #63f27b;
  color: #101310;
}

.spin-zone {
  border-radius: 3px;
  background:
    linear-gradient(135deg, rgba(99, 242, 123, 0.12), transparent),
    #1d201e;
}

.spin-button {
  border-color: rgba(99, 242, 123, 0.25);
  background: #63f27b;
  color: #101310;
  box-shadow: 0 0 0 1px #63f27b, 0 14px 34px rgba(0, 0, 0, 0.28);
}

.dialog-card,
.result-card,
.rules-card {
  border-radius: 3px;
  background: #1b1e1c;
}

.position-dialog {
  background: rgba(10, 12, 10, 0.9);
}

.result-wrap {
  background: #101310;
}

.record {
  color: #63f27b;
}

.meter > span {
  background: #63f27b;
}

.result-player {
  border-color: rgba(255, 255, 255, 0.15);
  border-radius: 2px;
  background: #202320;
}

.rules-card .number {
  color: #63f27b;
}

.toast {
  border-radius: 2px;
  background: #63f27b;
  color: #101310;
}

footer {
  background: #171b29;
  color: #999d99;
}

@media (min-width: 901px) {
  .game-topline {
    background: #171b19;
  }

  .draft-panel {
    background: transparent;
  }

  .roster-panel {
    border-color: rgba(255, 255, 255, 0.16);
    background: #181b19;
  }

  .player-grid {
    scrollbar-color: #63f27b transparent;
  }

  .player-grid::-webkit-scrollbar-thumb {
    background: #63f27b;
  }
}

@media (max-width: 900px) {
  .player-toolbar {
    margin: 10px 0;
    display: flex;
    justify-content: space-between;
    color: #bba9c2;
    font-size: 12px;
  }

  .football-field {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    padding: 14px;
  }

  .field-line {
    display: none;
  }

  .formation-slot {
    min-height: 70px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 8px;
    background: #2b0034;
    text-align: center;
  }

  .formation-pos {
    color: #04f5ff;
    font-size: 10px;
    font-weight: 800;
  }

  .formation-slot strong {
    margin: 3px 0;
    font-size: 12px;
  }

  .formation-slot small {
    color: #aa96b1;
    font-size: 9px;
  }
}

/* Premier League table-inspired visual system */
:root {
  --ink: #ffffff;
  --muted: #c7b9cf;
  --field: #36003f;
  --field-deep: #17001f;
  --panel: #2b0034;
  --panel-2: #3b0647;
  --line: rgba(255, 255, 255, 0.16);
  --lime: #ffffff;
  --orange: #ff2882;
  --gold: #04f5ff;
  --danger: #ff2882;
  --shadow: 0 16px 42px rgba(10, 0, 15, 0.28);
  font-family: "DM Sans", sans-serif;
}

body {
  background:
    radial-gradient(circle at 90% 8%, rgba(4, 245, 255, 0.09), transparent 22rem),
    linear-gradient(180deg, #17001f 0%, #25002d 100%);
}

.grain {
  display: none;
}

.site-header {
  width: 100%;
  height: 78px;
  padding: 0 max(24px, calc((100vw - 1180px) / 2));
  border: 0;
  background: #100014;
}

.site-header::after {
  content: "";
  position: absolute;
  top: 77px;
  left: 0;
  right: 0;
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
}

.brand {
  min-width: 78px;
  height: 46px;
  display: inline-grid;
  grid-auto-flow: column;
  place-content: center;
  align-items: center;
  border: 1px solid rgba(4, 245, 255, 0.45);
  border-radius: 24px;
  font-family: "DM Sans", sans-serif;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -1px;
}

.brand-mark:first-child,
.brand-dash {
  color: #fff;
}

.nav-link {
  color: #d9cedf;
  font-size: 14px;
  font-weight: 500;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
}

.nav-link.active {
  box-shadow: inset 0 -2px #04f5ff;
}

.header-tag {
  color: #fff;
  font-family: "DM Sans", sans-serif;
  font-weight: 600;
  letter-spacing: 0.5px;
}

#app {
  width: 100%;
  max-width: none;
}

.hero {
  min-height: 710px;
  padding: 74px max(24px, calc((100vw - 1180px) / 2));
  background:
    linear-gradient(120deg, rgba(112, 34, 255, 0.92), rgba(4, 245, 255, 0.82)),
    linear-gradient(180deg, #36003f, #17001f);
  gap: 50px;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 78px 0 auto;
  height: 8px;
  background: linear-gradient(90deg, #ff2882 0 25%, #04f5ff 25% 50%, #963cff 50% 75%, #eaff00 75%);
}

.hero-copy {
  position: relative;
  z-index: 1;
}

.eyebrow {
  color: #fff;
  font-family: "DM Sans", sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
}

.eyebrow::before {
  width: 22px;
  height: 2px;
  background: #fff;
}

h1,
h2,
h3,
.display {
  font-family: "DM Sans", sans-serif;
  text-transform: none;
}

h1 {
  margin: 20px 0 26px;
  font-size: clamp(62px, 8vw, 112px);
  line-height: 0.91;
  letter-spacing: -6px;
}

h1 span {
  color: #fff;
  -webkit-text-stroke: 0;
}

.hero-copy > p {
  color: rgba(255, 255, 255, 0.84);
}

.mode-button {
  min-height: 122px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 12px;
  background: rgba(35, 0, 45, 0.72);
  box-shadow: 0 8px 30px rgba(31, 0, 42, 0.18);
}

.mode-button:hover {
  border-color: #fff;
  background: #36003f;
}

.mode-button strong {
  font-family: "DM Sans", sans-serif;
  font-size: 20px;
  text-transform: none;
}

.mode-button span {
  color: #d9cedf;
}

.mode-button.primary {
  border-color: #fff;
  background: #fff;
  color: #36003f;
}

.mode-button.primary span {
  color: #67516e;
}

.stadium-card {
  min-height: 510px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 14px;
  background:
    linear-gradient(rgba(54, 0, 63, 0.1), rgba(23, 0, 31, 0.82)),
    repeating-linear-gradient(90deg, transparent 0 48px, rgba(255, 255, 255, 0.09) 49px 50px),
    linear-gradient(160deg, #04f5ff, #5d17a6 70%);
  transform: none;
}

.football {
  border-color: #f0b89b;
  background: #8e321b;
}

.card-stamp {
  border-radius: 18px;
  background: rgba(23, 0, 31, 0.5);
  font-family: "DM Sans", sans-serif;
  font-size: 11px;
}

.card-caption {
  font-family: "DM Sans", sans-serif;
  font-size: 24px;
  line-height: 1.1;
  text-transform: none;
}

.game-shell {
  min-height: 760px;
  padding: 0 0 80px;
}

.game-topline {
  min-height: 126px;
  margin: 0 0 30px;
  padding: 42px max(24px, calc((100vw - 1180px) / 2)) 30px;
  background: linear-gradient(110deg, #6f27ff 0%, #04f5ff 100%);
}

.round-label {
  color: #fff;
  font-family: "DM Sans", sans-serif;
  font-size: clamp(29px, 4vw, 48px);
  font-weight: 700;
  letter-spacing: -2px;
}

.mode-chip,
.status-chip {
  padding: 9px 14px;
  border-color: rgba(255, 255, 255, 0.45);
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.game-grid {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.draft-panel {
  order: 1;
  min-height: auto;
  padding: 26px;
  border: 0;
  border-radius: 12px;
  background: #36003f;
}

.roster-panel {
  order: 2;
  padding: 0 0 10px;
  border: 0;
  border-radius: 12px;
  background: #36003f;
  overflow: hidden;
}

.draft-head h2 {
  font-size: clamp(34px, 5vw, 56px);
  letter-spacing: -2.5px;
}

.panel-kicker {
  color: #bba9c2;
  font-weight: 600;
}

.draw-display {
  margin: 24px 0 16px;
}

.draw-box {
  min-height: 106px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  background: #2b0034;
}

.draw-box strong {
  font-family: "DM Sans", sans-serif;
  font-size: clamp(25px, 4vw, 38px);
  line-height: 1.05;
  text-transform: none;
}

.spin-zone {
  min-height: 230px;
  border: 0;
  border-radius: 10px;
  background:
    linear-gradient(120deg, rgba(111, 39, 255, 0.65), rgba(4, 245, 255, 0.36)),
    #2b0034;
}

.spin-button {
  width: 150px;
  height: 150px;
  border: 6px solid rgba(255, 255, 255, 0.24);
  background: #fff;
  color: #36003f;
  font-family: "DM Sans", sans-serif;
  font-size: 23px;
  box-shadow: 0 0 0 1px #fff, 0 14px 34px rgba(0, 0, 0, 0.25);
}

.player-grid {
  gap: 10px;
}

.player-card {
  min-height: 160px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 10px;
  background: #2b0034;
}

.player-card:hover:not(:disabled) {
  border-color: #04f5ff;
  background: #41064b;
}

.player-meta {
  color: #04f5ff;
}

.player-card h3 {
  font-size: 24px;
}

.ghost-button {
  border-color: rgba(255, 255, 255, 0.3);
  border-radius: 22px;
  color: #fff;
  font-weight: 500;
  text-transform: none;
}

.solid-button {
  border-radius: 22px;
  background: #fff;
  color: #36003f;
  text-transform: none;
}

.roster-title-row {
  min-height: 74px;
  padding: 18px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(90deg, #6f27ff, #1b89dd);
}

.roster-title-row .panel-kicker {
  margin-bottom: 2px;
  color: rgba(255, 255, 255, 0.75);
}

.roster-title-row strong {
  font-size: 19px;
}

.roster-title-row > span {
  font-size: 11px;
  font-weight: 700;
}

.roster-columns {
  padding: 13px 22px 8px;
  display: grid;
  grid-template-columns: 70px 1fr 80px;
  color: #ac98b3;
  font-size: 11px;
}

.roster-columns span:last-child {
  text-align: right;
}

.roster-slot {
  min-height: 64px;
  margin: 0 14px;
  padding: 10px 10px;
  grid-template-columns: 60px 1fr 70px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: transparent;
}

.slot-pos {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #4c0a57;
  color: #fff;
  font-family: "DM Sans", sans-serif;
  font-size: 12px;
}

.slot-name {
  font-size: 14px;
}

.slot-score {
  color: #fff;
  font-family: "DM Sans", sans-serif;
  text-align: right;
}

.position-dialog {
  background: rgba(16, 0, 20, 0.88);
}

.dialog-card {
  border: 0;
  border-radius: 14px;
  background: #36003f;
}

.dialog-card h2 {
  font-size: 36px;
}

.result-wrap {
  min-height: 760px;
  padding: 62px max(24px, calc((100vw - 1180px) / 2)) 80px;
  background:
    linear-gradient(110deg, rgba(111, 39, 255, 0.18), rgba(4, 245, 255, 0.09)),
    #17001f;
}

.result-card,
.rules-card {
  border: 0;
  border-radius: 12px;
  background: #36003f;
}

.record {
  color: #fff;
  font-family: "DM Sans", sans-serif;
  letter-spacing: -10px;
}

.meter {
  border-radius: 6px;
  overflow: hidden;
}

.meter > span {
  background: linear-gradient(90deg, #ff2882, #6f27ff, #04f5ff);
}

.result-player {
  border-color: rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: #2b0034;
}

.result-player small {
  color: #04f5ff;
}

.result-player strong {
  font-family: "DM Sans", sans-serif;
  text-transform: none;
}

.rules-page {
  max-width: none;
  padding: 70px max(24px, calc((100vw - 900px) / 2)) 90px;
}

.rules-page h1 {
  letter-spacing: -5px;
}

.rules-card .number {
  color: #04f5ff;
  font-family: "DM Sans", sans-serif;
}

.rules-card h3 {
  font-size: 22px;
}

.toast {
  border-radius: 8px;
  background: #04f5ff;
  color: #17001f;
}

footer {
  width: 100%;
  min-height: 78px;
  padding: 0 max(24px, calc((100vw - 1180px) / 2));
  border-color: rgba(255, 255, 255, 0.12);
  background: #100014;
  color: #a994b0;
}

@media (max-width: 850px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .game-grid {
    display: flex;
  }

  .roster-panel {
    display: block;
  }

  .roster-slot {
    margin: 0 14px;
    grid-template-columns: 60px 1fr 70px;
  }

  .slot-score {
    display: block;
  }
}

@media (max-width: 600px) {
  .site-header {
    padding: 0 18px;
  }

  .brand {
    min-width: 66px;
  }

  .hero {
    padding: 56px 20px;
  }

  h1 {
    font-size: clamp(54px, 17vw, 76px);
    letter-spacing: -4px;
  }

  .game-topline {
    min-height: 112px;
    padding: 36px 20px 24px;
  }

  .round-label {
    font-size: 28px;
    letter-spacing: -1px;
  }

  .game-grid {
    width: calc(100% - 24px);
  }

  .draft-panel {
    padding: 16px;
  }

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

  .roster-columns {
    grid-template-columns: 52px 1fr 62px;
  }

  .roster-slot {
    grid-template-columns: 42px 1fr 62px;
  }

  .result-wrap {
    padding: 42px 12px 70px;
  }
}

/* Final desktop draft layout: one viewport, one scrolling region. */
@media (min-width: 901px) {
  body:has(.game-shell) {
    height: 100vh;
    overflow: hidden;
  }

  body:has(.game-shell) footer {
    display: none;
  }

  .game-shell {
    height: calc(100vh - 78px);
    min-height: 0;
    padding: 0;
    overflow: hidden;
  }

  .game-topline {
    height: 64px;
    min-height: 64px;
    margin: 0;
    padding: 0 max(24px, calc((100vw - 1180px) / 2));
    background: #220029;
    border-bottom: 1px solid rgba(255, 255, 255, 0.13);
  }

  .round-label {
    font-size: 21px;
    letter-spacing: -0.5px;
  }

  .game-grid {
    width: min(1180px, calc(100% - 40px));
    height: calc(100% - 64px);
    margin: 0 auto;
    padding: 24px 0;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(420px, 0.95fr);
    gap: 30px;
  }

  .draft-panel {
    order: 1;
    min-width: 0;
    min-height: 0;
    height: 100%;
    padding: 0;
    display: flex;
    flex-direction: column;
    background: transparent;
    box-shadow: none;
    overflow: hidden;
  }

  .roster-panel {
    order: 2;
    min-height: 0;
    height: 100%;
    padding: 0;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.13);
    background: #2b0034;
  }

  .draft-head {
    min-height: 50px;
  }

  .draft-head h2 {
    font-size: 32px;
    letter-spacing: -1.5px;
  }

  .draw-display {
    flex: 0 0 auto;
    margin: 10px 0;
    display: flex;
    gap: 9px;
  }

  .draw-box {
    min-height: 58px;
    padding: 10px 14px;
    justify-content: center;
  }

  .draw-box:first-child {
    flex: 1;
  }

  .draw-box:last-child {
    flex: 0 0 132px;
  }

  .draw-box small {
    margin-bottom: 3px;
    font-size: 8px;
  }

  .draw-box strong {
    font-size: 18px;
  }

  .player-toolbar {
    flex: 0 0 38px;
  }

  .player-grid {
    min-height: 0;
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-right: 8px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #7d3489 transparent;
  }

  .player-card {
    flex: 0 0 100px;
    min-height: 100px;
    padding: 14px 18px;
    display: grid;
    grid-template-columns: minmax(160px, 1fr) minmax(250px, auto);
    grid-template-rows: auto 1fr;
    align-items: center;
  }

  .player-card .player-meta {
    grid-column: 1;
    align-self: end;
  }

  .player-card h3 {
    grid-column: 1;
    margin: 4px 0 0;
    align-self: start;
    font-size: 20px;
  }

  .player-card .stat-line,
  .player-card .hidden-stats {
    grid-column: 2;
    grid-row: 1 / 3;
    justify-content: flex-end;
    align-self: center;
  }

  .skip-row {
    flex: 0 0 38px;
    margin-top: 8px;
  }

  .roster-title-row {
    flex: 0 0 66px;
    min-height: 66px;
  }

  .football-field {
    min-height: 0;
    flex: 1;
    margin: 18px;
  }

  .spin-zone {
    min-height: 0;
    flex: 1;
  }
}

/* Active color theme */
:root {
  --ink: #f4f4f0;
  --muted: #a8aaa6;
  --field: #181b19;
  --field-deep: #101310;
  --panel: #191c1a;
  --panel-2: #222522;
  --line: rgba(255, 255, 255, 0.18);
  --lime: #63f27b;
  --orange: #63f27b;
  --gold: #63f27b;
}

body { background: #101310; }
.site-header, footer { background: #171b29; }
.brand { border-color: rgba(255,255,255,.35); border-radius: 4px; }
.nav-link.active { box-shadow: inset 0 -2px #63f27b; }
.header-tag, .hero .eyebrow, .hero h1 span, .panel-kicker, .player-meta,
.formation-pos, .result-player small, .rules-card .number { color: #63f27b; }
.hero {
  background:
    linear-gradient(90deg, #63f27b 0 8px, transparent 8px),
    linear-gradient(135deg, #181b19 0%, #101310 68%);
}
.hero::after { height: 1px; background: rgba(255,255,255,.16); }
.hero .eyebrow::before { background: #63f27b; }
.mode-button, .player-card, .result-player {
  border-color: rgba(255,255,255,.16);
  border-radius: 3px;
  background: #1d201e;
  box-shadow: none;
}
.mode-button.primary, .solid-button, .spin-button {
  border-color: #63f27b;
  border-radius: 3px;
  background: #63f27b;
  color: #101310;
}
.mode-button.primary span { color: #2b432f; }
.mode-button:hover, .player-card:hover:not(:disabled) {
  border-color: #63f27b;
  background: #242824;
}
.stadium-card {
  border-color: rgba(255,255,255,.18);
  border-radius: 3px;
  background:
    linear-gradient(rgba(16,19,16,.15), rgba(16,19,16,.82)),
    repeating-linear-gradient(90deg, transparent 0 48px, rgba(255,255,255,.07) 49px 50px),
    linear-gradient(160deg, #26372a, #141814 70%);
}
.card-stamp {
  border-color: #63f27b;
  border-radius: 2px;
  background: #101310;
  color: #63f27b;
}
.game-topline, .draft-panel, .roster-panel { background: #181b19; }
.draw-box, .player-search {
  border-color: rgba(255,255,255,.18);
  border-radius: 3px;
  background: #202320;
}
.player-search:focus { border-color: #63f27b; }
.position-filters button, .sort-pill, .ghost-button {
  border-color: rgba(255,255,255,.24);
  border-radius: 3px;
}
.position-filters button:hover, .position-filters button.active {
  border-color: #63f27b;
  background: #63f27b;
  color: #101310;
}
.ghost-button:hover:not(:disabled) { border-color: #63f27b; color: #63f27b; }
.player-card::after { color: rgba(99,242,123,.04); }
.roster-title-row { background: #222622; border-bottom: 3px solid #63f27b; }
.roster-title-row .panel-kicker { color: #63f27b; }
.football-field {
  border-color: rgba(255,255,255,.18);
  border-radius: 2px;
  background:
    linear-gradient(90deg, rgba(99,242,123,.025), transparent 40%, rgba(99,242,123,.035)),
    repeating-linear-gradient(90deg, #171a18 0 9.8%, #1d201e 10% 19.8%);
}
.formation-slot {
  border-color: rgba(255,255,255,.3);
  border-radius: 3px;
  background: rgba(29,32,30,.94);
}
.formation-slot.filled { border-color: #63f27b; background: #242824; }
.formation-slot.has-chemistry {
  border-color: #f5cf55;
  box-shadow: inset 0 0 0 1px rgba(245, 207, 85, 0.22), 0 0 18px rgba(245, 207, 85, 0.09);
}
.formation-slot.chemistry-legendary { border-color: #f5cf55; }
.formation-slot.chemistry-elite { border-color: #9d8cff; }
.formation-slot.chemistry-proven { border-color: #68c7ff; }
.formation-slot.chemistry-familiar { border-color: #63f27b; }
.chemistry-tag {
  position: absolute;
  right: 6px;
  bottom: 5px;
  padding: 2px 4px;
  border: 1px solid currentColor;
  border-radius: 2px;
  color: #f5cf55;
  background: #171a18;
  font-size: 7px;
  font-weight: 900;
  letter-spacing: 0.4px;
  line-height: 1;
  text-transform: uppercase;
}
.chemistry-summary {
  margin: 22px 0;
  padding: 18px;
  border: 1px solid rgba(245, 207, 85, 0.32);
  background: rgba(245, 207, 85, 0.045);
}
.chemistry-summary-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}
.chemistry-summary-head strong {
  font-size: 13px;
}
.chemistry-connection {
  display: grid;
  grid-template-columns: 82px minmax(180px, 0.8fr) 1fr;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.chemistry-connection > span {
  color: #f5cf55;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.7px;
  text-transform: uppercase;
}
.chemistry-connection > strong {
  font-size: 12px;
}
.chemistry-connection > small {
  color: var(--muted);
  font-size: 10px;
}
.chemistry-connection.chemistry-elite > span { color: #9d8cff; }
.chemistry-connection.chemistry-proven > span { color: #68c7ff; }
.chemistry-connection.chemistry-familiar > span { color: #63f27b; }
@media (max-width: 720px) {
  .chemistry-connection {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
.spin-zone {
  border-radius: 3px;
  background: linear-gradient(135deg, rgba(99,242,123,.12), transparent), #1d201e;
}
.dialog-card, .result-card, .rules-card {
  border-radius: 3px;
  background: #1b1e1c;
}
.position-dialog { background: rgba(10,12,10,.9); }
.result-wrap { background: #101310; }
.record { color: #63f27b; }
.meter > span { background: #63f27b; }
.toast { border-radius: 2px; background: #63f27b; color: #101310; }
@media (min-width: 901px) {
  .draft-panel { background: transparent; }
  .roster-panel { background: #181b19; }
  .player-grid { scrollbar-color: #63f27b transparent; }
  .player-grid::-webkit-scrollbar-thumb { background: #63f27b; }
}

@media (min-width: 901px) {
  .formation-slot {
    width: 108px;
    min-height: 58px;
    padding: 7px;
  }

  .formation-slot strong {
    font-size: 11px;
  }

  .formation-slot small {
    font-size: 8px;
  }

  .formation-db {
    left: 50%;
    top: 9%;
  }

  .formation-lb {
    left: 50%;
    top: 21%;
  }

  .formation-dl {
    left: 50%;
    top: 33%;
  }

  .formation-wr1 {
    left: 14%;
    top: 51%;
  }

  .formation-te {
    left: 34%;
    top: 51%;
  }

  .formation-ol {
    left: 50%;
    top: 53%;
  }

  .formation-flex {
    left: 66%;
    top: 51%;
  }

  .formation-wr2 {
    left: 86%;
    top: 51%;
  }

  .formation-qb {
    left: 50%;
    top: 70%;
  }

  .formation-rb {
    left: 50%;
    top: 86%;
  }
}

/* Football field details */
@media (min-width: 901px) {
  .football-field {
    isolation: isolate;
    background:
      linear-gradient(180deg, rgba(0, 0, 0, 0.22) 0 7%, transparent 7% 93%, rgba(0, 0, 0, 0.22) 93%),
      repeating-linear-gradient(180deg, #18311f 0 10%, #1c3924 10% 20%);
  }

  .football-field::before {
    inset: 5% 7%;
    z-index: 1;
    border: 2px solid rgba(244, 244, 240, 0.58);
  }

  .football-field::after {
    display: none;
  }

  .end-zone {
    position: absolute;
    left: 5%;
    right: 5%;
    z-index: 1;
    height: 7%;
    display: grid;
    place-items: center;
    border-color: rgba(244, 244, 240, 0.38);
    background: rgba(10, 25, 14, 0.72);
    overflow: hidden;
  }

  .end-zone span {
    color: rgba(244, 244, 240, 0.42);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 5px;
    writing-mode: horizontal-tb;
  }

  .end-zone-left {
    top: 0;
    border-bottom: 2px solid rgba(244, 244, 240, 0.58);
  }

  .end-zone-right {
    bottom: 0;
    border-top: 2px solid rgba(244, 244, 240, 0.58);
  }

  .field-line {
    left: 5%;
    right: 5%;
    z-index: 1;
    width: auto;
    height: 1px;
    border: 0;
    border-top: 2px solid rgba(244, 244, 240, 0.42);
  }

  .line-20 {
    top: 25%;
  }

  .line-40 {
    top: 40%;
  }

  .line-60 {
    top: 60%;
  }

  .line-80 {
    top: 75%;
  }

  .hash-row {
    position: absolute;
    top: 8%;
    bottom: 8%;
    z-index: 1;
    width: 16px;
    height: auto;
    background: repeating-linear-gradient(
      180deg,
      transparent 0 3.5%,
      rgba(244, 244, 240, 0.72) 3.5% 3.9%,
      transparent 3.9% 7%
    );
  }

  .hash-row-top {
    top: 8%;
    left: 39%;
  }

  .hash-row-bottom {
    bottom: 8%;
    right: 39%;
  }

  .yard-number {
    position: absolute;
    z-index: 1;
    color: rgba(244, 244, 240, 0.38);
    font-size: 21px;
    font-weight: 800;
    letter-spacing: -2px;
  }

  .yard-20-top {
    left: 14%;
    top: 23%;
  }

  .yard-40-top {
    left: 14%;
    top: 38%;
  }

  .yard-40-bottom {
    right: 14%;
    bottom: 38%;
    transform: rotate(180deg);
  }

  .yard-20-bottom {
    right: 14%;
    bottom: 23%;
    transform: rotate(180deg);
  }

  .midfield-mark {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 1;
    width: 104px;
    height: 104px;
    display: grid;
    place-items: center;
    border: 2px solid rgba(99, 242, 123, 0.28);
    border-radius: 50%;
    background: rgba(16, 19, 16, 0.28);
    transform: translate(-50%, -50%);
  }

  .midfield-mark span {
    color: rgba(99, 242, 123, 0.2);
    font-size: 38px;
    font-weight: 900;
  }

  .formation-slot {
    z-index: 3;
    backdrop-filter: blur(3px);
  }
}

@media (max-width: 900px) {
  .end-zone,
  .hash-row,
  .yard-number,
  .midfield-mark {
    display: none;
  }
}

.player-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.milestone-badge {
  min-width: 27px;
  height: 20px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid currentColor;
  border-radius: 2px;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.6px;
  line-height: 1;
}

.badge-mvp {
  color: #f4cf58;
  background: rgba(244, 207, 88, 0.1);
}

.badge-champion {
  color: #63f27b;
  background: rgba(99, 242, 123, 0.1);
}

.badge-allPro {
  color: #e5e7e5;
  background: rgba(229, 231, 229, 0.08);
}

.badge-proBowl {
  color: #68c7ff;
  background: rgba(104, 199, 255, 0.1);
}

.badge-leader {
  color: #ff9f43;
  background: rgba(255, 159, 67, 0.1);
}

.badge-hof {
  color: #d8a64b;
  background: rgba(216, 166, 75, 0.12);
}

.badge-dpoy {
  color: #ff704d;
  background: rgba(255, 112, 77, 0.12);
}

.player-card > .player-badges {
  position: absolute;
  top: 10px;
  right: 14px;
  z-index: 2;
}

.player-badges.compact {
  position: absolute;
  top: 3px;
  right: 3px;
  gap: 2px;
}

.player-badges.compact .milestone-badge {
  min-width: 14px;
  width: 14px;
  height: 14px;
  padding: 0;
  overflow: hidden;
  font-size: 0;
  border-radius: 50%;
}

.player-badges.compact .milestone-badge::after {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}

.result-player .player-badges {
  margin-top: 10px;
}

.badge-legend {
  margin: 28px 0 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.badge-legend > span {
  padding: 8px 10px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: #1b1e1c;
  color: #b8bbb7;
  font-size: 11px;
}

@media (max-width: 900px) {
  .player-card > .player-badges {
    top: 12px;
    right: 12px;
  }
}

/* Stat-focused interface theme */
:root {
  --ink: #f7f8fa;
  --muted: #a7a9b2;
  --field-deep: #111113;
  --panel: #1b1b1e;
  --panel-2: #222226;
  --line: rgba(255, 255, 255, 0.08);
  --lime: #5bc0d5;
  --orange: #5bc0d5;
  --gold: #f1cf57;
}

body {
  background: #111113;
  color: var(--ink);
}

.grain {
  display: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  width: 100%;
  height: 64px;
  padding: 0 max(16px, calc((100vw - 1120px) / 2));
  gap: 12px;
  border-bottom: 1px solid var(--line);
  background: rgba(17, 17, 19, 0.96);
  backdrop-filter: blur(16px);
}

.brand {
  width: 72px;
  min-width: 72px;
  height: 38px;
  padding: 5px 10px;
  border: 0;
  border-radius: 12px;
  background: #232327;
}

.brand-logo {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.brand-mark:first-child,
.brand-dash {
  color: var(--ink);
}

.site-header nav {
  margin-left: auto;
  gap: 8px;
}

.nav-link {
  padding: 9px 15px;
  border-radius: 999px;
  background: #202024;
  color: #c7c8ce;
  font-size: 12px;
}

.nav-link:hover,
.nav-link.active {
  background: #29292e;
  color: #fff;
  box-shadow: none;
}

.header-tag {
  margin-left: 0;
  padding: 9px 16px;
  border-radius: 999px;
  background: #5bc0d5;
  color: #101113;
  font-family: "DM Sans", sans-serif;
  font-size: 12px;
  letter-spacing: 0;
}

#app {
  width: min(1120px, calc(100% - 28px));
}

.hero {
  min-height: auto;
  padding: 38px 0 58px;
  display: block;
  background: transparent;
}

.hero::after {
  display: none;
}

.hero-copy {
  width: min(760px, 100%);
  margin: 0 auto;
}

.muse-prompt {
  min-height: 58px;
  margin-bottom: 28px;
  padding: 9px 11px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #202024;
  color: #c8c9cf;
  box-shadow: 0 16px 35px rgba(0, 0, 0, 0.18);
}

.muse-prompt-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: #5bc0d5;
  color: #111113;
  font-weight: 900;
}

.muse-prompt-action {
  padding: 9px 13px;
  border-radius: 999px;
  background: #2b2b30;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
}

.hero .eyebrow {
  color: #5bc0d5;
  font-size: 11px;
}

.hero .eyebrow::before {
  background: #5bc0d5;
}

.hero h1 {
  max-width: 720px;
  margin: 16px 0 20px;
  font-size: clamp(50px, 8vw, 88px);
  line-height: 0.94;
  letter-spacing: -5px;
}

.hero h1 span {
  display: inline;
  color: #5bc0d5;
}

.hero-copy > p {
  max-width: 680px;
  color: #b7b8c0;
  font-size: 16px;
  line-height: 1.55;
}

.stadium-card {
  display: none;
}

.format-picker,
.mode-grid {
  margin-top: 20px;
  padding: 10px;
  border-radius: 20px;
  background: #1c1c1f;
}

.format-picker > span {
  margin: 2px 4px 10px;
}

.format-picker > div,
.mode-grid {
  gap: 8px;
}

.format-picker button,
.mode-button {
  min-height: 84px;
  padding: 16px 18px;
  border: 0;
  border-radius: 14px;
  background: #242428;
}

.format-picker button:hover,
.format-picker button.active,
.mode-button:hover {
  border: 0;
  background: #2b2b30;
  box-shadow: none;
  transform: none;
}

.format-picker button.active {
  box-shadow: inset 0 0 0 2px #5bc0d5;
}

.format-picker button.active small {
  color: #9fdde9;
}

.mode-button.primary,
.solid-button,
.spin-button {
  border: 0;
  background: #5bc0d5;
  color: #101113;
}

.mode-button.primary span {
  color: #294c54;
}

.game-shell {
  margin: 24px auto 50px;
}

.game-topline {
  min-height: 54px;
  padding: 8px 10px 8px 18px;
  border: 1px solid var(--line);
  border-radius: 18px 18px 0 0;
  background: #1b1b1e;
}

.mode-chip,
.status-chip,
.sort-pill,
.position-filters button,
.ghost-button {
  border: 0;
  border-radius: 999px;
  background: #27272c;
}

.mode-chip:first-child,
.position-filters button.active,
.position-filters button:hover {
  background: #5bc0d5;
  color: #101113;
}

.game-grid {
  gap: 14px;
}

.draft-panel,
.roster-panel {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #1b1b1e;
  box-shadow: none;
}

.draft-panel {
  padding: 24px;
}

.draft-head h2 {
  font-size: clamp(34px, 5vw, 54px);
  letter-spacing: -3px;
}

.panel-kicker,
.player-meta,
.formation-pos,
.roster-title-row .panel-kicker {
  color: #5bc0d5;
}

.draft-panel .panel-kicker,
.roster-panel .panel-kicker,
.result-card .panel-kicker {
  color: #5bc0d5;
}

.draw-box,
.player-search {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #232327;
}

.draw-box {
  min-height: 96px;
}

.reel-active,
.reel-landed,
.player-search:focus {
  border-color: #5bc0d5;
}

.reel-box {
  box-shadow: none;
}

.reel-landed .reel-value {
  color: #5bc0d5;
  text-shadow: 0 0 18px rgba(91, 192, 213, 0.25);
}

.spin-zone {
  min-height: 210px;
  border-radius: 18px;
  background: #202024;
}

.spin-button {
  width: 136px;
  height: 136px;
  border-radius: 50%;
  box-shadow: 0 0 0 8px rgba(91, 192, 213, 0.12);
}

.player-controls {
  gap: 10px;
}

.position-filters {
  padding: 4px;
  border-radius: 999px;
  background: #222226;
}

.player-card,
.result-player {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #222226;
}

.player-card:hover:not(:disabled) {
  border-color: rgba(91, 192, 213, 0.65);
  background: #29292e;
}

.roster-title-row {
  border-bottom: 1px solid var(--line);
  border-radius: 20px 20px 0 0;
  background: #202024;
}

.football-field {
  border-color: rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background:
    linear-gradient(90deg, rgba(91, 192, 213, 0.03), transparent 45%),
    repeating-linear-gradient(90deg, #18181b 0 9.8%, #1e1e22 10% 19.8%);
}

.formation-slot {
  border-radius: 12px;
  background: rgba(35, 35, 39, 0.96);
}

.formation-slot.filled {
  border-color: #5bc0d5;
  background: #29292e;
}

.rules-page,
.result-card {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #1b1b1e;
}

.rules-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #222226;
}

.record,
.rules-card .number {
  color: #5bc0d5;
}

.meter > span {
  background: #5bc0d5;
}

.toast {
  border-radius: 999px;
  background: #5bc0d5;
  color: #101113;
}

footer {
  border-top: 1px solid var(--line);
  background: #111113;
  color: #777982;
}

@media (max-width: 900px) {
  .site-header {
    padding: 0 14px;
  }

  .header-tag {
    display: inline-flex;
  }

  .hero {
    padding-top: 22px;
  }

  .hero h1 {
    font-size: clamp(48px, 15vw, 72px);
    letter-spacing: -4px;
  }

  .format-picker > div,
  .mode-grid {
    grid-template-columns: 1fr;
  }

  .game-shell {
    margin-top: 14px;
  }
}

@media (max-width: 560px) {
  .site-header nav {
    gap: 4px;
  }

  .nav-link {
    padding: 8px 11px;
  }

  .header-tag {
    padding: 8px 12px;
  }

  .muse-prompt {
    grid-template-columns: auto 1fr;
  }

  .muse-prompt-action {
    display: none;
  }

  .draft-panel {
    padding: 18px 14px;
  }

  .draw-display {
    gap: 8px;
  }
}

/* Persistent light and dark themes */
.theme-toggle {
  min-width: 38px;
  width: 38px;
  height: 38px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  background: #232327;
  color: #f7f8fa;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.theme-toggle:hover {
  background: #303036;
  transform: translateY(-1px);
}

.theme-toggle:focus-visible {
  outline: 2px solid #5bc0d5;
  outline-offset: 2px;
}

.theme-icon {
  width: 15px;
  height: 15px;
  display: inline-block;
  border: 2px solid currentColor;
  border-radius: 50%;
  box-shadow:
    0 -6px 0 -5px currentColor,
    0 6px 0 -5px currentColor,
    6px 0 0 -5px currentColor,
    -6px 0 0 -5px currentColor;
}

[data-theme="light"] {
  --ink: #17181c;
  --muted: #656872;
  --field-deep: #f4f5f7;
  --panel: #ffffff;
  --panel-2: #f0f1f4;
  --line: rgba(20, 24, 32, 0.12);
  --lime: #168ca4;
  --orange: #168ca4;
  --gold: #9a6b00;
  color-scheme: light;
}

[data-theme="light"] body {
  background: #f4f5f7;
  color: var(--ink);
}

[data-theme="light"] .site-header {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 1px 0 rgba(20, 24, 32, 0.04);
}

[data-theme="light"] .brand,
[data-theme="light"] .nav-link,
[data-theme="light"] .theme-toggle {
  background: #eceef1;
  color: #202228;
}

[data-theme="light"] .brand-mark:first-child,
[data-theme="light"] .brand-dash {
  color: #202228;
}

[data-theme="light"] .nav-link:hover,
[data-theme="light"] .nav-link.active,
[data-theme="light"] .theme-toggle:hover {
  background: #dde1e6;
  color: #111216;
}

[data-theme="light"] .header-tag,
[data-theme="light"] .muse-prompt-icon,
[data-theme="light"] .mode-chip:first-child,
[data-theme="light"] .position-filters button.active,
[data-theme="light"] .position-filters button:hover,
[data-theme="light"] .mode-button.primary,
[data-theme="light"] .solid-button,
[data-theme="light"] .spin-button,
[data-theme="light"] .toast {
  background: #168ca4;
  color: #ffffff;
}

[data-theme="light"] .theme-icon {
  border: 0;
  background: currentColor;
  box-shadow: inset -5px -2px 0 #eceef1;
}

[data-theme="light"] .hero h1 span,
[data-theme="light"] .hero .eyebrow,
[data-theme="light"] .panel-kicker,
[data-theme="light"] .player-meta,
[data-theme="light"] .formation-pos,
[data-theme="light"] .record,
[data-theme="light"] .rules-card .number {
  color: #168ca4;
}

[data-theme="light"] .hero .eyebrow::before,
[data-theme="light"] .meter > span {
  background: #168ca4;
}

[data-theme="light"] .hero-copy > p,
[data-theme="light"] .mode-button span,
[data-theme="light"] .format-picker button small,
[data-theme="light"] .dialog-card p,
[data-theme="light"] .player-toolbar,
[data-theme="light"] .hidden-stats,
[data-theme="light"] .chemistry-connection > small {
  color: #656872;
}

[data-theme="light"] .muse-prompt,
[data-theme="light"] .format-picker,
[data-theme="light"] .mode-grid,
[data-theme="light"] .game-topline,
[data-theme="light"] .draft-panel,
[data-theme="light"] .roster-panel,
[data-theme="light"] .rules-page,
[data-theme="light"] .result-card,
[data-theme="light"] .dialog-card {
  border-color: var(--line);
  background: #ffffff;
  color: #17181c;
  box-shadow: 0 16px 42px rgba(24, 31, 42, 0.08);
}

[data-theme="light"] .muse-prompt {
  color: #4e515a;
}

[data-theme="light"] .muse-prompt-action,
[data-theme="light"] .format-picker button,
[data-theme="light"] .mode-button,
[data-theme="light"] .draw-box,
[data-theme="light"] .player-search,
[data-theme="light"] .spin-zone,
[data-theme="light"] .position-filters,
[data-theme="light"] .position-filters button,
[data-theme="light"] .sort-pill,
[data-theme="light"] .mode-chip,
[data-theme="light"] .status-chip,
[data-theme="light"] .ghost-button,
[data-theme="light"] .player-card,
[data-theme="light"] .result-player,
[data-theme="light"] .rules-card,
[data-theme="light"] .roster-title-row,
[data-theme="light"] .chemistry-summary,
[data-theme="light"] .chemistry-connection,
[data-theme="light"] .badge-legend > span {
  border-color: var(--line);
  background: #f0f1f4;
  color: #24262c;
}

[data-theme="light"] .format-picker button:hover,
[data-theme="light"] .format-picker button.active,
[data-theme="light"] .mode-button:hover,
[data-theme="light"] .player-card:hover:not(:disabled),
[data-theme="light"] .ghost-button:hover:not(:disabled) {
  background: #e2e5e9;
  color: #111216;
}

[data-theme="light"] .format-picker button.active {
  box-shadow: inset 0 0 0 2px #168ca4;
}

[data-theme="light"] .format-picker button.active small,
[data-theme="light"] .mode-button.primary span {
  color: #dff8fd;
}

[data-theme="light"] .round-label,
[data-theme="light"] .mode-chip,
[data-theme="light"] .status-chip,
[data-theme="light"] .draw-box strong,
[data-theme="light"] .player-search {
  color: #17181c;
}

[data-theme="light"] .reel-active,
[data-theme="light"] .reel-landed,
[data-theme="light"] .player-search:focus,
[data-theme="light"] .player-card:hover:not(:disabled) {
  border-color: #168ca4;
}

[data-theme="light"] .reel-landed .reel-value {
  color: #168ca4;
  text-shadow: none;
}

[data-theme="light"] .reel-box,
[data-theme="light"] .reel-active,
[data-theme="light"] .reel-landed {
  box-shadow: none;
  animation: none;
}

[data-theme="light"] .reel-box::before,
[data-theme="light"] .reel-box::after {
  display: none;
}

[data-theme="light"] .football-field {
  border-color: rgba(255, 255, 255, 0.5);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(0, 0, 0, 0.05)),
    repeating-linear-gradient(180deg, #397849 0 10%, #438654 10% 20%);
}

[data-theme="light"] .formation-slot {
  border-color: rgba(255, 255, 255, 0.66);
  background: rgba(250, 252, 250, 0.92);
  color: #17181c;
}

[data-theme="light"] .formation-slot.filled {
  border-color: #8fe1f0;
  background: #ffffff;
}

[data-theme="light"] .position-dialog {
  background: rgba(226, 230, 235, 0.88);
}

[data-theme="light"] footer {
  border-color: var(--line);
  background: #e9ebee;
  color: #666a73;
}

[data-theme="light"] .badge-allPro {
  color: #4b4e55;
  background: rgba(75, 78, 85, 0.08);
}

/* Compact mobile draft: keep controls and roster fixed while players scroll. */
@media (max-width: 900px) {
  body:has(.game-shell) {
    height: 100dvh;
    overflow: hidden;
  }

  body:has(.game-shell) footer {
    display: none;
  }

  body:has(.game-shell) .site-header {
    position: fixed;
    inset: 0 0 auto;
    z-index: 50;
    height: 52px;
    padding: 0 12px;
  }

  body:has(.game-shell) #app {
    width: 100%;
    height: 100dvh;
  }

  body:has(.game-shell) .game-shell {
    width: 100%;
    height: 100dvh;
    min-height: 0;
    margin: 0;
    padding: 52px 0 104px;
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow: hidden;
    box-sizing: border-box;
  }

  body:has(.game-shell) .game-topline {
    flex: 0 0 42px;
    min-height: 42px;
    padding: 0 12px;
    border-right: 0;
    border-left: 0;
    border-radius: 0;
  }

  body:has(.game-shell) .round-label {
    font-size: 12px;
  }

  body:has(.game-shell) .mode-chip {
    padding: 6px 9px;
    font-size: 9px;
  }

  body:has(.game-shell) .game-grid {
    width: 100%;
    height: calc(100% - 42px);
    min-height: 0;
    margin: 0;
    display: block;
  }

  body:has(.game-shell) .draft-panel {
    height: 100%;
    min-height: 0;
    padding: 7px 10px 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 0;
    border-radius: 0;
  }

  body:has(.game-shell) .draft-head {
    flex: 0 0 32px;
    min-height: 32px;
  }

  body:has(.game-shell) .draft-head .panel-kicker {
    display: none;
  }

  body:has(.game-shell) .draft-head h2 {
    margin: 0;
    font-size: 19px;
    letter-spacing: -0.5px;
  }

  body:has(.game-shell) .status-chip {
    padding: 5px 8px;
    font-size: 9px;
  }

  body:has(.game-shell) .draw-display {
    flex: 0 0 43px;
    margin: 3px 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 92px;
    gap: 6px;
  }

  body:has(.game-shell) .draw-box {
    min-height: 43px;
    padding: 5px 9px;
    border-radius: 10px;
  }

  body:has(.game-shell) .draw-box small {
    margin-bottom: 0;
    font-size: 7px;
  }

  body:has(.game-shell) .draw-box strong {
    font-size: 13px;
  }

  body:has(.game-shell) .player-controls {
    flex: 0 0 auto;
    margin: 3px 0;
    gap: 6px;
    flex-wrap: nowrap;
  }

  body:has(.game-shell) .position-filters {
    flex: 1 1 auto;
    min-width: 0;
    padding: 3px;
    overflow-x: auto;
    flex-wrap: nowrap;
    white-space: nowrap;
    scrollbar-width: none;
  }

  body:has(.game-shell) .position-filters::-webkit-scrollbar {
    display: none;
  }

  body:has(.game-shell) .position-filters button {
    flex: 0 0 auto;
    padding: 7px 9px;
    font-size: 9px;
  }

  body:has(.game-shell) .player-search {
    flex: 0 0 112px;
    width: 112px;
    min-height: 34px;
    padding: 7px 9px;
    border-radius: 10px;
    font-size: 11px;
  }

  body:has(.game-shell) .player-toolbar {
    flex: 0 0 25px;
    min-height: 25px;
    margin: 0;
    font-size: 9px;
  }

  body:has(.game-shell) .sort-pill {
    display: none;
  }

  body:has(.game-shell) .player-grid {
    flex: 1 1 0;
    min-height: 0;
    padding: 2px 2px 8px;
    gap: 5px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
  }

  body:has(.game-shell) .player-card {
    flex: 0 0 72px;
    min-height: 72px;
    padding: 8px 9px;
    display: grid;
    grid-template-columns: minmax(106px, 0.85fr) 1.15fr;
    grid-template-rows: auto 1fr;
    border-radius: 11px;
    text-align: left;
  }

  body:has(.game-shell) .player-card h3 {
    grid-column: 1;
    align-self: start;
    margin: 2px 0 0;
    font-size: 14px;
    line-height: 1.05;
  }

  body:has(.game-shell) .player-card .player-meta {
    grid-column: 1;
    align-self: end;
    font-size: 8px;
  }

  body:has(.game-shell) .player-card .stat-line,
  body:has(.game-shell) .player-card .hidden-stats {
    grid-column: 2;
    grid-row: 1 / 3;
    align-self: center;
    justify-content: flex-end;
    gap: 7px;
  }

  body:has(.game-shell) .player-card .stat-line span {
    font-size: 7px;
  }

  body:has(.game-shell) .player-card .stat-line strong {
    font-size: 12px;
  }

  body:has(.game-shell) .player-card > .player-badges {
    top: 4px;
    right: 5px;
    transform: scale(0.7);
    transform-origin: top right;
  }

  body:has(.game-shell) .skip-row {
    flex: 0 0 31px;
    margin: 3px 0 4px;
    gap: 5px;
  }

  body:has(.game-shell) .skip-row .ghost-button {
    padding: 6px 8px;
    font-size: 8px;
  }

  body:has(.game-shell) .spin-zone {
    flex: 1 1 0;
    min-height: 0;
  }

  body:has(.game-shell) .spin-button {
    width: 104px;
    height: 104px;
  }

  body:has(.game-shell) .pick-hint {
    margin: 5px;
    font-size: 10px;
  }

  body:has(.game-shell) .roster-panel {
    position: fixed;
    z-index: 40;
    inset: auto 0 0;
    width: 100%;
    height: 104px;
    min-height: 104px;
    overflow: hidden;
    border: 0;
    border-top: 1px solid var(--line);
    border-radius: 0;
    background: color-mix(in srgb, var(--panel) 92%, transparent);
    backdrop-filter: blur(16px);
  }

  body:has(.game-shell) .roster-title-row {
    display: none;
  }

  body:has(.game-shell) .football-field {
    width: 100%;
    height: 100%;
    min-height: 0;
    margin: 0;
    padding: 7px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
    gap: 5px;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: transparent !important;
  }

  body:has(.game-shell) .football-field > :not(.formation-slot) {
    display: none;
  }

  body:has(.game-shell) .formation-slot {
    position: relative !important;
    inset: auto !important;
    width: auto !important;
    height: auto !important;
    min-width: 0;
    padding: 4px 3px;
    transform: none !important;
    border-radius: 9px;
    overflow: hidden;
  }

  body:has(.game-shell) .formation-pos {
    font-size: 8px;
  }

  body:has(.game-shell) .formation-slot strong {
    max-width: 100%;
    font-size: 8px;
    line-height: 1.05;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  body:has(.game-shell) .formation-slot small,
  body:has(.game-shell) .formation-slot .chemistry-tag,
  body:has(.game-shell) .formation-slot .player-badges {
    display: none;
  }
}

@media (max-width: 560px) {
  body:has(.game-shell) .site-header nav {
    display: none;
  }

  body:has(.game-shell) .brand {
    width: 58px;
    min-width: 58px;
    height: 34px;
  }

  body:has(.game-shell) .header-tag {
    margin-left: auto;
    padding: 7px 10px;
    font-size: 9px;
  }

  body:has(.game-shell) .theme-toggle {
    width: 34px;
    min-width: 34px;
    height: 34px;
  }
}

/* Compact desktop draft: one dashboard, with only the player list scrolling. */
@media (min-width: 901px) {
  body:has(.game-shell) .site-header {
    height: 52px;
    padding-inline: max(18px, calc((100vw - 1180px) / 2));
  }

  body:has(.game-shell) .brand {
    width: 62px;
    min-width: 62px;
    height: 34px;
  }

  body:has(.game-shell) .nav-link,
  body:has(.game-shell) .header-tag {
    padding: 7px 12px;
    font-size: 10px;
  }

  body:has(.game-shell) .theme-toggle {
    width: 34px;
    min-width: 34px;
    height: 34px;
  }

  body:has(.game-shell) #app {
    width: 100%;
    max-width: none;
  }

  body:has(.game-shell) .game-shell {
    width: 100%;
    height: calc(100dvh - 52px);
    min-height: 0;
    margin: 0;
    overflow: hidden;
  }

  body:has(.game-shell) .game-topline {
    height: 44px;
    min-height: 44px;
    padding: 0 max(18px, calc((100vw - 1180px) / 2));
    border-right: 0;
    border-left: 0;
    border-radius: 0;
  }

  body:has(.game-shell) .round-label {
    font-size: 14px;
    letter-spacing: -0.2px;
  }

  body:has(.game-shell) .mode-chip {
    padding: 6px 10px;
    font-size: 9px;
  }

  body:has(.game-shell) .game-grid {
    width: min(1180px, calc(100% - 36px));
    height: calc(100% - 44px);
    padding: 18px 0;
    grid-template-columns: minmax(430px, 0.94fr) minmax(500px, 1.06fr);
    gap: 42px;
  }

  body:has(.game-shell) .draft-panel {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  body:has(.game-shell) .draft-head {
    flex: 0 0 35px;
    min-height: 35px;
  }

  body:has(.game-shell) .draft-head .panel-kicker {
    display: none;
  }

  body:has(.game-shell) .draft-head h2 {
    margin: 0;
    font-size: 24px;
    letter-spacing: -0.8px;
  }

  body:has(.game-shell) .status-chip {
    padding: 6px 10px;
    font-size: 9px;
  }

  body:has(.game-shell) .draw-display {
    flex: 0 0 50px;
    min-height: 50px;
    margin: 5px 0;
    gap: 7px;
  }

  body:has(.game-shell) .draw-box {
    min-height: 50px;
    padding: 6px 11px;
    border-radius: 10px;
  }

  body:has(.game-shell) .draw-box:last-child {
    flex-basis: 112px;
  }

  body:has(.game-shell) .draw-box small {
    margin-bottom: 1px;
    font-size: 7px;
  }

  body:has(.game-shell) .draw-box strong {
    font-size: 14px;
  }

  body:has(.game-shell) .player-controls {
    flex: 0 0 36px;
    margin: 4px 0;
    gap: 7px;
    flex-wrap: nowrap;
  }

  body:has(.game-shell) .position-filters {
    min-width: 0;
    padding: 3px;
    flex-wrap: nowrap;
  }

  body:has(.game-shell) .position-filters button {
    padding: 7px 8px;
    font-size: 8px;
  }

  body:has(.game-shell) .player-search {
    flex: 0 0 132px;
    width: 132px;
    min-height: 34px;
    padding: 7px 10px;
    border-radius: 10px;
    font-size: 10px;
  }

  body:has(.game-shell) .player-toolbar {
    flex: 0 0 25px;
    min-height: 25px;
    font-size: 9px;
  }

  body:has(.game-shell) .sort-pill {
    padding: 5px 8px;
    font-size: 8px;
  }

  body:has(.game-shell) .player-grid {
    gap: 5px;
    padding-right: 5px;
  }

  body:has(.game-shell) .player-card {
    flex: 0 0 72px;
    min-height: 72px;
    padding: 8px 11px;
    grid-template-columns: minmax(140px, 0.9fr) minmax(210px, 1.1fr);
    border-radius: 10px;
  }

  body:has(.game-shell) .player-card h3 {
    margin-top: 2px;
    font-size: 15px;
    line-height: 1.05;
  }

  body:has(.game-shell) .player-card .player-meta {
    font-size: 8px;
  }

  body:has(.game-shell) .player-card .stat-line,
  body:has(.game-shell) .player-card .hidden-stats {
    gap: 8px;
  }

  body:has(.game-shell) .player-card .stat-line span {
    font-size: 7px;
  }

  body:has(.game-shell) .player-card .stat-line strong {
    font-size: 12px;
  }

  body:has(.game-shell) .player-card > .player-badges {
    top: 4px;
    right: 5px;
    transform: scale(0.72);
    transform-origin: top right;
  }

  body:has(.game-shell) .skip-row {
    flex: 0 0 31px;
    margin-top: 4px;
    gap: 6px;
  }

  body:has(.game-shell) .skip-row .ghost-button {
    padding: 6px 10px;
    font-size: 8px;
  }

  body:has(.game-shell) .roster-panel {
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  body:has(.game-shell) .roster-title-row {
    display: none;
  }

  body:has(.game-shell) .football-field {
    width: min(100%, 570px);
    min-height: 0;
    margin: 0 auto;
    border-radius: 12px;
  }

  body:has(.game-shell) .formation-slot {
    width: 94px;
    min-height: 50px;
    padding: 5px;
  }

  body:has(.game-shell) .formation-slot strong {
    font-size: 9px;
  }

  body:has(.game-shell) .formation-slot small {
    font-size: 7px;
  }

  body:has(.game-shell) .spin-zone {
    border: 0;
    background: transparent;
  }

  body:has(.game-shell) .spin-button {
    width: 112px;
    height: 112px;
    font-size: 18px;
  }

  body:has(.game-shell) .pick-hint {
    margin: 5px 0 0;
    font-size: 9px;
  }
}

/* Brand lockup and focused home hero. */
.brand {
  width: 116px;
  min-width: 116px;
  padding: 5px 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.brand-logo {
  width: 48px;
  height: auto;
  flex: 0 0 auto;
}

.brand-szn,
.hero-logo-lockup span {
  color: var(--ink);
  font-family: "DM Sans", sans-serif;
  font-style: italic;
  font-weight: 900;
  letter-spacing: -0.09em;
  line-height: 1;
}

.brand-szn {
  font-size: 18px;
}

.hero {
  padding-top: 54px;
}

.hero-copy {
  text-align: center;
}

.hero-brand {
  margin: 0 auto 18px;
  display: grid;
  justify-items: center;
  gap: 12px;
}

.hero-logo-lockup {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
}

.hero-logo-lockup img {
  width: clamp(150px, 22vw, 210px);
  height: auto;
}

.hero-logo-lockup span {
  font-size: clamp(54px, 8vw, 78px);
}

.hero-brand-caption {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.28em;
}

.hero h1 {
  max-width: none;
  margin: 0 0 12px;
  font-size: clamp(32px, 4.2vw, 50px);
  line-height: 1.02;
  letter-spacing: -2.5px;
}

.hero-copy > p {
  max-width: 610px;
  margin: 0 auto;
  font-size: 15px;
}

.hero .format-picker,
.hero .mode-grid {
  text-align: left;
}

/* Flat reels in dark mode. */
[data-theme="dark"] .reel-box,
[data-theme="dark"] .reel-active,
[data-theme="dark"] .reel-landed {
  box-shadow: none;
}

[data-theme="dark"] .reel-box::before,
[data-theme="dark"] .reel-box::after {
  display: none;
}

[data-theme="dark"] .reel-landed .reel-value {
  text-shadow: none;
}

/* Make the two redraw actions easy to find at a glance. */
.skip-row .ghost-button:not(:disabled) {
  border: 1px solid rgba(91, 192, 213, 0.72);
  background: rgba(91, 192, 213, 0.15);
  color: #8fe1f0;
  font-weight: 800;
}

.skip-row .ghost-button:nth-child(2):not(:disabled) {
  border-color: rgba(241, 207, 87, 0.72);
  background: rgba(241, 207, 87, 0.13);
  color: #f1cf57;
}

.skip-row .ghost-button:not(:disabled):hover {
  border-color: #5bc0d5;
  background: #5bc0d5;
  color: #101113;
}

.skip-row .ghost-button:nth-child(2):not(:disabled):hover {
  border-color: #f1cf57;
  background: #f1cf57;
  color: #17130a;
}

[data-theme="light"] .skip-row .ghost-button:not(:disabled) {
  border-color: #168ca4;
  background: rgba(22, 140, 164, 0.12);
  color: #116e80;
}

[data-theme="light"] .skip-row .ghost-button:nth-child(2):not(:disabled) {
  border-color: #9a6b00;
  background: rgba(154, 107, 0, 0.1);
  color: #765200;
}

@media (min-width: 901px) {
  body:has(.game-shell) .brand {
    width: 104px;
    min-width: 104px;
  }

  body:has(.game-shell) .brand-logo {
    width: 43px;
  }

  body:has(.game-shell) .brand-szn {
    font-size: 16px;
  }
}

@media (max-width: 900px) {
  .hero {
    padding-top: 38px;
  }

  .hero-brand {
    margin-bottom: 16px;
  }

  .hero-logo-lockup img {
    width: clamp(120px, 34vw, 160px);
  }

  .hero-logo-lockup span {
    font-size: clamp(44px, 15vw, 60px);
  }

  .hero h1 {
    font-size: clamp(30px, 9vw, 42px);
    letter-spacing: -2px;
  }

  body:has(.game-shell) .brand {
    width: 94px;
    min-width: 94px;
  }

  body:has(.game-shell) .brand-logo {
    width: 38px;
  }

  body:has(.game-shell) .brand-szn {
    font-size: 14px;
  }
}

@media (max-width: 560px) {
  .brand {
    width: 98px;
    min-width: 98px;
  }

  .brand-logo {
    width: 40px;
  }

  .brand-szn {
    font-size: 15px;
  }

  body:has(.game-shell) .brand {
    width: 88px;
    min-width: 88px;
  }

  .hero-brand-caption {
    font-size: 8px;
    letter-spacing: 0.2em;
  }
}

/* Use the supplied logo file exactly, framing its original white canvas. */
.brand {
  position: relative;
  overflow: hidden;
}

.brand .brand-logo {
  position: absolute;
  left: -10px;
  top: 4px;
  width: 137px;
  max-width: none;
  height: auto;
}

.hero-logo-lockup {
  position: relative;
  width: 400px;
  height: 64px;
  overflow: hidden;
}

.hero-logo-lockup img {
  position: absolute;
  left: -81px;
  top: -59px;
  width: 550px;
  max-width: none;
  height: auto;
}

@media (min-width: 901px) {
  body:has(.game-shell) .brand .brand-logo {
    left: -15px;
    top: 5px;
    width: 137px;
  }
}

@media (max-width: 900px) {
  body:has(.game-shell) .brand .brand-logo {
    left: -20px;
    top: 6px;
    width: 137px;
  }
}

@media (max-width: 560px) {
  .hero-logo-lockup {
    width: 300px;
    height: 49px;
  }

  .hero-logo-lockup img {
    left: -61px;
    top: -44px;
    width: 412px;
  }

  body:has(.game-shell) .brand .brand-logo {
    left: -24px;
    top: 7px;
    width: 137px;
  }
}

/* Accounts and leaderboard */
.account-button {
  max-width: 180px;
  padding: 9px 15px;
  overflow: hidden;
  border: 1px solid rgba(91, 192, 213, 0.55);
  border-radius: 999px;
  background: transparent;
  color: #8de4f5;
  font: 700 12px/1 "DM Sans", sans-serif;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}

.account-button:hover,
.account-button.signed-in {
  background: #5bc0d5;
  color: #101113;
}

.auth-overlay {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(5, 6, 9, 0.78);
  backdrop-filter: blur(8px);
}

.auth-card {
  position: relative;
  width: min(440px, 100%);
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #1b1b1e;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

.auth-card h2 {
  margin: 8px 0 6px;
  font-size: 30px;
}

.auth-card > p,
.auth-email {
  margin: 0 0 22px;
  color: var(--muted);
}

.dialog-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: #29292e;
  color: var(--ink);
  font-size: 22px;
  cursor: pointer;
}

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

.auth-form label {
  display: grid;
  gap: 7px;
  color: #c7c8ce;
  font-size: 12px;
  font-weight: 700;
}

.auth-form input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 11px;
  outline: none;
  background: #111113;
  color: var(--ink);
  font: 500 15px/1 "DM Sans", sans-serif;
}

.auth-form input:focus {
  border-color: #5bc0d5;
}

.auth-submit {
  margin-top: 4px;
}

.auth-switch {
  width: 100%;
  margin-top: 18px;
  border: 0;
  background: transparent;
  color: #8de4f5;
  font-weight: 700;
  cursor: pointer;
}

.auth-actions,
.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.form-error {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(244, 91, 105, 0.12);
  color: #ff9aa4;
  font-size: 13px;
}

.leaderboard-submit {
  padding: 12px 18px;
  border: 1px solid #5bc0d5;
  border-radius: 999px;
  background: #5bc0d5;
  color: #101113;
  font-weight: 800;
  cursor: pointer;
}

.leaderboard-submit.submitted {
  opacity: 0.7;
  cursor: default;
}

.leaderboard-page {
  min-height: calc(100vh - 150px);
  padding: 58px 0 80px;
}

.leaderboard-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 34px;
}

.leaderboard-heading h1 {
  margin: 7px 0;
  font-size: clamp(42px, 7vw, 76px);
  letter-spacing: -0.06em;
}

.leaderboard-heading p {
  margin: 0;
  color: var(--muted);
}

.leaderboard-table {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
}

.leaderboard-labels,
.leaderboard-row {
  display: grid;
  grid-template-columns: 64px minmax(180px, 1fr) 130px 130px;
  align-items: center;
}

.leaderboard-labels {
  grid-template-columns: minmax(244px, 1fr) 130px 130px;
  padding: 13px 20px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.leaderboard-labels span:nth-child(n + 2) {
  text-align: right;
}

.leaderboard-row {
  min-height: 76px;
  padding: 12px 20px;
  border-bottom: 1px solid var(--line);
}

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

.leaderboard-rank {
  color: #5bc0d5;
  font-size: 20px;
}

.leaderboard-user {
  display: grid;
  gap: 4px;
}

.leaderboard-user > strong {
  font-size: 17px;
}

.leaderboard-user span,
.leaderboard-impact span,
.leaderboard-record span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.leaderboard-impact,
.leaderboard-record {
  display: grid;
  gap: 2px;
  text-align: right;
}

.leaderboard-impact strong,
.leaderboard-record strong {
  font-size: 21px;
}

.leaderboard-empty {
  padding: 56px 20px;
  color: var(--muted);
  text-align: center;
}

[data-theme="light"] .account-button {
  border-color: #168ca4;
  color: #126f82;
}

[data-theme="light"] .account-button:hover,
[data-theme="light"] .account-button.signed-in {
  background: #168ca4;
  color: #fff;
}

[data-theme="light"] .auth-card,
[data-theme="light"] .leaderboard-table {
  background: #fff;
}

[data-theme="light"] .auth-form input {
  border-color: rgba(20, 24, 32, 0.15);
  background: #f4f5f7;
  color: #202228;
}

[data-theme="light"] .dialog-close {
  background: #eceef1;
  color: #202228;
}

@media (max-width: 720px) {
  .site-header {
    gap: 7px;
  }

  .site-header nav .nav-link[data-action="rules"] {
    display: none;
  }

  .account-button {
    max-width: 116px;
    padding-inline: 11px;
  }

  .leaderboard-page {
    padding-top: 30px;
  }

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

  .leaderboard-labels {
    display: none;
  }

  .leaderboard-row {
    grid-template-columns: 34px minmax(110px, 1fr) 72px 68px;
    min-height: 70px;
    padding: 10px 12px;
  }

  .leaderboard-impact strong,
  .leaderboard-record strong {
    font-size: 17px;
  }
}

@media (max-width: 560px) {
  .site-header nav {
    margin-left: auto;
  }

  .site-header nav .nav-link[data-action="home"] {
    display: none;
  }

  .site-header nav .nav-link[data-action="leaderboard"] {
    padding-inline: 9px;
    font-size: 0;
  }

  .site-header nav .nav-link[data-action="leaderboard"]::after {
    content: "Ranks";
    font-size: 11px;
  }

  .account-button {
    max-width: 92px;
    font-size: 11px;
  }

  .auth-card {
    padding: 28px 20px 22px;
  }
}
