.modal {
  padding: 30px 0 0;
}

.modal__images {
  display: flex;
  flex-wrap: wrap;
}

.modal__images .modal__image {
  position: relative;
  width: calc((100% - (32px * 2)) / 3);
}

.modal__images .modal__up:hover {
  opacity: .6;
  transition: opacity .6s;

}

.modal__images .modal__trigger {
  cursor: pointer;
}


.modal__images .modal__image:nth-child(3n - 1),
.modal__images .modal__image:nth-child(3n) {
  margin-left: 32px;
}

.modal__images .modal__image:before {
  display: block;
  padding-top: calc((2 / 3) * 100%);
  padding-top: 80%;
  content: '';
}

.modal__images .modal__image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  object-fit: cover;
  object-position: center top;
}

/* パノラマ写真用の設定 */
.modal__images .modal__image.panorama img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 83%;
  object-fit: cover;
  object-position: center top;
}

/* モーダル本体 */
.modal__wrapper {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10;
  z-index: 20;
  width: 100%;
  height: 100%;
}

.modal__layer {
  height: 100%;
  background: rgba(50, 50, 50, .85);
  cursor: pointer;
}

.modal__container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(calc(100% - 40px), 1000px);
  max-height: calc(100% - 40px);
}

.modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  background: rgba(50, 50, 50, 1);
  cursor: pointer;
  transition: opacity .6s;
}

.modal__close:hover {
  opacity: .6;
}

.modal__close:before,
.modal__close:after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 1px;
  background: #fff;
  content: '';
}

.modal__close:before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.modal__close:after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.modal__content .modal__image img {
  width: 100%;
}
