:root {
  --color-background: 18 18 18;
  --color-primary: 36 36 36;
  --color-primary-highlight: 40 40 40;
  --color-secondary: 24 24 27;
  --color-surface-deep: 19 19 24;
  --color-surface-panel: 24 24 30;
  --color-accent: 145 71 255;
  --color-accent-highlight: 128 58 228;
  --color-blue: 71 178 255;
  --color-gold: 255 224 102;

  --color-tinted-subtle: rgba(255, 255, 255, 0.05);
  --color-tinted: rgba(255, 255, 255, 0.1);
  --color-tinted-highlight: rgba(255, 255, 255, 0.14);
  --color-tinted-press: rgba(255, 255, 255, 0.21);

  --color-fg-secondary: rgba(255, 255, 255, 0.7);
  --color-fg-muted: rgba(255, 255, 255, 0.5);
  --color-fg-faint: rgba(255, 255, 255, 0.3);
  --color-fg-accent: rgb(160, 117, 241);

  --max: 1080px;
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }
html:has(.viewer[open]) { overflow: hidden; }
section[tabindex="-1"]:focus { outline: none; }

::selection { background: rgb(var(--color-accent) / 0.4); color: #fff; }

body {
  background: rgb(var(--color-background));
  color: #fff;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: Rubik, Inter, -apple-system, sans-serif;
  font-weight: 600;
  line-height: 1.2;
}

a { color: var(--color-fg-accent); text-decoration: none; }
a:hover { color: rgb(180, 145, 250); text-decoration: underline; }

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgb(var(--color-background) / 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-tinted);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
  flex-wrap: wrap;
}

.brand { display: inline-flex; align-items: center; }
.brand:hover { text-decoration: none; }
.brand img { width: 150px; height: auto; display: block; }

.site-nav { display: flex; gap: 24px; flex-wrap: wrap; }

.site-nav a {
  color: var(--color-fg-secondary);
  font-size: 15px;
  transition: color 120ms ease-out;
}

.site-nav a:hover { color: #fff; text-decoration: none; }

.hero { padding-top: 92px; padding-bottom: 68px; }

.hero-eyebrow {
  display: inline-block;
  font-family: Rubik, sans-serif;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-fg-accent);
  background: rgb(var(--color-accent) / 0.12);
  border: 1px solid rgb(var(--color-accent) / 0.35);
  border-radius: 999px;
  padding: 7px 18px;
  line-height: 1.4;
  margin-bottom: 20px;
}

.hero h1 {
  font-family: Rubik, sans-serif;
  font-weight: 700;
  font-size: clamp(40px, 7vw, 66px);
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  /* Wider than "Play, chat, and" (6.9em), narrower than "Play, chat, and make" (9.7em) */
  max-width: 8em;
  text-wrap: balance;
}

