:root {
  color-scheme: dark;
  --ink: #110e0d;
  --panel: #1b1512;
  --line: #45322b;
  --paper: #f4e6d1;
  --muted: #c6ab96;
  --gold: #e9ad77;
  --serif: "Palatino Linotype", Palatino, Georgia, serif;
  --ui: "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-padding-top: 1.5rem; }
body { margin: 0; background: var(--ink); color: var(--paper); font: 1rem/1.5 var(--ui); }
a { color: var(--gold); text-underline-offset: .24em; }
a:hover { color: #ffe1b8; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.frame { width: min(100% - 3rem, 72rem); margin-inline: auto; }
.skip { position: absolute; inset: .6rem auto auto .75rem; z-index: 2; padding: .65rem; background: var(--ink); }
.skip:not(:focus) { clip-path: inset(50%); }

.site-bar { background: #120e0d; border-bottom: 1px solid var(--line); }
.masthead { min-height: 4.3rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.wordmark { color: var(--paper); font: bold clamp(.95rem, 2vw, 1.18rem)/1.1 var(--serif); text-decoration: none; }
.wordmark i, h1 i { color: var(--gold); font-weight: normal; }
nav { display: flex; gap: clamp(.9rem, 3vw, 2rem); }
nav a { font-size: .9rem; text-decoration: none; }

.hero {
  min-height: clamp(29rem, 47vw, 40rem);
  display: grid;
  align-items: center;
  background-color: #221611;
  background-image: linear-gradient(90deg, #120c0af5, #140c08b0 34%, transparent 72%),
    linear-gradient(0deg, var(--ink), transparent 28%), url("./war-hounds.webp");
  background-position: center, center, center 54%;
  background-size: cover;
  border-bottom: 1px solid var(--line);
}
.hero-content { padding-block: 4rem; }
.eyebrow { margin: 0 0 .55rem; color: var(--gold); font-size: .83rem; font-weight: 700; letter-spacing: .17em; text-transform: uppercase; }
h1, h2 { margin: 0; font-family: var(--serif); font-weight: 700; }
h1 { max-width: 55rem; font-size: clamp(3.65rem, 8.7vw, 8rem); line-height: .87; letter-spacing: -.055em; text-shadow: 0 2px 24px #180a05; }
h1 i { font-size: .60em; }
.identity { margin: 1.5rem 0; color: #fae8d1; font-weight: 600; }
.identity span { padding-inline: .2rem; color: var(--gold); }
.primary { display: inline-flex; align-items: center; min-height: 3rem; padding: .6rem 1.15rem; border: 1px solid #f3c39a; background: var(--gold); color: #20120d; font-weight: 750; text-decoration: none; }
.primary:hover { color: #20120d; background: #f5c496; }

.roster { padding-block: 3.4rem 4.5rem; }
.roster-heading { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 1rem; margin-bottom: 1.65rem; }
h2 { font-size: clamp(2.45rem, 5vw, 4rem); line-height: 1; letter-spacing: -.04em; }
.sync { margin: 0; color: var(--muted); font-size: .875rem; }
.sync strong { display: block; color: #c4d1a7; }
.sync-stale strong { color: var(--gold); }

.class-list { display: flex; flex-wrap: wrap; gap: .45rem; margin-bottom: 1.3rem; }
.class-chip { display: inline-flex; gap: .65rem; min-height: 2.75rem; align-items: center; padding-inline: .75rem; background: var(--panel); color: var(--paper); border: 1px solid var(--line); }
.class-chip strong { color: var(--gold); }
.class-chip:hover, .class-chip[aria-pressed="true"] { border-color: var(--gold); background: #3a251c; }
.filters { display: grid; grid-template-columns: minmax(11rem, 2fr) minmax(8rem, 1fr) auto; align-items: end; gap: .75rem; }
.filters label { display: grid; gap: .35rem; color: var(--muted); font-size: .9rem; }
.filters input, .filters select, .reset { width: 100%; min-height: 2.75rem; padding: .5rem .75rem; background: var(--panel); color: var(--paper); border: 1px solid var(--line); border-radius: .15rem; }
.reset { background: transparent; color: var(--gold); }
.reset:hover { border-color: var(--gold); }
.result-count { margin: .95rem 0 .5rem; color: var(--muted); font-size: .875rem; }

.table-wrap { border: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; background: #191310; text-align: left; }
thead { background: #281e19; color: var(--muted); }
th, td { padding: .78rem clamp(.55rem, 2.2vw, 1.4rem); border-bottom: 1px solid var(--line); }
thead th { font-size: .85rem; }
tbody tr:last-child > * { border-bottom: 0; }
tbody th { font-weight: 650; overflow-wrap: anywhere; }
tbody th a { color: var(--paper); }
tbody tr:hover { background: #271b15; }
.rank { color: var(--muted); }
.rank-lead { color: var(--gold); font-weight: 700; }
.empty { margin: 0; padding: 1.5rem; background: var(--panel); }
.empty p { margin-top: 0; }
.site-footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 1rem; padding-block: 1.35rem 2.5rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .875rem; }

@media (max-width: 42rem) {
  .frame { width: calc(100% - 2rem); }
  .hero { background-position: center, center, 61% center; }
  .roster { padding-top: 2.6rem; }
  .filters { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .filters label:first-child { grid-column: 1 / -1; }
  th, td { font-size: .875rem; }
}

@media (max-width: 24rem) {
  .identity span { padding-inline: 0; }
  .identity { font-size: .88rem; }
  th, td { padding-inline: .35rem; }
}
