/* =============================
   iGEM Wiki 内容页面样式 - 粉蓝配色主题
   ============================= */

/* CSS变量定义粉蓝主题 - 简约设计 */
:root {
    --content-primary: #FF6B9D;          /* 粉红色 - 主色调 */
    --content-primary-600: #FF4785;      /* 深粉色 - 悬停等 */
    --content-secondary: #4ECDC4;        /* 青绿色 - 辅助色 */
    --content-accent: #FFF5F8;           /* 极淡粉色背景 */
    --content-surface: #FFFFFF;          /* 纯白 */
    --content-surface-light: #FFFFFF;
    --content-border: #E5E7EB;           /* 中性灰边框 */
    --content-text: #1F2937;             /* 深灰文字 */
    --content-muted: #6B7280;            /* 中性灰 */
    --content-bg: #FAFBFC;               /* 极淡灰背景 */
}

.pdf_preview {
    width: 100%;
    height: 30vw;
    overflow: hidden;
    margin-bottom: 2rem;
    margin-top: 2rem;
}

.pdf_preview iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* smpt 加粗字体样式 */
smpt {
    color: var(--content-primary-600);
    font-weight: bold;
    font-size: 1.05em;
    letter-spacing: 0.02em;
}


/* em 斜体样式 - 简洁版，用于专业术语 */
em {
    font-style: italic;
}

/* 侧边栏中的斜体保持紧凑 */
.wiki-sidebar em {
    font-style: italic;
    display: inline;
}


  .cover_title{
    display: inline-block;
    will-change: transform, opacity;
    animation: heroFadeUp 700ms ease-out both;
    position: absolute;
    font-size: 9rem;
    font-weight: bold;
    /* left: 30%; */
    top: 40%;
    color: #fff;
    text-shadow: 1px 2px 2px #ff4b4b;
    font-family: 'Orbitron', serif;
    background-clip: text;
  }

  .cover_title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -0.14rem;
    height: 0.12rem;
    width: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(255,255,255,0.65), rgba(255,255,255,0.25));
    box-shadow: 0 2px 6px rgba(0,0,0,0.12);
    animation: heroUnderline 900ms 220ms ease-out forwards;
    pointer-events: none;
  }
  header:hover .cover_title { transform: translateY(-2px); }
  header:hover .diy-tit2 { transform: translateY(-1px); }

  @keyframes heroFadeUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
  }
  @keyframes heroUnderline {
    from { width: 0; opacity: 0; }
    60% { width: 70%; opacity: 1; }
    to { width: 100%; opacity: 1; }
  }
  @keyframes heroGradientShift {
    from { background-position: 0% 50%; }
    to { background-position: 100% 50%; }
  }

  /* Respect reduced motion */
  @media (prefers-reduced-motion: reduce) {
    header .cover_title,
    header .cover_title::after { animation: none; width: 100%; opacity: 1; }
  }

/* a 超链接样式 */
p a {
    color: var(--content-primary);
    text-decoration: none;
    transition: all 0.3s ease;
    border-bottom: 1px solid transparent;
    font-weight: 500;
    text-decoration: underline;
}



.content-card p a::after {
    content: "↗";
    font-size: 0.8em;
    margin-left: 4px;
}

.content-card p a:hover {
    color: var(--content-primary-600);
    /* border-bottom-color: var(--content-primary); */
    text-decoration: none;
    transform: translateY(-1px);
    background-color: var(--content-primary);
    color: white !important;
    padding: 0 4px;
    border-radius: 4px;
    padding: 4px;
}

p a:active {
    color: var(--content-primary);
    transform: translateY(0);
}

p a:visited {
    color: var(--content-primary-600);
    opacity: 0.8;
}

/* 主内容区域布局 */
.wiki-content-wrapper {
    max-width: none;
    margin: 0;
    padding: 60px 18vw 60px 10vw;
    position: relative;
    background: var(--content-bg);
    min-height: 100vh;
}

