/* Direction A2 - Seamless in motion. Enabled TOGETHER with dir-seamless.css, and after it: everything that is not
   the home page is Seamless untouched. The base rules here draw a complete, static page. The script only ever ADDS
   `.is-live` (pinning, the roll, the pan), so with no script or with reduced motion nothing is pinned or hidden. */

/* fixed only while the script is driving (html.m-live): with no script it stays a normal bar that scrolls away.
   Past the three scroll acts it slides off, because a transparent bar over a grid of photographs is unreadable. */
html.m-live[data-page="home"] .t-nav { position: fixed; transition: color .3s, transform .45s cubic-bezier(.2, .7, .2, 1); }
html.m-live.m-nav-away[data-page="home"] .t-nav { transform: translateY(-110%); }
/* these sheets are not swept paper: no tuck-under, no rounded foot, no drop shadow */
.t-main > section.m-open, .t-main > section.m-roll, .t-main > section.m-doors, .t-main > section.m-close { margin-top: 0; border-radius: 0; box-shadow: none; }

/* every cut-out person: stands on the floor of its sheet, in FRONT of the type */
.m-cut { position: absolute; z-index: 2; bottom: 0; width: auto; max-width: none; pointer-events: none; transform-origin: 50% 100%; user-select: none; }

/* ---------- 1  Open: blue paper, the headline printed on it, a person standing in front ---------- */
.m-open { position: relative; min-height: 100svh; display: flex; flex-direction: column; justify-content: flex-end; padding: 120px var(--pad) clamp(30px, 4vw, 60px) !important; overflow: hidden; }
.m-open .t-eyebrow { position: relative; z-index: 3; }
.m-h1 { position: relative; z-index: 1; font-stretch: 125%; font-weight: 800; text-transform: uppercase; letter-spacing: -.035em; line-height: .84; font-size: clamp(54px, 10.6vw, 224px); }
.m-open-cut { right: .4vw; height: 91%; transform: translate3d(0, calc(var(--e, 0) * -9vh), 0) scale(calc(1 + var(--e, 0) * .05)); }
.m-open-foot { position: relative; z-index: 3; display: flex; align-items: flex-end; gap: clamp(24px, 4vw, 70px); margin-top: clamp(22px, 2.6vw, 40px); }
.m-open-foot .t-lede, .m-open-foot .t-actions { margin-top: 0; }
.m-open-foot .t-lede { max-width: 32ch; }

/* ---------- 2  The Roll: the peak. Static = four stacked panels; live = one pinned stage ---------- */
.m-roll { position: relative; padding: 0 !important; }
.m-prelude { display: flex; align-items: center; min-height: 62svh; padding: 0 var(--pad); background-color: var(--f); }
.m-claim { font-size: clamp(20px, 2.1vw, 34px); line-height: 1.25; font-weight: 500; letter-spacing: -.01em; max-width: 26ch; }
.m-scene { position: relative; min-height: 100svh; overflow: hidden; background-color: transparent !important; }
.m-paper { position: absolute; inset: 0; background-color: var(--f); color: var(--k); }
.m-word { position: absolute; left: var(--pad); top: 47%; transform: translateY(-50%); font-stretch: 125%; font-weight: 800; text-transform: uppercase; letter-spacing: -.04em; line-height: .82; font-size: clamp(54px, 10.4vw, 220px); }
.m-cap { position: absolute; left: var(--pad); bottom: clamp(22px, 3vw, 40px); display: flex; align-items: center; gap: 10px; font-size: 12px; font-weight: 600; letter-spacing: .13em; text-transform: uppercase; }
.m-chip { width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; background-color: var(--f); }
.m-scene-cut { right: 9.6vw; height: 90%; }
.m-cut--lilac { right: 3vw; height: 86%; } .m-cut--tan { right: 10vw; height: 94%; } .m-cut--violet { right: 15.5vw; height: 92%; }
.m-bar, .m-dots { display: none; }

