/* 页面加载动画 */
#page-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(ellipse at center, rgba(0,20,40,1) 0%, rgba(0,5,15,1) 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity 0.5s ease;
}

#page-loader.loaded {
  opacity: 0;
  pointer-events: none;
}

.loader-spinner {
  width: 60px;
  height: 60px;
  border: 3px solid rgba(0,255,255,0.2);
  border-top-color: rgba(0,255,255,0.8);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

.loader-text {
  margin-top: 20px;
  color: rgba(0,255,255,0.8);
  font-size: 16px;
  font-family: "Microsoft Yahei", sans-serif;
  letter-spacing: 2px;
  text-shadow: 0 0 10px rgba(0,255,255,0.5);
}

.loader-progress {
  margin-top: 10px;
  color: rgba(0,200,255,0.6);
  font-size: 12px;
}

/* 欢迎语样式 */
#welcome-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(ellipse at center, rgba(0,20,40,0.98) 0%, rgba(0,5,15,0.99) 100%);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.8s ease;
}

#welcome-overlay.show {
  opacity: 1;
  pointer-events: all;
}

#welcome-overlay.hide {
  opacity: 0;
  pointer-events: none;
}

.welcome-content {
  text-align: center;
  transform: translateY(30px);
  opacity: 0;
  transition: all 1s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#welcome-overlay.show .welcome-content {
  transform: translateY(0);
  opacity: 1;
}

.welcome-title {
  font-size: 32px;
  color: rgba(0,255,255,0.9);
  font-weight: 300;
  letter-spacing: 8px;
  margin: 0 0 20px 0;
  text-shadow: 0 0 30px rgba(0,255,255,0.6);
  animation: welcome-glow 3s ease-in-out infinite;
}

.welcome-subtitle {
  font-size: 48px;
  background: linear-gradient(135deg, #00ffff 0%, #00d4ff 50%, #0099cc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 600;
  letter-spacing: 6px;
  margin: 0 0 30px 0;
  text-shadow: 0 0 40px rgba(0,255,255,0.8);
}

.welcome-desc {
  font-size: 18px;
  color: rgba(0,200,255,0.7);
  letter-spacing: 2px;
  margin: 0 0 50px 0;
  font-weight: 300;
}

.welcome-btn {
  padding: 15px 50px;
  font-size: 18px;
  color: #fff;
  background: linear-gradient(135deg, rgba(0,212,255,0.6) 0%, rgba(0,153,204,0.6) 100%);
  border: 2px solid rgba(0,255,255,0.8);
  border-radius: 50px;
  cursor: pointer;
  letter-spacing: 3px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  box-shadow: 0 0 30px rgba(0,255,255,0.4);
}

.welcome-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 50px rgba(0,255,255,0.8);
  background: linear-gradient(135deg, rgba(0,212,255,0.8) 0%, rgba(0,153,204,0.8) 100%);
}

@keyframes welcome-glow {
  0%, 100% { text-shadow: 0 0 30px rgba(0,255,255,0.6); }
  50% { text-shadow: 0 0 50px rgba(0,255,255,1); }
}

/* 唱片音乐控制器 */
#music-player {
  position: fixed;
  top: 30px;
  right: 30px;
  z-index: 100;
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#music-player.show {
  opacity: 1;
  transform: scale(1);
}

.vinyl-record {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #333 0%, #000 50%, #1a1a1a 100%);
  position: relative;
  cursor: pointer;
  box-shadow: 0 8px 30px rgba(0,0,0,0.6),
              inset 0 0 20px rgba(0,0,0,0.8);
  transition: all 0.3s ease;
}

.vinyl-record:hover {
  transform: scale(1.1);
  box-shadow: 0 10px 40px rgba(0,255,255,0.4);
}

.vinyl-record.playing {
  animation: vinyl-spin 3s linear infinite;
}

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

.vinyl-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: radial-gradient(circle, #666 0%, #333 100%);
  box-shadow: inset 0 0 10px rgba(0,0,0,0.8);
}

.vinyl-label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(0,212,255,0.8) 0%, rgba(0,153,204,0.8) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: #fff;
  box-shadow: 0 0 15px rgba(0,255,255,0.6);
}

.vinyl-grooves {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.vinyl-groove {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.05);
}

.vinyl-groove:nth-child(1) { width: 90%; height: 90%; top: 5%; left: 5%; }
.vinyl-groove:nth-child(2) { width: 80%; height: 80%; top: 10%; left: 10%; }
.vinyl-groove:nth-child(3) { width: 70%; height: 70%; top: 15%; left: 15%; }
.vinyl-groove:nth-child(4) { width: 60%; height: 60%; top: 20%; left: 20%; }
.vinyl-groove:nth-child(5) { width: 50%; height: 50%; top: 25%; left: 25%; }

