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

:root {
    --primary-color: #1a1a1a;
    --accent-color: #0066cc;
    --accent-hover: #0052a3;
    --text-color: #333;
    --text-light: #666;
    --bg-color: #ffffff;
    --secondary-bg: #f7f7f7;
    --border-color: #e0e0e0;
    --highlight-bg: #f0f7ff;
    --code-bg: #f5f5f5;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.7;
    color: var(--text-color);
    background: var(--bg-color);
    font-size: 16px;
}

/* Article Container */
article {
    max-width: 900px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

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

h1 {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    line-height: 1.3;
}

.authors {
    margin: 1.5rem 0;
}

.authors p {
    font-size: 1.05rem;
    color: var(--text-color);
    margin: 0.5rem 0;
}

.authors a {
    color: var(--text-color);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.authors a:hover {
    border-bottom-color: var(--accent-color);
}

.affiliation {
    font-size: 0.95rem;
    color: var(--text-light);
}

.venue {
    margin: 1.5rem 0;
}

.venue p {
    font-size: 1rem;
    color: var(--text-color);
    font-weight: 600;
    margin: 0.5rem 0;
}

.oral {
    display: inline-block;
    background: #dc2626;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-left: 0.5rem;
}

.spotlight {
    display: inline-block;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-left: 0.5rem;
}

/* Links */
.links {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--accent-color);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    border: 2px solid var(--accent-color);
}

.btn:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,102,204,0.2);
}

.btn-secondary {
    background: white;
    color: var(--accent-color);
}

.btn-secondary:hover {
    background: var(--highlight-bg);
    border-color: var(--accent-color);
}

/* Sections */
section {
    margin: 4rem 0;
}

h3 {
    font-size: 1.75rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-weight: 700;
}

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

p {
    margin-bottom: 1.25rem;
    line-height: 1.8;
}

.tldr {
    background: var(--highlight-bg);
    padding: 1.5rem;
    border-left: 4px solid var(--accent-color);
    border-radius: 4px;
    font-size: 1.05rem;
}

ul {
    margin: 1rem 0 1.5rem 1.5rem;
    line-height: 1.8;
}

li {
    margin-bottom: 0.75rem;
}

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

.component {
    background: var(--secondary-bg);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.component h4 {
    margin-top: 0;
    color: var(--accent-color);
}

.component ul {
    margin-left: 1.25rem;
}

/* Results Highlight */
.results-highlight {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.5rem;
    margin: 2.5rem 0;
}

.metric-card {
    background: var(--secondary-bg);
    padding: 2rem 1.5rem;
    border-radius: 8px;
    text-align: center;
    border: 1px solid var(--border-color);
    transition: transform 0.2s, box-shadow 0.2s;
}

.metric-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-color);
    line-height: 1.2;
}

.metric-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    margin-top: 0.5rem;
}

.metric-desc {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-top: 0.25rem;
}

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

.figure img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.figure-wide {
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    width: min(1400px, 95vw);
}

.figure-wide img {
    width: 100%;
    max-width: none;
}

.figure-wide .caption {
    max-width: 1000px;
}

.caption {
    margin-top: 1.25rem;
    font-size: 0.95rem;
    color: var(--text-light);
    line-height: 1.6;
    text-align: center;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Tables */
.table-container {
    overflow-x: auto;
    margin: 2rem 0;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    font-size: 0.95rem;
}

thead {
    background: var(--primary-color);
    color: white;
}

th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.9rem;
}

td {
    padding: 0.9rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

tbody tr:hover {
    background: var(--secondary-bg);
}

tbody tr.highlight-row {
    background: var(--highlight-bg);
    font-weight: 600;
}

tbody tr.highlight-row:hover {
    background: #e6f2ff;
}

/* Citation */
#citation pre {
    background: var(--code-bg);
    padding: 1.5rem;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    overflow-x: auto;
    margin-top: 1rem;
}

#citation code {
    font-family: 'SF Mono', 'Monaco', 'Consolas', 'Courier New', monospace;
    font-size: 0.85rem;
    color: var(--text-color);
    line-height: 1.6;
}

/* Footer */
footer {
    text-align: center;
    padding: 3rem 0 2rem;
    margin-top: 5rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-light);
    font-size: 0.9rem;
}

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

footer a:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
    article {
        padding: 2rem 1.5rem;
    }

    h1 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.5rem;
    }

    h4 {
        font-size: 1.15rem;
    }

    .links {
        flex-direction: column;
        gap: 0.75rem;
    }

    .btn {
        width: 100%;
    }

    .component-grid {
        grid-template-columns: 1fr;
    }

    .results-highlight {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .metric-value {
        font-size: 2rem;
    }

    th, td {
        padding: 0.75rem 0.5rem;
        font-size: 0.85rem;
    }

    .table-container {
        margin: 1.5rem -1rem;
        border-radius: 0;
    }

    .figure-wide {
        width: 100%;
        left: 0;
        transform: none;
    }
}

@media (max-width: 480px) {
    article {
        padding: 1.5rem 1rem;
    }

    h1 {
        font-size: 1.5rem;
    }

    .authors p {
        font-size: 0.95rem;
    }
}
