/* YUZ public site. Tokens mirror packages/yuz_ui (YuzColors): brand blue, silver, blue-black.
   Everything that moves lives under `prefers-reduced-motion: no-preference` and the `js` class
   (set in <head>), so without JS or with reduced motion the page is simply static. */
@font-face { font-family: Onest; font-weight: 400; font-display: swap; src: url(fonts/Onest-Regular.woff2) format("woff2"); }
@font-face { font-family: Onest; font-weight: 500; font-display: swap; src: url(fonts/Onest-Medium.woff2) format("woff2"); }
@font-face { font-family: Onest; font-weight: 600; font-display: swap; src: url(fonts/Onest-SemiBold.woff2) format("woff2"); }

:root {
  --bg: #070b14;
  --surface: #0e1522;
  --raised: #162133;
  --line: #1f2b3f;
  --line-strong: #3b4b66;
  --text: #f1f3f7;
  --muted: #9aa5b8;
  --faint: #66728a;
  --brand: #023d85;
  --silver: #e4e5e7;
  --accent: #1259c7;
  --accent-hover: #1a66dc;
  --highlight: #6ba6ff;
  --gutter: 24px;
  --top-h: 64px;
  --ease: cubic-bezier(0.33, 1, 0.68, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-io: cubic-bezier(0.76, 0, 0.24, 1);
  /* Delay of the first screen: time the opening doors need. */
  --d: 0s;
  --logo-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 -0.13 2.85 1.13'%3E%3Cpath d='M0 0L0.31 0L0.45 0.43L0.59 0L0.9 0L0.585 0.62L0.585 1L0.315 1L0.315 0.62ZM0.98 0L1.25 0L1.25 0.63L1.251 0.643L1.253 0.656L1.258 0.668L1.263 0.68L1.271 0.691L1.279 0.701L1.289 0.709L1.3 0.717L1.312 0.722L1.324 0.727L1.337 0.729L1.35 0.73L1.41 0.73L1.423 0.729L1.436 0.727L1.448 0.722L1.46 0.717L1.471 0.709L1.481 0.701L1.489 0.691L1.497 0.68L1.502 0.668L1.507 0.656L1.509 0.643L1.51 0.63L1.51 0L1.78 0L1.78 0.7L1.777 0.739L1.77 0.778L1.757 0.815L1.74 0.85L1.718 0.883L1.692 0.912L1.663 0.938L1.63 0.96L1.595 0.977L1.558 0.99L1.519 0.997L1.48 1L1.28 1L1.241 0.997L1.202 0.99L1.165 0.977L1.13 0.96L1.097 0.938L1.068 0.912L1.042 0.883L1.02 0.85L1.003 0.815L0.99 0.778L0.983 0.739L0.98 0.7ZM1.87 0.12L2.42 0.12L1.87 0.82ZM2.63 0.14L2.63 0.84L2.08 0.84ZM1.99 -0.04L2.74 -0.04L2.74 0.03L1.99 0.03ZM2.67 -0.04L2.74 -0.04L2.74 1L2.67 1ZM1.87 0.93L2.74 0.93L2.74 1L1.87 1ZM2.09 -0.13L2.85 -0.13L2.85 -0.071L2.09 -0.071ZM2.791 -0.13L2.85 -0.13L2.85 0.9L2.791 0.9Z'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--top-h); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.55 Onest, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-x: clip;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1, h2, h3 { font-weight: 600; letter-spacing: -0.02em; text-wrap: balance; }
h1 { font-size: clamp(2.35rem, 6.2vw, 4.5rem); line-height: 1.04; }
h1 em { font-style: normal; color: #a9c9ff; }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.75rem); line-height: 1.12; }
h3 { font-size: 1.25rem; line-height: 1.25; letter-spacing: -0.01em; }
p { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--highlight); outline-offset: 3px; }
.defs { position: absolute; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }
.eyebrow {
  color: var(--highlight);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* Fixed helpers: page progress, pointer light, opening doors */
.progress {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 30;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--highlight));
  transform: scaleX(0);
  transform-origin: 0 50%;
}
.glow, .intro { display: none; }

/* Header */
.top {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 20;
  border-bottom: 1px solid transparent;
  transition: background-color 0.26s var(--ease), border-color 0.26s var(--ease);
}
.top.is-scrolled {
  background: rgba(7, 11, 20, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}
.top__row { display: flex; align-items: center; gap: 32px; height: var(--top-h); }
.brand { display: flex; align-items: center; margin-right: auto; }
.brand__logo { width: 76px; height: 30px; fill: var(--silver); }
.nav { display: none; gap: 28px; font-size: 0.9375rem; color: var(--muted); }
.nav a { position: relative; padding: 8px 0; transition: color 0.2s; }
.nav a::after {
  content: "";
  position: absolute;
  inset: auto 0 2px 0;
  height: 1px;
  background: var(--silver);
  transform: scaleX(0);
  transform-origin: 100% 50%;
  transition: transform 0.4s var(--ease-out);
}
.nav a:hover, .nav a[aria-current="true"] { color: var(--text); }
.nav a:hover::after, .nav a[aria-current="true"]::after { transform: scaleX(1); transform-origin: 0 50%; }

.btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 2px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  transition: background 0.2s, transform 0.2s var(--ease);
}
.btn:hover { background: var(--accent-hover); }
.btn:active { transform: scale(0.97); }
.btn--small { min-height: 40px; padding: 0 18px; font-size: 0.9375rem; }

/* Hero */
.hero { position: relative; isolation: isolate; overflow: hidden; min-height: min(100svh, 920px); display: flex; align-items: flex-end; }
.hero__photo { position: absolute; inset: 0; z-index: -1; }
.hero__photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 11, 20, 0.6) 0%, rgba(7, 11, 20, 0.05) 18%, rgba(7, 11, 20, 0.25) 28%, rgba(7, 11, 20, 0.92) 46%, var(--bg) 60%);
}
.hero__zoom { position: absolute; inset: 0 0 40% 0; transform-origin: 60% 40%; }
.hero__draft, .hero__color, .hero__scan { position: absolute; inset: 0; }
.hero__zoom img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 50%; }
.hero__draft, .hero__scan, .hero__cue { display: none; }
.hero__grid { position: relative; padding-top: min(38svh, 340px); padding-bottom: 40px; }
.hero__text { max-width: 620px; }
.hero h1 { margin-top: 14px; }
.lead { margin-top: 20px; color: var(--muted); font-size: 1.0625rem; max-width: 34em; }
.hero__phone { display: none; position: relative; }
.note { margin-top: 16px; color: var(--faint); font-size: 0.875rem; }

