* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
}

:root {

    /* --primary-color: #0078d4 ;
    --primary-dark: #005a9e; */

    --primary-dark: #0078d4 ;
    --primary-color: #005a9e;

    /* --primary-color: #1a56db;
    --primary-dark: #1e3a8a; */
    --secondary-color: #6b7280;
    --light-color: #f8fafc;
    --border-color: #e5e7eb;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --radius: 8px;
}

body {
    background: linear-gradient(135deg, #f8fafc 0%, #e0f2fe 100%);
    min-width: 200px;
    min-height: 100vh;
    display: flex;
    color: #1f2937;
    overflow-y: auto;
}


.login-container {
    display: flex;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

/* 左侧区域 - 占大面积 (61.8%) */
.login-left {
    flex: 0 0 61.8%; /* 黄金分割左侧比例 - 占据大部分 */
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow-y: auto;
    min-width: 0;
}

/* 右侧登录区域 - 占小面积 (38.2%) */
.login-right {
    flex: 0 0 38.2%; /* 黄金分割右侧比例 - 占据小部分 */
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-color: white;
    overflow-y: auto;
    min-width: 0;
}

/* 右侧内部容器 - 确保垂直居中 */
.login-right-inner {
    max-width: 320px; /* 稍微减小最大宽度 */
    width: 100%;
    margin: auto; /* 水平和垂直居中 */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* 顶部Logo调整 - 减少顶部边距 */
.logo {
    display: flex;
    align-items: center;
    margin-bottom: 30px; /* 从40px减少到30px */
    margin-top: 20px; /* 添加顶部边距防止遮挡 */
}

.logo-icon {
    width: 36px; /* 稍微减小 */
    height: 36px;
    /* background: linear-gradient(45deg, #3b82f6, #8b5cf6); */
    background: linear-gradient(45deg, var(--primary-dark), #8b5cf6);

    color: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 21px;
}

.logo-text {
    font-size: 30px; /* 稍微减小 */
    font-weight: 500;
    color: #1f2937;
}

.login-right h1 {
    font-size: 26px; /* 稍微减小 */
    font-weight: 700;
    margin-bottom: 12px;
    color: #111827;
    display: none;
}

.login-subtitle {
    color: var(--secondary-color);
    margin-bottom: 30px; /* 从40px减少到30px */
    font-size: 14px; /* 稍微减小 */
    display: none;
}

.form-group {
    margin: 10px 0;
    /* margin-bottom: 20px; 从24px减少到20px */
}

.form-label {
    display: block;
    font-size: 13px; /* 稍微减小 */
    font-weight: 600;
    margin-bottom: 6px; /* 从8px减少到6px */
    color: #374151;
}

/* .input-with-icon {
    position: relative;
} */
/* 密码输入框容器 */
.input-with-icon {
    position: relative;
    display: flex;          /* 启用Flex布局 */
    align-items: center;    /* 垂直居中对齐 */
}

/* 输入框图标样式 */
/* .input-icon {
    margin-right: 12px;     
    color: var(--secondary-color);
    font-size: 17px;
    position: static;      
} */

/* 密码切换按钮样式 */
/* .password-toggle {
    background: none;
    border: none;
    color: var(--secondary-color);
    cursor: pointer;
    font-size: 17px;
    margin-left: auto;      
} */

.form-control {
    width: 100%;
    padding: 12px 16px 12px 43px; /* 稍微减小内边距 */
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius);
    font-size: 14px; /* 稍微减小 */
    transition: all 0.3s;
    background-color: #fcfcfc;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    background-color: white;
}

.input-icon {
    position: absolute;
    left: 14px; /* 稍微调整 */
    top: 50%;
    transform: translateY(-50%);
    color: var(--secondary-color);
    font-size: 17px; /* 稍微减小 */
}

.password-toggle {
    position: absolute;
    right: 14px; /* 稍微调整 */
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--secondary-color);
    cursor: pointer;
    font-size: 17px; /* 稍微减小 */
}

.remember-forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px; /* 从30px减少到25px */
}

.remember-me {
    display: flex;
    align-items: center;
}

.remember-me input {
    margin-right: 6px; /* 从8px减少到6px */
    width: 16px; /* 稍微减小 */
    height: 16px;
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 13px; /* 稍微减小 */
    font-weight: 500;
}

.forgot-password:hover {
    text-decoration: underline;
}

.login-btn {
    width: 100%;
    padding: 14px; /* 从16px减少到14px */
    background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 15px; /* 从16px减少到15px */
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 18px; /* 从20px减少到18px */
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.login-btn:active {
    transform: translateY(0);
}

.divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 20px 0; /* 从25px减少到20px */
    color: var(--secondary-color);
    font-size: 13px; /* 从14px减少到13px */
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--border-color);
}

.divider:not(:empty)::before {
    margin-right: 12px; /* 从15px减少到12px */
}

.divider:not(:empty)::after {
    margin-left: 12px; /* 从15px减少到12px */
}

/* 第三方登录区域调整 - 减小尺寸 */
.social-login {
    /* display: flex; */
    display: none;
    gap: 12px; /* 从15px减少到12px */
    margin-bottom: 6px; /* 从30px减少到25px */
}

.social-btn {
    flex: 1;
    padding: 6px; /* 从12px减少到10px */
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius);
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px; /* 从10px减少到8px */
    font-size: 14px; /* 从15px减少到14px */
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    transition: all 0.3s;
}

