/* Quodra Legal — the docs book's reading voice, minus the book. One centred
   column at a reading measure, dates under the title, an On-this-page rail on
   wide screens. Self-contained like docs.css: these pages must render with
   nothing else loaded. */
:root {
  --bg: #08090a; --bg-2: #0e0f11; --panel: #131415; --panel-2: #1a1b1c;
  --border: #232426; --border-2: #2d2d2f;
  --text: #E7E9EC; --text-soft: #B4B7BD; --muted: #8A8D93; --faint: #9699A1;
  --accent: #8A6BFF; --accent-strong: #7C4DFF; --accent-soft: rgba(124,77,255,.14);
  --accent-quiet: #B7A6FF;
  --code-bg: #0c0d0f; --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --toc: 230px; --measure: 760px;
}
:root[data-theme="light"] {
  --bg: #FBFAF6; --bg-2: #F1EFE8; --panel: #FFFFFF; --panel-2: #F2F0E9;
  --border: #E4E0D4; --border-2: #D5D0C2;
  --text: #1B1C1F; --text-soft: #43464C; --muted: #6C6F76; --faint: #686B72;
  --accent: #6B47E0; --accent-strong: #5B2EE0; --accent-soft: rgba(91,46,224,.10);
  --accent-quiet: #5B2EE0;
  --code-bg: #14151A;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--sans);
  font-size: 16px; line-height: 1.7; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: var(--panel); padding: 8px 12px; border-radius: 8px; z-index: 100; }

/* header — same shape as the docs header so moving between them feels seamless */
.lhead { position: sticky; top: 0; z-index: 50; height: 60px; display: flex; align-items: center;
  gap: 16px; padding: 0 22px; background: rgba(8,9,10,.82); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border); }
:root[data-theme="light"] .lhead { background: rgba(251,250,246,.85); }
.lhead__brand { display: flex; align-items: center; gap: 9px; color: var(--text); font-weight: 620;
  font-size: 17px; letter-spacing: -.01em; }
.lhead__brand:hover { text-decoration: none; }
.lhead__actions { margin-left: auto; display: flex; align-items: center; gap: 20px; font-size: 14.5px; }
.lhead__actions > a { color: var(--text-soft); }
.lhead__cta { padding: 7px 15px; border-radius: 9px; background: var(--accent-strong);
  color: #fff !important; font-weight: 560; }
.lhead__cta:hover { background: var(--accent); text-decoration: none; }
.lhead__theme { display: inline-flex; align-items: center; gap: 7px; padding: 6px 11px;
  border: 1px solid var(--border); border-radius: 9px; background: var(--panel);
  color: var(--text-soft); font: inherit; font-size: 13.5px; line-height: 1; cursor: pointer;
  transition: color .15s ease, border-color .15s ease; }
.lhead__theme:hover { color: var(--text); border-color: var(--border-2); }
.lhead__theme svg { width: 15px; height: 15px; }

/* layout: centred column + optional right rail */
.llayout { display: grid; grid-template-columns: minmax(0, 1fr) var(--toc); width: 100%;
  max-width: calc(var(--measure) + var(--toc) + 96px); margin: 0 auto; align-items: start; }
.lmain { min-width: 0; padding: 40px 32px 80px; }
.doc { max-width: var(--measure); margin: 0 auto; }
.doc__eyebrow { font-family: var(--mono); font-size: 11.5px; letter-spacing: .16em;
  text-transform: uppercase; color: var(--accent-quiet); margin-bottom: 10px; }
.doc h1 { font-size: 2.05rem; line-height: 1.15; letter-spacing: -.02em; margin: 0 0 10px; text-wrap: balance; }
.doc__dates { display: flex; gap: 10px; flex-wrap: wrap; color: var(--muted); font-size: 14px;
  font-family: var(--mono); margin: 0 0 14px; }
.doc__lede { color: var(--text-soft); font-size: 1.08rem; margin: 0 0 26px; }
.doc h2 { font-size: 1.32rem; letter-spacing: -.01em; margin: 44px 0 12px; padding-top: 14px;
  border-top: 1px solid var(--border); }
.doc h3 { font-size: 1.06rem; margin: 26px 0 8px; }
.doc h2 .anchor, .doc h3 .anchor { margin-left: 8px; color: var(--faint); opacity: 0;
  font-weight: 400; transition: opacity .12s ease; }
.doc h2:hover .anchor, .doc h3:hover .anchor,
.doc h2 .anchor:focus-visible, .doc h3 .anchor:focus-visible { opacity: 1; }
.doc p { margin: 0 0 14px; }
.doc ul, .doc ol { margin: 0 0 14px; padding-left: 24px; }
.doc li { margin-bottom: 5px; }
.doc hr { border: 0; border-top: 1px solid var(--border); margin: 30px 0; }
.doc code { font-family: var(--mono); font-size: .85em; background: var(--panel);
  border: 1px solid var(--border); border-radius: 5px; padding: 1px 5px; overflow-wrap: anywhere; }
.doc pre.code { background: var(--code-bg); color: #c9cfda; border-radius: 10px;
  padding: 14px 16px; overflow-x: auto; font-family: var(--mono); font-size: 13px; line-height: 1.6; }
.doc pre.code code { background: none; border: 0; padding: 0; font-size: inherit; }
.callout { border: 1px solid var(--border); border-left: 3px solid var(--accent);
  background: var(--panel); border-radius: 10px; padding: 12px 16px; margin: 0 0 16px; }
.callout__label { font-family: var(--mono); font-size: 11px; letter-spacing: .12em;
  text-transform: uppercase; color: var(--accent-quiet); margin-bottom: 4px; }
.callout p { margin: 0; color: var(--text-soft); }
.tablewrap { overflow-x: auto; margin: 0 0 18px; border: 1px solid var(--border); border-radius: 10px; }
.doc table { border-collapse: collapse; width: 100%; font-size: 14px; }
.doc th, .doc td { text-align: left; padding: 9px 13px; border-bottom: 1px solid var(--border); vertical-align: top; }
.doc th { font-family: var(--mono); font-size: 11.5px; text-transform: uppercase;
  letter-spacing: .08em; color: var(--muted); background: var(--panel); }
.doc tr:last-child td { border-bottom: 0; }

/* the right rail */
.onthis { position: sticky; top: 84px; padding: 0 22px 40px 0; margin-top: 40px;
  max-height: calc(100vh - 110px); overflow-y: auto; font-size: 13px; }
.onthis__title { font-family: var(--mono); font-size: 11px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.onthis a { display: block; color: var(--text-soft); padding: 3.5px 0; line-height: 1.4; }
.onthis a:hover { color: var(--text); text-decoration: none; }

/* footer */
.lfoot { max-width: var(--measure); margin: 56px auto 0; padding-top: 18px;
  border-top: 1px solid var(--border); color: var(--muted); font-size: 13.5px;
  display: flex; flex-direction: column; gap: 8px; }
.lfoot a { color: var(--text-soft); }
.doc p a, .doc li a, .lfoot a { text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 1080px) {
  .llayout { grid-template-columns: minmax(0, 1fr); max-width: calc(var(--measure) + 64px); }
  .onthis { display: none; }
}
@media (max-width: 640px) {
  .lmain { padding: 28px 18px 64px; }
  .doc h1 { font-size: 1.7rem; }
  .lhead { padding: 0 16px; }
  .lhead__actions { gap: 12px; }
  .lhead__actions > a:not(.lhead__cta) { display: none; }
}
