/* Training: the course hub and course pages. Both sit on the article shell
   (article.css) — one 720px reading column — and add the course card, the
   lesson list and the signup dialog. */
.course__crumb { margin: 0 0 16px; font-size: 14px; line-height: 20px; color: rgba(0, 0, 0, .5); }
.post__body .course__crumb a { text-decoration: none; color: inherit; }
.post__body .course__crumb a:hover { color: var(--ink); }

/* hosts row under the lede: square crops of the about page portraits, centred on the head */
.post__body .course__hosts { display: flex; flex-wrap: wrap; gap: 16px 32px; margin: 0 0 40px; padding: 0; list-style: none; }
.post__body .course__hosts li { display: flex; align-items: center; gap: 12px; margin: 0; font-size: 15px; line-height: 20px; color: var(--ink); }
.course__hosts img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: #f8f9fd; }
.course__hosts strong { display: block; font-weight: 500; color: var(--ink); }
.course__hosts span { display: block; font-size: 14px; color: rgba(0, 0, 0, .55); }

/* the signup band: one ask before the lessons, and a quiet note once unlocked */
.course__access { display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; margin: 40px 0 0; padding: 24px; border-radius: 20px; background: var(--surface); }
.post__body .course__access p { margin: 0; font-size: 15px; line-height: 22px; }
.course__access strong { display: block; font-size: 17px; line-height: 24px; font-weight: 500; color: var(--ink); }
.course__access .btn { flex: none; background: var(--ink); }
.course__access .btn:hover { background: #3a3a3a; }
.course__access .btn:focus-visible, .lesson__deck:focus-visible, .lesson__play:focus-visible, .course-card:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.course__access[data-unlocked] .btn { display: none; }

.post__body .course__outline { margin: 48px 0 0; padding: 0; list-style: none; border-top: 1px solid var(--frame-line); }
.post__body .course__outline li { margin: 0; border-bottom: 1px solid var(--frame-line); }
.post__body .course__outline a { display: grid; grid-template-columns: 88px minmax(0, 1fr) auto; gap: 16px; padding: 14px 0; font-size: 15px; line-height: 22px; text-decoration: none; color: var(--ink); }
.course__outline a > span:first-child, .course__outline a > span:last-child { color: rgba(0, 0, 0, .5); font-variant-numeric: tabular-nums; }
.post__body .course__outline a:hover > span:nth-child(2) { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(0, 0, 0, .25); }

/* one lesson: label, title, copy, then the video and its presentation */
.lesson { margin-top: 80px; scroll-margin-top: 96px; }
.lesson__meta { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 0 0 8px; font-size: 14px; line-height: 20px; color: rgba(0, 0, 0, .5); font-variant-numeric: tabular-nums; }
.lesson__free { padding: 0 8px; border-radius: 999px; background: rgba(0, 224, 239, .14); color: #00646b; }
.post__body .lesson h2 { margin: 0 0 16px; font-size: 28px; line-height: 34px; letter-spacing: -.56px; text-wrap: balance; }
.post__body .lesson__hook { color: var(--ink); font-weight: 500; }

.lesson__video { position: relative; margin: 32px 0 0; aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; background: #0b1530; }
.lesson__video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.lesson__play { position: absolute; inset: 0; display: block; width: 100%; padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
.lesson__play img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease-out-quint), filter .3s ease; }
.lesson__badge { position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: inline-flex; align-items: center; gap: 10px; height: 48px; padding-inline: 20px 22px; border-radius: 999px; background: rgba(255, 255, 255, .94); color: var(--ink); font-family: inherit; font-size: 16px; line-height: 1; font-weight: 500; letter-spacing: -.2px; white-space: nowrap; box-shadow: 0 8px 24px rgba(0, 0, 0, .18); transition: transform .18s ease, background .18s ease; }
.lesson__badge svg { width: 16px; height: 16px; flex: none; }
.lesson__badge .is-locked, [data-locked] .lesson__badge .is-open { display: none; }
[data-locked] .lesson__badge .is-locked { display: inline; }
[data-locked] .lesson__play img { filter: brightness(.72); }
@media (hover: hover) {
  .lesson__play:hover img { transform: scale(1.015); }
  .lesson__play:hover .lesson__badge { background: #fff; }
}
.lesson__play:active .lesson__badge { transform: scale(.96); }

.lesson__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-top: 16px; }
.post__body a.lesson__deck { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding-inline: 20px; border-radius: 999px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .18); color: var(--ink); font-size: 15px; font-weight: 500; letter-spacing: -.15px; text-decoration: none; transition: background .18s ease, box-shadow .18s ease, transform .18s ease; }
.lesson__deck svg { width: 14px; height: 14px; }
.post__body a.lesson__deck:hover { background: var(--surface); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .3); }
.post__body a.lesson__deck:active { transform: scale(.97); }
.lesson__note { margin: 0; font-size: 14px; line-height: 20px; color: rgba(0, 0, 0, .5); }

/* hub: one card per course */
.post__body .courses { margin: 48px 0 0; padding: 0; list-style: none; }
.post__body .courses li { margin: 0; }
.post__body a.course-card { display: block; border-radius: 20px; overflow: hidden; background: var(--surface); color: var(--ink); text-decoration: none; transition: transform .3s var(--ease-out-quint); }
.course-card img { display: block; width: 100%; height: auto; aspect-ratio: 32 / 15; object-fit: cover; object-position: top; }   /* crops the live-event date off the welcome frame */
.course-card__body { padding: 24px 24px 28px; }
.post__body .course-card__meta { margin: 0 0 8px; font-size: 14px; line-height: 20px; color: rgba(0, 0, 0, .5); }
.post__body .course-card h2 { margin: 0 0 8px; }
.post__body .course-card p { margin: 0; }
.course-card__more { display: inline-block; margin-top: 16px; font-size: 15px; font-weight: 500; }
@media (hover: hover) { .post__body a.course-card:hover { transform: translateY(-2px); } }

/* signup dialog: the enquiry dialog's surface, sized to its one short step */
.enquiry.course-signup { height: fit-content; }   /* auto stretches a modal: it is pinned inset 0 */
.course-signup .enquiry__viewport { flex: none; overflow: visible; }
.course-signup .enquiry__step { position: static; overflow: visible; }
.course-signup .enquiry__heading { min-height: 0; }
.course-signup__fine { margin: 8px 0 0; font-size: 12px; line-height: 18px; color: var(--muted); text-align: center; }
.course-signup__fine a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }

@media (max-width: 600px) {
  .course__access { flex-direction: column; align-items: stretch; padding: 20px; }
  .course__access .btn { width: 100%; }
  .post__body .course__outline a { grid-template-columns: 72px minmax(0, 1fr); }
  .course__outline a > span:last-child { display: none; }
  .lesson { margin-top: 64px; }
  .post__body .lesson h2 { font-size: 24px; line-height: 30px; letter-spacing: -.48px; }
  .lesson__video { margin-top: 24px; border-radius: 12px; margin-inline: calc(var(--frame-gut) * -.5); }
  .lesson__badge { height: 40px; padding-inline: 16px 18px; font-size: 15px; }
  .post__body a.lesson__deck { width: 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  .lesson__play img, .post__body a.course-card { transition: none; }
}
