@font-face {
  font-family: Bricolage;
  src: url("fonts/bricolage-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
}

@font-face {
  font-family: Instrument;
  src: url("fonts/instrument-regular-latin.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: Instrument;
  src: url("fonts/instrument-italic-latin.woff2") format("woff2");
  font-style: italic;
  font-weight: 400;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #f8f6ef;
  --ink: #171615;
  --muted: #514e48;
  --rule: #bab5aa;
  --accent: #3022dc;
  --gutter: clamp(1.125rem, 4.5vw, 5rem);
  --sans: Bricolage, Arial, sans-serif;
  --serif: Instrument, Georgia, serif;
  --mono: "Courier New", monospace;
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 1rem/1.5 var(--sans);
}

h1, h2, p, figure, dl, dd { margin: 0; }
a { color: inherit; text-underline-offset: .22em; }
a:hover { color: var(--accent); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 5px; }
::selection { color: white; background: var(--accent); }

.shell {
  width: min(100% - 2 * var(--gutter), 88rem);
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  z-index: 5;
  top: 1rem;
  left: 1rem;
  transform: translateY(-250%);
  padding: .7rem 1rem;
  color: white;
  background: var(--accent);
}

.skip-link:focus { transform: none; color: white; }

.masthead {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 4.5625rem;
  gap: 1rem;
  border-bottom: 1px solid var(--rule);
}

.brand {
  display: inline-grid;
  min-width: 2.75rem;
  min-height: 2.75rem;
  place-items: center;
  color: var(--accent);
  font-size: 1.65rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -.115em;
  text-decoration: none;
}

.masthead nav, .footer-links { display: flex; gap: clamp(.75rem, 3.5vw, 2.75rem); }

.masthead nav a, .footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  font-size: .98rem;
  font-weight: 650;
  text-decoration: none;
}

.masthead nav [aria-current] {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 2px;
}

.masthead nav a:hover, .footer-links a:hover { text-decoration: underline; }

.intro {
  padding-block: clamp(2.5rem, 5.4vw, 5.15rem) clamp(2.3rem, 5vw, 4.8rem);
}

.intro h1 {
  display: flex;
  flex-wrap: wrap;
  column-gap: .17em;
  font-size: clamp(4.6rem, 12.15vw, 11.9rem);
  font-weight: 760;
  line-height: .83;
  letter-spacing: -.052em;
}

.intro p {
  margin-top: clamp(1.15rem, 2.3vw, 2.15rem);
  padding-inline: .11em;
  color: var(--accent);
  font: italic 400 clamp(2.2rem, 4.1vw, 4.65rem)/.99 var(--serif);
  letter-spacing: -.025em;
}

.index-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .75rem 1.25rem;
  padding-block: .75rem 1rem;
  border-top: 1px solid var(--ink);
}

.index-head h2 { font-size: 1rem; font-weight: 750; }
.index-head p, .eyebrow { color: var(--muted); font: .78rem/1.4 var(--mono); }

.work-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  align-items: start;
  column-gap: clamp(1.125rem, 2.25vw, 2.25rem);
  row-gap: clamp(2.7rem, 7.1vw, 7rem);
}

.tile { display: block; min-width: 0; text-decoration: none; }
.tile--signal, .tile--glow { grid-column: span 7; }
.tile--form, .tile--colour { grid-column: span 5; }
.tile--afterimage { grid-column: span 8; }
.tile--paper { grid-column: span 4; }
.tile--form { margin-top: clamp(1.8rem, 5vw, 4.75rem); }
.tile--paper { margin-top: clamp(1.5rem, 7vw, 7rem); }
.tile--glow { margin-top: clamp(1.5rem, 3.5vw, 4rem); }

.tile-meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .65rem;
  align-items: baseline;
  padding-block: .6rem .15rem;
}

