/* Xons Play "arcade lobby" theme. Loaded after style.css on every public page (the admin panel has its own
   styles and does not load this file). Chunky pressable buttons, game-title type, cartridge tiles and a
   featured-game stage on the home page. */
:root {
  --night: #1a1033; --night2: #221544; --panel: #2a1b55; --panel2: #34226a; --edge: #4a3590; --edge-hi: #6b54c2;
  --gold: #ffc83d; --gold-lip: #b97c00; --pink: #ff5ca8; --pink-lip: #a52f6a; --cyan: #38d6ff; --cyan-lip: #1580a8; --lime: #8cff5a;
  --text: #f6f1ff; --muted: #b6a8e6;
  --bg: var(--night); --bg2: var(--night2); --card: var(--panel); --line: var(--edge);
  --pri: #8a5cff; --pri2: var(--cyan); --acc: var(--pink); --ok: var(--lime);
  --font: "Nunito", "Segoe UI Rounded", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --display: "Lilita One", "Arial Rounded MT Bold", "Arial Black", "Segoe UI Black", system-ui, sans-serif;
  --r: 18px;
}
body {
  font-family: var(--font); font-weight: 600; color: var(--text);
  background:
    radial-gradient(900px 520px at 85% -8%, #7b3cff40, transparent 70%),
    radial-gradient(700px 480px at -5% 12%, #ff5ca826, transparent 70%),
    radial-gradient(#ffffff0f 1.2px, transparent 1.4px) 0 0 / 22px 22px,
    var(--night);
  background-attachment: fixed;
}
a { color: var(--cyan); }
h1, h2, h3, .brand span { font-family: var(--display); font-weight: 400; letter-spacing: .01em; }
h1 { line-height: 1.05; text-shadow: 0 4px 0 #00000055; }
h2 { line-height: 1.1; }
::selection { background: var(--pink); color: #fff; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* ---------- buttons: a solid lip underneath that sinks when pressed ---------- */
.btn {
  --face: var(--panel2); --lip: #1c1240; --ink: #fff;
  position: relative; font: 400 1rem/1 var(--display); letter-spacing: .02em; color: var(--ink);
  background: var(--face); border: 2px solid #ffffff22; border-radius: 14px; padding: 11px 18px 12px;
  box-shadow: 0 5px 0 var(--lip), 0 9px 18px #0007; transform: translateY(0);
  transition: transform .08s ease, box-shadow .08s ease, filter .15s;
}
.btn:hover { filter: brightness(1.08); text-decoration: none; }
.btn:active, .btn.pressed { transform: translateY(4px); box-shadow: 0 1px 0 var(--lip), 0 3px 8px #0007; }
.btn.primary { --face: var(--gold); --lip: var(--gold-lip); --ink: #3a2100; background: linear-gradient(180deg, #ffe07a, var(--gold) 55%); border-color: #fff3; text-shadow: 0 1px 0 #fff6; }
.btn.accent { --face: var(--pink); --lip: var(--pink-lip); background: linear-gradient(180deg, #ff8cc2, var(--pink) 55%); border-color: #fff3; text-shadow: 0 2px 0 #0003; }
.btn.ghost { --face: #2b1d58; --lip: #150d33; background: var(--face); border-color: var(--edge); }
.btn.big { padding: 15px 24px 16px; font-size: 1.18rem; border-radius: 16px; box-shadow: 0 6px 0 var(--lip), 0 12px 24px #0008; }
.btn.big:active { transform: translateY(5px); box-shadow: 0 1px 0 var(--lip), 0 4px 10px #0007; }
.btn.sm { padding: 7px 13px 8px; font-size: .9rem; border-radius: 11px; box-shadow: 0 3px 0 var(--lip); }
.btn.sm:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--lip); }
.btn[disabled] { filter: grayscale(.6) brightness(.8); transform: none; }
.mode-buttons .btn:nth-child(3) { --face: var(--cyan); --lip: var(--cyan-lip); --ink: #04263a; background: linear-gradient(180deg, #8ae9ff, var(--cyan) 55%); border-color: #fff3; }

/* ---------- header as a game HUD bar ---------- */
.site-header { background: linear-gradient(180deg, #24164dee, #1a1033e6); border-bottom: 3px solid #0e0822; box-shadow: 0 2px 0 #ffffff0d inset, 0 8px 20px #0006; }
.brand span { font-size: 1.45rem; color: #fff; text-shadow: 0 3px 0 #0e0822; }
.brand b { color: var(--gold); font-weight: 400; }
.site-nav a, .nav-drop summary { font-family: var(--display); font-weight: 400; font-size: 1.02rem; letter-spacing: .02em; color: #ddd3ff; border-radius: 12px; }
.site-nav a:hover, .site-nav a[aria-current], .nav-drop summary:hover, .nav-drop[open] summary { background: #ffffff14; color: #fff; }
.site-nav a[aria-current] { box-shadow: inset 0 -3px 0 var(--gold); }
.nav-drop > div { background: var(--panel); border: 2px solid var(--edge); border-radius: 16px; box-shadow: 0 6px 0 #0e0822, 0 18px 40px #0009; }
.nav-drop > div a { font-family: var(--font); font-weight: 800; font-size: .95rem; }
.prof-btn { font-family: var(--display); font-weight: 400; font-size: 1rem; background: var(--panel2); border: 2px solid var(--edge-hi); box-shadow: 0 3px 0 #0e0822; }
.prof-btn .pb-ic { background: linear-gradient(135deg, var(--pink), var(--gold)); box-shadow: 0 0 0 2px #fff3; }
.announce { font-family: var(--display); letter-spacing: .02em; background: linear-gradient(90deg, var(--pink), #8a5cff); }

/* ---------- home: featured game stage ---------- */
.stage-hero {
  --c: var(--pink); position: relative; max-width: 1680px; margin: 18px auto 6px; padding: 0 clamp(8px, 2vw, 24px);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-areas: "art info" "picks picks"; gap: 0;
}
.stage-hero::before { content: ""; position: absolute; inset: 0 clamp(8px, 2vw, 24px); border-radius: 28px; background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--c) 38%, transparent), transparent 60%), linear-gradient(160deg, var(--panel2), var(--night2)); border: 3px solid #ffffff1c; box-shadow: 0 8px 0 #0e0822, 0 30px 60px #0009; z-index: -1; transition: background .4s; }
.sh-art { grid-area: art; padding: 18px 0 0 18px; }
.sh-art img { width: 100%; max-height: 380px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 20px; border: 4px solid #fff; box-shadow: 0 0 0 4px var(--c), 0 18px 40px #000a; transform: rotate(-1.2deg); transition: opacity .16s, transform .3s; background: var(--night); }
.sh-info { grid-area: info; padding: clamp(18px, 3vw, 40px); display: flex; flex-direction: column; justify-content: center; gap: 12px; min-width: 0; }
.sh-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.sb { font-family: var(--display); font-size: .9rem; letter-spacing: .02em; padding: 5px 12px 6px; border-radius: 10px; background: #ffffff18; color: #fff; box-shadow: 0 3px 0 #0005; }
.sb.new { background: var(--lime); color: #14320a; }
.sb.multi { background: var(--cyan); color: #04263a; }
.sb.solo { background: #8a5cff; }
.sh-title { margin: 4px 0 0; font-size: clamp(2.3rem, 4.6vw, 4rem); line-height: .98; color: #fff; text-shadow: 0 5px 0 #0e0822, 0 0 30px color-mix(in srgb, var(--c) 55%, transparent); overflow-wrap: anywhere; }
.sh-tag { margin: 0; color: #e6dcff; font-size: clamp(1rem, 1.4vw, 1.15rem); line-height: 1.5; max-width: 46ch; }
.sh-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 8px; }
.sh-actions .btn.big { font-size: 1.45rem; padding: 17px 34px 18px; }
.sh-players { font-weight: 800; color: var(--muted); }
.sh-picks { grid-area: picks; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; padding: 16px 18px 18px; }
.sh-pick { position: relative; padding: 0; border: 3px solid transparent; border-radius: 14px; overflow: hidden; background: var(--night); cursor: pointer; aspect-ratio: 16 / 7; box-shadow: 0 4px 0 #0e0822; transition: transform .12s, border-color .15s; }
.sh-pick img { width: 100%; height: 100%; object-fit: cover; opacity: .72; transition: opacity .15s; }
.sh-pick span { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 8px 6px; font-family: var(--display); font-size: .88rem; color: #fff; text-align: left; background: linear-gradient(transparent, #000c); text-shadow: 0 2px 0 #0008; }
.sh-pick:hover img, .sh-pick.on img { opacity: 1; }
.sh-pick:hover { transform: translateY(-3px); }
.sh-pick.on { border-color: var(--gold); }
.stage-hero.swap .sh-art img { opacity: 0; transform: rotate(-1.2deg) scale(.97); }
.stage-hero.swap .sh-title, .stage-hero.swap .sh-tag { opacity: .2; }
.sh-title, .sh-tag { transition: opacity .16s; }
@media (max-width: 900px) {
  .stage-hero { grid-template-columns: 1fr; grid-template-areas: "art" "info" "picks"; margin-top: 10px; }
  .sh-art { padding: 14px 14px 0; }
  .sh-info { padding: 16px 18px 6px; }
  .sh-picks { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 38%; overflow-x: auto; scrollbar-width: none; padding: 12px 18px 18px; }
  .sh-picks::-webkit-scrollbar { display: none; }
  .sh-actions .btn.big { flex: 1 1 auto; }
}

/* ---------- home: search and filters as mode tabs ---------- */
.g-tools { background: linear-gradient(180deg, var(--night) 72%, #1a103300); }
.g-search { background: var(--panel); border: 2px solid var(--edge); border-radius: 16px; box-shadow: 0 4px 0 #0e0822; }
.g-search:focus-within { border-color: var(--gold); box-shadow: 0 4px 0 #0e0822, 0 0 0 4px #ffc83d33; }
.g-search input { font-weight: 700; }
.chip { font: 400 .98rem/1 var(--display); letter-spacing: .02em; padding: 10px 16px 11px; border-radius: 12px; background: var(--panel); border: 2px solid var(--edge); color: #ddd3ff; box-shadow: 0 3px 0 #0e0822; }
.chip:hover { background: var(--panel2); }
.chip:active { transform: translateY(2px); box-shadow: 0 1px 0 #0e0822; }
.chip.on { background: var(--gold); border-color: #fff4; color: #3a2100; box-shadow: 0 3px 0 var(--gold-lip); }
.chip.ghost { border-style: dashed; }

/* ---------- game tiles as cartridges ---------- */
.tile { border-radius: 18px; background: var(--panel); border: 3px solid #2f2163; box-shadow: 0 5px 0 #0e0822, 0 10px 18px #0006; }
.tile.big { border-radius: 22px; }
.tile::after { box-shadow: inset 0 2px 0 #ffffff22; }
.tile:hover, .tile:focus-visible { transform: translateY(-5px) rotate(-.6deg); border-color: var(--c); box-shadow: 0 9px 0 #0e0822, 0 18px 30px #000a, 0 0 0 3px #ffffff22; }
.t-name { font-family: var(--display); font-weight: 400; font-size: .95rem; letter-spacing: .02em; text-shadow: 0 2px 0 #000a; }
.tile.big .t-name { font-size: 1.3rem; transform: none; padding: 34px 14px 12px; }
.t-badge { font-family: var(--display); font-weight: 400; font-size: .72rem; letter-spacing: .03em; text-transform: none; border-radius: 8px; padding: 3px 8px 4px; background: var(--cyan); color: #04263a; box-shadow: 0 2px 0 #0007; }
.t-badge.new { background: var(--lime); color: #14320a; }
@media (hover: none) { .t-name { font-size: .8rem; } .tile.big .t-name { font-size: 1.05rem; } }
@media (max-width: 760px) { .tile { border-width: 2px; border-radius: 14px; box-shadow: 0 4px 0 #0e0822; } }

/* ---------- sections, cards, categories, guides ---------- */
.section h2, .prose h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); color: #fff; text-shadow: 0 3px 0 #0e0822; }
.cat-tile, .guide-card, .about-band, .faq details, .game-card, .cta-box, .modal-card, .panel {
  background: linear-gradient(170deg, var(--panel2), var(--panel)); border: 2px solid var(--edge); border-radius: 18px; box-shadow: 0 5px 0 #0e0822, 0 14px 28px #0006;
}
.cat-tile { font-family: var(--display); }
.cat-tile b { font-weight: 400; font-size: 1.08rem; }
.cat-tile small { font-family: var(--font); font-weight: 700; }
.cat-tile:hover { border-color: var(--c); transform: translateY(-3px); }
.guide-card { transition: transform .15s, border-color .15s; }
.guide-card:hover { transform: translateY(-3px); border-color: var(--gold); text-decoration: none; }
.guide-card h3 { font-size: 1.22rem; line-height: 1.2; color: #fff; }
.guide-card .tag, .tag { font-family: var(--display); font-weight: 400; text-transform: none; letter-spacing: .02em; font-size: .85rem; color: var(--gold); background: none; padding: 0; }
.pill { font-family: var(--display); font-weight: 400; font-size: .86rem; letter-spacing: .02em; background: var(--panel2); border: 2px solid var(--edge); color: #e9e1ff; border-radius: 10px; padding: 4px 11px 5px; }
.faq details { padding: 4px 18px; margin-bottom: 12px; }
.faq summary { font-family: var(--display); font-weight: 400; font-size: 1.1rem; letter-spacing: .01em; padding: 12px 0; cursor: pointer; }
.faq details[open] { border-color: var(--edge-hi); }
.about-band a, .prose a { color: var(--gold); font-weight: 800; }
.game-card .gc-body h3 { font-size: 1.2rem; }
.gc-mode { font-family: var(--display); font-weight: 400; text-transform: none; letter-spacing: .02em; }

/* ---------- game page: a start screen ---------- */
.game-hero { position: relative; }
.game-hero h1 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); color: #fff; text-shadow: 0 5px 0 #0e0822, 0 0 34px color-mix(in srgb, var(--c) 45%, transparent); }
.game-hero .lead { font-size: 1.15rem; color: #e6dcff; }
.crumbs { font-weight: 800; }
.crumbs a { color: var(--muted); }
.gh-art img { border-radius: 22px; border: 5px solid #fff; box-shadow: 0 0 0 5px var(--c), 0 10px 0 6px #0e0822, 0 30px 60px #000b; transform: rotate(1.2deg); }
.mode-buttons { gap: 14px 12px; }
.join-form input { font-family: var(--display); letter-spacing: .25em; background: var(--panel); border: 2px solid var(--edge); border-radius: 12px; box-shadow: inset 0 3px 0 #0005; color: #fff; }
.join-form input:focus { border-color: var(--gold); }
.share-bar a, .share-bar button { font-family: var(--display); font-weight: 400; }

/* ---------- forms, tables, misc ---------- */
input, textarea, select { font-family: var(--font); }
input:not([type=checkbox]):not([type=radio]):not([type=range]), textarea, select { background: var(--panel); border-color: var(--edge); }
.lb th { font-family: var(--display); font-weight: 400; letter-spacing: .02em; text-transform: none; }
.seg button.on, .tabs button.on, .tabs button[aria-selected=true] { background: var(--gold); color: #3a2100; }
.cookie { background: var(--panel); border: 2px solid var(--edge-hi); box-shadow: 0 6px 0 #0e0822, 0 20px 40px #000a; border-radius: 18px; }

/* ---------- footer ---------- */
.site-footer { background: linear-gradient(180deg, transparent, #0f0924 30%); border-top: 3px solid #0e0822; }
.site-footer h4 { font-family: var(--display); font-weight: 400; font-size: 1.1rem; letter-spacing: .02em; color: var(--gold); text-transform: none; }
.foot-stats b { font-family: var(--display); font-weight: 400; color: var(--gold); }

@media (prefers-reduced-motion: reduce) {
  .btn, .tile, .sh-pick, .sh-art img, .guide-card { transition: none !important; }
  .tile:hover, .tile:focus-visible { transform: none; }
}

/* small tiles: only the New badge; the mode tabs already filter by multiplayer */
.tile:not(.big) .t-badge:not(.new) { display: none; }
.join-form input { letter-spacing: .12em; min-width: 8.5em; }
.share-bar span { font-family: var(--display); font-weight: 400; font-size: 1rem; color: var(--muted); }
.share-bar a, .share-bar button { font-size: .92rem; letter-spacing: .02em; border-radius: 11px; background: var(--panel); border: 2px solid var(--edge); box-shadow: 0 3px 0 #0e0822; padding: 6px 12px 7px; }
.share-bar a:hover, .share-bar button:hover { background: var(--panel2); }
.share-bar a:active, .share-bar button:active { transform: translateY(2px); box-shadow: 0 1px 0 #0e0822; }
.sh-pick span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* level select: chunky level buttons */
.lv { font: 400 1.1rem var(--display); background: var(--panel2); border: 2px solid var(--edge); box-shadow: 0 3px 0 #0e0822; padding: 9px 2px 7px; }
.lv:not(.locked):hover { border-color: var(--gold); }
.lv:not(.locked):active { transform: translateY(2px); box-shadow: 0 1px 0 #0e0822; }
.lv.locked { background: #1d1340; box-shadow: none; opacity: .65; }
.lv-pager select { font-family: var(--display); background: var(--panel); border: 2px solid var(--edge); border-radius: 11px; color: #fff; }
.lv.cur { border-color: var(--gold); box-shadow: 0 3px 0 #0e0822, 0 0 0 3px #ffc83d55; }

/* profile */
.pf-tabs button { font: 400 1.05rem var(--display); letter-spacing: .02em; border-radius: 12px; background: var(--night2); border: 2px solid var(--edge); color: #ddd3ff; }
.pf-tabs button.on { background: var(--gold); color: #3a2100; border: 2px solid #fff4; box-shadow: 0 3px 0 var(--gold-lip); }
.hud-btn.on { background: var(--gold); color: #3a2100; }
.pf-card { background: linear-gradient(170deg, var(--panel2), var(--panel)); border: 2px solid var(--edge); box-shadow: 0 5px 0 #0e0822, 0 14px 28px #0006; }
.pf-stats div { background: var(--night2); border: 2px solid var(--edge); }
.pf-stats b { font-family: var(--display); font-weight: 400; color: var(--gold); }
