:root {
  --fg: #1f2937;
  --fg-muted: #6b7280;
  --bg: #ffffff;
  --bg-alt: #f9fafb;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --accent-fg: #ffffff;
  --card: #ffffff;
  --border: #e5e7eb;
  --success-bg: #ecfdf5;
  --success-fg: #047857;
  --error-bg: #fef2f2;
  --error-fg: #b91c1c;
}
@media (prefers-color-scheme: dark) {
  :root {
    --fg: #f3f4f6;
    --fg-muted: #9ca3af;
    --bg: #0f172a;
    --bg-alt: #1e293b;
    --accent: #3b82f6;
    --accent-dark: #2563eb;
    --accent-fg: #ffffff;
    --card: #1e293b;
    --border: #334155;
    --success-bg: #064e3b;
    --success-fg: #6ee7b7;
    --error-bg: #7f1d1d;
    --error-fg: #fecaca;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { max-width: 880px; margin: 0 auto; padding: 0 24px; }
section { padding: 60px 0; }
section.alt { background: var(--bg-alt); }
h1, h2, h3 { line-height: 1.4; }
h2 { font-size: 22px; margin: 0 0 24px; text-align: center; }
h3 { font-size: 16px; margin: 0 0 8px; }

.nav { padding: 16px 0; border-bottom: 1px solid var(--border); }
.nav .container { display: flex; justify-content: space-between; align-items: center; }
.nav-brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 16px; color: inherit; text-decoration: none; }
.nav-brand img { width: 24px; height: 24px; }
.nav-cta { font-size: 13px; padding: 6px 14px; border: 1px solid var(--accent); color: var(--accent); border-radius: 9999px; }

.hero { padding: 80px 0 60px; text-align: center; }
.hero h1 { font-size: 32px; margin: 0 0 16px; letter-spacing: 0.02em; }
.hero .lead { font-size: 16px; color: var(--fg-muted); margin: 0 0 32px; }
.hero .cta-group { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.cta-primary {
  display: inline-block; padding: 14px 32px; background: var(--accent); color: var(--accent-fg);
  border-radius: 9999px; font-weight: 600; font-size: 15px; transition: background 0.15s;
}
.cta-primary:hover { background: var(--accent-dark); text-decoration: none; }
.cta-secondary {
  display: inline-block; padding: 14px 32px; border: 1.5px solid var(--accent); color: var(--accent);
  border-radius: 9999px; font-weight: 600; font-size: 15px;
}
.cta-secondary:hover { text-decoration: none; background: var(--accent); color: var(--accent-fg); }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.feature-card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 20px; text-align: center; }
.feature-icon { display: flex; justify-content: center; margin: 4px 0 12px; color: var(--accent); }
.feature-icon svg { width: 40px; height: 40px; }
.feature-card h3 { text-align: left; }
.feature-card p { margin: 8px 0 0; font-size: 13px; color: var(--fg-muted); text-align: left; }

.badge-beta {
  display: inline-block;
  background: #fef3c7; color: #92400e;
  font-size: 11px; font-weight: 700;
  padding: 2px 7px; border-radius: 999px;
  margin-left: 6px; vertical-align: 1px;
  letter-spacing: 0.02em;
}
@media (prefers-color-scheme: dark) {
  .badge-beta { background: #78350f; color: #fef3c7; }
}

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.step-card { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 20px; position: relative; }
.step-num {
  position: absolute; top: -12px; left: 16px; width: 28px; height: 28px;
  background: var(--accent); color: var(--accent-fg); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px;
}
.step-card h3 { margin-top: 8px; }
.step-card p { margin: 4px 0 0; font-size: 13px; color: var(--fg-muted); }

.install-lead { text-align: center; margin: 0 auto 24px; max-width: 640px; font-size: 14px; color: var(--fg-muted); }
.install-compare {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px; margin-bottom: 32px;
}
.install-card {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 20px;
}
.install-card.recommended {
  border-color: #f59e0b; border-width: 2px;
  background: linear-gradient(180deg, rgba(245,158,11,0.06), transparent 60%), var(--card);
}
.install-card .install-badge {
  display: inline-block; background: #f59e0b; color: #fff; font-size: 11px;
  font-weight: 700; padding: 2px 8px; border-radius: 9999px; margin-bottom: 8px;
}
.install-card h3 { font-size: 15px; margin: 0 0 12px; }
.install-card ul { margin: 0; padding-left: 18px; font-size: 13px; color: var(--fg-muted); line-height: 1.8; }
.install-card.recommended ul li::marker { color: #16a34a; }
.install-card:not(.recommended) ul li::marker { color: #b91c1c; }

.install-steps {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.install-step {
  background: var(--bg-alt); border: 1px solid var(--border); border-radius: 12px; padding: 16px;
}
.install-step h4 { margin: 0 0 8px; font-size: 14px; }
.install-step p { margin: 0; font-size: 13px; color: var(--fg-muted); line-height: 1.7; }

.form { max-width: 560px; margin: 0 auto; }
.form-row { margin-bottom: 16px; }
.form-row label { display: block; font-size: 13px; font-weight: 600; color: var(--fg-muted); margin-bottom: 6px; }
.form-row input, .form-row select, .form-row textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px;
  background: var(--card); color: var(--fg); font-size: 15px; font-family: inherit;
}
.form-row textarea { min-height: 140px; resize: vertical; }
.form-row input:focus, .form-row select:focus, .form-row textarea:focus {
  outline: 2px solid var(--accent); outline-offset: -1px; border-color: var(--accent);
}
.form-honeypot { position: absolute; left: -10000px; visibility: hidden; }
.form-submit {
  width: 100%; padding: 14px 24px; background: var(--accent); color: var(--accent-fg);
  border: none; border-radius: 9999px; font-weight: 600; font-size: 15px; cursor: pointer;
}
.form-submit:disabled { opacity: 0.6; cursor: not-allowed; }
.form-feedback { margin-top: 16px; padding: 12px 16px; border-radius: 8px; font-size: 14px; }
.form-feedback.success { background: var(--success-bg); color: var(--success-fg); }
.form-feedback.error { background: var(--error-bg); color: var(--error-fg); }
.form-note { font-size: 12px; color: var(--fg-muted); margin-bottom: 16px; }

.stats-sample { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 16px; }
.stats-sample .sample-caption {
  font-size: 12px; color: var(--fg-muted); margin: 0 0 12px;
}
.stats-sample h3 {
  font-size: 13px; margin: 4px 0 8px; color: var(--fg-muted); font-weight: 600;
}
.stats-sample h3:not(:first-child) { margin-top: 24px; }
.stats-sample .chart-wrap { width: 100%; overflow-x: auto; }
.stats-sample svg.chart {
  display: block; width: 100%; max-width: 480px; height: auto; margin: 0 auto;
  color: var(--fg-muted);
}
.stats-sample .legend {
  display: flex; gap: 14px; justify-content: center;
  font-size: 11px; color: var(--fg-muted); margin-top: 4px;
}
.stats-sample .legend .swatch {
  display: inline-block; width: 10px; height: 10px; border-radius: 2px; vertical-align: middle; margin-right: 4px;
}
.stats-sample .table-wrap { overflow-x: auto; }
.stats-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 520px; }
.stats-table th, .stats-table td { padding: 6px 8px; text-align: right; border-bottom: 1px solid var(--border); white-space: nowrap; }
.stats-table th { font-weight: 600; color: var(--fg-muted); font-size: 11px; }
.stats-table th:first-child, .stats-table td:first-child { text-align: left; }
.stats-table tr:last-child td { border-bottom: none; }
.stats-table tr.total td { font-weight: 700; background: var(--bg-alt); }
.stats-table .num-pos { color: var(--success-fg); }

.footer { padding: 32px 0; border-top: 1px solid var(--border); color: var(--fg-muted); font-size: 12px; text-align: center; }
