
        /* 基础样式 */
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
        }
        
        body {
            background-color: #f8f9fa;
            color: #333;
            line-height: 1.6;
        }
        
        .container {
            max-width: 1200px;
            margin: 0 auto;
            padding: 0 20px;
            position: relative;
            top: 40px;
        }
        
        
        /* 文章头部样式 */
        .article-header {
            border-radius: 10px;
            padding: 30px;
            margin-bottom: 30px;
        }
        
        .article-title {
            font-size: 32px;
            color: #2c3e50;
            margin-bottom: 15px;
            line-height: 1.3;
        }
        
        .article-meta {
            display: flex;
            gap: 20px;
            margin-bottom: 25px;
            color: #7f8c8d;
            font-size: 14px;
        }
        
        .article-meta span {
            display: flex;
            align-items: center;
            gap: 5px;
        }
        
        /* 初始目录容器（在文章内容上方） */
        #tocContainer {
            background-color: white;
            border-radius: 10px;
            box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
            overflow: hidden;
            transition: all 0.3s ease;
            border: 1px solid #e8e8e8;
        }
        
        /* 目录头部 */
        .toc-header {
            padding: 15px 20px;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            display: flex;
            justify-content: space-between;
            align-items: center;
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
            position: relative;
            z-index: 10;
        }
        
        .toc-header h3 {
            margin: 0;
            font-size: 16px;
            font-weight: 600;
            letter-spacing: 0.5px;
            display: flex;
            align-items: center;
            gap: 8px;
        }
        
        .toc-header h3 i {
            font-size: 15px;
        }
        
        .toc-toggle {
            background: rgba(255, 255, 255, 0.2);
            border: none;
            color: white;
            width: 24px;
            height: 24px;
            border-radius: 50%;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 16px;
            transition: all 0.3s ease;
        }
        
        .toc-toggle:hover {
            background: rgba(255, 255, 255, 0.3);
        }
        
        /* 目录内容区域 */
        .toc-nav {
            padding: 15px 20px;
            overflow-y: auto;
            height: 246px; /* 300px - 头部54px */
        }
        
        .toc-nav::-webkit-scrollbar {
            width: 4px;
        }
        
        .toc-nav::-webkit-scrollbar-track {
            background: #f1f1f1;
            border-radius: 2px;
        }
        
        .toc-nav::-webkit-scrollbar-thumb {
            background: #c1c1c1;
            border-radius: 2px;
        }
        
        .toc-nav::-webkit-scrollbar-thumb:hover {
            background: #a1a1a1;
        }
        
        /* 目录列表 */
        #tocList {
            list-style: none;
            padding: 0;
            margin: 0;
        }
        
        .toc-item {
            margin: 0;
            padding: 0;
            position: relative;
        }
        
        .toc-item a {
            display: block;
            padding: 8px 10px;
            color: #555;
            text-decoration: none;
            font-size: 14px;
            line-height: 1.4;
            border-left: 3px solid transparent;
            transition: all 0.2s ease;
            border-radius: 4px;
            margin: 2px 0;
        }
        
        .toc-item a:hover {
            color: #667eea;
            background: #f8f9fa;
            border-left-color: #667eea;
        }
        
        .toc-item.level-2 a {
            padding-left: 15px;
            font-weight: 600;
            color: #333;
        }
        
        .toc-item.level-3 a {
            padding-left: 30px;
            font-size: 13px;
            color: #666;
        }
        
        .toc-item.active > a {
            color: #667eea;
            background: linear-gradient(90deg, rgba(102, 126, 234, 0.1) 0%, transparent 100%);
            border-left-color: #667eea;
            font-weight: 600;
        }
        
        /* 文章内容区域 */
        .article-content {
            background-color: white;
            border-radius: 10px;
            box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
            padding: 40px;
            font-size: 16px;
            line-height: 1.8;
        }
        
        .article-content p {
            margin-bottom: 20px;
            text-align: justify;
        }
        
        .article-content h2,
        .article-content h3 {
            position: relative;
            padding-left: 20px;
            scroll-margin-top: 100px;
            margin-top: 40px;
            margin-bottom: 20px;
        }
        
        .article-content h2 {
            font-size: 28px;
            color: #2c3e50;
            border-left: 5px solid #667eea;
            padding-left: 15px;
            text-align: left;
        }
        
        .article-content h3 {
            font-size: 22px;
            color: #34495e;
            border-left: 4px solid #764ba2;
            padding-left: 15px;
        }
        
        .article-content h2::before,
        .article-content h3::before {
            content: '#';
            position: absolute;
            left: 0;
            color: #667eea;
            opacity: 0;
            transition: opacity 0.3s ease;
            font-weight: normal;
        }
        
        .article-content h2:hover::before,
        .article-content h3:hover::before {
            opacity: 1;
        }
        
        /* 滚动后目录样式 - 固定在侧边（PC端） */
        @media (min-width: 769px) {
            .toc-container.fixed {
                position: fixed;
                top: 120px;
                right: 20px; /* 在文章容器外面 */
                width: 350px; /* PC端展开宽度 */
                height: auto;
                max-height: calc(100vh - 140px);
                margin-bottom: 0;
                z-index: 999;
            }
            
            .toc-container.fixed .toc-nav {
                height: auto;
                max-height: calc(100vh - 194px); /* 减去头部和边距 */
            }
        }
        
        /* 移动端侧边栏样式 */
        @media (max-width: 768px) {
            .toc-container.fixed {
                position: fixed;
                top: 53px;
                right: 0;
                width: 50%; /* 移动端展开宽度50% */
                height: 88%;
                max-height: calc(100vh - 100px);
                margin-bottom: 0;
                z-index: 999;
                display: block !important;
            }
            
            .toc-container.fixed .toc-nav {
                height: auto;
                max-height: calc(100vh - 154px);
            }
            
            .article-content {
                padding: 15px;
            }
            
            .article-header {
                padding: 5px;
            }
        }
        
        /* PC端最小化状态 - 修改为圆角方框和FontAwesome图标 */
        @media (min-width: 769px) {
            .toc-container.minimized {
                width: 50px !important; /* 最小化宽度固定 */
                height: 50px !important;
                max-height: 50px !important;
                overflow: hidden;
                position: fixed;
                top: 50%;
                right: 320px; /* 与展开时相同位置 */
                transform: translateY(-50%);
                border-radius: 12px; /* 圆角方框 */
                box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
                cursor: pointer;
                z-index: 1000;
                background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
                display: flex;
                align-items: center;
                justify-content: center;
            }
			@media (max-width: 1366px) and (min-width: 1024px) {
    .toc-container.minimized {
        right: 20px !important;
    }
}
            
            .toc-container.minimized .toc-header,
            .toc-container.minimized .toc-nav {
                display: none;
            }
            
            .toc-container.minimized .minimized-icon {
                display: block !important;
                color: white;
                font-size: 22px;
            }
            
            .toc-container.minimized:hover {
                transform: translateY(-50%) scale(1.1);
                box-shadow: 0 8px 25px rgba(102, 126, 234, 0.5);
            }
        }
        
        /* 移动端最小化位置 */
        @media (max-width: 768px) {
            .toc-container.minimized {
                right: 10px;
                width: 45px !important;
                height: 45px !important;
                border-radius: 12px; /* 移动端也使用圆角方框 */
                background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
                display: flex;
                align-items: center;
                justify-content: center;
            }
            
            .toc-container.minimized .minimized-icon {
                display: block !important;
                color: white;
                font-size: 20px;
            }
        }
        
        /* 最小化图标（默认隐藏） */
        .minimized-icon {
            display: none;
        }
        
        /* 遮罩层 - 透明，仅用于捕获点击事件 */
        .toc-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-color: transparent;
            z-index: 998;
            display: none;
        }
        
        .toc-overlay.active {
            display: block;
        }
        
        /* 文章代码块样式 */
        .code-block {
            background-color: #2d3a4b;
            color: #e6e6e6;
            padding: 20px;
            border-radius: 8px;
            margin: 25px 0;
            overflow-x: auto;
            font-family: 'Consolas', 'Monaco', monospace;
            font-size: 14px;
            line-height: 1.5;
        }
        
        /* 提示框样式 */
        .tip-box {
            background-color: #e8f4fd;
            border-left: 4px solid #2196f3;
            padding: 15px 20px;
            margin: 25px 0;
            border-radius: 0 5px 5px 0;
        }
        
        /* 移动端最小化位置 - 修复：添加固定位置 */
