/* Policy Comparison: two-sided upload, and the review report. */

label { display: block; font-weight: 600; margin-top: 16px; margin-bottom: 4px; font-size: 14px; }
.help { color: #777; font-size: 12px; margin-top: 2px; }
.errorlist { color: #c00000; list-style: none; padding: 0; margin: 6px 0; font-size: 13px; }
.placeholder-note { color: #c00000; font-style: italic; }

button[type=submit] {
    margin-top: 22px; padding: 10px 22px; border: none; border-radius: 4px;
    background: var(--navy); color: #fff; font-size: 15px; cursor: pointer;
}
button[type=submit]:hover { opacity: .9; }
button[disabled] { opacity: .65; cursor: progress; }

.status-badge { display: inline-block; padding: 4px 12px; border-radius: 12px; font-size: 13px; font-weight: 600; }
.status-complete { background: #dff5e1; color: #1a7431; }
.status-failed { background: #fbe1e1; color: #a11; }
.status-pending, .status-reading, .status-extracting, .status-reviewing { background: #fff3cd; color: #916a00; }

/* ------------------------------------------------------- two-sided upload */

.sides { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; margin-top: 18px; }

.side { padding: 18px; border: 1px solid var(--line); border-radius: 10px; background: #fcfdff; }
.side-new { background: #fbfcff; }

.side-title { display: flex; align-items: center; gap: 9px; margin: 0 0 6px; font-size: 15px; color: var(--navy); }

.side-tag {
    padding: 2px 9px; border-radius: 99px; background: var(--navy); color: #fff;
    font-size: 10px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
}
.side-tag-new { background: var(--teal); }

.side-help { margin: 0 0 12px; font-size: 12.5px; color: var(--muted); }

.why {
    margin-top: 18px; padding: 12px 14px;
    border-left: 3px solid var(--teal); border-radius: 0 6px 6px 0;
    background: #f6fbf9; font-size: 13px; color: #35495c;
}

/* ------------------------------------------------------------- the report */

.verdict { margin: 18px 0 14px; padding: 18px 20px; border-radius: 8px; border-left: 4px solid; }
.verdict-clean { background: #f4faf6; border-color: #1a7431; }
.verdict-issues { background: #fdf4f4; border-color: #a11; }

.verdict-headline { margin: 0 0 6px; font-size: 20px; font-weight: 700; }
.verdict-clean .verdict-headline { color: #1a7431; }
.verdict-issues .verdict-headline { color: #a11; }
.verdict-summary { margin: 0 0 8px; font-size: 14.5px; line-height: 1.6; }
.verdict-label { margin: 0; font-size: 11.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }

.glance { display: grid; grid-template-columns: repeat(auto-fit, minmax(135px, 1fr)); gap: 10px; margin-bottom: 6px; }

.g { padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.g-bad { border-color: #f0cccc; background: #fdf4f4; }
.g-warn { border-color: #e6dcc3; background: #fdfaf0; }

.gv { display: block; font-size: 22px; font-weight: 700; color: var(--navy); line-height: 1.2; }
.g-bad .gv { color: #a11; }
.g-warn .gv { color: #916a00; }
.gk { display: block; margin-top: 3px; font-size: 11px; color: var(--muted); }

/* --- what was compared --- */
.compared { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.cmp { padding: 14px 16px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.cmp-new { border-color: #cfe6dc; }
.cmp-title { display: flex; align-items: center; gap: 8px; margin: 0 0 6px; font-weight: 700; color: var(--navy); font-size: 14px; }
.cmp-meta { margin: 0; font-size: 12px; color: var(--muted); }
.cmp-files { margin: 8px 0 0; padding-left: 18px; font-size: 12px; color: #4b5563; }

/* --- headings --- */
.pc-heading {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    margin: 30px 0 8px; padding-bottom: 6px; border-bottom: 2px solid var(--navy);
    color: var(--navy); font-size: 16px; text-transform: uppercase; letter-spacing: .02em;
}

.judgement {
    padding: 2px 8px; border-radius: 99px; background: #fff3cd; color: #916a00;
    font-size: 10.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
}

.pc-note { margin: 0 0 12px; font-size: 12.5px; color: var(--muted); }
.pc-empty { margin: 0; font-size: 13px; color: var(--muted); font-style: italic; }

/* --- tables --- */
.pc-table-wrap {
    overflow-x: auto; margin: 4px 0 10px;
    background:
        linear-gradient(to right, #fff 30%, rgba(255, 255, 255, 0)) left center,
        linear-gradient(to left, #fff 30%, rgba(255, 255, 255, 0)) right center,
        radial-gradient(farthest-side at 0 50%, rgba(32, 35, 96, .18), rgba(32, 35, 96, 0)) left center,
        radial-gradient(farthest-side at 100% 50%, rgba(32, 35, 96, .18), rgba(32, 35, 96, 0)) right center;
    background-repeat: no-repeat;
    background-size: 40px 100%, 40px 100%, 14px 100%, 14px 100%;
    background-attachment: local, local, scroll, scroll;
}

.pc-table { border-collapse: collapse; width: 100%; font-size: 12.5px; }
.pc-table th, .pc-table td { border: 1px solid #e0e2ec; padding: 7px 10px; text-align: left; vertical-align: top; }
.pc-table thead th { background: var(--navy); color: #fff; font-weight: 700; font-size: 12px; }
.pc-rowhead { background: #fafbff; font-weight: 600; min-width: 170px; }
.pc-src { font-size: 11.5px; color: var(--muted); }
.pc-row-note { display: block; margin-top: 3px; font-weight: 400; font-style: italic; font-size: 11px; color: var(--muted); }
.pc-absent { color: #b4b4b4; font-style: italic; font-size: 11.5px; }

/* --- status pills --- */
/* The vocabulary is small and fixed (see schema.py), so anything unrecognised
   falls through to the neutral default rather than rendering unstyled. */
.pill {
    display: inline-block; padding: 2px 9px; border-radius: 99px;
    background: var(--gray); color: var(--muted);
    font-size: 11px; font-weight: 700; letter-spacing: .03em; text-transform: capitalize; white-space: nowrap;
}
.pill-carried_forward, .pill-yes, .pill-unchanged, .pill-increased { background: #dff5e1; color: #1a7431; }
.pill-missing, .pill-no, .pill-reduced, .pill-removed { background: #fbe1e1; color: #a11; }
.pill-unclear, .pill-partial, .pill-changed { background: #fff3cd; color: #916a00; }
.pill-added { background: #e4edfb; color: #22437a; }

/* --- findings --- */
.finding { padding: 14px 16px; border: 1px solid var(--line); border-left-width: 3px; border-radius: 0 8px 8px 0; background: #fff; margin-bottom: 10px; }
.finding-critical { border-left-color: #a11; background: #fdf4f4; }
.finding-warning { border-left-color: #c9a227; background: #fdfaf0; }
.finding-info { border-left-color: var(--teal); background: #f6fbf9; }

.finding-head { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin: 0 0 4px; font-weight: 700; color: var(--navy); font-size: 14px; }
.finding-cat { margin: 0 0 6px; font-size: 11.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.finding p { margin: 0 0 6px; font-size: 13.5px; }
.finding-evidence { font-style: italic; color: #4b5563; font-size: 12.5px; }

.sev { padding: 2px 8px; border-radius: 99px; font-size: 10px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.sev-critical { background: #a11; color: #fff; }
.sev-warning { background: #c9a227; color: #fff; }
.sev-info { background: var(--teal); color: #fff; }

.points { margin: 6px 0 0; padding-left: 20px; font-size: 13.5px; }
.points li { margin-bottom: 5px; }
.points.flagged li { color: #a11; }

.pc-foot { margin-top: 26px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); }
