/**
 * 玩家控制台 · Apple 风格（清晰、留白、毛玻璃侧栏）
 */
:root {
  --api-bg: #f5f5f7;
  --api-bg-elevated: #ffffff;
  --api-surface: #ffffff;
  --api-surface-2: #fbfbfd;
  --api-border: rgba(0, 0, 0, 0.06);
  --api-border-strong: rgba(0, 0, 0, 0.1);
  --api-text: #1d1d1f;
  --api-text-secondary: #6e6e73;
  --api-text-muted: #86868b;
  --api-accent: #0071e3;
  --api-accent-hover: #0077ed;
  --api-accent-soft: rgba(0, 113, 227, 0.1);
  --api-sidebar: rgba(251, 251, 253, 0.78);
  --api-sidebar-hover: rgba(0, 0, 0, 0.04);
  --api-sidebar-active: rgba(0, 113, 227, 0.12);
  --api-sidebar-text: #1d1d1f;
  --api-sidebar-muted: #86868b;
  /* IDE · VS Code Dark+ */
  --ide-bg: #1e1e1e;
  --ide-bg-elevated: #252526;
  --ide-chrome: #2d2d2d;
  --ide-border: #3c3c3c;
  --ide-text: #d4d4d4;
  --ide-text-dim: #858585;
  --ide-key: #9cdcfe;
  --ide-str: #ce9178;
  --ide-num: #b5cea8;
  --ide-bool: #569cd6;
  --ide-kw: #c586c0;
  --ide-fn: #dcdcaa;
  --ide-comment: #6a9955;
  --ide-flag: #4ec9b0;
  --ide-type: #4ec9b0;
  --api-code-bg: var(--ide-bg);
  --api-code-border: var(--ide-border);
  --api-radius: 10px;
  --api-radius-lg: 14px;
  --api-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  --api-shadow-md: 0 8px 30px rgba(0, 0, 0, 0.06);
  --api-font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "PingFang SC",
    "Helvetica Neue", "Microsoft YaHei UI", sans-serif;
  --api-mono: "JetBrains Mono", "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
  --api-nav-width: 252px;
  --api-docs-nav-width: 268px;
  --api-space-xs: 8px;
  --api-space-sm: 16px;
  --api-space-md: 24px;
  --api-space-lg: 32px;
  --api-space-xl: 40px;
  --api-topbar-h: 60px;
  --api-content-max: 1120px;
}

body.player-portal.player-console-app {
  font-family: var(--api-font);
  background: var(--api-bg);
  color: var(--api-text);
  font-size: 14px;
  line-height: 1.55;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.player-portal a {
  color: var(--api-accent);
  text-decoration: none;
  transition: color 0.15s ease;
}
body.player-portal a:hover {
  color: var(--api-accent-hover);
}

/* —— 侧栏（毛玻璃） —— */
body.player-portal.player-console-app .sidebar {
  width: var(--api-nav-width);
  background: var(--api-sidebar);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-right: 1px solid var(--api-border);
  box-shadow: 1px 0 0 rgba(255, 255, 255, 0.6) inset;
}

body.player-portal .sidebar .brand {
  padding: 20px 16px 16px;
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .brand-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

body.player-portal .brand-mark {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

body.player-portal .brand-mark svg,
body.player-portal .brand-default-img {
  width: 36px;
  height: 36px;
  display: block;
  border-radius: 9px;
  object-fit: contain;
}

body.player-portal .brand-logo-img {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  object-fit: contain;
}

body.player-portal .brand-title {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--api-text);
  letter-spacing: -0.02em;
  line-height: 1.25;
}

body.player-portal .sidebar .brand-sub {
  display: block;
  font-size: 11px;
  font-weight: 500;
  color: var(--api-sidebar-muted);
  margin-top: 2px;
  letter-spacing: 0.01em;
}

body.player-portal .sidebar-nav {
  padding: 8px 10px 12px;
  flex: 1;
  overflow-y: auto;
}

body.player-portal .nav-section-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--api-sidebar-muted);
  letter-spacing: 0.02em;
  padding: 16px 12px 6px;
  margin: 0;
}

body.player-portal .sidebar-nav > .nav-section-label:first-child {
  padding-top: 8px;
}

body.player-portal .nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  margin: 2px 0;
  border-radius: var(--api-radius);
  color: var(--api-sidebar-text);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.18s ease, color 0.18s ease;
}

body.player-portal .nav-item:hover {
  background: var(--api-sidebar-hover);
  color: var(--api-text);
  text-decoration: none;
}

body.player-portal .nav-item.active {
  background: var(--api-sidebar-active);
  color: var(--api-accent);
  font-weight: 600;
}

body.player-portal .nav-item.active .nav-icon {
  color: var(--api-accent);
}

body.player-portal .nav-icon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  color: var(--api-sidebar-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--api-border);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

body.player-portal .nav-icon svg {
  width: 18px;
  height: 18px;
  display: block;
}

body.player-portal .nav-icon-img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  display: block;
}

body.player-portal .nav-item.active .nav-icon {
  background: var(--api-accent-soft);
  border-color: rgba(0, 113, 227, 0.35);
}

body.player-portal .nav-label {
  flex: 1;
  min-width: 0;
}

body.player-portal .sidebar .foot {
  padding: 14px 14px 18px;
  border-top: 1px solid var(--api-border);
  background: rgba(255, 255, 255, 0.35);
}

body.player-portal .foot-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

body.player-portal .foot-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.05);
  color: var(--api-sidebar-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}

body.player-portal .foot-avatar img.foot-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}

body.player-portal .foot-avatar img.foot-avatar-img.hidden {
  display: none;
}

body.player-portal .foot-avatar svg.foot-avatar-fallback {
  width: 18px;
  height: 18px;
}

body.player-portal .btn.btn-sm {
  padding: 6px 14px;
  font-size: 13px;
  border-radius: 6px;
}

/* —— 个人资料页 —— */
body.player-portal .profile-page {
  max-width: 1080px;
}

body.player-portal .profile-page-lead {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--api-text-secondary);
  line-height: 1.5;
}

body.player-portal .profile-top-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 14px;
  margin-bottom: 14px;
}

body.player-portal .profile-login-card {
  margin-bottom: 14px;
}

body.player-portal .profile-login-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

body.player-portal .profile-login-subtitle {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--api-accent);
  letter-spacing: 0.03em;
}

body.player-portal .profile-login-block-prev .profile-login-subtitle {
  color: var(--api-text-muted);
}

body.player-portal .profile-login-block {
  padding: 12px 14px;
  background: var(--api-surface-2);
  border: 1px solid var(--api-border);
  border-radius: 10px;
}

body.player-portal .profile-login-meta {
  grid-template-columns: 1fr;
  gap: 8px;
}

body.player-portal .profile-login-meta .profile-meta-item dd {
  font-family: var(--api-mono);
  font-size: 13px;
}

@media (max-width: 720px) {
  body.player-portal .profile-login-columns {
    grid-template-columns: 1fr;
  }
}

body.player-portal .profile-records-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

body.player-portal .profile-card-compact {
  padding: 16px 18px;
  margin-bottom: 0;
}

body.player-portal .profile-card-compact .profile-card-title {
  margin: 0 0 12px;
  padding: 0;
  border: none;
  font-size: 15px;
  font-weight: 600;
  color: var(--api-text);
  letter-spacing: -0.01em;
}

body.player-portal .profile-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

body.player-portal .profile-card-head .profile-card-title {
  margin: 0;
}

body.player-portal .profile-identity {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .profile-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--api-surface-2);
  flex-shrink: 0;
  border: 1px solid var(--api-border);
}

body.player-portal .profile-display-name {
  margin: 0 0 2px;
  font-size: 16px;
  font-weight: 600;
  color: var(--api-text);
  line-height: 1.3;
}

body.player-portal .profile-username {
  margin: 0 0 6px;
  font-size: 12px;
  color: var(--api-text-muted);
}

body.player-portal .profile-avatar-hint {
  margin: 0;
  font-size: 11px;
  color: var(--api-text-muted);
  line-height: 1.45;
}

body.player-portal .profile-meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
  margin: 0;
}

body.player-portal .profile-meta-item {
  margin: 0;
  min-width: 0;
}

body.player-portal .profile-meta-item dt {
  margin: 0 0 3px;
  font-size: 11px;
  font-weight: 500;
  color: var(--api-text-muted);
  text-transform: none;
  letter-spacing: 0.02em;
}

body.player-portal .profile-meta-item dd {
  margin: 0;
  font-size: 13px;
  color: var(--api-text);
  line-height: 1.4;
  word-break: break-word;
}

body.player-portal .profile-wallet-card .profile-wallet-body {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

body.player-portal .profile-wallet-balance {
  font-size: 26px;
  line-height: 1.15;
}

body.player-portal .profile-wallet-hint {
  margin: 10px 0 0;
  font-size: 11px;
  color: var(--api-text-muted);
  line-height: 1.45;
}

body.player-portal .profile-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 16px;
}

body.player-portal .profile-form-grid .profile-field {
  margin-bottom: 0;
}

body.player-portal .profile-form-grid .profile-field-full {
  grid-column: 1 / -1;
}

body.player-portal .profile-form-grid .form-row label {
  margin-bottom: 5px;
  font-size: 12px;
}

body.player-portal .profile-form-grid .form-row input,
body.player-portal .profile-form-grid .form-row textarea {
  max-width: none;
  padding: 7px 10px;
  font-size: 13px;
}

body.player-portal .profile-form-grid .form-row textarea {
  min-height: 56px;
  resize: vertical;
}

