/* Ignis Studios. One variable family, a near-black page, and a colour block per game.
 *
 * The chrome is deliberately quiet - #111, cream text, hairline rules - because every game on
 * the page brings its own colour and its own name set at poster size. The studio is the shelf;
 * the games are the boxes. Type is Bricolage Grotesque with its width axis pulled to 75% for
 * anything set large, which is what gives the names their condensed, slightly odd character. */


/* Monster Island's own display face, served by the game itself and shipped here the same way. */
@font-face {
  font-family: "Knights Quest";
  src: url("../fonts/knightsquest-webfont.woff2") format("woff2"),
       url("../fonts/knightsquest-webfont.woff") format("woff");
  font-weight: normal; font-style: normal; font-display: swap;
}

:root {
  --bg: #111;
  --bg-2: #1c1c1c;
  --bg-3: #2c2c2c;
  --ink: #f5f3ef;
  --ink-2: #c7cccd;
  --ink-3: #9a9690;
  --line: #2b2b2b;
  --amber: oklch(0.74 0.17 55);
  --hero-bg: #0a0e0f;
  --gutter: clamp(20px, 4vw, 48px);
  --head-h: 60px;
  --radius: 24px;
  --font: "Bricolage Grotesque", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100svh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 17px; line-height: 1.5;
  -webkit-font-smoothing: antialiased; font-optical-sizing: auto;
}
main { flex: 1 0 auto; }
img { max-width: 100%; }
a { color: inherit; text-decoration: none; transition: opacity 0.15s; }
a:hover { opacity: 0.8; }
::selection { background: var(--amber); color: #111; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; border-radius: 6px; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--amber); color: #111; font-weight: 700; padding: 10px 16px; border-radius: 999px;
}
.skip:focus { top: 12px; opacity: 1; }

/* The condensed voice: every big word on the site. */
.display {
  font-weight: 800; font-stretch: 75%; letter-spacing: -0.03em; line-height: 0.86;
  text-wrap: balance; overflow-wrap: anywhere; margin: 0;
}

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

.site-head {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 16px var(--gutter);
  background: rgba(17, 17, 17, 0.86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow 0.3s;
}
.site-head.scrolled { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35); }
.brand img { height: 26px; width: auto; display: block; }
.pills { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.pill {
  font-size: 14px; font-weight: 600; padding: 8px 14px; border-radius: 999px;
  background: #222; color: var(--ink);
  transition: transform 0.15s var(--ease), background 0.15s;
}
.pill:hover { background: var(--bg-3); transform: translateY(-1px); opacity: 1; }
.pill.is-current { background: var(--ink); color: #111; }

/* ---------------------------------------------------------------- hero */

.hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: calc(100svh - var(--head-h));
  display: flex; flex-direction: column; justify-content: flex-end;
  background: var(--hero-bg); color: var(--ink);
}
.hero-art { position: absolute; inset: 0; z-index: -1; }
.hero-art img { width: 100%; height: 100%; object-fit: cover; object-position: 56% 35%; display: block; }
.hero-art::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 14, 15, 0.05), rgba(10, 14, 15, 0.3) 45%, rgba(10, 14, 15, 0.94) 100%),
    linear-gradient(90deg, rgba(10, 14, 15, 0.7), rgba(10, 14, 15, 0.15) 45%, rgba(10, 14, 15, 0) 65%);
}
/* film grain, so the plate reads as a place rather than a render */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: 0.07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.hero-body {
  position: relative; z-index: 1;
  display: flex; justify-content: space-between; align-items: flex-end; gap: 28px; flex-wrap: wrap;
  padding: var(--gutter);
}
.hero-copy { display: flex; flex-direction: column; gap: 18px; max-width: 900px; }
.hero-copy > * { animation: rise 0.7s var(--ease) both; }
.hero-copy > :nth-child(2) { animation-delay: 0.08s; }
.hero-copy > :nth-child(3) { animation-delay: 0.16s; }
.hero .cta { animation: rise 0.7s var(--ease) 0.24s both; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }

