/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow: hidden;
}

/* 主容器 */
.auth-container {
    display: flex;
    min-height: 100vh;
}

/* 左侧插画区域 */
.auth-illustration {
    flex: 1;
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.illustration-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.illustration-image {
    max-width: 400px;
    z-index: 2;
}

.illustration-image img {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.1));
}

/* 浮动元素 */
.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
}

.floating-card {
    position: absolute;
    background: white;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    animation: float 6s ease-in-out infinite;
    color: #4f46e5;
    font-size: 24px;
}

.card-1 {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.card-2 {
    top: 60%;
    right: 15%;
    animation-delay: 2s;
}

.card-3 {
    bottom: 20%;
    left: 20%;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* 聊天气泡 */
.chat-bubbles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
}

.chat-bubble {
    position: absolute;
    background: #f59e0b;
    color: white;
    padding: 15px;
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(245, 158, 11, 0.3);
    animation: pulse 3s ease-in-out infinite;
}

.bubble-1 {
    top: 30%;
    right: 20%;
    animation-delay: 1s;
}

.bubble-2 {
    bottom: 30%;
    right: 30%;
    animation-delay: 3s;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.1);
        opacity: 1;
    }
}

/* 右侧表单区域 */
.auth-form-container {
    flex: 1;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    min-height: 100vh;
}

.auth-form {
    width: 100%;
    max-width: 420px;
    animation: slideInRight 0.8s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.auth-header {
    text-align: center;
    margin-bottom: 40px;
}

.auth-header h1 {
    font-size: 32px;
    color: #1e293b;
    margin-bottom: 10px;
}

/* 表单样式 */
.login-form {
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #374151;
    font-size: 14px;
}

.input-group {
    position: relative;
}

.input-group i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    font-size: 16px;
    z-index: 2;
}

.input-group input {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 16px;
    background: #f9fafb;
    transition: all 0.3s ease;
    outline: none;
}

.input-group input:focus {
    border-color: #4f46e5;
    background: white;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.input-group input::placeholder {
    color: #9ca3af;
}

.password-toggle {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    font-size: 16px;
    z-index: 2;
    transition: color 0.3s;
}

.password-toggle:hover {
    color: #4f46e5;
}

/* 表单选项 */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.remember-me {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
    color: #6b7280;
    user-select: none;
}

.remember-me input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 18px;
    height: 18px;
    border: 2px solid #d1d5db;
    border-radius: 4px;
    margin-right: 8px;
    position: relative;
    transition: all 0.3s;
}

.remember-me input[type="checkbox"]:checked + .checkmark {
    background: #4f46e5;
    border-color: #4f46e5;
}

.remember-me input[type="checkbox"]:checked + .checkmark::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.forgot-password {
    color: #4f46e5;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s;
}

.forgot-password:hover {
    color: #3730a3;
}

/* 登录按钮 */
.btn-login {
    width: 100%;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    border: none;
    padding: 16px 20px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
}

.btn-login:hover {
    background: linear-gradient(135deg, #3730a3 0%, #6b21a8 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.3);
}

.btn-login:active {
    transform: translateY(0);
}

.btn-login i {
    transition: transform 0.3s;
}

.btn-login:hover i {
    transform: translateX(5px);
}

/* 分割线 */
.auth-divider {
    text-align: center;
    margin: 30px 0;
    position: relative;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e5e7eb;
}

.auth-divider span {
    background: white;
    padding: 0 20px;
    color: #9ca3af;
    font-size: 14px;
    position: relative;
    z-index: 1;
}

/* 社交登录 */
.social-login {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.social-btn {
    flex: 1;
    padding: 12px 20px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    background: white;
    color: #6b7280;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.social-btn:hover {
    border-color: #d1d5db;
    background: #f9fafb;
}

.social-btn.wechat:hover {
    border-color: #00b852;
    color: #00b852;
}

.social-btn.qq:hover {
    border-color: #1677ff;
    color: #1677ff;
}

/* 页脚 */
.auth-footer {
    text-align: center;
}

.auth-footer p {
    color: #6b7280;
    font-size: 14px;
}

.auth-footer a {
    color: #4f46e5;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.auth-footer a:hover {
    color: #3730a3;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .auth-container {
        flex-direction: column;
    }
    
    .auth-illustration {
        min-height: 40vh;
        order: 2;
    }
    
    .auth-form-container {
        order: 1;
        min-height: 60vh;
        padding: 20px;
    }
    
    .auth-header h1 {
        font-size: 28px;
    }
    
    .social-login {
        flex-direction: column;
    }
    
    .floating-card {
        display: none;
    }
    
    .chat-bubble {
        display: none;
    }
}

@media (max-width: 480px) {
    .auth-form-container {
        padding: 15px;
    }
    
    .auth-form {
        max-width: 100%;
    }
    
    .auth-header h1 {
        font-size: 24px;
    }
    
    .input-group input {
        padding: 12px 12px 12px 40px;
        font-size: 14px;
    }
    
    .btn-login {
        padding: 14px 20px;
        font-size: 14px;
    }
}

/* 注册页面特定样式 */
.register-form .auth-header p {
    color: #6b7280;
    font-size: 16px;
    margin-top: 8px;
}

.register-form .form-group {
    margin-bottom: 20px;
}

.register-form .form-options {
    margin-bottom: 20px;
}

.register-form .form-options .remember-me {
    font-size: 13px;
    line-height: 1.4;
}

.register-form .terms-link,
.register-form .privacy-link {
    color: #4f46e5;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.register-form .terms-link:hover,
.register-form .privacy-link:hover {
    color: #3730a3;
    text-decoration: underline;
}

/* 注册页面响应式优化 */
@media (max-width: 768px) {
    .register-form .auth-form-container {
        padding: 15px;
    }
    
    .register-form .form-group {
        margin-bottom: 18px;
    }
    
    .register-form .auth-header h1 {
        font-size: 26px;
    }
    
    .register-form .auth-header p {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .register-form .auth-header h1 {
        font-size: 22px;
    }
    
    .register-form .auth-header p {
        font-size: 13px;
    }
    
    .register-form .form-options .remember-me {
        font-size: 12px;
    }
}

/* 返回首页链接样式 */
.back-to-home {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1000;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.95);
    color: #4f46e5;
    text-decoration: none;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    border: 1px solid rgba(79, 70, 229, 0.2);
}

.back-link:hover {
    background: rgba(79, 70, 229, 0.1);
    color: #3730a3;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.2);
}

.back-link i {
    font-size: 12px;
    transition: transform 0.3s ease;
}

.back-link:hover i {
    transform: translateX(-3px);
}

/* 响应式优化 */
@media (max-width: 768px) {
    .back-to-home {
        top: 15px;
        left: 15px;
    }
    
    .back-link {
        padding: 10px 16px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .back-to-home {
        top: 10px;
        left: 10px;
    }
    
    .back-link {
        padding: 8px 12px;
        font-size: 12px;
        gap: 6px;
    }
    
    .back-link span {
        display: none;
    }
    
    .back-link {
        width: 36px;
        height: 36px;
        border-radius: 50%;
        justify-content: center;
    }
} 