:root {
  --bg-main: #13091f;
  --bg-darker: #0d0615;
  --bg-surface: #1e1030;
  --bg-card: #25143a;
  --primary-purple: #6a1b9a;
  --accent-pink: #ff2a85;
  --accent-pink-hover: #ff529f;
  --text-white: #f5f2f9;
  --text-muted: #a69bb5;
  --border-color: #3b2257;
  --badge-bg: rgba(13, 6, 21, 0.85);
  --font-serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

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

html {
  overflow-x: hidden;
}

body {
  background-color: var(--bg-main);
  color: var(--text-white);
  font-family: var(--font-sans);
  letter-spacing: 0.01em;
  line-height: 1.57;
  overflow-x: hidden;
  background-image:
    linear-gradient(135deg, rgba(255, 42, 133, 0.05) 0%, transparent 40%),
    linear-gradient(225deg, rgba(106, 27, 154, 0.15) 0%, transparent 60%);
  background-attachment: fixed;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.icon {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  vertical-align: middle;
  display: inline-block;
}

/* 顶部双层导航 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-darker);
  border-bottom: 1px solid var(--border-color);
}

.main-nav-bar {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 20px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand-logo {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 900;
  color: var(--accent-pink);
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 24px;
  font-size: 15px;
}

.nav-links a {
  transition: color 0.2s;
}

.nav-links a:hover, .nav-links a.active {
  color: var(--accent-pink);
}

.search-box {
  flex: 0 1 360px;
  position: relative;
}

.search-box input {
  width: 100%;
  height: 38px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-white);
  padding: 0 40px 0 14px;
  font-size: 13px;
}

.search-box input:focus {
  outline: none;
  border-color: var(--accent-pink);
}

.search-box button {
  position: absolute;
  right: 0;
  top: 0;
  height: 38px;
  width: 38px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.upload-btn {
  background: var(--accent-pink);
  color: #fff;
  padding: 8px 18px;
  min-height: 40px;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.2s;
}

.upload-btn:hover {
  background: var(--accent-pink-hover);
}

/* 副导航分类条 */
.sub-nav-bar {
  background: var(--bg-surface);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  border-bottom: 2px solid var(--accent-pink);
}

.sub-nav-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  gap: 28px;
  overflow-x: auto;
  scrollbar-width: none;
}
.sub-nav-inner::-webkit-scrollbar { display: none; }

.sub-nav-inner a {
  padding: 12px 0;
  font-size: 14px;
  color: var(--text-muted);
  white-space: nowrap;
  position: relative;
}

.sub-nav-inner a:hover, .sub-nav-inner a.current {
  color: var(--text-white);
  font-weight: 600;
}

.sub-nav-inner a.current::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent-pink);
}

/* 页面斜切色块背景分区 */
.diagonal-layer {
  position: relative;
  max-width: 1440px;
  margin: 0 auto;
  padding: 30px 20px;
}

.diagonal-layer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 380px;
  background: linear-gradient(170deg, rgba(106, 27, 154, 0.25) 0%, rgba(19, 9, 31, 0) 70%);
  pointer-events: none;
  z-index: -1;
}

/* 焦点横幅大卡 */
.hero-banner {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 20px;
  margin-bottom: 36px;
  background: var(--bg-darker);
  border: 1px solid var(--border-color);
}

.hero-display {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #000;
}

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

.hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 30px;
  background: linear-gradient(0deg, rgba(13, 6, 21, 0.95) 0%, rgba(13, 6, 21, 0.5) 60%, transparent 100%);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hero-badge {
  display: inline-block;
  align-self: flex-start;
  background: var(--accent-pink);
  color: #fff;
  font-size: 11px;
  padding: 3px 8px;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.hero-overlay h1 {
  font-family: var(--font-serif);
  font-size: clamp(19px, 3vw, 26px);
  font-weight: 700;
  line-height: 1.3;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  color: var(--text-muted);
  font-size: 13px;
}

.play-action {
  align-self: flex-start;
  background: var(--accent-pink);
  color: #fff;
  padding: 10px 24px;
  min-height: 44px;
  font-weight: 600;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  transition: background 0.2s;
}

.play-action:hover {
  background: var(--accent-pink-hover);
}

.hero-side-picks {
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  background: var(--bg-surface);
}

.hero-side-picks h2.side-heading {
  font-family: var(--font-serif);
  font-size: 16px;
  color: var(--accent-pink);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 8px;
}

.side-pick-item {
  display: flex;
  gap: 12px;
  align-items: center;
}

.side-pick-thumb {
  flex: 0 0 110px;
  aspect-ratio: 16 / 9;
  position: relative;
  background: #000;
}

.side-pick-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.side-pick-info h3 {
  font-size: 13px;
  line-height: 1.4;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.side-pick-info span {
  font-size: 11px;
  color: var(--text-muted);
}

/* 整体瀑布流主体 + 右侧Sticky布局 */
.stream-container {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 30px;
  align-items: start;
}

.section-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 10px;
}

.section-title {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 18px;
  background: var(--accent-pink);
}

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

.filter-tag {
  font-size: 12px;
  padding: 4px 10px;
  background: var(--bg-surface);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
  cursor: pointer;
}

.filter-tag.active {
  background: var(--accent-pink);
  color: #fff;
  border-color: var(--accent-pink);
}

/* 视频卡列表网格 */
.video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 40px;
}

