/* Scene 4b, your website too: the studio behind Terminal 42 builds the agency's website.
   Two real sites play as films on screens in a dark room: the live one (Pangea Ring) large, its own light
   spilling round it; the concept smaller, in front of its corner; the studio's claims in the quarter they leave. */

.sc--web {
  --w-gap: clamp(28px, 3.4vw, 64px);
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr);
  row-gap: clamp(26px, 4.6svh, 56px);
  min-height: max(100svh, 640px);
  padding: clamp(96px, 12svh, 140px) var(--gut) calc(env(safe-area-inset-bottom, 0px) + clamp(100px, 12svh, 130px));
  color: var(--bone); isolation: isolate; overflow: clip;
  /* the room: the fares' warm dark, a little warmer where the screens stand */
  background: radial-gradient(80% 70% at 66% 56%, #2a1f1a 0%, rgba(28, 21, 18, 0) 72%), var(--cocoa);
}
.motion .sc--web { height: max(100svh, 640px); }

.w-hl { grid-row: 1; position: relative; z-index: 3; font-size: clamp(44px, 6.2vw, 132px); font-weight: 520; font-stretch: 125%; line-height: .9; letter-spacing: -.04em; white-space: nowrap; }
.w-hl__b { color: var(--dusk); }

/* ---------- the stage: everything in it is measured from the frame (the section's own sizes, restated), so it holds
   at any size. Not a container query: WebKit moves the scroll position when a pinned scene holds a container. ---------- */
.w-stage {
  grid-row: 2; position: relative; min-height: 0;
  --cap: clamp(54px, 6.6svh, 66px);
  --stw: calc(100vw - var(--gut) * 2);
  --sth: calc(max(100svh, 640px) - clamp(96px, 12svh, 140px) - env(safe-area-inset-bottom, 0px) - clamp(100px, 12svh, 130px) - clamp(44px, 6.2vw, 132px) * .9 - clamp(26px, 4.6svh, 56px));
  /* the live site's screen: as wide as the stage allows, never taller than the stage minus its caption */
  --bw: min(var(--stw) * .6, (var(--sth) - var(--cap)) * 1.5);
  --bh: calc(var(--bw) * .625 + max(20px, var(--bw) * .034));
  --sw: calc(var(--bw) * .42);
}

/* the live site's own light on the room, drawn from the film as it plays */
.w-glow { position: absolute; z-index: 0; right: 0; top: 0; width: var(--bw); height: var(--bh); pointer-events: none; }
.w-glow canvas {
  position: absolute; inset: -16% -12% -34%; width: 124%; height: 150%; max-width: none;
  filter: blur(clamp(44px, 5.4vw, 96px)) saturate(1.3); opacity: 0; transition: opacity 1.4s;
}
.w-glow canvas.is-lit { opacity: .4; }

.w-film { position: absolute; z-index: 1; margin: 0; }
.w-film--ring { right: 0; top: 0; width: var(--bw); }
.w-film--hand { z-index: 2; width: var(--sw); top: calc(var(--bw) * .055); right: calc(var(--bw) * .9); }

