/* ----- Fonts ------ */
@font-face {
    font-family: space-grotesk;
    src: url(/static/font/SpaceGrotesk.woff2);
}

@font-face {
    font-family: roboto;
    src: url(/static/font/RobotoFlex.woff2);
}

/* ------ General ------- */

.mr-1 {
    margin-right: 0.25rem;
}

.mr-2 {
    margin-right: 0.5rem;
}

.mr-3 {
    margin-right: 1rem;
}

.mr-4 {
    margin-right: 1.5rem;
}

.mr-5 {
    margin-right: 3rem;
}

.ml-1 {
    margin-left: 0.25rem;
}

.ml-2 {
    margin-left: 0.5rem;
}

.ml-3 {
    margin-left: 1rem;
}

.ml-4 {
    margin-left: 1.5rem;
}

.ml-5 {
    margin-left: 3rem;
}

:root {
    --blue: #5072FF;
    --poppy: #FF8650;
    --poppy-1: #FFE7DC;
    --teal: #50FFDD;
    --teal-1: #D3FFF6;
    --pale-blue: #C2D3FF;
}

body {
    font-family: roboto, sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
    margin-right: calc(-1 * (100vw - 100%));
    color: #424654;
}

main {
    flex: 1;
    background-color: white;
}

h1 {
    font-family: space-grotesk, sans-serif;
    font-size: 2.5rem;
    line-height: 3rem;
    letter-spacing: 0;
    font-weight: 700;
    color: var(--blue);
}

a, th {
    color: #424654 !important;
}

.cursor-pointer {
    cursor: pointer;
}

.bg-teal-1 {
    background: var(--teal-1);
}

.bg-blue {
    background: var(--blue);
}

.shadow-lr {
    -webkit-box-shadow: 10px 10px 14px -3px rgba(143, 143, 143, 0.49);
    -moz-box-shadow: 10px 10px 14px -3px rgba(143, 143, 143, 0.49);
    box-shadow: 10px 10px 14px -3px rgba(143, 143, 143, 0.49);
}

.dot {
    color: var(--blue);
    margin: 0 0.5em;
}

.orange {
    color: var(--poppy) !important;
}

.blue {
    color: var(--blue) !important;
}

.active-badge {
    background-color: rgba(78, 180, 81, 0.5);
    border-radius: 5px;
    padding: 5px 10px;
    color: darkgreen;
    font-weight: 700;
}

.inactive-badge {
    background-color: rgba(244, 67, 54, 0.5);
    border-radius: 5px;
    padding: 5px 10px;
    color: darkred;
    font-weight: 700;
}

.successful-request {
    color: var(--blue);
}

.unsuccessful-request {
    color: var(--poppy);
}

.invalid-feedback {
    color: var(--poppy);
}

.blurred {
    filter: blur(8px);
}

/* ----- Buttons ------ */

.primary-button {
    background: var(--poppy);
    color: white !important;
    border: none;
    padding-left: 1.7em;
    padding-right: 1.7em;
    width: auto;
}

.secondary-button {
    background: var(--blue);
    color: white !important;
    border: none;
    padding-left: 1.7em;
    padding-right: 1.7em;
}

.button {
    font-size: 1.1em;
    font-weight: 700;
    border-radius: 25px;
    height: 45px;
    text-decoration: none;
    display: flex;
    justify-content: center;
    align-items: center;
    -webkit-box-shadow: 3px 3px 7px 3px rgba(143, 143, 143, 0.49);
    -moz-box-shadow: 3px 3px 7px 3px rgba(143, 143, 143, 0.49);
    box-shadow: 3px 3px 7px 3px rgba(143, 143, 143, 0.49);
}

.button:disabled {
    cursor: not-allowed;
}

a.button {
    max-width: 170px;
}

@media screen and (max-width: 355px) {
    .button {
        width: 100%;
        margin: 0;
    }

    a.button {
        max-width: 100% !important;
    }
}

.add-entity-button {
    cursor: pointer;
    color: var(--blue) !important;
    text-decoration: none;
    font-weight: 700;
    display: flex;
    justify-content: center;
    align-items: center;
}

.toggle-blur-button {
    background: none;
    border: none;
    padding: 0;
}

.toggle-blur-button .visibility-on-img {
    display: none;
}

.toggle-blur-button.visibility-on .visibility-on-img {
    display: inline-block;
}

.toggle-blur-button.visibility-on .visibility-off-img {
    display: none;
}

/* --------Container-------- */

.container {
    max-width: 1130px;
}

.container-xxl {
    max-width: 1480px;
}

.orange-container {
    background-color: var(--poppy-1);
    padding: 3em;
    border-radius: 5px;
    max-width: 700px !important;
    min-height: 470px;
    margin-top: 3rem;
}

.request-container {
    margin-top: 3rem;
}

@media screen and (max-width: 700px) {
    .orange-container, .request-container {
        margin-top: 0;
    }
}

@media screen and (max-width: 450px) {
    .orange-container {
        padding: 1.5em;
    }
}

@media screen and (max-width: 355px) {
    .orange-container {
        padding: 1em;
    }
}

.ope-container {
    font-size: 0.75em;
    margin-top: 3em;
    padding: 1em;
    line-height: 12px;
    display: flex;
    flex-direction: column;
    align-items: end;
    z-index: 2;
}

@media screen and (max-width: 600px) {
    .ope-container {
        align-items: center !important;
    }
}

/* --------Forms-------- */


.form-element {
    background: white;
    padding: 1em;
    border-radius: 5px;
}


