:root {
    --bright-background: #FFFFFF;
    --background: #F4F4F4;
    --dark-background: #D9D9D9;
    --darker-background: #BBBCBC;
    --black: #212121;
    --dark-grey: #63666A;
    --grey: #888B8D;
    --red: #C8102E;
    --blue: #00B5E2;
    --green: #6CC24A;
    --yellow: #FFF200;
}

.imageDropZone {
    border: dotted var(--dark-grey);
    align-items: center;
    width: 100%;
}

.imageDropZone .center {
    margin: 5px auto;
    align-items: center;
    text-align: center;
    display: grid;
}

.allowDrop {
    background: var(--dark-background);
}

/* Reset browser defaults */
* {
    box-sizing: border-box;
    color: var(--black);
}

html {
    height: 100%;
}

body {
    display: flex;
    height: 100%;
    background-color: var(--background);
}

ul, form, li, html, body, h1, h2, h3, img, button {
    margin: 0;
    padding: 0;
    border-width: 0;
    /*! background-color: transparent; */
}

canvas {
    width: 100%;
    height: 100%;
    display: block;
    position: absolute;
}

table {
    border-spacing: 5px;
}

#PageContent {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 800px;
    flex-grow: 1;
    min-width: 1240px;
    line-height: 1.42857143;
}

a {
    color: var(--dark-grey);
}

    a:link {
        color: var(--dark-grey);
    }

    a:visited {
        color: var(--dark-grey);
    }

    a:hover {
        color: var(--blue);
        cursor: pointer;
        text-decoration: underline;
    }

.page-header {
    height: 105px;
    min-height: 105px;
    width: 100%;
    display: flex;
    background-color: var(--bright-background);
    border-bottom: 4px solid var(--red);
}

ul.message-list {
    margin-left: 20px;
}

.page-body {
    width: 100%;
    height: 100%;
    flex-grow: 1;
    background-color: var(--background);
    min-height: 750px;
    min-width: 800px;
}

.page-footer {
    flex-basis: 40px;
    width: 100%;
    background-color: var(--dark-background);
    border-top: 1px solid var(--dark-grey);
}

.page-error {
    padding: 50px;
    font-size: 5em;
    font-weight: bold;
}

.page-warning {
    padding: 50px;
    font-size: 4em;
}

.reload-icon {
    background-image: url('../Images/Reload.png');
    background-repeat: no-repeat;
    background-color: transparent;
    background-size: 18px 18px;
    width: 20px;
    height: 20px;
    padding: 2px;
    margin: 2px;
    margin-left: 5px;
    float: right;
    position: relative;
    pointer-events: painted;
    cursor: pointer;
}

.header-left {
        display: flex;
    margin-right: 16px;
}

    .header-left .brand {
        display: flex;
    }

        .header-left .brand .bar {
            margin: 26.25px 0;
            height: 52.5px;
            width: 1px;
            background-color: var(--dark-grey);
        }

        .header-left .brand .ds-logo {
            margin: 26.25px;
            height: 52.5px;
            aspect-ratio: 4;
            background-size: contain;
            background-repeat: no-repeat;
            background-image: url("../Images/DPS_Logo.jpg");
        }

        .header-left .brand .product {
            margin: 26.25px 10px 26.25px 26.25px;
            height: 49.5px;
            padding-top: 3px;
        }

            .header-left .brand .product .mf-headline {
                font-family: Arial, sans-serif;
                font-weight: bold;
                color: var(--dark-grey);
            }

            .header-left .brand .product .mf-subheadline {
                font-family: Arial, sans-serif;
                color: var(--grey);
                font-size: 13px;
                white-space: pre;
            }

.header-center {
    display: flex;
    flex-grow: 1;
    align-items: center;
    padding-left: 10px;
    border-left: 1px solid var(--dark-grey);
}

    .header-center table td:first-of-type {
        min-width: 140px;
    }

.header-center table td {
        max-width: 280px;
    }

.header-right {
    width: 490px;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    padding: 10px;
    justify-items: center;
    align-items: center;
    justify-content: space-evenly;
}

    .header-right td {
        padding: 10px;
    }

.red {
    color: var(--red);
}

.green {
    color: var(--green);
}

.header-right .account-menu {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    position: absolute;
    background-color: var(--bright-background);
    padding: 3px 15px 10px 5px;
    z-index: 500;
    -webkit-box-shadow: 2px 2px 5px 2px rgba(196,196,196,0.65);
    -moz-box-shadow: 2px 2px 5px 2px rgba(196,196,196,0.65);
    box-shadow: 2px 2px 5px 2px rgba(196,196,196,0.65);
}

    .header-right .account-menu a {
        margin-top: 7px;
    }

