/*
 * gracepetre.com — public site.
 * Quiet, cinematic, editorial: a near-black gallery wall, warm off-white type, one warm accent.
 * Order: tokens · base · type & controls · header & menu · home · gallery · lightbox · about ·
 * coming soon · 404 · footer · motion.
 */

/* ------------------------------------------------------------------ tokens */
:root {
  --bg: #0b0b0b;
  --bg-2: #111;
  --surface: #161616;
  --ink: #ece9e3;
  --ink-2: #a8a49c;
  --ink-3: #6e6a64;
  --line: rgba(236, 233, 227, .12);
  --line-2: rgba(236, 233, 227, .26);
  --accent: #c3a27c;

  --serif: "Cormorant Garamond", "Cormorant Garamond Fallback", Georgia, "Times New Roman", serif;
  --sans: "Jost", "Jost Fallback", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --maxw: 1440px;
  --gutter: clamp(20px, 4.4vw, 64px);
  --col-gap: clamp(16px, 1.8vw, 28px);
  --section: clamp(80px, 12vw, 180px);
  --header-h: 88px;
  --preview-h: 0px;

  --ease: cubic-bezier(.4, 0, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

@media (max-width: 959px) {
  :root { --header-h: 68px; }
}

.has-preview { --preview-h: 34px; }

/* ------------------------------------------------------------------ base */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  background: var(--bg);
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scrollbar-gutter: stable;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.75;
  font-synthesis: none;
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
}

main {
  display: block;
  flex: 1 0 auto;
  outline: none;
}

h1, h2, h3, h4, p, figure, dl, dd, blockquote { margin: 0; }
h1, h2, h3, h4 { font-weight: 400; }
ul, ol { margin: 0; padding: 0; list-style: none; }
img, svg, picture { display: block; }
img { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
em { font-style: italic; }

button {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  cursor: pointer;
}

[hidden] { display: none !important; }

::selection { background: rgba(195, 162, 124, .38); color: #fff; }

:focus:not(:focus-visible) { outline: none; }
:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }

/* Anchors, and elements focused with (Shift+)Tab, stop below the fixed header rather than under it. */
html { scroll-padding-top: calc(var(--header-h) + var(--preview-h) + 24px); }

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 12px 18px;
  background: var(--ink);
  color: var(--bg);
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  transform: translateY(-160%);
  transition: transform .3s var(--ease-out);
}
.skip-link:focus { transform: none; }

.wrap {
  width: 100%;
  max-width: calc(var(--maxw) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: max(var(--gutter), env(safe-area-inset-left)) max(var(--gutter), env(safe-area-inset-right));
}

/* Image boxes: the average colour, then a blurred preview, then the image fades in on top. */
.media {
  position: relative;
  overflow: hidden;
  background-color: var(--c, var(--surface));
}
.media::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--lqip, none) center / cover no-repeat;
  filter: blur(18px);
  transform: scale(1.12);
  transition: opacity .6s var(--ease) .4s;
}
.media.is-loaded::before { opacity: 0; }
.media picture { position: relative; width: 100%; height: 100%; }
.media img { position: relative; width: 100%; height: auto; }
.js .media img { opacity: 0; transition: opacity .9s var(--ease); }
.js .media.is-loaded img { opacity: 1; }

/* ------------------------------------------------------------------ type & controls */
.label {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.label .num {
  color: var(--accent);
  letter-spacing: .14em;
}
.label .num::after {
  content: "";
  display: inline-block;
  width: 28px;
  height: 1px;
  margin: 0 1em 0 1.1em;
  background: currentColor;
  opacity: .7;
  vertical-align: middle;
  transform: translateY(-1px);
}
.label .dot,
.dot {
  display: inline-block;
  width: 3px;
  height: 3px;
  margin: 0 1.1em;
  border-radius: 50%;
  background: currentColor;
  opacity: .6;
  vertical-align: middle;
  transform: translateY(-1px);
}

.prose p { color: var(--ink-2); max-width: 62ch; }
.prose p + p { margin-top: 1.15em; }
.prose .lead {
  font-family: var(--serif);
  font-size: clamp(22px, 1.95vw, 28px);
  font-weight: 400;
  line-height: 1.45;
  letter-spacing: .003em;
  color: var(--ink);
  max-width: 25em;
}
.prose .lead + p { margin-top: 1.6em; }
.quiet { font-style: italic; color: var(--ink-2) !important; }

/* Grace's own text: a long unbroken word (a URL, a filename-like title) wraps instead of
   overflowing its column or the screen. Ordinary words are unaffected. */
.prose p,
.intro__title,
.sel__title,
.teaser__title,
.teaser__text,
.page-title,
.tile__title,
.lb__title,
.lb__meta,
.lb__caption,
.about__title,
.about__h2,
.hl__text,
.hero__work-title,
.notfound__title,
.footer__name,
.footer__tagline { overflow-wrap: anywhere; }

.section-title {
  font-family: var(--serif);
  font-size: clamp(40px, 5.2vw, 80px);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -.005em;
}
.section-title em { font-weight: 300; }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px 48px;
  padding-bottom: clamp(24px, 2.6vw, 36px);
  border-bottom: 1px solid var(--line);
}
.section-head__meta { padding-bottom: .5em; }

