/* ============================================================
   Zola's Jerk Marinade — Gallery Page
   ============================================================ */

/* ---- Gallery intro ---- */
.jm-gallery-intro {
  padding: var(--section-padding);
  background: var(--jm-ember);
  text-align: center;
}

.jm-gallery-intro__desc {
  max-width: 620px;
  margin: 0 auto;
  font-size: 1rem;
  color: var(--jm-text-muted);
  line-height: 1.8;
}

/* ---- Gallery category section ---- */
.jm-gallery-section {
  padding: var(--section-padding);
  background: var(--jm-charcoal);
}

.jm-gallery-section--alt {
  background: var(--jm-ember);
}

.jm-gallery-section__header {
  text-align: center;
  margin-bottom: 2rem;
}

.jm-gallery-section__subtitle {
  max-width: 560px;
  margin: .75rem auto 0;
  font-size: .95rem;
  color: var(--jm-text-muted);
  line-height: 1.7;
}

/* ---- Override slideshow slide shadow for dark theme ---- */
body.theme-jerk-marinade .slideshow__slide img {
  box-shadow: 0 8px 32px rgba(0, 0, 0, .3);
}

/* ---- Gallery highlight strip ---- */
.jm-gallery-highlight {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  margin-top: 3rem;
}

.jm-gallery-highlight--reverse {
  direction: rtl;
}

.jm-gallery-highlight--reverse > * {
  direction: ltr;
}

.jm-gallery-highlight__text {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.jm-gallery-highlight__name {
  font-family: var(--font-heading);
  font-size: clamp(1.3rem, 3vw, 1.7rem);
  font-weight: 700;
  color: var(--jm-text);
}

.jm-gallery-highlight__desc {
  font-size: .95rem;
  color: var(--jm-text-muted);
  line-height: 1.75;
}

.jm-gallery-highlight__link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-family: var(--font-body);
  font-size: .9rem;
  font-weight: 600;
  color: var(--jm-primary);
  text-decoration: none;
  transition: gap .25s var(--ease), color .25s var(--ease);
}

.jm-gallery-highlight__link:hover {
  gap: .65rem;
  color: var(--jm-primary-light);
}

.jm-gallery-highlight__link i {
  font-size: .85rem;
}

.jm-gallery-highlight__visual {
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--jm-border);
}

.jm-gallery-highlight__visual img,
.jm-gallery-highlight__visual video {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
}

.jm-gallery-highlight__visual--wide img,
.jm-gallery-highlight__visual--wide video {
  aspect-ratio: 16 / 9;
}

/* ---- Quick stats ---- */
.jm-gallery-stats {
  display: flex;
  gap: 2rem;
  margin-top: 1.25rem;
  flex-wrap: wrap;
}

.jm-gallery-stat {
  display: flex;
  flex-direction: column;
  gap: .15rem;
}

.jm-gallery-stat__value {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--jm-primary);
}

.jm-gallery-stat__label {
  font-size: .78rem;
  color: var(--jm-text-muted);
  text-transform: uppercase;
  letter-spacing: .04em;
}

/* ---- Photo mosaic grid ---- */
.jm-gallery-mosaic {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2.5rem;
}

.jm-gallery-mosaic__item {
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--jm-border);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}

.jm-gallery-mosaic__item:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .3);
}

.jm-gallery-mosaic__item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.jm-gallery-mosaic__item figcaption {
  padding: .6rem .75rem;
  font-family: var(--font-body);
  font-size: .8rem;
  font-weight: 500;
  color: var(--jm-text);
  text-align: center;
}

/* ---- Mid-page CTA ---- */
.jm-gallery-banner {
  padding: 5rem 0;
  background: linear-gradient(135deg, var(--jm-ember) 0%, rgba(224, 115, 25, .1) 100%);
  text-align: center;
}

.jm-gallery-banner__inner {
  max-width: 640px;
  margin: 0 auto;
}

.jm-gallery-banner__title {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  color: var(--jm-text);
  margin-bottom: 1rem;
}

.jm-gallery-banner__desc {
  font-size: .95rem;
  color: var(--jm-text-muted);
  line-height: 1.7;
  margin-bottom: 2rem;
}

/* ---- Responsive ---- */
@media (hover: none) {
  .jm-gallery-mosaic__item:hover {
    transform: none;
  }
}

@media (max-width: 900px) {
  .jm-gallery-highlight {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .jm-gallery-highlight--reverse {
    direction: ltr;
  }

  .jm-gallery-mosaic {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .jm-gallery-mosaic {
    grid-template-columns: 1fr 1fr;
    gap: .75rem;
  }

  .jm-gallery-stats {
    gap: 1.25rem;
  }

  .jm-gallery-highlight__visual {
    border-radius: 14px;
  }
}
