﻿:root {
  --primary: #0052cc;
  --primary-dark: #0747a6;
  --primary-light: #deebff;
  --accent: #ff5630;
  --accent-hover: #de350b;
  --dark: #091e42;
  --text-main: #172b4d;
  --text-sub: #5e6c84;
  --bg: #f4f6f8;
  --card-bg: #ffffff;
  --border: #e2e8f0;
  --success-bg: #e3fcef;
  --success-text: #006644;
  --radius: 12px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg);
  color: var(--text-main);
  line-height: 1.7;
  padding-bottom: 80px; /* スマホ固定フッター用余白 */
}

.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 24px 16px;
}

/* ヘッダー・ヒーロー */
header {
  text-align: center;
  padding: 36px 16px 28px;
  background: linear-gradient(135deg, #091e42 0%, #0052cc 100%);
  color: #fff;
  border-radius: var(--radius);
  margin-bottom: 24px;
  box-shadow: 0 10px 20px rgba(9, 30, 66, 0.15);
}
.badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 14px;
  letter-spacing: 0.05em;
}
header h1 {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 12px;
}
.hero-desc {
  font-size: 1.05rem;
  opacity: 0.9;
  max-width: 600px;
  margin: 0 auto;
}

/* カード共通 */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 30px;
  margin-bottom: 24px;
  box-shadow: 0 4px 12px rgba(9, 30, 66, 0.04);
}
.card h2 {
  font-size: 1.35rem;
  color: var(--dark);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 2px solid #edf2f7;
  padding-bottom: 12px;
}

/* 構造比較ブロック（VDSL vs 直引き） */
.compare-box {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 20px 0;
}
@media (max-width: 640px) {
  .compare-box { grid-template-columns: 1fr; }
}
.compare-item {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  background: #fafbfc;
}
.compare-item.winner {
  border: 2px solid var(--primary);
  background: #f0f7ff;
}
.compare-item-title {
  font-weight: bold;
  font-size: 1.1rem;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
}
.speed-tag-bad { color: #de350b; font-weight: bold; }
.speed-tag-good { color: var(--primary); font-weight: bold; }

/* テーブル */
.table-responsive { overflow-x: auto; margin: 16px 0; }
table { width: 100%; border-collapse: collapse; text-align: left; font-size: 0.95rem; }
th, td { padding: 12px 14px; border: 1px solid var(--border); }
th { background-color: #f8fafc; color: var(--dark); font-weight: bold; }
.highlight-cell { background-color: #ebf5ff; font-weight: bold; color: var(--primary); }

/* シミュレーター */
.calc-panel {
  background: #f8faff;
  border: 1px solid #cce0ff;
  border-radius: 10px;
  padding: 22px;
  margin-top: 14px;
}
.price-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.95rem;
}
.price-total {
  border-top: 2px dashed #cbd5e1;
  padding-top: 14px;
  margin-top: 14px;
  align-items: center;
}
.real-price {
  font-size: 2.2rem;
  color: var(--accent);
  font-weight: 800;
}

/* フォーム */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 600px) { .grid-2 { grid-template-columns: 1fr; } }
label { display: block; font-size: 0.9rem; font-weight: bold; margin-bottom: 6px; color: var(--dark); }
select, input, textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 1rem;
  margin-bottom: 14px;
  background: #fafbfc;
  transition: all 0.2s ease;
}
select:focus, input:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(0, 82, 204, 0.15);
}

/* ボタン */
.btn {
  display: inline-block;
  width: 100%;
  padding: 16px 20px;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}
.btn-cta {
  background: var(--accent);
  color: #fff;
  margin-top: 18px;
  box-shadow: 0 4px 14px rgba(255, 86, 48, 0.35);
}
.btn-cta:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}
.btn-copy {
  background: #e2e8f0;
  color: var(--dark);
  padding: 8px 16px;
  font-size: 0.85rem;
  width: auto;
  border-radius: 6px;
}
.btn-copy:hover { background: #cbd5e1; }

/* 判定バッジ */
.score-badge { display: inline-block; padding: 6px 14px; border-radius: 6px; font-weight: bold; margin-bottom: 10px; }
.score-high { background: var(--success-bg); color: var(--success-text); }
.score-mid { background: #fff0b3; color: #172b4d; }

.output-area {
  background: #282c34;
  color: #abb2bf;
  border: 1px solid #1e2227;
  border-radius: 8px;
  padding: 16px;
  font-family: Consolas, Monaco, monospace;
  white-space: pre-wrap;
  font-size: 0.9rem;
  max-height: 280px;
  overflow-y: auto;
}

/* ロードマップ */
.step-list { list-style: none; margin: 16px 0; padding-left: 0; }
.step-item { display: flex; gap: 16px; margin-bottom: 20px; }
.step-number {
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  min-width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
}
.step-content { flex: 1; }
.step-title { font-weight: bold; font-size: 1.05rem; margin-bottom: 4px; color: var(--dark); }

/* FAQ */
.faq-item { margin-bottom: 16px; border-bottom: 1px solid var(--border); padding-bottom: 12px; }
.faq-q { font-weight: bold; color: var(--dark); margin-bottom: 6px; }
.faq-a { color: var(--text-sub); font-size: 0.95rem; }

/* スマホ固定追従CTAバー */
.sticky-footer-cta {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #ffffff;
  border-top: 1px solid var(--border);
  padding: 12px 16px;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  max-width: 860px;
  margin: 0 auto;
}
.sticky-footer-cta .text { font-size: 0.9rem; font-weight: bold; color: var(--dark); }
.sticky-footer-cta .text span { color: var(--accent); font-size: 1.2rem; }
.sticky-footer-cta .btn-small {
  background: var(--accent);
  color: #fff;
  padding: 10px 18px;
  border-radius: 6px;
  font-weight: bold;
  text-decoration: none;
  font-size: 0.95rem;
}
