/* Strategy2D — shared styles. Dark navy table, warm gold, felt green: the house style of the games. */

:root {
  --bg: #080b16;
  --bg-2: #0d1122;
  --panel: #12172b;
  --panel-2: #181e36;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --text: #eef0f7;
  --muted: #a3a9c2;
  --dim: #6f7694;
  --gold: #e0b252;
  --gold-soft: rgba(224, 178, 82, 0.14);
  --cream: #f4ead2;
  --felt: #2e9e6b;
  --red: #e5484d;
  --rose: #ec5a79;
  --blue: #4f8df5;
  --violet: #8a6cf0;
  --teal: #2fc29a;
  --good: #7fd88c;
  --bad: #f07a7a;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.7);
  --max: 1180px;
  --serif: "Noto Serif Display", "Noto Serif", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--sans);
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
/* Let grid/flex children shrink below their content width (no horizontal overflow on phones) */
[class*="grid"] > *, .split > *, .ladder > *, .game-panel > *, .featured > *, .versus > * { min-width: 0; }
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3 { line-height: 1.15; margin: 0; }
p { margin: 0; }

/* Backdrop: drifting light specks over a navy gradient, like the in-game backdrop */
.backdrop {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(1200px 700px at 15% -10%, rgba(138, 108, 240, 0.18), transparent 60%),
    radial-gradient(900px 600px at 100% 20%, rgba(79, 141, 245, 0.12), transparent 60%),
    radial-gradient(900px 700px at 50% 120%, rgba(224, 178, 82, 0.08), transparent 60%),
    var(--bg);
}
.backdrop::before {
  content: ""; position: absolute; inset: 0; opacity: 0.35;
  background-image:
    linear-gradient(45deg, rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(-45deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 44px 44px;
}
.speck {
  position: absolute; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.22), transparent 70%);
  animation: drift linear infinite;
}
@keyframes drift {
  from { transform: translateY(10vh); opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  to { transform: translateY(-110vh); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .speck { display: none; }
  html { scroll-behavior: auto; }
}

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  background: rgba(8, 11, 22, 0.72);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 700; letter-spacing: 0.02em; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 30px; height: 30px; }
.brand b { color: var(--gold); font-weight: 800; }
.nav { display: flex; gap: 6px; align-items: center; }
.nav a {
  color: var(--muted); font-size: 14px; font-weight: 500;
  padding: 8px 12px; border-radius: 999px;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); background: rgba(255,255,255,0.06); text-decoration: none; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 22px; border-radius: 999px;
  font-weight: 650; font-size: 15px; letter-spacing: 0.01em;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-gold { background: linear-gradient(180deg, #f0c66a, #c8952f); color: #1b1408; box-shadow: 0 10px 30px -10px rgba(224,178,82,0.6); }
.btn-ghost { border-color: var(--line-strong); color: var(--text); background: rgba(255,255,255,0.03); }
.btn-ghost:hover { border-color: rgba(255,255,255,0.3); background: rgba(255,255,255,0.06); }

/* Type */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--gold);
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: currentColor; border-radius: 2px; }
.display { font-family: var(--serif); font-weight: 700; letter-spacing: 0.01em; }
.lead { color: var(--muted); font-size: 18px; max-width: 60ch; }
.section { padding: 96px 0; position: relative; }
.section-head { display: grid; gap: 14px; margin-bottom: 44px; max-width: 760px; }
.section-head h2 { font-family: var(--serif); font-size: clamp(32px, 4.4vw, 48px); }
.center { text-align: center; margin-left: auto; margin-right: auto; }
.center .eyebrow { justify-content: center; }
.center .lead { margin: 0 auto; }

/* Panels / cards */
.panel {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* Screenshot frame */
.shot {
  position: relative; border-radius: 14px; overflow: hidden;
  border: 1px solid var(--line-strong);
  background: #05070f;
  box-shadow: 0 30px 80px -30px rgba(0,0,0,0.85), 0 0 0 6px rgba(255,255,255,0.02);
  cursor: zoom-in;
}
.shot img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; transition: transform .5s ease; }
.shot:hover img { transform: scale(1.015); }
.shot figcaption {
  position: absolute; left: 12px; bottom: 12px;
  font-size: 12px; font-weight: 600; color: var(--text);
  background: rgba(8, 11, 22, 0.78); border: 1px solid var(--line);
  padding: 5px 10px; border-radius: 999px;
  backdrop-filter: blur(6px);
}

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-size: 13px; font-weight: 600; padding: 6px 12px; border-radius: 999px;
  background: rgba(255,255,255,0.05); border: 1px solid var(--line); color: var(--text);
}
.chip i { font-style: normal; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 7px; vertical-align: 1px; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 40px 0 56px; color: var(--dim); font-size: 14px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; align-items: center; }
.site-footer a { color: var(--muted); }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 100; display: none;
  align-items: center; justify-content: center; padding: 24px;
  background: rgba(3, 5, 12, 0.92);
}
.lightbox.open { display: flex; }
.lightbox img { max-height: 86vh; width: auto; border-radius: 12px; border: 1px solid var(--line-strong); box-shadow: var(--shadow); }
.lightbox p { position: absolute; bottom: 22px; left: 0; right: 0; text-align: center; color: var(--muted); font-size: 14px; padding: 0 16px; }
.lightbox button {
  position: absolute; background: rgba(255,255,255,0.08); color: var(--text);
  border: 1px solid var(--line-strong); width: 46px; height: 46px; border-radius: 50%;
  font-size: 20px; cursor: pointer;
}
.lightbox button:hover { background: rgba(255,255,255,0.16); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 18px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 18px; top: 50%; transform: translateY(-50%); }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

@media (max-width: 760px) {
  .wrap { padding: 0 16px; }
  .section { padding: 64px 0; }
  .nav a.hide-sm { display: none; }
  .nav a { padding: 8px 9px; }
  .lead { font-size: 16px; }
  .lb-prev, .lb-next { top: auto; bottom: 64px; transform: none; }
}