/* Store buttons */
.stores { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 28px; }
.stores .store--main { grid-column: 1 / -1; }
.store {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 60px;
  padding: 8px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: rgba(14, 21, 34, 0.6);
  transition: background 0.2s, border-color 0.2s, transform 0.2s var(--ease);
}
.store svg { flex: none; width: 24px; height: 24px; }
.store span { display: grid; line-height: 1.2; }
.store small { color: var(--muted); font-size: 0.75rem; }
.store b { font-weight: 600; font-size: 0.9375rem; white-space: nowrap; }
.store:hover { border-color: var(--silver); }
.store:not([aria-disabled="true"]):active { transform: scale(0.98); }
.store--main { background: var(--accent); border-color: var(--accent); }
.store--main small { color: rgba(255, 255, 255, 0.78); }
.store--main:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.store[aria-disabled="true"] { cursor: default; color: var(--muted); border-color: var(--line); }
.store[aria-disabled="true"]:hover { border-color: var(--line); }
.store[aria-disabled="true"] small { color: var(--faint); }
/* A strip of light that crosses the main buttons, like a reflection on glass. */
.btn::after, .store--main::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 36%, rgba(255, 255, 255, 0.3) 50%, transparent 64%);
  transform: translateX(-120%);
  pointer-events: none;
}

/* Phone frame: a thin metal rim */
.phone {
  position: relative;
  width: 280px;
  padding: 8px;
  border: 1px solid transparent;
  border-radius: 34px;
  background:
    linear-gradient(#05080f, #05080f) padding-box,
    linear-gradient(155deg, rgba(228, 229, 231, 0.6), rgba(59, 75, 102, 0.55) 30%, rgba(31, 43, 63, 0.9) 68%, rgba(228, 229, 231, 0.32)) border-box;
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.9);
}
.phone img { width: 100%; aspect-ratio: 390 / 844; object-fit: cover; object-position: top; border-radius: 26px; }
.phone--small { width: 232px; border-radius: 30px; padding: 7px; }
.phone--small img { border-radius: 23px; }
.phone--cycle img + img { position: absolute; left: 8px; top: 8px; width: calc(100% - 16px); }
.phone--cycle img:not(.is-on) { opacity: 0; }
.phone__glare { display: none; }

/* Facts */
.facts { border-block: 1px solid var(--line); }
.facts__row { display: grid; grid-template-columns: 1fr 1fr; }
.facts__row > div { padding: 24px 16px 24px 0; }
.facts__row > div:nth-child(even) { padding-left: 20px; border-left: 1px solid var(--line); }
.facts__row > div:nth-child(n + 3) { border-top: 1px solid var(--line); }
.facts b { display: block; font-size: 1.75rem; font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; color: var(--silver); font-variant-numeric: tabular-nums; }
.facts b + span { display: block; margin-top: 8px; color: var(--muted); font-size: 0.875rem; line-height: 1.4; }

/* Sections */
.section { padding: 72px 0; }
.section--tint { background: var(--surface); border-block: 1px solid var(--line); }
.section--flush { padding-bottom: 0; }
.head { max-width: 680px; margin-bottom: 40px; }
.head h2 { margin-top: 12px; }
.head__sub { margin-top: 16px; color: var(--muted); }

/* Steps: static three columns by default; `story--on` (set by JS) turns them into a pinned scene */
.steps { display: grid; gap: 56px; }
.step { display: grid; justify-items: center; gap: 28px; text-align: center; }
.step__n { color: var(--highlight); font-size: 0.875rem; font-weight: 500; letter-spacing: 0.14em; }
.step h3 { margin-top: 8px; }
.step p { margin-top: 10px; color: var(--muted); max-width: 22em; font-size: 1rem; }
.story__bar { display: none; }

.story--on { padding-bottom: 0; }
.story--on .head { margin-bottom: 0; }
.story--on .story__track { height: calc(100svh - var(--top-h) + 190vh); }
.story--on .story__pin {
  position: sticky;
  top: var(--top-h);
  height: calc(100svh - var(--top-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}
.story--on .steps {
  --ph: clamp(320px, calc(100svh - var(--top-h) - 300px), 540px);
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 20px 0;
}
.story--on .step { display: contents; }
.story--on .step__phone {
  grid-area: 1 / 1;
  width: calc(var(--ph) * 0.475);
  opacity: 0;
  transform: perspective(1400px) translateX(64%) rotateY(-34deg) scale(0.8);
  transition: transform 0.9s var(--ease-out), opacity 0.6s var(--ease);
}
.story--on .step.is-past .step__phone { transform: perspective(1400px) translateX(-64%) rotateY(34deg) scale(0.8); }
.story--on .step.is-prev .step__phone, .story--on .step.is-next .step__phone { opacity: 0.26; }
.story--on .step.is-active .step__phone { opacity: 1; transform: none; z-index: 2; }
.story--on .step__text {
  grid-area: 2 / 1;
  max-width: 22em;
  opacity: 0;
  transform: translateY(14px);
  pointer-events: none;
  transition: opacity 0.45s var(--ease), transform 0.7s var(--ease-out);
}
.story--on .step.is-active .step__text { opacity: 1; transform: none; pointer-events: auto; }
.story--on .story__bar { display: flex; justify-content: center; gap: 6px; margin-top: 18px; }
.story__bar i { position: relative; overflow: hidden; width: 36px; height: 2px; background: var(--line-strong); }
.story__bar i::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--highlight);
  transform: scaleX(var(--p, 0));
  transform-origin: 0 50%;
}