.icon { flex: none; }
.icon-arrow-right,
.icon-arrow-left { width: 26px; height: 11px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-height: 50px;
  padding: 0 22px 0 26px;
  border: 1px solid var(--line-2);
  color: var(--ink);
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: background-color .45s var(--ease), color .45s var(--ease), border-color .45s var(--ease);
}
.btn .icon { transition: transform .5s var(--ease-out); }
.btn:hover { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.btn:hover .icon { transform: translateX(4px); }
.btn .icon-download { width: 11px; height: 15px; }
.btn:hover .icon-download { transform: translateY(2px); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 12px 0;
  color: var(--ink);
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
}
.link-arrow span {
  padding-bottom: 6px;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  transition: background-size .6s var(--ease-out);
}
.link-arrow .icon { margin-top: -6px; transition: transform .5s var(--ease-out); }
.link-arrow:hover span { background-size: 0 1px; background-position: 100% 100%; }
.link-arrow:hover .icon { transform: translateX(5px); }

.rule {
  display: block;
  width: 56px;
  height: 1px;
  background: var(--accent);
}

/* ------------------------------------------------------------------ preview bar (Studio preview) */
.preview-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  height: var(--preview-h);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 16px;
  background: var(--accent);
  color: #17120c;
  font: 500 11px/1 var(--sans);
  letter-spacing: .16em;
  text-transform: uppercase;
  white-space: nowrap;
}
.preview-bar a { text-decoration: underline; text-underline-offset: 3px; }
.preview-bar a:focus-visible { outline-color: #17120c; outline-offset: 2px; }

/* ------------------------------------------------------------------ header */
.site-header {
  position: fixed;
  top: var(--preview-h);
  left: 0;
  right: 0;
  z-index: 40;
  height: var(--header-h);
  background-color: rgba(11, 11, 11, 0);
  border-bottom: 1px solid transparent;
  transition: background-color .5s var(--ease), border-color .5s var(--ease), transform .6s var(--ease-out);
}
body:not(.has-hero) .site-header { background-color: var(--bg); }
/* Over the hero, once scrolled, a soft shade keeps the nav readable above the big title. */
.site-header::before {
  content: "";
  position: absolute;
  inset: 0 0 -32px;
  z-index: -1;
  background: linear-gradient(rgba(11, 11, 11, .8), rgba(11, 11, 11, .58) 62%, rgba(11, 11, 11, 0));
  opacity: 0;
  pointer-events: none;
  transition: opacity .5s var(--ease);
}
.has-hero .site-header.is-scrolled:not(.is-solid)::before { opacity: 1; }
body:not(.has-hero) .site-header.is-scrolled,
.site-header.is-solid {
  border-bottom-color: var(--line);
  background-color: rgba(11, 11, 11, .84);
  -webkit-backdrop-filter: blur(18px) saturate(1.15);
  backdrop-filter: blur(18px) saturate(1.15);
}
.site-header.is-hidden { transform: translateY(calc(-100% - var(--preview-h) - 2px)); }

.site-header__inner {
  /* About + Instagram + Contact, the widest nav: its text plus two of its gaps. */
  --nav-side: calc(200px + 2 * clamp(24px, 2.8vw, 44px));
  height: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  column-gap: 32px;
}

.nav {
  display: flex;
  align-items: center;
  gap: clamp(24px, 2.8vw, 44px);
}
.nav--right { justify-content: flex-end; }

.nav__link {
  position: relative;
  display: inline-block;
  padding: 12px 0;
  font: 500 11px/1.2 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(236, 233, 227, .8);
  white-space: nowrap;
  transition: color .3s var(--ease);
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: .22em;
  bottom: 5px;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .55s var(--ease-out);
}
.nav__link:hover,
.nav__link[aria-current] { color: var(--ink); }
.nav__link:hover::after,
.nav__link[aria-current]::after { transform: scaleX(1); transform-origin: left; }

/* Grace can retitle the site, so the wordmark wraps onto a second line (then clips) rather than
   running into the nav; on desktop it is capped so the widest right-hand nav always fits beside it. */
.wordmark {
  display: block;
  min-width: 0;
  max-width: calc(min(100vw - 16px - 2 * var(--gutter), var(--maxw)) - 64px - 2 * var(--nav-side));
  padding: 10px 0;
  margin-right: -.22em;
  font-family: var(--serif);
  font-size: clamp(20px, 1.65vw, 25px);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: .22em;
  text-transform: uppercase;
  text-align: center;
  text-wrap: balance;
  color: var(--ink);
}
.wordmark__text {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

.menu-toggle,
.menu-close {
  display: none;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  padding: 0 0 0 16px;
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink);
}
.menu-toggle__icon {
  display: grid;
  gap: 6px;
  width: 24px;
}
.menu-toggle__icon span { display: block; height: 1px; background: currentColor; }
.menu-toggle__icon span:last-child { width: 15px; justify-self: end; transition: width .4s var(--ease-out); }
.menu-toggle:hover .menu-toggle__icon span:last-child { width: 24px; }
.menu-close .icon { width: 15px; height: 15px; }

@media (max-width: 959px) {
  .site-header__inner { grid-template-columns: minmax(0, 1fr) auto; column-gap: 16px; }
  .site-header .nav { display: none; }
  .site-header .wordmark { justify-self: start; }
  .menu-toggle { display: inline-flex; }
  .wordmark {
    max-width: 100%;
    font-size: 19px;
    letter-spacing: .2em;
    text-align: left;
  }
  .wordmark--long { font-size: clamp(13px, 4.2vw, 17px); letter-spacing: .12em; }
}

/* Mobile menu: a full-screen dialog of large numbered serif links. */
.menu {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--bg);
  color: var(--ink);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  opacity: 0;
  transition: opacity .4s var(--ease);
}
.menu[open] { display: flex; flex-direction: column; }
.menu.is-open { opacity: 1; }
.menu::backdrop { background: var(--bg); opacity: 0; }
.menu__top {
  flex: none;
  height: var(--header-h);
  margin-top: var(--preview-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
}
.menu__top .wordmark { flex: 0 1 auto; }
.menu .menu-close { display: inline-flex; flex: none; }
.menu__nav {
  flex: 1 0 auto;
  display: flex;
  align-items: center;
  padding-block: 40px;
}
.menu__list { width: 100%; }
.menu__item {
  border-bottom: 1px solid var(--line);
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .7s var(--ease-out), transform .9s var(--ease-out);
}
.menu__item:first-child { border-top: 1px solid var(--line); }
.menu.is-open .menu__item { opacity: 1; transform: none; }
.menu.is-open .menu__item:nth-child(1) { transition-delay: .08s; }
.menu.is-open .menu__item:nth-child(2) { transition-delay: .14s; }
.menu.is-open .menu__item:nth-child(3) { transition-delay: .2s; }
.menu__link {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  align-items: baseline;
  padding: 22px 0 20px;
}
.menu__num,
.menu__count {
  font: 500 11px/1 var(--sans);
  letter-spacing: .16em;
}
.menu__num { color: var(--accent); }
.menu__count { color: var(--ink-2); }
.menu__label {
  font-family: var(--serif);
  font-size: clamp(40px, 11.5vw, 72px);
  font-weight: 300;
  line-height: 1;
  transition: transform .5s var(--ease-out);
}
.menu__link:hover .menu__label { transform: translateX(8px); }
.menu__link[aria-current] .menu__label { font-style: italic; }
.menu__foot {
  flex: none;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 32px;
  padding-top: 24px;
  padding-bottom: calc(28px + env(safe-area-inset-bottom));
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.menu__foot a { padding: 10px 0; transition: color .3s; }
.menu__foot a:hover,
.menu__foot a[aria-current] { color: var(--ink); }

html.menu-open,
html.lb-open { overflow: hidden; }

/* ------------------------------------------------------------------ home: hero */
.hero {
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 560px;
  overflow: hidden;
  isolation: isolate;
  background: var(--bg);
}
.hero__media {
  position: absolute;
  inset: 0;
  z-index: -2;
}
.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
}
.js .hero__media.is-loaded img { animation: hero-settle 3.2s var(--ease-out) both; }
/* A banner too wide or tall for any screen is shown whole over its own blurred preview. */
.hero--contain .hero__media img { object-fit: contain; }
.hero--contain .hero__media.is-loaded::before { opacity: .55; }
/* Scrims: top for the nav, bottom for the foot, and a centre pool so the title and kicker stay
   readable over pale skies, fog or snow (plus an overall wash when the banner is bright). */
.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(11, 11, 11, .62) 0, rgba(11, 11, 11, .22) 150px, rgba(11, 11, 11, 0) 34%),
    linear-gradient(to top, rgba(11, 11, 11, .82) 0, rgba(11, 11, 11, .35) 22%, rgba(11, 11, 11, 0) 48%),
    radial-gradient(ellipse 72% 48% at 50% 50%, rgba(11, 11, 11, .46), rgba(11, 11, 11, .36) 38%, rgba(11, 11, 11, 0) 80%);
}
.hero--light .hero__scrim {
  background:
    linear-gradient(to bottom, rgba(11, 11, 11, .62) 0, rgba(11, 11, 11, .22) 150px, rgba(11, 11, 11, 0) 34%),
    linear-gradient(to top, rgba(11, 11, 11, .82) 0, rgba(11, 11, 11, .35) 22%, rgba(11, 11, 11, 0) 48%),
    radial-gradient(ellipse 72% 48% at 50% 50%, rgba(11, 11, 11, .5), rgba(11, 11, 11, .4) 38%, rgba(11, 11, 11, 0) 80%),
    rgba(11, 11, 11, .24);
}
.hero__content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--header-h) + var(--preview-h)) var(--gutter) 96px;
  text-align: center;
}
.hero__kicker {
  max-width: 100%;
  margin-bottom: clamp(18px, 2.2vw, 30px);
  font: 500 11px/1.6 var(--sans);
  letter-spacing: .34em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
  color: var(--ink);
  text-shadow: 0 0 14px rgba(11, 11, 11, .6);
  animation: rise 1.4s var(--ease-out) .2s both;
}
/* --lw (set by the template) is the longest word's length: long words shrink the type until they
   fit the screen (≈ .8em per uppercase letter), so nothing is cut off at the hero's edges. */
