/* 每日大赛 - 主题大赛 · 勇于挑战 */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", sans-serif;
  color: #1f2937;
  background: #f8fafc;
  line-height: 1.65;
}

a {
  color: #dc2626;
  text-decoration: none;
}

a:hover {
  color: #b91c1c;
  text-decoration: underline;
}

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

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.wrapper {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ========== 顶栏 ========== */
.topbar {
  background: #1e293b;
  color: #e2e8f0;
  padding: 10px 0;
  font-size: 0.8125rem;
}

.topbar .wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.topbar a {
  color: #94a3b8;
}

.topbar a:hover {
  color: #f59e0b;
}

/* ========== 主导航 ========== */
.main-header {
  background: #fff;
  border-bottom: 3px solid #dc2626;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.main-header .wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.site-logo {
  font-size: 1.375rem;
  font-weight: 800;
  color: #dc2626;
  letter-spacing: 0.02em;
}

.site-logo:hover {
  color: #b91c1c;
  text-decoration: none;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.main-nav a {
  padding: 8px 14px;
  color: #475569;
  font-weight: 500;
  font-size: 0.9375rem;
  border-radius: 6px;
}

.main-nav a:hover,
.main-nav a.active {
  background: #fef2f2;
  color: #dc2626;
  text-decoration: none;
}

.menu-btn {
  display: none;
  padding: 8px 12px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.875rem;
  color: #475569;
}

/* ========== Hero 主视觉 ========== */
.hero-banner {
  background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
  color: #fff;
  padding: 48px 20px 56px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero-banner::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(to top, #f8fafc, transparent);
  pointer-events: none;
}

.hero-banner .wrapper {
  position: relative;
  z-index: 1;
}

.hero-banner .tag {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(245, 158, 11, 0.9);
  color: #1e293b;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 4px;
  margin-bottom: 16px;
}

.hero-banner h1 {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 800;
  margin-bottom: 12px;
  line-height: 1.25;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.hero-banner h1 .highlight {
  color: #f59e0b;
}

.hero-banner .hero-lead {
  font-size: 1rem;
  color: #cbd5e1;
  max-width: 560px;
  margin: 0 auto 24px;
  line-height: 1.7;
}

.hero-banner .hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.hero-banner .btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.9375rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.hero-banner .btn-primary {
  background: #dc2626;
  color: #fff;
  border: none;
}

.hero-banner .btn-primary:hover {
  background: #b91c1c;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(220, 38, 38, 0.35);
  text-decoration: none;
}

.hero-banner .btn-outline {
  background: transparent;
  color: #fff;
  border: 2px solid #f59e0b;
}

.hero-banner .btn-outline:hover {
  background: rgba(245, 158, 11, 0.2);
  text-decoration: none;
}

/* ========== 区块通用 ========== */
.section {
  padding: 48px 0;
}

.section:nth-child(even) {
  background: #fff;
}

.section-head {
  margin-bottom: 28px;
}

.section-head h2 {
  font-size: 1.5rem;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 8px;
}

.section-head p {
  font-size: 0.9375rem;
  color: #64748b;
}

.section-head .more {
  font-size: 0.875rem;
  font-weight: 600;
  margin-top: 8px;
  display: inline-block;
}

/* ========== 期数卡片（主题大赛） ========== */
.phase-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.phase-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.phase-card:hover {
  border-color: #fecaca;
  box-shadow: 0 8px 24px rgba(220, 38, 38, 0.08);
}

.phase-card a {
  display: block;
  color: inherit;
}

.phase-card a:hover {
  text-decoration: none;
}

.phase-card .thumb {
  position: relative;
  aspect-ratio: 16/10;
  background: #e2e8f0;
}

.phase-card .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.phase-card .phase-num {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  background: #dc2626;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 4px;
}

.phase-card .body {
  padding: 16px;
}

.phase-card .body h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 6px;
  line-height: 1.35;
}

.phase-card .body .meta {
  font-size: 0.8125rem;
  color: #64748b;
}

/* ========== 交错图文 ========== */
.alt-blocks {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.alt-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: center;
  padding: 32px 0;
  border-bottom: 1px solid #e2e8f0;
}

.alt-block:last-child {
  border-bottom: none;
}

.alt-block.reverse {
  direction: rtl;
}

.alt-block.reverse > * {
  direction: ltr;
}

.alt-block .block-img {
  border-radius: 8px;
  overflow: hidden;
  background: #e2e8f0;
}

.alt-block .block-img img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}

.alt-block .block-text h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 10px;
}

.alt-block .block-text p {
  font-size: 0.9375rem;
  color: #475569;
  line-height: 1.7;
}

/* ========== 数字亮点 ========== */
.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.stat-box {
  text-align: center;
  padding: 24px 16px;
  background: #fff;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
}

.stat-box .num {
  font-size: 2rem;
  font-weight: 800;
  color: #dc2626;
  line-height: 1.2;
  margin-bottom: 6px;
}

.stat-box .label {
  font-size: 0.8125rem;
  color: #64748b;
}

/* ========== 列表（链接列表） ========== */
.link-list {
  list-style: none;
}

.link-list li {
  border-bottom: 1px solid #e2e8f0;
}

.link-list a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
  color: #1e293b;
  font-weight: 500;
}

