/* === 登录页：与落地页一致的深紫黑极简风格 === */

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  position: relative;
  overflow: hidden;
  padding: 24px;
}

/* 背景光晕 — 与落地页 Hero 一致 */
.login-page::before {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(13, 2, 33, 0.06) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.4;
  top: -10%;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
  animation: loginGlowPulse 8s ease-in-out infinite;
}

.login-page::after {
  content: '';
  position: absolute;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(85, 85, 85, 0.04) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.4;
  bottom: 10%;
  right: 10%;
  pointer-events: none;
  animation: loginGlowPulse 6s ease-in-out infinite reverse;
}

@keyframes loginGlowPulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.6; }
}

.login-card {
  width: 100%;
  max-width: 420px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-radius: var(--radius-xl);
  padding: 48px 36px;
  border: 1px solid rgba(0, 0, 0, 0.04);
  box-shadow: 0 8px 40px rgba(13, 2, 33, 0.08), 0 1px 3px rgba(0, 0, 0, 0.04);
  animation: loginFadeIn 0.6s cubic-bezier(0.25, 1, 0.5, 1);
  position: relative;
  z-index: 1;
}

@keyframes loginFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Logo */
.login-logo {
  text-align: center;
  margin-bottom: 32px;
}

.login-logo-img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  object-fit: cover;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px rgba(13, 2, 33, 0.15);
}

.login-logo h1 {
  font-size: 22px;
  font-weight: 800;
  color: #1a1a1a;
  letter-spacing: -0.02em;
}

.login-logo p {
  font-size: 13px;
  color: #666;
  margin-top: 4px;
}

/* 登录方式切换 */
.login-type-tabs {
  display: flex;
  margin-bottom: 24px;
  background: #f5f5f5;
  border-radius: 10px;
  padding: 4px;
}

.login-type-tab {
  flex: 1;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 500;
  color: #666;
  border: none;
  background: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

.login-type-tab.active {
  background: #fff;
  color: #1a1a1a;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* 表单 */
.login-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.login-input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.login-input-group label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
}

/* 通用输入框（Login 专用，不依赖全局 .input） */
.login-field {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #e8e8e8;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-family: var(--font-sans);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
  box-sizing: border-box;
}

.login-field:focus {
  border-color: #1a0a2e;
  box-shadow: 0 0 0 3px rgba(13, 2, 33, 0.08);
}

.login-field::placeholder {
  color: #999;
}

/* 验证码行：输入框占满剩余空间，按钮固定紧凑 */
.login-code-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.login-code-input {
  flex: 1 1 auto;
  min-width: 0;
}

/* 验证码按钮：独立样式，优先级最高 */
.login-send-code-btn {
  flex: 0 0 auto;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #1a0a2e;
  background: rgba(13, 2, 33, 0.06);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
  font-family: inherit;
  min-width: 84px;
}

.login-send-code-btn:hover:not(:disabled) {
  background: rgba(13, 2, 33, 0.1);
}

.login-send-code-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* 登录按钮：与落地页 btn-primary 一致 */
.login-action-btn {
  width: 100%;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  background: #1a0a2e;
  border: none;
  border-radius: 980px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
  box-shadow: 0 4px 20px rgba(13, 2, 33, 0.15);
  transition: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
  font-family: inherit;
}

.login-action-btn:hover:not(:disabled) {
  background: #0d0221;
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(13, 2, 33, 0.2);
}

.login-action-btn:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: 0 4px 20px rgba(13, 2, 33, 0.15);
}

.login-action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* 错误信息 */
.login-error {
  color: #ef4444;
  font-size: 13px;
  text-align: center;
  min-height: 20px;
}

/* 底部 */
.login-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 12px;
  color: #999;
}

.login-footer a {
  color: #1a0a2e;
  text-decoration: none;
  font-weight: 500;
}

.login-footer a:hover {
  text-decoration: underline;
}

/* === 移动端适配 === */
@media (max-width: 480px) {
  .login-card {
    padding: 32px 20px;
    border-radius: var(--radius-lg);
  }

  .login-logo-img {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
  }

  .login-logo h1 {
    font-size: 20px;
  }

  .login-logo p {
    font-size: 12px;
  }

  .login-code-row {
    gap: 8px;
  }

  .login-send-code-btn {
    padding: 10px 10px;
    font-size: 12px;
    min-width: 80px;
  }

  .login-action-btn {
    padding: 14px 24px;
    font-size: 16px;
  }
}
/* ============================================
   Modal 式新用户引导 - WelcomeGuide
   ============================================ */

.wg-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: wg-fade-in 0.25s ease;
}

@keyframes wg-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.wg-modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: #fff;
  border-radius: 20px;
  padding: 32px 28px 24px;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.18),
    0 0 0 1px rgba(0, 0, 0, 0.04);
  text-align: center;
  animation: wg-modal-in 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html[data-theme="dark"] .wg-overlay {
  background: rgba(0, 0, 0, 0.6);
}

html[data-theme="dark"] .wg-modal {
  background: #1e1e2e;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.06);
}

/* 步骤指示器 */
.wg-step-indicator {
  font-size: 12px;
  font-weight: 600;
  color: #9ca3af;
  margin-bottom: 20px;
  letter-spacing: 0.04em;
}

html[data-theme="dark"] .wg-step-indicator {
  color: #6b7280;
}

/* 关闭按钮 */
.wg-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.wg-close:hover {
  background: #f3f4f6;
  color: #4b5563;
}

html[data-theme="dark"] .wg-close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #d1d5db;
}

/* 图标区域 - 关键：居中 */
.wg-icon-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 20px;
}

.wg-icon-bg {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: #f3f4f6;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7c3aed;
}

html[data-theme="dark"] .wg-icon-bg {
  background: #2a2a3e;
  color: #a78bfa;
}

/* 标题 */
.wg-title {
  font-size: 18px;
  font-weight: 700;
  color: #1f2937;
  margin: 0 0 10px;
  line-height: 1.35;
}

html[data-theme="dark"] .wg-title {
  color: #f3f4f6;
}

/* 描述 */
.wg-desc {
  font-size: 14px;
  color: #6b7280;
  line-height: 1.65;
  margin: 0 0 28px;
}

html[data-theme="dark"] .wg-desc {
  color: #9ca3af;
}

/* 底部 */
.wg-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* 进度点 */
.wg-dots {
  display: flex;
  gap: 6px;
}

.wg-dot {
  width: 7px;
  height: 7px;
  border-radius: 3.5px;
  background: #e5e7eb;
  transition: all 0.25s;
}

.wg-dot.active {
  width: 20px;
  background: #7c3aed;
}

.wg-dot.done {
  background: #c4b5fd;
}

html[data-theme="dark"] .wg-dot {
  background: #3a3a4a;
}

html[data-theme="dark"] .wg-dot.active {
  background: #a78bfa;
}

html[data-theme="dark"] .wg-dot.done {
  background: #5b4a8a;
}

/* 操作按钮 */
.wg-actions {
  display: flex;
  gap: 8px;
}

.wg-prev {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  background: #fff;
  color: #6b7280;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.wg-prev:hover {
  border-color: #7c3aed;
  color: #7c3aed;
}

html[data-theme="dark"] .wg-prev {
  border-color: #3a3a4a;
  background: #2a2a3a;
  color: #9ca3af;
}

html[data-theme="dark"] .wg-prev:hover {
  border-color: #a78bfa;
  color: #a78bfa;
}

.wg-next {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 36px;
  padding: 0 18px;
  border-radius: 10px;
  border: none;
  background: #1f2937;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.wg-next:hover {
  background: #374151;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(31, 41, 55, 0.25);
}

html[data-theme="dark"] .wg-next {
  background: #f3f4f6;
  color: #1f2937;
}

html[data-theme="dark"] .wg-next:hover {
  background: #e5e7eb;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* 移动端适配 */
@media (max-width: 480px) {
  .wg-modal {
    padding: 28px 22px 20px;
  }

  .wg-title {
    font-size: 16px;
  }

  .wg-desc {
    font-size: 13px;
  }
}
/* === 对话页 === */
.chat-page {
  display: flex;
  height: 100vh;
  height: 100dvh;
  background: #fff;
  overflow: hidden;
}

/* --- 左侧会话列表 --- */
.chat-sidebar {
  width: 33.333%;
  min-width: 260px;
  max-width: 380px;
  background: #f9f9f9;
  border-right: 1px solid #f0f0f0;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  height: 100vh;
  height: 100dvh;
  padding-bottom: max(16px, env(safe-area-inset-bottom, 16px));
}

.chat-sidebar-header {
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-sidebar-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-sidebar-header h2 {
  font-size: 14px;
  font-weight: 700;
  color: #1a1a1a;
}

.chat-beta-badge {
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  background: #7c3aed;
  padding: 1px 5px;
  border-radius: 4px;
  letter-spacing: 0.02em;
}

/* 通知助手 */
.chat-notification-assistant {
  cursor: pointer;
}

.chat-notification-assistant:hover {
  background: #f5f5f5;
}

/* 深色模式通知助手头像 */
html[data-theme="dark"] .chat-friend-item .chat-friend-avatar div[style*="#fff7ed"] {
  background: #431407 !important;
}

html[data-theme="dark"] .chat-beta-badge {
  background: #a78bfa;
}

.chat-sidebar-list {
  flex: 1;
  overflow-y: auto;
  padding: 6px 10px;
}

.chat-sidebar-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
  margin-bottom: 2px;
  font-size: 13px;
  color: #444;
}

.chat-sidebar-item:hover {
  background: #f0f0f0;
}

.chat-sidebar-item.active {
  background: #eee;
  color: #1a1a1a;
  font-weight: 600;
}

.chat-sidebar-item-icon {
  flex-shrink: 0;
  color: #999;
}

.chat-sidebar-item.active .chat-sidebar-item-icon {
  color: #666;
}

.chat-sidebar-item-text {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-sidebar-item-time {
  font-size: 11px;
  color: #bbb;
  flex-shrink: 0;
}

.chat-sidebar-item-menu-wrap {
  position: relative;
  flex-shrink: 0;
}

.chat-sidebar-item-menu-trigger {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: none;
  background: none;
  color: #ccc;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all 0.15s;
  outline: none;
}

.chat-sidebar-item-menu-trigger:hover,
.chat-sidebar-item-menu-trigger:focus {
  background: #f0f0f0;
  color: #666;
}

.chat-sidebar-item.active .chat-sidebar-item-menu-trigger {
  color: #bbb;
}

.chat-sidebar-item.active .chat-sidebar-item-menu-trigger:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

/* 下拉菜单 */
.chat-sidebar-item-menu-dropdown {
  position: absolute;
  top: -6px;
  right: -4px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
  border: 1px solid #f0f0f0;
  padding: 6px 0;
  min-width: 130px;
  z-index: 100;
  animation: fadeIn 0.12s ease;
}

.chat-sidebar-item-menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  font-size: 13px;
  color: #333;
  cursor: pointer;
  transition: background 0.1s;
  white-space: nowrap;
}

.chat-sidebar-item-menu-item:hover {
  background: #f5f5f5;
}

.chat-sidebar-item-menu-item.danger {
  color: #e74c3c;
}

.chat-sidebar-item-menu-item.danger:hover {
  background: #fee;
}

.chat-sidebar-item-menu-divider {
  height: 1px;
  background: #f0f0f0;
  margin: 4px 10px;
}

/* === 微信式好友列表 === */
.chat-friend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
  margin-bottom: 2px;
  position: relative;
}

.chat-friend-item:hover {
  background: #f0f0f0;
}

.chat-friend-item.active {
  background: #eee;
}

.chat-friend-avatar {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #666;
  overflow: hidden;
  position: relative;
}

.chat-friend-item.active .chat-friend-avatar {
  background: #e0e0e0;
  color: #333;
}

.chat-friend-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.chat-friend-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chat-friend-name {
  font-size: 14px;
  font-weight: 500;
  color: #1a1a1a;
  display: flex;
  align-items: center;
  gap: 4px;
}

.chat-friend-alias-input {
  flex: 1;
  min-width: 0;
  padding: 3px 8px;
  font-size: 14px;
  font-weight: 500;
  color: #1a1a1a;
  background: #fff;
  border: 1px solid #d9d9d9;
  border-radius: 6px;
  outline: none;
  height: 26px;
  line-height: 1;
}

.chat-friend-alias-input:focus {
  border-color: #7c3aed;
  box-shadow: 0 0 0 2px rgba(124, 58, 237, 0.1);
}

.chat-friend-new-badge {
  font-size: 9px;
  font-weight: 700;
  color: #fff;
  background: #ff3b30;
  padding: 1px 4px;
  border-radius: 4px;
  line-height: 1;
  flex-shrink: 0;
}

.chat-friend-time {
  font-size: 11px;
  color: #bbb;
  flex-shrink: 0;
}

.chat-friend-preview {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chat-friend-lastmsg {
  font-size: 12px;
  color: #999;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-friend-lastmsg.unread {
  color: #1a1a1a;
  font-weight: 600;
}

/* 未读红点 */
.chat-friend-unread-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  background: #ff3b30;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 3px rgba(255, 59, 48, 0.3);
}

.chat-friend-avatar {
  position: relative;
}

/* 置顶标记 */
.chat-friend-pin-icon {
  margin-left: 4px;
  color: #f5a623;
  vertical-align: middle;
}

.chat-friend-item.pinned {
  background: rgba(245, 166, 35, 0.04);
}

.chat-friend-item.pinned:hover {
  background: rgba(245, 166, 35, 0.08);
}

/* 好友更多菜单按钮 */
.chat-friend-menu-btn {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  border: none;
  background: transparent;
  color: #bbb;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: all 0.15s;
  flex-shrink: 0;
}

.chat-friend-menu-btn:hover {
  background: #e5e5e5;
  color: #666;
}

.chat-friend-item.active .chat-friend-menu-btn {
  color: #ccc;
}

.chat-friend-item.active .chat-friend-menu-btn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: #fff;
}

/* 好友下拉菜单 */
.chat-friend-menu-dropdown {
  position: absolute;
  top: 6px;
  right: 6px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
  border: 1px solid #f0f0f0;
  padding: 6px 0;
  min-width: 120px;
  z-index: 100;
  animation: fadeIn 0.12s ease;
}

.chat-friend-menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  font-size: 13px;
  color: #333;
  cursor: pointer;
  transition: background 0.1s;
  white-space: nowrap;
}

.chat-friend-menu-item:hover {
  background: #f5f5f5;
}

.chat-friend-menu-divider {
  height: 1px;
  background: #f0f0f0;
  margin: 4px 0;
}

.chat-friend-menu-item-danger {
  color: #ef4444;
}

.chat-friend-menu-item-danger:hover {
  background: #fef2f2;
}

/* 编辑标题输入框 */
.chat-sidebar-item-edit-input {
  flex: 1;
  min-width: 0;
  padding: 4px 8px;
  border: 1px solid #1a1a1a;
  border-radius: 6px;
  font-size: 13px;
  color: #1a1a1a;
  background: #fff;
  outline: none;
  margin-right: 4px;
}

.chat-sidebar-item.pinned .chat-sidebar-item-icon {
  color: #f5a623;
}

.chat-sidebar-actions {
  display: flex;
  flex-direction: row;
  border-top: 1px solid #f0f0f0;
}

.chat-sidebar-action-item {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 0;
  font-size: 12px;
  color: #555;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  border-right: 1px solid #f0f0f0;
  white-space: nowrap;
}

.chat-sidebar-action-item:last-child {
  border-right: none;
}

