/* Documentation site. Colors, sizes, radii and fonts all come from theme.css tokens. */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: calc(var(--docs-top) + 16px); -webkit-text-size-adjust: 100%; }
:root { --docs-top: 56px; --docs-side: 264px; --docs-toc: 220px; --docs-article: 720px; }
body.docs { margin: 0; background: var(--sb-bg); color: var(--sb-text); font: var(--fw-text) var(--fs-sm)/1.5 var(--font-sans); }
.docs a { color: inherit; }
.docs :focus-visible { outline: 2px solid var(--sb-brand); outline-offset: 2px; border-radius: var(--r-sm); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--sb-surface-2); padding: 8px 12px; border-radius: var(--r-md); z-index: 100; }
.skip:focus { left: 8px; }
[hidden] { display: none !important; }

/* buttons */
.btn { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: var(--r-sm); border: 1px solid var(--sb-border-strong); background: transparent; color: var(--sb-text); font: var(--fw-medium) var(--fs-xs)/1 var(--font-sans); text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn:hover { background: var(--sb-surface-2); }
.btn.btn-brand { background: var(--sb-brand-fill); border-color: var(--sb-brand-ring); color: var(--sb-on-brand); }
.btn.btn-brand:hover { background: var(--sb-brand-fill-hover); color: var(--sb-on-brand); }

/* top bar */
.dtop { position: sticky; top: 0; z-index: 30; height: var(--docs-top); background: var(--sb-bg); border-bottom: 1px solid var(--sb-border); }
.dtop-in { height: 100%; display: flex; align-items: center; gap: 16px; padding: 0 24px; max-width: 1600px; margin: 0 auto; }
.dbrand { display: flex; align-items: center; gap: 8px; text-decoration: none; flex: none; }
.dbrand-name { font: var(--fw-semibold) var(--fs-md)/1 var(--font-display); }
.dbrand-tag { font: var(--fw-medium) 11px/1 var(--font-mono); letter-spacing: .08em; color: var(--sb-text-muted); border: 1px solid var(--sb-border-strong); border-radius: var(--r-sm); padding: 3px 5px; }
.dsections { display: flex; gap: 2px; margin-left: 12px; }
.dsec { position: relative; }
.dsec > a { display: flex; align-items: center; gap: 2px; height: 32px; padding: 0 10px; border-radius: var(--r-md); color: var(--sb-text-muted); text-decoration: none; font-weight: var(--fw-medium); }
.dsec > a:hover, .dsec.is-current > a { color: var(--sb-text); }
.dsec-menu { display: none; position: absolute; left: 0; top: 100%; min-width: 220px; margin: 0; padding: 6px; list-style: none; background: var(--sb-surface-1); border: 1px solid var(--sb-border-strong); border-radius: var(--r-lg); max-height: 70vh; overflow: auto; }
.dsec:hover .dsec-menu, .dsec:focus-within .dsec-menu { display: block; }
.dsec-menu a { display: block; padding: 6px 10px; border-radius: var(--r-sm); text-decoration: none; color: var(--sb-text-muted); }
.dsec-menu a:hover { background: var(--sb-surface-3); color: var(--sb-text); }
.dtop-end { margin-left: auto; display: flex; align-items: center; gap: 8px; min-width: 0; }
.dsearch { display: flex; align-items: center; gap: 8px; width: min(340px, 30vw); height: 32px; padding: 0 8px 0 10px; border-radius: var(--r-md); border: 1px solid var(--sb-border-strong); background: var(--sb-surface-1); color: var(--sb-text-muted); font: inherit; cursor: pointer; }
.dsearch:hover { border-color: var(--sb-text-faint); }
.dsearch-label { flex: 1; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.docs kbd { font: var(--fw-medium) 11px/1 var(--font-mono); color: var(--sb-text-muted); border: 1px solid var(--sb-border-strong); border-radius: var(--r-sm); padding: 3px 5px; background: var(--sb-surface-2); }
.dmenu { display: none; background: none; border: 0; color: var(--sb-text); padding: 6px; border-radius: var(--r-md); cursor: pointer; }

/* layout */
.dwrap { display: grid; grid-template-columns: var(--docs-side) minmax(0, 1fr); max-width: 1600px; margin: 0 auto; }
.dside { position: sticky; top: var(--docs-top); align-self: start; height: calc(100vh - var(--docs-top)); overflow-y: auto; padding: 20px 12px 40px 24px; border-right: 1px solid var(--sb-border); }
.sgroup { margin-bottom: 4px; }
.sgroup summary { cursor: pointer; padding: 6px 8px; border-radius: var(--r-md); font: var(--fw-semibold) 12px/1.4 var(--font-sans); letter-spacing: .04em; text-transform: uppercase; color: var(--sb-text-muted); list-style: none; display: flex; justify-content: space-between; }
.sgroup summary::-webkit-details-marker { display: none; }
.sgroup summary::after { content: ""; width: 6px; height: 6px; margin: 6px 4px 0 0; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); transition: transform .15s; }
.sgroup[open] summary::after { transform: rotate(-135deg); margin-top: 9px; }
.sgroup ul { list-style: none; margin: 2px 0 10px; padding: 0; }
.sgroup li a { display: block; padding: 5px 8px; border-radius: var(--r-md); color: var(--sb-text-muted); text-decoration: none; }
.sgroup li a:hover { color: var(--sb-text); background: var(--sb-surface-1); }
.sgroup li a[aria-current="page"] { color: var(--sb-brand); background: var(--sb-surface-2); font-weight: var(--fw-medium); }
.dmain { min-width: 0; padding: 40px 48px 0; }
.dcols { display: grid; grid-template-columns: minmax(0, var(--docs-article)) var(--docs-toc); gap: 56px; justify-content: center; }
.dscrim { display: none; }

/* article */
.prose { font-size: var(--fs-md); line-height: 1.65; min-width: 0; }
.prose > :first-child { margin-top: 0; }
.dcrumb { margin: 0 0 8px; font: var(--fw-medium) 12px/1 var(--font-sans); letter-spacing: .06em; text-transform: uppercase; color: var(--sb-brand); }
.prose h1 { font: var(--fw-medium) 36px/1.15 var(--font-display); letter-spacing: -.01em; margin: 0 0 12px; }
.dlead { font-size: var(--fs-lg); color: var(--sb-text-muted); margin: 0 0 28px; line-height: 1.5; }
.prose h2, .prose h3 { font-family: var(--font-display); position: relative; line-height: 1.25; }
.prose h2 { font-size: 24px; font-weight: var(--fw-semibold); margin: 48px 0 12px; padding-top: 24px; border-top: 1px solid var(--sb-border); }
.prose h3 { font-size: var(--fs-h3); font-weight: var(--fw-semibold); margin: 32px 0 8px; }
.prose h4 { font: var(--fw-semibold) var(--fs-md)/1.3 var(--font-display); margin: 24px 0 6px; }
.anchor { position: absolute; left: -22px; padding-right: 8px; color: var(--sb-text-faint); text-decoration: none; opacity: 0; font-weight: var(--fw-text); }
.prose h2:hover .anchor, .prose h3:hover .anchor, .anchor:focus { opacity: 1; }
.prose a { color: var(--sb-brand); text-decoration: underline; text-decoration-color: var(--sb-brand-ring); text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: currentColor; }
.prose p, .prose ul, .prose ol { margin: 0 0 16px; }
.prose li { margin: 4px 0; }
.prose li > p { margin: 0 0 8px; }
.prose ul.contains-task-list { list-style: none; padding-left: 4px; }
.prose hr { border: 0; border-top: 1px solid var(--sb-border); margin: 32px 0; }
.prose :not(pre) > code { font: 0.86em var(--font-mono); background: var(--sb-surface-2); border: 1px solid var(--sb-border); border-radius: var(--r-sm); padding: 1px 5px; overflow-wrap: anywhere; }
.prose a code { color: inherit; }
.prose pre { position: relative; margin: 0 0 20px; padding: 14px 16px; overflow-x: auto; background: var(--sb-surface-1); border: 1px solid var(--sb-border); border-radius: var(--r-lg); font: 13px/1.6 var(--font-mono); tab-size: 2; }
.prose pre code { font: inherit; background: none; border: 0; padding: 0; white-space: pre; }
.copy { position: absolute; top: 8px; right: 8px; display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 6px; background: var(--sb-surface-2); color: var(--sb-text-muted); border: 1px solid var(--sb-border-strong); border-radius: var(--r-sm); font: var(--fw-medium) 11px/1 var(--font-sans); cursor: pointer; opacity: 0; }
pre:hover > .copy, .copy:focus-visible, .pcard:hover .copy, .copy.done { opacity: 1; }
@media (hover: none) { .copy { opacity: 1; } }
.copy.done { color: var(--sb-brand); }
.table-wrap { overflow-x: auto; margin: 0 0 20px; border: 1px solid var(--sb-border); border-radius: var(--r-lg); }
.prose table { border-collapse: collapse; width: 100%; font-size: var(--fs-sm); line-height: 1.5; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 9px 14px; border-bottom: 1px solid var(--sb-border); }
.prose tr:last-child td { border-bottom: 0; }
.prose th { background: var(--sb-surface-1); color: var(--sb-text-muted); font-weight: var(--fw-medium); white-space: nowrap; }
.prose td code { white-space: nowrap; }
.prose blockquote { margin: 0 0 20px; padding: 2px 16px; border-left: 2px solid var(--sb-border-strong); color: var(--sb-text-muted); }
.prose blockquote.callout { border: 1px solid var(--sb-border); border-left-width: 3px; border-radius: var(--r-lg); background: var(--sb-surface-1); color: var(--sb-text); padding: 12px 16px; }
.callout::before { content: attr(data-callout); display: block; font: var(--fw-semibold) 12px/1.4 var(--font-sans); letter-spacing: .05em; text-transform: uppercase; margin-bottom: 4px; }
.callout > :last-child { margin-bottom: 0; }
.callout-note { border-left-color: var(--sb-info) !important; } .callout-note::before { color: var(--sb-info); }
.callout-tip { border-left-color: var(--sb-ok) !important; } .callout-tip::before { color: var(--sb-ok); }
.callout-warning { border-left-color: var(--sb-warn) !important; } .callout-warning::before { color: var(--sb-warn); }
.prose img { max-width: 100%; }

/* code tabs and the hero card tabs: labels show without JavaScript, tabs with it */
.codetabs { margin: 0 0 20px; border: 1px solid var(--sb-border); border-radius: var(--r-lg); background: var(--sb-surface-1); overflow: hidden; }
.codetabs pre { margin: 0; border: 0; border-radius: 0; }
.codetab[data-label]::before { content: attr(data-label); display: block; padding: 8px 16px 0; font: var(--fw-medium) 12px/1 var(--font-sans); color: var(--sb-text-muted); }
.tab-list { display: flex; gap: 2px; padding: 0 8px; border-bottom: 1px solid var(--sb-border); }
.tab { background: none; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px; padding: 10px 10px 8px; color: var(--sb-text-muted); font: var(--fw-medium) var(--fs-sm)/1 var(--font-sans); cursor: pointer; }
.tab:hover { color: var(--sb-text); }
.tab[aria-selected="true"] { color: var(--sb-text); border-bottom-color: var(--sb-brand); }
.js .codetab[data-label]::before, .js .pcard-panel[data-label]::before { display: none; }
.js .is-hidden { display: none; }

/* pager, outline, footer */
.dpager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 56px 0 16px; }
.dpager a { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border: 1px solid var(--sb-border); border-radius: var(--r-lg); text-decoration: none; color: var(--sb-text); }
.dpager a:hover { border-color: var(--sb-brand); }
.dpager span { font-size: var(--fs-xs); color: var(--sb-text-muted); }
.dpager-next { grid-column: 2; text-align: right; }
.dpager-prev:only-child { grid-column: 1; }
.dmeta { font-size: var(--fs-sm); color: var(--sb-text-muted); }
.dtoc { position: sticky; top: calc(var(--docs-top) + 24px); align-self: start; max-height: calc(100vh - var(--docs-top) - 48px); overflow-y: auto; }
.dtoc-title { margin: 0 0 8px; font: var(--fw-semibold) 12px/1.4 var(--font-sans); letter-spacing: .04em; text-transform: uppercase; color: var(--sb-text-muted); }
.dtoc ul { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--sb-border); }
.dtoc a { display: block; padding: 4px 12px; margin-left: -1px; border-left: 1px solid transparent; color: var(--sb-text-muted); text-decoration: none; font-size: 13px; }
.dtoc .l3 a { padding-left: 24px; }
.dtoc a:hover { color: var(--sb-text); }
.dtoc a.active { color: var(--sb-brand); border-left-color: var(--sb-brand); }
.dfoot { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 64px; padding: 24px 0 40px; border-top: 1px solid var(--sb-border); color: var(--sb-text-muted); font-size: var(--fs-xs); }
.dfoot a { text-decoration: none; } .dfoot a:hover { color: var(--sb-text); }

