:root {
    --primary-color: #6B70AC;
    --secondary-color: #C0BBF6;
    --onyx: #343E3D;
    --green: #B7E2C1;
    --background-rgb: 227, 215, 255;
    --onyx-rgb: 52, 62, 61;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

body {
    font-family: "Roboto", system-ui;
    font-weight: 400;
    font-style: normal;
    color: var(--onyx);
    margin: 0;
}

button {
    padding: 5px 15px;
    font-family: "Roboto", system-ui;
    font-weight: 400;
    font-style: normal;
}

a {
    text-decoration: none;

    img {
        width: 2em;
    }
}

.header {
    padding: 1em;
    background-color: var(--primary-color);

    a {
        color: white;
        margin: 0 1em;
        width: max-content;
    }

    button {
        color: white;
        font-weight: bold;
        background-color: var(--primary-color);
        vertical-align: inherit;
    }

    .logo img {
        width: 50%;
        display: inline-block;
        height: 100%;
        vertical-align: middle;
    }
}

h2 {
    color: var(--primary-color);
}

.modal-body {
    button {
        background-color: var(--primary-color);
        padding-left: 2.5em;
        padding-right: 2.5em;
    }

    a {
        color: var(--primary-color);
    }

    .lead {
        margin-bottom: 0.5rem;
    }

    input {
        border: solid 1px var(--primary-color);
    }
}

.modal-header {
    color: var(--primary-color);
}

.modal-content {
    width: 80%;
}

.modal-dialog-centered {
    justify-content: space-evenly;
}

a:hover {
    font-weight: bold;
    text-decoration: underline;
}

button:hover {
    background-color: var(--secondary-color);
    color: white;
}

button:focus {
    background-color: var(--secondary-color);
    color: white;
}

.btn:focus {
    box-shadow: none;
}

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
}

.shadow {
    box-shadow: 5px 2px 10px rgba(0, 0, 0, .15);
}

#your_data_form {
    input {
        font-size: 1.5em;
        line-height: 0;
        max-width: 4em;
    }

    input:focus{
        outline: none;
    }

    span {
        color: var(--primary-color);
        display: flex;
        align-items: center;
        padding-left: .25em;
    }

    label {
        margin: 0;
    }
}

.card_section {
    background-color: rgba(var(--background-rgb), 0.75);
}

.money_input {
    height: fit-content;

    span {
        color: var(--primary-color);
    }

    input {
        width: 4em;
        min-width: 4em;
        max-width: 10em;
        text-align: right;
    }
}

.percent_input {
    height: fit-content;
    display: inline-block;

    span {
        color: var(--primary-color);
    }

    input {
        width: 2.5em;
        text-align: right;
    }
}

.age_input {
    height: fit-content;
    display: inline-block;

    span {
        color: var(--primary-color);
    }

    input {
        width: 2em;
        text-align: right;
    }
}

input[type="radio"] {
    width: 0;
    height: 0;
}

input[type="radio"]:checked+label  {
    background: var(--primary-color);
    color: white;
}

input[type="radio"]:focus+label  {
    background: var(--primary-color);
    color: white;
    outline: solid 1px black;
}

input[type="radio"]+label {
    text-align: center;
    border: 2px solid var(--primary-color);
    cursor: pointer;
    color: var(--primary-color);
    font-weight: bold;
    display: inline-block;
    margin-bottom: 0;
}

input[type="radio"]:not(:checked)+label:hover {
    background: var(--secondary-color);
    color: white;
}

.tooltip-inner {
    background-color: white;
    color: var(--onyx);
    box-shadow: 5px 5px 8px rgba(0, 0, 0, .15);
}

.tooltip.show {
    opacity: 1;
}

.tooltip .arrow::before {
    display: none;
}

.add_button, .add_button_span, .new_user {
    background-color: transparent;
    color: var(--primary-color);
    font-weight: bold;
}

#data_break {
    width: 0;
}

