/* Home bundles (“Learning tracks”) — premium showcase; scoped so #courses stays unchanged */

body.dm-page-home .dm-home-bundles {
  --dm-bundles-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --dm-bundles-surface: rgba(255, 255, 255, 0.5);
  --dm-bundles-glass-edge: rgba(255, 255, 255, 0.72);
  position: relative;
  overflow: hidden;
  /* Pearl / studio backdrop — restrained vs candy gradients */
  background:
    linear-gradient(
      172deg,
      #f3f6fb 0%,
      #f6f7fb 28%,
      #f4f5fa 55%,
      #f2f8fc 82%,
      #eef6fb 100%
    );
  border-top: 1px solid rgba(15, 23, 42, 0.06);
  border-bottom: 1px solid rgba(15, 23, 42, 0.055);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(255, 255, 255, 0.55),
    0 28px 64px -36px rgba(15, 23, 42, 0.14),
    0 14px 40px -28px rgba(37, 99, 235, 0.12);
}

body.dm-page-home .dm-home-bundles::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 92% 68% at 5% 6%, rgba(37, 99, 235, 0.12) 0%, transparent 58%),
    radial-gradient(ellipse 68% 52% at 96% 16%, rgba(99, 102, 241, 0.1) 0%, transparent 56%),
    radial-gradient(ellipse 65% 50% at 90% 92%, rgba(14, 165, 233, 0.09) 0%, transparent 54%),
    radial-gradient(ellipse 72% 48% at 42% 102%, rgba(59, 130, 246, 0.07) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}

/* Micro-grid: editorial, low-contrast */
body.dm-page-home .dm-home-bundles::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(15, 23, 42, 0.045) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: linear-gradient(
    180deg,
    transparent 0%,
    rgba(0, 0, 0, 0.45) 14%,
    rgba(0, 0, 0, 0.75) 48%,
    rgba(0, 0, 0, 0.75) 52%,
    rgba(0, 0, 0, 0.45) 86%,
    transparent 100%
  );
  -webkit-mask-image: linear-gradient(
    180deg,
    transparent 0%,
    rgba(0, 0, 0, 0.45) 14%,
    rgba(0, 0, 0, 0.75) 48%,
    rgba(0, 0, 0, 0.75) 52%,
    rgba(0, 0, 0, 0.45) 86%,
    transparent 100%
  );
  pointer-events: none;
  z-index: 0;
}

body.dm-page-home .dm-home-bundles > .container {
  position: relative;
  z-index: 1;
}

/* --- Header: frosted editorial panel */
body.dm-page-home .dm-home-bundles__header {
  text-align: center;
  max-width: 48rem;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 2.85rem;
  padding: 2rem 1.35rem 2.15rem;
  border-radius: 1.35rem;
  background: linear-gradient(
    165deg,
    rgba(255, 255, 255, 0.58) 0%,
    rgba(255, 255, 255, 0.38) 100%
  );
  border: 1px solid var(--dm-bundles-glass-edge);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 28px 56px -32px rgba(15, 23, 42, 0.14),
    0 0 0 1px rgba(37, 99, 235, 0.05);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
}

@media (min-width: 576px) {
  body.dm-page-home .dm-home-bundles__header {
    padding: 2.25rem 2rem 2.35rem;
  }
}

@media (min-width: 992px) {
  body.dm-page-home .dm-home-bundles__header {
    margin-bottom: 3.35rem;
    padding: 2.5rem 2.5rem 2.6rem;
    border-radius: 1.5rem;
  }
}

body.dm-page-home .dm-home-bundles__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #334155;
  margin-bottom: 1.05rem;
  padding: 0.42rem 1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 6px 20px rgba(15, 23, 42, 0.06);
}

body.dm-page-home .dm-home-bundles__stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 0.6rem;
  margin-bottom: 1.45rem;
}

body.dm-page-home .dm-home-bundles__stat {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  font-variant-numeric: tabular-nums;
  color: #475569;
  padding: 0.48rem 1.02rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(15, 23, 42, 0.05);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 4px 16px rgba(15, 23, 42, 0.05);
}

body.dm-page-home .dm-home-bundles__stat i {
  font-size: 1.02rem;
  color: var(--dm-primary);
  opacity: 0.75;
}

body.dm-page-home .dm-home-bundles__stat strong {
  color: #0f172a;
  font-weight: 700;
}

body.dm-page-home .dm-home-bundles__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.9rem, 3.9vw, 2.55rem);
  letter-spacing: -0.038em;
  line-height: 1.12;
  color: #0f172a;
  margin-bottom: 1.05rem;
  text-wrap: balance;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.65);
}

body.dm-page-home .dm-home-bundles__title::before {
  content: "";
  display: block;
  width: 2.75rem;
  height: 0.1875rem;
  border-radius: 999px;
  margin: 0 auto 1.2rem;
  background: linear-gradient(90deg, var(--dm-blue-600), var(--dm-play-violet));
  opacity: 0.88;
  box-shadow: 0 2px 12px rgba(37, 99, 235, 0.22);
}

body.dm-page-home .dm-home-bundles__lede {
  font-size: 1.0625rem;
  line-height: 1.62;
  font-weight: 400;
  letter-spacing: 0.005em;
  max-width: 36rem;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 0;
  color: #475569 !important;
}

body.dm-page-home .dm-home-bundles__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.7rem 1rem;
  margin-top: 1.65rem;
}

