/* Full-bleed light-tube hero carrying the logo, then a quiet catalogue on charcoal
   where every MLO is described by its own data: rooms, doors, world position.
   Corners are cut at 45 degrees like the strokes of the mark. */
/* Fonts are served from this site (OFL, licences in fonts/), no request to Google */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("fonts/archivo-var-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("fonts/archivo-var-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/ibm-plex-mono-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/ibm-plex-mono-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/ibm-plex-mono-500-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/ibm-plex-mono-500-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #0B0D12;
  --bg-raised: #10131A;
  --bg-glass: rgba(11, 13, 18, .74);
  --surface: #151922;
  --surface-hi: #1A2030;
  --line: #222835;
  --fg: #F5F7FA;
  --fg-soft: rgba(245, 247, 250, .86);
  --muted: #A3ACBC;
  --faint: #7A8496;
  --accent: #2B7FFF;
  --accent-text: #79ADFF;
  --accent-glow: rgba(43, 127, 255, .5);
  --shade: rgba(0, 0, 0, .9);

  --display: "Archivo", "Arial", system-ui, sans-serif;
  --body: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --gutter: clamp(16px, 4vw, 40px);
  --max: 1200px;
  --cut: 16px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-padding-top: 84px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--accent); color: var(--fg); }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; }
img { max-width: 100%; }

.wrap { max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }

/* Nav */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: calc(14px + env(safe-area-inset-top, 0px)) var(--gutter) 14px;
  border-bottom: 1px solid transparent;
  transition: background .3s, border-color .3s;
}
.nav.is-solid {
  background: var(--bg-glass);
  border-bottom-color: var(--line);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
}
.nav__brand { display: block; line-height: 0; }
.nav__brand img { display: block; height: 36px; width: auto; }
.nav__links { display: flex; gap: 28px; margin-left: auto; }
.nav__links a {
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .02em;
  text-decoration: none;
  transition: color .2s;
}
.nav__links a:hover { color: var(--fg); }

/* Buttons */
.btn {
  --cut: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 26px;
  font: 650 15px/1 var(--body);
  font-stretch: 112%;
  letter-spacing: .03em;
  text-decoration: none;
  color: var(--fg);
  border: 0;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut));
  transition: background .2s, filter .2s, transform .2s var(--ease);
}
.btn:disabled { opacity: .55; cursor: default; transform: none; filter: none; }
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--accent); }
.btn--primary:hover { filter: brightness(1.12) drop-shadow(0 0 18px var(--accent-glow)); }
.btn--ghost {
  background: rgba(245, 247, 250, .09);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.btn--ghost:hover { background: rgba(245, 247, 250, .16); }
.btn--small { --cut: 8px; min-height: 38px; padding: 0 18px; font-size: 14px; }

/* Light tubes: one fixed layer behind every page. Below the hero a veil dims it for reading. */
.bg-tubes {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(55% 45% at 12% 100%, rgba(43, 127, 255, .22), transparent 70%),
    radial-gradient(35% 35% at 85% 8%, rgba(43, 127, 255, .12), transparent 70%),
    var(--bg);
}
.bg-tubes__canvas {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  mix-blend-mode: screen;
  opacity: 0;
  transition: opacity .7s ease;
}
.tubes-live.tubes-here .bg-tubes__canvas { opacity: 1; }
.bg-tubes::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--bg);
  opacity: var(--veil, 0);
}
main, .footer { position: relative; z-index: 1; }
main { overflow-x: clip; }

/* Hero */
.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: max(640px, 100svh);
  padding: clamp(84px, 13vh, 120px) var(--gutter);
  overflow: hidden;
}
.hero__veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 34% 30% at 50% 47%, rgba(11, 13, 18, .42), rgba(11, 13, 18, 0) 100%);
}
.hero__content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  text-align: center;
  pointer-events: none;
}
.hero__content a { pointer-events: auto; }
.hero__logo {
  margin: 0 0 6px;
  width: min(560px, 80vw, 62vh);
  line-height: 0;
  filter: drop-shadow(0 0 16px var(--shade)) drop-shadow(0 0 42px rgba(11, 13, 18, .8));
}
.hero__logo svg { display: block; width: 100%; height: auto; overflow: visible; }
.hero__line {
  margin: 0;
  max-width: 34ch;
  font-size: clamp(16px, 2.1vw, 20px);
  font-stretch: 106%;
  color: var(--fg-soft);
  text-shadow: 0 0 18px var(--shade), 0 0 4px var(--shade);
  text-wrap: balance;
}
.hero__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.hero__hint {
  position: absolute;
  inset: auto 0 calc(28px + env(safe-area-inset-bottom, 0px)) 0;
  z-index: 2;
  margin: 0;
  padding-inline: var(--gutter);
  text-align: center;
  font: 500 11px/1.5 var(--mono);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(245, 247, 250, .55);
  pointer-events: none;
}
.hint--touch { display: none; }
@media (hover: none) {
  .hint--pointer { display: none; }
  .hint--touch { display: inline; }
}
html:not(.tubes-live) .hero__hint { visibility: hidden; }

