@layer reset, component, override-base, variant, override, override-variant;

@font-face {
    font-family: ebx-font-text;
    font-style: normal;
    font-weight: normal;
    src: url(../fonts/Lato-Regular.woff) format('woff');
    text-rendering: optimizeLegibility;
}

@font-face {
    font-family: ebx-font-text;
    font-style: italic;
    font-weight: normal;
    src: url(../fonts/Lato-Italic.woff) format('woff');
    text-rendering: optimizeLegibility;
}

@font-face {
    font-family: ebx-font-text;
    font-style: normal;
    font-weight: bold;
    src: url(../fonts/Lato-Bold.woff) format('woff');
    text-rendering: optimizeLegibility;
}

@font-face {
    font-family: ebx-font-text;
    font-style: italic;
    font-weight: bold;
    src: url(../fonts/Lato-BoldItalic.woff) format('woff');
    text-rendering: optimizeLegibility;
}

@font-face {
    font-family: ebx-font-mono;
    font-style: normal;
    font-weight: 400;
    src: url(../fonts/DroidSansMono.woff) format('woff');
}

@layer reset {
    body {
        font-size: 14px;
        line-height: 17px;
        color: #1E1E1E;
        cursor: default;
    }

    * {
        font-family: ebx-font-text, Helvetica, Arial, sans-serif;
    }

    form {
        margin: 0;
    }

    input{
        cursor: auto;
    }

    input[type="button"],
    button {
        cursor: pointer;
    }

    legend {
        box-sizing: border-box;
        color: inherit;
        display: table;
        max-width: 100%;
        padding: 0;
        white-space: normal;
    }
}

:root {
    --error-text-color: #E00000;
    --label-color: #909090;
}

@layer component {
    body {
        display: flex;
        flex-direction: column;
        width: 100vw;
        height: 100vh;
        margin: 0;
        padding: 0;
        background-color: #F2F2F2;
    }

    .header {
        flex: 0 0 40px;
        height: 40px;

        display: flex;
        flex-direction: row;
        justify-content: space-between;
        white-space: nowrap;
        overflow-y: hidden;

        background-color: var(--ebx-header-color);
        color: var(--ebx-header-text);
    }

    .body {
        flex: 1 1 auto;

        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }

    .footer {
        flex: 0;

        font-size: 13px;
        color: #808080;
        text-shadow: 1px 1px 0 #FFFFFF;
        padding-bottom: 20px;
        text-align: center;
    }

    .footer a {
        text-decoration: none;
        color: #404040;
    }

    .release-info {
        display: inline-block;
        margin: 30px 20px 20px;
        padding: 0 5px;
        font-weight: bold;
        border: 1px solid var(--ebx-main-color);
        border-radius: 4px;

        text-align: left;
    }

    .release-info > p {
        margin: 10px 0;
    }

    .release-info_description {
        font-style: italic;
        color: var(--error-text-color);
    }

    .release-info_notice {

    }

    .icon-10 {
        height: 10px;
        width: 10px;
        vertical-align: 0;
    }

    .icon-16 {
        height: 16px;
        width: 16px;
        vertical-align: -3px;
    }
}

/* Card START */

@layer component {
    .card {
        width: 500px;
        padding: 20px;
        background-color: #FFFFFF;
        border-radius: 5px;
        box-shadow: 0 1px 1px #C0C0C0;
        overflow: auto;
    }
}

/* Card END */
/* CardFooter START */

@layer component {
    .card-footer {
        margin-top: 20px;
        padding-top: 20px;
        border-top: 1px solid #D0D0D0;
    }
}

/* CardFooter END */
/* CardHeader START */

@layer component {
    .card-header {
        font-size: 28px;
        line-height: 34px;
        text-align: center;
        margin-top: 20px;
        margin-bottom: 40px;
    }
}

/* CardHeader END */
/* GlobalMessages START */

@layer component {
    .global-messages-error {
        list-style: none;
        margin: 0 0 20px 0;
        padding: 5px 10px;

        color: var(--error-text-color);

        background-color: #F0D0D0;

        border: 1px solid var(--error-text-color);
        border-radius: 4px;
    }

    .global-messages-warning {
        list-style: none;
        margin: 0 0 20px 0;
        padding: 5px 10px;

        color: #926100;

        background-color: #FFE0B0;

        border: 1px solid #926100;
        border-radius: 4px;
    }

    .global-messages-info {
        list-style: none;
        margin: 0 0 20px 0;
        padding: 5px 10px;

        color: #436CCB;

        background-color: #D0D0FF;

        border: 1px solid #436CCB;
        border-radius: 4px;
    }
}

