/*
 * Shopper sign-up and log-in pages (TMA-18): account/register.liquid, account/login.liquid.
 *
 * Everything is scoped under .lr-auth. The forms themselves are printed by the platform
 * (Kreezalid/Users login_form and register_form elements), so the rules below restyle
 * their markup rather than replace it: field names, CSRF and form-protection tokens stay
 * the platform's.
 */
.lr-auth {
    --lr-green: oklch(90% 0.16 128.41);
    --lr-green-soft: #eefadc;
    --lr-green-ink: #3d7a0f;
    --lr-ink: #1f2328;
    --lr-muted: #5b6573;
    --lr-line: #d5dce4;
    --lr-social: #eff3f8;
    max-width: 480px;
    margin: 0 auto;
    padding: 48px 20px 72px;
    color: var(--lr-ink);
}
.lr-auth h1 {
    margin: 0 0 16px;
    font-size: 34px;
    font-weight: 700;
    line-height: 1.15;
    color: var(--lr-ink);
}
.lr-auth a.lr-auth__link,
.lr-auth .lr-auth__switch a {
    color: var(--lr-green-ink);
    font-weight: 700;
    text-decoration: none;
}
.lr-auth a.lr-auth__link:hover,
.lr-auth .lr-auth__switch a:hover {
    text-decoration: underline;
}
.lr-auth__switch {
    margin: 0 0 28px;
    font-size: 16px;
}

/* Choice screen */
.lr-auth__choice {
    text-align: center;
}
.lr-auth__choice h1 {
    margin-bottom: 10px;
}
.lr-auth__intro {
    margin: 0 auto 32px;
    max-width: 380px;
    color: var(--lr-muted);
    font-size: 15px;
    line-height: 1.5;
}
.lr-auth__footer {
    margin: 28px 0 0;
    color: var(--lr-muted);
    font-weight: 600;
    font-size: 16px;
}

/* Social buttons: the choice screen's own and the platform's block on the login page */
.lr-auth .lr-auth__social,
.lr-auth .social-login-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 52px;
    margin: 0 0 14px;
    padding: 12px 56px;
    border: 0;
    border-radius: 999px;
    background: var(--lr-social);
    color: var(--lr-ink) !important;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none !important;
    transition: background-color .15s ease;
}
.lr-auth .lr-auth__social:hover,
.lr-auth .social-login-btn:hover {
    background: #e2e9f1;
}
.lr-auth .lr-auth__social svg,
.lr-auth .social-login-btn svg {
    position: absolute;
    left: 22px;
    top: 50%;
    width: 24px;
    height: 24px;
    transform: translateY(-50%);
}
.lr-auth .lr-auth__separator,
.lr-auth .social-login-separator {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 26px 0;
    color: var(--lr-muted);
    font-size: 16px;
    font-weight: 700;
    text-transform: lowercase;
}
.lr-auth .lr-auth__separator::before,
.lr-auth .lr-auth__separator::after,
.lr-auth .social-login-separator::before,
.lr-auth .social-login-separator::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--lr-line);
}
.lr-auth .social-login-separator span {
    padding: 0;
}
.lr-auth .social-login {
    margin: 0;
}

.lr-auth__email {
    display: block;
    width: 100%;
    min-height: 52px;
    padding: 12px 24px;
    border: 0;
    border-radius: 999px;
    background: var(--lr-green-soft);
    color: var(--lr-green-ink);
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color .15s ease;
}
.lr-auth__email:hover {
    background: #e2f6c4;
}

/* Two steps: the script adds .is-choice until "S'inscrire par e-mail" is pressed. Without
   the script both stay visible, so the form is always reachable. */
.lr-auth.is-choice .lr-auth__form,
.lr-auth.is-form .lr-auth__choice {
    display: none;
}
.lr-auth.is-form .lr-auth__form {
    animation: lr-auth-in .25s ease both;
}
@keyframes lr-auth-in {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: none; }
}
.lr-auth__choice + .lr-auth__form {
    margin-top: 56px;
}
.lr-auth.is-form .lr-auth__form {
    margin-top: 0;
}
/* The choice screen already offers the social buttons. */
.lr-auth--register .lr-auth__form .social-login {
    display: none;
}

