    /* ── Dithering shader background ── */
    .bench-shader-wrap {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        z-index: 0;
        pointer-events: none;
        display: none;
        opacity: 0;
        mix-blend-mode: multiply;
        -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.18) 28%, rgba(0,0,0,0.18) 72%, rgba(0,0,0,0.8) 100%);
                mask-image: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.18) 28%, rgba(0,0,0,0.18) 72%, rgba(0,0,0,0.8) 100%);
    }

    .bench-shader-wrap canvas {
        display: block;
        width: 100vw;
        height: 100vh;
    }

    /* ── Base ── */
    .bench-page {
        display: grid;
        gap: 3rem;
        padding-top: 0.7rem;
        padding-bottom: 3rem;
        overflow-x: hidden;
        overflow-wrap: break-word;
        word-wrap: break-word;
        position: relative;
        z-index: 1;
    }

    .bench-panel {
        padding-top: 1.2rem;
    }

    #ecosystem-results.bench-panel {
        padding: 1.6rem 0 1.4rem;
        border-top: 1px solid var(--line);
    }

    #prior-work.bench-panel {
        padding: 1.4rem 1.2rem 1.3rem;
        border: 1px solid var(--line);
        border-radius: 4px;
        background: rgba(247, 244, 236, 0.97);
    }

    @media (max-width: 760px) {
        #ecosystem-results.bench-panel { padding: 1.1rem 0 1rem; }
        #prior-work.bench-panel { padding: 1.1rem 0.85rem; }
    }

    .bench-hero {
        padding: 0.6rem 0 1.4rem;
        position: relative;
        border-bottom: 1px solid var(--line);
    }

    .bench-hero-meta {
        margin: 0.9rem 0 0;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 0.55rem;
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.72rem;
        letter-spacing: 0.04em;
        color: var(--text-soft);
    }
    .bench-hero-meta > span[aria-hidden="true"] {
        color: var(--line-strong);
    }

    .bench-kicker {
        display: inline-block;
        margin: 0 0 0.6rem;
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.68rem;
        letter-spacing: 0.16em;
        text-transform: uppercase;
        color: var(--accent-strong);
        font-weight: 700;
    }

    .bench-title {
        margin: 0 0 0.85rem;
        font-size: clamp(2rem, 4.4vw, 3.4rem);
        line-height: 1.08;
        letter-spacing: -0.02em;
        max-width: 34ch;
        text-wrap: balance;
    }

    .bench-title-qualifier {
        display: inline;
        font-size: 0.72em;
        font-weight: 500;
        color: var(--text-soft);
        letter-spacing: 0;
        white-space: normal;
    }

    .bench-sub {
        margin: 0;
        max-width: 68ch;
        color: var(--text-soft);
        font-size: 1rem;
        line-height: 1.75;
    }

    .bench-hero-nav {
        display: flex;
        flex-wrap: wrap;
        gap: 0.3rem;
        margin-top: 1.1rem;
    }

    .bench-hero-nav a {
        border: 1px solid var(--line-strong);
        background: rgba(247, 244, 236, 0.97);
        padding: 0.36rem 0.7rem;
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.66rem;
        text-transform: uppercase;
        letter-spacing: 0.1em;
        color: var(--text-main);
        text-decoration: none;
        border-radius: 999px;
        transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
    }

    .bench-hero-nav a:hover,
    .bench-hero-nav a:focus-visible {
        color: #fff;
        border-color: var(--accent);
        background: var(--accent);
        outline: none;
    }

    .bench-proof {
        margin-top: -0.6rem;
    }

    .bench-proof-grid {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 0.85rem;
    }

    .bench-proof-card {
        border-left: 1px solid var(--line);
        padding: 1.2rem 1rem 1rem;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
    }

    .bench-proof-value {
        display: block;
        font-family: 'IBM Plex Mono', monospace;
        font-size: clamp(2rem, 3.4vw, 2.9rem);
        font-weight: 700;
        line-height: 1;
        margin-bottom: 0.5rem;
        color: var(--text-main);
        letter-spacing: -0.01em;
    }

    .bench-proof-card--hero .bench-proof-value {
        font-size: clamp(2.4rem, 4vw, 3.4rem);
        color: var(--accent);
    }

    .bench-proof-label {
        display: block;
        font-size: 0.72rem;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        font-weight: 700;
        color: var(--text-main);
        margin-bottom: 0.4rem;
    }

    .bench-proof-detail {
        margin: 0;
        color: var(--text-soft);
        font-size: 0.74rem;
        line-height: 1.55;
    }

    .bench-section-title {
        margin: 0 0 0.35rem;
        font-size: clamp(1.15rem, 2.5vw, 1.58rem);
        letter-spacing: -0.01em;
    }

    .bench-section-sub {
        margin: 0 0 1rem;
        color: var(--text-soft);
        font-size: 0.85rem;
        line-height: 1.55;
        max-width: 72ch;
    }

    .bench-title-date {
        font-size: 0.58em;
        font-weight: 500;
        color: var(--text-soft);
        letter-spacing: 0;
        margin-left: 0.45rem;
        vertical-align: 0.15em;
    }

    .bench-prose {
        color: var(--text-soft);
        font-size: 0.85rem;
        line-height: 1.7;
        max-width: 72ch;
    }

    .bench-prose p { margin: 0 0 0.9rem; }
    .bench-prose p:last-child { margin-bottom: 0; }
    .bench-prose strong { color: var(--text-main); font-weight: 600; }
    .bench-prose a { color: var(--accent-strong); text-decoration: underline; text-underline-offset: 2px; }
    .bench-prose a:hover { color: var(--text-main); }

    /* ── Reveal (no animation — always visible) ── */
    .reveal {
        opacity: 1;
        transform: none;
    }

    /* ── Tab switcher ── */
    .bench-tabs {
        display: inline-flex;
        border: 1px solid var(--line);
        margin-bottom: 1.1rem;
        overflow: hidden;
    }

    .bench-tab {
        padding: 0.55rem 1.2rem;
        font-size: 0.78rem;
        font-weight: 600;
        letter-spacing: 0.02em;
        cursor: pointer;
        color: var(--text-soft);
        background: transparent;
        border: none;
        border-right: 1px solid var(--line);
        display: flex;
        align-items: center;
        gap: 0.45rem;
        transition: background 0.25s, color 0.25s;
        font-family: inherit;
    }

    .bench-tab:last-child { border-right: none; }

    .bench-tab:hover {
        background: rgba(var(--accent-rgb), 0.05);
        color: var(--text-main);
    }

    .bench-tab.active {
        background: rgba(var(--accent-rgb), 0.08);
        color: var(--accent);
    }

    .bench-tab-badge {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0.15rem 0.5rem;
        border-radius: 4px;
        font-size: 0.62rem;
        font-weight: 700;
        letter-spacing: 0.04em;
    }

    .bench-tab-badge--npm {
        background: rgba(203, 63, 56, 0.12);
        color: #cb3f38;
    }

    .bench-tab-badge--pypi {
        background: rgba(55, 118, 171, 0.15);
        color: #3776AB;
    }

    .bench-tab-content {
        display: none;
        animation: tabFadeIn 0.4s ease;
    }

    .bench-tab-content.active { display: block; }

    @keyframes tabFadeIn {
        from { opacity: 0; transform: translateY(8px); }
        to { opacity: 1; transform: translateY(0); }
    }

    /* ── Results callouts ── */
    .bench-callouts {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        margin-bottom: 1rem;
        border-top: 1px solid var(--line);
        border-bottom: 1px solid var(--line);
    }

    .bench-callout {
        padding: 0.95rem 0.8rem;
        border-right: 1px solid var(--line);
        transition: background 0.2s ease;
    }

    .bench-callout:hover { background: rgba(var(--accent-rgb), 0.02); }
    .bench-callout:last-child { border-right: none; }

    .bench-callout-value {
        display: block;
        font-family: 'IBM Plex Mono', monospace;
        font-size: clamp(1.6rem, 3vw, 2.2rem);
        font-weight: 700;
        color: var(--text-main);
        line-height: 1.1;
        margin-bottom: 0.3rem;
    }

    .bench-callout-label {
        display: block;
        font-size: 0.7rem;
        font-weight: 600;
        color: var(--text-soft);
        text-transform: uppercase;
        letter-spacing: 0.06em;
        margin-bottom: 0.15rem;
    }

    .bench-callout-detail {
        display: block;
        font-size: 0.68rem;
        color: var(--text-soft);
        line-height: 1.4;
    }

    .bench-callout-value--pypi { color: var(--accent-strong); }

    .bench-corpus-dot {
        display: inline-block;
        width: 10px;
        height: 10px;
        border-radius: 2px;
        margin-right: 0.35rem;
        vertical-align: middle;
    }
    .bench-corpus-dot--tp { background: var(--accent); }
    .bench-corpus-dot--fn { background: var(--line-strong); }
    .bench-corpus-dot--tn { background: #64748b; }

    .bench-note {
        margin-top: 1.4rem;
        padding: 1rem 1.2rem;
        border: 1px solid var(--line);
        border-left: 3px solid var(--accent-strong);
        border-radius: 3px;
        background: rgba(247, 244, 236, 0.97);
        font-size: 0.78rem;
        color: var(--text-soft);
        line-height: 1.6;
    }
    .bench-note strong {
        color: var(--text-main);
        font-size: 0.72rem;
        text-transform: uppercase;
        letter-spacing: 0.08em;
    }
    .bench-note-code {
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.72rem;
        padding: 0.05rem 0.3rem;
        background: var(--bg-alt);
        color: var(--accent-strong);
        border-radius: 2px;
    }

    /* ── Source list ── */
    .bench-source-grid {
        display: flex;
        flex-direction: column;
        gap: 0;
        margin-top: 1.5rem;
        margin-bottom: 2.5rem;
        border-top: none;
    }

    .bench-source-card {
        padding: 1.5rem 0;
        border-top: 1px solid var(--line);
        display: grid;
        grid-template-columns: minmax(200px, 1fr) 2.5fr;
        gap: 2rem;
        align-items: baseline;
    }

    .bench-source-name {
        display: block;
        font-size: 0.95rem;
        font-weight: 700;
        color: var(--text-main);
        line-height: 1.25;
    }

    .bench-source-name a {
        color: var(--text-main);
        text-decoration: none;
        border-bottom: 1px solid var(--line);
        transition: color 0.2s ease, border-color 0.2s ease;
    }

    .bench-source-name a:hover { color: var(--accent-strong); border-color: var(--accent); }

    .bench-source-desc {
        font-size: 0.85rem;
        color: var(--text-soft);
        line-height: 1.55;
        margin: 0;
    }

    .bench-source-label {
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.65rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.1em;
        color: var(--text-soft);
        margin-top: 0.2rem;
    }

    .bench-source-card:nth-child(-n+3) .bench-source-label {
        color: rgba(220, 38, 38, 0.85);
    }
    .bench-source-card:nth-child(4) .bench-source-label {
        color: rgba(5, 150, 105, 0.85);
    }

    /* ── Comparison table ── */
    .bench-table-wrap {
        background: rgba(247, 244, 236, 1);
        border: 1px solid var(--line);
    }
    .bench-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 0.84rem;
        text-align: center;
    }

    .bench-table thead th {
        padding: 0.8rem 0.85rem;
        background: rgba(26, 26, 26, 0.04);
        font-size: 0.66rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        color: var(--text-main);
        border-bottom: 1px solid var(--line-strong);
        border-right: 1px solid var(--line);
    }

    .bench-table thead th:last-child { border-right: none; }
    .bench-table thead th:first-child { text-align: left; color: var(--text-soft); }

    .bench-table tbody td {
        padding: 0.7rem 0.85rem;
        border-bottom: 1px solid var(--line);
        border-right: 1px solid var(--line);
        color: var(--text-main);
        transition: background 0.2s;
    }

    .bench-table tbody td:last-child { border-right: none; }
    .bench-table tbody td:first-child {
        text-align: left;
        font-weight: 600;
        color: var(--text-soft);
        background: rgba(26, 26, 26, 0.02);
    }
    .bench-table tbody tr:nth-child(even) td { background: rgba(26, 26, 26, 0.018); }
    .bench-table tbody tr:nth-child(even) td:first-child { background: rgba(26, 26, 26, 0.035); }
    .bench-table tbody tr:hover td { background: rgba(var(--accent-rgb), 0.05); }

    .bench-table .bench-ours {
        background: rgba(var(--accent-rgb), 0.07) !important;
        font-weight: 700;
        color: var(--accent-strong);
    }
    .bench-table tbody tr:nth-child(even) td.bench-ours {
        background: rgba(var(--accent-rgb), 0.1) !important;
    }
    .bench-table tbody tr:hover td.bench-ours {
        background: rgba(var(--accent-rgb), 0.13) !important;
    }

    .bench-table thead .bench-ours {
        background: rgba(var(--accent-rgb), 0.16) !important;
        color: var(--accent);
        border-bottom-color: rgba(var(--accent-rgb), 0.4);
    }

    /* ── Confusion matrix ── */
    .bench-confusion {
        display: grid;
        grid-template-columns: 7rem 1fr 1fr;
        grid-template-rows: auto auto auto;
        border: 1px solid var(--line);
        border-radius: 3px;
        margin-top: 1rem;
        overflow: hidden;
        background: var(--surface);
    }
    .bench-confusion-corner { background: transparent; }
    .bench-confusion-colhead,
    .bench-confusion-rowhead {
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.64rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        color: var(--text-soft);
        padding: 0.55rem 0.8rem;
        background: var(--bg-alt);
        display: flex;
        align-items: center;
    }
    .bench-confusion-colhead {
        justify-content: center;
        border-right: 1px solid var(--line);
        border-bottom: 1px solid var(--line);
    }
    .bench-confusion-colhead:last-of-type { border-right: none; }
    .bench-confusion-rowhead {
        justify-content: center;
        text-align: center;
        border-right: 1px solid var(--line);
        border-bottom: 1px solid var(--line);
        line-height: 1.3;
    }
    .bench-confusion-rowhead:last-of-type { border-bottom: none; }
    .bench-confusion-cell {
        padding: 0.9rem 1rem;
        border-right: 1px solid var(--line);
        border-bottom: 1px solid var(--line);
        display: flex;
        flex-direction: column;
        gap: 0.2rem;
        align-items: flex-start;
    }
    .bench-confusion-cell:nth-of-type(2n) { border-right: none; }
    .bench-confusion-cell:nth-last-of-type(-n+2) { border-bottom: none; }
    .bench-confusion-cell--good { background: rgba(var(--accent-rgb), 0.04); }
    .bench-confusion-cell--bad { background: rgba(180, 60, 60, 0.04); }
    .bench-confusion-label {
        font-size: 0.86rem;
        font-weight: 700;
        color: var(--text-main);
    }
    .bench-confusion-abbr {
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.64rem;
        font-weight: 700;
        letter-spacing: 0.1em;
        color: var(--text-soft);
    }

    /* ── Methodology lede + grid ── */
    .bench-method-lede {
        margin: 0.4rem 0 1.2rem;
        max-width: 56ch;
        font-size: 0.92rem;
        line-height: 1.7;
        color: var(--text-soft);
    }
    .bench-method-lede strong { color: var(--text-main); font-weight: 600; }

    .bench-method-grid {
        display: flex;
        flex-direction: column;
        gap: 0;
        margin-top: 1.5rem;
        border-top: none;
    }

    .bench-method-card {
        padding: 1.5rem 0;
        border-top: 1px solid var(--line);
        display: grid;
        grid-template-columns: minmax(200px, 1fr) 2.5fr;
        gap: 2rem;
        align-items: baseline;
    }

    .bench-method-card h4 {
        margin: 0;
        font-size: 0.95rem;
        font-weight: 700;
        color: var(--text-main);
        letter-spacing: -0.005em;
    }
    
    .bench-method-card p {
        margin: 0;
        font-size: 0.85rem;
        color: var(--text-soft);
        line-height: 1.6;
    }

    .bench-method-card code {
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.72rem;
        background: var(--bg-alt);
        color: var(--text-main);
        padding: 0.1rem 0.3rem;
        border: 1px solid var(--line);
    }

    /* ── Corpus stacked bar ── */
    .bench-corpus-bar-wrap {
        margin-top: 1.2rem;
    }

    .bench-corpus-title {
        font-size: 0.68rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.1em;
        color: var(--text-soft);
        margin: 0 0 0.6rem;
    }

    .bench-corpus-bar {
        display: flex;
        height: 28px;
        border: 1px solid var(--line);
        overflow: hidden;
    }

    .bench-corpus-seg {
        display: flex;
        align-items: center;
        justify-content: center;
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.62rem;
        font-weight: 600;
        white-space: nowrap;
        transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
        width: 0;
    }

    .bench-corpus-seg--tp { background: var(--accent); color: #fff; }
    .bench-corpus-seg--fn { background: #c8d1e0; color: #0f1f33; }
    .bench-corpus-seg--tn { background: #64748b; color: #fff; }
    .bench-corpus-seg--fp { background: #c8d1e0; color: #0f1f33; }

    .bench-corpus-legend { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 0.6rem; }

    .bench-corpus-key {
        display: flex;
        align-items: center;
        gap: 0.35rem;
        font-size: 0.7rem;
        color: var(--text-soft);
    }

    .bench-corpus-dot { width: 8px; height: 8px; border-radius: 1px; flex-shrink: 0; }

    /* ── Comparison bar chart ── */
    .bench-chart {
        border: 1px solid var(--line);
        padding: 1.2rem 1rem;
        margin-top: 1.2rem;
    }

    .bench-chart-title {
        font-size: 0.68rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.1em;
        color: var(--text-soft);
        margin: 0 0 1rem;
    }

    .bench-chart-group { margin-bottom: 1.2rem; }
    .bench-chart-group:last-of-type { margin-bottom: 0; }

    .bench-chart-label {
        font-size: 0.74rem;
        font-weight: 600;
        color: var(--text-main);
        margin-bottom: 0.4rem;
    }

    .bench-chart-row {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        margin-bottom: 0.25rem;
        position: relative;
    }

    .bench-chart-row:last-child { margin-bottom: 0; }

    .bench-chart-row:hover .bench-chart-fill {
        filter: brightness(1.15);
    }

    .bench-chart-name {
        width: 7.5rem;
        flex-shrink: 0;
        font-size: 0.68rem;
        color: var(--text-soft);
        text-align: right;
    }

    .bench-chart-track {
        flex: 1;
        height: 20px;
        background: var(--bg-alt);
        position: relative;
        overflow: hidden;
        border-radius: 2px;
    }

    .bench-chart-fill {
        height: 100%;
        width: 0;
        transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1), filter 0.2s ease;
    }

    .bench-chart-fill--ours { background: var(--accent); }
    .bench-chart-fill--pypi { background: var(--accent-strong); }
    .bench-chart-fill--gpt4 { background: #64748b; }
    .bench-chart-fill--gpt3 { background: #94a3b8; }
    .bench-chart-fill--static { background: #cbd5e1; }

    .bench-chart-val {
        flex-shrink: 0;
        width: 2.8rem;
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.7rem;
        font-weight: 600;
        color: var(--text-main);
    }

    .bench-chart-legend {
        display: flex;
        flex-wrap: wrap;
        gap: 1rem;
        margin-top: 1rem;
        padding-top: 0.8rem;
        border-top: 1px solid var(--line);
    }

    .bench-chart-key { display: flex; align-items: center; gap: 0.35rem; font-size: 0.7rem; color: var(--text-soft); }

    .bench-chart-swatch { width: 12px; height: 12px; border-radius: 1px; flex-shrink: 0; }

    /* ── Tooltip ── */
    .bench-chart-tooltip {
        position: fixed;
        pointer-events: none;
        background: var(--surface);
        border: 1px solid var(--line);
        border-radius: 3px;
        box-shadow: 0 4px 14px rgba(26,26,26,0.12);
        padding: 0.4rem 0.65rem;
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.72rem;
        font-weight: 600;
        color: var(--text-main);
        z-index: 100;
        opacity: 0;
        transition: opacity 0.15s;
        white-space: nowrap;
    }

    .bench-chart-tooltip.show { opacity: 1; }

    /* ── Live pulse on "Current Results" ── */
    .bench-live-dot {
        display: inline-block;
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: var(--accent);
        margin-right: 0.3rem;
        margin-left: 6px;
        animation: livePulse 2s ease infinite;
        vertical-align: middle;
    }

    @keyframes livePulse {
        0%, 100% { box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0.4); }
        50% { box-shadow: 0 0 0 6px rgba(var(--accent-rgb), 0); }
    }

    /* ── Context (prior work) softening ── */
    .bench-context-note {
        margin: 0 0 1rem;
        max-width: 64ch;
        padding: 0.7rem 0.95rem;
        background: rgba(247, 244, 236, 1);
        border-left: 2px solid rgba(var(--accent-rgb), 0.3);
        font-size: 0.8rem;
        line-height: 1.6;
        color: var(--text-soft);
    }
    .bench-context-note strong { color: var(--text-main); font-weight: 600; }
    .bench-context-note a {
        color: var(--accent-strong);
        text-decoration: underline;
        text-underline-offset: 2px;
    }
    .bench-context-note a:hover { color: var(--text-main); }

    /* ── Closing CTA ── */
    .bench-cta {
        margin-top: 1rem;
        padding: 1.6rem 0;
        display: grid;
        gap: 0.9rem;
    }
    .bench-cta-title {
        margin: 0;
        font-size: clamp(1.1rem, 2vw, 1.35rem);
        line-height: 1.25;
        letter-spacing: -0.01em;
        color: var(--text-main);
    }
    .bench-cta-sub {
        margin: 0;
        font-size: 0.85rem;
        color: var(--text-soft);
        line-height: 1.6;
        max-width: 56ch;
    }
    .bench-cta-actions {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 0.8rem;
    }
    .bench-cta-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0.6rem 1.1rem;
        background: var(--accent);
        color: #fff;
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.78rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        text-decoration: none;
        border: 1px solid rgba(var(--accent-rgb), 0.4);
        border-radius: 3px;
        transition: background 0.15s ease;
    }
    .bench-cta-btn:hover { background: var(--accent-strong); }
    .bench-cta-cmd {
        font-family: 'IBM Plex Mono', monospace;
        font-size: 0.78rem;
        color: var(--text-main);
        background: rgba(247, 244, 236, 0.97);
        border: 1px solid var(--line);
        padding: 0.55rem 2.55rem 0.55rem 0.8rem;
        border-radius: 3px;
        white-space: nowrap;
        overflow-x: auto;
        max-width: 100%;
        position: relative;
        display: inline-block;
    }

    .bench-copy-cmd {
        position: absolute;
        right: 0.45rem;
        top: 50%;
        transform: translateY(-50%);
        background: none;
        border: none;
        color: var(--text-soft);
        cursor: pointer;
        opacity: 0.6;
        transition: all 0.2s;
        padding: 0.35rem;
        border-radius: 4px;
    }

    .bench-copy-cmd:hover {
        background: rgba(var(--accent-rgb), 0.08);
        color: var(--accent);
        opacity: 1;
    }

    /* ── Responsive ── */
    @media (max-width: 820px) {
        /* Default .site-main container is min(1200px, 100% - 3rem) which
           leaves 1.5rem margin each side on mobile. Tighten to 0.75rem
           each side on benchmark so content-dense grids (confusion matrix,
           bar charts, corpus bars) have room to breathe. */
        .site-main { width: min(1200px, calc(100% - 1.5rem)); }
    }
    @media (max-width: 980px) {
        .bench-proof-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    }

    @media (max-width: 760px) {
        .bench-page { gap: 1.9rem; padding-top: 0.25rem; }
        .bench-panel { padding-top: 0.8rem; }
        .bench-hero { padding: 0.5rem 0 1rem; }
        .bench-hero-meta { font-size: 0.66rem; gap: 0.4rem; }
        .bench-proof-grid { grid-template-columns: 1fr; gap: 0.6rem; }
        .bench-cta { padding: 1.2rem 0; }
        .bench-callouts { grid-template-columns: 1fr; }
        .bench-callout { border-right: none; border-bottom: 1px solid var(--line); }
        .bench-callout:last-child { border-bottom: none; }
        .bench-source-grid { grid-template-columns: 1fr; }
        .bench-method-grid { grid-template-columns: 1fr; }
        .bench-source-card { grid-template-columns: 1fr; gap: 0.4rem; padding: 1.2rem 0; }
        .bench-method-card { grid-template-columns: 1fr; gap: 0.4rem; padding: 1.2rem 0; }
        .bench-method-card::before { top: -1.2rem; }
        .bench-confusion { grid-template-columns: 4.6rem 1fr 1fr; }
        .bench-confusion-colhead, .bench-confusion-rowhead { font-size: 0.56rem; padding: 0.4rem 0.35rem; }
        .bench-confusion-cell { padding: 0.65rem 0.55rem; }
        .bench-confusion-label { font-size: 0.74rem; }
        .bench-chart-name { width: 5.5rem; font-size: 0.62rem; }
        .bench-chart-val { width: 2.4rem; font-size: 0.62rem; }
        .bench-corpus-legend { gap: 0.6rem; }

        /* Tabs: stack vertically, hide detail text */
        .bench-tabs { display: flex; flex-direction: column; width: 100%; }
        .bench-tab { border-right: none; border-bottom: 1px solid var(--line); min-height: 44px; justify-content: center; }
        .bench-tab:last-child { border-bottom: none; }

        /* Table: card layout on mobile */
        .bench-table { min-width: 0; }
        .bench-table thead { display: none; }
        .bench-table tbody tr { display: block; border-bottom: 1px solid var(--line); padding: 0.7rem 0; }
        .bench-table tbody tr:last-child { border-bottom: none; }
        .bench-table tbody td { display: block; padding: 0.2rem 0.8rem; border: none; text-align: left; font-weight: 600; }
        .bench-table tbody td:first-child { font-size: 0.82rem; color: var(--accent-strong); margin-bottom: 0.2rem; font-weight: 700; }
        .bench-table tbody td:not(:first-child)::before {
            content: attr(data-label);
            display: inline-block;
            font-size: 0.62rem;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 0.08em;
            color: var(--text-soft);
            margin-right: 0.5rem;
            min-width: 6.5rem;
        }
        .bench-table .bench-ours { background: none; }
    }

    @media (max-width: 480px) {
        .bench-page { gap: 1.1rem; padding-bottom: 1.4rem; }
        .bench-panel { padding-top: 0.6rem; }
        .bench-hero { padding: 0.35rem 0 0.9rem; }
        .bench-title { font-size: clamp(1.8rem, 9vw, 2.5rem); max-width: none; }
        .bench-sub { font-size: 0.9rem; line-height: 1.65; }
        .bench-hero-nav { gap: 0.4rem; }
        .bench-hero-nav a { font-size: 0.62rem; padding: 0.28rem 0.45rem; }
        .bench-proof-grid { grid-template-columns: 1fr; }
        .bench-proof-card { padding: 1rem 0.85rem 0.85rem; }
        .bench-cta-cmd { font-size: 0.7rem; padding: 0.5rem 0.65rem; }
        .bench-cta-btn { width: 100%; }
        /* Confusion matrix: 3-col is too tight — stack as single column
           with clear "Actual x / Predicted y" labels per cell. */
        .bench-confusion {
            grid-template-columns: 1fr;
        }
        .bench-confusion-corner,
        .bench-confusion-colhead,
        .bench-confusion-rowhead { display: none; }
        .bench-confusion-cell {
            border-right: none !important;
            padding: 0.75rem 0.9rem;
        }
        .bench-confusion-cell:not(:last-child) {
            border-bottom: 1px solid var(--line) !important;
        }
        .bench-confusion-cell::before {
            display: block;
            font-family: 'IBM Plex Mono', monospace;
            font-size: 0.56rem; font-weight: 700;
            text-transform: uppercase; letter-spacing: 0.1em;
            color: var(--text-soft);
            margin-bottom: 0.2rem;
        }
        /* Parent has 9 children: corner, 2 colheads, rowhead, TP, FP,
           rowhead, FN, TN — so cells are DOM children 5, 6, 8, 9. */
        .bench-confusion-cell:nth-child(5)::before { content: 'Malicious · predicted malicious'; }
        .bench-confusion-cell:nth-child(6)::before { content: 'Safe · predicted malicious'; }
        .bench-confusion-cell:nth-child(8)::before { content: 'Malicious · predicted safe'; }
        .bench-confusion-cell:nth-child(9)::before { content: 'Safe · predicted safe'; }

        /* Corpus bar: FN slice is 0.1% and invisible — keep the bar but
           tighten labels inside TP/TN so they don't clip. */
        .bench-corpus-seg { font-size: 0.5rem; padding: 0 0.3rem; }
        /* Chart tight-mode */
        .bench-chart { border-radius: 3px; }
        .bench-callouts { grid-template-columns: 1fr; }
        .bench-callout { border-right: none; border-bottom: 1px solid var(--line); }
        .bench-callout:last-child { border-bottom: none; }
        .bench-callout-detail { font-size: 0.72rem; }
        .bench-chart-row { flex-wrap: wrap; }
        .bench-chart-name { width: 100%; text-align: left; margin-bottom: 0.15rem; }
        .bench-corpus-bar { height: 22px; }
        .bench-corpus-seg { font-size: 0.54rem; }
        .bench-corpus-legend { flex-direction: column; gap: 0.3rem; }

        /* Tab detail text: hide on smallest screens */
        .bench-tab .bench-tab-detail { display: none; }

        /* Section sub tighter */
        .bench-section-sub { font-size: 0.8rem; }

        /* PyPI explainer box: tighter padding */
        .bench-pypi-note { padding: 0.8rem !important; }

        /* Comparison chart: tighter */
        .bench-chart { padding: 0.8rem 0.6rem; }
        .bench-chart-title { font-size: 0.62rem; margin-bottom: 0.7rem; }

    }

    @media (prefers-reduced-motion: reduce) {
        .bench-chart-fill { transition: none !important; }
        .bench-corpus-seg { transition: none !important; }
        .bench-live-dot { animation: none !important; }
    }