/* docs home */
.dhome-body { max-width: var(--docs-article); margin: 0 auto; }
.pcard { position: relative; border: 1px solid var(--sb-border-strong); border-radius: var(--r-xl); background: var(--sb-surface-1); overflow: hidden; font-size: var(--fs-sm); }
.pcard .tab-list { padding: 4px 12px 0; padding-right: 56px; }
.pcard-panel { padding: 16px 20px 20px; position: relative; }
.pcard-panel[data-label]::before { content: attr(data-label); display: block; margin-bottom: 8px; font: var(--fw-medium) 12px/1 var(--font-sans); color: var(--sb-text-muted); }
.pcard-panel p { margin: 0 0 10px; line-height: 1.6; }
.pcard-panel ol { margin: 0; padding-left: 20px; }
.pcard-panel li { margin: 0 0 8px; line-height: 1.6; padding-left: 4px; }
.pcard-panel code { font: 12.5px var(--font-mono); background: var(--sb-surface-3); border-radius: var(--r-sm); padding: 1px 6px; overflow-wrap: anywhere; }
.pcard-panel pre { margin: 0 0 10px; padding: 12px; border: 1px solid var(--sb-border); border-radius: var(--r-md); background: var(--sb-bg); font: 12.5px/1.6 var(--font-mono); overflow-x: auto; }
.pcard-panel pre code { background: none; padding: 0; }
.pcard .copy { top: 8px; right: 12px; opacity: 1; }
.pcard-panel.clamped { max-height: 270px; overflow: hidden; }
.pcard-panel.clamped::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 80px; background: linear-gradient(transparent, var(--sb-surface-1)); pointer-events: none; }
.pill { display: block; margin: 0 auto 12px; height: 26px; padding: 0 12px; border-radius: var(--r-pill); border: 1px solid var(--sb-border-strong); background: var(--sb-surface-2); color: var(--sb-text-muted); font: var(--fw-medium) var(--fs-xs)/1 var(--font-sans); cursor: pointer; }
.pill:hover { color: var(--sb-text); }
.pill-wrap { position: relative; z-index: 1; margin-top: -4px; }

