/* Course detail — sidebar | center | right rail (bundle + info cards) */
.cd-page.course-detail-layout {
  padding: 24px 16px 48px;
}

@media (min-width: 1024px) {
  .cd-page.course-detail-layout {
    padding: 24px 16px 48px;
  }
}

.cd-page {
  background: #f8fafc;
}

.cd-wrap {
  max-width: 1320px;
  margin: 0 auto;
}

.cd-grid {
  display: grid;
  grid-template-columns: minmax(300px, 320px) minmax(0, 1fr) minmax(300px, 340px);
  gap: 28px;
  align-items: start;
}

/* Legacy inline/course.css .content-area padding pushed center column down — align all columns at top */
.cd-page .cd-center.content-area {
  padding: 0 !important;
  overflow: visible;
}

.cd-page .cd-grid > .cd-sidebar,
.cd-page .cd-grid > .cd-center,
.cd-page .cd-grid > .cd-rail {
  margin-top: 0;
  align-self: start;
}

.cd-page .cd-hero-image-wrap,
.cd-page .course-detail-image-container {
  margin-top: 0;
}

.cd-page .cd-sidebar-header.course-header {
  padding-top: 0 !important;
}

@media (max-width: 1100px) {
  .cd-grid {
    grid-template-columns: 1fr;
  }

  .cd-rail {
    order: 3;
  }

  .cd-center {
    order: 2;
  }

  .cd-sidebar {
    order: 1;
  }
}

/* Floating "back to course list" button — mobile only (see the 1100px reorder above, which is
   the same breakpoint where the course list sits above the course content instead of beside
   it). Hidden entirely above that width; the sidebar is already visible in its own column
   there, so jumping "up to it" wouldn't mean anything. */
.cd-back-to-list-btn {
  display: none;
}

@media (max-width: 1100px) {
  /* Clicking a course in the mobile list scrolls #cdCourseContent flush to the viewport top
     (see initMobileCourseNavScroll() in js/course-detail.js) — but the fixed 70px .navbar
     (style.css) sits on top of that, cropping the course title underneath it. scroll-margin-top
     stops short of the bar instead of scrolling all the way to the true top. */
  #cdCourseContent {
    scroll-margin-top: 86px;
  }

  .cd-back-to-list-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    right: 18px;
    bottom: 24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    background: var(--accent-green, #2ecc71);
    color: #ffffff;
    font-size: 1.1rem;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.25);
    cursor: pointer;
    z-index: 900;
    opacity: 0;
    pointer-events: none;
    transform: translateY(8px);
    transition: opacity 0.2s ease, transform 0.2s ease;
  }

  .cd-back-to-list-btn.is-visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }
}

/* Left sidebar */
.cd-page .cd-sidebar.sidebar {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 20px 18px;
  position: sticky;
  top: 88px;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.cd-sidebar-header {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e2e8f0;
  width: 100%;
}

/* Override legacy course-detail.php inline .course-header h1 (42px) */
.cd-page .cd-sidebar-header.course-header {
  padding-top: 0;
  padding-bottom: 0;
  text-align: center;
}

.cd-page .cd-sidebar-header.course-header h1 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.375rem;
  font-weight: 700;
  color: #0f2e46;
  margin: 0 auto 10px;
  line-height: 1.3;
  letter-spacing: -0.02em;
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: normal;
  hyphens: none;
  max-width: 100%;
  text-align: center;
}

.cd-page .cd-sidebar-header .price-tag.course-price-section {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 14px;
  letter-spacing: 0;
  justify-content: center;
}

.cd-sidebar-header h1 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.375rem;
  font-weight: 700;
  color: #0f2e46;
  margin: 0 0 10px;
  line-height: 1.3;
}

.cd-sidebar-header .course-price-section {
  margin-bottom: 14px;
  width: 100%;
}

.cd-sidebar-header .course-price-section #coursePrice {
  font-size: 1.375rem;
  font-weight: 700;
  color: #0f2e46;
}