body.player-portal .profile-edit-card .msg {
  margin-bottom: 10px;
}

body.player-portal .profile-table-wrap {
  overflow-x: auto;
  margin: 0 -2px;
}

body.player-portal .table-compact {
  width: 100%;
  font-size: 12px;
}

body.player-portal .table-compact th,
body.player-portal .table-compact td {
  padding: 7px 8px;
  vertical-align: middle;
}

body.player-portal .table-compact th {
  font-size: 11px;
  font-weight: 600;
  color: var(--api-text-muted);
  white-space: nowrap;
}

body.player-portal .table-compact .table-empty {
  text-align: center;
  color: var(--api-text-muted);
  padding: 20px 8px;
}

body.player-portal .table-compact .time-cell {
  white-space: nowrap;
  font-size: 11px;
  color: var(--api-text-secondary);
}

body.player-portal .table-compact .mono-cell {
  font-family: var(--api-mono);
  font-size: 11px;
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.player-portal .table-compact .num-cell {
  font-family: var(--api-mono);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

body.player-portal .table-compact .remark-cell {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--api-text-secondary);
}

@media (max-width: 900px) {
  body.player-portal .profile-top-grid,
  body.player-portal .profile-records-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  body.player-portal .profile-meta-grid,
  body.player-portal .profile-form-grid {
    grid-template-columns: 1fr;
  }
}

body.player-portal .foot-username,
body.player-portal .sidebar .foot #userLabel {
  font-size: 13px;
  font-weight: 600;
  color: var(--api-text);
  line-height: 1.3;
}

body.player-portal .foot-logout {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--api-radius);
  color: var(--api-text-secondary) !important;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none !important;
  transition: background 0.15s ease;
}

body.player-portal .foot-logout:hover {
  background: rgba(0, 0, 0, 0.05);
  color: var(--api-text) !important;
}

body.player-portal .foot-logout .nav-icon {
  width: 18px;
  height: 18px;
}

/* 兼容旧选择器 */
body.player-portal .sidebar nav a.nav-item {
  display: flex;
}

/* —— 主区 —— */
body.player-portal.player-console-app .main {
  background: var(--api-bg);
}

body.player-portal .topbar,
body.player-portal .player-topbar {
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--api-border);
  padding: 0 var(--api-space-lg);
  min-height: var(--api-topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--api-space-sm);
  position: sticky;
  top: 0;
  z-index: 30;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9);
}

body.player-portal .topbar h1,
body.player-portal .topbar strong {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--api-text);
  letter-spacing: -0.03em;
  line-height: 1.25;
}

body.player-portal .topbar-meta,
body.player-portal #balanceLabel {
  font-size: 13px;
  color: var(--api-text-muted) !important;
  font-weight: 500;
  padding: 4px 12px;
  background: rgba(0, 0, 0, 0.04);
  border-radius: 20px;
}

body.player-portal .content,
body.player-portal .player-content {
  padding: var(--api-space-md) var(--api-space-lg) var(--api-space-xl);
  flex: 1;
}

body.player-portal .card {
  background: var(--api-surface);
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius-lg);
  padding: 24px 28px;
  box-shadow: var(--api-shadow-md);
  margin-bottom: 20px;
}

body.player-portal .card h2 {
  font-size: 18px;
  font-weight: 600;
  color: var(--api-text);
  margin: 0 0 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--api-border);
  letter-spacing: -0.02em;
}

/* —— 表单与按钮 —— */
body.player-portal .form-row label {
  display: block !important;
  width: auto !important;
  max-width: 100%;
  overflow: visible !important;
  color: var(--api-text-secondary);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 8px;
}

body.player-portal .form-row input,
body.player-portal .form-row textarea,
body.player-portal .form-row select {
  border: 1px solid var(--api-border-strong);
  border-radius: var(--api-radius);
  padding: 9px 12px;
  color: var(--api-text);
  background: var(--api-surface);
  transition: border-color 0.15s, box-shadow 0.15s;
}

body.player-portal .form-row input:focus,
body.player-portal .form-row textarea:focus,
body.player-portal .form-row select:focus {
  outline: none;
  border-color: var(--api-accent);
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.18);
}

body.player-portal .btn {
  color: #fff;
  background: var(--api-accent);
  border: none;
  border-radius: 980px;
  font-weight: 500;
  padding: 9px 20px;
  font-size: 14px;
  letter-spacing: -0.01em;
  transition: background 0.15s ease, opacity 0.15s ease;
}
body.player-portal .btn:hover {
  background: var(--api-accent-hover);
}
body.player-portal .btn.secondary {
  background: var(--api-surface);
  color: var(--api-text);
  border: 1px solid var(--api-border-strong);
  border-radius: 980px;
}
body.player-portal .btn.secondary:hover {
  background: var(--api-surface-2);
}

body.player-portal table th {
  background: var(--api-surface-2);
  color: var(--api-text-secondary);
  font-size: 12px;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.02em;
  border-bottom: 1px solid var(--api-border);
}

body.player-portal table td {
  border-bottom: 1px solid var(--api-border);
  color: var(--api-text);
  padding: 12px 14px;
}

body.player-portal .key-mono {
  font-family: var(--api-mono);
  font-size: 12px;
  background: var(--api-surface-2);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--api-border);
}

/* —— 接口文档页 —— */
body.player-portal .docs-page {
  padding: 0 !important;
  border: none;
  box-shadow: none;
  background: transparent;
}

body.player-portal .docs-page-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--api-text);
  margin: 0 0 6px;
  letter-spacing: -0.03em;
}

body.player-portal .docs-page-sub {
  font-size: 13px;
  color: var(--api-text-muted);
  margin: 0 0 20px;
  line-height: 1.5;
}

body.player-portal .docs-integration-banner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 0 0 18px;
}

@media (max-width: 960px) {
  body.player-portal .docs-integration-banner {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 520px) {
  body.player-portal .docs-integration-banner {
    grid-template-columns: 1fr;
  }
}

body.player-portal .docs-pillar {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  background: var(--api-surface-2);
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius);
  font-size: 12px;
  color: var(--api-text-muted);
  line-height: 1.45;
}

body.player-portal .docs-pillar strong {
  color: var(--api-text);
  font-size: 13px;
}

body.player-portal .docs-pillar-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--api-accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  margin-bottom: 2px;
}

body.player-portal .docs-pillar a {
  margin-top: 4px;
  font-weight: 600;
  font-size: 12px;
}

body.player-portal .docs-pillar-visual a {
  color: var(--api-accent);
}

body.player-portal .docs-coverage-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 24px;
  margin: 12px 0 14px;
  font-size: 13px;
  color: var(--api-text-muted);
}

body.player-portal .docs-coverage-stats strong {
  color: var(--api-text);
  font-size: 15px;
  margin-left: 4px;
}

body.player-portal .docs-coverage-table code.cov-param {
  font-size: 11px;
  color: var(--api-text-muted);
}

body.player-portal .cov-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
}

body.player-portal .cov-full {
  background: rgba(34, 197, 94, 0.12);
  color: #15803d;
}

body.player-portal .cov-partial {
  background: rgba(234, 179, 8, 0.15);
  color: #a16207;
}

body.player-portal .cov-h5only {
  background: rgba(59, 130, 246, 0.1);
  color: #1d4ed8;
}

body.player-portal .cov-nav {
  background: var(--api-surface-3, #f1f5f9);
  color: var(--api-text-muted);
}

body.player-portal .doc-h5-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin: 8px 0 10px;
  padding: 8px 12px;
  background: rgba(59, 130, 246, 0.06);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 6px;
  font-size: 12px;
}

body.player-portal .doc-h5-label {
  font-weight: 700;
  color: #1d4ed8;
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 0.06em;
}

body.player-portal .doc-h5-meta {
  color: var(--api-text-muted);
  flex: 1;
  min-width: 140px;
}

body.player-portal .doc-sync-policy {
  margin: 16px 0;
  padding: 14px 16px;
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius);
  background: var(--api-surface-2);
}

body.player-portal .doc-sync-policy .doc-h4 {
  margin: 0 0 8px;
}

body.player-portal .docs-layout {
  display: flex;
  gap: 0;
  min-height: calc(100vh - 200px);
  background: var(--api-surface);
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius-lg);
  box-shadow: var(--api-shadow-md);
  overflow: hidden;
}

body.player-portal .h5map-base-url {
  margin: 12px 0 16px;
  padding: 12px 14px;
  border-radius: 10px;
  background: linear-gradient(135deg, #e8f4ff 0%, #f0f7ff 100%);
  border: 1px solid #91caff;
}

body.player-portal .h5map-base-label {
  margin: 0 0 6px;
  font-size: 13px;
  color: var(--api-text);
}

body.player-portal .h5map-base-link-row {
  margin: 0 0 6px;
}

body.player-portal .h5map-base-link,
body.player-portal .h5map-page-link,
body.player-portal .h5map-open-link {
  color: #0958d9;
  word-break: break-all;
}

body.player-portal .h5map-url-snippet {
  display: inline-block;
  margin-top: 4px;
  font-size: 11px;
  color: var(--api-text-secondary);
  word-break: break-all;
}

body.player-portal .h5map-summary-table .h5map-open-link {
  font-weight: 600;
  text-decoration: none;
}

body.player-portal .h5map-summary-table .h5map-open-link:hover,
body.player-portal .h5map-page-link:hover,
body.player-portal .h5map-base-link:hover {
  text-decoration: underline;
}

body.player-portal .docs-subnav {
  width: var(--api-docs-nav-width);
  flex-shrink: 0;
  background: var(--api-surface-2);
  border-right: 1px solid var(--api-border);
  padding: 16px 12px;
  max-height: calc(100vh - 200px);
  overflow-y: auto;
}

body.player-portal .docs-subnav-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--api-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0 10px 10px;
  margin: 0;
}

