/* playbuff — a downloadable-only mod catalogue.
   Dark, catalogue-style layout: top nav, game pages, per-mod pages. */

:root {
  --bg: #0c0e13;
  --bg-deep: #08090d;
  --panel: #14171e;
  --panel-2: #1b1f27;
  --panel-3: #222733;
  --line: rgba(255, 255, 255, .07);
  --line-2: rgba(255, 255, 255, .13);
  --text: #e9ecf2;
  --muted: #9da5b6;
  --faint: #6e7688;
  --accent: #f0a94a;
  --accent-2: #ffc069;
  --accent-dim: rgba(240, 169, 74, .13);
  --green: #7cc27f;
  --red: #e0705f;
  --blue: #64a4dd;
  --radius: 12px;
  --radius-sm: 8px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: Manrope, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif; font-size: 14px; line-height: 1.55; }
button, input, select { font: inherit; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent-2); }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
img { display: block; }
h1, h2, h3, h4 { letter-spacing: -.02em; margin: 0; }
.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; }
.mono { font-family: 'DM Mono', monospace; }
.container { max-width: 1440px; margin: 0 auto; padding: 0 26px; width: 100%; }
.view { min-height: calc(100vh - 62px - 64px); padding-bottom: 64px; }
.loading-block { color: var(--faint); font-family: 'DM Mono', monospace; font-size: 12px; padding-top: 90px; }

/* ---------------- header ---------------- */
.site-header { position: sticky; top: 0; z-index: 30; background: var(--bg-deep); border-bottom: 1px solid var(--line); }
.header-inner { max-width: 1440px; margin: 0 auto; padding: 0 26px; height: 64px; display: flex; align-items: center; gap: 34px; }
.brand { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; }
.brand-logo { display: block; height: 30px; width: auto; }
.brand:hover .brand-logo { opacity: .88; }
.main-nav { display: flex; gap: 4px; flex: 1 1 auto; min-width: 0; }
.main-nav a { color: var(--muted); font-size: 13px; font-weight: 600; padding: 8px 13px; border-radius: var(--radius-sm); white-space: nowrap; }
.main-nav a:hover { color: var(--text); background: rgba(255, 255, 255, .05); }
.main-nav a.is-active { color: var(--accent-2); background: var(--accent-dim); box-shadow: inset 0 -2px 0 var(--accent); }
.header-tools { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; margin-left: auto; }
.search-field { display: flex; align-items: center; gap: 8px; background: rgba(255, 255, 255, .055); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; width: min(300px, 30vw); }
.search-field:focus-within { border-color: var(--accent); background: rgba(255, 255, 255, .08); }
.search-field svg { width: 14px; height: 14px; color: var(--faint); flex: 0 0 auto; }
.search-field input { border: 0; outline: 0; background: transparent; color: var(--text); min-width: 0; width: 100%; font-size: 13px; }
.search-field input::placeholder { color: var(--faint); }

/* language switch (zh-Hant / en) */
.lang-switch { display: inline-flex; border: 1px solid var(--line-2); border-radius: var(--radius-sm); overflow: hidden; flex: 0 0 auto; }
.lang-switch button { border: 0; background: transparent; color: var(--faint); font: 600 11px 'DM Mono', monospace; letter-spacing: .04em; padding: 7px 10px; cursor: pointer; transition: background .15s, color .15s; }
.lang-switch button + button { border-left: 1px solid var(--line); }
.lang-switch button:hover { color: var(--text); background: rgba(255, 255, 255, .06); }
.lang-switch button.is-active { background: var(--accent-dim); color: var(--accent-2); }

/* small inline tag (genres & co.) */
.tag { display: inline-flex; align-items: center; border: 1px solid var(--line-2); border-radius: 999px; color: var(--muted); font-size: 11px; padding: 2px 10px; margin: 2px 3px 2px 0; white-space: nowrap; }

