/* Shared by the docs, privacy and terms pages. The landing page keeps its own inline CSS. */
:root {
  --ground: #f5f6f8;
  --surface: #ffffff;
  --ink: #13161c;
  --muted: #5a6170;
  --faint: #8b92a0;
  --rule: #e2e5eb;
  --dot: #c9ced8;
  --del-bg: #fdf0f1;
  --del-ink: #a32a37;
  --add-bg: #ebf7f0;
  --add-ink: #146236;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Martian Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #111317; --surface: #191c22; --ink: #eceef2; --muted: #a0a7b3; --faint: #737a87; --rule: #2a2e36; --dot: #3a3f49;
    --del-bg: #2b1519; --del-ink: #ff9ea8; --add-bg: #12261a; --add-ink: #84e2ab;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ground: #111317; --surface: #191c22; --ink: #eceef2; --muted: #a0a7b3; --faint: #737a87; --rule: #2a2e36; --dot: #3a3f49;
  --del-bg: #2b1519; --del-ink: #ff9ea8; --add-bg: #12261a; --add-ink: #84e2ab;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 24px; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 17px/1.65 var(--sans); -webkit-font-smoothing: antialiased; }
.wrap { max-width: 1180px; margin: 0 auto;
  padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); }
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }

nav.top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-block: 26px; }
.brand { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.wordmark { font-family: var(--mono); font-weight: 500; font-size: 19px; letter-spacing: -0.03em; text-decoration: none; }
.crumb { font-family: var(--mono); font-size: 15px; color: var(--faint); letter-spacing: -0.03em; }
.crumb::before { content: "/"; margin-right: 10px; color: var(--dot); }
@media (max-width: 440px) { .crumb { display: none; } }
.navlinks { display: flex; align-items: center; gap: 28px; font-size: 15px; }
.navlinks a:not(.btn) { text-decoration: none; color: var(--muted); }
.navlinks a:not(.btn):hover, .navlinks a[aria-current="page"] { color: var(--ink); }
@media (max-width: 720px) { .navlinks a:not(.btn) { display: none; } }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border-radius: 12px; font-weight: 600; font-size: 16px; text-decoration: none; white-space: nowrap; }
.btn-ink { background: var(--ink); color: var(--ground); }
.btn-ink:hover { opacity: .88; }

/* page layout: contents on the left, prose on the right */
.doc { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 72px; padding-block: clamp(32px, 6vw, 72px) 112px; border-top: 1px solid var(--rule); }
.toc { position: sticky; top: 24px; align-self: start; max-height: calc(100vh - 48px); overflow-y: auto; font-size: 14.5px; }
.toc b { display: block; margin-bottom: 10px; font-size: 13px; font-weight: 600; color: var(--muted); letter-spacing: .02em; text-transform: uppercase; }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.toc a { display: block; padding: 5px 0; color: var(--muted); text-decoration: none; line-height: 1.35; }
.toc a:hover { color: var(--ink); }
@media (max-width: 920px) {
  .doc { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .toc { position: static; max-height: none; padding: 18px 20px; border-radius: 16px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule); }
  .toc ol { grid-template-columns: repeat(auto-fill, minmax(min(150px, 40%), 1fr)); column-gap: 18px; }
  .toc a { padding: 4px 0; font-size: 14px; }
}

.prose { max-width: 46em; min-width: 0; }
.prose > header { display: grid; gap: 14px; margin-bottom: 8px; }
.eyebrow { font-size: 14px; font-weight: 600; color: var(--muted); }
h1 { margin: 0; font-weight: 640; font-size: clamp(38px, 4.6vw, 56px); line-height: 1.05; letter-spacing: -0.03em; text-wrap: balance; }
.lead { margin: 0; color: var(--muted); font-size: 19px; line-height: 1.55; text-wrap: pretty; }
.prose section { padding-top: 56px; margin-top: 56px; border-top: 1px solid var(--rule); }
.prose header + section { border-top: 0; margin-top: 24px; padding-top: 24px; }
h2 { margin: 0 0 18px; font-weight: 640; font-size: clamp(27px, 2.6vw, 33px); line-height: 1.15; letter-spacing: -0.02em; text-wrap: balance; }
h3 { margin: 36px 0 10px; font-weight: 620; font-size: 19px; line-height: 1.3; }
p { margin: 0 0 14px; text-wrap: pretty; }
.muted { color: var(--muted); }
ul, ol { margin: 0 0 16px; padding-left: 1.3em; }
li { margin: 6px 0; padding-left: 4px; }
li::marker { color: var(--faint); }
strong { font-weight: 620; }
.prose a { text-decoration-color: var(--dot); text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: currentColor; }
code { font-family: var(--mono); font-stretch: 75%; font-size: 0.82em; letter-spacing: -0.02em; padding: 1px 6px; border-radius: 6px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule); overflow-wrap: anywhere; }

