.gite-photo-section {
  padding-top: 20px;
  padding-bottom: 82px;
  border-top: 1px solid #e5e5df;
  margin-top: 0px
}

.photo-section-heading {
  text-align: center;
  margin-bottom: 30px
}

.photo-section-heading h2 {
  font-family: Georgia, serif;
  font-size: clamp(2.3rem, 4.2vw, 4rem);
  font-weight: 400;
  line-height: 1.1;
  margin: 8px 0 14px
}

.photo-section-heading p:last-child {
  color: #728078;
  max-width: 630px;
  margin: 0 auto
}

.photo-thumb-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px
}

.photo-thumb {
  position: relative;
  display: block;
  aspect-ratio: 4/3;
  border: 0;
  padding: 0;
  overflow: hidden;
  background: #e9e7df;
  cursor: zoom-in;
  text-align: left
}

.photo-thumb[hidden],
.photo-more-button[hidden] {
  display: none !important
}

.photo-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease
}

.photo-thumb:hover img {
  transform: scale(1.04)
}

.photo-thumb-label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 18px 12px 10px;
  color: white;
  font-size: .8rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, .6))
}

.photo-thumb:focus-visible,
.photo-more-button:focus-visible {
  outline: 3px solid #24523f;
  outline-offset: 3px
}

.photo-more-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 26px;
  flex-wrap: wrap
}

.photo-more-button {
  border: 1px solid #cfd3cc;
  padding: 14px 24px;
  background: white;
  color: #243a2e;
  font: inherit;
  cursor: pointer
}

.photo-more-button:hover {
  background: #f2f4f0
}

.photo-viewer {
  inset: 0;
  margin: auto;
  width: min(100vw, 1180px);
  height: 100dvh;
  max-width: 100vw;
  max-height: 100dvh;
  padding: 0;
  border: 0;
  color: white;
  background: #15231b;
  overflow: hidden
}

.photo-viewer::backdrop {
  background: rgba(4, 11, 7, .94)
}

.photo-viewer-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  z-index: 1
}

.photo-viewer-header button,
.photo-viewer-arrow {
  color: white;
  border: 1px solid #ffffff75;
  border-radius: 4px;
  background: #ffffff22;
  min-width: 44px;
  min-height: 44px;
  font-size: 26px;
  cursor: pointer
}

.photo-viewer figure {
  height: 100%;
  margin: 0;
  padding: 70px 70px 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 14px
}

.photo-viewer figure img {
  display: block;
  max-width: 100%;
  max-height: calc(100% - 50px);
  width: auto;
  height: auto;
  object-fit: contain
}

.photo-viewer figcaption {
  text-align: center;
  color: #e5e9e3
}

.photo-viewer-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%)
}

.photo-viewer-prev {
  left: 12px
}

.photo-viewer-next {
  right: 12px
}

@media(max-width:850px) {
  .photo-thumb-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px
  }
}

@media(max-width:560px) {
  .gite-photo-section {
    padding-top: 45px;
    padding-bottom: 55px;
    margin-top: 40px
  }

  .photo-thumb-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px
  }

  .photo-viewer figure {
    padding: 70px 14px 95px
  }

  .photo-viewer-arrow {
    top: auto;
    bottom: 22px;
    transform: none
  }
}

@media(prefers-reduced-motion:reduce) {
  .photo-thumb img {
    transition: none
  }
}

/* Add to the end of gallery.css */
.photo-filters {
  display: flex;
  flex-wrap: wrap;
  gap: .55rem;
  margin: 0 0 1.25rem;
}

.photo-filter {
  font: inherit;
  cursor: pointer;
  border: 1px solid #d9ddd3;
  background: #fff;
  color: #243a2e;
  border-radius: 999px;
  padding: .48rem .9rem;
}

.photo-filter:hover,
.photo-filter:focus-visible {
  border-color: #45634d;
}

.photo-filter[aria-pressed="true"] {
  background: #243a2e;
  border-color: #243a2e;
  color: #fff;
}