.cd-sidebar-header .old-price,
.cd-page .cd-sidebar-header .price-tag .old-price {
  font-size: 1rem;
  color: #94a3b8;
  text-decoration: line-through;
  margin-left: 8px;
}

.cd-sidebar-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.cd-sidebar-actions .btn-enroll-header,
.cd-sidebar-actions .btn-cart-header {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  justify-content: center;
  padding: 12px 16px;
  font-size: 0.9375rem;
  flex-wrap: nowrap;
}

.cd-page .sidebar {
  width: 100%;
  min-width: 0;
  padding-right: 4px;
  box-sizing: border-box;
  overflow: visible;
}

.cd-page .cd-sidebar.sidebar {
  overflow: visible;
}

.cd-page .sidebar-content,
.cd-page .course-list {
  width: 100%;
  max-height: none;
  overflow: visible;
}

.cd-page .sidebar h3 {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #64748b;
  margin: 16px 0 10px;
}

.cd-page .course-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Bundle groups — course detail left sidebar only */
.cd-page .cd-sidebar-groups {
  gap: 8px;
}

.cd-page .cd-bundle-group {
  border: 1px solid #bbf7d0;
  border-left: 4px solid var(--accent-green, #2ecc71);
  border-radius: 10px;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(22, 163, 74, 0.08);
}

.cd-page .cd-bundle-group__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 13px 14px;
  border: none;
  background: #f0fdf4;
  color: #15803d;
  font-family: 'Rethink Sans', Helvetica, sans-serif;
  font-size: 1rem;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
  border-bottom: 1px solid #bbf7d0;
}

.cd-page .cd-bundle-group__header:hover {
  background: #dcfce7;
}

.cd-page .cd-bundle-group__title-wrap {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.cd-page .cd-bundle-group__title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  line-height: 1.35;
  letter-spacing: 0.01em;
  font-size: 1.02rem;
  font-weight: 800;
  color: #15803d;
}

.cd-page .cd-bundle-group__icon {
  flex-shrink: 0;
  font-size: 0.95rem;
  color: var(--accent-green, #2ecc71);
}

.cd-page .cd-bundle-group__meta {
  font-size: 0.72rem;
  font-weight: 600;
  color: #16a34a;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding-left: 1.55rem;
}

.cd-page .cd-bundle-group__chevron {
  flex-shrink: 0;
  font-size: 0.75rem;
  color: var(--accent-green, #2ecc71);
  transition: transform 0.2s ease;
}

.cd-page .cd-bundle-group.is-expanded .cd-bundle-group__chevron {
  transform: rotate(180deg);
}

.cd-page .cd-bundle-group__courses {
  display: none;
  flex-direction: column;
  gap: 6px;
  padding: 10px 12px 12px 20px;
  margin: 0 8px 8px;
  border-left: 2px solid #86efac;
  border-radius: 0 0 8px 8px;
  background: #fafdfb;
}

.cd-page .cd-bundle-group.is-expanded .cd-bundle-group__courses {
  display: flex;
}

/* Mobile / tablet: show bundle courses when “All Courses” panel is open */
@media (max-width: 1024px) {
  .cd-page .sidebar-content.active.cd-sidebar-groups,
  .cd-page .sidebar-content.active.course-list {
    overflow: visible;
    max-height: none;
  }

  .cd-page .sidebar-content.active .cd-bundle-group {
    display: block;
    margin-bottom: 8px;
  }

  .cd-page .sidebar-content.active .cd-bundle-group.is-expanded .cd-bundle-group__courses {
    display: flex !important;
  }
}

.cd-page .cd-bundle-group__courses .course-btn {
  font-size: 0.78rem;
  padding: 8px 10px;
}

.cd-page .course-btn {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 0.8125rem;
  text-decoration: none;
  color: #334155;
  background: #f1f5f9;
  border: none;
  transition: background 0.15s;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  text-align: left;
}

.cd-page .course-btn .cd-side-icon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e2e8f0;
  flex-shrink: 0;
  font-size: 0.75rem;
}

.cd-page .course-btn.active {
  background: #003366;
  color: #fff;
}

.cd-page .course-btn.active .cd-side-icon {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.cd-side-label {
  flex: 1;
  min-width: 0;
  line-height: 1.35;
  word-break: normal;
  overflow-wrap: break-word;
}

/* Center column */
.cd-center {
  min-width: 0;
}

.cd-center .cd-cards-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 20px;
}

/* Outcome + Tools Used — side by side; content stacks vertically in each card */
.cd-outcome-tools-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  align-items: stretch;
  width: 100%;
}