body.player-portal .docs-sub-group {
  padding: 14px 10px 6px;
  margin: 0;
  border-top: 1px solid var(--api-border);
}
body.player-portal .docs-sub-group:first-of-type {
  border-top: none;
  padding-top: 6px;
}

body.player-portal .docs-nav-cat {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--api-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.3;
}

body.player-portal .docs-sub-link {
  display: block;
  padding: 7px 10px;
  margin: 1px 0;
  border-radius: 6px;
  border-left: 3px solid transparent;
  line-height: 1.35;
  text-decoration: none;
  color: inherit;
}

body.player-portal .docs-sub-link:hover {
  background: #fff;
  text-decoration: none;
}

body.player-portal .docs-sub-link.active {
  background: var(--api-accent-soft);
  border-left-color: transparent;
  box-shadow: inset 3px 0 0 var(--api-accent);
}

body.player-portal .docs-nav-top-text {
  font-size: 13px;
  font-weight: 500;
  color: var(--api-text-secondary);
}

body.player-portal .docs-sub-link.docs-sub-top:hover .docs-nav-top-text,
body.player-portal .docs-sub-link.docs-sub-top.active .docs-nav-top-text {
  color: var(--api-accent);
  font-weight: 600;
}

body.player-portal .docs-sub-link.docs-sub-page {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

body.player-portal .docs-nav-page-text {
  flex: 1;
  min-width: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--api-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.player-portal .docs-sub-link.docs-sub-page:hover .docs-nav-page-text,
body.player-portal .docs-sub-link.docs-sub-page.active .docs-nav-page-text {
  color: var(--api-accent);
}

body.player-portal .docs-sub-link.docs-sub-api {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 12px;
}

body.player-portal .docs-nav-api-method {
  flex-shrink: 0;
  width: 38px;
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  line-height: 1.5;
  padding: 2px 0;
  border-radius: 4px;
  font-family: var(--api-mono);
}

body.player-portal .docs-nav-api-text {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  font-weight: 400;
  color: var(--api-text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.player-portal .docs-sub-link.docs-sub-api:hover .docs-nav-api-text,
body.player-portal .docs-sub-link.docs-sub-api.active .docs-nav-api-text {
  color: var(--api-text);
  font-weight: 500;
}

body.player-portal .docs-sub-link.docs-sub-api.active .docs-nav-api-text {
  color: var(--api-accent);
}

body.player-portal .docs-sub-link .usage-badge-sm {
  font-size: 10px;
  font-weight: 600;
  padding: 1px 6px;
  border-radius: 4px;
  line-height: 1.35;
  margin: 0;
  vertical-align: baseline;
}

body.player-portal .docs-sub-h5-head {
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--api-border);
}

body.player-portal .docs-sub-h5-head .docs-nav-cat {
  color: #0958d9;
}

body.player-portal .docs-sub-h5-cat .docs-nav-cat-sm {
  font-size: 10px;
  padding-top: 8px;
}

body.player-portal .docs-sub-link.docs-sub-h5-link {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #0958d9;
}

body.player-portal .docs-sub-link.docs-sub-h5-link:hover {
  background: rgba(9, 88, 217, 0.06);
}

body.player-portal .docs-sub-link.docs-sub-h5-link .docs-nav-page-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.player-portal .docs-sub-link.docs-sub-h5-link.active {
  background: rgba(9, 88, 217, 0.1);
  font-weight: 600;
}

body.player-portal .docs-content {
  display: flex;
  flex: 1;
  min-width: 0;
  min-height: 0;
}

body.player-portal .docs-layout.has-h5-preview .docs-main {
  flex: 1;
  min-width: 0;
  border-right: 1px solid var(--api-border);
}

body.player-portal .docs-h5-preview {
  width: min(52%, 520px);
  min-width: 320px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  background: var(--api-surface);
}

body.player-portal .docs-h5-preview.hidden {
  display: none;
}

body.player-portal .docs-h5-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--api-border);
  background: var(--api-surface-2);
}

body.player-portal .docs-h5-preview-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--api-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.player-portal .docs-h5-preview-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

body.player-portal .docs-h5-preview-open {
  font-size: 12px;
  color: #0958d9;
  text-decoration: none;
}

body.player-portal .docs-h5-preview-open:hover {
  text-decoration: underline;
}

body.player-portal .docs-h5-preview-close {
  border: none;
  background: transparent;
  color: var(--api-text-muted);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

body.player-portal .docs-h5-preview-close:hover {
  color: var(--api-text);
}

body.player-portal .docs-h5-preview-frame {
  flex: 1;
  width: 100%;
  min-height: 420px;
  border: 0;
  background: #f5f5f5;
}

body.player-portal .docs-layout.has-h5-preview .docs-h5-preview {
  max-height: calc(100vh - var(--api-topbar-h) - 168px);
}

/* 体彩 H5 独立页 · 三联手机预览（仅 page=h5preview，接口文档不展示） */
body.player-portal .player-content > .card.h5-preview-page {
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 0;
  border: none;
  box-shadow: none;
  background: transparent;
}

body.player-portal .h5-preview-page .docs-h5-spotlight {
  margin: 0;
  width: 100%;
  min-height: calc(100vh - var(--api-topbar-h) - 40px);
}

body.player-portal .h5-preview-page.has-h5-spotlight .docs-h5-spotlight {
  flex: 1;
}

/* 接口文档 · 三联 H5 预览（已迁至 h5preview 页，以下保留兼容） */
body.player-portal .docs-page.has-h5-spotlight .docs-h5-spotlight {
  margin: 0 var(--api-space-md) var(--api-space-md);
  width: calc(100% - 2 * var(--api-space-md));
  max-width: none;
}

body.player-portal .docs-h5-spotlight {
  --docs-phone-h: clamp(560px, calc(100vh - 200px), 860px);
  --docs-phone-gap: clamp(16px, 2.5vw, 36px);
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #f0f2f8 0%, #e8ecf4 100%);
  border: 1px solid var(--api-border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--api-shadow-sm);
}

body.player-portal .docs-h5-spotlight-head {
  padding: 12px 16px;
  border-bottom: 1px solid var(--api-border);
  background: linear-gradient(180deg, var(--api-surface) 0%, var(--api-surface-2) 100%);
}

body.player-portal .docs-h5-spotlight-title {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--api-text);
  letter-spacing: 0.02em;
}

body.player-portal .docs-h5-spotlight-hint {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--api-text-muted);
}

body.player-portal .docs-h5-spotlight-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  justify-items: center;
  gap: var(--docs-phone-gap);
  padding: clamp(20px, 3vw, 40px) clamp(16px, 2vw, 32px) clamp(24px, 3vw, 44px);
  min-height: calc(var(--docs-phone-h) + 56px);
  width: 100%;
  box-sizing: border-box;
}

body.player-portal .docs-h5-phone-window {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  width: 100%;
  max-width: min(420px, 100%);
  min-width: 0;
  transition: transform 0.15s ease, filter 0.15s ease;
}

body.player-portal .docs-h5-phone-window.active {
  transform: translateY(-4px);
  filter: drop-shadow(0 8px 20px rgba(0, 113, 227, 0.18));
}

body.player-portal .docs-h5-phone-window-head {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 2px 8px;
  width: 100%;
  padding: 0 4px;
  text-align: center;
}

body.player-portal .docs-h5-phone-window-title {
  grid-column: 1;
  grid-row: 1;
  font-size: 13px;
  font-weight: 700;
  color: var(--api-text);
}

body.player-portal .docs-h5-phone-window-sub {
  grid-column: 1;
  grid-row: 2;
  font-size: 11px;
  color: var(--api-text-muted);
}

body.player-portal .docs-h5-phone-window-open {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: center;
  width: 28px;
  height: 28px;
  line-height: 28px;
  text-align: center;
  border-radius: 50%;
  background: var(--api-surface);
  border: 1px solid var(--api-border);
  font-size: 14px;
  color: #0958d9;
  text-decoration: none;
}

body.player-portal .docs-h5-phone-window-open:hover {
  background: #e6f4ff;
  border-color: #91caff;
}

body.player-portal .docs-h5-phone-shell {
  width: 100%;
  padding: 6px;
  box-sizing: border-box;
}

body.player-portal .docs-h5-phone-bezel {
  position: relative;
  width: 100%;
  background: linear-gradient(145deg, #2a2d35 0%, #12141a 55%, #1e2129 100%);
  border-radius: clamp(24px, 3vw, 36px);
  padding: clamp(10px, 1.2vw, 14px) clamp(8px, 1vw, 12px) clamp(12px, 1.5vw, 18px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.08) inset,
    0 16px 40px rgba(0, 0, 0, 0.38),
    0 4px 10px rgba(0, 0, 0, 0.22);
  box-sizing: border-box;
}

body.player-portal .docs-h5-phone-notch {
  display: none !important;
}

body.player-portal .docs-h5-phone-screen {
  position: relative;
  width: 100%;
  height: var(--docs-phone-h);
  max-height: 78vh;
  border-radius: clamp(16px, 2vw, 22px);
  overflow: hidden;
  background: #000;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.5) inset;
}

body.player-portal .docs-h5-spot-frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #f5f5f7;
}