@media (prefers-reduced-motion: no-preference) {
  .hero__hint { animation: hint 2.8s ease-in-out infinite; }
  .jx-white, .jx-studio { transform-box: fill-box; transform-origin: center; }
  .jx-white { animation: jx-settle 1s var(--ease) both; }
  .jx-blue-a { animation: jx-from-a 1.1s .2s var(--ease) both; }
  .jx-blue-b { animation: jx-from-b 1.1s .2s var(--ease) both; }
  .jx-word { animation: jx-rise .9s .45s var(--ease) both; }
  .jx-studio { animation: jx-settle .9s .7s ease both; }
  .jx-line-l, .jx-line-r { transform-box: fill-box; animation: jx-grow 1s .8s var(--ease) both; }
  .jx-line-l { transform-origin: right center; }
  .jx-line-r { transform-origin: left center; }
  .hero__line { animation: jx-rise .9s .85s var(--ease) both; }
  .hero__actions { animation: jx-rise .9s 1s var(--ease) both; }
}
@keyframes jx-settle { from { opacity: 0; transform: scale(.96); } }
@keyframes jx-from-a { from { opacity: 0; transform: translate(80px, -80px); } }
@keyframes jx-from-b { from { opacity: 0; transform: translate(-80px, 80px); } }
@keyframes jx-rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes jx-grow { from { transform: scaleX(0); } }
@keyframes hint { 50% { opacity: .4; } }

/* Sections */
.section { padding-block: clamp(80px, 11vw, 136px); }
.section__head { display: grid; gap: 18px; max-width: 760px; margin-bottom: clamp(44px, 6vw, 68px); }
.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  font: 500 12px/1 var(--mono);
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--accent-text);
}
.eyebrow::before {
  content: "";
  width: 11px;
  height: 14px;
  background: var(--accent);
  clip-path: polygon(55% 0, 100% 0, 45% 100%, 0 100%);
}
h2 {
  margin: 0;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  font-size: clamp(30px, 4.6vw, 54px);
  line-height: 1.04;
  letter-spacing: -.01em;
  text-transform: uppercase;
  text-wrap: balance;
}
.lede { margin: 0; max-width: 62ch; color: var(--muted); font-size: clamp(16px, 1.6vw, 18px); text-wrap: balance; }

.group + .group { margin-top: clamp(64px, 8vw, 96px); }
.group__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}
.group__head h3 {
  margin: 0;
  font: 750 15px/1.2 var(--display);
  font-stretch: 125%;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.group__meta { font: 500 12px/1.2 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--faint); }