.wiki-main-content {
    padding-left: 0;
    min-height: 100vh;
}


.sidebar-title img {
    width: 100%;
    height: auto;
    max-width: 100% !important;
}

/* =============================
   侧边栏目录设计
   ============================= */
.page_content {
    display: flex;
    gap: 0;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
    position: relative;
}

.wiki-sidebar {
    position: sticky;
    top: 120px;
    flex-shrink: 0;
    width: var(--sidebar-width, 16vw);
    max-height: calc(100vh - 200px);
    /* background: var(--content-surface); */
    /* border: 2px solid var(--content-border); */
    border-radius: 0;
    padding: 0 12px 0 0;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 1;
    margin-left: 0;
    transition: width 0.1s ease-out;
}

/* 拖拽时的视觉反馈 */
body.resizing-sidebar {
    cursor: col-resize !important;
    user-select: none !important;
}

body.resizing-sidebar * {
    cursor: col-resize !important;
    user-select: none !important;
}

/* Mac 设备和高分辨率屏幕优化 */
@media (min-width: 1025px) and (max-width: 1920px) {
    /* 在中等屏幕上确保拖拽条可见性 */
    .wiki-content-wrapper::before {
        opacity: 0.35 !important;
        width: 3px !important;
        height: 80px !important;
    }
    
    .wiki-content-wrapper:hover::before,
    .wiki-content-wrapper.resizing::before {
        width: 28px !important;
        height: 100px !important;
    }
}

/* 超大屏幕（4K 等）优化 */
@media (min-width: 2560px) {
    .wiki-content-wrapper::before {
        width: 4px !important;
        height: 90px !important;
    }
    
    .wiki-content-wrapper:hover::before,
    .wiki-content-wrapper.resizing::before {
        width: 32px !important;
        height: 120px !important;
        font-size: 20px !important;
    }
}

/* 移动端和小屏幕隐藏拖拽条 */
@media (max-width: 1024px) {
    .wiki-sidebar {
        width: 25vw !important;
    }
    
    .wiki-content-wrapper {
        max-width: 70vw !important;
    }
    
    .wiki-content-wrapper::before,
    .wiki-content-wrapper::after {
        display: none !important;
    }
}

/* 确保拖拽条在小于1366px的屏幕上也正常显示 */
@media (max-width: 1366px) and (min-width: 1025px) {
    .wiki-content-wrapper::before {
        opacity: 0.4 !important;
    }
    
    .page_content:hover .wiki-content-wrapper::before {
        opacity: 0.5 !important;
    }
}

smpt {
    display: contents !important;
}


.wiki-content-wrapper {
    flex: 1;
    max-width: calc(100vw - var(--sidebar-width, 16vw) - 60px);
    margin: 0;
    padding: 0 !important;
    transition: max-width 0.1s ease-out;
    position: relative;
}

/* 拖拽分隔条 - 使用 ::before 伪元素 */
.wiki-content-wrapper::before {
    content: '⋮⋮⋮';
    position: fixed;
    left: calc(var(--sidebar-width, 16vw));
    top: 50%;
    transform: translate(-50%, -50%);
    width: 3px;
    height: 80px;
    background: linear-gradient(to bottom, 
        transparent 0%, 
        var(--content-primary) 15%, 
        var(--content-primary) 85%, 
        transparent 100%);
    cursor: col-resize;
    z-index: 100;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0.3;
    border-radius: 3px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: transparent;
    font-weight: bold;
    letter-spacing: -3px;
    line-height: 1.2;
}

/* 鼠标在页面内时，稍微明显一些 */
.page_content:hover .wiki-content-wrapper::before {
    opacity: 0.35;
}



/* 鼠标直接hover在拖拽条上时，完全显示并加宽，显示箭头图标 */
.wiki-content-wrapper:hover::before {
    content: '↔';
    opacity: 1;
    width: 28px;
    height: 100px;
    left: calc(var(--sidebar-width, 16vw));
    transform: translate(-50%, -50%);
    background: var(--content-primary);
    color: white;
    font-size: 18px;
    box-shadow: 0 2px 12px rgba(255, 107, 157, 0.4);
    border-radius: 6px;
    letter-spacing: 0;
}

