:root {
  --bg: #ffffff;
  --surface: #f8fafc;
  --surface-2: #eef2f7;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --accent: #0f172a;
  --accent-2: #2563eb;
  --success: #047857;
  --warning: #b45309;
  --radius: 22px;
  --shadow: 0 20px 60px rgba(15, 23, 42, 0.08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a { color: inherit; }
img { max-width: 100%; display: block; }

.container {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 72px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 900;
  text-decoration: none;
  letter-spacing: -0.03em;
}

.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 22px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.nav a {
  text-decoration: none;
}

.nav a:hover { color: var(--text); }

.btn,
button.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 16px;
  background: var(--accent);
  color: #fff;
  padding: 13px 18px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.16);
}

.btn:hover { transform: translateY(-1px); }
.btn-secondary {
  background: #fff;
  color: var(--text);
  border: 1px solid var(--line);
  box-shadow: none;
}

.hero {
  padding: 82px 0 64px;
  background: radial-gradient(circle at top right, #dbeafe 0, transparent 35%), linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 48px;
  align-items: center;
}

.eyebrow,
.badge {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 8px;
  border: 1px solid #bbf7d0;
  background: #f0fdf4;
  color: #166534;
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 800;
}

.badge.is-special { border-color: #bfdbfe; background: #eff6ff; color: #1d4ed8; }
.badge.is-info { border-color: #fed7aa; background: #fff7ed; color: #c2410c; }
.badge.is-neutral { border-color: var(--line); background: var(--surface); color: var(--muted); }

h1, h2, h3, h4 {
  margin: 0;
  line-height: 1.08;
  letter-spacing: -0.04em;
}

h1 {
  margin-top: 22px;
  font-size: clamp(42px, 6vw, 72px);
  max-width: 950px;
}

.hero p,
.lead {
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 19px;
  line-height: 1.8;
  max-width: 720px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.hero-card {
  border: 1px solid var(--line);
  border-radius: 32px;
  background: #fff;
  padding: 26px;
  box-shadow: var(--shadow);
}

.hero-card h2 { font-size: 24px; }
.card-list {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.mini-card {
  border-radius: 20px;
  background: var(--surface);
  padding: 16px;
}

.mini-card strong { display: block; }
.mini-card span { display: block; color: var(--muted); font-size: 14px; margin-top: 4px; }

.section {
  padding: 72px 0;
}

.section.is-muted { background: var(--surface); }
.section-head {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  align-items: end;
  margin-bottom: 30px;
}

.section-title {
  margin-top: 14px;
  font-size: clamp(30px, 4vw, 44px);
}

.section-copy {
  margin: 14px 0 0;
  color: var(--muted);
  max-width: 760px;
}

.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-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 24px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
}

.card:hover { box-shadow: var(--shadow); }
.card h3 { font-size: 22px; margin-top: 16px; }
.card p { color: var(--muted); margin: 12px 0 0; }
.card .url {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  margin-top: 10px;
  word-break: break-word;
}

.card-footer {
  border-top: 1px solid var(--line);
  margin-top: 18px;
  padding-top: 18px;
}

.tag-list,
.link-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: var(--surface-2);
  color: #475569;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 750;
}

.text-link {
  color: var(--accent-2);
  font-weight: 800;
  text-decoration: none;
}
.text-link:hover { text-decoration: underline; }

.filter-bar {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.input,
.select,
.textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 16px;
  padding: 14px 15px;
  font: inherit;
  outline: none;
}

.input:focus,
.select:focus,
.textarea:focus { box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12); border-color: #93c5fd; }

.search-input { width: 280px; }

.check-list {
  display: grid;
  gap: 12px;
  padding: 0;
  margin: 20px 0 0;
  list-style: none;
}

.check-list li {
  display: flex;
  gap: 10px;
  color: var(--muted);
}

.check-list li::before {
  content: "✓";
  color: var(--success);
  font-weight: 900;
}

.content-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 34px;
  align-items: start;
}

.prose {
  border: 1px solid var(--line);
  border-radius: 30px;
  background: #fff;
  padding: min(7vw, 46px);
  box-shadow: 0 10px 34px rgba(15, 23, 42, 0.04);
}

.prose h2 { margin-top: 38px; font-size: 30px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 26px; font-size: 24px; }
.prose p { color: var(--muted); font-size: 17px; }
.prose ul { padding-left: 20px; color: var(--muted); }
.prose li { margin: 7px 0; }

.sidebar {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 16px;
}

.sidebar-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  padding: 20px;
  box-shadow: 0 10px 34px rgba(15, 23, 42, 0.04);
}
.sidebar-card h3 { font-size: 18px; }
.sidebar-card ul { padding-left: 18px; color: var(--muted); }
.sidebar-card li { margin: 7px 0; }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 20px;
}
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--text); }