/* GlobalMessages END */
/* InputMessages START */

@layer component {
    .input-messages-error {
        list-style: none;
        margin: 0;
        padding: 0;

        color: var(--error-text-color);
        font-style: italic;
    }

    .input-messages-error > li::before {
        width: 20px;
        background: transparent url(../images/ebx_error.svg) no-repeat;
        content: "";
        display: inline-block;
        height: 14px;
    }

    .input-messages-warning {
        list-style: none;
        margin: 0;
        padding: 0;

        color: #926100;
        font-style: italic;
    }

    .input-messages-warning > li::before {
        width: 20px;
        background: transparent url(../images/ebx_warning.svg) no-repeat;
        content: "";
        display: inline-block;
        height: 14px;
    }

    .input-messages-info {
        list-style: none;
        margin: 0;
        padding: 0;

        color: #436CCB;
        font-style: italic;
    }

    .input-messages-info > li::before {
        width: 20px;
        background: transparent url(../images/ebx_info.svg) no-repeat;
        content: "";
        display: inline-block;
        height: 14px;
    }
}

/* InputMessages END */
/* StyledButton START */

@layer component {
    ._ebx-button {
        background-color: white;
        cursor: pointer;
        block-size: 28px;
        border: 1px solid transparent;
        font-size: 14px;
        line-height: 16px;
        padding: 4px 8px;
        border-radius: 4px;
    }

    ._ebx-button:focus {
        border-color: var(--ebx-focus-color);
        outline: none;
        box-shadow: 0 0 0 1px var(--ebx-focus-color);
    }

    ._ebx-button:hover {
        background-color: rgba(160,160,160,0.2);
    }
}

@layer override {
    ._ebx-button-bottom-bar-start {
        margin-left: -8px;
        color: var(--label-color);
    }
}

@layer variant {
    ._ebx-button-primary {
        background-color: var(--ebx-primary-button-color);
        color: var(--ebx-primary-button-text);
    }

    ._ebx-button-primary:focus {
        border-color: var(--ebx-primary-button-text);
    }

    ._ebx-button-primary:hover {
        background-color: var(--ebx-primary-button-color-hover);
    }
}

/* StyledButton END */
/* StyledInput START */

@layer component {
    ._ebx-input {
        box-sizing: border-box;
        padding-inline: 8px;
        font-size: 14px;
        border: 1px solid #D0D0D0;
        border-radius: 4px;
        block-size: 28px;
        line-height: 28px;
    }

    ._ebx-input:invalid {
        border-color: var(--error-text-color);
    }

    ._ebx-input:focus {
        border-color: var(--ebx-focus-color);
        outline-color: var(--ebx-focus-color);
        box-shadow: 0 0 0 1px var(--ebx-focus-color);
        outline-style: solid;
        outline-width: 0;
    }
}

/* StyledInput END */
/* StyledLabel START */

@layer component {
    ._ebx-label {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        cursor: pointer;
        color: var(--label-color);
        padding: 8px 10px 8px 0;
        width: 128px;
    }
}

@layer variant {
    ._ebx-label-mandatory::after {
        content: "*";
        margin-inline-start: 4px;
        color: var(--error-text-color);
    }
}

/* StyledLabel END */
/* StyledSelect START */

@layer component {
    ._ebx-select {
        box-sizing: border-box;
        padding-inline: 8px;
        font-size: 14px;
        border: 1px solid #D0D0D0;
        border-radius: 4px;
        block-size: 28px;
        line-height: 28px;
    }

    ._ebx-select:invalid {
        border-color: var(--error-text-color);
    }

    ._ebx-select:focus {
        border-color: var(--ebx-focus-color);
        outline-color: var(--ebx-focus-color);
        box-shadow: 0 0 0 1px var(--ebx-focus-color);
        outline-style: solid;
        outline-width: 0;
    }
}

/* StyledSelect END */
/* LocaleSelector START */