#EditInformationOverlay .edit-information {
    display: flex;
    flex-direction: row;
    margin-top: 20px;
}

#EditInformationOverlay .edit-col {
    width: 50%;
}

#EditInformationOverlay .edit-grid {
    padding: 20px 20px 0 0;
    justify-content: space-evenly;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    grid-gap: 10px;
}

#EditPasswordOverlay .edit-password {
    display: grid;
    grid-template-columns: 1fr 2fr;
    grid-gap: 10px;
}

#EditPreferencesOverlay .edit-preferences {
    display: flex;
    flex-direction: column;
    padding: 10px;
}

.footer-left {
    padding-left: 10px;
}

.noselect {
    -webkit-user-select: none;
    -moz-user-select: none;
    user-select: none;
}

/* -------------------------------- Overlay Dialogs ---------------------------------- */

.BackgroundFader {
    /*display: none;*/
    width: 100%;
    height: 100%;
    position: fixed;
    /* ReSharper disable once RequiresFallbackColor */
    background: rgba(0, 0, 0, 0.65);
    z-index: 1000;
}

#AjaxAnimation {
    /*display: none;*/
    position: absolute;
    z-index: 1003;
    top: calc(50% - 90px);
    left: calc(50% - 50px);
    left: 50%;
    margin-top: -1px;
    margin-left: -1px;
    height: 180px;
    aspect-ratio: 2.34;
    background-image: url('../Images/infinite-loop.gif');
    background-size: contain;
    background-repeat: no-repeat;
}

#MessageBox {
    z-index: 1001;
}

#SessionTimeoutOverlay {
    z-index: 1002;
}

