/* 全局样式 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  line-height: 1.6;
  color: #333;
  background: linear-gradient(135deg, #f5f7fa 0%, #e9ecef 100%);
  min-height: 100vh;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* 页眉 */
.header {
  background: linear-gradient(135deg, #1e3c72 0%, #2c5aa0 100%);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
}

.logo {
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: 1px;
  white-space: nowrap;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.logo:hover {
  color: #ffd700;
  transition: color 0.3s;
}

.main-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.5rem;
}

.main-nav a {
  padding: 0.6rem 1.2rem;
  text-decoration: none;
  color: #fff;
  white-space: nowrap;
  transition: all 0.3s;
  border-radius: 6px;
  font-weight: 500;
  background: rgba(255,255,255,0.1);
}

.main-nav a:hover {
  background: rgba(255,255,255,0.25);
  transform: translateY(-2px);
}

.main-nav a.active {
  background: #ffd700;
  color: #1e3c72;
  box-shadow: 0 2px 8px rgba(255,215,0,0.4);
}

/* 首页英雄区 */
.hero {
  text-align: center;
  padding: 3rem 1rem;
  background: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(255,255,255,0.7));
  border-radius: 12px;
  margin-bottom: 2rem;
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.hero-title {
  font-size: 2rem;
  color: #1e3c72;
  margin-bottom: 1rem;
  line-height: 1.4;
}

/* 介绍区块 */
.intro-section {
  background: #fff;
  padding: 2rem;
  border-radius: 12px;
  margin-bottom: 3rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  line-height: 1.8;
  font-size: 1.05rem;
}

.intro-section p {
  color: #555;
}

/* 区块标题 */
section h2 {
  font-size: 1.8rem;
  color: #1e3c72;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 3px solid #2c5aa0;
}

.section-desc {
  color: #666;
  margin-bottom: 1.5rem;
}

.section-desc a {
  color: #2c5aa0;
  text-decoration: none;
  font-weight: 500;
}

.section-desc a:hover {
  text-decoration: underline;
}

/* 视频卡片网格 */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.video-card {
  background: #fff;
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: all 0.3s;
}

.video-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.video-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.video-card h3 a {
  color: #1e3c72;
  text-decoration: none;
}

.video-card h3 a:hover {
  color: #2c5aa0;
}

.video-meta {
  color: #999;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.video-desc {
  color: #666;
  font-size: 0.95rem;
  line-height: 1.6;
}

/* 排行榜列表 */
.rank-list {
  background: #fff;
  border-radius: 10px;
  padding: 1.5rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  margin-bottom: 3rem;
}

.rank-item {
  display: flex;
  align-items: center;
  padding: 0.8rem 0;
  border-bottom: 1px solid #eee;
  gap: 1rem;
}

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

.rank-num {
  font-size: 1.2rem;
  font-weight: bold;
  color: #2c5aa0;
  min-width: 2rem;
  text-align: center;
}

.rank-item a {
  flex: 1;
  color: #333;
  text-decoration: none;
  font-weight: 500;
}

.rank-item a:hover {
  color: #2c5aa0;
}

.rank-year {
  color: #999;
  font-size: 0.9rem;
}

/* 最新列表 */
.latest-list {
  display: grid;
  gap: 1.5rem;
}

.latest-item {
  background: #fff;
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: all 0.3s;
}

.latest-item:hover {
  transform: translateX(5px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

.latest-item h4 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.latest-item h4 a {
  color: #1e3c72;
  text-decoration: none;
}

.latest-item h4 a:hover {
  color: #2c5aa0;
}

.latest-meta {
  color: #999;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.latest-desc {
  color: #666;
  line-height: 1.6;
}

/* 列表页样式 */
.page-title {
  font-size: 2rem;
  color: #1e3c72;
  margin-bottom: 1rem;
  padding: 2rem;
  background: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(255,255,255,0.7));
  border-radius: 12px;
  text-align: center;
}

.page-desc {
  background: #fff;
  padding: 1.5rem;
  border-radius: 10px;
  margin-bottom: 2rem;
  line-height: 1.8;
  color: #555;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.list-content {
  display: grid;
  gap: 1.5rem;
}

/* 大全页卡片 */
.daquan-card {
  background: #fff;
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: all 0.3s;
}

.daquan-card:hover {
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.8rem;
}

.card-header h3 {
  font-size: 1.3rem;
}

.card-header h3 a {
  color: #1e3c72;
  text-decoration: none;
}

.card-header h3 a:hover {
  color: #2c5aa0;
}

.card-id {
  color: #999;
  font-size: 0.85rem;
  background: #f5f5f5;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
}

.card-meta {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 0.8rem;
}

.card-desc {
  color: #666;
  line-height: 1.7;
  margin-bottom: 0.8rem;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  background: #e3f2fd;
  color: #2c5aa0;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.85rem;
}

/* 排行榜页卡片 */
.top-card {
  background: #fff;
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  display: flex;
  align-items: center;
  gap: 1.5rem;
  transition: all 0.3s;
}

.top-card:hover {
  transform: translateX(5px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

.rank-badge {
  font-size: 2rem;
  font-weight: bold;
  color: #fff;
  background: linear-gradient(135deg, #2c5aa0, #1e3c72);
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  flex-shrink: 0;
}

.card-content {
  flex: 1;
}

.card-content h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.card-content h3 a {
  color: #1e3c72;
  text-decoration: none;
}

.card-content h3 a:hover {
  color: #2c5aa0;
}

/* 专题页样式 */
.topic-group {
  background: #fff;
  padding: 2rem;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  margin-bottom: 2rem;
}

.group-title {
  font-size: 1.5rem;
  color: #1e3c72;
  margin-bottom: 1.5rem;
  padding-bottom: 0.8rem;
  border-bottom: 2px solid #2c5aa0;
}

.topic-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1rem;
}

.topic-card {
  padding: 1rem;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  transition: all 0.3s;
}

.topic-card:hover {
  border-color: #2c5aa0;
  box-shadow: 0 4px 12px rgba(44,90,160,0.2);
}

.topic-card h4 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.topic-card h4 a {
  color: #333;
  text-decoration: none;
}

.topic-card h4 a:hover {
  color: #2c5aa0;
}

.card-year {
  color: #999;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

/* 最新页卡片 */
.latest-card {
  background: #fff;
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  display: flex;
  gap: 1.5rem;
  transition: all 0.3s;
}

.latest-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

.latest-date {
  font-size: 1.5rem;
  font-weight: bold;
  color: #2c5aa0;
  background: #f5f5f5;
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  min-width: 80px;
}

/* 详情页样式 */
.detail-page {
  max-width: 900px;
}

.video-detail {
  background: #fff;
  padding: 2.5rem;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.detail-title {
  font-size: 2rem;
  color: #1e3c72;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 3px solid #2c5aa0;
}

.video-info {
  background: #f8f9fa;
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 2rem;
}

.info-row {
  display: flex;
  padding: 0.5rem 0;
  border-bottom: 1px solid #e0e0e0;
}

.info-row:last-child {
  border-bottom: none;
}

.info-row .label {
  font-weight: 600;
  color: #555;
  min-width: 80px;
}

.info-row span:last-child {
  color: #666;
  flex: 1;
}

.video-oneline,
.video-summary,
.video-review {
  margin-bottom: 2rem;
}

.video-oneline h3,
.video-summary h3,
.video-review h3 {
  font-size: 1.3rem;
  color: #1e3c72;
  margin-bottom: 1rem;
}

.video-oneline p,
.video-summary p,
.video-review p {
  color: #555;
  line-height: 1.8;
  font-size: 1.05rem;
}

/* 相关推荐 */
.related-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 2px solid #e0e0e0;
}

.related-section h3 {
  font-size: 1.5rem;
  color: #1e3c72;
  margin-bottom: 1.5rem;
}

.related-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}

.related-item {
  background: #f8f9fa;
  padding: 1.2rem;
  border-radius: 8px;
  transition: all 0.3s;
}

.related-item:hover {
  background: #e9ecef;
  transform: translateY(-3px);
}

.related-item h4 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.related-item h4 a {
  color: #1e3c72;
  text-decoration: none;
}

.related-item h4 a:hover {
  color: #2c5aa0;
}

.related-desc {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.6;
}

/* 页脚 */
.footer {
  background: #1e3c72;
  color: #fff;
  text-align: center;
  padding: 2rem 1rem;
  margin-top: 4rem;
}

.footer p {
  color: rgba(255,255,255,0.8);
}

/* 响应式 */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: 0.8rem;
    padding: 0.8rem;
  }

  .logo {
    font-size: 1.4rem;
  }

  .main-nav {
    width: 100%;
    justify-content: space-between;
    gap: 0;
    overflow-x: hidden;
  }

  .main-nav a {
    flex: 1 1 0;
    min-width: 0;
    text-align: center;
    padding: 0.5rem 0.2rem;
    font-size: 0.8rem;
    overflow: hidden;
    text-overflow: ellipsis;
  }

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

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

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

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

  .video-detail {
    padding: 1.5rem;
  }

  .related-list {
    grid-template-columns: 1fr;
  }

  .topic-items {
    grid-template-columns: 1fr;
  }

  .top-card {
    flex-direction: column;
    text-align: center;
  }

  .latest-card {
    flex-direction: column;
  }

  .latest-date {
    width: 100%;
  }
}

/* UI 样式变体 */
body.ui-style-0 { --primary: #1e3c72; --accent: #2c5aa0; }
body.ui-style-1 { --primary: #0f2027; --accent: #2c5364; }
body.ui-style-2 { --primary: #283048; --accent: #859398; }
body.ui-style-3 { --primary: #1e3c72; --accent: #2c5aa0; }
body.ui-style-4 { --primary: #141e30; --accent: #243b55; }
body.ui-style-5 { --primary: #000428; --accent: #004e92; }
