/* 改稿题「与 AI 对改」（#623）：编辑部校样纸，不另造主题色。 */
.rw-server-verdict {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 7px;
    margin-top: var(--sp-4);
    padding: var(--sp-3);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-light);
}

.rw-server-stamp,
.rw-kicker,
.rw-proof-no,
.rw-misses-title > span {
    font: 700 var(--fs-xs)/1.2 var(--font-mono);
    letter-spacing: .1em;
    text-transform: uppercase;
}

.rw-server-stamp {
    color: var(--gold-text);
}

.rw-duel {
    position: relative;
    margin-top: var(--sp-6);
    padding-top: var(--sp-6);
    border-top: 1px solid var(--border);
}

.rw-duel::before {
    content: "";
    position: absolute;
    top: -1px;
    left: 0;
    width: 86px;
    height: 3px;
    background: var(--gold);
}

.rw-duel-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: var(--sp-3);
}

.rw-kicker {
    margin-bottom: 5px;
    color: var(--gold-text);
}

.rw-duel h4,
.rw-proof h5,
.rw-ai-unavailable h5,
.rw-misses h5 {
    margin: 0;
    font-family: var(--font-serif);
    color: var(--text);
}

.rw-duel h4 {
    font-size: var(--fs-lg);
}

.rw-ruleset {
    max-width: 50%;
    overflow: hidden;
    padding: 5px 8px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-meta);
    font-size: var(--fs-xs);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rw-duel-note {
    margin: var(--sp-2) 0 var(--sp-4);
    color: var(--text-meta);
    font-size: var(--fs-sm);
    line-height: 1.75;
}

.rw-duel-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--sp-3);
}

.rw-proof,
.rw-ai-unavailable {
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--white);
}

.rw-proof-human {
    border-top: 3px solid var(--green);
}

.rw-proof-ai {
    border-top: 3px solid var(--gold);
}

.rw-proof > header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--sp-2);
    padding: var(--sp-3);
    border-bottom: 1px solid var(--border);
}

.rw-proof-no {
    display: block;
    margin-bottom: 4px;
    color: var(--text-meta);
}

.rw-proof h5,
.rw-ai-unavailable h5,
.rw-misses h5 {
    font-size: var(--fs-base);
}

.rw-proof-score {
    display: flex;
    align-items: baseline;
    color: var(--text-meta);
    font-variant-numeric: tabular-nums;
}

.rw-proof-score strong {
    color: var(--text);
    font: 900 var(--fs-2xl)/1 var(--font-display);
}

.rw-proof-score span {
    margin-left: 2px;
    font-size: var(--fs-xs);
}

.rw-proof-copy {
    min-height: 12rem;
    padding: var(--sp-3);
    background:
        linear-gradient(var(--line-2) 1px, transparent 1px) 0 31px / 100% 31px,
        var(--bg-subtle);
    color: var(--text-light);
    font-size: var(--fs-sm);
    line-height: 2.2;
    overflow-wrap: anywhere;
    white-space: pre-wrap;
}

.rw-diff-mark {
    padding: 2px 1px;
    border-bottom: 2px solid var(--gold);
    border-radius: 2px;
    background: var(--gold-light);
    color: var(--text);
}

.rw-proof > footer {
    display: flex;
    flex-wrap: wrap;
    gap: 0 5px;
    padding: 9px var(--sp-3);
    border-top: 1px solid var(--border);
    color: var(--text-meta);
    font-size: var(--fs-xs);
    line-height: 1.6;
}

.rw-proof > footer b {
    margin-left: auto;
    color: var(--text-light);
}

.rw-ai-unavailable {
    display: flex;
    min-height: 18rem;
    flex-direction: column;
    justify-content: center;
    padding: var(--sp-6);
    border-style: dashed;
    background: var(--bg-subtle);
}

.rw-ai-unavailable p {
    margin: var(--sp-2) 0 0;
    color: var(--text-meta);
    font-size: var(--fs-sm);
    line-height: 1.8;
}

.rw-misses {
    display: grid;
    grid-template-columns: 9rem 1fr;
    gap: var(--sp-3);
    margin-top: var(--sp-3);
    padding: var(--sp-3);
    border: 1px solid var(--border);
    border-left: 3px solid var(--red);
    border-radius: var(--radius-sm);
    background: var(--red-light);
}

.rw-misses-title > span {
    display: block;
    margin-bottom: 5px;
    color: var(--red);
}

.rw-miss-item + .rw-miss-item {
    margin-top: var(--sp-2);
    padding-top: var(--sp-2);
    border-top: 1px solid var(--border);
}

.rw-miss-item b {
    color: var(--text);
    font-size: var(--fs-sm);
}

.rw-miss-item p,
.rw-no-miss {
    margin: 3px 0 0;
    color: var(--text-light);
    font-size: var(--fs-sm);
    line-height: 1.75;
}

@media (max-width: 640px) {
    .rw-duel-head {
        align-items: start;
        flex-direction: column;
    }

    .rw-ruleset {
        max-width: 100%;
    }

    .rw-duel-grid,
    .rw-misses {
        grid-template-columns: 1fr;
    }

    .rw-proof-copy {
        min-height: 0;
    }

    .rw-ai-unavailable {
        min-height: 0;
        padding: var(--sp-4);
    }
}
