/* ---------- Design tokens ---------- */
:root {
  --bg: #f7f6f1;
  --surface: #ffffff;
  --surface-2: #f1efe7;
  --surface-3: #e9e6db;
  --ink: #131b18;
  --ink-2: #46524c;
  --ink-3: #6d7a73;
  --line: #e2ded2;
  --line-strong: #cfc9b9;
  --brand: #0d5c4b;
  --brand-strong: #094438;
  --brand-ink: #ffffff;
  --brand-soft: #e6f1ec;
  --brand-soft-2: #d3e8df;
  --accent: #b65329;
  --accent-soft: #f7e9e0;
  --good: #0b6b52;
  --good-soft: #e4f3ec;
  --warn: #9a5a08;
  --warn-soft: #fbf0d9;
  --bad: #a1392c;
  --bad-soft: #fbe9e5;
  --focus: #1a7f68;
  --shadow-sm: 0 1px 2px rgba(19, 27, 24, 0.05);
  --shadow-md: 0 2px 4px rgba(19, 27, 24, 0.04), 0 16px 40px -24px rgba(19, 27, 24, 0.22);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --font-sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, sans-serif;
  --font-display: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia,
    "Times New Roman", serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --container: 1160px;
  --header-h: 68px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1412;
    --surface: #151d1a;
    --surface-2: #1b2521;
    --surface-3: #22302a;
    --ink: #eef4f0;
    --ink-2: #b7c3bd;
    --ink-3: #90a099;
    --line: #27332e;
    --line-strong: #38473f;
    --brand: #52c7a8;
    --brand-strong: #7ad9c0;
    --brand-ink: #07241d;
    --brand-soft: #16302a;
    --brand-soft-2: #1c3d34;
    --accent: #e2966e;
    --accent-soft: #2f211b;
    --good: #58cba6;
    --good-soft: #16312a;
    --warn: #e0ad5e;
    --warn-soft: #2c2517;
    --bad: #ef9c8f;
    --bad-soft: #33201d;
    --focus: #7ad9c0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 2px 4px rgba(0, 0, 0, 0.3), 0 20px 50px -28px rgba(0, 0, 0, 0.8);
    color-scheme: dark;
  }
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 24px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.no-scroll {
  overflow: hidden;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-weight: 650;
  line-height: 1.15;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

h1,
h2 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.015em;
}

p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--brand);
}

img,
svg {
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection {
  background: var(--brand-soft-2);
  color: var(--ink);
}

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 2rem 0;
}

/* ---------- Layout ---------- */
.container {
  width: min(var(--container), 100% - 2.5rem);
  margin-inline: auto;
}

.container--narrow {
  width: min(760px, 100% - 2.5rem);
  margin-inline: auto;
}

.section {
  padding-block: clamp(2.75rem, 6vw, 4.75rem);
}

.section--tight {
  padding-block: clamp(2rem, 4vw, 3rem);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.75rem;
}

.section-title {
  font-size: clamp(1.7rem, 3vw, 2.35rem);
}

.section-lead {
  margin-top: 0.6rem;
  max-width: 62ch;
  color: var(--ink-2);
  font-size: 1.02rem;
}

.section-link {
  flex-shrink: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--brand);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.section-link:hover {
  border-color: currentColor;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  color: var(--brand);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: currentColor;
}

.lead {
  color: var(--ink-2);
  font-size: clamp(1.02rem, 1.6vw, 1.15rem);
  line-height: 1.7;
  max-width: 66ch;
}

.muted {
  color: var(--ink-2);
}

.small {
  font-size: 0.86rem;
}

.grid {
  display: grid;
  gap: 1rem;
}

.grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

/* ---------- Buttons & pills ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.65rem 1.1rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 0.94rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease,
    transform 0.18s ease;
}

.btn:hover {
  color: inherit;
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn--primary {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--brand-ink);
  box-shadow: var(--shadow-sm);
}

.btn--primary:hover {
  background: var(--brand-strong);
  border-color: var(--brand-strong);
  color: var(--brand-ink);
}

.btn--secondary {
  background: var(--surface);
  border-color: var(--line-strong);
  color: var(--ink);
}

.btn--secondary:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.btn--ghost {
  padding-inline: 0.75rem;
  color: var(--ink-2);
}

.btn--ghost:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.btn--sm {
  min-height: 36px;
  padding: 0.45rem 0.85rem;
  font-size: 0.84rem;
}

.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.28rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-2);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.pill--brand {
  background: var(--brand-soft);
  border-color: transparent;
  color: var(--brand);
}

.pill--en {
  background: var(--surface-2);
  color: var(--ink-3);
  border-color: var(--line);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
}

/* ---------- Header ---------- */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 100;
  padding: 0.7rem 1rem;
  border-radius: 8px;
  background: var(--brand);
  color: var(--brand-ink);
  font-weight: 600;
}

