Spaces:
Running
Running
| /* css/styles.css — layout + colour tokens. | |
| * | |
| * Contrast targets (WCAG AA, 4.5:1): | |
| * --fg #1a1f2c on --bg #fafbfc → 14.5:1 | |
| * --fg-muted #4a5063 on --bg → 7.4:1 | |
| * --accent #2456c9 on --bg → 6.8:1 | |
| */ | |
| * { box-sizing: border-box; } | |
| :root { | |
| --bg: #fafbfc; | |
| --bg-elev: #ffffff; | |
| --fg: #1a1f2c; | |
| --fg-muted: #4a5063; | |
| --border: #d6dae3; | |
| --accent: #2456c9; | |
| --accent-fg: #ffffff; | |
| --chip-bg: #eef0f5; | |
| --chip-on-bg: #d8e2f7; | |
| --chip-on-fg: #102a66; | |
| --shadow: 0 1px 2px rgba(20, 25, 40, 0.06), 0 4px 12px rgba(20, 25, 40, 0.04); | |
| --radius: 10px; | |
| --radius-sm: 6px; | |
| --gap: 12px; | |
| } | |
| @media (prefers-color-scheme: dark) { | |
| :root { | |
| --bg: #11141b; | |
| --bg-elev: #1a1e28; | |
| --fg: #f0f2f6; | |
| --fg-muted: #b5bcc9; | |
| --border: #2c3140; | |
| --accent: #6f9bff; | |
| --accent-fg: #0b1224; | |
| --chip-bg: #232838; | |
| --chip-on-bg: #2c4a8a; | |
| --chip-on-fg: #e0e9ff; | |
| } | |
| } | |
| html, body { | |
| margin: 0; | |
| padding: 0; | |
| background: var(--bg); | |
| color: var(--fg); | |
| font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; | |
| font-size: 15px; | |
| line-height: 1.45; | |
| -webkit-font-smoothing: antialiased; | |
| } | |
| main { | |
| max-width: 1100px; | |
| margin: 0 auto; | |
| padding: 24px 20px 80px; | |
| } | |
| header { | |
| display: flex; | |
| align-items: baseline; | |
| justify-content: space-between; | |
| gap: var(--gap); | |
| margin-bottom: 18px; | |
| flex-wrap: wrap; | |
| } | |
| header h1 { | |
| margin: 0; | |
| font-size: 22px; | |
| font-weight: 600; | |
| letter-spacing: -0.01em; | |
| } | |
| #engine-label { | |
| font-size: 13px; | |
| color: var(--fg-muted); | |
| } | |
| .search-row { | |
| display: flex; | |
| gap: var(--gap); | |
| margin-bottom: 14px; | |
| flex-wrap: wrap; | |
| } | |
| #query { | |
| flex: 1 1 360px; | |
| min-width: 0; | |
| font: inherit; | |
| padding: 11px 14px; | |
| border: 1px solid var(--border); | |
| background: var(--bg-elev); | |
| color: var(--fg); | |
| border-radius: var(--radius); | |
| box-shadow: var(--shadow); | |
| } | |
| #query:focus { | |
| outline: 2px solid var(--accent); | |
| outline-offset: 1px; | |
| border-color: transparent; | |
| } | |
| #query:disabled { | |
| opacity: 0.6; | |
| cursor: progress; | |
| } | |
| #topk, #model-select { | |
| font: inherit; | |
| padding: 11px 14px; | |
| border: 1px solid var(--border); | |
| background: var(--bg-elev); | |
| color: var(--fg); | |
| border-radius: var(--radius); | |
| cursor: pointer; | |
| } | |
| #topk:focus, #model-select:focus { outline: 2px solid var(--accent); outline-offset: 1px; } | |
| #model-select { flex: 1 1 260px; min-width: 0; } | |
| #model-select option:disabled { color: var(--fg-muted); } | |
| #quality-panel { | |
| background: var(--bg-elev); | |
| border: 1px solid var(--border); | |
| border-radius: var(--radius); | |
| margin-bottom: 16px; | |
| box-shadow: var(--shadow); | |
| } | |
| #quality-panel > summary { | |
| cursor: pointer; | |
| padding: 12px 16px; | |
| font-weight: 600; | |
| font-size: 14px; | |
| user-select: none; | |
| list-style: none; | |
| } | |
| #quality-panel > summary::-webkit-details-marker { display: none; } | |
| #quality-panel > summary::before { | |
| content: "▸ "; | |
| font-size: 11px; | |
| color: var(--fg-muted); | |
| transition: transform 120ms ease; | |
| display: inline-block; | |
| } | |
| #quality-panel[open] > summary::before { transform: rotate(90deg); } | |
| .quality-body { padding: 0 16px 16px; } | |
| #model-blurb { | |
| font-size: 13px; | |
| color: var(--fg-muted); | |
| margin: 0 0 14px; | |
| line-height: 1.55; | |
| } | |
| .quality-grid { | |
| display: grid; | |
| grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); | |
| gap: 10px; | |
| margin-bottom: 14px; | |
| } | |
| .quality-card { | |
| border: 1px solid var(--border); | |
| border-radius: var(--radius-sm); | |
| padding: 10px 12px; | |
| background: var(--bg); | |
| } | |
| .quality-card-label { | |
| font-size: 11px; | |
| text-transform: uppercase; | |
| letter-spacing: 0.04em; | |
| color: var(--fg-muted); | |
| font-weight: 600; | |
| } | |
| .quality-card-value { | |
| font-size: 20px; | |
| font-weight: 600; | |
| font-variant-numeric: tabular-nums; | |
| margin: 2px 0 1px; | |
| color: var(--accent); | |
| } | |
| .quality-card-sub { | |
| font-size: 11px; | |
| color: var(--fg-muted); | |
| line-height: 1.4; | |
| } | |
| .leaderboard-details > summary { | |
| cursor: pointer; | |
| font-size: 12px; | |
| color: var(--fg-muted); | |
| padding: 6px 0; | |
| list-style: none; | |
| user-select: none; | |
| } | |
| .leaderboard-details > summary::-webkit-details-marker { display: none; } | |
| .leaderboard-details > summary::before { | |
| content: "▸ "; | |
| font-size: 10px; | |
| display: inline-block; | |
| transition: transform 120ms ease; | |
| } | |
| .leaderboard-details[open] > summary::before { transform: rotate(90deg); } | |
| table.leaderboard { | |
| width: 100%; | |
| border-collapse: collapse; | |
| font-size: 12px; | |
| margin: 8px 0; | |
| } | |
| table.leaderboard th, table.leaderboard td { | |
| text-align: left; | |
| padding: 6px 8px; | |
| border-bottom: 1px solid var(--border); | |
| font-variant-numeric: tabular-nums; | |
| } | |
| table.leaderboard th { color: var(--fg-muted); font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: 0.03em; } | |
| table.leaderboard td:nth-child(3), table.leaderboard td:nth-child(4), | |
| table.leaderboard th:nth-child(3), table.leaderboard th:nth-child(4) { text-align: right; width: 80px; } | |
| table.leaderboard tr.active { background: var(--chip-on-bg); color: var(--chip-on-fg); font-weight: 500; } | |
| .leaderboard-foot { | |
| font-size: 11px; | |
| color: var(--fg-muted); | |
| margin: 8px 0 0; | |
| } | |
| .leaderboard-foot a { color: var(--accent); text-decoration: none; } | |
| .leaderboard-foot a:hover { text-decoration: underline; } | |
| #libraries { | |
| display: flex; | |
| flex-wrap: wrap; | |
| gap: 8px; | |
| margin-bottom: 14px; | |
| } | |
| .chip { | |
| display: inline-flex; | |
| align-items: center; | |
| gap: 6px; | |
| padding: 6px 11px; | |
| background: var(--chip-bg); | |
| color: var(--fg); | |
| border-radius: 999px; | |
| cursor: pointer; | |
| user-select: none; | |
| font-size: 13px; | |
| border: 1px solid transparent; | |
| transition: background 80ms ease, border-color 80ms ease; | |
| } | |
| .chip:hover { border-color: var(--border); } | |
| .chip input[type="checkbox"] { position: absolute; opacity: 0; pointer-events: none; } | |
| .chip:has(input:checked) { | |
| background: var(--chip-on-bg); | |
| color: var(--chip-on-fg); | |
| } | |
| .chip:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; } | |
| .chip-count { color: var(--fg-muted); font-variant-numeric: tabular-nums; font-size: 12px; } | |
| .chip:has(input:checked) .chip-count { color: inherit; opacity: 0.8; } | |
| .chip-disabled { | |
| opacity: 0.4; | |
| pointer-events: none; | |
| cursor: not-allowed; | |
| } | |
| #status-row { | |
| display: flex; | |
| justify-content: space-between; | |
| align-items: center; | |
| gap: var(--gap); | |
| margin-bottom: 14px; | |
| min-height: 20px; | |
| } | |
| #status { color: var(--fg-muted); font-size: 13px; } | |
| #status.error { color: #c01717; } | |
| @media (prefers-color-scheme: dark) { | |
| #status.error { color: #ff8a8a; } | |
| } | |
| #progress { | |
| width: 100%; | |
| height: 4px; | |
| background: var(--chip-bg); | |
| border-radius: 999px; | |
| overflow: hidden; | |
| margin-bottom: 14px; | |
| } | |
| #progress-bar { | |
| height: 100%; | |
| width: 0%; | |
| background: var(--accent); | |
| transition: width 120ms ease; | |
| } | |
| #empty-state { | |
| padding: 40px 0; | |
| text-align: center; | |
| color: var(--fg-muted); | |
| font-size: 14px; | |
| } | |
| #results { | |
| list-style: none; | |
| margin: 0; | |
| padding: 0; | |
| display: grid; | |
| grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); | |
| gap: 12px; | |
| } | |
| .result { | |
| background: var(--bg-elev); | |
| border: 1px solid var(--border); | |
| border-radius: var(--radius); | |
| padding: 14px; | |
| display: flex; | |
| flex-direction: column; | |
| gap: 10px; | |
| box-shadow: var(--shadow); | |
| transition: transform 80ms ease, border-color 80ms ease; | |
| } | |
| .result:focus, .result:hover { | |
| border-color: var(--accent); | |
| outline: none; | |
| transform: translateY(-1px); | |
| } | |
| .result-svg { | |
| display: flex; | |
| align-items: center; | |
| justify-content: center; | |
| height: 64px; | |
| color: var(--fg); | |
| } | |
| .result-svg svg { width: 40px; height: 40px; } | |
| .result-name { | |
| font-weight: 500; | |
| font-size: 14px; | |
| word-break: break-word; | |
| } | |
| .result-row { | |
| display: flex; | |
| justify-content: space-between; | |
| font-size: 12px; | |
| color: var(--fg-muted); | |
| font-variant-numeric: tabular-nums; | |
| } | |
| .result-lib { font-weight: 500; } | |
| .result-score { color: var(--accent); } | |
| footer { | |
| margin-top: 60px; | |
| padding-top: 20px; | |
| border-top: 1px solid var(--border); | |
| color: var(--fg-muted); | |
| font-size: 12px; | |
| display: flex; | |
| flex-wrap: wrap; | |
| gap: 12px; | |
| justify-content: space-between; | |
| } | |
| footer a { color: var(--accent); text-decoration: none; } | |
| footer a:hover, footer a:focus { text-decoration: underline; } | |