/* A shared dark studio. The lettering sits on the back wall, below the moving assembly. */
body {
  background-color: #050910;
}

#scene.sticky {
  isolation: isolate;
  background:
    radial-gradient(ellipse at 63% 50%, rgb(37 73 118 / 46%), transparent 53%),
    radial-gradient(ellipse at 29% 35%, rgb(23 47 79 / 64%), transparent 60%),
    linear-gradient(116deg, #09121f 2%, #07111e 39%, #070d17 68%, #03070d 100%);
}

#scene.sticky::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(to right, transparent calc(4vw - 1px), rgb(161 191 233 / 7%) 4vw, transparent calc(4vw + 1px)),
    linear-gradient(to left, transparent calc(4vw - 1px), rgb(161 191 233 / 7%) 4vw, transparent calc(4vw + 1px)),
    linear-gradient(180deg, rgb(4 7 14 / 90%) 0%, transparent 29%, transparent 71%, rgb(3 7 13 / 83%) 100%);
}

.bench-wordmark {
  position: absolute;
  left: 50%;
  width: 94%;
  top: max(95px, 13svh);
  transform: translateX(-50%);
  z-index: 0;
  pointer-events: none;
  user-select: none;
  opacity: clamp(0, calc(1 - var(--p, 0) * 3), 1);
}

.bench-wordmark svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.bench-wordmark text {
  font-family: Arial, Helvetica, sans-serif;
  font-weight: 500;
  fill: #e2e9f3;
}

#scene > .mj-world,
#scene > .camera {
  z-index: 2;
}

#scene[data-meter-view="travel"] > .bench-wordmark,
#scene[data-meter-view="meter"] > .bench-wordmark {
  visibility: hidden;
}

/* Both cover signatures use the same original Chinese wordmark and double arc. */
#scene .cover-logo {
  clip-path: inset(0 0 18% 0);
}

#scene .scene-controls {
  left: 4vw;
  bottom: clamp(28px, 5svh, 64px);
}

#scene .scene-toggle {
  border-radius: 999px;
  background: #e3eaf1;
  color: #101e2d;
  min-width: 138px;
  border-color: #edf4ff;
  box-shadow: inset 0 1px 1px white, 0 7px 22px #02061157;
}

#scene .scene-toggle:hover,
#scene .scene-toggle:focus-visible {
  background-color: #fff;
}

#scene .scene-toggle[aria-expanded="true"] {
  background: #102033;
  border-color: #587085;
  color: #f2f6fb;
}

@media (min-width: 1650px) {
  .bench-wordmark { width: min(94%, 1900px); }
}

@media (max-width: 800px) {
  .bench-wordmark {
    top: calc(52% - 21vw - 10vw);
    width: 94%;
  }
  #scene .scene-controls {
    left: max(5vw, 14px);
    bottom: max(9svh, env(safe-area-inset-bottom));
    gap: 16px;
  }
  #scene .scene-toggle { min-width: 122px; }
}

@media (max-width: 600px) and (orientation: portrait) {
  #scene:not(.ready) .scene-controls {
    top: min(calc(52% + 18.5vw + 100px), calc(100% - 74px));
    bottom: auto;
  }
}

@media (max-height: 520px) and (orientation: landscape) {
  .bench-wordmark { top: 65px; width: min(88%, 145svh); }
  #scene .scene-controls { bottom: 12px; }
}
