:root {
  --ink: #17211d;
  --dark: #10231f;
  --paper: #f7f3eb;
  --surface: #ffffff;
  --surface-soft: #eef5ef;
  --line: #d7ddd6;
  --muted: #60706a;
  --domain: #2f6b4f;
  --action: #087b83;
  --action-dark: #055e64;
  --warning: #b86b10;
  --data: #315f9d;
  --danger: #9f2f2f;
  --shadow: 0 18px 44px rgba(16, 35, 31, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--paper);
  color: var(--ink);
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  letter-spacing: 0;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
}

body,
button,
input,
select,
textarea {
  font: inherit;
}

a {
  color: var(--action-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

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

.narrow {
  max-width: 780px;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 20;
  padding: 12px 16px;
  background: var(--dark);
  color: #fff;
}

.skip-link:focus {
  top: 16px;
}

.site-header {
  background: rgba(247, 243, 235, 0.96);
  border-bottom: 1px solid var(--line);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}

.main-nav a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  padding: 8px 11px;
  border-radius: 8px;
  color: var(--ink);
  text-decoration: none;
}

.main-nav a:hover,
.main-nav a:focus,
.main-nav a[aria-current="page"] {
  background: var(--surface-soft);
  outline: none;
}

.intro-band,
.page-hero {
  padding: 56px 0 40px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.64), rgba(247,243,235,0.86)),
    var(--paper);
  border-bottom: 1px solid var(--line);
}

.hero-grid,
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.85fr);
  gap: 40px;
  align-items: center;
}

.align-start {
  align-items: start;
}

.hero-copy {
  max-width: 660px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--domain);
  font-weight: 700;
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: 48px;
  line-height: 1.04;
  letter-spacing: 0;
}

h2 {
  margin: 0 0 14px;
  font-size: 28px;
  line-height: 1.18;
  letter-spacing: 0;
}

h3 {
  margin: 24px 0 10px;
  font-size: 19px;
  line-height: 1.25;
}

.lede {
  color: var(--muted);
  font-size: 20px;
  line-height: 1.55;
  margin: 18px 0 0;
}

.hero-actions,
.next-step {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 700;
  text-decoration: none;
}

.button.primary {
  background: var(--action);
  color: #fff;
}

.button.primary:hover,
.button.primary:focus {
  background: var(--action-dark);
}

.button.secondary {
  background: var(--dark);
  color: #fff;
}

.button.ghost {
  background: var(--surface);
  border-color: var(--line);
  color: var(--ink);
}

.button:focus,
.link-button:focus,
input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(184, 107, 16, 0.42);
  outline-offset: 2px;
}

.fine-print {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.visual-panel {
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.guide-hero {
  padding-bottom: 46px;
  background:
    linear-gradient(135deg, rgba(238, 245, 239, 0.9), rgba(247, 243, 235, 0.78)),
    var(--paper);
}

.guide-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.82fr);
  gap: 34px;
  align-items: center;
}

.guide-quick {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 24px;
}

