:root {
  --media-bg-top: #202438;
  --media-bg-bottom: #0b0f14;
}

/*---------------------------------------------------------------------------*/
/* Media section */
.media {
  position: relative;
  padding: 80px 0;
  background: linear-gradient(to bottom, var(--media-bg-top), var(--media-bg-bottom));
}

.media-content {
  position: relative;
  z-index: 2;
}

.media-title {
  margin: 0 0 32px;
  text-align: center;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.media-thumb {
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  border-radius: 12px;
  overflow: hidden;
}

.media-thumb img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.media-thumb:hover img {
  transform: scale(1.03);
  opacity: 0.92;
}

/*---------------------------------------------------------------------------*/
/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: rgba(0, 0, 0, 0.88);
}

.lightbox.is-open {
  display: flex;
}

.lightbox-image {
  display: block;
  max-width: min(3840px, 98vw);
  max-height: 95vh;
  width: auto;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
  color: white;
  background: rgba(255, 255, 255, 0.12);
}

/*---------------------------------------------------------------------------*/
/* Responsive */
@media (max-width: 900px) {
  .media-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

  .lightbox {
    padding: 20px;
  }
}
