/* UI Style 15 - Layout Variant D */

/* 全局样式 */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

main {
  min-height: calc(100vh - 200px);
}

/* 页眉区域 */
.hero {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 60px 20px;
  text-align: center;
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 15px;
  font-weight: 700;
}

.hero .subtitle {
  font-size: 1.1rem;
  opacity: 0.95;
}

/* 介绍区域 */
.intro {
  background: white;
  padding: 50px 20px;
  margin: 30px 0;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.intro-content p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #555;
}

/* 分区标题 */
section h2 {
  font-size: 2rem;
  margin-bottom: 10px;
  color: #2c3e50;
  border-left: 4px solid #667eea;
  padding-left: 15px;
}

.section-desc {
  color: #666;
  margin-bottom: 30px;
  font-size: 1rem;
}

/* 分区容器 */
.featured, .top-section, .latest-section {
  padding: 50px 20px;
  margin: 30px 0;
}

.featured {
  background: white;
  border-radius: 8px;
}

.top-section {
  background: #f9f9f9;
}

.latest-section {
  background: white;
  border-radius: 8px;
}

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

.card {
  background: white;
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: transform 0.3s, box-shadow 0.3s;
  position: relative;
}

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

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

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

.card h3 a:hover {
  color: #667eea;
}

.card .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 0.9rem;
  color: #777;
}

.badge {
  background: #667eea;
  color: white;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.85rem;
}

.badge-small {
  background: #764ba2;
  color: white;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.8rem;
}

.card .summary {
  color: #555;
  line-height: 1.6;
  margin-bottom: 12px;
  font-size: 0.95rem;
}

.card .review-snippet {
  font-style: italic;
  color: #888;
  font-size: 0.9rem;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #eee;
}

.card .read-more {
  display: inline-block;
  color: #667eea;
  font-weight: 500;
  margin-top: 10px;
  transition: transform 0.3s;
}

.card .read-more:hover {
  transform: translateX(5px);
}

/* 列表页特殊标识 */
.rank-number {
  position: absolute;
  top: 10px;
  right: 10px;
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 0.9rem;
}

.topic-tag {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #4facfe;
  color: white;
  padding: 5px 12px;
  border-radius: 15px;
  font-size: 0.8rem;
}

.date-tag {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #43e97b;
  color: white;
  padding: 5px 12px;
  border-radius: 15px;
  font-size: 0.8rem;
}

/* 列表视图 */
.list-view {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 30px;
}

.list-item {
  background: white;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  display: flex;
  gap: 20px;
  align-items: flex-start;
  transition: box-shadow 0.3s;
}

.list-item:hover {
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

.list-item .rank {
  font-size: 2rem;
  font-weight: bold;
  color: #667eea;
  min-width: 50px;
  text-align: center;
}

.list-item .list-content {
  flex: 1;
}

.list-item h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
  color: #2c3e50;
}

.list-item h3 a:hover {
  color: #667eea;
}

.list-item p {
  color: #555;
  line-height: 1.6;
  margin-bottom: 8px;
}

.meta-small {
  font-size: 0.85rem;
  color: #888;
}

/* 时间轴视图 */
.timeline-view {
  position: relative;
  padding-left: 30px;
  margin-bottom: 30px;
}

.timeline-view::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #ddd;
}

.timeline-item {
  position: relative;
  margin-bottom: 30px;
  padding-left: 30px;
}

.timeline-marker {
  position: absolute;
  left: -26px;
  top: 5px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #667eea;
  border: 2px solid white;
  box-shadow: 0 0 0 2px #667eea;
}

.timeline-content {
  background: white;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: box-shadow 0.3s;
}

.timeline-content:hover {
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

.timeline-content h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
  color: #2c3e50;
}

.timeline-content h3 a:hover {
  color: #667eea;
}

.timeline-meta {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 0.85rem;
  color: #888;
}

.timeline-content p {
  color: #555;
  line-height: 1.6;
}

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

.more-link a {
  display: inline-block;
  padding: 12px 30px;
  background: #667eea;
  color: white;
  border-radius: 25px;
  font-weight: 500;
  transition: background 0.3s, transform 0.3s;
}

.more-link a:hover {
  background: #5568d3;
  transform: translateY(-2px);
}

/* 列表页样式 */
.page-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 50px 20px;
  text-align: center;
}

.page-header h1 {
  font-size: 2.5rem;
  margin-bottom: 10px;
}

.page-subtitle {
  font-size: 1rem;
  opacity: 0.9;
  margin-bottom: 15px;
}

.breadcrumb {
  font-size: 0.9rem;
  opacity: 0.85;
}