/* Styles switcher */
.styles__view { position: relative; overflow: hidden; border-radius: 4px; background: var(--raised); aspect-ratio: 4 / 3; }
.styles__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; }
.styles__img.is-current { opacity: 1; z-index: 1; }
.styles__img.is-incoming { opacity: 1; z-index: 2; clip-path: inset(0 100% 0 0); }
.styles__img.is-incoming.is-wiping { clip-path: inset(0 0 0 0); }
.styles__wipe { position: absolute; inset: 0; z-index: 3; opacity: 0; transform: translateX(-100%); pointer-events: none; }
.styles__wipe::after {
  content: "";
  position: absolute;
  inset: 0 0 0 auto;
  width: 2px;
  background: linear-gradient(180deg, transparent, #cfe1ff 15%, #fff 50%, #cfe1ff 85%, transparent);
  box-shadow: 0 0 22px 3px rgba(107, 166, 255, 0.6);
}
.styles__label {
  position: absolute;
  z-index: 4;
  left: 14px;
  top: 14px;
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 7px 12px;
  border-radius: 2px;
  background: rgba(7, 11, 20, 0.62);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: 0.875rem;
  font-weight: 500;
}
.styles__label b { color: var(--highlight); font-weight: 500; font-size: 0.75rem; letter-spacing: 0.12em; }
.styles__view figcaption {
  position: absolute;
  z-index: 4;
  inset: auto 0 0 0;
  padding: 40px 16px 12px;
  background: linear-gradient(transparent, rgba(7, 11, 20, 0.8));
  color: rgba(241, 243, 247, 0.72);
  font-size: 0.75rem;
}
.styles__tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.styles__tabs button {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: transparent;
  color: var(--muted);
  font: 500 0.875rem/1.25 Onest, system-ui, sans-serif;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.styles__tabs img { flex: none; width: 56px; height: 42px; object-fit: cover; border-radius: 2px; }
.styles__tabs button:hover { color: var(--text); border-color: var(--line-strong); }
.styles__tabs button[aria-selected="true"] { color: var(--text); border-color: var(--highlight); background: rgba(107, 166, 255, 0.08); }
.styles__timer {
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: var(--highlight);
  transform: scaleX(0);
  transform-origin: 0 50%;
}

/* Product tiles */
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tile { position: relative; overflow: hidden; border-radius: 4px; background: var(--raised); aspect-ratio: 4 / 5; }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease-out); }
.tile:hover img { transform: scale(1.06); }
.tile span {
  position: absolute;
  z-index: 2;
  inset: auto 0 0 0;
  padding: 48px 14px 14px;
  background: linear-gradient(transparent, rgba(7, 11, 20, 0.88));
  font-weight: 500;
  font-size: 0.9375rem;
  line-height: 1.25;
}

