/* ===================================================
   みらいそ沖縄 - 新メインビジュアル用CSS
   ファイル: /css/mv-new.css
   =================================================== */

/* ===== MV Container ===== */
.mv-container {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
}

/* ===== 既存MV（フェードアウト用） ===== */
.mv-original {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
  background: url("../img/top_mv.jpg") no-repeat center center;
  background-size: cover;
  transition: opacity 1.5s ease, transform 1.5s ease;
}

.mv-original.fade-out {
  opacity: 0;
  transform: scale(1.05);
  pointer-events: none;
}

.mv-original .original-content {
  position: absolute;
  top: 50%;
  left: 6vw;
  transform: translateY(-50%);
  z-index: 10;
  max-width: 900px;
}

/* 1画面目：見出しスタイル（2画面目と同じ） */
.mv-original .original-heading h2 {
  font-family: 'Zen Old Mincho', serif;
  font-weight: 400;
  font-size: clamp(1.6rem, 3.5vw, 2.6rem);
  line-height: 1.8;
  color: #1a1a1a;
}

.mv-original .original-heading h2 span {
  display: inline-block;
  background: rgba(255, 255, 255, 0.92);
  padding: 10px 25px;
  margin-bottom: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
}

/* 1画面目：タグライン */
.mv-original .original-tagline {
  margin-top: 30px;
}

