@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@400;500;600;700;900&family=Source+Sans+3:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --ink: #0f2230;
    --ink-soft: #3c4b57;
    --ink-muted: #69757f;
    --ink-faint: #97a1aa;

    --paper: #f1f6fa;
    --paper-2: #e4eef5;
    --surface: #ffffff;
    --hairline: #d1e2ec;
    --hairline-soft: #e3eef5;

    --brand: #0d7c96;
    --blue: #0a6885;
    --teal: #0d7c96;
    --cyan: #18a0bd;
    --accent: #0d7c96;
    --accent-dark: #0a5c72;
    --accent-soft: #e6f3f8;

    --gradient: linear-gradient(120deg, #0a6680 0%, #0d7c96 55%, #18a0bd 100%);
    --gradient-primary: linear-gradient(135deg, #0a6680 0%, #0d7c96 55%, #18a0bd 100%);
    --gradient-soft: linear-gradient(120deg, #0d7c96, #42b8d4);

    --hero-1: #062432;
    --hero-2: #094e63;
    --hero-3: #0d7c96;
    --hero-text: #e8f4fa;

    --shadow-xs: 0 1px 2px rgba(15, 34, 48, 0.04);
    --shadow-sm: 0 2px 8px rgba(15, 34, 48, 0.05), 0 1px 2px rgba(15, 34, 48, 0.04);
    --shadow-md: 0 12px 32px -8px rgba(15, 34, 48, 0.14), 0 4px 10px -4px rgba(15, 34, 48, 0.08);
    --shadow-lg: 0 24px 56px -16px rgba(8, 32, 48, 0.28);

    --radius: 18px;
    --radius-sm: 12px;
    --radius-pill: 999px;

    --font-ui: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-serif: 'Noto Serif SC', 'Songti SC', serif;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body {
    font-family: var(--font-ui);
    color: var(--ink);
    background: var(--paper);
    line-height: 1.6;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
}

::selection { background: rgba(13, 124, 150, 0.16); color: var(--accent-dark); }

a:focus-visible, button:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 3px;
    border-radius: 4px;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 32px;
    width: 100%;
}

.container-narrow { max-width: 880px; }

/* ════════ HERO ════════ */
.site-header {
    position: relative;
    isolation: isolate;
    background:
        radial-gradient(120% 120% at 50% -10%, var(--hero-3) 0%, transparent 55%),
        linear-gradient(150deg, var(--hero-1) 0%, var(--hero-2) 56%, var(--hero-3) 100%);
    color: var(--hero-text);
    padding: 48px 0 44px;
    overflow: hidden;
    text-align: center;
}

.site-header::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(circle at 82% 18%, rgba(13, 124, 150, 0.24) 0%, transparent 42%),
        radial-gradient(circle at 12% 88%, rgba(24, 160, 189, 0.18) 0%, transparent 46%);
    pointer-events: none;
}

.site-header::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(13, 124, 150, 0.55), rgba(24, 160, 189, 0.45), transparent);
}

.hero-glow {
    position: absolute;
    z-index: -1;
    top: -180px;
    left: 50%;
    width: 760px;
    height: 520px;
    transform: translateX(-50%);
    background: radial-gradient(circle, rgba(13, 124, 150, 0.32) 0%, rgba(24, 160, 189, 0.16) 38%, transparent 70%);
    filter: blur(14px);
    pointer-events: none;
}

.hero-inner { position: relative; z-index: 1; }

.wechat-modal[hidden] { display: none; }

.wechat-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.wechat-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(6, 46, 49, 0.62);
    backdrop-filter: blur(4px);
}

.wechat-modal-panel {
    position: relative;
    z-index: 1;
    width: min(100%, 340px);
    padding: 44px 20px 20px;
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-lg);
    text-align: center;
}

.wechat-modal-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 50%;
    background: var(--accent-soft);
    color: var(--accent-dark);
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
}

