/* ========================================
   密码重置页面 - 样式表
   与 exam-report.css 风格保持一致
   ======================================== */

:root {
    /* 主色调 */
    --primary-gradient: linear-gradient(135deg, #0072ff 0%, #00c6ff 100%);
    --primary-color: #0072ff;
    --primary-light: #00c6ff;
    --primary-dark: #0055cc;

    /* 辅助色 */
    --success-color: #52c41a;
    --warning-color: #faad14;
    --danger-color: #ff4d4f;

    /* 中性色 */
    --text-primary: #333333;
    --text-secondary: #666666;
    --text-muted: #999999;
    --border-color: #e8e8e8;
    --bg-light: #f5f7fa;

    /* 阴影 */
    --card-shadow: 0 10px 40px rgba(0, 114, 255, 0.15);
    --input-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    --hover-shadow: 0 8px 25px rgba(0, 114, 255, 0.25);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    min-height: 100vh;
    background: var(--bg-light);
}

.container {
    display: flex;
    min-height: 100vh;
}

/* ========================================
   左侧装饰区域
   ======================================== */

.left-section {
    flex: 1;
    background: var(--primary-gradient);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.decoration-circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}

.circle-1 {
    width: 400px;
    height: 400px;
    top: -100px;
    right: -100px;
    animation: float 6s ease-in-out infinite;
}

.circle-2 {
    width: 300px;
    height: 300px;
    bottom: -50px;
    left: -50px;
    animation: float 8s ease-in-out infinite reverse;
}

.circle-3 {
    width: 150px;
    height: 150px;
    top: 50%;
    left: 30%;
    animation: pulse 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.1; }
    50% { transform: scale(1.1); opacity: 0.2; }
}

.decoration-lines {
    position: absolute;
    right: 10%;
    top: 20%;
}

.decoration-lines .line {
    width: 80px;
    height: 3px;
    background: rgba(255, 255, 255, 0.3);
    margin-bottom: 15px;
    border-radius: 2px;
}

.decoration-lines .line:nth-child(2) {
    width: 60px;
    margin-left: 20px;
}

.decoration-lines .line:nth-child(3) {
    width: 40px;
    margin-left: 40px;
}