.skip-link:focus {
  top: 0.75rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.03em;
  font-size: 1.16rem;
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--brand);
  color: var(--brand-ink);
}

.brand-mark svg {
  display: block;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  margin-left: 0.5rem;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 0.7rem;
  border-radius: 8px;
  color: var(--ink-2);
  font-size: 0.89rem;
  font-weight: 550;
  text-decoration: none;
}

.nav-link:hover,
.nav-link[aria-current="page"] {
  background: var(--surface-2);
  color: var(--ink);
}

.nav-drop,
.lang,
.menu {
  position: relative;
}

.nav-drop > summary,
.lang > summary,
.menu > summary {
  list-style: none;
  cursor: pointer;
}

.nav-drop > summary::-webkit-details-marker,
.lang > summary::-webkit-details-marker,
.menu > summary::-webkit-details-marker {
  display: none;
}

.nav-drop > summary::marker,
.lang > summary::marker,
.menu > summary::marker {
  content: "";
}

.nav-drop-panel {
  position: absolute;
  top: calc(100% + 12px);
  left: -120px;
  width: min(680px, 78vw);
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.nav-drop-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.5fr;
  gap: 0.75rem;
}

.nav-drop-col {
  padding: 0.5rem;
}

.nav-drop-col--soft {
  border-radius: 10px;
  background: var(--surface-2);
}

