:root {
  --bg: #f5f4f1;          /* warm off-white page */
  --surface: #ffffff;     /* cards */
  --surface-2: #f2f1ed;   /* inset / nested */
  --ink: #1c1c1e;         /* soft black — primary text */
  --ink-2: #3a3a3e;
  --muted: #77767b;       /* grey text */
  --line: #e6e4df;        /* hairline borders */
  --brand: #ef5b25;       /* orange */
  --brand-strong: #d94c17;
  --brand-tint: #fef1ea;  /* soft orange wash */
  --ok: #1c8a53;
  --ok-tint: #e8f5ee;
  --err: #c53a2b;
  --err-tint: #fcecea;
  --radius: 0;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
::selection { background: var(--brand-tint); }
.hidden { display: none !important; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: var(--surface-2);
  border: 1px solid var(--line);
  padding: 1px 6px;
  border-radius: 0;
  font-size: .85em;
}

/* --- top bar --- */
.topbar {
  display: flex;
  align-items: center;
  gap: 14px 22px;
  flex-wrap: wrap;
  padding: 13px 24px;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -.01em;
  color: var(--ink);
  text-decoration: none;
}
.brand-mark {
  width: 11px; height: 22px;
  background: url("/wslogo.png?v=1") center / contain no-repeat;
}
.brand-sub { color: var(--muted); font-size: 13px; font-weight: 400; }

/* signed-in cluster — two columns (text + Log out), pushed to the far right */
.signed-in { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.signed-in-text { color: var(--muted); font-size: 13px; font-weight: 400; }
#co-email { color: var(--ink-2); }
#co-company:not(:empty)::before { content: " · "; }
.linklike {
  background: none; border: 0; padding: 0; margin: 0;
  color: var(--muted); font-size: 13px; font-weight: 400; cursor: pointer;
}
.linklike:hover { color: var(--brand); background: none; text-decoration: underline; }
.linklike:active { color: var(--brand-strong); }

/* directory nav — orange text links, no button chrome */
.topnav { display: flex; align-items: center; gap: 22px; }
.navlink {
  position: relative;
  background: none; border: 0; padding: 2px 0 6px; margin: 0; cursor: pointer;
  color: var(--brand); font-size: 16px; font-weight: 500; letter-spacing: -.01em;
  transition: color .12s;
}
.navlink:hover { color: var(--brand-strong); background: none; }
.navlink:active { color: var(--brand-strong); }
.navlink.active { color: var(--brand-strong); }
/* a quiet underline marks the selected page */
.navlink.active::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0; height: 2px;
  background: var(--brand-strong);
}
.navlink:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }

/* --- mobile nav (hamburger + drawer) --- */
/* The drawer is display:contents on desktop, so topnav + signed-in lay out as
   normal topbar children. On mobile it becomes a dropdown panel. */
.nav-drawer { display: contents; }
.nav-toggle {
  display: none; align-items: center; justify-content: center;
  background: none; border: 1px solid var(--line); color: var(--ink);
  padding: 9px 11px; cursor: pointer;
}
.nav-toggle:hover { background: var(--surface-2); }
.nav-toggle:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
  display: block; width: 18px; height: 2px; background: currentColor;
}
.nav-toggle-bars { position: relative; }
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }

@media (max-width: 760px) {
  .topbar { flex-wrap: nowrap; }
  .brand-sub { display: none; }
  .nav-toggle { display: inline-flex; margin-left: auto; }
  .nav-drawer {
    display: none; position: absolute; top: 100%; left: 0; right: 0; z-index: 20;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface); border-bottom: 1px solid var(--line);
    box-shadow: 0 16px 30px rgba(20, 20, 20, .1); padding: 6px 0;
  }
  .topbar.nav-open .nav-drawer { display: flex; }
  .topnav { flex-direction: column; align-items: stretch; gap: 0; }
  .navlink { padding: 13px 22px; font-size: 16px; }
  .navlink.active { background: var(--brand-tint); }
  .navlink.active::after { display: none; }
  .signed-in {
    margin-left: 0; padding: 13px 22px; gap: 10px;
    justify-content: space-between; border-top: 1px solid var(--line);
  }
  .signed-in .linklike { flex: none; white-space: nowrap; }
}

