/* ===== 全局重置 ===== */
*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, h3, h4, h5, h6, p, ul, ol, li, dl, dt, dd, form, input, textarea, select, button, img, table, thead, tbody, tr, th, td { margin: 0; padding: 0; border: 0; }
ol, ul { list-style: none; }
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
table { border-collapse: collapse; }

/* ===== 全局变量 & 基础 ===== */
:root {
  --bg:        #0f111a;
  --bg2:       #161b2e;
  --bg3:       #1e2540;
  --card:      #1a2035;
  --border:    #252d47;
  --accent:    #e63462;
  --accent2:   #ff6b35;
  --gold:      #f5c518;
  --text:      #e0e4f0;
  --text2:     #8b93b0;
  --radius:    8px;
  --shadow:    0 4px 24px rgba(0,0,0,.5);
  --trans:     .2s ease;
}
body {
  font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
}
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* ===== 滚动条 ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

/* ===== HEADER ===== */
#header {
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 20px rgba(0,0,0,.6);
}
.header-inner {
  display: flex; align-items: center;
  height: 64px; gap: 24px;
}
.logo { flex-shrink: 0; }
.logo img { height: 40px; width: auto; }
.logo-text {
  font-size: 22px; font-weight: 700;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  letter-spacing: 1px;
}

/* 搜索框 */
.search-box {
  flex: 1; max-width: 460px;
  display: flex; align-items: center;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 24px;
  overflow: hidden;
  transition: border-color var(--trans), box-shadow var(--trans);
}
.search-box:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(230,52,98,.15);
}
.search-box input {
  flex: 1; background: none; border: none; outline: none;
  padding: 10px 16px; color: var(--text); font-size: 14px;
}
.search-box input::placeholder { color: var(--text2); }
.search-box button {
  background: var(--accent); border: none; cursor: pointer;
  padding: 0 20px; height: 40px; color: #fff;
  font-size: 14px; white-space: nowrap;
  transition: background var(--trans);
}
.search-box button:hover { background: #c2284f; }

/* 统计 */
.header-stats {
  display: flex; gap: 16px; flex-shrink: 0;
}
.header-stats span {
  font-size: 12px; color: var(--text2);
  white-space: nowrap;
}
.header-stats b { color: var(--accent); }

/* ===== NAV ===== */
#nav {
  background: var(--bg3);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  display: flex; flex-wrap: wrap;
  align-items: center; gap: 0;
  min-height: 44px;
}
.nav-group { display: flex; align-items: center; }
.nav-parent {
  padding: 0 14px; height: 44px; line-height: 44px;
  font-size: 14px; font-weight: 600;
  color: var(--gold); white-space: nowrap;
  border-right: 1px solid var(--border);
}
.nav-child {
  padding: 0 14px; height: 44px; line-height: 44px;
  font-size: 13px; color: var(--text2);
  white-space: nowrap; transition: color var(--trans);
}
.nav-child:hover, .nav-child.active { color: var(--accent); }
.nav-divider {
  width: 1px; height: 20px; background: var(--border); margin: 0 4px;
}

/* ===== 面包屑 ===== */
.breadcrumb {
  padding: 12px 0; font-size: 13px; color: var(--text2);
}
.breadcrumb a { color: var(--text2); transition: color var(--trans); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb .sep { margin: 0 8px; }

/* ===== 首页Banner区块 ===== */
.banner-section {
  padding: 20px 0 0;
}
.banner-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 16px;
  align-items: start;
}

