/* =========================================================
   清晨教育 - 非标机械方案设计系统课 课程页样式
   蓝白色调 · 与整站风格一致 · 响应式
   ========================================================= */

/* ---------- Banner 满屏大图 ---------- */
.course-banner {
  position: relative;
  width: 100%;
  height: 450px;
  overflow: hidden;
  display: flex;
  align-items: center;
}
.course-banner-bg,
.course-banner-bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.course-banner-bg img {
  object-fit: cover;
  object-position: center;
}
.course-banner-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(10, 37, 64, 0.88) 0%, rgba(10, 76, 176, 0.62) 45%, rgba(11, 99, 229, 0.25) 100%);
}
.course-banner-inner {
  position: relative;
  z-index: 2;
  color: var(--white);
}
.course-banner-inner .hero-tag {
  background: rgba(255, 255, 255, 0.14);
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(4px);
}
.course-banner-inner h1 {
  font-size: 42px;
  line-height: 1.35;
  letter-spacing: 2px;
  margin-bottom: 16px;
  text-shadow: 0 4px 24px rgba(10, 37, 64, 0.45);
}
.course-banner-inner p {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 28px;
}
.course-banner-inner .hero-actions { margin-bottom: 0; }

/* ---------- 热门教程推荐（选项卡切换） ---------- */
.course-tab-btns { margin-bottom: 40px; }
/* 覆盖 style.css 中 .tab-panel 的卡片式布局，改为内容容器 */
.course-tabs > .tab-panel {
  display: none;
  grid-template-columns: none;
  gap: 0;
  align-items: initial;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
}
.course-tabs > .tab-panel.active {
  display: block;
  animation: fadeUp 0.45s ease;
}
.tutorial-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
}
.tutorial-card::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 4px;
  background: linear-gradient(90deg, var(--blue), #5ea2ff);
  transform: scaleX(0);
  transform-origin: left;
  transition: var(--transition);
}
.tutorial-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-6px); }
.tutorial-card:hover::after { transform: scaleX(1); }
.tutorial-media {
  aspect-ratio: 3 / 2;
  overflow: hidden;
  line-height: 0;
}
.tutorial-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.tutorial-card:hover .tutorial-media img { transform: scale(1.06); }
.tutorial-body { padding: 18px 20px 20px; }
.tutorial-body h3 {
  font-size: 16px;
  color: var(--blue-deep);
  margin-bottom: 14px;
  line-height: 1.5;
  min-height: 2.9em;
}
.tutorial-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.tutorial-learners {
  font-size: 13px;
  color: var(--text-sub);
}
.tutorial-btn {
  display: inline-block;
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--blue);
  border: 1px solid var(--blue);
  border-radius: 999px;
  transition: var(--transition);
  white-space: nowrap;
}
.tutorial-btn:hover {
  background: var(--blue);
  color: var(--white);
  transform: translateY(-1px);
}

/* ---------- 行业前景 ---------- */
.prospect-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 26px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
.prospect-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 4px;
  background: linear-gradient(90deg, var(--blue), #5ea2ff);
  transform: scaleX(0);
  transform-origin: left;
  transition: var(--transition);
}
.prospect-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-6px); }
.prospect-card:hover::before { transform: scaleX(1); }
.prospect-num {
  font-size: 34px;
  font-weight: 800;
  color: var(--blue-light);
  -webkit-text-stroke: 1px var(--blue);
  display: block;
  margin-bottom: 12px;
}
.prospect-card h3 { font-size: 20px; color: var(--blue-deep); margin-bottom: 10px; }
.prospect-card p { font-size: 14px; color: var(--text-sub); }

