/* 试卷中心 — 对齐 wancode.net/#/testPaperCenter */
.paper-page {
    padding: 16px 15px 48px;
    max-width: 1250px;
    color: #333;
    font-family: inherit;
}

body:has(.paper-page),
body:has(.paper-detail-page) {
    background: #f0f2f5;
}

.paper-breadcrumb {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 2px;
    margin: 0 0 14px;
    padding: 6px 10px 6px 8px;
    background: #fff;
    border: 1px solid #e8edf3;
    border-radius: 999px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
    font-size: 13px;
    line-height: 1.2;
    color: #94a3b8;
}

.paper-seo-intro {
    margin: 0 0 16px;
}

.paper-seo-h1 {
    margin: 0 0 6px;
    font-size: 22px;
    font-weight: 600;
    color: #1f2329;
    letter-spacing: -0.02em;
    line-height: 1.35;
}

.paper-seo-lead {
    margin: 0;
    font-size: 14px;
    color: #646a73;
    line-height: 1.5;
}

.paper-bc-link {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    color: #64748b;
    text-decoration: none !important;
    transition: color 0.15s ease, background 0.15s ease;
}

.paper-bc-link:hover {
    color: #0080ff;
    background: #eff6ff;
}

.paper-bc-sep {
    display: inline-block;
    width: 5px;
    height: 5px;
    margin: 0 2px;
    border-right: 1.5px solid #cbd5e1;
    border-bottom: 1.5px solid #cbd5e1;
    transform: rotate(-45deg);
    flex-shrink: 0;
}

.paper-bc-current {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    color: #0f172a;
    font-weight: 400;
    background: #f8fafc;
}

.paper-layout {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    min-width: 0;
}

.paper-sidebar {
    width: 232px;
    flex-shrink: 0;
    box-sizing: border-box;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #e8edf3;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    position: sticky;
    top: 72px;
    align-self: flex-start;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.paper-sidebar-head {
    padding: 14px 16px 8px;
    font-size: 12px;
    font-weight: 450;
    letter-spacing: 0.06em;
    color: #94a3b8;
    line-height: 1.2;
}

.paper-sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 0 8px 10px;
}

.paper-menu-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    min-height: 44px;
    margin: 0;
    border-radius: 10px;
    padding: 9px 10px;
    font-size: 14px;
    color: #334155;
    text-decoration: none !important;
    border: 1px solid transparent;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.paper-menu-dot {
    width: 6px;
    height: 6px;
    margin-top: 7px;
    border-radius: 50%;
    background: #cbd5e1;
    flex-shrink: 0;
    transition: background 0.15s ease, box-shadow 0.15s ease;
}

.paper-menu-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    line-height: 1.35;
}

.paper-menu-text strong {
    font-size: 14px;
    font-weight: 650;
    color: inherit;
}

.paper-menu-text em {
    font-style: normal;
    font-size: 11px;
    line-height: 1.35;
    color: #94a3b8;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.paper-menu-item:hover {
    background: #f8fafc;
    color: #0f172a;
    border-color: #eef2f7;
}

.paper-menu-item:hover .paper-menu-dot {
    background: #0080ff;
}

.paper-menu-item.active {
    background: #e7f3ff !important;
    border-color: #bfdbfe !important;
    color: #0080ff !important;
    box-shadow: 0 0 0 1px rgba(0, 128, 255, 0.06);
}

.paper-menu-item.active .paper-menu-dot {
    background: #0080ff;
    box-shadow: 0 0 0 3px rgba(0, 128, 255, 0.18);
}

.paper-menu-item.active .paper-menu-text em {
    color: #60a5fa;
}

.paper-menu-item.is-all.active {
    background: #f8fafc !important;
    border-color: #e2e8f0 !important;
    color: #0f172a !important;
}

.paper-menu-item.is-all.active .paper-menu-dot {
    background: #0080ff;
}

.paper-main {
    flex: 1;
    min-width: 0;
    max-width: 100%;
    margin: 0;
    padding: 0;
}

.paper-select {
    width: 100%;
    background: #fff;
    border-radius: 12px;
    margin: 0 0 16px;
    border: 1px solid #e8edf3;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    overflow: hidden;
}

.paper-select-content {
    padding: 14px 20px 16px;
}

.paper-filter-row {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

.paper-filter-row:last-of-type {
    border-bottom: none;
}

.paper-filter-label {
    display: flex;
    align-items: center;
    height: 30px;
    color: #64748b;
    font-size: 13px;
    font-weight: 400;
    letter-spacing: 0.02em;
    flex-shrink: 0;
}

.paper-filter-options {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-width: 0;
}

.paper-filter-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 0 12px;
    font-size: 13px;
    line-height: 1;
    color: #334155;
    background: #f8fafc;
    border: 1px solid transparent;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none !important;
    transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    white-space: nowrap;
}