body.dm-page-home .dm-home-bundles__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: 0.01em;
  padding: 0.62rem 1.45rem;
  border-radius: 999px;
  transition:
    transform 0.35s var(--dm-bundles-ease),
    box-shadow 0.35s var(--dm-bundles-ease),
    border-color 0.25s ease,
    background-color 0.25s ease,
    color 0.25s ease;
}

body.dm-page-home .dm-home-bundles__cta-icon {
  font-size: 1rem;
  opacity: 0.92;
  transition: transform 0.35s var(--dm-bundles-ease);
}

body.dm-page-home .dm-home-bundles .dm-home-bundles__cta--primary.btn {
  border: none;
  color: #fff;
  background-image: linear-gradient(165deg, #1d4ed8 0%, #2563eb 42%, #1e40af 100%);
  background-color: transparent;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.22) inset,
    0 10px 28px -8px rgba(37, 99, 235, 0.45),
    0 4px 12px rgba(15, 23, 42, 0.08);
}

body.dm-page-home .dm-home-bundles .dm-home-bundles__cta--primary.btn:hover {
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.28) inset,
    0 16px 36px -10px rgba(37, 99, 235, 0.5),
    0 8px 18px rgba(15, 23, 42, 0.1);
  color: #fff;
}

body.dm-page-home .dm-home-bundles .dm-home-bundles__cta--primary.btn:hover .dm-home-bundles__cta-icon {
  transform: translate(2px, -2px);
}

body.dm-page-home .dm-home-bundles .dm-home-bundles__cta--ghost.btn {
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(37, 99, 235, 0.18);
  color: #1e40af;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.85) inset,
    0 6px 18px rgba(15, 23, 42, 0.05);
}

body.dm-page-home .dm-home-bundles .dm-home-bundles__cta--ghost.btn:hover {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(37, 99, 235, 0.28);
  color: #1d4ed8;
  transform: translateY(-2px);
}

body.dm-page-home .dm-home-bundles .dm-home-bundles__cta--ghost.btn:hover .dm-home-bundles__cta-icon {
  transform: rotate(-8deg);
}

@media (prefers-reduced-motion: reduce) {
  body.dm-page-home .dm-home-bundles__cta:hover,
  body.dm-page-home .dm-home-bundles__cta:hover .dm-home-bundles__cta-icon,
  body.dm-page-home .dm-home-bundles .dm-course-card-popular:hover,
  body.dm-page-home .dm-home-bundles .dm-course-card-popular:hover .dm-course-card-popular__link i {
    transform: none;
  }

  body.dm-page-home .dm-home-bundles .dm-course-card-popular {
    transition: none;
  }
}

/* Grid rhythm */
body.dm-page-home .dm-home-bundles__grid.row {
  --bs-gutter-x: 1.35rem;
  --bs-gutter-y: 1.35rem;
}

@media (min-width: 992px) {
  body.dm-page-home .dm-home-bundles__grid.row {
    --bs-gutter-x: 1.6rem;
    --bs-gutter-y: 1.6rem;
  }
}

/* Cards — bezel, lift, editorial motion */
body.dm-page-home .dm-home-bundles.dm-page-home--catalog-mark .dm-course-card-popular {
  position: relative;
  border-left: 1px solid rgba(255, 255, 255, 0.65);
  margin-left: 0;
  border-radius: 1.125rem;
  overflow: hidden;
  transition:
    transform 0.5s var(--dm-bundles-ease),
    box-shadow 0.5s var(--dm-bundles-ease),
    border-color 0.35s ease;
  box-shadow:
    0 0 0 1px rgba(15, 23, 42, 0.045),
    0 1px 0 rgba(255, 255, 255, 0.75) inset,
    0 2px 6px rgba(15, 23, 42, 0.03),
    0 22px 44px -18px rgba(15, 23, 42, 0.14),
    0 14px 36px -22px rgba(37, 99, 235, 0.14);
}

body.dm-page-home .dm-home-bundles.dm-page-home--catalog-mark .dm-course-card-popular:hover {
  border-left-color: rgba(255, 255, 255, 0.85);
}

body.dm-page-home .dm-home-bundles .dm-course-card-popular:hover {
  transform: translateY(-10px);
  box-shadow:
    0 0 0 1px rgba(37, 99, 235, 0.12),
    0 1px 0 rgba(255, 255, 255, 0.85) inset,
    0 8px 16px rgba(15, 23, 42, 0.04),
    0 36px 56px -22px rgba(15, 23, 42, 0.16),
    0 22px 48px -18px rgba(37, 99, 235, 0.2);
}

body.dm-page-home .dm-home-bundles .dm-course-card-popular__thumb {
  aspect-ratio: 16 / 9;
}

body.dm-page-home .dm-home-bundles .dm-course-card-popular .dm-course-card-popular__body {
  background: linear-gradient(180deg, #fefeff 0%, #fafbfd 100%);
}

body.dm-page-home .dm-home-bundles .dm-course-card-popular__link i {
  display: inline-block;
  transition: transform 0.45s var(--dm-bundles-ease);
}

body.dm-page-home .dm-home-bundles .dm-course-card-popular:hover .dm-course-card-popular__link i {
  transform: translateX(5px);
}

body.dm-page-home .dm-home-bundles__cell {
  perspective: 1200px;
}

