.tab-panel[data-tab-panel="courses"] {
  padding: 0 0 calc(92px + env(safe-area-inset-bottom));
  background: #fffefa;
}

.course-page {
  display: grid;
  gap: 10px;
  width: calc(100% - 36px);
  margin: 13px auto 0;
  color: var(--home-ink);
}

.course-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 183px;
  gap: 12px;
  align-items: center;
}

.course-header h1 {
  margin: 0;
  color: #101211;
  font-family: "Avenir Next", "PingFang SC", "Hiragino Sans GB", sans-serif;
  font-size: 25px;
  font-weight: 900;
  line-height: 1.1;
}

.course-header p {
  margin-top: 6px;
  color: #686f6a;
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
}

.course-search {
  display: flex;
  gap: 8px;
  align-items: center;
  height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 30px rgba(54, 43, 30, 0.08);
  color: #a6aaa9;
}

.course-search svg {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
}

.course-search input {
  min-width: 0;
  width: 100%;
  border: 0;
  outline: none;
  background: transparent;
  color: #252b28;
  font-size: 13px;
  font-weight: 650;
}

.course-search input::placeholder {
  color: #aaaead;
}

.course-hero {
  position: relative;
  min-height: 122px;
  overflow: hidden;
  border-radius: 8px;
  background: #eee7d9;
  box-shadow: 0 12px 28px rgba(54, 43, 30, 0.08);
}

.course-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 65% center;
}

.course-hero::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(248, 239, 222, 0.96) 0%, rgba(248, 239, 222, 0.7) 45%, rgba(248, 239, 222, 0.05) 100%);
  content: "";
}

.course-hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  padding: 25px 0 0 25px;
}

.course-hero h2 {
  color: #151816;
  font-family: "Avenir Next", "PingFang SC", "Hiragino Sans GB", sans-serif;
  font-size: 25px;
  font-weight: 900;
  line-height: 1.18;
}

.course-hero h2 span {
  color: #0f8b53;
  font-size: 32px;
}

.course-hero p {
  color: #5f655f;
  font-size: 14px;
  font-weight: 750;
}

.course-dots {
  position: absolute;
  left: 50%;
  bottom: 12px;
  z-index: 1;
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  transform: translateX(-50%);
}

.course-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
}

.course-dots span:first-child {
  width: 10px;
  background: #0f9b61;
}

.course-categories,
.course-recommend,
.course-gift {
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 28px rgba(54, 43, 30, 0.08);
}

.course-categories {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  min-height: 105px;
  padding: 14px 8px 13px;
}

.course-categories button {
  display: grid;
  justify-items: center;
  gap: 5px;
  min-width: 0;
  border-radius: 8px;
  transition: background 180ms ease, transform 180ms ease;
}

.course-categories button:hover {
  background: rgba(15, 139, 83, 0.06);
  transform: translateY(-1px);
}

.course-categories svg {
  width: 31px;
  height: 31px;
  color: #2a8966;
  stroke-width: 1.9;
}

.course-categories strong {
  margin-top: 2px;
  color: #1f2421;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.course-categories span {
  color: #858985;
  font-size: 11px;
  font-weight: 650;
  white-space: nowrap;
}

.course-recommend {
  overflow: hidden;
}

.course-section-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 22px;
  align-items: end;
  min-height: 52px;
  padding: 15px 13px 10px;
  border-bottom: 1px solid rgba(225, 221, 214, 0.72);
}

.course-section-head h2 {
  color: #101211;
  font-family: "Avenir Next", "PingFang SC", "Hiragino Sans GB", sans-serif;
  font-size: 20px;
  font-weight: 900;
}

.course-filter-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
}

.course-filter-tabs button {
  position: relative;
  height: 27px;
  color: #777d79;
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.course-filter-tabs .is-active {
  color: #0f8b53;
}

.course-filter-tabs .is-active::after {
  position: absolute;
  right: 50%;
  bottom: -5px;
  width: 20px;
  height: 3px;
  border-radius: 999px;
  background: #159b63;
  content: "";
  transform: translateX(50%);
}
