/**
 *
 * 音乐搜索器 - CSS 文件
 *
 * @author  MaiCong <i@maicong.me>
 * @link    https://github.com/maicong/music
 * @since   1.5.4
 *
 */

:root {
  --primary-color: #3498db;
  --primary-hover: #2980b9;
  --secondary-color: #2ecc71;
  --secondary-hover: #27ae60;
  --text-color: #34495e;
  --text-secondary: #7f8c8d;
  --background-color: #ecf0f1;
  --card-bg: #ffffff;
  --border-color: #e0e0e0;
  --success-color: #2ecc71;
  --error-color: #e74c3c;
}

html {
  font-family: -apple-system, BlinkMacSystemFont, 'San Francisco', 'Microsoft YaHei', 'PingFang SC',
    'Hiragino Sans GB', 'WenQuanYi Micro Hei', 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell',
    'Fira Sans', 'Droid Sans', 'Noto Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif,
    'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
  -webkit-text-size-adjust: 100%;
  -moz-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background-color: var(--background-color);
  color: var(--text-color);
  -webkit-tap-highlight-color: transparent;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  -webkit-transition: all 0.3s;
  transition: all 0.3s;
}

a:hover {
  color: var(--primary-hover);
}

.about {
  background: var(--card-bg);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  border-radius: 8px;
  margin: 20px auto;
  max-width: 1200px;
}

.about-color {
  color: var(--primary-color);
}

