/* ==========================================================================
   登录弹窗（替代跳转 /login 页面）
   --------------------------------------------------------------------------
   弹窗由 index.html 里的脚本动态创建，样式集中在这里。
   视觉沿用后台/前端的轻量风格：白卡片、圆角、蓝色主按钮。
   ========================================================================== */

.bntab-login-mask {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(0, 0, 0, .45);
    backdrop-filter: blur(2px);
}

.bntab-login-mask.open { display: flex; }

.bntab-login-card {
    position: relative;
    width: 100%;
    max-width: 380px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .28);
    padding: 28px 24px 22px;
    animation: bntab-login-in .16s ease;
}

@keyframes bntab-login-in {
    from { opacity: 0; transform: translateY(8px) scale(.98); }
    to   { opacity: 1; transform: none; }
}

.bntab-login-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #8e8e94;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}

.bntab-login-close:hover { background: rgba(0, 0, 0, .06); color: #3a3a3c; }

.bntab-login-title { cursor: move; user-select: none; }
.bntab-login-title {
    margin: 0 0 4px;
    font-size: 20px;
    font-weight: 600;
    color: #1d2327;
}

.bntab-login-sub {
    margin: 0 0 18px;
    font-size: 13px;
    color: #8e8e94;
}

.bntab-login-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 18px;
    border-bottom: 1px solid #e8e8ea;
}

.bntab-login-tab {
    flex: 1;
    padding: 9px 4px;
    border: 0;
    border-bottom: 2px solid transparent;
    background: none;
    color: #8e8e94;
    font-size: 14px;
    cursor: pointer;
}

.bntab-login-tab.active {
    color: #2271b1;
    border-bottom-color: #2271b1;
    font-weight: 600;
}

.bntab-login-tab:disabled { opacity: .45; cursor: not-allowed; }

.bntab-login-field { margin-bottom: 14px; }

.bntab-login-field label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #3a3a3c;
}

.bntab-login-field input {
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #d0d0d4;
    border-radius: 10px;
    font-size: 14px;
    color: #1d2327;
    background: #fff;
    outline: none;
    box-sizing: border-box;
}

.bntab-login-field input:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, .12);
}

.bntab-login-row { display: flex; gap: 8px; }
.bntab-login-row input { flex: 1; }

.bntab-login-code {
    min-width: 112px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #2271b1;
    border-radius: 10px;
    background: #f6f7f7;
    color: #2271b1;
    font-size: 13px;
    cursor: pointer;
    white-space: nowrap;
}

.bntab-login-code:disabled { opacity: .55; cursor: not-allowed; }

.bntab-login-submit {
    width: 100%;
    height: 42px;
    margin-top: 6px;
    border: 0;
    border-radius: 10px;
    background: #2271b1;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.bntab-login-submit:hover { background: #135e96; }
.bntab-login-submit:disabled { opacity: .6; cursor: not-allowed; }

.bntab-login-msg {
    display: none;
    margin-bottom: 14px;
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 13px;
    line-height: 1.5;
}

.bntab-login-msg.err { display: block; background: #fcf0f1; color: #a02224; border: 1px solid #f3c1c3; }
.bntab-login-msg.ok { display: block; background: #edfaef; color: #00701a; border: 1px solid #b8e6c2; }

.bntab-login-hint {
    margin: 12px 0 0;
    font-size: 12px;
    color: #8e8e94;
    text-align: center;
}

.bntab-login-hint a { color: #2271b1; text-decoration: none; }

/* 移动端：卡片占满宽度更舒服 */
@media (max-width: 480px) {
    .bntab-login-card { max-width: 100%; padding: 24px 18px 18px; border-radius: 14px; }
}
