:root {
    --recovery-bg: #f8fafc;
    --recovery-card: #ffffff;

    --text: #0f172a;
    --muted: #64748b;
    --soft: #94a3b8;

    --border: #e2e8f0;
    --border-soft: #edf2f7;

    --blue: #2563eb;
    --blue-soft: #dbeafe;

    --purple: #7c3aed;
    --purple-soft: #ede9fe;

    --green: #16a34a;
    --green-soft: #dcfce7;

    --red: #dc2626;
    --red-soft: #fee2e2;
}

* {
    box-sizing: border-box;
}

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

body {
    margin: 0;
    font-family:
            Inter,
            ui-sans-serif,
            system-ui,
            -apple-system,
            BlinkMacSystemFont,
            "Segoe UI",
            sans-serif;
    background: var(--recovery-bg);
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input {
    font: inherit;
}

/* Page */
.recoveryShell {
    max-width: 1240px;
    margin: 86px auto 0;
    display: grid;
    /*grid-template-columns: 1fr 480px;*/
    grid-template-columns:
    minmax(420px, 0.92fr)
    minmax(520px, 1.08fr);
    gap: 76px;
    align-items: center;
    min-height: 100vh;
}

/* Left branding panel */

.recoveryBrandPanel {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 42px 48px 30px;
    color: #ffffff;
}

.brandGlow {
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
    filter: blur(22px);
}

.brandGlowOne {
    top: -100px;
    left: -130px;
    width: 360px;
    height: 360px;
    background: rgba(124, 58, 237, 0.25);
}

.brandGlowTwo {
    right: -160px;
    bottom: -150px;
    width: 430px;
    height: 430px;
    background: rgba(37, 99, 235, 0.2);
}

.brandContent {
    position: relative;
    z-index: 1;
    width: min(100%, 620px);
    display: flex;
    flex: 1;
    flex-direction: column;
}

.brand {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 13px;
}

.brandMark {
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(
            135deg,
            #2563eb,
            #7c3aed
    );
    box-shadow:
            0 16px 40px
            rgba(37, 99, 235, 0.32);
    font-size: 18px;
    font-weight: 900;
}

.brandText strong,
.brandText small {
    display: block;
}

.brandText strong {
    color: #ffffff;
    font-size: 21px;
    letter-spacing: -0.04em;
}

.brandText small {
    margin-top: 2px;
    color: #cbd5e1;
    font-size: 10px;
    font-weight: 700;
}

.brandHero {
    /*margin-top: auto;*/
    /*padding-top: 90px;*/
}

.brandEyebrow {
    display: inline-flex;
    border: 1px solid
    rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    padding: 7px 10px;
    color: #ddd6fe;
    background:
            rgba(255, 255, 255, 0.07);
    font-size: 10px;
    font-weight: 900;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.brandHero h1 {
    max-width: 580px;
    margin: 18px 0 0;
    font-size: clamp(36px, 4vw, 55px);
    line-height: 1.05;
    letter-spacing: -0.065em;
}

.brandHero > p {
    max-width: 550px;
    margin: 18px 0 0;
    color: #cbd5e1;
    line-height: 1.7;
    font-size: 15px;
}

.securityHighlights {
    display: grid;
    gap: 14px;
    margin-top: 36px;
}

.securityHighlight {
    display: grid;
    grid-template-columns:
    42px minmax(0, 1fr);
    gap: 13px;
    align-items: start;
}

.securityHighlight > span {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 1px solid
    rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    color: #c4b5fd;
    background:
            rgba(255, 255, 255, 0.07);
    font-weight: 900;
}

.securityHighlight strong {
    display: block;
    font-size: 13px;
}

.securityHighlight p {
    max-width: 450px;
    margin: 5px 0 0;
    color: #94a3b8;
    line-height: 1.45;
    font-size: 11px;
}

.brandFooter {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 60px;
    color: #64748b;
    font-size: 10px;
}

.brandFooter div {
    display: flex;
    gap: 16px;
}

.brandFooter a:hover {
    color: #cbd5e1;
}

/* Form side */

.recoveryFormPanel {
    min-height: 100vh;
    /*display: flex;*/
    /*flex-direction: column;*/
    /*background:
            radial-gradient(
                    circle at 100% 0%,
                    rgba(124, 58, 237, 0.05),
                    transparent 30%
            ),
            #f8fafc;*/
}

.mobileBrand {
    display: none;
}

.recoveryCardWrapper {
    width: 100%;
    max-width: 570px;
    margin: auto;
    padding: 50px 32px;
}

.recoveryCard {
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 34px;
    background: #ffffff;
    box-shadow:
            0 28px 80px
            rgba(15, 23, 42, 0.09);
}

.recoveryIcon,
.successIcon {
    width: 62px;
    height: 62px;
    display: grid;
    place-items: center;
    border-radius: 18px;
    font-size: 23px;
    font-weight: 900;
}

.recoveryIcon {
    color: #7c3aed;
    background:
            linear-gradient(
                    135deg,
                    #eff6ff,
                    #ede9fe
            );
}

.successIcon {
    color: #16a34a;
    background: #dcfce7;
}

.recoveryHeader {
    margin-top: 23px;
}

.recoveryHeader h2 {
    margin: 0;
    color: #0f172a;
    font-size: 30px;
    letter-spacing: -0.055em;
}

.recoveryHeader > p {
    margin: 10px 0 0;
    color: #64748b;
    line-height: 1.6;
    font-size: 14px;
}

.recoveryHeader > p strong {
    color: #334155;
}

/* Form */

.recoveryForm {
    display: grid;
    gap: 20px;
    margin-top: 27px;
}

.formField {
    display: grid;
    gap: 8px;
}

.formField > span:first-child {
    color: #0f172a;
    font-size: 12px;
    font-weight: 900;
}

.inputWrapper {
    height: 49px;
    display: grid;
    grid-template-columns:
    43px minmax(0, 1fr);
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 11px;
    overflow: hidden;
    background: #ffffff;
    transition:
            border-color 0.15s ease,
            box-shadow 0.15s ease;
}

.inputWrapper:focus-within {
    border-color:
            rgba(124, 58, 237, 0.72);
    box-shadow:
            0 0 0 4px
            rgba(124, 58, 237, 0.08);
}

.inputIcon {
    height: 100%;
    display: grid;
    place-items: center;
    border-right:
            1px solid var(--border-soft);
    color: #64748b;
    background: #f8fafc;
    font-weight: 900;
}

.inputWrapper input {
    width: 100%;
    height: 100%;
    border: 0;
    outline: none;
    padding: 0 13px;
    color: #0f172a;
    background: transparent;
}

.inputWrapper input::placeholder {
    color: #94a3b8;
}

.formField.hasError
.inputWrapper {
    border-color: #ef4444;
    background: #fffafa;
}

.formField.hasError
.inputWrapper:focus-within {
    border-color: #dc2626;
    box-shadow:
            0 0 0 4px
            rgba(220, 38, 38, 0.08);
}

.fieldError {
    display: none;
    align-items: center;
    gap: 6px;
    color: #dc2626;
    font-size: 11px;
    font-weight: 700;
}

.fieldError.is-visible {
    display: flex;
}

.fieldError i {
    width: 17px;
    height: 17px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #ffffff;
    background: #dc2626;
    font-size: 8px;
    font-style: normal;
    font-weight: 900;
}

.recoveryButton {
    min-height: 49px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border: 0;
    border-radius: 11px;
    color: #ffffff;
    background:
            linear-gradient(
                    135deg,
                    #2563eb,
                    #7c3aed
            );
    box-shadow:
            0 16px 34px
            rgba(37, 99, 235, 0.2);
    cursor: pointer;
    font-weight: 900;
}

.recoveryButton:disabled {
    cursor: not-allowed;
    opacity: 0.65;
}

.spinner {
    width: 17px;
    height: 17px;
    border: 2px solid
    rgba(255, 255, 255, 0.35);
    border-top-color: #ffffff;
    border-radius: 999px;
    animation:
            recoverySpin 0.8s linear infinite;
}

@keyframes recoverySpin {
    to {
        transform: rotate(360deg);
    }
}

/* Generic security notice */

.securityNotice {
    display: grid;
    grid-template-columns:
    34px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    margin-top: 20px;
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    padding: 12px;
    color: #1e3a8a;
    background: #eff6ff;
}

.securityNotice > span {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    color: #2563eb;
    background: #ffffff;
    font-weight: 900;
}

.securityNotice p {
    margin: 0;
    line-height: 1.45;
    font-size: 10px;
}

.backToSignIn {
    margin-top: 24px;
    text-align: center;
}

.backToSignIn a {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #2563eb;
    font-size: 12px;
    font-weight: 900;
}

/* Error banner */

.errorBanner {
    display: grid;
    grid-template-columns:
    38px minmax(0, 1fr);
    gap: 11px;
    margin-top: 20px;
    border: 1px solid #fecaca;
    border-radius: 12px;
    padding: 13px;
    color: #991b1b;
    background: #fef2f2;
}

.errorBanner > span {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    color: #dc2626;
    background: #ffffff;
    font-weight: 900;
}

.errorBanner strong {
    display: block;
    font-size: 11px;
}

.errorBanner p {
    margin: 4px 0 0;
    font-size: 10px;
}

/* Success */

.successEyebrow {
    display: inline-flex;
    margin-bottom: 7px;
    border-radius: 999px;
    padding: 6px 9px;
    color: #16a34a;
    background: #dcfce7;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.emailSentCard {
    display: grid;
    grid-template-columns:
    47px minmax(0, 1fr);
    gap: 13px;
    align-items: center;
    margin-top: 23px;
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 14px;
    background: #f8fafc;
}

.emailSentIcon {
    width: 45px;
    height: 45px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #2563eb;
    background: #dbeafe;
    font-size: 17px;
}

.emailSentCard span,
.emailSentCard strong {
    display: block;
}

.emailSentCard span {
    color: #64748b;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
}

.emailSentCard strong {
    margin-top: 3px;
    color: #0f172a;
    font-size: 13px;
}

.emailSentCard p {
    margin: 4px 0 0;
    color: #64748b;
    line-height: 1.4;
    font-size: 10px;
}

.recoverySteps {
    display: grid;
    gap: 15px;
    margin-top: 24px;
}

.recoveryStep {
    display: grid;
    grid-template-columns:
    34px minmax(0, 1fr);
    gap: 11px;
    align-items: start;
}

.recoveryStep > span {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #7c3aed;
    background: #ede9fe;
    font-size: 10px;
    font-weight: 900;
}

.recoveryStep strong {
    display: block;
    color: #0f172a;
    font-size: 12px;
}

.recoveryStep p {
    margin: 4px 0 0;
    color: #64748b;
    line-height: 1.45;
    font-size: 10px;
}

.resendSection {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin-top: 24px;
    color: #64748b;
    font-size: 11px;
}

.resendSection button {
    border: 0;
    padding: 0;
    color: #2563eb;
    background: transparent;
    cursor: pointer;
    font-weight: 900;
}

.resendSection button:disabled {
    opacity: 0.5;
}

.returnButton {
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 18px;
    border-radius: 11px;
    color: #ffffff;
    background:
            linear-gradient(
                    135deg,
                    #2563eb,
                    #7c3aed
            );
    font-weight: 900;
}

.successHelp {
    display: grid;
    grid-template-columns:
    32px minmax(0, 1fr);
    gap: 9px;
    align-items: center;
    margin-top: 18px;
    color: #64748b;
}

.successHelp > span {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    color: #64748b;
    background: #f1f5f9;
    font-size: 10px;
    font-weight: 900;
}

.successHelp p {
    margin: 0;
    line-height: 1.4;
    font-size: 10px;
}

/* Mobile */

.mobileFooter {
    display: none;
}

/* Responsive */

@media (max-width: 980px) {
    .recoveryPage {
        grid-template-columns: 1fr;
    }

    .recoveryBrandPanel {
        display: none;
    }

    .recoveryFormPanel {
        min-height: 100vh;
    }

    .mobileBrand {
        display: block;
        padding: 24px;
    }

    .mobileBrand .brandText small {
        display: none;
    }

    .mobileBrand .brandText strong {
        color: #0f172a;
    }

    .recoveryCardWrapper {
        padding-top: 20px;
    }

    .mobileFooter {
        display: block;
        padding: 20px;
        color: #94a3b8;
        text-align: center;
        font-size: 9px;
    }
}

@media (max-width: 600px) {
    .recoveryCardWrapper {
        padding:
                12px 16px 32px;
    }

    .recoveryCard {
        padding: 24px 20px;
        border-radius: 18px;
    }

    .recoveryHeader h2 {
        font-size: 26px;
    }

    .resendSection {
        align-items: flex-start;
        flex-direction: column;
    }
}



/* Password Reset */

.passwordInputWrapper {
    position: relative;
}

.passwordInputWrapper input {
    padding-right: 72px;
}

.passwordToggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);

    border: 0;
    background: transparent;

    color: #667085;
    font-size: 13px;
    font-weight: 600;

    cursor: pointer;
}

