:root {
  --wall: #252525;           /* the wall of the gallery (the site's own ground) */
  --wall-lit: #34302b;       /* the warm light from the ceiling track */
  --wall-deep: #1b1a19;      /* the corners of the room */
  --paper: #ece7dd;          /* words, and the paper border of the prints */
  --muted: #8f8a82;          /* quiet words: years, labels */
  --accent: #c9a27a;         /* one warm accent, like a tungsten lamp */
  --veil: #141312;           /* the room dims behind an open print */
  --serif: 'Newsreader Variable', Georgia, serif;
  --sans: 'Instrument Sans Variable', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--wall); color: var(--paper); font-family: var(--sans); overflow: hidden; -webkit-font-smoothing: antialiased; }

.stage { position: relative; height: 100vh; min-height: 300px; overflow: hidden; isolation: isolate; }

/* ---------------------------------------------------------------- the wall: warm light, corners and grain */
.wall-bg { position: absolute; inset: 0; z-index: 0; background: var(--wall); }
.wall-bg__light { position: absolute; inset: 0;
  background:
    radial-gradient(70% 55% at 50% 0%, var(--wall-lit), transparent 70%),
    radial-gradient(120% 100% at 50% 50%, transparent 55%, var(--wall-deep) 100%); }
.wall-bg__grain { position: absolute; inset: -40px; opacity: .07; mix-blend-mode: screen; pointer-events: none; background-size: 180px 180px; }
.wall-bg__grain.is-moving { animation: grain .5s steps(4) infinite; }
@keyframes grain {
  0% { transform: translate(0, 0); } 25% { transform: translate(-22px, 13px); }
  50% { transform: translate(17px, -9px); } 75% { transform: translate(-8px, -21px); } 100% { transform: translate(0, 0); }
}

