/* SR-Source Mods: the launcher's look (dark, lime, Teko). */

@font-face {
  font-family: "Teko";
  src: url("fonts/teko-bold.woff") format("woff");
  font-weight: 600 700;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #07090a;
  --bg-alt: #0b0f0e;
  --panel: #101614;
  --panel-2: #151d1a;
  --line: rgba(184, 255, 46, 0.13);
  --line-strong: rgba(184, 255, 46, 0.42);
  --text: #e8f1ea;
  --muted: #94a59a;
  --faint: #66756c;
  --accent: #b8ff2e;
  --accent-hover: #ccff66;
  --accent-ink: #0b1200;
  --sr: #ffc23b;
  --zg: #3be0ff;
  --radius: 12px;
  --gutter: 16px;
  --display: "Teko", "Arial Narrow", "Roboto Condensed", system-ui, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Hiragino Sans",
    "Yu Gothic UI", "Noto Sans JP", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
img { max-width: 100%; display: block; }
code {
  font: 0.88em/1.4 ui-monospace, "Cascadia Mono", "DejaVu Sans Mono", monospace;
  background: var(--panel-2);
  border: 1px solid var(--line);
  padding: 0.05em 0.35em;
  border-radius: 5px;
  overflow-wrap: anywhere;
}

.wrap { width: min(1180px, 100% - 2 * var(--gutter)); margin-inline: auto; }

.skip {
  position: absolute; left: -999px; top: 8px; z-index: 10;
  background: var(--accent); color: var(--accent-ink); padding: 8px 14px; border-radius: 8px;
}
.skip:focus { left: 8px; }

.display {
  font-family: var(--display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 0.9;
}
html[lang="ja"] .section-head .display { font-family: var(--body); font-weight: 800; letter-spacing: 0; }

/* ---- Header ---- */

.top {
  position: sticky; top: 0; z-index: 5;
  background: rgba(7, 9, 10, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.top-row { display: flex; align-items: center; gap: 24px; height: 60px; }
.brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--text); text-decoration: none;
  font: 700 26px/1 var(--display); text-transform: uppercase; letter-spacing: 0.02em;
  padding-top: 4px;
}
.brand img { border-radius: 7px; margin-top: -4px; }
.brand b { color: var(--accent); font-weight: 700; }
.brand:hover { color: var(--text); }
.nav { display: flex; gap: 22px; margin-left: auto; font-size: 15px; }
.nav a { color: var(--muted); text-decoration: none; }
.nav a:hover { color: var(--text); }
.ext::after { content: " ↗"; font-size: 0.85em; }
.lang {
  display: flex; border: 1px solid var(--line-strong); border-radius: 999px; padding: 2px;
}
.lang button {
  font: 600 13px/1 var(--body); color: var(--muted);
  background: none; border: 0; border-radius: 999px; padding: 7px 11px; cursor: pointer;
}
.lang button:hover { color: var(--text); }
.lang button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); }

/* ---- Hero ---- */

.hero {
  position: relative;
  background: #000 url("img/floor.jpg") center bottom / cover no-repeat;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.1) 55%, transparent);
  pointer-events: none;
}
.hero::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 90px;
  background: linear-gradient(transparent, var(--bg));
  pointer-events: none;
}
.hero-row {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  align-items: center; gap: 48px;
  padding: 72px 0 120px;
}
.kicker {
  margin: 0 0 6px;
  font: 700 24px/1 var(--display); text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--accent);
}
html[lang="ja"] .kicker { font: 700 17px/1.2 var(--body); letter-spacing: 0.06em; }
h1.display {
  margin: 0;
  font-size: clamp(96px, 14vw, 176px);
  transform: skewX(-9deg);
  transform-origin: left bottom;
  color: var(--text);
  text-shadow: 0 0 40px rgba(184, 255, 46, 0.22);
}
.lead { margin: 18px 0 28px; max-width: 34em; color: #c9d6cd; font-size: 17px; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 12px 22px; border-radius: 10px;
  font: 600 15px/1 var(--body); text-decoration: none;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s, transform 0.15s;
}
.btn-solid { background: var(--accent); color: var(--accent-ink); }
.btn-solid:hover { background: var(--accent-hover); color: var(--accent-ink); transform: translateY(-1px); }
.btn-ghost { border: 1px solid var(--line-strong); color: var(--text); background: rgba(0, 0, 0, 0.35); }
.btn-ghost:hover { border-color: var(--accent); color: var(--text); }
.hero-art img {
  width: 100%; height: auto;
  border-radius: 14px;
  border: 1px solid var(--line-strong);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.6), 0 24px 60px rgba(0, 0, 0, 0.7),
    0 0 60px rgba(184, 255, 46, 0.12);
  transform: perspective(1400px) rotateY(-9deg) rotateX(2deg);
}

/* ---- Sections ---- */

.section { padding: 72px 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }
.section-head {
  display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between;
  gap: 16px; margin-bottom: 28px;
}
.section-head h2 {
  margin: 0; font-size: 56px; position: relative; padding-bottom: 10px;
}
.section-head h2::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 56px; height: 4px; background: var(--accent); border-radius: 2px;
}
html[lang="ja"] .section-head h2 { font-size: 34px; line-height: 1.2; }

.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filters button {
  font: 600 14px/1 var(--body); color: var(--muted);
  background: var(--panel); border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 14px; cursor: pointer;
}
.filters button:hover { color: var(--text); border-color: var(--line-strong); }
.filters button[aria-pressed="true"] { color: var(--accent-ink); background: var(--accent); border-color: var(--accent); }

/* ---- Mod cards ---- */

.grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr));
  gap: 22px;
}
.card {
  display: flex; flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.card:hover {
  border-color: var(--line-strong);
  transform: translateY(-3px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5), 0 0 30px rgba(184, 255, 46, 0.08);
}
.card[hidden] { display: none; }
.thumb { position: relative; aspect-ratio: 16 / 9; background: #000; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb-empty {
  display: grid; place-items: center; height: 100%; padding: 48px 16px 16px;
  background:
    linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.2) 55%, transparent 100%),
    repeating-linear-gradient(90deg, rgba(184, 255, 46, 0.18) 0 1px, transparent 1px 44px),
    repeating-linear-gradient(0deg, rgba(184, 255, 46, 0.18) 0 1px, transparent 1px 30px),
    #031006;
}
.thumb-empty span {
  font: 700 clamp(34px, 6vw, 48px)/0.9 var(--display); text-transform: uppercase;
  color: var(--accent); text-align: center; transform: skewX(-9deg);
  text-shadow: 0 0 24px rgba(184, 255, 46, 0.35);
  overflow-wrap: anywhere;
}
.badge {
  position: absolute; left: 12px; top: 12px;
  display: inline-flex; align-items: center; gap: 7px;
  font: 700 17px/1 var(--display); text-transform: uppercase; letter-spacing: 0.05em;
  padding: 6px 10px 3px; border-radius: 7px;
  background: rgba(0, 0, 0, 0.78); color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; margin-top: -3px; background: currentColor; }
.badge-GXEE8P::before { background: var(--sr); }
.badge-RS9E8P::before { background: var(--zg); }
.card-body { display: flex; flex-direction: column; gap: 10px; padding: 18px 18px 6px; flex: 1; }
.card h3 {
  margin: 0; font: 700 32px/0.95 var(--display); text-transform: uppercase; letter-spacing: 0.01em;
  overflow-wrap: anywhere;
}
.meta { margin: 0; color: var(--muted); font-size: 14px; }
.meta .version { color: var(--accent); font-weight: 600; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.tags li {
  font-size: 12.5px; font-weight: 600; color: var(--text);
  border: 1px solid var(--line-strong); border-radius: 999px; padding: 3px 10px;
}
.desc { margin: 0; color: #cfdad2; }
.changes { margin: 0; font-size: 14.5px; color: var(--muted); }
.changes b { color: var(--text); font-weight: 600; }
.netplay { margin: 0; display: flex; gap: 8px; align-items: center; font-size: 13.5px; color: var(--muted); }
.netplay svg { width: 18px; height: 18px; flex: none; fill: none; stroke: var(--accent); stroke-width: 1.8; }
.license { margin: 0; font-size: 13px; color: var(--faint); }
.card-foot { padding: 14px 18px 18px; }
.card-foot .btn { width: 100%; }
.card-foot .btn small { font-weight: 500; opacity: 0.7; }
.btn-disabled { background: var(--panel-2); color: var(--faint); border: 1px dashed var(--line-strong); cursor: default; }
.older { margin: 0; font-size: 13.5px; }
.older a { color: var(--muted); }
.older a:hover { color: var(--text); }

.empty {
  display: grid; justify-items: center; text-align: center; gap: 6px;
  padding: 64px 24px;
  border: 1px dashed var(--line-strong); border-radius: var(--radius);
  background:
    radial-gradient(ellipse at 50% 120%, rgba(184, 255, 46, 0.12), transparent 60%),
    var(--panel);
}
.empty img { width: 72px; height: 72px; border-radius: 14px; opacity: 0.9; margin-bottom: 10px; }
.empty h3 { margin: 0; font: 700 42px/1 var(--display); text-transform: uppercase; color: var(--accent); }
html[lang="ja"] .empty h3 { font: 800 26px/1.3 var(--body); }
.empty p { margin: 0; max-width: 32em; color: var(--muted); }

/* ---- How to install ---- */

.steps {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px;
  margin: 0; padding: 0; list-style: none; counter-reset: none;
}
.step {
  position: relative; padding: 26px 24px 24px;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
}
.step-n {
  display: block; margin-bottom: 8px;
  font: 700 64px/0.8 var(--display);
  color: transparent; -webkit-text-stroke: 1.5px var(--accent);
}
.step h3 { margin: 0 0 8px; font-size: 19px; }
.step p { margin: 0; color: #c3cfc7; }
.step b { color: var(--text); }

/* ---- Good to know ---- */

.rules {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 36px;
  margin: 0; padding: 0; list-style: none;
}
.rule { display: flex; gap: 16px; padding: 18px 0; border-top: 1px solid var(--line); }
.rule svg {
  width: 30px; height: 30px; flex: none; margin-top: 2px;
  fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.rule h3 { margin: 0 0 4px; font-size: 17px; }
.rule p { margin: 0; color: #c3cfc7; }

/* ---- Footer ---- */

.foot { border-top: 1px solid var(--line); padding: 32px 0 40px; color: var(--muted); font-size: 14px; }
.foot-row { display: grid; gap: 8px; }
.foot p { margin: 0; }
.foot a { color: var(--muted); }
.foot a:hover { color: var(--text); }
.legal { color: var(--faint); font-size: 13px; max-width: 70em; }

/* ---- Narrow screens ---- */

@media (max-width: 960px) {
  .hero-row { grid-template-columns: 1fr; gap: 28px; padding: 40px 0 96px; }
  .hero-art { order: -1; }
  .hero-art img { transform: none; }
  .steps { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .nav { display: none; }
  .lang { margin-left: auto; }
  .rules { grid-template-columns: 1fr; gap: 0; }
  .section { padding: 52px 0; }
  .section-head h2 { font-size: 46px; }
}
@media (max-width: 420px) {
  .brand { font-size: 22px; }
  .brand img { width: 26px; height: 26px; }
  .lang button { padding: 7px 8px; }
  .cta .btn { flex: 1 1 100%; }
}
