/* 暗黑模式规则已迁入 dark-mode-unified.css（原 components/teacher_card.css） */
/**
 * 老师卡片组件样式 - 统一样式文件
 * 
 * 基于老师列表页（teacher_list.css）的标准样式
 * 支持多种卡片类型：Teacher（列表页）、voice-card（首页推荐）、discount-teacher-card（限时打折）
 */

/* --------------------------------------------------
   TVCBOOK discover 卡片参考：主色 ~#818cf8；标题/副文/弱文案分层清晰（避免副文过深发「糊」）
   （列表 .Teacher 与首页 .voice-card 共用）
   -------------------------------------------------- */
.Teacher,
.voice-card-inner,
.discount-teacher-inner {
  --tvcbook-font: "Alimama FangYuanTi VF", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "微软雅黑", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --tvcbook-title: #171717;
  --tvcbook-sub: #525252;
  --tvcbook-muted: #737373;
  --tvcbook-primary: #818cf8;
  --tvcbook-radius: 10px;
  /* 🎨 标签：中性灰 chip，干净不抢戏 */
  --tvcbook-secondary-bg: #fafafa;
  --tag-chip-bg: #fafafa;
  --tag-chip-border: #ebebeb;
  --tag-chip-text: #525252;
  --tag-chip-radius: 6px;
  --card-surface-border: var(--card-surface-outline, rgba(0, 0, 0, 0.1));
  --card-surface-border-hover: var(--card-surface-outline-hover, rgba(0, 0, 0, 0.18));
  --card-surface-shadow: var(--card-shadow-rest);
  --card-surface-shadow-hover: var(--card-shadow-hover-lift);
  --card-avatar-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  font-family: var(--tvcbook-font);
  font-variation-settings: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* 卡片内按钮色由 card_actions 根变量 + JS 统一控制，此处不再单独覆盖，避免与样音卡悬停色不一致 */

/* ========================================
   老师卡片组件 - 极简扁平设计
   ======================================== */

/* Bunny Studio 风格卡片（全站统一：列表页 / 首页等凡引入本组件处均生效） */
.Teacher {
  width: 100%;
  padding: 24px 20px 18px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--card-surface-panel, transparent);
  height: auto;
  border: 1px solid var(--card-surface-outline, rgba(0, 0, 0, 0.1));
  border-radius: var(--tvcbook-radius, 10px);
  box-shadow: var(--card-surface-shadow);
  transform: translateY(0);
  transition:
    transform var(--card-hover-duration, 0.22s) var(--card-hover-easing, cubic-bezier(0.25, 0.72, 0.38, 1)),
    box-shadow var(--card-hover-duration, 0.22s) var(--card-hover-easing, cubic-bezier(0.25, 0.72, 0.38, 1)),
    border-color var(--card-hover-duration, 0.22s) ease;
  position: relative;
  /* 勿用 contain:layout+style：部分内核下易与 box-shadow 叠出「底边被裁平」 */
  overflow: visible;
}

@media (hover: hover) and (pointer: fine) {
  .Teacher:hover {
    z-index: 2;
    border-color: var(--card-surface-outline-hover, rgba(0, 0, 0, 0.18));
    background: var(--card-surface-panel-hover, transparent);
    transform: translateY(var(--card-hover-lift-y, -2px));
    box-shadow: var(--card-surface-shadow-hover);
  }
}

/* ========== 卡片头部结构（card-header） ========== */

.card-header {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 8px;  /* 🎯 统一基础样式 */
}


/* ========================================
   头像样式 - Bunny Studio 风格
   ======================================== */

/* 电脑端统一 40×40，断点 768px→45px，480px→40px */
.HeadImg {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  margin: 0 auto 14px;  /* 🎯 头像下方间距：14px */
  float: none;
  display: block;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #fafafa; /* 🎨 头像占位：中性冷白 */
  border: none;
  box-shadow: var(--card-avatar-shadow, 0 1px 3px rgba(15, 23, 42, 0.07));
  transition: transform 0.2s ease;
  overflow: hidden;
}

@media (hover: hover) and (pointer: fine) {
  .Teacher:hover .HeadImg {
    transform: scale(1.06);
    box-shadow: 0 3px 12px rgba(24, 24, 27, 0.12);
  }
}

