/* 疾病百科页面样式 */

.diseases-page {
    background: #f8fafc;
    min-height: 100vh;
}

/* 疾病搜索区域 */
.disease-search-section {
    background: white;
    padding: 40px 0;
    margin-bottom: 30px;
    border-bottom: 1px solid #e5e7eb;
}

.search-header {
    text-align: center;
    margin-bottom: 30px;
}

.search-header h1 {
    color: #1f2937;
    margin-bottom: 10px;
    font-size: 28px;
}

.search-header p {
    color: #6b7280;
    font-size: 16px;
}

.disease-search-form {
    max-width: 600px;
    margin: 0 auto 30px auto;
}

.search-input-group {
    display: flex;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 50px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

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

.search-btn {
    background: #4f46e5;
    color: white;
    border: none;
    padding: 15px 30px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
}

.search-btn:hover {
    background: #4338ca;
}

/* 快速导航 */
.quick-nav {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.nav-title {
    color: #6b7280;
    margin-bottom: 15px;
    font-size: 14px;
}

.nav-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.nav-links a {
    padding: 8px 16px;
    background: #f3f4f6;
    color: #4b5563;
    text-decoration: none;
    border-radius: 20px;
    font-size: 14px;
    transition: all 0.2s;
}

.nav-links a:hover {
    background: #4f46e5;
    color: white;
}

/* 布局 */
.diseases-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
    align-items: start;
}

/* 筛选侧边栏 */
.diseases-filters {
    background: white;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    overflow: hidden;
    position: sticky;
    top: 20px;
}

.filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
}

.filters-header h3 {
    margin: 0;
    color: #1f2937;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.clear-filters {
    color: #4f46e5;
    text-decoration: none;
    font-size: 14px;
}

.clear-filters:hover {
    text-decoration: underline;
}

.filter-group {
    padding: 20px;
    border-bottom: 1px solid #e5e7eb;
}

.filter-group:last-child {
    border-bottom: none;
}

.filter-group h4 {
    margin: 0 0 15px 0;
    color: #1f2937;
    font-size: 14px;
    font-weight: 600;
}

.filter-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    color: #6b7280;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.2s;
}

.filter-option:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.filter-option.active {
    background: #eef2ff;
    color: #4f46e5;
    font-weight: 500;
}

/* 严重程度徽章 */
.difficulty-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    color: white;
}

.difficulty-badge.difficulty-mild {
    background: #10b981;
}

.difficulty-badge.difficulty-normal {
    background: #f59e0b;
}

.difficulty-badge.difficulty-severe {
    background: #ef4444;
}

.difficulty-badge.difficulty-critical {
    background: #dc2626;
}

/* 热门疾病 */
.popular-diseases {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.popular-item {
    padding: 12px;
    border: 1px solid #f3f4f6;
    border-radius: 8px;
    transition: all 0.2s;
}

.popular-item:hover {
    border-color: #e5e7eb;
    background: #fafafa;
}

.popular-item h5 {
    margin: 0 0 5px 0;
    font-size: 14px;
}

.popular-item h5 a {
    color: #1f2937;
    text-decoration: none;
}

.popular-item h5 a:hover {
    color: #4f46e5;
}

.disease-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #6b7280;
}

.disease-meta .category {
    background: #f3f4f6;
    padding: 2px 6px;
    border-radius: 10px;
}

.disease-meta .views {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 字母导航 */
.alphabet-nav {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 5px;
}

.alphabet-link {
    padding: 6px;
    text-align: center;
    color: #6b7280;
    text-decoration: none;
    border-radius: 4px;
    font-size: 12px;
    transition: all 0.2s;
}

.alphabet-link:hover {
    background: #4f46e5;
    color: white;
}

/* 主内容区 */
.diseases-main {
    background: white;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    overflow: hidden;
}

/* 搜索结果头部 */
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    border-bottom: 1px solid #e5e7eb;
    background: #f9fafb;
}

.results-info h2 {
    margin: 0 0 5px 0;
    color: #1f2937;
    font-size: 20px;
}

.results-info p {
    margin: 0;
    color: #6b7280;
    font-size: 14px;
}

.results-sort select {
    padding: 8px 15px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: white;
    color: #6b7280;
    font-size: 14px;
}

/* 疾病列表 */
.diseases-list {
    padding: 30px;
}

.letter-group {
    margin-bottom: 40px;
}

.letter-header {
    font-size: 24px;
    font-weight: 700;
    color: #4f46e5;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eef2ff;
}

.letter-diseases {
    display: grid;
    gap: 20px;
}

.disease-card {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 20px;
    border: 1px solid #f3f4f6;
    border-radius: 12px;
    transition: all 0.3s;
    background: white;
}

.disease-card:hover {
    border-color: #e5e7eb;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.disease-content {
    flex: 1;
    min-width: 0;
}

