/* SPPickEmLeague "Arena" look (Update 31): night game under stadium lights.
   Loaded after style.css and overrides it. Always dark: charcoal, electric blue, orange.
   --brand-2: electric blue (links, your picks, selections)  --accent: orange (main buttons, live, active tab) */
:root, :root[data-theme] {
  --bg: #08090D;
  --card: #11141B;
  --card-2: #181C25;
  --ink: #EEF2F8;
  --muted: #8F99AB;
  --line: #242A36;
  --choice-line: #394151;
  --brand: #06070A;
  --brand-2: #2E9BFF;
  --blue-hot: #19D3FF;
  --accent: #FF6A1A;
  --accent-hot: #FF8A3D;
  --on-brand: #FFFFFF;
  --on-brand-muted: #8F99AB;
  --gold: #FFC23D;
  --silver: #C9D3E0;
  --bronze: #D98A4E;
  --win: #3DE08C;
  --win-bg: #0E2A1C;
  --loss: #FF5470;
  --loss-bg: #2E1119;
  --push: #FFC23D;
  --push-bg: #2C2310;
  --sel: #0E2240;
  --pick: #10335C;
  --radius: 6px;
  --shadow: 0 1px 0 rgba(255, 255, 255, .04) inset, 0 10px 30px rgba(0, 0, 0, .45);
  --glow-blue: 0 0 0 1px rgba(46, 155, 255, .55), 0 0 22px rgba(46, 155, 255, .28);
  --glow-orange: 0 0 0 1px rgba(255, 106, 26, .6), 0 0 22px rgba(255, 106, 26, .3);
  --edge: linear-gradient(90deg, var(--brand-2), var(--blue-hot) 45%, var(--accent) 55%, var(--accent-hot));
  color-scheme: dark;
}