/* Running line with the rest of the catalogue */
.marquee {
  overflow: hidden;
  display: grid;
  gap: 2px;
  margin-top: 56px;
  padding-bottom: 64px;
  -webkit-mask: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.marquee__row { display: flex; width: max-content; }
.marquee__row span {
  display: inline-flex;
  align-items: center;
  padding-right: 0.45em;
  font-weight: 600;
  font-size: clamp(2.25rem, 7vw, 5.25rem);
  line-height: 1.16;
  letter-spacing: -0.03em;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px var(--line-strong);
}
.marquee__row span::after {
  content: "";
  flex: none;
  width: 0.2em;
  height: 0.2em;
  margin-left: 0.45em;
  border: 1px solid var(--highlight);
  transform: rotate(45deg);
}
.marquee__row--b span { color: rgba(228, 229, 231, 0.09); -webkit-text-stroke: 0; }

/* Finished projects: an editorial grid, filled by site.js */
.works[hidden], .works__more[hidden], .nav a[hidden] { display: none; }
.works__grid { display: grid; gap: 10px; }
.work { position: relative; overflow: hidden; border-radius: 4px; background: var(--raised); aspect-ratio: 4 / 3; }
.work:first-child { aspect-ratio: 4 / 5; }
.work > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease-out); }
.work:hover > img, .work:focus-within > img { transform: scale(1.05); }
.work__tag, .work__count {
  position: absolute;
  z-index: 2;
  top: 12px;
  max-width: calc(100% - 104px);
  padding: 5px 10px;
  border-radius: 2px;
  background: rgba(7, 11, 20, 0.62);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.3;
}
.work__tag { left: 12px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.work__count { right: 12px; display: inline-flex; align-items: center; gap: 6px; color: var(--silver); font-variant-numeric: tabular-nums; }
.work__count svg { width: 15px; height: 15px; }
.work__cap {
  position: absolute;
  z-index: 2;
  inset: auto 0 0 0;
  display: grid;
  gap: 4px;
  padding: 72px 68px 16px 16px;
  background: linear-gradient(transparent, rgba(7, 11, 20, 0.92));
}
.work__cap b { font-weight: 600; font-size: 1.0625rem; line-height: 1.22; letter-spacing: -0.01em; text-wrap: balance; }
.work__cap small { color: rgba(241, 243, 247, 0.72); font-size: 0.875rem; }
.work__open { position: absolute; inset: 0; z-index: 3; width: 100%; padding: 0; border: 0; border-radius: 4px; background: none; color: inherit; cursor: pointer; }
.work__open:focus-visible { outline-offset: -3px; }
.work__open svg {
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 40px;
  height: 40px;
  padding: 10px;
  border: 1px solid rgba(228, 229, 231, 0.34);
  border-radius: 50%;
  background: rgba(7, 11, 20, 0.4);
  transition: background 0.3s, border-color 0.3s, transform 0.5s var(--ease-out);
}
.work:hover .work__open svg, .work__open:focus-visible svg { background: var(--accent); border-color: var(--accent); transform: translateX(3px); }
.works__more {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  margin-top: 12px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.works__more:hover { border-color: var(--silver); background: rgba(228, 229, 231, 0.04); }

/* Project viewer: photos on the left, the story on the right (below on a phone) */
html.is-locked { overflow: hidden; }
.viewer {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
}
.viewer:not([open]) { display: none; }
.viewer::backdrop { background: var(--bg); }
.viewer__body { height: 100%; overflow-y: auto; overscroll-behavior: contain; }
.viewer__main { display: grid; grid-template-rows: minmax(0, 1fr) auto; height: min(66svh, 560px); background: #04070d; }
.viewer__stage { position: relative; overflow: hidden; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.viewer__blur { position: absolute; inset: -48px; background: center / cover no-repeat; filter: blur(40px) saturate(1.15); opacity: 0.38; }
.viewer__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; -webkit-user-drag: none; }
.viewer__nav, .viewer__close {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(228, 229, 231, 0.3);
  border-radius: 50%;
  background: rgba(7, 11, 20, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}
.viewer__nav svg, .viewer__close svg { width: 20px; height: 20px; }
.viewer__nav:hover, .viewer__close:hover { background: var(--accent); border-color: var(--accent); }
.viewer__nav { top: 50%; margin-top: -22px; }
.viewer__nav--prev { left: 12px; }
.viewer__nav--prev svg { transform: scaleX(-1); }
.viewer__nav--next { right: 12px; }
.viewer__close { top: 12px; right: 12px; }
.viewer__counter {
  position: absolute;
  z-index: 3;
  left: 12px;
  bottom: 12px;
  padding: 4px 10px;
  border-radius: 2px;
  background: rgba(7, 11, 20, 0.62);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
  color: var(--silver);
}
.viewer__thumbs { display: flex; gap: 6px; padding: 8px 12px; overflow-x: auto; scrollbar-width: none; }
.viewer__thumbs::-webkit-scrollbar { display: none; }
.viewer__thumbs button {
  flex: none;
  width: 68px;
  aspect-ratio: 4 / 3;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 2px;
  overflow: hidden;
  background: var(--raised);
  opacity: 0.46;
  cursor: pointer;
  transition: opacity 0.25s, border-color 0.25s;
}
.viewer__thumbs button:hover { opacity: 0.8; }
.viewer__thumbs button[aria-current="true"] { opacity: 1; border-color: var(--highlight); }
.viewer__thumbs img { width: 100%; height: 100%; object-fit: cover; }
.viewer--single .viewer__nav, .viewer--single .viewer__counter, .viewer--single .viewer__thumbs { display: none; }
.viewer__info { padding: 28px var(--gutter) 48px; }
.viewer__info h3 { margin-top: 10px; font-size: clamp(1.5rem, 3vw, 2rem); line-height: 1.14; letter-spacing: -0.02em; }
.viewer__meta { margin-top: 10px; color: var(--muted); }
.viewer__text { margin-top: 20px; max-width: 38em; color: rgba(241, 243, 247, 0.86); white-space: pre-line; }
.viewer__type:empty, .viewer__meta:empty, .viewer__text:empty { display: none; }
.viewer__cta { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--line); }
.viewer__cta .btn { width: 100%; }
.viewer__cta p { margin-top: 14px; color: var(--faint); font-size: 0.875rem; line-height: 1.45; }

/* Feature + live 3D model */
.feature { display: grid; gap: 48px; }
.feature__text h2 { margin-top: 12px; }
.feature__text > p:not(.eyebrow) { margin-top: 18px; color: var(--muted); }
.checks { margin-top: 24px; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 28px; }
.checks li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.42em;
  width: 12px;
  height: 7px;
  border: solid var(--highlight);
  border-width: 0 0 1.5px 1.5px;
  transform: rotate(-45deg);
}
.link { display: inline-flex; align-items: center; gap: 10px; margin-top: 28px; color: var(--highlight); font-weight: 500; }
.link svg { width: 20px; height: 20px; transition: transform 0.3s var(--ease-out); }
.link:hover svg { transform: translateX(5px); }

.model {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: radial-gradient(120% 80% at 50% 0%, #111c30 0%, var(--bg) 72%);
}
.model__canvas { display: block; width: 100%; aspect-ratio: 1 / 0.9; cursor: grab; touch-action: pan-y; }
.model__canvas.is-dragging { cursor: grabbing; }
.model__hint {
  position: absolute;
  left: 16px;
  top: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--highlight);
  font-size: 0.8125rem;
  pointer-events: none;
}
.model__hint svg { width: 18px; height: 18px; }
.model__controls { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding: 14px 18px 4px; border-top: 1px solid var(--line); }
.model__controls label { display: grid; gap: 4px; }
.model__row { display: flex; align-items: baseline; justify-content: space-between; color: var(--muted); font-size: 0.8125rem; }
.model__row output { color: var(--text); font-weight: 600; font-size: 1.125rem; font-variant-numeric: tabular-nums; }
.model__note { padding: 4px 18px 16px; color: var(--faint); font-size: 0.8125rem; }
.model__note a { color: var(--highlight); }
.model input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 28px;
  margin: 0;
  background: transparent;
  cursor: pointer;
}
.model input[type="range"]::-webkit-slider-runnable-track {
  height: 2px;
  background: linear-gradient(90deg, var(--highlight) var(--fill, 50%), var(--line-strong) var(--fill, 50%));
}
.model input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  margin-top: -8px;
  border: 0;
  border-radius: 2px;
  background: var(--silver);
  box-shadow: 0 0 0 5px rgba(107, 166, 255, 0.16);
  transition: box-shadow 0.2s, transform 0.2s;
}
.model input[type="range"]:active::-webkit-slider-thumb { box-shadow: 0 0 0 9px rgba(107, 166, 255, 0.2); transform: scale(1.08); }
.model input[type="range"]::-moz-range-track { height: 2px; background: var(--line-strong); }
.model input[type="range"]::-moz-range-progress { height: 2px; background: var(--highlight); }
.model input[type="range"]::-moz-range-thumb { width: 18px; height: 18px; border: 0; border-radius: 2px; background: var(--silver); box-shadow: 0 0 0 5px rgba(107, 166, 255, 0.16); }