.disease-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.disease-name {
    margin: 0 0 8px 0;
    font-size: 18px;
}

.disease-name a {
    color: #1f2937;
    text-decoration: none;
}

.disease-name a:hover {
    color: #4f46e5;
}

.disease-badges {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.category-badge {
    background: #eef2ff;
    color: #4f46e5;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.disease-symptoms {
    margin-bottom: 10px;
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
}

.disease-symptoms strong {
    color: #1f2937;
}

.disease-description {
    margin-bottom: 15px;
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
}

.disease-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 120px;
    flex-shrink: 0;
    margin-left: 20px;
}

.disease-actions .btn {
    padding: 8px 12px;
    border-radius: 6px;
    text-decoration: none;
    text-align: center;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    border: 1px solid transparent;
    cursor: pointer;
}

.btn-primary {
    background: #4f46e5;
    color: white;
}

.btn-primary:hover {
    background: #4338ca;
}

/* 最新更新区域 */
.recent-updates-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #e5e7eb;
}

.recent-updates-section h3 {
    margin-bottom: 20px;
    color: #1f2937;
    font-size: 18px;
}

.recent-diseases {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.recent-item {
    padding: 15px;
    background: #f9fafb;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}

.recent-item h5 {
    margin: 0 0 8px 0;
    font-size: 14px;
}

.recent-item h5 a {
    color: #1f2937;
    text-decoration: none;
}

.recent-item h5 a:hover {
    color: #4f46e5;
}

.recent-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #6b7280;
}

/* 疾病详情页样式 */
.disease-detail-page {
    background: #f8fafc;
    min-height: 100vh;
}

.disease-detail-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 30px;
    align-items: start;
}

/* 疾病资料卡片 */
.disease-profile-card {
    background: white;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    overflow: hidden;
    margin-bottom: 30px;
}

.disease-profile-card .disease-header {
    padding: 30px;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
}

.disease-title-section {
    margin-bottom: 20px;
}

.disease-profile-card .disease-name {
    font-size: 32px;
    margin: 0 0 15px 0;
    font-weight: 700;
}

.disease-profile-card .disease-badges {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.disease-profile-card .category-badge,
.disease-profile-card .difficulty-badge {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.2);
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 13px;
    font-weight: 500;
}

.contagious-badge {
    background: rgba(239, 68, 68, 0.2) !important;
    color: #fecaca !important;
}

.disease-stats {
    display: flex;
    gap: 20px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.disease-profile-card .disease-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.disease-profile-card .btn {
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 2px solid transparent;
    cursor: pointer;
}

.disease-profile-card .btn-primary {
    background: white;
    color: #4f46e5;
    border-color: white;
}

.disease-profile-card .btn-primary:hover {
    background: #f8fafc;
}

.disease-profile-card .btn-outline {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
}

.disease-profile-card .btn-outline:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* 疾病概述 */
.disease-overview {
    padding: 30px;
    border-top: 1px solid #e5e7eb;
}

.disease-overview h3 {
    margin: 0 0 15px 0;
    color: #1f2937;
    font-size: 18px;
}

.overview-content {
    color: #6b7280;
    line-height: 1.6;
    font-size: 15px;
}

/* 标签页 */
.disease-tabs {
    background: white;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    overflow: hidden;
}

.tab-navigation {
    display: flex;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    flex-wrap: wrap;
}

.tab-btn {
    flex: 1;
    padding: 15px 20px;
    border: none;
    background: none;
    color: #6b7280;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    border-bottom: 3px solid transparent;
    min-width: 120px;
}

.tab-btn:hover {
    color: #1f2937;
    background: #f3f4f6;
}

.tab-btn.active {
    color: #4f46e5;
    background: white;
    border-bottom-color: #4f46e5;
}

.tab-content {
    padding: 30px;
}

.tab-panel {
    display: none;
}

.tab-panel.active {
    display: block;
}

/* 内容区块 */
.content-section {
    margin-bottom: 30px;
}

.content-section h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 15px 0;
    color: #1f2937;
    font-size: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f3f4f6;
}

.content-section h3 i {
    color: #4f46e5;
}

.symptoms-content,
.causes-content,
.treatment-content,
.prevention-content,
.diet-content,
.care-content {
    color: #6b7280;
    line-height: 1.6;
    font-size: 15px;
}

/* 严重程度指示器 */
.severity-indicator {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
}