/* Stadium lights: two floodlight glows at the top, a faint diagonal "turf" texture */
body {
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 55% 38% at 8% -6%, rgba(120, 190, 255, .20), transparent 70%),
    radial-gradient(ellipse 55% 38% at 92% -6%, rgba(255, 150, 80, .16), transparent 70%),
    repeating-linear-gradient(115deg, rgba(255, 255, 255, .012) 0 2px, transparent 2px 14px);
  background-attachment: fixed;
}
a { color: var(--brand-2); }
a:hover { color: var(--blue-hot); }
::selection { background: var(--accent); color: #fff; }

/* Type: heavy, condensed, leaning forward */
h1, h2, h3, .brand-mark, .stat b, .lc-stats b, .pick-summary b, .team-abbr, .team-score, .rating-num, .price, .fee-box b, .upgrade-cta b, .hh-pts, .vs b, .rk-chip, .top-rank, .trophy .t-count, .records .rec-val { font-style: italic; }
h1 { font-size: 34px; font-weight: 900; letter-spacing: .5px; }
.card > h2, .card > h3:first-child, .page-head h2 { letter-spacing: .6px; }
.card > h2::before, .page-head h2::before { content: ""; display: inline-block; width: 6px; height: .8em; margin-right: 10px; background: var(--accent); transform: skewX(-16deg); vertical-align: -1px; }

/* ---------- Top bar ---------- */
.topbar { background: linear-gradient(180deg, #0C0E14, #06070A); border-bottom: 0; box-shadow: 0 8px 24px rgba(0, 0, 0, .55); }
.topbar::after { content: ""; position: absolute; left: 0; right: 0; bottom: -3px; height: 3px; background: var(--edge); box-shadow: 0 0 14px rgba(46, 155, 255, .45), 0 0 14px rgba(255, 106, 26, .35); }
.bm-a { background: var(--accent); color: #FFFFFF; text-shadow: 0 1px 0 rgba(0, 0, 0, .25); }
.bm-b { background: var(--brand-2); color: #06070A; }
.brand:hover .brand-mark { filter: drop-shadow(0 0 10px rgba(46, 155, 255, .45)); }
.topnav a { color: var(--on-brand-muted); text-transform: uppercase; letter-spacing: .8px; font-size: 13px; font-weight: 800; }
.topnav a:hover, .topnav a.on { background: linear-gradient(180deg, transparent, rgba(46, 155, 255, .14)); color: #FFFFFF; box-shadow: inset 0 -3px 0 var(--brand-2); }
.topnav a.dev { color: var(--gold); }
.avatar { background: linear-gradient(135deg, var(--brand-2), #1460B8); color: #fff; border: 2px solid rgba(255, 255, 255, .15); }
.usermenu-pop { background: #0F1218; border-color: var(--line); border-top: 2px solid var(--brand-2); border-radius: 6px; box-shadow: 0 18px 40px rgba(0, 0, 0, .6); }
.usermenu-pop a:hover { background: var(--sel); color: #fff; }

/* ---------- League bar ---------- */
.leaguebar { background:
    linear-gradient(100deg, rgba(46, 155, 255, .10), transparent 40%, transparent 60%, rgba(255, 106, 26, .08)),
    linear-gradient(180deg, #10131A, #0B0D12);
  border-bottom: 1px solid var(--line); }
.leaguebar-title h1 { font-size: 40px; text-shadow: 0 2px 18px rgba(46, 155, 255, .25); }
.sport-chip, .sport-chip[class*="sport-"] { background: var(--brand-2); color: #06070A; }
.mini-sport { background: var(--brand-2); color: #06070A; }
.tabs a { color: var(--muted); text-transform: uppercase; letter-spacing: .7px; font-size: 13px; }
.tabs a:hover { color: var(--ink); }
.tabs a.on { color: #fff; border-color: var(--accent); text-shadow: 0 0 12px rgba(255, 106, 26, .45); }
.subtabs a { background: var(--card); border-color: var(--line); border-radius: 4px; text-transform: uppercase; font-size: 13px; font-weight: 800; letter-spacing: .5px; }
.subtabs a.on { background: var(--brand-2); color: #06070A; border-color: var(--brand-2); box-shadow: var(--glow-blue); }

/* ---------- Cards ---------- */
.card, .stat, .league-card, .game, .pick-summary, .table-scroll, .disc-row, .hh-card, .savebar {
  background: linear-gradient(180deg, #141821, #0F1218); border-color: var(--line); border-radius: var(--radius); }
.card { position: relative; box-shadow: var(--shadow); }
.card::after { content: ""; position: absolute; left: -1px; top: -1px; width: 64px; height: 3px; background: var(--brand-2); transform: skewX(-30deg); transform-origin: left; border-radius: 0; pointer-events: none; }
.card.empty::after, .card.narrow::after { width: 96px; }
.danger-zone::after { background: var(--loss); }
.stat { position: relative; overflow: hidden; }
.stat::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--accent); }
.stat:nth-child(even)::before { background: var(--brand-2); }
.stat b { font-size: 34px; color: #fff; }
.stat span { text-transform: uppercase; letter-spacing: .8px; font-weight: 700; font-size: 11px; }

/* League tiles: angled color edge, lift and glow on hover */
.league-card { border-top: 0; position: relative; overflow: hidden; transition: transform .15s, box-shadow .15s, border-color .15s; }
.league-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--edge); }
.league-card:nth-child(3n+2)::before { background: linear-gradient(90deg, var(--accent), var(--accent-hot)); }
.league-card:nth-child(3n)::before { background: linear-gradient(90deg, var(--brand-2), var(--blue-hot)); }
.league-card:hover { transform: translateY(-3px); border-color: var(--brand-2); box-shadow: var(--glow-blue), var(--shadow); }
.league-card h3 { font-size: 26px; color: #fff; }
.lc-stats b { font-size: 26px; color: #fff; }
.lc-stats span { text-transform: uppercase; letter-spacing: .6px; font-weight: 700; font-size: 11px; }
.lc-due { border-radius: 4px; text-transform: uppercase; letter-spacing: .4px; font-size: 12px; font-weight: 800; }
.lc-due.due, .big.due { background: linear-gradient(90deg, rgba(255, 106, 26, .22), rgba(255, 106, 26, .06)); color: var(--accent-hot); border-left: 3px solid var(--accent); }
.lc-due.done, .big.done { background: linear-gradient(90deg, rgba(61, 224, 140, .16), rgba(61, 224, 140, .04)); color: var(--win); border-left: 3px solid var(--win); }
.lc-franchise { color: var(--accent-hot); }
.franchise-pill { background: var(--card-2); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 4px; }
.franchise-pill:hover { box-shadow: var(--glow-orange); }

/* ---------- Buttons ---------- */
.btn { background: linear-gradient(180deg, var(--accent-hot), var(--accent)); color: #fff; border: 0; border-radius: 0; padding: 11px 22px;
  clip-path: polygon(9px 0, 100% 0, calc(100% - 9px) 100%, 0 100%); text-transform: uppercase; letter-spacing: .7px; font-size: 14px; font-weight: 800; transition: filter .12s, transform .12s; }
.btn:hover { filter: brightness(1.12) saturate(1.1); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn-ghost { background: transparent; color: var(--ink); clip-path: none; border: 2px solid var(--choice-line); border-radius: 4px; }
.btn-ghost:hover { border-color: var(--brand-2); color: #fff; box-shadow: var(--glow-blue); filter: none; }
.btn-danger { background: linear-gradient(180deg, #FF6F86, var(--loss)); }
.btn-sm { padding: 7px 14px; font-size: 12px; }
.btn-link { color: var(--brand-2); }
.savebar { border-top: 0; box-shadow: 0 -10px 30px rgba(0, 0, 0, .55); background: rgba(12, 14, 19, .92); }
.savebar::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--edge); border-radius: var(--radius) var(--radius) 0 0; }

/* ---------- Forms ---------- */
input, select, textarea { background-color: #0B0D12; border-color: var(--choice-line); border-radius: 4px; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--brand-2); box-shadow: 0 0 16px rgba(46, 155, 255, .3); }
select { background-color: #0B0D12; border-radius: 4px; box-shadow: none; }
.choice { border-color: var(--choice-line); border-radius: 6px; background: rgba(255, 255, 255, .01); }
.choice:hover { border-color: var(--brand-2); }
.choice:has(input:checked) { border-color: var(--brand-2); background: var(--sel); box-shadow: var(--glow-blue); }
.switch input:checked + span { background: var(--brand-2); box-shadow: 0 0 12px rgba(46, 155, 255, .5); }
.sport-sec { background: var(--card-2); border-radius: 6px; }
.sport-sec > .choice-grid, .sport-sec > .mix-grid { background: var(--card); }
code { background: #0B0D12; color: var(--blue-hot); }

/* ---------- Alerts and banners ---------- */
.alert { border-radius: 4px; border-left-width: 4px; }
.alert-success { border-left-color: var(--win); }
.alert-error { border-left-color: var(--loss); }
.alert-info { background: var(--sel); border-color: rgba(46, 155, 255, .35); border-left-color: var(--brand-2); }
.pass-banner { background: linear-gradient(90deg, rgba(255, 194, 61, .16), rgba(255, 106, 26, .06) 60%, transparent); border: 1px solid rgba(255, 194, 61, .35); border-radius: 4px; }
.champion, .champion.surv-banner { background: linear-gradient(90deg, rgba(255, 194, 61, .22), transparent); color: var(--gold); border-left: 4px solid var(--gold); border-radius: 4px; font-weight: 700; }
.upgrade-card { background: linear-gradient(135deg, var(--card) 55%, rgba(255, 194, 61, .14)); border-color: var(--gold); }
.badge-gold { background: transparent; color: var(--gold); border: 1px solid rgba(255, 194, 61, .5); }
.badge-franchise { background: rgba(255, 106, 26, .14); color: var(--accent-hot); }
.badge-freeleague { background: var(--win-bg); color: var(--win); }
.bdg { background: rgba(255, 194, 61, .14); color: var(--gold); }
.sport-nba, .sport-ncaab, .sport-mlb, .sport-epl, .sport-laliga, .sport-bund, .sport-seriea, .sport-ligue1,
.sport-mls, .sport-ligamx, .sport-crc, .sport-hon, .sport-gua, .sport-bra, .sport-arg, .sport-uru, .sport-ecu, .sport-chile, .sport-ksa, .sport-jpn, .sport-chn, .sport-ind, .sport-rsa, .sport-aleague { background: var(--brand-2); color: #06070A; }
.sport-chip.sport-nba, .sport-chip.sport-ncaab, .sport-chip.sport-mlb { background: var(--accent); color: #fff; }

/* ---------- Picks: scoreboard strip and game tiles ---------- */
.pick-summary { position: relative; background: linear-gradient(100deg, #0E1A2E, #0B0D12 55%, #1E1009); border: 1px solid var(--line); overflow: hidden; }
.pick-summary::before { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--edge); }
.pick-summary b { font-size: 38px; text-shadow: 0 0 18px rgba(46, 155, 255, .35); }
.week-pick select { background-color: var(--card-2); color: #fff; border: 1px solid var(--brand-2); box-shadow: var(--glow-blue); }
.game { box-shadow: var(--shadow); transition: box-shadow .15s, transform .15s; }
.game.open:hover { box-shadow: 0 0 0 1px rgba(46, 155, 255, .35), var(--shadow); }
.game-meta { background: linear-gradient(90deg, #1A1F2A, #12151C); border-bottom-color: var(--line); color: var(--muted); }
.game-meta .lock { background: #262D3A; color: var(--ink); }
.game-meta .lock.soon { background: var(--gold); color: #1A1200; animation: arena-pulse 1.6s ease-in-out infinite; }
.game-meta .final { background: #2A3140; color: #fff; }
.game-meta .live { background: var(--accent); color: #fff; box-shadow: 0 0 14px rgba(255, 106, 26, .55); }
.game-meta .live::before { content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: #fff; vertical-align: 1px; animation: arena-blink 1s steps(2) infinite; }
.worth { background: var(--accent); }
.team { background: transparent; border-bottom-color: var(--line); transition: background .12s, box-shadow .12s; }
.team-abbr { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22), inset 0 -3px 0 rgba(0, 0, 0, .25); background-image: linear-gradient(180deg, rgba(255, 255, 255, .16), transparent 60%); }
.team-score { color: #fff; }
.game.open .team:hover { background: rgba(46, 155, 255, .07); }
.team.sel, .team:has(input:checked) { background: linear-gradient(90deg, rgba(46, 155, 255, .32), rgba(46, 155, 255, .08)); box-shadow: inset 5px 0 0 var(--brand-2), inset 0 0 0 1px rgba(46, 155, 255, .35); }
.game.open .team.sel:hover, .game.open .team:has(input:checked):hover { background: linear-gradient(90deg, rgba(46, 155, 255, .4), rgba(46, 155, 255, .12)); }
.team.sel .team-tick, .team:has(input:checked) .team-tick { background: var(--brand-2); border-color: var(--brand-2); color: #06070A; box-shadow: 0 0 12px rgba(46, 155, 255, .7); }
.team:has(input:checked) .team-tick { animation: arena-pop .25s ease-out; }
.game.res-win { border-color: var(--win); box-shadow: 0 0 0 1px var(--win), 0 0 20px rgba(61, 224, 140, .18); }
.game.res-loss, .game.res-none { border-color: rgba(255, 84, 112, .6); }
.game.joker { box-shadow: 0 0 0 2px var(--gold), 0 0 22px rgba(255, 194, 61, .3); }
.result { border-radius: 3px; text-transform: uppercase; letter-spacing: .5px; font-size: 12px; font-weight: 900; }
.conf-btn, .conf-btn:not(.empty) { background: linear-gradient(135deg, var(--brand-2), #1460B8); color: #fff; border-radius: 4px; box-shadow: 0 0 14px rgba(46, 155, 255, .35); }
.conf-btn .chev { border-color: #fff; }
.conf-btn.empty { background: transparent; color: var(--accent-hot); border-color: var(--accent); box-shadow: none; }
.conf-btn.empty .chev { border-color: var(--accent-hot); }
.conf-pop { background: #0F1218; border-top: 2px solid var(--brand-2); border-radius: 6px; box-shadow: 0 18px 40px rgba(0, 0, 0, .6); }
.conf-pop .chips button { background: #0B0D12; border-radius: 4px; }
.conf-pop .chips button.cur { color: #1A1200; }
.joker-tag:has(input:checked), .joker-tag.on { box-shadow: 0 0 14px rgba(255, 194, 61, .45); }

/* ---------- Standings and leaderboards ---------- */
.table-scroll { box-shadow: var(--shadow); }
th, .table-scroll thead th, .table-scroll thead .sticky { background: #0B0D12; color: var(--muted); letter-spacing: .8px; }
.table-scroll thead tr { box-shadow: inset 0 -2px 0 var(--brand-2); }
.sticky { background: #11141B; }
tbody tr:hover td { background: rgba(46, 155, 255, .06); }
tr.me td, tr.me .sticky { background: linear-gradient(90deg, rgba(46, 155, 255, .22), rgba(46, 155, 255, .10)); }
tr.me td:first-child { box-shadow: inset 4px 0 0 var(--brand-2); }
tr.me td { font-weight: 700; color: #fff; }
.standings td b { font-family: var(--display); font-size: 19px; font-style: italic; color: #fff; }
td.rk { width: 44px; }
.rk-chip { display: inline-grid; place-items: center; min-width: 30px; height: 26px; padding: 0 6px; font-family: var(--display); font-weight: 900; font-size: 16px; line-height: 1;
  color: var(--ink); background: #232937; clip-path: polygon(5px 0, 100% 0, calc(100% - 5px) 100%, 0 100%); }
.rk-chip.rk-1 { background: linear-gradient(180deg, #FFD978, var(--gold)); color: #1A1200; }
.rk-chip.rk-2 { background: linear-gradient(180deg, #EEF3F9, var(--silver)); color: #10141B; }
.rk-chip.rk-3 { background: linear-gradient(180deg, #F0A974, var(--bronze)); color: #1A0D04; }
.standings td.wk-won, .field-teams tr.won td { background: rgba(61, 224, 140, .14); color: var(--win); }
.standings td.wk-lost { background: rgba(255, 84, 112, .14); }
.tier-table tr.zone-up td, .tier-table tr.zone-up .sticky { background: rgba(46, 155, 255, .14); }
.tier-table tr.zone-down td, .tier-table tr.zone-down .sticky { background: rgba(255, 84, 112, .12); }
.zone-key.up::before { background: rgba(46, 155, 255, .4); }
.zone-key.down::before { background: rgba(255, 84, 112, .4); }
.tier-num { background: var(--accent); }
tr.cutline td { border-bottom-color: var(--gold); }
.mini-standings li { align-items: center; padding: 7px 8px; border-radius: 4px; border-bottom: 1px solid rgba(255, 255, 255, .04); }
.mini-standings li > span { display: flex; align-items: center; gap: 10px; min-width: 0; }
.mini-standings li b { font-family: var(--display); font-style: italic; font-size: 19px; color: #fff; }
.mini-standings li.me { background: linear-gradient(90deg, rgba(46, 155, 255, .24), transparent); box-shadow: inset 3px 0 0 var(--brand-2); }
.top-list li.me { background: linear-gradient(90deg, rgba(46, 155, 255, .24), transparent); border-radius: 4px; }
.top-rank { background: #232937; border-radius: 0; clip-path: polygon(5px 0, 100% 0, calc(100% - 5px) 100%, 0 100%); }
.top-list li:nth-child(1) .top-rank { background: var(--gold); color: #1A1200; }
.top-list li:nth-child(2) .top-rank { background: var(--silver); color: #10141B; }
.top-list li:nth-child(3) .top-rank { background: var(--bronze); color: #1A0D04; }
.vs b { color: #fff; text-shadow: 0 0 18px rgba(46, 155, 255, .35); }
.hh-card.mine { border-color: var(--brand-2); box-shadow: var(--glow-blue); }
.hh-side.won { background: rgba(61, 224, 140, .12); }

/* ---------- Trophies, rating, chat ---------- */
.rating-card { background: radial-gradient(circle at 85% 0%, rgba(255, 106, 26, .35), transparent 55%), linear-gradient(160deg, #10284A, #0A0C11); border: 1px solid rgba(46, 155, 255, .35); }
.rating-num { text-shadow: 0 0 24px rgba(46, 155, 255, .55); }
.trophy { border-radius: 6px; border-color: var(--choice-line); }
.trophy.got { position: relative; overflow: hidden; border-color: var(--gold); background: linear-gradient(135deg, rgba(255, 194, 61, .16), transparent 60%); }
.trophy.got::after { content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 40%; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .14), transparent); transform: skewX(-20deg); animation: arena-shine 4.5s ease-in-out infinite; pointer-events: none; }
.trophy .t-count { color: var(--gold); }
.msg-body { background: var(--card-2); border-radius: 2px 10px 10px 10px; }
.msg.mine .msg-body { background: var(--sel); box-shadow: inset 3px 0 0 var(--brand-2); }
.react { background: var(--card-2); }
.react.on { box-shadow: 0 0 10px rgba(46, 155, 255, .35); }
.info-dialog { background: var(--bg); border-top: 3px solid var(--brand-2); border-radius: 6px; }
.info-foot { background: var(--card); }
.info-btn { background: transparent; border-color: var(--choice-line); }
.back-link { background: var(--sel); border-radius: 4px; }
.plan { border-radius: 6px; }

/* ---------- Footer ---------- */
.site-foot { border-top: 0; position: relative; background: #06070A; }
.site-foot::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--edge); opacity: .7; }

/* ---------- Signed-out pages: a night stadium ---------- */
.auth-body { background-color: #06070A; background-image:
    radial-gradient(ellipse 40% 50% at 12% 0%, rgba(140, 200, 255, .32), transparent 70%),
    radial-gradient(ellipse 40% 50% at 88% 0%, rgba(255, 160, 90, .26), transparent 70%),
    linear-gradient(115deg, transparent 0 46%, rgba(46, 155, 255, .10) 46% 52%, transparent 52% 56%, rgba(255, 106, 26, .10) 56% 62%, transparent 62%),
    radial-gradient(ellipse 90% 40% at 50% 110%, rgba(46, 155, 255, .16), transparent 70%); }
.auth-card { background: linear-gradient(180deg, #151922, #0F1218); border: 1px solid var(--line); border-top: 0; border-radius: 6px; position: relative; box-shadow: 0 30px 80px rgba(0, 0, 0, .7), 0 0 60px rgba(46, 155, 255, .10); }
.auth-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--edge); border-radius: 6px 6px 0 0; }
.legal-body .legal-top { background: #06070A; }

/* ---------- Motion: standings slide in, numbers count up (app.js), live badges pulse ---------- */
@keyframes arena-row { from { opacity: 0; transform: translateX(-18px); } }
@keyframes arena-rise { from { opacity: 0; transform: translateY(12px); } }
@keyframes arena-pulse { 50% { filter: brightness(1.25); box-shadow: 0 0 14px rgba(255, 194, 61, .6); } }
@keyframes arena-blink { 50% { opacity: .2; } }
@keyframes arena-pop { 0% { transform: scale(.4); } 70% { transform: scale(1.2); } 100% { transform: scale(1); } }
@keyframes arena-shine { 0%, 60% { left: -60%; } 100% { left: 130%; } }
.standings tbody tr, .mini-standings li, .top-list li, .ladder li { animation: arena-row .45s cubic-bezier(.2, .8, .2, 1) backwards; animation-delay: calc(var(--i, 0) * 45ms); }
.league-card, .stat, .game, .trophy { animation: arena-rise .4s ease-out backwards; animation-delay: calc(var(--i, 0) * 40ms); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

@media (max-width: 760px) {
  h1 { font-size: 28px; }
  .leaguebar-title h1 { font-size: 30px; }
  .pick-summary b { font-size: 30px; }
}

/* ---------- User menu + profile picture (Update 31) ---------- */
.userbox { display: flex; align-items: center; gap: 4px; position: relative; }
.avatar-btn { background: none; border: 0; padding: 0; cursor: pointer; border-radius: 50%; display: grid; }
.avatar-btn:hover .avatar, .avatar-btn:focus-visible .avatar { box-shadow: 0 0 0 2px var(--brand-2), 0 0 14px rgba(46, 155, 255, .6); }
.avatar-btn:focus-visible { outline: none; }
.avatar { overflow: hidden; flex: none; }
.avatar.has-img { padding: 0; background: #11141B; }
.avatar.has-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.usermenu { align-self: stretch; }
.usermenu summary { height: 100%; padding: 0 4px 0 8px; gap: 8px; }
.usermenu summary .chev { width: 8px; height: 8px; border-right: 2px solid var(--on-brand-muted); border-bottom: 2px solid var(--on-brand-muted); transform: rotate(45deg) translateY(-3px); transition: transform .15s; }
.usermenu[open] summary .chev { transform: rotate(225deg) translate(-2px, -1px); }
.usermenu summary:hover .uname, .usermenu[open] .uname { color: #fff; }
.usermenu-pop { top: calc(100% + 10px); right: 0; z-index: 40; min-width: 220px; animation: arena-rise .16s ease-out; }
.usermenu-pop a[href="logout.php"] { border-top: 1px solid var(--line); margin-top: 4px; border-radius: 0 0 4px 4px; }
.usermenu-pop a[href="profile.php"] { border-top: 1px solid var(--line); margin-top: 4px; }

.photo-dialog { width: min(420px, calc(100vw - 24px)); padding: 0; border: 1px solid var(--line); border-radius: 8px; background: linear-gradient(180deg, #151922, #0F1218); color: var(--ink); box-shadow: 0 30px 80px rgba(0, 0, 0, .7), 0 0 50px rgba(46, 155, 255, .12); overflow: hidden; }
.photo-dialog::before { content: ""; display: block; height: 4px; background: var(--edge); }
.photo-dialog::backdrop { background: rgba(3, 4, 7, .75); backdrop-filter: blur(3px); }
.photo-form { padding: 14px 20px 18px; }
.photo-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.photo-head h2 { margin: 0; font-size: 22px; text-transform: uppercase; }
.photo-x { background: none; border: 0; color: var(--muted); font-size: 28px; line-height: 1; cursor: pointer; padding: 0 4px; }
.photo-x:hover { color: #fff; }
.photo-stage { display: grid; place-items: center; margin: 10px 0 6px; }
.avatar.avatar-xl { width: 200px; height: 200px; font-size: 84px; border-width: 3px; box-shadow: 0 0 0 3px rgba(46, 155, 255, .45), 0 0 40px rgba(46, 155, 255, .25); }
.photo-video { width: 240px; height: 240px; border-radius: 50%; object-fit: cover; transform: scaleX(-1); background: #000; box-shadow: 0 0 0 3px var(--accent), 0 0 40px rgba(255, 106, 26, .3); }
.photo-video[hidden], .photo-preview[hidden] { display: none; }
.photo-msg { min-height: 20px; text-align: center; margin: 6px 0; color: var(--muted); }
.photo-msg.bad { color: var(--loss); }
.photo-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.photo-actions[hidden] { display: none; }
.photo-actions .btn { flex: 1 1 150px; }
.photo-actions label.btn { cursor: pointer; }
.photo-actions label.btn:focus-within { box-shadow: var(--glow-blue); }
.photo-foot { margin: 14px 0 0; text-align: center; }
.photo-foot .btn-link { margin-left: 6px; }
@media (max-width: 760px) {
  .uname { display: none; }
  .usermenu summary { padding: 0 8px; }
}
.topnav a, .uname { white-space: nowrap; }
@media (max-width: 980px) {
  .uname { display: none; }
  .topnav a { padding: 0 10px; }
}
@media (max-width: 900px) {
  .topbar-inner { gap: 10px; }
  .topnav a { padding: 0 8px; letter-spacing: .3px; font-size: 12px; }
}

/* ---------- Dropdowns (Update 31): the closed box, and the styled list app.js opens on computers ---------- */
select, .week-pick select {
  -webkit-appearance: none; appearance: none; cursor: pointer;
  background-color: #0B0D12;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%232E9BFF' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"),
    linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, 0));
  background-repeat: no-repeat, no-repeat; background-position: right 14px center, 0 0; background-size: 12px 8px, 100% 100%;
  border: 2px solid var(--choice-line); border-radius: 4px; padding: 9px 40px 9px 14px;
  color: var(--ink); font-weight: 700; box-shadow: none; transition: border-color .12s, box-shadow .12s;
}
select:hover { border-color: var(--brand-2); }
select:focus, select:focus-visible, select.xsel-open { outline: none; border-color: var(--brand-2); box-shadow: 0 0 0 1px var(--brand-2), 0 0 18px rgba(46, 155, 255, .3); }
select.xsel-open { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 6.5l5-5 5 5' fill='none' stroke='%23FF6A1A' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"), linear-gradient(180deg, rgba(46, 155, 255, .10), rgba(46, 155, 255, 0)); }
select:disabled { opacity: .5; cursor: not-allowed; }
select option, select optgroup { background: #11141B; color: var(--ink); }   /* phones and the no-script fallback */
.week-pick select { color: #fff; font-family: var(--display); font-style: italic; font-size: 18px; letter-spacing: .5px; text-transform: uppercase; border-color: var(--brand-2); box-shadow: var(--glow-blue); background-position: right 16px center, 0 0; }
.menu-lang select, .lang-switch select { padding-top: 6px; padding-bottom: 6px; }

.xsel-list { position: fixed; z-index: 1000; margin: 0; padding: 6px; list-style: none; overflow-y: auto; overscroll-behavior: contain;
  background: linear-gradient(180deg, #161A23, #0F1218); border: 1px solid var(--line); border-radius: 6px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, .65), 0 0 0 1px rgba(46, 155, 255, .12); color: var(--ink);
  font: 600 14px/1.3 Inter, system-ui, sans-serif; animation: xsel-in .14s ease-out; }
.xsel-list::before { content: ""; position: sticky; top: -6px; display: block; height: 3px; margin: -6px -6px 6px; background: var(--edge); }
.xsel-list.up { animation-name: xsel-in-up; }
.xsel-list.up::before { display: none; }
.xsel-list.up { border-bottom: 3px solid var(--brand-2); }
.xsel-opt { position: relative; padding: 9px 34px 9px 12px; border-radius: 4px; cursor: pointer; white-space: nowrap; }
.xsel-opt.on { background: linear-gradient(90deg, rgba(46, 155, 255, .26), rgba(46, 155, 255, .08)); color: #fff; box-shadow: inset 3px 0 0 var(--accent); }
.xsel-opt.cur { color: #fff; font-weight: 800; }
.xsel-opt.cur::after { content: ""; position: absolute; right: 12px; top: 50%; width: 6px; height: 11px; margin-top: -7px; border: solid var(--brand-2); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.xsel-opt.off { opacity: .4; cursor: not-allowed; }
.xsel-group { padding: 10px 12px 4px; font-size: 11px; font-weight: 800; letter-spacing: .9px; text-transform: uppercase; color: var(--muted); }
.xsel-group:first-of-type { padding-top: 4px; }
@keyframes xsel-in { from { opacity: 0; transform: translateY(-6px); } }
@keyframes xsel-in-up { from { opacity: 0; transform: translateY(6px); } }

/* ---------- Scroll bars (Update 31): one look for all of them, up-down and sideways ---------- */
::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: #0B0D12; }
::-webkit-scrollbar-thumb { background: #394151; border-radius: 10px; border: 3px solid #0B0D12; min-height: 40px; min-width: 40px; }
::-webkit-scrollbar-thumb:hover { background: var(--brand-2); }
::-webkit-scrollbar-thumb:active { background: var(--accent); }
::-webkit-scrollbar-button { display: none; width: 0; height: 0; }
::-webkit-scrollbar-corner { background: #0B0D12; }
/* Inside tables and lists the track takes the panel's own color */
.table-scroll::-webkit-scrollbar-track, .table-scroll::-webkit-scrollbar-corner { background: #0F1218; }
.table-scroll::-webkit-scrollbar-thumb { border-color: #0F1218; }
.xsel-list::-webkit-scrollbar, .field-list::-webkit-scrollbar, .info-body::-webkit-scrollbar { width: 10px; height: 10px; }
.xsel-list::-webkit-scrollbar-track, .info-body::-webkit-scrollbar-track { background: transparent; }
.xsel-list::-webkit-scrollbar-thumb { border-color: #12151C; }
/* Firefox has no pseudo-elements for this, so it gets the colors only */
@supports not selector(::-webkit-scrollbar) {
  html, .table-scroll, .xsel-list, .field-list, .info-body { scrollbar-color: #394151 #0B0D12; }
  .xsel-list, .field-list { scrollbar-width: thin; }
}
