/* 前端样式文件 - 美化版 */
:root {
  --primary: #6366f1;
  --primary-light: #818cf8;
  --primary-dark: #4f46e5;
  --secondary: #8b5cf6;
  --accent: #1e293b;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --dark: #0f172a;
  --light: #f8fafc;
  --gray: #64748b;
  --gray-light: #94a3b8;
  --border: #e2e8f0;
  --gradient-primary: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  --gradient-success: linear-gradient(135deg, #10b981 0%, #34d399 100%);
  --gradient-danger: linear-gradient(135deg, #ef4444 0%, #f87171 100%);
  --gradient-warning: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --radius: 16px;
  --radius-sm: 8px;
  --margin-bg-tanchuang:rgba(70, 70, 70, 0.3);
}

* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(135deg, #f0f4ff 0%, #faf5ff 50%, #fff1f2 100%);
  color: var(--accent);
  line-height: 1.6;
  min-height: 100vh;
}

/* 现代化头部区域 */
.modern-header {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 24px;
  margin-bottom: 32px;
  align-items: start;
}



.user-info-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.leaderboard-section {
  display: flex;
  flex-direction: column;
}

.header-content {
  display: flex;
  gap: 20px;
  flex-direction: column;
}

/* 欢迎区域 */
.guest-welcome {
  background: var(--gradient-primary);
  border-radius: var(--radius);
  padding: 60px 40px;
  text-align: center;
  color: white;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.guest-welcome::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
  animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 0.5; }
  50% { transform: scale(1.1); opacity: 0.8; }
}

.welcome-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
}

.welcome-icon svg {
  width: 40px;
  height: 40px;
}

.welcome-title {
  font-size: 36px;
  font-weight: 700;
  margin: 0 0 12px 0;
  letter-spacing: -0.5px;
}

.welcome-subtitle {
  font-size: 16px;
  opacity: 0.95;
  margin: 0 0 32px 0;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.btn-modern {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 4px 4px;
  background: var(--main-bg-color);
  color: var(--primary);
  border-radius: calc(var(--radius) - 8px);
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
  border: none;
  cursor: pointer;
}

.btn-modern:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.btn-modern svg {
  width: 20px;
  height: 20px;
}

/* 用户仪表盘 */
.user-dashboard {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.user-card-modern {
  position: relative;
  background: var(--main-bg-color);
  border-radius: calc(var(--radius) + 4px);
  padding-bottom: 32px;
  box-shadow: 0 8px 32px rgba(99, 102, 241, 0.12), 0 2px 8px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(99, 102, 241, 0.08);
}

.user-card-modern:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(99, 102, 241, 0.2), 0 4px 16px rgba(0, 0, 0, 0.08);
  border-color: rgba(99, 102, 241, 0.2);
}

.user-card-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 140px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  opacity: 1;
  overflow: hidden;
}



.user-card-bg::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: linear-gradient(to top, var(--main-bg-color), transparent);
}

@keyframes bgRotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.user-card-content {
  position: relative;
  z-index: 1;
  margin: -60px 24px 16px 24px;
  display: flex;
  gap: 28px;
  align-items: center;
  padding: 24px;
  border-radius: calc(var(--radius) - 4px);
  backdrop-filter: blur(20px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.8);
  transition: all 0.3s ease;
}

.user-card-modern:hover .user-card-content {
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12), 0 4px 8px rgba(0, 0, 0, 0.06);
  border-color: rgba(99, 102, 241, 0.15);
}

.user-avatar-modern {
  position: relative;
  flex-shrink: 0;
}

.user-avatar-modern img {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 5px solid white;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15), 0 0 0 4px rgba(99, 102, 241, 0.1);
  transition: all 0.3s ease;
}

.user-card-modern:hover .user-avatar-modern img {
  transform: scale(1.05) rotate(-3deg);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2), 0 0 0 6px rgba(99, 102, 241, 0.15);
}

.avatar-ring {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 28px;
  height: 28px;
  background: linear-gradient(135deg, #10b981 0%, #34d399 100%);
  border-radius: 50%;
  border: 4px solid white;
  animation: ping 2s cubic-bezier(0, 0, 0.2, 1) infinite;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

@keyframes ping {
  75%, 100% {
    transform: scale(2);
    opacity: 0;
  }
}

.user-details {
  flex: 1;
  min-width: 0;
}

.user-name-modern {
  font-size: 30px;
  font-weight: 800;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0 0 18px 0;
  letter-spacing: -0.8px;
  line-height: 1.2;
  filter: drop-shadow(0 2px 4px rgba(102, 126, 234, 0.2));
}

.user-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.user-badges-row-1 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 14px;
}

.user-badges-row-2 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  align-items: stretch;
}

.user-badges-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 14px;
}



.badge-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-radius: calc(var(--radius) - 8px);
  font-size: 13px;
  font-weight: 600;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  justify-content: center;
  min-height: 68px;
  position: relative;
  overflow: hidden;
}

.badge-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.6s;
}

.badge-item:hover::before {
  left: 100%;
}

.badge-item:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
}

