/* Layout: fixed index column on the left, one quiet reading column on the right.
   Every project uses the same order: title, statement, photographs, film, book, exhibitions. */
:root {
  --paper: #f4f4f2;
  --ink: #181918;
  --muted: #6c6f6c;
  --rule: #d9dad6;
  --accent: #2f6a52;        /* Hong Kong tram green, used only for links on hover and the active item */
  --plate: #e8e8e5;          /* placeholder behind images while they load */
  --sans: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;
  --side: 15rem;
  --col: 38rem;             /* one width for text and every image */
  --step--1: 0.78rem;
  --step-0: 0.95rem;
  --step-1: 1.15rem;
  --step-2: clamp(1.6rem, 1.1rem + 2vw, 2.4rem);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #131413; --ink: #e6e7e3; --muted: #959893; --rule: #2c2e2c;
    --accent: #7cc0a2; --plate: #1d1f1d; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #131413; --ink: #e6e7e3; --muted: #959893; --rule: #2c2e2c;
  --accent: #7cc0a2; --plate: #1d1f1d; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 var(--step-0)/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; background: var(--plate); }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, h3 { font-weight: 500; margin: 0; text-wrap: balance; }
p { margin: 0; }

.frame {
  display: grid; grid-template-columns: var(--side) minmax(0, 1fr);
  min-height: 100vh;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}

/* ---------- index column ---------- */
.side {
  position: sticky; top: 0; align-self: start; height: 100vh; overflow-y: auto;
  padding-block: 2rem; padding-right: 1.5rem;
  display: flex; flex-direction: column; gap: 2rem;
}
.name { font-size: var(--step-1); font-weight: 500; letter-spacing: -0.01em; line-height: 1.2; }
.menu summary { display: none; }
.menu nav { display: grid; gap: 1.75rem; }
.group {
  font: 400 var(--step--1)/1 var(--mono); text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--muted); margin-top: 1rem;
}
.group:first-child { margin-top: 0; }
.side ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.3rem; }
.side li a { color: var(--muted); display: inline-block; line-height: 1.35; }
.side li a:hover { color: var(--ink); }
.side li a[aria-current="page"] { color: var(--ink); font-weight: 700; }

/* ---------- main column ---------- */
main { padding-block: 2rem 0; display: flex; flex-direction: column; gap: 6rem; min-width: 0; }
.foot {
  margin-top: auto; border-top: 1px solid var(--rule); padding-block: 1.25rem 2rem;
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  font: 400 var(--step--1)/1.4 var(--mono); color: var(--muted);
}

.label, .kicker, .meta, figcaption, dt, .list .y, .pager span, .buy, .card .m {
  font-family: var(--mono); font-size: var(--step--1); letter-spacing: 0.02em;
}
.label { text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-weight: 400;
  border-top: 1px solid var(--rule); padding-top: 0.75rem; margin-bottom: 1.75rem; }

.intro { display: grid; gap: 0.6rem; max-width: 46rem; }
.intro h1 { font-size: var(--step-2); line-height: 1.1; letter-spacing: -0.02em; }
.kicker, .meta { color: var(--muted); }
.statement { display: grid; gap: 1em; max-width: var(--col); font-size: var(--step-0); }
.statement a { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 3px; }
blockquote { margin: 0.5rem 0 0; padding-left: 1rem; border-left: 1px solid var(--rule); color: var(--muted); font-style: italic; }
blockquote cite { display: block; margin-top: 0.4rem; font: normal var(--step--1)/1.4 var(--mono); }
.credits { color: var(--muted); }
.out { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.25rem; }
.out a { text-decoration: none; color: var(--accent); }

.project, .page { display: flex; flex-direction: column; gap: 3.5rem; }

/* photographs: one per row, one consistent rhythm */
/* every image on a project page: same width as the text, left aligned, stacked under it */
.project > *, .pubs { width: 100%; max-width: var(--col); }
.series { display: grid; gap: 2.5rem; }
.plate { margin: 0; }
.project img, .pubs img { width: 100%; height: auto; }

figure { margin: 0; }
figcaption { color: var(--muted); margin-top: 0.6rem; }
.block { display: flex; flex-direction: column; }

.film { display: grid; gap: 0; }
.film + .film { margin-top: 2.5rem; }
.frame16 { position: relative; aspect-ratio: 16 / 9; max-width: 100%; background: var(--plate); }
.frame16 iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.book-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.75rem; }
.book-info { display: grid; gap: 1.25rem; min-width: 0; }
.book-info h3 { font-size: var(--step-1); line-height: 1.25; }
dl { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 0.45rem 1.25rem; margin: 0; }
dt { color: var(--muted); padding-top: 0.15em; }
dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.buy { justify-self: start; border: 1px solid var(--ink); padding: 0.55rem 0.9rem; text-transform: uppercase; letter-spacing: 0.08em; }
.buy:hover { border-color: var(--accent); }
.spreads { display: grid; gap: 2.5rem; margin-top: 2.5rem; }

