/* 每日大赛 · 吃瓜爆料 · 吃瓜网 - 资讯流风格 */
*,
*::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: #334155;
  background: #f5f3ff;
  line-height: 1.6;
}

a {
  color: #6d28d9;
  text-decoration: none;
}

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

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

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

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

/* ========== 顶导航 ========== */
.top-nav {
  background: linear-gradient(90deg, #5b21b6 0%, #7c3aed 100%);
  color: #fff;
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 12px rgba(91, 33, 182, 0.25);
}

.top-nav .contain {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.brand {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.02em;
}

.brand:hover {
  color: #e9d5ff;
  text-decoration: none;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: wrap;
}

.nav-menu a {
  padding: 8px 16px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.9375rem;
  font-weight: 500;
  border-radius: 8px;
}

.nav-menu a:hover,
.nav-menu a.active {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  text-decoration: none;
}

.menu-btn {
  display: none;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  border-radius: 8px;
  color: #fff;
  font-size: 0.875rem;
  cursor: pointer;
}

/* ========== 主区：左主栏 + 右侧栏 ========== */
.main-wrap {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 28px;
  padding: 28px 0 40px;
  align-items: start;
}

@media (max-width: 900px) {
  .main-wrap {
    grid-template-columns: 1fr;
  }
}

/* ========== 首屏头条 ========== */
.hero-block {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 24px;
  box-shadow: 0 4px 16px rgba(91, 33, 182, 0.08);
  border: 1px solid rgba(139, 92, 246, 0.12);
}

.hero-block a {
  display: block;
  color: inherit;
}

.hero-block a:hover {
  text-decoration: none;
}

.hero-block .hero-img {
  aspect-ratio: 21/9;
  background: #ede9fe;
}

.hero-block .hero-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-block .hero-cap {
  padding: 20px 24px;
}

.hero-block .hero-cap .k {
  display: inline-block;
  padding: 3px 10px;
  background: #ede9fe;
  color: #6d28d9;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 6px;
  margin-bottom: 10px;
}

.hero-block .hero-cap h1 {
  font-size: 1.375rem;
  font-weight: 800;
  color: #1e1b4b;
  margin-bottom: 8px;
  line-height: 1.35;
}

.hero-block .hero-cap p {
  font-size: 0.9375rem;
  color: #64748b;
  line-height: 1.55;
}

/* ========== 信息流卡片（图左文右） ========== */
.feed {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.feed-item {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 20px;
  align-items: center;
  padding: 20px 0;
  border-bottom: 1px solid #e9d5ff;
  text-decoration: none;
  color: inherit;
  transition: background 0.2s;
}

.feed-item:hover {
  background: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  color: inherit;
}

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

.feed-item .thumb {
  aspect-ratio: 16/10;
  border-radius: 8px;
  overflow: hidden;
  background: #ede9fe;
}

.feed-item .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.feed-item .txt h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #1e1b4b;
  margin-bottom: 6px;
  line-height: 1.4;
}

.feed-item .txt .tag {
  display: inline-block;
  padding: 2px 8px;
  margin-right: 6px;
  background: #f5f3ff;
  color: #6d28d9;
  font-size: 0.75rem;
  border-radius: 4px;
  margin-bottom: 6px;
}

.feed-item .txt .sum {
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.5;
}

/* ========== 区块标题 ========== */
.block-head {
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.block-head h2 {
  font-size: 1.25rem;
  font-weight: 800;
  color: #1e1b4b;
}

.block-head .more {
  font-size: 0.875rem;
  font-weight: 600;
  color: #6d28d9;
}

/* ========== 侧栏 ========== */
.sidebar {
  position: sticky;
  top: 80px;
}

.side-card {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 4px 16px rgba(91, 33, 182, 0.06);
  border: 1px solid rgba(139, 92, 246, 0.1);
}

.side-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #1e1b4b;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid #ede9fe;
}

.side-list {
  list-style: none;
}

.side-list li {
  margin-bottom: 12px;
}

.side-list li:last-child {
  margin-bottom: 0;
}

.side-list a {
  font-size: 0.9375rem;
  color: #475569;
  font-weight: 500;
}

.side-list a:hover {
  color: #6d28d9;
  text-decoration: none;
}

/* ========== 小卡片网格（侧栏或区块内） ========== */
.mini-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.mini-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(139, 92, 246, 0.1);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.mini-card:hover {
  border-color: rgba(109, 40, 217, 0.3);
  box-shadow: 0 4px 12px rgba(91, 33, 182, 0.1);
}

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

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

.mini-card .m-img {
  aspect-ratio: 16/10;
  background: #ede9fe;
}

.mini-card .m-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mini-card .m-txt {
  padding: 12px;
}

.mini-card .m-txt h4 {
  font-size: 0.875rem;
  font-weight: 700;
  color: #1e1b4b;
  line-height: 1.4;
}

.mini-card .m-txt .m-tag {
  font-size: 0.6875rem;
  color: #6d28d9;
  margin-top: 6px;
}

/* ========== 内容页 ========== */
.content-wrap {
  padding: 24px 0 40px;
}

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

.bread a {
  color: #64748b;
}

.bread a:hover {
  color: #6d28d9;
}

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

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

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

.content-cover {
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 28px;
  border: 1px solid rgba(139, 92, 246, 0.12);
}

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

.prose {
  max-width: 700px;
}

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

.prose h2 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #1e1b4b;
  margin: 26px 0 12px;
}

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

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

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

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

/* ========== 列表页：仅流式 ========== */
.list-feed {
  margin-bottom: 24px;
}

/* ========== 页脚 ========== */
.foot {
  margin-top: auto;
  background: #1e1b4b;
  color: #a5b4fc;
  padding: 32px 20px 24px;
  font-size: 0.875rem;
}

.foot .contain {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 28px;
  margin-bottom: 24px;
}

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

.foot ul {
  list-style: none;
}

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

.foot a {
  color: #a5b4fc;
}

.foot a:hover {
  color: #e9d5ff;
}

.foot-bottom {
  padding-top: 16px;
  border-top: 1px solid #3730a3;
  text-align: center;
  color: #818cf8;
  font-size: 0.8125rem;
}

/* ========== 响应式 ========== */
@media (max-width: 640px) {
  .nav-menu {
    display: none;
  }

  .nav-menu.open {
    display: flex;
    width: 100%;
    flex-direction: column;
    margin-top: 8px;
  }

  .menu-btn {
    display: block;
  }

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

  .feed-item .thumb {
    max-height: 180px;
    aspect-ratio: 16/9;
  }

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

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

  .hero-block .hero-img {
    aspect-ratio: 16/9;
  }
}
