/**
 * AI数字人资讯主题 - ComfyUI工作流引流版
 * @package aiDigitalHuman
 * @version 2.0.0
 */

/* ===== CSS 变量（暗色主题） ===== */
:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #14141e;
    --bg-card: #1a1a2e;
    --bg-card-hover: #222244;
    --text-primary: #eaeef2;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --accent-cyan: #00d4ff;
    --accent-purple: #7c3aed;
    --accent-gradient: linear-gradient(135deg, #00d4ff 0%, #7c3aed 100%);
    --border-color: #2a2a44;
    --shadow-glow: 0 4px 30px rgba(0, 212, 255, 0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--accent-cyan);
    text-decoration: none;
    transition: all 0.3s ease;
}
a:hover {
    color: #fff;
    text-decoration: none;
}

.container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== 顶部公告栏（引流） ===== */
.top-banner {
    background: var(--accent-gradient);
    text-align: center;
    padding: 8px 0;
    font-size: 14px;
    font-weight: 500;
    color: #fff;
}
.top-banner a {
    color: #fff;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* ===== 头部导航 ===== */
.site-header {
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 999;
}
.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.site-brand h1 {
    font-size: 24px;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.site-brand h1 a {
    -webkit-text-fill-color: transparent;
}
.site-brand p {
    font-size: 12px;
    color: var(--text-muted);
    letter-spacing: 1px;
    margin-top: -2px;
}

.site-nav ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 28px;
}
.site-nav ul li a {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
}
.site-nav ul li a:hover {
    color: #fff;
}

/* 核心引流按钮（头部） */
.btn-cta {
    background: var(--accent-gradient);
    color: #fff !important;
    padding: 8px 20px;
    border-radius: 40px;
    font-weight: 700;
    font-size: 14px;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
    transition: all 0.3s ease;
}
.btn-cta:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.5);
    color: #fff !important;
}

/* ===== 首页英雄区（巨型引流位） ===== */
.hero-section {
    background: radial-gradient(ellipse at 70% 30%, #1a1a3e 0%, #0a0a0f 70%);
    border-radius: 24px;
    padding: 60px 50px;
    margin: 30px 0 40px;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}
.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0,212,255,0.08) 0%, transparent 70%);
    pointer-events: none;
}
.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
}
.hero-content .badge {
    background: rgba(0, 212, 255, 0.15);
    color: var(--accent-cyan);
    padding: 4px 16px;
    border-radius: 40px;
    font-size: 13px;
    font-weight: 600;
    border: 1px solid rgba(0, 212, 255, 0.2);
}
.hero-content h2 {
    font-size: 44px;
    font-weight: 800;
    line-height: 1.2;
    max-width: 700px;
}
.hero-content h2 span {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-content p {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 550px;
    margin: 8px 0 12px;
}
.hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.btn-hero {
    background: var(--accent-gradient);
    color: #fff;
    padding: 14px 40px;
    border-radius: 60px;
    font-weight: 700;
    font-size: 18px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.25);
}
.btn-hero:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 50px rgba(0, 212, 255, 0.4);
    color: #fff;
}
.btn-hero-outline {
    background: transparent;
    color: #fff;
    padding: 14px 36px;
    border-radius: 60px;
    font-weight: 600;
    font-size: 18px;
    border: 2px solid var(--border-color);
}
.btn-hero-outline:hover {
    border-color: var(--accent-cyan);
    color: var(--accent-cyan);
    transform: translateY(-3px);
}

/* ===== 主布局 ===== */
.main-wrapper {
    display: flex;
    gap: 40px;
    padding: 20px 0 50px;
}
.main-content {
    flex: 1;
    min-width: 0;
}
.sidebar {
    width: 320px;
    flex-shrink: 0;
}

/* ===== 文章列表 ===== */
.post-list .post-item {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 24px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}
.post-list .post-item:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent-cyan);
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}

.post-item .post-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 8px;
}
.post-item .post-title a {
    color: var(--text-primary);
}
.post-item .post-title a:hover {
    color: var(--accent-cyan);
}