/* ---------------------------------------------------------------- header */
.head { position: absolute; z-index: 2; top: 0; left: 0; right: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: clamp(12px, 3vh, 24px) clamp(14px, 3.4vw, 32px); }
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand__mark { width: 24px; height: 24px; flex: none; fill: none; stroke: var(--paper); stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.brand__words { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-family: var(--serif); font-size: 19px; font-weight: 380; font-variation-settings: 'opsz' 48; letter-spacing: -.005em; }
.brand__sub { margin-top: 4px; font-size: 8.5px; letter-spacing: .26em; text-transform: uppercase; color: var(--muted); }
.head__where { display: inline-flex; align-items: center; gap: 10px; font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.head__sep { width: 1px; height: 10px; background: currentColor; opacity: .5; }

/* ---------------------------------------------------------------- the prints (the photos are drawn in WebGL on top) */
.wall { position: absolute; inset: 0; z-index: 1; }
.print { position: absolute; left: 0; top: 0; padding: 0; margin: 0; border: 0; background: transparent; cursor: pointer;
  -webkit-tap-highlight-color: transparent; }
.print img { display: block; width: 100%; height: 100%; object-fit: cover; opacity: 0; border: var(--mat, 6px) solid var(--paper);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 14px 30px rgba(0, 0, 0, .35); transition: opacity .5s; }
.stage.no-gl .print img { opacity: 1; }
.print:focus-visible { outline: 1px solid var(--accent); outline-offset: 6px; }

.label { position: absolute; left: 0; top: 0; margin: 0; pointer-events: none; display: flex; flex-direction: column; gap: 3px; line-height: 1.2;
  transition: opacity .5s; }
.label__title { font-family: var(--serif); font-style: italic; font-size: 13px; font-weight: 360; color: var(--paper); opacity: .62;
  transition: opacity .45s, transform .6s cubic-bezier(.34, 1.56, .64, 1); }
.label__year { font-size: 9px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); transition: color .45s; }
.label.is-hover .label__title { opacity: 1; transform: translateX(3px); }
.label.is-hover .label__year { color: var(--accent); }
.stage.is-narrow .label, .stage.is-narrow .hint { display: none; }

.hint { position: absolute; z-index: 1; left: 50%; bottom: clamp(10px, 2.6vh, 22px); transform: translateX(-50%); margin: 0; white-space: nowrap;
  font-size: 9.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }

/* ---------------------------------------------------------------- the open print */
.veil { position: absolute; inset: 0; z-index: 3; background: var(--veil); opacity: 0; pointer-events: none; }
.gl { position: absolute; inset: 0; z-index: 4; width: 100%; height: 100%; display: block; pointer-events: none; }
.big { position: absolute; z-index: 4; left: 0; top: 0; object-fit: cover; border: 6px solid var(--paper); opacity: 0; pointer-events: none;
  box-shadow: 0 30px 70px rgba(0, 0, 0, .5); }

.box { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
.box[hidden] { display: none; }
.cap { position: absolute; left: 0; top: 0; pointer-events: auto; }
.cap__room { margin: 0 0 10px; font-size: 9px; letter-spacing: .26em; text-transform: uppercase; color: var(--accent); }
.cap__title { margin: 0; font-family: var(--serif); font-weight: 340; font-size: clamp(20px, min(3vw, 4.6vh), 34px); line-height: 1.08;
  font-variation-settings: 'opsz' 60; letter-spacing: -.01em; }
.cap__meta { display: flex; align-items: center; gap: 10px; margin: 12px 0 0; font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--paper); opacity: .82; }
.cap__sep { width: 1px; height: 10px; background: var(--muted); }
.cap__size { margin: 6px 0 0; font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.cap__note { max-width: 24em; margin: 14px 0 0; font-family: var(--serif); font-style: italic; font-size: 14px; line-height: 1.45; font-weight: 340; color: var(--paper); opacity: .78; }

.close { display: inline-flex; align-items: center; gap: 9px; margin-top: 22px; height: 36px; padding: 0 18px 0 14px; border-radius: 99px; cursor: pointer;
  border: 1px solid rgba(236, 231, 221, .22); background: linear-gradient(to bottom, rgba(255, 255, 255, .07), rgba(255, 255, 255, .02));
  color: var(--paper); font: 500 10px/1 var(--sans); letter-spacing: .22em; text-transform: uppercase;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 10px 24px rgba(0, 0, 0, .25);
  transition: transform .45s cubic-bezier(.34, 1.56, .64, 1), border-color .4s, background-color .4s; -webkit-tap-highlight-color: transparent; }
.close svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; transition: transform .6s cubic-bezier(.34, 1.56, .64, 1); }
.close__word { display: inline-flex; }
.close__word span { display: inline-block; }
.close.is-hover { border-color: rgba(201, 162, 122, .7); }
.close.is-hover svg { transform: rotate(90deg); color: var(--accent); }
@media (hover: hover) {
  .close:hover { border-color: rgba(201, 162, 122, .7); }
  .close:hover svg { transform: rotate(90deg); color: var(--accent); }
}
.close:active, .close.is-pressed { transform: scale(.95); transition-duration: .12s; }
.close:focus-visible { outline: 1px solid var(--accent); outline-offset: 3px; }

/* ---------------------------------------------------------------- the drawn pointer of the autopilot */
.hand { position: absolute; z-index: 8; left: 0; top: 0; width: 22px; height: 22px; pointer-events: none; opacity: 0;
  fill: #fff; stroke: #1c1b1a; stroke-width: 1.2; stroke-linejoin: round; filter: drop-shadow(0 3px 5px rgba(0, 0, 0, .4)); }

@media (max-width: 560px) {
  .head__where span:last-child, .head__sep { display: none; }
  .cap__note { display: none; }
  .close { margin-top: 12px; height: 32px; }
  .cap__meta { margin-top: 8px; }
  .cap__room { margin-bottom: 6px; }
}
@media (max-height: 460px) {
  .cap__note { display: none; }
  .hint { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .wall-bg__grain.is-moving { animation: none; }
  .label__title, .close, .close svg { transition-property: opacity, color, border-color; }
}