.m-roll.is-live { height: calc(var(--span) * 100svh); }
.m-roll.is-live .m-stage { position: sticky; top: 0; height: 100svh; overflow: hidden; background-color: var(--f); }
.m-roll.is-live .m-prelude { position: absolute; inset: 0; min-height: 0; z-index: 1; }
.m-roll.is-live .m-prelude .m-claim { transform: translateY(-16vh); }        /* sits where the first word will land, so the sentence runs on */
.m-roll.is-live .m-scene { position: absolute; inset: 0; min-height: 0; z-index: calc(var(--i) + 2); }
/* the paper comes down like a curtain, over the last scene and the person in it */
.m-roll.is-live .m-paper { clip-path: inset(0 0 calc((1 - var(--r, 0)) * 100%) 0); }
/* ...and then the new person rises in front of it, and keeps drifting while the paper holds still: that difference is the depth */
.m-roll.is-live .m-scene-cut { transform: translate3d(0, calc((1 - var(--s, 0)) * 104%), 0) scale(calc(1 + var(--z, 0) * .04)); }
.m-roll.is-live .m-bar { display: block; position: absolute; z-index: 1; left: 0; right: 0; top: 0; height: 20px; margin-top: -10px; opacity: var(--b, 0); transform: translate3d(0, calc(var(--r, 0) * 100svh), 0);
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, .18), rgba(255, 255, 255, .55) 32%, rgba(255, 255, 255, .1) 50%, rgba(0, 0, 0, .42)); box-shadow: 0 12px 22px rgba(0, 0, 0, .3); }
.m-roll.is-live .m-dots { display: flex; flex-direction: column; gap: 12px; position: absolute; z-index: 30; left: clamp(14px, 1.6vw, 24px); top: 50%; transform: translateY(-50%); color: var(--live-ink, #0b0b0c); }
.m-dot { width: 16px; height: 16px; border-radius: 50%; background-color: var(--c); border: 2px solid currentColor; transition: transform .2s; }
.m-dot:hover { transform: scale(1.25); } .m-dot[aria-pressed="true"] { box-shadow: 0 0 0 3px currentColor; }

/* ---------- 3  Three doors: sideways travel, because sideways reads as options ---------- */
.m-doors { position: relative; padding: var(--gap-y) 0 !important; }
.m-rail { display: flex; flex-direction: column; gap: 16px; padding: 0 var(--pad); }
.m-rail-head .t-sec-lede { margin-top: 16px; }
.m-rail .s-door { min-height: 0; }
.m-rail .s-door-label { margin-top: 0; }
.m-rail-end { padding: 30px 0 10px; } .m-rail-end p { max-width: 34ch; }
.m-doors.is-live { height: calc(var(--span) * 100svh); padding: 0 !important; }
.m-doors.is-live .m-pan-stage { position: sticky; top: 0; height: 100svh; overflow: hidden; display: flex; align-items: center; }
.m-doors.is-live .m-rail { flex-direction: row; align-items: stretch; width: max-content; transform: translate3d(calc(var(--tx, 0) * -1px), 0, 0); will-change: transform; }
.m-doors.is-live .m-rail > * { flex: none; }
.m-doors.is-live .m-rail-head { width: clamp(320px, 36vw, 600px); align-self: center; padding-right: 3vw; }
.m-doors.is-live .s-door { width: clamp(300px, 31vw, 500px); height: min(74svh, 720px); }
.m-doors.is-live .m-rail-end { width: clamp(300px, 30vw, 460px); align-self: center; padding: 0 0 0 3vw; }

/* ---------- 4  Work: pictures wipe in once. The clipped state exists only while the script has put it there ---------- */
.m-work .t-ph img { clip-path: inset(0); transition: clip-path .95s cubic-bezier(.2, .7, .2, 1) var(--d, 0ms), transform .5s cubic-bezier(.2, .7, .2, 1); }
.m-work .t-ph.will-wipe img { clip-path: inset(0 0 100% 0); }

/* ---------- 5  Close: the page inverts. Bare white paper, the smallest type on the site, then the name ---------- */
.m-close { padding: clamp(80px, 10vw, 170px) var(--pad) 0 !important; overflow: hidden; }
.m-close-cols { display: grid; grid-template-columns: 1.4fr 1fr auto; gap: clamp(24px, 5vw, 90px); align-items: start; max-width: var(--max); margin-inline: auto; }
.m-close-h { font-size: clamp(22px, 2vw, 30px); font-weight: 700; letter-spacing: -.01em; margin-bottom: 14px; }
.m-close-p { font-size: 16px; line-height: 1.7; } .m-close-p a { text-decoration: none; border-bottom: 1px solid transparent; } .m-close-p a:hover { border-bottom-color: currentColor; }
.m-close .t-hours div { padding: 9px 0; border-top-width: 1px; font-size: 15px; font-weight: 500; } .m-close .t-hours dd { font-weight: 700; }
.m-close-act { display: grid; gap: 14px; justify-items: start; }
.m-close-link { font-size: 17px; font-weight: 700; text-decoration: none; border-bottom: 2px solid currentColor; padding-bottom: 3px; }
.m-close-link::after { content: " →"; } .m-close-link--2 { font-weight: 500; border-bottom-width: 1px; }
.m-mark { font-stretch: 125%; font-weight: 800; text-transform: uppercase; letter-spacing: -.045em; line-height: .78; white-space: nowrap; font-size: 9.35vw; margin: clamp(60px, 8vw, 130px) 0 -.055em; text-align: center; }

/* ---------- phone: art-directed, not shrunk. Type sits ABOVE the person here, never behind ---------- */
@media (max-width: 960px) {
  .m-close-cols { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .m-open { padding-top: 104px !important; justify-content: flex-start; min-height: 0; padding-bottom: 0 !important; }
  .m-h1 { font-size: 14vw; }                      /* CREATION is the longest line: it must fit 390 wide */
  .m-open-foot { flex-direction: column; align-items: flex-start; gap: 20px; }
  .m-open-cut { position: relative; right: auto; align-self: center; height: auto; width: 78%; margin-top: 8px; }
  .m-word { top: 14%; transform: none; font-size: 13vw; }   /* sized for MINUTES., the longest word */
  /* centred with auto margins, not a transform: the transform belongs to the rise */
  .m-scene-cut, .m-cut--lilac, .m-cut--tan, .m-cut--violet { left: 0; right: 0; margin-inline: auto; height: 60%; }
  .m-cut--lilac { height: 50%; }
  .m-cap { font-size: 10px; letter-spacing: .1em; top: calc(14% + 24vw); bottom: auto; }   /* under the word: at the foot it hid behind the legs */
  .m-roll.is-live .m-prelude .m-claim { transform: translateY(-22vh); }
  .m-roll.is-live .m-dots { display: none; }
  .m-mark { font-size: 9.1vw; }
}
@media (prefers-reduced-motion: reduce) { .m-open-cut { transform: none; } }