.passwordToggle:hover {
    color: #344054;
}

.passwordToggle:focus-visible {
    outline: 2px solid #6c63ff;
    outline-offset: 2px;
    border-radius: 4px;
}


/* Password requirements */

.passwordRequirements {
    margin-top: -4px;
    padding: 14px 16px;

    border: 1px solid #eaecf0;
    border-radius: 10px;

    background: #f9fafb;
}

.passwordRequirements > p {
    margin: 0 0 10px;

    color: #475467;
    font-size: 13px;
    font-weight: 600;
}

.passwordRequirements ul {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 7px 16px;

    margin: 0;
    padding: 0;

    list-style: none;
}

.passwordRequirements li {
    display: flex;
    align-items: center;
    gap: 7px;

    color: #667085;
    font-size: 12px;
}

.passwordRequirements li span {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 16px;
    height: 16px;

    border: 1px solid #d0d5dd;
    border-radius: 50%;

    color: transparent;
    font-size: 10px;

    background: #fff;
}

.passwordRequirements li.valid {
    color: #027a48;
}

.passwordRequirements li.valid span {
    border-color: #abefc6;
    background: #ecfdf3;
    color: #027a48;
}


/* Invalid fields */

.inputWrapper:has(input[aria-invalid="true"]) {
    border-color: #f04438;
    box-shadow: 0 0 0 3px rgba(240, 68, 56, 0.08);
}

@media (max-width: 640px) {
    .passwordRequirements ul {
        grid-template-columns: 1fr;
    }
}