/* Toby AI Knowledge Base — shared styles.
   Brand: Toby blue #0045B0, accent orange #EE8A3C, Figtree. */

:root {
  --brand: #0045B0;
  --brand-2: #3E72C7;
  --brand-deep: #002a6b;
  --brand-text: #0045B0;
  --accent: #EE8A3C;
  --accent-soft: #fdf0e4;
  --ok: #1a8a52;
  --ok-soft: #e6f5ec;
  --warn: #b25e09;
  --warn-soft: #fff3e2;
  --danger: #c0392b;
  --danger-soft: #fdecea;
  --bg: #FAFAFC;
  --surface: #FFFFFF;
  --surface-2: #F3F5FA;
  --soft: #EAF0FB;
  --ink: #14141C;
  --muted: #5C6070;
  --faint: #8A8FA0;
  --line: #E4E7EF;
  --code-bg: #0f1a2e;
  --code-ink: #e6ecf8;
  --shadow: 0 1px 2px rgba(20, 20, 28, .04), 0 8px 24px rgba(20, 20, 28, .05);
  --font: "Figtree", "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --nav-h: 64px;
  --side-w: 272px;
  --toc-w: 224px;
  --r: 12px;
  --r-lg: 18px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #3E72C7;
    --brand-2: #6F9BE6;
    --brand-deep: #0a1f45;
    --brand-text: #8DB2F0;
    --accent-soft: rgba(238, 138, 60, .14);
    --ok: #42D08A;
    --ok-soft: rgba(66, 208, 138, .12);
    --warn: #f2a65a;
    --warn-soft: rgba(242, 166, 90, .12);
    --danger: #f1786b;
    --danger-soft: rgba(241, 120, 107, .12);
    --bg: #0B0D14;
    --surface: #121521;
    --surface-2: #171B29;
    --soft: rgba(62, 114, 199, .16);
    --ink: #F2F3F7;
    --muted: #A3A8B8;
    --faint: #7A7F91;
    --line: #262B3B;
    --code-bg: #070a12;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --brand: #3E72C7;
  --brand-2: #6F9BE6;
  --brand-deep: #0a1f45;
  --brand-text: #8DB2F0;
  --accent-soft: rgba(238, 138, 60, .14);
  --ok: #42D08A;
  --ok-soft: rgba(66, 208, 138, .12);
  --warn: #f2a65a;
  --warn-soft: rgba(242, 166, 90, .12);
  --danger: #f1786b;
  --danger-soft: rgba(241, 120, 107, .12);
  --bg: #0B0D14;
  --surface: #121521;
  --surface-2: #171B29;
  --soft: rgba(62, 114, 199, .16);
  --ink: #F2F3F7;
  --muted: #A3A8B8;
  --faint: #7A7F91;
  --line: #262B3B;
  --code-bg: #070a12;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: calc(var(--nav-h) + 20px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.65 var(--font);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand-text); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
img, svg { max-width: 100%; }
code, kbd {
  font-family: var(--mono);
  font-size: .86em;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: .08em .38em;
}
:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 2px; border-radius: 6px; }
.skip-link {
  position: absolute; left: 12px; top: -48px; z-index: 100;
  background: var(--brand); color: #fff; padding: 8px 14px; border-radius: 8px;
}
.skip-link:focus { top: 10px; }

/* ---------- Navbar ---------- */
.navbar {
  position: sticky; top: 0; z-index: 40;
  height: var(--nav-h);
  display: flex; align-items: center; gap: 14px;
  padding: 0 20px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 800; letter-spacing: -.02em; }
.brand:hover { text-decoration: none; }
.brand svg { width: 30px; height: 28px; }
.brand-name { font-size: 20px; }
.brand-divider { width: 1px; height: 22px; background: var(--line); margin: 0 4px; }
.brand-docs { font-weight: 600; color: var(--muted); font-size: 15px; }
.nav-spacer { flex: 1; }
.nav-search {
  display: flex; align-items: center; gap: 8px;
  width: min(320px, 34vw); height: 38px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface-2); color: var(--faint);
  font: inherit; font-size: 14px; cursor: pointer; text-align: left;
}
.nav-search:hover { border-color: var(--brand-2); }
.nav-search svg { width: 16px; height: 16px; flex: none; }
.nav-search span { flex: 1; }
.nav-search kbd { font-size: 11px; padding: 1px 6px; }
.icon-btn {
  width: 38px; height: 38px; display: inline-grid; place-items: center;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--muted); cursor: pointer;
}
.icon-btn:hover { color: var(--ink); border-color: var(--brand-2); }
.icon-btn svg { width: 18px; height: 18px; }
.menu-btn { display: none; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 18px; border-radius: 999px;
  font-weight: 700; font-size: 14px; white-space: nowrap;
  border: 1px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-deep); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.btn-ghost:hover { background: rgba(255, 255, 255, .1); }