.cta {
  border-radius: 34px;
  background: var(--accent);
  color: #fff;
  padding: 48px;
}
.cta p { color: #cbd5e1; max-width: 700px; }
.cta .input,
.cta .select,
.cta .textarea { border-color: rgba(255,255,255,0.16); }
.cta-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 32px; align-items: start; }

.form-grid { display: grid; gap: 14px; }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
label span { display: block; color: #e2e8f0; font-size: 13px; font-weight: 800; margin-bottom: 7px; }

.site-footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 34px 0;
  color: var(--muted);
  font-size: 14px;
}
.footer-grid { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.footer-links { display: flex; gap: 16px; flex-wrap: wrap; }
.footer-links a { text-decoration: none; color: var(--muted); }
.footer-links a:hover { color: var(--text); }

.skip-link {
  position: absolute;
  left: -999px;
  top: 10px;
  background: #fff;
  padding: 10px;
  z-index: 100;
}
.skip-link:focus { left: 10px; }

@media (max-width: 980px) {
  .hero-grid, .content-layout, .cta-grid { grid-template-columns: 1fr; }
  .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sidebar { position: static; }
  .nav { display: none; }
}

@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .section-head { align-items: stretch; flex-direction: column; }
  .form-row { grid-template-columns: 1fr; }
  .hero { padding: 52px 0; }
  .section { padding: 52px 0; }
  .cta { padding: 26px; border-radius: 26px; }
  .header-inner { min-height: 64px; }
  .btn { width: 100%; }
  .header-inner .btn { width: auto; }
  .search-input { width: 100%; }
}

.facts-box {
  margin: 26px 0 34px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  padding: 22px;
}

.facts-box h2 {
  margin-top: 0;
  font-size: 24px;
}

.facts-table {
  width: 100%;
  margin-top: 14px;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 18px;
}

.facts-table th,
.facts-table td {
  border-top: 1px solid var(--line);
  padding: 14px 12px;
  text-align: left;
  vertical-align: top;
}

.facts-table th {
  width: 190px;
  color: var(--text);
  font-size: 14px;
}

.facts-table td {
  color: var(--muted);
}

.prose a.text-link,
.sidebar a.text-link,
.card a.text-link {
  overflow-wrap: anywhere;
}

@media (max-width: 640px) {
  .facts-table,
  .facts-table tbody,
  .facts-table tr,
  .facts-table th,
  .facts-table td {
    display: block;
    width: 100%;
  }
  .facts-table th { padding-bottom: 4px; }
  .facts-table td { padding-top: 0; }
}

.reader-box {
  margin: 0 0 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  padding: 22px;
}

.reader-box + .reader-box { margin-top: 16px; }
.reader-box h2 { margin-top: 0; font-size: 24px; }
.reader-box .check-list { margin-top: 14px; }

.numbered-list {
  counter-reset: steps;
  list-style: none;
  padding: 0;
  margin: 20px 0 0;
  display: grid;
  gap: 12px;
}

.numbered-list li {
  counter-increment: steps;
  position: relative;
  padding: 16px 16px 16px 56px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  color: var(--muted);
}

.numbered-list li::before {
  content: counter(steps);
  position: absolute;
  left: 16px;
  top: 14px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
  font-size: 13px;
}

.section-table { margin: 22px 0; }

