/**
 * 深圳汇创业务管理系统 - 科技感登录页面样式
 * 微信红包与支付管理平台
 */

/* 基础样式重置 */
html {
    height: 100%;
}

body.signin {
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
    overflow: hidden;
    position: relative;
}

/* 动态背景容器 */
.bg-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
}

/* 六边形网格背景 */
.hex-grid {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='49' viewBox='0 0 28 49'%3E%3Cg fill-rule='evenodd'%3E%3Cg fill='%2307C160' fill-opacity='0.05'%3E%3Cpath d='M13.99 9.25l13 7.5v15l-13 7.5L1 31.75v-15l12.99-7.5zM3 17.9v12.7l10.99 6.34 11-6.35V17.9l-11-6.34L3 17.9zM0 15l12.98-7.5V0h-2v6.35L0 12.69v2.3zm0 18.5L12.98 41v8h-2v-6.85L0 35.81v-2.3zM15 0v7.5L27.99 15H28v-2.31h-.01L17 6.35V0h-2zm0 49v-8l12.99-7.5H28v2.31h-.01L17 42.15V49h-2z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.6;
    animation: gridFloat 20s ease-in-out infinite;
}

@keyframes gridFloat {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-10px, -10px); }
}

/* 浮动粒子 */
.particles {
    position: absolute;
    width: 100%;
    height: 100%;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #07C160;
    border-radius: 50%;
    opacity: 0.3;
    animation: float 15s infinite ease-in-out;
}

.particle:nth-child(1) { left: 10%; top: 20%; animation-delay: 0s; animation-duration: 12s; }
.particle:nth-child(2) { left: 20%; top: 80%; animation-delay: 2s; animation-duration: 18s; }
.particle:nth-child(3) { left: 30%; top: 40%; animation-delay: 4s; animation-duration: 14s; }
.particle:nth-child(4) { left: 50%; top: 10%; animation-delay: 1s; animation-duration: 16s; }
.particle:nth-child(5) { left: 60%; top: 60%; animation-delay: 3s; animation-duration: 20s; }
.particle:nth-child(6) { left: 70%; top: 30%; animation-delay: 5s; animation-duration: 13s; }
.particle:nth-child(7) { left: 80%; top: 70%; animation-delay: 2.5s; animation-duration: 17s; }
.particle:nth-child(8) { left: 90%; top: 50%; animation-delay: 1.5s; animation-duration: 15s; }
.particle:nth-child(9) { left: 15%; top: 55%; animation-delay: 3.5s; animation-duration: 19s; }
.particle:nth-child(10) { left: 85%; top: 15%; animation-delay: 0.5s; animation-duration: 11s; }
.particle:nth-child(11) { left: 45%; top: 85%; animation-delay: 4.5s; animation-duration: 21s; }
.particle:nth-child(12) { left: 75%; top: 45%; animation-delay: 6s; animation-duration: 14s; }

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.3;
    }
    25% {
        transform: translate(30px, -50px) scale(1.2);
        opacity: 0.5;
    }
    50% {
        transform: translate(-20px, 20px) scale(0.8);
        opacity: 0.2;
    }
    75% {
        transform: translate(40px, 30px) scale(1.1);
        opacity: 0.4;
    }
}

/* 发光圆环装饰 */
.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.15;
    animation: orbPulse 8s ease-in-out infinite;
}

.glow-orb.green {
    background: #07C160;
    width: 400px;
    height: 400px;
    top: -100px;
    right: -100px;
    animation-delay: 0s;
}

.glow-orb.blue {
    background: #3b82f6;
    width: 300px;
    height: 300px;
    bottom: -50px;
    left: -50px;
    animation-delay: 4s;
}

@keyframes orbPulse {
    0%, 100% { transform: scale(1); opacity: 0.15; }
    50% { transform: scale(1.1); opacity: 0.25; }
}

/* 波浪底部装饰 */
.waves {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 150px;
    overflow: hidden;
}

.wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 200%;
    height: 100%;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 320'%3E%3Cpath fill='%2307C160' fill-opacity='0.1' d='M0,160L48,170.7C96,181,192,203,288,192C384,181,480,139,576,128C672,117,768,139,864,154.7C960,171,1056,181,1152,165.3C1248,149,1344,107,1392,85.3L1440,64L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E%3C/svg%3E") repeat-x;
    background-size: 50% 100%;
    animation: waveMove 25s linear infinite;
}

.wave:nth-child(2) {
    bottom: 10px;
    opacity: 0.5;
    animation-duration: 20s;
    animation-direction: reverse;
}

.wave:nth-child(3) {
    bottom: 20px;
    opacity: 0.3;
    animation-duration: 30s;
}

