@font-face {
  font-family: Anybody;
  src: url('../fonts/anybody.woff2') format('woff2');
  font-weight: 100 900;
  font-stretch: 50% 150%;
  font-display: swap;
}
@font-face {
  font-family: "DM Sans";
  src: url('../fonts/dm-sans.woff2?v=2') format('woff2');
  font-weight: 100 1000;
  font-display: swap;
}
/* every lowercase r on the site keeps Anybody: this face covers only U+0072
   and sits first in the stack; size-adjust matches x-heights */
@font-face {
  font-family: "Anybody R";
  /* r-only subset of Anybody with the 86% x-height match baked into its
     units-per-em: Safari clips glyphs under size-adjust, this avoids it */
  src: url('../fonts/anybody-r.woff2?v=4') format('woff2');
  font-weight: 100 900;
  font-stretch: 50% 150%;
  font-display: swap;
  unicode-range: U+72;
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

:root {
  --bg: hsl(120 92% 50%);
  --ink: hsl(300 92% 20%);
  --css-ok: 1;
}

html { background: var(--bg); scroll-snap-type: y mandatory; scroll-behavior: smooth; overflow-x: clip; overscroll-behavior-x: none; }
#panel { overflow-x: clip; }
html.no-snap { scroll-snap-type: none; }
.hint, .badge, .letter { touch-action: manipulation; }
html[data-boot] body { visibility: hidden; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Anybody R", "DM Sans", system-ui, sans-serif;
  overflow-x: hidden;
  transition: background-color .45s ease;
}
.letter, .hint { transition: color .45s ease; }

.name {
  font-family: Anybody, system-ui, sans-serif;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  height: 100dvh;
  padding: 2dvh 3vw;
  scroll-snap-align: start;
  transition: transform .6s cubic-bezier(.2, .8, .2, 1), filter .6s, opacity .6s;
}

.word {
  display: flex;
  justify-content: space-between;
  line-height: .78;
}
.word:first-child { font-size: min(46dvh, 30vw); }
.word:last-child { font-size: min(46dvh, 24vw); }

.letter {
  all: unset;
  font: inherit;
  color: var(--ink);
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  will-change: transform;
  font-variation-settings: "wght" 650, "wdth" 110;
}

body.open .name { transform: scale(.5); filter: blur(8px); opacity: .18; }

.hint {
  position: absolute;
  left: 50%;
  top: calc(100svh - 8.5svh);
  translate: -50% 0;
  padding: 1.2dvh 5vw;
  color: var(--ink);
  text-decoration: none;
  opacity: 1;
  transition: color .45s ease, opacity .25s ease;
  font-size: 0;
  animation: bob 2.2s ease-in-out infinite;
}
.hint::before {
  content: "";
  display: block;
  width: clamp(26px, 4.5dvh, 38px);
  height: clamp(26px, 4.5dvh, 38px);
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E") no-repeat center / contain;
  transform: rotate(-90deg);
}
@keyframes bob { 50% { translate: -50% .9dvh; } }

.hint-up {
  position: absolute;
  top: calc(env(safe-area-inset-top, 0px) + 1.5dvh);
  left: 50%;
  translate: -50% 0;
  padding: 1.2dvh 5vw;
  color: var(--ink);
  font-size: 0;
  text-decoration: none;
  transition: color .45s ease;
  touch-action: manipulation;
}
.hint-up::before {
  content: "";
  display: block;
  width: clamp(26px, 4.5dvh, 38px);
  height: clamp(26px, 4.5dvh, 38px);
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E") no-repeat center / contain;
  transform: rotate(90deg);
}

.plain {
  position: relative;
  height: 100dvh;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6dvh;
  padding: 4vw;
}
.badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(16px, 3vw, 40px);
}
.badges.socials { margin-top: 4dvh; }
.badge {
  all: unset;
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
  color: var(--ink);
  border: .45vmin solid var(--ink);
  display: grid;
  place-items: center;
  cursor: pointer;
  font-family: "Anybody R", "DM Sans", system-ui, sans-serif;
  font-variation-settings: "wght" 700;
  transition: transform .15s ease;
}
@media (hover: hover) {
  .badge:hover, .badge:focus-visible {
    transform: scale(1.12) rotate(-4deg);
    outline: none;
    background: var(--ink);
    color: var(--bg);
  }
}
.badge.round {
  width: clamp(30px, 4.8vmin, 44px);
  aspect-ratio: 1;
  border: none;
}
.badge.round svg { width: 100%; height: 100%; }
@media (hover: hover) {
  .badge.round:hover, .badge.round:focus-visible {
    background: none;
    color: var(--ink);
    transform: scale(1.12) rotate(-4deg);
  }
}
.badge.pill {
  border-radius: 999px;
  inline-size: 5.9em;
  padding: clamp(11px, 1.9vmin, 17px) 0;
  font-size: clamp(1.05rem, 3.1vmin, 1.8rem);
  font-variation-settings: "wght" 430;
  line-height: 1;
  text-box: trim-both cap alphabetic;
}

