@import './../../styles/colors.scss';

* {
    box-sizing: border-box;
    font-family: 'OpenSans' !important;
}

#app {
    min-height: 100vh;
    display: flex;
    flex-flow: column;
}

#main-section {
    flex-grow: 1;
    margin-bottom: 20px; // to contain diag section
}

html {
    font-size: 1rem;
}

body {
    background-color: #f9f9fa;
    padding: 0rem 0.75rem;
    margin: 0;
}

nav {
    position: sticky;
    top: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: left;
    align-items: center;
    padding: 1rem 1rem;
    border-bottom: 2px solid $ultra-light-grey;
    height: 5rem;

    img {
        margin-right: 0.5rem;
    }
}

p,
li,
h1,
h2,
h3 {
    max-width: 100ex;
}

h1 {
    font-size: 1.1rem;
}

.header {
    display: grid;
    grid-template-columns: 1.75rem 1fr;
    align-items: center;
    max-height: 3.5rem;
    min-height: 3.5rem;
    position: sticky;
    top: 0;
    z-index: 1;
    user-select: none;

    .webpage-metadata {
        word-break: break-all;
        display: flex;
        flex-flow: column;
        flex-wrap: nowrap;
        font-size: 0.875rem;
        font-weight: 600;
        justify-content: center;
        padding-left: 1rem;
        color: #000;

        &--hyperlink {
            font-weight: 400;
            color: $ultra-black-color;
            max-height: 2rem;
            overflow: hidden;
        }
    }
}

.sv_main {
    font-family: 'OpenSans' !important;
    background-color: transparent;
    .sv_p_root {
        max-width: 100ex;
        margin: 0 auto;

        & > .sv_row:nth-child(2n) {
            background-color: #fff;
        }

        & > .sv_row:nth-child(2n + 1) {
            background-color: #fff;
        }

        & > .sv_row {
            border-bottom: none;
            background-color: #fff;
            box-shadow: rgba(12, 12, 13, 0.1) 0px 1px 4px 0px;
        }

        & > .sv_row:last-child {
            border-bottom: none;
        }
    }
    .sv_container {
        color: rgb(12, 12, 13);
        padding: 0;
        .sv_body {
            padding: 0;

            .sv_nav {
                display: flex;
            }

            .sv_p_root {
                & > .sv_row {
                    padding: 0.75rem 1.5rem;
                    margin-bottom: 1rem;
                    border-radius: 3px;
                }

                .sv_page_title {
                    font-weight: bold;
                    font-size: calc(15 / 16 * 1rem);
                }
                .sv_q {
                    padding: 0;
                }
            }

            .sv_progress {
                height: 0.25rem;
                .sv_progress_bar {
                    margin-top: 0;
                    margin-bottom: 0.5rem;
                }
            }
        }
    }
    .sv_body {
        border: none !important;
        background-color: transparent;
    }
    .sv_progress {
        background-color: hsl(240, 9.1%, 87.8%);
        margin-bottom: 4rem;
        transition: all 200ms;
        transition-timing-function: cubic-bezier(0.25, 0.1, 0.25, 1);
        & > span {
            font-weight: 600;
        }
    }
    .sv_progress_bar {
        background-color: #000;
        transition: all 200ms;
        transition-timing-function: cubic-bezier(0.25, 0.1, 0.25, 1);
    }
}

.sv_main .sv_container .sv_body .sv_p_root .sv_page_title {
    font-size: 1.1rem;
    font-weight: bold;
}

.sv_q_radiogroup {
    margin-top: 0.25rem;
}

.sv_main .sv_q_other input,
.sv_main .sv_q_text_root,
.sv_main .sv_q_dropdown_control,
.sv_main
    input:not([type='button']):not([type='reset']):not([type='submit']):not([type='image']):not([type='checkbox']):not([type='radio']),
.sv_main select,
.sv_main textarea {
    border: 1px solid #6d7072;
    color: #000;
    padding-left: 0.25rem !important;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.sv_q_radiogroup_label {
    cursor: pointer;
}

.sv_nav {
    display: flex;
    margin: 2rem 0;
    justify-content: center;
}

.sv_prev_btn,
.sv_next_btn,
.sv_complete_btn {
    border: 0;
    outline: 0;
    font-size: 0.875rem !important;
    line-height: 0.875rem !important;
    height: 2.5rem;
    cursor: pointer;
    min-width: 100px;
}
.sv_next_btn,
.sv_complete_btn {
    background-color: #000 !important;
    font-weight: 800 !important;
    padding: 0 1.5rem;
    background-color: #000;
    margin: 0 !important;
    color: #fff !important;

    &:hover {
        color: $icd-rentgen-color !important;
        background-image: linear-gradient(
            to right,
            $icd-rentgen-color 0%,
            $icd-rentgen-color 4%,
            #000 4%,
            #000 100%
        );
        animation: slidebg 1s cubic-bezier(0.19, 1, 0.22, 1) infinite;
    }

    @keyframes slidebg {
        to {
            background-position: 155px;
        }
    }
}

.sv_prev_btn {
    margin-right: 0.5rem !important;
    color: #000 !important;
    text-decoration: underline !important;
    background-color: transparent !important;
    font-weight: 700 !important;
}

.sv_main .sv_q_erbox:not([style*='display: none']):not([style*='display:none']) {
    color: $dark-red;
}

.sv_main .sv_q_erbox:not([style*='display: none']):not([style*='display:none']) {
    border: 1px solid $dark-red;
    background-color: $pale-red;
}

.sv_main
    .sv_container
    .sv_body
    .sv_p_root
    .sv_q
    .sv_q_erbox:not([style*='display: none']):not([style*='display:none']) {
    margin: 0.5rem 0;
    padding: 1rem;
}

.sv_qstn fieldset {
    margin: 0px;
    padding: 0px;
    font-size: calc(14 / 16 * 1rem);
}

.sv_main .sv_custom_header {
    background-color: transparent;
}

.sv_main .sv_q_other input:focus,
.sv_main .sv_q_text_root:focus,
.sv_main .sv_q_dropdown_control:focus,
.sv_main
    input:not([type='button']):not([type='reset']):not([type='submit']):not([type='image']):not([type='checkbox']):not([type='radio']):focus,
.sv_main select:focus,
.sv_main textarea:focus {
    border: 1px solid #000;
}

.sv_q_title,
.sv_main .sv_container .sv_body .sv_p_root .sv_q_title {
    font-weight: 600;
    font-size: calc(14 / 16 * 1rem);
}

.generator-container {
    max-width: 100ex;
    margin: 0 auto;
    font-size: calc(14 / 16 * 1rem);
    margin-top: 3rem;

    a {
        color: $ultra-black-color;
    }
}

.diag-toolbox {
    position: fixed;
    bottom: 10px;
    left: 10px;
}
