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

body {
  font-family: 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', sans-serif;
  background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf1 100%);
  color: #2c3e50;
  line-height: 1.8;
  font-size: 16px;
}

a {
  text-decoration: none;
  color: #3498db;
  transition: color 0.3s ease;
}

a:hover {
  color: #2980b9;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* 导航栏样式 */
nav {
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  color: white;
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

nav .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
}

nav .logo {
  font-size: 28px;
  font-weight: bold;
  letter-spacing: 2px;
  white-space: nowrap;
  background: linear-gradient(45deg, #fff, #ecf0f1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 5px;
  flex-wrap: nowrap;
  align-items: center;
  flex: 1;
  justify-content: flex-end;
  margin: 0;
  padding: 0;
}

nav ul li {
  white-space: nowrap;
  flex: 1 1 0;
  min-width: 0;
  text-align: center;
}

nav ul li a {
  display: block;
  padding: 10px 15px;
  color: white;
  border-radius: 6px;
  transition: all 0.3s ease;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
}

nav ul li a:hover {
  background: rgba(52, 152, 219, 0.2);
  transform: translateY(-2px);
}

/* 页面头部 */
.page-header {
  text-align: center;
  padding: 60px 20px;
  background: white;
  border-radius: 12px;
  margin-bottom: 40px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.page-header h1 {
  font-size: 36px;
  color: #2c3e50;
  margin-bottom: 20px;
  font-weight: 700;
  line-height: 1.4;
}

.page-header .intro {
  font-size: 18px;
  color: #7f8c8d;
  max-width: 900px;
  margin: 0 auto;
  line-height: 1.8;
}

/* 区块样式 */
.section {
  background: white;
  border-radius: 12px;
  padding: 40px;
  margin-bottom: 30px;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
}

.section h2 {
  font-size: 28px;
  color: #2c3e50;
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 3px solid #3498db;
  font-weight: 600;
}

.section h3 {
  font-size: 22px;
  color: #34495e;
  margin-bottom: 20px;
}

/* 网格布局 */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 25px;
}

.card {
  background: #f8f9fa;
  padding: 25px;
  border-radius: 10px;
  transition: all 0.3s ease;
  border: 1px solid #e9ecef;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 24px rgba(52, 152, 219, 0.15);
  border-color: #3498db;
}

.card h3 {
  font-size: 20px;
  margin-bottom: 12px;
  color: #2c3e50;
}

.card h3 a {
  color: #2c3e50;
}

.card h3 a:hover {
  color: #3498db;
}

.card .meta {
  font-size: 14px;
  color: #95a5a6;
  margin-bottom: 10px;
}

.card .oneline {
  font-size: 15px;
  color: #7f8c8d;
  line-height: 1.6;
}

/* 排行榜样式 */
.rank-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.rank-item:hover {
  background: #e9ecef;
  transform: translateX(5px);
}

.rank-num {
  display: inline-block;
  width: 40px;
  height: 40px;
  line-height: 40px;
  text-align: center;
  background: linear-gradient(135deg, #3498db, #2980b9);
  color: white;
  border-radius: 50%;
  font-weight: bold;
  font-size: 18px;
  flex-shrink: 0;
}

.rank-item a {
  color: #2c3e50;
  font-size: 18px;
  font-weight: 500;
}

.rank-item a:hover {
  color: #3498db;
}

/* 列表卡片 */
.list-grid {
  display: grid;
  gap: 25px;
}

.list-card {
  background: white;
  padding: 30px;
  border-radius: 10px;
  border-left: 4px solid #3498db;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.list-card:hover {
  box-shadow: 0 6px 20px rgba(52, 152, 219, 0.15);
  transform: translateX(5px);
}

.list-card h3 {
  font-size: 22px;
  margin-bottom: 12px;
  color: #2c3e50;
}

.list-card h3 a {
  color: #2c3e50;
}

.list-card h3 a:hover {
  color: #3498db;
}

.list-card .meta {
  font-size: 14px;
  color: #95a5a6;
  margin-bottom: 8px;
}

.list-card .tags {
  font-size: 13px;
  color: #7f8c8d;
  margin-bottom: 12px;
}

.list-card .desc {
  font-size: 16px;
  color: #34495e;
  line-height: 1.7;
}

/* 排行榜卡片 */
.rank-container {
  display: grid;
  gap: 20px;
}

.rank-card {
  display: flex;
  gap: 20px;
  background: white;
  padding: 25px;
  border-radius: 10px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.rank-card:hover {
  box-shadow: 0 6px 20px rgba(52, 152, 219, 0.15);
  transform: translateY(-3px);
}

.rank-badge {
  width: 60px;
  height: 60px;
  line-height: 60px;
  text-align: center;
  background: linear-gradient(135deg, #3498db, #2980b9);
  color: white;
  font-size: 24px;
  font-weight: bold;
  border-radius: 12px;
  flex-shrink: 0;
}

.rank-content {
  flex: 1;
}

.rank-content h3 {
  font-size: 20px;
  margin-bottom: 10px;
  color: #2c3e50;
}

.rank-content h3 a {
  color: #2c3e50;
}

.rank-content h3 a:hover {
  color: #3498db;
}

.rank-content .meta {
  font-size: 14px;
  color: #95a5a6;
  margin-bottom: 8px;
}

.rank-content .desc {
  font-size: 15px;
  color: #7f8c8d;
  line-height: 1.6;
}

/* 专题样式 */
.topic-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 25px;
}

.topic-group {
  background: white;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.topic-group h3 {
  font-size: 20px;
  color: #2c3e50;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #3498db;
}

.topic-group ul {
  list-style: none;
  padding: 0;
}

.topic-group ul li {
  margin-bottom: 12px;
  padding-left: 20px;
  position: relative;
  font-size: 15px;
  line-height: 1.6;
}

.topic-group ul li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: #3498db;
  font-weight: bold;
}

.topic-group ul li a {
  color: #34495e;
}

.topic-group ul li a:hover {
  color: #3498db;
}

/* 最新整理 */
.latest-grid {
  display: grid;
  gap: 25px;
}

.latest-card {
  background: white;
  padding: 30px;
  border-radius: 10px;
  position: relative;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.latest-card:hover {
  box-shadow: 0 6px 20px rgba(52, 152, 219, 0.15);
  transform: translateX(5px);
}

.year-tag {
  position: absolute;
  top: 20px;
  right: 20px;
  background: linear-gradient(135deg, #3498db, #2980b9);
  color: white;
  padding: 6px 15px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: bold;
}

.latest-card h3 {
  font-size: 22px;
  margin-bottom: 12px;
  color: #2c3e50;
  padding-right: 80px;
}

.latest-card h3 a {
  color: #2c3e50;
}

.latest-card h3 a:hover {
  color: #3498db;
}

.latest-card .meta {
  font-size: 14px;
  color: #95a5a6;
  margin-bottom: 10px;
}

.latest-card .desc {
  font-size: 16px;
  color: #34495e;
  line-height: 1.7;
}

/* 详情页样式 */
.detail {
  background: white;
  border-radius: 12px;
  padding: 50px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.detail-header {
  text-align: center;
  padding-bottom: 40px;
  border-bottom: 3px solid #3498db;
  margin-bottom: 40px;
}

.detail-header h1 {
  font-size: 42px;
  color: #2c3e50;
  margin-bottom: 15px;
  font-weight: 700;
}

.detail-header .subtitle {
  font-size: 18px;
  color: #7f8c8d;
}

.detail-section {
  margin-bottom: 40px;
}

.detail-section h2 {
  font-size: 26px;
  color: #2c3e50;
  margin-bottom: 20px;
  padding-left: 15px;
  border-left: 5px solid #3498db;
  font-weight: 600;
}

.info-list {
  list-style: none;
  padding: 0;
}

.info-list li {
  padding: 12px 0;
  border-bottom: 1px solid #ecf0f1;
  font-size: 16px;
  line-height: 1.8;
}

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

.info-list strong {
  color: #2c3e50;
  margin-right: 10px;
  display: inline-block;
  min-width: 80px;
}

.highlight {
  font-size: 20px;
  color: #3498db;
  font-weight: 500;
  padding: 20px;
  background: #ecf8ff;
  border-radius: 8px;
  border-left: 4px solid #3498db;
}

.summary {
  font-size: 17px;
  color: #34495e;
  line-height: 2;
  text-align: justify;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.related-item {
  background: #f8f9fa;
  padding: 20px;
  border-radius: 8px;
  transition: all 0.3s ease;
  border: 1px solid #e9ecef;
}

.related-item:hover {
  border-color: #3498db;
  box-shadow: 0 4px 16px rgba(52, 152, 219, 0.15);
  transform: translateY(-3px);
}

.related-item h4 {
  font-size: 18px;
  margin-bottom: 10px;
  color: #2c3e50;
}

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

.related-item h4 a:hover {
  color: #3498db;
}

.related-item p {
  font-size: 15px;
  color: #7f8c8d;
  line-height: 1.6;
}

/* 更多链接 */
.more-link {
  text-align: center;
  margin-top: 30px;
}

.more-link a {
  display: inline-block;
  padding: 12px 30px;
  background: linear-gradient(135deg, #3498db, #2980b9);
  color: white;
  border-radius: 25px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.more-link a:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(52, 152, 219, 0.3);
}

.text-links {
  list-style: none;
  padding: 20px 0;
}

.text-links li {
  display: inline-block;
  margin-right: 30px;
  margin-bottom: 15px;
}

.text-links li a {
  font-size: 18px;
  color: #3498db;
  padding: 8px 16px;
  border-radius: 5px;
  transition: all 0.3s ease;
}

.text-links li a:hover {
  background: #ecf8ff;
}

/* 响应式设计 */
@media (max-width: 768px) {
  nav .container {
    flex-direction: column;
    gap: 10px;
  }

  nav .logo {
    font-size: 22px;
  }

  nav ul {
    width: 100%;
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 2px;
    overflow: hidden;
  }

  nav ul li {
    flex: 1 1 0;
    min-width: 0;
    font-size: 13px;
  }

  nav ul li a {
    padding: 8px 5px;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .page-header h1 {
    font-size: 28px;
  }

  .page-header .intro {
    font-size: 16px;
  }

  .section {
    padding: 25px;
  }

  .section h2 {
    font-size: 24px;
  }

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

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

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

  .detail {
    padding: 30px 20px;
  }

  .detail-header h1 {
    font-size: 32px;
  }
}

@media (max-width: 480px) {
  nav .logo {
    font-size: 18px;
  }

  nav ul li {
    font-size: 11px;
  }

  nav ul li a {
    padding: 6px 3px;
    font-size: 11px;
  }

  .page-header {
    padding: 40px 15px;
  }

  .page-header h1 {
    font-size: 24px;
  }

  .section {
    padding: 20px;
  }

  .detail {
    padding: 25px 15px;
  }

  .detail-header h1 {
    font-size: 28px;
  }
}