.paper-filter-tag:hover {
    color: #0080ff;
    background: #eff6ff;
    border-color: #dbeafe;
}

.paper-filter-tag.active {
    color: #0080ff;
    background: #e7f3ff;
    border-color: #bfdbfe;
    font-weight: 400;
    box-shadow: 0 0 0 1px rgba(0, 128, 255, 0.08);
}

.paper-filter-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
    padding: 14px 0 2px;
    border-top: 1px dashed #e2e8f0;
}

.paper-year-select {
    height: 36px;
    min-width: 118px;
    padding: 0 28px 0 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    font-size: 13px;
    color: #334155;
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2364748b' d='M3 4.5L6 8l3-3.5'/%3E%3C/svg%3E") no-repeat right 10px center;
    appearance: none;
    -webkit-appearance: none;
    outline: none;
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.paper-search-box {
    display: flex;
    align-items: stretch;
    flex: 1;
    min-width: 200px;
    max-width: 420px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.paper-search-box:focus-within {
    border-color: #0080ff;
    box-shadow: 0 0 0 3px rgba(0, 128, 255, 0.12);
}

.paper-search-input {
    flex: 1;
    min-width: 0;
    height: 36px;
    border: 0;
    outline: none;
    padding: 0 12px;
    font-size: 13px;
    color: #0f172a;
    background: transparent;
}

.paper-search-input::placeholder {
    color: #94a3b8;
}

.paper-search-btn {
    flex-shrink: 0;
    height: 36px;
    padding: 0 16px;
    border: 0;
    border-left: 1px solid #e2e8f0;
    background: #f8fafc;
    color: #0080ff;
    font-size: 13px;
    font-weight: 400;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.paper-search-btn:hover {
    background: #e7f3ff;
}

.paper-year-select:hover,
.paper-year-select:focus {
    border-color: #0080ff;
}

.paper-year-select:focus {
    box-shadow: 0 0 0 3px rgba(0, 128, 255, 0.12);
}

.paper-reset-btn {
    display: inline-flex;
    align-items: center;
    height: 36px;
    padding: 0 12px;
    font-size: 13px;
    color: #64748b;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none !important;
    white-space: nowrap;
    margin-left: auto;
}

.paper-reset-btn:hover {
    color: #0080ff;
    background: #eff6ff;
    border-color: #dbeafe;
}

/* legacy toggles kept for safety */
.paper-filter-controls,
.paper-vip-toggle {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.paper-toggle-btn {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 12px;
    font-size: 13px;
    color: #334155;
    background: #f8fafc;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none !important;
    border: 1px solid transparent;
}

.paper-toggle-btn:hover,
.paper-toggle-btn.active {
    color: #0080ff;
    background: #e7f3ff;
}

.paper-list {
    min-height: 320px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e8edf3;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    overflow: hidden;
}

.paper-list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    border-top: 1px solid #f1f5f9;
    text-decoration: none !important;
    color: inherit;
    padding: 14px 18px;
    transition: background 0.15s ease;
}

.paper-list-item:first-child {
    border-top: none;
}

.paper-list-item:hover {
    background: #f8fbff;
}

.paper-list-main {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
    min-width: 0;
    text-decoration: none !important;
    color: inherit;
}

.paper-list-detail {
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    padding: 0;
    min-height: 0;
    overflow: hidden;
}

.paper-type-icon {
    position: relative;
    flex: 0 0 56px;
    width: 56px;
    margin: 0;
    float: none;
}

.paper-category {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
    font-size: 10px;
    font-weight: 450;
    letter-spacing: 0.02em;
    color: #fff;
    padding: 0 5px;
    height: 16px;
    line-height: 16px;
    border-radius: 6px 0 6px 0;
}

.paper-category.free {
    background: #10b981;
}

.paper-category.vip {
    background: linear-gradient(135deg, #f43f5e, #fb7185);
}

.paper-type-cover {
    position: relative;
    display: block;
    margin: 0;
    width: 56px;
    height: 74px;
    background-color: #f1f5f9;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

.paper-mid {
    float: none;
    flex: 1;
    min-width: 0;
    max-width: none;
    margin-top: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    justify-content: center;
}

.paper-item-title {
    position: relative;
    height: auto;
    max-height: 40px;
    line-height: 1.35;
    font-weight: 650;
    color: #0f172a;
    font-size: 15px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    white-space: normal;
}

.paper-list-item:hover .paper-item-title {
    color: #0080ff;
}

.paper-item-sub {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
}

.paper-attribute {
    margin-top: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 0;
}

.paper-attribute i,
.paper-tag {
    display: inline-flex;
    align-items: center;
    background: #f1f5f9;
    border-radius: 999px;
    height: 22px;
    line-height: 22px;
    padding: 0 9px;
    font-size: 12px;
    font-weight: 400;
    color: #64748b;
    margin-right: 0;
    vertical-align: middle;
    font-style: normal;
}

.paper-meta-row {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #64748b;
}

.paper-meta-stat {
    display: inline-flex;
    align-items: center;
    height: 22px;
    padding: 0 8px;
    border-radius: 6px;
    background: #f8fafc;
    border: 1px solid #eef2f7;
    color: #475569;
}

.paper-meta-row b,
.paper-meta-stat b {
    color: #0f172a;
    font-weight: 450;
    margin-right: 2px;
}

.paper-album {
    display: none;
}

.paper-feature {
    margin-top: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0;
    line-height: 1.4;
}

.paper-feature .item,
.paper-feature > span {
    display: inline-flex;
    align-items: center;
    padding-right: 0;
    font-size: 12px;
    color: #94a3b8;
    max-width: none;
    white-space: nowrap;
}

.paper-feature > span + span::before {
    content: "";
    display: inline-block;
    width: 3px;
    height: 3px;
    margin: 0 8px;
    border-radius: 50%;
    background: #cbd5e1;
}

.paper-feature .item em {
    color: #94a3b8;
    margin-left: 0;
    font-style: normal;
}

.paper-open {
    float: none;
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    gap: 8px;
    padding-top: 0;
    min-width: 108px;
    text-align: center;
    align-self: center;
}

.paper-open-btn,
.paper-download-btn,
.paper-fav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 34px;
    padding: 0 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 400;
    text-decoration: none !important;
    white-space: nowrap;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    box-sizing: border-box;
    cursor: pointer;
}

.paper-fav-btn {
    background: #fff;
    color: #0080ff;
    border: 1px solid #bfdbfe;
}

.paper-fav-btn:hover {
    background: #eff6ff;
    border-color: #93c5fd;
}

.paper-fav-btn.is-on {
    background: #fff1f0;
    border-color: #ffa39e;
    color: #cf1322;
}

.paper-fav-btn:disabled {
    opacity: 0.65;
    cursor: wait;
}

.paper-open-btn {
    background: #0080ff;
    color: #fff !important;
    border: 1px solid #0080ff;
    box-shadow: 0 1px 2px rgba(0, 128, 255, 0.25);
}

.paper-list-item:hover .paper-open-btn {
    background: #0066d6;
    border-color: #0066d6;
    box-shadow: 0 4px 10px rgba(0, 128, 255, 0.28);
}

.paper-download-btn {
    background: #fff;
    color: #0080ff !important;
    border: 1px solid #bfdbfe;
}

.paper-download-btn:hover {
    background: #eff6ff;
    border-color: #93c5fd;
}

.paper-download-btn.is-disabled {
    color: #94a3b8 !important;
    border-color: #e2e8f0;
    background: #f8fafc;
    cursor: default;
    font-weight: 400;
}

.paper-open .download {
    display: none;
}

.paper-empty {
    padding: 64px 20px;
    text-align: center;
    color: #94a3b8;
    font-size: 14px;
}

.paper-pager {
    margin-top: 20px;
    text-align: center;
    padding: 16px;
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(26, 26, 26, 0.1);
}

.paper-pager .pagination {
    margin: 0;
}

.paper-total {
    color: #80848b;
    font-size: 13px;
    margin-bottom: 8px;
}

.paper-pagesize {
    margin-left: 12px;
}

.paper-pagesize a {
    display: inline-block;
    margin: 0 2px;
    padding: 2px 8px;
    border-radius: 4px;
    color: #80848b;
    text-decoration: none !important;
}

.paper-pagesize a:hover,
.paper-pagesize a.active {
    background: #0080ff;
    color: #fff;
}

/* 详情 */
.paper-detail-page {
    padding: 24px 15px 48px;
    max-width: 960px;
}

.paper-detail-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    padding: 28px 32px;
}

.paper-detail-head {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid #ebeef5;
}

.paper-detail-title {
    margin: 0 0 12px;
    font-size: 22px;
    font-weight: 400;
    color: #303133;
    line-height: 1.4;
}

.paper-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.paper-detail-stats {
    font-size: 13px;
    color: #80848b;
    line-height: 1.8;
}

.paper-detail-stats span {
    margin-right: 16px;
}

.paper-detail-actions {
    margin-top: 16px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.paper-detail-actions .paper-open-btn,
.paper-detail-actions .paper-download-btn,
.paper-detail-actions .paper-fav-btn {
    min-width: 108px;
}

.paper-detail-tip {
    margin-top: 20px;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    font-size: 14px;
    color: #606266;
    line-height: 1.7;
}

.paper-detail-body {
    margin-top: 8px;
    border-top: 1px dashed #ebeef5;
    padding-top: 24px;
}

.paper-detail-empty {
    text-align: center;
    padding: 28px 20px 12px;
    max-width: 520px;
    margin: 0 auto;
}

.paper-detail-empty-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f39c12, #e74c3c);
    color: #fff;
    font-size: 28px;
    font-weight: 450;
    line-height: 56px;
}

.paper-detail-empty h2 {
    margin: 0 0 10px;
    font-size: 18px;
    color: #303133;
    font-weight: 400;
}

.paper-detail-empty p {
    margin: 0 0 16px;
    font-size: 14px;
    color: #606266;
    line-height: 1.7;
}

.paper-detail-empty-list {
    text-align: left;
    margin: 0 auto 8px;
    padding: 16px 20px;
    background: #f8f9fa;
    border-radius: 12px;
    color: #606266;
    font-size: 13px;
    line-height: 1.9;
    list-style: disc;
    padding-left: 36px;
}

.paper-questions {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.paper-q-item {
    border: 1px solid #eef0f3;
    border-radius: 10px;
    padding: 16px 18px 14px;
    background: #fff;
}

.paper-q-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.paper-q-num {
    font-size: 14px;
    font-weight: 400;
    color: #303133;
}

.paper-q-type {
    font-size: 12px;
    color: #909399;
    background: #f4f6f8;
    border-radius: 4px;
    padding: 2px 8px;
}

.paper-q-stem {
    font-size: 15px;
    color: #303133;
    line-height: 1.7;
    overflow-x: auto;
}

.paper-q-stem img,
.paper-q-opt-body img,
.paper-q-analysis img {
    max-width: 100%;
    height: auto;
}

.paper-q-options {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.paper-q-option {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    padding: 8px 10px;
    background: #fafbfc;
    border-radius: 6px;
}

.paper-q-opt-key {
    flex: 0 0 auto;
    font-weight: 400;
    color: #606266;
    line-height: 1.6;
}

.paper-q-opt-body {
    flex: 1;
    min-width: 0;
    line-height: 1.6;
    color: #303133;
}

.paper-q-answer {
    margin-top: 12px;
    padding: 10px 12px;
    background: #f0f9eb;
    border-radius: 6px;
    color: #67c23a;
    font-size: 14px;
}

.paper-q-analysis {
    margin-top: 10px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 6px;
    font-size: 14px;
    color: #606266;
    line-height: 1.7;
}

.paper-q-label {
    display: inline-block;
    font-weight: 400;
    color: #303133;
    margin-right: 8px;
    margin-bottom: 6px;
}

.paper-back-link {
    display: inline-block;
    margin-bottom: 16px;
    color: #80848b;
    font-size: 13px;
    text-decoration: none;
}

.paper-back-link:hover {
    color: #0080ff;
}

@media (max-width: 992px) {
    .paper-layout {
        flex-direction: column;
    }

    .paper-sidebar {
        width: 100%;
        position: static;
        display: block;
        padding: 0;
    }

    .paper-sidebar-head {
        display: none;
    }

    .paper-sidebar-nav {
        flex-direction: row;
        flex-wrap: nowrap;
        overflow-x: auto;
        gap: 6px;
        padding: 10px 12px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .paper-sidebar-nav::-webkit-scrollbar {
        display: none;
    }

    .paper-menu-item {
        flex: 0 0 auto;
        align-items: center;
        min-height: 36px;
        padding: 6px 12px;
        border-radius: 999px;
        background: #f8fafc;
    }

    .paper-menu-dot {
        display: none;
    }

    .paper-menu-text em {
        display: none;
    }

    .paper-menu-text strong {
        font-size: 13px;
        font-weight: 400;
        white-space: nowrap;
    }

    .paper-mid {
        width: auto;
        float: none;
        display: flex;
        overflow: hidden;
    }

    .paper-list-item {
        flex-wrap: wrap;
        height: auto;
        min-height: 0;
    }

    .paper-list-main {
        width: 100%;
    }

    .paper-open {
        display: flex;
        flex-direction: row;
        width: 100%;
        min-width: 0;
        padding-left: 72px;
        box-sizing: border-box;
    }

    .paper-open-btn,
    .paper-download-btn,
    .paper-fav-btn {
        flex: 1;
    }

    .paper-list-detail {
        height: auto;
        min-height: 0;
    }

    .paper-search-input {
        width: auto;
    }

    .paper-filter-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .paper-search-box {
        max-width: none;
    }

    .paper-reset-btn {
        margin-left: 0;
        justify-content: center;
    }

    .paper-filter-row {
        grid-template-columns: 44px minmax(0, 1fr);
        gap: 8px;
    }