.nav-drop-title {
  margin: 0 0 0.4rem;
  padding-inline: 0.45rem;
  color: var(--ink-3);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.nav-drop-link {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.42rem 0.45rem;
  border-radius: 6px;
  color: var(--ink);
  font-size: 0.86rem;
  text-decoration: none;
}

.nav-drop-link span {
  color: var(--ink-3);
  font-size: 0.72rem;
}

.nav-drop-link:hover {
  background: var(--brand-soft);
  color: var(--brand);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-left: auto;
}

.lang > summary {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.6rem;
  border-radius: 8px;
  color: var(--ink-2);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.lang > summary:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.lang-panel {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  min-width: 210px;
  padding: 0.5rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.lang-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.5rem 0.6rem;
  border-radius: 7px;
  color: var(--ink);
  font-size: 0.86rem;
  text-decoration: none;
}

.lang-option small {
  color: var(--ink-3);
  font-size: 0.7rem;
}

.lang-option:hover {
  background: var(--surface-2);
}

.lang-option[aria-current="true"] {
  background: var(--brand-soft);
  color: var(--brand);
  font-weight: 600;
}

.menu {
  display: none;
}

.menu > summary {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 600;
}

.menu-panel {
  position: fixed;
  inset: var(--header-h) 0 auto 0;
  max-height: calc(100dvh - var(--header-h));
  overflow: auto;
  padding: 1rem 1.25rem 2rem;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.mobile-group + .mobile-group {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.mobile-link {
  display: block;
  padding: 0.55rem 0;
  color: var(--ink);
  font-size: 0.98rem;
  text-decoration: none;
}

.mobile-link:hover {
  color: var(--brand);
}

/* ---------- Breadcrumbs ---------- */
.crumbs {
  padding-top: 1.25rem;
  color: var(--ink-3);
  font-size: 0.78rem;
}

.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.crumbs li {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.crumbs li + li::before {
  content: "/";
  color: var(--line-strong);
}

.crumbs a {
  color: var(--ink-2);
  text-decoration: none;
}

.crumbs a:hover {
  color: var(--brand);
}

.crumbs [aria-current="page"] {
  color: var(--ink-3);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(2.5rem, 6vw, 5rem) clamp(2.5rem, 5vw, 4rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.hero-title {
  font-size: clamp(2.5rem, 5.4vw, 4.3rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
}

.hero-title em {
  color: var(--brand);
  font-style: italic;
}

.hero .lead {
  margin-top: 1.25rem;
  font-size: clamp(1.05rem, 1.7vw, 1.18rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  color: var(--ink-3);
  font-size: 0.8rem;
}

.hero-trust span {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.hero-trust svg {
  color: var(--brand);
}

.hero-art {
  position: relative;
  padding: 1.1rem;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 85% 15%, rgba(255, 255, 255, 0.16), transparent 42%),
    linear-gradient(150deg, #0d5c4b 0%, #0a3f35 58%, #082f28 100%);
  box-shadow: var(--shadow-md);
}

.hero-art::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background-image: linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(180deg, black, transparent 85%);
  pointer-events: none;
}

.demo-card {
  position: relative;
  padding: 1.15rem;
  border-radius: 16px;
  background: #fbfaf6;
  color: #131b18;
  box-shadow: 0 24px 50px -30px rgba(0, 0, 0, 0.7);
}

.demo-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.demo-label {
  color: #66736c;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.demo-chip {
  padding: 0.22rem 0.5rem;
  border-radius: 999px;
  background: #e6f1ec;
  color: #0d5c4b;
  font-size: 0.64rem;
  font-weight: 700;
}

.demo-value {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 3.4vw, 2.6rem);
  line-height: 1;
  letter-spacing: -0.03em;
}

.demo-caption {
  margin-top: 0.35rem;
  color: #66736c;
  font-size: 0.76rem;
}

.demo-chart {
  display: block;
  width: 100%;
  height: 96px;
  margin-top: 0.85rem;
}

.demo-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-top: 0.9rem;
  padding-top: 0.9rem;
  border-top: 1px solid #e2ded2;
}

.demo-stat strong {
  display: block;
  font-size: 0.98rem;
  font-variant-numeric: tabular-nums;
}

.demo-stat span {
  color: #66736c;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.demo-note {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.9rem;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.72rem;
}

.demo-note::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #7ad9c0;
  box-shadow: 0 0 0 4px rgba(122, 217, 192, 0.15);
}

/* ---------- Cards ---------- */
.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 1.15rem;
  color: inherit;
  text-decoration: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.card-link:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  color: inherit;
}

.card-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-bottom: 0.9rem;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--brand);
}

.card-title {
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.card-desc {
  margin-top: 0.4rem;
  color: var(--ink-2);
  font-size: 0.84rem;
  line-height: 1.55;
}

.card-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  margin-top: auto;
  padding-top: 0.9rem;
  color: var(--ink-3);
  font-size: 0.72rem;
}

.card-foot .dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
}

.calc-card {
  overflow: hidden;
}

.calc-card .card-link {
  padding: 1.1rem 1.15rem 1rem;
}

.calc-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.calc-card .card-title {
  font-family: var(--font-display);
  font-size: 1.22rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.calc-card .card-desc {
  min-height: 3.1em;
}

.calc-card .arrow {
  color: var(--ink-3);
  transition: transform 0.18s ease, color 0.18s ease;
}

.calc-card:hover .arrow {
  color: var(--brand);
  transform: translate(2px, -2px);
}

.cat-card .card-link {
  padding: 1.25rem;
}

.cat-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 24px;
  padding-inline: 0.5rem;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--ink-2);
  font-size: 0.72rem;
  font-weight: 700;
}

.cat-card h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
}

.cat-card p {
  margin-top: 0.35rem;
  color: var(--ink-2);
  font-size: 0.86rem;
}

.cat-card .cat-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.9rem;
}

.cat-card .cat-list span {
  padding: 0.18rem 0.45rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-3);
  font-size: 0.66rem;
}

.guide-card .card-link {
  padding: 1.2rem;
}

.guide-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.6rem;
  color: var(--ink-3);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.guide-card h3 {
  font-family: var(--font-display);
  font-size: 1.28rem;
  line-height: 1.25;
}

.guide-card p {
  margin-top: 0.5rem;
  color: var(--ink-2);
  font-size: 0.87rem;
}

/* ---------- Home: trust / stats ---------- */
.stats-band {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.stat {
  padding: 1.2rem 1.25rem;
  background: var(--surface);
}

.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
}

.stat span {
  display: block;
  margin-top: 0.45rem;
  color: var(--ink-3);
  font-size: 0.76rem;
  line-height: 1.4;
}

.split {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.split h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
}

.principles {
  display: grid;
  gap: 0.9rem;
}

.principle {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 0.85rem;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
}

.principle:first-child {
  border-top: 0;
  padding-top: 0;
}

.principle-num {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--brand);
  font-size: 0.75rem;
  font-weight: 700;
}

