/* ==========================================
   CSS Variables — tp45_light_pink：暖米白底 + 珊瑚粉主色（版式参考 dmhyy.com 亮色版）
   色值依目标站实测（canvas #fff8f2／surface #fffdfb／inset #f0e9e3／ink #2a211f／muted #7c6d68／heading #3a241f／line #eadfd9／
   primary #e76550／顶栏渐层 #fbe4dc→#fff8f2／页面顶部晕染 #f5c4b8→#fbe4dc／海报状态胶囊 rgb(42 33 31/.78)）
   元件内一律引用变数，不写死色码
   ========================================== */
:root {
  --section-gap:  24px;   /* 模块统一垂直间距（skill 强制 20） */
  --bg-base:       #fff8f2;   /* 全站暖米白背景（目标站 canvas） */
  --bg-topbar:     rgba(255, 248, 242, 0.96);   /* 底栏／弹层用的半透明底 */
  --bg-header:     linear-gradient(110deg, #fbe4dc, #fff8f2);   /* 顶栏暖粉渐层（目标站 --header-background） */
  --bg-page-top:   linear-gradient(180deg, #fbe4dc 0, rgba(251, 228, 220, 0) 460px);   /* 页面顶部粉色晕染 */
  --bg-card:       #fffdfb;   /* 卡片／面板（目标站 surface） */
  --bg-elevated:   #f0e9e3;   /* 次一阶底色：胶囊、hover（目标站 inset） */
  --bg-tertiary:   #f0e5df;   /* 图片占位（目标站 placeholder） */
  --bg-soft:       #f6eee9;   /* 极浅分隔线／列表 hover */

  --accent:        #e76550;   /* 珊瑚粉主色：选中胶囊、指示器、CTA、色条 */
  --accent-hover:  #d4533f;
  --accent-deep:   #c4442f;   /* 浅底上的强调文字（加深以确保对比度 ≥4.5:1） */
  --accent-light:  rgba(231, 101, 80, 0.1);
  --accent-grad:   linear-gradient(to right, #f08a6f 0%, #e76550 100%);   /* 主按钮／数字徽章渐层 */
  --on-accent:     #ffffff;

  --rank-1:        #e76550;   /* 排行前三名：珊瑚／橙／杏 */
  --rank-2:        #f08a4b;
  --rank-3:        #f2b04b;

  --gold:          #f5a524;   /* 评分星级金色 */
  --gold-2:        #ec7a4f;
  --gold-grad:     linear-gradient(104deg, var(--gold) 9.95%, var(--gold-2) 86.56%);
  --gold-line:     rgba(245, 165, 36, 0.3);   /* 站内广告横幅金色描边 */

  --danger:        #d64545;   /* 错误提示（目标站 --color-error） */
  --danger-light:  rgba(214, 69, 69, 0.08);
  --danger-line:   rgba(214, 69, 69, 0.2);
  --status-end:    #2f8f63;   /* 完结状态标签文字 */
  --status-end-light: rgba(63, 178, 127, 0.14);

  --detail-veil-top: rgba(255, 248, 242, 0.55);   /* 详情页 Hero 背景虚化遮罩（暖米白，末端接 --bg-base） */
  --detail-veil-mid: rgba(255, 248, 242, 0.82);
  --pad-box:       24px;      /* 弹窗／空态／载入提示的内距 */

  --text-1:        #2a211f;   /* 正文（目标站 ink） */
  --text-2:        #7c6d68;   /* 次要文字（目标站 muted） */
  --text-3:        #a3928b;   /* 三级文字 */
  --text-label:    #7c6d68;
  --text-strong:   #3a241f;   /* 标题（目标站 heading） */
  --text-nav:      #8d7d77;   /* 顶栏导航（目标站 nav-muted） */
  --text-nav-on:   var(--accent-deep);
  --text-btn:      #7c6d68;
  --text-tab-off:  #8d7d77;
  --text-foot:     #8d7d77;
  --rank-num:      #cdbab2;   /* 排行第 4 名起的数字 */

  --border:        #eadfd9;   /* 目标站 line */
  --border-2:      #e2d3cb;

  --score-hi:      #ec7a4f;
  --score-mid:     #3fb27f;

  --media-status:  rgba(42, 33, 31, 0.78);     /* 海报右上角状态胶囊底（目标站 --media-status-background） */
  --media-status-line: rgba(255, 244, 237, 0.46);
  --hero-panel:    linear-gradient(90deg, rgba(42, 33, 31, 0) 0%, rgba(42, 33, 31, 0.55) 30%, rgba(42, 33, 31, 0.72) 100%);   /* Banner 右侧面板底 */
  --hero-fade:     linear-gradient(180deg, rgba(42, 33, 31, 0) 0%, rgba(42, 33, 31, 0.72) 100%);   /* 移动端 Banner 底部叠字渐层 */
  --hero-dot:      rgba(255, 255, 255, 0.5);
  --hero-arrow-bg: #ffffff;
  --hero-arrow-fg: #2a211f;

  --shadow-sm:     0 1px 4px rgba(107, 60, 50, 0.08);
  --shadow-md:     0 4px 20px rgba(107, 60, 50, 0.08);   /* 目标站 --surface-shadow */
  --shadow-paper:  0 4px 20px rgba(107, 60, 50, 0.08), 0 0 1px rgba(107, 60, 50, 0.12);
  --shadow-card-hover: 0 12px 24px -8px rgba(107, 60, 50, 0.28);
  --shadow-poster: 0 12px 30px rgba(0, 0, 0, 0.35);
  --shadow-accent: 0 6px 18px rgba(231, 101, 80, 0.3);   /* 漂浮按钮主色投影 */
  --shadow-accent-hover: 0 8px 28px rgba(231, 101, 80, 0.4), 0 2px 10px rgba(107, 60, 50, 0.14);

  /* 旧页面 CSS 内引用的别名变数 */
  --text-pri:      var(--text-1);
  --text-sec:      var(--text-2);
  --text-muted:    var(--text-3);
  --bg-sidebar:    var(--bg-card);

  --font-impact:   Impact, "Helvetica Neue", sans-serif;   /* 排行数字 */
  --container:     1400px;    /* 内容最大宽度（目标站 max-w 1400） */
  --page-pad:      24px;      /* 内容两侧留白：≥1200 24px／≤1199 16px／≤767 12px */
  --topbar-h:      64px;
  --radius:        8px;
  --radius-sm:     4px;
  --radius-lg:     16px;      /* Banner 圆角 */
  --radius-pill:   999px;
}

/* ==========================================
  Base Reset
   ========================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  background-color: var(--bg-base);
  scroll-behavior: smooth;
}

body {
  background: var(--bg-page-top) no-repeat, var(--bg-base);
  color: var(--text-1);
  font-family: -apple-system-font, BlinkMacSystemFont, "Helvetica Neue", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei UI", "Microsoft YaHei", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
}

a { text-decoration: none; color: inherit; }
img { display: block; background: url(../img/load.gif) no-repeat center/cover, var(--bg-tertiary); }
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }
ul { list-style: none; }
/* 评论列表／楼中楼用 ul，归零浏览器预设内距（样式主体在各页 css） */
.cmt-item-reply-list { margin: 0; padding: 0; list-style: none; }
.cmt-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 0; }

/* 仅供屏幕阅读器使用，不影响视觉呈现 */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
/* 全站 icon（public/icons.html 的 SVG sprite）：尺寸跟随 font-size，颜色跟随 color */
.mac-icon {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  width: 1em;
  height: 1em;
  fill: currentColor;
  flex-shrink: 0;
}

/* ==========================================
   Page Layout — 顶栏＋内容全宽置中（--container）；页面顶部粉色晕染由 body 背景提供
   ========================================== */
.page-shell { min-height: 100vh; }

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

/* ==========================================
   Topbar — 仿 dmhyy.com：暖粉渐层吸顶横栏（高 64，底部 1px 分隔线）
   ≥1200px 一列：Logo｜纯文字导航（15px 灰褐字，选中主色粗体）｜置中白底圆角搜索框（max 600）｜观看记录
   ≤1199px：吸顶两列（第 1 列可横滑导航＋观看记录，第 2 列 Logo＋搜索框）
   ========================================== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 200;
  background: var(--bg-header);
  border-bottom: 1px solid var(--border);
  height: var(--topbar-h);
}

.topbar-inner {
  display: flex;
  align-items: center;
  height: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--page-pad);
  gap: 16px;
}
.topbar-left { display: flex; align-items: center; gap: 20px; min-width: 0; flex-shrink: 0; }

/* Logo */
.topbar-brand {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  min-width: 0;
  text-decoration: none;
}
.brand-logo-img {
  height: 30px;
  width: auto;
  max-width: 150px;
  object-fit: contain;
  background: none;
  flex-shrink: 0;
}

/* 导航：列表 ul>li（强制 2.3）；纯文字，选中为主色粗体＋底部 2px 短条 */
.topbar-nav { position: relative; min-width: 0; }
.tn-list { display: flex; align-items: center; list-style: none; margin: 0; padding: 0; gap: 2px; }
.tn-list > li { flex-shrink: 0; }
.tn-item {
  position: relative;
  display: flex;
  align-items: center;
  height: 40px;
  padding: 0 10px;
  font-size: 15px;
  color: var(--text-nav);
  white-space: nowrap;
  transition: color 0.2s;
}
.tn-item:hover { color: var(--accent-deep); }
.tn-item.is-active { color: var(--text-nav-on); font-weight: 700; }
.tn-item.is-active::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 2px;
  width: 16px;
  height: 3px;
  margin-left: -8px;
  border-radius: var(--radius-pill);
  background: var(--accent);
}

/* 右侧：置中搜索框＋观看记录 */
.topbar-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex: 1;
  min-width: 0;
}

