/* Redesign v3 draft: page 1 (wordmark) and page 2 (the system). Colours: sky #E80204, cream text, black model. */
:root { --red: #E80204; --cream: #FBF1DE; --ink: #1B0507; --dim: rgba(251, 241, 222, .72);
  /* the cursor-Vector's colour moments (old site palette) and easing */
  --surface-purple: #6254dc; --surface-coral: #ff6a1a; --surface-teal: #ffb584; --surface-amber: #ffdf94; --surface-violet: #2f2a45; --ease-out: cubic-bezier(.2, .8, .25, 1); }
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; background: var(--red); font-family: 'Outfit', system-ui, sans-serif; }
.track { height: 560vh; }

/* ============================ page 1 ============================ */
.stage { position: fixed; inset: 0; overflow: hidden; background: var(--red); }
/* a 16:9 box, scaled to cover the screen (the same fit as background-size: cover) and centred */
.box { position: absolute; left: 50%; top: 50%; width: max(100vw, 177.7778vh); height: max(56.25vw, 100vh); transform: translate(-50%, -50%); container-type: size; }
.layer { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.layer--people { top: 12%; height: 46%; pointer-events: none; }      /* only the band where the wordmark is (rows 12% to 58% of the frame) */

/* wordmark: real text, cream, in the sky like the key frame */
.word { position: absolute; left: 0; right: 0; top: 25%; margin: 0; text-align: center; color: var(--cream); font-weight: 500; will-change: transform, opacity; }
.word__name { display: block; font-size: 10cqw; line-height: 1; letter-spacing: -.035em; }
.word__sub { display: flex; align-items: center; justify-content: center; gap: 3cqw; margin-top: 1.1cqw; font-size: 2.6cqw; font-weight: 300; letter-spacing: .5em; text-indent: .5em; }
.word__sub b { font-weight: 300; }
.word__sub i { display: block; width: 5.1cqw; height: 1px; background: currentColor; opacity: .8; }
@media (max-aspect-ratio: 6/5) {   /* portrait screens show only the middle of the 16:9 frame, so the wordmark is sized to the screen */
  .word__name { font-size: 13.4vw; }
  .word__sub { gap: 3.6vw; margin-top: 1.6vw; font-size: 3.6vw; }
  .word__sub i { width: 6vw; }
}

.cue { position: fixed; left: 50%; top: 3.6vh; translate: -50% 0; display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 600; letter-spacing: .5em; text-indent: .5em; text-transform: uppercase; color: var(--cream); opacity: 0; transition: opacity .8s; pointer-events: none; z-index: 5; }
.cue.on { opacity: 1; }
.cue svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 0%, 100% { transform: translateY(-3px); opacity: .55; } 50% { transform: translateY(4px); opacity: 1; } }

/* the small studio label, top left, from the second screen on */
.brand { position: fixed; z-index: 30; left: 4cqw; left: max(16px, 4vw); top: max(14px, 2.6vh); color: var(--cream); font-size: 13px; font-weight: 600; letter-spacing: -.01em; text-decoration: none; opacity: 0; visibility: hidden; transition: opacity .5s, visibility .5s; }
.brand span { font-weight: 300; letter-spacing: .32em; font-size: 10px; margin-left: .4em; }
.brand.on { opacity: 1; visibility: visible; }
.brand:focus-visible { outline: 2px solid var(--cream); outline-offset: 4px; border-radius: 4px; }