#panel {
  position: fixed;
  inset: 0;
  /* own compositor layer: iOS Safari can skip painting a fixed panel inside a
     freshly position-fixed body until forced. will-change (not transform!) —
     a transform would turn the fixed lightbox/arrows into panel-scrolled ones */
  will-change: opacity;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 8vw;
  font-size: clamp(1.4rem, 4vw, 3rem);
  font-variation-settings: "wght" 640;
  background: var(--bg);
  color: var(--ink);
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  opacity: 0;
  transition: opacity .5s ease;
}
#panel.show { opacity: 1; }
#panel[data-mode="smile"],
#panel[data-mode="about"],
#panel[data-mode="contact"] { background: transparent; }
#panel #close {
  all: unset;
  position: fixed;
  z-index: 10;
  top: 2vmin;
  right: 3vmin;
  padding: 14px 18px;
  font-size: clamp(2.2rem, 7vmin, 4rem);
  line-height: 1.25;
  cursor: pointer;
  touch-action: manipulation;
  font-variation-settings: normal;
  font-weight: 700;
  font-stretch: 100%;
}
#panel #close::before {
  content: "";
  display: block;
  width: clamp(26px, 5.5vmin, 40px);
  height: clamp(26px, 5.5vmin, 40px);
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 6.4 6.4 5 12 10.6 17.6 5 19 6.4 13.4 12 19 17.6 17.6 19 12 13.4 6.4 19 5 17.6 10.6 12z'/%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 6.4 6.4 5 12 10.6 17.6 5 19 6.4 13.4 12 19 17.6 17.6 19 12 13.4 6.4 19 5 17.6 10.6 12z'/%3E%3C/svg%3E") no-repeat center / contain;
}
#panel[data-mode="works"] #close,
#panel[data-mode="about"] #close,
#panel[data-mode="contact"] #close { left: 3vmin; right: auto; }

