/* Ollama-inspired minimal design — pure grayscale, SF Pro Rounded, zero shadows */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: ui-sans-serif, system-ui, -apple-system, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji", sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: #000000;
    background-color: #ffffff;
    display: flex;
    min-height: 100vh;
}

/* 侧边栏 */
.sidebar {
    width: 240px;
    background-color: #fafafa;
    border-right: 1px solid #e5e5e5;
    padding: 24px 0 24px;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    flex-shrink: 0;
}

.sidebar .logo {
    padding: 0 16px 16px;
    border-bottom: 1px solid #e5e5e5;
    margin-bottom: 12px;
}

.sidebar .logo h2 {
    font-family: "SF Pro Rounded", system-ui, -apple-system, system-ui, sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #000000;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar .logo .version {
    font-size: 12px;
    color: #a3a3a3;
}

.sidebar .nav-section {
    margin-bottom: 4px;
}

.sidebar .nav-section h3 {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #a3a3a3;
    font-weight: 500;
    padding: 8px 16px 4px;
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    margin: 0;
    padding: 0 8px;
}

.sidebar a {
    display: block;
    padding: 6px 12px;
    color: #262626;
    text-decoration: none;
    font-size: 14px;
    line-height: 1.5;
    border-radius: 9999px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border: none;
}

.sidebar a:hover {
    background-color: #e5e5e5;
    color: #000000;
    border-bottom: none;
    text-decoration: none;
}

.sidebar a.active {
    background-color: #e5e5e5;
    color: #000000;
    font-weight: 500;
    border-bottom: none;
}

/* 主内容区 */
.content {
    margin-left: 240px;
    flex: 1;
    padding: 48px 0 88px;
    display: flex;
    justify-content: center;
    background: #ffffff;
}

/* 文章容器 */
article {
    max-width: 860px;
    width: 100%;
    padding: 0 48px;
}

/* 文档标题 */
h1 {
    font-family: "SF Pro Rounded", system-ui, -apple-system, system-ui, sans-serif;
    font-size: 48px;
    font-weight: 500;
    color: #000000;
    line-height: 1.0;
    margin-bottom: 12px;
    padding-bottom: 0;
    border-bottom: none;
    letter-spacing: normal;
}

.subtitle {
    font-size: 18px;
    color: #737373;
    margin-bottom: 48px;
    margin-top: 8px;
    font-weight: 400;
    line-height: 1.56;
}

h2 {
    font-family: "SF Pro Rounded", system-ui, -apple-system, system-ui, sans-serif;
    font-size: 30px;
    font-weight: 500;
    color: #000000;
    line-height: 1.2;
    margin-top: 48px;
    margin-bottom: 16px;
    border-bottom: none;
    padding-bottom: 0;
}

h3 {
    font-family: "SF Pro Rounded", system-ui, -apple-system, system-ui, sans-serif;
    font-size: 24px;
    font-weight: 500;
    color: #000000;
    line-height: 1.33;
    margin-top: 32px;
    margin-bottom: 10px;
}

h4 {
    font-size: 18px;
    font-weight: 500;
    color: #000000;
    margin-top: 24px;
    margin-bottom: 8px;
}

/* h2 下分隔线 */
h2::after {
    content: "";
    display: block;
    margin-top: 12px;
    border-bottom: 1px solid #e5e5e5;
}

/* 段落 */
p {
    margin: 8px 0;
    color: #000000;
}

/* 列表 */
ul, ol {
    margin: 8px 0;
    padding-left: 24px;
}

li {
    margin: 4px 0;
    color: #000000;
}

/* 表格 */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 14px;
    box-shadow: none;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    overflow: hidden;
}

thead {
    background-color: #fafafa;
    color: #000000;
}

thead th {
    padding: 10px 16px;
    text-align: left;
    font-weight: 500;
    font-size: 13px;
    color: #262626;
    text-transform: none;
    letter-spacing: normal;
    border-bottom: 1px solid #e5e5e5;
}

tbody tr {
    border-bottom: 1px solid #e5e5e5;
}

tbody tr:last-child {
    border-bottom: none;
}

tbody tr:hover {
    background-color: #fafafa;
}

tbody td {
    padding: 10px 16px;
    vertical-align: top;
    font-size: 14px;
    color: #262626;
}