/* the cursor-Vector (js/vector/cursor-vector.js, the old site's cursor): fine pointers only; touch keeps the system behaviour */
html.has-custom-cursor, html.has-custom-cursor * { cursor: none !important; }
html.has-custom-cursor .vector-input__field { cursor: text !important; }
.cursor-vector { position: fixed; left: 0; top: 0; z-index: 99; width: 96px; height: 96px; opacity: 0; pointer-events: none; transition: opacity .15s ease-out; }
.cursor-layer { position: fixed; inset: 0; z-index: 98; pointer-events: none; }
.cursor-answer { position: absolute; left: 0; top: 0; max-width: 18rem; margin: 0; padding: .55rem .85rem; border-radius: 1rem; background: color-mix(in srgb, var(--cream) 94%, transparent); box-shadow: 0 6px 20px rgba(40, 0, 0, .22); color: var(--ink); font-size: .95rem; font-weight: 500; line-height: 1.35; text-wrap: pretty; }
.cursor-answer--thinking { color: #5f4a46; font-size: .8rem; white-space: nowrap; }
.fragment { display: inline-block; }
/* the caret written straight into the page: a small Vector mark and a blinking caret, cream on the red */
.vector-input { position: absolute; display: flex; align-items: center; gap: .6rem; translate: 0 -50%; pointer-events: auto; }
.vector-input__mark { flex: none; width: 10px; height: 10px; border-radius: 55% 45% 50% 50%; background: var(--ink); animation: vector-mark 2.4s ease-in-out infinite; }
@keyframes vector-mark { 50% { scale: 1.2; border-radius: 45% 55% 50% 50%; } }
.vector-input__field { min-width: 14ch; max-width: min(26rem, 60vw); padding: 0; border: 0; outline: 0; background: transparent; color: var(--cream); caret-color: var(--cream); font: inherit; font-size: 1.35rem; font-weight: 500; field-sizing: content; }
.vector-input__field::placeholder { color: var(--cream); opacity: .6; }
/* a question as particles (js/vector/absorb.js): each letter turns into a dot and is pulled into the Vector */
.absorb-particle { position: absolute; left: 0; top: 0; display: grid; place-items: center; translate: -50% -50%; }
.absorb-particle > * { grid-area: 1 / 1; }
.absorb-particle__glyph { white-space: pre; }
.absorb-particle__dot { width: 5px; aspect-ratio: 1; border-radius: 50%; background: var(--ink); opacity: 0; }
.absorb-mirror { position: fixed; white-space: pre; visibility: hidden; pointer-events: none; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { .vector-input__mark { animation: none; } }

/* ============================ page 2 ============================ */
.p2 { position: fixed; inset: 0; container-type: size; visibility: hidden; pointer-events: none; color: var(--cream); }
.p2.on { visibility: visible; }
.p2.live { pointer-events: auto; }
.eyebrow { margin: 0 0 1.6cqh; font-size: max(11px, .85cqw); font-weight: 500; letter-spacing: .42em; text-transform: uppercase; color: var(--dim); }

/* headline: a light first line and a heavy second line, tight, cream */
.p2__head { position: absolute; left: 4cqw; top: 9.6cqh; max-width: 62cqw; will-change: transform, opacity; }
.p2__title { margin: 0; font-size: clamp(28px, min(4.1cqw, 6.9cqh), 78px); line-height: 1.02; letter-spacing: -.035em; font-weight: 300; }
.p2__l1 { display: block; font-weight: 300; }
.p2__l2 { display: block; font-weight: 650; letter-spacing: -.04em; }
.p2__note { position: absolute; right: 4cqw; top: 10.4cqh; margin: 0; max-width: 21em; font-size: max(13px, 1.05cqw); line-height: 1.5; font-weight: 300; color: var(--dim); text-align: left; padding-left: 1.4cqw; border-left: 1px solid rgba(251, 241, 222, .4); will-change: transform, opacity; }

/* the model: a 16:9 box, sized so the whole of it fits between the headline and the foot */
.sys { position: absolute; left: 50%; top: 24cqh; width: min(68cqw, 94cqh); aspect-ratio: 16 / 9; transform: translateX(-50%); perspective: 1400px; }
.sys__tilt { position: absolute; inset: 0; transform-style: preserve-3d; will-change: transform, opacity; }
.sys__base, .sys__fx { position: absolute; display: block; user-select: none; -webkit-user-drag: none; }
.sys__base { inset: 0; width: 100%; height: 100%; }
.sys__fx { inset: 0; width: 100%; height: 100%; pointer-events: none; }
/* Vector has its own small canvas (about 320 x 320 model px around the disc), so the big effects canvas never redraws it at full size */
.sys__vec { position: absolute; display: block; left: 41.1%; top: 38.8%; width: 19.1%; height: 34%; pointer-events: none; }
/* the slow light pass: a gradient moved by transform (compositor only), clipped to the model's own shape by a mask */
.sys__sweep { position: absolute; inset: 0; overflow: hidden; pointer-events: none; -webkit-mask: url(../model/model.webp) center / 100% 100% no-repeat; mask: url(../model/model.webp) center / 100% 100% no-repeat; }
.sys__sweep i { position: absolute; top: 0; bottom: 0; left: 0; width: 28%; background: linear-gradient(90deg, rgba(255, 225, 170, 0), rgba(255, 225, 170, .5), rgba(255, 225, 170, 0)); transform: translate3d(-100%, 0, 0); animation: sweep 9s linear infinite; }
@keyframes sweep { 0% { transform: translate3d(-100%, 0, 0); } 30% { transform: translate3d(400%, 0, 0); } 100% { transform: translate3d(400%, 0, 0); } }
/* the six platforms: each one its own layer. They float slowly (CSS, compositor only), lean with the pointer by depth, and lift when selected. */
.plats { position: absolute; inset: 0; pointer-events: none; --u: 1px; }
.plat { position: absolute; display: block; user-select: none; -webkit-user-drag: none; transform-origin: 50% 80%;
  animation: plfloat var(--fd, 7s) ease-in-out var(--fl, 0s) infinite;
  translate: calc(var(--px, 0) * var(--d, 0) * var(--u)) calc(var(--py, 0) * var(--d, 0) * var(--u) * .5 - var(--lift, 0) * var(--u));
  transition: translate .45s cubic-bezier(.2, .8, .2, 1), filter .3s, opacity .3s; }
@keyframes plfloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(calc(var(--fa, 3) * var(--u) * -1)); } }
.plat.on { --lift: 16; filter: brightness(1.3) saturate(1.12) drop-shadow(0 calc(26 * var(--u)) calc(20 * var(--u)) rgba(70, 0, 0, .55)); }
.sys.has-active .plat:not(.on) { opacity: .72; }
.p2.q1 .plat, .p2.q2 .plat { animation: none; }
/* nothing on page 2 animates until page 2 is on screen */
.p2:not(.on) .plat, .p2:not(.on) .sys__sweep i { animation-play-state: paused; }
.p2.q2 .plat:not(.on) { display: none; }
.p2.q2 .plat.on { --lift: 0; transition: none; }

