/* ===== AI 论文页独立样式 v2 ===== */

/* ---------- 页面标题区 ---------- */
.page-head {
    max-width: 1200px;
    margin: 0 auto 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.page-head-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.page-title {
    font-size: 30px;
    font-weight: 700;
    color: var(--text, #1f2d3d);
    margin: 10px 0;
    text-align: center;
}

.page-desc {
    font-size: 15px;
    color: var(--text-light, #8a93a6);
    margin: 0;
    text-align: center;
}

/* 状态徽标 */
.paper-pill {
    font-size: 12px;
    font-weight: 600;
    color: var(--brand, #2f6bff);
    background: var(--brand-light, #eef4ff);
    border: 1px solid rgba(47, 107, 255, 0.25);
    border-radius: 999px;
    padding: 4px 14px;
    white-space: nowrap;
}

/* ---------- 主体卡片 ---------- */
.paper-card {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    background: var(--card, #ffffff);
    border: 1px solid var(--border, #e6ebf4);
    border-radius: 16px;
    padding: 30px 50px;
    box-shadow: 0 6px 24px rgba(31, 56, 88, 0.07);
}

/* 表格容器（窄屏横向滚动） */
.table-wrap {
    overflow-x: auto;
    border-radius: 12px;
}

/* ---------- 数据表格 ---------- */
.paper-table {
    width: 100%;
    table-layout: fixed; /* 列宽均分：增删列后自动重新分配，始终铺满卡片 */
    border-collapse: separate;
    border-spacing: 0;
    font-size: 14px;
    border: 1px solid var(--brand, #2f6bff); /* 表格品牌色外边框 */
    border-radius: 12px;
    overflow: hidden;
}

.paper-table td {
    position: relative;
    height: 50px;
    min-width: 0;
    padding: 12px 16px;
    border: 1px solid var(--border, #e6ebf4);
    text-align: center;
    color: var(--text, #1f2d3d);
    background: #ffffff;
    overflow-wrap: break-word;
    transition: background 0.25s ease;
}

/* 第一列固定宽度（其余列自动均分剩余宽度） */
.paper-table td:first-child {
    width: 140px;
}

/* 去掉外圈重复边线，只保留内部网格感 */
.paper-table td:first-child {
    border-left-width: 0;
}
.paper-table tr:first-child td {
    border-top-width: 0;
}
.paper-table tr:last-child td {
    border-bottom-width: 0;
}
.paper-table td:last-child {
    border-right-width: 0;
}

/* 斑马纹（跳过首行，首行作表头） */
.paper-table tbody tr:nth-child(n+2):nth-child(odd) td {
    background: #fafbfe;
}

/* 悬停高亮（仅数据区：跳过首行与首列） */
.paper-table tbody tr:nth-child(n+2):hover td:nth-child(n+2) {
    background: var(--brand-light, #eef4ff);
}

/* ---------- 第一行：表头行 ---------- */
.paper-table tbody tr:first-child td {
    background: var(--brand-light, #eef4ff);
    font-weight: 700;
    color: var(--brand, #2f6bff);
    border-bottom: 2px solid rgba(47, 107, 255, 0.35);
}

/* ---------- 第一列：行头列 ---------- */
.paper-table tbody tr:nth-child(n+2) td:first-child {
    background: #f3f6fc;
    font-weight: 600;
    color: #3d4a63;
    border-right: 2px solid rgba(47, 107, 255, 0.25);
}

/* ---------- 第一列超链接样式 ---------- */
.paper-table tbody tr:nth-child(n+2) td:first-child a {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-weight: 600;
    font-size: 14px;
    color: var(--brand, #2f6bff);
    text-decoration: none;
    padding: 4px 12px;
    border-radius: 6px;
    background: rgba(47, 107, 255, 0.08);
    border: 1px solid rgba(47, 107, 255, 0.2);
    transition: all 0.2s ease;
    cursor: pointer;
}

/* 外部链接小图标（::after 箭头） */
.paper-table tbody tr:nth-child(n+2) td:first-child a::after {
    content: "↗";
    font-size: 12px;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

/* 访问过的链接保持品牌色，不变紫（必须在 :hover 之前声明） */
.paper-table tbody tr:nth-child(n+2) td:first-child a:visited {
    color: var(--brand, #2f6bff);
}

/* 悬停：背景加深、边框变实、文字变白（覆盖 visited 状态） */
.paper-table tbody tr:nth-child(n+2) td:first-child a:hover,
.paper-table tbody tr:nth-child(n+2) td:first-child a:visited:hover {
    background: var(--brand, #2f6bff);
    color: #ffffff;
    border-color: var(--brand, #2f6bff);
    box-shadow: 0 2px 8px rgba(47, 107, 255, 0.3);
}

.paper-table tbody tr:nth-child(n+2) td:first-child a:hover::after {
    opacity: 1;
}

/* ---------- 左上角交叉格 ---------- */
.paper-table tbody tr:first-child td:first-child {
    background: var(--brand, #2f6bff);
    color: #ffffff;
}

/* ---------- 空单元格骨架占位（不填充内容，仅视觉占位） ---------- */
.paper-table td:empty::before {
    content: "";
    display: block;
    height: 10px;
    border-radius: 5px;
    background: linear-gradient(90deg, #e8edf5 25%, #f6f8fc 37%, #e8edf5 63%);
    background-size: 400% 100%;
    animation: paper-shimmer 1.6s ease infinite;
    margin: 0 auto;
}

/* 每列骨架条宽度错落，模拟真实数据节奏 */
.paper-table td:empty:nth-child(1)::before { width: 55%; }
.paper-table td:empty:nth-child(2)::before { width: 38%; }
.paper-table td:empty:nth-child(3)::before { width: 62%; }
.paper-table td:empty:nth-child(4)::before { width: 45%; }
.paper-table td:empty:nth-child(5)::before { width: 58%; }
.paper-table td:empty:nth-child(6)::before { width: 34%; }

@keyframes paper-shimmer {
    0%   { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

/* 悬停时骨架条变淡，提示可交互 */
.paper-table tbody tr:hover td:empty::before {
    opacity: 0.55;
}

/* 突出区域的骨架条改用品牌色半透明，与浅蓝底协调 */
.paper-table tbody tr:first-child td:empty::before,
.paper-table tbody td:first-child:empty::before {
    background: linear-gradient(90deg, rgba(47, 107, 255, 0.18) 25%, rgba(47, 107, 255, 0.07) 37%, rgba(47, 107, 255, 0.18) 63%);
    background-size: 400% 100%;
}

/* 左上角交叉格骨架条用白色半透明 */
.paper-table tbody tr:first-child td:first-child:empty::before {
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.45) 25%, rgba(255, 255, 255, 0.15) 37%, rgba(255, 255, 255, 0.45) 63%);
    background-size: 400% 100%;
}
