/* Shared structural styles for pre-login pages.
   Used by Login, Register, ForgotPassword, ResetPassword, InvalidYear,
   ConfirmEmail, RegisterComplete, and OneTimeLogin.
   Page-specific stylesheets override these via CSS variables or by
   defining their own additional rules. */

:root {
    /* Image container */
    --image-container-max-width: 400px;
    --image-container-max-width-small: 300px;
    /* Page background */
    --page-bg-color: #f5f5f5;
    --page-bg-image: url(/Images/Pro/login_bg.png);
    /* Form container */
    --form-container-max-width: 350px;
    --form-input-border-color: #ccc; /* Light gray for input borders */
    --form-button-justify: space-evenly;
    /* Login button colors (overridable per page) */
    --button-simple-bg: #2e7d32; /* Dark green for simple login button */
    --button-simple-color: #ffffff; /* White text for simple login button */
    --button-passkey-bg: #1a1a1a; /* Very dark gray for passkey login button */
    --button-passkey-color: #ffffff; /* White text for passkey login button */
    --button-facebook-bg: #2680eb; /* Facebook blue for Facebook login button */
    --button-facebook-color: #ffffff; /* White text for Facebook login button */
    --button-google-bg: #d9d9d9; /* Light gray for Google login button */
    --button-google-color: #1a1a1a; /* Very dark gray for text on Google login button */
    /* Link */
    --link-color: #2680eb; /* Facebook blue for links on pre-login pages */
}

.page-root {
    background-color: var(--page-bg-color);
    min-height: 100vh;
    height: 100%;
    display: flex;
    -ms-flex-direction: column;
    -webkit-flex-direction: column;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-image: var(--page-bg-image);
    background-size: cover;
    background-position: center;
    overflow-y: auto;
}

.page-sub-root {
    display: flex;
    -ms-flex-direction: column;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-align-items: center;
    align-items: center;
    width: 95%;
}

.form-header {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
    display: flex;
    -ms-flex-direction: column;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-align-items: center;
    align-items: center;
}

.form-header > h1 {
    font-weight: 700;
    font-size: 28px;
}

.form-header > span {
    font-weight: 400;
    width: 95%;
    font-size: 18px;
}

.logo-title-1 {
    font-family: 'PT Serif', serif;
    font-size: 22px;
    letter-spacing: 2px;
}

.logo-title-2 {
    font-family: 'PT Sans', sans-serif;
    font-size: 12px;
}

.form-container {
    max-width: var(--form-container-max-width);
    margin: 0 auto;
    display: flex;
    -ms-flex-direction: column;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: center;
    justify-content: center;
    gap: 4px;
}

    .form-container input {
        width: 100%;
        height: 40px;
        border: 1px solid var(--form-input-border-color);
        border-radius: 5px;
        padding: 5px 10px;
        margin-bottom: 10px;
    }

    .form-container button {
        width: 100%;
        height: 40px;
        border: 1px solid var(--form-input-border-color);
        border-radius: 5px;
        padding: 5px;
        margin-bottom: 10px;
        cursor: pointer;
        display: flex;
        justify-content: var(--form-button-justify);
        font-weight: bold;
        -webkit-align-items: center;
        align-items: center;
        text-align: center;
    }

        .form-container button > span:first-child {
            display: flex;
            flex-direction: column;
            align-items: center;
            -webkit-justify-content: inherit;
            justify-content: inherit;
            width: 20%;
        }

        .form-container button > span:last-child {
            width: 20%;
            visibility: hidden;
        }

        .form-container button > span > img {
            height: 20px;
            aspect-ratio: 1/1;
        }

.button-login-simple {
    background-color: var(--button-simple-bg);
    color: var(--button-simple-color);
}

.button-login-passkey {
    background-color: var(--button-passkey-bg);
    color: var(--button-passkey-color);
}

.button-login-facebook {
    background-color: var(--button-facebook-bg);
    color: var(--button-facebook-color);
}

.button-login-google {
    background-color: var(--button-google-bg);
    color: var(--button-google-color);
}

    .button-login-google > span:nth-child(2n) {
        color: var(--button-google-color) !important;
    }

.link {
    width: 100%;
    text-align: start;
    font-weight: 400;
}

    .link > a {
        text-decoration: none;
        color: var(--link-color);
        font-size: 14px;
        font-weight: bold;
    }

.image-container {
    width: 100%;
    max-width: var(--image-container-max-width);
    margin: 0 auto;
    object-fit: contain;
}

@media (max-height: 750px) {
    .page-root {
        height: unset;
    }

    .image-container {
        max-width: var(--image-container-max-width-small);
    }
}
