/* Risograph print: black ink for the wolf, three spot colours on white stock */
:root {
  --paper: #FAFAF7;
  --ink: #000;
  --blue: #0078BF;
  --pink: #FF48B0;
  --yellow: #FFE800;
  --ink-soft: #3A3A3A;

  --display: "Dela Gothic One", "Arial Black", sans-serif;
  --body: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", system-ui, sans-serif;

  --gutter: clamp(16px, 4vw, 56px);
  --max: 1200px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 500 1.0625rem/1.75 var(--body);
  -webkit-font-smoothing: antialiased;
}
/* paper grain over everything, so flat colour reads as printed */
body::after {
  content: ""; position: fixed; inset: 0; z-index: 100; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: .13; mix-blend-mode: multiply;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; margin: 0; line-height: 1.15; }
p { margin: 0; }

:focus-visible { outline: 3px solid var(--pink); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 10;
  background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 8px; font-weight: 700;
}
.skip:focus { top: 16px; }

.wrap { max-width: var(--max); margin: 0 auto; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 10px var(--gutter);
  background: var(--paper);
  border-bottom: 2px solid var(--ink);
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font: 400 1.05rem var(--display); }
.brand img { width: 40px; height: auto; }
.nav ul { display: flex; align-items: center; gap: 26px; list-style: none; margin: 0; padding: 0; }
.nav a, .brand { text-decoration: none; font-weight: 700; white-space: nowrap; }
.nav a:not(.nav-cta):hover { text-decoration: underline; text-decoration-thickness: 3px; text-decoration-color: var(--pink); text-underline-offset: 6px; }
.nav a.nav-cta { background: var(--ink); color: var(--paper); padding: 8px 18px; border-radius: 999px; }
.nav a.nav-cta:hover { background: var(--blue); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 26px; border-radius: 999px; border: 2px solid var(--ink);
  font: 700 1rem var(--body); text-decoration: none;
  transition: transform .12s ease, box-shadow .12s ease;
}
.btn-ink { background: var(--ink); color: var(--paper); box-shadow: 4px 4px 0 var(--pink); }
.btn-ink:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--pink); }
.btn-ink:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--pink); }
.btn-line { background: transparent; }
.btn-line:hover { background: var(--yellow); }

/* Hero */
.hero {
  max-width: var(--max); margin: 0 auto;
  padding: clamp(40px, 7vw, 96px) var(--gutter) clamp(56px, 8vw, 110px);
  display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(32px, 6vw, 72px); align-items: center;
}
.hero h1 { font-size: clamp(2.3rem, 5vw, 4.3rem); line-height: 1.12; letter-spacing: -0.01em; text-wrap: balance; }
.lede { margin-top: 26px; max-width: 32em; font-size: 1.175rem; color: var(--ink-soft); }
.hero-actions { margin-top: 34px; display: flex; flex-wrap: wrap; gap: 14px; }

.stamp { position: relative; margin: 0; justify-self: center; width: min(100%, 420px); aspect-ratio: 600 / 770; }
.plate { position: absolute; inset: 0; mix-blend-mode: multiply; }
.plate-blue {
  inset: 14% -6% 4% -10%; border-radius: 50%;
  background: radial-gradient(circle, var(--blue) 42%, transparent 46%) 0 0 / 9px 9px;
}
.plate-pink {
  background: var(--pink);
  -webkit-mask: url("assets/logo.png") center / contain no-repeat;
          mask: url("assets/logo.png") center / contain no-repeat;
  transform: translate(9px, 7px);
}
.stamp-ink { position: relative; width: 100%; height: auto; mix-blend-mode: multiply; }

/* Shared section heads */
.services, .engines, .platforms { padding: clamp(64px, 9vw, 120px) var(--gutter); }
.section-head { margin-bottom: clamp(36px, 5vw, 56px); }
.section-head h2 { font-size: clamp(1.9rem, 3.8vw, 3rem); max-width: 18em; }
.section-head p { margin-top: 16px; max-width: 36em; font-size: 1.125rem; }

/* Services: the blue plate */
.services { background: var(--blue); color: var(--paper); }
.service-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px 32px; }
.service { border-top: 2px solid var(--paper); padding-top: 28px; }
.glyph { width: 64px; height: 64px; fill: none; stroke: var(--paper); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 20px; overflow: visible; }
.glyph .dot { fill: var(--pink); stroke: none; mix-blend-mode: multiply; }
.service h3 { font-size: 1.45rem; }
.service > p { margin-top: 10px; }
.service ul { list-style: none; margin: 18px 0 0; padding: 0; font-weight: 700; font-size: .95rem; }
.service li { padding: 8px 0; border-top: 1px dashed rgba(250, 250, 247, .5); }

