/* ============================================================================
   THE 3D GALLERY (/world). The hall is a fixed canvas behind the page; each
   section of the page is one stop in the walk. Text cards accept the pointer,
   and everything else passes it through to the hall for dragging and clicks.
   ============================================================================ */

/* Brand: Prata headings and the MonteCarlo wordmark, the same as /ideas and
   the homepage. This page did not load either face before. */
@font-face{font-family:"Prata";src:url("/concepts/assets/fonts/prata-latin.woff2") format("woff2");font-weight:400;font-style:normal;font-display:swap}
@font-face{font-family:"MonteCarlo";src:url("/concepts/assets/fonts/montecarlo-wordmark.woff2") format("woff2");font-weight:400;font-style:normal;font-display:optional}
:root{--display:"Prata",Georgia,serif}
.wordmark{font-family:"MonteCarlo","Snell Roundhand",cursive;font-size:29px;line-height:1;color:var(--gold);text-decoration:none;white-space:nowrap}
.page-world{background:#050404}
.hall-stage{position:fixed;inset:0;z-index:0;overflow:hidden;background:#050404}
.hall-poster{
  position:absolute;inset:0;
  background:#050404 url("/motion/posters/world-desktop.webp") 50% 50% / cover no-repeat;
  transition:opacity 1s ease;
}
@media (max-aspect-ratio:19/20){
  .hall-poster{background-image:url("/motion/posters/world-mobile.webp")}
}
.hall-canvas{position:absolute;inset:0;width:100%;height:100%;display:block;opacity:0;transition:opacity .9s ease;cursor:grab;touch-action:pan-y}
.hall-canvas:active{cursor:grabbing}
.hall-ready .hall-canvas{opacity:1}
.hall-ready .hall-poster{opacity:0}

.page-world .bar{z-index:30}
.page-world main{position:relative;z-index:1;pointer-events:none}
.page-world main a,.page-world main button,.page-world .tour-card{pointer-events:auto}
.page-world footer{position:relative;z-index:1;background:rgba(5,4,4,.92)}

/* scroll lands softly on each stop */
html.tour-snap{scroll-snap-type:y proximity}
.page-world section.tour-stop{scroll-snap-align:start;scroll-margin-top:0}

/* ---------------------------------------------------------------- stops */
.tour-stop{
  min-height:100svh;display:flex;align-items:center;
  padding:calc(var(--bar-h) + 1.5rem) var(--gutter) clamp(4.5rem,9vh,6rem);
}
.tour-stop[data-card="right"]{justify-content:flex-end}
.tour-card{
  width:min(100%,27rem);
  background:rgba(10,9,8,.86);border:1px solid var(--panel-line);
  padding:clamp(1.25rem,2.4vw,1.85rem);
  -webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);
}
.page-world .placard{max-width:none;box-shadow:none;border:1px solid var(--panel-line);background:rgba(10,9,8,.86)}
.tour-card .prov{display:block;font-size:11.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--sky-ink-3)}
.tour-card h2{font-family:var(--display);font-weight:400;font-size:clamp(26px,2.4vw,34px);line-height:1.12;margin:.45rem 0 .7rem;color:var(--sky-ink);text-wrap:balance}
.tour-card p{color:var(--sky-ink-2);font-size:15px;line-height:1.62}
.tour-card .label{color:var(--gold-soft);letter-spacing:.24em;font-size:12px}
.tour-fallback{display:none;width:100%;height:auto;margin-bottom:1rem;border:1px solid var(--panel-line)}

/* the entrance */
.tour-intro .tour-card{width:min(100%,33rem);background:rgba(8,7,6,.62)}
.tour-intro h1.page-title{margin:.7rem 0 .9rem;max-width:14ch}
.tour-lede{font-size:clamp(15.5px,1.2vw,17px) !important}
.tour-hint-touch{display:none}
@media (pointer:coarse){.tour-hint-mouse{display:none}.tour-hint-touch{display:inline}}
.tour-index{list-style:none;counter-reset:ex;margin:1.1rem 0 0;border-top:1px solid var(--gold-line)}
.tour-index li{counter-increment:ex;border-bottom:1px solid var(--gold-line)}
.tour-index a{display:flex;gap:1rem;align-items:baseline;padding:.6rem 0;color:var(--sky-ink);text-decoration:none;font-size:15.5px}
.tour-index a::before{content:"0" counter(ex);font-size:11.5px;letter-spacing:.12em;color:var(--gold-soft)}
.tour-index a:hover{color:var(--gold-soft)}
.tour-list-link{margin-top:1rem}
.tour-card .textlink{color:var(--gold-soft);border-bottom-color:var(--gold-line-strong)}
.page-world .scene-caption--inline{position:static;inset:auto;margin-top:1.1rem;justify-content:flex-start;flex-wrap:wrap}

