.gallery-page { background: var(--white); }

.gallery-hero {
  position: relative;
  min-height: 74svh;
  display: flex;
  align-items: flex-end;
  background: #1f3b33 url("assets/gallery/receptions/reception-15.webp") center / cover no-repeat;
  color: var(--white);
  isolation: isolate;
}

.gallery-hero-shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(0deg, rgba(7, 23, 18, .86) 0%, rgba(7, 23, 18, .22) 68%, rgba(7, 23, 18, .36) 100%);
}

.gallery-hero-copy {
  width: var(--page);
  margin: 0 auto;
  padding: 180px 0 85px;
}

.gallery-hero h1 {
  max-width: 940px;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(72px, 10vw, 148px);
  font-weight: 400;
  line-height: .84;
  letter-spacing: 0;
}

.gallery-hero-copy > p:last-child {
  max-width: 610px;
  margin: 30px 0 0;
  font-family: var(--serif);
  font-size: clamp(20px, 2vw, 28px);
  line-height: 1.35;
}

.gallery-scroll {
  position: absolute;
  right: max(48px, calc((100% - 1320px)/2));
  bottom: 38px;
  display: inline-flex;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid rgba(255,255,255,.65);
  padding-bottom: 5px;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .07em;
}

.collection { padding: 120px max(48px, calc((100% - 1320px)/2)) 150px; }

.collection-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, .55fr);
  gap: 9vw;
  align-items: end;
  margin-bottom: 88px;
}

.collection-intro > p {
  max-width: 480px;
  margin: 0 0 8px;
  font-size: 16px;
}

.gallery-filterbar {
  position: sticky;
  top: 0;
  z-index: 12;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  margin: 0 -12px 34px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255,253,249,.95);
  padding: 13px 12px;
  backdrop-filter: blur(14px);
}

.gallery-filters { display: flex; flex-wrap: wrap; gap: 4px; }

.filter-button {
  min-height: 42px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  padding: 8px 14px;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .06em;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease;
}

.filter-button span { margin-left: 5px; color: var(--sage); font-size: 9px; }
.filter-button:hover { background: rgba(23,63,53,.08); }
.filter-button.is-active { background: var(--forest); color: var(--white); }
.filter-button.is-active span { color: rgba(255,255,255,.66); }
.visible-count { flex: 0 0 auto; margin: 0; color: #52635d; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

.collection-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }

.collection-item { position: relative; min-width: 0; aspect-ratio: 1.85 / 1; overflow: hidden; background: #d8d9d4; }
.collection-item[hidden] { display: none; }
.collection-open { position: relative; width: 100%; height: 100%; display: block; border: 0; background: transparent; padding: 0; cursor: zoom-in; }
.collection-open img { width: 100%; height: 100%; object-fit: cover; transition: transform 650ms cubic-bezier(.2,.65,.2,1), filter 350ms ease; }
.collection-open:hover img, .collection-open:focus-visible img { transform: scale(1.035); filter: saturate(1.04); }
.collection-open::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(7,23,18,.56), transparent 55%); opacity: 0; transition: opacity 250ms ease; }
.collection-open:hover::after, .collection-open:focus-visible::after { opacity: 1; }
.collection-label { position: absolute; z-index: 2; left: 17px; bottom: 14px; color: var(--white); font-size: 9px; font-weight: 750; letter-spacing: .12em; text-transform: uppercase; opacity: 0; transform: translateY(6px); transition: opacity 220ms ease, transform 220ms ease; }
.collection-open:hover .collection-label, .collection-open:focus-visible .collection-label { opacity: 1; transform: none; }
.collection-item.is-entering { animation: collection-in 430ms ease both; }

@keyframes collection-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

.gallery-cta { width: 100%; min-height: 560px; display: flex; flex-direction: column; align-items: center; justify-content: center; background: var(--forest); color: var(--white); padding: 100px 24px; text-align: center; }
.gallery-cta .display { max-width: 920px; }
.gallery-cta .button { margin-top: 42px; }

