/* 汽车音响 - 样式表 */
/* 基于歌词风格布局，主色调: #e91e63 */

/* CSS 变量 */
:root {
  --accent-color: #e91e63;
  --accent-light: #f48fb1;
  --accent-dark: #c2185b;
  --text-primary: #212121;
  --text-secondary: #757575;
  --text-muted: #9e9e9e;
  --bg-primary: #ffffff;
  --bg-secondary: #fafafa;
  --bg-dark: #263238;
  --border-color: #e0e0e0;
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --max-width: 1200px;
  --header-height: 64px;
}

/* 重置样式 */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

/* 容器 */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* 头部 */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent-color);
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--accent-color), var(--accent-dark));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.1rem;
}

.nav {
  display: flex;
  gap: 32px;
}

.nav a {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s;
}

.nav a:hover,
.nav a.active {
  color: var(--accent-color);
}

.search-box {
  position: relative;
  width: 240px;
}

.search-box input {
  width: 100%;
  padding: 10px 16px 10px 40px;
  border: 1px solid var(--border-color);
  border-radius: 24px;
  font-size: 0.875rem;
  background: var(--bg-secondary);
  transition: all 0.2s;
}

.search-box input:focus {
  outline: none;
  border-color: var(--accent-color);
  background: var(--bg-primary);
}

.search-box::before {
  content: "🔍";
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.875rem;
  opacity: 0.5;
}

/* Hero 区域 */
.hero {
  padding: 60px 0;
  text-align: center;
  background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.hero-title span {
  color: var(--accent-color);
}

.hero-desc {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 32px;
}

.hero-search {
  max-width: 560px;
  margin: 0 auto;
}

.hero-search input {
  width: 100%;
  padding: 16px 24px;
  border: 2px solid var(--border-color);
  border-radius: 32px;
  font-size: 1rem;
  text-align: center;
  transition: all 0.2s;
}

.hero-search input:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 4px rgba(233, 30, 99, 0.1);
}

/* 分类标签 */
.genre-tags {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
  flex-wrap: wrap;
}

.genre-tag {
  padding: 8px 20px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  font-size: 0.875rem;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.genre-tag:hover {
  border-color: var(--accent-color);
  color: var(--accent-color);
}

.genre-tag.active {
  background: var(--accent-color);
  border-color: var(--accent-color);
  color: white;
}

/* 区块标题 */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

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

.section-more {
  font-size: 0.875rem;
  color: var(--accent-color);
  font-weight: 500;
}

.section-more:hover {
  text-decoration: underline;
}

/* 内容区块 */
.section {
  padding: 48px 0;
}

.section-alt {
  background: var(--bg-secondary);
}

/* 卡片网格 */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

/* 卡片 */
.card {
  background: var(--bg-primary);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  transition: all 0.2s;
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card-image {
  aspect-ratio: 16/10;
  background: linear-gradient(135deg, var(--bg-secondary), var(--border-color));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 2.5rem;
}

.card-body {
  padding: 20px;
}

.card-title {
  font-size: 1.0625rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text-primary);
  line-height: 1.4;
}

.card-meta {
  font-size: 0.875rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-meta span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* 列表项 */
.list-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border-color);
}

.list-item:last-child {
  border-bottom: none;
}

.list-number {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.list-number.top {
  background: var(--accent-color);
  color: white;
}

.list-content {
  flex: 1;
}

.list-title {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.list-desc {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* 三栏布局 */
.three-col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.col-section {
  background: var(--bg-primary);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--border-color);
}

.col-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--accent-color);
  display: inline-block;
}

/* 面包屑 */
.breadcrumb {
  padding: 16px 0;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.breadcrumb a:hover {
  color: var(--accent-color);
}

.breadcrumb span {
  margin: 0 8px;
  color: var(--text-muted);
}

/* 页面标题 */
.page-header {
  padding: 40px 0;
  text-align: center;
  background: var(--bg-secondary);
}

.page-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.page-desc {
  color: var(--text-secondary);
}

/* 排序选项 */
.sort-options {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 20px;
}

.sort-options a {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
}

.sort-options a:hover,
.sort-options a.active {
  color: var(--accent-color);
  border-bottom-color: var(--accent-color);
}

/* 分页 */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
}

