/* Project gallery page (gallery.html). Builds on the shared .gallery-item
   lightbox trigger from styles.css. */

.gx-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(24px, 4vw, 64px);
  align-items: start;
}

.gx-filters {
  display: grid;
  gap: 14px;
  margin-bottom: clamp(24px, 3vw, 36px);
}

.gx-filters[hidden] {
  display: none;
}

.gx-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}

.gx-filter-label {
  flex: 0 0 100%;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--stone-700);
}

.gx-chip {
  min-height: 40px;
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--white);
  color: var(--ink);
  font-family: var(--grotesk);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease, border-color 180ms ease;
}

.gx-chip:hover {
  border-color: var(--ink);
}

.gx-chip[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
}

.gx-chip:focus-visible {
  outline: 2px solid var(--wood);
  outline-offset: 2px;
}

.gx-status {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}

.gx-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--gallery-gap, 22px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.gx-item {
  margin: 0;
  min-width: 0;
}

.gx-item[hidden] {
  display: none;
}

/* Overrides the fixed one-third width the shared rule gives .gallery-item;
   the grid handles columns here. */
.gx-item .gallery-item {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
}

.gx-item .gallery-item img {
  display: block;
}

.gx-cap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 12px;
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--muted);
}

.gx-credit {
  font-weight: 700;
  letter-spacing: 0.02em;
}

.gx-cap a {
  color: var(--ink);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.gx-cap a:hover {
  color: var(--wood);
}

.gx-empty {
  margin-top: 24px;
  color: var(--muted);
}

.gx-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 960px) {
  .gx-intro {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .gx-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .gx-grid {
    grid-template-columns: 1fr;
  }

  .gx-cta-actions .btn {
    width: 100%;
  }
}
