:root {
    color-scheme: light;
}

* { box-sizing: border-box; }

body.auth-recovery-page {
    min-height: 100dvh;
    margin: 0;
    padding: 22px;
    display: grid;
    place-items: center;
    overflow-x: hidden;
    position: relative;
    font-family: "Segoe UI", system-ui, sans-serif;
    background:
        radial-gradient(circle at 14% 18%, rgba(37, 99, 235, .34), transparent 27%),
        radial-gradient(circle at 86% 82%, rgba(14, 165, 233, .22), transparent 30%),
        linear-gradient(135deg, #071426 0%, #0c2140 48%, #102d57 100%);
}

body.auth-recovery-page::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: .22;
    background-image:
        linear-gradient(rgba(255, 255, 255, .055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .055) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(to bottom right, #000, transparent 72%);
}

body.auth-recovery-page::after {
    content: "";
    position: fixed;
    right: -110px;
    top: -130px;
    width: 380px;
    height: 380px;
    border: 70px solid rgba(96, 165, 250, .09);
    border-radius: 50%;
    pointer-events: none;
}

.recovery-card {
    position: relative;
    z-index: 1;
    width: min(100%, 430px);
    padding: 25px 30px 24px;
    overflow: hidden;
    text-align: center;
    background: #fff;
    border: 1px solid rgba(255, 255, 255, .78);
    border-radius: 22px;
    box-shadow: 0 30px 80px rgba(0, 9, 28, .45), 0 8px 24px rgba(0, 16, 48, .18);
    animation: recoveryIn .45s ease-out;
}

.recovery-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 4px;
    background: linear-gradient(90deg, #2563eb, #38bdf8, #22c55e);
}

.recovery-logo {
    width: auto;
    max-width: 170px;
    height: 66px;
    object-fit: contain;
    filter: drop-shadow(0 5px 9px rgba(15, 23, 42, .16));
}

.recovery-icon {
    width: 42px;
    height: 42px;
    margin: 5px auto 11px;
    display: grid;
    place-items: center;
    color: #1d4ed8;
    background: #eaf2ff;
    border: 1px solid #bfdbfe;
    border-radius: 13px;
    font-size: 1.1rem;
}

.recovery-title {
    margin: 0 0 6px;
    color: #172033;
    font-size: 1.55rem;
    font-weight: 750;
}

.recovery-subtitle {
    margin: 0 0 21px;
    color: #64748b;
    font-size: .9rem;
    line-height: 1.5;
}

.recovery-form { text-align: left; }
.recovery-form .form-label { color: #253047; font-size: .85rem; font-weight: 650; }
.recovery-form .form-control {
    min-height: 46px;
    border-color: #d8e2ef;
    border-radius: 10px;
    color: #172033;
    background: #f8fafc;
}
.recovery-form .form-control:focus {
    border-color: #60a5fa;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, .13);
}
.recovery-form .form-control[readonly] { color: #64748b; background: #f1f5f9; }

.recovery-input-group { position: relative; }
.recovery-input-group .form-control { padding-right: 46px; }
.recovery-password-toggle {
    position: absolute;
    z-index: 3;
    top: 50%;
    right: 5px;
    width: 38px;
    height: 38px;
    transform: translateY(-50%);
    border: 0;
    border-radius: 8px;
    color: #52647d;
    background: transparent;
}
.recovery-password-toggle:hover { color: #1d4ed8; background: #eaf2ff; }

.recovery-sensitive-input { -webkit-text-security: disc; }
.recovery-sensitive-input.is-visible { -webkit-text-security: none; }

.password-security-help {
    margin-top: 8px;
    padding: 10px 12px;
    color: #40536d;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 10px;
    font-size: .78rem;
    line-height: 1.45;
}
.password-security-help i { color: #2563eb; }

.recovery-btn {
    min-height: 47px;
    border: 0;
    border-radius: 10px;
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #1677e8);
    font-weight: 700;
    box-shadow: 0 10px 22px rgba(37, 99, 235, .2);
    transition: transform .18s ease, box-shadow .18s ease;
}
.recovery-btn:hover { color: #fff; transform: translateY(-1px); box-shadow: 0 14px 26px rgba(37, 99, 235, .28); }

.recovery-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 18px;
    color: #315276;
    font-size: .86rem;
    text-decoration: none;
}
.recovery-back:hover { color: #1d4ed8; text-decoration: underline; }

.recovery-alert { border: 0; border-radius: 11px; text-align: left; font-size: .84rem; }

@keyframes recoveryIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 575.98px) {
    body.auth-recovery-page { padding: 15px; align-items: center; }
    .recovery-card { padding: 22px 20px 21px; border-radius: 19px; }
    .recovery-logo { height: 58px; }
    .recovery-title { font-size: 1.35rem; }
}
