/* Scoped to recovery controls: existing login/register styles stay untouched. */
#forgot-password, #recovery-dialog {
    --rx-accent: var(--primary-accent);
    --rx-text: var(--text-color);
    --rx-muted: var(--secondary-text);
    --rx-surface: var(--bg-color);
    --rx-border: var(--border-color);
}
#forgot-password {
    display: inline-block;
    margin-top: 16px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--rx-accent);
    font-family: inherit;
    font-size: .9rem;
    font-weight: 600;
    line-height: normal;
    cursor: pointer;
    text-align: center;
}
#forgot-password:hover:not(:disabled) { text-decoration: underline; }
#forgot-password:focus-visible,
#recovery-dialog :where(button, input):focus-visible {
    outline: 2px solid var(--rx-accent);
    outline-offset: 4px;
}
#forgot-password:disabled,
#recovery-dialog button:disabled {
    cursor: not-allowed;
    opacity: .55;
    transform: none;
    box-shadow: none;
}
#recovery-dialog {
    box-sizing: border-box;
    width: min(520px, calc(100vw - 32px));
    max-width: none;
    max-height: calc(100dvh - 32px);
    overflow-y: auto;
    position: fixed;
    inset: 50dvh auto auto 50vw;
    margin: 0;
    transform: translate(-50%, -50%);
    padding: clamp(20px, 5vw, 40px);
    background: var(--rx-surface);
    color: var(--rx-text);
    font-family: inherit;
    text-align: center;
}
#recovery-dialog::backdrop { backdrop-filter: blur(6px); }
#recovery-dialog [hidden] { display: none !important; }
#recovery-dialog h2 {
    margin: 0 0 20px;
    font-size: 1.5rem;
    font-weight: 600;
    overflow-wrap: anywhere;
}
#recovery-dialog :where(input, button) { font-family: inherit; box-sizing: border-box; }
#recovery-dialog #recovery-status {
    margin: 20px 0 0;
    padding: 12px;
    border: 1px solid var(--rx-border);
    border-radius: 10px;
    line-height: 1.5;
    text-align: left;
    overflow-wrap: anywhere;
}
#recovery-dialog #recovery-status:empty { display: none; }
#recovery-dialog #recovery-close { margin-top: 20px; }