/* 搜索：外观仿目标站的白底圆角输入框（max 600、高 40），实际是 #searchToggle 按钮 */
.tb-search-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  max-width: 600px;
  height: 40px;
  margin: 0 auto;
  padding: 0 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  color: var(--text-3);
  font-size: 14px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.tb-search-box .mac-icon { font-size: 18px; color: var(--text-2); }
.tb-search-box:hover { border-color: var(--accent); box-shadow: var(--shadow-md); }
.tb-search-ph { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* 观看记录：图标＋文字，白底圆角描边按钮 */
.tb-hist-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--bg-card);
  font-size: 13px;
  color: var(--text-btn);
  white-space: nowrap;
  flex-shrink: 0;
  transition: color 0.2s, border-color 0.2s;
}
.tb-hist-btn .mac-icon { font-size: 16px; }
.tb-hist-btn:hover { color: var(--accent-deep); border-color: var(--accent); }

/* ≤1199px：吸顶两列（导航列 + Logo/搜索列） */
@media (max-width: 1199px) {
  :root { --topbar-h: 104px; --page-pad: 16px; }   /* --topbar-h 只作锚点/吸顶偏移的参考值，实际高度由内容决定 */
  .topbar { height: auto; }
  .topbar-inner { flex-wrap: wrap; align-content: flex-start; gap: 0 10px; padding-top: 4px; padding-bottom: 8px; }
  .topbar-left, .topbar-right { display: contents; }
  .topbar-nav { order: 1; flex: 1 1 calc(100% - 130px); overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .topbar-nav::-webkit-scrollbar { display: none; }
  .tb-hist-btn { order: 2; }
  .topbar-brand { order: 3; height: 44px; margin-top: 4px; }
  .tb-search-box { order: 4; flex: 1 1 0; max-width: none; margin-top: 4px; }
}
@media (max-width: 767px) {
  :root { --page-pad: 12px; }
  .tn-item { font-size: 14px; padding: 0 8px; }
  .tb-hist-btn span { display: none; }
  .tb-hist-btn { width: 36px; justify-content: center; padding: 0; }
  .topbar-nav { flex-basis: calc(100% - 50px); }
  .brand-logo-img { height: 24px; max-width: 110px; }
}

/* ==========================================
   Search Overlay — 全屏彈出式搜尋
   ========================================== */
.search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 500;
  background: var(--bg-topbar);
  backdrop-filter: blur(6px);
  align-items: flex-start;
  justify-content: center;
  padding-top: 80px;
}
.search-overlay.is-open { display: flex; }

.search-overlay-inner {
  width: 100%;
  max-width: 680px;
  padding: 0 20px;
}

.search-bar {
  display: flex;
  align-items: center;
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 4px 4px 4px 18px;
  gap: 8px;
  transition: border-color 0.2s;
}
.search-bar:focus-within { border-color: var(--accent); }

.search-bar-icon {
  color: var(--text-3);
  font-size: 20px;
  flex-shrink: 0;
}

#searchInput {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: var(--text-1);
  font-size: 16px;
  padding: 10px 0;
  min-width: 0;
}
#searchInput::placeholder { color: var(--text-3); }

.search-submit-btn {
  padding: 9px 22px;
  background: var(--accent-grad);
  color: #fff;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
  transition: background 0.2s;
}
.search-submit-btn:hover { filter: brightness(1.08); }

.search-close-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: var(--text-3);
  font-size: 18px;
  flex-shrink: 0;
  transition: color 0.2s, background 0.2s;
}
.search-close-btn:hover { color: var(--text-1); background: rgba(26, 26, 46, 0.05); }

.search-drop {
  display: flex;
  flex-direction: column;
  padding: 12px 4px 4px;
}
.sd-group + .sd-group { margin-top: 6px; }
.sd-group-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px 6px;
}
.sd-label {
  font-size: 11px;
  color: var(--text-3);
  letter-spacing: 0.5px;
}
.sd-clear {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: var(--text-3);
  font-size: 14px;
  transition: color 0.2s, background 0.2s;
}
.sd-clear:hover { color: var(--text-1); background: rgba(26, 26, 46, 0.05); }
.sd-list { list-style: none; counter-reset: sd-counter; }
.sd-item { counter-increment: sd-counter; }
.sd-word {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 10px;
  padding: 7px 6px;
  border: none;
  background: transparent;
  border-radius: 6px;
  font: inherit;
  font-size: 13px;
  color: var(--text-2);
  text-align: left;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.sd-num {
  flex-shrink: 0;
  width: 16px;
  font-size: 12px;
  color: var(--text-3);
  text-align: center;
}
.sd-num::before { content: counter(sd-counter); }
.sd-word:hover { background: rgba(26, 26, 46, 0.05); color: var(--accent-deep); }
.sd-word:hover .sd-num { color: var(--accent-deep); }

/* ==========================================
   Page Content
   ========================================== */
.page-content { flex: 1; }

/* ==========================================
   Hero Banner — 仿 dmhyy.com：内容区等宽、圆角 16、1px 描边的宽幅轮播（≥1024 高 420），整张投影片为连结（导向详情页）；
   ≥1024px 右侧 400px 深色渐层面板：竖海报（10:14、宽 128，两侧白色圆形上一部／下一部按钮）＋片名置中＋备注＋两行简介，
   面板底部拉长式圆点（选中为主色胶囊）；≤1023px 隐藏海报与箭头，改底部渐层叠字、圆点移到右下角
   ========================================== */
.hero-wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 16px var(--page-pad) 0;
  width: 100%;
}
.hero-banner {
  position: relative;
  height: 420px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-tertiary);
  margin-bottom: var(--section-gap);
  /* 允许手机版左右滑动切换投影片（见 hero.js），同时保留垂直滚动页面 */
  touch-action: pan-y;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: block;
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
  z-index: 1;
  color: var(--on-accent);
}
.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
  z-index: 2;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-color: var(--bg-tertiary);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
}

/* 右侧面板底：由透明渐入深色 */
.hero-overlay {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 480px;
  background: var(--hero-panel);
}

.hero-content {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  z-index: 2;
  width: 400px;
  padding: 40px 28px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero-poster {
  display: block;
  width: 128px;
  aspect-ratio: 10/14;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-tertiary);
  box-shadow: var(--shadow-poster);
  margin-bottom: 20px;
}
.hero-poster img { width: 100%; height: 100%; object-fit: cover; }
.hero-title {
  width: 100%;
  color: var(--on-accent);
  font-size: 20px;
  line-height: 1.4;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hero-note {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--on-accent);
  opacity: 0.9;
  text-align: center;
}
.hero-meta {
  width: 100%;
  margin-top: 8px;
  font-size: 12px;
  line-height: 20px;
  color: var(--on-accent);
  opacity: 0.9;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 上一部／下一部：白色 28px 圆形按钮，贴在海报左右两侧底部（海报顶 40px＋高 179px） */
.hero-arrow {
  position: absolute;
  top: 191px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--hero-arrow-bg);
  color: var(--hero-arrow-fg);
  font-size: 14px;
  box-shadow: var(--shadow-poster);
  transition: background-color 0.2s, color 0.2s;
}
.hero-arrow:hover { background: var(--accent); color: var(--on-accent); }
.hero-prev { right: 280px; }
.hero-next { right: 92px; }

/* 圆点指示器（沿用 #heroPlaylist／.hero-playlist-item／data-idx，hero.js 不需改 selector） */
.hero-playlist {
  position: absolute;
  right: 0;
  bottom: 28px;
  z-index: 5;
  width: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 12px;
}
.hero-playlist-item {
  width: 6px;
  height: 6px;
  padding: 0;
  border-radius: var(--radius-pill);
  background: var(--hero-dot);
  transition: width 0.25s, background-color 0.25s;
}
.hero-playlist-item:hover { background: var(--on-accent); }
.hero-playlist-item.is-active {
  width: 20px;
  background: var(--accent);
}