.principle h3 {
  font-family: var(--font-sans);
  font-size: 0.98rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.principle p {
  margin-top: 0.25rem;
  color: var(--ink-2);
  font-size: 0.87rem;
}

/* ---------- Page head ---------- */
.page-head {
  padding-block: 1.2rem clamp(1.6rem, 3vw, 2.4rem);
}

.page-head .eyebrow {
  margin-top: 0.75rem;
}

.page-title {
  font-size: clamp(2.1rem, 4.4vw, 3.4rem);
  line-height: 1.04;
}

.page-lead {
  margin-top: 0.9rem;
  max-width: 68ch;
  color: var(--ink-2);
  font-size: clamp(0.98rem, 1.5vw, 1.08rem);
}

.byline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.85rem;
  margin-top: 1.25rem;
  color: var(--ink-3);
  font-size: 0.76rem;
}

.byline .pill {
  font-size: 0.68rem;
}

.byline a {
  color: var(--ink-2);
  text-decoration: none;
  border-bottom: 1px dotted var(--line-strong);
}

/* ---------- Calculator ---------- */
.calc-shell {
  margin-block: 1.5rem 2.5rem;
}

.calc-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.84fr) minmax(0, 1.16fr);
  gap: 1.1rem;
  align-items: start;
}

.calc-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.calc-panel--form {
  padding: 1.15rem;
}

.calc-panel--results {
  position: sticky;
  top: calc(var(--header-h) + 18px);
  overflow: hidden;
  background:
    linear-gradient(180deg, var(--brand-soft) 0%, transparent 150px),
    var(--surface);
}

.results-wrap {
  padding: 1.15rem;
}

.calc-form {
  display: grid;
  gap: 1.1rem;
}

.calc-fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

.calc-fieldset + .calc-fieldset {
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.calc-legend {
  margin-bottom: 0.65rem;
  padding: 0;
  color: var(--ink);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.field {
  min-width: 0;
}

.field--full {
  grid-column: 1 / -1;
}

.field.is-hidden {
  display: none;
}

.field-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.32rem;
  color: var(--ink-2);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.35;
}

.field-label .optional {
  color: var(--ink-3);
  font-size: 0.66rem;
  font-weight: 500;
}

.field-control {
  position: relative;
  display: flex;
  align-items: center;
}

.field-control .affix {
  position: absolute;
  color: var(--ink-3);
  font-size: 0.86rem;
  font-weight: 600;
  pointer-events: none;
}

.field-control .affix--prefix {
  left: 0.7rem;
}

.field-control .affix--suffix {
  right: 0.8rem;
}

.input,
.select {
  width: 100%;
  height: 42px;
  padding: 0 0.7rem;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: var(--surface);
  color: var(--ink);
  font-size: 0.94rem;
  font-variant-numeric: tabular-nums;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.input:hover,
.select:hover {
  border-color: var(--ink-3);
}

.input:focus,
.select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft-2);
}

.field-control--prefix .input {
  padding-left: 1.55rem;
}

.field-control--suffix .input {
  padding-right: 2rem;
}

.field-control--suffix-wide .input {
  padding-right: 3.4rem;
}

.select {
  appearance: none;
  padding-right: 2rem;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-3) 50%),
    linear-gradient(135deg, var(--ink-3) 50%, transparent 50%);
  background-position: calc(100% - 15px) 18px, calc(100% - 10px) 18px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.field-hint {
  margin-top: 0.3rem;
  color: var(--ink-3);
  font-size: 0.69rem;
  line-height: 1.45;
}

.calc-advanced {
  margin-top: 0.85rem;
  border-top: 1px dashed var(--line);
}

.calc-advanced > summary {
  padding: 0.7rem 0;
  color: var(--ink-3);
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.calc-advanced > summary::-webkit-details-marker {
  display: none;
}

.calc-advanced > summary::before {
  content: "+";
  display: inline-block;
  margin-right: 0.45rem;
  color: var(--brand);
  font-weight: 700;
}

.calc-advanced[open] > summary::before {
  content: "–";
}

.calc-advanced .field-grid {
  padding-bottom: 0.35rem;
}

.calc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line);
}

.calc-actions .btn {
  flex: 0 0 auto;
}

.calc-status {
  margin-left: auto;
  align-self: center;
  color: var(--ink-3);
  font-size: 0.68rem;
}

.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.results-title {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand);
}

.results-live {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--ink-3);
  font-size: 0.68rem;
}

.results-live::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--good);
  box-shadow: 0 0 0 3px var(--good-soft);
}

