/* =========================================================
   POSTER ALL PAGE
========================================================= */

.poster-all-page {
  min-height: 100vh;
}

/* =========================================================
   CONTAINER
========================================================= */

.poster-all-container {
  width: min(1200px, calc(100% - 40px));
  margin: 0 auto;
}

/* =========================================================
   HEADER
========================================================= */

.poster-all-header {
  padding: 80px 0 50px;
  text-align: center;
}

.poster-all-eyebrow {
  display: inline-block;
  margin-bottom: 10px;

  font-size: 12px;
  font-weight: 700;

  letter-spacing: 2px;
  text-transform: uppercase;
}

.poster-all-header h1 {
  margin: 0 0 14px;

  font-size: clamp(32px, 5vw, 52px);
  line-height: 1.1;
}

.poster-all-header p {
  max-width: 650px;
  margin: 0 auto;

  font-size: 16px;
  line-height: 1.7;

  opacity: 0.7;
}

/* =========================================================
   CONTENT
========================================================= */

.poster-all-content {
  padding: 20px 0 90px;
}

/* =========================================================
   GRID
========================================================= */

.poster-all-grid {
  display: grid;

  grid-template-columns: repeat(4, minmax(0, 1fr));

  gap: 24px;
}

/* =========================================================
   POSTER
========================================================= */

.poster-all-item {
  position: relative;

  aspect-ratio: 1122 / 1402;

  overflow: hidden;

  border-radius: 12px;

  cursor: pointer;

  outline: none;

  background: #eeeeee;

  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);

  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease;
}

.poster-all-item:hover,
.poster-all-item:focus-visible {
  transform: translateY(-6px);

  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.14);
}

/* =========================================================
   IMAGE
========================================================= */

.poster-all-image {
  position: relative;

  width: 100%;
  height: 100%;

  overflow: hidden;
}

.poster-all-image img {
  width: 100%;
  height: 100%;

  display: block;

  object-fit: cover;

  transition: transform 0.5s ease;
}

.poster-all-item:hover .poster-all-image img,
.poster-all-item:focus-visible .poster-all-image img {
  transform: scale(1.05);
}

/* =========================================================
   HOVER
========================================================= */

.poster-all-hover {
  position: absolute;

  inset: 0;

  display: flex;
  flex-direction: column;

  align-items: center;
  justify-content: center;

  gap: 10px;

  background: rgba(0, 0, 0, 0.55);

  color: #ffffff;

  opacity: 0;

  transition: opacity 0.3s ease;
}

.poster-all-item:hover .poster-all-hover,
.poster-all-item:focus-visible .poster-all-hover {
  opacity: 1;
}

.poster-all-view-icon {
  display: flex;

  align-items: center;
  justify-content: center;

  width: 52px;
  height: 52px;

  border: 1px solid rgba(255, 255, 255, 0.8);

  border-radius: 50%;

  font-size: 26px;

  transform: translateY(10px);

  transition: transform 0.3s ease;
}

.poster-all-view-text {
  font-size: 14px;
  font-weight: 600;

  transform: translateY(10px);

  transition: transform 0.3s ease 0.03s;
}

.poster-all-item:hover .poster-all-view-icon,
.poster-all-item:hover .poster-all-view-text,
.poster-all-item:focus-visible .poster-all-view-icon,
.poster-all-item:focus-visible .poster-all-view-text {
  transform: translateY(0);
}

/* =========================================================
   PAGINATION
========================================================= */

.poster-pagination {
  display: flex;

  align-items: center;
  justify-content: center;

  gap: 7px;

  margin-top: 50px;
}

.poster-pagination-number,
.poster-pagination-prev,
.poster-pagination-next {
  display: flex;

  align-items: center;
  justify-content: center;

  min-width: 40px;
  height: 40px;

  padding: 0 10px;

  border-radius: 8px;

  text-decoration: none;

  color: inherit;

  font-size: 14px;
  font-weight: 600;

  transition:
    background-color 0.2s ease,
    transform 0.2s ease;
}

.poster-pagination-number:hover,
.poster-pagination-prev:hover,
.poster-pagination-next:hover {
  transform: translateY(-2px);
}

