/*
 * This file contains color customizations that follow OpenAMP branding
 * This file was originally copied from the Zephyr project and modified
 * The original copyright and license are maintained below
 *
 * Copyright (c) 2021 Nordic Semiconductor ASA
 * Copyright (c) 2023 Linaro Ltd
 * SPDX-License-Identifier: Apache-2.0
 */

html {
    --primary-color: #e86060;
    --primary-dark-color: #d04040;
    --primary-light-color: #c0c0c0;
    --primary-lighter-color: #e0e0e0;
    --primary-lightest-color: #f0f0f0;

    --side-nav-background: #343131;
    --side-nav-foreground: #c0c0c0;

    --searchbar-background: var(--page-background-color);
    --searchbar-foreground: var(--page-foreground-color);

    --link-color: #2980b9;
    --param-color: #b71c1c;

    --side-nav-fixed-width: 300px;
    --top-height: 280px;
}

@media (prefers-color-scheme: dark) {
    html:not(.light-mode) {
        color-scheme: dark;

        --primary-color: #af7fe4;
        --primary-dark-color: #cb99f6;
        --primary-light-color: #7929d2;
        --primary-lighter-color: #191e21;
        --primary-lightest-color: #191a1c;

        --side-nav-background: #343131;
        --side-nav-foreground: var(--page-foreground-color);

        --param-color: #ef9a9a;
    }
}

html.dark-mode {
    color-scheme: dark;

    --primary-color: #e86060;
    --primary-dark-color: #d04040;
    --primary-light-color: #707070;
    --primary-lighter-color: #191e21;
    --primary-lightest-color: #191a1c;

    --side-nav-background: #343131;
    --side-nav-foreground: var(--page-foreground-color);

    --param-color: #ef9a9a;
}

a:link, a:visited, a:hover, a:focus, a:active {
    color: var(--link-color) !important;
}

.paramname {
    color: var(--param-color);
}

dl.section dd, dl.bug dd, dl.deprecated dd {
    margin-inline-start: revert;
}

/* adjust top and title to ~match Sphinx docs */
#top {
    background: var(--side-nav-background);
    background-image: url("triangle_background.png");
}

#titlearea {
    padding-bottom: 0;
}

#titlearea table {
    width: 100%;
}

#projectlogo img {
    width:  150px;
    height: 150px;
    max-height: none !important;
    padding-top: 12px;
}

#projectalign {
    display: none;
}

@media screen and (min-width: 767px) {
    #doc-content {
        padding-top: calc(var(--top-height) - 220px);
    }
}

/* style for re-injected version */
#projectversion {
    color: var(--side-nav-foreground);
    padding-top: 25px;
    text-align: center;
    color: #ffffff;
}

#nav-sync {
    visibility: hidden;
}
