:root {
    --auth-primary: #245d86;
    --auth-primary-hover: #1d4f73;

    --auth-text: #183b5a;
    --auth-label: #183b5a;

    --auth-border: #b8cddd;
    --auth-border-focus: #245d86;

    --auth-error-bg: #fceaea;
    --auth-error-border: #e8bcbc;
    --auth-error-text: #8d2929;

    --auth-info-bg: #eaf2f8;
    --auth-info-border: #bfd4e4;
    --auth-info-text: #245d86;
}


* {
    box-sizing: border-box;
}


html,
body {
    margin: 0;
    width: 100%;
    min-height: 100%;
}


body {
    min-height: 100vh;

    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    color: var(--auth-text);

    background: #f9fbfd;
}


button,
input {
    font: inherit;
}


/*
 * ============================================================
 * GESAMTFLÄCHE
 * ============================================================
 */

.auth-page {
    position: relative;

    display: grid;

    grid-template-columns:
        minmax(540px, 1.12fr)
        minmax(520px, 0.88fr);

    min-height: 100vh;

    overflow: hidden;

    background:
        radial-gradient(
            circle at 20% 44%,
            rgba(193, 220, 239, 0.40) 0,
            rgba(226, 239, 248, 0.25) 29%,
            rgba(248, 251, 253, 0) 58%
        ),
        linear-gradient(
            104deg,
            #eaf4fb 0%,
            #f2f8fc 36%,
            #fbfdfe 58%,
            #ffffff 100%
        );
}


/*
 * weicher Übergang statt harter Spaltengrenze
 */

.auth-page::after {
    content: "";

    position: absolute;

    z-index: 1;

    top: 0;
    bottom: 0;

    left: 31%;

    width: 37%;

    pointer-events: none;

    background:
        linear-gradient(
            90deg,
            rgba(247, 251, 253, 0),
            rgba(251, 253, 254, 0.70) 48%,
            rgba(255, 255, 255, 0.96) 100%
        );
}


/*
 * ============================================================
 * DIGITALISIERUNGSILLUSTRATION
 * ============================================================
 */

.auth-art {
    position: relative;

    z-index: 0;

    min-height: 100vh;

    overflow: hidden;
}


.auth-art::before {
    content: "";

    position: absolute;

    inset: -7% -10% -7% -12%;

    opacity: 0.28;

    background-image:
        linear-gradient(
            rgba(36, 93, 134, 0.10) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(36, 93, 134, 0.10) 1px,
            transparent 1px
        );

    background-size: 82px 82px;

    transform: rotate(-4deg);

    mask-image:
        linear-gradient(
            90deg,
            #000 0%,
            rgba(0, 0, 0, 0.75) 58%,
            transparent 100%
        );
}


.auth-art::after {
    content: "";

    position: absolute;

    width: 560px;
    height: 430px;

    left: -230px;
    bottom: -205px;

    border-radius: 45%;

    background:
        linear-gradient(
            135deg,
            rgba(92, 155, 199, 0.16),
            rgba(146, 191, 221, 0.06)
        );

    transform: rotate(31deg);
}


.auth-art img {
    position: absolute;

    z-index: 2;

    width: min(900px, 112%);
    height: 100%;

    left: -7%;
    top: 0;

    object-fit: cover;
    object-position: left center;

    opacity: 0.90;

    user-select: none;

    pointer-events: none;

    mask-image:
        linear-gradient(
            90deg,
            #000 0%,
            #000 61%,
            rgba(0, 0, 0, 0.45) 79%,
            transparent 100%
        );
}


/*
 * ============================================================
 * LOGIN-SEITE RECHTS
 * ============================================================
 */

.auth-panel {
    position: relative;

    z-index: 3;

    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 100vh;

    padding:
        54px
        clamp(54px, 6vw, 105px)
        54px
        36px;
}


.login-card {
    width: min(100%, 570px);

    padding:
        68px
        56px
        50px;

    background:
        rgba(255, 255, 255, 0.96);

    border:
        1px solid rgba(154, 184, 206, 0.50);

    border-radius: 17px;

    box-shadow:
        0 2px 4px rgba(22, 54, 78, 0.025),
        0 18px 48px rgba(30, 74, 105, 0.075);

    backdrop-filter: blur(10px);
}


/*
 * ============================================================
 * NEUTRALES SIGNET
 * ============================================================
 */

.login-symbol {
    position: relative;

    width: 76px;
    height: 62px;

    margin:
        0 auto
        24px;
}


.login-symbol span {
    position: absolute;

    width: 40px;
    height: 40px;

    border-radius: 2px;
}


.login-symbol span:first-child {
    left: 10px;
    top: 0;

    background: #245d86;
}


