/* ========== 全局重置 ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  background-attachment: fixed;
  color: #1f2937;
  line-height: 1.6;
  min-height: 100vh;
}

/* ========== 容器：居中、限制宽度 ========== */
.container {
  max-width: 480px;
  margin: 0 auto;
  padding: 2rem 1rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ========== 标题样式 ========== */
h1 {
  font-size: 2rem;
  font-weight: 700;
  color: #ffffff;
  text-align: center;
  margin-bottom: 0.5rem;
  cursor: pointer;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s ease;
}

h1:hover {
  transform: scale(1.05);
}

/* ========== 副标题 ========== */
.subtitle {
  text-align: center;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

/* ========== 按钮通用样式 ========== */
.btn {
  display: block;
  width: 100%;
  padding: 1rem;
  border-radius: 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  text-align: center;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-bottom: 1rem;
  text-decoration: none;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

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

.btn:active {
  transform: translateY(0);
}

/* 蓝色按钮（微软登录） */
.btn-blue {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

.btn-blue:hover {
  background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

/* 绿色按钮（播放） */
.btn-green {
  background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
  color: white;
}

.btn-green:hover {
  background: linear-gradient(135deg, #38ef7d 0%, #11998e 100%);
}

/* 灰色按钮（返回） */
.btn-gray {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  backdrop-filter: blur(10px);
}

.btn-gray:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* ========== 圆形播放按钮 ========== */
.play-btn {
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 2rem;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  font-size: 1.5rem;
  border: 3px solid rgba(255, 255, 255, 0.2);
}

.play-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.play-btn.playing {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  }
  50% {
    box-shadow: 0 10px 50px rgba(255, 255, 255, 0.5);
  }
}

/* ========== 歌曲列表 ========== */
.song-list {
  margin-top: 1.5rem;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 1rem;
  padding: 1rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  max-height: 400px;
  overflow-y: auto;
  backdrop-filter: blur(10px);
  animation: slideDown 0.3s ease;
}

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

/* 歌曲列表项 */
.song-item {
  padding: 1rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  border: 2px solid transparent;
}

.song-item:last-child {
  margin-bottom: 0;
}

.song-item:hover {
  background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
  border-color: #22c55e;
  transform: translateX(5px);
}

.song-item.playing {
  background: linear-gradient(135deg, #22c55e 0%, #86efac 100%);
  color: white;
  border-color: #166534;
}

.song-item.playing .song-name {
  color: white;
}

.song-item.playing .song-icon {
  color: white;
}

.song-icon {
  font-size: 1.2rem;
  margin-right: 0.75rem;
  color: #22c55e;
}

.song-name {
  font-weight: 600;
  color: #1f2937;
  flex: 1;
}

/* 滚动条美化 */
.song-list::-webkit-scrollbar {
  width: 6px;
}

.song-list::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 10px;
}

.song-list::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 10px;
}

.song-list::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* ========== 播放器控制栏（底部） ========== */
.player-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.98);
  padding: 1rem;
  box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
}

/* ========== 卡片容器（登录页等） ========== */
.card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  border-radius: 1.5rem;
  padding: 2rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

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

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

/* ========== 响应式 ========== */
@media (max-width: 640px) {
  .container {
    padding: 1.5rem 1rem;
  }
  
  h1 {
    font-size: 1.75rem;
  }
  
  .play-btn {
    width: 4rem;
    height: 4rem;
  }
}