/* 汉雅星空 - layui 表单主题适配
 * 让 layui 原生表单元素融入现有「深色科技风(注册/登录)」与「白色卡片(忘记密码)」
 * 需要在 layui.css 之后加载
 */

/* ============ 深色科技风：注册 / 登录 ============ */
.auth-card.layui-form-card {
  padding-top: 0px;
}

.auth-card .layui-form-label {
  width: 100px;
  padding: 0 12px 0 0;
  color: #fff;
  font-size: 13px;
  text-align: right;
  line-height: 42px;
  height: 42px;
  white-space: nowrap;
}

.auth-card .layui-input-block {
  margin-left: 100px;
  min-height: 42px;
}

/* 无 label 的表单（登录页）：输入框顶格，去除为 label 预留的间距 */
.auth-card .no-label-form .layui-input-block {
  margin-left: 0;
}

.auth-card .layui-input,
.auth-card .layui-select {
  height: 42px;
  line-height: 42px;
  background: rgba(255, 255, 255, .07);
  border: 1px solid rgba(140, 195, 255, .35);
  color: #fff;
  border-radius: 4px;
}

.auth-card .layui-input::placeholder {
  color: #6f93bf;
}

.auth-card .layui-input:focus {
  border-color: #00AEEF;
  background: rgba(255, 255, 255, .11);
  box-shadow: 0 0 0 3px rgba(0, 174, 239, .15);
}

.auth-card .layui-form-item {
  margin-bottom: 14px;
}

/* 密码眼睛按钮 */
.auth-card .pw-wrap {
  position: relative;
}

.auth-card .pw-wrap .layui-input {
  padding-right: 46px;
}

.auth-card .pw-eye {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7fa8d8;
  z-index: 2;
}

.auth-card .pw-eye:hover {
  color: #00AEEF;
}

.auth-card .pw-eye::before {
  content: "";
  width: 19px;
  height: 19px;
  display: block;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-7 11-7 11 7 11 7-4 7-11 7-11-7-11-7z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-7 11-7 11 7 11 7-4 7-11 7-11-7-11-7z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") no-repeat center / contain;
}

.auth-card .pw-eye.is-open::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24'/%3E%3Cline x1='1' y1='1' x2='23' y2='23'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24'/%3E%3Cline x1='1' y1='1' x2='23' y2='23'/%3E%3C/svg%3E");
}

/* 图形验证码行 */
.auth-card .captcha-row {
  position: relative;
  margin-bottom: 28px;
}

.auth-card .captcha-field {
  display: flex;
  gap: 12px;
  align-items: center;
}

.auth-card .captcha-field .layui-input {
  flex: 1;
  min-width: 0;
  width: auto;
}

.auth-card .captcha-img {
  width: 132px;
  height: 42px;
  flex: 0 0 auto;
  border: 1px solid rgba(140, 195, 255, .35);
  border-radius: 4px;
  cursor: pointer;
  background: #fff;
  object-fit: cover;
}

.auth-card .captcha-img:hover {
  border-color: #00AEEF;
}

.auth-card .captcha-tip {
  position: absolute;
  left: 112px;
  bottom: -14px;
  color: #6f93bf;
  font-size: 11px;
  white-space: nowrap;
}

