/* ══════════════════════════════════════════════════════════════
   Single Course Template – single-course.css
   ══════════════════════════════════════════════════════════════ */

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --brand-green: #8cb849;
  --brand-green-hover: #7ea342;
  --bg-yellow: #fdedc6;
  --text-dark: #1f1f1f;
  --text-gray: #666;
  --radius-card: 12px;
  --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.07);
}
.single-course-main .cds-cpt-social-container {
  justify-content: flex-end;
}
/* ── 1. HERO ───────────────────────────────────────────────── */
.course-hero {
  position: relative;
  width: 100%;
  min-height: 460px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 150px 20px 100px; /* bottom padding extra để container overlap */
}
.course-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.25) 0%,
    rgba(0, 0, 0, 0.72) 100%
  );
}
.course-hero-content {
  position: relative;
  z-index: 2;
  color: #fff;
  max-width: 820px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

a.hero-label {
  font-size: 12px;
  color: #fff;
  letter-spacing: 3px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 8px;
  opacity: 0.85;
}
.hero-title {
  font-size: clamp(2.4rem, 6vw, 4.8rem);
  color: #fff;
  font-weight: 400;
  margin: 0 0 10px;
  line-height: 1.05;
  text-shadow: 2px 4px 16px rgba(0, 0, 0, 0.35);
}
.hero-meta {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1.5px;
  margin-bottom: 22px;
  text-transform: uppercase;
  opacity: 0.9;
}

/* Badges row */
.hero-badges {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
  background: rgba(255, 255, 255, 0.18);
  padding: 8px 22px;
  border-radius: 50px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.badge-software {
  display: flex;
  align-items: center;
  gap: 6px;
}
.badge-software .sw-icon {
  width: 26px;
  height: 26px;
  border-radius: 5px;
  object-fit: contain;
}
.badge-price {
  font-weight: 800;
  font-size: 15px;
  padding-left: 14px;
  border-left: 1px solid rgba(255, 255, 255, 0.4);
}

/* Level icons override – đảm bảo hiển thị trong hero */
.badge-level .cds-level-icons {
  display: flex;
  align-items: flex-end;
  gap: 3px;
}
.badge-level .cds-level__icon {
  opacity: 0.35;
  filter: grayscale(1);
}
.badge-level .cds-level__icon.on {
  opacity: 1;
  filter: none;
}

/* Slots */
.hero-slots-wrapper {
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.slots-icons {
  display: flex;
  gap: 10px;
  justify-content: center;
}
.slot-item {
  color: #fff;
  opacity: 0.35;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.slot-item.is-filled {
  opacity: 1;
}

.slots-text {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

/* CTA */
.hero-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}
.action-note {
  font-size: 12px;
  margin-top: 8px;
  opacity: 0.75;
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--brand-green);
  color: #fff !important;
  padding: 12px 26px;
  border-radius: 30px;
  font-weight: 800;
  text-decoration: none !important;
  transition:
    background 0.25s,
    transform 0.15s;
  font-size: 13px;
  letter-spacing: 0.5px;
}
.btn-primary:hover {
  background-color: var(--brand-green-hover);
  transform: translateY(-1px);
}
.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: transparent;
  border: 2px solid var(--text-dark);
  color: var(--text-dark) !important;
  padding: 10px 20px;
  border-radius: 30px;
  font-weight: 800;
  text-decoration: none !important;
  transition: all 0.25s;
  font-size: 13px;
}
.btn-secondary:hover {
  background-color: var(--text-dark);
  color: #fff !important;
}

/* ── 2. MAIN LAYOUT ────────────────────────────────────────── */
.course-container {
  max-width: 1120px;
  margin: -50px auto 70px;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 1fr 370px;
  gap: 28px;
  position: relative;
  z-index: 10;
}
@media (max-width: 920px) {
  .course-container {
    grid-template-columns: 1fr;
    margin-top: 20px;
  }
}

/* ── 3. CONTENT LEFT ───────────────────────────────────────── */
.course-content-left {
  background-color: var(--bg-yellow);
  padding: 38px 42px;
  border-radius: var(--radius-card);
  color: var(--text-dark);
  box-shadow: var(--shadow-card);
}

.course-content-left li,
.course-content-left p {
  font-size: 1rem;
}
.course-section {
  margin-bottom: 36px;
}
.course-section:last-child {
  margin-bottom: 0;
}

.section-title {
  font-size: 28px;
  font-weight: 900;
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Custom lists */
.custom-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.custom-list li {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 10px;
  font-size: 15px;
  line-height: 1.6;
}

.list-check ul,
.entry-content.list-check ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.list-check ul li,
.entry-content.list-check ul li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 9px;
  font-size: 15px;
  line-height: 1.6;
}
.list-check ul li::before,
.entry-content.list-check ul li::before {
  content: '✓';
  position: absolute;
  left: 0;
  font-weight: 900;
  color: var(--brand-green);
}

/* Target audience bold label */
.entry-content strong {
  display: block;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 4px;
}

/* Teacher */
.teacher-profile {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.teacher-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.teacher-name {
  margin: 0 0 3px;
  font-size: 18px;
  font-weight: 900;
  text-transform: uppercase;
}
.teacher-role {
  font-size: 11px;
  color: var(--text-gray);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.teacher-quote {
  font-style: italic;
  font-size: 14.5px;
  line-height: 1.7;
  color: #444;
  border-left: 3px solid var(--brand-green);
  padding-left: 14px;
  margin-top: 4px;
}

/* ── 4. SIDEBAR ────────────────────────────────────────────── */
.course-sidebar-right {
  /* sticky wrapper */
}
.sidebar-box {
  background-color: var(--bg-yellow);
  padding: 18px;
  border-radius: var(--radius-card);
  position: sticky;
  top: 28px;
  box-shadow: var(--shadow-card);
}

/* Gallery / single thumbnail */
.sidebar-image-wrap {
  position: relative;
  margin-bottom: 16px;
  border-radius: 8px;
  overflow: hidden;
}
.sidebar-image-wrap > img {
  width: 100%;
  height: auto;
  display: block;
}

/* Gallery grid: 3 ảnh – 2 nhỏ ở dưới */
.sidebar-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}
.sidebar-gallery .gallery-thumb {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}
.sidebar-gallery .gallery-thumb:first-child {
  grid-column: span 3;
  aspect-ratio: 16 / 9;
}

.sidebar-price {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(140, 184, 73, 0.9);
  color: #fff;
  padding: 5px 14px;
  border-radius: 20px;
  font-weight: 800;
  font-size: 14px;
}

/* Action buttons */
.sidebar-actions {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}
.sidebar-btn {
  flex: 1;
  justify-content: center;
  padding: 10px 6px;
  font-size: 12px;
  text-align: center;
}
.sidebar-btn i {
  font-size: 1rem;
}
.sidebar-note {
  font-size: 11px;
  text-align: center;
  color: var(--text-gray);
  margin: 0 0 16px;
}

/* Schedule */
.sidebar-schedule {
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  padding: 14px 0;
  margin-bottom: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.schedule-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
}
.schedule-item svg {
  flex-shrink: 0;
  margin-top: 1px;
  color: var(--text-dark);
}

/* Location */
.sidebar-location {
  font-size: 12.5px;
  line-height: 1.65;
  margin-bottom: 16px;
  color: var(--text-dark);
}
.sidebar-location strong {
  display: inline;
  font-weight: 800;
}
.sidebar-location a {
  color: var(--text-dark);
  text-decoration: underline;
  word-break: break-all;
}

/* Social Icons */
.sidebar-social {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}
.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.08);
  color: var(--text-dark);
  text-decoration: none;
  transition:
    background 0.2s,
    transform 0.15s;
}
.social-btn:hover {
  background: var(--brand-green);
  color: #fff;
  transform: translateY(-2px);
}
.social-btn svg {
  display: block;
}

/* ── 5. RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 600px) {
  .course-content-left {
    padding: 24px 20px;
  }
  .hero-badges {
    flex-wrap: wrap;
    border-radius: 16px;
  }
  .sidebar-actions {
    flex-direction: column;
  }
  .sidebar-btn {
    width: 100%;
  }
}