.badge-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.25);
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.badge-item:hover .badge-icon {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.badge-icon svg {
  width: 20px;
  height: 20px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
}

.badge-content {
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-align: center;
}

.badge-item:hover .badge-label {
  opacity: 1;
  letter-spacing: 1px;
}

.badge-item:hover .badge-value {
  transform: scale(1.05);
}

.badge-label {
  font-size: 11px;
  font-weight: 500;
  opacity: 0.9;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 2px;
}

.badge-value {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.badge-level {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: 1px solid rgba(102, 126, 234, 0.3);
}

.badge-quota {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  color: white;
  border: 1px solid rgba(79, 172, 254, 0.3);
}

.badge-daily {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  color: white;
  border: 1px solid rgba(79, 172, 254, 0.3);
}

.badge-exp {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  color: white;
  border: 1px solid rgba(240, 147, 251, 0.3);
}

.badge-points {
  background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
  color: white;
  border: 1px solid rgba(250, 112, 154, 0.3);
}

.badge-coins {
  background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
  color: #8b4513;
  border: 1px solid rgba(252, 182, 159, 0.3);
}

.badge-coins .badge-icon {
  background: rgba(139, 69, 19, 0.15);
}

.badge-exchange {
  background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  color: white;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-exchange .badge-icon {
  background: rgba(255, 255, 255, 0.25);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  transition: all 0.2s ease;
}

.badge:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(99, 102, 241, 0.2);
}

.badge svg {
  width: 18px;
  height: 22px;
}

.badge-level {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(239, 68, 68, 0.15));
  color: var(--success);
}

/* 行动卡片 */
.action-card {
  position: relative;
  background: var(--main-bg-color);
  border-radius: calc(var(--radius) - 4px);
  padding: 28px;
  display: flex;
  align-items: center;
  gap: 24px;
  box-shadow: 0 6px 24px rgba(99, 102, 241, 0.1), 0 2px 6px rgba(0, 0, 0, 0.04);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(99, 102, 241, 0.08);
  overflow: hidden;
}

.action-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: linear-gradient(180deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  transform: scaleY(0);
  transition: transform 0.4s ease;
}

.action-card:hover {
  box-shadow: 0 12px 40px rgba(99, 102, 241, 0.18), 0 4px 12px rgba(0, 0, 0, 0.08);
  border-color: rgba(99, 102, 241, 0.15);
  transform: translateX(8px);
}

.action-card:hover::before {
  transform: scaleY(1);
}

.action-icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: calc(var(--radius) - 8px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
  transition: all 0.3s ease;
}

.action-card:hover .action-icon {
  transform: scale(1.1) rotate(-5deg);
  box-shadow: 0 12px 36px rgba(102, 126, 234, 0.4);
}

.action-icon svg {
  width: 32px;
  height: 32px;
  color: white;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
}

.action-content {
  flex: 1;
}

.action-content h3 {
  margin: 0 0 6px 0;
  font-size: 20px;
  font-weight: 800;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.8px;
}

.action-content p {
  margin: 0;
  font-size: 14px;
  color: var(--main-color);
  opacity: 0.85;
  font-weight: 500;
}

.btn-primary-modern {
  background: var(--gradient-primary);
  color: white;
  padding: 12px 28px;
  font-size: 15px;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

.btn-primary-modern:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

/* 统计卡片 */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.stat-card {
  position: relative;
  background: var(--main-bg-color);
  border-radius: calc(var(--radius) - 4px);
  padding: 28px;
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: 0 6px 24px rgba(99, 102, 241, 0.1), 0 2px 6px rgba(0, 0, 0, 0.04);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  border: 1px solid rgba(99, 102, 241, 0.08);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  transform: scaleX(0);
  transition: transform 0.4s ease;
}

.stat-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 12px 40px rgba(99, 102, 241, 0.18), 0 4px 12px rgba(0, 0, 0, 0.08);
  border-color: rgba(99, 102, 241, 0.15);
}

.stat-card:hover::before {
  transform: scaleX(1);
}

.stat-icon {
  width: 64px;
  height: 64px;
  border-radius: calc(var(--radius) - 8px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
  transition: all 0.3s ease;
}

.stat-card:hover .stat-icon {
  transform: scale(1.1) rotate(-5deg);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.16);
}

.stat-icon svg {
  width: 32px;
  height: 32px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
}

.stat-icon-shares {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: 1px solid rgba(102, 126, 234, 0.3);
}

.stat-icon-value {
  background: linear-gradient(135deg, #10b981 0%, #34d399 100%);
  color: white;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.stat-icon-exp {
  background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  color: white;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.stat-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.stat-label {
  font-size: 13px;
  color: var(--main-color);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  opacity: 0.85;
}

.stat-value {
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.8px;
  line-height: 1.2;
}

.stat-card:hover .stat-value {
  transform: translateX(4px);
}

.stat-sub {
  font-size: 12px;
  color: var(--gray-light);
}

.exp-bar-container {
  width: 120px;
  height: 6px;
  background: rgba(99, 102, 241, 0.1);
  border-radius: 3px;
  overflow: hidden;
}

.exp-bar {
  height: 100%;
  background: var(--gradient-primary);
  border-radius: 3px;
  transition: width 0.5s ease;
}

/* 财富排行榜 */
.leaderboard-modern {
  position: relative;
  background: var(--main-bg-color);
  border-radius: calc(var(--radius) + 4px);
  padding: 0;
  box-shadow: 0 8px 32px rgba(99, 102, 241, 0.12), 0 2px 8px rgba(0, 0, 0, 0.04);
  position: sticky;
  height: fit-content;
  border: 1px solid rgba(99, 102, 241, 0.08);
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.leaderboard-modern:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(99, 102, 241, 0.2), 0 4px 16px rgba(0, 0, 0, 0.08);
  border-color: rgba(99, 102, 241, 0.15);
}

.leaderboard-header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 32px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  color: white;
  overflow: hidden;
}



@keyframes headerShine {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.leaderboard-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 22px;
  font-weight: 800;
  color: white;
  position: relative;
  z-index: 1;
  letter-spacing: -0.8px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.leaderboard-title svg {
  width: 32px;
  height: 32px;
  fill: white;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.view-all-link {
  font-size: 14px;
  color: white;
  text-decoration: none;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.3s ease;
  opacity: 0.9;
  position: relative;
  z-index: 1;
}

.view-all-link:hover {
  opacity: 1;
  transform: translateX(4px);
}

.view-all-link svg {
  width: 18px;
  height: 18px;
}

.leaderboard-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
}

.leaderboard-item {
  display: grid;
  grid-template-columns: 60px 1fr 130px;
  align-items: center;
  /* gap: 16px; */
  padding: 16px 20px;
  background: linear-gradient(135deg, #f8f9ff 0%, #fff 100%);
  border-radius: 16px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  /* border: 2px solid transparent; */
  position: relative;
  overflow: hidden;
}

.leaderboard-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
  transform: scaleY(0);
  transition: transform 0.3s ease;
}

.leaderboard-item:hover {
  background: linear-gradient(135deg, #fff 0%, #f8f9ff 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(102, 126, 234, 0.15);
  border-color: rgba(102, 126, 234, 0.2);
}

.leaderboard-item:hover::before {
  transform: scaleY(1);
}

.leaderboard-item.top-1 {
  background: linear-gradient(135deg, #fff9e6 0%, #fff5d6 100%);
  border-color: #ffd700;
  box-shadow: 0 4px 16px rgba(255, 215, 0, 0.2);
}

.leaderboard-item.top-1::before {
  background: linear-gradient(180deg, #ffd700 0%, #ffb700 100%);
  transform: scaleY(1);
}

.leaderboard-item.top-2 {
  background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
  border-color: #c0c0c0;
  box-shadow: 0 4px 16px rgba(192, 192, 192, 0.2);
}

.leaderboard-item.top-2::before {
  background: linear-gradient(180deg, #c0c0c0 0%, #a8a8a8 100%);
  transform: scaleY(1);
}

.leaderboard-item.top-3 {
  background: linear-gradient(135deg, #fff5eb 0%, #ffe8d6 100%);
  border-color: #cd7f32;
  box-shadow: 0 4px 16px rgba(205, 127, 50, 0.2);
}

.leaderboard-item.top-3::before {
  background: linear-gradient(180deg, #cd7f32 0%, #b87333 100%);
  transform: scaleY(1);
}

.rank-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  font-weight: 700;
  font-size: 18px;
  position: relative;
}

.rank-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  font-weight: 700;
  font-size: 16px;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.medal {
  font-size: 40px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
  animation: medalBounce 2s ease-in-out infinite;
}

@keyframes medalBounce {
  0%, 100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-6px) scale(1.1);
  }
}

.player-info {
  display: flex;
  align-items: center;
  gap: 14px;
}

.player-avatar {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  overflow: hidden;
  border: 3px solid rgba(102, 126, 234, 0.2);
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.leaderboard-item:hover .player-avatar {
  border-color: #667eea;
  transform: scale(1.08) rotate(-3deg);
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.3);
}

.player-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.player-name {
  font-weight: 600;
  color: #2d3748;
  text-decoration: none;
  font-size: 16px;
  transition: all 0.3s ease;
}

.player-name:hover {
  color: #667eea;
}

.player-score {
  font-size: 20px;
  font-weight: 700;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-align: right;
}

.empty-leaderboard {
  text-align: center;
  padding: 80px 20px;
  color: #718096;
}

.empty-leaderboard svg {
  width: 100px;
  height: 100px;
  margin-bottom: 24px;
  opacity: 0.3;
  color: #667eea;
}

.empty-leaderboard p {
  margin: 0;
  font-size: 16px;
  opacity: 0.8;
}

/* 倒计时定时器 */
.countdown-timer {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.08));
  border-radius: var(--radius-sm);
  padding: 20px 24px;
  margin: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid rgba(99, 102, 241, 0.2);
}

.countdown-display {
  font-size: 28px;
  font-weight: 700;
  font-family: 'SF Mono', Monaco, monospace;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  padding: 8px 20px;
  border-radius: var(--radius-sm);
}

.invest-platform {
  max-width: 1400px;
  margin: 0 auto;
  padding: 32px 24px;
  position: relative;
  z-index: 1;
}

/* 确保投资平台的所有子元素不会遮挡其他页面元素 */
.invest-platform * {
  position: relative;
  z-index: 1;
}

/* 页面标题 */
.page-header {
  text-align: center;
  margin-bottom: 40px;
  padding: 60px 30px;
  background: var(--gradient-primary);
  border-radius: var(--radius);
  color: white;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.page-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.3;
}

.page-header::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%);
  animation: rotate 20s linear infinite;
}

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

.page-header h1 {
  font-size: 42px;
  font-weight: 800;
  margin: 0 0 16px 0;
  letter-spacing: -1px;
  position: relative;
  z-index: 1;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.page-header p {
  font-size: 18px;
  opacity: 0.95;
  margin: 0;
  position: relative;
  z-index: 1;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* 卡片设计 - 统一现代化风格 */
.card-gupian {
  position: relative;
  background: var(--main-bg-color);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: 0 8px 32px rgba(99, 102, 241, 0.12), 0 2px 8px rgba(0, 0, 0, 0.04);
  margin-bottom: 32px;
  overflow: hidden;
  border: 1px solid rgba(99, 102, 241, 0.08);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(10px);
}

.card-gupian:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(99, 102, 241, 0.2), 0 4px 16px rgba(0, 0, 0, 0.08);
  border-color: rgba(99, 102, 241, 0.2);
}

.card-gupian-header {
  position: relative;
  padding: 28px 32px;
  border-bottom: 2px solid rgba(99, 102, 241, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  color: white;
  gap: 16px;
  overflow: hidden;
}


@keyframes headerShine {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.card-gupian-title {
  font-size: 22px;
  font-weight: 800;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  letter-spacing: -0.8px;
  position: relative;
  z-index: 1;
}

.card-gupian-title i,
.card-gupian-title svg {
  width: 24px;
  height: 24px;
  filter: drop-shadow(0 2px 4px rgba(102, 126, 234, 0.2));
}

.card-gupian-body {
  padding: 32px;
  position: relative;
}

/* 用户信息卡片 */
.user-profile {
  display: flex;
  align-items: center;
  gap: 20px;
}

.user-avatar {
  position: relative;
}

.user-avatar img {
  border-radius: 50%;
  border: 3px solid var(--primary);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}

.user-avatar::after {
  content: '';
  position: absolute;
  bottom: 5px;
  right: 5px;
  width: 16px;
  height: 16px;
  background: var(--success);
  border-radius: 50%;
  border: 2px solid white;
}

.user-info {
  flex: 1;
}

.user-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--main-color);
  margin: 0 0 8px 0;
}

.user-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.stat-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--gradient-primary);
  color: white;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: var(--shadow-sm);
}

.stat-badge.success {
  background: var(--gradient-success);
}

.stat-badge.warning {
  background: var(--gradient-warning);
}

/* 资产网格 */
.assets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.asset-card-gupian {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
  border-radius: var(--radius-sm);
  padding: 20px;
  text-align: center;
  border: 1px solid rgba(99, 102, 241, 0.2);
  transition: all 0.3s ease;
}

.asset-card-gupian:hover {
  transform: scale(1.02);
  border-color: var(--primary);
}

.asset-label {
  font-size: 13px;
  color: var(--main-color);
  margin-bottom: 8px;
}

.asset-value {
  font-size: 28px;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 财富排行榜 */
.caifu {
  min-width: 320px;
}

.ranking-table {
  width: 100%;
}

.ranking-item {
  display: flex;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
}

.ranking-item:hover {
  background: rgba(99, 102, 241, 0.05);
  margin: 0 -16px;
  padding-left: 16px;
  padding-right: 16px;
}

.ranking-item:last-child {
  border-bottom: none;
}

.ranking-position {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-right: 12px;
}

.ranking-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 12px;
}

.ranking-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ranking-info {
  flex: 1;
}

.ranking-name {
  font-weight: 600;
  color: var(--main-color);
}

.ranking-wealth {
  font-size: 13px;
  color: var(--main-color);
}

.ranking-score {
  font-size: 16px;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 按钮样式 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  margin: 2px;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.6s;
}

.btn:hover::before {
  left: 100%;
}

.btn i,
.btn svg {
  width: 18px;
  height: 18px;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.4);
}

.btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.5);
}

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

