/* 靶向药博客 - 专业医疗科技风格 */
/* 配色：深蓝#1a5f7a + 青绿#2eb872 + 浅灰白#f8fafc + 橙色#e67e22 */

:root {
    --primary: #1a5f7a;
    --primary-dark: #134a5f;
    --secondary: #2eb872;
    --secondary-light: #48d68d;
    --accent: #e67e22;
    --bg-light: #f8fafc;
    --bg-white: #ffffff;
    --text-dark: #1e293b;
    --text-gray: #64748b;
    --border: #e2e8f0;
    --shadow: rgba(26, 95, 122, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.7;
}

/* 导航栏 */
.navbar {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px var(--shadow);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-logo::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--secondary);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.2); }
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--secondary-light);
}

/* 英雄区 */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, #0d3d4d 100%);
    color: white;
    padding: 5rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%232eb872' fill-opacity='0.1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    font-weight: 800;
}

.hero p {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.hero-btn {
    display: inline-block;
    background: var(--secondary);
    color: white;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
}

.hero-btn:hover {
    background: var(--secondary-light);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(46, 184, 114, 0.3);
}

/* 分类区域 */
.categories {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.section-title {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 2rem;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--secondary);
    margin: 1rem auto 0;
    border-radius: 2px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.category-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    text-decoration: none;
    color: var(--text-dark);
    transition: all 0.3s;
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--secondary);
    transform: scaleY(0);
    transition: transform 0.3s;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px var(--shadow);
}

.category-card:hover::before {
    transform: scaleY(1);
}

.category-card h3 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
}

.category-card p {
    color: var(--text-gray);
    font-size: 0.95rem;
}

/* 文章列表 */
.articles {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.article-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    text-decoration: none;
    color: var(--text-dark);
    transition: all 0.3s;
    border: 1px solid var(--border);
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px var(--shadow);
}

.article-image {
    height: 200px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.article-image span {
    color: white;
    font-size: 3rem;
}

.article-content {
    padding: 1.5rem;
}

.article-tag {
    display: inline-block;
    background: var(--bg-light);
    color: var(--primary);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
}

.article-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
    color: var(--text-dark);
}

.article-card p {
    color: var(--text-gray);
    font-size: 0.95rem;
    line-height: 1.6;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
    font-size: 0.85rem;
    color: var(--text-gray);
}

/* 文章详情页 */
.article-detail {
    max-width: 800px;
    margin: 3rem auto;
    padding: 0 2rem;
}

.article-header {
    margin-bottom: 2rem;
}

.article-header .tag {
    display: inline-block;
    background: var(--secondary);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.article-header h1 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
    line-height: 1.3;
}

.article-header .meta {
    color: var(--text-gray);
    font-size: 0.95rem;
}

.article-body {
    background: white;
    padding: 3rem;
    border-radius: 16px;
    box-shadow: 0 4px 20px var(--shadow);
}

.article-body h2 {
    color: var(--primary);
    font-size: 1.5rem;
    margin: 2rem 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--secondary);
}

.article-body h3 {
    color: var(--text-dark);
    font-size: 1.25rem;
    margin: 1.5rem 0 0.75rem;
}

.article-body p {
    margin-bottom: 1.25rem;
    text-align: justify;
}

.article-body ul, .article-body ol {
    margin: 1rem 0 1.5rem 1.5rem;
}

.article-body li {
    margin-bottom: 0.5rem;
}

.article-body blockquote {
    background: var(--bg-light);
    border-left: 4px solid var(--secondary);
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    border-radius: 0 8px 8px 0;
}

/* 相关文章 */
.related-articles {
    max-width: 800px;
    margin: 3rem auto;
    padding: 0 2rem;
}

.related-articles h2 {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.related-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-dark);
    border: 1px solid var(--border);
    transition: all 0.3s;
}

.related-card:hover {
    border-color: var(--secondary);
    box-shadow: 0 4px 15px var(--shadow);
}

.related-card h4 {
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.related-card p {
    color: var(--text-gray);
    font-size: 0.9rem;
}

/* 外链区域 */
.external-links {
    background: var(--bg-light);
    padding: 3rem 2rem;
    margin-top: 4rem;
}

.external-links h3 {
    text-align: center;
    color: var(--primary);
    margin-bottom: 2rem;
    font-size: 1.25rem;
}

.links-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.links-container a {
    background: white;
    color: var(--text-dark);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.9rem;
    border: 1px solid var(--border);
    transition: all 0.3s;
}

.links-container a:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* 页脚 */
.footer {
    background: var(--primary-dark);
    color: white;
    padding: 3rem 2rem;
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer p {
    opacity: 0.8;
    margin-bottom: 1rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--secondary-light);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .nav-links {
        display: none;
    }
    
    .article-grid {
        grid-template-columns: 1fr;
    }
    
    .related-grid {
        grid-template-columns: 1fr;
    }
    
    .article-body {
        padding: 1.5rem;
    }
}

/* 分类页标题 */
.category-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 3rem 2rem;
    text-align: center;
}

.category-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.category-header p {
    opacity: 0.9;
    font-size: 1.1rem;
}

/* 面包屑导航 */
.breadcrumb {
    max-width: 1200px;
    margin: 1.5rem auto;
    padding: 0 2rem;
}

.breadcrumb a {
    color: var(--text-gray);
    text-decoration: none;
}

.breadcrumb a:hover {
    color: var(--primary);
}

.breadcrumb span {
    color: var(--text-gray);
    margin: 0 0.5rem;
}