@layer component {
    #locale-selector-button {
        position: absolute;
        right: 0;

        white-space: nowrap;
        display: inline-block;
        box-sizing: border-box;
        text-decoration: none;
        height: 40px;
        border: 1px solid transparent;
        background-color: transparent;
        color: var(--ebx-header-text);
        font-size: 14px;
        line-height: 20px;
        padding: 9px 13px;
        cursor: pointer;
    }

    #locale-selector-button:hover {
        background-color: rgba(255, 255, 255, 0.2);
    }

    #locale-selector-button:focus {
        outline: none;
        border-color: var(--ebx-header-text);
        box-shadow: 0 0 0 1px var(--ebx-header-text);
    }

    #locale-selector-button > svg {
        margin: 0 0 0 5px;
    }

    #locale-selector-selector {
        position: absolute;
        top: 40px;
        right: 0;
        display: none;
        flex-direction: column;

        box-shadow: 0 2px 4px silver;
    }
}

@layer variant {
    #locale-selector-button.is-open {
        background-color: white;
        color: #1E1E1E;
    }

    #locale-selector-button.is-open > div {
        color: #1E1E1E;
    }

    #locale-selector-selector.is-visible {
        display: flex;
    }
}

/* LocaleSelector END */
/* LocaleSelectorItem START */

@layer component {
    .locale-selector-item {
        cursor: pointer;
        text-decoration: none;
        white-space: nowrap;
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: baseline;

        background-color: white;
        height: 28px;
        padding-inline: 24px;
        line-height: 28px;
        border: none;
        outline: none;
    }

    .locale-selector-item:focus {
        box-shadow: 0 0 0 2px var(--ebx-focus-color) inset;
        border-radius: 4px;
        /*background-color: rgba(160, 160, 160, 0.2);*/
    }

    .locale-selector-item:hover {
        background-color: rgba(160, 160, 160, 0.2);
    }

    .locale-selector-item.is-current {
        padding-inline-start: 0;
    }

    .locale-selector-item.is-current > svg {
        margin-inline: 6px;
    }
}

/* LocaleSelectorItem END */
/* ApplicationLockedPage START */

@layer component {
    .application-locked-actions {
        display: flex;
        flex-direction: row-reverse;
    }

    .application-locked-actions.is-logged {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
    }
}

/* ApplicationLockedPage END */
/* BackedUpUserPage START */

@layer component {
    .backed-up-user_replace {
        display: flex;
        flex-direction: column;
        margin-block-start: 20px;
    }

    .backed-up-user_replace_form,
    .backed-up-user_continue {
        display: flex;
        flex-direction: row;
    }

    .backed-up-user_replace_form {
        margin-top: 8px;
    }

    .backed-up-user_replace > div:first-child::before,
    .backed-up-user_continue > div::before {
        content: "»";
        margin-right: 4px;
    }
}

@layer override {
    .backed-up-user_replace_form > select,
    .backed-up-user_continue > div {
        flex: 1 1 auto;
    }

    .backed-up-user_continue > div {
        padding-block: 4px;
    }

    .backed-up-user_replace_form > button,
    .backed-up-user_continue > button {
        flex: 0;
        margin-left: 10px;
    }
}

/* BackedUpUserPage END */
/* ForgotPasswordPage START */

@layer component {
    .forgot-password-body {

    }

    .forgot-password-prompt {
        margin-block-end: 16px;
        font-weight: bold;
    }

    .forgot-password-info {
        margin-block-end: 16px;
    }

    .forgot-password-form {
        display: inline-grid;
        grid-template-columns: auto auto;
        grid-gap: 4px;
    }

    .forgot-password-actions {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
    }
}

/* ForgotPasswordPage END */
/* LoginPage START */

@layer component {
    .loginFormBody {
        display: inline-grid;
        grid-template-columns: auto auto;
        grid-gap: 4px;
    }

    .loginFormActions {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
    }

    .loginFormActions_default {
        display: none;
    }

    .loginRescueMessage {
        margin-bottom: 8px;
    }
}

@layer variant {
    .loginFormActions.is-rescue {
        flex-direction: row-reverse;
    }
}

/* LoginPage END */
/* LoggedOutPage START */

@layer component {
    .logged-out_content {
        text-align: center;
    }

    .logged-out_footer {
        display: flex;
        flex-direction: row;
        justify-content: space-around;
    }
}

/* LoggedOutPage END */