/* リセット & ベース */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* メンズ脱毛向けカラー：クール&クリーン */
  --primary-color: #3b82f6; /* ブルー */
  --primary-hover: #2563eb; /* ダークブルー */
  --secondary-color: #06b6d4; /* シアン */
  --success-color: #10b981; /* グリーン */
  --bg-color: #f8fafc;
  --card-bg: #ffffff;
  --text-primary: #0f172a; /* ダークブルーグレー */
  --text-secondary: #475569; /* グレー */
  --border-color: #e2e8f0;
  --shadow:
    0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg:
    0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

body {
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  background: linear-gradient(to bottom, #f8fafc 0%, #e0f2fe 100%); /* 淡いブルーグラデーション */
  min-height: 100vh;
  line-height: 1.6;
  color: var(--text-primary);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* ヘッダー */
.header {
  background: linear-gradient(135deg, #1e40af 0%, #0284c7 100%); /* ブルーグラデーション */
  padding: 20px 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-logo {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
}

.site-logo a {
  color: white;
  text-decoration: none;
}

.header-nav {
  display: flex;
  gap: 20px;
}

.header-nav a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 4px;
  transition: background 0.3s;
}

.header-nav a:hover {
  background: rgba(255, 255, 255, 0.1);
}

.title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
  text-align: center;
}

.subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  text-align: center;
}

/* カード */
.card {
  background: var(--card-bg);
  border-radius: 16px;
  padding: 32px;
  box-shadow: var(--shadow-lg);
  margin-bottom: 20px;
}

/* スクリーン管理 */
.screen {
  display: none;
}

.screen.active {
  display: block;
}

/* 開始画面 */
.description {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin: 20px 0;
}

.feature-list {
  list-style: none;
  margin: 24px 0;
}

.feature-list li {
  padding: 12px 0;
  font-size: 1.1rem;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
}

.feature-list li:last-child {
  border-bottom: none;
}

/* ボタン */
.btn {
  display: inline-block;
  width: 100%;
  padding: 16px 32px;
  font-size: 1.1rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 10px;
}

.btn:focus,
.btn:focus-visible {
  outline: 3px solid rgba(124, 58, 237, 0.5);
  outline-offset: 2px;
}

.btn-primary {
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--secondary-color)
  );
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: var(--bg-color);
  color: var(--text-primary);
  border: 2px solid var(--border-color);
}

.btn-secondary:hover {
  background: white;
  border-color: var(--primary-color);
}

.btn-cta {
  background: var(--success-color);
  color: white;
  font-size: 1.2rem;
  padding: 18px 32px;
}

.btn-cta:hover {
  background: #059669;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* プログレスバー */
.progress-bar {
  width: 100%;
  height: 8px;
  background: var(--bg-color);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 20px;
}

.progress-fill {
  height: 100%;
  background: var(--primary-color);
  transition: width 0.4s ease;
  border-radius: 10px;
}

.question-number {
  color: var(--text-secondary);
  text-align: center;
  font-size: 1rem;
  margin-bottom: 20px;
}

/* 質問 */
.question-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--text-primary);
}

.options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.option {
  padding: 16px 20px;
  background: var(--bg-color);
  border: 2px solid var(--border-color);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
  text-align: left;
}

.option:hover {
  background: white;
  border-color: var(--primary-color);
  transform: translateX(4px);
}

/* 結果画面 */
.result-card {
  text-align: center;
}

.result-intro {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin: 16px 0 24px;
}

.teacher-result {
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  padding: 24px;
  border-radius: 12px;
  margin: 24px 0;
  text-align: left;
}

.teacher-name {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 12px;
}

.teacher-site {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.teacher-specialties {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
}

.specialty-tag {
  background: white;
  color: var(--primary-color);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}

.teacher-description {
  font-size: 1rem;
  color: var(--text-primary);
  line-height: 1.7;
  margin-top: 16px;
}

.teacher-match {
  background: var(--success-color);
  color: white;
  padding: 12px;
  border-radius: 8px;
  margin-top: 16px;
  font-weight: 600;
}

/* CTA セクション */
.cta-section {
  margin: 32px 0;
  padding: 24px;
  background: linear-gradient(135deg, #1e40af, #0284c7);
  border-radius: 12px;
  color: white; /* 白文字に変更 */
}

.cta-section h3 {
  color: white; /* 白文字に変更 */
  margin-bottom: 12px;
}

.cta-section p {
  color: white; /* 白文字に変更 */
}

.cta-text {
  color: white; /* 白文字に変更 */
  margin-bottom: 16px;
}

.cta-text strong {
  color: var(--secondary-color);
  font-size: 1.2rem;
}

/* フッター */
.footer {
  background: #1f2937;
  color: white;
  text-align: center;
  margin-top: 60px;
  padding: 40px 20px;
  font-size: 0.9rem;
}

.footer a {
  color: white;
  text-decoration: none;
  transition: opacity 0.3s;
}

.footer a:hover {
  opacity: 0.7;
}

/* レスポンシブ */
@media (max-width: 640px) {
  body {
    padding: 10px;
  }

  .title {
    font-size: 2rem;
  }

  .subtitle {
    font-size: 1rem;
  }

  .card {
    padding: 24px;
  }

  .btn {
    padding: 14px 24px;
    font-size: 1rem;
  }

  .question-title {
    font-size: 1.3rem;
  }

  .teacher-name {
    font-size: 1.5rem;
  }

  .teachers-list {
    grid-template-columns: 1fr;
  }
}

/* 複数の占い師カード表示 */
.teachers-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.teacher-card {
  position: relative;
  background: white;
  border: 2px solid var(--border-color);
  border-radius: 12px;
  padding: 20px;
  transition: all 0.3s ease;
}

.teacher-card:hover {
  border-color: var(--primary-color);
  box-shadow: var(--shadow-md);
}

.teacher-card:focus-within {
  border-color: var(--primary-color);
  box-shadow: var(--shadow-md);
}

.rank-badge {
  position: absolute;
  top: -10px;
  right: 10px;
  padding: 6px 12px;
  border-radius: 20px;
  font-weight: bold;
  font-size: 0.85rem;
  color: white;
}

.rank-badge.rank-1 {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
}

.rank-badge.rank-2 {
  background: linear-gradient(135deg, #94a3b8, #64748b);
}

.rank-badge.rank-3 {
  background: linear-gradient(135deg, #fb923c, #f97316);
}

.teacher-header {
  margin-bottom: 12px;
}

.teacher-name {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.teacher-site {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.teacher-rating {
  font-size: 0.95rem;
  color: var(--secondary-color);
  margin-bottom: 12px;
  font-weight: 500;
}

.btn-teacher,
a.btn-teacher {
  display: block;
  width: 100%;
  padding: 12px 20px;
  background: var(--primary-color) !important;
  color: white !important;
  text-align: center;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  margin-top: 12px;
}

.btn-teacher:hover,
a.btn-teacher:hover {
  background: var(--primary-hover) !important;
  box-shadow: var(--shadow-md);
}

.btn-teacher:focus,
.btn-teacher:focus-visible,
a.btn-teacher:focus,
a.btn-teacher:focus-visible {
  background: #7c3aed !important;
  color: #ffffff !important;
  outline: 3px solid rgba(124, 58, 237, 0.5) !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.1) !important;
  text-decoration: none !important;
  transform: none !important;
  opacity: 1 !important;
  visibility: visible !important;
}
