/* ===================================
   模板5 全局变量与基础样式（与首页统一）
   =================================== */

/* --- 全局变量与初始化 --- */
:root {
    --primary-blue: #2f54eb;
    --hover-blue: #597ef7;
    --text-dark: #1a1a1a;
    --text-gray: #666;
    --bg-light: #f5f7fa;
    --bg-dark: #151520;
    --bg-card-dark: #1e1e2d;
    --green: #00b42a;
    --red: #f53f3f;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: "Microsoft YaHei", "PingFang SC", sans-serif; color: var(--text-dark); line-height: 1.6; background: #fff; }
a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* --- 顶部导航 --- */
header { background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,0.05); position: sticky; top: 0; z-index: 100; }
.nav-inner { height: 70px; display: flex; align-items: center; justify-content: space-between; }
.logo { font-size: 24px; font-weight: bold; color: var(--primary-blue); }
.logo span { color: #333; }
.nav-menu { display: flex; gap: 30px; font-size: 14px; font-weight: 500; }
.nav-menu a:hover { color: var(--primary-blue); }
.lang-switch { font-size: 12px; color: #999; cursor: pointer; }

/* --- Hero Banner (修复重叠问题) --- */
.hero {
    background: linear-gradient(135deg, #e6f7ff 0%, #f4f0ff 100%);
    padding: 80px 0 180px;
    position: relative;
}
.hero-content { display: flex; align-items: center; justify-content: space-between; }
.hero-text { max-width: 600px; }
.hero-text h1 { font-size: 48px; margin-bottom: 20px; line-height: 1.2; color: #000; }
.hero-text h1 span { color: #00b4ff; }
.hero-desc { color: #666; margin-bottom: 40px; font-size: 16px; }
.btn-group { display: flex; gap: 15px; }
.btn { padding: 12px 36px; border-radius: 4px; font-weight: bold; text-align: center; font-size: 16px; box-shadow: 0 4px 6px rgba(47, 84, 235, 0.2); }
.btn-primary { background: var(--primary-blue); color: #fff; }
.btn-primary:hover { background: var(--hover-blue); transform: translateY(-2px); }

/* 图片占位符 */
.hero-img { width: 480px; height: 320px; background: #000; border-radius: 12px; display: flex; align-items: center; justify-content: center; color: #fff; box-shadow: 0 20px 40px rgba(0,0,0,0.1); overflow: hidden;}
.hero-img img { width: 100%; height: 100%; object-fit: cover; opacity: 0.8; }

/* --- 浮动行情条 (真实数据容器) --- */
.ticker-bar {
    background: #fff;
    max-width: 1100px;
    margin: 0 auto;
    margin-top: -100px;
    border-radius: 12px;
    padding: 25px 40px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    position: relative;
    z-index: 10;
}
.ticker-item { flex: 1; border-right: 1px solid #eee; padding-left: 20px; }
.ticker-item:first-child { padding-left: 0; }
.ticker-item:last-child { border-right: none; }

.ticker-item h4 { font-size: 13px; color: #888; text-transform: uppercase; margin-bottom: 5px; }
.ticker-item .price { font-size: 22px; font-weight: bold; color: #000; font-family: Consolas, Monaco, monospace; }
.ticker-item .change { font-size: 14px; font-weight: bold; margin-left: 5px; }

/* 涨跌颜色类 */
.green { color: var(--green); }
.red { color: var(--red); }

/* --- APP下载板块 --- */
.app-section { padding: 100px 0 80px; text-align: center; }
.section-title { font-size: 36px; margin-bottom: 10px; font-weight: 800; }
.section-sub { color: #888; margin-bottom: 60px; font-size: 16px; }

.download-cards { display: flex; gap: 24px; text-align: left; }
.dl-card { flex: 1; background: #fff; border: 1px solid #f0f0f0; padding: 40px 30px; border-radius: 16px; transition: all 0.3s; position: relative; overflow: hidden; }
.dl-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgba(0,0,0,0.08); border-color: #fff; }

.dl-icon { width: 56px; height: 56px; border-radius: 50%; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 24px; margin-bottom: 24px; font-weight: bold;}
.icon-a { background: linear-gradient(135deg, #597ef7, #2f54eb); }
.icon-i { background: linear-gradient(135deg, #36cfc9, #13c2c2); }
.icon-p { background: linear-gradient(135deg, #9254de, #722ed1); }

.dl-card h3 { font-size: 22px; margin-bottom: 15px; }
.dl-card p { font-size: 14px; color: #666; margin-bottom: 25px; line-height: 1.5; min-height: 42px; }
.dl-list li { font-size: 13px; color: #555; margin-bottom: 10px; padding-left: 20px; position: relative; }
.dl-list li::before { content: "✓"; position: absolute; left: 0; color: var(--primary-blue); font-weight: bold; }

.dl-btn { display: block; width: 100%; padding: 12px 0; background: #f0f5ff; color: var(--primary-blue); text-align: center; border-radius: 6px; font-weight: bold; margin-top: 30px; transition: 0.2s;}
.dl-btn:hover { background: var(--primary-blue); color: #fff; }

/* --- 为什么选择 (深色模式) --- */
.features-dark { background: var(--bg-dark); color: #fff; padding: 80px 0; }
.features-dark .section-title { color: #fff; text-align: center; }
.features-dark .section-sub { color: #888; text-align: center; }

.feature-grid { display: flex; flex-wrap: wrap; gap: 20px; margin-top: 60px; }
.feature-card { width: calc(33.33% - 14px); background: var(--bg-card-dark); padding: 35px; border-radius: 12px; transition: 0.3s; }
.feature-card:hover { background: #2b2b3c; }
.f-icon { width: 44px; height: 44px; background: rgba(47, 84, 235, 0.15); border-radius: 10px; margin-bottom: 20px; color: #597ef7; display: flex; align-items: center; justify-content: center; font-size: 20px; }
.feature-card h3 { font-size: 18px; margin-bottom: 12px; }
.feature-card p { font-size: 13px; color: #999; line-height: 1.7; }

/* 数据统计 */
.stats-row { display: flex; justify-content: space-around; text-align: center; margin-top: 80px; padding-top: 50px; border-top: 1px solid #2a2a35; }
.stat-num { font-size: 36px; color: #597ef7; font-weight: bold; font-family: Impact, sans-serif; }
.stat-desc { font-size: 13px; color: #666; margin-top: 8px; }

/* --- 底部CTA --- */
.cta-dark { background: #151520; padding: 60px 0; color: #fff; display: flex; justify-content: center; align-items: center; gap: 60px; border-top: 1px solid #222;}
.qr-code { text-align: center; }
.qr-placeholder { width: 120px; height: 120px; background: #fff; border-radius: 8px; margin: 0 auto; display: flex; align-items: center; justify-content: center; color: #333; font-size: 12px;}

.cta-purple { background: linear-gradient(90deg, #597ef7, #9254de); padding: 60px 0; text-align: center; color: #fff; }
.btn-white { background: #fff; color: var(--primary-blue); padding: 12px 45px; border-radius: 6px; font-weight: bold; display: inline-block; box-shadow: 0 5px 15px rgba(0,0,0,0.2); }
.btn-white:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,0,0,0.3); }

/* --- 页脚 --- */
footer { background: #000; color: #666; padding: 60px 0 30px; font-size: 12px; }
.footer-cols { display: flex; justify-content: space-between; margin-bottom: 50px; }
.footer-col h5 { color: #fff; margin-bottom: 25px; font-size: 15px; }
.footer-col li { margin-bottom: 12px; }
.footer-col a:hover { color: #fff; }
.copyright { text-align: center; border-top: 1px solid #222; padding-top: 30px; color: #444; }

/* 移动端适配 */
@media (max-width: 768px) {
    .hero-content, .download-cards, .feature-grid, .cta-dark { flex-direction: column; }
    .hero-img { display: none; }
    .feature-card { width: 100%; }
    .nav-menu { display: none; }
    .ticker-bar { margin-top: -50px; width: 90%; padding: 20px; }
    .ticker-item { border-right: none; border-bottom: 1px solid #eee; padding: 15px 0; display: flex; justify-content: space-between; align-items: center; }
    .ticker-item:last-child { border-bottom: none; }
    .hero-text h1 { font-size: 32px; text-align: center; }
    .hero-desc { text-align: center; }
    .btn-group { justify-content: center; }
    .app-section { padding: 50px 0; }
}

/* ===================================
   模板5 资讯列表页样式 - 蓝色科技主题
   =================================== */

/* 页面容器 - 增加最小高度避免内容少时太紧凑 */
.template5-news-section {
    padding: 80px 0 !important;
    background: linear-gradient(180deg, #ffffff 0%, #f5f7ff 100%) !important;
    min-height: calc(100vh - 300px) !important;
    width: 100% !important;
    display: block !important;
}

/* 内容容器 - 限制最大宽度 */
.template5-news-container {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 0 20px !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* 标题区域 */
.template5-news-header {
    text-align: center !important;
    margin-bottom: 60px !important;
}

.template5-news-title {
    font-size: 42px !important;
    font-weight: 700 !important;
    color: #1a1a1a !important;
    margin-bottom: 20px !important;
    letter-spacing: 2px !important;
}

.template5-news-title span {
    color: #2f54eb !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
}

.template5-news-subtitle {
    font-size: 18px !important;
    color: #666666 !important;
}

/* 卡片网格 */
.template5-news-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)) !important;
    gap: 40px !important;
}

/* 卡片 */
.template5-news-card {
    background: white !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08) !important;
    transition: all 0.4s ease !important;
    border: 1px solid #f0f0f0 !important;
    display: flex !important;
    flex-direction: column !important;
}

.template5-news-card:hover {
    transform: translateY(-10px) !important;
    box-shadow: 0 15px 45px rgba(47, 84, 235, 0.15) !important;
    border-color: #e6f7ff !important;
}

/* 卡片主体内容 */
.template5-news-card-body {
    padding: 28px !important;
    flex: 1 !important;
}

/* 卡片图片 */
.template5-news-card-image {
    height: 200px !important;
    background: linear-gradient(135deg, #2f54eb 0%, #597ef7 100%) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 70px !important;
    border-bottom: 1px solid #e6f7ff !important;
}

/* 卡片底部 */
.template5-news-card-footer {
    padding: 20px 28px !important;
    border-top: 1px solid #f0f0f0 !important;
    background: #fafafa !important;
}

.footer{
    margin-bottom: 20px !important;
    margin-top: 100px !important;
}

.template5-news-card-footer a {
    color: #2f54eb !important;
    text-decoration: none !important;
    font-weight: 600 !important;
    transition: all 0.3s !important;
}

.template5-news-card-footer a:hover {
    color: #597ef7 !important;
    transform: translateX(5px) !important;
    display: inline-block !important;
}

/* 卡片标题 */
.template5-news-card-title {
    font-size: 20px !important;
    font-weight: 700 !important;
    margin-bottom: 16px !important;
    line-height: 1.5 !important;
}

.template5-news-card-title a {
    color: #1a1a1a !important;
    text-decoration: none !important;
    transition: color 0.3s !important;
}

.template5-news-card-title a:hover {
    color: #2f54eb !important;
}

/* 卡片元信息 */
.template5-news-card-meta {
    font-size: 14px !important;
    color: #999999 !important;
    margin-bottom: 16px !important;
    padding-bottom: 16px !important;
    border-bottom: 2px solid #f5f5f5 !important;
    display: flex !important;
    gap: 16px !important;
    flex-wrap: wrap !important;
}

/* 卡片摘要 */
.template5-news-card-excerpt {
    font-size: 15px !important;
    color: #666666 !important;
    line-height: 1.8 !important;
    margin-bottom: 20px !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 3 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
}

/* 阅读全文按钮 */
.template5-news-card-btn {
    display: inline-block !important;
    padding: 12px 24px !important;
    background: linear-gradient(135deg, #2f54eb 0%, #597ef7 100%) !important;
    color: white !important;
    text-decoration: none !important;
    border-radius: 8px !important;
    font-weight: 600 !important;
    transition: all 0.3s !important;
    font-size: 15px !important;
}

.template5-news-card-btn:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 20px rgba(47, 84, 235, 0.4) !important;
}

/* 空状态 */
.template5-news-empty {
    text-align: center !important;
    padding: 100px 20px !important;
    color: #999999 !important;
    grid-column: 1 / -1 !important;
    background: white !important;
    border-radius: 16px !important;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08) !important;
    border: 1px solid #f0f0f0 !important;
}

.template5-news-empty-icon {
    font-size: 96px !important;
    margin-bottom: 20px !important;
}

.template5-news-empty-text {
    font-size: 18px !important;
}

/* 分页 */
.template5-news-pagination {
    display: flex !important;
    justify-content: center !important;
    gap: 12px !important;
    margin-top: 60px !important;
}

.template5-news-pagination-link,
.template5-news-pagination-current {
    padding: 12px 20px !important;
    border: 2px solid #e0e0e0 !important;
    border-radius: 8px !important;
    color: #555555 !important;
    text-decoration: none !important;
    transition: all 0.3s !important;
    background: white !important;
    font-weight: 500 !important;
    display: inline-block !important;
}

.template5-news-pagination-link:hover {
    border-color: #2f54eb !important;
    color: white !important;
    background: linear-gradient(135deg, #2f54eb 0%, #597ef7 100%) !important;
    transform: translateY(-2px) !important;
}

.template5-news-pagination-current {
    border-color: #2f54eb !important;
    color: white !important;
    background: linear-gradient(135deg, #2f54eb 0%, #597ef7 100%) !important;
    font-weight: 600 !important;
}

/* ===================================
   资讯详情页样式（蓝色科技主题）
   =================================== */

/* 资讯文章容器 */
.template5-news-article {
    background: white !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08) !important;
    border: 1px solid #f0f0f0 !important;
}

/* 资讯详情头部 */
.news-detail-header {
    padding: 40px !important;
    border-bottom: 2px solid #f5f5f5 !important;
    background: linear-gradient(135deg, #fafafa 0%, #ffffff 100%) !important;
}

.news-detail-title {
    font-size: 32px !important;
    font-weight: 700 !important;
    color: #1a1a1a !important;
    margin-bottom: 25px !important;
    line-height: 1.5 !important;
    letter-spacing: 1px !important;
}

.news-detail-meta {
    display: flex !important;
    gap: 25px !important;
    flex-wrap: wrap !important;
    font-size: 14px !important;
    color: #999999 !important;
}

.news-detail-meta span {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 5px 12px !important;
    background: white !important;
    border-radius: 20px !important;
    border: 1px solid #f0f0f0 !important;
}

/* 资讯详情内容 */
.news-detail-content {
    padding: 40px !important;
    font-size: 16px !important;
    line-height: 2 !important;
    color: #333333 !important;
    background: white !important;
}

.news-detail-content p {
    margin-bottom: 20px !important;
    text-align: justify !important;
}

.news-detail-content h1,
.news-detail-content h2,
.news-detail-content h3,
.news-detail-content h4 {
    margin-top: 35px !important;
    margin-bottom: 20px !important;
    font-weight: 600 !important;
    color: #1a1a1a !important;
    line-height: 1.5 !important;
}

.news-detail-content h2 {
    font-size: 28px !important;
    padding-bottom: 10px !important;
    border-bottom: 2px solid #f0f0f0 !important;
    color: #2f54eb !important;
}

.news-detail-content h3 {
    font-size: 22px !important;
}

.news-detail-content h4 {
    font-size: 18px !important;
}

.news-detail-content ul,
.news-detail-content ol {
    margin: 20px 0 !important;
    padding-left: 30px !important;
}

.news-detail-content li {
    margin-bottom: 12px !important;
    line-height: 1.8 !important;
}

.news-detail-content img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: 8px !important;
    margin: 25px 0 !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1) !important;
    border: 1px solid #e6f7ff !important;
}

.news-detail-content blockquote {
    border-left: 4px solid #2f54eb !important;
    padding: 20px 25px !important;
    margin: 25px 0 !important;
    background: linear-gradient(135deg, #f0f5ff 0%, #ffffff 100%) !important;
    border-radius: 0 8px 8px 0 !important;
    font-style: italic !important;
    color: #666666 !important;
    line-height: 1.8 !important;
}

.news-detail-content code {
    background: #f0f5ff !important;
    padding: 3px 8px !important;
    border-radius: 4px !important;
    font-family: 'Courier New', monospace !important;
    font-size: 14px !important;
    color: #2f54eb !important;
}

.news-detail-content pre {
    background: #1a1a1a !important;
    color: #cccccc !important;
    padding: 20px !important;
    border-radius: 8px !important;
    overflow-x: auto !important;
    margin: 25px 0 !important;
    line-height: 1.6 !important;
    border: 1px solid #2f54eb !important;
}

.news-detail-content pre code {
    background: transparent !important;
    color: inherit !important;
    padding: 0 !important;
}

.news-detail-content a {
    color: #2f54eb !important;
    text-decoration: none !important;
    transition: all 0.3s !important;
    border-bottom: 1px solid transparent !important;
}

.news-detail-content a:hover {
    color: #597ef7 !important;
    border-bottom-color: #597ef7 !important;
}

.news-detail-content table {
    width: 100% !important;
    border-collapse: collapse !important;
    margin: 25px 0 !important;
    background: white !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05) !important;
    border: 1px solid #f0f0f0 !important;
}

.news-detail-content th,
.news-detail-content td {
    padding: 12px 15px !important;
    text-align: left !important;
    border-bottom: 1px solid #f0f0f0 !important;
}

.news-detail-content th {
    background: #f0f5ff !important;
    font-weight: 600 !important;
    color: #1a1a1a !important;
}

/* 空状态（通用） */
.news-empty,
.news-loading {
    text-align: center !important;
    padding: 100px 20px !important;
    color: #999999 !important;
    background: white !important;
    border-radius: 16px !important;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08) !important;
    border: 1px solid #f0f0f0 !important;
}

.news-empty .icon,
.news-loading .icon {
    font-size: 96px !important;
    margin-bottom: 20px !important;
}

.news-empty p,
.news-loading p {
    font-size: 18px !important;
    margin: 0 !important;
    color: #999999 !important;
}

/* ===================================
   移动端响应式优化
   =================================== */

@media (max-width: 768px) {
    /* 确保body可以正常滚动 */
    body {
        overflow-x: hidden !important;
        overflow-y: auto !important;
        position: relative !important;
    }

    /* 移除可能影响布局的transform */
    body[style*="transform"] {
        transform: none !important;
    }

    /* 导航栏适配 */
    .nav-menu {
        display: none !important;
    }

    /* 资讯页面容器调整 */
    .template5-news-section {
        padding: 60px 0 !important;
        min-height: calc(100vh - 250px) !important;
    }

    .template5-news-container {
        padding: 0 15px !important;
    }

    .template5-news-header {
        margin-bottom: 40px !important;
    }

    .template5-news-title {
        font-size: 28px !important;
    }

    .template5-news-grid {
        grid-template-columns: 1fr !important;
        gap: 25px !important;
    }

    .template5-news-card-body {
        padding: 20px !important;
    }

    .template5-news-card-footer {
        padding: 15px 20px !important;
    }

    .template5-news-card-title {
        font-size: 18px !important;
    }

    /* 详情页响应式 */
    .news-detail-header,
    .news-detail-content {
        padding: 25px 15px !important;
    }

    .news-detail-title {
        font-size: 24px !important;
    }

    .news-detail-meta {
        flex-direction: column !important;
        gap: 8px !important;
    }

    .news-detail-content {
        font-size: 15px !important;
        line-height: 1.8 !important;
    }

    .news-detail-content h2 {
        font-size: 22px !important;
    }

    .news-detail-content h3 {
        font-size: 19px !important;
    }
}

/* 中等屏幕适配 */
@media (min-width: 769px) and (max-width: 1024px) {
    .template5-news-section {
        min-height: calc(100vh - 280px) !important;
    }

    .template5-news-container {
        padding: 0 30px !important;
    }

    .template5-news-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)) !important;
        gap: 30px !important;
    }
}