/* 拖拽时，使用辅助色，显示箭头图标 */
.wiki-content-wrapper.resizing::before {
    content: '↔';
    background: var(--content-secondary);
    opacity: 1;
    width: 28px;
    height: 100px;
    left: calc(var(--sidebar-width, 16vw));
    transform: translate(-50%, -50%);
    color: white;
    font-size: 18px;
    box-shadow: 0 4px 20px rgba(78, 205, 196, 0.6);
    border-radius: 6px;
    letter-spacing: 0;
}

.content-card table smpt {
    color: #000 !important;
}

/* 拖拽分隔条扩大点击区域（不可见但可交互） */
.wiki-content-wrapper::after {
    content: '';
    position: fixed;
    left: calc(var(--sidebar-width, 16vw));
    transform: translateX(-50%);
    top: 0;
    width: 30px;
    height: 100vh;
    cursor: col-resize;
    z-index: 999;
    /* 调试用：取消注释可以看到实际点击区域 */
}

/* 拖拽提示工具提示 */
.resize-tooltip {
    position: fixed;
    background: linear-gradient(135deg, rgba(255, 107, 157, 0.95), rgba(255, 71, 133, 0.95));
    color: white;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    pointer-events: none;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    white-space: nowrap;
    box-shadow: 0 4px 16px rgba(255, 107, 157, 0.4), 0 2px 8px rgba(0, 0, 0, 0.2);
    transform: translateX(-5px);
}

.resize-tooltip.show {
    opacity: 1;
    transform: translateX(0);
}

.resize-tooltip::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    border-right: 8px solid rgba(255, 107, 157, 0.95);
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.resize-tooltip::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 8px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* 拖拽提示引导窗口 */
.resize-guide {
    position: fixed;
    left: calc(var(--sidebar-width, 16vw) + 35px);
    top: 50%;
    transform: translateY(-50%);
    background: white;
    border-radius: 12px;
    padding: 20px 24px;
    max-width: 280px;
    z-index: 9999;
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.15),
        0 8px 40px rgba(255, 107, 157, 0.2);
    border: 2px solid var(--content-primary);
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: auto;
}

.resize-guide.show {
    opacity: 1;
    visibility: visible;
}

.resize-guide::before {
    content: '';
    position: absolute;
    left: -12px;
    top: 50%;
    transform: translateY(-50%);
    border-right: 12px solid var(--content-primary);
    border-top: 12px solid transparent;
    border-bottom: 12px solid transparent;
}

.resize-guide-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--content-primary), var(--content-secondary));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 12px;
    animation: guideIconPulse 2s ease-in-out infinite;
}

@keyframes guideIconPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(255, 107, 157, 0.4); }
    50% { transform: scale(1.05); box-shadow: 0 0 0 8px rgba(255, 107, 157, 0); }
}

.resize-guide-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--content-text);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.resize-guide-desc {
    font-size: 13px;
    line-height: 1.6;
    color: var(--content-muted);
    margin-bottom: 14px;
}

.resize-guide-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.resize-guide-try {
    flex: 1;
    background: linear-gradient(135deg, var(--content-primary), var(--content-primary-600));
    color: white;
    border: none;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.resize-guide-try:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 107, 157, 0.4);
}

.resize-guide-close {
    width: 32px;
    height: 32px;
    background: rgba(0, 0, 0, 0.05);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--content-muted);
    transition: all 0.3s ease;
}

.resize-guide-close:hover {
    background: rgba(0, 0, 0, 0.1);
    color: var(--content-text);
}

/* 移动端隐藏引导 */
@media (max-width: 1024px) {
    .resize-guide {
        display: none;
    }
}

