/* 首页 - 推荐高校 */
.home-recommended {
  background: #f8fafc;
  padding: 80px 0;
}

.home-recommended .section_tittle {
  text-align: center;
  margin-bottom: 45px;
}

.home-recommended .section_tittle h2 {
  font-size: 32px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 10px;
}

.home-recommended .section_tittle p {
  color: #64748b;
  font-size: 16px;
}

.rec-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.rec-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.rec-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12);
}

.rec-video {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0f172a;
}

.rec-video video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.rec-video .play-btn {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
  cursor: pointer;
  background: rgba(15, 23, 42, 0.18);
  transition: background 0.2s ease, opacity 0.2s ease;
}

.rec-card:hover .rec-video .play-btn {
  background: rgba(15, 23, 42, 0.08);
}
/* 播放后隐藏中央叠层播放钮，露出原生控件，避免遮挡点击 */
.rec-video.is-playing .play-btn {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.rec-video .play-btn span {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
}

.rec-video .play-btn span svg {
  width: 22px;
  height: 22px;
  fill: #e84c55;
  margin-left: 3px;
}

.rec-body {
  padding: 20px 22px 26px;
}

.rec-body h3 {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
  line-height: 1.35;
}

.rec-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 14px;
  color: #475569;
}

.rec-meta svg {
  width: 16px;
  height: 16px;
  stroke: #64748b;
}

.rec-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.rec-tag {
  display: inline-block;
  padding: 5px 10px;
  border-radius: 20px;
  background: #fdecec;
  color: #c73b45;
  font-size: 12px;
  font-weight: 500;
}

.rec-tag.lang-en {
  background: #eaf1f7;
  color: #0a3d62;
}

.rec-empty {
  text-align: center;
  color: #64748b;
  padding: 40px 0;
}

@media (max-width: 991px) {
  .rec-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 575px) {
  .home-recommended {
    padding: 60px 0;
  }
  .home-recommended .section_tittle h2 {
    font-size: 26px;
  }
  /* 手机端：推荐高校改为一行横向滑动，避免竖排三个太长 */
  .rec-grid {
    display: flex;
    grid-template-columns: none;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    gap: 14px;
    margin: 0 -16px;
    padding: 2px 16px 12px;
  }
  .rec-card {
    flex: 0 0 78%;
    max-width: 78%;
    scroll-snap-align: start;
  }
  /* 手机端 video 自带 controls 原生播放键，隐藏 CSS 叠加按钮，避免两个播放图重叠 */
  .rec-video .play-btn {
    display: none;
  }
}