body.player-portal .docs-h5-phone-home {
  width: 36%;
  max-width: 88px;
  height: 4px;
  margin: 10px auto 0;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.35);
}

body.player-portal .nav-icon-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}

body.player-portal .nav-icon-beidan {
  background: linear-gradient(145deg, #0d9488 0%, #0f766e 100%);
}

body.player-portal .nav-icon-basketball {
  background: linear-gradient(145deg, #ea580c 0%, #c2410c 100%);
}

/* 体彩门户首页 · 仿手机屏幕弹窗预览 */
body.player-portal .h5-phone-preview-mask {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(4px);
  box-sizing: border-box;
}

body.player-portal .h5-phone-preview-mask.hidden {
  display: none;
}

body.player-portal.h5-phone-preview-open {
  overflow: hidden;
}

body.player-portal .h5-phone-preview-dialog {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: min(420px, 100%);
  width: 100%;
  max-height: calc(100vh - 48px);
  animation: h5-phone-pop-in 0.22s ease-out;
}

@keyframes h5-phone-pop-in {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

body.player-portal .h5-phone-preview-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  max-width: 390px;
  margin-bottom: 12px;
  padding: 10px 14px;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

body.player-portal .h5-phone-preview-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--api-text);
}

body.player-portal .h5-phone-preview-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

body.player-portal .h5-phone-preview-open {
  font-size: 12px;
  color: #0958d9;
  text-decoration: none;
}

body.player-portal .h5-phone-preview-close {
  border: none;
  background: transparent;
  color: var(--api-text-muted);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

body.player-portal .h5-phone-device-wrap {
  display: flex;
  justify-content: center;
  width: 100%;
}

body.player-portal .h5-phone-device {
  --phone-w: min(390px, calc(100vw - 48px));
  width: var(--phone-w);
  max-height: min(780px, calc(100vh - 120px));
  display: flex;
  flex-direction: column;
  padding: 10px 10px 14px;
  border-radius: 36px;
  background: linear-gradient(145deg, #2a2a2e 0%, #1a1a1d 100%);
  box-shadow:
    0 0 0 2px #3d3d42,
    0 24px 48px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  box-sizing: border-box;
}

body.player-portal .h5-phone-status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 22px;
  padding: 0 16px 4px;
  color: #f5f5f5;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}

body.player-portal .h5-phone-signal {
  width: 14px;
  height: 8px;
  border: 1.5px solid #f5f5f5;
  border-radius: 2px;
  opacity: 0.85;
}

body.player-portal .h5-phone-screen {
  flex: 1;
  min-height: 0;
  width: 100%;
  border-radius: 24px;
  overflow: hidden;
  background: #000;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

body.player-portal .h5-phone-frame {
  display: block;
  width: 100%;
  height: 100%;
  min-height: min(640px, calc(100vh - 180px));
  border: 0;
  background: #f5f5f5;
}

body.player-portal .h5-phone-home-indicator {
  width: 36%;
  max-width: 120px;
  height: 4px;
  margin: 10px auto 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  flex-shrink: 0;
}

@media (max-width: 480px) {
  body.player-portal .h5-phone-preview-mask {
    padding: 12px 8px;
  }

  body.player-portal .h5-phone-device {
    --phone-w: 100%;
    border-radius: 28px;
    padding: 8px 8px 12px;
  }

  body.player-portal .h5-phone-frame {
    min-height: min(560px, calc(100vh - 140px));
  }
}

body.player-portal .docs-sub-external {
  flex-shrink: 0;
  font-size: 11px;
  opacity: 0.75;
}

body.player-portal .doc-h5-open-link {
  color: #0958d9;
  font-size: 13px;
  margin-left: 8px;
}

body.player-portal .docs-main {
  flex: 1;
  padding: 24px 28px 32px;
  max-height: calc(100vh - 200px);
  overflow-y: auto;
  background: var(--api-surface);
}

body.player-portal .doc-section h3,
body.player-portal .doc-h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--api-text);
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}

body.player-portal .doc-h4 {
  font-size: 15px;
  font-weight: 600;
  color: var(--api-text);
  margin: 28px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .doc-note,
body.player-portal .doc-notes-list,
body.player-portal .doc-steps-list,
body.player-portal .sdk-steps {
  color: var(--api-text-secondary);
  font-size: 14px;
  line-height: 1.75;
}

body.player-portal .docs-meta {
  background: var(--api-accent-soft);
  border: 1px solid rgba(0, 113, 227, 0.15);
  border-radius: var(--api-radius);
  padding: 16px 18px;
  margin-bottom: 20px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--api-text-secondary);
}

body.player-portal .docs-meta strong {
  color: var(--api-text);
}

/* 正文内联代码（浅色标签，与深色代码块区分） */
body.player-portal .docs-meta code,
body.player-portal .doc-note code,
body.player-portal .doc-steps-list code,
body.player-portal .doc-param-table code:not(.doc-field-name),
body.player-portal .doc-dict-table code:not(.doc-field-name),
body.player-portal td code:not(.doc-field-name):not(.doc-path):not(.doc-inline-api) {
  font-family: var(--api-mono);
  font-size: 12px;
  font-weight: 500;
  background: #f4f4f5;
  color: #c41a7f;
  padding: 2px 7px;
  border-radius: 5px;
  border: 1px solid #e4e4e7;
}

body.player-portal .doc-note code.doc-path,
body.player-portal code.doc-path {
  color: #047857;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

/* 接口卡片 */
body.player-portal .doc-api-pro {
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius-lg);
  margin-bottom: 28px;
  overflow: hidden;
  box-shadow: var(--api-shadow);
  background: var(--api-surface);
}

body.player-portal .doc-api-header {
  padding: 18px 22px 14px;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .doc-api-pro .doc-api-title {
  gap: 10px;
  align-items: center;
}

body.player-portal .doc-api-pro .doc-path,
body.player-portal code.doc-path {
  font-family: var(--api-mono);
  font-size: 12px;
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
  padding: 3px 8px;
  border-radius: 4px;
}

body.player-portal .doc-api-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--api-text);
}

body.player-portal .doc-endpoint-bar {
  padding: 12px 20px;
  background: var(--ide-bg);
  border-bottom: 1px solid var(--ide-border);
  gap: 12px;
}

body.player-portal .doc-endpoint-bar .method {
  font-family: var(--api-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 5px 10px;
  border-radius: 4px;
}

body.player-portal .doc-endpoint-bar .method-get {
  background: #3b82f6;
  color: #fff;
}
body.player-portal .doc-endpoint-bar .method-post {
  background: #22c55e;
  color: #fff;
}

body.player-portal .doc-full-url {
  font-family: var(--api-mono);
  font-size: 13px;
  color: var(--ide-key);
  line-height: 1.5;
}

body.player-portal .doc-panel-head {
  padding: 11px 20px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--api-text-secondary);
  background: var(--api-surface-2);
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .doc-panel-body {
  padding: 0;
}

body.player-portal .doc-panel-flush .code-editor {
  border-radius: 0;
  border-left: none;
  border-right: none;
}

body.player-portal .doc-panel-flush .code-editor-body pre {
  max-height: 440px;
  border-radius: 0;
}

/* —— IDE 代码编辑器外壳 —— */
body.player-portal .doc-block-code {
  margin-top: 14px;
  margin-bottom: 18px;
}

body.player-portal .doc-note-above-code {
  margin-bottom: 10px;
}

body.player-portal .code-editor {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--ide-border);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  background: var(--ide-bg);
}

body.player-portal .code-editor-chrome {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: var(--ide-chrome);
  border-bottom: 1px solid var(--ide-border);
  min-height: 36px;
}

body.player-portal .code-editor-traffic {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

body.player-portal .code-editor-traffic span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ff5f57;
}
body.player-portal .code-editor-traffic span:nth-child(2) {
  background: #febc2e;
}
body.player-portal .code-editor-traffic span:nth-child(3) {
  background: #28c840;
}

body.player-portal .code-editor-filename {
  flex: 1;
  font-family: var(--api-mono);
  font-size: 12px;
  color: var(--ide-text-dim);
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.player-portal .code-editor-lang-badge {
  font-family: var(--api-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ide-text-dim);
  background: rgba(255, 255, 255, 0.06);
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid var(--ide-border);
}

body.player-portal .code-editor-copy {
  flex-shrink: 0;
  font-size: 11px !important;
  padding: 4px 12px !important;
  background: rgba(255, 255, 255, 0.08) !important;
  color: #e8e8e8 !important;
  border-color: var(--ide-border) !important;
}
body.player-portal .code-editor-copy:hover {
  background: rgba(255, 255, 255, 0.14) !important;
}

body.player-portal .code-editor-body {
  background: var(--ide-bg);
}

body.player-portal pre.doc-code-block,
body.player-portal pre.doc-json,
body.player-portal pre.doc-code,
body.player-portal .docs pre.doc-json,
body.player-portal .docs pre.doc-code {
  margin: 0 !important;
  padding: 16px 18px !important;
  background: var(--ide-bg) !important;
  color: var(--ide-text) !important;
  border: none !important;
  border-radius: 0 !important;
  font-family: var(--api-mono) !important;
  font-size: 13px !important;
  font-weight: 400;
  line-height: 1.62 !important;
  letter-spacing: 0;
  tab-size: 2;
  -moz-tab-size: 2;
  max-height: 520px;
  overflow: auto;
  white-space: pre;
  -webkit-font-smoothing: antialiased;
}

body.player-portal pre.doc-code-block code {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
  background: transparent;
  padding: 0;
  border: none;
}

/* JSON 语法色 · Dark+ */
body.player-portal pre .json-key,
body.player-portal pre .tok-json-key {
  color: var(--ide-key);
}
body.player-portal pre .json-str,
body.player-portal pre .tok-json-str,
body.player-portal pre .tok-str {
  color: var(--ide-str);
}
body.player-portal pre .json-num,
body.player-portal pre .tok-json-num,
body.player-portal pre .tok-num {
  color: var(--ide-num);
}
body.player-portal pre .json-bool,
body.player-portal pre .tok-json-bool,
body.player-portal pre .json-null,
body.player-portal pre .tok-json-null {
  color: var(--ide-bool);
}
body.player-portal pre .tok-kw {
  color: var(--ide-kw);
}
body.player-portal pre .tok-comment {
  color: var(--ide-comment);
  font-style: italic;
}
body.player-portal pre .tok-flag {
  color: var(--ide-flag);
}
body.player-portal pre .tok-fn {
  color: var(--ide-fn);
}

body.player-portal .code-editor-body::-webkit-scrollbar,
body.player-portal pre.doc-code-block::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
body.player-portal .code-editor-body::-webkit-scrollbar-thumb,
body.player-portal pre.doc-code-block::-webkit-scrollbar-thumb {
  background: #424242;
  border-radius: 4px;
}
body.player-portal .code-editor-body::-webkit-scrollbar-track,
body.player-portal pre.doc-code-block::-webkit-scrollbar-track {
  background: var(--ide-bg);
}

/* 表格 */
body.player-portal .doc-param-table th,
body.player-portal .doc-dict-table th,
body.player-portal .doc-spec-table th,
body.player-portal .doc-tier-table th,
body.player-portal .doc-scenario-table th {
  background: #f1f5f9;
  color: var(--api-text-secondary);
  font-size: 12px;
  font-weight: 600;
  border-color: var(--api-border);
  padding: 10px 12px;
}

body.player-portal .doc-param-table td,
body.player-portal .doc-dict-table td,
body.player-portal .doc-spec-table td,
body.player-portal .doc-tier-table td,
body.player-portal .doc-scenario-table td {
  border-color: var(--api-border);
  padding: 10px 12px;
  font-size: 13px;
  color: var(--api-text);
}

body.player-portal .doc-field-name {
  font-family: var(--api-mono);
  color: #0d9488;
  background: #f0fdfa;
  border: 1px solid #99f6e4;
}

body.player-portal .doc-db-col {
  font-family: var(--api-mono);
  color: #6d28d9;
  background: #f5f3ff;
  border: 1px solid #ddd6fe;
}

body.player-portal .doc-type {
  font-family: var(--api-mono);
  color: #1d4ed8;
  font-size: 12px;
}

body.player-portal .doc-page-head {
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--api-border);
}

body.player-portal .doc-page-head .doc-note {
  margin-top: 8px;
}

body.player-portal .doc-frontend-url {
  font-family: var(--api-mono);
  font-size: 12px;
  color: var(--api-text-muted);
  background: var(--api-surface-2);
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px dashed var(--api-border-strong);
}

/* HTTP 方法色 */
body.player-portal .method-get,
body.player-portal .method-mini.method-get {
  background: #dbeafe;
  color: #1d4ed8;
}
body.player-portal .method-post,
body.player-portal .method-mini.method-post {
  background: #dcfce7;
  color: #15803d;
}
body.player-portal .method-put,
body.player-portal .method-mini.method-put {
  background: #ffedd5;
  color: #c2410c;
}
body.player-portal .method-delete,
body.player-portal .method-mini.method-delete {
  background: #fee2e2;
  color: #b91c1c;
}

body.player-portal .usage-required {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}
body.player-portal .usage-recommended {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}
body.player-portal .usage-optional {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}
body.player-portal .usage-reference {
  background: #faf5ff;
  color: #7e22ce;
  border: 1px solid #e9d5ff;
}

body.player-portal .doc-breadcrumb {
  font-size: 13px;
  color: var(--api-text-muted);
  margin-bottom: 16px;
}
body.player-portal .doc-breadcrumb a {
  font-weight: 500;
}

body.player-portal .btn-copy {
  font-size: 11px;
  padding: 5px 12px;
  border-radius: 6px;
  font-weight: 500;
}

body.player-portal .tag.ok {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #bbf7d0;
}

body.player-portal .msg.ok {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}
body.player-portal .msg.err {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

/* 关联说明 / 字段字典 / 页面对照 */
body.player-portal .assoc-faq dt,
body.player-portal .doc-dict-group-title {
  color: var(--api-text);
}

body.player-portal .fdict-endpoint {
  border-bottom-color: var(--api-border);
}

body.player-portal .doc-prize-panel .doc-panel-head {
  background: #fffbeb;
  color: #92400e;
  border-bottom-color: #fde68a;
}

/* 文档区块间距 */
body.player-portal .doc-section {
  margin-bottom: 40px;
  padding-bottom: 8px;
}
body.player-portal .doc-section.hidden {
  display: none !important;
}

body.player-portal .doc-req-yes {
  color: #b91c1c;
  font-weight: 600;
  font-size: 12px;
}
body.player-portal .doc-req-no {
  color: var(--api-text-muted);
  font-size: 12px;
}

body.player-portal .doc-default {
  color: var(--api-text-muted);
  font-size: 12px;
}

/* 关联说明 FAQ */
body.player-portal .assoc-faq {
  margin: 16px 0;
}
body.player-portal .assoc-faq dt {
  font-weight: 600;
  font-size: 14px;
  margin-top: 16px;
  padding: 10px 14px;
  background: var(--api-surface-2);
  border-radius: var(--api-radius);
  border: 1px solid var(--api-border);
}
body.player-portal .assoc-faq dd {
  margin: 8px 0 0;
  padding: 0 4px 0 14px;
  color: var(--api-text-secondary);
  line-height: 1.75;
}

/* SDK 语言区块 */
body.player-portal .sdk-section h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--api-text);
  margin: 20px 0 10px;
}