/* ---------- a screen: a quiet browser frame, the film inside it ---------- */
.w-scr {
  position: relative; overflow: hidden; container-type: inline-size; border-radius: 12px; background: #0d0a09;
  box-shadow: 0 0 0 1px rgba(244, 238, 230, .1), 0 60px 100px -40px rgba(0, 0, 0, .85), 0 16px 34px rgba(0, 0, 0, .42);
}
.w-film--hand .w-scr { border-radius: 9px; box-shadow: 0 0 0 1px rgba(244, 238, 230, .12), 0 40px 70px -24px rgba(0, 0, 0, .9), 0 10px 24px rgba(0, 0, 0, .5); }
.w-scr__bar {
  position: relative; display: flex; align-items: center; height: max(20px, 3.4cqw); padding: 0 max(9px, 1.6cqw);
  background: #191311; box-shadow: inset 0 -1px 0 rgba(244, 238, 230, .06);
}
.w-scr__dots { display: flex; gap: max(4px, .7cqw); }
.w-scr__dots i { width: max(5px, .78cqw); height: max(5px, .78cqw); border-radius: 50%; background: rgba(244, 238, 230, .17); }
.w-scr__url {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: inline-flex; align-items: center; gap: .7em; height: 64%; padding: 0 1.5em;
  border-radius: 99px; background: rgba(244, 238, 230, .06); font-family: var(--f-mono); font-size: max(9px, 1.24cqw); letter-spacing: .04em; color: var(--bone-3); white-space: nowrap;
}
.w-scr__url svg { flex: none; width: .82em; height: auto; }
.w-scr__view { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: #0d0a09; }
.w-scr__poster, .w-scr__v { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; }
.w-scr__glare {
  position: absolute; inset: 0; pointer-events: none; mix-blend-mode: screen;
  background: linear-gradient(112deg, rgba(255, 255, 255, .07) 0%, rgba(255, 255, 255, .02) 24%, transparent 36%, transparent 74%, rgba(255, 236, 214, .04) 100%);
}

/* the films can be stopped: one quiet control in the live site's frame */
.w-play {
  appearance: none; border: 0; margin: 0; padding: 0; cursor: pointer;
  position: absolute; z-index: 2; right: max(7px, 1.2cqw); top: calc(max(20px, 3.4cqw) / 2); translate: 0 -50%;
  display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%;
  background: transparent; color: var(--bone-3); box-shadow: inset 0 0 0 1px rgba(244, 238, 230, .18);
  transition: color .3s, background .3s, box-shadow .3s;
}
.w-play svg { grid-area: 1 / 1; transition: opacity .25s; }
.w-play__play { opacity: 0; }
.w-play[aria-pressed="true"] .w-play__pause { opacity: 0; }
.w-play[aria-pressed="true"] .w-play__play { opacity: 1; }
.w-play:hover { color: var(--ink); background: var(--bone); box-shadow: inset 0 0 0 1px var(--bone); }
.w-play:active { background: #e7ded2; }
.w-play:focus-visible { border-radius: 50%; }

/* ---------- captions, in the page's mono ---------- */
.w-cap {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 5px 18px; margin-top: clamp(12px, 1.6svh, 18px);
  font-family: var(--f-mono); font-size: var(--t-lab); line-height: 1.5; letter-spacing: .12em; text-transform: uppercase; color: var(--bone-3);
}
.w-cap__k { display: inline-flex; gap: 1.2em; }
.w-cap__n { color: var(--dusk); }
.w-cap__t { color: var(--bone); }
.w-cap__s { flex-basis: 100%; font-family: var(--f-wide); font-size: var(--t-cap); font-stretch: 108%; line-height: 1.42; letter-spacing: 0; text-transform: none; color: var(--bone-2); }
.w-cap__a {
  display: inline-flex; align-items: center; gap: .6em; color: var(--bone-2); text-decoration: none; text-transform: none; letter-spacing: .04em;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .5s var(--ease-out), color .3s;
}
.w-cap__a:hover { color: var(--bone); background-size: 100% 1px; }
.w-cap__a svg { flex: none; transition: transform .45s var(--ease-out); }
.w-cap__a:hover svg { transform: translate(2px, -2px); }
/* the concept's caption stands to its left, level with its frame */
.w-film--hand .w-cap {
  position: absolute; right: calc(100% + clamp(16px, 1.8vw, 30px)); top: 0; margin: 0;
  flex-direction: column; flex-wrap: nowrap; align-items: flex-end; gap: 6px; text-align: right;
  width: max-content; max-width: max(0px, min(320px, var(--stw) - var(--bw) * .9 - var(--sw) - 24px));
}
.w-film--hand .w-cap__s { flex-basis: auto; }
/* narrower frames: the concept's number stands over its name, so the name keeps to one line */
@media (min-width: 861px) and (max-width: 1180px) and (orientation: landscape) {
  .w-film--hand .w-cap__k { flex-direction: column; align-items: flex-end; gap: 4px; }
}

/* ---------- the studio's claims, in the quarter the screens leave, ending level with the live site's caption ---------- */
.w-copy { position: absolute; z-index: 1; left: 0; bottom: 0; width: min(620px, var(--stw) - var(--bw) - var(--w-gap)); }
.w-say { font-size: clamp(20px, 2vw, 38px); font-weight: 500; font-stretch: 112%; line-height: 1.1; letter-spacing: -.02em; text-wrap: balance; }
.w-say__a { color: var(--bone-2); }
.w-say__b { color: var(--bone); }
.w-say .o42 { --o42-ink: var(--bone-2); }
.w-spec { margin: clamp(18px, 3svh, 30px) 0 0; }
.w-spec div { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 18px; padding: 11px 0 12px; border-top: 1px solid var(--hair); }
.w-spec div:last-child { border-bottom: 1px solid var(--hair); }
.w-spec dt { font-size: clamp(14px, 1.02vw, 17px); font-weight: 520; font-stretch: 108%; letter-spacing: -.01em; }
.w-spec dd { margin: 0; font-family: var(--f-mono); font-size: var(--t-lab); letter-spacing: .1em; text-transform: uppercase; color: var(--bone-3); }
.w-spec div:last-child dd { color: var(--dusk); }

/* ---------- phones and portrait screens: the screens stack, the concept offset to the right ---------- */
@media (orientation: portrait), (max-width: 860px) {
  .sc--web, .motion .sc--web { display: block; height: auto; min-height: 0; padding: clamp(96px, 13svh, 130px) var(--gut) clamp(120px, 17svh, 160px); }
  .w-hl { font-size: clamp(40px, 11.6vw, 92px); }
  .w-hl__a, .w-hl__b { display: block; }
  .w-stage { margin-top: clamp(30px, 5svh, 52px); }
  .w-film, .w-film--ring, .w-film--hand { position: relative; left: auto; right: auto; top: auto; }
  /* short landscape phones: a screen is never taller than the screen it is seen on */
  .w-film--ring { width: min(100%, (100svh - 110px) * 1.45); }
  .w-film--hand { width: min(80%, (100svh - 110px) * 1.2); margin: clamp(34px, 6svh, 56px) 0 0 auto; }
  .w-glow { width: min(100%, (100svh - 110px) * 1.45); height: auto; aspect-ratio: 1 / .659; right: auto; left: 0; }
  .w-film--hand .w-cap { position: static; width: auto; max-width: none; align-items: flex-end; margin-top: 12px; }
  .w-scr { border-radius: 10px; }
  .w-film--hand .w-scr { border-radius: 8px; }
  .w-copy { position: relative; left: auto; bottom: auto; width: auto; max-width: 560px; margin-top: clamp(48px, 8svh, 80px); }
  .w-say { font-size: clamp(22px, 6.2vw, 34px); }
  .w-glow canvas.is-lit { opacity: .34; }
}
@media (max-width: 420px) {
  .w-cap__a { letter-spacing: .02em; }
}
.w-hl .word { display: inline-block; }
html:not(.js) .w-play { display: none; }