.wechat-modal-title {
    font-family: var(--font-serif);
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--ink);
    margin: 0 0 16px;
    line-height: 1.4;
    white-space: nowrap;
}

@media (max-width: 360px) {
    .wechat-modal-title {
        font-size: 0.8125rem;
    }
}

.wechat-modal-qr {
    width: 220px;
    height: 220px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    border: 1px solid var(--hairline-soft);
    background: #fff;
}

body.modal-open { overflow: hidden; }

.site-kicker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 16px;
}

.site-kicker span {
    font-size: 0.74rem;
    font-weight: 600;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: rgba(153, 246, 228, 0.9);
}

.site-kicker::before,
.site-kicker::after {
    content: "";
    width: 44px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(94, 234, 212, 0.6));
}
.site-kicker::after { background: linear-gradient(90deg, rgba(94, 234, 212, 0.6), transparent); }

.vision-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 0.74rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: #99f6e4;
    background: rgba(13, 124, 150, 0.14);
    border: 1px solid rgba(94, 234, 212, 0.25);
    padding: 5px 14px;
    border-radius: var(--radius-pill);
    margin-bottom: 18px;
}

.site-header h1 {
    font-family: var(--font-serif);
    font-size: clamp(1.85rem, 5vw, 2.7rem);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.02em;
}

.site-header h1 .title-zh {
    display: inline-block;
    background: linear-gradient(180deg, #ffffff 0%, #b8e8e0 130%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.site-header h1 .title-en { display: none; }

.site-tagline {
    font-family: var(--font-serif);
    font-size: clamp(1rem, 2vw, 1.18rem);
    font-weight: 400;
    color: rgba(238, 246, 245, 0.86);
    margin: 12px auto 0;
    max-width: 600px;
    line-height: 1.55;
}

.site-desc {
    color: rgba(238, 246, 245, 0.66);
    font-size: 1rem;
    max-width: 560px;
    margin: 14px auto 0;
    line-height: 1.7;
}

.site-intro {
    max-width: 580px;
    margin: 12px auto 0;
}

.site-intro p {
    font-size: 0.92rem;
    color: rgba(238, 246, 245, 0.6);
    line-height: 1.6;
}

.site-intro p:last-child { color: rgba(238, 246, 245, 0.42); }

.hero-divider {
    width: 52px;
    height: 2px;
    margin: 22px auto 0;
    background: var(--gradient-soft);
    border-radius: 2px;
}

.hero-stats {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0;
    margin-top: 22px;
}

.hero-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 0 26px;
    position: relative;
}

.hero-stat + .hero-stat::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 30px;
    width: 1px;
    background: rgba(255, 255, 255, 0.12);
}

.hero-stat-value {
    font-family: var(--font-serif);
    font-size: 1.45rem;
    font-weight: 600;
    color: #fff;
    line-height: 1;
}

.hero-stat-label {
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(153, 246, 228, 0.7);
}

/* ════════ FEATURES ════════ */
.features {
    margin-top: 0;
    position: relative;
    z-index: 2;
    padding: 28px 0 0;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    background: var(--surface);
    border: 1px solid var(--hairline);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.feature-card {
    padding: 20px 22px;
    position: relative;
    transition: background 0.3s var(--ease);
}

.feature-card + .feature-card { border-left: 1px solid var(--hairline-soft); }

.feature-card:hover { background: var(--accent-soft); }

.feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 11px;
    background: var(--gradient);
    color: #fff;
    font-size: 1.05rem;
    margin-bottom: 11px;
    box-shadow: 0 5px 14px -5px rgba(2, 132, 199, 0.55);
}

.feature-card h3 {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 5px;
    letter-spacing: 0.01em;
}

.feature-card p {
    font-size: 0.85rem;
    color: var(--ink-muted);
    line-height: 1.55;
}

/* ════════ PAPER LIBRARY ════════ */
.paper-section {
    flex: 1 0 auto;
    padding: 40px 0 24px;
}

.section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
    flex-wrap: wrap;
}

.section-eyebrow {
    display: block;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 8px;
}

