:root {
    color-scheme: dark;
    --bg: #08090a;
    --panel: #151618;
    --panel-2: #1b1c1f;
    --panel-3: #24262a;
    --line: #33363b;
    --line-soft: #27292d;
    --text: #f4f4f5;
    --soft: #a7a9af;
    --muted: #70737a;
    --brand: #ff9862;
    --green: #18bf88;
    --green-soft: #8bd8bd;
    --green-base: oklch(69.6% .17 162.48);
    --green-deep: color-mix(in oklch, var(--green-base), black 30%);
    --green-pale: color-mix(in oklch, var(--green-base), white 55%);
    --red: #e83262;
    --blue: #3baeea;
    --bronze: #c77b42;
    --silver: #b9bdc5;
    --gold: #dda72f;
    --platinum: #b8e2df;
    --diamond: #82b9ef;
    --master: #7ec9ad;
    --grandmaster: #b79be8;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    min-width: 320px;
    background:
        radial-gradient(circle at 10% 4%, rgba(180, 65, 21, .08), transparent 23rem),
        var(--bg);
    color: var(--text);
    font-family: Inter, "Pretendard GOV Variable", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.45;
}
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
a { color: inherit; text-decoration: none; }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.page-shell { width: min(1420px, calc(100% - 64px)); margin: 0 auto; }
.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;
}

