/* Extra CSS for AI4H-Inspired FM Benchmarks Documentation */

/* ============================================
   LAYOUT: Full-width content (no right TOC)
   ============================================ */

/* Hide the right-side TOC completely */
.md-sidebar--secondary {
    display: none;
}

/* Make content area take full width */
.md-content {
    max-width: 100%;
}

/* Expand content container */
.md-main__inner {
    max-width: 100%;
}

/* Wider content area on large screens */
@media screen and (min-width: 76.25em) {
    .md-content__inner {
        max-width: 60rem; /* Wider content */
        margin: 0 auto;
    }
}

@media screen and (min-width: 60em) {
    .md-content {
        margin-left: 0;
    }
}

/* Enhance code blocks */
.highlight {
    border-radius: 4px;
}

/* Make tables more readable */
table {
    border-collapse: collapse;
    width: 100%;
    margin: 1em 0;
}

table th {
    background-color: var(--md-default-fg-color--lightest);
    font-weight: 600;
    padding: 0.6rem 1rem;
    text-align: left;
}

table td {
    padding: 0.6rem 1rem;
    border-top: 1px solid var(--md-default-fg-color--lightest);
}

/* Leaderboard styling */
.leaderboard-table {
    font-size: 0.9em;
}

.leaderboard-table td:first-child {
    font-weight: 600;
}

/* Metric badges */
.metric-badge {
    display: inline-block;
    padding: 0.2em 0.6em;
    border-radius: 3px;
    font-size: 0.85em;
    font-weight: 600;
    background-color: var(--md-accent-fg-color--transparent);
    color: var(--md-accent-fg-color);
}

/* Callout boxes for important information */
.admonition {
    margin: 1.5em 0;
}

/* Code fence improvements */
code {
    background-color: var(--md-code-bg-color);
    border-radius: 2px;
    padding: 0.1em 0.3em;
}

/* Improve inline code in tables */
table code {
    white-space: nowrap;
}

/* Add visual hierarchy to sections */
h1 {
    border-bottom: 2px solid var(--md-primary-fg-color);
    padding-bottom: 0.3em;
}

h2 {
    margin-top: 2em;
    border-bottom: 1px solid var(--md-default-fg-color--lightest);
    padding-bottom: 0.2em;
}

/* Benchmark card styling (optional, for future use) */
.benchmark-card {
    border: 1px solid var(--md-default-fg-color--lightest);
    border-radius: 4px;
    padding: 1em;
    margin: 1em 0;
    background-color: var(--md-default-bg-color);
}

.benchmark-card h3 {
    margin-top: 0;
    color: var(--md-primary-fg-color);
}

/* Status indicators */
.status-completed {
    color: #4caf50;
    font-weight: 600;
}

.status-pending {
    color: #ff9800;
    font-weight: 600;
}

.status-failed {
    color: #f44336;
    font-weight: 600;
}

/* Improve mobile responsiveness */
@media screen and (max-width: 768px) {
    table {
        font-size: 0.85em;
    }
    
    table th,
    table td {
        padding: 0.4rem 0.6rem;
    }
}

/* Syntax highlighting improvements for YAML */
.language-yaml .na {
    color: var(--md-code-hl-name-color);
}

.language-yaml .s {
    color: var(--md-code-hl-string-color);
}

/* Model card styling */
.model-info {
    background-color: var(--md-default-fg-color--lightest);
    padding: 0.5em 1em;
    border-left: 3px solid var(--md-primary-fg-color);
    margin: 1em 0;
}

/* Citation blocks */
.citation {
    font-family: var(--md-code-font-family);
    font-size: 0.85em;
    background-color: var(--md-code-bg-color);
    padding: 1em;
    border-radius: 4px;
    overflow-x: auto;
}

/* Footer adjustments */
.md-footer-meta {
    background-color: var(--md-default-bg-color);
}

/* Navigation improvements */
.md-nav__link--active {
    font-weight: 600;
}

/* Search result highlighting */
.md-search-result__meta {
    color: var(--md-default-fg-color--light);
}

/* Improve readability of inline links */
a code {
    color: var(--md-typeset-a-color);
}