.additional_card_header {
    border: none;
    font-size: 1.15rem;
    font-weight: 500;
    text-align: center;
    margin-bottom: 0.5rem;
    resize: none;
    height: 1.75em;
    overflow: hidden;
    width: 90%;
}

#scenario_title {
    color: var(--primary-color);
    border: none;
    font-size: 2.25rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    line-height: 1.2;
    padding: 0;
    width: 80%;
    text-overflow:ellipsis
}

.card_menu {
    position: absolute;
    right: 25px;
    cursor: pointer;
}

.card_menu_popup {
    position: relative;
    right: 0;
    cursor: pointer;
}

.inflation_switcher {
    height: 1.5em;
}

#income_card form:first-of-type {
    min-height: 17em;
    display: flex;
    flex-direction: column;
    justify-content: space-between;

    .additional_card_header {
        width: 90%;
        margin-right: auto;
        margin-left: auto;
    }
}

#default_income_after_free {
    display: flex;
    align-items: center;
    height: 17em;
    cursor: pointer;
    justify-content: center;

    &.hidden {
        display: none;
    }
}

#scenario {
    margin-left: 5em;
    margin-right: 5em;
}

#menu_toggle {
    cursor: pointer;
    padding: 10px 10px 5px 10px;
    border-radius: .25rem;
    top: 82px;
    left: 5px;

    display: block;
    position: absolute;

    z-index: 1;

    -webkit-user-select: none;
    user-select: none;

    ::-webkit-scrollbar {
        display: none;
    }

    ::-webkit-scrollbar-track {
        display: none;
    }

    ::-webkit-scrollbar-thumb {
        display: none;
    }
}

#menu_toggle:hover {
    background-color: var(--secondary-color);
}

#menu {
    position: absolute;
    width: 300px;
    height: 100vh;
    margin: -46px 0 0 -25px;
    padding: 25px 0 100px 25px;
    text-align: left;

    background: var(--secondary-color);
    color: var(--onyx);
    list-style-type: none;
    -webkit-font-smoothing: antialiased;

    transform-origin: 0 0;
    transform: translate(-100%, 0);

    transition: transform 0.5s cubic-bezier(0.77, 0.2, 0.05, 1.0);
    z-index: 3;
    overflow: scroll;

    h3 {
        margin-bottom: 10px;
        font-weight: bold;
    }

    h5 {
        margin: 0;
        font-weight: bold;

        li {
            overflow: hidden;
            width: 210px;
            white-space: nowrap;
            text-overflow: ellipsis;
        }
    }

    div.scenario_hover {
        cursor: pointer;
        padding: 10px;
        border-radius: 5px 0 0 5px;
    }

    div.scenario_hover:hover {
        background-color: var(--primary-color);
        color: white;

        img {
            filter: brightness(0) saturate(100%) invert(100%) sepia(100%) saturate(1%) hue-rotate(79deg) brightness(102%) contrast(102%);
        }
    }

    p {
        font-size: 0.75rem;
        margin: 0;
    }

    img {
        margin-right: 10px;
        filter: brightness(0) saturate(100%) invert(21%) sepia(4%) saturate(1460%) hue-rotate(125deg) brightness(92%) contrast(87%);
    }

    .selected {
        background-color: white;
        color: var(--primary-color);

        img {
            filter: brightness(0) saturate(100%) invert(48%) sepia(22%) saturate(957%) hue-rotate(198deg) brightness(88%) contrast(81%);
        }
    }

    .card_menu {
        right: 0;
    }
}

#menu_toggle input {
    display: block;
    width: 55px;
    height: 45px;
    position: absolute;
    top: -1px;
    left: -1px;

    cursor: pointer;

    opacity: 0;
    z-index: 2;

    -webkit-touch-callout: none;
}

#menu_toggle span {
    display: block;
    width: 35px;
    height: 4px;
    margin-bottom: 6px;
    position: relative;

    background: var(--primary-color);
    border-radius: 3px;

    z-index: 1;

    transform-origin: 4px 0px;
}