@media (max-width: 1023px) {
  .hero-banner { height: 300px; }
  .hero-overlay { top: auto; left: 0; width: auto; height: 60%; background: var(--hero-fade); }
  .hero-content {
    top: auto; left: 0;
    width: auto;
    padding: 0 16px 30px;
    align-items: flex-start;
  }
  .hero-poster, .hero-note, .hero-arrow { display: none; }
  .hero-title { text-align: left; font-size: 18px; }
  .hero-meta { max-width: 70%; margin-top: 4px; }
  .hero-playlist { width: auto; right: 16px; bottom: 14px; justify-content: flex-end; }
}
@media (max-width: 767px) {
  .hero-wrap { padding-top: 12px; }
  .hero-banner { height: 200px; border-radius: var(--radius); }
  .hero-content { padding: 0 12px 26px; }
  .hero-title { font-size: 16px; }
  .hero-meta { max-width: 100%; }
  .hero-playlist { right: 12px; bottom: 10px; }
}

/* ==========================================
   Content Block — 模块容器（与顶栏同宽、同内距）
   ========================================== */
.content-block {
  max-width: var(--container);
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  padding: 0 var(--page-pad);
  margin-bottom: var(--section-gap);
}
.index-main { padding-bottom: 8px; }

/* 模块标题行（仿 dmhyy.com）：左侧 4px 主色圆角色条＋18px 粗体标题｜日排行（可选）｜「更多 ›」灰字 */
.section-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-strong);
  line-height: 1.4;
}
.section-title::before {
  content: "";
  flex-shrink: 0;
  width: 4px;
  height: 20px;
  border-radius: var(--radius-pill);
  background: var(--accent);
}
.section-title > a { transition: color 0.2s; }
.section-title > a:hover { color: var(--accent-deep); }
.section-title:has(.section-title-icon)::before { display: none; }   /* 带图标的标题（地图/明星页）不再叠色条 */
.section-title-icon {
  color: var(--accent-deep);
  font-size: 20px;
  display: flex;
}

/* 「更多 ›」：14px 灰字，hover 主色 */
.section-more {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 14px;
  color: var(--text-2);
  white-space: nowrap;
  transition: color 0.2s;
}
.section-more .mac-icon { font-size: 12px; }
.section-more:hover { color: var(--accent-deep); }

/* 首页/分类页模块标题行：当前分类日排行（index.md 强制 2.3 / vod-type 4.2）——横向滚动、不换行、移动端隐藏；前三名珊瑚/橙/杏 */
.section-hd > .section-title,
.section-hd > .section-more { flex-shrink: 0; }
.sh-dayrank { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; padding-left: 12px; font-size: 13px; }
.sdr-label { flex-shrink: 0; display: inline-flex; align-items: center; gap: 3px; padding: 2px 8px; border-radius: var(--radius-pill); background: var(--accent-light); color: var(--accent-deep); font-weight: 700; font-size: 12px; }
.sdr-list { display: flex; gap: 16px; min-width: 0; overflow-x: auto; scrollbar-width: none; list-style: none; margin: 0; padding: 0; counter-reset: sdr; }
.sdr-list::-webkit-scrollbar { display: none; }
.sdr-list > li { flex-shrink: 0; white-space: nowrap; counter-increment: sdr; }
.sdr-item { color: var(--text-2); }
.sdr-item::before { content: counter(sdr); margin-right: 4px; font-weight: 700; color: var(--text-3); }
.sdr-list > li:nth-child(1) .sdr-item::before { color: var(--rank-1); }
.sdr-list > li:nth-child(2) .sdr-item::before { color: var(--rank-2); }
.sdr-list > li:nth-child(3) .sdr-item::before { color: var(--rank-3); }
.sdr-item:hover { color: var(--accent-deep); }

/* 分类页标题页签（「电影推荐 | 电影库」）：左侧色条＋18px 标题，选中为主色字＋底部 3px 短条 */
.mh-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 14px;
}
.mh-tabs::before {
  content: "";
  flex-shrink: 0;
  width: 4px;
  height: 20px;
  margin-right: 4px;
  border-radius: var(--radius-pill);
  background: var(--accent);
}
.mh-tab {
  position: relative;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text-tab-off);
  transition: color 0.2s;
}
a.mh-tab:hover { color: var(--accent-deep); }
.mh-tab.is-active { color: var(--text-strong); }
.mh-line { width: 1px; height: 16px; margin: 0 12px; background: var(--border-2); }

/* 分类页「频道／分类」导航卡片（widget/type_nav_panel；仿 dmhyy.com 分类页白底筛选卡片：行首灰字标签，选项为圆角 4 胶囊，选中主色底白字） */
.type-nav-panel { margin-bottom: var(--section-gap); padding: 8px 16px; border-radius: var(--radius); background: var(--bg-card); box-shadow: var(--shadow-sm); font-size: 14px; }
.tnp-row { display: flex; align-items: center; gap: 8px; padding: 6px 0; }
.tnp-label { flex-shrink: 0; min-width: 40px; color: var(--text-label); white-space: nowrap; }
.tnp-list { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; list-style: none; margin: 0; padding: 0; }
.tnp-list > li { flex-shrink: 0; }   /* 手机横滑时选项不被压缩，文字保持横排 */
.tnp-item { display: block; white-space: nowrap; padding: 4px 12px; border-radius: var(--radius-sm); line-height: 20px; color: var(--text-2); transition: color 0.2s, background-color 0.2s; }
.tnp-item:hover { color: var(--accent-deep); background: var(--accent-light); }
.tnp-item.is-active { background: var(--accent); color: var(--on-accent); }

@media (max-width: 767px) {
  .section-hd { margin-bottom: 10px; }
  .section-title { font-size: 16px; }
  .section-title::before, .mh-tabs::before { height: 16px; }
  .section-more { font-size: 13px; }
  .sh-dayrank { display: none; }
  .mh-tabs { margin-bottom: 10px; }
  .mh-tab { font-size: 16px; }
  .mh-line { margin: 0 8px; }
  .type-nav-panel { padding: 4px 12px; font-size: 13px; }
  .tnp-list { flex: 1; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .tnp-list::-webkit-scrollbar { display: none; }
}

/* ==========================================
   VOD Grid — 一般清单页：多栏自动换行
   ========================================== */
.vod-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 20px 16px;
}

/* 首页／分类模块专用：固定六栏 */
.vod-row--fixed { grid-template-columns: repeat(6, minmax(0, 1fr)); }

/* ==========================================
   VOD Card — 仿 dmhyy.com：5:7 圆角 8 海报，右上角深色状态胶囊显示备注（更新状态），
   片名靠左于下方 14px＋别名；hover 海报暖色投影上浮＋片名变主色（不放播放 icon）
   ========================================== */
.vod-card { position: relative; min-width: 0; }
.vod-card > a { display: block; }

.vod-thumb {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 5/7;
  background: var(--bg-tertiary);
  transition: box-shadow 0.2s, transform 0.2s;
}
.vod-thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
@media (hover: hover) and (min-width: 1025px) {
  .vod-card:hover .vod-thumb { box-shadow: var(--shadow-card-hover); transform: translateY(-3px); }
}

/* ===== 影視卡網格（單一來源，skill 強制 11.9／11.10）：
   一行 6 列（≤1199px 4 列、≤600px 3 列）；想改單頁列數只加修飾類，不動 base 規則。 ===== */
.vod-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 20px 16px;
  margin-bottom: var(--section-gap);
}
@media (max-width: 1199px) {
  .vod-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .vod-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 10px; }
}

/* 详情页「关联系列」：收起时每个断点只留一行（6/4/3 列），detail.js 判断有被收起的项才显示按钮 */
.rel-series-grid { margin-bottom: 0; }
.rel-series-grid.is-collapsed > li:nth-child(n+7) { display: none; }
@media (max-width: 1199px) { .rel-series-grid.is-collapsed > li:nth-child(n+5) { display: none; } }
@media (max-width: 600px)  { .rel-series-grid.is-collapsed > li:nth-child(n+4) { display: none; } }
.rel-toggle { display: inline-flex; align-items: center; gap: 4px; margin-top: 12px; padding: 6px 14px; font-size: 13px; color: var(--text-2); background: none; border: 1px solid var(--border-2); border-radius: var(--radius-pill); cursor: pointer; transition: color .2s, border-color .2s; }
.rel-toggle[hidden] { display: none; }
.rel-toggle:hover { color: var(--accent-deep); border-color: var(--accent); }

/* 影視卡 hover 不放播放 icon（decisions.md 全局：影視卡 hover 弹层不要播放 icon） */

/* ===== hover 彈出詳情卡（skill 強制15）：寬度 170% 跨出欄寬，置中展開；
   靠視窗邊緣時由 vod_card.js 加 .pop-left／.pop-right 改為貼齊左／右緣，避免被裁切；移動端隱藏 ===== */