.chat-sidebar-action-item:hover {
  background: #f0f0f0;
  color: #1a1a1a;
}

.chat-sidebar-action-item .chat-sidebar-menu-icon {
  color: #888;
  transition: color 0.2s;
}

.chat-sidebar-action-item:hover .chat-sidebar-menu-icon {
  color: #1a0a2e;
}

/* 旧样式保留兼容 */
.chat-sidebar-official {
  padding: 10px 14px;
  border-top: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: #444;
  cursor: pointer;
  transition: all 0.15s;
}

.chat-sidebar-official:hover {
  background: #f0f0f0;
}

.chat-sidebar-myspace {
  padding: 10px 14px;
  border-top: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: #444;
  cursor: pointer;
  transition: all 0.15s;
}

.chat-sidebar-myspace:hover {
  background: #f0f0f0;
}

.chat-sidebar-user {
  padding: 10px 14px;
  border-top: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.15s;
}

.chat-sidebar-user:hover {
  background: #f0f0f0;
}

.chat-sidebar-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #333, #555);
  overflow: hidden;
}

.chat-sidebar-info {
  flex: 1;
  min-width: 0;
}

.chat-sidebar-name {
  font-size: 12px;
  font-weight: 600;
  color: #1a1a1a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-sidebar-points {
  font-size: 11px;
  color: #888;
}

.chat-sidebar-recharge {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  border: none;
  background: none;
  color: #f5a623;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 2px;
}

.chat-sidebar-recharge:hover {
  background: #fff8e6;
}

.chat-sidebar-logout {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  border: none;
  background: none;
  color: #bbb;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-sidebar-logout:hover {
  color: #e74c3c;
  background: #f5f5f5;
}

/* --- 右侧主区域 --- */
.chat-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: #fff;
}

.chat-header {
  padding: 8px 16px;
  background: #fff;
  border-bottom: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  min-height: 44px;
}

.chat-header h3 {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
}

.chat-header-status {
  font-size: 12px;
  color: #bbb;
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 4px;
}

.chat-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.chat-header-right {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.chat-header-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: none;
  color: #666;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all 0.15s;
}

.chat-header-btn:hover {
  background: #f5f5f5;
  color: #1a1a1a;
}

.chat-header-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: #ff4d6d;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
  pointer-events: none;
}

.chat-header-menu-btn {
  display: none;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: none;
  color: #666;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all 0.15s;
}

.chat-header-menu-btn:hover {
  background: #f5f5f5;
  color: #1a1a1a;
}

.chat-header-back-btn {
  display: none;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: none;
  color: #666;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all 0.15s;
}

.chat-header-back-btn:hover {
  background: #f5f5f5;
  color: #1a1a1a;
}

.chat-header-friend-avatar {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
  margin-right: 6px;
  overflow: hidden;
}

.chat-header-tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  background: #fff;
  color: #666;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
  margin-left: 8px;
}

.chat-header-tool-btn:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
  color: #333;
}

/* --- 消息区域 --- */
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  scrollbar-width: none;
}

.chat-messages::-webkit-scrollbar {
  display: none;
}

.chat-messages.empty {
  justify-content: center;
  align-items: center;
  padding-bottom: 80px;
}

/* --- 空状态（Kimi 风格） --- */
.chat-empty {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  animation: fadeIn 0.6s ease-out;
}

.chat-empty-title {
  position: relative;
  z-index: 1;
  font-size: 42px;
  font-weight: 800;
  color: #1a1a1a;
  letter-spacing: 2px;
  line-height: 1.2;
  display: flex;
}

.chat-empty-char {
  display: inline-block;
  opacity: 0;
  transform: translateY(20px) scale(0.8);
  animation: charReveal 0.6s ease forwards;
}

@keyframes charReveal {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.chat-empty-subtitle {
  position: relative;
  z-index: 1;
  font-size: 14px;
  color: #999;
  font-weight: 400;
  animation: fadeIn 1s ease-out 0.6s both;
}

/* --- 消息气泡 --- */
.chat-msg {
  display: flex;
  gap: 12px;
  max-width: 85%;
  animation: fadeIn 0.3s ease-out;
}

.chat-msg.user {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.chat-msg.assistant {
  align-self: flex-start;
}

.chat-msg-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}

.chat-msg.user .chat-msg-avatar {
  background: linear-gradient(135deg, #333, #555);
}

.chat-msg.assistant .chat-msg-avatar {
  background: transparent;
}

.chat-msg-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.chat-msg-bubble {
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.6;
  word-wrap: break-word;
}

.chat-msg.user .chat-msg-bubble {
  background: #1a1a1a;
  color: #fff;
  border-radius: 16px 4px 16px 16px;
}

.chat-msg.assistant .chat-msg-bubble {
  background: #f5f5f5;
  color: #333;
  border: none;
  border-radius: 4px 16px 16px 16px;
}

.chat-msg-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 4px;
}

.chat-msg-time {
  font-size: 11px;
  color: #bbb;
}

.chat-msg.user .chat-msg-meta {
  justify-content: flex-end;
}

.chat-msg-copy {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 6px;
  border: none;
  background: none;
  color: #bbb;
  cursor: pointer;
  font-size: 11px;
  transition: all 0.15s;
  opacity: 0;
}

.chat-msg:hover .chat-msg-copy {
  opacity: 1;
}

.chat-msg-copy:hover {
  background: #f0f0f0;
  color: #666;
}

.chat-msg-copy span {
  font-size: 11px;
}

/* --- 输入框（Kimi 风格大圆角） --- */
.chat-input-area {
  position: relative;
  padding: 16px 24px 24px;
  background: transparent;
  flex-shrink: 0;
  display: flex;
  justify-content: center;
}

.chat-input-wrap {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 24px;
  padding: 14px 18px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: box-shadow 0.2s, border-color 0.2s, background 0.2s;
  width: 100%;
  max-width: 720px;
  -webkit-tap-highlight-color: transparent;
}

.chat-input-wrap:focus-within {
  border-color: rgba(200, 200, 200, 0.6);
  box-shadow: 0 6px 32px rgba(0, 0, 0, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.8);
  background: rgba(255, 255, 255, 0.95);
  outline: none;
}

.chat-input-textarea {
  flex: 1;
  border: none;
  background: none;
  font-size: 15px;
  line-height: 1.6;
  resize: none;
  outline: none;
  -webkit-tap-highlight-color: transparent;
  max-height: 200px;
  min-height: 24px;
  font-family: var(--font-sans);
  color: #1a1a1a;
  padding: 0;
  margin-bottom: 10px;
  overflow-y: auto;
  scroll-behavior: auto;
}

.chat-input-textarea:focus,
.chat-input-textarea:active {
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.chat-input-textarea::placeholder {
  color: #bbb;
}

/* --- 输入框工具栏 --- */
.chat-input-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 8px;
  border-top: 1px solid #f5f5f5;
}

.chat-input-toolbar-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-input-toolbar-btn {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid #e8e8e8;
  background: #fff;
  color: #666;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.chat-input-toolbar-btn:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

.chat-input-toolbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* --- 附件标签 --- */
.chat-attachment-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: #f5f5f5;
  border-radius: 8px;
  font-size: 12px;
  color: #666;
  margin-bottom: 8px;
  width: fit-content;
}

.chat-attachment-remove {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  border: none;
  background: none;
  color: #999;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.chat-attachment-tag.uploading {
  background: #fff8e6;
  color: #b8860b;
}

.chat-attachment-tag.error {
  background: #fff0f0;
  color: #c0392b;
  border: 1px solid #ffcccc;
}

.chat-attachment-remove:hover {
  color: #e74c3c;
  background: #eee;
}

.chat-input-send {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: #1a1a1a;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.chat-input-send:hover:not(:disabled) {
  background: #333;
  transform: scale(1.05);
}

.chat-input-send:disabled {
  background: #e0e0e0;
  color: #bbb;
  cursor: not-allowed;
}

/* 停止按钮 */
.chat-input-stop {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 20px;
  border: none;
  background: #fee;
  color: #e74c3c;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.chat-input-stop:hover {
  background: #fdd;
  transform: scale(1.02);
}

.chat-input-stop span {
  font-size: 13px;
}

/* 到底悬浮按钮 —— 位于输入框右上方 */

.chat-disclaimer {
  text-align: center;
  font-size: 11px;
  color: #bbb;
  padding: 6px 0 8px;
  letter-spacing: 0.01em;
  flex-shrink: 0;
}

html[data-theme="dark"] .chat-disclaimer {
  color: #555;
}

.chat-scroll-bottom-btn {
  position: absolute;
  bottom: calc(100% + 8px);
  right: 24px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid #e8e8e8;
  background: #fff;
  color: #666;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: all 0.2s ease;
  z-index: 50;
  animation: fadeIn 0.2s ease;
}

.chat-scroll-bottom-btn:hover {
  background: #1a1a1a;
  color: #fff;
  border-color: #1a1a1a;
  transform: translateY(-1px);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.12);
}

/* --- 功能卡片 --- */
.chat-widgets {
  padding: 0 24px 20px;
  background: transparent;
  flex-shrink: 0;
  display: flex;
  justify-content: center;
}

.chat-widgets-scroll {
  display: inline-flex;
  gap: 10px;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 4px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  cursor: grab;
  -webkit-user-select: none;
  user-select: none;
  touch-action: pan-x;
}

.chat-widgets-scroll:active {
  cursor: grabbing;
}

.chat-widgets-scroll::-webkit-scrollbar {
  display: none;
}

.chat-widget-card {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  min-width: 150px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
  text-align: left;
}

.chat-widget-card:hover:not(.disabled) {
  border-color: rgba(200, 200, 200, 0.5);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.88);
}

.chat-widget-card:active:not(.disabled) {
  transform: scale(0.98) translateY(0);
}

.chat-widget-card:focus-visible {
  outline: 2px solid rgba(139, 92, 246, 0.5);
  outline-offset: 2px;
}

.chat-widget-card.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  background: #fafafa;
}

.chat-widget-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: #f5f5f5;
  color: #555;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.chat-widget-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.chat-widget-title {
  font-size: 13px;
  font-weight: 600;
  color: #1a1a1a;
  white-space: nowrap;
}

.chat-widget-desc {
  font-size: 11px;
  color: #aaa;
  white-space: nowrap;
}

/* --- 打字指示器 --- */
.chat-typing {
  display: flex;
  gap: 4px;
  padding: 8px 0;
}

.chat-typing-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ccc;
  animation: pulse 1.4s ease-in-out infinite;
}

.chat-typing-dot:nth-child(2) { animation-delay: 0.2s; }
.chat-typing-dot:nth-child(3) { animation-delay: 0.4s; }

/* --- 生成回复中状态 --- */
.chat-streaming-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  font-size: 14px;
  color: #999;
}

/* --- 响应式 --- */
@media (max-width: 768px) {
  /* H5改造：默认显示好友列表全屏 */
  .chat-sidebar {
    position: static;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    padding-bottom: max(16px, env(safe-area-inset-bottom, 16px));
    transform: none;
    transition: none;
    z-index: 1;
    background: #f9f9f9;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-right: none;
    box-shadow: none;
  }

  .chat-main {
    display: none;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
    background: var(--bg-base, #fff);
  }

  /* 当切换到聊天视图时 */
  .chat-page.mobile-chat-view .chat-sidebar {
    display: none;
  }

  .chat-page.mobile-chat-view .chat-main {
    display: flex;
  }

  /* 移动端返回按钮显示，菜单按钮隐藏 */
  .chat-header-back-btn {
    display: flex;
  }

  .chat-header-menu-btn {
    display: none;
  }

  /* 聊天视图时显示返回按钮 */
  .chat-page.mobile-chat-view .chat-header-back-btn {
    display: flex;
  }

  .chat-sidebar-overlay {
    display: none;
  }

  .chat-widgets {
    padding: 0 16px 16px;
  }

  .chat-widgets-scroll {
    gap: 8px;
    padding-bottom: 8px;
  }

  .chat-widget-card {
    min-width: 140px;
    padding: 8px 12px;
  }

  .chat-msg {
    max-width: 92%;
  }

  .chat-messages {
    padding: 16px;
  }

  .chat-input-area {
    padding: 12px 16px 20px;
  }

  .chat-empty-title {
    font-size: 32px;
  }

  .chat-msg-copy {
    opacity: 1;
  }

  .chat-scroll-bottom-btn {
    right: 16px;
    width: 30px;
    height: 30px;
  }
}

/* --- 弹窗 --- */
.chat-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.2s ease;
}

.chat-modal {
  background: #fff;
  border-radius: 16px;
  width: 100%;
  max-width: 420px;
  max-height: 85vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
  animation: slideUp 0.25s ease;
}

.chat-modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.chat-modal-header h3 {
  font-size: 16px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0;
}

.chat-modal-close {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: none;
  background: none;
  color: #999;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all 0.15s;
}

.chat-modal-close:hover {
  background: #f5f5f5;
  color: #1a1a1a;
}

.chat-modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
  scrollbar-width: none;
}

.chat-modal-body::-webkit-scrollbar {
  display: none;
}

.chat-modal-footer {
  padding: 12px 20px;
  border-top: 1px solid #f0f0f0;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-shrink: 0;
}

/* --- 用户信息弹窗 --- */
.chat-user-avatar-lg {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(135deg, #333, #555);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 700;
  margin: 0 auto 20px;
}

.chat-form-group {
  margin-bottom: 16px;
}

.chat-form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #666;
  margin-bottom: 6px;
}

.chat-form-group input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  font-size: 14px;
  color: #1a1a1a;
  background: #fff;
  outline: none;
  transition: border-color 0.2s;
  box-sizing: border-box;
}

.chat-form-group input:focus {
  border-color: #1a1a1a;
}

.chat-form-group input:disabled {
  background: #f5f5f5;
  color: #999;
  cursor: not-allowed;
}

.chat-form-static {
  padding: 10px 12px;
  font-size: 14px;
  color: #1a1a1a;
  background: #f5f5f5;
  border-radius: 10px;
}

.chat-form-divider {
  height: 1px;
  background: #f0f0f0;
  margin: 20px 0;
}

.chat-password-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: #f9f9f9;
  border: 1px solid #f0f0f0;
  border-radius: 10px;
  font-size: 13px;
  color: #444;
  cursor: pointer;
  transition: all 0.15s;
}

.chat-password-toggle:hover {
  background: #f0f0f0;
}

.chat-password-arrow {
  margin-left: auto;
  transition: transform 0.2s ease;
}

.chat-password-arrow.open {
  transform: rotate(90deg);
}

.chat-password-form {
  margin-top: 12px;
  animation: slideDown 0.25s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- 按钮 --- */
.chat-btn {
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.15s;
}

.chat-btn-primary {
  background: #1a1a1a;
  color: #fff;
}

.chat-btn-primary:hover {
  background: #333;
}

.chat-btn-secondary {
  background: #f5f5f5;
  color: #666;
}

.chat-btn-secondary:hover {
  background: #e8e8e8;
}

/* --- 我的空间弹窗 --- */
.chat-myspace-modal {
  min-height: 320px;
}

.chat-myspace-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  gap: 12px;
  text-align: center;
}

.chat-myspace-empty p {
  font-size: 14px;
  color: #666;
  margin: 0;
}

.chat-myspace-empty span {
  font-size: 12px;
  color: #aaa;
}

.chat-myspace-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.chat-myspace-item {
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  background: #f5f5f5;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.chat-myspace-item:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.chat-myspace-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.chat-myspace-file {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #888;
}

.chat-myspace-file span {
  font-size: 11px;
  text-align: center;
  padding: 0 4px;
  word-break: break-all;
}