.guide-quick div {
  min-height: 108px;
  padding: 14px;
  border: 1px solid rgba(47, 107, 79, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
}

.guide-quick span,
.section-kicker {
  display: block;
  color: var(--data);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.guide-quick strong {
  display: block;
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.42;
}

.guide-visual-card {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.guide-visual-card figcaption {
  padding: 14px 16px 16px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.tool-band,
.section {
  padding: 54px 0;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 24px;
}

.section-heading p,
.article-body p,
.side-note p,
.feature-card p,
.source-box p {
  color: var(--muted);
  line-height: 1.62;
}

.estimator-panel,
.form-shell,
.side-note,
.source-box,
.metric {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.evidence-note {
  border-color: #b8d0c4;
  background: #f1faf6;
}

.estimator-panel {
  padding: 24px;
}

.estimator-panel label,
.form-shell label {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--ink);
  font-weight: 650;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid #b9c6be;
  border-radius: 8px;
  padding: 10px 12px;
  background: #fff;
  color: var(--ink);
}

textarea {
  resize: vertical;
}

.estimate-result {
  display: block;
  min-height: 96px;
  margin-top: 18px;
  padding: 16px;
  border: 1px solid #b8d0c4;
  border-radius: 8px;
  background: #f1faf6;
  color: var(--ink);
  line-height: 1.5;
}

.estimate-result strong {
  display: block;
  margin-bottom: 6px;
  font-size: 22px;
}

.estimate-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.estimate-scenarios {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.estimate-scenarios strong {
  font-size: 16px;
}

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

.check-list li {
  position: relative;
  padding-left: 28px;
  line-height: 1.5;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 12px;
  height: 8px;
  border-left: 3px solid var(--domain);
  border-bottom: 3px solid var(--domain);
  transform: rotate(-45deg);
}

.feature-grid,
.status-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.feature-card {
  display: grid;
  gap: 8px;
  min-height: 190px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  text-decoration: none;
  color: var(--ink);
}

.feature-card:hover,
.feature-card:focus {
  border-color: var(--action);
  box-shadow: var(--shadow);
  outline: none;
}

.feature-card span,
.metric span {
  color: var(--data);
  font-weight: 700;
  font-size: 14px;
}

.feature-card strong {
  font-size: 22px;
  line-height: 1.2;
}

.feature-card.passive {
  min-height: auto;
}

.hub-card-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  margin-bottom: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f3eb;
}

.source-list,
.related-links {
  display: grid;
  gap: 10px;
}

.source-list a,
.related-links a {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
}

.source-list a:hover,
.source-list a:focus,
.related-links a:hover,
.related-links a:focus {
  border-color: var(--action);
  outline: none;
}

.source-list span {
  color: var(--muted);
  line-height: 1.45;
}

.article-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 32px;
  align-items: start;
}

.article-body {
  display: grid;
  gap: 24px;
  min-width: 0;
}

.article-grid > *,
.split > *,
.hero-grid > *,
.guide-hero-grid > * {
  min-width: 0;
}

.article-body section {
  min-width: 0;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.article-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.article-meta span + span::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: var(--line);
}

.brief-builder,
.answer-panel,
.question-panel,
.limit-panel,
.explorer-panel,
.faq-panel {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(238, 245, 239, 0.54));
}

.brief-builder h2,
.answer-panel h2,
.question-panel h2,
.limit-panel h2,
.explorer-panel h2,
.faq-panel h2 {
  margin-top: 8px;
}

.brief-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.brief-card {
  min-height: 132px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.brief-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 17px;
}

.brief-card p {
  margin: 0;
}

.brief-hero {
  padding-bottom: 46px;
  background:
    radial-gradient(circle at top right, rgba(8, 123, 131, 0.12), transparent 28%),
    linear-gradient(145deg, rgba(238, 245, 239, 0.92), rgba(247, 243, 235, 0.82)),
    var(--paper);
}

.brief-hero-grid,
.brief-workspace {
  display: grid;
  grid-template-columns: minmax(320px, 0.88fr) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.brief-hero-card,
.brief-report-panel {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.brief-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #e4f4ed;
  color: var(--domain);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.brief-hero-card strong {
  display: block;
  margin-top: 16px;
  font-size: 28px;
  line-height: 1.08;
}

.brief-hero-card p {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.58;
}

.brief-hero-points {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.brief-hero-points span {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f3eb;
  font-weight: 600;
}

.brief-hero-points span::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--action);
  flex: 0 0 auto;
}

.brief-form {
  position: sticky;
  top: 18px;
}

.brief-form h2 {
  margin-top: 8px;
}

.brief-report-shell {
  display: grid;
  gap: 18px;
}

.report-meta {
  margin-bottom: -6px;
}

.brief-range {
  margin: 14px 0 0;
  color: var(--action-dark);
  font-size: 18px;
  font-weight: 800;
}

.brief-summary-grid,
.brief-report-grid {
  display: grid;
  gap: 12px;
}

.brief-summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 18px;
}

.brief-report-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.brief-summary-card {
  min-height: 110px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(238, 245, 239, 0.78), rgba(255, 255, 255, 0.96));
}

.brief-summary-card span {
  display: block;
  color: var(--data);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.brief-summary-card strong {
  display: block;
  margin-top: 8px;
  font-size: 17px;
  line-height: 1.38;
}

.brief-summary-copy {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f3eb;
  white-space: pre-line;
  line-height: 1.58;
}

.brief-prefill-note {
  margin-bottom: 18px;
  border-color: #b8d0c4;
  background: #f1faf6;
  color: var(--ink);
}

.brief-live-list {
  margin-top: 18px;
}

.utility-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.utility-card {
  min-height: 126px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.utility-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 17px;
}

.utility-card p {
  margin: 0;
}

.explorer-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.explorer-form label {
  display: grid;
  gap: 8px;
  font-weight: 650;
}

.explorer-result {
  display: grid;
  gap: 18px;
  margin-top: 20px;
}

.explorer-result-heading {
  padding: 18px;
  border: 1px solid #b8d0c4;
  border-radius: 8px;
  background: #f1faf6;
}

.explorer-result-heading span {
  display: block;
  color: var(--data);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.explorer-result-heading strong {
  display: block;
  margin-top: 8px;
  font-size: 22px;
  line-height: 1.25;
}

.explorer-result-heading p {
  margin: 10px 0 0;
}

.explorer-next-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.explorer-next-grid h3 {
  margin-top: 0;
}

.explorer-choice {
  width: 100%;
  cursor: pointer;
  text-align: left;
  font: inherit;
}

.section-helper {
  display: grid;
  gap: 4px;
  margin-top: 16px;
  padding: 14px 16px;
  border-left: 4px solid var(--action);
  border-radius: 8px;
  background: #f1faf6;
  line-height: 1.48;
}

.section-helper span {
  color: var(--muted);
}

.number-list {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding-left: 24px;
}

.number-list li {
  padding-left: 6px;
  line-height: 1.52;
}

.faq-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.faq-item summary {
  min-height: 48px;
  padding: 14px 16px;
  cursor: pointer;
  font-weight: 750;
}

.faq-item p {
  margin: 0;
  padding: 0 16px 16px;
}

.limit-panel {
  background: #fff8ea;
  border-color: rgba(184, 107, 16, 0.32);
}

.warning-list li::before {
  width: 12px;
  height: 12px;
  border: 3px solid var(--warning);
  border-top: 0;
  border-left: 0;
  transform: rotate(45deg);
}

.sidebar-visual {
  margin: 0 0 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f3eb;
}

.side-note,
.source-box {
  padding: 22px;
}

.side-note .button {
  width: 100%;
  margin-top: 10px;
}

.form-shell {
  padding: 24px;
}

.form-shell.compact {
  box-shadow: none;
}

.worksheet-page .article-body {
  gap: 18px;
}

.worksheet-section {
  padding: 22px;
  border: 1px solid var(--line) !important;
  border-radius: 8px;
  background: var(--surface);
}

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

.worksheet-list li {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 10px;
  line-height: 1.45;
}

.worksheet-list li span {
  width: 20px;
  height: 20px;
  border: 2px solid var(--domain);
  border-radius: 4px;
  background: #fff;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 16px;
}

.check-row {
  display: grid !important;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: start;
  gap: 12px !important;
  font-weight: 500 !important;
}

.check-row input {
  min-height: auto;
  width: 18px;
  height: 18px;
  margin-top: 3px;
}

.honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.alert {
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid rgba(159, 47, 47, 0.35);
  border-radius: 8px;
  background: #fff4f1;
  color: var(--danger);
}

.table-wrap {
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.compact-table table {
  min-width: 0;
}

table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
}

th,
td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: #eef5ef;
}

tr:last-child td {
  border-bottom: 0;
}

.metric {
  padding: 20px;
}

.metric strong {
  display: block;
  margin-top: 6px;
  font-size: 26px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  font-weight: 700;
}

.pill.ok {
  background: #e2f4e8;
  color: #1f6638;
}

.pill.fail {
  background: #fff0e0;
  color: #9a4b00;
}

.site-footer {
  padding: 40px 0;
  background: var(--dark);
  color: #eff7f2;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 28px;
  align-items: start;
}

.site-footer p {
  color: #cfe1d8;
  line-height: 1.55;
}

.site-footer nav {
  display: grid;
  gap: 10px;
}

.site-footer a,
.link-button {
  color: #fff;
}

.link-button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.cookie-banner {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  max-width: 960px;
  margin: 0 auto;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.cookie-banner p {
  margin: 4px 0 0;
  color: var(--muted);
}

.cookie-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

[hidden] {
  display: none !important;
}

@media (max-width: 880px) {
  h1 {
    font-size: 38px;
  }

  .header-inner,
  .hero-grid,
  .guide-hero-grid,
  .brief-hero-grid,
  .split,
  .article-grid,
  .brief-workspace,
  .footer-grid,
  .cookie-banner {
    grid-template-columns: 1fr;
  }

  .header-inner {
    align-items: flex-start;
    padding: 14px 0;
  }

  .main-nav {
    justify-content: flex-start;
  }

  .feature-grid,
  .status-grid,
  .form-grid,
  .brief-card-grid,
  .utility-grid,
  .explorer-form,
  .explorer-next-grid,
  .brief-summary-grid,
  .brief-report-grid {
    grid-template-columns: 1fr;
  }

  .guide-quick {
    grid-template-columns: 1fr;
  }

  .visual-panel {
    order: -1;
  }

  .brief-form {
    position: static;
  }
}

@media (max-width: 520px) {
  .wrap {
    width: min(100% - 22px, 1120px);
  }

  h1 {
    font-size: 32px;
  }

  .lede {
    font-size: 18px;
  }

  .hero-actions,
  .cookie-actions,
  .next-step {
    display: grid;
  }

  .button {
    width: 100%;
  }

  .brief-builder,
  .answer-panel,
  .question-panel,
  .limit-panel,
  .explorer-panel,
  .faq-panel,
  .brief-hero-card,
  .brief-report-panel {
    padding: 18px;
  }
}

@media print {
  body {
    background: #fff;
  }

  .site-header,
  .site-footer,
  .cookie-banner,
  .no-print {
    display: none !important;
  }

  .page-hero,
  .section {
    padding: 18px 0;
    border: 0;
    background: #fff;
  }

  .wrap {
    width: 100%;
  }

  .article-grid,
  .worksheet-page,
  .brief-workspace {
    display: block;
  }

  .worksheet-section,
  .brief-report-panel {
    break-inside: avoid;
    box-shadow: none;
  }

  .brief-form {
    display: none !important;
  }
}