/* ---------------- buttons & chips ---------------- */
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: rgba(255, 255, 255, .04); color: var(--text); padding: 10px 16px; cursor: pointer; font-size: 13px; font-weight: 600; transition: background .15s, border-color .15s, color .15s, box-shadow .15s; }
.button svg { width: 14px; height: 14px; }
.button:hover { background: rgba(255, 255, 255, .09); }
.button:disabled { opacity: .55; cursor: wait; }
.button-primary { background: var(--accent); border-color: var(--accent); color: #221503; box-shadow: 0 4px 16px rgba(240, 169, 74, .18); }
.button-primary:hover { background: var(--accent-2); border-color: var(--accent-2); color: #221503; box-shadow: 0 6px 20px rgba(240, 169, 74, .28); }
.button-quiet { color: var(--muted); }
.button-quiet:hover { color: var(--text); border-color: var(--muted); }
.button-large { padding: 12px 16px; font-size: 14px; width: 100%; }
.button-block { width: 100%; margin-top: 12px; }
.button svg { flex: 0 0 auto; }

.chip-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.chip { background: transparent; border: 1px solid var(--line); color: var(--muted); border-radius: 999px; padding: 5px 12px; font-size: 12px; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.chip:hover { color: var(--text); border-color: var(--line-2); }
.chip.is-selected { background: var(--accent-dim); border-color: var(--accent); color: var(--accent-2); }
.chip .count { color: var(--faint); margin-left: 5px; font-family: 'DM Mono', monospace; font-size: 10px; }
.chip.is-selected .count { color: var(--accent); }

.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 3px; letter-spacing: .04em; white-space: nowrap; }
.badge.ok { background: rgba(124, 194, 127, .13); color: var(--green); }
.badge.warn { background: rgba(218, 142, 53, .15); color: var(--accent-2); }
.badge.err { background: rgba(224, 112, 95, .14); color: var(--red); }
.badge.off { background: rgba(255, 255, 255, .07); color: var(--muted); }
.badge.ghost { background: rgba(255, 255, 255, .05); color: var(--faint); font-weight: 500; }
.badge.stale { background: rgba(100, 164, 221, .13); color: var(--blue); }

/* ---------------- home banners (featured) ---------------- */
.hero-banners { padding: 26px 0 6px; }

.banner-main { position: relative; display: block; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--panel); height: clamp(260px, 34vw, 420px); color: var(--text); }
.banner-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .7s ease; pointer-events: none; }
.banner-slide.is-active { opacity: 1; pointer-events: auto; }
.banner-slide img.banner-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.banner-shade { position: absolute; inset: 0; background:
  linear-gradient(180deg, rgba(8, 9, 13, .10) 26%, rgba(8, 9, 13, .58) 70%, rgba(8, 9, 13, .92) 100%),
  linear-gradient(100deg, rgba(8, 9, 13, .82) 0%, rgba(8, 9, 13, .38) 46%, rgba(8, 9, 13, 0) 74%); }
.banner-fallback { position: absolute; inset: 0; display: grid; place-items: center; color: var(--faint); font-size: 70px; font-weight: 800; letter-spacing: .04em; }
.banner-fallback span { opacity: .4; }
.banner-tag { position: absolute; top: 22px; left: 42px; background: var(--accent); color: #221503; font: 700 10px/1 'DM Mono', monospace; letter-spacing: .14em; padding: 6px 10px; border-radius: 6px; }
.banner-copy { position: absolute; left: 42px; right: 42px; bottom: 34px; max-width: 640px; }
.banner-copy h1 { font-size: clamp(28px, 3.2vw, 46px); font-weight: 800; letter-spacing: -.02em; }
.banner-copy .banner-sub { color: var(--muted); font-size: 13px; margin: 10px 0 0; }
.banner-copy .banner-cta { margin-top: 18px; display: inline-flex; }
.banner-dots { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); display: flex; gap: 8px; }
.banner-dot { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .34); cursor: pointer; transition: background .2s, transform .2s; }
.banner-dot.is-active { background: var(--accent); transform: scale(1.2); }
.banner-main:hover { border-color: rgba(240, 169, 74, .45); }

.banner-mini-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 16px; }
.banner-mini { display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .16s, border-color .16s, background .16s; color: var(--text); }
.banner-mini:hover { transform: translateY(-3px); border-color: rgba(240, 169, 74, .5); background: var(--panel-2); color: var(--text); }
.banner-mini-cover { position: relative; aspect-ratio: 16 / 9; background: var(--panel-3); overflow: hidden; }
.banner-mini-cover img { width: 100%; height: 100%; object-fit: cover; opacity: .92; transition: opacity .2s, transform .25s; }
.banner-mini:hover .banner-mini-cover img { opacity: 1; transform: scale(1.03); }
.banner-mini-cover .game-cover-fallback { font-size: 40px; }
.banner-mini-body { padding: 13px 16px 15px; }
.banner-mini-body strong { display: block; font-size: 15px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.banner-mini-body span { display: block; color: var(--faint); font-size: 12px; margin-top: 4px; }

.stat-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 36px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; }
.stat-value { font-size: 26px; font-weight: 800; line-height: 1.1; }
.stat-value.accent { color: var(--accent-2); }
.stat-label { color: var(--faint); font: 10px 'DM Mono', monospace; letter-spacing: .08em; text-transform: uppercase; margin-top: 6px; }