.form-control, .form-select {
    border: none;
    border-radius: 0;
    border-bottom: 1px solid #424654 !important;
    padding: 0;
    color: #424654;
}

.form-control:disabled {
    background: white;
    cursor: not-allowed;
}

.form-control:focus,
.form-select:focus {
    box-shadow: none !important;
}

.invalid-form input, .invalid-form select, form.was-validated input:invalid {
    border-bottom: 1px solid var(--poppy) !important;
}

.invalid-form label, form.was-validated .form-element:has(input:invalid) label {
    color: var(--poppy);
}

#password-error-message {
    display: none;
}

.invalid-form #password-error-message, form.was-validated:has(input:invalid) #password-error-message {
    display: block;
}

.invalid-form #password-info-message, form.was-validated:has(input:invalid) #password-info-message {
    display: none;
}

#password-info-message, #password-error-message {
    height: 40px;
}

@media screen and (max-width: 390px) {
    #password-info-message, #password-error-message {
        height: 60px;
    }
}


.form-check-input, .form-check-input:invalid, .form-check-input:valid {
    border-color: var(--poppy) !important;
}

.form-check-input {
    width: 20px;
    height: 20px;
}

.form-check-input:checked[type="checkbox"] {
    --bs-form-check-bg-image: url("/static/image/check-lg.svg");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 20px 20px;
    background-color: var(--poppy);
}

.form-check-input:checked[type="checkbox"]:valid {
    background-color: var(--poppy);
}

.form-check-input:focus {
    box-shadow: none !important;
}

/* Excel/Pdf/Csv Buttons */

.btn-group button {
    border: none;
    height: 2em;
    background-color: white;
    color: #0072BC;
    font-weight: 700;
    margin: 0;
    padding: 0;
}

.btn-group button:hover {
    border: none;
    background-color: white;
    color: #0072BC;
}

.btn-group button img {
    width: 1.2em;
}

.btn-group > .btn-group:not(:first-child), .btn-group > :not(.btn-check:first-child) + .btn {
    margin-left: 1em;
}

/* ----Table styles---- */
.dataTable {
    z-index: 2;
    position: relative;
}

#my-table thead th {
    background-color: #f8f8f8;
    white-space: normal;
    padding: 5px;
}

#my-table tbody tr:nth-child(even) td {
    background-color: #FAFAFA;
}

#my-table tbody tr td {
    border-style: none;
    word-wrap: break-word;
    padding-top: 1em;
    padding-bottom: 1em;
    padding-right: 1em;
}

#my-table { /*Initially set to display none. Is being set to block via respective data table javascript file*/
    display: none;
}


/* Datatable specific css */
table.dataTable th.dt-type-numeric,
table.dataTable th.dt-type-date,
table.dataTable td.dt-type-numeric,
table.dataTable td.dt-type-date {
    text-align: left !important;
}

@media screen and (max-width: 800px) {
    .table-title {
        flex-direction: column;
    }

    .access-code-admin-buttons {
        flex-direction: column;
    }

    .access-code-admin-buttons a {
        margin: 0 0 5px;
    }
}


/*-- Privacy notice --*/

ul.dashed {
    list-style-type: none;
}

ul.dashed > li {
    text-indent: -5px;
}

ul.dashed > li:before {
    content: "-";
    text-indent: -5px;
}


/*---- Date range ----*/

#reportrange {
    background: #fff;
    cursor: pointer;
    padding-left: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #9e9e9e;
    width: 100%
}

.daterangepicker .calendar-table th, .daterangepicker .calendar-table td {
    padding: 0;
}

/*------ pagination ------*/
.page-link {
    border: none;
    color: #424654;
    background-color: white;
    margin: 5px;
}

.page-link:hover, .page-link:focus, .page-item.active .page-link {
    background-color: lightgray;
    color: #424654;
    box-shadow: none;
}

.page-item.disabled .page-link {
    color: lightgray;
    background-color: transparent;
}

/* ---- access code success page ---- */

.success-access-code {
    font-size: 3.6em;
}

@media screen and (max-width: 500px) {
    .success-access-code {
        font-size: 2em;
    }
}

/* ---- access code create page ---- */

.create-request img {
    max-width: 160px;
}

.create-request form {
    flex-basis: 500px;
    flex-grow: 15;
}

.create-request .input-field:has(#patient-email) {
    flex-basis: 350px;
    min-height: 50px;
}

.create-request .input-field:has(#confirmation-email) {
    flex-basis: 290px;
    min-height: 50px;
}

/* ---- access code confirm page ---- */

.confirm-request form {
    flex-basis: 450px;
    flex-grow: 15;
}


.confirm-request .img {
    width: 150px;
    display: flex;
    align-items: end;
}

/* ---- loading spinner ---- */

#loading-spinner {
    display: none;
}

.spinner {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    position: relative;
    animation: rotate 0.5s linear infinite
}

.spinner::before {
    content: "";
    box-sizing: border-box;
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 4px solid #5072FF;
    animation: prixClipFix 2s linear infinite;
}

@keyframes rotate {
    100% {
        transform: rotate(360deg)
    }
}

@keyframes prixClipFix {
    0% {
        clip-path: polygon(50% 50%, 0 0, 0 0, 0 0, 0 0, 0 0)
    }
    25% {
        clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 0, 100% 0, 100% 0)
    }
    50% {
        clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 100% 100%, 100% 100%)
    }
    75% {
        clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 0 100%, 0 100%)
    }
    100% {
        clip-path: polygon(50% 50%, 0 0, 100% 0, 100% 100%, 0 100%, 0 0)
    }
}