/* Comparison pages (/compare and /vs/<slug>).
   Layered on top of resources.css -- these only add what the article styles
   do not already cover: the winner-marked comparison table, the correction
   callouts, the balance columns, and the sourced-figures footer. */

/* ── Verification banner ──────────────────────────────────────────── */
.comparison-verified {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    margin-bottom: 24px;
    border: 1px solid var(--df-glass-border);
    border-radius: 12px;
    background: var(--df-glass-bg-subtle);
    font-size: 0.9rem;
    color: var(--df-text);
}
.comparison-verified i {
    width: 18px;
    height: 18px;
    color: var(--df-primary);
    flex-shrink: 0;
}

/* ── At-a-glance table ────────────────────────────────────────────── */
.comparison-table {
    width: 100%;
    border-collapse: collapse;
}
.comparison-table th,
.comparison-table td {
    padding: 12px 14px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--df-glass-border);
    font-size: 0.94rem;
    line-height: 1.5;
}
.comparison-table thead th {
    font-weight: 700;
    white-space: nowrap;
}
.comparison-table .col-ours {
    background: color-mix(in srgb, var(--df-primary) 8%, transparent);
}
/* The [data-theme] variant raises specificity above the themed .content-table
   thead rule in resources.css, which otherwise greys out our own column header
   in dark mode -- the one cell the eye is meant to land on. */
.comparison-table thead th.col-ours,
[data-theme] .comparison-table thead th.col-ours {
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    color: var(--df-primary);
    background: color-mix(in srgb, var(--df-primary) 12%, transparent);
}
.comparison-table tbody th[scope="row"] {
    font-weight: 600;
    width: 26%;
}

/* A small marker rather than a colour-only signal, so the winner column is
   still readable for anyone who cannot distinguish the tint. */
.win-marker {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
}
.win-marker::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
    background: currentColor;
}
.win-us { color: var(--df-primary); }
.win-them { color: var(--df-gray-500); }
.win-tie { color: var(--df-gray-400); }

/* ── Corrections ──────────────────────────────────────────────────── */
.correction {
    border: 1px solid var(--df-glass-border-strong);
    border-left: 3px solid var(--df-primary);
    border-radius: 12px;
    padding: 18px 20px;
    margin-bottom: 18px;
    background: var(--df-glass-bg-subtle);
}
.correction-claim {
    font-weight: 600;
    margin: 0 0 6px;
}
.correction-verdict {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 3px 9px;
    border-radius: 999px;
    margin-bottom: 10px;
    background: color-mix(in srgb, var(--df-primary) 14%, transparent);
    color: var(--df-primary);
}
.correction p:last-child { margin-bottom: 0; }

/* ── Balance columns (they win / we win) ──────────────────────────── */
.balance-item {
    padding: 16px 0;
    border-bottom: 1px solid var(--df-glass-border);
}
.balance-item:last-child { border-bottom: none; padding-bottom: 0; }
.balance-item h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.02rem;
    margin: 0 0 6px;
}
.balance-item h3 i { width: 18px; height: 18px; color: var(--df-primary); flex-shrink: 0; }
.balance-item p { margin: 0; }
.balance-proof {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: 8px;
    font-size: 0.87rem;
    font-weight: 600;
}

/* ── Verdict split ────────────────────────────────────────────────── */
.verdict-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}
.verdict-card {
    padding: 18px 20px;
    border-radius: 14px;
    border: 1px solid var(--df-glass-border);
    background: var(--df-glass-bg-subtle);
}
.verdict-card.is-ours {
    border-color: color-mix(in srgb, var(--df-primary) 45%, transparent);
    background: color-mix(in srgb, var(--df-primary) 7%, transparent);
}
.verdict-card h3 { margin: 0 0 8px; font-size: 1rem; }
.verdict-card p { margin: 0; font-size: 0.94rem; }

/* ── Sources ──────────────────────────────────────────────────────── */
.source-list { list-style: none; padding: 0; margin: 0; }
.source-list li {
    padding: 9px 0;
    border-bottom: 1px solid var(--df-glass-border);
    font-size: 0.92rem;
}
.source-list li:last-child { border-bottom: none; }
.source-list a { word-break: break-word; }

/* ── Hub cards ────────────────────────────────────────────────────── */
.compare-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 8px;
}
.compare-card {
    display: flex;
    flex-direction: column;
    padding: 24px;
    border-radius: 16px;
    border: 1px solid var(--df-glass-border);
    background: var(--df-glass-bg);
    text-decoration: none;
    color: inherit;
    transition: transform 0.18s ease, border-color 0.18s ease;
}
.compare-card:hover {
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--df-primary) 50%, transparent);
}
.compare-card h2 { font-size: 1.18rem; margin: 0 0 10px; }
.compare-card p { font-size: 0.93rem; margin: 0 0 14px; }
.compare-card-cta {
    margin-top: auto;
    font-weight: 600;
    color: var(--df-primary);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

@media (max-width: 720px) {
    .comparison-table tbody th[scope="row"] { width: auto; }
    .comparison-table th,
    .comparison-table td { padding: 10px; font-size: 0.88rem; }
}
