:root {
  color-scheme: light;
  --bg: #f6f8f7;
  --surface: #ffffff;
  --surface-soft: #f1f7f4;
  --surface-warm: #fff7ed;
  --ink: #111817;
  --muted: #5d6f69;
  --muted-strong: #394844;
  --line: #d9e4df;
  --line-strong: #bfd0c9;
  --green: #047857;
  --green-dark: #065f46;
  --blue: #2563eb;
  --cyan: #0f9f9a;
  --amber: #c56a16;
  --rose: #be3455;
  --shadow: 0 24px 70px rgba(17, 24, 23, 0.13);
  --shadow-soft: 0 14px 36px rgba(17, 24, 23, 0.08);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0, rgba(246, 248, 247, 0.98) 42%, rgba(239, 247, 244, 0.88) 100%),
    var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, Helvetica, sans-serif;
  line-height: 1.64;
  margin: 0;
  min-width: 320px;
  text-rendering: optimizeLegibility;
}

body::before {
  background-image:
    linear-gradient(rgba(4, 120, 87, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.045) 1px, transparent 1px);
  background-size: 48px 48px;
  content: "";
  inset: 0;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.28), transparent 48%);
  pointer-events: none;
  position: fixed;
  z-index: -1;
}

::selection {
  background: rgba(4, 120, 87, 0.18);
}

a {
  color: var(--green);
  text-decoration-color: rgba(4, 120, 87, 0.38);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

a:hover {
  color: var(--green-dark);
  text-decoration-color: currentColor;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.28);
  outline-offset: 3px;
}

h1,
h2,
h3,
p,
li,
td,
th,
a {
  overflow-wrap: break-word;
}

h1,
h2,
h3 {
  color: var(--ink);
  letter-spacing: 0;
  line-height: 1.12;
  text-wrap: balance;
}

p {
  margin-top: 0;
}

code {
  background: #e8f1ee;
  border: 1px solid rgba(191, 208, 201, 0.72);
  border-radius: 5px;
  color: #173c35;
  overflow-wrap: anywhere;
  padding: 0.1rem 0.3rem;
}

pre {
  background: #102521;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  color: #e8f8f2;
  overflow-x: auto;
  padding: 1rem;
}

pre code {
  background: transparent;
  border: 0;
  color: inherit;
  padding: 0;
}

.site-header {
  align-items: center;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(217, 228, 223, 0.92);
  box-shadow: 0 10px 30px rgba(17, 24, 23, 0.06);
  display: flex;
  gap: 1.5rem;
  justify-content: space-between;
  min-height: 72px;
  padding: 0 5vw;
  position: sticky;
  top: 0;
  z-index: 20;
}

.brand {
  align-items: center;
  color: var(--ink);
  display: inline-flex;
  flex: 0 0 auto;
  font-size: 1.08rem;
  font-weight: 860;
  gap: 0.58rem;
  letter-spacing: 0;
  text-decoration: none;
  white-space: nowrap;
}

.brand::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.36), transparent 38%),
    linear-gradient(135deg, var(--green), var(--blue));
  border-radius: var(--radius);
  box-shadow: 0 12px 24px rgba(4, 120, 87, 0.24);
  content: "";
  height: 1.85rem;
  width: 1.85rem;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  justify-content: flex-end;
}

.nav a,
.button {
  border-radius: var(--radius);
  color: var(--ink);
  line-height: 1.2;
  min-width: 0;
  padding: 0.64rem 0.88rem;
  text-decoration: none;
}

