/* * TxtPress Corporate Theme v2.0 (Fixed)
 * Style: Modern Business / Clean / Professional 
 */

:root {
    /* --- 企业配色 --- */
    --c-primary: #3a86ff;       /* 主色：现代亮蓝 */
    --c-primary-dark: #2a75f3;  /* 悬停深色 */
    --c-secondary: #6c757d;     /* 辅助色：灰色 */
    --c-accent: #ff5c5c;        /* 强调色：珊瑚红 */
    --c-bg-light: #f8f9fa;      /* 浅灰背景 */

    /* --- 基础背景与文字 --- */
    --bg-body: #ffffff;
    --bg-card: #ffffff;
    --text-main: #222222;       /* 主要文字 */
    --text-light: #555555;      /* 次要文字 */
    --text-lighter: #999999;    /* 极淡文字 */
    --border-color: #e9ecef;    /* 边框颜色 */

    /* --- 布局参数 --- */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --header-height: 70px;
    --max-width: 1200px;
    
    /* --- 阴影系统 --- */
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-card: 0 5px 15px rgba(0,0,0,0.05);
    --shadow-hover: 0 15px 30px rgba(0,0,0,0.1);
}

/* === 全局重置 === */
* { box-sizing: border-box; margin: 0; padding: 0; outline: none; -webkit-tap-highlight-color: transparent; }

body {
    background-color: var(--bg-body);
    color: var(--text-light);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    font-size: 16px;
    padding-top: var(--header-height); /* 防止内容被固定头部遮挡 */
}

a { text-decoration: none; color: inherit; transition: all 0.2s ease; }
ul, li { list-style: none; }
img { display: block; max-width: 100%; height: auto; }

/* === 容器 === */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* === 头部导航 === */
.site-header {
    background: rgba(255, 255, 255, 0.98);
    height: var(--header-height);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: fixed; /* 固定头部 */
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.header-inner {
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--c-primary);
    display: flex;
    align-items: center;
    letter-spacing: -0.5px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 10px;
}

.desktop-nav a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-main);
    padding: 8px 16px;
    border-radius: 20px;
}

.desktop-nav a:hover, 
.desktop-nav a.active {
    color: var(--c-primary);
    background-color: rgba(58, 134, 255, 0.08);
}

/* 移动端菜单触发器 */
.mobile-menu-trigger {
    display: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: var(--text-main);
    padding: 5px;
}

/* 移动端全屏菜单 */
.mobile-menu-overlay {
    display: none; /* JS控制显示 flex */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #fff;
    z-index: 9999;
    flex-direction: column;
    padding: 20px;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 20px;
}

.logo-mobile {
    font-weight: 800;
    font-size: 1.4rem;
    color: var(--c-primary);
}

.close-btn {
    font-size: 2.5rem;
    cursor: pointer;
    line-height: 1;
    color: var(--text-light);
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: center;
    overflow-y: auto;
}

.mobile-nav-links a {
    font-size: 1.3rem;
    color: var(--text-main);
    font-weight: 600;
    padding: 10px;
    border-radius: 8px;
}

.mobile-nav-links a:active {
    background-color: var(--c-bg-light);
}

/* === Hero Section (企业大图) === */
.hero-section {
    background: linear-gradient(135deg, #3a86ff 0%, #0d6efd 100%);
    color: #fff;
    padding: 80px 0 100px;
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    overflow: hidden;
}

/* 增加一点背景纹理装饰 */
.hero-section::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    font-weight: 800;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 40px;
    opacity: 0.9;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    font-weight: 300;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* === 按钮样式 === */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 32px;
    font-size: 1rem;
    border-radius: 50px; /* 圆角按钮 */
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
}

.primary-btn {
    background: #fff;
    color: var(--c-primary);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.primary-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.secondary-btn {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.4);
    color: #fff;
    backdrop-filter: blur(5px);
}

.secondary-btn:hover {
    background: rgba(255,255,255,0.2);
    border-color: #fff;
    transform: translateY(-3px);
}

.small-btn {
    padding: 8px 24px;
    font-size: 0.9rem;
}

/* === Info Section (核心价值) === */
.info-section {
    margin-bottom: 80px;
}

.section-header {
    margin-bottom: 40px;
}

.center-header {
    text-align: center;
}