.lede {
  font-size: clamp(17px, 2.2vw, 20px);
  color: var(--color-fg-secondary);
  max-width: 62ch;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.waitlist-block { display: flow-root; }

.waitlist-block.is-done {
  display: flex;
  align-items: center;
}

.waitlist-block.is-done .waitlist-msg { margin-top: 0; }

.waitlist-intro[hidden] { display: none; }

.waitlist-intro {
  margin-top: 28px;
  font-size: 15px;
  color: var(--color-fg-muted);
}

.waitlist[hidden] { display: none; }

.waitlist {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 10px;
  max-width: 460px;
}

.waitlist input {
  flex: 1 1 240px;
  min-width: 0;
  background: rgb(var(--color-secondary));
  border: 1px solid var(--color-tinted-highlight);
  border-radius: 8px;
  padding: 13px 15px;
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  transition: border-color 120ms ease-out;
}

.waitlist input::placeholder { color: var(--color-fg-faint); }

.waitlist input:focus {
  outline: none;
  border-color: rgb(var(--color-accent));
}

.waitlist button {
  background: rgb(var(--color-accent));
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 13px 24px;
  font-family: Rubik, Inter, sans-serif;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background 120ms ease-out;
}

.waitlist button:hover { background: rgb(var(--color-accent-highlight)); }
.waitlist button:disabled { opacity: 0.55; cursor: default; }

.waitlist input:disabled {
  opacity: 0.55;
  cursor: default;
}

.waitlist button { position: relative; }

.waitlist button .spinner { display: none; }

.waitlist button.is-loading .btn-label { visibility: hidden; }

.waitlist button.is-loading .spinner {
  display: block;
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 600ms linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.waitlist-msg {
  margin-top: 12px;
  font-size: 15px;
  color: var(--color-fg-secondary);
  min-height: 1.4em;
}

.waitlist-msg.is-error { color: rgb(255, 138, 138); }

section { padding: 56px 0; border-top: 1px solid var(--color-tinted); }

section h2 {
  font-size: clamp(26px, 3.6vw, 34px);
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

.section-intro {
  color: var(--color-fg-secondary);
  max-width: 68ch;
  margin-bottom: 32px;
}

.grid { display: grid; gap: 16px; }

.card {
  background: rgb(var(--color-primary));
  border: 1px solid var(--color-tinted);
  border-radius: 12px;
  padding: 22px;
  transition: background 120ms ease-out, border-color 120ms ease-out;
}

.card:hover {
  background: rgb(var(--color-primary-highlight));
  border-color: var(--color-tinted-highlight);
}

.card h3 { font-size: 18px; margin-bottom: 6px; }
.card p { color: var(--color-fg-secondary); font-size: 14.5px; }

.grid-games { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 800px) {
  .grid-games { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 540px) {
  .grid-games { grid-template-columns: 1fr; }
}

.game-card { padding: 0; overflow: hidden; }

.game-card img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  background: rgb(var(--color-surface-deep));
  border-bottom: 1px solid var(--color-tinted);
}

.game-body { padding: 18px 20px 20px; }

.game-link { display: block; color: inherit; }
.game-link:hover { color: inherit; text-decoration: none; }

.store-title {
  font-family: Rubik, sans-serif;
  font-weight: 700;
  font-size: clamp(36px, 5vw, 52px);
  letter-spacing: -0.02em;
  margin: 48px 0 24px;
}

.store {
  display: grid;
  grid-template-columns: 8fr 4fr;
  gap: 32px;
  align-items: start;
  padding-bottom: 56px;
}

.store-pitch { color: var(--color-fg-secondary); }

.details {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 18px;
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--color-tinted);
  font-size: 14.5px;
}

.details dt { color: var(--color-fg-muted); }

.gallery-main {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  padding: 0;
  border: 1px solid var(--color-tinted);
  border-radius: 12px;
  overflow: hidden;
  background: rgb(var(--color-surface-deep));
  cursor: zoom-in;
  transition: border-color 150ms ease-out;
}

.gallery-main:hover { border-color: var(--color-tinted-highlight); }

.slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 400ms ease-in-out;
}

.slide.is-active { opacity: 1; }

.gallery-thumbs {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 150px));
  gap: 10px;
  margin-top: 10px;
}

.gallery-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  background: rgb(var(--color-surface-deep));
  cursor: pointer;
  opacity: 0.55;
  transition: opacity 150ms ease-out, border-color 150ms ease-out;
}

.gallery-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb:hover { opacity: 0.85; }
.gallery-thumb[aria-current="true"] { opacity: 1; border-color: rgb(var(--color-accent)); }

.gallery-main:focus-visible,
.gallery-thumb:focus-visible,
.viewer-btn:focus-visible {
  outline: 2px solid rgb(var(--color-accent));
  outline-offset: 3px;
}

.viewer {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
}

.viewer[open] {
  display: grid;
  place-items: center;
  animation: viewer-in 220ms cubic-bezier(0.16, 1, 0.3, 1);
}

.viewer::backdrop { background: rgb(0 0 0 / 0.88); }

.viewer-frame {
  position: relative;
  width: min(92vw, 1400px, calc(82dvh * 16 / 9));
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  overflow: hidden;
  background: rgb(var(--color-surface-deep));
}

.viewer-btn {
  position: fixed;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: rgb(var(--color-primary) / 0.9);
  color: #fff;
  cursor: pointer;
  transition: background 120ms ease-out;
}

.viewer-btn:hover { background: rgb(var(--color-primary-highlight)); }
.viewer-btn:active { background: rgb(var(--color-secondary)); }
.viewer-close { top: 20px; right: 20px; }
.viewer-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.viewer-next { right: 20px; top: 50%; transform: translateY(-50%); }