.nav a {
  border: 1px solid transparent;
  color: var(--muted-strong);
  font-size: 0.95rem;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.nav a:hover,
.nav a[aria-current="page"] {
  background: var(--surface-soft);
  border-color: rgba(4, 120, 87, 0.16);
  color: var(--green-dark);
}

.hero {
  background: #071a17;
  color: #ffffff;
  isolation: isolate;
  margin: 0;
  min-height: min(560px, calc(100svh - 188px));
  overflow: hidden;
  padding: clamp(2.45rem, 5vw, 4.15rem) 5vw clamp(2rem, 4vw, 3.2rem);
  position: relative;
}

.hero::before {
  background:
    linear-gradient(90deg, rgba(7, 26, 23, 0.99) 0, rgba(7, 26, 23, 0.94) 42%, rgba(7, 26, 23, 0.55) 72%, rgba(7, 26, 23, 0.16) 100%),
    url("seo-archive-map.png") calc(100% + 120px) center / min(920px, 68vw) auto no-repeat;
  content: "";
  inset: 0;
  position: absolute;
  z-index: -2;
}

.hero::after {
  background:
    linear-gradient(180deg, transparent 0, rgba(4, 120, 87, 0.13) 100%),
    linear-gradient(90deg, rgba(37, 99, 235, 0.16), transparent 42%, rgba(197, 106, 22, 0.13));
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  bottom: 0;
  content: "";
  height: 34%;
  left: 0;
  position: absolute;
  right: 0;
  z-index: -1;
}

.hero-copy {
  max-width: 760px;
  position: relative;
}

.hero h1 {
  color: #ffffff;
  font-size: 3.7rem;
  line-height: 1.02;
  margin: 0 0 1.35rem;
  max-width: 760px;
}

.hero p {
  color: rgba(235, 248, 242, 0.86);
  font-size: 1.07rem;
  max-width: 680px;
}

.hero img {
  height: 1px;
  opacity: 0;
  pointer-events: none;
  position: absolute;
  width: 1px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.82rem;
  margin-top: 1.9rem;
}

.button {
  align-items: center;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid var(--line);
  display: inline-flex;
  font-weight: 760;
  justify-content: center;
  min-height: 2.95rem;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.button:hover {
  background: #ffffff;
  border-color: rgba(4, 120, 87, 0.26);
  box-shadow: var(--shadow-soft);
  color: var(--green-dark);
  transform: translateY(-1px);
}

.button.primary {
  background: linear-gradient(135deg, var(--green), var(--blue));
  border-color: transparent;
  box-shadow: 0 16px 32px rgba(4, 120, 87, 0.24);
  color: #ffffff;
}

.button.primary:hover {
  background: linear-gradient(135deg, #05865f, #1d55d8);
  color: #ffffff;
}

.hero .button {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.26);
  color: #ffffff;
}

.hero .button:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.42);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
  color: #ffffff;
}

.hero .button.primary {
  background: #ffffff;
  border-color: #ffffff;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.24);
  color: #0b332d;
}

.hero .button.primary:hover {
  background: #eaf7f1;
  color: #0b332d;
}

.hero-metrics {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 1.65rem;
  max-width: 760px;
}

.hero-metrics span {
  border-top: 1px solid rgba(255, 255, 255, 0.22);
  color: rgba(235, 248, 242, 0.78);
  display: block;
  padding-top: 0.82rem;
}

.hero-metrics strong {
  color: #ffffff;
  display: block;
  font-size: 1.78rem;
  line-height: 1;
  margin-bottom: 0.2rem;
}

.eyebrow {
  align-items: center;
  color: var(--amber);
  display: inline-flex;
  font-size: 0.78rem;
  font-weight: 850;
  gap: 0.5rem;
  letter-spacing: 0;
  margin: 0 0 0.62rem;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #7be2bf;
}

.eyebrow::before {
  background: currentColor;
  border-radius: 999px;
  content: "";
  height: 0.46rem;
  width: 0.46rem;
}

.section,
.source-band,
.article-layout {
  margin: 0 auto;
  max-width: 1180px;
  padding: clamp(3.4rem, 6vw, 5.2rem) 5vw;
}

.section-heading {
  max-width: 780px;
}

.section h2,
.source-band h2 {
  font-size: 3rem;
  margin: 0.25rem 0 1rem;
}

.section-heading p,
.split p,
.source-band p,
.lead,
.audit-grid p,
.route-list span,
.site-footer {
  color: var(--muted);
}

.audit-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 2.2rem;
}

.audit-grid article,
.route-list a,
.prose,
.side-panel,
.metric-panel {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(217, 228, 223, 0.94);
  border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(17, 24, 23, 0.055);
}

