@media (prefers-color-scheme: dark) {
    body {
        background-color: black;
        color: #C9D1D9;
    }

    h1, h2, h3, h4, h5, h6, summary.raptor {
        color: #7f9edc;
    }

    details.raptor[open] {
        background-color: #0e0e0e;
        box-shadow: 3px 3px 4px #161616;
    }

    h1 {
        border-bottom: 2px solid #DADADA;
    }

    div.contents {
        background-color: #212121;
    }

    #titlearea {
        background-color: #090D16;
    }

    .footer {
        background-color: transparent;
    }

    /* code snippets */
    div.fragment {
        background-color: black;
        border: 1px solid #30363D;
    }

    /* inline code */
    code {
        background-color: black;
        border: 1px solid #30363D;
    }

    dl.attention {
        background-color: #292525;
    }

    dl.warning {
        border-color: #311f04;
        background-color: #FBF0E0;
    }

    dl.note {
        border-color: #E9DF24;
        background-color: #161614;
    }

    hr {
        border-top: 2px solid #E4E4E4;
    }

    /* markdown tables */
    table.markdownTable {
        border: 1px solid #283A5D;
    }

    table.markdownTable caption {
        color: #000;
    }

    table.markdownTable thead {
        background-color: #283A5D;
        color: #C4CFE5;
    }

    table.markdownTable td {
        border-bottom: 2px solid #283A5D;
    }

    table.markdownTable th {
        border-bottom: 2px solid #283A5D;
        background-color: #283A5D;
        color: #C4CFE5;
    }

    /* assignment box */
    div.assignment {
        background-color: #232527;
        border-left: 6px solid #2f436a;
    }

    /* solution box */
    div.solution {
        background-color: #819c79;
        border-left: 6px solid #408000;
        color: #354C7B;
    }

    /* Side nav bar styles: */
    #nav-tree .label a { /*default*/
        color: #90A5CE;
    }

    /* make all important pages bold */
    #nav-tree .label a[class^="modules"][class$="html"],
    #nav-tree .label a[class^="group"][class$="html"],
    #nav-tree .label a[class^="usergroup"][class$="html"],
    #nav-tree .label a[class^="namespace"][class$="html"],
    #nav-tree .label a[class="nolink"],
    #nav-tree .label a[class="annotated.html"],
    #nav-tree .label a[class="classes.html"],
    #nav-tree .label a[class^="functions"][class$="html"],
    #nav-tree .label a[class^="globals"][class$="html"],
    #nav-tree .label a[class="hierarchy.html"],
    #nav-tree .label a[class="index.html"],
    #nav-tree .label a[class="files.html"],
    #nav-tree .label a[class="concepts.html"],
    #nav-tree .label a[class="cookbook.html"] {
        color: #90A5CE;
    }

    #nav-tree .selected .label a,
    #nav-tree .selected .label a[class^="modules"][class$="html"],
    #nav-tree .selected .label a[class^="group"][class$="html"],
    #nav-tree .selected .label a[class^="usergroup"][class$="html"],
    #nav-tree .selected .label a[class^="namespace"][class$="html"],
    #nav-tree .selected .label a[class="nolink"],
    #nav-tree .selected .label a[class="annotated.html"],
    #nav-tree .selected .label a[class="classes.html"],
    #nav-tree .selected .label a[class^="functions"][class$="html"],
    #nav-tree .selected .label a[class^="globals"][class$="html"],
    #nav-tree .selected .label a[class="hierarchy.html"],
    #nav-tree .selected .label a[class="index.html"],
    #nav-tree .selected .label a[class="files.html"],
    #nav-tree .selected .label a[class="concepts.html"],
    #nav-tree .selected .label a[class="cookbook.html"] {
        color: #DCE2EF;
    }

    #nav-tree .selected{
        color: #DCE2EF;
        background-color: transparent;
    }

    /* add Concept and Class suffix */
    #nav-tree .label a[class^="concept"][class$="html"]::after {
        color: grey;
    }

    /* Remove suffix from Concept List */
    #nav-tree .label a[class^="concepts.html"]::after {
        color: grey;
    }

    #nav-tree .label a[class^="class"][class$="html"]::after,
    #nav-tree .label a[class^="struct"][class$="html"]::after {
        color: grey;
    }

    .mlabel.experimental-api
    {
        background-color: #826740;
        border-top: 1px solid #da8d00; /* darken(orange, 14.5) */
        border-left: 1px solid #da8d00; /* same as above */
        border-right: 1px solid #ffc965; /* lighten(orange, 40) */
        border-bottom: 1px solid #ffc965; /* same as above */
    }

    .mlabel.stable-api
    {
        background-color: #214a21;
        border-top: 1px solid #006d00; /* darken(green, 14.5) */
        border-left: 1px solid #006d00; /* same as above */
        border-right: 1px solid #00cc00; /* lighten(green, 20) */
        border-bottom: 1px solid #00cc00; /* same as above */
    }

    .mlabel.no-api
    {
        background-color: #692b2b;
        border-top: 1px solid #da0000; /* darken(red, 14.5) */
        border-left: 1px solid #da0000; /* same as above */
        border-right: 1px solid #ff9999; /* lighten(red, 60) */
        border-bottom: 1px solid #ff9999; /* same as above */
    }

    dl.stable-api {
        background-color: #214a21;
        border-color: #00D000;
    }

    dl.experimental-api {
        border-color: #E08D12;
        background-color: #826740;
    }

    dl.no-api {
        border-color: #FF0000;
        background-color: #692b2b;
    }

    .memtitle.no-api
    {
        background-color: #692b2b;
    }

    .memtitle.experimental-api
    {
        background-color: #826740;
    }
}