.dialog {
    width: 100%;
    height: 100%;
    position: fixed;
    /* ReSharper disable once RequiresFallbackColor */
    background: rgba(0, 0, 0, 0.50);
    z-index: 700;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

    .dialog h1 {
        padding-top: 10px;
        padding-bottom: 10px;
    }

.dialog-content {
    position: absolute;
    box-shadow: 0 0 5px 3px rgba(0, 0, 0, 0.15);
    border-radius: 5px;
    z-index: 701;
    padding: 22px;
    background-color: var(--bright-background);
    min-width: 500px;
    max-height: 90%;
    overflow: auto;
    width: 80%;
}

    .dialog-content .row {
        margin-top: 30px;
        display: flex;
        flex-direction: row;
        justify-content: space-around;
    }

        .dialog-content .row input[type=button] {
            width: 25%;
        }

.dialog .dialog-buttons {
    display: flex;
    width: 100%;
    justify-content: center;
    padding-top: 40px;
    align-items: center;
}

    .dialog .dialog-buttons input[type=button] {
        min-width: 100px;
        margin: 0 20px;
    }

/*#MessageBox.dialog {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}*/

/*#MessageBox .dialog-content {
    width: 50%;
    min-width: 500px;
    padding: 20px;
}*/

.required::after {
    color: var(--red);
    content: " *";
}
/* ------------------------- Input element normalization ---------------- */

select {
    -webkit-appearance: none;
    -moz-appearance: none;
    /* ReSharper disable once CssNotResolved */
    appearance: none;
    background-image: url('../Images/SelectBoxArrow.png');
    background-position: right 0;
    background-repeat: no-repeat;
    padding-right: 18px;
}

    select::-ms-expand {
        display: none;
    }

option.indent-1 {
    padding-left: 20px;
}

option.indent-2 {
    padding-left: 40px;
}

option.indent-3 {
    padding-left: 60px;
}

input.button-a,
input.button-b,
input.button-c,
input.numeric-input,
input.decimal-input,
input.text,
input.date,
select {
    height: 30px;
    border: 1px solid var(--dark-grey);
    border-radius: 4px;
    padding-left: 5px;
}

select
{
    background-color: var(--bright-background);
}

input.checkbox {
}

input:disabled, select:disabled {
    opacity: 0.5;
    background-color: var(--bright-background);
}

input.date {
    background-image: url('../Images/SelectBoxArrow.png');
    background-position: right -28px;
    background-repeat: no-repeat;
    padding-right: 18px;
}

div.numeric-input, div.decimal-input {
    position: relative;
    display: inline-block;
}

    div.numeric-input input, div.decimal-input input {
        width: calc(100% - 15px);
        text-align: right;
        border-bottom-right-radius: 0;
        border-top-right-radius: 0;
        border-right: none;
        padding-right: 5px;
    }

    div.numeric-input > button, div.decimal-input > button {
        position: absolute;
        width: 15px;
        height: 15px;
        border: 1px solid var(--dark-grey);
        background-image: url('../Images/IncreaseDecreaseArrows.png');
        background-color: var(--bright-background);
    }

        div.numeric-input > button:hover:enabled, div.decimal-input > button:hover:enabled {
            background-color: var(--background);
        }

        div.numeric-input > button:active:enabled, div.decimal-input > button:active:enabled {
            background-color: var(--dark-background);
        }

        div.numeric-input > button.increase, div.decimal-input > button.increase {
            top: 0;
            right: 0;
            border-top-right-radius: 4px;
        }

        div.numeric-input > button.decrease, div.decimal-input > button.decrease {
            bottom: 0;
            right: 0;
            border-bottom-right-radius: 4px;
            background-position: 0 -15px;
        }

div.button-row {
    display: flex;
    justify-content: space-evenly;
}

    div.button-row input {
        display: block;
        min-width: 100px;
    }

input.button-a {
    height: 40px;
    background-color: var(--blue);
    color: white;
    box-shadow: none;
}

input.button-b {
    height: 40px;
    border: 1px solid var(--dark-grey);
    color: var(--black);
    box-shadow: none;
}

    input.button-b:hover:enabled,
    input.button-c:hover:enabled {
        color: var(--black);
        background-color: var(--dark-background);
    }

    button:disabled, input.button-a:disabled, input.button-b:disabled {
        opacity: 0.5;
        background-color: var(--background);
        color: var(--black);
    }

input.button-c {
    height: 35px;
}

    input.button-c:hover:enabled:not(:active) {
        border-color: var(--dark-grey);
    }

    input.button-c:enabled:active {
        box-shadow: none;
        background-color: var(--grey);
    }

button.patient-icon-button {
    margin: 0 5px;
}

button.icon-button {
    margin: 0 20px;
}

button.icon-button,
button.patient-icon-button {
    width: 185px;
    height: 120px;
    border: 1px solid var(--dark-grey);
    border-radius: 4px;
    background-repeat: no-repeat;
    align-self: center;
    color: var(--dark-grey);
    display: table-cell;
    padding: 5px;
}

    button.icon-button#AddPatient .icon {
        background-image: url(../Images/Add-user.png);
        background-size: contain;
    }

    button.icon-button#FindPatient .icon {
        background-image: url(../Images/Search-user.png);
        background-size: contain;
    }

    button.icon-button#SearchDatabase .icon {
        background-image: url(../Images/search.png);
        background-size: contain;
    }

    button.icon-button#UploadImages .icon,
    button.patient-icon-button#UploadImages .icon,
    .imageDropZone .uploadicon.center{
        background-image: url(../Images/image.png);
        background-size: contain;
    }

    .imageDropZone .uploadicon.center {
        height: 50px;
        width: 50px;
    }

    button.patient-icon-button#StartNewTreatmentPlan .icon {
        background-image: url(../Images/Add.png);
        background-size: contain;
    }

    button.icon-button#ReviewTreatmentPlans .icon {
        background-position: calc(4 * -44px) 0;
    }

    button.patient-icon-button#EditPatient .icon {
        background-image: url(../Images/User.png);
        background-size: contain;
    }

    button.icon-button .icon,
    button.patient-icon-button .icon {
        display: inline-block;
        width: 44px;
        height: 44px;
        align-self: center;
        margin-bottom: 5px;
        background-image: url('../Images/ButtonIcons.png');
        -webkit-filter: grayscale(100%);
        filter: grayscale(100%);
    }

    button.icon-button:hover:enabled,
    button.patient-icon-button:hover:enabled {
        border-color: var(--dark-grey);
        background-color: var(--dark-background);
    }

    button.icon-button .label,
    button.patient-icon-button .label {
        display: inline-block;
        width: 150px;
        text-align: center;
    }

.icon-button-b {
    cursor: pointer;
    display: flex;
    align-items: center;
}

    .icon-button-b label {
        cursor: pointer;
    }

input.click-to-edit {
    border-style: none;
}

/* ------------------------------ Navigation Bar ---------------------------------- */

