/* 文章容器响应式设计 */
.article-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    line-height: 1.6;
    color: #333;
    font-size: 1.05rem;
}

/* 文章标题样式增强 */
.article-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #2c3e50;
    line-height: 1.2;
}

/* 文章元数据 */
.article-meta {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eaeaea;
}

/* 目录样式 */
.article-toc {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2.5rem;
    border-left: 4px solid #3498db;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.article-toc:hover {
    border-left-width: 6px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.article-toc h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: #2c3e50;
    font-size: 1.3rem;
}

.article-toc ul {
    list-style-type: none;
    padding-left: 1rem;
    margin-bottom: 0;
}

.article-toc li {
    margin-bottom: 0.7rem;
    position: relative;
    padding-left: 0.75rem;
}

.article-toc li:before {
    content: "•";
    position: absolute;
    left: 0;
    color: #3498db;
}

.article-toc a {
    text-decoration: none;
    color: #3498db;
    transition: all 0.2s ease;
}

.article-toc a:hover {
    color: #2072a7;
    text-decoration: underline;
    padding-left: 2px;
}

/* 文章章节样式 */
.article-section {
    margin-bottom: 3rem;
    scroll-margin-top: 2rem;
}

.article-section h2 {
    font-size: 1.8rem;
    border-bottom: 2px solid #eaeaea;
    padding-bottom: 0.6rem;
    margin-bottom: 1.5rem;
    color: #2c3e50;
}

.article-section p {
    margin-bottom: 1.2rem;
}

/* 图片容器样式 */
.article-img-container {
    text-align: center;
    margin: 2rem 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.article-img {
    max-width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.article-img-container:hover .article-img {
    transform: scale(1.01);
}

.article-img-caption {
    display: block;
    text-align: center;
    color: #666;
    font-style: italic;
    font-size: 0.9rem;
    margin-top: 0.8rem;
    padding: 0.5rem;
    background-color: #f9f9f9;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}

/* 文章注释框样式 */
.article-note {
    background-color: #eef7fe;
    border-left: 5px solid #3498db;
    padding: 1.2rem 1.5rem;
    margin: 2rem 0;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.article-note p:first-child {
    margin-top: 0;
}

.article-note p:last-child {
    margin-bottom: 0;
}

.article-note ul {
    margin-bottom: 0;
    padding-left: 1.5rem;
}

.article-note li {
    margin-bottom: 0.5rem;
}

/* 代码样式 */
code {
    background: #f5f5f5;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-family: Consolas, Monaco, 'Andale Mono', monospace;
    color: #e74c3c;
    font-size: 0.9em;
    border: 1px solid #eaeaea;
}

/* 结论部分样式 */
.conclusion {
    background-color: #f9fff9;
    padding: 1.5rem;
    border-radius: 8px;
    margin-top: 3rem;
    border-left: 4px solid #2ecc71;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.conclusion h2 {
    margin-top: 0;
    color: #27ae60;
    border-bottom: none;
    padding-bottom: 0.5rem;
}

/* 返回按钮样式 */
.back-btn {
    margin-top: 2.5rem;
    display: inline-block;
    padding: 0.6rem 1.2rem;
    background-color: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.back-btn:hover {
    background-color: #2072a7;
    transform: translateY(-2px);
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

.back-btn:active {
    transform: translateY(0);
}

/* 链接样式统一 */
.article-content a:not(.btn):not(.article-toc a) {
    color: #3498db;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.2s ease;
}

.article-content a:not(.btn):not(.article-toc a):hover {
    border-bottom-color: #3498db;
}

/* 响应式设计增强 */
@media (max-width: 768px) {
    .article-container {
        padding: 1.5rem 1rem;
    }
    
    .article-title {
        font-size: 2rem;
    }
    
    .article-section h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .article-container {
        padding: 1rem;
        font-size: 1rem;
    }
    
    .article-title {
        font-size: 1.8rem;
    }
    
    .article-toc {
        padding: 1rem;
    }
}