/* ---------- 系统课四阶段对照表 ---------- */
.stage-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  background: var(--white);
  -webkit-overflow-scrolling: touch;
}
.stage-table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
  text-align: center;
}
.stage-table th,
.stage-table td {
  padding: 18px 16px;
  font-size: 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  line-height: 1.8;
}
.stage-table thead th {
  background: linear-gradient(120deg, var(--blue) 0%, var(--blue-dark) 100%);
  color: var(--white);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 1px;
  border-bottom: none;
}
.stage-table thead th:first-child {
  background: var(--blue-deep);
}
.stage-table tbody th {
  background: var(--bg-alt);
  color: var(--blue-deep);
  font-weight: 600;
  white-space: nowrap;
  width: 110px;
}
.stage-table tbody tr:last-child th,
.stage-table tbody tr:last-child td { border-bottom: none; }
.stage-table tbody tr { transition: background 0.25s ease; }
.stage-table tbody tr:hover td { background: #f2f7ff; }
.stage-table td strong { color: var(--blue); font-size: 15px; }
.stage-badge {
  display: inline-block;
  background: var(--blue-light);
  color: var(--blue);
  font-weight: 700;
  font-size: 14px;
  padding: 6px 16px;
  border-radius: 999px;
  white-space: nowrap;
}

/* 屏幕阅读器专用（SEO / 无障碍） */
.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;
}

/* ---------- 常见问题解答 FAQ（单栏排列） ---------- */
.faq-list {
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.faq-item + .faq-item { border-top: 1px solid var(--border); }
.faq-q { margin: 0; }
.faq-q-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  padding: 20px 24px;
  background: var(--white);
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  text-align: left;
  transition: var(--transition);
}
.faq-q-btn:hover { color: var(--blue); background: var(--bg-alt); }
.faq-item.active .faq-q-btn { color: var(--blue); background: var(--blue-light); }
.faq-icon {
  position: relative;
  flex-shrink: 0;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--blue-light);
  transition: var(--transition);
}
.faq-icon::before,
.faq-icon::after {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  background: var(--blue);
  border-radius: 2px;
  transform: translate(-50%, -50%);
  transition: var(--transition);
}
.faq-icon::before { width: 12px; height: 2px; }
.faq-icon::after { width: 2px; height: 12px; }
.faq-item.active .faq-icon { background: var(--blue); transform: rotate(180deg); }
.faq-item.active .faq-icon::before { background: var(--white); }
.faq-item.active .faq-icon::after { background: var(--white); transform: translate(-50%, -50%) scaleY(0); }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}
.faq-a p {
  padding: 18px 24px 22px;
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.9;
  border-top: 1px dashed var(--border);
}
.faq-item.active .faq-a { max-height: 400px; }

/* =========================================================
   响应式
   ========================================================= */
@media (max-width: 1024px) {
  .course-banner { height: 400px; }
  .course-banner-inner h1 { font-size: 34px; }
}

@media (max-width: 768px) {
  .course-banner { height: 340px; }
  .course-banner-inner h1 { font-size: 27px; letter-spacing: 1px; }
  .course-banner-inner p { font-size: 15px; }
  .course-banner-inner .hero-tag { font-size: 12px; padding: 5px 12px; }
  .tutorial-grid { grid-template-columns: repeat(2, 1fr); }
  .prospect-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  .course-banner { height: 300px; }
  .course-banner-inner h1 { font-size: 23px; }
  .course-rec-grid { grid-template-columns: 1fr; }
  .tutorial-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tutorial-body h3 { min-height: 0; }
  .prospect-grid { grid-template-columns: 1fr; }
  .course-rec-body { padding: 18px 18px 22px; }
  .faq-q-btn { padding: 16px 18px; font-size: 15px; }
  .faq-a p { padding: 14px 18px 18px; }
}

/* 小屏教程卡片：两列并收紧内容 */
@media (max-width: 560px) {
  .tutorial-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .tutorial-body {
    padding: 12px 10px 14px;
  }

  .tutorial-grid .tutorial-body h3 {
    min-height: 0;
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 1.4;
  }

  .tutorial-meta {
    gap: 6px;
    flex-wrap: wrap;
  }

  .tutorial-grid .tutorial-learners {
    font-size: 11px;
  }

  .tutorial-grid .tutorial-btn {
    padding: 4px 9px;
    font-size: 11px;
  }
}
