:root {
    --page-zoom: 1;
    --viewport-width: calc(100vw / var(--page-zoom));
    --viewport-height: calc(100vh / var(--page-zoom));
    --viewport-dynamic-height: calc(100dvh / var(--page-zoom));
    color-scheme: dark;
    --background: #0e0e12;
    --surface: #15151b;
    --surface-raised: #1b1a22;
    --border: #2b2934;
    --text: #f1eff5;
    --muted: #9994a5;
    --accent: #9867e8;
    --accent-hover: #aa7af0;
    --danger: #e87c86;
    --content-width: 1440px;
    --page-gutter: 24px;
    --control-font-size: 12px;
    --control-font-weight: 600;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--background);
    color: var(--text);
}

.score-query-debug { padding: 17px 20px; margin-bottom: 18px; border: 1px solid #ac762f; border-left: 4px solid #e5ae56; border-radius: 4px; background: #9b642014; }
.score-query-debug strong { font-size: 21px; font-weight: 800; color: #f5c779; letter-spacing: .025em; }
.score-query-form { display: grid; gap: 10px; padding: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: 5px; }
.score-query-form > label { font-weight: 600; font-size: 13px; }
.score-query-form textarea { box-sizing: border-box; width: 100%; min-height: 130px; resize: vertical; padding: 13px; border: 1px solid var(--border); border-radius: 3px; background: #111116; color: var(--text); font: 14px/1.7 ui-monospace, Consolas, monospace; tab-size: 4; }
.score-query-form textarea:focus { outline: 1px solid var(--accent); }
.score-query-examples, .score-query-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.score-query-examples { gap: 8px; margin-bottom: 3px; }
.score-query-examples .button { font-size: 12px; padding: 6px 10px; }
.score-query-actions label { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; }
.score-query-actions input { accent-color: var(--accent); }
.score-query-actions select { color: var(--text); background: var(--surface-raised); border: 1px solid var(--border); padding: 5px; border-radius: 3px; font: inherit; }
.score-query-form .query-schema { justify-self: start; font-size: 12px; color: var(--accent-hover); }
.score-query-status { display: flex; align-items: center; gap: 8px; min-height: 52px; color: var(--muted); font-size: 13px; }
.score-query-results { max-width: 100%; overflow-x: auto; border: 1px solid var(--border); border-radius: 4px; }
.score-query-results table { border-collapse: collapse; width: 100%; font-size: 13px; }
.score-query-results th, .score-query-results td { padding: 10px 14px; text-align: left; white-space: nowrap; border-bottom: 1px solid var(--border); }
.score-query-results th { background: var(--surface-raised); color: var(--muted); font-size: 12px; font-weight: 600; }
.score-query-results tr:last-child td { border-bottom: 0; }
.score-query-results tbody tr:hover { background: #ffffff04; }
.score-query-results a:hover { color: var(--accent-hover); }
.query-player { display: inline-flex; align-items: center; gap: 9px; }
.query-player img { object-fit: cover; border-radius: 50%; background: var(--surface-raised); }
.query-number { font-variant-numeric: tabular-nums; }
.query-null { color: #686272; }
.score-query-pagination { display: flex; justify-content: center; padding: 16px; }

.page-heading.leaderboard-directory-heading { width: min(800px, 100%); margin-bottom: 24px; }
.leaderboard-directory { display: flex; flex-direction: column; max-width: 800px; border-top: 1px solid var(--border); }
.leaderboard-choice { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 16px; min-height: 84px; padding: 16px 12px; border-bottom: 1px solid var(--border); transition: background .15s; }
.leaderboard-choice:hover { background: #ffffff04; }
.leaderboard-choice:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.leaderboard-choice-icon { display: grid; place-items: center; width: 30px; height: 30px; color: var(--accent-hover); }
.leaderboard-choice-icon svg { width: 23px; height: 23px; }
.leaderboard-choice-copy { display: grid; gap: 4px; }
.leaderboard-choice-copy strong { font-size: 16px; font-weight: 600; }
.leaderboard-choice-copy > span { color: var(--muted); font-size: 12px; line-height: 1.5; }
.leaderboard-choice-footer { display: flex; align-items: center; gap: 18px; color: var(--muted); font-size: 14px; white-space: nowrap; }
.leaderboard-choice:hover .leaderboard-choice-footer { color: var(--accent-hover); }
.leaderboard-choice[href$="/snovercalc-player-rating"] .leaderboard-choice-icon { color: #70c5db; }
.leaderboard-choice[href$="/pack-lamp"] .leaderboard-choice-icon { color: #d8b46b; }
.leaderboard-choice[href$="/pack-progress"] .leaderboard-choice-icon { color: #81c797; }
.leaderboard-choice[href$="/etterna-completion"] .leaderboard-choice-icon { color: #c49bdf; }
.leaderboard-choice[href$="/esa"] .leaderboard-choice-icon { color: #e69b8b; }
.leaderboard-soon { color: var(--muted); font-size: 11px; }
.leaderboard-placeholder { max-width: 800px; padding: 22px; border: 1px solid var(--border); border-radius: 6px; background: var(--surface); }
.leaderboard-placeholder p { color: var(--muted); font-size: 14px; }
.leaderboard-placeholder a { display: inline-block; margin-top: 12px; color: var(--accent-hover); font-size: 13px; }
@media (max-width: 600px) {
    .leaderboard-choice { gap: 8px 12px; padding: 16px 4px; }
    .leaderboard-choice-footer { grid-column: 2 / -1; justify-content: space-between; }
    .leaderboard-choice-footer:not(:has(.leaderboard-soon)) { grid-column: 3; grid-row: 1; }
}
.rating-leaderboard { max-width: 1010px; }
.rating-table-scroll { overflow-x: auto; }
.rating-table { width: 100%; min-width: 1000px; table-layout: fixed; border-collapse: collapse; font-size: 13px; white-space: nowrap; }
.rating-table th, .rating-table td { padding: 6px 10px; text-align: right; }
.rating-table td { height: 40px; border-bottom: 1px solid #ffffff06; }
.rating-table th { height: 41px; color: var(--muted); font-size: 11px; font-weight: 500; background: #15141b; border-bottom: 1px solid var(--border); }
.rating-table th:first-child, .rating-table td:first-child { width: 64px; padding-left: 12px; }
.rating-table th:nth-child(2), .rating-table td:nth-child(2) { width: 180px; text-align: left; }
.rating-table th:nth-child(n+3):nth-child(-n+10), .rating-table td:nth-child(n+3):nth-child(-n+10) { width: 72px; padding-inline: 10px; }
.rating-table th:last-child, .rating-table td.rating-last-score { width: 180px; padding-inline: 12px; }
.rating-last-score { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.rating-table th button { border: 0; padding: 6px 0; background: transparent; cursor: pointer; font-weight: 600; }
.rating-table th button:hover { filter: brightness(1.25); }
.rating-table th button span { display: inline-block; width: 10px; }
.rating-table th[aria-sort="descending"], .rating-table th[aria-sort="ascending"] { box-shadow: inset 0 -1px var(--accent); background: #1c1825; }
.rating-table tbody tr:nth-child(even) { background: #ffffff02; }
.rating-table tbody tr:hover { background: #9867e80a; }
.rating-table tbody tr.is-focused-player { background: #9867e820; }
.rating-table tbody tr.is-focused-player td:first-child { box-shadow: inset 2px 0 var(--accent); }
.rating-search { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; max-width: 1120px; }
.rating-search input { width: 220px; min-width: 0; height: 34px; padding: 0 10px; border: 1px solid var(--border); border-radius: 3px; background: var(--surface); color: var(--text); font: inherit; font-size: 13px; }
.rating-search input:focus { outline: 1px solid var(--accent); }
.rating-search .button, .rating-earlier { min-height: 0; padding: 7px 12px; font-size: 12px; background: var(--surface); border: 1px solid var(--border); }
.rating-earlier { margin-bottom: 10px; }
.rating-rank, .rating-value { font-variant-numeric: tabular-nums; }
.rating-rank { color: var(--muted); }
.rating-value { font-weight: 500; letter-spacing: -.02em; }
.rating-player { display: flex; align-items: center; gap: 9px; min-width: 0; font-weight: 500; }
.rating-player > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rating-settings { flex-wrap: wrap; gap: 6px 16px; margin: 0 0 12px; }
.rating-settings[hidden] { display: none; }
.rating-settings-label { color: #c5b5d9; font-weight: 500; }
.rating-settings-key { color: var(--muted); margin-right: 4px; }
.rating-player:hover { color: var(--accent-hover); }
.rating-avatar { display: grid; place-items: center; flex: 0 0 26px; height: 26px; border-radius: 50%; overflow: hidden; background: var(--surface-raised); color: var(--muted); }
.rating-avatar img { width: 26px; height: 26px; object-fit: cover; }
.rating-state { display: flex; justify-content: center; align-items: center; gap: 10px; padding: 28px; color: var(--muted); font-size: 14px; }
.rating-state:empty { display: none; }
.rating-leaderboard footer { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; gap: 16px; color: var(--muted); font-size: 11px; }
.rating-leaderboard footer .button { padding: 7px 12px; min-height: 0; font-size: 12px; background: var(--surface); border: 1px solid var(--border); }
.rating-leaderboard footer .button:hover { border-color: var(--accent); }
* { box-sizing: border-box; }
html { overflow-y: scroll; zoom: var(--page-zoom); }
@media (min-width: 851px) {
    :root { --page-zoom: 1.1; }
}
body { margin: 0; min-width: 320px; min-height: var(--viewport-height); background: var(--background); }
button, input, select { font: inherit; }
button, a, select { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
.is-hidden { display: none !important; }

.site-header {
    height: 66px;
    padding: 0 var(--page-gutter);
    border-bottom: 1px solid var(--border);
    background: #111116;
    position: sticky;
    top: 0;
    z-index: 20;
}
.site-header-inner { position: relative; width: 100%; height: 100%; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }

.brand { display: flex; align-items: baseline; gap: 2px; font-size: 32px; letter-spacing: -.045em; white-space: nowrap; }
.brand-goober { color: var(--accent); font-weight: 800; }
.brand-online { color: var(--text); font-weight: 300; }
.primary-nav { grid-column: 2; display: flex; align-items: center; gap: 0; }
.primary-nav a { position: relative; padding: 8px 15px; color: var(--muted); font-size: 15px; font-weight: 600; }
.primary-nav a + a::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 1px; background: var(--border); }
.primary-nav a:hover { color: var(--text); }
.primary-nav a.is-active { color: #bd93f4; }
.header-actions { grid-column: 3; justify-self: end; display: flex; align-items: center; }
.account-area { position: relative; }
.button { min-height: 38px; padding: 0 17px; border: 1px solid var(--border); border-radius: 3px; color: var(--text); background: var(--surface-raised); cursor: pointer; font-weight: 650; }
.button:hover { border-color: #4a4557; }
.button-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.button-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.button:disabled { opacity: .55; cursor: wait; }
.button-full { width: 100%; margin-top: 5px; }

.profile-button { height: 65px; padding: 0; display: flex; align-items: center; gap: 11px; color: var(--text); background: transparent; border: 0; cursor: pointer; }
.profile-button-copy { min-width: 76px; display: grid; row-gap: 2px; text-align: right; line-height: 1.05; }
.profile-button-copy small { color: #817a89; font-size: 10px; font-weight: 600; font-variant-numeric: tabular-nums; }
.profile-button-line { display: flex; align-items: baseline; justify-content: end; gap: 8px; color: var(--text); font-size: 15px; font-weight: 680; white-space: nowrap; }
#profile-rating { font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
#profile-rank { color: #fff; font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; }
#profile-rating-options { color: #817a89; font-size: 9px; font-weight: 600; text-align: right; white-space: nowrap; }
#profile-quota { color: #aaa3b1; font-size: 9px; font-weight: 600; text-align: right; white-space: nowrap; }
.profile-button:hover .profile-button-copy > span, .profile-button[aria-expanded="true"] .profile-button-copy > span { color: var(--text); }
.profile-button[aria-expanded="true"] .profile-button-copy small { color: #b89bda; }
.avatar { width: 34px; height: 34px; display: block; object-fit: cover; background: var(--surface); border: 1px solid #373340; border-radius: 50%; }
.profile-button:hover .avatar, .profile-button[aria-expanded="true"] .avatar { border-color: #665077; }
.profile-flyout { position: absolute; right: 0; top: 49px; width: 220px; padding: 7px; background: var(--surface-raised); border: 1px solid var(--border); box-shadow: 0 5px 16px #0004; }
.profile-summary { padding: 10px 11px 12px; border-bottom: 1px solid var(--border); margin-bottom: 6px; display: grid; gap: 3px; }
.profile-summary span { color: var(--muted); font-size: 12px; }
.profile-flyout a, .profile-flyout button { width: 100%; min-height: 38px; padding: 0 11px; display: flex; align-items: center; border: 0; color: var(--text); background: transparent; cursor: pointer; text-align: left; }
.profile-flyout a:hover, .profile-flyout button:hover { background: #25232d; }
.profile-setting { min-height: 38px; padding: 0 11px; display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--text); cursor: pointer; }
.profile-setting:hover { background: #25232d; }
.profile-setting input { width: 15px; height: 15px; margin: 0; accent-color: var(--accent); }
.profile-flyout #logout-button { color: #d9828a; }
.profile-flyout #logout-button:hover { color: #f09aa2; background: #2a1d22; }

.option { min-width: 0; flex: 1 1 122px; display: grid; gap: 4px; }
.option-wife { flex-grow: .72; flex-basis: 92px; }
.option-mina { flex-grow: 1.45; flex-basis: 174px; }
.option-judge { flex-grow: .75; flex-basis: 88px; }
.option-wide { flex-grow: 1.35; flex-basis: 174px; }
.option-completion { flex-grow: .9; flex-basis: 116px; }
.option label { padding-left: 8px; color: #8e8997; font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .09em; }
.option-select { position: relative; }
.option-select > select { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.option-select > button { position: relative; width: 100%; height: 36px; padding: 0 28px 0 9px; overflow: hidden; color: #ddd9e2; background: #111116; border: 1px solid transparent; border-radius: 3px; cursor: pointer; text-align: left; text-overflow: ellipsis; white-space: nowrap; font-size: var(--control-font-size); font-weight: var(--control-font-weight); }
.option-select > button:hover { color: #fff; background: #1f1d26; border-color: #383442; }
.option-select > button::after { content: ""; position: absolute; right: 11px; top: 13px; width: 6px; height: 6px; border-right: 1px solid #918b99; border-bottom: 1px solid #918b99; transform: rotate(45deg); }
.option-select > button[aria-expanded="true"] { color: #fff; background: #201c28; border-color: #72529a; }
.option-select [role="option"].is-default { font-weight: 750; }
.option-select .calculation-option-value { display: flex; align-items: center; gap: 8px; }
.calculation-option-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.grade-value, [data-option-select="grade"] .calculation-option-label { font-weight: 700; }
.calculation-default-badge { display: inline-flex; align-items: center; gap: 4px; flex: 0 0 auto; margin-left: auto; color: #bd9ce7; font-size: 10px; font-weight: 600; }
.calculation-default-badge svg { width: 14px; height: 14px; flex: 0 0 14px; }
.option-select [role="listbox"] { position: absolute; z-index: 40; top: calc(100% + 5px); left: 0; min-width: 100%; width: max-content; max-width: min(720px, calc(var(--viewport-width) - 32px)); max-height: calc(var(--viewport-dynamic-height) - 150px); padding: 7px; display: grid; grid-auto-flow: row; grid-auto-rows: 32px; gap: 3px; overflow-y: auto; color: var(--text); background: #18171e; border: 1px solid #403a4b; box-shadow: 0 8px 20px #0006; }
.option-select[data-option-select="steps"] [role="listbox"] { display: block; width: max-content; max-width: min(440px, calc(var(--viewport-width) - 32px)); overflow-y: auto; }
.steps-group { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px; margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--border); }
.steps-group-label { grid-column: 1 / -1; padding: 4px 10px; color: var(--muted); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; }
.steps-group [role="option"], .option-select[data-option-select="steps"] [role="listbox"] > [role="option"] { min-height: 32px; }
.option-select[data-option-select="steps"] [role="listbox"] > [role="option"] { width: 100%; }
.page-filters { padding: 12px; border: 1px solid #282630; border-radius: 5px; background: #121217; }
.page-calculation-controls { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; }
.page-calculation-controls .option { flex: 1 1 135px; }
.page-calculation-controls .option-mina { flex: 2 1 245px; }
.page-calculation-controls .option-wide { flex: 1.5 1 190px; }
.page-calculation-controls .option-wife, .page-calculation-controls .option-judge { flex: .7 1 100px; }
.page-calculation-controls .option label { padding-left: 0; font-size: 10px; }
.page-calculation-controls .option-select > button { background: #0d0d12; }
.rating-filters { max-width: 1010px; margin-bottom: 14px; }
.lamp-options .option, .lamp-options .option-wide { flex: 0 1 230px; }
.lamp-ranked-option { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; color: var(--muted); font-size: 12px; cursor: pointer; }
.lamp-ranked-option input { width: 16px; height: 16px; margin: 0; accent-color: var(--accent); cursor: pointer; }
.lamp-leaderboard .rating-table th, .lamp-leaderboard .rating-table td { width: auto; font-variant-numeric: tabular-nums; }
.lamp-leaderboard .rating-table td:nth-child(n+3) { text-align: right; white-space: nowrap; }
.lamp-leaderboard .rating-table th button [data-label] { width: auto; }
.lamp-leaderboard .rating-table { min-width: 700px; }
.lamp-leaderboard .rating-table th:first-child, .lamp-leaderboard .rating-table td:first-child { width: 64px; }
.lamp-leaderboard .rating-table th:nth-child(2), .lamp-leaderboard .rating-table td:nth-child(2) { width: 200px; }
.lamp-leaderboard .rating-table th:nth-child(n+3), .lamp-leaderboard .rating-table td:nth-child(n+3) { width: auto; }
.rating-filters .page-calculation-controls .option { flex: 1 1 80px; }
.rating-filters .page-calculation-controls .option-mina { flex: 2 1 190px; }
.rating-filters .page-calculation-controls .option-wide { flex: 1.5 1 150px; }
.page-heading.player-rating-heading { width: min(1010px, 100%); }
.rating-filters .rating-search { margin: 12px 0 0; padding-top: 12px; border-top: 1px solid var(--border); }
.rating-filters .rating-search input { flex: 1 1 220px; height: 36px; background: #0d0d12; font-size: 14px; border-color: transparent; }
.rating-filters .rating-search .button { height: 36px; }
.rating-blocking-option { display: flex; align-items: center; gap: 8px; width: fit-content; margin-top: 12px; color: var(--muted); font-size: 12px; cursor: pointer; }
.rating-blocking-option input { flex: 0 0 14px; width: 14px; height: 14px; margin: 0; padding: 0; accent-color: var(--accent); cursor: pointer; }
.pack-toolbar .page-calculation-controls { grid-column: 1 / -1; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.pack-toolbar .page-calculation-controls .option { flex: 0 1 145px; min-width: 0; max-width: 100%; }
.pack-toolbar .page-calculation-controls .option-mina { flex-basis: 280px; }
.pack-toolbar .page-calculation-controls .option-wide { flex-basis: 190px; }
.page-calculation-controls.is-ignored .option label { color: #77717f; }
.pack-detail-options { margin-bottom: 16px; }
@media (max-width: 520px) {
    .steps-group { grid-template-columns: 1fr; }
    .page-calculation-controls .option, .page-calculation-controls .option-mina, .page-calculation-controls .option-wide { flex: 1 1 100%; }
}
.option:last-child .option-select [role="listbox"] { right: 0; left: auto; }
.option-select [role="listbox"][hidden] { display: none; }
.option-select [role="option"] { min-width: 130px; padding: 0 10px; color: #b8b3c0; background: transparent; border: 0; border-radius: 2px; cursor: pointer; text-align: left; white-space: nowrap; font-size: var(--control-font-size); font-weight: var(--control-font-weight); }
.option-select [role="option"]:hover { color: var(--text); background: #26232e; }
.option-select [role="option"][aria-selected="true"] { color: #fff; background: #35254a; }
.option { transition: opacity .12s ease; }
.option.is-disabled { opacity: .46; }
.option.is-disabled .option-select > button { color: #77717f; pointer-events: none; }

#app { width: min(var(--content-width), calc(100% - 2 * var(--page-gutter))); margin: 0 auto; padding: 58px 0 90px; outline: none; }
#app > * { margin-left: auto; margin-right: auto; }
.page-heading { width: min(980px, 100%); margin: 1px 0 14px; }
.page-heading.stats-heading { width: 100%; text-align: left; }
.hero { padding: clamp(28px, 5vw, 72px) 0; max-width: 850px; }
.eyebrow { margin: 0 0 10px; color: #b58bea; font-size: 12px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.hero h1, .page-heading h1 { margin: 0; font-size: clamp(36px, 5vw, 60px); line-height: 1.05; letter-spacing: -.045em; }
.hero p:not(.eyebrow) { max-width: 680px; margin: 24px 0 0; color: var(--muted); font-size: 18px; line-height: 1.65; }
.page-heading h1 { font-size: 28px; line-height: 1; letter-spacing: -.035em; }
.page-heading p { max-width: 760px; margin: 8px 0 0; color: #8e8896; font-size: 12px; line-height: 1.55; }
.leaderboard-heading { max-width: 720px; }
.leaderboard-groups { max-width: 980px; margin-top: 44px; display: grid; gap: 38px; }
.leaderboard-group { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 20px; }
.leaderboard-group-context { padding-top: 38px; border-top: 1px solid var(--border); }
.section-label { display: flex; flex-direction: column; gap: 5px; padding-top: 14px; }
.section-label span { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.section-label small { color: var(--muted); font-size: 11px; line-height: 1.4; }
.leaderboard-links { border-top: 1px solid var(--border); }
.leaderboard-link { min-height: 74px; padding: 13px 12px; display: grid; grid-template-columns: 9px minmax(0, 1fr) auto; align-items: center; gap: 15px; border-bottom: 1px solid var(--border); }
.leaderboard-link:hover { background: var(--surface); }
.leaderboard-link-mark { width: 3px; height: 28px; background: #5d416f; }
.leaderboard-link:hover .leaderboard-link-mark { background: var(--accent); }
.leaderboard-link strong, .leaderboard-link small { display: block; }
.leaderboard-link strong { margin-bottom: 4px; font-size: 15px; }
.leaderboard-link small { color: var(--muted); font-size: 12px; line-height: 1.4; }
.leaderboard-link-arrow { color: #726d7b; font-size: 19px; }
.leaderboard-link:hover .leaderboard-link-arrow { color: var(--accent-hover); }
.panel-grid { margin-top: 38px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.panel { min-height: 150px; padding: 22px; background: var(--surface); border: 1px solid var(--border); }
.panel h2 { margin: 0 0 9px; font-size: 16px; }
.panel p { margin: 0; color: var(--muted); line-height: 1.55; font-size: 14px; }

.ranking-panel { max-width: 980px; margin-top: 38px; }
.manage-grid { width: min(980px, 100%); margin-top: 30px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; align-items: start; }
.manage-panel { min-width: 0; padding: 18px; background: #141419; border: 1px solid var(--border); border-radius: 4px; }
.manage-player-panel { grid-row: span 2; }
.manage-panel-heading { margin-bottom: 15px; }
.manage-panel-heading h2 { margin: 0; font-size: 17px; }
.manage-panel-heading p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.manage-inline-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 7px; }
.manage-panel input, .manage-panel select, .manage-output { width: 100%; min-width: 0; height: 38px; padding: 0 11px; color: var(--text); background: #0e0e12; border: 1px solid #373440; border-radius: 3px; outline: none; }
.manage-panel input:focus, .manage-panel select:focus, .manage-output:focus { border-color: var(--accent); }
.manage-message { min-height: 18px; margin: 9px 0 0; color: #a6c798; font-size: 11px; }
.manage-message.is-error { color: var(--danger); }
.manage-output { height: 118px; margin-top: 5px; padding: 10px 11px; resize: vertical; font: 12px/1.5 ui-monospace, SFMono-Regular, Consolas, monospace; }
.manage-player-form { margin-top: 4px; padding-top: 14px; display: grid; gap: 10px; border-top: 1px solid #292631; }
.manage-player-form label { display: grid; gap: 5px; color: #aaa4b1; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.manage-player-summary { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 4px 10px; }
.manage-player-summary strong { overflow: hidden; font-size: 16px; text-overflow: ellipsis; }
.manage-player-summary code { color: #8e8796; font-size: 10px; }
.manage-player-summary span { grid-column: 1 / -1; color: #77717f; font-size: 10px; }
.manage-actions { margin-top: 4px; display: flex; gap: 7px; }
.manage-errors-panel { grid-column: 1 / -1; }
.manage-indexing-attempts { display: grid; gap: 6px; }
.manage-indexing-attempt { padding: 11px 12px; background: #0e0e12; border: 1px solid #292631; border-radius: 3px; }
.manage-indexing-attempt > div { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: baseline; gap: 14px; }
.manage-indexing-attempt footer { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; }
.manage-indexing-attempt strong { overflow: hidden; color: #e5e1e8; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.manage-indexing-attempt time, .manage-indexing-attempt footer { color: #77717f; font-size: 10px; }
.manage-attempt-result { color: #d4979f; font-size: 9px; font-weight: 800; letter-spacing: .05em; }
.manage-indexing-attempt.is-success .manage-attempt-result { color: #83c99c; }
.manage-indexing-attempt p { margin: 7px 0; color: #d4979f; font: 11px/1.45 ui-monospace, SFMono-Regular, Consolas, monospace; white-space: pre-wrap; }
.manage-indexing-attempt p.is-success { color: #93bda2; }
.manage-indexing-attempt details { margin: 7px 0; color: #9992a0; font-size: 10px; }
.manage-indexing-attempt summary { cursor: pointer; }
.manage-indexing-attempt ul { max-height: 130px; margin: 7px 0 0; padding-left: 20px; overflow: auto; }
.manage-indexing-attempt footer { margin-top: 8px; }
.manage-indexing-attempt a { color: #b894e4; }
.manage-attempts-placeholder { min-height: 80px; margin: 0; display: grid; place-items: center; color: #77717f; font-size: 11px; }
.manage-attempts-placeholder.is-error { color: var(--danger); }
.manage-errors-more { margin: 12px auto 0; display: block; }
.manage-errors-more[hidden] { display: none; }
.button-danger { color: #e89ba2; background: #211418; border-color: #4b282e; }
.button-danger:hover { color: #ffc0c5; background: #2b181d; border-color: #75404a; }
.ranking-drop { min-height: 150px; display: grid; place-content: center; justify-items: center; gap: 6px; color: var(--muted); border: 1px dashed #4b4357; background: #121217; cursor: pointer; }
.ranking-drop:hover, .ranking-drop.is-dragging { color: var(--text); border-color: var(--accent); background: #18131f; }
.ranking-drop input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.ranking-drop strong { color: var(--text); font-size: 15px; }
.ranking-drop span { font-size: 11px; }
.upload-actions { margin: 12px 0; display: flex; gap: 8px; }
.ranking-queue { border-top: 1px solid var(--border); }
.ranking-entry { min-height: 67px; padding: 10px 8px; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: start; gap: 10px; border-bottom: 1px solid var(--border); }
.ranking-index { padding-top: 2px; color: #716a79; font: 11px ui-monospace, monospace; }
.ranking-entry-main { min-width: 0; display: grid; gap: 4px; }
.ranking-entry-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.ranking-entry-main small { color: var(--muted); font-size: 10px; }
.ranking-entry-options { margin-top: 5px; display: flex; align-items: end; flex-wrap: wrap; gap: 8px 14px; }
.ranking-entry-options > label:not(.ranking-check) { display: grid; gap: 4px; color: #817a89; font-size: 9px; font-weight: 650; letter-spacing: .04em; text-transform: uppercase; }
.ranking-entry-options input[type="date"], .ranking-entry-options input[type="number"] { width: 142px; height: 30px; padding: 0 8px; color: #d9d5df; background: #101015; border: 1px solid #302d37; border-radius: 3px; outline: none; font-size: 11px; }
.ranking-entry-options input[type="number"] { width: 92px; }
.ranking-entry-options input:focus { border-color: var(--accent); }
.ranking-check { height: 30px; display: inline-flex; align-items: center; gap: 6px; color: #aaa4b2; font-size: 10px; cursor: pointer; }
.ranking-check input { width: 13px; height: 13px; margin: 0; accent-color: var(--accent); }
.ranking-entry-options input:disabled { opacity: .55; cursor: default; }
.ranking-entry-main ul { margin: 5px 0 0; padding-left: 18px; color: #d9858d; font: 10px/1.5 ui-monospace, monospace; }
.ranking-progress { position: relative; width: 100%; height: 4px; margin-top: 3px; overflow: hidden; background: #29252f; }
.ranking-progress i { width: var(--progress); height: 100%; display: block; background: var(--accent); transition: width .12s linear; }
.ranking-progress.is-ranking i { width: 32%; animation: ranking-progress 1.1s ease-in-out infinite; }
@keyframes ranking-progress { from { transform: translateX(-110%); } to { transform: translateX(320%); } }
.ranking-running .ranking-index { color: var(--accent); }
.ranking-success .ranking-index { color: #72d69a; }
.ranking-failed .ranking-index { color: var(--danger); }
.indexing-log { margin-top: 2px; color: #b89ada; font-size: 10px; white-space: nowrap; }
.indexing-log:hover { color: var(--text); }

.home-heading { max-width: 980px; }
.home-description { max-width: 980px; padding: 30px 0; display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 20px; }
.home-description > span { color: #a679df; font-size: 11px; font-weight: 750; text-transform: uppercase; letter-spacing: .08em; }
.home-description p { margin: 0; color: #aaa5b1; font-size: 15px; line-height: 1.65; }
.home-directory { max-width: 980px; border-top: 1px solid var(--border); }
.home-directory a { min-height: 62px; padding: 0 12px; display: grid; grid-template-columns: 180px minmax(0, 1fr) auto; align-items: center; gap: 15px; border-bottom: 1px solid var(--border); }
.home-directory a:hover { background: var(--surface); }
.home-directory span { font-size: 14px; font-weight: 700; }
.home-directory small { color: var(--muted); font-size: 12px; }
.home-directory b { color: #8561ad; font-size: 16px; }
.home-status { max-width: 980px; margin-top: 28px; padding: 17px 19px; display: grid; grid-template-columns: 130px minmax(0, 1fr) auto; align-items: center; gap: 20px; border: 1px solid var(--border); background: #131218; }
.home-status strong { color: #c0a6df; font-size: 11px; }
.home-status p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.home-status a { color: #b998df; font-size: 11px; white-space: nowrap; }

.simple-home-hero { max-width: 820px; padding: 72px 0 66px; }
.simple-home-hero h1 { margin: 0; font-size: clamp(52px, 7vw, 84px); line-height: 1; letter-spacing: -.055em; }
.simple-home-hero > p:not(.eyebrow) { max-width: 720px; margin: 24px 0 29px; color: var(--muted); font-size: 17px; line-height: 1.65; }
.simple-home-links { max-width: 980px; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--border); border-left: 1px solid var(--border); }
.simple-home-links a { min-height: 142px; padding: 21px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--surface); }
.simple-home-links a:hover { background: var(--surface-raised); }
.simple-home-links strong, .simple-home-links span { display: block; }
.simple-home-links strong { margin-bottom: 9px; font-size: 15px; }
.simple-home-links span { color: var(--muted); font-size: 12px; line-height: 1.55; }
.simple-wip { max-width: 980px; margin-top: 20px; padding: 17px 20px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 20px; border: 1px solid #393142; background: #151219; }
.simple-wip > span { padding: 3px 6px; color: #c4a3ef; border: 1px solid #513968; font-size: 9px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.simple-wip p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.simple-wip a { color: #c8b0e8; font-size: 11px; font-weight: 700; white-space: nowrap; }
.simple-wip a:hover { color: var(--text); }

.home-hero { min-height: 480px; padding: 54px 0 72px; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(330px, .7fr); align-items: center; gap: clamp(45px, 8vw, 120px); }
.home-hero-copy h1 { max-width: 760px; margin: 0; font-size: clamp(48px, 6.5vw, 88px); line-height: .98; letter-spacing: -.055em; }
.home-lead { max-width: 720px; margin: 26px 0 0; color: #aaa5b1; font-size: 18px; line-height: 1.65; }
.home-actions { margin-top: 31px; display: flex; align-items: center; gap: 24px; }
.home-action { display: inline-flex; align-items: center; }
.home-text-link { display: inline-flex; align-items: center; gap: 9px; color: #c9c4cf; font-size: 13px; font-weight: 700; }
.home-text-link span { color: var(--accent-hover); font-size: 17px; transition: transform .12s ease; }
.home-text-link:hover { color: var(--text); }
.home-text-link:hover span { transform: translateX(3px); }
.home-snapshot { border: 1px solid var(--border); background: var(--surface); }
.snapshot-head, .snapshot-row, .snapshot-footer { padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 15px; border-bottom: 1px solid var(--border); }
.snapshot-head { color: #bdb8c5; font-size: 10px; font-weight: 800; letter-spacing: .11em; }
.live-dot { padding: 3px 6px; color: #c7a7f5; background: #2b2039; border: 1px solid #49345f; letter-spacing: .08em; }
.snapshot-row { min-height: 63px; align-items: start; flex-direction: column; justify-content: center; }
.snapshot-row span { color: var(--muted); font-size: 11px; }
.snapshot-row strong { font-size: 13px; font-weight: 650; }
.snapshot-footer { border-bottom: 0; justify-content: start; color: var(--muted); font-size: 10px; }
.snapshot-pulse { width: 7px; height: 7px; background: var(--accent); }
.home-features { padding: 72px 0 82px; border-top: 1px solid var(--border); }
.home-section-heading { max-width: 680px; margin-bottom: 40px; }
.home-section-heading h2, .addon-copy h2, .wip-copy h2 { margin: 0; font-size: clamp(28px, 3.5vw, 44px); line-height: 1.1; letter-spacing: -.04em; }
.feature-list { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--border); border-left: 1px solid var(--border); }
.feature { min-height: 250px; padding: 24px; display: grid; grid-template-rows: auto auto 1fr auto; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--surface); }
.feature:hover { background: var(--surface-raised); }
.feature-number { color: #71578f; font: 700 11px ui-monospace, monospace; }
.feature h3 { margin: 35px 0 10px; font-size: 18px; }
.feature p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.feature-arrow { margin-top: 22px; color: var(--accent-hover); font-size: 18px; }
.addon-section { padding: 90px 0; display: grid; grid-template-columns: minmax(0, .9fr) minmax(400px, 1.1fr); gap: clamp(55px, 10vw, 150px); align-items: center; border-top: 1px solid var(--border); }
.addon-copy p:last-child { margin: 20px 0 0; color: var(--muted); line-height: 1.65; }
.addon-steps { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--border); }
.addon-steps li { min-height: 78px; padding: 14px 8px; display: grid; grid-template-columns: 35px 1fr; align-items: center; gap: 13px; border-bottom: 1px solid var(--border); }
.addon-steps li > span { color: #8e65c8; font: 700 12px ui-monospace, monospace; }
.addon-steps strong, .addon-steps small { display: block; }
.addon-steps strong { margin-bottom: 4px; font-size: 14px; }
.addon-steps small { color: var(--muted); font-size: 12px; }
.wip-section { margin-top: 10px; padding: 30px; display: grid; grid-template-columns: 180px minmax(0, 1fr) auto; align-items: start; gap: 35px; border: 1px solid #3d3349; background: #17141c; }
.wip-label { display: flex; align-items: center; gap: 9px; color: #b6a1ca; font-size: 10px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.wip-label span { width: 7px; height: 7px; background: var(--accent); }
.wip-copy h2 { font-size: 24px; }
.wip-copy p { max-width: 720px; margin: 13px 0 0; color: var(--muted); font-size: 13px; line-height: 1.65; }

.login-dialog { width: min(430px, calc(var(--viewport-width) - 32px)); padding: 0; color: var(--text); background: var(--surface-raised); border: 1px solid #403a4b; box-shadow: 0 8px 24px #0005; }
.login-dialog::backdrop { background: #08070bb8; }
.login-dialog form { padding: 27px; display: grid; gap: 17px; }
.dialog-heading { display: flex; justify-content: space-between; align-items: start; margin-bottom: 4px; }
.dialog-heading h1 { margin: 0; font-size: 30px; letter-spacing: -.035em; }
.icon-button { width: 34px; height: 34px; border: 0; background: transparent; color: var(--muted); font-size: 25px; cursor: pointer; }
.icon-button:hover { color: var(--text); background: #27242f; }
.login-dialog label { display: grid; gap: 7px; color: #c5c0cc; font-size: 13px; font-weight: 650; }
.login-dialog input { height: 42px; padding: 0 12px; color: var(--text); background: #101014; border: 1px solid var(--border); outline: none; }
.login-dialog input:focus { border-color: var(--accent); }
.form-message { min-height: 19px; margin: -4px 0; color: var(--danger); font-size: 13px; }
.dialog-note { margin: 2px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; text-align: center; }

.pack-browser { width: min(1180px, 100%); }
.pack-browser-heading { margin: 1px 0 14px; }
.pack-browser-heading h1 { margin: 0; font-size: 28px; line-height: 1; letter-spacing: -.035em; }
.pack-browser-heading p { max-width: 760px; margin: 8px 0 0; color: #8e8896; font-size: 12px; line-height: 1.55; }
.pack-toolbar { display: grid; grid-template-columns: minmax(0, 1fr) 210px auto; align-items: center; gap: 10px; padding: 9px 10px; background: #121217; border: 1px solid #282630; border-radius: 4px; }
.pack-picker { display: grid; max-height: 310px; overflow-y: auto; }
.pack-picker-anchor { position: relative; }
.pack-picker-sort { width: 150px; max-width: 100%; height: 36px; padding: 0 10px; border: 1px solid var(--border); border-radius: 3px; color: var(--text); background: var(--surface); font-size: 13px; cursor: pointer; }
.pack-picker-sort:focus-visible { outline: 1px solid var(--accent); }
.player-progress-search { align-items: center; }
.player-progress-search label { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12px; white-space: nowrap; cursor: pointer; }
.rating-filters .player-progress-search label input { flex: none; width: 14px; height: 14px; padding: 0; margin: 0; accent-color: var(--accent); }
.player-progress-search label:has(input:disabled) { opacity: .5; cursor: default; }
.progress-pack-link { display: block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background: none; border: 0; padding: 0; color: var(--text); text-align: left; cursor: pointer; }
.progress-pack-link:hover { color: var(--accent-hover); }
.progress-search-modes { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; margin-top: 14px; }
:is(.pack-progress-filters, .lamp-filters) .page-calculation-controls .option { flex: 0 1 180px; min-width: 0; max-width: 100%; }
:is(.pack-progress-filters, .lamp-filters) .page-calculation-controls .option-wide { flex-basis: 220px; }
.progress-search-area { min-width: 0; border: 1px solid var(--border); border-radius: 4px; padding: 12px; }
.progress-search-area.is-active { border-color: #9867e880; background: #9867e807; }
.progress-mode { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; padding: 0; border: 0; background: none; font-size: 13px; font-weight: 600; cursor: pointer; }
.progress-mode span { font-weight: 400; color: var(--muted); font-size: 11px; }
.progress-search-area .rating-search { margin: 0; }
.progress-search-area .rating-search > input, .progress-search-area .pack-query-input { flex: 1; width: 0; min-width: 100px; }
.progress-search-area .pack-query-input input, .progress-result-filters .pack-query-input input { position: relative; width: 100%; background: transparent; }
.progress-search-area .pack-query-highlights, .progress-result-filters .pack-query-highlights { padding: 0 10px; font-size: 13px; line-height: 32px; }
.pack-picker-anchor .pack-picker-tools { display: contents; }
.pack-picker-tools .compact-select { flex: none; width: 140px; }
.pack-picker-anchor .rating-search { align-items: center; }
.progress-share { display: flex; margin-top: 8px; }
.progress-result-filters { padding: 0 12px 12px; }
.pack-progress-lamp-counts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding: 0 12px 12px; font-size: 12px; }
.lamp-count-total { color: var(--muted); }
.lamp-grade-count { white-space: nowrap; font-variant-numeric: tabular-nums; }
.lamp-grade-count.is-zero { opacity: .2; }
.progress-result-filters .rating-search { align-items: center; margin: 0; }
.progress-result-filters .rating-search[hidden] { display: none; }
.progress-result-filters .pack-query-input { flex: 1; min-width: 180px; }
.progress-result-filters .rating-search > input { flex: 1; }
.progress-result-filters label { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.progress-result-filters label input { flex: none; width: 14px; height: 14px; margin: 0; padding: 0; accent-color: var(--accent); }
.progress-result-filters .player-pack-filter-tools { border: 0; }
.progress-result-filters label.is-overridden { opacity: .45; }
.progress-result-filters .compact-select { width: 118px; }
@media (max-width: 700px) { .progress-search-modes { grid-template-columns: 1fr; } }
.pack-picker-popover { position: absolute; inset: calc(100% + 6px) 0 auto; z-index: 30; max-height: min(400px, 50vh); overflow-y: auto; padding: 6px; border: 1px solid var(--border); border-radius: 6px; background: var(--surface); box-shadow: 0 12px 32px #0008; }
.pack-picker-popover[hidden] { display: none; }
.pack-picker-popover .pack-picker { max-height: none; overflow: visible; }
.pack-picker-popover .pack-picker-state:not(:empty) { padding: 10px; }
.pack-picker-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; padding: 10px 12px; text-align: left; border: 0; border-bottom: 1px solid var(--border); background: transparent; cursor: pointer; }
.pack-picker-row:hover, .pack-picker-row:focus-visible { background: #9867e81a; }
.pack-picker-row strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.pack-picker-row span { color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.pack-picker-stats { display: flex; gap: 16px; }
.pack-picker-stat { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.pack-picker-stat img { flex: 0 0 14px; }
.pack-picker-state:empty { display: none; }
.pack-progress-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 12px; }
.pack-progress-heading h2 { margin: 0 0 4px; font-size: 18px; overflow-wrap: anywhere; }
.pack-progress-title { flex: 1; min-width: 0; }
.pack-progress-name { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; }
.pack-progress-name [data-pack-id] { font-size: 11px; white-space: nowrap; padding: 2px 7px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); }
.pack-progress-name [data-pack-id]:empty { display: none; }
.pack-progress-title .pack-progress-lamp-counts { padding: 0; margin: 5px 0 0; }
.pack-progress-totals:empty { display: none; }
.pack-progress-banner { flex: 0 0 216px; height: 70px; display: grid; place-items: center; background: #ffffff06; color: var(--muted); font-size: 12px; }
.pack-progress-banner[hidden] { display: none; }
.pack-progress-banner img { width: 100%; height: 100%; object-fit: cover; }
.pack-progress-heading .pack-progress-banner.is-player-avatar { flex: 0 0 64px; height: 64px; border-radius: 4px; overflow: hidden; font-size: 25px; }
.pack-progress-banner.is-player-avatar a { display: grid; place-items: center; width: 64px; height: 64px; }
.pack-progress-banner.is-player-avatar img { width: 64px; height: 64px; }
.pack-progress-totals { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 9px; font-size: 12px; color: var(--muted); }
.pack-progress-totals span { display: inline-flex; align-items: center; gap: 5px; }
.progress-navigation-row { cursor: pointer; }
.progress-navigation-row:hover, .progress-navigation-row:focus-visible { background: #ffffff06; }
@media (max-width: 650px) { .pack-progress-heading { flex-wrap: wrap; justify-content: flex-start; } .pack-progress-banner:not(.is-player-avatar) + .pack-progress-title { flex-basis: 100%; } .pack-progress-actions { margin-left: auto; } }
.pack-progress-heading [data-pack-id], .progress-total { color: var(--muted); }
.progress-table-toolbar { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 8px; }
.progress-table-toolbar .progress-result-filters { flex: 1; min-width: 0; padding: 0; }
.progress-table-toolbar .rating-search { margin-bottom: 0; }
.pack-progress-actions { display: flex; justify-content: flex-end; gap: 8px; flex-shrink: 0; }
:is(.pack-progress-filters, .pack-progress-leaderboard) :is(.rating-search .button, .pack-progress-actions .button) { min-height: 36px; height: 36px; padding: 0 10px; border: 1px solid transparent; border-radius: 3px; background: #111116; color: #ddd9e2; font-size: var(--control-font-size); font-weight: var(--control-font-weight); cursor: pointer; }
:is(.pack-progress-filters, .pack-progress-leaderboard) :is(.rating-search .button, .pack-progress-actions .button):hover:not(:disabled) { color: #fff; background: #1f1d26; border-color: #383442; }
:is(.pack-progress-filters, .pack-progress-leaderboard) :is(.rating-search .button, .pack-progress-actions .button):focus-visible { outline: 1px solid var(--accent); outline-offset: 2px; }
.compact-select > button:disabled { opacity: .45; cursor: default; }
.compact-select [role="listbox"][popover] { position: fixed; inset: auto; margin: 0; }
.compact-select [role="listbox"][popover]:not(:popover-open) { display: none; }
@media (max-width: 700px) { .progress-table-toolbar { flex-wrap: wrap; } .progress-table-toolbar .progress-result-filters { flex-basis: 100%; } .pack-progress-actions { margin-left: auto; } }
.pack-progress-filters, .pack-progress-leaderboard { max-width: 1110px; }
.page-heading.pack-progress-page-heading { width: min(1110px, 100%); }
.pack-progress-leaderboard .rating-table th { height: 41px; padding-block: 3px; }
.pack-progress-leaderboard .rating-table th button { padding: 0; line-height: 14px; }
.pack-progress-leaderboard .rating-table th button[data-metric] { white-space: nowrap; color: var(--muted); }
.pack-progress-leaderboard th .compact-select { display: inline-block; width: 110px; margin: 0 0 0 7px; vertical-align: middle; text-align: left; }
.pack-progress-leaderboard .rating-table th .compact-select > button { padding: 0 28px 0 9px; line-height: normal; height: 34px; }
.pack-progress-leaderboard .rating-table th .compact-select [role="option"] { padding: 0 10px; line-height: normal; }
.pack-progress-leaderboard .rating-table th[aria-sort="ascending"] button, .pack-progress-leaderboard .rating-table th[aria-sort="descending"] button,
.pack-progress-leaderboard th[aria-sort="ascending"] select, .pack-progress-leaderboard th[aria-sort="descending"] select { color: var(--text); }
.pack-progress-summary { display: flex; flex-wrap: wrap; gap: 8px 24px; min-height: 32px; padding: 0 12px 14px; font-size: 12px; line-height: 18px; color: var(--muted); }
.pack-progress-summary .is-ranked { color: #66cc66; }
.pack-progress-summary:empty { display: none; }
.pack-progress-title .pack-progress-summary { min-height: 0; padding: 0; margin-top: 7px; }
.pack-progress-leaderboard .rating-table { min-width: 1110px; }
.pack-progress-leaderboard .rating-table th:nth-child(n+3), .pack-progress-leaderboard .rating-table td:nth-child(n+3) { width: auto; }
.pack-progress-leaderboard .rating-table th:nth-child(3), .pack-progress-leaderboard .rating-table td:nth-child(3) { width: 60px; text-align: left; }
.pack-progress-leaderboard .rating-table th:nth-child(4), .pack-progress-leaderboard .rating-table td:nth-child(4) { width: 140px; text-align: left; }
.pack-progress-leaderboard.is-player-progress .rating-table th:nth-child(2), .pack-progress-leaderboard.is-player-progress .rating-table td:nth-child(2) { width: 260px; }
.pack-progress-leaderboard .rating-table th:nth-child(n+5), .pack-progress-leaderboard .rating-table td:nth-child(n+5) { width: 195px; }
.player-progress-search .pack-query-input { flex: 1; min-width: 190px; }
.player-progress-search .pack-query-input input { position: relative; width: 100%; background: transparent; }
.player-progress-search .pack-query-highlights { padding: 0 10px; font-size: 13px; line-height: 32px; }
.player-pack-filter-tools[hidden] { display: none; }
.progress-grade-bar { height: 14px; width: 100%; background: #ffffff12; display: flex; overflow: hidden; border-radius: 2px; }
.progress-grade-bar span { height: 100%; flex-shrink: 0; }
@media (max-width: 600px) { .pack-picker-row { grid-template-columns: minmax(0, 1fr); gap: 6px; } .pack-picker-stats { gap: 14px; } }
.pack-toolbar > label { display: grid; gap: 7px; color: #aaa4b2; font-size: 11px; font-weight: 700; letter-spacing: .065em; text-transform: uppercase; }
.pack-search { min-width: 0; }
.pack-query-input { position: relative; min-width: 0; border-radius: 4px; background: #0d0d12; }
.pack-query-highlights { position: absolute; inset: 0; padding: 0 12px 0 36px; overflow: hidden; white-space: pre; line-height: 36px; font-size: 14px; color: transparent; pointer-events: none; border: 1px solid transparent; }
.pack-query-highlights mark { color: transparent; background: #9966cc25; border-radius: 3px; }
.pack-query-highlights mark.is-invalid { background: #ff55552b; text-decoration: underline wavy #ed7777; }
.pack-toolbar .pack-query-input #pack-search { position: relative; background-color: transparent; width: 100%; }
.pack-query-tools { grid-column: 1 / -1; display: flex; align-items: center; flex-wrap: wrap; gap: 10px 24px; padding-top: 8px; border-top: 1px solid var(--border); color: var(--muted); font-size: 12px; }
.pack-similarity { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.pack-toolbar .pack-similarity input { width: 120px; height: 18px; padding: 0; border: 0; accent-color: var(--accent); box-shadow: none; }
.pack-similarity output { width: 34px; font-variant-numeric: tabular-nums; }
.pack-query-sort-note { color: #bda3df; font-size: 11px; }
.pack-sort-controls.is-overridden { opacity: .45; }
.pack-ignore-options.is-overridden { opacity: .45; cursor: default; }
.pack-sort-controls.is-overridden button { cursor: default; }
.pack-sort-controls.is-overridden .option-select > button::after { display: none; }
.pack-query-help { margin-left: auto; position: relative; }
.pack-query-help-trigger { width: 24px; height: 24px; padding: 0; border: 1px solid var(--border); border-radius: 50%; color: var(--muted); background: var(--surface); cursor: help; }
.pack-query-help .pack-query-guide { display: none; position: absolute; right: 0; top: 100%; z-index: 60; width: min(560px, calc(var(--viewport-width) - 40px)); max-height: 55vh; overflow: auto; padding: 12px 16px; line-height: 1.7; background: var(--surface-raised); border: 1px solid var(--border); border-radius: 5px; box-shadow: 0 12px 30px #0008; }
.pack-query-help:hover .pack-query-guide, .pack-query-help:focus-within .pack-query-guide { display: block; }
.pack-query-guide p { margin: 8px 0; }
.pack-query-guide code { color: #c9b2e4; font-size: 12px; overflow-wrap: anywhere; }
.pack-query-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 24px; margin-top: 14px; }
.pack-query-fields > div { display: grid; grid-template-columns: 95px minmax(0, 1fr); gap: 8px; border-top: 1px solid #ffffff08; padding-top: 5px; }
.pack-query-error { flex-basis: 100%; color: #ef9292; }
@media (max-width: 760px) { .pack-query-fields { grid-template-columns: 1fr; } .pack-query-tools { gap: 10px; } }
.pack-toolbar-options { display: grid; gap: 6px; }
.page-calculation-controls > .pack-toolbar-options { align-self: end; min-height: 36px; align-items: center; margin-left: 8px; }
.pack-toolbar .pack-ignore-options { display: inline-flex; align-items: center; gap: 7px; margin: 0; padding: 0; color: #8f8997; font-size: 11px; font-weight: 600; line-height: 14px; letter-spacing: .01em; text-transform: none; white-space: nowrap; cursor: pointer; }
.pack-toolbar .pack-ignore-options input { appearance: none; flex: 0 0 14px; width: 14px; height: 14px; margin: 0; padding: 0; display: grid; place-items: center; color: #fff; background: #15141a; border: 1px solid #4a4651; border-radius: 3px; box-shadow: none; cursor: pointer; }
.pack-toolbar .pack-ignore-options input::after { content: ""; width: 7px; height: 4px; margin-top: -1px; border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; opacity: 0; transform: rotate(-45deg); }
.pack-toolbar .pack-ignore-options input:checked { background: var(--accent); border-color: var(--accent); }
.pack-toolbar .pack-ignore-options input:checked::after { opacity: 1; }
.pack-toolbar .pack-ignore-options:hover { color: #bbb5c2; }
.pack-toolbar #pack-search { height: 36px; padding: 0 12px 0 36px; background: #0d0d12 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%238d8795' stroke-width='1.5'%3E%3Ccircle cx='7' cy='7' r='4.5'/%3E%3Cpath d='m10.5 10.5 3 3'/%3E%3C/svg%3E") no-repeat 12px center / 14px; border-color: transparent; font-size: 14px; }
.pack-toolbar select, .pack-toolbar input { width: 100%; height: 42px; padding: 0 13px; color: var(--text); background: #101014; border: 1px solid #393641; border-radius: 4px; outline: 0; font-size: 14px; }
.pack-sort-controls { display: grid; grid-template-columns: minmax(0, 1fr) 36px; gap: 6px; }
.pack-sort-controls .option-select > button { height: 36px; }
.pack-sort-controls .option-select > button { background: #0d0d12; }
.pack-sort-controls .option-select > button:hover, .pack-sort-controls .option-select > button[aria-expanded="true"] { background: #17151d; }
.pack-sort-controls .option-select [role="listbox"] { right: 0; left: auto; }
#pack-direction { height: 36px; color: #d3cddd; background: #0d0d12; border: 1px solid transparent; border-radius: 3px; cursor: pointer; font-size: 18px; }
#pack-direction:hover { color: #fff; border-color: #383442; background: #1f1d26; }
.pack-toolbar input::placeholder { color: #797481; }
.pack-toolbar input:hover, .pack-toolbar select:hover { border-color: #514b5d; }
.pack-toolbar input:focus, .pack-toolbar select:focus { border-color: var(--accent); box-shadow: 0 0 0 2px #9867e81f; }
.pack-filter-warning, .rating-settings { display: flex; align-items: center; max-width: 100%; padding: 9px 12px; border: 0; border-left: 2px solid #635172; border-radius: 0; background: #a77bd608; color: #ada5b7; font-size: 12px; line-height: 1.5; }
.pack-filter-warning::before, .rating-settings::before { content: ""; width: 16px; height: 16px; flex: 0 0 16px; background: url("./icons/calculation-notice.svg") center / contain no-repeat; }
.pack-filter-warning { gap: 9px; margin-top: 6px; }
.pack-filter-warning > span { min-width: 0; }
.rating-settings > span { overflow-wrap: anywhere; }
.pack-filter-warning[hidden] { display: none; }
.pack-filter-warning > b { display: none; }
.pack-state { min-height: 26px; display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.pack-state:empty { min-height: 26px; }
.pack-state.is-loading { justify-content: center; }
.pack-state.is-loading.is-initial { min-height: 220px; }
.pack-state.is-empty { min-height: 220px; display: grid; place-content: center; justify-items: center; gap: 6px; color: #77717f; text-align: center; }
.pack-state.is-empty::before { content: ""; width: 21px; height: 21px; margin-bottom: 8px; border: 2px solid #514a59; border-radius: 50%; box-shadow: 8px 8px 0 -6px #514a59; }
.pack-state.is-empty strong { color: #bcb6c4; font-size: 14px; font-weight: 650; }
.pack-state.is-empty span { max-width: 340px; font-size: 11px; }
.pack-state.is-error { width: fit-content; max-width: 100%; min-height: 28px; margin-top: 6px; padding: 5px 9px; color: #d9939a; background: #181215; border: 1px solid #43272c; border-radius: 3px; }
.pack-spinner { width: 13px; height: 13px; border: 2px solid #41394b; border-top-color: var(--accent); border-radius: 50%; animation: pack-spin .65s linear infinite; }
@keyframes pack-spin { to { transform: rotate(360deg); } }
.pack-list { display: grid; gap: 0; border-top: 1px solid #292630; }
.pack-card { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 70px; background: #121217; border-bottom: 1px solid #292630; transition: background .15s; }
.pack-edit { position: absolute; top: 7px; left: 7px; width: 27px; height: 27px; display: grid; place-items: center; color: #b69ad4; background: #17151d; border: 1px solid #383241; border-radius: 3px; cursor: pointer; z-index: 2; }
.pack-edit:hover { color: #fff; border-color: #765995; background: #211c29; }
.pack-card:hover { background: #17161d; border-color: #373340; }
.pack-card.is-empty .pack-card-link { opacity: .43; }
.pack-card.is-empty:hover .pack-card-link { opacity: .58; }
.pack-empty-message { margin-top: 8px; color: #aaa3b0; font-size: 11px; }
.pack-card-link { min-width: 0; padding: 12px 10px; display: grid; grid-template-columns: 220px minmax(0, 1fr) 210px; align-items: center; gap: 18px; }
.pack-banner-link > img, .pack-card-fallback { width: 220px; height: 72px; display: block; object-fit: cover; background: #0e0d12; border-radius: 2px; }
.pack-card-copy { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-content: center; gap: 9px 12px; }
.pack-card-heading, .pack-card-meta, .pack-card-stats, .pack-card-copy > .pack-empty-message { grid-column: 1; }
.pack-card-identity { grid-column: 2; grid-row: 1 / 4; display: flex; flex-direction: column; align-items: flex-end; gap: 7px; }
.pack-card-identity code { color: #716b79; font-size: 10px; }
.pack-card-identity .pack-ranked { min-height: 12px; }
.pack-popularity { color: #82798e; font-size: 10px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pack-popularity b { color: #b6a9c6; font-weight: 500; }
.pack-card-heading { min-width: 0; display: flex; align-items: center; gap: 10px; }
.pack-card-heading strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; font-weight: 650; line-height: 1.25; }
.pack-card-heading code { margin-left: auto; flex-shrink: 0; color: #716b79; font-size: 10px; }
.pack-card-meta { min-width: 0; display: flex; align-items: center; gap: 15px; color: #837e8a; font-size: 11px; }
.pack-card-meta > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pack-card-meta b { color: #bbb5c2; font-weight: 600; }
.pack-ranked { margin-left: auto; color: #625d68; font-size: 9px; font-weight: 750; letter-spacing: .055em; }
.pack-ranked.is-ranked { color: #b892df; }
.pack-player-rating-count { margin-left: auto; color: #96909d; font-size: 10px; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pack-player-rating-count + .pack-ranked { margin-left: -8px; }
.pack-detail-hero .pack-ranked { margin-left: 10px; }
.pack-card-stats { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 17px; }
.pack-stat { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.pack-stat-link { border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.pack-stat-link:hover, .pack-stat-link:focus-visible { color: var(--accent-hover); }
.pack-stat-link:hover b { color: inherit; }
.pack-name-link { min-width: 0; }
.pack-banner-link { display: block; min-width: 0; }
.pack-banner-link > img { width: 100%; height: 72px; object-fit: cover; border-radius: 2px; }
.pack-stat-icon { width: 14px; height: 14px; flex: 0 0 14px; }
.pack-stat-row { display: flex; align-items: baseline; gap: 19px; white-space: nowrap; }
.pack-stat-row > span { display: inline-flex; align-items: baseline; }
.pack-stat-row b { margin-right: 4px; color: #d6d1dc; font-size: 12px; font-weight: 700; letter-spacing: 0; font-variant-numeric: tabular-nums; }
.pack-stat-row-secondary { color: #6e6975; }
.pack-card-stats b { color: #bcb6c5; font-size: 12px; font-weight: 500; font-variant-numeric: tabular-nums; }
.pack-icon { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.45; stroke-linecap: round; stroke-linejoin: round; }
.pack-msd { position: relative; min-width: 0; min-height: 104px; padding: 8px 10px; display: block; background: #0e0e13; border: 1px solid #292630; border-radius: 3px; }
.pack-msd-skillsets { position: absolute; top: 12px; left: 10px; right: 58px; display: flex; align-items: center; gap: 8px; overflow: hidden; white-space: nowrap; font-size: 9px; font-variant-numeric: tabular-nums; }
.pack-msd-skillsets span { flex: 0 0 auto; }
.pack-msd-skillsets i { font-style: normal; font-weight: 700; }
.pack-msd .pack-msd-skillsets b { color: inherit; font-size: 9px; font-weight: 400; }
.pack-msd-plot { min-width: 0; height: 100%; padding-top: 27px; display: flex; align-items: end; }
.pack-msd-plot > svg { width: 100%; height: 61px; overflow: visible; }
.pack-msd-bucket:hover .pack-msd-bar { filter: brightness(1.35); stroke: #fff; stroke-width: 1; vector-effect: non-scaling-stroke; }
.pack-msd-bucket:hover .pack-msd-hit { fill: #ffffff0c; }
.pack-msd-tooltip { position: fixed; width: max-content; max-width: calc(var(--viewport-width) - 16px); z-index: 1000; padding: 6px 9px; border: 1px solid #48414f; border-radius: 3px; background: #1b1821; color: #eeeaf2; font-size: 12px; line-height: 1.45; font-weight: 400; font-variant-numeric: tabular-nums; white-space: pre-line; pointer-events: none; }
.pack-msd-rating { position: absolute; top: 8px; right: 10px; padding: 2px 4px; background: #0e0e13d9; }
.pack-msd-rating b { font-size: 17px; }
.pack-msd b { font-size: 15px; font-variant-numeric: tabular-nums; }
.pack-msd small, .pack-msd-empty { color: var(--muted); font-size: 9px; font-variant-numeric: tabular-nums; }
.pack-msd-empty { width: 100%; min-height: 104px; display: grid; place-items: center; text-align: center; }
.pack-msd.is-no-rating .pack-msd-rating { color: var(--muted); }
.pack-msd-no-data { width: 100%; height: 61px; display: grid; place-items: center; border-bottom: 1px solid #292630; color: var(--muted); font-size: 11px; }
.pack-actions { display: flex; flex-direction: column-reverse; justify-content: center; align-items: center; gap: 6px; padding: 10px 6px; }
.pack-file-size { color: #a39daa; font-size: 11px; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pack-download { width: 22px; height: 22px; display: inline-grid; place-items: center; color: #ad89d8; }
.pack-download .pack-icon { width: 15px; height: 15px; }
.pack-download:hover { color: #fff; }
.pack-download.is-disabled { color: #494550; cursor: not-allowed; }
.pack-more { margin: 18px auto 0; display: block; }
.pack-more[hidden] { display: none; }
.back-link { width: min(980px, 100%); margin-top: 28px; display: block; color: #b894e4; font-size: 12px; }
.pack-detail { width: min(1180px, 100%); }
.pack-detail > .back-link { margin: 0 0 12px; }
.pack-detail-hero { min-height: 235px; padding: 14px; display: grid; grid-template-columns: minmax(360px, 1.25fr) minmax(300px, 1fr) 230px; align-items: center; gap: 22px; background: #121217; border: 1px solid #282630; border-radius: 4px; }
.pack-detail-hero > img, .pack-detail-banner-fallback { width: 100%; height: 205px; object-fit: cover; background: #0d0c11; border-radius: 3px; }
.pack-detail-title { display: flex; align-items: center; gap: 10px; }
.pack-detail-title h1 { margin: 0; font-size: clamp(26px, 3vw, 42px); line-height: 1.05; letter-spacing: -.04em; }
.pack-detail-hero code { display: inline-block; margin-top: 8px; color: #8f8998; font-size: 11px; }
.pack-detail-hero p { margin: 11px 0; color: #8f8998; font-size: 12px; }
.pack-detail-stats { display: flex; flex-wrap: wrap; gap: 8px 17px; color: #77717f; font-size: 10px; text-transform: uppercase; }
.pack-detail-stats b { margin-right: 3px; color: #d7d2dc; font-size: 13px; }
.pack-detail-edit { padding: 5px 8px; display: inline-flex; align-items: center; gap: 5px; color: #b99bdb; background: transparent; border: 1px solid #44384f; border-radius: 3px; cursor: pointer; white-space: nowrap; }
.pack-detail-edit:hover { color: #fff; background: #211c29; }
.pack-song-toolbar { position: sticky; top: 66px; z-index: 8; margin-top: 12px; padding: 8px; display: flex; align-items: center; gap: 12px; background: #15141a; border: 1px solid #292630; }
.pack-song-toolbar input { height: 38px; min-width: 280px; flex: 1; padding: 0 12px; color: var(--text); background: #0d0d12; border: 1px solid #393641; border-radius: 3px; outline: 0; }
.pack-song-toolbar input:focus { border-color: var(--accent); }
.pack-song-toolbar span { color: #918a99; font-size: 11px; white-space: nowrap; }
.pack-song-list { margin-top: 8px; display: grid; gap: 6px; }
.pack-song { min-height: 92px; padding: 7px; display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 14px; background: #121217; border: 1px solid #24222b; border-radius: 3px; }
.pack-song:hover { background: #17161d; border-color: #373340; }
.pack-song > img, .pack-song-fallback { width: 250px; height: 78px; object-fit: cover; background: #0d0c11; border-radius: 2px; }
.pack-song-copy { min-width: 0; display: grid; grid-template-rows: auto auto auto 1fr; align-content: center; }
.pack-song-copy > strong { overflow: hidden; color: #eeeaf1; font-size: 17px; text-overflow: ellipsis; white-space: nowrap; }
.pack-song-copy > span:not(.pack-detail-charts) { color: #aaa4b1; font-size: 12px; }
.pack-song-copy > small { color: #706a77; font-size: 10px; }
.pack-detail-charts { align-self: end; display: flex; flex-wrap: wrap; gap: 4px; }
.pack-detail-chart { min-width: 56px; padding: 3px 6px; display: inline-flex; align-items: baseline; justify-content: space-between; gap: 5px; color: #d9d4dd; background: #211d27; border-left: 3px solid #8d61b8; font-variant-numeric: tabular-nums; }
.pack-detail-chart b { font-size: 12px; }
.pack-detail-chart small { color: #8e8795; font-size: 8px; }
.pack-edit-dialog { width: min(960px, calc(var(--viewport-width) - 32px)); max-width: calc(var(--viewport-width) - 32px); height: min(780px, calc(var(--viewport-height) - 32px)); max-height: calc(var(--viewport-height) - 32px); padding: 0; overflow: hidden; color: var(--text); background: #18171d; border: 1px solid #403a4b; }
.pack-edit-dialog::backdrop { background: #08070bc7; }
.pack-edit-dialog form { width: 100%; min-width: 0; height: 100%; padding: 18px 22px; box-sizing: border-box; display: grid; grid-template-rows: auto auto minmax(90px, 1fr) auto auto; gap: 10px; overflow: hidden; }
.pack-edit-dialog .dialog-heading { justify-content: space-between; align-items: center; gap: 7px; }
.pack-edit-dialog h2 { margin: 0; }
.pack-manage-loading, .pack-manage-error { min-height: 190px; padding: 24px; display: flex; align-items: center; justify-content: center; gap: 9px; color: #aaa4b2; }
.pack-manage-error { flex-direction: column; color: #d9939a; }
.pack-manage-fields { min-width: 0; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 8px 14px; }
.pack-manage-fields > label, .pack-manage-banner, .pack-manage-banner > label { min-width: 0; }
.pack-manage-fields > label:nth-child(1) { grid-column: span 5; grid-row: 1; }
.pack-manage-fields > label:nth-child(2) { grid-column: span 5; grid-row: 1; }
.pack-manage-fields > label:nth-child(3) { grid-column: span 2; grid-row: 1; }
.pack-manage-fields > label:nth-child(4) { grid-column: span 6; grid-row: 2; }
.pack-manage-fields > .pack-manage-banner { grid-column: span 6; grid-row: 2; }
.pack-edit-dialog label { display: grid; gap: 5px; color: #bcb6c4; font-size: 12px; font-weight: 650; }
.pack-edit-dialog input, .pack-edit-dialog textarea { width: 100%; min-width: 0; max-width: 100%; padding: 9px 10px; color: var(--text); background: #0e0d12; border: 1px solid #393641; border-radius: 3px; outline: 0; resize: vertical; }
.pack-edit-dialog input:focus, .pack-edit-dialog textarea:focus { border-color: var(--accent); }
.pack-edit-dialog .pack-edit-check { display: flex; align-items: center; gap: 8px; }
.pack-edit-dialog .pack-edit-check input { flex: 0 0 auto; width: 15px; height: 15px; }
.pack-manage-banner { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 14px; }
.pack-manage-charts { min-height: 0; display: grid; grid-template-rows: auto auto auto minmax(0, 1fr); gap: 5px; overflow: hidden; }
.pack-manage-charts > div:first-child { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.pack-manage-charts h3 { margin: 0; font-size: 14px; }
.pack-manage-charts > div:first-child > span { display: flex; flex-wrap: wrap; gap: 7px; }
.pack-edit-dialog .pack-manage-ranked { margin-right: 5px; white-space: nowrap; }
.pack-manage-charts button:not([type="submit"]) { padding: 4px 7px; color: #a9a2b0; background: #121116; border: 1px solid #37333e; border-radius: 3px; cursor: pointer; }
.pack-manage-charts > p { margin: 0; color: #77717f; font-size: 10px; }
.pack-manage-chart-head { padding: 2px 8px; display: grid; grid-template-columns: minmax(120px, 1fr) 40px 55px 64px 110px 120px; gap: 8px; color: #6f6976; font-size: 8px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.pack-manage-chart-list { min-height: 0; overflow-y: auto; background: #0d0c11; border: 1px solid #2b2831; }
.pack-edit-dialog .pack-manage-chart { min-height: 34px; padding: 3px 8px; display: grid; grid-template-columns: minmax(120px, 1fr) 40px 55px 64px 110px 120px; align-items: center; gap: 8px; border-bottom: 1px solid #211f26; }
.pack-manage-other { color: #aaa4b1; font-size: 11px; font-variant-numeric: tabular-nums; }
.pack-edit-dialog .pack-manage-chart:last-child { border-bottom: 0; }
.pack-edit-dialog .pack-manage-chart:hover { background: #15131a; }
.pack-edit-dialog .pack-manage-chart input { width: 14px; height: 14px; padding: 0; accent-color: var(--accent); }
.pack-edit-dialog .pack-manage-chart .pack-manage-previous { opacity: .45; cursor: default; }
.pack-edit-dialog .pack-manage-toggle { width: 28px; height: 30px; display: grid; place-items: center; cursor: pointer; }
.pack-edit-dialog .pack-manage-toggle input { width: 18px; height: 18px; cursor: pointer; }
.pack-manage-chart code { overflow: hidden; color: #77717f; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.pack-manage-song { overflow: hidden; color: #c5bfca; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.pack-manage-difficulty { font-size: 10px; font-weight: 800; }
.pack-manage-empty { min-height: 70px; display: grid; place-items: center; color: #77717f; font-size: 11px; }
.pack-edit-dialog button[type="submit"] { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.pack-edit-dialog button[type="submit"] .pack-spinner { width: 14px; height: 14px; border-width: 2px; }
.pack-edit-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pack-edit-actions .button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.pack-edit-actions .pack-spinner { width: 14px; height: 14px; border-width: 2px; }

@media (max-width: 850px) {
    :root { --page-gutter: 16px; }
    .site-header { height: auto; min-height: 66px; }
    .site-header-inner { grid-template-columns: auto 1fr; row-gap: 0; }
    .primary-nav { grid-column: 1 / -1; grid-row: 2; overflow-x: auto; }
    .header-actions { grid-column: 2; grid-row: 1; }
    .primary-nav a { padding-inline: 10px; }
    .panel-grid { grid-template-columns: 1fr; }
    .manage-grid { grid-template-columns: 1fr; }
    .manage-player-panel { grid-row: auto; }
    .leaderboard-group { grid-template-columns: 1fr; gap: 9px; }
    .section-label { padding-top: 0; }
    .home-description { grid-template-columns: 1fr; gap: 8px; }
    .home-directory a { grid-template-columns: 120px minmax(0, 1fr) auto; }
    .home-status { grid-template-columns: 1fr; gap: 8px; }
    .simple-home-links { grid-template-columns: 1fr; }
    .simple-wip { grid-template-columns: 1fr; }
    .home-hero, .addon-section { grid-template-columns: 1fr; }
    .home-snapshot { max-width: 520px; }
    .feature-list { grid-template-columns: 1fr; }
    .feature { min-height: 210px; }
    .wip-section { grid-template-columns: 1fr; }
    .pack-toolbar { grid-template-columns: 1fr; }
    .pack-manage-fields { grid-template-columns: 1fr; }
    .pack-manage-fields > label { grid-column: 1 !important; grid-row: auto !important; }
    .pack-manage-fields > .pack-manage-banner { grid-column: 1; grid-row: auto; }
    .pack-manage-chart-head { grid-template-columns: 38px 32px 58px 48px 32px minmax(100px, 1fr); }
    .pack-manage-chart-head span:nth-child(6) { display: none; }
    .pack-edit-dialog .pack-manage-chart { grid-template-columns: 38px 32px 58px 48px 32px minmax(100px, 1fr); }
    .pack-manage-chart code { display: none; }
    .pack-card-link { padding-right: 8px; grid-template-columns: 150px minmax(0, 1fr); }
    .pack-banner-link > img, .pack-card-fallback { width: 150px; height: 48px; }
    .pack-detail-hero { grid-template-columns: 1fr; }
    .pack-detail-hero > img, .pack-detail-banner-fallback { height: auto; aspect-ratio: 3 / 1; }
    .pack-song { grid-template-columns: 120px minmax(0, 1fr); }
    .pack-song > img, .pack-song-fallback { width: 120px; height: 48px; }
    .pack-msd { grid-column: 1 / -1; }
    .pack-actions { position: static; margin: 0 8px 9px auto; width: max-content; }
}
* { scrollbar-width: thin; scrollbar-color: #51485e #151419; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-track { background: #151419; }
*::-webkit-scrollbar-thumb { background: #51485e; border: 2px solid #151419; border-radius: 999px; }
*::-webkit-scrollbar-thumb:hover { background: #795ca0; }
*::-webkit-scrollbar-corner { background: #151419; }
.pack-browser-heading:has(.pack-collection-stats) { display: grid; grid-template-columns: minmax(0, 1fr) 360px; column-gap: 32px; row-gap: 12px; align-items: end; }
.pack-browser-heading:has(.pack-collection-stats) h1 { grid-column: 1 / -1; }
.pack-browser-heading:has(.pack-collection-stats) p { margin: 0; }
/* Keep the same columns and three-row height before the request completes. */
.pack-collection-stats { display: grid; gap: 6px; align-content: end; justify-self: end; width: 360px; min-height: 66px; max-width: 100%; color: var(--muted); font-size: 12px; line-height: 1.5; text-align: right; }
.pack-collection-stats[hidden] { display: grid; visibility: hidden; }
.pack-collection-stats-row { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px 18px; }
.pack-collection-stats-row > span { white-space: nowrap; }
.pack-collection-stats strong { color: var(--text); font-size: inherit; font-weight: 500; font-variant-numeric: tabular-nums; }
@media (max-width: 1000px) {
    .pack-browser-heading:has(.pack-collection-stats) { grid-template-columns: minmax(0, 1fr); }
    .pack-collection-stats { margin-top: 2px; }
}
@media (max-width: 440px) {
    .pack-collection-stats { min-height: 114px; }
}
.settings-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; max-width: 1000px; }
.settings-card { padding: 22px; display: flex; flex-direction: column; gap: 18px; border: 1px solid var(--border); background: var(--surface); border-radius: 6px; min-width: 0; }
.settings-card h2 { margin: 0; font-size: 20px; }
.settings-card label { display: grid; gap: 7px; color: var(--muted); font-size: 13px; }
.settings-card input, .profile-rating-settings select { min-width: 0; width: 100%; padding: 10px; border: 1px solid var(--border); border-radius: 3px; color: var(--text); background: #18171f; font: inherit; }
.settings-card input:focus-visible, .profile-rating-settings select:focus-visible { outline: 1px solid var(--accent); }
.settings-avatar { display: flex; align-items: center; gap: 18px; }
.settings-avatar img { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; }
.settings-avatar p { color: var(--muted); font-size: 13px; line-height: 1.8; }
.settings-card .button { align-self: flex-start; margin-top: auto; gap: 8px; }
.settings-message { min-height: 20px; margin: 0; color: var(--danger); font-size: 13px; }
.settings-message.is-success { color: #83ca96; }
.settings-card .is-saving::before { content: ''; width: 12px; height: 12px; border: 2px solid #ffffff40; border-top-color: currentColor; border-radius: 50%; animation: pack-spin .7s linear infinite; }
.profile-rating-settings { display: grid; gap: 10px; padding: 12px 11px; border-block: 1px solid var(--border); }
.profile-rating-settings > span { font-size: 12px; color: var(--muted); }
.profile-rating-settings label { display: grid; gap: 5px; font-size: 12px; }
.profile-rating-settings select { padding: 7px; }
.profile-flyout { width: 270px; max-height: calc(var(--viewport-dynamic-height) - 110px); overflow-y: auto; }
@media (max-width: 850px) { .pack-song-toolbar { top: 100px; } }
@media (max-width: 700px) { .settings-grid { grid-template-columns: 1fr; } }

.pack-manage-song small { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; }
.pack-manage-state-pair { display: flex; align-items: center; justify-content: center; gap: 18px; }
.pack-manage-chart-head > span:nth-child(n+2) { text-align: center; }
.pack-manage-chart-head small { display: block; margin-top: 6px; color: #aaa4b1; font-size: 10px; text-transform: none; letter-spacing: 0; }
.pack-manage-chart > b, .pack-manage-difficulty, .pack-manage-other { text-align: center; font-variant-numeric: tabular-nums; }
.pack-manage-chart-head { font-size: 10px; padding-block: 8px; color: #b3adbd; }
.pack-manage-difficulty { font-size: 13px; }
.pack-manage-chart > b { font-size: 13px; }
.pack-edit-dialog .pack-manage-chart { min-height: 45px; }

@media (max-width: 600px) {
    .pack-card-link { grid-template-columns: minmax(0, 1fr); }
    .pack-banner-link > img, .pack-card-fallback { width: 100%; height: 110px; }
    .pack-card-meta, .pack-stat-row { flex-wrap: wrap; gap: 8px 12px; }
    .pack-card-heading code { flex-shrink: 0; }
    .pack-card-copy { width: 100%; }
    .pack-song-toolbar { flex-wrap: wrap; }
    .pack-song-toolbar input { min-width: 0; width: 100%; }
}
.profile-heading { display: flex; align-items: center; gap: 24px; }
.load-error { line-height: 1.6; }
.retry-link { display: inline; padding: 0; margin-left: 5px; border: 0; background: none; color: var(--accent-hover); font: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.retry-link:hover { color: var(--text); }
.retry-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.pack-card-fallback, .pack-song-fallback, .pack-detail-banner-fallback { display: grid; place-items: center; color: var(--muted); font-size: 13px; font-weight: 400; }
.pack-card .pack-msd { min-height: 76px; padding: 0; background: none; border: 0; border-radius: 0; }
.pack-card .pack-msd-skillsets { top: 0; left: 0; gap: 6px; }
.pack-card .pack-msd-rating { top: -3px; right: 0; background: none; }
.pack-card .pack-msd-plot { padding-top: 25px; }
.pack-card .pack-msd-plot > svg { height: 51px; }
.pack-card .pack-msd-no-data { height: 51px; }
.pack-card .pack-msd-empty { min-height: 76px; }
.pack-card .pack-card-meta { flex-wrap: wrap; gap: 5px 12px; }
.pack-card .pack-player-rating-count { margin-left: 0; }
.pack-card .pack-ranked { margin-left: -5px; }
@media (max-width: 1100px) {
    .pack-card-link { grid-template-columns: 150px minmax(0, 1fr); gap: 12px; }
    .pack-banner-link > img, .pack-card-fallback { width: 150px; height: 50px; }
    .pack-card .pack-msd, .pack-card .pack-msd-empty { grid-column: 2; }
    .pack-card .pack-actions { margin: 0; width: auto; }
}
@media (max-width: 600px) {
    .pack-card { grid-template-columns: minmax(0, 1fr) 48px; }
    .pack-card-link { grid-template-columns: minmax(0, 1fr); padding: 12px 8px; }
    .pack-banner-link > img, .pack-card-fallback { width: 100%; height: auto; aspect-ratio: 3.1; }
    .pack-card .pack-msd, .pack-card .pack-msd-empty { grid-column: 1; }
    .pack-card-heading { flex-wrap: wrap; gap: 4px; }
    .pack-card-heading strong { white-space: normal; overflow-wrap: anywhere; }
    .pack-card-heading code { margin-left: 0; }
    .pack-card .pack-actions { justify-content: flex-end; flex-direction: column; padding: 14px 2px; }
    .pack-file-size { font-size: 10px; }
}
@media (max-width: 520px) { .site-header-inner { grid-template-columns: minmax(0, 1fr) auto; } .brand { font-size: 24px; } .primary-nav { min-width: 0; } }
.profile-picture { width: 112px; height: 112px; flex-shrink: 0; display: grid; place-items: center; border-radius: 16px; overflow: hidden; background: #ffffff08; color: #9da5b5; }
.profile-picture img { width: 100%; height: 100%; object-fit: cover; }
.profile-picture .profile-state { font-size: 11px; flex-direction: column; padding: 8px; }
.profile-filters { margin-bottom: 24px; }
.profile-filters .page-calculation-controls .option { flex: 1 1 110px; min-width: 0; max-width: 100%; }
.profile-filters .page-calculation-controls .option-mina { flex-basis: 280px; }
.profile-filters .page-calculation-controls .option-wide { flex-basis: 180px; }
.profile-identity, .profile-filters > div { min-width: 0; }
.profile-identity h1 { overflow-wrap: anywhere; }
.profile-filters p, .profile-top-description { color: #9da5b5; font-size: 13px; }
.player-profile { max-width: 1180px; }
.chart-board { max-width: 1180px; }
.chart-board-note, .chart-board-stats { font-size: 12px; color: var(--muted); margin: 16px 0; }
.chart-score-scroll { overflow-x: auto; }
.chart-score-table { width: 100%; border-collapse: collapse; font-size: 13px; white-space: nowrap; }
.chart-score-table th, .chart-score-table td { padding: 12px; border-bottom: 1px solid var(--border); text-align: right; }
.chart-score-table th { color: var(--muted); font-weight: 500; }
.chart-score-table th:first-child, .chart-score-table td:first-child { text-align: left; }
.chart-score-table a:hover { color: var(--accent-hover); }
.chart-board [data-status]:empty { display: none; }
.profile-overview { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 32px; padding: 20px 0 26px; border-bottom: 1px solid var(--border); margin-bottom: 28px; }
.profile-heading { align-self: start; flex-direction: column; align-items: flex-start; gap: 16px; }
.profile-picture { width: 104px; height: 104px; border-radius: 10px; }
.profile-skills { width: 100%; max-width: 580px; min-width: 0; }
.profile-skills [data-skills] { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; }
.profile-skill { display: grid; grid-template-columns: 100px minmax(0, 1fr) 48px 64px; align-items: center; gap: 12px; min-width: 0; padding: 0; color: inherit; }
.profile-skill-label { font-size: 13px; font-weight: 600; }
.profile-skill-rank { font-size: 16px; font-weight: 600; color: #fff; text-align: right; font-variant-numeric: tabular-nums; }
.profile-skill-value { text-align: right; font-size: 16px; font-variant-numeric: tabular-nums; }
.profile-skill-track { display: block; height: 7px; background: #ffffff0b; border-radius: 2px; overflow: hidden; }
.profile-skill-track > span { display: block; height: 100%; }
.profile-state { min-height: 100px; padding: 20px; display: flex; justify-content: center; align-items: center; gap: 12px; color: var(--muted); text-align: center; }
.profile-tops-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.profile-tops-heading h2 { margin: 0; font-size: 20px; }
.profile-tops-heading > span { color: var(--muted); font-size: 12px; }
.profile-skill-tabs { display: flex; gap: 6px; overflow-x: auto; border-bottom: 1px solid var(--border); margin-bottom: 12px; }
.profile-skill-tabs[hidden] { display: none; }
#profile-score-view { overflow-anchor: none; }
.profile-score-tabs { display: flex; gap: 20px; border-bottom: 1px solid var(--border); margin-bottom: 12px; overflow-x: auto; }
.profile-score-tabs button { flex-shrink: 0; padding: 8px 0 12px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); font: inherit; font-size: 16px; font-weight: 600; cursor: pointer; }
.profile-score-tabs button:hover { color: var(--text); }
.profile-score-tabs button[aria-selected="true"] { color: var(--text); border-bottom-color: var(--accent); }
.profile-skill-tabs button { flex-shrink: 0; border: 0; border-bottom: 2px solid transparent; padding: 10px 13px; background: transparent; color: var(--skillset-color, var(--muted)); font: inherit; font-size: 13px; cursor: pointer; }
.profile-skill-tabs button:hover { color: var(--skillset-color, var(--text)); background: #ffffff05; }
.profile-skill-tabs button[aria-selected="true"] { color: var(--skillset-color, var(--text)); border-bottom-color: var(--skillset-color, var(--accent)); }
.profile-score-scroll { overflow-x: auto; }
.profile-score-list { width: 100%; min-width: 1110px; border-collapse: collapse; table-layout: fixed; font-size: 12px; font-variant-numeric: tabular-nums; }
.profile-score-list th { text-align: right; color: var(--muted); font-size: 10px; font-weight: 500; padding: 8px 6px; border-bottom: 1px solid var(--border); }
.profile-score-list td { padding: 10px 6px; border-bottom: 1px solid #ffffff0b; text-align: right; }
.profile-score-list th:first-child { width: 24px; }
.profile-score-list th:nth-child(2) { width: 325px; text-align: left; }
.profile-score-list th:nth-child(3) { width: 54px; }
.profile-score-list th:nth-child(4) { width: 72px; }
.profile-score-list th:nth-child(5) { width: 45px; }
.profile-score-list th:nth-child(6) { width: 55px; }
.profile-score-list th:nth-child(n+7):nth-child(-n+12) { width: 43px; }
.profile-score-list th:last-child { width: 210px; }
.profile-score-list tr:hover td { background: #ffffff03; }
.profile-score-list tbody tr { cursor: pointer; }
.profile-score-list td:nth-child(2) { width: 110px; }
.profile-score-list .profile-score-song { text-align: left; }
.profile-score-position { color: var(--muted); }
.profile-score-banner { width: 100%; height: 48px; display: grid; place-items: center; overflow: hidden; border-radius: 3px; background: #ffffff04; color: var(--muted); font-size: 10px; }
.profile-score-banner img { width: 100%; height: 100%; object-fit: cover; }
.profile-score-song strong, .profile-score-song small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-score-song strong { font-size: 13px; }
.profile-score-song small { color: var(--muted); font-size: 11px; margin-top: 3px; }
.profile-score-meta { display: flex; gap: 7px; color: var(--muted); font-size: 10px; margin-top: 5px; }
.profile-score-meta a { color: var(--muted); }
.profile-score-song a:hover, .profile-score-target:hover { color: var(--accent-hover); }
.profile-score-rating, .profile-score-wife { font-weight: 600; }
.profile-score-judgment.is-zero { opacity: .28; }
.profile-score-plot { height: 52px; display: flex; align-items: center; justify-content: center; gap: 5px; font-size: 10px; color: var(--muted); background: #101015; border-radius: 3px; overflow: hidden; }
.profile-score-plot canvas { display: block; width: 100%; height: 100%; }
.profile-score-plot button { cursor: pointer; color: var(--accent); background: transparent; border: 0; padding: 4px; }
@media (max-width: 760px) {
    .profile-overview { grid-template-columns: minmax(0, 1fr); gap: 24px; }
    .profile-heading { flex-direction: row; align-items: center; }
    .profile-picture { width: 80px; height: 80px; }
}
@media (max-width: 520px) {
    .profile-skill { grid-template-columns: 92px minmax(0, 1fr) 45px 64px; gap: 6px; }
    .profile-tops-heading { flex-wrap: wrap; }
}
/* global statistics share one fixed timeline for both history graphs */
.global-stats { min-width: 0; }
.stats-metrics { display: flex; flex-wrap: wrap; gap: 20px 40px; margin: 16px 0; }
.stats-metrics dt, .stats-caption { color: #9e9aa9; font-size: .9rem; }
.stats-metrics dd { margin: 5px 0 0; font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.stats-collection, .stats-history { margin-top: 28px; border-top: 1px solid #ffffff15; padding-top: 18px; }
.global-stats h2 { font-size: 1.05rem; font-weight: 600; margin: 0 0 12px; }
.stats-chart { display: block; width: 100%; max-height: 320px; margin: 12px 0 28px; overflow: visible; }
.stats-chart text { fill: #aaa5b7; font: 12px sans-serif; }
.stats-grid { stroke: #ffffff16; stroke-width: 1; }
.stats-bar { fill: #ac8ddd; }
.stats-chart g:hover .stats-bar { fill: #d8baff; }
.stats-line { fill: none; stroke: #ac8ddd; stroke-width: 2.5; }
.stats-dot { fill: #ac8ddd; }
.stats-chart g:hover .stats-dot { fill: #fff; r: 4; }
.stats-hit { fill: transparent; }
.stats-empty { padding: 24px 0; color: #9e9aa9; }
@media (max-width: 600px) { .stats-metrics { gap: 16px 25px; } .stats-chart { min-height: 180px; } }
