/* 中国程式肿瘤诊疗联盟 - 网站样式 */

* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: "Microsoft YaHei", "PingFang SC", sans-serif; line-height: 1.6; color: #333; background: #f8f9fa; }
a { text-decoration: none; color: inherit; }
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.1); position: sticky; top: 0; z-index: 1000; }
.header .container { display: flex; align-items: center; justify-content: space-between; height: 80px; }
.logo { max-width: 280px; }
.logo img { 
    height: 80px; 
    width: auto; 
    max-width: 100%;
    max-height: 90px;
}
.nav ul { display: flex; gap: 30px; }
.nav a { font-size: 16px; color: #333; transition: color 0.3s; }
.nav a:hover, .nav a.active { color: #e74c3c; }
.consult-btn { background: #e74c3c; color: #fff; padding: 10px 25px; border-radius: 25px; transition: background 0.3s; }
.consult-btn:hover { background: #c0392b; }

/* 横幅 */
.banner { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: #fff; padding: 80px 0; text-align: center; }
.banner-content h1 { font-size: 42px; margin-bottom: 15px; }
.banner-content p { font-size: 20px; opacity: 0.9; }

/* 通用区块 */
.section { padding: 60px 0; }
.section-title { text-align: center; font-size: 32px; margin-bottom: 40px; color: #2c3e50; position: relative; }
.section-title::after { content: ''; display: block; width: 60px; height: 3px; background: #e74c3c; margin: 15px auto 0; }

/* 企业简介 */
.about-section { background: #fff; }
.about-content { display: flex; gap: 50px; align-items: center; }
.about-text { flex: 1; font-size: 16px; color: #666; line-height: 1.8; }
.about-stats { display: flex; gap: 40px; }
.stat-item { text-align: center; }
.stat-num { display: block; font-size: 42px; font-weight: bold; color: #e74c3c; }
.stat-label { font-size: 14px; color: #999; }

/* 核心技术 */
.tech-section { background: #f8f9fa; }
.tech-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.tech-card { background: #fff; padding: 30px; border-radius: 10px; text-align: center; transition: transform 0.3s, box-shadow 0.3s; overflow: hidden; }
.tech-card:hover { transform: translateY(-10px); box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.tech-icon { font-size: 48px; margin-bottom: 20px; }
.tech-thumb { width: 100%; height: 200px; margin-bottom: 15px; border-radius: 8px; overflow: hidden; max-width: 340px; margin-left: auto; margin-right: auto; }
.tech-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.tech-card:hover .tech-thumb img { transform: scale(1.05); }
.tech-card h3 { font-size: 18px; margin-bottom: 10px; color: #2c3e50; }
.tech-card p { color: #666; margin-bottom: 15px; font-size: 13px; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.learn-more { color: #e74c3c; font-weight: bold; }

/* 患者案例 */
.cases-section { background: #fff; }
.cases-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.case-card { background: #f8f9fa; border-radius: 10px; overflow: hidden; transition: transform 0.3s; }
.case-card:hover { transform: translateY(-5px); }
.case-thumb { height: 180px; background: #ddd; overflow: hidden; }
.case-thumb img { width: 100%; height: 100%; object-fit: cover; }
.case-info { padding: 20px; }
.case-info h3 { font-size: 16px; margin-bottom: 10px; color: #2c3e50; }
.case-info p { font-size: 13px; color: #666; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.more-link { text-align: center; margin-top: 40px; }
.btn-more { display: inline-block; padding: 12px 40px; background: #e74c3c; color: #fff; border-radius: 30px; transition: background 0.3s; }
.btn-more:hover { background: #c0392b; }

/* 新闻资讯 */
.news-section { background: #f8f9fa; }
.news-list { max-width: 800px; margin: 0 auto; }
.news-item { display: flex; gap: 20px; padding: 20px; background: #fff; border-radius: 10px; margin-bottom: 15px; transition: box-shadow 0.3s; }
.news-item:hover { box-shadow: 0 5px 20px rgba(0,0,0,0.1); }
.news-date { width: 60px; height: 60px; background: #e74c3c; color: #fff; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 14px; text-align: center; flex-shrink: 0; }
.news-content h3 { font-size: 18px; margin-bottom: 8px; color: #2c3e50; }
.news-content p { font-size: 14px; color: #666; }

/* 留言 */
.message-section { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: #fff; }
.message-section .section-title { color: #fff; }
.message-section .section-title::after { background: #fff; }
.message-form { max-width: 600px; margin: 0 auto; background: #fff; padding: 40px; border-radius: 15px; }
.message-success { background: #d4edda; color: #155724; padding: 15px; border-radius: 8px; margin-bottom: 20px; text-align: center; }
.form-row { display: flex; gap: 15px; margin-bottom: 15px; }
.form-group { flex: 1; margin-bottom: 15px; }
.form-group input, .form-group textarea { width: 100%; padding: 12px 15px; border: 1px solid #ddd; border-radius: 8px; font-size: 14px; }
.form-group textarea { min-height: 120px; resize: vertical; }
.submit-btn { width: 100%; padding: 15px; background: #e74c3c; color: #fff; border: none; border-radius: 8px; font-size: 16px; cursor: pointer; transition: background 0.3s; }
.submit-btn:hover { background: #c0392b; }

/* 底部 */
.footer { background: #2c3e50; color: #fff; padding: 50px 0 20px; }
.footer-content { display: flex; justify-content: space-between; margin-bottom: 30px; }
.footer-info h3 { font-size: 20px; margin-bottom: 20px; }
.footer-info p { margin-bottom: 10px; opacity: 0.8; }
.footer-qrcode { text-align: center; }
.footer-qrcode img { width: 120px; height: 120px; background: #fff; padding: 10px; border-radius: 10px; }
.footer-qrcode p { margin-top: 10px; }
.copyright { text-align: center; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.1); opacity: 0.6; font-size: 14px; }

/* ===== 响应式设计 ===== */

/* 平板电脑 (768px - 1024px) */
@media (max-width: 1024px) {
    .container { padding: 0 15px; }
    
    /* 头部 */
    .header .container { height: auto; padding: 15px; flex-wrap: wrap; }
    .nav ul { gap: 20px; }
    .logo img { height: 40px; }
    
    /* 横幅 */
    .banner { padding: 60px 0; }
    .banner-content h1 { font-size: 32px; }
    .banner-content p { font-size: 16px; }
    
    /* 统计 */
    .about-content { gap: 30px; }
    .stat-num { font-size: 36px; }
    
    /* 技术卡片 */
    .tech-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    
    /* 案例卡片 */
    .cases-grid { grid-template-columns: repeat(2, 1fr); }
    
    /* 底部 */
    .footer-content { gap: 30px; }
}

/* 手机横屏 / 小平板 (576px - 768px) */
@media (max-width: 768px) {
    /* 头部 */
    .header .container { flex-direction: column; gap: 15px; }
    .logo { text-align: center; max-width: 250px; }
    .logo img { height: auto; max-width: 100%; max-height: 90px; width: auto; }
    .nav { width: 100%; }
    .nav ul { justify-content: center; flex-wrap: wrap; gap: 10px 20px; }
    .nav a { font-size: 14px; }
    .header-right { width: 100%; text-align: center; }
    .consult-btn { display: inline-block; width: auto; }
    
    /* 横幅 */
    .banner { padding: 40px 0; }
    .banner-content h1 { font-size: 26px; }
    .banner-content p { font-size: 14px; }
    
    /* 通用区块 */
    .section { padding: 40px 0; }
    .section-title { font-size: 24px; margin-bottom: 30px; }
    
    /* 企业简介 */
    .about-content { flex-direction: column; gap: 30px; }
    .about-text { text-align: center; }
    .about-stats { width: 100%; justify-content: space-around; }
    
    /* 技术卡片 */
    .tech-grid { grid-template-columns: 1fr; }
    .tech-card { padding: 30px 20px; }
    .tech-icon { font-size: 36px; }
    
    /* 案例卡片 */
    .cases-grid { grid-template-columns: 1fr; }
    .case-thumb { height: 200px; }
    
    /* 新闻 */
    .news-item { flex-direction: column; gap: 15px; }
    .news-date { width: auto; padding: 10px 20px; }
    
    /* 留言表单 */
    .message-form { padding: 25px; }
    .form-row { flex-direction: column; gap: 0; }
    
    /* 底部 */
    .footer { padding: 40px 0 20px; }
    .footer-content { flex-direction: column; text-align: center; }
    .footer-qrcode { margin-top: 20px; }
    
    /* 文章页 */
    .article-header h1 { font-size: 22px; }
    .article-meta { flex-wrap: wrap; gap: 10px; }
}

/* 手机竖屏 (小于 576px) */
@media (max-width: 576px) {
    .container { padding: 0 10px; }
    
    /* 头部 */
    .header .container { padding: 10px; }
    .nav ul { gap: 8px 15px; }
    .nav a { font-size: 13px; padding: 5px 0; }
    .consult-btn { padding: 8px 20px; font-size: 14px; }
    
    /* 横幅 */
    .banner { padding: 30px 0; }
    .banner-content h1 { font-size: 22px; }
    .banner-content p { font-size: 13px; }
    
    /* 通用区块 */
    .section { padding: 30px 0; }
    .section-title { font-size: 20px; }
    
    /* 统计 */
    .stat-num { font-size: 28px; }
    .stat-label { font-size: 12px; }
    
    /* 卡片 */
    .tech-card { padding: 20px 15px; }
    .tech-card h3 { font-size: 16px; }
    .tech-card p { font-size: 13px; }
    
    .case-info { padding: 15px; }
    .case-info h3 { font-size: 14px; }
    .case-info p { font-size: 12px; }
    
    /* 新闻 */
    .news-content h3 { font-size: 16px; }
    .news-content p { font-size: 13px; }
    
    /* 留言表单 */
    .message-form { padding: 20px 15px; }
    .form-group input, .form-group textarea { padding: 10px 12px; font-size: 14px; }
    .submit-btn { padding: 12px; font-size: 15px; }
    
    /* 底部 */
    .footer-info h3 { font-size: 16px; }
    .footer-info p { font-size: 13px; }
    .copyright p { font-size: 12px; }
    
    /* 文章页 */
    .article-page .container { padding: 15px 10px; }
    .article-header h1 { font-size: 18px; }
    .article-content { font-size: 15px; line-height: 1.8; }
    .related-articles h3 { font-size: 16px; }
}

/* 高分辨率屏幕优化 */
@media (min-width: 1400px) {
    .container { max-width: 1320px; }
    .tech-grid { grid-template-columns: repeat(3, 1fr); }
    .cases-grid { grid-template-columns: repeat(4, 1fr); }
}

/* 打印样式 */
@media print {
    .header, .footer, .message-section, .consult-btn { display: none; }
    .banner { background: none; color: #000; padding: 20px 0; }
    .section { padding: 20px 0; }
    .tech-card, .case-card, .news-item { break-inside: avoid; }
}
