/**
 * 文章详情页样式（T_系统内容模板 / T_视频内容模板）
 */

body.article-page {
    color: #fff;
}

body.article-page .site-footer {
    margin-top: auto;
}

body.article-page--video .content-interact {
    display: none;
}

.article-page-main {
    width: 100%;
    max-width: 860px;
    margin: 0 auto;
    padding: 8px 15px 36px;
    flex: 1;
    min-width: 0;
    box-sizing: border-box;
}

/* 面包屑 */
.article-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 8px;
    margin-bottom: 14px;
    padding: 10px 14px;
    font-size: 0.86rem;
    color: rgba(255, 255, 255, 0.88);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--radius-lg, 12px);
}

.article-breadcrumb a {
    color: rgba(255, 255, 255, 0.92);
    text-decoration: none;
    transition: color var(--transition-fast, 0.2s);
}

.article-breadcrumb a:hover {
    color: var(--color-accent, #f5a623);
}

.article-breadcrumb .sep {
    color: rgba(255, 255, 255, 0.45);
    user-select: none;
}

.article-breadcrumb-current {
    color: rgba(255, 255, 255, 0.72);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

/* 文章卡片 */
.article-card {
    background: #fff;
    color: #2c3e50;
    border-radius: var(--radius-xl, 14px);
    box-shadow: var(--shadow-lg, 0 4px 20px rgba(0, 0, 0, 0.2));
    overflow: hidden;
}

.article-card-header {
    padding: 28px 28px 20px;
    border-bottom: 1px solid #eef1f5;
    background: linear-gradient(180deg, #fafbfc 0%, #fff 100%);
    position: relative;
}

.article-card-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #8b1a1a, #f5a623);
}

.article-title {
    margin: 0 0 14px;
    font-size: 1.65rem;
    font-weight: 700;
    line-height: 1.35;
    color: #1a1a2e;
    letter-spacing: 0.01em;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
}

.article-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    font-size: 0.82rem;
    color: #64748b;
    background: #f1f5f9;
    border-radius: 999px;
    line-height: 1.4;
}

.article-meta-item i {
    color: #8b1a1a;
    font-size: 0.78rem;
    opacity: 0.85;
}

.article-meta .page-view-count:empty {
    display: none;
}

.article-summary {
    margin: 16px 0 0;
    padding: 12px 14px;
    font-size: 0.95rem;
    line-height: 1.65;
    color: #475569;
    background: #f8fafc;
    border-left: 3px solid var(--color-accent, #f5a623);
    border-radius: 0 var(--radius-md, 8px) var(--radius-md, 8px) 0;
}

/* 正文 */
.article-card .article-content {
    padding: 24px 28px 28px;
    color: #334155;
    font-size: 1rem;
    line-height: 1.85;
    overflow-x: clip;
}

.article-card .article-content > :first-child {
    margin-top: 0;
}

.article-card .article-content > :last-child {
    margin-bottom: 0;
}

.article-card .article-content p {
    margin: 0 0 1em;
}

.article-card .article-content h2,
.article-card .article-content h3,
.article-card .article-content h4 {
    margin: 1.4em 0 0.6em;
    color: #1e293b;
    line-height: 1.35;
    font-weight: 600;
}

.article-card .article-content h2 { font-size: 1.35rem; }
.article-card .article-content h3 { font-size: 1.15rem; }
.article-card .article-content h4 { font-size: 1.05rem; }

.article-card .article-content ul,
.article-card .article-content ol {
    margin: 0 0 1em;
    padding-left: 1.4em;
}

.article-card .article-content li {
    margin-bottom: 0.35em;
}

.article-card .article-content a {
    color: #8b1a1a;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.article-card .article-content a:hover {
    color: #b21f1f;
}

.article-card .article-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 1.2em auto;
    border-radius: var(--radius-md, 8px);
    box-shadow: var(--shadow-sm, 0 2px 8px rgba(0, 0, 0, 0.1));
}

.article-card .article-content blockquote {
    margin: 1.2em 0;
    padding: 12px 16px;
    color: #475569;
    background: #f8fafc;
    border-left: 4px solid #cbd5e1;
    border-radius: 0 var(--radius-md, 8px) var(--radius-md, 8px) 0;
}

.article-card .article-content table {
    width: 100%;
    max-width: 100%;
    margin: 1em 0;
    border-collapse: collapse;
    font-size: 0.92rem;
    overflow-x: auto;
    display: block;
}

.article-card .article-content th,
.article-card .article-content td {
    padding: 8px 10px;
    border: 1px solid #e2e8f0;
    text-align: left;
}

.article-card .article-content th {
    background: #f1f5f9;
    font-weight: 600;
}

.article-card .article-content .article-video-wrap {
    margin: 0 0 1.2em;
}

/* 页脚操作区 */
.article-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding: 16px 28px 22px;
    background: #f8fafc;
    border-top: 1px solid #eef1f5;
}

.article-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #8b1a1a;
    text-decoration: none;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    transition: background var(--transition-fast, 0.2s), border-color var(--transition-fast, 0.2s), transform var(--transition-fast, 0.2s);
}

.article-back-link:hover {
    background: #fff5f5;
    border-color: #fecaca;
    transform: translateX(-2px);
}

.article-back-link i {
    font-size: 0.82rem;
}

/* 视频类文章：正文以播放器为主 */
body.article-page--video .article-card .article-content {
    padding-top: 20px;
}

@media (max-width: 768px) {
    .article-page-main {
        padding: 6px 12px 28px;
    }

    .article-breadcrumb {
        padding: 8px 12px;
        font-size: 0.82rem;
    }

    .article-card-header {
        padding: 22px 18px 16px;
    }

    .article-title {
        font-size: 1.35rem;
    }

    .article-card .article-content {
        padding: 18px 18px 22px;
        font-size: 0.96rem;
    }

    .article-card-footer {
        padding: 14px 18px 18px;
    }
}

@media (max-width: 375px) {
    .article-meta-item {
        font-size: 0.78rem;
        padding: 4px 10px;
    }
}
