:root {
  --bg: #f7f5f0;
  --surface: #ffffff;
  --text: #1d1b18;
  --muted: #5f5a52;
  --line: #e2ddd3;
  --accent: #c2410c;
  --draft-bg: #fff4d6;
  --draft-line: #e8c770;
  --max: 46rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171614;
    --surface: #211f1c;
    --text: #ece8e1;
    --muted: #a9a297;
    --line: #36322c;
    --accent: #fb923c;
    --draft-bg: #3a2f12;
    --draft-line: #7a6326;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  overflow-wrap: anywhere;
}

a { color: var(--accent); }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px;
}

header.site {
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

header.site .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
  text-decoration: none;
}

nav { display: flex; flex-wrap: wrap; gap: 4px 18px; }
nav a { color: var(--muted); text-decoration: none; font-size: 0.95rem; }
nav a:hover, nav a[aria-current="page"] { color: var(--text); text-decoration: underline; }

main { padding: 40px 0 56px; }

h1 { font-size: 2rem; line-height: 1.2; margin: 0 0 12px; }
h2 { font-size: 1.25rem; margin: 36px 0 8px; }
h3 { font-size: 1.05rem; margin: 24px 0 6px; }

.lead { color: var(--muted); font-size: 1.1rem; margin: 0 0 32px; }

.draft {
  background: var(--draft-bg);
  border: 1px solid var(--draft-line);
  border-radius: 8px;
  padding: 10px 14px;
  margin: 0 0 28px;
  font-size: 0.95rem;
}

.games {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 13rem), 1fr));
  gap: 16px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.games li {
  background: var(--surface);
  border: 1px dashed var(--line);
  border-radius: 10px;
  padding: 22px 18px;
  color: var(--muted);
}

.games strong { display: block; color: var(--text); margin-bottom: 4px; }

table { border-collapse: collapse; width: 100%; font-size: 0.95rem; }
.table-scroll { overflow-x: auto; }
th, td { text-align: left; vertical-align: top; padding: 8px 10px; border-bottom: 1px solid var(--line); }
th { font-weight: 600; }

footer.site {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
}

footer.site .wrap { padding-top: 20px; padding-bottom: 28px; }
footer.site p { margin: 4px 0; }