/* ---------------- sections ---------------- */
.section { margin-top: 46px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.section-head h2 { font-size: 21px; font-weight: 800; }
.section-head .hint { color: var(--faint); font-size: 12px; }
.section-link { color: var(--accent-2); font-size: 13px; font-weight: 600; white-space: nowrap; }

/* ---------------- game grid ---------------- */
.game-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(272px, 1fr)); gap: 16px; }
.game-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .16s, border-color .16s, background .16s; display: flex; flex-direction: column; }
.game-card:hover { transform: translateY(-3px); border-color: rgba(240, 169, 74, .5); background: var(--panel-2); color: var(--text); }
.game-cover { position: relative; aspect-ratio: 460 / 215; background: var(--panel-3); overflow: hidden; }
.game-cover img { width: 100%; height: 100%; object-fit: cover; opacity: .9; transition: opacity .2s, transform .25s; }
.game-card:hover .game-cover img { opacity: 1; transform: scale(1.03); }
.game-cover-fallback { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: var(--panel-3); color: var(--faint); font-size: 44px; font-weight: 800; letter-spacing: .04em; }
.game-cover-fallback span { opacity: .5; }
.game-hero.no-cover { min-height: 190px; }
.game-rank { position: absolute; top: 8px; left: 8px; background: rgba(8, 9, 13, .82); color: var(--accent-2); font: 500 10px 'DM Mono', monospace; padding: 3px 6px; border-radius: 3px; }
.game-body { padding: 14px 16px 15px; display: flex; flex-direction: column; gap: 7px; flex: 1 1 auto; }
.game-name { font-size: 15px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.game-meta { color: var(--muted); font-size: 11.5px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 35px; }
.game-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--faint); }
.game-tags { display: flex; gap: 6px; margin-top: auto; padding-top: 6px; flex-wrap: wrap; }

/* ---------------- mod rows ---------------- */
.mod-rows { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--panel); }
.mod-row { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto 16px; gap: 15px; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); background: var(--panel); transition: background .13s; color: var(--text); }
.mod-row:last-child { border-bottom: 0; }
.mod-row:hover { background: var(--panel-2); color: var(--text); }
.mod-row.is-error { opacity: .75; }
.mod-icon { width: 42px; height: 42px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--panel-2); display: grid; place-items: center; color: var(--accent); overflow: hidden; }
.mod-icon img { width: 100%; height: 100%; object-fit: cover; }
.mod-icon svg { width: 16px; height: 16px; }
.mod-info { min-width: 0; }
.mod-title { font-size: 14px; font-weight: 700; display: flex; align-items: center; gap: 8px; min-width: 0; }
.mod-title .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mod-summary { color: var(--muted); font-size: 12px; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mod-meta { display: flex; align-items: center; gap: 14px; color: var(--faint); font-size: 11px; font-family: 'DM Mono', monospace; white-space: nowrap; }
.mod-meta .sep { color: var(--line-2); }
.mod-arrow { color: var(--faint); display: grid; place-items: center; }
.mod-arrow svg { width: 14px; height: 14px; }
.mod-row:hover .mod-arrow { color: var(--accent); }
.mod-row:hover .mod-title .name { color: var(--accent-2); }

/* ---------------- browse toolbar ---------------- */
.page-head { padding: 34px 0 6px; }
.page-head h1 { font-size: 30px; font-weight: 800; }
.page-head .hint { color: var(--faint); font-size: 12px; margin-top: 6px; }
.toolbar { display: flex; flex-direction: column; gap: 10px; padding: 18px 0 20px; }
.toolbar-group { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.toolbar-label { color: var(--faint); font: 10px 'DM Mono', monospace; letter-spacing: .1em; text-transform: uppercase; flex: 0 0 auto; min-width: 48px; }
.games-search { display: flex; align-items: center; gap: 8px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 9px 13px; width: min(420px, 100%); }
.games-search:focus-within { border-color: var(--accent); }
.games-search svg { width: 14px; height: 14px; color: var(--faint); flex: 0 0 auto; }
.games-search input { border: 0; outline: 0; background: transparent; color: var(--text); width: 100%; font-size: 13px; }
.games-search input::placeholder { color: var(--faint); }
.section-head-inline { padding: 34px 0 14px; }
.section-head-inline h2 { font-size: 19px; }

/* ---------------- screenshots ---------------- */
.shot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; }
.shot { padding: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-deep); cursor: zoom-in; overflow: hidden; aspect-ratio: 16 / 10; transition: border-color .15s, transform .15s; }
.shot:hover { border-color: var(--accent); transform: translateY(-2px); }
.shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shot.is-broken { display: none; }