#menu_toggle input:checked ~ ul {
    transform: none;
}

.save, .download, .download_users {
    cursor: pointer;
}

.generated_data p.banner_values {
    font-weight: bold;
    font-size: 1.5em;
}

.green p.banner_values {
    color: #00610A;
}

.yellow p.banner_values {
    color: #E2C114;
}

.red p.banner_values {
    color: #EB0909;
}

#table_graph {
    position: relative;
    overflow: scroll;
    height: 22em;

    th {
        color: var(--primary-color);
        padding: 5px 10px;
        position: sticky;
        top: 0;
        background-color: white;
        font-size: 1.4em;
    }

    th:after {
        content: '';
        position: absolute;
        left: 0;
        width: 100%;
        bottom: -1px;
        border-bottom: 2px solid var(--primary-color);
    }

    td {
        border-bottom: 1px solid black;
        padding: 5px 10px;
        font-size: 1.15em;
    }

    #last_saved {
        display: block;
        width: 100%;
        background: white;
        position: sticky;
        text-align: right;
        bottom: 0;
        left: 0;
        margin: 0;
        font-size: .8em;
        z-index: 10;
    }
}

.apexcharts-tooltip {
    text-align: left;
    padding: 0.75em;
}

#view_selection_switcher {
    input[type="radio"]:checked+label  {
        img {
            width: 25px;
            height: 25px;
            filter: invert(98%) sepia(55%) saturate(2%) hue-rotate(202deg) brightness(111%) contrast(100%);
        }
    }

    input[type="radio"]:not(:checked)+label {
        img {
            width: 25px;
            height: 25px;
            filter: invert(48%) sepia(22%) saturate(957%) hue-rotate(198deg) brightness(88%) contrast(81%);
        }
    }
}

#admin_users_list {
    margin-left: 5em;
    margin-right: 5em;

    ul {
        list-style: none;
    }

    a {
        color: var(--primary-color);
    }
}

.page-item.active .page-link {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

#resend_otp {
    color: var(--primary-color);
    text-decoration: underline;
    cursor: pointer;
}

.blue_shading {
    background-color: rgba(var(--background-rgb), 0.75);
}

.onyx_shading {
    background-color: rgba(var(--onyx-rgb), 0.20);
}

a img.download_users {
    width: 2em;
}

footer {
    font-size: 0.85em;
    margin-top: 200px;
    padding: 2em;
    background-color: rgba(var(--background-rgb), 0.75);

    h6 {
        font-weight: 700;
    }

    a {
        text-decoration: underline;
    }
}

.notification_alert {
    display: none;
    width: max-content;
    float: right;
    margin: 1em;
    position: sticky;
    bottom: 1em;
    z-index: 100;

    .lead {
        margin: 0;
    }
}

#your_data_form input:placeholder-shown, #lifestyle_expense input:placeholder-shown, #savings_investment input:placeholder-shown {
    background: var(--green);
    border-radius: .25rem;
}

#welcome img {
    padding-left: 2.5rem
}

@keyframes grow {
    from {
        transform: scale(1);
    }
    to {
        transform: scale(1.5);
    }
}

.grow {
    animation: grow 0.5s ease;
    animation-duration: 1s;
    animation-iteration-count: 6;
    animation-direction: alternate;
    animation-delay: 3s;
}

.btn:disabled {
    background-color:  grey;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 .2rem rgba(var(--background-rgb), 0.75);
}

.drag_and_drop {
    display: none;
}

@media print {
    #chart_download, #table {
        display: block !important;
        padding-bottom: 3em;
    }

    #table_graph {
        height: auto;
    }

    .sub_header, .save, .download, #view_selection_switcher, #chart, #card_section_switcher {
        display: none !important;
    }

    .logo {
        text-align: left;
    }

    .header, .table_graph {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .card_section h2 {
        font-size: 1.5rem;
    }

    .page_break {
        page-break-before: always;
    }

    #scenario_title {
        width: 100%;
    }
}
