/* ---------------------------------------------------------------
   Lightbox — Remmelt Studios
   Restyles PhotoSwipe (photoswipe.css, loaded just before this file)
   into the gallery's own voice: black, thin strokes, and the small
   uppercase labels the figcaptions use. Driven by lightbox.js.

   Top bar:  counter ............ copy link   close
   Bottom:   caption, centred
   The padding in lightbox.js keeps the photograph clear of both.
   --------------------------------------------------------------- */

.pswp {
  --pswp-bg: #000;
  --pswp-placeholder-bg: #0d0d0d;
  --pswp-preloader-color: rgb(255 255 255 / 0.15);
  --pswp-preloader-color-secondary: rgb(255 255 255 / 0.6);
  --rs-lb-dim: var(--rs-muted, #8a8a8a);
  --rs-lb-bar: 56px;
  --rs-lb-foot: 64px;
}
@media (min-width: 700px) {
  .pswp { --rs-lb-bar: 72px; --rs-lb-foot: 80px; }
}

/* the label style shared by counter, button and caption */
.pswp__counter,
.rs-copy__label,
.pswp .rs-caption {
  font-size: 0.75rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  line-height: 1;
}

/* ---------- top bar ---------- */
.pswp__top-bar {
  height: var(--rs-lb-bar);
  align-items: center;
  padding: 0 6px 0 16px;
  box-sizing: border-box;
}
@media (min-width: 700px) {
  .pswp__top-bar { padding: 0 20px 0 32px; }
}

.pswp__counter {
  height: auto;
  margin: 0;
  color: var(--rs-lb-dim);
  text-shadow: none;
  opacity: 1;
  font-variant-numeric: tabular-nums;
}

/* PhotoSwipe zeroes button padding on :hover/:focus, hence the doubled
   selectors — without them the label jumps sideways when hovered. */
.pswp .pswp__button--rs-copy,
.pswp .pswp__button--rs-copy:hover,
.pswp .pswp__button--rs-copy:focus,
.pswp .pswp__button--close,
.pswp .pswp__button--close:hover,
.pswp .pswp__button--close:focus {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  width: auto;
  height: 44px;
  padding: 0 12px;
  margin: 0;
  font: inherit;
  color: var(--rs-lb-dim);
  opacity: 1;
  transition: color 200ms;
}
.pswp .pswp__button--rs-copy.is-copied { color: #fff; }
@media (hover: hover) {
  .pswp .pswp__button--rs-copy:hover,
  .pswp .pswp__button--close:hover { color: #fff; }
}
.pswp .pswp__button:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: -6px;
}

.pswp .rs-icn {
  display: block;
  width: 16px;
  height: 16px;
  flex: none;
}
.pswp .pswp__button--close .rs-icn { width: 22px; height: 22px; }

/* ---------- arrows (mouse only; touch swipes) ---------- */
.pswp .pswp__button--arrow,
.pswp .pswp__button--arrow:hover,
.pswp .pswp__button--arrow:focus {
  width: 72px;
  height: 120px;
  margin-top: -60px;
  color: var(--rs-lb-dim);
  opacity: 1;
  transition: color 200ms;
}
@media (hover: hover) {
  .pswp .pswp__button--arrow:hover { color: #fff; }
}
.pswp .pswp__button--arrow .rs-icn {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 28px;
  height: 28px;
  transform: translate(-50%, -50%);
}

/* ---------- caption ---------- */
.pswp .rs-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--rs-lb-foot);
  padding: 0 1.5rem env(safe-area-inset-bottom);
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #c4c4c4;
}
/* never catch a click: the space around the photograph closes it */
.pswp .rs-caption,
.pswp--ui-visible .rs-caption { pointer-events: none; }