.lightbox { position: fixed; inset: 0; z-index: 60; background: rgba(8, 10, 14, .93); display: grid; place-items: center; padding: 40px 24px; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 4px; box-shadow: 0 24px 70px rgba(0, 0, 0, .6); }
.lightbox-close { position: absolute; top: 20px; right: 22px; width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: rgba(255, 255, 255, .06); color: var(--text); cursor: pointer; }
.lightbox-close:hover { background: rgba(255, 255, 255, .14); }
.lightbox-close svg { width: 17px; height: 17px; }
body.dialog-open { overflow: hidden; }

/* ---------------- breadcrumb ---------------- */
.breadcrumb { display: flex; align-items: center; gap: 8px; color: var(--faint); font-size: 12px; padding: 20px 0 0; flex-wrap: wrap; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--accent-2); }
.breadcrumb svg { width: 12px; height: 12px; }
.breadcrumb .current { color: var(--text); font-weight: 600; max-width: 46ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------------- game hero ---------------- */
.game-hero { position: relative; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-top: 20px; min-height: 300px; display: flex; align-items: flex-end; background: var(--panel); }
.game-hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .5; }
.game-hero-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8, 9, 13, .18) 0%, rgba(8, 9, 13, .74) 60%, rgba(8, 9, 13, .94) 100%); }
.game-hero-content { position: relative; padding: 30px 34px 28px; width: 100%; }
.game-hero-content h1 { font-size: clamp(28px, 3.2vw, 42px); font-weight: 800; letter-spacing: -.02em; }
.game-hero-meta { display: flex; gap: 18px; flex-wrap: wrap; color: var(--muted); font-size: 12px; margin-top: 10px; font-family: 'DM Mono', monospace; }
.game-hero-meta strong { color: var(--text); font-weight: 500; }
.game-hero-detail { color: var(--muted); font-size: 13px; margin-top: 10px; max-width: 720px; }
.game-hero-actions { margin-top: 18px; display: flex; gap: 10px; flex-wrap: wrap; }
.game-hero-genres { display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: 10px; }
.game-hero-genres .tag { border-color: rgba(255, 255, 255, .22); color: #d7dce7; background: rgba(8, 9, 13, .55); }

/* game info: about + facts */
.game-info-grid { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 22px; margin-top: 20px; align-items: start; }
.game-info-grid .panel { margin-top: 0; }
.game-about.is-clamped { max-height: 320px; overflow: hidden; position: relative; }
.game-about.is-clamped::after { content: ""; position: absolute; inset: auto 0 0 0; height: 90px; background: linear-gradient(180deg, rgba(20, 23, 30, 0) 0%, rgba(20, 23, 30, .97) 78%); pointer-events: none; }
.game-about-panel .about-toggle { margin-top: 12px; }
.game-about-panel .about-toggle[hidden] { display: none; }
.game-facts-panel .meta-list dd .tag { margin-top: 2px; }

/* ---------------- mod detail page ---------------- */
.mod-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 22px; margin-top: 20px; align-items: start; }
.mod-head { display: flex; gap: 16px; align-items: flex-start; }
.mod-head-icon { width: 76px; height: 76px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); overflow: hidden; display: grid; place-items: center; color: var(--accent); flex: 0 0 auto; }
.mod-head-icon img { width: 100%; height: 100%; object-fit: cover; }
.mod-head-icon svg { width: 26px; height: 26px; }
.mod-head h1 { font-size: clamp(22px, 2.6vw, 30px); font-weight: 800; line-height: 1.25; }
.mod-head-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; color: var(--muted); font-size: 12px; margin-top: 9px; font-family: 'DM Mono', monospace; }
.mod-head-meta .sep { color: var(--faint); }
.mod-lede { color: var(--muted); font-size: 14px; margin: 18px 0 0; }

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; margin-top: 18px; }
.panel-title { display: flex; align-items: center; gap: 9px; font-size: 15px; font-weight: 800; margin-bottom: 14px; }
.panel-title svg { width: 16px; height: 16px; color: var(--accent); }
.panel-title .sub { color: var(--faint); font-size: 11px; font-weight: 400; font-family: 'DM Mono', monospace; margin-left: auto; }