.audit-grid article {
  min-height: 228px;
  overflow: hidden;
  padding: 1.24rem;
  position: relative;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.audit-grid article::before {
  background: linear-gradient(90deg, var(--green), var(--blue), var(--amber));
  content: "";
  height: 3px;
  inset: 0 0 auto;
  position: absolute;
}

.audit-grid article:hover {
  border-color: rgba(4, 120, 87, 0.28);
  box-shadow: var(--shadow-soft);
  transform: translateY(-2px);
}

.audit-grid span {
  color: var(--blue);
  font-size: 0.92rem;
  font-weight: 850;
}

.audit-grid h3 {
  font-size: 1.2rem;
  margin: 0.58rem 0 0.56rem;
}

.split {
  align-items: start;
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 0.86fr) minmax(320px, 1.14fr);
}

.route-list {
  display: grid;
  gap: 0.85rem;
}

.route-list a {
  color: var(--ink);
  display: grid;
  gap: 0.25rem;
  padding: 1rem 1.1rem;
  text-decoration: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.route-list a::before {
  background: linear-gradient(135deg, var(--green), var(--cyan));
  border-radius: 999px;
  content: "";
  height: 0.55rem;
  width: 0.55rem;
}

.route-list a:hover {
  border-color: rgba(4, 120, 87, 0.28);
  box-shadow: var(--shadow-soft);
  color: var(--ink);
  transform: translateY(-1px);
}

.source-band {
  align-items: center;
  background:
    linear-gradient(135deg, rgba(241, 247, 244, 0.98), rgba(255, 247, 237, 0.86));
  border-bottom: 1px solid var(--line);
  border-top: 1px solid var(--line);
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 0.78fr) minmax(320px, 1.22fr);
  max-width: none;
}

.source-band > div {
  justify-self: end;
  max-width: 430px;
}

.source-band .link-row {
  max-width: 740px;
}

.article-layout {
  align-items: start;
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 1fr) 310px;
}

.prose {
  padding: clamp(1.4rem, 4vw, 2.75rem);
  position: relative;
}

.prose::before {
  background: linear-gradient(90deg, var(--green), var(--blue), var(--amber));
  border-radius: var(--radius) var(--radius) 0 0;
  content: "";
  height: 4px;
  inset: 0 0 auto;
  position: absolute;
}

.hero > *,
.split > *,
.source-band > *,
.article-layout > *,
.prose,
.side-panel,
.metric-panel {
  min-width: 0;
}

.prose h1 {
  font-size: 3.35rem;
  line-height: 1.04;
  margin: 0.25rem 0 1rem;
}

.prose h2 {
  font-size: 1.95rem;
  margin: 2.25rem 0 1rem;
}

.prose h3 {
  margin-bottom: 0.4rem;
}

.lead {
  font-size: 1.12rem;
  margin-bottom: 1.65rem;
}

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

.process section,
.topic-list section,
.steps li,
.feature-note {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 251, 249, 0.98));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 10px 24px rgba(17, 24, 23, 0.05);
  padding: 1rem;
}

.process span {
  background: linear-gradient(135deg, var(--green), var(--blue));
  border-radius: 999px;
  color: #ffffff;
  display: grid;
  font-weight: 850;
  height: 2rem;
  place-items: center;
  width: 2rem;
}

.table-wrap {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow-x: auto;
}

table {
  background: var(--surface);
  border-collapse: collapse;
  min-width: 720px;
  width: 100%;
}

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

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

th {
  background: var(--surface-soft);
  color: var(--green-dark);
  font-size: 0.92rem;
}

.check-list {
  display: grid;
  gap: 0.7rem;
  list-style: none;
  padding: 0;
}

.check-list li {
  background: var(--surface-soft);
  border-left: 4px solid var(--green);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 0.86rem 1rem;
}

.topic-list {
  display: grid;
  gap: 1rem;
}

.topic-list h2 {
  margin-top: 0;
}

.steps {
  counter-reset: item;
  display: grid;
  gap: 1rem;
  list-style: none;
  padding: 0;
}

.steps li {
  padding-left: 3.45rem;
  position: relative;
}

.steps li::before {
  background: linear-gradient(135deg, var(--amber), var(--rose));
  border-radius: 999px;
  color: #ffffff;
  content: counter(item);
  counter-increment: item;
  display: grid;
  font-weight: 850;
  height: 1.9rem;
  left: 1rem;
  place-items: center;
  position: absolute;
  top: 1.12rem;
  width: 1.9rem;
}

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

.code-grid > * {
  min-width: 0;
}

