/* Micromodal styles */
.modal {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.modal__overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  opacity: 0;
  transition: background-color 0.3s ease, opacity 0.3s ease;
}

.modal-container {
  background-color: white;
  max-width: 90vw;
  max-height: 90vh;
  width: 100%;
  position: relative;
  overflow: visible;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  /* 開く時：少し上から出現 */
  transform: translateY(100px) scale(0.95);
  opacity: 0;
  transition: all 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@media (min-width: 768px) {
  .modal-container {
    max-width: 80vw;
    max-height: 85vh;
  }
}

@media (min-width: 1024px) {
  .modal-container {
    max-width: 50vw;
    max-height: 90vh;
  }
}

.modal.is-open .modal-container {
  /* 開いた状態：元の位置に戻る */
  transform: translateY(0) scale(1);
  opacity: 1;
}

.modal.is-open .modal__overlay {
  background: rgba(0, 0, 0, 0.8);
  opacity: 1;
}

/* Closing animation */
.modal.is-closing .modal__overlay {
  background: rgba(0, 0, 0, 0);
}

/* 閉じる時：少し下に下がる */
.modal.is-closing .modal-container {
  transform: translateY(100px) scale(0.95);
  opacity: 0;
  transition: all 0.6s cubic-bezier(0.55, 0.055, 0.675, 0.19);
}

.modal.is-closing {
  opacity: 0;
  visibility: hidden;
}

.modal__header {
  position: sticky;
  top: 0;
  background: white;
  z-index: 10;
}

.modal_content {
  overflow-y: auto;
  max-height: calc(95vh - 4rem);
}

@media (min-width: 768px) {
  .modal_content {
    max-height: calc(95vh - 4rem);
  }
}

@media (min-width: 1024px) {
  .modal_content {
    max-height: calc(95vh - 4rem);
  }
}

.modal_close {
  position: absolute;
  top: -1.5rem;
  right: -1.5rem;
  background: rgba(180, 180, 180, 0.9);
  border: none;
  border-radius: 50%;
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 30;
  /* モーダルよりも高いz-index */
  transition: background-color 0.3s;
}

.modal_close:hover {
  background: rgba(220, 220, 220, 0.9);
}

.modal_close svg {
  width: 1.25rem;
  height: 1.25rem;
}

/* YouTube iframe */
.youtube-container {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
}

.youtube-iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}


/*   Title  */


.section-title-3 {
  margin: 0;
  padding: 25px 25px 27px 25px;
  font-family: "Open Sans", Arial, Helvetica, sans-serif;
  font-weight: 300;
  font-size: 30px;
  line-height: 30px;
}

/* Swiper Custom Styles */
.fullscreen-slider {
  width: 100%;
  height: 100vh;
  --swiper-navigation-color: #fff;
  --swiper-pagination-color: #fff;
  --swiper-navigation-size: 44px;
}

.swiper-slide {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.slide-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 1;
}

.slide-content {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  text-align: center;
}

/* Typography */
.slide-title-xl {
  font-size: clamp(3rem, 8vw, 8rem);
  font-weight: 100;
  letter-spacing: 0.2em;
  line-height: 0.9;
  text-transform: uppercase;
  margin-bottom: 0;
}

.slide-title-lg {
  font-size: clamp(2rem, 5vw, 4rem);
  font-weight: 100;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin: 1rem 0;
}

.slide-title-bold {
  font-size: clamp(2.5rem, 6vw, 6rem);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 1.5rem;
}

.slide-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.5rem);
  font-weight: 300;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin: 2rem 0;
}

/* Buttons */
.btn-custom {
  padding: 1rem 2.5rem;
  font-size: 1rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 2px solid rgba(255, 255, 255, 0.8);
  background: transparent;
  color: white;
  text-decoration: none;
  display: inline-block;
  margin: 0 0.5rem;
  transition: all 0.3s ease;
}

.btn-custom:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: white;
  color: white;
  text-decoration: none;
}

/* Navigation */
.swiper-button-next,
.swiper-button-prev {
  margin-top: 0;
  top: 50%;
  transform: translateY(-50%);
}

.swiper-button-next {
  right: 20px;
}

.swiper-button-prev {
  left: 20px;
}

.swiper-pagination {
  bottom: 20px;
}

/* Play Button */
.play-button {
  width: 80px;
  height: 80px;
  border: 3px solid rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  background: transparent;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.play-button:hover {
  border-color: white;
  background: rgba(255, 255, 255, 0.1);
  transform: scale(1.1);
}

/* Slide 3 Layout */
.slide-3-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
}

.slide-3-text {
  flex: 1;
  padding-left: 5%;
}

