:root {
  color-scheme: dark;
  --background: #111914;
  --surface: #18231b;
  --text: #edf3ed;
  --muted: #b8c3ba;
  --accent: #c6ed94;
  --border: #354238;
  font-family: system-ui, sans-serif;
  background: var(--background);
  color: var(--text);
  scroll-padding-top: 28px;
}
* { box-sizing: border-box; }
body { margin: 0; line-height: 1.7; }
a { color: var(--accent); text-underline-offset: 4px; overflow-wrap: anywhere; }
a:hover { color: #e0ffc0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }
.skip { position: fixed; left: 16px; top: -100px; z-index: 10; padding: 12px 20px; background: var(--surface); }
.skip:focus { top: 12px; }
.topbar { max-width: 1440px; margin: auto; padding: 26px 40px; display: flex; justify-content: space-between; align-items: center; gap: 20px; border-bottom: 1px solid var(--border); font-size: 13px; }
.brand { color: var(--text); font-size: 20px; font-weight: 600; text-decoration: none; }
.brand span { color: var(--muted); font-size: 13px; font-weight: 400; }
.layout { max-width: 1340px; margin: 0 auto; padding: 50px 40px 0; display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 64px; }
.toc { position: sticky; top: 28px; align-self: start; font-size: 13px; }
.toc ol { margin: 16px 0 28px; padding-left: 22px; }
.toc li { padding: 5px 0 5px 4px; color: var(--muted); }
.toc a { text-decoration: none; color: var(--muted); }
.toc a:hover, .toc .back { color: var(--accent); }
.eyebrow, .step { color: var(--accent); font-size: 11px; letter-spacing: 1.6px; text-transform: uppercase; }
.eyebrow { margin: 0; }
.hero { padding: 10px 0 30px; }
h1 { margin: 22px 0; font-size: clamp(34px, 4.2vw, 62px); line-height: 1.12; font-weight: 500; letter-spacing: -0.045em; }
h1 span { color: var(--accent); }
.lead { max-width: 750px; font-size: 19px; color: var(--muted); line-height: 1.7; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin: 26px 0 18px; }
.badges span { font-size: 11px; border: 1px solid var(--border); border-radius: 30px; padding: 5px 12px; color: var(--muted); }
.caption, figcaption { color: #a4b3a6; font-size: 12px; line-height: 1.65; }
section { padding: 46px 0 8px; border-top: 1px solid var(--border); margin-top: 40px; scroll-margin-top: 20px; }
h2 { margin: 10px 0 24px; font-size: clamp(25px, 3vw, 34px); line-height: 1.2; font-weight: 500; letter-spacing: -0.025em; }
h3 { margin: 32px 0 14px; font-size: 20px; font-weight: 500; }
p { margin: 16px 0; }
li { margin: 10px 0; padding-left: 4px; }
ul, ol { padding-left: 24px; }
.note { background: var(--surface); border-left: 3px solid var(--accent); padding: 18px 22px; margin: 28px 0; color: var(--muted); font-size: 14px; }
.note strong { color: var(--text); }
code, pre { font-family: ui-monospace, Consolas, monospace; }
code { color: #d7ecc8; overflow-wrap: anywhere; }
:not(pre) > code { font-size: 0.9em; background: var(--surface); border-radius: 3px; padding: 2px 4px; }
pre { position: relative; background: #0c130e; border: 1px solid var(--border); border-radius: 10px; padding: 48px 20px 20px; margin: 22px 0; line-height: 1.7; font-size: 13px; max-width: 100%; overflow-x: auto; tab-size: 2; }
pre code { overflow-wrap: normal; }
.copy { position: absolute; top: 10px; right: 12px; font: inherit; font-size: 11px; color: var(--accent); border: 1px solid #42553d; padding: 4px 10px; background: var(--surface); border-radius: 5px; cursor: pointer; }
.copy:hover { background: #253326; }
figure { margin: 28px 0; }
figure a { display: block; background: #f8f9fa; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
img { display: block; width: 100%; height: auto; }
figcaption { margin-top: 10px; }
.table-wrap { width: 100%; overflow-x: auto; margin: 24px 0; }
table { width: 100%; border-collapse: collapse; text-align: left; font-size: 14px; }
th, td { padding: 14px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
thead th { color: var(--muted); font-size: 12px; font-weight: 500; }
tbody th { font-weight: 500; width: 38%; }
td { color: var(--muted); }
kbd { border: 1px solid var(--border); border-radius: 4px; padding: 2px 7px; font-size: 12px; }
details { border-bottom: 1px solid var(--border); padding: 18px 0; }
summary { cursor: pointer; color: var(--accent); font-size: 16px; padding-right: 12px; }
details p { color: var(--muted); font-size: 14px; }
.sources li { font-size: 14px; }
footer { display: flex; justify-content: space-between; gap: 24px; padding: 38px 0; margin-top: 40px; border-top: 1px solid var(--border); font-size: 13px; }
@media (max-width: 1000px) {
  .layout { grid-template-columns: 180px minmax(0, 1fr); gap: 32px; padding: 35px 24px 0; }
  .topbar { padding: 22px 24px; }
}
@media (max-width: 760px) {
  .layout { display: block; padding: 28px 20px 0; }
  .topbar { padding: 20px; flex-wrap: wrap; }
  .topbar > a:last-child { font-size: 12px; }
  .toc { position: static; border-bottom: 1px solid var(--border); padding-bottom: 18px; margin-bottom: 32px; }
  .toc ol { columns: 2; column-gap: 24px; font-size: 12px; margin-bottom: 12px; }
  .toc li { break-inside: avoid; padding: 2px 0; }
  .toc .back { display: none; }
  .lead { font-size: 17px; }
  section { margin-top: 28px; padding-top: 32px; }
  pre { font-size: 12px; padding-left: 14px; padding-right: 14px; }
  th, td { padding: 12px 8px; }
  .note { padding: 16px; }
}
@media print {
  :root { color-scheme: light; --background: white; --surface: #f4f4f4; --text: #111; --muted: #333; --accent: #294d21; --border: #ccc; }
  .toc, .topbar, .copy, .skip, footer { display: none; }
  .layout { display: block; padding: 0; }
  main { max-width: none; }
  pre { white-space: pre-wrap; background: #f5f5f5; padding-top: 20px; }
  code { color: #111; }
  section { break-before: auto; }
  figure { break-inside: avoid; }
  details > * { display: block; }
}