.estimator {
  margin: 34px 0;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #fff;
  padding: 26px;
  box-shadow: 0 10px 34px rgba(15, 23, 42, 0.05);
}
.estimator h2 { margin-top: 0; }
.estimator-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 22px;
}
.estimator label span,
.copy-box label span {
  color: var(--text);
}
.estimate-result {
  margin-top: 20px;
  border-radius: 22px;
  background: var(--accent);
  color: #fff;
  padding: 22px;
  display: grid;
  gap: 6px;
}
.estimate-result strong {
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1;
}
.estimate-result span { color: #cbd5e1; }
.copy-box {
  margin: 34px 0;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #fff;
  padding: 26px;
}
.copy-box h2 { margin-top: 0; }
.copy-box pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 18px;
  color: #334155;
  font: 15px/1.7 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.text-link.on-dark { color: #bfdbfe; }
@media (max-width: 640px) {
  .estimator-grid { grid-template-columns: 1fr; }
}

.tool-wizard {
  margin: 34px 0;
  border: 1px solid var(--line);
  border-radius: 30px;
  background: #fff;
  padding: 28px;
  box-shadow: 0 18px 46px rgba(15, 23, 42, 0.07);
}
.tool-wizard-head h2 { margin: 8px 0 10px; }
.tool-wizard-head p { color: var(--muted); max-width: 860px; }
.wizard-step { margin-top: 28px; }
.wizard-step-title {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}
.wizard-step-title span {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
}
.wizard-step-title h3 { margin: 0; }
.choice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.choice-grid-compact { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.choice-card {
  appearance: none;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  padding: 16px;
  min-height: 96px;
  cursor: pointer;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
.choice-card strong { display: block; font-size: 16px; margin-bottom: 7px; }
.choice-card span { display: block; color: var(--muted); line-height: 1.45; }
.choice-card:hover { transform: translateY(-2px); border-color: rgba(37, 99, 235, .45); }
.choice-card.is-selected {
  background: #eff6ff;
  border-color: var(--accent);
  box-shadow: 0 10px 24px rgba(37, 99, 235, .12);
}
.wizard-advanced {
  margin: 26px 0;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  padding: 16px 18px;
}
.wizard-advanced summary { cursor: pointer; font-weight: 800; }
.tool-result {
  margin-top: 26px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  border-radius: 26px;
  background: var(--accent);
  color: #fff;
  padding: 24px;
}
.result-label {
  display: inline-block;
  color: #bfdbfe;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 800;
  margin-bottom: 8px;
}
.tool-result strong {
  display: block;
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1;
  margin-bottom: 10px;
}
.tool-result p,
.tool-result li { color: #dbeafe; }
.result-list h3 { margin-top: 0; color: #fff; }
.result-list ul { margin-bottom: 0; }
.copy-brief {
  margin-top: 20px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--surface);
  padding: 22px;
}
.copy-brief-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 14px;
}
.copy-brief-head h3 { margin: 0 0 6px; }
.copy-brief-head p { margin: 0; color: var(--muted); }
.copy-brief textarea { min-height: 190px; }
@media (max-width: 900px) {
  .choice-grid,
  .choice-grid-compact,
  .tool-result { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .tool-wizard { padding: 20px; border-radius: 24px; }
  .choice-grid,
  .choice-grid-compact,
  .tool-result { grid-template-columns: 1fr; }
  .choice-card { min-height: auto; }
  .copy-brief-head { flex-direction: column; }
}
.copy-brief-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 14px;
}
.copy-brief-actions .btn { width: auto; }
@media (max-width: 640px) {
  .copy-brief-actions .btn { width: 100%; }
}

/* Package 20: proof points, backend-ready forms and visual trust blocks */
.proof-figure {
  margin: 0 0 28px;
  border: 1px solid var(--line);
  border-radius: 28px;
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow);
}
.proof-figure figcaption {
  padding: 12px 18px;
  color: var(--muted);
  font-size: 14px;
  border-top: 1px solid var(--line);
}
.proof-panel {
  border: 1px solid #bfdbfe;
  border-radius: 24px;
  padding: 22px;
  background: #eff6ff;
  margin: 0 0 28px;
}
.proof-panel h2 { margin-top: 0; }
.proof-panel .facts-table { background: #fff; }
.consent-line {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: rgba(255,255,255,.86);
  font-size: 14px;
}
.consent-line input { margin-top: 5px; }
.cta .input[type="file"] {
  background: #fff;
}