/* Download */
.download__box {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  justify-items: center;
  text-align: center;
  padding: 56px var(--gutter);
  border-radius: 4px;
  background: linear-gradient(160deg, #034a9f 0%, var(--brand) 45%, #012c63 100%);
}
.download__box::before, .download__box::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 70%;
  aspect-ratio: 1;
  border-radius: 50%;
  pointer-events: none;
}
.download__box::before { left: -22%; top: -55%; background: radial-gradient(circle, rgba(107, 166, 255, 0.42), transparent 64%); }
.download__box::after { right: -26%; bottom: -70%; background: radial-gradient(circle, rgba(1, 20, 48, 0.75), transparent 64%); }
.download__logo { position: relative; display: block; width: 132px; }
.download__logo svg { display: block; width: 100%; height: auto; fill: var(--silver); }
.shine { display: none; }
.download h2 { margin-top: 28px; }
.download__box > p { margin-top: 14px; color: rgba(241, 243, 247, 0.78); max-width: 32em; }
.stores--center { width: 100%; max-width: 760px; }
.download .store { background: rgba(1, 26, 60, 0.45); border-color: rgba(228, 229, 231, 0.34); text-align: left; }
.download .store--main { background: var(--silver); border-color: var(--silver); color: #04162f; }
.download .store--main small { color: rgba(4, 22, 47, 0.7); }
.download .store--main:hover { background: #fff; border-color: #fff; }
.download .store[aria-disabled="true"] { color: rgba(241, 243, 247, 0.72); border-color: rgba(228, 229, 231, 0.2); }
.download .store[aria-disabled="true"] small { color: rgba(241, 243, 247, 0.5); }
.howto { margin-top: 28px; max-width: 34em; color: rgba(241, 243, 247, 0.82); font-size: 0.9375rem; }
.howto summary { cursor: pointer; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: rgba(241, 243, 247, 0.4); }
.howto ol { margin-top: 14px; padding-left: 20px; list-style: decimal; text-align: left; display: grid; gap: 8px; }

/* Footer */
.foot { overflow: hidden; border-top: 1px solid var(--line); padding: 56px 0 0; }
.foot__grid { display: grid; gap: 40px; }
.foot__logo { width: 92px; height: 36px; fill: var(--silver); }
.foot__tag { margin-top: 10px; color: var(--muted); font-size: 0.6875rem; letter-spacing: 0.2em; text-transform: uppercase; }
.foot__about { margin-top: 18px; color: var(--muted); font-size: 0.9375rem; max-width: 24em; }
.foot h3 { font-size: 0.8125rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); }
.foot__social { display: inline-flex; align-items: center; gap: 10px; margin-top: 16px; font-weight: 500; transition: color 0.2s; }
.foot__social svg { width: 24px; height: 24px; }
.foot__social:hover { color: var(--highlight); }
.foot__hint { margin-top: 12px; color: var(--muted); font-size: 0.875rem; max-width: 26em; }
.foot__links { margin-top: 16px; display: grid; gap: 10px; font-size: 0.9375rem; color: var(--muted); }
.foot__links a { transition: color 0.2s; }
.foot__links a:hover { color: var(--text); }
.foot__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: space-between;
  margin-top: 48px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 0.8125rem;
}
/* The mark, as wide as the page, closes it. */
.foot__giant { margin: 40px auto -4.5%; padding: 0 var(--gutter); max-width: 1500px; }
.foot__giant svg {
  display: block;
  width: 100%;
  height: auto;
  fill: rgba(228, 229, 231, 0.03);
  stroke: rgba(228, 229, 231, 0.26);
  stroke-width: 0.008;
}

