:root {
  --bg: #ffffff; --bg2: #f6f6f4; --fg: #1f2328; --muted: #6a7078; --line: #e6e6e1;
  --accent: #ff5a3c; --accent-fg: #ffffff; --chip: #efefea; --link: #1f2328;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #141416; --bg2: #1c1c1f; --fg: #ececec; --muted: #9a9aa1; --line: #2c2c31; --accent: #ff6b4f; --accent-fg: #14141a; --chip: #26262b; --link: #ececec; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--link); text-decoration-color: var(--line); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
.wrap { max-width: 760px; margin: 0 auto; padding: 0 16px; }
.wrap.wide { max-width: 980px; }
.top { border-bottom: 1px solid var(--line); }
.bar { display: flex; align-items: center; justify-content: space-between; height: 56px; gap: 12px; }
.brand, nav a { white-space: nowrap; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; text-decoration: none; letter-spacing: -.01em; }
.logo { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 6px; background: var(--accent); color: var(--accent-fg); }
nav { display: flex; align-items: center; gap: 16px; font-size: 14px; }
nav a { text-decoration: none; color: var(--muted); }
nav a:hover { color: var(--fg); }
nav a.btn { color: var(--accent-fg); }
main { padding-top: 8px; padding-bottom: 40px; min-height: 60vh; }
.foot { padding-top: 20px; padding-bottom: 32px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.foot a { color: var(--muted); }

.btn { display: inline-block; border: 1px solid var(--accent); background: var(--accent); color: var(--accent-fg); font: inherit; font-weight: 600; font-size: 15px; padding: 8px 16px; border-radius: 8px; cursor: pointer; text-decoration: none; }
.btn:hover { filter: brightness(.94); }
.btn.small { font-size: 13px; padding: 5px 12px; }
.btn.ghost { background: transparent; color: var(--fg); border-color: var(--line); }

.hero { padding: 28px 0 8px; }
.hero h1 { font-size: 26px; line-height: 1.2; margin: 0 0 6px; letter-spacing: -.02em; }
.hero p { margin: 0; color: var(--muted); }
.sec { display: flex; align-items: baseline; gap: 10px; font-size: 18px; margin: 28px 0 4px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.sec .date { color: var(--muted); font-size: 14px; font-weight: 400; }
.list { list-style: none; margin: 0; padding: 0; }
.row { display: flex; align-items: center; gap: 14px; padding: 14px 6px; margin: 0 -6px; border-radius: 10px; }
.row:hover { background: var(--bg2); }
.row-link { flex: none; line-height: 0; }
.row-main { flex: 1; min-width: 0; }
.row h3 { margin: 0; font-size: 16px; line-height: 1.3; }
.row h3 a { text-decoration: none; }
.rank { color: var(--muted); font-weight: 500; }
.tagline { margin: 2px 0 0; color: var(--muted); font-size: 14.5px; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 6px; font-size: 13px; }
.play { color: var(--accent); font-weight: 600; text-decoration: none; margin-right: 4px; }
.play:hover { text-decoration: underline; }
.chip { background: var(--chip); color: var(--muted); border-radius: 999px; padding: 1px 9px; font-size: 12px; }
.thumb { position: relative; width: 64px; height: 64px; border-radius: 12px; overflow: hidden; background: var(--chip); display: grid; place-items: center; }
.thumb.lg { width: 72px; height: 72px; }
.thumb span { font-size: 26px; font-weight: 700; color: var(--muted); }
.thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.vote { flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; width: 54px; height: 60px; border: 1px solid var(--line); background: var(--bg); color: var(--fg); border-radius: 10px; font: inherit; font-size: 14px; cursor: pointer; }
.vote:hover { border-color: var(--accent); color: var(--accent); }
.vote.on { border-color: var(--accent); background: var(--accent); color: var(--accent-fg); }
.vote b { font-weight: 600; font-variant-numeric: tabular-nums; }
.empty { color: var(--muted); padding: 24px 0; }

.crumb { margin: 18px 0 8px; font-size: 14px; }
.game-head { display: flex; align-items: center; gap: 16px; margin: 8px 0 18px; }
.game-title h1 { margin: 0; font-size: 28px; line-height: 1.2; letter-spacing: -.02em; }
.game-title .tagline { font-size: 17px; margin-top: 4px; }
.cover { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: var(--chip); display: grid; place-items: center; border: 1px solid var(--line); }
.cover span { font-size: 72px; font-weight: 700; color: var(--muted); }
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.actions { display: flex; align-items: center; gap: 12px; margin: 18px 0 24px; }
.play-big { font-size: 18px; padding: 12px 32px; }
.actions .vote { width: 64px; height: 50px; flex-direction: row; gap: 8px; }
.cols { display: grid; grid-template-columns: 1fr 240px; gap: 32px; align-items: start; }
.desc p { margin: 0 0 14px; }
.facts { margin: 0; font-size: 14px; border-left: 1px solid var(--line); padding-left: 20px; }
.facts div { margin-bottom: 14px; }
.facts dt { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .05em; }
.facts dd { margin: 2px 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.muted { color: var(--muted); }

.prose { padding-top: 24px; }
.prose h1 { font-size: 28px; letter-spacing: -.02em; margin: 0 0 12px; }
.prose h2 { font-size: 18px; margin: 28px 0 6px; }
.prose.narrow { max-width: 600px; }
.prose code { background: var(--chip); padding: 1px 6px; border-radius: 5px; }
.form { display: flex; flex-direction: column; gap: 16px; margin-top: 20px; }
.form label { display: flex; flex-direction: column; gap: 5px; font-size: 14px; font-weight: 600; }
.form label em { font-weight: 400; font-style: normal; color: var(--muted); }
.form label i { color: var(--accent); font-style: normal; }
.form small { font-weight: 400; color: var(--muted); }
input, textarea { font: inherit; font-weight: 400; color: var(--fg); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 9px 11px; width: 100%; }
input:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form .btn { align-self: flex-start; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { background: color-mix(in srgb, var(--accent) 14%, transparent); border: 1px solid var(--accent); border-radius: 8px; padding: 10px 14px; }

.pend-list { list-style: none; margin: 16px 0; padding: 0; display: grid; gap: 14px; }
.pend { display: flex; gap: 20px; justify-content: space-between; border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.pend h3 { margin: 0 0 4px; font-size: 17px; }
.pend p { margin: 4px 0; }
.pend .kv { font-size: 13px; word-break: break-all; }
.pend-info { min-width: 0; flex: 1; }
.pend-act { display: flex; flex-direction: column; gap: 8px; flex: none; width: 170px; font-size: 13px; }
.pend-act label { display: flex; flex-direction: column; gap: 4px; }

@media (max-width: 640px) {
  .hero h1 { font-size: 22px; }
  .row { gap: 10px; }
  .thumb { width: 54px; height: 54px; border-radius: 10px; }
  .vote { width: 48px; height: 54px; }
  .cols { grid-template-columns: 1fr; gap: 8px; }
  .facts { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 16px; }
  .two { grid-template-columns: 1fr; }
  .game-title h1 { font-size: 23px; }
  .pend { flex-direction: column; }
  .pend-act { width: 100%; }
  nav { gap: 12px; }
  nav a:not(.btn):first-child { display: none; }
}

/* ---- assets ---- */
.asearch { display: flex; gap: 8px; margin: 16px 0 12px; }
.asearch input[type=search] { flex: 1; min-width: 0; }
.asearch select { font: inherit; color: var(--fg); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 9px 10px; max-width: 200px; }
.tabs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 16px; }
.tab { text-decoration: none; font-size: 14px; color: var(--muted); padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line); }
.tab:hover { color: var(--fg); }
.tab.on { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.tabs .count { margin-left: auto; font-size: 13px; }
.agrid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.acard { min-width: 0; }
.acard a { display: block; text-decoration: none; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--bg); }
.acard a:hover { border-color: var(--accent); }
.apic, .acover { position: relative; aspect-ratio: 1 / 1; background: var(--chip); display: grid; place-items: center; }
.apic span, .acover span { font-size: 40px; font-weight: 700; color: var(--muted); }
.apic img, .acover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ainfo { padding: 8px 10px 10px; min-width: 0; }
.ainfo b { display: block; font-size: 14px; font-weight: 600; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ainfo small { color: var(--muted); font-size: 12px; }
.pager { display: flex; align-items: center; justify-content: space-between; margin: 24px 0 0; font-size: 14px; }
.acover { aspect-ratio: 4 / 3; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); }
.acover img { object-fit: contain; }
.atitle { margin: 16px 0 0; font-size: 28px; line-height: 1.2; letter-spacing: -.02em; }
.asset .chips { display: flex; flex-wrap: wrap; gap: 6px; }
.asset .chip { text-decoration: none; }
.asset .chip:hover { color: var(--fg); }
.asset .license { margin-top: 18px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg2); font-size: 14px; }
.asset .btn small { font-weight: 400; opacity: .85; }
.extra { margin: -12px 0 20px; font-size: 13px; color: var(--muted); }
.extra ul { margin: 8px 0 0; padding-left: 20px; }
.extra a { color: var(--muted); }
@media (max-width: 640px) {
  .agrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .asearch { flex-wrap: wrap; }
  .asearch input[type=search] { flex: 1 1 100%; }
  nav a:not(.btn):nth-child(3) { display: none; }
  .asearch select { max-width: none; flex: 1; }
  .atitle { font-size: 23px; }
}
