/* 全屏背景 + 居中卡片 */
.nq-auth {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--nq-auth-bg, #f5f7fa) center / cover no-repeat fixed;
}

/* 登录卡片 */
.nq-auth-form {
  width: 420px;
  background: var(--nq-bg-1);
  border-radius: var(--nq-radius);
  box-shadow: var(--nq-shadow-3);
  padding: 40px 36px;
}

.nq-auth-form-inner {
  width: 100%;
}

/* Logo */
.nq-auth-logo {
  text-align: center;
  margin-bottom: 32px;
}

.nq-auth-logo img {
  height: 40px;
  width: auto;
}

/* 登录 Tab */
.nq-auth-form .nav-tabs {
  margin-bottom: 12px;
}

.nq-auth-form .nav-tabs .nav-link {
  font-size: 15px;
}

/* 输入框统一 38px */
.nq-auth-form .form-control {
  height: 38px !important;
  font-size: 12px !important;
}

.nq-auth-form textarea.form-control {
  height: auto;
}

.nq-auth-form .input-group-append,
.nq-auth-form .input-group-prepend {
  height: 38px !important;
}

body.nq .bootstrap-select>.dropdown-toggle .filter-option-inner-inner {
  line-height: 28px !important;
}

/* 表单间距 */
.nq-auth-form .form-group {
  margin-bottom: 8px;
}

.nq-auth-form .form-group label {
  margin-bottom: 8px;
}

/* 独立输入框图标（邮箱、密码） */
.nq-auth-form .nq-input-icon {
  position: relative;
}

.nq-auth-form .nq-input-icon>i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  color: var(--nq-text-3);
  pointer-events: none;
  z-index: 2;
  transition: color .1s;
}

.nq-auth-form .nq-input-icon>.form-control {
  padding-left: 36px;
}

.nq-auth-form .nq-input-icon:focus-within>i {
  color: var(--nq-primary);
}

/* input-group 内图标（手机号） */
.nq-auth-form .input-group>.nq-ig-icon {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  left: 12px;
  font-size: 14px;
  color: var(--nq-text-3);
  pointer-events: none;
  z-index: 4;
  transition: color .1s;
}

.nq-auth-form .input-group>.nq-ig-icon+.form-control {
  padding-left: 36px;
}

.nq-auth-form .input-group>.input-group-prepend+.nq-ig-icon {
  left: calc(100px + 12px);
}

.nq-auth-form .input-group:focus-within>.nq-ig-icon {
  color: var(--nq-primary);
}

/* 登录按钮 */
.nq-auth-form .btn-login {
  height: 42px;
  font-size: 15px;
  font-weight: 500;
  margin-top: 14px;
  position: relative;
}

.nq-auth-form .btn-login.is-loading {
  pointer-events: none;
}

.nq-auth-form .btn-login.is-loading .btn-text {
  visibility: hidden;
}

.nq-auth-form .btn-login .btn-loading {
  display: none;
  position: absolute;
  inset: 0;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--nq-bg-1);
  font-size: 14px;
}

.nq-auth-form .btn-login.is-loading .btn-loading {
  display: flex;
}

.nq-auth-form .btn-login .btn-loading::before {
  content: '';
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: var(--nq-bg-1);
  border-radius: 50%;
  animation: nq-btn-spin .6s linear infinite;
}

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

/* 按钮下方操作链接（竖线分隔） */
.nq-auth-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 16px;
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--nq-text-3);
}

.nq-auth-actions>a,
.nq-auth-actions>span:not([style*="display:none"]):not([style*="display: none"]) {
  padding: 0 10px !important;
  white-space: nowrap !important;
  color: var(--nq-text-2) !important;
  text-decoration: none !important;
  transition: color .15s;
  user-select: none;
  -webkit-user-select: none;
}
.nq-auth-actions>a:hover,
.nq-auth-actions>span:not([style*="display:none"]):not([style*="display: none"]):hover {
  color: var(--nq-primary) !important;
}

/* 隐藏的 span 不占空间 */
.nq-auth-actions>span[style*="display:none"],
.nq-auth-actions>span[style*="display: none"] {
  padding: 0;
  border: none;
}

/* 可见相邻元素之间加竖线 */
.nq-auth-actions> :not([style*="display:none"]):not([style*="display: none"])~ :not([style*="display:none"]):not([style*="display: none"]) {
  border-left: 1px solid var(--nq-border-2);
}

/* 第三方登录 */
.nq-auth-oauth {
  text-align: center;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--nq-fill-3);
}

.nq-auth-oauth .oauth-title {
  font-size: 13px;
  color: var(--nq-text-3);
  margin-bottom: 12px;
}

.nq-auth-oauth .list-inline {
  margin-bottom: 0;
  display: flex;
  justify-content: center;
  gap: 12px;
}

.nq-auth-oauth .list-inline-item {
  margin: 0;
}

.nq-auth-oauth .social-list-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: var(--nq-fill-1);
  transition: background .2s;
}

.nq-auth-oauth .social-list-item:hover {
  background: var(--nq-fill-3);
}

.nq-auth-oauth .social-list-item svg,
.nq-auth-oauth .social-list-item img {
  width: 24px;
  height: 24px;
}

.nq-auth-oauth .social-list-item .icon {
  width: 24px;
  height: 24px;
}

/* 隐私协议 */
.nq-auth-agreement {
  display: flex;
  justify-content: center;
  font-size: 13px;
  color: var(--nq-text-3);
}

.nq-auth-agreement .form-check {
  display: inline-flex;
}

.nq-auth-agreement a {
  color: var(--nq-primary) !important;
  font-weight: 500;
}

.nq-auth-register a {
  color: var(--nq-primary) !important;
}

/* 注册/登录引导 */
.nq-auth-register {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--nq-text-3);
}

/* 页头/页脚自定义区 */
.nq-auth-header {
  text-align: center;
  padding: 12px 16px;
  font-size: 13px;
  color: var(--nq-text-3);
}

.nq-auth-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  text-align: center;
  padding: 24px 16px;
  font-size: 13px;
  color: var(--nq-text-1);
  z-index: 10;
}

/* 验证码按钮高度对齐 */
.nq-auth-form .input-group-append .btn {
  height: 38px;
  line-height: 36px;
  white-space: nowrap;
}

/* 国际区号选择框 */
.nq-auth-form .input-group-prepend {
  width: 100px;
  position: relative;
}

.nq-auth-form .input-group-prepend::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--nq-border-2);
  z-index: 3;
}

.nq-auth-form .input-group-prepend .form-control {
  padding-right: 4px;
}

.nq-auth-form .input-group-prepend .bootstrap-select>.dropdown-toggle {
  height: 38px !important;
  border-radius: var(--nq-radius) 0 0 var(--nq-radius) !important;
}

/* 验证码登录隐藏切换 */
.allow_login_code_captcha {
  display: none;
}

/* ---- 响应式 ---- */
@media (max-width: 575.98px) {
  .nq-auth {
    padding: 16px;
  }

  .nq-auth-form {
    width: 100%;
    padding: 24px 20px;
  }
}