:root {
  --docs-primary: #0EA5E9;
  --docs-bg: #FFFFFF;
  --docs-sidebar: #F8FAFC;
  --docs-border: #E2E8F0;
  --docs-text: #0F172A;
  --docs-muted: #64748B;
  --docs-code-bg: #0F172A;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--docs-bg);
  color: var(--docs-text);
  line-height: 1.7;
}

a { color: var(--docs-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* 紧凑顶栏 */
header.docs-header {
  position: sticky; top: 0; z-index: 100;
  background: #FFFFFF; border-bottom: 1px solid var(--docs-border);
  height: 60px; display: flex; align-items: center; justify-content: space-between; padding: 0 24px;
}
.docs-logo { font-size: 18px; font-weight: 800; color: #0F172A; display: flex; align-items: center; gap: 8px; }
.docs-nav-links { display: flex; gap: 20px; list-style: none; font-size: 14px; }
.docs-nav-links a { color: var(--docs-muted); font-weight: 500; }
.docs-nav-links a:hover, .docs-nav-links a.active { color: var(--docs-primary); font-weight: 600; text-decoration: none; }

/* 三栏布局骨架 */
.docs-layout {
  display: grid; grid-template-columns: 260px minmax(0, 1fr) 220px;
  max-width: 1440px; margin: 0 auto; min-height: calc(100vh - 60px);
}
.docs-sidebar-left {
  background: var(--docs-sidebar); border-right: 1px solid var(--docs-border);
  padding: 24px 16px; position: sticky; top: 60px; height: calc(100vh - 60px); overflow-y: auto; font-size: 14px;
}
.sidebar-group-title { font-size: 12px; font-weight: 700; color: #94A3B8; text-transform: uppercase; margin: 16px 0 8px; letter-spacing: 0.05em; }
.sidebar-menu { list-style: none; }
.sidebar-menu li { margin-bottom: 4px; }
.sidebar-menu a { display: block; padding: 6px 12px; border-radius: 6px; color: var(--docs-muted); font-weight: 500; }
.sidebar-menu a:hover, .sidebar-menu a.active { background: #E0F2FE; color: #0284C7; text-decoration: none; }

.docs-main-content { padding: 36px 48px; max-width: 860px; }
.docs-toc-right {
  padding: 24px 16px; position: sticky; top: 60px; height: calc(100vh - 60px);
  overflow-y: auto; font-size: 13px; color: var(--docs-muted); border-left: 1px solid #F1F5F9;
}
.toc-title { font-weight: 700; color: #0F172A; margin-bottom: 12px; font-size: 12px; text-transform: uppercase; }
.toc-list { list-style: none; }
.toc-list li { margin-bottom: 8px; }
.toc-list a { color: var(--docs-muted); }
.toc-list a:hover { color: var(--docs-primary); text-decoration: none; }

/* 代码呼出盒 Callout */
.callout-box {
  background: #F0F9FF; border-left: 4px solid var(--docs-primary);
  border-radius: 4px; padding: 16px; margin: 20px 0; font-size: 14px; color: #0369A1;
}
.docs-code {
  background: var(--docs-code-bg); color: #38BDF8; padding: 16px;
  border-radius: 8px; font-family: Consolas, monospace; font-size: 13px; margin: 16px 0; overflow-x: auto;
}

/* 下载页独有布局：文档引导流式下载指南 (步骤式) */
.flow-step-card {
  background: #FFFFFF; border: 1px solid var(--docs-border);
  border-radius: 8px; padding: 24px; margin-bottom: 24px; position: relative;
}
.flow-step-badge {
  display: inline-block; padding: 3px 10px; border-radius: 4px;
  background: #0284C7; color: #fff; font-size: 12px; font-weight: 700; margin-bottom: 12px;
}

/* 页脚 */
footer.docs-footer { border-top: 1px solid var(--docs-border); background: #F8FAFC; padding: 40px 0 20px; font-size: 13px; color: var(--docs-muted); }
.docs-footer-inner { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 20px; }

@media (max-width: 1100px) {
  .docs-layout { grid-template-columns: 240px minmax(0, 1fr); }
  .docs-toc-right { display: none; }
}
@media (max-width: 768px) {
  .docs-layout { grid-template-columns: 1fr; }
  .docs-sidebar-left { display: none; }
  .docs-main-content { padding: 24px; }
}