/* Blurry Ware studio site. Palette from the splash. */
:root {
  --night: #070a12;
  --dusk: #182134;
  --fog: #c4d0e6;
  --ink: #e8eef8;
  --ember: #ffb37a;
  --line: rgba(196, 208, 230, 0.16);
  --display: "Unbounded", "Arial Black", Impact, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html, body { margin: 0; min-height: 100%; }

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: radial-gradient(130% 80% at 50% 38%, var(--dusk) 0%, var(--night) 72%) fixed var(--night);
  color: var(--ink);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.stage {
  flex: 1;
  display: grid;
  place-items: center;
  padding: 48px 16px 24px;
}

.placard {
  width: 100%;
  max-width: 560px;
  text-align: center;
  animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

/* Hold the placard until the splash has gone. */
html.bw-splash-on .placard { animation: none; opacity: 0; }

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); filter: blur(8px); }
  to { opacity: 1; transform: none; filter: none; }
}

.mark { display: block; margin: 0 auto 18px; border-radius: 18px; }

h1 {
  margin: 0;
  font: 900 clamp(34px, 9vw, 56px)/1.05 var(--display);
  letter-spacing: -0.01em;
}

.tagline { margin: 10px 0 36px; color: var(--fog); }

.game {
  display: flex;
  gap: 20px;
  align-items: center;
  padding: 20px;
  text-align: left;
  color: inherit;
  text-decoration: none;
  background: rgba(24, 33, 52, 0.72);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.game:hover, .game:focus-visible { transform: translateY(-3px); border-color: rgba(255, 179, 122, 0.55); }
.game:focus-visible { outline: 2px solid var(--ember); outline-offset: 3px; }

.game img { flex: none; width: 96px; height: 96px; border-radius: 22px; }

.game-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }

.game-kicker {
  font: 500 11px/1 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ember);
}

.game-name { font: 900 26px/1.1 var(--display); }

.game-blurb { color: var(--fog); font-size: 14px; }

.play {
  align-self: flex-start;
  margin-top: 10px;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--ember);
  color: var(--night);
  font: 500 13px/1 var(--display);
  text-decoration: none;
}

.play.solo { display: inline-block; }

.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 20px;
  padding: 20px 16px calc(20px + env(safe-area-inset-bottom));
  color: var(--fog);
  font-size: 13px;
}

.foot a { color: var(--fog); }
.foot a:hover { color: var(--ink); }

@media (max-width: 480px) {
  .game { flex-direction: column; text-align: center; }
  .game-text { align-items: center; }
  .play { align-self: center; }
}

@media (prefers-reduced-motion: reduce) {
  .placard { animation: none; }
  .game { transition: none; }
}

/* --- Blurry Ware studio splash (blurryware-splash.js): plays once a session
   over the game page while the player's data loads. --- */
html.bw-splash-on,
html.bw-splash-on body {
  overflow: hidden;
}

.bw-splash {
  position: fixed;
  inset: 0;
  z-index: 1000;
  overflow: hidden;
  background: radial-gradient(130% 80% at 50% 42%, #182134 0%, #070a12 72%);
  perspective: 700px;
  cursor: pointer;
  transition: opacity 0.55s ease;
}

.bw-splash.bw-splash-out {
  opacity: 0;
  pointer-events: none;
}

/* Larger than the screen, so the tilted plane's edges stay out of view. */
.bw-splash-tilt {
  position: absolute;
  inset: -18%;
  transform-style: preserve-3d;
  transform: rotateX(12deg) rotateY(-14deg);
  animation: bw-splash-sway 9s ease-in-out infinite alternate;
}

@keyframes bw-splash-sway {
  from { transform: rotateX(14deg) rotateY(-16deg); }
  to { transform: rotateX(6deg) rotateY(13deg); }
}

.bw-splash-tilt canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.bw-splash-soft {
  opacity: 0;
  will-change: filter, opacity, transform;
}

.bw-splash-loader {
  position: absolute;
  left: max(14%, env(safe-area-inset-left, 0px));
  right: max(14%, env(safe-area-inset-right, 0px));
  bottom: calc(11% + env(safe-area-inset-bottom, 0px));
  display: grid;
  gap: 10px;
}

.bw-splash-row {
  display: flex;
  justify-content: space-between;
  font: 500 10px/1 "Unbounded", "Arial Black", Impact, sans-serif;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(196, 208, 230, 0.8);
  font-variant-numeric: tabular-nums;
}

.bw-splash-track {
  height: 3px;
  border-radius: 3px;
  background: rgba(196, 208, 230, 0.18);
  overflow: hidden;
}

.bw-splash-bar {
  height: 100%;
  width: 0%;
  border-radius: 3px;
  background: linear-gradient(90deg, #c4d0e6, #ffb37a);
  box-shadow: 0 0 10px #ffb37a;
}