@media (max-width: 768px) {
    .toc-container.minimized {
        position: fixed !important;
        top: 50%;
        right: 10px;
        width: 45px !important;
        height: 45px !important;
        border-radius: 12px;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        display: flex !important;
        align-items: center;
        justify-content: center;
        z-index: 1000;
        box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
        cursor: pointer;
        margin-bottom: 0 !important;
    }
    
    .toc-container.minimized .toc-header,
    .toc-container.minimized .toc-nav {
        display: none !important;
    }
    
    .toc-container.minimized .minimized-icon {
        display: block !important;
        color: white;
        font-size: 20px;
    }
    
    .toc-container.minimized:hover {
        transform: scale(1.1);
        box-shadow: 0 8px 25px rgba(102, 126, 234, 0.5);
    }
}

.article-copyright {
    background: #191f2b url(/static/upload/image/20251210/copyright_sky.svg) no-repeat;
    background-size: cover;
    text-align: center;
    line-height: 4rem;
    border-radius: .4rem;
    margin: 2rem 0 2rem 0;
    position: relative;
}

.article-copyright p:before {
    content: "";
    position: absolute;
    left: 15rem;
    top: -1.5rem;
    width: 4rem;
    height: 5rem;
    background: url(/static/upload/image/20251210/copyright.svg) no-repeat;
    background-size: contain;
}
@media (max-width: 768px) {
    .article-copyright p:before {
        left: -1rem;
        top: -1.5rem;
        width: 3rem;
        height: 4rem;
    }
}

