.hero {
  position: relative;
  overflow: hidden;
}

.world-canvas {
  opacity: 0;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity;
}

.world-canvas.is-loaded {
  opacity: 1;
}

@media (min-width: 801px) {
  .hero .world-canvas {
    position: absolute;
    left: auto;
    right: max(12px, calc((100vw - var(--max)) / 2));
    top: calc(50% + var(--header) / 2);
    transform: translateY(-50%);
    width: min(48vw, 610px);
    height: min(48vw, 610px);
    aspect-ratio: 1 / 1;
    z-index: 0;
    pointer-events: auto;
  }

  .hero .shell {
    position: relative;
    z-index: 2;
    pointer-events: none;
  }

  .hero-copy,
  .hero-copy a,
  .hero-copy button,
  .world-status {
    pointer-events: auto;
  }
}

@media (max-width: 800px) {
  .hero .world-canvas {
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
  }

  .hero-copy {
    position: relative;
    z-index: 2;
  }
}

.page-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background-color: #030108;
}

.page-hero::before {
  content: "";
  position: absolute;
  inset: var(--header) 0 0;
  z-index: -1;
  width: auto;
  aspect-ratio: auto;
  right: 0;
  top: var(--header);
  border: 0;
  border-radius: 0;
  background:
    linear-gradient(90deg, rgba(3, 1, 8, .98) 0%, rgba(3, 1, 8, .88) 42%, rgba(3, 1, 8, .18) 78%),
    linear-gradient(0deg, #030108 0%, transparent 28%);
  box-shadow: none;
  pointer-events: none;
}

.page-hero .world-canvas {
  position: absolute;
  inset: var(--header) 0 0;
  height: calc(100% - var(--header));
  z-index: -2;
}

@media (prefers-reduced-motion: reduce) {
  .page-hero {
    background: url("assets/images/digital-world.png") 68% center / cover;
  }

  .page-hero::before {
    background: linear-gradient(90deg, rgba(3, 1, 8, .98), rgba(3, 1, 8, .5));
  }
}