.sidebar-title {
    color: var(--content-text);
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 12px;
    letter-spacing: 0.5px;
    position: relative;
    text-align: center;
    width: calc(100% + 48px);
    margin-left: -24px;
    opacity: 0;
}

.sidebar-title img {
    width: 100%;
    height: auto;
    max-width: 200px;
    border-radius: 8px;
    margin-bottom: 10px;
}

.sidebar-title::after {
    /* content: "";
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, var(--content-primary-600), var(--content-primary));
    border-radius: 2px; */
}

.sidebar-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* 一级导航项 */
.sidebar-item-level1 {
    margin-bottom: 12px;
}

.sidebar-item-level1 > .nav-link {
    display: block;
    padding: 10px 12px;
    text-decoration: none;
    color: var(--content-text);
    border-radius: 0;
    font-weight: 600;
    font-size: 0.85rem;
    line-height: 1.6;
    background: transparent;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
    position: relative;
    word-break: break-word;
}

.sidebar-item-level1 > .nav-link:hover {
    background: var(--content-accent);
    border-left-color: var(--content-secondary);
    color: var(--content-text);
    text-decoration: none;
}

.sidebar-item-level1 > .nav-link.active {
    background: transparent;
    color: var(--content-primary);
    border-left-color: var(--content-primary);
    font-weight: 700;
}

/* 二级导航项 */
.sidebar-item-level2 {
    margin-bottom: 4px;
}

.sidebar-item-level2 > .nav-link {
    display: block;
    padding: 6px 12px 6px 24px;
    text-decoration: none;
    color: var(--content-muted);
    border-radius: 0;
    font-size: 0.8rem;
    font-weight: 400;
    line-height: 1.5;
    transition: all 0.2s ease;
}

.sidebar-item-level2 > .nav-link:hover {
    color: var(--content-text);
    text-decoration: underline;
}

.sidebar-item-level2 > .nav-link.active {
    color: var(--content-primary);
    font-weight: 600;
}

/* 滚动条样式 - 默认隐藏，hover显示 */
.wiki-sidebar::-webkit-scrollbar {
    width: 4px;
}

.wiki-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.wiki-sidebar::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
    border-radius: 2px;
    transition: background 0.2s ease;
}

.wiki-sidebar:hover::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.25);
}

.wiki-sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--content-primary);
}

/* =============================
   极简标题栏设计
   ============================= */
.section-header {
    background: transparent;
    border-radius: 0;
    padding: 0 0 16px 0;
    margin: 60px 0 40px 0;
    position: relative;
    border-bottom: 3px solid var(--content-primary);
    display: block;
    max-width: 100%;
}

.section-title {
    color: var(--content-text);
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0;
    font-family: 'Orbitron', serif;
    letter-spacing: -0.5px;
    text-transform: uppercase;
}

/* =============================
   极简卡片设计
   ============================= */
.content-card {
    background: var(--content-surface);
    border-radius: 0;
    padding: 50px;
    margin: 0 0 40px 0;
    border: 1px solid var(--content-border);
    /* border-left: 4px solid var(--content-primary); */
    line-height: 1.9;
    position: relative;
    width: 100%;
    max-width: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 
        0 1px 3px rgba(0, 0, 0, 0.05),
        0 4px 12px rgba(0, 0, 0, 0.04),
        0 8px 20px rgba(255, 107, 157, 0.08);
}

/* =============================
   标题样式设计（1-6级）
   ============================= */
.content-title {
    color: var(--content-text);
    font-weight: 700;
    margin-top: 2.5rem;
    margin-bottom: 1.5rem;
    position: relative;
    scroll-margin-top: 120px;
}

.content-title:first-child {
    margin-top: 0;
}

/* H1 - 主标题 */
.content-title.h1 {
    font-size: 2.6rem;
    color: var(--content-text);
    margin-top: 3rem;
    margin-bottom: 2rem;
    font-weight: 900;
    letter-spacing: -1px;
    position: relative;
    padding-left: 20px;
    border-left: 6px solid var(--content-primary);
}