.grid { display: grid; gap: 20px; }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* Store cards */
.card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--surface);
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
  transition: background .25s;
}
.card:hover { background: var(--surface-hi); }
.card__media { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-raised); }
.card__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .7s var(--ease);
}
.card:hover .card__media img { transform: scale(1.04); }
.tag {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 7px 10px 6px;
  font: 500 11px/1 var(--mono);
  letter-spacing: .16em;
  text-transform: uppercase;
}
.tag--paid { background: var(--accent); color: var(--fg); }
.card__body { display: flex; flex: 1; flex-direction: column; gap: 10px; padding: 22px 22px 26px; }
.card__title {
  margin: 0;
  font: 800 21px/1.15 var(--display);
  font-stretch: 125%;
  text-transform: uppercase;
  text-wrap: balance;
}
.card__place { margin: 0; color: var(--accent-text); font-size: 14px; font-weight: 550; }
.card__text { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.55; }
.card__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  margin-top: auto;
  padding-top: 8px;
  color: var(--fg);
  font-size: 15px;
  font-weight: 650;
  text-decoration: none;
}
.card__link::after { content: "\2192"; transition: transform .2s var(--ease); }
.card__link:hover { color: var(--accent-text); }
.card__link:hover::after { transform: translateX(4px); }

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 6px 0 0;
  border-block: 1px solid var(--line);
}
.stats > div { display: grid; gap: 6px; padding: 12px 0; }
.stats > div + div { padding-left: 14px; border-left: 1px solid var(--line); }
.stats dt { font: 500 10.5px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); }
.stats dd { margin: 0; font: 750 22px/1 var(--display); font-stretch: 112%; font-variant-numeric: tabular-nums; }
.coords {
  margin: 2px 0 0;
  font: 400 12.5px/1.4 var(--mono);
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.coords span { margin-right: 6px; color: var(--accent-text); }

/* Custom work: one clip recorded in game on stage, the commissions beside it */
#work .wrap { --max: 1360px; }
.reel { display: grid; grid-template-columns: minmax(0, 2.1fr) minmax(0, 1fr); gap: 20px; }
.reel__stage {
  position: relative;
  margin: 0;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--bg-raised) center / cover no-repeat;
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
}
.reel__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.reel__video, .reel__cap { transition: opacity .3s var(--ease); }
.reel__stage.is-switching .reel__video, .reel__stage.is-switching .reel__cap { opacity: 0; }
.tag--clip { z-index: 1; background: rgba(11, 13, 18, .72); color: var(--fg); }
.reel__cap {
  position: absolute;
  inset: auto 0 0 0;
  display: grid;
  gap: 6px;
  padding: 72px 28px 24px;
  background: linear-gradient(180deg, rgba(11, 13, 18, 0), rgba(11, 13, 18, .9));
  pointer-events: none;
}
.reel__room {
  display: flex;
  gap: 12px;
  margin: 0 0 4px;
  font: 500 11.5px/1 var(--mono);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent-text);
}
.reel__room span:first-child { color: var(--fg-soft); font-variant-numeric: tabular-nums; }
.reel__room.is-new span:last-child { animation: jx-rise .5s var(--ease); }
.reel__marks { position: absolute; inset: auto 0 0 0; height: 7px; pointer-events: none; }
.reel__marks i { position: absolute; bottom: 0; width: 2px; height: 7px; background: rgba(245, 247, 250, .55); }
.reel__title { margin: 0; font: 800 clamp(20px, 2.1vw, 28px)/1.1 var(--display); font-stretch: 125%; text-transform: uppercase; }
.reel__text { margin: 0; max-width: 58ch; color: var(--fg-soft); font-size: 15px; line-height: 1.5; }
.reel__cap .coords { margin: 2px 0 0; }
.reel__bar {
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
}
.reel__list { display: grid; grid-auto-rows: minmax(60px, 1fr); gap: 8px; margin: 0; padding: 0; list-style: none; }
.work {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "title title" "place facts";
  align-content: center;
  gap: 5px 12px;
  min-width: 0;
  padding: 10px 20px;
  background-color: var(--bg-raised);
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
  transition: background-color .2s;
}
.work--clip { cursor: pointer; }
.work--clip:hover { background-color: var(--surface); }
.work--clip:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--accent-text); }
.work.is-on { background-color: var(--surface-hi); box-shadow: inset 2px 0 0 var(--accent); }
.work > div { display: contents; }
.work__title { grid-area: title; margin: 0; font: 800 15.5px/1.2 var(--display); font-stretch: 125%; text-transform: uppercase; }
.work__place { grid-area: place; align-self: baseline; margin: 0; color: var(--accent-text); font-size: 13.5px; font-weight: 550; line-height: 1.2; }
.work__facts {
  grid-area: facts;
  align-self: baseline;
  display: flex;
  margin: 0;
  font: 500 11px/1.2 var(--mono);
  letter-spacing: .14em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--muted);
}
.work__facts span + span::before { content: "\00b7"; margin: 0 8px; color: var(--faint); }
.work__facts b { margin-right: 5px; font-weight: 600; letter-spacing: 0; font-variant-numeric: tabular-nums; color: var(--fg); }
.section__more { margin: 0; font: 500 11.5px/1.5 var(--mono); letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.section__more b { font-weight: 600; color: var(--accent-text); }

/* Custom MLOs */
.section--custom { background: linear-gradient(180deg, rgba(11, 13, 18, 0), rgba(16, 19, 26, .6)); border-top: 1px solid var(--line); }
.custom { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.custom .section__head { position: sticky; top: calc(100px + env(safe-area-inset-top, 0px)); margin: 0; }
.custom .btn { justify-self: start; margin-top: 10px; }
.steps { display: grid; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  column-gap: 16px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
}
.steps li:last-child { border-bottom: 1px solid var(--line); }
.steps li::before {
  content: counter(step, decimal-leading-zero);
  grid-row: span 2;
  font: 800 30px/1 var(--display);
  font-stretch: 125%;
  color: var(--accent);
}
.steps h3 {
  margin: 0 0 6px;
  font: 750 18px/1.25 var(--display);
  font-stretch: 118%;
  letter-spacing: .02em;
  text-transform: uppercase;
}
.steps p { margin: 0; color: var(--muted); }
.steps em { font-style: normal; color: var(--fg); }

/* Contact */
.section--contact { border-top: 1px solid var(--line); }
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px clamp(40px, 6vw, 96px); align-items: end; }
.contact .lede { margin-top: 18px; }
.contact h2 { margin-top: 18px; }
.contact__links { display: grid; gap: 12px; }
.contact__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  padding: 22px 24px;
  background: var(--surface);
  color: var(--fg);
  text-decoration: none;
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
  transition: background .2s;
}
.contact__row:hover { background: var(--surface-hi); }
.contact__label { font: 500 12px/1 var(--mono); letter-spacing: .18em; text-transform: uppercase; color: var(--faint); }
.contact__value { min-width: 0; font: 750 clamp(16px, 2vw, 20px)/1.2 var(--display); font-stretch: 112%; overflow-wrap: anywhere; }