.cd-outcome-tools-row .cd-info-card {
  height: 100%;
  min-width: 0;
}

.cd-outcome-tools-row:has(> :only-child) {
  grid-template-columns: 1fr;
}

@media (max-width: 720px) {
  .cd-outcome-tools-row {
    grid-template-columns: 1fr;
  }
}

.cd-hero-image-wrap {
  margin-bottom: 20px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
}

.cd-hero-image-wrap img {
  width: 100%;
  height: auto;
  display: block;
}

.cd-how {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 22px;
  margin-bottom: 20px;
}

.cd-how-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.25rem;
  margin: 0 0 18px;
  color: #0f172a;
}

.cd-how-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

@media (max-width: 700px) {
  .cd-how-steps {
    grid-template-columns: 1fr 1fr;
  }
}

.cd-how-step {
  text-align: center;
  position: relative;
}

.cd-how-num {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #003366;
  color: #fff;
  font-weight: 700;
  font-size: 0.875rem;
  margin-bottom: 8px;
}

.cd-how-step h4 {
  font-size: 0.8125rem;
  margin: 0 0 4px;
  color: #0f172a;
}

.cd-how-step p {
  font-size: 0.75rem;
  color: #64748b;
  margin: 0;
  line-height: 1.4;
}

.cd-grid.cd-grid--no-rail {
  grid-template-columns: minmax(300px, 320px) minmax(0, 1fr);
}

@media (max-width: 1100px) {
  .cd-grid.cd-grid--no-rail {
    grid-template-columns: 1fr;
  }
}

/* Right rail */
.cd-rail {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: 88px;
}

.cd-rail.cd-rail--hidden {
  display: none;
}

/* Enrolled panel — right rail (replaces bundle card when user has access) */
.cd-rail .cd-enrolled-rail-card {
  width: 100%;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
}

.cd-rail .cd-enrolled-rail-card__inner {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  box-sizing: border-box;
  padding: 22px;
  border-radius: 16px;
  border: 1px solid #c5e8e4;
  background: linear-gradient(165deg, #ffffff 0%, #f0fdfa 100%);
  box-shadow: 0 4px 24px rgba(0, 138, 138, 0.12);
}

.cd-rail .cd-enrolled-rail-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  padding: 8px 4px 4px;
}

.cd-rail .cd-enrolled-rail-icon.access-icon-wrapper {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(145deg, #00c4ff 0%, #008a8a 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(0, 138, 138, 0.35);
}

.cd-rail .cd-enrolled-rail-icon i {
  font-size: 1.75rem;
  color: #fff;
}

.cd-rail .cd-enrolled-rail-eyebrow {
  margin: 0 0 6px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #008a8a;
}

.cd-rail .cd-enrolled-rail-card .access-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.375rem;
  font-weight: 700;
  color: #0f2e46;
  margin: 0 0 6px;
  line-height: 1.2;
}

.cd-rail .cd-enrolled-rail-card .access-subtitle {
  margin: 0;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #059669;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.cd-rail .cd-enrolled-rail-card .access-description {
  margin: 0;
  padding: 0;
  font-size: 0.875rem;
  line-height: 1.55;
  color: #64748b;
  text-align: center;
}

.cd-rail .cd-enrolled-rail-cta.access-course-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  margin: 0;
  padding: 14px 18px;
  border: none;
  border-radius: 12px;
  font-size: 0.9375rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #008a8a 0%, #006f6f 100%);
  box-shadow: 0 6px 16px rgba(0, 138, 138, 0.28);
  cursor: pointer;
  text-transform: none;
  letter-spacing: 0.01em;
}

