/* ---------- Header ---------- */

.site-header {
  text-align: center;
  padding: 5rem 1.5rem 2rem;
}

.couple-names {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  letter-spacing: 0.02em;
  margin: 0;
}

.wedding-date {
  margin: 0.5rem 0 0;
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ---------- Toolbar ---------- */

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 1.5rem 1.5rem;
  max-width: 1600px;
  margin: 0 auto;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  flex: 1 1 auto;
}

.toolbar-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 0 0 auto;
}

/* ---------- Gallery: uniform grid ---------- */

.gallery {
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 1.5rem 4rem;
}

.gallery--uniform {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 6px;
}

.grid-item {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 2px;
  padding: 0;
  border: none;
  background: var(--surface);
}

.grid-item .photo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---------- Gallery: masonry ---------- */

.gallery--masonry {
  display: flex;
  align-items: flex-start;
  gap: 6px;
}

.masonry-column {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1 1 0;
  min-width: 0;
}

.masonry-item {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  background: var(--surface);
  border-radius: 2px;
  overflow: hidden;
}

.photo-img--natural {
  width: 100%;
  height: auto;
}

/* ---------- Gallery: justified rows ---------- */

.gallery--justified {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.justified-row {
  display: flex;
  gap: 6px;
  width: 100%;
}

.justified-item {
  padding: 0;
  border: none;
  overflow: hidden;
  background: var(--surface);
  flex-shrink: 0;
}

.justified-item .photo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---------- Empty / error states ---------- */

.empty-message,
.error-message {
  text-align: center;
  color: var(--text-muted);
  padding: 4rem 1rem;
  font-size: 1rem;
}

/* ---------- Responsive ---------- */

@media (max-width: 600px) {
  .site-header {
    padding: 3rem 1rem 1.5rem;
  }

  .toolbar {
    flex-direction: column;
    align-items: stretch;
    padding: 0 1rem 1rem;
  }

  .toolbar-controls {
    justify-content: space-between;
  }

  .gallery {
    padding: 0 1rem 3rem;
  }

  .gallery--uniform {
    grid-template-columns: 1fr;
  }

  .justified-row {
    flex-direction: column;
  }

  .justified-item {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 4 / 3;
  }
}
