/*
  Game showcase pages: one layout for every Loudstack game.
  Each game page sets its own look on <body class="game game-NAME"> with the variables below.
  To add a game, copy templates/game-showcase.html (see README.md) and add a theme block at the bottom.
*/

body.game {
  --bg: var(--g-bg);
  --bg-2: var(--g-bg-2);
  --card: var(--g-card);
  --line: var(--g-line);
  --fg: var(--g-fg);
  --muted: var(--g-muted);
  --accent: var(--g-accent);
  --accent-ink: var(--g-accent-ink);
}

/* ---------- Hero ---------- */
.g-hero { position: relative; min-height: min(88vh, 820px); display: flex; align-items: flex-end; padding: 0 0 72px; overflow: hidden; isolation: isolate; }
.g-hero .backdrop { position: absolute; inset: 0; z-index: -2; }
.g-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 20%, transparent) 0%, color-mix(in srgb, var(--bg) 55%, transparent) 55%, var(--bg) 100%); }
.crumbs { display: flex; gap: 8px; font-size: .9rem; color: var(--muted); margin-bottom: 22px; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--fg); }
.g-title { font-family: var(--g-title-font); font-weight: var(--g-title-weight, 700); font-size: clamp(3.4rem, 12vw, var(--g-title-max, 8rem)); line-height: .92; letter-spacing: var(--g-title-tracking, -0.03em); margin: 16px 0 0; text-shadow: 0 4px 30px rgba(0,0,0,.45); }
.g-tagline { font-size: clamp(1.15rem, 2.6vw, 1.45rem); max-width: 36rem; margin-top: 18px; color: color-mix(in srgb, var(--fg) 88%, transparent); }
.quick { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.quick span { font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 7px 13px; border-radius: 999px; background: color-mix(in srgb, var(--card) 75%, transparent); border: 1px solid var(--line); backdrop-filter: blur(6px); }
.g-hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

/* ---------- Sub nav ---------- */
.g-subnav { position: sticky; top: 64px; z-index: 40; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.g-subnav ul { display: flex; gap: 4px; list-style: none; overflow-x: auto; scrollbar-width: none; padding: 8px 0; }
.g-subnav a { display: block; white-space: nowrap; text-decoration: none; color: var(--muted); font-size: .9rem; font-weight: 600; padding: 7px 12px; border-radius: 8px; }
.g-subnav a:hover { color: var(--fg); background: var(--bg-2); }

/* ---------- About ---------- */
.g-about { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.g-about .copy p { color: var(--muted); font-size: 1.08rem; }
.g-about .copy p + p { margin-top: 16px; }
.g-about .copy p strong { color: var(--fg); }
.g-about figure { border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: var(--card); position: relative; min-height: 340px; }
.g-about figcaption { position: absolute; left: 14px; bottom: 12px; font-size: .78rem; color: rgba(255,255,255,.8); background: rgba(0,0,0,.5); padding: 4px 10px; border-radius: 999px; }

/* ---------- Feature cards ---------- */
.g-features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.g-feature { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.g-feature .num { font-family: var(--g-title-font); color: var(--accent); font-size: 1.5rem; line-height: 1; }
.g-feature h3 { font-size: 1.2rem; margin-top: 14px; font-family: var(--display); letter-spacing: -0.01em; }
.g-feature p { color: var(--muted); margin-top: 8px; font-size: .97rem; }

/* ---------- World cards ---------- */
.g-world { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.g-place { position: relative; border-radius: var(--radius); border: 1px solid var(--line); padding: 58px 22px 22px; min-height: 230px; display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden; isolation: isolate; background: var(--card); }
.g-place .swatch { position: absolute; inset: 0; z-index: -1; opacity: .9; }
.g-place .swatch::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 20%, rgba(0,0,0,.75)); }
.g-place .lvl { position: absolute; top: 16px; left: 16px; font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 4px 9px; border-radius: 999px; background: rgba(0,0,0,.45); color: #fff; }
.g-place h3 { color: #fff; font-size: 1.15rem; font-family: var(--display); }
.g-place p { color: rgba(255,255,255,.8); font-size: .9rem; margin-top: 4px; }

/* ---------- Spotlight list ---------- */
.g-spotlight { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.g-spot { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; position: relative; }
.g-spot .idx { font-family: var(--g-title-font); font-size: 2.6rem; color: color-mix(in srgb, var(--accent) 70%, transparent); line-height: 1; }
.g-spot h3 { margin-top: 10px; font-size: 1.12rem; font-family: var(--display); }
.g-spot .sub { font-size: .8rem; color: var(--accent); font-weight: 600; margin-top: 2px; }
.g-spot p { color: var(--muted); font-size: .92rem; margin-top: 10px; }

/* ---------- Media ---------- */
.g-media { display: grid; grid-template-columns: 2fr 1fr; grid-auto-rows: 240px; gap: 16px; }
.g-shot { position: relative; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--card); display: grid; place-items: center; }
.g-shot:first-child { grid-row: span 2; }
.g-shot img { width: 100%; height: 100%; object-fit: cover; }
.g-shot img.contain { object-fit: contain; padding: 18px; }
.g-shot figcaption { position: absolute; left: 12px; bottom: 10px; font-size: .78rem; color: rgba(255,255,255,.85); background: rgba(0,0,0,.55); padding: 4px 10px; border-radius: 999px; }
.g-shot.empty { border-style: dashed; color: var(--muted); font-size: .92rem; text-align: center; padding: 20px; }

/* ---------- Details ---------- */
.g-details { display: grid; grid-template-columns: 1fr 1fr; gap: 0 48px; border-top: 1px solid var(--line); }
.g-details div { display: flex; justify-content: space-between; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.g-details dt { color: var(--muted); }
.g-details dd { font-weight: 600; text-align: right; }

/* ---------- Follow ---------- */
.g-follow { text-align: center; background: var(--bg-2); border-top: 1px solid var(--line); }
.g-follow h2 { font-family: var(--g-title-font); font-weight: var(--g-title-weight, 700); font-size: clamp(2.4rem, 7vw, 4rem); line-height: 1; }
.g-follow p { color: var(--muted); max-width: 34rem; margin: 16px auto 0; }
.g-follow .actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 30px; }

.tbd { color: var(--muted); font-style: italic; }

@media (max-width: 900px) {
  .g-about, .g-details { grid-template-columns: 1fr; }
  .g-features { grid-template-columns: 1fr 1fr; }
  .g-media { grid-template-columns: 1fr; grid-auto-rows: 220px; }
  .g-shot:first-child { grid-row: span 1; }
}
@media (max-width: 560px) {
  .g-features { grid-template-columns: 1fr; }
  .g-hero { min-height: 78vh; padding-bottom: 52px; }
  .g-subnav { top: 64px; }
}

/* =========================================================
   Game themes
   ========================================================= */

/* Renaissance: warm, painterly, gold on oxblood. */
body.game-renaissance {
  --g-bg: #140c0a;
  --g-bg-2: #1c1210;
  --g-card: #231715;
  --g-line: #3a2723;
  --g-fg: #f3e9da;
  --g-muted: #b9a693;
  --g-accent: #e2b45a;
  --g-accent-ink: #1e1206;
  --g-title-font: "Cormorant Garamond", Georgia, serif;
  --g-title-weight: 600;
  --g-title-tracking: 0;
  --g-title-max: 9rem;
}
.game-renaissance .backdrop {
  background:
    radial-gradient(ellipse at 20% 25%, rgba(244, 196, 104, .5), transparent 45%),
    radial-gradient(ellipse at 85% 60%, rgba(150, 30, 40, .7), transparent 55%),
    radial-gradient(ellipse at 55% 5%, rgba(255, 236, 200, .22), transparent 40%),
    linear-gradient(160deg, #3b1d14, #1d0f0c 60%, #120a09);
}
.game-renaissance .backdrop .mono { position: absolute; right: 2%; top: -8%; font-family: "Cormorant Garamond", Georgia, serif; font-style: italic; font-weight: 600; font-size: min(60vw, 46rem); line-height: 1; color: rgba(255, 226, 170, .08); }

/* Ulterior Lands: swamp-dark greens with the Beacon's amber glow, pixel type. */
body.game-ulteriorlands {
  --g-bg: #0b1411;
  --g-bg-2: #101c18;
  --g-card: #13221d;
  --g-line: #22382f;
  --g-fg: #e8efe6;
  --g-muted: #98ab9f;
  --g-accent: #f2c26b;
  --g-accent-ink: #1a1405;
  --g-title-font: "Jacquard 24", "Space Grotesk", sans-serif;
  --g-title-weight: 400;
  --g-title-tracking: .01em;
  --g-title-max: 9.5rem;
}
.game-ulteriorlands .backdrop { background: #0b1411; }
.game-ulteriorlands .backdrop .scene { position: absolute; inset: 0; background-size: cover; background-position: center 40%; image-rendering: pixelated; opacity: .6; filter: saturate(.85) hue-rotate(-8deg); }
.game-ulteriorlands .backdrop .glow { position: absolute; inset: 0; background: radial-gradient(ellipse at 70% 25%, rgba(242, 194, 107, .35), transparent 45%), radial-gradient(ellipse at 10% 90%, rgba(40, 160, 120, .25), transparent 50%); }
.game-ulteriorlands .backdrop .sprite { position: absolute; image-rendering: pixelated; filter: drop-shadow(0 10px 18px rgba(0,0,0,.5)); }
.game-ulteriorlands .g-feature .num { font-size: 2.2rem; }
/* Blackletter numerals are hard to read (IV looks like JV), so boss numbers use the display font. */
.game-ulteriorlands .g-spot .idx { font-family: var(--display); font-weight: 700; font-size: 2rem; }
.sw-landfall { background: radial-gradient(circle at 50% 30%, rgba(255, 220, 140, .6), transparent 50%), linear-gradient(160deg, #6b5a3e, #3a3226); }
.sw-mirewood { background: radial-gradient(circle at 70% 30%, rgba(160, 255, 120, .25), transparent 45%), linear-gradient(160deg, #2a4a2a, #0f2219); }
.sw-frostspine { background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .5), transparent 45%), linear-gradient(160deg, #8fb2c9, #3b4f6b); }
.sw-sporelands { background: radial-gradient(circle at 60% 40%, rgba(90, 255, 220, .45), transparent 45%), linear-gradient(160deg, #4a2a6a, #160f2a); }
.sw-tidewatch { background: radial-gradient(circle at 40% 30%, rgba(255, 230, 180, .35), transparent 45%), linear-gradient(160deg, #2c5b78, #0f2638); }
