
    /* ========== 全局通用样式 (核心：统一居中) ========== */
    * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }

    body {
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        line-height: 1.7;
        color: #333;
        background-color: #f8f9fa;
        scroll-behavior: smooth;
        /* 页面整体无横向滚动 */
        overflow-x: hidden;
    }

    /* 通用居中容器 - 所有页面核心内容的父容器 */
    .container {
        max-width: 1200px;
        margin: 0 auto; /* 核心：左右居中 */
        padding: 0 20px; /* 左右留白，小屏幕不贴边 */
        width: 100%; /* 确保占满可用宽度 */
    }

    /* ========== 通用页眉样式 (居中) ========== */
    header {
        background-color: #ffffff;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        position: sticky;
        top: 0;
        z-index: 100;
        transition: all 0.3s ease;
        width: 100%; /* 页眉通栏 */
    }

    .header-container {
        max-width: 1200px;
        margin: 0 auto; /* 页眉内容居中 */
        padding: 1rem 20px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }

    .logo {
        font-size: 1.8rem;
        font-weight: 700;
        color: #2c3e50;
        text-decoration: none;
        transition: color 0.3s ease;
    }

    .logo:hover {
        color: #3498db;
    }

    .nav-links {
        display: flex;
        gap: 1.5rem;
    }

    .nav-links a {
        color: #555;
        text-decoration: none;
        font-weight: 500;
        transition: color 0.3s ease;
        position: relative;
    }

    .nav-links a::after {
        content: '';
        position: absolute;
        bottom: -4px;
        left: 0;
        width: 0;
        height: 2px;
        background-color: #3498db;
        transition: width 0.3s ease;
    }

    .nav-links a:hover {
        color: #3498db;
    }

    .nav-links a:hover::after {
        width: 100%;
    }

    /* ========== 通用页脚样式 (居中) ========== */
    footer {
        background-color: #2c3e50;
        color: white;
        padding: 2rem 0;
        margin-top: 3rem;
        width: 100%; /* 页脚通栏 */
    }

    .footer-container {
        max-width: 1200px;
        margin: 0 auto; /* 页脚内容居中 */
        padding: 0 20px;
        text-align: center;
        width: 100%;
    }

    .footer-links {
        display: flex;
        justify-content: center;
        gap: 1.5rem;
        margin-bottom: 1rem;
    }

    .footer-links a {
        color: #bdc3c7;
        text-decoration: none;
        transition: color 0.3s ease;
    }

    .footer-links a:hover {
        color: white;
    }

    .footer-copyright {
        color: #95a5a6;
        font-size: 0.9rem;
    }

    /* ========== 通用组件样式 ========== */
    .btn-primary {
        display: inline-block;
        background-color: #3498db;
        color: white;
        padding: 0.6rem 1.2rem;
        border-radius: 4px;
        text-decoration: none;
        font-weight: 500;
        transition: background-color 0.3s ease, transform 0.2s ease;
        border: none;
        cursor: pointer;
    }

    .btn-primary:hover {
        background-color: #2980b9;
        transform: translateY(-2px);
    }

    .card {
        background-color: white;
        border-radius: 8px;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }

    .card:hover {
        transform: translateY(-5px);
        box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    }

    .icon {
        width: 16px;
        height: 16px;
        fill: currentColor;
    }

    /* ========== 列表页特有样式 (完全居中) ========== */
    .main-content {
        padding: 2rem 0;
        width: 100%;
    }

    /* 博客列表容器 - 确保居中 */
    .blog-list {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
        gap: 2rem;
        margin: 0 auto 2rem; /* 上下间距 + 左右居中 */
        max-width: 1200px; /* 与容器一致 */
        width: 100%;
    }

    .blog-card {
        display: flex;
        flex-direction: column;
        overflow: hidden;
        width: 100%; /* 卡片占满网格列宽 */
    }

    .blog-image {
        width: 100%;
        height: 200px;
        object-fit: cover;
    }

    .blog-content {
        padding: 1.5rem;
        flex: 1;
        display: flex;
        flex-direction: column;
    }

    .blog-title {
        font-size: 1.4rem;
        font-weight: 600;
        margin-bottom: 0.8rem;
        color: #2c3e50;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
        line-height: 1.4;
        height: calc(1.4em * 2);
    }

    .blog-meta {
        font-size: 0.9rem;
        color: #7f8c8d;
        margin-bottom: 1rem;
        display: flex;
        align-items: center;
    }

    .blog-meta span {
        margin-right: 1rem;
    }

    .blog-excerpt {
        color: #555;
        margin-bottom: 1.5rem;
        line-height: 1.7;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
        height: calc(1.7em * 3);
    }

    .read-more {
        margin-top: auto;
        align-self: flex-start;
    }

    /* 分页控件 - 居中 */
    .pagination {
        display: flex;
        justify-content: center;
        align-items: center;
        margin: 2rem auto 0; /* 上下间距 + 左右居中 */
        max-width: 1200px;
        width: 100%;
    }

    .pagination a {
        color: #3498db;
        text-decoration: none;
        padding: 0.8rem 1.2rem;
        margin: 0 0.3rem;
        border-radius: 4px;
        border: 1px solid #ddd;
        transition: all 0.3s ease;
    }

    .pagination a:hover {
        background-color: #3498db;
        color: white;
        border-color: #3498db;
    }

    .pagination .active {
        background-color: #3498db;
        color: white;
        border-color: #3498db;
    }

    /* ========== 详情页特有样式 (完全居中) ========== */
    .main-container {
        padding: 2rem 0;
        /* display: grid; */
        grid-template-columns: 1fr 300px;
        gap: 2rem;
        max-width: 1200px;
        margin: 0 auto; /* 核心：详情页整体居中 */
        width: 100%;
    }

    .article-content {
        padding: 2.5rem;
        width: 100%;
    }

    .article-title {
        font-size: 2.2rem;
        font-weight: 700;
        color: #2c3e50;
        margin-bottom: 1.5rem;
        line-height: 1.3;
        position: relative;
        padding-bottom: 0.8rem;
    }

    .article-title::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 60px;
        height: 3px;
        background-color: #3498db;
        border-radius: 3px;
    }

    .article-meta {
        display: flex;
        align-items: center;
        gap: 1.5rem;
        margin-bottom: 2rem;
        padding-bottom: 1rem;
        border-bottom: 1px solid #eee;
        font-size: 0.95rem;
        color: #7f8c8d;
    }

    .meta-item {
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

    .article-featured-image {
        width: 100%;
        height: auto;
        border-radius: 8px;
        margin-bottom: 2rem;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }

    .article-body {
        color: #444;
        font-size: 1.05rem;
    }

    .article-body p {
        margin-bottom: 1.8rem;
        text-align: justify;
    }

    .article-body h2 {
        color: #2c3e50;
        margin: 2.5rem 0 1.2rem;
        font-size: 1.6rem;
        font-weight: 600;
    }

    .article-body h3 {
        color: #34495e;
        margin: 2rem 0 1rem;
        font-size: 1.3rem;
        font-weight: 600;
    }

    .article-body ul, .article-body ol {
        margin-bottom: 1.8rem;
        padding-left: 1.5rem;
    }

    .article-body li {
        margin-bottom: 0.8rem;
    }

    .article-body blockquote {
        border-left: 4px solid #3498db;
        padding: 1rem 1.5rem;
        margin: 1.8rem 0;
        background-color: #f8f9fa;
        border-radius: 0 4px 4px 0;
        font-style: italic;
        color: #555;
    }

    .article-body code {
        background-color: #f1f3f4;
        padding: 0.2rem 0.4rem;
        border-radius: 3px;
        font-family: 'Courier New', Courier, monospace;
        font-size: 0.9rem;
    }

    .article-body pre {
        background-color: #f1f3f4;
        padding: 1.5rem;
        border-radius: 6px;
        overflow-x: auto;
        margin-bottom: 1.8rem;
    }

    .article-body pre code {
        background-color: transparent;
        padding: 0;
    }

    .article-tags {
        margin: 2.5rem 0;
        padding-top: 1.5rem;
        border-top: 1px solid #eee;
    }

    .tags-title {
        font-weight: 600;
        color: #555;
        margin-bottom: 1rem;
    }

    .tags-list {
        display: flex;
        flex-wrap: wrap;
        gap: 0.8rem;
    }

    .tag {
        background-color: #e3f2fd;
        color: #1976d2;
        padding: 0.4rem 0.8rem;
        border-radius: 20px;
        font-size: 0.85rem;
        text-decoration: none;
        transition: all 0.3s ease;
    }

    .tag:hover {
        background-color: #1976d2;
        color: white;
    }

    .author-info {
        display: flex;
        align-items: center;
        gap: 1.5rem;
        margin: 2.5rem 0;
        padding: 1.5rem;
        background-color: #f8f9fa;
        border-radius: 8px;
    }

    .author-avatar {
        width: 60px;
        height: 60px;
        border-radius: 50%;
        object-fit: cover;
    }

    .author-details h3 {
        margin: 0 0 0.3rem;
        color: #2c3e50;
    }

    .author-bio {
        color: #666;
        font-size: 0.95rem;
    }

    .article-navigation {
        display: flex;
        justify-content: space-between;
        margin: 2.5rem 0;
        padding-top: 1.5rem;
        border-top: 1px solid #eee;
    }

    .nav-prev, .nav-next {
        display: flex;
        align-items: center;
        gap: 0.8rem;
        text-decoration: none;
        color: #555;
        transition: color 0.3s ease;
    }

    .nav-prev:hover, .nav-next:hover {
        color: #3498db;
    }

    .nav-content h4 {
        margin: 0 0 0.2rem;
        font-size: 0.95rem;
    }

    .nav-content p {
        margin: 0;
        font-size: 0.85rem;
        color: #777;
    }

    .sidebar {
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
        width: 100%;
    }

    .sidebar-widget {
        padding: 1.5rem;
        width: 100%;
    }

    .widget-title {
        font-size: 1.2rem;
        font-weight: 600;
        color: #2c3e50;
        margin-bottom: 1.2rem;
        padding-bottom: 0.8rem;
        border-bottom: 2px solid #3498db;
    }

    .search-box {
        display: flex;
        margin-bottom: 1.5rem;
        width: 100%;
    }

    .search-input {
        flex: 1;
        padding: 0.8rem;
        border: 1px solid #ddd;
        border-radius: 4px 0 0 4px;
        font-size: 0.95rem;
        width: 100%;
    }

    .search-btn {
        background-color: #3498db;
        color: white;
        border: none;
        padding: 0.8rem 1rem;
        border-radius: 0 4px 4px 0;
        cursor: pointer;
        transition: background-color 0.3s ease;
    }

    .search-btn:hover {
        background-color: #2980b9;
    }

    .popular-posts {
        list-style: none;
        width: 100%;
    }

    .popular-post {
        display: flex;
        gap: 1rem;
        margin-bottom: 1.2rem;
        padding-bottom: 1.2rem;
        border-bottom: 1px solid #eee;
        width: 100%;
    }

    .popular-post:last-child {
        margin-bottom: 0;
        padding-bottom: 0;
        border-bottom: none;
    }

    .popular-post-image {
        width: 80px;
        height: 60px;
        object-fit: cover;
        border-radius: 4px;
    }

    .popular-post-content h4 a {
        color: #2c3e50;
        text-decoration: none;
        transition: color 0.3s ease;
    }

    .popular-post-content h4 a:hover {
        color: #3498db;
    }

    .popular-post-date {
        font-size: 0.8rem;
        color: #7f8c8d;
    }

    .categories-list {
        list-style: none;
        width: 100%;
    }

    .category-item {
        margin-bottom: 0.8rem;
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }

    .category-item a {
        color: #555;
        text-decoration: none;
        transition: color 0.3s ease;
    }

    .category-item a:hover {
        color: #3498db;
    }

    .category-count {
        background-color: #e3f2fd;
        color: #1976d2;
        padding: 0.2rem 0.6rem;
        border-radius: 12px;
        font-size: 0.75rem;
        font-weight: 600;
    }

    /* ========== 响应式规则 (保持居中) ========== */
    @media (max-width: 992px) {
        .main-container {
            grid-template-columns: 1fr;
            padding: 1rem 0;
        }
        
        .sidebar {
            flex-direction: row;
            flex-wrap: wrap;
            justify-content: center; /* 侧边栏组件居中排列 */
        }

        .sidebar-widget {
            flex: 1;
            min-width: 250px;
            margin: 0 auto;
        }
    }

    @media (max-width: 768px) {
        /* 页眉响应式 - 仍居中 */
        .header-container {
            flex-direction: column;
            gap: 1rem;
            text-align: center;
        }
        
        .nav-links {
            gap: 1rem;
            justify-content: center; /* 导航链接居中 */
            width: 100%;
        }

        /* 列表页响应式 - 居中 */
        .blog-list {
            grid-template-columns: 1fr;
            padding: 0 10px;
        }

        .blog-title {
            -webkit-line-clamp: 2;
            height: calc(1.4em * 2);
        }

        .blog-excerpt {
            -webkit-line-clamp: 2;
            height: calc(1.7em * 2);
        }

        /* 详情页响应式 - 居中 */
        .article-content {
            padding: 1.5rem;
        }
        
        .article-title {
            font-size: 1.8rem;
            text-align: left; /* 标题仍左对齐，容器整体居中 */
        }
        
        .article-meta {
            flex-direction: column;
            align-items: flex-start;
            gap: 0.8rem;
        }
        
        .article-navigation {
            flex-direction: column;
            gap: 1.5rem;
        }
        
        .sidebar {
            flex-direction: column;
            align-items: center;
        }

        /* 分页响应式 - 居中 */
        .pagination {
            flex-wrap: wrap;
            padding: 0 10px;
        }
    }

    /* 小屏幕极致适配 (手机) */
    @media (max-width: 480px) {
        .container, .header-container, .footer-container, .main-container, .blog-list {
            padding: 0 10px;
        }

        .article-content {
            padding: 1rem;
        }

        .sidebar-widget {
            padding: 1rem;
            min-width: 100%;
        }
    }


     /* 新增分页样式 - 核心适配 */
        #pages {
            text-align: center;
            padding: 20px 0;
        }
        ._page_container {
            display: inline-flex;
            align-items: center;
            gap: 15px;
            flex-wrap: wrap;
            justify-content: center;
        }
        ._pages {
            display: flex;
            align-items: center;
            gap: 8px;
        }
        ._pages li {
            padding: 8px 14px;
            border: 1px solid #ddd;
            border-radius: 4px;
            cursor: pointer;
            background: #fff;
            transition: all 0.3s;
            font-size: 14px;
        }
        ._pages li:hover:not(._disabled):not(._active_1) {
            border-color: #2c3e50;
            color: #2c3e50;
        }
        ._pages li._disabled {
            cursor: not-allowed;
            opacity: 0.6;
            background: #f5f5f5;
        }
        ._pages li._active_1 {
            background: #2c3e50;
            color: #fff;
            border-color: #2c3e50;
        }
        ._jumper {
            display: flex;
            align-items: center;
            gap: 8px;
            font-size: 14px;
        }
        ._jumper_input {
            width: 50px;
            padding: 6px;
            border: 1px solid #ddd;
            border-radius: 4px;
            text-align: center;
            font-size: 14px;
        }
        ._jumper_input:focus {
            outline: none;
            border-color: #2c3e50;
        }
        .main-container img{
            width: 100%;
        }
._pages li._active_1 {
    background: #3498db;
}
._pages li._disabled {
    opacity: 1 !important;
}
li::marker {
  content: ''; /* 清空标记内容 */
  color: transparent; /* 兼容部分旧浏览器 */
}