/* ================= cs-docs.css — docs pages polish (loaded last) =================
   Hub (body.vp-built) + reader (body.docs-reader). Monochrome, homepage type scale. */

/* 1. no decorative blobs */
html:not(#cs) body :is(.vp-layout,.docs-platform-layout)::before,
html:not(#cs) body :is(.overview-hero,.docs-hub-hero)::before{content:none!important;display:none!important}

/* 2. type scale — calmer, denser */
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article){font-size:15.5px;line-height:1.75;color:#2c2d33}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc h1,.docs-reader-header h1){font-size:38px!important;line-height:46px!important;font-weight:600!important;letter-spacing:-.025em!important;margin:0!important;color:#161618}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-lead,.reader-intro){margin:12px 0 0!important;font-size:17px!important;line-height:28px!important;color:rgba(22,22,24,.6)!important}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) h2{margin:48px 0 12px!important;padding-top:0!important;border-top:0!important;font-size:23px!important;line-height:32px!important;font-weight:600!important;letter-spacing:-.015em}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) h3{margin:32px 0 10px!important;font-size:17px!important;line-height:26px!important;font-weight:600!important;letter-spacing:-.01em}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) :is(p,li){font-size:15.5px;line-height:1.75}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) :is(ul,ol){padding-left:1.25em}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) li{margin:4px 0}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) li>p{margin:0}
html:not(#cs) body.docs-reader .docs-reader-header{margin-bottom:0;padding-bottom:22px;border-bottom:1px solid rgba(22,22,24,.08)}

/* breadcrumb: one quiet line */
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-crumbs,.docs-breadcrumb){font-size:13px!important;line-height:20px;margin-bottom:18px!important;color:rgba(22,22,24,.4)}
html:not(#cs) body.docs-reader .docs-breadcrumb>span:last-child{color:#161618!important;max-width:320px}

/* 3. code blocks: light card so shiki github-light colours are readable */
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article,.api-peek) pre{
  margin:16px 0 24px!important;padding:16px 18px!important;border-radius:12px!important;
  background:#f7f7f9!important;color:#24292e!important;border:1px solid rgba(22,22,24,.07)!important;box-shadow:none!important;
  font-size:13px!important;line-height:1.7!important;overflow-x:auto!important;white-space:pre!important;tab-size:4;
  scrollbar-width:thin;scrollbar-color:#d4d5dc transparent}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article,.api-peek) pre code{background:none!important;color:inherit!important;padding:0!important;font-size:inherit!important;white-space:inherit!important;display:block;min-width:max-content}
html:not(#cs) body:is(.vp-built,.docs-reader) pre.shiki span[style*="--shiki-light"]{color:var(--shiki-light)!important}
html:not(#cs) body:is(.vp-built,.docs-reader) pre.shiki{background:#f7f7f9!important}

/* 4. callouts: drop the English label, use a small Chinese tag */
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-block,.custom-block){margin:24px 0!important;padding:14px 18px!important;border-radius:12px!important;background:#f6f6f8!important;font-size:14.5px;line-height:1.7}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-block-title,.custom-block-title){font-size:0!important;line-height:0!important;margin:0 0 6px!important}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-block-title,.custom-block-title)::before{content:"提示";display:inline-block;font-size:12px;line-height:20px;font-weight:600;letter-spacing:.04em;color:rgba(22,22,24,.56)}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-block,.custom-block) p{margin:0;font-size:14.5px}

/* tables: lighter */
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) table{border-radius:12px!important;box-shadow:none!important;border:1px solid rgba(22,22,24,.08)!important;font-size:14px}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) :is(th,td){padding:10px 14px!important}
html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) th{background:#f7f7f9!important;font-weight:600;color:#161618}

/* 5. reader sidebar */
html:not(#cs) body.docs-reader .docs-platform-sidebar__title{display:block!important;margin:0 0 10px;padding:0 12px;font-size:13px;font-weight:600;color:#161618}
html:not(#cs) body.docs-reader .reader-start-link{display:flex!important;align-items:center;justify-content:space-between;margin:0 0 10px!important;padding:8px 12px!important;border-radius:10px!important;background:#f4f4f6!important;color:#161618!important;box-shadow:none!important;font-size:14px!important;font-weight:600}
html:not(#cs) body.docs-reader .reader-start-link:hover{background:#ececef!important}
html:not(#cs) body.docs-reader .reader-start-link .qx-arrow{background:none!important;color:rgba(22,22,24,.5)!important}
html:not(#cs) body.docs-reader .reader-nav-search{display:block;position:sticky;top:-40px;z-index:2;margin:0 0 12px;padding:0 0 4px;background:#fff}
html:not(#cs) body.docs-reader .reader-nav-search input{width:100%;height:36px!important;padding:0 12px!important;border-radius:10px!important;border:1px solid rgba(22,22,24,.1)!important;background:#fff!important;box-shadow:none!important;font-size:13px!important;color:#161618}
html:not(#cs) body.docs-reader .reader-nav-search input:focus{outline:none;border-color:rgba(22,22,24,.35)!important}
html:not(#cs) body.docs-reader .docs-platform-sidebar summary{display:flex!important;align-items:center;gap:6px;padding:7px 12px!important;font-size:13.5px!important;font-weight:600!important;color:#161618}
html:not(#cs) body.docs-reader .docs-platform-sidebar summary span{margin-left:auto;float:none!important;font-size:12px;font-weight:500;color:rgba(22,22,24,.36)!important}
html:not(#cs) body.docs-reader .reader-function-groups{display:grid!important;gap:2px!important}
html:not(#cs) body.docs-reader .reader-function-groups details{margin:0!important;padding:0!important;border:0!important}
html:not(#cs) body.docs-reader .reader-function-groups details>div{display:grid!important;gap:1px!important;margin:2px 0 8px 12px;padding-left:8px;border-left:1px solid rgba(22,22,24,.08)}
html:not(#cs) body.docs-reader .reader-function-groups details>div a{padding:5px 10px!important;font-size:13px!important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html:not(#cs) body.docs-reader .reader-function-groups details>div a code{font-size:12.5px!important}
html:not(#cs) body.docs-reader .docs-platform-sidebar :is(.docs-platform-sidebar__item,.reader-supplemental a){font-size:14px!important}
html:not(#cs) body.docs-reader .reader-supplemental{margin-top:20px}

/* 6. prev / next */
html:not(#cs) body.docs-reader .docs-api-route{margin-top:40px!important;padding-top:0!important}
html:not(#cs) body.docs-reader .docs-api-route__primary a{font-size:13px;color:rgba(22,22,24,.56)!important;text-decoration:none!important}
html:not(#cs) body.docs-reader .docs-api-route__primary a:hover{color:#161618!important}
html:not(#cs) body.docs-reader .docs-api-route__adjacent{display:grid!important;grid-template-columns:1fr 1fr;gap:12px!important;margin-top:14px}
html:not(#cs) body.docs-reader .docs-api-route__adjacent>span:empty{display:block}
html:not(#cs) body.docs-reader .docs-api-route__adjacent a{display:flex!important;flex-direction:column;gap:2px;padding:14px 18px!important;border:1px solid rgba(22,22,24,.1)!important;border-radius:12px!important;background:#fff!important;box-shadow:none!important;color:#161618!important;font-size:15px;font-weight:600;text-decoration:none!important;transition:border-color .15s}
html:not(#cs) body.docs-reader .docs-api-route__adjacent a[rel=next]{grid-column:2;text-align:right;align-items:flex-end}
html:not(#cs) body.docs-reader .docs-api-route__adjacent a[rel=prev]{grid-column:1}
html:not(#cs) body.docs-reader .docs-api-route__adjacent a:hover{border-color:rgba(22,22,24,.35)!important;box-shadow:none!important}
html:not(#cs) body.docs-reader .docs-api-route__adjacent a>span{font-size:12px;font-weight:500;color:rgba(22,22,24,.5)}
html:not(#cs) body.docs-reader .docs-article-meta{margin-top:40px!important;padding-top:16px!important;font-size:12.5px;color:rgba(22,22,24,.5)}

/* toc */
html:not(#cs) body:is(.docs-reader,.vp-built) .vp-outline-title{font-size:12.5px!important;font-weight:600;color:#161618;margin-bottom:8px}
html:not(#cs) body.docs-reader .docs-toc__title{font-size:0!important;line-height:0!important;margin:0 0 12px!important}
html:not(#cs) body.docs-reader .docs-toc__title::before{content:"本页目录"!important;font-size:12.5px!important;line-height:20px;font-weight:600;color:#161618}
html:not(#cs) body.docs-reader .docs-toc{padding-top:44px!important}
html:not(#cs) body.docs-reader .docs-toc a{font-size:13px}

/* desktop alignment: same top as hub */
@media (min-width:1101px){
  html:not(#cs) body.docs-reader .docs-platform-sidebar{top:calc(var(--header-height) + 40px)!important;margin-top:40px!important;max-height:calc(100vh - var(--header-height) - 40px)!important;padding-top:0!important}
  html:not(#cs) body.docs-reader .reader-nav-search{top:0!important}
  html:not(#cs) body.docs-reader .docs-platform-content-grid{padding-top:40px!important;grid-template-columns:minmax(0,720px) 200px!important;justify-content:space-between}
}

/* 7. mobile */
@media (max-width:1100px){
  html:not(#cs) body.docs-reader .reader-mobile-bar{top:var(--header-height)!important;z-index:20;padding:0 16px!important;background:rgba(255,255,255,.92)!important;backdrop-filter:saturate(1.6) blur(12px);border-bottom:1px solid rgba(22,22,24,.08)!important}
  html:not(#cs) body.docs-reader .reader-mobile-bar button{font-size:14px;color:#161618}
  html:not(#cs) body.docs-reader .docs-platform-content-grid{padding:20px 0 64px!important}
  html:not(#cs) body.docs-reader .docs-platform-main{padding:0 20px!important;left:0!important;width:auto!important}
}
@media (max-width:960px){
  /* hub: sidebar list becomes a compact horizontal chip row instead of a 2-col dump */
  html:not(#cs) body.vp-built .vp-layout{grid-template-columns:minmax(0,1fr)!important}
  html:not(#cs) body.vp-built :is(.vp-sidebar,.vp-content,.vp-aside){min-width:0!important;max-width:100vw}
  html:not(#cs) body.vp-built .vp-sidebar{position:static!important;padding:16px 16px 4px!important;max-height:none!important;overflow:visible!important}
  html:not(#cs) body.vp-built .vp-sidebar :is(.vp-sidebar-title,.vp-sidebar-group){display:none!important}
  html:not(#cs) body.vp-built .vp-sidebar .vp-tree{display:flex!important;flex-wrap:nowrap;gap:6px;overflow-x:auto;scrollbar-width:none;margin:0 -16px;padding:0 16px 8px}
  html:not(#cs) body.vp-built .vp-sidebar .vp-tree::-webkit-scrollbar{display:none}
  html:not(#cs) body.vp-built .vp-sidebar .vp-tree a{flex:0 0 auto;padding:6px 12px!important;border-radius:999px!important;background:#f4f4f6;color:#2c2d33!important;font-size:13px!important;white-space:nowrap}
  html:not(#cs) body.vp-built .vp-sidebar .vp-tree+.vp-sidebar-group+.vp-tree{display:none!important}
  html:not(#cs) body.vp-built .vp-content{padding-top:16px!important}
}
@media (max-width:760px){
  html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc h1,.docs-reader-header h1){font-size:30px!important;line-height:38px!important}
  html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-lead,.reader-intro){font-size:16px!important;line-height:26px!important}
  html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article) h2{margin-top:40px!important;font-size:21px!important;line-height:30px!important}
  html:not(#cs) body:is(.vp-built,.docs-reader) :is(.vp-doc,.docs-article,.api-peek) pre{margin-inline:-20px!important;border-radius:0!important;border-inline:0!important}
  html:not(#cs) body.docs-reader .docs-breadcrumb{display:none!important}
}

html:not(#cs) body.docs-reader .docs-reader-header+h2,html:not(#cs) body.docs-reader .docs-reader-header~h2:first-of-type{margin-top:32px!important}
/* language label on code blocks: keep it clear of the first line */
html:not(#cs) body:is(.vp-built,.docs-reader) pre[data-terminal-title]{padding-top:30px!important;position:relative}
html:not(#cs) body:is(.vp-built,.docs-reader) .docs-article pre::before{content:none!important;display:none!important}
html:not(#cs) body:is(.vp-built,.docs-reader) .docs-article pre[data-terminal-title]::after{content:attr(data-terminal-title)!important;position:absolute!important;top:7px!important;right:14px!important;left:auto!important;transform:none!important;font-size:11px!important;line-height:16px;font-weight:500;color:rgba(22,22,24,.4)!important}

/* 8. learning pages: sidebar list + step diagram */
html:not(#cs) body.docs-reader .docs-platform-sidebar__primary{display:grid!important;gap:1px;margin:0!important;padding:0!important;border:0!important}
html:not(#cs) body.docs-reader .docs-platform-sidebar .docs-platform-sidebar__item{margin:0!important;padding:6px 12px!important;font-size:14px!important;line-height:20px!important}
html:not(#cs) body.docs-reader .reader-supplemental{display:grid;gap:1px;margin:24px 0 0!important;padding:16px 0 0!important;border-top:1px solid rgba(22,22,24,.08)}
html:not(#cs) body.docs-reader .reader-supplemental>span{display:block;padding:0 12px 6px;font-size:12px!important;font-weight:600;color:rgba(22,22,24,.45)!important;letter-spacing:.02em}
html:not(#cs) body.docs-reader .reader-supplemental a{margin:0!important}

html:not(#cs) body.docs-reader .reader-diagram{margin:28px 0!important;padding:22px 24px 8px!important;border:1px solid rgba(22,22,24,.08)!important;border-radius:16px!important;background:#fff!important;box-shadow:none!important}
html:not(#cs) body.docs-reader .reader-diagram figcaption{margin:0 0 8px}
html:not(#cs) body.docs-reader .reader-figure-label{display:block;font-size:12px;font-weight:600;color:rgba(22,22,24,.45);letter-spacing:.04em}
html:not(#cs) body.docs-reader .reader-diagram figcaption strong{display:block;margin:4px 0 4px;font-size:18px;line-height:26px;color:#161618}
html:not(#cs) body.docs-reader .reader-diagram figcaption p{margin:0;font-size:14.5px;color:rgba(22,22,24,.6)}
html:not(#cs) body.docs-reader .reader-diagram-nodes{display:block!important;margin:12px 0 0!important;padding:0!important;list-style:none}
html:not(#cs) body.docs-reader .reader-diagram-nodes>li{display:grid!important;grid-template-columns:32px minmax(0,1fr) auto;grid-template-areas:"n t a" "n p a";column-gap:16px;row-gap:2px;align-items:start;margin:0!important;padding:16px 0!important;border:0!important;border-top:1px solid rgba(22,22,24,.07)!important;background:none!important;box-shadow:none!important;position:relative}
html:not(#cs) body.docs-reader .reader-diagram-nodes>li::before,html:not(#cs) body.docs-reader .reader-diagram-nodes>li::after{content:none!important;display:none!important}
html:not(#cs) body.docs-reader .reader-node-number{grid-area:n;display:grid!important;place-items:center;width:28px!important;height:28px!important;margin:0!important;border:0!important;border-radius:999px;background:#f2f2f4!important;color:#161618!important;font-size:12px!important;font-weight:600;font-variant-numeric:tabular-nums}
html:not(#cs) body.docs-reader .reader-node-number::after,html:not(#cs) body.docs-reader .reader-node-number::before{content:none!important;display:none!important}
html:not(#cs) body.docs-reader .reader-node-title{grid-area:t;margin:3px 0 0!important;font-size:15px!important;line-height:22px;font-weight:600;color:#161618}
html:not(#cs) body.docs-reader .reader-diagram-nodes>li>p{grid-area:p;margin:0!important;font-size:14px!important;line-height:1.65!important;color:rgba(22,22,24,.62)}
html:not(#cs) body.docs-reader .reader-diagram-nodes>li>a{grid-area:a;align-self:center;display:inline-flex!important;align-items:center;gap:2px;white-space:nowrap;padding:6px 10px!important;border-radius:999px;font-size:13px!important;color:#161618!important;text-decoration:none!important;background:#f4f4f6}
html:not(#cs) body.docs-reader .reader-diagram-nodes>li>a:hover{background:#ececef}
html:not(#cs) body.docs-reader .reader-diagram-nodes>li>a .qx-arrow{background:none!important;color:inherit!important;width:14px;height:14px}
@media (max-width:640px){
  html:not(#cs) body.docs-reader .reader-diagram{padding:18px 16px 4px!important}
  html:not(#cs) body.docs-reader .reader-diagram-nodes>li{grid-template-columns:28px minmax(0,1fr);grid-template-areas:"n t" "n p" "n a";column-gap:12px}
  html:not(#cs) body.docs-reader .reader-diagram-nodes>li>a{justify-self:start;margin-top:8px}
}
