/* 蘑菇视频 - 主样式文件 */
:root {
  --primary: #ff6b35;
  --primary-dark: #e55a25;
  --secondary: #4caf50;
  --text-main: #222;
  --text-sub: #666;
  --text-light: #999;
  --bg-light: #f7f8fa;
  --bg-white: #fff;
  --border: #e8e8e8;
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --radius: 8px;
  --radius-lg: 12px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", sans-serif;
  font-size: 14px;
  color: var(--text-main);
  background: var(--bg-light);
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--primary); }
img { max-width: 100%; display: block; }
ul { list-style: none; }

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

/* ===== 顶部公告栏 ===== */
.top-bar {
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  text-align: center;
  padding: 6px 0;
}
.top-bar a { color: #fff; text-decoration: underline; }

/* ===== 头部导航 ===== */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.site-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
}
.site-logo img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}
.main-nav a {
  padding: 6px 14px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s, color 0.2s;
}
.main-nav a:hover,
.main-nav a.active {
  background: #fff3ee;
  color: var(--primary);
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.btn-primary {
  background: var(--primary);
  color: #fff !important;
  border: none;
  border-radius: 20px;
  padding: 8px 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  display: inline-block;
}
.btn-primary:hover { background: var(--primary-dark); color: #fff !important; }
.btn-outline {
  border: 1px solid var(--primary);
  color: var(--primary);
  border-radius: 20px;
  padding: 7px 18px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  background: transparent;
  transition: all 0.2s;
  display: inline-block;
}
.btn-outline:hover { background: var(--primary); color: #fff; }

/* ===== 搜索栏 ===== */
.search-bar-wrap {
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
}
.search-bar {
  display: flex;
  align-items: center;
  max-width: 680px;
  margin: 0 auto;
  background: var(--bg-light);
  border: 2px solid var(--border);
  border-radius: 30px;
  overflow: hidden;
  transition: border-color 0.2s;
}
.search-bar:focus-within { border-color: var(--primary); }
.search-bar input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px 20px;
  font-size: 15px;
  outline: none;
  color: var(--text-main);
}
.search-bar button {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 10px 24px;
  font-size: 15px;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s;
}
.search-bar button:hover { background: var(--primary-dark); }
.search-hot-tags {
  text-align: center;
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-light);
}
.search-hot-tags span { margin-right: 4px; }
.search-hot-tags a {
  display: inline-block;
  background: #fff3ee;
  color: var(--primary);
  border-radius: 12px;
  padding: 2px 10px;
  margin: 2px 3px;
  font-size: 12px;
  transition: background 0.2s;
}
.search-hot-tags a:hover { background: var(--primary); color: #fff; }

/* ===== 面包屑 ===== */
.breadcrumb {
  padding: 10px 0;
  font-size: 12px;
  color: var(--text-light);
}
.breadcrumb a { color: var(--text-light); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb span { margin: 0 6px; }

/* ===== 首屏Banner ===== */
.hero-section {
  background: linear-gradient(135deg, #fff8f5 0%, #fff3ee 100%);
  padding: 0;
  overflow: hidden;
}
.hero-inner {
  display: flex;
  align-items: center;
  min-height: 380px;
  gap: 40px;
}
.hero-content {
  flex: 1;
  padding: 40px 0;
}
.hero-badge {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  border-radius: 20px;
  padding: 4px 14px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 16px;
}
.hero-title {
  font-size: 36px;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.3;
  margin-bottom: 12px;
}
.hero-title em {
  color: var(--primary);
  font-style: normal;
}
.hero-desc {
  font-size: 16px;
  color: var(--text-sub);
  margin-bottom: 24px;
  line-height: 1.8;
}
.hero-stats {
  display: flex;
  gap: 32px;
  margin-bottom: 28px;
}
.hero-stat-item strong {
  display: block;
  font-size: 24px;
  font-weight: 800;
  color: var(--primary);
}
.hero-stat-item span {
  font-size: 12px;
  color: var(--text-light);
}
.hero-actions { display: flex; gap: 12px; }
.hero-image {
  flex: 0 0 480px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.hero-image img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}

/* ===== 通用模块 ===== */
.section {
  padding: 40px 0;
}
.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 24px;
}
.section-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-main);
  position: relative;
  padding-left: 14px;
}
.section-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 4px;
  background: var(--primary);
  border-radius: 2px;
}
.section-subtitle {
  font-size: 13px;
  color: var(--text-light);
  margin-top: 4px;
  padding-left: 14px;
}
.more-link {
  font-size: 13px;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 4px;
}
.more-link:hover { color: var(--primary-dark); }

