/* oldmansgames.com — shared stylesheet
   Theme: old phosphor CRT terminal. Dark, scanlines, monospace headings,
   one neon accent per game (set via --accent on the page root). */

:root {
  --bg: #07090d;
  --bg-raise: #0c1016;
  --panel: #0e131b;
  --line: #1b2433;
  --ink: #d7e0e8;
  --ink-dim: #8694a6;
  --ink-faint: #56657a;
  --phosphor: #ff3b4f;          /* studio neon red */
  --accent: var(--phosphor);    /* overridden per game */
  --accent-dim: color-mix(in srgb, var(--accent) 55%, transparent);
  --accent-glow: color-mix(in srgb, var(--accent) 22%, transparent);
  --mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;
  --display: "Martian Mono", "IBM Plex Mono", ui-monospace, monospace;
  --body: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.7 var(--body);
  -webkit-font-smoothing: antialiased;
}

/* CRT atmosphere: scanlines + vignette, fixed behind everything */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  background:
    repeating-linear-gradient(0deg,
      rgba(0, 0, 0, 0.22) 0px, rgba(0, 0, 0, 0.22) 1px,
      transparent 1px, transparent 3px),
    radial-gradient(ellipse 120% 90% at 50% 0%,
      transparent 55%, rgba(0, 0, 0, 0.5) 100%);
  opacity: .55;
}

main { position: relative; z-index: 1; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

::selection { background: var(--accent); color: var(--bg); }

.wrap {
  max-width: 980px;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

/* ---------- header ---------- */

.site-head {
  position: relative;
  z-index: 3;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, var(--bg-raise), var(--bg));
}

.site-head .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: .85rem;
}

.brand {
  font-family: var(--mono);
  font-size: .95rem;
  color: var(--ink-dim);
  white-space: nowrap;
}

.brand b { color: var(--phosphor); font-weight: 600; }
.brand a { color: inherit; }
.brand-mark {
  width: 32px; height: 32px;
  margin-right: .6rem;
  vertical-align: -0.7em;
  border-radius: 6px;
}
.brand a:hover { text-decoration: none; color: var(--ink); }

.lang {
  font-family: var(--mono);
  font-size: .8rem;
  letter-spacing: .08em;
}

.lang a, .lang span { padding: .2rem .45rem; color: var(--ink-faint); }
.lang span { color: var(--accent); border: 1px solid var(--accent-dim); }
.lang a:hover { color: var(--ink); text-decoration: none; }

/* ---------- hero (home) ---------- */

.hero { padding: 5rem 0 3.5rem; }

.prompt {
  font-family: var(--mono);
  color: var(--ink-faint);
  font-size: .9rem;
  margin: 0 0 1rem;
}

.prompt b { color: var(--phosphor); font-weight: 500; }

h1.title {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(1.8rem, 6vw, 3.4rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 1.1rem;
  color: #fff;
  text-shadow: 0 0 24px var(--accent-glow), 0 0 60px var(--accent-glow);
}

h1.title .cursor {
  display: inline-block;
  width: .55em; height: .95em;
  margin-left: .12em;
  background: var(--phosphor);
  vertical-align: -0.08em;
  animation: blink 1.1s steps(1) infinite;
}

@keyframes blink { 50% { opacity: 0; } }

.tagline {
  max-width: 34em;
  color: var(--ink-dim);
  font-size: 1.1rem;
  margin: 0;
}

/* ---------- game cards ---------- */

.shelf { padding: 1rem 0 4rem; }

.shelf-label {
  font-family: var(--mono);
  font-size: .8rem;
  letter-spacing: .25em;
  color: var(--ink-faint);
  text-transform: uppercase;
  margin: 0 0 1.2rem;
}

.card {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 1.25rem;
  align-items: center;
  padding: 1.4rem;
  margin-bottom: 1rem;
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.card:hover {
  transform: translateX(4px);
  border-color: var(--accent-dim);
  border-left-color: var(--accent);
  box-shadow: 0 0 32px var(--accent-glow);
  text-decoration: none;
}

a.card { color: inherit; }
a.card:hover { text-decoration: none; }

.card .art {
  width: 96px; height: 96px;
  object-fit: cover;
  border: 1px solid var(--line);
  image-rendering: auto;
}

.card .art-ph {
  width: 96px; height: 96px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line);
  font-family: var(--mono);
  font-size: 1.6rem;
  color: var(--accent);
  background:
    repeating-linear-gradient(45deg, transparent 0 8px, rgba(255,255,255,.015) 8px 16px);
}

.card h2 {
  font-family: var(--display);
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 .3rem;
  color: #fff;
}

.card p { margin: 0; color: var(--ink-dim); font-size: .95rem; }

.badge {
  font-family: var(--mono);
  font-size: .68rem;
  letter-spacing: .12em;
  padding: .18rem .5rem;
  margin-left: .6rem;
  vertical-align: 2px;
  color: var(--accent);
  border: 1px solid var(--accent-dim);
  white-space: nowrap;
}

.badge.soon { color: var(--ink-faint); border-color: var(--line); }

@media (max-width: 540px) {
  .card { grid-template-columns: 64px 1fr; }
  .card .art, .card .art-ph { width: 64px; height: 64px; }
}

/* ---------- game page ---------- */

.game-hero { padding: 4rem 0 2.5rem; }

.game-hero .kicker {
  font-family: var(--mono);
  font-size: .8rem;
  letter-spacing: .25em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 .8rem;
}

.game-hero h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(1.7rem, 5.5vw, 3rem);
  margin: 0 0 1rem;
  color: #fff;
  text-shadow: 0 0 28px var(--accent-glow);
}

