/* ============================================================
   GNN Challenge — Interactive Leaderboard Styles
   ============================================================ */

:root {
  --bg: #0d1117;
  --surface: #161b22;
  --border: #30363d;
  --text: #e6edf3;
  --text-muted: #8b949e;
  --accent: #58a6ff;
  --gold: #ffd700;
  --silver: #c0c0c0;
  --bronze: #cd7f32;
  --green: #3fb950;
  --radius: 8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  padding: 2rem 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

/* --- Header --- */

header {
  text-align: center;
  margin-bottom: 2rem;
}

header h1 {
  font-size: 1.8rem;
  font-weight: 700;
}

.subtitle {
  color: var(--text-muted);
  margin-top: .4rem;
}

/* --- Controls --- */

.controls {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.controls label {
  color: var(--text-muted);
  font-size: .9rem;
}

.controls select,
.controls input[type="text"],
.controls input[type="date"] {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: .4rem .7rem;
  font-size: .9rem;
}

.controls input[type="text"] {
  flex: 1;
  min-width: 160px;
}

.controls input[type="date"] {
  width: 140px;
}

/* Column toggle row */

.column-toggles {
  gap: .6rem;
}

.column-toggles .toggle-label {
  color: var(--text-muted);
  font-size: .9rem;
  font-weight: 600;
  margin-right: .3rem;
}

.column-toggles label {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  cursor: pointer;
  font-size: .85rem;
  color: var(--text-muted);
}

.column-toggles input[type="checkbox"] {
  accent-color: var(--accent);
  cursor: pointer;
}

/* --- Table --- */

table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

thead th {
  background: var(--surface);
  text-align: left;
  padding: .7rem .8rem;
  font-size: .85rem;
  color: var(--text-muted);
  border-bottom: 2px solid var(--border);
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

thead th:hover {
  color: var(--accent);
}

thead th.hidden-col,
tbody td.hidden-col {
  display: none;
}

tbody td {
  padding: .55rem .8rem;
  border-bottom: 1px solid var(--border);
  font-variant-numeric: tabular-nums;
  font-size: .9rem;
}

tbody tr:hover {
  background: rgba(88, 166, 255, .06);
}

/* Rank medals */
.rank-1 { color: var(--gold); font-weight: 700; }
.rank-2 { color: var(--silver); font-weight: 700; }
.rank-3 { color: var(--bronze); font-weight: 700; }

/* Highlight primary metric */
.primary-metric {
  color: var(--green);
  font-weight: 600;
}

/* Submission type badges */
.type-badge {
  display: inline-block;
  padding: .15rem .5rem;
  border-radius: 3px;
  font-size: .78rem;
  font-weight: 600;
  text-transform: uppercase;
}
.type-human     { background: #1a3a2a; color: #3fb950; }
.type-llm       { background: #2a1a3a; color: #bc8cff; }
.type-human-llm { background: #3a2a1a; color: #d2a04e; }
.type-baseline  { background: #1a2a3a; color: #58a6ff; }

/* --- Footer --- */

footer {
  margin-top: 2rem;
  text-align: center;
  color: var(--text-muted);
  font-size: .85rem;
}

footer a {
  color: var(--accent);
  text-decoration: none;
}

.meta {
  color: var(--text-muted);
  font-size: .85rem;
  margin-top: .5rem;
}
