.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100%;
    font-family: sans-serif !important;
    background-color: white;
    overflow: hidden;
    z-index: 1049;
}

.dropdown {
    color: var(--principal_blue) !important;
    background-color: white !important;
    font-weight: bold;
}

.sidebar-first-item {
    color: white;
    background-color: var(--secondary_blue) !important;
    text-decoration: none !important;
    font-size: 20px;
    font-weight: bold;
    height: 65px;
}
  
.sidebar-first-item>label {
    padding-top: 1em;
    padding-left: 1em;
    padding-bottom: 1em;
    margin-bottom: 0;
}

.sidebar-first-item .Select-control, .sidebar-first-item .Select-control .Select-multi-value-wrapper .Select-input {
    background-color: var(--principal_blue) !important;
    color: grey;
    font-weight: bold;
    height: 2rem !important;
    margin-top: 0;
    padding-top: 0;
    border-radius: 0px;
    border: none;
    box-shadow: none !important;
}

#app-sidebar>label {
    color: #8A959F;
}

.sidebar .card-header {
    padding-left: .5rem;
    padding-right: 0px;
}

.sidebar-item {
    height: 2rem;
    margin: 1rem 0;
}

.sidebar-item>label {
    height: 1.5rem;
}

.sidebar-item>button {
    height: 2rem;
    display: table-cell;
    outline: none;
    text-align: left;
    text-decoration: none !important;
    vertical-align: middle;
    margin-bottom: .6rem;
}

.sidebar-item>button:hover, .sidebar-item>button:focus {
    color: var(--principal_blue);
}

#variable-dropdown-forecast div.Select-menu-outer .Select-menu {
    height: auto !important;
    background-color: var(--principal_blue) !important;
}

.sidebar-dropdown {
    max-height: 46vh;
    overflow-y: auto;
    overflow-x: hidden;
    color: var(--light_grey);
}

.sidebar-dropdown>label {
    display: block;
    margin-left: 0.5rem;
    margin-bottom: 1rem;
    font-size: 14px;
}

.sidebar-dropdown label:last-of-type {
    margin-bottom: 0 !important;
}

.sidebar>label {
    margin-left: 1rem;
    margin-top: 0.5rem;
    display: block;
}

/* Custom control: Classes recently added by Francesco */
.form-check {
    display: flex;
    flex-direction: row-reverse;
    justify-content: space-between;
    padding-left: 0;
    padding-right: 0.2rem;
}

.form-check-label {
    /* margin-left: 1rem; */
    margin-top: 0.1rem;
    display: block;
    font-size: small;
}

.form-check-label::before,
.form-check-label::after {
    left: unset;
    right: 0.5rem;
    float: right;
    vertical-align: top;
}
/* --- */

.sidebar-dropdown>label>input[type=checkbox] {
    float: right;
    vertical-align: bottom;
    /*
    margin-right: 1rem !important;
    margin-top: 0.6rem;
    */
}

.sidebar-dropdown>label>input[type=radio] {
    float: right;
    vertical-align: bottom;
}

.sidebar-dropdown>label>input[type=radio]{
    accent-color: var(--principal_blue) !important;
}

.card-header {
    display: block;
    background-color: white;
    border-bottom: none;
}

.card-header>h2>button.btn-link {
    white-space: normal;
    float: left !important;
    text-align: left !important;
    display: block;
    width: 100%;
    text-decoration: none;
}

/* .card-header>h2>button.btn-link:hover {
    text-decoration: underline;
} */

.card {
    border-top: none;
    border-bottom: none;
}

/*.accordion>.card>.card-header:after {
    display: inline-block;
    font-variant: normal;
    text-rendering: auto;
    -webkit-font-smoothing: antialiased;
    font-family: "Font Awesome 5 Brands","Font Awesome 5 Free";
    font-size: 15px;
    font-weight: 900;
    font-style: normal;
    content: "\f107";
    float: right;
    color: grey;
}*/

.accordion>.card>.card-header[aria-expanded="true"]:after {
    display: inline-block;
    font-variant: normal;
    text-rendering: auto;
    -webkit-font-smoothing: antialiased;
    font-family: "Font Awesome 5 Brands","Font Awesome 5 Free";
    font-size: 15px;
    font-weight: 900;
    font-style: normal;
    content: "\f107";
    float: right;
    color: grey;
}

.accordion .card {
    border-radius: 0;
    border-right: 0;
}

.sidebar-bottom {
    position: fixed;
    width: inherit;
    margin: 0;
    padding: 0;
    bottom: 0px;
    z-index: 1002 !important;
    border-right: 1px solid var(--dark_grey);
}

/* Info button on the sidebar bottom */
.sidebar-bottom #info-button {
    background-image: url("./images/icons/Icon_Info.svg");
    background-position: center;
    width: 100%;
    height: 55px;
    background-color: var(--principal_blue);
    border: none !important;
}

.sidebar-bottom #info-button:hover {
    background-image: url("./images/icons/Icon_Info_Lime_L.svg");
}

/* Download button on the sidebar bottom */
.sidebar-bottom #download-button {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-content: space-around;
    background-image: url("./images/icons/Icon_Download.svg");
    background-position: 13% 50%;
    background-color: var(--secondary_blue);
    border: none !important;
    width: 100%;
    height: 50px;
    color: white;
    padding-top: 0.6rem;
    padding-left: 2.5rem;
}