.tile-title { font-size: clamp(1.25rem, 2.25vw, 2rem); font-weight: 750; line-height: 1; letter-spacing: -.035em; }
.tile-arrow { grid-column: 2; grid-row: 1 / 3; color: var(--accent); font-size: 1.38rem; line-height: 1; }
.tile-kind { grid-column: 1; color: var(--muted); font-size: .875rem; line-height: 1.2; }
.tile:hover .tile-title { text-decoration: underline; text-decoration-thickness: .07em; }

.cover {
  position: relative;
  display: block;
  isolation: isolate;
  container-type: inline-size;
  overflow: hidden;
  aspect-ratio: var(--cover-ratio);
  background: var(--cover-ground);
  color: var(--cover-ink, white);
}

.cover img {
  position: absolute;
  inset: var(--photo-inset, 0);
  display: block;
  width: var(--photo-width, 100%);
  height: var(--photo-height, 100%);
  object-fit: cover;
  object-position: var(--photo-position, center);
}

.cover-mark {
  position: absolute;
  inset: auto;
  font: 750 12cqw/.82 var(--sans);
  letter-spacing: -.045em;
}

.cover-signal { --cover-ratio: 1.46; --cover-ground: #1e5abe; }

.cover-signal .cover-mark {
  left: 5.4%;
  top: 8.2%;
  max-width: 62%;
  color: #fff7e7;
  font-size: 13.6cqw;
}

.signal-dot {
  position: absolute;
  top: 10%;
  right: 5.5%;
  width: 8%;
  aspect-ratio: 1;
  border: max(2px, .45cqw) solid #fff7e7;
  border-radius: 50%;
}

.cover-form {
  --cover-ratio: 1.23;
  --cover-ground: #dedcfc;
  --cover-ink: #20179c;
  --photo-inset: 21% 4.6% 5%;
  --photo-width: 90.8%;
  --photo-height: 74%;
  --photo-position: 50% 43%;
}

.cover-form .cover-mark {
  top: 5%;
  left: 4.5%;
  font: italic 400 12.6cqw/.9 var(--serif);
  letter-spacing: -.025em;
}

.cover-afterimage {
  --cover-ratio: 1.72;
  --cover-ground: #160b12;
  --photo-position: 60% 51%;
}

.cover-afterimage::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, #15070ed4, transparent 53%);
  pointer-events: none;
}

.cover-afterimage .cover-mark {
  z-index: 1;
  bottom: 7%;
  left: 5%;
  font: italic 400 19.5cqw/.78 var(--serif);
  letter-spacing: -.045em;
  color: #ffe5e9;
}

.cover-paper {
  --cover-ratio: .94;
  --cover-ground: #e9dfcf;
  --cover-ink: #28231d;
  --photo-inset: 7% 7% auto;
  --photo-width: 86%;
  --photo-height: 64%;
}

.cover-paper .cover-mark {
  bottom: 8%;
  left: 7%;
  right: 7%;
  padding-top: 4%;
  border-top: 1px solid currentColor;
  font: 400 15.5cqw/.86 var(--serif);
  letter-spacing: -.025em;
}

.cover-colour {
  --cover-ratio: 1.17;
  --cover-ground: #015977;
  --photo-position: 50% 58%;
}

.cover-colour .cover-mark {
  top: 5%;
  right: 5%;
  max-width: 54%;
  padding: 2.3% 2.8% 3.15%;
  background: #eaff49;
  color: #1f2700;
  font-size: 12cqw;
  text-align: right;
}

.cover-glow {
  --cover-ratio: 1.55;
  --cover-ground: #03060e;
  --photo-position: 58% 56%;
}

.cover-glow .cover-mark {
  top: 7%;
  left: 5%;
  max-width: 26%;
  padding-bottom: 2%;
  border-bottom: 1px solid currentColor;
  color: #e5f1ff;
  font-size: 7.5cqw;
  letter-spacing: -.045em;
  line-height: .92;
}

.project-intro { padding-block: clamp(2rem, 4.5vw, 4.7rem) clamp(1.35rem, 3.25vw, 3rem); }
.back-link { display: inline-flex; align-items: center; min-height: 2.75rem; font-weight: 700; }
.project-intro .eyebrow, .text-page .eyebrow { margin-top: 1.5rem; }