.section-header h2 {
    font-family: var(--font-serif);
    font-size: 1.45rem;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: 0.02em;
}

.section-sub {
    font-size: 0.86rem;
    color: var(--ink-muted);
    margin-top: 6px;
}

.paper-count {
    font-size: 0.82rem;
    color: var(--ink-muted);
    background: var(--surface);
    border: 1px solid var(--hairline);
    padding: 8px 16px;
    border-radius: var(--radius-pill);
    white-space: nowrap;
    box-shadow: var(--shadow-xs);
}

.paper-count strong {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 600;
    color: var(--accent-dark);
    margin-right: 2px;
}

.paper-search {
    margin-bottom: 18px;
}

.paper-search-field {
    position: relative;
}

.paper-search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: var(--ink-faint);
    pointer-events: none;
}

.paper-search-input {
    width: 100%;
    font-family: var(--font-ui);
    font-size: 0.95rem;
    color: var(--ink);
    background: var(--surface);
    border: 1px solid var(--hairline);
    border-radius: var(--radius-pill);
    padding: 13px 18px 13px 44px;
    box-shadow: var(--shadow-xs);
    transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.paper-search-input::placeholder {
    color: var(--ink-faint);
}

.paper-search-input:hover {
    border-color: rgba(13, 124, 150, 0.35);
}

.paper-search-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(13, 124, 150, 0.14);
}

.paper-search-input::-webkit-search-cancel-button {
    -webkit-appearance: none;
    height: 16px;
    width: 16px;
    margin-left: 4px;
    background:
        linear-gradient(45deg, transparent 42%, var(--ink-faint) 42%, var(--ink-faint) 58%, transparent 58%),
        linear-gradient(-45deg, transparent 42%, var(--ink-faint) 42%, var(--ink-faint) 58%, transparent 58%);
    cursor: pointer;
}

.paper-search-tags {
    margin-top: 12px;
}

.paper-search-tags-list {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: thin;
    scrollbar-color: rgba(13, 124, 150, 0.35) transparent;
}

.paper-search-tags-list::-webkit-scrollbar {
    height: 4px;
}

.paper-search-tags-list::-webkit-scrollbar-thumb {
    background: rgba(13, 124, 150, 0.35);
    border-radius: var(--radius-pill);
}

.paper-search-tag {
    appearance: none;
    -webkit-appearance: none;
    font-family: var(--font-ui);
    font-size: 0.78rem;
    font-weight: 500;
    line-height: 1.2;
    color: var(--accent-dark);
    background: var(--surface);
    border: 1px solid rgba(13, 124, 150, 0.22);
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    cursor: pointer;
    flex-shrink: 0;
    white-space: nowrap;
    transition: background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease), box-shadow 0.2s var(--ease), transform 0.2s var(--ease);
}

.paper-search-tag--year {
    font-weight: 600;
    border-color: rgba(13, 124, 150, 0.38);
    background: linear-gradient(180deg, #f3f9fc 0%, var(--surface) 100%);
}

.paper-search-tag:hover {
    background: var(--accent-soft);
    border-color: rgba(13, 124, 150, 0.4);
    transform: translateY(-1px);
}

.paper-search-tag.is-active {
    color: #fff;
    background: var(--gradient);
    border-color: transparent;
    box-shadow: 0 4px 14px rgba(13, 124, 150, 0.35);
}

.paper-search-tag-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    margin-left: 6px;
    padding: 0 5px;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1;
    border-radius: var(--radius-pill);
    background: rgba(13, 124, 150, 0.14);
    color: var(--accent-dark);
}

.paper-search-tag.is-active .paper-search-tag-count {
    background: rgba(255, 255, 255, 0.24);
    color: #fff;
}

