/* Docs: the app's sidebar on the left, one readable column, a quiet rail on the right, and the ⌘K palette. */
.docs-page .site-wrap { max-width: 1320px; }
[data-icon="apps"] { --icon: url('/assets/icons/apps.svg'); }
[data-icon="branch"] { --icon: url('/assets/icons/branch.svg'); }
[data-icon="chevron-down"] { --icon: url('/assets/icons/chevron-down.svg'); }
[data-icon="clock"] { --icon: url('/assets/icons/clock.svg'); }
[data-icon="code"] { --icon: url('/assets/icons/code.svg'); }
[data-icon="copy"] { --icon: url('/assets/icons/copy.svg'); }
[data-icon="check"] { --icon: url('/assets/icons/check.svg'); }
[data-icon="download"] { --icon: url('/assets/icons/download.svg'); }
[data-icon="external-link"] { --icon: url('/assets/icons/external-link.svg'); }
[data-icon="file"] { --icon: url('/assets/icons/file.svg'); }
[data-icon="github"] { --icon: url('/assets/icons/github.svg'); }
[data-icon="keyboard"] { --icon: url('/assets/icons/keyboard.svg'); }
[data-icon="lifebuoy"] { --icon: url('/assets/icons/lifebuoy.svg'); }
[data-icon="markdown"] { --icon: url('/assets/icons/markdown.svg'); }
[data-icon="new-agent"] { --icon: url('/assets/icons/new-agent.svg'); }
[data-icon="note"] { --icon: url('/assets/icons/note.svg'); }
[data-icon="plug"] { --icon: url('/assets/icons/plug.svg'); }
[data-icon="return"] { --icon: url('/assets/icons/return.svg'); }
[data-icon="search"] { --icon: url('/assets/icons/search.svg'); }
[data-icon="server"] { --icon: url('/assets/icons/server.svg'); }
[data-icon="shield"] { --icon: url('/assets/icons/shield.svg'); }
[data-icon="sidebar"] { --icon: url('/assets/icons/sidebar.svg'); }
[data-icon="terminal"] { --icon: url('/assets/icons/terminal.svg'); }
[data-icon="user"] { --icon: url('/assets/icons/user.svg'); }

.docs-shell { display: grid; grid-template-columns: 248px minmax(0, 1fr) 208px; gap: 56px; align-items: start; padding: 28px 0 96px; }