/* dialogs: search palette and agent prompt */
dialog.dlg { padding: 0; border: 1px solid var(--sb-border-strong); border-radius: var(--r-xl); background: var(--sb-surface-1); color: var(--sb-text); width: min(640px, calc(100vw - 24px)); max-height: 80vh; margin: 10vh auto auto; overflow: hidden; }
dialog.dlg::backdrop { background: rgb(0 0 0 / .6); }
.sbox { display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--sb-border); color: var(--sb-text-muted); }
.sbox input { flex: 1; height: 52px; background: none; border: 0; outline: 0; color: var(--sb-text); font: var(--fw-text) var(--fs-md)/1 var(--font-sans); }
.sresults { list-style: none; margin: 0; padding: 8px; max-height: calc(80vh - 60px); overflow-y: auto; }
.sresults a { display: block; padding: 9px 12px; border-radius: var(--r-md); text-decoration: none; }
.sresults a[aria-selected="true"], .sresults a:hover { background: var(--sb-surface-3); }
.sr-t { display: block; font-weight: var(--fw-medium); }
.sr-g { color: var(--sb-text-muted); font-weight: var(--fw-text); }
.sr-x { display: block; margin-top: 2px; color: var(--sb-text-muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sempty { padding: 24px 16px; color: var(--sb-text-muted); text-align: center; }
.dlg-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px 0 20px; font: var(--fw-semibold) var(--fs-md)/1 var(--font-display); }
.dlg-close { background: none; border: 0; color: var(--sb-text-muted); font-size: 22px; line-height: 1; cursor: pointer; padding: 4px 8px; border-radius: var(--r-sm); }
.dlg .pcard { margin: 12px 16px 16px; max-height: 60vh; overflow-y: auto; }

@media (max-width: 1200px) {
  .dcols { grid-template-columns: minmax(0, var(--docs-article)); }
  .dtoc { display: none; }
}
@media (max-width: 1100px) { .dsections { display: none; } }
@media (max-width: 900px) {
  .dwrap { grid-template-columns: minmax(0, 1fr); }
  .dmenu { display: inline-flex; }
  .dside { position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--sb-border); padding: 12px 16px; }
  .js .dside { position: fixed; z-index: 40; border-bottom: 0; padding: 20px 12px 40px 24px; top: var(--docs-top); left: 0; bottom: 0; width: min(300px, 86vw); height: auto; background: var(--sb-bg); transform: translateX(-100%); transition: transform .2s; }
  .js body.nav-open .dside, body.nav-open .dside { transform: none; }
  body.nav-open .dscrim { display: block; position: fixed; inset: var(--docs-top) 0 0 0; z-index: 35; background: rgb(0 0 0 / .5); }
  .dmain { padding: 28px var(--gutter) 0; }
  .dtop-in { padding: 0 16px; gap: 10px; }
  .dsearch { width: 32px; padding: 0; justify-content: center; }
  .dsearch-label, .dsearch kbd { display: none; }
}
@media (max-width: 640px) {
  .prose h1 { font-size: var(--fs-h1); }
  .dask span { display: none; }
  .dask { padding: 0 7px; }
  .dbrand-tag { display: none; }
  .anchor { display: none; }
  .dpager { grid-template-columns: 1fr; } .dpager-next { grid-column: 1; }
}
@media (prefers-reduced-motion: reduce) { .dside, .sgroup summary::after { transition: none; } }