.badge {
  align-self: flex-start;
  font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  background: var(--amber); color: #111; padding: 6px 12px; border-radius: 999px;
}
.hero h1 { font-size: clamp(76px, 12vw, 190px); line-height: 0.85; }
.hero p { margin: 0; font-size: clamp(18px, 1.6vw, 22px); line-height: 1.45; color: var(--ink-2); max-width: 36ch; text-wrap: pretty; }
.cta {
  background: var(--ink); color: var(--hero-bg);
  font-weight: 800; font-size: 20px; padding: 22px 40px; border-radius: 999px;
  transition: transform 0.2s var(--ease), box-shadow 0.2s;
}
.cta:hover { opacity: 1; transform: translateY(-2px) scale(1.02); box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35); }

/* ---------------------------------------------------------------- current games */

.game {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
  gap: clamp(24px, 4vw, 56px); align-items: center;
  padding: clamp(40px, 6vw, 88px) var(--gutter);
  background: var(--g-bg); color: var(--g-ink);
}
.game-copy { display: flex; flex-direction: column; gap: 18px; }
.game .genre { font-size: 14px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; opacity: 0.8; }
.game h2 { font-size: clamp(60px, 8vw, 120px); line-height: 0.88; }
.game .pitch { margin: 0; font-size: 19px; line-height: 1.5; max-width: 36ch; text-wrap: pretty; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn {
  background: var(--g-ink); color: var(--g-bg);
  font-weight: 800; font-size: 16px; padding: 14px 26px; border-radius: 999px;
  transition: transform 0.15s var(--ease);
}
.btn:hover { opacity: 1; transform: translateY(-2px); }
/* the art sits a degree off true, and rights itself when you look at it */
.frame {
  aspect-ratio: 4 / 3; border-radius: var(--radius); overflow: hidden;
  border: 2px solid var(--g-ink); background: rgba(0, 0, 0, 0.12);
  transform: rotate(-1.2deg);
  transition: transform 0.5s var(--ease);
}
.game:hover .frame { transform: rotate(0deg); }
.frame img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.6s var(--ease); }
.game:hover .frame img { transform: scale(1.03); }
.frame.contain img { object-fit: contain; padding: 8%; }
.frame.placeholder {
  display: flex; align-items: flex-end; padding: 16px;
  font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 12px;
  background: repeating-linear-gradient(135deg, rgba(0, 0, 0, 0.08) 0 10px, rgba(0, 0, 0, 0.02) 10px 20px);
}
/* alternate sides so the page zig-zags down rather than marching */
@media (min-width: 860px) {
  .game:nth-child(even) .frame { order: -1; transform: rotate(1.2deg); }
  .game:nth-child(even):hover .frame { transform: rotate(0deg); }
}

/* ---------------------------------------------------------------- back catalogue */