.login-symbol span:last-child {
    left: 31px;
    top: 20px;

    background:
        rgba(103, 161, 201, 0.48);

    border:
        1px solid rgba(36, 93, 134, 0.08);
}


/*
 * ============================================================
 * ÜBERSCHRIFT
 * ============================================================
 */

.login-heading {
    margin-bottom: 46px;

    text-align: center;
}


.login-heading h1 {
    margin: 0;

    color: #183f61;

    font-size:
        clamp(32px, 2.4vw, 40px);

    font-weight: 400;

    line-height: 1.15;

    letter-spacing: -0.025em;
}


/*
 * ============================================================
 * FORMULAR
 * ============================================================
 */

.login-form {
    display: flex;
    flex-direction: column;

    gap: 29px;
}


.login-field label {
    display: block;

    margin-bottom: 10px;

    color: var(--auth-label);

    font-size: 15px;
    font-weight: 600;
}


.input-shell {
    position: relative;
}


.login-field input {
    width: 100%;
    height: 61px;

    padding:
        0 20px
        0 58px;

    color: #203847;

    background: #ffffff;

    border:
        1px solid var(--auth-border);

    border-radius: 8px;

    outline: none;

    font-size: 16px;

    transition:
        border-color 140ms ease,
        box-shadow 140ms ease,
        background 140ms ease;
}


.login-field input:hover {
    border-color: #91afc5;
}


.login-field input:focus {
    border-color:
        var(--auth-border-focus);

    box-shadow:
        0 0 0 3px
        rgba(36, 93, 134, 0.12);
}


/*
 * Autofill:
 * Browsergelb möglichst durch unser neutrales Weiß ersetzen.
 */

.login-field input:-webkit-autofill,
.login-field input:-webkit-autofill:hover,
.login-field input:-webkit-autofill:focus {
    -webkit-text-fill-color: #203847;

    -webkit-box-shadow:
        0 0 0 1000px
        #ffffff inset;

    caret-color: #203847;

    transition:
        background-color 9999s ease-out 0s;
}


/*
 * ============================================================
 * CSS-ICONS
 * ============================================================
 */

.input-icon {
    position: absolute;

    z-index: 2;

    left: 19px;
    top: 50%;

    width: 22px;
    height: 22px;

    transform: translateY(-50%);

    pointer-events: none;
}


.user-icon::before {
    content: "";

    position: absolute;

    width: 8px;
    height: 8px;

    left: 7px;
    top: 1px;

    border:
        1.8px solid var(--auth-primary);

    border-radius: 50%;
}


.user-icon::after {
    content: "";

    position: absolute;

    width: 16px;
    height: 8px;

    left: 3px;
    bottom: 1px;

    border:
        1.8px solid var(--auth-primary);

    border-radius:
        9px 9px 2px 2px;
}


.password-icon::before {
    content: "";

    position: absolute;

    width: 14px;
    height: 11px;

    left: 4px;
    bottom: 2px;

    border:
        1.8px solid var(--auth-primary);

    border-radius: 3px;
}


.password-icon::after {
    content: "";

    position: absolute;

    width: 9px;
    height: 9px;

    left: 6.5px;
    top: 1px;

    border:
        1.8px solid var(--auth-primary);

    border-bottom: 0;

    border-radius:
        7px 7px 0 0;
}


/*
 * ============================================================
 * BUTTON
 * ============================================================
 */

.login-button {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 30px;

    width: 100%;
    min-height: 64px;

    margin-top: 9px;

    padding:
        0 30px;

    color: #ffffff;

    background:
        linear-gradient(
            105deg,
            #2d75aa,
            #245d86
        );

    border: 0;
    border-radius: 8px;

    font-size: 17px;
    font-weight: 600;

    cursor: pointer;

    box-shadow:
        0 8px 20px
        rgba(36, 93, 134, 0.16);

    transition:
        transform 120ms ease,
        box-shadow 120ms ease,
        background 120ms ease;
}


.login-button:hover {
    background:
        linear-gradient(
            105deg,
            #286a9b,
            #1d4f73
        );

    box-shadow:
        0 10px 24px
        rgba(36, 93, 134, 0.21);
}


.login-button:active {
    transform: translateY(1px);
}


.login-button:focus-visible {
    outline:
        3px solid
        rgba(36, 93, 134, 0.25);

    outline-offset: 3px;
}


.button-arrow {
    font-size: 25px;
    font-weight: 300;

    line-height: 1;
}


/*
 * ============================================================
 * PASSWORT-HILFE
 * ============================================================
 */

.login-assistance {
    margin-top: 25px;

    text-align: center;
}


.login-assistance a {
    color: var(--auth-primary);

    font-size: 14px;
    font-weight: 600;

    text-decoration: none;
}


.login-assistance a:hover {
    text-decoration: underline;
}


