/* Gallery page. Shares tokens, nav, buttons and footer with style.css. */
body.gal { background: var(--ivory); color: var(--graphite); }
.gal__nav { position: fixed; }
.gal__main { max-width: 1320px; margin: 0 auto; padding: 132px var(--gutter) 72px; }
.gal__title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.6rem, 7vw, 5.4rem); line-height: .98; letter-spacing: -.01em; margin: 14px 0 12px; }
.gal__title em { color: var(--slate); }
.gal__lede { max-width: 46ch; opacity: .75; }

.gal__filters { display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: end; justify-content: space-between; margin: 36px 0 30px; }
.gal__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.gal__chips button { font: inherit; font-size: .88rem; font-weight: 600; padding: 9px 18px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: inherit; cursor: pointer; transition: background .3s, color .3s; }
.gal__chips button:hover { background: color-mix(in srgb, var(--graphite) 8%, transparent); }
.gal__chips button.is-active { background: var(--graphite); color: var(--ivory); border-color: var(--graphite); }
.gal__select { display: grid; gap: 4px; font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; opacity: .9; }
.gal__select select { font: inherit; font-size: .95rem; letter-spacing: 0; text-transform: none; padding: 10px 14px; min-width: 240px; border-radius: 12px; border: 1px solid var(--line); background: var(--ivory); color: var(--graphite); }

.gal__cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 22px 18px; }
.gcard { text-align: left; font: inherit; color: inherit; background: none; border: 0; cursor: pointer; display: grid; gap: 6px; }
.gcard__img { aspect-ratio: 4 / 3; border-radius: 18px; overflow: hidden; background: color-mix(in srgb, var(--silver) 45%, var(--ivory)); display: grid; place-items: center; }
.gcard__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.gcard:hover .gcard__img img { transform: scale(1.04); }
.gcard__img i { font-style: normal; font-size: .82rem; opacity: .55; }
.gcard__name { font-family: var(--serif); font-size: 1.45rem; line-height: 1.1; }
.gcard__meta { font-size: .82rem; opacity: .65; }
.gcard.is-empty { cursor: default; }
.gcard.is-empty .gcard__name { opacity: .7; }

.gal__head { display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between; align-items: end; margin-bottom: 26px; }
.gal__head h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(2rem, 4.4vw, 3.4rem); line-height: 1; margin-top: 8px; }
.gal__meta { opacity: .65; margin-top: 6px; }
.gal__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.gal__empty { padding: 56px 0; opacity: .7; max-width: 52ch; }

.gal__grid { columns: 3 280px; column-gap: 14px; }
.gshot { display: block; width: 100%; margin: 0 0 14px; padding: 0; border: 0; border-radius: 14px; overflow: hidden; background: color-mix(in srgb, var(--silver) 45%, var(--ivory)); cursor: zoom-in; break-inside: avoid; }
.gshot img { width: 100%; height: auto; display: block; min-height: 120px; transition: transform .6s var(--ease), opacity .4s; }
.gshot:hover img { transform: scale(1.03); }

.gal__foot { padding: 28px var(--gutter) 40px; border-top: 1px solid var(--line); text-align: center; display: grid; gap: 6px; }

.lightbox { position: fixed; inset: 0; z-index: 90; background: color-mix(in srgb, var(--graphite) 94%, black); display: grid; grid-template-columns: 64px 1fr 64px; align-items: center; color: var(--ivory); }
.lightbox__fig { display: grid; gap: 10px; justify-items: center; max-height: 100vh; padding: 18px 0; min-width: 0; }
.lightbox__fig img { max-width: 100%; max-height: calc(100vh - 90px); object-fit: contain; border-radius: 10px; }
.lightbox__fig figcaption { font-size: .85rem; opacity: .75; }
.lightbox__nav, .lightbox__close { background: transparent; border: 1px solid rgba(255,255,255,.28); color: var(--ivory); border-radius: 999px; width: 44px; height: 44px; font-size: 1.3rem; cursor: pointer; justify-self: center; transition: background .3s; }
.lightbox__nav:hover, .lightbox__close:hover { background: rgba(255,255,255,.14); }
.lightbox__close { position: absolute; top: 16px; right: 16px; z-index: 1; }

@media (max-width: 820px) {
  .gal__main { padding-top: 104px; }
  .gal__select select { min-width: 0; width: 100%; }
  .gal__select { width: 100%; }
  .lightbox { grid-template-columns: 1fr; }
  .lightbox__nav { position: absolute; bottom: 16px; }
  .lightbox__nav--prev { left: 16px; }
  .lightbox__nav--next { right: 16px; }
  .lightbox__fig img { max-height: calc(100vh - 150px); }
}
