:root {
  --bg: #ffffff;
  --line: #e4e4e0;
  --text: #0e0e0e;
  --muted: #5e5e59;
  --green: #0f3d2e;
  --green-soft: #e7efeb;
  --todo: #fff4c2;
}
* { box-sizing: border-box; margin: 0; }
body { background: var(--bg); color: var(--text); font: 400 16px/1.7 "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--green); text-underline-offset: 3px; }
.wrap { max-width: 1280px; margin: 0 auto; padding: 0 48px; }
nav { display: flex; justify-content: space-between; align-items: center; height: 84px; border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 19px; letter-spacing: -0.02em; color: var(--text); text-decoration: none; }
.brand svg { width: 26px; height: 26px; }
nav .other { font-size: 15px; color: var(--muted); }

.doc { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 80px; padding: 72px 0 120px; }
.toc { position: sticky; top: 32px; align-self: start; font-size: 14px; }
.toc p { color: var(--muted); margin-bottom: 12px; }
.toc ol { padding-left: 26px; color: var(--muted); }
.toc li { padding: 3px 0; }
.toc a { color: var(--muted); text-decoration: none; }
.toc a:hover { color: var(--text); }
article { max-width: 44rem; }
h1 { font-weight: 500; font-size: clamp(40px, 5vw, 64px); line-height: 1; letter-spacing: -0.045em; }
.meta { margin-top: 20px; color: var(--muted); font-size: 15px; }
.draft { margin-top: 28px; padding: 16px 20px; background: var(--green-soft); border-left: 3px solid var(--green); font-size: 15px; }
h2 { margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line); font-weight: 500; font-size: 24px; letter-spacing: -0.02em; line-height: 1.25; scroll-margin-top: 24px; }
h3 { margin-top: 28px; font-weight: 500; font-size: 17px; }
article p, article ul, article table { margin-top: 14px; }
article ul { padding-left: 22px; }
article li { margin-top: 6px; }
article li::marker { color: var(--muted); }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th { text-align: left; font-weight: 500; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--text); vertical-align: bottom; }
td { padding: 12px 12px 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
mark { background: var(--todo); color: inherit; padding: 0 4px; border-radius: 2px; }
footer { display: flex; justify-content: space-between; gap: 16px; padding: 28px 0 40px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
footer a { color: var(--muted); margin-left: 20px; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }

@media (max-width: 900px) {
  .wrap { padding: 0 20px; }
  .doc { grid-template-columns: 1fr; gap: 40px; padding: 48px 0 80px; }
  .toc { display: none; }
  footer { flex-direction: column; }
  footer a { margin: 0 16px 0 0; }
  table, thead, tbody, tr, th, td { display: block; }
  thead { display: none; }
  tr { border-bottom: 1px solid var(--line); padding: 10px 0; }
  td { border: 0; padding: 2px 0; }
  td:first-child { font-weight: 500; }
}
