:root {
  --primary-color: #4A90E2;
  --primary-dark: #357ABD;
  --secondary-color: #5BA7F7;
  --accent-color: #FF6B6B;
  --text-color: #2C3E50;
  --text-secondary: #7F8C8D;
  --background-color: #ffffff;
  --card-background: #f8fbff;
  --border-color: #e1ecf4;
  --shadow-sm: 0 2px 12px rgba(74, 144, 226, 0.08);
  --shadow-md: 0 4px 20px rgba(74, 144, 226, 0.12);
  --shadow-lg: 0 8px 40px rgba(74, 144, 226, 0.16);
  --gradient-bg: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-hero: linear-gradient(135deg, #4A90E2 0%, #5BA7F7 50%, #72C5F7 100%);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; /* モダンなサンセリフに変更 */
  line-height: 1.7; /* 行間を少し広げる */
  color: var(--text-color);
  background-color: var(--background-color);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased; /* フォントのアンチエイリアス */
  -moz-osx-font-smoothing: grayscale;
}

html {
  scroll-behavior: smooth;
}

.container {
  max-width: 1100px; /* 少し狭めてコンテンツのまとまりを良くする */
  margin: 0 auto;
  padding: 0 1.5rem; /* 左右のパディングを少し調整 */
}

.section-title {
  font-size: 2.2rem; /* 少し小さくしてバランス調整 */
  font-weight: 700;
  text-align: center;
  margin-bottom: 1.5rem; /* マージン調整 */
  letter-spacing: -0.01em;
  color: var(--text-color);
}

.section-subtitle {
  font-size: 1.1rem; /* 少し小さく */
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 2.5rem; /* マージン調整 */
  font-weight: 400;
  max-width: 600px; /* サブタイトルが長くなりすぎないように */
  margin-left: auto;
  margin-right: auto;
}

/* Hero Section */
.hero {
  background: var(--gradient-hero);
  padding: 8rem 0 6rem;
  position: relative;
  overflow: hidden;
  color: white;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  animation: float 20s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(-30px, -30px) rotate(180deg); }
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 4rem;
  position: relative;
  z-index: 1;
}

.hero-content {
  text-align: left; /* テキストは左揃えに戻す */
}

.hero-title {
  font-size: 4rem;
  font-weight: 800;
  margin-bottom: 1rem;
  color: white;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.hero-subtitle {
  font-size: 1.15rem; /* サイズ調整 */
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 1.5rem;
  font-weight: 400; /* 太さを調整 */
}

.main-message {
  font-size: 1.8rem;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 3rem;
  line-height: 1.4;
  font-weight: 600;
}

.hero-image {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.app-mockup {
  width: 100%;
  max-width: 300px;
  height: auto;
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.2));
  transition: transform 0.3s ease;
  border-radius: 1.5rem;
}

.app-mockup:hover {
  transform: translateY(-10px);
}

.final-cta .app-mockup {
  border-radius: 0;
  max-width: 400px;
  height: 90px;
  width: auto;
}

.store-badge {
  display: inline-block;
  height: 70px;
  width: auto;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.15));
}

.store-badge:hover {
  transform: scale(1.05) translateY(-2px);
}

/* 課題提起セクション */
.problem {
  padding: 4rem 0;
  background: var(--background-color);
}

.problem-grid {
  display: grid; /* problem-grid は grid のままの方が良さそう */
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem; /* カード間のギャップを少し詰める */
}

.problem-card {
  padding: 2rem 1.5rem;
  background: var(--card-background);
  border-radius: 1rem; /* 角丸を少し小さく */
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm); /* 影を新しい定義に */
  text-align: center; /* problem-card 内のテキストも中央揃え */
}

.problem-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-color);
}

.problem-icon {
  font-size: 2.5rem; /* アイコンサイズ調整 */
  margin-bottom: 1rem;
}

.problem-card p {
  font-size: 1rem; /* テキストサイズ調整 */
  line-height: 1.6;
}

/* Features Section */
.features {
  padding: 6rem 0;
  background: var(--card-background);
  position: relative;
}

.features::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100px;
  background: linear-gradient(to bottom, var(--card-background), transparent);
  z-index: 1;
}

.features-showcase {
  margin-top: 3rem; /* showcase のマージン調整 */
}

.feature-item {
  display: grid;
  grid-template-columns: 1fr 1fr; /* 画像とテキストを左右に配置 */
  gap: 3rem; /* 要素間のギャップ調整 */
  align-items: center;
  margin-bottom: 4rem;
}

/* 画像がないfeature-itemのためのスタイルを追加 */
.feature-item.text-only {
  display: block;
  text-align: center;
}