/* Vector: a button over the middle of the disc (the blob itself is drawn on the canvas) */
.vec { position: absolute; left: 48.4%; top: 49%; width: 11%; aspect-ratio: 1; transform: translate(-50%, -50%); border: 0; border-radius: 50%; background: transparent; cursor: pointer; padding: 0; }
.vec:focus-visible { outline: 2px solid var(--cream); outline-offset: 4px; }

/* discipline labels: number in a ring, small caps name; they sit beside their platform */
.chips { list-style: none; margin: 0; padding: 0; }
.chip { position: absolute; transform: translate(var(--tx, 0), -50%); will-change: opacity; }
.chip button { display: flex; align-items: center; gap: .7em; padding: .45em .7em .45em .45em; margin: -.45em; border: 0; border-radius: 999px; background: transparent; color: var(--cream); font: 500 max(11px, .82cqw)/1 'Outfit', system-ui, sans-serif; letter-spacing: .17em; text-transform: uppercase; cursor: pointer; white-space: nowrap; transition: background-color .2s, color .2s; }
.chip b { display: grid; place-items: center; width: 2.3em; height: 2.3em; border: 1px solid rgba(251, 241, 222, .6); border-radius: 50%; font-weight: 500; letter-spacing: 0; font-size: .92em; transition: border-color .2s, background-color .2s, color .2s; }
.chip button:hover, .chip button:focus-visible, .chip.active button { background: var(--cream); color: var(--ink); }
.chip button:hover b, .chip button:focus-visible b, .chip.active b { border-color: var(--ink); }
.chip button:focus-visible { outline: 2px solid var(--cream); outline-offset: 3px; }

