:root {
  --gx3-night: #061127;
  --gx3-gold-a: #ffe27f;
  --gx3-gold-b: #ffad42;
  --gx3-text: #f8fbff;
}

.gx3-enter-splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
  background: var(--gx3-night);
  opacity: 1;
  visibility: visible;
  transition: opacity .58s ease, visibility .58s ease;
}

.gx3-enter-splash.is-leaving {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.gx3-enter-splash *,
.gx3-enter-splash *::before,
.gx3-enter-splash *::after {
  box-sizing: border-box;
}

.gx3-blur-bg {
  position: absolute;
  inset: -32px;
  z-index: -3;
  background:
    linear-gradient(rgba(2, 8, 25, .28), rgba(2, 8, 25, .28)),
    url("/static/park-ui-desktop.webp") center / cover no-repeat;
  filter: blur(28px) saturate(.9) brightness(.58);
  transform: scale(1.08);
}

.gx3-artboard {
  position: relative;
  z-index: 1;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background: #071225;
}

.gx3-picture,
.gx3-scene {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.gx3-scene {
  object-fit: cover;
  user-select: none;
  pointer-events: none;
  animation: gx3-scene-breathe 13s ease-in-out infinite;
}

/*
  Real button covers the painted button exactly.
  Do not add another button elsewhere.
*/
.gx3-enter-btn {
  position: absolute;
  left: 50%;
  top: 49.7%;
  z-index: 4;
  width: 27.4%;
  height: 118px;
  min-width: 230px;
  min-height: 54px;
  transform: translate(-50%, -50%);
  border: 1px solid rgba(255, 246, 203, .9);
  border-radius: 999px;
  color: #4a2800;
  background: linear-gradient(135deg, var(--gx3-gold-a), var(--gx3-gold-b));
  box-shadow:
    0 12px 30px rgba(255, 172, 55, .28),
    inset 0 2px 0 rgba(255, 255, 255, .55);
  font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: clamp(16px, 1.45vw, 25px);
  font-weight: 950;
  letter-spacing: .02em;
  cursor: pointer;
  transition: filter .2s ease, box-shadow .2s ease;
  animation: gx3-button-breathe 3s ease-in-out infinite;
}

.gx3-enter-btn:not(:disabled):hover {
  filter: brightness(1.06);
  box-shadow:
    0 17px 38px rgba(255, 172, 55, .38),
    inset 0 2px 0 rgba(255, 255, 255, .65);
}

.gx3-enter-btn:disabled {
  cursor: wait;
  color: rgba(255,255,255,.86);
  border-color: rgba(255,255,255,.16);
  background: linear-gradient(135deg, #536a8b, #344a6b);
  box-shadow: 0 10px 28px rgba(0,0,0,.22);
  animation: none;
}

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

.gx3-fireflies {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.gx3-fireflies i {
  position: absolute;
  width: .34%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #eaff88;
  box-shadow: 0 0 9px 4px rgba(213,255,116,.42);
  opacity: 0;
  animation: gx3-firefly var(--time, 5s) ease-in-out var(--delay, 0s) infinite;
}

.gx3-fireflies i:nth-child(1) { left: 12%; top: 65%; --time: 4.8s; --delay: .2s; }
.gx3-fireflies i:nth-child(2) { left: 27%; top: 71%; --time: 5.6s; --delay: 1.4s; }
.gx3-fireflies i:nth-child(3) { left: 41%; top: 64%; --time: 4.4s; --delay: 2.1s; }
.gx3-fireflies i:nth-child(4) { left: 62%; top: 70%; --time: 5.3s; --delay: .7s; }
.gx3-fireflies i:nth-child(5) { left: 77%; top: 62%; --time: 4.9s; --delay: 1.8s; }
.gx3-fireflies i:nth-child(6) { left: 89%; top: 69%; --time: 5.8s; --delay: 2.6s; }

.gx3-mobile-features {
  display: none;
}

.gx3-mobile-clear-lower {
  display: none;
}

@keyframes gx3-scene-breathe {
  50% { transform: scale(1.008); filter: brightness(1.025); }
}

@keyframes gx3-button-breathe {
  50% {
    transform: translate(-50%, -50%) scale(1.018);
    box-shadow:
      0 17px 40px rgba(255, 172, 55, .36),
      inset 0 2px 0 rgba(255,255,255,.66);
  }
}

@keyframes gx3-firefly {
  0%,100% { opacity: 0; transform: translate(0, 8px) scale(.55); }
  35% { opacity: .8; }
  65% { opacity: .35; transform: translate(8px, -15px) scale(1); }
  82% { opacity: .72; transform: translate(-5px, -22px) scale(.78); }
}

@media (max-width: 700px) {
  .gx3-enter-splash {
    align-items: stretch;
    overflow: hidden;
  }

  .gx3-blur-bg {
    background-image:
      linear-gradient(rgba(2,8,25,.25), rgba(2,8,25,.25)),
      url("/static/park-ui-mobile.webp");
  }

  .gx3-artboard {
    width: 100vw;
    height: 100dvh;
    aspect-ratio: auto;
    box-shadow: none;
  }

  .gx3-scene {
    object-fit: cover;
  }

  .gx3-mobile-clear-lower {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    filter: none;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0 61%, rgba(0,0,0,.45) 65%, #000 69% 100%);
    mask-image: linear-gradient(to bottom, transparent 0 61%, rgba(0,0,0,.45) 65%, #000 69% 100%);
  }

  .gx3-enter-btn {
    top: 41.8%;
    width: 84%;
    height: 14%;
    min-width: 0;
    min-height: 118px;
    border-color: transparent;
    color: transparent;
    background: transparent;
    box-shadow: none;
    text-shadow: none;
    animation: none;
    -webkit-tap-highlight-color: transparent;
  }

  .gx3-enter-btn:disabled,
  .gx3-enter-btn:not(:disabled):hover {
    border-color: transparent;
    color: transparent;
    background: transparent;
    box-shadow: none;
    filter: none;
  }

  .gx3-fireflies i:nth-child(n+5) {
    display: none;
  }

  .gx3-mobile-features {
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: max(16px, env(safe-area-inset-bottom));
    z-index: 5;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: minmax(80px, auto);
    gap: 9px;
  }

  .gx3-feature {
    min-height: 80px;
    height: auto;
    display: grid;
    grid-template-columns: 38px 1fr;
    align-items: center;
    gap: 9px;
    padding: 11px 12px;
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 17px;
    color: var(--gx3-text);
    background: rgba(8, 25, 55, .88);
    box-shadow: 0 12px 28px rgba(0,0,0,.23);
    backdrop-filter: blur(14px);
  }

  .gx3-feature > span {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    background: rgba(255,255,255,.1);
    font-size: 21px;
  }

  .gx3-feature strong,
  .gx3-feature small {
    display: block;
  }

  .gx3-feature strong {
    font-size: 13px;
    font-weight: 950;
    line-height: 1.3;
  }

  .gx3-feature small {
    margin-top: 3px;
    color: rgba(235,243,255,.72);
    font-size: 10px;
    line-height: 1.35;
  }

  .gx3-feature-purple { border-color: rgba(174,124,255,.35); }
  .gx3-feature-green  { border-color: rgba(157,237,100,.35); }
  .gx3-feature-blue   { border-color: rgba(105,190,255,.35); }
  .gx3-feature-gold   { border-color: rgba(255,196,83,.38); }
}

@media (max-width: 380px) {
  .gx3-mobile-features {
    gap: 8px;
    left: 10px;
    right: 10px;
    bottom: max(9px, env(safe-area-inset-bottom));
  }

  .gx3-feature {
    padding-inline: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gx3-scene,
  .gx3-enter-btn,
  .gx3-fireflies i {
    animation: none !important;
  }
}