/* Engines: a big typographic list */
.engine-list { list-style: none; margin: 0; padding: 0; border-bottom: 2px solid var(--ink); }
.engine-list li {
  display: flex; align-items: baseline; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  padding: 18px 0; border-top: 2px solid var(--ink);
}
.engine-list strong { font: 400 clamp(1.9rem, 5.4vw, 4.4rem)/1.1 var(--display); }
.engine-list span { font-weight: 700; color: var(--ink-soft); }
.engine-list li:hover strong { color: var(--blue); text-shadow: 5px 4px 0 var(--pink); }

/* Platforms + playable demo: the yellow plate */
.platforms { background: var(--yellow); }
.platforms-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.platform-list { margin: 0; display: grid; gap: 0; border-bottom: 2px solid var(--ink); }
.platform-list div { border-top: 2px solid var(--ink); padding: 14px 0; display: grid; grid-template-columns: 7.5rem 1fr; gap: 16px; align-items: baseline; }
.platform-list dt { font: 400 1.3rem var(--display); }
.platform-list dd { margin: 0; font-weight: 500; }

.stage { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 20px; min-height: 34rem; }
.device {
  position: relative; width: 100%; aspect-ratio: 16 / 10;
  border: 12px solid var(--ink); border-radius: 16px; background: var(--paper);
  box-shadow: 10px 10px 0 var(--pink);
  margin-bottom: 34px;
  transition: width .5s cubic-bezier(.6,-0.2,.3,1.3), aspect-ratio .5s cubic-bezier(.6,-0.2,.3,1.3), border-radius .5s, border-width .5s;
}
.device canvas { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 3px; cursor: pointer; touch-action: manipulation; }
.device-stand {
  position: absolute; left: 50%; bottom: -48px; transform: translateX(-50%);
  width: 34%; height: 36px;
  background: linear-gradient(var(--ink), var(--ink)) center top / 20% 26px no-repeat,
              linear-gradient(var(--ink), var(--ink)) center bottom / 100% 10px no-repeat;
  transition: opacity .3s;
}
.device[data-platform="console"] { aspect-ratio: 16 / 9; border-width: 8px; border-radius: 8px; }
.device[data-platform="console"] .device-stand { bottom: -50px; width: 124px; height: 52px; background: none; }
.device[data-platform="console"] .device-stand::before {
  content: ""; position: absolute; inset: 14px 0 0; background: var(--ink); border-radius: 22px 22px 30px 30px;
}
.device[data-platform="console"] .device-stand::after {
  content: ""; position: absolute; top: 27px; right: 26px; width: 10px; height: 10px; border-radius: 50%;
  background: var(--pink); box-shadow: -62px 0 0 var(--blue);
}
.device[data-platform="mobile"] { width: min(46%, 230px); aspect-ratio: 9 / 18; border-width: 10px; border-radius: 34px; margin-bottom: 0; }
.device[data-platform="mobile"] canvas { border-radius: 24px; }
.device[data-platform="mobile"] .device-stand { opacity: 0; }

.platform-switch { display: flex; gap: 4px; padding: 4px; border: 2px solid var(--ink); border-radius: 999px; background: var(--paper); }
.platform-switch button {
  font: 700 .95rem var(--body); color: var(--ink);
  background: none; border: 0; padding: 8px 18px; border-radius: 999px; cursor: pointer;
}
.platform-switch button:hover { background: var(--yellow); }
.platform-switch button[aria-checked="true"] { background: var(--ink); color: var(--paper); }
.stage-hint { font-size: .925rem; font-weight: 700; text-align: center; }