.slide-3-play {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Animations */
.swiper-slide-active .animate-1 {
  animation: slideInUp 1s ease-out 0.2s both;
}

.swiper-slide-active .animate-2 {
  animation: slideInUp 1s ease-out 0.4s both;
}

.swiper-slide-active .animate-3 {
  animation: slideInUp 1s ease-out 0.6s both;
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .swiper-button-next,
  .swiper-button-prev {
    display: none;
  }

  .slide-subtitle {
    display: none;
  }

  .btn-custom {
    display: block;
    margin: 0.5rem auto;
    width: 200px;
    text-align: center;
  }

  .slide-3-content {
    flex-direction: column;
    text-align: center;
  }

  .slide-3-text {
    padding: 0 1rem;
    margin-bottom: 2rem;
  }

  .play-button {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }
}

@media (max-width: 576px) {
  .slide-title-xl {
    font-size: 2.5rem;
  }

  .slide-title-lg {
    font-size: 1.8rem;
  }

  .slide-title-bold {
    font-size: 2rem;
  }
}

/* KVエリアYouTube用 */
.header {
  position: relative;
  display: flex;
  height: 55vw;
  max-height: 80vh;
  background: #000;
  overflow: hidden;
}

.header__background {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 0;
  padding-bottom: 66.25%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.header__video-overlay {
  position: absolute;
  width: 100%;
  height: 100%;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  transition: opacity 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94), visibility 0.5s linear;
}

.header__video-overlay--fadeOut {
  opacity: 0;
  visibility: hidden;
}

.header iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.header__title {
  position: relative;
  flex: 0 0 auto;
  align-self: center;
  width: 100%;
  font-family: "Permanent Marker", cursive;
  font-size: 50px;
  font-weight: normal;
  text-align: center;
  color: white;
  line-height: 1;
}

@media screen and (max-width: 768px) {
  .header {
    height: 75vw;
    max-height: 75vh;
    overflow: hidden;
  }

  .header__background {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
    overflow: hidden;
  }

  .header iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 180%;
    /* 幅を強制的に拡大 */
    height: 180%;
    /* 高さも拡大 */
    min-width: none;
    min-height: none;
    transform: translate(-50%, -50%) scale(1);
    object-fit: cover;
    overflow: hidden;
  }
}

/* Style for the grid container to ensure it fills the header height */
.header > .grid {
  height: 100%;
}

/* Animation for the background reveal */
@keyframes slideInFromLeft {
  0% {
    transform: scaleX(0);
    transform-origin: left;
  }

  100% {
    transform: scaleX(1);
    transform-origin: left;
  }
}

/* Apply the animation to the background */
.bg-reveal {
  animation: slideInFromLeft 1.2s ease-out forwards;
}

/* Alternative approach using a class instead of inline styles */
.red-bg-column {
  position: relative;
}

.red-bg-column::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #b20107;
  opacity: 0.8;
  z-index: 0;
}

.red-bg-column > * {
  position: relative;
  z-index: 1;
}

.text-forum {
  font-family: "Forum", serif;
  font-weight: 400;
  font-style: normal;
}

.text-serif {
  font-family: "Noto Serif JP", serif;
  font-weight: 400;
  font-style: normal;
}

.section-title-2 {
  margin: 0;
  padding: 25px 25px 27px 25px;
  font-family: "Open Sans", Arial, Helvetica, sans-serif;
  font-weight: 300;
  font-size: 30px;
  line-height: 30px;
  color: #4b4e53;
}

/* Mobile navigation positioning */
@media (max-width: 1023px) {
  .testimonial-mobile-nav {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    z-index: 20;
    /* Position relative to the text area */
    transform: translateY(-100%);
  }
}

.spec-table {
  border-collapse: collapse;
  width: calc(950 / 16 * 1em);
  margin: 5em auto 0;

  th,
  td {
    font-size: calc(18 / 16 * 1em);
    padding: calc(10 / 14 * 1em) calc(20 / 14 * 1em);
    border: 1px solid #b3b3b3;
    vertical-align: middle;
    position: relative;
  }

  th {
    background-color: #ede2da;
    text-align: center;
    font-weight: 400;

    &.center {
      text-align: center;
    }
  }

  @media screen and (max-width: 750px) {
    margin: 3em auto 0;
    width: calc(350 / 375 * 100%);

    /*
    th {
      white-space: nowrap;
    }
    */

    th,
    td {
      font-size: calc(14 / 16 * 1em);
      padding: calc(4 / 11 * 1em) calc(4 / 11 * 1em);
    }
  }
}

/* コンバージョンエリア */
.cvtslide-up {
  animation: slideUp 0.5s forwards;
}

.cvtslide-down {
  animation: slideDown 0.3s forwards;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }

  to {
    transform: translateY(0);
  }
}

@keyframes slideDown {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(100%);
  }
}

.ribbon-bow {
  background: linear-gradient(45deg, #d4af37, #f4e4a6, #d4af37);
}