.result-headline {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
}

.metric {
  min-width: 0;
  padding: 0.75rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.result-headline .metric {
  padding: 0.9rem 0.85rem;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.metric-label {
  display: block;
  color: var(--ink-3);
  font-size: 0.66rem;
  font-weight: 600;
  line-height: 1.35;
}

.metric-value {
  display: block;
  margin-top: 0.25rem;
  font-size: 1.05rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.result-headline .metric-value {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.3vw, 1.75rem);
  font-weight: 600;
  line-height: 1.1;
}

.metric-hint {
  display: block;
  margin-top: 0.2rem;
  color: var(--ink-3);
  font-size: 0.64rem;
}

.metric.tone-good .metric-value {
  color: var(--good);
}

.metric.tone-warn .metric-value {
  color: var(--warn);
}

.metric.tone-bad .metric-value {
  color: var(--bad);
}

.result-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem;
  margin-top: 0.55rem;
}

.callout {
  display: flex;
  gap: 0.65rem;
  margin-top: 0.8rem;
  padding: 0.75rem 0.85rem;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--ink-2);
  font-size: 0.78rem;
  line-height: 1.5;
}

.callout::before {
  flex: 0 0 auto;
  content: "i";
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-top: 1px;
  border-radius: 50%;
  background: var(--brand);
  color: var(--brand-ink);
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  font-style: italic;
}

.callout--good {
  background: var(--good-soft);
  color: var(--ink-2);
}

.callout--good::before {
  content: "✓";
  background: var(--good);
  font-family: var(--font-sans);
  font-style: normal;
}

.callout--warn {
  background: var(--warn-soft);
}

.callout--warn::before {
  content: "!";
  background: var(--warn);
  font-family: var(--font-sans);
  font-style: normal;
}

.chart-block {
  margin-top: 0.9rem;
  padding: 0.85rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}

.chart-title {
  margin: 0 0 0.5rem;
  color: var(--ink-2);
  font-size: 0.74rem;
  font-weight: 600;
}

.chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.5rem;
  color: var(--ink-3);
  font-size: 0.66rem;
}

.chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.chart-key {
  width: 14px;
  height: 3px;
  border-radius: 2px;
  background: var(--brand);
}

.chart-key--muted {
  background: var(--ink-3);
  opacity: 0.55;
}

.chart-svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.chart-grid-line {
  stroke: var(--line);
  stroke-width: 1;
  stroke-dasharray: 3 4;
}

.chart-axis-label {
  fill: var(--ink-3);
  font-family: var(--font-sans);
  font-size: 9px;
}

