/* =========================================================
   Chase162 Design System
   ========================================================= */

:root {
  --c-navy-950: #041b36;
  --c-navy-900: #07284d;
  --c-navy-850: #0a315e;
  --c-navy-800: #0c3b70;
  --c-navy-700: #12518f;

  --c-red-600: #ed1238;
  --c-red-500: #ff1744;
  --c-red-400: #ff4968;

  --c-blue-500: #1976d2;
  --c-blue-400: #328bea;

  --c-green-600: #0d9b58;
  --c-green-500: #20b86a;

  --c-gold-500: #f6b51b;

  --c-white: #ffffff;
  --c-gray-25: #fbfcfe;
  --c-gray-50: #f7f9fc;
  --c-gray-100: #edf2f7;
  --c-gray-150: #e7edf4;
  --c-gray-200: #dbe4ee;
  --c-gray-300: #c8d4e1;
  --c-gray-500: #74879d;
  --c-gray-600: #596e85;
  --c-gray-700: #3d5066;
  --c-gray-900: #15263a;

  --bg-page: #f6f9fc;
  --bg-card: #ffffff;
  --bg-navbar: #06264b;
  --bg-dark-card: #082c55;

  --text-primary: #08264a;
  --text-secondary: #536980;
  --text-muted: #8494a7;
  --text-inverse: #ffffff;

  --border-light: #dde6ef;
  --border-strong: #c7d3e1;

  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --radius-xl: 24px;

  --shadow-xs: 0 1px 2px rgba(4, 27, 54, 0.05);
  --shadow-sm: 0 4px 14px rgba(4, 27, 54, 0.08);
  --shadow-md: 0 10px 28px rgba(4, 27, 54, 0.12);
  --shadow-lg: 0 20px 50px rgba(4, 27, 54, 0.18);

  /* Desktop content width. 1360px put a roster row and a paragraph of copy 170 characters
     wide, which is past the point where the eye can find the next line. 1180px keeps tables
     and the draft board comfortable while leaving room for the side panel. */
  --container: 1180px;
  --navbar-height: 72px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: 160ms var(--ease-out);
  --transition-normal: 260ms var(--ease-out);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg-page);
  color: var(--text-primary);
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  font-size: 16px;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 20% 0%, rgba(25, 118, 210, 0.06), transparent 26rem),
    var(--bg-page);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

.display,
.page-title,
.hero-title,
.sports-title {
  font-family:
    "Barlow Condensed",
    "Arial Narrow",
    "Roboto Condensed",
    Impact,
    sans-serif;
  /* 900 in a condensed italic face at hero size fills in: the counters close up and the strokes
     merge into a slab. 800 italic is a real loaded weight (see the font link), so the letterforms
     stay genuine instead of being a synthesised oblique of 900. Tracking was already opened up
     from -0.04em, which had been overlapping the glyphs. */
  font-weight: 800;
  letter-spacing: 0.01em;
  line-height: 0.95;
}

.sports-title {
  font-style: italic;
  text-transform: uppercase;
}

.eyebrow {
  color: var(--c-red-500);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.section-title {
  margin: 0;
  font-size: clamp(1.5rem, 2vw, 2.15rem);
  font-weight: 900;
  letter-spacing: -0.03em;
}



.container {
  width: min(calc(100% - 40px), var(--container));
  margin-inline: auto;
}

.page-section {
  padding: 34px 0;
}

.stack-sm { display: grid; gap: 8px; }
.stack-md { display: grid; gap: 16px; }
.stack-lg { display: grid; gap: 24px; }

.site-navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--navbar-height);
  background:
    linear-gradient(
      180deg,
      rgba(7, 40, 77, 0.98),
      rgba(4, 27, 54, 0.98)
    );
  border-bottom: 1px solid rgba(255,255,255,0.12);
  backdrop-filter: blur(14px);
}

.navbar-inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 34px;
}

.brand-logo {
  width: 245px;
  max-height: 50px;
  object-fit: contain;
  flex: none;
}

.nav-links {
  display: flex;
  align-items: stretch;
  height: 100%;
  gap: 8px;
}

