/* OPENNEXUS 门户统一登录 UI */
.onx-auth-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  flex-wrap: wrap;
}
.onx-auth-status {
  font-family: "Fira Code", monospace;
  font-size: 0.72rem;
  color: rgba(0, 243, 255, 0.75);
  padding: 4px 8px;
  border: 1px solid rgba(0, 243, 255, 0.25);
  border-radius: 4px;
  white-space: nowrap;
}
.onx-auth-btn {
  font-family: "Fira Code", monospace;
  font-size: 0.72rem;
  padding: 6px 12px;
  border: 1px solid rgba(0, 243, 255, 0.45);
  background: rgba(0, 243, 255, 0.08);
  color: #00f3ff;
  cursor: pointer;
  border-radius: 4px;
  text-decoration: none;
  line-height: 1.2;
}
.onx-auth-btn:hover { background: rgba(0, 243, 255, 0.18); }
.onx-auth-btn-ghost {
  border-color: rgba(255, 255, 255, 0.25);
  color: rgba(255, 255, 255, 0.85);
  background: transparent;
}
.onx-auth-btn-admin {
  border-color: rgba(255, 189, 46, 0.55);
  color: #ffbd2e;
}

.onx-auth-modal {
  position: fixed;
  inset: 0;
  /* 必须高于玖衍品牌条(2147483000)与自定义光标(10000)，否则：
     1) 系统光标被 *{cursor:none} 隐藏，赛博光标又被面板压住 → 感觉「面板压过鼠标」
     2) 品牌条 pointer-events:auto 会挡住注册表单底部按钮 */
  z-index: 2147483646;
  background: rgba(0, 8, 16, 0.72);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  /* 面板内恢复系统光标，可点可选 */
  cursor: auto;
  pointer-events: auto;
}
.onx-auth-modal.open { display: flex; }
.onx-auth-modal.open,
.onx-auth-modal.open * {
  cursor: auto !important;
}
.onx-auth-modal input,
.onx-auth-modal textarea,
.onx-auth-modal input:focus,
.onx-auth-modal textarea:focus {
  cursor: text !important;
}
.onx-auth-modal button,
.onx-auth-modal .onx-auth-tab,
.onx-auth-modal .onx-auth-close,
.onx-auth-modal .onx-auth-submit,
.onx-auth-modal a {
  cursor: pointer !important;
}
/* 登录弹层打开时：隐藏战术光标，避免「看不见鼠标」 */
body.onx-auth-open .cyber-cursor {
  display: none !important;
  visibility: hidden !important;
}
body.onx-auth-open .onx-jiuyan-root {
  pointer-events: none !important;
  z-index: 1 !important;
}
.onx-auth-dialog {
  width: min(440px, 100%);
  max-height: min(92vh, 860px);
  overflow-y: auto;
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(0, 180, 220, 0.16), transparent 55%),
    linear-gradient(160deg, #0a1628 0%, #071018 100%);
  border: 1px solid rgba(0, 243, 255, 0.35);
  border-radius: 12px;
  padding: 24px 22px 20px;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 40px rgba(0, 243, 255, 0.12), 0 24px 60px rgba(0, 0, 0, 0.45);
  animation: onxAuthIn .45s cubic-bezier(.16,1,.3,1) both;
  pointer-events: auto;
}
@keyframes onxAuthIn {
  from { opacity: 0; transform: translateY(12px) scale(.98); }
  to { opacity: 1; transform: none; }
}
.onx-auth-close {
  position: absolute;
  top: 10px;
  right: 12px;
  border: none;
  background: none;
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.4rem;
  cursor: pointer;
}
.onx-auth-title {
  margin: 0 0 4px;
  font-size: 1.05rem;
  color: #00f3ff;
  letter-spacing: 1px;
}
.onx-auth-sub {
  margin: 0 0 16px;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.55);
}
.onx-auth-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}
.onx-auth-tab {
  flex: 1;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: transparent;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  border-radius: 4px;
  font-size: 0.82rem;
}
.onx-auth-tab.active {
  border-color: rgba(0, 243, 255, 0.5);
  color: #00f3ff;
  background: rgba(0, 243, 255, 0.08);
}
.onx-auth-panel { display: none; }
.onx-auth-panel.active { display: block; }
.onx-auth-panel label {
  display: block;
  margin-bottom: 10px;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.75);
}
.onx-auth-panel input,
.onx-auth-panel textarea {
  width: 100%;
  margin-top: 4px;
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  border-radius: 4px;
  box-sizing: border-box;
  font-size: 0.85rem;
}
.onx-auth-submit {
  width: 100%;
  margin-top: 6px;
  padding: 10px;
  border: none;
  border-radius: 4px;
  background: linear-gradient(90deg, #00cfff, #00f3ff);
  color: #001018;
  font-weight: 700;
  cursor: pointer;
}
.onx-auth-error {
  min-height: 1.2em;
  font-size: 0.78rem;
  color: #ff6b6b;
  margin: 0 0 8px;
}

.sys-card.onx-locked {
  opacity: 0.82;
  position: relative;
}
.sys-card.onx-locked::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 8px,
    rgba(0, 0, 0, 0.06) 8px,
    rgba(0, 0, 0, 0.06) 16px
  );
  pointer-events: none;
  border-radius: inherit;
}
.onx-access-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 0.62rem;
  padding: 3px 7px;
  border-radius: 3px;
  font-family: "Fira Code", monospace;
  letter-spacing: 0.5px;
}
.onx-badge-lock { background: rgba(255, 75, 75, 0.85); color: #fff; }
.onx-badge-wait { background: rgba(255, 189, 46, 0.9); color: #111; }
.onx-badge-ok { background: rgba(0, 255, 136, 0.85); color: #001a0d; }

@media (max-width: 900px) {
  .onx-auth-bar {
    order: 2;
    width: 100%;
    justify-content: flex-end;
    margin-left: 0;
    padding-top: 6px;
  }
}
