:root {
  --ink: #07140F; --ink-2: #0C201B;
  --green: #13B878; --green-dark: #08724C; --green-light: #49E8A9; --mint: #DDF8ED;
  --bg: #F3F7F5; --card: #FFFFFF; --line: #DCE7E1;
  --text: #10251D; --muted: #5E7268; --on-dark: #F5FFF9; --link: #08724C;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #06100C; --card: #0E1D17; --line: #1C3229; --text: #EAF6F0; --muted: #9DB3A8; --mint: #12352A; --link: #49E8A9; }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif; background: var(--bg); color: var(--text); line-height: 1.65; }
a { color: inherit; text-decoration: none; }
.wrap { width: min(1080px, 100% - 32px); margin-inline: auto; }

.top { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--ink) 92%, transparent); backdrop-filter: saturate(160%) blur(14px); border-bottom: 1px solid rgba(255,255,255,.06); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--on-dark); font-weight: 800; font-size: 19px; letter-spacing: -.02em; }
.brand b { color: var(--green-light); }
.brand svg { width: 32px; height: 32px; }
.back { color: rgba(245,255,249,.8); font-weight: 700; font-size: 14px; padding: 8px 14px; border-radius: 999px; border: 1px solid rgba(255,255,255,.16); }
.back:hover { background: rgba(255,255,255,.06); color: var(--on-dark); }

.head { padding: 48px 0 28px; border-bottom: 1px solid var(--line); }
.eyebrow { margin: 0 0 10px; color: var(--green); font-weight: 800; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
h1 { margin: 0; font-size: clamp(32px, 5vw, 48px); line-height: 1.1; letter-spacing: -.03em; }
.lead { margin: 16px 0 0; max-width: 720px; color: var(--muted); font-size: 17px; }
.meta { margin: 14px 0 0; color: var(--muted); font-size: 13px; font-weight: 600; }

.layout { display: grid; grid-template-columns: 230px 1fr; gap: 48px; padding: 32px 0 64px; align-items: start; }
.toc { position: sticky; top: 88px; font-size: 14px; }
.toc p { margin: 0 0 10px; font-weight: 800; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; border-left: 2px solid var(--line); }
.toc a { display: block; padding: 4px 0 4px 14px; margin-left: -2px; border-left: 2px solid transparent; color: var(--muted); font-weight: 600; }
.toc a:hover { color: var(--text); border-left-color: var(--green); }

article section { padding: 6px 0 22px; scroll-margin-top: 84px; }
article section + section { border-top: 1px solid var(--line); padding-top: 22px; }
h2 { margin: 0 0 10px; font-size: 21px; letter-spacing: -.01em; }
article p { margin: 0 0 10px; }
article ul { margin: 0 0 10px; padding-left: 20px; display: grid; gap: 6px; }
article li::marker { color: var(--green); }
article a { color: var(--link); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

footer { border-top: 1px solid var(--line); padding: 28px 0 44px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 14px 24px; justify-content: space-between; align-items: center; }
footer nav { display: flex; flex-wrap: wrap; gap: 8px 18px; }
footer a:hover, footer a[aria-current="page"] { color: var(--text); }
footer a[aria-current="page"] { font-weight: 700; }

@media (max-width: 820px) {
  .layout { grid-template-columns: 1fr; gap: 20px; padding-top: 20px; }
  .toc { position: static; }
  .toc ol { display: flex; flex-wrap: wrap; gap: 8px; border: 0; }
  .toc a { padding: 6px 12px; margin: 0; border: 1px solid var(--line); border-radius: 999px; background: var(--card); font-size: 13px; }
  .head { padding-top: 32px; }
}