.login-assistance a:focus-visible {
    outline:
        3px solid
        rgba(36, 93, 134, 0.18);

    outline-offset: 4px;

    border-radius: 2px;
}


/*
 * ============================================================
 * MELDUNGEN
 * ============================================================
 */

.login-message {
    margin:
        -16px 0
        30px;

    padding:
        12px 14px;

    border-radius: 7px;

    font-size: 14px;

    line-height: 1.45;
}


.login-message-error {
    color: var(--auth-error-text);

    background:
        var(--auth-error-bg);

    border:
        1px solid
        var(--auth-error-border);
}


.login-message-info {
    color: var(--auth-info-text);

    background:
        var(--auth-info-bg);

    border:
        1px solid
        var(--auth-info-border);
}


/*
 * ============================================================
 * RESPONSIVE
 * ============================================================
 */

@media (max-width: 1100px) {

    .auth-page {
        grid-template-columns:
            minmax(390px, 0.78fr)
            minmax(500px, 1fr);
    }


    .auth-panel {
        padding:
            40px
            44px
            40px
            24px;
    }


    .login-card {
        padding:
            58px
            44px
            44px;
    }


    .auth-art img {
        width: 135%;

        left: -25%;
    }
}


@media (max-width: 780px) {

    .auth-page {
        display: block;
    }


    .auth-page::after {
        display: none;
    }


    .auth-art {
        position: fixed;

        inset: 0;

        min-height: 100vh;

        opacity: 0.20;
    }


    .auth-art img {
        width: 125%;
        height: 100%;

        left: -25%;

        mask-image: none;
    }


    .auth-panel {
        min-height: 100vh;

        padding:
            28px
            20px;
    }


    .login-card {
        width: min(100%, 510px);

        padding:
            52px
            38px
            40px;

        background:
            rgba(255, 255, 255, 0.97);
    }
}


@media (max-width: 480px) {

    .auth-panel {
        padding:
            16px
            13px;
    }


    .login-card {
        padding:
            40px
            22px
            31px;

        border-radius: 13px;
    }


    .login-symbol {
        transform: scale(.88);

        margin-bottom: 17px;
    }


    .login-heading {
        margin-bottom: 35px;
    }


    .login-heading h1 {
        font-size: 30px;
    }


    .login-form {
        gap: 23px;
    }


    .login-field input {
        height: 56px;
    }


    .login-button {
        min-height: 59px;
    }
}


@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}


/* ==========================================================
   LOGIN-UI-04
   Desktop-Feintuning
   ========================================================== */

@media (min-width: 1160px) {

    /*
     * Illustration etwas zurücknehmen.
     * Die Anmeldung soll der visuelle Schwerpunkt bleiben.
     */
    .auth-visual-image {
        opacity: 0.88;
    }


    /*
     * Übergang früher beginnen und weicher auslaufen lassen.
     */
    .auth-visual::after {
        right: -2px;

        width: 52%;

        background:
            linear-gradient(
                90deg,
                rgba(255,255,255,0) 0%,
                rgba(255,255,255,0.08) 18%,
                rgba(255,255,255,0.28) 42%,
                rgba(255,255,255,0.68) 72%,
                rgba(255,255,255,0.94) 91%,
                #ffffff 100%
            );
    }


    /*
     * Rechte Spalte etwas großzügiger.
     * Dadurch wandert die Karte leicht Richtung Bildmitte.
     */
    .auth-page {
        grid-template-columns:
            minmax(0, 52%)
            minmax(0, 48%);
    }


    .auth-panel {
        justify-content: flex-start;

        padding:
            48px
            clamp(58px, 6vw, 105px)
            48px
            clamp(42px, 4.5vw, 78px);
    }


    /*
     * Karte etwas größer, ohne massiv zu wirken.
     */
    .login-card {
        width: min(100%, 620px);

        padding:
            66px
            62px
            48px;

        border-radius: 16px;

        box-shadow:
            0 2px 5px rgba(24,63,96,0.025),
            0 17px 46px rgba(24,63,96,0.075);
    }


    /*
     * Signet minimal kompakter.
     */
    .login-symbol {
        transform: scale(0.94);

        margin-bottom: 22px;
    }


    /*
     * Weniger Leerraum zwischen Titel und Formular.
     */
    .login-heading {
        margin-bottom: 43px;
    }


    /*
     * Formular geringfügig kompakter.
     */
    .login-form {
        gap: 27px;
    }


    /*
     * Felder bleiben großzügig, werden aber nicht höher.
     */
    .login-field input {
        height: 61px;
    }


    /*
     * Button etwas weniger dominant.
     */
    .login-button {
        min-height: 62px;

        margin-top: 8px;
    }


    .login-assistance {
        margin-top: 23px;
    }

}
