/* Phoenix 账号系统样式
 *
 * 登录/注册页复用 PunBB 原生 .blockform > h2 + .box > .inform > fieldset 结构，
 * 因此这里只做"补丁"，不重新发明卡片样式——配色、边框、渐变标题栏全部交给 Cobalt.css。
 *
 * 注意：Cobalt.css 有 `.pun div, .pun form, .pun p, .pun h2 { margin:0; padding:0; border:0 }`
 * 这类 (0,1,1) 特异性的重置规则，覆盖它必须用同等或更高的特异性。
 */

/* ---------- 导航栏登录态（gs-navbar，首页那套） ---------- */
.gs-nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.gs-nav-container .gs-auth-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  letter-spacing: .5px;
  white-space: nowrap;
  padding-right: 4px;
}
.gs-nav-container .gs-auth-nav a { color: var(--muted); }
.gs-nav-container .gs-auth-nav a:hover { color: #fff; text-decoration: none; }
.gs-nav-container .gs-auth-nav .gs-auth-user { color: var(--accent); font-weight: 600; }
.gs-nav-container .gs-auth-nav button {
  background: none;
  border: 0;
  padding: 0;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
}
.gs-nav-container .gs-auth-nav button:hover { color: #fff; text-decoration: underline; }

/* ---------- 论坛页导航里的账号入口（沿用 #brdmenu 的绿色强调） ---------- */
.pun #brdmenu .gs-auth-link a { color: #b4e61e; }
.pun #brdmenu .gs-auth-user { color: #b4e61e; font-weight: bold; }
.pun .gs-welcome-guest { color: #a9a9a4; }

/* ---------- 登录 / 注册页 ---------- */

/* 主区域宽度与论坛列表一致，表单不铺满整行 */
#brdmain .blockform { max-width: 760px; }

/* 表单字段：PunBB 默认 .conl 是左浮动，窄屏会挤在一起 */
.pun .infldset label.conl { margin-right: 16px; }
.pun .infldset label strong { color: #e0e0da; }
.pun .infldset label strong span {
  color: #888;
  font-weight: normal;
  font-size: 9px;
  margin-left: 4px;
  text-transform: uppercase;
}
.pun .infldset label input[type="text"],
.pun .infldset label input[type="password"],
.pun .infldset label input[type="email"] {
  margin-top: 3px;
  padding: 5px 7px;
  border-radius: 3px;
  font-size: 12px;
  font-family: inherit;
  transition: border-color .15s;
}
.pun .infldset label input:focus {
  border-color: #95b806;
  outline: none;
}
.pun .infldset p { color: #a9a9a4; line-height: 1.6; }

/* 提示文字 */
.pun .gs-field-hint {
  color: #8b8b88;
  font-size: 10px;
  padding-top: 6px;
}

/* 表单消息：沿用论坛的告警配色 */
.pun .gs-auth-msg {
  margin: 0 0 10px;
  padding: 6px 10px;
  border-radius: 3px;
  font-size: 11px;
  line-height: 1.6;
}
.pun .gs-auth-msg.is-error {
  border: 1px solid #6b1e1e;
  background: #3a1414;
  color: #ff9a9a;
}
.pun .gs-auth-msg.is-success {
  border: 1px solid #3d5410;
  background: #1e2b0a;
  color: #b4e61e;
}
.pun .gs-auth-msg[hidden] { display: none; }

/* 提交按钮：沿用论坛的绿色强调色 */
.pun .buttons { text-align: right; padding-top: 4px; }
.pun input.gs-auth-submit {
  padding: 5px 18px;
  background: #1e2b0a;
  border: 1px solid #95b806;
  border-radius: 3px;
  color: #b4e61e;
  font-size: 11px;
  font-family: inherit;
  font-weight: bold;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.pun input.gs-auth-submit:hover:not(:disabled) {
  background: #95b806;
  color: #12120f;
}
.pun input.gs-auth-submit:disabled {
  opacity: .45;
  cursor: not-allowed;
}

/* 次要链接按钮（去登录 / 立即注册） */
.pun .gs-auth-linkbtn {
  display: inline-block;
  padding: 5px 18px;
  background: #212122;
  border: 1px solid #4f4f4d;
  border-radius: 3px;
  color: #d4d4d4;
  font-size: 11px;
}
.pun .gs-auth-linkbtn:hover {
  background: #272726;
  border-color: #95b806;
  color: #b4e61e;
  text-decoration: none;
}

/* Turnstile 容器 */
.pun .gs-turnstile {
  min-height: 65px;
  padding-top: 8px;
  clear: both;
}
.pun .gs-turnstile:empty { display: none; }

/* 次要区块（"还没有账号"）压低视觉权重 */
.pun .gs-auth-alt h2 { color: #9a9a9a; }
.pun .gs-auth-alt .infldset p { padding: 0; }

@media (max-width: 760px) {
  .pun .infldset label.conl {
    float: none;
    display: block;
    margin: 0 0 10px;
  }
  .pun .infldset label input[type="text"],
  .pun .infldset label input[type="password"],
  .pun .infldset label input[type="email"] { width: 100%; }
}

/* ---------- 未验证邮箱提示条 ---------- */
.pun .gs-verify-notice {
  margin-top: 6px;
  padding: 5px 8px;
  border-left: 3px solid #95b806;
  background: #1e2b0a;
  color: #c8d8a0;
  font-size: 11px;
  line-height: 1.6;
}
.pun .gs-verify-notice button.gs-verify-resend {
  padding: 1px 8px;
  background: transparent;
  border: 1px solid #6d8509;
  border-radius: 3px;
  color: #b4e61e;
  font-size: 10px;
  font-family: inherit;
  cursor: pointer;
}
.pun .gs-verify-notice button.gs-verify-resend:hover:not(:disabled) {
  background: #95b806;
  color: #12120f;
}
.pun .gs-verify-notice button.gs-verify-resend:disabled {
  opacity: .5;
  cursor: not-allowed;
}
.pun .gs-verify-status {
  margin-left: 8px;
  color: #9a9a9a;
}
.pun .gs-verify-status a { color: #b4e61e; text-decoration: underline; }

/* ---------- 邀请码输入 ---------- */
.pun .infldset input#inviteCode {
  font-family: Consolas, "Cascadia Mono", Menlo, monospace;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.pun .infldset input#inviteCode::placeholder {
  color: #555;
  letter-spacing: .5px;
  text-transform: none;
}

/* ---------- 密码强度提示 ---------- */
.pun .gs-pw-meter {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 6px;
}
.pun .gs-pw-meter[hidden] { display: none; }
.pun .gs-pw-bar {
  flex: 0 0 120px;
  height: 4px;
  background: #2a2a2a;
  border-radius: 2px;
  overflow: hidden;
}
.pun .gs-pw-bar i {
  display: block;
  height: 100%;
  width: 0;
  background: #95b806;
  transition: width .2s, background .2s;
}
.pun .gs-pw-meter[data-score="0"] .gs-pw-bar i,
.pun .gs-pw-meter[data-score="1"] .gs-pw-bar i { background: #c0392b; }
.pun .gs-pw-meter[data-score="2"] .gs-pw-bar i { background: #d68910; }
.pun .gs-pw-meter[data-score="3"] .gs-pw-bar i { background: #95b806; }
.pun .gs-pw-meter[data-score="4"] .gs-pw-bar i { background: #b4e61e; }
.pun .gs-pw-label { font-size: 10px; color: #8b8b88; }

/* ---------- 用户协议勾选框 ---------- */
.pun .gs-terms-label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 2px 0;
  font-size: 11px;
  color: #c0c0ba;
  cursor: pointer;
}
.pun .gs-terms-label input[type="checkbox"] {
  margin: 2px 0 0;
  flex: 0 0 auto;
}
.pun .gs-terms-label a { color: #b4e61e; }

/* ---------- 用户协议正文 ---------- */
.pun .gs-terms-body h3 {
  margin: 16px 0 6px;
  font-size: 12px;
  font-weight: bold;
  color: #e0e0da;
}
.pun .gs-terms-body h3:first-child { margin-top: 0; }
.pun .gs-terms-body p,
.pun .gs-terms-body li { color: #a9a9a4; line-height: 1.8; }
.pun .gs-terms-body ul { list-style: disc; padding-left: 20px; }
.pun .gs-terms-body li { margin: 2px 0; }
