/* Mobile course landing and physician profiles. Desktop rules remain unchanged. */
@media (max-width: 600px) {
  /* Keep long course section titles at the legacy mobile scale. */
  #pgy-quote .dba-action-panel__heading { font-size: 24px; line-height: 1.6; }
  #pgy-career-courses .dba-course-query__heading,
  #pgy-communication-courses .dba-course-query__heading,
  #pgy-courses .dba-course-query__heading { font-size: 26px; line-height: 1.4; }
  /* Explicit gutters: the shared spacing token currently resolves to zero. */
  #pgy-programme.dba-media-content,
  #pgy-preview-lessons.dba-media-content,
  #pgy-outcomes.dba-media-content { padding-inline: 20px; }
  #pgy-outcomes .dba-media-content__heading { font-size: 24px; line-height: 1.5; }
  #pgy-outcomes.dba-media-content { min-height: 0; }
  /* Theme list indentation must not offset full-width media or outcome cards. */
  #pgy-preview-lessons .dba-media-content__previews { margin: 20px 0 24px; padding: 0; gap: 24px; }
  #pgy-preview-lessons .dba-media-content__preview-meta { margin: 0; padding: 0; }
  #pgy-preview-lessons .dba-media-content__preview-meta-item { align-items: flex-start; line-height: 1.65; }
  #pgy-preview-lessons .dba-media-content__preview-meta-icon { margin-top: 3px; }
  #pgy-outcomes .dba-media-content__outcomes { margin: 0; padding: 0 0 30px; }

  /* Course rails end after their content instead of a legacy fixed height. */
  #pgy-career-courses.dba-course-query,
  #pgy-communication-courses.dba-course-query,
  #pgy-courses.dba-course-query { min-height: 0; }
  #pgy-career-courses .dba-course-query__inner,
  #pgy-communication-courses .dba-course-query__inner,
  #pgy-courses .dba-course-query__inner { padding-block: 32px; }
  #pgy-career-courses .dba-course-query__header,
  #pgy-communication-courses .dba-course-query__header,
  #pgy-courses .dba-course-query__header { margin-bottom: 28px; }

  /* Share the author area with the portrait; keep every line of the quote. */
  #pgy-expert-testimonials .dba-media-content__expert {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 100px;
    align-content: start;
    column-gap: 12px;
    row-gap: 6px;
    height: auto;
    min-height: 0;
    padding: 20px;
  }
  #pgy-expert-testimonials .dba-media-content__quote-mark,
  #pgy-expert-testimonials .dba-media-content__expert-quote,
  #pgy-expert-testimonials .dba-media-content__expert-body { grid-column: 1 / -1; }
  #pgy-expert-testimonials .dba-media-content__quote-mark { font-size: 30px; line-height: 1; }
  #pgy-expert-testimonials .dba-media-content__expert-quote { font-size: 18px; line-height: 1.7; }
  #pgy-expert-testimonials .dba-media-content__expert-body { margin-top: 8px; font-size: 16px; line-height: 1.8; }
  #pgy-expert-testimonials .dba-media-content__expert-name { grid-column: 1; grid-row: 4; margin: 16px 0 0; font-size: 18px; }
  #pgy-expert-testimonials .dba-media-content__expert-credential { grid-column: 1; grid-row: 5; margin: 0; font-size: 13px; line-height: 1.7; overflow-wrap: anywhere; }
  #pgy-expert-testimonials .dba-media-content__expert-image {
    position: static;
    grid-column: 2;
    grid-row: 4 / 6;
    align-self: end;
    justify-self: end;
    width: 100px;
    margin: 0 -20px -20px 0;
  }

  /* Compact consultation band with readable copy and one clear touch target. */
  #pgy-purchase.dba-action-panel { min-height: 0; }
  #pgy-purchase .dba-action-panel__content { padding: 40px 24px; }
  #pgy-purchase .dba-action-panel__heading { margin: 0; font-size: clamp(22px, 6vw, 24px); line-height: 1.45; }
  #pgy-purchase .dba-action-panel__body { margin: 16px 0 0; color: #fff; font-size: 18px; line-height: 1.7; }
  #pgy-purchase .dba-action-panel__body p { margin: 0; }
  #pgy-purchase .dba-action-panel__buttons { width: 100%; margin-top: 24px; }
  #pgy-purchase .dba-action-panel__button { justify-content: center; min-height: 52px; padding: 14px 24px; gap: 10px; color: #0f4d81; font-size: 16px; line-height: 24px; }
  #pgy-purchase .dba-action-panel__button-icon { color: inherit; font-size: 18px; }
  #pgy-student-testimonials .dba-media-content__students { padding: 0; }
  #pgy-student-testimonials .dba-media-content__student { height: auto; min-height: 287px; }
  #pgy-student-testimonials .dba-media-content__student-quote { max-height: none; overflow: visible; }
  #pgy-student-testimonials .dba-media-content__student-meta { height: auto; min-height: 87px; }
  /* Statistics must fit their two-column mobile grid, including 50,000+. */
  .dba-profile .dba-profile__stat-number { font-size: clamp(30px, 8.5vw, 40px); }
  .dba-profile .dba-profile__stat-suffix { font-size: .8em; }
}

@media (max-width: 360px) {
  #pgy-outcomes .dba-media-content__heading,
  #pgy-student-testimonials .dba-media-content__heading { font-size: 22px; }
  /* On the narrowest phones, give credentials the full width to avoid orphans. */
  #pgy-expert-testimonials .dba-media-content__expert { grid-template-columns: minmax(0, 1fr) 76px; column-gap: 10px; }
  #pgy-expert-testimonials .dba-media-content__expert-name { align-self: center; }
  #pgy-expert-testimonials .dba-media-content__expert-image { grid-row: 4; align-self: center; width: 72px; margin: 10px 0 0; }
  #pgy-expert-testimonials .dba-media-content__expert-credential { grid-column: 1 / -1; }
}
