/* Style_Gallery.css (NO JS VERSION) */

/* Gallery page styles */
.gallery-page{
  --g-ink: #1a1a1a;
  --g-bg: #ffffff;
  --g-panel: #2b2b2b;
  --g-line: rgba(255,255,255,.35);
  --g-text: rgba(255,255,255,.92);

  background: var(--g-bg);
  color: var(--g-ink);
  font-family: "Source Sans 3", system-ui, -apple-system, sans-serif;
}

/* Basic helper (kept in case you reuse it) */
.sr-only{
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* Hero */
.gallery-hero{
  background: var(--g-panel);
  color: var(--g-text);
  border-top: 1px solid var(--g-line);
  border-bottom: 1px solid var(--g-line);
}

.gallery-hero-inner{
  width: min(1050px, 92vw);
  height: 26vw;
  margin: 0 auto;
  padding: clamp(44px, 6vw, 64px) 18px clamp(34px, 4.5vw, 52px);
  text-align: center;
}

.gallery-eyebrow{
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255,255,255,.70);
  margin-bottom: 12px;
}

.gallery-title{
  margin: 0 0 14px;
  font-family: big-caslon-fb, serif;
  font-weight: 500;
  font-size: 44px;
  letter-spacing: 0.02em;
  color: rgba(255,255,255,.95);
}

.gallery-lede{
  margin: 0 auto 24px;
  max-width: 72ch;
  font-size: 16px;
  line-height: 1.75;
  color: rgba(255,255,255,.84);
}

.gallery-hero-actions{
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* Grid wrapper */
.gallery-wrap{
  padding: 22px 18px 80px;
  background: #fff;
}

/* Masonry-ish grid */
.gallery-grid{
  width: min(1100px, 92vw);
  margin: 0 auto;
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(12, minmax(0, 1fr));
}

.tile{
  grid-column: span 4;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.10);
  background: #fff;
  box-shadow: 0 10px 26px rgba(0,0,0,.05);
}

/* Vary spans for a masonry feel */
.tile:nth-child(6n + 1),
.tile:nth-child(6n + 4){
  grid-column: span 5;
}

.tile:nth-child(6n + 2),
.tile:nth-child(6n + 5){
  grid-column: span 3;
}

/* Tile link (now an <a>) */
.tile-btn{
  display: block;
  width: 100%;
  text-decoration: none;
  color: inherit;
}

/* Keyboard focus */
.tile-btn:focus-visible{
  outline: 3px solid rgba(0,0,0,.22);
  outline-offset: 4px;
  border-radius: 12px;
}

/* Image */
.tile img{
  width: 100%;
  height: 320px;
  object-fit: cover;
  display: block;
  transform: scale(1);
  transition: transform 0.22s ease, filter 0.22s ease;
  filter: saturate(1.02);
}

.tile:hover img{
  transform: scale(1.03);
}

/* Caption */
.tile-cap{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 12px;
}

.tile-name{
  font-weight: 700;
  color: rgba(0,0,0,.82);
  letter-spacing: 0.01em;
}

.tile-tag{
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(0,0,0,.55);
}

/* Responsive */
@media (max-width: 980px){
  .tile,
  .tile:nth-child(6n + 1),
  .tile:nth-child(6n + 4),
  .tile:nth-child(6n + 2),
  .tile:nth-child(6n + 5){
    grid-column: span 6;
  }
}

@media (max-width: 640px){
  .tile,
  .tile:nth-child(6n + 1),
  .tile:nth-child(6n + 4),
  .tile:nth-child(6n + 2),
  .tile:nth-child(6n + 5){
    grid-column: span 12;
  }

  .gallery-title{
    font-size: 34px;
  }
}