.left-content {
    text-align: center;
    color: white;
    z-index: 1;
    padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.logo {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    backdrop-filter: blur(10px);
}

.logo i {
    font-size: 48px;
    color: white;
}

.left-content h1 {
    font-size: 36px;
    font-weight: 600;
    margin-bottom: 15px;
    letter-spacing: 2px;
}

.left-content > p {
    font-size: 16px;
    opacity: 0.9;
    letter-spacing: 3px;
    margin-bottom: 45px;
}

.features {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 25px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(10px);
}

.feature-item i {
    font-size: 20px;
    width: 30px;
    text-align: center;
    flex-shrink: 0;
}

.feature-item span {
    font-size: 16px;
    letter-spacing: 1px;
}

/* ========================================
   右侧表单区域
   ======================================== */

.right-section {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    background: var(--bg-light);
}

.form-container {
    width: 100%;
    max-width: 480px;
    background: white;
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    padding: 50px 40px;
    animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-header {
    text-align: center;
    margin-bottom: 35px;
}

.user-avatar {
    width: 80px;
    height: 80px;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 8px 25px rgba(0, 114, 255, 0.3);
}

.user-avatar i {
    font-size: 36px;
    color: white;
}

.form-header h2 {
    font-size: 26px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.form-header p {
    font-size: 14px;
    color: var(--text-muted);
}

/* 表单标签 */
.input-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
    padding-left: 5px;
}

/* 输入组 */
.input-group {
    margin-bottom: 22px;
}

.input-wrapper {
    display: flex;
    align-items: center;
    position: relative;
    width: 100%;
}

.input-icon {
    width: 54px;
    min-width: 54px;
    height: 54px;
    background: var(--primary-gradient);
    border-radius: 12px 0 0 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    margin: 0;
    padding: 0;
}

.input-icon i {
    font-size: 22px;
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.input-group input {
    width: 100%;
    height: 54px;
    padding: 0 18px 0 15px;
    border: 2px solid #e0e0e0;
    border-left: none;
    border-radius: 0 12px 12px 0;
    font-size: 15px;
    font-family: inherit;
    color: #333;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: white;
    box-shadow: var(--input-shadow);
}

.input-group input:focus + .input-icon,
.input-wrapper:focus-within .input-icon {
    box-shadow: inset 0 0 0 2px var(--primary-light);
}

.input-wrapper:focus-within .input-icon {
    background: linear-gradient(135deg, #0055cc 0%, #00a8e0 100%);
}

/* 密码显示切换 */
.password-toggle {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--text-muted);
    transition: all 0.3s ease;
    z-index: 2;
    padding: 8px;
}

.password-toggle:hover {
    color: var(--primary-color);
}

.password-toggle i {
    font-size: 18px;
}

/* 验证码按钮 */
.code-wrapper {
    position: relative;
}

.code-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    height: 38px;
    padding: 0 16px;
    background: var(--success-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    font-family: inherit;
    z-index: 2;
}

.code-btn:hover:not(:disabled) {
    background: #3dad13;
    box-shadow: 0 4px 12px rgba(82, 196, 26, 0.35);
}

.code-btn:active:not(:disabled) {
    transform: translateY(-50%) scale(0.97);
}

.code-btn:disabled {
    background: #b7eb8f;
    color: white;
    cursor: not-allowed;
}

.code-btn.counting {
    background: #d9d9d9;
    color: #999;
}

/* 提交按钮 */
.submit-btn {
    width: 100%;
    height: 54px;
    background: var(--primary-gradient);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
    letter-spacing: 4px;
    margin-top: 10px;
    position: relative;
    overflow: hidden;
}

.submit-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;
}

.submit-btn:hover::before {
    left: 100%;
}

.submit-btn:hover {
    box-shadow: var(--hover-shadow);
    transform: translateY(-2px);
}

.submit-btn:active {
    transform: translateY(0);
}

/* 底部返回链接 */
.form-footer {
    margin-top: 28px;
    text-align: center;
    padding-top: 22px;
    border-top: 1px solid var(--border-color);
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--primary-color);
    font-size: 14px;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

.back-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.back-link i {
    font-size: 13px;
}

/* ========================================
   加载动画
   ======================================== */

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    backdrop-filter: blur(4px);
}

.spinner {
    text-align: center;
    color: white;
}

.spinner-circle {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.spinner p {
    font-size: 15px;
    letter-spacing: 2px;
}

/* ========================================
   Toast提示
   ======================================== */

.toast {
    position: fixed;
    top: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(-80px);
    background: white;
    padding: 14px 28px;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 10000;
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    max-width: 400px;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
}

.toast i {
    font-size: 20px;
    color: var(--success-color);
}

.toast.error i {
    color: var(--danger-color);
}

.toast span {
    font-size: 14px;
    color: var(--text-primary);
}

/* ========================================
   成功弹窗
   ======================================== */

.success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
}

.success-modal.show {
    display: flex;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: white;
    border-radius: 24px;
    padding: 50px 40px;
    text-align: center;
    max-width: 400px;
    width: 90%;
    animation: modalSlideUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #52c41a, #73d13d);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    animation: successPop 0.5s ease 0.2s both;
}

@keyframes successPop {
    0% { transform: scale(0); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

.modal-icon i {
    font-size: 40px;
    color: white;
}

.modal-content h3 {
    font-size: 22px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.modal-content p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 30px;
}

.modal-btn {
    display: inline-block;
    padding: 14px 48px;
    background: var(--primary-gradient);
    color: white;
    border-radius: 12px;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
    letter-spacing: 2px;
}

.modal-btn:hover {
    box-shadow: var(--hover-shadow);
    transform: translateY(-2px);
}

/* ========================================
   响应式设计
   ======================================== */

@media (max-width: 1024px) {
    .left-section {
        display: none;
    }

    .right-section {
        flex: 1;
        min-height: 100vh;
        padding: 20px;
    }

    .form-container {
        max-width: 480px;
        padding: 40px 32px;
    }
}

@media (max-width: 520px) {
    .right-section {
        padding: 15px;
        align-items: flex-start;
        padding-top: 30px;
    }

    .form-container {
        padding: 32px 24px;
        border-radius: 20px;
    }

    .form-header h2 {
        font-size: 22px;
    }

    .user-avatar {
        width: 65px;
        height: 65px;
    }

    .user-avatar i {
        font-size: 28px;
    }

    .input-icon {
        width: 46px;
        min-width: 46px;
        height: 46px;
    }

    .input-icon i {
        font-size: 19px;
    }

    .input-group input {
        height: 46px;
        font-size: 14px;
    }

    .submit-btn {
        height: 48px;
        font-size: 16px;
    }

    .code-btn {
        height: 34px;
        padding: 0 12px;
        font-size: 12px;
    }

    .modal-content {
        padding: 36px 28px;
    }

    .modal-icon {
        width: 65px;
        height: 65px;
    }

    .modal-icon i {
        font-size: 32px;
    }
}

/* 横屏适配 */
@media (max-height: 550px) and (orientation: landscape) {
    .right-section {
        padding: 15px;
        overflow-y: auto;
    }

    .form-container {
        padding: 24px 28px;
    }

    .form-header {
        margin-bottom: 20px;
    }

    .user-avatar {
        width: 60px;
        height: 60px;
        margin-bottom: 12px;
    }

    .user-avatar i {
        font-size: 26px;
    }

    .input-group {
        margin-bottom: 14px;
    }

    .submit-btn {
        height: 46px;
        margin-top: 5px;
    }
}