.feature-item.text-only .feature-content {
  grid-column: 1 / -1; /* コンテンツをグリッド全体に広げる */
  text-align: center; /* テキストを中央揃え */
  max-width: 700px; /* 最大幅を設定して読みやすくする */
  margin-left: auto;
  margin-right: auto;
}

.feature-item.text-only .feature-content ul {
  text-align: left;
  display: inline-block;
}

.feature-item.reverse {
  direction: ltr;
}

.feature-item.reverse .feature-content {
  direction: ltr;
  order: 1;
}

.feature-item.reverse .feature-image {
  order: 2;
}
/* text-only で reverse の場合も中央揃えにする */
.feature-item.text-only.reverse .feature-content {
  text-align: center;
}

.feature-image {
  width: 100%;
  max-width: 380px; /* 画像の最大幅調整 */
  margin: 0 auto;
}

.feature-screenshot {
  width: 100%;
  height: auto;
  border-radius: 1rem; /* 角丸調整 */
  box-shadow: var(--shadow-md); /* 影を新しい定義に */
  transition: transform 0.3s ease;
}

.feature-screenshot:hover {
  transform: scale(1.03); /* ホバー時のスケール調整 */
}

.feature-content {
  /* text-align: left; feature-item の中で制御するので不要かも */
}

.feature-content h3 {
  font-size: 2.2rem;
  margin-bottom: 1.5rem;
  color: var(--text-color);
  font-weight: 700;
}

.feature-content ul {
  list-style: none; /* リストマーカーを削除 */
  padding-left: 0;
}

.feature-content li {
  margin-bottom: 0.75rem;
  font-size: 1rem;
  position: relative;
  padding-left: 1.8em; /* アイコン分のスペース */
}

.feature-content li::before {
  content: "✓";
  color: var(--primary-color);
  position: absolute;
  left: 0;
  font-weight: bold;
  font-size: 1.1rem;
}

/* Highlights Section */
.highlights {
  padding: 6rem 0;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  position: relative;
}

.highlights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* minmax調整 */
  gap: 1.5rem;
}

.highlight-item {
  padding: 3rem 2rem;
  background: white;
  border-radius: 1.5rem;
  border: none;
  text-align: center;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.highlight-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 4px;
  background: var(--gradient-hero);
  transition: left 0.3s ease;
}

.highlight-item:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.highlight-item:hover::before {
  left: 0;
}

.highlight-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color); /* アイコンの色をプライマリーカラーに */
}

.highlight-item h3 {
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--text-color);
}

.highlight-item p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Target Section */
.target {
  padding: 6rem 0;
  background: var(--card-background);
}
.target-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); /* minmax調整 */
  gap: 1.5rem;
}
.target-item {
  display: flex;
  align-items: center;
  padding: 2rem;
  background: white;
  border-radius: 1rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}
.target-item:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-color);
}
.target-icon {
  font-size: 2.5rem;
  margin-right: 1.5rem;
  flex-shrink: 0;
  color: var(--primary-color);
}
.target-item p {
  font-size: 1.125rem;
  color: var(--text-color);
  line-height: 1.6;
  margin: 0;
}

/* Final CTA */
.final-cta {
  padding: 6rem 0;
  background: var(--gradient-hero);
  color: white;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.final-cta::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 70%);
  animation: float 25s ease-in-out infinite reverse;
}
.final-cta h2 {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  font-weight: 800;
  position: relative;
  z-index: 1;
}
.final-cta p {
  font-size: 1.3rem;
  margin-bottom: 3rem;
  color: rgba(255, 255, 255, 0.9);
  position: relative;
  z-index: 1;
}
.final-cta .hero-image {
  /* .hero-image のスタイルを再利用、または専用スタイル作成 */
  margin-top: 1rem;
}
.final-cta .store-badge {
  height: 80px;
  position: relative;
  z-index: 1;
}
.final-cta .store-badge:hover {
  transform: scale(1.05);
}

