:root {
  --ink: #151515;
  --muted: #858585;
  --faint: #d8d8d4;
  --paper: #f8f8f6;
  --timeline-width: 14rem;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 20;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 1.45rem 1.7rem;
  mix-blend-mode: difference;
  color: #fff;
  pointer-events: none;
}

.site-name,
.site-nav { pointer-events: auto; }

.site-name {
  font-size: 1.18rem;
  font-weight: 700;
  letter-spacing: .01em;
  text-decoration: none;
}

.site-nav {
  display: flex;
  gap: 1.25rem;
  font-size: .82rem;
}

.site-nav a { text-decoration: none; }

.archive {
  padding: 15vh calc(var(--timeline-width) + 5vw) 16vh 5vw;
}

.work-entry {
  min-height: 78vh;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.work-link {
  width: min(55vw, 45rem);
  text-decoration: none;
}

.work-link img {
  display: block;
  width: 100%;
  height: auto;
}

.work-caption {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: .8rem;
  font-size: .82rem;
  line-height: 1.35;
}

.work-years { color: var(--muted); white-space: nowrap; }

.timeline {
  position: fixed;
  z-index: 10;
  top: 14vh;
  right: 2.2rem;
  bottom: 10vh;
  width: var(--timeline-width);
  pointer-events: none;
}

.timeline-line,
.timeline-range {
  position: absolute;
  right: 1.8rem;
  width: 1px;
}

.timeline-line {
  inset-block: 0;
  background: var(--faint);
}

.timeline-range {
  top: var(--range-start, 100%);
  height: var(--range-height, 0%);
  min-height: 3px;
  background: var(--ink);
  transition: top .55s ease, height .55s ease;
}

.year-mark {
  position: absolute;
  right: 2.45rem;
  transform: translateY(-50%);
  font-size: .73rem;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-style: normal;
  color: #aaa;
  transition: color .4s ease;
}

.year-mark.active { color: var(--ink); }

.timeline-title {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 8.4rem;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-style: normal;
  font-size: .95rem;
  line-height: 1.25;
}

.timeline-title span {
  display: block;
  margin-top: .35rem;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: .68rem;
  color: var(--muted);
}

.work-page { background: #fff; }

.back-link {
  position: fixed;
  z-index: 22;
  top: 1.5rem;
  left: 1.7rem;
  font-size: .82rem;
  text-decoration: none;
}

.project-hero {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(18rem, .8fr);
  gap: 5vw;
  align-items: center;
  padding: 6rem 5vw 5rem;
}

.project-hero img {
  display: block;
  width: 100%;
  max-height: 82vh;
  object-fit: contain;
}

.project-title {
  margin: 0 0 1.2rem;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: clamp(2.2rem, 4vw, 4.5rem);
  font-weight: 500;
  line-height: .96;
}

.project-meta {
  font-size: .82rem;
  line-height: 1.55;
  color: #555;
}

.project-text {
  display: grid;
  grid-template-columns: 1fr minmax(20rem, 39rem) 1fr;
  padding: 12vh 5vw 18vh;
}

.project-text-inner { grid-column: 2; }

.project-text p {
  margin: 0 0 1.4rem;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
}

.project-text em { font-style: normal; }

.caption-action {
  display: block;
  margin-top: .3rem;
  font-size: .7rem;
  color: var(--muted);
}

.exhibition-note {
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid #ddd;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif !important;
  font-size: .78rem !important;
  color: #666;
}

.documentation {
  padding: 0 5vw 12vh;
}

.doc-image {
  display: block;
  width: min(66vw, 58rem);
  height: auto;
  margin-bottom: 15vh;
}

.doc-image:nth-child(even) { margin-left: auto; width: min(46vw, 40rem); }
.doc-image:last-child { margin-bottom: 0; }

.credit {
  padding: 0 5vw 3rem;
  font-size: .7rem;
  color: #888;
}

@media (max-width: 760px) {
  :root { --timeline-width: 0; }

  .site-header {
    padding: 1.1rem 1rem;
    mix-blend-mode: normal;
    color: var(--ink);
    background: linear-gradient(var(--paper) 55%, transparent);
  }

  .site-nav { gap: .8rem; }

  .archive { padding: 7rem 1rem 8rem; }
  .work-entry { min-height: 66vh; }
  .work-link { width: 100%; }

  .timeline {
    top: auto;
    left: 1rem;
    right: 1rem;
    bottom: .9rem;
    width: auto;
    height: 3.7rem;
    background: rgba(248,248,246,.94);
  }

  .timeline-line,
  .timeline-range {
    top: 1.1rem;
    bottom: auto;
    height: 1px;
  }

  .timeline-line { left: 0; right: 0; width: auto; }
  .timeline-range {
    left: var(--mobile-start, 100%);
    width: var(--mobile-width, 0%);
    min-width: 3px;
    transition: left .55s ease, width .55s ease;
  }

  .year-mark {
    top: 1.9rem !important;
    right: auto;
    transform: translateX(-50%);
    font-size: .62rem;
  }

  .timeline-title { display: none; }

  .back-link {
    top: 1.1rem;
    left: 1rem;
    padding: .35rem .5rem;
    background: rgba(255,255,255,.85);
  }

  .project-hero {
    min-height: auto;
    display: block;
    padding: 4.7rem 1rem 5rem;
  }

  .project-hero img { max-height: none; }
  .project-info { margin-top: 2.2rem; }
  .project-title { font-size: 2.65rem; }

  .project-text {
    display: block;
    padding: 3rem 1rem 7rem;
  }

  .project-text p { font-size: 1.04rem; }
  .documentation { padding: 0 1rem 7rem; }
  .doc-image,
  .doc-image:nth-child(even) {
    width: 100%;
    margin: 0 0 5rem;
  }
  .credit { padding: 0 1rem 2rem; }
}
