/* =========================================
   BASIS
========================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    min-height: 100vh;
    font-family: "Inter", sans-serif;
    background: #F7F3EE;
    color: #3F3A35;
    padding: 10px;
}

.login-page {
    width: 100%;
}

/* =========================================
   WRAPPER
========================================= */

.login-wrapper {
    position: relative;
    width: 100%;
    min-height: calc(100vh - 20px);
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .08);
}

/* =========================================
   BACKGROUND
========================================= */

.login-background {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.login-background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.login-background::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, .22);
}

/* =========================================
   LOGO
========================================= */

.login-logo {
    position: absolute;
    top: 36px;
    left: 44px;
    z-index: 5;
}

.logo-link {
    display: inline-flex;
}

.login-logo img {
    width: 220px;
    height: auto;
    display: block;
}

/* =========================================
   LOGIN CARD
========================================= */

.login-card {
    position: absolute;
    right: clamp(24px, 6vw, 80px);
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: min(620px, calc(100% - 48px));
    max-height: calc(100vh - 70px);
    overflow-y: auto;
    background: rgba(247, 241, 236, .96);
    backdrop-filter: blur(6px);
    border-radius: 34px;
    padding: 44px 50px 40px;
}

.login-heart {
    text-align: center;
    margin-bottom: 18px;
}

.login-heart img {
    width: 44px;
    height: auto;
    display: block;
    margin: 0 auto;
}

.login-card h1 {
    text-align: center;
    margin-bottom: 12px;
    font-family: "Playfair Display", serif;
    font-size: 36px;
    line-height: 1.12;
    color: #3B4335;
}

.login-subtitle {
    text-align: center;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 30px;
    color: #5E5852;
}

/* =========================================
   FORM
========================================= */

.login-form {
    margin-bottom: 22px;
}

.input-group {
    position: relative;
    margin-bottom: 18px;
}

.input-group input {
    width: 100%;
    height: 62px;
    border: 1px solid #DDD6CE;
    border-radius: 18px;
    background: #FFFFFF;
    padding: 0 64px;
    font-size: 17px;
    color: #555;
}

.input-group input:focus {
    outline: none;
    border-color: #9FA990;
    box-shadow: 0 0 0 4px rgba(159, 169, 144, .16);
}

.input-icon {
    position: absolute;
    left: 22px;
    top: 50%;
    transform: translateY(-50%);
    color: #9B928A;
    pointer-events: none;
}

.input-icon img {
    width: 23px;
    height: auto;
    display: block;
}

.password-icon {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: #9B928A;
    font-size: 21px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.password-icon:hover {
    background: #F5F1EC;
}

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

.login-button {
    width: 100%;
    height: 64px;
    border: none;
    border-radius: 18px;
    background: #B8BBB0;
    color: #FFFFFF;
    font-size: 25px;
    font-weight: 500;
    cursor: pointer;
    transition: .25s;
}

.login-button:hover {
    background: #A9AD9F;
}

/* =========================================
   PASSWORT VERGESSEN
========================================= */

.forgot-password {
    display: block;
    text-align: center;
    margin: 16px 0 22px;
    color: #8F8071;
    text-decoration: none;
}

.forgot-password:hover {
    opacity: .8;
}

/* =========================================
   TRENNER
========================================= */

.login-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 22px;
}

.login-divider span {
    flex: 1;
    height: 1px;
    background: #E6DDD5;
}

.divider-heart,
.divider-heart img {
    display: flex;
    align-items: center;
    justify-content: center;
}

.divider-heart img {
    width: 24px;
    height: auto;
}

/* =========================================
   REGISTRIERUNG
========================================= */

.register-area {
    text-align: center;
}

.register-area p {
    margin-bottom: 14px;
    color: #5E5852;
}

.register-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 250px;
    min-height: 52px;
    padding: 0 22px;
    border-radius: 18px;
    background: #EEE1D6;
    color: #6D625A;
    text-decoration: none;
    font-size: 18px;
    font-weight: 500;
    transition: .25s;
}

.register-button:hover {
    background: #EADFD5;
}

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

.success-message {
    background: #EEF3E7;
    border: 1px solid #DCE2D3;
    color: #4F6146;
    border-radius: 16px;
    padding: 18px 20px;
    margin-bottom: 22px;
}

.success-message strong {
    display: block;
    margin-bottom: 8px;
    font-size: 17px;
}

.success-message p {
    margin: 0;
    line-height: 1.45;
}

.error-message {
    background: #FFF1F1;
    border: 1px solid #F1B2B2;
    color: #B84242;
    border-radius: 16px;
    padding: 16px 18px;
    margin: 0 0 22px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.45;
    display: grid;
    grid-template-columns: 30px 1fr;
    gap: 8px 12px;
    align-items: start;
}

.error-message::before {
    content: "!";
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #F26464;
    color: #FFFFFF;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    line-height: 1;
    grid-row: 1 / span 10;
}

.error-message p {
    margin: 2px 0 0;
}

.error-message p + p {
    margin-top: 6px;
}

/* =========================================
   TABLET
========================================= */

@media (max-width: 1100px) {
    body {
        padding: 0;
    }

    .login-wrapper {
        min-height: 100vh;
        border-radius: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 28px 20px 36px;
    }

    .login-logo {
        position: relative;
        top: auto;
        left: auto;
        z-index: 10;
        margin-bottom: 20px;
    }

    .login-logo img {
        width: 190px;
    }

    .login-card {
        position: relative;
        top: auto;
        right: auto;
        transform: none;
        width: min(620px, 100%);
        max-height: none;
        overflow: visible;
        margin-top: auto;
        margin-bottom: auto;
        padding: 42px 44px 38px;
    }
}

/* =========================================
   MOBILE
========================================= */

@media (max-width: 600px) {
    .login-wrapper {
        padding: 18px 12px 28px;
    }

    .login-logo {
        margin-bottom: 14px;
    }

    .login-logo img {
        width: 150px;
    }

    .login-card {
        width: 100%;
        border-radius: 26px;
        padding: 26px 18px 24px;
    }

    .login-heart {
        margin-bottom: 12px;
    }

    .login-heart img {
        width: 36px;
    }

    .login-card h1 {
        font-size: 31px;
    }

    .login-subtitle {
        font-size: 15px;
        line-height: 1.55;
        margin-bottom: 22px;
    }

    .input-group {
        margin-bottom: 14px;
    }

    .input-group input {
        height: 56px;
        border-radius: 15px;
        padding: 0 54px;
        font-size: 16px;
    }

    .input-icon {
        left: 18px;
    }

    .input-icon img {
        width: 20px;
    }

    .password-icon {
        right: 8px;
        width: 42px;
        height: 42px;
        font-size: 19px;
    }

    .login-button {
        height: 58px;
        border-radius: 16px;
        font-size: 21px;
    }

    .forgot-password {
        margin: 14px 0 18px;
        font-size: 15px;
    }

    .login-divider {
        gap: 14px;
        margin-bottom: 18px;
    }

    .register-area p {
        font-size: 15px;
    }

    .register-button {
        width: 100%;
        min-width: 0;
        min-height: 50px;
        font-size: 16px;
    }

    .success-message,
    .error-message {
        margin-bottom: 18px;
        font-size: 15px;
    }
}

@media (max-width: 380px) {
    .login-card {
        padding-left: 14px;
        padding-right: 14px;
    }

    .input-group input {
        padding-left: 48px;
        padding-right: 48px;
    }

    .login-card h1 {
        font-size: 28px;
    }
}
