/* Shakthi Hari — portfolio. Black, white, Geist. */
@font-face { font-family: "Geist"; font-style: normal; font-weight: 100 900; font-display: swap; src: url(/assets/fonts/geist-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: "Geist"; font-style: normal; font-weight: 100 900; font-display: swap; src: url(/assets/fonts/geist-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; }
:root {
  --bg: #000;
  --fg: #fff;
  --mute: rgba(255, 255, 255, .6);
  --line: rgba(255, 255, 255, .14);
  --chip: rgba(255, 255, 255, .1);
  --card: rgba(255, 255, 255, .06);
  --g: 20px;
  --gap: 5px;
  --ease: cubic-bezier(.44, 0, .56, 1);
  --out: cubic-bezier(.22, 1, .36, 1);
  --spring: cubic-bezier(.34, 1.36, .64, 1);
  --font: "Geist", -apple-system, "SF Pro Display", "Helvetica Neue", Arial, sans-serif;
}
@media (max-width: 809.98px) { :root { --g: 15px; } }

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); color: var(--fg); -webkit-text-size-adjust: 100%; scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }
html.smooth, html.smooth body { height: auto; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font: 500 14px/1.16 var(--font); font-optical-sizing: auto; letter-spacing: 0;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility;
}
img, video, iframe { display: block; max-width: 100%; }
img { height: auto; }
img, video, canvas { -webkit-user-drag: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
ul, ol, dl, dd, figure, blockquote, h1, h2, h3, p { margin: 0; padding: 0; list-style: none; }
h1, h2, h3 { font-weight: 400; }
::selection { background: #fff; color: #000; }
:focus-visible { outline: 1px solid var(--fg); outline-offset: 3px; }

.mute { color: var(--mute); }
.label { font-size: 14px; font-weight: 500; letter-spacing: .01em; line-height: 1.1; text-transform: uppercase; }
.h2u { font-size: 32px; letter-spacing: -.01em; line-height: 1; text-transform: uppercase; }
.h3u { font-size: 32px; letter-spacing: -.01em; line-height: 1; text-transform: uppercase; }
.lead { font-size: 24px; font-weight: 400; letter-spacing: -.01em; line-height: 1.2; max-width: 700px; }
.lead p + p { margin-top: 1.1em; }
/* About copy: Geist Semi Bold 20/22, -0.4px (black in light mode, white in dark) */
.about .lead { font-size: 20px; font-weight: 600; line-height: 22px; letter-spacing: -.4px; color: var(--fg); }
.small-w { max-width: 260px; }
.center { text-align: center; }

/* ---------- letter roll ---------- */
.roll { display: inline-block; overflow: hidden; vertical-align: top; line-height: 1.16; }
.roll-in { display: inline; }
.w { display: inline-flex; white-space: nowrap; overflow: hidden; vertical-align: top; }
.ch { display: inline-flex; flex-direction: column; height: 1.16em; }
.ch > span { display: block; transition: transform .5s var(--out); transition-delay: calc(var(--i) * 18ms); }
a:hover .ch > span, button:hover .ch > span, a:focus-visible .ch > span, .card:hover .ch > span { transform: translateY(-100%); }
.btn { display: inline-flex; align-items: center; }
.btn[aria-current="page"] { position: relative; }
.btn[aria-current="page"]::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; margin-right: 6px; }
.btn.ul { position: relative; padding-bottom: 2px; text-transform: uppercase; letter-spacing: .01em; }
.btn.ul::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor; transform-origin: right; transition: transform .6s var(--out); }
.btn.ul:hover::after { transform: scaleX(0); }
.pill { display: inline-flex; align-items: center; height: 40px; padding: 0 18px; border-radius: 999px; background: var(--fg); color: var(--bg); font-size: 14px; transition: transform .5s var(--out); }
.pill:hover { transform: scale(1.04); }
.pill.ghost { background: var(--chip); color: var(--fg); }

.dot { display: inline-block; border-radius: 50%; background: var(--fg); flex: none; }
.dot-s { width: 8px; height: 8px; }
.dot-m { width: 14px; height: 14px; }
.dot-l { width: .16em; height: .16em; }

/* ---------- nav: global menubar ----------
   Fixed groups, 10px inset: name left, frosted-glass pills centre, Contact pill right.
   Groups clip their children so they rise into place on the first load of a visit. */
:root {
  --glass: rgba(255, 255, 255, .8); --glass-hi: rgba(255, 255, 255, .92); --glass-on: rgba(255, 255, 255, .96);
  --glass-edge: rgba(255, 255, 255, .5); --glass-fg: #000;
  --soft: cubic-bezier(.25, 1, .5, 1); --give: cubic-bezier(.3, 1.22, .45, 1);
}
.nav { position: fixed; inset: 0 0 auto 0; z-index: 50; height: 0; font: 500 13px/1 var(--font); letter-spacing: -.01em; text-transform: uppercase; }
.nv-logo, .nv-clip, .nv-menu { display: flex; align-items: center; gap: 6px; padding: 10px; overflow: clip; }
.nv-logo, .nv-mid, .nv-right, .nv-menu { position: fixed; top: 0; }
.nv-logo { left: 0; height: 52px; color: var(--fg); view-transition-name: nv-logo; }   /* 10px in from the edge, like Contact on the right */
/* centred on the viewport without a transform, so no sub-pixel drift */
.nv-mid { left: 0; right: 0; width: max-content; margin-inline: auto; view-transition-name: nv-mid; }
.nv-right { right: 0; view-transition-name: nv-right; }
::view-transition-group(nv-logo), ::view-transition-group(nv-mid), ::view-transition-group(nv-right) { animation-duration: 0s; z-index: 60; }
::view-transition-old(nv-logo), ::view-transition-old(nv-mid), ::view-transition-old(nv-right) { animation: none; opacity: 0; }
::view-transition-new(nv-logo), ::view-transition-new(nv-mid), ::view-transition-new(nv-right) { animation: none; }

/* frosted matte glass: 80% white, 4px corners, black type; hover firms the tint and rolls the letters */
.nv-chip {
  position: relative; display: flex; align-items: center; justify-content: center; height: 32px; padding: 0 12px;
  border-radius: 4px; color: var(--glass-fg); white-space: nowrap; background: var(--glass);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
  box-shadow: inset 0 0 0 1px var(--glass-edge);
  transition: background-color .6s var(--soft), box-shadow .6s var(--soft), transform .6s var(--give);
}
.nv-chip:hover, .nv-chip:focus-visible { background-color: var(--glass-hi); }
.nv-chip:active { transform: scale(.96); transition-duration: .2s; }
.nv-chip .ch > span { transition-duration: .65s; transition-timing-function: var(--soft); }

/* contact: hovering the pill (or the gap below it) drops a glass box with the email + copy icon.
   The box unfolds from the pill's corner: clip opens downward while it settles from a slight lift and blur. */
.nv-drop {
  position: absolute; top: 48px; right: 10px; display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 10px 0 12px;
  border-radius: 4px; background: var(--glass); color: var(--glass-fg); white-space: nowrap;
  font: 500 13px/1 var(--font); letter-spacing: 0; text-transform: none;
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
  box-shadow: inset 0 0 0 1px var(--glass-edge);
  transform-origin: 100% 0; opacity: 0; visibility: hidden; pointer-events: none;
  transform: translateY(-8px) scale(.94); filter: blur(6px); clip-path: inset(0 0 100% 0 round 4px);
  transition: opacity .25s var(--soft), transform .35s var(--soft), filter .25s var(--soft), clip-path .3s var(--soft), visibility 0s .35s, background-color .5s var(--soft);
}
.nv-mid.open .nv-drop {
  opacity: 1; visibility: visible; pointer-events: auto; transform: none; filter: blur(0); clip-path: inset(0 0 0 0 round 4px);
  transition: opacity .35s var(--soft), transform .7s var(--give), filter .45s var(--soft), clip-path .6s var(--soft), visibility 0s, background-color .5s var(--soft);
}
/* hover bridge between pill and box */
.nv-mid.open .nv-drop::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.nv-drop:hover, .nv-drop:focus-visible { background-color: var(--glass-hi); }
.nv-drop > * { transition: opacity .3s var(--soft), transform .55s var(--soft); }
.nv-mid:not(.open) .nv-drop > * { opacity: 0; transform: translateY(-6px); }
.nv-mid.open .nv-drop .nd-mail { transition-delay: .08s; }
.nv-mid.open .nv-drop .nd-icon { transition-delay: .14s; }
.nd-icon { position: relative; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 3px; background: rgba(0, 0, 0, .06); }
.nd-icon svg { grid-area: 1 / 1; width: 14px; height: 14px; transition: opacity .3s var(--soft), transform .45s var(--give); }
.nd-icon .i-ok { opacity: 0; transform: scale(.5); }
.nv-drop.copied .nd-icon .i-copy { opacity: 0; transform: scale(.5); }
.nv-drop.copied .nd-icon .i-ok { opacity: 1; transform: none; }
.nd-mail { display: grid; }
.nd-mail > span { grid-area: 1 / 1; justify-self: start; transition: opacity .35s var(--soft), transform .5s var(--soft); }
.nd-mail .nd-done { opacity: 0; transform: translateY(6px); }
.nv-drop.copied .nd-mail .nd-addr { opacity: 0; transform: translateY(-6px); }
.nv-drop.copied .nd-mail .nd-done { opacity: 1; transform: none; }