.views { display: grid; gap: 2.5rem; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; border-top: 1px solid var(--rule); padding-top: 1rem; }
.pager a { display: grid; gap: 0.2rem; font-size: var(--step-1); line-height: 1.25; }
.pager a:last-child { text-align: right; }
.pager span { color: var(--muted); text-transform: uppercase; letter-spacing: 0.08em; }

/* home */
.home { display: grid; gap: 3.5rem; }
.lede { max-width: 34rem; font-size: var(--step-1); line-height: 1.45; }
.lede a { color: var(--accent); }
.grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.5rem 1.25rem; width: 70%; }
.card { display: grid; gap: 0.75rem; }
.thumb { display: block; aspect-ratio: 4 / 5; overflow: hidden; background: var(--plate); max-width: 100%; }
.thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease, opacity .3s; }
.card:hover .thumb img { transform: scale(1.025); }
.cap { display: grid; gap: 0.15rem; }
.cap .t { line-height: 1.3; }
.card .m { color: var(--muted); }

/* publications */
.pubs { list-style: none; margin: 0; padding: 0; display: grid; gap: 2.5rem; }
.pubs figcaption { display: grid; gap: 0.1rem; }
.pubs .t { color: var(--ink); font-family: var(--sans); font-size: var(--step-0); letter-spacing: 0; }

/* bio */
.contact dl { max-width: 36rem; }
.contact a { color: var(--accent); }
.cv { display: grid; grid-template-columns: minmax(0, 1fr); gap: 3.5rem; max-width: var(--col); }
.list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.list li { display: grid; grid-template-columns: 3.5rem minmax(0, 1fr); gap: 1rem; }
.list .y { color: var(--muted); font-variant-numeric: tabular-nums; padding-top: 0.2em; }

