:root {
  --bg: #0d0d0d;
  --surface: #1a1a1a;
  --surface2: #242424;
  --border: #2e2e2e;
  --accent: #e63946;
  --accent-hover: #c1121f;
  --text: #f0f0f0;
  --text-muted: #888;
  --better: #51cf66;
  --worse: #ff6b6b;
  --blue: #74c0fc;
  --orange: #ffa94d;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 18px; }
body { background: var(--bg); color: var(--text); font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; line-height: 1.5; min-height: 100vh; }
a { color: inherit; text-decoration: none; }

/* ─── Header ────────────────────────────────────────────────── */
header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.7rem 1.75rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  position: sticky; top: 0; z-index: 50;
}
.header-left { display: flex; align-items: center; gap: 2rem; }
.logo-group { display: flex; flex-direction: column; gap: 0; align-items: flex-start; }
.logo { display: flex; align-items: center; gap: 0; font-size: 1.5rem; font-weight: 800; color: var(--text); letter-spacing: -1px; line-height: 1; font-family: 'Barlow Condensed', 'DM Sans', sans-serif; }
.logo-icon { width: 30px; height: 30px; border-radius: 6px; flex-shrink: 0; margin-left: 0.45rem; }
.logo-iq { color: var(--accent); }
.logo-tagline { font-size: 0.62rem; color: var(--text-muted); letter-spacing: 0.02em; line-height: 1; font-family: 'DM Sans', sans-serif; font-weight: 400; font-style: italic; margin-top: 1px; }
.site-nav { display: flex; gap: 0.125rem; }
.nav-link { font-size: 0.8rem; color: var(--text-muted); padding: 0.3rem 0.65rem; border-radius: 4px; transition: color 0.15s; }
.nav-link:hover { color: var(--text); }
.nav-link.active { color: var(--text); background: var(--surface2); }
.nav-link.dim { opacity: 0.35; cursor: not-allowed; }
.header-actions { display: flex; align-items: center; gap: 0.5rem; }
.user-email { color: var(--text-muted); font-size: 0.78rem; margin-right: 0.25rem; }