.center-header h2 {
    font-size: 2.2rem;
    color: var(--text-main);
    margin-bottom: 10px;
    font-weight: 700;
}

.center-header p, .section-header .cat-desc {
    color: var(--text-light);
    font-size: 1rem;
    opacity: 0.8;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.info-card {
    background: var(--bg-card);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    transition: all 0.4s ease;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.info-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(58, 134, 255, 0.2);
}

.info-card .icon {
    font-size: 3rem;
    margin-bottom: 20px;
    background: rgba(58, 134, 255, 0.1);
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--c-primary);
}

.info-card h3 {
    font-size: 1.4rem;
    color: var(--text-main);
    margin-bottom: 15px;
}

.info-card p {
    color: var(--text-light);
    margin-bottom: 25px;
    font-size: 0.95rem;
    line-height: 1.7;
}

.read-more {
    color: var(--c-primary);
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
}

.read-more:hover {
    text-decoration: underline;
    gap: 5px;
}

/* === Main Content Area === */
.main-content-area {
    min-height: 400px;
    margin-bottom: 80px;
}

.section-header h2 {
    font-size: 1.8rem;
    color: var(--text-main);
    border-left: 5px solid var(--c-primary);
    padding-left: 15px;
    line-height: 1.2;
}

/* === Post Grid (文章列表) === */
.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

.grid-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.grid-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.card-cover-wrapper {
    display: block;
    width: 100%;
    height: 200px;
    background: #f1f3f5;
    overflow: hidden;
    position: relative;
}

.card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.grid-card:hover .card-img {
    transform: scale(1.08);
}

.card-img-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #adb5bd;
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: 1px;
}

.card-body {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: #999;
    margin-bottom: 12px;
}

.cat-tag {
    color: var(--c-primary);
    font-weight: 600;
    background: rgba(58, 134, 255, 0.08);
    padding: 2px 8px;
    border-radius: 4px;
}

.grid-card h3 {
    font-size: 1.2rem;
    margin-bottom: 12px;
    line-height: 1.4;
    color: var(--text-main);
    font-weight: 700;
}

.grid-card h3 a {
    color: inherit;
}

.grid-card h3 a:hover {
    color: var(--c-primary);
}

.excerpt {
    font-size: 0.95rem;
    color: var(--text-light);
    flex-grow: 1;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-tags {
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}

.tag-badge {
    font-size: 0.75rem;
    color: #888;
    margin-right: 8px;
    display: inline-block;
}

.tag-badge:hover {
    color: var(--c-primary);
}

/* === Pagination === */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 50px;
}

.page-btn {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-main);
    background: #fff;
    transition: all 0.2s;
}

.page-btn:hover {
    background: var(--c-primary);
    color: #fff;
    border-color: var(--c-primary);
}

.page-current {
    display: flex;
    align-items: center;
    padding: 0 15px;
    font-weight: 600;
    color: var(--text-main);
}

/* === 文章/页面详情页 === */
.single-post {
    background: var(--bg-card);
    padding: 50px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-color);
}

.single-header {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 30px;
    margin-bottom: 40px;
}

.breadcrumb {
    font-size: 0.9rem;
    color: #999;
    margin-bottom: 20px;
}

.breadcrumb a:hover {
    color: var(--c-primary);
}

.breadcrumb span {
    margin: 0 8px;
    color: #ddd;
}

.single-header h1 {
    font-size: 2.2rem;
    color: var(--text-main);
    margin-bottom: 20px;
    line-height: 1.3;
    font-weight: 800;
}

.meta-line {
    font-size: 0.95rem;
    color: #888;
    display: flex;
    gap: 20px;
}

/* === Markdown/文章正文样式优化 === */
.markdown-body {
    color: #333;
    font-size: 1.1rem;
    line-height: 1.8;
}

.markdown-body h2 {
    font-size: 1.6rem;
    color: #111;
    margin: 2em 0 1em;
    padding-left: 15px;
    border-left: 4px solid var(--c-primary);
}

.markdown-body h3 {
    font-size: 1.3rem;
    margin: 1.5em 0 0.8em;
    color: #333;
}

.markdown-body p {
    margin-bottom: 1.5em;
}

.markdown-body ul, .markdown-body ol {
    margin-bottom: 1.5em;
    padding-left: 1.5em;
}