.cd-rail .cd-enrolled-rail-cta.access-course-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0, 138, 138, 0.36);
}

@media (max-width: 1100px) {
  .cd-rail .cd-enrolled-rail-card {
    order: 3;
  }
}

/* Bundle card */
.cd-bundle-card.bundle-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 22px;
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
  margin: 0;
}

.cd-bundle-card::before {
  display: none;
}

.cd-bundle-badge {
  display: inline-block;
  padding: 4px 10px;
  background: #059669;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  border-radius: 4px;
  margin-bottom: 10px;
}

.cd-bundle-card h2.pricing-card-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.35rem;
  margin: 0 0 6px;
  color: #0f172a;
}

.cd-bundle-card .bundle-sub {
  font-size: 0.8125rem;
  color: #64748b;
  margin: 0 0 14px;
}

.cd-bundle-card .bundle-price {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 12px;
  margin-bottom: 16px;
}

.cd-bundle-card .big-price {
  font-size: 2rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1;
}

.cd-bundle-card .big-price .currency-symbol {
  font-size: 1.25rem;
}

.cd-bundle-card .strike-price .currency-symbol {
  font-size: 0.875rem;
}

.cd-bundle-card .strike-price {
  color: #94a3b8;
  text-decoration: line-through;
  font-size: 0.9375rem;
}

.cd-bundle-card .limited-tag {
  display: inline-block;
  padding: 4px 10px;
  background: #f97316;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  border-radius: 999px;
}

.cd-features-list {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
}

.cd-features-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-family: "Inter", "Rethink Sans", system-ui, sans-serif;
  font-size: 0.8125rem;
  font-weight: 400;
  color: #334155;
  margin-bottom: 10px;
  line-height: 1.45;
}

.cd-features-list .cd-feature-text {
  font-family: inherit;
  font-size: inherit;
  font-weight: 400;
  line-height: inherit;
}

.cd-features-list .cd-feature-text strong {
  font-weight: 700;
  color: #1e293b;
}

.cd-features-list li i {
  color: #059669;
  margin-top: 3px;
  flex-shrink: 0;
}

.cd-bundle-card .btn-green {
  width: 100%;
  padding: 14px 20px;
  background: #059669;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.9375rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 10px;
  text-decoration: none;
  box-sizing: border-box;
}

.cd-bundle-card .btn-green:hover {
  background: #047857;
}

.cd-bundle-card .cd-btn-single {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px 20px;
  background: #fff;
  color: #0f172a;
  border: 1px solid #cbd5e1;
  text-decoration: none;
  box-sizing: border-box;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
}

.cd-bundle-card .cd-btn-single:hover {
  background: #f8fafc;
}

/* Info cards grid (image 3) */
.cd-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.cd-info-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 18px;
  margin: 0;
  font-family: "Rethink Sans", "Inter", Helvetica, sans-serif;
}

/* Unified typography — Key Takeaway, Example, Use Cases, Outcome, Tools Used */
.cd-page .cd-info-card .card-header,
.cd-page .cd-info-card .section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: "Rethink Sans", "Inter", Helvetica, sans-serif;
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.01em;
  color: #0f172a;
  margin: 0 0 12px;
  border: none;
  padding: 0;
}

.cd-page .cd-info-card .card-header i,
.cd-page .cd-info-card .section-title i {
  font-size: 1rem;
  width: 1.125rem;
  text-align: center;
  flex-shrink: 0;
}

.cd-page .cd-info-card .cd-info-card__body,
.cd-page .cd-info-card .cd-info-card__body p,
.cd-page .cd-info-card .cd-info-card__body li,
.cd-page .cd-info-card .cd-info-card__body span,
.cd-page .cd-info-card .cd-tools-sub.cd-info-card__body {
  font-family: "Rethink Sans", "Inter", Helvetica, sans-serif !important;
  font-size: 15px !important;
  font-weight: 400 !important;
  line-height: 1.65 !important;
  letter-spacing: 0.01em !important;
  color: #475569 !important;
}

