@charset "utf-8";

:root {
    --primary-color: #007bff; /* 活力蓝 */
    --card-bg: #ffffff;
    --text-color-dark: #ee3939;
    --text-color-light: #ee3939;
    --input-bg: #f4f7f9;
    --gradient-start: #e0f7fa; /* 清爽薄荷绿 */
    --gradient-end: #80deea;   /* 柔和青色 */
    --header-bg: rgba(255, 255, 255, 0.9);
    --footer-bg: rgba(0, 0, 0, 0.2);
}

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    font-family: 'Helvetica Neue', 'Hiragino Sans GB', 'WenQuanYi Micro Hei', 'Microsoft Yahei', sans-serif;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    animation: gradient-animation 15s ease infinite;
    background-size: 200% 200%;
    display: flex;
    flex-direction: column;
}

@keyframes gradient-animation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* --- Header --- */
.login-header {
    background-color: var(--header-bg);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 15px 40px;
    backdrop-filter: blur(5px);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.header-left { display: flex; align-items: center; gap: 15px; }
.logo { width: 40px; height: 40px; }
.system-title h1 { font-size: 20px; color: var(--text-color-dark); margin: 0; }
.system-title p { font-size: 12px; color: var(--text-color-light); margin: 2px 0 0; }
.back-to-home { display: flex; align-items: center; gap: 8px; padding: 8px 16px; background-color: var(--primary-color); color: white; text-decoration: none; border-radius: 6px; transition: background-color 0.3s; }
.back-to-home:hover { background-color: #357abd; }

/* --- Main Content --- */
.login-main {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

.login-card {
    display: flex;
    width: 950px;
    height: 580px;
    background-color: var(--card-bg);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.left-panel {
    width: 55%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background-color: #f9faff;
    overflow: hidden;
}

.illustration-img {
    width: 100%;
    max-width: 450px;
    height: auto;
    /* 增强的动画效果 */
    animation:
        medical-breathe 3s ease-in-out infinite,
        enhanced-glow 4s ease-in-out infinite,
        subtle-float 6s ease-in-out infinite;
    transform-origin: center center;
    transition: transform 0.3s ease;
    /* 确保动画可见 */
    will-change: transform, filter, opacity;
}

/* 悬停时保持动画继续，仅轻微放大 */
.illustration-img:hover {
    transform: scale(1.66);
}

.right-panel {
    width: 45%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
    box-sizing: border-box;
}

.login-box { width: 100%; }
.login-box h2 { font-size: 24px; color: var(--text-color-dark); margin-bottom: 30px; text-align: center; }
.input-group { margin-bottom: 20px; }
.input-group input { width: 100%; padding: 14px; border: 1px solid #ddd; border-radius: 8px; background-color: var(--input-bg); font-size: 16px; box-sizing: border-box; }
.input-group-inline { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; }
.input-group-inline input { flex-grow: 1; }
.captcha-img { height: 50px; border-radius: 8px; cursor: pointer; flex-shrink: 0; }
.form-footer { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 25px; }
.form-footer a { color: var(--primary-color); text-decoration: none; }
.login-btn { width: 100%; padding: 15px; border: none; border-radius: 8px; background-color: var(--primary-color); color: white; font-size: 18px; font-weight: bold; cursor: pointer; transition: background-color 0.3s ease; }
.login-btn:hover { background-color: #357abd; }

/* --- Footer --- */
.login-footer {
    padding: 15px;
    text-align: center;
    color: white;
    font-size: 14px;
    background-color: var(--footer-bg);
}

/* --- Contact Buttons --- */
.contact-buttons {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 100;
}

.contact-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    background-color: var(--header-bg);
    border-radius: 10px;
    color: var(--text-color-light);
    text-decoration: none;
    font-size: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s;
    backdrop-filter: blur(5px);
}
.contact-item:hover { transform: scale(1.1); color: var(--primary-color); }
.contact-item i {
    font-size: 24px;
    margin-bottom: 8px;
    color: var(--primary-color); /* 将图标颜色设为主题蓝色 */
    transition: color 0.3s;
}

.contact-item:hover i {
    color: #0056b3; /* 悬停时加深 */
}

/* 小弹窗样式 */
.toast {
    position: fixed;
    top: 15%; /* 调整到中间偏上 */
    left: 50%; /* 水平居中 */
    transform: translate(-50%, -50%); /* 居中定位 */
    background-color: #333;
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 10px; /* 图标和文本之间的间距 */
}

/* 显示动画 */
.toast.show {
    opacity: 1;
    transform: translate(-50%, 0); /* 显示时保持水平居中 */
}

/* 成功弹窗样式 */
.toast.success {
    background-color: #5dbb5d; /* 绿色 */
}

/* 错误弹窗样式 */
.toast.error {
    background-color: #c5544c; /* 红色 */
}

/* 图标样式 */
.toast-icon {
    font-size: 16px; /* 图标大小 */
}

/* 文本样式 */
.toast-text {
    flex: 1; /* 文本占据剩余空间 */
}

/* ========== 登录页面插图动画效果 ========== */

/* 增强的医疗呼吸效果 - 更明显的缩放和透明度变化 */
@keyframes medical-breathe {
    0%, 100% {
        transform: scale(2);
        opacity: 1;
    }
    50% {
        transform: scale(2.1);
        opacity: 10;
    }
}

/* 轻微浮动效果 */
@keyframes subtle-float {
    0%, 100% {
        transform: translateY(10px);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* 增强的光晕效果 - 医疗主题配色，更强对比度 */
@keyframes enhanced-glow {
    0%, 100% {
        filter: drop-shadow(0 8px 16px rgba(0, 150, 255, 0.15))
                drop-shadow(0 4px 8px rgba(0, 200, 150, 0.15));
    }
    25% {
        filter: drop-shadow(0 12px 24px rgba(0, 180, 255, 0.35))
                drop-shadow(0 6px 12px rgba(0, 220, 180, 0.25));
    }
    50% {
        filter: drop-shadow(0 16px 32px rgba(0, 123, 255, 0.4))
                drop-shadow(0 8px 16px rgba(0, 255, 200, 0.3));
    }
    75% {
        filter: drop-shadow(0 12px 24px rgba(0, 180, 255, 0.35))
                drop-shadow(0 6px 12px rgba(0, 220, 180, 0.25));
    }
}

/* 响应式优化 - 在小屏幕上减少动画强度 */
@media (max-width: 768px) {
    .illustration-img {
        animation:
            medical-breathe-mobile 4s ease-in-out infinite,
            enhanced-glow-mobile 6s ease-in-out infinite,
            subtle-float-mobile 8s ease-in-out infinite;
    }

    @keyframes medical-breathe-mobile {
        0%, 100% {
            transform: scale(1);
            opacity: 0.95;
        }
        50% {
            transform: scale(1.04);
            opacity: 1;
        }
    }

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

    @keyframes enhanced-glow-mobile {
        0%, 100% {
            filter: drop-shadow(0 4px 8px rgba(0, 150, 255, 0.15));
        }
        50% {
            filter: drop-shadow(0 8px 16px rgba(0, 123, 255, 0.25));
        }
    }
}

/* 减少动画偏好设置支持 */
@media (prefers-reduced-motion: reduce) {
    .illustration-img {
        animation: none;
    }

    .illustration-img:hover {
        transform: none;
    }
}
/* 添加圆角和阴影 */
.success-message, .error-message {
    border-radius: 0 0 8px 8px; /* 底部圆角 */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); /* 阴影效果 */
}

/* 右侧联系方式样式 */
.contact-buttons {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.contact-item {
    background: var(--white);
    padding: 10px;
    border-radius: 4px;
    text-decoration: none;
    color: var(--text-gray);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.contact-item img {
    width: 50px;
    height: 50px;
}

/* 页脚样式 */
footer {
    background: var(--white);
    padding: 15px 50px;
    font-size: 12px;
    color: var(--text-gray);
}

.footer-content {
    text-align: center;
}

.version-info {
    margin-bottom: 8px;
}

.version-info span {
    margin: 0 10px;
}

.footer-links a {
    color: var(--text-gray);
    text-decoration: none;
    margin: 0 10px;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .illustration {
        display: none;
    }
    
    .login-container {
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    .login-container {
        width: 100%;
    }
    
    header {
        padding: 10px 20px;
    }
    
    .contact-buttons {
        display: none;
    }
}