/* Gallery — a pale wall, an uneven hang, a small label beside each work.
   The interface stays quiet: one small sans, one light serif, no boxes or buttons. */
:root {
  --wall: #eeece6;
  --ink: #23211d;
  --muted: #68645c;
  --hairline: #d8d5cc;
  --accent: #a83a1b;
  --serif: "Spectral", Georgia, serif;
  --sans: "Hanken Grotesk", system-ui, sans-serif;
  --wrap: 92rem;
  --hang-shadow: 0 1px 2px rgb(45 40 30 / 0.16), 0 20px 34px -22px rgb(45 40 30 / 0.45);
}

* {
  box-sizing: border-box;
}
html {
  background: var(--wall);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
body {
  margin: 0;
  overflow-wrap: break-word;
}
a {
  color: inherit;
  text-decoration: none;
}
a:hover {
  color: var(--accent);
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
img {
  max-width: 100%;
  display: block;
}
h1,
h2,
h3 {
  font-weight: 300;
}
.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: clamp(1.25rem, 5vw, 5rem);
  padding-right: clamp(1.25rem, 5vw, 5rem);
}
.muted,
.empty {
  color: var(--muted);
}

/* The masthead: three small things in one line, nothing more. */
.masthead {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.5rem;
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
  font-size: 0.875rem;
}
.brand {
  margin-right: auto;
  font-weight: 500;
}
.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  color: var(--muted);
}

/* The statement on the home page: short, and set like a wall text. */
.statement {
  max-width: 24ch;
  margin: clamp(2.5rem, 9vw, 7rem) 0 clamp(3rem, 8vw, 6.5rem);
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.6rem, 3.4vw, 2.6rem);
  line-height: 1.2;
}

/* A work on the wall. Real images keep their own proportions, nothing is cropped;
   a work without an image shows a horizon in one of the tones below. */
.print {
  display: block;
  width: 100%;
  height: auto;
  box-shadow: var(--hang-shadow);
}
.blank {
  aspect-ratio: 4 / 3;
}

/* The hang: six placements that repeat, so any number of works stays uneven. */
.wall {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: clamp(2.75rem, 7vw, 4rem) 0;
  align-items: start;
}
.wall > .empty {
  grid-column: 1 / -1;
}
.hang {
  min-width: 0;
}
.hang-link {
  display: block;
}
.hang:nth-child(3n + 1) {
  grid-column: 1 / -1;
}
.hang:nth-child(3n + 2) {
  grid-column: 1 / span 4;
}
.hang:nth-child(3n + 3) {
  grid-column: 3 / span 4;
}
.hang:nth-child(6n + 1) .blank {
  aspect-ratio: 3 / 2;
}
.hang:nth-child(6n + 2) .blank {
  aspect-ratio: 4 / 5;
}
.hang:nth-child(6n + 3) .blank {
  aspect-ratio: 1;
}
.hang:nth-child(6n + 4) .blank {
  aspect-ratio: 5 / 4;
}
.hang:nth-child(6n + 5) .blank {
  aspect-ratio: 4 / 5;
}
.hang:nth-child(6n + 6) .blank {
  aspect-ratio: 2 / 1;
}
@media (min-width: 48rem) {
  .wall {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: clamp(1rem, 2vw, 2rem);
    row-gap: clamp(3rem, 6vw, 6rem);
  }
  .hang:nth-child(6n + 1) {
    grid-column: 1 / span 7;
  }
  .hang:nth-child(6n + 2) {
    grid-column: 9 / span 4;
    margin-top: clamp(4rem, 12vw, 11rem);
  }
  .hang:nth-child(6n + 3) {
    grid-column: 3 / span 4;
  }
  .hang:nth-child(6n + 4) {
    grid-column: 8 / span 5;
    margin-top: clamp(3rem, 8vw, 7rem);
  }
  .hang:nth-child(6n + 5) {
    grid-column: 1 / span 4;
    margin-top: clamp(1rem, 3vw, 3rem);
  }
  .hang:nth-child(6n + 6) {
    grid-column: 6 / span 7;
    margin-top: clamp(5rem, 14vw, 13rem);
  }
}