.cd-page .cd-info-card .cd-info-card__body *:not(i):not(svg):not(path):not(img) {
  font-family: inherit !important;
  font-size: inherit !important;
  font-weight: inherit !important;
  font-style: normal !important;
  line-height: inherit !important;
  letter-spacing: inherit !important;
  color: inherit !important;
}

.cd-page .cd-info-card .cd-info-card__body strong,
.cd-page .cd-info-card .cd-info-card__body b {
  font-weight: 600 !important;
}

.cd-page .cd-info-card .cd-info-card__body.ql-editor,
.cd-page .cd-info-card .cd-info-card__body.text-block {
  margin: 0;
}

.cd-page .cd-info-card .cd-info-card__body.ql-editor p,
.cd-page .cd-info-card .cd-info-card__body.ql-editor li {
  margin: 0 0 0.65em;
}

.cd-page .cd-info-card .cd-info-card__body.ql-editor p:last-child,
.cd-page .cd-info-card .cd-info-card__body.ql-editor li:last-child {
  margin-bottom: 0;
}

/* Legacy selectors — keep in sync with cd-info-card__body */
.cd-page .cd-info-card .ql-editor,
.cd-page .cd-info-card .text-block,
.cd-page .cd-info-card .use-cases li,
.cd-page .cd-info-card .use-cases li span,
.cd-page .cd-info-card .cd-tools-sub {
  font-family: "Rethink Sans", "Inter", Helvetica, sans-serif;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.65;
  letter-spacing: 0.01em;
  color: #475569;
}

.cd-page .cd-info-card .ql-editor,
.cd-page .cd-info-card .text-block {
  margin: 0;
}

.cd-page .cd-info-card .ql-editor p,
.cd-page .cd-info-card .text-block p,
.cd-page .cd-info-card .ql-editor li,
.cd-page .cd-info-card .text-block li {
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
  margin: 0 0 0.65em;
}

.cd-page .cd-info-card .ql-editor p:last-child,
.cd-page .cd-info-card .text-block p:last-child,
.cd-page .cd-info-card .ql-editor li:last-child,
.cd-page .cd-info-card .text-block li:last-child {
  margin-bottom: 0;
}

.cd-page .cd-info-card .ql-editor [class*="ql-font-"],
.cd-page .cd-info-card .text-block [class*="ql-font-"],
.cd-page .cd-info-card .use-cases li [class*="ql-font-"],
.cd-page .cd-info-card .cd-info-card__body [class*="ql-font-"] {
  font-family: inherit !important;
}

.cd-page .cd-info-card .ql-editor [class*="ql-size-"],
.cd-page .cd-info-card .text-block [class*="ql-size-"],
.cd-page .cd-info-card .cd-info-card__body [class*="ql-size-"] {
  font-size: inherit !important;
}

.cd-info-card.bg-blue-light {
  background: #f8fafc;
}

.cd-info-card.bg-orange-light {
  background: #fff7ed;
  border-color: #fed7aa;
}

.cd-page .cd-info-card .use-cases li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 8px;
}

.cd-page .cd-info-card .use-cases li:last-child {
  margin-bottom: 0;
}

.cd-page .cd-info-card .use-cases li span {
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
}

.cd-page .cd-info-card .use-cases .icon-check,
.cd-page .cd-info-card .use-cases li i.fa-check {
  color: #059669;
  flex-shrink: 0;
  margin-top: 3px;
  font-size: 0.9375rem;
}

.cd-tools-card .cd-tools-sub {
  margin: 0 0 10px;
  color: #64748b;
}

.cd-page .cd-info-card .use-cases {
  list-style: none;
  margin: 0;
  padding: 0;
}

.cd-tools-card .use-cases li {
  background: #f1f5f9;
  border-radius: 999px;
  padding: 6px 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 6px 6px 0;
  width: auto;
}