/* ===== 视频卡片 ===== */
.video-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.video-card {
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
}
.video-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}
.video-thumb {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
  background: #000;
}
.video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.video-card:hover .video-thumb img { transform: scale(1.05); }
.play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  width: 52px;
  height: 52px;
  background: rgba(255,107,53,0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
}
.video-card:hover .play-btn { transform: translate(-50%, -50%) scale(1); }
.play-btn svg { width: 22px; height: 22px; fill: #fff; margin-left: 4px; }
.video-duration {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0,0,0,0.7);
  color: #fff;
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 4px;
}
.video-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--primary);
  color: #fff;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 4px;
}
.video-info {
  padding: 12px;
}
.video-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.5;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.video-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-light);
}
.video-author {
  display: flex;
  align-items: center;
  gap: 6px;
}
.video-author img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
}
.video-stats {
  display: flex;
  gap: 10px;
  font-size: 12px;
  color: var(--text-light);
  margin-top: 6px;
}
.video-stats span { display: flex; align-items: center; gap: 3px; }

/* ===== 热门资讯列表 ===== */
.news-list { display: flex; flex-direction: column; gap: 12px; }
.news-item {
  display: flex;
  gap: 14px;
  background: #fff;
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: var(--shadow);
  transition: transform 0.2s;
}
.news-item:hover { transform: translateX(4px); }
.news-thumb {
  flex: 0 0 120px;
  height: 80px;
  border-radius: 6px;
  overflow: hidden;
}
.news-thumb img { width: 100%; height: 100%; object-fit: cover; }
.news-content { flex: 1; }
.news-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 6px;
  line-height: 1.5;
}
.news-title:hover { color: var(--primary); }
.news-desc {
  font-size: 13px;
  color: var(--text-sub);
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.news-footer {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--text-light);
}
.news-rank {
  flex: 0 0 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  color: var(--text-light);
}
.news-rank.top1 { background: #ff4d4f; color: #fff; }
.news-rank.top2 { background: #ff7a45; color: #fff; }
.news-rank.top3 { background: #ffa940; color: #fff; }

/* ===== 专题聚合 ===== */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.topic-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.2s;
}
.topic-card:hover { transform: translateY(-4px); }
.topic-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
}
.topic-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  padding: 20px 14px 14px;
  color: #fff;
}
.topic-overlay h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.topic-overlay p { font-size: 12px; opacity: 0.85; }