.btn-danger {
  background: var(--gradient-danger);
  color: white;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.4);
}

.btn-danger:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 24px rgba(239, 68, 68, 0.5);
}

.btn-success {
  background: var(--gradient-success);
  color: white;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.btn-success:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.5);
}

.btn-warning {
  background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  color: white;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
}

.btn-warning:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.5);
}

.btn-secondary {
  background: linear-gradient(135deg, #64748b 0%, #94a3b8 100%);
  color: white;
  background-color: red;
  box-shadow: 0 4px 14px rgba(100, 116, 139, 0.3);
}

.btn-secondary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 24px rgba(100, 116, 139, 0.4);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

.btn-exchange {
  background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
  border-radius: 16px;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 500;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  width: 100%;
}

.btn-exchange:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(245, 158, 11, 0.5);
}

/* 表格样式 */
.data-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  padding: 15px;
}

.data-table thead {
  background: var(--gradient-primary);
  color: white;
  position: sticky;
  top: 0;
  z-index: 10;
}

.data-table th {
  padding: 18px 20px;
  text-align: center;
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.data-table th:first-child {
  border-radius: var(--radius-sm) 0 0 0;
}

.data-table th:last-child {
  border-radius: 0 var(--radius-sm) 0 0;
}

.data-table td {
  padding: 20px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  font-size: 15px;
  text-align: center;
}

.data-table tbody tr {
  transition: all 0.3s ease;
}

.data-table tbody tr:hover {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(139, 92, 246, 0.08) 100%);
  transform: scale(1.01);
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

.data-table code {
  display: inline-block;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
  border-radius: 6px;
  font-family: 'SF Mono', Monaco, monospace;
  font-size: 13px;
  color: var(--primary);
  font-weight: 600;
}

/* 价格样式 */
.price-up {
  color: var(--danger);
  font-weight: 600;
}

.price-down {
  color: var(--success);
  font-weight: 600;
}

.price-value {
  font-size: 16px;
  font-weight: 700;
}

/* 交易类型标签样式 */
.type-label {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.type-label.label-buy {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: white;
}

.type-label.label-normal {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: white;
}

.type-label.label-pledge {
  background: linear-gradient(135deg, #3b82f6, #60a5fa);
  color: white;
}

.type-label.label-short {
  background: linear-gradient(135deg, #f97316, #fb923c);
  color: white;
}

/* 事件卡片 */
.event-card {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--radius) - 8px);
  padding: 24px;
  margin-bottom: 0;
  box-shadow: 0 6px 24px rgba(99, 102, 241, 0.1), 0 2px 6px rgba(0, 0, 0, 0.04);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(99, 102, 241, 0.08);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.events-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 0;
}

.events-grid .event-card:last-child {
  margin-bottom: 0;
}

.event-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
  transform: scaleY(0);
  transition: transform 0.4s ease;
}

.event-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(99, 102, 241, 0.18), 0 4px 12px rgba(0, 0, 0, 0.08);
  border-color: rgba(99, 102, 241, 0.15);
}