/* ---- Docs theme: the same look as the landing page (Instrument Sans, warm dark neutrals, one green accent,
   soft rounded surfaces, poster headings). Appended last so it refines the structure above. ---- */
:root { --docs-top: 64px; --docs-article: 740px; }
body.docs h1, body.docs h2 { text-wrap: balance; }

/* top bar: translucent, with controls the same size and shape as the landing header */
.dtop { background: color-mix(in srgb, var(--sb-bg) 88%, transparent); backdrop-filter: blur(10px); }
.dtop-in { gap: 8px; }
.dbrand { gap: 10px; margin-right: 8px; }
.dbrand-name { font-size: 18px; font-weight: 600; letter-spacing: -.02em; }
.dbrand-tag { color: var(--sb-brand); border-color: color-mix(in srgb, var(--sb-brand) 40%, transparent); background: var(--sb-brand-soft); border-radius: var(--r-pill); padding: 3px 8px; }
.dsec > a { font-size: var(--fs-sm); border-radius: 10px; }
.dsec > a:hover { background: var(--sb-surface-2); }
.dsec-menu { border-radius: 14px; padding: 8px; box-shadow: 0 24px 60px -20px rgb(0 0 0 / .45); }
.dsec-menu a { border-radius: 8px; padding: 7px 10px; }
.dsearch { height: 36px; border-radius: 10px; }
.btn { height: 34px; padding: 0 14px; font-size: var(--fs-sm); border-radius: 10px; }
.btn.btn-brand { border-color: transparent; }
.dtop-end .theme-cycle { width: 34px; height: 34px; border-radius: 10px; }