.paper-search-tag--featured {
    font-weight: 600;
    color: var(--accent-dark);
    border-color: rgba(13, 124, 150, 0.32);
    background: linear-gradient(180deg, #f8fcfe 0%, var(--surface) 100%);
}

.paper-search-tag--featured:hover {
    background: var(--accent-soft);
    border-color: rgba(13, 124, 150, 0.45);
}

.paper-search-tag--featured.is-active {
    background: var(--gradient);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 14px rgba(13, 124, 150, 0.35);
}

.paper-search-tag--sort {
    font-weight: 600;
    border-style: dashed;
    border-color: rgba(13, 124, 150, 0.35);
    background: linear-gradient(180deg, #f8fcfe 0%, var(--surface) 100%);
}

.paper-search-tag--sort:hover {
    border-style: solid;
}

.paper-search-empty {
    font-size: 0.9rem;
    color: var(--ink-muted);
    text-align: center;
    padding: 28px 20px;
    margin-bottom: 14px;
    background: var(--surface);
    border: 1px dashed var(--hairline);
    border-radius: var(--radius-sm);
}

.paper-search-empty[hidden] {
    display: none;
}

.paper-card.is-filter-hidden,
.paper-card.is-page-hidden {
    display: none;
}

.paper-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-top: 20px;
    padding: 12px 0 4px;
    flex-wrap: wrap;
}

.paper-pagination[hidden] {
    display: none;
}

.paper-pagination-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-ui);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent-dark);
    background: var(--surface);
    border: 1px solid var(--hairline);
    border-radius: var(--radius-pill);
    padding: 8px 16px;
    cursor: pointer;
    box-shadow: var(--shadow-xs);
    transition: background 0.2s var(--ease), border-color 0.2s var(--ease), opacity 0.2s;
}

.paper-pagination-btn svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.paper-pagination-btn:hover:not(:disabled) {
    background: var(--accent-soft);
    border-color: rgba(13, 124, 150, 0.35);
}

.paper-pagination-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.paper-pagination-info {
    font-size: 0.82rem;
    color: var(--ink-muted);
    min-width: 140px;
    text-align: center;
}

.back-to-top {
    position: fixed;
    right: max(22px, env(safe-area-inset-right, 0px));
    bottom: max(22px, env(safe-area-inset-bottom, 0px));
    z-index: 1500;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: #fff;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(13, 124, 150, 0.32);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(12px) scale(0.9);
    transition: opacity 0.25s var(--ease), transform 0.25s var(--ease), visibility 0.25s, box-shadow 0.25s var(--ease);
}

.back-to-top-icon {
    width: 22px;
    height: 22px;
    display: block;
    transition: transform 0.2s var(--ease);
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0) scale(1);
}

.back-to-top:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 10px 24px rgba(13, 124, 150, 0.4);
}

.back-to-top:hover .back-to-top-icon {
    transform: translateY(-1px);
}

.back-to-top:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 3px;
}

.paper-list {
    display: grid;
    gap: 14px;
    counter-reset: paper;
}

.paper-card {
    counter-increment: paper;
    position: relative;
    background: var(--surface);
    border: 1px solid var(--hairline);
    border-radius: var(--radius);
    overflow: visible;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: stretch;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.4s var(--ease), border-color 0.4s, transform 0.4s var(--ease);
}

.paper-card::after {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--gradient);
    opacity: 0;
    transition: opacity 0.4s var(--ease);
}