/* Fields */
.lr-auth form .form-group {
    margin: 0 0 20px;
}
.lr-auth form label,
.lr-auth form .form-label {
    display: block;
    margin: 0 0 8px;
    color: var(--lr-ink);
    font-size: 16px;
    font-weight: 700;
}
.lr-auth form .form-control {
    width: 100%;
    height: 52px;
    padding: 12px 16px;
    border: 1px solid var(--lr-line);
    border-radius: 8px;
    background: #fff;
    background-image: none;
    box-shadow: none;
    color: var(--lr-ink);
    font-size: 16px;
}
.lr-auth form .form-control::placeholder {
    color: #94a0b0;
}
.lr-auth form .form-control:focus {
    border-color: var(--lr-green-ink);
    outline: 2px solid var(--lr-green);
    outline-offset: 0;
}
.lr-auth form .input-group {
    display: block;
    width: 100%;
}
.lr-auth form .input-group-addon {
    display: none;
}
.lr-auth form .error-message,
.lr-auth form .help-block {
    margin-top: 6px;
    color: #c0392b;
    font-size: 14px;
}

/* Password visibility */
.lr-auth__password {
    position: relative;
}
.lr-auth__password .form-control {
    padding-right: 52px;
}
.lr-auth__eye {
    position: absolute;
    top: 50%;
    right: 6px;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #5b6573;
    cursor: pointer;
}
.lr-auth__eye:hover {
    background: #f1f4f8;
}
.lr-auth__eye svg {
    width: 22px;
    height: 22px;
}
.lr-auth__eye .lr-auth__eye-open,
.lr-auth__eye.is-shown .lr-auth__eye-closed {
    display: none;
}
.lr-auth__eye.is-shown .lr-auth__eye-open {
    display: block;
}

/* Phone: country and number side by side */
.lr-auth .phone-attribute-wrapper {
    display: flex;
    gap: 10px;
}
.lr-auth .phone-country-wrapper {
    flex: 0 0 40%;
    min-width: 150px;
}
.lr-auth .phone-number-wrapper {
    flex: 1;
}
/* Room for the flag the widget draws inside the country field (left: 12px, 22px wide);
   important because a theme rule already forces this padding. */
.lr-auth .phone-country-wrapper.has-flag .form-control {
    padding-left: 44px !important;
}

/* Consent checkboxes */
.lr-auth form .checkbox label {
    gap: 12px !important;
    font-weight: 400;
    font-size: 15px;
    line-height: 1.45;
}
.lr-auth form .checkbox .form-check {
    margin: 2px 0 0;
}
.lr-auth form .checkbox input[type=checkbox],
.lr-auth form .remember_me_option input[type=checkbox] {
    position: static;
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--lr-green-ink);
}
.lr-auth form .checkbox a {
    color: var(--lr-green-ink);
    font-weight: 700;
}

/* Submit */
.lr-auth form .btn.btn-primary {
    min-height: 54px;
    padding: 12px 36px;
    border: 0;
    border-radius: 999px;
    background: var(--lr-green);
    color: var(--lr-ink);
    font-size: 17px;
    font-weight: 700;
    box-shadow: none;
}
.lr-auth form .btn.btn-primary:hover {
    filter: brightness(.96);
}
.lr-auth--register form .btn.btn-primary {
    width: 100%;
    margin-top: 12px;
}

/* Login: the button with "forgotten password" on its right, then "remember me" */
.lr-auth--login .login-form .text-right {
    text-align: left;
}
.lr-auth__actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 8px;
}
.lr-auth--login form .btn.btn-primary.full-width {
    width: auto;
}
.lr-auth__forgot {
    color: var(--lr-muted) !important;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none !important;
}
.lr-auth__forgot:hover {
    color: var(--lr-ink) !important;
}
.lr-auth--login .remember_me_option {
    margin-top: 18px;
}
.lr-auth--login .remember_me_option .form-check {
    display: flex;
    align-items: center;
    gap: 10px;
}
.lr-auth--login .remember_me_option label {
    margin: 0;
    padding-left: 0;
    font-weight: 400;
}
.lr-auth--login .social-login {
    margin-top: 8px;
}

@media (max-width: 575px) {
    .lr-auth {
        padding: 32px 18px 56px;
    }
    .lr-auth h1 {
        font-size: 28px;
    }
    .lr-auth__actions .btn.btn-primary {
        width: 100% !important;
    }
    .lr-auth--login .login-form .lr-auth__actions {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
}
