Spaces:
Running
Running
| /* PRIMO benchmark platform - Gradio stylesheet | |
| Derived from the Scienta design system + primomics.org. | |
| Load with: gr.Blocks(css_paths=["primo.css"]) | |
| Every value here is a design-system token; do not invent new ones. */ | |
| /* ---------- fonts ---------- */ | |
| @font-face { font-family: "Funnel Display"; font-weight: 500 700; font-display: swap; src: url("/gradio_api/file=fonts/funnel-display.woff2") format("woff2"); } | |
| @font-face { font-family: "Funnel Sans"; font-weight: 400 700; font-display: swap; src: url("/gradio_api/file=fonts/funnel-sans.woff2") format("woff2"); } | |
| @font-face { font-family: "DM Mono"; font-weight: 400; font-display: swap; src: url("/gradio_api/file=fonts/dm-mono-regular.woff2") format("woff2"); } | |
| /* ---------- tokens ---------- */ | |
| :root { | |
| --marine-50: #e5e9fc; --marine-100: #bcc3ea; --marine-200: #929ed8; | |
| --marine-400: #3f53b5; --marine-500: #162da3; --marine-700: #0d1b62; | |
| --coral-400: #fd9878; --coral-500: #fd7e56; --coral-600: #d36745; | |
| --n-100: #f5f5f5; --n-200: #e5e5e5; --n-300: #d4d4d4; | |
| --n-400: #a3a3a3; --n-500: #737373; --n-600: #525252; --n-900: #171717; | |
| --border: var(--n-200); | |
| --text-body: var(--n-900); | |
| --text-secondary: var(--n-600); | |
| --text-muted: var(--n-500); | |
| --surface-selected: var(--marine-50); | |
| --sidebar: radial-gradient(ellipse 100% 5rem at 50% 100%, rgb(253 126 86 / .35), transparent 70%), | |
| linear-gradient(45deg, var(--marine-500), var(--marine-700)); | |
| --sidebar-fg: rgb(255 255 255 / .9); | |
| --sidebar-sub-fg: rgb(255 255 255 / .6); | |
| --sidebar-accent: linear-gradient(90deg, rgb(253 152 120 / .15), rgb(63 83 181 / .2)); | |
| --sidebar-highlight: rgb(63 83 181 / .2); | |
| --sidebar-border: var(--marine-700); | |
| --font-sans: "Funnel Sans", sans-serif; | |
| --font-title: "Funnel Display", sans-serif; | |
| --font-mono: "DM Mono", ui-monospace, monospace; | |
| --radius-sm: 4px; --radius-md: 6px; --radius-lg: 8px; --radius-xl: 12px; | |
| --shadow-xs: 0 1px 2px rgb(9 18 65 / .05); | |
| --shadow-sm: 0 1px 3px rgb(9 18 65 / .1), 0 1px 2px -1px rgb(9 18 65 / .1); | |
| } | |
| /* ---------- Gradio reset: get its chrome out of the way ---------- */ | |
| .gradio-container { max-width: 100% ; padding: 0 ; font-family: var(--font-sans) ; } | |
| .gradio-container .prose :where(h1, h2, h3) { font-family: var(--font-title); } | |
| footer { display: none ; } | |
| /* the rail replaces the tab bar (Gradio renamed .tab-nav -> .tab-wrapper) */ | |
| #pm-pages > .tab-nav, #pm-pages > .tab-wrapper { display: none ; } | |
| #pm-pages > .tabitem { border: 0 ; padding: 0 ; } | |
| #pm-shell { flex-wrap: nowrap ; gap: 0 ; align-items: stretch ; } | |
| /* ---------- rail ---------- */ | |
| #pm-rail { | |
| width: 272px ; min-width: 272px ; flex: 0 0 272px ; | |
| background: var(--sidebar); color: var(--sidebar-fg); padding: 8px; gap: 0 ; | |
| } | |
| .pm-brand { display: flex; align-items: center; gap: 8px; height: 3rem; padding: 8px; border-radius: var(--radius-md); color: #fff; text-decoration: none; } | |
| .pm-brand:hover { background: var(--sidebar-highlight); color: #fff ; } | |
| .pm-brand img { height: 24px; width: auto; padding: 2px; background: #fff; border-radius: var(--radius-sm); object-fit: contain; } | |
| .pm-brand b { font: 700 1.125rem/1 var(--font-title); letter-spacing: -.04em; } | |
| .pm-brand span { font: 500 1.25rem/0 var(--font-title); letter-spacing: -.04em; color: var(--sidebar-sub-fg); } | |
| .pm-rail-group { padding: 16px 16px 0; } | |
| .pm-rail-label { display: flex; align-items: center; height: 2.5rem; padding: 8px; | |
| font: 400 10px/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--sidebar-sub-fg); } | |
| /* board links are Gradio buttons, restyled */ | |
| #pm-rail .pm-link { | |
| position: relative; display: flex ; align-items: center; justify-content: space-between; gap: 8px; | |
| width: 100%; height: 2rem; min-height: 2rem; padding: 0 8px; margin: 0 0 2px; | |
| border: 0 ; border-radius: var(--radius-md); background: transparent ; box-shadow: none ; | |
| font: 400 14px/1 var(--font-sans); color: var(--sidebar-sub-fg) ; text-align: left; | |
| transition: color .15s ease, background .15s ease; | |
| } | |
| #pm-rail .pm-link:hover { background: var(--sidebar-highlight) ; color: #fff ; } | |
| #pm-rail .pm-link::before { | |
| content: ""; position: absolute; top: 50%; left: 0; height: 50%; width: 2px; | |
| translate: 0 -50%; background: var(--coral-500); opacity: 0; transition: opacity .15s ease; | |
| } | |
| #pm-rail .pm-link.pm-active { background: var(--sidebar-accent) ; color: #fff ; font-weight: 500; } | |
| #pm-rail .pm-link.pm-active::before { opacity: 1; } | |
| #pm-rail .pm-link--open { opacity: .58; } | |
| #pm-rail .pm-link--open:hover { opacity: 1; } | |
| .pm-link .pm-count { font: 400 12px/1 var(--font-mono); opacity: .75; } | |
| .pm-link .pm-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } | |
| /* Gradio colours <span>/<b> explicitly, which beats inheriting the link colour; | |
| force the rail's inner text to take the link/brand colour instead. */ | |
| #pm-rail .pm-link .pm-label, #pm-rail .pm-link .pm-count, #pm-rail .pm-brand b { color: inherit ; } | |
| .pm-rail-foot { margin-top: auto; padding: 16px; border-top: 1px solid var(--sidebar-border); } | |
| #pm-rail .pm-foot-link { | |
| display: flex ; align-items: center; width: 100%; height: 2.5rem; padding: 8px; margin: 0 0 2px; | |
| border: 0 ; border-radius: var(--radius-md); background: transparent ; box-shadow: none ; | |
| font: 500 14px/1 var(--font-sans); color: var(--sidebar-fg) ; text-align: left; | |
| } | |
| #pm-rail .pm-foot-link:hover { background: var(--sidebar-highlight) ; color: #fff ; } | |
| #pm-rail .pm-foot-link.pm-active { background: var(--sidebar-accent) ; color: #fff ; } | |
| /* ---------- page shell ---------- */ | |
| #pm-main { min-width: 0; background: #fff; } | |
| .pm-head { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 20px 32px; border-bottom: 1px solid var(--border); } | |
| .pm-head h1 { margin: 0; font: 600 1.5rem/1.1 var(--font-title); letter-spacing: -.04em; color: var(--marine-700); } | |
| .pm-head p { margin: 6px 0 0; font-size: 14px; color: var(--text-secondary); } | |
| #pm-main .pm-body { padding: 24px 32px 32px ; } | |
| .pm-prose { max-width: 860px; } | |
| .pm-over { margin: 0; font: 400 10px/1.4 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted); } | |
| .pm-over--marine { color: var(--marine-500); } | |
| h2.pm-h2 { margin: 0; font: 600 1.125rem/1.2 var(--font-title); letter-spacing: -.03em; color: var(--marine-700); } | |
| .pm-group { margin-bottom: 28px; } | |
| .pm-group-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 12px; } | |
| .pm-group-head .pm-note { margin: 0; font-size: 12px; color: var(--text-muted); } | |
| .pm-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; } | |
| /* ---------- cards ---------- */ | |
| .pm-card { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius-xl); | |
| background: #fff; padding: 20px; box-shadow: var(--shadow-xs); } | |
| .pm-card--live { border-left: 4px solid var(--marine-500); } | |
| .pm-card--open { border-style: dashed; border-color: var(--marine-200); box-shadow: none; opacity: .58; } | |
| .pm-card--open:hover { opacity: 1; } | |
| .pm-card--note { background: var(--surface-selected); border-color: var(--marine-100); } | |
| .pm-card h3 { margin: 0; font: 600 1.25rem/1.1 var(--font-title); letter-spacing: -.04em; color: var(--marine-700); } | |
| .pm-card--open h3 { color: var(--text-secondary); } | |
| .pm-card .pm-meta { margin: 10px 0 0; font: 400 12px/1.5 var(--font-mono); color: var(--text-muted); } | |
| .pm-card .pm-asks { margin: 8px 0 0; font-size: 14px; color: var(--text-secondary); } | |
| .pm-card .pm-leader { margin: 6px 0 0; font-size: 14px; color: var(--text-body); } | |
| .pm-card .pm-leader--2 { margin-top: 2px; color: var(--text-muted); } | |
| .pm-card p.pm-cta { margin: 14px 0 0; font-size: 14px; } | |
| a { color: var(--marine-500); text-decoration: none; } | |
| a:hover { color: var(--marine-700); } | |
| /* ---------- badges ---------- */ | |
| .pm-badge { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border: 1px solid transparent; | |
| border-radius: var(--radius-md); font: 400 12px/1 var(--font-sans); white-space: nowrap; } | |
| .pm-badge--marine { background: var(--marine-50); color: var(--marine-500); } | |
| .pm-badge--quiet { background: var(--n-100); border-color: var(--border); color: var(--text-secondary); } | |
| .pm-link .pm-badge--quiet { background: transparent; border-color: var(--sidebar-border); color: var(--sidebar-sub-fg); } | |
| /* ---------- buttons (page actions) ---------- */ | |
| #pm-main .pm-btn { display: inline-flex ; align-items: center; justify-content: center; height: 2rem; min-height: 2rem; | |
| padding: 0 12px; border-radius: var(--radius-md); font: 500 12px/1 var(--font-sans); border: 1px solid transparent; box-shadow: none; } | |
| #pm-main .pm-btn--primary { background: var(--marine-400) ; color: #fff ; } | |
| #pm-main .pm-btn--primary:hover { background: var(--marine-500) ; } | |
| #pm-main .pm-btn--outline { background: #fff ; border-color: var(--border) ; color: var(--marine-700) ; box-shadow: var(--shadow-xs); } | |
| #pm-main .pm-btn--outline:hover { background: var(--n-100) ; } | |
| #pm-main .pm-btn--block { width: 100%; height: 2.25rem; font-size: 14px; } | |
| /* ---------- toggle group (Ranked / Per task) ---------- */ | |
| #pm-main .pm-toggle { display: inline-flex; gap: 2px; padding: 3px; border-radius: var(--radius-lg); background: var(--n-100); margin-bottom: 16px; } | |
| #pm-main .pm-toggle button { height: 1.75rem; min-height: 1.75rem; padding: 0 14px; border: 0 ; border-radius: var(--radius-md); | |
| background: transparent ; box-shadow: none ; font: 400 14px/1 var(--font-sans); color: var(--text-muted) ; } | |
| #pm-main .pm-toggle button.pm-active { background: #fff ; color: var(--marine-400) ; box-shadow: var(--shadow-sm) ; font-weight: 500; } | |
| /* ---------- tables ---------- */ | |
| .pm-table-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-md); } | |
| .pm-table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 14px; } | |
| .pm-table thead { background: var(--n-100); } | |
| .pm-table thead tr, .pm-table tbody tr { border-bottom: 1px solid var(--border); } | |
| .pm-table tbody tr:last-child { border-bottom: 0; } | |
| .pm-table th { height: 2.5rem; padding: 0 8px; text-align: left; vertical-align: middle; | |
| font: 400 10px/1.3 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted); } | |
| .pm-table th.pm-sort { cursor: pointer; user-select: none; } | |
| .pm-table th.pm-sort:hover, .pm-table th.pm-sort:focus-visible { background: var(--marine-50); color: var(--marine-500); outline: 0; } | |
| .pm-table th.pm-sort::after { content: "↕"; margin-left: 5px; color: var(--n-400); } | |
| .pm-table th.pm-sort[data-sort-direction="asc"]::after { content: "↑"; color: var(--marine-500); } | |
| .pm-table th.pm-sort[data-sort-direction="desc"]::after { content: "↓"; color: var(--marine-500); } | |
| .pm-table td { padding: 8px; vertical-align: middle; color: var(--text-secondary); } | |
| .pm-table th:first-child, .pm-table td:first-child { padding-left: 16px; } | |
| .pm-table th:last-child, .pm-table td:last-child { padding-right: 16px; } | |
| .pm-table td.pm-strong { color: var(--text-body); } | |
| .pm-table td.pm-name { font-weight: 500; color: var(--marine-700); } | |
| .pm-table .pm-num { text-align: right; font-family: var(--font-mono); font-size: 13px; color: var(--text-body); } | |
| .pm-table .pm-num--dim { color: var(--n-400); } | |
| .pm-table .pm-score { text-align: right; font-family: var(--font-mono); font-size: .9375rem; color: var(--marine-700); } | |
| .pm-table .pm-metric { font-family: var(--font-mono); font-size: 12px; color: var(--marine-700); } | |
| .pm-table .pm-groupline td { padding-top: 22px; border-bottom: 0; | |
| font: 400 10px/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--marine-700); } | |
| .pm-table .pm-invite td { text-align: center; color: var(--text-muted); } | |
| /* definition table (Method) */ | |
| .pm-table--def td:first-child { width: 190px; background: var(--n-100); | |
| font: 400 11px/1.4 var(--font-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--text-secondary); } | |
| .pm-caption { margin: 14px 0 0; font-size: 14px; color: var(--text-muted); } | |
| /* ---------- submit steps + code ---------- */ | |
| .pm-step { display: flex; gap: 16px; } | |
| .pm-step-n { flex: none; width: 26px; height: 26px; display: grid; place-content: center; | |
| border-radius: var(--radius-md); background: var(--marine-500); color: #fff; font: 400 12px/1 var(--font-mono); } | |
| .pm-step p { max-width: 60ch; margin: 8px 0 0; font-size: 14px; line-height: 1.6; color: var(--text-secondary); } | |
| .pm-code { margin: 14px 0 0; padding: 16px 18px; border-radius: var(--radius-md); | |
| background: var(--n-900); color: var(--n-100); font: 400 12px/1.7 var(--font-mono); overflow-x: auto; } | |
| code, .pm-inline-code { font-family: var(--font-mono); font-size: .95em; } | |
| /* ---------- submit form (Gradio inputs) ---------- */ | |
| #pm-form { display: flex; flex-direction: column; gap: 14px; } | |
| #pm-form .block { padding: 12px ; border: 0 ; background: transparent ; } | |
| #pm-form label > span { font-size: 13px ; font-weight: 400 ; color: var(--text-secondary) ; } | |
| #pm-form input[type="text"], #pm-form textarea { | |
| border: 1px solid var(--border) ; border-radius: var(--radius-md) ; | |
| box-shadow: var(--shadow-xs) ; font-family: var(--font-sans) ; font-size: 14px ; } | |
| #pm-form input[type="text"]:focus, #pm-form textarea:focus { outline: 3px solid rgb(63 83 181 / .5); outline-offset: 0; } | |
| #pm-form .pm-hint { margin: 6px 0 0; font-size: 12px; color: var(--text-muted); } | |
| #pm-form .upload-container, #pm-form .file-preview { border: 1px dashed var(--marine-200) ; | |
| border-radius: var(--radius-md) ; background: #fff ; } | |
| /* ---------- routes (Contribute) ---------- */ | |
| .pm-route { display: block; padding: 20px; margin-bottom: 12px; border: 1px solid var(--border); | |
| border-radius: var(--radius-xl); box-shadow: var(--shadow-xs); text-decoration: none; transition: border-color .15s ease, box-shadow .15s ease; } | |
| .pm-route:hover { border-color: var(--marine-400); box-shadow: var(--shadow-sm); } | |
| .pm-route-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; } | |
| .pm-route-cta { font: 400 12px/1 var(--font-mono); color: var(--coral-600); white-space: nowrap; } | |
| .pm-route p { max-width: 70ch; margin: 8px 0 0; font-size: 14px; line-height: 1.6; color: var(--text-secondary); } | |
| .pm-logos { display: flex; flex-wrap: wrap; gap: 10px; } | |
| .pm-logo { height: 64px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; | |
| padding: 0 26px; border: 1px solid var(--border); border-radius: var(--radius-lg); } | |
| .pm-logo img { max-width: 132px; max-height: 22px; object-fit: contain; } | |
| .pm-logo--hf img { max-height: 35px; } | |
| .pm-logo--open { border-style: dashed; border-color: var(--marine-200); } | |
| /* ---------- rail inner wrapper (keeps the foot links at the bottom) ---------- */ | |
| #pm-rail .pm-rail-inner { display: flex; flex-direction: column; min-height: 100%; } | |
| .pm-leader .pm-num--dim { font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); } | |
| /* ---------- responsive: rail collapses under 900px ---------- */ | |
| @media (max-width: 900px) { | |
| #pm-shell { flex-wrap: wrap ; } | |
| #pm-rail { width: 100% ; min-width: 0 ; flex: 1 1 100% ; } | |
| .pm-grid { grid-template-columns: 1fr 1fr; } | |
| .pm-head { flex-direction: column; align-items: flex-start; } | |
| } | |