/* 图片预览 */
.chat-image-preview {
  position: relative;
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.chat-image-preview img {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 12px;
  object-fit: contain;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.chat-image-preview-close {
  position: absolute;
  top: -40px;
  right: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.9);
  color: #333;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.chat-image-preview-close:hover {
  background: #fff;
  transform: scale(1.1);
}

.chat-image-preview-actions {
  display: flex;
  gap: 12px;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* === 深色模式 ===
   Muted postal · monochromatic · approachable sophistication
   Card-based with layered elements · neo minimalism
*/
/* html[data-theme="dark"] 优先级 (0,1,1) 高于 :root (0,1,0)，确保深色变量不被 LandingPage.css 的 :root 覆盖 */
html[data-theme="dark"] {
  --bg-base: #111114;
  --bg-surface: #18181c;
  --bg-raised: #1e1e22;
  --bg-elevated: #242428;
  --bg-hover: #2c2c30;
  --bg-active: #343438;
  --border-subtle: rgba(255, 255, 255, 0.04);
  --border-default: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.14);
  --text-primary: #ededf0;
  --text-secondary: #9ca3af;
  --text-tertiary: #6b7280;
}

/* 提高优先级：使用 html[data-theme="dark"] 确保覆盖默认样式 */
html[data-theme="dark"] body {
  background: var(--bg-base) !important;
  color: var(--text-primary);
}

/* --- 根容器 --- */
html[data-theme="dark"] .chat-page {
  background: var(--bg-base) !important;
}

/* --- 侧边栏 --- */
html[data-theme="dark"] .chat-sidebar,
html[data-theme="dark"] .chat-sidebar {
  background: var(--bg-surface) !important;
  border-right-color: var(--border-default);
}

html[data-theme="dark"] .chat-sidebar-header h2 {
  color: var(--text-primary);
}

/* 深色模式下logo反色适配（白色logo在深色背景可见） */
.chat-logo-dark {
  filter: brightness(0) invert(1);
}

/* 深色模式下玛丽（logo.png）头像反色，与顶部logo保持一致 */
html[data-theme="dark"] .chat-friend-avatar img[src*="logo.png"],
html[data-theme="dark"] .chat-header-friend-avatar img[src*="logo.png"],
html[data-theme="dark"] .chat-msg-avatar img[src*="logo.png"] {
  filter: brightness(0) invert(1);
}

html[data-theme="dark"] .chat-sidebar-item {
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-sidebar-item:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-sidebar-item.active {
  background: var(--bg-hover);
  color: var(--text-primary);
}

/* 深色模式 Header 工具按钮 */
html[data-theme="dark"] .chat-header-friend-avatar {
  background: var(--bg-elevated);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-header-tool-btn {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-header-tool-btn:hover {
  background: var(--bg-hover);
  border-color: var(--border-hover);
  color: var(--text-primary);
}

/* 下拉菜单深色 */
html[data-theme="dark"] .chat-sidebar-item-menu-dropdown {
  background: var(--bg-surface);
  border-color: var(--border-default);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

html[data-theme="dark"] .chat-sidebar-item-menu-item {
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-sidebar-item-menu-item:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-sidebar-item-menu-item.danger {
  color: #f87171;
}

html[data-theme="dark"] .chat-sidebar-item-menu-item.danger:hover {
  background: rgba(220, 38, 38, 0.1);
}

html[data-theme="dark"] .chat-sidebar-item-menu-divider {
  background: var(--border-default);
}

/* 编辑输入框深色 */
html[data-theme="dark"] .chat-sidebar-item-edit-input {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-sidebar-item-edit-input:focus {
  border-color: var(--border-hover);
}

/* 充值按钮深色 */
html[data-theme="dark"] .chat-sidebar-recharge {
  color: #d4a843;
}

html[data-theme="dark"] .chat-sidebar-recharge:hover {
  background: rgba(212, 168, 67, 0.1);
}

html[data-theme="dark"] .chat-sidebar-search {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-sidebar-search::placeholder {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-sidebar-search:focus {
  border-color: var(--border-hover);
}

html[data-theme="dark"] .chat-sidebar-search-icon {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-sidebar-search-clear {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-sidebar-search-clear:hover {
  color: var(--text-primary);
  background: var(--bg-hover);
}

html[data-theme="dark"] .chat-sidebar-logout {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-sidebar-logout:hover {
  color: #f87171;
  background: rgba(220, 38, 38, 0.08);
}

/* --- 主区域 --- */
html[data-theme="dark"] .chat-main {
  background: var(--bg-base) !important;
}

html[data-theme="dark"] .chat-header {
  background: var(--bg-raised) !important;
  border-bottom-color: var(--border-default);
}

html[data-theme="dark"] .chat-header h3 {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-header-status {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-header-btn,
html[data-theme="dark"] .chat-header-menu-btn {
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-header-btn:hover,
html[data-theme="dark"] .chat-header-menu-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

/* --- 消息区 --- */
html[data-theme="dark"] .chat-messages {
  background: var(--bg-base) !important;
}

html[data-theme="dark"] .chat-msg-bubble {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-msg.assistant .chat-msg-bubble {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-msg.user .chat-msg-bubble {
  background: linear-gradient(135deg, #2c2c30, #242428);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-msg.user .chat-msg-avatar {
  background: linear-gradient(135deg, #3a3a3e, #4a4a4e);
}

html[data-theme="dark"] .chat-msg-time {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-msg-copy {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-msg-copy:hover {
  background: var(--bg-hover);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-msg-actions {
  background: var(--bg-raised);
  border-color: var(--border-default);
}

html[data-theme="dark"] .chat-msg-action-btn {
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-msg-action-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

/* --- 输入区 --- */
html[data-theme="dark"] .chat-input-area {
  background: var(--bg-base) !important;
}

html[data-theme="dark"] .chat-input-wrap {
  background: rgba(28, 28, 32, 0.85);
  border-color: var(--border-default);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

html[data-theme="dark"] .chat-input-wrap:focus-within {
  background: rgba(30, 30, 34, 0.95);
  border-color: var(--border-hover);
  box-shadow: 0 6px 32px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

html[data-theme="dark"] .chat-input-textarea {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-input-textarea::placeholder {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-input-send {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-input-send:hover:not(:disabled) {
  background: var(--bg-active);
}

html[data-theme="dark"] .chat-input-send:disabled {
  background: var(--bg-elevated);
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-input-stop {
  background: rgba(220, 38, 38, 0.1);
  color: #f87171;
}

html[data-theme="dark"] .chat-input-stop:hover {
  background: rgba(220, 38, 38, 0.15);
}

/* --- 附件 --- */
html[data-theme="dark"] .chat-attachment-tag {
  background: var(--bg-elevated);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-attachment-tag.uploading {
  background: #2d2610;
  color: #d4a843;
}

html[data-theme="dark"] .chat-attachment-tag.error {
  background: #2d1010;
  color: #f87171;
  border-color: #5c2020;
}

html[data-theme="dark"] .chat-attachment-remove {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-attachment-remove:hover {
  color: #f87171;
  background: var(--bg-hover);
}

/* --- 好友列表 dark 模式 --- */
html[data-theme="dark"] .chat-friend-item:hover {
  background: var(--bg-hover);
}

html[data-theme="dark"] .chat-friend-item.active {
  background: var(--bg-elevated);
}

html[data-theme="dark"] .chat-friend-avatar {
  background: var(--bg-elevated);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-friend-alias-input {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-friend-alias-input:focus {
  border-color: #a78bfa;
  box-shadow: 0 0 0 2px rgba(167, 139, 250, 0.15);
}

html[data-theme="dark"] .chat-friend-item.active .chat-friend-avatar {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-friend-name {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-friend-time {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-friend-lastmsg {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-friend-lastmsg.unread {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-friend-item.pinned {
  background: rgba(245, 166, 35, 0.06);
}

html[data-theme="dark"] .chat-friend-item.pinned:hover {
  background: rgba(245, 166, 35, 0.1);
}

html[data-theme="dark"] .chat-friend-menu-btn {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-friend-menu-btn:hover {
  background: var(--bg-hover);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-friend-item.active .chat-friend-menu-btn {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-friend-item.active .chat-friend-menu-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-friend-menu-dropdown {
  background: var(--bg-raised);
  border-color: var(--border-default);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

html[data-theme="dark"] .chat-friend-menu-item {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-friend-menu-item:hover {
  background: var(--bg-hover);
}

html[data-theme="dark"] .chat-friend-menu-divider {
  background: var(--border-default);
}

html[data-theme="dark"] .chat-friend-menu-item-danger {
  color: #f87171;
}

html[data-theme="dark"] .chat-friend-menu-item-danger:hover {
  background: rgba(239, 68, 68, 0.15);
}

/* --- 功能卡片 --- */
html[data-theme="dark"] .chat-widget-card {
  background: rgba(28, 28, 32, 0.72);
  border-color: var(--border-default);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

html[data-theme="dark"] .chat-widget-card:hover:not(.disabled) {
  background: rgba(32, 32, 36, 0.88);
  border-color: var(--border-hover);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

html[data-theme="dark"] .chat-widget-card.disabled {
  background: var(--bg-raised);
  opacity: 0.4;
}

html[data-theme="dark"] .chat-widget-card:focus-visible {
  outline-color: var(--text-secondary);
}

html[data-theme="dark"] .chat-widget-icon {
  background: var(--bg-hover);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-widget-title {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-widget-desc {
  color: var(--text-tertiary);
}

/* --- 空状态 --- */
html[data-theme="dark"] .chat-empty-title {
  color: var(--text-primary) !important;
}

html[data-theme="dark"] .chat-empty-subtitle {
  color: var(--text-secondary) !important;
}

/* --- 打字指示器 --- */
html[data-theme="dark"] .chat-typing-dot {
  background: var(--text-tertiary);
}

html[data-theme="dark"] .chat-streaming-status {
  color: var(--text-tertiary);
}

/* --- 滚动按钮 --- */
html[data-theme="dark"] .chat-scroll-bottom-btn {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-secondary);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

html[data-theme="dark"] .chat-scroll-bottom-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-hover);
}

/* --- 弹窗 --- */
html[data-theme="dark"] .chat-modal-overlay {
  background: rgba(0, 0, 0, 0.6);
}

html[data-theme="dark"] .chat-modal {
  background: var(--bg-surface);
  color: var(--text-primary);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

html[data-theme="dark"] .chat-modal-header {
  border-bottom-color: var(--border-default);
}

html[data-theme="dark"] .chat-modal-header h3 {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-modal-close {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-modal-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-modal-footer {
  border-top-color: var(--border-default);
}

html[data-theme="dark"] .chat-modal-body textarea {
  background: var(--bg-elevated);
  border-color: var(--border-default) !important;
  color: var(--text-primary) !important;
}

html[data-theme="dark"] .chat-modal-body textarea::placeholder {
  color: var(--text-tertiary);
}

/* --- 表单 --- */
html[data-theme="dark"] .chat-form-group label {
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-form-group input {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-form-group input:focus {
  border-color: var(--border-hover);
}

html[data-theme="dark"] .chat-form-group input:disabled {
  background: var(--bg-raised);
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-form-static {
  background: var(--bg-raised);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-form-divider {
  background: var(--border-default);
}

html[data-theme="dark"] .chat-password-toggle {
  background: var(--bg-raised);
  border-color: var(--border-default);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-password-toggle:hover {
  background: var(--bg-hover);
}

html[data-theme="dark"] .chat-user-avatar-lg {
  background: linear-gradient(135deg, #3a3a3e, #4a4a4e);
}

/* --- 按钮 --- */
html[data-theme="dark"] .chat-btn-primary {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-btn-primary:hover {
  background: var(--bg-active);
}

html[data-theme="dark"] .chat-btn-secondary {
  background: var(--bg-elevated);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-btn-secondary:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

/* --- 我的空间 --- */
html[data-theme="dark"] .chat-myspace-empty p {
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-myspace-empty span {
  color: var(--text-tertiary);
}

/* === 高级思考指示器 === */
.chat-thinking-advanced {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  color: #888;
  font-size: 13px;
  font-weight: 500;
}

.chat-thinking-text {
  animation: thinkingBreath 2.4s ease-in-out infinite;
}

@keyframes thinkingBreath {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

.chat-thinking-dots {
  display: flex;
  gap: 3px;
  align-items: center;
}

.chat-thinking-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #aaa;
  animation: thinkingDotWave 1.4s ease-in-out infinite;
}

.chat-thinking-dot:nth-child(1) { animation-delay: 0s; }
.chat-thinking-dot:nth-child(2) { animation-delay: 0.2s; }
.chat-thinking-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes thinkingDotWave {
  0%, 100% { transform: translateY(0); opacity: 0.3; }
  50% { transform: translateY(-4px); opacity: 1; }
}

/* 深色模式 */
html[data-theme="dark"] .chat-thinking-advanced {
  color: #777;
}

html[data-theme="dark"] .chat-thinking-dot {
  background: #bbb;
}

html[data-theme="dark"] .chat-myspace-item {
  background: var(--bg-elevated);
}

html[data-theme="dark"] .chat-myspace-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

/* --- Widget 面板 --- */
html[data-theme="dark"] .chat-widget-panel {
  background: var(--bg-surface);
  border-color: var(--border-default);
}

html[data-theme="dark"] .chat-widget-item {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-widget-item:hover {
  background: var(--bg-hover);
}

/* --- 移动端 --- */
@media (max-width: 768px) {
  html[data-theme="dark"] .chat-sidebar {
    background: var(--bg-surface);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-right-color: var(--border-default);
  }

  html[data-theme="dark"] .chat-sidebar-overlay {
    display: none;
  }

  html[data-theme="dark"] .chat-header-back-btn {
    color: var(--text-secondary);
  }

  html[data-theme="dark"] .chat-header-back-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
  }
}

/* --- 侧边栏底部菜单 --- */
html[data-theme="dark"] .chat-sidebar-actions {
  border-top-color: var(--border-default);
}

html[data-theme="dark"] .chat-sidebar-action-item {
  border-right-color: var(--border-default);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-sidebar-action-item:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-sidebar-action-item .chat-sidebar-menu-icon {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-sidebar-action-item:hover .chat-sidebar-menu-icon {
  color: var(--accent-light);
}

html[data-theme="dark"] .chat-sidebar-official,
html[data-theme="dark"] .chat-sidebar-myspace,
html[data-theme="dark"] .chat-sidebar-user {
  border-top-color: var(--border-default);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-sidebar-official:hover,
html[data-theme="dark"] .chat-sidebar-myspace:hover,
html[data-theme="dark"] .chat-sidebar-user:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-sidebar-menu-icon {
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-sidebar-menu-arrow {
  color: var(--text-tertiary);
}

html[data-theme="dark"] .chat-sidebar-name {
  color: var(--text-primary);
}

html[data-theme="dark"] .chat-sidebar-points {
  color: var(--text-tertiary);
}

/* --- 输入框工具栏 --- */
html[data-theme="dark"] .chat-input-toolbar {
  border-top-color: var(--border-default);
}

html[data-theme="dark"] .chat-input-toolbar-btn {
  background: var(--bg-elevated);
  border-color: var(--border-default);
  color: var(--text-secondary);
}

html[data-theme="dark"] .chat-input-toolbar-btn:hover {
  background: var(--bg-hover);
  border-color: var(--border-hover);
  color: var(--text-primary);
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
/**
 * 行业情报雷达 - 可视化大屏 Dashboard
 * 双主题配色：浅色/深色自适应，变量定义在 .radar-dashboard 作用域
 */

/* ─── 浅色主题变量（默认） ─── */
.radar-dashboard {
  --r-bg: #fff;
  --r-surface: #f9f9f9;
  --r-raised: #f5f5f7;
  --r-elevated: #f0f0f0;
  --r-hover: #eaeaea;
  --r-active: #e0e0e0;
  --r-border: rgba(0, 0, 0, 0.08);
  --r-border-subtle: rgba(0, 0, 0, 0.04);
  --r-border-hover: rgba(0, 0, 0, 0.14);
  --r-text: #1a1a1a;
  --r-text-secondary: #666;
  --r-text-tertiary: #999;
  --r-accent: #b8923e;
  --r-accent-light: rgba(184, 146, 62, 0.12);
  --r-up: #389e0d;
  --r-down: #cf1322;
  --r-overlay: rgba(0, 0, 0, 0.45);
}

/* ─── 深色主题变量 ─── */
html[data-theme="dark"] .radar-dashboard {
  --r-bg: #1e1e22;
  --r-surface: #18181c;
  --r-raised: #1e1e22;
  --r-elevated: #242428;
  --r-hover: #2c2c30;
  --r-active: #343438;
  --r-border: rgba(255, 255, 255, 0.08);
  --r-border-subtle: rgba(255, 255, 255, 0.04);
  --r-border-hover: rgba(255, 255, 255, 0.14);
  --r-text: #ededf0;
  --r-text-secondary: #9ca3af;
  --r-text-tertiary: #6b7280;
  --r-accent: #d4a853;
  --r-accent-light: rgba(212, 168, 83, 0.12);
  --r-up: #52c41a;
  --r-down: #f87171;
  --r-overlay: rgba(0, 0, 0, 0.7);
}

/* ─── 遮罩 ─── */
.radar-overlay {
  position: fixed;
  inset: 0;
  background: var(--r-overlay);
  backdrop-filter: blur(12px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: r-fade-in 0.35s ease both;
}

@keyframes r-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ─── 大屏容器 ─── */
.radar-dashboard {
  width: 92vw;
  max-width: 1200px;
  max-height: 92vh;
  background: var(--r-bg);
  border-radius: 24px;
  border: 1px solid var(--r-border);
  box-shadow:
    0 40px 120px rgba(0, 0, 0, 0.35),
    0 0 0 1px var(--r-border-subtle) inset;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: r-scale-in 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes r-scale-in {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(16px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* ─── 顶部标题栏 ─── */
.radar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px;
  border-bottom: 1px solid var(--r-border);
  background: linear-gradient(90deg, var(--r-accent-light) 0%, transparent 50%);
  flex-shrink: 0;
}

.radar-header-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  color: var(--r-text);
  letter-spacing: 0.02em;
}

.radar-header-title svg {
  color: var(--r-text);
  animation: r-pulse 2.5s ease-in-out infinite;
}

@keyframes r-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.15); }
}

.radar-header-meta {
  display: flex;
  align-items: center;
  gap: 14px;
}

.radar-date-badge {
  font-size: 11px;
  font-weight: 500;
  color: var(--r-text-tertiary);
  background: var(--r-surface);
  padding: 5px 12px;
  border-radius: 20px;
  border: 1px solid var(--r-border);
  letter-spacing: 0.03em;
}

.radar-close-btn {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: none;
  background: var(--r-surface);
  color: var(--r-text-tertiary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  border: 1px solid var(--r-border);
}

.radar-close-btn:hover {
  background: var(--r-hover);
  color: var(--r-text);
  transform: rotate(90deg);
  border-color: var(--r-border-hover);
}

/* ─── 内容区域 ─── */
.radar-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.radar-body::-webkit-scrollbar { width: 5px; }
.radar-body::-webkit-scrollbar-track { background: transparent; }
.radar-body::-webkit-scrollbar-thumb {
  background: var(--r-border-hover);
  border-radius: 3px;
}

/* ─── 加载状态 ─── */
.radar-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 100px 20px;
  gap: 20px;
}

.radar-loading-ring {
  width: 44px;
  height: 44px;
  border: 3px solid var(--r-border);
  border-top-color: var(--r-accent);
  border-radius: 50%;
  animation: r-spin 0.9s linear infinite;
}

@keyframes r-spin {
  to { transform: rotate(360deg); }
}

.radar-loading-text {
  color: var(--r-text-tertiary);
  font-size: 14px;
  letter-spacing: 0.04em;
}

/* ─── 空状态 ─── */
.radar-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 100px 20px;
  gap: 16px;
  color: var(--r-text-tertiary);
}

.radar-empty svg { opacity: 0.25; }

/* ─── KPI 指标行 ─── */
.radar-kpi-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  animation: r-slide-up 0.5s cubic-bezier(0.16,1,0.3,1) both;
}

.radar-kpi-card {
  background: var(--r-surface);
  border-radius: 16px;
  padding: 20px;
  border: 1px solid var(--r-border);
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.radar-kpi-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--r-accent), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.radar-kpi-card:hover {
  transform: translateY(-2px);
  border-color: var(--r-border-hover);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

html[data-theme="dark"] .radar-kpi-card:hover {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.radar-kpi-card:hover::before { opacity: 1; }

.radar-kpi-label {
  font-size: 12px;
  color: var(--r-text-tertiary);
  margin-bottom: 10px;
  letter-spacing: 0.03em;
  display: flex;
  align-items: center;
  gap: 6px;
}

.radar-kpi-value {
  font-size: 26px;
  font-weight: 800;
  color: var(--r-text);
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.radar-kpi-sub {
  font-size: 12px;
  color: var(--r-text-secondary);
  margin-top: 8px;
  font-weight: 500;
}

.radar-kpi-trend {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  font-weight: 600;
  margin-left: 6px;
}

.radar-kpi-trend.up   { color: var(--r-up); }
.radar-kpi-trend.down { color: var(--r-down); }

/* ─── 摘要卡片 ─── */
.radar-summary-card {
  background: var(--r-surface);
  border-radius: 16px;
  padding: 20px 24px;
  border: 1px solid var(--r-border);
  animation: r-slide-up 0.5s cubic-bezier(0.16,1,0.3,1) 0.05s both;
}

.radar-summary-label {
  font-size: 11px;
  color: var(--r-text-tertiary);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.radar-summary-text {
  font-size: 14px;
  line-height: 1.7;
  color: var(--r-text-secondary);
}

.radar-mock-badge {
  margin-top: 14px;
  font-size: 12px;
  color: var(--r-text-tertiary);
  background: var(--r-raised);
  padding: 8px 12px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--r-border);
}

/* ─── 主网格：排行 + 图表 ─── */
.radar-main-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  animation: r-slide-up 0.5s cubic-bezier(0.16,1,0.3,1) 0.1s both;
}

/* ─── 区块卡片 ─── */
.radar-section-card {
  background: var(--r-surface);
  border-radius: 16px;
  padding: 20px;
  border: 1px solid var(--r-border);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.radar-section-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--r-text);
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: 0.02em;
}

.radar-section-title svg {
  color: var(--r-accent);
  opacity: 0.9;
}

/* ─── 排行列表 ─── */
.radar-rank-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.radar-rank-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--r-raised);
  border: 1px solid var(--r-border-subtle);
  transition: all 0.2s ease;
  animation: r-slide-right 0.4s cubic-bezier(0.16,1,0.3,1) both;
}

.radar-rank-item:hover {
  background: var(--r-hover);
  border-color: var(--r-border);
  transform: translateX(3px);
}

@keyframes r-slide-right {
  from { opacity: 0; transform: translateX(-10px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes r-slide-up {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

.radar-rank-num {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  flex-shrink: 0;
}

.radar-rank-num.gold {
  background: linear-gradient(135deg, #d4a853, #b8923e);
  color: #fff;
}

.radar-rank-num.silver {
  background: linear-gradient(135deg, #a0a0a4, #7a7a7e);
  color: #fff;
}

.radar-rank-num.bronze {
  background: linear-gradient(135deg, #b87333, #8a5a28);
  color: #fff;
}

.radar-rank-num.normal {
  background: var(--r-elevated);
  color: var(--r-text-tertiary);
}

.radar-rank-info { flex: 1; min-width: 0; }

.radar-rank-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--r-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.radar-rank-meta {
  font-size: 11px;
  color: var(--r-text-tertiary);
  margin-top: 2px;
}

.radar-rank-value {
  font-size: 12px;
  font-weight: 700;
  color: var(--r-accent);
  flex-shrink: 0;
  white-space: nowrap;
}

.radar-rank-change {
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
  margin-left: 6px;
}

.radar-rank-change.up   { color: var(--r-up); }
.radar-rank-change.down { color: var(--r-down); }

/* ─── 热度条 ─── */
.radar-heat-bar {
  width: 100%;
  height: 3px;
  background: var(--r-elevated);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 5px;
}

.radar-heat-fill {
  height: 100%;
  background: linear-gradient(90deg, rgba(184,146,62,0.5), var(--r-accent));
  border-radius: 2px;
  transition: width 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

html[data-theme="dark"] .radar-heat-fill {
  background: linear-gradient(90deg, rgba(212,168,83,0.5), var(--r-accent));
}

/* ─── 右侧图表区 ─── */
.radar-chart-area {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* 环形图 */
.radar-donut-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 10px 0;
}

.radar-donut {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: conic-gradient(
    var(--r-accent) 0% var(--p1, 35%),
    var(--r-elevated) var(--p1, 35%) 100%
  );
  position: relative;
  flex-shrink: 0;
}

.radar-donut::after {
  content: '';
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  background: var(--r-surface);
}

.radar-donut-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.radar-donut-val {
  font-size: 22px;
  font-weight: 800;
  color: var(--r-text);
  line-height: 1;
}

.radar-donut-label {
  font-size: 10px;
  color: var(--r-text-tertiary);
  margin-top: 3px;
  letter-spacing: 0.04em;
}

.radar-donut-legend {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.radar-legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--r-text-secondary);
}

.radar-legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 3px;
  flex-shrink: 0;
}

/* ─── 资讯流 ─── */
.radar-news-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.radar-news-item {
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--r-raised);
  border: 1px solid var(--r-border-subtle);
  transition: all 0.2s ease;
  animation: r-slide-right 0.4s cubic-bezier(0.16,1,0.3,1) both;
}

.radar-news-item:hover {
  background: var(--r-hover);
  border-color: var(--r-border);
}

.radar-news-title {
  font-size: 12px;
  color: var(--r-text-secondary);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.radar-news-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 11px;
}

.radar-news-source {
  color: var(--r-accent);
  font-weight: 500;
  opacity: 0.9;
}

.radar-news-time {
  color: var(--r-text-tertiary);
}

/* ─── AI 洞察 ─── */
.radar-insight-card {
  background: var(--r-surface);
  border-radius: 16px;
  padding: 20px;
  border: 1px solid var(--r-border);
  animation: r-slide-up 0.5s cubic-bezier(0.16,1,0.3,1) 0.15s both;
}

.radar-insight-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--r-text);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.radar-insight-title svg { color: var(--r-accent); opacity: 0.9; }

.radar-insight-text {
  font-size: 13px;
  color: var(--r-text-secondary);
  line-height: 1.8;
}

/* ─── 底部栏 ─── */
.radar-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 28px;
  border-top: 1px solid var(--r-border);
  background: var(--r-surface);
  flex-shrink: 0;
}

.radar-btn {
  padding: 8px 20px;
  border-radius: 10px;
  border: none;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.radar-btn-secondary {
  background: var(--r-elevated);
  color: var(--r-text-secondary);
  border: 1px solid var(--r-border);
}

.radar-btn-secondary:hover {
  background: var(--r-hover);
  color: var(--r-text);
  border-color: var(--r-border-hover);
}

.radar-btn-primary {
  background: var(--r-text);
  color: var(--r-bg);
}

.radar-btn-primary:hover {
  background: var(--r-text);
  opacity: 0.9;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.radar-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* ─── 下排网格：资讯 + 洞察 ─── */
.radar-bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  animation: r-slide-up 0.5s cubic-bezier(0.16,1,0.3,1) 0.12s both;
}

/* ─── 响应式 ─── */
@media (max-width: 960px) {
  .radar-dashboard {
    width: 96vw;
    max-height: 95vh;
    border-radius: 20px;
  }
  .radar-kpi-row {
    grid-template-columns: repeat(2, 1fr);
  }
  .radar-main-grid,
  .radar-bottom-grid {
    grid-template-columns: 1fr;
  }
  .radar-body {
    padding: 16px 20px;
  }
}

@media (max-width: 640px) {
  .radar-overlay { padding: 0; }
  .radar-dashboard {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    max-height: none;
    border-radius: 0;
  }
  .radar-body {
    padding: 14px 16px;
    gap: 14px;
  }
  .radar-kpi-row {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .radar-kpi-card { padding: 14px; }
  .radar-kpi-value { font-size: 18px; }
  .radar-kpi-label { font-size: 11px; }
  .radar-kpi-sub { font-size: 11px; }
  .radar-header { padding: 16px 18px; }
  .radar-header-title { font-size: 16px; }
  .radar-footer { padding: 14px 18px; }
  .radar-summary-card { padding: 16px; }
  .radar-section-card { padding: 16px; gap: 12px; }
  .radar-rank-item { padding: 9px 11px; gap: 10px; }
  .radar-rank-name { font-size: 12px; }
  .radar-donut-wrap {
    flex-direction: column;
    gap: 14px;
  }
  .radar-donut {
    width: 110px;
    height: 110px;
  }
  .radar-donut::after { inset: 14px; }
  .radar-donut-val { font-size: 18px; }
  .radar-news-item { padding: 10px 12px; }
  .radar-insight-card { padding: 16px; }
  .radar-btn {
    padding: 8px 14px;
    font-size: 12px;
  }
}

@media (max-width: 380px) {
  .radar-kpi-value { font-size: 16px; }
  .radar-kpi-sub { font-size: 10px; }
  .radar-header-title { font-size: 15px; gap: 8px; }
  .radar-donut {
    width: 96px;
    height: 96px;
  }
  .radar-donut::after { inset: 12px; }
  .radar-donut-val { font-size: 16px; }
}
.points-record-page {
  min-height: 100vh;
  background: #fff;
  display: flex;
  flex-direction: column;
}

/* 顶部导航 */
.points-record-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: #fff;
  border-bottom: 1px solid #f0f0f0;
  position: sticky;
  top: 0;
  z-index: 10;
}

.points-record-header h1 {
  font-size: 17px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0;
}

.points-record-back {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  color: #333;
  transition: background 0.2s;
}

.points-record-back:hover {
  background: #f5f5f5;
}

/* 主体内容 */
.points-record-body {
  flex: 1;
  padding: 16px;
  max-width: 600px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

/* 统计卡片 */
.points-record-stats {
  margin-bottom: 16px;
}

.points-record-total-card {
  background: #1a1a1a;
  border-radius: 16px;
  padding: 24px;
  text-align: center;
  color: #fff;
}

.points-record-total-label {
  font-size: 13px;
  opacity: 0.7;
  letter-spacing: 0.5px;
}

.points-record-total-value {
  font-size: 36px;
  font-weight: 700;
  margin-top: 8px;
}

.points-record-sub-stats {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.points-record-sub-card {
  flex: 1;
  background: #f5f5f5;
  border-radius: 12px;
  padding: 16px 0;
  text-align: center;
}

.points-record-sub-value {
  font-size: 18px;
  font-weight: 600;
  color: #1a1a1a;
}

.points-record-sub-label {
  font-size: 12px;
  color: #999;
  margin-top: 4px;
}

/* 筛选标签 */
.points-record-tabs {
  display: flex;
  background: #f5f5f5;
  border-radius: 12px;
  margin-bottom: 12px;
  overflow: hidden;
  padding: 4px;
  gap: 4px;
}

.points-record-tab {
  flex: 1;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 400;
  color: #666;
  border: none;
  background: none;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
  border-radius: 10px;
}

.points-record-tab.active {
  font-weight: 600;
  color: #1a1a1a;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

/* 记录列表 */
.points-record-list {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #f0f0f0;
}

.points-record-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #f5f5f5;
}

.points-record-item:last-child {
  border-bottom: none;
}

.points-record-item-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}

.points-record-item-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  flex-shrink: 0;
}

.points-record-item-icon.earn {
  background: #1a1a1a;
}

.points-record-item-icon.spend {
  background: #999;
}

.points-record-item-info {
  min-width: 0;
}

.points-record-item-desc {
  font-size: 14px;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.points-record-item-time {
  font-size: 12px;
  color: #bbb;
  margin-top: 3px;
}

.points-record-item-change {
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  margin-left: 12px;
}

.points-record-item-change.earn {
  color: #1a1a1a;
}

.points-record-item-change.spend {
  color: #999;
}

/* 空状态 */
.points-record-empty {
  text-align: center;
  padding: 60px 20px;
  color: #999;
}

.points-record-empty-icon {
  margin-bottom: 16px;
  color: #D1D5DB;
}

.points-record-empty-title {
  font-size: 15px;
  margin: 0;
  color: #666;
}

.points-record-empty-desc {
  font-size: 13px;
  color: #bbb;
  margin-top: 6px;
}

.points-record-loading {
  font-size: 14px;
  color: #999;
}

/* 响应式 */
@media (max-width: 480px) {
  .points-record-body {
    padding: 12px;
  }

  .points-record-total-value {
    font-size: 32px;
  }
}
:root {
  /* Chat 浅色模式配色系统 — 无紫色，纯黑白灰 */
  --bg-base: #ffffff;
  --bg-surface: #f9f9f9;
  --bg-raised: #f5f5f5;
  --bg-elevated: #f0f0f0;
  --bg-hover: #eee;
  --bg-active: #e5e5e5;
  --border-subtle: #f0f0f0;
  --border-default: #e8e8e8;
  --border-hover: #d0d0d0;
  --text-primary: #1a1a1a;
  --text-secondary: #666;
  --text-tertiary: #999;

  /* 品牌强调色 — 深紫色系 */
  --accent: #1a0a2e;
  --accent-hover: #0d0221;
  --accent-light: #2d1655;
  --accent-bg: rgba(13, 2, 33, 0.06);
  --accent-border: rgba(13, 2, 33, 0.12);
  --accent-glow: rgba(13, 2, 33, 0.08);

  /* 功能色 */
  --success: #34c759;
  --warning: #ff9f0a;
  --error: #ff3b30;

  /* 渐变 */
  --gradient-hero: linear-gradient(135deg, #1a0a2e 0%, #2d1655 50%, #4a1a6b 100%);
  --gradient-surface: linear-gradient(180deg, var(--bg-surface) 0%, var(--bg-base) 100%);

  /* 字体 */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', 'PingFang SC', sans-serif;

  /* 间距 */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2rem;
  --space-6: 2.5rem;
  --space-7: 3rem;
  --space-8: 5rem;
  --space-9: 7rem;
  --space-10: 9rem;

  /* 圆角 */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-full: 980px;

  /* 阴影 */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.12);
  --shadow-glow: 0 8px 40px rgba(13, 2, 33, 0.08);

  /* 动画 */
  --ease-out: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 0.2s;
  --duration-normal: 0.4s;
  --duration-slow: 0.6s;
  --duration-slower: 0.8s;
}

.landing-page {
  font-family: var(--font-primary);
  background-color: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* 隐藏滚动条 */
.landing-page::-webkit-scrollbar {
  display: none;
}
.landing-page {
  -ms-overflow-style: none;
  scrollbar-width: none;
}
html {
  scrollbar-width: none;
  -ms-overflow-style: none;
}
html::-webkit-scrollbar {
  display: none;
}
body {
  scrollbar-width: none;
  -ms-overflow-style: none;
}
body::-webkit-scrollbar {
  display: none;
}

/* 跳转链接 */
.skip-link {
  position: absolute;
  top: -100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: white;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-full);
  font-weight: 600;
  z-index: 10000;
  text-decoration: none;
  transition: top var(--duration-fast);
}
.skip-link:focus { top: var(--space-3); }

/* ==================== 导航栏 ==================== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--duration-normal) var(--ease-out);
}
.nav.scrolled {
  background: rgba(255, 255, 255, 0.95);
  border-bottom-color: var(--border-default);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-5);
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
  color: var(--text-primary);
  transition: all var(--duration-fast) var(--ease-out);
}
.nav-logo:hover { opacity: 0.7; }
.nav-logo img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: cover;
}
.nav-logo-text {
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-5);
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 400;
  transition: all var(--duration-fast);
}
.nav-links a:hover { color: var(--text-primary); }

.nav-cta {
  background: var(--accent);
  color: white !important;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-weight: 500;
  font-size: 0.8125rem !important;
  transition: all var(--duration-fast);
  border: none;
  cursor: pointer;
  font-family: inherit;
}
.nav-cta:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(13, 2, 33, 0.2);
}

/* ==================== Hero 区域 ==================== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(56px + var(--space-10)) var(--space-5) var(--space-9);
  position: relative;
  overflow: hidden;
  background: #ffffff;
}

/* Hero 背景效果 */
.hero-bg-effects {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.4;
}
.hero-glow-1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(13, 2, 33, 0.06) 0%, transparent 70%);
  top: -10%;
  left: 50%;
  transform: translateX(-50%);
  animation: glowPulse 8s ease-in-out infinite;
}
.hero-glow-2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(85, 85, 85, 0.04) 0%, transparent 70%);
  bottom: 10%;
  right: 10%;
  animation: glowPulse 6s ease-in-out infinite reverse;
}
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 0, 0.02) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 0%, transparent 70%);
}

/* 粒子 Canvas */
.hero-particles-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

@keyframes glowPulse {
  0%, 100% { transform: translateX(-50%) scale(1); opacity: 0.4; }
  50% { transform: translateX(-50%) scale(1.15); opacity: 0.6; }
}

.hero-content {
  max-width: 900px;
  position: relative;
  z-index: 1;
}

/* ==================== Hero 影视风格开屏动效 ==================== */

.hero-eyebrow {
  display: inline-block;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-4);
}

/* ==================== 开屏渐显 ==================== */
.hero-splash {
  position: fixed;
  inset: 0;
  z-index: 2001;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: splashOut 1.2s cubic-bezier(0.25, 0.1, 0.25, 1.0) 2.2s forwards;
}
.hero-splash-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-5);
}
.hero-splash-img {
  width: 200px;
  height: auto;
  opacity: 0;
  animation: splashItemIn 1.0s cubic-bezier(0.25, 0.1, 0.25, 1.0) 0.3s forwards;
}
.hero-splash-text {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.3em;
  color: #1a0a2e;
  opacity: 0;
  animation: splashItemIn 1.0s cubic-bezier(0.25, 0.1, 0.25, 1.0) 0.6s forwards;
}
@keyframes splashItemIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes splashOut {
  from { opacity: 1; }
  to { opacity: 0; visibility: hidden; }
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.04em;
  margin-bottom: var(--space-6);
}

.hero-title .gradient {
  background: linear-gradient(100deg, #0d0221 0%, #1a0a2e 25%, #2d1655 50%, #4a1a6b 60%, #d8ccf0 70%, #4a1a6b 85%, #0d0221 100%) 0 0 / 200% 100%;
  -webkit-text-fill-color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  filter: drop-shadow(0 0 24px rgba(13, 2, 33, 0.12));
  animation: shimmer 8s ease-in-out infinite;
}

.hero-subtitle {
  font-size: clamp(1.125rem, 2vw, 1.375rem);
  font-weight: 400;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-7);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: var(--space-8);
}

/* ==================== Agent环绕动画 ==================== */
.agent-orbit {
  position: relative;
  width: 360px;
  height: 360px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.agent-orbit-center {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.agent-orbit-logo {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  object-fit: cover;
  box-shadow: 0 8px 32px rgba(13, 2, 33, 0.2);
  animation: orbitLogoPulse 3s ease-in-out infinite;
}

@keyframes orbitLogoPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 8px 32px rgba(13, 2, 33, 0.2); }
  50% { transform: scale(1.05); box-shadow: 0 12px 40px rgba(13, 2, 33, 0.3); }
}

.agent-orbit-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.agent-orbit-track {
  position: absolute;
  inset: 0;
  animation: orbitRotate 30s linear infinite;
  pointer-events: none;
}

@keyframes orbitRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.agent-orbit-agent {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 48px;
  height: 48px;
  margin-top: -24px;
  margin-left: -24px;
  pointer-events: auto;
  cursor: pointer;
  transform: rotate(var(--orbit-angle)) translateX(140px) rotate(calc(var(--orbit-angle) * -1));
  animation: agentCounterRotate 30s linear infinite;
}

@keyframes agentCounterRotate {
  from { transform: rotate(var(--orbit-angle)) translateX(140px) rotate(calc(var(--orbit-angle) * -1)) rotate(0deg); }
  to { transform: rotate(var(--orbit-angle)) translateX(140px) rotate(calc(var(--orbit-angle) * -1)) rotate(-360deg); }
}

.agent-orbit-agent-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  position: relative;
  z-index: 2;
  overflow: hidden;
}

.agent-orbit-agent:hover .agent-orbit-agent-icon {
  transform: scale(1.2);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.3);
}

.agent-orbit-tooltip {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) scale(0.9);
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  box-shadow: var(--shadow-lg);
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.25s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 2px;
  pointer-events: none;
}

.agent-orbit-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: var(--bg-base);
}

.agent-orbit-tooltip strong {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-primary);
}

.agent-orbit-tooltip span {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.agent-orbit-agent:hover .agent-orbit-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) scale(1);
}

/* 悬停时暂停轨道动画 */
.agent-orbit:hover .agent-orbit-track,
.agent-orbit:hover .agent-orbit-agent {
  animation-play-state: paused;
}

/* 按钮样式 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--radius-full);
  border: none;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out);
  font-family: inherit;
}
.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 4px 20px rgba(13, 2, 33, 0.15);
  font-weight: 600;
  font-size: 1.0625rem;
}
.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(13, 2, 33, 0.2);
}
.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1.5px solid var(--border-default);
  font-weight: 500;
}
.btn-secondary:hover {
  background: var(--bg-surface);
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

/* ==================== 通用区块 ==================== */
.section-container {
  max-width: 1200px;
  margin: 0 auto;
}
.section-header {
  text-align: center;
  margin-bottom: var(--space-9);
}
.section-eyebrow {
  display: inline-block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-3);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.section-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 900;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-3);
  color: var(--text-primary);
}
.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ==================== 功能特性 ==================== */
.features {
  padding: var(--space-10) var(--space-5);
  background: var(--bg-surface);
  position: relative;
}
.features::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-default), transparent);
}


/* ==================== 展示区 ==================== */
.showcase {
  padding: var(--space-10) var(--space-5);
  background: var(--bg-base);
  position: relative;
}
.showcase::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-default), transparent);
}

.showcase-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-9);
  align-items: center;
}
.showcase-content:nth-child(2) {
  direction: rtl;
}
.showcase-content:nth-child(2) > * {
  direction: ltr;
}
.showcase-content:nth-child(4) {
  direction: rtl;
}
.showcase-content:nth-child(4) > * {
  direction: ltr;
}
.showcase-visual {
  display: flex;
  justify-content: center;
  align-self: center;
}
.showcase-text h3 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 800;
  margin-bottom: var(--space-5);
  letter-spacing: -0.03em;
  color: var(--text-primary);
}
.showcase-text p {
  font-size: 1.0625rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-5);
}
.showcase-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding: 0;
  margin: 0;
}
.showcase-list li {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: 1rem;
  color: var(--text-secondary);
}
.check-icon {
  color: var(--accent);
  font-weight: 700;
  font-size: 1.125rem;
}
.showcase-visual {
  display: flex;
  justify-content: center;
}
.showcase-mockup {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 9/16;
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-default);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  box-shadow: var(--shadow-lg);
  transition: all var(--duration-normal);
}
.showcase-mockup:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}
.mockup-header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--border-default);
}
.mockup-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border-default);
}
.mockup-name {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.9375rem;
}
.mockup-role {
  font-size: 0.75rem;
  color: var(--text-tertiary);
}
.mockup-messages {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.mockup-bubble {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  font-size: 0.8125rem;
  line-height: 1.5;
}
.mockup-bubble.user {
  background: var(--accent);
  color: white;
  align-self: flex-end;
  max-width: 85%;
  border-bottom-right-radius: 4px;
}
.mockup-bubble.ai {
  background: var(--bg-base);
  color: var(--text-secondary);
  align-self: flex-start;
  max-width: 85%;
  border-bottom-left-radius: 4px;
  border: 1px solid var(--border-default);
}

/* Mockup 附件样式 */
.mockup-attachment {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  padding: 4px 10px;
  background: rgba(255,255,255,0.15);
  border-radius: 6px;
  font-size: 0.75rem;
}
.mockup-file-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}
.mockup-link {
  display: inline-block;
  margin-top: 8px;
  color: var(--accent-light);
  font-size: 0.8125rem;
  cursor: pointer;
}
.mockup-image {
  width: 100%;
  border-radius: 8px;
  margin: 8px 0;
  object-fit: cover;
}

/* 多行 showcase 布局 */
.showcase-content + .showcase-content {
  margin-top: var(--space-10);
}

/* 电脑 Mockup */
.showcase-mockup.desktop {
  width: 100%;
  max-width: 680px;
  aspect-ratio: 16 / 10;
  min-height: unset;
  padding: 0;
  overflow: hidden;
}
.desktop-titlebar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  background: var(--bg-raised);
  border-bottom: 1px solid var(--border-default);
}
.desktop-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.desktop-dot.red { background: #ff5f57; }
.desktop-dot.yellow { background: #febc2e; }
.desktop-dot.green { background: #28c840; }
.desktop-title {
  margin-left: 8px;
  font-size: 0.8125rem;
  color: var(--text-secondary);
}
.desktop-body {
  display: flex;
  height: calc(100% - 41px);
  min-height: unset;
}
.desktop-sidebar {
  width: 180px;
  background: var(--bg-raised);
  border-right: 1px solid var(--border-default);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  flex-shrink: 0;
}
.sidebar-logo {
  font-weight: 700;
  font-size: 0.9375rem;
  color: var(--text-primary);
}
.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.nav-item {
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}
.nav-item:hover {
  background: var(--bg-hover);
}
.nav-item.active {
  background: var(--accent-bg);
  color: var(--accent);
  font-weight: 600;
}
.desktop-main {
  flex: 1;
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  overflow-y: auto;
}

/* 手机刘海装饰 */
.showcase-mockup.phone {
  position: relative;
}
.showcase-mockup.phone::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 22px;
  background: var(--bg-surface);
  border-radius: 0 0 14px 14px;
  border: 1px solid var(--border-default);
  border-top: none;
  z-index: 2;
}

@media (max-width: 1024px) {
  .showcase-content,
  .showcase-content:nth-child(2),
  .showcase-content:nth-child(4) {
    grid-template-columns: 1fr;
    direction: ltr;
  }
  .showcase-content:nth-child(2) > *,
  .showcase-content:nth-child(4) > * {
    direction: ltr;
  }
  .showcase-mockup.desktop {
    max-width: 100%;
    aspect-ratio: 16 / 10;
    max-width: 100%;
  }
  .desktop-sidebar {
    display: none;
  }
}

@media (max-width: 768px) {
  .showcase-mockup.desktop {
    aspect-ratio: 4 / 3;
  }
}

/* ==================== 数据亮点 ==================== */
.highlights {
  padding: var(--space-10) var(--space-5);
  background: var(--bg-surface);
  position: relative;
}
.highlights::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-default), transparent);
}

.highlights-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-5);
}
.highlight-item {
  text-align: center;
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  transition: all var(--duration-normal) var(--ease-out);
}
.highlight-item:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: var(--shadow-glow);
  border-color: var(--accent-border);
}
.highlight-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-3);
  background: var(--accent-bg);
  color: var(--accent);
  transition: all var(--duration-normal);
}
.highlight-item:hover .highlight-icon {
  transform: scale(1.1);
  background: rgba(13, 2, 33, 0.1);
}
.highlight-label {
  font-size: 1.0625rem;
  color: var(--text-primary);
  font-weight: 700;
  margin-bottom: var(--space-1);
}
.highlight-desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ==================== 安全亮点（紧凑版） ==================== */
.security-section {
  padding: var(--space-6) var(--space-5);
  background: var(--bg-surface);
  border-top: 1px solid var(--border-default);
}
.security-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  max-width: 900px;
  margin: 0 auto;
}
.security-header {
  margin-bottom: var(--space-5) !important;
}
.security-item {
  text-align: center;
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  transition: all var(--duration-normal) var(--ease-out);
}
.security-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
  border-color: var(--accent-border);
}
.security-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-2);
  background: var(--accent-bg);
  color: var(--accent);
  transition: all var(--duration-normal);
}
.security-item:hover .security-icon {
  transform: scale(1.1);
  background: rgba(13, 2, 33, 0.1);
}
.security-label {
  font-size: 0.9375rem;
  color: var(--text-primary);
  font-weight: 700;
  margin-bottom: 4px;
}
.security-desc {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ==================== 定价区域 — 复刻 moxt.ai 风格 ==================== */
.pricing {
  padding: var(--space-10) var(--space-5);
  background: var(--bg-base);
  position: relative;
}
.pricing::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-default), transparent);
}

.pricing-hero-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  margin-bottom: var(--space-2);
  color: var(--text-primary);
  text-align: center;
}
.pricing-hero-title em {
  font-style: italic;
  font-weight: 400;
  color: var(--text-secondary);
}
.pricing-hero-desc {
  font-size: 1.125rem;
  color: var(--text-secondary);
  text-align: center;
  max-width: 560px;
  margin: 0 auto var(--space-8);
  line-height: 1.7;
}

/* 积分展示 */
.pricing-credit-display {
  text-align: center;
  margin-bottom: var(--space-6);
}
.pricing-credit-amount {
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 900;
  color: var(--text-primary);
  letter-spacing: -0.04em;
  line-height: 1.1;
}
.pricing-credit-unit {
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  font-weight: 600;
  color: var(--text-secondary);
  margin-left: var(--space-2);
}
.pricing-credit-rate {
  font-size: 0.9375rem;
  color: var(--text-tertiary);
  margin-top: var(--space-2);
}
.pricing-credit-rate span {
  font-weight: 600;
  color: var(--text-secondary);
}

/* 价格选择器 */
.pricing-selector {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2);
  margin-bottom: var(--space-6);
}
.pricing-selector-btn {
  padding: 10px 20px;
  border: 1.5px solid var(--border-default);
  border-radius: var(--radius-full);
  background: var(--bg-base);
  color: var(--text-secondary);
  font-size: 0.9375rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--duration-fast);
  font-family: inherit;
}
.pricing-selector-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
  background: var(--bg-surface);
}
.pricing-selector-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}
.pricing-selector-btn.active:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}
.pricing-selector-custom {
  padding: 10px 20px;
  border: 1.5px solid var(--border-default);
  border-radius: var(--radius-full);
  background: var(--bg-base);
  color: var(--text-secondary);
  font-size: 0.9375rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--duration-fast);
  font-family: inherit;
}
.pricing-selector-custom:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}
.pricing-selector-custom.active {
  background: var(--bg-surface);
  color: var(--text-primary);
  border-color: var(--accent);
  border-style: dashed;
}

/* 自定义金额输入 */
.pricing-custom-input-wrap {
  display: none;
  justify-content: center;
  margin-bottom: var(--space-6);
}
.pricing-custom-input-wrap.show {
  display: flex;
}
.pricing-custom-input {
  width: 200px;
  padding: 10px 16px;
  border: 1.5px solid var(--border-default);
  border-radius: var(--radius-full);
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary);
  background: var(--bg-base);
  outline: none;
  text-align: center;
  font-family: inherit;
  transition: border-color var(--duration-fast);
}
.pricing-custom-input:focus {
  border-color: var(--accent);
}
.pricing-custom-input::placeholder {
  color: var(--text-tertiary);
}

/* CTA */
.pricing-cta {
  text-align: center;
  margin-bottom: var(--space-3);
}
.pricing-cta .btn-primary {
  padding: 16px 40px;
  font-size: 1.0625rem;
}

/* 试用说明 + FAQ 入口 */
.pricing-trial-faq-entry {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  margin-bottom: var(--space-9);
}
.pricing-trial-note {
  font-size: 0.875rem;
  color: var(--text-tertiary);
  margin: 0;
}
.pricing-trial-faq-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-full);
  background: var(--bg-base);
  color: var(--text-secondary);
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--duration-fast);
  font-family: inherit;
}
.pricing-trial-faq-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-bg);
}
.pricing-trial-faq-btn svg {
  transition: transform 0.2s;
}

/* FAQ 弹窗 */
.faq-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-5);
}
.faq-modal-overlay.active {
  display: flex !important;
}
.faq-modal-content {
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  max-width: 640px;
  width: 100%;
  max-height: 80vh;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.2);
  position: relative;
  transform: translateY(20px) scale(0.95);
  transition: transform var(--duration-normal) var(--ease-out);
  padding: var(--space-7);
}
.faq-modal-overlay.active .faq-modal-content {
  transform: translateY(0) scale(1);
}
.faq-modal-close {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-raised);
  border: 1px solid var(--border-default);
  font-size: 1.75rem;
  line-height: 1;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--duration-fast);
  display: flex;
  align-items: center;
  justify-content: center;
}
.faq-modal-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  transform: rotate(90deg);
}
.faq-modal-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-5);
  padding-right: var(--space-6);
}
.faq-modal-list {
  overflow-y: auto;
  max-height: calc(80vh - 120px);
}
.faq-modal-item {
  border-bottom: 1px solid var(--border-default);
}
.faq-modal-item:first-child {
  border-top: 1px solid var(--border-default);
}
.faq-modal-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: var(--space-4) var(--space-3);
  background: none;
  border: none;
  border-radius: var(--radius-full);
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  transition: color var(--duration-fast);
}
.faq-modal-question:hover {
  color: var(--accent);
}
.faq-modal-arrow {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  transition: transform 0.3s var(--ease-out);
  color: var(--text-tertiary);
}
.faq-modal-item.open .faq-modal-arrow {
  transform: rotate(180deg);
}
.faq-modal-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}
.faq-modal-item.open .faq-modal-answer {
  max-height: 300px;
}
.faq-modal-answer-inner {
  padding: 0 0 var(--space-4);
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ==================== CTA ==================== */
.cta {
  padding: var(--space-10) var(--space-5);
  background: var(--bg-surface);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-default), transparent);
}