.paper-card:hover {
    border-color: rgba(13, 124, 150, 0.3);
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.paper-card:hover::after { opacity: 1; }

/* 精选：与普通卡片同主题，仅顶栏 ★ 精选 徽章区分 */
.paper-badge-featured {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: #fff;
    background: var(--gradient);
    padding: 3px 11px 3px 9px;
    border-radius: var(--radius-pill);
    box-shadow: 0 2px 8px rgba(13, 124, 150, 0.28);
}

.paper-badge-featured-icon {
    width: 12px;
    height: 12px;
    flex-shrink: 0;
}

.paper-card-body {
    padding: 22px 26px;
    min-width: 0;
    position: relative;
}

.paper-card-body::before {
    content: counter(paper, decimal-leading-zero);
    position: absolute;
    top: 18px;
    right: 24px;
    font-family: var(--font-serif);
    font-size: 1.9rem;
    font-weight: 700;
    line-height: 1;
    color: var(--paper-2);
    pointer-events: none;
    transition: color 0.4s var(--ease);
}

.paper-card:hover .paper-card-body::before { color: #d7ede9; }

.paper-card-top {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 11px;
}

.paper-year {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: #fff;
    background: var(--gradient);
    padding: 3px 11px;
    border-radius: var(--radius-pill);
}

.paper-stat {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--ink-muted);
    background: var(--paper);
    border: 1px solid var(--hairline);
    padding: 3px 11px;
    border-radius: var(--radius-pill);
}

.paper-title-zh {
    font-family: var(--font-serif);
    font-size: 1.22rem;
    font-weight: 600;
    margin-bottom: 5px;
    line-height: 1.4;
    letter-spacing: 0.01em;
    padding-right: 44px;
}

.paper-title-zh a {
    color: var(--ink);
    text-decoration: none;
    transition: color 0.2s;
}

.paper-title-zh a:hover { color: var(--accent); }

.paper-title-en {
    color: var(--ink-muted);
    font-size: 0.85rem;
    font-style: italic;
    line-height: 1.45;
    margin-bottom: 10px;
    padding-right: 44px;
}

.paper-meta {
    font-size: 0.8rem;
    color: var(--ink-muted);
    margin-bottom: 10px;
    line-height: 1.55;
}

.paper-meta a {
    color: var(--blue);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 1px solid rgba(3, 105, 161, 0.25);
    transition: border-color 0.2s;
}

.paper-meta a:hover { border-bottom-color: var(--blue); }

.paper-desc {
    color: var(--ink-soft);
    font-size: 0.88rem;
    line-height: 1.62;
    margin-bottom: 12px;
}

.paper-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.tag {
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--accent-dark);
    background: var(--accent-soft);
    padding: 4px 12px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(13, 124, 150, 0.16);
}