.link-list a:hover {
  color: #dc2626;
  text-decoration: none;
}

.link-list .thumb-sm {
  width: 80px;
  height: 50px;
  flex-shrink: 0;
  border-radius: 6px;
  overflow: hidden;
  background: #e2e8f0;
}

.link-list .thumb-sm img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ========== 内容页 ========== */
.content-area {
  padding: 32px 0 48px;
}

.breadcrumb {
  font-size: 0.8125rem;
  color: #64748b;
  margin-bottom: 20px;
}

.breadcrumb a {
  color: #64748b;
}

.breadcrumb a:hover {
  color: #dc2626;
}

.content-head {
  margin-bottom: 24px;
}

.content-head h1 {
  font-size: 1.75rem;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 10px;
  line-height: 1.35;
}

.content-head .meta {
  font-size: 0.875rem;
  color: #64748b;
}

.content-cover {
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 28px;
  border: 1px solid #e2e8f0;
}

.content-cover img {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
}

.prose {
  max-width: 720px;
}

.prose p {
  font-size: 1rem;
  color: #334155;
  line-height: 1.8;
  margin-bottom: 16px;
}

.prose h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1e293b;
  margin: 28px 0 12px;
}

.prose h2:first-of-type {
  margin-top: 0;
}

.prose h3 {
  font-size: 1.0625rem;
  font-weight: 600;
  color: #334155;
  margin: 20px 0 8px;
}

.prose .tags {
  margin-top: 24px;
}

.prose .tags span {
  display: inline-block;
  padding: 4px 12px;
  margin-right: 8px;
  margin-bottom: 8px;
  background: #fef2f2;
  color: #dc2626;
  font-size: 0.8125rem;
  border-radius: 6px;
}

.back-link {
  display: inline-block;
  margin-top: 28px;
  font-size: 0.9375rem;
  font-weight: 500;
}

/* ========== 页脚 ========== */
.footer {
  margin-top: auto;
  background: #1e293b;
  color: #94a3b8;
  padding: 36px 20px 24px;
  font-size: 0.875rem;
}

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

.footer h4 {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 12px;
}

.footer ul {
  list-style: none;
}

.footer li {
  margin-bottom: 8px;
}

.footer a {
  color: #94a3b8;
}

.footer a:hover {
  color: #f59e0b;
}

.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid #334155;
  text-align: center;
  color: #64748b;
  font-size: 0.8125rem;
}

.footer-bottom a {
  color: #94a3b8;
}

/* ========== 响应式 ========== */
@media (max-width: 900px) {
  .phase-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .alt-block,
  .alt-block.reverse {
    grid-template-columns: 1fr;
    direction: ltr;
  }

  .stats-row {
    grid-template-columns: repeat(2, 1fr);
  }

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

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

  .main-nav.open {
    display: flex;
    width: 100%;
    flex-direction: column;
  }

  .menu-btn {
    display: block;
  }

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

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

  .hero-banner {
    padding: 36px 16px 44px;
  }

  .section {
    padding: 36px 0;
  }

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