.event-card:hover::before {
  transform: scaleY(1);
}

.event-card.positive {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.06) 0%, rgba(255, 255, 255, 1) 100%);
  border-left: 4px solid var(--danger);
}

.event-card.negative {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.06) 0%, rgba(255, 255, 255, 1) 100%);
  border-left: 4px solid var(--success);
}

.event-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 12px;
  gap: 12px;
}

.event-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--main-color);
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  flex: 1;
}

.event-impact {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 700;
  backdrop-filter: blur(10px);
}

.event-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border-radius: 16px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.event-badge.positive {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
}

.event-badge.negative {
  background: rgba(16, 185, 129, 0.15);
  color: var(--success);
}

.event-content {
  font-size: 14px;
  color: var(--main-color);
  margin-bottom: 12px;
  line-height: 1.6;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.event-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--gray-light);
  flex-wrap: wrap;
}

.event-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.event-category {
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
  color: var(--primary);
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid rgba(99, 102, 241, 0.2);
  transition: all 0.2s ease;
}

.event-category:hover {
  background: var(--gradient-primary);
  color: white;
  transform: translateY(-2px);
}

.event-progress {
  width: 100%;
  height: 6px;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 3px;
  overflow: hidden;
  margin-top: auto;
}

.event-progress-bar {
  height: 100%;
  transition: width 0.5s ease;
  position: relative;
  overflow: hidden;
}

.event-progress-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  from { transform: translateX(-100%); }
  to { transform: translateX(100%); }
}

.event-time {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--main-color);
  background: rgba(0, 0, 0, 0.03);
  padding: 4px 10px;
  border-radius: 10px;
  white-space: nowrap;
}

.event-time i,
.event-time svg {
  width: 14px;
  height: 14px;
}

/* 倒计时样式 */
.countdown-bar {
  margin-bottom: 20px;
  padding: 20px 28px;
  background: var(--gradient-primary);
  border-radius: var(--radius-sm);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
  position: relative;
  overflow: hidden;
}

.countdown-bar::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
  animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 0.5; }
  50% { transform: scale(1.1); opacity: 0.8; }
}

.countdown-label {
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 1;
  font-size: 16px;
}

.countdown-time {
  font-size: 28px;
  font-weight: 700;
  font-family: 'SF Mono', Monaco, monospace;
  background: rgba(255, 255, 255, 0.25);
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  backdrop-filter: blur(10px);
  position: relative;
  z-index: 1;
  letter-spacing: 1px;
}

/* 图表容器 */
.chart-container {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.03) 0%, rgba(139, 92, 246, 0.03) 100%);
  border-radius: var(--radius-sm);
  padding: 2px;
  min-height: 350px;
  max-height: 500px;
  border: 1px solid rgba(99, 102, 241, 0.15);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.03);
}

/* 空状态 */
.empty-state {
  padding: 80px 40px;
  text-align: center;
  color: var(--main-color);
}

.empty-state i,
.empty-state svg {
  width: 64px;
  height: 64px;
  margin-bottom: 20px;
  opacity: 0.4;
}

.empty-state-icon {
  font-size: 64px;
  margin-bottom: 20px;
  opacity: 0.4;
}

.empty-state-text {
  font-size: 16px;
  margin: 0;
}

.empty-state-mini {
  text-align: center;
  padding: 40px;
  color: var(--main-color);
}

/* 购买弹窗样式 */
.modal1 {
  display: none;
  position: fixed;
  z-index: 10000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: var(--margin-bg-tanchuang);
  /* backdrop-filter: blur(20px) saturate(180%); */
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  animation: modalFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  align-items: center;
  justify-content: center;
}

.modal1.show {
  display: flex !important;
}

.modal1 > div {
  background: var(--main-bg-color);
  border-radius: 24px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  box-shadow: 0 1px 3px -1px rgb(0 5 255 / 25%), 0 0 0 1px rgb(22 24 121 / 10%), inset 0 1px 0 rgb(138 52 52 / 10%);
  overflow: hidden;
  animation: modalSlideUp 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex;
  flex-direction: column;
  position: relative;
}

.modal1 > div::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #3b82f6, #2563eb, #60a5fa, #3b82f6);
  background-size: 300% 100%;
  animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.modal1 > div form {
  padding: 28px 32px;
  overflow-y: auto;
  flex: 1;
  -webkit-overflow-scrolling: touch;
}

/* 宽版弹窗样式 */
#short-modal > div {
  max-width: 600px;
}

#short-modal .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

#short-modal .form-group {
  margin-bottom: 16px;
}

/* 购买弹窗标题颜色 */
#buy-modal h3 {
  color: var(--primary);
}

/* 积分兑换弹窗标题颜色 */
#exchange-modal h3 {
  color: var(--primary);
}

/* 做空弹窗标题颜色 */
#short-modal h3 {
  color: #dc3545;
}

.modal1-header {
  padding: 28px 32px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.modal1-header::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 60%);
  animation: rotate 20s linear infinite;
}

.modal1-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
}

.modal1-header h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  position: relative;
  z-index: 1;
  letter-spacing: -0.3px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.close {
  color: white;
  font-size: 28px;
  font-weight: 300;
  cursor: pointer;
  opacity: 0.9;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  position: relative;
  z-index: 1;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
}

.close:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.25);
  transform: rotate(90deg) scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.modal1-body {
  padding: 28px;
}

.form-group {
  margin-bottom: 22px;
}

.form-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-weight: 600;
  color: var(--main-color);
  font-size: 14px;
}

.form-group label i {
  color: var(--primary);
  font-size: 17px;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid var(--border);
  border-radius: 12px;
  font-size: 15px;
  font-weight: 500;
  transition: all 0.25s ease;
  background: var(--main-bg-color);
  height: 50px;
  box-sizing: border-box;
}

.form-group input::placeholder {
  color: var(--gray);
  font-weight: 400;
}

.form-group small {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  color: var(--gray);
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.form-group input[readonly] {
  background: rgba(0,0,0,0.02);
  color: var(--gray);
  cursor: not-allowed;
}

/* 管理员面板 */
.admin-panel {
  border: 2px solid rgba(99, 102, 241, 0.2) !important;
  box-shadow: 0 8px 32px rgba(99, 102, 241, 0.15), 0 2px 8px rgba(0, 0, 0, 0.06);
}

.admin-panel:hover {
  border-color: rgba(99, 102, 241, 0.3) !important;
  box-shadow: 0 16px 48px rgba(99, 102, 241, 0.25), 0 4px 16px rgba(0, 0, 0, 0.1);
}

.admin-panel .card-gupian-header {
  /* 继承普通卡片的头部样式 */
}

.admin-panel .card-gupian-title {
  color: white;
  -webkit-text-fill-color: white;
}

.admin-controls {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.cron-status {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.03), rgba(139, 92, 246, 0.03));
  padding: 20px;
  border-radius: var(--radius-sm);
  margin-top: 20px;
  border: 1px solid rgba(99, 102, 241, 0.15);
}

.cron-status h4 {
  margin-top: 0;
  margin-bottom: 16px;
  font-size: 15px;
  color: var(--main-color);
  font-weight: 700;
}

