/* ===== 拾光潮汐 - 认证系统样式（海洋主题：深色背景 + 蓝白配色） ===== */

/* 导航栏认证按钮 */
.sgcx-nav-auth {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 12px;
}

.sgcx-nav-auth .sgcx-btn {
  padding: 6px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
  white-space: nowrap;
}

.sgcx-btn-primary {
  background: linear-gradient(135deg, #0ea5e9, #0284c7);
  color: #fff;
  border: none;
  cursor: pointer;
}
.sgcx-btn-primary:hover {
  background: linear-gradient(135deg, #38bdf8, #0ea5e9);
  box-shadow: 0 0 16px rgba(14, 165, 233, 0.4);
}

.sgcx-btn-outline {
  background: transparent;
  color: #7dd3fc;
  border: 1px solid rgba(125, 211, 252, 0.4);
  cursor: pointer;
}
.sgcx-btn-outline:hover {
  border-color: #38bdf8;
  color: #bae6fd;
  background: rgba(14, 165, 233, 0.1);
}

/* 下拉菜单 */
.sgcx-dropdown-trigger {
  color: #7dd3fc;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  padding: 6px 8px;
  border-radius: 6px;
  transition: all 0.2s;
}
.sgcx-dropdown-trigger:hover {
  color: #bae6fd;
  background: rgba(14, 165, 233, 0.1);
}

.sgcx-dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: 100%;
  margin-top: 6px;
  background: #0f2744;
  border: 1px solid rgba(125, 211, 252, 0.2);
  border-radius: 8px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  min-width: 160px;
  z-index: 1000;
  overflow: hidden;
}
.sgcx-dropdown-menu.sgcx-dropdown-open {
  display: block;
}
.sgcx-dropdown-menu a,
.sgcx-dropdown-menu span {
  display: block;
  padding: 10px 16px;
  color: #bae6fd;
  text-decoration: none;
  font-size: 13px;
  transition: background 0.15s;
}
.sgcx-dropdown-menu a:hover {
  background: rgba(14, 165, 233, 0.15);
  color: #fff;
}
.sgcx-pending-badge {
  color: #fbbf24 !important;
  font-style: italic;
}

.sgcx-logged-in {
  position: relative;
}

/* 弹窗 */
.sgcx-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: sgcxFadeIn 0.2s ease;
}
@keyframes sgcxFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.sgcx-modal {
  background: #0c1f3a;
  border: 1px solid rgba(125, 211, 252, 0.25);
  border-radius: 16px;
  box-shadow: 0 16px 64px rgba(0, 0, 0, 0.5), 0 0 40px rgba(14, 165, 233, 0.1);
  width: 420px;
  max-width: 95vw;
  max-height: 90vh;
  overflow-y: auto;
  animation: sgcxSlideUp 0.25s ease;
}
@keyframes sgcxSlideUp {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.sgcx-modal-content {
  padding: 32px 28px;
  position: relative;
}

.sgcx-modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  color: #64748b;
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
}
.sgcx-modal-close:hover {
  color: #bae6fd;
}

.sgcx-modal-title {
  margin: 0 0 24px;
  font-size: 22px;
  font-weight: 700;
  color: #e0f2fe;
  text-align: center;
}

/* 表单 */
.sgcx-form-group {
  margin-bottom: 18px;
}
.sgcx-form-group label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 500;
  color: #7dd3fc;
}
.sgcx-form-group input[type="text"],
.sgcx-form-group input[type="password"],
.sgcx-form-group input[type="number"] {
  width: 100%;
  padding: 10px 14px;
  background: #0a1628;
  border: 1px solid rgba(125, 211, 252, 0.2);
  border-radius: 8px;
  color: #e0f2fe;
  font-size: 14px;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
  outline: none;
}
.sgcx-form-group input:focus {
  border-color: #0ea5e9;
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
}

/* 角色选择 */
.sgcx-role-select {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.sgcx-role-option {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  background: #0a1628;
  border: 1px solid rgba(125, 211, 252, 0.15);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  gap: 10px;
}
.sgcx-role-option:hover {
  border-color: rgba(125, 211, 252, 0.35);
  background: #0d1e35;
}
.sgcx-role-option input[type="radio"] {
  accent-color: #0ea5e9;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.sgcx-role-label {
  color: #e0f2fe;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}
.sgcx-role-desc {
  color: #64748b;
  font-size: 12px;
  margin-left: auto;
}

/* 验证码 */
.sgcx-captcha-q {
  display: inline-block;
  background: #0a1628;
  border: 1px solid rgba(125, 211, 252, 0.3);
  border-radius: 6px;
  padding: 4px 12px;
  color: #38bdf8;
  font-weight: 600;
  font-size: 14px;
  margin-left: 6px;
  font-family: 'Courier New', monospace;
}

/* 按钮 */
.sgcx-modal .sgcx-btn {
  width: 100%;
  padding: 12px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  margin-top: 8px;
}

/* 错误提示 */
.sgcx-form-error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 8px;
  padding: 10px 14px;
  color: #fca5a5;
  font-size: 13px;
  margin-bottom: 8px;
}

/* 底部链接 */
.sgcx-form-footer {
  text-align: center;
  margin-top: 18px;
  font-size: 13px;
  color: #64748b;
}
.sgcx-form-footer a {
  color: #38bdf8;
  text-decoration: none;
  font-weight: 500;
}
.sgcx-form-footer a:hover {
  text-decoration: underline;
}

/* ===== 管理员审核页面 ===== */
.sgcx-admin-page {
  max-width: 900px;
  margin: 40px auto;
  padding: 0 20px;
  color: #e0f2fe;
}
.sgcx-admin-page h1 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
  color: #bae6fd;
}
.sgcx-admin-page .sgcx-admin-subtitle {
  color: #64748b;
  margin-bottom: 32px;
  font-size: 14px;
}

.sgcx-pending-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.sgcx-pending-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: #0a1628;
  border: 1px solid rgba(125, 211, 252, 0.12);
  border-radius: 10px;
  transition: border-color 0.2s;
}
.sgcx-pending-item:hover {
  border-color: rgba(125, 211, 252, 0.3);
}
.sgcx-pending-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sgcx-pending-username {
  font-size: 15px;
  font-weight: 600;
  color: #e0f2fe;
}
.sgcx-pending-meta {
  font-size: 12px;
  color: #64748b;
}
.sgcx-pending-role {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
}
.sgcx-role-captain {
  background: rgba(14, 165, 233, 0.2);
  color: #38bdf8;
}
.sgcx-role-shop {
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
}
.sgcx-pending-actions {
  display: flex;
  gap: 8px;
}
.sgcx-btn-approve {
  padding: 8px 20px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #fff;
  transition: all 0.2s;
}
.sgcx-btn-approve:hover {
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.4);
}
.sgcx-btn-reject {
  padding: 8px 20px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid rgba(239, 68, 68, 0.4);
  cursor: pointer;
  background: transparent;
  color: #fca5a5;
  transition: all 0.2s;
}
.sgcx-btn-reject:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.6);
}
.sgcx-empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #64748b;
}

/* 管理员页面的加载/错误状态 */
.sgcx-loading {
  text-align: center;
  padding: 40px;
  color: #64748b;
}
.sgcx-admin-error {
  text-align: center;
  padding: 40px;
  color: #fca5a5;
}

/* 操作按钮禁用态 */
.sgcx-pending-actions button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