/* ===== 创作者中心 ===== */
.creator-section {
  background: linear-gradient(135deg, #ff6b35 0%, #ff8c5a 100%);
  border-radius: var(--radius-lg);
  padding: 40px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.creator-content h2 { font-size: 28px; font-weight: 800; margin-bottom: 10px; }
.creator-content p { font-size: 15px; opacity: 0.9; margin-bottom: 20px; }
.creator-benefits {
  display: flex;
  gap: 24px;
  margin-bottom: 24px;
}
.creator-benefit {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}
.creator-benefit .icon {
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}
.btn-white {
  background: #fff;
  color: var(--primary);
  border: none;
  border-radius: 24px;
  padding: 12px 32px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-block;
}
.btn-white:hover { background: #fff3ee; color: var(--primary-dark); }
.creator-image {
  flex: 0 0 280px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  opacity: 0.95;
}
.creator-image img { width: 100%; height: 200px; object-fit: cover; }

/* ===== 人气作者 ===== */
.author-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.author-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 20px;
  text-align: center;
  box-shadow: var(--shadow);
  transition: transform 0.2s;
}
.author-card:hover { transform: translateY(-4px); }
.author-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 12px;
  border: 3px solid #fff3ee;
}
.author-name {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 4px;
}
.author-fans {
  font-size: 12px;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 6px;
}
.author-desc {
  font-size: 12px;
  color: var(--text-sub);
  margin-bottom: 12px;
  line-height: 1.5;
}
.btn-follow {
  background: #fff3ee;
  color: var(--primary);
  border: 1px solid #ffd5c0;
  border-radius: 16px;
  padding: 5px 18px;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-follow:hover { background: var(--primary); color: #fff; }

/* ===== 互动专区 ===== */
.interaction-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.comment-list { display: flex; flex-direction: column; gap: 12px; }
.comment-item {
  background: #fff;
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: var(--shadow);
}
.comment-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.comment-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
}
.comment-user { font-size: 14px; font-weight: 600; }
.comment-time { font-size: 12px; color: var(--text-light); margin-left: auto; }
.comment-text { font-size: 14px; color: var(--text-sub); line-height: 1.6; }
.comment-actions {
  display: flex;
  gap: 16px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-light);
}
.comment-actions span { cursor: pointer; display: flex; align-items: center; gap: 4px; }
.comment-actions span:hover { color: var(--primary); }

/* ===== FAQ ===== */
.faq-list { display: flex; flex-direction: column; gap: 10px; }
.faq-item {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.faq-question {
  padding: 16px 20px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background 0.2s;
}
.faq-question:hover { background: #fff8f5; }
.faq-question::after {
  content: '+';
  font-size: 20px;
  color: var(--primary);
  transition: transform 0.2s;
}
.faq-item.open .faq-question::after { transform: rotate(45deg); }
.faq-answer {
  padding: 0 20px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s, padding 0.3s;
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.7;
}
.faq-item.open .faq-answer {
  max-height: 200px;
  padding: 0 20px 16px;
}

/* ===== 帮助中心 ===== */
.help-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.help-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 24px 16px;
  text-align: center;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
}
.help-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}
.help-icon {
  font-size: 32px;
  margin-bottom: 12px;
}
.help-card h3 { font-size: 15px; font-weight: 700; margin-bottom: 6px; }
.help-card p { font-size: 13px; color: var(--text-sub); }

/* ===== 联系我们 ===== */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.contact-card {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 24px 16px;
  text-align: center;
  box-shadow: var(--shadow);
}
.contact-icon { font-size: 32px; margin-bottom: 10px; }
.contact-card h3 { font-size: 14px; font-weight: 700; margin-bottom: 6px; }
.contact-card p { font-size: 13px; color: var(--text-sub); }

/* ===== 页脚 ===== */
.site-footer {
  background: #1a1a2e;
  color: #aaa;
  padding: 48px 0 24px;
  margin-top: 40px;
}
.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}
.footer-brand .site-logo {
  color: #fff;
  margin-bottom: 12px;
}
.footer-brand p {
  font-size: 13px;
  line-height: 1.8;
  color: #888;
  margin-bottom: 16px;
}
.footer-col h4 {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 14px;
}
.footer-col ul li {
  margin-bottom: 8px;
}
.footer-col ul li a {
  font-size: 13px;
  color: #888;
  transition: color 0.2s;
}
.footer-col ul li a:hover { color: var(--primary); }
.footer-divider {
  border: none;
  border-top: 1px solid #2a2a3e;
  margin: 0 0 20px;
}
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: #666;
}
.footer-links { display: flex; gap: 16px; }
.footer-links a { color: #666; }
.footer-links a:hover { color: var(--primary); }
.update-time { font-size: 12px; color: #555; margin-top: 6px; }

/* ===== 侧边栏 ===== */
.main-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 24px;
  padding: 24px 0;
}
.sidebar-widget {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow);
  margin-bottom: 20px;
}
.widget-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--primary);
  color: var(--text-main);
}
.hot-rank-list { display: flex; flex-direction: column; gap: 10px; }
.hot-rank-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  cursor: pointer;
  transition: color 0.2s;
}
.hot-rank-item:hover { color: var(--primary); }
.rank-num {
  flex: 0 0 22px;
  height: 22px;
  border-radius: 4px;
  background: var(--bg-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-light);
}
.rank-num.r1 { background: #ff4d4f; color: #fff; }
.rank-num.r2 { background: #ff7a45; color: #fff; }
.rank-num.r3 { background: #ffa940; color: #fff; }

/* ===== 标签 ===== */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
  background: var(--bg-light);
  color: var(--text-sub);
  border-radius: 16px;
  padding: 4px 12px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}
.tag:hover { background: var(--primary); color: #fff; }

/* ===== 互动按钮 ===== */
.action-bar {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin: 16px 0;
}
.action-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: #fff;
  font-size: 13px;
  color: var(--text-sub);
  cursor: pointer;
  transition: all 0.2s;
}
.action-btn:hover { border-color: var(--primary); color: var(--primary); }
.action-btn.liked { background: #fff3ee; border-color: var(--primary); color: var(--primary); }

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
  .video-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .main-layout { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .hero-inner { flex-direction: column; }
  .hero-image { flex: none; width: 100%; }
  .video-grid { grid-template-columns: repeat(2, 1fr); }
  .author-grid { grid-template-columns: repeat(2, 1fr); }
  .help-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: repeat(2, 1fr); }
  .topic-grid { grid-template-columns: 1fr 1fr; }
  .creator-section { flex-direction: column; }
  .creator-image { flex: none; width: 100%; }
  .main-nav { display: none; }
  .footer-top { grid-template-columns: 1fr; }
  .interaction-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .video-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 26px; }
  .hero-stats { gap: 16px; }
}

/* ===== 懒加载占位 ===== */
img[data-src] { background: #f0f0f0; }

/* ===== 通知条 ===== */
.notice-bar {
  background: #fff8f5;
  border: 1px solid #ffd5c0;
  border-radius: var(--radius);
  padding: 10px 16px;
  font-size: 13px;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

/* ===== 分页 ===== */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 24px 0;
}
.page-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}
.page-btn:hover, .page-btn.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* ===== 加载动画 ===== */
.loading {
  display: flex;
  justify-content: center;
  padding: 40px;
}
.loading-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--primary);
  margin: 0 4px;
  animation: bounce 1.2s infinite ease-in-out;
}
.loading-dot:nth-child(2) { animation-delay: 0.2s; }
.loading-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}