.cron-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.cron-item {
  padding: 16px;
  background: var(--main-bg-color);
  border-radius: var(--radius-sm);
  border-left: 5px solid var(--success);
  font-size: 14px;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.cron-item:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow);
}

.cron-item.inactive {
  border-left-color: var(--danger);
}

/* 市场动态滚动展示 */
.ticker-wrapper {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.06) 0%, rgba(139, 92, 246, 0.06) 100%);
  border-radius: var(--radius-sm);
  padding: 20px;
  overflow: hidden;
  border: 1px solid rgba(99, 102, 241, 0.15);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.03);
  height: 300px;
  position: relative;
}

.ticker-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: vertical-scroll 60s linear infinite;
  padding-bottom: 20px;
  transition: animation-play-state 0.3s ease;
}

.ticker-wrapper:hover .ticker-list {
  animation-play-state: paused;
}

.ticker-wrapper {
  overflow-y: auto;
}

/* 自定义滚动条 */
.ticker-wrapper::-webkit-scrollbar {
  width: 6px;
}

.ticker-wrapper::-webkit-scrollbar-track {
  background: rgba(99, 102, 241, 0.1);
  border-radius: 10px;
}

.ticker-wrapper::-webkit-scrollbar-thumb {
  background: rgba(99, 102, 241, 0.5);
  border-radius: 10px;
}

.ticker-wrapper::-webkit-scrollbar-thumb:hover {
  background: rgba(99, 102, 241, 0.7);
}

.ticker-item {
  font-size: 15px;
  color: var(--main-color);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--main-bg-color);
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  border-left: 3px solid var(--primary);
}

@keyframes vertical-scroll {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(-100%);
  }
}

/* 投资说明 */
.investment-guide {
  counter-reset: guide-counter;
}

.investment-guide li {
  margin-bottom: 16px;
  padding-left: 12px;
  position: relative;
  font-size: 15px;
  line-height: 1.7;
}

.investment-guide li::before {
  counter-increment: guide-counter;
  content: counter(guide-counter);
  position: absolute;
  left: -18px;
  top: 2px;
  width: 24px;
  height: 24px;
  background: var(--gradient-primary);
  color: white;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* 融资融券样式 */
.finance-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
  flex-wrap: wrap;
  border-bottom: 2px solid var(--border);
  padding-bottom: 16px;
}

.finance-tab {
  padding: 12px 20px;
  border: none;
  background: var(--main-bg-color);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  color: var(--main-color);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.finance-tab::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.finance-tab:hover {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
}

.finance-tab.active {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
}

.finance-tab.active::before {
  transform: scaleX(1);
}

.finance-tab-content {
  display: none;
}

.finance-tab-content.active {
  display: block;
  animation: fadeIn 0.4s ease;
}

.finance-info-box {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
  padding: 24px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.06) 0%, rgba(139, 92, 246, 0.06) 100%);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(99, 102, 241, 0.15);
}

.info-item {
  text-align: center;
  padding: 16px;
  background: var(--main-bg-color);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.info-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.info-label {
  display: block;
  font-size: 13px;
  color: var(--main-color);
  margin-bottom: 8px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.info-value {
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
  display: block;
}

.finance-form-inline {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.finance-calc-result {
  display: flex;
  gap: 24px;
  margin-top: 16px;
  padding: 16px 20px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.06), rgba(139, 92, 246, 0.06));
  border-radius: var(--radius-sm);
  font-size: 15px;
  border: 1px solid rgba(99, 102, 241, 0.15);
}

.finance-calc-result strong {
  color: var(--primary);
  font-size: 18px;
}

.finance-table-wrap {
  overflow-x: auto;
}

.finance-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.finance-table th,
.finance-table td {
  padding: 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.finance-table th {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.08));
  font-weight: 700;
  color: var(--main-color);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.finance-table tr {
  transition: all 0.2s ease;
}

.finance-table tr:hover {
  background: rgba(99, 102, 241, 0.03);
  transform: scale(1.01);
}

.danger-row {
  background: rgba(34, 197, 94, 0.08) !important;
  animation: danger-flash 2s infinite;
}

.expired-row {
  background: rgba(239, 68, 68, 0.15) !important;
  animation: expired-flash 1.5s infinite;
}

.warning-row {
  background: rgba(245, 158, 11, 0.1) !important;
}

.interest-warning-row {
  background: rgba(139, 92, 246, 0.1) !important;
}

.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  margin-left: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-danger {
  background: var(--gradient-danger);
  color: white;
}

.badge-warning {
  background: var(--gradient-warning);
  color: white;
}

.badge-interest {
  background: var(--gradient-primary);
  color: white;
}

@keyframes danger-flash {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
  }
  50% {
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.3);
  }
}

@keyframes expired-flash {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0);
  }
  50% {
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.4);
  }
}

.status-liquidated {
  background: rgba(220, 53, 69, 0.1) !important;
  color: var(--danger) !important;
  font-weight: 600;
}

.status-forced-sell {
  background: rgba(255, 193, 7, 0.1) !important;
  color: var(--warning) !important;
  font-weight: 600;
}

.text-red {
  color: var(--danger) !important;
  font-weight: 600;
}

.text-green {
  color: var(--success) !important;
  font-weight: 600;
}

.text-blue {
  color: var(--primary) !important;
  font-weight: 600;
}

.empty-state-mini {
  text-align: center;
  padding: 40px;
  color: var(--main-color);
}

.btn-danger {
  background: var(--gradient-danger) !important;
  border: none !important;
  color: white !important;
}

.btn-danger:hover {
  opacity: 0.9;
}

.btn-sm {
  padding: 8px 16px !important;
  font-size: 13px !important;
}

/* 响应式设计 - 重新组织 */

/* 大屏幕 (1200px以上) - 默认布局 */
/* 现代头部：左侧用户信息 + 右侧排行榜 */

/* 中等屏幕 (1024px - 1199px) */
@media (max-width: 1199px) {
  .modern-header {
    grid-template-columns: 1fr 360px;
    gap: 20px;
  }
}

