* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    width: 100%;
    height: 100vh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #050b1f;
    position: relative; /* 确保相对定位 */
}

#matrix-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-color: #050b1f;
}

.brand-logo {
    position: fixed;
    top: 30px;
    left: 30px;
    z-index: 100;
}

.brand-logo img {
    height: 40px;
    filter: drop-shadow(0 0 10px rgba(110, 142, 251, 0.5));
    transition: all 0.3s ease;
}

.brand-logo img:hover {
    filter: drop-shadow(0 0 15px rgba(110, 142, 251, 0.8));
    transform: scale(1.05);
}

/* 容器布局更新样式 */
.login-container, .progress-container {
    width: 100%;
    max-width: 420px;
    padding: 20px;
    z-index: 10;
    transition: transform 0.8s cubic-bezier(0.68, -0.55, 0.27, 1.55);
}

.progress-container {
    position: absolute;
    left: 50%;
    transform: translateX(100%) scale(0.9);
    opacity: 0;
    visibility: hidden;
    transition: all 0.8s cubic-bezier(0.68, -0.55, 0.27, 1.55);
}

/* 平移效果的类 */
body.login-progress-active .login-container {
    transform: translateX(-50%);
}

body.login-progress-active .progress-container {
    transform: translateX(-15%) scale(1);
    opacity: 1;
    visibility: visible;
}

.glassmorphism-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 24px;
    padding: 40px 30px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.36);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: white;
    overflow: hidden;
    position: relative;
    transition: all 0.5s ease;
}

.glassmorphism-card:hover {
    box-shadow: 0 12px 42px 0 rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.18);
    transform: translateY(-5px);
}

.login-header {
    text-align: center;
    margin-bottom: 35px;
}

.login-header h1 {
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 10px;
    background: linear-gradient(5deg, #6e8efb, #cccccc, #6e8efb);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 0.5px;
}

.login-header p {
    font-size: 15px;
    opacity: 0.8;
}

/* 表单组样式 */
.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.3px;
}

/* 输入框和图标样式 */
.input-with-icon {
    position: relative;
    width: 100%;
}

.input-with-icon input {
    width: 100%;
    padding: 16px 16px 16px 50px; /* 增加左侧内边距，确保文本不与图标重叠 */
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: white;
    font-size: 15px;
    transition: all 0.3s ease;
    cursor: text !important;
}

.input-with-icon input:focus {
    outline: none;
    border-color: rgba(110, 142, 251, 0.6);
    background: rgba(255, 255, 255, 0.11);
    box-shadow: 0 0 20px rgba(110, 142, 251, 0.15);
}

.input-with-icon input::placeholder {
    color: rgba(255, 255, 255, 0.4);
    transition: color 0.3s ease;
}

.input-with-icon input:focus::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.icon-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 50px; /* 明确的图标容器宽度 */
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.icon-wrapper svg {
    color: rgba(255, 255, 255, 0.5);
    transition: color 0.3s ease;
}

.input-with-icon input:focus ~ .icon-wrapper svg {
    color: rgba(110, 142, 251, 0.8);
}

.input-with-icon input:not(:placeholder-shown) ~ .icon-wrapper svg {
    color: rgba(110, 142, 251, 0.8);
}

/* 登录按钮样式 */
.login-button {
    width: 100%;
    padding: 16px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(45deg, rgba(255, 255, 255, 0.4), #6e8efb, rgba(255, 255, 255, 0.4));
    color: white;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer !important;
    transition: all 0.3s ease;
    margin-top: 15px;
    position: relative;
    overflow: hidden;
}

.login-button::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
            to bottom right,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.1) 50%,
            rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(45deg);
    transition: all 0.7s ease;
}

.login-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(110, 142, 251, 0.4);
}

.login-button:hover::before {
    left: 100%;
}

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

/* 禁用按钮状态 */
.login-button:disabled {
    opacity: 0.7;
    cursor: not-allowed !important;
    transform: none !important;
}

.login-button:disabled::before {
    display: none;
}

.powered-by {
    text-align: center;
    margin-top: 35px;
    font-size: 13px;
    opacity: 0.6;
    letter-spacing: 0.5px;
}

/* 登录反馈消息样式 */
.login-message {
    padding: 12px;
    margin: 15px 0;
    border-radius: 10px;
    text-align: center;
    font-size: 14px;
    transition: opacity 0.3s ease;
    opacity: 0;
}

.login-message.error {
    background: rgba(255, 87, 87, 0.15);
    border: 1px solid rgba(255, 87, 87, 0.3);
    color: #ff5757;
}

.login-message.success {
    background: rgba(87, 255, 173, 0.15);
    border: 1px solid rgba(87, 255, 173, 0.3);
    color: #57ffad;
}

/* 进度卡片样式 */
.progress-card {
    height: 100%;
}

.progress-header {
    text-align: center;
    margin-bottom: 25px;
}

.progress-header h2 {
    font-size: 24px;
    font-weight: 600;
    background: linear-gradient(5deg, #6e8efb, #cccccc, #6e8efb);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 0.5px;
}

/* 进度步骤样式 */
.progress-steps {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.progress-step {
    display: flex;
    align-items: flex-start;
    position: relative;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.progress-step.active {
    opacity: 1;
}

.progress-step.completed .step-status {
    background-color: #57ffad;
}

.progress-step.error .step-status {
    background-color: #ff5757;
}

.step-icon {
    margin-right: 15px;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.3s ease;
}

.progress-step.active .step-icon {
    color: #6e8efb;
}

.progress-step.completed .step-icon {
    color: #57ffad;
}

.progress-step.error .step-icon {
    color: #ff5757;
}

.step-content {
    flex: 1;
}

.step-content h3 {
    font-size: 16px;
    margin-bottom: 5px;
    font-weight: 500;
}

.step-content p {
    font-size: 14px;
    opacity: 0.7;
}

.step-status {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    transition: background-color 0.3s ease;
    position: relative;
}

.progress-step.active .step-status {
    background-color: #6e8efb;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(110, 142, 251, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(110, 142, 251, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(110, 142, 251, 0);
    }
}

/* 响应式样式 */
@media (max-width: 480px) {
    .glassmorphism-card {
        padding: 30px 20px;
    }

    .login-header h1 {
        font-size: 24px;
    }

    .login-button {
        padding: 12px;
    }

    .brand-logo {
        top: 20px;
        left: 20px;
    }

    .brand-logo img {
        height: 30px;
    }
}

/* 针对平板和移动设备的响应式布局 */
@media (max-width: 768px) {
    body.login-progress-active .login-container {
        transform: translateY(-100%) scale(0.9);
        opacity: 0;
    }

    .progress-container {
        left: 0;
        right: 0;
        top: 50%;
        transform: translateY(100%);
        width: 100%;
        max-width: 90%;
        margin: 0 auto;
    }

    body.login-progress-active .progress-container {
        transform: translateY(0) scale(1);
    }
}

/* 为可交互元素设置正确的光标样式 */
input, button, a, .brand-logo {
    cursor: pointer !important;
}

input {
    cursor: text !important;
}

button:disabled {
    cursor: not-allowed !important;
}