/* H2 - 主要章节 */
.content-title.h2 {
    font-size: 2rem;
    color: var(--content-text);
    margin-top: 2.5rem;
    font-weight: 700;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--content-border);
}

/* H3 - 子章节 */
.content-title.h3 {
    font-size: 1.5rem;
    color: var(--content-text);
    margin-top: 2rem;
    font-weight: 600;
    padding-left: 16px;
    border-left: 4px solid var(--content-secondary);
}

/* H4 - 小节 */
.content-title.h4 {
    font-size: 1.4rem;
    color: var(--content-text);
    margin-top: 2rem;
}

/* H5 - 子小节 */
.content-title.h5 {
    font-size: 1.2rem;
    color: var(--content-text);
    margin-top: 1.8rem;
}

/* H6 - 细分项 */
.content-title.h6 {
    font-size: 1.1rem;
    color: var(--content-muted);
    font-weight: 600;
    margin-top: 1.5rem;
}

/* =============================
   内容元素样式
   ============================= */

/* 段落和文本 */
.content-card p {
    font-size: 1.15rem;
    color: var(--content-text);
    text-align: justify;
    line-height: 1.8;
    margin-bottom: 0;
}

.content-card ul, .content-card ol {
    margin-bottom: 2rem;
    padding-left: 2.5rem;
}

.content-card li {
    font-size: 1.1rem;
    color: var(--content-text);
    line-height: 1.8;
}

.content-card li strong {
    color: var(--content-primary);
    font-weight: 600;
}

/* 图片和媒体 */
.content-image {
    width: 100%;
    max-width: 100%;
    border-radius: 16px;
    /* box-shadow:
        0 12px 32px rgba(255, 107, 157, 0.12),
        0 4px 16px rgba(255, 107, 157, 0.08); */
    /* border: 1px solid rgba(255, 107, 157, 0.1); */
    margin: 0 auto;
    cursor: pointer;
}

/* iframe 视频居中 */
.content-card iframe {
    display: block;
    margin: 2rem auto;
    max-width: 100%;
    border-radius: 12px;
    box-shadow: 
        0 4px 16px rgba(0, 0, 0, 0.1),
        0 8px 24px rgba(255, 107, 157, 0.15);
}

/* 包含 iframe 的段落或容器居中 */
.content-card p:has(iframe),
.content-card span:has(iframe) {
    text-align: center;
    display: block;
    margin: 2rem 0;
}

/* 图片放大遮罩层 */
.image-lightbox-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    z-index: 99999;
    animation: fadeIn 0.3s ease;
    overflow: auto;
}

.image-lightbox-overlay.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    animation: zoomIn 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 60px 20px;
}

.image-lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    height: auto;
    width: auto;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    cursor: default;
}

.image-lightbox-close {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    color: white;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    z-index: 100000;
}

.image-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

/* 滚动条样式优化 */
.image-lightbox-overlay::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.image-lightbox-overlay::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.image-lightbox-overlay::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 5px;
}

.image-lightbox-overlay::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes zoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.image-caption {
    text-align: center !important;
    font-size: 0.95rem !important;
    color: var(--content-muted) !important;
    margin-top: 1rem !important;
}

/* 引用块 */
.content-quote {
    background: linear-gradient(135deg, var(--content-accent) 0%, rgba(240, 230, 247, 0.8) 100%);
    border-left: 6px solid var(--content-primary);
    padding: 24px 30px;
    margin: 3rem 0;
    border-radius: 0 16px 16px 0;
    font-style: italic;
    color: var(--content-text);
    font-size: 1.1rem;
    line-height: 1.7;
    position: relative;
    box-shadow: 0 6px 20px rgba(255, 107, 157, 0.1);
}

.content-quote::before {
    content: "\201C";
    position: absolute;
    top: 10px;
    left: 15px;
    font-size: 3rem;
    color: var(--content-primary);
    font-weight: bold;
    line-height: 1;
}