.social-btn:hover {
    border-color: var(--primary-color);
    background-color: #f8fafc;
}

.social-btn i {
    font-size: 16px; /* 从18px减少到16px */
}

.register-link {
    text-align: center;
    font-size: 14px; /* 从15px减少到14px */
    color: var(--secondary-color);
    margin-top: 12px; /* 从15px减少到12px */
}

.register-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.register-link a:hover {
    text-decoration: underline;
}

/* 左侧区域样式保持不变 */
.welcome-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 25px;
}

.welcome-text {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 15px;
    opacity: 0.9;
}

.features {
    margin-bottom: 18%;
}

.feature {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.feature-icon {
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    font-size: 18px;
    flex-shrink: 0;
}

.feature-text {
    font-size: 15px;
    line-height: 1.5;
}

.error-message {
    color: #dc2626;
    font-size: 12px; /* 从13px减少到12px */
    margin-top: 4px; /* 从5px减少到4px */
    display: none;
}

.form-control.error {
    border-color: #dc2626;
}

.success-message {
    background-color: #d1fae5;
    color: #065f46;
    padding: 11px 15px; /* 从12px 16px稍微减小 */
    border-radius: var(--radius);
    margin-bottom: 18px; /* 从20px减少到18px */
    display: none;
    font-size: 13px; /* 添加字体大小 */
}

.copyright {
    text-align: center;
    margin-top: auto; /* 从40px减少到35px */
    font-size: 13px; /* 从13px减少到12px */
    color: var(--secondary-color);
    opacity: 0.8;
}

.copyright a {
  color: inherit; /* 继承 .copyright 的 #999 */
  text-decoration: none;
}

/* 悬停时给一点交互反馈（可选） */
.copyright a:hover {
  color: #fff; 
  text-decoration: underline;
}

.footer-right {
   text-align: center;
    margin-top: 40px; /* 从40px减少到35px */
    font-size: 13px; /* 从13px减少到12px */
    color: var(--secondary-color);
    opacity: 0.8;
}

.login-left .copyright {
    color: rgba(255, 255, 255, 0.8);
}

/* 响应式调整 */
/* 
@media (max-width: 1400px) {
    .login-left {
        flex: 0 0 58%;
    }
    
    .login-right {
        flex: 0 0 42%;
    }
}

@media (max-width: 1200px) {
    .login-left {
        flex: 0 0 55%;
    }
    
    .login-right {
        flex: 0 0 45%;
    }
    
    .login-right-inner {
        max-width: 280px;
    }
}

@media (max-width: 1100px) {
    .login-left {
        flex: 0 0 52%;
    }
    
    .login-right {
        flex: 0 0 48%;
    }
}

@media (max-width: 1050px) {
    .login-left {
        flex: 0 0 51%;
    }
    
    .login-right {
        flex: 0 0 49%;
    }
}

@media (max-width: 1030px) {
    .login-left {
        flex: 0 0 41%;
    }
    
    .login-right {
        flex: 0 0 59%;
    }
}

@media (max-width: 900px) {
    .login-left {
        flex: 0 0 37%;
    }
    
    .login-right {
        flex: 0 0 63%;
    }
}
*/

@media (max-width: 900px) {
    .login-left {
        flex: 0 0 55%;
    }
    
    .login-right {
        flex: 0 0 45%;
    }
}


@media (max-width: 710px) {
    .login-container {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
        overflow-y: auto;
    }
    
    .login-left, .login-right {
        flex: 1 1 auto;
        min-width: 200;
        min-height: 50vh;
        overflow-y: visible;
        width: 100%;
    }
    
    .login-left {
        padding: 40px 30px;
    }
    
    .login-right {
        padding: 40px 30px;
    }
    
    .login-right-inner {
        max-width: 260px;
    }
    
    .social-login {
        flex-direction: row;
    }
    
    .welcome-title {
        font-size: 29px;
    }
    
    .login-right h1 {
        font-size: 23px;
    }
}

@media (max-width: 570px) {
    .login-left, .login-right {
        padding: 34px 24px;
    }
    
    .logo-text {
        font-size: 21px;
    }
    
    .welcome-title {
        font-size: 27px;
    }
    
    .login-right h1 {
        font-size: 19px;
    }
    
    .welcome-text, .feature-text {
        font-size: 15px;
    }
    
    .form-control {
        padding: 12px 16px 12px 43px;
    }
    
    .social-login {
        flex-direction: column;
    }
}

/* 针对超高屏幕的优化 */
@media (min-height: 950px) {
    .login-right-inner {
        margin-top: 90px;
        margin-bottom: 70px;
    }
}

/* 超小屏幕高度优化 */
@media (max-height: 680px) {
    .login-left, .login-right {
        padding-top: 22px;
        padding-bottom: 22px;
    }
    
    .logo {
        margin-bottom: 20px;
    }
    
    .login-subtitle {
        margin-bottom: 24px;
    }
    
    .form-group {
        margin-bottom: 16px;
    }
    
    .remember-forgot {
        margin-bottom: 20px;
    }
    
    .login-btn {
        margin-bottom: 16px;
    }
    
    .divider {
        margin: 18px 0;
        display: none;
    }
    
    .social-login {
        margin-bottom: 20px;
    }
    
    .features {
        margin-top: 25px;
    }
    
    .feature {
        margin-bottom: 15px;
    }
    
    .copyright {
        margin-top: 25px;
    }
}