/* 平板横屏/小桌面 (768px - 1023px) */
@media (max-width: 1023px) {
  .caifu {
    min-width: auto;
  }
  
  .modern-header {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .leaderboard-modern {
    position: relative;
    top: 0;
    max-width: 100%;
  }
  
  /* 用户信息区域改为横向布局 */
  .user-card-content {
    flex-direction: row;
    align-items: flex-start;
    text-align: left;
    gap: 20px;
    padding: 20px;
    margin: -50px 18px 14px 18px;
  }
  
  .user-details {
    flex: 1;
    min-width: 0;
  }
  
  /* 徽章保持 3 列但减小间距 */
  .user-badges-row-1,
  .user-badges-row-2,
  .user-badges-row {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }
  
  .badge-item {
    padding: 12px 14px;
    min-height: 62px;
  }
  
  .badge-label {
    font-size: 10px;
  }
  
  .badge-value {
    font-size: 13px;
  }
  
  .user-avatar-modern img {
    width: 76px;
    height: 76px;
  }
  
  .user-name-modern {
    font-size: 24px;
  }
}

/* 平板竖屏 (600px - 767px) */
@media (max-width: 767px) {
  .invest-platform {
    padding: 16px;
  }
  
  .modern-header {
    gap: 16px;
  }
  
  /* 用户信息改为垂直布局 */
  .user-card-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 20px;
    margin: -45px 16px 12px 16px;
    padding: 20px;
  }
  
  .user-avatar-modern img {
    width: 80px;
    height: 80px;
  }
  
  .user-name-modern {
    font-size: 22px;
  }
  
  /* 徽章改为 2 列布局 */
  .user-badges-row-1,
  .user-badges-row-2,
  .user-badges-row {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 10px;
  }
  
  .badge-item {
    min-height: 58px;
    padding: 20px 20px;
  }
  
  .badge-icon {
    width: 30px;
    height: 30px;
  }
  
  .badge-icon svg {
    width: 16px;
    height: 16px;
  }
  
  .badge-label {
    font-size: 10px;
  }
  
  .badge-value {
    font-size: 13px;
  }
  
  .header-content {
    gap: 16px;
  }
  
  .page-header {
    padding: 30px 16px;
  }
  
  .page-header h1 {
    font-size: 24px;
  }
  
  .page-header p {
    font-size: 14px;
  }
  
  .card-gupian-body {
    padding: 3px;
  }
  
  .card-gupian-header {
    padding: 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  
  .user-profile {
    flex-direction: column;
    text-align: center;
  }
  
  .user-stats {
    justify-content: center;
  }
  
  .user-badges {
    justify-content: center;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .assets-grid {
    grid-template-columns: 1fr;
  }
  
  .events-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .events-grid .event-card {
    margin-bottom: 0;
  }
  
  /* 表格优化 */
  .data-table thead {
    display: none;
  }
  
  .data-table tr {
    display: block;
    margin-bottom: 20px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 20px;
    background: var(--main-bg-color);
  }
  
  .data-table td {
    display: flex;
    justify-content: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
  }
  
  .data-table td:last-child {
    border-bottom: none;
    padding-top: 14px;
    justify-content: center;
  }
  
  .data-table td::before {
    content: attr(data-label);
    font-weight: 700;
    color: var(--main-color);
    margin-right: 12px;
    text-transform: uppercase;
    font-size: 12px;
  }
  
  .btn {
    width: 100%;
    margin: 6px 0;
    padding: 14px 20px;
  }
  
  .countdown-bar {
    flex-direction: column;
    gap: 12px;
    text-align: center;
    padding: 20px;
  }
  
  .countdown-time {
    font-size: 24px;
    padding: 8px 16px;
  }
  
  .event-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  
  .event-impact {
    width: 100%;
    justify-content: center;
  }
  
  .event-categories {
    flex-wrap: wrap;
  }
  
  .admin-controls {
    flex-direction: column;
  }
  
  .cron-grid {
    grid-template-columns: 1fr;
  }
  
  .finance-tabs {
    flex-direction: column;
  }
  
  .finance-tab {
    width: 100%;
  }
  
  .finance-info-box {
    grid-template-columns: 1fr;
  }
  
  .ticker-wrapper {
    padding: 16px;
  }
  
  .ticker-icon {
    font-size: 20px;
  }
  
  .ticker-list {
    gap: 20px;
  }
  
  .ticker-item {
    font-size: 13px;
    padding: 6px 12px;
  }
}

/* 手机小屏幕 (480px 以下) */
@media (max-width: 200px) {
  .invest-platform {
    padding: 12px;
  }
  
  .card-gupian {
    margin-bottom: 20px;
    border-radius: 12px;
  }
  
  .page-header {
    padding: 24px 12px;
  }
  
  .page-header h1 {
    font-size: 22px;
  }
  
  .welcome-title {
    font-size: 24px;
  }
  
  .welcome-subtitle {
    font-size: 13px;
  }
  
  /* 用户卡片小屏幕优化 */
  .user-card-bg {
    height: 100px;
  }
  
  .user-card-content {
    margin: -40px 12px 12px 12px;
    gap: 16px;
    padding: 16px;
  }
  
  .user-avatar-modern img {
    width: 70px;
    height: 70px;
    border-width: 4px;
  }
  
  .avatar-ring {
    width: 22px;
    height: 22px;
    border-width: 3px;
  }
  
  .user-name-modern {
    font-size: 20px;
  }
  
  /* 徽章单列布局 */
  .user-badges-row-1,
  .user-badges-row-2,
  .user-badges-row {
    grid-template-columns: 1fr;
    gap: 8px;
    margin-bottom: 8px;
  }
  
  .badge-item {
    min-height: 52px;
    padding: 10px 14px;
    flex-direction: row;
    justify-content: flex-start;
    gap: 12px;
  }
  
  .badge-icon {
    width: 32px;
    height: 32px;
  }
  
  .badge-icon svg {
    width: 16px;
    height: 16px;
  }
  
  .badge-content {
    flex-direction: row;
    align-items: center;
    gap: 10px;
    flex: 1;
    justify-content: space-between;
  }
  
  .badge-label {
    font-size: 11px;
  }
  
  .badge-value {
    font-size: 14px;
  }
  
  .badge1 {
    padding: 6px 12px;
    font-size: 13px;
  }
  
  /* 统计卡片 */
  .stats-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  
  .stat-card {
    padding: 14px;
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }
  
  .stat-icon {
    width: 44px;
    height: 44px;
  }
  
  .stat-icon svg {
    width: 22px;
    height: 22px;
  }
  
  .stat-value {
    font-size: 20px;
  }
  
  .stat-label {
    font-size: 12px;
  }
  
  .assets-grid {
    grid-template-columns: 1fr;
  }
  
  .asset-value {
    font-size: 22px;
  }
  
  /* 排行榜小屏幕优化 */
  .leaderboard-modern {
    padding: 0;
    border-radius: 16px;
  }
  
  .leaderboard-header {
    padding: 16px 18px;
  }
  
  .leaderboard-title {
    font-size: 16px;
    gap: 8px;
  }
  
  .leaderboard-title svg {
    width: 22px;
    height: 22px;
  }
  
  .ranking-tabs {
    padding: 8px 12px !important;
  }
  
  .ranking-tab {
    padding: 8px 12px;
    font-size: 13px;
  }
  
  .ranking-tab i {
    display: none;
  }
  
  .leaderboard-list {
    padding: 12px;
    gap: 8px;
  }
  
  .leaderboard-item {
    grid-template-columns: 40px 1fr 80px;
    padding: 12px 14px;
    gap: 12px;
  }
  
  .rank-badge {
    width: 40px;
    height: 40px;
  }
  
  .rank-number {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }
  
  .medal {
    font-size: 32px;
  }
  
  .player-avatar {
    width: 40px;
    height: 40px;
    border-width: 2px;
  }
  
  .player-name {
    font-size: 14px;
  }
  
  .player-score {
    font-size: 16px;
  }
  
  .modal-content {
    width: 95%;
    margin: 15% auto;
  }
  
  .modal1-header {
    padding: 20px;
  }
  
  .modal1-body {
    padding: 20px;
  }
  
  .countdown-time {
    font-size: 20px;
    padding: 6px 12px;
  }
  
  .event-card {
    padding: 16px;
  }
  
  .event-title {
    font-size: 16px;
  }
  
  .event-impact {
    font-size: 12px;
    padding: 4px 10px;
  }
}

/* ==================== 弹窗样式全面美化 ==================== */

/* 基础弹窗遮罩层 */
.jninvest-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--margin-bg-tanchuang);
  /* backdrop-filter: blur(20px) saturate(180%); */
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  padding: 20px;
  box-sizing: border-box;
  animation: modalFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* 弹窗内容容器 */
.jninvest-modal > div {
  background: var(--main-bg-color);
  border-radius: 24px;
  box-shadow: 
    0 25px 80px -12px rgba(99, 102, 241, 0.25),
    0 0 0 1px rgba(99, 102, 241, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  max-height: 90vh;
  max-width: 480px;
  width: 100%;
  overflow: hidden;
  animation: modalSlideUp 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex;
  flex-direction: column;
  position: relative;
}

.jninvest-modal > div::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #667eea, #764ba2, #f093fb, #667eea);
  background-size: 300% 100%;
  animation: gradientShift 3s ease infinite;
  z-index: 1;
}

/* 弹窗头部 */
.jninvest-modal h3 {
  margin: 0;
  padding: 28px 32px 24px;
  font-size: 20px;
  font-weight: 700;
  color: var(--main-color);
  background: linear-gradient(180deg, var(--main-bg-color) 0%, transparent 100%);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  letter-spacing: -0.3px;
  border-bottom: 1px solid var(--border);
}

.jninvest-modal h3 i {
  color: var(--primary);
  font-size: 24px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 弹窗内容区域 */
.jninvest-modal > div > div {
  padding: 12px 32px 28px;
  overflow-y: auto;
  flex: 1;
  -webkit-overflow-scrolling: touch;
}

/* 弹窗表格样式 */
.jninvest-modal table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.jninvest-modal td {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  transition: all 0.2s ease;
}

.jninvest-modal td:first-child {
  color: var(--gray);
  font-weight: 500;
  font-size: 13px;
}

.jninvest-modal td:last-child {
  text-align: right;
  font-weight: 600;
  color: var(--main-color);
}

.jninvest-modal tr:last-child td {
  border-bottom: none;
}

.jninvest-modal tr:hover td {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.04) 0%, transparent 100%);
}

