.photoParallaxBox {
  /*background-color: #333;*/
  background-color: #fff;
  position: relative;
  z-index: 99;
  margin: 0 auto;
}

.photoParallaxInBox {
  width: auto;
  max-width: 100%;
  margin-top: 100px;
  height: calc(100dvh - 100px);  /* この高さが重要 */
  margin: 0 auto;
  position: relative;
  aspect-ratio: 32 / 9;
}

.photoParallax {
  position: relative; /* 親要素として位置を指定 */
  height: 100%;  /* 親の高さに依存 */
}

.parallaxBackground {
  position: sticky;
  top: 250px;
  left: 0;
  width: 100%;
  aspect-ratio: 32 / 9;
  background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg1.png");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: top center;
  z-index: 1;
}

.parallaxBackground.inView {
  animation: bgAn 3.5s linear forwards;
}

@keyframes bgAn {
  0% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg1.png");
  }
  5.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg2.png");
  }
  11% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg3.png");
  }
  16.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg4.png");
  }
  22% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg5.png");
  }
  27.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg6.png");
  }
  33% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg7.png");
  }
  38.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg8.png");
  }
  44% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg9.png");
  }
  49.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg10.png");
  }
  55% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg11.png");
  }
  60.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg12.png");
  }
  66% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg13.png");
  }
  71.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg14.png");
  }
  77% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg15.png");
  }
  82.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg16.png");
  }
  88% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg17.png");
  }
  93.5% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg18.png");
  }
  100% {
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg19.png");
  }
}

.photoParallaxTop {
  position: absolute;
  z-index: 10001;
  right: 10px;
  bottom: 10px;
  color: #fff;
  background-color: #9b2222;
  text-align: center;
  font-size: 12px;
  line-height: 1.5em;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  font-weight: 600;
  cursor: pointer;
  letter-spacing: -1px;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0.75;
  transition: 0.5s;
}

.photoParallaxTop:hover {
  opacity: 1;
}

.photoLayerBox {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
}

.photoLayer {
  position: relative;
  top: 0;
  left: 0;
  width: 100%;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  opacity: 1;
  transition: all 1s ease-out;
  z-index: 1;
  background-image: unset !important;
}

.photoLayer img {
  max-width: 100%;
}

.photo1, .photo2, .photo3, .photo4, .photo5, .photo6, .photo7, .photo8, .photo9, .photo10, .photo11, .photo12, .photo13, .photo14, .photo15, .photo16, .photo17 {
  opacity: 0;
}

.photoFixed {
  position: absolute;
  left: 0;
  top: 0;
  overflow: hidden;
}

.photoFixed img {
  opacity: 0;
  transition: 0.5s ease-in-out;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 通常のフェードイン */
.photoFixedFadein.inView img {
  opacity: 1;
}

/* 左からのスライド */
.photoFixedLeft img {
  transform: translateX(-10dvw);
}

.photoFixedLeft.inView img {
  opacity: 1;
  transform: translateX(0);
}

/* 右からのスライド */
.photoFixedRight img {
  transform: translateX(10dvw);
}

.photoFixedRight.inView img {
  opacity: 1;
  transform: translateX(0);
}

/* 上からのスライド */
.photoFixedDown img {
  transform: translateY(-10dvw);
}

.photoFixedDown.inView img {
  opacity: 1;
  transform: translateY(0);
}

/* 下からのスライド */
.photoFixedUp img {
  transform: translateY(10dvw);
}

.photoFixedUp.inView img {
  opacity: 1;
  transform: translateY(0);
}

/* 中央から大きく */
.photoFixedBig img {
  transform: scale(0);
}

.photoFixedBig.inView img {
  opacity: 1;
  transform: scale(1);
}

/* 大きいのを縮める */
.photoFixedShrink img {
  transform: scale(10);
  transform-origin: center;
}

.photoFixedShrink.inView img {
  opacity: 1;
  transform: scale(1);
}

.photoF11 {
  transition: 0.75s ease-in-out;
}

.photoF11.inView {
  background-color: rgba(255, 255, 255, 0.9);
}

.photoParallaxLayer {
  position: fixed;
  z-index: 1002;
  bottom: 0;
  left: 0;
  background-color: rgba(255, 0, 0, 0.5);
  color: #fff;
  font-weight: 600;
  font-size: 12px;
  line-height: 1.25em;
  padding: 3px 5px;
  letter-spacing: -1px;
}


@media all and (max-width: 1024px) { /* SP */
  .photoParallaxInBox {
    aspect-ratio: 11 / 24;
  }

  .parallaxBackground {
    position: fixed;
    background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg1_sp.png");
    aspect-ratio: 11 / 24;
    height: 100%;
    width: auto;
    left: 50%;
    transform: translate(-50%, 0);
  }

  @keyframes bgAn {
    0% {
      background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg1_sp.png");
    }
    100% {
      background-image: url("/wp-content/themes/manga-biz2024/images/top/mangaAnimation/bg/bg1_sp.png");
    }
  }

  .photoParallaxTop {
    bottom: 30px;
  }
}