/* Scoped to the public course landing page; admin and student dashboards are unaffected. */
body.course-landing,
body.course-landing * {
  text-align: center !important;
}

/* Center common flex/grid compositions, including inline-styled homepage blocks. */
body.course-landing [style*="display:flex"],
body.course-landing [style*="display: flex"] {
  align-items: center !important;
  justify-content: center !important;
}
body.course-landing [style*="display:grid"],
body.course-landing [style*="display: grid"] {
  align-items: center !important;
  justify-content: center !important;
  justify-items: center !important;
}
body.course-landing :is(.lp-inner-full, .lp-actions, .lp-stats, .slide-caption-bar, #featured-courses, #feat-grid, #portal-grid, .crs-meta, .nav-links, .nav-actions) {
  align-items: center !important;
  justify-content: center !important;
  justify-items: center !important;
}
body.course-landing .lp-inner-full,
body.course-landing .lp-sub,
body.course-landing .slide-caption-bar {
  margin-inline: auto !important;
}

/* Hero colors are set by the contrast sampler, not by the active theme. */
body.course-landing .lp-hero {
  --hero-text-color: #fff;
}
body.course-landing .lp-hero.hero-text-dark {
  --hero-text-color: #111;
}
body.course-landing .lp-hero :is(.lp-title, .lp-sub, .lp-badge-txt, .lp-stat-num, .lp-stat-lbl, .slide-cat-lbl, .slide-title-lbl) {
  color: var(--hero-text-color) !important;
}
body.course-landing .lp-hero .gold-text {
  color: var(--hero-text-color) !important;
  -webkit-text-fill-color: var(--hero-text-color) !important;
  background: none !important;
  background-image: none !important;
}
body.course-landing .lp-hero #stat-rating,
body.course-landing .lp-hero #stat-rating * {
  color: var(--hero-text-color) !important;
  -webkit-text-fill-color: var(--hero-text-color) !important;
}
body.course-landing .lp-hero .lp-badge {
  background: color-mix(in srgb, var(--hero-text-color) 10%, transparent) !important;
  border-color: color-mix(in srgb, var(--hero-text-color) 30%, transparent) !important;
}
body.course-landing .lp-hero .lp-badge-dot {
  background: var(--hero-text-color) !important;
}
body.course-landing .lp-hero .slide-caption-bar {
  background: color-mix(in srgb, var(--hero-text-color) 12%, transparent) !important;
  border-color: color-mix(in srgb, var(--hero-text-color) 28%, transparent) !important;
}
body.course-landing .lp-hero #hero-cta1 {
  color: #111 !important;
}
body.course-landing .lp-hero #hero-cta2 {
  color: var(--hero-text-color) !important;
  border-color: color-mix(in srgb, var(--hero-text-color) 72%, transparent) !important;
}
body.course-landing .lp-hero.hero-text-light :is(.lp-title, .lp-sub, .lp-badge-txt, .lp-stat-num, .lp-stat-lbl, .slide-caption-bar, #hero-cta2) {
  text-shadow: 0 1px 8px rgba(0, 0, 0, .18);
}
body.course-landing .lp-hero.hero-text-dark :is(.lp-title, .lp-sub, .lp-badge-txt, .lp-stat-num, .lp-stat-lbl, .slide-caption-bar, #hero-cta2) {
  text-shadow: 0 1px 8px rgba(255, 255, 255, .22);
}

/* Center the remaining layout groups while keeping responsive card grids intact. */
body.course-landing .nav-inner {
  flex-wrap: wrap !important;
  justify-content: center !important;
  gap: 10px clamp(12px, 2vw, 24px) !important;
}
body.course-landing :is(.nav-logo, .nav-links, .nav-actions, .lp-badge, .loc-strip, .testi-author, .pds-cookie-actions) {
  justify-content: center !important;
}
body.course-landing :is(.steps-row, .testi-grid, .footer-grid, .mobile-nav-links, .mobile-nav-actions) {
  justify-content: center !important;
  justify-items: center !important;
}
body.course-landing #pds-cookie-banner {
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  text-align: center !important;
}
body.course-landing #pds-cookie-banner > * {
  text-align: center !important;
}
body.course-landing .pds-cookie-actions {
  margin-inline: auto !important;
}
body.course-landing .footer-bottom {
  flex-wrap: wrap !important;
  justify-content: center !important;
  gap: 12px !important;
}