/* layui 主按钮改为科技蓝 */
.auth-card .layui-btn.auth-btn {
  width: 100%;
  height: 44px;
  line-height: 44px;
  margin-top: 4px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  background: linear-gradient(90deg, #00AEEF, #0288d1);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 4px;
}

.auth-card .layui-btn.auth-btn:hover {
  background: linear-gradient(90deg, #02b6f5, #0392dc);
}

.auth-card .layui-btn.auth-btn:disabled {
  opacity: .6;
  cursor: not-allowed;
}

/* 次级按钮（重置 / 回到首页）：描边样式，与主按钮区分 */
.auth-card .layui-btn.auth-btn.btn-secondary,
.layui-form-card .layui-btn.auth-btn.btn-secondary {
  background: rgba(0, 174, 239, .18) !important;
  border: 1px solid rgba(0, 174, 239, .55) !important;
  color: #bfe4ff !important;
}
.auth-card .layui-btn.auth-btn.btn-secondary:hover,
.layui-form-card .layui-btn.auth-btn.btn-secondary:hover {
  background: rgba(0, 174, 239, .32) !important;
  color: #fff !important;
}

/* layui 校验提示文案颜色适配深色 */
.auth-card .layui-form-mid {
  color: #ff8a80;
}

/* ============ 白色卡片：忘记密码 ============ */
.forgot-card.layui-form-card {
  padding-bottom: 24px;
}

.forgot-card .layui-form-label {
  width: 68px;
  padding: 0;
  color: #6b7c88;
  font-size: 13px;
  text-align: right;
  line-height: 44px;
  height: 44px;
  white-space: nowrap;
}

.forgot-card .layui-input-block {
  margin-left: 68px;
  min-height: 44px;
}

.forgot-card .layui-input {
  height: 44px;
  line-height: 44px;
  border: 1px solid #dce5ea;
  border-radius: 3px;
  color: #3d4d59;
  font-size: 14px;
}

.forgot-card .layui-input::placeholder {
  color: #b0bec7;
}

.forgot-card .layui-input:focus {
  border-color: #009688;
}

.forgot-card .layui-form-item {
  margin-bottom: 16px;
}

/* 输入框图标 - 覆盖旧 forgot.css 的 input-wrap 边框（现由 layui-input 承担） */
.forgot-card .input-wrap {
  position: relative;
  display: block;
  height: auto;
  border: none;
  border-radius: 0;
  overflow: visible;
}

.forgot-card .input-wrap:focus-within {
  border-color: transparent;
}

.forgot-card .input-wrap .ico {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: #9fb0bb;
  z-index: 2;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.forgot-card .input-wrap .ico svg {
  width: 17px;
  height: 17px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.6;
}

.forgot-card .input-wrap .layui-input {
  padding-left: 38px;
}

.forgot-card .pw-field .layui-input {
  padding-right: 44px;
}

.forgot-card .pw-eye {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9fb0bb;
  z-index: 2;
}

.forgot-card .pw-eye:hover {
  color: #009688;
}

.forgot-card .pw-eye::before {
  content: "";
  width: 19px;
  height: 19px;
  display: block;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-7 11-7 11 7 11 7-4 7-11 7-11-7-11-7z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") no-repeat center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-7 11-7 11 7 11 7-4 7-11 7-11-7-11-7z'/%3E%3Ccircle cx='12' cy='12' r='3'/%3E%3C/svg%3E") no-repeat center / contain;
}

.forgot-card .pw-eye.is-open::before {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24'/%3E%3Cline x1='1' y1='1' x2='23' y2='23'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24'/%3E%3Cline x1='1' y1='1' x2='23' y2='23'/%3E%3C/svg%3E");
}

/* 验证码行：输入框 + 获取验证码按钮 */
.forgot-card .code-row .layui-input-block {
  display: flex;
  gap: 12px;
  align-items: center;
}

.forgot-card .code-row .input-wrap {
  flex: 1;
  min-width: 0;
}

.forgot-card .code-btn.layui-btn {
  width: 120px;
  height: 44px;
  line-height: 44px;
  flex: 0 0 auto;
  margin: 0;
  border: 1px solid #009688;
  background: #fff;
  color: #009688;
  border-radius: 3px;
  font-size: 13px;
  font-weight: 400;
}

.forgot-card .code-btn.layui-btn:hover {
  background: #e6f4f1;
}

.forgot-card .code-btn.layui-btn:disabled {
  border-color: #c9d6de;
  color: #9fb0bb;
  background: #fff;
  cursor: not-allowed;
}

/* layui 单选改为青绿色 */
.forgot-card .layui-form-radio>i {
  color: #009688;
  font-size: 20px;
  margin-right: 4px;
}

.forgot-card .layui-form-radioed>div {
  color: #009688 !important;
}

/* 提交按钮 */
.forgot-card .submit-btn.layui-btn {
  width: 100%;
  height: 46px;
  line-height: 46px;
  margin-top: 6px;
  background: #009688;
  color: #fff;
  border: none;
  border-radius: 3px;
  font-size: 16px;
  letter-spacing: 4px;
}

.forgot-card .submit-btn.layui-btn:hover {
  background: #00877a;
}

.forgot-card .submit-btn.layui-btn:disabled {
  opacity: .6;
  cursor: not-allowed;
}

.forgot-msg {
  min-height: 18px;
  margin: 10px 0 0;
  font-size: 12px;
  text-align: center;
}

.forgot-msg.error {
  color: #e53935;
}

.forgot-msg.success {
  color: #009688;
}

.forgot-msg.code {
  color: #009688;
  background: #eef8f6;
  padding: 7px 10px;
  border-radius: 3px;
}

.hidden {
  display: none !important;
}
/* ============ 忘记密码页（沿用登录页 auth-card 深色风格） ============ */
/* 邮箱/手机切换：分段按钮样式（替代默认 radio 圆圈） */
.auth-card .reset-tabs {
  margin-bottom: 20px;
}
.auth-card .reset-tabs .layui-input-block {
  margin-left: 0;
  display: flex;
  width: 100%;
  gap: 8px;
  padding: 4px;
  background: rgba(0, 0, 0, .16);
  border: 1px solid rgba(140, 195, 255, .2);
  border-radius: 999px;
}
.auth-card .reset-tabs .layui-form-radio {
  flex: 1;
  min-width: 0;
  height: 36px;
  margin: 0 !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #8fb8e8;
  font-size: 13px;
  cursor: pointer;
  transition: color .2s ease, background .2s ease, box-shadow .2s ease, transform .2s ease;
  -webkit-user-select: none;
  user-select: none;
}
.auth-card .reset-tabs .layui-form-radio > i {
  display: none !important;
}
.auth-card .reset-tabs .layui-form-radio > div {
  color: inherit !important;
  line-height: 1;
  font-weight: 500;
}
.auth-card .reset-tabs .layui-form-radio:hover {
  color: #cfe6ff;
  background: rgba(255, 255, 255, .07);
}
.auth-card .reset-tabs .layui-form-radioed,
.auth-card .reset-tabs .layui-form-radioed:hover {
  color: #fff !important;
  background: linear-gradient(90deg, #00AEEF, #0288d1);
  border-color: rgba(255, 255, 255, .12);
  box-shadow: 0 6px 16px rgba(0, 174, 239, .28);
  transform: translateY(-1px);
}
.auth-card .reset-tabs .layui-form-radioed > div {
  color: #fff !important;
  font-weight: 600;
}

/* 验证码行：输入框 + 获取验证码按钮 */
.auth-card .code-row { position: relative; margin-bottom: 28px; }
.auth-card .code-field { display: flex; gap: 12px; align-items: center; }
.auth-card .code-field .layui-input { flex: 1; min-width: 0; width: auto; }
.auth-card .code-btn.layui-btn {
  width: 124px;
  height: 42px;
  line-height: 42px;
  flex: 0 0 auto;
  margin: 0;
  border: 1px solid rgba(0, 174, 239, .55);
  background: rgba(0, 174, 239, .18);
  color: #bfe4ff;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 400;
}
.auth-card .code-btn.layui-btn:hover { background: rgba(0, 174, 239, .32); color: #fff; }
.auth-card .code-btn.layui-btn:disabled {
  border-color: rgba(140, 195, 255, .25);
  color: #6f93bf;
  background: rgba(255, 255, 255, .04);
  cursor: not-allowed;
}

/* 验证码演示提示（科技蓝底） */
.auth-msg.code {
  color: #bfe4ff;
  background: rgba(0, 174, 239, .14);
  border: 1px solid rgba(0, 174, 239, .3);
  padding: 8px 10px;
  border-radius: 4px;
  line-height: 1.5;
}