.pagination a,
.pagination span {
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  font-size: 0.9375rem;
  transition: all 0.2s;
}

.pagination a {
  background: var(--bg-secondary);
  color: var(--text-secondary);
}

.pagination a:hover {
  background: var(--accent-color);
  color: white;
}

.pagination span {
  background: var(--accent-color);
  color: white;
}

/* 文章详情 */
.article-header {
  text-align: center;
  padding: 48px 0;
}

.article-image {
  width: 200px;
  height: 200px;
  margin: 0 auto 32px;
  background: linear-gradient(135deg, var(--bg-secondary), var(--border-color));
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  box-shadow: var(--shadow-md);
}

.article-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.article-meta {
  display: flex;
  justify-content: center;
  gap: 16px;
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.article-meta span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.article-info {
  max-width: 600px;
  margin: 32px auto 0;
  padding: 20px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  text-align: left;
}

.article-info-item {
  display: flex;
  padding: 8px 0;
  font-size: 0.9375rem;
}

.article-info-label {
  width: 100px;
  color: var(--text-secondary);
}

.article-info-value {
  flex: 1;
  color: var(--text-primary);
  font-weight: 500;
}

/* 文章内容 */
.article-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 48px 20px;
}

.article-content h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 40px 0 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--accent-color);
}

.article-content p {
  margin-bottom: 20px;
  line-height: 1.8;
  color: var(--text-primary);
}

.lyrics-box {
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  padding: 40px;
  margin: 32px 0;
  text-align: center;
  border-left: 4px solid var(--accent-color);
}

.lyrics-box p {
  margin-bottom: 16px;
  font-size: 1.0625rem;
  line-height: 2;
  color: var(--text-primary);
}

.lyrics-box p:last-child {
  margin-bottom: 0;
}

/* 相关推荐 */
.related-section {
  background: var(--bg-secondary);
  padding: 48px 0;
}

.related-title {
  text-align: center;
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 32px;
}

.related-grid {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.related-item {
  width: 160px;
  text-align: center;
}

.related-thumb {
  width: 160px;
  height: 160px;
  background: linear-gradient(135deg, var(--bg-secondary), var(--border-color));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
}

.related-name {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-primary);
}

/* 404 页面 */
.error-page {
  min-height: calc(100vh - var(--header-height) - 300px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px;
}

.error-code {
  font-size: 8rem;
  font-weight: 700;
  color: var(--accent-color);
  line-height: 1;
  margin-bottom: 16px;
  opacity: 0.8;
}

.error-title {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.error-desc {
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.error-btn {
  display: inline-block;
  padding: 14px 32px;
  background: var(--accent-color);
  color: white;
  border-radius: 24px;
  font-weight: 500;
  transition: all 0.2s;
}

.error-btn:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* 页脚 */
.footer {
  background: var(--bg-dark);
  color: rgba(255,255,255,0.7);
  padding: 48px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand {
  color: white;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.footer-desc {
  font-size: 0.875rem;
  line-height: 1.7;
  opacity: 0.8;
}

.footer-title {
  color: white;
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: 16px;
}

.footer-links a {
  display: block;
  padding: 6px 0;
  font-size: 0.875rem;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--accent-light);
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center;
  font-size: 0.875rem;
  opacity: 0.6;
}

/* 响应式设计 */
@media (max-width: 1024px) {
  .three-col {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav {
    display: none;
  }

  .search-box {
    width: 160px;
  }

  .hero-title {
    font-size: 1.75rem;
  }

  .hero-desc {
    font-size: 1rem;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .article-title {
    font-size: 1.5rem;
  }

  .article-meta {
    flex-wrap: wrap;
    justify-content: center;
  }

  .lyrics-box {
    padding: 24px;
  }

  .error-code {
    font-size: 5rem;
  }
}

@media (max-width: 480px) {
  .genre-tags {
    gap: 8px;
  }

  .genre-tag {
    padding: 6px 14px;
    font-size: 0.8125rem;
  }

  .pagination a,
  .pagination span {
    min-width: 36px;
    height: 36px;
    font-size: 0.875rem;
  }
}
