.gallery-intro {
  padding: 64px 48px 32px;
  background: var(--cream);
}

.gallery-intro .container {
  max-width: 700px;
}

.gallery-intro p {
  font-size: 16px;
  color: var(--mid-gray);
  line-height: 1.8;
}

/* FILTERS — same pattern as The Post */
.gallery-filter {
  background: var(--cream);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 72px;
  z-index: 100;
}

.gallery-filter-inner {
  display: flex;
  gap: 4px;
  overflow-x: auto;
}

.gallery-filter-btn {
  background: none;
  border: none;
  padding: 16px 20px;
  font-family: 'Barlow', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--mid-gray);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.2s;
  white-space: nowrap;
}

.gallery-filter-btn:hover { color: var(--navy); }
.gallery-filter-btn.active { color: var(--navy); border-bottom-color: var(--gold); font-weight: 600; }

.gallery-full-section {
  padding: 32px 48px 96px;
  background: var(--cream);
}

.gallery-full-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 220px;
  gap: 12px;
}

.gallery-full-item {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
}

.gallery-full-item .img-placeholder,
.gallery-full-item .gallery-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Variable tile sizes — set via "size" in gallery.json */
.gallery-full-item.gallery-wide { grid-column: span 2; }
.gallery-full-item.gallery-tall { grid-row: span 2; }
.gallery-full-item.gallery-large { grid-column: span 2; grid-row: span 2; }

/* Caption sits over the tile always, whether it's a placeholder or a
   loaded photo, so 130 photos are still identifiable at a glance. */
.gallery-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10,25,48,0.82);
  color: var(--white);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
  padding: 8px 10px;
  z-index: 1;
}

@media (max-width: 1100px) {
  .gallery-full-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
  .gallery-intro { padding: 48px 24px 24px; }
  .gallery-filter-inner { padding: 0 24px; }
  .gallery-full-section { padding: 24px 24px 64px; }
  .gallery-full-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 180px; }
  .gallery-full-item.gallery-wide,
  .gallery-full-item.gallery-large { grid-column: span 2; }
}
