/* 找回密码页面样式 - PC端 */

/* Reset 已统一到 common/reset.css */

body.page-forgot-password {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-hover, #F7F8FA);
    min-height: 100vh;
    overflow-y: scroll;
    scrollbar-gutter: stable;
}

/* ========== 模态框通用样式 ========== */
body.page-forgot-password .modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-overlay, rgba(0, 0, 0, 0.5));
    z-index: var(--z-toast, 9999);
    align-items: center;
    justify-content: center;
    padding: var(--spacing-lg, 20px);
}

body.page-forgot-password .modal-overlay.show {
    display: flex;
}

body.page-forgot-password .login-container {
    display: flex;
    width: 100%;
    min-height: 100vh;
    background: var(--bg-card, #fff);
    overflow-x: hidden;
    overflow-y: auto;
}

/* ========== 左侧品牌展示区 ========== */
body.page-forgot-password .brand-section {
    width: 55%;
    background: linear-gradient(135deg, var(--color-info, #165DFF) 0%, var(--color-info-dark, #0F3DA8) 50%, var(--color-info, #1E6FE5) 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 32px 24px;
    color: var(--text-inverse, #fff);
}

body.page-forgot-password .brand-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(135deg, rgba(var(--color-info-rgb), 0.3) 0%, rgba(var(--color-info-dark-rgb), 0.25) 50%, rgba(30, 111, 229, 0.3) 100%),
        radial-gradient(circle at 20% 30%, rgba(255,255,255,0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255,255,255,0.08) 0%, transparent 40%),
        linear-gradient(45deg, transparent 40%, rgba(255,255,255,0.05) 50%, transparent 60%);
    pointer-events: none;
    z-index: 1;
}

body.page-forgot-password .brand-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.3;
    pointer-events: none;
    z-index: 1;
}

body.page-forgot-password .brand-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    z-index: 0;
}

body.page-forgot-password .brand-content {
    position: relative;
    z-index: 2;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 40px;
    gap: var(--spacing-xxl, 32px);
}

body.page-forgot-password .logo-area {
    display: flex;
    align-items: center;
    gap: var(--spacing-md, 16px);
    text-decoration: none;
    color: var(--text-inverse, #fff);
    cursor: pointer;
    transition: opacity 0.3s ease;
}

body.page-forgot-password .logo-area:hover {
    opacity: 0.9;
}

body.page-forgot-password .logo-icon {
    width: 56px;
    height: 56px;
    aspect-ratio: 1 / 1;
    border-radius: var(--radius-lg, 12px);
    overflow: hidden;
    background: rgba(255,255,255,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

body.page-forgot-password .logo-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
}

body.page-forgot-password .logo-text h1 {
    font-size: 28px;
    font-weight: 600;
    margin: 0 0 4px 0;
    letter-spacing: 1px;
}

body.page-forgot-password .logo-text p {
    font-size: var(--font-base, 14px);
    color: rgba(255,255,255,0.7);
    margin: 0;
}

body.page-forgot-password .footer-info {
    position: relative;
    z-index: 2;
    font-size: var(--font-xs, 12px);
    opacity: 0.6;
    line-height: 1.8;
    text-align: center;
}

body.page-forgot-password .footer-info p {
    margin: 0;
}

/* ========== 右侧找回密码功能区 ========== */
body.page-forgot-password .login-section {
    width: 45%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card, #fff);
    padding: 40px;
}

body.page-forgot-password .forgot-password-card {
    width: 100%;
    max-width: 420px;
    background: var(--bg-card, #fff);
    border-radius: var(--radius-xl, 16px);
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    animation: forgotFadeIn 0.6s ease;
}

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

/* ========== 安全提示 ========== */
body.page-forgot-password .security-tip {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm, 8px);
    padding: 10px 14px;
    background: rgba(var(--color-success-rgb), 0.08);
    border-radius: var(--radius-md, 8px);
    font-size: var(--font-sm, 13px);
    color: var(--color-success, #00B42A);
    margin-bottom: var(--spacing-lg, 20px);
    animation: securityPulse 2s ease-in-out infinite;
}

@keyframes securityPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ========== 标题区 ========== */
body.page-forgot-password .forgot-password-header {
    text-align: center;
    margin-bottom: 28px;
}

body.page-forgot-password .forgot-password-header h2 {
    font-size: var(--font-title, 24px);
    font-weight: 600;
    color: var(--text-primary, #1D2129);
    margin: 0 0 10px 0;
}

body.page-forgot-password .forgot-desc {
    font-size: var(--font-sm, 13px);
    color: var(--text-secondary, #86909C);
    margin: 0;
    line-height: 1.6;
}

/* ========== Toast消息 ========== */
body.page-forgot-password .toast-message {
    padding: 10px 16px;
    border-radius: var(--radius-md, 8px);
    font-size: var(--font-sm, 13px);
    margin-bottom: var(--spacing-md, 16px);
    display: none;
    text-align: center;
    animation: toastPop 0.3s ease;
}

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

body.page-forgot-password .toast-info {
    background: var(--color-info-soft, #F2F7FF);
    color: var(--color-info, #165DFF);
    border: 1px solid var(--brand-soft-border, #BEDAFF);
}

body.page-forgot-password .toast-success {
    background: var(--color-success-soft, #E8FFEA);
    color: var(--color-success, #00B42A);
    border: 1px solid var(--color-success-soft, #A8E6B0);
}

body.page-forgot-password .toast-error {
    background: var(--color-error-soft, #FFF0F0);
    color: var(--color-error, #F53F3F);
    border: 1px solid var(--color-error-soft, #FFCDD2);
}

/* ========== 表单 ========== */
body.page-forgot-password .login-form {
    display: flex;
    flex-direction: column;
}

body.page-forgot-password .login-form .form-group {
    margin-bottom: 18px;
}

/* ========== 验证方式选择 ========== */
body.page-forgot-password .form-label {
    display: inline-block;
    font-size: var(--font-sm, 13px);
    color: var(--text-regular, #4E5969);
    margin-bottom: var(--spacing-sm, 8px);
    font-weight: 500;
}

body.page-forgot-password .contact-type-selector {
    display: flex;
    gap: var(--spacing-base, 12px);
}

body.page-forgot-password .contact-type-option {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 12px 16px;
    border: 2px solid var(--border-base, #E5E6EB);
    border-radius: 10px;
    cursor: pointer;
    transition: var(--transition-base);
    font-size: var(--font-base, 14px);
    color: var(--text-regular, #4E5969);
    background: var(--bg-hover, #F7F8FA);
    position: relative;
    overflow: hidden;
}

body.page-forgot-password .contact-type-option::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(var(--color-info-rgb), 0.06) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

body.page-forgot-password .contact-type-option:hover {
    border-color: var(--brand-soft-border, #BEDAFF);
    background: var(--color-info-soft, #F2F7FF);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(var(--color-info-rgb), 0.1);
}

body.page-forgot-password .contact-type-option.active {
    border-color: var(--color-info, #165DFF);
    color: var(--color-info, #165DFF);
    background: var(--color-info-soft, #F2F7FF);
    font-weight: 500;
    box-shadow: 0 2px 12px rgba(var(--color-info-rgb), 0.15);
}

body.page-forgot-password .contact-type-option.active::before {
    opacity: 1;
}

body.page-forgot-password .contact-type-option input[type="radio"] {
    display: none;
}

/* ========== 验证码行 ========== */
body.page-forgot-password .verify-row {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

body.page-forgot-password .verify-input {
    flex: 1;
}

body.page-forgot-password .verify-btn {
    flex-shrink: 0;
    min-width: 110px;
    height: 44px;
    padding: 0 16px;
    border: 1.5px solid var(--color-info, #165DFF);
    border-radius: var(--radius-md, 8px);
    background: var(--bg-card, #fff);
    color: var(--color-info, #165DFF);
    font-size: var(--font-sm, 13px);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-base);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

body.page-forgot-password .verify-btn:hover:not(:disabled) {
    background: var(--color-info-soft, #F2F7FF);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(var(--color-info-rgb), 0.15);
}

body.page-forgot-password .verify-btn:active:not(:disabled) {
    transform: translateY(0);
}

body.page-forgot-password .verify-btn:disabled {
    border-color: var(--border-dark, #C9CDD4);
    color: var(--text-disabled, #C9CDD4);
    background: var(--bg-hover, #F7F8FA);
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

body.page-forgot-password .verify-btn.counting {
    border-color: var(--border-dark, #C9CDD4);
    color: var(--text-secondary, #86909C);
    background: var(--bg-hover, #F7F8FA);
}

/* ========== 提交按钮 ========== */
body.page-forgot-password .login-btn {
    margin-top: 10px;
    width: 100%;
    height: 44px;
    border: none;
    border-radius: var(--radius-md, 8px);
    background: linear-gradient(135deg, var(--color-info, #165DFF) 0%, var(--color-info-dark, #0F3DA8) 100%);
    color: var(--text-inverse, #fff);
    font-size: var(--font-md, 15px);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-base);
    position: relative;
    overflow: hidden;
}

body.page-forgot-password .login-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

body.page-forgot-password .login-btn:hover::before {
    left: 100%;
}

body.page-forgot-password .login-btn:hover {
    background: linear-gradient(135deg, var(--color-info-dark, #0D47A1) 0%, var(--color-info-dark, #0A2E70) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(var(--color-info-rgb), 0.4);
}

body.page-forgot-password .login-btn:active {
    transform: translateY(0);
    box-shadow: 0 3px 10px rgba(var(--color-info-rgb), 0.3);
}

body.page-forgot-password .login-btn:disabled {
    background: var(--text-disabled, #BBBFC4);
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

body.page-forgot-password .login-btn:disabled::before {
    display: none;
}

/* ========== 底部链接 ========== */
body.page-forgot-password .form-footer {
    text-align: center;
    margin-top: var(--spacing-lg, 20px);
}

body.page-forgot-password .back-link {
    font-size: var(--font-base, 14px);
    color: var(--color-info, #165DFF);
    text-decoration: none;
    transition: var(--transition-base);
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs, 4px);
}

body.page-forgot-password .back-link:hover {
    color: var(--color-info-dark, #0D47A1);
    transform: translateX(-2px);
}

/* ========== 成功提示 ========== */
body.page-forgot-password .success-box {
    text-align: center;
    padding: 48px 32px;
    animation: forgotFadeIn 0.5s ease;
}

body.page-forgot-password .success-icon {
    margin-bottom: var(--spacing-lg, 20px);
    animation: successBounce 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes successBounce {
    0% { transform: scale(0); opacity: 0; }
    60% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

body.page-forgot-password .success-box h3 {
    font-size: var(--font-xxl, 20px);
    color: var(--text-primary, #1D2129);
    margin: 0 0 10px 0;
    font-weight: 600;
}

body.page-forgot-password .success-box p {
    font-size: var(--font-base, 14px);
    color: var(--text-secondary, #86909C);
    margin: 0 0 28px 0;
    line-height: 1.6;
}

body.page-forgot-password .success-box .login-btn {
    display: inline-block;
    width: auto;
    padding: 12px 48px;
    text-decoration: none;
    font-size: var(--font-md, 15px);
}

/* ========== 错误信息 ========== */
body.page-forgot-password .error-message {
    display: block;
    font-size: var(--font-xs, 12px);
    color: var(--color-error, #F53F3F);
    margin-top: var(--spacing-xs, 4px);
    min-height: 16px;
    line-height: 1.2;
}

/* ========== 响应式适配 ========== */
@media (max-width: 768px) {
    body.page-forgot-password .login-container {
        flex-direction: column;
    }

    body.page-forgot-password .brand-section {
        width: 100%;
        min-height: 180px;
        padding: 24px 20px;
    }

    body.page-forgot-password .brand-content {
        padding-top: 0;
    }

    body.page-forgot-password .login-section {
        width: 100%;
        padding: 24px 16px;
    }

    body.page-forgot-password .forgot-password-card {
        max-width: 100%;
        padding: 28px 24px;
        box-shadow: 0 4px 16px rgba(0,0,0,0.06);
    }

    body.page-forgot-password .forgot-password-header h2 {
        font-size: var(--font-xxl, 20px);
    }
}

@media (max-width: 480px) {
    body.page-forgot-password .forgot-password-card {
        padding: 24px 20px;
    }

    body.page-forgot-password .contact-type-option {
        padding: 10px 12px;
        font-size: var(--font-sm, 13px);
    }

    body.page-forgot-password .verify-btn {
        min-width: 96px;
        font-size: var(--font-xs, 12px);
    }
}

@media (min-width: 1440px) {
    body.page-forgot-password {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 20px 0;
    }

    body.page-forgot-password .login-container {
        width: 100%;
        max-width: 1400px;
        height: auto;
        min-height: 700px;
        border-radius: var(--radius-xl, 16px);
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
        overflow-x: hidden;
        overflow-y: auto;
    }

    body.page-forgot-password .brand-section {
        padding: 48px 40px;
    }

    body.page-forgot-password .forgot-password-card {
        padding: 40px;
    }
}

@media (min-width: 1920px) {
    body.page-forgot-password .login-container {
        max-width: 1600px;
        min-height: 800px;
    }

    body.page-forgot-password .brand-section {
        padding: 64px 56px;
    }

    body.page-forgot-password .forgot-password-card {
        padding: 48px;
    }
}

/* ===== 可访问性：焦点高亮（仅表单控件保留，按钮/图标按钮统一不画方框） ===== */
input[type=text]:focus-visible,
input[type=password]:focus-visible,
input[type=email]:focus-visible,
input[type=tel]:focus-visible,
input[type=number]:focus-visible,
input[type=search]:focus-visible,
input[type=url]:focus-visible,
input[type=date]:focus-visible,
input[type=time]:focus-visible,
input[type=datetime-local]:focus-visible,
input[type=month]:focus-visible,
input[type=week]:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid var(--color-primary, #667eea);
    outline-offset: 2px;
}

/* 所有按钮、a 、tabindex 元素、aria role=button/tab —— 一律去掉焦点框（用户要求无外边框） */
button:focus-visible,
button:focus,
a:focus,
a:focus-visible,
li:focus,
li:focus-visible,
[tabindex]:focus,
[tabindex]:focus-visible,
[role="button"]:focus,
[role="button"]:focus-visible,
[role="tab"]:focus,
[role="tab"]:focus-visible {
    outline: none !important;
    box-shadow: none !important;
    border: none;
}
