/* THE DRAW DESK — shared design system for stat pages */
:root {
    --ink: #070a10;
    --ink-2: #0a0e15;
    --panel: #0d1320;
    --panel-2: #111a2a;
    --line: #1b2536;
    --line-2: #263247;
    --text: #edf1f8;
    --muted: #9caabf;
    --faint: #71809a;
    --red: #ff3344;
    --red-deep: #c8102e;
    --red-glow: rgba(255, 51, 68, 0.35);
    --gold: #ffc220;
    --gold-soft: #ffd35e;
    --gold-glow: rgba(255, 194, 32, 0.28);
    --mint: #3ddc97;
    --ice: #5aa7ff;
    --display: 'Anton', 'Arial Narrow', sans-serif;
    --cond: 'Barlow Condensed', 'Arial Narrow', sans-serif;
    --mono: 'IBM Plex Mono', 'Menlo', monospace;
    --body: 'Barlow', 'Helvetica Neue', sans-serif;
    --radius: 10px;
}

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

body {
    font-family: var(--body);
    background-color: var(--ink);
    background-image:
        radial-gradient(1100px 480px at 50% -120px, rgba(200, 16, 46, 0.14), transparent 70%),
        repeating-linear-gradient(0deg, rgba(120, 150, 200, 0.035) 0 1px, transparent 1px 56px),
        repeating-linear-gradient(90deg, rgba(120, 150, 200, 0.035) 0 1px, transparent 1px 56px);
    color: var(--text);
    font-size: 15px; line-height: 1.6; min-height: 100vh;
}

::selection { background: var(--red); color: #fff; }
a { color: var(--gold); }

.sr-only {
    position: absolute; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* top bar */
.topbar {
    position: sticky; top: 0; z-index: 200; height: 58px;
    background: rgba(7, 10, 16, 0.92); backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 1.25rem; gap: 1rem;
}
.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand-ball {
    width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0;
    background: radial-gradient(circle at 35% 30%, #ff7a7a, var(--red-deep));
    box-shadow: 0 0 14px var(--red-glow), inset 0 -3px 5px rgba(0,0,0,0.35);
}
.brand strong {
    font-family: var(--display); font-weight: 400; font-size: 1.35rem;
    letter-spacing: 0.06em; color: var(--text); text-transform: uppercase;
}
.brand strong em { font-style: normal; color: var(--red); }
.nav-links { display: flex; gap: 1.25rem; }
.nav-links a {
    font-family: var(--cond); font-weight: 600; font-size: 0.85rem;
    letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--muted); text-decoration: none;
}
.nav-links a:hover { color: var(--gold); }

main { max-width: 980px; margin: 0 auto; padding: 2.25rem 1.25rem 4rem; }

/* breadcrumbs */
.crumbs {
    font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.06em;
    color: var(--faint); margin-bottom: 1.25rem;
}
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--gold); }

/* page heading */
.kicker {
    display: inline-block; font-family: var(--mono); font-size: 0.66rem;
    letter-spacing: 0.22em; text-transform: uppercase; color: var(--red);
    border: 1px solid rgba(255,51,68,0.4); border-radius: 4px;
    padding: 0.3rem 0.7rem; margin-bottom: 0.9rem;
}
h1 {
    font-family: var(--display); font-weight: 400;
    font-size: clamp(1.8rem, 4.5vw, 2.8rem); line-height: 1.08;
    letter-spacing: 0.03em; text-transform: uppercase; margin-bottom: 0.6rem;
}
h1 em { font-style: normal; color: var(--gold); text-shadow: 0 0 24px var(--gold-glow); }
.lede { color: var(--muted); font-size: 1rem; max-width: 720px; margin-bottom: 1.5rem; }

/* panels */
.panel {
    background: linear-gradient(180deg, var(--panel-2), var(--panel));
    border: 1px solid var(--line); border-radius: var(--radius);
    padding: 1.4rem; margin-top: 1.25rem;
}
.panel-label {
    font-family: var(--cond); font-weight: 600; font-size: 0.78rem;
    letter-spacing: 0.3em; text-transform: uppercase; color: var(--faint);
    display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.9rem;
}
.panel-label::before { content: ''; width: 8px; height: 8px; background: var(--red); flex-shrink: 0; }