.markdown-body li {
    margin-bottom: 0.5em;
    list-style: disc; /* 恢复列表样式 */
}

.markdown-body blockquote {
    background: #f8f9fa;
    border-left: 5px solid #ddd;
    margin: 1.5em 0;
    padding: 20px;
    color: #666;
    font-style: italic;
    border-radius: 4px;
}

.markdown-body img {
    max-width: 100%;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin: 20px 0;
}

.markdown-body a {
    color: var(--c-primary);
    border-bottom: 1px dashed rgba(58, 134, 255, 0.4);
}

.markdown-body a:hover {
    border-bottom-style: solid;
}

/* === 文章底部元素 === */
.post-tags-container {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.tags-label {
    font-weight: bold;
    color: var(--text-main);
    margin-right: 5px;
}

.tag-pill {
    background: #f1f3f5;
    color: #666;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.tag-pill:hover {
    background: var(--c-primary);
    color: #fff;
}

.post-cta {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 30px;
    border-radius: var(--radius-md);
    margin: 40px 0;
    text-align: center;
    border: 1px solid #dee2e6;
}

.post-cta p {
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-main);
}

.post-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
    gap: 20px;
}

.nav-prev, .nav-next {
    flex: 1;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    transition: all 0.2s;
}

.nav-prev:hover, .nav-next:hover {
    border-color: var(--c-primary);
    background: rgba(58, 134, 255, 0.02);
}

.nav-next {
    text-align: right;
    align-items: flex-end;
}

.nav-prev small, .nav-next small {
    color: #999;
    font-size: 0.8rem;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.nav-prev span, .nav-next span {
    font-weight: 600;
    color: var(--text-main);
    line-height: 1.3;
}

/* === 404 Page === */
.error-404 {
    text-align: center;
    padding: 80px 0;
}

.error-404 h1 {
    font-size: 6rem;
    color: var(--c-primary);
    line-height: 1;
    margin-bottom: 20px;
}

.error-404 p {
    font-size: 1.5rem;
    color: var(--text-light);
    margin-bottom: 30px;
}

/* === FAQ Section (常见问题) === */
.faq-section {
    background: #f8f9fa;
    padding: 80px 0;
    margin-top: 60px;
}

.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: #fff;
    border-radius: var(--radius-md);
    margin-bottom: 15px;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.faq-question {
    padding: 20px 25px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    color: var(--text-main);
    transition: background 0.2s;
    user-select: none;
}

.faq-question:hover {
    background: #fcfcfc;
    color: var(--c-primary);
}

.faq-question .arrow {
    font-size: 1.2rem;
    font-weight: 300;
    transition: transform 0.3s;
}

.faq-question.active .arrow {
    transform: rotate(45deg); /* 加号变叉号的简单效果，或者旋转 */
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    background: #fff;
}

.faq-answer p {
    padding: 0 25px 25px;
    color: var(--text-light);
    font-size: 0.95rem;
    border-top: 1px solid #f1f1f1;
    padding-top: 15px;
}

.faq-question.active {
    color: var(--c-primary);
}

/* === Footer (页脚) === */
.site-footer {
    background: #1a1a1a;
    color: #b0b0b0;
    padding: 70px 0 30px;
    margin-top: auto; /* 确保沉底 */
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 50px;
}

.footer-col h4 {
    color: #fff;
    margin-bottom: 25px;
    font-size: 1.2rem;
}

.footer-col p {
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.footer-col a {
    display: block;
    margin-bottom: 10px;
    color: #b0b0b0;
    transition: color 0.2s;
}

.footer-col a:hover {
    color: var(--c-primary);
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 30px;
    text-align: center;
    font-size: 0.9rem;
}

/* === Media Queries (响应式适配) === */
@media (max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    /* 头部适配 */
    .desktop-nav {
        display: none;
    }
    .mobile-menu-trigger {
        display: block;
    }

    /* Hero适配 */
    .hero-content h1 {
        font-size: 2.2rem;
    }
    .hero-section {
        padding: 60px 0 80px;
    }

    /* Grid适配 */
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .post-navigation {
        flex-direction: column;
    }
    .nav-next {
        align-items: flex-start;
        text-align: left;
    }
    
    /* 文章详情页适配 */
    .single-post {
        padding: 25px;
    }
    .single-header h1 {
        font-size: 1.6rem;
    }
}