.paper-card-action {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    align-items: stretch;
    gap: 12px;
    padding: 22px 16px 18px;
    min-width: 168px;
    min-height: 100%;
    border-left: 1px solid var(--hairline-soft);
    background: linear-gradient(180deg, #e6f3f8 0%, #f1f6fa 100%);
}

/* 阅读中译：在右侧栏中间偏下；四图标贴底 */
.paper-card-action .paper-card-link {
    align-self: center;
    margin: 10px 0 0;
}

.paper-card-action .paper-card-tools {
    align-self: stretch;
    margin: 0;
    padding-top: 0;
}

.paper-card-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    white-space: nowrap;
    color: #fff;
    background: var(--gradient);
    border: none;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    padding: 13px 20px;
    border-radius: var(--radius-pill);
    box-shadow:
        0 6px 20px rgba(13, 124, 150, 0.38),
        0 2px 6px rgba(13, 124, 150, 0.18);
    transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.paper-card-link:hover {
    color: #fff;
    background: var(--gradient);
    transform: translateY(-2px);
    box-shadow:
        0 12px 28px rgba(13, 124, 150, 0.48),
        0 4px 10px rgba(13, 124, 150, 0.22);
}

.empty {
    color: var(--ink-muted);
    text-align: center;
    padding: 80px 28px;
    background: var(--surface);
    border: 1px dashed var(--hairline);
    border-radius: var(--radius);
    font-size: 0.95rem;
}

/* ════════ FOOTER ════════ */
.page-bottom {
    margin-top: auto;
    flex-shrink: 0;
    width: 100%;
    background: linear-gradient(180deg, #f8fbfd 0%, #eef6fa 100%);
    border-top: 1px solid var(--hairline);
    padding: 14px 0 16px;
}

.page-bottom-inner {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.site-footer {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 6px 16px;
    padding: 0;
    background: none;
    border-top: none;
    box-shadow: none;
}

.footer-inner {
    display: contents;
}

.footer-brand-row {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.footer-mark {
    flex-shrink: 0;
    border-radius: 4px;
    box-shadow: 0 1px 4px rgba(13, 124, 150, 0.18);
}

.footer-brand-zh {
    font-family: var(--font-serif);
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: 0.01em;
    line-height: 1;
    white-space: nowrap;
}

.footer-brand-en {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: none;
    color: var(--accent-dark);
    line-height: 1;
    white-space: nowrap;
}

.footer-divider { display: none; }

.footer-brand {
    font-family: var(--font-serif);
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--ink-muted);
    letter-spacing: 0.02em;
    margin-top: 2px;
}

.footer-social {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0;
    flex-shrink: 0;
}

.footer-social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 24px;
    padding: 0;
    border: none;
    border-radius: 0;
    font-family: var(--font-ui);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    line-height: 1;
    text-decoration: none;
    background: transparent;
    color: var(--ink-soft);
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s var(--ease);
}

.footer-social-link:visited {
    color: var(--ink-soft);
}

.footer-social-link:hover {
    background: transparent;
    border: none;
    color: var(--accent-dark);
    box-shadow: none;
}

button.footer-social-link {
    appearance: none;
    -webkit-appearance: none;
    margin: 0;
}

.footer-social-icon {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    display: block;
}

.footer-social-link--wechat .footer-social-icon {
    color: #07c160;
}

.footer-social-link--github .footer-social-icon {
    color: var(--ink);
}

.footer-social-link:hover .footer-social-icon {
    color: var(--accent-dark);
}

.footer-social-link--wechat:hover .footer-social-icon {
    color: #059669;
}

.footer-meta {
    font-size: 0.65rem;
    color: var(--ink-faint);
    line-height: 1;
    margin: 0;
    white-space: nowrap;
}

/* ════════ PAPER SHARE (modal only; card buttons use community-action) ════════ */
.share-modal[hidden] {
    display: none;
}

.share-modal {
    position: fixed;
    inset: 0;
    z-index: 2500;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.share-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 34, 48, 0.45);
    backdrop-filter: blur(4px);
}

.share-modal-panel {
    position: relative;
    width: min(100%, 440px);
    max-height: min(92vh, 640px);
    overflow: auto;
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    padding: 24px 24px 20px;
    border: 1px solid var(--hairline-soft);
}

.share-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 50%;
    background: var(--paper);
    color: var(--ink-muted);
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.share-modal-close:hover {
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.share-modal-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 32px 6px 0;
}

.share-modal-hint {
    font-size: 0.78rem;
    color: var(--ink-muted);
    margin: 0 0 16px;
    line-height: 1.5;
}

.share-card-preview {
    background: linear-gradient(180deg, #f3f9fc 0%, var(--paper) 100%);
    border: 1px solid var(--hairline);
    border-radius: var(--radius-sm);
    padding: 16px 18px;
    margin-bottom: 16px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.share-card-kicker {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    margin: 0 0 8px;
}

.share-card-title {
    font-size: 0.98rem;
    font-weight: 700;
    line-height: 1.45;
    color: var(--ink);
    margin: 0 0 6px;
}

.share-card-title-en {
    font-size: 0.78rem;
    font-style: italic;
    color: var(--ink-muted);
    line-height: 1.45;
    margin: 0 0 10px;
}

.share-card-title-en[hidden] {
    display: none;
}

.share-card-desc {
    font-size: 0.82rem;
    line-height: 1.62;
    color: var(--ink-soft);
    margin: 0 0 14px;
    white-space: pre-wrap;
    word-break: break-word;
}

.share-card-links {
    margin: 0;
    padding-top: 12px;
    border-top: 1px dashed var(--hairline-soft);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.share-card-link-row {
    margin: 0;
}

.share-card-link-row[hidden] {
    display: none;
}

.share-card-link-row dt {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--ink-muted);
    margin: 0 0 4px;
}

.share-card-link-row dd {
    margin: 0;
}

.share-card-link-url {
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--blue);
    word-break: break-all;
    line-height: 1.5;
    text-decoration: none;
    border-bottom: 1px solid rgba(3, 105, 161, 0.2);
}

.share-card-link-url:hover {
    border-bottom-color: var(--blue);
}

.share-qrcode-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
}

.share-qrcode-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 14px 12px 10px;
    border-radius: var(--radius-sm);
    background: #fff;
    border: 1px solid var(--hairline-soft);
}

