:root {
  color-scheme: dark;
  --bg: #07110e;
  --surface: #0b1814;
  --surface-2: #0e201a;
  --line: #244137;
  --line-strong: #356251;
  --text: #edf6f2;
  --muted: #91a99f;
  --green: #35df91;
  --green-deep: #197c51;
  --blue: #68a9ff;
  --amber: #ffc95e;
  --red: #ff766d;
  --max: 1280px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Pretendard", "Noto Sans KR", "Malgun Gothic", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.55;
}
button, select, input { font: inherit; }
button, a, select, input { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 17, 14, 0.96);
  backdrop-filter: blur(12px);
}
.topbar__inner {
  width: min(var(--max), calc(100% - 40px));
  height: 64px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 30px;
}
.brand { display: flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 800; }
.brand__mark { width: 20px; height: 20px; border: 3px solid var(--green); border-radius: 50%; box-shadow: inset 0 0 0 4px var(--bg); }
.section-nav { display: flex; gap: 26px; margin-left: auto; color: var(--muted); }
.section-nav a { padding: 21px 0 18px; border-bottom: 2px solid transparent; }
.section-nav a:hover, .section-nav a:focus-visible { color: var(--text); border-color: var(--green); outline: none; }
.ranked-badge { display: flex; align-items: center; gap: 7px; padding: 7px 10px; border: 1px solid var(--line-strong); border-radius: 4px; color: #c9ded5; font-weight: 700; font-size: 12px; }
.ranked-badge span { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }

main { width: min(var(--max), calc(100% - 40px)); margin: 0 auto; padding: 44px 0 72px; }
.intro { display: flex; align-items: flex-start; justify-content: space-between; gap: 40px; margin-bottom: 24px; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: clamp(34px, 3vw, 38px); line-height: 1.16; letter-spacing: 0; }
h2 { margin-bottom: 4px; font-size: 22px; letter-spacing: 0; }
h3 { letter-spacing: 0; }
.intro__copy { max-width: 660px; margin-bottom: 0; color: #b6c9c1; font-size: 15px; }
.intro__meta { display: flex; align-items: flex-end; gap: 14px; color: var(--muted); white-space: nowrap; }
.patch-picker { color: var(--muted); font-size: 11px; font-weight: 700; }
.patch-picker select { min-width: 176px; }
.data-freshness { display: flex; flex-direction: column; align-items: flex-end; padding-bottom: 2px; }
.data-freshness small { color: #6f8a7f; }
.matchup-picker button {
  min-height: 40px;
  border: 1px solid var(--green-deep);
  border-radius: 4px;
  background: #123a2a;
  color: var(--text);
  padding: 0 16px;
  font-weight: 750;
  cursor: pointer;
}
.matchup-picker button:hover, .matchup-picker button:focus-visible { border-color: var(--green); background: #174d37; outline: none; }
.matchup-picker button:disabled { cursor: wait; opacity: .55; }

.notice { display: flex; align-items: center; gap: 12px; min-height: 46px; margin-bottom: 18px; padding: 10px 14px; border: 1px solid #6e5725; border-left: 3px solid var(--amber); background: #1c190f; color: #d8c99e; }
.notice strong { color: var(--amber); white-space: nowrap; }

.source-summary { margin: 0 0 18px; border: 1px solid var(--line); background: var(--surface); }
.source-summary summary { min-height: 66px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 14px; padding: 13px 16px; cursor: pointer; list-style: none; }
.source-summary summary::-webkit-details-marker { display: none; }
.source-summary summary::after { content: "+"; width: 24px; height: 24px; display: grid; place-items: center; border: 1px solid var(--line-strong); color: var(--muted); font-size: 16px; line-height: 1; }
.source-summary[open] summary::after { content: "−"; }
.source-summary summary:hover, .source-summary summary:focus-visible { background: #0e201a; outline: none; }
.source-summary summary:focus-visible { box-shadow: inset 0 0 0 2px var(--green); }
.source-summary__label { color: var(--green); font-size: 10px; font-weight: 800; white-space: nowrap; }
.source-summary__title { font-size: 15px; }
.source-summary__period { color: var(--muted); font-size: 11px; white-space: nowrap; }
.source-summary__body { padding: 16px; border-top: 1px solid var(--line); }
.source-summary__body p { max-width: 980px; margin-bottom: 9px; color: #aec2b9; }
.source-summary__counts { color: #c8d9d2 !important; font-variant-numeric: tabular-nums; }
.source-summary .source-summary__links { display: flex; flex-wrap: wrap; gap: 8px 20px; padding-top: 3px; }
.source-summary__links a { color: var(--green); font-weight: 750; }
.source-summary__links a:hover, .source-summary__links a:focus-visible { color: var(--text); text-decoration: underline; outline: none; }

.tier-filter { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 62px; margin-bottom: 18px; padding: 9px 12px 9px 16px; border: 1px solid var(--line); background: var(--surface); }
.tier-filter__heading { min-width: 230px; }
.tier-filter__heading h2 { margin-bottom: 1px; font-size: 14px; }
.tier-filter__heading p { margin-bottom: 0; color: var(--muted); font-size: 11px; }
.tier-filter__options { display: grid; grid-template-columns: repeat(4, minmax(96px, auto)); gap: 4px; }
.tier-filter__options button { min-height: 40px; border: 1px solid transparent; border-bottom-color: var(--line-strong); border-radius: 2px; background: transparent; color: #a9beb5; padding: 5px 13px; font-weight: 800; cursor: pointer; }
.tier-filter__options button:hover { border-color: #486b5d; background: #10231c; color: var(--text); }
.tier-filter__options button:focus-visible { outline: 2px solid var(--green); outline-offset: 1px; }
.tier-filter__options button[aria-pressed="true"] { border-color: #36765c; border-bottom-color: var(--green); background: #123025; color: var(--text); }
.tier-filter__options button:disabled { border-color: transparent; background: transparent; color: #52675f; cursor: not-allowed; }
.tier-filter__options button small { display: block; margin-top: -1px; color: var(--amber); font-size: 9px; font-weight: 700; }

.scope-dock { position: fixed; left: 0; right: 0; top: var(--bm-header-height, 65px); z-index: 19; border-bottom: 1px solid var(--line-strong); background: rgba(8, 20, 16, .97); box-shadow: 0 8px 22px rgba(0, 0, 0, .3); backdrop-filter: blur(10px); }
.scope-dock__inner { width: min(var(--max), calc(100% - 40px)); min-height: 42px; margin: 0 auto; display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 11px; }
.scope-dock__label { color: var(--green); font-weight: 800; }
.scope-dock__inner strong { color: var(--text); font-size: 13px; }
.scope-dock__counts { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.scope-dock__inner button { min-height: 30px; margin-left: auto; border: 1px solid var(--line-strong); border-radius: 3px; background: #10231c; color: var(--text); padding: 0 10px; font-size: 11px; font-weight: 800; cursor: pointer; }
.scope-dock__inner button:hover, .scope-dock__inner button:focus-visible { border-color: var(--green); outline: none; }

.metric-strip { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); background: var(--surface); margin-bottom: 22px; }
.metric { min-width: 0; padding: 20px 22px; border-right: 1px solid var(--line); }
.metric:last-child { border-right: 0; }
.metric span, .metric small { display: block; color: var(--muted); }
.metric strong { display: block; margin: 3px 0 1px; font-size: 29px; line-height: 1.15; font-variant-numeric: tabular-nums; }
.metric--accent strong { color: var(--text); }

.panel { margin-top: 38px; border: 0; border-top: 1px solid var(--line-strong); border-radius: 0; background: transparent; overflow: visible; }
.panel__header { min-height: 92px; padding: 22px 0; border-bottom: 0; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.panel__header p:last-child { margin-bottom: 0; color: var(--muted); }
.section-title-line { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.section-title-line h2 { margin-bottom: 0; }
.scope-badge { display: inline-flex; align-items: center; min-height: 22px; padding: 2px 7px; border: 1px solid #3e6657; border-radius: 3px; background: #0d211a; color: #bcd2c9; font-size: 10px; font-weight: 800; white-space: nowrap; }
.filters { display: flex; gap: 10px; }
.filters label, .matchup-picker label { color: var(--muted); font-size: 11px; font-weight: 700; }
select { display: block; min-width: 154px; height: 40px; margin-top: 4px; border: 1px solid var(--line-strong); border-radius: 4px; background: #091510; color: var(--text); padding: 0 34px 0 11px; }
select:focus-visible { outline: 2px solid var(--green); outline-offset: 1px; }

.table-wrap { width: 100%; max-width: 100%; overflow-x: clip; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th { height: 42px; padding: 0 14px; background: #0a1612; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 12px; text-align: right; white-space: nowrap; }
.ranking-table { table-layout: fixed; }
.ranking-table thead { box-shadow: 0 1px 0 var(--line); }
.ranking-col--rank { width: 4.5%; }
.ranking-col--weapon { width: 16%; }
.ranking-col--usage { width: 10%; }
.ranking-col--share { width: 8%; }
.ranking-col--damage { width: 12%; }
.ranking-col--kills { width: 11%; }
.ranking-col--top10 { width: 11%; }
.ranking-col--duel { width: 12%; }
.ranking-col--sample { width: 7.5%; }
td { height: 62px; padding: 8px 14px; border-bottom: 1px solid #193029; text-align: right; white-space: nowrap; }
th:nth-child(-n+2), td:nth-child(-n+2) { text-align: left; }
.ranking-table th[data-sort-key] { padding: 0; }
.sort-button { width: 100%; min-height: 42px; display: flex; align-items: center; justify-content: flex-end; gap: 5px; border: 0; background: transparent; color: inherit; padding: 5px 8px; font: inherit; font-weight: 800; line-height: 1.25; white-space: normal; text-align: right; cursor: pointer; }
.ranking-table th:nth-child(2) .sort-button { justify-content: flex-start; }
.sort-button:hover { color: var(--text); background: #10231c; }
.sort-button:focus-visible { position: relative; z-index: 1; outline: 2px solid var(--green); outline-offset: -2px; }
.sort-indicator { width: 10px; color: var(--green); font-size: 9px; text-align: center; }
tbody tr:hover { background: #10231c; }
.rank-number { color: var(--muted); font-weight: 800; }
.weapon-cell { min-width: 0; display: flex; align-items: center; gap: 8px; }
.weapon-thumb { width: 68px; height: 40px; flex: 0 0 68px; padding: 3px 4px; object-fit: contain; border: 0; background: transparent; filter: brightness(1.3) contrast(1.08) drop-shadow(0 4px 6px rgba(0,0,0,.45)); }
.weapon-cell > span { min-width: 0; }
.weapon-name, .weapon-category { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.weapon-thumb--fallback { display: grid; place-items: center; border: 1px solid var(--line); color: var(--muted); font-size: 10px; }
.weapon-name { display: block; font-weight: 800; }
.weapon-category { display: block; color: var(--muted); font-size: 11px; }
.primary-stat { color: var(--text); font-weight: 800; }
.sample-badge { display: inline-flex; align-items: center; justify-content: center; min-height: 24px; padding: 3px 7px; border: 1px solid var(--line-strong); border-radius: 3px; font-size: 10px; font-weight: 800; }
.sample-badge--ranking { width: 100%; max-width: 94px; min-height: 34px; flex-direction: column; gap: 1px; padding: 3px 4px; line-height: 1.2; white-space: normal; }
.sample-badge--ranking small { color: inherit; font-size: 9px; font-weight: 700; opacity: .82; }
.sample-badge[data-level="very-low"] { border-color: #8a3c38; color: #ff9f98; background: #261311; }
.sample-badge[data-level="low"] { border-color: #7a5c20; color: var(--amber); background: #251d0d; }
.sample-badge[data-level="building"] { color: #acd0c1; }
.sample-badge[data-level="usable"] { border-color: #4b655b; color: #c5d5cf; }
.ranking-actions { display: flex; justify-content: center; padding: 14px 0 2px; }
.ranking-actions button { min-height: 38px; padding: 0 18px; border: 1px solid var(--line-strong); border-radius: 4px; background: transparent; color: #c7d7d1; cursor: pointer; }
.ranking-actions button:hover, .ranking-actions button:focus-visible { border-color: #668579; background: #10201a; outline: none; }
.ranking-mobile { display: none; }
.panel__footnote { margin: 0; padding: 12px 0; color: var(--muted); font-size: 11px; }
.loading-cell { padding: 36px !important; color: var(--muted); text-align: center !important; }

.panel__header--matchup { align-items: flex-end; }
.heading-with-help { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; }
.heading-with-help h2 { margin-bottom: 0; }
.help-tooltip { position: relative; display: inline-flex; }
.help-tooltip__button { width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid #58756a; border-radius: 50%; background: transparent; color: #bdd0c8; padding: 0; font-size: 12px; font-weight: 900; cursor: help; }
.help-tooltip__button:hover, .help-tooltip__button:focus-visible { border-color: var(--green); color: var(--green); outline: none; }
.help-tooltip__content { position: absolute; left: 0; top: calc(100% + 9px); z-index: 30; box-sizing: border-box; width: min(390px, calc(100vw - 40px)); padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 4px; background: #10231c; color: #cfddd7; box-shadow: 0 14px 36px rgba(0,0,0,.45); font-size: 12px; font-weight: 500; line-height: 1.6; white-space: normal; overflow-wrap: anywhere; word-break: keep-all; text-align: left; opacity: 0; visibility: hidden; transform: translateY(-4px); transition: opacity .14s ease, transform .14s ease, visibility .14s; }
.help-tooltip:hover .help-tooltip__content, .help-tooltip:focus-within .help-tooltip__content { opacity: 1; visibility: visible; transform: translateY(0); }
.help-tooltip__content--right { left: auto; right: 0; }
.table-heading-with-help { display: flex; align-items: center; justify-content: center; gap: 5px; min-height: 44px; }
.table-heading-with-help .sort-button { width: auto; }
.matchup-picker { display: flex; align-items: flex-end; gap: 10px; }
.weapon-choice { width: 190px; }
.weapon-choice label { display: block; color: var(--muted); font-size: 11px; font-weight: 700; }
.weapon-choice select { width: 100%; min-width: 0; }
.versus { display: grid; place-items: center; width: 32px; height: 40px; color: var(--amber); font-weight: 900; }
.matchup-result { display: grid; grid-template-columns: 260px minmax(0, 1fr) 260px; min-height: 330px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.matchup-side { padding: 30px 24px; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; }
.matchup-side--a { border-right: 1px solid var(--line); }
.matchup-side--b { border-left: 1px solid var(--line); }
.weapon-visual { width: 210px; height: 100px; display: grid; place-items: center; margin-bottom: 12px; padding: 8px; border-bottom: 1px solid #30483f; background: transparent; }
.weapon-visual img { width: 100%; height: 100%; object-fit: contain; filter: brightness(1.28) contrast(1.08) drop-shadow(0 8px 9px rgba(0,0,0,.5)); }
.weapon-visual .fallback-label { color: var(--muted); font-size: 12px; border-bottom: 1px solid var(--line-strong); padding: 14px; }
.matchup-side p { margin-bottom: 2px; color: var(--muted); font-size: 11px; font-weight: 800; }
.matchup-side h3 { margin-bottom: 9px; font-size: 21px; }
.matchup-side strong { font-size: 34px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.matchup-side--a strong { color: var(--green); }
.matchup-side--b strong { color: var(--blue); }
.matchup-side > span { color: var(--muted); font-size: 11px; }
.matchup-centre { padding: 44px 34px; display: flex; flex-direction: column; justify-content: center; }
.sample-line { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 16px; }
.sample-line > strong { font-size: 18px; }
.win-bar { position: relative; height: 42px; display: flex; align-items: flex-end; overflow: visible; background: transparent; }
.win-bar > span { display: block; height: 16px; border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong); transition: width .25s ease; }
.win-bar__a { border-left: 1px solid var(--line-strong); background: var(--green-deep); }
.win-bar__b { border-right: 1px solid var(--line-strong); background: #326cae; }
.win-bar__labels { position: absolute; inset: 0 0 auto; display: flex; justify-content: space-between; align-items: center; font-size: 13px; font-variant-numeric: tabular-nums; }
.win-bar__labels strong:first-child { color: var(--green); }
.win-bar__labels strong:last-child { color: var(--blue); }
.matchup-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 18px; border: 1px solid var(--line); }
.matchup-stats div { padding: 12px; border-right: 1px solid var(--line); text-align: center; }
.matchup-stats div:last-child { border-right: 0; }
.matchup-stats span { display: block; color: var(--muted); font-size: 10px; }
.matchup-stats strong { display: block; margin-top: 3px; font-size: 14px; font-variant-numeric: tabular-nums; }
.distance-section { border-top: 1px solid var(--line); padding: 20px 22px 24px; }
.subsection-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 14px; }
.subsection-heading h3, .subsection-heading p { margin-bottom: 0; }
.subsection-heading p { color: var(--muted); font-size: 11px; }
.distance-grid { display: grid; grid-template-columns: repeat(5, 1fr); border: 1px solid var(--line); }
.distance-card { min-width: 0; padding: 14px; border-right: 1px solid var(--line); }
.distance-card:last-child { border-right: 0; }
.distance-card__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.distance-card h4 { margin: 0; font-size: 13px; }
.distance-card small { color: var(--muted); }
.distance-card strong { display: block; margin: 12px 0 5px; font-size: 22px; color: var(--text); font-variant-numeric: tabular-nums; }
.mini-bar { height: 5px; background: #173029; overflow: hidden; }
.mini-bar span { display: block; height: 100%; background: var(--green); }
.distance-card p { margin: 7px 0 0; color: var(--muted); font-size: 10px; }

.legend { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; }
.legend span { width: 13px; height: 7px; margin-left: 8px; }
.legend__a { background: var(--green-deep); }
.legend__b { background: #326cae; }
.comparison-tabs { display: flex; border-bottom: 1px solid var(--line); }
.comparison-tabs button { min-width: 170px; min-height: 46px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); padding: 0 18px; font-weight: 800; cursor: pointer; }
.comparison-tabs button:hover { color: var(--text); background: #0c1c17; }
.comparison-tabs button[aria-selected="true"] { border-bottom-color: var(--green); color: var(--text); }
.comparison-tabs button:focus-visible { outline: 2px solid var(--green); outline-offset: -3px; }
.comparison-panel { padding-top: 18px; }
.reference-toolbar { display: flex; align-items: flex-end; gap: 14px; padding: 0 0 18px; }
.reference-toolbar label { color: var(--muted); font-size: 11px; font-weight: 800; }
.reference-toolbar select { width: 210px; margin-top: 4px; }
.reference-toolbar p { margin: 0 0 9px; color: var(--muted); font-size: 12px; }
.reference-toolbar p strong { color: var(--text); }
.reference-overall { display: grid; grid-template-columns: minmax(180px, .7fr) minmax(180px, .7fr) minmax(280px, 1.6fr); border: 1px solid var(--line); border-bottom: 0; background: #0b1713; }
.reference-overall > div, .reference-overall > p { min-width: 0; margin: 0; padding: 14px 16px; }
.reference-overall > div + div, .reference-overall > p { border-left: 1px solid var(--line); }
.reference-overall span, .reference-overall small { display: block; color: var(--muted); font-size: 10px; }
.reference-overall strong { display: block; margin: 3px 0; color: var(--text); font-size: 19px; }
.reference-overall > p { align-self: stretch; display: flex; align-items: center; color: var(--muted); font-size: 11px; line-height: 1.55; }
.reference-matchups { border-top: 1px solid var(--line); }
.reference-matchup { width: 100%; min-height: 86px; display: grid; grid-template-columns: minmax(180px, 1fr) minmax(230px, 1.25fr) minmax(180px, 1fr); align-items: center; gap: 20px; border: 0; border-bottom: 1px solid #193029; background: transparent; color: var(--text); padding: 10px 16px; text-align: left; cursor: pointer; }
.reference-matchup:hover { background: #10231c; }
.reference-matchup:focus-visible { position: relative; z-index: 1; outline: 2px solid var(--green); outline-offset: -2px; }
.reference-matchup:disabled { cursor: default; opacity: .5; }
.reference-matchup:disabled:hover { background: transparent; }
.reference-side { min-width: 0; display: flex; align-items: center; gap: 12px; }
.reference-side--opponent { flex-direction: row-reverse; text-align: right; }
.reference-side span { min-width: 0; }
.reference-side small, .reference-side strong { display: block; }
.reference-side small { color: var(--muted); font-size: 10px; }
.reference-side strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.reference-weapon-image { width: 112px; height: 56px; object-fit: contain; filter: brightness(1.28) contrast(1.08) drop-shadow(0 5px 7px rgba(0,0,0,.5)); }
.reference-score { min-width: 0; display: flex; flex-direction: column; align-items: center; text-align: center; }
.reference-score__numbers { display: flex; align-items: baseline; gap: 7px; }
.reference-score__numbers strong { color: var(--green); font-size: 22px; font-variant-numeric: tabular-nums; }
.reference-score__numbers small { color: var(--blue); font-size: 12px; font-weight: 800; }
.reference-score__bar { width: 100%; height: 6px; display: block; margin: 6px 0; overflow: hidden; background: #326cae; }
.reference-score__bar span { display: block; height: 100%; background: var(--green-deep); }
.reference-score > small { color: var(--muted); font-size: 10px; }
.reference-load-more { display: flex; justify-content: center; padding: 18px 0 2px; }
.reference-load-more button { min-width: 210px; min-height: 42px; border: 1px solid var(--line-strong); border-radius: 4px; background: #0d1d17; color: var(--text); font-weight: 800; cursor: pointer; }
.reference-load-more button span { margin-left: 6px; color: var(--muted); font-size: 11px; font-weight: 600; }
.reference-load-more button:hover, .reference-load-more button:focus-visible { border-color: var(--green); background: #123025; outline: none; }
.matrix-guide { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 16px 8px; }
.matrix-guide p { margin: 0; color: var(--muted); font-size: 12px; }
.matrix-guide strong { color: var(--text); }
.matrix-wrap { overflow-x: auto; padding: 8px 16px 16px; }
.matrix-table { width: max-content; min-width: 100%; table-layout: fixed; }
.matrix-table th, .matrix-table td { width: 92px; min-width: 92px; height: 60px; padding: 5px; text-align: center; }
.matrix-table th:first-child, .matrix-table td:first-child { position: sticky; left: 0; z-index: 2; width: 110px; min-width: 110px; background: #0a1612; text-align: left; }
.matrix-cell { font-weight: 800; }
.matrix-cell small { display: block; color: rgba(255,255,255,.66); font-weight: 500; }
.matrix-cell--empty { color: #486059; }
.matrix-cell__button { width: 100%; height: 100%; border: 0; background: transparent; color: var(--text); padding: 0; cursor: pointer; }
.matrix-cell__button strong, .matrix-cell__button small { display: block; }
.matrix-cell__button:hover { background: rgba(255,255,255,.08); }
.matrix-cell__button:focus-visible { outline: 2px solid var(--green); outline-offset: -2px; }

.analysis-reading { margin-top: 34px; padding: 24px 0 28px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.analysis-reading__heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.analysis-reading__heading .eyebrow { margin: 0 0 4px; color: var(--green); font-size: 11px; font-weight: 800; }
.analysis-reading__heading h2 { margin: 0; font-size: 20px; }
.analysis-reading__heading > a { color: var(--muted); font-size: 12px; font-weight: 700; }
.analysis-reading__heading > a:hover, .analysis-reading__heading > a:focus-visible { color: var(--text); outline: none; text-decoration: underline; }
.analysis-reading__links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.analysis-reading__links a { min-width: 0; display: grid; gap: 5px; padding: 16px 18px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--text); }
.analysis-reading__links strong { font-size: 14px; }
.analysis-reading__links span { color: var(--muted); font-size: 11px; line-height: 1.5; }
.analysis-reading__links a:hover, .analysis-reading__links a:focus-visible { background: #0d2119; outline: none; }

.method-note { margin-top: 28px; padding: 22px 0; border-top: 1px solid var(--line); color: var(--muted); }
.method-note h2 { color: var(--text); font-size: 17px; }
.method-note p { max-width: 980px; margin-bottom: 0; }
footer { min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 20px; width: min(var(--max), calc(100% - 40px)); margin: 0 auto; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 16px; }
.footer-links a:hover, .footer-links a:focus-visible { color: var(--text); outline: none; text-decoration: underline; }
.error-banner { position: fixed; left: 50%; bottom: 24px; z-index: 50; transform: translateX(-50%); max-width: min(600px, calc(100% - 32px)); padding: 12px 16px; border: 1px solid var(--red); background: #29120f; color: #ffd1cc; box-shadow: 0 14px 40px rgba(0,0,0,.45); }

@media (max-width: 1100px) {
  .section-nav { gap: 16px; font-size: 12px; }
  .ranked-badge { margin-left: auto; }
  .table-wrap { overflow-x: auto; overscroll-behavior-inline: contain; }
  .ranking-table { min-width: 1390px; }
  .ranking-table .weapon-cell { min-width: 210px; gap: 12px; }
  .ranking-table .weapon-thumb { width: 88px; height: 44px; flex-basis: 88px; }
  .ranking-table .sort-button { padding-inline: 14px; white-space: nowrap; }
  .panel__header--matchup { align-items: flex-start; flex-direction: column; }
  .matchup-result { grid-template-columns: 210px minmax(0, 1fr) 210px; }
  .distance-grid { grid-template-columns: repeat(3, 1fr); }
  .distance-card { border-bottom: 1px solid var(--line); }
  .reference-matchup { grid-template-columns: minmax(150px, 1fr) minmax(200px, 1.15fr) minmax(150px, 1fr); gap: 10px; }
  .reference-weapon-image { width: 88px; }
  .source-summary summary { grid-template-columns: auto minmax(0, 1fr) auto auto; }
}

@media (max-width: 780px) {
  .section-nav { display: none; }
  .topbar__inner, main, footer { width: min(100% - 24px, var(--max)); }
  main { padding-top: 30px; }
  .intro { align-items: flex-start; flex-direction: column; gap: 18px; }
  .intro__meta { width: 100%; align-items: stretch; flex-wrap: wrap; white-space: normal; }
  .patch-picker { flex: 1 1 190px; }
  .patch-picker select { width: 100%; }
  .data-freshness { flex: 1 1 180px; align-items: flex-start; justify-content: flex-end; }
  .notice { align-items: flex-start; flex-direction: column; gap: 4px; }
  .notice strong { white-space: normal; }
  .source-summary summary { grid-template-columns: 1fr auto; gap: 3px 12px; padding: 12px 13px; }
  .source-summary__label { grid-column: 1; }
  .source-summary__title { grid-column: 1; }
  .source-summary__period { grid-column: 1; white-space: normal; }
  .source-summary summary::after { grid-column: 2; grid-row: 1 / span 3; }
  .tier-filter { align-items: stretch; flex-direction: column; gap: 9px; padding: 13px; }
  .tier-filter__heading { min-width: 0; }
  .tier-filter__options { grid-template-columns: 1fr 1fr; }
  .scope-dock__inner { width: calc(100% - 24px); gap: 8px; }
  .scope-dock__label { display: none; }
  .scope-dock__counts { font-size: 10px; }
  .metric-strip { grid-template-columns: 1fr 1fr; }
  .metric:nth-child(2) { border-right: 0; }
  .metric:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .panel__header { align-items: flex-start; flex-direction: column; }
  .help-tooltip__content { position: fixed; left: 16px; right: 16px; top: calc(var(--bm-header-height, 90px) + 8px); width: auto; }
  .filters, .matchup-picker { width: 100%; flex-wrap: wrap; }
  .filters label, .weapon-choice { flex: 1 1 170px; width: auto; }
  select { width: 100%; min-width: 0; }
  #rankings .table-wrap { display: none; }
  .ranking-mobile { display: block; border-top: 1px solid var(--line); }
  .ranking-mobile__sort { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 12px 0; }
  .ranking-mobile__sort button { min-width: 0; min-height: 40px; display: flex; align-items: center; justify-content: center; gap: 4px; border: 1px solid var(--line); border-radius: 4px; background: #0a1612; color: var(--muted); padding: 5px 7px; font-size: 11px; font-weight: 800; cursor: pointer; }
  .ranking-mobile__sort button[aria-pressed="true"] { border-color: var(--green); background: #102a20; color: var(--text); }
  .ranking-mobile__sort button:focus-visible { outline: 2px solid var(--green); outline-offset: 1px; }
  .ranking-mobile__list { display: grid; gap: 10px; }
  .ranking-card { border: 1px solid var(--line); border-radius: 4px; background: #091510; overflow: hidden; }
  .ranking-card__header { min-height: 72px; display: grid; grid-template-columns: 28px 72px minmax(0, 1fr) auto; align-items: center; gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--line); }
  .ranking-card__rank { color: var(--muted); font-size: 13px; font-weight: 900; text-align: center; }
  .ranking-card__image { width: 72px; height: 48px; object-fit: contain; filter: brightness(1.3) contrast(1.08) drop-shadow(0 4px 6px rgba(0,0,0,.45)); }
  .ranking-card__identity { min-width: 0; }
  .ranking-card__identity strong, .ranking-card__identity small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ranking-card__identity strong { font-size: 15px; }
  .ranking-card__identity small { color: var(--muted); font-size: 10px; }
  .ranking-card .sample-badge--ranking { width: 62px; }
  .ranking-card__metrics { display: grid; grid-template-columns: 1fr 1fr; }
  .ranking-card__metrics > div { min-width: 0; padding: 11px 12px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
  .ranking-card__metrics > div:nth-child(even) { border-right: 0; }
  .ranking-card__metrics span, .ranking-card__metrics small { display: block; color: var(--muted); font-size: 10px; }
  .ranking-card__metrics strong { display: block; margin: 2px 0; color: var(--text); font-size: 18px; line-height: 1.2; font-variant-numeric: tabular-nums; }
  .ranking-card__details summary { min-height: 44px; display: flex; align-items: center; justify-content: center; color: #bfd0c9; font-size: 11px; font-weight: 800; cursor: pointer; list-style: none; }
  .ranking-card__details summary::-webkit-details-marker { display: none; }
  .ranking-card__details summary::after { content: "+"; margin-left: 6px; color: var(--green); }
  .ranking-card__details[open] summary::after { content: "−"; }
  .ranking-card__details dl { display: grid; grid-template-columns: 1fr 1fr; margin: 0; border-top: 1px solid var(--line); }
  .ranking-card__details dl > div { padding: 9px 12px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
  .ranking-card__details dl > div:nth-child(even) { border-right: 0; }
  .ranking-card__details dt { color: var(--muted); font-size: 10px; }
  .ranking-card__details dd { margin: 2px 0 0; color: var(--text); font-weight: 800; }
  .ranking-card__details dd small { color: var(--muted); font-weight: 500; }
  .versus { display: none; }
  .matchup-picker button { flex: 1 1 100%; }
  .matchup-result { grid-template-columns: 1fr 1fr; }
  .matchup-centre { grid-column: 1 / -1; grid-row: 2; border-top: 1px solid var(--line); padding: 28px 18px; }
  .matchup-side { min-width: 0; padding: 20px 12px; }
  .matchup-side--a { border-right: 1px solid var(--line); }
  .matchup-side--b { border-left: 0; }
  .weapon-visual { width: min(180px, 100%); height: 82px; }
  .matchup-stats { grid-template-columns: 1fr; }
  .matchup-stats div { border-right: 0; border-bottom: 1px solid var(--line); }
  .matchup-stats div:last-child { border-bottom: 0; }
  .distance-grid { grid-template-columns: 1fr 1fr; }
  .distance-card:nth-child(even) { border-right: 0; }
  .reference-toolbar { align-items: flex-start; flex-direction: column; }
  .reference-toolbar label, .reference-toolbar select { width: 100%; }
  .reference-overall { grid-template-columns: 1fr 1fr; }
  .reference-overall > p { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--line); }
  .reference-matchup { grid-template-columns: 1fr; gap: 8px; padding: 14px 10px; }
  .reference-side, .reference-side--opponent { flex-direction: row; justify-content: flex-start; text-align: left; }
  .reference-score { order: 3; }
  .reference-side--opponent { order: 2; }
  .matrix-guide { align-items: flex-start; flex-direction: column; }
  .analysis-reading__heading { align-items: flex-start; flex-direction: column; gap: 8px; }
  .analysis-reading__links { grid-template-columns: 1fr; }
  footer { padding: 18px 0; flex-direction: column; align-items: flex-start; justify-content: center; }
  .footer-links { justify-content: flex-start; }
}

.report-entry { margin: 18px 0; padding: 18px 20px; border: 1px solid var(--line); border-left: 3px solid #51b497; border-radius: 8px; background: rgba(50,130,108,.08); }
.report-entry > span { display: block; color: var(--muted); font-size: 12px; margin-bottom: 6px; }
.report-entry > a { display: inline-block; color: inherit; font-weight: 700; font-size: 18px; line-height: 1.5; text-decoration: none; }
.report-entry > a:hover, .report-entry > a:focus-visible { text-decoration: underline; }
.report-entry > p { margin: 7px 0 0; color: var(--muted); font-size: 13px; }
#rankings, #matchup, #matrix { scroll-margin-top: 80px; }

@media (max-width: 460px) {
  h1 { font-size: 32px; }
  .ranked-badge { font-size: 10px; }
  .metric { padding: 15px; }
  .metric strong { font-size: 24px; }
  .tier-filter__options button { min-width: 0; padding-inline: 7px; }
  .scope-dock__counts { display: none; }
  .distance-grid { grid-template-columns: 1fr; }
  .distance-card { border-right: 0; }
  .subsection-heading { align-items: flex-start; flex-direction: column; gap: 4px; }
  .comparison-tabs button { min-width: 0; flex: 1; padding: 0 8px; font-size: 12px; }
}