/* numbered steps */
ol.steps { list-style: none; padding: 0; counter-reset: step; display: grid; gap: 18px; margin: 20px 0 22px; }
ol.steps > li { counter-increment: step; display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 14px; margin: 0; padding: 0; }
ol.steps > li::before { content: counter(step); width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 620; font-size: 14px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule); }
ol.steps > li > div { min-width: 0; padding-top: 2px; }
ol.steps > li > div > p:last-child, ol.steps > li > div > pre:last-child { margin-bottom: 0; }

/* code blocks: the dark style of the landing page's sample event */
.code { position: relative; margin: 14px 0 20px; }
.code pre { margin: 0; padding: 20px 22px; border-radius: 16px; background: #14171d; color: #d7dbe3; box-shadow: 0 0 0 1px var(--rule);
  font-family: var(--mono); font-stretch: 75%; font-size: 13px; line-height: 1.75; letter-spacing: -0.02em; white-space: pre-wrap; overflow-wrap: anywhere; }
.code .c { color: #8b92a0; } .code .k { color: #8fb4ff; } .code .s { color: #a6e3b8; }
.code button { position: absolute; top: 10px; right: 10px; padding: 4px 10px; border: 0; border-radius: 999px; background: rgba(255, 255, 255, .12); color: #d7dbe3; font: 600 12px var(--sans); cursor: pointer; }
.code button:hover { background: rgba(255, 255, 255, .2); }
.code.has-copy pre { padding-right: 84px; }
@media (max-width: 640px) { .code.has-copy pre { padding-right: 22px; padding-top: 44px; } }
.code .tag { position: absolute; top: 12px; right: 14px; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: rgba(255, 255, 255, .12); color: #d7dbe3; }

/* callouts */
.callout { display: flex; gap: 14px; align-items: flex-start; margin: 20px 0; padding: 18px 20px; border-radius: 16px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule); }
.callout svg { flex: 0 0 20px; margin-top: 4px; }
.callout p { margin: 0; font-size: 16px; color: var(--muted); }
.callout p + p { margin-top: 8px; }
.callout b { color: var(--ink); font-weight: 620; }
.callout.ok svg { color: var(--add-ink); }
.callout.warn svg { color: var(--del-ink); }

/* tables: rows become cards on narrow screens */
.table { margin: 16px 0 22px; border-radius: 16px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule); overflow: hidden; }
table { width: 100%; border-collapse: collapse; font-size: 15.5px; line-height: 1.5; }
th { text-align: left; font-size: 13px; font-weight: 600; color: var(--muted); padding: 12px 16px; border-bottom: 1px solid var(--rule); }
td { padding: 12px 16px; border-top: 1px solid var(--rule); vertical-align: top; overflow-wrap: anywhere; }
tr:first-child td { border-top: 0; }
td:first-child { font-weight: 600; }
td .muted { font-size: 14.5px; }
@media (max-width: 640px) {
  table, tbody, tr, td { display: block; }
  thead { display: none; }
  tr { padding: 12px 16px; border-top: 1px solid var(--rule); }
  tr:first-child { border-top: 0; }
  td { padding: 3px 0; border: 0; }
  td[data-label]::before { content: attr(data-label); display: block; font-size: 12.5px; font-weight: 600; color: var(--muted); }
  td:first-child { font-size: 16.5px; }
}

.files { list-style: none; padding: 0; display: grid; gap: 10px; }
.files li { margin: 0; padding: 14px 18px; border-radius: 14px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule); display: grid; gap: 2px; }
.files a { font-family: var(--mono); font-stretch: 75%; font-size: 14.5px; font-weight: 500; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.files span { color: var(--muted); font-size: 15.5px; }

footer { padding-block: 28px 48px; border-top: 1px solid var(--rule); color: var(--faint); font-size: 14px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; }
footer .links { display: flex; flex-wrap: wrap; gap: 8px 22px; }
footer a { color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--ink); }

/* legal pages */
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font-size: 15px; color: var(--muted); }
.pill { display: inline-flex; align-items: center; padding: 2px 10px; border-radius: 999px; font-size: 13px; font-weight: 600; background: var(--del-bg); color: var(--del-ink); }
.summary { list-style: none; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.summary li { margin: 0; padding: 16px 18px; border-radius: 14px; background: var(--surface); box-shadow: 0 0 0 1px var(--rule); display: grid; gap: 4px; align-content: start; }
.summary b { font-weight: 620; line-height: 1.35; }
.summary span { color: var(--muted); font-size: 15.5px; line-height: 1.5; }
@media (max-width: 640px) { .summary { grid-template-columns: 1fr; } }
.items { display: grid; gap: 0; margin: 8px 0 18px; }
.items > div { padding: 18px 0; border-top: 1px solid var(--rule); display: grid; grid-template-columns: 11em minmax(0, 1fr); gap: 6px 28px; }
.items > div:first-child { border-top: 0; padding-top: 6px; }
.items h3 { margin: 0; font-size: 17px; line-height: 1.45; }
.items p { margin: 0; }
.items p + p { margin-top: 8px; }
.items .why { color: var(--muted); font-size: 15.5px; }
@media (max-width: 640px) { .items > div { grid-template-columns: 1fr; } }
