/* 试卷详情页：优化信息层级、预览状态和多端阅读体验。 */
.paper-detail-page > .breadcrumb {
    display: flex;
    overflow: hidden;
    width: 100%;
    height: 50px;
    padding-right: 0;
    padding-left: 0;
    align-items: center;
    box-sizing: border-box;
    line-height: 50px;
    white-space: nowrap;
}

.paper-detail-page > .breadcrumb > a {
    flex: 0 0 auto;
}

.paper-detail-page .breadcrumb-paper-title,
.paper-detail-page > .breadcrumb > span:last-child {
    display: block;
    overflow: hidden;
    min-width: 0;
    color: #8a94a3;
    flex: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.paper-detail-page .content {
    display: grid;
    width: 100%;
    grid-template-columns: minmax(0, 1fr) 310px;
    gap: 20px;
}

/* 旧版清除浮动伪元素不能作为 Grid 子项参与排版。 */
.paper-detail-page .content::before,
.paper-detail-page .content::after {
    display: none;
    content: none;
}

.paper-detail-page .left-box,
.paper-detail-page .right-box {
    float: none;
    width: auto;
    min-width: 0;
    margin-left: 0;
}

.paper-detail-page .viewtop,
.paper-detail-page .noticebox,
.paper-detail-page .view-ta,
.paper-detail-page .list-box {
    border: 1px solid #edf0f5;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(38, 50, 68, .05);
}

.paper-detail-page .viewtop .docinfobox .title {
    display: flex;
    width: 100%;
    align-items: flex-start;
}

.paper-detail-page .viewtop .docinfobox .title h1 {
    float: none;
    width: auto;
    min-width: 0;
    flex: 1;
    font-size: 24px;
    font-weight: 650;
}

.paper-detail-page .viewtop .docinfobox .title ul.operate {
    float: none;
    flex: 0 0 auto;
}

.paper-detail-page .view-tabs {
    padding: 0 20px 18px;
    color: #7c8797;
}

.paper-meta-tags {
    display: flex;
    padding: 0 0 18px;
    flex-wrap: wrap;
    gap: 8px;
}

.paper-meta-tags a,
.paper-meta-tags span {
    display: inline-flex;
    min-height: 28px;
    padding: 0 11px;
    border-radius: 14px;
    align-items: center;
    color: #667085;
    font-size: 12px;
    background: #f3f5f8;
}

.paper-meta-tags a {
    color: #d9363e;
    background: #fff1f0;
}

.paper-preview-heading {
    display: flex;
    margin-top: 14px;
    padding: 18px 22px;
    border: 1px solid #edf0f5;
    border-radius: 10px 10px 0 0;
    align-items: center;
    justify-content: space-between;
    background: #fff;
}

.paper-preview-heading h2 {
    color: #252f3f;
    font-size: 20px;
    line-height: 30px;
}

.paper-preview-heading p {
    margin-top: 3px;
    color: #8a94a3;
    font-size: 13px;
}

.paper-preview-heading > a {
    padding: 9px 18px;
    border: 1px solid #f0aaa5;
    border-radius: 20px;
    color: #d9363e;
    white-space: nowrap;
    background: #fff7f6;
}

.paper-detail-page .view-body {
    margin-top: 0;
    padding-top: 18px;
    border-radius: 0 0 10px 10px;
}

.paper-preview-empty {
    display: flex;
    min-height: 330px;
    border: 1px dashed #dfe4eb;
    border-radius: 10px;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    color: #98a1af;
    background: linear-gradient(145deg, #fff 0%, #f5f7fa 100%);
}

/* 预览图品牌遮罩：保留题目可读性，同时明确图片来源和预览属性。 */
.paper-detail-page .view-page[data-preview-page] {
    position: relative;
    overflow: hidden;
}

.paper-preview-watermark {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    color: rgba(210, 48, 48, .2);
    pointer-events: none;
    transform: rotate(-24deg);
    user-select: none;
}

.paper-preview-watermark span {
    padding: 10px 22px;
    border: 2px solid rgba(210, 48, 48, .14);
    border-radius: 8px;
    font-size: 34px;
    font-weight: 700;
    letter-spacing: 8px;
}

.paper-preview-watermark small {
    margin-top: 8px;
    font-size: 15px;
    letter-spacing: 6px;
}

.paper-preview-end-mask {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 3;
    display: flex;
    min-height: 150px;
    padding: 54px 20px 22px;
    align-items: center;
    flex-direction: column;
    justify-content: flex-end;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0), rgba(255, 255, 255, .96) 58%);
    box-sizing: border-box;
}

.paper-preview-end-mask strong {
    color: #374151;
    font-size: 16px;
}

.paper-preview-end-mask a {
    margin-top: 10px;
    padding: 8px 20px;
    border-radius: 18px;
    color: #fff;
    background: #ec3b3b;
}

.paper-preview-empty i {
    margin-bottom: 18px;
    font-size: 48px;
    color: #ef6a62;
}

.paper-preview-empty strong {
    margin-bottom: 8px;
    font-size: 18px;
    color: #465164;
}

.paper-detail-page .view-bar {
    width: 100%;
    margin-top: 12px;
    border-radius: 10px;
    text-align: center;
}