.post-item .post-meta {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
.post-item .post-meta .cat-link {
    color: var(--accent-cyan);
    font-weight: 500;
}

.post-item .post-excerpt {
    color: var(--text-secondary);
    font-size: 15px;
}
.post-item .post-excerpt .more-link {
    color: var(--accent-cyan);
    font-weight: 600;
    margin-left: 6px;
}

/* ===== 文章详情页 ===== */
.post-detail {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 40px 42px;
    border: 1px solid var(--border-color);
}

.post-detail .post-title {
    font-size: 34px;
    font-weight: 800;
    line-height: 1.3;
}
.post-detail .post-meta {
    font-size: 14px;
    color: var(--text-muted);
    margin: 12px 0 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.post-detail .post-content {
    font-size: 17px;
    color: var(--text-secondary);
    line-height: 1.9;
}
.post-detail .post-content h2 {
    color: #fff;
    font-size: 26px;
    margin: 36px 0 16px;
}
.post-detail .post-content h3 {
    color: #fff;
    font-size: 21px;
    margin: 28px 0 12px;
}
.post-detail .post-content p {
    margin-bottom: 20px;
}
.post-detail .post-content img {
    max-width: 100%;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}
.post-detail .post-content blockquote {
    border-left: 4px solid var(--accent-cyan);
    background: rgba(0, 212, 255, 0.05);
    padding: 16px 24px;
    border-radius: 0 12px 12px 0;
    margin: 20px 0;
}
.post-detail .post-content code {
    background: #1a1a2e;
    padding: 2px 10px;
    border-radius: 6px;
    color: var(--accent-cyan);
}
.post-detail .post-content pre {
    background: #0a0a0f;
    padding: 20px;
    border-radius: 12px;
    overflow-x: auto;
    border: 1px solid var(--border-color);
}

/* ===== 文章内工作流引流卡片（核心转化点） ===== */
.workflow-cta-box {
    background: linear-gradient(135deg, #1a1a3e 0%, #0d0d1a 100%);
    border: 1px solid var(--accent-cyan);
    border-radius: 16px;
    padding: 28px 34px;
    margin: 36px 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    box-shadow: 0 0 40px rgba(0, 212, 255, 0.08);
}
.workflow-cta-box .left h4 {
    font-size: 20px;
    font-weight: 700;
    color: #fff;
}
.workflow-cta-box .left p {
    color: var(--text-secondary);
    margin: 4px 0 0;
    font-size: 14px;
}
.workflow-cta-box .right a {
    background: var(--accent-gradient);
    color: #fff;
    padding: 12px 32px;
    border-radius: 60px;
    font-weight: 700;
    font-size: 16px;
    display: inline-block;
    box-shadow: 0 0 25px rgba(0, 212, 255, 0.3);
    transition: all 0.3s ease;
    white-space: nowrap;
}
.workflow-cta-box .right a:hover {
    transform: scale(1.05);
    box-shadow: 0 0 40px rgba(0, 212, 255, 0.5);
    color: #fff;
}

/* ===== 分页 ===== */
.pagination {
    text-align: center;
    margin-top: 10px;
}
.pagination a,
.pagination span {
    display: inline-block;
    padding: 8px 18px;
    margin: 0 4px;
    border-radius: 8px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 14px;
}
.pagination a:hover {
    background: var(--accent-cyan);
    color: #0a0a0f;
    border-color: var(--accent-cyan);
}
.pagination .current {
    background: var(--accent-gradient);
    color: #fff;
    border-color: transparent;
}

/* ===== 侧边栏 ===== */
.sidebar .widget {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 24px 26px;
    margin-bottom: 24px;
    border: 1px solid var(--border-color);
}
.sidebar .widget h3 {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 14px;
    color: #fff;
    letter-spacing: 0.5px;
}
.sidebar .widget ul {
    list-style: none;
}
.sidebar .widget ul li {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.sidebar .widget ul li a {
    color: var(--text-secondary);
    font-size: 14px;
}
.sidebar .widget ul li a:hover {
    color: var(--accent-cyan);
}

/* 侧边栏固定工作流推荐位 */
.sidebar-cta-card {
    background: linear-gradient(145deg, #1a1a3e, #0d0d1a);
    border: 1px solid var(--accent-purple);
    text-align: center;
    padding: 28px 20px !important;
}
.sidebar-cta-card .emoji-big {
    font-size: 48px;
    display: block;
    margin-bottom: 8px;
}
.sidebar-cta-card h4 {
    color: #fff;
    font-size: 18px;
}
.sidebar-cta-card p {
    color: var(--text-muted);
    font-size: 14px;
    margin: 6px 0 16px;
}
.sidebar-cta-card .btn-sm {
    background: var(--accent-gradient);
    color: #fff;
    padding: 10px 24px;
    border-radius: 40px;
    font-weight: 700;
    display: inline-block;
}

/* ===== 底部 ===== */
.site-footer {
    border-top: 1px solid var(--border-color);
    padding: 30px 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
}
.site-footer a {
    color: var(--text-secondary);
}
.site-footer a:hover {
    color: var(--accent-cyan);
}

/* ===== 响应式 ===== */
@media (max-width: 900px) {
    .main-wrapper {
        flex-direction: column;
    }
    .sidebar {
        width: 100%;
    }
    .hero-section {
        padding: 36px 24px;
    }
    .hero-content h2 {
        font-size: 30px;
    }
    .post-detail {
        padding: 24px 18px;
    }
    .post-detail .post-title {
        font-size: 26px;
    }
    .workflow-cta-box {
        flex-direction: column;
        text-align: center;
    }
    .site-nav ul {
        gap: 14px;
        flex-wrap: wrap;
        justify-content: center;
    }
}
@media (max-width: 480px) {
    .hero-content h2 {
        font-size: 24px;
    }
    .btn-hero, .btn-hero-outline {
        padding: 12px 24px;
        font-size: 15px;
        width: 100%;
        text-align: center;
    }
    .hero-buttons {
        width: 100%;
    }
}