/* ============================================================
   IDEAS BY LEO — World mode
   One 3D world (fixed canvas) + plain supportive text.
   No cards. Text lives in the clear space above the run and
   never overlaps a domino; a soft halo (the world's own colour)
   keeps it legible. The 3D run is the whole show.
   ============================================================ */

.world-mode { background: #fff; }
.world-mode #main { display: none; }

#world { position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100dvh; display: block; z-index: 0; background: #fff; }
#driver { position: relative; width: 100%; height: 900vh; height: 900dvh; pointer-events: none; z-index: -1; }

/* foot scrim: a soft fade of the world's own colour so the closing text
   sits clear of the domino run at the reveal (no card, just an edge fade) */
#foot-scrim {
  position: fixed; left: 0; right: 0; bottom: 0; height: 46vh; z-index: 4; pointer-events: none;
  background: linear-gradient(to top, var(--world-bg, #fff) 16%, transparent);
  opacity: 0; transition: opacity 0.55s var(--ease-standard);
}
.finale-on #foot-scrim { opacity: 1; }

/* the beats layer */
#beats { position: fixed; inset: 0; z-index: 5; pointer-events: none; }
.beat {
  position: absolute; inset: 0; display: flex;
  align-items: flex-start; justify-content: center; text-align: center;
  padding: clamp(86px, 13vh, 148px) clamp(20px, 5vw, 60px) clamp(24px, 5vw, 50px);
  opacity: 0; will-change: opacity, transform;
}
.beat--foot { align-items: flex-end; }

/* ---- plain, centred text — no cards, no shadows ---- */
.beat__inner {
  max-width: min(640px, 92vw); width: 100%; margin-inline: auto;
  display: grid; gap: clamp(8px, 1vw, 14px); justify-items: center;
  color: var(--chrome-fg, #0a0a0a);
  transition: color 0.5s var(--ease-standard);
}
.beat__inner .eyebrow { color: var(--chrome-accent, #0a0a0a); opacity: 0.95; }
.beat .lead, .beat .body-copy, .tal__body, .lab__body, .pop__body { max-width: 54ch; margin-inline: auto; }

/* studio logos replace the studio headlines — rendered white on their worlds */
.studio-logo { display: block; width: auto; margin: 4px auto 8px; filter: brightness(0) invert(1); max-width: 82vw; }
.studio-logo--lab { height: clamp(78px, 12.5vw, 132px); }
.studio-logo--pop { height: clamp(82px, 13vw, 138px); }
/* Talisman — clean text wordmark (white TALIS + yellow MAN) */
.tal-logo { display: block; font-family: var(--font-tal-display); text-transform: uppercase;
  letter-spacing: 0.012em; line-height: 1; font-size: clamp(3.2rem, 10.5vw, 6.6rem); margin: 4px auto 8px; }
.tal-logo .tw1 { color: #ffffff; font-weight: 700; }        /* TALIS — Posterama Bold (brand) */
.tal-logo .tw2 { color: var(--tal-yellow); font-weight: 400; } /* MAN — lighter (Regular) */
.tal__sub { font-family: var(--font-tal-display); font-weight: 700; text-transform: uppercase; letter-spacing: 0.09em;
  font-size: clamp(0.98rem, 1.7vw, 1.5rem); color: var(--tal-yellow); }
@media (max-width: 760px) { .studio-logo { max-width: 74vw; } }

/* type — restrained, supportive */
.beat__mega { font-family: var(--font-display); text-transform: uppercase; line-height: 0.92; letter-spacing: 0.01em;
  font-size: clamp(2.3rem, 4.6vw, 4.4rem); color: var(--chrome-fg); }
.beat__big  { font-family: var(--font-display); text-transform: uppercase; line-height: 0.94; letter-spacing: 0.01em;
  font-size: clamp(2rem, 3.6vw, 3.4rem); color: var(--chrome-fg); }
.beat__script { font-family: var(--font-script); font-size: clamp(1.4rem, 2vw, 2rem); color: var(--chrome-fg); line-height: 1; }
.beat .lead { font-size: clamp(1rem, 1.15vw, 1.16rem); line-height: 1.5; color: var(--chrome-fg); opacity: 0.92; }
.beat .body-copy { font-size: clamp(0.95rem, 1.05vw, 1.08rem); line-height: 1.55; color: var(--chrome-fg); opacity: 0.92; max-width: none; }
.beat__hint { font-family: var(--font-body); font-weight: 700; font-size: 11px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--chrome-fg); opacity: 0.7; display: inline-flex; align-items: center; gap: 9px; margin-top: 4px; }
.beat__arrow { display: inline-block; animation: bob 1.6s var(--ease-standard) infinite; }
@keyframes bob { 0%,100% { transform: translateY(0);} 50% { transform: translateY(5px);} }
.beat__belief {
  font-family: var(--font-display); text-transform: uppercase; font-size: clamp(1.1rem, 1.6vw, 1.5rem);
  line-height: 1.05; color: var(--chrome-fg); border-top: var(--b-bold) solid currentColor; padding-top: 12px; margin-top: 2px;
}
.beat__cta { align-self: center; margin-top: 8px; }

/* ---- studio accents (colour comes from the world) ---- */
.beat__sprint { font-family: var(--font-tal-display); font-weight: 900; text-transform: uppercase; letter-spacing: 0.015em;
  font-size: clamp(2.4rem, 5vw, 4.4rem); line-height: 0.94; color: var(--tal-yellow); }
.tal__body { font-family: var(--font-tal-body); font-size: clamp(0.98rem, 1.1vw, 1.14rem); line-height: 1.5; color: #F6E9FA; }
.beat__warm { font-family: var(--font-tal-body); font-style: italic; font-size: 0.98rem; color: var(--tal-yellow); max-width: 46ch; margin-inline: auto; }
.beat__cta--tal { background: var(--tal-yellow); color: var(--tal-purple-x); border-color: var(--tal-yellow); }
.beat__cta--tal::before { background: #fff; } .beat__cta--tal:hover { color: var(--tal-purple-x); }

.beat__lab { font-family: var(--font-lab-display); font-size: clamp(2.1rem, 3.8vw, 3.6rem); line-height: 1; color: var(--lab-cream); }
.beat__lab-sub { font-family: var(--font-lab-sub); text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700;
  font-size: clamp(0.95rem, 1.4vw, 1.35rem); color: var(--lab-orange); }
.lab__body { font-family: var(--font-lab-body); font-size: clamp(0.96rem, 1.05vw, 1.12rem); line-height: 1.5; color: var(--lab-cream); }
.beat__cta--lab { background: var(--lab-red); color: #fff; border-color: var(--lab-red); }
.beat__cta--lab::before { background: var(--lab-orange); } .beat__cta--lab:hover { color: #fff; }

.beat__pop { font-family: var(--font-pop-display); font-size: clamp(2.6rem, 4.8vw, 4.4rem); line-height: 0.84; color: #fff; }
.beat__pop-sub { font-family: var(--font-pop-sec); font-size: clamp(1.1rem, 1.8vw, 1.7rem); text-transform: uppercase; color: #fff; }
.beat__verbs { display: flex; flex-wrap: wrap; gap: 7px 16px; justify-content: center; }
.beat__verbs li { font-family: var(--font-pop-sec); text-transform: uppercase; font-size: clamp(0.95rem, 1.4vw, 1.3rem);
  color: #fff; border-bottom: 2px solid #fff; }
.pop__services { list-style: none; display: grid; gap: clamp(5px, 0.9vw, 11px); justify-items: center; margin: 6px 0; }
.pop__services li { display: inline-flex; align-items: baseline; gap: 13px; font-family: var(--font-pop-sec);
  text-transform: uppercase; font-size: clamp(1.15rem, 2.2vw, 2rem); line-height: 1; color: #fff; }
.pop__services .ps-no { font-family: var(--font-mono); font-size: 0.52em; font-weight: 700; opacity: 0.6; }
.pop__body { font-family: var(--font-pop-body); font-size: clamp(0.9rem,1.05vw,1.05rem); line-height: 1.5; color: #fff; }
.beat__cta--pop { background: #fff; color: #000; border-color: #fff; }
.beat__cta--pop::before { background: var(--tal-yellow); } .beat__cta--pop:hover { color: #000; }

/* ---- close ---- */
.beat__mark { width: 52px; color: var(--chrome-fg); justify-self: center; }
.beat__actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 4px; }
.beat__fine { font-size: 11px; color: var(--chrome-fg); opacity: 0.7; line-height: 1.7; margin-top: 4px; }

/* ---- next-destination scroll indicator ---- */
#next-dest {
  position: fixed; left: 50%; bottom: clamp(16px, 3vh, 30px); transform: translateX(-50%);
  z-index: 40; display: grid; justify-items: center; gap: 3px; text-align: center;
  color: var(--chrome-fg); background: none; pointer-events: auto; cursor: pointer;
  opacity: 0; transition: opacity 0.5s var(--ease-standard), color 0.5s;
}
#next-dest.is-on { opacity: 1; }
.nd-ey { font-family: var(--font-body); font-weight: 700; font-size: 9px; letter-spacing: 0.26em; text-transform: uppercase; opacity: 0.6; }
.nd-label { font-family: var(--font-display); text-transform: uppercase; font-size: clamp(0.92rem, 1.3vw, 1.18rem); letter-spacing: 0.03em; line-height: 1; }
.nd-line { width: 1px; height: 16px; background: currentColor; opacity: 0.5; margin-top: 2px; }
.nd-arrow { font-size: 14px; line-height: 1; animation: bob 1.6s var(--ease-standard) infinite; }

/* ---- reduced / no-webgl fallback: a plain, readable stacked page on white ---- */
.no-webgl #world,
.no-webgl #foot-scrim,
.no-webgl #progress,
.no-webgl #next-dest,
.no-webgl #cursor,
.no-webgl #driver { display: none; }
.no-webgl body { overflow: auto; cursor: auto; }
.no-webgl #beats { position: static; pointer-events: auto; }
.no-webgl .beat {
  position: relative; inset: auto; opacity: 1 !important; transform: none !important;
  pointer-events: auto; min-height: auto; padding: clamp(48px, 9vh, 96px) 22px;
  border-bottom: 1px solid #ececec;
}
.no-webgl .beat__inner { color: #0a0a0a; text-shadow: none; max-width: 640px; }
/* re-colour every element that is white/near-white on its 3D world so it reads on white */
.no-webgl .tal__body,
.no-webgl .lab__body,
.no-webgl .pop__body,
.no-webgl .beat__pop-sub,
.no-webgl .pop__services li,
.no-webgl .tal-logo .tw1 { color: #0a0a0a; }
.no-webgl .studio-logo { filter: none; }          /* stop inverting the wordmark SVGs to white */
.no-webgl .tal-logo .tw2 { color: #8a6a00; }      /* darker gold so "man" reads on white */
.no-webgl .tal__sub { color: #8a6a00; }
.no-webgl .beat__lab-sub { color: #c24e00; }
.no-webgl .beat__warm { color: #8a6a00; }
.no-webgl .pop__services .ps-no { color: #0a0a0a; opacity: 0.55; }

@media (max-width: 760px) {
  /* keep text compact + high so it never reaches the run, with side breathing room */
  .beat { padding: 64px 28px 22px; align-items: flex-start; }
  .beat--foot { align-items: flex-end; }
  .beat__inner { max-width: 100%; gap: 7px; }
  .beat .lead, .beat .body-copy, .tal__body, .lab__body, .pop__body { max-width: 100%; }
  .beat__mega { font-size: clamp(2rem, 10vw, 2.7rem); }
  .beat__big  { font-size: clamp(1.6rem, 8vw, 2.2rem); }
  .beat__script { font-size: clamp(1.2rem, 6vw, 1.6rem); }
  .beat .lead, .beat .body-copy, .tal__body, .lab__body, .pop__body { font-size: 0.9rem; line-height: 1.42; max-width: 92vw; }
  .beat__pop-sub, .beat__lab-sub { font-size: clamp(0.9rem, 3.4vw, 1.1rem); }
  .beat__warm { font-size: 0.86rem; }
  .beat__cta { padding: 12px 18px; font-size: 12px; margin-top: 4px; }
  .tal-logo { font-size: clamp(2.4rem, 14vw, 3.6rem); }
  .studio-logo--lab { height: clamp(58px, 16vw, 92px); }
  .studio-logo--pop { height: clamp(60px, 17vw, 96px); }
  .beat__fine { font-size: 10px; }
  #next-dest { bottom: 12px; }
  .nd-label { font-size: 0.9rem; }
  /* smaller header on phones */
  #nav { padding: 8px 14px; }
  .nav__brand svg { width: 46px; }
  .nav__cta { font-size: 8.5px; padding: 6px 9px; letter-spacing: 0.08em; }
}
