:root {
    --forgot-blue-900: #102b72;
    --forgot-blue-700: #2e63e6;
    --forgot-text: #12274e;
    --forgot-soft: #6f84a7;
    --forgot-line: #dbe6f7;
    --forgot-success-bg: #eef7ff;
    --forgot-success-border: #c9e0ff;
    --forgot-success-text: #29518f;
    --forgot-danger: #c62343;
}

* {
    box-sizing: border-box;
}

body.forgot-password-page {
    margin: 0;
    min-height: 100vh;
    font-family: 'Sora', sans-serif;
    color: var(--forgot-text);
    background: #ffffff;
}

.forgot-password-shell,
.forgot-password-stage {
    min-height: 100vh;
}

.forgot-password-panel {
    --login-card-width: min(100%, 440px);
    --login-card-offset-x: -110px;
    --login-card-height: 640px;
}

.forgot-password-visual__content {
    justify-content: center;
}

.forgot-password-card {
    position: relative;
    z-index: 1;
    align-self: flex-start;
    width: var(--login-card-width);
    margin: 0 0 0 var(--login-card-offset-x);
    padding: 34px;
    border: 1px solid rgba(219, 230, 247, 0.92);
    border-radius: 28px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(246, 250, 255, 0.98) 100%);
    box-shadow: 0 20px 44px rgba(16, 43, 114, 0.08);
}

.forgot-password-card__header {
    margin-bottom: 24px;
    text-align: center;
}

.forgot-password-card__logo {
    display: block;
    width: min(150px, 70%);
    max-width: 100%;
    margin: 0 auto 18px;
}

.forgot-password-card__intro h1 {
    margin: 0;
    font-size: clamp(1.6rem, 1.9vw, 2rem);
    line-height: 1.18;
    color: var(--forgot-text);
}

.forgot-password-card__intro p {
    margin: 12px 0 0;
    color: var(--forgot-soft);
    font-size: 0.94rem;
    line-height: 1.7;
}

.forgot-password-status {
    margin-bottom: 18px;
    padding: 13px 14px;
    border: 1px solid var(--forgot-success-border);
    border-radius: 14px;
    background: var(--forgot-success-bg);
    color: var(--forgot-success-text);
    font-size: 0.85rem;
    line-height: 1.55;
}

.forgot-password-form {
    display: grid;
    gap: 18px;
}

.forgot-password-field {
    display: grid;
    gap: 8px;
}

.forgot-password-field > span {
    font-size: 0.86rem;
    font-weight: 700;
    color: #233a67;
}

.forgot-password-field__control {
    position: relative;
}

.forgot-password-field__control svg {
    position: absolute;
    top: 50%;
    left: 16px;
    width: 18px;
    height: 18px;
    color: #8a9ab5;
    transform: translateY(-50%);
    pointer-events: none;
}

.forgot-password-field__control input {
    width: 100%;
    min-height: 54px;
    padding: 0 16px 0 48px;
    border: 1px solid var(--forgot-line);
    border-radius: 16px;
    background: #ffffff;
    font: inherit;
    color: var(--forgot-text);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.forgot-password-field__control input::placeholder {
    color: #99a7bd;
}

.forgot-password-field__control input:focus {
    outline: none;
    border-color: #7aa4ff;
    box-shadow: 0 0 0 4px rgba(46, 99, 230, 0.12);
}

.forgot-password-error {
    color: var(--forgot-danger);
    font-size: 0.8rem;
    font-weight: 600;
}

.forgot-password-actions {
    display: flex;
}

.forgot-password-button {
    width: 100%;
    min-height: 52px;
    border: 0;
    border-radius: 16px;
    background: linear-gradient(180deg, #365fe2 0%, #2348bc 100%);
    color: #ffffff;
    font: inherit;
    font-size: 0.92rem;
    font-weight: 700;
    box-shadow: 0 18px 36px rgba(35, 72, 188, 0.22);
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.2s ease;
}

.forgot-password-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 20px 38px rgba(35, 72, 188, 0.26);
}

.forgot-password-links {
    display: flex;
    justify-content: center;
    margin-top: 16px;
}

.forgot-password-link {
    color: var(--forgot-blue-700);
    font-size: 0.88rem;
    font-weight: 600;
    text-decoration: none;
}

.forgot-password-link:hover {
    color: var(--forgot-blue-900);
}

.forgot-password-footer {
    color: #76839b;
}

@media (max-width: 1024px) {
    .forgot-password-card {
        align-self: center;
        margin: -96px auto 0;
        width: min(100%, 460px);
    }

    .forgot-password-footer {
        position: relative;
        left: auto;
        top: auto;
        min-height: auto;
        width: 100%;
        margin-top: auto;
        padding-top: 24px;
    }
}

@media (min-width: 641px) and (max-width: 1024px) {
    .forgot-password-card {
        width: min(100%, 560px);
        margin-top: -118px;
        padding: 34px 32px 28px;
        border-radius: 30px;
    }

    .forgot-password-card__logo {
        width: 110px;
        margin-bottom: 18px;
    }
}

@media (max-width: 640px) {
    .forgot-password-page {
        height: auto;
        min-height: 100vh;
        min-height: 100dvh;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .forgot-password-shell,
    .forgot-password-stage {
        height: auto;
        min-height: 100vh;
        min-height: 100dvh;
    }

    .forgot-password-card {
        width: 100%;
        margin-top: -88px;
        padding: 24px 20px 20px;
        border-radius: 26px;
        flex-shrink: 0;
    }

    .forgot-password-card__logo {
        width: min(120px, 56%);
        margin: 0 auto 16px;
    }

    .forgot-password-card__intro p {
        font-size: 0.9rem;
    }

    .forgot-password-footer {
        padding-top: 14px;
        padding-bottom: 0;
        flex-shrink: 0;
    }
}
