/* Libish Murugesan · portfolio site
   Design system follows the print portfolio (deck/): Spectral / Archivo / JetBrains Mono,
   paper #F6F4EF, ink #16151C, indigo #34327A, dark plate #15142C, lavender #B8B2E0, terracotta #A8553B. */

:root {
  --paper: #F6F4EF;
  --paper-2: #F2EFE6;
  --frame: #ECE9E1;
  --ink: #16151C;
  --ink-deep: #16142E;
  --body: #56535E;
  --meta: #6B6774;
  --rule: #DEDAD0;
  --indigo: #34327A;
  --plate: #15142C;
  --plate-2: #23223F;
  --lavender: #B8B2E0;
  --lavender-bg: #BDB8E0;
  --terracotta: #A8553B;
  --on-dark: #E9E6F2;
  --on-dark-2: rgba(233, 230, 242, .72);
  --on-dark-rule: rgba(233, 230, 242, .16);

  --f-display: 'Spectral', Georgia, 'Times New Roman', serif;
  --f-body: 'Archivo', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;

  --gutter: clamp(18px, 5vw, 88px);
  --nav-h: 60px;
  --ease: cubic-bezier(.2, .7, .1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body.is-locked { overflow: hidden; }
img, video, canvas { display: block; max-width: 100%; }
img { -webkit-user-drag: none; user-select: none; -webkit-touch-callout: none; }
a { color: inherit; }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }
::selection { background: var(--lavender); color: var(--ink-deep); }
:focus-visible { outline: 2px solid var(--indigo); outline-offset: 3px; }
.dark :focus-visible, .case.is-dark :focus-visible, .lb :focus-visible { outline-color: var(--lavender); }

.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--ink); color: #fff; padding: 8px 14px; }
.skip:focus { left: 8px; }

/* ---------- type primitives ---------- */
.mono { font-family: var(--f-mono); }
.eyebrow {
  font-family: var(--f-mono); font-size: 12px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--meta);
}
.kicker { font-family: var(--f-mono); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--terracotta); }
.display { font-family: var(--f-display); font-weight: 300; letter-spacing: -.02em; line-height: 1.04; margin: 0; }
.h2 { font-family: var(--f-display); font-weight: 400; font-size: clamp(34px, 4.4vw, 60px); line-height: 1.04; letter-spacing: -.015em; margin: 0; }
.lead { font-family: var(--f-display); font-style: italic; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.45; color: #2A2840; }
.dark .lead { color: #D8D4EE; }
.muted { color: var(--body); }

.wrap { padding-inline: var(--gutter); }
.section { padding-block: clamp(64px, 9vw, 128px); position: relative; }
.section__bar {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  border-bottom: 1px solid var(--rule); padding-bottom: 15px; margin-bottom: clamp(28px, 4vw, 46px);
}
.dark .section__bar { border-color: var(--on-dark-rule); }
.section__head { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 64px); align-items: end; margin-bottom: clamp(28px, 4vw, 48px); }
.section__head p { margin: 0; max-width: 620px; }
@media (max-width: 860px) { .section__head { grid-template-columns: 1fr; } }

.dark { background: var(--plate); color: var(--on-dark); }
.dark .eyebrow { color: rgba(233, 230, 242, .55); }
.dark .kicker { color: var(--lavender); }
.dark .muted { color: var(--on-dark-2); }

/* ---------- buttons / chips ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  padding: 12px 18px; border: 1px solid var(--indigo); color: var(--indigo); background: transparent;
  text-decoration: none; cursor: pointer; transition: background .25s var(--ease), color .25s var(--ease), transform .25s var(--ease);
  border-radius: 2px;
}
.btn:hover { background: var(--indigo); color: #fff; }
.btn--solid { background: var(--indigo); color: #fff; }
.btn--solid:hover { background: var(--ink-deep); border-color: var(--ink-deep); }
.dark .btn, .case.is-dark .btn { border-color: var(--lavender); color: var(--lavender); }
.dark .btn:hover, .case.is-dark .btn:hover { background: var(--lavender); color: var(--ink-deep); }
.dark .btn--solid { background: var(--lavender); color: var(--ink-deep); }
.btn .arr { transition: transform .25s var(--ease); }
.btn:hover .arr { transform: translate(2px, -2px); }

.chip {
  font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em;
  color: var(--meta); border: 1px solid var(--rule); padding: 5px 11px; border-radius: 3px; white-space: nowrap;
}
.dark .chip, .case.is-dark .chip { color: #8682A6; border-color: var(--on-dark-rule); }
.pill {
  font-family: var(--f-mono); font-size: 12px; letter-spacing: .04em;
  border: 1px solid currentColor; border-radius: 999px; padding: 7px 15px; opacity: .85;
}

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  padding-top: env(safe-area-inset-top, 0px);
  background: rgba(246, 244, 239, .95); backdrop-filter: saturate(1.2) blur(12px); -webkit-backdrop-filter: saturate(1.2) blur(12px);
  border-bottom: 1px solid transparent; transition: border-color .3s, background .3s;
}
.nav.is-scrolled { border-bottom-color: var(--rule); }
.nav__in { height: var(--nav-h); display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-inline: var(--gutter); }
.nav__brand { font-family: var(--f-mono); font-size: 12.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--indigo); text-decoration: none; white-space: nowrap; }
.nav__brand b { font-weight: 600; }
.nav__links { display: flex; align-items: center; gap: clamp(12px, 2vw, 28px); }
.nav__links a { white-space: nowrap; font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--body); text-decoration: none; position: relative; padding: 6px 0; }
.nav__links a::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--indigo); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.nav__links a:hover, .nav__links a.is-active { color: var(--indigo); }
.nav__links a:hover::after, .nav__links a.is-active::after { transform: scaleX(1); }
.nav__links .btn { padding: 8px 12px; font-size: 11px; }
.nav__links .btn::after { display: none; }
.nav__links .btn:hover { color: #fff; }
.nav__toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav__toggle span { display: block; width: 22px; height: 1.5px; background: var(--ink); margin: 5px 0; transition: transform .3s; }
.nav__progress { position: absolute; left: 0; bottom: -1px; height: 2px; background: var(--indigo); width: 0; }
@media (max-width: 1100px) {
  .nav__toggle { display: block; }
  .nav__links { position: fixed; inset: calc(var(--nav-h) + env(safe-area-inset-top, 0px)) 0 auto 0; flex-direction: column; align-items: flex-start; gap: 4px; padding: 18px var(--gutter) 26px; background: var(--paper); border-bottom: 1px solid var(--rule); transform: translateY(-120%); transition: transform .35s var(--ease); z-index: -1; }
  .nav__links { visibility: hidden; transition: transform .35s var(--ease), visibility 0s .35s; }
  .nav.is-open .nav__links { transform: none; visibility: visible; transition: transform .35s var(--ease); }
  .nav.is-open .nav__toggle span:first-child { transform: translateY(3.25px) rotate(45deg); }
  .nav.is-open .nav__toggle span:last-child { transform: translateY(-3.25px) rotate(-45deg); }
  .nav__links a { font-size: 13px; padding: 10px 0; }
}

/* ---------- hero ---------- */
.hero { min-height: 100svh; display: grid; grid-template-columns: 53% 47%; padding-top: calc(var(--nav-h) + env(safe-area-inset-top, 0px)); }
.hero__paper { background: var(--paper-2); padding: clamp(28px, 4.5vh, 64px) clamp(22px, 4.5vw, 56px) clamp(28px, 4.5vh, 56px) var(--gutter); display: flex; flex-direction: column; justify-content: space-between; gap: clamp(22px, 3.5vh, 40px); }
.hero__top { display: flex; justify-content: space-between; gap: 12px; }
.hero__top span:first-child { color: var(--indigo); }
.hero h1 { font-size: clamp(46px, min(6.4vw, 10.5vh), 100px); color: var(--ink-deep); }
.hero h1 em { font-style: italic; font-weight: 400; }
.hero__kicker { margin-bottom: clamp(12px, 2.4vh, 24px); }
.hero__rule { width: 54px; height: 2px; background: var(--indigo); margin-bottom: 20px; }
.hero__tag { font-size: clamp(15.5px, 1.25vw, 18px); color: #3A3850; max-width: 540px; margin: 0; }
.hero__contact a { text-decoration: none; border-bottom: 1px solid var(--rule); }
.hero__contact a:hover { color: var(--indigo); border-color: var(--indigo); }
.hero__contact { margin-top: clamp(12px, 2vh, 20px); font-family: var(--f-mono); font-size: 12px; letter-spacing: .1em; color: var(--body); line-height: 1.9; }
.hero__cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: clamp(16px, 3vh, 28px); }
.hero__stage { position: relative; background: var(--lavender-bg); overflow: hidden; min-height: 420px; touch-action: pan-y; }
.hero__stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; }
.hero__stage canvas:active { cursor: grabbing; }
.hero__fallback { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 30% 50%; }
.hero__stage.has-3d .hero__fallback { opacity: 0; transition: opacity .8s; }
.hero__hint { position: absolute; left: 18px; bottom: 16px; right: 18px; display: flex; justify-content: space-between; gap: 12px; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: rgba(22, 20, 46, .78); pointer-events: none; }
.hero__legend { position: absolute; top: 18px; right: 18px; background: rgba(189, 184, 224, .72); padding: 4px 8px; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .1em; color: rgba(22, 20, 46, .78); text-align: right; pointer-events: none; line-height: 1.7; }
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero__stage { height: 64vh; min-height: 360px; }
}

