/* ============================================================
   风花国际 · 登录 / 注册页「键盘安全区」样式 v1
   键盘弹出时（html.zaka-kb-open）：卡片钉在键盘上方的可见区域内，
   卡片自身可上下滚动，输入框不会被键盘盖住
   ============================================================ */

html.zaka-kb-open .kk-auth-page .kk-auth-form,
html.zaka-kb-open .kk-auth-form {
  position: fixed !important;
  top: calc(var(--zaka-vv-top, 0px) + 10px) !important;
  bottom: auto !important;
  left: 0 !important;
  right: 0 !important;
  width: calc(100vw - 31.2 * var(--zx)) !important;
  max-width: 390px !important;
  margin: 0 auto !important;
  height: auto !important;
  max-height: calc(var(--zaka-vv-h, 100vh) - 22px) !important;
  padding: calc(22 * var(--zx)) calc(25.05 * var(--zx)) calc(26 * var(--zx)) !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  transform: none !important;
  animation: none !important;
  z-index: 2600 !important;
  color: #1f285a !important;
}

/* 键盘弹出时，卡片内的元素不许再缩，保证可读、可点 */
html.zaka-kb-open .kk-auth-page .kk-field,
html.zaka-kb-open .kk-auth-page .kk-field input {
  flex-shrink: 0 !important;
}

/* 键盘弹出时收起顶部关闭按钮和客服行，避免压住内容 */
html.zaka-kb-open .zaka-x,
html.zaka-kb-open .zaka-kefu {
  display: none !important;
}

/* 键盘弹出时背景不跟着跳 */
html.zaka-kb-open .kk-auth-page .kk-auth-shell {
  background-attachment: scroll, scroll !important;
}

/* 注册页面板在键盘模式下上方留白收一点，尽量把 5 个框都露出来 */
html.zaka-kb-open .kk-auth-form-register {
  padding-top: calc(18 * var(--zx)) !important;
}

/* ---------- 键盘模式：紧凑版，尽量让整张卡片（含按钮）不滚动就能看全 ---------- */
html.zaka-kb-open .kk-auth-page .kk-field,
html.zaka-kb-open .kk-field {
  height: calc(42 * var(--zx)) !important;
  flex: 0 0 calc(42 * var(--zx)) !important;
  margin-bottom: calc(7 * var(--zx)) !important;
}
html.zaka-kb-open .kk-auth-page .kk-field input,
html.zaka-kb-open .kk-field input {
  font-size: calc(15.6 * var(--zx)) !important;
}
html.zaka-kb-open .kk-auth-page .kk-primary,
html.zaka-kb-open .kk-primary {
  height: calc(46 * var(--zx)) !important;
  flex: 0 0 calc(46 * var(--zx)) !important;
  margin-top: calc(16 * var(--zx)) !important;
  border-radius: calc(23 * var(--zx)) !important;
  font-size: calc(17 * var(--zx)) !important;
}
html.zaka-kb-open .kk-auth-page .kk-login-options {
  margin-top: calc(5 * var(--zx)) !important;
}
html.zaka-kb-open .kk-auth-login .kk-login-options,
html.zaka-kb-open .kk-auth-page .kk-back-login {
  margin-top: calc(10 * var(--zx)) !important;
  line-height: calc(18 * var(--zx)) !important;
}
html.zaka-kb-open .zaka-links {
  margin-top: calc(12 * var(--zx)) !important;
}
html.zaka-kb-open .kk-auth-page .kk-auth-error {
  min-height: calc(13 * var(--zx)) !important;
  line-height: calc(13 * var(--zx)) !important;
}