#panel[data-mode="works"] #close::before,
#panel[data-mode="about"] #close::before,
#panel[data-mode="contact"] #close::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E");
}
@media (hover: none) {
  #panel #close { top: calc(env(safe-area-inset-top, 0px) + 10px); }
}
#panel [data-section="about"],
#panel [data-section="contact"] {
  width: min(88vw, 780px);
  height: min(74vh, 580px);
  display: grid;
  place-items: center;
  padding: clamp(24px, 4vmin, 48px);
}
#panel [data-section="about"] { background: #d9f24b; color: #142400; }
#panel [data-section="contact"] {
  background: #111;
  color: #fff;
  font-size: clamp(1.1rem, 2.6vw, 1.8rem);
  font-variation-settings: "wght" 420;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3.5vmin;
}
.mail-title {
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-variation-settings: "wght" 640;
  margin-top: clamp(10px, 3vh, 30px);
}
#mailForm {
  display: flex;
  flex-direction: column;
  gap: 13px;
  width: min(86%, 480px);
  margin-top: clamp(8px, 2.5vh, 24px);
}
#mailForm input, #mailForm textarea {
  background: #1c1c1c;
  border: 1px solid #4a4a4a;
  color: #fff;
  font-family: Anybody, system-ui, sans-serif;
  font-size: 1rem;
  font-variation-settings: "wght" 400;
  line-height: 1.5;
  padding: 12px 16px;
  outline: none;
}
#mailForm textarea { min-height: 100px; resize: vertical; }
#mailForm input:focus, #mailForm textarea:focus { border-color: #fff; }
#mailForm ::placeholder { color: #7a7a7a; }
#mailSend { align-self: center; }
#mfStatus { text-align: center; font-size: 1rem; min-height: 1.3em; }
.mail-alt {
  margin-top: calc(-1 * clamp(8px, 2vh, 18px));
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
}
.mail-or { font-size: 1rem; color: #9a9a9a; }
.mail-address {
  font-size: clamp(1.25rem, 2.6vw, 1.7rem);
  color: #111;
  background: #f7e948;
  padding: 4px 14px;
}
#mailSend {
  all: unset;
  border: 2px solid #fff;
  border-radius: 999px;
  padding: 10px 30px;
  font-size: 1.05rem;
  cursor: pointer;
  touch-action: manipulation;
  font-variation-settings: "wght" 430;
  transition: background .15s ease, color .15s ease;
}
#mailSend:hover { background: #fff; color: #111; }
#panel[data-mode="works"] { background: #fff; color: #111; place-items: start center; padding: 6vmin 6vmin 0; }
@media (max-width: 700px) {
  .name { justify-content: center; gap: 7dvh; }
  .word:first-child { font-size: min(22dvh, 28vw); }
  .word:last-child { font-size: min(22dvh, 21.5vw); }
  .plain { gap: 7dvh; }
  .badges { gap: 14px; }
  .badge.pill { font-size: 1.15rem; padding: 12px 26px; }
  .badge.round { width: 38px; }
  #panel { padding: 6vw; }
  #panel [data-section="about"],
  #panel [data-section="contact"] {
    width: 100%;
    height: auto;
    min-height: min(67vh, 570px);
  }
  #panel[data-mode="works"] { padding: 14vmin 5vw 0; }
  #lightbox { padding: 4vw; }
}
#panel .works-page { transition: filter .35s ease; will-change: filter; }
#panel.lightboxed .works-page { filter: blur(14px); pointer-events: none; }
@keyframes lbfade { from { opacity: 0; } }
#lightbox { animation: lbfade .3s ease; }
#lightbox {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 0;
  background: rgba(255, 255, 255, .88);
  cursor: pointer;
  margin: 0;
}
#lightbox[hidden] { display: none; }
/* one stable stage for every work: same footprint for portrait, landscape,
   square; shrinks before #lbContent ever scrolls */
#lbMediaStage {
  width: min(84vw, 1100px);
  height: min(72dvh, 780px);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  place-items: center;
  flex: 0 1 auto;
  min-height: 0;
}
#lbMediaStage img,
#lbMediaStage video {
  grid-area: 1 / 1;
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}
#lightbox figcaption, #lbAbout, #lbCount { flex-shrink: 0; }
#lightbox video[hidden], #lightbox img[hidden] { display: none; }
#lightbox figcaption {
  text-align: center;
  font-size: clamp(1rem, 2.6vmin, 1.5rem);
  font-variation-settings: "wght" 400;
}
#lightbox figcaption em { font-style: italic; }
#lbPrev, #lbNext {
  all: unset;
  position: fixed;
  top: 50%;
  translate: 0 -50%;
  z-index: 11;
  padding: 18px 14px;
  font-size: 0;
  cursor: pointer;
  touch-action: manipulation;
}
#lbPrev::before, #lbNext::before {
  content: "";
  display: block;
  width: clamp(24px, 4.5vmin, 34px);
  height: clamp(24px, 4.5vmin, 34px);
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M11 4 3 12l8 8 1.6-1.6L7.2 13H21v-2H7.2l5.4-5.4z'/%3E%3C/svg%3E") no-repeat center / contain;
}
#lbNext::before { transform: scaleX(-1); }
.rights {
  position: absolute;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 22px);
  left: 0;
  right: 0;
  text-align: center;
  font-size: .75rem;
  color: var(--ink);
  opacity: .75;
  transition: color .45s ease;
  font-variation-settings: "wght" 400;
}
#lbAbout {
  justify-self: center;
  width: auto;
  max-width: min(80vw, 52ch);
  text-align: center;
  text-wrap: balance;
  font-size: .85rem;
  line-height: 1.5;
  color: #444;
  font-variation-settings: "wght" 400;
}
#lbAbout:empty { display: none; }
#lbPrev { left: 1.5vmin; }
#lbNext { right: 1.5vmin; }
#panel[hidden] { display: none; }
#panel [data-section]:focus { outline: none; }
#panel [data-section][hidden] { display: none; }
body.open .hint, body.open .hint-up { visibility: hidden; }
body.open .plain { opacity: 0; pointer-events: none; }
body.scrolled .hint { opacity: 0; pointer-events: none; }
#panel a { color: var(--ink); }
#panel [data-section="about"] p {
  font-size: clamp(1.1rem, 2.6vw, 1.8rem);
  line-height: 1.4;
  max-width: 34ch;
  font-variation-settings: "wght" 420;
}

