/* ============================================================
   /cve/trending — three-column trending CVE view (modern)
   ============================================================ */

.cvt-hero {
    margin-bottom: 18px;
    padding: 28px 32px 24px;
    background: linear-gradient(135deg, var(--bg-1) 0%, var(--surface) 100%);
    border-radius: 16px;
    color: var(--ink);
    position: relative;
    overflow: hidden;
}
.cvt-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,0.05) 1px, transparent 0);
    background-size: 18px 18px;
    opacity: 0.6;
}
.cvt-hero-inner { position: relative; z-index: 1; }
.cvt-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: var(--ink-3);
    margin-bottom: 14px;
}
.cvt-hero-eyebrow-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
    display: inline-block;
}
.cvt-hero h1 {
    margin: 0 0 8px;
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--ink);
    line-height: 1.05;
    letter-spacing: -0.02em;
}
.cvt-hero-sub {
    margin: 0;
    color: var(--ink-2);
    max-width: 760px;
    line-height: 1.55;
    font-size: 0.95rem;
}

/* ── KPI strip ──────────────────────────────────────────────── */
.cvt-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0;
    margin-bottom: 18px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
}
.cvt-kpi {
    padding: 20px 22px;
    border-right: 1px solid var(--border-color);
}
.cvt-kpi:last-child { border-right: 0; }
@media (max-width: 720px) {
    .cvt-kpi { border-right: 0; border-bottom: 1px solid var(--border-color); }
    .cvt-kpi:last-child { border-bottom: 0; }
}
.cvt-kpi-val {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
}
.cvt-kpi-lbl {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-tertiary);
    margin-top: 8px;
    font-weight: 700;
}

/* ── Three-column grid ──────────────────────────────────────── */
/* minmax(0, 1fr) instead of bare 1fr so the columns can shrink below
   their content's intrinsic min-width. Without it, a long product
   name or wide chip row blows the grid past the viewport on
   narrower laptops (1024-1280px) and forces horizontal scroll. */
.cvt-cols {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
}
@media (min-width: 980px) {
    .cvt-cols { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Keep .cve-section as the column frame; override from cve.css so the
   trending page uses the same bordered panel pattern as /ransomware. */
.cvt-cols .cve-section {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 18px 22px 22px;
    margin-bottom: 0;
    min-width: 0;
    overflow: hidden;
}
.cvt-cols .cve-section h2 {
    margin: 0 0 14px;
    font-size: 0.82rem;
    font-weight: 800;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 8px;
}
.cvt-section-help {
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-tertiary);
    text-transform: none;
    letter-spacing: 0;
    white-space: nowrap;
}

/* ── Row (CVE list item) ────────────────────────────────────── */
/* Grid layout: header line (CVE ID + right metric on opposite ends),
   then product name on its own line, then chips. This keeps things
   readable in narrow ~340-400px columns without horizontal squeezing. */
.cvt-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
        "cveid right"
        "mid   mid";
    column-gap: 10px;
    row-gap: 4px;
    padding: 10px 12px;
    border-radius: 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    text-decoration: none;
    color: var(--text-primary);
    margin-bottom: 6px;
    transition: border-color 100ms ease;
}
.cvt-row:hover {
    border-color: var(--accent);
}

.cvt-cve-id {
    grid-area: cveid;
    font-family: 'JetBrains Mono', 'SF Mono', 'Fira Code', Menlo, Consolas, monospace;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-primary);
    letter-spacing: -0.01em;
    align-self: center;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.cvt-mid {
    grid-area: mid;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.cvt-product {
    font-size: 0.78rem;
    color: var(--text-secondary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.cvt-chips {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}
.cvt-chip {
    font-size: 0.62rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 999px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.cvt-chip-critical { background: rgba(220, 38, 38, 0.18); color: var(--accent-1); }
.cvt-chip-high     { background: rgba(234, 88, 12, 0.18); color: var(--warn); }
.cvt-chip-medium   { background: rgba(59, 130, 246, 0.18); color: var(--info); }
.cvt-chip-low      { background: rgba(16, 185, 129, 0.16); color: var(--ok); }
.cvt-chip-ransom   { background: rgba(124, 58, 237, 0.18); color: #C4B5FD; }
.cvt-chip-actors   { background: rgba(220, 38, 38, 0.14); color: var(--accent-1); }
.cvt-chip-kev      { background: rgba(220, 38, 38, 0.18); color: var(--accent-1); }

.cvt-right {
    grid-area: right;
    text-align: right;
    font-size: 0.68rem;
    color: var(--text-tertiary);
    line-height: 1.3;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 600;
    align-self: center;
    white-space: nowrap;
}
.cvt-right strong {
    display: block;
    font-size: 0.95rem;
    color: var(--text-primary);
    line-height: 1;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.01em;
    font-weight: 800;
    text-transform: none;
}
