@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700;900&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body {
  background: #ffffff;
  color: #1d1d1f;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #f5f5f7; }
::-webkit-scrollbar-thumb { background: #d2d2d7; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #86868b; }

/* ===== 动画 ===== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes card-shine {
  0% { left: -100%; }
  100% { left: 200%; }
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}
@keyframes pulse-soft {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.animate-fadeInUp { animation: fadeInUp 0.8s ease forwards; }
.animate-fadeIn { animation: fadeIn 0.6s ease forwards; }
.animate-delay-100 { animation-delay: 0.1s; opacity: 0; }
.animate-delay-200 { animation-delay: 0.2s; opacity: 0; }
.animate-delay-300 { animation-delay: 0.3s; opacity: 0; }
.animate-delay-400 { animation-delay: 0.4s; opacity: 0; }
.animate-delay-500 { animation-delay: 0.5s; opacity: 0; }
.animate-delay-600 { animation-delay: 0.6s; opacity: 0; }

/* ===== 导航栏 ===== */
#navbar {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  transition: all 0.3s ease;
}

.nav-logo-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #F26522, #00C853);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== Tab按钮 ===== */
.tab-btn {
  transition: all 0.3s ease;
  cursor: pointer;
  color: #86868b;
  background: transparent;
  border: none;
  border-radius: 10px;
  font-size: 13px;
  padding: 6px 14px;
}
.tab-btn:hover:not(.active) {
  color: #1d1d1f;
  background: rgba(0, 0, 0, 0.04);
}
.tab-btn.active {
  background: #1d1d1f;
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* ===== 区块标题栏 ===== */
.section-title-bar {
  width: 4px;
  height: 24px;
  background: linear-gradient(to bottom, #F26522, #00C853);
  border-radius: 2px;
}

/* ===== 卡片通用 ===== */
.card-hover {
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

.glass-card {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.glass-card-alt {
  background: #f5f5f7;
  border: 1px solid rgba(0, 0, 0, 0.04);
  border-radius: 16px;
}

/* ===== 技术卡片 ===== */
.tech-card {
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}
.tech-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

/* ===== Hero区域 ===== */
.hero-section {
  background: linear-gradient(180deg, #f5f5f7 0%, #ffffff 100%);
  position: relative;
  overflow: hidden;
}
.hero-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(ellipse at 50% 30%, rgba(242, 101, 34, 0.03) 0%, transparent 50%);
  pointer-events: none;
}

/* ===== 挑战卡片滚动 ===== */
.challenge-scroll {
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.challenge-scroll::-webkit-scrollbar { height: 4px; }
.challenge-scroll::-webkit-scrollbar-thumb { background: #d2d2d7; border-radius: 2px; }
.challenge-card {
  scroll-snap-align: start;
  flex-shrink: 0;
}

/* ===== 球员卡 ===== */
.player-card-container {
  background: linear-gradient(135deg, #f5f5f7, #ffffff, #f5f5f7);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 20px;
  overflow: hidden;
  position: relative;
}
.player-card-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  animation: card-shine 4s ease-in-out infinite;
  pointer-events: none;
}

/* ===== 进化路线 ===== */
.evolution-line { position: relative; }
.evolution-line::before {
  content: '';
  position: absolute;
  left: 20px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, rgba(242, 101, 34, 0.15), rgba(0, 200, 83, 0.15));
}

/* ===== 聊天气泡 ===== */
.chat-bubble { animation: fadeInUp 0.3s ease forwards; }

/* ===== 球星之路 ===== */
.star-challenge {
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid rgba(0, 0, 0, 0.06);
  border-radius: 16px;
  background: #ffffff;
}
.star-challenge:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}
.star-challenge.active {
  border-color: #F26522 !important;
  box-shadow: 0 8px 30px rgba(242, 101, 34, 0.1);
}

/* ===== 排行行 ===== */
.rank-row {
  transition: all 0.3s ease;
}
.rank-row:hover {
  background: rgba(0, 0, 0, 0.02);
}

/* ===== 弹窗 ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(12px);
  z-index: 100;
  display: none;
  justify-content: center;
  align-items: center;
}
.modal-overlay.show { display: flex; }

/* ===== 星级图标 ===== */
.star-icon {
  display: inline-block;
  color: #FFD700;
  font-size: 16px;
  margin-right: 2px;
}

/* ===== 输入框 ===== */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  border-radius: 2px;
  outline: none;
  background: #e5e7eb;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #1d1d1f;
  cursor: pointer;
  border: 2px solid #ffffff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

/* ===== 区块背景交替 ===== */
.section-white { background: #ffffff; }
.section-gray { background: #f5f5f7; }

/* ===== 标签 ===== */
.tag-orange {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  background: rgba(242, 101, 34, 0.08);
  color: #F26522;
  font-size: 12px;
  font-weight: 500;
  border: 1px solid rgba(242, 101, 34, 0.12);
}
.tag-green {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  background: rgba(0, 200, 83, 0.08);
  color: #00C853;
  font-size: 12px;
  font-weight: 500;
  border: 1px solid rgba(0, 200, 83, 0.12);
}
.tag-purple {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  background: rgba(155, 89, 182, 0.08);
  color: #9B59B6;
  font-size: 12px;
  font-weight: 500;
  border: 1px solid rgba(155, 89, 182, 0.12);
}

/* ===== 按钮 ===== */
.btn-primary {
  padding: 12px 32px;
  border-radius: 12px;
  background: #1d1d1f;
  color: #ffffff;
  font-weight: 700;
  font-size: 14px;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}
.btn-primary:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}
.btn-secondary {
  padding: 12px 32px;
  border-radius: 12px;
  background: transparent;
  color: #1d1d1f;
  font-weight: 700;
  font-size: 14px;
  border: 1.5px solid rgba(0, 0, 0, 0.15);
  cursor: pointer;
  transition: all 0.3s ease;
}
.btn-secondary:hover {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.3);
}

/* ===== 统计数字 ===== */
.stat-card {
  background: #f5f5f7;
  border-radius: 14px;
  padding: 16px;
  text-align: center;
  border: 1px solid rgba(0, 0, 0, 0.04);
}
.stat-number {
  font-size: 28px;
  font-weight: 900;
  line-height: 1.2;
}
.stat-label {
  font-size: 11px;
  color: #86868b;
  margin-top: 4px;
}

/* ===== 进度条 ===== */
.progress-bar-bg {
  height: 6px;
  background: rgba(0, 0, 0, 0.06);
  border-radius: 3px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s ease;
}

/* ===== Canvas容器 ===== */
.canvas-container {
  background: #f5f5f7;
  border-radius: 14px;
  overflow: hidden;
}

/* ===== 页脚 ===== */
footer {
  background: #f5f5f7;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

/* ===== 章节卡片 ===== */
.chapter-card {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 16px;
  padding: 24px;
  transition: all 0.3s ease;
}
.chapter-card.active-chapter {
  border-color: rgba(242, 101, 34, 0.2);
}
.chapter-card.locked-chapter {
  opacity: 0.6;
}

/* ===== 学生卡片 ===== */
.student-card {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 16px;
  padding: 20px;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.student-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

/* ===== 响应式 ===== */
@media (max-width: 768px) {
  .stat-number { font-size: 22px; }
}

/* ===== 颜色工具类 ===== */
.text-nba { color: #F26522; }
.text-guard { color: #00C853; }
.text-gold { color: #B8860B; }
.text-silver { color: #808080; }
.text-bronze { color: #CD7F32; }
.bg-nba { background-color: #F26522; }
.bg-guard { background-color: #00C853; }

/* ===== 登录角色按钮 ===== */
.login-role-btn.active {
  background: #1d1d1f;
  color: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* ===== 战术选择按钮 ===== */
.tactic-btn.active {
  border-color: #F26522 !important;
  box-shadow: 0 4px 16px rgba(242,101,34,0.12);
  background: rgba(242,101,34,0.03);
}

/* ===== PK对战选中对手 ===== */
.pk-opponent.ring-2 { box-shadow: 0 0 0 2px #F26522; }

/* ===== 球星/位置选择卡片 ===== */
.avatar-pick.selected img {
  filter: drop-shadow(0 0 20px rgba(242, 101, 34, 0.5));
}
.avatar-pick.selected .avatar-check {
  opacity: 1 !important;
}
.pos-pick.ring-2 {
  border-color: #F26522 !important;
  background: rgba(242, 101, 34, 0.02);
  box-shadow: 0 0 0 2px #F26522;
}