.hero__title {
  max-width: min(16em, 100%);
  font-family: var(--serif);
  font-size: clamp(38px, 6.4vw, 100px);
  font-size: min(clamp(38px, 6.4vw, 100px), calc((100vw - 2 * var(--gutter)) / (var(--lw, 10) * .8)));
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-wrap: balance;
  overflow-wrap: anywhere;
  text-shadow: 0 0 32px rgba(11, 11, 11, .42);
  margin-right: -.08em;
  animation: rise 1.6s var(--ease-out) .35s both;
}
.hero__foot {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  animation: fade 1.6s var(--ease) .9s both;
}
.hero__foot-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: start;
  border-top: 1px solid rgba(236, 233, 227, .28);
}
.hero__work {
  justify-self: start;
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 16px;
  padding: 22px 0 30px;
  min-width: 0;
}
.hero__work-title {
  font-family: var(--serif);
  font-size: 19px;
  font-style: italic;
  line-height: 1.3;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .6s var(--ease-out);
}
.hero__work:hover .hero__work-title { background-size: 100% 1px; }
.hero__work-year,
.hero__cat {
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(236, 233, 227, .78);
}
.hero__cue {
  justify-self: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding-top: 20px;
  font: 500 10px/1 var(--sans);
  letter-spacing: .34em;
  text-transform: uppercase;
  color: rgba(236, 233, 227, .78);
  margin-right: -.34em;
}
.hero__cue-line {
  position: relative;
  width: 1px;
  height: 52px;
  overflow: hidden;
  background: rgba(236, 233, 227, .2);
}
.hero__cue-line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--ink);
  animation: cue 2.6s var(--ease) infinite;
}
.hero__cat {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 26px 0 30px;
  transition: color .3s;
}
.hero__cat .icon { transition: transform .5s var(--ease-out); }
.hero__cat:hover { color: var(--ink); }
.hero__cat:hover .icon { transform: translateX(4px); }