.more { padding: clamp(40px, 6vw, 88px) var(--gutter); display: flex; flex-direction: column; gap: 28px; }
.more h2 { font-size: clamp(40px, 5vw, 64px); letter-spacing: -0.02em; line-height: 1; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 16px; }
.card {
  display: flex; flex-direction: column; gap: 12px;
  background: var(--bg-2); border-radius: 20px; padding: 22px;
  transition: transform 0.25s var(--ease), background 0.25s;
}
.card:hover { transform: translateY(-4px); background: #222; }
.card .shot { aspect-ratio: 16 / 10; border-radius: 12px; overflow: hidden; background: #111; }
.card .shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card .genre { font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.card h3 { margin: 0; font-weight: 800; font-size: 28px; line-height: 1; letter-spacing: -0.01em; }
.card p { margin: 0; font-size: 15px; line-height: 1.55; color: #c2beb8; text-wrap: pretty; }
.card .actions { margin-top: auto; gap: 8px; }
.chip { font-weight: 700; font-size: 14px; padding: 8px 14px; border-radius: 999px; background: var(--bg-3); }
.chip:hover { opacity: 1; background: #383838; }

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

.site-foot {
  margin-top: auto;
  display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap;
  padding: 28px var(--gutter); border-top: 1px solid var(--line);
  font-size: 14px; color: var(--ink-3);
}
.site-foot p { margin: 0; }
.site-foot strong { color: var(--ink); }
.site-foot nav { display: flex; gap: 20px; flex-wrap: wrap; }
.site-foot a:hover { color: var(--ink); opacity: 1; }

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

.page-article { padding: clamp(40px, 6vw, 88px) var(--gutter); max-width: 1100px; margin: 0 auto; width: 100%; }
.page-head h1 { font-size: clamp(52px, 8vw, 120px); margin: 0 0 0.35em; }
.prose { max-width: 70ch; font-size: 18px; line-height: 1.65; color: #dcd8d1; }
.prose h2, .prose h3, .prose h4 { color: var(--ink); font-weight: 800; letter-spacing: -0.01em; line-height: 1.15; text-wrap: balance; }
.prose h2 { font-size: clamp(26px, 3vw, 34px); margin: 2em 0 0.5em; }
.prose h3 { font-size: 22px; margin: 1.6em 0 0.4em; }
.prose p, .prose ul, .prose ol { margin: 0 0 1.1em; }
.prose li { margin: 0.35em 0; }
.prose a { color: var(--amber); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose a:hover { color: var(--ink); opacity: 1; }
.prose strong { color: var(--ink); }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.5em 0; }
.prose blockquote { margin: 1.5em 0; padding: 0.2em 0 0.2em 1.2em; border-left: 3px solid var(--amber); color: var(--ink-2); }
.prose img { border-radius: 12px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 16px; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.prose th { color: var(--ink); }

/* Contact Form 7, dressed for the page. */
.prose .wpcf7 form { display: grid; gap: 14px; max-width: 560px; }
.prose .wpcf7 label { display: block; font-weight: 600; color: var(--ink); font-size: 15px; }
.prose .wpcf7 input:not([type="submit"]), .prose .wpcf7 textarea, .prose .wpcf7 select {
  display: block; width: 100%; margin-top: 6px; font: inherit; color: var(--ink);
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px;
}
.prose .wpcf7 input:focus, .prose .wpcf7 textarea:focus { outline: none; border-color: var(--amber); }
.prose .wpcf7 input[type="submit"] {
  justify-self: start; font: inherit; font-weight: 800; font-size: 16px; cursor: pointer;
  background: var(--ink); color: #111; border: 0; border-radius: 999px; padding: 14px 26px;
}
.prose .wpcf7-response-output { border-radius: 12px; border: 1px solid var(--line) !important; padding: 12px 16px; }
.prose .wpcf7-response-output:empty, .prose .wpcf7-form.init .wpcf7-response-output { display: none; }

/* blog listing */
.post-row { padding: 22px 0; border-bottom: 1px solid var(--line); }
.post-row time { font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.post-row h2 { margin: 6px 0 8px; font-weight: 800; font-size: 28px; line-height: 1.1; }
.post-row h2 a:hover { color: var(--amber); opacity: 1; }
.navigation.pagination { margin-top: 30px; }
.nav-links { display: flex; gap: 8px; }
.nav-links .page-numbers { padding: 8px 14px; border-radius: 999px; background: var(--bg-2); }
.nav-links .page-numbers.current { background: var(--ink); color: #111; }

/* ---------------------------------------------------------------- motion */

[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.7s var(--ease); }
[data-reveal].in { opacity: 1; transform: none; }
.frame[data-reveal].in { transform: rotate(-1.2deg); }
@media (min-width: 860px) { .game:nth-child(even) .frame[data-reveal].in { transform: rotate(1.2deg); } }
.game:hover .frame[data-reveal].in { transform: rotate(0deg); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  [data-reveal] { opacity: 1; transform: none; }
  .frame, .frame[data-reveal].in { transform: none; }
}

/* ---------------------------------------------------------------- small screens */

@media (max-width: 640px) {
  .site-head { padding: 12px 16px; flex-wrap: nowrap; }
  .brand img { height: 22px; }
  /* one row that scrolls sideways, rather than two rows that push the hero down */
  .pills { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; scrollbar-width: none; min-width: 0; padding-bottom: 2px; }
  .pills::-webkit-scrollbar { display: none; }
  .pill { font-size: 13px; padding: 7px 11px; flex: 0 0 auto; }
  .hero h1 { font-size: clamp(64px, 19vw, 96px); }
  .cta { font-size: 17px; padding: 16px 28px; }
  .game h2 { font-size: clamp(52px, 15vw, 84px); }
  .game .pitch { font-size: 17px; }
  .page-head h1 { font-size: clamp(44px, 14vw, 72px); }
  .prose { font-size: 17px; }
}

/* ---------------------------------------------------------------- each game in its own voice
 *
 * The block colour was never going to be enough: a games studio's shelf should show the boxes'
 * own type. Every block sets its game's display face and the small treatments that go with it,
 * borrowed from the game itself: eie.io's wooden sign, TrivAI's blinking cursor and marquee
 * bulbs, Tappy Star's sparkles, Monster Island's swells, Mafia Origins' brass rule. */

/* every backdrop layer overscans its block for the parallax; the block clips them so none can paint over a neighbour */
.game { position: relative; isolation: isolate; overflow: hidden; overflow: clip; }
.game > * { position: relative; z-index: 1; }
.game h2 {
  font-family: var(--g-font, var(--font));
  font-weight: var(--g-weight, 800);
  font-stretch: var(--g-stretch, 75%);
  letter-spacing: var(--g-tracking, -0.03em);
  text-transform: var(--g-case, none);
  line-height: var(--g-leading, 0.88);
}

/* Mafia Origins: Oswald, uppercase, a brass hairline above the name, brass badge */
.game--mafia-origins h1 {
  font-family: "Oswald", var(--font); font-weight: 700; font-stretch: 100%;
  text-transform: uppercase; letter-spacing: -0.01em; line-height: 0.92;
  font-size: clamp(68px, 11vw, 172px);
}
.game--mafia-origins h1::before { content: ""; display: block; width: 72px; height: 3px; background: #d8b441; margin-bottom: 0.18em; }
.game--mafia-origins .badge { background: #d8b441; }

/* Trivarium: TrivAI's Lilita One, the cursor from its logo, and marquee bulbs round the frame */
.game--trivarium { --g-font: "Lilita One"; --g-weight: 400; --g-stretch: 100%; --g-tracking: 0.005em; --g-leading: 0.95; }
.game--trivarium h2::after {
  content: ""; display: inline-block; width: 0.07em; height: 0.82em; margin-left: 0.06em; vertical-align: -0.06em;
  background: #ff4fa3; animation: blink 1.1s steps(2, start) infinite;
}
@keyframes blink { to { visibility: hidden; } }
/* the card already carries its own marquee bulbs, so the frame takes the card's shape and adds nothing */
.game--trivarium .frame { aspect-ratio: 1200 / 630; background: #2a1846; }

/* Tappy Star: Bubblegum Sans, a glossy pop to the name, a sky of slowly turning sparkles */
.game--tappy-star { --g-font: "Bubblegum Sans"; --g-weight: 400; --g-stretch: 100%; --g-tracking: 0.01em; --g-leading: 0.95; }
.game--tappy-star h2 { color: #fff7d6; text-shadow: 0 4px 0 #b8760f, 0 6px 18px rgba(120, 70, 0, 0.35); }
.game--tappy-star::before {
  content: ""; position: absolute; inset: -10%; z-index: 0; pointer-events: none; opacity: 0.7;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cg fill='%23fff8dc'%3E%3Cpath d='M40 10l4 14 14 4-14 4-4 14-4-14-14-4 14-4z'/%3E%3Cpath d='M190 60l3 9 9 3-9 3-3 9-3-9-9-3 9-3z'/%3E%3Cpath d='M110 170l5 17 17 5-17 5-5 17-5-17-17-5 17-5z'/%3E%3Cpath d='M230 210l2 7 7 2-7 2-2 7-2-7-7-2 7-2z'/%3E%3Ccircle cx='60' cy='200' r='3'/%3E%3Ccircle cx='150' cy='30' r='2.5'/%3E%3Ccircle cx='220' cy='140' r='2'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 260px 260px;
  transform: translateY(var(--shift, 0px)) rotate(-4deg);
  animation: twinkle 3.2s ease-in-out infinite alternate;
}
@keyframes twinkle { from { opacity: 0.45; } to { opacity: 0.85; } }

/* Mob Underground: Anton, uppercase and tight, on faint scanlines. Stand-in until the game's own face is known. */
.game--mob-underground { --g-font: "Anton"; --g-weight: 400; --g-stretch: 100%; --g-tracking: 0.005em; --g-case: uppercase; --g-leading: 0.9; }
.game--mob-underground::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.07) 0 2px, transparent 2px 7px);
}
/* the plate is a widescreen poster; the frame takes its shape rather than cropping the coast or the crew */
.game--mob-underground .frame { aspect-ratio: 16 / 9; border-width: 3px; }

/* Monster Island: medieval display type, and the sea moving under the block */
.game--monster-island { --g-font: "Knights Quest", "MedievalSharp"; --g-weight: 400; --g-stretch: 100%; --g-tracking: 0.01em; --g-leading: 0.95; }
.game--monster-island::before {
  content: ""; position: absolute; inset: -45% 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 34% 6% at 18% 28%, rgba(255, 255, 255, 0.28), transparent 70%),
    radial-gradient(ellipse 40% 6% at 78% 62%, rgba(255, 255, 255, 0.2), transparent 70%),
    radial-gradient(ellipse 30% 5% at 55% 88%, rgba(255, 255, 255, 0.16), transparent 70%);
  transform: translateY(calc(var(--shift, 0px) * 0.5));
}

/* eie.io: the wooden sign from the game, Lilita One in cream with the .io in lime, a chunky button */
.game--eie-io { --g-font: "Lilita One"; --g-weight: 400; --g-stretch: 100%; --g-tracking: 0.01em; --g-leading: 1; }
.game--eie-io h2 {
  display: inline-block; position: relative; align-self: flex-start;
  font-size: clamp(52px, 6.5vw, 100px);
  color: #fff3dd; text-shadow: 0 3px 0 #3a2210;
  background: linear-gradient(180deg, #8a5a2b, #6e4520);
  border: 3px solid #4a2d12; border-radius: 14px; box-shadow: 0 7px 0 #3a2210;
  padding: 0.18em 0.5em 0.28em; transform: rotate(-1.6deg);
}
.game--eie-io h2 .io { color: #b0ff45; }
.game--eie-io h2::before, .game--eie-io h2::after {
  content: ""; position: absolute; top: 10px; width: 9px; height: 9px; border-radius: 50%; background: #4a2d12;
}
.game--eie-io h2::before { left: 12px; } .game--eie-io h2::after { right: 12px; }
.game--eie-io .btn {
  font-family: "Lilita One", var(--font); font-weight: 400; font-size: 20px; letter-spacing: 0.02em; text-transform: uppercase;
  background: #4a7a12; color: #b0ff45; border: 2px solid #3d6410; box-shadow: 0 5px 0 #223d08; padding: 14px 30px;
}
.game--eie-io .btn:hover { transform: translateY(-2px); box-shadow: 0 7px 0 #223d08; }
.game--eie-io .btn:active { transform: translateY(3px); box-shadow: 0 2px 0 #223d08; }
.game--eie-io .frame { border: 4px solid #4a2d12; border-radius: 16px; box-shadow: 0 8px 0 #3a2210; }

/* ---------------------------------------------------------------- scroll
 *
 * site.js drives these from scroll position: --accent is the colour of the game under the
 * header, --shift a slow offset for a block's own backdrop, and the frames and copy get inline
 * transforms as they cross the viewport. Reveal on these is opacity only, so it never fights
 * the scroll-driven transform. */
.progress {
  position: fixed; top: 0; left: 0; z-index: 20; height: 3px; width: 100%;
  background: var(--accent, var(--amber)); transform-origin: 0 50%; transform: scaleX(0);
  transition: background 0.4s;
}
.site-head { border-bottom: 2px solid var(--accent, var(--line)); transition: border-color 0.4s, box-shadow 0.3s; }
.pill.is-current::before {
  content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 8px; vertical-align: 1px;
  background: var(--accent, var(--amber)); transition: background 0.4s;
}
.hero-art img, .hero-body { will-change: transform; }
.game .frame, .game .game-copy { will-change: transform; }
.game .frame[data-reveal], .game .game-copy[data-reveal] { transition: opacity 0.6s ease; transform: none; }
.game .frame[data-reveal].in { transform: none; }
@media (prefers-reduced-motion: reduce) {
  .progress { display: none; }
  .game--tappy-star::before, .game--trivarium h2::after { animation: none; }
}

/* ---------------------------------------------------------------- backdrops
 * Decorative layers sit at z-index 0 under a block's copy and frame. */
.game > .clouds, .game > .bgvideo { z-index: 0; }

/* Trivarium: TrivAI's own doodle texture (licensed for Ignis; it is already in the game's social card),
 * tiled at the game's 1000px and drifting diagonally at the game's own 14px a second. */
.game--trivarium::before {
  content: ""; position: absolute; inset: -30%; z-index: 0; pointer-events: none; opacity: 0.14;
  background-image: url("../img/trivarium-doodles.jpg"); background-size: 1000px auto;
  filter: grayscale(1); mix-blend-mode: multiply;
  transform: translateY(var(--shift, 0px));
  animation: doodle-drift 72s linear infinite;
}
@keyframes doodle-drift { to { background-position: -1000px 500px; } }

/* Monster Island: the game's clouds, three depths, three speeds */
/* clouds drift sideways only: a vertical parallax slid the whole layer up and bared the block's bottom edge */
.clouds { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.cloud { position: absolute; left: 0; display: block; height: auto; filter: drop-shadow(0 10px 20px rgba(0, 60, 70, 0.15)); animation: cloud-drift linear infinite; }
.cloud.c1 { top: 4%; width: 34%; opacity: 0.95; animation-duration: 70s; --to: 300%; }
.cloud.c2 { top: 52%; width: 40%; opacity: 0.8; animation-duration: 96s; animation-delay: -38s; --to: 260%; }
.cloud.c3 { top: 28%; width: 60%; opacity: 0.6; animation-duration: 130s; animation-delay: -70s; --to: 180%; }
@keyframes cloud-drift { from { transform: translateX(-110%); } to { transform: translateX(var(--to, 260%)); } }

/* eie.io: gameplay running behind the block, tinted back toward the block's green so the copy holds */
.bgvideo { position: absolute; inset: 0; overflow: hidden; pointer-events: none; background: var(--poster) center / cover no-repeat; }
/* softened a touch: the point is motion behind the words, not a second set of words */
.bgvideo video { width: 100%; height: 100%; object-fit: cover; display: block; filter: blur(1.5px) saturate(1.1); transform: scale(1.02); }
.bgvideo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, color-mix(in oklch, var(--g-bg) 97%, transparent), color-mix(in oklch, var(--g-bg) 88%, transparent) 42%, color-mix(in oklch, var(--g-bg) 55%, transparent) 70%, color-mix(in oklch, var(--g-bg) 40%, transparent));
}
.game--eie-io .frame { box-shadow: 0 8px 0 #3a2210, 0 24px 60px rgba(0, 0, 0, 0.35); }

@media (prefers-reduced-motion: reduce) {
  .game--trivarium::before, .cloud { animation: none; }
  .cloud.c1 { transform: translateX(10%); } .cloud.c2 { transform: translateX(120%); } .cloud.c3 { transform: translateX(60%); }
  .bgvideo video { display: none; }
}
