/* _static/custom.css */
/* 专为 sphinx_rtd_theme 优化：宽屏 + 大字体 */

/* -------------------------- */
/* 1. 扩展内容区域宽度 */
/* -------------------------- */
@media screen and (min-width: 768px) {
    /* 移除 RTD 默认的 800px 限制，铺满可用空间 */
    .wy-nav-content {
        max-width: none !important;
        width: 100% !important;
        padding-left: 30px;
        padding-right: 30px;
    }

    /* 缩小左侧侧边栏（默认 300px → 220px） */
    .wy-nav-side {
        width: 220px !important;
    }

    /* 调整主内容容器左边距，匹配侧边栏 */
    .wy-nav-content-wrap {
        margin-left: 220px !important;
    }
}

/* 移动端保持原样 */
@media screen and (max-width: 767px) {
    .wy-nav-content {
        padding: 1.618em 1em;
    }
}

/* -------------------------- */
/* 2. 增大代码块字体至 15px */
/* -------------------------- */
/* 高亮代码块（Pygments 生成） */
.rst-content div[class*="highlight"] pre,
/* 未高亮的 literal block（如 :: 生成的） */
.rst-content pre.literal-block,
/* 行号区域 */
.rst-content .linenodiv pre {
    font-size: 15px !important;
    line-height: 1.45 !important;
}

/* 行号容器（确保对齐） */
.rst-content .linenodiv {
    font-size: 15px !important;
}

/* 行内代码（如 :code:`foo` 或 ``foo``） */
.rst-content code,
.rst-content tt {
    font-size: 15px !important;
    background-color: #f0f0f0;
    padding: 2px 4px;
    border-radius: 3px;
    font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
}

/* -------------------------- */
/* 3. （可选）美化代码块外观 */
/* -------------------------- */
.rst-content div[class*="highlight"] {
    margin: 1.2em 0 !important;
    border-radius: 6px !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08) !important;
}