/* name ↔ "back to home": one line slides out the top, the other comes in from below */
/* the name sits in the same pill as the rest of the menubar (white on dark, black on light) */
.nv-logo > .nv-i { display: flex; align-items: center; height: 32px; padding: 0 12px; border-radius: 4px;
  color: var(--glass-fg); background: var(--glass); box-shadow: inset 0 0 0 1px var(--glass-edge);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%); }
.nv-logo:not(.nv-static):hover > .nv-i, .nv-logo:focus-visible > .nv-i { background-color: var(--glass-hi); }
.nv-static { cursor: default; }
/* the name pill hugs whichever label is showing: main.js measures both labels into --w1 / --w2 and
   the width eases between them on hover (until measured, it fits the wider one) */
.nv-swap { display: grid; height: 1em; overflow: clip; }
.nv-swap > span { width: max-content; }
.nv-swap.sized { width: var(--w1); transition: width .7s var(--soft); }
.nv-logo:not(.nv-static):hover .nv-swap.sized { width: var(--w2); }
.nv-swap > span { grid-area: 1 / 1; white-space: nowrap; transition: transform .7s var(--soft); }
.nv-swap > span + span { transform: translateY(110%); }
.nv-logo:not(.nv-static):hover .nv-swap > span:first-child { transform: translateY(-110%); }
.nv-logo:not(.nv-static):hover .nv-swap > span + span { transform: none; }
.nv-menu { display: none; }
.menu { display: none; }

/* entrance: rise 48px out of the clip, only on the first page of a visit */
.js:not(.nv-seen) .nv-i { transform: translateY(48px); }
.loaded .nv-i { transform: none; transition: transform 1.1s var(--out) var(--d, .6s), background-color .6s var(--soft), box-shadow .6s var(--soft), width .75s var(--give); }
.nv-seen .nv-i, .nv-seen.loaded .nv-i { transition: background-color .6s var(--soft), box-shadow .6s var(--soft), width .75s var(--give), transform .6s var(--give); }
.nv-chip.nv-i:active { transform: scale(.96); }

@media (max-width: 809.98px) {
  .nv-mid, .nv-contact, .nv-drop { display: none; }
  .nv-right { right: 78px; z-index: 52; }
  .nv-menu {
    display: grid; left: auto; right: 10px; top: 10px; z-index: 52; width: 72px; height: 32px; padding: 0; align-content: center; justify-content: center; border-radius: 4px;
    background: var(--glass); color: var(--glass-fg); font: inherit; letter-spacing: inherit;
    -webkit-backdrop-filter: blur(18px) saturate(170%); backdrop-filter: blur(18px) saturate(170%);
    box-shadow: inset 0 0 0 1px var(--glass-edge);
  }
  .nv-mt { display: grid; height: 1em; overflow: clip; }
  .nv-mt span { grid-area: 1 / 1; text-align: center; transition: transform .6s var(--soft); }
  .nv-mt span + span { transform: translateY(110%); }
  .menu-open .nv-mt span:first-child { transform: translateY(-110%); }
  .menu-open .nv-mt span + span { transform: none; }
  /* frosted panel grows out of the MENU pill */
  .menu {
    display: flex; flex-direction: column; justify-content: center; position: fixed; inset: 0; z-index: 49;
    background: rgba(18, 18, 20, .62); -webkit-backdrop-filter: blur(30px) saturate(160%); backdrop-filter: blur(30px) saturate(160%);
    color: #fff; text-transform: uppercase; letter-spacing: -.02em;
    clip-path: inset(10px 10px calc(100% - 42px) calc(100% - 82px) round 4px); visibility: hidden;
    transition: clip-path .75s var(--soft), visibility 0s .75s;
  }
  .menu-open .menu { clip-path: inset(0 0 0 0 round 0); visibility: visible; transition: clip-path .75s var(--soft); }
  .menu-big { text-align: center; }
  .menu-big li { overflow: clip; }
  .menu-big a { display: block; padding: 3px 0; font-size: 30px; font-weight: 600; line-height: 1.05; letter-spacing: -.045em; transform: translateY(80px); transition: transform .7s var(--out); }
  .menu-open .menu-big a { transform: none; transition-delay: calc(.12s + var(--i) * .04s); }
  .menu-big a[aria-current] { color: rgba(255, 255, 255, .45); }
  /* Contact: one pill with the address; tap to copy */
  .menu-contact { display: flex; justify-content: center; padding-top: 14px; }
  .mc-copy { display: inline-flex; max-width: calc(100vw - 48px); padding: 13px 18px; border: 0; border-radius: 6px; cursor: pointer;
    background: var(--glass); color: var(--glass-fg, #000); font: 500 15px/1.3 var(--font); letter-spacing: -.01em; text-align: left;
    transform: translateY(80px); transition: transform .7s var(--out); }
  .menu-open .mc-copy { transform: none; transition-delay: calc(.12s + var(--i) * .04s); }
  .mc-t { display: grid; } .mc-t > span { grid-area: 1 / 1; transition: opacity .3s var(--soft), transform .4s var(--soft); }
  .mc-l2 { display: flex; align-items: center; gap: 8px; }
  .mc-l2 b { font-weight: 600; }
  .mc-copy svg { width: 16px; height: 16px; flex: none; }
  .mc-done { display: flex; align-items: center; gap: 8px; opacity: 0; transform: translateY(6px); }
  .mc-copy.copied .mc-addr { opacity: 0; transform: translateY(-6px); }
  .mc-copy.copied .mc-done { opacity: 1; transform: none; }
  .menu-tick { position: absolute; left: 0; right: 0; bottom: 0; overflow: clip; font-size: 96px; font-weight: 500; line-height: 1; transform: translateY(120px); transition: transform .8s var(--out); }
  .menu-open .menu-tick { transform: none; transition-delay: .2s; }
  .menu-tick > div { display: flex; width: max-content; animation: menu-tick 14s linear infinite; }
  .menu-tick span { padding-right: 24px; white-space: nowrap; }
}
@keyframes menu-tick { to { transform: translateX(-50%); } }

/* ---------- theme toggle + light mode ----------
   Dark is the default; html[data-theme="light"] flips the tokens. The switch itself is a
   circular reveal from the toggle (view transition, see main.js). */
.nv-theme { width: 32px; padding: 0; overflow: clip; }
.nv-theme svg { position: absolute; width: 16px; height: 16px; transition: transform .7s var(--give), opacity .4s var(--soft); }
.nv-theme .i-moon { opacity: 0; transform: rotate(-90deg) scale(.4); }
[data-theme="light"] .nv-theme .i-sun { opacity: 0; transform: rotate(90deg) scale(.4); }
[data-theme="light"] .nv-theme .i-moon { opacity: 1; transform: none; }
.nv-theme:hover svg { transform: rotate(20deg); }
/* right-hand dropdowns (Social links, colour themes): a glass box that unfolds from under its pill,
   styled and timed like Contact's email box. JS adds .on. */
.nv-ddrop {
  position: absolute; top: 48px; right: 10px; display: flex; flex-direction: column; min-width: 168px; padding: 4px;
  border-radius: 4px; background: var(--glass); color: var(--glass-fg); white-space: nowrap;
  font: 500 13px/1 var(--font); letter-spacing: 0; text-transform: none;
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
  box-shadow: inset 0 0 0 1px var(--glass-edge);
  transform-origin: 100% 0; opacity: 0; visibility: hidden; pointer-events: none;
  transform: translateY(-8px) scale(.94); filter: blur(6px); clip-path: inset(0 0 100% 0 round 4px);
  transition: opacity .25s var(--soft), transform .35s var(--soft), filter .25s var(--soft), clip-path .3s var(--soft), visibility 0s .35s, background-color .5s var(--soft);
}
.nv-ddrop.on {
  opacity: 1; visibility: visible; pointer-events: auto; transform: none; filter: blur(0); clip-path: inset(0 0 0 0 round 4px);
  transition: opacity .35s var(--soft), transform .7s var(--give), filter .45s var(--soft), clip-path .6s var(--soft), visibility 0s, background-color .5s var(--soft);
}
.nv-ddrop.on::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }   /* hover bridge */
.nv-ddrop > * { display: flex; align-items: center; gap: 10px; height: 36px; padding: 0 10px; border-radius: 3px; font: inherit; color: inherit; text-align: left;
  opacity: 0; transform: translateY(-6px); transition: background-color .3s var(--soft), opacity .3s var(--soft), transform .55s var(--soft); }