.severity-level {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.level-text {
    font-size: 24px;
    font-weight: 700;
    padding: 10px 20px;
    border-radius: 25px;
    color: white;
}

.severity-level.severity-mild .level-text {
    background: #10b981;
}

.severity-level.severity-normal .level-text {
    background: #f59e0b;
}

.severity-level.severity-severe .level-text {
    background: #ef4444;
}

.severity-level.severity-critical .level-text {
    background: #dc2626;
}

.level-description {
    color: #6b7280;
    font-size: 14px;
}

/* 警告提醒 */
.warning-notice {
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 8px;
    padding: 15px;
    color: #92400e;
}

.warning-notice p {
    margin: 0;
    line-height: 1.5;
}

/* 侧边栏 */
.disease-sidebar {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

/* 快速操作 */
.quick-actions .action-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    color: #1f2937;
    text-decoration: none;
    transition: all 0.2s;
}

.action-btn:hover {
    background: #4f46e5;
    color: white;
    border-color: #4f46e5;
}

.action-btn i {
    color: #4f46e5;
    font-size: 16px;
}

.action-btn:hover i {
    color: white;
}

/* 相关疾病 */
.related-diseases {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.related-item {
    padding: 15px;
    border: 1px solid #f3f4f6;
    border-radius: 8px;
    transition: all 0.2s;
}

.related-item:hover {
    border-color: #e5e7eb;
    background: #fafafa;
}

.related-item h5 {
    margin: 0 0 8px 0;
    font-size: 14px;
}

.related-item h5 a {
    color: #1f2937;
    text-decoration: none;
}

.related-item h5 a:hover {
    color: #4f46e5;
}

.related-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}

.related-meta .views {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #6b7280;
}

/* 相关医生 */
.related-doctors {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.doctor-item {
    display: flex;
    gap: 12px;
    padding: 15px;
    border: 1px solid #f3f4f6;
    border-radius: 8px;
    transition: all 0.2s;
}

.doctor-item:hover {
    border-color: #e5e7eb;
    background: #fafafa;
}

.doctor-item .doctor-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.doctor-item .doctor-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.doctor-item .avatar-placeholder {
    width: 50px;
    height: 50px;
    background: #f3f4f6;
    color: #6b7280;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 20px;
}

.doctor-item .doctor-info h5 {
    margin: 0 0 5px 0;
    font-size: 14px;
}

.doctor-item .doctor-info h5 a {
    color: #1f2937;
    text-decoration: none;
}

.doctor-item .doctor-info h5 a:hover {
    color: #4f46e5;
}

.doctor-item .doctor-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 5px;
}

.doctor-item .doctor-meta span {
    font-size: 12px;
    color: #6b7280;
}

.doctor-item .doctor-rating {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 12px;
}

.doctor-item .doctor-rating i {
    color: #fbbf24;
}

.doctor-item .doctor-rating .far {
    color: #d1d5db;
}

/* 相关问答 */
.related-questions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.question-item {
    padding: 15px;
    border: 1px solid #f3f4f6;
    border-radius: 8px;
    transition: all 0.2s;
}

.question-item:hover {
    border-color: #e5e7eb;
    background: #fafafa;
}

.question-item h5 {
    margin: 0 0 8px 0;
    font-size: 14px;
    line-height: 1.4;
}

.question-item h5 a {
    color: #1f2937;
    text-decoration: none;
}

.question-item h5 a:hover {
    color: #4f46e5;
}

.question-meta {
    display: flex;
    gap: 15px;
    font-size: 12px;
    color: #6b7280;
}

.question-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 健康提醒 */
.health-reminder {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.health-reminder .widget-title {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
}

.reminder-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.reminder-item {
    display: flex;
    gap: 12px;
}

.reminder-item i {
    color: rgba(255, 255, 255, 0.8);
    font-size: 16px;
    margin-top: 2px;
    flex-shrink: 0;
}

.reminder-item p {
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    line-height: 1.4;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .diseases-layout,
    .disease-detail-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .diseases-filters {
        position: static;
    }
    
    .disease-sidebar {
        order: -1;
    }
}

@media (max-width: 768px) {
    .nav-links {
        justify-content: flex-start;
    }
    
    .disease-card {
        flex-direction: column;
        gap: 15px;
    }
    
    .disease-actions {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .disease-actions .btn {
        flex: 1;
        min-width: 120px;
    }
    
    .disease-profile-card .disease-actions {
        flex-direction: column;
    }
    
    .tab-navigation {
        flex-direction: column;
    }
    
    .tab-btn {
        min-width: auto;
    }
    
    .alphabet-nav {
        grid-template-columns: repeat(8, 1fr);
    }
    
    .recent-diseases {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .search-input-group {
        flex-direction: column;
        border-radius: 12px;
    }
    
    .search-btn {
        border-radius: 0 0 10px 10px;
    }
    
    .disease-card {
        padding: 15px;
    }
    
    .disease-profile-card .disease-header {
        padding: 20px;
    }
    
    .disease-profile-card .disease-name {
        font-size: 24px;
    }
    
    .tab-content {
        padding: 20px;
    }
    
    .disease-sidebar {
        gap: 20px;
    }
}