.btn-light { background: #fff; color: var(--brand); }
.btn-light:hover { background: #eef3fc; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

/* ---------- Layout ---------- */
.layout { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); min-height: calc(100vh - var(--nav-h)); }
.sidebar-container {
  position: sticky; top: var(--nav-h);
  height: calc(100vh - var(--nav-h)); overflow-y: auto;
  padding: 22px 14px 40px;
  border-right: 1px solid var(--line);
  background: var(--surface);
}
.content { display: grid; grid-template-columns: minmax(0, 1fr) var(--toc-w); gap: 40px; padding: 36px 40px 80px; max-width: 1180px; width: 100%; }
.content.no-toc { grid-template-columns: minmax(0, 1fr); }
.doc-col { min-width: 0; max-width: 780px; }
.doc-content { min-width: 0; }

/* ---------- Sidebar ---------- */
.nav-group { margin-bottom: 18px; }
.nav-group-title {
  margin: 0 10px 6px; font-size: 11px; font-weight: 800; letter-spacing: .09em;
  text-transform: uppercase; color: var(--faint);
}
.nav-list { list-style: none; margin: 0; padding: 0; }
.nav-link {
  display: flex; align-items: center; gap: 10px;
  padding: 7px 10px; border-radius: 9px;
  color: var(--muted); font-size: 14.5px; font-weight: 600;
}
.nav-link:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.nav-link svg { width: 16px; height: 16px; flex: none; opacity: .85; }
.nav-link[aria-current="page"] { background: var(--soft); color: var(--brand-text); }
.nav-sub { margin: 2px 0 4px; }
.nav-sub > summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; gap: 10px;
  padding: 7px 10px; border-radius: 9px;
  color: var(--ink); font-size: 14.5px; font-weight: 700;
}
.nav-sub > summary::-webkit-details-marker { display: none; }
.nav-sub > summary:hover { background: var(--surface-2); }
.nav-sub > summary svg { width: 16px; height: 16px; flex: none; }
.nav-sub > summary .chev { margin-left: auto; width: 14px; height: 14px; transition: transform .15s; opacity: .6; }
.nav-sub[open] > summary .chev { transform: rotate(90deg); }
.nav-sub .nav-list { margin-left: 18px; padding-left: 10px; border-left: 1px solid var(--line); }
.nav-sub .nav-link { font-weight: 500; padding: 5px 10px; }