.cta-bg-effects {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.cta-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.3;
}
.cta-glow-1 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(13, 2, 33, 0.06) 0%, transparent 70%);
  top: 50%;
  left: 20%;
  transform: translateY(-50%);
}
.cta-glow-2 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(85, 85, 85, 0.04) 0%, transparent 70%);
  top: 50%;
  right: 20%;
  transform: translateY(-50%);
}

.cta-content {
  max-width: 640px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.cta-logo {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--space-5);
}
.cta-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  filter: drop-shadow(0 4px 20px rgba(13, 2, 33, 0.1));
}
.cta h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 900;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-3);
  color: var(--text-primary);
}
.cta p {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-6);
  line-height: 1.7;
  font-weight: 400;
}
.cta-buttons {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
  flex-wrap: wrap;
}

/* ==================== Footer ==================== */
.footer {
  padding: var(--space-6) var(--space-5);
  background: var(--bg-base);
  border-top: 1px solid var(--border-default);
  position: relative;
  z-index: 10;
  min-height: 180px;
  display: flex;
  align-items: center;
}
.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
}
.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.footer-logo img {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}
.footer-logo span {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.9375rem;
}
.footer-links {
  display: flex;
  gap: var(--space-5);
  list-style: none;
  margin: 0;
  padding: 0;
  justify-content: center;
  flex-wrap: wrap;
}
.footer-links a, .footer-links button {
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.875rem;
  transition: all var(--duration-fast);
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 6px 8px;
  border-radius: 6px;
}
.footer-links a:hover, .footer-links button:hover {
  color: var(--text-primary);
  background: var(--bg-hover);
}
.footer-copyright {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  margin: 0;
  text-align: center;
}
.footer-beian {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.8125rem;
  color: var(--text-secondary);
  margin-top: 4px;
}
.footer-beian-icon {
  width: 16px;
  height: 16px;
  display: inline-block;
  object-fit: contain;
}
.footer-beian-link {
  color: var(--text-tertiary);
  text-decoration: none;
  transition: color var(--duration-fast);
}
.footer-beian-link:hover {
  color: var(--text-primary);
}