/* sidebar: quiet group labels, a soft pill on the current page */
.dside { padding-top: 24px; }
.sgroup summary { font: 11px var(--font-mono); letter-spacing: .1em; color: var(--sb-text-faint); padding: 8px; }
.sgroup summary:hover { color: var(--sb-text); }
.sgroup li a { padding: 6px 10px; border-radius: 10px; font-size: var(--fs-sm); }
.sgroup li a[aria-current="page"] { background: var(--sb-brand-soft); color: var(--sb-brand); font-weight: var(--fw-medium); }

/* article */
.dmain { padding-top: 48px; }
.dcrumb { font: 12px var(--font-mono); letter-spacing: .1em; margin-bottom: 14px; }
.prose h1 { font-size: clamp(36px, 4.4vw, 54px); font-weight: 600; line-height: 1.02; letter-spacing: -.045em; margin-bottom: 16px; }
.dlead { font-size: 19px; line-height: 1.55; max-width: 36em; margin-bottom: 36px; }
.prose h2 { font-size: 28px; font-weight: 600; letter-spacing: -.03em; margin-top: 56px; border-top-color: var(--sb-border); }
.prose h3 { font-weight: 600; letter-spacing: -.02em; }
.prose a { text-decoration-thickness: 1px; }
.prose :not(pre) > code { border-radius: 6px; background: var(--sb-surface-2); }
.prose pre { border-radius: 14px; padding: 16px 18px; background: var(--sb-surface-1); }
.copy { border-radius: 8px; height: 26px; }
.table-wrap { border-radius: 14px; }
.prose th { font: 11px var(--font-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--sb-text-faint); }
.prose blockquote.callout { border-radius: 14px; padding: 14px 18px; }
.callout-note { background: var(--sb-info-soft) !important; }
.callout-tip { background: var(--sb-brand-soft) !important; }
.callout-warning { background: var(--sb-warn-soft) !important; }
.codetabs { border-radius: 14px; }
.tab[aria-selected="true"] { border-bottom-color: var(--sb-brand); }