/* the last stop */
.tour-end .desk-list{margin:.7rem 0 0;color:var(--sky-ink-2)}

/* ---------------------------------------------------------------- the rail */
.tour-rail{
  position:fixed;z-index:25;left:50%;bottom:clamp(.9rem,2.4vh,1.6rem);transform:translateX(-50%);
  display:flex;align-items:center;gap:.9rem;
  padding:.5rem .9rem;border:1px solid var(--gold-line);border-radius:999px;
  background:rgba(8,7,6,.72);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);
}
.tour-rail-dots{display:flex;gap:.35rem}
.tour-rail a{display:block;padding:.45rem .2rem}
.tour-rail a span{display:block;width:14px;height:3px;border-radius:2px;background:rgba(243,238,230,.28);transition:width .35s ease,background-color .35s ease}
.tour-rail a:hover span{background:rgba(243,238,230,.6)}
.tour-rail a[aria-current] span{width:30px;background:var(--gold-soft)}
.tour-rail-label{font-size:12px;letter-spacing:.06em;color:var(--sky-ink-2);min-width:9.5rem;white-space:nowrap}

/* ---------------------------------------------------------------- free walk (computers) */
/* W A S D clear the placards away so the hall is open to walk; any scroll
   brings them back. The hint sits just above the stop rail. */
.page-world main,.page-world footer{transition:opacity .4s ease,visibility 0s linear 0s}
html.hall-walking .page-world main,html.hall-walking .page-world footer{opacity:0;visibility:hidden;transition:opacity .4s ease,visibility 0s linear .4s}
.walk-hint{
  position:fixed;z-index:26;left:50%;bottom:calc(clamp(.9rem,2.4vh,1.6rem) + 3.1rem);
  margin:0;padding:.45rem .95rem;border:1px solid var(--gold-line);border-radius:999px;
  background:rgba(8,7,6,.78);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);
  color:var(--sky-ink-2);font-size:12.5px;letter-spacing:.02em;white-space:nowrap;
  opacity:0;visibility:hidden;transform:translate(-50%,.4rem);pointer-events:none;
  transition:opacity .35s ease,transform .35s ease,visibility 0s linear .35s;
}
.walk-hint kbd{font:inherit;font-size:11px;color:var(--sky-ink);display:inline-block;min-width:1.6em;padding:.05rem .3rem;text-align:center;border:1px solid var(--gold-line-strong);border-radius:4px}
html.hall-walking .walk-hint{opacity:1;visibility:visible;transform:translate(-50%,0);transition:opacity .35s ease,transform .35s ease,visibility 0s}
@media (pointer:coarse){.walk-hint{display:none}}

/* ---------------------------------------------------------------- phones */
@media (max-width:739px){
  .tour-stop,.tour-stop[data-card="right"]{
    align-items:flex-end;justify-content:center;
    padding:calc(var(--bar-h) + 1rem) var(--pad) 4.4rem;
  }
  .tour-card{width:100%;padding:1.1rem 1.15rem}
  .tour-card p{font-size:14.5px}
  .tour-intro{align-items:flex-start}
  .tour-intro .tour-card{background:rgba(8,7,6,.72)}
  .tour-card h2{font-size:24px}
  .tour-rail{bottom:.7rem;padding:.35rem .7rem}
  .tour-rail-label{min-width:0;font-size:11.5px}
}

/* ---------------------------------------------------------------- without WebGL */
.hall-fallback .hall-canvas{display:none}
.hall-fallback .hall-poster{opacity:1}
.hall-fallback .tour-fallback{display:block}
.hall-fallback .tour-rail{display:none}
.hall-fallback .tour-stop{min-height:0;padding-top:clamp(2rem,5vw,3.5rem);padding-bottom:0}
.hall-fallback .tour-intro{min-height:70svh}
.hall-fallback .tour-end{padding-bottom:clamp(3rem,6vw,5rem)}

@media (prefers-reduced-motion:reduce){
  .hall-canvas,.hall-poster,.tour-rail a span,.walk-hint,
  .page-world main,.page-world footer,html.hall-walking .page-world main,html.hall-walking .page-world footer,html.hall-walking .walk-hint{transition:none}
}
@media (max-width:739px){
  /* the stop rail and scrolling already list the exhibits; keep the hall visible */
  .tour-intro{align-items:flex-end}
  .tour-intro .tour-index{display:none}
  .tour-intro h1.page-title{font-size:clamp(34px,10vw,44px)}
}
@media (max-width:739px){
  /* placards start halfway down, so the exhibit always shows above them; long
     placards simply make their stop a little taller than the screen */
  .tour-stop:not(.tour-intro),.tour-stop[data-card="right"]:not(.tour-intro){display:block;padding-top:50svh}
}