.guide-title { font-size: 13px; font-weight: 700; color: var(--accent-2); margin: 0 0 10px; }
.guide-steps { margin: 0; padding: 0 0 0 4px; list-style: none; counter-reset: step; display: flex; flex-direction: column; gap: 9px; }
.guide-steps li { position: relative; padding-left: 34px; color: var(--muted); font-size: 13px; line-height: 1.65; counter-increment: step; }
.guide-steps li::before { content: counter(step, decimal-leading-zero); position: absolute; left: 0; top: 1px; color: var(--accent); font: 500 11px 'DM Mono', monospace; border: 1px solid var(--line-2); border-radius: 3px; padding: 1px 5px; }
.guide-note { border-left: 2px solid var(--accent); background: var(--accent-dim); color: var(--muted); font-size: 12px; line-height: 1.7; padding: 10px 13px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; margin: 14px 0 0; }

.mod-description { color: var(--muted); font-size: 13px; line-height: 1.8; }
.mod-description p { margin: 0 0 10px; }
.mod-description h4 { color: var(--text); font-size: 14px; margin: 16px 0 8px; }
.mod-description ul { margin: 0 0 10px; padding-left: 20px; }
.mod-description blockquote { margin: 0 0 10px; padding: 6px 12px; border-left: 2px solid var(--line-2); color: var(--faint); }

.file-meta, .meta-list { margin: 0; display: flex; flex-direction: column; }
.file-meta > div, .meta-list > div { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.file-meta > div:last-child, .meta-list > div:last-child { border-bottom: 0; }
.file-meta dt, .meta-list dt { color: var(--faint); font: 10px 'DM Mono', monospace; letter-spacing: .06em; text-transform: uppercase; }
.file-meta dd, .meta-list dd { margin: 0; color: var(--text); font-size: 12.5px; overflow-wrap: anywhere; }
.file-meta dd.hash { font-family: 'DM Mono', monospace; font-size: 11px; color: var(--muted); word-break: break-all; }
.file-meta dd a { color: var(--blue); }

.download-card { padding: 18px 20px 20px; }
.download-state { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); margin-bottom: 12px; font-family: 'DM Mono', monospace; }
.download-size { color: var(--faint); font-size: 11px; text-align: center; margin-top: 10px; font-family: 'DM Mono', monospace; }
.download-note { color: var(--muted); font-size: 12px; line-height: 1.65; margin: 12px 0 0; }
.download-note strong { color: var(--accent-2); }
.mod-side { position: sticky; top: 78px; }
.mod-side .panel:first-child { margin-top: 0; }

.notice { border-radius: var(--radius-sm); border: 1px solid var(--line); padding: 12px 15px; font-size: 12.5px; line-height: 1.65; margin-top: 18px; display: flex; gap: 10px; align-items: flex-start; }
.notice svg { width: 15px; height: 15px; flex: 0 0 auto; margin-top: 2px; }
.notice.warn { background: rgba(100, 164, 221, .08); border-color: rgba(100, 164, 221, .35); color: var(--muted); }
.notice.warn svg { color: var(--blue); }
.notice.err { background: rgba(224, 112, 95, .08); border-color: rgba(224, 112, 95, .3); color: var(--muted); }
.notice.err svg { color: var(--red); }