@media (min-width: 600px) {
  :root { --gutter: 32px; }
  .stores { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stores .store--main { grid-column: auto; }
  .store { padding: 8px 20px; }
  .store b { font-size: 1.0625rem; }
  .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .styles__tabs { grid-template-columns: repeat(4, 1fr); }
  .styles__tabs button { flex-direction: column; align-items: stretch; gap: 8px; padding: 6px 6px 10px; }
  .styles__tabs img { width: 100%; height: auto; aspect-ratio: 4 / 3; }
  .styles__tabs span { padding: 0 4px; }
  .tiles { grid-template-columns: repeat(4, 1fr); gap: 12px; }
  .works__grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .work:first-child { aspect-ratio: 4 / 3; }
  .work__cap { padding: 80px 72px 20px 20px; }
  .viewer__cta .btn { width: auto; }
  .facts__row { grid-template-columns: repeat(4, 1fr); }
  .facts__row > div { padding: 28px 20px; border-top: 0 !important; border-left: 1px solid var(--line); }
  .facts__row > div:first-child { padding-left: 0; border-left: 0; }
  .foot__grid { grid-template-columns: 1.3fr 1fr 1fr; }
  .download__box { padding: 72px 40px; }
  .foot__giant svg { stroke-width: 0.004; }
}

/* Two columns: a card left alone in the last row takes the whole row. */
@media (min-width: 600px) and (max-width: 959px) {
  .work.is-odd { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
}

@media (min-width: 960px) {
  :root { --top-h: 72px; }
  body { font-size: 18px; }
  .nav { display: flex; }
  .section { padding: 112px 0; }
  .section--flush { padding-bottom: 0; }
  .head { margin-bottom: 56px; }
  .hero { align-items: center; min-height: min(100svh, 860px); }
  .hero__zoom { inset: 0; }
  .hero__zoom img { object-position: right center; }
  .hero__photo::after {
    background:
      linear-gradient(90deg, var(--bg) 0%, rgba(7, 11, 20, 0.92) 30%, rgba(7, 11, 20, 0.35) 62%, rgba(7, 11, 20, 0.55) 100%),
      linear-gradient(180deg, rgba(7, 11, 20, 0.5) 0%, transparent 22%, transparent 74%, var(--bg) 100%);
  }
  .hero__grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 64px; padding-top: 120px; padding-bottom: 72px; }
  .hero__phone { display: block; padding-right: 40px; }
  .hero__phone::before {
    content: "";
    position: absolute;
    z-index: -1;
    inset: -14% -22%;
    background: radial-gradient(closest-side, rgba(18, 89, 199, 0.42), transparent);
  }
  .tilt { transform: perspective(1100px) rotateY(calc(var(--rx, -10) * 1deg)) rotateX(calc(var(--ry, 3) * 1deg)); }
  .lead { font-size: 1.1875rem; }
  .stores { max-width: 620px; }
  .step { justify-items: start; text-align: left; }
  .styles { display: grid; grid-template-columns: minmax(0, 1fr) 248px; gap: 16px; align-items: start; }
  .styles__tabs { grid-template-columns: 1fr; margin-top: 0; gap: 10px; }
  .styles__tabs button { flex-direction: row; align-items: center; gap: 14px; padding: 8px; font-size: 0.9375rem; }
  .styles__tabs img { width: 84px; height: 63px; aspect-ratio: auto; }
  .styles__tabs span { padding: 0; }
  .styles__label { left: 20px; top: 20px; font-size: 1rem; }
  .feature { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); align-items: center; gap: 72px; }
  .tile span { font-size: 1.0625rem; padding: 64px 18px 18px; }

  /* The first project is large, two more stand beside it, the rest go three in a row. */
  .works__grid { grid-template-columns: repeat(6, 1fr); }
  .work { grid-column: span 2; }
  .work:first-child { grid-column: span 4; grid-row: span 2; aspect-ratio: auto; }
  .work.is-half { grid-column: span 3; aspect-ratio: 16 / 9; }
  .work.is-wide { grid-column: 1 / -1; aspect-ratio: 21 / 8; }
  .works__grid[data-count="1"] .work { grid-column: 1 / -1; grid-row: auto; aspect-ratio: 21 / 9; }
  .works__grid[data-count="2"] .work { grid-column: span 3; grid-row: auto; aspect-ratio: 4 / 3; }
  .work__cap b { font-size: 1.125rem; }
  .work:first-child .work__cap b, .work.is-wide .work__cap b { font-size: 1.5rem; }
  .works__more { width: auto; margin: 28px auto 0; padding: 0 36px; }

  .viewer__body { display: grid; grid-template-columns: minmax(0, 1fr) 420px; overflow: hidden; }
  .viewer__main { height: 100%; min-height: 0; }
  .viewer__info { display: flex; flex-direction: column; overflow-y: auto; padding: 96px 40px 40px; border-left: 1px solid var(--line); }
  .viewer__cta { margin-top: auto; }
  .viewer__text { margin-bottom: 32px; }
  .viewer__thumbs { padding: 10px 16px 14px; gap: 8px; }
  .viewer__thumbs button { width: 92px; }
  .viewer__nav { width: 52px; height: 52px; margin-top: -26px; }
  .viewer__nav--prev { left: 20px; }
  .viewer__nav--next { right: 20px; }
  .viewer__close { top: 20px; right: 20px; }
  .viewer__counter { left: 20px; bottom: 16px; }
  .marquee { margin-top: 88px; padding-bottom: 104px; }

  /* Pinned scene: three captions on the left, phones turning on the right */
  .story--on .head { margin-bottom: 0; }
  .story--on .steps {
    --ph: clamp(420px, calc(100svh - var(--top-h) - 110px), 640px);
    grid-template-columns: minmax(0, 470px) minmax(0, 1fr);
    align-content: center;
    gap: 0 48px;
  }
  .story--on .step__phone { grid-area: 1 / 2 / 4 / 3; align-self: center; }
  .story--on .step:nth-child(1) .step__text { grid-area: 1 / 1; }
  .story--on .step:nth-child(2) .step__text { grid-area: 2 / 1; }
  .story--on .step:nth-child(3) .step__text { grid-area: 3 / 1; }
  .story--on .step__text {
    position: relative;
    justify-self: stretch;
    max-width: none;
    padding: 24px 0 24px 32px;
    text-align: left;
    opacity: 0.36;
    transform: none;
    pointer-events: auto;
    cursor: pointer;
    transition: opacity 0.5s var(--ease);
  }
  .story--on .step__text:hover { opacity: 0.6; }
  .story--on .step.is-active .step__text { opacity: 1; cursor: default; }
  .story--on .step__text::before, .story--on .step__text::after { content: ""; position: absolute; inset: 0 auto 0 0; width: 2px; background: var(--line); }
  .story--on .step__text::after { background: var(--highlight); transform: scaleY(var(--p, 0)); transform-origin: 50% 0; }
  .story--on .step h3 { font-size: 1.625rem; }
  .story--on .step p { max-width: 24em; }
  .story--on .story__bar { display: none; }
}

