.page-hero--gallery {
  background: linear-gradient(135deg, #1b4332 0%, #2d6a4f 100%);
  border-bottom: none;
  color: #fff;
}

.page-hero--gallery .eyebrow {
  color: #b8e986;
}

.page-hero--gallery .page-hero__title {
  color: #fff;
}

.page-hero--gallery .page-hero__lead {
  color: rgba(255, 255, 255, 0.92);
  opacity: 1;
  max-width: 52ch;
}

.gallery-section {
  padding-top: 2rem;
  padding-bottom: 3rem;
}

.gallery-empty {
  text-align: center;
  padding: 3rem 1rem;
  color: #5a7568;
}

.gallery-empty p {
  margin: 0 0 1rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  align-items: stretch;
  width: 100%;
}

.gallery-grid--count-1 {
  grid-template-columns: minmax(280px, 520px);
  justify-content: center;
}

.gallery-grid--count-2 {
  grid-template-columns: repeat(2, minmax(280px, 1fr));
  max-width: 920px;
  margin-inline: auto;
}

@media (max-width: 640px) {
  .gallery-grid--count-2 {
    grid-template-columns: 1fr;
  }
}

.gallery-grid__item {
  margin: 0;
  display: flex;
  flex-direction: column;
}

.gallery-grid__btn {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  border-radius: 14px;
  overflow: hidden;
  cursor: zoom-in;
  background: #fff;
  border: 1px solid rgba(27, 67, 50, 0.1);
  box-shadow: 0 10px 28px rgba(27, 67, 50, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gallery-grid__btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 32px rgba(27, 67, 50, 0.16);
}

.gallery-grid__frame {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 220px;
  aspect-ratio: 4 / 3;
  background: linear-gradient(160deg, #eef4f0 0%, #e3ebe6 100%);
  overflow: hidden;
}

.gallery-grid__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
}

.gallery-grid__caption {
  margin-top: 0.55rem;
  font-size: 0.88rem;
  color: #3d5a4a;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.gallery-grid__caption strong {
  color: var(--color-forest-green);
}

.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

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

.gallery-lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 24, 18, 0.88);
}

.gallery-lightbox__dialog {
  position: relative;
  z-index: 1;
  max-width: min(96vw, 1100px);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.gallery-lightbox__img {
  max-width: 100%;
  max-height: 78vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}

.gallery-lightbox__close {
  position: absolute;
  top: -2.5rem;
  right: 0;
  width: 2.25rem;
  height: 2.25rem;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.gallery-lightbox__meta {
  margin-top: 0.75rem;
  text-align: center;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

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