/* fonts */
@font-face {
    font-family: 'Source Sans Pro';
    src: url("../font/SourceSansPro-Regular.otf") format("opentype");
}

@font-face {
    font-family: 'Source Sans Pro';
    font-weight: bold;
    src: url("../font/SourceSansPro-Bold.otf") format("opentype");
}

body {
    font-family: 'Source Sans Pro';
    src: url("../font/SourceSansPro-Regular.otf") format("opentype");
}

@font-face {
    font-family: 'Source Sans Pro';
    font-weight: bold;
    src: url("../font/SourceSansPro-Bold.otf") format("opentype");
}


body {
    font-family: 'Source Sans Pro' !important;
    color: #121212;
    font-style: normal;
    background: #FFFFFF;
}

h1 {
    font-family: 'Source Sans Pro';
    font-weight: 700;
    font-size: 34px !important;
    line-height: 51px;
    text-align: center;
}

.hidden {
    display: none !important;
}

/* Necessary overwrites from parent theme (patternfly) */
.login-pf body {
    background: #FFFFFF;
}

.login-pf-page {
    padding-top: 0px;
}

.login-pf-page .login-pf-header {
    margin-bottom: 0px !important;
}

/* Custom classes that are mapped in theme.properties */
.j40-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 0px !important;
    width: 100%;
    height: 64px;
    background: #FFFFFF;
}

.j40-header-wrapper {
    display: none;
}

.j40-logo {
    width: 143px;
    height: 48px;
    background-image: url("../img/justitia-swiss-platform-logo.svg");
    background-repeat: no-repeat;
    background-size: auto 38px;
    background-position: center;
    margin-left: 49px;
}

.j40-gradient {
    background: linear-gradient(90.03deg, #265073 -0.08%, #A01513 31.72%, #E52320 56%, #336B99 99.94%);
    width: 100%;
    height: 6px;
}

#kc-page-title {
    margin-top: 80px;
    margin-bottom: 56px;
}

.j40-form-wrapper {
    display: flex;
    flex-direction: row;
    justify-content: center;
    background: #FFFFFF;
}

.j40-login-form, .j40-registration-form-bottom {
    width: 432px;
}

.j40-form-group {
    margin-top: 24px;
}

#kc-form-buttons {
    margin-top: 0px;
}

.j40-label {
    margin: 0px;
    font-weight: 400;
    font-size: 14px;
    line-height: 21px;
}

.j40-input {
    padding: 12px;
    width: 100%;
    height: 56px;
    background: #FFFFFF;
    border: 1px solid #757575;
    font-weight: 400;
    font-size: 18px;
    line-height: 27px;
}

.j40-input:focus,
.j40-input:focus-visible {
    border: 2px solid #121212;
    outline: none;
}

.j40-input[aria-invalid='true'] {
    border: 1px solid #E52320;
}

.j40-input[aria-invalid='true']:focus,
.j40-input[aria-invalid='true']:focus-visible {
    border: 2px solid #E52320;
}

.j40-btn,
.j40-idp-btn {
    padding-top: 10px;
    width: 100%;
    height: 48px;
    text-align: center;
    font-weight: 700;
    font-size: 18px;
    line-height: 27px;
}

.j40-btn {
    background: #FFFFFF;
    border: 1px solid #336B99;
    color: #336B99;
}

.j40-idp-btn {
    background: #336B99;
    color: #FFFFFF;
}

.j40-btn:active {
    background: #FFFFFF;
    border: 1px solid #19364D;
    color: #19364D;
}

.j40-idp-btn:active {
    background: #19364D;
    color: #FFFFFF;
}

.j40-btn:focus,
.j40-idp-btn:focus,
.j40-btn:focus-visible,
.j40-idp-btn:focus-visible {
    outline: 2px solid #000000;
    outline-offset: 2px;
    border-radius: 0px;
}

.j40-btn:focus,
.j40-btn:focus-visible {
    color: #336B99;
    text-decoration: none;
}

.j40-idp-btn:focus,
.j40-idp-btn:focus-visible {
    color: #FFFFFF;
    text-decoration: none;
}

#kc-form-buttons input:hover {
    border: 1px solid#265073;
    color: #265073;
}