@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  /* Only after JS has split the headline into words. */
  .split em .w > span {
    background: linear-gradient(100deg, #e4e5e7 0%, #8fbcff 40%, #ffffff 55%, #6ba6ff 100%) 0 0 / 220% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}

/* ───────────────────────── Motion ───────────────────────── */
@media (prefers-reduced-motion: no-preference) {
  .js { --d: 0.1s; }
  .js:not(.no-intro) { --d: 0.75s; }

  /* Opening doors */
  .js:not(.no-intro):not(.is-done) .intro { display: block; position: fixed; inset: 0; z-index: 100; }
  .intro__door {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 50.2%;
    background: var(--bg);
    transition: transform 1s var(--ease-io) 0.12s;
  }
  .intro__door--l { left: 0; border-right: 1px solid rgba(228, 229, 231, 0.2); }
  .intro__door--r { right: 0; border-left: 1px solid rgba(228, 229, 231, 0.2); }
  .is-ready .intro__door--l { transform: translateX(-101%); }
  .is-ready .intro__door--r { transform: translateX(101%); }
  .intro__brand {
    position: absolute;
    inset: 0;
    display: grid;
    place-content: center;
    justify-items: center;
    gap: 18px;
    transition: opacity 0.3s, transform 0.5s var(--ease);
  }
  .is-ready .intro__brand { opacity: 0; transform: scale(1.05); }
  .intro__logo {
    width: min(46vw, 220px);
    fill: var(--silver);
    fill-opacity: 0;
    stroke: var(--silver);
    stroke-width: 0.012;
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: draw 1.05s var(--ease-io) 0.1s forwards, fill-in 0.5s ease 0.75s forwards;
  }
  .intro__tag {
    color: var(--muted);
    font-size: 0.6875rem;
    letter-spacing: 0.9em;
    margin-right: -0.9em;
    text-transform: uppercase;
    opacity: 0;
    animation: tag-in 1s var(--ease-out) 0.45s forwards;
  }

  .js .top { opacity: 0; transform: translateY(-14px); }
  .js.is-ready .top {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s var(--ease-out) calc(var(--d) + 0.25s), transform 0.8s var(--ease-out) calc(var(--d) + 0.25s), background-color 0.26s var(--ease), border-color 0.26s var(--ease);
  }

  /* Pointer light (desktop) */
  @media (hover: hover) and (pointer: fine) {
    .js .glow {
      display: block;
      position: fixed;
      z-index: 15;
      left: -320px;
      top: -320px;
      width: 640px;
      height: 640px;
      border-radius: 50%;
      background: radial-gradient(circle, rgba(107, 166, 255, 0.085), transparent 62%);
      pointer-events: none;
      opacity: 0;
      transition: opacity 0.8s;
    }
    .js .glow.is-on { opacity: 1; }
    .btn:hover::after, .store--main:hover::after { transform: translateX(120%); transition: transform 0.9s var(--ease-out); }
  }

  /* Hero: the house starts as a grey draft; a line of light crosses it and it becomes real */
  .js .hero__draft { display: block; filter: grayscale(1) brightness(0.8) contrast(1.1); }
  .js .hero__draft::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(107, 166, 255, 0.28) 1px, transparent 1px), linear-gradient(90deg, rgba(107, 166, 255, 0.28) 1px, transparent 1px);
    background-size: 56px 56px;
  }
  .js.hero-live .hero__draft { display: none; }
  .js .hero__color { clip-path: inset(0 100% 0 0); }
  .js.is-ready .hero__color { animation: wipe 1.7s var(--ease-io) calc(var(--d) + 0.3s) both; }
  .js.hero-live .hero__color { animation: none; clip-path: none; }
  .js .hero__scan { display: block; opacity: 0; transform: translateX(-100%); }
  .js .hero__scan::before {
    content: "";
    position: absolute;
    inset: 0 0 0 auto;
    width: 200px;
    background: linear-gradient(270deg, rgba(107, 166, 255, 0.3), transparent);
  }
  .js .hero__scan::after {
    content: "";
    position: absolute;
    inset: 0 0 0 auto;
    width: 2px;
    background: linear-gradient(180deg, transparent, #cfe1ff 15%, #fff 50%, #cfe1ff 85%, transparent);
    box-shadow: 0 0 24px 4px rgba(107, 166, 255, 0.65);
  }
  .js.is-ready .hero__scan { animation: scan 1.7s var(--ease-io) calc(var(--d) + 0.3s) both; }
  .js.hero-live .hero__scan { display: none; }
  .js .hero__zoom { transform: scale(1.12); }
  .js.is-ready .hero__zoom { animation: zoom-out 3.6s var(--ease-out) var(--d) both; }

  .float { animation: float 7s ease-in-out infinite; }
  .phone--cycle img { transition: opacity 0.9s var(--ease), transform 1.1s var(--ease-out); }
  .phone--cycle img:not(.is-on) { transform: translateY(16px) scale(0.985); }
  .phone__glare {
    display: block;
    position: absolute;
    inset: 8px;
    border-radius: 26px;
    background: linear-gradient(112deg, transparent 32%, rgba(255, 255, 255, 0.13) 47%, transparent 62%) calc(50% + var(--rx, -10) * 5%) 0 / 260% 100% no-repeat;
    pointer-events: none;
  }
  .split em .w > span { animation: shimmer 5s ease-in-out infinite alternate; }
  .store--main::after { animation: sweep 6s var(--ease-out) 4s infinite; }

  .js .hero__cue { display: none; }
  @media (min-width: 960px) and (min-height: 700px) {
    .js .hero__cue {
      display: block;
      position: absolute;
      left: 50%;
      bottom: 26px;
      width: 1px;
      height: 54px;
      overflow: hidden;
      background: rgba(228, 229, 231, 0.18);
    }
    .js .hero__cue::after {
      content: "";
      position: absolute;
      inset: 0 0 60% 0;
      background: var(--silver);
      animation: cue 2.4s var(--ease-io) infinite;
    }
  }

  /* Reveal on scroll */
  .js .reveal {
    opacity: 0;
    transform: translate3d(0, 28px, 0);
    transition: opacity 0.9s var(--ease-out) var(--in, 0s), transform 1.1s var(--ease-out) var(--in, 0s);
  }
  .js .reveal--left { transform: translate3d(-44px, 0, 0); }
  .js .reveal--scale { transform: scale(0.93); }
  .js .reveal--phone {
    transform: perspective(1200px) translate3d(0, 90px, 0) rotateY(-30deg) rotateX(10deg) scale(0.9);
    transition-duration: 1s, 1.6s;
  }
  .js .reveal.is-visible { opacity: 1; transform: none; }
  /* The picture rises from behind its lower edge. The clip is on the image, not on the observed
     element: IntersectionObserver treats a fully clipped target as not visible. */
  .js .reveal--clip { opacity: 1; transform: none; background: transparent; transition: background 0.4s var(--in, 0s); }
  .js .reveal--clip > img {
    clip-path: inset(100% 0 0 0);
    transform: scale(1.3);
    transition: clip-path 1.2s var(--ease-out) var(--in, 0s), transform 1.8s var(--ease-out) var(--in, 0s);
  }
  .js .reveal--clip > span { opacity: 0; transition: opacity 0.8s var(--ease) calc(var(--in, 0s) + 0.5s); }
  .js .reveal--clip.is-visible { background: var(--raised); }
  .js .reveal--clip.is-visible > img { clip-path: inset(0 0 0 0); transform: none; }
  .js .reveal--clip.is-visible > span { opacity: 1; }

  /* Headlines rise word by word from behind a mask */
  .split .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0.12em 0 0.2em; margin: -0.12em 0 -0.2em; }
  .split .w > span {
    display: inline-block;
    transform: translateY(125%) rotate(4deg);
    transform-origin: 0 100%;
    transition: transform 1.05s var(--ease-out) calc(var(--in, 0s) + var(--wi, 0) * 60ms);
  }
  .split.is-visible .w > span { transform: none; }

  /* Styles: the next look wipes in behind a line of light, then drifts slowly */
  .styles__img.is-incoming.is-wiping { transition: clip-path 1.1s var(--ease-io); }
  .styles__view.is-wiping .styles__wipe { opacity: 1; transform: translateX(0); transition: transform 1.1s var(--ease-io); }
  .styles__img.is-live { animation: drift-in 9s linear both; }
  .styles__label.is-change span { animation: label-in 0.7s var(--ease-out) both; }
  .styles.is-playing [aria-selected="true"] .styles__timer { animation: timer 5.5s linear forwards; }
  .styles.is-hover .styles__timer { animation-play-state: paused; }

  /* Project viewer: the screen fades in, the story rises line by line, photos slide from their side */
  .viewer[open] { animation: viewer-in 0.4s var(--ease) both; }
  .viewer[open] .viewer__info > * { animation: rise 0.8s var(--ease-out) both; animation-delay: 0.18s; }
  .viewer[open] .viewer__info > :nth-child(2) { animation-delay: 0.24s; }
  .viewer[open] .viewer__info > :nth-child(3) { animation-delay: 0.3s; }
  .viewer[open] .viewer__info > :nth-child(4) { animation-delay: 0.36s; }
  .viewer[open] .viewer__info > :nth-child(5) { animation-delay: 0.44s; }
  .viewer__img.is-in { animation: photo-in 0.6s var(--ease-out) both; }

  .marquee__row { animation: marquee 46s linear infinite; }
  .marquee__row--b { animation-direction: reverse; animation-duration: 54s; }

  .download__box::before { animation: aurora 15s ease-in-out infinite alternate; }
  .download__box::after { animation: aurora-b 19s ease-in-out infinite alternate; }
  .foot__giant svg { stroke-dasharray: 1; stroke-dashoffset: 1; fill-opacity: 0; }
  .foot__giant.is-visible svg { animation: draw 2.6s var(--ease-io) 0.1s forwards, fill-in 1.2s ease 1.8s forwards; }

  @media (hover: hover) and (pointer: fine) {
    .tile { transform: perspective(900px) rotateX(calc(var(--ty, 0) * -7deg)) rotateY(calc(var(--tx, 0) * 7deg)); transition: transform 0.5s var(--ease-out); }
    .tile.is-tilting { transition: transform 0.1s linear; }
    .tile::after {
      content: "";
      position: absolute;
      z-index: 1;
      inset: 0;
      background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.16), transparent 62%);
      opacity: 0;
      transition: opacity 0.35s;
      pointer-events: none;
    }
    .tile:hover::after { opacity: 1; }
  }

  @supports ((-webkit-mask-image: url("")) or (mask-image: url(""))) {
    /* Reflection that runs over the silver letters only. */
    .shine {
      display: block;
      position: absolute;
      inset: 0;
      pointer-events: none;
      background: linear-gradient(105deg, transparent 42%, #fff 50%, transparent 58%) 100% 0 / 300% 100% no-repeat;
      -webkit-mask: var(--logo-mask) center / contain no-repeat;
      mask: var(--logo-mask) center / contain no-repeat;
      animation: shine 5.5s var(--ease-io) 1s infinite;
    }
  }
}

