/* Public Gallery page */
.gallery-page {
  --gallery-teal: #0b4e56;
  --gallery-gold: #feee90;
}

.gallery-hero {
  position: relative;
  padding: clamp(110px, 16vw, 160px) var(--section-inline, 5vw) clamp(48px, 8vw, 72px);
  background:
    radial-gradient(circle at 85% 20%, rgba(254, 238, 144, 0.18), transparent 40%),
    linear-gradient(160deg, #083840 0%, #0b4e56 55%, #0d5c66 100%);
  color: #fff;
  overflow: hidden;
}

.gallery-hero::after {
  content: '';
  position: absolute;
  inset: auto 0 0;
  height: 4px;
  background: linear-gradient(90deg, #e0d070, #feee90, #fff6b8);
}

.gallery-hero .container {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
}

.gallery-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gallery-gold);
  margin-bottom: 1rem;
}

.gallery-hero__eyebrow .line {
  width: 36px;
  height: 1px;
  background: var(--gallery-gold);
}

.gallery-hero h1 {
  font-family: var(--ff-display, 'Cormorant Garamond', serif);
  font-size: clamp(2.4rem, 6vw, 4rem);
  line-height: 1.1;
  margin: 0 0 1rem;
}

.gallery-hero h1 em {
  font-style: italic;
  color: var(--gallery-gold);
}

.gallery-hero p {
  max-width: 560px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.05rem;
  line-height: 1.7;
  margin: 0;
}

.gallery-toolbar {
  padding: 1.5rem var(--section-inline, 5vw) 0.5rem;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.gallery-filter {
  border: 1px solid rgba(11, 78, 86, 0.18);
  background: #fff;
  color: #0b4e56;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s ease;
}

.gallery-filter.is-active,
.gallery-filter:hover {
  background: #0b4e56;
  color: #feee90;
  border-color: #0b4e56;
}

.gallery-grid-wrap {
  padding: 1.5rem var(--section-inline, 5vw) clamp(80px, 12vw, 120px);
  max-width: 1200px;
  margin: 0 auto;
}

.gallery-grid {
  columns: 1;
  column-gap: 1rem;
}

@media (min-width: 640px) {
  .gallery-grid { columns: 2; }
}

@media (min-width: 992px) {
  .gallery-grid { columns: 3; }
}

.gallery-card {
  break-inside: avoid;
  margin: 0 0 1rem;
  border-radius: 18px;
  overflow: hidden;
  position: relative;
  background: #eef6f7;
  cursor: pointer;
  border: 0;
  padding: 0;
  width: 100%;
  text-align: left;
  display: block;
}

.gallery-card img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.45s ease;
}

.gallery-card:hover img {
  transform: scale(1.03);
}

.gallery-card__meta {
  position: absolute;
  inset: auto 0 0;
  padding: 1.4rem 1rem 1rem;
  background: linear-gradient(180deg, transparent, rgba(8, 56, 64, 0.88));
  color: #fff;
}

.gallery-card__meta strong {
  display: block;
  font-family: var(--ff-display, 'Cormorant Garamond', serif);
  font-size: 1.2rem;
}

.gallery-card__meta span {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.78rem;
  color: #feee90;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.gallery-empty,
.gallery-loading,
.gallery-error {
  text-align: center;
  padding: 4rem 1rem;
  color: #5a6b6d;
}

.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 12000;
  background: rgba(8, 56, 64, 0.94);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.gallery-lightbox.is-open {
  display: flex;
}

.gallery-lightbox img {
  max-width: min(1100px, 92vw);
  max-height: 82vh;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}

.gallery-lightbox__close,
.gallery-lightbox__nav {
  position: absolute;
  border: 1px solid rgba(254, 238, 144, 0.4);
  background: rgba(11, 78, 86, 0.75);
  color: #feee90;
  border-radius: 999px;
  cursor: pointer;
}

.gallery-lightbox__close {
  top: 1.25rem;
  right: 1.25rem;
  width: 44px;
  height: 44px;
  font-size: 1.4rem;
}

.gallery-lightbox__nav {
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  font-size: 1.2rem;
}

.gallery-lightbox__nav--prev { left: 1rem; }
.gallery-lightbox__nav--next { right: 1rem; }

.gallery-lightbox__caption {
  position: absolute;
  left: 50%;
  bottom: 1.25rem;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.88);
  text-align: center;
  max-width: min(720px, 90vw);
  font-size: 0.95rem;
}