/* 主轮播 */
.swiper-wrap {
  position: relative; border-radius: var(--radius);
  overflow: hidden; aspect-ratio: 16/7;
  background: var(--bg3);
}
.swiper-slides { position: relative; width: 100%; height: 100%; }
.swiper-slide {
  position: absolute; inset: 0;
  opacity: 0; transition: opacity .6s ease;
}
.swiper-slide.active { opacity: 1; }
.swiper-slide img {
  width: 100%; height: 100%; object-fit: cover;
}
.swiper-info {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 40px 20px 18px;
  background: linear-gradient(to top, rgba(0,0,0,.85), transparent);
}
.swiper-info h3 { font-size: 20px; font-weight: 700; margin-bottom: 6px; }
.swiper-info p { font-size: 12px; color: rgba(255,255,255,.7); line-height: 1.5; }
.swiper-info .play-btn {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 10px; padding: 7px 18px;
  background: var(--accent); color: #fff;
  border-radius: 20px; font-size: 13px;
  transition: background var(--trans);
}
.swiper-info .play-btn:hover { background: #c2284f; }
.swiper-dots {
  position: absolute; bottom: 14px; right: 14px;
  display: flex; gap: 6px;
}
.swiper-dot {
  width: 6px; height: 6px; border-radius: 3px;
  background: rgba(255,255,255,.4); cursor: pointer;
  transition: all var(--trans);
}
.swiper-dot.active { width: 20px; background: var(--accent); }
.swiper-prev, .swiper-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(0,0,0,.5); border: none; cursor: pointer;
  color: #fff; font-size: 18px; display: flex;
  align-items: center; justify-content: center;
  transition: background var(--trans); z-index: 5;
}
.swiper-prev:hover, .swiper-next:hover { background: var(--accent); }
.swiper-prev { left: 10px; }
.swiper-next { right: 10px; }

/* 侧边更新列表 */
.side-update {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
}
.side-update-head {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 8px;
}
.side-update-head h4 { font-size: 14px; font-weight: 600; }
.dot-red { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex-shrink: 0; }
.update-list { padding: 8px 0; }
.update-item {
  display: flex; align-items: center; gap: 10px;
  padding: 7px 16px;
  border-bottom: 1px solid rgba(255,255,255,.04);
  transition: background var(--trans);
}
.update-item:last-child { border: none; }
.update-item:hover { background: rgba(255,255,255,.03); }
.update-item .num {
  width: 22px; height: 22px; border-radius: 4px;
  background: var(--bg3); color: var(--text2);
  font-size: 11px; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.update-item:nth-child(-n+3) .num { background: var(--accent); color: #fff; }
.update-item .name {
  flex: 1; font-size: 13px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap;
}
.update-item .name:hover { color: var(--accent); }
.update-item .time { font-size: 11px; color: var(--text2); flex-shrink: 0; }

/* ===== 区块标题 ===== */
.section-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 24px 0 14px;
}
.section-head h2 {
  font-size: 18px; font-weight: 700;
  display: flex; align-items: center; gap: 10px;
}
.section-head h2::before {
  content: '';
  width: 4px; height: 20px;
  background: linear-gradient(to bottom, var(--accent), var(--accent2));
  border-radius: 2px;
}
.section-head a { font-size: 13px; color: var(--text2); transition: color var(--trans); }
.section-head a:hover { color: var(--accent); }

/* ===== 影片卡片网格 ===== */
.vod-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}
.vod-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--trans), box-shadow var(--trans), border-color var(--trans);
  cursor: pointer;
}
.vod-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}
.vod-card-thumb {
  position: relative; aspect-ratio: 3/4;
  background: var(--bg3); overflow: hidden;
}
.vod-card-thumb img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
}
.vod-card:hover .vod-card-thumb img { transform: scale(1.05); }
.vod-card-thumb .badge {
  position: absolute; top: 8px; left: 8px;
  padding: 2px 8px; border-radius: 4px;
  font-size: 11px; font-weight: 600;
}
.badge-new { background: var(--accent); color: #fff; }
.badge-hot { background: var(--accent2); color: #fff; }
.badge-hd  { background: var(--gold); color: #111; }
.vod-card-thumb .overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.5);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity var(--trans);
}
.vod-card:hover .overlay { opacity: 1; }
.overlay-play {
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--accent); display: flex;
  align-items: center; justify-content: center;
}
.overlay-play svg { width: 20px; height: 20px; fill: #fff; }
.vod-card-body { padding: 10px 12px 12px; }
.vod-card-title {
  font-size: 13px; font-weight: 600;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  margin-bottom: 4px;
}
.vod-card-meta {
  font-size: 11px; color: var(--text2);
  display: flex; align-items: center; justify-content: space-between;
}
.vod-card-meta .tag {
  background: var(--bg3); color: var(--text2);
  padding: 2px 6px; border-radius: 3px;
}
.vod-card-time { font-size: 11px; color: var(--text2); }

/* ===== 列表式（首页/分类/搜索） ===== */
.list-head {
  display: flex; align-items: center;
  padding: 12px 16px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius) var(--radius) 0 0;
  font-size: 12px; color: var(--text2);
  font-weight: 600;
}
.list-head .col-name { flex: 1; }
.list-head .col-type { width: 120px; text-align: center; }
.list-head .col-action { width: 100px; text-align: center; }
.list-head .col-time { width: 120px; text-align: center; }