/* Custom class for protocol boxes */
.protocol-step {
    background-color: var(--md-default-fg-color--lightest);
    border-left: 4px solid var(--md-accent-fg-color);
    padding: 1em;
    margin: 1em 0;
    border-radius: 0 4px 4px 0;
}

.protocol-step h4 {
    margin-top: 0;
    color: var(--md-accent-fg-color);
}

/* Enhance metric tables in leaderboards */
.metrics-table {
    font-variant-numeric: tabular-nums;
}

.metrics-table td {
    text-align: center;
}

.metrics-table td:first-child {
    text-align: left;
    font-weight: 600;
}

/* ============================================
   GAMIFIED LEADERBOARD STYLES
   ============================================ */

/* Leaderboard table enhancements */
table tr:first-child td {
    background: linear-gradient(135deg, #ffd70020 0%, #fff8e120 100%);
    font-weight: 700;
}

table tr:nth-child(2) td {
    background: linear-gradient(135deg, #c0c0c020 0%, #e8e8e820 100%);
}

table tr:nth-child(3) td {
    background: linear-gradient(135deg, #cd7f3220 0%, #daa06d20 100%);
}

/* Rank column styling */
table td:first-child {
    font-size: 1.2em;
    text-align: center !important;
    min-width: 60px;
}

/* Trophy/medal animations */
@keyframes trophy-glow {
    0%, 100% { filter: drop-shadow(0 0 3px #ffd700); }
    50% { filter: drop-shadow(0 0 8px #ffd700); }
}

/* Champion row highlight */
table tr:first-child {
    position: relative;
}

/* Score column */
table td:nth-child(3) {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

/* Details expandable sections */
details {
    margin: 0.5em 0;
    padding: 0.5em;
    border-radius: 8px;
    background: var(--md-default-fg-color--lightest);
    border-left: 4px solid var(--md-primary-fg-color);
}

details[open] {
    background: linear-gradient(180deg, var(--md-default-fg-color--lightest) 0%, transparent 100%);
}

details summary {
    cursor: pointer;
    padding: 0.5em;
    font-weight: 600;
    user-select: none;
}

details summary:hover {
    color: var(--md-primary-fg-color);
}

/* Stratified table styling */
details table {
    margin-top: 0.5em;
    font-size: 0.9em;
}

details table tr:first-child td {
    background: linear-gradient(135deg, #4caf5020 0%, #81c78420 100%);
}

/* Stats banner styling */
.md-typeset .admonition.success {
    border-color: #4caf50;
    background: linear-gradient(135deg, #4caf5010 0%, #81c78410 100%);
}

/* Quick nav styling */
.md-typeset ul a {
    text-decoration: none;
}

.md-typeset ul a:hover {
    text-decoration: underline;
}

/* Submission CTA section */
h2:has(+ p > strong:first-child) {
    background: linear-gradient(90deg, var(--md-primary-fg-color) 0%, var(--md-accent-fg-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Model name styling in tables */
table td strong {
    color: var(--md-primary-fg-color);
}

/* Crown emoji special styling */
table td:contains("👑") {
    font-size: 1.1em;
}

/* Hover effects for table rows */
table tbody tr:hover {
    background-color: var(--md-accent-fg-color--transparent) !important;
    transition: background-color 0.2s ease;
}

/* Performance tier badges */
.tier-excellent { color: #ffd700; font-weight: bold; }
.tier-good { color: #4caf50; }
.tier-fair { color: #ff9800; }
.tier-developing { color: #2196f3; }

/* Methodology note styling */
table + hr + p {
    font-style: italic;
    color: var(--md-default-fg-color--light);
    font-size: 0.85em;
    text-align: center;
    margin-top: 1em;
}

/* Add subtle animation to interactive elements */
.md-nav__link:hover,
.md-footer__link:hover {
    transition: color 0.2s ease;
}

/* Improve contrast for dark mode code blocks */
[data-md-color-scheme="slate"] .highlight {
    background-color: var(--md-code-bg-color);
}

/* Better spacing for nested lists */
.md-typeset ul ul,
.md-typeset ol ol {
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}

/* Checkbox list styling */
.task-list-item {
    list-style-type: none;
}

.task-list-item input[type="checkbox"] {
    margin-right: 0.5em;
}