#panel [data-section="smile"] { font-size: clamp(2.2rem, 9vmin, 6rem); font-variation-settings: "wght" 420, "wdth" 110; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .name { transition: none; }
  .hint { animation: none; }
  .badge { transition: none; }
  #panel { transition: none; }
}

body.static .letter { font-variation-settings: "wght" 640, "wdth" 105; }



/* ---------- aftertaste project page (preview) ---------- */
.works-page {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  width: 100%;
  padding: 4vmin 0 0;
}
.proj-head { max-width: 620px; text-align: center; }
.proj-head { margin-bottom: 0; }
.proj-head h2 .title-apple {
  height: .96em;
  width: auto;
  display: inline-block;
  margin-left: .34em;
  vertical-align: baseline;
}
.proj-head h2 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-variation-settings: "wght" 640;
  margin-bottom: clamp(28px, 5vh, 52px);
}
.proj-dates { font-size: .95rem; color: #777; margin-bottom: 22px; font-variation-settings: "wght" 400; }
.proj-statement {
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  line-height: 1.65;
  text-align: justify;
  hyphens: auto;
  -webkit-hyphens: auto;
  color: #222;
  font-variation-settings: "wght" 400;
}
.works-sequence {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  gap: 0;
  margin-top: clamp(64px, 12vh, 120px);
}
.work-composition {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  column-gap: clamp(12px, 2vw, 32px);
  align-items: start;
  width: min(100%, 1380px);
}
.work-composition figure.work {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  min-width: 0;
}
.work-composition img,
.work-composition video {
  display: block;
  width: 100%;
  height: auto;
  cursor: pointer;
  transition: transform .3s ease;
}
.work-composition .work-open { width: 100%; }

/* narrative spacing: relationships between works, not a uniform gap */
.beat-tight { margin-top: clamp(4.5rem, 9vh, 7rem); }
.beat-standard { margin-top: clamp(7rem, 15vh, 12rem); }
.beat-chapter { margin-top: clamp(11rem, 24vh, 18rem); }

/* scale hierarchy: grid span sets the stage, scale caps the actor */
.works-sequence figure.scale-primary { max-width: min(82vw, 1260px); }
.works-sequence figure.scale-secondary { max-width: min(62vw, 900px); }
.works-sequence figure.scale-tertiary { max-width: min(34vw, 490px); }
.works-sequence figure.scale-fragment { max-width: min(24vw, 340px); }

/* monument: one work owns the viewport */
.composition-monument { width: min(100%, 1480px); }
.composition-monument figure { grid-row: 1; grid-column: 2 / 12; justify-self: center; align-items: center; }
.composition-monument.is-offset figure { grid-column: 2 / 11; justify-self: center; align-items: center; }
.composition-monument.is-left figure { grid-column: 1 / 11; justify-self: start; align-items: flex-start; }
.composition-monument.is-right figure { grid-column: 3 / 13; justify-self: end; align-items: flex-end; }
.composition-monument img,
.composition-monument video { width: auto; max-width: 100%; max-height: 82vh; margin-inline: auto; }
.composition-monument.is-left img,
.composition-monument.is-left video { margin-inline: 0 auto; }
.composition-monument.is-right img,
.composition-monument.is-right video { margin-inline: auto 0; }
.composition-monument .apple-green {
  grid-row: 1;
  grid-column: 1 / 6;
  align-self: center;
  justify-self: center;
  width: min(16vw, 230px);
  height: auto;
  max-height: none;
  margin: 0;
  cursor: default;
}
.composition-monument figure.scale-secondary img,
.composition-monument figure.scale-secondary video { max-height: 70vh; }

/* anchor and satellite: dominant work, smaller response */
.composition-anchor .pos-anchor { grid-column: 1 / 7; }
.composition-anchor .pos-satellite {
  grid-column: 9 / 13;
  align-self: end;
  justify-self: end;
  margin-top: clamp(5rem, 13vh, 10rem);
}
.composition-anchor.is-reversed .pos-anchor { grid-column: 7 / 13; justify-self: end; }
.composition-anchor.is-reversed .pos-satellite {
  grid-column: 1 / 5;
  grid-row: 1;
  justify-self: start;
  margin-top: clamp(4rem, 10vh, 8rem);
}

.composition-anchor .apple-pink {
  grid-row: 2;
  grid-column: 4 / 7;
  justify-self: center;
  width: min(11vw, 150px);
  height: auto;
  margin-top: clamp(1rem, 2.5vh, 2rem);
  position: relative;
  left: clamp(32px, 5vw, 72px);
  transform: scaleX(-1);
  cursor: default;
}

/* broken triptych: three unequal presences */
.composition-broken-trio .pos-a { grid-column: 1 / 6; margin-top: clamp(5rem, 11vh, 8rem); }
.composition-broken-trio .pos-b { grid-column: 6 / 10; }
.composition-broken-trio .pos-c { grid-column: 10 / 13; margin-top: clamp(9rem, 19vh, 14rem); }

/* witness: a small work alone in white space */
.composition-witness figure { grid-column: 2 / 5; justify-self: start; }
.composition-witness.is-centre figure { grid-column: 5 / 9; justify-self: center; }
.composition-witness.is-right figure { grid-column: 9 / 13; justify-self: end; }

/* constellation: one salon passage, two staggered rows */
.composition-constellation { grid-template-rows: auto auto; row-gap: clamp(5rem, 12vh, 9rem); }
.composition-constellation .pos-a { grid-column: 1 / 5; grid-row: 1; }
.composition-constellation .pos-b { grid-column: 6 / 9; grid-row: 1; margin-top: clamp(4rem, 9vh, 7rem); }
.composition-constellation .pos-c { grid-column: 10 / 13; grid-row: 1; margin-top: clamp(10rem, 20vh, 15rem); }
.composition-constellation .pos-d { grid-column: 4 / 7; grid-row: 2; }
.composition-constellation .pos-e { grid-column: 8 / 12; grid-row: 2; margin-top: clamp(3rem, 7vh, 5rem); }

/* reading: writing is its own spatial condition */
.composition-reading figure { grid-column: 4 / 10; justify-self: stretch; }
.composition-reading img { width: auto; max-width: 100%; max-height: 78vh; margin-inline: auto; }

/* ending: unresolved, right of centre, surrounded by air */
.composition-ending { margin-top: clamp(11rem, 25vh, 19rem); }
.composition-ending figure { grid-column: 8 / 12; justify-self: end; max-width: min(22vw, 310px); }

/* apples are decorative: immune to monument media margins */
.work-composition img.apple-green, .work-composition img.apple-pink { margin-block: 0; margin-inline: 0; }
.composition-anchor img.apple-pink { margin-top: clamp(-4.5rem, -5vh, -2.5rem); }

/* captions belong to their media */
.work.is-caption-left figcaption { text-align: left; align-self: flex-start; }
.work.is-caption-right figcaption { text-align: right; align-self: flex-end; }
.work.is-caption-centre figcaption { text-align: center; align-self: center; }

.process-note { font-size: .8rem; color: #999; letter-spacing: .12em; font-variation-settings: "wght" 400; }
.section-title .title-hl { display: inline-block; background: #f7e948; padding: 5px 12px 4px; line-height: 1.25; }
.section-title {
  width: min(100%, 1380px);
  margin-inline: auto;
  margin-bottom: clamp(3rem, 6vh, 5rem);
  padding-left: calc(100% / 24);
  text-align: left;
  font-size: clamp(1.05rem, 1.8vw, 1.45rem);
  font-variation-settings: "wght" 560;
  color: #111;
}
.works-page figcaption {
  font-size: .85rem;
  line-height: 1.45;
  color: #333;
  text-align: center;
  opacity: 1;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.cap-title {
  font-style: italic;
  font-variation-settings: "wght" 520;
  /* Anybody has no italic axis, so the browser slants glyphs; the last
     letter's overhang paints past the box and iOS clips it without this */
  padding-inline: .2em;
}
.cap-info { color: #777; font-variation-settings: "wght" 400; }
@media (hover: hover) and (pointer: fine) {
  .works-page figure.work:hover img,
  .works-page figure.work:hover video { transform: scale(1.015); }
}
#lbCount {
  position: fixed;
  left: 0;
  right: 0;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 16px);
  text-align: center;
  font-size: .8rem;
  color: #999;
  font-variation-settings: "wght" 400;
}
.works-rights {
  position: static;
  width: 100%;
  margin-top: clamp(8rem, 18vh, 13rem);
  padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 22px);
  text-align: center;
  font-size: .75rem;
  color: #8a8a8a;
  font-variation-settings: "wght" 400;
}

.letter:focus-visible,
.badge:focus-visible,
#close:focus-visible,
#lbPrev:focus-visible,
#lbNext:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 6px;
}

@media (max-width: 900px) {
  .works-sequence { margin-top: clamp(40px, 8vh, 72px); }
  .beat-tight { margin-top: clamp(3.5rem, 8vh, 5.5rem); }
  .beat-standard { margin-top: clamp(5.5rem, 12vh, 8rem); }
  .beat-chapter { margin-top: clamp(8rem, 18vh, 12rem); }
  .work-composition {
    display: flex;
    flex-direction: column;
    width: 100%;
    row-gap: clamp(3.5rem, 8vh, 5.5rem);
  }
  .work-composition figure.work { margin: 0; max-width: none; align-items: stretch; }
  .work-composition figure.work img,
  .work-composition figure.work video { width: 100%; height: auto; max-height: none; margin: 0; }
  .work-composition img.apple-green { width: 22%; align-self: flex-start; margin-inline: 4vw 0; }
  .work-composition img.apple-pink { width: 26%; align-self: center; margin-top: 0; }
  .work-composition figure.mobile-primary { width: 100%; }
  .work-composition figure.mobile-secondary { width: 82%; }
  .work-composition figure.mobile-tertiary { width: 64%; }
  .work-composition figure.mobile-fragment { width: 48%; }
  .composition-reading figure { width: 94%; }
  .work-composition figure.mobile-left { align-self: flex-start; }
  .work-composition figure.mobile-right { align-self: flex-end; }
  .work-composition figure.mobile-centre { align-self: center; }
  .composition-ending { margin-top: clamp(8rem, 18vh, 12rem); }
  .work-composition.composition-ending figure { width: 64%; max-width: none; align-self: flex-end; margin-right: 3vw; }
  .works-rights { padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 18px); }
  .section-title { width: 100%; padding-left: 2vw; margin-bottom: clamp(2rem, 4vh, 3rem); }
  #lbPrev, #lbNext {
    top: auto;
    bottom: calc(env(safe-area-inset-bottom, 0px) + 14px);
    translate: 0 0;
  }
  #lbContent { padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 88px); }
  #lbMediaStage {
    width: 88vw;
    height: min(66dvh, 620px);
  }
}
@media (max-height: 650px) {
  #lbMediaStage { height: 56dvh; }
}

.work-open {
  all: unset;
  display: block;
  cursor: pointer;
  line-height: 0;
}
.work-open:focus-visible { outline: 3px solid currentColor; outline-offset: 6px; }


#lbContent {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.2vmin;
  overflow-y: auto;
  max-height: 100dvh;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: calc(env(safe-area-inset-top, 0px) + 6vh) 5vw calc(env(safe-area-inset-bottom, 0px) + 5vh);
}

@media (prefers-reduced-motion: reduce) {
  .works-page,
  .works-page figure.work img,
  .works-page figure.work video {
    transition: none !important;
  }
  .works-page figure.work:hover img,
  .works-page figure.work:hover video {
    transform: none;
  }
  #lightbox {
    animation: none;
  }
}

.works-page img, .works-page video, #lightbox img {
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
  user-select: none;
  -webkit-user-select: none;
}
