/* 希腊极简主义风格 - PLK1 知识库 */

/* CSS 变量定义 - 希腊风格配色 */
:root {
    --marble-white: #FAFAF8;
    --cream: #F5F2ED;
    --sand: #E8E2D5;
    --light-sand: #F0EBE3;
    --warm-gray: #D8D2C7;
    --olive-green: #6B7F5F;
    --deep-olive: #4A5A42;
    --aegean-blue: #5B7C99;
    --terracotta: #C67B5C;
    --charcoal: #2C2C2C;
    --stone-gray: #8B8680;
    --gold: #D4A574;
    
    --primary-bg: #F5F2ED;  /* 改为米色背景 */
    --secondary-bg: var(--cream);
    --card-bg: #E8E2D5;  /* 卡片背景改为沙色 */
    --text-primary: var(--charcoal);
    --text-secondary: #6B6560;  /* 深一些的次要文字 */
    --border-color: #C9C3B8;  /* 深一些的边框 */
    --accent-color: var(--olive-green);
    
    --serif-font: 'Playfair Display', Georgia, serif;
    --sans-font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 基础字体和背景 */
body {
    font-family: var(--sans-font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--primary-bg);
    font-weight: 400;
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* ====================== 过滤器提示栏样式 ====================== */
.filter-notice {
    background: var(--olive-green);
    color: white;
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 101;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.filter-notice p {
    margin: 0;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.filter-notice .filter-icon {
    font-size: 16px;
}

.filter-notice strong {
    font-weight: 600;
    color: white;
}

.filter-notice .filter-desc {
    font-size: 13px;
    opacity: 0.9;
}

.filter-notice .clear-filter {
    color: white;
    text-decoration: none;
    padding: 4px 12px;
    border: 1px solid rgba(255,255,255,0.5);
    border-radius: 4px;
    font-size: 13px;
    transition: all 0.2s ease;
    margin-left: 12px;
}

.filter-notice .clear-filter:hover {
    background: rgba(255,255,255,0.2);
    border-color: white;
}

/* 当有过滤器时调整导航栏 */
body:has(.filter-notice) header {
    top: 48px; /* 过滤器提示栏的高度 */
}

/* ====================== 导航栏样式 ====================== */
header {
    background: #FDFCFA;  /* 浅色导航栏保持对比 */
    border-bottom: 1px solid #C9C3B8;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

nav {
    padding: 24px 0;
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.site-logo {
  height: 50px;           /* 桌面端 40px */
  width: auto;
  border-radius: 6px;     /* 轻微圆角更柔和 */
}

.site-title-wrapper h1 {
  font-size: 1.35rem;
  line-height: 1.15;
  margin: 0;
}

.nav-brand h1 {
    font-family: var(--serif-font);
    font-size: 28px;
    font-weight: 400;
    color: var(--charcoal);
    letter-spacing: 0.02em;
}

.nav-brand h1 a {
    text-decoration: none;
    color: inherit;
}

.subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 300;
    margin-top: 4px;
    letter-spacing: 0.05em;
}

.nav-menu {
    list-style: none;
    display: flex;
    gap: 40px;
    align-items: center;
}

.nav-menu a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 400;
    letter-spacing: 0.02em;
    transition: color 0.2s ease;
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--olive-green);
    transition: width 0.2s ease;
}

.nav-menu a:hover {
    color: var(--olive-green);
}

.nav-menu a:hover::after {
    width: 100%;
}

/* ====================== 下拉菜单样式 ====================== */
.nav-menu .dropdown {
    position: relative;
}

.nav-menu .dropdown > a {
    cursor: pointer;
}

.nav-menu .dropdown > a::after {
    display: none; /* 移除导航链接的下划线 */
}

/* 下拉箭头 */
.nav-menu .dropdown > a::before {
    content: ' ▼';
    font-size: 0.7em;
    display: inline-block;
    margin-left: 4px;
    transition: transform 0.2s ease;
}

.nav-menu .dropdown:hover > a::before {
    transform: rotate(180deg);
}

/* 过滤器标记 */
.filter-badge {
    color: var(--olive-green);
    font-weight: 600;
    font-size: 0.85em;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    list-style: none;
    padding: 0;
    min-width: 250px;
    opacity: 0;
    visibility: hidden;
    margin-top: 12px;
    z-index: 1000;
    transition: all 0.3s ease;
}

/* 鼠标悬停时显示下拉菜单 */
.nav-menu .dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    display: block;
}

/* 下拉菜单项 */
.dropdown-menu li {
    margin: 0;
    padding: 0;
    list-style: none;
}

/* 下拉菜单标题样式 */
.dropdown-menu .dropdown-header {
    padding: 12px 20px 8px;
    font-weight: 600;
    color: var(--olive-green);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    background-color: var(--cream);
    border-bottom: 1px solid var(--border-color);
    cursor: default;
}

/* 下拉菜单链接 */
.dropdown-menu a {
    display: block;
    padding: 12px 20px;
    font-size: 14px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.2s ease;
    position: relative;
}

.dropdown-menu a::after {
    display: none; /* 移除下划线效果 */
}

.dropdown-menu a:hover {
    background: var(--sand);
    color: var(--olive-green);
    padding-left: 24px;
}

/* 激活的过滤器选项 */
.dropdown-menu a.active {
    background: var(--light-sand);
    color: var(--olive-green);
    font-weight: 500;
}

.dropdown-menu a .check {
    position: absolute;
    right: 20px;
    color: var(--olive-green);
}

/* 清除过滤器链接 */
.dropdown-menu .clear-filter-link {
    color: var(--terracotta) !important;
}

.dropdown-menu .clear-filter-link:hover {
    background: #fce4e4 !important;
}

/* 分隔线 */
.dropdown-divider {
    height: 0;
    margin: 8px 0;
    overflow: hidden;
    border-top: 1px solid var(--border-color);
}

/* ====================== 导航栏搜索表单 ====================== */
.search-item {
    margin-left: 20px;
}

.nav-search-form {
    display: flex;
    align-items: center;
    gap: 0;
}

.nav-search-input {
    padding: 8px 16px;
    background: white;
    border: 1px solid var(--border-color);
    border-right: none;
    font-size: 14px;
    color: var(--text-primary);
    width: 200px;
    transition: all 0.2s ease;
}

.nav-search-input:focus {
    outline: none;
    border-color: var(--olive-green);
    width: 250px;
}

.nav-search-btn {
    padding: 8px 16px;
    background: var(--olive-green);
    color: white;
    border: 1px solid var(--olive-green);
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.nav-search-btn:hover {
    background: var(--deep-olive);
    border-color: var(--deep-olive);
}

.search-icon {
    font-size: 14px;
}

/* ====================== 主要内容区域 ====================== */
main {
    min-height: calc(100vh - 200px);
    padding: 60px 0;
}

/* ====================== 英雄区域 - 带背景图片 ====================== */
.hero {
    position: relative;
    text-align: center;
    padding: 120px 0;
    margin-bottom: 80px;
    border-bottom: 1px solid var(--border-color);
    background-image: url('/images/hero-bg.jpg'); /* 替换为你的图片路径 */
    background-size: auto; /* 保持图片原始尺寸 */
    background-position: top left;
    background-repeat: repeat; /* 平铺 */
    background-attachment: fixed;
    overflow: hidden;
}

/* 背景图片遮罩层 */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        135deg,
        rgba(245, 242, 237, 0.85) 0%,  /* 降低透明度，让pattern更明显 */
        rgba(245, 242, 237, 0.82) 50%,
        rgba(232, 226, 213, 0.8) 100%
    );
    z-index: 1;
}

/* 确保所有内容在遮罩层之上 */
.hero > * {
    position: relative;
    z-index: 2;
}

.hero h2 {
    font-family: var(--serif-font);
    font-size: 48px;
    font-weight: 300;
    color: var(--charcoal);
    margin-bottom: 24px;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.hero p {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.8;
    text-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.hero-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
}

/* 暗色主题的 hero 样式（可选） */
.hero.dark-theme {
    color: white;
}

.hero.dark-theme::before {
    background: linear-gradient(
        135deg,
        rgba(44, 44, 44, 0.85) 0%,
        rgba(44, 44, 44, 0.8) 50%,
        rgba(107, 127, 95, 0.75) 100%
    );
}

.hero.dark-theme h2,
.hero.dark-theme p {
    color: white;
    text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

/* 按钮样式 - 扁平设计 */
.btn {
    display: inline-block;
    padding: 14px 32px;
    background: var(--olive-green);
    color: white;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0.02em;
    transition: all 0.2s ease;
    border: 2px solid var(--olive-green);
}

.btn:hover {
    background: var(--deep-olive);
    border-color: var(--deep-olive);
}

.btn-secondary {
    background: transparent;
    color: var(--olive-green);
    border: 2px solid var(--olive-green);
}

.btn-secondary:hover {
    background: var(--olive-green);
    color: white;
}

.btn-primary {
    background: var(--aegean-blue);
    border-color: var(--aegean-blue);
}

.btn-primary:hover {
    background: #4A6581;
    border-color: #4A6581;
}

/* 统计卡片 - 极简卡片 */
.stats {
    margin-bottom: 80px;
}

.stats h3 {
    font-family: var(--serif-font);
    text-align: center;
    margin-bottom: 48px;
    font-size: 36px;
    font-weight: 300;
    color: var(--charcoal);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.stat-card {
    background: #E8E2D5;  /* 沙色背景 */
    border: 1px solid #B8AFA2;  /* 更深的边框 */
    padding: 40px;
    text-align: center;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.stat-card:hover {
    border-color: var(--olive-green);
    box-shadow: 0 4px 8px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

.stat-number {
    font-family: var(--serif-font);
    font-size: 48px;
    font-weight: 300;
    color: var(--olive-green);
    line-height: 1;
}

.stat-label {
    color: var(--text-secondary);
    margin-top: 12px;
    font-size: 14px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* 快速访问 - 简洁网格 */
.quick-access h3 {
    font-family: var(--serif-font);
    text-align: center;
    margin-bottom: 48px;
    font-size: 36px;
    font-weight: 300;
    color: var(--charcoal);
}

.quick-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.quick-card {
    background: #E8E2D5;  /* 沙色背景 */
    border: 1px solid #B8AFA2;  /* 更深的边框 */
    padding: 32px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.quick-card:hover {
    border-color: var(--olive-green);
    box-shadow: 0 4px 8px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

.quick-card h4 {
    font-family: var(--serif-font);
    margin-bottom: 24px;
    color: var(--charcoal);
    font-size: 24px;
    font-weight: 400;
}

.quick-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.quick-links a {
    color: var(--text-primary);
    text-decoration: none;
    padding: 12px 0;
    border-bottom: 1px solid var(--cream);
    font-size: 15px;
    transition: all 0.2s ease;
}

.quick-links a:hover {
    color: var(--olive-green);
    padding-left: 8px;
}

/* 搜索表单 - 极简设计 */
.data-header {
    text-align: center;
    margin-bottom: 60px;
}

.data-header h2 {
    font-family: var(--serif-font);
    font-size: 42px;
    font-weight: 300;
    margin-bottom: 32px;
    color: var(--charcoal);
}

.search-form {
    display: flex;
    gap: 0;
    max-width: 600px;
    margin: 0 auto;
}

.search-form input {
    flex: 1;
    padding: 16px 24px;
    background: white;
    border: 1px solid var(--border-color);
    border-right: none;
    font-size: 16px;
    color: var(--text-primary);
}

.search-form input:focus {
    outline: none;
    border-color: var(--olive-green);
}

.search-form button {
    padding: 16px 32px;
    background: var(--olive-green);
    color: white;
    border: 1px solid var(--olive-green);
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.02em;
    transition: all 0.2s ease;
}

.search-form button:hover {
    background: var(--deep-olive);
    border-color: var(--deep-olive);
}

/* 数据信息 */
.data-info {
    text-align: center;
    margin-bottom: 40px;
    color: var(--text-secondary);
    font-size: 15px;
}

/* 生成综述按钮区域 */
.review-actions {
    margin: 40px 0;
    text-align: center;
    padding: 32px;
    background: var(--cream);
    border: 1px solid var(--border-color);
}

/* 页脚 - 极简设计 */
footer {
    background: #D8D2C7;  /* 深色页脚 */
    border-top: 1px solid #B8AFA2;
    color: var(--text-secondary);
    text-align: center;
    padding: 40px 0;
    margin-top: 80px;
}

.footer-note {
    font-size: 14px;
    margin-top: 8px;
}

/* 数据卡片样式 - 希腊极简风格 */
.data-cards {
    display: grid;
    gap: 24px;
    margin-top: 40px;
}

.data-card {
    background: #E8E2D5;  /* 沙色背景 */
    border: 1px solid #B8AFA2;  /* 更深的边框 */
    padding: 32px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);  /* 添加轻微阴影 */
}

.data-card:hover {
    border-color: var(--olive-green);
    box-shadow: 0 4px 8px rgba(0,0,0,0.12);  /* 悬停时阴影加深 */
    transform: translateY(-2px);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--cream);
}

.sn {
    font-family: var(--serif-font);
    font-size: 20px;
    font-weight: 300;
    color: var(--charcoal);
}

/* 置信度样式 - 扁平设计 */
.confidence {
    padding: 6px 16px;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: transparent;
    border: 1px solid;
}

.confidence-高 {
    color: var(--olive-green);
    border-color: var(--olive-green);
}

.confidence-中 {
    color: var(--gold);
    border-color: var(--gold);
}

.confidence-低 {
    color: var(--terracotta);
    border-color: var(--terracotta);
}

.confidence-未知 {
    color: var(--stone-gray);
    border-color: var(--stone-gray);
}

/* 三元组显示 */
.triple-display {
    margin: 24px 0;
}

.triple-parts {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 24px;
}

.triple-parts > div {
    text-align: center;
}

.triple-parts .label {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: block;
    margin-bottom: 8px;
}

.triple-parts .value {
    font-size: 16px;
    font-weight: 500;
    color: var(--charcoal);
    display: block;
    margin-bottom: 4px;
}

.triple-parts .type {
    font-size: 14px;
    color: var(--text-secondary);
    font-style: italic;
}

.triple-parts .arrow {
    color: var(--olive-green);
    font-size: 20px;
}

.predicate .value {
    color: var(--olive-green);
}

.triple-raw {
    margin-top: 20px;
    padding: 16px;
    background: var(--cream);
    border-left: 3px solid var(--sand);
    font-size: 14px;
    color: var(--text-secondary);
    font-style: italic;
}

/* 元数据 */
.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--cream);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-secondary);
}

.meta-item .icon {
    font-size: 16px;
    opacity: 0.6;
}

.meta-item a {
    color: var(--olive-green);
    text-decoration: none;
    transition: color 0.2s ease;
}

.meta-item a:hover {
    color: var(--deep-olive);
    text-decoration: underline;
}

/* 操作按钮 */
.card-actions {
    margin-top: 24px;
    text-align: right;
}

.btn-small {
    display: inline-block;
    padding: 10px 24px;
    background: transparent;
    color: var(--olive-green);
    text-decoration: none;
    border: 1px solid var(--olive-green);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
    transition: all 0.2s ease;
}

.btn-small:hover {
    background: var(--olive-green);
    color: white;
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 32px;
    margin-top: 60px;
}

.page-link {
    padding: 12px 24px;
    background: white;
    color: var(--charcoal);
    text-decoration: none;
    border: 1px solid var(--border-color);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
    transition: all 0.2s ease;
}

.page-link:hover {
    border-color: var(--olive-green);
    color: var(--olive-green);
}

.page-info {
    color: var(--text-secondary);
    font-size: 14px;
    letter-spacing: 0.05em;
}

/* 无数据提示 */
.no-data {
    text-align: center;
    padding: 80px 40px;
    background: white;
    border: 1px solid var(--border-color);
}

.no-data p {
    color: var(--text-secondary);
    font-size: 18px;
    margin-bottom: 32px;
    font-style: italic;
}

/* 详情页面样式 */
.detail-container {
    background: white;
    border: 1px solid var(--border-color);
    padding: 48px;
    margin-top: 40px;
}

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 40px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.detail-header h2 {
    font-family: var(--serif-font);
    font-size: 36px;
    font-weight: 300;
    color: var(--charcoal);
}

/* 三元组可视化 */
.triple-section {
    background: var(--cream);
    padding: 40px;
    margin-bottom: 40px;
}

.triple-section h3 {
    font-family: var(--serif-font);
    color: var(--charcoal);
    margin-bottom: 32px;
    font-size: 24px;
    font-weight: 400;
}

.triple-visualization {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    margin-bottom: 32px;
}

.entity {
    background: white;
    border: 1px solid var(--border-color);
    padding: 24px;
    text-align: center;
    min-width: 200px;
}

.entity h4 {
    color: var(--charcoal);
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 8px;
}

.entity p {
    color: var(--text-secondary);
    font-size: 14px;
    margin: 4px 0;
}

.entity .level {
    font-style: italic;
    font-size: 13px;
}

.relation {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.arrow-line {
    width: 100px;
    height: 1px;
    background: var(--olive-green);
    margin: 0 auto;
    position: relative;
}

.arrow-line::after {
    content: '→';
    position: absolute;
    right: -10px;
    top: -10px;
    color: var(--olive-green);
    font-size: 20px;
}

.predicate-box {
    background: white;
    border: 1px solid var(--olive-green);
    padding: 16px 24px;
    margin-top: 16px;
}

.predicate-box h4 {
    color: var(--olive-green);
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 4px;
}

.predicate-box p {
    color: var(--text-secondary);
    font-size: 14px;
    margin: 0;
}

/* 详情网格 */
.detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 32px;
}

.detail-section {
    background: var(--cream);
    padding: 32px;
}

.detail-section h3 {
    font-family: var(--serif-font);
    color: var(--charcoal);
    font-size: 20px;
    font-weight: 400;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--sand);
}

.detail-table {
    width: 100%;
}

.detail-table tr {
    border-bottom: 1px solid var(--sand);
}

.detail-table tr:last-child {
    border-bottom: none;
}

.detail-table td {
    padding: 12px 0;
    vertical-align: top;
    font-size: 15px;
}

.detail-table .label {
    font-weight: 500;
    color: var(--text-secondary);
    width: 40%;
}

.detail-table td:last-child {
    color: var(--text-primary);
}

/* PMID 链接 */
.pmid-link {
    color: var(--olive-green);
    text-decoration: none;
    transition: color 0.2s ease;
}

.pmid-link:hover {
    color: var(--deep-olive);
    text-decoration: underline;
}

.external-link {
    font-size: 12px;
    margin-left: 4px;
}

/* 操作按钮 */
.detail-actions {
    margin-top: 48px;
    display: flex;
    gap: 16px;
    justify-content: center;
}

/* 模态框样式 */
.review-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    border-radius: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    padding: 24px 32px;
    background: var(--cream);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-family: var(--serif-font);
    font-size: 24px;
    font-weight: 400;
    color: var(--charcoal);
}

.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: var(--charcoal);
}

.modal-body {
    padding: 32px;
    overflow-y: auto;
    flex: 1;
}

.review-content {
    line-height: 1.8;
    color: var(--text-primary);
    font-size: 16px;
}

.modal-footer {
    padding: 20px 32px;
    background: var(--cream);
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 16px;
}

.btn-copy {
    background: var(--aegean-blue);
    border-color: var(--aegean-blue);
}

.btn-copy:hover {
    background: #4A6581;
    border-color: #4A6581;
}

/* 加载动画 */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--sand);
    border-top-color: var(--olive-green);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }
    
    /* 移动端 hero 样式调整 */
    .hero {
        padding: 60px 0;
        background-attachment: scroll; /* 移动端禁用视差效果 */
    }
    
    .hero h2 {
        font-size: 36px;
    }
    
    .nav-menu {
        flex-direction: column;
        gap: 16px;
    }
    
    .stats-grid,
    .quick-grid {
        grid-template-columns: 1fr;
    }
    
    .search-form {
        flex-direction: column;
    }
    
    .search-form input {
        border-right: 1px solid var(--border-color);
        border-bottom: none;
    }
    
    .search-form button {
        width: 100%;
    }
    
    .triple-parts {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .data-card {
        padding: 24px;
    }
    
    .detail-grid {
        grid-template-columns: 1fr;
    }
}