/* 弹窗按钮区域 */
.jninvest-modal > div > div:last-child {
  display: flex;
  gap: 14px;
  padding: 20px 32px 32px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
  background: var(--main-bg-color);
}

.jninvest-modal button {
  flex: 1;
  padding: 16px 24px;
  border: none;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  letter-spacing: -0.2px;
}

.jninvest-modal button:first-child {
  background: linear-gradient(135deg, #94a3b8 0%, #64748b 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(100, 116, 139, 0.25);
}

.jninvest-modal button:first-child:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(100, 116, 139, 0.35);
}

.jninvest-modal button:last-child {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

.jninvest-modal button:last-child:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(99, 102, 241, 0.5);
}

/* 弹窗动画 */
@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* 手机版弹窗优化 */
@media (max-width: 768px) {
  .jninvest-modal {
    padding: 0;
    align-items: flex-end;
  }
  
  .jninvest-modal > div {
    max-height: 88vh;
    max-width: 100%;
    border-radius: 24px 24px 0 0;
    animation: modalSlideUpMobile 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  }
  
  .jninvest-modal > div::before {
    border-radius: 24px 24px 0 0;
  }
  
  @keyframes modalSlideUpMobile {
    from {
      opacity: 0;
      transform: translateY(100%);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .jninvest-modal h3 {
    padding: 24px 24px 20px;
    font-size: 18px;
  }
  
  .jninvest-modal h3 i {
    font-size: 22px;
  }
  
  .jninvest-modal > div > div {
    padding: 12px 24px 24px;
  }
  
  .jninvest-modal td {
    padding: 12px 0;
    font-size: 13px;
  }
  
  .jninvest-modal > div > div:last-child {
    padding: 18px 24px 28px;
    gap: 12px;
  }
  
  .jninvest-modal button {
    padding: 16px 20px;
    font-size: 15px;
    border-radius: 14px;
  }
  
  .modal1 > div {
    max-width: 100%;
    max-height: 88vh;
    border-radius: 24px 24px 0 0;
    animation: modalSlideUpMobile 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  }
  
  .modal1 > div form {
    padding: 24px;
  }
}

/* 统一弹窗表格样式 */
.modal-form-content {
  padding: 0;
  overflow-y: auto;
  flex: 1;
}

.modal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.modal-table tr {
  border-bottom: 1px solid var(--border);
  transition: all 0.2s ease;
}

.modal-table tr:last-child {
  border-bottom: none;
}

.modal-table tr:hover {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.04) 0%, transparent 100%);
}

.modal-table td {
  padding: 14px 8px;
  vertical-align: middle;
}

.modal-table td:first-child {
  color: var(--gray);
  font-weight: 500;
  width: 35%;
}

.modal-table td:last-child {
  text-align: right;
  font-weight: 600;
  color: var(--main-color);
}

/* 输入行样式 */
.modal-table tr.input-row td:last-child {
  text-align: left;
}

/* 输入组样式 */
.input-group {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.modal-input {
  width: 100%;
  padding: 14px 18px;
  border: 2px solid var(--border);
  border-radius: 12px;
  font-size: 15px;
  background: var(--main-bg-color);
  color: var(--main-color);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
}

.modal-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 
    0 0 0 4px rgba(99, 102, 241, 0.12),
    inset 0 1px 3px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}

.modal-select {
  width: 100%;
  padding: 14px 18px;
  border: 2px solid var(--border);
  border-radius: 12px;
  font-size: 15px;
  background: var(--main-bg-color);
  color: var(--main-color);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
  appearance: none;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="%2364748b" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"></polyline></svg>');
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
}

.modal-select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 
    0 0 0 4px rgba(99, 102, 241, 0.12),
    inset 0 1px 3px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}

.input-hint {
  display: block;
  color: var(--gray-light);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.4;
}

/* 值单元格样式 */
.value-cell {
  font-weight: 600;
  color: var(--main-color);
  font-size: 14px;
  transition: all 0.3s ease;
}

.value-cell:hover {
  color: var(--primary);
}

/* 弹窗标题美化 */
.modal h3 {
  margin: 0;
  padding: 28px 32px 24px;
  font-size: 20px;
  font-weight: 700;
  color: var(--main-color);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  letter-spacing: -0.3px;
}

.modal h3 i {
  color: var(--primary);
  font-size: 24px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* 弹窗按钮区域 */
.modal-buttons {
  display: flex;
  gap: 14px;
  padding: 24px 32px 32px;
  border-top: 1px solid var(--border);
  background: var(--main-bg-color);
}

.modal-buttons .btn {
  flex: 1;
  padding: 16px 24px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 14px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  cursor: pointer;
  letter-spacing: -0.2px;
}

.modal-buttons .btn-secondary {
  background: linear-gradient(135deg, #94a3b8 0%, #64748b 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(100, 116, 139, 0.25);
}

.modal-buttons .btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(100, 116, 139, 0.35);
}

.modal-buttons .btn-primary {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%) !important;
  color: white !important;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.4) !important;
}

.modal-buttons .btn-primary:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.5) !important;
}

.modal-buttons .btn-warning {
  background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%) !important;
  color: white !important;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4) !important;
}

.modal-buttons .btn-warning:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.5) !important;
}

.modal-buttons .btn-danger {
  background: linear-gradient(135deg, #ef4444 0%, #f87171 100%) !important;
  color: white !important;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.4) !important;
}

.modal-buttons .btn-danger:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 25px rgba(239, 68, 68, 0.5) !important;
}

/* 高亮行 */
.modal-table tr.highlight-row {
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.06) 0%, transparent 100%);
}

.modal-table tr.highlight-row td:first-child {
  padding-left: 12px;
  border-radius: 10px 0 0 10px;
}

.modal-table tr.highlight-row td:last-child {
  padding-right: 12px;
  border-radius: 0 10px 10px 0;
}