/* The wall label: small, close to the work, like the card beside a frame. */
.label {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0 1.25rem;
  margin-top: 0.75rem;
  font-size: 0.875rem;
}
.label-title {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1rem;
}
.label-price {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.hang-link:hover .label-title {
  color: var(--accent);
}

.onward {
  margin: clamp(2.5rem, 5vw, 4.5rem) 0 0;
  font-size: 0.875rem;
  text-align: right;
}
.onward a {
  text-decoration: underline;
  text-decoration-color: var(--hairline);
  text-underline-offset: 4px;
}
.onward-inline {
  margin-top: 1.5rem;
  text-align: left;
}

/* The latest series on the home page. */
.latest {
  margin-top: clamp(4.5rem, 12vw, 10rem);
}
.quiet-heading {
  margin: 0 0 1.25rem;
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--muted);
}
.latest-series,
.series {
  display: grid;
  gap: 1.25rem;
  align-items: end;
}
.latest-media,
.series-media {
  display: block;
  min-width: 0;
}
.series-title {
  margin: 0 0 0.5rem;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  line-height: 1.15;
}
.latest-text p,
.series-text p {
  max-width: 36rem;
}
.latest-text .muted,
.series-text .muted {
  margin-top: 0;
  margin-bottom: 0;
}
.date {
  margin: 0 0 0.5rem;
  font-size: 0.875rem;
  color: var(--muted);
}
@media (min-width: 48rem) {
  .latest-series {
    grid-template-columns: minmax(0, 8fr) minmax(0, 4fr);
    gap: clamp(1.5rem, 4vw, 4rem);
  }
  .latest-media .blank {
    aspect-ratio: 16 / 9;
  }
}

/* Room headings: as small as the labels, the works do the talking. */
.room-title {
  margin: clamp(2rem, 5vw, 4rem) 0 clamp(2rem, 5vw, 4rem);
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.6rem, 3.4vw, 2.6rem);
  line-height: 1.2;
}
.room-head {
  margin-bottom: clamp(2.5rem, 6vw, 5rem);
}
.room-head .room-title {
  margin-bottom: 0.75rem;
}
.room-intro {
  max-width: 36rem;
  margin: 0;
}

/* The series index: one work per row, stepping from side to side. */
.series-list {
  display: grid;
  gap: clamp(3.5rem, 9vw, 8rem);
}
.series-list > .empty {
  margin: 0;
}
@media (min-width: 48rem) {
  .series {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: clamp(1rem, 2vw, 2rem);
  }
  .series-media {
    grid-column: 1 / span 7;
  }
  .series-text {
    grid-column: 9 / span 4;
  }
  .series:nth-child(even) .series-media {
    grid-column: 6 / span 7;
    grid-row: 1;
  }
  .series:nth-child(even) .series-text {
    grid-column: 1 / span 4;
    grid-row: 1;
  }
  .series:nth-child(6n + 3) .series-media {
    grid-column: 3 / span 5;
  }
  .series:nth-child(6n + 3) .blank {
    aspect-ratio: 1;
  }
}

/* A single work: the print large, with its label at the lower edge. */
.work {
  display: grid;
  gap: 1.5rem;
  padding-top: clamp(1rem, 4vw, 3.5rem);
}
.work-media {
  display: grid;
  gap: clamp(1.5rem, 4vw, 3rem);
  min-width: 0;
}
.work-blank {
  aspect-ratio: 5 / 4;
}
.work-title {
  margin: 0 0 0.75rem;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.5rem;
  line-height: 1.2;
}
.work-price {
  margin: 1rem 0;
  font-variant-numeric: tabular-nums;
}
.work-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin: 0;
  font-size: 0.875rem;
  color: var(--muted);
}
.enquire {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}
@media (min-width: 48rem) {
  .work {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: clamp(1rem, 2vw, 2rem);
    align-items: end;
  }
  .work-media {
    grid-column: 1 / span 8;
  }
  .work-label {
    position: sticky;
    bottom: 2rem;
    grid-column: 9 / span 4;
    padding-left: clamp(0.5rem, 2vw, 2rem);
  }
}

