/* =====================================================================
   BHESpecs browse page: search, filters, sortable table (cards on phones).
   Used by browse.js. Same dark + orange palette as the spec pages.
   ===================================================================== */
.bhe-browse, .bhe-browse *{box-sizing:border-box;}
.bhe-browse{
  --bg:#0b0d12; --card:#12151c; --card-2:#171b24; --ink:#e9eef4; --muted:#9fb1c4; --label:#c9d6e6;
  --rule:#223044; --accent:#ff9f1a; --accent-soft:rgba(255,159,26,.14); --accent-line:rgba(255,159,26,.55);
  --white:#fff; --on-accent:#1a1205; --link:#ffd28a;
  font-family:ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
  font-size:15px; line-height:1.5; color:var(--ink); background:var(--bg);
  border-radius:16px; container-type:inline-size; text-align:left;
}
.bhe-browse a{color:var(--link);text-decoration:none;}
.bhe-browse a:hover{color:#ffe1b3;}
.bhe-browse :focus-visible{outline:2px solid var(--accent);outline-offset:2px;}
.bhe-browse button{font:inherit;cursor:pointer;}
.bhe-browse input, .bhe-browse select{font:inherit;color:var(--ink);background:var(--bg);border:1px solid var(--rule);border-radius:10px;}

.bhe-b-wrap{max-width:1280px;margin:0 auto;padding:16px 16px 40px;display:flex;flex-direction:column;gap:16px;}

.bhe-b-crumbs{display:flex;flex-wrap:wrap;gap:4px 8px;margin:0;padding:0;list-style:none;font-size:13px;color:var(--muted);}
.bhe-b-crumbs li{margin:0;padding:0;list-style:none;}
.bhe-b-crumbs li + li::before{content:"\203A";margin-right:8px;color:var(--rule);}
.bhe-b-crumbs a{color:var(--muted);}
.bhe-b-crumbs [aria-current]{color:var(--ink);}

.bhe-b-head{display:flex;flex-direction:column;gap:6px;}
.bhe-b-title{margin:0;padding:0;font-size:32px;line-height:1.15;font-weight:800;color:var(--white);}
.bhe-b-lead{margin:0;color:var(--muted);max-width:70ch;}

.bhe-b-search{display:flex;gap:10px;flex-wrap:wrap;}
.bhe-b-search input{flex:1 1 260px;min-width:0;height:48px;padding:0 14px;font-size:16px;background:var(--card);}
.bhe-b-search input::placeholder{color:var(--muted);opacity:.8;}

.bhe-b-chips{display:flex;flex-wrap:wrap;gap:8px;}
.bhe-b-chip{border:1px solid var(--rule);background:var(--card);color:var(--ink);border-radius:999px;padding:7px 12px;font-size:14px;font-weight:600;line-height:1.2;}
.bhe-b-chip span{color:var(--muted);font-weight:400;margin-left:6px;font-variant-numeric:tabular-nums;}
.bhe-b-chip:hover{border-color:var(--accent-line);}
.bhe-b-chip[aria-pressed="true"]{background:var(--accent);border-color:var(--accent);color:var(--on-accent);}
.bhe-b-chip[aria-pressed="true"] span{color:var(--on-accent);}

.bhe-b-body{display:grid;grid-template-columns:260px minmax(0,1fr);gap:20px;align-items:start;}

/* filters */
.bhe-b-filters{background:var(--card);border:1px solid var(--rule);border-radius:14px;padding:4px 16px 16px;}
.bhe-b-filters h2{margin:0;padding:14px 0 10px;font-size:12px;letter-spacing:.05em;text-transform:uppercase;color:var(--muted);font-weight:700;}
.bhe-b-group{border-top:1px solid var(--rule);padding:4px 0 12px;}
.bhe-b-group:first-of-type{border-top:0;}
.bhe-b-group h3{margin:0;padding:10px 0 8px;font-size:14px;font-weight:700;color:var(--white);}
.bhe-b-opts{display:flex;flex-direction:column;gap:2px;max-height:260px;overflow-y:auto;margin:0;padding:0;}
.bhe-b-opt{display:flex;align-items:center;gap:8px;padding:4px 0;font-size:14px;cursor:pointer;color:var(--ink);margin:0;font-weight:400;}
.bhe-b-opt input{width:16px;height:16px;margin:0;accent-color:var(--accent);flex:none;}
.bhe-b-opt span{flex:1;min-width:0;}
.bhe-b-opt em{font-style:normal;color:var(--muted);font-size:13px;font-variant-numeric:tabular-nums;}
.bhe-b-opt.is-zero{opacity:.45;}
.bhe-b-find{width:100%;height:34px;padding:0 10px;font-size:14px;margin-bottom:6px;}
.bhe-b-range{display:grid;grid-template-columns:1fr auto 1fr auto;gap:6px;align-items:center;font-size:13px;color:var(--muted);}
.bhe-b-range input{width:100%;min-width:0;height:34px;padding:0 8px;font-size:14px;}
.bhe-b-clear{margin-top:12px;width:100%;height:38px;border-radius:10px;border:1px solid var(--rule);background:transparent;color:var(--ink);font-weight:700;font-size:14px;}
.bhe-b-clear:hover{border-color:var(--accent-line);}
.bhe-b-toggle{display:none;height:44px;border-radius:10px;border:1px solid var(--rule);background:var(--card);color:var(--ink);font-weight:700;padding:0 14px;}

/* results */
.bhe-b-results{min-width:0;display:flex;flex-direction:column;gap:12px;}
.bhe-b-bar{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px 16px;}
.bhe-b-count{margin:0;color:var(--muted);font-size:14px;}
.bhe-b-count b{color:var(--white);}
.bhe-b-sort{display:none;align-items:center;gap:8px;font-size:14px;color:var(--muted);}
.bhe-b-sort select{height:38px;padding:0 8px;}
.bhe-b-active{display:flex;flex-wrap:wrap;gap:6px;}
.bhe-b-pill{border:1px solid var(--accent-line);background:var(--accent-soft);color:var(--ink);border-radius:999px;padding:4px 10px;font-size:13px;line-height:1.3;}
.bhe-b-pill::after{content:"  \00D7";color:var(--muted);}

.bhe-b-scroll{overflow-x:auto;border:1px solid var(--rule);border-radius:14px;background:var(--card);}
.bhe-browse table.bhe-b-table{table-layout:auto;width:100%;min-width:760px;border-collapse:collapse;margin:0;border:0;font-size:14px;font-variant-numeric:tabular-nums;background:transparent;}
.bhe-b-table th,.bhe-b-table td{padding:10px 12px;border:0;border-bottom:1px solid var(--rule);text-align:left;vertical-align:middle;background:transparent;color:var(--ink);}
.bhe-b-table tbody tr:last-child td{border-bottom:0;}
.bhe-b-table tbody tr:hover td{background:var(--card-2);}
.bhe-b-table thead th{position:sticky;top:0;background:var(--card-2);color:var(--label);font-size:12px;letter-spacing:.04em;text-transform:uppercase;font-weight:700;white-space:nowrap;border-bottom:2px solid var(--accent-line);padding:0;}
.bhe-b-table thead button{display:flex;align-items:center;gap:6px;width:100%;padding:11px 12px;background:none;border:0;color:inherit;font:inherit;letter-spacing:inherit;text-transform:inherit;text-align:left;}
.bhe-b-table thead button:hover{color:var(--white);}
.bhe-b-table thead th[aria-sort="ascending"] button,.bhe-b-table thead th[aria-sort="descending"] button{color:var(--accent);}
.bhe-b-arrow{font-size:10px;opacity:.5;}
.bhe-b-table th[aria-sort] .bhe-b-arrow{opacity:1;}
.bhe-b-table td.num,.bhe-b-table th.num button{text-align:right;justify-content:flex-end;}
.bhe-b-table td.num{white-space:nowrap;}
.bhe-b-table tbody td:first-child{min-width:200px;}   /* the theme sets fixed-width table columns; give the model name room */
.bhe-b-table td.none{color:var(--rule);}
.bhe-b-name{display:flex;align-items:center;gap:10px;min-width:0;}
.bhe-b-name a{font-weight:700;color:var(--white);}
.bhe-b-name a:hover{color:var(--link);}
.bhe-b-name small{display:block;color:var(--muted);font-size:12.5px;font-weight:400;}
.bhe-b-thumb{flex:none;width:44px;height:44px;border-radius:8px;border:1px solid var(--rule);background:var(--bg) center/contain no-repeat;}
.bhe-b-thumb.is-icon{background-size:82%;background-color:var(--card-2);opacity:.6;}
.bhe-b-conv{text-decoration:underline dotted var(--muted);text-underline-offset:3px;cursor:help;}
.bhe-b-tag{display:inline-block;border:1px solid var(--rule);border-radius:999px;padding:1px 8px;font-size:12px;color:var(--muted);}

/* cards (narrow) */
.bhe-b-cards{display:none;flex-direction:column;gap:10px;margin:0;padding:0;list-style:none;}
.bhe-b-card{background:var(--card);border:1px solid var(--rule);border-radius:12px;padding:12px;display:flex;flex-direction:column;gap:10px;list-style:none;margin:0;}
.bhe-b-facts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:0;}
.bhe-b-facts div{min-width:0;}
.bhe-b-facts dt{font-size:11px;letter-spacing:.05em;text-transform:uppercase;color:var(--muted);font-weight:700;margin:0;}
.bhe-b-facts dd{margin:0;font-weight:700;color:var(--white);font-size:14px;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;}

