/* Scoped to Benchmarks; shares the existing MoSE3-derived light/dark tokens. */
#benchmarks .bm-tabs{display:flex;justify-content:center;flex-wrap:wrap;gap:5px;margin:0 auto 24px;padding:5px;width:fit-content;max-width:100%;border:1px solid var(--line);border-radius:11px;background:var(--surface)}
#benchmarks .bm-tab{border:0;border-radius:7px;background:transparent;color:var(--dim);padding:11px 21px;font:500 14px var(--body);cursor:pointer}
#benchmarks .bm-tab[aria-selected=true]{background:var(--bg);color:var(--axis-z);box-shadow:0 1px 6px -3px rgba(0,0,0,.3)}
#benchmarks .bm-toolbar{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:12px 24px;margin-bottom:14px}
#benchmarks .bm-modes{display:flex;flex-wrap:wrap;justify-content:center;gap:3px;padding:3px;border:1px solid var(--line);border-radius:8px}
#benchmarks .bm-modes button{border:0;background:transparent;color:var(--dim);border-radius:5px;padding:8px 13px;font:500 12px var(--mono);cursor:pointer}
#benchmarks .bm-modes button[aria-pressed=true]{color:var(--text);background:var(--surface-2)}
#benchmarks .bm-filter{display:flex;align-items:center;gap:8px;color:var(--dim);font-size:12px}
#benchmarks select{max-width:190px;border:1px solid var(--line);border-radius:7px;background:var(--bg);color:var(--text);padding:8px 28px 8px 10px;font:400 12px var(--body)}
#benchmarks .bm-oracle-control{display:flex;justify-content:center;align-items:center;gap:8px;margin:12px auto;color:var(--dim);font-size:12px;cursor:pointer}
#benchmarks .bm-oracle-control input{accent-color:var(--axis-z)}
#benchmarks [hidden]{display:none!important}
#benchmarks .bm-context{text-align:center;color:var(--text);font-size:14px;margin:14px auto 8px;max-width:850px}
#benchmarks .bm-legend{display:flex;gap:9px 20px;flex-wrap:wrap;justify-content:center;margin:16px 0 20px;font-size:12px;color:var(--dim)}
#benchmarks .bm-legend-item{display:inline-flex;align-items:center;gap:7px}
#benchmarks .bm-legend-item.bm-ours{color:var(--text);font-weight:600}
#benchmarks .bm-swatch{width:12px;height:12px;border-radius:3px;display:inline-block;background:var(--bm-color);flex:none}
#benchmarks .bm-oracle .bm-swatch{background:transparent;border:1.5px dashed var(--bm-color)}
#benchmarks .bm-charts{display:flex;flex-direction:column;gap:16px}
#benchmarks .bm-dataset{background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:16px 18px 10px;min-width:0}
#benchmarks .bm-dataset-heading{display:flex;align-items:baseline;justify-content:space-between;gap:12px;margin-bottom:7px}
#benchmarks .bm-dataset h3{margin:0;text-align:left;font:600 15px/1.4 var(--display)}
#benchmarks .bm-dataset-heading>span{font:400 11px/1.4 var(--mono);color:var(--dim);text-align:right}
#benchmarks .bm-metrics{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:12px}
#benchmarks .bm-metric{margin:0;min-width:0}
#benchmarks .bm-metric figcaption{font:500 12px/1.4 var(--body);color:var(--text);text-align:center;margin:6px 0 0}
#benchmarks .bm-metric figcaption span{color:var(--dim);margin-left:5px}
#benchmarks .bm-chart{width:100%;height:auto;display:block;overflow:visible}
#benchmarks .bm-gridline{stroke:var(--line);stroke-width:1;stroke-dasharray:3 4}
#benchmarks line.bm-baseline{stroke:var(--line);stroke-width:1.2}
#benchmarks .bm-tick{font:400 10px var(--mono);fill:var(--dim)}
#benchmarks .bm-value{font:500 11px var(--mono);fill:var(--text);font-variant-numeric:tabular-nums;opacity:0;transition:opacity .25s ease .35s}
#benchmarks .bm-bar rect{fill:var(--bm-color);transform-box:fill-box;transform-origin:50% 100%;transform:scaleY(0);transition:transform .55s cubic-bezier(.2,.7,.2,1)}
/* Numeric bolding always encodes rank; colors and legend labels identify methods. */
#benchmarks .bm-bar.bm-best .bm-value{font-weight:700}
#benchmarks .bm-block-separator{stroke:var(--dim);stroke-width:1;stroke-dasharray:3 4}
#benchmarks .bm-block-label{font:400 10px var(--body);fill:var(--dim)}
#benchmarks .bm-bar.bm-oracle rect{fill:var(--bg);stroke:var(--bm-color);stroke-dasharray:4 3;stroke-width:1.5}
#benchmarks .bm-grown .bm-bar rect{transform:scaleY(1)}
#benchmarks .bm-grown .bm-value{opacity:1}
#benchmarks .bm-bar:hover rect,#benchmarks .bm-bar:focus rect{opacity:.76}
#benchmarks .bm-bar:focus{outline:none}
#benchmarks .bm-bar:focus .bm-value{text-decoration:underline}
#benchmarks .bm-chart-note,#benchmarks .bm-note{font-size:12px;line-height:1.65;color:var(--dim);text-align:center;margin:14px auto 0;max-width:940px}
#benchmarks .bm-note{margin-top:20px}
#benchmarks .bm-source{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:12px 20px;margin-top:16px;font-size:13px}
#benchmarks .bm-source a{color:var(--axis-z);text-underline-offset:3px}
#benchmarks .bm-download{border:1px solid var(--line);border-radius:7px;padding:8px 12px;background:var(--bg);color:var(--dim);font:500 12px var(--body);cursor:pointer}
#benchmarks .bm-tables{margin-top:24px;border-top:1px solid var(--line);padding-top:18px}
#benchmarks .bm-tables summary{cursor:pointer;font:500 14px var(--body);color:var(--text);width:fit-content}
#benchmarks .bm-table-note{font-size:12px;color:var(--dim);line-height:1.65;margin:14px 0 20px}
#benchmarks .bm-table-title{margin:22px 0 6px;font:600 15px var(--display);text-align:left}
#benchmarks .bm-scroll{overflow-x:auto;border:1px solid var(--line);border-radius:9px;background:var(--bg);margin-bottom:18px}
#benchmarks table{border-collapse:separate;border-spacing:0;width:100%;font:400 11px/1.5 var(--mono);white-space:nowrap;font-variant-numeric:tabular-nums}
#benchmarks caption{text-align:left;padding:12px;color:var(--dim);font:400 12px var(--body)}
#benchmarks th,#benchmarks td{padding:9px 11px;text-align:right;border-bottom:1px solid var(--line)}
#benchmarks thead th{font-weight:500;color:var(--dim);background:var(--surface);text-align:center}
#benchmarks thead tr:first-child th{border-bottom:0}
#benchmarks tbody th{font:500 12px var(--body)}
#benchmarks tr{background:var(--bg)}
#benchmarks tr.bm-ours{background:color-mix(in srgb,var(--axis-z) 7%,var(--bg))}
#benchmarks tbody th[scope=row],#benchmarks thead th[rowspan]{position:sticky;left:0;text-align:left;background:inherit;z-index:1}
#benchmarks thead th[rowspan]{background:var(--surface)}
#benchmarks td.bm-best{font-weight:700;color:var(--text);background:color-mix(in srgb,var(--axis-y) 9%,transparent)}
#benchmarks .bm-break th,#benchmarks .bm-break td{border-top:2px solid var(--line)}
#benchmarks tr.bm-oracle th,#benchmarks tr.bm-oracle td{border-top:1px dashed var(--dim);color:var(--dim)}
#benchmarks tbody tr:last-child th,#benchmarks tbody tr:last-child td{border-bottom:0}
#benchmarks .bm-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
#benchmarks :is(button,select,input,summary,a):focus-visible{outline:2px solid var(--axis-z);outline-offset:3px}
@media(max-width:640px){
  #benchmarks .bm-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:100%}
  #benchmarks .bm-tab{padding:11px 8px;font-size:13px}
  #benchmarks .bm-metrics{grid-template-columns:minmax(0,1fr)}
  #benchmarks .bm-dataset{padding:14px 12px 6px}
  #benchmarks .bm-legend{gap:8px 14px;font-size:11.5px}
  #benchmarks .bm-modes button{padding:8px 9px;font-size:11px}
  #benchmarks .bm-context{font-size:13px}
}
@media(prefers-reduced-motion:reduce){
  #benchmarks .bm-bar rect{transform:none;transition:none}
  #benchmarks .bm-value{opacity:1;transition:none}
}
@media print{
  #benchmarks .bm-bar rect{transform:none!important}
  #benchmarks .bm-value{opacity:1!important}
  #benchmarks .bm-dataset{break-inside:avoid}
}