/* 滚动条（WebKit） */
body.player-portal .docs-subnav::-webkit-scrollbar,
body.player-portal .docs-main::-webkit-scrollbar {
  width: 6px;
}
body.player-portal .docs-subnav::-webkit-scrollbar-thumb,
body.player-portal .docs-main::-webkit-scrollbar-thumb {
  background: var(--api-border-strong);
  border-radius: 3px;
}

/* API 密钥 · 显示/隐藏与复制 */
body.player-portal .key-cell {
  min-width: 280px;
}

body.player-portal .key-secret-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

body.player-portal .key-value {
  font-family: var(--api-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--api-text);
  background: #f4f4f5;
  border: 1px solid var(--api-border-strong);
  border-radius: 8px;
  padding: 6px 10px;
  word-break: break-all;
  flex: 1 1 180px;
  min-width: 0;
}

body.player-portal .key-secret-actions {
  display: flex;
  flex-shrink: 0;
  gap: 6px;
}

body.player-portal .btn-key-toggle,
body.player-portal .btn-key-copy {
  font-size: 12px !important;
  padding: 6px 12px !important;
  border-radius: 8px !important;
}

body.player-portal .btn-key-copy:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

body.player-portal .key-copy-modal .modal-key-copy {
  max-width: 520px;
  width: 92%;
}

body.player-portal .key-copy-modal .modal-body {
  padding: 8px 24px 4px;
}

body.player-portal .key-copy-modal .key-copy-success {
  margin: 0 0 10px;
  padding: 10px 14px;
  border-radius: 8px;
  background: #ecfdf5;
  color: #15803d;
  font-size: 15px;
  font-weight: 600;
  text-align: center;
  border: 1px solid #bbf7d0;
}

body.player-portal .key-copy-modal .key-copy-hint {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--api-text-secondary);
}

body.player-portal .key-copy-modal .key-copy-preview {
  margin: 0;
  padding: 12px 14px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid var(--api-border);
  font-family: var(--api-mono);
  font-size: 13px;
  line-height: 1.5;
  word-break: break-all;
  white-space: pre-wrap;
  max-height: 200px;
  overflow: auto;
  color: var(--api-text);
}

body.player-portal .key-copy-modal .modal-actions {
  padding-bottom: 16px;
}

body.player-portal #keysTable th:nth-child(2),
body.player-portal #keysTable td.key-cell {
  width: 38%;
}

/* 代码示例 · 接口地址说明（始终置顶） */
body.player-portal .sdk-endpoint-panel {
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .sdk-endpoint-title {
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 600;
  color: var(--api-text);
  letter-spacing: -0.02em;
}

body.player-portal .sdk-endpoint-intro {
  margin-bottom: 12px;
}

body.player-portal .sdk-endpoint-meta {
  margin-bottom: 16px;
}

body.player-portal .sdk-base-url {
  font-family: var(--api-mono);
  font-size: 13px;
  font-weight: 600;
  color: #047857;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 2px 8px;
  border-radius: 6px;
}

body.player-portal .sdk-endpoint-table-wrap {
  overflow-x: auto;
  margin-bottom: 12px;
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius-lg);
  background: var(--api-surface);
}

body.player-portal .sdk-endpoint-table {
  margin: 0;
  width: 100%;
  min-width: 640px;
}

body.player-portal .sdk-endpoint-table .sdk-full-url {
  font-family: var(--api-mono);
  font-size: 12px;
  color: #1d4ed8;
  word-break: break-all;
  white-space: normal;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  padding: 4px 8px;
  border-radius: 6px;
  display: inline-block;
  max-width: 100%;
}