.side-panel,
.metric-panel {
  align-self: start;
  display: grid;
  gap: 0.9rem;
  padding: 1.25rem;
  position: sticky;
  top: 96px;
}

.side-panel h2,
.metric-panel h2 {
  font-size: 1.08rem;
  margin: 0;
}

.side-panel a,
.side-panel span,
.link-row a,
.link-row span {
  display: inline-flex;
}

.side-panel a,
.side-panel span,
.link-row a,
.link-row span {
  background: var(--surface-soft);
  border: 1px solid rgba(4, 120, 87, 0.12);
  border-radius: var(--radius);
  color: var(--green-dark);
  padding: 0.58rem 0.72rem;
  text-decoration: none;
}

.side-panel a:hover,
.link-row a:hover {
  background: #e4f2ed;
  border-color: rgba(4, 120, 87, 0.25);
}

.side-panel hr {
  border: 0;
  border-top: 1px solid var(--line);
  width: 100%;
}

.metric-panel {
  background:
    linear-gradient(180deg, rgba(255, 253, 250, 0.98), rgba(255, 247, 237, 0.96));
  border-color: #ecd7bd;
}

.metric-panel ol,
.metric-panel ul {
  margin: 0;
  padding-left: 1.2rem;
}

.link-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.site-footer {
  background: rgba(255, 255, 255, 0.7);
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  justify-content: space-between;
  padding: 2rem 5vw;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 1080px) {
  .hero h1 {
    font-size: 3rem;
  }

  .section h2,
  .source-band h2 {
    font-size: 2.35rem;
  }

  .prose h1 {
    font-size: 2.75rem;
  }
}

@media (max-width: 900px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.8rem;
    padding-bottom: 1rem;
    padding-top: 1rem;
    position: static;
  }

  .nav {
    justify-content: flex-start;
    width: 100%;
  }

  .hero {
    min-height: auto;
  }

  .hero::before {
    background:
      linear-gradient(90deg, rgba(7, 26, 23, 0.96), rgba(7, 26, 23, 0.8)),
      url("seo-archive-map.png") right top / 760px auto no-repeat;
  }

  .split,
  .source-band,
  .article-layout {
    grid-template-columns: 1fr;
  }

  .source-band > div {
    justify-self: start;
  }

  .audit-grid,
  .process,
  .code-grid {
    grid-template-columns: 1fr 1fr;
  }

  .side-panel,
  .metric-panel {
    position: static;
  }
}

@media (max-width: 620px) {
  .site-header {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .nav {
    flex-wrap: wrap;
    overflow-x: visible;
    padding-bottom: 0.15rem;
  }

  .nav a {
    padding-left: 0.58rem;
    padding-right: 0.58rem;
  }

  .section,
  .source-band,
  .article-layout,
  .hero {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .section,
  .source-band {
    padding-bottom: 3rem;
    padding-top: 3rem;
  }

  .hero {
    padding-bottom: 1.45rem;
    padding-top: 1.65rem;
  }

  .hero h1 {
    font-size: 2.02rem;
    line-height: 1.08;
    margin-bottom: 0.85rem;
  }

  .hero p,
  .lead {
    font-size: 0.98rem;
  }

  .section h2,
  .source-band h2 {
    font-size: 2rem;
  }

  .prose h1 {
    font-size: 2.08rem;
    line-height: 1.08;
  }

  .prose h2 {
    font-size: 1.48rem;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 0.65rem;
    margin-top: 1rem;
  }

  .button {
    justify-content: center;
    min-height: 2.72rem;
  }

  .audit-grid,
  .process,
  .code-grid {
    grid-template-columns: 1fr;
  }

  .hero-metrics {
    gap: 0.45rem;
    margin-top: 1.05rem;
  }

  .hero-metrics span {
    font-size: 0.78rem;
    padding-top: 0.58rem;
  }

  .hero-metrics strong {
    font-size: 1.32rem;
  }

  .audit-grid article {
    min-height: 0;
  }

  .prose {
    padding: 1.1rem;
  }

  table {
    font-size: 0.92rem;
    min-width: 680px;
  }

  th,
  td {
    padding: 0.66rem;
  }

  pre {
    max-width: 100%;
    white-space: pre-wrap;
  }

  .steps li {
    padding-left: 1rem;
    padding-top: 3.2rem;
  }
}