.nv-ddrop.on > * { opacity: 1; transform: none; }
.nv-ddrop.on > :nth-child(n+2) { transition-delay: 0s, .04s, .04s; }
.nv-ddrop.on > :nth-child(n+4) { transition-delay: 0s, .08s, .08s; }
.nv-ddrop.on > :nth-child(n+6) { transition-delay: 0s, .12s, .12s; }
.nv-ddrop > :hover, .nv-ddrop > :focus-visible { background-color: rgba(127, 127, 127, .16); }
.nv-sdrop { right: 48px; }   /* under the Social pill, which sits left of the 32px theme switch */
.nv-sdrop svg { width: 16px; height: 16px; flex: none; }
.ns-arrow { margin-left: auto; opacity: .5; }
/* colour themes: a tight grid of thumbnails, each the page colour with a square of its ink colour;
   the current one gets a ring */
.nv-tdrop { display: grid; grid-template-columns: repeat(4, 34px); gap: 4px; min-width: 0; padding: 6px; }
.nv-tdrop > * { height: 24px; padding: 0; border-radius: 2px; }
.nv-tdrop > :hover, .nv-tdrop > :focus-visible { background: none; }
.tp-sw { display: grid; place-items: center; width: 100%; height: 100%; border-radius: 2px; background: var(--sb);
  box-shadow: inset 0 0 0 1px rgba(127, 127, 127, .35); transition: transform .3s var(--give); }
.tp-sw::after { content: ""; width: 8px; height: 8px; background: var(--sf); }
.nv-tdrop > :hover .tp-sw { transform: scale(1.08); }
.nv-tdrop [aria-checked="true"] .tp-sw { box-shadow: 0 0 0 1.5px var(--glass-fg); }
[data-theme="light"] .nv-theme:hover .i-moon { transform: rotate(-16deg); }
[data-theme="light"] .nv-theme:hover .i-sun { transform: rotate(90deg) scale(.4); }

html.theme-vt::view-transition-old(root) { animation: none; }
html.theme-vt::view-transition-new(root) { animation: theme-in .75s cubic-bezier(.65, 0, .25, 1) both; }
@keyframes theme-in {
  from { clip-path: circle(0 at var(--tx, 100%) var(--ty, 0)); }
  to { clip-path: circle(var(--tr, 150vmax) at var(--tx, 100%) var(--ty, 0)); }
}