body.player-portal .sdk-auth-req {
  font-size: 12px;
  font-weight: 600;
  color: #b45309;
}

body.player-portal .sdk-auth-none {
  font-size: 12px;
  font-weight: 600;
  color: #15803d;
}

body.player-portal .sdk-endpoint-footer {
  margin-bottom: 0;
}

body.player-portal .sdk-endpoint-footer a {
  font-weight: 500;
}

/* 侧栏未读角标 */
body.player-portal .nav-item {
  position: relative;
}
body.player-portal .nav-badge {
  margin-left: auto;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  border-radius: 10px;
  background: #ff3b30;
  color: #fff;
  flex-shrink: 0;
}
body.player-portal .nav-badge.hidden {
  display: none;
}

/* 控制台页头（账户/支持类页面） */
body.player-portal .console-page-header {
  margin-bottom: 16px;
}

body.player-portal .console-page-header .docs-page-title {
  margin: 0 0 6px;
}

body.player-portal .console-page-header .docs-page-sub {
  margin: 0;
}

/* —— 联系方式页 · 名片排版 —— */
body.player-portal .contact-page-wrap {
  max-width: 520px;
}

body.player-portal .contact-business-shell {
  padding: 0;
  overflow: hidden;
  border-radius: var(--api-radius-lg);
  box-shadow: var(--api-shadow-md);
}

body.player-portal .contact-bc-head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 22px 22px 18px;
  background: linear-gradient(145deg, rgba(0, 113, 227, 0.08) 0%, rgba(90, 200, 250, 0.06) 100%);
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .contact-bc-head-mark {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--api-border);
  box-shadow: 0 2px 10px rgba(0, 113, 227, 0.12);
}

body.player-portal .contact-bc-head-mark svg,
body.player-portal .contact-bc-head-icon {
  width: 32px;
  height: 32px;
  object-fit: contain;
  display: block;
}

body.player-portal .contact-bc-head-text {
  flex: 1;
  min-width: 0;
}

body.player-portal .contact-page-card-title {
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 700;
  color: var(--api-text);
  letter-spacing: -0.02em;
}

body.player-portal .contact-page-intro {
  margin: 0;
  color: var(--api-text-secondary);
  font-size: 13px;
  line-height: 1.55;
}

body.player-portal .contact-bc-body-mount {
  padding: 16px 18px 8px;
}

body.player-portal .contact-page-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin: 0;
  padding: 14px 18px 16px;
  border-top: 1px solid var(--api-border);
  font-size: 12px;
  color: var(--api-text-muted);
  background: var(--api-surface-2);
}

body.player-portal .contact-sync-hint {
  color: var(--api-text-muted);
}

body.player-portal .contact-page-foot a {
  color: var(--api-accent);
  font-weight: 600;
  font-size: 13px;
}

/* 名片渠道行 */
body.player-portal .contact-card-view.contact-business {
  padding: 0;
}

body.player-portal .contact-card-view.contact-business .contact-channels {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

body.player-portal .contact-card-view.contact-business .contact-channel {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  margin: 0;
  background: var(--api-surface);
  border: 1px solid var(--api-border);
  border-radius: 12px;
  flex-wrap: nowrap;
}

body.player-portal .contact-card-view.contact-business .contact-channel.contact-copyable {
  cursor: pointer;
}

body.player-portal .contact-card-view.contact-business .contact-channel.contact-copyable:hover {
  border-color: var(--api-accent);
  box-shadow: 0 4px 16px rgba(0, 113, 227, 0.1);
  transform: translateY(-1px);
}

body.player-portal .contact-card-view.contact-business .contact-channel.is-copied {
  border-color: #34c759;
  background: rgba(52, 199, 89, 0.06);
}

body.player-portal .contact-card-view.contact-business .contact-ch-icon-wrap {
  width: 44px;
  height: 44px;
  background: #fff;
  border: 1px solid var(--api-border);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

body.player-portal .contact-card-view.contact-business .contact-ch-icon {
  width: 36px;
  height: 36px;
}

body.player-portal .contact-card-view.contact-business .contact-bc-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

body.player-portal .contact-card-view.contact-business .contact-bc-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--api-text-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

body.player-portal .contact-card-view.contact-business .contact-bc-value {
  font-family: var(--api-mono);
  font-size: 14px;
  font-weight: 500;
  color: var(--api-text);
  word-break: break-all;
  line-height: 1.35;
}

body.player-portal .contact-card-view.contact-business .contact-ch-copy-hint {
  flex-shrink: 0;
  font-size: 11px;
  color: var(--api-text-muted);
  padding: 4px 8px;
  border-radius: 6px;
  background: var(--api-surface-2);
}

body.player-portal .contact-card-view.contact-business .contact-channel:hover .contact-ch-copy-hint {
  color: var(--api-accent);
  background: var(--api-accent-soft);
}

body.player-portal .contact-card-view.contact-business .contact-qr {
  flex-basis: 100%;
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px dashed var(--api-border);
  text-align: center;
}

body.player-portal .contact-card-view.contact-business .contact-qr img {
  max-height: 100px;
  border-radius: 8px;
}

body.player-portal .contact-card-view.contact-business .contact-channel:has(.contact-qr) {
  flex-wrap: wrap;
}

body.player-portal .contact-card-view.contact-business .contact-empty {
  text-align: center;
  padding: 24px 12px;
  font-size: 13px;
}

/* 联系方式名片 */
body.player-portal .contact-card-view {
  padding: 4px 0;
}

body.player-portal .contact-card-view.console .contact-channels {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}

body.player-portal .contact-card-view.console .contact-channel {
  flex-direction: column;
  align-items: flex-start;
  height: 100%;
}

body.player-portal .contact-card-view.console .contact-ch-value {
  flex: 1;
}

body.player-portal .contact-card-view.console .contact-qr {
  margin-top: auto;
  width: 100%;
  text-align: center;
}

body.player-portal .contact-card-view.console .contact-qr img {
  max-height: 120px;
}
body.player-portal .contact-card-title {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--api-text);
}
body.player-portal .contact-card-intro {
  margin: 0 0 16px;
  color: var(--api-text-secondary);
  font-size: 14px;
  line-height: 1.55;
}
body.player-portal .contact-channels {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
body.player-portal .contact-channel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  padding: 12px 14px;
  background: var(--api-surface-2);
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
body.player-portal .contact-channel.contact-copyable:hover {
  border-color: var(--api-accent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--api-accent) 18%, transparent);
}
body.player-portal .contact-ch-label {
  font-weight: 600;
  color: var(--api-accent);
  min-width: 4em;
}
body.player-portal .contact-ch-value {
  font-family: var(--api-mono);
  font-size: 14px;
  color: var(--api-text);
  word-break: break-all;
}
body.player-portal .contact-qr img {
  max-height: 96px;
  border-radius: 8px;
  border: 1px solid var(--api-border);
}
body.player-portal .contact-empty {
  color: var(--api-text-muted);
  margin: 0;
}

body.player-portal .ticket-card-player {
  margin-bottom: 12px;
}
body.player-portal .ticket-reply-box {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--api-border);
}
body.player-portal .ticket-reply-box label {
  display: block;
  font-size: 12px;
  color: var(--api-text-muted);
  margin-bottom: 6px;
}
body.player-portal .ticket-reply-box pre {
  margin: 0;
  padding: 10px 12px;
  background: #ecfdf5;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  font-size: 13px;
  white-space: pre-wrap;
  word-break: break-word;
}
body.player-portal .tag.warn {
  background: #fff7e6;
  color: #d46b08;
}

/* 钱包 */
body.player-portal .wallet-card,
body.player-portal .profile-wallet-card.wallet-card {
  background: linear-gradient(135deg, #eff6ff 0%, #f0fdf4 100%);
  border: 1px solid #bfdbfe;
}
body.player-portal .wallet-balance-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
body.player-portal .wallet-label {
  margin: 0 0 4px;
  font-size: 13px;
  color: var(--api-text-secondary);
}
body.player-portal .wallet-balance {
  margin: 0;
  font-size: 32px;
  font-weight: 700;
  color: #047857;
  letter-spacing: -0.02em;
}
body.player-portal .wallet-ledger-table .amt-plus {
  color: #15803d;
  font-weight: 600;
}
body.player-portal .wallet-ledger-table .amt-minus {
  color: #dc2626;
  font-weight: 600;
}
/* —— 钱包充值弹窗 —— */
body.player-portal .wallet-recharge-modal {
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

body.player-portal .wallet-recharge-modal .modal-recharge {
  max-width: 440px;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid var(--api-border);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
}

body.player-portal .recharge-modal-hero {
  position: relative;
  padding: 22px 24px 20px;
  background: linear-gradient(135deg, #0071e3 0%, #5ac8fa 55%, #34c759 120%);
  color: #fff;
  overflow: hidden;
}

body.player-portal .recharge-hero-glow {
  position: absolute;
  inset: -40% -20% auto auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  filter: blur(40px);
  pointer-events: none;
}

body.player-portal .recharge-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(0, 0, 0, 0.12);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

body.player-portal .recharge-modal-close:hover {
  background: rgba(0, 0, 0, 0.2);
}

body.player-portal .recharge-hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
  padding-right: 28px;
}

body.player-portal .recharge-site-logo {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.95);
  padding: 4px;
  flex-shrink: 0;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

body.player-portal .recharge-site-logo.hidden {
  display: none;
}

body.player-portal .recharge-hero-text h3 {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
}

body.player-portal .recharge-hero-sub {
  margin: 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.88);
}

body.player-portal .recharge-modal-body {
  padding: 20px 22px 8px;
  background: var(--api-surface);
}

body.player-portal .recharge-field {
  margin-bottom: 18px;
}

body.player-portal .recharge-field-label {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--api-text-secondary);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

body.player-portal .recharge-amount-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 14px;
  border: 1px solid var(--api-border-strong);
  border-radius: 12px;
  background: var(--api-surface-2);
  transition: border-color 0.15s, box-shadow 0.15s;
}

