Jonna Marie Matthiesen
Extract embed SVG generator into embed.js and add version tracking
5969585
/* ── Page Layout ─────────────────────────────────────── */
.page {
position: relative;
z-index: 1;
display: flex;
flex-direction: row;
min-height: 100vh;
max-width: 1640px;
margin: 0 auto;
}
/* ── Sidebar ─────────────────────────────────────────── */
.sidebar {
width: 280px;
max-width: 300px;
flex-shrink: 0;
padding: var(--space-xl) 0;
position: sticky;
top: 0;
height: 100vh;
overflow-y: auto;
}
.sidebar-logo {
display: block;
padding: 0 var(--space-md) var(--space-2xl);
}
.sidebar-nav {
display: flex;
flex-direction: column;
}
.sidebar-item {
display: block;
padding: var(--space-sm) var(--space-md);
font-size: var(--text-lg);
font-weight: 400;
color: var(--text-dim);
text-decoration: none;
cursor: pointer;
border-left: 2px solid transparent;
transition: color 0.15s, background 0.15s, border-color 0.15s;
}
.sidebar-item:hover {
color: var(--text-muted);
}
.sidebar-item.active {
color: var(--teal);
font-weight: 600;
}
.sidebar-variant {
display: block;
padding: var(--space-sm) var(--space-md) var(--space-sm) var(--space-xl);
font-size: var(--text-md);
font-weight: 400;
color: var(--text-dim);
cursor: pointer;
border-left: 2px solid transparent;
transition: color 0.15s, background 0.15s;
}
.sidebar-variant:hover {
color: var(--text-muted);
}
.sidebar-variant.active {
color: var(--teal);
font-weight: 600;
}
/* ── Main Column ─────────────────────────────────────── */
.main {
flex: 1;
min-width: 0;
}
.main-inner {
width: 100%;
padding: 0 var(--space-xl) var(--space-xl);
}
/* ── Hero ────────────────────────────────────────────── */
.hero {
position: relative;
padding: var(--space-xl) 0;
}
.hero-badge {
display: inline-block;
padding: 1px;
border-radius: 999px;
background: linear-gradient(90deg, var(--teal), var(--blue));
margin-bottom: var(--space-md);
}
.hero-badge span {
display: inline-block;
padding: var(--space-sm) var(--space-md);
border-radius: 999px;
background: var(--bg-opaque);
color: var(--teal);
font-size: var(--text-md);
font-weight: 600;
letter-spacing: 0.03em;
text-transform: uppercase;
}
.hero h1 {
font-size: clamp(1.8rem, 3.5vw, 3.0rem);
font-weight: 700;
margin-bottom: var(--space-sm);
letter-spacing: -0.02em;
}
.hero .accent {
color: var(--teal);
}
.hero-sub {
color: var(--text-muted);
font-size: var(--text-md);
line-height: 1.6;
}
/* ── Filters ─────────────────────────────────────────── */
.filters-bar {
display: flex;
flex-wrap: wrap;
gap: var(--space-md);
padding: var(--space-md) 0 var(--space-2xl);
top: 0;
z-index: 10;
}
.filter-group label {
display: block;
font-size: var(--text-sm);
font-weight: 600;
letter-spacing: 0.08em;
color: var(--text-dim);
margin-bottom: var(--space-xs);
}
.btn-group {
display: flex;
}
.btn {
background: transparent;
border: 1px solid var(--border);
color: var(--text-muted);
font-size: var(--text-md);
font-weight: 400;
padding: var(--space-sm) var(--space-md);
cursor: pointer;
transition: all 0.15s;
}
.btn:first-child {
border-radius: 6px 0 0 6px;
}
.btn:last-child {
border-radius: 0 6px 6px 0;
}
.btn:not(:first-child) {
margin-left: -1px;
}
.btn:hover {
color: var(--text);
background: var(--btn-hover-bg);
}
.btn.active {
background: var(--btn-active-bg);
color: var(--teal);
border-color: var(--btn-active-border);
font-weight: 600;
z-index: 1;
position: relative;
}
/* ── Chart ───────────────────────────────────────────── */
.chart-header {
display: flex;
flex-wrap: wrap;
align-items: center;
justify-content: space-between;
gap: var(--space-sm) var(--space-md);
margin-bottom: var(--space-xs);
}
.chart-header-left {
display: flex;
align-items: baseline;
gap: var(--space-md);
}
.chart-header-right {
display: flex;
align-items: center;
gap: var(--space-md);
margin-left: auto;
}
.chart-header .filter-group {
margin: 0;
}
.chart-header .filter-group label {
display: none;
}
.chart-header .btn,
.demo-device-selector .btn {
border: 0;
background: transparent;
}
.chart-header .btn:hover,
.demo-device-selector .btn:hover {
color: var(--text);
background: transparent;
}
.chart-header .btn.active,
.demo-device-selector .btn.active {
background: transparent;
border-color: var(--btn-active-border);
}
.chart-block {
margin: var(--space-lg) 0;
}
.chart-heading {
font-size: var(--text-lg);
font-weight: 600;
color: var(--text);
margin-bottom: 0;
}
.chart-subtitle {
font-size: var(--text-md);
color: var(--text-muted);
margin-bottom: 0;
}
.chart-wrap {
height: 340px;
}
/* ── Tables ──────────────────────────────────────────── */
.table-card {
margin: var(--space-lg) 0;
}
.table-card h3 {
font-size: var(--text-md);
font-weight: 600;
color: var(--text);
margin-bottom: var(--space-sm);
padding-bottom: var(--space-sm);
border-bottom: 1px solid var(--border);
}
.table-scroll {
overflow-x: auto;
scrollbar-color: var(--text-dim) var(--border);
scrollbar-width: thin;
}
.table-scroll::-webkit-scrollbar {
height: 8px;
}
.table-scroll::-webkit-scrollbar-track {
background: var(--border);
border-radius: 4px;
}
.table-scroll::-webkit-scrollbar-thumb {
background: var(--text-dim);
border-radius: 4px;
}
.table-scroll::-webkit-scrollbar-thumb:hover {
background: var(--text-muted);
}
table {
width: 100%;
border-collapse: collapse;
font-size: var(--text-md);
}
thead th {
text-align: left;
font-weight: 600;
font-size: var(--text-sm);
letter-spacing: 0.05em;
color: var(--text-dim);
padding: var(--space-sm) var(--space-ms);
border-bottom: 1px solid var(--border);
white-space: nowrap;
}
tbody td {
padding: var(--space-sm) var(--space-ms);
border-bottom: 1px solid var(--row-border);
white-space: nowrap;
color: var(--text-muted);
}
th.metric-cell,
td.metric-cell {
text-align: right;
}
tbody tr:last-child td {
border-bottom: 1px solid var(--border);
}
tbody tr:hover {
background: var(--row-hover-bg);
}
.model-cell {
display: flex;
align-items: center;
gap: var(--space-sm);
font-weight: 500;
color: var(--text);
}
.model-cell a {
color: var(--teal);
text-decoration: none;
transition: color 0.15s;
}
.model-cell a:hover {
text-decoration: underline;
}
.model-dot {
width: 8px;
height: 8px;
border-radius: 50%;
flex-shrink: 0;
}
th.first-metric, td.first-metric {
padding-left: var(--space-xl);
}
.oom {
color: var(--red);
font-weight: 600;
}
tbody tr.row-group-break td {
border-top: 2px solid var(--border);
}
/* ── Sticky first column in scrollable tables ─────────── */
.table-split {
display: flex;
}
.table-split-fixed table,
.table-split-scroll table {
width: 100%;
}
.table-split-fixed {
flex-shrink: 0;
}
.table-split-scroll {
overflow-x: auto;
flex: 1;
min-width: 0;
scrollbar-color: var(--text-dim) var(--border);
scrollbar-width: thin;
}
.table-scroll-mobile {
display: none;
}
#accuracy-section:empty {
margin-bottom: 0;
}
#accuracy-section {
margin-bottom: var(--space-xl);
}
.acc-title-link {
color: inherit;
text-decoration: none;
}
.acc-title-link:hover {
text-decoration: underline;
color: var(--accent);
}
.legend-section {
margin: var(--space-xl) 0;
padding-top: var(--space-lg);
}
.legend-grid {
display: grid;
grid-template-columns: 1fr;
gap: var(--space-xs);
font-size: var(--text-sm);
color: var(--text-dim);
}
.legend-grid strong {
color: var(--text-muted);
font-weight: 500;
}
.experiment-setup {
margin-top: var(--space-md);
font-size: var(--text-md);
color: var(--text-dim);
font-style: italic;
line-height: 1.6;
}
.experiment-setup p {
margin-bottom: var(--space-xs);
}
/* ── Footer ──────────────────────────────────────────── */
.footer {
padding: var(--space-xl) 0;
margin-top: var(--space-xl);
}
.footer-inner {
max-width: 1640px;
margin: 0 auto;
padding: 0 var(--space-xl);
}
.footer-grid {
display: flex;
gap: var(--space-2xl);
flex-wrap: wrap;
}
.footer-col {
font-size: var(--text-md);
color: var(--text-dim);
line-height: 1.7;
}
.footer-col p {
margin: 0;
}
.footer-col-title {
font-size: var(--text-sm);
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.08em;
color: var(--text);
}
.footer-logo-img {
display: block;
margin-bottom: var(--space-sm);
}
.footer-logo {
font-size: var(--text-md);
color: var(--text-muted);
margin-bottom: var(--space-md);
}
.footer-logo a {
color: var(--text-muted);
text-decoration: none;
}
.footer-logo a:hover {
text-decoration: underline;
}
.footer-social {
display: flex;
gap: var(--space-md);
}
.footer-social a {
color: var(--text-dim);
transition: color 0.15s;
display: flex;
align-items: center;
}
.footer-social a:hover {
color: var(--teal);
}
/* ── Embed ──────────────────────────────────────────── */
.embed-btn {
display: inline-flex;
align-items: center;
gap: var(--space-sm);
border: 1px solid var(--border);
border-radius: 6px;
padding: var(--space-sm) var(--space-md);
font-size: var(--text-sm);
color: var(--text-muted);
background: transparent;
cursor: pointer;
transition: all 0.15s;
margin-left: auto;
white-space: nowrap;
}
.embed-btn:hover {
color: var(--teal);
border-color: var(--btn-active-border);
background: var(--btn-active-bg);
}
.embed-overlay {
position: fixed;
inset: 0;
z-index: 1000;
background: rgba(0, 0, 0, 0.7);
display: flex;
align-items: center;
justify-content: center;
opacity: 0;
pointer-events: none;
transition: opacity 0.2s;
backdrop-filter: blur(4px);
}
.embed-overlay.visible {
opacity: 1;
pointer-events: auto;
}
.embed-modal {
background: #0e1a2e;
border: 1px solid rgba(88, 177, 195, 0.2);
border-radius: 12px;
width: 90%;
max-width: 720px;
max-height: 90vh;
overflow-y: auto;
padding: var(--space-xl);
scrollbar-color: var(--text-dim) var(--border);
scrollbar-width: thin;
}
.embed-modal::-webkit-scrollbar {
width: 8px;
}
.embed-modal::-webkit-scrollbar-track {
background: var(--border);
border-radius: 4px;
}
.embed-modal::-webkit-scrollbar-thumb {
background: var(--text-dim);
border-radius: 4px;
}
.embed-modal::-webkit-scrollbar-thumb:hover {
background: var(--text-muted);
}
.embed-modal-header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: var(--space-lg);
}
.embed-modal-header h3 {
font-size: var(--text-lg);
font-weight: 600;
color: var(--text);
}
.embed-close {
background: none;
border: none;
color: var(--text-dim);
font-size: 1.5rem;
cursor: pointer;
padding: var(--space-sm);
line-height: 1;
transition: color 0.15s;
}
.embed-close:hover {
color: var(--text);
}
.embed-preview {
background: #0B1527;
border-radius: 8px;
padding: var(--space-sm);
margin-bottom: var(--space-lg);
overflow: hidden;
}
.embed-preview svg {
width: 100%;
height: auto;
display: block;
}
.embed-status-bar {
margin-bottom: var(--space-md);
}
.embed-status {
font-size: var(--text-sm);
font-weight: 500;
}
.embed-status.checking {
color: var(--text-dim);
}
.embed-status.checking::before {
content: "\25CB ";
}
.embed-status.up-to-date {
display: none;
}
.embed-status.uploading {
color: var(--teal);
}
.embed-status.uploading::before {
content: "\21BB ";
}
.embed-status.uploaded {
color: var(--green);
}
.embed-status.uploaded::before {
content: "\2713 ";
}
.embed-status.needs-token {
color: #ffd166;
}
.embed-status.needs-token::before {
content: "\26A0 ";
}
.embed-status a {
color: var(--teal);
text-decoration: none;
font-weight: 600;
}
.embed-status a:hover {
text-decoration: underline;
}
.embed-status.error {
color: var(--red);
word-break: break-word;
}
.embed-status.error::before {
content: "\2717 ";
}
.embed-actions {
display: flex;
gap: var(--space-md);
margin-bottom: var(--space-lg);
}
.embed-action-btn {
border-radius: 6px !important;
padding: var(--space-sm) var(--space-md);
font-size: var(--text-md);
cursor: pointer;
transition: all 0.15s;
}
.embed-action-btn:first-child {
background: var(--btn-active-bg);
border-color: var(--btn-active-border);
color: var(--teal);
}
.embed-action-btn:first-child:hover {
background: rgba(88, 177, 195, 0.2);
}
.embed-secondary {
opacity: 0.7;
}
.embed-secondary:hover {
opacity: 1;
}
.embed-code-section {
margin-bottom: var(--space-sm);
}
.embed-code-section label {
display: block;
font-size: var(--text-sm);
color: var(--text-dim);
margin-bottom: var(--space-sm);
}
.embed-code {
width: 100%;
background: rgba(0, 0, 0, 0.3);
border: 1px solid var(--border);
border-radius: 6px;
color: var(--teal);
font-family: "SF Mono", "Fira Code", "Consolas", monospace;
font-size: var(--text-sm);
padding: var(--space-md);
resize: vertical;
line-height: 1.5;
scrollbar-color: var(--text-dim) var(--border);
scrollbar-width: thin;
}
.embed-code::-webkit-scrollbar {
width: 8px;
height: 8px;
}
.embed-code::-webkit-scrollbar-track {
background: var(--border);
border-radius: 4px;
}
.embed-code::-webkit-scrollbar-thumb {
background: var(--text-dim);
border-radius: 4px;
}
.embed-code::-webkit-scrollbar-thumb:hover {
background: var(--text-muted);
}
.embed-code:focus {
outline: none;
border-color: var(--btn-active-border);
}
/* ── Responsive ──────────────────────────────────────── */
@media (max-width: 900px) {
.page {
flex-direction: column;
}
.sidebar {
width: 100%;
max-width: none;
height: auto;
position: static;
border-right: none;
border-bottom: 1px solid var(--border);
padding: var(--space-sm) 0;
}
.sidebar-nav {
flex-direction: row;
flex-wrap: wrap;
align-items: center;
padding: 0 var(--space-sm);
}
.sidebar-item {
border-left: none;
border-bottom: 2px solid transparent;
padding: var(--space-sm) var(--space-md);
}
.sidebar-item.active {
border-left-color: transparent;
border-bottom-color: var(--teal);
}
.sidebar-variant {
border-left: none;
border-bottom: 2px solid transparent;
padding: var(--space-sm) var(--space-md);
font-size: var(--text-sm);
}
.sidebar-variant.active {
border-bottom-color: var(--teal);
}
.main-inner {
padding: 0 var(--space-md) var(--space-xl);
}
.table-split {
display: none;
}
.table-scroll-mobile {
display: block;
}
}