/* Gallery pages */

.gallery-page,
.editorial-page {
  padding: calc(var(--header-height) + clamp(58px, 8vw, 118px)) var(--page-gutter) clamp(80px, 10vw, 150px);
}

.page-heading {
  display: grid;
  max-width: 1600px;
  margin: 0 auto clamp(52px, 8vw, 124px);
  align-items: end;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  gap: 8vw;
}

.eyebrow,
.section-number {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.page-heading h1,
.editorial-heading h1 {
  margin: 0;
  font-size: clamp(48px, 8.5vw, 138px);
  font-weight: 300;
  letter-spacing: -0.065em;
  line-height: 0.88;
}

.gallery-grid {
  max-width: 1800px;
  margin: 0 auto;
  columns: 2;
  column-gap: clamp(8px, 0.9vw, 16px);
}

.gallery-item {
  position: relative;
  display: block;
  width: 100%;
  margin: 0 0 clamp(8px, 0.9vw, 16px);
  padding: 0;
  break-inside: avoid;
  overflow: hidden;
  background: #161616;
  cursor: zoom-in;
  text-align: left;
}

.gallery-item img {
  width: 100%;
  height: auto;
  transition: transform 650ms var(--ease-out), filter 500ms ease;
}

.gallery-item > span {
  position: absolute;
  right: 12px;
  bottom: 10px;
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  opacity: 0;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.25);
  font-size: 8px;
  letter-spacing: 0.06em;
  backdrop-filter: blur(8px);
  transition: opacity 220ms ease;
}

.gallery-item:hover img {
  transform: scale(1.015);
  filter: brightness(0.82);
}

.gallery-item:hover > span {
  opacity: 1;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 650ms ease, transform 650ms var(--ease-out);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.lightbox {
  width: 100vw;
  max-width: none;
  height: 100vh;
  max-height: none;
  margin: 0;
  padding: 26px var(--page-gutter);
  border: 0;
  background: rgba(5, 5, 5, 0.98);
  color: var(--text);
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.95);
}

.lightbox[open] {
  display: grid;
  align-items: center;
  grid-template-columns: 52px 1fr 52px;
}

.lightbox figure {
  display: grid;
  height: calc(100vh - 90px);
  margin: 30px 0 0;
  place-items: center;
}

.lightbox figure img {
  max-width: calc(100vw - 190px);
  max-height: calc(100vh - 135px);
  object-fit: contain;
}

.lightbox figcaption {
  position: absolute;
  bottom: 18px;
  left: 50%;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transform: translateX(-50%);
}

.lightbox button {
  background: transparent;
  cursor: pointer;
}

.lightbox__previous,
.lightbox__next {
  width: 48px;
  height: 48px;
  font-size: 22px;
  opacity: 0.7;
  transition: opacity 180ms ease;
}

.lightbox__previous:hover,
.lightbox__next:hover {
  opacity: 1;
}

.lightbox__close {
  position: absolute;
  z-index: 1;
  top: 20px;
  right: var(--page-gutter);
  padding: 8px 0;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.lightbox__close span {
  margin-left: 8px;
  font-size: 18px;
}
