@charset "UTF-8";
/*
Theme Name: EHS安全管理资料站
Theme URI: https://example.com/ehs-mall
Author: EHS工程师专家组
Author URI: https://example.com
Description: 专为EHS安全官设计的资料售卖系统主题。包含本地文件上传进度条、会员等级设置、扫码支付引导及SEO优化。
Version: 1.7.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: ehs, safety, shop, mall, classic, blue
*/

/* 基础重置与变量 */
:root {
    --primary-color: #003366;
    --secondary-color: #004a99;
    --accent-color: #f39c12;
    --danger-color: #e03131;
    --success-color: #2b8a3e;
    --bg-light: #f8f9fb;
    --text-dark: #212529;
    --text-muted: #868e96;
    --border-color: #dee2e6;
    --card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --card-shadow-hover: 0 10px 20px rgba(0,0,0,0.1);
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: "PingFang SC", "Microsoft YaHei", -apple-system, sans-serif;
    background: var(--bg-light);
    color: var(--text-dark);
    margin: 0;
    line-height: 1.6;
}

/* 布局容器 */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.wrap-all {
    width: 100%;
    overflow-x: hidden;
    position: relative;
}

/* 头部样式 */
header {
    background: #fff;
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 22px;
    font-weight: 800;
    color: var(--primary-color);
    text-decoration: none;
}

.main-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 30px;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 15px;
    transition: color 0.3s;
}

.main-nav a:hover { color: var(--primary-color); }

/* 首页 Hero 区域 */
.hero-section {
    background: linear-gradient(135deg, #002a55 0%, #004a99 100%);
    color: #fff;
    text-align: center;
    padding: 100px 0;
}

.hero-title {
    font-size: 45px;
    margin-bottom: 20px;
    font-weight: 800;
}

.hero-desc {
    font-size: 18px;
    opacity: 0.8;
    max-width: 800px;
    margin: 0 auto 50px;
}

.search-box-wrap {
    max-width: 700px;
    margin: 0 auto;
    background: rgba(255,255,255,0.1);
    padding: 10px;
    border-radius: 12px;
}

.search-form { display: flex; gap: 10px; }

.search-input {
    flex: 1;
    padding: 15px 25px;
    border-radius: 8px;
    border: none;
    font-size: 16px;
    outline: none;
}

.search-submit {
    background: var(--accent-color);
    color: #fff;
    border: none;
    padding: 0 40px;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    font-size: 16px;
}

/* 核心优势 */
.stats-bar {
    background: #fff;
    padding: 30px 0;
    border-bottom: 1px solid #eee;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    text-align: center;
}

.stat-item strong { display: block; font-size: 18px; color: var(--primary-color); }
.stat-item p { margin: 5px 0 0; color: #999; font-size: 14px; }

/* 资料列表网格 */
.resource-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
    padding: 20px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
}

.section-title { margin: 0; font-size: 32px; font-weight: 800; }

/* 资料卡片 */
.resource-card {
    background: #fff;
    border-radius: 15px;
    border: 1px solid #eee;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
}

.resource-card:hover { 
    transform: translateY(-5px); 
    box-shadow: var(--card-shadow-hover);
}

.resource-thumb {
    height: 180px;
    position: relative;
    background: #f8f9fa;
}

.resource-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.resource-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(0,51,102,0.85);
    color: #fff;
    font-size: 11px;
    padding: 4px 12px;
    border-radius: 20px;
}

.resource-info { padding: 20px; flex: 1; }
.resource-title { 
    margin: 0 0 10px; 
    font-size: 16px; 
    height: 44px; 
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.resource-title a { color: #333; text-decoration: none; font-weight: bold; }

.resource-meta {
    font-size: 13px;
    color: #999;
    display: flex;
    justify-content: space-between;
}

.price-box {
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #f8f9fa;
}

.price { font-size: 20px; font-weight: bold; color: var(--danger-color); }

.btn-get {
    background: var(--primary-color);
    color: #fff;
    padding: 8px 18px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
}

/* 会员计划 */
.membership-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    align-items: flex-end;
}

.plan-card {
    background: #fff;
    color: #333;
    padding: 40px;
    border-radius: 20px;
    width: 300px;
    text-align: center;
    box-shadow: var(--card-shadow);
}

.plan-card.featured {
    background: var(--accent-color);
    color: #fff;
    padding: 60px 40px;
    width: 340px;
    transform: scale(1.05);
}

.plan-name { font-size: 22px; margin: 0; font-weight: 800; }
.plan-price { font-size: 42px; margin: 20px 0; font-weight: 900; }
.plan-desc { font-size: 14px; line-height: 1.8; margin-bottom: 30px; }

.btn-plan {
    display: block;
    background: var(--primary-color);
    color: #fff;
    padding: 15px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: bold;
}

.featured .btn-plan { background: #fff; color: var(--accent-color); }

/* 页脚 */
footer {
    background: #222;
    color: #999;
    padding: 60px 0;
    margin-top: 80px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.footer-col h3 { color: #fff; margin-bottom: 25px; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 12px; }
.footer-links a { color: #999; text-decoration: none; }
.footer-links a:hover { color: #fff; }

/* ==========================================
   响应式追加样式 (Mobile First 修改补充)
   ========================================== */

/* 移动端调整 (< 768px) */
@media (max-width: 767px) {
    header .container { flex-direction: column; gap: 15px; }
    .main-nav ul { gap: 15px; flex-wrap: wrap; justify-content: center; }
    
    .hero-title { font-size: 32px; }
    .hero-desc { font-size: 15px; }
    .search-form { flex-direction: column; }
    
    .stats-grid { grid-template-columns: 1fr; gap: 20px; }
    
    .resource-grid { grid-template-columns: 1fr; }
    .section-header { flex-direction: column; align-items: center; gap: 10px; text-align: center; }
    
    .membership-grid { flex-direction: column; align-items: center; }
    .plan-card { width: 100%; max-width: 350px; }
    .plan-card.featured { width: 100%; transform: none; padding: 40px; }
    
    .footer-grid { grid-template-columns: 1fr; text-align: center; }
    
    /* 触屏优化 */
    .btn-get, .btn-plan, .search-submit { min-height: 44px; display: flex; align-items: center; justify-content: center; }
}

/* 平板端 (768px - 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
    .resource-grid { grid-template-columns: repeat(2, 1fr); }
    .membership-grid { flex-wrap: wrap; }
}