/* previous / next */
.dpager a { border-radius: 14px; padding: 16px 18px; background: var(--sb-surface-1); transition: border-color .15s, transform .15s; }
.dpager a:hover { border-color: var(--sb-brand); transform: translateY(-1px); }
.dpager strong { font-size: var(--fs-md); font-weight: 600; letter-spacing: -.01em; }
.dpager-prev span::before { content: "← "; } .dpager-next span::after { content: " →"; }

/* outline on the right */
.dtoc-title { font: 11px var(--font-mono); letter-spacing: .1em; color: var(--sb-text-faint); }
.dtoc a.active { color: var(--sb-brand); }

/* docs home: poster heading, big cards */
.pcard { border-radius: 18px; }
.pill { border-radius: var(--r-pill); }

/* search and prompt dialogs */
dialog.dlg { border-radius: 20px; box-shadow: 0 40px 100px -20px rgb(0 0 0 / .6); }
.sresults a { border-radius: 10px; }
@media (max-width: 900px) { .dtop-in { gap: 6px; } .dmain { padding-top: 32px; } }
@media (prefers-reduced-motion: reduce) { .dpager a, .dcard, .dcard::after { transition: none; } }

/* docs home: centered hero with search, agent banner, icon cards */
.dhome { max-width: 760px; margin: 0 auto; padding: 40px 0 8px; text-align: center; }
.dhome-eyebrow { margin: 0 0 16px; font: var(--fw-medium) 12px/1 var(--font-sans); letter-spacing: .14em; color: var(--sb-brand); }
.dhome h1 { margin: 0; font: var(--fw-semibold) clamp(36px, 5vw, 56px)/1.05 var(--font-display); letter-spacing: -.03em; }
.dhome-lead { margin: 20px 0 0; font-size: 18px; line-height: 1.55; color: var(--sb-text-muted); }
.dhome-search { display: flex; align-items: center; gap: 12px; width: 100%; max-width: 620px; height: 56px; margin: 36px auto 0; padding: 0 18px; box-sizing: border-box; border: 1px solid var(--sb-border-strong); border-radius: 12px; background: var(--sb-surface-1); color: var(--sb-text-muted); font: 16px var(--font-sans); text-align: left; cursor: pointer; }
.dhome-search:hover { border-color: var(--sb-brand); }
.dhome-search span { flex: 1; }
.dhome-search kbd { font: 12px var(--font-mono); border: 1px solid var(--sb-border-strong); border-radius: 6px; padding: 3px 7px; }
.dhome-popular { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 10px; margin: 20px 0 0; font-size: 13px; }
.dhome-popular span { color: var(--sb-text-faint); }
.dhome-popular a { color: var(--sb-text); text-decoration: none; border: 1px solid var(--sb-border-strong); border-radius: 999px; padding: 6px 14px; font-weight: var(--fw-medium); }
.dhome-popular a:hover { border-color: var(--sb-brand); color: var(--sb-brand); }
.dagent { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; max-width: 1180px; margin: 56px auto 40px; padding: 18px 22px; border: 1px solid var(--sb-border); border-radius: 14px; background: linear-gradient(var(--sb-brand-soft), var(--sb-brand-soft)), var(--sb-surface-1); }
.dagent > svg { flex: none; color: var(--sb-brand); }
.dagent div { flex: 1; min-width: 260px; display: grid; gap: 2px; }
.dagent strong { font-size: 15px; font-weight: var(--fw-semibold); }
.dagent div span { color: var(--sb-text-muted); font-size: var(--fs-sm); line-height: 1.5; }
.dagent-alt { font-size: var(--fs-sm); font-weight: var(--fw-medium); text-decoration: none; }
.dcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; max-width: 1180px; margin: 0 auto 48px; }
.dcard { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 22px; border: 1px solid var(--sb-border); border-radius: 14px; background: var(--sb-surface-1); transition: border-color .15s, background .15s; }
.dcard:hover, .dcard:focus-within { border-color: var(--sb-brand); background: var(--sb-surface-2); }
.dcard-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--sb-brand-soft); color: var(--sb-brand); }
.dcard h2 { margin: 6px 0 0; font: var(--fw-semibold) 17px/1.3 var(--font-display); letter-spacing: -.01em; }
.dcard h2 a { color: inherit; text-decoration: none; }
.dcard h2 a::after { content: ""; position: absolute; inset: 0; border-radius: 14px; }
.dcard p { margin: 0; flex: 1; color: var(--sb-text-muted); font-size: var(--fs-sm); line-height: 1.5; }
.dcard ul { position: relative; display: grid; gap: 6px; margin: 0; padding: 12px 0 0; list-style: none; border-top: 1px solid var(--sb-border); font-size: 13px; font-weight: var(--fw-medium); }
.dcard ul a { position: relative; z-index: 1; color: var(--sb-brand); text-decoration: none; }
.dcard ul a:hover { text-decoration: underline; }
@media (prefers-reduced-motion: reduce) { .dcard { transition: none; } }