.paper-wechat-guide {
    display: flex;
    margin-top: 12px;
    padding: 22px 26px;
    border: 1px solid #ffd9d4;
    border-radius: 10px;
    align-items: center;
    background: linear-gradient(135deg, #fff8f6 0%, #fff 100%);
    box-shadow: 0 5px 20px rgba(38, 50, 68, .04);
}

.paper-wechat-guide-icon {
    display: flex;
    width: 52px;
    height: 52px;
    margin-right: 18px;
    border-radius: 14px;
    align-items: center;
    flex: 0 0 auto;
    justify-content: center;
    color: #fff;
    font-size: 22px;
    font-weight: 700;
    background: #07c160;
}

.paper-wechat-guide-content > span {
    color: #8b95a5;
    font-size: 13px;
}

.paper-wechat-guide-content h2 {
    margin: 3px 0 5px;
    color: #252f3f;
    font-size: 20px;
    line-height: 30px;
}

.paper-wechat-guide-content p {
    color: #7b8594;
    font-size: 13px;
}

.paper-detail-page .noticebox .notice_hd span {
    position: relative;
    font-size: 18px;
}

.paper-detail-page .noticebox .notice_hd span::before {
    position: absolute;
    bottom: -18px;
    left: 50%;
    width: 60px;
    height: 4px;
    margin-left: -30px;
    border-radius: 30px;
    background: #ec3b3b;
    content: "";
}

@media (max-width: 1100px) {
    .paper-detail-page .content {
        display: block;
    }

    .paper-detail-page .right-box {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }
}

@media (max-width: 768px) {
    .paper-detail-page {
        width: calc(100% - 24px) !important;
        padding: 0 0 76px;
    }

    .paper-detail-page > .breadcrumb {
        height: 42px;
        line-height: 42px;
    }

    .paper-detail-page .breadcrumb-paper-title,
    .paper-detail-page > .breadcrumb > span:last-child {
        display: none;
    }

    .paper-detail-page .viewtop .docinfobox {
        padding: 18px 16px 0;
    }

    .paper-detail-page .viewtop .docinfobox .title {
        display: block;
    }

    .paper-detail-page .viewtop .docinfobox .title h1 {
        font-size: 20px;
        line-height: 30px;
    }

    .paper-detail-page .viewtop .docinfobox .title ul.operate {
        display: none;
    }

    .paper-detail-page .viewtop .docinfobox .intro,
    .paper-detail-page .viewtop .docinfobox .intro ul.intro-list {
        height: auto;
    }

    .paper-detail-page .viewtop .docinfobox .intro ul.intro-list {
        display: flex;
        flex-wrap: wrap;
    }

    .paper-detail-page .view-tabs {
        padding: 8px 16px 16px;
    }

    .paper-meta-tags {
        padding-bottom: 14px;
    }

    .paper-preview-heading {
        padding: 14px 16px;
    }

    .paper-preview-heading h2 {
        font-size: 17px;
    }

    .paper-preview-heading p {
        font-size: 12px;
        line-height: 18px;
    }

    .paper-preview-heading > a {
        display: none;
    }

    .paper-preview-empty {
        min-height: 230px;
        padding: 20px;
        text-align: center;
    }

    .paper-preview-watermark span {
        padding: 8px 14px;
        font-size: 22px;
        letter-spacing: 4px;
    }

    .paper-preview-end-mask {
        min-height: 120px;
        padding-bottom: 16px;
    }

    .paper-detail-page .view-bar,
    .paper-detail-page .view-bar.fixed {
        position: fixed;
        right: 0;
        bottom: 0;
        left: 0;
        z-index: 998;
        width: 100%;
        height: 66px;
        margin: 0;
        padding: 10px 12px;
        border-radius: 0;
        box-shadow: 0 -5px 20px rgba(31, 42, 58, .12);
    }

    .paper-detail-page .view-bar .view-down-btn {
        width: 100%;
        max-width: 420px;
        box-sizing: border-box;
    }

    .paper-wechat-guide {
        padding: 18px 16px;
        align-items: flex-start;
    }

    .paper-wechat-guide-icon {
        width: 44px;
        height: 44px;
        margin-right: 12px;
        border-radius: 12px;
        font-size: 18px;
    }

    .paper-wechat-guide-content h2 {
        font-size: 17px;
        line-height: 26px;
    }

    .paper-detail-page .noticebox {
        padding: 20px 16px;
    }

    .paper-detail-page .noticeidtxt {
        line-height: 24px;
    }

    .paper-detail-page .view-ta {
        padding: 0 14px 16px;
    }

    .paper-detail-page .view-ta .doc-list-title {
        height: 56px;
        line-height: 56px;
    }

    .paper-detail-page .view-ta .list-row {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .paper-detail-page .view-ta .list-row .list-item {
        width: auto;
        margin: 0;
        padding: 8px;
    }

    .paper-detail-page .view-ta .list-row .list-item-img {
        height: auto;
        aspect-ratio: 4 / 5;
    }

    .paper-detail-page .right-box {
        display: block;
    }

    .paper-detail-page .right-box .list-box {
        margin-top: 12px;
    }
}
