/* meshupload/static/css/auth.css */

/* --- 1. 全局重置 --- */
* { box-sizing: border-box; margin: 0; padding: 0; }

/* --- 2. 视频背景专用样式 --- */
#bg-video {
    position: fixed;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: -100;
    transform: translateX(-50%) translateY(-50%);
    object-fit: cover;
}

/* --- 3. Body 布局 --- */
body {
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    display: flex;
    /* 【核心修改】改成垂直列方向，这样 Logo 就在卡片上方了 */
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    color: #333;
    background: transparent;
}
/* --- 4. 卡片容器通用样式 (核心毛玻璃效果) --- */
/* 将三个页面的容器类名合在一起写 */
.login-container,
.register-container,
.reset-container {
    background: #ffffff;  /* 直接用纯白，最稳妥清晰 */
    padding: 40px;
    width: 100%;
    max-width: 500px;
    border-radius: 12px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;

    max-height: 95vh;
    overflow-y: auto;
    scrollbar-width: none;
}

/* 注册页稍微宽一点 */
.register-container, .reset-container {
    max-width: 450px;
}

/* 隐藏 Chrome/Safari 滚动条 */
.login-container::-webkit-scrollbar,
.register-container::-webkit-scrollbar,
.reset-container::-webkit-scrollbar {
    display: none;
}

.login-container:hover,
.register-container:hover,
.reset-container:hover {
    transform: translateY(-5px); /* 悬停上浮 */
}

/* --- 5. 标题与表单元素 --- */
h1 {
    text-align: center;
    margin-bottom: 25px; /* 原来30px，稍微减小一点 */
    color: #1a73e8;
    font-weight: 600;
    font-size: 24px;
}

.form-group { margin-bottom: 10px; }

label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-size: 14px;
    font-weight: 600;
}

/* 输入框 & 下拉框 */
input[type="text"],
input[type="password"],
select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 16px;
    outline: none;
    background: rgba(255, 255, 255, 0.9);
    transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus, select:focus {
    border-color: #1a73e8;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.2);
}

/* --- 6. 按钮样式 --- */
button {
    width: 100%;
    padding: 12px;
    background-color: #1a73e8; /* 默认蓝色 */
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
    margin-top: 10px;
}

button:hover { filter: brightness(0.9); }
button:active { transform: scale(0.98); }
button:disabled { background-color: #a0c3ff; cursor: not-allowed; }

/* 注册页按钮可以用绿色区分，如果不喜欢可以删掉这块 */
.register-container button {
    background-color: #28a745;
}
.register-container button:disabled {
    background-color: #94d3a2;
}

/* --- 7. 底部链接与消息 --- */
.footer-link {
    margin-top: 20px;
    font-size: 14px;
    color: #333;
    display: flex;
    justify-content: space-between; /* 左右分布 */
    align-items: center;
}
/* 单一居中链接时的样式覆盖 */
.footer-link.center { justify-content: center; }

.footer-link a { color: #1a73e8; text-decoration: none; font-weight: 600; }
.footer-link a:hover { text-decoration: underline; }

#message { margin-top: 15px; text-align: center; font-size: 14px; min-height: 20px; }
.success { color: #28a745; font-weight: bold; }
.error { color: #dc3545; font-weight: bold; }

/* --- 8. 特殊组件样式 (注册页/找回密码页专用) --- */

/* 自定义问题输入框 (注册页) */
.custom-question-input {
    margin-top: 8px;
    display: none; /* 默认隐藏 */
}

/* 分割线 (注册页) */
.divider {
    margin: 25px 0 20px 0;
    border-top: 1px dashed #666;
    position: relative;
    opacity: 0.5;
}
.divider-text {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    padding: 0 10px;
    color: #333;
    font-size: 12px;
    border-radius: 4px;
}

/* 步骤容器 (找回密码页) */
#step2-container { display: none; }
.question-label {
    background: rgba(0,0,0,0.05);
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 8px;
    font-size: 14px;
    color: #333;
}
/* --- 9. Logo 样式定制 --- */

/* A. 登录页专用样式 (悬浮在卡片上方) */
.brand-wrapper {
    text-align: center;
    margin-bottom: 30px; /* 控制 Slogan 和下面白色卡片的距离 */
    z-index: 10; /* 确保在视频上方 */
}

.login-logo {
    height: 120px;     /* 金属质感Logo可以稍微大一点 */
    width: auto;
    display: block;
    margin: 0 auto 10px auto;
    /* 如果你的Logo本身带阴影就不用下面这行，不带的话建议加个投影增加立体感 */
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.4));
}

.slogan {
    font-size: 18px;   /* 字体稍微大一点 */
    font-weight: 500;
    letter-spacing: 1px;
    margin: 0;

    /* 【关键】因为背景是视频，文字必须是白色 */
    color: #ffffff;
    /* 加黑色文字阴影，保证不管视频背景多亮都能看清文字 */
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

/* B. 注册/找回密码页专用样式 (左上角悬浮) - 保持不变 */
.corner-logo {
    position: fixed;
    top: 30px;
    left: 30px;
    height: 80px;
    width: auto;
    z-index: 1000;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}
@media (max-width: 600px) {
    .corner-logo { height: 40px; top: 15px; left: 15px; }
}

#sendSmsBtn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

#captcha_input,
#sms_code,
#captcha_canvas,
#sendSmsBtn {
    height: 38px;
}

#captcha_canvas {
    display: block;
    vertical-align: middle;
}

#sendSmsBtn {
    white-space: nowrap;
    min-width: 100px;
    line-height: 1;
    padding: 0 15px;
    margin-top: 0;
}