:root {
  --ink: #0b0c0c;
  --panel: #121414;
  --panel-2: #171a19;
  --line: #2b302e;
  --muted: #929c97;
  --paper: #eef1ec;
  --acid: #ccff3d;
  --mint: #60ffd6;
  --danger: #ff816b;
  --shadow: 0 30px 90px rgba(0,0,0,.38);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--paper); background: var(--ink); font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", "Microsoft YaHei", sans-serif; min-width: 320px; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
.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; }
.hidden { display: none !important; }
.noise { position: fixed; inset: 0; pointer-events: none; z-index: 20; opacity: .03; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E"); }

.site-header { width: min(1420px, calc(100% - 56px)); height: 88px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); position: relative; z-index: 3; }
.brand { display: inline-flex; align-items: center; gap: 12px; letter-spacing: .08em; }
.brand-mark { width: 38px; height: 38px; display: grid; place-items: center; color: var(--ink); background: var(--acid); font-weight: 950; font-size: 22px; transform: skew(-8deg); }
.brand > span:last-child { display: grid; line-height: 1; gap: 4px; }
.brand b { font-size: 15px; }
.brand small { color: var(--muted); font-size: 8px; letter-spacing: .23em; }
nav { display: flex; align-items: center; gap: 42px; font-size: 13px; color: #b8c0bc; }
nav a { transition: color .2s; }
nav a:hover { color: var(--acid); }
.season-pill { border: 1px solid var(--line); border-radius: 999px; padding: 9px 14px; font-size: 11px; letter-spacing: .08em; color: #bac2be; }
.season-pill i, .live-indicator i { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--acid); box-shadow: 0 0 14px var(--acid); margin-right: 7px; }
.header-actions { display: flex; align-items: center; gap: 18px; }
.signout-button { border: 1px solid #4a534d; background: transparent; color: var(--paper); padding: 9px 13px; cursor: pointer; font-size: 11px; }
.signout-button:hover { border-color: var(--acid); color: var(--acid); }

.auth-section { width: min(1280px, calc(100% - 56px)); min-height: calc(100vh - 230px); margin: 0 auto; display: grid; grid-template-columns: 1fr minmax(360px, 440px); align-items: center; gap: 8vw; padding: 80px 0 110px; }
.auth-intro h1 { font-size: clamp(54px, 6vw, 88px); line-height: 1.02; letter-spacing: -.065em; margin: 0; }
.auth-intro h1 em { color: transparent; -webkit-text-stroke: 1px var(--acid); font-style: normal; }
.auth-intro > p:not(.eyebrow) { color: #aeb6b2; line-height: 1.9; max-width: 560px; font-size: 14px; margin: 30px 0 35px; }
.auth-facts { display: flex; flex-wrap: wrap; gap: 9px; }
.auth-facts span { border: 1px solid #343c36; color: #9fa9a3; font-size: 10px; padding: 8px 10px; }
.auth-card { background: #111412; border: 1px solid #353d37; box-shadow: var(--shadow); }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--line); }
.auth-tab { height: 58px; background: transparent; color: #828c86; border: 0; cursor: pointer; font-size: 13px; font-weight: 750; }
.auth-tab.active { color: var(--acid); box-shadow: inset 0 -2px var(--acid); }
.auth-card form { display: grid; padding: 32px; }
.auth-caption { color: var(--muted); font-size: 12px; margin: 0 0 20px; }
.auth-card label { color: #b2bab5; font-size: 11px; margin: 0 0 9px; }
.auth-card input { height: 49px; width: 100%; background: #0a0d0b; border: 1px solid #3a433c; color: var(--paper); outline: none; padding: 0 13px; margin: 0 0 19px; }
.auth-card input:focus { border-color: var(--acid); }
.auth-card input::placeholder { color: #636d65; }
.register-fields { display: grid; }
.code-row { display: flex; gap: 8px; }
.code-row input { min-width: 0; flex: 1; }
.code-row button { height: 49px; white-space: nowrap; background: #232c24; border: 1px solid #4f6250; color: var(--acid); padding: 0 12px; cursor: pointer; font-size: 11px; }
.code-row button:disabled { opacity: .45; cursor: default; }
.auth-submit { height: 52px; margin-top: 5px; padding: 0 18px; display: flex; align-items: center; justify-content: space-between; border: 0; background: var(--acid); color: var(--ink); font-weight: 850; cursor: pointer; }
.auth-submit:disabled { opacity: .55; cursor: progress; }
.auth-submit span { font-size: 19px; }
.auth-message { min-height: 18px; margin: 17px 0 0; color: #a9b3ab; font-size: 11px; line-height: 1.6; }
.auth-message.error { color: var(--danger); }
.auth-message.success { color: var(--acid); }
.auth-footnote { margin: 0; border-top: 1px solid var(--line); padding: 17px 32px; font-size: 10px; color: #77817a; }

main { overflow: hidden; }
.hero { width: min(1420px, calc(100% - 56px)); min-height: 660px; margin: 0 auto; display: grid; grid-template-columns: 1.08fr .92fr; align-items: center; border-bottom: 1px solid var(--line); position: relative; }
.hero::before { content: "ARENA / 27"; position: absolute; left: -3px; bottom: 14px; font-size: 10px; color: #59605c; letter-spacing: .25em; writing-mode: vertical-rl; transform: rotate(180deg); }
.hero-copy { padding: 70px 4vw 90px 5vw; position: relative; z-index: 2; }
.eyebrow { color: var(--acid); letter-spacing: .22em; font-weight: 750; font-size: 11px; margin: 0 0 22px; }
.hero h1 { font-size: clamp(48px, 6.4vw, 96px); line-height: .98; letter-spacing: -.065em; margin: 0; max-width: 800px; }
.hero h1 em { color: transparent; -webkit-text-stroke: 1px var(--acid); font-style: normal; }
.hero-sub { color: #aeb6b2; line-height: 1.85; font-size: 15px; max-width: 610px; margin: 30px 0 36px; }
.primary-cta { display: inline-flex; gap: 38px; align-items: center; justify-content: space-between; background: var(--acid); color: var(--ink); padding: 17px 20px 17px 22px; min-width: 224px; font-weight: 800; font-size: 14px; transition: transform .2s, box-shadow .2s; }
.primary-cta:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(204,255,61,.14); }
.primary-cta span { font-size: 21px; }

.hero-visual { height: 560px; position: relative; display: grid; place-items: center; background: radial-gradient(circle, rgba(96,255,214,.08), transparent 58%); }
.hero-visual::before, .hero-visual::after { content: ""; position: absolute; background: var(--line); }
.hero-visual::before { width: 1px; height: 100%; left: 50%; }
.hero-visual::after { height: 1px; width: 100%; top: 50%; }
.orbit { position: absolute; border: 1px solid #202522; border-radius: 50%; }
.orbit-a { width: 510px; height: 510px; }
.orbit-b { width: 380px; height: 380px; border-style: dashed; animation: spin 35s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.hero-radar { width: min(440px, 80%); position: relative; z-index: 1; filter: drop-shadow(0 20px 50px rgba(0,0,0,.3)); }
.hero-radar svg { width: 100%; overflow: visible; }
.grid polygon, .grid path { fill: none; stroke: #46504a; stroke-width: 1; }
.hero-shape { fill: rgba(204,255,61,.13); stroke: var(--acid); stroke-width: 2; animation: breathe 4s ease-in-out infinite; transform-origin: center; }
@keyframes breathe { 50% { transform: scale(.96); opacity: .82; } }
.dots circle { fill: var(--acid); filter: drop-shadow(0 0 7px var(--acid)); }
.score-badge { position: absolute; right: -20px; top: 38%; background: rgba(11,12,12,.9); backdrop-filter: blur(10px); border: 1px solid #3c433f; padding: 17px 19px; display: grid; gap: 2px; min-width: 125px; }
.score-badge small { color: var(--muted); font-size: 10px; }
.score-badge strong { font-size: 25px; letter-spacing: -.04em; }
.score-badge span { color: var(--acid); font-size: 9px; letter-spacing: .14em; }

.stats-strip { width: min(1420px, calc(100% - 56px)); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--line); }
.stats-strip > div { padding: 32px 5vw; display: flex; align-items: center; gap: 20px; border-right: 1px solid var(--line); }
.stats-strip > div:last-child { border-right: 0; }
.stats-strip > div > span { color: var(--acid); font-size: 30px; font-weight: 300; font-variant-numeric: tabular-nums; }
.stats-strip p { margin: 0; display: grid; gap: 7px; }
.stats-strip b { font-size: 13px; }
.stats-strip small { color: var(--muted); font-size: 11px; }

.leaderboard-section { width: min(1280px, calc(100% - 56px)); margin: 0 auto; padding: 130px 0; }
.section-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 42px; }
.section-heading .eyebrow { margin-bottom: 14px; }
.section-heading h2, .account-copy h2 { font-size: clamp(38px, 4.5vw, 68px); letter-spacing: -.055em; margin: 0; }
.live-indicator { color: #a8b0ac; font-size: 11px; background: #121413; border: 1px solid var(--line); padding: 10px 14px; border-radius: 99px; }
.live-indicator.limited i { background: #ffc857; box-shadow: 0 0 14px #ffc857; }
.live-indicator.error i { background: var(--danger); box-shadow: 0 0 14px var(--danger); }

.board-shell { border: 1px solid var(--line); background: #0f1110; box-shadow: var(--shadow); }
.board-toolbar { display: flex; justify-content: space-between; align-items: center; padding: 18px; border-bottom: 1px solid var(--line); }
.tabs { display: flex; background: #171918; padding: 4px; }
.tab { color: #9fa8a4; background: transparent; border: 0; padding: 12px 18px; cursor: pointer; font-weight: 750; font-size: 13px; transition: background .2s, color .2s; }
.tab small { font-size: 8px; letter-spacing: .12em; margin-left: 7px; opacity: .6; }
.tab.active { background: var(--paper); color: var(--ink); }
.search-box { width: min(270px, 35vw); display: flex; align-items: center; gap: 8px; border-bottom: 1px solid #3b413e; padding: 8px 3px; }
.search-box span { color: var(--acid); font-size: 20px; }
.search-box input { width: 100%; border: 0; outline: 0; color: var(--paper); background: transparent; font-size: 12px; }
.search-box input::placeholder { color: #68706c; }
.board-summary { display: flex; justify-content: space-between; gap: 20px; padding: 18px 24px; color: var(--muted); font-size: 11px; border-bottom: 1px solid var(--line); }
.board-summary p { margin: 0; }
.board-summary span, .board-summary b { color: var(--paper); }
.table-wrap { position: relative; min-height: 290px; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 860px; }
th { color: #747d78; font-size: 9px; letter-spacing: .12em; text-transform: uppercase; text-align: left; font-weight: 650; padding: 14px 20px; border-bottom: 1px solid #242825; }
td { padding: 19px 20px; border-bottom: 1px solid #222624; font-size: 12px; color: #bac1bd; font-variant-numeric: tabular-nums; }
tbody tr { cursor: pointer; transition: background .18s, transform .18s; }
tbody tr:hover { background: #171b18; }
tbody tr:focus-visible { outline: 2px solid var(--acid); outline-offset: -2px; }
.rank { color: var(--paper); font-weight: 850; font-size: 14px; }
.rank.top { color: var(--acid); }
.player-cell { display: flex; align-items: center; gap: 11px; color: var(--paper); font-weight: 720; }
.avatar { width: 32px; height: 32px; display: grid; place-items: center; background: linear-gradient(135deg, #2c3731, #141715); color: var(--acid); border: 1px solid #3b443f; font-size: 11px; }
.mode-chip { display: inline-flex; padding: 5px 8px; border: 1px solid #374039; color: #aeb7b2; font-size: 10px; }
.score { color: var(--acid); font-size: 15px; font-weight: 850; }
.open-profile { width: 29px; height: 29px; border: 1px solid #39403c; display: grid; place-items: center; color: var(--acid); transition: background .2s, color .2s; }
tr:hover .open-profile { background: var(--acid); color: var(--ink); }
.loading-state, .empty-state { min-height: 260px; display: grid; place-content: center; justify-items: center; color: var(--muted); gap: 12px; }
.loading-state span { width: 25px; height: 25px; border: 2px solid #343a36; border-top-color: var(--acid); border-radius: 50%; animation: spin 1s linear infinite; }
.loading-state p, .empty-state p { margin: 0; font-size: 12px; }
.empty-state b { color: var(--paper); }
.empty-state button { margin-top: 8px; padding: 9px 15px; border: 1px solid var(--acid); background: transparent; color: var(--acid); cursor: pointer; }
.pagination { min-height: 64px; display: flex; justify-content: center; align-items: center; gap: 7px; padding: 14px; }
.pagination button { min-width: 34px; height: 34px; border: 1px solid #303632; background: transparent; color: #919a95; cursor: pointer; }
.pagination button.active, .pagination button:hover:not(:disabled) { background: var(--acid); color: var(--ink); border-color: var(--acid); }
.pagination button:disabled { opacity: .3; cursor: not-allowed; }

.account-section { width: min(1420px, calc(100% - 56px)); margin: 0 auto 100px; display: grid; grid-template-columns: .9fr 1.1fr; border: 1px solid var(--line); background: linear-gradient(135deg, #121513 0%, #0d0f0e 70%); }
.account-copy { padding: 80px 7vw; border-right: 1px solid var(--line); }
.account-copy > p:not(.eyebrow) { color: var(--muted); max-width: 520px; line-height: 1.9; font-size: 13px; }
.privacy-note { display: flex; align-items: center; gap: 14px; margin-top: 34px; padding-top: 28px; border-top: 1px solid var(--line); }
.privacy-note > span { width: 35px; height: 35px; border: 1px solid #3b443f; display: grid; place-items: center; color: var(--acid); }
.privacy-note p { display: grid; gap: 5px; margin: 0; }
.privacy-note b { font-size: 12px; }
.privacy-note small { color: var(--muted); font-size: 10px; }
.lookup-card { padding: 80px 7vw; display: grid; align-content: center; }
.lookup-card form label { display: block; color: #aab2ae; font-size: 11px; letter-spacing: .08em; margin-bottom: 11px; }
.lookup-input-row { display: flex; }
.lookup-input-row input { min-width: 0; flex: 1; height: 58px; background: #0b0d0c; color: var(--paper); border: 1px solid #39413d; border-right: 0; padding: 0 18px; outline: none; }
.lookup-input-row input:focus { border-color: var(--acid); }
.lookup-input-row button { height: 58px; border: 0; background: var(--acid); color: var(--ink); font-weight: 850; padding: 0 21px; cursor: pointer; }
.lookup-input-row button span { margin-left: 14px; }
.form-help { color: #6f7873; font-size: 10px; }
.lookup-result { margin-top: 26px; border-top: 1px solid var(--line); padding-top: 24px; animation: rise .35s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
.lookup-result.success { display: grid; grid-template-columns: 52px 1fr; gap: 16px; align-items: center; }
.result-avatar { width: 52px; height: 52px; display: grid; place-items: center; color: var(--ink); background: var(--mint); font-weight: 900; font-size: 18px; }
.result-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.result-field { border-left: 1px solid #3a413d; padding-left: 14px; display: grid; gap: 4px; }
.result-field small { color: var(--muted); font-size: 9px; letter-spacing: .12em; }
.result-field b { font-size: 14px; overflow-wrap: anywhere; }
.lookup-result.message { color: #aab2ae; font-size: 12px; line-height: 1.7; }
.lookup-result.message b { color: var(--danger); display: block; margin-bottom: 4px; }

footer { width: min(1420px, calc(100% - 56px)); margin: 0 auto; min-height: 140px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; color: #646c68; font-size: 10px; }
.footer-brand { opacity: .7; }

.player-dialog { width: min(1050px, calc(100% - 36px)); max-height: calc(100vh - 40px); color: var(--paper); background: #0e100f; border: 1px solid #363e3a; padding: 0; box-shadow: 0 35px 120px rgba(0,0,0,.75); overflow: auto; }
.player-dialog::backdrop { background: rgba(2,4,3,.82); backdrop-filter: blur(8px); }
.dialog-close { position: absolute; right: 22px; top: 20px; width: 38px; height: 38px; border-radius: 50%; border: 1px solid #3a423e; color: #b8c0bc; background: transparent; font-size: 25px; cursor: pointer; z-index: 2; }
.dialog-close:hover { color: var(--ink); background: var(--acid); border-color: var(--acid); }
.dialog-head { padding: 46px 50px 28px; border-bottom: 1px solid var(--line); }
.dialog-head .eyebrow { margin-bottom: 13px; }
.dialog-head h2 { margin: 0; font-size: 40px; letter-spacing: -.04em; }
.player-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.player-meta span { padding: 6px 9px; background: #181b19; border: 1px solid #2f3632; color: #a9b1ad; font-size: 9px; letter-spacing: .08em; }
.player-meta span:last-child { color: var(--acid); }
.profile-grid { display: grid; grid-template-columns: 1fr 1fr; }
.radar-card, .history-card { padding: 32px 38px 42px; min-height: 470px; }
.radar-card { border-right: 1px solid var(--line); }
.card-title { display: flex; justify-content: space-between; align-items: center; }
.card-title h3 { margin: 0; font-size: 14px; }
.card-title span { color: var(--muted); font-size: 9px; }
.radar-chart { min-height: 360px; display: grid; place-items: center; }
.radar-chart svg { width: min(360px, 100%); overflow: visible; }
.radar-label { fill: #aeb6b1; font-size: 10px; }
.radar-value { fill: var(--acid); font-size: 8px; font-weight: 800; }
.history-list { margin-top: 24px; display: grid; gap: 8px; max-height: 370px; overflow: auto; padding-right: 6px; }
.history-item { border: 1px solid #2c322f; padding: 14px; display: grid; grid-template-columns: 1fr auto; gap: 7px 14px; }
.history-item.best { border-color: #69773b; background: rgba(204,255,61,.035); }
.history-item strong { font-size: 14px; }
.history-item .history-score { color: var(--acid); font-size: 14px; font-weight: 850; }
.history-item small { color: var(--muted); font-size: 9px; }
.history-item .history-stats { color: #aeb6b2; font-size: 10px; grid-column: 1 / -1; }
.history-note { color: var(--muted); font-size: 11px; line-height: 1.7; border: 1px dashed #39403c; padding: 14px; }

@media (max-width: 900px) {
  .site-header { width: calc(100% - 32px); }
  .auth-section { width: calc(100% - 32px); grid-template-columns: 1fr; gap: 48px; }
  .auth-intro { max-width: 680px; }
  .auth-card { max-width: 520px; width: 100%; }
  nav { display: none; }
  .hero { width: calc(100% - 32px); grid-template-columns: 1fr; padding-top: 40px; }
  .hero-copy { padding: 40px 16px 20px; }
  .hero-visual { height: 440px; }
  .stats-strip { width: calc(100% - 32px); }
  .stats-strip > div { padding: 26px 20px; }
  .leaderboard-section { width: calc(100% - 32px); padding: 90px 0; }
  .account-section { width: calc(100% - 32px); grid-template-columns: 1fr; }
  .account-copy { border-right: 0; border-bottom: 1px solid var(--line); }
  .profile-grid { grid-template-columns: 1fr; }
  .radar-card { border-right: 0; border-bottom: 1px solid var(--line); }
  footer { width: calc(100% - 32px); }
}
@media (max-width: 620px) {
  .site-header { height: 74px; }
  .season-pill { display: none; }
  .auth-section { padding: 60px 0 80px; }
  .auth-intro h1 { font-size: 54px; }
  .auth-card form { padding: 25px; }
  .auth-footnote { padding: 17px 25px; }
  .hero { min-height: auto; }
  .hero h1 { font-size: 48px; }
  .hero-sub { font-size: 13px; }
  .hero-visual { height: 360px; }
  .orbit-a { width: 340px; height: 340px; }
  .orbit-b { width: 270px; height: 270px; }
  .score-badge { right: -6px; }
  .stats-strip { grid-template-columns: 1fr; }
  .stats-strip > div { border-right: 0; border-bottom: 1px solid var(--line); }
  .stats-strip > div:last-child { border-bottom: 0; }
  .section-heading { align-items: start; gap: 18px; flex-direction: column; }
  .board-toolbar { align-items: stretch; flex-direction: column; gap: 16px; }
  .tabs { width: 100%; }
  .tab { flex: 1; padding: 12px 8px; }
  .tab small { display: none; }
  .search-box { width: 100%; }
  .board-summary p:last-child { display: none; }
  .account-copy, .lookup-card { padding: 54px 25px; }
  .lookup-input-row { flex-direction: column; gap: 8px; }
  .lookup-input-row input { border-right: 1px solid #39413d; }
  .lookup-input-row button { width: 100%; }
  .result-fields { grid-template-columns: 1fr; }
  footer { padding: 35px 0; align-items: flex-start; flex-direction: column; gap: 22px; }
  .dialog-head { padding: 38px 24px 24px; }
  .dialog-head h2 { font-size: 32px; }
  .radar-card, .history-card { padding: 28px 22px 34px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