.video-list {
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  overflow: hidden;
}
.video-item {
  display: flex; align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,.04);
  transition: background var(--trans);
}
.video-item:last-child { border: none; }
.video-item:hover { background: rgba(255,255,255,.03); }
.video-item .fire-icon { width: 18px; margin-right: 8px; flex-shrink: 0; }
.video-item .col-name {
  flex: 1; font-size: 13px; font-weight: 500;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.video-item .col-name a:hover { color: var(--accent); }
.video-item .col-type { width: 120px; text-align: center; font-size: 12px; color: var(--text2); }
.video-item .col-action { width: 100px; text-align: center; }
.video-item .col-action a {
  display: inline-block; padding: 4px 12px;
  background: var(--accent); color: #fff;
  border-radius: 4px; font-size: 12px;
  transition: background var(--trans);
}
.video-item .col-action a:hover { background: #c2284f; }
.video-item .col-time {
  width: 120px; text-align: center;
  font-size: 12px; color: var(--accent);
}

/* ===== 详情页 ===== */
.detail-section { padding: 20px 0; }
.detail-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
  display: flex; gap: 24px;
}
.detail-poster {
  width: 180px; flex-shrink: 0;
  border-radius: var(--radius); overflow: hidden;
}
.detail-poster img { width: 100%; aspect-ratio: 2/3; object-fit: cover; }
.detail-info { flex: 1; }
.detail-info h1 {
  font-size: 22px; font-weight: 700; margin-bottom: 12px;
}
.detail-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.detail-meta-item { display: flex; gap: 6px; font-size: 13px; }
.detail-meta-label { color: var(--text2); }
.detail-meta-value { color: var(--text); }
.detail-desc {
  font-size: 13px; color: var(--text2);
  line-height: 1.8; margin-bottom: 16px;
}
.detail-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 24px; background: var(--accent); color: #fff;
  border-radius: 24px; font-size: 14px; font-weight: 600;
  transition: background var(--trans), transform var(--trans);
}
.btn-primary:hover { background: #c2284f; transform: translateY(-1px); }
.btn-secondary {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 24px;
  border: 1px solid var(--border); color: var(--text2);
  border-radius: 24px; font-size: 14px;
  transition: all var(--trans);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }

/* 播放列表 */
.playlist-box {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); margin-top: 16px; overflow: hidden;
}
.playlist-head {
  padding: 14px 18px; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.playlist-head h3 { font-size: 15px; font-weight: 600; }
.playlist-source { font-size: 12px; color: var(--text2); }
.playlist-grid {
  padding: 16px 18px;
  display: flex; flex-wrap: wrap; gap: 8px;
  max-height: 360px; overflow-y: auto;
}
.ep-btn {
  padding: 7px 14px; border-radius: 4px;
  background: var(--bg3); color: var(--text2);
  font-size: 12px; border: 1px solid var(--border);
  transition: all var(--trans); white-space: nowrap;
}
.ep-btn:hover { border-color: var(--accent); color: var(--accent); }
.ep-btn.current { background: var(--accent); color: #fff; border-color: var(--accent); }
.copy-all-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 14px;
  border: 1px solid var(--border); color: var(--text2);
  border-radius: 4px; font-size: 12px; cursor: pointer;
  background: none; transition: all var(--trans);
}
.copy-all-btn:hover { border-color: var(--accent); color: var(--accent); }

/* ===== 播放页 ===== */
.player-section { padding: 16px 0; }
.player-wrap {
  background: #000; border-radius: var(--radius);
  overflow: hidden; aspect-ratio: 16/9;
  position: relative;
}
.player-wrap iframe, .player-wrap video {
  width: 100%; height: 100%; border: none;
}
.player-info {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px 20px; margin-top: 12px;
  display: flex; align-items: center; justify-content: space-between;
}
.player-title { font-size: 16px; font-weight: 600; }
.player-subtitle { font-size: 13px; color: var(--text2); margin-top: 4px; }
.player-nav { display: flex; gap: 8px; }
.player-nav a {
  padding: 7px 16px; border-radius: 4px;
  border: 1px solid var(--border); color: var(--text2);
  font-size: 13px; transition: all var(--trans);
}
.player-nav a:hover { border-color: var(--accent); color: var(--accent); }

/* ===== 搜索结果页顶部 ===== */
.search-banner {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px 20px; margin-bottom: 16px;
}
.search-keyword {
  font-size: 16px; font-weight: 600;
  color: var(--text);
}
.search-keyword em { color: var(--accent); font-style: normal; }
.search-count { font-size: 13px; color: var(--text2); margin-top: 4px; }

/* ===== 分页 ===== */
.paging {
  display: flex; justify-content: center; align-items: center;
  gap: 6px; padding: 28px 0;
}
.paging a, .paging span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px; padding: 0 10px;
  border-radius: 6px; font-size: 13px;
  border: 1px solid var(--border);
  color: var(--text2); transition: all var(--trans);
}
.paging a:hover { border-color: var(--accent); color: var(--accent); }
.paging .current {
  background: var(--accent); border-color: var(--accent);
  color: #fff; font-weight: 600;
}
.paging .disabled { opacity: .4; cursor: not-allowed; }

