/* Gallery grid + lightbox (website-images) */
.opc-gallery-tile {
  cursor: zoom-in;
  border-radius: 1rem;
}

.opc-gallery-tile:focus-visible {
  outline: 2px solid var(--opc-gold, #c5a037);
  outline-offset: 3px;
}

.opc-gallery-tile__media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #eef1f5;
}

.opc-gallery-tile__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.opc-gallery-tile:hover .opc-gallery-tile__img {
  transform: scale(1.04);
}

.opc-gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1080;
  display: flex;
  align-items: center;
  justify-content: center;
}

.opc-gallery-lightbox[hidden] {
  display: none !important;
}

body.opc-gallery-lightbox-open {
  overflow: hidden;
}

.opc-gallery-lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 18, 32, 0.92);
}

.opc-gallery-lightbox__panel {
  position: relative;
  z-index: 2;
  width: min(96vw, 1100px);
  max-height: 92vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 3.25rem;
}

.opc-gallery-lightbox__figure {
  margin: 0;
  width: 100%;
  text-align: center;
}

.opc-gallery-lightbox__img {
  max-width: 100%;
  max-height: min(72vh, 780px);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 0.5rem;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
}

.opc-gallery-lightbox__caption {
  color: #f1f5f9;
  margin-top: 0.85rem;
  font-size: 0.95rem;
}

.opc-gallery-lightbox__counter {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.8rem;
  margin: 0.35rem 0 0;
}

.opc-gallery-lightbox__close,
.opc-gallery-lightbox__nav {
  position: absolute;
  border: 0;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.opc-gallery-lightbox__close:hover,
.opc-gallery-lightbox__nav:hover {
  background: rgba(255, 255, 255, 0.22);
}

.opc-gallery-lightbox__close {
  top: 0.75rem;
  right: 0.75rem;
  z-index: 3;
}

.opc-gallery-lightbox__nav--prev {
  left: 0.25rem;
  top: 50%;
  transform: translateY(-50%);
}

.opc-gallery-lightbox__nav--next {
  right: 0.25rem;
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 575.98px) {
  .opc-gallery-lightbox__panel {
    padding: 2.75rem 0.5rem 1rem;
  }

  .opc-gallery-lightbox__nav {
    width: 2.25rem;
    height: 2.25rem;
  }
}