@keyframes waveMove {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* 登录面板容器 */
.signinpanel {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
    animation: fadeInUp 0.8s ease-out;
}

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

/* 品牌区域 */
.brand-section {
    text-align: center;
    margin-bottom: 30px;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.brand-title {
    font-size: 28px;
    font-weight: 600;
    color: #fff;
    margin: 0 0 10px 0;
    letter-spacing: 2px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.brand-subtitle {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    margin: 0;
}

/* 登录卡片 */
.login-card {
    width: 100%;
    max-width: 400px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 40px 35px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.login-card h4 {
    color: #fff;
    font-size: 18px;
    font-weight: 500;
    margin: 0 0 25px 0;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* 表单样式 */
.login-card .form-control {
    display: block;
    width: 100%;
    height: 48px;
    padding: 12px 45px 12px 15px;
    margin-top: 15px;
    font-size: 14px;
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    outline: none;
    transition: all 0.3s ease;
}

.login-card .form-control::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.login-card .form-control:focus {
    background: rgba(255, 255, 255, 0.12);
    border-color: #07C160;
    box-shadow: 0 0 0 3px rgba(7, 193, 96, 0.2), 0 0 20px rgba(7, 193, 96, 0.1);
}

/* 输入框图标 */
.input-icon {
    position: relative;
}

.input-icon .form-control {
    padding-right: 45px;
}

.input-icon::after {
    content: '';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.5;
}

.input-icon.user::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2'%3E%3Cpath d='M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2'%3E%3C/path%3E%3Ccircle cx='12' cy='7' r='4'%3E%3C/circle%3E%3C/svg%3E");
}

.input-icon.lock::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2'%3E%3Crect x='3' y='11' width='18' height='11' rx='2' ry='2'%3E%3C/rect%3E%3Cpath d='M7 11V7a5 5 0 0 1 10 0v4'%3E%3C/path%3E%3C/svg%3E");
}

/* 验证码区域 */
.captcha-row {
    display: flex;
    align-items: stretch;
    gap: 12px;
    margin-top: 15px;
}

.captcha-row .col-xs-6 {
    margin: 0;
    padding: 0;
}

.captcha-row .col-xs-6:first-child {
    flex: 1;
}

.captcha-row .col-xs-6:last-child {
    flex-shrink: 0;
    display: flex;
    align-items: stretch;
}

/* 验证码输入框 - 与账号密码对齐 */
.login-card .code-input {
    display: block;
    width: 100%;
    height: 48px;
    padding: 12px 15px;
    margin-top: 0;
    font-size: 14px;
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    outline: none;
    transition: all 0.3s ease;
}

.login-card .code-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.login-card .code-input:focus {
    background: rgba(255, 255, 255, 0.12);
    border-color: #07C160;
    box-shadow: 0 0 0 3px rgba(7, 193, 96, 0.2), 0 0 20px rgba(7, 193, 96, 0.1);
}

/* 验证码图片样式优化 - 与输入框高度对齐 */
.login-card .imgcode {
    height: 48px;
    min-width: 110px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(7, 193, 96, 0.3);
    /* CSS 滤镜：反色 + 色调旋转，使验证码与深色主题协调 */
    filter: invert(1) hue-rotate(80deg) contrast(0.9);
    mix-blend-mode: normal;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: block;
}

.login-card .imgcode:hover {
    transform: scale(1.02);
    border-color: #07C160;
    box-shadow: 0 4px 15px rgba(7, 193, 96, 0.3);
    filter: invert(1) hue-rotate(80deg) contrast(1);
}

/* 记住我复选框 */
.checkbox-custom {
    position: relative;
    padding: 0 0 0 28px;
    margin: 20px 0 15px;
    display: inline-block;
}

.checkbox-custom input[type="checkbox"] {
    opacity: 0;
    position: absolute;
    cursor: pointer;
    z-index: 2;
    width: 18px;
    height: 18px;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
}

.checkbox-custom label {
    cursor: pointer;
    color: rgba(255, 255, 255, 0.7);
    font-weight: normal;
    font-size: 14px;
    margin: 0;
    line-height: 1.5;
}

.checkbox-custom label:before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease;
}

.checkbox-custom input[type="checkbox"]:checked + label:before {
    background: #07C160;
    border-color: #07C160;
}

.checkbox-custom input[type="checkbox"]:checked + label:after {
    content: '';
    position: absolute;
    left: 6px;
    top: 50%;
    transform: translateY(-60%) rotate(45deg);
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
}

/* 登录按钮 */
.btn-login {
    width: 100%;
    height: 50px;
    margin-top: 10px;
    padding: 0;
    font-size: 16px;
    font-weight: 500;
    color: #fff;
    background: linear-gradient(135deg, #07C160 0%, #00d4aa 100%);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(7, 193, 96, 0.3);
    letter-spacing: 4px;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(7, 193, 96, 0.4);
}

.btn-login:active {
    transform: translateY(0);
    box-shadow: 0 5px 20px rgba(7, 193, 96, 0.3);
}

.btn-login:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* 底部版权 */
.signup-footer {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    text-align: center;
    color: rgba(255, 255, 255, 0.4);
    font-size: 12px;
    z-index: 10;
    animation: fadeInUp 0.8s ease-out 0.6s both;
}

.signup-footer a {
    color: rgba(7, 193, 96, 0.8);
    text-decoration: none;
}

.signup-footer a:hover {
    color: #07C160;
}

/* 注册链接 */
.register-link {
    display: block;
    text-align: center;
    margin-top: 20px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

.register-link a {
    color: #07C160;
    text-decoration: none;
    font-weight: 500;
}

.register-link a:hover {
    text-decoration: underline;
}

/* 响应式布局 */
@media screen and (max-width: 768px) {
    .signinpanel {
        padding: 15px;
    }

    .login-card {
        padding: 30px 25px;
        border-radius: 16px;
    }

    .brand-title {
        font-size: 22px;
    }

    .glow-orb.green {
        width: 250px;
        height: 250px;
    }

    .glow-orb.blue {
        width: 200px;
        height: 200px;
    }
}

@media screen and (max-width: 480px) {
    .login-card {
        padding: 25px 20px;
    }

    .brand-title {
        font-size: 20px;
    }

    .login-card .form-control {
        height: 44px;
        font-size: 13px;
    }

    .btn-login {
        height: 46px;
        font-size: 15px;
    }
}

/* 加载动画 */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Layer弹窗样式覆盖 */
body .layer-ext-moon-msg {
    background-color: rgba(15, 23, 42, 0.95) !important;
    border: 1px solid rgba(7, 193, 96, 0.3) !important;
    border-radius: 10px !important;
}

body .layer-ext-moon-msg .layui-layer-content {
    color: #fff !important;
}
