:root { color-scheme: dark; --bg: #0d0d1a; --panel: #17182b; --line: #363b59; --text: #f5f4ff; --muted: #abb2ca; --accent: #a78bfa; }
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 50% -15%, #26294c, var(--bg) 55%); color: var(--text); font-family: Raleway, Arial, sans-serif; }
main { width: min(100% - 32px, 820px); margin: 36px auto 72px; }
.back { display: inline-block; margin-bottom: 28px; color: var(--accent); text-decoration: none; font-size: 14px; font-weight: 700; }
.eyebrow { margin: 0; color: var(--accent); text-transform: uppercase; letter-spacing: .2em; font-size: 12px; font-weight: 800; }
h1 { font-size: clamp(48px, 10vw, 90px); letter-spacing: -.07em; margin: 4px 0 12px; }
.intro { color: var(--muted); line-height: 1.5; max-width: 650px; }
.modes { display: flex; gap: 10px; margin: 25px 0 12px; }
button { font: inherit; cursor: pointer; }
.mode, .actions button { padding: 10px 17px; border: 1px solid var(--line); border-radius: 10px; background: #101222; color: var(--muted); font-weight: 800; }
.mode.active { border-color: var(--accent); color: var(--accent); background: #25203e; }
.board { margin: 18px 0; padding: clamp(18px, 4vw, 28px); background: var(--panel); border: 1px solid var(--line); border-radius: 20px; }
.board-label { margin: 0 0 15px; color: var(--muted); font-size: 11px; font-weight: 900; letter-spacing: .16em; }
.endpoints { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; }
.endpoints > div { min-width: 0; padding: 15px; background: #101222; border: 1px solid var(--line); border-radius: 12px; }
.endpoints span { display: block; color: var(--accent); font-size: 11px; font-weight: 900; letter-spacing: .14em; }
.endpoints strong { display: block; overflow-wrap: anywhere; margin-top: 8px; font-size: clamp(16px, 3vw, 24px); }
.endpoints .connector { font-size: 26px; letter-spacing: normal; }
#progress { margin: 20px 0 10px; color: var(--muted); font-weight: 700; }
#chain, #solution-chain { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
#chain li, #solution-chain li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 15px; border: 1px solid var(--line); border-radius: 10px; background: #101222; }
#chain li:first-child { border-color: var(--accent); }
#chain li span, #solution-chain li span { padding: 4px 8px; border-radius: 6px; background: #29243d; color: var(--accent); font-size: 11px; font-weight: 800; }
label { display: block; margin-bottom: 12px; color: var(--muted); font-weight: 700; }
label strong { color: var(--text); }
#player-search { width: 100%; padding: 13px 14px; border: 1px solid var(--line); border-radius: 10px; background: #101222; color: var(--text); font: inherit; }
#player-search:focus { border-color: var(--accent); outline: none; }
#suggestions { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 7px; margin-top: 9px; }
#suggestions:empty { display: none; }
#suggestions button { padding: 10px; text-align: left; background: #202039; border: 1px solid var(--line); border-radius: 8px; color: var(--text); }
#suggestions button:hover { border-color: var(--accent); }
#message { min-height: 25px; color: var(--accent); line-height: 1.5; }
.actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 16px; }
.actions button:hover:not(:disabled), .mode:hover { border-color: var(--accent); color: var(--text); }
.actions button:disabled { opacity: .4; cursor: default; }
.actions .primary { background: var(--accent); border-color: var(--accent); color: #171026; }
.actions .primary:hover { color: #171026 !important; }
button:focus-visible, a:focus-visible { outline: 3px solid #f7d77b; outline-offset: 2px; }
#solution { margin-top: 28px; }
#solution h2 { margin: 0 0 12px; font-size: 17px; }
.note { color: var(--muted); font-size: 12px; line-height: 1.5; margin-top: 30px; }
@media (max-width: 540px) { .endpoints { gap: 7px; } .endpoints > div { padding: 11px; } .endpoints .connector { font-size: 17px; } #suggestions { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