/* Pages and series texts: title on one side, reading column on the other. */
.sheet {
  display: grid;
  gap: 1.25rem;
  padding-top: clamp(2rem, 5vw, 4rem);
}
.sheet-title {
  margin: 0 0 0.5rem;
  font-family: var(--serif);
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  line-height: 1.1;
}
@media (min-width: 48rem) {
  .sheet {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: clamp(1rem, 2vw, 2rem);
  }
  .sheet > * {
    grid-column: 6 / span 6;
    min-width: 0;
  }
  .sheet > .sheet-title,
  .sheet > .sheet-side {
    grid-column: 1 / span 4;
  }
}
.exhibition-cover {
  margin-top: clamp(0.5rem, 3vw, 2rem);
}
.exhibition-cover.blank {
  aspect-ratio: 2 / 1;
}
.lede {
  margin: 0 0 1.5rem;
  font-family: var(--serif);
  font-size: 1.3rem;
  line-height: 1.4;
}
.prose {
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.65;
}
.prose > :first-child {
  margin-top: 0;
}
.prose p {
  margin: 0 0 1.1em;
}
.prose h2,
.prose h3 {
  margin: 2em 0 0.4em;
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.4;
}
.prose blockquote {
  margin: 1.5em 0;
  font-style: italic;
  font-size: 1.3rem;
  line-height: 1.35;
}
.prose ul,
.prose ol {
  padding-left: 1.25rem;
}
.prose img {
  height: auto;
  margin: 2em 0;
}
.prose a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.prose-small {
  font-size: 1rem;
  line-height: 1.5;
}
.prose-small p {
  margin-bottom: 0.6em;
}

.colophon {
  margin-top: clamp(5rem, 12vw, 10rem);
  padding-top: 1.5rem;
  padding-bottom: 2.5rem;
  font-size: 0.8125rem;
  color: var(--muted);
}
.colophon p {
  max-width: 40rem;
  margin: 0 0 0.25rem;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: clamp(3rem, 7vw, 5rem);
  font-size: 0.875rem;
}
.pagination-status {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.pagination-link:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* The language switcher; only there on a site with several languages. */
.lang-switch {
  display: inline-flex;
  gap: 0.5rem;
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
}
.lang-switch a {
  color: var(--muted);
}
.lang-switch a:hover,
.lang-switch a[aria-current] {
  color: var(--ink);
}

/* The stand-ins for works without an image: seven river horizons in the manner of a
   long exposure, sky above and water below, each with its own light and horizon height. */
.tone-0 {
  background: linear-gradient(180deg, #d4d4cf 0%, #c3c4c0 56%, #a9acaa 58%, #989c9b 100%);
}
.tone-1 {
  background: linear-gradient(
    180deg,
    #3b3744 0%,
    #7a5350 38%,
    #bd7a52 49%,
    #5a4441 50.5%,
    #2e2b31 100%
  );
}
.tone-2 {
  background: linear-gradient(
    180deg,
    #1c2a3c 0%,
    #41607a 62%,
    #6f8ca1 66%,
    #2c3f52 67.5%,
    #151e29 100%
  );
}
.tone-3 {
  background: linear-gradient(
    180deg,
    #c9c3ac 0%,
    #b5ae95 24%,
    #8f8970 26%,
    #6d6853 60%,
    #4f4c3d 100%
  );
}
.tone-4 {
  background: linear-gradient(
    180deg,
    #e3d3c6 0%,
    #d6b9a9 42%,
    #c9a595 45%,
    #8f837c 47%,
    #6f6a67 100%
  );
}
.tone-5 {
  background:
    radial-gradient(circle at 18% 55%, rgb(244 178 92 / 0.9) 0, rgb(244 178 92 / 0) 2.5%),
    radial-gradient(circle at 34% 55%, rgb(244 178 92 / 0.75) 0, rgb(244 178 92 / 0) 2%),
    radial-gradient(circle at 71% 55%, rgb(244 178 92 / 0.9) 0, rgb(244 178 92 / 0) 3%),
    linear-gradient(180deg, #0f1115 0%, #231d1b 50%, #4b3322 55%, #17140f 57%, #0b0c0f 100%);
}
.tone-6 {
  background: linear-gradient(
    180deg,
    #a5b3aa 0%,
    #c6cdc0 71%,
    #d8dacb 73%,
    #67766f 74.5%,
    #47564f 100%
  );
}

@media (prefers-reduced-motion: no-preference) {
  .hang-link .print {
    transition: transform 0.4s ease;
  }
  .hang-link:hover .print {
    transform: translateY(-3px);
  }
}