.share-qrcode-wrap[hidden] {
    display: none;
}

.share-qrcode {
    width: 168px;
    height: 168px;
    padding: 8px;
    border-radius: 10px;
    background: #fff;
    box-shadow: inset 0 0 0 1px var(--hairline-soft);
}

.share-qrcode img,
.share-qrcode canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
}

.share-qrcode-hint {
    margin: 0;
    font-size: 0.72rem;
    color: var(--ink-muted);
    text-align: center;
}

.share-modal-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.share-action-btn {
    appearance: none;
    -webkit-appearance: none;
    font-family: var(--font-ui);
    font-size: 0.84rem;
    font-weight: 600;
    line-height: 1.2;
    padding: 11px 16px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--hairline);
    background: var(--surface);
    color: var(--ink-soft);
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, box-shadow 0.2s, transform 0.15s;
}

.share-action-btn:hover {
    background: var(--accent-soft);
    border-color: rgba(13, 124, 150, 0.35);
    transform: translateY(-1px);
}

.share-action-btn--primary {
    color: #fff;
    background: var(--gradient);
    border-color: transparent;
    box-shadow: 0 4px 14px rgba(13, 124, 150, 0.28);
}

.share-action-btn--primary:hover {
    color: #fff;
    box-shadow: 0 6px 18px rgba(13, 124, 150, 0.38);
}

.share-action-btn--ghost {
    background: transparent;
}

.share-toast {
    position: fixed;
    left: 50%;
    bottom: max(24px, env(safe-area-inset-bottom, 0px));
    transform: translateX(-50%) translateY(12px);
    z-index: 3000;
    background: #0f2230;
    color: #e8f4fa;
    font-size: 0.82rem;
    padding: 10px 18px;
    border-radius: var(--radius-pill);
    box-shadow: var(--shadow-md);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s, transform 0.25s;
}

.share-toast.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

body.modal-open {
    overflow: hidden;
}

/* ════════ RESPONSIVE ════════ */
@media (max-width: 880px) {
    .feature-grid { grid-template-columns: 1fr; }
    .feature-card + .feature-card { border-left: none; border-top: 1px solid var(--hairline-soft); }
    .features { margin-top: 0; padding-top: 22px; }
}

@media (max-width: 720px) {
    .site-header { padding: 40px 0 36px; }
    .paper-card { grid-template-columns: 1fr; }
    .paper-card-action {
        display: flex;
        flex-direction: column;
        border-left: none;
        border-top: 1px solid var(--hairline-soft);
        padding: 16px 22px 20px;
        min-width: 0;
        min-height: 0;
        background: linear-gradient(180deg, #e6f3f8 0%, transparent 100%);
    }
    .paper-card-action .paper-card-link {
        align-self: stretch;
        margin-top: 0;
    }
    .paper-card-action .paper-card-tools {
        max-width: 280px;
        margin-left: auto;
        margin-right: auto;
    }
    .section-header { flex-direction: column; align-items: flex-start; }
    .hero-stat { padding: 0 20px; }
}

@media (max-width: 480px) {
    .container { padding: 0 18px; }
    .paper-card-body { padding: 24px 22px; }
    .paper-card-body::before { font-size: 1.8rem; top: 20px; right: 20px; }
    .paper-title-zh, .paper-title-en { padding-right: 40px; }
    .hero-stats { gap: 0; }
    .hero-stat { padding: 8px 16px; }
    .hero-stat + .hero-stat::before { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .feature-card, .paper-card, .paper-card-link, .paper-card::after { transition: none; }
}