body.player-portal .recharge-amount-wrap:focus-within {
  border-color: var(--api-accent);
  box-shadow: 0 0 0 3px var(--api-accent-soft);
}

body.player-portal .recharge-amount-prefix {
  font-size: 22px;
  font-weight: 600;
  color: var(--api-text-muted);
}

body.player-portal .recharge-amount-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 28px;
  font-weight: 700;
  color: var(--api-text);
  padding: 10px 0;
  min-width: 0;
  letter-spacing: -0.02em;
}

body.player-portal .recharge-amount-input:focus {
  outline: none;
}

body.player-portal .recharge-limits {
  margin: 8px 0 0;
  font-size: 12px;
  color: var(--api-text-muted);
}

body.player-portal .recharge-channel-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

body.player-portal .recharge-channel-option {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--api-border);
  border-radius: 12px;
  background: var(--api-surface-2);
  cursor: pointer;
  text-align: left;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}

body.player-portal .recharge-channel-option:hover {
  border-color: var(--api-accent);
  background: #fff;
}

body.player-portal .recharge-channel-option.active {
  border-color: var(--api-accent);
  background: var(--api-accent-soft);
  box-shadow: 0 0 0 1px rgba(0, 113, 227, 0.15);
}

body.player-portal .recharge-channel-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

body.player-portal .recharge-channel-icon-wrap img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

body.player-portal .recharge-channel-name {
  flex: 1;
  font-size: 15px;
  font-weight: 600;
  color: var(--api-text);
}

body.player-portal .recharge-channel-check {
  color: var(--api-accent);
  opacity: 0;
  transform: scale(0.85);
  transition: opacity 0.15s, transform 0.15s;
}

body.player-portal .recharge-channel-option.active .recharge-channel-check {
  opacity: 1;
  transform: scale(1);
}

body.player-portal .recharge-channel-empty {
  margin: 0;
  padding: 16px;
  text-align: center;
  font-size: 13px;
  color: var(--api-text-muted);
  background: var(--api-surface-2);
  border-radius: 10px;
}

body.player-portal .recharge-channel-select-native {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

body.player-portal .recharge-modal-actions {
  padding: 12px 22px 20px;
  gap: 10px;
  background: var(--api-surface);
  border-top: 1px solid var(--api-border);
}

body.player-portal .recharge-pay-btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  font-size: 15px;
  font-weight: 600;
  background: linear-gradient(180deg, #0077ed 0%, #0071e3 100%);
  box-shadow: 0 4px 14px rgba(0, 113, 227, 0.35);
}

body.player-portal .recharge-pay-btn:hover {
  background: linear-gradient(180deg, #0084ff 0%, #0077ed 100%);
}

body.player-portal .recharge-pay-icon {
  width: 22px;
  height: 22px;
  object-fit: contain;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.95);
  padding: 2px;
}

/* —— 白名单添加弹窗 —— */
body.player-portal .whitelist-page-head-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

body.player-portal .whitelist-page-head-row .btn {
  flex-shrink: 0;
  margin-top: 4px;
}

body.player-portal .whitelist-add-modal {
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

body.player-portal .whitelist-add-modal .modal-whitelist {
  max-width: 440px;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid var(--api-border);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.18);
}

body.player-portal .whitelist-modal-hero {
  position: relative;
  padding: 20px 22px 18px;
  background: linear-gradient(135deg, #5856d6 0%, #0071e3 55%, #5ac8fa 110%);
  color: #fff;
  overflow: hidden;
}

body.player-portal .whitelist-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(0, 0, 0, 0.12);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

body.player-portal .whitelist-hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
  padding-right: 28px;
}

body.player-portal .whitelist-hero-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
}

body.player-portal .whitelist-hero-icon svg {
  width: 24px;
  height: 24px;
}

body.player-portal .whitelist-modal-hero h3 {
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 700;
  color: #fff;
}

body.player-portal .whitelist-hero-sub {
  margin: 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.45;
}

body.player-portal .whitelist-modal-body {
  padding: 20px 22px 8px;
  background: var(--api-surface);
}

body.player-portal .whitelist-modal-body .form-row label {
  font-size: 12px;
  font-weight: 600;
  color: var(--api-text-secondary);
}

body.player-portal .whitelist-modal-body .form-row input {
  max-width: none;
  width: 100%;
}

body.player-portal .whitelist-modal-body .form-hint {
  margin: 6px 0 0;
  font-size: 11px;
  color: var(--api-text-muted);
  line-height: 1.45;
}

body.player-portal .whitelist-modal-actions {
  padding: 12px 22px 20px;
  gap: 10px;
  background: var(--api-surface);
  border-top: 1px solid var(--api-border);
}

body.player-portal .pay-icon-preview {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid #e8e8e8;
  background: #fff;
}
body.player-portal .payment-channel-card {
  margin-top: 12px;
  border: 1px dashed #e8e8e8;
}

/* ═══════════════════════════════════════════════════════════════
   玩家控制台 · 全局布局精修（各页统一间距与层次）
   ═══════════════════════════════════════════════════════════════ */

/* 标准内容页：卡片居中、宽度一致 */
body.player-portal .player-content > .card:not(.docs-page):not(.contact-page-wrap) {
  width: 100%;
  max-width: var(--api-content-max);
  margin-left: auto;
  margin-right: auto;
}