/* Typographic hero when there's no work yet. */
.hero--type {
  height: auto;
  min-height: 86vh;
  min-height: 86svh;
  display: grid;
  background:
    radial-gradient(ellipse 70% 55% at 50% 45%, #191815 0%, rgba(11, 11, 11, 0) 70%),
    var(--bg);
  border-bottom: 1px solid var(--line);
}
.hero--type .hero__content { position: relative; }
.hero__rule {
  display: block;
  width: 1px;
  height: 64px;
  margin-top: clamp(32px, 4vw, 48px);
  background: var(--accent);
  animation: fade 1.6s var(--ease) .8s both;
}

.home-start { height: 0; outline: none; }
/* Whichever section comes first after the banner (the intro is optional) gets the top space. */
.home-start + .selected,
.home-start + .portfolio,
.home-start + .teaser { padding-top: var(--section); }

@media (max-width: 767px) {
  .hero__foot-inner { grid-template-columns: minmax(0, 1fr) auto; column-gap: 24px; }
  .hero__cat { display: none; }
  .hero__cue { justify-self: end; margin-right: 0; }
  .hero__work { flex-direction: column; gap: 8px; padding-bottom: 28px; }
  .hero__work-title { font-size: 18px; }
}

/* ------------------------------------------------------------------ home: intro */
.intro {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  padding-block: var(--section);
}
.intro__head { grid-column: 1 / span 5; }
.intro__text { grid-column: 7 / span 6; padding-top: .35em; }
.intro__title {
  font-family: var(--serif);
  font-size: clamp(30px, 3.3vw, 50px);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-wrap: balance;
}
.intro__head .rule { margin: clamp(28px, 3vw, 40px) 0; }
.intro__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.intro__title + .rule + .intro__actions,
.intro__head > .intro__actions:first-child { margin-top: 0; }

@media (max-width: 899px) {
  .intro { grid-template-columns: minmax(0, 1fr); row-gap: 48px; }
  .intro__head,
  .intro__text { grid-column: auto; }
}
@media (max-width: 479px) {
  .intro__actions .btn { flex: 1 1 100%; justify-content: space-between; }
}

/* ------------------------------------------------------------------ home: selected works */
.selected { padding-bottom: var(--section); }
.selected .section-head,
.portfolio .section-head { margin-bottom: clamp(48px, 7vw, 110px); }

.sel-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: clamp(80px, 9vw, 150px);
  align-items: start;
}
.sel { grid-column: var(--start) / span var(--span); min-width: 0; }
.sel--offset { margin-top: clamp(64px, 14vw, 240px); }
/* Never taller than the screen: a very tall work narrows (centred in its column) instead. */
.sel__link {
  display: block;
  max-width: calc(85vh * var(--r, 1));
  max-width: calc(85svh * var(--r, 1));
  margin-inline: auto;
}
.sel__media img { transition: transform 1.6s var(--ease-out), opacity .9s var(--ease); }
.sel__link:hover .sel__media img { transform: scale(1.025); }
.sel__cap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 18px;
  margin-top: 20px;
}
.sel__num {
  font: 500 11px/1 var(--sans);
  letter-spacing: .14em;
  color: var(--accent);
}
.sel__title {
  flex: 0 1 auto;
  min-width: 0;
  margin-right: auto;
  font-family: var(--serif);
  font-size: clamp(20px, 1.55vw, 24px);
  line-height: 1.25;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .6s var(--ease-out);
}
.sel__link:hover .sel__title { background-size: 100% 1px; }
.sel__meta {
  font: 500 10.5px/1.4 var(--sans);
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-2);
}

@media (max-width: 899px) {
  .sel-grid { display: flex; flex-direction: column; row-gap: clamp(56px, 12vw, 88px); }
  .sel { width: 100%; }
  .sel--square { width: 68%; }
  .sel--portrait,
  .sel--tall { width: 58%; }
  .sel:nth-child(even):not(.sel--landscape):not(.sel--wide) { margin-left: auto; }
  .sel--offset { margin-top: 0; }
  .sel__cap {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 14px;
    row-gap: 6px;
    margin-top: 16px;
  }
  .sel__meta { grid-column: 2; }
}
@media (max-width: 599px) {
  .sel--square { width: 84%; }
  .sel--portrait,
  .sel--tall { width: 76%; }
}

/* ------------------------------------------------------------------ home: portals */
.portfolio { padding-bottom: var(--section); }
.portals {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(12px, 1.6vw, 24px);
}
.portal {
  position: relative;
  display: block;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  isolation: isolate;
  background: var(--surface);
}
.portals--single { grid-template-columns: minmax(0, 1fr); }
.portals--single .portal { aspect-ratio: 21 / 9; }
.portal__media {
  position: absolute;
  inset: 0;
  z-index: -2;
}
.portal__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.8s var(--ease-out), opacity .9s var(--ease);
}
.portal:hover .portal__media img { transform: scale(1.045); }
.portal::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to top, rgba(11, 11, 11, .84) 0, rgba(11, 11, 11, .4) 30%, rgba(11, 11, 11, 0) 58%);
  transition: opacity .6s var(--ease);
}
.portal__body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  gap: 14px;
  padding: clamp(24px, 3vw, 48px);
}
.portal__label { color: rgba(236, 233, 227, .82); }
.portal__title {
  font-family: var(--serif);
  font-size: clamp(44px, 5.2vw, 80px);
  font-weight: 300;
  line-height: .95;
  margin-left: -.03em;
}
.portal__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 8px;
  padding-top: 18px;
  border-top: 1px solid rgba(236, 233, 227, .3);
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(236, 233, 227, .82);
}
.portal__cta {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--ink);
}
.portal__cta .icon { transition: transform .5s var(--ease-out); }
.portal:hover .portal__cta .icon { transform: translateX(5px); }

@media (max-width: 767px) {
  .portals { grid-template-columns: minmax(0, 1fr); }
  .portals--single .portal,
  .portal { aspect-ratio: 4 / 5; }
}

/* ------------------------------------------------------------------ home: about teaser */
.teaser {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  align-items: center;
  padding-bottom: var(--section);
}
.teaser__media { grid-column: 2 / span 4; }
.teaser__portrait { aspect-ratio: 4 / 5; }
.teaser__portrait img { width: 100%; height: 100%; object-fit: cover; }
.teaser__body { grid-column: 7 / span 5; }
.teaser--solo .teaser__body { grid-column: 3 / span 8; }
.teaser__title {
  margin-top: 22px;
  font-family: var(--serif);
  font-size: clamp(44px, 5vw, 76px);
  font-weight: 300;
  line-height: 1;
}
.teaser__text {
  margin: clamp(24px, 2.6vw, 36px) 0 clamp(28px, 3vw, 40px);
  max-width: 46ch;
  color: var(--ink-2);
  font-size: 17px;
  line-height: 1.8;
}

@media (max-width: 899px) {
  .teaser { grid-template-columns: minmax(0, 1fr); row-gap: 48px; }
  .teaser__media,
  .teaser__body,
  .teaser--solo .teaser__body { grid-column: auto; }
  .teaser__media { width: 76%; max-width: 440px; }
}

