/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #154d39;
    --text-color: #000000;
    --light-gray: #f8f8f8;
    --border-color: #e5e5e5;
    --link-color: #000000;
    --link-hover: #666666;
    --max-width: 800px;
    --spacing-unit: 1.5rem;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #ffffff;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    margin: 0;
    padding: 0;
}

strong, b {
    color: var(--primary-color);
    font-weight: 700;
}

/* Container */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
}

h1 {
    font-size: 3.5rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    letter-spacing: -0.03em;
}

.subtitle {
    font-size: 1.1rem;
    color: #666;
    font-weight: 400;
    margin-bottom: 1rem;
}

.authors {
    font-size: 1rem;
    color: #444;
    margin-bottom: 1rem;
}

.author-row {
    margin-bottom: 0.3rem;
}

.author {
    margin: 0 0.5rem;
}

.affiliations {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.4;
}

.affiliations div {
    margin-bottom: 0.3rem;
}

.equal-contrib {
    font-style: italic;
}

.emails {
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 0.85rem;
}

/* Quote Block */
.quote-block {
    margin: 2.5rem 0;
}

.quote-block blockquote {
    margin: 0;
    padding: 1.5rem;
    background-color: var(--light-gray);
    border-left: 4px solid #e0e0e0;
    font-style: italic;
}

.quote-block blockquote p {
    margin: 0;
    line-height: 1.7;
    color: #555;
}

.quote-block cite {
    display: block;
    margin-top: 1rem;
    text-align: right;
    font-style: normal;
    font-size: 0.9rem;
    color: #666;
}

/* Navigation */
nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin: 1.5rem 0;
    padding: 0;
    flex-wrap: wrap;
    font-size: 1.1rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    transition: opacity 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-link:hover {
    opacity: 0.7;
}

.nav-separator {
    color: #ccc;
    font-weight: 300;
    margin: 0 0.5rem;
}

.paper-icon {
    width: 24px;
    height: 24px;
}

.hf-logo {
    width: 24px;
    height: 24px;
}

.github-logo {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* Main Content */
main {
    margin-bottom: 4rem;
}

section {
    margin-bottom: 4rem;
}

h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 2rem 0 1rem;
}

h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 1rem 0 0.5rem;
}

p {
    margin-bottom: 1rem;
    line-height: 1.7;
}

/* Lists */
ul, ol {
    margin: 1rem 0 1.5rem 2rem;
}

li {
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

ol li {
    padding-left: 0.5rem;
}

/* Links */
a {
    color: var(--link-color);
    text-decoration: underline;
    text-underline-offset: 2px;
    text-decoration-thickness: 1px;
    transition: opacity 0.2s ease;
}

a:hover {
    opacity: 0.7;
}

/* Figures */
.figure {
    margin: 3rem 0;
    text-align: center;
}

.responsive-img {
    max-width: 100%;
    height: auto;
    border: none;
    border-radius: 0;
    box-shadow: none;
}

.caption {
    margin-top: 1rem;
    font-size: 0.875rem;
    color: #666;
    font-style: normal;
    text-align: left;
    line-height: 1.5;
}

/* Method Grid */
.method-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.method-card {
    padding: 0;
}

.method-card h4 {
    margin-bottom: 0.5rem;
}

.method-card p {
    color: #666;
    font-size: 0.95rem;
    margin: 0;
}

/* Results Summary */
.results-summary {
    display: flex;
    justify-content: space-around;
    gap: 2rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.result-item {
    text-align: center;
}

.result-metric {
    font-size: 2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.result-label {
    font-size: 0.9rem;
    color: #666;
}

/* Artifacts Table */
.table-container {
    margin: 2rem 0;
    overflow-x: auto;
}

.artifacts-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.artifacts-table th {
    background-color: var(--light-gray);
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid var(--border-color);
}

.artifacts-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.artifacts-table tr.section-header td {
    background-color: #f5f5f5;
    font-weight: 600;
    padding-top: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: none;
}

.artifacts-table tbody tr:hover:not(.section-header) {
    background-color: #fafafa;
}

.artifacts-table a {
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 0.85rem;
}

.artifacts-info {
    margin-top: 2rem;
}

.artifacts-info ul {
    list-style: none;
    margin: 0.5rem 0;
    padding: 0;
}

.artifacts-info li {
    margin-bottom: 0.5rem;
}

/* Citation Box */
.citation-box {
    background: var(--light-gray);
    border: none;
    border-radius: 0;
    padding: 1.5rem;
    margin: 1.5rem 0;
    overflow-x: auto;
}

.citation-box pre {
    margin: 0;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
}

.citation-box code {
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--primary-color);
    font-family: inherit;
}

/* Footer */
footer {
    text-align: center;
    padding: 4rem 0 2rem;
    border-top: none;
    color: #666;
    font-size: 0.9rem;
}

footer p {
    margin-bottom: 0.5rem;
}

footer a {
    color: #666;
}

/* Responsive Design */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    nav {
        gap: 1.5rem;
    }
    
    h2 {
        font-size: 1.3rem;
    }
    
    .method-grid,
    .model-grid {
        grid-template-columns: 1fr;
    }
    
    .results-summary {
        flex-direction: column;
        gap: 1.5rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 1.5rem 1rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    nav {
        gap: 1rem;
    }
    
    .nav-link {
        font-size: 0.9rem;
    }
}

/* Print Styles */
@media print {
    body {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    .container {
        max-width: 100%;
    }
    
    nav, footer {
        display: none;
    }
    
    a {
        color: var(--text-color);
        text-decoration: none;
    }
    
    .stat-card {
        break-inside: avoid;
    }
}