.vod-card:hover { z-index: 30; }
.vod-pop {
  position: absolute;
  top: -10px;
  left: 50%;
  width: 170%;
  transform: translateX(-50%);
  transform-origin: center top;
  z-index: 30;
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: 0 18px 44px rgba(26, 26, 46, 0.2);
  overflow: hidden;
  /* 未 hover 時 display:none（對照 tp30 .hover-popout）：絕對定位的 170% 寬浮層若只用 opacity/visibility 隱藏，
     仍會計入 scrollWidth，最右一列卡片會撐出橫向捲軸（decisions.md tp16 已記錄此坑）。
     display 無法 transition，淡入改用 @keyframes（0.15s hover 意圖延遲 + 0.2s 淡入縮放）；
     縮放用獨立的 scale 屬性，transform 只管定位，pop-left／pop-right 翻轉不必各寫一套動畫。 */
  display: none;
}
/* 只在真正支持悬停、且宽度 ≥768px 的设备打开浮层：触屏点击会触发 :hover，
   若不加限定，:hover 规则的优先级会盖过下方移动端的 display:none（强制 15「移动端隐藏」） */
@media (hover: hover) and (min-width: 768px) {
  .vod-card:hover .vod-pop {
    display: block;
    animation: vodPopIn 0.2s ease 0.15s both;
  }
}
@keyframes vodPopIn {
  from { opacity: 0; scale: 0.94; }
  to   { opacity: 1; scale: 1; }
}
.vod-card.pop-left .vod-pop { left: 0; transform: none; transform-origin: left top; }
.vod-card.pop-right .vod-pop { left: auto; right: 0; transform: none; transform-origin: right top; }
.vod-pop-thumb {
  position: relative;
  display: block;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--bg-tertiary);
}
.vod-pop-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.vod-pop-body { padding: 12px 14px 14px; }
.vod-pop-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-1);
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.vod-pop-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 8px; font-size: 11px; }
.vem-tag { color: var(--text-2); background: var(--bg-elevated); border-radius: 4px; padding: 1px 6px; }
.vem-tag--accent { color: var(--accent-deep); background: var(--accent-light); }
.vem-score { display: inline-flex; align-items: center; gap: 3px; color: var(--score-hi); font-weight: 700; }
.vem-score .mac-icon { font-size: 11px; }

.vod-pop-genres { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.veg-tag { font-size: 11px; color: var(--accent-deep); border: 1px solid var(--accent); border-radius: var(--radius-pill); padding: 0 8px; }
.vod-pop-people {
  margin-top: 6px;
  font-size: 12px;
  color: var(--text-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.vod-pop-people span { color: var(--text-3); }
.vod-pop-desc {
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (max-width: 767px) {
  .vod-pop { display: none; }
}

/* 海报右上角状态胶囊（外观仿 dmhyy.com：深褐 78% 底＋浅色细描边、白字 11px、单行省略） */
.vod-note {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 1;
  max-width: calc(100% - 12px);
  padding: 1px 6px;
  border: 1px solid var(--media-status-line);
  border-radius: var(--radius-sm);
  background: var(--media-status);
  color: var(--on-accent);
  font-size: 11px;
  line-height: 18px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}

.vod-name {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text-1);
  transition: color 0.2s;
}
.vod-card:hover .vod-name { color: var(--accent-deep); }
/* 片名下方别名（vod_sub）：12px 灰字、单行省略 */
.vod-sub {
  margin-top: 1px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 767px) {
  .vod-name { font-size: 13px; margin-top: 6px; }
  .vod-sub { font-size: 11px; }
  .vod-note { top: 4px; right: 4px; font-size: 10px; padding: 0 4px; }
}

/* ==========================================
   登入／註冊表單（user/login、user/reg、widget/login_form 共用）
   ========================================== */
.modal-box {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: 14px;
  padding: 32px 28px 28px;
  width: 340px;
  max-width: calc(100vw - 32px);
  position: relative;
  box-shadow: 0 20px 60px rgba(26, 26, 46, 0.14);
}
.modal-title { font-size: 18px; font-weight: 700; margin-bottom: var(--pad-box); }
.modal-field { margin-bottom: 16px; }
.modal-label { display: block; font-size: 12px; color: var(--text-2); margin-bottom: 6px; }
.modal-input {
  width: 100%;
  padding: 10px 13px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-1);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}
.modal-input:focus { border-color: var(--accent); }
.modal-submit {
  width: 100%;
  padding: 13px;
  background: var(--accent);
  color: #fff;
  border-radius: var(--radius-pill);
  font-size: 14px;
  font-weight: 700;
  transition: background 0.2s;
  margin-top: 6px;
}
.modal-submit:hover { background: var(--accent-hover); }
.modal-footer {
  margin-top: 16px;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-3);
}
.modal-link { color: var(--text-2); transition: color 0.2s; }
.modal-link:hover { color: var(--accent-deep); }
.modal-link--accent { color: var(--accent-deep); }

/* ==========================================
   History Modal
   ========================================== */
.hm-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(26, 26, 46, 0.45);
  z-index: 9000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.hm-overlay.is-open { display: flex; }

.hm-box {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: 12px;
  width: 100%;
  max-width: 700px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(26, 26, 46, 0.14);
}
.hm-header {
  display: flex;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.hm-title {
  flex: 1;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
}
.hm-clear {
  font-size: 13px;
  color: var(--text-3);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
  transition: color 0.15s;
}
.hm-clear:hover { color: var(--accent-deep); }
.hm-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px; height: 26px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50%;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-3);
  transition: background 0.15s, color 0.15s;
}
.hm-close:hover { background: var(--border); color: var(--text-1); }
.hm-body {
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-content: flex-start;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.hm-body::-webkit-scrollbar { width: 4px; }
.hm-body::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
.hm-card {
  flex: 0 0 calc((100% - 50px) / 6);
  min-width: 0;
  display: block;
  text-decoration: none;
  color: var(--text-1);
  align-self: flex-start;
}
.hm-thumb {
  position: relative;
  aspect-ratio: 2/3;
  border-radius: 6px;
  overflow: hidden;
  background: var(--bg-card);
  contain: strict;
}
.hm-thumb img {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.2s;
}
.hm-card:hover .hm-thumb img { transform: scale(1.04); }
.hm-card:hover .hm-name { color: var(--accent-deep); }
.hm-name {
  margin-top: 5px;
  font-size: 11px;
  color: var(--text-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.15s;
}
.hm-empty {
  width: 100%;
  text-align: center;
  padding: 40px 0;
  color: var(--text-3);
  font-size: 13px;
}

/* ==========================================
   Footer — 仿 dmhyy.com 简洁页脚：上方 1px 分隔线，内容置中（网站地图＋免责声明／ICP／版权，12px 灰褐字）
   ========================================== */
.site-footer {
  margin-top: 0;   /* 与上方区块的间距由区块自身 margin-bottom（--section-gap）提供（强制 20） */
  color: var(--text-1);
  font-size: 12px;
  line-height: 1.6;
}
.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--page-pad);
}
.footer-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 28px 0 32px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.footer-info { min-width: 0; }
.footer-note { font-size: 12px; color: var(--text-foot); line-height: 1.6; margin-top: 3px; }
.footer-links.footer-links--site { justify-content: center; gap: 8px 24px; margin-bottom: 4px; }
/* 修饰类提高优先级，避免被下方同优先级的 .footer-links a 覆盖（强制 11.8） */
.footer-links.footer-links--site a { font-size: 13px; color: var(--text-2); }

/* 友情链接列（首页使用：白底圆角卡片，「友情链接」灰字标签＋链接 14px 横排） */
.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 20px;
}
.footer-links a { font-size: 14px; color: var(--text-2); transition: color 0.2s; }
.footer-links a:hover { color: var(--accent-deep); }
.fl-label { font-size: 14px; font-weight: 700; color: var(--text-strong); }
.friend-links-row { padding: 14px 16px; border-radius: var(--radius); background: var(--bg-card); box-shadow: var(--shadow-sm); }

@media (max-width: 767px) {
  .footer-main { padding: 20px 0; }
  .friend-links-row { padding: 12px; gap: 8px 14px; }
}

/* ==========================================
   漂浮功能按鈕 (FAB)
   ========================================== */