/* foot: who we are on the left, the selected discipline on the right, a hairline above both */
.p2__foot { position: absolute; left: 4cqw; right: 4cqw; bottom: 4.2cqh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, min(46cqw, 600px)); gap: 4cqw; align-items: end; padding-top: 2.2cqh; border-top: 1px solid rgba(251, 241, 222, .4); will-change: transform, opacity; }
.who__line { margin: 0; font-size: clamp(18px, 2.1cqw, 38px); line-height: 1.12; font-weight: 300; letter-spacing: -.02em; }
.sel { height: 13.5cqh; padding-left: 2cqw; border-left: 1px solid rgba(251, 241, 222, .4); }
.sel__idle { margin: 0; font-size: max(13px, 1cqw); line-height: 1.5; font-weight: 300; color: var(--dim); max-width: 30em; }
.sel__num { margin: 0 0 .6cqh; font-size: max(11px, .8cqw); letter-spacing: .34em; text-transform: uppercase; font-weight: 500; color: var(--dim); }
.sel__name { margin: 0; font-size: clamp(20px, 2.1cqw, 38px); line-height: 1.05; font-weight: 600; letter-spacing: -.03em; }
.sel__line { margin: .8cqh 0 0; font-size: max(13px, 1cqw); line-height: 1.45; font-weight: 300; max-width: 34em; }
.sel__tags { margin: 1.2cqh 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: .5em .5em; }
.sel__tags li { padding: .32em .8em; border: 1px solid rgba(251, 241, 222, .5); border-radius: 999px; font-size: max(11px, .78cqw); letter-spacing: .08em; font-weight: 400; }

/* portrait and narrow screens: the model fills the width, the disciplines become a list under it */
@media (max-aspect-ratio: 6/5) {
  .p2__head { top: 12cqh; left: 6cqw; right: 6cqw; max-width: none; }
  .p2__title { font-size: 9.4cqw; }
  .eyebrow { font-size: 11px; }
  .p2__note { display: none; }
  .sys { top: 29cqh; width: 108cqw; }
  .chips { position: absolute; left: 5.4%; right: 5.4%; top: calc(100% + 3cqh); display: grid; grid-template-columns: 1fr 1fr; gap: 1cqh 2.4cqw; }
  .chip { position: static; transform: none; }
  .chip button { margin: 0; font-size: 10.5px; letter-spacing: .1em; padding: .35em .6em .35em .4em; border: 1px solid rgba(251, 241, 222, .3); width: 100%; }
  .p2__foot { grid-template-columns: 1fr; gap: 1cqh; bottom: 2.4cqh; left: 6cqw; right: 6cqw; padding-top: 1.4cqh; }
  .who__line { font-size: 5cqw; }
  .who .eyebrow { display: none; }
  .sel { padding-left: 4cqw; height: auto; min-height: 0; }
  .sel__idle, .sel__line { font-size: 13px; }
  .sel__name { font-size: 20px; }
}
/* quality levels (set by v3.js): lite drops the light pass, minimal also drops the live canvas */
.p2.q1 .sys__sweep, .p2.q2 .sys__sweep { display: none; }
.p2.q2 .sys__fx { display: none; }
@media (prefers-reduced-motion: reduce) { .sys__sweep { display: none; } .cue svg { animation: none; } .cue, .brand { transition: none; } .plat { animation: none; transition: none; } .cur i { animation: none; } }
