/* ==========================================================================
   Ryaan Ranch: camera-trap gallery + lightbox
   ========================================================================== */
.rr-ele-gallery { background-color: var(--theme-color2); color: #fff; }
.rr-ele-gallery .sec-title .title { color: #fff; }
.rr-ele-gallery__intro { max-width: 860px; margin: 0 auto 50px; text-align: center; }
.rr-ele-gallery__intro .rr-lead { color: #fff; }
.rr-ele-gallery__intro p { color: rgba(255, 255, 255, 0.75); margin-bottom: 16px; }
.rr-ele-gallery__intro p:last-child { margin-bottom: 0; }
.rr-ele-gallery__quote {
  margin: 28px auto 0; max-width: 620px;
  font-family: var(--heading-font-family); font-size: 22px; line-height: 1.45; font-weight: 600;
  color: var(--theme-color1);
}

.rr-ele-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.rr-ele-thumb {
  position: relative; display: block; overflow: hidden;
  border-radius: 14px; aspect-ratio: 16 / 10; background: #0d1a14;
}
.rr-ele-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s ease, filter .4s ease; }
.rr-ele-thumb::after {
  content: ""; position: absolute; inset: 0; opacity: 0;
  background: rgba(0, 0, 0, .35) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-4-4M11 8v6M8 11h6'/%3E%3C/svg%3E") center / 34px no-repeat;
  transition: opacity .3s ease;
}
.rr-ele-thumb:hover img { transform: scale(1.06); }
.rr-ele-thumb:hover::after, .rr-ele-thumb:focus-visible::after { opacity: 1; }
.rr-ele-thumb:focus-visible { outline: 3px solid var(--theme-color1); outline-offset: 3px; }
.rr-ele-gallery__note { margin-top: 20px; text-align: center; font-size: 14px; color: rgba(255, 255, 255, 0.6); }

@media (max-width: 767.98px) {
  .rr-ele-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
@media (max-width: 575.98px) {
  .rr-ele-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .rr-ele-thumb { border-radius: 10px; }
  .rr-ele-gallery__quote { font-size: 19px; }
}

/* Lightbox */
.rr-lb-lock, .rr-lb-lock body { overflow: hidden; }
.rr-lb {
  position: fixed; inset: 0; z-index: 99999;
  display: flex; align-items: center; justify-content: center;
  padding: 60px 80px; background: rgba(5, 10, 8, 0.94);
  opacity: 0; visibility: hidden; transition: opacity .3s ease, visibility 0s linear .3s;
}
.rr-lb.is-open { opacity: 1; visibility: visible; transition: opacity .3s ease; }
.rr-lb__figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; }
.rr-lb__img {
  max-width: 100%; max-height: calc(100vh - 160px); border-radius: 8px; display: block;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .5); transition: opacity .25s ease;
}
.rr-lb.is-loading .rr-lb__img { opacity: .3; }
.rr-lb__caption { margin-top: 14px; color: rgba(255, 255, 255, .85); font-size: 15px; text-align: center; max-width: 760px; }
.rr-lb__close, .rr-lb__nav {
  position: absolute; border: 0; cursor: pointer; color: #fff;
  background: rgba(255, 255, 255, .1); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: background-color .3s ease;
}
.rr-lb__close { top: 18px; right: 18px; width: 46px; height: 46px; font-size: 30px; line-height: 1; }
.rr-lb__nav { top: 50%; transform: translateY(-50%); width: 54px; height: 54px; font-size: 38px; line-height: 1; padding-bottom: 4px; }
.rr-lb__nav--prev { left: 18px; }
.rr-lb__nav--next { right: 18px; }
.rr-lb__close:hover, .rr-lb__nav:hover, .rr-lb__close:focus-visible, .rr-lb__nav:focus-visible { background: var(--theme-color1); outline: none; }
.rr-lb__count { position: absolute; top: 28px; left: 24px; color: rgba(255, 255, 255, .7); font-size: 14px; letter-spacing: .08em; }
@media (max-width: 767.98px) {
  .rr-lb { padding: 70px 12px 90px; }
  .rr-lb__nav { top: auto; bottom: 22px; transform: none; width: 48px; height: 48px; }
  .rr-lb__nav--prev { left: calc(50% - 60px); }
  .rr-lb__nav--next { right: calc(50% - 60px); }
  .rr-lb__img { max-height: calc(100vh - 200px); }
}