.fab-group {
  position: fixed;
  bottom: 30px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 400;
}
.fab-btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  cursor: pointer;
  box-shadow: var(--shadow-accent);
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s, opacity 0.25s;
}
.fab-btn:hover {
  background: var(--accent-hover);
  transform: translateY(-3px) scale(1.08);
  box-shadow: var(--shadow-accent-hover);
}
.fab-btn--top { opacity: 0; pointer-events: none; }
.fab-btn--top.is-visible { opacity: 1; pointer-events: auto; }
.fab-qr-popup {
  position: fixed;
  bottom: 160px;
  right: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 14px;
  text-align: center;
  box-shadow: 0 8px 32px rgba(26, 26, 46, 0.14);
  z-index: 401;
  display: none;
}
.fab-qr-popup.is-open { display: block; }
.fab-qr-popup figcaption { font-size: 12px; color: var(--text-2); margin-bottom: 10px; }
.fab-qr-popup img { width: 130px; height: 130px; border-radius: 4px; background: #fff; display: block; }

/* ==========================================
   Comments (shared)
   ========================================== */

.gbook-count { font-size: 13px; font-weight: 400; color: var(--text-3); margin-left: 6px; }

/* ==========================================
   Rank Widgets — 排行卡（tp37 沿用、tp45 换暖粉配色）：白底圆角 8＋多层柔和阴影，
   标题 18px 置中、下方 5px 黑色短条；名次 Impact 24px 灰字，前三名红/橙/黄，行与行之间 1px 极浅分隔线
   ========================================== */
.rank-col {
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow-paper);
  overflow: hidden;
  min-width: 0;
}
.rank-col-hd {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; border-bottom: 1px solid var(--bg-soft);
}
.rank-col-title { position: relative; padding: 20px 15px 25px; text-align: center; font-size: 18px; font-weight: 700; color: var(--text-1); }
.rank-col > .rank-col-title::after { content: ""; position: absolute; left: 40%; bottom: 13px; width: 20%; height: 5px; border-radius: 50px; background: var(--text-strong); }
.rch-badge { font-size: 11px; font-weight: 400; padding: 1px 6px; border-radius: var(--radius-sm); background: var(--accent-light); color: var(--accent-deep); margin-left: 6px; vertical-align: 2px; }
.rank-col-more { font-size: 12px; color: var(--text-3); }
.rank-col-more:hover { color: var(--accent-deep); }
.rank-top1 { margin: 0 10px; padding: 10px 0; }
.rank-top1 a { display: flex; gap: 10px; }
.rt1-thumb {
  position: relative; flex-shrink: 0;
  width: 56px; height: 78px;
  border-radius: var(--radius-sm); overflow: hidden; background: var(--bg-tertiary);
}
.rt1-thumb img { width: 100%; height: 100%; object-fit: cover; }
.rt1-crown { position: absolute; top: 3px; left: 3px; color: var(--rank-3); font-size: 13px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.5)); }
.rt1-info { flex: 1; min-width: 0; }
.rt1-name { font-size: 14px; font-weight: 700; color: var(--text-1); margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-top1 a:hover .rt1-name { color: var(--accent-deep); }
.rt1-meta { font-size: 12px; color: var(--text-3); margin-bottom: 3px; }
.rt1-status { font-size: 12px; color: var(--text-3); margin-bottom: 5px; }
.rt1-hits { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; color: var(--rank-1); }
.rank-list { list-style: none; padding: 0 0 6px; }
.rank-li { border-top: 1px solid var(--bg-soft); margin: 0 10px; transition: margin 0.15s; }
.rank-li-inner {
  display: flex; align-items: center; gap: 8px;
  min-height: 45px; padding: 10px 0; font-size: 14px; color: var(--text-1); transition: background 0.15s, padding 0.15s;
}
.rank-li:hover { margin: 0; }
.rank-li:hover .rank-li-inner { padding: 10px; background: var(--bg-base); }
.rank-li-inner:hover .rl-name { color: var(--accent-deep); }
.rl-num {
  flex-shrink: 0; width: 40px;
  font-family: var(--font-impact); font-size: 22px; font-weight: 700; line-height: 1;
  text-align: center; color: var(--rank-num);
}
.rl-name { flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; transition: color 0.15s; }
.rl-hits { flex-shrink: 0; font-size: 12px; color: var(--text-3); display: flex; align-items: center; gap: 2px; }

/* ==========================================
   Art Card (文章資訊 — 橫向清單卡)
   ========================================== */
/* 文章／專題卡網格用 ul>li（skill 強制 2.3）；li 內的卡片撐滿等高 */
.art-card-item, .topic-card-item { display: flex; min-width: 0; }
.art-card-item > .art-card, .topic-card-item > .topic-card { flex: 1; min-width: 0; }
.art-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px 28px; }
@media (max-width: 1199px) { .art-grid { grid-template-columns: 1fr; } }
.art-card {
  position: relative;
  display: flex; align-items: flex-start; gap: 14px;
  color: var(--text-1);
}
.art-card-thumb {
  position: relative; flex: 0 0 150px; width: 150px; aspect-ratio: 4/3;
  overflow: hidden; border-radius: var(--radius-sm); background: var(--bg-elevated);
}
.art-card-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.art-card:hover .art-card-thumb img { transform: scale(1.05); }
.art-card-nopic { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 30px; color: var(--text-3); }

.art-card-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.art-card-title {
  font-size: 15px; font-weight: 700; color: var(--text-1); line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; transition: color 0.2s;
}
.art-card:hover .art-card-title { color: var(--accent-deep); }
.art-card-desc {
  font-size: 12.5px; color: var(--text-3); line-height: 1.7;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ==========================================
   首頁排行榜三欄（index.html .rank-home-grid）
   ========================================== */
.rank-home-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 23px 18px; }

/* ==========================================
   Topic Card
   ========================================== */