/* 桌面端 Footer 保持水平顶部行 */
@media (min-width: 769px) {
  .footer-content {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-3) var(--space-5);
  }
  .footer-copyright,
  .footer-beian {
    flex: 0 0 100%;
    text-align: center;
    justify-content: center;
  }
}

/* ==================== 移动端菜单 ==================== */
.mobile-menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  gap: 5px;
  z-index: 1001;
}
.mobile-menu-btn span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all var(--duration-fast) var(--ease-out);
}
.mobile-menu-btn.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.mobile-menu-btn.active span:nth-child(2) { opacity: 0; }
.mobile-menu-btn.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

.mobile-nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-fast);
}
.mobile-nav-overlay.active { opacity: 1; visibility: visible; }

.mobile-nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 320px;
  height: 100vh;
  background: var(--bg-base);
  border-left: 1px solid var(--border-default);
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  transition: right var(--duration-normal) var(--ease-out);
  padding: calc(56px + var(--space-6)) var(--space-5) var(--space-6);
  overflow-y: auto;
}
.mobile-nav.active { right: 0; }
.mobile-nav-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding: 0;
  margin: 0;
}
.mobile-nav-links a, .mobile-nav-links button {
  display: block;
  padding: var(--space-3) var(--space-4);
  text-decoration: none;
  color: var(--text-primary);
  font-size: 1.125rem;
  font-weight: 500;
  border-radius: var(--radius-full);
  transition: all var(--duration-fast);
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  text-align: left;
  width: 100%;
}
.mobile-nav-links a:hover, .mobile-nav-links button:hover { background: var(--bg-surface); }
.mobile-nav-links .nav-cta {
  margin-top: var(--space-4);
  text-align: center;
  background: var(--accent);
  color: white !important;
}
.mobile-nav-links .nav-cta:hover { background: var(--accent-hover); }