/* ------------------------------------------------------------------ gallery */
.page-head {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: 32px;
  align-items: end;
  padding-top: calc(var(--header-h) + var(--preview-h) + clamp(56px, 8vw, 128px));
  padding-bottom: clamp(36px, 4.4vw, 64px);
}
.page-head__main { grid-column: 1 / span 7; }
.page-head__aside { grid-column: 9 / span 4; padding-bottom: .4em; }
.page-title {
  margin-top: clamp(18px, 2vw, 28px);
  margin-left: -.045em;
  font-family: var(--serif);
  font-size: clamp(58px, 9.4vw, 144px);
  font-weight: 300;
  line-height: .9;
  letter-spacing: -.012em;
}
.page-intro { font-size: 16px; line-height: 1.75; }

.meta-bar {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
  margin-bottom: clamp(20px, 2.4vw, 32px);
}

@media (max-width: 899px) {
  .page-head { grid-template-columns: minmax(0, 1fr); }
  .page-head__main,
  .page-head__aside { grid-column: auto; }
  .page-head__aside { max-width: 52ch; }
}

/* Justified rows in pure CSS: width grows in proportion to aspect ratio, so every item in a row
   ends up the same height; the huge-growth spacer keeps the last row at its natural height.
   Grow factors are ×100 because flexbox hands out only part of the free space when a line's
   factors add up to less than 1 (a lone portrait would stop short of the edge). */
.jg {
  --row-h: 300px;
  --gap: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: var(--gap);
  /* site.js picks the row breaks, then shows the grid, so nothing jumps after first paint. Until
     then (1.2 s at most, in case it never runs) the grid is hidden and, where content-visibility
     animates, its tiles aren't laid out either: a lazy image picked at the provisional CSS width
     would fetch one size too large. Without JavaScript the <noscript> style drops the hold. */
  animation: jg-hold 1.2s step-end;
}
.jg.is-ready { animation: none; }
@keyframes jg-hold { from, to { visibility: hidden; content-visibility: hidden; } }
.jg::after {
  content: "";
  flex: 100000000 1 0px;
}
.jg__item {
  flex: calc(var(--r) * 100) 1 calc(var(--r) * var(--row-h));
  min-width: 0;
}
@media (max-width: 1199px) { .jg { --row-h: 260px; } }
@media (max-width: 899px) { .jg { --row-h: 220px; --gap: 10px; } }
@media (max-width: 599px) { .jg { --row-h: 170px; --gap: 6px; } }
/* One or two works shouldn't sit small in a corner: larger, and centred rather than stretched. */
.jg--few { --row-h: 460px; justify-content: center; }
.jg--few::after { display: none; }
.jg--few .jg__item { flex-grow: 0; max-width: 100%; }
@media (max-width: 1199px) { .jg--few { --row-h: 380px; } }
@media (max-width: 899px) { .jg--few { --row-h: 300px; } }
@media (max-width: 599px) { .jg--few { --row-h: 240px; } }
/* site.js has chosen the row breaks and given every work its width (and a centred row its margins). */
.jg.is-laid::after { display: none; }
.jg.is-laid > .jg__item {
  flex: 0 0 var(--w);
  max-width: none;
  margin: 0 var(--mr, 0px) 0 var(--ml, 0px);
}

.tile {
  position: relative;
  display: block;
  overflow: hidden;
}
.tile__media img { transition: transform 1.4s var(--ease-out), opacity .9s var(--ease); }
.tile:hover .tile__media img { transform: scale(1.03); }
.tile__cap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 48px 18px 14px;
  background: linear-gradient(to top, rgba(11, 11, 11, .72), rgba(11, 11, 11, 0));
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .45s var(--ease), transform .6s var(--ease-out);
  pointer-events: none;
}
.tile:hover .tile__cap,
.tile:focus-visible .tile__cap { opacity: 1; transform: none; }
.tile:focus-visible { outline-offset: 3px; }
.tile__title {
  display: -webkit-box;
  min-width: 0;
  overflow: hidden;
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.2;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}
.tile__year {
  flex: none;
  font: 500 10.5px/1 var(--sans);
  letter-spacing: .2em;
  color: rgba(236, 233, 227, .8);
}
/* Touch screens: no hover captions, but the title and year stay in the link's accessible name
   (the image's alt is left empty when it would only repeat the title). */
@media (hover: none) {
  .tile__cap {
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}

.empty {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 18px;
  min-height: clamp(260px, 36vw, 480px);
  border: 1px solid var(--line);
  text-align: center;
  padding: 48px 24px;
}
.empty__text {
  font-family: var(--serif);
  font-size: clamp(28px, 3.2vw, 44px);
  font-style: italic;
  font-weight: 300;
  line-height: 1.15;
  color: var(--ink);
}

.nojs-work { margin-bottom: 48px; }
.nojs-work img { max-height: 80vh; width: auto; margin-inline: auto; }
.nojs-work figcaption { margin-top: 16px; text-align: center; color: var(--ink-2); }

/* Onward links at the foot of a gallery. */
.onward {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  column-gap: clamp(32px, 6vw, 96px);
  padding-top: var(--section);
}
.onward__link {
  display: flex;
  align-items: center;
  gap: clamp(20px, 3vw, 44px);
  padding: clamp(28px, 3.4vw, 48px) 0;
  border-top: 1px solid var(--line-2);
  min-width: 0;
}
.onward__link:only-child { grid-column: 1 / -1; }
.onward__text { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; min-width: 0; }
.onward__title {
  font-family: var(--serif);
  font-size: clamp(40px, 5.6vw, 88px);
  font-weight: 300;
  line-height: 1;
  transition: transform .6s var(--ease-out);
}
.onward__link--quiet .onward__title { font-size: clamp(30px, 2.8vw, 44px); line-height: 1.1; }
.onward__meta {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-2);
  transition: color .3s;
}
.onward__meta .icon { transition: transform .5s var(--ease-out); }
.onward__link:hover .onward__meta { color: var(--ink); }
.onward__link:hover .onward__meta .icon { transform: translateX(5px); }
.onward__link:hover .onward__title { transform: translateX(6px); }
.onward__thumb {
  flex: none;
  width: clamp(88px, 11vw, 168px);
  aspect-ratio: 4 / 5;
}
.onward__thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.6s var(--ease-out), opacity .9s var(--ease); }
.onward__link:hover .onward__thumb img { transform: scale(1.05); }

