/* style.css */
body { overflow-x: hidden; }

/* d-title: title above figure (plot | card), then caption – centered, constrained width */
d-title.title-figure-layout {
    grid-column: 1 / -1;
    padding: 2rem 0 1.5rem;
    contain: layout style;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}
d-title.title-figure-layout h1 {
    grid-column: 1 / -1;
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1.2;
    margin: 0 0 1.5rem;
    color: inherit;
    text-align: center;
    max-width: 50vw;
    width: 100%;
}
@media (min-width: 768px) {
    d-title.title-figure-layout h1 { font-size: 2.75rem; }
}
d-title.title-figure-layout .title-figure {
    grid-column: 1 / -1;
    margin: 0 0 1rem;
    max-width: 60vw;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}
d-title.title-figure-layout .title-figure-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 0;
    height: 500px;
    min-height: 500px;
    align-items: stretch;
    background: #fff;
    width: 100%;
    overflow: hidden;
    margin-bottom: 0.75rem;
}
d-title.title-figure-layout .title-figure-row .main-plot-container {
    min-height: 0;
    display: block;
    overflow: hidden;
}
d-title.title-figure-layout .title-figure-row [id^="plot-"] {
    display: block;
    width: 100%;
    height: 500px;
    min-height: 500px;
    box-sizing: border-box;
}
d-title.title-figure-layout .title-figure-row .model-card-container {
    padding: 1rem;
    min-height: 0;
    height: 500px;
    max-height: 500px;
    overflow-y: auto;
    box-sizing: border-box;
}
d-title.title-figure-layout .title-figure-caption {
    font-size: 0.9em;
    font-style: italic;
    color: var(--distill-gray);
    line-height: 1.5;
    margin-top: 0;
    margin-bottom: 0;
    max-width: 50vw;
    width: 100%;
    text-align: center;
}
@media (max-width: 900px) {
    d-title.title-figure-layout .title-figure-row {
        grid-template-columns: 1fr;
        height: auto;
        min-height: 0;
    }
    d-title.title-figure-layout .title-figure-row [id^="plot-"] { min-height: 400px; height: auto; }
    d-title.title-figure-layout .title-figure-row .model-card-container { max-height: none; }
}

/* Define colors */
:root {
    --distill-gray: rgb(107, 114, 128);
    --distill-gray-light: rgb(185, 185, 185);
    --distill-gray-lighter: rgb(228, 228, 228);
    --distill-gray-lightest: rgb(245, 245, 245);
    --distill-blue: #007BFF;
}

/* Plot containers inside article (e.g. deployment plot) – hero plot has its own rules */
d-article [id^="plot-"] {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}
d-article [id^="plot-"] figure {
    margin-bottom: 0;
    margin-top: 0;
    padding: 0;
}
.plotly_controls {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    justify-content: center;
    align-items: flex-start;
    gap: 30px;
}

/* Deployment section: narrow left column (title + controls), plot on the right */
.deployment-plot-section {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.5rem;
    align-items: start;
    margin-top: 21px;
    margin-bottom: 35px;
}
.deployment-plot-controls {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    min-width: 0;
    width: 100px;
}
.deployment-plot-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.25rem 0;
    line-height: 1.3;
}
.deployment-plot-help {
    font-size: 0.75rem;
    line-height: 1.35;
    margin: 0 0 0.75rem 0;
    color: rgba(0, 0, 0, 0.7);
}
.deployment-plot-section .main-plot-container {
    margin: 0;
    min-width: 0;
}

.plotly_input_container {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 10px;
}

/* Style for the select dropdown */
.plotly_input_container > select {
    padding: 2px 4px;
    /* border: 1px solid #ccc; */
    line-height: 1.5em;
    text-align: center;
    border-radius: 4px;
    font-size: 12px;
    background-color: var(--distill-gray-lightest);
    outline: none;
}

/* Style for the labels */
.plotly_input_container > label {
    font-size: 14px;
    font-weight: bold;
}

.main-plot-container {
    margin-top: 21px;
    margin-bottom: 35px;
}

.main-plot-container > figure {
    display: block !important;
    /* Let this be handled by graph-container */
    margin-bottom: 0px;
    margin-top: 0px;
}
.main-plot-container > div {
    display: block !important;
}

d-byline .byline {
  grid-template-columns: 1fr;
  grid-column: text;
  font-size: 0.9rem;
  line-height: 1.8em;
}

@media (min-width: 768px) {
  d-byline .byline {
    grid-template-columns: 5fr 1fr 1fr;
  }
}

