/* ============================================================
   优点科技 · 文档中心
   复用 style_7.css 的设计令牌，视觉与全站保持一致
   ============================================================ */

/* ============================================================
   0. 页面骨架：和其它页面一样由 window 滚动
   早先做过「整页锁死 100vh、.page-body 自己滚」的应用式外壳，
   副作用是 html 失去滚动条 —— 而 fixed 导航的初始包含块宽度
   会因此比别的页面多出一个滚动条宽度，右侧「登录 / 注册」整体
   右移，顶部统一组件和全站对不上。这里回退成普通文档流，
   导航宽度、滚动条、sticky 行为与 index / news 完全一致。
   ============================================================ */
body {
    /* style_7.css 在窄屏给 body 加了 padding-top，这里统一交给 .page-body 的 padding-top */
    padding-top: 0 !important;
}
/* 滚动条槽位常驻：文档页有些短文章一屏就放得下（没有纵向滚动条），
   而首页/资讯等长页面一定带滚动条。导航与正文都是「1760 上限 + 居中」，
   有/无滚动条时会差半个滚动条宽（≈7.5px），从别的页面切进来顶部菜单
   看上去就像整体往右跳了一下。这里始终预留槽位，两种情况位置一致。 */
html {
    scrollbar-gutter: stable;
}
.page-body {
    /* 顶部让出固定导航（.nav 是 64px，窄屏 56px） */
    padding-top: 64px;
}

/* 导航栏保持 index.html 的 1200 容器，不做任何覆盖，
   文档内容区也用同一个 1200，两个页面切换时导航不会跳宽度 */
.docs-foot {
    flex: 0 0 auto;
}

/* ============================================================
   1. 两栏骨架（宽度对齐 index.html 的 .container 1200）
   ============================================================ */
.docs-shell {
    display: flex;
    align-items: flex-start;
    /* 不用 gap：TOC 是浮动的、不占流，gap 会让正文右侧多缩一段 */
    gap: 0;
    /* style_6 里有 `.container { width:1200px }`，这里显式 width:auto
       让 max-width 生效，且与 index 的 .container 同宽 */
    width: auto;
    max-width: 1200px;
    margin: 0 auto;
    /* 顶部留 32：和 changelog / news 这些内页一致（它们内容区也是导航下
       再退 34-44 才起），不然首屏面包屑直接贴着导航下沿，像被截了一段。
       这段 padding 只作用于首屏，往下滚时和其它页一样会滚出去 */
    padding: 32px 0 64px;
}

/* 桌面端把内容区放宽到与首页内容区一致（首页 .container 上限 1480），
   1440 视口仍是 1200 不变，1600 / 1920 才逐渐铺开 */
@media (min-width: 1181px) {
    .docs-shell {
        width: calc(100% - 240px);
        max-width: 1480px;
    }
}
/* 宽屏右侧有固定「本页目录」，给目录留出位置，避免正文压上去 */
@media (min-width: 1700px) {
    .docs-shell { width: calc(100vw - 440px); }
}

/* ============================================================
   2. 左侧导航
   ============================================================ */
.docs-aside {
    flex: 0 0 300px;
    position: sticky;
    /* 页面由 window 滚动，吸顶位置要自己让开固定导航的 64px */
    top: 64px;
    /* 容器高 = 100vh - 导航 64，上下各留 24 的空隙 */
    max-height: calc(100vh - 112px);
    min-height: 0;
    /* 侧栏自己滚：内容超出时可随时滚，不必先把鼠标移进来。
       overscroll-behavior 防止滚到底后把滚动链传给整页，手感打滑。 */
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    background: #fff;
    border: 1px solid #E7EDF6;
    border-radius: 18px;
    box-shadow:
        0 1px 2px rgba(15, 23, 42, .04),
        0 16px 40px -20px rgba(15, 23, 42, .14);
}

