/* ChangekoGame — "neon arcade" theme, dark: HUD chrome, cyan/magenta neon, cut-corner panels, Chakra Petch display */
:root {
  color-scheme: dark;
  --bg: #07070f;
  --surface: #0f0f1c;
  --surface-2: #161629;
  --text: #e8ebff;
  --muted: #8f94b8;
  --line: #24243d;
  --neon: #00f0ff;          /* primary accent: cyan */
  --neon-2: #ff2bd6;        /* secondary accent: magenta */
  --neon-ink: #05050c;      /* text on neon fills */
  --hot: #ff2b5e;           /* live / breaking */
  --link: #5cf6ff;
  --chrome: #0b0b16;        /* header, panels, bands and footer */
  --chrome-2: #11111f;
  --chrome-line: #22223a;
  --news: #00f0ff;          /* "rarity" colours by post type */
  --article: #b07cff;
  --review: #ffc53d;
  --cut: 14px;              /* cut-corner size */
  --glow: 0 0 18px rgb(0 240 255 / .35);
  --shadow: 0 10px 30px rgb(0 0 0 / .45);
  --display: "Chakra Petch", "Kanit", "Sarabun", system-ui, sans-serif;
  --body: "Sarabun", "Noto Sans Thai", "Leelawadee UI", "Thonburi", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.7;
  overflow-wrap: break-word;
  background:
    radial-gradient(900px 500px at 8% -10%, rgb(0 240 255 / .10), transparent 60%),
    radial-gradient(800px 500px at 100% 0%, rgb(255 43 214 / .10), transparent 60%),
    linear-gradient(rgb(255 255 255 / .025) 1px, transparent 1px) 0 0 / 100% 40px,
    linear-gradient(90deg, rgb(255 255 255 / .025) 1px, transparent 1px) 0 0 / 40px 100%,
    var(--bg);
  background-attachment: fixed;
}
::selection { background: var(--neon-2); color: #fff; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--link); }
a:focus-visible { outline: 2px solid var(--neon); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--display); overflow-wrap: anywhere; }
.wrap { max-width: 1240px; margin-inline: auto; padding: 0 16px; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.skip { position: absolute; left: -999px; top: 0; background: var(--neon); color: var(--neon-ink); padding: 8px 12px; z-index: 50; font-weight: 700; }
.skip:focus { left: 8px; }


/* cut-corner panel shape, shared */
.tile, .feature, .shot, .trending, .game-banner, .meta-panel, .post-body ul, .post-cover img, .post-body img, .online-box {
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
}
/* HUD corner brackets, shared */
.online-box::before, .meta-panel::before, .game-info::before {
  content: ""; position: absolute; inset: 6px; pointer-events: none; opacity: .7;
  background:
    linear-gradient(var(--neon), var(--neon)) left top / 12px 2px, linear-gradient(var(--neon), var(--neon)) left top / 2px 12px,
    linear-gradient(var(--neon), var(--neon)) right bottom / 12px 2px, linear-gradient(var(--neon), var(--neon)) right bottom / 2px 12px;
  background-repeat: no-repeat;
}

/* ---------- app shell: launcher sidebar + main column ---------- */
.app { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100vh; }
.main-col { min-width: 0; display: flex; flex-direction: column; }
.main-col > main { flex: 1; }
.wrap { max-width: 1280px; margin-inline: auto; padding: 0 28px; width: 100%; }

.sidebar {
  position: sticky; top: 0; height: 100vh; overflow-y: auto; scrollbar-width: thin;
  display: flex; flex-direction: column; gap: 18px; padding: 20px 14px 18px;
  background: linear-gradient(180deg, #0b0b17, #08080f); border-right: 1px solid var(--chrome-line);
}
.sidebar::after {
  content: ""; position: absolute; top: 0; bottom: 0; right: -1px; width: 2px; pointer-events: none;
  background: linear-gradient(180deg, var(--neon), var(--neon-2) 60%, transparent);
  box-shadow: 0 0 14px rgb(0 240 255 / .45);
}
.side-brand { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 6px; }
.logo { display: inline-flex; align-items: center; gap: 10px; flex: none; }
.logo:hover { color: inherit; }
.logo img { filter: drop-shadow(0 0 8px rgb(0 240 255 / .45)); }
.logo-text {
  position: relative; font-family: var(--display); font-weight: 700; font-size: 1.32rem; letter-spacing: .05em; line-height: 1;
  color: var(--text); text-shadow: -2px 0 rgb(255 43 214 / .7), 2px 0 rgb(0 240 255 / .7);
}
.logo-text b { color: var(--neon); font-weight: 700; margin-left: 2px; }
.sidebar .logo-text { font-size: 1.12rem; letter-spacing: .02em; } /* 12-letter wordmark must fit the sidebar */
.logo:hover .logo-text { animation: glitch .35s steps(2) 2; }
@keyframes glitch {
  0% { text-shadow: -3px 0 var(--neon-2), 3px 0 var(--neon); transform: translateX(0); }
  50% { text-shadow: 3px 0 var(--neon-2), -3px 0 var(--neon); transform: translateX(1px); }
  100% { text-shadow: -2px 0 rgb(255 43 214 / .7), 2px 0 rgb(0 240 255 / .7); transform: none; }
}
.hud { display: inline-flex; align-items: center; gap: 7px; font-family: var(--display); font-size: .72rem; letter-spacing: .12em; color: #3dff8a; }
.hud-mini { display: none; }
.hud-dot { flex: none; width: 7px; height: 7px; border-radius: 50%; background: #3dff8a; box-shadow: 0 0 8px #3dff8a; animation: pulse 1.6s ease-in-out infinite; }

.side-label { margin: 0 0 6px; padding: 0 10px; font-family: var(--display); font-size: .7rem; font-weight: 700; letter-spacing: .22em; color: var(--muted); }
.side-nav { flex: 1; }
.side-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.side-nav a {
  position: relative; display: flex; align-items: center; gap: 12px; padding: 7px 10px; min-height: 44px;
  font-family: var(--display); font-weight: 600; font-size: .98rem; color: #b8bcdc; white-space: nowrap;
  border: 1px solid transparent; transition: color .15s, background .15s, border-color .15s;
}
.nav-ico {
  flex: none; width: 30px; height: 30px; display: grid; place-items: center; font-size: 1rem;
  background: var(--surface-2); border: 1px solid var(--line);
  clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%);
}
.nav-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.nav-count { flex: none; font-size: .72rem; color: var(--muted); padding: 0 7px; border: 1px solid var(--line); line-height: 1.6; }
.side-nav a:hover { color: var(--text); background: var(--surface-2); }
.side-nav a:hover .nav-ico { background: rgb(0 240 255 / .18); }
.side-nav a[aria-current="page"] {
  color: var(--text); background: linear-gradient(90deg, rgb(0 240 255 / .18), rgb(0 240 255 / 0)); border-color: rgb(0 240 255 / .3);
}
.side-nav a[aria-current="page"]::before {
  content: ""; position: absolute; left: -1px; top: 6px; bottom: 6px; width: 3px; background: var(--neon); box-shadow: 0 0 10px var(--neon);
}
.side-nav a[aria-current="page"] .nav-ico { background: var(--neon); border-color: var(--neon); }
.side-nav a[aria-current="page"] .nav-count { color: var(--neon); border-color: rgb(0 240 255 / .5); }

.online-box { position: relative; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); font-size: .82rem; }
.online-box p { margin: 0; }
.online-status { display: flex; align-items: center; gap: 8px; font-family: var(--display); font-weight: 700; letter-spacing: .1em; color: #3dff8a; font-size: .76rem; }
.online-tag { margin-top: 6px !important; color: var(--text); line-height: 1.45; }
.online-meta { margin-top: 4px !important; color: var(--muted); font-size: .76rem; }
.online-rss { display: inline-block; margin-top: 8px; padding: 3px 0; font-family: var(--display); font-weight: 700; font-size: .74rem; letter-spacing: .1em; color: var(--neon-2); }

/* ticker (top of main column) */
.ticker { display: flex; align-items: stretch; background: #080812; border-bottom: 1px solid var(--chrome-line); height: 40px; overflow: hidden; }
.ticker-label {
  flex: none; display: flex; align-items: center; gap: 8px; padding: 0 22px 0 16px;
  background: var(--neon-2); color: #fff; font-family: var(--display); font-weight: 700; letter-spacing: .14em;
  clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 100%, 0 100%);
  text-shadow: 0 0 8px rgb(255 255 255 / .6);
}
.pulse { width: 8px; height: 8px; border-radius: 50%; background: #fff; animation: pulse 1.1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .2; } }
.ticker-view { overflow: hidden; flex: 1; mask-image: linear-gradient(90deg, transparent, #000 24px, #000 calc(100% - 48px), transparent); }
.ticker-track { list-style: none; margin: 0; padding: 0; display: flex; width: max-content; height: 100%; animation: ticker 70s linear infinite; }
.ticker:hover .ticker-track, .ticker:focus-within .ticker-track { animation-play-state: paused; }
.ticker-track li { display: flex; align-items: center; }
.ticker-track a { display: flex; align-items: center; gap: 10px; padding: 0 28px; white-space: nowrap; font-size: .92rem; color: var(--text); }
.ticker-track a:hover { color: var(--neon); }
.ticker-track li + li a { border-left: 1px solid var(--chrome-line); }
.ticker-sec { font-family: var(--display); font-size: .72rem; font-weight: 700; color: var(--neon); letter-spacing: .06em; }
.ticker-sec::before { content: "["; opacity: .6; }
.ticker-sec::after { content: "]"; opacity: .6; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* breadcrumbs */
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px; padding: 0; margin: 18px auto 0; font-size: .85rem; color: var(--muted); font-family: var(--display); }
.crumbs li + li::before { content: "›"; margin-right: 6px; color: var(--neon); }
.crumbs a { display: inline-block; padding: 2px 0; }
.crumbs [aria-current] { color: var(--text); padding: 2px 0; }
.crumbs li:last-child span { display: inline-block; max-width: 60ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; }

/* ---------- shared bits ---------- */
section { margin-top: 44px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.section-title {
  display: flex; align-items: center; gap: 12px;
  font-weight: 700; font-size: 1.45rem; line-height: 1.2; margin: 0 0 16px; letter-spacing: .02em;
}
.section-head .section-title { margin: 0; min-width: 0; }
.section-title::before {
  content: ""; flex: none; width: 0; height: 0; border-style: solid; border-width: 8px 0 8px 12px;
  border-color: transparent transparent transparent var(--neon); filter: drop-shadow(0 0 6px var(--neon));
}
.section-title a:hover { color: var(--neon); text-shadow: var(--glow); }
.head-note { flex: none; font-family: var(--display); font-size: .74rem; font-weight: 700; letter-spacing: .2em; color: var(--neon-2); }
.sec-ico { font-style: normal; }
.sec-count { font-family: var(--display); font-size: .78rem; font-weight: 600; color: var(--muted); padding: 0 8px; border: 1px solid var(--line); line-height: 1.7; }
.more {
  flex: none; display: inline-block; font-family: var(--display); font-weight: 600; font-size: .86rem; letter-spacing: .04em;
  padding: 5px 16px; color: var(--neon); border: 1px solid rgb(0 240 255 / .5);
  clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}
.more:hover { background: var(--neon); color: var(--neon-ink); }
.badge {
  position: relative; z-index: 2;
  display: inline-flex; align-items: center; gap: 5px; padding: 1px 12px;
  background: rgb(0 240 255 / .12); color: var(--neon); border: 1px solid rgb(0 240 255 / .45);
  font-family: var(--display); font-weight: 700; font-size: .78rem; line-height: 1.7; letter-spacing: .03em;
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
}
.badge:hover { background: var(--neon); color: var(--neon-ink); }
.type { font-family: var(--display); font-weight: 700; font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; }
.type::before { content: "◆ "; font-size: .85em; }
.type-news { color: var(--news); }
.type-article { color: var(--article); }
.type-review { color: var(--review); text-shadow: 0 0 10px rgb(255 197 61 / .5); }
.sub { color: var(--muted); margin: 0 0 8px; font-size: .95rem; line-height: 1.55; }
.meta { margin: 0; font-size: .8rem; color: var(--muted); }
.stretch::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.feature-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 10px; }

/* ---------- store tile ---------- */
.tile {
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(140deg, var(--line), var(--line)) border-box;
  border: 1px solid transparent; transition: transform .2s, background .2s;
}
.tile:hover {
  transform: translateY(-3px);
  background: linear-gradient(var(--surface-2), var(--surface-2)) padding-box, linear-gradient(140deg, var(--neon), var(--neon-2)) border-box;
}
.tile-img { position: relative; overflow: hidden; background: var(--surface-2); }
.tile-img::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgb(0 0 0 / .12) 0 1px, transparent 1px 3px); pointer-events: none; }
.tile-img img { aspect-ratio: 16/9; object-fit: cover; width: 100%; transition: transform .5s cubic-bezier(.2, .7, .2, 1); }
.tile:hover .tile-img img { transform: scale(1.06); }
.tile-img .type {
  position: absolute; left: 8px; bottom: 8px; z-index: 1; padding: 0 8px; font-size: .72rem;
  background: rgb(7 7 15 / .88); border: 1px solid currentColor;
}
.tile-body { padding: 10px 12px 12px; display: flex; flex-direction: column; flex: 1; }
.tile-sec { margin: 0; font-family: var(--display); font-size: .72rem; font-weight: 600; color: var(--muted); letter-spacing: .02em; }
.tile h3 {
  font-size: .98rem; font-weight: 600; line-height: 1.4; margin: 4px 0 8px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.tile h3 a:hover { color: var(--neon); }
.tile .meta { margin-top: auto; font-size: .74rem; }
.tile-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }

/* ---------- home: featured banner + screenshots ---------- */
.showcase { margin-top: 24px; }
.feature {
  position: relative; overflow: hidden; background: #000; color: #fff;
  isolation: isolate; width: 100%; min-height: 420px; aspect-ratio: 21/8; display: flex; align-items: flex-end;
}
.feature img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -3;
  transition: transform .6s cubic-bezier(.2, .7, .2, 1); filter: saturate(1.15) contrast(1.05);
}
.feature::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgb(7 7 15 / .96) 0%, rgb(7 7 15 / .75) 38%, rgb(7 7 15 / 0) 72%),
    linear-gradient(0deg, rgb(7 7 15 / .8), transparent 45%);
}
.feature::after {
  content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background: repeating-linear-gradient(0deg, rgb(0 0 0 / .18) 0 1px, transparent 1px 3px);
  box-shadow: inset 0 0 0 1px rgb(0 240 255 / .35), inset 0 0 60px rgb(0 240 255 / .12);
}
.feature:hover img { transform: scale(1.04); }
.feature-body { padding: 32px 36px; max-width: 640px; }
.feature-flag {
  display: inline-block; margin: 0 0 12px; padding: 2px 14px; font-family: var(--display); font-weight: 700; font-size: .78rem; letter-spacing: .2em;
  background: var(--review); color: var(--neon-ink); clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
}
.feature h2 { font-size: clamp(1.6rem, 3vw, 2.5rem); font-weight: 700; line-height: 1.2; margin: 0 0 10px; text-shadow: 0 2px 20px rgb(0 0 0 / .6); }
.feature h2 a:hover { color: var(--neon); text-shadow: var(--glow); }
.feature .sub { color: #c9cde6; font-size: 1.02rem; }
.feature-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 16px; }
.play-btn {
  display: inline-block; padding: 9px 26px; font-family: var(--display); font-weight: 700; letter-spacing: .06em;
  background: linear-gradient(90deg, var(--neon), #46a8ff); color: var(--neon-ink); box-shadow: var(--glow);
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}
.feature:hover .play-btn { background: linear-gradient(90deg, var(--neon-2), #ff6ad5); }
.feature .meta { color: #b3b8d6; }

.shots { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.shot {
  position: relative; display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 12px; align-items: center;
  padding: 8px; background: var(--surface); border: 1px solid var(--line); transition: border-color .15s, background .15s;
}
.shot:hover { border-color: var(--neon); background: var(--surface-2); }
.shot img { aspect-ratio: 16/9; object-fit: cover; width: 100%; }
.shot h3 {
  font-size: .95rem; font-weight: 600; line-height: 1.4; margin: 2px 0 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.shot h3 a:hover { color: var(--neon); }

/* ---------- home: new releases grid + trending ---------- */
.browse { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; margin-top: 44px; }
.browse > section { margin-top: 0; }
.trending { position: sticky; top: 16px; background: var(--surface); border: 1px solid var(--line); padding: 18px 18px 8px; }
.trending .section-title { font-size: 1.2rem; color: var(--neon-2); text-shadow: 0 0 12px rgb(255 43 214 / .4); margin-bottom: 8px; }
.trending .section-title::before { border-left-color: var(--neon-2); filter: drop-shadow(0 0 6px var(--neon-2)); }
.trending ol { list-style: none; margin: 0; padding: 0; }
.trending li { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 10px; padding: 10px 0; }
.trending li + li { border-top: 1px dashed var(--line); }
.rank {
  font-family: var(--display); font-weight: 700; font-size: 1.55rem; line-height: 1.1;
  color: transparent; -webkit-text-stroke: 1.2px var(--neon); text-shadow: 0 0 12px rgb(0 240 255 / .3);
}
.trending li:nth-child(-n+3) .rank { -webkit-text-stroke-color: var(--review); text-shadow: 0 0 12px rgb(255 197 61 / .4); }
.trending .tile-sec { display: block; }
.trending a { display: block; padding: 2px 0; font-weight: 600; font-size: .92rem; line-height: 1.45; }

/* ---------- home: section shelves ---------- */
.shelf {
  display: grid; grid-auto-flow: column; grid-auto-columns: 232px; gap: 14px;
  overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; padding-bottom: 12px;
  scrollbar-width: thin; scrollbar-color: var(--neon) var(--surface-2);
}
.shelf:focus-visible { outline: 2px solid var(--neon); outline-offset: 4px; }
.shelf .tile { scroll-snap-align: start; }
.shelf::-webkit-scrollbar { height: 6px; }
.shelf::-webkit-scrollbar-track { background: var(--surface-2); }
.shelf::-webkit-scrollbar-thumb { background: var(--neon); }

/* ---------- list: game page header ---------- */
.game-head { margin-top: 16px; }
.game-banner {
  position: relative; overflow: hidden; isolation: isolate; min-height: 260px; display: flex; align-items: flex-end;
  background: radial-gradient(600px 220px at 70% 100%, rgb(255 43 214 / .3), transparent 70%), linear-gradient(180deg, #0a0a18, #120a24);
  border: 1px solid var(--chrome-line);
}
.game-banner::after {
  content: ""; position: absolute; left: -10%; right: -10%; bottom: -40px; height: 140px; pointer-events: none; z-index: -1;
  background:
    linear-gradient(rgb(255 43 214 / .5) 1px, transparent 1px) 0 0 / 100% 22px,
    linear-gradient(90deg, rgb(0 240 255 / .4) 1px, transparent 1px) 0 0 / 46px 100%;
  transform: perspective(240px) rotateX(58deg); transform-origin: top;
  mask-image: linear-gradient(transparent, #000 40%);
}
.game-art {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -3; opacity: .45; filter: saturate(1.2) blur(1px);
  mask-image: linear-gradient(90deg, transparent 10%, #000 70%);
}
.game-banner::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(0deg, rgb(7 7 15 / .9), rgb(7 7 15 / .1) 70%); }
.game-info { position: relative; display: flex; align-items: center; gap: 22px; padding: 28px 32px; width: 100%; }
.game-info::before { inset: 10px; opacity: .5; }
.game-icon {
  flex: none; margin: 0; width: 92px; height: 92px; display: grid; place-items: center; font-size: 2.6rem; line-height: 1;
  background: linear-gradient(140deg, rgb(0 240 255 / .25), rgb(255 43 214 / .25)); border: 1px solid var(--neon);
  clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%);
  filter: drop-shadow(0 0 12px rgb(0 240 255 / .5));
}
.game-text { min-width: 0; }
.game-kicker { margin: 0; font-family: var(--display); font-weight: 700; font-size: .76rem; letter-spacing: .24em; color: var(--neon); }
.game-head h1 {
  font-weight: 700; font-size: clamp(1.9rem, 4.2vw, 3rem); line-height: 1.15; margin: 4px 0 6px; letter-spacing: .02em;
  text-shadow: 0 0 24px rgb(0 240 255 / .35);
}
.game-head h1 small { font-size: .45em; color: var(--neon-2); }
.game-intro { margin: 0; color: #c1c5e0; max-width: 62ch; }
.game-intro a { color: var(--neon); text-decoration: underline; }
.game-stats { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; border: 1px solid var(--line); border-top: 0; background: var(--surface); }
.game-stats li { flex: 1 1 140px; padding: 10px 18px; display: flex; flex-direction: column; line-height: 1.3; }
.game-stats li + li { border-left: 1px solid var(--line); }
.game-stats b { font-family: var(--display); font-size: 1.1rem; color: var(--text); }
.game-stats span { font-size: .76rem; color: var(--muted); }
.gameover h1 { color: var(--hot); text-shadow: -3px 0 var(--neon), 3px 0 var(--neon-2), 0 0 30px rgb(255 43 94 / .5); letter-spacing: .08em; }
.list-title { margin-top: 32px; }
.pager { display: flex; gap: 16px; justify-content: center; align-items: center; margin-top: 36px; font-family: var(--display); color: var(--muted); }
.pager a {
  padding: 8px 20px; font-weight: 700; color: var(--neon); border: 1px solid var(--neon);
  clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}
.pager a:hover { background: var(--neon); color: var(--neon-ink); }

/* ---------- article: patch notes ---------- */
.patch { margin-top: 18px; }
.patch-head { max-width: 880px; padding-bottom: 18px; border-bottom: 1px solid var(--line); position: relative; }
.patch-head::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 160px; height: 2px; background: linear-gradient(90deg, var(--neon), var(--neon-2)); box-shadow: 0 0 10px var(--neon); }
.patch-tag { margin: 0 0 12px; font-family: var(--display); font-weight: 700; font-size: .78rem; letter-spacing: .22em; color: var(--neon-2); }
.patch-tag span { color: var(--muted); letter-spacing: .06em; }
.patch-head .type { padding: 1px 10px; border: 1px solid currentColor; }
.patch-head h1 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); font-weight: 700; line-height: 1.25; margin: 8px 0 10px; }
.post-sub { font-size: 1.15rem; color: var(--muted); margin: 0; line-height: 1.55; }
.patch-layout { display: grid; grid-template-columns: minmax(0, 760px) 270px; gap: 44px; margin-top: 24px; align-items: start; }
.patch-main { min-width: 0; }
.post-cover { margin: 0 0 24px; position: relative; }
.post-cover img { width: 100%; aspect-ratio: 1200/630; object-fit: cover; }
.post-body { font-size: 1.08rem; color: #d7daf0; }
.post-body strong { color: var(--text); }
.post-body .lead { font-size: 1.16rem; padding: 4px 0 4px 18px; border-left: 3px solid var(--neon); box-shadow: -8px 0 16px -10px var(--neon); }
.post-body h2 {
  font-size: 1.35rem; font-weight: 700; line-height: 1.3; margin: 40px 0 12px; color: var(--text);
  padding: 8px 14px; background: linear-gradient(90deg, rgb(0 240 255 / .12), transparent); border-left: 3px solid var(--neon);
}
.post-body h2::before { content: "## "; color: var(--neon-2); font-size: .85em; }
.post-body h3 { font-size: 1.15rem; margin: 28px 0 8px; color: var(--text); }
.post-body img { margin: 24px 0; width: 100%; }
.post-body a { color: var(--link); text-decoration: underline; text-underline-offset: 3px; }
.post-body ul { list-style: none; padding: 16px 20px; background: var(--surface); border: 1px solid var(--line); display: grid; gap: 8px; }
.post-body li { display: flex; gap: 10px; font-weight: 500; }
.post-body li::before { content: "+"; flex: none; width: 18px; color: #3dff8a; font-family: var(--display); font-weight: 700; }
.post-body ol li::before { content: none; }
.post-body blockquote { margin: 24px 0; padding: 14px 20px; border-left: 3px solid var(--neon-2); background: rgb(255 43 214 / .06); }
.post-foot { margin-top: 32px; padding-top: 14px; border-top: 1px dashed var(--line); font-size: .92rem; color: var(--muted); }
.post-foot a { color: var(--neon); font-weight: 600; }

.meta-panel { position: sticky; top: 16px; background: var(--surface); border: 1px solid var(--line); padding: 20px; }
.meta-author { display: flex; align-items: center; gap: 12px; padding-bottom: 14px; border-bottom: 1px dashed var(--line); }
.meta-author p { margin: 0; display: flex; flex-direction: column; line-height: 1.35; min-width: 0; }
.meta-author a { font-family: var(--display); font-weight: 700; color: var(--neon); padding: 2px 0; }
.meta-k, .meta-list dt { font-family: var(--display); font-size: .7rem; font-weight: 700; letter-spacing: .16em; color: var(--muted); }
.avatar {
  width: 46px; height: 46px; display: grid; place-items: center; flex: none;
  background: linear-gradient(140deg, var(--neon), var(--neon-2)); color: var(--neon-ink);
  font-family: var(--display); font-weight: 700; font-size: 1.2rem;
  clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%);
}
.meta-list { margin: 0; display: grid; gap: 12px; padding-top: 14px; }
.meta-list div { display: flex; flex-direction: column; }
.meta-list dd { margin: 0; font-size: .92rem; line-height: 1.45; }
.meta-list dd a { color: var(--neon); font-weight: 600; display: inline-block; padding: 2px 0; }
.more-like { margin-top: 56px; }

/* ---------- footer ---------- */
.site-footer { margin-top: 72px; background: var(--chrome); border-top: 1px solid var(--chrome-line); color: var(--muted); font-size: .9rem; position: relative; }
.site-footer::before { content: ""; display: block; height: 2px; background: linear-gradient(90deg, var(--neon), var(--neon-2)); box-shadow: 0 0 16px rgb(255 43 214 / .5); }
.site-footer a { color: var(--text); }
.site-footer a:hover { color: var(--neon); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: 48px; padding-top: 36px; padding-bottom: 28px; }
.footer-brand p { margin: 12px 0 0; line-height: 1.7; max-width: 42ch; }
.footer-title { margin: 2px 0 12px; color: var(--neon); font-family: var(--display); font-weight: 700; font-size: .9rem; letter-spacing: .14em; }
.footer-latest { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 24px; }
.footer-latest a { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.5; font-weight: 500; padding: 1px 0; }
.footer-latest time { display: block; margin-top: 2px; font-size: .76rem; }
.footer-bottom-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 12px; padding-bottom: 14px; border-top: 1px solid var(--chrome-line); font-size: .82rem; font-family: var(--display); }
.footer-bottom-row p { margin: 0; }
.site-footer .to-top { display: inline-block; padding: 6px 0; color: var(--neon); }

/* ---------- responsive ---------- */
@media (max-width: 1240px) {
  .tile-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .patch-layout { grid-template-columns: minmax(0, 1fr) 250px; gap: 32px; }
}
@media (max-width: 1100px) {
  .browse { grid-template-columns: minmax(0, 1fr); }
  .trending { position: static; }
  .trending ol { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; }
  .trending li:nth-child(2) { border-top: 0; }
  .shots { grid-template-columns: minmax(0, 1fr); gap: 10px; }
}
/* tablet / phone: sidebar collapses to a compact top bar with a horizontally scrolling nav */
@media (max-width: 900px) {
  .app { display: block; }
  .wrap { padding: 0 16px; }
  .sidebar {
    position: relative; height: auto; overflow: visible; padding: 10px 0 0; gap: 8px;
    border-right: 0; border-bottom: 1px solid var(--chrome-line);
  }
  .sidebar::after { top: auto; bottom: -1px; left: 0; right: 0; width: auto; height: 2px; background: linear-gradient(90deg, transparent, var(--neon) 20%, var(--neon-2) 80%, transparent); }
  .side-brand { padding: 0 16px; }
  .hud-mini { display: inline-flex; }
  .side-label, .online-box { display: none; }
  .side-nav ul { flex-direction: row; gap: 4px; overflow-x: auto; padding: 0 16px 10px; scrollbar-width: none; }
  .side-nav ul::-webkit-scrollbar { display: none; }
  .side-nav a { min-height: 40px; padding: 4px 12px 4px 6px; gap: 8px; font-size: .92rem; border-color: var(--line); background: var(--surface); }
  .nav-ico { width: 28px; height: 28px; font-size: .92rem; }
  .nav-count { display: none; }
  .side-nav a[aria-current="page"]::before { left: 6px; right: 6px; top: auto; bottom: -1px; width: auto; height: 2px; }
  .patch-layout { grid-template-columns: minmax(0, 1fr); }
  .meta-panel { position: static; order: -1; }
  .meta-list { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
  .footer-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .logo-text { font-size: 1.2rem; }
  .feature { aspect-ratio: auto; min-height: 400px; }
  .feature::before { background: linear-gradient(0deg, rgb(7 7 15 / .97) 0%, rgb(7 7 15 / .7) 55%, rgb(7 7 15 / .1) 100%); }
  .feature-body { padding: 20px; }
  .shot { grid-template-columns: 104px minmax(0, 1fr); }
  .tile-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .tile-body { padding: 8px 10px 10px; }
  .tile h3 { font-size: .92rem; }
  .trending ol { grid-template-columns: minmax(0, 1fr); }
  .trending li:nth-child(2) { border-top: 1px dashed var(--line); }
  .shelf { grid-auto-columns: 200px; }
  .game-info { flex-direction: column; align-items: flex-start; gap: 12px; padding: 22px 20px; }
  .game-icon { width: 68px; height: 68px; font-size: 2rem; }
  .game-stats li { flex-basis: 100px; padding: 8px 12px; }
  .footer-latest { grid-template-columns: minmax(0, 1fr); }
  .footer-bottom-row { flex-direction: column; align-items: flex-start; gap: 0; }
}
@media (max-width: 380px) {
  .tile-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
  .pulse, .hud-dot, .logo:hover .logo-text { animation: none; }
  .ticker-track { animation: none; }
  .ticker-view { overflow-x: auto; }
  .ticker-track li[aria-hidden] { display: none; }
}

/* ad slots: code comes from the admin app (zone ads) */
.ad-slot { display: flex; flex-direction: column; align-items: center; gap: 16px; margin: 24px auto; max-width: 1280px; padding: 0 16px; text-align: center; overflow: hidden; }
.ad-unit { width: 100%; max-width: 100%; overflow: hidden; }
.post-body + .ad-slot, .post-cover + .ad-slot { padding: 0; }

/* empty state: no posts yet */
.empty { margin-top: 0; text-align: center; padding: 64px 24px; background: var(--surface); border: 1px solid var(--line); clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut))); }
.empty-ico { font-size: 3rem; margin: 0; filter: drop-shadow(0 0 14px rgb(0 240 255 / .6)); }
.empty h2 { font-size: 1.8rem; margin: 12px 0 6px; color: var(--neon); text-shadow: var(--glow); }
.empty p { margin: 0; color: var(--muted); }

/* broken image: replaced by the site logo (script in layout.html), centred on the logo's own background */
img.img-fallback { object-fit: contain !important; background: #07070f; filter: none !important; }
.post-body img.img-fallback, .post-cover img.img-fallback { aspect-ratio: 16/9; max-height: 420px; }

/* mobile: the last breadcrumb (article title) shrinks to the screen instead of pushing the page wider */
.crumbs li:last-child { display: flex; min-width: 0; max-width: 100%; }
.crumbs li:last-child span { min-width: 0; max-width: 60ch; }

/* sidebar ad zone: fits the column it sits in */
.ad-slot.ad-sidebar { margin: 0 0 16px; padding: 0; max-width: 100%; }
/* an ad never widens the page: the slot takes its parent's width and clips anything wider */
.ad-slot { width: 100%; min-width: 0; box-sizing: border-box; }
.ad-unit > * { max-width: 100%; }