@media (max-width: 899px) {
  .onward { grid-template-columns: minmax(0, 1fr); }
}
/* "Photography" beside its thumbnail must still fit a 320px screen (and 400% zoom). */
@media (max-width: 399px) {
  .onward__thumb { width: 72px; }
  .onward__title { font-size: clamp(30px, 10vw, 40px); }
}

/* ------------------------------------------------------------------ lightbox */
.lb {
  --lb-pad: clamp(16px, 2vw, 28px);
  --info-w: 0px;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: #080808;
  color: var(--ink);
  overflow: hidden;
  opacity: 0;
  transition: opacity .35s var(--ease);
  outline: none;
}
.lb[open] {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--info-w);
  grid-template-rows: 72px minmax(0, 1fr) 96px;
  grid-template-areas:
    "bar bar"
    "stage info"
    "strip info";
  transition: opacity .35s var(--ease), grid-template-columns .5s var(--ease-out);
}
.lb.is-open { opacity: 1; }
.lb::backdrop { background: rgba(8, 8, 8, .92); }
.lb.has-info { --info-w: 380px; }
.lb.is-single { grid-template-rows: 72px minmax(0, 1fr) 40px; }

.lb__bar {
  grid-area: bar;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--lb-pad);
  min-width: 0;
}
.lb__count {
  font: 400 13px/1 var(--sans);
  letter-spacing: .14em;
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
  padding-left: 4px;
}
.lb__count [data-lb-pos] { color: var(--ink); }
.lb__count-sep { margin: 0 .6em; color: var(--ink-3); }
.lb.is-single .lb__count { visibility: hidden; }
.lb__tools { display: flex; align-items: center; gap: 4px; }
.lb__tool {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 12px;
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-2);
  transition: color .3s;
}
.lb__tool .icon { width: 15px; height: 15px; }
.lb__tool:hover,
.lb__tool[aria-expanded="true"] { color: var(--ink); }

.lb__stage {
  grid-area: stage;
  position: relative;
  overflow: hidden;
  min-width: 0;
  touch-action: pan-y pinch-zoom;
}
.lb__viewport {
  position: absolute;
  inset: 0 clamp(72px, 7vw, 104px) 12px;
}
.lb.is-single .lb__viewport { inset-inline: clamp(24px, 4vw, 64px); }
.lb__frame {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 0;
  height: 0;
  overflow: hidden;
  background-color: var(--c, #151515);
  opacity: 0;
  pointer-events: none;
  transition: opacity .55s var(--ease), transform .75s var(--ease-out);
}
.lb__frame.is-active { opacity: 1; pointer-events: auto; z-index: 1; }
.lb__frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--lqip, none) center / cover no-repeat;
  filter: blur(20px);
  transform: scale(1.12);
  transition: opacity .5s var(--ease) .25s;
}
.lb__frame.is-loaded::before { opacity: 0; }
.lb__frame picture,
.lb__frame img {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
}
.lb__frame img { opacity: 0; transition: opacity .5s var(--ease); -webkit-user-select: none; user-select: none; -webkit-user-drag: none; }
.lb__frame.is-loaded img { opacity: 1; }

.lb__nav {
  grid-area: stage;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(4px, 1vw, 16px) 12px;
  pointer-events: none;
}
.lb__arrow {
  pointer-events: auto;
  display: grid;
  place-items: center;
  width: 64px;
  height: 112px;
  color: var(--ink-2);
  transition: color .3s;
}
.lb__arrow .icon { width: 15px; height: 30px; transition: transform .5s var(--ease-out); }
.lb__arrow:hover { color: var(--ink); }
.lb__arrow--prev:hover .icon { transform: translateX(-4px); }
.lb__arrow--next:hover .icon { transform: translateX(4px); }
.lb.is-single .lb__arrow { visibility: hidden; }
.lb__mini { display: none; }

.lb__strip {
  grid-area: strip;
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 0 var(--lb-pad) 8px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
}
.lb__strip::-webkit-scrollbar { display: none; }
.lb__strip::before,
.lb__strip::after { content: ""; margin: auto; }
.lb__thumb {
  position: relative;
  flex: none;
  height: 54px;
  background: var(--c, var(--surface));
  opacity: .34;
  transition: opacity .35s var(--ease);
}
.lb__thumb picture { height: 100%; }
.lb__thumb img { width: auto; height: 100%; max-width: none; }
.lb__thumb:hover { opacity: .78; }
.lb__thumb[aria-current="true"] { opacity: 1; }
.lb__thumb::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -9px;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transition: transform .45s var(--ease-out);
}
.lb__thumb[aria-current="true"]::after { transform: scaleX(1); }

.lb__info {
  grid-area: info;
  min-width: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-left: 1px solid var(--line);
  background: #0d0d0d;
  visibility: hidden;
}
.lb__sheet-head { display: none; }
.lb__info-body {
  width: 380px;
  padding: 12px 40px 48px;
}
.lb__cat { margin-bottom: 20px; color: var(--accent); }
.lb__title {
  font-family: var(--serif);
  font-size: clamp(30px, 2.3vw, 38px);
  font-weight: 400;
  line-height: 1.08;
  text-wrap: balance;
}
.lb__meta {
  margin-top: 14px;
  font-size: 13px;
  letter-spacing: .04em;
  color: var(--ink-2);
}
.lb__caption {
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink);
}
.lb__caption p + p { margin-top: .85em; }
.lb__exif { margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--line); }
.lb__exif-list {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 11px 22px;
  margin-top: 18px;
  font-size: 13px;
  line-height: 1.45;
}
.lb__exif-list dt { color: var(--ink-2); white-space: nowrap; }
.lb__exif-list dd { color: var(--ink); overflow-wrap: anywhere; }
.lb__copy {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
  padding: 12px 0;
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-2);
  transition: color .3s;
}
.lb__copy .icon { width: 15px; height: 15px; }
.lb__copy:hover { color: var(--ink); }

@media (min-width: 900px) {
  .lb.has-info .lb__info { visibility: visible; }
}