/* ---------- ticker ---------- */
.ticker { background: var(--ink-deep); color: var(--lavender); overflow: hidden; border-block: 1px solid #000; }
.ticker__track { display: flex; width: max-content; animation: tick 48s linear infinite; }
.ticker__track span { font-family: var(--f-mono); font-size: 12px; letter-spacing: .16em; text-transform: uppercase; padding: 14px 22px; white-space: nowrap; }
.ticker__track span::after { content: '·'; margin-left: 44px; color: rgba(184, 178, 224, .45); }
@keyframes tick { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker__track { animation: none; } }

/* ---------- profile ---------- */
.profile__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(32px, 6vw, 72px); }
.profile h2 { font-family: var(--f-display); font-weight: 400; font-size: clamp(28px, 3vw, 38px); line-height: 1.18; letter-spacing: -.01em; margin: 0 0 22px; }
.profile p { color: var(--body); margin: 0 0 16px; font-size: 16px; }
.facts { margin-top: 30px; border-top: 1px solid var(--rule); padding-top: 22px; display: grid; grid-template-columns: 1fr 1fr; gap: 18px 24px; }
.facts dt { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--meta); margin-bottom: 6px; }
.facts dd { margin: 0; font-size: 14.5px; line-height: 1.45; }
.contents { border-left: 1px solid var(--rule); padding-left: clamp(0px, 4vw, 46px); }
.contents a { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; align-items: baseline; gap: 16px; padding: 14px 0; border-bottom: 1px solid #E8E4DB; text-decoration: none; transition: padding .3s var(--ease), background .3s; }
.contents a:hover { padding-left: 10px; background: linear-gradient(90deg, rgba(184, 178, 224, .22), transparent); }
.contents .t { font-family: var(--f-display); font-size: clamp(19px, 1.8vw, 23px); line-height: 1.2; }
.contents .t small { display: block; font-family: var(--f-body); font-size: 13px; color: var(--meta); margin-top: 3px; }
.contents .n { font-family: var(--f-mono); font-size: 12px; color: var(--body); }
.contents .l { font-family: var(--f-mono); font-size: 12px; color: var(--indigo); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: clamp(40px, 6vw, 72px); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.stat { padding: 22px 18px 20px 0; }
.stat + .stat { border-left: 1px solid var(--rule); padding-left: 22px; }
.stat b { display: block; font-family: var(--f-display); font-weight: 300; font-size: clamp(36px, 4.2vw, 58px); line-height: 1; letter-spacing: -.02em; color: var(--indigo); }
.stat span { display: block; margin-top: 8px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; color: var(--meta); }
@media (max-width: 860px) {
  .profile__grid { grid-template-columns: 1fr; }
  .contents { border-left: 0; padding-left: 0; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--rule); }
}

/* ---------- feature (Kuppam) ---------- */
.feature { background: var(--plate); color: var(--on-dark); overflow: hidden; }
.feature__grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.feature__new { display: inline-flex; align-items: center; gap: 10px; }
.feature__new i { width: 8px; height: 8px; border-radius: 50%; background: #E0775A; box-shadow: 0 0 0 0 rgba(224, 119, 90, .6); animation: pulse 2.2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(224, 119, 90, 0); } 100% { box-shadow: 0 0 0 0 rgba(224, 119, 90, 0); } }
.feature h2 { margin: 14px 0 10px; }
.feature .sub { font-size: clamp(16px, 1.4vw, 19px); color: #B7B2D6; margin: 0 0 20px; }
.feature .body { color: #AFAAC8; font-size: 15px; }
.feature .body p, .case__text .body p { margin: 0 0 12px; }
.film { position: relative; background: #000; border: 1px solid var(--on-dark-rule); aspect-ratio: 4 / 5; max-height: 82vh; margin-inline: auto; width: 100%; }
.film video, .film iframe { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border: 0; }
.film__tabs { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.film__tabs button { background: none; border: 1px solid var(--on-dark-rule); color: var(--on-dark-2); font-family: var(--f-mono); font-size: 11px; letter-spacing: .08em; padding: 7px 12px; cursor: pointer; border-radius: 2px; }
.film__tabs button[aria-pressed="true"] { border-color: var(--lavender); color: var(--lavender); }
.film__cap { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .04em; color: #8682A6; margin-top: 10px; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; background: rgba(255, 255, 255, .04); border: 1px solid var(--on-dark-rule); padding: 18px 22px; margin: 22px 0; }
.metrics b { display: block; font-family: var(--f-display); font-weight: 300; font-size: clamp(24px, 2.4vw, 32px); line-height: 1; color: #fff; }
.metrics span { display: block; margin-top: 6px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .03em; color: rgba(238, 235, 246, .6); }
.case:not(.is-dark) .metrics { background: var(--plate); }
@media (max-width: 560px) { .metrics { grid-template-columns: 1fr 1fr; } }
.contrib { list-style: none; padding: 0; margin: 0 0 20px; }
.contrib li { display: flex; gap: 11px; align-items: baseline; font-size: 14px; line-height: 1.5; margin-bottom: 8px; color: var(--body); }
.dark .contrib li, .case.is-dark .contrib li { color: #AFAAC8; }
.contrib li::before { content: ''; width: 5px; height: 5px; border-radius: 1px; background: var(--indigo); flex: none; transform: translateY(-2px); }
.dark .contrib li::before, .case.is-dark .contrib li::before { background: var(--lavender); }
.links { display: flex; gap: 10px; flex-wrap: wrap; }
.strip { display: grid; grid-auto-flow: column; grid-auto-columns: clamp(220px, 24vw, 340px); gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 10px; margin-top: clamp(28px, 4vw, 44px); scrollbar-width: thin; }
.strip button { scroll-snap-align: start; }
.live { margin-top: clamp(28px, 4vw, 44px); border: 1px solid var(--on-dark-rule); position: relative; aspect-ratio: 16 / 9; background: radial-gradient(ellipse at 50% 60%, #2b2a52, #0f0e22); overflow: hidden; }
.live iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #fff; }
.live__facade { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; text-align: center; padding: 20px; }
.live__facade img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .38; filter: saturate(.8); }
.live__facade > *:not(img) { position: relative; }
.live__bar { position: absolute; left: 0; right: 0; top: 0; display: flex; justify-content: space-between; align-items: center; padding: 8px 10px; background: rgba(15, 14, 34, .82); font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; z-index: 2; }
.live__bar a { color: var(--lavender); }
@media (max-width: 900px) { .feature__grid { grid-template-columns: 1fr; } .film { max-width: 520px; } .live { aspect-ratio: 3 / 4; } }

/* ---------- media tile (shared) ---------- */
.tile { position: relative; display: block; width: 100%; padding: 0; border: 1px solid var(--rule); background: var(--frame); overflow: hidden; cursor: zoom-in; }
.dark .tile, .case.is-dark .tile { border-color: var(--on-dark-rule); background: var(--plate-2); }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease), opacity .5s; }
.tile:hover img { transform: scale(1.035); }
.tile--contain img { object-fit: contain; }
.tile__label { position: absolute; left: 9px; top: 9px; font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .12em; text-transform: uppercase; color: #fff; background: rgba(10, 9, 24, .62); padding: 3px 7px; pointer-events: none; }
.tile__cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 10px 9px; font-size: 12px; line-height: 1.35; color: #fff; text-align: left; background: linear-gradient(transparent, rgba(10, 9, 24, .78)); opacity: 0; transform: translateY(6px); transition: opacity .35s, transform .35s var(--ease); pointer-events: none; }
.tile:hover .tile__cap, .tile:focus-visible .tile__cap { opacity: 1; transform: none; }
@media (hover: none) { .tile__cap { opacity: 1; transform: none; } }
.strip .tile { aspect-ratio: 4 / 3; }

/* ---------- work index ---------- */
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.filters button { background: transparent; border: 1px solid var(--rule); color: var(--body); font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .06em; padding: 8px 14px; border-radius: 999px; cursor: pointer; transition: all .25s var(--ease); }
.filters button:hover { border-color: var(--indigo); color: var(--indigo); }
.filters button[aria-pressed="true"] { background: var(--indigo); border-color: var(--indigo); color: #fff; }
.filters button i { font-style: normal; opacity: .6; margin-left: 6px; }
.view-toggle { margin-left: auto; display: flex; gap: 4px; }
.view-toggle button { border-radius: 2px; padding: 8px 10px; }
.work-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 2.4vw, 34px) clamp(16px, 2vw, 26px); margin-top: clamp(24px, 3vw, 36px); }
@media (max-width: 1100px) { .work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .work-grid { grid-template-columns: 1fr; } }
.card { display: flex; flex-direction: column; text-align: left; background: none; border: 0; padding: 0; cursor: pointer; color: inherit; transition: opacity .4s, transform .4s var(--ease); }
.card.is-hidden { display: none; }
.card__media { position: relative; aspect-ratio: 4 / 3; border: 1px solid var(--rule); background: var(--frame); overflow: hidden; }
.card__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .6s var(--ease), transform 1.2s var(--ease); }
.card__media img + img { opacity: 0; }
.card:hover .card__media img.is-on { transform: scale(1.04); }
.card__media img.is-on { opacity: 1; }
.card__media img.is-off { opacity: 0; }
.card__no { position: absolute; left: 10px; top: 10px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .12em; color: #fff; background: rgba(10, 9, 24, .62); padding: 3px 7px; }
.card__badges { position: absolute; right: 10px; top: 10px; display: flex; gap: 6px; }
.card__badges span { font-family: var(--f-mono); font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-deep); background: rgba(246, 244, 239, .9); padding: 3px 7px; }
.card__badges span.new { background: #E0775A; color: #fff; }
.card__dots { position: absolute; left: 10px; right: 10px; bottom: 10px; display: flex; gap: 4px; opacity: 0; transition: opacity .3s; }
.card:hover .card__dots, .card:focus-visible .card__dots { opacity: 1; }
.card__dots i { flex: 1; height: 2px; background: rgba(255, 255, 255, .45); }
.card__dots i.is-on { background: #fff; }
.card__meta { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; }
.card__meta .kicker { font-size: 11px; }
.card__meta .yr { font-family: var(--f-mono); font-size: 11px; color: var(--meta); }
.card__title { font-family: var(--f-display); font-size: clamp(22px, 2vw, 27px); line-height: 1.1; letter-spacing: -.01em; margin: 7px 0 5px; transition: color .25s; }
.card:hover .card__title { color: var(--indigo); }
.card__sub { font-size: 14px; color: var(--body); line-height: 1.4; }
.card__tags { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; font-family: var(--f-mono); font-size: 10.5px; color: var(--meta); }
/* list view */
.work-grid.is-list { grid-template-columns: 1fr; gap: 0; border-top: 1px solid var(--rule); }
.work-grid.is-list .card { display: grid; grid-template-columns: 70px minmax(0, 1.4fr) minmax(0, 1fr) 90px 120px; align-items: center; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--rule); }
.work-grid.is-list .card__media { display: none; }
.work-grid.is-list .card__meta { display: contents; }
.work-grid.is-list .card__meta .kicker { order: 4; }
.work-grid.is-list .card__meta .yr { order: 5; text-align: right; }
.work-grid.is-list .card__title { margin: 0; order: 2; font-size: 22px; }
.work-grid.is-list .card__sub { order: 3; font-size: 13px; }
.work-grid.is-list .card__tags { display: none; }
.work-grid.is-list .card::before { content: attr(data-no); font-family: var(--f-mono); font-size: 12px; color: var(--indigo); order: 1; }
@media (max-width: 760px) { .work-grid.is-list .card { grid-template-columns: 50px minmax(0, 1fr) 60px; } .work-grid.is-list .card__sub, .work-grid.is-list .card__meta .kicker { display: none; } }
.peek { position: fixed; z-index: 40; width: 300px; aspect-ratio: 4 / 3; pointer-events: none; border: 1px solid var(--rule); background: var(--frame); opacity: 0; transform: scale(.92); transition: opacity .25s, transform .25s var(--ease); box-shadow: 0 20px 50px rgba(22, 21, 28, .25); }
.peek.is-on { opacity: 1; transform: none; }
.peek img { width: 100%; height: 100%; object-fit: cover; }

/* section dividers inside work */
.divider { grid-column: 1 / -1; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(18px, 3vw, 40px); align-items: end; color: var(--on-dark); padding: clamp(28px, 4vw, 48px); margin-top: 10px; position: relative; overflow: hidden; }
.divider__letter { font-family: var(--f-display); font-weight: 300; font-size: clamp(90px, 12vw, 160px); line-height: .8; color: rgba(242, 239, 230, .16); }
.divider h3 { font-family: var(--f-display); font-weight: 400; font-size: clamp(26px, 3.2vw, 44px); line-height: 1.05; margin: 8px 0 12px; letter-spacing: -.01em; }
.divider p { margin: 0; color: rgba(242, 239, 230, .78); max-width: 680px; font-size: 15px; }
.divider .eyebrow { color: rgba(242, 239, 230, .55); }
.work-grid.is-list .divider { margin: 26px 0 0; padding: 22px 24px; }
.work-grid.is-list .divider__letter { font-size: 64px; }
.work-grid.is-list .divider p { display: none; }

/* ---------- 3D lab ---------- */
.lab__grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, .8fr); gap: clamp(20px, 3vw, 40px); align-items: stretch; }
.lab__stage { position: relative; aspect-ratio: 4 / 3; min-height: 360px; background: radial-gradient(ellipse at 50% 38%, #3a3872 0%, #1d1c3c 55%, #121127 100%); border: 1px solid var(--on-dark-rule); overflow: hidden; }
.lab__stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: grab; }
.lab__stage canvas:active { cursor: grabbing; }
.lab__loading { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--on-dark-2); pointer-events: none; }
.lab__bar { width: 160px; height: 2px; background: rgba(255, 255, 255, .12); overflow: hidden; }
.lab__bar i { display: block; height: 100%; width: 0; background: var(--lavender); transition: width .2s; }
.lab__hud { position: absolute; left: 12px; top: 12px; right: 12px; display: flex; justify-content: space-between; gap: 10px; pointer-events: none; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .08em; color: rgba(233, 230, 242, .7); }
.lab__tip { position: absolute; pointer-events: none; font-family: var(--f-mono); font-size: 10.5px; color: var(--ink-deep); background: var(--lavender); padding: 3px 7px; transform: translate(12px, -50%); white-space: nowrap; opacity: 0; transition: opacity .15s; }
.lab__tip.is-on { opacity: 1; }
.lab__tools { position: absolute; right: 12px; bottom: 12px; display: flex; gap: 6px; }
.lab__tools button, .lab__panel button.tab { background: rgba(15, 14, 34, .7); border: 1px solid var(--on-dark-rule); color: var(--on-dark); font-family: var(--f-mono); font-size: 11px; letter-spacing: .06em; padding: 8px 11px; cursor: pointer; border-radius: 2px; backdrop-filter: blur(6px); }
.lab__tools button[aria-pressed="true"] { border-color: var(--lavender); color: var(--lavender); }
.lab__panel { display: flex; flex-direction: column; gap: 18px; }
.lab__tabs { display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--on-dark-rule); }
.lab__tabs button { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 12px; align-items: center; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--on-dark-rule); padding: 14px 4px; cursor: pointer; color: var(--on-dark-2); transition: color .2s, padding .3s var(--ease); }
.lab__tabs button:hover { color: #fff; padding-left: 10px; }
.lab__tabs button[aria-pressed="true"] { color: #fff; }
.lab__tabs button[aria-pressed="true"] .n { color: var(--lavender); }
.lab__tabs .n { font-family: var(--f-mono); font-size: 11px; color: #8682A6; }
.lab__tabs .t { font-family: var(--f-display); font-size: 20px; line-height: 1.15; }
.lab__tabs .s { font-family: var(--f-mono); font-size: 10px; color: #8682A6; }
.lab__desc { font-size: 14px; color: var(--on-dark-2); margin: 0; min-height: 3em; }
.slider { display: grid; gap: 8px; }
.slider label { display: flex; justify-content: space-between; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: rgba(233, 230, 242, .6); }
input[type="range"] { -webkit-appearance: none; appearance: none; width: 100%; height: 22px; background: transparent; cursor: pointer; }
input[type="range"]::-webkit-slider-runnable-track { height: 2px; background: rgba(233, 230, 242, .25); }
input[type="range"]::-moz-range-track { height: 2px; background: rgba(233, 230, 242, .25); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--lavender); margin-top: -7px; border: 0; }
input[type="range"]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--lavender); border: 0; }
@media (max-width: 900px) { .lab__grid { grid-template-columns: 1fr; } .lab__stage { aspect-ratio: 1 / 1; } }

/* ---------- masonry gallery ---------- */
.masonry { columns: 3 300px; column-gap: 14px; }
.masonry .tile { break-inside: avoid; margin-bottom: 14px; }
.masonry .tile img { height: auto; }
.masonry figure { margin: 0; }

/* ---------- studio ---------- */
.studio-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px 20px; }
@media (max-width: 1000px) { .studio-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .studio-grid { grid-template-columns: 1fr; } }
.scard { text-align: left; background: none; border: 0; padding: 0; cursor: zoom-in; color: inherit; }
.scard .tile { aspect-ratio: 1 / 1; pointer-events: none; }
.scard:hover .tile img { transform: scale(1.04); }
.scard h3 { font-family: var(--f-display); font-weight: 400; font-size: 19px; margin: 10px 0 2px; line-height: 1.15; }
.scard p { margin: 0; font-size: 12.5px; color: var(--body); line-height: 1.35; }
.scard .count { font-family: var(--f-mono); font-size: 10px; color: var(--meta); margin-top: 6px; display: block; }

/* ---------- publications ---------- */
.pubs { border-top: 1px solid var(--rule); }
.pub { display: grid; grid-template-columns: 70px minmax(0, 1fr) minmax(160px, auto); gap: 18px 24px; padding: 20px 0; border-bottom: 1px solid var(--rule); align-items: start; }
.pub__yr { font-family: var(--f-display); font-weight: 300; font-size: 30px; line-height: 1; color: var(--indigo); }
.pub__type { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--terracotta); margin-bottom: 6px; }
.pub h3 { font-family: var(--f-display); font-weight: 400; font-size: clamp(18px, 1.7vw, 22px); line-height: 1.25; margin: 0 0 4px; }
.pub h3 a { text-decoration: none; background: linear-gradient(var(--indigo), var(--indigo)) 0 100% / 0 1px no-repeat; transition: background-size .35s var(--ease); }
.pub h3 a:hover { background-size: 100% 1px; color: var(--indigo); }
.pub__au { font-size: 13px; color: var(--meta); }
.pub p { margin: 6px 0 0; font-size: 14px; color: var(--body); line-height: 1.5; }
.pub__links { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.pub__links a, .pub__links button { font-size: 11px; color: var(--indigo); text-decoration: none; background: none; border: 0; padding: 0; cursor: pointer; text-align: right; overflow-wrap: anywhere; }
.pub__links a:hover, .pub__links button:hover { text-decoration: underline; }
@media (max-width: 700px) { .pub { grid-template-columns: 54px minmax(0, 1fr); } .pub__links { grid-column: 2; align-items: flex-start; } .pub__links a, .pub__links button { text-align: left; } }

/* ---------- archive ---------- */
.archive { background: var(--paper-2); }
.plates { display: grid; grid-auto-flow: column; grid-auto-columns: clamp(220px, 26vw, 360px); gap: 16px; overflow-x: auto; scroll-snap-type: x proximity; padding-bottom: 14px; scrollbar-width: thin; }
.plates button { scroll-snap-align: start; background: #fff; border: 1px solid var(--rule); padding: 0; cursor: zoom-in; position: relative; aspect-ratio: 2990 / 2115; box-shadow: 0 8px 26px rgba(22, 21, 28, .08); transition: transform .4s var(--ease), box-shadow .4s; }
.plates button:hover { transform: translateY(-4px); box-shadow: 0 16px 36px rgba(22, 21, 28, .16); }
.plates img { width: 100%; height: 100%; object-fit: cover; }
.plates span { position: absolute; left: 8px; bottom: 8px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .1em; background: rgba(22, 21, 28, .75); color: #fff; padding: 2px 6px; }
.scrollnav { display: flex; gap: 6px; }
.scrollnav button { width: 40px; height: 40px; border: 1px solid var(--rule); background: transparent; cursor: pointer; font-size: 18px; border-radius: 50%; }
.scrollnav button:hover { border-color: var(--indigo); color: var(--indigo); }

/* ---------- colophon ---------- */
.colophon { background: var(--ink-deep); }
.colophon__grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 60px); }
.repos a { display: grid; grid-template-columns: minmax(150px, 250px) minmax(0, 1fr) 18px; gap: 14px; align-items: baseline; padding: 11px 0; border-bottom: 1px solid rgba(233, 230, 242, .12); text-decoration: none; transition: padding .3s var(--ease); }
.repos a:hover { padding-left: 8px; }
.repos a:hover .arr { color: var(--lavender); transform: translate(2px, -2px); }
.repos .nm { font-family: var(--f-mono); font-size: 13px; color: #fff; overflow-wrap: anywhere; }
.repos .ds { font-size: 13px; color: rgba(233, 230, 242, .72); line-height: 1.35; }
.repos .arr { color: rgba(233, 230, 242, .4); transition: transform .25s, color .25s; }
.thanks { border-left: 1px solid rgba(233, 230, 242, .18); padding-left: clamp(0px, 4vw, 54px); display: flex; flex-direction: column; justify-content: space-between; gap: 40px; }
.thanks h2 { font-family: var(--f-display); font-weight: 300; font-size: clamp(44px, 5vw, 64px); line-height: 1.02; letter-spacing: -.02em; margin: 0 0 20px; }
.thanks p { color: rgba(233, 230, 242, .78); margin: 0; }
.sign { font-family: var(--f-mono); font-size: 12.5px; letter-spacing: .06em; color: rgba(233, 230, 242, .7); line-height: 2; }
.sign a { color: var(--lavender); text-decoration: none; }
.social { display: flex; gap: 10px; margin-top: 18px; }
.social a { width: 42px; height: 42px; display: grid; place-items: center; border: 1px solid rgba(233, 230, 242, .22); border-radius: 50%; color: var(--on-dark); transition: all .25s var(--ease); }
.social a:hover { background: var(--lavender); color: var(--ink-deep); border-color: var(--lavender); transform: translateY(-2px); }
.social svg { width: 18px; height: 18px; }
.foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: clamp(48px, 7vw, 90px); padding-top: 18px; border-top: 1px solid rgba(233, 230, 242, .12); font-family: var(--f-mono); font-size: 11px; letter-spacing: .08em; color: rgba(233, 230, 242, .62); padding-bottom: env(safe-area-inset-bottom, 0px); }
.foot a { color: rgba(233, 230, 242, .7); }
@media (max-width: 860px) { .colophon__grid { grid-template-columns: 1fr; } .thanks { border-left: 0; padding-left: 0; } .repos a { grid-template-columns: 1fr 18px; } .repos .ds { grid-column: 1; } }

/* ---------- case study overlay ---------- */
.case { position: fixed; inset: 0; z-index: 60; background: var(--paper); color: var(--ink); overflow-y: auto; overscroll-behavior: contain; opacity: 0; transform: translateY(24px); transition: opacity .4s var(--ease), transform .45s var(--ease); }
.case.is-open { opacity: 1; transform: none; }
.case.is-dark { background: var(--plate); color: var(--on-dark); }
.case__bar { position: sticky; top: 0; z-index: 3; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: calc(12px + env(safe-area-inset-top, 0px)) var(--gutter) 12px; background: inherit; border-bottom: 1px solid var(--rule); font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--meta); }
.case.is-dark .case__bar { border-color: var(--on-dark-rule); color: #8682A6; }
.case__nav { display: flex; gap: 6px; align-items: center; }
.case__nav button { background: none; border: 1px solid var(--rule); width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 17px; line-height: 1; transition: all .2s; }
.case.is-dark .case__nav button { border-color: var(--on-dark-rule); }
.case__nav button:hover { border-color: currentColor; }
.case__body { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(28px, 5vw, 64px); padding: clamp(28px, 4vw, 48px) var(--gutter) clamp(32px, 4vw, 48px); }
.case__text { position: sticky; top: 90px; align-self: start; }
.case__text h2 { font-family: var(--f-display); font-weight: 400; font-size: clamp(38px, 4.6vw, 64px); line-height: 1; letter-spacing: -.015em; margin: 14px 0 10px; }
.case__text .sub { font-size: clamp(16px, 1.3vw, 18px); color: var(--body); margin: 0 0 18px; line-height: 1.4; }
.case.is-dark .case__text .sub { color: #B7B2D6; }
.case__text .chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }
.case__text .lead { margin: 0 0 14px; }
.case.is-dark .case__text .lead { color: #D8D4EE; }
.case__text .body { font-size: 15px; color: var(--body); margin: 0 0 22px; }
.case.is-dark .case__text .body { color: #AFAAC8; }
.case__text h4 { font-family: var(--f-mono); font-size: 10.5px; font-weight: 400; letter-spacing: .16em; text-transform: uppercase; color: var(--meta); margin: 0 0 11px; }
.case__tags { display: flex; gap: 12px; flex-wrap: wrap; font-family: var(--f-mono); font-size: 10.5px; color: var(--meta); margin: 16px 0 22px; }
.case__note { font-size: 12.5px; color: var(--meta); border-left: 2px solid var(--terracotta); padding-left: 12px; margin: 0 0 20px; }
.case__media { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.case__media .hero-img { aspect-ratio: auto; }
.case__media .hero-img img { height: auto; max-height: 78vh; object-fit: contain; background: var(--frame); }
.case.is-dark .case__media .hero-img img { background: var(--plate-2); }
.case__cap { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .04em; color: var(--meta); margin-top: -4px; }
.case__gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.case__gallery .tile { aspect-ratio: 4 / 3; }
.case__gallery .tile.is-wide { grid-column: span 2; aspect-ratio: 16 / 7; }
.case__section-label { font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--meta); margin-top: 10px; }
.case__end { padding: 0 var(--gutter) calc(clamp(60px, 8vw, 110px) + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 18px; }
.case__foot { display: flex; justify-content: space-between; gap: 16px; border-top: 1px solid var(--rule); padding-top: 20px; }
.case.is-dark .case__foot { border-color: var(--on-dark-rule); }
.case__foot button { background: none; border: 0; cursor: pointer; text-align: left; padding: 6px 0; }
.case__foot button:last-child { text-align: right; }
.case__foot small { display: block; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--meta); }
.case__foot span { font-family: var(--f-display); font-size: clamp(20px, 2vw, 26px); }
@media (max-width: 900px) { .case__body { grid-template-columns: 1fr; } .case__text { position: static; } }

/* pipeline stepper */
.stepper { border: 1px solid var(--rule); background: var(--frame); }
.case.is-dark .stepper { border-color: var(--on-dark-rule); background: var(--plate-2); }
.stepper__view { position: relative; aspect-ratio: 16 / 10; overflow: hidden; }
.stepper__view img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: 0; transition: opacity .5s var(--ease); }
.stepper__view img.is-on { opacity: 1; }
.stepper__steps { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; border-top: 1px solid var(--rule); }
.case.is-dark .stepper__steps { border-color: var(--on-dark-rule); }
.stepper__steps button { background: none; border: 0; border-right: 1px solid var(--rule); padding: 10px 8px 12px; text-align: left; cursor: pointer; position: relative; }
.case.is-dark .stepper__steps button { border-color: var(--on-dark-rule); }
.stepper__steps button:last-child { border-right: 0; }
.stepper__steps button::before { content: ''; position: absolute; left: 0; top: -1px; height: 2px; width: 0; background: var(--indigo); transition: width .4s var(--ease); }
.case.is-dark .stepper__steps button::before { background: var(--lavender); }
.stepper__steps button[aria-selected="true"]::before { width: 100%; }
.stepper__steps b { display: block; font-family: var(--f-mono); font-size: 10px; font-weight: 400; color: var(--meta); }
.stepper__steps span { font-size: 12.5px; line-height: 1.3; display: block; margin-top: 3px; }

/* compare slider */
.compare { position: relative; aspect-ratio: 4 / 3; overflow: hidden; border: 1px solid var(--rule); background: var(--frame); user-select: none; touch-action: pan-y; --pos: 50%; }
.case.is-dark .compare { border-color: var(--on-dark-rule); background: var(--plate-2); }
.compare img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.compare .b { clip-path: inset(0 0 0 var(--pos)); }
.compare__handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; background: #fff; transform: translateX(-1px); pointer-events: none; box-shadow: 0 0 0 1px rgba(0, 0, 0, .15); }
.compare__handle::after { content: '⟷'; position: absolute; top: 50%; left: 50%; width: 38px; height: 38px; transform: translate(-50%, -50%); background: #fff; color: var(--ink); border-radius: 50%; display: grid; place-items: center; font-size: 16px; box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
.compare input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; margin: 0; }
.compare .tile__label.r { left: auto; right: 9px; }

/* ---------- lightbox ---------- */
.lb { position: fixed; inset: 0; z-index: 80; background: rgba(12, 11, 26, .96); color: var(--on-dark); display: grid; grid-template-rows: auto minmax(0, 1fr) auto; opacity: 0; transition: opacity .3s; }
.lb.is-open { opacity: 1; }
.lb__top { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: calc(12px + env(safe-area-inset-top, 0px)) 18px 12px; font-family: var(--f-mono); font-size: 11.5px; letter-spacing: .12em; color: rgba(233, 230, 242, .65); }
.lb__stage { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; padding: 0 64px; touch-action: none; }
.lb__stage img { max-width: 100%; max-height: 100%; object-fit: contain; transition: transform .35s var(--ease), opacity .25s; cursor: zoom-in; transform-origin: center; }
.lb__stage.is-zoom img { cursor: zoom-out; }
.lb__cap { padding: 12px 18px calc(16px + env(safe-area-inset-bottom, 0px)); text-align: center; font-size: 14px; color: var(--on-dark-2); min-height: 48px; }
.lb__cap b { font-family: var(--f-display); font-weight: 400; font-size: 18px; color: #fff; margin-right: 10px; }
.lb button.icon { background: rgba(255, 255, 255, .06); border: 1px solid rgba(233, 230, 242, .2); color: #fff; width: 44px; height: 44px; border-radius: 50%; cursor: pointer; font-size: 20px; line-height: 1; transition: background .2s; }
.lb button.icon:hover { background: rgba(255, 255, 255, .16); }
.lb__prev, .lb__next { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; }
.lb__prev { left: 12px; } .lb__next { right: 12px; }
.lb__thumbs { display: flex; gap: 6px; justify-content: center; padding: 0 18px 10px; overflow-x: auto; }
.lb__thumbs button { flex: none; width: 54px; height: 40px; padding: 0; border: 1px solid transparent; opacity: .5; cursor: pointer; background: #000; }
.lb__thumbs button[aria-current="true"] { opacity: 1; border-color: var(--lavender); }
.lb__thumbs img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 600px) { .lb__stage { padding: 0 8px; } .lb__prev, .lb__next { top: auto; bottom: 8px; transform: none; } }

/* ---------- reveal ---------- */
.rv { opacity: 0; transform: translateY(22px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .rv { opacity: 1; transform: none; transition: none; } }

/* ---------- misc ---------- */
.deckcta { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: center; border: 1px solid var(--rule); padding: clamp(20px, 3vw, 32px); background: var(--paper-2); margin-top: clamp(40px, 6vw, 72px); }
.deckcta h3 { font-family: var(--f-display); font-weight: 400; font-size: clamp(22px, 2.4vw, 30px); margin: 6px 0 6px; }
.deckcta p { margin: 0; color: var(--body); font-size: 14.5px; }
.deckcta .links { justify-content: flex-end; }
@media (max-width: 760px) { .deckcta { grid-template-columns: 1fr; } .deckcta .links { justify-content: flex-start; } }
.noscript { padding: 16px var(--gutter); background: var(--terracotta); color: #fff; }

/* static render for screenshots (?still) */
.is-still .rv { opacity: 1; transform: none; transition: none; }
.is-still .hero { min-height: 860px; }
.is-still .hero__stage { height: auto; }
.is-still .ticker__track { animation: none; }

/* ---------- mobile refinements ---------- */
.case__bar em { font-style: normal; }
.case__mhero { display: none; }
@media (max-width: 900px) {
  /* cover: lead with the live 3D, then the title */
  .hero__stage { order: -1; height: 46svh; min-height: 300px; }
  .hero__paper { gap: 26px; }
  /* case study: lead image first, short header */
  .case__mhero { display: block; aspect-ratio: 4 / 3; margin: 0 0 20px; }
  .case__mhero img { height: 100%; }
  .case__media > .hero-img, .case__media > .hero-img + .case__cap { display: none; }
  .case__bar em { display: none; }
  .case__body { padding-top: 18px; }
}
@media (max-width: 640px) {
  /* filters: one swipeable row */
  .filters { flex-wrap: nowrap; overflow-x: auto; margin-inline: calc(var(--gutter) * -1); padding: 2px var(--gutter) 8px; scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .filters button { flex: none; }
  .view-toggle { margin-left: 8px; }
  /* section dividers: letter becomes a watermark */
  .divider { grid-template-columns: 1fr; padding: 26px 22px 30px; }
  .divider__letter { position: absolute; right: 14px; top: 6px; font-size: 96px; }
  .divider h3 { font-size: 26px; }
  .case__gallery { grid-template-columns: 1fr 1fr; gap: 8px; }
  .lb__cap { font-size: 13px; }
}

/* ---------- review fixes (UX audit) ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
/* cards are buttons holding spans */
.card > span, .card__text > span { display: block; }
.card__text .card__meta { display: flex; }
.work-grid.is-list .card__text { display: contents; }
/* a lone last card in the 3-column grid spans the row */
@media (min-width: 1101px) {
  .work-grid:not(.is-list) .card--wide { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 26px; align-items: end; }
  .work-grid:not(.is-list) .card--wide .card__media { aspect-ratio: 16 / 7; }
  .work-grid:not(.is-list) .card--wide .card__title { font-size: clamp(26px, 2.4vw, 34px); }
}
/* list view: one line per kicker */
.work-grid.is-list .card { grid-template-columns: 70px minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 190px) 60px; }
.work-grid.is-list .card__meta .kicker { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* tap targets */
.pub__links a, .pub__links button { padding: 4px 0; }
.foot a { display: inline-block; padding: 6px 0; }
/* touch: no hover hints on the cover */
.hero__hint span { background: rgba(189, 184, 224, .72); padding: 3px 7px; }
@media (max-width: 640px) {
  .divider h3, .divider .eyebrow { padding-right: 58px; }
  .divider__letter { color: rgba(242, 239, 230, .1); }
  .view-toggle { display: none; }
}
@media (prefers-reduced-motion: reduce) { .case, .lb { transition: none; transform: none; } }
.card__meta .yr { white-space: nowrap; }

.card__text .card__tags { display: flex; }
@media (max-width: 640px) { .divider__letter { font-size: 72px; top: 10px; right: 14px; } .divider h3, .divider .eyebrow { padding-right: 60px; } }

/* ---------- 3D Lab on touch: hint, explore mode ---------- */
.lab__hint { position: absolute; left: 12px; top: 30px; right: 12px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .06em; color: rgba(233, 230, 242, .62); pointer-events: none; }
.lab__stage.is-full { position: fixed; inset: 0; z-index: 75; width: 100vw; height: 100vh; height: 100dvh; aspect-ratio: auto; min-height: 0; border: 0; }
.lab__stage.is-full .lab__hud { top: calc(12px + env(safe-area-inset-top, 0px)); }
.lab__stage.is-full .lab__hint { top: calc(30px + env(safe-area-inset-top, 0px)); }
.lab__stage.is-full .lab__tools { bottom: auto; top: calc(52px + env(safe-area-inset-top, 0px)); }
.lab__fullbar { display: none; }
.lab__stage.is-full .lab__fullbar { display: flex; flex-wrap: wrap; align-items: end; gap: 10px 18px; position: absolute; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); padding: 10px 12px 12px; background: rgba(15, 14, 34, .78); border: 1px solid var(--on-dark-rule); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.lab__fullbar .slider { flex: 1 1 130px; min-width: 0; }
.lab__fullnav { display: flex; align-items: center; gap: 8px; flex: 1 1 100%; font-family: var(--f-display); font-size: 18px; color: #fff; }
.lab__fullnav span { flex: 1; text-align: center; }
.lab__fullnav button, .lab__close { background: rgba(255, 255, 255, .06); border: 1px solid var(--on-dark-rule); color: var(--on-dark); font-family: var(--f-mono); font-size: 18px; min-width: 44px; height: 44px; border-radius: 2px; cursor: pointer; }
.lab__close { font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; padding: 0 16px; background: var(--lavender); color: var(--ink-deep); border-color: var(--lavender); }
@media (min-width: 720px) { .lab__fullnav { flex: 0 1 320px; } }