.viewer-count {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 14px;
  color: var(--color-fg-secondary);
  font-variant-numeric: tabular-nums;
}

@keyframes viewer-in { from { opacity: 0; transform: scale(0.98); } }

.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  counter-reset: step;
}

.steps li {
  counter-increment: step;
  padding: 18px 20px;
  border: 1px solid var(--color-tinted-subtle);
  border-radius: 6px;
  background: var(--color-tinted-subtle);
  text-align: center;
}

.steps li::before {
  content: counter(step);
  display: block;
  margin-bottom: 6px;
  font-family: Rubik, sans-serif;
  font-size: 20px;
  font-weight: 700;
}

.steps h3 { font-size: 15px; margin-bottom: 4px; }
.steps p { font-size: 14px; color: var(--color-fg-secondary); text-wrap: pretty; }

.row {
  list-style: none;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(150px, 1fr);
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  margin: 0 -4px;
  padding: 4px 4px 8px;
  scrollbar-width: thin;
  scrollbar-color: var(--color-tinted-highlight) transparent;
}

.row li { scroll-snap-align: start; }

@media (min-width: 1024px) {
  .row {
    grid-auto-flow: row;
    grid-template-columns: repeat(8, minmax(0, 1fr));
    overflow: visible;
  }
}

.row img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--color-tinted);
  transition: border-color 150ms ease-out;
}

.row strong { display: block; margin-top: 10px; font-family: Rubik, sans-serif; font-weight: 600; font-size: 15px; }

.row a { display: block; color: #fff; }
.row a:hover { color: #fff; text-decoration: none; }
.row a:hover img { border-color: var(--color-tinted-press); }
.row a:focus-visible { outline: none; }
.row a:focus-visible img { outline: 2px solid rgb(var(--color-accent)); outline-offset: 2px; }

@media (max-width: 860px) {
  .store { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .viewer-prev, .viewer-next { top: auto; bottom: 12px; transform: none; }
  .viewer-count { bottom: 24px; }
}

.callout {
  background: rgb(var(--color-surface-panel));
  border: 1px solid var(--color-tinted);
  border-radius: 12px;
  padding: 26px;
  margin-top: 28px;
}

.callout h3 { font-size: 19px; margin-bottom: 14px; }

ul.clean { list-style: none; display: grid; gap: 10px; }

ul.clean li {
  position: relative;
  padding-left: 22px;
  color: var(--color-fg-secondary);
  font-size: 15px;
}

ul.clean li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgb(var(--color-accent));
}

.contact-email {
  font-family: Rubik, sans-serif;
  font-size: clamp(20px, 3vw, 26px);
  font-weight: 500;
}

.site-footer {
  border-top: 1px solid var(--color-tinted);
  padding: 32px 0 48px;
  margin-top: 24px;
  background: rgb(var(--color-surface-deep));
}

.site-footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.site-footer a { color: var(--color-fg-muted); font-size: 14px; }
.site-footer a:hover { color: #fff; }
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }
.copyright { color: var(--color-fg-muted); font-size: 14px; }

.legal { padding: 56px 0 24px; }
.legal h1 { font-family: Rubik, sans-serif; font-weight: 700; font-size: clamp(32px, 5vw, 44px); margin-bottom: 8px; }
.legal .updated { color: var(--color-fg-muted); font-size: 14px; margin-bottom: 40px; }
.legal section { border-top: none; padding: 0 0 34px; }
.legal h2 { font-size: 22px; margin-bottom: 12px; }
.legal h3 { font-size: 17px; margin: 20px 0 10px; }
.legal p { color: var(--color-fg-secondary); margin-bottom: 14px; max-width: 78ch; }
.legal ul { color: var(--color-fg-secondary); padding-left: 22px; margin-bottom: 16px; display: grid; gap: 8px; max-width: 78ch; }
.legal strong { color: #fff; font-weight: 500; }

.site-footer .container { align-items: flex-start; }
.footer-business { display: grid; gap: 8px; }

.business-address {
  font-style: normal;
  color: var(--color-fg-muted);
  font-size: 14px;
  line-height: 1.7;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .waitlist button.is-loading .spinner { animation-duration: 1600ms; }
  .viewer[open] { animation: none; }
  .slide { transition: none; }
}