.breadcrumb a {
  color: white;
  text-decoration: underline;
}

.list-content {
  padding: 50px 20px;
}

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

.list-intro p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #555;
}

.list-stats {
  margin-bottom: 30px;
  padding: 15px 25px;
  background: #f0f4ff;
  border-left: 4px solid #667eea;
  border-radius: 4px;
  color: #555;
}

.list-stats strong {
  color: #667eea;
  font-size: 1.2rem;
}

/* 详情页样式 */
.detail-page {
  padding: 30px 20px 50px;
}

.detail-page .breadcrumb {
  font-size: 0.9rem;
  color: #888;
  margin-bottom: 20px;
}

.detail-page .breadcrumb a {
  color: #667eea;
  transition: color 0.3s;
}

.detail-page .breadcrumb a:hover {
  color: #5568d3;
}

.detail-header {
  background: white;
  padding: 40px;
  border-radius: 8px;
  margin-bottom: 30px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.detail-header h1 {
  font-size: 2.5rem;
  color: #2c3e50;
  margin-bottom: 10px;
}

.detail-header .subtitle {
  font-size: 1.1rem;
  color: #888;
}

.detail-info, .detail-highlight, .detail-summary, .detail-review, .detail-related {
  background: white;
  padding: 35px;
  border-radius: 8px;
  margin-bottom: 25px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.detail-info h2, .detail-highlight h2, .detail-summary h2, .detail-review h2, .detail-related h2 {
  font-size: 1.6rem;
  margin-bottom: 20px;
  color: #2c3e50;
  border-left: 4px solid #667eea;
  padding-left: 15px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 15px;
}

.info-item {
  display: flex;
  padding: 10px 0;
  border-bottom: 1px solid #f0f0f0;
}

.info-item.full-width {
  grid-column: 1 / -1;
}

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

.info-item .value {
  color: #333;
  flex: 1;
}

.info-item .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  background: #e8eaf6;
  color: #5568d3;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 0.85rem;
}

.tag-style {
  background: #fff3e0;
  color: #f57c00;
}

.highlight-text {
  font-size: 1.2rem;
  line-height: 1.8;
  color: #333;
  font-weight: 500;
  padding: 20px;
  background: #f8f9ff;
  border-left: 4px solid #667eea;
  border-radius: 4px;
}

.summary-text p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #444;
  margin-bottom: 15px;
  text-indent: 2em;
}

.review-text {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #555;
  padding: 20px;
  background: #fffbf0;
  border-left: 4px solid #ffa726;
  border-radius: 4px;
  font-style: italic;
}

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

.related-card {
  padding: 20px;
  background: #f9f9f9;
  border-radius: 8px;
  transition: background 0.3s, transform 0.3s;
}

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

.related-card h3 {
  font-size: 1.1rem;
  margin-bottom: 10px;
  color: #2c3e50;
}

.related-card h3 a:hover {
  color: #667eea;
}

.related-card .related-desc {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 10px 0;
}

.related-card .related-link {
  display: inline-block;
  color: #667eea;
  font-size: 0.9rem;
  font-weight: 500;
  margin-top: 8px;
  transition: transform 0.3s;
}

.related-card .related-link:hover {
  transform: translateX(5px);
}

/* 页脚 */
footer {
  background: #2c3e50;
  color: white;
  padding: 40px 20px;
  text-align: center;
  margin-top: 50px;
}

footer p {
  margin-bottom: 10px;
  font-size: 0.95rem;
}

.footer-note {
  font-size: 0.85rem;
  opacity: 0.8;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .hero h1, .page-header h1, .detail-header h1 {
    font-size: 1.8rem;
  }

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

  section h2 {
    font-size: 1.5rem;
  }

  .detail-header, .detail-info, .detail-highlight, .detail-summary, .detail-review, .detail-related {
    padding: 20px;
  }

  .list-item {
    flex-direction: column;
  }

  .list-item .rank {
    font-size: 1.5rem;
  }

  .timeline-view {
    padding-left: 20px;
  }

  .timeline-item {
    padding-left: 20px;
  }
}

/* 返回顶部按钮 */
#backToTop {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: #667eea;
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 1.5rem;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  transition: background 0.3s, transform 0.3s;
  z-index: 999;
}

#backToTop:hover {
  background: #5568d3;
  transform: translateY(-3px);
}

#backToTop.show {
  display: flex;
}

@media (max-width: 768px) {
  #backToTop {
    width: 45px;
    height: 45px;
    bottom: 20px;
    right: 20px;
    font-size: 1.3rem;
  }
}