/* ============================================================
   MacCMS 2025 · Detail Page Enhancements
   HighlightReel · MoodMatch · SentimentCards · SmartEpisodeNav
   ============================================================ */

/* ── 1. HighlightReel 精华预览播放器 ── */
.highlight-reel {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  margin-bottom: clamp(16px, 2vw, 24px);
}
.highlight-reel__player {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
}
.highlight-reel__player video {
  width: 100%; height: 100%;
  object-fit: cover;
}
.highlight-reel__play-btn {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 56px; height: 56px;
  border-radius: 50%;
  background: rgba(232,168,56,0.9);
  border: none;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: transform var(--dur-normal) var(--ease-out),
              opacity var(--dur-normal) var(--ease-out);
  z-index: 2;
}
.highlight-reel__play-btn:hover {
  transform: translate(-50%, -50%) scale(1.1);
}
.highlight-reel__play-btn svg {
  width: 24px; height: 24px;
  fill: var(--bg-primary);
  margin-left: 4px;
}
.highlight-reel__label {
  padding: 10px 16px;
  font-size: var(--fs-c1);
  color: var(--text-secondary);
  background: var(--bg-card);
}
.highlight-reel__label strong {
  color: var(--gold);
  font-weight: var(--fw-semibold);
}
/* 降级: 剧照轮播 */
.highlight-reel--fallback {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 8px;
  padding: 12px;
}
.highlight-reel--fallback img {
  flex-shrink: 0;
  width: clamp(200px, 30vw, 320px);
  aspect-ratio: 16/9;
  object-fit: cover;
  border-radius: var(--radius-sm);
  scroll-snap-align: start;
}

/* ── 2. MoodMatch 情绪匹配度 ── */
.mood-match {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
}
.mood-match__ring {
  flex-shrink: 0;
  width: 40px; height: 40px;
}
.mood-match__ring circle {
  fill: none;
  stroke-width: 3;
  transform: rotate(-90deg);
  transform-origin: center;
}
.mood-match__ring-bg {
  stroke: var(--border);
}
.mood-match__ring-fill {
  stroke: var(--gold);
  transition: stroke-dashoffset 1s var(--ease-out);
}
.mood-match__text {
  font-size: var(--fs-c1);
  color: var(--text-secondary);
  line-height: 1.4;
}
.mood-match__percent {
  font-family: var(--serif);
  font-size: 1.2rem;
  color: var(--gold);
  font-weight: var(--fw-normal);
}
/* 未登录态 */
.mood-match--locked .mood-match__ring-fill {
  stroke: var(--text-tertiary);
}
.mood-match--locked .mood-match__percent {
  color: var(--text-tertiary);
}
/* 数据不足 */
.mood-match--insufficient .mood-match__ring-fill {
  stroke: var(--teal);
}

/* ── 3. SentimentCards 感受性评论 ── */
.sentiment-cards {
  display: flex;
  gap: clamp(8px, 1.2vw, 14px);
  margin-bottom: clamp(20px, 2.5vw, 32px);
}
.sentiment-card {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: clamp(14px, 2vw, 20px);
  cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease-out),
              background var(--dur-fast) var(--ease-out);
  position: relative;
}
.sentiment-card:hover {
  border-color: var(--border-em);
}
.sentiment-card__quote {
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  color: var(--gold);
  line-height: 0.8;
  margin-bottom: 8px;
  opacity: 0.6;
}
.sentiment-card__text {
  font-size: var(--fs-c1);
  color: var(--text-secondary);
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.sentiment-card__expanded {
  display: none;
  font-size: var(--fs-c1);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.sentiment-card__user {
  font-size: var(--fs-c2);
  color: var(--text-tertiary);
  margin-top: 6px;
}
/* 移动端竖向堆叠 */
@media (max-width: 767px) {
  .sentiment-cards {
    flex-direction: column;
  }
  .sentiment-card:nth-child(3) {
    display: none;
  }
}

/* ── 4. SmartEpisodeNav 智能剧集导航 ── */
.episode-progress {
  background: var(--bg-card);
  border: 1px solid var(--gold-glow);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.episode-progress__bar {
  flex: 1;
  height: 4px;
  background: var(--bg-surface);
  border-radius: 2px;
  overflow: hidden;
}
.episode-progress__fill {
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
  transition: width var(--dur-slow) var(--ease-out);
}
.episode-progress__text {
  font-size: var(--fs-c1);
  color: var(--text-secondary);
  white-space: nowrap;
}
.episode-progress__badge {
  padding: 3px 8px;
  background: var(--gold-glow);
  border-radius: var(--radius-sm);
  font-size: var(--fs-c2);
  color: var(--gold);
  font-weight: var(--fw-medium);
}