.cd-tools-card .use-cases li .cd-tool-icon {
  color: #9333ea;
  flex-shrink: 0;
  font-size: 0.9375rem;
}

.cd-tools-card .use-cases li .cd-tool-icon-img {
  width: 1.25rem;
  height: 1.25rem;
  max-width: 32px;
  max-height: 32px;
  object-fit: contain;
  flex-shrink: 0;
  display: block;
}

@media (min-width: 768px) {
  .cd-tools-card .use-cases li .cd-tool-icon-img {
    width: 1.5rem;
    height: 1.5rem;
  }
}

@media (max-width: 480px) {
  .cd-page .cd-info-card .card-header,
  .cd-page .cd-info-card .section-title {
    font-size: 1rem;
  }

  .cd-page .cd-info-card .cd-info-card__body,
  .cd-page .cd-info-card .cd-info-card__body p,
  .cd-page .cd-info-card .cd-info-card__body li,
  .cd-page .cd-info-card .cd-info-card__body span,
  .cd-page .cd-info-card .cd-tools-sub.cd-info-card__body,
  .cd-page .cd-info-card .ql-editor,
  .cd-page .cd-info-card .text-block,
  .cd-page .cd-info-card .use-cases li,
  .cd-page .cd-info-card .use-cases li span,
  .cd-page .cd-info-card .cd-tools-sub,
  .cd-page .cd-info-card .use-cases .icon-check,
  .cd-page .cd-info-card .use-cases li i.fa-check,
  .cd-tools-card .use-cases li .cd-tool-icon {
    font-size: 14px;
  }
}

/* Enrolled banner */
.cd-enrolled-banner.course-access-section {
  background: linear-gradient(90deg, #ecfdf5, #f0fdf4);
  border: 1px solid #bbf7d0;
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 20px;
}

.cd-enrolled-banner .access-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  background: transparent;
  border: none;
  padding: 0;
  box-shadow: none;
}

.cd-enrolled-banner .access-title {
  color: #047857;
  margin: 0;
}

.cd-enrolled-banner .access-course-button {
  background: #059669;
  color: #fff;
  border: none;
  padding: 12px 20px;
  border-radius: 10px;
  font-weight: 700;
  cursor: pointer;
}

.cd-footer-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 28px;
  padding: 20px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
}

@media (max-width: 900px) {
  .cd-footer-bar {
    grid-template-columns: 1fr 1fr;
  }
}

.cd-footer-item {
  text-align: center;
}

.cd-footer-item i {
  color: #059669;
  font-size: 1.25rem;
  margin-bottom: 6px;
}

.cd-footer-item strong {
  display: block;
  font-size: 0.875rem;
}

.cd-footer-item span {
  font-size: 0.75rem;
  color: #64748b;
}

/* Hide legacy duplicates */
.cd-page > .layout-wrapper > .course-header,
.cd-center .bundle-card:not(.cd-bundle-card),
.cd-center .purchase-card {
  display: none !important;
}

.cd-hooks-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

/* Masterclass hero — text-only professional card (course detail page) */
.cd-masterclass-hero.course-hero {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: clamp(1rem, 2.5vw, 1.5rem) clamp(1rem, 3vw, 1.5rem);
  background: #eef1f4;
  box-sizing: border-box;
}

.cd-masterclass-hero .course-hero-shell {
  max-width: 1320px;
  margin: 0 auto;
}

.cd-masterclass-hero--text-only .course-hero-card {
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  box-shadow:
    0 1px 2px rgba(15, 39, 68, 0.04),
    0 8px 32px rgba(15, 39, 68, 0.07);
}

.cd-masterclass-hero--text-only .course-hero-container {
  grid-template-columns: minmax(0, 1fr);
  min-height: 0;
}

.cd-masterclass-hero--text-only .course-hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: clamp(1.75rem, 4.5vw, 3rem) clamp(1.5rem, 4vw, 3rem);
  max-width: 52rem;
  margin: 0 auto;
  width: 100%;
  gap: 0;
}