body.player-portal .player-content > .contact-page-wrap {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

body.player-portal .profile-page {
  max-width: var(--api-content-max);
  margin-left: auto;
  margin-right: auto;
}

/* 文档 / SDK / 代码示例：全宽双栏 */
body.player-portal .player-content > .card.docs-page {
  max-width: none;
  width: 100%;
  margin: 0;
}

body.player-portal .docs-page > .docs-page-title {
  padding: var(--api-space-md) var(--api-space-md) 0;
  margin: 0 0 var(--api-space-xs);
  border: none;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.2;
}

body.player-portal .docs-page > .docs-page-sub {
  padding: 0 var(--api-space-md);
  margin: 0 0 var(--api-space-md);
  font-size: 14px;
  color: var(--api-text-secondary);
  line-height: 1.6;
  max-width: 72ch;
}

body.player-portal .player-page-desc {
  color: var(--api-text-muted);
  font-size: 13px;
  line-height: 1.6;
}

body.player-portal .docs-page > .docs-layout {
  margin: 0;
  min-height: calc(100vh - var(--api-topbar-h) - 168px);
  border-radius: var(--api-radius-lg);
}

body.player-portal .docs-subnav {
  padding: var(--api-space-sm) var(--api-space-xs);
  max-height: calc(100vh - var(--api-topbar-h) - 168px);
}

body.player-portal .docs-main {
  padding: var(--api-space-md) var(--api-space-md) var(--api-space-xl);
  max-height: calc(100vh - var(--api-topbar-h) - 168px);
}

/* SDK 代码示例页 */
body.player-portal .sdk-endpoint-panel {
  margin: 0 0 var(--api-space-md);
  padding: var(--api-space-md);
  background: linear-gradient(145deg, rgba(0, 113, 227, 0.06) 0%, rgba(90, 200, 250, 0.04) 100%);
  border: 1px solid rgba(0, 113, 227, 0.12);
  border-radius: var(--api-radius-lg);
  border-bottom: 1px solid rgba(0, 113, 227, 0.12);
}

body.player-portal .sdk-section:not(.hidden) {
  margin-bottom: var(--api-space-lg);
  padding-bottom: var(--api-space-lg);
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .sdk-section:not(.hidden):last-of-type {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

body.player-portal .sdk-section h3,
body.player-portal .sdk-section .doc-h3 {
  margin-top: 0;
  padding-top: 4px;
}

body.player-portal .sdk-steps {
  margin: 12px 0 20px;
  padding-left: 1.35em;
}

body.player-portal .sdk-steps li {
  margin-bottom: 8px;
}

body.player-portal .sdk-sub-link {
  font-size: 13px;
  font-weight: 500;
}

/* 全局表格 */
body.player-portal .card table:not(.sdk-endpoint-table) {
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius);
  overflow: hidden;
  background: var(--api-surface);
}

body.player-portal .card table:not(.sdk-endpoint-table) tbody tr:hover {
  background: var(--api-surface-2);
}

/* 表单与按钮间距 */
body.player-portal .card .form-row:last-child {
  margin-bottom: 0;
}

body.player-portal .card > .btn {
  margin-top: 4px;
}

body.player-portal .card > .btn + .btn {
  margin-left: 10px;
}

body.player-portal .form-hint {
  margin: 8px 0 0;
  font-size: 12px;
  line-height: 1.55;
  color: var(--api-text-muted);
}

/* 侧栏导航间距 */
body.player-portal .nav-item.active {
  box-shadow: inset 3px 0 0 var(--api-accent);
}

body.player-portal .foot-logout {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  margin: 0 -6px;
  border-radius: var(--api-radius);
  color: var(--api-text-secondary);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

body.player-portal .foot-logout:hover {
  background: var(--api-sidebar-hover);
  color: var(--api-accent);
  text-decoration: none;
}

body.player-portal .foot-logout .nav-icon {
  width: 24px;
  height: 24px;
}

/* 工单等独立标题页 */
body.player-portal .card > .docs-page-title:first-child {
  padding: 0;
  margin: 0 0 var(--api-space-xs);
  font-size: 20px;
  border: none;
}

body.player-portal .card > .docs-page-sub.player-page-desc {
  padding: 0;
  margin: 0 0 var(--api-space-md);
}

@media (max-width: 960px) {
  body.player-portal .player-content {
    padding: var(--api-space-sm);
  }

  body.player-portal .docs-layout {
    flex-direction: column;
    min-height: auto;
  }

  body.player-portal .docs-subnav {
    width: 100%;
    max-height: 220px;
    border-right: none;
    border-bottom: 1px solid var(--api-border);
  }

  body.player-portal .docs-main {
    max-height: none;
  }

  body.player-portal .docs-layout.has-h5-preview .docs-content {
    flex-direction: column;
  }

  body.player-portal .docs-h5-preview {
    width: 100%;
    min-width: 0;
    max-height: 60vh;
  }

  body.player-portal .docs-layout.has-h5-preview .docs-main {
    border-right: none;
    border-bottom: 1px solid var(--api-border);
  }

  body.player-portal .docs-h5-spotlight {
    --docs-phone-h: clamp(480px, calc(100vh - 220px), 720px);
    margin-left: var(--api-space-sm);
    margin-right: var(--api-space-sm);
    width: calc(100% - 2 * var(--api-space-sm));
  }

  body.player-portal .docs-h5-spotlight-grid {
    grid-template-columns: repeat(3, minmax(220px, 1fr));
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    justify-items: stretch;
    padding: 16px 12px 24px;
  }

  body.player-portal .docs-h5-phone-window {
    max-width: none;
    min-width: 220px;
  }
}

@media (max-width: 720px) {
  body.player-portal .docs-h5-spotlight {
    --docs-phone-h: min(72vh, 640px);
  }

  body.player-portal .docs-h5-spotlight-grid {
    grid-template-columns: 1fr;
    justify-items: center;
    overflow-x: visible;
  }

  body.player-portal .docs-h5-phone-window {
    max-width: min(100%, 400px);
    min-width: 0;
  }
}

/* ═══════════════════════════════════════════════════════════════
   个人资料页 · 整齐布局（profile-page）
   ═══════════════════════════════════════════════════════════════ */
body.player-portal .profile-page {
  max-width: 1040px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

body.player-portal .profile-page-header {
  margin: 0 0 4px;
}

body.player-portal .profile-page-title {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--api-text);
  line-height: 1.25;
}

body.player-portal .profile-page .profile-page-lead {
  margin: 0;
  font-size: 14px;
  color: var(--api-text-secondary);
  line-height: 1.55;
}

body.player-portal .profile-summary-row {
  display: grid;
  grid-template-columns: 1fr minmax(268px, 300px);
  gap: 16px;
  align-items: stretch;
}

body.player-portal .profile-page .profile-panel {
  padding: 20px 22px;
  margin-bottom: 0;
  border-radius: var(--api-radius-lg);
  box-shadow: var(--api-shadow-md);
  background: var(--api-surface);
}

body.player-portal .profile-panel-title {
  margin: 0 0 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--api-border);
  font-size: 15px;
  font-weight: 700;
  color: var(--api-text);
  letter-spacing: -0.01em;
}

body.player-portal .profile-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: -4px 0 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .profile-panel-head .profile-panel-title {
  margin: 0;
  padding: 0;
  border: none;
}

body.player-portal .profile-page .profile-identity {
  margin-bottom: 18px;
  padding-bottom: 18px;
}

body.player-portal .profile-page .profile-avatar {
  width: 56px;
  height: 56px;
}

body.player-portal .profile-page .profile-display-name {
  font-size: 17px;
}

body.player-portal .profile-page .profile-username {
  font-family: var(--api-mono);
  font-size: 13px;
  color: var(--api-text-secondary);
}

body.player-portal .profile-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 18px;
  margin: 0;
}

body.player-portal .profile-stat-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

body.player-portal .profile-stat-grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

body.player-portal .profile-balance-stat dd {
  font-size: 16px;
  font-weight: 700;
  color: var(--api-accent);
  font-variant-numeric: tabular-nums;
}

body.player-portal .profile-stat-grid .profile-meta-item dt {
  font-size: 12px;
  font-weight: 600;
  color: var(--api-text-muted);
  margin-bottom: 4px;
}

body.player-portal .profile-stat-grid .profile-meta-item dd {
  font-size: 14px;
  font-weight: 500;
  color: var(--api-text);
  line-height: 1.4;
}

body.player-portal .profile-login-meta {
  grid-template-columns: 1fr;
  gap: 10px;
}

body.player-portal .profile-login-meta .profile-meta-item dd {
  font-family: var(--api-mono);
  font-size: 13px;
}

/* 钱包卡片 */
body.player-portal .profile-wallet-card {
  background: linear-gradient(155deg, #0066cc 0%, #0071e3 42%, #5ac8fa 100%);
  border: none;
  color: #fff;
}

body.player-portal .profile-wallet-card .profile-panel-title {
  color: rgba(255, 255, 255, 0.92);
  border-bottom-color: rgba(255, 255, 255, 0.22);
}

body.player-portal .profile-wallet-inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

body.player-portal .profile-wallet-label {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.88);
}

body.player-portal .profile-wallet-amount {
  margin: 6px 0 16px;
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: #fff;
}

body.player-portal .profile-wallet-btn {
  width: 100%;
  margin: 0;
  padding: 11px 16px;
  border-radius: 10px;
  background: #fff;
  color: #0071e3;
  font-size: 15px;
  font-weight: 600;
  border: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

body.player-portal .profile-wallet-btn:hover {
  background: #f0f9ff;
  color: #005bb5;
}

body.player-portal .profile-wallet-card .profile-wallet-hint {
  margin: 14px 0 0;
  font-size: 12px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.78);
}

/* 登录信息 */
body.player-portal .profile-page .profile-login-card {
  margin: 0;
}

body.player-portal .profile-page .profile-login-columns {
  gap: 16px;
}

body.player-portal .profile-page .profile-login-block {
  padding: 16px 18px;
  border-radius: var(--api-radius);
  background: var(--api-surface-2);
}

body.player-portal .profile-login-subtitle {
  font-size: 12px;
  margin-bottom: 12px;
}

/* 可编辑资料 */
body.player-portal .profile-edit-card .profile-form-grid {
  gap: 16px 20px;
}

body.player-portal .profile-edit-card .form-row label {
  font-size: 13px;
  font-weight: 600;
  color: var(--api-text-secondary);
  margin-bottom: 6px;
}

body.player-portal .profile-edit-card .form-row input,
body.player-portal .profile-edit-card .form-row textarea {
  width: 100%;
  max-width: none;
  padding: 10px 12px;
  font-size: 14px;
  border-radius: var(--api-radius-sm, var(--api-radius));
}

body.player-portal .profile-edit-card .msg {
  margin-bottom: 12px;
}

/* 资金记录 */
body.player-portal .profile-records-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

body.player-portal .profile-block-label {
  margin: 4px 0 0;
  padding: 0 2px;
  font-size: 12px;
  font-weight: 700;
  color: var(--api-text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body.player-portal .profile-page .profile-records-grid {
  gap: 16px;
}

body.player-portal .profile-table-card .profile-panel-title {
  margin-bottom: 12px;
}

body.player-portal .profile-table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--api-border);
  border-radius: var(--api-radius);
  background: var(--api-surface);
}

body.player-portal .profile-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 300px;
}

body.player-portal .profile-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f8fafc;
  font-size: 12px;
  font-weight: 600;
  color: var(--api-text-secondary);
  padding: 11px 12px;
  text-align: left;
  white-space: nowrap;
  border-bottom: 1px solid var(--api-border);
}

body.player-portal .profile-table td {
  padding: 11px 12px;
  vertical-align: middle;
  border-bottom: 1px solid var(--api-border);
  color: var(--api-text);
}

body.player-portal .profile-table tbody tr:last-child td {
  border-bottom: none;
}

body.player-portal .profile-table tbody tr:hover td {
  background: var(--api-surface-2);
}

body.player-portal .profile-table .table-empty {
  text-align: center;
  color: var(--api-text-muted);
  padding: 24px 12px;
}

body.player-portal .profile-table .time-cell {
  white-space: nowrap;
  font-size: 12px;
  color: var(--api-text-secondary);
}

body.player-portal .profile-table .mono-cell {
  font-family: var(--api-mono);
  font-size: 12px;
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.player-portal .profile-table .num-cell {
  font-family: var(--api-mono);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  white-space: nowrap;
}

body.player-portal .profile-table .remark-cell {
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--api-text-secondary);
  font-size: 12px;
}

@media (max-width: 900px) {
  body.player-portal .profile-summary-row,
  body.player-portal .profile-page .profile-records-grid,
  body.player-portal .profile-page .profile-login-columns {
    grid-template-columns: 1fr;
  }

  body.player-portal .profile-stat-grid--3,
  body.player-portal .profile-stat-grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  body.player-portal .profile-stat-grid--3,
  body.player-portal .profile-stat-grid--4,
  body.player-portal .profile-form-grid {
    grid-template-columns: 1fr;
  }

  body.player-portal .profile-wallet-amount {
    font-size: 28px;
  }
}