.topic-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.topic-card {
  display: flex; flex-direction: column;
  background: var(--bg-card); border: none; border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden; transition: transform 0.25s, box-shadow 0.25s; color: var(--text-1);
}
.topic-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.topic-card-thumb { position: relative; aspect-ratio: 16/9; overflow: hidden; background: var(--bg-elevated); }
.topic-card-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.topic-card:hover .topic-card-thumb img { transform: scale(1.04); }
.topic-card-count { position: absolute; bottom: 8px; right: 8px; padding: 2px 8px; background: rgba(0,0,0,0.65); color: #fff; font-size: 11px; border-radius: 3px; }
.topic-card-body { padding: 12px 14px; flex: 1; display: flex; flex-direction: column; gap: 4px; }
.topic-card-title { font-size: 14px; font-weight: 600; color: var(--text-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color 0.2s; }
.topic-card:hover .topic-card-title { color: var(--accent-deep); }
.topic-card-blurb { font-size: 12px; color: var(--text-3); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ==========================================
   Mobile Tabbar — 仿 dmhyy.com：暖白毛玻璃底栏，选中为主色图示＋文字
   ========================================== */
.mobile-tabbar {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0;
  height: 56px; background: var(--bg-topbar);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  z-index: 300; flex-direction: row;
}
.mtb-item {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 2px; height: 100%;
  color: var(--text-2); font-size: 10px;
  text-decoration: none; position: relative; transition: color 0.2s;
}
.mtb-item .mac-icon { font-size: 22px; transition: transform 0.2s; }

.mtb-item.is-active { color: var(--accent); }
.mtb-item.is-active .mac-icon { transform: scale(1.1); }

/* ==========================================
   Pagination
   ========================================== */
.pagination { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; padding: 28px 0 10px; }
.pg-btn, .pg-num {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px; padding: 0 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-2);
  background: var(--bg-card); color: var(--text-2); font-size: 13px; transition: all 0.2s;
}
.pg-btn:hover, .pg-num:hover { color: var(--accent-deep); border-color: var(--accent); }
.pg-num.is-active { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 700; }
.pg-info { font-size: 12px; color: var(--text-3); margin-left: 8px; }

/* ==========================================
   Download page
   ========================================== */

/* 详情页剧情收起样式只在 vod_detail.css 的 #detailDesc.desc-collapsed 定义一份（强制 11.9；原通用 .desc-collapsed/.desc-expanded 已无引用） */

/* ==========================================
   Ad Slots
   ========================================== */

/* 實測站內促銷橫幅為金色系（呼應「立即訂閱」按鈕漸層），與導覽/卡片的珊瑚粉主色區隔開來 */
.site-ad { border-radius: var(--radius); border: 1px solid var(--gold-line); background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-elevated) 100%); overflow: hidden; position: relative; }
.site-ad::before { content: ''; position: absolute; top: 0; left: 0; width: 3px; height: 100%; background: var(--gold-grad); border-radius: var(--radius) 0 0 var(--radius); }
.site-ad--banner { display: flex; align-items: center; gap: 12px; padding: 8px 14px 8px 18px; font-size: 12px; color: var(--text-2); flex: 1; }
.site-ad-left { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; }
.site-ad-icon { font-size: 18px; flex-shrink: 0; color: var(--gold); }
.site-ad-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.site-ad-text strong { font-size: 13px; color: var(--text-1); }
.site-ad-text span { font-size: 11px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.site-ad--sidebar { display: flex; align-items: center; gap: 12px; padding: 12px 14px 12px 18px; text-align: left; }
.site-ad--sidebar .site-ad-body { flex: 1; min-width: 0; }
.site-ad-label { display: inline-block; font-size: 9px; color: var(--gold); margin-bottom: 3px; letter-spacing: 1px; text-transform: uppercase; }
.site-ad-title { font-size: 13px; font-weight: 700; color: var(--text-1); margin-bottom: 2px; }
.site-ad-desc { font-size: 11px; color: var(--text-3); line-height: 1.5; }
.site-ad-btn { display: inline-flex; align-items: center; flex-shrink: 0; padding: 6px 14px; background: var(--gold-grad); color: #fff; border-radius: var(--radius-sm); font-size: 12px; font-weight: 600; white-space: nowrap; transition: filter 0.2s; }
.site-ad-btn:hover { filter: brightness(1.1); }

/* ==========================================
   MAC.Pop 彈出層覆寫
   ========================================== */
.mac_pop_bg { background: rgba(26,26,46,0.45) !important; backdrop-filter: blur(4px); }
.mac_pop { background: var(--bg-card) !important; border: 1px solid var(--border) !important; border-radius: var(--radius) !important; box-shadow: 0 24px 64px rgba(26, 26, 46, 0.14) !important; padding: 0 !important; display: flex !important; flex-direction: column !important; overflow: hidden !important; }
.mac_pop .pop_top { display: flex !important; align-items: center !important; justify-content: space-between !important; height: auto !important; padding: 14px 16px !important; background: var(--bg-elevated) !important; border-bottom: 1px solid var(--border) !important; flex-shrink: 0 !important; }
.mac_pop .pop_top h2 { font-size: 15px !important; font-weight: 600 !important; color: var(--text-1) !important; margin: 0 !important; line-height: 1 !important; float: none !important; }
.mac_pop span.pop_close { float: none !important; width: 28px !important; height: 28px !important; font-size: 16px !important; text-indent: 0 !important; background: none !important; display: inline-flex !important; align-items: center !important; justify-content: center !important; border-radius: 50% !important; color: var(--text-3) !important; cursor: pointer !important; transition: color 0.2s, background 0.2s !important; line-height: 1 !important; }
.mac_pop span.pop_close:hover { color: var(--text-1) !important; background: var(--bg-base) !important; }
.mac_pop .pop_content { flex: 1 !important; overflow-y: auto !important; scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
.mac_pop_msg_bg { background: rgba(26,26,46,0.15) !important; }
.mac_pop_msg { background: var(--bg-elevated) !important; border: 1px solid var(--border) !important; border-radius: var(--radius-sm) !important; box-shadow: 0 4px 24px rgba(26, 26, 46, 0.14) !important; padding: 10px 20px !important; }
.mac_pop_msg .pop-msg { color: var(--text-1) !important; font-size: 13px !important; }

/* ==========================================
   Responsive
   ========================================== */
@media (max-width: 1199px) {
  .mobile-tabbar { display: flex; }
  .main-area { padding-bottom: 56px; }
}
@media (max-width: 1023px) {
  .rank-home-grid { grid-template-columns: repeat(3, 1fr); }
  .topic-grid     { grid-template-columns: repeat(3, 1fr); }
  .vod-row--fixed { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .site-ad--banner .site-ad-text span { display: none; }
  .fab-group { bottom: 76px; right: 14px; }
  .fab-qr-popup { bottom: 146px; right: 14px; }
  .fab-btn--qr { display: none; }
}

@media (max-width: 767px) {
  /* .content-block 间距、.mobile-tabbar 显示、.main-area 底部留白已由基础规则与 ≤1199px 规则覆盖，不在此重复（强制 11.9） */
  .vod-row { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 10px; }
  .art-grid       { grid-template-columns: 1fr; gap: 16px; }
  .art-card-thumb { flex-basis: 110px; width: 110px; }
  .art-card-title { font-size: 14px; }
  .topic-grid     { grid-template-columns: repeat(2, 1fr); }
  .rank-home-grid { grid-template-columns: 1fr; }
  .hm-overlay { padding: 16px; }
  .hm-box { max-height: 85vh; }
  .hm-card { flex: 0 0 calc((100% - 20px) / 3); }
}

/* ==========================================
   Section Lazy Reveal (Intersection Observer)
   ========================================== */
.content-block.will-observe {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.content-block.is-visible {
  opacity: 1;
  transform: none;
}

/* ===== Breadcrumb 面包屑（widget/breadcrumb：nav>ol>li，全站唯一来源；强制 3.2 / 11.9）
   基础版用于内容栏内；--wide 版用于整宽页（左右 gutter 与 .content-block 对齐）；深色底版由各页覆盖颜色 ===== */
.breadcrumb { font-size: 13px; color: var(--text-3); margin-bottom: var(--section-gap); }
.breadcrumb ol { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; list-style: none; margin: 0; padding: 0; }
.breadcrumb li { display: inline-flex; align-items: center; min-width: 0; }
.breadcrumb a { color: var(--text-3); }
.breadcrumb a:hover { color: var(--accent-deep); }
.breadcrumb .bc-sep { display: inline-flex; margin: 0 4px; color: var(--text-3); }
.breadcrumb .bc-current { color: var(--text-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 60vw; }
.breadcrumb--wide { max-width: var(--container); margin: 16px auto var(--section-gap); padding: 0 var(--page-pad); }
@media (max-width: 767px) {
  .breadcrumb--wide { margin: 10px 0 var(--section-gap); }
}

/* 排行榜名次配色（label-rank 強制 6.1：用 :nth-child，不在模板內 if／elseif 判斷）。
   第 1 名由 widget/rank_top（皇冠）呈現，.rank-list 從第 2 名起（start="2"），
   所以 li:nth-child(1)＝第 2 名（橙）、nth-child(2)＝第 3 名（黃），第 4 名起維持預設灰。 */
.rank-list > li:nth-child(1) .rl-num { color: var(--rank-2); }
.rank-list > li:nth-child(2) .rl-num { color: var(--rank-3); }
/* 資訊側欄「熱播影視」（widget/art_hot_vod，art/type 與 art/detail 共用 → 樣式集中在 main.css，原 art_type.css） */
.art-hot-list { padding: 8px 0; }
.art-hot-list li a {
    display: flex; align-items: center; gap: 10px;
    padding: 8px 16px; font-size: 13px; color: var(--text-2);
    transition: color 0.2s;
}
.art-hot-list li a:hover { color: var(--accent-deep); }
.ahl-num {
    flex-shrink: 0; width: 20px; height: 20px;
    border-radius: 3px; background: var(--bg-elevated);
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700; color: var(--text-3);
}
.ahl-name { flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
/* 資訊側欄「熱播影視」前三名配色（art-type 強制 6.1：用 :nth-child，不在模板內 if／elseif；tp45 改用排行三色 token，與全站一致） */
.art-hot-list > li:nth-child(-n+3) .ahl-num { color: var(--on-accent); }
.art-hot-list > li:nth-child(1) .ahl-num { background: var(--rank-1); }
.art-hot-list > li:nth-child(2) .ahl-num { background: var(--rank-2); }
.art-hot-list > li:nth-child(3) .ahl-num { background: var(--rank-3); }

/* ===== 排行榜頁 label/rank 專屬變體（原 label_rank.css，限定 .rank-wrap 內；強制 11.9 同名 class 只在 main.css 定義） ===== */
.rank-wrap .rank-col { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.rank-wrap .rank-col-hd { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.rank-wrap .rank-col-title { padding: 12px; font-size: 14px; font-weight: 700; color: var(--text-1); }
.rank-wrap .rank-col-more { font-size: 12px; color: var(--text-3); transition: color .15s; }
.rank-wrap .rank-col-more:hover { color: var(--accent-deep); }
.rank-wrap .rank-top1 { margin: 0; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.rank-wrap .rank-top1 > a { display: flex; gap: 12px; align-items: flex-start; text-decoration: none; }
.rank-wrap .rt1-thumb { position: relative; width: 64px; flex-shrink: 0; border-radius: var(--radius-sm); overflow: hidden; }
.rank-wrap .rt1-thumb img { width: 100%; aspect-ratio: 2/3; object-fit: cover; display: block; }
.rank-wrap .rt1-crown { position: absolute; top: 4px; left: 4px; font-size: 16px; color: var(--score-hi); line-height: 1; filter: drop-shadow(0 1px 2px rgba(0,0,0,.5)); }
.rank-wrap .rt1-info { flex: 1; min-width: 0; }
.rank-wrap .rt1-name { font-size: 14px; font-weight: 600; color: var(--text-1); margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .15s; }
.rank-wrap .rank-top1 > a:hover .rt1-name { color: var(--accent-deep); }
.rank-wrap .rt1-meta { font-size: 12px; color: var(--text-3); margin-bottom: 4px; }
.rank-wrap .rt1-status { font-size: 12px; color: var(--score-mid); }
.rank-wrap .rt1-hits { display: flex; align-items: center; gap: 4px; font-size: 12px; color: var(--accent-deep); margin-top: 6px; }
.rank-wrap .rank-list { list-style: none; padding: 4px 0; margin: 0; }
.rank-wrap .rank-li, .rank-wrap .rank-li:hover { margin: 0; border-top: 0; border-bottom: 1px solid var(--border); }
.rank-wrap .rank-li:last-child { border-bottom: none; }
.rank-wrap .rank-li-inner { display: flex; align-items: center; gap: 10px; padding: 9px 16px; text-decoration: none; transition: background .15s; }
.rank-wrap .rank-li-inner:hover, .rank-wrap .rank-li:hover .rank-li-inner { padding: 9px 16px; background: var(--accent-light); }
.rank-wrap .rank-li-inner:hover .rl-name { color: var(--accent-deep); }
.rank-wrap .rl-num { font-family: inherit; line-height: 1; width: 22px; height: 22px; border-radius: 4px; background: var(--bg-elevated); color: var(--text-3); font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.rank-wrap .rl-name { flex: 1; font-size: 13px; color: var(--text-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .15s; }
.rank-wrap .rl-hits { font-size: 11px; color: var(--text-3); flex-shrink: 0; display: flex; align-items: center; gap: 2px; }

/* ===== 登入／註冊／跳轉頁專屬變體（原 jump.css，限定 .jump-main 內） ===== */
.jump-main .modal-field { display: flex; flex-direction: column; gap: 6px; }
.jump-main .modal-label { font-size: 12px; color: var(--text-2); font-weight: 500; }
.jump-main .modal-input { height: 40px; padding: 0 12px; background: var(--bg-elevated); border: 1px solid var(--border-2); border-radius: var(--radius-sm); color: var(--text-1); font-size: 14px; outline: none; transition: border-color .15s; }
.jump-main .modal-input:focus { border-color: var(--accent); }
.jump-main .modal-submit { height: 42px; background: var(--accent); color: #fff; font-size: 15px; font-weight: 600; border: none; border-radius: var(--radius-sm); cursor: pointer; transition: background .15s; }
.jump-main .modal-submit:hover { background: var(--accent-hover); }
.jump-main .modal-footer { font-size: 13px; color: var(--text-3); text-align: center; margin-top: 8px; }
.jump-main .modal-link--accent { color: var(--accent-deep); text-decoration: none; }
.jump-main .modal-link--accent:hover { text-decoration: underline; }

/* ===== 文章詳情頁關聯影視卡片列（原 art_detail.css 的 .vod-row，限定 .art-layout 內；強制 11.9） ===== */
.art-layout .vod-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }   /* 中栏固定 3 列（3 的倍数，decisions tp06：art_rel_vod 6 条＝2 行） */
@media (max-width: 768px) { .art-layout .vod-row { gap: 10px; } }

/* ==========================================
   共用元件樣式（原散落在 vod_detail／art_detail／actor／vod_show 等頁面 css 的重複定義，
   依 skill 強制 11.9 合併為單一來源；以 vod_detail 版本為準）
   ========================================== */
/* ---------- actor grid ---------- */
.actor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 16px;
    margin-bottom: var(--section-gap);
}
.actor-card { display: block; }
@media (max-width: 768px) { .actor-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; } }   /* 原在 vod_show.css，收口单一来源（强制 11.9） */
.ac-thumb {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    aspect-ratio: 2/3;
    background: var(--bg-elevated);
}
.ac-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.actor-card:hover .ac-thumb img { transform: scale(1.05); }
.ac-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 48px; color: var(--text-3);
}
.ac-score {
    position: absolute; bottom: 6px; right: 6px;
    background: var(--gold); color: var(--text-1);
    font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 3px;
}
.ac-info { padding: 6px 2px 0; }
.ac-name {
    font-size: 13px; color: var(--text-1); font-weight: 500;
    overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}
.ac-meta { font-size: 11px; color: var(--text-3); margin-top: 2px; }
.art-layout {
    max-width: var(--container); margin: 0 auto;
    display: grid;
    grid-template-columns: 200px 1fr 240px;
    gap: 20px;
    padding: 20px var(--page-pad) 40px;
    align-items: start;
}
.art-layout > * { min-width: 0; }   /* grid 子项显式 min-width:0，长标题/长 URL 不撑爆中栏（强制 11.8） */
/* ---------- left nav (shared) ---------- */
.art-leftnav {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); overflow: hidden;
    position: sticky; top: calc(var(--topbar-h) + 12px);
}
.aln-item {
    display: flex; align-items: center; gap: 8px;
    padding: 10px 16px; font-size: 14px; color: var(--text-2);
    border-bottom: 1px solid var(--border); transition: all 0.2s;
}
.aln-list { list-style: none; margin: 0; padding: 0; }   /* 资讯左栏改 ul/li（强制 2.3） */
.aln-list > li:last-child .aln-item { border-bottom: none; }
.aln-item:hover { color: var(--text-1); background: var(--bg-elevated); }
/* ---------- sidebar ---------- */
.art-sidebar { position: sticky; top: calc(var(--topbar-h) + 12px); }
.art-sb-block {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); overflow: hidden; margin-bottom: var(--section-gap);
}
.art-sb-title {
    display: flex; align-items: center; gap: 6px;
    font-size: 14px; font-weight: 600; color: var(--text-1);
    padding: 12px 16px; border-bottom: 1px solid var(--border);
}
.art-sb-read-list { padding: 8px 12px; }
.art-sb-item a { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.art-sb-item:last-child a { border-bottom: none; }
.asi-thumb { flex-shrink: 0; width: 64px; height: 42px; border-radius: 4px; overflow: hidden; background: var(--bg-elevated); }
.asi-thumb img { width: 100%; height: 100%; object-fit: cover; }
.asi-info { flex: 1; min-width: 0; }
.asi-title { font-size: 13px; color: var(--text-2); line-height: 1.4; margin-bottom: 4px; }
.art-sb-item a:hover .asi-title { color: var(--accent-deep); }
.asi-cat { font-size: 11px; color: var(--text-3); }
.detail-section {
  margin-bottom: var(--section-gap);
}
.detail-section-hd {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-pri);
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
/* ===== Comment Section ===== */
.cmt-total-label { font-size: 13px; font-weight: 400; color: var(--text-muted); margin-left: 6px; }
.cmt-total-label em { color: var(--accent-deep); font-style: normal; }
.cmt-form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: var(--section-gap);
}
.cmt-textarea {
  display: block;
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-pri);
  font-size: 13px;
  font-family: inherit;
  resize: vertical;
  min-height: 80px;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s;
}
.cmt-textarea:focus { border-color: var(--accent); }
.cmt-textarea::placeholder { color: var(--text-muted); }
.cmt-form-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.cmt-verify-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}
.cmt-verify-input {
  width: 90px;
  padding: 6px 10px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-pri);
  font-size: 12px;
  outline: none;
}
.cmt-captcha-img { height: 30px; border-radius: 3px; cursor: pointer; flex-shrink: 0; }
.cmt-form-right { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.cmt-remaining { font-size: 12px; color: var(--text-muted); white-space: nowrap; }
.cmt-remaining em { color: var(--accent-deep); font-style: normal; }
.cmt-submit-btn {
  padding: 7px 20px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.2s;
}
.cmt-submit-btn:hover { opacity: 0.85; }
.cmt-item {
  display: flex;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.cmt-item:last-child { border-bottom: none; }
.cmt-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-elevated);
  color: var(--text-sec);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  text-transform: uppercase;
}
.cmt-body { flex: 1; min-width: 0; }
.cmt-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.cmt-name { font-size: 13px; font-weight: 600; color: var(--text-pri); }
.cmt-time { font-size: 11px; color: var(--text-muted); }
.cmt-content { font-size: 13px; color: var(--text-sec); line-height: 1.6; margin: 0 0 6px; }
.cmt-child-item {
  margin-top: 8px;
  padding: 8px 12px;
  background: var(--bg-card);
  border-radius: var(--radius);
  border-left: 2px solid var(--border);
}
.cmt-child-name { font-size: 12px; font-weight: 600; color: var(--text-pri); margin-right: 6px; }
.cmt-actions { display: flex; gap: 12px; margin-top: 4px; }
.cmt-action-link {
  font-size: 12px;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}
.cmt-action-link:hover { color: var(--accent-deep); }
.cmt-empty {
  padding: 32px 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}
.cmt-loading {
  font-size: 13px;
  color: var(--text-muted);
  padding: var(--pad-box) 0;
  text-align: center;
}
.cmt-paging {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  padding: 16px 0 4px;
}
.cmt-page-btn {
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 13px;
  color: var(--text-sec);
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s;
}
.cmt-page-btn:hover { border-color: var(--accent); color: var(--accent-deep); }
/* tp35：原本即屬本頁的規則（曾被誤移至 main.css 後移回） */
.aln-item.is-active { color: var(--accent-deep); background: var(--accent-light); font-weight: 600; }
.aln-item .mac-icon { font-size: 16px; }
.cmt-page-btn.is-active { background: var(--accent); border-color: var(--accent); color: #fff; }
.cmt-page-btn.is-disabled { opacity: 0.4; cursor: default; pointer-events: none; }

/* 列表空態（vod/show、vod/type 共用；skill 強制 5.4／decisions.md 空態） */
.show-empty {
    padding: 60px 20px;
    text-align: center;
    color: var(--text-3);
}
.show-empty .mac-icon {
    font-size: 48px;
    display: block;
    margin: 0 auto 16px;
    color: var(--text-3);
}
.show-empty p { font-size: 15px; color: var(--text-2); margin-bottom: 6px; }
.show-empty .se-hint { font-size: 13px; color: var(--text-3); }

/* ===== 详情/播放/下载共用：播放列表 widget、分享弹窗（原在 vod_detail.css；播放页不再整份加载 vod_detail.css，强制 11.9） ===== */
.playlist-section {
  margin-bottom: var(--section-gap);
}
.share-modal { display: none; }
.share-modal.is-open { display: block; }
.share-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26,26,46,0.45);
  z-index: 1400;
}
.share-popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1401;
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: var(--pad-box);
  width: min(380px, 92vw);
  box-shadow: 0 16px 40px rgba(26,26,46,0.16);
}
.share-popup-close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--text-muted);
  cursor: pointer;
  line-height: 1;
}
.share-popup-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-pri);
  margin: 0 0 16px;
}
.share-popup-icons {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
}
.spi {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  text-decoration: none;
  color: var(--text-sec);
  font-size: 12px;
  cursor: pointer;
}
.spi-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--text-pri);
  border: 1px solid var(--border);
}
.share-popup-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin: 0 0 8px;
}
.share-popup-link {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  font-size: 12px;
  color: var(--text-sec);
  resize: none;
  height: 52px;
  box-sizing: border-box;
  display: block;
  margin-bottom: 10px;
}
.share-popup-copy {
  width: 100%;
  padding: 9px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.share-popup-copy:hover { opacity: 0.88; }
.playlist-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.playlist-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-pri);
}
.pl-sort-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 5px 12px;
  font-size: 13px;
  color: var(--text-sec);
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
.pl-sort-btn:hover { color: var(--accent-deep); border-color: var(--accent); }
.playlist-sources {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.pl-source-tab {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--text-sec);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.pl-source-tab.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.playlist-empty {
  padding: var(--pad-box);
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}
.playlist-panel { display: none; }
.playlist-panel.is-active { display: block; }
.playlist-notice {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 10px;
  padding: 7px 12px;
  background: var(--bg-card);
  border-radius: var(--radius);
}
.playlist-episodes {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0 0 4px;   /* 选集改 ul/li（强制 2.3） */
}
.playlist-episodes > li { display: flex; min-width: 0; max-width: 100%; }
.playlist-episodes.episodes-collapsed {
  max-height: calc(2 * (32px + 6px));
  overflow: hidden;
}
.episode-btn {
  display: inline-block;
  max-width: 100%;          /* 超长集名换行显示，不裁切也不撑破容器（vod-detail 8.2 / vod-play 9.2） */
  overflow-wrap: anywhere;
  text-align: center;
  padding: 5px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 13px;
  color: var(--text-sec);
  text-decoration: none;
  white-space: normal;
  line-height: 1.5;
  transition: border-color 0.15s, color 0.15s;
}
.episode-btn:hover { border-color: var(--accent); color: var(--accent-deep); }
.episode-btn.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.episode-more-trigger {
  display: flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  margin: 8px 0 0 auto;
  padding: 5px 12px;
  border: 1px dashed var(--border);
  border-radius: 4px;
  font-size: 12px;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.episode-more-trigger:hover { color: var(--accent-deep); border-color: var(--accent); }
@media (max-width: 640px) {
  .playlist-sources {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    scroll-behavior: smooth;
  }
  .playlist-sources::-webkit-scrollbar { display: none; }
  .pl-source-tab {
    flex: 0 0 auto;
    white-space: nowrap;
    scroll-snap-align: start;
  }
}

/* ===== 评论区补充（原分散在 vod_detail.css / art_detail.css，收口单一来源，强制 11.9） ===== */
.cmt-verify-input:focus { border-color: var(--accent); }
.cmt-ajax-wrap { border: none; background: transparent; min-height: 60px; }
.cmt-child-item .cmt-time { font-size: 11px; color: var(--text-3); }
.cmt-child-item .cmt-content { margin-top: 4px; color: var(--text-2); }
@media (max-width: 640px) {
  .cmt-form-footer { flex-direction: column; align-items: stretch; }
  .cmt-form-right { margin-left: 0; justify-content: space-between; }
}

/* ===== 资讯页布局响应式（资讯分类 + 资讯详情共用，原两份页面 css 断点不一致，收口单一来源，强制 11.9） ===== */
@media (max-width: 1023px) {
  .art-layout { grid-template-columns: 140px 1fr; gap: 14px; padding: 16px 16px 60px; }
  .art-sidebar { display: none; }
}
@media (max-width: 767px) {
  .art-layout { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 10px 10px 80px; overflow-x: hidden; }
  .art-leftnav { position: static; border-radius: var(--radius); min-width: 0; width: 100%; }
  .aln-list { display: flex; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .aln-list::-webkit-scrollbar { display: none; }
  .aln-list > li { flex-shrink: 0; }
  .aln-item { border-bottom: none; border-right: 1px solid var(--border); padding: 9px 14px; font-size: 13px; white-space: nowrap; }
  .aln-list > li:last-child .aln-item { border-right: none; }
}

/* ===== 工具栏锚点（播放页 #playlist / #comment）避开吸顶 header ===== */
#playlist, .anchor-target { scroll-margin-top: calc(var(--topbar-h) + 12px); }

/* ===== 详情页 Hero（widget/detail_hero，vod/detail 与 vod/down 共用；原在 vod_detail.css，收口 main.css，强制 11.9） ===== */
.detail-wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--section-gap) var(--page-pad) 0;
}
.detail-hero {
  position: relative;
  width: 100%;
  overflow: hidden;
}
.detail-hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 20%;
  filter: blur(32px) brightness(1.1) saturate(1.15);
  transform: scale(1.15); /* 放大，避免模糊後邊緣露出銳利邊框 */
  z-index: 0;
}
.detail-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
      var(--detail-veil-top) 0%,
      var(--detail-veil-mid) 65%,
      var(--bg-base) 100%);
  z-index: 1;
}
.detail-wrap--hero {
  position: relative;
  z-index: 2;
  padding-top: 36px;
}
.detail-top {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  padding-bottom: var(--section-gap);
}
.detail-poster {
  flex-shrink: 0;
  width: 250px;
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(26,26,46,0.18);
}
.detail-poster img {
  width: 100%;
  display: block;
  aspect-ratio: 2/3;
  object-fit: cover;
}
.poster-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
}
.poster-score {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--score-mid);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}
.detail-info {
  flex: 1;
  min-width: 0;
  padding-top: 4px;
  /* 背景遮罩本輪調得很淺（見 .detail-hero-overlay），加一層文字陰影保底可讀性，
     沿用 §21.2 hero-badges/.hero-title-chip 已驗證過的作法，text-shadow 為
     可繼承屬性，掛在容器上即可讓標題／標籤／meta／簡介文字統一套用 */
  text-shadow: none; /* tp35 亮色主題：背景改為淺色霧面遮罩，深色文字不需陰影 */
}
.detail-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 4px;
}
.detail-title-row .detail-title { margin-bottom: 0; }
.detail-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-pri);
  margin: 0 0 4px;
  line-height: 1.3;
}
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.dtag {
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 12px;
  border: 1px solid var(--border);
  color: var(--text-sec);
  background: var(--bg-card);
}
.detail-meta {
  margin: 0 0 18px;
}
.dm-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 13px;
  padding: 5px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text-sec);
}
.dm-row:last-child { border-bottom: none; }
.dm-row dt {
  color: var(--text-muted);
  flex-shrink: 0;
  width: 38px;
  font-weight: 500;
}
.dm-row dd {
  margin: 0;
  flex: 1;
  min-width: 0;
}
.dm-row dd a {
  color: var(--text-sec);
  text-decoration: none;
  margin-right: 4px;
}
.dm-row dd a:hover { color: var(--accent-deep); }
.dm-actors {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dm-actors a { display: inline; }
.dm-row--combo {
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 6px;
}
.dm-row--combo dt { width: auto; }
.dm-row--combo dd { flex: 0 1 auto; }
.dm-row--combo dd + dt {
  margin-left: 14px;
  padding-left: 20px;
  border-left: 1px solid var(--border);
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}
.detail-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 20px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  border: none;
  transition: opacity 0.2s;
}
.detail-btn:hover { opacity: 0.85; }
.detail-btn--play {
  background: var(--accent);
  color: #fff;
}
.detail-btn--dl {
  background: var(--accent-light);
  border: 1px solid var(--accent);
  color: var(--accent-hover);
}
.detail-btn--share {
  background: var(--bg-elevated);
  border: 1px solid var(--border-2);
  color: var(--text-1);
}
.dm-status {
  display: inline-flex; align-items: center;
  padding: 1px 8px; margin-right: 6px;
  border-radius: 4px; font-size: 12px; font-weight: 600;
}
.dm-status--end { background: var(--status-end-light); color: var(--status-end); }
.dm-status--ing { background: var(--accent-light); color: var(--accent-deep); }
.dm-sep { margin: 0 4px; color: var(--text-3); }
@media (max-width: 640px) {
  .detail-hero-bg { filter: blur(18px) brightness(1.1) saturate(1.1); }
  .detail-top { flex-direction: column; align-items: center; }
  .detail-poster { width: 230px; }
  .detail-info { width: 100%; }
  .detail-wrap { padding: 16px var(--page-pad) 0; }
}