.topbar {
    position: sticky;
    inset: 0 0 auto;
    z-index: 40;
    height: 54px;
    border-bottom: 1px solid #25272a;
    background: rgba(20, 21, 23, .96);
    backdrop-filter: blur(18px);
}
.topbar-inner { height: 100%; display: flex; align-items: center; gap: 28px; }
.brand {
    display: inline-flex;
    align-items: baseline;
    font-size: 1.42rem;
    font-weight: 950;
    letter-spacing: -.075em;
}
.brand b { color: var(--brand); }
.brand em { color: #8a8d94; font-size: .68em; font-style: normal; letter-spacing: -.02em; }
.main-nav { display: flex; height: 100%; gap: 6px; }
.main-nav a {
    position: relative;
    display: flex;
    align-items: center;
    padding: 0 15px;
    color: #a5a7ac;
    font-size: .86rem;
    font-weight: 750;
}
.main-nav a:hover, .main-nav a.active { color: #fff; background: rgba(255,255,255,.035); }
.main-nav a.active::after { content: ""; position: absolute; inset: auto 14px 0; height: 2px; background: var(--brand); }
.topbar-meta { margin-left: auto; display: flex; align-items: center; gap: 8px; color: #91949b; font-size: .72rem; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(24,191,136,.12); }

.page-heading { min-height: 126px; display: flex; align-items: center; justify-content: space-between; }
.page-heading > div:first-child { display: flex; align-items: baseline; gap: 14px; }
.page-heading h1 { margin: 0; color: #ffb184; font-size: 2rem; line-height: 1; letter-spacing: -.04em; }
.page-heading p { margin: 0; color: #c4c5c9; font-size: .82rem; font-weight: 700; }
.page-heading p i { margin: 0 7px; color: #6f7177; font-style: normal; }
.updated-copy { text-align: right; }
.updated-copy span, .updated-copy strong { display: block; }
.updated-copy span { color: var(--muted); font-size: .68rem; }
.updated-copy strong { margin-top: 3px; color: var(--soft); font-size: .72rem; font-weight: 650; }

.overview-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.overview-card {
    --muted: #a1a1aa;
    --green-soft: var(--green-base);
    min-height: 554px;
    display: flex;
    flex-direction: column;
    padding: 16px;
    border: 1px solid #3f3f46;
    border-radius: 12px;
    background: #18181b;
    box-shadow: 0 16px 44px rgba(0,0,0,.22);
}
.overview-card > header { min-height: 24px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.overview-card header > div:first-child { display: flex; align-items: baseline; gap: 7px; min-width: 0; }
.overview-card h2 { margin: 0; font-size: 1.02rem; letter-spacing: -.025em; }
.overview-card header span { color: var(--muted); font-size: .75rem; font-weight: 650; white-space: nowrap; }
.card-tags { display: flex; gap: 4px; }
.card-tags span { padding: 2px 6px; border-radius: 4px; background: #27272a; color: #a1a1aa !important; font-size: .625rem; }
.overview-card footer {
    min-height: 44px;
    margin-top: 12px;
    padding-top: 8px;
    border-top: 1px solid #3f3f46;
    display: flex;
    justify-content: space-between;
    color: #a1a1aa;
    font-size: .75rem;
}
.skeleton-stack::before {
    content: "正在生成竞技环境概览…";
    display: grid;
    min-height: 230px;
    place-items: center;
    color: var(--muted);
    font-size: .72rem;
}

.trend-list, .map-meta-list, .role-meta-list { flex: 1; min-width: 0; }
.trend-list, .map-meta-list { padding: 2px 0; }
.role-meta-list { padding: 0; }
.trend-row {
    display: grid;
    grid-template-columns: 150px 1fr 58px;
    align-items: center;
    gap: 10px;
    min-height: 44px;
}
.hero-ident { min-width: 0; display: flex; align-items: center; gap: 9px; }
.hero-avatar {
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    overflow: hidden;
    border: 1px solid #3d4046;
    border-radius: 7px;
    background: #27292d;
    object-fit: cover;
}
.hero-ident div { min-width: 0; }
.hero-ident strong, .hero-ident small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hero-ident strong { font-size: .77rem; }
.hero-ident small { margin-top: 1px; color: #767980; font-size: .61rem; }
.delta-track, .metric-track {
    position: relative;
    height: 15px;
    overflow: hidden;
    border-radius: 5px;
    background: #27272a;
}
.delta-track i, .metric-track i {
    position: absolute;
    top: 0;
    bottom: 0;
    border-radius: 4px;
}
.delta-track::after { content: ""; position: absolute; left: 50%; top: 0; bottom: 0; width: 1px; background: #4b4e54; }
.delta-track i.up { left: 50%; background: linear-gradient(90deg, #0f7758, #139c72); }
.delta-track i.down { right: 50%; background: linear-gradient(90deg, #bf234c, #761631); }
.trend-row > strong { text-align: right; font-size: .72rem; }
.positive { color: var(--green); }
.negative { color: var(--red); }

.map-row {
    display: grid;
    grid-template-columns: 40px minmax(0, 2fr) minmax(64px, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 4px;
    border-radius: 4px;
    transition: background .15s ease;
}
.map-row:hover { background: rgba(255,255,255,.035); }
.map-row:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
.map-row:hover .map-ident-copy strong { color: var(--brand); }
.map-thumb {
    width: 40px;
    height: 28px;
    display: block;
    flex: 0 0 auto;
    border-radius: 6px;
    background:
        linear-gradient(135deg, rgba(255,152,98,.55), transparent 55%),
        #2d3035;
    object-fit: cover;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.08);
}
.map-ident-copy { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.map-ident-copy strong {
    overflow: hidden;
    font-size: .875rem;
    font-weight: 500;
    line-height: 1.15;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.map-ident-copy small {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    color: #a1a1aa;
    font-size: .625rem;
    line-height: 1.15;
}
.map-mode { flex: 0 0 auto; text-transform: uppercase; letter-spacing: .04em; }
.map-meta-hero {
    min-width: 0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 1px 4px;
    overflow: hidden;
    border-radius: 3px;
    background: #27272a;
    color: #a1a1aa;
}
.map-meta-hero span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
}
.map-meta-hero-avatar {
    width: 12px;
    height: 12px;
    display: block;
    flex: 0 0 auto;
    border-radius: 3px;
    background: #32353a;
    object-fit: cover;
}
.metric-track i { left: 0; background: var(--green-deep); }
.map-lift-track { height: 14px; overflow: visible; }
.map-ratio {
    position: absolute;
    top: 50%;
    z-index: 1;
    padding: 0 4px;
    color: var(--muted);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .625rem;
    font-weight: 650;
    line-height: 1;
    white-space: nowrap;
    transform: translateY(-50%);
}
.map-ratio.positive { color: var(--green-soft); }
.map-row > strong {
    min-width: 40px;
    text-align: right;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .75rem;
}
.map-meta-footer { gap: 12px; }
.map-meta-footer > span { min-width: 0; }
.map-meta-footer a {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 6px;
    margin-left: auto;
    padding: 0;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: var(--text);
    font: inherit;
    font-weight: 500;
}
.map-meta-footer a:hover { color: var(--brand); }
.map-meta-footer a:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
.map-meta-footer a i { font-size: .78rem; font-style: normal; }

.role-section { padding: 4px 0; }
.role-section:first-child { padding-top: 0; }
.role-section + .role-section { border-top: 1px solid #3f3f46; }
.role-title { display: flex; align-items: baseline; justify-content: space-between; padding: 4px 4px 2px; }
.role-title strong { font-size: .6875rem; letter-spacing: .04em; }
.role-title strong.role-tank { color: oklch(76.9% .188 70.08); }
.role-title strong.role-damage { color: oklch(63.7% .237 25.331); }
.role-title strong.role-support { color: oklch(72.3% .219 149.579); }
.role-title span {
    color: #a1a1aa;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .625rem;
}
.role-title strong, .role-title span { line-height: 1.5; }
.role-row {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) 1fr auto;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 4px;
    border-radius: 4px;
}
.role-row:hover { background: rgba(255,255,255,.035); }
.role-hero-ident { min-width: 0; display: flex; align-items: center; gap: 8px; }
.role-hero-ident .hero-avatar { width: 28px; height: 28px; border: 0; border-radius: 8px; }
.role-hero-ident > div { min-width: 0; }
.role-hero-ident strong,
.role-hero-ident small {
    display: block;
    overflow: hidden;
    line-height: 1.15;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.role-hero-ident strong { font-size: .875rem; font-weight: 500; }
.role-hero-ident small { color: #a1a1aa; font-size: .625rem; }
.win-track { height: 14px; overflow: visible; }
.win-track i { background: var(--green-deep); }
.role-win-label {
    position: absolute;
    top: 50%;
    z-index: 1;
    padding: 0 2px;
    color: var(--text);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .625rem;
    font-weight: 650;
    line-height: 1;
    white-space: nowrap;
    transform: translateY(-50%);
}
.role-win-label.muted { color: var(--muted); }
.role-row > strong {
    min-width: 48px;
    text-align: right;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .75rem;
}

.filter-panel {
    margin-top: 24px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: #151618;
}
.filter-segments { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.segmented { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; min-height: 39px; padding: 3px; border-radius: 8px; background: #25262a; }
.segmented button { border: 0; border-radius: 6px; background: transparent; color: #9b9da3; cursor: pointer; font-size: .72rem; font-weight: 750; }
.segmented button:hover { color: #fff; }
.segmented button.active { color: #ffb184; background: #191a1d; box-shadow: 0 2px 8px rgba(0,0,0,.22); }
.filter-selects { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 12px; }
.filter-selects label { min-width: 0; }
.filter-selects select {
    width: 100%;
    height: 45px;
    padding: 0 36px 0 13px;
    border: 1px solid #34373c;
    border-radius: 9px;
    outline: none;
    background: #1a1b1e;
    color: #e9e9eb;
    cursor: pointer;
    font-size: .74rem;
}
.filter-selects select:focus { border-color: #5d6067; }

.stats-panel, .hero-directory {
    margin-top: 24px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: #151618;
}
.stats-summary {
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 0 16px;
    border-bottom: 1px solid var(--line);
    background: #242529;
    color: #aaacb1;
    font-size: .66rem;
}
.stats-summary strong { color: #fff; }
.summary-divider { width: 1px; height: 15px; background: #3a3c41; }
.scatter-button {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 10px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #e4e5e7;
    cursor: pointer;
    font-size: .68rem;
    font-weight: 700;
}
.scatter-button:hover { background: rgba(255,255,255,.06); }
.scatter-button svg { width: 16px; height: 16px; }
.table-scroll { overflow-x: auto; }
.hero-table { width: 100%; min-width: 1120px; border-collapse: collapse; table-layout: fixed; }
.hero-table th, .hero-table td { border-bottom: 1px solid #2c2e32; text-align: left; }
.hero-table th { height: 38px; padding: 0 11px; background: #191a1d; color: #a8abb1; font-size: .64rem; font-weight: 650; }
.hero-table th:first-child { width: 190px; }
.hero-table th:nth-child(2), .hero-table th:nth-child(3), .hero-table th:nth-child(4) { width: 150px; }
.hero-table th:nth-child(n+5) { width: 170px; }
.hero-table th button { padding: 0; border: 0; background: transparent; color: inherit; cursor: pointer; font-size: inherit; font-weight: inherit; }
.hero-table th button:hover { color: #fff; }
.hero-table th span { margin-left: 3px; color: #65686e; }
.hero-table td { height: 49px; padding: 5px 11px; color: #d6d7da; font-size: .7rem; }
.hero-table tbody tr:hover { background: rgba(255,255,255,.025); }
.hero-table .hero-ident strong { font-size: .73rem; }
.hero-table .hero-ident small { font-size: .57rem; }
.hero-table .hero-avatar { width: 32px; height: 32px; }
.value-cell {
    position: relative;
    height: 31px;
    overflow: hidden;
    border-radius: 5px;
    background: #202226;
}
.value-cell i { position: absolute; inset: 0 auto 0 0; opacity: .58; border-radius: inherit; }
.value-cell span { position: relative; z-index: 1; display: block; padding: 7px 9px; color: #f0f1f2; font-size: .72rem; font-weight: 750; }
.value-pick i { background: #164e6b; }
.value-win.good i { background: #13563f; }
.value-win.bad i { background: #66182f; }
.value-ban i { background: #532132; }
.value-win.good span { color: #28c893; }
.value-win.bad span { color: #e43b69; }
.rank-bars { height: 31px; display: flex; align-items: flex-end; gap: 3px; padding: 5px 6px; border-radius: 5px; background: #202226; }
.rank-bars i { width: 9px; min-height: 2px; border-radius: 3px 3px 1px 1px; opacity: .95; }
.rank-win { align-items: center; }
.rank-win i { height: 18px !important; min-height: 18px; border-radius: 3px; }
.rank-win i.good { background: #79cbb0 !important; }
.rank-win i.bad { background: #e77b91 !important; }
.rank-win i.neutral { background: #d3d4d7 !important; }
.rank-bronze { background: var(--bronze) !important; }
.rank-silver { background: var(--silver) !important; }
.rank-gold { background: var(--gold) !important; }
.rank-platinum { background: var(--platinum) !important; }
.rank-diamond { background: var(--diamond) !important; }
.rank-master { background: var(--master) !important; }
.rank-grandmaster { background: var(--grandmaster) !important; }
.info-dot {
    display: inline-grid;
    width: 13px;
    height: 13px;
    margin-left: 3px;
    padding: 0;
    place-items: center;
    border: 1px solid #777a80;
    border-radius: 50%;
    background: transparent;
    color: #92959a !important;
    cursor: pointer;
    font-size: .5rem;
    line-height: 1;
}
.info-dot:hover,
.info-dot[aria-expanded="true"] { border-color: var(--brand); background: rgba(255,152,98,.1); color: var(--brand) !important; }
.info-dot:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.rank-legend {
    min-height: 36px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 14px;
    color: #85888e;
    font-size: .59rem;
}
.rank-legend > span { margin-right: 3px; color: #b0b2b7; }
.rank-legend i { width: 8px; height: 8px; margin-left: 4px; border-radius: 2px; }
.rank-color-help {
    position: fixed;
    z-index: 95;
    width: min(320px, calc(100vw - 24px));
    display: none;
    padding: 14px;
    border: 1px solid #45484f;
    border-radius: 11px;
    background: #1b1c20;
    box-shadow: 0 18px 50px rgba(0,0,0,.55);
}
.rank-color-help.open { display: block; }
.rank-color-help header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.rank-color-help header div { display: grid; gap: 2px; }
.rank-color-help header span { color: var(--brand); font-size: .53rem; font-weight: 850; letter-spacing: .13em; }
.rank-color-help header strong { color: #f0f1f3; font-size: .78rem; }
.rank-color-help header button {
    width: 26px;
    height: 26px;
    padding: 0;
    border: 1px solid #40434a;
    border-radius: 6px;
    background: #25272b;
    color: #b8bac0;
    cursor: pointer;
}
.rank-color-help header button:hover { border-color: #666a72; color: #fff; }
.rank-color-help > p { margin: 10px 0; color: #8b8e95; font-size: .62rem; }
.rank-color-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 7px 12px; }
.rank-color-grid span { display: flex; align-items: center; gap: 7px; color: #c7c9cd; font-size: .64rem; }
.rank-color-grid i { width: 11px; height: 11px; flex: 0 0 auto; border-radius: 3px; }
.rank-color-help footer {
    margin-top: 11px;
    padding-top: 9px;
    border-top: 1px solid #303238;
    color: #74777e;
    font-size: .59rem;
}
.empty-state { padding: 54px 20px; text-align: center; }
.empty-state strong { font-size: .95rem; }
.empty-state p { margin: 5px 0 0; color: var(--muted); font-size: .72rem; }

.hero-directory { margin-bottom: 90px; padding: 16px; }
.hero-directory > header h2 { margin: 0 0 14px; font-size: .9rem; }
.directory-tools { display: flex; align-items: center; gap: 12px; }
.hero-search { position: relative; flex: 1; }
.hero-search svg { position: absolute; left: 12px; top: 50%; width: 15px; height: 15px; color: #767980; transform: translateY(-50%); }
.hero-search input {
    width: 100%;
    height: 39px;
    padding: 0 12px 0 37px;
    border: 1px solid transparent;
    border-radius: 7px;
    outline: none;
    background: #27282d;
    color: #fff;
    font-size: .72rem;
}
.hero-search input:focus { border-color: #50535a; }
.directory-role-tabs { display: flex; gap: 4px; }
.directory-role-tabs button { padding: 8px 13px; border: 0; border-radius: 6px; background: transparent; color: #96999f; cursor: pointer; font-size: .68rem; font-weight: 700; }
.directory-role-tabs button.active { background: #e5e5e7; color: #202124; }
.hero-directory-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 16px; }
.directory-column[hidden] { display: none; }
.directory-column-title { display: flex; align-items: center; gap: 7px; margin-bottom: 10px; font-size: .72rem; }
.directory-column-title span { color: #777a80; font-weight: 500; }
.subrole-group + .subrole-group { margin-top: 15px; }
.subrole-group > span { display: block; margin-bottom: 7px; color: #85888e; font-size: .61rem; }
.avatar-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(49px, 1fr)); gap: 9px 7px; }
.avatar-card { min-width: 0; display: block; border: 0; background: transparent; color: #ddd; cursor: pointer; text-align: center; }
.avatar-card img {
    width: 44px;
    height: 44px;
    display: block;
    margin: 0 auto 4px;
    border: 1px solid #3b3e43;
    border-radius: 8px;
    background: #282a2e;
    object-fit: cover;
    transition: transform .16s ease, border-color .16s ease;
}
.avatar-card:hover img { border-color: var(--brand); transform: translateY(-2px); }
.avatar-card span { display: block; overflow: hidden; color: #d5d6d9; font-size: .58rem; text-overflow: ellipsis; white-space: nowrap; }

.site-footer { padding: 0 0 80px; color: #80838a; font-size: .65rem; text-align: center; }
.site-footer p { margin: 4px 0; }
.bottom-tabs { display: none; }

.scatter-modal { position: fixed; inset: 0; z-index: 80; display: none; }
.scatter-modal.open { display: block; }
.scatter-backdrop { position: absolute; inset: 0; width: 100%; border: 0; background: rgba(0,0,0,.72); backdrop-filter: blur(6px); }
.scatter-dialog {
    position: absolute;
    inset: 50% auto auto 50%;
    width: min(900px, calc(100% - 40px));
    padding: 20px;
    border: 1px solid #40434a;
    border-radius: 14px;
    background: #17181b;
    box-shadow: 0 30px 90px rgba(0,0,0,.55);
    transform: translate(-50%, -50%);
}
.scatter-dialog header { display: flex; align-items: flex-start; justify-content: space-between; }
.scatter-dialog header span { color: var(--brand); font-size: .6rem; font-weight: 800; letter-spacing: .14em; }
.scatter-dialog h2 { margin: 3px 0 0; font-size: 1.1rem; }
.scatter-dialog header button { width: 34px; height: 34px; border: 1px solid #3b3e44; border-radius: 7px; background: #23252a; cursor: pointer; }
.scatter-chart {
    position: relative;
    height: min(58vh, 500px);
    margin-top: 18px;
    border-left: 1px solid #4b4e55;
    border-bottom: 1px solid #4b4e55;
    background:
        linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
    background-size: 10% 10%;
}
.scatter-chart::before { content: "胜率"; position: absolute; left: 4px; top: 4px; color: #777a80; font-size: .6rem; }
.scatter-chart::after { content: "选取率"; position: absolute; right: 4px; bottom: 4px; color: #777a80; font-size: .6rem; }
.scatter-average-x, .scatter-average-y { position: absolute; pointer-events: none; border-color: rgba(255,255,255,.25); border-style: dashed; }
.scatter-average-x { top: 0; bottom: 0; border-left-width: 1px; }
.scatter-average-y { left: 0; right: 0; border-top-width: 1px; }
.scatter-point { position: absolute; width: 34px; height: 34px; padding: 0; overflow: hidden; border: 2px solid #fff; border-radius: 50%; background: #222; cursor: pointer; transform: translate(-50%, 50%); box-shadow: 0 5px 13px rgba(0,0,0,.4); }
.scatter-point img { width: 100%; height: 100%; object-fit: cover; }
.scatter-point:hover { z-index: 3; border-color: var(--brand); transform: translate(-50%, 50%) scale(1.25); }
.scatter-dialog footer { margin-top: 10px; color: #81848a; font-size: .65rem; }

@media (max-width: 1180px) {
    .page-shell { width: min(100% - 36px, 1100px); }
    .overview-grid { grid-template-columns: 1fr 1fr; }
    .role-card { grid-column: 1 / -1; min-height: 330px; }
    .role-meta-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
    .role-section + .role-section { margin-top: 0; padding: 0 0 0 14px; border-top: 0; border-left: 1px solid var(--line-soft); }
}

@media (max-width: 760px) {
    body { padding-bottom: 68px; }
    .page-shell { width: min(100% - 24px, 720px); }
    .topbar { height: 54px; }
    .main-nav, .topbar-meta { display: none; }
    .brand { font-size: 1.3rem; }
    .page-heading { min-height: 92px; }
    .page-heading h1 { font-size: 1.55rem; }
    .updated-copy { display: none; }
    .overview-grid { display: block; }
    .overview-card { min-height: 390px; margin-bottom: 12px; }
    .role-card { min-height: 470px; }
    .role-meta-list { display: block; }
    .role-section + .role-section { margin-top: 0; padding: 4px 0; border-top: 1px solid var(--line-soft); border-left: 0; }
    .trend-row { grid-template-columns: 132px 1fr 50px; }
    .map-row { grid-template-columns: 40px minmax(0, 2fr) minmax(64px, 1fr) auto; }
    .filter-panel { padding: 12px; }
    .filter-segments { grid-template-columns: 1fr; }
    .filter-selects { grid-template-columns: 1fr 1fr; gap: 8px; }
    .stats-summary { overflow-x: auto; white-space: nowrap; }
    .stats-summary .summary-divider { display: none; }
    .scatter-button { position: sticky; right: 0; background: #242529; }
    .hero-directory { padding: 13px; }
    .directory-tools { align-items: stretch; flex-direction: column; }
    .directory-role-tabs { display: grid; grid-template-columns: repeat(4, 1fr); }
    .hero-directory-grid { grid-template-columns: 1fr; gap: 24px; }
    .bottom-tabs {
        position: fixed;
        inset: auto 0 0;
        z-index: 60;
        height: 62px;
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        border-top: 1px solid #303238;
        background: rgba(17,18,20,.96);
        backdrop-filter: blur(15px);
    }
    .bottom-tabs a { display: grid; place-content: center; gap: 2px; color: #777a81; text-align: center; font-size: .59rem; }
    .bottom-tabs a.active { color: var(--brand); }
    .bottom-tabs svg { width: 18px; height: 18px; margin: 0 auto; }
    .site-footer { padding-bottom: 24px; }
    .scatter-dialog { width: calc(100% - 20px); padding: 14px; }
    .scatter-point { width: 28px; height: 28px; }
    .rank-color-help {
        inset: auto 12px 74px !important;
        width: auto;
    }
}

@media (max-width: 430px) {
    .region-tabs { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); }
    .filter-selects { grid-template-columns: 1fr; }
    .overview-card { padding: 13px; }
    .trend-row { grid-template-columns: 118px 1fr 45px; gap: 7px; }
    .map-row { grid-template-columns: 36px minmax(0, 2fr) 64px auto; gap: 6px; }
    .map-thumb { width: 36px; }
    .role-row { grid-template-columns: minmax(112px, 1fr) minmax(64px, 1fr) auto; gap: 6px; }
    .rank-legend { overflow-x: auto; white-space: nowrap; }
    .map-meta-footer > span { display: none; }
    .map-meta-footer { justify-content: flex-end; }
}
