@media screen and (forced-colors: none) {
    :root:not([data-theme]) {
        --default-chart-silver-dark: linear-gradient(180deg, #a6a6a6, #8c8c8c 48%, #747474 54%, #858585);
        --default-chart-silver: linear-gradient(180deg, #dedede, #c5c5c5 48%, #a5a5a5 54%, #b6b6b6);
        --default-chart-silver-light: linear-gradient(180deg, #f6f6f6, #e8e8e8 48%, #cbcbcb 54%, #dbdbdb);
        --default-table-heading: linear-gradient(180deg, #383838, #2c2c2c 52%, #252525);
    }

    /* Masthead, reading surfaces, and archive cards. */
    :root:not([data-theme]) .home-view-menu > [data-market-ticker] [data-market]:is(
        [data-market='platinum'], [data-market='palladium'], [data-market='nickel'],
        [data-market='aluminum'], [data-market='zinc'], [data-market='tin']
    ) {
        --price-texture: linear-gradient(115deg, var(--sw-line-bright), rgb(9 9 9 / 24%)),
            url('/assets/images/price-texture-silver.webp');
    }

    :root:not([data-theme]) .market-pulse__info .market-pulse__provenance {
        background: var(--sw-bg-raised);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) :is(.authors-grid .author-card, .institutional-section.institutional-contact) {
        background-color: var(--sw-bg-raised);
    }

    :root:not([data-theme]) :is(.intelligence-grid, .author-reporting) .post-card,
    :root:not([data-theme]) .related-intelligence article {
        background-color: color-mix(in srgb, var(--sw-bg-raised) 78%, transparent);
    }

    :root:not([data-theme]) :is(.post-card__media, .post-navigation > a) {
        background-color: var(--sw-bg-raised);
    }

    :root:not([data-theme]) :is(.article-layout > .article-content, .article-footer) {
        background-color: color-mix(in srgb, var(--sw-bg) 85%, transparent);
    }

    :root:not([data-theme]) .reading-tools__sources {
        background-color: var(--sw-bg);
        border-color: var(--sw-line);
    }

    :root:not([data-theme]) .reading-tools__count {
        border-color: var(--sw-line-bright);
        color: var(--sw-ink-soft);
    }

    :root:not([data-theme]) :is(.source-index, .source-index__empty, .source-index__close) {
        background: var(--sw-bg-raised);
        border-color: var(--sw-line);
    }

    :root:not([data-theme]) :is(.source-index__item, .source-index__footer) {
        border-top-color: var(--sw-line);
    }

    :root:not([data-theme]) .source-index__close:hover {
        background: var(--sw-panel-soft);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .article-content.gh-content blockquote {
        background: linear-gradient(115deg, rgb(210 210 210 / 7%), transparent 75%), var(--sw-bg-raised);
    }

    :root:not([data-theme]) .article-content.gh-content th {
        background-color: rgb(210 210 210 / 8%);
    }

    :root:not([data-theme]) .article-content.gh-content tbody tr:nth-child(even) {
        background-color: rgb(210 210 210 / 3%);
    }

    :root:not([data-theme]) .article-content.gh-content :is(tbody tr:hover, tfoot :is(th, td)) {
        background-color: rgb(210 210 210 / 7%);
    }

    :root:not([data-theme]) :is(#home-doom-line-panel, .home-doom-line .home-doom-line__header) {
        background-color: var(--sw-bg-raised);
    }

    :root:not([data-theme]) .jukebox-standby i {
        background:
            radial-gradient(circle, currentColor 0 3%, transparent 3.4% 12%, currentColor 12.4% 12.9%, transparent 13.4%),
            repeating-radial-gradient(circle, transparent 0 4px, rgb(222 222 222 / 20%) 4.5px 5px, transparent 5.5px 8px),
            radial-gradient(circle at center, var(--sw-bg), var(--sw-panel) 60%, var(--sw-bg) 74%);
        box-shadow: inset 0 0 0 1px currentColor, 0 0 42px rgb(202 202 202 / 10%);
    }

    /* Research charts, filters, and evidence cards. */
    :root:not([data-theme]) .research-body :is(
        .research-chain > li, .research-provenance, .website-audit__category, .website-audit__next-step
    ) {
        background-color: var(--sw-panel);
    }

    :root:not([data-theme]) .research-chain p {
        color: var(--sw-ink-soft);
    }

    :root:not([data-theme]) .website-audit [data-category='not-established'] {
        --audit-tone: var(--sw-ink-soft);
    }

    :root:not([data-theme]) .research-body .website-audit__next-step {
        border-inline-start-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) :is(.research-chart__track, .historical-track, .historical-stack) {
        background-color: var(--sw-panel-soft);
    }

    :root:not([data-theme]) .research-chart__track {
        border-inline-start-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .research-page .research-body :is(input, select, .historical-controls button, .website-audit__filters button) {
        background: var(--sw-bg-raised);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .historical-bars li {
        border-top-color: var(--sw-line);
    }

    :root:not([data-theme]) .research-body .historical-view {
        background: var(--sw-panel);
    }

    /* The figure templates set fills inline. Match those fills on both the bars and their legend swatches. */
    :root:not([data-theme]) :is(
        .research-chart__track > span, .research-chart__label > i, .historical-stack > i, .historical-legend i
    ):is([style$='background:#52697e' i], [style$='background:#596578' i], [style$='background:#8998a8' i]) {
        background: var(--default-chart-silver-dark) !important;
    }

    :root:not([data-theme]) :is(
        .research-chart__track > span, .research-chart__label > i, .historical-stack > i, .historical-legend i
    ):is(
        [style$='background:#687f91' i], [style$='background:#547d9b' i], [style$='background:#859aa8' i],
        [style$='background:#8498a8' i], [style$='background:#9aaab6' i], [style$='background:#7fb7c9' i]
    ) {
        background: var(--default-chart-silver) !important;
    }

    :root:not([data-theme]) :is(
        .research-chart__track > span, .research-chart__label > i, .historical-stack > i, .historical-legend i
    ):is(
        [style$='background:#aab6bf' i], [style$='background:#bdc8d0' i],
        [style$='background:#8c9fad' i], [style$='background:#a79acf' i]
    ) {
        background: var(--default-chart-silver-light) !important;
    }

    :root:not([data-theme]) .osint-case__bar-track i:not(.osint-case__bar-hybrid) {
        background: var(--default-chart-silver);
    }

    :root:not([data-theme]) :is(.historical-grid, .sia-gridline, .home-doom-line .doom-gsr__gridline) {
        stroke: var(--sw-line-bright);
    }

    :root:not([data-theme]) :is(.historical-line text, .sia-chart svg text, .home-doom-line .doom-gsr__axis) {
        fill: var(--sw-ink-soft);
    }

    :root:not([data-theme]) .home-doom-line .doom-gsr__line {
        stroke: var(--sw-ink);
    }

    :root:not([data-theme]) .sia-chart svg [stroke='#9da9b4'] {
        stroke: #c5c5c5;
    }

    :root:not([data-theme]) .sia-chart svg [fill='#9da9b4'] {
        fill: #c5c5c5;
    }

    :root:not([data-theme]) .sia-chart svg [fill='#11161b'] {
        fill: var(--sw-bg-raised);
    }

    :root:not([data-theme]) .sia-chart-legend i[style$='background:#9da9b4' i] {
        background: var(--default-chart-silver) !important;
    }

    :root:not([data-theme]) .sia {
        --sia-line: var(--sw-line);
    }

    :root:not([data-theme]) .sia :is(
        .sia-snapshot, .sia-finding, .sia-reader-brief, .sia-notice, .sia-chart, .sia-revision-example,
        .sia-source, .sia-cross-check, .sia-funding-snapshot, .sia-funding-focus, .sia-funding-governance,
        .sia-funding-check, .sia-ksg-totals > div, .sia-ksg-questions, .sia-module-grid > a
    ) {
        background: var(--sw-bg-raised);
    }

    :root:not([data-theme]) .sia :is(.sia-revision-example, .sia-timeline li, .sia-method-grid > div, .sia-institute-overview, .sia-officer) {
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .sia :is(
        .sia-key-finding, .sia-controls, .sia-module-grid > a:hover, .sia-module-nav a[aria-current='page'], .sia-table caption
    ) {
        background: var(--sw-panel);
    }

    :root:not([data-theme]) .sia :is(.sia-controls input, .sia-controls select, .sia-module-select select) {
        background: var(--sw-bg);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .sia :is(.sia-share-fallback, .sia-table tbody tr:nth-child(even)) {
        background: var(--sw-bg-raised);
    }

    :root:not([data-theme]) .sia .sia-table :is(th, td) {
        border-bottom-color: var(--sw-line);
    }

    :root:not([data-theme]) .sia .sia-table td {
        color: var(--sw-ink-soft);
    }

    :root:not([data-theme]) .sia .sia-table .sia-number {
        color: var(--sw-ink);
    }

    :root:not([data-theme]) :is(
        .research-data-table, .historical-table table, .historical-observations table,
        .sia .sia-table, .mineral-atlas__table-wrap table, .osint-case__table, .article-content.gh-content table
    ) > thead,
    :root[data-pale-eye-theme='default'] .pale-eye-page table > thead {
        background: var(--default-table-heading);
    }

    :root:not([data-theme]) :is(
        .research-data-table, .historical-table table, .historical-observations table,
        .sia .sia-table, .mineral-atlas__table-wrap table, .osint-case__table, .article-content.gh-content table
    ) > thead th,
    :root[data-pale-eye-theme='default'] .pale-eye-page table > thead th {
        background: transparent;
        color: var(--sw-ink, var(--pale-ink));
        border-bottom-color: var(--sw-line-bright, var(--pale-edge));
    }

    :root:not([data-theme]) .sia button {
        background-color: var(--sw-panel);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .sia button:not(:disabled):hover {
        background-color: var(--sw-panel-soft);
    }

    :root:not([data-theme]) .sia .sia-button--quiet:not(:hover) {
        background-color: transparent;
    }

    :root:not([data-theme]) .silver-standards__element {
        background: linear-gradient(140deg, var(--sw-line), var(--sw-bg-raised) 65%);
        border-color: var(--sw-line-bright);
        color: var(--sw-ink);
    }

    :root:not([data-theme]) :is(.silver-standards__lenses, .silver-standards__register) {
        background-color: var(--sw-bg-raised);
        border-color: var(--sw-line);
    }

    :root:not([data-theme]) :is(
        .silver-standards__register-heading, .silver-standards__controls,
        .silver-standards__results-bar, .silver-standards__key, .silver-standard
    ) {
        border-bottom-color: var(--sw-line);
    }

    :root:not([data-theme]) :is(.silver-standards__controls, .silver-standards__results-bar, .silver-standard[open]) {
        background-color: var(--sw-panel);
    }

    :root:not([data-theme]) .silver-standards__controls :is(input, select) {
        background: var(--sw-bg);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .silver-standards button,
    :root:not([data-theme]) .silver-standard__body > .silver-standard__qualification {
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .silver-standards button:not(:disabled):hover,
    :root:not([data-theme]) .silver-standard summary:hover {
        background: var(--sw-panel-soft);
    }

    /* Atlas controls and the frame around the map. */
    :root:not([data-theme]) :is(
        .mineral-atlas__workspace, .mineral-atlas__register, .mineral-atlas__summary,
        .mineral-atlas__zoom, .mineral-atlas__map-tip, .mineral-atlas__dialog
    ) {
        background: var(--sw-bg-raised);
        border-color: var(--sw-line);
    }

    :root:not([data-theme]) :is(
        .mineral-atlas__toolbar, .mineral-atlas__views, .mineral-atlas__searchbar, .mineral-atlas__status,
        .mineral-atlas__leaders, .mineral-atlas__notice, .mineral-atlas__record-grid, .mineral-atlas__record-footer
    ) {
        border-color: var(--sw-line);
    }

    :root:not([data-theme]) :is(.mineral-atlas__toolbar, .mineral-atlas__dialog-bar) {
        background: var(--sw-panel);
    }

    :root:not([data-theme]) .mineral-atlas__dialog-bar {
        border-bottom-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) :is(.mineral-atlas__dialog, .source-index)::backdrop {
        background: color-mix(in srgb, var(--sw-bg) 80%, transparent);
    }

    :root:not([data-theme]) .mineral-atlas__map-column {
        background: radial-gradient(ellipse at 52% 44%, var(--sw-panel-soft), var(--sw-bg) 80%);
    }

    :root:not([data-theme]) .mineral-atlas__metals button {
        background: var(--sw-bg-raised);
        border-right-color: var(--sw-line);
    }

    :root:not([data-theme]) .mineral-atlas__search input {
        background: var(--sw-bg);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .mineral-atlas__search button {
        background: var(--sw-panel-soft);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .mineral-atlas :is(
        .mineral-atlas__metals button, .mineral-atlas__views button, .mineral-atlas__search button,
        .mineral-atlas__zoom button, .mineral-atlas__leaders button, .mineral-atlas__dialog-bar button
    ):not(:disabled):hover {
        background: var(--sw-panel-soft);
    }

    :root:not([data-theme]) .mineral-atlas :is(.mineral-atlas__metals, .mineral-atlas__views) button[aria-pressed='true'] {
        background: var(--sw-line);
    }

    :root:not([data-theme]) .mineral-atlas__views button[aria-pressed='true'] {
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .mineral-atlas__table-wrap :is(th, td) {
        color: var(--sw-ink-soft);
        border-bottom-color: var(--sw-line);
    }

    :root:not([data-theme]) .mineral-atlas__table-wrap thead th,
    :root:not([data-theme]) .mineral-atlas__table-wrap td button {
        color: var(--sw-ink);
    }

    :root:not([data-theme]) .mineral-atlas__table-wrap td button {
        border-bottom-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .mineral-atlas__table-wrap:is(
        [data-table-mineral='silver'], [data-table-mineral='antimony'], [data-table-mineral='tungsten'],
        [data-table-mineral='cobalt'], [data-table-mineral='graphite']
    ) {
        --atlas-table-accent: var(--sw-warm);
    }

    :root:not([data-theme]) .mineral-atlas__table-wrap :is(caption, .is-total th, .is-total td) {
        color: var(--atlas-table-accent, var(--atlas-accent));
    }

    :root:not([data-theme]) .mineral-atlas__table-wrap .is-total :is(th, td) {
        border-top-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .mineral-atlas__zoom button {
        border-color: var(--sw-line);
    }

    /* Services, funding, and sponsor dossiers. */
    :root:not([data-theme]) .funding-router :is(.funding-controls, .funding-perspective, .funding-program:not(.funding-program--historic)) {
        background: var(--sw-bg-raised);
    }

    :root:not([data-theme]) .funding-router .funding-perspective__toggle button[aria-pressed='true'] {
        background-color: var(--sw-warm);
    }

    :root:not([data-theme]) :is(.osint-example, .osint-evidence, .pp-fieldnote) {
        background: linear-gradient(135deg, var(--sw-panel-soft), var(--sw-bg-raised));
    }

    :root:not([data-theme]) :is(.osint-contents-panel, .osint-case__chart) {
        background: var(--sw-bg-raised);
    }

    :root:not([data-theme]) .osint-example dl > div {
        border-top-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .osint-case__bar-track {
        background: var(--sw-panel-soft);
    }

    :root:not([data-theme]) .osint-button {
        background: linear-gradient(170deg, var(--sw-ink), #bcbcbc);
    }

    :root:not([data-theme]) .osint-button:hover {
        background: var(--sw-ink);
    }

    :root:not([data-theme]) .usas-dossier {
        --ag-line: var(--sw-line);
    }

    :root:not([data-theme]) .usas-materials {
        background:
            repeating-linear-gradient(0deg, transparent 0 39px, rgb(195 195 195 / 4%) 39px 40px),
            repeating-linear-gradient(90deg, transparent 0 39px, rgb(195 195 195 / 4%) 39px 40px),
            radial-gradient(ellipse at center, rgb(110 110 110 / 25%), transparent 70%),
            var(--sw-bg-raised);
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .usas-materials__pair > div {
        background: linear-gradient(125deg, #999, #e9e9e9 45%, #aaa);
        border-color: var(--sw-ink-soft);
        box-shadow: 8px 8px 0 rgb(190 190 190 / 7%);
        color: var(--sw-bg);
    }

    :root:not([data-theme]) .usas-materials__pair > div:last-child {
        background: linear-gradient(125deg, #777, #bcbcbc 45%, #8b8b8b);
    }

    :root:not([data-theme]) .usas-operation {
        background-color: var(--sw-bg-raised);
    }

    :root:not([data-theme]) .usas-operation--planned {
        background-color: var(--sw-bg);
    }

    :root:not([data-theme]) .usas-silver span {
        border-color: var(--sw-line-bright);
    }

    :root:not([data-theme]) .copper-defense__metal--silver {
        background: linear-gradient(120deg, rgb(192 192 192 / 8%), transparent 75%), var(--sw-bg-raised);
        border-color: var(--sw-line);
    }

    :root:not([data-theme]) .copper-defense__metal--silver .copper-defense__symbol {
        border-color: var(--sw-line-bright);
    }

    /* Embedded Pale Eye uses the same Default palette with its own theme attribute. */
    :root[data-pale-eye-theme='default'] .pale-eye-page :is(.masthead, .workspace, .console-intro) button:not(
        .company, .mintage-coin-thumbnails, .equity-heatmap__tile
    ) {
        --button-silver: linear-gradient(112deg, #3b3b3b, #595959 32%, #505050 66%, #3e3e3e);
        background-color: #4c4c4c;
        border-color: var(--pale-edge);
    }

    :root[data-pale-eye-theme='default'] .pale-eye-page :is(.masthead, .workspace, .console-intro) button:not(
        .company, .mintage-coin-thumbnails, .equity-heatmap__tile, :disabled
    ):hover {
        --button-silver: linear-gradient(112deg, #4c4c4c, #5f5f5f 32%, #595959 66%, #464646);
        border-color: var(--pale-muted);
    }

    :root[data-pale-eye-theme='default'] .pale-eye-page :is(.masthead, .workspace, .console-intro) :is(
        button:not(.company):is([aria-pressed='true'], [aria-selected='true'], [aria-expanded='true']),
        th:is([aria-sort='ascending'], [aria-sort='descending']) > button
    ) {
        --button-silver: linear-gradient(112deg, #535353, #656565 32%, #606060 66%, #4f4f4f);
        background-color: #5e5e5e;
        border-color: var(--pale-muted);
        border-inline-start-color: var(--pale-phosphor);
    }

    :root[data-pale-eye-theme='default'] .pale-eye-page .workspace .terminal-menu__buttons button {
        --view-plate-tint: color-mix(in srgb, var(--pale-phosphor) 23%, var(--pale-panel));
        background-color: var(--view-plate-tint);
        background-blend-mode: normal, luminosity;
    }

    :root[data-pale-eye-theme='default'] .equity-heatmap {
        --heatmap-flat: #3e3e3e;
        --heatmap-missing: #343434;
    }
}

@media screen and (forced-colors: none) and (max-width: 900px) {
    :root:not([data-theme]) .sia-module-sidebar {
        background: var(--sw-bg-raised);
    }
}