/* ---------- narrower screens ---------- */
@media (max-width: 1100px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cv { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .frame { grid-template-columns: minmax(0, 1fr); }
  .side {
    position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; height: auto; overflow: visible;
    padding-block: 1rem; padding-right: 0; gap: 0; background: var(--paper);
    flex-direction: row; justify-content: space-between; align-items: baseline; flex-wrap: wrap;
    border-bottom: 1px solid var(--rule);
  }
  body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--paper); }
  .menu summary {
    display: block; cursor: pointer; list-style: none;
    font: 400 var(--step--1)/1 var(--mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted);
  }
  .menu summary::-webkit-details-marker { display: none; }
  .menu[open] summary { color: var(--ink); }
  .menu { position: static; }
  .menu nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--paper); border-bottom: 1px solid var(--rule);
    padding: 1rem max(16px, env(safe-area-inset-right, 0px)) 1.5rem max(16px, env(safe-area-inset-left, 0px));
    max-height: 75vh; overflow-y: auto;
  }
  .menu:not([open]) nav { display: none; }
  main { padding-block: 2rem 0; gap: 4rem; }
  .series, .views, .spreads, .pubs { gap: 2rem; }
  .grid { width: 100%; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem 1rem; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* shop */
.price { font-family: var(--mono); font-size: var(--step-0); color: var(--ink); }
.shop-grid { width: 100%; max-width: var(--col); grid-template-columns: repeat(2, minmax(0, 1fr)); }
.shop-grid .thumb { aspect-ratio: 1 / 1; }
.shop-grid .thumb img { object-fit: contain; }
.shop .cap { display: grid; gap: 0.15rem; }
.shop .cap .t { line-height: 1.3; }
.kicker a:hover { color: var(--accent); }
.buy-note { color: var(--muted); }
.sel { color: var(--ink); user-select: all; }
.statement .credits a { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 3px; }

/* buttons */
.btn {
  font: 400 var(--step--1)/1 var(--mono); text-transform: uppercase; letter-spacing: 0.08em;
  padding: 0.7rem 1rem; border: 1px solid var(--ink); background: transparent; color: var(--ink); cursor: pointer;
}
.btn:hover { border-color: var(--accent); color: var(--accent); }
.btn-solid { background: var(--ink); color: var(--paper); }
.btn-solid:hover { background: var(--accent); border-color: var(--accent); color: var(--paper); }
.btn:focus-visible, .linkish:focus-visible, input:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.linkish { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; }
.linkish:hover, .foot a:hover { color: var(--accent); }
.foot-links { display: flex; gap: 1.25rem; flex-wrap: wrap; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* video placeholder until consent */
.play {
  position: absolute; inset: 0; width: 100%; display: grid; place-content: center; gap: 0.4rem;
  background: var(--plate); color: var(--ink); border: 0; cursor: pointer;
  font: 400 var(--step-0)/1.2 var(--sans);
}
.play span { font: 400 var(--step--1)/1.3 var(--mono); color: var(--muted); }
.play::before { content: "▶"; font-size: 1.5rem; color: var(--accent); }
.play:hover { color: var(--accent); }

/* newsletter */
.newsletter { max-width: var(--col); margin-top: auto; }
.newsletter form { display: grid; gap: 0.9rem; }
.nl-row { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.nl-row input {
  flex: 1 1 14rem; min-width: 0; font: inherit; color: var(--ink); background: transparent;
  border: 0; border-bottom: 1px solid var(--muted); padding: 0.55rem 0; border-radius: 0;
}
.nl-row input::placeholder { color: var(--muted); }
.nl-consent { display: flex; gap: 0.6rem; align-items: start; font-size: var(--step--1); color: var(--muted); line-height: 1.5; }
.nl-consent input { margin-top: 0.25em; accent-color: var(--accent); }
.nl-consent a { text-decoration: underline; text-underline-offset: 3px; }
.nl-msg:empty { display: none; }
.nl-msg { font-size: var(--step--1); color: var(--accent); }
.foot { margin-top: 0; }

/* cookie notice */
.consent {
  position: fixed; z-index: 20; left: 0; right: 0; bottom: 0;
  display: flex; gap: 1rem 2rem; align-items: center; justify-content: space-between; flex-wrap: wrap;
  background: var(--paper); border-top: 1px solid var(--rule);
  padding-block: 1rem calc(1rem + env(safe-area-inset-bottom, 0px));
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  box-shadow: 0 -8px 24px rgb(0 0 0 / 0.06);
}
.consent p { max-width: 46rem; font-size: var(--step--1); line-height: 1.5; }
.consent a { text-decoration: underline; text-underline-offset: 3px; }
.consent-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.consent[hidden] { display: none; }
.cap-link { color: var(--accent); }

.name { display: grid; gap: 0.35rem; }
.name .eyebrow {
  font: 400 var(--step--1)/1 var(--mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted);
}
@media (max-width: 760px) { .side { align-items: center; } }
.nl-body { display: flex; gap: 1rem 1.5rem; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.newsletter .btn { text-decoration: none; display: inline-block; }

/* home: images travel slowly in half circles across their years; oldest at left, newest on top */
.desk { list-style: none; margin: 0; padding: 0; position: relative; height: calc(100vh - 6rem); min-height: 34rem; }
.desk li { position: absolute; left: var(--x); top: var(--y); width: calc(22% * var(--s, 1)); z-index: var(--z); will-change: transform; }
.desk li.portrait { width: calc(15% * var(--s, 1)); }
.desk li.moving { left: 0; top: 0; }
.desk a { display: block; transition: transform .35s ease; }
.desk img { width: 100%; height: auto; background: none; }

.desk li:hover a, .desk li:focus-within a { transform: scale(1.04); }
@media (max-width: 760px) {
  /* phones: same motion on a tall canvas, smaller images */
  .desk { height: calc(100svh - 8rem); min-height: 30rem; }
  .desk li { width: calc(38% * var(--s, 1)); }
  .desk li.portrait { width: calc(26% * var(--s, 1)); }
}
.bio .newsletter { margin-top: 0; }
.foot a { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 3px; }

/* vertical films: as wide as fits within the screen height, left aligned */
.film.vertical .frame16 { width: min(100%, calc(85vh * 9 / 16)); }



/* newsletter form */
.nl-form { display: grid; gap: 1.1rem; }
.nl-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 1.25rem; }
.nl-fields .nl-wide { grid-column: 1 / -1; }
.nl-fields label { display: grid; gap: 0.3rem; min-width: 0; }
.nl-fields label span { font: 400 var(--step--1)/1 var(--mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.nl-fields input {
  font: inherit; color: var(--ink); background: transparent; min-width: 0; width: 100%;
  border: 0; border-bottom: 1px solid var(--muted); border-radius: 0; padding: 0.45rem 0;
}
.nl-fields input:focus { border-bottom-color: var(--accent); outline: none; }
.nl-note { font-size: var(--step--1); color: var(--muted); line-height: 1.5; }
.nl-note a { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 480px) { .nl-fields { grid-template-columns: minmax(0, 1fr); } }

/* menu in lowercase throughout */
.side nav a { text-transform: lowercase; }

/* home images stay in their own layer, so the index always sits above all of them */
.desk { isolation: isolate; }

/* titles in lowercase across the site */
.intro h1, .book-info h3, .label { text-transform: lowercase; }
.label { text-transform: uppercase; }   /* section labels keep their small capitals */
.intro h1, .book-info h3 { text-transform: lowercase; }

/* home pictures fade in as they arrive instead of popping in */
.desk img { transition: opacity .6s ease; }
.desk li:not(.loaded) img { opacity: 0; }
@media (prefers-reduced-motion: reduce) { .desk img { transition: none; } }
.nl-msg:empty { display: none; }
.nl-msg { font-size: var(--step--1); color: var(--accent); }
.nl-form button[disabled] { opacity: .6; cursor: wait; }

/* hold the pictures back for a moment while their starting places are worked out */
.desk.arranging li { opacity: 0; }
.desk li { transition: opacity .5s ease; }
