:root {
    --bg-color: #ffffff;
    --text-primary: #111827;
    --text-body: #374151;
    --text-light: #6b7280;
    --accent-color: #2563eb;
    --accent-hover: #1d4ed8;
    --border-color: #e5e7eb;
    --light-bg: #f9fafb;
    --highlight-bg: #eff6ff;
    --highlight-border: #bfdbfe;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-color);
    color: var(--text-body);
    font-family: 'Lora', serif;
    line-height: 1.7;
    font-size: 18px;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
.btn,
.project-badge,
.footer,
table,
code {
    font-family: 'Inter', sans-serif;
}

h1,
h2,
h3 {
    color: var(--text-primary);
    font-weight: 600;
}

a {
    color: var(--accent-color);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

code {
    background: var(--light-bg);
    border: 1px solid var(--border-color);
    padding: 0.1em 0.4em;
    border-radius: 3px;
    font-size: 0.85em;
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
}

.container {
    max-width: 860px;
    margin: 0 auto;
    padding: 4rem 2rem;
    display: flex;
    flex-direction: column;
    gap: 4rem;
}

/* Hero Section */
.hero {
    text-align: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 3rem;
}

.project-badge {
    display: inline-block;
    background: var(--highlight-bg);
    color: var(--accent-color);
    border: 1px solid var(--highlight-border);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 0.3rem 0.9rem;
    margin-bottom: 1.25rem;
}

.hero h1 {
    font-size: 2.1rem;
    line-height: 1.3;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

/* Authors */
.authors {
    margin-bottom: 2rem;
}

.author-list {
    font-family: 'Inter', sans-serif;
    font-size: 1.05rem;
    color: var(--text-primary);
    margin-bottom: 0.35rem;
}

.author-list .author {
    font-weight: 600;
}

.author-list .author sup {
    font-weight: 400;
    color: var(--text-light);
}

.author-list .author-tba {
    color: var(--text-light);
    font-weight: 400;
    font-style: italic;
}

.affiliations {
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Action Buttons */
.action-buttons {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-body);
    background: #ffffff;
    border: 1px solid #d1d5db;
    transition: all 0.2s;
}

.btn:hover {
    background: var(--light-bg);
    border-color: #9ca3af;
    text-decoration: none;
}

.btn-primary {
    background: var(--text-primary);
    color: #ffffff;
    border-color: var(--text-primary);
}

.btn-primary:hover {
    background: #000000;
    border-color: #000000;
    color: #ffffff;
}

/* Disabled / not-yet-public button */
.btn-disabled {
    background: var(--light-bg);
    color: var(--text-light);
    border: 1px dashed #cbd5e1;
    cursor: not-allowed;
}

.btn-disabled:hover {
    background: var(--light-bg);
    border-color: #cbd5e1;
}

/* Availability note beside the action buttons */
.availability-note {
    margin-top: 1rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    color: var(--text-light);
}

.icon {
    display: inline-block;
    vertical-align: middle;
    flex-shrink: 0;
}

/* Content Sections */
.section h2 {
    font-size: 1.45rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.section h3 {
    font-size: 1.1rem;
    margin-top: 1.75rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.content p,
.results-intro {
    margin-bottom: 1.25rem;
    text-align: justify;
}

.content p:last-child {
    margin-bottom: 0;
}

/* Methodology Figure */
.figure-container {
    margin: 1.5rem 0 1rem;
}

.caption {
    font-size: 0.88rem;
    color: var(--text-light);
    margin-top: 1rem;
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
}

/* Results Tables */
.table-wrapper {
    overflow-x: auto;
    margin-top: 0.75rem;
    border-radius: 6px;
    border: 1px solid var(--border-color);
}

.results-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
    font-family: 'Inter', sans-serif;
}

.results-table thead tr {
    background: var(--light-bg);
    border-bottom: 2px solid var(--border-color);
}

.results-table th {
    padding: 0.7rem 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.85rem;
    letter-spacing: 0.02em;
}

.results-table td {
    padding: 0.65rem 1rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-body);
}

.results-table tbody tr:last-child td {
    border-bottom: none;
}

.results-table tbody tr:hover {
    background: var(--light-bg);
}

.results-table .highlight-row td {
    background: var(--highlight-bg);
}

.results-table .highlight-row:hover td {
    background: #dbeafe;
}

/* Grouped (paper-style) results table */
.results-table-grouped th {
    text-align: center;
}

.results-table-grouped th.col-model {
    text-align: left;
    vertical-align: bottom;
}

.results-table-grouped .group-sep {
    border-left: 1px solid var(--border-color);
}

.results-table-grouped thead tr:first-child th[colspan] {
    font-size: 0.9rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.results-table .empty-state {
    text-align: center;
    color: var(--text-light);
    font-style: italic;
    padding: 1.5rem 1rem;
}

/* Disabled Hugging Face link (not yet public) */
.hf-link-disabled {
    color: var(--text-light);
    cursor: not-allowed;
    opacity: 0.65;
}

/* Citation Flat UI */
.citation-box {
    position: relative;
    background: var(--light-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 1.5rem;
    margin-top: 1rem;
}

.citation-box pre {
    font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.88rem;
    color: var(--text-body);
    margin: 0;
    white-space: pre-wrap;
    word-break: break-all;
}

.copy-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: #ffffff;
    border: 1px solid #d1d5db;
    color: var(--text-body);
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
}

.copy-btn:hover {
    background: var(--light-bg);
    border-color: #9ca3af;
}

/* Footer Section */
.footer {
    text-align: center;
    padding: 2rem;
    font-size: 0.85rem;
    color: var(--text-light);
    border-top: 1px solid var(--border-color);
}

.footer a {
    color: var(--text-light);
}

.footer a:hover {
    color: var(--text-primary);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .container {
        padding: 2rem 1.25rem;
        gap: 3rem;
    }

    .hero h1 {
        font-size: 1.65rem;
    }

    .action-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 260px;
        justify-content: center;
    }

    .results-table th,
    .results-table td {
        padding: 0.55rem 0.65rem;
        font-size: 0.82rem;
    }
}