/* ---------- Table of contents ---------- */
.toc { position: sticky; top: calc(var(--nav-h) + 36px); align-self: start; max-height: calc(100vh - var(--nav-h) - 60px); overflow-y: auto; font-size: 13.5px; }
.toc-title { font-size: 11px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--faint); margin: 0 0 10px; }
.toc ul { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.toc a { display: block; padding: 4px 0 4px 14px; margin-left: -1px; color: var(--muted); border-left: 2px solid transparent; }
.toc a:hover { color: var(--ink); text-decoration: none; }
.toc a.active { color: var(--brand-text); border-left-color: var(--brand); font-weight: 600; }

/* ---------- Typography ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  color: var(--brand-text); margin: 0 0 10px;
}
.doc-content h1 { font-size: clamp(30px, 4vw, 42px); line-height: 1.12; letter-spacing: -.03em; margin: 0 0 14px; font-weight: 800; }
.doc-content h2 { font-size: 25px; line-height: 1.25; letter-spacing: -.02em; margin: 48px 0 12px; font-weight: 800; }
.doc-content h3 { font-size: 18.5px; line-height: 1.35; margin: 28px 0 8px; font-weight: 700; }
.doc-content p, .doc-content li { color: var(--ink); }
.doc-content p { margin: 0 0 14px; }
.doc-content ul, .doc-content ol { padding-left: 22px; margin: 0 0 16px; }
.doc-content li { margin: 4px 0; }
.lead { font-size: 18.5px; color: var(--muted) !important; line-height: 1.6; margin-bottom: 22px !important; }
.muted { color: var(--muted) !important; }
.small { font-size: 14px; }
.meta-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 26px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12.5px; font-weight: 700; padding: 4px 10px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--muted);
}
.chip svg { width: 13px; height: 13px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 36px 0; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  margin: 0 0 40px; padding: 44px 40px 40px;
  border-radius: var(--r-lg);
  background:
    radial-gradient(600px 300px at 90% -10%, rgba(111, 155, 230, .55), transparent 60%),
    radial-gradient(500px 260px at -10% 120%, rgba(238, 138, 60, .28), transparent 60%),
    linear-gradient(135deg, #0045B0 0%, #00337f 60%, #002a6b 100%);
  color: #fff;
  border-bottom: 5px solid var(--accent);
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 32px; align-items: center;
}
.hero .eyebrow { color: #ffd2ad; }
.hero h1 { color: #fff; font-size: clamp(32px, 4.4vw, 48px); margin-bottom: 14px; }
.hero h1 .hl { position: relative; white-space: nowrap; }
.hero h1 .hl::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 6px;
  border-radius: 6px; background: var(--accent);
}
.hero p { color: rgba(255, 255, 255, .86) !important; font-size: 17px; }
.hero .chat p, .hero .chat .msg-text { color: var(--ink) !important; font-size: 14px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.hero-steps { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 20px; font-size: 13px; font-weight: 700; }
.hero-steps span { padding: 4px 10px; border-radius: 999px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .2); }

/* ---------- Chat mock ---------- */
.chat {
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow); overflow: hidden; font-size: 14px;
}
.hero .chat { box-shadow: 0 20px 50px rgba(0, 0, 0, .3); border: 0; }
.chat-head {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; border-bottom: 1px solid var(--line);
  font-weight: 800; font-size: 13px; background: var(--surface-2);
}
.chat-head .where { margin-left: auto; color: var(--faint); font-weight: 600; }
.chat-body { padding: 12px 14px; display: grid; gap: 12px; }
.msg { display: grid; grid-template-columns: 30px 1fr; gap: 10px; }
.avatar { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: var(--surface-2); color: var(--muted); }
.avatar.toby { background: var(--brand); color: #fff; }
.avatar.toby svg { width: 20px; height: 18px; }
.msg-name { font-weight: 800; font-size: 13.5px; }
.msg-name .tag { font-size: 10px; font-weight: 800; padding: 1px 5px; border-radius: 4px; background: var(--surface-2); color: var(--faint); margin-left: 4px; vertical-align: 1px; }
.msg-name time { font-weight: 500; color: var(--faint); font-size: 12px; margin-left: 6px; }
.msg-text { margin: 2px 0 0 !important; color: var(--ink); line-height: 1.5; }
.mention { color: var(--brand-text); font-weight: 700; background: var(--soft); border-radius: 4px; padding: 0 3px; }
.approve-box { margin-top: 8px; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--surface-2); }
.approve-box strong { display: block; font-size: 13px; margin-bottom: 8px; }
.approve-actions { display: flex; gap: 8px; }
.approve-actions span { font-size: 12.5px; font-weight: 800; padding: 4px 12px; border-radius: 7px; border: 1px solid var(--line); background: var(--surface); }
.approve-actions .yes { background: var(--ok); border-color: var(--ok); color: #fff; }
.chat-foot { padding: 8px 14px; font-size: 12px; color: var(--faint); border-top: 1px solid var(--line); }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr)); gap: 14px; margin: 18px 0 28px; }
.cards.two { grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); }
.card {
  display: flex; flex-direction: column; gap: 6px;
  padding: 18px; border-radius: var(--r);
  background: var(--surface); border: 1px solid var(--line);
  color: var(--ink); box-shadow: var(--shadow);
  transition: border-color .15s, transform .15s;
}
a.card:hover { text-decoration: none; border-color: var(--brand-2); transform: translateY(-2px); }
.card .card-icon { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--soft); color: var(--brand-text); margin-bottom: 6px; }
.card .card-icon svg { width: 19px; height: 19px; }
.card .card-icon.orange { background: var(--accent-soft); color: var(--accent); }
.card .card-kicker { font-size: 11px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--faint); }
.card h3 { margin: 0 !important; font-size: 17px !important; }
.card p { margin: 0 !important; color: var(--muted) !important; font-size: 14.5px; line-height: 1.55; }
.card .card-link { margin-top: auto; padding-top: 8px; font-weight: 700; font-size: 14px; color: var(--brand-text); }