.mv-original .original-tagline p {
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  font-size: clamp(0.9rem, 1.5vw, 1.3rem);
  letter-spacing: 0.15em;
  background: linear-gradient(90deg, #0d747f, #569ea6, #4ecdc4, #c77dff, #0d747f);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-transform: uppercase;
  animation: mvGradientText 5s linear infinite;
}

/* 1画面目：右下デコレーション */
.mv-original .original-deco {
  position: absolute;
  bottom: 10%;
  right: 6vw;
  z-index: 10;
  text-align: right;
}

.mv-original .original-deco .brand-tag {
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  color: #555;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(13, 116, 127, 0.15);
  display: inline-block;
  border-radius: 4px;
  backdrop-filter: blur(5px);
}

/* ===== ヘッダーナビ黒文字（MV表示中） ===== */
.header .inner__pc .pc__navi li a {
  color: #333 !important;
}

.header .inner__pc .pc__navi li a.contact__navi {
  color: #FFF !important;
}

/* ===== 新MV ===== */
.mv-new {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  background: linear-gradient(180deg, #ffffff 0%, #f8f9fa 50%, #f0f2f5 100%);
}

/* ★★★ 重要：canvasはクリックを通さない ★★★ */
#particle-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0 !important;
  pointer-events: none !important;
  display: block !important;
}

.mv-new-mesh-gradient {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
  background: 
    radial-gradient(circle at 10% 20%, rgba(255, 107, 107, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(78, 205, 196, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(199, 125, 255, 0.05) 0%, transparent 50%);
}

/* ===== Content ===== */
.mv-new-content {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 6vw;
  opacity: 0;
  transition: opacity 1s ease 0.5s;
}

.mv-new-content.visible {
  opacity: 1;
}

.mv-new-heading {
  max-width: 900px;
}

.mv-new-heading h1 {
  font-family: 'Zen Old Mincho', serif;
  font-weight: 400;
  font-size: clamp(1.6rem, 3.5vw, 2.6rem);
  line-height: 1.8;
  color: #1a1a1a;
}

/* Pattern D: 各行に白背景 */
.mv-new-heading h1 span {
  display: block;  /* blockに変更 */
  width: fit-content;  /* テキストサイズに合わせる */
  background: rgba(255, 255, 255, 0.92);
  padding: 10px 25px;
  margin-bottom: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
  opacity: 0;
  transform: translateY(30px);
}

@media (max-width: 768px) {
  .mv-new-heading h1 span {
    padding: 8px 15px;
    margin-bottom: 8px;
  }
}

.mv-new-heading h1 span.animate {
  animation: mvFadeInUp 0.8s ease forwards;
}

.mv-new-heading h1 span:nth-child(1).animate { animation-delay: 0.1s; }
.mv-new-heading h1 span:nth-child(2).animate { animation-delay: 0.3s; }

@keyframes mvFadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Tagline（大きく） ===== */
.mv-new-tagline {
  margin-top: 30px;
  opacity: 0;
  transform: translateY(20px);
}

.mv-new-tagline.animate {
  animation: mvFadeInUp 0.8s ease 0.6s forwards;
}

.mv-new-tagline p {
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  font-size: clamp(0.9rem, 1.5vw, 1.3rem);
  letter-spacing: 0.15em;
  background: linear-gradient(90deg, #0d747f, #569ea6, #4ecdc4, #c77dff, #0d747f);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-transform: uppercase;
  animation: mvGradientText 5s linear infinite;
}

@keyframes mvGradientText {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

/* ===== Decoration（右下） ===== */
/* ★★★ 重要：mv-new-decoをcanvasより手前に ★★★ */
.mv-new-deco {
  position: absolute;
  bottom: 10%;
  right: 6vw;
  z-index: 20 !important;
  text-align: right;
  opacity: 0;
  pointer-events: auto !important;
}

.mv-new-deco.animate {
  animation: mvFadeIn 1s ease 0.8s forwards;
}

@keyframes mvFadeIn {
  to { opacity: 1; }
}

.mv-new-deco .brand-tag {
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  color: #555;
  padding: 12px 24px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(13, 116, 127, 0.15);
  display: inline-block;
  border-radius: 4px;
  backdrop-filter: blur(5px);
}

/* ===== Scroll Indicator ===== */
.mv-new-scroll-indicator {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  opacity: 0;
}

.mv-new-scroll-indicator.animate {
  animation: mvFadeIn 1s ease 1s forwards;
}

.mv-new-scroll-indicator span {
  display: block;
  width: 2px;
  height: 50px;
  background: linear-gradient(to bottom, #0d747f, #4ecdc4, transparent);
  margin: 0 auto 10px;
  animation: mvScrollPulse 2s ease-in-out infinite;
  border-radius: 2px;
}

.mv-new-scroll-indicator p {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  color: #999;
  text-transform: uppercase;
}

@keyframes mvScrollPulse {
  0%, 100% { opacity: 0.5; transform: scaleY(0.8); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .mv-container {
    min-height: 100vh;
  }

  .mv-new-content {
    padding: 0 5%;
    justify-content: center;
  }

  .mv-new-heading h1 {
    font-size: 1.3rem;
    line-height: 1.9;
  }

  .mv-new-heading h1 span {
    padding: 8px 15px;
    margin-bottom: 8px;
  }

  /* 1画面目レスポンシブ */
  .mv-original .original-content {
    left: 5%;
    right: 5%;
  }

  .mv-original .original-heading h2 {
    font-size: 1.3rem;
    line-height: 1.9;
  }

  .mv-original .original-heading h2 span {
    padding: 8px 15px;
    margin-bottom: 8px;
  }

  .mv-original .original-tagline {
    margin-top: 20px;
  }

  .mv-original .original-tagline p {
    font-size: 0.75rem;
    letter-spacing: 0.1em;
  }

  .mv-original .original-deco {
    display: none;
  }

  .mv-new-tagline p {
    font-size: 0.75rem;
    letter-spacing: 0.1em;
  }

  .mv-new-deco {
    display: none;
  }
}

/* h1の基本スタイル */
.mv-new-heading h1 {
  line-height: 1.6;
  letter-spacing: 0.05em;
  font-size: clamp(1.4rem, 4vw, 2.2rem);
}

.mv-new-heading h1 span {
  display: block;
  word-break: break-word;
}

/* スマホ専用改行 */
.sp-only {
  display: none;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .mv-new-heading h1 {
    font-size: 1.4rem;
    line-height: 1.8;
    padding: 0 15px;
    box-sizing: border-box;
  }
  
  .sp-only {
    display: block;
  }
  
  /* スマホで各行の間隔を調整 */
  .mv-new-heading h1 span {
    margin-bottom: 8px;
  }
}

@media (max-width: 640px) {
  .mv-new-heading h1 {
    font-size: 1.2rem;
    line-height: 1.7;
  }
}