/* Trang chi tiết khóa học (/khoa-hoc/{slug}/) */
.hcp {
  --hcp-orange: #f15a24;
  --hcp-orange-dark: #d9481a;
  --hcp-blue: #1f5fe0;
  --hcp-blue-50: #eef4ff;
  --hcp-green: #16a34a;
  --hcp-star: #f5a524;
  --hcp-ink: #0c1a2e;
  --hcp-muted: #5d6e88;
  --hcp-line: #e6ebf2;
  background: #f6f8fc;
  color: var(--hcp-ink);
  padding-bottom: 40px;
}
.hcp-wrap { width: min(1200px, calc(100% - 40px)); margin: 0 auto; }
.hcp h1, .hcp h2, .hcp h3 { display: block; text-transform: none; letter-spacing: normal; font-weight: 700; text-align: left; margin: 0; }
.hcp-i { width: 18px; height: 18px; flex: none; }

.hcp-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 18px 0 14px; font-size: 13px; color: var(--hcp-muted); }
.hcp-crumbs a:hover { color: var(--hcp-blue); }
.hcp-crumbs b { color: var(--hcp-ink); font-weight: 600; }

/* Hero */
.hcp-hero { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 32px; background: #fff; border-radius: 20px; padding: 24px; box-shadow: 0 10px 30px rgba(2, 31, 71, .06); }
.hcp-media { position: relative; border-radius: 16px; overflow: hidden; aspect-ratio: 16 / 10; background: linear-gradient(135deg, #2f6fe8 0%, #1d4fc4 55%, #163c99 100%); }
.hcp-media--player { aspect-ratio: auto; background: #000; }
.hcp-embed { position: relative; padding-top: 56.25%; background: #000; overflow: hidden; border-radius: inherit; }
.hcp-embed iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; display: block; }
.hcp-media img { width: 100%; height: 100%; object-fit: cover; }
.hcp-media.has-video { cursor: pointer; }
.hcp-media__art { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-start; padding: 9% 9%; color: #fff; }
.has-video .hcp-media__art { padding-top: 7%; }
.has-video .hcp-play { top: 66%; }
.hcp-media__art b { font-size: clamp(34px, 5vw, 64px); line-height: 1.05; font-weight: 800; letter-spacing: -.01em; }
.hcp-media__art span { margin-top: 14px; font-size: clamp(16px, 1.8vw, 22px); max-width: 70%; opacity: .92; line-height: 1.4; }
.hcp-media__art::after { content: ""; position: absolute; right: -12%; bottom: -30%; width: 60%; aspect-ratio: 1; border-radius: 50%; background: rgba(255, 255, 255, .08); }
.hcp-play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 76px; height: 76px; border-radius: 50%; border: 0; background: rgba(12, 26, 46, .72); color: #fff; display: grid; place-items: center; cursor: pointer; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); transition: transform .2s, background .2s; }
.hcp-play .hcp-i { width: 30px; height: 30px; margin-left: 4px; }
.hcp-media:hover .hcp-play { transform: translate(-50%, -50%) scale(1.06); background: var(--hcp-orange); }
.hcp-media img + .hcp-play { top: 50%; }
.hcp-media__tag { position: absolute; left: 14px; bottom: 14px; background: rgba(12, 26, 46, .7); color: #fff; font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 99px; }

.hcp-summary { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.hcp-summary h1 { font-size: 30px; line-height: 1.2; color: var(--hcp-ink); }
.hcp-sub { color: var(--hcp-muted); font-size: 15px; margin-top: -4px; }
.hcp-rating { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 14px; color: var(--hcp-muted); }
.hcp-rating b { color: var(--hcp-ink); }
.hcp-rating a:hover { color: var(--hcp-blue); }
.hcp-dot { color: #c2cbd8; }
.hcp-stars { display: inline-flex; gap: 2px; }
.hcp-stars i { width: 15px; height: 15px; display: block; background: #d9dfe8; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.5l2.9 6.1 6.6.8-4.9 4.6 1.3 6.6L12 17.3l-5.9 3.3 1.3-6.6-4.9-4.6 6.6-.8z'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.5l2.9 6.1 6.6.8-4.9 4.6 1.3 6.6L12 17.3l-5.9 3.3 1.3-6.6-4.9-4.6 6.6-.8z'/%3E%3C/svg%3E") center / contain no-repeat; }
.hcp-stars i.full { background: var(--hcp-star); }
.hcp-stars i.half { background: linear-gradient(90deg, var(--hcp-star) 50%, #d9dfe8 50%); }

.hcp-meta { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 0; border-top: 1px solid var(--hcp-line); border-bottom: 1px solid var(--hcp-line); }
.hcp-meta li { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: #3a4a62; padding: 6px 10px; background: #f4f7fb; border-radius: 10px; }
.hcp-meta .hcp-i { width: 16px; height: 16px; color: var(--hcp-blue); }

.hcp-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; }
.hcp-price b { font-size: 32px; font-weight: 800; color: var(--hcp-orange); letter-spacing: -.01em; }
.hcp-price s { color: #98a3b3; font-size: 16px; }
.hcp-off { align-self: center; background: #fff1eb; color: var(--hcp-orange); font-weight: 700; font-size: 13px; padding: 4px 10px; border-radius: 8px; }

.hcp-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 50px; padding: 0 22px; border-radius: 12px; font-weight: 700; font-size: 15px; border: 1.5px solid var(--hcp-orange); cursor: pointer; transition: background .2s, color .2s, transform .1s; }
.hcp-btn:active { transform: translateY(1px); }
.hcp-btn--fill { background: var(--hcp-orange); color: #fff; }
.hcp-btn--fill:hover { background: var(--hcp-orange-dark); border-color: var(--hcp-orange-dark); color: #fff; }
.hcp-btn--line { background: #fff; color: var(--hcp-orange); }
.hcp-btn--line:hover { background: #fff5f0; }
.hcp-summary .hcp-btn { width: 100%; }
.hcp-owned { display: flex; align-items: center; gap: 6px; color: var(--hcp-green); font-weight: 600; font-size: 14px; }

.hcp-assure { display: grid; gap: 8px; margin-top: 4px; }
.hcp-assure li { display: flex; align-items: flex-start; gap: 10px; font-size: 13.5px; color: #3a4a62; }
.hcp-assure .hcp-i { color: var(--hcp-blue); width: 17px; height: 17px; margin-top: 1px; }
.hcp-hint { font-size: 13px; color: var(--hcp-muted); }
.hcp-hint a { color: var(--hcp-blue); font-weight: 600; }

/* Tabs */
.hcp-tabs { position: sticky; top: 76px; z-index: 50; background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--hcp-line); margin-top: 24px; }
.hcp-tabs .hcp-wrap { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.hcp-tabs a { padding: 14px 16px; font-weight: 600; font-size: 14.5px; color: var(--hcp-muted); border-bottom: 2.5px solid transparent; white-space: nowrap; }
.hcp-tabs a:hover { color: var(--hcp-ink); }
.hcp-tabs a.on { color: var(--hcp-blue); border-bottom-color: var(--hcp-blue); }

/* Sections */
.hcp-section { background: #fff; border-radius: 20px; padding: 28px; margin-top: 20px; box-shadow: 0 6px 20px rgba(2, 31, 71, .04); scroll-margin-top: 140px; }
.hcp-section h2 { font-size: 22px; color: var(--hcp-ink); line-height: 1.3; }
.hcp-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 18px; }
.hcp-head > span, .hcp-head > a { font-size: 13.5px; color: var(--hcp-muted); }
.hcp-head > a { display: inline-flex; align-items: center; gap: 4px; color: var(--hcp-blue); font-weight: 600; }
.hcp-head > a .hcp-i { width: 15px; height: 15px; }
.hcp-empty { color: var(--hcp-muted); }

.hcp-intro { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 32px; align-items: start; }
.hcp-desc { margin-top: 12px; color: #3a4a62; line-height: 1.75; }
.hcp-desc p + p { margin-top: 10px; }
.hcp-checks { display: grid; gap: 10px; margin-top: 16px; }
.hcp-checks li { display: flex; align-items: flex-start; gap: 10px; color: #26364d; }
.hcp-checks .hcp-i { width: 20px; height: 20px; padding: 3px; border-radius: 50%; background: var(--hcp-green); color: #fff; stroke-width: 3; margin-top: 2px; }
.hcp-teacher { display: flex; align-items: center; gap: 8px; margin-top: 18px; color: var(--hcp-muted); font-size: 14px; }
.hcp-teacher b { color: var(--hcp-ink); }
.hcp-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hcp-stats > div { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 18px 12px; border-radius: 16px; background: #f6f9ff; border: 1px solid #e8eefb; }
.hcp-stats span { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: #fff; color: var(--hcp-blue); box-shadow: 0 4px 12px rgba(31, 95, 224, .1); margin-bottom: 4px; }
.hcp-stats span .hcp-i { width: 22px; height: 22px; }
.hcp-stats b { font-size: 20px; color: var(--hcp-ink); line-height: 1.25; }
.hcp-stats small { font-size: 12.5px; color: var(--hcp-muted); }

/* Curriculum */
.hcp-acc { display: grid; gap: 10px; }
.hcp-ch { border: 1px solid var(--hcp-line); border-radius: 14px; overflow: hidden; }
.hcp-ch__head { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 18px; background: #f8fafd; border: 0; cursor: pointer; font: inherit; font-weight: 600; color: var(--hcp-ink); text-align: left; }
.hcp-ch__head em { font-style: normal; font-weight: 500; color: var(--hcp-muted); margin-left: 4px; }
.hcp-ch__head .hcp-i { color: var(--hcp-muted); transition: transform .2s; }
.hcp-ch.open .hcp-ch__head .hcp-i { transform: rotate(180deg); }
.hcp-ch__list { display: none; }
.hcp-ch.open .hcp-ch__list { display: block; }
.hcp-ch__list li { display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--hcp-line); font-size: 14.5px; }
.hcp-ch__list li.can-preview { cursor: pointer; }
.hcp-ch__list li.can-preview:hover { background: #fafcff; }
.hcp-ch__list li.muted { color: var(--hcp-muted); }
.hcp-ch__ico { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #eef2f7; color: #8a97ab; flex: none; }
.hcp-ch__ico .hcp-i { width: 14px; height: 14px; }
.can-preview .hcp-ch__ico { background: var(--hcp-blue-50); color: var(--hcp-blue); }
.hcp-ch__t { flex: 1; min-width: 0; }
.hcp-ch__d { color: var(--hcp-muted); font-size: 13px; font-variant-numeric: tabular-nums; min-width: 44px; text-align: right; }
.hcp-free { border: 0; background: var(--hcp-blue-50); color: var(--hcp-blue); font: inherit; font-size: 12.5px; font-weight: 700; padding: 4px 10px; border-radius: 99px; cursor: pointer; }

/* Samples */
.hcp-previews { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.hcp-pv { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--hcp-line); border-radius: 14px; background: #fff; cursor: pointer; text-align: left; font: inherit; transition: border-color .2s, box-shadow .2s; }
.hcp-pv:hover { border-color: #c7d6f5; box-shadow: 0 6px 18px rgba(31, 95, 224, .08); }
.hcp-pv__thumb { display: grid; place-items: center; width: 64px; height: 48px; border-radius: 10px; background: linear-gradient(135deg, #2f6fe8, #163c99); color: #fff; flex: none; }
.hcp-pv__t { display: flex; flex-direction: column; min-width: 0; }
.hcp-pv__t b { font-size: 14.5px; color: var(--hcp-ink); }
.hcp-pv__t small { color: var(--hcp-muted); font-size: 12.5px; }
.hcp-files { margin-top: 14px; border: 1px solid var(--hcp-line); border-radius: 14px; overflow: hidden; }
.hcp-files li { display: flex; align-items: center; gap: 12px; padding: 12px 16px; }
.hcp-files li + li { border-top: 1px solid var(--hcp-line); }
.hcp-pdf { display: grid; place-items: center; width: 38px; height: 44px; border-radius: 8px; background: #ffe9ec; color: #e5383b; font-size: 10px; font-weight: 800; flex: none; }
.hcp-files__t { flex: 1; min-width: 0; font-weight: 600; font-size: 14.5px; display: flex; flex-direction: column; }
.hcp-files__t small { font-weight: 400; color: var(--hcp-muted); font-size: 12.5px; }
.hcp-lock { display: inline-flex; align-items: center; gap: 6px; color: var(--hcp-muted); font-size: 12.5px; white-space: nowrap; }
.hcp-lock .hcp-i { width: 14px; height: 14px; }

/* Reviews */
.hcp-reviews { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 28px; align-items: start; }
.hcp-score { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 22px; border-radius: 16px; background: #fffaf0; border: 1px solid #fbeccb; }
.hcp-score > b { font-size: 44px; line-height: 1; color: var(--hcp-ink); }
.hcp-score .hcp-stars i { width: 18px; height: 18px; }
.hcp-score > small { color: var(--hcp-muted); }
.hcp-bars { width: 100%; display: grid; gap: 6px; margin-top: 8px; }
.hcp-bars div { display: grid; grid-template-columns: 26px 1fr 26px; gap: 8px; align-items: center; font-size: 12.5px; color: var(--hcp-muted); }
.hcp-bars i { height: 8px; border-radius: 99px; background: #eef1f5; overflow: hidden; }
.hcp-bars em { display: block; height: 100%; background: var(--hcp-star); border-radius: 99px; }
.hcp-bars div span:last-child { text-align: right; }
.hcp-rlist { display: grid; gap: 14px; }
.hcp-review { display: flex; gap: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--hcp-line); }
.hcp-review:last-child { border-bottom: 0; }
.hcp-ava { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg, #2f6fe8, #6a9bff); color: #fff; font-weight: 700; flex: none; }
.hcp-review__top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.hcp-review__top time { color: var(--hcp-muted); font-size: 12.5px; margin-left: auto; }
.hcp-review p { margin-top: 6px; color: #3a4a62; line-height: 1.65; white-space: pre-line; }

/* Catalog listing */
.hcp-cathead { padding: 8px 0 18px; }
.hcp-cathead h1 { font-size: 32px; line-height: 1.2; }
.hcp-cathead p { color: var(--hcp-muted); font-size: 16px; max-width: 680px; margin-top: 10px; line-height: 1.6; }
.hcp-catalog { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }

/* Others */
.hcp-others { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.hcp-card { display: flex; flex-direction: column; gap: 6px; padding: 12px; border: 1px solid var(--hcp-line); border-radius: 16px; transition: box-shadow .2s, transform .2s; background: #fff; }
.hcp-card:hover { box-shadow: 0 12px 28px rgba(2, 31, 71, .1); transform: translateY(-2px); }
.hcp-card__img { aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: linear-gradient(135deg, #2f6fe8, #163c99); display: grid; place-items: center; margin-bottom: 4px; }
.hcp-card__img img { width: 100%; height: 100%; object-fit: cover; }
.hcp-card__img i { color: #fff; font-style: normal; font-weight: 800; font-size: 22px; }
.hcp-card b { color: var(--hcp-ink); font-size: 16px; }
.hcp-card small { color: var(--hcp-muted); font-size: 13px; }
.hcp-card__price { color: var(--hcp-orange); font-weight: 800; margin-top: auto; }
.hcp-card__price s { color: #98a3b3; font-weight: 400; font-size: 13px; }
.hcp-card__meta { display: block; }
.hcp-card__rate { display: flex; align-items: center; gap: 6px; }
.hcp-card__rate .hcp-stars i { width: 13px; height: 13px; }
.hcp-card--more { background: #f7f9fd; }

/* CTA */
.hcp-cta { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 20px; padding: 30px 34px; border-radius: 20px; color: #fff; background: linear-gradient(110deg, #0b2a6b 0%, #1f4fb8 60%, #2f6fe8 100%); position: relative; overflow: hidden; }
.hcp-cta::after { content: ""; position: absolute; right: -60px; top: -80px; width: 260px; height: 260px; border-radius: 50%; background: rgba(255, 255, 255, .07); }
.hcp-cta h2 { font-size: 22px; color: #fff; }
.hcp-cta p { opacity: .85; margin-top: 4px; }
.hcp-cta .hcp-btn { position: relative; z-index: 1; flex: none; min-width: 170px; }

/* Floating cart, sticky bar, modal, toast */
.hcp-cartfab { position: fixed; right: 20px; bottom: 24px; z-index: 60; width: 56px; height: 56px; border-radius: 50%; background: var(--hcp-blue); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 26px rgba(31, 95, 224, .35); }
.hcp-cartfab[hidden] { display: none; }
.hcp-cartfab .hcp-i { width: 24px; height: 24px; }
.hcp-cartfab b { position: absolute; top: -2px; right: -2px; min-width: 22px; height: 22px; border-radius: 99px; background: var(--hcp-orange); font-size: 12px; display: grid; place-items: center; padding: 0 6px; border: 2px solid #fff; }
.hcp-bar { display: none; }
.hcp-modal { position: fixed; inset: 0; z-index: 2000; background: rgba(6, 14, 28, .78); display: grid; place-items: center; padding: 20px; }
.hcp-modal[hidden] { display: none; }
.hcp-modal__box { position: relative; width: min(960px, 100%); }
.hcp-modal__stage { aspect-ratio: 16 / 9; background: #000; border-radius: 14px; overflow: hidden; }
.hcp-modal__stage iframe, .hcp-modal__stage video { width: 100%; height: 100%; border: 0; display: block; }
.hcp-modal__x { position: absolute; right: 0; top: -46px; width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .15); color: #fff; display: grid; place-items: center; cursor: pointer; }
.hcp-toast { position: fixed; left: 50%; bottom: 28px; z-index: 2100; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; background: var(--hcp-ink); color: #fff; padding: 12px 18px; border-radius: 12px; font-size: 14px; box-shadow: 0 12px 30px rgba(0, 0, 0, .25); transition: opacity .2s, transform .2s; max-width: calc(100% - 32px); }
.hcp-toast.on { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.hcp-toast a { color: #ffb38f; font-weight: 700; margin-left: 6px; }

/* Buy page additions */
.hc-shop__card--cart { border-color: #c8962e33; }
.hc-shop__cart-line { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px dashed #e4e9f0; }
.hc-shop__cart-line strong { flex: 1; font-size: 15px !important; }
.hc-shop__cart-line b { color: #001f4d; }
.hc-shop__remove { font-size: 12.5px; color: #b42318; font-weight: 600; }
.hc-shop__more { margin-left: auto; font-size: 13px; font-weight: 700; color: #1f5fe0; }

@media (max-width: 1024px) {
  .hcp-hero { grid-template-columns: 1fr; }
  .hcp-intro, .hcp-reviews { grid-template-columns: 1fr; }
  .hcp-others, .hcp-catalog { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .hcp-wrap { width: calc(100% - 24px); }
  .hcp-hero { padding: 14px; gap: 18px; border-radius: 16px; }
  .hcp-summary h1 { font-size: 24px; }
  .hcp-media__art + .hcp-play,
  .hcp-media:hover .hcp-media__art + .hcp-play { top: auto; left: auto; right: 12px; bottom: 12px; transform: none; width: 52px; height: 52px; }
  .hcp-media__art + .hcp-play .hcp-i { width: 22px; height: 22px; }
  .hcp-price b { font-size: 26px; }
  .hcp-tabs a { padding: 12px 12px; font-size: 14px; }
  .hcp-section { padding: 18px; border-radius: 16px; scroll-margin-top: 120px; }
  .hcp-section h2 { font-size: 19px; }
  .hcp-stats b { font-size: 17px; }
  .hcp-ch__head { padding: 13px 14px; }
  .hcp-ch__list li { padding: 11px 14px; gap: 10px; font-size: 14px; }
  .hcp-lock { display: none; }
  .hcp-others, .hcp-catalog { grid-template-columns: 1fr; }
  .hcp-cathead h1 { font-size: 26px; }
  .hcp-cta { flex-direction: column; align-items: stretch; padding: 22px; }
  .hcp-cta .hcp-btn { width: 100%; }
  .hcp { padding-bottom: 90px; }
  .hcp-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 70; background: #fff; padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); box-shadow: 0 -6px 20px rgba(2, 31, 71, .1); }
  .hcp-bar b { color: var(--hcp-orange); font-size: 20px; font-weight: 800; display: block; line-height: 1.1; }
  .hcp-bar s { color: #98a3b3; font-size: 12.5px; }
  .hcp-bar .hcp-btn { height: 46px; flex: none; min-width: 132px; }
  .hcp-cartfab { bottom: calc(86px + env(safe-area-inset-bottom, 0px)); right: 14px; width: 50px; height: 50px; }
  .hcp-toast { bottom: calc(90px + env(safe-area-inset-bottom, 0px)); }
}

@media (max-width: 400px) {
  .hcp-wrap { width: calc(100% - 20px); }
  .hcp-summary h1 { font-size: 22px; }
  .hcp-bar { flex-wrap: wrap; }
  .hcp-bar .hcp-btn { width: 100%; min-width: 0; }
}