/* 文字颜色 */
.text-red {
  color: var(--danger) !important;
}

.text-primary {
  color: var(--primary) !important;
}

.text-success {
  color: var(--success) !important;
}

/* 手机版弹窗按钮和表格优化 */
@media (max-width: 768px) {
  .modal h3 {
    padding: 24px 24px 20px;
    font-size: 18px;
  }
  
  .modal h3 i {
    font-size: 22px;
  }
  
  .modal-buttons {
    padding: 18px 24px 28px;
    gap: 12px;
    flex-direction: column;
  }
  
  .modal-buttons .btn {
    padding: 16px 20px;
    font-size: 15px;
    width: 100%;
    border-radius: 14px;
  }
  
  .value-cell {
    font-size: 13px;
  }
  
  .modal-table td {
    padding: 12px 6px;
    font-size: 13px;
  }
  
  .modal-table td:first-child {
    width: 40%;
  }
  
  .modal-input,
  .modal-select {
    padding: 12px 14px;
    font-size: 14px;
    border-radius: 10px;
  }
}

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

.card-gupian {
  animation: fadeIn 0.4s ease;
}

.card-gupian:nth-child(2) {
  animation-delay: 0.1s;
}

.card-gupian:nth-child(3) {
  animation-delay: 0.2s;
}

.card-gupian:nth-child(4) {
  animation-delay: 0.3s;
}

/* 加载动画 */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  border-top-color: white;
  animation: spin 0.8s linear infinite;
}

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

/* 提示框 */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  padding: 16px 24px;
  background: var(--dark);
  color: white;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  z-index: 9999;
  animation: slideInRight 0.3s ease;
}

.toast.success {
  background: var(--success);
}

.toast.error {
  background: var(--danger);
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* 融资融券样式 */
.finance-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  border-bottom: 2px solid var(--border);
  padding-bottom: 12px;
}

.finance-tab {
  padding: 10px 16px;
  border: none;
  background: var(--main-bg-color);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--main-color);
  transition: all 0.3s;
}

.finance-tab:hover {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
}

.finance-tab.active {
  background: var(--gradient-primary);
  color: white;
}

.finance-tab-content {
  display: none;
}

.finance-tab-content.active {
  display: block;
}

.finance-info-box {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 20px;
  padding: 16px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
  border-radius: var(--radius-sm);
}

.info-item {
  text-align: center;
}

.info-label {
  display: block;
  font-size: 12px;
  color: var(--main-color);
  margin-bottom: 4px;
}

.info-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--primary);
}

.finance-form-inline {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.finance-calc-result {
  display: flex;
  gap: 20px;
  margin-top: 12px;
  padding: 12px 16px;
  background: rgba(99, 102, 241, 0.05);
  border-radius: var(--radius-sm);
  font-size: 14px;
}

.finance-calc-result strong {
  color: var(--primary);
}

.finance-table-wrap {
  overflow-x: auto;
}

.finance-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.finance-table th,
.finance-table td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.finance-table th {
  background: var(--main-bg-color);
  font-weight: 600;
  color: var(--main-color);
  font-size: 12px;
  text-transform: uppercase;
}

.finance-table tr:hover {
  background: rgba(99, 102, 241, 0.02);
}

.danger-row {
  background: rgba(34, 197, 94, 0.05) !important;
}

.text-red {
  color: var(--danger) !important;
}

.text-green {
  color: var(--success) !important;
}

.empty-state-mini {
  text-align: center;
  padding: 30px;
  color: var(--main-color);
}

.btn-danger {
  background: var(--gradient-danger) !important;
  border: none !important;
  color: white !important;
}

.btn-danger:hover {
  opacity: 0.9;
}

.btn-sm {
  padding: 6px 12px !important;
  font-size: 12px !important;
}

@media (max-width: 768px) {
  .finance-info-box {
    grid-template-columns: 1fr;
  }
  
  .finance-form-inline {
    flex-direction: column;
  }
  
  .finance-form-inline .form-control,
  .finance-form-inline .btn {
    width: 100%;
  }
  
  .finance-calc-result {
    flex-direction: column;
    gap: 8px;
  }
}

/* 排行榜标签样式 */
.ranking-tabs {
  display: flex;
  gap: 0;
  background: var(--main-bg-color);
  padding: 0;
  border-bottom: none;
}

.ranking-tab {
  flex: 1;
  padding: 16px 24px;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-weight: 600;
  color: #718096;
  font-size: 15px;
  position: relative;
}

.ranking-tab::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: transparent;
  transition: all 0.3s ease;
}

.ranking-tab::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
  transition: width 0.3s ease;
}

.ranking-tab:hover {
  background: rgba(102, 126, 234, 0.05);
  color: #667eea;
}

.ranking-tab:hover::after {
  width: 60%;
}

.ranking-tab.active {
  background: var(--main-bg-color);
  border-radius: var(--radius-sm);
  color: #667eea;
  font-weight: 700;
}

.ranking-tab.active::after {
  width: 100%;
}

.ranking-tab i {
  margin-right: 8px;
  font-size: 18px;
  vertical-align: middle;
}

/* 排行榜内容样式 */
.ranking-content {
  display: none;
  animation: fadeIn 0.3s ease;
}

.ranking-content.active {
  display: block;
}

/* 排行榜样式 */
.ranking-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ranking-item {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  background: white;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.ranking-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 4px;
  background: var(--primary);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.ranking-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.ranking-item:hover::before {
  opacity: 1;
}

.ranking-number {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 16px;
  margin-right: 16px;
  flex-shrink: 0;
}

.ranking-item:nth-child(1) .ranking-number {
  background: linear-gradient(135deg, #ffd700, #ffed4e);
  box-shadow: 0 0 15px rgba(255, 215, 0, 0.6);
  transform: scale(1.1);
}

.ranking-item:nth-child(2) .ranking-number {
  background: linear-gradient(135deg, #c0c0c0, #e0e0e0);
  box-shadow: 0 0 12px rgba(192, 192, 192, 0.6);
  transform: scale(1.05);
}

.ranking-item:nth-child(3) .ranking-number {
  background: linear-gradient(135deg, #cd7f32, #e6b480);
  box-shadow: 0 0 10px rgba(205, 127, 50, 0.6);
}

.ranking-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 16px;
  flex-shrink: 0;
}

.ranking-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.ranking-name {
  font-weight: 600;
  color: var(--dark);
  font-size: 16px;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ranking-desc {
  font-size: 12px;
  color: var(--text-secondary);
}

.ranking-value {
  font-weight: 700;
  font-size: 18px;
  min-width: 120px;
  text-align: right;
  flex-shrink: 0;
}

/* 响应式调整 - 排行榜 */
@media (max-width: 768px) {
  .ranking-tabs {
    flex-direction: row;
    gap: 0;
  }
  
  .ranking-tab {
    padding: 14px 16px;
    font-size: 14px;
  }
  
  .ranking-tab i {
    display: block;
    margin-right: 0;
    margin-bottom: 4px;
    font-size: 20px;
  }
  
  .leaderboard-item {
    padding: 12px 14px;
    grid-template-columns: 50px 1fr 100px;
    gap: 12px;
  }
  
  .player-score {
    font-size: 16px;
  }
  
  .medal {
    font-size: 32px;
  }
  
  .player-avatar {
    width: 40px;
    height: 40px;
  }
  
  .player-name {
    font-size: 14px;
  }
}