/* Our Games */
.games { padding: clamp(56px, 8vw, 110px) var(--gutter); border-top: 2px solid var(--ink); }
.game-group + .game-group { margin-top: clamp(48px, 6vw, 72px); }
.game-group > h3 {
  display: inline-block; margin-bottom: 24px;
  font-size: 1.4rem; padding: 4px 18px 6px; border-radius: 999px;
  background: var(--ink); color: var(--paper);
}
.game-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 28px; }
.game { display: flex; flex-direction: column; border: 2px solid var(--ink); border-radius: 18px; background: var(--paper); overflow: hidden; }
.game-cover { position: relative; aspect-ratio: 1; display: grid; place-items: center; border-bottom: 2px solid var(--ink); overflow: hidden; }
#games-pc .game-cover { aspect-ratio: 16 / 9; }
.game-cover img { width: 100%; height: 100%; object-fit: cover; }
.game-cover.cover-blue { background: var(--blue); }
.game-cover.cover-pink { background: var(--pink); }
.game-cover.cover-yellow { background: var(--yellow); }
/* halftone on the placeholder covers, so empty slots still look printed */
.game-cover:not(:has(img))::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle, rgba(0,0,0,.18) 30%, transparent 34%) 0 0 / 10px 10px;
}
.game-initial { position: relative; font: 400 clamp(4rem, 9vw, 6rem)/1 var(--display); color: var(--paper); -webkit-text-stroke: 2px var(--ink); text-shadow: 6px 5px 0 var(--ink); }
.game-body { display: flex; flex-direction: column; gap: 10px; padding: 20px 20px 22px; flex: 1; }
.game-body h4 { font: 400 1.3rem/1.2 var(--display); margin: 0; }
.game-body p { color: var(--ink-soft); }
.game-actions { margin-top: auto; padding-top: 8px; display: flex; flex-wrap: wrap; gap: 10px; }
.store-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: 999px; border: 2px solid var(--ink);
  font: 700 .925rem var(--body); text-decoration: none;
}
a.store-btn { background: var(--ink); color: var(--paper); box-shadow: 3px 3px 0 var(--pink); transition: transform .12s ease, box-shadow .12s ease; }
a.store-btn:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--pink); }
a.store-playStore::before {
  content: ""; width: 0; height: 0;
  border-left: 11px solid currentColor; border-top: 7px solid transparent; border-bottom: 7px solid transparent;
}
.store-btn.is-soon { border-style: dashed; color: var(--ink-soft); cursor: default; }
.game-empty { font-weight: 700; color: var(--ink-soft); }

/* Contact: the pink plate */
.contact {
  background: var(--pink);
  padding: clamp(72px, 10vw, 130px) var(--gutter);
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 18px;
}
.contact h2 { font-size: clamp(2.2rem, 5.6vw, 4.4rem); }
.contact p { max-width: 32em; font-size: 1.125rem; }
.btn-big { margin-top: 16px; font-size: clamp(1rem, 2.4vw, 1.25rem); padding: 18px 30px; word-break: break-all; box-shadow: 5px 5px 0 var(--blue); }
.btn-big:hover { box-shadow: 7px 7px 0 var(--blue); }

.footer {
  max-width: var(--max); margin: 0 auto; padding: 36px var(--gutter);
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px;
  font-size: .95rem; font-weight: 500;
}
.footer .brand img { width: 34px; }

/* Responsive */
@media (max-width: 1000px) {
  .service-list { grid-template-columns: repeat(2, 1fr); }
  .platforms-grid { grid-template-columns: 1fr; }
  .nav ul li:nth-child(3) { display: none; }
}
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; }
  .stamp { width: min(58%, 230px); grid-row: 1; }
  .nav ul li:not(:last-child) { display: none; }
  .brand { font-size: .95rem; }
  .nav a.nav-cta { padding: 7px 14px; font-size: .95rem; }
  .service-list { grid-template-columns: 1fr; }
  .platform-list div { grid-template-columns: 1fr; gap: 2px; }
  .stage { min-height: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* Legal pages */
.legal { max-width: 46rem; margin: 0 auto; padding: clamp(40px, 7vw, 88px) var(--gutter) clamp(56px, 8vw, 100px); }
.legal-head { display: flex; align-items: center; gap: 22px; padding-bottom: 28px; margin-bottom: 8px; border-bottom: 2px solid var(--ink); }
.legal-icon { width: 88px; height: 88px; border-radius: 22px; border: 2px solid var(--ink); box-shadow: 4px 4px 0 var(--pink); flex: none; }
.legal-head h1 { font-size: clamp(1.8rem, 4.4vw, 2.8rem); }
.legal-head p { margin-top: 6px; font-weight: 700; color: var(--ink-soft); }
.legal-body > p, .legal-body li { color: #1d1d1d; }
.legal-body > * + * { margin-top: 14px; }
.legal-body h2 { font-size: 1.3rem; margin-top: 40px; scroll-margin-top: 90px; }
.legal-body ul { padding-left: 1.3em; }
.legal-body li + li { margin-top: 6px; }
.legal-body a { text-decoration-color: var(--pink); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.legal-body code { font-size: .9em; background: var(--yellow); padding: 1px 6px; border-radius: 4px; word-break: break-all; }
.legal-facts { margin: 18px 0 0; border-top: 2px solid var(--ink); }
.legal-facts div { display: grid; grid-template-columns: 7rem 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px dashed var(--ink-soft); }
.legal-facts dt { font-weight: 700; }
.legal-facts dd { margin: 0; overflow-wrap: anywhere; }
@media (max-width: 560px) {
  .legal-head { flex-direction: column; align-items: flex-start; }
  .legal-facts div { grid-template-columns: 1fr; gap: 0; }
}

/* Small text links under a game's store buttons */
.game-links { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: .9rem; font-weight: 700; }
.game-links a { text-decoration-color: var(--pink); text-decoration-thickness: 2px; text-underline-offset: 3px; }
