/* ===== ヒーローセクション - トップページのメインビジュアル ===== */

/* === 基本レイアウト === */
.hero-section {
  height: 100vh; /* 画面全体の高さ */
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--bg) 0%, var(--light) 100%);
  position: relative;
  overflow: hidden; /* 背景パターンがはみ出すのを防ぐ */
}

/* === 背景装飾パターン === */
/* 軽い点線パターンで視覚的な深みを演出 */
.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 25% 25%, rgba(139, 115, 85, 0.05) 2px, transparent 2px),
    radial-gradient(circle at 75% 75%, rgba(139, 115, 85, 0.05) 2px, transparent 2px);
  background-size: 80px 80px, 120px 120px;
  animation: backgroundFloat 30s ease-in-out infinite; /* ゆっくりとした動き */
}

/* === メインコンテンツエリア === */
.hero-content {
  text-align: center;
  /* アニメーション初期状態：非表示 + 下にずらす */
  opacity: 0;
  transform: translateY(30px);
  animation: heroFadeIn 1.2s ease-out 0.3s forwards; /* 0.3秒後にフェードイン */
  z-index: 1;
  position: relative;
  max-width: 90%;
  width: 100%;
  padding-bottom: 160px; /* スクロールインジケーターとの距離確保 */
}

/* === タイトル部分 === */
.hero-title {
  font-size: clamp(2.5rem, 7vw, 4.5rem); /* レスポンシブフォントサイズ */
  margin: 5rem 0 2rem 0;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: -0.01em; /* 文字間をわずかに詰める */
  line-height: 1.2;
  font-family: "Kaisei HarunoUmi";
  letter-spacing: 0.1rem;
}

/* ゲーム紹介の小さなサブタイトル */
.hero-subtitle-small {
  font-size: 0.45em; /* タイトルの45%サイズ */
  font-weight: 400;
  color: var(--accent);
  display: inline-block;
  margin-left: 0.5em;
  vertical-align: bottom;
  margin-top: 0.1em;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

/* メインサブタイトル */
.hero-subtitle {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  margin: 0 0 2rem 0;
  opacity: 0.8;
  line-height: 1.5;
  max-width: 550px;
  margin-left: auto;
  margin-right: auto;
  color: var(--ink);
}

/* === ゲーム情報表示エリア === */
/* プレイ人数、時間、年齢などを表示する3つのカード */
.hero-features {
  display: flex;
  justify-content: center;
  gap: 0rem;
  margin: 0 0 1rem 0;
  /* アニメーション：1秒後に表示開始 */
  opacity: 0;
  animation: heroFeaturesIn 1s ease-out 1s forwards;
  flex-wrap: wrap; /* 小さい画面で折り返し */
}

/* 個別の情報カード */
.hero-feature {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  /* グラスモーフィズム効果 */
  padding: 1rem 1rem;
  border-radius: 20px;
  backdrop-filter: blur(10px);
  min-width: 65px;
  flex-shrink: 0;
}

.hero-feature img {
  filter: invert(34%) sepia(28%) saturate(10%) hue-rotate(27deg) brightness(116%) contrast(98%);
  max-width: 100px;
}

/* カード内の数字（人数、時間など） */
.feature-number {
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  font-weight: 700;
  color: var(--accent);
  display: block;
  margin: 0 0 0.5rem 0;
  line-height: 1;
}

/* カード内のラベル（「人」「分」など） */
.feature-label {
  font-size: clamp(0.8rem, 1.8vw, 0.95rem);
  color: var(--ink);
  opacity: 0.8;
  font-weight: 500;
  margin: 0;
  line-height: 1.2;
}

/* === スクロール促進インジケーター === */
.scroll-indicator {
  position: absolute;
  bottom: 3rem;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  /* 1.8秒後に表示開始 */
  opacity: 0;
  animation: scrollIndicatorIn 1s ease-out 1.8s forwards;
  z-index: 10;
}

/* スクロール促進テキスト */
.scroll-text {
  font-size: 0.9rem;
  color: var(--accent);
  margin-bottom: 0.5rem;
  font-weight: 400;
  opacity: 0.9;
  white-space: nowrap; /* 改行しない */
}

/* スクロール矢印 */
.scroll-arrow {
  font-size: 1.2rem;
  color: var(--accent);
  animation: bounce 2.5s infinite ease-in-out 2.2s; /* 2.2秒後からバウンス開始 */
  opacity: 0.7;
}

/* ===== レスポンシブ対応 ===== */

/* === タブレット（768px以下） === */
@media (max-width: 768px) {
  .hero-content {
    max-width: 95%;
    padding-bottom: 120px; /* スクロールインジケーターとの距離調整 */
  }

  .hero-title {
    margin-bottom: 1.5rem;
  }
  
  .hero-subtitle {
    margin-bottom: 3rem;
  }

  .hero-features {
    gap: 0; /* カード間の距離を縮める */
    margin-bottom: 4rem;
  }
  
  .hero-feature {
    padding: 1rem 1rem; /* パディング調整 */
    min-width: 50px;
  }

  .scroll-indicator {
    bottom: 2rem;
  }
}

/* === スマートフォン（480px以下） === */
@media (max-width: 480px) {
  .hero-content {
    padding-bottom: 100px;
  }

  .hero-title {
    margin-bottom: 1rem;
    font-size: clamp(2rem, 8vw, 3rem); /* フォントサイズを調整 */
  }
  
  .hero-subtitle {
    margin-bottom: 2.5rem;
    font-size: clamp(1rem, 3vw, 1.2rem);
  }

  .hero-features {
    gap: 1rem;
    align-items: center;
    margin-bottom: 3rem;
  }
  
  /* カードを横向きレイアウトに変更 */
  .hero-feature {
    flex-direction: row;
    gap: 0;
    padding: 0.5rem 0.2rem;
    min-width: 40px;
    width: auto;
    max-width: 200px;
  }
  
  .feature-number {
    margin: 0;
  }
  
  .feature-label {
    margin: 0;
    align-self: center;
  }
  
  .scroll-indicator {
    bottom: 1.5rem;
  }

  .scroll-text {
    font-size: 0.8rem;
  }
}

/* === 画面高さ対応 === */

/* 高さが低い画面（700px以下） */
@media (max-height: 700px) {
  .hero-content {
    padding-bottom: 100px;
  }
  
  .hero-title {
    margin-bottom: 1rem;
  }
  
  .hero-subtitle {
    margin-bottom: 2.5rem;
  }
  
  .hero-features {
    margin-bottom: 3rem;
  }
  
  .scroll-indicator {
    bottom: 1.5rem;
  }
}

/* 非常に高さが低い画面（600px以下） */
@media (max-height: 600px) {
  .hero-content {
    transform: scale(0.9); /* 全体を90%に縮小 */
    padding-bottom: 90px;
  }
  
  .hero-features {
    margin-bottom: 2rem;
  }
  
  .scroll-indicator {
    bottom: 1rem;
  }
}