/* 输入列 */
tbody td:nth-child(4) {
    font-family: ui-monospace, "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    background-color: #fafafa;
    font-size: 13px;
    color: #525252;
}

/* 代码 */
code {
    background-color: #fafafa;
    padding: 1px 6px;
    border-radius: 9999px;
    font-size: 13px;
    font-family: ui-monospace, "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    color: #262626;
    border: 1px solid #e5e5e5;
}

pre {
    background-color: #fafafa;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 20px;
    overflow-x: auto;
    margin: 16px 0;
    line-height: 1.6;
}

pre code {
    background: none;
    border: none;
    border-radius: 0;
    padding: 0;
    color: #262626;
    font-size: 14px;
}

/* 链接 */
a {
    color: #000000;
    text-decoration: none;
    border-bottom: none;
    font-weight: 500;
}

a:hover {
    color: #525252;
    text-decoration: underline;
    border-bottom: none;
}

/* 引用块 */
blockquote {
    border-left: 2px solid #e5e5e5;
    padding: 4px 16px;
    margin: 12px 0;
    background-color: #fafafa;
    border-radius: 0 12px 12px 0;
    font-style: normal;
    color: #737373;
    font-size: 14px;
}

/* Section 容器 */
section {
    margin: 24px 0;
}

section.overview ul {
    list-style: none;
    padding-left: 0;
}

section.overview li {
    padding-left: 20px;
    position: relative;
}

section.overview li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #000000;
    font-weight: 500;
}

/* Tier 分组 */
.tier {
    margin: 20px 0;
    padding: 20px 24px;
    background-color: #fafafa;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
}

.tier-desc {
    color: #737373;
    font-size: 14px;
    margin-bottom: 12px;
}

.tier table {
    border: 1px solid #e5e5e5;
    margin-top: 12px;
}

/* Footer */
footer {
    margin-top: 88px;
    padding-top: 20px;
    border-top: 1px solid #e5e5e5;
    color: #a3a3a3;
    font-size: 14px;
}

/* strong */
strong {
    font-weight: 500;
    color: #000000;
}

/* 响应式 */
@media (max-width: 1024px) {
    .sidebar {
        width: 200px;
    }
    .content {
        margin-left: 200px;
    }
    article {
        padding: 0 32px;
    }
    h1 {
        font-size: 36px;
    }
}

@media (max-width: 768px) {
    body {
        flex-direction: column;
    }
    .sidebar {
        position: static;
        width: 100%;
        height: auto;
        border-right: none;
        border-bottom: 1px solid #e5e5e5;
    }
    .content {
        margin-left: 0;
        padding: 32px 0 60px;
    }
    article {
        padding: 0 20px;
    }
    h1 {
        font-size: 30px;
    }
    h2 {
        font-size: 24px;
    }
}

/* 滚动条 */
.sidebar::-webkit-scrollbar {
    width: 4px;
}
.sidebar::-webkit-scrollbar-thumb {
    background-color: #e5e5e5;
    border-radius: 9999px;
}
.sidebar::-webkit-scrollbar-thumb:hover {
    background-color: #a3a3a3;
}

/* Case 链接 */
.case-link {
    font-family: ui-monospace, "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-weight: 500;
    font-size: 13px;
    color: #000000;
}

/* 统计数字卡片 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin: 16px 0;
}

.stat-card {
    background: #fafafa;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 20px 24px;
    text-align: center;
}

.stat-card .stat-value {
    font-family: "SF Pro Rounded", system-ui, -apple-system, system-ui, sans-serif;
    font-size: 36px;
    font-weight: 500;
    color: #000000;
    line-height: 1.0;
}

.stat-card .stat-label {
    font-size: 14px;
    color: #737373;
    margin-top: 6px;
    line-height: 1.43;
}

.stat-card .stat-pct {
    display: inline-block;
    background: #e5e5e5;
    color: #525252;
    font-size: 12px;
    padding: 1px 8px;
    border-radius: 9999px;
    margin-left: 4px;
    vertical-align: middle;
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

/* 水平分隔线 */
hr {
    border: none;
    border-top: 1px solid #e5e5e5;
    margin: 32px 0;
}

/* Focus ring — 唯一非灰色元素 */
:focus-visible {
    outline: 2px solid rgba(59, 130, 246, 0.5);
    outline-offset: 2px;
}