/* Sidebar: a glass panel with project-style groups and session-style rows. */
.docs-sidebar { position: sticky; top: 84px; max-height: calc(100vh - 104px); overflow: auto; overscroll-behavior: contain; scrollbar-width: none; display: flex; flex-direction: column; padding: 8px; border-radius: 12px; background: linear-gradient(180deg, #ffffff07, #ffffff03); border: 1px solid #ffffff10; box-shadow: inset 0 1px 0 #ffffff08; }
.docs-sidebar::-webkit-scrollbar { display: none; }
.docs-search { display: flex; align-items: center; gap: 8px; height: 32px; margin-bottom: 6px; padding: 0 8px; border-radius: 7px; background: #ffffff08; border: 1px solid #ffffff0f; color: #8e86a3; font-size: 13px; text-align: left; transition: border-color 140ms ease, color 140ms ease; }
.docs-search .icon { width: 13px; height: 13px; }
.docs-search span:not(.icon) { flex: 1; }
.docs-search kbd, .docs-search-input kbd, .docs-search-foot kbd { font: 500 11px/1 -apple-system, BlinkMacSystemFont, sans-serif; padding: 3px 5px; border-radius: 5px; color: #a9a2bc; background: #ffffff0d; border: 1px solid #ffffff14; }
.docs-group { margin-top: 10px; }
.docs-group-head { display: flex; align-items: center; gap: 7px; height: 28px; padding: 0 8px; font-size: 12px; font-weight: 500; color: #d4cce0; }
.docs-group-head .icon { width: 11px; height: 11px; color: #8e86a3; }
.docs-group ul { margin: 0; padding: 0; list-style: none; }
.docs-row { position: relative; display: flex; align-items: center; gap: 9px; height: 31px; padding: 0 9px 0 26px; border-radius: 7px; font-size: 13px; color: #b6afc9; border: 1px solid transparent; transition: background-color 120ms ease, color 120ms ease; }
.docs-row .icon { width: 14px; height: 14px; color: #8e86a3; transition: color 120ms ease; }
.docs-row span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.docs-row[aria-current] { color: var(--rp-text); background: #ffffff0f; border-color: #ffffff14; box-shadow: inset 0 1px 0 #ffffff08; }
.docs-row[aria-current] .icon { color: var(--rp-rose); }
.docs-sidebar-foot { display: flex; gap: 4px; margin-top: 14px; padding-top: 8px; border-top: 1px solid #ffffff0d; }
.docs-sidebar-foot a { display: inline-flex; align-items: center; gap: 6px; padding: 6px 8px; border-radius: 6px; font-size: 12px; color: #8e86a3; transition: color 120ms ease, background-color 120ms ease; }
.docs-sidebar-foot .icon { width: 12px; height: 12px; }
@media (hover: hover) and (pointer: fine) {
  .docs-search:hover { color: #c9c2d8; border-color: #ffffff1c; }
  .docs-row:not([aria-current]):hover { background: #ffffff09; color: var(--rp-text); }
  .docs-row:hover .icon { color: #c9c2d8; }
  .docs-sidebar-foot a:hover { color: var(--rp-text); background: #ffffff09; }
}
.docs-menu { display: none; }

/* Heading and column. */
.docs-main { min-width: 0; max-width: 760px; }
.docs-heading { padding: 18px 0 30px; border-bottom: 1px solid #ffffff10; margin-bottom: 34px; }
.docs-heading .eyebrow { color: #f0c5c3; font-weight: 500; font-size: 12.5px; }
.docs-heading h1 { margin: 12px 0 14px; font-size: clamp(32px, 4.2vw, 44px); line-height: 1.08; letter-spacing: -.035em; font-weight: 500; text-wrap: balance; }
.docs-heading p { max-width: 660px; margin: 0; font-size: 17.5px; line-height: 1.6; color: #b6afc9; text-wrap: pretty; }
.docs-heading p a { color: var(--rp-text); text-decoration: underline; text-decoration-color: #ebbcba66; text-underline-offset: 4px; }
.docs-heading code, .docs-content code { font: .86em ui-monospace, SFMono-Regular, Menlo, monospace; color: #e9d2d6; padding: 1px 5px; border-radius: 5px; background: #ffffff0b; border: 1px solid #ffffff10; }

.docs-content { font-size: 15.5px; line-height: 1.72; color: #c9c2d8; }
.docs-content > :first-child { margin-top: 0; }
.docs-content p { margin: 0 0 16px; text-wrap: pretty; }
.docs-content strong { color: var(--rp-text); font-weight: 550; }
.docs-content a { color: var(--rp-text); text-decoration: underline; text-decoration-color: #ebbcba59; text-underline-offset: 4px; transition: text-decoration-color 140ms ease; }
.docs-content a:hover { text-decoration-color: #ebbcba; }
.docs-content a code { color: var(--rp-text); }
.docs-content h2, .docs-content h3, .docs-content h4 { position: relative; scroll-margin-top: 88px; color: var(--rp-text); }
.docs-content h2 { margin: 52px 0 14px; font-size: 23px; line-height: 1.3; letter-spacing: -.02em; font-weight: 550; }
.docs-content h3 { margin: 34px 0 10px; font-size: 17px; line-height: 1.4; letter-spacing: -.01em; font-weight: 550; }
.docs-content h4 { margin: 24px 0 8px; font-size: 15px; font-weight: 600; }
.docs-content h3 code { font-size: .9em; padding: 2px 7px; color: #f0c5c3; background: #ebbcba12; border-color: #ebbcba2a; }
.anchor { position: absolute; left: -22px; width: 22px; color: #6e6a86; text-decoration: none !important; opacity: 0; transition: opacity 120ms ease; font-weight: 400; }
.docs-content :is(h2, h3, h4):hover .anchor { opacity: 1; }
.docs-content ul, .docs-content ol { margin: 0 0 18px; padding-left: 22px; }
.docs-content li { margin: 7px 0; padding-left: 4px; }
.docs-content li::marker { color: #8e86a3; }
.docs-content kbd { display: inline-block; min-width: 1.6em; margin: 0 1px; padding: 0 6px; border-radius: 6px; font: 500 .8em/1.6 -apple-system, BlinkMacSystemFont, sans-serif; text-align: center; color: var(--rp-text); background: #ffffff10; border: 1px solid #ffffff1c; box-shadow: inset 0 -1px 0 #ffffff12; }
.docs-content blockquote { margin: 0 0 18px; padding: 14px 18px; border-radius: 12px; background: linear-gradient(160deg, #ebbcba10, #ffffff05); border: 1px solid #ebbcba2e; color: var(--rp-text); }
.docs-content blockquote p:last-child { margin: 0; }

/* Code blocks: the terminal surface from the app, one copy button. */
.code-block { position: relative; margin: 0 0 20px; border-radius: 10px; background: #15131f; border: 1px solid #ffffff12; box-shadow: inset 0 1px 0 #ffffff06; overflow: hidden; }
.code-head { display: flex; align-items: center; height: 32px; padding: 0 14px; font: 12px ui-monospace, SFMono-Regular, Menlo, monospace; color: #8e86a3; border-bottom: 1px solid #ffffff0c; background: #ffffff04; }
.code-block pre { margin: 0; padding: 13px 16px; overflow-x: auto; font: 13px/1.65 ui-monospace, SFMono-Regular, Menlo, monospace; color: #e0def4; tab-size: 2; }
.code-block pre code { padding: 0; border: 0; background: none; font: inherit; color: inherit; }
.code-copy { position: absolute; top: 4px; right: 5px; display: grid; place-items: center; width: 26px; height: 24px; border-radius: 6px; color: #8e86a3; background: transparent; transition: color 120ms ease, background-color 120ms ease, opacity 120ms ease; }
.code-block:not(:has(.code-head)) .code-copy { top: 8px; right: 8px; opacity: 0; }
.code-block:hover .code-copy, .code-copy:focus-visible { opacity: 1; }
.code-copy .icon { --icon: url('/assets/icons/copy.svg'); width: 13px; height: 13px; }
.code-copy.copied { color: #8fd3a3; }
.code-copy.copied .icon { --icon: url('/assets/icons/check.svg'); }
.code-copy:hover { color: var(--rp-text); background: #ffffff10; }
.tk-comment { color: #6e6a86; font-style: italic; }
.tk-cmd { color: #9ccfd8; }
.tk-flag { color: #c4a7e7; }
.tk-str { color: #f6c177; }
.tk-key { color: #ebbcba; }
.tk-num, .tk-lit { color: #c4a7e7; }

/* Tables: shared columns and hairlines, no cards. */
.table-wrap { margin: 4px 0 22px; overflow-x: auto; border-radius: 10px; border: 1px solid #ffffff10; }
.docs-content table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.55; }
.docs-content th { padding: 9px 14px; text-align: left; font-size: 12px; font-weight: 500; color: #a9a2bc; background: #ffffff05; border-bottom: 1px solid #ffffff10; white-space: nowrap; }
.docs-content td { padding: 10px 14px; vertical-align: top; border-top: 1px solid #ffffff0a; }
.docs-content tr:first-child td { border-top: 0; }
.docs-content td:first-child { color: var(--rp-text); }
.docs-content td code { white-space: nowrap; }
.docs-content thead:has(th:empty:first-child + th:empty:last-child) { display: none; }

/* Callouts. */
.callout { margin: 4px 0 20px; padding: 14px 18px; border-radius: 12px; background: #ffffff07; font-size: 15px; --tone: #a9a2bc; }
.callout > strong { display: block; margin-bottom: 3px; font-size: 12.5px; font-weight: 500; color: var(--tone); }
.callout p:last-child { margin: 0; }
.callout.tip { --tone: #ebbcba; }
.callout.warning { --tone: #f6c177; }

.doc-shot { margin: 6px 0 24px; }
.doc-shot img { display: block; max-width: 100%; height: auto; border-radius: 12px; border: 1px solid #ffffff17; box-shadow: 0 18px 40px -22px #000c; background: #26233a; }
.doc-shot figcaption { margin-top: 10px; font-size: 13.5px; line-height: 1.55; color: #a9a2bc; }

.docs-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 60px; padding-top: 26px; border-top: 1px solid #ffffff10; }
.docs-pager a { display: flex; flex-direction: column; gap: 3px; padding: 13px 16px; border-radius: 10px; color: var(--rp-text); font-size: 15px; font-weight: 500; border: 1px solid #ffffff10; transition: border-color 140ms ease, background-color 140ms ease; }
.docs-pager a span { font-size: 12px; font-weight: 400; color: #8e86a3; }
.docs-pager .next { text-align: right; }
.docs-pager a:hover { border-color: #ffffff24; background: #ffffff05; }

/* Right rail. */
.docs-rail { position: sticky; top: 84px; max-height: calc(100vh - 104px); overflow: auto; scrollbar-width: none; padding-top: 22px; }
.docs-toc { display: flex; flex-direction: column; gap: 2px; margin-bottom: 26px; font-size: 12.5px; line-height: 1.45; }
.docs-toc > span { margin-bottom: 8px; font-size: 12px; font-weight: 500; color: var(--rp-text); }
.docs-toc a { padding: 4px 0 4px 12px; color: #8e86a3; border-left: 1px solid #ffffff12; transition: color 140ms ease, border-color 140ms ease; }
.docs-toc a:hover { color: var(--rp-text); }
.docs-toc a.active { color: var(--rp-text); border-left-color: var(--rp-rose); }
.docs-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding-top: 16px; border-top: 1px solid #ffffff0d; }
.docs-actions :is(a, button) { display: inline-flex; align-items: center; gap: 8px; padding: 5px 0; font-size: 12.5px; color: #8e86a3; background: none; transition: color 140ms ease; }
.docs-actions .icon { width: 13px; height: 13px; }
.docs-actions :is(a, button):hover { color: var(--rp-text); }

/* ⌘K: the app's command palette. */
.docs-search-dialog { position: fixed; inset: 0; z-index: 60; display: flex; justify-content: center; align-items: flex-start; padding: 13vh 16px 16px; }
.docs-search-scrim { position: absolute; inset: 0; background: #0b0a1199; backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); animation: docs-fade 140ms ease-out; }
.docs-search-panel { position: relative; width: min(620px, 100%); max-height: min(560px, 76vh); display: flex; flex-direction: column; border-radius: 14px; background: #1f1d2ee6; border: 1px solid #ffffff17; box-shadow: 0 30px 80px -20px #000000d9, inset 0 1px 0 #ffffff0d; backdrop-filter: blur(24px) saturate(1.4); -webkit-backdrop-filter: blur(24px) saturate(1.4); overflow: hidden; animation: docs-pop 180ms cubic-bezier(.16,1,.3,1); transform-origin: 50% 0; }
@keyframes docs-fade { from { opacity: 0; } }
@keyframes docs-pop { from { opacity: 0; transform: scale(.97) translateY(-4px); } }
.docs-search-input { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 16px; border-bottom: 1px solid #ffffff10; }
.docs-search-input .icon { width: 16px; height: 16px; color: #8e86a3; }
.docs-search-input input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: none; color: var(--rp-text); font-size: 16px; }
.docs-search-input input::placeholder { color: #6e6a86; }
.docs-search-input input::-webkit-search-cancel-button { display: none; }
.docs-search-results { flex: 1; margin: 0; padding: 6px; overflow: auto; list-style: none; overscroll-behavior: contain; }
.docs-search-results li a { display: grid; grid-template-columns: 18px minmax(0, 1fr); column-gap: 10px; padding: 8px 10px; border-radius: 8px; color: #c9c2d8; }
.docs-search-results .icon { width: 15px; height: 15px; margin-top: 2px; color: #8e86a3; }
.docs-search-results .r-title { color: var(--rp-text); font-size: 14px; font-weight: 500; }
.docs-search-results .r-path { margin-left: 6px; font-size: 12px; color: #8e86a3; }
.docs-search-results .r-text { grid-column: 2; font-size: 12.5px; line-height: 1.45; color: #908caa; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.docs-search-results mark { background: none; color: #f0c5c3; }
.docs-search-results li[aria-selected="true"] a { background: #ffffff10; box-shadow: inset 0 0 0 1px #ffffff12; }
.docs-search-results li[aria-selected="true"] .icon { color: var(--rp-rose); }
.docs-search-results .empty { padding: 28px 12px; text-align: center; color: #8e86a3; font-size: 13.5px; }
.docs-search-foot { display: flex; gap: 16px; padding: 9px 16px; font-size: 12px; color: #8e86a3; border-top: 1px solid #ffffff0d; }
.docs-search-foot kbd { margin-right: 3px; }
body.searching { overflow: hidden; }

.docs-page :is(a, button, input):focus-visible { outline: 2px solid var(--rp-rose); outline-offset: 2px; border-radius: 6px; }

@media (max-width: 1180px) {
  .docs-shell { grid-template-columns: 236px minmax(0, 1fr); gap: 48px; }
  .docs-rail { display: none; }
}
@media (max-width: 860px) {
  .docs-shell { display: block; padding-top: 12px; }
  .docs-menu { display: flex; align-items: center; gap: 8px; width: 100%; height: 40px; padding: 0 12px; border-radius: 10px; font-size: 13px; color: #a9a2bc; background: #ffffff07; border: 1px solid #ffffff10; text-align: left; }
  .docs-menu .icon { width: 15px; height: 15px; }
  .docs-menu strong { color: var(--rp-text); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .docs-menu-sep { color: #6e6a86; }
  .docs-sidebar { position: static; display: none; max-height: none; margin-top: 8px; }
  .docs-menu[aria-expanded="true"] + .docs-sidebar { display: flex; }
  .docs-heading { padding-top: 26px; }
  .docs-content { font-size: 15.5px; }
  .anchor { display: none; }
  .docs-pager { grid-template-columns: 1fr; }
  .docs-search-dialog { padding-top: 10px; }
  .docs-search-panel { max-height: 80vh; }
}
@media (prefers-reduced-motion: reduce) {
  .docs-search-scrim, .docs-search-panel { animation: none; }
}
.docs-search-input input:focus-visible { outline: none; }
@media (hover: none) { .docs-search kbd { display: none; } }

/* Articles outside the docs (agents, comparisons, releases): guide layout, docs typography. */
.article-page .guide-layout { grid-template-columns: 200px minmax(0, 760px); }
.article-content { max-width: 760px; }
.article-content > h2:first-child { margin-top: 0; }
.guide-heading .agent-tile { margin-bottom: 22px; }
.agent-tile { display: inline-grid; place-items: center; flex: 0 0 auto; border-radius: 14px; background: linear-gradient(180deg, #ffffff14, #ffffff08); box-shadow: inset 0 0 0 1px #ffffff1a, 0 10px 30px -14px #000; color: var(--rp-text); }
.agent-tile.lg { width: 56px; height: 56px; }
.agent-tile.lg .icon { width: 28px; height: 28px; }
.agent-tile.sm { width: 34px; height: 34px; border-radius: 9px; }
.agent-tile.sm .icon { width: 17px; height: 17px; }
.agent-tile.letter { font-weight: 600; font-size: 15px; }
.agent-tile.lg.letter { font-size: 24px; }
.docs-content .agent-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 8px; margin: 0 0 36px; padding: 0; list-style: none; }
.docs-content .agent-grid li { margin: 0; padding: 0; }
.agent-grid a { display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 11px; border: 1px solid #ffffff10; color: var(--rp-text); font-size: 14.5px; text-decoration: none; transition: background-color 140ms ease, border-color 140ms ease; }
.agent-grid a:hover { background: #ffffff07; border-color: #ffffff22; }
.install-box { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px 28px; align-items: center; margin: 48px 0 8px; padding: 22px 24px; border-radius: 14px; background: linear-gradient(160deg, #ebbcba14, #ffffff05 60%); border: 1px solid #ebbcba2e; }
.install-copy strong { display: block; font-size: 18px; font-weight: 550; letter-spacing: -.01em; color: var(--rp-text); }
.install-copy span { display: block; margin-top: 4px; font-size: 14px; line-height: 1.55; color: #b6afc9; }
.install-actions { min-width: 0; display: flex; flex-direction: column; align-items: stretch; gap: 8px; }
.install-actions .button.primary { height: 38px; text-decoration: none; color: #241c26; }
.install-actions .button .icon { width: 14px; height: 14px; }
.install-brew { margin: 0; }
.install-brew pre { padding: 8px 40px 8px 12px; font-size: 12px; }
.install-brew .code-copy { top: 5px; right: 5px; opacity: 1; }
.release-page .release { max-width: none; padding-top: 0; }
.release-heading h2 a { color: inherit; text-decoration: none; }
.release-heading h2 a:hover { color: #f0c5c3; }
@media (max-width: 820px) {
  .install-box { grid-template-columns: minmax(0, 1fr); padding: 18px; }
}
.article-page .guide-heading { max-width: 940px; }
.article-page .guide-heading h1 { hyphens: manual; }