.project-intro h1, .text-page h1 {
  margin-top: .45rem;
  font-size: clamp(3.2rem, 9.7vw, 9rem);
  font-weight: 740;
  line-height: .91;
  letter-spacing: -.05em;
}

.project-figure { --detail-width: 67rem; width: min(100%, var(--detail-width)); }
.project-figure:has(.cover-form, .cover-paper) { --detail-width: 54rem; }

.photo-credit {
  padding-top: .7rem;
  color: var(--muted);
  font-size: .875rem;
}

.photo-credit a { color: var(--accent); }

.project-notes, .text-section {
  display: grid;
  grid-template-columns: minmax(8rem, 1fr) minmax(0, 2fr);
  gap: .65rem 2rem;
  max-width: 67rem;
  padding-block: 1rem 1.6rem;
  border-top: 1px solid var(--rule);
}

.project-notes { margin-top: clamp(2.2rem, 5vw, 4.75rem); }
.project-notes h2, .text-section h2 { font-size: 1rem; font-weight: 750; }
.project-notes p, .text-section p { max-width: 53ch; font-size: clamp(1.05rem, 1.6vw, 1.3rem); }

.next-project {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  gap: .35rem 1rem;
  max-width: 67rem;
  margin-top: clamp(1.75rem, 4vw, 4rem);
  border-block: 1px solid var(--rule);
  padding-block: 1rem;
  color: var(--accent);
  text-decoration: none;
}

.next-project strong { font-weight: 400; font: 400 clamp(2.1rem, 5vw, 4.5rem)/.95 var(--serif); }
.next-project:hover strong { text-decoration: underline; text-decoration-thickness: .045em; }

.text-page { padding-top: clamp(2.5rem, 8vw, 7.5rem); }
.text-page .eyebrow { margin-top: 0; }

.page-lede {
  max-width: 28ch;
  margin-block: .65em 1.15em;
  color: var(--accent);
  font: italic 400 clamp(2rem, 4.2vw, 4.2rem)/1.04 var(--serif);
  letter-spacing: -.015em;
}

.text-section a { color: var(--accent); }
.text-section p + p { margin-top: .75rem; }
.text-section:target { scroll-margin-block: 1.5rem; }

.site-footer {
  margin-top: clamp(3rem, 9vw, 8.25rem);
  background: var(--accent);
  color: white;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .5rem 2rem;
  min-height: 6.2rem;
  padding-block: .85rem;
}

.footer-name { font: 400 clamp(1.85rem, 3.5vw, 3.15rem)/1 var(--serif); }
.site-footer a:hover, .site-footer a:focus-visible { color: white; }
.site-footer :focus-visible { outline-color: white; }

@media (prefers-reduced-motion: no-preference) {
  .tile-arrow { transition: transform .17s ease-out; }
  .tile:hover .tile-arrow { transform: translate(.12em, -.12em); }
}

@media (max-width: 50rem) {
  .masthead { min-height: 3.7rem; }
  .work-grid { grid-template-columns: 1fr 1fr; }
  .tile { grid-column: span 1; }
  .tile--paper, .tile--glow { margin-top: 2rem; }
}

@media (max-width: 39rem) {
  .intro h1 { flex-direction: column; font-size: clamp(4.3rem, 16.5vw, 7.4rem); line-height: .86; }
  .intro p { font-size: clamp(2.2rem, 9vw, 3.25rem); }
  .work-grid { grid-template-columns: minmax(0, 1fr); }
  .tile { grid-column: 1; margin-top: 0; }
  .tile--form, .tile--paper { margin-left: clamp(0rem, 5vw, 1.5rem); }
  .tile--colour { margin-right: clamp(0rem, 5vw, 1.5rem); }
  .tile-meta { column-gap: .55rem; }
  .project-notes, .text-section { grid-template-columns: minmax(0, 1fr); }
  .next-project { grid-template-columns: 1fr auto; }
  .next-project .eyebrow { grid-column: 1 / -1; }
  .footer-inner { display: block; }
  .footer-links { margin-top: .3rem; }
}
