/* ============================================================
 * custom.css — 定制样式覆盖层
 * 类似 WPS 的加搜定制 CSS，用 !important 覆盖关键样式
 * ============================================================ */

/* 主题色覆盖 */
.header {
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04) !important;
}

/* 文章标题增强 */
.article-title {
    color: #1a1a2e !important;
}

.detail_article h2 {
    position: relative;
    padding-left: 16px;
}

.detail_article h2::before {
    content: "";
    position: absolute;
    left: 0;
    top: 6px;
    bottom: 6px;
    width: 4px;
    background: var(--theme-color);
    border-radius: 2px;
}

/* 代码块增强 */
.detail_article pre {
    border: 1px solid #313244;
}

/* 链接悬停效果 */
.detail_article a {
    transition: all 0.2s ease;
}

/* 侧边栏卡片微交互 */
.sidebar-box {
    transition: box-shadow 0.2s ease;
}

.sidebar-box:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1) !important;
}

/* 相关文章卡片 */
.related-card {
    border: 1px solid var(--border-color);
}

.related-card:hover {
    border-color: var(--theme-color);
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}

/* 打印样式 */
@media print {
    .header, .sidebar, .p-footer, #backtop, .article-footer-bar,
    .post-navigation, .related_article, .breadcrumb {
        display: none !important;
    }
    .detail_main {
        box-shadow: none !important;
        padding: 0 !important;
    }
    .list-cont {
        max-width: 100% !important;
    }
}