.video-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
}

.video-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px rgba(255, 42, 133, 0.15);
  border-color: var(--accent-pink);
}

.thumb-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}

.thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.video-card:hover .thumb-wrap img {
  transform: scale(1.05);
}

.time-badge {
  position: absolute;
  bottom: 6px;
  right: 6px;
  background: var(--badge-bg);
  font-size: 11px;
  padding: 2px 6px;
  color: #fff;
  font-weight: 500;
}

.danmaku-badge {
  position: absolute;
  bottom: 6px;
  left: 6px;
  background: var(--badge-bg);
  font-size: 11px;
  padding: 2px 6px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}

.card-body {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  justify-content: space-between;
}

.video-title {
  font-size: 14px;
  line-height: 1.45;
  font-weight: 600;
  margin-bottom: 12px;
  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-muted);
}

.author-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.author-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.author-name {
  max-width: 100px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.play-stat {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* 右侧 Sticky 播放榜 */
.sticky-rank-aside {
  position: sticky;
  top: 130px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  padding: 20px;
}

.rank-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 12px;
}

.rank-num {
  flex: 0 0 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  background: var(--bg-card);
  color: var(--text-muted);
}

.rank-item:nth-child(1) .rank-num { background: var(--accent-pink); color: #fff; }
.rank-item:nth-child(2) .rank-num { background: #ab47bc; color: #fff; }
.rank-item:nth-child(3) .rank-num { background: #7e57c2; color: #fff; }

.rank-content {
  flex-grow: 1;
  min-width: 0;
}

.rank-video-title {
  display: block;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.rank-video-title:hover {
  color: var(--accent-pink);
}

.rank-sub {
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
}

/* 正在直播模块 */
.live-stream-row {
  margin-bottom: 40px;
}

.live-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.live-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  position: relative;
}

.live-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: #e50914;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  display: flex;
  align-items: center;
  gap: 4px;
  z-index: 2;
}

.live-dot {
  width: 6px;
  height: 6px;
  background: #fff;
  border-radius: 50%;
  animation: pulse 1.2s infinite;
}

@keyframes pulse {
  0% { opacity: 0.3; }
  50% { opacity: 1; }
  100% { opacity: 0.3; }
}

.live-info {
  padding: 12px;
}

.live-room-title {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 6px;
}

.live-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: var(--text-muted);
}

/* 创作者动态资讯 + 常见问答 */
.lower-content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  margin-bottom: 40px;
}

.info-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.info-item {
  background: var(--bg-surface);
  border-left: 3px solid var(--accent-pink);
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
}

.info-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text-white);
}

.info-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: var(--bg-surface);
  padding: 14px;
  border: 1px solid var(--border-color);
}

.faq-q {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-pink);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.faq-a {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* 底部页脚 */
.site-footer {
  background: var(--bg-darker);
  border-top: 1px solid var(--border-color);
  padding: 40px 20px 24px;
  font-size: 13px;
  color: var(--text-muted);
}

.footer-inner {
  max-width: 1440px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 30px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--border-color);
}

.footer-col h3 {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--text-white);
  margin-bottom: 14px;
}

.footer-col p {
  line-height: 1.6;
  margin-bottom: 10px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links a:hover {
  color: var(--accent-pink);
}

.footer-bottom {
  max-width: 1440px;
  margin: 20px auto 0;
  text-align: center;
  font-size: 12px;
  color: #8a7d9b;
}

/* 响应式断点（已修复原模板 @interface 拼写错误） */
@media screen and (max-width: 1100px) {
  .stream-container {
    grid-template-columns: 1fr;
  }
  .sticky-rank-aside {
    position: static;
    margin-top: 20px;
  }
  .video-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .live-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media screen and (max-width: 820px) {
  .hero-banner {
    grid-template-columns: 1fr;
  }
  .hero-side-picks {
    display: none;
  }
  .lower-content-grid {
    grid-template-columns: 1fr;
  }
  .footer-inner {
    grid-template-columns: 1fr 1fr;
  }
  .search-box {
    display: none;
  }
  .nav-links {
    display: none;
  }
}

@media screen and (max-width: 560px) {
  .hero-overlay {
    padding: 16px;
    gap: 6px;
  }
  .hero-meta {
    font-size: 11px;
    gap: 8px;
  }
  .video-grid {
    grid-template-columns: 1fr;
  }
  .live-grid {
    grid-template-columns: 1fr;
  }
  .footer-inner {
    grid-template-columns: 1fr;
  }
}
