/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html, body, h1, h2, h3, h4, h5, h6, p, ul, ol, figure, blockquote { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }

:root {
  --color-background: #000000;
  --color-surface: #1a1a1a;
  --color-button: #8e3cf6;
  --color-button-hover: #000000;
  --color-button-text: #ffffff;
  --color-secondary-button: #000000;
  --color-secondary-button-hover: #8e3cf6;
  --color-secondary-button-text: #ffffff;
  --color-font: #ffffff;
  --color-headers: #8e3cf6;
  --color-link: #8e3cf6;
  --color-link-hover: #ffffff;
  --color-border: #0e9e55;
  --color-accent: #0e9e55;
  --font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

html { font-size: 16px; }

body {
  background-color: var(--color-background);
  color: var(--color-font);
  font-family: var(--font-family);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--color-font);
  font-family: var(--font-family);
  line-height: 1.2;
}

p { color: var(--color-font); }

a {
  color: var(--color-link);
}
a:hover, a:focus {
  color: var(--color-link-hover);
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}

.btn {
  display: inline-block;
  font-family: var(--font-family);
  font-weight: 600;
  font-size: 1rem;
  padding: 10px 22px;
  border-radius: 6px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  text-align: center;
}

.btn-cta,
.btn-primary {
  background-color: var(--color-button);
  color: var(--color-button-text);
}
.btn-cta:hover,
.btn-primary:hover {
  background-color: var(--color-button-hover);
  color: var(--color-button-text);
  border-color: var(--color-button);
}

.btn-secondary {
  background-color: var(--color-secondary-button);
  color: var(--color-secondary-button-text);
  border-color: var(--color-border);
}
.btn-secondary:hover {
  background-color: var(--color-secondary-button-hover);
  color: var(--color-secondary-button-text);
}

/* Header */
.site-header {
  background-color: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  padding: 14px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.logo-link {
  display: inline-flex;
  align-items: center;
}

.logo-img {
  height: 40px;
  width: auto;
}

/* Footer */
.site-footer {
  background-color: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: 28px 0;
  margin-top: auto;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

.footer-logo-img {
  height: 32px;
  width: auto;
}

.footer-legal {
  color: var(--color-font);
  font-size: 0.875rem;
  opacity: 0.8;
}

/* Layout helpers for page bodies */
body {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

main {
  flex: 1 0 auto;
}

/* Tablet */
@media (min-width: 600px) {
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

/* Desktop */
@media (min-width: 1024px) {
  .logo-img { height: 48px; }
  .footer-logo-img { height: 36px; }
}

/* ---- Page-body additions (brand-driven design system) ---- */
:root {
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 16px;
  --space-4: 24px;
  --space-5: 32px;
  --space-6: 48px;
  --space-7: 64px;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  --maxw-narrow: 760px;
}

h1 {
  font-size: clamp(2rem, 1.4rem + 2.6vw, 3.25rem);
  line-height: 1.15;
  font-weight: 700;
}

h2 {
  font-size: clamp(1.4rem, 1.15rem + 1vw, 2rem);
  line-height: 1.2;
  font-weight: 700;
  margin-bottom: var(--space-3);
}

body p,
.page li {
  font-size: clamp(1rem, 0.95rem + 0.15vw, 1.125rem);
  line-height: 1.6;
}

.container.narrow {
  max-width: var(--maxw-narrow);
}

.page .section {
  padding: var(--space-6) 0;
  background-color: var(--color-background);
}

.page .section > .container {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.page .section-alt {
  background-color: var(--color-surface);
}

.page .section h2 {
  color: var(--color-font);
}

.page .section p + p,
.page .section p + .table-wrap,
.page .section .table-wrap + p {
  margin-top: var(--space-2);
}

/* Hero */
.hero {
  background: radial-gradient(circle at 20% 20%, rgba(142, 60, 246, 0.35), transparent 55%),
              linear-gradient(180deg, var(--color-surface) 0%, var(--color-background) 100%);
  padding: var(--space-7) 0 var(--space-6);
  border-bottom: 1px solid var(--color-border);
}

.hero-inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  max-width: 820px;
}

.hero-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-accent);
}

.hero-lead {
  font-size: clamp(1.05rem, 1rem + 0.3vw, 1.3rem);
  max-width: 68ch;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-2);
}

.trust-item {
  display: inline-flex;
  align-items: center;
  background-color: rgba(14, 158, 85, 0.15);
  border: 1px solid var(--color-border);
  color: var(--color-font);
  border-radius: 999px;
  padding: var(--space-1) var(--space-3);
  font-size: 0.875rem;
  font-weight: 600;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-3);
}