/* 代码块 */
.content-code {
    background: linear-gradient(135deg, #f8f9fa 0%, #f1f3f4 100%);
    border: 1px solid #e9ecef;
    border-left: 4px solid var(--content-primary);
    border-radius: 12px;
    padding: 24px;
    margin: 2.5rem 0;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.95rem;
    overflow-x: auto;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

/* =============================
   表格样式设计
   ============================= */
.content-card table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 2.5rem 0;
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 
        0 8px 24px rgba(255, 107, 157, 0.12),
        0 4px 12px rgba(255, 107, 157, 0.08);
    border: 1px solid rgba(255, 107, 157, 0.15);
}

/* 表格标题行 */
.content-card table thead {
    background: linear-gradient(135deg, var(--content-primary) 0%, var(--content-primary-600) 100%);
}

.content-card table thead th {
    padding: 18px 20px;
    text-align: left;
    font-weight: 600;
    font-size: 1rem;
    color: white;
    letter-spacing: 0.3px;
    border: none;
    position: relative;
}

.content-card table thead th:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 25%;
    height: 50%;
    width: 1px;
    background: rgba(255, 255, 255, 0.2);
}

/* 表格主体 */
.content-card table tbody tr {
    transition: all 0.3s ease;
}

.content-card table tbody tr:nth-child(even) {
    background: rgba(255, 107, 157, 0.03);
}

.content-card table tbody tr:hover {
    background: rgba(255, 107, 157, 0.08);
    transform: scale(1.01);
}

.content-card table tbody td {
    padding: 16px 20px;
    color: var(--content-text);
    font-size: 1rem;
    line-height: 1.6;
    border-bottom: 1px solid rgba(255, 107, 157, 0.1);
    vertical-align: top;
}

.content-card table tbody tr:last-child td {
    border-bottom: none;
}

/* 表格内的强调文本 */
.content-card table td strong,
.content-card table th strong {
    color: var(--content-primary);
    font-weight: 600;
}

/* 表格内的链接 */
.content-card table a {
    color: var(--content-primary);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.content-card table a:hover {
    border-bottom-color: var(--content-primary);
}

/* 表格容器 - 支持横向滚动 */
.table-wrapper {
    width: 100%;
    overflow-x: auto;
    margin: 2.5rem 0;
    border-radius: 16px;
    box-shadow: 
        0 8px 24px rgba(255, 107, 157, 0.12),
        0 4px 12px rgba(255, 107, 157, 0.08);
}

.table-wrapper::-webkit-scrollbar {
    height: 8px;
}

.table-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 107, 157, 0.05);
    border-radius: 4px;
}

.table-wrapper::-webkit-scrollbar-thumb {
    background: rgba(255, 107, 157, 0.3);
    border-radius: 4px;
}

.table-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 107, 157, 0.5);
}

/* 表格标题 */
.table-title {
    text-align: center;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--content-primary);
    margin-bottom: 1rem;
    font-family: 'Orbitron', serif;
}

/* 表格说明 */
.table-caption {
    text-align: center;
    font-size: 0.95rem;
    color: var(--content-muted);
    margin-top: 1rem;
    font-style: italic;
}

/* 响应式表格 */
@media (max-width: 768px) {
    .content-card table {
        font-size: 0.9rem;
        margin: 2rem 0;
    }
    
    .content-card table thead th {
        padding: 14px 12px;
        font-size: 0.9rem;
    }
    
    .content-card table tbody td {
        padding: 12px;
        font-size: 0.9rem;
    }
    
    /* 移动端可选：堆叠显示 */
    .content-card table.stack-on-mobile {
        border: none;
        box-shadow: none;
    }
    
    .content-card table.stack-on-mobile thead {
        display: none;
    }
    
    .content-card table.stack-on-mobile tbody tr {
    display: block;
        margin-bottom: 20px;
        border-radius: 12px;
        overflow: hidden;
        box-shadow: 0 4px 12px rgba(255, 107, 157, 0.15);
    }
    
    .content-card table.stack-on-mobile tbody td {
        display: block;
        text-align: right;
        padding: 12px;
        border-bottom: 1px solid rgba(255, 107, 157, 0.1);
        position: relative;
        padding-left: 50%;
    }
    
    .content-card table.stack-on-mobile tbody td::before {
        content: attr(data-label);
    position: absolute;
        left: 12px;
        width: 45%;
        text-align: left;
        font-weight: 600;
        color: var(--content-primary);
    }
    
    .content-card table.stack-on-mobile tbody td:last-child {
        border-bottom: none;
    }
}