.connector-tile { flex-direction: row; align-items: center; gap: 12px; padding: 14px 16px; }
.connector-tile .card-body { display: flex; flex-direction: column; min-width: 0; }
.connector-tile strong { font-size: 15.5px; }
.connector-tile span { color: var(--muted); font-size: 13.5px; }
.mono-logo {
  width: 40px; height: 40px; flex: none; border-radius: 10px;
  display: grid; place-items: center; font-weight: 800; font-size: 15px; color: #fff;
  background: var(--logo, var(--brand));
}
.page-title-row { display: flex; align-items: center; gap: 16px; margin-bottom: 6px; }
.page-title-row .mono-logo { width: 54px; height: 54px; font-size: 20px; border-radius: 14px; }
.page-title-row h1 { margin: 0 !important; }

/* ---------- Steps ---------- */
.steps { list-style: none; padding: 0 !important; margin: 20px 0 28px !important; counter-reset: step; }
.steps > li {
  position: relative; counter-increment: step;
  padding: 0 0 22px 58px; margin: 0 !important;
}
.steps > li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute; left: 0; top: -2px;
  width: 40px; height: 40px; border-radius: 12px;
  display: grid; place-items: center;
  font-weight: 800; font-size: 14px;
  background: var(--soft); color: var(--brand-text);
}
.steps > li::after { content: ""; position: absolute; left: 19px; top: 44px; bottom: 4px; width: 2px; background: var(--line); }
.steps > li:last-child::after { display: none; }
.steps h3 { margin: 6px 0 6px !important; font-size: 17.5px !important; }
.steps p:last-child { margin-bottom: 0; }

/* ---------- Admonitions ---------- */
.admonition {
  display: grid; grid-template-columns: 22px 1fr; gap: 12px;
  padding: 14px 16px; margin: 18px 0 22px;
  border-radius: var(--r); border: 1px solid var(--line);
  background: var(--surface-2);
}
.admonition::before {
  content: "•"; width: 22px; height: 22px; margin-top: 1px; border-radius: 50%;
  display: grid; place-items: center; font-size: 12px; font-weight: 900; color: #fff;
  background: var(--muted);
}
.admonition > div { min-width: 0; }
.admonition p { margin: 0 0 6px !important; }
.admonition p:last-child, .admonition ul:last-child { margin-bottom: 0 !important; }
.admonition ul { margin: 4px 0 0 !important; }
.admonition-title { font-weight: 800; }
.admonition-info { background: var(--soft); border-color: color-mix(in srgb, var(--brand-2) 30%, transparent); }
.admonition-info::before { content: "i"; background: var(--brand); font-family: Georgia, serif; font-style: italic; }
.admonition-tip { background: var(--ok-soft); border-color: color-mix(in srgb, var(--ok) 30%, transparent); }
.admonition-tip::before { content: "✓"; background: var(--ok); }
.admonition-warning { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 35%, transparent); }
.admonition-warning::before { content: "!"; background: var(--warn); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; margin: 16px 0 24px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
th, td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); background: var(--surface-2); white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
td strong { font-weight: 700; }
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11.5px; font-weight: 800; padding: 2px 8px; border-radius: 999px; white-space: nowrap;
  border: 1px solid transparent;
}
.badge-read { background: var(--soft); color: var(--brand-text); }
.badge-write { background: var(--accent-soft); color: var(--warn); }
.badge-approve { background: var(--ok-soft); color: var(--ok); }
.badge-schedule { background: var(--surface-2); color: var(--muted); border-color: var(--line); }
.badge-no { background: var(--danger-soft); color: var(--danger); }
.yes { color: var(--ok); font-weight: 800; }
.no { color: var(--faint); }

/* ---------- Lists ---------- */
.check-list, .cross-list { list-style: none; padding: 0 !important; }
.check-list li, .cross-list li { position: relative; padding-left: 28px; }
.check-list li::before, .cross-list li::before {
  position: absolute; left: 0; top: 3px;
  width: 18px; height: 18px; border-radius: 50%;
  display: grid; place-items: center; font-size: 11px; font-weight: 900;
}
.check-list li::before { content: "✓"; background: var(--ok-soft); color: var(--ok); }
.cross-list li::before { content: "✕"; background: var(--danger-soft); color: var(--danger); }