#title-plot {
    margin-top: 0px;
    margin-bottom: 0px;
}


@media (max-width: 1199px) {
    d-contents {
        display: none;
        background: white;
        justify-self: start;
        align-self: start;
        padding-bottom: 0.5em;
        margin-bottom: 1em;
        padding-left: 0.25em;
        border-bottom: 1px solid rgba(0, 0, 0, 0.1);
        overflow-y: scroll;
        height: calc(100vh - 40px);
        scrollbar-width: none;
        z-index: -100;
    }
}

d-contents a:hover {
    border-bottom: none;
}

.toc-header {
    cursor: pointer;
    user-select: none;
}

.toc-title {
    font-weight: bold;
    font-size: 1.25em;
    color: #1a1a1a;
}

.toggle-icon {
    transition: transform 0.3s;
    color: #555;
    font-size: 0.7em;
}

.toggle-icon.collapsed {
    transform: rotate(-90deg);
}

.toc-content {
    margin-top: 15px;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.toc-content.collapsed {
    max-height: 0;
    margin-top: 0;
}

@media (min-width: 1200px) {
    d-article {
        /* Ensure d-article does not prevent sticky positioning */
        overflow: visible;
    }

    d-contents {
        align-self: start;
        background: white;
        grid-column-start: 1 !important;
        grid-column-end: 4 !important;
        grid-row: auto / span 6;
        justify-self: end;
        margin-top: 0em;
        padding-right: 3em;
        padding-left: 2em;
        position: -webkit-sticky;
        position: sticky;
        top: 10px; /* Adjust this value if needed */
        overflow-y: auto;
        height: calc(100vh - 40px);
        scrollbar-width: none;
        transition: max-height 0.3s ease-out;
        z-index: -100;
    }

    /* Sticky right column: image in gutter, same row as first content so top-aligned with text */
    d-article .article-top-image {
        grid-column: gutter-start / screen-end;
        grid-row: 3 / -1;
        align-self: start;
        position: sticky;
        top: 10px;
        margin: 0;
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
    d-article .article-top-image img {
        width: 100%;
        height: auto;
        display: block;
    }
}

d-contents nav a.toc-link {
    border-bottom: none;
    text-decoration: none;
    display: block;
    line-height: 1.4;
}
d-contents nav .toc-list { padding-left: 0; margin: 0.5em 0 0; list-style: none; }
d-contents nav .toc-list ul { padding-left: 1em; margin: 0.2em 0 0.4em; list-style: none; border-left: 1px solid rgba(0, 0, 0, 0.1); }
d-contents nav .toc-list li { margin-bottom: 0.35em; }
d-contents nav a.toc-link.toc-level-0 { font-size: 13px; font-weight: 600; color: #1a1a1a; }
d-contents nav a.toc-link.toc-level-1,
d-contents nav a.toc-link.toc-level-2 { font-size: 12px; font-weight: 500; color: rgba(0, 0, 0, 0.75); }
d-contents nav a.toc-link:hover { text-decoration: none; }
d-contents nav a.toc-link.toc-level-0:hover { color: #2563eb; }
d-contents nav .toc-list ul a.toc-link:hover { text-decoration: underline; color: rgba(0, 0, 0, 0.9); }

d-article aside {
    margin-bottom: 1em;
}

d-article img {
    max-width: 100%;
}

@media (min-width: 768px) {
    d-article aside {
        margin-bottom: 0;
    }
}

d-contents nav a.toc-link.active { color: #2563eb; font-weight: 600; text-decoration: underline; }

/* Invisible anchor for "top of content" TOC link */
.toc-anchor { display: block; height: 0; overflow: hidden; margin: 0; padding: 0; }

.note-box {
    background-color: #f6f8fa;
    border-left: 4px solid #444444;
    padding: 1rem;
    margin: 1rem 0;  /* Keep this modest margin */
    border-radius: 6px;
    /* Add this to ensure the box only takes up needed space */
    display: inline-block;
    width: 100%;
}

.note-box-title {
    margin: 0;
    color: #444444;
    font-weight: 600;
    font-size: 1em;
}

.note-box-content {
    margin-top: 0.5rem;
    margin-bottom: 0;  /* Ensure no bottom margin */
    color: #24292f;
    font-size: 0.9em;
    line-height: 1.5em;
}

d-article {
    font-size: 1.0em;
}

/* Top-of-article image: default (in text column on narrow viewports) */
d-article .article-top-image {
    margin: 0 0 1.5em 0;
}
d-article .article-top-image img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Transition image in main content between Conclusion and Appendix (not in right column) */
d-article .article-transition-image {
    margin: 1.5em 0;
}
d-article .article-transition-image img {
    max-width: 100%;
    height: auto;
    display: block;
}

.figure-legend {
    font-size: 0.9em;
    font-style: italic;
    color: var(--distill-gray);
    line-height: 1.5em;
}

d-code {
    font-size: 12px;
}

.large-image-background {
        width: 100vw;
        padding-top: 10px;
        padding-bottom: 10px;
        margin-left: calc(-50vw + 50%);
        margin-right: calc(-50vw + 50%);
        background: white;
        height: fit-content; /* This will make it match the image height */
        display: flex;
        justify-content: center; /* This will center your image */
}

.large-image-background-transparent {
    /* width: 100vw; */
    padding-top: 10px;
    padding-bottom: 10px;
    /* margin-left: calc(-50vw + 50%); */
    margin-left:-100px;
    margin-right: -100px;
    /* margin-right: calc(-50vw + 50%); */
    /* background: white; */
    height: fit-content; /* This will make it match the image height */
    display: flex;
    justify-content: center; /* This will center your image */
}

.boxed-image {
    padding: 0.5rem;
    background: white;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

d-article li {
    margin-bottom: 0.0em;
}

d-article ul ul {
    margin-bottom: 0.0em;
}

d-article ol ol {
    margin-bottom: 0.0em;
}

d-article hr {
    grid-column: text;
}

/* Memory visualization */
#graph-all {
    min-width: 500px;
    margin-right: 10px;
    margin-bottom: 2rem;
    padding: 0.5rem;
    background: #f9fafb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}


/* Main container styles */
#controls {
    max-width: 1200px;
    /* margin: 2rem auto; */
    margin-bottom: 2rem;
    margin-left: 10px;
    padding: 0.6rem;
    background: #f9fafb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Grid layout */
#controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* gap: 2rem; */
}

/* Cell styles */
.cell {
    margin-bottom: 0.2rem;
}

/* Label styles */
label {
    display: block;
    /* margin-bottom: 0.5rem; */
    font-size: 0.8rem;
    font-weight: 500;
    color: #374151;
}

/* Input container for range + number combination */
.input-container {
    display: flex;
    gap: 1rem;
    align-items: center;
}

/* Range input styling */
input[type="range"] {
    flex: 1;
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
    appearance: none;
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 16px;
    height: 16px;
    background: #3b82f6;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.15s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
    background: #2563eb;
}

/* Number input styling */
input[type="number"] {
    width: 80px;
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 0.9rem;
    color: #374151;
}

/* Select styling */
select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: white;
    font-size: 0.9rem;
    color: #374151;
    cursor: pointer;
}

/* Checkbox styling */
input[type="checkbox"] {
    width: 1.2rem;
    height: 1.2rem;
    margin-right: 0.5rem;
    border: 2px solid #e5e7eb;
    border-radius: 4px;
    cursor: pointer;
}

/* Column specific styles */
.column-1 {
    padding-right: 0.5rem;
}

.column-2 {
    padding-left: 0.5rem;
}

/* Checkbox container */
.checkbox-container {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

/* Memory visualization styles */
.memory-block {
    background: #fff;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.memory-title {
    font-size: 1.1rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.5rem;
}

.memory-value {
    font-size: 1.5rem;
    font-weight: 600;
    color: #3b82f6;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    #controls {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

    .column-1, .column-2 {
        padding: 0;
    }
}

/* Hover states and transitions */
input:hover, select:hover {
    border-color: #3b82f6;
}

input:focus, select:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

/* Add smooth transitions */
input, select, button {
    transition: all 0.15s ease;
}

/* Preset dropdown special styling */
select[name="presets"] {
    background-color: #f3f4f6;
    font-weight: 500;
}

/* Memory graph enhancements */
.activation-memory {
    background: #dbeafe;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.gradient-memory {
    background: #ede9fe;
    padding: 1rem;
    border-radius: 8px;
}

/* Model card and tags (ported from Gradio CARD_CSS) */
:root {
    --border-color-primary: rgba(0, 0, 0, 0.1);
}

.plot-hint {
    font-size: 0.85rem;
    color: rgba(0, 0, 0, 0.55);
    margin: 0 0 10px 0;
}

.model-card-container {
    display: flex;
    flex-direction: column;
}

.model-card {
    border: 1px solid var(--border-color-primary);
    border-radius: 12px;
    padding: 18px;
    border-left-width: 4px;
}
.model-card[data-category="task_domain"] { border-left-color: #1F77B4; }
.model-card[data-category="small"] { border-left-color: #2CA02C; }
.model-card[data-category="medium"] { border-left-color: #FF7F0E; }
.model-card[data-category="large"] { border-left-color: #D62728; }

.card-block {
    margin-top: 14px;
}
.card-block:first-child { margin-top: 0; }
.card-block-top {
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border-color-primary);
}
.card-block-bottom { }

.card-title-link {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid currentColor;
}
.card-title-link:hover {
    opacity: 0.85;
}

.card-header { margin-bottom: 12px; }
.card-title { font-size: 20px; font-weight: 600; }
.card-subtitle { font-size: 14px; margin-top: 4px; opacity: 0.8; }
.card-section { margin-top: 14px; }
.card-section-title {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0.7;
    margin-bottom: 6px;
}
.card-text, .card-line { font-size: 14px; line-height: 1.5; }
.card-line { margin-top: 6px; }

.card-analysis {
    margin-top: 8px;
    font-size: 14px;
    line-height: 1.5;
}
.card-source-ref {
    font-size: 0.85em;
    vertical-align: super;
    text-decoration: none;
    opacity: 0.85;
}
.card-source-ref:hover { text-decoration: underline; }

.card-badges {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
.card-badge {
    display: inline-block;
    padding: 0.2em 0.5em;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}
.card-badge-confidence {
    background: rgba(0, 0, 0, 0.08);
    color: rgba(0, 0, 0, 0.75);
}
.card-badge-detail {
    background: rgba(0, 0, 0, 0.05);
    color: rgba(0, 0, 0, 0.7);
    font-weight: 500;
}

/* Inline training plot (after Training Costs per Category): graph on top, description + card below */
.training-plot-inline {
    margin: 1.5rem 0;
}
.training-plot-inline-graph {
    margin: 0 -1.5rem 1rem -1.5rem;
    width: calc(100% + 3rem);
    max-width: 100vw;
    box-sizing: border-box;
}
.training-plot-inline-graph .main-plot-container {
    width: 100%;
}
.training-plot-inline-bottom {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    align-items: start;
}
.training-plot-inline-left {
    min-width: 0;
}
.training-plot-inline-title {
    font-size: 1.15rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
}
.training-plot-inline-desc {
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(0, 0, 0, 0.75);
    margin: 0 0 0.75rem 0;
}
.training-plot-inline-left .plot-hint {
    margin-bottom: 0;
}
.training-plot-inline-card {
    min-width: 0;
}
.training-plot-inline-card .model-card-container {
    max-height: 280px;
    overflow-y: auto;
}
@media (max-width: 700px) {
    .training-plot-inline-bottom {
        grid-template-columns: 1fr;
    }
    .training-plot-inline-graph {
        margin-left: 0;
        width: 100%;
    }
}

/* In-text model mentions [[ModelName]] */
.model-mention {
    display: inline;
    padding: 0.15em 0.4em;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95em;
    text-decoration: none;
}
.model-mention--task_domain {
    background: rgba(31, 119, 180, 0.15);
    border: 1px solid rgba(31, 119, 180, 0.4);
    color: #1a5a8a;
}
.model-mention--small {
    background: rgba(44, 160, 44, 0.15);
    border: 1px solid rgba(44, 160, 44, 0.4);
    color: #1e7a1e;
}
.model-mention--medium {
    background: rgba(255, 127, 14, 0.15);
    border: 1px solid rgba(255, 127, 14, 0.4);
    color: #b35a00;
}
.model-mention--large {
    background: rgba(214, 39, 40, 0.15);
    border: 1px solid rgba(214, 39, 40, 0.4);
    color: #9e1b1b;
}
a.model-mention:hover {
    filter: brightness(0.92);
}

/* Hover tooltip for in-text model mentions */
.model-mention-tooltip {
    position: fixed;
    z-index: 10000;
    max-width: 320px;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.12);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    font-size: 13px;
    line-height: 1.4;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.15s ease;
    pointer-events: auto;
}
.model-mention-tooltip-name {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
}
.model-mention-tooltip-params,
.model-mention-tooltip-cost,
.model-mention-tooltip-confidence {
    margin-top: 4px;
    opacity: 0.9;
}
.model-mention-tooltip-notes {
    margin-top: 6px;
    font-size: 12px;
    opacity: 0.85;
    max-height: 12em;
    overflow-y: auto;
}

/* Tag chips */
.tag {
    display: inline-block;
    padding: 0.15em 0.5em;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95em;
}
.tag-sage { background: rgba(156, 168, 138, 0.4); }
.tag-lavender { background: rgba(184, 169, 201, 0.4); }
.tag-peach { background: rgba(232, 196, 160, 0.5); }
.tag-rose { background: rgba(232, 164, 164, 0.4); }
.tag-lime { background: rgba(212, 232, 156, 0.4); }
.tag-neutral { background: rgba(37, 99, 235, 0.12); }

/* Callout */
.callout {
    padding: 1em 1.25em;
    margin: 1em 0;
    border-left: 4px solid #5b7cbb;
    background: rgba(91, 124, 187, 0.08);
    border-radius: 0 6px 6px 0;
}

/* Section title */
h2.section-title {
    font-size: 1.4rem;
    margin-top: 1.5em;
    padding-bottom: 0.3em;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

/* Subsection title (category H3s under Training Costs) */
h3.subsection-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.5em;
    padding-bottom: 0.3em;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

/* Theme toggle: bottom-left button (light/dark) */
.theme-toggle {
    position: fixed;
    bottom: 1.25rem;
    left: 1.25rem;
    z-index: 1000;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 50%;
    background: #fff;
    color: #333;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    transition: background 0.2s, color 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.theme-toggle:hover {
    background: #f5f5f5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.theme-toggle .theme-toggle-icon {
    position: absolute;
}
.theme-toggle .theme-icon-dark { display: none; }
.theme-toggle .theme-icon-light { display: inline; }
html.dark .theme-toggle .theme-icon-dark { display: inline; }
html.dark .theme-toggle .theme-icon-light { display: none; }
html.dark .theme-toggle {
    border-color: rgba(255, 255, 255, 0.2);
    background: #2a2a2a;
    color: #e0e0e0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}
html.dark .theme-toggle:hover { background: #353535; }

/* Dark mode: only when user chose it via toggle (class set from localStorage). Single block. */
html.dark {
    --border-color-primary: rgba(255, 255, 255, 0.08);
    --dm-bg: #1e1e1e;
    --dm-card: #252525;
    --dm-text: #e5e7eb;
    --dm-muted: rgba(255, 255, 255, 0.7);
}
html.dark d-title.title-figure-layout .title-figure-row { background: var(--dm-bg); }
html.dark .model-card { background: var(--dm-card); color: var(--dm-text); }
html.dark .model-card .card-subtitle,
html.dark .model-card .card-section-title { color: var(--dm-muted); }
html.dark .model-card .card-text,
html.dark .model-card .card-line { color: rgba(255, 255, 255, 0.85); }
html.dark .card-badge-confidence { background: rgba(255, 255, 255, 0.2); color: rgba(255, 255, 255, 0.95); }
html.dark .card-badge-detail { background: rgba(255, 255, 255, 0.12); color: rgba(255, 255, 255, 0.9); }
html.dark .plot-hint,
html.dark .training-plot-inline-desc { color: var(--dm-muted); }
html.dark .note-box { background: #1c1c1c; border-left-color: #888; }
html.dark .note-box-title { color: #888; }
html.dark .note-box-content { color: #d4d4d4; }
html.dark .model-mention--task_domain { background: rgba(31, 119, 180, 0.25); border-color: rgba(31, 119, 180, 0.5); color: #7eb8e8; }
html.dark .model-mention--small { background: rgba(44, 160, 44, 0.25); border-color: rgba(44, 160, 44, 0.5); color: #7ee07e; }
html.dark .model-mention--medium { background: rgba(255, 127, 14, 0.25); border-color: rgba(255, 127, 14, 0.5); color: #ffb347; }
html.dark .model-mention--large { background: rgba(214, 39, 40, 0.25); border-color: rgba(214, 39, 40, 0.5); color: #f08080; }
html.dark .model-mention-tooltip { border-color: rgba(255, 255, 255, 0.15); background: rgba(28, 28, 28, 0.98); box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4); }
html.dark .tag-sage { background: rgba(168, 184, 153, 0.35); }
html.dark .tag-lavender { background: rgba(196, 181, 214, 0.35); }
html.dark .tag-peach { background: rgba(240, 212, 184, 0.35); }
html.dark .tag-rose { background: rgba(240, 196, 196, 0.35); }
html.dark .tag-lime { background: rgba(232, 240, 184, 0.35); }
html.dark .tag-neutral { background: rgba(96, 165, 250, 0.2); }
html.dark .callout { border-left-color: #7b9cdb; background: rgba(123, 156, 219, 0.12); }
html.dark h2.section-title,
html.dark h3.subsection-title { border-bottom-color: rgba(255, 255, 255, 0.15); }