.btn {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

/* Carousel / promo tiles */
.carousel {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3);
  margin-top: var(--space-5);
  padding-bottom: var(--space-2);
}

.tile {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tile:hover {
  transform: translateY(-4px);
}

.tile-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.tile-body {
  padding: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  flex: 1;
}

.tile-heading {
  font-size: 1.1rem;
  margin: 0;
}

.tile-btn {
  width: 100%;
}

/* Byline card */
.byline-card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  font-size: 0.9rem;
}

/* TOC */
.toc-box {
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-4);
  background-color: var(--color-surface);
}

.toc-title {
  margin-bottom: var(--space-2);
}

.toc-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-2);
}

.toc-list li::before {
  content: "\2713";
  color: var(--color-accent);
  margin-right: var(--space-2);
  font-weight: 700;
}

.toc-list a {
  color: var(--color-font);
  text-decoration: underline;
  text-decoration-color: var(--color-accent);
  text-underline-offset: 3px;
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: var(--space-2) 0;
}

.toc-list a:hover,
.toc-list a:focus-visible {
  color: var(--color-link-hover);
}

/* Callouts */
.callout {
  border-left: 4px solid var(--color-accent);
  background-color: rgba(14, 158, 85, 0.1);
  padding: var(--space-3);
  border-radius: var(--radius-sm);
}

/* Banner */
.banner-link {
  display: block;
  min-height: 44px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease;
}

.banner-link:hover {
  transform: scale(1.01);
}

.banner-img {
  width: 100%;
  min-height: 44px;
  object-fit: cover;
  display: block;
}

.figure-block img {
  width: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
}

/* Tables */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  margin-top: var(--space-2);
}

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

thead th {
  background-color: var(--color-button);
  color: var(--color-button-text);
  text-align: left;
  padding: var(--space-2) var(--space-3);
  font-weight: 700;
  font-size: 0.9rem;
}

tbody td {
  padding: var(--space-3);
  border-top: 1px solid var(--color-border);
  font-size: 0.92rem;
  vertical-align: top;
}

tbody tr:nth-child(odd) {
  background-color: rgba(255, 255, 255, 0.02);
}

/* Steps */
.steps {
  counter-reset: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.steps li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
}

.step-num {
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--color-button);
  color: var(--color-button-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}

/* Bullets */
.bullets {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding-left: var(--space-2);
}

.bullets li {
  position: relative;
  padding-left: var(--space-4);
}

.bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--color-accent);
}

/* CTA row */
.cta-row {
  display: flex;
  justify-content: center;
  margin-top: var(--space-3);
}

/* FAQ accordion */
.faq {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-top: var(--space-3);
}

.faq-item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background-color: var(--color-background);
  padding: var(--space-3);
}

.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  list-style: none;
  color: var(--color-font);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: var(--space-2) 0;
}

.faq-item summary h3 {
  font-size: inherit;
  font-weight: inherit;
  color: inherit;
  line-height: inherit;
  margin: 0;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.3rem;
  color: var(--color-accent);
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-answer {
  padding-top: var(--space-2);
}

/* Sources */
.sources-block {
  margin-top: var(--space-5);
  border-top: 1px solid var(--color-border);
  padding-top: var(--space-4);
}

.sources-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  font-size: 0.88rem;
  opacity: 0.92;
}

code {
  background-color: rgba(255, 255, 255, 0.08);
  padding: 0 4px;
  border-radius: 4px;
  font-size: 0.92em;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .btn,
  .tile,
  .banner-link,
  .faq-item summary::after {
    transition: none !important;
  }
}

/* Tablet */
@media (min-width: 600px) {
  .carousel {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Desktop */
@media (min-width: 900px) {
  .carousel {
    grid-template-columns: repeat(3, 1fr);
  }

  .toc-list {
    grid-template-columns: repeat(2, 1fr);
  }
}