@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes viewer-in { from { opacity: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes photo-in { from { opacity: 0; transform: translateX(calc(var(--dir, 0) * 36px)) scale(0.985); } }
@keyframes fill-in { to { fill-opacity: 1; } }
@keyframes tag-in { to { opacity: 1; letter-spacing: 0.34em; margin-right: -0.34em; } }
@keyframes wipe { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes scan {
  0% { opacity: 1; transform: translateX(-100%); }
  90% { opacity: 1; }
  100% { opacity: 0; transform: translateX(0); }
}
@keyframes zoom-out { from { transform: scale(1.12); } to { transform: scale(1); } }
@keyframes float { 0%, 100% { transform: translate3d(0, 0, 0); } 50% { transform: translate3d(0, -12px, 0); } }
@keyframes shimmer { to { background-position: 100% 0; } }
@keyframes sweep { 0%, 80% { transform: translateX(-120%); } 100% { transform: translateX(120%); } }
@keyframes cue { 0% { transform: translateY(-110%); } 100% { transform: translateY(260%); } }
@keyframes drift-in { from { transform: scale(1.001); } to { transform: scale(1.07); } }
@keyframes label-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes timer { to { transform: scaleX(1); } }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes aurora { to { transform: translate3d(34%, 26%, 0) scale(1.25); } }
@keyframes aurora-b { to { transform: translate3d(-30%, -22%, 0) scale(1.2); } }
@keyframes shine { 0%, 45% { background-position: 100% 0; } 100% { background-position: 0% 0; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
