/* The two objects share the counter. The inline cartridge uses its printed
   faces and moulded CSS sidewalls, so the landing page idles without WebGL. */
html { scrollbar-gutter: stable; }
#featured-holo {
  --sample-height: clamp(265px, 25.5vw, 390px);
  --pack-height: calc(var(--sample-height) * 1.06);
  min-height: calc(var(--sample-height) + 48px);
  pointer-events: auto;
}
.display-pack {
  position: absolute; left: 30%; top: 47%;
  width: auto; height: var(--pack-height); pointer-events: none; user-select: none;
  transform: translate(-50%, -50%) perspective(800px) rotateY(13deg) rotateZ(-11deg);
  filter: drop-shadow(4px 7px 2px #15223561) drop-shadow(8px 17px 8px #10233759);
}
.display-sample {
  position: absolute; left: 68%; top: 47%;
  width: calc(var(--sample-height) * .76); height: var(--sample-height);
  transform: translate(-50%, -50%); filter: drop-shadow(4px 7px 2px #14263b61) drop-shadow(8px 17px 8px #172e4766);
}
.display-ticket {
  position: absolute; height: 92%; width: auto; left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(7deg);
}
#featured-stage .binder-stage {
  --viewer-height: var(--sample-height);
  width: 100%; margin: 0; touch-action: pan-y;
}
#featured-stage .binder-casing {
  height: 92%;
  transform: translate(-50%, -50%) rotateZ(7deg) rotateX(calc(5deg + var(--angle-x,0deg)))
    rotateY(calc(164deg + var(--angle-y,0deg) + var(--turn,1) * 180deg));
}
#featured-stage .club-back-plate, #inspect-object .club-back-plate { display: block; width: 100%; height: 100%; }
#featured-stage .binder-stage, #inspect-object .binder-stage { cursor: grab; }
#featured-stage [data-grabbing="true"], #inspect-object [data-grabbing="true"] { cursor: grabbing; }
.display-controls {
  position: absolute; top: calc(47% + var(--sample-height) * .5 + 18px); left: 57%;
  transform: translateX(-50%); display: flex; gap: 0; color: var(--ink);
  background: #edf0e8; border: 1px solid #233b4a; box-shadow: 1px 2px 0 #2c435353;
}
.display-controls[hidden] { display: none; }
.display-controls button, #holo-inspector button {
  appearance: none; min-height: 42px; padding: 4px 13px; white-space: nowrap;
  font: 750 .87rem/1.15 var(--sans); color: var(--ink); cursor: pointer;
}
.display-controls button { border: 0; background: transparent; }
.display-name { display: block; align-content: center; max-width: clamp(105px, 13vw, 155px); padding-inline: 11px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font: italic 800 .96rem/42px var(--sans); }
.display-controls button { border-left: 1px solid #80909a; }
.display-controls button:hover, #holo-inspector button:hover { background: #fff5c7; }
.display-controls button:focus-visible, #holo-inspector button:focus-visible { outline: 3px solid #1a5490; outline-offset: 1px; }
#holo-inspector {
  border: 2px solid var(--ink); color: var(--ink); background: #f4f1e5; padding: 0;
  width: min(760px, calc(100vw - 28px)); max-height: 92dvh; overflow: auto;
  overscroll-behavior: contain; box-shadow: 4px 7px 0 #0c19274d;
}
#holo-inspector::backdrop { background: #0d2037cb; }
html:has(#holo-inspector[open]) { overflow: hidden; }
.inspect-top {
  display: flex; align-items: center; justify-content: space-between; gap: 15px;
  padding: 4px 12px 4px 20px; color: #fff7dd; background: #182e4b; border-bottom: 4px solid var(--yellow);
}
.inspect-top span { font: 700 .84rem/1.4 var(--mono); text-transform: uppercase; letter-spacing: .09em; }
#holo-inspector .inspect-top button { min-height: 36px; padding-inline: 11px; color: #fbf6e5; border: 1px solid #8b9ba6; background: transparent; }
#holo-inspector .inspect-top button:hover { background: #294763; }
.inspect-layout { display: grid; grid-template-columns: minmax(0,.92fr) minmax(0,1fr); align-items: center; gap: 24px; padding: 18px 24px 24px; }
#inspect-object .binder-stage { --viewer-height: clamp(240px, 50svh, 410px); width: 100%; }
#holo-inspector .ticket-toggle { border: 1px solid #657482; background: transparent; }
.inspect-copy h2 { font: 900 clamp(1.7rem, 3.5vw, 2.6rem)/1.06 var(--brand); letter-spacing: -.055em; overflow-wrap: anywhere; }
.inspect-copy p { color: #3c4b57; line-height: 1.42; margin-top: 12px; }
#holo-source .archive-source { align-items: flex-start; flex-direction: column; gap: 12px; margin-top: 18px; padding: 16px 0 0; border: 0; border-top: 1px solid #abb0a9; background: transparent; box-shadow: none; }
@media (max-width: 880px) and (min-width: 651px) {
  #featured-holo { --sample-height: clamp(212px, 29vw, 257px); }
  .display-pack { left: 29%; }
  .display-sample { left: 69%; }
}
@media (max-width: 650px) {
  #featured-holo { --sample-height: clamp(163px, 45vw, 240px); height: calc(var(--sample-height) + 70px); min-height: auto; }
  .display-pack { left: 37%; top: 43%; }
  .display-sample { left: 66%; top: 44%; }
  .display-controls { top: auto; bottom: 5px; left: 53%; }
  .display-controls button { min-height: 42px; }
}
@media (max-width: 400px) { html { scrollbar-gutter: auto; } }
@media (max-width: 580px) {
  .inspect-layout { grid-template-columns: 1fr; gap: 16px; padding: 8px 16px 20px; }
  #inspect-object .binder-stage { --viewer-height: clamp(240px, 47svh, 375px); }
  .inspect-copy h2 { font-size: 1.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  #featured-stage .binder-stage .binder-casing { transition: none; }
}