/* Phones and small tablets: full-bleed image, caption bar with arrows, details in a bottom sheet. */
@media (max-width: 899px) {
  .lb[open],
  .lb.is-single[open] {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 60px minmax(0, 1fr) auto;
    grid-template-areas:
      "bar"
      "stage"
      "nav";
  }
  .lb__bar { padding: 0 8px 0 16px; padding-top: env(safe-area-inset-top); }
  .lb__tool { padding: 0 10px; }
  .lb__viewport,
  .lb.is-single .lb__viewport { inset: 0; }
  .lb__nav {
    grid-area: nav;
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr) 56px;
    align-items: center;
    padding: 10px 0 calc(10px + env(safe-area-inset-bottom));
    pointer-events: auto;
  }
  .lb__arrow { width: 56px; height: 60px; }
  .lb__arrow .icon { width: 11px; height: 22px; }
  .lb__mini {
    display: grid;
    gap: 6px;
    justify-items: center;
    min-width: 0;
    padding: 6px 8px;
    text-align: center;
  }
  .lb__mini-title {
    max-width: 100%;
    overflow: hidden;
    font-family: var(--serif);
    font-size: 20px;
    line-height: 1.2;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
  .lb__mini-meta {
    max-width: 100%;
    overflow: hidden;
    font: 500 10px/1.3 var(--sans);
    letter-spacing: .18em;
    text-transform: uppercase;
    white-space: nowrap;
    text-overflow: ellipsis;
    color: var(--ink-2);
  }
  .lb__mini-meta:empty { display: none; }
  .lb__strip { display: none; }

  .lb__info {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 5;
    max-height: 76vh;
    max-height: 76svh;
    border-left: 0;
    border-top: 1px solid var(--line-2);
    background: #121212;
    transform: translateY(100%);
    transition: transform .5s var(--ease-out), visibility 0s linear .5s;
  }
  .lb.sheet-open .lb__info {
    visibility: visible;
    transform: none;
    transition: transform .5s var(--ease-out);
  }
  .lb__stage::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 3;
    background: rgba(8, 8, 8, .55);
    opacity: 0;
    pointer-events: none;
    transition: opacity .4s var(--ease);
  }
  .lb.sheet-open .lb__stage::after { opacity: 1; pointer-events: auto; }
  .lb__sheet-head {
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 44px;
    background: #121212;
  }
  .lb__handle { width: 36px; height: 2px; background: var(--line-2); }
  .lb__sheet-close {
    position: absolute;
    right: 6px;
    top: 0;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    color: var(--ink-2);
  }
  .lb__sheet-close .icon { width: 13px; height: 13px; }
  .lb__info-body {
    width: auto;
    padding: 4px 24px calc(32px + env(safe-area-inset-bottom));
  }
  .lb__title { font-size: 30px; }
  .lb__caption { font-size: 18px; margin-top: 22px; padding-top: 22px; }
  .lb__exif { margin-top: 24px; padding-top: 22px; }
  .lb__copy { margin-top: 20px; }
}

@media (min-width: 600px) and (max-width: 899px) {
  .lb__viewport,
  .lb.is-single .lb__viewport { inset: 8px 32px; }
}

/* ------------------------------------------------------------------ about */
.about {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-rows: auto 1fr;
  column-gap: var(--col-gap);
  padding-top: calc(var(--header-h) + var(--preview-h) + clamp(56px, 8vw, 128px));
  padding-bottom: var(--section);
}
.about__head { grid-column: 7 / span 6; grid-row: 1; }
.about__media { grid-column: 1 / span 5; grid-row: 1 / span 2; }
.about__body { grid-column: 7 / span 6; grid-row: 2; }
.about--solo .about__head,
.about--solo .about__body { grid-column: 3 / span 8; }
.about__sticky { position: sticky; top: calc(var(--header-h) + var(--preview-h) + 32px); }
.about__portrait { aspect-ratio: 4 / 5; }
.about__portrait img { width: 100%; height: 100%; object-fit: cover; }
.about__title {
  margin-top: clamp(18px, 2vw, 28px);
  margin-left: -.04em;
  font-family: var(--serif);
  font-size: clamp(54px, 7.4vw, 116px);
  font-weight: 300;
  line-height: .95;
  letter-spacing: -.01em;
}
.about__text { margin-top: clamp(40px, 5vw, 72px); }
.about__text p:not(.lead) { font-size: 17px; line-height: 1.8; }
.about__section { margin-top: clamp(64px, 7vw, 104px); }
.about__h2 {
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line-2);
  font-family: var(--serif);
  font-size: clamp(28px, 2.4vw, 36px);
  font-weight: 400;
  line-height: 1.15;
}
.hl__row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 24px;
  padding: 20px 0 19px;
  border-bottom: 1px solid var(--line);
}
.hl__year {
  padding-top: 6px;
  font: 500 12px/1.4 var(--sans);
  letter-spacing: .14em;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
}
.hl__text {
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.4;
}
.contact__row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: baseline;
  gap: 24px;
  padding: 20px 0 19px;
  border-bottom: 1px solid var(--line);
}
.contact__row .label { line-height: 1.4; }
.contact__value {
  font-family: var(--serif);
  font-size: clamp(22px, 2vw, 28px);
  line-height: 1.3;
  overflow-wrap: anywhere;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .6s var(--ease-out);
}
a.contact__value:hover { background-size: 100% 1px; }
.no-js [data-email-show] { display: none; }
.contact__resume {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 24px;
  margin-top: 40px;
}
.contact__file {
  font: 500 11px/1 var(--sans);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-2);
}

@media (max-width: 899px) {
  .about { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; }
  .about__head,
  .about__media,
  .about__body,
  .about--solo .about__head,
  .about--solo .about__body { grid-column: auto; grid-row: auto; }
  .about__media { margin-top: 44px; }
  .about__sticky { position: static; }
  .hl__row { grid-template-columns: 64px minmax(0, 1fr); gap: 16px; }
  .hl__text { font-size: 20px; }
  .contact__row { grid-template-columns: minmax(0, 1fr); gap: 6px; }
}