.poster-pagination-number.is-active {
  background: #222222;
  color: #ffffff;
}

.poster-pagination-dots {
  display: flex;

  align-items: center;
  justify-content: center;

  min-width: 30px;

  opacity: 0.5;
}

/* =========================================================
   EMPTY
========================================================= */

.poster-all-empty {
  padding: 100px 20px;

  text-align: center;
}

.poster-all-empty h2 {
  margin: 0 0 10px;
}

.poster-all-empty p {
  margin: 0;

  opacity: 0.6;
}

/* =========================================================
   MODAL
========================================================= */

.poster-all-modal {
  position: fixed;

  inset: 0;

  z-index: 99999;

  display: flex;

  align-items: center;
  justify-content: center;

  padding: 30px;

  visibility: hidden;
  opacity: 0;

  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

.poster-all-modal.is-open {
  visibility: visible;
  opacity: 1;
}

/* =========================================================
   BACKDROP
========================================================= */

.poster-all-modal-backdrop {
  position: absolute;

  inset: 0;

  background: rgba(0, 0, 0, 0.78);

  backdrop-filter: blur(5px);
}

/* =========================================================
   DIALOG
========================================================= */

.poster-all-modal-dialog {
  position: relative;

  z-index: 1;

  width: min(900px, 100%);

  max-height: calc(100vh - 60px);

  overflow: auto;

  border-radius: 14px;

  background: #ffffff;

  transform: scale(0.96);

  transition: transform 0.3s ease;
}

.poster-all-modal.is-open .poster-all-modal-dialog {
  transform: scale(1);
}

/* =========================================================
   CLOSE
========================================================= */

.poster-all-modal-close {
  position: absolute;

  top: 12px;
  right: 12px;

  z-index: 3;

  display: flex;

  align-items: center;
  justify-content: center;

  width: 40px;
  height: 40px;

  border: none;

  border-radius: 50%;

  background: rgba(0, 0, 0, 0.65);

  color: #ffffff;

  font-size: 26px;
  line-height: 1;

  cursor: pointer;

  transition:
    background-color 0.2s ease,
    transform 0.2s ease;
}

.poster-all-modal-close:hover {
  background: rgba(0, 0, 0, 0.85);

  transform: rotate(90deg);
}

/* =========================================================
   MODAL CONTENT
========================================================= */

.poster-all-modal-content {
  display: flex;
  flex-direction: column;
}

.poster-all-modal-image {
  display: flex;

  align-items: center;
  justify-content: center;

  padding: 25px;

  background: #f5f5f5;
}

.poster-all-modal-image img {
  display: block;

  width: auto;
  max-width: 100%;

  max-height: 70vh;

  object-fit: contain;
}

/* =========================================================
   MODAL INFO
========================================================= */

.poster-all-modal-info {
  padding: 20px 25px 25px;
}

.poster-all-modal-info h2 {
  margin: 0 0 8px;

  font-size: 20px;
  line-height: 1.4;
}

.poster-all-modal-info time {
  display: block;

  font-size: 13px;

  opacity: 0.6;
}

/* =========================================================
   BODY LOCK
========================================================= */

body.poster-all-modal-open {
  overflow: hidden;
}

/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 1000px) {
  .poster-all-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .poster-all-container {
    width: min(100% - 30px, 1200px);
  }

  .poster-all-header {
    padding: 60px 0 35px;
  }

  .poster-all-content {
    padding-bottom: 60px;
  }

  .poster-all-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 16px;
  }

  .poster-all-modal {
    padding: 15px;
  }

  .poster-all-modal-dialog {
    max-height: calc(100vh - 30px);
  }

  .poster-all-modal-image {
    padding: 15px;
  }

  .poster-all-modal-info {
    padding: 16px 18px 20px;
  }
}

@media (max-width: 430px) {
  .poster-all-container {
    width: calc(100% - 24px);
  }

  .poster-all-grid {
    gap: 12px;
  }

  .poster-all-item {
    border-radius: 8px;
  }

  .poster-pagination {
    gap: 3px;
  }

  .poster-pagination-number,
  .poster-pagination-prev,
  .poster-pagination-next {
    min-width: 36px;
    height: 36px;

    padding: 0 7px;
  }
}