.cd-masterclass-hero--text-only .course-hero-image {
  display: none;
}

.cd-masterclass-hero--text-only .course-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: clamp(1rem, 2.5vw, 1.25rem);
  padding: 0.5rem 0.875rem;
  background: #ecfdf5;
  color: #047857;
  border: 1px solid rgba(5, 150, 105, 0.14);
  border-radius: 999px;
  font-family: "Rethink Sans", "Inter", system-ui, sans-serif;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  line-height: 1.3;
}

.cd-masterclass-hero--text-only .course-hero-badge i {
  font-size: 0.75rem;
  color: #059669;
}

.cd-masterclass-hero--text-only .course-hero-title {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: "Playfair Display", Georgia, "Times New Roman", serif;
  font-size: clamp(1.75rem, 4.2vw, 2.5rem);
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: -0.025em;
  color: #0f2744;
  margin: 0 auto clamp(1rem, 2.2vw, 1.35rem);
  gap: 0.15em;
  width: 100%;
  max-width: 44rem;
  text-align: center;
  text-wrap: balance;
}

.cd-masterclass-hero--text-only .course-hero-title-line {
  display: block;
  width: 100%;
  text-align: center;
  text-wrap: balance;
}

.cd-masterclass-hero--text-only .course-hero-title-line--sub {
  margin-top: 0;
  font-size: 0.92em;
  line-height: 1.28;
  text-wrap: balance;
}

.cd-masterclass-hero--text-only .course-hero-title-accent {
  color: #16a34a;
  font-weight: 700;
}

.cd-masterclass-hero--text-only .course-hero-description-accent {
  display: block;
  color: #16a34a;
  font-weight: 600;
  line-height: 1.45;
  max-width: 34rem;
  text-wrap: balance;
}

.cd-masterclass-hero--text-only .course-hero-description-lead {
  display: block;
  color: #5c6b7a;
  line-height: 1.7;
  max-width: 40rem;
  text-wrap: pretty;
}

.cd-masterclass-hero--text-only .course-hero-description {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  font-family: "Rethink Sans", "Inter", system-ui, sans-serif;
  font-size: clamp(1rem, 1.35vw, 1.125rem);
  font-weight: 400;
  line-height: 1.7;
  color: #5c6b7a;
  margin: 0 auto;
  max-width: 42rem;
  width: 100%;
  text-align: center;
}

.cd-masterclass-hero + .cd-page.course-detail-layout {
  padding-top: clamp(0.75rem, 2vw, 1.25rem);
}

@media (max-width: 480px) {
  .cd-masterclass-hero--text-only .course-hero-content {
    padding: 1.5rem 1.25rem;
  }

  .cd-masterclass-hero--text-only .course-hero-badge {
    font-size: 0.625rem;
    padding: 0.4375rem 0.75rem;
    letter-spacing: 0.08em;
  }

  .cd-masterclass-hero--text-only .course-hero-title {
    font-size: clamp(1.5rem, 6.5vw, 1.875rem);
  }
}

@media (min-width: 768px) {
  .cd-masterclass-hero--text-only .course-hero-description {
    font-size: 1.0625rem;
  }
}

/* Override course.css hero alignment — always centered on detail page */
.cd-masterclass-hero.cd-masterclass-hero--text-only .course-hero-content,
.cd-masterclass-hero.cd-masterclass-hero--text-only .course-hero-title {
  align-items: center;
  text-align: center;
}

.cd-masterclass-hero.cd-masterclass-hero--text-only .course-hero-title-line,
.cd-masterclass-hero.cd-masterclass-hero--text-only .course-hero-title-line--sub,
.cd-masterclass-hero.cd-masterclass-hero--text-only .course-hero-title-accent {
  text-align: center;
}

/* Dynamic showcase block (course title + highlights + how-it-works) */
.cd-showcase-block {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 20px 22px;
  margin: 14px 0;
}

.cd-showcase-block--top {
  margin-bottom: 12px;
  text-align: center;
}