/* ─── Buttons ──────────────────────────────────────────────── */
button { cursor: pointer; border: none; font-family: inherit; }
.btn { border-radius: 4px; font-size: 0.8rem; font-weight: 500; padding: 0.4rem 0.85rem; transition: background 0.15s, border-color 0.15s; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { background: transparent; color: var(--text-muted); border: 1px solid var(--border); }
.btn-ghost:hover { color: var(--text); border-color: #555; }
button:disabled { opacity: 0.4; cursor: not-allowed; }

/* ─── Layout ───────────────────────────────────────────────── */
main { max-width: 1100px; margin: 0 auto; padding: 2rem 1.75rem; }
.loader { text-align: center; padding: 5rem 2rem; }
.spinner-wordmark {
  font-size: 1.5rem; font-weight: 800; letter-spacing: -1px;
  font-family: 'Barlow Condensed', 'DM Sans', sans-serif;
  color: var(--text); margin-bottom: 1.5rem;
}
.spinner-wordmark span { color: var(--accent); }
.spinner-ring {
  width: 44px; height: 44px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
  margin: 0 auto 1.25rem;
}
@keyframes spin { to { transform: rotate(360deg); } }
.spinner-text { font-size: 0.75rem; color: var(--text-muted); letter-spacing: 0.04em; }
.empty-state { text-align: center; padding: 4rem 2rem; color: var(--text-muted); }
.empty-state h2 { font-size: 1.1rem; color: var(--text); margin-bottom: 0.5rem; }

/* ─── Event hero ───────────────────────────────────────────── */
.event-eyebrow { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--accent); margin-bottom: 0.25rem; }
.event-name { font-size: 1.85rem; font-weight: 800; line-height: 1.15; margin-bottom: 0.25rem; font-family: 'Barlow Condensed', sans-serif; letter-spacing: 0.02em; }
.event-meta { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 1.1rem; }
.event-meta span + span::before { content: ' · '; }

/* ─── Countdown ─────────────────────────────────────────────── */
.countdown-row { display: flex; gap: 0.6rem; margin-bottom: 1.5rem; }
.countdown-box { background: var(--surface); border: 1px solid var(--border); border-radius: 6px; padding: 0.6rem 1rem; text-align: center; min-width: 62px; }
.countdown-num { font-size: 1.4rem; font-weight: 800; line-height: 1; color: var(--accent); font-family: 'Barlow Condensed', sans-serif; }
.countdown-lbl { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-top: 0.2rem; }

/* ─── Badges ────────────────────────────────────────────────── */
.badge { font-size: 0.67rem; padding: 0.18rem 0.45rem; border-radius: 3px; text-transform: uppercase; letter-spacing: 0.07em; }
.badge-main { background: #3d0a0e; color: var(--accent); }
.badge-title { background: #3d2800; color: #ffc107; }
.badge-wc { background: var(--surface2); color: var(--text-muted); }

/* ─── Main event card ──────────────────────────────────────── */
.main-event-card {
  background: var(--surface); border: 1px solid #4a1a0e; border-radius: 10px;
  padding: 1.3rem 1.5rem; margin-bottom: 0.75rem;
  position: relative; overflow: hidden;
}
.main-event-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: var(--accent); }
.main-event-badges { display: flex; gap: 0.35rem; margin-bottom: 0.85rem; }

.matchup-grid { display: grid; grid-template-columns: 1fr 54px 1fr; align-items: start; gap: 0.75rem; }
.fighter-col { }
.fighter-col.right { text-align: right; }
.fighter-name-main { font-size: 1.15rem; font-weight: 700; margin-bottom: 0.05rem; font-family: 'Barlow Condensed', sans-serif; letter-spacing: 0.01em; }
.fighter-nickname { font-size: 0.72rem; color: var(--text-muted); font-style: italic; margin-bottom: 0.18rem; }
.fighter-record-main { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 0.35rem; }

/* ─── Main event archetype badges ──────────────────────────── */
.me-arch-row { display: flex; flex-wrap: wrap; gap: 0.3rem; margin-bottom: 0.3rem; }
.fighter-col.right .me-arch-row { justify-content: flex-end; }
.me-arch-badge { font-size: 0.63rem; font-weight: 600; padding: 0.1rem 0.4rem; border-radius: 3px; }
.arch-secondary { opacity: 0.7; }

/* ─── Tale of tape badges ───────────────────────────────────── */
.tape-badges { display: flex; flex-wrap: wrap; gap: 0.28rem; margin-top: 0.12rem; }
.fighter-col.right .tape-badges { justify-content: flex-end; }
.tape-badge { font-size: 0.6rem; font-weight: 700; padding: 0.12rem 0.42rem; border-radius: 3px; border: 1px solid; }

/* ─── All-Rounder archetype ─────────────────────────────────── */
.arch-all { background: #1a1a1a; color: #888; }
.vs-col { display: flex; align-items: center; justify-content: center; padding-top: 0.5rem; }
.vs-main { font-size: 0.8rem; font-weight: 800; color: var(--text-muted); }

/* ─── Shared stat rows (main event card) ───────────────────── */
.matchup-stats { margin-top: 0.75rem; display: flex; flex-direction: column; gap: 0; }
.stat-row-grid { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 0.5rem; padding: 0.35rem 0; border-bottom: 1px solid var(--border); }
.stat-row-grid:last-child { border-bottom: none; }
.f1-stat-val { font-size: 0.88rem; font-weight: 700; text-align: left; }
.f2-stat-val { font-size: 0.88rem; font-weight: 700; text-align: right; }
.stat-row-lbl { font-size: 0.63rem; color: rgba(255,255,255,0.55); text-transform: uppercase; letter-spacing: 0.06em; text-align: center; white-space: nowrap; }
.f1-stat-val.hi, .f2-stat-val.hi { color: var(--better); }
.f1-stat-val.lo, .f2-stat-val.lo { color: #ff6b6b; }
.stat-lo-ind { font-size: 0.6rem; margin-left: 0.15rem; vertical-align: middle; }

.compare-cta { text-align: center; margin-top: 0.9rem; padding-top: 0.75rem; border-top: 1px solid var(--border); }
.btn-compare-main { font-size: 0.8rem; font-weight: 600; padding: 0.42rem 1rem; background: var(--accent); color: #fff; border: none; border-radius: 4px; cursor: pointer; }
.btn-compare-main:hover { background: var(--accent-hover); }

/* ─── Section label ────────────────────────────────────────── */
.section-label { font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); margin: 1.1rem 0 0.5rem; padding-bottom: 0.3rem; border-bottom: 1px solid var(--border); }

/* ─── Bout row cards ───────────────────────────────────────── */
.bout-row {
  background: var(--surface); border: 1px solid var(--border); border-radius: 7px;
  padding: 0.75rem 1.1rem; display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.4rem;
}
.bout-row.title-fight { border-color: #3d2800; }
.bout-row { position: relative; }
.bout-row.co-main { border-color: #2a1a00; background: #111009; padding-top: 1.75rem; }
.badge-co-main { position: absolute; top: 0.45rem; left: 1.1rem; font-size: 0.62rem; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; padding: 0.1rem 0.45rem; background: rgba(255,169,77,0.12); color: var(--orange); border-radius: 3px; }
.bout-fighters { flex: 1; display: grid; grid-template-columns: 1fr 54px 1fr; align-items: center; gap: 0.5rem; }
.bout-name { font-size: 0.9rem; font-weight: 600; min-height: 2.4em; }
.bout-rec { font-size: 0.72rem; color: var(--text-muted); }
.bout-nickname { font-size: 0.67rem; color: var(--text-muted); font-style: italic; }
.bout-arch-row { display: flex; flex-wrap: wrap; gap: 0.25rem; margin-top: 0.2rem; }
.bout-right .bout-arch-row { justify-content: flex-end; }
.bout-tape-row { display: flex; flex-wrap: wrap; gap: 0.2rem; margin-top: 0.15rem; }
.bout-right .bout-tape-row { justify-content: flex-end; }
.bout-tape-badge { font-size: 0.6rem; font-weight: 700; padding: 0.08rem 0.38rem; border-radius: 3px; border: 1px solid; }
.tape-f1 { color: var(--blue);   background: rgba(116,192,252,0.12); border-color: rgba(116,192,252,0.35); }
.tape-f2 { color: var(--orange); background: rgba(255,169,77,0.12);  border-color: rgba(255,169,77,0.35); }
.bout-stat { font-size: 0.67rem; color: var(--text-muted); margin-top: 0.12rem; }
.bout-stat strong { color: var(--text); font-weight: 500; }
.bout-arch { display: inline-block; margin-top: 0.18rem; font-size: 0.63rem; font-weight: 600; padding: 0.08rem 0.38rem; border-radius: 3px; }
.bout-vs { font-size: 0.68rem; font-weight: 700; color: var(--text-muted); text-align: center; }
.bout-right { text-align: right; }
.bout-wc { font-size: 0.67rem; color: var(--text-muted); white-space: nowrap; flex-shrink: 0; min-width: 110px; text-align: right; }
.btn-bout-compare { font-size: 0.72rem; font-weight: 500; padding: 0.3rem 0.6rem; background: transparent; color: var(--accent); border: 1px solid #4a1010; border-radius: 4px; cursor: pointer; white-space: nowrap; flex-shrink: 0; }
.btn-bout-compare:hover { background: #1a0606; }
.btn-bout-compare:disabled { color: var(--text-muted); border-color: var(--border); cursor: not-allowed; background: transparent; }

@media (max-width: 520px) {
  .bout-row { flex-wrap: wrap; padding: 0.6rem 0.75rem; }
  .bout-fighters { flex-basis: 100%; }
  .bout-wc { flex: 1; min-width: 0; text-align: left; }
  .btn-bout-compare { margin-left: auto; }
}

/* ─── Explore section ──────────────────────────────────────── */
.explore-row { margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--border); }
.explore-search-card { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 1.1rem 1.25rem; }
.explore-search-title { font-size: 0.85rem; font-weight: 600; margin-bottom: 0.8rem; }
.explore-search-inputs { display: flex; align-items: center; gap: 0.6rem; }
.explore-search-wrap { position: relative; flex: 1; min-width: 0; }
.explore-search-input { width: 100%; box-sizing: border-box; background: var(--surface2); border: 1px solid var(--border); border-radius: 6px; color: var(--text); font-size: 0.82rem; padding: 0.45rem 0.75rem; }
.explore-search-input:focus { outline: none; border-color: var(--accent); }
.explore-desc { font-size: 0.72rem; color: var(--text-muted); }

/* ─── Auth modal ───────────────────────────────────────────── */
.modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,0.88); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); display: flex; align-items: center; justify-content: center; z-index: 200; }
.modal { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 2rem 1.75rem 1.75rem; width: 100%; max-width: 380px; position: relative; overflow: hidden; }
.modal::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--accent); }
.modal-close { position: absolute; top: 1rem; right: 1rem; background: none; border: none; color: var(--text-muted); font-size: 1.1rem; cursor: pointer; line-height: 1; padding: 0.25rem; z-index: 1; }
.modal-close:hover { color: var(--text); }
.modal-brand { text-align: center; margin-bottom: 1.5rem; }
.modal-brand-icon { display: none; }
.modal-logo { font-size: 1.8rem; font-weight: 800; letter-spacing: -1px; color: var(--text); font-family: 'Barlow Condensed', 'DM Sans', sans-serif; }
.modal-logo span { color: var(--accent); }
.modal-tagline { font-size: 0.7rem; color: var(--text-muted); margin-top: 0.2rem; letter-spacing: 0.02em; }
/* pill tab toggle */
.tabs { display: flex; background: var(--surface2); border-radius: 6px; padding: 3px; margin-bottom: 1.5rem; gap: 0; }
.tab-btn { flex: 1; background: none; border: none; color: var(--text-muted); padding: 0.45rem 0; font-size: 0.83rem; font-weight: 500; border-radius: 4px; cursor: pointer; transition: color 0.15s, background 0.15s, box-shadow 0.15s; }
.tab-btn.active { background: var(--surface); color: var(--text); box-shadow: 0 1px 4px rgba(0,0,0,0.5); }
/* fields */
.field { margin-bottom: 1rem; }
.field-label { display: block; font-size: 0.7rem; font-weight: 500; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.07em; margin-bottom: 0.35rem; }
input[type="email"], input[type="password"], input[type="text"] { width: 100%; background: var(--surface2); border: 1px solid var(--border); color: var(--text); padding: 0.65rem 0.875rem; border-radius: 6px; font-size: 0.875rem; font-family: inherit; transition: border-color 0.15s, box-shadow 0.15s; }
input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(230,57,70,0.12); }
input::placeholder { color: #555; }
.input-wrap { position: relative; }
.input-wrap input { padding-right: 3.75rem; }
.toggle-pw { position: absolute; right: 0.75rem; top: 50%; transform: translateY(-50%); background: none; border: none; color: var(--text-muted); font-size: 0.7rem; font-weight: 500; font-family: inherit; letter-spacing: 0.04em; cursor: pointer; padding: 0; transition: color 0.15s; }
.toggle-pw:hover { color: var(--text); }
/* feedback messages */
.form-error { font-size: 0.78rem; color: var(--worse); background: rgba(255,107,107,0.08); border: 1px solid rgba(255,107,107,0.2); border-radius: 5px; padding: 0.5rem 0.75rem; margin-bottom: 1rem; display: none; }
.form-success { font-size: 0.78rem; color: var(--better); background: rgba(81,207,102,0.08); border: 1px solid rgba(81,207,102,0.2); border-radius: 5px; padding: 0.5rem 0.75rem; margin-bottom: 1rem; display: none; }
/* submit button */
.btn-submit { width: 100%; background: var(--accent); color: #fff; border: none; padding: 0.75rem; border-radius: 6px; font-size: 0.9rem; font-weight: 600; cursor: pointer; margin-top: 0.5rem; transition: background 0.15s; position: relative; }
.btn-submit:hover:not(:disabled) { background: var(--accent-hover); }
.btn-submit:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-submit.loading { color: transparent; }
.btn-submit.loading::after { content: ''; position: absolute; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,0.3); border-top-color: #fff; border-radius: 50%; animation: spin 0.7s linear infinite; top: 50%; left: 50%; transform: translate(-50%,-50%); }

/* auth modal — loading state hides all form content */
.auth-loading .auth-form-content { display: none; }

/* auth modal — SSO */
.auth-sso { margin-bottom: 1rem; }
.btn-google { display: flex; align-items: center; justify-content: center; gap: 0.6rem; width: 100%; background: #fff; color: #3c4043; border: 1px solid #dadce0; border-radius: 6px; padding: 0.65rem 1rem; font-size: 0.875rem; font-weight: 500; cursor: pointer; transition: box-shadow 0.15s, background 0.15s; font-family: inherit; }
.btn-google:hover { background: #f8f9fa; box-shadow: 0 1px 4px rgba(0,0,0,0.25); }
.btn-google svg { flex-shrink: 0; }
.auth-divider { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1rem; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.auth-divider span { font-size: 0.72rem; color: var(--text-muted); white-space: nowrap; }

/* auth modal loading / confirm state */
.auth-state-panel { display: none; text-align: center; padding: 2rem 1.5rem 1.5rem; }
.auth-state-panel .spinner-ring { margin: 0 auto 1.5rem; }
.auth-ring-static { animation: none !important; border-top-color: var(--accent); }
.auth-state-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 0.6rem; }
.auth-state-text { font-size: 0.83rem; color: var(--text-muted); line-height: 1.6; margin: 0 0 1.25rem; }
.auth-state-back { background: none; border: 1px solid var(--border); color: var(--text-muted); font-size: 0.78rem; padding: 0.45rem 1.1rem; border-radius: 5px; cursor: pointer; transition: color 0.15s, border-color 0.15s; }
.auth-state-back:hover { color: var(--text); border-color: var(--text-muted); }

/* ─── Compare page: search ─────────────────────────────────── */
.search-section { display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; gap: 1.5rem; margin-bottom: 1.5rem; }
.vs-divider { text-align: center; font-size: 1.4rem; font-weight: 800; color: var(--accent); padding-top: 1.7rem; }
.search-box label { display: block; font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 0.4rem; }
.search-wrapper { position: relative; }
.search-input { width: 100%; background: var(--surface); border: 1px solid var(--border); color: var(--text); padding: 0.7rem 1rem; border-radius: 6px; font-size: 0.875rem; font-family: inherit; }
.search-input:focus { outline: none; border-color: var(--accent); }
.search-input::placeholder { color: var(--text-muted); }
.search-dropdown { position: absolute; top: 100%; left: 0; right: 0; background: var(--surface); border: 1px solid var(--border); border-top: none; border-radius: 0 0 6px 6px; max-height: 220px; overflow-y: auto; z-index: 20; display: none; }
.search-dropdown.open { display: block; }
.search-option { padding: 0.6rem 1rem; cursor: pointer; border-bottom: 1px solid var(--border); font-size: 0.85rem; }
.search-option:last-child { border-bottom: none; }
.search-option:hover { background: var(--surface2); }
.opt-name { font-weight: 500; }
.opt-meta { font-size: 0.73rem; color: var(--text-muted); margin-top: 0.1rem; }
.selected-chip { margin-top: 0.5rem; padding: 0.45rem 0.7rem; background: var(--surface2); border-radius: 4px; display: flex; align-items: center; justify-content: space-between; font-size: 0.85rem; border: 1px solid var(--border); }
.chip-name { font-weight: 500; }
.chip-record { font-size: 0.73rem; color: var(--text-muted); margin-left: 0.35rem; }
.chip-clear { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1rem; line-height: 1; padding: 0; margin-left: 0.5rem; }
.chip-clear:hover { color: var(--accent); }
.compare-action { text-align: center; margin-bottom: 2rem; }
#btn-compare, #btm-btn-compare { padding: 0.7rem 2.25rem; font-size: 0.95rem; font-weight: 600; border-radius: 6px; border: none; transition: background 0.15s; }
#btn-compare:not(:disabled), #btm-btn-compare:not(:disabled) { background: var(--accent); color: #fff; cursor: pointer; }
#btn-compare:not(:disabled):hover, #btm-btn-compare:not(:disabled):hover { background: var(--accent-hover); }
#btn-compare:disabled, #btm-btn-compare:disabled { background: var(--surface2); color: var(--text-muted); cursor: not-allowed; border: 1px solid var(--border); }

/* ─── Compare page: fighter headers ───────────────────────── */
.fh-grid { display: grid; grid-template-columns: 1fr auto 1fr; gap: 1rem; align-items: start; margin-bottom: 1.5rem; }
.fh-card { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 0.9rem 1rem; }
.fh-card.f1 { border-top: 3px solid var(--blue); }
.fh-card.f2 { border-top: 3px solid var(--orange); text-align: right; }
.fh-name { font-size: 0.95rem; font-weight: 700; margin-bottom: 0.15rem; }
.fh-sub { font-size: 0.7rem; color: var(--text-muted); line-height: 1.4; }
.fh-record { font-size: 1.2rem; font-weight: 800; margin-top: 0.4rem; }
.fh-record small { font-size: 0.62rem; font-weight: 400; color: var(--text-muted); }
.vs-center { display: flex; flex-direction: column; align-items: center; justify-content: center; padding-top: 0.75rem; }
.vs-big { font-size: 1.25rem; font-weight: 800; color: var(--accent); }
.vs-div-label { font-size: 0.65rem; color: var(--text-muted); margin-top: 0.2rem; text-align: center; }

/* ─── Compare page: fighter header physical row ────────────── */
.fh-phys { font-size: 0.67rem; color: var(--text-muted); margin-top: 0.3rem; line-height: 1.5; }

/* ─── Compare page: compact stat duel ─────────────────────── */
.sg-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; margin-bottom: 1.5rem; }
.sg-header { display: grid; grid-template-columns: 1fr 1fr 1fr; padding: 0.45rem 1rem; border-bottom: 2px solid var(--border); background: var(--surface2); }
.sg-header-f1 { font-size: 0.78rem; font-weight: 700; color: var(--blue); }
.sg-header-f2 { font-size: 0.78rem; font-weight: 700; color: var(--orange); text-align: right; }
.sg-header-lbl { text-align: center; font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); }
.sg-row { display: grid; grid-template-columns: 1fr 1fr 1fr; padding: 0.28rem 1rem; border-bottom: 1px solid var(--border); align-items: center; }
.sg-row:last-child { border-bottom: none; }
.sg-row:nth-child(even) { background: rgba(255,255,255,0.015); }
.sg-val { font-weight: 600; font-size: 0.88rem; }
.sg-f1 { color: var(--blue); }
.sg-f2 { color: var(--orange); text-align: right; }
.sg-f1.sg-better, .sg-f2.sg-better { color: var(--better); }
.sg-f1.sg-na, .sg-f2.sg-na { color: var(--text-muted); font-weight: 400; }
.sg-lbl { text-align: center; font-size: 0.67rem; color: var(--text-muted); }
.val-better { color: var(--better); }
.val-na { color: var(--text-muted); font-weight: 400; }

/* ─── Chart subtitle ───────────────────────────────────────── */
.chart-subtitle { font-size: 0.68rem; color: var(--text-muted); margin-bottom: 0.4rem; padding: 0 0.25rem; }

/* ─── Round chart component ────────────────────────────────── */
.rnd-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 1.1rem 1.25rem; margin-bottom: 1.5rem; }
.rnd-title { font-size: 0.7rem; font-weight: 700; margin-bottom: 0.6rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); }
.rnd-filter-row { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; }
.rnd-filter-label { font-size: 0.63rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); white-space: nowrap; min-width: 48px; }
.rnd-win-btn, .rnd-rf-btn { font-size: 0.67rem; padding: 0.22rem 0.65rem; border-radius: 12px; background: var(--surface2); color: var(--text-muted); border: 1px solid var(--border); font-family: inherit; cursor: pointer; transition: background 0.15s, color 0.15s, border-color 0.15s; }
.rnd-win-btn:hover, .rnd-rf-btn:hover { color: var(--text); border-color: #555; }
.rnd-win-btn.active, .rnd-rf-btn.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.rnd-sub { font-size: 0.7rem; color: var(--text-muted); margin-bottom: 0.85rem; min-height: 1em; }
.rnd-tabs { display: flex; border-bottom: 1px solid var(--border); margin-bottom: 0.85rem; }
.rnd-tab { font-size: 0.72rem; padding: 0.38rem 0.85rem; color: var(--text-muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; background: none; border-top: none; border-left: none; border-right: none; font-family: inherit; transition: color 0.15s; }
.rnd-tab.active { color: var(--text); border-bottom-color: var(--accent); }
.rnd-legend { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-bottom: 0.7rem; }
.rnd-leg-item { display: flex; align-items: center; gap: 0.35rem; font-size: 0.7rem; color: var(--text-muted); }
.rnd-leg-line { width: 18px; height: 3px; border-radius: 2px; flex-shrink: 0; }
.rnd-leg-dash { width: 18px; height: 0; border-top: 2px dashed; flex-shrink: 0; }
.rnd-desc { font-size: 0.68rem; color: var(--text-muted); font-style: italic; margin-bottom: 0.5rem; }
.rnd-chart-box { background: var(--surface2); border: 1px solid var(--border); border-radius: 7px; padding: 0.65rem; margin-bottom: 0.7rem; }
.rnd-insights { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 0.5rem; margin-bottom: 0.7rem; }
.rnd-ins-card { background: var(--surface2); border: 1px solid var(--border); border-radius: 7px; padding: 0.55rem 0.7rem; }
.rnd-ins-round { font-size: 0.63rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 0.35rem; }
.rnd-ins-stat { display: flex; justify-content: space-between; margin-bottom: 0.15rem; align-items: baseline; }
.rnd-ins-label { font-size: 0.63rem; color: var(--text-muted); }
.rnd-ins-val { font-size: 0.78rem; font-weight: 700; }
.rnd-ins-net { margin-top: 0.38rem; padding-top: 0.38rem; border-top: 1px solid var(--border); }
.rnd-ins-net-label { font-size: 0.6rem; color: var(--text-muted); margin-bottom: 0.08rem; }
.rnd-ins-net-val { font-size: 0.78rem; font-weight: 700; }
.rnd-momentum { background: var(--surface2); border: 1px solid var(--border); border-radius: 7px; padding: 0.6rem 0.85rem; }
.rnd-mom-label { font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 0.45rem; }
.rnd-mom-track { display: flex; height: 8px; border-radius: 4px; overflow: hidden; }
.rnd-mom-fighters { display: flex; justify-content: space-between; margin-top: 0.28rem; font-size: 0.68rem; color: var(--text-muted); }
.rnd-narrative { margin-top: 0.55rem; font-size: 0.7rem; color: var(--text-muted); line-height: 1.5; border-top: 1px solid var(--border); padding-top: 0.45rem; }

/* ─── Net striking share bar (round insight cards) ─────────── */
.rnd-net-share { margin-top: 0.5rem; padding-top: 0.4rem; border-top: 1px solid var(--border); }
.rnd-net-share-lbl { font-size: 0.63rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-muted); margin-bottom: 0.22rem; }
.rnd-net-share-bar { display: flex; height: 6px; border-radius: 3px; overflow: hidden; background: var(--surface2); margin-bottom: 0.25rem; }
.rnd-net-share-vals { display: flex; justify-content: space-between; font-size: 0.65rem; font-weight: 600; }

/* ─── Empty state banner ───────────────────────────────────── */
.rnd-empty-banner { background: rgba(255,169,77,0.07); border: 1px solid rgba(255,169,77,0.25); border-radius: 6px; padding: 0.45rem 0.75rem; font-size: 0.72rem; color: var(--text-muted); margin-bottom: 0.5rem; }

/* ─── Finish tags (history table) ─────────────────────────── */
.finish-tag { font-size: 0.6rem; font-weight: 600; padding: 0.1rem 0.35rem; border-radius: 3px; white-space: nowrap; }
.finish-tag-ko  { background: rgba(255,107,107,0.15); color: #ff6b6b; }
.finish-tag-dec { background: rgba(134,142,150,0.15); color: #868e96; }

/* ─── Finish badges (round insight cards) ─────────────────── */
.rnd-finish-badges { display: inline-flex; gap: 0.3rem; margin-left: 0.4rem; vertical-align: middle; }
.rnd-finish-badge { font-size: 0.62rem; font-weight: 700; padding: 0.1rem 0.32rem; border-radius: 3px; white-space: nowrap; }
.rnd-finish-blue   { background: rgba(116,192,252,0.15); color: #74c0fc; }
.rnd-finish-orange { background: rgba(255,169,77,0.15);  color: #ffa94d; }
.rnd-ins-card-finish { border-color: rgba(255,107,107,0.3); }

/* ─── Charts ───────────────────────────────────────────────── */
.chart-section { margin-bottom: 1.5rem; }
.chart-section-label { font-size: 0.62rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); margin-bottom: 0.5rem; padding-bottom: 0.3rem; border-bottom: 1px solid var(--border); }
.chart-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; overflow: hidden; }
.chart-legend { display: flex; gap: 1.25rem; padding: 0.65rem 1rem 0.25rem; }
.leg-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.leg-label { font-size: 0.7rem; color: var(--text-muted); display: flex; align-items: center; gap: 0.35rem; }
.chart-inner { padding: 0.25rem 0.75rem 0.75rem; }

/* ─── Strike distribution ──────────────────────────────────── */
.sil-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 1.5rem; }
.sil-card { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 0.9rem; }
.sil-title { font-size: 0.72rem; font-weight: 600; margin-bottom: 0.7rem; }
.sil-title.blue { color: var(--blue); }
.sil-title.orange { color: var(--orange); }
.sil-body { display: flex; align-items: flex-start; gap: 0.85rem; }
.sil-svg-wrap { flex-shrink: 0; display: flex; align-self: stretch; align-items: center; }
.sil-bars { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.42rem; justify-content: center; }
.sil-bar-row { }
.sil-bar-label { font-size: 0.62rem; color: var(--text-muted); margin-bottom: 0.15rem; display: flex; justify-content: space-between; }
.sil-bar-label span { font-size: 0.65rem; font-weight: 600; color: var(--text); }
.sil-track { height: 5px; background: var(--surface2); border-radius: 3px; overflow: hidden; }
.sil-fill { height: 5px; border-radius: 3px; transition: width 0.4s ease; }
.sil-divider { border-top: 1px solid var(--border); margin: 0.5rem 0 0.25rem; }
.fill-head { background: var(--accent); }
.fill-body { background: var(--orange); }
.fill-leg { background: var(--blue); }
.fill-dist { background: var(--better); }
.fill-clinch { background: #aaa; }
.fill-ground { background: #666; }
.sil-na { font-size: 0.72rem; color: var(--text-muted); padding: 1rem 0; text-align: center; }

/* ─── Fighter header badges ────────────────────────────────── */
.fh-badges { display: flex; flex-wrap: wrap; gap: 0.28rem; margin-top: 0.4rem; }
.fh-badge { font-size: 0.6rem; padding: 0.14rem 0.4rem; border-radius: 3px; font-weight: 500; white-space: nowrap; }
.fh-badge-edge { background: rgba(255,255,255,0.05); color: var(--text-muted); }
.fh-badge-slope-up { background: #0e2a14; color: var(--better); }
.fh-badge-slope-dn { background: #2a0a0e; color: var(--worse); }

/* ─── TD funnel ─────────────────────────────────────────────── */
.td-funnel-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 1.5rem; }
.td-card { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 0.85rem 0.95rem; }
.td-card-header { font-size: 0.72rem; font-weight: 600; margin-bottom: 0.65rem; }
.td-step { display: grid; grid-template-columns: 62px 1fr 70px; align-items: center; gap: 0.55rem; margin-bottom: 0.45rem; }
.td-step:last-child { margin-bottom: 0; }
.td-lbl { font-size: 0.63rem; color: var(--text-muted); }
.td-bar-wrap { height: 6px; background: var(--surface2); border-radius: 3px; overflow: hidden; }
.td-bar { height: 6px; border-radius: 3px; }
.td-val { font-size: 0.75rem; font-weight: 600; text-align: right; }

/* ─── Fight history ────────────────────────────────────────── */
.hist-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 1.5rem; }
.hist-card { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; overflow: hidden; }
.hist-card-header { padding: 0.5rem 0.9rem; border-bottom: 1px solid var(--border); font-size: 0.72rem; font-weight: 600; }
.hist-card-header.blue { color: var(--blue); }
.hist-card-header.orange { color: var(--orange); }
.hist-table { width: 100%; border-collapse: collapse; font-size: 0.7rem; }
.hist-table th { padding: 0.32rem 0.7rem; text-align: left; font-size: 0.63rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-muted); font-weight: 400; border-bottom: 1px solid var(--border); background: var(--surface2); }
.hist-table td { padding: 0.4rem 0.7rem; border-bottom: 1px solid var(--border); vertical-align: middle; }
.hist-table tr:last-child td { border-bottom: none; }
.result-w { background: #0e2a14; color: var(--better); font-size: 0.6rem; font-weight: 700; padding: 0.1rem 0.38rem; border-radius: 3px; }
.result-l { background: #2a0a0e; color: var(--accent); font-size: 0.6rem; font-weight: 700; padding: 0.1rem 0.38rem; border-radius: 3px; }
.result-d { background: #1e1a00; color: #ffc107; font-size: 0.6rem; font-weight: 700; padding: 0.1rem 0.38rem; border-radius: 3px; }
.opp-name { color: var(--text); font-weight: 500; font-size: 0.72rem; }
.fight-meta { color: var(--text-muted); font-size: 0.64rem; }
.stat-cell { color: var(--text-muted); font-size: 0.67rem; }
.stat-cell strong { color: var(--text); font-weight: 600; }

/* ─── Stat tooltips ─────────────────────────────────────────── */
.tip { position: relative; display: inline-block; cursor: help; font-style: normal; vertical-align: middle; }
.tip::after {
  content: attr(data-tip);
  position: absolute;
  bottom: 130%; left: 50%;
  transform: translateX(-50%);
  background: #1e1e1e;
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.65rem;
  white-space: nowrap;
  padding: 0.3rem 0.55rem;
  border-radius: 4px;
  z-index: 200;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 400;
}
.tip:hover::after { opacity: 1; }
#tip-popup { display: none; position: absolute; background: #1e1e1e; border: 1px solid var(--border); color: var(--text); font-size: 0.65rem; padding: 0.3rem 0.55rem; border-radius: 4px; z-index: 300; max-width: min(260px, 85vw); white-space: normal; pointer-events: none; line-height: 1.4; }
@media (hover: none) { .tip::after { display: none; } }

/* ─── Archetype badges ───────────────────────────────────────── */
.arch-str     { background: #1a0e00; color: #ff9800; }
.arch-brawler { background: #2a0a0e; color: var(--worse); }
.arch-wr      { background: #0a1a2a; color: var(--blue); }
.arch-gr      { background: #0a1520; color: #63c5da; }
.arch-sub     { background: #140a20; color: #b388ff; }
.arch-ctr     { background: #0e2a14; color: var(--better); }

/* ─── Weight class mismatch warning ────────────────────────── */
.wc-warn {
  background: #1e1500; border: 1px solid #3d2800; border-radius: 6px;
  color: #ffc107; font-size: 0.72rem; padding: 0.45rem 0.85rem;
  margin-bottom: 1rem; text-align: center;
}

/* ─── Share button (R2) ─────────────────────────────────────────── */
.share-btn {
  display: inline-flex; align-items: center; gap: 0.28rem;
  background: transparent; border: 1px solid var(--border);
  color: var(--text-muted); border-radius: 4px;
  padding: 0.22rem 0.45rem; font-size: 0.63rem; font-family: inherit;
  cursor: pointer; margin-top: 0.4rem; transition: color 0.15s, border-color 0.15s;
}
.share-btn:hover { color: var(--text); border-color: #555; }

/* ─── Round filter group labels (R4) ────────────────────────────── */
.rnd-group-label {
  font-size: 0.63rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--text-muted); margin-bottom: 0.28rem; margin-top: 0.6rem;
}
.rnd-group-label:first-child { margin-top: 0; }
.rnd-filter-desc {
  font-size: 0.68rem; color: var(--text-muted); font-style: italic;
  margin: 0.3rem 0 0.6rem; min-height: 1.1em;
}

/* ─── Style matchup blurb (R6) ──────────────────────────────────── */
.style-blurb {
  font-size: 0.73rem; color: var(--text-muted); font-style: italic;
  padding: 0.45rem 1rem; margin: 0 0 0.6rem;
  border-left: 2px solid var(--border);
}

/* ─── Deep dive toggle (R9) ─────────────────────────────────────── */
.deep-dive-wrap { margin-top: 1rem; }
.deep-dive-toggle {
  display: block; width: 100%;
  background: var(--surface2); border: 1px solid rgba(255,255,255,0.12);
  color: var(--text); border-radius: 6px;
  padding: 0.6rem 1rem; font-size: 0.72rem; font-weight: 600; font-family: inherit;
  cursor: pointer; text-align: center; margin-bottom: 1rem;
  letter-spacing: 0.04em; transition: background 0.15s, border-color 0.15s;
}
.deep-dive-toggle:hover { background: #2a2a2a; border-color: rgba(255,255,255,0.22); }

/* ─── Bottom CTA (R7) ───────────────────────────────────────────── */
.btm-cta {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 9px; padding: 1.25rem 1.5rem; margin-top: 2rem;
}
.btm-cta-heading { font-size: 0.82rem; font-weight: 600; margin-bottom: 1rem; }
.btm-cta-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; gap: 1.5rem; }
.btm-cta-row .vs-divider { padding-top: 1.7rem; }
.btm-cta-action { text-align: center; margin-top: 1rem; }

/* ─── Responsive (768px) ─────────────────────────────────────────── */
@media (max-width: 768px) {
  main { padding: 1rem; }
  header { padding: 0.65rem 1rem; }
  .site-nav { display: none; }

  /* Search inputs */
  .search-section { grid-template-columns: 1fr; }
  .vs-divider { padding-top: 0; text-align: center; }
  #btn-compare { width: 100%; }

  /* Fighter header cards */
  .fh-grid { grid-template-columns: 1fr; }
  .fh-card.f2 { text-align: left; }
  .fh-card.f2 .fh-badges { justify-content: flex-start; }
  .vs-center {
    flex-direction: row; justify-content: center; gap: 0.75rem;
    padding: 0.3rem 0;
    border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  }
  .vs-center .vs-div-label { display: none; }

  /* Career stats — label above values */
  .sg-row {
    grid-template-columns: 1fr 1fr;
    grid-template-areas: "lbl lbl" "f1 f2";
    padding: 0.42rem 0.75rem;
  }
  .sg-lbl { grid-area: lbl; text-align: left; margin-bottom: 0.08rem; }
  .sg-f1 { grid-area: f1; }
  .sg-f2 { grid-area: f2; text-align: right; }
  .sg-header { grid-template-columns: 1fr 1fr; }
  .sg-header-lbl { display: none; }
  .sg-header-f2 { text-align: right; }

  /* Round chart */
  .rnd-filter-row { flex-wrap: wrap; }
  .rnd-tabs { flex-wrap: wrap; }
  .rnd-insights { grid-template-columns: 1fr 1fr; }
  .rnd-chart-box { min-height: 200px; }

  /* Radar — square */
  .radar-chart-inner { height: auto !important; aspect-ratio: 1 / 1; min-height: 260px; }

  /* Strike distribution */
  .sil-grid { grid-template-columns: 1fr; }

  /* TD funnel */
  .td-funnel-grid { grid-template-columns: 1fr; }

  /* Fight history */
  .hist-grid { grid-template-columns: 1fr; }
  .td-col-hide { display: none; }

  /* Bottom CTA */
  .btm-cta-row { grid-template-columns: 1fr; }
  .btm-cta-row .vs-divider { padding-top: 0; }
  .btm-cta-action button { width: 100%; }

  /* Index page utilities */
  .matchup-grid { grid-template-columns: 1fr; }
  .vs-col { display: none; }
  .explore-search-inputs { flex-direction: column; align-items: stretch; }
  .cmp-table thead th, .cmp-table td { padding: 0.4rem 0.65rem; }
}

/* ─── Enhanced Analytics Panel ─────────────────────────────── */
.ea-section {
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  padding-top: 1.5rem;
}
.ea-section-heading {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid var(--border);
}
.ea-intro {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  line-height: 1.55;
}
.ea-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 1.1rem;
  margin-bottom: 1rem;
}

/* ─── Scroll focus effect ───────────────────────────────────── */
.scroll-dim   { opacity: 0.38; transition: opacity 0.35s ease; }
.scroll-focus { opacity: 1;    transition: opacity 0.35s ease; }
.rnd-wrap.scroll-dim, .rnd-wrap.scroll-focus { transition: opacity 0.35s ease; }
.ea-card-title {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--text-muted);
  margin-bottom: 0.65rem;
}
.ea-legend {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 0.6rem;
}
.ea-leg-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  color: var(--text-muted);
}
.ea-leg-dot {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}
.ea-leg-dash {
  width: 16px;
  height: 0;
  border-top: 2px dashed;
  flex-shrink: 0;
}
.ea-three-col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1rem;
}
.ea-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}
.ea-chart-wrap {
  position: relative;
  width: 100%;
}
.ea-interpret {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-style: italic;
  margin-top: 0.5rem;
  line-height: 1.45;
  padding: 0.35rem 0.5rem;
  border-left: 2px solid var(--border);
}
.ea-arc-pair, .ea-eff-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 0.5rem;
}
.ea-arc-pair { margin-bottom: 1rem; }
.ea-card-subtitle { font-size: 0.68rem; font-weight: 600; margin-bottom: 0.35rem; }
.ea-arc-name { font-size: 0.78rem; font-weight: 700; margin-bottom: 0.3rem; }
.ea-desc {
  font-size: 0.65rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin-top: 0.55rem;
  padding-top: 0.4rem;
  border-top: 1px solid var(--border);
}
.ea-metric-line { display: block; margin-bottom: 0.22rem; }
.ea-metric-line strong { color: var(--text); font-weight: 600; }
@media (max-width: 768px) {
  .ea-three-col, .ea-two-col { grid-template-columns: 1fr; }
  .ea-arc-pair, .ea-eff-pair { grid-template-columns: 1fr; }
}

/* ─── Section jump nav ──────────────────────────────────────── */
.section-nav { display: flex; gap: 0.25rem; flex-wrap: wrap; margin-bottom: 1rem; padding: 0.5rem 0.6rem; background: var(--surface2); border: 1px solid var(--border); border-radius: 7px; position: sticky; top: 58px; z-index: 10; }
.section-nav-btn { font-size: 0.67rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; padding: 0.3rem 0.7rem; border: none; border-radius: 4px; background: transparent; color: var(--text-muted); cursor: pointer; transition: background 0.15s, color 0.15s; white-space: nowrap; }
.section-nav-btn:hover { background: var(--surface); color: var(--text); }
.section-nav-toggle { display: none; }
.section-nav-drawer { display: contents; }
@media (max-width: 640px) {
  .section-nav { flex-direction: column; gap: 0; padding: 0; }
  .section-nav-toggle { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 0.65rem 0.75rem; background: none; border: none; color: var(--text); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer; }
  .section-nav-drawer { display: none; flex-direction: column; padding: 0.25rem 0.5rem 0.5rem; border-top: 1px solid var(--border); }
  .section-nav-drawer.open { display: flex; }
  .section-nav-btn { text-align: left; padding: 0.5rem 0.6rem; }
}

/* ─── Back to top ────────────────────────────────────────────── */
.back-to-top { position: fixed; bottom: 5.5rem; right: 1rem; width: 40px; height: 40px; border-radius: 50%; background: var(--accent); color: #fff; border: none; font-size: 1.1rem; cursor: pointer; display: none; align-items: center; justify-content: center; z-index: 99; box-shadow: 0 2px 10px rgba(0,0,0,0.4); transition: opacity 0.2s; }
.back-to-top.visible { display: flex; }

/* ─── Winner / statistical edge summary ─────────────────────── */
.edge-summary { display: flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.55rem 1rem; background: var(--surface2); border: 1px solid var(--border); border-radius: 7px; font-size: 0.7rem; color: var(--text-muted); margin-bottom: 1rem; flex-wrap: wrap; text-align: center; }
.edge-summary strong { color: var(--text); font-weight: 600; }
.edge-f1 { color: var(--blue); font-weight: 700; }
.edge-f2 { color: var(--orange); font-weight: 700; }
.edge-sep { color: var(--border); }

/* ─── Finish timing ──────────────────────────────────────────── */
.finish-timing { margin-top: 1.25rem; padding: 0.9rem 1rem; background: var(--surface); border: 1px solid var(--border); border-radius: 6px; }
.finish-timing-hdr { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 0.6rem; font-size: 0.68rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.07em; }
.finish-timing-grid { display: grid; grid-template-columns: 55px 1fr 55px; align-items: center; gap: 0.75rem; }
.ft-stat-right { text-align: right; }
.ft-val { font-size: 1.3rem; font-family: 'Barlow Condensed', sans-serif; font-weight: 700; line-height: 1; }
.ft-lbl { font-size: 0.65rem; color: var(--text-muted); }
.ft-bar { height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; }
.ft-bar-inner { display: flex; height: 100%; }
.ft-bar-seg { transition: width 0.6s cubic-bezier(0.4,0,0.2,1); }

/* ─── Matchup edges ──────────────────────────────────────────── */
.matchup-edges { background: var(--surface); border: 1px solid var(--border); border-radius: 7px; padding: 0.75rem 1rem; margin-bottom: 1rem; }
.me-title { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 0.6rem; }
.me-row { display: grid; grid-template-columns: 70px 130px 1fr; align-items: baseline; gap: 0.5rem; padding: 0.35rem 0; border-top: 1px solid rgba(255,255,255,0.04); font-size: 0.78rem; }
.me-row:first-of-type { border-top: none; }
.me-f1 { color: var(--blue); font-weight: 700; font-size: 0.72rem; }
.me-f2 { color: var(--orange); font-weight: 700; font-size: 0.72rem; }
.me-label { color: var(--text); font-weight: 600; }
.me-detail { color: var(--text-muted); font-size: 0.72rem; }

/* ─── Stat legend (▼ explanation) ───────────────────────────── */
.stat-legend { font-size: 0.63rem; color: var(--text-muted); text-align: center; margin-top: 0.4rem; }
.stat-legend span { color: #ff6b6b; font-weight: 700; }

/* ─── No-data round card ─────────────────────────────────────── */
.rnd-ins-card.no-data { opacity: 0.45; }
.rnd-ins-card.no-data .rnd-ins-round::after { content: ' — no data'; font-size: 0.55rem; color: var(--text-muted); font-weight: 400; }

/* ─── Privacy page ─────────────────────────────────────────── */
.privacy-main { max-width: 680px; margin: 0 auto; padding: 2.5rem 1.5rem 4rem; }
.privacy-content h1 { font-size: 2rem; font-weight: 800; font-family: 'Barlow Condensed', sans-serif; letter-spacing: -0.5px; margin-bottom: 0.25rem; }
.privacy-date { font-size: 0.75rem; color: var(--text-muted); margin-bottom: 2rem; }
.privacy-content h2 { font-size: 1rem; font-weight: 700; margin: 2rem 0 0.6rem; color: var(--text); }
.privacy-content p, .privacy-content li { font-size: 0.875rem; color: var(--text-muted); line-height: 1.7; margin-bottom: 0.75rem; }
.privacy-content ul { padding-left: 1.25rem; margin-bottom: 0.75rem; }
.privacy-content a { color: var(--accent); }
.privacy-content a:hover { text-decoration: underline; }

/* ─── Site footer ───────────────────────────────────────────── */
.site-footer { margin-top: 2.5rem; padding: 1.25rem 1.5rem; border-top: 1px solid var(--border); text-align: center; }
.footer-inner { display: flex; align-items: center; justify-content: center; gap: 0.6rem; flex-wrap: wrap; font-size: 0.67rem; color: var(--text-muted); }
.footer-brand { font-weight: 700; color: var(--accent); }
.footer-inner a { color: var(--text-muted); text-decoration: none; }
.footer-inner a:hover { color: var(--text); }
.footer-sep { color: var(--border); }

/* ─── Mobile bottom nav ─────────────────────────────────────── */
.mobile-nav { display: none; }
@media (max-width: 768px) {
  .mobile-nav {
    display: flex;
    position: fixed; bottom: 0; left: 0; right: 0;
    background: var(--surface); border-top: 1px solid var(--border);
    z-index: 50;
    padding-bottom: env(safe-area-inset-bottom, 0);
  }
  .mobile-nav-item {
    flex: 1; text-align: center; padding: 0.8rem 0.5rem;
    font-size: 0.7rem; font-weight: 600; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 0.08em;
    transition: color 0.15s;
  }
  .mobile-nav-item.active { color: var(--accent); }
  .mobile-nav-item:hover { color: var(--text); }
  main { padding-bottom: 5rem; }
  .site-footer { margin-bottom: 3.5rem; }
}

/* ─── Reduced motion ────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .spinner-ring { animation: none; border-top-color: var(--accent); }
  .btn-submit.loading::after { animation: none; }
  .scroll-dim, .scroll-focus { transition: none; }
  .sil-fill { transition: none; }
}