/* Footer */
.footer { padding-block: 48px calc(48px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); }
.footer__inner { display: grid; justify-items: start; gap: 14px; }
.footer__logo { display: block; height: 32px; width: auto; }
.footer__claim { margin: 0; font: 500 11.5px/1.5 var(--mono); letter-spacing: .3em; text-transform: uppercase; color: var(--muted); }
.footer__small { margin: 0; font-size: 13px; color: var(--faint); }

@media (min-width: 1041px) {
  .reel__list { contain: size; overflow: hidden auto; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
  #work .section__head { position: relative; max-width: none; }
  #work .section__more { position: absolute; right: 0; bottom: 0; text-align: right; }
}
@media (max-width: 1040px) {
  .reel { grid-template-columns: minmax(0, 1fr); }
  .reel__list { grid-auto-rows: auto; }
  .grid--3 { grid-template-columns: minmax(0, 1fr); }
  .grid--3 .card { flex-direction: row; }
  .grid--3 .card__media { flex: 0 0 44%; aspect-ratio: auto; min-height: 240px; }
}
@media (max-width: 880px) {
  .custom { grid-template-columns: minmax(0, 1fr); }
  .custom .section__head { position: static; }
}
@media (max-width: 760px) {
  .nav__links { display: none; }
  .nav .btn { margin-left: auto; }
  .contact { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .nav__brand img { height: 28px; }
  .grid--3 .card { flex-direction: column; }
  .grid--3 .card__media { flex: none; aspect-ratio: 16 / 10; min-height: 0; }
  .steps li { grid-template-columns: 52px minmax(0, 1fr); }
  .steps li::before { font-size: 24px; }
  .reel__cap { padding: 48px 18px 16px; }
  .reel__text { display: none; }
  .work { padding: 12px 16px; }
}

/* Scroll motion: each page builds up when it arrives. On large screens one scroll moves a whole page.
   Without JS or with reduced motion everything simply stays visible. */
.js-motion [data-reveal] {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity .8s var(--ease), transform .9s var(--ease);
  transition-delay: calc(var(--d, 0) * 110ms);
}
.js-motion [data-reveal].is-in { opacity: 1; transform: none; }
.js-motion [data-reveal][data-dim] { opacity: .2; transform: translateX(28px); }
.js-motion [data-reveal][data-dim].is-in { opacity: 1; transform: none; }

.steps { position: relative; }
.steps::before {
  content: "";
  position: absolute;
  top: 0;
  left: -22px;
  width: 2px;
  height: 100%;
  background: var(--accent);
  transform-origin: top;
}
.js-motion .steps::before { transform: scaleY(0); transition: transform 1.5s var(--ease) .55s; }
.js-motion .steps.is-in::before { transform: none; }
@media (max-width: 880px) { .steps::before { display: none; } }

/* Pages: on large screens every section fills the screen, site.js turns one wheel step into one page */
@media (min-width: 900px) and (min-height: 620px) {
  html.paging { scroll-padding-top: 0; }
  .section.page {
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-block: 84px 32px;
  }
  .section.page > .wrap { width: 100%; }
  .page .section__head { max-width: 1000px; margin-bottom: clamp(20px, 3.5vh, 40px); }
  .page .group__head { margin-bottom: 18px; padding-bottom: 12px; }
  .page .card__body { gap: 8px; padding: 18px 20px 20px; }
  .page h2 { font-size: clamp(28px, min(4.4vw, 6.4vh), 54px); }
  .page .card__media { aspect-ratio: 16 / 9; }
  .page .custom .section__head { position: static; }
}

/* Short laptop screens: drop the secondary lines so every page still fits on one screen */
@media (min-width: 900px) and (min-height: 620px) and (max-height: 820px) {
  .page .card__text { display: none; }
  .page .card__media { aspect-ratio: 2 / 1; }
}
@media (min-width: 900px) and (min-height: 620px) and (max-height: 800px) {
  #projects .lede, #work .lede, .page .coords { display: none; }
  .section.page { padding-block: 76px 24px; }
}
