:root {
  --bg: #fafaf7;
  --ink: #1a1a1a;
  --muted: #6b6b6b;
  --line: #e5e5e5;
  --accent: #1b3a57;
  --success: #2e7d32;
  --accent-soft: #eef3f7;
  --white: #ffffff;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 17px;
}

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

a {
  color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.site-header,
.site-footer,
main {
  width: min(100%, 720px);
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}

.site-header {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  padding-top: 28px;
  padding-bottom: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
}

.brand img {
  display: block;
  width: 180px;
  height: auto;
}

nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 14px;
  font-size: 0.92rem;
}

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

h1 {
  margin: 0;
  font-size: clamp(2rem, 8vw, 2.35rem);
  line-height: 1.08;
  letter-spacing: 0;
}

h2 {
  margin: 0 0 18px;
  font-size: clamp(1.45rem, 5vw, 1.65rem);
  line-height: 1.25;
  letter-spacing: 0;
}

h3 {
  margin: 0 0 8px;
  font-size: 1.2rem;
  line-height: 1.25;
}

p {
  margin: 0 0 18px;
}

.hero {
  padding: 64px 0;
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.lead {
  margin-top: 24px;
  color: var(--muted);
  font-size: 1.16rem;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button,
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  color: var(--white);
  background: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 8px;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.button-secondary {
  color: var(--accent);
  background: transparent;
}

.button-secondary:hover,
.button-secondary:focus {
  color: var(--success);
  border-color: var(--success);
}

.meta {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.section {
  padding: 54px 0;
  border-top: 1px solid var(--line);
}

.steps {
  display: grid;
  gap: 12px;
  padding-left: 22px;
}

.articles-list article,
.download-box,
.legal-box,
blockquote,
pre {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.articles-list {
  display: grid;
  gap: 16px;
}

.article-page {
  padding-top: 46px;
  padding-bottom: 84px;
}

.article-page header {
  margin-bottom: 42px;
}

.article-page h2 {
  margin-top: 56px;
}

.article-page ul,
.article-page ol {
  padding-left: 24px;
}

blockquote {
  margin: 24px 0;
  color: var(--muted);
}

pre {
  overflow-x: auto;
  margin: 24px 0;
  white-space: pre-wrap;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9rem;
}

table {
  width: 100%;
  margin: 26px 0;
  border-collapse: collapse;
  background: var(--white);
}

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

th {
  color: var(--accent);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.download-box,
.legal-box {
  margin: 28px 0;
}

form {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

label {
  font-weight: 700;
}

input {
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  font: inherit;
}

select {
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  font: inherit;
}

.result-panel {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

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

.result-value {
  margin: 0;
  color: var(--accent);
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1.1;
}

.small {
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer {
  padding-top: 36px;
  padding-bottom: 36px;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

@media (max-width: 640px) {
  html {
    font-size: 18px;
  }

  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  nav {
    justify-content: flex-start;
  }

  .hero {
    padding-top: 48px;
  }

  .result-grid {
    grid-template-columns: 1fr;
  }
}