.nav-link {
  position: relative;
  display: flex;
  align-items: center;
  padding: 0 14px;
  color: rgba(255,255,255,0.82);
  font-weight: 700;
  font-size: 0.93rem;
  transition:
    color var(--transition-fast),
    background var(--transition-fast);
}

.nav-link:hover {
  color: #fff;
  background: rgba(255,255,255,0.05);
}

.nav-link.is-active {
  color: #fff;
}

.nav-link.is-active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 14px;
  right: 14px;
  height: 3px;
  border-radius: 4px 4px 0 0;
  background: var(--c-red-500);
}

.nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 850;
  line-height: 1;
  transition:
    transform var(--transition-fast),
    box-shadow var(--transition-fast),
    background var(--transition-fast),
    border-color var(--transition-fast);
}

.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--c-red-500), #e50831);
  box-shadow: 0 8px 20px rgba(237, 18, 56, 0.24);
}

.btn-primary:hover {
  box-shadow: 0 12px 28px rgba(237, 18, 56, 0.32);
}

.btn-secondary {
  color: var(--text-primary);
  background: #fff;
  border-color: var(--border-strong);
}

.btn-dark {
  color: #fff;
  background: var(--c-navy-900);
  border-color: rgba(255,255,255,0.14);
}



.card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-xs);
}

.card-hover {
  transition:
    transform var(--transition-normal),
    box-shadow var(--transition-normal),
    border-color var(--transition-normal);
}

.card-hover:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: rgba(25,118,210,0.24);
}



.hero {
  position: relative;
  overflow: hidden;
  min-height: 500px;
  background:
    linear-gradient(
      90deg,
      rgba(255,255,255,0.99) 0%,
      rgba(255,255,255,0.93) 39%,
      rgba(255,255,255,0.1) 68%
    ),
    var(--hero-image, none);
  background-size: cover;
  background-position: center;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 120px;
  background: linear-gradient(transparent, rgba(4,27,54,0.08));
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 2;
  min-height: 500px;
  display: flex;
  align-items: center;
}

.hero-copy {
  width: min(620px, 50%);
  padding: 52px 0;
}

.hero-title {
  margin: 10px 0 18px;
  max-width: 610px;
  font-size: clamp(3.8rem, 6vw, 6.8rem);
  color: var(--c-navy-950);
}