.game-hero .lede { color: var(--ink-dim); font-size: 1.05rem; max-width: 38em; }

.section { padding: 1.5rem 0 2.5rem; }

.section h2 {
  font-family: var(--mono);
  font-size: .85rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0 0 1rem;
}

.section h2::before { content: "// "; color: var(--accent); }

.section p { max-width: 42em; color: var(--ink); }
.section ul { max-width: 42em; color: var(--ink); padding-left: 1.2rem; }
.section li { margin: .35rem 0; }
.section li::marker { color: var(--accent); }

code {
  font-family: var(--mono);
  font-size: .92em;
  color: var(--accent);
  background: var(--bg-raise);
  border: 1px solid var(--line);
  padding: .05rem .35rem;
}

/* screenshot strip */
.shots {
  display: flex;
  gap: .9rem;
  overflow-x: auto;
  padding-bottom: .75rem;
  scroll-snap-type: x mandatory;
}

.shots img {
  height: 380px;
  width: auto;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  scroll-snap-align: start;
}

@media (max-width: 540px) { .shots img { height: 300px; } }

/* store buttons */
.stores { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: .5rem; }

.store-btn {
  display: inline-block;
  font-family: var(--mono);
  font-size: .85rem;
  letter-spacing: .06em;
  padding: .7rem 1.2rem;
  color: var(--bg);
  background: var(--accent);
  border: 1px solid var(--accent);
  font-weight: 600;
}

.store-btn:hover { text-decoration: none; box-shadow: 0 0 24px var(--accent-glow); }

.store-btn.ghost {
  color: var(--ink-dim);
  background: transparent;
  border-color: var(--line);
  cursor: default;
}

.store-btn.ghost:hover { box-shadow: none; }

/* ---------- legal pages ---------- */

.legal { padding: 3rem 0 4rem; }

.legal article {
  max-width: 760px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent);
  padding: 2.2rem clamp(1.2rem, 4vw, 2.5rem) 2.5rem;
}

.legal h1 { font-family: var(--display); font-size: 1.45rem; margin: 0 0 .3rem; color: #fff; }
.legal .meta { color: var(--ink-faint); font-family: var(--mono); font-size: .82rem; margin-bottom: 1.6rem; }
.legal h2 { font-size: 1.05rem; margin: 1.9rem 0 .5rem; color: #fff; }
.legal h3 { font-size: .95rem; margin: 1.3rem 0 .4rem; color: #fff; }
.legal p, .legal li { color: var(--ink); font-size: .96rem; }
.legal ul { padding-left: 1.2rem; }
.legal li { margin: .25rem 0; }

.legal .note {
  background: var(--bg-raise);
  border: 1px solid var(--accent-dim);
  padding: .8rem 1rem;
  font-size: .92rem;
}

.legal .lang-note {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--line);
  color: var(--ink-faint);
  font-size: .85rem;
}

/* ---------- footer ---------- */

.site-foot {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
  position: relative;
  z-index: 1;
}

.site-foot .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 2rem;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: .82rem;
  color: var(--ink-faint);
}

.site-foot a { color: var(--ink-dim); }
.site-foot .social { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; }
.site-foot a:hover { color: var(--ink); }

/* ---------- 404 ---------- */

.err { min-height: 70vh; display: grid; place-content: center; text-align: center; padding: 3rem 1rem; }
.err h1 { font-family: var(--display); font-size: clamp(2.2rem, 9vw, 4.5rem); color: #fff; margin: 0 0 .5rem; text-shadow: 0 0 32px var(--accent-glow); }
.err p { font-family: var(--mono); color: var(--ink-dim); }

@media (prefers-reduced-motion: reduce) {
  h1.title .cursor { animation: none; }
  .card, .card:hover { transition: none; transform: none; }
}