/* 头像链接：不单独叠加 transform/异色阴影，与整卡悬停一致（列表/首页/折扣等凡用本组件处） */
.Teacher .headimg-link,
.voice-card .headimg-link,
.discount-teacher-card .headimg-link {
  display: block;
  text-decoration: none;
  color: inherit;
  margin-bottom: 6px;
}

.HeadImgs-beijing {
  display: none;
}



/* ========== 名字和标签容器 ========== */

.teacher-details {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

/* 名字（与首页 .voice-name 同一层级） */
.teacher-code {
  font-family: var(--tvcbook-font);
  font-weight: 600;
  color: var(--tvcbook-title, #1f2937);
  font-size: 16px;
  line-height: 1.35;
  transition: color 0.25s ease;
  letter-spacing: 0.01em;
  text-decoration: none;
  display: block;
}

.Teacher:hover .teacher-code {
  color: var(--tvcbook-primary, #818cf8);
}

.teacher-info-line {
  width: 100%;
  text-align: center;
  
}

/* 信息文字 */
.teacher-info-text {
  font-family: var(--tvcbook-font) !important;
  font-size: 13px;
  font-weight: 400;
  color: var(--tvcbook-sub, #52525b);
  line-height: 1.45;
  display: inline-block;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
}

/* ========== 作品数和粉丝数 - Bunny Studio 风格 ========== */
.teacher-stats-line {
  width: 100%;
  text-align: center;
  margin: 6px 0 0;
  padding: 0;
  font-family: var(--tvcbook-font) !important;
  font-size: 13px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: none;
  border-radius: 0;
  box-sizing: border-box;
}

.teacher-stats-line .stat-item {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
}

/* TVC discover：数字与标题同色加粗，「作品」「关注」为副文灰 */
.teacher-stats-line .stat-num {
  color: var(--tvcbook-title, #1f2937);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.teacher-stats-line .stat-label {
  color: var(--tvcbook-sub, #52525b);
  font-weight: 400;
}

.teacher-stats-line .stat-divider {
  color: var(--tvcbook-muted, #71717a);
  font-weight: 400;
}



/* ========== 布局模式支持 ========== */

/* 居中模式（默认） */
.layout-center .Teacher,
:not(.layout-left) > .Teacher {
  align-items: center;
  text-align: center;
}

.layout-center .card-header,
:not(.layout-left) > .Teacher .card-header {
  align-items: center;
  text-align: center;
}

.layout-center .teacher-details,
:not(.layout-left) > .Teacher .teacher-details {
  align-items: center;
  text-align: center;
}

.layout-center .teacher-info-line,
:not(.layout-left) > .Teacher .teacher-info-line {
  text-align: center;
  justify-content: center;
  display: flex;
}

.layout-center .teacher-info-text,
:not(.layout-left) > .Teacher .teacher-info-text {
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.layout-center .teacher-stats-line,
:not(.layout-left) > .Teacher .teacher-stats-line {
  justify-content: center;
  text-align: center;
}

/* 左对齐布局支持 */
.layout-left .card-header {
  align-items: flex-start;
  text-align: left;
}

.layout-left .teacher-details {
  align-items: flex-start;
  text-align: left;
}

.layout-left .teacher-info-line {
  text-align: left;
  justify-content: flex-start;
}

.layout-left .teacher-info-text {
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  display: block;
}

.layout-left .teacher-stats-line {
  justify-content: flex-start;
  text-align: left;
}

/* ========== 播放器容器 - Bunny Studio 风格 ========== */

.audio_teacher_list {
  position: relative;
  height: 40px;  /* 🎯 播放器高度稍高一点 */
  display: flex;
  align-items: center;
  width: 100%;
  margin: 12px 0 20px;  /* 🎯 播放器上方16px，下方12px */
  z-index: 1;
}



.audio_teacher_list .unified-player-wrapper {
  width: 100%;
  margin: 0;
}

.audio_teacher_list .unified-player-container {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 10px;
  padding: 4px 10px 4px 4px;
  box-sizing: border-box;
  background: var(--card-player-bg, #eaeaec);
  border: 1px solid var(--card-player-border, #e4e4e7);
  border-radius: var(--card-player-radius, 8px);
}

.audio_teacher_list .unified-player-button {
  flex-shrink: 0;
}

/* ========== 首页推荐男声/女声卡片（继承 Teacher 样式） ========== */

.voice-cards-container {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  width: 100%;
  clear: both;
}

/* 首页推荐区域的老师卡片宽度 */
.voice-cards-container .Teacher,
.voice-card {
  width: calc((100% - 60px) / 5);
  flex: 0 0 calc((100% - 60px) / 5);
  box-sizing: border-box;
  height: 100%;
  position: relative;
  z-index: 1;
  animation: fadeInUp 0.6s ease-out backwards;
}

/* 🎬 淡入上浮动画 */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 为每张卡片设置延迟，形成波浪效果 */
.voice-card:nth-child(1) { animation-delay: 0.05s; }
.voice-card:nth-child(2) { animation-delay: 0.1s; }
.voice-card:nth-child(3) { animation-delay: 0.15s; }
.voice-card:nth-child(4) { animation-delay: 0.2s; }
.voice-card:nth-child(5) { animation-delay: 0.25s; }
.voice-card:nth-child(6) { animation-delay: 0.3s; }
.voice-card:nth-child(7) { animation-delay: 0.35s; }
.voice-card:nth-child(8) { animation-delay: 0.4s; }
.voice-card:nth-child(9) { animation-delay: 0.45s; }
.voice-card:nth-child(10) { animation-delay: 0.5s; }

.voice-card:has(.action-dropdown.show) {
  z-index: 9999;
}

/* ⭐ 首页推荐男声/女声卡片 - Bunny Studio 风格 */
.voice-card-inner {
  position: relative;
  padding: 24px 20px 18px;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  background: var(--card-surface-panel, transparent);
  border: 1px solid var(--card-surface-outline, rgba(0, 0, 0, 0.1));
  border-radius: var(--tvcbook-radius, 10px);
  box-shadow: var(--card-surface-shadow);
  transform: translateY(0);
  transition:
    transform var(--card-hover-duration, 0.22s) var(--card-hover-easing, cubic-bezier(0.25, 0.72, 0.38, 1)),
    box-shadow var(--card-hover-duration, 0.22s) var(--card-hover-easing, cubic-bezier(0.25, 0.72, 0.38, 1)),
    border-color var(--card-hover-duration, 0.22s) ease;
}

/* 悬停效果（与 .Teacher 一致） */
@media (hover: hover) and (pointer: fine) {
  .voice-card-inner:hover {
    z-index: 2;
    overflow: visible;
    border-color: var(--card-surface-outline-hover, rgba(0, 0, 0, 0.18));
    background: var(--card-surface-panel-hover, transparent);
    transform: translateY(var(--card-hover-lift-y, -2px));
    box-shadow: var(--card-surface-shadow-hover);
  }
}

/* .voice-card .card-header 样式已统一到通用 .card-header */

.voice-card .voice-avatar-link {
  display: block;
  text-decoration: none;
}

.voice-card .voice-details {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  margin-top: 8px;
}

/* 头像 - TVCBOOK 风格 */
/* 与 .HeadImg 统一：电脑端 40×40 */
.voice-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
  background-color: #fafafa;
  border: none;
  box-shadow: var(--card-avatar-shadow, 0 1px 3px rgba(15, 23, 42, 0.07));
  transition: transform 0.2s ease;
  position: relative;
  overflow: hidden;
}

@media (hover: hover) and (pointer: fine) {
  .voice-card-inner:hover .voice-avatar {
    transform: scale(1.06);
    box-shadow: 0 3px 12px rgba(24, 24, 27, 0.12);
  }
}

/* ========== .voice-name（与 .teacher-code 对齐，避免首页/列表字重字号不一致） ========== */
.voice-name {
  font-family: var(--tvcbook-font);
  font-weight: 600;
  color: var(--tvcbook-title, #1f2937);
  font-size: 16px;
  margin: 12px 0 8px;
  line-height: 1.35;
  transition: color 0.15s ease;
  letter-spacing: 0.01em;
  text-decoration: none;
  display: block;
  text-align: center;
}

.voice-card:hover .voice-name {
  color: var(--tvcbook-primary, #818cf8);
}


/* ========== 头像区域容器 ========== */
.voice-avatar-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 8px;
}

/* ========== 头像链接悬停效果 ========== */
.voice-avatar-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  color: inherit;
  width: 100%;
}

.voice-avatar-link:hover .voice-name {
  color: var(--tvcbook-primary, #818cf8);
}

.voice-avatar-link:hover .voice-avatar {
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.12);
  transform: scale(1.04);
}


/* ========== 信息行样式 ========== */
.voice-info-line {
  text-align: center;
  min-height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 15px;
}

.voice-info-text {
  display: inline-block;
  font-family: var(--tvcbook-font);
  font-size: 13px;
  font-weight: 400;
  color: var(--tvcbook-sub, #52525b);
  line-height: 1.45;
  word-break: break-word;
}


/* ========== 标签样式 ========== */
.voice-tags {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 15px;
  min-height: 30px;
}

.voice-tag {
  display: inline-block;
  padding: 5px 12px;
  border-radius: var(--tag-chip-radius, 6px);
  background: var(--tag-chip-bg, #ecfdf5);
  color: var(--tag-chip-text, #475569);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
  margin: 0 4px 8px 4px;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  border: 1px solid var(--tag-chip-border, #e2e8f0);
  box-shadow: none;
}

.voice-tag:hover {
  background: #ebebeb;
  border-color: #d4d4d4;
  color: var(--tag-chip-text, #525252);
}

/* ========== 音频区域样式 ========== */
.voice-audio-section {
  position: relative;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 37px;
  box-sizing: border-box;
  min-height: 40px;
}

.voice-card .controls {
  position: absolute;
  top: 45%;
  left: 2px;
  transform: translateY(-50%);
  z-index: 10;
}

/* .voice-info-text 已统一为 .teacher-info-text */

.voice-card .audio_teacher_list {
  margin-bottom: 16px;
  background: none;
  border: none;
  box-shadow: none;
  padding: 0;
}

.voice-card .waveform {
  width: 100%;
  height: 40px;
}

/* ========== 限时打折卡片（继承 Teacher 样式） ========== */

.discount-teacher-card {
  /* 供顶栏倒计时等按「卡片宽度」自适应（桌面多列窄卡与手机两列均生效） */
  container-type: inline-size;
  container-name: discount-card;
  width: calc((100% - 60px) / 5);
  flex: 0 0 calc((100% - 60px) / 5);
  flex-shrink: 0;
  padding: 0;
  box-sizing: border-box;
  position: relative;
  z-index: 1;
}

.discount-teacher-card:has(.action-dropdown.show) {
  z-index: 9999;
}

/* ⭐ 限时打折卡片 - Bunny Studio 风格（顶区略收紧，避免倒计时行显得「飘」在上方） */
.discount-teacher-inner {
  padding: 16px 20px 18px;
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
  overflow: visible;
  min-width: 0;
  max-width: 100%;
  background: var(--card-surface-panel, transparent);
  border: 1px solid var(--card-surface-outline, rgba(0, 0, 0, 0.1));
  border-radius: var(--tvcbook-radius, 10px);
  box-shadow: var(--card-surface-shadow);
  transform: translateY(0);
  transition:
    transform var(--card-hover-duration, 0.22s) var(--card-hover-easing, cubic-bezier(0.25, 0.72, 0.38, 1)),
    box-shadow var(--card-hover-duration, 0.22s) var(--card-hover-easing, cubic-bezier(0.25, 0.72, 0.38, 1)),
    border-color var(--card-hover-duration, 0.22s) ease;
  contain: layout style;
}

/* 悬停效果：与 .Teacher 一致（无灰底，仅阴影抬高） */
@media (hover: hover) and (pointer: fine) {
  .discount-teacher-inner:hover {
    z-index: 2;
    border-color: var(--card-surface-outline-hover, rgba(0, 0, 0, 0.18));
    background: var(--card-surface-panel-hover, transparent);
    transform: translateY(var(--card-hover-lift-y, -2px));
    box-shadow: var(--card-surface-shadow-hover);
  }
}

.discount-teacher-card .card-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  margin-bottom: 0;  /* 🎯 结构统一后，间距由内部元素控制 */
  padding-top: 0; /* 顶部条已占位，无需再垫高 */
}

.discount-teacher-card .discount-teacher-link {
  display: block;
  text-decoration: none;
}

.discount-teacher-card .discount-teacher-details {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  margin-top: 0;  /* 🎯 头像已有下间距，这里不需要额外间距 */
  text-align: center;
}

/* ⚠️ 已弃用的类名（已改用统一类名）：
 * - .discount-teacher-avatar → 改用 .HeadImg
 * - .discount-teacher-details → 改用 .teacher-details
 * - .discount-teacher-name → 改用 .teacher-code
 * - .discount-teacher-info-line → 改用 .teacher-info-line
 * - .discount-teacher-info-text → 改用 .teacher-info-text
 */

/* 资质标签（限时打折特有） */
.discount-teacher-type {
  font-family: var(--tvcbook-font);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.45;
  color: var(--tvcbook-sub, #52525b);
  margin-bottom: 8px;
}

 

/* 折扣标签 - Bunny Studio 风格（其它页/折扣卡模块；首页限时顶栏已不展示） */
.discount-badge {
  position: relative;
  z-index: 21;
  flex-shrink: 0;
  background: #111827;
  border-radius: 6px;
  padding: 5px 9px;
  height: auto;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 2px;
  color: #ffffff;
  font-weight: 500;
  font-size: 11px;
  line-height: 1;
  box-shadow: none;
  filter: none;
}

.discount-value {
  font-size: 12px;
  line-height: 1;
  font-weight: 600;
  color: #ffffff;
}

.discount-label {
  font-size: 9px;
  font-weight: 500;
  opacity: 0.8;
  text-transform: uppercase;
}

/* 倒计时 - 宽度随文案；字重与颜色略加强，易读 */
.discount-countdown {
  position: relative;
  z-index: 20;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: 0 1 auto;
  align-self: flex-start;
  min-width: 0;
  max-width: 100%;
  font-size: clamp(11px, 2.9vw, 12px);
  font-weight: 500;
  white-space: nowrap;
  overflow: visible;
  color: #3f3f46;
  margin: 0;
  padding: 5px 8px;
  height: auto;
  box-sizing: border-box;
  background: #f4f4f5;
  border: 1px solid #e7e5e4;
  border-radius: 6px;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

/* 倒计时图标 - 用伪元素添加时钟 */
.discount-countdown::before {
  content: '';
  width: 13px;
  height: 13px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2352525b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpolyline points='12,6 12,12 16,14'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  flex-shrink: 0;
}

/* 紧急状态 - 更醒目但不刺眼 */
.discount-countdown.urgent {
  color: #c2410c;
  background: #fff7ed;
  border-color: #fed7aa;
}

.discount-countdown.urgent::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c2410c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpolyline points='12,6 12,12 16,14'/%3E%3C/svg%3E");
}

/* 价格区内倒计时：与专题/广告价同一块，无底色、线稿时钟 + 文案 */
.discount-price-section .discount-countdown {
  --dc-fg: #64748b;
  min-width: 0;
  width: 100%;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  background: none;
  border: none;
  border-radius: 0;
  font-size: clamp(12px, 2.8vw, 14px);
  font-weight: 500;
  color: var(--dc-fg);
  line-height: 1.4;
  letter-spacing: -0.01em;
  overflow: hidden;
  box-shadow: none;
}

@supports (container-type: inline-size) {
  .discount-teacher-card .discount-price-section .discount-countdown {
    font-size: clamp(12px, 2.8cqw + 3px, 14px);
  }
}

.discount-price-section .discount-countdown-text {
  min-width: 0;
  flex: 0 1 auto;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

.discount-price-section .discount-countdown::before {
  content: '';
  display: block;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  border-radius: 0;
  background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236366f1' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpolyline points='12,6 12,12 16,14'/%3E%3C/svg%3E");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  border: none;
  box-shadow: none;
}

.discount-price-section .discount-countdown.urgent {
  --dc-fg: #c2410c;
  background: none;
  box-shadow: none;
}

.discount-price-section .discount-countdown.urgent::before {
  background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ea580c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpolyline points='12,6 12,12 16,14'/%3E%3C/svg%3E");
}

.discount-price-section .discount-countdown.expired {
  --dc-fg: #94a3b8;
}

.discount-price-section .discount-countdown.expired .discount-countdown-text {
  color: var(--dc-fg);
}

.discount-price-section .discount-countdown.expired::before {
  opacity: 0.45;
  filter: grayscale(0.4);
}

@container discount-card (max-width: 380px) {
  .discount-price-section .discount-countdown {
    gap: 8px;
  }

  .discount-price-section .discount-countdown::before {
    width: 14px;
    height: 14px;
  }

  .discount-price-section .discount-countdown {
    font-size: 13px;
    gap: 5px;
  }

  .discount-price-section .discount-countdown-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

@supports not (container-type: inline-size) {
  @media (max-width: 768px) {
    .discount-price-section .discount-countdown {
      font-size: 13px;
      gap: 5px;
    }

    .discount-price-section .discount-countdown::before {
      width: 14px;
      height: 14px;
    }

    .discount-price-section .discount-countdown-text {
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
  }
}

/* 价格展示 - Bunny Studio 风格（可与顶部倒计时同块） */
.discount-price-section {
  margin: 8px 0 0;
  padding: 10px 10px;
  background: #f9fafb;
  border-radius: 8px;
  min-height: 0;
  height: auto;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.discount-price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0;
}

.discount-price-label {
  font-size: 12px;
  color: var(--tvcbook-sub, #52525b);
  font-weight: 400;
  line-height: 1.35;
}

.discount-price-value {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.discount-current-price {
  font-size: 16px;
  font-weight: 600;
  color: #f97316;
}

.discount-original-price {
  font-size: 12px;
  color: #9ca3af;
  text-decoration: line-through;
}

/* ========== 响应式设计（以 teacher_list.css 为准） ========== */
/* ✅ .Teacher 使用Grid布局，宽度自动填满单元格，无需手动计算 */

/* 1350px断点：Content有padding，提前切换到4列 */
@media (max-width: 1350px) {
  .voice-cards-container .Teacher,
  .voice-card {
    width: calc((100% - 45px) / 4); /* 4列，3个间隙×15px=45px */
    flex: 0 0 calc((100% - 45px) / 4);
  }
}

@media (max-width: 1200px) {
  .voice-cards-container .Teacher,
  .voice-card {
    width: calc((100% - 45px) / 4); /* 4列，3个间隙×15px=45px */
    flex: 0 0 calc((100% - 45px) / 4);
  }
  
  .voice-cards-container {
    gap: 15px;
  }
}

@media (max-width: 1024px) {
  .voice-cards-container .Teacher,
  .voice-card {
    width: calc((100% - 24px) / 3); /* 3列，2个间隙×12px=24px */
    flex: 0 0 calc((100% - 24px) / 3);
  }
  
  .voice-cards-container {
    gap: 12px;
  }
}

@media (max-width: 768px) {
  .Teacher {
    width: 100%; /* Grid自动处理 */
    max-width: 100%; /* 🔧 确保不超出容器 */
    min-width: 0; /* 🔧 关键：允许在Grid中收缩 */
    margin: 0;
    padding: 20px 16px 16px;  /* 🎯 平板端：上20px 左右16px 下16px */
    display: flex;
    overflow: hidden; /* 🔧 防止内容溢出 */
    flex-direction: column;
  }
  
  /* 平板端 45×45 */
  .HeadImg {
    width: 45px;
    height: 45px;
    margin: 0 auto 12px;  /* 🎯 平板端头像间距 */
  }
  
  .voice-cards-container .Teacher,
  .voice-card {
    width: calc(50% - 5px); /* 2列 */
    flex: 0 0 calc(50% - 5px);
    margin: 0;
    display: flex;
    flex-direction: column;
  }
  
  .voice-card-inner, .discount-teacher-inner {
    padding: 15px;
  }
  
  .voice-avatar {
    width: 45px;
    height: 45px;
    margin: 0 auto 12px;  /* 🎯 平板端头像间距 */
  }
  
 
  
  .teacher-stats-line {
    font-size: 13px;
  }
  
  .voice-info-line, .discount-teacher-type, .teacher-info-text {
    font-size: 13px;
  }
  
  .Teacher .audio_teacher_list, .voice-card .audio_teacher_list {
    width: 100%;
    float: none;
    margin: 14px 0 10px;  /* 🎯 平板端播放器间距 */
    display: flex;
    justify-content: center;
    background: rgb(236 236 236 / 0%);
    border-radius: 8px;
  }
  
  .voice-cards-container {
    gap: 10px;
  }
  
}

@media (max-width: 576px) {
  .Teacher {
    width: 100%; /* Grid自动处理 */
    max-width: 100%; /* 🔧 确保不超出容器 */
    min-width: 0; /* 🔧 关键：允许在Grid中收缩 */
    margin: 0;
    padding: 18px 14px 14px;  /* 🎯 移动端：上18px 左右14px 下14px */
    display: flex;
    flex-direction: column;
    overflow: hidden; /* 🔧 防止内容溢出 */
  }
  
  /* 🔧 576px断点：头像尺寸平滑过渡 (768px 45px → 576px 42px → 480px 40px) */
  .HeadImg {
    width: 42px;
    height: 42px;
    margin: 0 auto 11px;
  }
  
  .voice-avatar {
    width: 42px;
    height: 42px;
    margin: 0 auto 11px;
  }
  
  .Teacher .audio_teacher_list {
    width: 100%;
    float: none;
    margin: 12px 0 20px;  /* 🎯 移动端播放器间距调整 */
    display: flex;
    justify-content: center;
    background: rgb(236 236 236 / 0%);
    border-radius: 8px;
  }
}

@media (max-width: 480px) {
  /* 手机端 40×40 */
  .HeadImg {
    width: 40px;
    height: 40px;
    margin: 0 auto 10px;
  }
  
  .voice-cards-container .Teacher,
  .voice-card {
    width: calc(50% - 4px);
    flex: 0 0 calc(50% - 4px);
  }
  .teacher-info-text {
    max-width: 165px;
  }
  .teacher-info-line {
     
    margin: 0 0;
  }
  
  /* 🔧 小屏手机老师名字字体统一调整 */
  .voice-name,
  .discount-teacher-name,
  .teacher-code,
  .teacherName,
  .teacher-name,
  .order-teacher-code,
  .teacher-name-info .Name h2 {
    font-size: 15px;
  }
  
  .teacher-stats-line,
  .voice-info-line,
  .discount-teacher-type,
  .teacher-info-text {
    font-size: 13px;
  }
  
  .voice-card-inner, .discount-teacher-inner {
    padding: 12px 6px;
  }
  
  .voice-avatar {
    width: 40px;
    height: 40px;
    margin: 0 auto 10px;  /* 🎯 移动端头像间距 */
  }
  
  .voice-cards-container {
    gap: 8px;
  }
}








.voice-card:focus-within .voice-card-inner,
.voice-card-inner:focus {
  outline: 3px solid rgba(74, 86, 243, 0.35);
  outline-offset: 2px;
  border-color: var(--tvcbook-primary, #818cf8);
}






.discount-teacher-card:focus-within .discount-teacher-inner,
.discount-teacher-inner:focus {
  outline: 3px solid rgba(74, 86, 243, 0.35);
  outline-offset: 2px;
  border-color: var(--tvcbook-primary, #818cf8);
}








/* ========================================
   🚀 性能优化：尊重用户动画偏好
   ======================================== */
@media (prefers-reduced-motion: reduce) {
  .Teacher,
  .voice-card-inner,
  .discount-teacher-inner,
  .voice-avatar,
  .HeadImg {
    transition: none;
  }
  
  .Teacher:hover,
  .voice-card-inner:hover,
  .discount-teacher-inner:hover {
    transform: none;
  }

  .Teacher:hover .HeadImg,
  .voice-card-inner:hover .voice-avatar {
    transform: none;
  }
}