/* 选择文本样式 */
::selection {
    background: var(--olive-green);
    color: white;
}

::-moz-selection {
    background: var(--olive-green);
    color: white;
}

/* ====================== 移动端响应式设计 ====================== */

/* 平板设备 (768px - 1024px) */
@media (max-width: 1024px) {
    .container {
        padding: 0 24px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .quick-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 手机设备 (max-width: 768px) */
@media (max-width: 768px) {
    /* 容器调整 */
    .container {
        padding: 0 16px;
    }
    
    /* 过滤器提示栏移动端 */
    .filter-notice p {
        font-size: 12px;
        flex-wrap: wrap;
        text-align: center;
    }
    
    .filter-notice .filter-desc {
        display: none;
    }
    
    /* 导航栏移动端优化 */
    header {
        position: fixed;
        width: 100%;
        background: rgba(253, 252, 250, 0.98);
        backdrop-filter: blur(10px);
    }
    
    nav {
        padding: 16px 0;
    }
    
    nav .container {
        flex-direction: column;
        gap: 16px;
    }
    
    .site-logo {
        height: 32px;         /* 移动端 32px，避免挤压文字 */
    }
    .nav-brand {
        gap: 8px;
    }
    .site-title-wrapper h1 {
        font-size: 1.15rem;
    }
    
    .nav-brand h1 {
        font-size: 22px;
        text-align: center;
    }
    
    .subtitle {
        font-size: 12px;
        text-align: center;
    }
    
    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
        padding: 0;
    }
    
    .nav-menu a {
        padding: 8px 12px;
        font-size: 14px;
    }
    
    /* 搜索框移动端 */
    .search-item {
        margin-left: 0;
        width: 100%;
    }
    
    .nav-search-form {
        width: 100%;
    }
    
    .nav-search-input {
        width: 100%;
    }
    
    .nav-search-input:focus {
        width: 100%;
    }
    
    /* 下拉菜单移动端 */
    .dropdown-menu {
        position: fixed;
        left: 16px;
        right: 16px;
        top: auto;
        width: auto;
        transform: none;
    }
    
    /* 主内容区域调整 */
    main {
        padding: 40px 0;
        margin-top: 120px; /* 为固定导航栏留空间 */
    }
    
    /* 当有过滤器时的调整 */
    body:has(.filter-notice) main {
        margin-top: 168px; /* 导航栏 + 过滤器提示栏 */
    }
    
    /* 英雄区域移动端 */
    .hero {
        padding: 40px 20px;
        margin-bottom: 40px;
    }
    
    .hero h2 {
        font-size: 32px;
        line-height: 1.2;
    }
    
    .hero p {
        font-size: 16px;
        margin-bottom: 24px;
    }
    
    .hero-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-actions .btn {
        width: 100%;
        text-align: center;
    }
    
    /* 按钮移动端优化 */
    .btn {
        padding: 16px 24px;
        font-size: 16px;
        touch-action: manipulation; /* 防止双击缩放 */
    }
    
    /* 统计卡片移动端 */
    .stats h3 {
        font-size: 28px;
        margin-bottom: 32px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .stat-card {
        padding: 24px;
    }
    
    .stat-number {
        font-size: 36px;
    }
    
    /* 快速访问移动端 */
    .quick-access h3 {
        font-size: 28px;
        margin-bottom: 32px;
    }
    
    .quick-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .quick-card {
        padding: 24px;
    }
    
    .quick-card h4 {
        font-size: 20px;
        margin-bottom: 16px;
    }
    
    /* 搜索表单移动端 */
    .data-header {
        margin-bottom: 32px;
    }
    
    .data-header h2 {
        font-size: 28px;
        margin-bottom: 20px;
    }
    
    .search-form {
        flex-direction: column;
        gap: 12px;
    }
    
    .search-form input {
        width: 100%;
        padding: 16px;
        font-size: 16px; /* 防止iOS缩放 */
        border-radius: 8px;
        border: 1px solid var(--border-color);
    }
    
    .search-form button {
        width: 100%;
        padding: 16px;
        font-size: 16px;
        border-radius: 8px;
    }
    
    /* 数据卡片移动端 */
    .data-cards {
        gap: 16px;
        margin-top: 24px;
    }
    
    .data-card {
        padding: 20px;
        border-radius: 8px;
    }
    
    .card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        margin-bottom: 20px;
    }
    
    .sn {
        font-size: 18px;
    }
    
    /* 三元组显示移动端 */
    .triple-parts {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .triple-parts > div {
        width: 100%;
        padding: 12px;
        background: rgba(255, 255, 255, 0.5);
        border-radius: 4px;
    }
    
    .triple-parts .arrow {
        display: none;
    }
    
    .predicate {
        background: rgba(107, 127, 95, 0.1);
        border: 1px solid var(--olive-green);
    }
    
    /* 元数据移动端 */
    .card-meta {
        flex-direction: column;
        gap: 12px;
        padding-top: 16px;
    }
    
    .meta-item {
        width: 100%;
    }
    
    /* 操作按钮移动端 */
    .card-actions {
        margin-top: 20px;
    }
    
    .btn-small {
        display: block;
        width: 100%;
        text-align: center;
        padding: 12px 20px;
    }
    
    /* 分页移动端 */
    .pagination {
        flex-wrap: wrap;
        gap: 12px;
        margin-top: 40px;
    }
    
    .page-link {
        padding: 12px 20px;
        font-size: 14px;
    }
    
    .page-info {
        width: 100%;
        text-align: center;
        order: -1;
        margin-bottom: 8px;
    }
    
    /* 详情页面移动端 */
    .detail-container {
        padding: 24px 16px;
        margin-top: 20px;
    }
    
    .detail-header {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
        margin-bottom: 24px;
        padding-bottom: 20px;
    }
    
    .detail-header h2 {
        font-size: 24px;
        line-height: 1.3;
    }
    
    /* 三元组可视化移动端 */
    .triple-section {
        padding: 20px;
        margin-bottom: 24px;
    }
    
    .triple-section h3 {
        font-size: 20px;
        margin-bottom: 20px;
    }
    
    /* 详情网格移动端 */
    .detail-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .detail-section {
        padding: 20px;
    }
    
    .detail-section h3 {
        font-size: 18px;
        margin-bottom: 16px;
    }
    
    .detail-table td {
        padding: 10px 0;
        font-size: 14px;
    }
    
    .detail-table .label {
        width: 35%;
        font-size: 13px;
    }
    
    /* 详情操作按钮移动端 */
    .detail-actions {
        flex-direction: column;
        gap: 12px;
        margin-top: 32px;
    }
    
    .detail-actions .btn {
        width: 100%;
    }
    
    /* 知识图谱移动端 */
    .kg-container {
        padding: 20px;
        margin-top: 20px;
    }
    
    .kg-description {
        font-size: 14px;
        margin-bottom: 24px;
    }
    
    .kg-node {
        padding: 12px 16px;
        font-size: 14px;
    }
    
    .kg-node-1 {
        font-size: 16px;
    }
    
    .kg-level-2 {
        margin-left: 16px;
    }
    
    .kg-actions {
        flex-direction: column;
        gap: 12px;
        margin-top: 32px;
    }
    
    .kg-actions .btn {
        width: 100%;
    }
    
    /* 上传页面移动端 */
    .upload-container {
        padding: 20px;
        margin-top: 20px;
    }
    
    .form-group input[type="file"] {
        padding: 16px;
        font-size: 14px;
    }
    
    .form-info {
        padding: 16px;
        margin-bottom: 20px;
    }
    
    .form-info h4 {
        font-size: 16px;
    }
    
    .form-info ul {
        font-size: 14px;
    }
    
    /* 模态框移动端 */
    .review-modal {
        padding: 16px;
    }
    
    .modal-content {
        width: 100%;
        max-width: none;
        height: calc(100vh - 32px);
        max-height: none;
        border-radius: 8px;
    }
    
    .modal-header {
        padding: 16px 20px;
    }
    
    .modal-header h2 {
        font-size: 20px;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .review-content {
        font-size: 14px;
        line-height: 1.7;
    }
    
    .modal-footer {
        padding: 16px 20px;
        flex-direction: column;
        gap: 12px;
    }
    
    .modal-footer .btn {
        width: 100%;
    }
    
    /* 页脚移动端 */
    footer {
        padding: 32px 16px;
        margin-top: 40px;
    }
    
    footer p {
        font-size: 14px;
    }
    
    .footer-note {
        font-size: 12px;
    }
    
    /* 生成综述按钮区域移动端 */
    .review-actions {
        margin: 20px 0;
        padding: 20px;
    }
    
    /* 加载动画移动端 */
    #reviewLoading {
        font-size: 14px;
    }
    
    /* 触摸优化 */
    a, button, .btn, .btn-small, .page-link {
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }
    
    /* 防止横向滚动 */
    body {
        overflow-x: hidden;
    }
    
    /* 提高可点击区域 */
    .nav-menu a,
    .quick-links a,
    .meta-item a {
        padding: 12px 8px;
        margin: -4px -8px;
    }
}

/* 小屏幕手机 (max-width: 375px) */
@media (max-width: 375px) {
    .container {
        padding: 0 12px;
    }
    
    .hero h2 {
        font-size: 28px;
    }
    
    .stat-number {
        font-size: 32px;
    }
    
    .data-card {
        padding: 16px;
    }
    
    .detail-container {
        padding: 20px 12px;
    }
}

/* 横屏模式优化 */
@media (max-width: 768px) and (orientation: landscape) {
    header {
        position: static;
    }
    
    main {
        margin-top: 0;
    }
    
    .hero {
        padding: 30px 20px;
    }
    
    .stats-grid,
    .quick-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* iOS 安全区域适配 */
@supports (padding: max(0px)) {
    .container {
        padding-left: max(16px, env(safe-area-inset-left));
        padding-right: max(16px, env(safe-area-inset-right));
    }
    
    footer {
        padding-bottom: max(32px, env(safe-area-inset-bottom));
    }
}

/* SVG 横图样式 */
.overview-diagram {
    margin: 80px 0;
    text-align: center;
}

.overview-diagram h3 {
    font-family: var(--serif-font);
    font-size: 36px;
    font-weight: 300;
    color: var(--charcoal);
    margin-bottom: 48px;
}

.diagram-container {
    background: white;
    border: 1px solid var(--border-color);
    padding: 40px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
    max-width: 1200px;
    margin: 0 auto;
}

/* 内联 SVG 样式 */
.diagram-container svg {
    width: 100%;
    height: auto;
    max-height: 500px;
}

/* 外部 SVG 图片样式 */
.overview-svg {
    width: 100%;
    height: auto;
    max-width: 100%;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .overview-diagram {
        margin: 40px 0;
    }
    
    .overview-diagram h3 {
        font-size: 28px;
        margin-bottom: 32px;
    }
    
    .diagram-container {
        padding: 20px;
    }
}