.docs-aside::-webkit-scrollbar { width: 6px; }
.docs-aside::-webkit-scrollbar-track { background: transparent; }
.docs-aside::-webkit-scrollbar-thumb {
    background: #D6E0EC;
    border-radius: 3px;
    border: 1.5px solid #fff;
}
.docs-aside::-webkit-scrollbar-thumb:hover { background: #B7C7DA; }

.docs-aside__head {
    position: sticky;
    top: 0;
    z-index: 3;
    background: linear-gradient(180deg, #fff 72%, rgba(255, 255, 255, .92) 100%);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 12px 12px 10px;
    border-bottom: 1px solid #EEF3F9;
    border-radius: 18px 18px 0 0;
}

/* 移动端目录折叠按钮：桌面不显示 */
.docs-aside__toggle { display: none; }

/* 搜索框 */
.docs-search {
    position: relative;
    display: flex;
    align-items: center;
}
.docs-search__icon {
    position: absolute;
    left: 11px;
    width: 14px;
    height: 14px;
    color: #9BAEC4;
    pointer-events: none;
    transition: color var(--t-fast) var(--e-out);
}
.docs-search__input {
    width: 100%;
    height: 36px;
    border: 1px solid #E4EBF4;
    border-radius: 10px;
    padding: 0 32px 0 34px;
    font-size: 13.4px;
    color: var(--t-1);
    background: #F7FAFD;
    outline: none;
    transition: background var(--t-fast) var(--e-out),
                border-color var(--t-fast) var(--e-out),
                box-shadow var(--t-fast) var(--e-out);
    -webkit-appearance: none;
    appearance: none;
    font-family: inherit;
}
.docs-search__input::placeholder { color: #9BAEC4; }
.docs-search__input:focus {
    background: #fff;
    border-color: #A8C4ED;
    box-shadow: 0 0 0 3px rgba(37,99,235,.09);
}
.docs-search__input:focus ~ .docs-search__icon,
.docs-search:focus-within .docs-search__icon { color: var(--c-primary); }
.docs-search__input::-webkit-search-cancel-button { display: none; }
.docs-search__clear {
    position: absolute;
    right: 8px;
    width: 17px;
    height: 17px;
    border: none;
    background: #DCE5F0;
    color: #64809E;
    border-radius: 50%;
    font-size: 9px;
    line-height: 1;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: background var(--t-fast);
}
.docs-search__clear.is-show { display: flex; }
.docs-search__clear:hover { background: #C3D1E2; color: var(--t-1); }

/* 树 */
.docs-tree { padding: 8px 8px 12px; }
.docs-tree__list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.docs-tree__list .docs-tree__list {
    display: none;
    padding: 2px 0 7px 13px;
    margin-left: 10px;
    border-left: 1px solid #EDF2F8;
}
.docs-tree__item.is-open > .docs-tree__list {
    display: block;
    animation: treeSlide .22s var(--e-out);
}
@keyframes treeSlide {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}

.docs-tree__row {
    display: flex;
    align-items: flex-start;
    gap: 3px;
    border-radius: 9px;
    position: relative;
    transition: background var(--t-fast) var(--e-out);
}
.docs-tree__row:hover { background: #F4F8FD; }

.docs-tree__toggle {
    flex: 0 0 18px;
    width: 18px;
    height: 32px;
    border: none;
    background: none;
    color: #AFC0D2;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform .22s var(--e-out), color var(--t-fast);
}
.docs-tree__toggle:hover { color: var(--c-primary); }
.docs-tree__item.is-open > .docs-tree__row > .docs-tree__toggle {
    transform: rotate(90deg);
    color: #6F8CAC;
}
.docs-tree__dot {
    flex: 0 0 18px;
    width: 18px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.docs-tree__dot::before {
    content: '';
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #CBD8E6;
    transition: background var(--t-fast), transform var(--t-fast);
}
.docs-tree__row:hover .docs-tree__dot::before {
    background: var(--c-primary);
    transform: scale(1.25);
}

.docs-tree__link {
    flex: 1;
    min-width: 0;
    display: block;
    font-size: 13.8px;
    line-height: 20px;
    color: var(--t-2);
    text-decoration: none;
    padding: 6px 8px 6px 2px;
    transition: color var(--t-fast) var(--e-out);
    word-break: break-word;
}
.docs-tree__link:hover { color: var(--c-primary); }

/* 有子项的分类：整行就是展开/收起开关，不再需要瞄准小箭头 */
.docs-tree__link--group { cursor: pointer; }
.docs-tree__link--overview { color: #64748B; }
.docs-tree__link--overview:hover { color: var(--c-primary); }

/* 一级分类用 <button> 实现，抹掉浏览器默认外观 */
button.docs-tree__link {
    border: none;
    background: none;
    font-family: inherit;
    text-align: left;
    -webkit-appearance: none;
    appearance: none;
}
/* 点它只是展开/收起，不需要焦点框；键盘 Tab 到时用整行底色提示 */
.docs-tree__link--group:focus,
.docs-tree__link--group:focus-visible {
    outline: none;
    box-shadow: none;
}
.docs-tree__item > .docs-tree__row:has(> .docs-tree__link--group:focus-visible) {
    background: #EAF2FE;
}

/* 一级目录 */
.docs-tree__list--root > .docs-tree__item { margin-bottom: 2px; }
.docs-tree__list--root > .docs-tree__item > .docs-tree__row {
    min-height: 42px;
}
.docs-tree__list--root > .docs-tree__item > .docs-tree__row > .docs-tree__link {
    font-size: 15px;
    font-weight: 650;
    color: #1E3249;
    line-height: 22px;
    padding-top: 10px;
    padding-bottom: 10px;
    letter-spacing: -.15px;
}
.docs-tree__list--root > .docs-tree__item > .docs-tree__row > .docs-tree__toggle {
    height: 42px;
}
.docs-tree__list--root > .docs-tree__item.is-open > .docs-tree__row > .docs-tree__link {
    color: #1D4ED8;
}
.docs-tree__list--root > .docs-tree__item.is-open > .docs-tree__row {
    background: #F7FAFE;
}

/* 当前项 */
.docs-tree__link.is-active {
    color: #1D4ED8;
    font-weight: 700;
}
.docs-tree__row:has(> .docs-tree__link.is-active) {
    background: linear-gradient(92deg, #E9F2FE 0%, #F3F8FF 100%);
}
.docs-tree__row:has(> .docs-tree__link.is-active)::before {
    content: '';
    position: absolute;
    left: 0;
    top: 4px;
    bottom: 4px;
    width: 3px;
    border-radius: 0 3px 3px 0;
    background: linear-gradient(180deg, #2563EB, #0891B2);
    box-shadow: 0 0 8px rgba(37, 99, 235, .4);
}
.docs-tree__row:has(> .docs-tree__link.is-active) .docs-tree__dot::before {
    background: var(--c-primary);
}
/* 一级分类同时命中当前页时不再重复画左侧竖条（子项「概览」已经有一条） */
.docs-tree__list--root > .docs-tree__item > .docs-tree__row:has(> .docs-tree__link.is-active)::before {
    display: none;
}

/* 搜索无结果 */
.docs-empty {
    padding: 34px 16px 40px;
    text-align: center;
    font-size: 13px;
    color: var(--t-3);
    line-height: 1.9;
}
.docs-empty span { font-size: 12px; color: #9BAEC4; }

/* ============================================================
   3. 右侧正文区
   ============================================================ */
.docs-main {
    flex: 1;
    min-width: 0;
    margin-left: 40px;
    /* 宽度交给 .docs-shell 控制（对齐首页内容区），这里不再单独限宽，
       否则大屏下正文会比首页那排卡片窄一大截 */
    max-width: none;
    min-height: calc(100vh - 280px);
}

/* 欢迎页与卡片墙已移除：进文档区直接显示第一篇，相关样式一并删掉 */

/* ---------- 文章 ---------- */
.docs-article { min-height: 400px; }

/* 文档头（面包屑 + 标题 + 更新时间 + 分享操作）：**不吸顶**，跟着正文一起滚走。
   试过钉在滚动容器顶部，但正文从它下沿穿过去时总要在边界上切掉半行字，
   怎么调底色 / 裙边都像「内容从标题里透出来」。干脆不做吸顶：
   标题、更新时间滚出视野后，正文占满整个可视高度，最干净。
   标题下那条阅读进度线也一起滚走，它只在文档顶端可见。 */
.docs-head {
    position: relative;
    /* 底色写死：不依赖变量 / 主题切换，永远不透明 */
    background-color: #fff;
    padding-bottom: 14px;
}
/* 标题下有装饰线时不需要再收起：is-stuck 只在滚动后短暂存在，
   现在已经不吸顶，保留这条规则只为兼容旧状态类，视觉无影响 */
.docs-head.is-stuck .docs-title { border-bottom-color: transparent; }

@media (max-width: 768px) {
    /* 窄屏导航是 56px 高 */
    .page-body { padding-top: 56px; }
}

.docs-crumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
    font-size: 12.3px;
    color: #93A6BC;
    margin-bottom: 13px;
    line-height: 1.65;
}
.docs-crumb a {
    color: #7E93AC;
    text-decoration: none;
    transition: color var(--t-fast);
}
.docs-crumb a:hover { color: var(--c-primary); }
.docs-crumb i {
    font-style: normal;
    color: #C6D4E4;
    font-size: 11px;
}
.docs-crumb span { color: #7E93AC; }
.docs-crumb span:last-child { color: #1E3249; font-weight: 600; }

.docs-title {
    font-size: 34px;
    font-weight: 800;
    color: #0F2035;
    line-height: 1.3;
    margin: 0 0 28px;
    letter-spacing: -.9px;
    padding-bottom: 22px;
    /* 右侧给「手机预览 / 分享本页」两个按钮让位，长标题不会压到按钮上 */
    padding-right: 224px;
    border-bottom: 1px solid #EDF2F8;
    position: relative;
    /* 吸顶时这条线要收起（见第 3 节 is-stuck），过渡一下不跳 */
    transition: border-bottom-color .18s var(--e-out);
}
/* 标题右上角操作区：手机预览（二维码）+ 分享本页（复制链接） */
.docs-actions {
    position: absolute;
    right: 0;
    top: 2px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.docs-share {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 32px;
    padding: 0 13px;
    border: 1px solid #DCE6F2;
    border-radius: 9px;
    background: #fff;
    color: #4C6A8A;
    font-size: 12.8px;
    font-weight: 600;
    font-family: inherit;
    line-height: 1;
    cursor: pointer;
    transition: border-color .18s, color .18s, background .18s, box-shadow .18s;
}
.docs-share svg { width: 14px; height: 14px; flex: 0 0 14px; }
.docs-share:hover {
    border-color: #2563EB;
    color: #2563EB;
    background: #F5F9FF;
    box-shadow: 0 2px 8px rgba(37, 99, 235, .12);
}
.docs-share:active { transform: translateY(1px); }

/* 正文里的《文档名》自动变成可跳转链接 */
.docs-body .doc-doclink {
    color: #2563EB;
    text-decoration: none;
    border-bottom: 1px dashed rgba(37, 99, 235, .45);
    transition: color .15s, border-bottom-color .15s;
}
.docs-body .doc-doclink:hover {
    color: #1D4ED8;
    border-bottom-style: solid;
}

/* 文档更新时间：标题下方一行小字，全站统一时间 */
.docs-updated {
    display: flex;
    align-items: center;
    gap: 6px;
    /* 下间距交给 .docs-head 的 padding-bottom，进度条才不会压在时间文字上 */
    margin: -16px 0 0;
    font-size: 12.5px;
    color: #9BAEC4;
    letter-spacing: .2px;
}
.docs-updated svg {
    width: 14px;
    height: 14px;
    flex: 0 0 14px;
}

/* ============================================================
   4. Markdown 正文排版
   ============================================================ */
.docs-body {
    font-size: 16px;
    color: #3D5169;
    line-height: 1.95;
    word-wrap: break-word;
}
.docs-body > *:first-child { margin-top: 0; }
.docs-body > *:last-child { margin-bottom: 0; }

.docs-body p {
    margin: 0 0 13px;
    word-break: break-word;
}
.docs-body strong { color: var(--t-1); font-weight: 700; }
/* 整行加粗 = 源文档里没设标题样式时的小标题写法（飞书里很常见），
   统一补一点上间距，否则和下面的正文挤在一起看不出层级。
   只用样式统一，不升级成标题，避免 FAQ 类文档的问题行把目录撑爆 */
.docs-body p:has(> strong:only-child) {
    margin: 20px 0 9px;
    line-height: 1.7;
}
.docs-body em { font-style: italic; }
.docs-body del { color: #93A6BC; text-decoration-thickness: 1px; }

.docs-body a {
    color: var(--c-primary);
    text-decoration: none;
    border-bottom: 1px solid rgba(37,99,235,.22);
    transition: border-color var(--t-fast), color var(--t-fast);
    word-break: break-all;
}
.docs-body a:hover {
    border-bottom-color: var(--c-primary);
    color: #1D4ED8;
}

.docs-body code {
    background: #F1F5FB;
    color: #1D4ED8;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: .87em;
    padding: 1.5px 5px;
    border-radius: 4px;
    word-break: break-all;
    border: 1px solid #E5EDF7;
}

/* 标题 */
.docs-body .doc-h1,
.docs-body .doc-h2,
.docs-body .doc-h3,
.docs-body .doc-h4,
.docs-body .doc-h5,
.docs-body .doc-h6 {
    color: var(--t-1);
    font-weight: 700;
    line-height: 1.45;
    /* 固定导航 + 吸顶文档头的总高度，由 docs-app.js 写入 --docs-anchor-offset；
       直接打开 #h-2-1 这类原生锚点链接时，标题也能让开吸顶头部 */
    scroll-margin-top: var(--docs-anchor-offset, 78px);
}
.docs-body .doc-h2 {
    font-size: 22px;
    margin: 44px 0 16px;
    padding-left: 15px;
    letter-spacing: -.4px;
    position: relative;
    color: #0F2035;
}
.docs-body .doc-h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: .18em;
    bottom: .18em;
    width: 3.5px;
    border-radius: 3px;
    background: linear-gradient(180deg, #2563EB, #06B6D4);
}
.docs-body .doc-h3 {
    font-size: 18px;
    margin: 34px 0 13px;
    color: #1D4ED8;
    letter-spacing: -.2px;
}
.docs-body .doc-h4 {
    font-size: 16.4px;
    margin: 26px 0 11px;
    color: #2C4260;
}
.docs-body .doc-h5,
.docs-body .doc-h6 {
    font-size: 14.6px;
    margin: 19px 0 8px;
    color: var(--t-2);
}

/* 首个标题贴近顶部，避免上方留白过大 */
.docs-body > .doc-h2:first-child,
.docs-body > .doc-h3:first-child { margin-top: 4px; }

/* 源文档列表不闭合时，伪标题段落会被塞进 <li> 里，
   升级成标题后要拉回到正文左边缘，否则会缩进在编号列表中间 */
.docs-body li > .doc-h2,
.docs-body li > .doc-h3 {
    margin-left: -21px;
    margin-top: 30px;
}

/* 列表 */
.docs-body .doc-ul,
.docs-body .doc-ol {
    margin: 0 0 14px;
    padding-left: 21px;
}
.docs-body .doc-ul li,
.docs-body .doc-ol li {
    margin-bottom: 6px;
    line-height: 1.82;
    word-break: break-word;
}
.docs-body .doc-ul li:last-child,
.docs-body .doc-ol li:last-child { margin-bottom: 0; }

.docs-body .doc-ul {
    list-style: none;
    padding-left: 5px;
}
.docs-body .doc-ul > li {
    position: relative;
    padding-left: 17px;
}
.docs-body .doc-ul > li::before {
    content: '';
    position: absolute;
    left: 4px;
    top: .8em;
    width: 4.5px;
    height: 4.5px;
    border-radius: 50%;
    background: #93B4DC;
}
/* style_3.css 有全局 `li, ul { list-style: none }`，这里必须显式提高优先级覆盖 */
.docs-body .doc-ol {
    list-style: decimal outside;
    padding-left: 23px;
}
.docs-body .doc-ol > li {
    list-style: decimal outside;
    display: list-item;
}
.docs-body .doc-ol > li::marker {
    color: var(--c-primary);
    font-weight: 700;
    font-size: .95em;
    font-variant-numeric: tabular-nums;
}

/* 待办 */
.docs-body .doc-todo {
    list-style: none;
    position: relative;
    padding-left: 23px;
}
.docs-body .doc-todo__box {
    position: absolute;
    left: 2px;
    top: .36em;
    width: 13px;
    height: 13px;
    border: 1.5px solid #C6D4E4;
    border-radius: 3.5px;
    background: #fff;
}
.docs-body .doc-todo.is-done .doc-todo__box {
    background: var(--c-primary);
    border-color: var(--c-primary);
}
.docs-body .doc-todo.is-done .doc-todo__box::after {
    content: '';
    position: absolute;
    left: 3px;
    top: .5px;
    width: 4px;
    height: 6.5px;
    border: solid #fff;
    border-width: 0 1.8px 1.8px 0;
    transform: rotate(45deg);
}

/* 引用 */
.docs-body .doc-quote {
    margin: 20px 0;
    padding: 15px 19px;
    background: linear-gradient(96deg, #F5FAFF 0%, #FAFCFF 100%);
    border-left: 3.5px solid #60A5FA;
    border-radius: 0 11px 11px 0;
    color: #40566E;
    position: relative;
}
.docs-body .doc-quote p { margin: 0; }
.docs-body .doc-quote p + p { margin-top: 10px; }

/* 分割线 */
.docs-body .doc-hr {
    border: none;
    height: 1px;
    background: linear-gradient(90deg, #E4ECF6, #F0F5FB 60%, transparent);
    margin: 32px 0;
}

/* 代码块 */
.docs-body .doc-pre {
    margin: 20px 0;
    padding: 16px 18px;
    position: relative;
    background: linear-gradient(160deg, #101E33 0%, #0B1626 100%);
    border-radius: 12px;
    overflow-x: auto;
    line-height: 1.75;
    border: 1px solid rgba(148, 197, 255, .12);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .06),
        0 8px 24px -12px rgba(15, 23, 42, .38);
}
.docs-body .doc-pre code {
    background: none;
    color: #D8E4F2;
    padding: 0;
    font-size: 13px;
    border-radius: 0;
    border: none;
    white-space: pre;
    word-break: normal;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
}
/* 语法高亮（配色由 js/docs-app.js 的 tokenizer 输出，暗底下的对比度已校过） */
.docs-body .doc-pre .tok-com { color: #6F8AA8; font-style: italic; }
.docs-body .doc-pre .tok-str { color: #A8E6A3; }
.docs-body .doc-pre .tok-var { color: #FFCB6B; }
.docs-body .doc-pre .tok-num { color: #F79A6B; }
.docs-body .doc-pre .tok-kw { color: #82AAFF; font-weight: 600; }

.docs-body .doc-pre::-webkit-scrollbar { height: 7px; }
.docs-body .doc-pre::-webkit-scrollbar-track { background: rgba(255, 255, 255, .04); border-radius: 4px; }
.docs-body .doc-pre::-webkit-scrollbar-thumb {
    background: rgba(148, 197, 255, .28);
    border-radius: 4px;
}
.docs-body .doc-pre::-webkit-scrollbar-thumb:hover { background: rgba(148, 197, 255, .45); }

/* 表格 */
.doc-table-wrap {
    margin: 20px 0;
    overflow-x: auto;
    border: 1px solid #E4ECF6;
    border-radius: 12px;
    box-shadow: 0 2px 10px -4px rgba(15, 23, 42, .07);
    -webkit-overflow-scrolling: touch;
}
.doc-table-wrap::-webkit-scrollbar { height: 6px; }
.doc-table-wrap::-webkit-scrollbar-thumb { background: #D6E0EC; border-radius: 3px; }

.docs-body .doc-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.4px;
    background: #fff;
    min-width: 420px;
}
.docs-body .doc-table th {
    background: linear-gradient(180deg, #F5F9FE, #EFF5FC);
    color: #1E3249;
    font-weight: 700;
    font-size: 12.9px;
    text-align: left;
    padding: 11px 15px;
    border-bottom: 1px solid #E2EAF4;
    white-space: nowrap;
    letter-spacing: .2px;
}
.docs-body .doc-table td {
    padding: 11px 15px;
    color: #465C74;
    border-bottom: 1px solid #F1F6FB;
    line-height: 1.78;
    vertical-align: top;
}
.docs-body .doc-table tbody tr:last-child td { border-bottom: none; }
.docs-body .doc-table tbody tr {
    transition: background .16s var(--e-out);
}
.docs-body .doc-table tbody tr:hover td { background: #F8FBFF; }

/* 图片占位 */
.doc-figure { margin: 22px 0; }

/* 真实截图 */
.docs-body .doc-figure img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0 auto;
    border-radius: 11px;
    border: 1px solid #E3EBF5;
    background: #F7FAFD;
    box-shadow:
        0 2px 8px -2px rgba(15, 23, 42, .07),
        0 10px 30px -18px rgba(15, 23, 42, .18);
    transition: box-shadow .24s var(--e-out), transform .24s var(--e-out);
}
.docs-body .doc-figure img:hover {
    box-shadow:
        0 4px 12px -2px rgba(15, 23, 42, .1),
        0 16px 40px -20px rgba(15, 23, 42, .26);
    transform: translateY(-1px);
}
.docs-body .doc-figure img[loading] { content-visibility: auto; }
.doc-figure__ph {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 1.5px dashed #D5E0EE;
    background: linear-gradient(180deg, #FAFCFF 0%, #F5F9FD 100%);
    border-radius: 11px;
    padding: 28px 20px;
    transition: border-color var(--t-fast) var(--e-out),
                background var(--t-fast) var(--e-out);
}
.doc-figure__ph:hover {
    border-color: #A8C4ED;
    background: linear-gradient(180deg, #F8FBFF 0%, #EFF6FF 100%);
}
.doc-figure__icon {
    font-size: 20px;
    opacity: .35;
    line-height: 1;
}
.doc-figure__text {
    font-size: 12.5px;
    color: #7E93AC;
}
.doc-figure__token {
    font-size: 10.5px;
    color: #A9BACD;
    background: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid #E8EEF6;
    font-family: 'SFMono-Regular', Consolas, monospace;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 空文档提示 */
.doc-empty {
    padding: 38px 24px;
    text-align: center;
    font-size: 13.8px;
    color: #7E93AC;
    background: #F9FBFE;
    border: 1px dashed #DCE5F0;
    border-radius: 11px;
}

/* ============================================================
   5. 上一篇 / 下一篇
   ============================================================ */
.docs-pager {
    display: flex;
    gap: 14px;
    margin-top: 52px;
    padding-top: 28px;
    border-top: 1px solid #EDF2F8;
}
.docs-pager__placeholder { flex: 1; }
.docs-pager__item {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 15px 19px;
    background: #fff;
    border: 1px solid #E7EDF6;
    border-radius: 12px;
    text-decoration: none;
    transition: transform .2s var(--e-out),
                border-color .2s var(--e-out),
                box-shadow .2s var(--e-out);
    min-width: 0;
    position: relative;
}
.docs-pager__item:hover {
    border-color: #C5D9F2;
    box-shadow: 0 8px 22px -10px rgba(37, 99, 235, .24);
    transform: translateY(-2px);
}
.docs-pager__item--next {
    text-align: right;
    align-items: flex-end;
}
.docs-pager__label {
    font-size: 11.5px;
    color: #93A6BC;
    letter-spacing: .35px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.docs-pager__item--prev .docs-pager__label::before {
    content: '←';
    font-size: 12px;
    opacity: .6;
    transition: transform .2s var(--e-out);
}
.docs-pager__item--next .docs-pager__label::after {
    content: '→';
    font-size: 12px;
    opacity: .6;
    transition: transform .2s var(--e-out);
}
.docs-pager__item--prev:hover .docs-pager__label::before { transform: translateX(-3px); opacity: 1; }
.docs-pager__item--next:hover .docs-pager__label::after { transform: translateX(3px); opacity: 1; }
.docs-pager__title {
    font-size: 14px;
    font-weight: 650;
    color: #1E3249;
    line-height: 1.45;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
    transition: color .2s var(--e-out);
}
.docs-pager__item:hover .docs-pager__title { color: #1D4ED8; }

/* ============================================================
   6. 响应式
   ============================================================ */
/* style_3.css 给 body 设了 min-width:1200px，
   769–1199px 区间整页会横向滚动，文档页需要按视口自适应 */
@media (max-width: 1199px) {
    body { min-width: 0; }
    /* 页脚 4 列在 769–1199px 放不下会把页面撑出横向滚动条 */
    .footer_flex { flex-wrap: wrap; }
    .footer .wrapper { min-width: 0; }
}

@media (max-width: 1180px) {
    .docs-shell {
        gap: 0;
        padding: 28px 20px 64px;
    }
    .docs-aside { flex: 0 0 270px; }
    .docs-main { margin-left: 28px; }
}

@media (max-width: 980px) {
    .docs-shell {
        flex-direction: column;
        /* 单栏时必须横向撑满，否则 align-items:flex-start 会让正文
           收缩成内容宽度（平板尺寸下正文只剩一半宽） */
        align-items: stretch;
        gap: 18px;
        padding: 24px 16px 56px;
    }
    /* 单栏时正文只剩 shell 的 20px 内边距，头部如果也同宽，又像标题
       被正文左右裁掉了两侧；把它出血到视口两端，内容位置不变 */
    .docs-head {
        width: auto;
        margin-left: -20px;
        margin-right: -20px;
        padding-left: 20px;
        padding-right: 20px;
    }
    /* 出血后左右各溢出一点，裁掉，别撑出横向滚动条 */
    html,
    body { overflow-x: clip; }
    /* 单栏下不能再留横向外边距，否则正文左右各缩一段 */
    .docs-main { margin-left: 0; }
    /* 移动端：目录默认收起，点「目录」展开。
       折叠条本身固定在顶部，展开的树盖在正文上（下拉菜单式） */
    .docs-aside {
        position: sticky;
        /* 吸在窄屏导航（56px）下沿 */
        top: 56px;
        z-index: 32;
        flex: none;
        width: 100%;
        max-height: none;
        min-height: 0;
        overflow: visible;
        border-radius: 14px;
    }
    /* 折叠条不做内部滚动，展开的树自己有 max-height */
    .docs-aside:hover { overflow: visible; }
    .docs-aside__head {
        position: static;
        padding: 11px 12px;
        border-bottom: none;
        border-radius: 14px;
        display: flex;
        align-items: center;
        gap: 10px;
    }
    .docs-search { flex: 1; min-width: 0; }
    .docs-aside__toggle {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        flex: 0 0 auto;
        height: 34px;
        padding: 0 12px;
        border: 1px solid #E4EBF4;
        background: #F7FAFD;
        border-radius: 9px;
        font-size: 13px;
        font-weight: 600;
        color: #40566E;
        cursor: pointer;
        font-family: inherit;
        transition: background .18s var(--e-out), border-color .18s var(--e-out);
    }
    .docs-aside__toggle svg {
        width: 14px;
        height: 14px;
        transition: transform .22s var(--e-out);
    }
    .docs-aside__toggle:active { background: #EEF4FC; }
    .docs-aside.is-open .docs-aside__toggle {
        background: #E9F2FE;
        border-color: #BFD9F5;
        color: #1D4ED8;
    }
    .docs-aside.is-open .docs-aside__toggle svg { transform: rotate(180deg); }

    /* 收起时不占高度 */
    .docs-tree,
    .docs-empty,
    .docs-results {
        display: none;
    }
    .docs-aside.is-open .docs-tree,
    .docs-aside.is-searching .docs-results,
    .docs-aside.is-searching .docs-empty {
        display: block;
        max-height: 56vh;
        overflow-y: auto;
        overscroll-behavior: contain;
        border-top: 1px solid #EEF3F9;
        -webkit-overflow-scrolling: touch;
    }
    /* 检索命中时结果必须可见：原来目录收起时结果被 display:none 吃掉，
       移动端输入关键词后页面毫无反应（本次修复的 bug） */
    .docs-aside.is-searching .docs-tree { display: none; }

    .docs-main {
        max-width: 100%;
        min-height: 0;
    }

    .docs-updated { margin: -10px 0 0; font-size: 12px; }
    /* 移动端两个按钮只留图标，给标题腾地方 */
    .docs-actions { top: 4px; gap: 6px; }
    .docs-share { height: 28px; padding: 0 8px; }
    .docs-share span { display: none; }
    .docs-title {
        font-size: 24px;
        margin-bottom: 19px;
        padding-bottom: 15px;
        padding-right: 92px;
        letter-spacing: -.4px;
    }
    .docs-body { font-size: 15px; line-height: 1.88; }
    .docs-body .doc-h2 { font-size: 18.5px; margin: 28px 0 12px; }
    .docs-body .doc-h3 { font-size: 16.2px; margin: 22px 0 10px; }
    .docs-body .doc-pre { padding: 12px 14px; border-radius: 9px; }
    .docs-body .doc-pre code { font-size: 11.8px; }
    .docs-body .doc-table { font-size: 12.8px; min-width: 380px; }
    .docs-body .doc-table th,
    .docs-body .doc-table td { padding: 9px 12px; }

    .docs-pager {
        flex-direction: column;
        gap: 9px;
        margin-top: 34px;
        padding-top: 18px;
    }
    .docs-pager__placeholder { display: none; }
    .docs-pager__item--next {
        text-align: left;
        align-items: flex-start;
    }
}

/* style_7.css 在 ≤768px 时给 body 加了 56px 顶部让位，
   同时用 !important 把 .container 的 padding 压成 0，
   这里必须同步抵消，否则顶部会出现约一屏导航高度的空白 */
@media (max-width: 768px) {
    .container.docs-shell { padding: 20px 16px 56px !important; }
    /* 这个断点 shell 内边距是 16px，头部出血量跟着改 */
    .docs-head {
        margin-left: -16px;
        margin-right: -16px;
        padding-left: 16px;
        padding-right: 16px;
    }
}

@media (max-width: 480px) {
    .docs-body { font-size: 14px; }
    .docs-title { font-size: 19.5px; }
}

/* ============================================================
   7. 搜索结果面板
   原实现只是把左侧树过滤一遍：没有摘要、没有命中高亮，
   且清空搜索后 is-open 状态残留。这里改为标准的结果列表
   （对标 DocSearch / MkDocs Material search）
   ============================================================ */
.docs-results { padding: 8px 8px 12px; }
.docs-results[hidden] { display: none !important; }
.docs-results__meta {
    font-size: 11.6px;
    color: #93A6BC;
    padding: 2px 7px 9px;
    margin-bottom: 5px;
    border-bottom: 1px solid #EEF3F9;
}
.docs-results__meta b { color: #1D4ED8; font-weight: 700; }
.docs-results__list { list-style: none; margin: 0; padding: 0; }
.docs-results__item { border-radius: 8px; margin-bottom: 2px; }
.docs-results__item.is-active { background: #EEF5FE; }
.docs-results__link { display: block; padding: 7px 8px; text-decoration: none; }
.docs-results__title {
    display: block;
    font-size: 13.2px;
    font-weight: 600;
    color: #1E3249;
    line-height: 1.5;
    word-break: break-word;
}
.docs-results__item.is-active .docs-results__title { color: #1D4ED8; }
.docs-results__path {
    display: block;
    font-size: 11px;
    color: #9BAEC4;
    margin-top: 2px;
}
.docs-results__snippet {
    display: block;
    font-size: 11.8px;
    color: #64748B;
    line-height: 1.62;
    margin-top: 4px;
    word-break: break-word;
}
.docs-results mark {
    background: #FEF3C7;
    color: #B45309;
    padding: 0 2px;
    border-radius: 3px;
    font-weight: 600;
}

/* ============================================================
   8. 右侧本页目录（对标 VitePress outline / MkDocs toc.follow）
   正文 h2/h3 本来就有 id，但一直没有出口，只能靠滚动找
   ============================================================ */
/* 内容区固定 1200（与 index 一致），本页目录改为浮动在右侧留白里，
   不占正文宽度；留白不够宽时直接隐藏 */
.docs-toc {
    display: none;
    position: fixed;
    /* 它是 fixed（相对视口），起点 = 导航 64 + 24。文档头已经不吸顶，
       不用再躲标题那一块；这里写死，别跟锚点让位变量绑在一起 */
    top: 88px;
    right: 24px;
    /* 纯文字、没有底色，浮在右侧留白里，压在正文上沿也不影响阅读 */
    z-index: 31;
    width: 200px;
    max-height: calc(100vh - 128px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 4px 4px 8px 0;
}
@media (min-width: 1700px) {
    .docs-toc:not([hidden]) { display: block; }
}
.docs-toc[hidden] { display: none !important; }
.docs-toc::-webkit-scrollbar { width: 5px; }
.docs-toc::-webkit-scrollbar-thumb { background: #E1E9F3; border-radius: 3px; }
.docs-toc__title {
    font-size: 12px;
    font-weight: 700;
    color: #1E3249;
    letter-spacing: .3px;
    margin-bottom: 9px;
    padding-left: 13px;
}
.docs-toc__list {
    list-style: none;
    margin: 0;
    padding: 0;
    border-left: 1px solid #EDF2F8;
}
.docs-toc__link {
    display: block;
    font-size: 12.6px;
    line-height: 1.55;
    color: #7E93AC;
    text-decoration: none;
    padding: 5px 8px 5px 12px;
    margin-left: -1px;
    border-left: 2px solid transparent;
    transition: color .16s var(--e-out), border-color .16s var(--e-out);
    word-break: break-word;
}
.docs-toc__link:hover { color: #1D4ED8; }
.docs-toc__item.is-active > .docs-toc__link {
    color: #1D4ED8;
    font-weight: 650;
    border-left-color: #2563EB;
}
.docs-toc__item--sub > .docs-toc__link { padding-left: 22px; font-size: 12.2px; }
/* h4 及更深的小节再缩进一档（源文档常用 #### 分节） */
.docs-toc__item--sub2 > .docs-toc__link { padding-left: 32px; font-size: 12px; color: #8B9FB7; }



/* ============================================================
   9. 代码块复制按钮（原来 14 个代码块全无复制入口）
   ============================================================ */
.doc-pre-wrap { position: relative; margin: 20px 0; }
.doc-pre-wrap > .doc-pre { margin: 0; }
.doc-copy {
    position: absolute;
    top: 7px;
    right: 7px;
    height: 25px;
    padding: 0 9px;
    font-size: 11.5px;
    font-family: inherit;
    color: #A9C4E4;
    background: rgba(148, 197, 255, .12);
    border: 1px solid rgba(148, 197, 255, .2);
    border-radius: 6px;
    cursor: pointer;
    opacity: 0;
    transition: opacity .16s var(--e-out), background .16s var(--e-out), color .16s var(--e-out);
}
.doc-pre-wrap:hover .doc-copy,
.doc-copy:focus-visible { opacity: 1; }
.doc-copy:hover { background: rgba(148, 197, 255, .24); color: #E2EEFF; }
.doc-copy.is-done {
    color: #86EFAC;
    border-color: rgba(134, 239, 172, .38);
    background: rgba(34, 197, 94, .16);
}
@media (hover: none) {
    .doc-copy { opacity: 1; }
}

/* ============================================================
   9.1 协议文档「复制全文」工具条
   后台「内容页面管理」存的是 HTML，所以 HTML 与纯文本各给一个入口
   ============================================================ */
.doc-copytool {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin: 4px 0 22px;
    padding: 12px 16px;
    background: linear-gradient(180deg, #F5F8FF, #FDFEFF);
    border: 1px solid #DCE7FA;
    border-radius: 12px;
}
.doc-copytool__tip {
    flex: 1 1 240px;
    font-size: 13px;
    line-height: 1.6;
    color: #5B6B80;
}
.doc-copytool__btn {
    height: 32px;
    padding: 0 14px;
    font-family: inherit;
    font-size: 13px;
    color: #1D4ED8;
    background: #fff;
    border: 1px solid #C7D9F7;
    border-radius: 8px;
    cursor: pointer;
    transition: background .16s var(--e-out), color .16s var(--e-out), border-color .16s var(--e-out);
}
.doc-copytool__btn:hover { background: #2563EB; border-color: #2563EB; color: #fff; }
.doc-copytool__btn.is-done {
    color: #15803D;
    background: #E8F8EE;
    border-color: #86EFAC;
}
html[data-docs-theme="dark"] .doc-copytool {
    background: linear-gradient(180deg, #16233A, #131C2E);
    border-color: #2A3A55;
}
html[data-docs-theme="dark"] .doc-copytool__tip { color: #9DB0C8; }
html[data-docs-theme="dark"] .doc-copytool__btn {
    color: #9EC5FF;
    background: transparent;
    border-color: #2F4467;
}
html[data-docs-theme="dark"] .doc-copytool__btn:hover {
    color: #fff;
    background: #2563EB;
    border-color: #2563EB;
}

/* ============================================================
   10. 图片灯箱（112 张控制台截图，不可放大基本看不清）
   ============================================================ */
.docs-body img.is-zoomable { cursor: zoom-in; }
.docs-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 24px;
    background: rgba(8, 15, 26, .9);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    cursor: zoom-out;
    opacity: 0;
    transition: opacity .18s var(--e-out);
}
.docs-lightbox.is-show { opacity: 1; }
.docs-lightbox[hidden] { display: none !important; }
.docs-lightbox__img {
    max-width: 100%;
    max-height: calc(100vh - 108px);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 64px -20px rgba(0, 0, 0, .65);
    cursor: default;
}
.docs-lightbox__close {
    position: absolute;
    top: 16px;
    right: 18px;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, .14);
    color: #fff;
    font-size: 15px;
    line-height: 1;
    cursor: pointer;
    transition: background .16s var(--e-out);
}
.docs-lightbox__close:hover { background: rgba(255, 255, 255, .26); }
.docs-lightbox__hint {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 16px;
    text-align: center;
    font-size: 12px;
    color: rgba(255, 255, 255, .55);
}

/* ============================================================
   11. 阅读进度 / 回到顶部
   ============================================================ */
/* 进度条不再固定在整个视口顶部（原来会压在顶部导航上），
   改为吸顶文档头的下边线：跟着标题一起钉住，位置不跳。
   头部和正文的分界就由它自己承担 —— 全页只有这一条线：
   轨道（浅蓝灰）常显当分界线，滚动时左段被彩色进度覆盖。
   宽度跟头部一样就是正文列，左右两端和标题对齐，不另外往两边伸 */
.docs-progress {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    z-index: 1;
    pointer-events: none;
    background: #DDE7F3;
    border-radius: 2px;
    overflow: hidden;
}
/* 还没吸顶时头部就在文档流里，用不上这条分界线（标题下已有装饰线）；
   吸住的那一下才让它出现，页面上始终只有「一组」线 */
.docs-head:not(.is-stuck) .docs-progress { background: transparent; }
.docs-progress i {
    display: block;
    height: 100%;
    width: 0;
    border-radius: 2px;
    background: linear-gradient(90deg, #2563EB, #06B6D4);
    box-shadow: 0 0 10px rgba(37, 99, 235, .45);
    transition: width .12s linear;
}

.docs-gotop {
    position: fixed;
    right: 26px;
    bottom: 34px;
    z-index: 60;
    width: 42px;
    height: 42px;
    border: 1px solid #E1EAF5;
    border-radius: 50%;
    background: #fff;
    color: #465C74;
    box-shadow: 0 8px 24px -10px rgba(15, 23, 42, .26);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .2s var(--e-out), transform .2s var(--e-out),
                visibility .2s var(--e-out), border-color .2s var(--e-out);
}
.docs-gotop.is-show { opacity: 1; visibility: visible; transform: none; }
.docs-gotop:hover { border-color: #BFD9F5; color: #1D4ED8; }
.docs-gotop svg { width: 18px; height: 18px; }

@media (max-width: 980px) {
    /* 上移一点，避免滚动到底时压住页脚的备案号 */
    .docs-gotop { right: 14px; bottom: 76px; width: 38px; height: 38px; }
}

/* ============================================================
   12. 提示条 / 标题锚点 / 定位高亮
   ============================================================ */
.docs-notice {
    margin: 0 0 18px;
    padding: 11px 15px;
    font-size: 13px;
    line-height: 1.7;
    color: #1D4ED8;
    background: linear-gradient(96deg, #EFF6FF, #F8FBFF);
    border: 1px solid #D8E6FA;
    border-left: 3px solid #2563EB;
    border-radius: 0 9px 9px 0;
}
.docs-notice--warn {
    color: #B45309;
    background: linear-gradient(96deg, #FFFBEB, #FFFDF7);
    border-color: #FDE9C0;
    border-left-color: #F59E0B;
}
.docs-notice[hidden] { display: none !important; }

.docs-article:focus { outline: none; }

.docs-body .doc-h2,
.docs-body .doc-h3,
.docs-body .doc-h4,
.docs-body .doc-h5,
.docs-body .doc-h6 { position: relative; }
.doc-anchor {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    margin-left: 6px;
    vertical-align: middle;
    color: #B7C7DA;
    opacity: 0;
    text-decoration: none !important;
    border: none !important;
    transition: opacity .16s var(--e-out), color .16s var(--e-out);
}
.doc-h2:hover .doc-anchor,
.doc-h3:hover .doc-anchor,
.doc-h4:hover .doc-anchor,
.doc-h5:hover .doc-anchor,
.doc-h6:hover .doc-anchor,
.doc-anchor:focus-visible { opacity: 1; }
.doc-anchor:hover { color: #2563EB; }
.doc-anchor svg { width: 14px; height: 14px; }

.doc-h2.is-flash,
.doc-h3.is-flash,
.doc-h4.is-flash,
.doc-h5.is-flash,
.doc-h6.is-flash { animation: docFlash 1.8s ease-out; }
@keyframes docFlash {
    0% { background: rgba(37, 99, 235, .13); }
    100% { background: transparent; }
}

/* ============================================================
   12.5 正文末尾「常见报错」
   每篇文档统一挂一段可折叠的报错清单（数据见 js/docs-errors.js），
   用户不用再翻到《常见问题》里找对应条目
   ============================================================ */
.docs-errs {
    margin-top: 46px;
    padding-top: 4px;
}
.docs-errs > .doc-h2 { margin-top: 0; }
.docs-errs__lead {
    margin: 0 0 14px;
    font-size: 13.6px;
    color: #7E93AC;
    line-height: 1.8;
}
.docs-err {
    border: 1px solid #E8EFF8;
    border-radius: 10px;
    background: #FBFDFF;
    margin-bottom: 8px;
    overflow: hidden;
    transition: border-color .16s var(--e-out), background .16s var(--e-out);
}
.docs-err:hover { border-color: #CFE0F5; background: #F8FBFF; }
.docs-err[open] { border-color: #CFE0F5; background: #fff; }
.docs-err__sum {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    padding: 11px 14px 11px 12px;
    font-size: 14.4px;
    font-weight: 600;
    color: #1E3249;
    line-height: 1.6;
    cursor: pointer;
    list-style: none;
}
.docs-err__sum::-webkit-details-marker { display: none; }
.docs-err__sum:hover { color: #1D4ED8; }
.docs-err__idx {
    flex: 0 0 auto;
    font-size: 11.5px;
    font-weight: 700;
    color: #93A9C4;
    padding-top: 2px;
    font-variant-numeric: tabular-nums;
}
.docs-err__q { flex: 1 1 auto; word-break: break-word; }
.docs-err__chev {
    flex: 0 0 auto;
    width: 9px;
    height: 9px;
    margin: 5px 2px 0 0;
    border-right: 1.8px solid #A9BCCF;
    border-bottom: 1.8px solid #A9BCCF;
    transform: rotate(45deg);
    transition: transform .2s var(--e-out), border-color .16s var(--e-out);
}
.docs-err[open] .docs-err__chev {
    transform: rotate(-135deg);
    margin-top: 8px;
    border-color: #2563EB;
}
.docs-err__ans {
    padding: 0 14px 12px 34px;
    font-size: 14px;
    line-height: 1.85;
    color: #4A5F78;
}
.docs-err__ans p { margin: 0 0 8px; }
.docs-err__ans p:last-child { margin-bottom: 0; }
.docs-err__ans code { font-size: .88em; }

/* ============================================================
   13. 极简页脚
   文档页不放营销横幅与四列导航，只留备案链接（不再输出版权文案），
   避免打断阅读。灰字 12.5px，hover 变蓝，容器边线与全站同一套。
   ============================================================ */
.docs-foot {
    margin-top: 0;
    background: #fff;
    border-top: 1px solid #F2F5F9;
}
.docs-foot__inner {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    flex-wrap: wrap;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 20px 26px;
    box-sizing: border-box;
    font-size: 12.5px;
    line-height: 1.8;
    color: #94A3B8;
}
/* ≥1281 与全站页脚同边线：1760 上限 + 左右各 140 */
@media (min-width: 1281px) {
    .docs-foot__inner {
        max-width: 1760px;
        padding-left: 140px;
        padding-right: 140px;
    }
}
.docs-foot__links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px 8px;
}
.docs-foot__links i {
    font-style: normal;
    color: #DCE3EC;
}
.docs-foot__links a {
    color: #94A3B8;
    text-decoration: none;
    transition: color .16s var(--e-out);
}
.docs-foot__links a:hover { color: #2563EB; }
/* 备案号与热线不能被折成两行 */
.docs-foot__links span,
.docs-foot__links a { white-space: nowrap; }
.docs-foot__police {
    width: 14px;
    height: 14px;
    margin-right: 3px;
    vertical-align: middle;
}

@media (max-width: 640px) {
    /* 窄屏与全站页脚一致：竖排、贴左、隐藏分隔符 */
    .docs-foot__inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 14px 16px 20px;
        font-size: 12px;
    }
    .docs-foot__links { gap: 2px 6px; }
    .docs-foot__links i { display: none; }
}

/* ============================================================
   14. 打印（部署文档经常被打印/存 PDF 给客户）
   ============================================================ */
@media print {
    #nav,
    .m-drawer,
    .m-drawer__mask,
    .docs-aside,
    .docs-toc,
    .docs-gotop,
    .docs-progress,
    .docs-pager,
    .docs-lightbox,
    .docs-notice,
    .docs-foot,
    .source-cta,
    .footer { display: none !important; }

    .page-body { padding-top: 0 !important; }
    .docs-shell { display: block; max-width: none; padding: 0; }
    .docs-main { max-width: none; }
    .docs-article[hidden] { display: none !important; }
    .docs-body { font-size: 11.5pt; color: #111; }
    .docs-body .doc-pre {
        background: #F5F7FA;
        border: 1px solid #DDE3EB;
        box-shadow: none;
    }
    .docs-body .doc-pre code { color: #1F2937; }
    .doc-copy,
    .doc-anchor { display: none !important; }
    .docs-body .doc-figure img { max-width: 72%; box-shadow: none; }
    .doc-table-wrap { overflow: visible; border-color: #DDE3EB; }
    .docs-title { font-size: 18pt; }
    a { color: #000 !important; border-bottom: none !important; }
}

/* ============================================================
   16. 阅读工具：窄屏目录 / 阅读设置 / 弹层 / 反馈 / 命中高亮
   ============================================================ */
body.docs-locked { overflow: hidden; }

.docs-fabs {
    position: fixed;
    right: 26px;
    bottom: 90px;
    z-index: 70;
    display: flex;
    flex-direction: column;
    gap: 9px;
    align-items: flex-end;
}
.docs-fab {
    min-width: 42px;
    height: 42px;
    padding: 0 10px;
    border: 1px solid #E1EAF5;
    border-radius: 21px;
    background: #fff;
    color: #465C74;
    font-size: 13.5px;
    font-weight: 650;
    line-height: 1;
    cursor: pointer;
    box-shadow: 0 8px 24px -12px rgba(15, 23, 42, .3);
    transition: color .16s var(--e-out), border-color .16s var(--e-out), transform .16s var(--e-out);
}
.docs-fab:hover { color: #1D4ED8; border-color: #BFD9F5; transform: translateY(-1px); }
.docs-fab[hidden] { display: none !important; }
.docs-fab--toc { background: #2563EB; border-color: #2563EB; color: #fff; }
.docs-fab--toc:hover { color: #fff; background: #1D4ED8; border-color: #1D4ED8; }

.docs-pop {
    position: fixed;
    right: 26px;
    bottom: 190px;
    z-index: 71;
    width: 268px;
    padding: 16px 16px 12px;
    background: #fff;
    border: 1px solid #E7EEF7;
    border-radius: 14px;
    box-shadow: 0 20px 50px -20px rgba(15, 23, 42, .35);
}
.docs-pop[hidden] { display: none !important; }
.docs-pop__title { font-size: 13px; font-weight: 700; color: #1E3249; margin-bottom: 12px; }
.docs-pop__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}
.docs-pop__label { font-size: 12.6px; color: #7E93AC; flex: 0 0 auto; }
.docs-seg {
    display: flex;
    border: 1px solid #E3EBF5;
    border-radius: 8px;
    overflow: hidden;
}
.docs-seg button {
    border: 0;
    background: #fff;
    color: #5B7290;
    font-size: 12.4px;
    padding: 5px 10px;
    cursor: pointer;
    transition: background .15s var(--e-out), color .15s var(--e-out);
}
.docs-seg button + button { border-left: 1px solid #E3EBF5; }
.docs-seg button:hover { color: #1D4ED8; }
.docs-seg button.is-on { background: #EFF6FF; color: #1D4ED8; font-weight: 650; }
.docs-pop__tip { margin: 10px 0 0; font-size: 11.5px; color: #A9BACD; line-height: 1.6; }

.docs-modal {
    position: fixed;
    inset: 0;
    z-index: 9998;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(8, 15, 26, .55);
    -webkit-backdrop-filter: blur(3px);
}
.docs-modal[hidden] { display: none !important; }
.docs-modal__box {
    position: relative;
    width: 100%;
    max-width: 420px;
    padding: 26px 24px 22px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 30px 70px -30px rgba(8, 15, 26, .6);
}
.docs-modal__box--qr { max-width: 320px; text-align: center; }
.docs-modal__title { font-size: 15.5px; font-weight: 700; color: #0F2035; margin-bottom: 16px; text-align: center; }
.docs-modal__x {
    position: absolute;
    right: 12px;
    top: 10px;
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #A9BACD;
    font-size: 14px;
    cursor: pointer;
}
.docs-modal__x:hover { background: #F1F5FB; color: #1D4ED8; }

.docs-keys { list-style: none; margin: 0; padding: 0; }
.docs-keys li {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 9px 0;
    border-bottom: 1px dashed #EEF3F9;
    font-size: 13.4px;
    color: #3D5169;
}
.docs-keys li:last-child { border-bottom: 0; }
.docs-keys li span { flex: 1 1 auto; }
.docs-keys li i { font-style: normal; color: #A9BACD; font-size: 12px; }
.docs-keys kbd {
    display: inline-block;
    min-width: 22px;
    padding: 2px 6px;
    border: 1px solid #DFE8F3;
    border-bottom-width: 2px;
    border-radius: 5px;
    background: #F8FAFD;
    font-family: inherit;
    font-size: 12px;
    color: #465C74;
    text-align: center;
}

.docs-qr {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 192px;
    height: 192px;
    margin: 0 auto 12px;
    padding: 8px;
    border: 1px solid #E7EEF7;
    border-radius: 12px;
    background: #fff;
}
.docs-qr img, .docs-qr canvas { max-width: 100%; height: auto; }
.docs-qr__url {
    margin: 0 0 12px;
    font-size: 11.5px;
    color: #93A6BC;
    word-break: break-all;
    line-height: 1.6;
}
.docs-qr__copy {
    width: 100%;
    height: 38px;
    border: 1px solid #2563EB;
    border-radius: 9px;
    background: #2563EB;
    color: #fff;
    font-size: 13.4px;
    font-weight: 650;
    cursor: pointer;
}
.docs-qr__copy:hover { background: #1D4ED8; }

.docs-fb {
    margin-top: 30px;
    padding: 18px 18px 16px;
    border: 1px solid #E7EEF7;
    border-radius: 12px;
    background: #FBFDFF;
    text-align: center;
}
.docs-fb__q { margin: 0 0 12px; font-size: 13.8px; color: #3D5169; }
.docs-fb__btns { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; }
.docs-fb__btn {
    height: 34px;
    padding: 0 16px;
    border: 1px solid #E1EAF5;
    border-radius: 17px;
    background: #fff;
    color: #465C74;
    font-size: 13px;
    cursor: pointer;
    transition: border-color .15s var(--e-out), color .15s var(--e-out), background .15s var(--e-out);
}
.docs-fb__btn:hover { border-color: #BFD9F5; color: #1D4ED8; }
.docs-fb__btn.is-on { border-color: #2563EB; background: #EFF6FF; color: #1D4ED8; font-weight: 650; }
.docs-fb__contact { font-size: 13px; color: #7E93AC; text-decoration: none; border-bottom: 1px dashed #C6D4E4; }
.docs-fb__contact:hover { color: #1D4ED8; border-bottom-color: #2563EB; }
.docs-fb__done { margin: 10px 0 0; font-size: 12.4px; color: #16A34A; }

.docs-hit {
    background: #FFF3BF;
    color: inherit;
    padding: 0 2px;
    border-radius: 3px;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
}
.docs-hit.is-flash { animation: docsHitFlash 1.6s ease-out; }
@keyframes docsHitFlash {
    0% { background: #FFD43B; }
    100% { background: #FFF3BF; }
}

.docs-crumb a.docs-crumb__sep { color: #7E93AC; border-bottom: 1px dashed #D5E0EE; }
.docs-crumb a.docs-crumb__sep:hover { color: #1D4ED8; border-bottom-color: #2563EB; }

html[data-docs-fs="sm"] .docs-body { font-size: 15px; }
html[data-docs-fs="sm"] .docs-body .doc-h2 { font-size: 20px; }
html[data-docs-fs="sm"] .docs-body .doc-h3 { font-size: 16.6px; }
html[data-docs-fs="sm"] .docs-body .doc-h4 { font-size: 15.2px; }
html[data-docs-fs="sm"] .docs-title { font-size: 25px; }

html[data-docs-fs="lg"] .docs-body { font-size: 17.4px; }
html[data-docs-fs="lg"] .docs-body .doc-h2 { font-size: 24px; }
html[data-docs-fs="lg"] .docs-body .doc-h3 { font-size: 19.6px; }
html[data-docs-fs="lg"] .docs-body .doc-h4 { font-size: 17.6px; }
html[data-docs-fs="lg"] .docs-title { font-size: 30px; }

html[data-docs-width="narrow"] .docs-main { max-width: 860px; }
html[data-docs-width="wide"] .docs-main { max-width: 1240px; }
/* === docs-ui-part1-end === */

/* ============================================================
   17. 深色主题（只在阅读设置里手动切换，不跟随系统）
   ============================================================ */
html[data-docs-theme="dark"] body,
html[data-docs-theme="dark"] .page-body { background: #0F172A; }
html[data-docs-theme="dark"] #siteNav { background: transparent; }
/* 一级分类标题用 .docs-tree__list--root 的深层选择器定了颜色，
   这里必须按同样深度覆盖，否则深色下字看不见 */
html[data-docs-theme="dark"] .docs-tree__list--root > .docs-tree__item > .docs-tree__row > .docs-tree__link,
html[data-docs-theme="dark"] .docs-tree__link,
html[data-docs-theme="dark"] .docs-tree__link--group,
html[data-docs-theme="dark"] .docs-tree__link--overview { color: #CBD9EA; }
html[data-docs-theme="dark"] .docs-empty { color: #8FA6C0; }
html[data-docs-theme="dark"] .docs-empty span { color: #7E93AC; }
html[data-docs-theme="dark"] .docs-tree__list--root > .docs-tree__item > .docs-tree__row > .docs-tree__link.is-active { color: #7EB2FF; }
html[data-docs-theme="dark"] .docs-tree__toggle { color: #8FA6C0; }
/* 侧栏在浅色下用白色/浅蓝胶囊标注「展开的分类」和「当前文档」，
   深色主题里必须换成深底，否则浅底浅字直接看不清 */
html[data-docs-theme="dark"] .docs-tree__row { background: transparent; }
html[data-docs-theme="dark"] .docs-tree__row:hover { background: #1B2B4A; }
html[data-docs-theme="dark"] .docs-tree__list--root > .docs-tree__item.is-open > .docs-tree__row { background: #16213A; }
html[data-docs-theme="dark"] .docs-tree__row:has(> .docs-tree__link.is-active) {
    background: linear-gradient(92deg, #1B2B4A 0%, #16213A 100%);
}
html[data-docs-theme="dark"] .docs-tree__item > .docs-tree__row:has(> .docs-tree__link--group:focus-visible) { background: #1B2B4A; }
html[data-docs-theme="dark"] .docs-tree__link.is-active { color: #9EC5FF; }
html[data-docs-theme="dark"] .docs-tree__dot { border-color: #3B4A66; }
html[data-docs-theme="dark"] .docs-tree__row:has(> .docs-tree__link.is-active) .docs-tree__dot::before { background: #7EB2FF; }

/* 搜索结果列表同样是浅底 */
html[data-docs-theme="dark"] .docs-results__item { background: transparent; }
html[data-docs-theme="dark"] .docs-results__item:hover { background: #16213A; }
html[data-docs-theme="dark"] .docs-results__item.is-active { background: #1B2B4A; }
html[data-docs-theme="dark"] .docs-results__title { color: #DCE7F5; }
html[data-docs-theme="dark"] .docs-results__path,
html[data-docs-theme="dark"] .docs-results__meta { color: #8FA6C0; }
html[data-docs-theme="dark"] .docs-results__snippet { color: #A3B7CE; }
html[data-docs-theme="dark"] .docs-results mark { background: #6B4E00; color: #FFE9A8; }
html[data-docs-theme="dark"] .docs-search__clear { color: #8FA6C0; }
html[data-docs-theme="dark"] .docs-search__input {
    background: #16213A;
    border-color: #23304D;
    color: #D7E3F2;
}
html[data-docs-theme="dark"] .docs-aside__toggle { background: #16213A; border-color: #23304D; color: #B7C7DA; }

html[data-docs-theme="dark"] .docs-article { color: #C7D4E4; }
html[data-docs-theme="dark"] .docs-aside { background: #131E33; border-color: #23304D; }
/* 搜索框上方那圈白底是给滚动内容做的遮罩渐变，深色下要换掉 */
html[data-docs-theme="dark"] .docs-aside__head {
    background: linear-gradient(180deg, #131E33 72%, rgba(19, 30, 51, .92) 100%);
    border-bottom-color: #23304D;
}
html[data-docs-theme="dark"] .docs-search__input::placeholder { color: #7E93AC; }
html[data-docs-theme="dark"] .doc-figure__ph {
    background: linear-gradient(180deg, #16213A 0%, #131E33 100%);
    border-color: #2B3B5C;
}
html[data-docs-theme="dark"] .doc-figure__text { color: #8FA6C0; }
html[data-docs-theme="dark"] .doc-figure__token { background: #16213A; border-color: #2B3B5C; color: #93A9C4; }
html[data-docs-theme="dark"] .docs-body .doc-hr {
    background: linear-gradient(90deg, #23304D, #1B2843 60%, transparent);
}
html[data-docs-theme="dark"] .docs-notice {
    background: linear-gradient(96deg, #16213A, #131E33);
    border-color: #23304D;
    color: #9EC5FF;
}
html[data-docs-theme="dark"] .docs-notice--warn {
    background: linear-gradient(96deg, #2A2312, #1E1A10);
    border-color: #4A3A15;
    color: #F2C97A;
}
html[data-docs-theme="dark"] .docs-search__input { background: #0F1B30; }
/* 顶部导航是 #nav（ID 选择器 + !important），必须用同权重的 ID 覆盖 */
html[data-docs-theme="dark"] #nav,
html[data-docs-theme="dark"] #siteNav .nav,
html[data-docs-theme="dark"] .nav-content {
    background: #0C1424 !important;
    box-shadow: none !important;
}
html[data-docs-theme="dark"] #nav a,
html[data-docs-theme="dark"] #nav span { color: #C7D4E4; }
html[data-docs-theme="dark"] .docs-body .doc-table { background: #131E33; }
html[data-docs-theme="dark"] .docs-body .doc-table td { background: transparent; }
html[data-docs-theme="dark"] .docs-body .doc-table th {
    background: linear-gradient(180deg, #16213A, #131E33);
}
html[data-docs-theme="dark"] .docs-title { color: #EAF1FA; }
html[data-docs-theme="dark"] .docs-crumb,
html[data-docs-theme="dark"] .docs-crumb a,
html[data-docs-theme="dark"] .docs-crumb span { color: #8FA6C0; }
html[data-docs-theme="dark"] .docs-crumb span:last-child { color: #DCE7F5; }
html[data-docs-theme="dark"] .docs-updated { color: #7E93AC; }
html[data-docs-theme="dark"] .docs-share { background: #16213A; border-color: #2B3B5C; color: #C7D4E4; }

html[data-docs-theme="dark"] .docs-body { color: #C2D0E1; }
html[data-docs-theme="dark"] .docs-body .doc-h2 { color: #EAF1FA; }
html[data-docs-theme="dark"] .docs-body .doc-h3 { color: #8FB8FF; }
html[data-docs-theme="dark"] .docs-body .doc-h4 { color: #C6D6E9; }
html[data-docs-theme="dark"] .docs-body .doc-h5,
html[data-docs-theme="dark"] .docs-body .doc-h6 { color: #A9BCD3; }
html[data-docs-theme="dark"] .docs-body strong { color: #EAF1FA; }
html[data-docs-theme="dark"] .docs-body a { color: #7EB2FF; border-bottom-color: rgba(126, 178, 255, .35); }
html[data-docs-theme="dark"] .docs-body code {
    background: #18233C;
    border-color: #24314E;
    color: #9EC5FF;
}
html[data-docs-theme="dark"] .docs-body .doc-quote {
    background: #16213A;
    border-color: #23304D;
    color: #B7C7DA;
}
html[data-docs-theme="dark"] .docs-body .doc-pre {
    background: #121B30;
    border-color: #22304C;
}
html[data-docs-theme="dark"] .docs-body .doc-pre code { color: #CBD8E8; }
html[data-docs-theme="dark"] .docs-body .doc-table th {
    background: #16213A;
    color: #DCE7F5;
    border-color: #23304D;
}
html[data-docs-theme="dark"] .docs-body .doc-table td {
    border-color: #1E2A45;
    color: #C2D0E1;
}
html[data-docs-theme="dark"] .docs-body .doc-table tr:nth-child(even) td { background: #131E33; }
html[data-docs-theme="dark"] .docs-body .doc-figure img { border-color: #23304D; background: #16213A; }
html[data-docs-theme="dark"] .docs-body hr.doc-hr { border-color: #23304D; }

html[data-docs-theme="dark"] .docs-err { background: #131E33; border-color: #23304D; }
html[data-docs-theme="dark"] .docs-err:hover { background: #16213A; border-color: #2B3B5C; }
html[data-docs-theme="dark"] .docs-err[open] { background: #16213A; }
html[data-docs-theme="dark"] .docs-err__sum { color: #DCE7F5; }
html[data-docs-theme="dark"] .docs-err__ans { color: #AFC0D6; }
html[data-docs-theme="dark"] .docs-errs__lead { color: #8FA6C0; }

html[data-docs-theme="dark"] .docs-fb { background: #131E33; border-color: #23304D; }
html[data-docs-theme="dark"] .docs-fb__q { color: #C2D0E1; }
html[data-docs-theme="dark"] .docs-fb__btn { background: #16213A; border-color: #2B3B5C; color: #C7D4E4; }
html[data-docs-theme="dark"] .docs-fb__btn.is-on { background: #1B2B4A; border-color: #3B70C7; color: #9EC5FF; }

/* ============================================================
   7. 桌面端：左侧导航钉在视口里（不随页面滚到底上移）
   sticky 的行程上限是父容器（.docs-shell）的高度：页面滚到最底时
   容器底边进入视口，侧栏会被容器底边顶着往上跑 —— 这是 sticky 的
   固有行为，调 top / max-height 都只能把临界点往后推，推不掉。
   这里改成 fixed：位置只跟视口有关，正文滚到哪都不动。
   水平位置没法用纯 CSS 算（.docs-shell 居中、宽度还分三档断点），
   由 docs-app.js 按容器实测左边界同步，首帧用下面的兜底值。
   窄屏（≤980）是顶部折叠条，继续走上面的 sticky 规则。
   ============================================================ */
@media (min-width: 981px) {
    .docs-aside {
        position: fixed;
        /* 导航 64 + 容器首屏 32 的留白，与正文起点齐平 */
        top: 96px;
        /* 兜底值：1181–1720 区间容器左边界正好是 120，脚本随即校正 */
        left: 120px;
        width: 300px;
        /* 高度跟着目录内容走（原来钉死 calc(100vh - 120px)，
           目录条目少时卡片下面留一大片空白），超出视口才封顶并内部滚动 */
        height: auto;
        max-height: calc(100vh - 120px);
        z-index: 20;
    }
    /* 侧栏脱离文档流后，正文靠左外边距让出原来的位置（侧栏 300 + 间距 40） */
    .docs-main { margin-left: 340px; }
}

@media (min-width: 981px) and (max-width: 1180px) {
    .docs-aside { width: 270px; }
    .docs-main { margin-left: 298px; }
}

html[data-docs-theme="dark"] .docs-pager__item { background: #131E33; border-color: #23304D; }
html[data-docs-theme="dark"] .docs-pager__title { color: #DCE7F5; }
html[data-docs-theme="dark"] .docs-pager__label { color: #7E93AC; }

html[data-docs-theme="dark"] .docs-toc__title { color: #DCE7F5; }
html[data-docs-theme="dark"] .docs-toc__list { border-color: #23304D; }
html[data-docs-theme="dark"] .docs-toc__link { color: #A3B7CE; }
html[data-docs-theme="dark"] .docs-toc__item--sub2 > .docs-toc__link { color: #93A9C4; }
html[data-docs-theme="dark"] .docs-pager__label { color: #93A9C4; }
html[data-docs-theme="dark"] .docs-toc__item.is-active > .docs-toc__link { color: #7EB2FF; }

html[data-docs-theme="dark"] .docs-fab,
html[data-docs-theme="dark"] .docs-gotop { background: #16213A; border-color: #2B3B5C; color: #C7D4E4; }
html[data-docs-theme="dark"] .docs-fab--toc { background: #2563EB; border-color: #2563EB; color: #fff; }
html[data-docs-theme="dark"] .docs-pop,
html[data-docs-theme="dark"] .docs-modal__box { background: #131E33; border-color: #23304D; }
html[data-docs-theme="dark"] .docs-pop__title,
html[data-docs-theme="dark"] .docs-modal__title { color: #EAF1FA; }
html[data-docs-theme="dark"] .docs-seg { border-color: #2B3B5C; }
html[data-docs-theme="dark"] .docs-seg button { background: #16213A; color: #AFC0D6; }
html[data-docs-theme="dark"] .docs-seg button + button { border-color: #2B3B5C; }
html[data-docs-theme="dark"] .docs-seg button.is-on { background: #1B2B4A; color: #9EC5FF; }
html[data-docs-theme="dark"] .docs-keys li { color: #C2D0E1; border-color: #23304D; }
html[data-docs-theme="dark"] .docs-keys kbd { background: #16213A; border-color: #2B3B5C; color: #C7D4E4; }
html[data-docs-theme="dark"] .docs-modal__x:hover { background: #1B2B4A; }

html[data-docs-theme="dark"] .docs-foot { background: #0C1424; border-top-color: #1B2843; }
html[data-docs-theme="dark"] .docs-foot__inner { color: #7E93AC; }
/* 深色下取深色页底同色，保持写死的实底 */
html[data-docs-theme="dark"] .docs-head {
    background-color: #0F172A;
}
/* 深色下进度轨道换成深色系，页面上仍然只有这一条线 */
html[data-docs-theme="dark"] .docs-progress { background: #1E2A45; }
/* === docs-ui-part2-end === */

/* ============================================================
   18. 窄屏「本页目录」抽屉
   原来 TOC 只在 ≥1700px 显示，1440 / 1536 屏完全看不到；
   现在窄屏改成右侧抽屉，由「目录」按钮唤出
   ============================================================ */
@media (max-width: 1699px) {
    .docs-toc:not([hidden]) {
        display: block;
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: 274px;
        max-height: none;
        padding: 22px 16px 28px;
        background: #fff;
        border-left: 1px solid #EDF2F8;
        box-shadow: -18px 0 50px -30px rgba(15, 23, 42, .45);
        overflow-y: auto;
        z-index: 90;
        transform: translateX(102%);
        transition: transform .22s var(--e-out);
    }
    .docs-toc.is-open { transform: none; }
    html[data-docs-theme="dark"] .docs-toc:not([hidden]) {
        background: #131E33;
        border-left-color: #23304D;
    }
}
.docs-toc-mask {
    position: fixed;
    inset: 0;
    z-index: 89;
    background: rgba(8, 15, 26, .45);
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s var(--e-out), visibility .2s var(--e-out);
}
.docs-toc-mask.is-show { opacity: 1; visibility: visible; }

/* 宽屏右侧有固定 TOC，浮动按钮要让开，否则会压在目录上 */
@media (min-width: 1700px) {
    /* TOC 略收窄并贴右，保证正文右边界不压到目录（正文右边界 = (vw+shellW)/2） */
    /* 同时把目录高度收住：底部要留出「回到顶部 / Aa / ?」的位置，
       否则长目录会滚到最下面把按钮盖住（这就是「置顶按钮看不见」的原因） */
    .docs-toc {
        right: 20px;
        width: 190px;
        max-height: calc(100vh - 300px);
    }
}

@media (max-width: 980px) {
    /* 手机端三个悬浮键（目录/Aa/?）原来停在视口中段，常压住正文行；
       下移到近底部并默认半透明，点击或聚焦时恢复不透明，减少阅读干扰 */
    .docs-fabs { right: 10px; bottom: 92px; opacity: .86; transition: opacity .18s; }
    .docs-fabs:hover, .docs-fabs:focus-within { opacity: 1; }
    .docs-pop { right: 10px; bottom: 192px; width: 252px; }
    .docs-fab { height: 36px; min-width: 36px; font-size: 12.2px; }
}

@media print {
    .docs-fabs, .docs-pop, .docs-modal, .docs-fb, .docs-toc-mask { display: none !important; }
    .docs-hit { background: transparent !important; }
}