.scope-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 14px; margin: 16px 0 24px; }
.scope-box { border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; background: var(--surface); }
.scope-box h3 { margin: 0 0 10px !important; font-size: 16px !important; display: flex; align-items: center; gap: 8px; }
.scope-box ul { margin: 0 !important; }
.scope-box.can { border-top: 3px solid var(--ok); }
.scope-box.cannot { border-top: 3px solid var(--danger); }

/* ---------- FAQ ---------- */
.faq { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); margin: 10px 0; }
.faq summary {
  cursor: pointer; list-style: none; padding: 14px 18px;
  font-weight: 700; display: flex; justify-content: space-between; gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 20px; line-height: 1; color: var(--faint); }
.faq[open] summary::after { content: "–"; }
.faq > div { padding: 0 18px 14px; color: var(--muted); }
.faq > div p { color: var(--muted); }

/* ---------- Page nav & footer ---------- */
.page-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 56px; }
.page-nav a { display: block; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); }
.page-nav a:hover { border-color: var(--brand-2); text-decoration: none; }
.page-nav small { display: block; color: var(--faint); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.page-nav strong { font-weight: 700; }
.page-nav .next { text-align: right; grid-column: 2; }
.site-footer {
  border-top: 1px solid var(--line); background: var(--surface);
  padding: 28px 40px; font-size: 13.5px; color: var(--muted);
  display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center;
}
.site-footer a { color: var(--muted); font-weight: 600; }
.site-footer .footer-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.site-footer .disclaimer { flex-basis: 100%; font-size: 12.5px; color: var(--faint); }

/* ---------- Search dialog ---------- */
.search-dialog { border: 0; padding: 0; background: transparent; width: min(640px, calc(100vw - 32px)); margin-top: 10vh; }
.search-dialog::backdrop { background: rgba(10, 14, 25, .5); backdrop-filter: blur(3px); }
.search-panel { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 30px 80px rgba(0, 0, 0, .3); overflow: hidden; }
.search-input-row { display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.search-input-row svg { width: 18px; height: 18px; color: var(--faint); }
.search-input-row input { flex: 1; height: 56px; border: 0; outline: 0; background: transparent; color: var(--ink); font: inherit; font-size: 17px; }
.search-results { list-style: none; margin: 0; padding: 8px; max-height: 60vh; overflow-y: auto; }
.search-results a { display: block; padding: 10px 12px; border-radius: 10px; color: var(--ink); }
.search-results a:hover, .search-results a.selected { background: var(--soft); text-decoration: none; }
.search-results .r-title { font-weight: 700; }
.search-results .r-section { font-size: 12px; color: var(--faint); font-weight: 700; }
.search-results .r-snippet { font-size: 13.5px; color: var(--muted); display: block; margin-top: 2px; }
.search-results mark { background: var(--accent-soft); color: inherit; border-radius: 3px; }
.search-empty { padding: 18px; color: var(--muted); font-size: 14px; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .content { grid-template-columns: minmax(0, 1fr); }
  .toc { display: none; }
}
@media (max-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1fr); }
  .menu-btn { display: inline-grid; }
  .sidebar-container {
    position: fixed; z-index: 35; left: 0; top: var(--nav-h); bottom: 0; height: auto;
    width: min(300px, 86vw); transform: translateX(-100%); transition: transform .2s;
    box-shadow: var(--shadow);
  }
  body.nav-open .sidebar-container { transform: none; }
  body.nav-open::after { content: ""; position: fixed; inset: var(--nav-h) 0 0 0; background: rgba(10, 14, 25, .4); z-index: 30; }
  .content { padding: 26px 16px 64px; }
  .hero { grid-template-columns: minmax(0, 1fr); padding: 30px 22px; }
  .site-footer { padding: 24px 16px; }
  .nav-search { width: auto; }
  .nav-search span, .nav-search kbd { display: none; }
  .brand-docs, .brand-divider { display: none; }
}
@media (max-width: 560px) {
  .navbar { padding: 0 12px; gap: 8px; }
  .navbar .btn { display: none; }
  .page-nav { grid-template-columns: 1fr; }
  .page-nav .next { grid-column: 1; }
  .steps > li { padding-left: 50px; }
}
@media print {
  .navbar, .sidebar-container, .toc, .page-nav, .site-footer { display: none !important; }
  .layout, .content { display: block; padding: 0; }
}

/* Product screenshots inside steps */
.shot { margin: 12px 0 4px; }
.shot img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); background: var(--surface); }
.shot figcaption { margin-top: 6px; font-size: 13px; color: var(--muted); }