.about-title {
  font-size: 2.2rem;
  font-weight: 600;
  text-align: center;
  margin: 1rem 0;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.main {
  margin: 60px 0;
}

.music-tabs {
  border-radius: 50px;
  background: var(--background-color);
  padding: 5px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.music-tabs > li {
  border-radius: 50px;
  margin: 0 3px;
}

.music-tabs > li > a {
  padding: 0.6em 1.2em;
  cursor: pointer;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: 50px;
}

.music-tabs > li.am-active > a {
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  color: white;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
}

.music-tabs > li > a:hover {
  color: var(--primary-color);
}

.music-tabs > li.am-active > a:hover {
  color: white;
}

.music-main {
  display: none;
}

.music-main input {
  text-overflow: ellipsis;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  padding: 8px 12px;
  transition: all 0.3s;
}

.music-main input:focus,
.music-main input:hover {
  background: #f5f5f5;
  border-color: var(--primary-color);
  color: var(--text-color);
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.music-type {
  margin: 1.5rem 0;
}

.music-type .am-radio-inline,
.music-type label {
  color: var(--text-secondary);
  margin-right: 10px;
  margin-bottom: 10px;
  transition: all 0.3s;
}

.music-type .am-radio-inline:hover,
.music-type label:hover {
  color: var(--primary-color);
}

.music-type .am-icon-unchecked,
.music-type .am-icon-checked {
  color: var(--primary-color);
}

.am-btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  transition: all 0.3s;
}

.am-btn-primary:hover, 
.am-btn-primary:focus {
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
}

.am-btn-success {
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
  transition: all 0.3s;
}

.am-btn-success:hover,
.am-btn-success:focus {
  background-color: var(--secondary-hover);
  border-color: var(--secondary-hover);
}

.music-tips {
  margin-top: 50px;
  background: var(--card-bg);
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.music-tips h4 {
  color: var(--primary-color);
  font-weight: 600;
  border-left: 4px solid var(--primary-color);
  padding-left: 10px;
}

.music-tips blockquote {
  font-family: Menlo, Monaco, Consolas, 'Courier New', monospace;
  font-size: 14px;
  margin-top: 20px;
  border-left: 4px solid var(--secondary-color);
  background-color: rgba(46, 204, 113, 0.05);
  padding: 15px;
  border-radius: 0 8px 8px 0;
}

.music-tips p span {
  display: inline-block;
  min-width: 60px;
  font-weight: 500;
}

.music-tips p b {
  font-weight: 500;
  color: var(--error-color);
}

.music-tips p u {
  text-decoration: none;
  border-bottom: 1px dashed var(--text-secondary);
  padding-bottom: 1px;
}

.music-overflow {
  max-height: 200px;
  overflow: hidden;
  border-radius: 8px;
}

.music-more {
  padding: 12px;
  text-align: center;
  font-size: 14px;
  color: var(--text-color);
  background: var(--background-color);
  cursor: pointer;
  border-radius: 0 0 8px 8px;
  transition: all 0.3s;
}

.music-more:hover {
  background: var(--primary-color);
  color: white;
}

.footer {
  position: relative;
  left: 0;
  bottom: 0;
  width: 100%;
  overflow: hidden;
}

.footer p {
  color: var(--text-secondary);
  margin: 0;
  padding: 15px;
  text-align: center;
  background: var(--text-color);
}

.footer p a {
  color: var(--text-secondary);
}

.footer p a:hover {
  color: var(--primary-color);
}

.footer a {
  text-decoration: underline;
}

.am-alert {
  display: none;
  border-radius: 4px;
}

.am-alert-danger {
  background-color: rgba(231, 76, 60, 0.1);
  border-color: rgba(231, 76, 60, 0.2);
  color: var(--error-color);
}

.am-popup-bd {
  height: 100%;
}

.am-input-group-label {
  background-color: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

.aplayer {
  padding: 15px !important;
  margin: 0 !important;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* Custom APlayer Styling - Enhanced player appearance */
.aplayer {
  font-family: inherit !important;
  background: linear-gradient(to right, rgba(240, 245, 250, 0.8), rgba(255, 255, 255, 0.8)) !important;
  transition: all 0.3s ease;
}

.aplayer:hover {
  box-shadow: 0 5px 15px rgba(52, 152, 219, 0.15) !important;
  transform: translateY(-2px);
}

.aplayer .aplayer-info {
  padding: 14px 7px 0 !important;
  border: none !important;
}

.aplayer .aplayer-info .aplayer-music {
  margin-bottom: 15px !important;
}

.aplayer .aplayer-info .aplayer-music .aplayer-title {
  font-size: 18px !important;
  font-weight: 600 !important;
  color: var(--text-color) !important;
  transition: color 0.3s;
}

.aplayer .aplayer-info .aplayer-music .aplayer-title:hover {
  color: var(--primary-color) !important;
}

.aplayer .aplayer-info .aplayer-music .aplayer-author {
  font-size: 14px !important;
  color: var(--text-secondary) !important;
}

.aplayer .aplayer-info .aplayer-controller {
  transition: all 0.3s ease !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap {
  margin: 0 0 4px 0 !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar {
  height: 6px !important;
  border-radius: 3px !important;
  background: rgba(0, 0, 0, 0.05) !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-loaded {
  background: rgba(52, 152, 219, 0.2) !important;
  height: 6px !important;
  border-radius: 3px !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-played {
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color)) !important;
  height: 6px !important;
  border-radius: 3px !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-played .aplayer-thumb {
  background: var(--primary-color) !important;
  transform: scale(0.8) !important;
  transition: all 0.2s ease-in-out !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap:hover .aplayer-bar .aplayer-played .aplayer-thumb {
  transform: scale(1) !important;
  box-shadow: 0 0 10px rgba(52, 152, 219, 0.5) !important;
}

.aplayer .aplayer-time {
  color: var(--text-secondary) !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-time .aplayer-icon {
  transition: all 0.2s ease !important;
  color: var(--text-color) !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-time .aplayer-icon:hover {
  color: var(--primary-color) !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-time .aplayer-icon path {
  transition: all 0.2s ease !important;
}

.aplayer .aplayer-info .aplayer-controller .aplayer-time .aplayer-icon.aplayer-icon-loop,
.aplayer .aplayer-info .aplayer-controller .aplayer-time .aplayer-icon.aplayer-icon-order,
.aplayer .aplayer-info .aplayer-controller .aplayer-time .aplayer-icon.aplayer-icon-menu {
  margin-left: 12px !important;
}

.aplayer .aplayer-lrc {
  margin-top: 10px !important;
  text-align: center !important;
  height: 40px !important;
}

.aplayer .aplayer-lrc p {
  font-size: 14px !important;
  line-height: 20px !important;
  transition: all 0.3s ease !important;
}

.aplayer .aplayer-lrc p.aplayer-lrc-current {
  color: var(--primary-color) !important;
  font-weight: 600 !important;
  transform: scale(1.05) !important;
  filter: drop-shadow(0 0 2px rgba(52, 152, 219, 0.3)) !important;
}

.aplayer.aplayer-withlrc .aplayer-pic {
  width: 120px !important;
  height: 120px !important;
  border-radius: 8px !important;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1) !important;
  overflow: hidden !important;
  transition: all 0.3s ease !important;
  transform: translateZ(0) !important;
  -webkit-mask-image: -webkit-radial-gradient(white, black) !important;
}

.aplayer.aplayer-withlrc .aplayer-pic:hover {
  transform: scale(1.05) !important;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2) !important;
}

.aplayer.aplayer-withlrc .aplayer-info {
  margin-left: 130px !important;
  height: 120px !important;
}

.aplayer .aplayer-list {
  border-radius: 8px !important;
  overflow: hidden !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
  margin-top: 15px !important;
  background: linear-gradient(to right, rgba(240, 245, 250, 0.8), rgba(255, 255, 255, 0.8)) !important;
}

.aplayer .aplayer-list ol {
  padding: 8px 0 !important;
}

.aplayer .aplayer-list ol li {
  border-top: 1px solid rgba(224, 224, 224, 0.5) !important;
  padding: 10px 20px !important;
  transition: all 0.2s ease !important;
}

.aplayer .aplayer-list ol li:first-child {
  border-top: none !important;
}

.aplayer .aplayer-list ol li:hover {
  background-color: rgba(52, 152, 219, 0.1) !important;
}

.aplayer .aplayer-list ol li.aplayer-list-light {
  background: rgba(52, 152, 219, 0.15) !important;
}

.aplayer .aplayer-list ol li .aplayer-list-index {
  margin-right: 12px !important;
  color: var(--text-secondary) !important;
}

.aplayer .aplayer-list ol li .aplayer-list-author {
  color: var(--text-secondary) !important;
  padding-right: 10px !important;
}

.aplayer .aplayer-more {
  position: relative !important;
  font-size: 13px !important;
  padding: 12px !important;
  margin-top: 15px !important;
  text-align: center !important;
  color: var(--text-secondary) !important;
  background: linear-gradient(to right, rgba(52, 152, 219, 0.1), rgba(46, 204, 113, 0.1)) !important;
  border-radius: 8px !important;
  cursor: pointer !important;
  transition: all 0.3s !important;
}

.aplayer .aplayer-more:hover,
.aplayer .aplayer-more:active {
  color: white !important;
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color)) !important;
  box-shadow: 0 3px 10px rgba(52, 152, 219, 0.3) !important;
}

.aplayer .aplayer-list-hide {
  transition: all 0.5s ease-out !important;
}

/* Responsive adjustments for player */
@media only screen and (max-width: 640px) {
  .aplayer.aplayer-withlrc .aplayer-pic {
    width: 80px !important;
    height: 80px !important;
  }
  
  .aplayer.aplayer-withlrc .aplayer-info {
    margin-left: 90px !important;
    height: 80px !important;
  }
  
  .aplayer .aplayer-info .aplayer-music .aplayer-title {
    font-size: 16px !important;
  }
  
  .aplayer .aplayer-info .aplayer-music .aplayer-author {
    font-size: 12px !important;
  }
  
  .aplayer .aplayer-lrc {
    display: none !important;
  }
}

.am-form-group {
  margin-bottom: 1.5rem;
}

.am-form-field {
  border-radius: 4px;
  padding: 0.7em 1em;
  transition: all 0.3s ease;
}

.am-form-field:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

.am-input-group-sm .am-input-group-label, 
.am-input-group-sm .am-form-field, 
.am-input-group-sm .am-btn {
  border-radius: 4px;
  font-size: 14px;
}

/* Responsive design improvements */
@media only screen and (max-width: 640px) {
  .about-title {
    font-size: 1.8rem;
  }
}

/* Animation for player elements */
@keyframes rotate {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

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

.aplayer-pic-animation {
  animation: rotate 18s linear infinite;
  box-shadow: 0 0 20px rgba(52, 152, 219, 0.4) !important;
}

.aplayer-lrc {
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.5s ease;
}

.aplayer-lrc-show {
  opacity: 1;
  transform: translateY(0);
}

.aplayer-list ol li {
  animation: fadeIn 0.3s ease-out forwards;
  opacity: 0;
}

.aplayer-list ol li:nth-child(1) { animation-delay: 0.05s; }
.aplayer-list ol li:nth-child(2) { animation-delay: 0.1s; }
.aplayer-list ol li:nth-child(3) { animation-delay: 0.15s; }
.aplayer-list ol li:nth-child(4) { animation-delay: 0.2s; }
.aplayer-list ol li:nth-child(5) { animation-delay: 0.25s; }
.aplayer-list ol li:nth-child(6) { animation-delay: 0.3s; }
.aplayer-list ol li:nth-child(7) { animation-delay: 0.35s; }
.aplayer-list ol li:nth-child(8) { animation-delay: 0.4s; }
.aplayer-list ol li:nth-child(9) { animation-delay: 0.45s; }
.aplayer-list ol li:nth-child(10) { animation-delay: 0.5s; }

/* Music Visualizer */
.music-visualizer {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 40px;
  margin-top: 15px;
  padding: 10px;
  border-radius: 20px;
  background: linear-gradient(to right, rgba(52, 152, 219, 0.05), rgba(46, 204, 113, 0.05));
  overflow: hidden;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.5s ease;
}

.music-visualizer.active {
  opacity: 1;
  transform: translateY(0);
}

.visualizer-bar {
  width: 5px;
  height: 5px;
  margin: 0 5px;
  background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
  border-radius: 5px;
  transition: height 0.2s ease;
}

.visualizer-bar:nth-child(1) { animation-delay: 0.1s; }
.visualizer-bar:nth-child(2) { animation-delay: 0.2s; }
.visualizer-bar:nth-child(3) { animation-delay: 0.3s; }
.visualizer-bar:nth-child(4) { animation-delay: 0.4s; }
.visualizer-bar:nth-child(5) { animation-delay: 0.5s; }

@media only screen and (max-width: 640px) {
  .music-visualizer {
    height: 30px;
  }
}

/* 播放页按钮样式 */
.go-player-btn {
  background: linear-gradient(45deg, var(--secondary-color), #1abc9c) !important;
  border-color: var(--secondary-color) !important;
  color: white !important;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(46, 204, 113, 0.3);
  position: relative;
  overflow: hidden;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(46, 204, 113, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(46, 204, 113, 0);
  }
}

.go-player-btn:before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: rgba(255, 255, 255, 0.1);
  transform: rotate(45deg);
  animation: shine 3s infinite linear;
  pointer-events: none;
}

@keyframes shine {
  0% {
    transform: translateX(-100%) rotate(45deg);
  }
  100% {
    transform: translateX(100%) rotate(45deg);
  }
}

.go-player-btn:hover, 
.go-player-btn:focus {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(46, 204, 113, 0.4);
  background: linear-gradient(45deg, #1abc9c, var(--secondary-color)) !important;
}
