/* Additions scoped to SELECT's new level/rating UI. Existing category/period controls stay unchanged. */
#tab-rating.select-rating-enabled .rating-inner-tabs { grid-template-columns:repeat(4,minmax(0,1fr)); }
#tab-rating.select-rating-enabled .rating-categories[hidden], #tab-rating.select-rating-enabled #month-bar[hidden] { display:none; }
.select-rating-note { padding:0 16px 12px; font-size:11px; line-height:1.5; color:var(--muted); }
.select-level { padding:16px; margin:16px; border:1px solid var(--border2); border-radius:16px; background:var(--brand-gradient-soft); font-family:'Hauora',sans-serif; }
.select-level[hidden] { display:none; }
.select-level-track { margin-top:12px; height:5px; background:var(--surface-12); border-radius:3px; overflow:hidden; }
.select-level-track i { display:block; height:100%; background:linear-gradient(90deg,#FF6B00,#FF8A2B); }
.select-level-icon { width:25px; height:27px; flex-shrink:0; }
.select-level-icon img { display:block; width:100%; height:100%; object-fit:contain; }
.select-level-roadmap { padding:0 16px 8px; }
.select-level-step { display:grid; grid-template-columns:20px minmax(0,1fr) 16px; gap:7px; align-items:center; min-height:34px; box-sizing:border-box; padding:4px 7px; border-bottom:1px solid var(--border); }
.select-level-step strong { font-size:12px; line-height:1.2; font-weight:600; color:var(--text); }
.select-level-step small { display:block; margin:0; font-size:10px; white-space:nowrap; color:var(--muted); }
.select-level-step .select-level-mark { color:#FF8A2B; font-size:14px; text-align:center; line-height:1; }
.select-level-step.is-current { border-radius:8px; background:linear-gradient(90deg,rgba(255,107,0,.19),rgba(255,107,0,.09)); box-shadow:inset 0 0 0 1px rgba(255,138,43,.35); }
.select-level-step.is-current strong { color:#FFAD5C; font-weight:800; font-size:12px; }
.select-level-step.is-current small { color:#FF8A2B; }
.select-level-step.is-current .select-level-mark { font-size:15px; }
.select-level-step.is-locked strong { color:var(--muted); }
.select-level-step.is-locked .select-level-icon { opacity:.45; }
.select-home-level { position:relative; margin:10px 16px 14px; padding:12px; border-radius:18px; border-color:rgba(255,138,43,.2); background:radial-gradient(ellipse at top left,rgba(255,107,0,.11),transparent 65%),linear-gradient(145deg,var(--surface-06),var(--surface-02)); }
.select-home-level-top { display:flex; align-items:center; gap:10px; }
.select-home-level-badge { width:40px; height:44px; padding:6px; box-sizing:border-box; border-radius:10px; background:var(--accent-faint); box-shadow:inset 0 0 0 1px rgba(255,138,43,.22); }
.select-home-level-kicker { color:var(--muted); font-size:10px; letter-spacing:.08em; }
.select-home-level-info h2 { margin:2px 0; color:var(--text); font-size:20px; font-weight:600; line-height:1.15; letter-spacing:-.03em; text-wrap:balance; }
.select-home-level-points { display:flex; flex-wrap:wrap; align-items:baseline; gap:5px; }
.select-home-level-points strong { color:#FF8A2B; font-size:16px; font-weight:600; font-variant-numeric:tabular-nums; }
.select-home-level-points span { color:var(--muted); font-size:10px; }
.select-home-level .select-level-track { margin-top:10px; height:4px; }
.select-home-level-next { display:flex; flex-wrap:wrap; justify-content:space-between; gap:4px 10px; margin-top:6px; color:var(--text2); font-size:10px; }
.select-home-level-next b { font-weight:600; color:var(--text); }
.select-home-level-link { display:flex; width:100%; align-items:center; justify-content:space-between; min-height:40px; margin-top:2px; padding:0; color:#FF8A2B; border:0; background:none; font-family:inherit; font-size:12px; cursor:pointer; }
.select-home-level-link:active { transform:scale(.96); }
.select-home-level-details > summary { list-style:none; box-sizing:border-box; }
.select-home-level-details > summary::-webkit-details-marker { display:none; }
.select-home-level-details[open] > summary span { transform:rotate(180deg); }
.select-home-level-details .select-level-roadmap { padding:0; }
.select-home-level { scroll-margin-top:8px; background-color:var(--bg); }

.select-level-step > div:not(.select-level-icon) { display:flex; align-items:baseline; justify-content:space-between; gap:6px; min-width:0; }
.select-level-step .select-level-icon { width:20px; height:22px; }

/* The rating groups players by level; the home card keeps its own compact roadmap. */
.select-level-groups { display:grid; gap:10px; padding:10px 16px 20px; }
.select-level-group { overflow:hidden; border:1px solid var(--border); border-radius:16px; background:var(--surface-04); }
.select-level-group.is-own, .select-level-group[open] { border-color:rgba(255,138,43,.5); }
.select-level-group > summary { display:grid; grid-template-columns:44px minmax(0,1fr) 32px 14px; align-items:center; gap:12px; min-height:82px; padding:14px; box-sizing:border-box; list-style:none; cursor:pointer; }
.select-level-group > summary::-webkit-details-marker { display:none; }
.select-level-group > summary:focus-visible { outline:2px solid #FF8A2B; outline-offset:-3px; border-radius:15px; }
.select-level-group > summary .select-level-icon { width:44px; height:44px; }
.select-level-group-title { display:grid; gap:4px; min-width:0; }
.select-level-group-title strong { font-size:18px; line-height:1.2; font-weight:700; color:var(--text); }
.select-level-group-title > span { color:var(--muted); font-size:12px; }
.select-level-count { display:grid; place-items:center; width:32px; height:32px; border-radius:50%; background:rgba(255,107,0,.12); color:#FF8A2B; font-size:13px; font-weight:700; font-variant-numeric:tabular-nums; }
.select-level-chevron { color:var(--muted); font-size:18px; text-align:center; }
.select-level-group[open] > summary .select-level-chevron { transform:rotate(180deg); }
.select-level-members { border-top:1px solid var(--border); padding:14px; color:var(--text2); font-size:13px; line-height:1.5; }
.select-level-member + .select-level-member { margin-top:16px; padding-top:16px; border-top:1px solid var(--border); }
.select-level-member-heading { display:flex; align-items:baseline; justify-content:space-between; gap:12px; }
.select-level-member-heading > strong { min-width:0; overflow-wrap:anywhere; color:var(--text); font-size:15px; font-weight:600; }
.select-level-member-heading small { margin-left:7px; color:#FF8A2B; font-size:11px; }
.select-level-member-heading > b { flex-shrink:0; color:#FF8A2B; font-size:20px; font-weight:700; font-variant-numeric:tabular-nums; }
.select-level-member .select-level-track { height:6px; margin-top:8px; }
.select-level-member p { margin:6px 0 0; font-size:11px; color:var(--muted); }
.select-level-list-note { margin:12px 0 0; font-size:11px; color:var(--muted); }

.select-rating-state { padding:28px 16px; text-align:center; color:var(--text2); font-size:13px; line-height:1.5; }
.select-rating-state p { margin:0; }
.select-rating-retry { margin-top:12px; min-height:40px; padding:8px 16px; border:1px solid var(--border2); border-radius:10px; background:var(--surface-06); color:var(--text); font:inherit; cursor:pointer; }
.select-rating-retry:active { transform:scale(.96); }
#tab-rating.select-rating-enabled .rating-inner-tabs button.rating-tab:focus-visible, .select-home-level-link:focus-visible, .select-rating-retry:focus-visible { outline:2px solid var(--accent); outline-offset:-3px; }

.select-level-caption { margin:12px 16px 0; color:var(--muted); font-size:12px; }

.player-public-level-badge { display:flex; align-items:center; gap:7px; margin-top:7px; color:#FF8A2B; font-size:14px; font-family:'Hauora',sans-serif; }
.player-public-level-badge .select-level-icon { width:22px; height:24px; }
.player-profile-content-tabs { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; margin-bottom:10px; border-bottom:1px solid var(--border); }
.player-profile-content-tabs button { min-height:40px; padding:8px 3px; border:0; border-bottom:2px solid transparent; background:none; color:var(--muted); font:inherit; font-size:12px; letter-spacing:.06em; text-transform:uppercase; cursor:pointer; }
.player-profile-content-tabs button.active { border-bottom-color:var(--accent); color:var(--text); }
.player-profile-content-tabs button > span { margin-left:5px; font-size:10px; }
.player-profile-content-tabs button:focus-visible { outline:2px solid var(--accent); outline-offset:-3px; }
#other-player-achievements[hidden], #other-player-history[hidden] { display:none; }
.player-profile-history .shared-player-achievements { margin-top:0; }

/* Profile-only artwork carousel. The home and public profile badges stay compact. */
.select-level-journey { margin:16px; font-family:'Hauora',sans-serif; }
.select-level-journey[hidden] { display:none; }
.select-journey-heading { display:flex; justify-content:space-between; align-items:center; gap:12px; }
.select-journey-heading h2 { margin:0; font-size:11px; font-weight:600; letter-spacing:.12em; text-transform:uppercase; color:var(--muted); }
.select-journey-heading > span { color:#FF8A2B; font-size:13px; font-variant-numeric:tabular-nums; white-space:nowrap; }
.select-journey-navigation { display:flex; align-items:center; justify-content:center; gap:12px; margin:2px 0 6px; }
.select-journey-navigation > span { color:var(--muted); font-size:11px; }
.select-journey-navigation button { display:grid; place-items:center; width:40px; height:40px; padding:0; border:0; background:none; color:#FF8A2B; font:inherit; font-size:20px; cursor:pointer; }
.select-journey-navigation button:disabled { opacity:.25; cursor:default; }
.select-journey-navigation button:active, .select-journey-lock button:active { transform:scale(.96); }
.select-journey-track { position:relative; display:flex; gap:12px; overflow-x:auto; overscroll-behavior-x:contain; scroll-snap-type:x mandatory; scrollbar-width:none; border-radius:22px; -webkit-overflow-scrolling:touch; }
.select-journey-track::-webkit-scrollbar { display:none; }
.select-journey-card { position:relative; flex:0 0 100%; box-sizing:border-box; height:auto; aspect-ratio:4 / 5; overflow:hidden; scroll-snap-align:start; scroll-snap-stop:always; border-radius:22px; background:radial-gradient(ellipse at 50% 40%,#102b4d,#021127 78%); box-shadow:inset 0 0 0 1px rgba(255,255,255,.12); }
.select-journey-card.is-current { box-shadow:inset 0 0 0 1px rgba(255,138,43,.7),inset 0 0 32px rgba(255,107,0,.08); }
.select-journey-image { display:block; width:100%; height:100%; object-fit:cover; }
.select-journey-card::after { content:""; position:absolute; inset:0; z-index:2; border-radius:inherit; box-shadow:inset 0 0 0 1px rgba(255,255,255,.14); pointer-events:none; }
.select-journey-card.is-current::after { box-shadow:inset 0 0 0 1px rgba(255,138,43,.75); }
.select-journey-info { position:absolute; inset:auto 0 0; padding:40px 18px 20px; background:linear-gradient(0deg,rgba(2,12,29,.98),rgba(2,12,29,.85) 45%,rgba(2,12,29,0)); }
.select-journey-status { display:inline-block; padding:5px 9px; border:1px solid rgba(255,255,255,.14); border-radius:999px; font-size:10px; color:var(--text2); }
.is-current .select-journey-status { color:#FFAD5C; background:rgba(255,107,0,.1); border-color:rgba(255,138,43,.4); }
.select-journey-info h3 { margin:9px 0 2px; font:400 32px/1 var(--font-display); text-transform:uppercase; text-wrap:balance; color:var(--text); }
.select-journey-info p { margin:5px 0 0; font-size:12px; color:var(--text2); font-variant-numeric:tabular-nums; }
.select-journey-card.is-locked .select-journey-image { filter:grayscale(1); opacity:.22; }
.select-journey-lock { position:absolute; inset:1px; z-index:1; display:flex; flex-direction:column; justify-content:center; align-items:center; gap:12px; padding:28px; border-radius:21px; background:rgba(3,14,35,.7); backdrop-filter:blur(9px); text-align:center; }
.select-journey-lock > img { width:32px; height:32px; object-fit:contain; opacity:.8; }
.select-journey-lock > span { font-size:10px; letter-spacing:.18em; text-transform:uppercase; color:var(--muted); }
.select-journey-lock > strong { font:400 30px/1.05 var(--font-display); text-transform:uppercase; text-wrap:balance; }
.select-journey-lock p { max-width:220px; margin:0; color:var(--text2); font-size:13px; line-height:1.5; }
.select-journey-lock button { min-height:44px; margin-top:8px; padding:11px 17px; border:1px solid rgba(255,138,43,.45); border-radius:12px; background:rgba(255,107,0,.13); color:#FFAD5C; font:inherit; font-size:12px; cursor:pointer; }
.select-journey-progress { margin-top:12px; padding:14px; border-radius:16px; background:var(--brand-gradient-soft); box-shadow:inset 0 0 0 1px rgba(255,255,255,.12); }
.select-journey-total { display:flex; justify-content:space-between; align-items:baseline; flex-wrap:wrap; gap:6px 12px; font-size:12px; color:var(--text2); }
.select-journey-total b, .select-journey-total > strong { color:#FF8A2B; font-weight:600; }
.select-journey-total > strong { font-variant-numeric:tabular-nums; }
.select-journey-progress > p { margin:9px 0 0; color:var(--text2); font-size:12px; }
.select-journey-progress .select-level-roadmap { padding:0; }
.select-journey-track:focus-visible, .select-journey-navigation button:focus-visible, .select-journey-lock button:focus-visible { outline:2px solid #FF8A2B; outline-offset:2px; }
@media (prefers-reduced-motion:reduce) { .select-journey-track { scroll-behavior:auto; } }

#tab-rating.select-rating-enabled .rating-tab { min-width:0; min-height:64px; padding-inline:4px; white-space:nowrap; }
#tab-rating.select-rating-enabled .rating-tab > span:last-child { font-size:clamp(10px,2.9vw,13px); }
.select-top18 { padding:12px 16px 24px; }
.select-top18 .select-rating-note { padding:12px 0; }
.select-top18-table table { width:100%; border-collapse:collapse; table-layout:fixed; font-variant-numeric:tabular-nums; font-size:12px; }
.select-top18-table th,.select-top18-table td { padding:12px 3px; text-align:right; border-bottom:1px solid var(--border); }
.select-top18-table thead th { font-size:10px; font-weight:500; color:var(--muted); }
.select-top18-table th:first-child,.select-top18-table td:first-child { width:22px; text-align:left; color:var(--muted); }
.select-top18-table th:nth-child(2) { width:34%; text-align:left; overflow-wrap:anywhere; }
.select-top18-table tbody th { font-weight:500; }
.select-top18-table th button { display:block; min-height:40px; width:100%; border:0; background:transparent; color:inherit; font:inherit; text-align:left; padding:0; cursor:pointer; }
.select-top18-table small { display:block; color:var(--muted); font-size:9px; margin-top:3px; }
.select-top18-total { font-weight:800; }
.select-top18 button:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
@media(max-width:350px) { .select-top18 { padding-inline:10px; } .select-top18-table table { font-size:11px; } }

.select-top18 .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; }

.select-top18-action { cursor:pointer; }
.select-top18-action:hover { background:var(--surface-06); }

/* Reuse the approved filled trophy artwork and distinguish the final with its number. */
#tab-rating.select-rating-enabled .rating-top18-icon { position:relative; }
#tab-rating.select-rating-enabled .rating-top18-number { position:absolute; left:50%; top:calc(50% + 1px); transform:translate(-50%,-50%); color:var(--bg); font:800 7px/1 var(--font-sans); letter-spacing:-.04em; }
