:root {
  --bg: #0A1228;
  --surface: #15203A;
  --surface-hi: #1F2D4E;
  --hairline: #2A3A5E;
  --amber: #FFB547;
  --teal: #5EE3D6;
  --text-hi: #F3F5FB;
  --text-mid: #BFC8E0;
  --text-lo: #8794B5;
  --max-w: 760px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text-hi);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--amber);
  text-decoration: underline;
  text-underline-offset: 2px;
}
a:hover { color: var(--teal); }

main, header, footer {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 24px 20px;
}

header {
  border-bottom: 1px solid var(--hairline);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

header .brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.2px;
}

header nav {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 0.95rem;
}

header nav a {
  color: var(--text-mid);
  text-decoration: none;
}
header nav a:hover { color: var(--text-hi); }

h1, h2, h3 {
  color: var(--text-hi);
  line-height: 1.25;
}
h1 { font-size: 2rem; margin: 0.6em 0 0.4em; }
h2 { font-size: 1.35rem; margin: 1.6em 0 0.5em; }
h3 { font-size: 1.05rem; margin: 1.2em 0 0.4em; color: var(--text-mid); }

p, ul, ol { color: var(--text-mid); }
li { margin: 0.25em 0; }

.lede { font-size: 1.1rem; color: var(--text-hi); }

.muted { color: var(--text-lo); font-size: 0.9rem; }

.card {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 14px;
  padding: 18px 20px;
  margin: 16px 0;
}

code, pre {
  background: var(--surface-hi);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  padding: 1px 6px;
  font-size: 0.9em;
  color: var(--text-hi);
}
pre { padding: 12px 14px; overflow-x: auto; }

footer {
  border-top: 1px solid var(--hairline);
  color: var(--text-lo);
  font-size: 0.9rem;
  margin-top: 40px;
}

footer .row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  justify-content: space-between;
  align-items: center;
}

.cta {
  display: inline-block;
  background: var(--amber);
  color: #1A1003;
  font-weight: 700;
  padding: 10px 18px;
  border-radius: 999px;
  text-decoration: none;
  margin-top: 12px;
}
.cta:hover { background: var(--teal); color: #06231F; }

.icon-circle {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: var(--surface-hi);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--amber);
  font-weight: 700;
}

.toc {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 12px;
  padding: 12px 18px;
  font-size: 0.95rem;
  margin: 16px 0 24px;
}
.toc ul { padding-left: 18px; margin: 6px 0; }
.toc a { color: var(--text-mid); text-decoration: none; }
.toc a:hover { color: var(--amber); text-decoration: underline; }