/* フッター */
.footer {
  padding: 2.5rem 0;
  background: #2b3a42; /* フッター背景色を濃い色に */
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
}
.footer p {
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}
.footer a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
}
.footer a:hover {
  color: white;
  text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 968px) {
  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3rem;
  }
  .hero-content {
    text-align: center;
    order: 1;
  }
  .hero-image {
    order: 2;
    margin-bottom: 2rem;
  }
  .hero-title {
    font-size: 2.5rem;
  }
  .main-message {
    font-size: 1.5rem;
  }
  .section-title {
    font-size: 2rem;
  }

  .feature-item,
  .feature-item.reverse {
    grid-template-columns: 1fr; /* 1列表示 */
    direction: ltr; /* reverse解除 */
    text-align: center; /* feature-item自体を中央揃え */
  }
  .feature-item .feature-content {
    text-align: center;
    padding: 0 1rem;
    grid-column: auto;
    max-width: none;
  }
  
  .feature-item .feature-content ul {
    text-align: left;
    display: inline-block;
    max-width: 280px;
  }
  
  .feature-item.reverse .feature-content {
    text-align: center;
  }
  
  .feature-item.reverse .feature-content ul {
    text-align: left;
    display: inline-block;
    max-width: 280px;
  }
  .feature-image {
    margin-bottom: 2rem; /* 画像とコンテンツの間隔 */
    order: -1; /* 画像を上に持ってくる */
  }
  .feature-content h3 {
    margin-top: 1rem; /* 画像とテキストの間のマージン */
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 1rem; /* スマホ表示では左右パディングをさらに詰める */
  }
  .hero {
    padding: 3rem 0;
  }
  .hero-title {
    font-size: 2.5rem;
  }
  .main-message {
    font-size: 1.3rem;
  }
  .section-title {
    font-size: 1.8rem;
  }
  .problem-grid,
  .highlights-grid,
  .target-grid {
    grid-template-columns: 1fr;
  }
  .target-item {
    flex-direction: column;
    text-align: center;
  }
  .target-icon {
    margin-right: 0;
    margin-bottom: 1rem;
  }
  .feature-item {
    gap: 1.5rem; /* スマホ時のgap調整 */
  }
  .feature-image {
    max-width: 300px; /* スマホ時の画像サイズ調整 */
  }
  .final-cta h2 {
    font-size: 2rem;
  }
  .final-cta p {
    font-size: 1.1rem;
  }
  .features::before {
    display: none;
  }
}

/* アニメーション関連は一旦削除またはコメントアウト */
/*
@keyframes float { ... }
.hero::before { ... }
*/

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideIn {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(0);
  }
}

/*
.problem-card,
.highlight-item,
.target-item {
  animation: fadeInUp 0.5s ease-out forwards;
  opacity: 0;
}

.problem-card:nth-child(1) { animation-delay: 0.1s; }
.problem-card:nth-child(2) { animation-delay: 0.2s; }
.problem-card:nth-child(3) { animation-delay: 0.3s; }

.highlight-item:nth-child(1) { animation-delay: 0.1s; }
.highlight-item:nth-child(2) { animation-delay: 0.2s; }
.highlight-item:nth-child(3) { animation-delay: 0.3s; }
*/

/* Header Styles */
.site-header {
  background-color: var(--background-color);
  padding: 1rem 0;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: box-shadow 0.3s ease;
}

.site-header.scrolled {
  box-shadow: var(--shadow-sm);
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.site-branding a {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
  text-decoration: none;
}

.main-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
}

.main-navigation li {
  margin-left: 1.5rem;
}

.main-navigation a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  transition: color 0.3s ease;
}

.main-navigation a:hover,
.main-navigation a.active {
  color: var(--primary-color);
}

/* ハンバーガーメニュー */
.nav-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
  width: 30px;
  height: 30px;
  justify-content: center;
  align-items: center;
  background: none;
  border: none;
  padding: 0;
}

.nav-toggle .bar {
  width: 25px;
  height: 3px;
  background: var(--text-color);
  border-radius: 3px;
  transition: all 0.3s ease;
  transform-origin: center;
}

.nav-toggle .bar:not(:last-child) {
  margin-bottom: 5px;
}

/* ハンバーガーメニューアニメーション */
.nav-toggle.active .bar:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.nav-toggle.active .bar:nth-child(2) {
  opacity: 0;
  transform: translateX(-20px);
}

.nav-toggle.active .bar:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* レスポンシブ対応 (ヘッダー) */
@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }
  
  .main-navigation {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: white;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    transform: translateY(-10px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
  }
  
  .main-navigation.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  
  .main-navigation ul {
    flex-direction: column;
    padding: 1rem 0;
    gap: 0;
  }
  
  .main-navigation li {
    margin-left: 0;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.5s ease forwards;
  }
  
  .main-navigation.active li:nth-child(1) { animation-delay: 0.1s; }
  .main-navigation.active li:nth-child(2) { animation-delay: 0.2s; }
  .main-navigation.active li:nth-child(3) { animation-delay: 0.3s; }
  .main-navigation.active li:nth-child(4) { animation-delay: 0.4s; }
  
  .main-navigation a {
    display: block;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
  }
  
  .main-navigation li:last-child a {
    border-bottom: none;
  }
  
  .main-navigation a:hover {
    background: var(--card-background);
    color: var(--primary-color);
    padding-left: 2rem;
  }
}