/* ==================== 电影分镜式区块动画 ==================== */
.cinematic-section {
  position: relative;
}
.cinematic-section .section-inner {
  will-change: transform, opacity, filter;
  opacity: 1;
  transform: translateY(0);
  filter: blur(0px);
}

/* ==================== 拟态风格图标 ==================== */
.highlight-icon {
  background: linear-gradient(145deg, #f0eef5, #ffffff) !important;
  border: none !important;
  box-shadow:
    6px 6px 16px rgba(26, 10, 46, 0.08),
    -6px -6px 16px rgba(255, 255, 255, 0.9),
    inset 0 0 0 1px rgba(255, 255, 255, 0.5);
  color: #2D1B4E;
  transition: all 0.5s cubic-bezier(0.25, 0.1, 0.25, 1.0);
}
.highlight-icon svg {
  stroke: #2D1B4E;
  stroke-width: 1.5px;
  fill: none;
}
.highlight-item:hover .highlight-icon {
  background: linear-gradient(145deg, #e8e4f0, #f5f3fa) !important;
  box-shadow:
    8px 8px 20px rgba(26, 10, 46, 0.12),
    -4px -4px 12px rgba(255, 255, 255, 0.95),
    inset 0 0 0 1px rgba(255, 255, 255, 0.6);
  transform: translateY(-4px) scale(1.05);
}

/* ==================== 动画 ==================== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes shimmer {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s var(--ease-out);
}
.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }
.delay-5 { transition-delay: 0.5s; }
.delay-6 { transition-delay: 0.6s; }

/* ==================== 模态弹窗 ==================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-5);
}
.modal-overlay.active { display: flex !important; }
.modal-content {
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  max-width: 800px;
  width: 100%;
  max-height: 80vh;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.2);
  position: relative;
  transform: translateY(20px) scale(0.95);
  transition: transform var(--duration-normal) var(--ease-out);
}
.modal-overlay.active .modal-content { transform: translateY(0) scale(1); }
.modal-close {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-raised);
  border: 1px solid var(--border-default);
  font-size: 2rem;
  line-height: 1;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--duration-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}
.modal-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  transform: rotate(90deg);
}
.modal-body {
  padding: var(--space-8);
  overflow-y: auto;
  max-height: 80vh;
  color: var(--text-secondary);
}
.modal-body h2 {
  font-size: 2rem;
  font-weight: 900;
  margin-bottom: var(--space-6);
  color: var(--text-primary);
  letter-spacing: -0.02em;
}
.modal-body h3 {
  font-size: 1.375rem;
  font-weight: 700;
  margin-top: var(--space-6);
  margin-bottom: var(--space-3);
  color: var(--text-primary);
}
.modal-body p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: var(--space-4);
}
.modal-body ul {
  list-style: disc;
  padding-left: var(--space-5);
  margin-bottom: var(--space-4);
}
.modal-body li {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: var(--space-2);
}
.modal-body a {
  color: var(--accent);
  text-decoration: underline;
  font-weight: 500;
}

/* ==================== 响应式 ==================== */
@media (max-width: 1024px) {
  .showcase-content { grid-template-columns: 1fr; gap: var(--space-7); }
  .showcase-visual { order: -1; }
  .highlights-grid { grid-template-columns: repeat(2, 1fr); gap: var(--space-4); }
  .pricing-features-grid { grid-template-columns: repeat(2, 1fr); }
  .faq-modal-list { max-height: calc(90vh - 100px); }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .mobile-menu-btn { display: flex; }
  .hero {
    padding: calc(56px + var(--space-6)) var(--space-4) var(--space-7);
    min-height: auto;
  }
  .hero-title { font-size: clamp(2rem, 8vw, 3rem); }
  .hero-subtitle { font-size: 1rem; padding: 0 var(--space-3); }
  .hero-cta { flex-direction: column; align-items: center; gap: var(--space-3); margin-bottom: var(--space-6); }
  .agent-orbit {
    width: 280px;
    height: 280px;
  }
  .agent-orbit-logo {
    width: 56px;
    height: 56px;
    border-radius: 16px;
  }
  .agent-orbit-agent {
    transform: rotate(var(--orbit-angle)) translateX(100px) rotate(calc(var(--orbit-angle) * -1));
  }
  @keyframes agentCounterRotate {
    from { transform: rotate(var(--orbit-angle)) translateX(100px) rotate(calc(var(--orbit-angle) * -1)) rotate(0deg); }
    to { transform: rotate(var(--orbit-angle)) translateX(100px) rotate(calc(var(--orbit-angle) * -1)) rotate(-360deg); }
  }
  .agent-orbit-agent-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
  }
  .agent-orbit-tooltip strong {
    font-size: 0.8125rem;
  }
  .agent-orbit-tooltip span {
    font-size: 0.6875rem;
  }
  .btn { width: 100%; max-width: 280px; justify-content: center; }
  .showcase-text h3 { font-size: 1.5rem; }
  .showcase-mockup { max-width: 300px; }
  .highlights-grid { grid-template-columns: repeat(2, 1fr); gap: var(--space-3); }
  .highlight-item { padding: var(--space-4); }
  .highlight-icon { width: 48px; height: 48px; border-radius: 12px; }
  .highlight-icon svg { width: 22px; height: 22px; }
  .pricing-selector { gap: var(--space-1); }
  .pricing-selector-btn { padding: 8px 14px; font-size: 0.875rem; }
  .faq-modal-content { padding: var(--space-5); max-width: 95%; max-height: 90vh; }
  .faq-modal-title { font-size: 1.25rem; }
  .cta h2 { font-size: 1.75rem; }
  .cta p { font-size: 1rem; }
  .cta-buttons { flex-direction: column; align-items: center; }
  .features, .showcase, .highlights, .cta, .pricing { padding: var(--space-8) var(--space-4); }
  .modal-content { max-width: 95%; max-height: 90vh; }
  .modal-body { padding: var(--space-5); }
  .modal-body h2 { font-size: 1.5rem; }
  .modal-body h3 { font-size: 1.125rem; }
  /* 安全区块移动端紧凑 */
  .security-grid { gap: var(--space-2); }
  .security-item { padding: var(--space-3) var(--space-2); }
  .security-icon { width: 36px; height: 36px; }
  .security-icon svg { width: 18px; height: 18px; }
  .security-label { font-size: 0.8125rem; }
  .security-desc { font-size: 0.75rem; }
}

@media (max-width: 480px) {
  .nav-container { padding: 0 var(--space-3); }
  .nav-logo-text { font-size: 0.9375rem; }
  .hero { padding: calc(56px + var(--space-5)) var(--space-3) var(--space-6); }
  .hero-title { font-size: clamp(1.75rem, 10vw, 2.5rem); }
  .hero-subtitle { font-size: 0.9375rem; }
  .section-title { font-size: clamp(1.5rem, 6vw, 2rem); }
  .highlights-grid { grid-template-columns: 1fr; }
  .highlight-icon { width: 48px; height: 48px; }
  .pricing-credit-amount { font-size: 2.5rem; }
  .pricing-hero-title { font-size: 2rem; }
  /* 安全区块 H5 保持3列并排 */
  .security-section { padding: var(--space-4) var(--space-3); }
  .security-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .security-item { padding: var(--space-2) 6px; }
  .security-icon { width: 32px; height: 32px; border-radius: 8px; }
  .security-icon svg { width: 16px; height: 16px; }
  .security-label { font-size: 0.75rem; margin-bottom: 2px; }
  .security-desc { font-size: 0.6875rem; line-height: 1.4; }
}

@media (min-width: 1440px) {
  .section-container { max-width: 1200px; }
  .nav-container { max-width: 1200px; }
  .hero-title { font-size: 4rem; }
}

/* ==================== 登录弹窗 ==================== */
.login-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-5);
  animation: loginOverlayIn 0.25s ease;
}

