/*
 * Bands Gallery — Companion Stylesheet
 * File: bands-gallery.css
 * Place in: wp-content/themes/blocksy-child/bands-gallery.css
 */

/* ─── Override Blocksy content constraints ─────────────────── */

.page-template-page-bands-gallery .entry-content,
.page-template-page-bands-gallery .ct-container,
.page-template-page-bands-gallery .site-main {
  max-width: 100% !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.page-template-page-bands-gallery .site-content {
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}

/* ─── Page wrapper ─────────────────────────────────────────── */

.iltl-gallery-wrap {
  width: 100%;
  max-width: 100%;
  background: #0c0c0c;
  padding-bottom: 5rem;
}

/* ─── Header ───────────────────────────────────────────────── */

.iltl-gallery-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 3rem 2.5rem 2rem;
  border-bottom: 0.5px solid #1e1e1e;
  margin-bottom: 1.5rem;
}

.iltl-header-inner {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.iltl-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 300;
  color: #e2ddd4;
  letter-spacing: 0.02em;
  line-height: 1;
  margin: 0;
}

.iltl-title em {
  font-style: italic;
  color: #888;
  font-weight: 300;
}

.iltl-meta {
  font-family: 'DM Mono', 'Courier New', monospace;
  font-size: 11px;
  font-weight: 300;
  color: #3a3a3a;
  letter-spacing: 0.07em;
  margin: 0;
}

.iltl-count {
  font-family: 'DM Mono', 'Courier New', monospace;
  font-size: 11px;
  font-weight: 300;
  color: #2a2a2a;
  letter-spacing: 0.07em;
  white-space: nowrap;
}

/* ─── Uniform 3-column grid ────────────────────────────────── */

.iltl-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 3px;
  padding: 0 2.5rem;
}

/* ─── Individual brick ─────────────────────────────────────── */

.iltl-brick {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: #111;
  aspect-ratio: 3 / 2;
}

.iltl-brick img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transition: transform 0.6s cubic-bezier(0.25, 0, 0, 1);
  opacity: 1;
}

.iltl-brick:hover img {
  transform: scale(1.04);
}

/* ─── Hover overlay ────────────────────────────────────────── */

.iltl-brick-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  transition: background 0.35s ease;
  display: flex;
  align-items: flex-end;
  padding: 16px 18px;
  pointer-events: none;
}

.iltl-brick:hover .iltl-brick-overlay {
  background: rgba(0, 0, 0, 0.55);
}

.iltl-brick-label {
  display: flex;
  flex-direction: column;
  gap: 3px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.iltl-brick:hover .iltl-brick-label {
  opacity: 1;
  transform: translateY(0);
}

.iltl-brick-band {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  color: #e2ddd4;
  letter-spacing: 0.02em;
  line-height: 1.1;
}

.iltl-brick-sub {
  font-family: 'DM Mono', 'Courier New', monospace;
  font-size: 10px;
  font-weight: 300;
  color: #888;
  letter-spacing: 0.07em;
}

/* ─── Lightbox ─────────────────────────────────────────────── */

.iltl-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(8, 8, 8, 0.97);
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.iltl-lightbox--active {
  display: flex;
}

.iltl-lb-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 92vw;
  max-height: 82vh;
}

.iltl-lb-img {
  max-width: 92vw;
  max-height: 82vh;
  object-fit: contain;
  display: block;
}

.iltl-lb-close {
  position: fixed;
  top: 18px;
  right: 22px;
  background: none;
  border: none;
  color: #333;
  font-size: 18px;
  cursor: pointer;
  padding: 6px 10px;
  line-height: 1;
  transition: color 0.2s;
  font-family: 'DM Mono', monospace;
}

.iltl-lb-close:hover { color: #888; }

.iltl-lb-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #2a2a2a;
  font-size: 36px;
  cursor: pointer;
  padding: 16px 22px;
  transition: color 0.2s;
  line-height: 1;
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
}

.iltl-lb-nav:hover { color: #777; }
.iltl-lb-prev { left: 8px; }
.iltl-lb-next { right: 8px; }

.iltl-lb-footer {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-top: 16px;
  padding: 0 2rem;
}

.iltl-lb-band {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 16px;
  font-weight: 400;
  color: #888;
  letter-spacing: 0.02em;
}

.iltl-lb-sub {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  font-weight: 300;
  color: #333;
  letter-spacing: 0.07em;
}

.iltl-lb-counter {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  font-weight: 300;
  color: #252525;
  letter-spacing: 0.06em;
  margin-left: auto;
}

/* ─── Responsive ───────────────────────────────────────────── */

@media (max-width: 900px) {
  .iltl-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 0 1.25rem;
  }
  .iltl-gallery-header {
    padding: 2rem 1.25rem 1.5rem;
    flex-direction: column;
    gap: 8px;
  }
  .iltl-count { margin-top: 4px; }
}

@media (max-width: 500px) {
  .iltl-grid {
    grid-template-columns: 1fr;
    padding: 0 0.75rem;
  }
  .iltl-lb-nav { display: none; }
}