/* ------------------------------------------------------------------ coming soon */
.page-coming-soon main { flex: 1 0 auto; }
.soon {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 48px var(--gutter);
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}
.soon__media { position: absolute; inset: 0; z-index: -2; }
.soon__media img { width: 100%; height: 100%; object-fit: cover; }
.soon--contain .soon__media img { object-fit: contain; }
.soon--contain .soon__media.is-loaded::before { opacity: .55; }
.js .soon__media.is-loaded img { animation: hero-settle 4s var(--ease-out) both; }
.soon::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 60% 50% at 50% 50%, rgba(11, 11, 11, .42), rgba(11, 11, 11, .72) 100%),
    rgba(11, 11, 11, .3);
}
.soon--light::after {
  background:
    radial-gradient(ellipse 60% 50% at 50% 50%, rgba(11, 11, 11, .5), rgba(11, 11, 11, .76) 100%),
    rgba(11, 11, 11, .36);
}
.soon__content { max-width: 100%; animation: rise 1.8s var(--ease-out) .2s both; }
/* Same longest-word fit as .hero__title (wider tracking, so ≈ .86em per letter). */
.soon__name {
  margin-right: -.14em;
  font-family: var(--serif);
  font-size: clamp(44px, 8.4vw, 124px);
  font-size: min(clamp(44px, 8.4vw, 124px), calc((100vw - 2 * var(--gutter)) / (var(--lw, 10) * .86)));
  font-weight: 400;
  line-height: 1;
  letter-spacing: .14em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
  text-shadow: 0 0 32px rgba(11, 11, 11, .4);
}
.soon__label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: clamp(24px, 3vw, 36px);
  font: 500 11px/1.4 var(--sans);
  letter-spacing: .32em;
  text-transform: uppercase;
  color: rgba(236, 233, 227, .82);
}
.soon__label > span { white-space: nowrap; }
.soon__label::before,
.soon__label::after {
  content: "";
  flex: none;
  width: clamp(20px, 5vw, 56px);
  height: 1px;
  background: currentColor;
  opacity: .6;
}
@media (max-width: 399px) {
  .soon__label { gap: 14px; letter-spacing: .24em; }
}

/* ------------------------------------------------------------------ 404 */
.notfound {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  align-items: center;
  min-height: 78vh;
  min-height: 78svh;
  padding-top: calc(var(--header-h) + var(--preview-h) + 48px);
  padding-bottom: clamp(64px, 8vw, 120px);
}
.notfound__body { grid-column: 1 / span 7; position: relative; }
.notfound__code {
  grid-column: 8 / span 5;
  justify-self: end;
  font-family: var(--serif);
  font-size: clamp(120px, 21vw, 320px);
  font-weight: 300;
  line-height: .8;
  letter-spacing: -.02em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(236, 233, 227, .2);
  -webkit-user-select: none;
  user-select: none;
  order: 2;
}
.notfound__title {
  margin-top: clamp(20px, 2.2vw, 30px);
  font-family: var(--serif);
  font-size: clamp(42px, 5.4vw, 84px);
  font-weight: 300;
  line-height: 1.02;
  text-wrap: balance;
}
.notfound__text {
  max-width: 44ch;
  margin: clamp(22px, 2.4vw, 32px) 0 clamp(32px, 3.6vw, 48px);
  color: var(--ink-2);
  font-size: 17px;
}
.notfound__links { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 36px; }

@media (max-width: 899px) {
  .notfound { grid-template-columns: minmax(0, 1fr); align-content: center; }
  .notfound__body { grid-column: auto; }
  .notfound__code {
    grid-column: auto;
    justify-self: start;
    order: 0;
    font-size: clamp(110px, 34vw, 200px);
    margin-bottom: 24px;
  }
}

/* ------------------------------------------------------------------ footer */
.site-footer {
  flex: none;
  padding-top: clamp(64px, 8vw, 128px);
  padding-bottom: calc(28px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
}
.footer__name {
  font-family: var(--serif);
  font-size: clamp(52px, 9.6vw, 148px);
  font-weight: 300;
  line-height: .92;
  letter-spacing: -.01em;
  margin-left: -.04em;
}
.footer__name a { transition: color .4s; }
.footer__name a:hover { color: var(--ink-2); }
.footer__tagline {
  margin-top: clamp(14px, 1.6vw, 22px);
  font-family: var(--serif);
  font-size: clamp(19px, 1.6vw, 23px);
  font-style: italic;
  color: var(--ink-2);
}
.footer__main {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--col-gap);
  row-gap: 48px;
  align-items: end;
}
.footer__top { grid-column: 1 / span 7; }
.footer__cols {
  grid-column: 9 / span 4;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: var(--col-gap);
  align-items: start;
  padding-bottom: 6px;
}
.footer__heading { margin-bottom: 14px; }
.footer__links a {
  display: inline-block;
  padding: 3px 0;
  font-size: 15px;
  line-height: 1.8;
  color: var(--ink-2);
  transition: color .3s;
}
.footer__links a:hover,
.footer__links a[aria-current] { color: var(--ink); }
.footer__top-link {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 10px 0;
  font: 500 11px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-2);
  transition: color .3s;
}
.footer__top-link .icon { width: 9px; height: 15px; transition: transform .5s var(--ease-out); }
.footer__top-link:hover { color: var(--ink); }
.footer__top-link:hover .icon { transform: translateY(-4px); }
.footer__legal {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  margin-top: clamp(56px, 6.4vw, 104px);
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
  letter-spacing: .04em;
  color: var(--ink-2);
}

@media (max-width: 899px) {
  .footer__top,
  .footer__cols { grid-column: 1 / -1; }
  .footer__cols { max-width: 520px; }
}

/* ------------------------------------------------------------------ motion */
@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}
@keyframes fade {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes hero-settle {
  from { transform: scale(1.06); }
  to { transform: none; }
}
@keyframes cue {
  0% { transform: translateY(-100%); }
  55% { transform: translateY(0); }
  100% { transform: translateY(100%); }
}

/* Scroll reveals: site.js only hides elements that start below the fold, so nothing flashes. */
.rv-pending { opacity: 0; transform: translateY(32px); }
.rv-in {
  transition:
    opacity 1.1s var(--ease) var(--rv-delay, 0s),
    transform 1.4s var(--ease-out) var(--rv-delay, 0s);
}

@media (prefers-reduced-motion: reduce) {
  /* transition: none rather than a tiny duration: with the default transition-property (all),
     a tiny duration would still turn every layout change into a transition. */
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition: none !important;
  }
  .hero__cue-line::after { animation: none; transform: none; opacity: .5; }
  .jg:not(.is-ready) { animation-duration: 1.2s !important; }
}