[data-theme="light"] {
  --bg: #fff; --fg: #000;
  --mute: rgba(0, 0, 0, .55); --line: rgba(0, 0, 0, .12); --chip: rgba(0, 0, 0, .06); --card: rgba(0, 0, 0, .04);
  /* light mode: black pills with white text (the current page is solid black) */
  --glass: rgba(9, 9, 11, .86); --glass-hi: rgba(39, 39, 42, .94); --glass-on: #000;
  --glass-edge: rgba(255, 255, 255, .08); --glass-fg: #fff;
  color-scheme: light;
}
[data-theme="light"] ::selection { background: #000; color: #fff; }
[data-theme="light"] .reel { background: #e4e4e7; }
[data-theme="light"] .cell video, [data-theme="light"] .card-media, [data-theme="light"] .g-media,
[data-theme="light"] .fp-media, [data-theme="light"] .fp-cover-media { background: #f0f0f1; }
[data-theme="light"] .cell iframe { background: #ececed; }
[data-theme="light"] .nd-icon { background: rgba(0, 0, 0, .06); }
[data-theme="light"] .foot { background: #f4f4f5; color: #71717b; }
[data-theme="light"] .ft-h, [data-theme="light"] .scr:hover, [data-theme="light"] .scr:focus-visible { color: #09090b; }
[data-theme="light"] .ft-dot { color: #d4d4d8; }
/* titles laid over the cover images stay white */
[data-theme="light"] .lb { color: #fff; --mute: rgba(255, 255, 255, .6); --chip: rgba(255, 255, 255, .1); }
@media (max-width: 809.98px) {
  [data-theme="light"] .menu { background: rgba(255, 255, 255, .7); color: #000; }
  [data-theme="light"] .menu-big a[aria-current] { color: rgba(0, 0, 0, .4); }
}

/* ---------- entrance ---------- */
.js .a-in { opacity: 0; transform: translateY(30px); }
.loaded .a-in { opacity: 1; transform: none; transition: opacity 1s var(--ease) var(--d, 0s), transform 1.1s var(--out) var(--d, 0s); }
.js .a-pop { opacity: 0; transform: translateY(120px) scale(.2); }
.loaded .a-pop { opacity: 1; transform: none; transition: opacity .5s var(--ease) .9s, transform 1s var(--spring) .9s; }
.js [data-r] { opacity: 0; transform: translateY(30px); }
.js [data-r].in { opacity: 1; transform: none; transition: opacity 1s var(--ease) var(--rd, 0s), transform 1.2s var(--out) var(--rd, 0s); }
.js .about-pg [data-r], .js .proj [data-r], .js .works [data-r] { transform: translateY(14px); }
.js .proj [data-r].in, .js .works [data-r].in { transform: none; transition: opacity .4s var(--ease) var(--rd, 0s), transform .55s var(--out) var(--rd, 0s); }
.js .about-pg [data-r].in { transform: none; transition: opacity .45s var(--ease) var(--rd, 0s), transform .6s var(--out) var(--rd, 0s); }
.js .about-pg .a-in { transform: translateY(14px); }
.js .about-pg.loaded .a-in { transform: none; transition: opacity .5s var(--ease) var(--d, 0s), transform .6s var(--out) var(--d, 0s); }

/* ---------- fit text ---------- */
.fit { display: inline-block; white-space: nowrap; font-size: 160px; }
[data-fit] { visibility: hidden; }
.fitted [data-fit] { visibility: visible; }

/* ---------- hero ---------- */
.hero {
  position: sticky; top: 0; z-index: 1; height: 94vh; min-height: 500px; overflow: hidden;
  display: flex; align-items: center; gap: 20px; padding: 0;
}
.hero-spacer { flex: none; width: 20%; }
.hero-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 20px; padding-right: var(--g); will-change: transform, opacity; }
.hero-name { line-height: .8; }
.hero-name .fit { text-transform: uppercase; letter-spacing: -.06em; line-height: .8; padding-right: .06em; }
.hero-intro { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0 20px; align-items: start; }
.hero-reel { grid-column: 1 / span 2; }
.reel { width: 100%; border-radius: 2px; overflow: hidden; background: #111; }
.reel video { width: 100%; height: 100%; }
.hero-p { grid-column: 4 / span 2; max-width: 210px; }
.hero-bottom { position: absolute; left: var(--g); right: var(--g); bottom: var(--g); display: flex; justify-content: space-between; align-items: flex-end; }
.clock { display: inline-flex; align-items: center; gap: 8px; font-variant-numeric: tabular-nums; }
.clock-sep { color: var(--mute); }
.live { width: 6px; height: 6px; border-radius: 50%; background: #3ddc84; box-shadow: 0 0 0 0 rgba(61, 220, 132, .6); animation: ping 2s var(--ease) infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 7px rgba(61, 220, 132, 0); } 100% { box-shadow: 0 0 0 0 rgba(61, 220, 132, 0); } }
@media (max-width: 1199.98px) {
  .hero-spacer { width: 0; }
  .hero-main { padding-left: var(--g); }
  .hero-intro { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .hero-reel { grid-column: 1 / span 2; }
  .hero-p { grid-column: 3 / span 2; max-width: 175px; }
}
@media (max-width: 809.98px) {
  .hero { align-items: flex-end; padding-bottom: 70px; }
  .hero-reel { grid-column: 1 / span 2; }
  .hero-p { grid-column: 3 / span 2; }
}

/* centred intro (live home): copy sits in the middle of the screen, same size as before */
.hero-c .hero-spacer { display: none; }
.hero-c .hero-main { position: absolute; left: 0; right: 0; top: 0; height: 100vh; height: 100svh; padding: 0 var(--g); align-items: center; justify-content: center; }
.hero-c .hero-intro { display: block; }
.hero-c .hero-reel { display: none; }
.hero-c .hero-p { margin: 0 auto; text-align: center; }
/* same type as the About bio: Geist Semi Bold 20/22, -0.4px */
.hero-c .hero-p { font-size: 20px; font-weight: 600; line-height: 22px; letter-spacing: -.4px; color: var(--fg); }
.hero-c .hero-p { max-width: 273px; }   /* 210px + 30% */
/* three set lines on tablet and desktop; phones wrap naturally */
@media (min-width: 810px) {
  .hero-c .hero-p { max-width: none; }
  .hero-c .hero-p span { display: block; white-space: nowrap; }
}

/* cursor image trail (alternate hero) — each image keeps its own aspect ratio */
.trail { position: absolute; inset: 0; z-index: 4; pointer-events: none; overflow: hidden; }
.trail img {
  position: absolute; left: 0; top: 0; display: block; max-width: none;
  transform: scale(0); will-change: transform; backface-visibility: hidden;
}
@media (hover: none), (max-width: 809.98px) { .trail { display: none; } }

/* everything after the hero slides up over it */
.cover { position: relative; z-index: 3; background: var(--bg); }

/* ---------- justified rows: widths ∝ aspect ratio, so heights match and nothing is cropped ---------- */
.rows { display: flex; flex-direction: column; gap: var(--gap); }
.row { display: flex; gap: var(--gap); align-items: flex-start; }
.cell { flex: var(--ar) 1 0%; min-width: 0; aspect-ratio: var(--ar); position: relative; display: block; }
.cell img, .cell iframe { width: 100%; height: 100%; }
.cell video { display: block; width: 100%; height: 100%; background: #0d0d0d; }
.cell iframe { border: 0; background: #0a0a0a; }
.rows.tight { gap: 20px; } .rows.tight .row { gap: 20px; }
@media (max-width: 809.98px) {
  .row { flex-direction: column; }
  .cell { flex: none; width: 100%; }
  .rows.tight .row { flex-direction: row; }
  .rows.tight .cell { flex: var(--ar) 1 0%; width: auto; }
}
.gal .cell, .rows.grid .cell { aspect-ratio: auto; }

/* ---------- work cards ---------- */
.works { position: relative; padding: 20px var(--g) 0; background: var(--bg); }
.card { color: #fff; }
.card-media { display: block; aspect-ratio: var(--ar); overflow: hidden; background: #0d0d0d; border-radius: 2px; }
/* light loading: a ~1KB blurred preview fills the card, the real image fades in over it */
.card-media { position: relative; }
.card-media::before { content: ""; position: absolute; inset: 0; background: var(--lq, none) center / cover no-repeat; filter: blur(14px); transform: scale(1.15); }
.card-media picture { display: contents; }
.card-media img { position: relative; }
.js .card-media img { opacity: 0; }
.js .card-media img.ld { opacity: 1; transition: opacity .35s var(--ease), filter .8s var(--ease), transform 1.2s var(--out); }
.card-media img { width: 100%; height: 100%; filter: brightness(.86); transition: filter .8s var(--ease), transform 1.2s var(--out); }
.card:hover .card-media img { filter: brightness(1); }
.card-media video { position: relative; display: block; width: 100%; height: 100%; object-fit: cover; filter: brightness(.94); transition: filter .8s var(--ease); }
.card:hover .card-media video { filter: brightness(1); }
/* Vimeo thumbnail: fills the card (16:9), never takes clicks so the whole card stays a link */
.card-media .card-vimeo { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; pointer-events: none; background: transparent; }
/* caption: a glass pill in the thumbnail's top-left corner (same glass as the menubar), with the title
   and its category tags; it rises in on hover. Touch screens (no hover) show it all the time. */
.card-info { position: absolute; left: 12px; top: 12px; z-index: 2; max-width: calc(100% - 24px);
  display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding: 9px 12px 10px; border-radius: 4px;
  color: var(--glass-fg); background: var(--glass); box-shadow: inset 0 0 0 1px var(--glass-edge);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
  pointer-events: none; opacity: 0; transform: translateY(-6px);
  transition: opacity .3s var(--soft), transform .5s var(--give), background-color .5s var(--soft); }
.cell:hover .card-info, .cell:focus-visible .card-info { opacity: 1; transform: none; }
@media (hover: none) { .card-info { opacity: 1; transform: none; } }
.card-title { font-size: 15px; letter-spacing: -.01em; line-height: 1.2; font-weight: 500; }
.card-title .roll { line-height: 1.2; } .card-title .ch { height: 1.2em; }
.card-svc { font-size: 12px; line-height: 1.3; opacity: .62; }

/* ---------- sections ---------- */
.sec { position: relative; padding: 160px var(--g) 0; }
.split { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 20px; }
.split-l { grid-column: 1 / span 4; }
.split-r { grid-column: 5 / span 8; display: flex; flex-direction: column; gap: 60px; }
@media (max-width: 809.98px) {
  .sec { padding-top: 100px; }
  .split { display: flex; flex-direction: column; gap: 24px; }
  .split-r { gap: 40px; }
  .lead { font-size: 20px; }
}
.about-pics { max-width: 850px; }
.more { margin-top: -20px; }

.exp { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 20px; margin-top: 160px; }
.exp-head { grid-column: 1 / span 4; }
.table { grid-column: 5 / span 8; }
.th, .tr { display: grid; grid-template-columns: 1.2fr 1.2fr .6fr; gap: 20px; }
.th { padding-bottom: 12px; }
.tr { padding: 14px 0; border-top: 1px solid var(--line); position: relative; transition: color .4s var(--ease); }
.tr span:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.th span:last-child { text-align: right; }
.table ul:hover .tr { color: var(--mute); }
.table ul .tr:hover { color: var(--fg); }
@media (max-width: 809.98px) {
  .exp { display: flex; flex-direction: column; gap: 24px; margin-top: 100px; }
  .th { display: none; }
  .tr { grid-template-columns: 1fr auto; }
  .tr span:first-child { grid-column: 1 / -1; }
  .tr span:first-child:empty { display: none; }
  .tr span:nth-child(2) { color: var(--mute); }
}

/* capabilities */
.caps-in { display: flex; gap: 60px 20px; align-items: flex-start; }
.caps-head { flex: 1 0 0; position: sticky; top: 80px; display: flex; flex-direction: column; gap: 20px; }
.caps-list { flex: 2 0 0; display: flex; flex-direction: column; }
.cap { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding: 24px 0 60px; border-top: 1px solid var(--line); }
.cap-t { display: flex; flex-direction: column; gap: 12px; }
.cap-d { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.cap-d ul { display: flex; flex-direction: column; gap: 8px; }
.cap-d a { text-transform: uppercase; letter-spacing: .01em; transition: color .3s var(--ease); }
.cap-d:hover a { color: var(--mute); } .cap-d a:hover { color: var(--fg); }
@media (max-width: 809.98px) {
  .caps-in { flex-direction: column; gap: 40px; }
  .caps-head { position: relative; top: 0; }
  .cap { grid-template-columns: 1fr; }
  .h3u, .h2u { font-size: 26px; }
}

/* cursor preview — natural aspect ratio */
.preview {
  position: fixed; left: 0; top: 0; z-index: 40; width: 260px; pointer-events: none;
  opacity: 0; transform: translate3d(-999px, 0, 0) scale(.6); transition: opacity .35s var(--ease); border-radius: 2px; overflow: hidden;
}
.preview.on { opacity: 1; }
.preview img { width: 100%; height: auto; }
@media (hover: none) { .preview { display: none; } }

/* testimonials */
.testi { padding-top: 300px; }
.about .testi { padding: 160px 0 0; }   /* sits inside the About section, between bio and Experience */
.testi .sec-head { margin-bottom: 16px; }
/* testimonial cards drift left → right on a seamless loop, edge to edge */
.ticker.tmarq { margin-inline: calc(-1 * var(--g)); white-space: normal; }
.tmarq .track { align-items: stretch; gap: var(--gap); padding-right: var(--gap); }
.tmarq .tcopy { display: contents; }
.tmarq .tcard { flex: none; width: calc((100vw - 2 * var(--g) - 3 * var(--gap)) / 4); }
@media (max-width: 1199.98px) { .tmarq .tcard { width: calc((100vw - 2 * var(--g) - var(--gap)) / 2); } }
@media (max-width: 809.98px) { .tmarq .tcard { width: 80vw; } }
.sec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 40px; }
.tgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.tcard { background: var(--card); border-radius: 4px; padding: 20px; display: flex; flex-direction: column; justify-content: space-between; gap: 60px; min-height: 420px; }
.tcard figcaption { display: flex; flex-direction: column; gap: 4px; }
.tname { text-transform: uppercase; letter-spacing: .01em; }
.tcard blockquote { font-size: 17px; font-weight: 400; line-height: 1.3; letter-spacing: -.01em; }
@media (max-width: 1199.98px) { .tgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 809.98px) { .tgrid { grid-template-columns: 1fr; } .tcard { min-height: 0; } .testi { padding-top: 140px; } .about .testi { padding-top: 100px; } .sec-head { flex-direction: column; align-items: flex-start; } }

/* tickers */
.ticker { overflow: hidden; white-space: nowrap; }
.track { display: inline-flex; align-items: center; will-change: transform; }
.clients .label { margin-bottom: 40px; }
.ticker.small .track { gap: 60px; font-size: 40px; letter-spacing: -.03em; font-weight: 400; padding-right: 60px; }
.ticker.small .cl { line-height: 1.1; }

/* awards */
.awards { min-height: 110vh; display: flex; align-items: center; padding-bottom: 160px; }
.aw-grid { width: 100%; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 20px; align-items: start; }
.aw-title { grid-column: 1 / span 4; position: sticky; top: 80px; }
.aw-list { grid-column: 5 / span 8; }
.aw-list li > * { display: grid; grid-template-columns: 1.4fr .5fr 1.2fr .4fr; gap: 20px; padding: 14px 0; border-top: 1px solid var(--line); transition: color .3s var(--ease), padding .5s var(--out); }
.aw-list a:hover { padding-left: 10px; }
.aw-list:hover li > * { color: var(--mute); } .aw-list li > *:hover { color: var(--fg); }
.aw-y { text-align: right; font-variant-numeric: tabular-nums; }
.aw-n { text-transform: uppercase; letter-spacing: .01em; }
@media (max-width: 809.98px) {
  .aw-grid { display: flex; flex-direction: column; gap: 40px; }
  .aw-title { position: relative; top: 0; }
  .aw-list li > * { grid-template-columns: 1fr auto; gap: 4px 12px; }
  .aw-list li > * > span:nth-child(2):empty { display: none; }
  .aw-list li > * > span:nth-child(3) { grid-column: 1; color: var(--mute); }
}

/* values — pinned, words light up with scroll */
.values { height: 220vh; position: relative; }
.values-pin { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 28px; text-align: center; }
.vlist { display: flex; flex-direction: column; align-items: center; }
.vw { font-size: clamp(48px, 9vw, 150px); letter-spacing: -.05em; line-height: .9; text-transform: uppercase; opacity: .12; transition: opacity .25s linear; }
.vcta { margin-top: 12px; }

/* all works */
.allworks { padding: 40px var(--g) 160px; text-align: center; }
.allbtn { display: inline-block; font-size: clamp(64px, 14vw, 240px); letter-spacing: -.06em; text-transform: uppercase; line-height: .9; }
.allbtn .roll, .allbtn .ch { line-height: .9; } .allbtn .ch { height: .9em; }
.allbtn .ch > span { transition-duration: .7s; transition-delay: calc(var(--i) * 30ms); }

/* footer — fixed behind the page, revealed as the content scrolls away */
main { position: relative; z-index: 1; background: var(--bg); border-bottom: 1px solid var(--line); }
.foot-space { height: 100vh; pointer-events: none; }
.foot {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 0; height: 100vh; overflow: hidden;
  display: flex; background: #09090b; color: #71717b;
  font-size: 16px; font-weight: 400; letter-spacing: -.02em; line-height: 1.5; text-transform: uppercase;
  transform: translate3d(0, 300px, 0); will-change: transform;
}
.ft-text { position: relative; z-index: 2; flex: 1 0 0; min-width: 0; display: flex; flex-direction: column; justify-content: flex-end; gap: 120px; padding: 80px 10px 10px; pointer-events: none; }
.ft-text a, .ft-text li { pointer-events: auto; }
.ft-cols { display: flex; gap: 10px; }
.ft-cols > * { flex: 1 0 0; min-width: 0; }
.ft-col2 { display: flex; flex-direction: column; gap: 40px; }
.ft-h { color: #fafafa; }
.ft-dot { color: #3f3f46; margin: 0 10px; }
.scr { display: inline-block; white-space: nowrap; transition: color .2s linear; }
.scr:hover, .scr:focus-visible { color: #fafafa; }
.ft-art { flex: 1 0 0; min-width: 0; position: relative; }
.glyph { position: absolute; z-index: 1; width: min(944px, 58vw); aspect-ratio: 1; right: -8vw; bottom: -2vh; }
/* the ASCII canvas covers the whole footer so letters can fly anywhere; .glyph only marks where the portrait sits */
.ft-canvas { position: absolute; left: 0; top: 0; z-index: 1; display: block; pointer-events: none; }
.foot { touch-action: pan-y; }
@media (max-width: 809.98px) {
  .foot-space { display: none; }
  main { border-bottom: 0; }
  .foot { position: relative; height: auto; flex-direction: column; transform: none; }
  .ft-text { gap: 40px; padding: 40px 10px 10px; }
  .ft-cols:not(.ft-bottom) { flex-direction: column; gap: 40px; }
  .ft-art { padding: 20px; }
  .glyph { position: relative; width: 100%; right: auto; bottom: auto; }
}

/* ---------- page titles ---------- */
.ptitle { padding: 112px var(--g) 40px; display: flex; flex-direction: column; gap: 28px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.about-top { padding-top: 72px; }
.plain li.gap { margin-top: 1.16em; }
.big { font-size: clamp(36px, 11vw, 240px); letter-spacing: -.06em; line-height: .8; text-transform: uppercase; display: flex; align-items: flex-start; flex-wrap: wrap; gap: 0 .15em; }
.paren { font-size: 14px; letter-spacing: .01em; line-height: 1; font-weight: 500; padding-top: .3em; }
/* filters: plain text; the selected one is underlined (the line draws in from the left) */
.chips { display: flex; flex-wrap: wrap; gap: 6px 24px; }
.chip { padding: 0 0 3px; border-radius: 0; color: var(--fg);
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .5s var(--out), color .3s var(--ease); }
.chip:not(.on):hover { color: var(--mute); }
.chip.on { background-size: 100% 1px; }
.rows.grid { transition: opacity .35s var(--ease); }
/* a lone project card keeps the half-width size of its neighbours (home + works) */
.works:not(.gal) .rows.grid .row.solo > .cell { flex: 0 0 calc((100% - var(--gap)) / 2); }
.works:not(.gal) .rows.grid .row.solo > .cell[data-wide] { flex: 1 1 100%; }   /* e.g. Dailies: edge to edge */
@media (max-width: 809.98px) { .works:not(.gal) .rows.grid .row.solo > .cell { flex: none; width: 100%; } }
.rows.grid.swap { opacity: 0; }

/* galleries (play / illustrations) */
.gal figcaption { display: flex; flex-direction: column; gap: 2px; padding: 10px 0 30px; }
.gal figcaption span + span { color: var(--mute); }
.g-media { display: block; aspect-ratio: var(--ar); overflow: hidden; border-radius: 2px; background: #0d0d0d; }
.g-media img { width: 100%; height: 100%; transition: filter .8s var(--ease); filter: brightness(.92); }
.g-media:hover img { filter: brightness(1); }
.lb { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .92); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 60px var(--g); opacity: 0; visibility: hidden; transition: opacity .45s var(--ease), visibility 0s .45s; }
.lb.on { opacity: 1; visibility: visible; transition: opacity .45s var(--ease); }
.lb img { max-width: 100%; max-height: calc(100vh - 140px); width: auto; height: auto; object-fit: contain; transform: scale(.96); transition: transform .7s var(--out); }
.lb.on img { transform: none; }
.lb-x { position: absolute; top: 12px; right: var(--g); height: 28px; padding: 0 12px; border-radius: 999px; background: var(--chip); }
.lb-cap { color: var(--mute); text-align: center; }

/* ---------- project ---------- */
.p-head { padding: 140px var(--g) 30px; }
.p-title { line-height: .8; }
.p-title .fit { text-transform: uppercase; letter-spacing: -.06em; line-height: .86; padding-right: .06em; }
.p-hero { margin: 0 var(--g); aspect-ratio: var(--ar); transform-origin: 50% 0; will-change: transform; }
.p-hero img { width: 100%; height: 100%; border-radius: 2px; }
.p-info { padding: 120px var(--g); }
.details { display: grid; grid-template-columns: 1fr; max-width: 700px; }   /* one detail per line: label left, value right */
.dl { display: flex; justify-content: space-between; gap: 20px; padding: 14px 0; border-top: 1px solid var(--line); }
.dl dd { text-align: right; }
.gallery { padding: 0 var(--g); }
.rich { font-size: 17px; font-weight: 400; line-height: 1.45; max-width: 700px; }
.rich p + p { margin-top: .9em; }
.rich strong { font-weight: 500; }
.rich a { text-decoration: underline; text-underline-offset: 3px; }
.sec-s { padding: 100px var(--g) 0; }
.sec .sec-s { padding: 0 0 80px; }
.plain { display: flex; flex-direction: column; gap: 10px; font-size: 14px; font-weight: 500; line-height: 16.24px; letter-spacing: normal; color: var(--fg); }
.plain a { transition: color .3s var(--ease); } .plain a:hover { color: var(--mute); }
.more-works { padding: 200px var(--g) 160px; }
.mw-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 30px; }
.more-works .rows { margin: 0; }
@media (max-width: 809.98px) {
  .p-head { padding-top: 110px; }
  .p-info { padding: 70px var(--g); }
  .details { grid-template-columns: 1fr; }
  .more-works { padding: 120px var(--g) 100px; }
}

/* ---------- contact ---------- */
.contact { min-height: 100vh; padding: 140px var(--g) 80px; display: flex; flex-direction: column; justify-content: center; gap: 28px; }
.c-mail { line-height: .9; }
.c-mail .fit { letter-spacing: -.05em; line-height: 1; padding-right: .05em; }
.c-row { display: flex; flex-wrap: wrap; gap: 8px; }
.c-soc { display: flex; flex-wrap: wrap; gap: 8px 24px; color: var(--mute); }
.c-soc a:hover { color: var(--fg); }

/* page transitions (cross-document view transitions) */
@view-transition { navigation: auto; }
/* kept short: while a transition plays the page can't take clicks, so a long one makes the menubar feel stuck */
::view-transition-old(root) { animation: vt-out .18s var(--ease) both; }
::view-transition-new(root) { animation: vt-in .32s var(--out) both; }
@keyframes vt-out { to { opacity: 0; transform: translateY(-10px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(14px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; transition-delay: 0s !important; }
  .js .a-in, .js .a-pop, .js [data-r], .js .about-pg [data-r], .js .about-pg .a-in { opacity: 1; transform: none; }
}

/* ---------- FIELD-arranged project page (only projects with "layout" in site.json) ----------
   Placement follows field.io/work case studies: full-bleed cover, 12-col grid with 1rem gutter and
   .5rem gap, media full width or paired 6+6, heading-left / text-right blocks. Type is the site's own. */
.fp { --fp-gap: .5rem; --fp-pad: 1rem; }
.fp-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--fp-gap); width: 100%; max-width: 1800px; margin: 0 auto; padding: 0 var(--fp-pad); }
.fp-c1-9 { grid-column: 1 / 9; }
.fp-c1-6 { grid-column: 1 / 6; }
.fp-c7-e { grid-column: 7 / -1; }
.fp-cell { position: relative; }
.fp-s12 { grid-column: 1 / span 12; }
.fp-s6 { grid-column: span 6; }
.fp-media { position: relative; overflow: hidden; background: #0d0d0d; }
.fp-media img, .fp-media video { display: block; width: 100%; height: 100%; }

.fp-cover { margin-bottom: 10rem; }
.fp-cover-media { position: relative; width: 100%; overflow: hidden; background: #0d0d0d; }
.fp-cover-media img { display: block; width: 100%; height: 100%; }
.fp-meta { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px; padding: 1rem 1rem 0; }

.fp-lead .lead { max-width: none; }
.fp-lead strong { font-weight: inherit; }
.fp-lead + .fp-mediarow, .fp-summary + .fp-mediarow { margin-top: 2rem; }

.fp-summary { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.fp-sum { max-width: 820px; display: flex; flex-direction: column; gap: 30px; }
.fp-sum-row { display: grid; grid-template-columns: 191px minmax(0, 1fr); column-gap: 10px; align-items: start; }
.fp-sum-row h3 { padding-top: 8px; }
.fp-sum-row p { font-size: 24px; line-height: 1.2; letter-spacing: -.01em; font-weight: 400; }

.fp-mediarow + .fp-mediarow { margin-top: .5rem; }
.fp-small { margin-top: 4rem; margin-bottom: 4rem; }
.fp-small .rich { max-width: none; }
.fp-medium { margin-top: 9rem; margin-bottom: 2rem; }
.fp-medium .lead { max-width: none; }

.fp-credits { margin-top: 6rem; margin-bottom: 6rem; row-gap: 0; }
.fp-cr-head { grid-column: 1 / span 6; grid-row: 1 / span 40; }
.fp-source { margin-top: 1rem; }
.fp-cr-role { grid-column: 7 / span 3; font-size: 14px; font-weight: 500; }
.fp-cr-names { grid-column: 10 / span 3; }
.fp-cr-role, .fp-cr-names { padding: 12px 0; border-top: 1px solid var(--line); }

@media (max-width: 767.98px) {
  .fp-cover { margin-bottom: 5rem; }
  .fp-sum { gap: 28px; }
  .fp-sum-row { grid-template-columns: 1fr; row-gap: .5rem; }
  .fp-sum-row h3 { padding-top: 0; }
  .fp-sum-row p { font-size: 20px; }
  .fp-lead .fp-c1-9, .fp-medium .fp-c1-9, .fp-summary .fp-c1-9 { grid-column: 1 / -1; }
  .fp-small { margin-bottom: 2rem; }
  .fp-small .fp-c1-6 { grid-column: 1 / -1; margin-bottom: 1rem; }
  .fp-small .fp-c7-e { grid-column: 1 / -1; }
  .fp-medium { margin-top: 5rem; }
  .fp-cr-head { grid-row: auto; grid-column: 1 / -1; margin-bottom: 1rem; }
  .fp-cr-role { grid-column: 1 / span 5; }
  .fp-cr-names { grid-column: 6 / span 7; }
}

/* ---------- Fun: 3D infinite gallery ---------- */
.pool-pg main { border-bottom: 0; }
.g3 { position: fixed; inset: 0; overflow: hidden; background: var(--bg); touch-action: none; }
.g3-cam { position: absolute; inset: 0; perspective: 1200px; display: flex; align-items: center; justify-content: center; }
.g3-wall { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; will-change: transform; transition: transform .6s cubic-bezier(.4, 0, .2, 1); }
.g3-lanes { position: absolute; left: 0; width: 100%; display: flex; justify-content: center; gap: var(--gap); padding: var(--gap) var(--g); transition: top .6s cubic-bezier(.4, 0, .2, 1); }
.g3-lane { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--gap); will-change: transform; }
/* each tile: the image (Work-grid corners) with a small caption under it */
.g3-t { flex-shrink: 0; width: 100%; margin: 0;
  opacity: 0; transform: translateY(40px); transition: opacity .7s cubic-bezier(.19, 1, .22, 1), transform .7s cubic-bezier(.19, 1, .22, 1); }
.g3-t.in { opacity: 1; transform: none; }
.g3-img { border-radius: 2px; overflow: hidden; background: var(--card); }
.g3-img img { display: block; width: 100%; height: 100%; object-fit: cover; user-select: none; -webkit-user-drag: none; backface-visibility: hidden; }
/* caption: the same glass pill as the Work cards, in the image's top-left corner, revealed on hover
   (always shown on touch screens) */
.g3-t { position: relative; }
.g3-cap { position: absolute; left: 10px; top: 10px; z-index: 2; max-width: calc(100% - 20px);
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 7px 10px 8px; border-radius: 4px;
  color: var(--glass-fg); background: var(--glass); box-shadow: inset 0 0 0 1px var(--glass-edge);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
  pointer-events: none; opacity: 0; transform: translateY(-6px);
  transition: opacity .3s var(--soft), transform .5s var(--give); }
.g3-t:hover .g3-cap { opacity: 1; transform: none; }
@media (hover: none) { .g3-cap { opacity: 1; transform: none; } }
.g3-cap-t { font-size: 13px; line-height: 1.2; font-weight: 500; }
.g3-cap-s { font-size: 11px; line-height: 1.3; opacity: .62; }
/* gradient under the menubar (every page): page colour at the top fading to clear, so the pills read
   over whatever scrolls behind; taller on the Fun page to cover its category row */
/* outside the nav (its own layer, z 43) so the About clocks/hoop can pass above it but under the nav items (z 50) */
.nv-frost { position: fixed; left: 0; right: 0; top: 0; z-index: 43; height: 100px; pointer-events: none; background: linear-gradient(to bottom, var(--bg) 30%, transparent); }
body:has(.nv-sub:not(.peek)) .nv-frost { height: 136px; }
/* hairline tying the category row to the Fun pill: a short stem drops from Fun to a line running
   above the row (main.js sets its left / width / --stem) */
/* pills end at 42px and the row starts at 54px, so the hairline sits at the midpoint (47.5–48.5px),
   6px from each; the stem rises from it to the bottom of the Fun pill */
.nv-link { position: absolute; top: 47.5px; height: 1px; background: var(--glass); pointer-events: none; }
.nv-link::before { content: ""; position: absolute; left: var(--stem, 50%); bottom: 0; width: 1px; height: 6.5px; background: var(--glass); translate: -.5px 0; }
/* the Contact email box drops over the same spot, so the row steps aside while it's open */
.nv-sub, .nv-link { transition: opacity .3s var(--soft), translate .4s var(--soft); }
.nv-mid.open .nv-sub, .nv-mid.open .nv-link { opacity: 0; pointer-events: none; }
@media (max-width: 809.98px) { .nv-link { display: none; } }
/* message for a category that has nothing yet (e.g. AI) */
.g3-empty { position: absolute; left: 50%; top: 50%; translate: -50% -50%; z-index: 4; margin: 0; color: var(--mute); font-size: 14px; text-align: center; pointer-events: none; }
.g3-empty[hidden] { display: none; }
/* shown while the drift is paused by a click */
.g3-hint { position: absolute; left: 50%; top: 50%; translate: -50% calc(-50% + 8px); z-index: 5; padding: 8px 12px; border-radius: 4px; pointer-events: none;
  font-size: 12px; line-height: 1; color: #fff; background: #000; opacity: 0; transition: opacity .3s var(--soft), translate .5s var(--give); }
.g3.paused .g3-hint { opacity: 1; translate: -50% -50%; }
/* view switcher: same chips as the menubar */
.g3-bar { position: absolute; left: 50%; bottom: 20px; translate: -50% 0; z-index: 5; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; max-width: calc(100% - 32px);
  font: 500 13px/1 var(--font); letter-spacing: -.01em; }
.g3-v { height: 32px; padding: 0 12px; border-radius: 4px; color: var(--glass-fg); background: var(--glass);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%); box-shadow: inset 0 0 0 1px var(--glass-edge);
  transition: background-color .5s var(--soft), color .5s var(--soft), transform .35s var(--give); }
.g3-v:hover { background-color: var(--glass-hi); }
.g3-v:active { transform: scale(.95); }
.g3-v[aria-checked="true"] { background: var(--fg); color: var(--bg); }
.pool-ns { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; padding: 80px var(--g); }
@media (max-width: 809.98px) { .g3-bar { bottom: 14px; gap: 4px; flex-wrap: nowrap; } .g3-v { height: 28px; padding: 0 6px; font-size: 11px; } }


/* About page: Experience → Clients and Talks → Awards use the same 80px step as the lists between them */
.about-pg .about-top + .sec { padding-top: 120px; }
.about-pg .awards { padding-top: 0; }

/* the live home is a single screen with no footer underneath */
body.home main { border-bottom: 0; }
/* banner fills the screen exactly; the location/clock line sits as close to the bottom edge as the menubar text sits to the top */
.hero-c { min-height: 0; height: 100vh; height: 100svh; }
.hero-c .hero-bottom { bottom: 16px; }

/* bottom-edge bend: see main.js; sits above the page, under the menubar, never catches clicks */
.edge-bend { position: fixed; left: 0; right: 0; bottom: 0; height: 110px; z-index: 40; pointer-events: none;
  -webkit-backdrop-filter: url(#edgeBend); backdrop-filter: url(#edgeBend); transition: opacity .4s var(--soft); }
.foot-in .edge-bend { opacity: 0; }

/* ---------- colour palettes (values per palette are inlined in each page's <head> by build.py) ----------
   Everything below derives from the palette's page colour (--bg) and ink (--fg). */
html[data-palette] {
  --mute: color-mix(in srgb, var(--fg) 58%, transparent); --line: color-mix(in srgb, var(--fg) 14%, transparent);
  --chip: color-mix(in srgb, var(--fg) 8%, transparent); --card: color-mix(in srgb, var(--fg) 6%, transparent);
  /* menubar pills in the ink colour with page-colour text, like black-on-white light mode */
  --glass: color-mix(in srgb, var(--fg) 86%, transparent); --glass-hi: color-mix(in srgb, var(--fg) 94%, transparent); --glass-on: var(--fg);
  --glass-edge: color-mix(in srgb, var(--bg) 12%, transparent); --glass-fg: var(--bg);
}
html[data-palette] ::selection { background: var(--fg); color: var(--bg); }
html[data-palette] .reel, html[data-palette] .cell video, html[data-palette] .card-media, html[data-palette] .g-media,
html[data-palette] .fp-media, html[data-palette] .fp-cover-media, html[data-palette] .cell iframe { background: var(--card); }
html[data-palette] .foot { background: color-mix(in srgb, var(--fg) 5%, var(--bg)); color: var(--mute); }
html[data-palette] .ft-h, html[data-palette] .scr:hover, html[data-palette] .scr:focus-visible { color: var(--fg); }
@media (max-width: 809.98px) {
  html[data-palette] .menu { background: color-mix(in srgb, var(--bg) 75%, transparent); color: var(--fg); }
}

/* click burst (main.js): six 3×10px strokes around the click point; never blocks clicks */
.burst { position: fixed; z-index: 80; width: 0; height: 0; pointer-events: none; }
.burst i { position: absolute; left: -1.5px; top: -5px; width: 3px; height: 10px; border-radius: 1.5px; transform-origin: 50% 50%; }

/* Fun categories: a smaller row of menubar pills centred on the page under the menubar. The chosen
   one is solid; the rest are softer until hovered. On phones it becomes a scrollable row under the bar. */
.nv-sub { position: absolute; top: 54px; left: 50%; width: max-content; translate: -50% 0; display: flex; gap: 5px; white-space: nowrap; }
.nv-sub .nv-chip { height: 26px; padding: 0 10px; font-size: 11px; opacity: .55; transition: opacity .3s var(--soft), background-color .6s var(--soft), transform .6s var(--give); }
.nv-sub .nv-chip:hover, .nv-sub .nv-chip[aria-pressed="true"] { opacity: 1; }
@media (max-width: 809.98px) {
  .nv-mid:has(.nv-sub:not(.peek)) { display: block; left: 0; right: 0; width: auto; }
  .nv-mid:has(.nv-sub:not(.peek)) > .nv-clip, .nv-mid:has(.nv-sub:not(.peek)) > .nv-drop { display: none; }
  .nv-sub.peek, .nv-link.peek { display: none; }
  /* phones: the categories wrap onto two centred lines so none are cut off */
  .nv-sub { top: 52px; left: 0; right: 0; width: auto; translate: none; flex-wrap: wrap; justify-content: center; gap: 5px; padding: 0 15px; white-space: nowrap; }
  body:has(.nv-sub:not(.peek)) .nv-frost { height: 150px; }
}

/* off the Fun page the category row only peeks out while Fun (or the row itself) is hovered: the line
   draws in, then the pills drop in one after another */
.nv-sub.peek, .nv-link.peek { pointer-events: none; }
.nv-link.peek { opacity: 0; transform: scaleX(.4); transition: opacity .25s var(--soft), transform .45s var(--soft); }
.nv-sub.peek .nv-chip { opacity: 0; transform: translateY(-6px); transition: opacity .2s var(--soft), transform .3s var(--soft), background-color .6s var(--soft); }
.nv-mid.peeking .nv-sub.peek, .nv-mid.peeking .nv-link.peek { pointer-events: auto; }
.nv-mid.peeking .nv-link.peek { opacity: 1; transform: none; }
.nv-mid.peeking .nv-sub.peek .nv-chip { opacity: 1; transform: none; transition: opacity .35s var(--soft) calc(.06s + var(--i) * .045s), transform .55s var(--give) calc(.06s + var(--i) * .045s), background-color .6s var(--soft); }

/* "See project" button that follows the cursor over Work thumbnails (main.js): the label, and under it
   a large 320px oval flipping through the project's images, in one glass box. It
   stands in for the pointer there, so the arrow cursor is hidden on the cards. */
.see-cta { position: absolute; left: 0; top: 0; z-index: 3; will-change: transform; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 10px 12px 12px;
  border-radius: 4px; background: var(--glass); color: var(--glass-fg); box-shadow: inset 0 0 0 1px var(--glass-edge);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
  font: 500 13px/1 var(--font); letter-spacing: -.01em; text-transform: uppercase; white-space: nowrap; pointer-events: none;
  opacity: 0; transition: opacity .25s var(--soft); }
.see-cta.on { opacity: 1; }
.see-l { display: flex; align-items: center; gap: 6px; }
.see-l svg { width: 14px; height: 14px; }
.see-o { display: block; width: 320px; aspect-ratio: 5 / 3; border-radius: 50%; overflow: hidden; background: rgba(127, 127, 127, .2); }
.card-media .see-o img, .see-o img { position: static; display: block; width: 100%; height: 100%; object-fit: cover; opacity: 1; filter: none; transition: none; }
.see-cta.no-peek .see-o { display: none; }
.see-cta > * { transition: opacity .25s var(--soft), scale .45s var(--give); opacity: 0; scale: .7; }
.see-cta.on > * { opacity: 1; scale: 1; }
@media (hover: hover) and (pointer: fine) { .works a.cell { cursor: none; } }

/* ---------- project pages use the About page's type system ----------
   section labels: .label (500 14px caps) · lead / statement text: the About bio (600 20/22, -0.4px)
   · details (Year / Services): the About lists (500 14/16.24) */
.proj .lead, .proj .lead p, .proj .fp-sum-row p { font-size: 20px; font-weight: 600; line-height: 22px; letter-spacing: -.4px; color: var(--fg); }
.proj .lead strong, .proj .fp-sum-row p strong { font-weight: 600; }
/* every text area on a project page reads in the lead style too — only the labels on the left and the
   Year / Services details stay small */
.proj .rich, .proj .rich p, .proj .rich li { font-size: 20px; font-weight: 600; line-height: 22px; letter-spacing: -.4px; color: var(--fg); }
.proj .rich strong { font-weight: 600; }

/* ---------- the FIELD-arranged project page on the site grid ----------
   Same system as the About page and the other project pages: --g side margins, a 12-column grid with
   20px gutters, labels in columns 1–4, text in columns 5–12 (lines no wider than 700px), media rows
   5px apart like the galleries, and the cover inset to the margins like the other heroes. */
.fp { --fp-gap: 20px; --fp-pad: var(--g); }
.fp-grid { max-width: none; }
.fp-cover-media { width: auto; margin: 0 var(--g); border-radius: 2px; }
.fp-meta { padding: 1rem var(--g) 0; }
.fp-mediarow { column-gap: var(--gap); row-gap: var(--gap); }
.fp-mediarow + .fp-mediarow { margin-top: var(--gap); }
@media (min-width: 810px) {
  .fp-lead .fp-c1-9, .fp-medium .fp-c1-9 { grid-column: 5 / span 8; max-width: 700px; }
  .fp-summary .fp-c1-9 { grid-column: 1 / -1; }
  .fp-sum { max-width: none; }
  .fp-sum-row { grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 20px; }
  .fp-sum-row h3 { grid-column: 1 / span 4; padding-top: 0; }
  .fp-sum-row p { grid-column: 5 / span 8; max-width: 700px; }
  .fp-small .fp-c1-6 { grid-column: 1 / span 4; }
  .fp-small .fp-c7-e { grid-column: 5 / span 8; max-width: 700px; }
  .fp-cr-head { grid-column: 1 / span 4; }
  .fp-cr-role { grid-column: 5 / span 4; }
  .fp-cr-names { grid-column: 9 / span 4; }
}

/* FIELD page: its media rows sit between standard text sections */
/* text between images: the same space above and below it (the section's own top padding) */
.fp .split.sec-s + .fp-mediarow, .fp .p-info + .fp-mediarow { margin-top: var(--sec-pad, 100px); }
.fp .p-info { padding-bottom: 0; }

/* project text spacing: one even half-line between paragraphs and lists (no tall gaps), and
   back-to-back sections (e.g. Context / Approach / Impact) sit closer together than ones after images */
.proj .lead p + p, .proj .rich p + p, .proj .rich p + ul, .proj .rich ul + p, .proj .rich ul + ul { margin-top: 11px; }
.proj .rich ul { padding-left: 0; list-style: none; }
.proj .sec-s + .sec-s { padding-top: 48px; }

/* paragraphs inside a project text area are spaced by their own 11px margin, not the column's 60px
   stack gap (that made two paragraphs look like separate blocks) */
.proj .split-r.rich, .proj .split-r.lead { gap: 0; }

/* credits on project pages: the About page's Experience table, two columns (Role | Name) */
.ctable .th, .ctable .tr { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
.ctable .tr span:last-child, .ctable .th span:last-child { text-align: left; }
.ctable + p { margin-top: 24px; }
@media (max-width: 809.98px) { .ctable .tr { grid-template-columns: 1fr; gap: 4px; } .ctable .tr span:first-child { color: var(--mute); } }

/* About: floating analog clocks */
.aclock { position: fixed; left: 0; top: 0; z-index: 45; width: 140px; height: 140px; pointer-events: none; color: #e6e6e6; mix-blend-mode: difference; will-change: transform; }
.aclock svg { display: block; width: 100%; height: 100%; overflow: visible; fill: none; stroke: currentColor; stroke-width: 1.2; stroke-linecap: round; }
.aclock .h { stroke-width: 2.2; } .aclock .m { stroke-width: 1.6; } .aclock .s { stroke-width: .8; }
.aclock .c { fill: currentColor; stroke: none; }
.aclock text { fill: currentColor; stroke: none; font: 600 9px/1 var(--font); letter-spacing: .02em; text-anchor: middle; }
.aclock text.ap { font-size: 7px; font-weight: 500; }
.ahoop { position: fixed; left: 0; top: 30vh; z-index: 44; width: min(270px, 44vw); aspect-ratio: 270 / 340; pointer-events: none; color: #e6e6e6; mix-blend-mode: difference; }
.ahoop svg { display: block; width: 100%; height: 100%; overflow: visible; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }
.ahoop .board { stroke-width: 3; }
.ahoop .bracket { stroke-width: 1.6; }
.ahoop .rim { stroke-width: 3; }
.ahoop .net { stroke-width: .9; }
.ahoop .net.back { opacity: .45; }
.ahoop text { fill: currentColor; stroke: none; text-anchor: middle; font-family: var(--font); }
.ahoop .score { font-size: 34px; font-weight: 600; letter-spacing: -.02em; transform-box: fill-box; transform-origin: center; }
.ahoop .slabel { font-size: 10px; font-weight: 600; letter-spacing: .08em; }
.ahoop.hit .score { animation: ahoop-pop .6s cubic-bezier(.2, 1.6, .4, 1); }
@keyframes ahoop-pop { 30% { transform: scale(1.35); } }
@media (prefers-reduced-motion: reduce) { .ahoop { display: none; } }
/* light theme: difference flips the grey (white − colour), so a dark source reads as a light grey on white */
[data-theme="light"] .aclock, [data-theme="light"] .ahoop { color: #575757; }

/* ---------- phone home: copy in the upper half, a moving image strip below, location/time stacked ---------- */
.mstrip { display: none; }
@media (max-width: 809.98px) {
  .hero-c .hero-main { height: 52vh; height: 52svh; padding-top: 150px; }
  .mstrip { display: flex; align-items: center; justify-content: center; position: absolute; left: 0; right: 0; top: calc(52vh - 40px); top: calc(52svh - 40px); bottom: 124px; overflow: hidden; pointer-events: none; perspective: 900px; }
  .mcyl { position: relative; width: 0; transform-style: preserve-3d; animation: mcyl 6s linear infinite; will-change: transform; }
  .mcyl i { position: absolute; left: 0; top: 0; display: block; background-repeat: no-repeat; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
  .hero-c .hero-bottom { flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; text-align: center; }
  .hero-c .hero-bottom p { margin: 0; white-space: nowrap; }
}
@keyframes mcyl { from { transform: translateZ(calc(var(--r, 300px) * -1)) rotateY(0deg); } to { transform: translateZ(calc(var(--r, 300px) * -1)) rotateY(-360deg); } }
@media (prefers-reduced-motion: reduce) { .mcyl { animation: none; } }

/* ---------- About on phones: no clocks/hoop, testimonials stacked, company names bold ---------- */
@media (max-width: 809.98px) {
  .aclock, .ahoop { display: none; }
  .ticker.tmarq { margin-inline: 0; overflow: visible; }
  .tmarq .track { flex-direction: column; width: auto; padding-right: 0; transform: none !important; }
  .tmarq .tcopy { display: none; }
  .tmarq .tcard { width: 100%; gap: 28px; }
  .tmarq .tcard blockquote { order: -1; }   /* quote first, person underneath */
  .exp .tr span:first-child { font-weight: 600; }
}

/* ---------- Work on phones: no cursor button; title + tags sit under each thumbnail ---------- */
@media (max-width: 809.98px) {
  .works a.cell { aspect-ratio: auto; cursor: pointer; }
  .works .card-info { position: static; max-width: none; padding: 10px 0 22px; border-radius: 0; color: var(--fg); background: none; box-shadow: none;
    -webkit-backdrop-filter: none; backdrop-filter: none; opacity: 1; transform: none; }
  .works .see-cta { display: none !important; }
}

/* ---------- Fun on phones: one column; each image's details as text underneath (no hover pill) ---------- */
@media (max-width: 809.98px) {
  .g3-cap { position: static; max-width: none; padding: 9px 0 14px; border-radius: 0; color: var(--fg); background: none; box-shadow: none;
    -webkit-backdrop-filter: none; backdrop-filter: none; opacity: 1; transform: none; }
}