/* =============================
   响应式设计
   注意：按照从大到小的顺序排列，更具体的规则（如平板横屏）放在最后
   ============================= */

@media (max-width: 1400px) {
    .wiki-content-wrapper {
        padding: 60px 15vw 60px 10vw;
    }

    .page_content {
        gap: 2vw;
    }

    .wiki-sidebar {
        width: 22vw;
    }

    .wiki-content-wrapper {
        max-width: 60vw;
    }
}

@media (max-width: 1200px) {
    .wiki-content-wrapper {
        padding: 50px 10vw 50px 8vw;
    }

    .page_content {
        gap: 2.5vw;
    }

    .wiki-sidebar {
        width: 26vw; /* 调整为更大的宽度 */
    }

    .wiki-content-wrapper {
        max-width: 56vw; /* 调整为更小的宽度 */
    }

    .section-header {
        padding: 18px 35px;
        margin: 35px 0 25px 0;
    }

    .section-title {
        font-size: 1.6rem;
    }
}

@media (max-width: 768px) {
    .wiki-content-wrapper {
        padding: 30px 5vw 30px 5vw;
    }

    .page_content {
        flex-direction: column;
        gap: 30px;
    }

    .wiki-sidebar {
        position: relative;
        top: auto;
    width: 100%;
        max-height: none;
        margin-right: 0;
    }

    .wiki-content-wrapper {
        max-width: 100%;
    }

    .section-header {
        padding: 16px 30px;
        margin: 30px 0 20px 0;
    }

    .section-title {
        font-size: 1.4rem;
    }

    .content-card {
        padding: 30px 25px;
        margin: 25px 0;
    }

    .content-title.h1 {
        font-size: 2rem;
    }

    .content-title.h2 {
        font-size: 1.7rem;
    }

    .content-title.h3 {
        font-size: 1.4rem;
    }

    .content-title.h4 {
        font-size: 1.2rem;
    }

    .content-card p {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .wiki-content-wrapper {
        padding: 20px 3vw 20px 3vw;
    }

    .section-header {
        padding: 14px 25px;
    }

    .section-title {
        font-size: 1.3rem;
    }

    .content-card {
        padding: 25px 20px;
    }

    .content-title.h1 {
        font-size: 1.8rem;
    }

    .content-title.h2 {
        font-size: 1.5rem;
    }

    .content-quote {
        padding: 20px 24px;
        margin: 2rem 0;
    }
}

.page_content {
    background: linear-gradient(135deg, var(--content-bg) 0%, rgba(255,255,255,1) 100%);
}

/* 确保文本可以被选择且可见 */
* {
    user-select: text;
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
}

/* 自定义文本选择样式 */
::selection {
    background-color: var(--content-primary) !important;
    color: white !important;
    opacity: 1;
}

::-moz-selection {
    background-color: var(--content-primary) !important;
    color: white !important;
    opacity: 1;
}

::-webkit-selection {
    background-color: var(--content-primary) !important;
    color: white !important;
    opacity: 1;
}

/* 确保内容区域的文本选择正常工作 */
.content-card ::selection,
.content-card ::-moz-selection,
.content-card ::-webkit-selection {
    background-color: rgba(255, 107, 157, 0.3) !important;
    color: var(--content-text) !important;
}

/* 确保标题的文本选择正常工作 */
.content-title ::selection,
.content-title ::-moz-selection,
.content-title ::-webkit-selection {
    background-color: rgba(255, 107, 157, 0.2) !important;
    color: inherit !important;
}

/* 简洁的设计完成 */



/* PDF 卡片样式 */
.pdf_card {
    width: 100%;
    max-width: 500px;
    margin: 20px 0;
    padding: 24px;
    border-radius: 16px;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.pdf_card:hover {
    border-color: var(--content-primary);
    /* transform: translateY(-2px); */
    /* box-shadow: 0 8px 24px rgba(255, 107, 157, 0.15); */
}

.pdf_card_content {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 16px;
    width: 60%;
}

.pdf_card_info {
    flex: 1;
    width: 100%;
}

.pdf_card_name {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
    line-height: 1.3;
    transition: color 0.3s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pdf_card:hover .pdf_card_name {
    color: var(--content-primary);
}

.pdf_card_size {
    font-size: 13px;
    color: #6c757d;
    font-weight: 500;
}

/* 下载链接样式 */
.pdf_download_link {
    background: linear-gradient(135deg, var(--content-primary) 0%, var(--content-primary-600) 100%);
    color: white !important;
    text-decoration: none;
    border-radius: 8px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    border: none;
    outline: none;
    white-space: nowrap;
}

.pdf_download_link:hover {
    background: linear-gradient(135deg, var(--content-primary-600) 0%, var(--content-primary-600) 100%);
    /* transform: translateY(-1px); */
    /* box-shadow: 0 4px 12px rgba(255, 107, 157, 0.3); */
}

.pdf_download_link:active {
    /* transform: translateY(0); */
}

/* 段落中的下载链接特殊样式 */
p .pdf_download_link {
    padding: 4px 8px;
    font-size: 13px;
    margin: 0 2px;
}

p .pdf_download_link:hover {
    transform: none;
    box-shadow: none;
}

/* 上标和下标样式 */
.top-symbol {
    vertical-align: super;
    font-size: 0.8em;
    line-height: 0;
}

.bottom-symbol {
    vertical-align: sub;
    font-size: 0.8em;
    line-height: 0;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .pdf_card {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
        padding: 20px;
    }

    .pdf_card_content {
        width: 100%;
        gap: 12px;
    }

    .pdf_card_name {
        font-size: 15px;
    }

    .pdf_card_size {
        font-size: 12px;
    }

    .pdf_download_link {
        align-self: stretch;
        text-align: center;
        margin-top: 8px;
    }
}

/* =============================
   平板横屏适配 (iPad Pro, iPad Air 等 4:3 或 10:9 比例)
   注意：此规则放在最后，以覆盖之前的通用响应式规则
   ============================= */
@media (min-width: 1024px) and (max-width: 1366px) and (orientation: landscape) {
    .page_content {
        gap: 1.5vw !important;
    }

    .wiki-sidebar {
        width: 20vw !important;
        padding: 16px !important;
        margin-left: -1vw !important;
    }

    .wiki-content-wrapper {
        max-width: 72vw !important;
        padding: 0 !important;
    }

    .sidebar-title {
        font-size: 0.9rem !important;
        margin-bottom: 16px !important;
    }

    .sidebar-item-level1 > .nav-link {
        padding: 10px 10px 10px 28px !important;
        font-size: 0.8rem !important;
        line-height: 1.5 !important;
    }

    .sidebar-item-level1 > .nav-link::before {
        left: 10px !important;
        top: 12px !important;
        width: 12px !important;
        height: 12px !important;
    }

    .sidebar-item-level2 > .nav-link {
        padding: 7px 10px 7px 28px !important;
        font-size: 0.75rem !important;
        line-height: 1.4 !important;
    }

    .sidebar-item-level2 > .nav-link::before {
        left: 16px !important;
        top: 7px !important;
    }

    .sidebar-item-level2 > .nav-link.active {
        padding-left: 26px !important;
    }

    .content-card {
        padding: 35px !important;
    }
}