ul.navigation {
    display: flex;
    border-bottom: 1px solid var(--dark-grey);
}

    ul.navigation li {
        display: block;
        list-style: none;
        background-color: var(--background);
        border-top: 1px solid var(--dark-grey);
        border-right: 1px solid var(--dark-grey);
        padding-bottom: 5px;
        padding-top: 3px;
        padding-left: 10px;
        padding-right: 10px;
        margin-top: 5px;
        cursor: pointer;
        white-space: nowrap;
    }

        ul.navigation li.disabled {
            opacity: 0.5;
            background-color: var(--background) cursor: default;
            pointer-events: none;
        }

        ul.navigation li:first-child {
            border-left: 1px solid var(--dark-grey);
        }

        ul.navigation li.active {
            background-color: var(--dark-grey);
            color: var(--background);
            cursor: default;
            pointer-events: none;
        }

.page-title-bar {
    display: flex;
    justify-content: space-between;
    padding: 5px 20px;
    height: 40px;
    border-bottom: 2px var(--dark-grey) solid;
}

    .page-title-bar input {
        height: 28px;
    }

.pfm-marker {
    width: 45px;
}

.phase-unequal {
    width: 35px;
    height: 25px;
    background: url(../Images/movement.png) no-repeat;
    background-size: 20px;
}

.pfm-image {
    width: 30px;
    aspect-ratio: 3/2;
    background-image: url(../Images/pfm_grey.jpg);
    background-repeat: no-repeat;
    background-size: contain;
    border-radius: 4px;
    margin-left: 10px;
    float: right;
}

.validationIndicator {
    display: inline-block;
    padding: 0;
    width: 20px;
    height: 20px;
    border-radius: 10px;
    background-color: var(--dark-background);
}

    .validationIndicator.valid {
        background-color: var(--blue);
        background-image: url(../Images/check.png);
    }

#EditPatientOverlay .create-patient {
    display: flex;
    flex-direction: row;
    margin-top: 20px;
    min-width: 700px;
}

#EditPatientOverlay .edit-col {
    width: 50%;
}

#EditPatientOverlay .edit-grid {
    padding: 20px 20px 0 0;
    justify-content: space-evenly;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-gap: 10px;
}

#EditPatientOverlay input.small {
    width: 50px;
}

#ErrorBox, #CriticalError {
    z-index: 10000;
}

    #ErrorBox .dialog-content {
        width: 70%;
    }

    #ErrorBox .red {
        color: red;
    }

    #ErrorBox textarea {
        width: 100%;
        min-height: 200px;
        overflow: scroll;
    }

#ApproveTreatmentPlan div, td {
    margin-bottom: 5px;
    margin-top: 5px;
}

#ApproveTreatmentPlan td {
    padding: 5px;
}

.long-text {
    display: inline-block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    width: 100%;
    padding: 0;
    margin: 0;
}

    .long-text.revert {
        display: revert;
    }

    .long-text.block {
        display: block;
    }

.tooltip {
    background-color: var(--bright-background);
    position: absolute;
    text-align: center;
    padding: 5px;
    border-radius: 6px;
    z-index: 702;
}

    .tooltip.left {
        text-align: left;
    }

.blue {
    color: var(--dark-grey);
}

.character-limit {
    color: var(--darker-background);
    font-size: 10px;
}

.inline-text .character-limit {
    position: absolute;
    right: 10px;
    top: 9px;
}

.inline-text {
    position: relative;
}

    .inline-text input {
        width: 100%;
        padding-right: 25px;
    }

#LinksOverlay {
    z-index: 10000;
}

    #LinksOverlay table {
        width: 100%;
        text-align: left;
        border: solid var(--dark-grey) 1px;
        border-collapse: collapse;
    }

        #LinksOverlay table th {
            padding: 5px;
            border: solid var(--dark-grey) 1px;
            border-bottom: solid var(--dark-grey) 2px;
        }

        #LinksOverlay table td {
            padding: 5px;
            border: solid var(--dark-grey) 1px;
        }

th.tableheader {
    font-weight: bold;
    background: var(--dark-background);
    border: 1px solid black;
    border-spacing: 0px;
    text-align: center;
    height: 30px;
}

th.clickableheader {
    cursor: pointer;
}

table.transferTable, td.transferTable {
    border: 1px solid var(--black);
    border-spacing: 0px;
    width: auto;
    text-align: center;
    height: 30px;
    min-width: 100px;
    table-layout: fixed;
}

td.long-text {
    display: table-cell;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    width: 100%;
    padding: 0;
    margin: 0;
}

.dialog #PatientTransferList {
    position: sticky;
    top: 0;
}


