:root {
  --bg: #f6f7fb;
  --surface: #ffffff;
  --text: #1c2333;
  --muted: #6b7385;
  --border: #e3e6ee;
  --primary: #1f6feb;
  --primary-dark: #1859c2;
  --accent: #12a150;
  --danger: #d1342f;
  --warning-bg: #fff7e0;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(20, 30, 60, 0.06), 0 4px 16px rgba(20, 30, 60, 0.05);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.9rem; margin: 0.4em 0 0.6em; line-height: 1.2; }
h2 { font-size: 1.25rem; margin: 0 0 0.75em; }
h3 { font-size: 1.05rem; margin: 1em 0 0.5em; }
code { background: #eef1f6; padding: 0.1em 0.35em; border-radius: 4px; }

.container { max-width: 980px; margin: 0 auto; padding: 0 20px; }
.container-wide { max-width: 1200px; }
main.container { padding-top: 24px; padding-bottom: 48px; min-height: 70vh; }

.site-header { background: var(--surface); border-bottom: 1px solid var(--border); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { font-weight: 800; font-size: 1.2rem; color: var(--text); letter-spacing: -0.01em; }
.brand span { color: var(--primary); }
.brand:hover { text-decoration: none; }
.nav { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.nav a { color: var(--text); font-weight: 500; }
.nav a.button { color: #fff; }
.inline-form { display: inline; margin: 0; }
.link-button { background: none; border: 0; padding: 0; font: inherit; color: var(--muted); cursor: pointer; }
.link-button:hover { color: var(--text); }

.site-footer { border-top: 1px solid var(--border); background: var(--surface); color: var(--muted); font-size: 0.85rem; padding: 24px 0; }
.site-footer p { margin: 0.4em 0; }

.button {
  display: inline-block; background: var(--primary); color: #fff; border: 0; border-radius: 8px;
  padding: 10px 18px; font: inherit; font-weight: 600; cursor: pointer; text-align: center;
}
.button:hover { background: var(--primary-dark); text-decoration: none; }
.button-small { padding: 6px 14px; }
.button-large { padding: 14px 32px; font-size: 1.1rem; }
.button-block { display: block; width: 100%; }
.button-secondary { background: #eef1f6; color: var(--text); }
.button-secondary:hover { background: #e2e6ee; }
.button-danger { background: var(--danger); }
.button-danger:hover { background: #b02a26; }

.alert { padding: 12px 16px; border-radius: 8px; margin-bottom: 20px; }
.alert-success { background: #e6f6ec; color: #0e6b37; }
.alert-error { background: #fdeaea; color: #9b1c18; }
.alert-warning { background: var(--warning-bg); color: #7a5a00; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); margin-bottom: 20px; }
.card-highlight { border: 2px solid var(--primary); }
.card-danger { border-color: #f3c4c2; margin-top: 20px; }
.form-card { max-width: 480px; margin: 24px auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.grid-2 > .card, .grid-3 > .card { margin-bottom: 0; }
.grid-2 + .grid-2, .grid-2 + .card, .stats-grid + .grid-2 { margin-top: 20px; }
@media (max-width: 760px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 16px; margin-bottom: 20px; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.stat-value { font-size: 1.8rem; font-weight: 700; }
.stat-label { color: var(--muted); font-weight: 500; }
.stat-hint { color: var(--muted); font-size: 0.8rem; }

.form { display: flex; flex-direction: column; gap: 14px; margin-bottom: 18px; }
.form label { display: flex; flex-direction: column; gap: 6px; font-weight: 500; font-size: 0.95rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
input, textarea, select {
  font: inherit; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; background: #fff; color: var(--text); width: 100%;
}
input:focus, textarea:focus { outline: 2px solid rgba(31, 111, 235, 0.25); border-color: var(--primary); }
.form .checkbox { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 400; }
.form .checkbox input { width: auto; margin-top: 4px; }
.hint { color: var(--muted); font-size: 0.82rem; font-weight: 400; }

.table { width: 100%; border-collapse: collapse; margin-bottom: 12px; font-size: 0.95rem; }
.table th, .table td { text-align: left; padding: 9px 8px; border-bottom: 1px solid var(--border); vertical-align: top; }
.table th { color: var(--muted); font-weight: 600; font-size: 0.85rem; }
.table .num { text-align: right; }
.card .table:last-child { margin-bottom: 0; }
@media (max-width: 760px) { .card { overflow-x: auto; } }

.badge { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; background: #e6f0ff; color: var(--primary); font-size: 0.75rem; font-weight: 600; }
.badge-danger { background: #fdeaea; color: var(--danger); margin-left: 0; }

.muted { color: var(--muted); }
.small { font-size: 0.85rem; }
.center { text-align: center; }

.hero { text-align: center; padding: 40px 0 24px; }
.hero h1 { font-size: 2.6rem; max-width: 760px; margin: 0.3em auto; }
.hero .lead { font-size: 1.15rem; color: var(--muted); max-width: 680px; margin: 0 auto 24px; }
.invited-by { display: inline-block; background: #e6f0ff; color: var(--primary-dark); padding: 6px 16px; border-radius: 999px; }
.sponsor-note { max-width: 560px; margin: 28px auto 0; background: var(--surface); border-left: 4px solid var(--primary); padding: 16px 20px; text-align: left; border-radius: 8px; box-shadow: var(--shadow); }
.sponsor-note p { margin: 0 0 8px; white-space: pre-line; }
.sponsor-note cite { color: var(--muted); font-style: normal; font-weight: 600; }
.section { margin-top: 48px; }
.section > h2 { text-align: center; font-size: 1.6rem; margin-bottom: 24px; }
.step { width: 34px; height: 34px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; }
.price { font-size: 2rem; font-weight: 700; margin: 0.2em 0; }
.price span { font-size: 1rem; font-weight: 500; }
.checklist { padding: 0; list-style: none; }
.checklist li { padding: 4px 0 4px 26px; position: relative; }
.checklist li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.faq { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 14px 18px; margin-bottom: 10px; }
.faq summary { font-weight: 600; cursor: pointer; }
.faq p { margin: 10px 0 0; color: var(--muted); }

.link-card .copy-row { display: flex; gap: 10px; flex-wrap: wrap; }
.copy-input { flex: 1; min-width: 220px; font-family: ui-monospace, Consolas, monospace; }

.chart { display: flex; align-items: flex-end; gap: 3px; height: 140px; padding: 6px 0; border-bottom: 1px solid var(--border); }
.chart-col { flex: 1; height: 100%; display: flex; align-items: flex-end; }
.chart-bar { width: 100%; background: var(--primary); border-radius: 3px 3px 0 0; min-height: 2px; opacity: 0.85; }
.chart-col:hover .chart-bar { opacity: 1; }

.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 16px; }
.breadcrumb .sep { color: var(--muted); }

.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.search-row { display: flex; gap: 10px; margin-bottom: 12px; }
.search-row input { flex: 1; }
.pager { display: flex; gap: 16px; align-items: center; justify-content: center; }
.upline { padding-left: 20px; }
.plain-list { padding-left: 18px; }

.prose { max-width: 720px; margin: 0 auto; background: var(--surface); padding: 28px 32px; border-radius: var(--radius); border: 1px solid var(--border); }

.button-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.form-inline { display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end; }
.form-inline .hint { flex-basis: 100%; }

.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-top: 12px; }
.plan-card { border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; display: flex; flex-direction: column; gap: 6px; }
.plan-card h3 { margin: 0; }
.plan-card .button { margin-top: auto; }
.plan-price { font-size: 1.8rem; font-weight: 700; }
.plan-price span { font-size: 1rem; font-weight: 500; color: var(--muted); }

.capture { max-width: 640px; margin: 0 auto; text-align: center; }
.capture h1 { font-size: 2rem; margin-top: 4px; }
.capture .prose { text-align: left; border: 0; background: none; padding: 0 0 8px; }
.capture .form-card { text-align: left; }
.capture-link { margin-bottom: 16px; }
.capture-link .copy-row { margin-top: 6px; }

.step-form { border-top: 1px solid var(--border); padding-top: 16px; margin-top: 16px; }
.step-form h3 { margin: 0; }