/* --- layout --- */
#app { width: 100%; max-width: 680px; margin: 0 auto; padding: 32px 20px 48px; flex: 1; }
#app.docs-wide { max-width: 1120px; } /* Docs uses a wide sidebar + content layout */

.card, .panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.card { padding: 32px; border-radius: 0; border: 1px solid var(--line); box-shadow: none; }
.panel { padding: 22px 24px; margin-bottom: 16px; border: 1px solid var(--line); }
.auth-card { max-width: 420px; margin: 6vh auto 0; }

/* --- landing (signed-out home) --- */
#app.landing-wide { max-width: 1040px; }
.landing { padding-top: 6px; }
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 408px);
  gap: 44px 52px;
  align-items: start;
  padding: 18px 0 8px;
}
.hero-copy { min-width: 0; }
.hero-eyebrow {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.hero-title {
  margin: 0;
  font-size: 38px;
  line-height: 1.12;
  font-weight: 700;
  letter-spacing: -.025em;
  max-width: 15ch;
}
.hero-lead {
  margin: 18px 0 0;
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.6;
  max-width: 56ch;
}
.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 13px;
}
.hero-meta li { position: relative; padding-left: 14px; }
.hero-meta li::before {
  content: "";
  position: absolute; left: 0; top: .5em;
  width: 5px; height: 5px;
  background: var(--brand);
}
.hero-versions { margin: 26px 0 0; }
.hero-versions-label {
  display: block;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.hero-versions-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.hero-versions-list li {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 5px 10px;
  background: var(--surface);
  border: 1px solid var(--line);
  font-size: 12px;
}
.ver-name { color: var(--ink-2); font-weight: 600; }
.ver-tag {
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
}
/* In the hero, the auth card fills its column rather than centering on the page. */
.hero .auth-card { margin: 0; max-width: none; width: 100%; }

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;                 /* the line-coloured gap reads as hairline dividers */
  background: var(--line);
  border: 1px solid var(--line);
  margin-top: 46px;
}
.feature { background: var(--surface); padding: 26px 28px; }
.feature-kicker {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.feature h2 { margin: 0 0 9px; font-size: 18px; font-weight: 700; letter-spacing: -.01em; color: var(--ink); }
.feature p { margin: 0; color: var(--ink-2); font-size: 14.5px; line-height: 1.58; }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; gap: 34px; }
  .hero .auth-card { max-width: 420px; }
  .hero-title { font-size: 32px; max-width: 20ch; }
}
@media (max-width: 560px) {
  .feature-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 28px; }
}

/* --- type --- */
h1 { margin: 0; font-size: 24px; font-weight: 700; letter-spacing: -.02em; }
h2 { margin: 0 0 12px; font-size: 15px; font-weight: 600; color: var(--ink); }
.sub { margin: 6px 0 0; color: var(--muted); font-size: 14px; }
.muted { color: var(--muted); font-size: 14px; }

/* --- tabs (segmented control) --- */
.tabs { display: flex; gap: 6px; margin: 20px 0 18px; background: var(--surface-2); padding: 5px; border-radius: 0; }
.tab { flex: 1; background: transparent; color: var(--muted); border: 0; padding: 9px; border-radius: 0; cursor: pointer; font-size: 14px; font-weight: 600; transition: .15s; }
.tab:hover { color: var(--ink); }
.tab.active { background: var(--brand); color: #fff; }

/* --- forms --- */
form { display: flex; flex-direction: column; gap: 14px; }
label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
input {
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--ink);
  padding: 12px 13px;
  border-radius: 0;
  font-size: 15px;
  transition: border-color .15s, box-shadow .15s;
}
input::placeholder { color: #a9a8ac; }
input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint); }

/* signup consent checkboxes */
.agree-rows { display: flex; flex-direction: column; gap: 9px; margin: 2px 0; }
.agree-row { flex-direction: row; align-items: flex-start; gap: 9px; font-size: 13px; font-weight: 400; color: var(--ink-2); cursor: pointer; }
.agree-row input { flex: none; width: 16px; height: 16px; margin-top: 1px; padding: 0; accent-color: var(--brand); cursor: pointer; }
.agree-row a { color: var(--brand); }

