/* 彩虹：战报式排版（顶栏 + 时间线 + 正文侧栏），彩虹配色点缀 */
:root {
  --ch-ink: #2b2d42;
  --ch-sub: #4f5268;
  --ch-mute: #9a9cb5;
  --ch-line: #eeedf4;
  --ch-soft: #fafafc;
  --ch-c1: #ff6b6b;
  --ch-c2: #ff922b;
  --ch-c3: #fcc419;
  --ch-c4: #51cf66;
  --ch-c5: #339af0;
  --ch-c6: #9775fa;
  --ch-live: #fa5252;
  --ch-rainbow: linear-gradient(90deg, var(--ch-c1), var(--ch-c2), var(--ch-c3), var(--ch-c4), var(--ch-c5), var(--ch-c6));
}
*, *::before, *::after { box-sizing: border-box; }
html { font-size: 16px; }
body { margin: 0; color: var(--ch-sub); background: #fff; font: 16px/1.7 -apple-system, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", "Helvetica Neue", Arial, sans-serif; }
a { color: var(--ch-ink); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2 { color: var(--ch-ink); font-weight: 600; }
[hidden], .ch-hide { display: none !important; }

/* 顶栏 */
.ch-top { position: relative; border-bottom: 1px solid var(--ch-line); }
.ch-top::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--ch-rainbow); }
.ch-top-in { max-width: 980px; margin: 0 auto; padding: 0 20px; height: 56px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.ch-logo { font-size: 18px; font-weight: 600; white-space: nowrap; }
.ch-logo:hover { text-decoration: none; }
.ch-nav { display: flex; gap: 24px; }
.ch-nav-i { padding: 16px 0 14px; font-size: 15px; color: var(--ch-sub); border-bottom: 2px solid transparent; }
.ch-nav-i:hover { color: var(--ch-ink); text-decoration: none; }
.ch-nav-i.on { color: var(--ch-ink); font-weight: 600; border-bottom-color: var(--ch-c5); }

.ch-wrap { display: block; max-width: 980px; min-height: 60vh; margin: 0 auto; padding: 28px 20px 10px; }

/* 标题区 */
.ch-crumb { margin: 0 0 8px; font-size: 13px; color: var(--ch-mute); }
.ch-crumb a { color: var(--ch-mute); }
.ch-h1 { margin: 0; font-size: 22px; line-height: 1.4; }
.ch-lead { margin: 6px 0 24px; font-size: 14px; color: var(--ch-mute); }

/* 首页两栏 */
.ch-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.ch-col-t { margin: 0; padding-bottom: 8px; font-size: 16px; border-bottom: 1px solid var(--ch-ink); }
.ch-col-t::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--ch-c5); vertical-align: 2px; }
.ch-col:nth-child(2) .ch-col-t::before { background: var(--ch-c2); }
.ch-more { display: inline-block; margin-top: 16px; padding: 7px 18px; border-radius: 4px; background: var(--ch-c5); color: #fff; font-size: 14px; }
.ch-col:nth-child(2) .ch-more { background: var(--ch-c2); }
.ch-more:hover { opacity: .9; text-decoration: none; }

/* 时间线 */
.ch-tl { list-style: none; margin: 0; padding: 0; }
.ch-row { display: grid; grid-template-columns: 52px 1fr; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--ch-line); }
.ch-row-t { font-size: 14px; line-height: 1.6; color: var(--ch-mute); font-variant-numeric: tabular-nums; }
.is-live .ch-row-t { color: var(--ch-live); }
.ch-row-b { min-width: 0; }
.ch-row-vs { display: flex; align-items: center; gap: 6px; font-size: 15px; line-height: 1.6; }
.ch-team { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.ch-sc { flex: none; padding: 0 6px; color: var(--ch-mute); font-variant-numeric: tabular-nums; }
.is-live .ch-sc { color: var(--ch-live); font-weight: 600; }
.ch-emb { flex: none; width: 18px; height: 18px; object-fit: contain; }
.ch-row-m { display: flex; gap: 10px; margin: 2px 0 0; font-size: 12px; color: var(--ch-mute); }
.ch-row-m em { font-style: normal; }
.ch-st.live { color: var(--ch-live); }
.ch-tag { color: var(--ch-c4); }
.ch-tag.ch-btn-fill { color: var(--ch-live); }
.ch-tl-s .ch-row { grid-template-columns: 44px 1fr; gap: 10px; }
.ch-tl-s .ch-row-t { font-size: 13px; }
.ch-tl-s .ch-row-vs { font-size: 14px; }
.ch-pop { animation: chpop 2s ease-out; }
@keyframes chpop { 0%, 40% { background: #fff3b0; } 100% { background: transparent; } }

/* 按日期分组 */
.ch-day { margin-bottom: 28px; }
.ch-day-t { margin: 0; padding-bottom: 8px; font-size: 15px; border-bottom: 1px solid var(--ch-ink); }

/* 分页 */
.ch-pages { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; padding: 20px 0; }
.ch-pages a, .ch-pages strong { min-width: 34px; padding: 5px 10px; text-align: center; border: 1px solid var(--ch-line); border-radius: 4px; font-size: 14px; font-weight: 400; }
.ch-pages a:hover { border-color: #ccc; text-decoration: none; }
.ch-pages strong { background: var(--ch-c5); border-color: var(--ch-c5); color: #fff; }

.ch-empty { margin: 0; padding: 20px 0; font-size: 14px; color: var(--ch-mute); }
.ch-empty-over { padding: 14px 16px; background: var(--ch-soft); border-left: 3px solid var(--ch-live); color: var(--ch-live); }

/* 详情 */
.ch-spread { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 48px; align-items: start; }
.ch-kicker { margin: 0; font-size: 13px; color: var(--ch-mute); }
.ch-title { margin: 4px 0; font-size: 24px; line-height: 1.4; }
.ch-byline { margin: 0 0 20px; font-size: 13px; color: var(--ch-mute); }

.ch-score { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; margin-bottom: 28px; padding: 24px 0; border-top: 1px solid var(--ch-line); border-bottom: 1px solid var(--ch-line); }
.ch-score-side { display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; text-align: center; }
.ch-score-side img { width: 52px; height: 52px; object-fit: contain; }
.ch-ini { display: flex; width: 52px; height: 52px; align-items: center; justify-content: center; border-radius: 50%; background: var(--ch-soft); border: 1px solid var(--ch-line); color: var(--ch-ink); font-size: 20px; }
.ch-score-side b { max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 15px; font-weight: 600; color: var(--ch-ink); }
.ch-score-side small { font-size: 12px; color: var(--ch-mute); }
.ch-score-mid { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0 16px; }
.ch-score-mid .ch-st { font-size: 12px; color: var(--ch-mute); }
.ch-score-mid .ch-st.live { color: var(--ch-live); }
.ch-score-mid strong { font-size: 32px; font-weight: 600; color: var(--ch-ink); white-space: nowrap; font-variant-numeric: tabular-nums; }

.ch-block { margin-bottom: 32px; }
.ch-block-t { margin: 0 0 14px; font-size: 16px; }
.ch-video { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 4px; background: #111; }
.ch-video video, .ch-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.ch-video-tip { position: absolute; inset: 0; margin: 0; display: flex; align-items: center; justify-content: center; color: #888; font-size: 14px; }
.ch-lines { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.ch-line { --c: var(--ch-c5); display: inline-block; padding: 6px 16px; border: 1px solid var(--c); border-radius: 4px; background: #fff; color: var(--c); font: 400 14px/1.6 -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; cursor: pointer; }
.ch-line:nth-child(6n+2) { --c: var(--ch-c4); }
.ch-line:nth-child(6n+3) { --c: var(--ch-c2); }
.ch-line:nth-child(6n+4) { --c: var(--ch-c6); }
.ch-line:nth-child(6n+5) { --c: var(--ch-c1); }
.ch-line:nth-child(6n) { --c: #e0a800; }
.ch-line:hover { text-decoration: none; }
.ch-line.cur { background: var(--c); color: #fff; }
.ch-line sup { margin-left: 3px; font-size: 10px; opacity: .7; }
.ch-note { margin: 10px 0 0; font-size: 12px; color: var(--ch-mute); }

.ch-dl { display: grid; grid-template-columns: 100px 1fr; margin: 0; }
.ch-dl dt, .ch-dl dd { margin: 0; padding: 8px 0; border-bottom: 1px solid var(--ch-line); font-size: 14px; }
.ch-dl dt { color: var(--ch-mute); }
.ch-dl dd { color: var(--ch-ink); }

.ch-side { margin-bottom: 28px; }
.ch-side-t { margin: 0 0 4px; padding-bottom: 8px; font-size: 15px; border-bottom: 1px solid var(--ch-ink); }
.ch-side-tip { font-size: 13px; color: var(--ch-mute); }
.ch-side-tip .ch-side-t { border-bottom-color: var(--ch-line); }
.ch-side-tip p { margin: 8px 0 0; }

/* 404 */
.ch-404 { padding: 60px 0 40px; text-align: center; }
.ch-404-code { margin: 0 0 8px; font-size: 48px; font-weight: 300; line-height: 1.2; background: var(--ch-rainbow); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ch-404-go { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0; }
.ch-404-go a { padding: 7px 18px; border: 1px solid var(--ch-line); border-radius: 4px; font-size: 14px; }
.ch-404-go a:last-child { background: var(--ch-c5); border-color: var(--ch-c5); color: #fff; }
.ch-404-go a:hover { text-decoration: none; }

/* 页脚 */
.ch-foot { max-width: 980px; margin: 40px auto 0; padding: 20px; border-top: 1px solid var(--ch-line); text-align: center; font-size: 12px; color: var(--ch-mute); }
.ch-foot p { margin: 4px 0; }
.ch-foot a { margin: 0 6px; color: var(--ch-mute); }

@media (max-width: 860px) {
  .ch-top-in { padding: 0 14px; }
  .ch-nav { gap: 16px; }
  .ch-nav-i { font-size: 14px; }
  .ch-wrap { padding: 20px 14px 6px; }
  .ch-h1 { font-size: 19px; }
  .ch-cols, .ch-spread { grid-template-columns: 1fr; gap: 28px; }
  .ch-row { grid-template-columns: 44px 1fr; gap: 10px; }
  .ch-row-t { font-size: 13px; }
  .ch-row-vs { font-size: 14px; }
  .ch-title { font-size: 20px; }
  .ch-score-side img, .ch-ini { width: 40px; height: 40px; font-size: 16px; }
  .ch-score-side b { font-size: 14px; }
  .ch-score-mid { padding: 0 8px; }
  .ch-score-mid strong { font-size: 24px; }
  .ch-dl { grid-template-columns: 80px 1fr; }
}
@media (max-width: 420px) {
  .ch-top-in { height: auto; padding: 10px 14px 0; flex-direction: column; align-items: flex-start; gap: 0; }
  .ch-nav-i { padding: 8px 0 10px; }
}

/* 比分列表（内置 score-row 等）配色 */
:root { --sc-accent: #339af0; --sc-on: #fff; --sc-live: #fa5252; --sc-radius: 14px; }

/* 热门比赛标记（后台设为热门或属于热门联赛），手机上只显示火苗 */
.ch-fire { display: inline-flex; align-items: center; gap: 1px; margin-left: 4px; padding: 0 6px 0 4px; border-radius: 9px; background: linear-gradient(90deg, #ff8a1f, #ff3b30); color: #fff; font: normal 700 11px/17px -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; letter-spacing: 0; vertical-align: middle; white-space: nowrap; text-transform: none; animation: ch-fire-glow 1.8s ease-in-out infinite; }
.ch-fire::before { content: "🔥"; font-size: 11px; line-height: 1; }
@keyframes ch-fire-glow { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 80, 30, .35); } 50% { box-shadow: 0 0 0 4px rgba(255, 80, 30, 0); } }
@media (max-width: 480px) {
  .ch-fire { padding: 0 3px; font-size: 0; gap: 0; margin-left: 2px; }
  .ch-fire::before { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) { .ch-fire { animation: none; } }

/* 热门比赛：火苗跳动；整行左侧一抹淡淡的火光缓慢明暗，叠在原有背景上，不改变原样式 */
.ch-fire::before { display: inline-block; transform-origin: 50% 85%; animation: ch-flicker 1.3s ease-in-out infinite; }
@keyframes ch-flicker {
  0%, 100% { transform: scale(1) rotate(-4deg); filter: brightness(1); }
  25% { transform: scale(1.1, 1.2) rotate(3deg); filter: brightness(1.2); }
  50% { transform: scale(.95, 1.04) rotate(-2deg); filter: brightness(.95); }
  75% { transform: scale(1.06, 1.14) rotate(4deg); filter: brightness(1.15); }
}
.ch-hotrow { animation: ch-ember 3.2s ease-in-out infinite; }
@keyframes ch-ember {
  0%, 100% { box-shadow: inset 3px 0 0 rgba(255, 98, 40, .7), inset 90px 0 70px -52px rgba(255, 140, 50, .16); }
  50% { box-shadow: inset 3px 0 0 rgba(255, 64, 30, .9), inset 130px 0 90px -60px rgba(255, 112, 40, .26); }
}
tr.ch-hotrow { animation: none; }
tr.ch-hotrow > td { animation: ch-ember-td 3.2s ease-in-out infinite; }
tr.ch-hotrow > td:first-child { box-shadow: inset 3px 0 0 rgba(255, 80, 30, .8); }
@keyframes ch-ember-td { 0%, 100% { background-color: rgba(255, 150, 60, .05); } 50% { background-color: rgba(255, 120, 40, .11); } }
@media (prefers-reduced-motion: reduce) {
  .ch-fire::before, .ch-hotrow, tr.ch-hotrow > td { animation: none; }
  .ch-hotrow { box-shadow: inset 3px 0 0 rgba(255, 98, 40, .7), inset 90px 0 70px -52px rgba(255, 140, 50, .16); }
}

/* 播放页球队名链接到球队搜索页 */
.ch-tlink { color: inherit; text-decoration: none; border-bottom: 1px dashed currentColor; }
.ch-tlink:hover { opacity: .8; border-bottom-style: solid; }

/* 首页：日期选择 + 热门直播 + 赛事直播 */
.ch-wrap > .hd-dates { margin: 0 0 24px; }
.ch-hot, [data-hd-scope] { margin-bottom: 28px; }
.ch-col-t small { margin-left: 8px; font-size: 13px; font-weight: 400; color: var(--ch-mute); }
.ch-scope-t { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ch-scope-t h2 { margin: 0; font-size: 16px; }
.ch-scope-t::before { display: none; }
.ch-scope-t h2::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--ch-c2); vertical-align: 2px; }
[data-hd-scope] .hd-day { padding-left: 0; }
.ch-row-m .hd-lg:hover { color: var(--ch-ink); }
/* 导航 5 项：手机上一屏放下 */
@media (max-width: 480px) {
  .ch-nav { width: 100%; gap: 0; justify-content: space-between; }
  .ch-nav-i { font-size: 14px; }
}
.ch-row.ch-hotrow { padding-left: 10px; }

/* 热门标记：本模板专属样式（🌈 热门），覆盖上面通用的 🔥 热门；手机上只显示图标 */
.ch-fire { --ch-hot-lb: 11px; gap: 2px; font-size: 0; background: linear-gradient(90deg,#ff6b6b,#fcc419,#51cf66,#339af0,#cc5de8); color: #fff; border: 0; border-radius: 9px; animation: ch-hot-glow 1.8s ease-in-out infinite; text-shadow: 0 1px 1px rgba(0,0,0,.25); }
.ch-fire::before { content: "🌈"; display: inline-block; transform-origin: 50% 50%; animation: ch-hot-ic 1s ease-in-out infinite; }
.ch-fire::after { content: "热门"; font-size: var(--ch-hot-lb); line-height: 1; }
@keyframes ch-hot-glow { 0%, 100% { box-shadow: 0 0 0 0 rgba(204,93,232, .35); } 50% { box-shadow: 0 0 0 4px rgba(204,93,232, 0); } }
@keyframes ch-hot-ic { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-2px); } }
@media (max-width: 480px) { .ch-fire { --ch-hot-lb: 0; gap: 0; } }
@media (prefers-reduced-motion: reduce) { .ch-fire, .ch-fire::before { animation: none; } }

/* 日期条吸顶（样式在内置 hd.css）：底色跟页面一致 */
:root { --hd-bg: #fff; }
/* 整行可点（row-cover） */
.ch-row { cursor: pointer; }