.sidebar-bottom #download-button:hover {
    background-image: url("./images/icons/Icon_Download_Lime.svg");
    color: var(--lime);
}

.sidebar-bottom .btn {
    border-radius: 0;
    background-repeat: no-repeat;
    height: 10px;
    font-size: Medium;
    margin: 0 !important;
    width: -moz-fit-content;
    width: fit-content;
}

.sidebar-bottom .card-text>.download-section {
    background-image: url("./images/icons/Icon_Download.svg");
    background-repeat: no-repeat;
    background-position: 0.5rem;
    /* background-color: var(--principal_blue) !important; */
    background-color: var(--secondary_blue) !important;
    display: block;
    width: 98%;
    height: 33px;
    margin-top: 1rem !important;
    margin-bottom: 1rem !important;
    padding-left: 1rem !important;
    text-align: center;
    font-size: medium;
    color: white;
    border: 2px solid var(--secondary_blue) !important;
    text-decoration: none;
}

.sidebar-bottom .card-text>.download-section:hover {
    color: var(--lime);
    background-image: url("./images/icons/Icon_Download_Lime.svg");
}

.sidebar-bottom .card-text>.download-section:active {
    color: white;
    font-weight: bold;
}

.sidebar-bottom .card-text>p>a {
    color: var(--principal_blue);
    text-decoration: none;
}

.collapsible-cards {
    margin: 0 !important;
}
.collapsible-cards .col {
    margin: 0 !important;
    padding: 0 !important;
}

.collapsible-cards .col .collapse .card, 
.collapsible-cards .col .collapsing .card {
    margin: 0 !important;
    padding: 0 !important;
    border: none;
}

.collapsible-cards .col .collapse .card .card-body, 
.collapsible-cards .col .collapsing .card .card-body {
    overflow: auto;
    font-size: Small;
}

.card-body {
    padding-bottom: 1rem;
    padding-left: 1rem;
    padding-right: 1rem;
    padding-top: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.175) !important;
    border-left: none;
    border-right: none;
}

.sidebar-bottom .card-body {
    padding-top: 1rem !important;
}

.card:not(:first-child) .card-body {
    border-bottom: none !important;
}

.card {
    border-left: none;
}

.caret-span {
    color: #212529;
    font-size: 1.3em;
    font-weight: bold;
    position: absolute;
    right: 0;
    top: .0em;
    right: .5em;
}

.caret-span-closed{
    color: #212529;
    position: absolute;
    right: .5em; 
    font-size: 1.3em;
    font-weight: bold;
    transform: rotate(180deg);
    -ms-transform: rotate(180deg);
    -webkit-transform: rotate(180deg);
}

#group-1-toggle span, #group-2-toggle span {
    /* top: .15rem; */
    display: none;
}

.Select-arrow-zone {
    bottom: .3em;
    right: .5em;
    color: #212529;
}

/* overide dash default dropdown arrow*/
.Select-arrow {
    visibility: hidden;
}

/* Step 1: Common Properties
These styles are required to make icons render reliably */
.icon::after {
    display: inline-block;
    text-rendering: auto;
    -webkit-font-smoothing: antialiased;
}


/*style new caret arrow*/
.Select-arrow:after {
    display: inline-block;
    position: relative;
    visibility: visible;
    font-family: 'Font Awesome 5 free';
    font: var(-fa-font-solid);/*only one hyphen at beginning to function*/
    content: "\f106";
    font-weight: 900;
    vertical-align:middle;
    font-size: 1.1em;
    transform: rotate(180deg);
    -ms-transform: rotate(180deg);
    -webkit-transform: rotate(180deg);
}

/*rotate new caret*/
.is-open > .Select-control .Select-arrow:after {
    display:inherit;
    top: .2em;
    transform: rotate(0deg);
    -ms-transform: rotate(0deg);
    -webkit-transform: rotate(0deg);
}

/* Remove icon on the bottom right corner */
.js-plotly-plot .plotly .mapboxgl-ctrl-bottom-right {
    display: none !important;
}


/* Page content. The value of the margin-left property should match the value of the sidebar's width property */
div.tab-parent {
    position: fixed;
    width: 100%;
    margin-left: 280px;
    height: 100%;
    top: 0;
    bottom: 0;
}

/* On screens that are less than 700px wide, make the sidebar into a topbar */
/* @media screen and (max-width: 700px) { */
/*   .sidebar { */
/*     width: 100%; */
/*     height: auto; */
/*     position: relative; */
/*   } */
/*   .sidebar a {float: left;} */
/*   div.content {margin-left: 0;} */
/* } */
/**/

/* On screens that are less than 400px, display the bar vertically, instead of horizontally */
@media screen and (max-width: 400px) {
    .sidebar a {
        text-align: center;
        float: none;
    }
}

/* Decrease sizes in layout when resolution is too high */
@media (min-resolution: 120dpi) {
    .sidebar-dropdown>label {
        font-size: 70%;
    }

    .sidebar {
        width: 230px;
    }

    div.tab-parent {
        margin-left: 230px;
    }

    .sidebar-first-item>label {
        font-size: 95%;
    }

    .sidebar-bottom #download-button {
        font-size: 80%;
    }
}