/* --- buttons --- */
button {
  font-family: inherit;
  background: var(--brand);
  color: #fff;
  border: 0;
  padding: 11px 16px;
  border-radius: 0;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: background .15s, transform .05s, border-color .15s;
}
button:hover { background: var(--brand-strong); }
button:active { transform: translateY(1px); }
button:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
#auth-submit { margin-top: 2px; padding: 12px; }
button.ghost { background: var(--surface); border: 1px solid var(--line); color: var(--ink); }
button.ghost:hover { background: var(--surface-2); border-color: #d8d6d0; }
button.small { padding: 8px 12px; font-size: 13px; }

.error { color: var(--err); min-height: 18px; font-size: 13px; margin: 12px 0 0; }

/* --- verify banner --- */
.banner {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  background: var(--brand-tint); border: 1px solid #f6d3c1; color: #8a3c17;
  padding: 14px 16px; border-radius: 0; margin-bottom: 16px; font-size: 14px;
}
.banner-icon { font-size: 16px; }
.banner-body { flex: 1; min-width: 180px; }
.banner strong { color: #7a3413; }

/* --- license list --- */
.list { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-direction: column; gap: 10px; }
.list li {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  padding: 14px; background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 0; font-size: 13px;
}
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
#change-plan-picker { margin-top: 14px; }
button:disabled { opacity: .5; cursor: default; }
button.ghost:disabled:hover { background: var(--surface); border-color: var(--line); }

.badge {
  display: inline-block; padding: 3px 9px; border-radius: 0;
  font-size: 11px; font-weight: 600; text-transform: capitalize;
  background: var(--surface); border: 1px solid var(--line); color: var(--muted);
}
.badge.active { background: var(--ok-tint); border-color: #bfe3cd; color: var(--ok); }
.badge.revoked { background: var(--err-tint); border-color: #f2c5bf; color: var(--err); }

.key { font-family: ui-monospace, Menlo, monospace; word-break: break-all; }
.key.copyable { cursor: pointer; padding: 4px 8px; border-radius: 0; background: var(--surface); border: 1px solid var(--line); transition: border-color .15s; }
.key.copyable:hover { border-color: var(--brand); }
.key.copied { color: var(--ok); border-color: var(--ok); }
.icon-btn { background: transparent; border: 0; cursor: pointer; font-size: 15px; padding: 2px 4px; line-height: 1; color: var(--muted); }
.icon-btn:hover { color: var(--ink); background: transparent; }
.key-actions { display: inline-flex; gap: 6px; margin-left: auto; }
.key-actions button { padding: 5px 10px; font-size: 12px; }

/* --- plans / pricing --- */
#plan-picker { margin-top: 14px; }
.plans { display: flex; gap: 12px; flex-wrap: wrap; }
.plans-col { flex-direction: column; flex-wrap: nowrap; }
.plan {
  flex: 1; min-width: 160px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 0; padding: 18px;
  transition: border-color .15s, box-shadow .15s;
}
.plan:hover { border-color: var(--brand); }
.plan h3 { margin: 0 0 2px; font-size: 16px; font-weight: 700; }
.plan .plan-desc { margin: 2px 0 10px; font-size: 13px; color: var(--muted); line-height: 1.45; }
.plan .price { font-size: 22px; font-weight: 700; color: var(--ink); margin: 4px 0 14px; }
.plan button { width: 100%; }

/* --- onboarding steps --- */
.steps { margin: 8px 0 12px; padding-left: 0; list-style: none; counter-reset: step; }
.steps li { position: relative; padding: 7px 0 7px 34px; counter-increment: step; font-size: 14px; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: 6px;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--brand-tint); color: var(--brand);
  font-size: 12px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

/* --- Stripe checkout modal --- */
.modal { position: fixed; inset: 0; background: rgba(20,18,16,.55); display: flex; align-items: flex-start; justify-content: center; padding: 5vh 16px; overflow: auto; z-index: 50; }
.modal-card { background: var(--surface); border: 1px solid var(--line); border-radius: 0; padding: 20px; width: 100%; max-width: 540px; box-shadow: 0 24px 60px rgba(0,0,0,.28); }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.modal.center { align-items: center; padding: 16px; }
.modal-card.confirm { max-width: 400px; padding: 24px; }
.modal-card.confirm h3 { margin: 0 0 8px; font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.modal-card.confirm .muted { margin: 0; font-size: 14px; line-height: 1.5; }
.confirm-actions { justify-content: flex-end; margin-top: 20px; }
.confirm-input-row { margin-top: 16px; }
button.danger { background: var(--err); }
button.danger:hover { background: #a72e21; }

/* account / auth extras */
a.linkish { color: var(--brand); text-decoration: none; }
a.linkish:hover { color: var(--brand-strong); text-decoration: underline; }
.forgot { margin: 12px 0 0; }
.mfa-secret { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.mfa-secret .key { letter-spacing: .04em; }

/* games */
.game-name { font-size: 15px; font-weight: 600; color: var(--ink); }
/* over-plan-limit titles: greyed + struck, still listed and removable */
.game-inactive { background: var(--surface-2); }
.game-inactive .game-name { color: var(--muted); font-weight: 500; text-decoration: line-through; }
.game-add { display: flex; gap: 8px; margin-top: 12px; }
.game-add input { flex: 1; }
.warn-text {
  background: #fdf4e7; border: 1px solid #f0d8b4; color: #8a5a12;
  padding: 10px 12px; border-radius: 0; font-size: 13px; line-height: 1.45; margin: 0 0 14px;
}
@media (prefers-reduced-motion: no-preference) {
  .modal-card.confirm { animation: pop .14s ease-out; }
  @keyframes pop { from { opacity: 0; transform: translateY(6px) scale(.98); } to { opacity: 1; transform: none; } }
}

/* --- footer --- */
.footer { display: flex; gap: 8px; justify-content: center; align-items: center; flex-wrap: wrap; text-align: center; color: var(--muted); font-size: 12px; padding: 20px; border-top: 1px solid var(--line); }
.dot-sep { opacity: .5; }
.footer-brand { color: var(--ink-2); font-weight: 600; letter-spacing: .02em; }
.footer a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.footer a:hover { color: var(--ink); }

@media (max-width: 520px) {
  .card { padding: 24px; }
  #app { padding: 22px 14px 36px; }
  .plans { flex-direction: column; }
  .topbar { padding: 14px 16px; }
}

/* One-time purchases (support packages) list. */
.purchase-list { display: flex; flex-direction: column; gap: 8px; }
.purchase-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 10px 12px; border: 1px solid var(--line, #e6e4df); border-radius: 0; }
.purchase-name { font-weight: 600; }
.purchase-meta { color: var(--muted, #77767b); font-size: 13px; white-space: nowrap; }

/* Downloads tab (self-host release tarballs). */
.downloads-list { display: flex; flex-direction: column; gap: 14px; }
.dl-card { border: 1px solid var(--line); background: var(--surface); padding: 16px 18px; }
.dl-head { display: flex; align-items: baseline; gap: 10px; }
.dl-head h3 { margin: 0; font-size: 16px; }
.dl-version { font-size: 12px; font-weight: 600; letter-spacing: .02em; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); padding: 2px 8px; }
.dl-blurb { margin: 6px 0 12px; font-size: 13px; }
.dl-artifacts { display: flex; flex-direction: column; gap: 8px; }
.dl-artifact { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.dl-btn { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; background: var(--brand); color: #fff; border: 1px solid var(--brand-strong); padding: 7px 12px; font-size: 13px; font-weight: 600; transition: background .15s; }
.dl-btn:hover { background: var(--brand-strong); }
.dl-plat { font-weight: 500; opacity: .9; font-size: 12px; }
.dl-meta { color: var(--muted); font-size: 13px; }
.dl-sha { font-size: 12px; color: var(--muted); cursor: pointer; padding: 3px 7px; background: var(--surface-2); border: 1px solid var(--line); transition: border-color .15s; }
.dl-sha:hover { border-color: var(--brand); }
.dl-archive { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 10px; }
.dl-archive summary { cursor: pointer; color: var(--muted); font-size: 13px; font-weight: 600; }
.dl-archive-ver { margin: 12px 0 0; }
.dl-archive-tag { display: inline-block; font-size: 12px; font-weight: 700; color: var(--ink-2); margin-bottom: 6px; }

/* Docs tab. */
.doc-view .panel { line-height: 1.55; }
.doc-view h2 { margin: 2px 0 10px; }
.doc-view p { margin: 0 0 10px; color: var(--ink-2); }
.doc-lead { font-size: 15px; color: var(--ink) !important; }
.doc-tag {
  display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .06em;
  text-transform: uppercase; color: var(--brand-strong); background: var(--brand-tint);
  padding: 3px 9px; border-radius: 0; margin-bottom: 4px;
}
.doc-list { margin: 6px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; }
.doc-list li { color: var(--ink-2); }
.doc-option { border-left: 3px solid var(--line); padding: 2px 0 2px 14px; margin: 14px 0 0; }
.doc-option h3 { margin: 0 0 4px; font-size: 15px; }
.doc-option p { margin: 0; }
.doc-view code {
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 0;
  padding: 1px 6px; font-size: 13px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* ============ Docs: header dropdown + directory + article ============ */
.docs-page { max-width: 1120px; margin: 0 auto; padding: 4px 0 56px; }

/* Documentation: persistent left sidebar + content pane (docs-site layout). */
.docs-layout { display: flex; align-items: flex-start; gap: 44px; }
.docs-sidebar { flex: 0 0 236px; position: sticky; top: 74px; align-self: flex-start; }
.docs-sidebar-head h2 { margin: 0 0 4px; font-size: 21px; font-weight: 700; letter-spacing: -.01em; }
.docs-sidebar-head p { margin: 0 0 18px; color: var(--muted); font-size: 13px; line-height: 1.45; }
.docs-nav { display: flex; flex-direction: column; }
.docs-nav-group { display: flex; flex-direction: column; margin-bottom: 15px; }
.docs-nav-head { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 4px 0 6px; }
.docs-nav-item { text-align: left; background: none; border: 0; border-left: 2px solid var(--line); color: var(--ink-2); font: inherit; font-size: 13.5px; line-height: 1.35; padding: 7px 0 7px 14px; cursor: pointer; transition: color .12s, border-color .12s; }
.docs-nav-item:hover { color: var(--brand-strong); background: none; }
.docs-nav-item.active { color: var(--brand-strong); font-weight: 600; border-left-color: var(--brand); }
.docs-nav-toggle { display: none; }
.docs-content { flex: 1 1 auto; min-width: 0; max-width: 760px; line-height: 1.6; }
.docs-article h2 { margin: 8px 0 14px; }
.docs-article h3 { margin: 22px 0 6px; font-size: 16px; }
.docs-article p { margin: 0 0 12px; color: var(--ink-2); }
.docs-tag { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.docs-list { margin: 6px 0 12px; padding-left: 18px; display: flex; flex-direction: column; gap: 7px; color: var(--ink-2); }
.docs-code { background: var(--surface-2); border: 1px solid var(--line); padding: 12px 14px; overflow-x: auto; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; line-height: 1.5; white-space: pre; margin: 0 0 14px; }
.docs-note { background: var(--surface-2); border-left: 2px solid var(--brand); padding: 10px 14px; font-size: 13px; color: var(--ink-2); margin: 0 0 14px; }
.docs-article code, .docs-list code, .docs-note code { background: var(--surface-2); border: 1px solid var(--line); padding: 1px 5px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; }

/* Docs: API reference tables */
.docs-table { width: 100%; border-collapse: collapse; margin: 0 0 14px; font-size: 13px; }
.docs-table td { border: 1px solid var(--line); padding: 8px 10px; vertical-align: top; color: var(--ink-2); line-height: 1.55; }
.docs-table td:first-child { color: var(--ink); white-space: nowrap; }
.docs-table td:last-child { white-space: normal; }
.docs-table code { background: var(--surface-2); border: 1px solid var(--line); padding: 1px 5px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; }

/* Docs: API reference — endpoint blocks, method lists, parameter tables */
.docs-article h4 { margin: 16px 0 6px; font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.api-kind { color: var(--muted); font-size: 12.5px; margin: -2px 0 10px; }
.api-kind-inline { font-size: 12.5px; font-weight: 400; color: var(--muted); text-transform: none; letter-spacing: 0; }
.api-endpoint { border: 1px solid var(--line); border-left: 3px solid var(--brand); margin: 0 0 12px; }
.api-endpoint-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 9px 12px; background: var(--surface-2); }
.api-endpoint-desc { margin: 0; padding: 9px 12px; font-size: 13px; color: var(--ink-2); border-top: 1px solid var(--line); }
.api-method { display: inline-block; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 10.5px; font-weight: 700; letter-spacing: .04em; color: #fff; padding: 3px 8px; border: 0; }
.api-get { background: #1f6fd0; }
.api-post { background: #1c8a53; }
.api-put { background: #b4690e; }
.api-patch { background: #7a52c7; }
.api-delete { background: #c53a2b; }
.api-path { background: none; border: 0; padding: 0; font-size: 13.5px; color: var(--ink); }
.api-call { display: inline-block; margin-top: 5px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; color: var(--muted); }
.api-call .api-method { font-size: 9.5px; padding: 1px 5px; margin-right: 5px; vertical-align: middle; }
.api-methods { width: 100%; border-collapse: collapse; margin: 0 0 14px; font-size: 13px; }
.api-methods td { border-bottom: 1px solid var(--line); padding: 8px 10px; vertical-align: top; color: var(--ink-2); line-height: 1.5; }
.api-methods td:first-child { width: 40%; }
.api-methods td:first-child code { background: var(--surface-2); border: 1px solid var(--line); padding: 2px 6px; font-size: 12px; color: var(--ink); }
.api-params { width: 100%; border-collapse: collapse; margin: 0 0 14px; font-size: 12.5px; }
.api-params th { text-align: left; font-size: 10px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); font-weight: 700; padding: 6px 10px; border-bottom: 2px solid var(--line); }
.api-params td { border-bottom: 1px solid var(--line); padding: 7px 10px; vertical-align: top; color: var(--ink-2); line-height: 1.5; }
.api-params td:first-child { white-space: nowrap; color: var(--ink); }
.api-params td:first-child code { background: var(--surface-2); border: 1px solid var(--line); padding: 1px 5px; font-size: 11.5px; }
.api-type { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11.5px; color: var(--brand-strong); white-space: nowrap; }
.api-req { font-size: 9.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--brand-strong); white-space: nowrap; }
.api-opt { font-size: 9.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); white-space: nowrap; }
.api-scroll { overflow-x: auto; margin: 0 0 14px; }
.api-scroll > table { margin: 0; }

/* GSA-style reference tables: outer border, tinted header row, zebra striping. */
.api-params, .api-methods { border: 1px solid var(--line); }
.api-params th { background: var(--surface-2); border-bottom: 1px solid var(--line); }
.api-params tbody tr:nth-child(even) td, .api-methods tr:nth-child(even) td { background: rgba(20, 20, 20, .022); }
.api-params tbody tr:last-child td, .api-methods tr:last-child td { border-bottom: 0; }

/* Docs: stack the sidebar above the content on narrow screens. */
@media (max-width: 820px) {
  #app.docs-wide { max-width: 680px; }
  .docs-layout { flex-direction: column; gap: 14px; }
  .docs-sidebar { position: static; flex: none; width: 100%; }
  .docs-sidebar-head { margin-bottom: 4px; }
  .docs-sidebar-head p { margin-bottom: 12px; }
  .docs-nav-toggle {
    display: flex; align-items: center; justify-content: space-between; width: 100%;
    text-align: left; background: var(--surface); border: 1px solid var(--line);
    color: var(--ink); font: inherit; font-size: 14px; font-weight: 600; padding: 11px 14px; cursor: pointer;
  }
  .docs-nav-toggle::after { content: ""; width: 7px; height: 7px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); margin-left: 10px; }
  .docs-nav { display: none; border: 1px solid var(--line); border-top: 0; padding: 4px 0; }
  .docs-nav.open { display: flex; }
  .docs-nav-group { margin: 0; padding: 4px 14px; }
  .docs-content { max-width: none; }
}

/* One-time purchase fulfillment status */
.purchase-status { font-weight: 700; }
.purchase-status.done { color: #3a9d5d; }