@keyframes loginOverlayIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.login-modal-content {
  width: 100%;
  max-width: 420px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-radius: var(--radius-xl);
  padding: 40px 36px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.2);
  position: relative;
  z-index: 1;
  animation: loginModalIn 0.35s cubic-bezier(0.25, 1, 0.5, 1);
  max-height: 90vh;
  overflow-y: auto;
}

@keyframes loginModalIn {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.login-modal-close {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-raised);
  border: 1px solid var(--border-default);
  font-size: 1.75rem;
  line-height: 1;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--duration-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.login-modal-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  transform: rotate(90deg);
}

/* 登录弹窗内复用 Login.css 的样式 */
.login-modal-content .login-logo {
  text-align: center;
  margin-bottom: 28px;
}

.login-modal-content .login-logo-img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  object-fit: cover;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px rgba(13, 2, 33, 0.15);
}

.login-modal-content .login-logo h1 {
  font-size: 22px;
  font-weight: 800;
  color: #1a1a1a;
  letter-spacing: -0.02em;
}

.login-modal-content .login-logo p {
  font-size: 13px;
  color: #666;
  margin-top: 4px;
}

.login-modal-content .login-type-tabs {
  display: flex;
  margin-bottom: 24px;
  background: #f5f5f5;
  border-radius: 10px;
  padding: 4px;
}

.login-modal-content .login-type-tab {
  flex: 1;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 500;
  color: #666;
  border: none;
  background: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}

.login-modal-content .login-type-tab.active {
  background: #fff;
  color: #1a1a1a;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.login-modal-content .login-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.login-modal-content .login-input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.login-modal-content .login-input-group label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
}

.login-modal-content .login-field {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #e8e8e8;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-family: var(--font-primary);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
  box-sizing: border-box;
}

.login-modal-content .login-field:focus {
  border-color: #1a0a2e;
  box-shadow: 0 0 0 3px rgba(13, 2, 33, 0.08);
}

.login-modal-content .login-field::placeholder {
  color: #999;
}

.login-modal-content .login-code-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.login-modal-content .login-code-input {
  flex: 1 1 auto;
  min-width: 0;
}

.login-modal-content .login-send-code-btn {
  flex: 0 0 auto;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #1a0a2e;
  background: rgba(13, 2, 33, 0.06);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
  font-family: inherit;
  min-width: 84px;
}

.login-modal-content .login-send-code-btn:hover:not(:disabled) {
  background: rgba(13, 2, 33, 0.1);
}

.login-modal-content .login-send-code-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.login-modal-content .login-action-btn {
  width: 100%;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  background: #1a0a2e;
  border: none;
  border-radius: 980px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
  box-shadow: 0 4px 20px rgba(13, 2, 33, 0.15);
  transition: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
  font-family: inherit;
}

.login-modal-content .login-action-btn:hover:not(:disabled) {
  background: #0d0221;
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(13, 2, 33, 0.2);
}

.login-modal-content .login-action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.login-modal-content .login-error {
  color: #ef4444;
  font-size: 13px;
  text-align: center;
  min-height: 20px;
}

.login-modal-content .login-footer {
  text-align: center;
  margin-top: 20px;
  font-size: 12px;
  color: #999;
}

.login-modal-content .login-footer-link {
  color: #1a0a2e;
  text-decoration: none;
  font-weight: 500;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
  font-size: 12px;
}

.login-modal-content .login-footer-link:hover {
  text-decoration: underline;
}

@media (max-width: 480px) {
  .login-modal-overlay {
    padding: var(--space-3);
    align-items: flex-end;
  }
  .login-modal-content {
    padding: 32px 20px;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    max-height: 85vh;
    animation: loginModalInMobile 0.3s cubic-bezier(0.25, 1, 0.5, 1);
  }
  @keyframes loginModalInMobile {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
  }
  .login-modal-content .login-logo-img {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
  }
  .login-modal-content .login-logo h1 {
    font-size: 20px;
  }
}
.notifications-page {
  min-height: 100vh;
  background: #f5f6fa;
  display: flex;
  flex-direction: column;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.notifications-page.dark {
  background: #0f0f1a;
}

/* ===== Header ===== */
.notifications-header {
  background: #fff;
  border-bottom: 1px solid #eaeaf0;
  position: sticky;
  top: 0;
  z-index: 50;
}

.notifications-page.dark .notifications-header {
  background: #1a1a2e;
  border-bottom-color: #2a2a40;
}

.notifications-header-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.notifications-back {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: #555;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.notifications-page.dark .notifications-back {
  color: #aaa;
}

.notifications-back:hover {
  background: #f0f0f5;
}

.notifications-page.dark .notifications-back:hover {
  background: #252538;
}

.notifications-title {
  font-size: 17px;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0;
  letter-spacing: -0.01em;
}

.notifications-page.dark .notifications-title {
  color: #e8e8f0;
}

.notifications-header-spacer {
  flex: 1;
}

/* ===== Body ===== */
.notifications-body {
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
  padding: 24px;
  display: flex;
  gap: 20px;
  flex: 1;
}

/* ===== Sidebar ===== */
.notifications-sidebar {
  width: 220px;
  flex-shrink: 0;
  background: #fff;
  border-radius: 16px;
  padding: 20px 0;
  border: 1px solid #eaeaf0;
  display: flex;
  flex-direction: column;
  height: fit-content;
  position: sticky;
  top: 80px;
}

.notifications-page.dark .notifications-sidebar {
  background: #1a1a2e;
  border-color: #2a2a40;
}

.notifications-sidebar-header {
  padding: 4px 20px 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #1a1a2e;
}

.notifications-page.dark .notifications-sidebar-header {
  color: #e8e8f0;
}

.notifications-sidebar-header h2 {
  font-size: 15px;
  font-weight: 700;
  margin: 0;
  letter-spacing: -0.01em;
}

.notifications-sidebar-nav {
  flex: 1;
  padding: 0 10px;
}

.notifications-sidebar-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 13.5px;
  color: #555;
  transition: all 0.15s ease;
  text-align: left;
}

.notifications-page.dark .notifications-sidebar-item {
  color: #aaa;
}

.notifications-sidebar-item:hover {
  background: #f5f6fa;
}

.notifications-page.dark .notifications-sidebar-item:hover {
  background: #252538;
}

.notifications-sidebar-item.active {
  background: #f0edff;
  color: #5b4dbe;
  font-weight: 600;
}

.notifications-page.dark .notifications-sidebar-item.active {
  background: #2a2540;
  color: #9b8eff;
}

.notifications-sidebar-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0f0f5;
  color: #888;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.notifications-page.dark .notifications-sidebar-icon {
  background: #2a2a40;
  color: #999;
}

.notifications-sidebar-item.active .notifications-sidebar-icon {
  background: #5b4dbe;
  color: #fff;
}

.notifications-page.dark .notifications-sidebar-item.active .notifications-sidebar-icon {
  background: #6b5ce7;
}

.notifications-sidebar-label {
  flex: 1;
}

.notifications-sidebar-badge {
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  background: #ff4d6d;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  line-height: 1;
}

.notifications-sidebar-footer {
  padding: 14px 14px 0;
  border-top: 1px solid #eaeaf0;
  margin-top: 10px;
}

.notifications-page.dark .notifications-sidebar-footer {
  border-top-color: #2a2a40;
}

.notifications-mark-all {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 7px 10px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: #888;
  font-size: 12.5px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.notifications-page.dark .notifications-mark-all {
  color: #666;
}

.notifications-mark-all:hover:not(:disabled) {
  background: #f5f6fa;
  color: #555;
}

.notifications-page.dark .notifications-mark-all:hover:not(:disabled) {
  background: #252538;
  color: #aaa;
}

.notifications-mark-all:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

/* ===== Main ===== */
.notifications-main {
  flex: 1;
  background: #fff;
  border-radius: 16px;
  border: 1px solid #eaeaf0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 400px;
}

.notifications-page.dark .notifications-main {
  background: #1a1a2e;
  border-color: #2a2a40;
}

.notifications-main-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid #eaeaf0;
}

.notifications-page.dark .notifications-main-header {
  border-bottom-color: #2a2a40;
}

.notifications-main-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.notifications-main-title-group h2 {
  font-size: 15px;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0;
}

.notifications-page.dark .notifications-main-title-group h2 {
  color: #e8e8f0;
}

.notifications-main-badge {
  font-size: 11.5px;
  font-weight: 600;
  color: #7c3aed;
  background: #f0edff;
  padding: 2px 8px;
  border-radius: 6px;
}

.notifications-page.dark .notifications-main-badge {
  color: #9b8eff;
  background: #2a2540;
}

.notifications-filter {
  display: flex;
  gap: 2px;
  background: #f5f6fa;
  border-radius: 8px;
  padding: 3px;
}

.notifications-page.dark .notifications-filter {
  background: #252538;
}

.notifications-filter button {
  padding: 5px 14px;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: #888;
  font-size: 12.5px;
  cursor: pointer;
  transition: all 0.15s ease;
  font-weight: 500;
}

.notifications-page.dark .notifications-filter button {
  color: #666;
}

.notifications-filter button.active {
  background: #fff;
  color: #1a1a2e;
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.notifications-page.dark .notifications-filter button.active {
  background: #3a3a50;
  color: #e8e8f0;
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}

/* ===== List ===== */
.notifications-list {
  flex: 1;
  overflow-y: auto;
  padding: 6px;
}

.notifications-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
  position: relative;
}

.notifications-item:hover {
  background: #f8f8fc;
}

.notifications-page.dark .notifications-item:hover {
  background: #222236;
}

.notifications-item.unread {
  background: #faf8ff;
}

.notifications-page.dark .notifications-item.unread {
  background: #1e1c30;
}

.notifications-item.unread:hover {
  background: #f0edff;
}

.notifications-page.dark .notifications-item.unread:hover {
  background: #252240;
}

/* 未读红点 */
.notifications-item-dot {
  position: absolute;
  left: 8px;
  top: 22px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #7c3aed;
}

.notifications-page.dark .notifications-item-dot {
  background: #9b8eff;
}

/* 通知类型小图标 */
.notifications-item-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0edff;
  color: #7c3aed;
  flex-shrink: 0;
  margin-top: 2px;
}

.notifications-page.dark .notifications-item-icon {
  background: #2a2540;
  color: #9b8eff;
}

.notifications-item-content {
  flex: 1;
  min-width: 0;
}

.notifications-item-title {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0 0 5px;
  line-height: 1.4;
}

.notifications-page.dark .notifications-item-title {
  color: #e8e8f0;
}

.notifications-item.unread .notifications-item-title {
  font-weight: 700;
}

.notifications-item-desc {
  font-size: 13px;
  color: #888;
  margin: 0 0 8px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.notifications-page.dark .notifications-item-desc {
  color: #777;
}

.notifications-item-time {
  font-size: 12px;
  color: #bbb;
  display: flex;
  align-items: center;
}

.notifications-page.dark .notifications-item-time {
  color: #555;
}

/* ===== Empty & Loading ===== */
.notifications-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 20px 60px;
  gap: 8px;
}

.notifications-empty-icon {
  width: 64px;
  height: 64px;
  border-radius: 20px;
  background: #f5f6fa;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ccc;
  margin-bottom: 8px;
}

.notifications-page.dark .notifications-empty-icon {
  background: #252538;
  color: #444;
}

.notifications-empty-title {
  font-size: 15px;
  font-weight: 600;
  color: #555;
  margin: 0;
}

.notifications-page.dark .notifications-empty-title {
  color: #888;
}

.notifications-empty-desc {
  font-size: 13px;
  color: #aaa;
  margin: 0;
}

.notifications-page.dark .notifications-empty-desc {
  color: #555;
}

.notifications-loading-spinner {
  width: 28px;
  height: 28px;
  border: 3px solid #e8e8f0;
  border-top-color: #7c3aed;
  border-radius: 50%;
  animation: notifSpin 0.7s linear infinite;
}

.notifications-page.dark .notifications-loading-spinner {
  border-color: #2a2a40;
  border-top-color: #9b8eff;
}