.hero-subtitle {
  max-width: 550px;
  margin: 0 0 26px;
  color: var(--text-secondary);
  font-size: 1.15rem;
  font-weight: 650;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.hero-stats {
  display: flex;
  gap: 38px;
  margin-top: 34px;
}

.hero-stat-value {
  display: block;
  font-size: 1.22rem;
  font-weight: 900;
}

.hero-stat-label {
  color: var(--text-secondary);
  font-size: 0.84rem;
}

.game-banner {
  color: #fff;
  background:
    linear-gradient(90deg, rgba(4,27,54,0.98), rgba(8,44,85,0.82)),
    var(--banner-image, none);
  background-position: center;
  background-size: cover;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.game-banner-inner {
  min-height: 168px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
}

.game-banner-title {
  margin: 6px 0 10px;
  font-size: clamp(2.3rem, 4vw, 4.4rem);
}

.game-banner-title .accent { color: var(--c-red-500); }

.record-number {
  font-family: "Barlow Condensed", "Arial Narrow", Impact, sans-serif;
  font-style: italic;
  font-size: clamp(3.5rem, 7vw, 7.3rem);
  line-height: 0.88;
  letter-spacing: -0.05em;
  font-weight: 900;
}

.record-number .loss { color: var(--c-red-500); }

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metric-card {
  padding: 16px;
  text-align: center;
  background: var(--c-gray-50);
  border-radius: var(--radius-sm);
}

.metric-value {
  display: block;
  color: var(--text-primary);
  font-size: 1.7rem;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.metric-label {
  color: var(--text-secondary);
  font-size: 0.76rem;
  font-weight: 650;
}

/* The candidate list is what the player is choosing from, so it takes the full
   width and the roster summary sits under it. The side-by-side version reserved
   a 360px column beside the list at every desktop width, squeezing the grid into
   three narrow columns and leaving a short sticky roster panel towering over a
   long scrolling list. */
.game-layout {
  display: grid;
  /* Two columns on a desktop: the roster card was capped around 810px inside a 1180px
     container, which left a third of the width empty and pulled the page's weight to the
     left. The candidate grid needs the room more than the single-column stack did. */
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 28px;
  align-items: start;
}
/* The roster comes first: a drafter needs to see which positions are still
   open before choosing from the list below it. */
/* The candidate list leads and the roster sits beside it, so a drafter can check an open
   position without scrolling away from the choices. */
.game-layout > .draft-main { grid-column: 1; grid-row: 1; }
.game-layout > .roster-panel { grid-column: 2; grid-row: 1; }

.roster-panel {
  /* Sticky was for the old two-column layout. Under a long candidate grid it
     would pin the roster to the viewport while the list scrolls past it. */
  position: static;
  padding: 16px;
}

.roster-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.roster-slot {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  min-height: 50px;
  padding: 7px 10px;
  background: var(--c-gray-50);
  border: 1px solid var(--border-light);
  border-radius: 8px;
}

.roster-slot + .roster-slot { margin-top: 6px; }

.roster-pos {
  color: var(--c-navy-900);
  font-size: 0.8rem;
  font-weight: 900;
}

.roster-player { min-width: 0; }

.roster-player strong,
.roster-player small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.roster-player strong { font-size: 0.8rem; }

.roster-player small {
  color: var(--text-muted);
  font-size: 0.67rem;
}

.roster-ovr {
  color: var(--text-primary);
  font-weight: 900;
}

.table-card { overflow: hidden; }

.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th {
  padding: 11px 14px;
  color: var(--text-secondary);
  background: var(--c-gray-100);
  font-size: 0.7rem;
  font-weight: 850;
  letter-spacing: 0.02em;
  text-align: left;
  text-transform: uppercase;
}

.data-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border-light);
}

.data-table tbody tr {
  transition: background var(--transition-fast);
}

.data-table tbody tr:hover { background: #f9fbfd; }

.leaderboard-podium {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 14px;
  align-items: end;
}

.podium-card {
  padding: 20px;
  text-align: center;
}

.podium-card.is-first {
  padding-top: 28px;
  background: linear-gradient(150deg, #fffaf0, #ffe7a5);
  border-color: #f4c54a;
  box-shadow: 0 14px 40px rgba(246,181,27,0.2);
}

.rank-number {
  font-size: 2rem;
  font-weight: 950;
}

.result-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 80% 0%, rgba(246,181,27,0.18), transparent 30%),
    linear-gradient(140deg, #041b36, #0a3768);
}

.result-hero-inner {
  min-height: 410px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 430px;
  align-items: center;
  gap: 32px;
}

.result-tier {
  color: var(--c-gold-500);
  font-size: 1.25rem;
  font-weight: 900;
  text-transform: uppercase;
}

.share-card {
  padding: 20px;
  background: linear-gradient(145deg, #082d56, #031a33);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.tabs {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
}

.tab {
  min-width: 120px;
  padding: 10px 18px;
  border: 0;
  border-right: 1px solid var(--border-strong);
  color: var(--text-primary);
  background: #fff;
  cursor: pointer;
  font-weight: 800;
}

.tab:last-child { border-right: 0; }

.tab.is-active {
  color: #fff;
  background: var(--c-red-500);
}

.field {
  min-height: 42px;
  padding: 0 12px;
  color: var(--text-primary);
  background: #fff;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  outline: none;
  transition:
    border-color var(--transition-fast),
    box-shadow var(--transition-fast);
}

.field:focus {
  border-color: var(--c-blue-500);
  box-shadow: 0 0 0 3px rgba(25,118,210,0.12);
}


.text-green { color: var(--c-green-600); }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.bg-dark { color: #fff; background: var(--c-navy-950); }
.divider { height: 1px; background: var(--border-light); }
.hidden-desktop { display: none !important; }

@media (max-width: 1100px) {
  /* One column, roster first so an open position is visible before the list of choices.
     The explicit placement from the two-column rule has to be undone: grid-column:2 on a
     single-column grid still forces a second track, which is how a phone ended up squeezing
     the candidates into 105px beside a 218px roster. */
  .game-layout { grid-template-columns: minmax(0, 1fr); }
  .game-layout > .roster-panel { grid-column: 1; grid-row: 1; }
  .game-layout > .draft-main { grid-column: 1; grid-row: 2; }
  .roster-panel { position: static; }
  .hero-copy { width: 60%; }
}

@media (max-width: 760px) {
  :root { --navbar-height: 60px; }

  /* Twelve stacked slots pushed the candidate list 800px down the page, so on a phone the
     roster was a full screen of its own before a single player was visible. Two columns and a
     tighter row bring it to about a third of the screen. The slot drops its name line at this
     width because a half-width column cannot carry a name, a position and a button legibly. */
  .roster-panel { padding: 12px; }
  .roster-heading { margin-bottom: 8px; }
  .roster-grid { display:grid; grid-template-columns:repeat(2, minmax(0, 1fr)); gap:6px;
    /* Every slot is the same height whatever it holds. The grid sized each row to its tallest
       card, so a row of two open slots came out shorter than a row holding a player and the column
       visibly jumped down the list. */
    grid-auto-rows:46px; }
  .roster-grid .roster-slot {
    padding:5px 7px; gap:5px; margin-top:0;
    /* Position, name and rating on one line. The second row existed only to hold the add button,
       which is gone, so it left every open slot a row of dead space. */
    grid-template-columns:auto minmax(0, 1fr) auto;
    grid-template-areas:"pos name ovr";
    align-content:center; align-items:center;
  }
  .roster-grid .roster-slot .roster-pos { grid-area:pos; align-self:center; font-size:.72rem; }
  .roster-grid .roster-slot .roster-player { grid-area:name; min-width:0; line-height:1.2; }
  .roster-grid .roster-slot .roster-player strong { display:block; font-size:.78rem;
    white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
  /* The sub-line carries the year and the position's full name. At two columns there is no
     room for it, and the position badge already says the position. */
  .roster-grid .roster-slot .roster-player small { display:none; }
  /* The rating keeps its place on the right of the same line as the name. */
  .roster-grid .roster-slot .roster-ovr { grid-area:ovr; justify-self:end; align-self:center;
    font-size:.78rem; }
  /* An open slot states one thing. It used to read "TBD" with the position's full name underneath,
     and the second line is what made the card taller than its neighbour. */
  .roster-grid .roster-slot .roster-tbd { font-size:.78rem; }
  .roster-panel .metrics-heading { margin-top:12px; }

  /* What sits above the roster costs the drafter a screen and a half before the first
     candidate. The banner keeps its picture and its title but loses height: on a 390px screen
     it was the single largest block between the fold and the choices. The controls stay,
     because a drafter needs them without scrolling back up. */
  .hero-title, .game-banner-title { font-size: 1.6rem; }
  .draft-title { margin-bottom: 10px; padding-bottom: 10px; }
  .draft-title h2 { font-size: 1.2rem; line-height:1.2; }
  .draft-title a { font-size:.85rem; }
  /* The explanatory paragraph sits between the title and the first card and was a quarter of
     the screen by itself. It restates the line above the roster. */
  .draft-main > p { display:none; }
  .respin-control { flex-wrap:wrap; gap:6px; }
  .respin-control .btn { padding:8px 12px; font-size:.82rem; }

  .container {
    width: min(calc(100% - 24px), var(--container));
  }

  .brand-logo { width: 180px; }
  .nav-links { display: none; }

  .hero {
    min-height: auto;
    background:
      linear-gradient(
        180deg,
        rgba(255,255,255,0.98),
        rgba(255,255,255,0.91)
      ),
      var(--hero-image, none);
  }

  .hero-inner { min-height: auto; }

  .hero-copy {
    width: 100%;
    padding: 46px 0;
  }

  .hero-title {
    font-size: clamp(3rem, 16vw, 5rem);
  }

  .hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }

  .leaderboard-podium,
  .metric-grid {
    grid-template-columns: 1fr;
  }

  .game-banner-inner,
  .result-hero-inner {
    grid-template-columns: 1fr;
  }

  .hidden-mobile { display: none !important; }
  .hidden-desktop { display: initial !important; }
}