/* ===== 公告面板 ===== */
.notice-panel {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); margin: 16px 0; overflow: hidden;
}
.notice-panel .panel-head {
  padding: 12px 18px; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.notice-panel .panel-head h4 { font-size: 14px; font-weight: 600; color: var(--gold); }
.notice-panel .panel-body { padding: 14px 18px; }
.notice-panel .panel-body p { font-size: 13px; color: var(--text2); margin-bottom: 8px; line-height: 1.7; }
.notice-panel .panel-body p:last-child { margin: 0; }
.notice-panel .panel-body a { color: var(--accent); }
.notice-panel .panel-body a:hover { text-decoration: underline; }

/* ===== FOOTER ===== */
#footer {
  background: var(--bg2);
  border-top: 1px solid var(--border);
  margin-top: 48px; padding: 28px 0;
  text-align: center;
}
.footer-links {
  display: flex; justify-content: center; flex-wrap: wrap;
  gap: 20px; margin-bottom: 16px;
}
.footer-links a {
  font-size: 13px; color: var(--text2);
  transition: color var(--trans);
}
.footer-links a:hover { color: var(--accent); }
.footer-copy {
  font-size: 12px; color: var(--text2); line-height: 2;
}
.footer-disclaimer {
  font-size: 11px; color: rgba(139,147,176,.5);
  max-width: 700px; margin: 8px auto 0; line-height: 1.8;
}

/* ===== 工具类 ===== */
.clear { clear: both; }
.text-red { color: var(--accent); }
.text-muted { color: var(--text2); }
.mt8  { margin-top: 8px; }
.mt16 { margin-top: 16px; }
.mt24 { margin-top: 24px; }
.mb16 { margin-bottom: 16px; }

/* ===== 播放地址列表（详情页） ===== */
.addr-list { padding: 0 18px 12px; }
.addr-item {
  display: flex; align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
  gap: 16px;
  flex-wrap: nowrap;
}
.addr-item:last-of-type { border: none; }
.addr-text {
  flex: 1; font-size: 13px; color: var(--accent);
  word-break: break-all; line-height: 1.6;
  transition: opacity var(--trans);
  min-width: 0;
}
.addr-text:hover { opacity: .75; }
.addr-play-btn {
  flex-shrink: 0;
  display: inline-block;
  padding: 6px 18px;
  border: 1px solid var(--accent); color: var(--accent);
  border-radius: 4px; font-size: 12px; white-space: nowrap;
  transition: all var(--trans);
}
.addr-play-btn:hover { background: var(--accent); color: #fff; }
.addr-footer {
  display: flex; align-items: center;
  justify-content: space-between;
  padding: 10px 0 4px;
}
.addr-tip { font-size: 12px; color: var(--text2); }