.bhe-b-more{align-self:center;height:44px;padding:0 20px;border-radius:10px;border:1px solid var(--accent-line);background:var(--accent-soft);color:var(--ink);font-weight:700;}
.bhe-b-more:hover{background:var(--accent);color:var(--on-accent);}
.bhe-b-empty{border:1px dashed var(--rule);border-radius:14px;padding:28px 16px;text-align:center;color:var(--muted);}
.bhe-b-empty b{display:block;color:var(--white);font-size:16px;margin-bottom:4px;}
.bhe-b-foot{margin:0;font-size:13px;color:var(--muted);max-width:80ch;}

@container (max-width: 900px){
  .bhe-b-body{grid-template-columns:minmax(0,1fr);}
  .bhe-b-toggle{display:inline-flex;align-items:center;}
  .bhe-b-filters{display:none;}
  .bhe-b-filters.is-open{display:block;}
  .bhe-b-title{font-size:26px;}
}
@container (max-width: 640px){
  .bhe-b-scroll{display:none;}
  .bhe-b-cards{display:flex;}
  .bhe-b-sort{display:flex;}
}

/* plain list shown until the script has loaded */
.bhe-b-plain{columns:3 240px;column-gap:24px;margin:0;padding:0;list-style:none;font-size:14px;}
.bhe-b-plain li{margin:0;padding:3px 0;list-style:none;break-inside:avoid;}
