/* The home page is a viewport, not a scrolling landing page. */
body[data-page="home"] {
  height: 100vh;
  height: 100dvh;
  min-height: 320px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  overflow: hidden;
}
body[data-page="home"] #main {
  min-height: 0;
  display: flex;
}
.header-inner {
  height: 78px;
}
.header-inner nav > a[aria-current]:after {
  bottom: 17px;
}
.brand {
  gap: 0;
}
.brand > span {
  font-size: 28px;
}
.play-wordmark {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -1px;
  color: var(--text);
  margin-right: 12px;
}
.play-wordmark > span {
  color: var(--cyan);
}
body[data-page="home"] .header-inner,
body[data-page="home"] .footer-inner {
  width: calc(100% - 80px);
  max-width: none;
}
body[data-page="home"] #site-header {
  position: relative;
  z-index: 10;
  background: #141020;
}
body[data-page="home"] .footer-inner {
  min-height: 53px;
  padding-block: 10px;
}
body[data-page="home"] .footer-brand {
  font-size: 18px;
}
body[data-page="home"] #site-footer {
  position: relative;
  z-index: 10;
  background: #120f1b;
}
body[data-page="home"] .explorer {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  border-radius: 0;
  margin: 0;
  background: #131020;
  box-shadow: none;
  display: grid;
  grid-template: minmax(0, 1fr) / minmax(0, 1fr);
  isolation: isolate;
}
body[data-page="home"] .explorer-bar {
  position: absolute;
  z-index: 8;
  left: 40px;
  right: 40px;
  top: 24px;
  height: 44px;
  padding: 0;
  border: 0;
  pointer-events: none;
}
.explorer-title {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border: 1px solid #c8b4ff14;
  border-radius: 10px;
  background: #21182e8c;
  backdrop-filter: blur(16px);
}
.explorer-title h1 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.4;
  margin: 0;
}
.world-game-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border-left: 1px solid #ffffff20;
  padding-left: 13px;
  color: #b5a8c9;
  font-size: 10px;
  white-space: nowrap;
}
.world-game-count b {
  color: #e7dbff;
  font-weight: 600;
}
body[data-page="home"] .view-switch {
  pointer-events: auto;
  background: #20172dcc;
  border-color: #c3a4fa20;
  backdrop-filter: blur(18px);
  padding: 5px;
}
body[data-page="home"] .view-switch button {
  min-height: 33px;
  padding: 8px 14px;
  font-size: 11px;
}
body[data-page="home"] .view-switch button[aria-pressed="true"] {
  background: #51406470;
  box-shadow:
    inset 0 0 0 1px #c1a9f425,
    0 2px 8px #0002;
}
body[data-page="home"] .world-viewport {
  grid-area: 1 / 1;
  min-height: 0;
  height: 100%;
  width: 100%;
  touch-action: none;
  background:
    radial-gradient(ellipse at 49% 45%, #4b2e5d56, transparent 55%),
    radial-gradient(ellipse at 15% 35%, #22455730, transparent 50%),
    radial-gradient(circle, #baa3e42b 0.75px, transparent 1px), #131020;
  background-size:
    auto,
    auto,
    31px 31px,
    auto;
}
body[data-page="home"] .world-scene {
  top: 50%;
  width: 2000px;
  height: 1200px;
  z-index: 2;
  user-select: none;
}
body[data-page="home"] .map-coordinates {
  inset: 91px 42px auto;
  font-size: 8px;
  opacity: 0.65;
  z-index: 3;
}
body[data-page="home"] .map-vignette {
  z-index: 4;
  box-shadow: inset 0 0 110px 24px #100b1e85;
}
body[data-page="home"] .world-controls {
  bottom: 56px;
  z-index: 7;
}
body[data-page="home"] .world-controls button {
  backdrop-filter: blur(14px);
  background-color: #251c35ad;
  border-color: #c3a9e825;
}
body[data-page="home"] .explorer-bottom {
  position: absolute;
  bottom: 13px;
  left: 40px;
  right: 40px;
  min-height: 35px;
  border: 0;
  padding: 0;
  pointer-events: none;
  z-index: 8;
}
body[data-page="home"] .explorer-bottom p {
  font-size: 10px;
  color: #a99cbd;
  text-shadow: 0 2px 8px #110a20;
}
body[data-page="home"] .explorer-bottom button {
  pointer-events: auto;
  padding: 10px 14px;
  border: 1px solid #b2a0ff20;
  border-radius: 8px;
  background: #23192db3;
  backdrop-filter: blur(12px);
}
body[data-page="home"] .game-grid {
  grid-area: 1/1;
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  align-content: start;
  grid-auto-rows: max-content;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding: 96px max(40px, calc((100% - 1440px) / 2)) 76px;
  scrollbar-width: thin;
  scrollbar-color: #655078 #191224;
  background:
    radial-gradient(ellipse at 50% 0, #432c5240, transparent 60%), #151020;
}
body[data-page="home"] .is-overview .explorer-bar {
  top: 0;
  left: 0;
  right: 0;
  height: 78px;
  padding: 16px 40px;
  background: #171122f5;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
}
body[data-page="home"] .is-overview .explorer-bottom {
  left: 0;
  right: 0;
  bottom: 0;
  min-height: 62px;
  padding: 12px 40px;
  background: #171122;
  border-top: 1px solid var(--line);
  border-radius: 0;
}
body[data-page="home"] .map-card {
  border-color: #c6b0f426;
  background: linear-gradient(145deg, #2a2034, #1d182a);
  box-shadow:
    0 10px 34px #07041155,
    inset 0 1px #ffffff08;
}
body[data-page="home"] .map-card:hover {
  box-shadow:
    0 14px 48px #09031099,
    0 0 28px color-mix(in srgb, var(--game-color) 16%, transparent);
}
body[data-page="home"] .world-connections path {
  stroke-width: 1.3;
  opacity: 0.5;
}
.world-sun {
  position: absolute;
  width: 400px;
  height: 400px;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  pointer-events: none;
  isolation: isolate;
}
.sun-logo {
  display: block;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  border: 1px solid #a4edff65;
  box-shadow:
    0 0 28px #70e0fb50,
    0 0 75px #b184ef38,
    0 0 135px #8ebfe91c;
  position: relative;
  z-index: 2;
}
.sun-corona {
  position: absolute;
  inset: -50px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    #99d8fa25 25%,
    #ac70e228 42%,
    transparent 69%
  );
  animation: sun-breathe 9s ease-in-out infinite alternate;
}
.sun-rays {
  position: absolute;
  inset: -100px;
  background: repeating-conic-gradient(
    from 4deg,
    transparent 0deg 9deg,
    #86e0f538 11deg 12deg,
    transparent 14deg 25deg,
    #b99af535 27deg 28deg,
    transparent 30deg 40deg
  );
  -webkit-mask-image: radial-gradient(
    circle,
    transparent 29%,
    #000 41%,
    transparent 69%
  );
  mask-image: radial-gradient(
    circle,
    transparent 29%,
    #000 41%,
    transparent 69%
  );
  filter: blur(2px);
  opacity: 0.65;
  animation: sun-turn 90s linear infinite;
}
.sun-rays-soft {
  inset: -140px;
  opacity: 0.35;
  filter: blur(5px);
  animation-direction: reverse;
  animation-duration: 125s;
}
body[data-page="home"] .game-grid > .game-card {
  align-self: start;
  min-width: 0;
}
.ambient-object.cross:before {
  clip-path: polygon(
    38% 0,
    62% 0,
    62% 38%,
    100% 38%,
    100% 62%,
    62% 62%,
    62% 100%,
    38% 100%,
    38% 62%,
    0 62%,
    0 38%,
    38% 38%
  );
  border: 0;
  background: currentColor;
  opacity: 0.45;
}
.ambient-object.grid:before {
  background:
    repeating-linear-gradient(0deg, transparent 0 12px, currentColor 12px 13px),
    repeating-linear-gradient(90deg, transparent 0 12px, currentColor 12px 13px);
  opacity: 0.45;
  border: 0;
}
@keyframes sun-turn {
  to {
    transform: rotate(360deg);
  }
}
@keyframes sun-breathe {
  from {
    opacity: 0.65;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1.05);
  }
}
.world-atmosphere {
  position: absolute;
  inset: -14%;
  z-index: 0;
  pointer-events: none;
  transform: translate(var(--ambient-x, 0px), var(--ambient-y, 0px));
  transition: transform 0.55s ease-out;
}
.ambient-glow {
  position: absolute;
  width: 50%;
  height: 70%;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.22;
  animation: ambient-breathe 23s ease-in-out infinite alternate;
}
.ambient-glow-cyan {
  left: -10%;
  top: -20%;
  background: radial-gradient(ellipse, #4fa0b366, transparent 65%);
}
.ambient-glow-purple {
  right: -8%;
  bottom: -25%;
  background: radial-gradient(ellipse, #a265bb80, transparent 65%);
  animation-delay: -11s;
}
.ambient-object {
  position: absolute;
  left: var(--left);
  top: var(--top);
  width: var(--size);
  height: var(--size);
  opacity: var(--opacity, 0.2);
  color: var(--ambient-color, #bc9cdf);
  animation: ambient-drift var(--duration, 28s) ease-in-out infinite alternate;
  animation-delay: var(--delay, 0s);
}
.ambient-object:before {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid currentColor;
  transform: rotate(35deg);
  background: linear-gradient(135deg, #bb98f317, transparent 70%);
  box-shadow: 0 0 35px #9971d009;
}
.ambient-object.shard:before {
  clip-path: polygon(50% 0, 100% 30%, 75% 100%, 15% 75%, 0 30%);
  background: linear-gradient(130deg, #9c8ae929, #6dc9d914);
  border: 0;
}
.ambient-object.orbit:before {
  border-radius: 50%;
  transform: rotate(-35deg) scaleY(0.38);
  background: none;
}
.ambient-object.spark:before {
  clip-path: polygon(
    50% 0,
    60% 38%,
    100% 50%,
    60% 60%,
    50% 100%,
    40% 60%,
    0 50%,
    40% 40%
  );
  background: currentColor;
  border: 0;
}
.edge-hint {
  position: absolute;
  top: 28%;
  bottom: 28%;
  width: 70px;
  display: grid;
  align-items: center;
  pointer-events: none;
  z-index: 6;
  opacity: 0.18;
  transition:
    opacity 0.25s,
    filter 0.25s;
  color: #c4b3e5;
  font-size: 38px;
  font-weight: 400;
}
.edge-hint-left {
  left: 0;
  justify-items: start;
  padding-left: 17px;
  background: linear-gradient(90deg, #9773c112, transparent);
  border-radius: 0 50% 50% 0;
}
.edge-hint-right {
  right: 0;
  justify-items: end;
  padding-right: 17px;
  background: linear-gradient(-90deg, #9773c112, transparent);
  border-radius: 50% 0 0 50%;
}
.world-viewport[data-pan-x="left"] .edge-hint-left,
.world-viewport[data-pan-x="right"] .edge-hint-right {
  opacity: 0.85;
  filter: drop-shadow(0 0 10px #9dddec55);
}
@keyframes ambient-drift {
  from {
    transform: translate3d(-12px, 12px, 0) rotate(-10deg);
  }
  to {
    transform: translate3d(24px, -23px, 0) rotate(18deg);
  }
}
@keyframes ambient-breathe {
  from {
    transform: translate(-3%, 4%) scale(0.9);
    opacity: 0.16;
  }
  to {
    transform: translate(6%, -5%) scale(1.12);
    opacity: 0.3;
  }
}
@media (max-width: 760px) {
  .header-inner {
    height: 70px;
  }
  .brand > span {
    font-size: 25px;
  }
  body[data-page="home"] .header-inner,
  body[data-page="home"] .footer-inner {
    width: calc(100% - 40px);
  }
  body[data-page="home"] .explorer-bar {
    left: 20px;
    right: 20px;
    top: 16px;
  }
  .explorer-title {
    padding: 10px 12px;
    gap: 10px;
  }
  .explorer-title h1 {
    font-size: 10px;
    gap: 7px;
  }
  .world-game-count {
    font-size: 9px;
    padding-left: 10px;
  }
  body[data-page="home"] .view-switch button {
    padding: 7px 10px;
    font-size: 10px;
  }
  body[data-page="home"] .map-coordinates {
    inset: 79px 22px auto;
    font-size: 6px;
  }
  body[data-page="home"] .explorer-bottom {
    left: 20px;
    right: 20px;
    bottom: 12px;
  }
  body[data-page="home"] .explorer-bottom p {
    max-width: 220px;
    font-size: 9px;
  }
  body[data-page="home"] .game-grid {
    padding: 83px 20px 78px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }
  .edge-hint {
    width: 35px;
    font-size: 28px;
  }
  .edge-hint-left {
    padding-left: 8px;
  }
  .edge-hint-right {
    padding-right: 8px;
  }
}
@media (max-width: 520px) {
  .header-inner {
    height: 64px;
  }
  .header-inner nav > a[aria-current]:after {
    bottom: 10px;
  }
  .brand > span {
    font-size: 24px;
  }
  body[data-page="home"] .header-inner,
  body[data-page="home"] .footer-inner {
    width: calc(100% - 32px);
  }
  body[data-page="home"] .footer-inner {
    min-height: 49px;
    padding-block: 9px;
    gap: 10px;
  }
  body[data-page="home"] .footer-brand {
    font-size: 16px;
  }
  body[data-page="home"] .footer-credit {
    font-size: 7px;
  }
  body[data-page="home"] .explorer-bar {
    left: 12px;
    right: 12px;
    top: 12px;
    gap: 8px;
  }
  .explorer-title {
    border: 0;
    padding: 10px 0;
    background: none;
    backdrop-filter: none;
  }
  .explorer-title h1 {
    font-size: 9px;
    width: auto;
    max-width: 128px;
  }
  .explorer-title .status-dot {
    width: 4px;
    height: 4px;
  }
  .world-game-count {
    display: none;
  }
  body[data-page="home"] .view-switch {
    padding: 3px;
  }
  body[data-page="home"] .view-switch button {
    font-size: 9px;
    padding: 6px 7px;
    gap: 4px;
    min-height: 31px;
  }
  body[data-page="home"] .map-coordinates {
    inset: 66px 15px auto;
  }
  body[data-page="home"] .explorer-bottom {
    left: 13px;
    right: 13px;
    bottom: 10px;
  }
  body[data-page="home"] .explorer-bottom p {
    max-width: 185px;
    font-size: 8px;
    gap: 6px;
    line-height: 1.5;
  }
  body[data-page="home"] .explorer-bottom button {
    font-size: 9px;
    padding: 9px 10px;
  }
  body[data-page="home"] .game-grid {
    grid-template-columns: 1fr;
    padding: 76px 16px 74px;
    gap: 16px;
  }
  body[data-page="home"] .game-grid > .game-card {
    display: grid;
    grid-template-columns: 104px minmax(0, 1fr);
    min-height: 158px;
    height: auto;
    border-radius: 13px;
  }
  body[data-page="home"] .game-grid .game-art {
    aspect-ratio: auto;
    min-height: 158px;
    height: 100%;
  }
  body[data-page="home"] .game-grid .game-art > img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  body[data-page="home"] .game-grid .game-card-content {
    padding: 15px 14px;
  }
  body[data-page="home"] .game-grid h3 {
    font-size: 16px;
    line-height: 1.35;
  }
  body[data-page="home"] .game-grid .game-category {
    font-size: 8px;
    margin-bottom: 6px;
  }
  body[data-page="home"] .game-grid .game-card-content > p {
    font-size: 11px;
    line-height: 1.65;
    margin: 8px 0;
  }
  body[data-page="home"] .game-grid .card-play-text {
    margin-top: 10px;
    font-size: 11px;
    min-height: 24px;
    align-items: center;
  }
  body[data-page="home"] .game-grid .game-play {
    display: none;
  }
  body[data-page="home"] .game-grid .game-number {
    left: 8px;
    top: 8px;
  }

  body[data-page="home"] .world-controls {
    bottom: 57px;
  }
  .edge-hint {
    display: none;
  }
  .ambient-object {
    opacity: 0.12;
  }
  .play-wordmark {
    font-size: 17px;
    margin-right: 4px;
  }
}
@media (max-height: 540px) and (min-width: 600px) {
  body[data-page="home"] .header-inner {
    height: 57px;
  }
  body[data-page="home"] .footer-inner {
    min-height: 39px;
  }
  body[data-page="home"] .explorer-bar {
    top: 10px;
  }
  body[data-page="home"] .map-coordinates {
    display: none;
  }
  body[data-page="home"] .explorer-bottom {
    bottom: 7px;
  }
  body[data-page="home"] .world-controls {
    bottom: 42px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .world-atmosphere {
    transition: none;
  }
  .ambient-object,
  .ambient-glow,
  .sun-rays,
  .sun-corona {
    animation: none;
  }
  .edge-hint {
    transition: none;
  }
}

@media (max-width: 760px) {
  body[data-page="home"] .is-overview .explorer-bar {
    height: 67px;
    padding: 12px 20px;
  }
  body[data-page="home"] .is-overview .explorer-bottom {
    min-height: 57px;
    padding: 10px 20px;
  }
}
@media (max-width: 520px) {
  body[data-page="home"] .is-overview .explorer-bar {
    height: 64px;
    padding: 10px 12px;
  }
  body[data-page="home"] .is-overview .explorer-bottom {
    min-height: 55px;
    padding: 9px 13px;
  }
}
