/* =========================================================
   ILLUSTRATION PAGE
========================================================= */

.illustration-page {
  background: #080707;
  color: #f5f3ef;
  min-height: 100vh;
}


/* =========================================================
   PAGE HEADING
========================================================= */

.illustration-heading {
  width: min(1200px, calc(100% - 80px));
  margin: 0 auto;

  padding: 160px 0 90px;
}


/* ---------------------------------------------------------
   KICKER
--------------------------------------------------------- */

.illustration-heading-top {
  display: flex;
  align-items: center;

  gap: 18px;

  margin-bottom: 18px;
}


.illustration-kicker {
  flex: 0 0 auto;

  color: #b3131b;

  font-size: 11px;
  font-weight: 700;

  letter-spacing: 0.2em;
}


.illustration-heading-line {
  width: 70px;
  height: 1px;

  background: rgba(255, 255, 255, 0.25);
}


/* ---------------------------------------------------------
   TITLE
--------------------------------------------------------- */

.illustration-heading h1 {
  margin: 0;

  color: #f5f3ef;

  font-size: clamp(48px, 7vw, 88px);
  font-weight: 700;

  line-height: 0.95;

  letter-spacing: 0.04em;
}


.illustration-description {
  margin: 28px 0 0;

  color: #aaa5a0;

  font-size: 14px;
  line-height: 1.8;

  letter-spacing: 0.08em;
}


/* =========================================================
   GALLERY
========================================================= */

.illustration-gallery {
  width: min(1200px, calc(100% - 80px));
  margin: 0 auto;

  padding: 0 0 150px;

  display: grid;

  grid-template-columns:
    repeat(4, minmax(0, 1fr));

  gap: 24px;
}


/* =========================================================
   GALLERY ITEM
========================================================= */

.illustration-item {
  position: relative;

  width: 100%;
  aspect-ratio: 1 / 1;

  padding: 0;

  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;

  background: #111;

  cursor: pointer;
  overflow: hidden;

  transition:
    transform 0.35s ease,
    border-color 0.35s ease,
    background 0.35s ease;
}


/* ---------------------------------------------------------
   IMAGE
--------------------------------------------------------- */

.illustration-item img {
  width: 100%;
  height: 100%;
  display: block;

  object-fit: cover;
  border-radius: 12px;

  background: #111;

  transition:
    transform 0.45s ease,
    opacity 0.35s ease;
}


/* ---------------------------------------------------------
   HOVER
--------------------------------------------------------- */

.illustration-item:hover {
  transform: translateY(-4px);

  border-color:
    rgba(179, 19, 27, 0.75);

  background: #151313;
}


.illustration-item:hover img {
  transform: scale(1.035);

  opacity: 0.88;
}


/* =========================================================
   LIGHTBOX
========================================================= */

.illustration-lightbox {
  position: fixed;

  inset: 0;

  z-index: 9999;

  display: flex;

  align-items: center;
  justify-content: center;

  padding: 40px;

  opacity: 0;
  visibility: hidden;

  pointer-events: none;

  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}


/* ---------------------------------------------------------
   OPEN
--------------------------------------------------------- */

.illustration-lightbox.is-open {
  opacity: 1;
  visibility: visible;

  pointer-events: auto;
}


/* =========================================================
   LIGHTBOX BACKDROP
========================================================= */

.lightbox-backdrop {
  position: absolute;

  inset: 0;

  background:
    rgba(8, 7, 7, 0.94);

  backdrop-filter: blur(8px);
}


/* =========================================================
   LIGHTBOX IMAGE
========================================================= */

.lightbox-image-wrap {
  position: relative;

  z-index: 2;

  display: flex;

  align-items: center;
  justify-content: center;

  width: 100%;
  height: 100%;
}


.lightbox-image-wrap img {
  display: block;

  max-width: min(90vw, 1200px);
  max-height: 88vh;

  width: auto;
  height: auto;

  object-fit: contain;

  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.55);

  transform: scale(0.96);

  transition:
    transform 0.35s ease;
}


.illustration-lightbox.is-open
.lightbox-image-wrap img {
  transform: scale(1);
}


/* =========================================================
   CLOSE BUTTON
========================================================= */

.lightbox-close {
  position: absolute;

  z-index: 5;

  top: 28px;
  right: 32px;

  width: 52px;
  height: 52px;

  display: flex;

  align-items: center;
  justify-content: center;

  padding: 0;

  border: 1px solid rgba(255, 255, 255, 0.2);

  background: rgba(0, 0, 0, 0.25);

  color: #f5f3ef;

  font-family: inherit;

  font-size: 38px;
  font-weight: 300;

  line-height: 1;

  cursor: pointer;

  transition:
    transform 0.25s ease,
    background 0.25s ease,
    border-color 0.25s ease;
}


.lightbox-close:hover {
  transform: rotate(90deg);

  background: #b3131b;

  border-color: #b3131b;
}


/* =========================================================
   BODY LOCK
========================================================= */

body.lightbox-open {
  overflow: hidden;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 1000px) {

  .illustration-gallery {
    grid-template-columns:
      repeat(3, minmax(0, 1fr));

    gap: 20px;
  }

}


@media (max-width: 700px) {

  .illustration-heading,
  .illustration-gallery {
    width: calc(100% - 40px);
  }


  .illustration-heading {
    padding: 120px 0 65px;
  }


  .illustration-heading h1 {
    font-size: 48px;
  }


  .illustration-gallery {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));

    gap: 14px;

    padding-bottom: 100px;
  }


  .illustration-lightbox {
    padding: 20px;
  }


  .lightbox-image-wrap img {
    max-width: 94vw;
    max-height: 84vh;
  }


  .lightbox-close {
    top: 14px;
    right: 14px;

    width: 46px;
    height: 46px;

    font-size: 34px;
  }

}


@media (max-width: 420px) {

  .illustration-heading h1 {
    font-size: 38px;
  }


  .illustration-gallery {
    gap: 10px;
  }


  .illustration-description {
    font-size: 13px;
  }

}