/* ---------------- source table ---------------- */
.source-table-wrap { border: 1px solid var(--line); border-radius: var(--radius); overflow: auto; background: var(--panel); }
.source-table { border-collapse: collapse; width: 100%; min-width: 720px; text-align: left; }
.source-table th { color: var(--faint); font: 10px 'DM Mono', monospace; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; background: var(--bg-deep); padding: 12px 16px; border-bottom: 1px solid var(--line); }
.source-table td { padding: 12px 16px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 12.5px; vertical-align: top; }
.source-table tr:last-child td { border-bottom: 0; }
.source-table td:first-child { color: var(--text); font-weight: 700; }
.adapter { color: var(--accent-2); font-family: 'DM Mono', monospace; font-size: 11px; }
.source-status { display: inline-flex; gap: 7px; align-items: center; font-size: 11px; font-family: 'DM Mono', monospace; color: var(--green); }
.source-status.limited { color: var(--blue); }
.src-note { font-size: 12px; color: var(--faint); }
.sync-footnote { color: var(--faint); font-size: 12px; margin-top: 14px; display: flex; gap: 8px; align-items: center; }
.sync-footnote svg { width: 14px; height: 14px; color: var(--green); flex: 0 0 auto; }

/* ---------------- misc ---------------- */
.list-foot { display: flex; justify-content: center; padding: 22px 0 4px; }
.list-foot .button { min-width: 240px; }
.dep-block { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 14px; }
.dep-title { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; color: var(--text); }
.dep-title svg { width: 14px; height: 14px; color: var(--accent); }
.dep-hint { color: var(--faint); font-size: 12px; margin: 6px 0 10px; }
.dep-list { display: flex; flex-wrap: wrap; gap: 6px; }
.dep-item { background: rgba(255, 255, 255, .05); border: 1px solid var(--line); border-radius: 6px; padding: 4px 9px; font: 11px 'DM Mono', monospace; color: var(--muted); }
.empty-state { border: 1px dashed var(--line-2); border-radius: var(--radius); color: var(--faint); padding: 26px; font-size: 12.5px; }
.toast { position: fixed; bottom: 24px; right: 24px; background: var(--panel-3); border: 1px solid var(--line-2); color: var(--text); padding: 12px 16px; border-radius: var(--radius-sm); font-size: 12.5px; transform: translateY(140%); transition: transform .22s; z-index: 40; max-width: min(420px, 84vw); box-shadow: 0 10px 30px rgba(0, 0, 0, .4); }
.toast.is-visible { transform: translateY(0); }
.site-footer { border-top: 1px solid var(--line); background: var(--bg-deep); }
.footer-inner { display: flex; justify-content: space-between; gap: 12px; color: var(--faint); font-size: 12px; padding-top: 20px; padding-bottom: 20px; flex-wrap: wrap; }
.footer-inner .mono { font-size: 11px; }

@keyframes spin { to { transform: rotate(360deg); } }
.is-busy svg { animation: spin 1s linear infinite; }

@media (max-width: 1120px) {
  .mod-layout { grid-template-columns: minmax(0, 1fr); }
  .mod-side { position: static; }
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .header-inner { gap: 16px; flex-wrap: wrap; height: auto; padding: 10px 20px; }
  .main-nav { order: 3; flex: 1 1 100%; overflow-x: auto; }
  .search-field { width: min(210px, 42vw); }
  .container { padding: 0 18px; }
  .mod-row { grid-template-columns: 38px minmax(0, 1fr) 14px; }
  .mod-row .mod-meta { display: none; }
  .mod-head { flex-direction: column; }
  .game-hero-content { padding: 20px; }
  .game-info-grid { grid-template-columns: minmax(0, 1fr); }
  .banner-mini-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .banner-copy { left: 24px; right: 24px; bottom: 26px; }
  .banner-tag { left: 24px; top: 18px; }
}
@media (max-width: 560px) {
  .game-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .game-name { font-size: 13px; }
  .stat-strip { grid-template-columns: 1fr 1fr; }
  .header-tools .sync-button span { display: none; }
  .file-meta > div, .meta-list > div { grid-template-columns: 92px minmax(0, 1fr); }
  .page-head h1 { font-size: 24px; }
  .lang-switch button { padding: 7px 8px; }
  .banner-mini-row { grid-template-columns: minmax(0, 1fr); }
  .banner-main { height: clamp(240px, 62vw, 340px); }
  .banner-copy h1 { font-size: 26px; }
  .banner-copy { left: 18px; right: 18px; bottom: 30px; }
  .banner-tag { left: 18px; top: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