/* balls */
.balls { display: flex; gap: 0.55rem; flex-wrap: wrap; align-items: center; }
.ball {
    width: 52px; height: 52px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-family: var(--mono); font-weight: 600; font-size: 1.15rem;
    background: radial-gradient(circle at 35% 28%, #ffffff, #c9d2e0 72%);
    color: #0d1320; text-decoration: none;
    box-shadow: inset 0 -4px 8px rgba(0,0,0,0.28), 0 3px 10px rgba(0,0,0,0.5);
}
.ball.pb {
    background: radial-gradient(circle at 35% 28%, #ff8585, var(--red-deep) 75%);
    color: #fff;
    box-shadow: inset 0 -4px 8px rgba(0,0,0,0.35), 0 3px 10px rgba(0,0,0,0.5), 0 0 18px var(--red-glow);
}
a.ball:hover { outline: 2px solid var(--gold); }
.ball.sm { width: 36px; height: 36px; font-size: 0.85rem; }
.ball.hero { width: 84px; height: 84px; font-size: 2rem; }

.mult-chip {
    display: inline-block; margin-top: 0.7rem; font-family: var(--mono);
    font-size: 0.74rem; color: var(--gold); border: 1px solid rgba(255,194,32,0.35);
    border-radius: 4px; padding: 0.15rem 0.5rem; letter-spacing: 0.1em;
}

/* stat grid */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0.75rem; }
.stat-cell { background: rgba(0,0,0,0.3); border: 1px solid var(--line); border-radius: 8px; padding: 0.85rem 1rem; }
.stat-cell small {
    display: block; font-family: var(--cond); font-weight: 600; font-size: 0.7rem;
    letter-spacing: 0.2em; text-transform: uppercase; color: var(--faint); margin-bottom: 0.25rem;
}
.stat-cell b { font-family: var(--mono); font-size: 1.2rem; font-weight: 600; color: var(--text); }
.stat-cell b.gold { color: var(--gold); }
.stat-cell b.red { color: var(--red); }
.stat-cell b.mint { color: var(--mint); }
.stat-cell b em { font-style: normal; font-size: 0.72rem; color: var(--muted); font-weight: 400; }

/* key-value rows */
.krows { display: grid; gap: 0.4rem; }
.krow { display: flex; justify-content: space-between; align-items: baseline; font-size: 0.86rem; border-bottom: 1px dashed var(--line); padding-bottom: 0.4rem; }
.krow small { font-family: var(--cond); font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; font-size: 0.74rem; color: var(--faint); }
.krow span { font-family: var(--mono); font-size: 0.84rem; color: var(--text); }

/* table */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-family: var(--mono); font-size: 0.88rem; }
thead th {
    font-family: var(--cond); font-weight: 700; font-size: 0.8rem;
    letter-spacing: 0.22em; text-transform: uppercase; color: var(--faint);
    text-align: left; padding: 0.6rem 0.9rem; border-bottom: 1px solid var(--line-2); white-space: nowrap;
}
tbody td { padding: 0.55rem 0.9rem; border-bottom: 1px solid var(--line); color: var(--text); white-space: nowrap; }
tbody tr:hover td { background: rgba(255, 194, 32, 0.035); }
td.wb span { display: inline-block; min-width: 2ch; margin-right: 0.7rem; }
td.pbcell { color: var(--red); font-weight: 700; }
td.multcell { color: var(--gold); }
td.datecell a { color: var(--muted); text-decoration: none; }
td.datecell a:hover { color: var(--gold); }

/* prev / next pager */
.pn { display: flex; justify-content: space-between; gap: 1rem; margin-top: 1.5rem; flex-wrap: wrap; }
.pn a {
    font-family: var(--cond); font-weight: 600; font-size: 0.85rem;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--muted); text-decoration: none;
    border: 1px solid var(--line-2); border-radius: 7px; padding: 0.6rem 1rem;
}
.pn a:hover { border-color: var(--gold); color: var(--gold); }
.pn a b { color: var(--text); font-family: var(--mono); font-weight: 600; font-size: 0.8rem; display: block; letter-spacing: 0.04em; }

/* number link grids (archive of balls) */
.numgrid { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.numgrid a {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 44px; height: 38px; padding: 0 0.5rem;
    font-family: var(--mono); font-size: 0.84rem; color: var(--text); text-decoration: none;
    background: rgba(0,0,0,0.3); border: 1px solid var(--line-2); border-radius: 6px;
}
.numgrid a:hover { border-color: var(--gold); color: var(--gold); }

/* year sections on archive */
.year-h {
    font-family: var(--display); font-weight: 400; font-size: 1.5rem;
    letter-spacing: 0.05em; color: var(--gold); margin: 2rem 0 0.5rem;
    display: flex; align-items: baseline; gap: 0.9rem;
}
.year-h small { font-family: var(--mono); font-size: 0.72rem; color: var(--faint); letter-spacing: 0.1em; }

.cta {
    display: inline-flex; align-items: center; gap: 0.5rem;
    font-family: var(--cond); font-weight: 700; font-size: 0.95rem;
    letter-spacing: 0.18em; text-transform: uppercase;
    background: var(--red-deep); color: #fff; text-decoration: none;
    border: 1px solid #e8243d; border-radius: 7px; padding: 0.75rem 1.4rem;
    transition: transform 0.12s, box-shadow 0.2s, background 0.2s;
}
.cta:hover { background: var(--red); box-shadow: 0 4px 22px var(--red-glow); transform: translateY(-1px); }

/* footer */
footer {
    border-top: 1px solid var(--line); background: var(--ink-2);
    padding: 2rem 1.25rem 3rem; text-align: center;
    color: var(--muted); font-size: 0.85rem;
}
footer nav { margin: 0.8rem 0; display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; justify-content: center; }
footer nav a {
    font-family: var(--cond); font-weight: 600; font-size: 0.8rem;
    letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--muted); text-decoration: none;
}
footer nav a:hover { color: var(--gold); }
.disclaimer { font-size: 0.72rem; color: var(--faint); max-width: 720px; margin: 1.25rem auto 0; line-height: 1.6; }

@media (max-width: 640px) {
    .ball { width: 44px; height: 44px; font-size: 0.95rem; }
    .ball.hero { width: 64px; height: 64px; font-size: 1.5rem; }
}
