/**
 * 歌词易(geciyi.com) - 主样式文件
 */

/* 全局样式 */
:root {
  --primary-color: #8b5cf6;
  --primary-dark: #7c3aed;
  --secondary-color: #ec4899;
  --text-color: #1f2937;
  --light-gray: #f3f4f6;
  --dark-gray: #4b5563;
}

body {
  font-family: 'Noto Sans TC', sans-serif;
  color: var(--text-color);
  line-height: 1.6;
  background-color: #f9fafb;
}

/* 头部导航 */
.navbar {
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 100;
  transition: all 0.3s ease;
}

.navbar.scrolled {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.logo {
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--primary-color);
}

.nav-link {
  position: relative;
  transition: all 0.3s ease;
}

.nav-link:after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.nav-link:hover:after {
  width: 100%;
}

/* 语言切换器 */
.lang-switcher {
  cursor: pointer;
  transition: all 0.3s ease;
}

.lang-switcher:hover {
  color: var(--primary-color);
}

/* 英雄区域 */
.hero-section {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('/static/images/music-notes.svg');
  background-repeat: repeat;
  background-size: 100px;
  opacity: 0.1;
}

.search-container {
  max-width: 900px;
  position: relative;
  z-index: 2;
}

.recommended-search {
  cursor: pointer;
}

/* 按钮效果 */
.btn-hover-effect {
  position: relative;
  overflow: hidden;
}

.btn-hover-effect::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-hover-effect:hover::after {
  width: 300px;
  height: 300px;
}

/* 歌词卡片 */
.lyric-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.lyric-card:hover {
  transform: translateY(-5px);
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 特性卡片 */
.feature-card {
  transition: transform 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-10px);
}

.feature-icon {
  transition: transform 0.5s ease;
}

.feature-card:hover .feature-icon {
  transform: scale(1.2);
}

/* FAQ部分 */
.faq-question {
  transition: background-color 0.3s ease;
}

.faq-question:hover {
  background-color: #f9fafb;
}

.faq-answer {
  transition: all 0.3s ease;
}

/* 分页 */
.pagination .active {
  background-color: var(--primary-color);
  color: white;
}

.pagination a {
  transition: all 0.3s ease;
}

.pagination a:hover:not(.active) {
  background-color: #f3f4f6;
}

/* 详情页 */
.song-details {
  border-left: 4px solid var(--primary-color);
}

.lyrics-content {
  white-space: pre-line;
  line-height: 1.8;
}

.like-button {
  transition: all 0.3s ease;
}

.like-button:hover {
  transform: scale(1.1);
}

.like-button.liked {
  color: #ec4899;
}

/* 页脚 */
.footer {
  background-color: #1f2937;
}

.footer-link {
  transition: color 0.3s ease;
}

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

/* 响应式调整 */
@media (max-width: 768px) {
  .hero-section {
    padding: 2rem 0;
  }
  
  .feature-card {
    margin-bottom: 1.5rem;
  }
}

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

.fade-in {
  animation: fadeIn 0.5s ease forwards;
}

/* 搜索结果动画 */
#search-results {
  transition: all 0.5s ease;
}

/* 移动菜单 */
.mobile-menu {
  transition: transform 0.3s ease;
  transform: translateX(-100%);
}

.mobile-menu.open {
  transform: translateX(0);
}

/* 面包屑导航 */
.breadcrumb {
  background-color: transparent;
}

.breadcrumb-item + .breadcrumb-item::before {
  content: ">";
}

/* 标签样式 */
.tag {
  background-color: #e5e7eb;
  color: var(--dark-gray);
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  transition: all 0.3s ease;
}

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

/* 加载动画 */
.loading {
  display: inline-block;
  width: 1.5rem;
  height: 1.5rem;
  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); }
} 