.collection-lightbox { width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; border: 0; background: rgba(8,24,20,.98); color: var(--white); padding: 52px clamp(18px, 5vw, 80px) 30px; overflow: hidden; }
.collection-lightbox::backdrop { background: rgba(8,24,20,.9); }
.collection-lightbox[open] { display: grid; grid-template-columns: 72px minmax(0,1fr) 72px; grid-template-rows: minmax(0,1fr); align-items: center; gap: 20px; }
.collection-lightbox figure { width: min(100%, 1180px); height: 100%; min-height: 0; margin: 0 auto; display: grid; grid-template-rows: minmax(0,1fr) auto; gap: 17px; }
.collection-lightbox-image { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.collection-lightbox figcaption { display: flex; justify-content: center; align-items: center; gap: 13px; text-align: center; }
.collection-lightbox figcaption strong { font-family: var(--serif); font-size: 19px; font-weight: 400; }
.collection-lightbox figcaption span { color: rgba(255,255,255,.6); font-size: 10px; font-weight: 700; letter-spacing: .11em; text-transform: uppercase; }
.collection-close, .collection-arrow { border: 1px solid rgba(255,255,255,.34); border-radius: 50%; background: transparent; color: var(--white); cursor: pointer; transition: background 180ms ease, color 180ms ease; }
.collection-close:hover, .collection-arrow:hover { background: var(--white); color: var(--ink); }
.collection-close { position: absolute; right: 24px; top: 20px; width: 48px; height: 48px; font-size: 29px; font-weight: 200; line-height: 1; }
.collection-arrow { width: 58px; height: 58px; font-size: 23px; }
.collection-count { position: absolute; left: 28px; bottom: 22px; color: rgba(255,255,255,.58); font-size: 10px; font-weight: 750; letter-spacing: .14em; }
.noscript-message { padding: 40px 0; }

@media (max-width: 980px) {
  .gallery-hero { min-height: 680px; }
  .collection { padding-left: 24px; padding-right: 24px; }
  .collection-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .collection-intro { grid-template-columns: 1fr; gap: 34px; }
  .gallery-filterbar { align-items: flex-start; flex-direction: column; gap: 4px; }
}

@media (max-width: 720px) {
  .gallery-hero { min-height: 700px; background-position: 62% center; }
  .gallery-hero-copy { padding: 150px 0 112px; }
  .gallery-hero h1 { max-width: 360px; font-size: clamp(66px, 21vw, 90px); line-height: .88; }
  .gallery-hero-copy > p:last-child { max-width: 350px; font-size: 21px; }
  .gallery-scroll { left: 18px; right: auto; bottom: 35px; }
  .collection { padding: 82px 18px 96px; }
  .collection-intro { margin-bottom: 55px; }
  .gallery-filterbar { margin: 0 -18px 18px; padding: 10px 18px; }
  .gallery-filters { width: 100%; flex-wrap: nowrap; overflow-x: auto; padding-bottom: 3px; scrollbar-width: none; }
  .gallery-filters::-webkit-scrollbar { display: none; }
  .filter-button { flex: 0 0 auto; }
  .visible-count { padding-left: 14px; }
  .collection-grid { grid-template-columns: 1fr; gap: 10px; }
  .collection-label { opacity: 1; transform: none; }
  .collection-open::after { opacity: .65; }
  .gallery-cta { min-height: 540px; }
  .collection-lightbox { padding: 68px 10px 28px; }
  .collection-lightbox[open] { grid-template-columns: 46px minmax(0,1fr) 46px; gap: 4px; }
  .collection-arrow { width: 42px; height: 42px; font-size: 19px; }
  .collection-close { right: 12px; top: 12px; width: 44px; height: 44px; }
  .collection-lightbox figcaption { flex-direction: column; gap: 1px; }
  .collection-count { left: 16px; bottom: 15px; }
}