.cd-showcase-block--how {
  margin-top: 18px;
  margin-bottom: 22px;
  border: none;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.cd-showcase-title {
  margin: 0 auto;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.45rem, 1.9vw, 2.1rem);
  color: #0f2e46;
  line-height: 1.16;
  letter-spacing: -0.01em;
  text-align: center;
}

.cd-showcase-subtitle {
  margin-top: 10px;
  margin-left: auto;
  margin-right: auto;
  display: flex;
  flex-direction: column;
  gap: 0.2em;
  color: #243447;
  font-size: clamp(0.9rem, 1vw, 1rem);
  line-height: 1.5;
  max-width: 760px;
  text-align: center;
  align-items: center;
}

.cd-showcase-subtitle p {
  margin: 0;
}

.cd-showcase-subtitle__lead,
.cd-showcase-subtitle__accent {
  display: block;
}

.cd-showcase-subtitle__lead {
  color: #1e3a5f;
}

.cd-showcase-subtitle__accent {
  color: #16a34a;
  font-weight: 600;
}

.cd-showcase-highlights {
  margin-top: 16px;
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cd-showcase-highlight-item {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
}

.cd-showcase-highlight-item i {
  color: #475569;
  margin-top: 2px;
  font-size: 0.98rem;
}

.cd-showcase-highlight-item h4 {
  margin: 0;
  font-size: 0.92rem;
  color: #0f2e46;
  font-weight: 700;
  line-height: 1.25;
}

.cd-showcase-highlight-item p {
  margin: 3px 0 0;
  font-size: 0.82rem;
  color: #475569;
  line-height: 1.35;
}

.cd-showcase-how {
  margin-top: 0;
  overflow: visible;
}

.cd-showcase-block--how {
  overflow: visible;
}

.cd-showcase-how h3 {
  margin: 0 0 16px;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.28rem, 1.45vw, 1.55rem);
  color: #0f2e46;
  text-transform: none;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.cd-showcase-how-grid {
  display: grid;
  gap: 10px 4px;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  align-items: start;
}

.cd-showcase-step-arrow {
  display: none;
}

.cd-showcase-step {
  border: none;
  border-radius: 0;
  padding: 0 10px;
  background: transparent;
  min-height: 0;
  position: relative;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cd-showcase-step-num {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background: #e8f3f9;
  color: #3a8fbe;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  margin-bottom: 10px;
  font-size: 1.05rem;
  font-family: "Playfair Display", Georgia, serif;
  border: none;
  line-height: 1;
}

.cd-showcase-step-num i {
  font-size: 0.95rem;
  line-height: 1;
  color: #3a8fbe;
}

.cd-showcase-step h4 {
  margin: 0;
  color: #0f2e46;
  font-family: "Rethink Sans", "Inter", system-ui, sans-serif;
  font-size: 0.84rem;
  line-height: 1.35;
  font-weight: 700;
  max-width: 168px;
}

.cd-showcase-step p {
  margin: 5px 0 0;
  color: #5f6f82;
  font-family: "Rethink Sans", "Inter", system-ui, sans-serif;
  font-size: 0.76rem;
  line-height: 1.45;
  font-weight: 400;
  max-width: 175px;
}

@media (min-width: 901px) {
  .cd-showcase-how-grid {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0;
    overflow: visible;
  }

  .cd-showcase-step {
    flex: 1 1 0;
    min-width: 0;
    padding: 0 6px;
  }

  .cd-showcase-step-arrow {
    display: flex;
    flex: 0 0 18px;
    align-items: flex-start;
    justify-content: center;
    padding-top: 12px;
    color: #6b7e93;
    font-size: 0.95rem;
    font-weight: 400;
    line-height: 1;
    user-select: none;
  }
}

@media (max-width: 900px) {
  .cd-showcase-highlights {
    grid-template-columns: 1fr;
  }
  .cd-showcase-how-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .cd-showcase-how-grid {
    grid-template-columns: 1fr;
  }
}
