.apprentice-main {
  display: grid;
  align-content: start;
  gap: 22px;
  padding: 20px 18px calc(28px + env(safe-area-inset-bottom));
}

.apprentice-intro {
  display: grid;
  gap: 8px;
}

.apprentice-kicker {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--blue);
}

.apprentice-intro h2 {
  margin: 0;
  font-size: 26px;
  line-height: 1.15;
  letter-spacing: -.02em;
}

.apprentice-intro p:last-child,
.apprentice-note {
  margin: 0;
  font-size: 16px;
  line-height: 1.45;
  color: var(--text-soft);
}

.apprentice-section {
  display: grid;
  gap: 12px;
}

.apprentice-section[hidden] {
  display: none;
}

.apprentice-section > h2 {
  margin: 0;
  font-size: 20px;
}

.lesson-list,
.tool-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lesson-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.lesson-card h3 {
  margin: 0;
  font-size: 18px;
}

.lesson-card .lesson-summary {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.45;
}

/* Lessons are drawn 9:16 for a phone held upright. Cap the height so one video never fills a laptop screen. */
.lesson-card video {
  display: block;
  width: 100%;
  max-height: 70vh;
  aspect-ratio: 9 / 16;
  border-radius: 12px;
  background: var(--surface-muted);
  object-fit: contain;
}

/* YouTube lessons are usually filmed sideways; vertical ones (Shorts, upright phone video) say so. */
.lesson-youtube {
  position: relative;
  overflow: hidden;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  background: var(--surface-muted);
}

.lesson-youtube.vertical {
  width: min(100%, calc(70vh * 9 / 16));
  aspect-ratio: 9 / 16;
  margin-inline: auto;
}

.lesson-youtube iframe,
.youtube-start {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.youtube-start {
  display: grid;
  place-items: center;
  padding: 0;
  background: transparent;
  cursor: pointer;
}

.youtube-start img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.youtube-play {
  position: relative;
  width: 68px;
  height: 48px;
  border-radius: 14px;
  background: rgba(0, 0, 0, .72);
}

.youtube-play::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  border-style: solid;
  border-width: 11px 0 11px 18px;
  border-color: transparent transparent transparent #fff;
  transform: translate(-40%, -50%);
}

.youtube-start:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: -3px;
}

.lesson-steps {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 22px;
  line-height: 1.45;
}

.lesson-related {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--blue);
  font-weight: 600;
}

.tool-list li {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
}

.tool-list strong {
  font-size: 16px;
}

.tool-list p {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
  color: var(--muted);
}

.tool-list .tool-use {
  color: var(--text-soft);
}

.apprentice-status {
  margin: 0;
  color: var(--muted);
}

.apprentice-status:empty {
  display: none;
}

/* Field Card */
.lesson-card, .tool-list li { border: 1px solid var(--edge); }
.tool-list li { box-shadow: var(--hard-shadow-sm); }