.chart-line {
  fill: none;
  stroke: var(--brand);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chart-line--muted {
  stroke: var(--ink-3);
  stroke-width: 1.6;
  opacity: 0.5;
  stroke-dasharray: 5 4;
}

.chart-area {
  fill: var(--brand-soft);
  opacity: 0.65;
}

.table-wrap {
  margin-top: 0.9rem;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
}

.data-table caption {
  padding: 0.7rem 0.85rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 0.74rem;
  font-weight: 600;
  text-align: left;
}

.data-table th,
.data-table td {
  padding: 0.5rem 0.85rem;
  border-bottom: 1px solid var(--line);
  text-align: right;
  white-space: nowrap;
}

.data-table th:first-child,
.data-table td:first-child {
  text-align: left;
  white-space: normal;
}

.data-table thead th {
  position: sticky;
  top: 0;
  background: var(--surface-2);
  color: var(--ink-3);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table tbody tr:hover td {
  background: color-mix(in srgb, var(--brand-soft) 45%, transparent);
}

.table-footnote {
  margin: 0.5rem 0 0;
  color: var(--ink-3);
  font-size: 0.68rem;
  line-height: 1.45;
}

.notes {
  margin: 0.9rem 0 0;
  padding: 0.8rem 0.9rem;
  border: 1px dashed var(--line-strong);
  border-radius: 10px;
  color: var(--ink-3);
  font-size: 0.7rem;
  line-height: 1.5;
}

.notes ul {
  margin: 0;
  padding-left: 1rem;
}

.notes li + li {
  margin-top: 0.35rem;
}

.results-placeholder {
  display: grid;
  place-items: center;
  min-height: 260px;
  padding: 2rem;
  color: var(--ink-3);
  text-align: center;
  font-size: 0.85rem;
}

.calc-disclaimer {
  margin-top: 0.85rem;
  color: var(--ink-3);
  font-size: 0.68rem;
  line-height: 1.5;
}

.calc-footnote {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-top: 0.7rem;
  color: var(--ink-3);
  font-size: 0.68rem;
}

/* ---------- Prose ---------- */
.prose {
  color: var(--ink-2);
  font-size: 0.97rem;
  line-height: 1.75;
}

.prose > * + * {
  margin-top: 0.95rem;
}

.prose h2 {
  margin-top: 2.1rem;
  color: var(--ink);
  font-size: clamp(1.45rem, 2.4vw, 1.85rem);
  scroll-margin-top: calc(var(--header-h) + 24px);
}

.prose h3 {
  margin-top: 1.5rem;
  color: var(--ink);
  font-size: 1.08rem;
  font-family: var(--font-sans);
  font-weight: 650;
  letter-spacing: -0.01em;
}

.prose p {
  max-width: 72ch;
}

.prose ul,
.prose ol {
  padding-left: 1.2rem;
}

.prose li + li {
  margin-top: 0.35rem;
}

.prose a {
  color: var(--brand);
  font-weight: 550;
}

.prose strong {
  color: var(--ink);
  font-weight: 650;
}

.prose blockquote {
  margin: 1.5rem 0;
  padding: 0.9rem 1.1rem;
  border-left: 3px solid var(--brand);
  background: var(--brand-soft);
  border-radius: 0 10px 10px 0;
  color: var(--ink-2);
}

.prose blockquote p {
  margin: 0;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.prose th,
.prose td {
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.prose th {
  color: var(--ink-3);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.prose code {
  padding: 0.1rem 0.3rem;
  border-radius: 4px;
  background: var(--surface-2);
  font-family: var(--font-mono);
  font-size: 0.85em;
}

.article {
  max-width: 740px;
}

.article-head {
  padding-block: 1rem 1.75rem;
}

.article-head .page-title {
  font-size: clamp(2rem, 4vw, 2.9rem);
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}

.article-aside {
  position: sticky;
  top: calc(var(--header-h) + 20px);
  display: grid;
  gap: 1rem;
}

.toc {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.toc-title {
  margin: 0 0 0.6rem;
  color: var(--ink-3);
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.toc ol {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: toc;
}

.toc li {
  counter-increment: toc;
}

.toc li + li {
  margin-top: 0.35rem;
}

.toc a {
  display: flex;
  gap: 0.5rem;
  color: var(--ink-2);
  font-size: 0.78rem;
  line-height: 1.45;
  text-decoration: none;
}

.toc a::before {
  content: counter(toc, decimal-leading-zero);
  color: var(--ink-3);
  font-size: 0.64rem;
  font-variant-numeric: tabular-nums;
  padding-top: 0.15rem;
}

.toc a:hover {
  color: var(--brand);
}

.key-takeaways {
  padding: 1rem 1.1rem;
  border-radius: var(--radius);
  background: var(--brand-soft);
}

.key-takeaways h2,
.key-takeaways h3 {
  margin: 0 0 0.4rem;
  color: var(--brand);
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.key-takeaways ul {
  margin: 0;
  padding-left: 1.05rem;
  color: var(--ink-2);
  font-size: 0.82rem;
}

.key-takeaways li + li {
  margin-top: 0.35rem;
}

.section-divider {
  margin-block: 2.2rem;
  border-top: 1px solid var(--line);
}

.formula {
  padding: 0.8rem 1rem;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  overflow-x: auto;
}

/* ---------- FAQ ---------- */
.faq {
  margin-top: 1rem;
  border-top: 1px solid var(--line);
}

.faq-item {
  border-bottom: 1px solid var(--line);
}

.faq-item summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0;
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.45;
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  flex: 0 0 auto;
  color: var(--brand);
  font-size: 1.1rem;
  font-weight: 500;
  line-height: 1;
}

.faq-item[open] summary::after {
  content: "–";
}

.faq-a {
  padding: 0 0 0.9rem;
  max-width: 72ch;
  color: var(--ink-2);
  font-size: 0.88rem;
  line-height: 1.7;
}

/* ---------- Sources / author ---------- */
.sources {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.sources h2 {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.sources ul {
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
}

.sources li {
  position: relative;
  padding-left: 0.9rem;
  font-size: 0.78rem;
  line-height: 1.5;
}

.sources li + li {
  margin-top: 0.35rem;
}

.sources li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--ink-3);
}

.sources a {
  color: var(--ink-2);
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
}

.sources a:hover {
  color: var(--brand);
}

.author-box {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
  margin-top: 2rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-2);
}

.author-mark {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--brand);
  color: var(--brand-ink);
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
}

.author-box h3 {
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 650;
}

.author-box p {
  margin-top: 0.25rem;
  color: var(--ink-3);
  font-size: 0.76rem;
  line-height: 1.5;
}

.author-box a {
  color: var(--brand);
  font-weight: 600;
  text-decoration: none;
}

/* ---------- Aside cards / CTA band ---------- */
.aside-card {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.aside-card + .aside-card {
  margin-top: 0.75rem;
}

.aside-card-title {
  margin: 0 0 0.4rem;
  color: var(--ink-3);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.aside-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.aside-list li + li {
  margin-top: 0.35rem;
}

.aside-list a {
  color: var(--ink);
  font-size: 0.82rem;
  line-height: 1.4;
  text-decoration: none;
}

.aside-list a:hover {
  color: var(--brand);
}

.cta-band {
  padding: clamp(1.5rem, 4vw, 2.6rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--brand-soft), var(--surface) 70%);
}

.cta-band h2 {
  max-width: 26ch;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
}

.cta-band p {
  margin-top: 0.5rem;
  max-width: 62ch;
  color: var(--ink-2);
}

.cta-band .hero-actions {
  margin-top: 1.1rem;
}

/* ---------- Related ---------- */
.related {
  margin-top: 2rem;
}

.related h2 {
  font-size: clamp(1.3rem, 2.2vw, 1.6rem);
}

.related-sub {
  margin-top: 0.35rem;
  color: var(--ink-2);
  font-size: 0.86rem;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}

/* ---------- Ads ---------- */
.ad {
  margin-block: 1.5rem;
}

.ad-label {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--ink-3);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ad-inner {
  display: grid;
  place-items: center;
  min-height: 120px;
  padding: 0.5rem;
  border: 1px dashed var(--line-strong);
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--ink-3);
  font-size: 0.7rem;
  text-align: center;
}

.ad .adsbygoogle {
  display: block;
  min-height: 120px;
}

.ad--leaderboard .adsbygoogle,
.ad--leaderboard .ad-inner {
  min-height: 90px;
}

.ad--inline .adsbygoogle,
.ad--inline .ad-inner {
  min-height: 250px;
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: clamp(3rem, 6vw, 5rem);
  padding-top: clamp(2.5rem, 5vw, 3.5rem);
  background: #0c1411;
  color: #c7d2cc;
}

.site-footer a {
  color: #c7d2cc;
  text-decoration: none;
}

.site-footer a:hover {
  color: #ffffff;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.7fr repeat(3, 1fr);
  gap: 2rem;
  padding-bottom: 2.5rem;
}

.footer-brand .brand {
  color: #ffffff;
}

.footer-brand .brand-mark {
  background: #1c6a57;
}

.footer-brand p {
  margin-top: 0.8rem;
  max-width: 34ch;
  color: #93a49c;
  font-size: 0.82rem;
  line-height: 1.6;
}

.footer-title {
  margin: 0 0 0.75rem;
  color: #ffffff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-list li + li {
  margin-top: 0.4rem;
}

.footer-list a {
  font-size: 0.8rem;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-block: 1rem;
  border-top: 1px solid #1e2b26;
  color: #86978f;
  font-size: 0.7rem;
}

.footer-disclaimer {
  padding-bottom: 1.5rem;
  color: #73857c;
  font-size: 0.68rem;
  line-height: 1.6;
  max-width: 100ch;
}

/* ---------- Cookie banner ---------- */
.cookie {
  position: fixed;
  z-index: 60;
  inset: auto 0 1rem 0;
  display: flex;
  justify-content: center;
  padding-inline: 1rem;
  pointer-events: none;
}

.cookie[hidden] {
  display: none;
}

.cookie-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  width: min(880px, 100%);
  padding: 0.9rem 1rem;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
  pointer-events: auto;
}

.cookie-text {
  flex: 1 1 320px;
  font-size: 0.76rem;
  line-height: 1.5;
  color: var(--ink-2);
}

.cookie-text strong {
  color: var(--ink);
  font-weight: 650;
}

.cookie-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ---------- 404 ---------- */
.notfound {
  display: grid;
  place-items: center;
  min-height: 56vh;
  padding-block: 4rem;
  text-align: center;
}

.notfound code {
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  background: var(--surface-2);
  font-family: var(--font-mono);
  font-size: 0.85em;
}

.notfound .page-title {
  margin-top: 0.5rem;
}

.notfound .lead {
  margin-inline: auto;
}

.notfound .btn {
  margin-top: 1.5rem;
}

/* ---------- Utilities ---------- */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.mt-0 { margin-top: 0 !important; }
.mt-1 { margin-top: 0.5rem !important; }
.mt-2 { margin-top: 1rem !important; }
.mt-3 { margin-top: 1.5rem !important; }
.mt-4 { margin-top: 2rem !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-2 { margin-bottom: 1rem !important; }
.mb-3 { margin-bottom: 1.5rem !important; }
.nowrap { white-space: nowrap; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .hero-grid {
    gap: 2.5rem;
  }
  .grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .footer-grid {
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 1.5rem;
  }
  .article-layout {
    grid-template-columns: minmax(0, 1fr) 240px;
  }
}

@media (max-width: 960px) {
  :root {
    --header-h: 62px;
  }
  .nav {
    display: none;
  }
  .menu {
    display: block;
  }
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-art {
    max-width: 560px;
  }
  .calc-grid {
    grid-template-columns: 1fr;
  }
  .calc-panel--results {
    position: static;
  }
  .split {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }
  .article-layout {
    grid-template-columns: 1fr;
  }
  .article-aside {
    position: static;
    grid-row: 1;
  }
  .article-aside .toc {
    display: none;
  }
  .stats-band {
    grid-template-columns: repeat(2, 1fr);
  }
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .container,
  .container--narrow {
    width: min(var(--container), 100% - 1.75rem);
  }
  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
  }
  .grid--3 {
    grid-template-columns: 1fr;
  }
  .grid--2 {
    grid-template-columns: 1fr;
  }
  .result-headline {
    grid-template-columns: 1fr 1fr;
  }
  .result-headline .metric:last-child {
    grid-column: 1 / -1;
  }
  .result-metrics {
    grid-template-columns: 1fr 1fr;
  }
  .field-grid {
    grid-template-columns: 1fr;
  }
  .field--full {
    grid-column: auto;
  }
  .calc-actions .calc-status {
    display: none;
  }
  .hero-art {
    padding: 0.8rem;
  }
  .hero-trust {
    gap: 0.5rem 0.9rem;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem 1rem;
  }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 560px) {
  .hero {
    padding-top: 1.75rem;
  }
  .hero-actions .btn {
    flex: 1 1 auto;
  }
  .grid--4 {
    grid-template-columns: 1fr;
  }
  .stats-band {
    grid-template-columns: 1fr 1fr;
  }
  .stat {
    padding: 1rem;
  }
  .stat strong {
    font-size: 1.55rem;
  }
  .result-headline {
    grid-template-columns: 1fr;
  }
  .result-headline .metric:last-child {
    grid-column: auto;
  }
  .result-metrics {
    grid-template-columns: 1fr;
  }
  .related-grid {
    grid-template-columns: 1fr;
  }
  .calc-panel--form,
  .results-wrap {
    padding: 0.9rem;
  }
  .data-table th,
  .data-table td {
    padding: 0.45rem 0.6rem;
  }
  .cookie {
    inset: auto 0 0.5rem 0;
    padding-inline: 0.5rem;
  }
  .cookie-actions {
    width: 100%;
  }
  .cookie-actions .btn {
    flex: 1;
  }
}

/* ---------- Motion & print ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media print {
  :root {
    --bg: #ffffff;
    --surface: #ffffff;
    --surface-2: #ffffff;
    --ink: #000000;
    --ink-2: #333333;
    --ink-3: #555555;
    --line: #cccccc;
  }
  body {
    background: #fff;
    color: #000;
  }
  .site-header,
  .site-footer,
  .ad,
  .cookie,
  .calc-actions,
  .related,
  .author-box,
  .article-aside,
  .hero-actions,
  .menu,
  .lang {
    display: none !important;
  }
  .calc-grid {
    grid-template-columns: 1fr;
  }
  .calc-panel--results {
    position: static;
    break-inside: avoid;
  }
  .calc-panel--form,
  .calc-panel,
  .chart-block,
  .table-wrap {
    border-color: #ccc;
    box-shadow: none;
  }
  .container,
  .container--narrow {
    width: 100%;
  }
  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 0.7em;
    color: #555;
  }
}