@keyframes notifSpin {
  to { transform: rotate(360deg); }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .notifications-body {
    flex-direction: column;
    padding: 12px;
    gap: 12px;
  }

  .notifications-sidebar {
    width: 100%;
    position: static;
    flex-direction: row;
    align-items: center;
    padding: 10px 14px;
    gap: 10px;
    border-radius: 12px;
  }

  .notifications-sidebar-header {
    display: none;
  }

  .notifications-sidebar-nav {
    flex: 1;
    padding: 0;
  }

  .notifications-sidebar-item {
    width: auto;
    padding: 7px 12px;
  }

  .notifications-sidebar-footer {
    padding: 0;
    margin: 0;
    border: none;
  }

  .notifications-mark-all {
    padding: 7px;
    width: auto;
    font-size: 12px;
  }

  .notifications-main-header {
    padding: 12px 16px;
  }

  .notifications-item {
    padding: 14px 14px;
    gap: 10px;
  }

  .notifications-item-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
  }

  .notifications-item-icon svg {
    width: 14px;
    height: 14px;
  }

  .notifications-item-dot {
    left: 4px;
    top: 18px;
    width: 6px;
    height: 6px;
  }
}
.pay-page {
  min-height: 100vh;
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* 顶部导航 */
.pay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: #fff;
  border-bottom: 1px solid #f0f0f0;
  position: sticky;
  top: 0;
  z-index: 10;
  width: 100%;
  max-width: 680px;
  box-sizing: border-box;
}

.pay-header h1 {
  font-size: 17px;
  font-weight: 600;
  color: #1a1a1a;
  margin: 0;
}

.pay-back {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  color: #333;
  transition: background 0.2s;
}

.pay-back:hover {
  background: #f5f5f5;
}

/* Tab 切换 */
.pay-tabs {
  display: flex;
  background: #f5f5f5;
  border-radius: 12px;
  margin: 16px 16px 0;
  padding: 4px;
  gap: 4px;
  width: 100%;
  max-width: 680px;
  box-sizing: border-box;
}

.pay-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 400;
  color: #666;
  border: none;
  background: none;
  cursor: pointer;
  transition: all 0.2s;
  border-radius: 10px;
}

.pay-tab.active {
  font-weight: 600;
  color: #1a1a1a;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

/* 主体内容 */
.pay-body {
  flex: 1;
  padding: 16px;
  max-width: 680px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

/* 步骤标签 */
.pay-section-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 12px;
  letter-spacing: 0.02em;
}

/* 套餐网格 - PC 端 3 列固定 */
.pay-plan-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.pay-plan-card {
  position: relative;
  padding: 16px 8px;
  border-radius: 12px;
  border: 1.5px solid #f0f0f0;
  background: #fff;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  overflow: hidden;
}

.pay-plan-card:hover {
  border-color: #d0d0d0;
  background: #fafafa;
}

.pay-plan-card.selected {
  border-color: #1a1a1a;
  background: #fafafa;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.pay-plan-bonus {
  position: absolute;
  top: 0;
  right: 0;
  background: #1a1a1a;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 0 12px 0 8px;
}

.pay-plan-price {
  font-size: 22px;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 4px;
}

.pay-plan-points {
  font-size: 12px;
  color: #1a1a1a;
  font-weight: 600;
  margin-bottom: 2px;
}

.pay-plan-desc {
  font-size: 11px;
  color: #aaa;
}

/* 结算区 */
.pay-checkout {
  margin-top: 12px;
  padding: 20px;
  border-radius: 14px;
  border: 1px solid #f0f0f0;
  background: #fff;
}

.pay-checkout-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
}

.pay-checkout-label {
  font-size: 14px;
  color: #999;
}

.pay-checkout-value {
  font-size: 14px;
  color: #1a1a1a;
  font-weight: 500;
  display: flex;
  align-items: center;
}

.pay-checkout-price {
  font-size: 20px;
  font-weight: 700;
  color: #1a1a1a;
}

.pay-checkout-bonus {
  font-size: 14px;
  font-weight: 600;
  color: #f5a623;
}

.pay-checkout-divider {
  height: 1px;
  background: #f5f5f5;
  margin: 12px 0;
}

/* 支付按钮 */
.pay-btn {
  width: 100%;
  margin-top: 16px;
  padding: 14px 0;
  border: none;
  border-radius: 12px;
  background: #1a1a1a;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
}

.pay-btn:hover:not(:disabled) {
  background: #333;
}

.pay-btn:disabled {
  background: #e0e0e0;
  color: #bbb;
  cursor: not-allowed;
}

/* 安全提示 */
.pay-security {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 12px;
  color: #bbb;
  line-height: 1.5;
}

/* 错误提示 */
.pay-error {
  margin-top: 8px;
  padding: 10px 14px;
  border-radius: 8px;
  background: #fff0f0;
  color: #e74c3c;
  font-size: 13px;
}

/* 微信内提示 */
.pay-wechat-tip {
  margin-top: 12px;
  padding: 14px 16px;
  border-radius: 12px;
  background: #fffbf0;
  border: 1px solid #fde68a;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

/* 加载/空状态 */
.pay-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px;
  color: #999;
  font-size: 14px;
  gap: 8px;
}

.pay-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px;
  color: #999;
}

.pay-empty p {
  margin: 12px 0 0;
  font-size: 14px;
  color: #999;
}

/* 订单列表 */
.pay-order-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pay-order-card {
  padding: 16px;
  border-radius: 12px;
  border: 1px solid #f0f0f0;
  background: #fff;
}

.pay-order-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.pay-order-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pay-order-label {
  font-size: 14px;
  font-weight: 500;
  color: #1a1a1a;
}

.pay-order-bonus {
  font-size: 11px;
  color: #f5a623;
  background: #fff8e6;
  padding: 2px 6px;
  border-radius: 4px;
}

.pay-order-status {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 500;
}

.pay-order-meta {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #bbb;
}

.pay-order-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #f5f5f5;
}

.pay-order-btn {
  padding: 6px 12px;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  background: #fff;
  color: #666;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
}

.pay-order-btn:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

.pay-order-btn.danger {
  color: #e74c3c;
  border-color: #ffcccc;
}

.pay-order-btn.danger:hover {
  background: #fff0f0;
  border-color: #f5a6a6;
}

/* ==================== 深色模式 ==================== */

html[data-theme="dark"] .pay-page {
  background: #000;
}

html[data-theme="dark"] .pay-header {
  background: #1c1c1e;
  border-bottom-color: #38383a;
}

html[data-theme="dark"] .pay-header h1 {
  color: #ededf0;
}

html[data-theme="dark"] .pay-back {
  color: #8e8e93;
}

html[data-theme="dark"] .pay-back:hover {
  background: #2c2c2e;
  color: #ededf0;
}

/* Tab 深色 */
html[data-theme="dark"] .pay-tabs {
  background: #1c1c1e;
}

html[data-theme="dark"] .pay-tab {
  color: #8e8e93;
}

html[data-theme="dark"] .pay-tab.active {
  color: #ededf0;
  background: #2c2c2e;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

/* 步骤标签深色 */
html[data-theme="dark"] .pay-section-label {
  color: #ededf0;
}

/* 套餐卡片深色 */
html[data-theme="dark"] .pay-plan-card {
  border-color: #38383a;
  background: #1c1c1e;
}

html[data-theme="dark"] .pay-plan-card:hover {
  border-color: #48484a;
  background: #2c2c2e;
}

html[data-theme="dark"] .pay-plan-card.selected {
  border-color: #ededf0;
  background: #2c2c2e;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

html[data-theme="dark"] .pay-plan-bonus {
  background: #2c2c2e;
  color: #ededf0;
}

html[data-theme="dark"] .pay-plan-price {
  color: #ededf0;
}

html[data-theme="dark"] .pay-plan-points {
  color: #ededf0;
}

html[data-theme="dark"] .pay-plan-desc {
  color: #636366;
}

/* 结算区深色 */
html[data-theme="dark"] .pay-checkout {
  border-color: #38383a;
  background: #1c1c1e;
}

html[data-theme="dark"] .pay-checkout-label {
  color: #8e8e93;
}

html[data-theme="dark"] .pay-checkout-value {
  color: #c9c9cc;
}

html[data-theme="dark"] .pay-checkout-price {
  color: #ededf0;
}

html[data-theme="dark"] .pay-checkout-bonus {
  color: #d4a843;
}

html[data-theme="dark"] .pay-checkout-divider {
  background: #38383a;
}

/* 支付按钮深色 */
html[data-theme="dark"] .pay-btn {
  background: #0a84ff;
  color: #fff;
}

html[data-theme="dark"] .pay-btn:hover:not(:disabled) {
  background: #409cff;
}

html[data-theme="dark"] .pay-btn:disabled {
  background: #1c1c1e;
  color: #48484a;
}

/* 安全提示深色 */
html[data-theme="dark"] .pay-security {
  color: #48484a;
}

/* 错误提示深色 */
html[data-theme="dark"] .pay-error {
  background: rgba(220, 38, 38, 0.1);
  color: #f87171;
}

/* 微信内提示深色 */
html[data-theme="dark"] .pay-wechat-tip {
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.2);
}

/* 订单卡片深色 */
html[data-theme="dark"] .pay-order-card {
  border-color: #38383a;
  background: #1c1c1e;
}

html[data-theme="dark"] .pay-order-label {
  color: #ededf0;
}

html[data-theme="dark"] .pay-order-bonus {
  color: #d4a843;
  background: rgba(212, 168, 67, 0.1);
}

html[data-theme="dark"] .pay-order-meta {
  color: #48484a;
}

html[data-theme="dark"] .pay-order-actions {
  border-top-color: #38383a;
}

html[data-theme="dark"] .pay-order-btn {
  border-color: #38383a;
  background: #1c1c1e;
  color: #8e8e93;
}

html[data-theme="dark"] .pay-order-btn:hover {
  background: #2c2c2e;
  border-color: #48484a;
  color: #ededf0;
}

html[data-theme="dark"] .pay-order-btn.danger {
  color: #f87171;
  border-color: rgba(220, 38, 38, 0.2);
}

html[data-theme="dark"] .pay-order-btn.danger:hover {
  background: rgba(220, 38, 38, 0.1);
  border-color: rgba(220, 38, 38, 0.3);
}

/* 空状态深色 */
html[data-theme="dark"] .pay-empty p {
  color: #48484a;
}

/* 加载深色 */
html[data-theme="dark"] .pay-loading {
  color: #48484a;
}

/* 响应式 - H5 端 */
@media (max-width: 480px) {
  .pay-header {
    padding: 10px 12px;
  }

  .pay-tabs {
    margin: 12px 12px 0;
  }

  .pay-body {
    padding: 12px;
  }

  .pay-plan-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  .pay-plan-card {
    padding: 12px 6px;
  }

  .pay-plan-price {
    font-size: 18px;
  }

  .pay-plan-points {
    font-size: 11px;
  }

  .pay-checkout {
    padding: 16px;
  }

  .pay-checkout-row {
    padding: 6px 0;
  }
}

/* spin 动画 */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.spin {
  animation: spin 1s linear infinite;
}
/* === 全局重置 + 品牌色 === */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* 品牌紫 — 深紫黑系 */
  --brand-50: #f5f0ff;
  --brand-100: #ede5ff;
  --brand-200: #ddd0ff;
  --brand-300: #c4adff;
  --brand-400: #a78bfa;
  --brand-500: #5b21b6;
  --brand-600: #4a1a6b;
  --brand-700: #2d1655;
  --brand-800: #1a0a2e;
  --brand-900: #0d0221;
  --brand-950: #050110;

  /* 中性色 */
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;

  /* 功能色 */
  --success: #10b981;
  --error: #ef4444;
  --warning: #f59e0b;

  /* 圆角 */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  /* 字体 */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html, body, #root {
  height: 100%;
  width: 100%;
}

/* 去除浏览器默认点击闪蓝 */
* {
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
}

a, button, [role="button"], input, textarea, select {
  outline: none;
}

a:focus-visible, button:focus-visible, [role="button"]:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--brand-400);
  outline-offset: 2px;
  border-radius: 4px;
}

::selection {
  background: rgba(139, 92, 246, 0.2);
}

body {
  font-family: var(--font-sans);
  background: var(--gray-50);
  color: var(--gray-900);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* === 通用组件样式 === */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 24px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: linear-gradient(135deg, #1a0a2e, #0d0221);
  color: #fff;
  box-shadow: 0 2px 8px rgba(13, 2, 33, 0.3);
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(13, 2, 33, 0.4);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(0);
}

.btn-secondary {
  background: var(--gray-100);
  color: var(--gray-700);
}

.btn-secondary:hover:not(:disabled) {
  background: var(--gray-200);
}

.input {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-md);
  font-size: 15px;
  font-family: var(--font-sans);
  color: var(--gray-900);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.input:focus {
  border-color: var(--brand-500);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.12);
}

.input::placeholder {
  color: var(--gray-400);
}

/* === Markdown 渲染 === */
.markdown-body {
  font-size: 14px;
  line-height: 1.7;
  word-wrap: break-word;
}

.markdown-body p {
  margin-bottom: 8px;
}

.markdown-body p:last-child {
  margin-bottom: 0;
}

.markdown-body code {
  background: var(--gray-100);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 13px;
  font-family: 'SF Mono', 'Fira Code', monospace;
}

.markdown-body pre {
  background: var(--gray-900);
  color: var(--gray-100);
  padding: 16px;
  border-radius: var(--radius-md);
  overflow-x: auto;
  margin: 8px 0;
}

.markdown-body pre code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: 13px;
}

.markdown-body ul,
.markdown-body ol {
  padding-left: 20px;
  margin-bottom: 8px;
}

.markdown-body blockquote {
  border-left: 3px solid var(--brand-400);
  padding-left: 12px;
  color: var(--gray-600);
  margin: 8px 0;
}

.markdown-body a {
  color: var(--brand-600);
  text-decoration: none;
}

.markdown-body a:hover {
  text-decoration: underline;
}

.markdown-body table {
  border-collapse: collapse;
  width: 100%;
  margin: 8px 0;
}

.markdown-body th,
.markdown-body td {
  border: 1px solid var(--gray-200);
  padding: 8px 12px;
  text-align: left;
}

.markdown-body th {
  background: var(--gray-50);
  font-weight: 600;
}

.markdown-body img {
  max-width: 100%;
  border-radius: var(--radius-sm);
  min-height: 80px;
  background: var(--gray-100);
}

.markdown-body strong {
  font-weight: 700;
}

/* === 深色模式全局 === */
html[data-theme="dark"] body {
  background: #111114;
  color: #ededf0;
}

html[data-theme="dark"] .markdown-body code {
  background: rgba(255, 255, 255, 0.08);
  color: #ededf0;
}

html[data-theme="dark"] .markdown-body pre {
  background: #1e1e22;
  color: #ededf0;
}

html[data-theme="dark"] .markdown-body blockquote {
  border-left-color: rgba(139, 92, 246, 0.4);
  color: #9ca3af;
}

html[data-theme="dark"] .markdown-body a {
  color: #a78bfa;
}

html[data-theme="dark"] .markdown-body th,
html[data-theme="dark"] .markdown-body td {
  border-color: rgba(255, 255, 255, 0.08);
}

html[data-theme="dark"] .markdown-body th {
  background: #1e1e22;
}

/* === 动画 === */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.animate-fade-in {
  animation: fadeIn 0.3s ease-out;
}

.animate-pulse {
  animation: pulse 1.5s ease-in-out infinite;
}