.j40-idp-section ul {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.j40-idp-section ul a:hover {
    background: #265073;
    color: #FFFFFF;
    text-decoration: none;
}

.j40-login-error-wrapper {
    display: flex;
    flex-direction: row;
    align-items: center;
}

.j40-login-error {
    height: 24px;
    font-weight: 400;
    font-size: 14px;
    line-height: 24px;
    color: #E52320;
    margin-left: 8px;
    margin-top: 2px;
}

.j40-login-error-icon {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    background-image: url("../img/attention.svg");
    background-repeat: no-repeat;
    background-size: cover;
}

/* separator line */
.j40-separator span {
    font-weight: 400;
    font-size: 18px;
    line-height: 27px;
    color: #121212;

    display: flex;
    flex-direction: row;
    align-items: center;
    margin-top: 24px;
}

.j40-separator span::before,
.j40-separator span::after {
    content: "";
    flex: 1 1;
    border-bottom: 1px solid #757575;
}

.j40-separator span::before {
    margin-right: 12px
}

.j40-separator span::after {
    margin-left: 12px
}

/* rudimentary language selection menu */
.j40-locale-main {
    margin-top: 80px;
    display: flex;
    flex-direction: row;
    justify-content: center;
}

.j40-locale-list {
    list-style-type: none;
    padding: 0;
}

.j40-locale-list .j40-locale-list-item:not(:last-child) {
    border-right: solid 2px #121212;
    padding-right: 12px;
}

.j40-locale-list .j40-locale-list-item {
    margin-left: 12px;
    display: inline;
}

.j40-locale-list .j40-locale-list-item:first-child {
    margin-left: 0px;
}

.j40-locale-list-link {
    font-weight: 400;
    font-size: 18px;
    line-height: 27px;
    color: #121212;
    padding-top: 15px;
    padding-bottom: 15px;
    margin-top: -15px;
    margin-bottom: -15px;
}

.j40-locale-list-link:hover {
    text-decoration: none;
    color: #1178C2;
}

.j40-locale-list-link:active {
    text-decoration: none;
    color: #19364D;
}

.j40-locale-list-link:focus,
.j40-locale-list-link:focus-visible {
    outline: 2px solid #000000;
    outline-offset: 2px;
    border-radius: 0px;
    text-decoration: none;
    color: #121212;
}

.j40-locale-current-item {
    font-weight: 700;
}

/* registration page */
.j40-registration-form {
    width: 658px;
}

#j40-registration-header {
    margin-bottom: 64px;
}

#j40-registration-title {
    font-size: 48px !important;
    line-height: 72px;
    margin-top: 80px;
    margin-bottom: 8px;
    text-align: center;
}

.j40-registration-title-text {
    font-weight: 400;
    font-size: 22px;
    line-height: 33px;
    text-align: center;
}

#j40-registration-content {
    display: flex;
    flex-direction: row;
    justify-content: center;
}

.j40-registration-subtitle {
    font-weight: 700;
    font-size: 28px !important;
    line-height: 42px;
    margin-bottom: 24px;
    margin-top: 0px;
}

.j40-registration-explanation {
    font-weight: 400;
    font-size: 18px;
    line-height: 27px;
    margin-top: 64px;
    margin-bottom: 16px;
}

.j40-registration-link-wrapper {
    margin-bottom: 16px;
}

.j40-registration-link {
    font-weight: 700;
    font-size: 18px;
    line-height: 48px;
    color: #336B99;
    display: flex;
    align-items: center;
}

.j40-registration-link:hover {
    text-decoration: none;
    color: #265073;
}

.j40-registration-link:focus,
.j40-registration-link:focus-visible {
    border: 2px solid #121212;
    outline: none;
    text-decoration: none;
}

.j40-registration-element a::after {
    content: "";
    display: inline-block;
    background-image: url(../img/arrow.svg);
    background-repeat: no-repeat;
    background-size: contain;
    width: 10px;
    height: 20px;
    margin-left: 19px;
}

.j40-registration-element a:hover::after {
    background-image: url(../img/arrow-hover.svg);
}

.j40-dashboard-link {
    display: flex;
    flex-direction: row;
    justify-content: center;
}

/* Screen size L and smaller */
@media (max-width: 1442px) {
    .j40-logo {
        margin-left: 24px;
    }
}

/* Screen size M and smaller */
@media (max-width: 992px) {
    .j40-logo {
        margin-left: 16px;
    }
}

/* Screen size S and smaller */
@media (max-width: 576px) {
    h1 {
        font-size: 22px !important;
        line-height: 33px;
    }

    #kc-page-title {
        margin-top: 64px;
        margin-bottom: 48px;
    }

    .j40-logo {
        width: 106px;
        height: 48px;
        background-size: auto 28px;
    }

    .j40-login-form {
        width: 287px;
    }

    .j40-btn,
    .j40-idp-btn {
        font-size: 16px;
        line-height: 24px;
    }

    .j40-separator h4 {
        font-size: 16px;
        line-height: 24px;
    }

    .j40-locale-main {
        margin-top: 64px;
    }

    .j40-locale-list-link {
        font-size: 14px;
    }

    .j40-registration-form {
        width: 432px;
    }

    #j40-registration-title {
        font-size: 28px !important;
        line-height: 42px;
        margin-top: 64px;
        text-align: left;
    }

    .j40-registration-title-text {
        font-size: 18px;
        line-height: 27px;
        text-align: left;
    }

    .j40-registration-subtitle {
        font-size: 22px !important;
        line-height: 33px;
        margin-bottom: 16px;
    }

    .j40-registration-explanation {
        font-size: 16px;
        line-height: 24px;
        margin-top: 56px;
        margin-bottom: 12px;
    }

    .j40-registration-link {
        font-size: 16px;
        line-height: 48px;
    }
}

/* Screen size XS */
@media (max-width: 320px) {
    .j40-registration-form {
        width: 288px;
    }

    .j40-registration-explanation {
        font-size: 14px;
        line-height: 21px;
    }

    .j40-idp-section ul {
        gap: 16px;
    }
}

/* WCAG related styling */
.hidden-wcag-heading {
    position: absolute;
    left: -9999px;
    top: -9999px;
}