/* 临床试验博客 - 专业医疗科技风格 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #0ea5e9;
    --primary-hover: #0284c7;
    --primary-light: #38bdf8;
    --secondary-color: #06b6d4;
    --accent-color: #22d3ee;
    --background-color: #0c1222;
    --surface-color: #1e3a5f;
    --surface-hover: #2d4a6f;
    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border-color: #334155;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --gradient-primary: linear-gradient(135deg, #0ea5e9 0%, #06b6d4 50%, #22d3ee 100%);
    --gradient-surface: linear-gradient(180deg, #1e3a5f 0%, #0c1222 100%);
    --shadow-sm: 0 2px 8px rgba(14, 165, 233, 0.1);
    --shadow-md: 0 8px 24px rgba(14, 165, 233, 0.15);
    --shadow-lg: 0 20px 40px rgba(14, 165, 233, 0.2);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans SC', sans-serif;
    background-color: var(--background-color);
    color: var(--text-primary);
    line-height: 1.8;
    min-height: 100vh;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-light);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(12, 18, 34, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    padding: 14px 0;
}

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

.logo {
    font-size: 1.4rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-icon {
    font-size: 1.6rem;
}

.nav-links {
    display: flex;
    gap: 28px;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    padding: 6px 0;
}

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* 英雄区域 */
.hero {
    padding: 140px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
    background: var(--gradient-surface);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(14, 165, 233, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 80% 50%, rgba(6, 182, 212, 0.1) 0%, transparent 40%);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
}

.hero-icon {
    font-size: 4rem;
    margin-bottom: 24px;
    display: block;
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 20px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
}

.hero .subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto 40px;
    position: relative;
    line-height: 1.8;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    margin-top: 40px;
    position: relative;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: 4px;
}

/* 分类区域 */
.categories-section {
    padding: 80px 0;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 40px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.category-card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 28px;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.category-card:hover {
    transform: translateY(-6px);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.category-card:hover::before {
    transform: scaleX(1);
}

.category-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
    display: block;
}

.category-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.category-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.category-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* 文章列表 */
.articles-section {
    padding: 60px 0;
    background: var(--gradient-surface);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 28px;
}

.article-card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
}

.article-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.article-header {
    padding: 24px 24px 16px;
    border-bottom: 1px solid var(--border-color);
}

.article-category {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(14, 165, 233, 0.15);
    color: var(--primary-color);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-bottom: 12px;
}

.article-title {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.5;
    margin-bottom: 12px;
}

.article-excerpt {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-footer {
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.article-date {
    display: flex;
    align-items: center;
    gap: 6px;
}

.article-read-time {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* 文章详情页 */
.article-page {
    padding: 120px 0 80px;
}

.article-hero {
    text-align: center;
    margin-bottom: 60px;
}

.article-hero .category-tag {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(14, 165, 233, 0.15);
    color: var(--primary-color);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 20px;
}

.article-hero h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 20px;
    line-height: 1.4;
}

.article-meta {
    display: flex;
    justify-content: center;
    gap: 30px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.article-content {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.05rem;
    line-height: 2;
}

.article-content h2 {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 40px 0 20px;
    padding-left: 16px;
    border-left: 4px solid var(--primary-color);
}

.article-content h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 30px 0 15px;
}

.article-content p {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.article-content ul, .article-content ol {
    color: var(--text-secondary);
    margin-bottom: 20px;
    padding-left: 24px;
}

.article-content li {
    margin-bottom: 10px;
}

.article-content blockquote {
    background: rgba(14, 165, 233, 0.1);
    border-left: 4px solid var(--primary-color);
    padding: 20px 24px;
    margin: 30px 0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: var(--text-secondary);
}

.article-content code {
    background: rgba(14, 165, 233, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    font-family: 'Fira Code', monospace;
    font-size: 0.9em;
    color: var(--primary-light);
}

.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
}

.article-content th, .article-content td {
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    text-align: left;
}

.article-content th {
    background: var(--surface-color);
    color: var(--text-primary);
    font-weight: 600;
}

.article-content td {
    color: var(--text-secondary);
}

/* 相关文章 */
.related-articles {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid var(--border-color);
}

.related-title {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 24px;
    color: var(--text-primary);
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.related-card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.related-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.related-card-title {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.related-card-category {
    font-size: 0.8rem;
    color: var(--primary-color);
}

/* 外链区域 */
.external-links {
    padding: 60px 0;
    background: var(--surface-color);
    border-top: 1px solid var(--border-color);
}

.external-links-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 24px;
    text-align: center;
}

.links-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    max-width: 1000px;
    margin: 0 auto;
}

.link-item {
    display: inline-block;
    padding: 8px 16px;
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.link-item:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

/* 文本外链区域 */
.text-links-section {
    padding: 40px 0;
    background: var(--background-color);
    border-top: 1px solid var(--border-color);
}

.text-links-title {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 16px;
    text-align: center;
}

.text-links {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    max-width: 1000px;
    margin: 0 auto;
}

.text-link-item {
    color: var(--text-muted);
    font-size: 0.8rem;
    text-decoration: none;
    transition: color 0.3s ease;
}

.text-link-item:hover {
    color: var(--primary-color);
}

/* 页脚 */
.footer {
    padding: 40px 0;
    background: var(--background-color);
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.footer-content {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 16px;
}

.footer-links a {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.footer-links a:hover {
    color: var(--primary-color);
}

/* 面包屑导航 */
.breadcrumb {
    padding: 100px 0 20px;
    font-size: 0.9rem;
}

.breadcrumb-list {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
}

.breadcrumb-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.breadcrumb-item a {
    color: var(--text-secondary);
}

.breadcrumb-item a:hover {
    color: var(--primary-color);
}

.breadcrumb-separator {
    color: var(--text-muted);
}

/* 响应式 */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2rem;
    }

    .hero .subtitle {
        font-size: 1rem;
    }

    .hero-stats {
        flex-direction: column;
        gap: 24px;
    }

    .nav-links {
        display: none;
    }

    .categories-grid {
        grid-template-columns: 1fr;
    }

    .articles-grid {
        grid-template-columns: 1fr;
    }

    .article-hero h1 {
        font-size: 1.8rem;
    }

    .article-meta {
        flex-direction: column;
        gap: 12px;
    }

    .related-grid {
        grid-template-columns: 1fr;
    }
}

/* 淡入动画 */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 滚动条 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background-color);
}

::-webkit-scrollbar-thumb {
    background: var(--surface-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

::selection {
    background: var(--primary-color);
    color: white;
}