/* ==========================================================================
   GALLERY SECTION, PROOF STATS & LIGHTBOX
   ========================================================================== */
.gallery { padding-block: var(--space-3xl); }

.gallery__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-sm);
}

.gallery__item {
  position: relative;
  overflow: hidden;
  background: var(--color-navy-soft);
}

.gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--t-slow), filter var(--t-fast);
}

.gallery__item--interactive {
  cursor: pointer;
}

.gallery__item--interactive::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(8, 13, 21, 0.35) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 24 24' fill='none' stroke='%23DDA568' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='15 3 21 3 21 9'%3E%3C/polyline%3E%3Cpolyline points='9 21 3 21 3 15'%3E%3C/polyline%3E%3Cline x1='21' y1='3' x2='14' y2='10'%3E%3C/line%3E%3Cline x1='3' y1='21' x2='10' y2='14'%3E%3C/line%3E%3C/svg%3E") center no-repeat;
  opacity: 0;
  transition: opacity var(--t-fast);
  pointer-events: none;
}

.gallery__item--interactive:hover::after,
.gallery__item--interactive:focus-visible::after {
  opacity: 1;
}

.gallery__item:hover img {
  transform: scale(1.04);
}

.gallery__item--hero { grid-column: span 2; aspect-ratio: 4 / 3; }
.gallery__item--wide { grid-column: span 2; aspect-ratio: 16 / 9; }
.gallery__item:not(.gallery__item--hero):not(.gallery__item--wide) { aspect-ratio: 3 / 4; }

/* Proof stats */
.proof {
  margin-top: var(--space-2xl);
}
.proof__inner {
  position: relative;
  padding: clamp(1.5rem, 1rem + 1.8vw, 2.25rem) clamp(1.25rem, 1rem + 2vw, 3rem);
  background: linear-gradient(135deg, rgba(23, 32, 47, 0.75) 0%, rgba(11, 18, 32, 0.95) 100%);
  border: 1px solid rgba(232, 163, 92, 0.22);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(244, 239, 232, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: hidden;
}
.proof__inner::before {
  content: "";
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(232, 163, 92, 0.6), transparent);
}
.proof__list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-md);
  margin: 0;
  padding: 0;
  list-style: none;
}
.proof__item {
  display: flex;
  align-items: center;
  gap: clamp(0.75rem, 0.5rem + 1vw, 1.25rem);
  padding: var(--space-xs) var(--space-md);
  position: relative;
  transition: transform var(--t-fast);
}
.proof__item:not(:last-child)::after {
  content: "";
  position: absolute;
  right: 0;
  top: 15%;
  bottom: 15%;
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(43, 54, 74, 0.8), transparent);
}
.proof__icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(232, 163, 92, 0.08);
  border: 1px solid rgba(232, 163, 92, 0.25);
  color: var(--color-gold);
  transition: all var(--t-fast);
}
.proof__item:hover .proof__icon {
  background: rgba(232, 163, 92, 0.16);
  border-color: var(--color-gold);
  transform: scale(1.06);
}
.proof__content {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.proof__value {
  font-family: var(--font-accent);
  font-size: clamp(1.2rem, 1rem + 0.6vw, 1.6rem);
  font-weight: 400;
  color: var(--color-cream);
  line-height: 1.15;
}
.proof__label {
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-muted);
  font-family: var(--font-display);
}

@media (max-width: 54em) {
  .proof__list {
    grid-template-columns: 1fr;
    gap: var(--space-sm);
  }
  .proof__item {
    padding: var(--space-sm) 0;
  }
  .proof__item:not(:last-child)::after {
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(43, 54, 74, 0.8), transparent);
  }
}

/* ==========================================================================
   GALLERY LIGHTBOX MODAL
   ========================================================================== */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal, 1000);
  display: grid;
  place-items: center;
  padding: var(--space-sm);
  isolation: isolate;
}

.lightbox[hidden] {
  display: none !important;
}

.lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 7, 12, 0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.lightbox__container {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 75rem);
  max-height: 90svh;
}

.lightbox__stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  max-width: calc(100% - 7rem);
  max-height: 85svh;
}

.lightbox__image {
  max-width: 100%;
  max-height: calc(82svh - 4.5rem);
  object-fit: contain;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-navy-line);
  opacity: 0;
  transform: scale(0.97);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.lightbox__image.is-loaded {
  opacity: 1;
  transform: scale(1);
}

.lightbox__info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  width: 100%;
  margin-top: var(--space-xs);
  padding-inline: var(--space-2xs);
}

.lightbox__caption {
  font-size: var(--fs-small);
  color: var(--color-cream);
  max-width: 60ch;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lightbox__counter {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-gold);
  flex-shrink: 0;
}

/* Lightbox Buttons */
.lightbox__close {
  position: absolute;
  top: -2.75rem;
  right: 0;
  width: 40px;
  height: 40px;
  background: rgba(8, 13, 21, 0.75);
  border: 1px solid var(--color-navy-line);
  border-radius: 50%;
  color: var(--color-cream);
  font-size: 1.5rem;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all var(--t-fast);
}

.lightbox__close:hover,
.lightbox__close:focus-visible {
  border-color: var(--color-gold);
  color: var(--color-gold);
  outline: none;
}

.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  background: rgba(8, 13, 21, 0.85);
  border: 1px solid var(--color-navy-line);
  border-radius: 50%;
  color: var(--color-gold);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all var(--t-fast);
}

.lightbox__nav:hover,
.lightbox__nav:focus-visible {
  background: var(--color-navy);
  border-color: var(--color-gold);
  transform: translateY(-50%) scale(1.08);
  outline: none;
}

.lightbox__nav--prev {
  left: 0;
}

.lightbox__nav--next {
  right: 0;
}

@media (max-width: 48em) {
  .lightbox__stage {
    max-width: 100%;
  }

  .lightbox__close {
    top: -2.5rem;
    right: 0;
  }

  .lightbox__nav {
    width: 36px;
    height: 36px;
  }

  .lightbox__nav--prev {
    left: var(--space-2xs);
  }

  .lightbox__nav--next {
    right: var(--space-2xs);
  }
}

@media (min-width: 48em) {
  .proof__list { grid-template-columns: repeat(4, 1fr); }
  .gallery__grid { grid-template-columns: repeat(4, 1fr); }
  .gallery__item--hero { grid-column: span 2; grid-row: span 2; aspect-ratio: 4 / 5; }
  .gallery__item--wide { grid-column: span 2; aspect-ratio: 16 / 9; }
  .gallery__item:not(.gallery__item--hero):not(.gallery__item--wide) { aspect-ratio: 3 / 4; }
}