/* 音乐控制提示 */
.music-tooltip {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 10px;
  padding: 8px 15px;
  background: rgba(0,30,50,0.95);
  color: rgba(0,255,255,0.9);
  border-radius: 20px;
  font-size: 12px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(0,255,255,0.3);
}

.vinyl-record:hover + .music-tooltip {
  opacity: 1;
  visibility: visible;
}

/* 音乐列表 */
.music-list {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 15px;
  width: 280px;
  max-height: 400px;
  overflow-y: auto;
  background: rgba(0,20,40,0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 15px;
  border: 1px solid rgba(0,255,255,0.3);
  box-shadow: 0 10px 40px rgba(0,0,0,0.6),
              0 0 60px rgba(0,255,255,0.2);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 1000;
}

.music-list.show {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

.music-list-header {
  padding: 15px 20px;
  border-bottom: 1px solid rgba(0,255,255,0.2);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.music-list-title {
  font-size: 16px;
  font-weight: 600;
  color: rgba(0,255,255,0.9);
  letter-spacing: 1px;
  text-shadow: 0 0 10px rgba(0,255,255,0.5);
}

.music-list-close {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(0,255,255,0.1);
  border: 1px solid rgba(0,255,255,0.3);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  position: relative;
}

.music-list-close::before,
.music-list-close::after {
  content: '';
  position: absolute;
  width: 12px;
  height: 2px;
  background: rgba(0,255,255,0.8);
  border-radius: 1px;
}

.music-list-close::before {
  transform: rotate(45deg);
}

.music-list-close::after {
  transform: rotate(-45deg);
}

.music-list-close:hover {
  background: rgba(0,255,255,0.2);
  border-color: rgba(0,255,255,0.6);
  transform: rotate(90deg);
}

.music-list-items {
  padding: 10px;
}

.music-item {
  padding: 12px 15px;
  margin-bottom: 8px;
  border-radius: 10px;
  background: rgba(0,30,50,0.3);
  border: 1px solid rgba(0,255,255,0.1);
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 12px;
}

.music-item:hover {
  background: rgba(0,50,80,0.5);
  border-color: rgba(0,255,255,0.4);
  transform: translateX(5px);
}

.music-item.active {
  background: linear-gradient(135deg, rgba(0,212,255,0.3) 0%, rgba(0,153,204,0.3) 100%);
  border-color: rgba(0,255,255,0.6);
  box-shadow: 0 0 15px rgba(0,255,255,0.3);
}

.music-item-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(0,212,255,0.4) 0%, rgba(0,153,204,0.4) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  box-shadow: 0 0 10px rgba(0,255,255,0.3);
}

.music-item.active .music-item-icon {
  animation: music-pulse 1.5s ease-in-out infinite;
}

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

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

.music-item-name {
  font-size: 14px;
  color: rgba(255,255,255,0.9);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.music-item-artist {
  font-size: 12px;
  color: rgba(0,200,255,0.6);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.music-item.active .music-item-name {
  color: rgba(0,255,255,0.9);
  text-shadow: 0 0 10px rgba(0,255,255,0.5);
}

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

.music-list::-webkit-scrollbar-track {
  background: rgba(0,20,40,0.3);
  border-radius: 3px;
}

.music-list::-webkit-scrollbar-thumb {
  background: rgba(0,255,255,0.3);
  border-radius: 3px;
}

.music-list::-webkit-scrollbar-thumb:hover {
  background: rgba(0,255,255,0.5);
}

/* 移动端适配 */
@media screen and (max-width: 768px) {
  #music-player {
    top: 20px;
    right: 20px;
  }

  .vinyl-record {
    width: 60px;
    height: 60px;
  }

  .vinyl-center {
    width: 22px;
    height: 22px;
  }

  .vinyl-label {
    width: 18px;
    height: 18px;
    font-size: 10px;
  }

  .welcome-title {
    font-size: 24px;
  }

  .welcome-subtitle {
    font-size: 32px;
  }

  .welcome-desc {
    font-size: 14px;
    padding: 0 20px;
  }

  .welcome-btn {
    padding: 12px 40px;
    font-size: 16px;
  }

  /* 音乐列表移动端适配 */
  .music-list {
    width: calc(100vw - 40px);
    max-width: 320px;
    max-height: 60vh;
    right: -10px;
  }

  .music-list-header {
    padding: 12px 15px;
  }

  .music-list-title {
    font-size: 14px;
  }

  .music-item {
    padding: 10px 12px;
    gap: 10px;
  }

  .music-item-icon {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }

  .music-item-name {
    font-size: 13px;
  }

  .music-item-artist {
    font-size: 11px;
  }
}
