/*
 * LVF Course Engine v0.7.2
 * Local Progress Engine + Responsive Course Navigator.
 * Public/cacheable presentation only; normal LVF pages/posts remain untouched.
 */

:root {
  --lvf-course-green: #0a7a42;
  --lvf-course-green-deep: #075f34;
  --lvf-course-green-dark: #06472a;
  --lvf-course-green-soft: #eef8f2;
  --lvf-course-green-faint: #f7fbf8;
  --lvf-course-green-ring: rgba(10, 122, 66, 0.16);
  --lvf-course-text: #17233b;
  --lvf-course-muted: #687386;
  --lvf-course-line: #dfe8e3;
  --lvf-course-surface: #ffffff;
  --lvf-course-bg: #f3f7f5;
  --lvf-course-radius: 20px;
  --lvf-course-shadow: 0 18px 55px rgba(19, 49, 36, 0.08);
  --lvf-course-shadow-soft: 0 8px 30px rgba(19, 49, 36, 0.055);
}

/* --------------------------------------------------------------------------
   Theme escape hatch: Course Engine owns the entire content width.
   These rules are intentionally scoped to our CPT/archive body classes only.
   -------------------------------------------------------------------------- */
.lvf-course-engine-page #content > .ast-container,
.lvf-course-engine-page #content .ast-container,
.lvf-course-engine-page .site-content > .ast-container {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.lvf-course-engine-page #primary,
.lvf-course-engine-page .content-area,
.lvf-course-engine-page .site-main,
.lvf-course-engine-page .ast-separate-container #primary,
.lvf-course-engine-page.ast-right-sidebar #primary,
.lvf-course-engine-page.ast-left-sidebar #primary {
  float: none !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
}

.lvf-course-engine-page #secondary,
.lvf-course-engine-page .widget-area,
.lvf-course-engine-page .sidebar-main {
  display: none !important;
}

.lvf-course-engine-page .lvf-course-shell {
  box-sizing: border-box;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: clamp(2rem, 4vw, 4.5rem) clamp(1rem, 3vw, 2rem);
  background: var(--lvf-course-bg);
  color: var(--lvf-course-text);
}

.lvf-course-shell *,
.lvf-course-shell *::before,
.lvf-course-shell *::after {
  box-sizing: border-box;
}

.lvf-course-shell__inner {
  width: min(1280px, 100%);
  margin: 0 auto;
}

.lvf-course-shell__inner--lesson {
  width: min(1320px, 100%);
}

.lvf-course-runtime {
  min-width: 0;
}

/* ---------- Shared visual language ---------- */
.lvf-course-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 48px;
  padding: 0.78rem 1.2rem;
  border-radius: 12px;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none !important;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.lvf-course-button:hover,
.lvf-course-button:focus-visible {
  transform: translateY(-1px);
}

.lvf-course-button--primary {
  color: #fff !important;
  background: var(--lvf-course-green);
  box-shadow: 0 10px 25px rgba(10, 122, 66, 0.22);
}

.lvf-course-button--primary:hover,
.lvf-course-button--primary:focus-visible {
  background: var(--lvf-course-green-deep);
}

.lvf-course-button--secondary {
  color: var(--lvf-course-green-deep) !important;
  background: var(--lvf-course-green-soft);
  border: 1px solid rgba(10, 122, 66, 0.14);
}

.lvf-course-library-hero__eyebrow,
.lvf-course-hero__eyebrow,
.lvf-lesson-hero__eyebrow,
.lvf-course-card__eyebrow,
.lvf-course-outline__eyebrow,
.lvf-course-sequential-nav__eyebrow,
.lvf-course-navigator__eyebrow {
  margin: 0;
  color: var(--lvf-course-green);
  font-size: 0.75rem;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ---------- Course Library ---------- */
.lvf-course-library-hero {
  margin-bottom: 2rem;
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid rgba(10, 122, 66, 0.12);
  border-radius: 26px;
  background:
    radial-gradient(circle at 92% 12%, rgba(10, 122, 66, 0.13), transparent 31%),
    linear-gradient(135deg, #ffffff 0%, #f2faf5 100%);
  box-shadow: var(--lvf-course-shadow);
}

.lvf-course-library-hero h1 {
  margin: 0.45rem 0 0.8rem;
  color: var(--lvf-course-text);
  font-size: clamp(2.35rem, 5vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
}

.lvf-course-library-hero > p:last-child {
  max-width: 760px;
  margin: 0;
  color: var(--lvf-course-muted);
  font-size: clamp(1rem, 2vw, 1.18rem);
}

.lvf-course-library-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.35rem;
}

.lvf-course-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
  transition: transform 170ms ease, box-shadow 170ms ease, border-color 170ms ease;
}

.lvf-course-card:hover {
  transform: translateY(-2px);
  border-color: rgba(10, 122, 66, 0.24);
  box-shadow: 0 16px 38px rgba(19, 49, 36, 0.09);
}

.lvf-course-card__image {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--lvf-course-green-soft);
}

.lvf-course-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease;
}

.lvf-course-card:hover .lvf-course-card__image img {
  transform: scale(1.02);
}

.lvf-course-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 1.5rem;
}

.lvf-course-card__title {
  margin: 0.35rem 0 0.7rem;
  font-size: 1.42rem;
  line-height: 1.22;
}

.lvf-course-card__title a {
  color: var(--lvf-course-text);
  text-decoration: none;
}

.lvf-course-card__excerpt {
  margin: 0 0 1rem;
  color: var(--lvf-course-muted);
}

.lvf-course-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: auto;
  margin-bottom: 1rem;
}

.lvf-course-card__meta span {
  padding: 0.35rem 0.62rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 999px;
  color: #315243;
  background: var(--lvf-course-green-faint);
  font-size: 0.82rem;
  font-weight: 750;
}

.lvf-course-library-pagination {
  margin-top: 2rem;
}

/* ---------- Single Course ---------- */
.lvf-course-page,
.lvf-lesson-page {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.lvf-course-hero {
  margin-bottom: 1.5rem;
  padding: clamp(2rem, 5vw, 3.6rem);
  border: 1px solid rgba(10, 122, 66, 0.12);
  border-radius: 26px;
  background:
    radial-gradient(circle at 92% 12%, rgba(10, 122, 66, 0.13), transparent 29%),
    var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow);
}

.lvf-course-hero__title,
.lvf-lesson-hero__title {
  margin: 0.45rem 0 0;
  color: var(--lvf-course-text);
  font-size: clamp(2.2rem, 5vw, 3.55rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
}

.lvf-course-hero__intro {
  max-width: 780px;
  margin-top: 1rem;
  color: var(--lvf-course-muted);
  font-size: 1.08rem;
}

.lvf-course-hero__intro p:last-child { margin-bottom: 0; }

.lvf-course-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin: 1.35rem 0;
}

.lvf-course-hero__meta span {
  display: inline-flex;
  align-items: baseline;
  gap: 0.3rem;
  padding: 0.5rem 0.72rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 10px;
  color: #496054;
  background: var(--lvf-course-green-faint);
}

.lvf-course-hero__meta strong { color: var(--lvf-course-green-deep); }

.lvf-course-page__content {
  padding: clamp(1.35rem, 3vw, 2.15rem);
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-description > :first-child,
.lvf-course-lesson-content > :first-child { margin-top: 0; }

/* ---------- Course Outline ---------- */
.lvf-course-outline { margin-top: 2rem; }

.lvf-course-outline__header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  margin-bottom: 1rem;
}

.lvf-course-outline__header h2 {
  margin: 0.3rem 0 0;
  color: var(--lvf-course-text);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
}

.lvf-course-outline__summary {
  margin: 0;
  color: var(--lvf-course-muted);
  font-weight: 700;
}

.lvf-course-unit {
  margin: 0 0 0.9rem;
  overflow: clip;
  border: 1px solid var(--lvf-course-line);
  border-radius: 15px;
  background: var(--lvf-course-surface);
}

.lvf-course-unit summary {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem;
  cursor: pointer;
  color: var(--lvf-course-text);
  background: var(--lvf-course-green-faint);
  font-weight: 800;
}

.lvf-course-unit__lessons {
  margin: 0;
  padding: 0;
  list-style: none;
}

.lvf-course-unit__lessons li + li { border-top: 1px solid var(--lvf-course-line); }

.lvf-course-unit__lessons a {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.95rem 1.15rem;
  color: var(--lvf-course-text);
  text-decoration: none;
  transition: background 140ms ease;
}

.lvf-course-unit__lessons a:hover,
.lvf-course-unit__lessons a:focus-visible { background: var(--lvf-course-green-faint); }

.lvf-course-unit__position {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 2.15rem;
  width: 2.15rem;
  height: 2.15rem;
  border-radius: 999px;
  color: var(--lvf-course-green-deep);
  background: rgba(10, 122, 66, 0.1);
  font-size: 0.82rem;
  font-weight: 800;
}

/* ---------- Single Lesson: smarter 2-column learning shell ---------- */
.lvf-lesson-hero {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.1rem;
  padding: clamp(1.7rem, 4vw, 2.7rem);
  border: 1px solid var(--lvf-course-line);
  border-radius: 22px;
  background:
    radial-gradient(circle at 93% 15%, rgba(10, 122, 66, 0.075), transparent 28%),
    var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-lesson-hero__subtitle {
  max-width: 900px;
  margin: 0.72rem 0 0;
  color: var(--lvf-course-muted);
  font-size: clamp(0.98rem, 1.35vw, 1.08rem);
  line-height: 1.6;
}

.lvf-lesson-hero__quick-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.45rem;
}

.lvf-lesson-hero__quick-meta span {
  padding: 0.42rem 0.65rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 999px;
  color: #456052;
  background: var(--lvf-course-green-faint);
  font-size: 0.82rem;
  font-weight: 750;
}

.lvf-lesson-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(285px, 330px);
  align-items: start;
  gap: 1.35rem;
}

.lvf-lesson-layout__main { min-width: 0; }

.lvf-lesson-page__content {
  padding: clamp(1.4rem, 3vw, 2.4rem);
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-context {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem 1rem;
  margin: 0 0 1.6rem;
  padding: 0.95rem 1rem;
  border: 1px solid rgba(10, 122, 66, 0.17);
  border-radius: 13px;
  background: var(--lvf-course-green-faint);
}

.lvf-course-context__course {
  color: var(--lvf-course-green-deep);
  font-weight: 800;
  text-decoration: none;
}

.lvf-course-context__meta {
  color: var(--lvf-course-muted);
  font-size: 0.93rem;
  font-weight: 700;
}

.lvf-course-lesson-content {
  color: var(--lvf-course-text);
  font-size: 1.04rem;
  line-height: 1.68;
}

/*
 * Keep simple authored reading paragraphs compact and predictable.
 * Theme paragraph margins can otherwise create large vertical gaps between
 * short reading lines, especially when an inline vocabulary button is used.
 * Only direct paragraphs are normalized so authored cards/components keep
 * their own internal spacing.
 */
.lvf-course-lesson-content > p {
  margin: 0 0 0.38rem !important;
  line-height: 1.55;
}

.lvf-course-lesson-content > p:last-of-type {
  margin-bottom: 0 !important;
}

/* v0.7.4 — compact authored reading flow around inline vocabulary triggers. */
.lvf-course-lesson-content > p + p {
  margin-top: 0 !important;
}

.lvf-course-lesson-content .lvf-word {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.lvf-course-sequential-nav {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem;
  margin-top: 2.2rem;
  padding-top: 1.3rem;
  border-top: 1px solid var(--lvf-course-line);
}

.lvf-course-sequential-nav__previous,
.lvf-course-sequential-nav__next {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 0.35rem;
}

.lvf-course-sequential-nav__next {
  align-items: flex-end;
  text-align: right;
}

.lvf-course-sequential-nav a {
  color: var(--lvf-course-green-deep);
  font-weight: 800;
  text-decoration: none;
}

.lvf-course-sequential-nav a:hover,
.lvf-course-sequential-nav a:focus-visible { text-decoration: underline; }

/* ---------- Course Navigator ---------- */
.lvf-course-navigator-toggle {
  display: none;
}

.lvf-course-navigator {
  min-width: 0;
}

.lvf-course-navigator__panel {
  position: sticky;
  top: 1.25rem;
  overflow: hidden;
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.admin-bar .lvf-course-navigator__panel { top: 3.5rem; }

.lvf-course-navigator__topbar {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 1.15rem 0.85rem;
  border-bottom: 1px solid var(--lvf-course-line);
}

.lvf-course-navigator__title {
  margin: 0.25rem 0 0;
  font-size: 1.05rem;
  line-height: 1.3;
}

.lvf-course-navigator__title a {
  color: var(--lvf-course-text);
  text-decoration: none;
}

.lvf-course-navigator__close {
  display: none;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  color: var(--lvf-course-text);
  background: var(--lvf-course-green-faint);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.lvf-course-navigator__status {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.75rem 1.15rem;
  color: #496054;
  background: linear-gradient(90deg, #f7fbf8, #eef8f2);
  font-size: 0.82rem;
}

.lvf-course-navigator__status strong { color: var(--lvf-course-green-deep); }

.lvf-course-navigator__search-label {
  display: block;
  margin: 1rem 1.15rem 0.45rem;
  color: var(--lvf-course-text);
  font-size: 0.8rem;
  font-weight: 800;
}

.lvf-course-navigator__search-wrap {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0 1.15rem 1rem;
  padding: 0 0.72rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 11px;
  background: #fff;
}

.lvf-course-navigator__search-wrap:focus-within {
  border-color: rgba(10, 122, 66, 0.42);
  box-shadow: 0 0 0 3px var(--lvf-course-green-ring);
}

.lvf-course-navigator__search-wrap > span {
  color: var(--lvf-course-muted);
  font-size: 1.1rem;
}

.lvf-course-navigator__search {
  width: 100%;
  min-width: 0;
  height: 42px;
  padding: 0;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  color: var(--lvf-course-text);
  background: transparent !important;
  font: inherit;
  font-size: 0.9rem;
}

.lvf-course-navigator__units {
  max-height: min(52vh, 540px);
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  border-top: 1px solid var(--lvf-course-line);
}

.lvf-course-navigator__unit + .lvf-course-navigator__unit {
  border-top: 1px solid var(--lvf-course-line);
}

.lvf-course-navigator__unit-toggle {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.82rem 1.05rem;
  border: 0;
  color: var(--lvf-course-text);
  background: #fff;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.lvf-course-navigator__unit-toggle:hover,
.lvf-course-navigator__unit-toggle:focus-visible,
.lvf-course-navigator__unit.is-current-unit > .lvf-course-navigator__unit-toggle {
  background: var(--lvf-course-green-faint);
}

.lvf-course-navigator__unit-toggle::after {
  content: '⌄';
  color: var(--lvf-course-muted);
  transition: transform 150ms ease;
}

.lvf-course-navigator__unit-toggle[aria-expanded='false']::after {
  transform: rotate(-90deg);
}

.lvf-course-navigator__unit-meta {
  margin-left: auto;
  color: var(--lvf-course-muted);
  font-size: 0.75rem;
  font-weight: 700;
}

.lvf-course-navigator__lesson-list {
  margin: 0;
  padding: 0.35rem 0.55rem 0.6rem;
  list-style: none;
}

.lvf-course-navigator__lesson a {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.55rem;
  min-height: 44px;
  padding: 0.48rem 0.55rem;
  border-radius: 10px;
  color: #314339;
  text-decoration: none;
  font-size: 0.84rem;
  line-height: 1.3;
}

.lvf-course-navigator__lesson a:hover,
.lvf-course-navigator__lesson a:focus-visible {
  background: var(--lvf-course-green-faint);
}

.lvf-course-navigator__lesson.is-current a {
  color: var(--lvf-course-green-dark);
  background: var(--lvf-course-green-soft);
  font-weight: 800;
}

.lvf-course-navigator__lesson-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: var(--lvf-course-green-deep);
  background: #fff;
  border: 1px solid rgba(10, 122, 66, 0.12);
  font-size: 0.72rem;
  font-weight: 800;
}

.lvf-course-navigator__lesson-title {
  min-width: 0;
  overflow-wrap: anywhere;
}

.lvf-course-navigator__current-mark {
  padding: 0.2rem 0.4rem;
  border-radius: 999px;
  color: #fff;
  background: var(--lvf-course-green);
  font-size: 0.62rem;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.lvf-course-navigator__empty {
  margin: 0;
  padding: 1rem 1.15rem;
  color: var(--lvf-course-muted);
  font-size: 0.85rem;
}

.lvf-course-navigator__footer {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.45rem;
  padding: 0.85rem 1.15rem 1rem;
  border-top: 1px solid var(--lvf-course-line);
  background: #fff;
}

.lvf-course-navigator__footer a {
  color: var(--lvf-course-green-deep);
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

.lvf-course-navigator-backdrop {
  display: none;
}

.lvf-course-empty-state {
  padding: 2rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
}

/* ---------- Responsive ---------- */
@media (max-width: 1050px) {
  .lvf-course-library-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .lvf-lesson-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .lvf-course-navigator-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin: 0 0 1rem;
    padding: 0.72rem 0.95rem;
    border: 1px solid rgba(10, 122, 66, 0.2);
    border-radius: 12px;
    color: var(--lvf-course-green-deep);
    background: var(--lvf-course-green-soft);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
  }

  .lvf-course-navigator {
    position: fixed;
    z-index: 99999;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(390px, 92vw);
    padding: 0;
    transform: translateX(104%);
    transition: transform 200ms ease;
  }

  .admin-bar .lvf-course-navigator { top: 32px; }

  .lvf-course-navigator.is-open { transform: translateX(0); }

  .lvf-course-navigator__panel {
    position: relative;
    top: 0 !important;
    height: 100%;
    border-radius: 18px 0 0 18px;
    overflow: auto;
  }

  .lvf-course-navigator__close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
  }

  .lvf-course-navigator__units {
    max-height: none;
    overflow: visible;
  }

  .lvf-course-navigator-backdrop {
    position: fixed;
    z-index: 99998;
    inset: 0;
    display: block;
    pointer-events: none;
    opacity: 0;
    border: 0;
    background: rgba(9, 28, 19, 0.42);
    transition: opacity 180ms ease;
  }

  .lvf-course-navigator-backdrop.is-open {
    pointer-events: auto;
    opacity: 1;
  }

  body.lvf-course-nav-open { overflow: hidden; }
}

@media (max-width: 782px) {
  .admin-bar .lvf-course-navigator { top: 46px; }
}

@media (max-width: 680px) {
  .lvf-course-engine-page .lvf-course-shell {
    padding: 1.2rem 0.75rem 2.25rem;
  }

  .lvf-course-library-grid {
    grid-template-columns: 1fr;
  }

  .lvf-course-library-hero,
  .lvf-course-hero,
  .lvf-lesson-hero,
  .lvf-course-page__content,
  .lvf-lesson-page__content {
    border-radius: 16px;
  }

  .lvf-lesson-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .lvf-lesson-hero__quick-meta {
    justify-content: flex-start;
  }

  .lvf-course-sequential-nav {
    grid-template-columns: 1fr;
  }

  .lvf-course-sequential-nav__next {
    align-items: flex-start;
    text-align: left;
  }

  .lvf-course-context,
  .lvf-course-outline__header {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lvf-course-button,
  .lvf-course-card,
  .lvf-course-card__image img,
  .lvf-course-navigator,
  .lvf-course-navigator-backdrop,
  .lvf-course-navigator__unit-toggle::after {
    transition: none !important;
  }
}

/* v0.4.0 — local-first learning progress */
.lvf-course-local-progress {
  margin-top: 1.25rem;
  padding: 0.9rem 1rem;
  border: 1px solid var(--lvf-course-border);
  border-radius: 14px;
  background: rgba(245, 251, 247, 0.92);
}

.lvf-course-local-progress[hidden] {
  display: none !important;
}

.lvf-course-local-progress__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.55rem;
  color: var(--lvf-course-text-muted);
  font-size: 0.84rem;
}

.lvf-course-local-progress__row strong {
  color: var(--lvf-course-green-deep);
  font-weight: 800;
}

.lvf-course-local-progress__track {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(10, 122, 66, 0.10);
}

.lvf-course-local-progress__track > span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--lvf-course-green), var(--lvf-course-green-deep));
  transition: width 240ms ease;
}

.lvf-course-local-progress p,
.lvf-course-local-progress small {
  display: block;
  margin: 0.55rem 0 0;
  color: var(--lvf-course-text-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

.lvf-course-local-progress--hero {
  width: min(620px, 100%);
  margin-top: 1.35rem;
}

.lvf-course-local-progress--card {
  margin: 0.95rem 0 0;
  padding: 0.75rem 0.8rem;
}

.lvf-course-local-progress--card .lvf-course-local-progress__row {
  align-items: flex-start;
  flex-direction: column;
  gap: 0.15rem;
}

.lvf-course-local-progress--navigator {
  margin: 0;
  padding: 0.85rem 1.05rem;
  border-width: 0 0 1px;
  border-radius: 0;
  background: #fff;
}

.lvf-course-button.is-continue {
  box-shadow: 0 12px 30px rgba(10, 122, 66, 0.16);
}

.lvf-course-unit__lessons li.is-visited > a {
  background: rgba(10, 122, 66, 0.035);
}

.lvf-course-unit__lessons li.is-visited .lvf-course-unit__position {
  color: #fff;
  border-color: var(--lvf-course-green);
  background: var(--lvf-course-green);
}

.lvf-course-unit__title {
  min-width: 0;
}

.lvf-course-unit__visited {
  margin-left: auto;
  padding: 0.22rem 0.5rem;
  border-radius: 999px;
  color: var(--lvf-course-green-deep);
  background: var(--lvf-course-green-soft);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.lvf-course-navigator__lesson.is-visited:not(.is-current) a {
  color: var(--lvf-course-green-deep);
}

.lvf-course-navigator__lesson.is-visited:not(.is-current) .lvf-course-navigator__lesson-number {
  color: #fff;
  border-color: var(--lvf-course-green);
  background: var(--lvf-course-green);
}

.lvf-course-navigator__visited-mark {
  margin-left: auto;
  color: var(--lvf-course-green-deep);
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

@media (max-width: 680px) {
  .lvf-course-local-progress__row {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lvf-course-local-progress__track > span {
    transition: none !important;
  }
}

/* v0.5.0 — shared local knowledge-check + lesson completion engine */
.lvf-knowledge-check {
  margin-top: 2rem;
  padding: 1.35rem;
  border: 1px solid var(--lvf-course-border);
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(248,253,250,.98), rgba(239,249,243,.92));
}

.lvf-knowledge-check.is-passed {
  border-color: rgba(10,122,66,.32);
  box-shadow: inset 4px 0 0 var(--lvf-course-green);
}

.lvf-knowledge-check__heading h3 {
  margin: .25rem 0 .45rem;
  color: var(--lvf-course-text);
  font-size: clamp(1.15rem, 2vw, 1.45rem);
}

.lvf-knowledge-check__heading p:last-child {
  margin: 0;
  color: var(--lvf-course-text-muted);
  font-size: .9rem;
}

.lvf-knowledge-check__eyebrow,
.lvf-lesson-completion-ready__eyebrow {
  margin: 0;
  color: var(--lvf-course-green-deep);
  font-size: .75rem;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.lvf-knowledge-check__options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .75rem;
  margin-top: 1.1rem;
}

.lvf-knowledge-check__answer {
  display: flex;
  align-items: center;
  gap: .75rem;
  min-height: 58px;
  padding: .8rem .9rem;
  border: 1px solid rgba(20,60,40,.13);
  border-radius: 14px;
  color: var(--lvf-course-text);
  background: #fff;
  font: inherit;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.lvf-knowledge-check__answer:hover,
.lvf-knowledge-check__answer:focus-visible {
  border-color: rgba(10,122,66,.38);
  background: rgba(10,122,66,.035);
  outline: none;
  transform: translateY(-1px);
}

.lvf-knowledge-check__answer.is-correct {
  border-color: rgba(10,122,66,.45);
  background: rgba(10,122,66,.09);
}

.lvf-knowledge-check__answer.is-wrong {
  border-color: rgba(168,47,47,.28);
  background: rgba(168,47,47,.05);
}

.lvf-knowledge-check__letter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 999px;
  color: var(--lvf-course-green-deep);
  background: var(--lvf-course-green-soft);
  font-size: .78rem;
  font-weight: 900;
}

.lvf-knowledge-check__feedback {
  margin-top: .9rem;
  padding: .8rem .9rem;
  border-radius: 12px;
  font-size: .88rem;
  font-weight: 700;
}

.lvf-knowledge-check__feedback.is-correct {
  color: var(--lvf-course-green-deep);
  background: rgba(10,122,66,.08);
}

.lvf-knowledge-check__feedback.is-wrong {
  color: #8b3030;
  background: rgba(168,47,47,.07);
}

.lvf-lesson-completion-slot {
  margin-top: 1.15rem;
}

.lvf-lesson-completion-hint,
.lvf-lesson-completion-ready,
.lvf-lesson-completion-status,
.lvf-unit-readiness {
  border-radius: 16px;
  padding: 1rem 1.1rem;
}

.lvf-lesson-completion-hint {
  border: 1px dashed rgba(10,122,66,.24);
  background: rgba(248,253,250,.8);
}

.lvf-lesson-completion-hint strong,
.lvf-lesson-completion-ready strong,
.lvf-lesson-completion-status strong,
.lvf-unit-readiness strong {
  display: block;
  color: var(--lvf-course-text);
}

.lvf-lesson-completion-hint p,
.lvf-lesson-completion-ready p,
.lvf-lesson-completion-status p,
.lvf-unit-readiness p {
  margin: .3rem 0 0;
  color: var(--lvf-course-text-muted);
  font-size: .86rem;
}

.lvf-lesson-completion-ready {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border: 1px solid rgba(10,122,66,.25);
  background: rgba(10,122,66,.055);
}

.lvf-mark-complete-button {
  flex: 0 0 auto;
  border: 0;
  cursor: pointer;
}

.lvf-lesson-completion-status,
.lvf-unit-readiness {
  display: flex;
  align-items: flex-start;
  gap: .8rem;
  border: 1px solid rgba(10,122,66,.24);
  background: rgba(10,122,66,.07);
}

.lvf-lesson-completion-status > span,
.lvf-unit-readiness > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 999px;
  color: #fff;
  background: var(--lvf-course-green);
  font-weight: 900;
}

.lvf-unit-readiness-slot {
  margin-top: 1rem;
}

.lvf-course-unit__completed,
.lvf-course-navigator__completed-mark {
  margin-left: auto;
  padding: .22rem .5rem;
  border-radius: 999px;
  color: #fff;
  background: var(--lvf-course-green);
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .03em;
  text-transform: uppercase;
}

.lvf-course-unit__lessons li.is-completed > a {
  background: rgba(10,122,66,.055);
}

.lvf-course-unit__lessons li.is-completed .lvf-course-unit__position,
.lvf-course-navigator__lesson.is-completed .lvf-course-navigator__lesson-number {
  color: #fff;
  border-color: var(--lvf-course-green);
  background: var(--lvf-course-green);
}

.lvf-course-navigator__lesson.is-completed:not(.is-current) a {
  color: var(--lvf-course-green-deep);
  font-weight: 750;
}

@media (max-width: 680px) {
  .lvf-knowledge-check__options {
    grid-template-columns: 1fr;
  }

  .lvf-lesson-completion-ready {
    align-items: stretch;
    flex-direction: column;
  }

  .lvf-mark-complete-button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lvf-knowledge-check__answer {
    transition: none !important;
  }
}

/* --------------------------------------------------------------------------
   v0.6.0 Unit Mastery Checkpoint Engine
   Entirely client-side. No network request is made by this UI.
   -------------------------------------------------------------------------- */
.lvf-unit-checkpoint {
  margin: 1rem 0 1.5rem;
  overflow: hidden;
  border: 1px solid rgba(10, 122, 66, 0.18);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--lvf-course-shadow-soft);
  scroll-margin-top: 1.5rem;
}

.lvf-unit-checkpoint__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.4rem 1.5rem;
  background: linear-gradient(135deg, #f7fbf8 0%, #edf8f2 100%);
}

.lvf-unit-checkpoint__eyebrow {
  margin: 0 0 0.35rem;
  color: var(--lvf-course-green);
  font-size: 0.75rem;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.lvf-unit-checkpoint__header h3 {
  margin: 0;
  color: var(--lvf-course-text);
  font-size: clamp(1.35rem, 2vw, 1.75rem);
  line-height: 1.2;
}

.lvf-unit-checkpoint__header p:last-child {
  max-width: 780px;
  margin: 0.55rem 0 0;
  color: var(--lvf-course-muted);
}

.lvf-unit-checkpoint__status {
  flex: 0 0 auto;
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  background: #fff;
  color: var(--lvf-course-green-deep);
  font-size: 0.78rem;
  font-weight: 850;
  border: 1px solid rgba(10, 122, 66, 0.16);
}

.lvf-unit-checkpoint.is-locked .lvf-unit-checkpoint__status {
  color: #6f7786;
  border-color: #dde3e0;
  background: #f7f8f8;
}

.lvf-unit-checkpoint.is-mastered .lvf-unit-checkpoint__status {
  color: #fff;
  background: var(--lvf-course-green);
  border-color: var(--lvf-course-green);
}

.lvf-unit-checkpoint__locked {
  margin: 1.25rem 1.5rem 1.5rem;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  border: 1px dashed #cbd7d1;
  background: #fafcfb;
  color: var(--lvf-course-muted);
}

.lvf-unit-checkpoint__locked strong {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--lvf-course-text);
}

.lvf-unit-checkpoint__locked p {
  margin: 0;
}

.lvf-unit-checkpoint__assessment {
  padding: 1.25rem 1.5rem 1.5rem;
}

.lvf-unit-checkpoint__meter {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.35rem 1rem;
  align-items: center;
  margin-bottom: 1.2rem;
  padding: 0.9rem 1rem;
  border-radius: 14px;
  background: var(--lvf-course-green-faint);
}

.lvf-unit-checkpoint__meter > span:first-child {
  color: var(--lvf-course-muted);
  font-size: 0.9rem;
}

.lvf-unit-checkpoint__meter strong {
  color: var(--lvf-course-green-deep);
}

.lvf-unit-checkpoint__bar {
  grid-column: 1 / -1;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfece5;
}

.lvf-unit-checkpoint__bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--lvf-course-green);
  transition: width 180ms ease;
}

.lvf-unit-checkpoint__questions {
  display: grid;
  gap: 1rem;
}

.lvf-checkpoint-question {
  padding: 1.1rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 16px;
  background: #fff;
}

.lvf-checkpoint-question.is-mastered {
  border-color: rgba(10, 122, 66, 0.22);
  background: #f8fcf9;
}

.lvf-checkpoint-question__top {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.75rem;
  align-items: start;
  margin-bottom: 0.9rem;
}

.lvf-checkpoint-question__number {
  display: inline-grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: var(--lvf-course-green);
  font-size: 0.8rem;
  font-weight: 850;
}

.lvf-checkpoint-question__top h4 {
  margin: 0.15rem 0 0;
  color: var(--lvf-course-text);
  font-size: 1rem;
  line-height: 1.35;
}

.lvf-checkpoint-question__mastered {
  padding: 0.25rem 0.5rem;
  border-radius: 999px;
  color: var(--lvf-course-green-deep);
  background: #e8f6ed;
  font-size: 0.72rem;
  font-weight: 850;
  white-space: nowrap;
}

.lvf-checkpoint-question__options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.lvf-checkpoint-question__options button {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 48px;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 12px;
  color: var(--lvf-course-text);
  background: #fff;
  text-align: left;
  cursor: pointer;
}

.lvf-checkpoint-question__options button > span:first-child {
  display: inline-grid;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 999px;
  color: var(--lvf-course-green-deep);
  background: var(--lvf-course-green-soft);
  font-size: 0.78rem;
  font-weight: 850;
}

.lvf-checkpoint-question__options button:hover:not(:disabled),
.lvf-checkpoint-question__options button:focus-visible:not(:disabled) {
  border-color: rgba(10, 122, 66, 0.34);
  box-shadow: 0 0 0 3px var(--lvf-course-green-ring);
}

.lvf-checkpoint-question__options button.is-correct {
  border-color: rgba(10, 122, 66, 0.38);
  background: #edf9f1;
}

.lvf-checkpoint-question__options button.is-wrong {
  border-color: #e5aaaa;
  background: #fff7f7;
}

.lvf-checkpoint-question__options button:disabled {
  opacity: 0.62;
  cursor: default;
}

.lvf-checkpoint-question__feedback {
  margin-top: 0.7rem;
  padding: 0.7rem 0.8rem;
  border-radius: 10px;
  font-size: 0.88rem;
}

.lvf-checkpoint-question__feedback.is-correct {
  color: var(--lvf-course-green-deep);
  background: #eaf7ee;
}

.lvf-checkpoint-question__feedback.is-wrong {
  color: #8b3333;
  background: #fff2f2;
}

.lvf-unit-checkpoint__completion {
  margin-top: 1.2rem;
}

.lvf-unit-checkpoint__ready,
.lvf-unit-checkpoint__mastered {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid rgba(10, 122, 66, 0.22);
  border-radius: 14px;
  background: #eef9f2;
}

.lvf-unit-checkpoint__ready span {
  display: block;
  margin-bottom: 0.2rem;
  color: var(--lvf-course-green);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lvf-unit-checkpoint__ready strong,
.lvf-unit-checkpoint__mastered strong {
  display: block;
  color: var(--lvf-course-green-deep);
}

.lvf-unit-checkpoint__ready p,
.lvf-unit-checkpoint__mastered p {
  margin: 0.25rem 0 0;
  color: #466456;
}

.lvf-unit-checkpoint__mastered {
  justify-content: flex-start;
}

.lvf-unit-checkpoint__mastered > span:first-child {
  display: inline-grid;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: var(--lvf-course-green);
  font-size: 1.2rem;
  font-weight: 900;
}

.lvf-unit-readiness__link {
  display: inline-block;
  margin-top: 0.45rem;
  color: var(--lvf-course-green-deep) !important;
  font-weight: 800;
  text-decoration: none !important;
}

@media (max-width: 760px) {
  .lvf-unit-checkpoint__header,
  .lvf-unit-checkpoint__ready {
    flex-direction: column;
    align-items: stretch;
  }

  .lvf-unit-checkpoint__status {
    align-self: flex-start;
  }

  .lvf-checkpoint-question__options {
    grid-template-columns: 1fr;
  }

  .lvf-checkpoint-question__top {
    grid-template-columns: auto 1fr;
  }

  .lvf-checkpoint-question__mastered {
    grid-column: 2;
    justify-self: start;
  }
}


/* =========================================================
   v0.6.1 Dedicated Checkpoint Pages + Multi-Unit Architecture
   ========================================================= */
.lvf-course-shell--checkpoint .lvf-course-shell__inner {
  max-width: 1480px;
}

.lvf-checkpoint-hero {
  margin-bottom: 28px;
}

.lvf-checkpoint-hero__links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 24px;
  align-items: center;
  margin-top: 24px;
  font-weight: 700;
}

.lvf-checkpoint-hero__links a {
  color: #087a40;
  text-decoration: none;
}

.lvf-checkpoint-page__content {
  background: #fff;
  border: 1px solid rgba(10, 122, 66, .14);
  border-radius: 26px;
  padding: clamp(20px, 3vw, 44px);
  box-shadow: 0 18px 50px rgba(15, 23, 42, .06);
}

.lvf-checkpoint-page__intro {
  max-width: 900px;
  margin: 0 auto 24px;
}

.lvf-unit-checkpoint--standalone {
  margin: 0;
}

.lvf-checkpoint-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  margin: 14px 0 30px;
  padding: 22px 24px;
  border: 1px solid rgba(10, 122, 66, .16);
  border-radius: 20px;
  background: linear-gradient(135deg, #fff 0%, #f4fbf7 100%);
}

.lvf-checkpoint-summary__eyebrow {
  margin: 0 0 5px;
  color: #087a40;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.lvf-checkpoint-summary strong {
  display: block;
  font-size: 19px;
  line-height: 1.35;
}

.lvf-checkpoint-summary p:last-child {
  margin: 7px 0 0;
  color: #64748b;
}

.lvf-checkpoint-summary__action {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  min-width: 180px;
}

.lvf-checkpoint-summary__action > span {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  background: #eef6f1;
  color: #456257;
  font-size: 13px;
  font-weight: 800;
}

.lvf-checkpoint-summary.is-mastered {
  border-color: rgba(10, 122, 66, .34);
  background: linear-gradient(135deg, #f2fbf6 0%, #e8f7ee 100%);
}

.lvf-checkpoint-summary.is-mastered .lvf-checkpoint-summary__action > span {
  background: #087a40;
  color: #fff;
}

.lvf-unit-checkpoint__mastered .lvf-course-button {
  margin-top: 16px;
  width: fit-content;
}

@media (max-width: 780px) {
  .lvf-checkpoint-summary {
    grid-template-columns: 1fr;
  }
  .lvf-checkpoint-summary__action {
    align-items: stretch;
    min-width: 0;
  }
  .lvf-checkpoint-summary__action .lvf-course-button {
    text-align: center;
  }
}


.lvf-course-navigator__checkpoint-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 8px 12px 12px;
  padding: 11px 13px;
  border: 1px dashed rgba(10, 122, 66, .28);
  border-radius: 12px;
  background: #f7fbf8;
  color: #087a40;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.lvf-course-navigator__checkpoint-link:hover,
.lvf-course-navigator__checkpoint-link:focus-visible {
  background: #eef8f2;
}

/* v0.6.4 — authored educational content contract */
.lvf-learning-objectives,
.lvf-definition-card,
.lvf-example-box,
.lvf-note-box,
.lvf-tip-box,
.lvf-review-box,
.lvf-vocabulary-card {
  margin: 1.5rem 0;
  padding: 1.25rem 1.35rem;
  border: 1px solid rgba(10, 122, 66, 0.16);
  border-radius: 18px;
  background: #fff;
}

.lvf-learning-objectives,
.lvf-review-box {
  background: linear-gradient(135deg, rgba(10, 122, 66, 0.055), rgba(10, 122, 66, 0.015));
}

.lvf-definition-card {
  border-left: 5px solid #0a7a42;
}

.lvf-example-box {
  background: rgba(10, 122, 66, 0.04);
}

.lvf-note-box {
  background: rgba(17, 24, 39, 0.035);
}

.lvf-tip-box {
  background: rgba(10, 122, 66, 0.075);
}

.lvf-learning-objectives > :first-child,
.lvf-definition-card > :first-child,
.lvf-example-box > :first-child,
.lvf-note-box > :first-child,
.lvf-tip-box > :first-child,
.lvf-review-box > :first-child,
.lvf-vocabulary-card > :first-child {
  margin-top: 0;
}

.lvf-learning-objectives > :last-child,
.lvf-definition-card > :last-child,
.lvf-example-box > :last-child,
.lvf-note-box > :last-child,
.lvf-tip-box > :last-child,
.lvf-review-box > :last-child,
.lvf-vocabulary-card > :last-child {
  margin-bottom: 0;
}

.lvf-content-kicker {
  margin: 0 0 .45rem;
  color: #0a7a42;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.lvf-word-chip {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  margin: .2rem .35rem .2rem 0;
  padding: .4rem .7rem;
  border-radius: 999px;
  border: 1px solid rgba(10, 122, 66, .16);
  background: rgba(10, 122, 66, .05);
  font-weight: 700;
}

.lvf-checkpoint-authored-content {
  padding: 0 1.75rem 1rem;
}

.lvf-checkpoint-authored-content > :first-child {
  margin-top: 0;
}

.lvf-unit-checkpoint.is-locked .lvf-checkpoint-authored-content [data-lvf-checkpoint-question] {
  display: none !important;
}

.lvf-checkpoint-authored-content [data-lvf-checkpoint-question] {
  margin-top: 1.25rem;
}

@media (max-width: 720px) {
  .lvf-learning-objectives,
  .lvf-definition-card,
  .lvf-example-box,
  .lvf-note-box,
  .lvf-tip-box,
  .lvf-review-box,
  .lvf-vocabulary-card {
    padding: 1rem;
    border-radius: 14px;
  }

  .lvf-checkpoint-authored-content {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

/* =========================================================
   v0.6.5 — UI Stabilization Patch
   Scoped visual fixes only; no learning/runtime logic changes.
   ========================================================= */

/* 1) Give authored checkpoint review content clear breathing room. */
.lvf-checkpoint-authored-content > .lvf-review-box:first-child,
.lvf-checkpoint-authored-content > [data-lvf-checkpoint-assessment-content] > .lvf-review-box:first-child {
  margin-top: 1.4rem;
}

.lvf-checkpoint-authored-content .lvf-review-box + [data-lvf-checkpoint-question],
.lvf-checkpoint-authored-content .lvf-review-box + .lvf-checkpoint-question {
  margin-top: 1.75rem;
}

/* 2) Keep question number + question text together as one readable heading row. */
.lvf-checkpoint-question__top {
  grid-template-columns: 38px minmax(0, 1fr) auto;
  column-gap: .85rem;
  row-gap: .45rem;
  align-items: center;
}

.lvf-checkpoint-question__number {
  width: 38px;
  height: 38px;
  align-self: start;
  margin-top: .05rem;
}

.lvf-checkpoint-question__top h3,
.lvf-checkpoint-question__top h4 {
  grid-column: 2;
  justify-self: stretch;
  width: 100%;
  min-width: 0;
  margin: .1rem 0 0 !important;
  color: var(--lvf-course-text) !important;
  font-size: clamp(1.05rem, 1.8vw, 1.35rem);
  line-height: 1.35;
  text-align: left !important;
}

.lvf-checkpoint-question__mastered {
  grid-column: 3;
  justify-self: end;
  align-self: start;
}

/* 3) Normalize option states so theme/global button hover rules cannot erase text. */
.lvf-knowledge-check__answer,
.lvf-checkpoint-question__options button {
  color: var(--lvf-course-text) !important;
  background-color: #fff !important;
  text-decoration: none !important;
}

.lvf-knowledge-check__answer > span:not(.lvf-knowledge-check__letter),
.lvf-checkpoint-question__options button > span:not(:first-child) {
  color: inherit !important;
}

.lvf-knowledge-check__answer:hover:not(:disabled),
.lvf-knowledge-check__answer:focus-visible:not(:disabled),
.lvf-checkpoint-question__options button:hover:not(:disabled),
.lvf-checkpoint-question__options button:focus-visible:not(:disabled) {
  color: var(--lvf-course-text) !important;
  background-color: #f4fbf7 !important;
  border-color: rgba(10, 122, 66, .42) !important;
  outline: none;
}

.lvf-knowledge-check__answer:hover:not(:disabled) .lvf-knowledge-check__letter,
.lvf-knowledge-check__answer:focus-visible:not(:disabled) .lvf-knowledge-check__letter,
.lvf-checkpoint-question__options button:hover:not(:disabled) > span:first-child,
.lvf-checkpoint-question__options button:focus-visible:not(:disabled) > span:first-child {
  color: var(--lvf-course-green-deep) !important;
  background: var(--lvf-course-green-soft) !important;
}

.lvf-knowledge-check__answer.is-correct,
.lvf-knowledge-check__answer.is-correct:hover,
.lvf-knowledge-check__answer.is-correct:focus-visible,
.lvf-checkpoint-question__options button.is-correct,
.lvf-checkpoint-question__options button.is-correct:hover,
.lvf-checkpoint-question__options button.is-correct:focus-visible {
  color: var(--lvf-course-green-deep) !important;
  background: #edf9f1 !important;
  border-color: rgba(10, 122, 66, .45) !important;
}

.lvf-knowledge-check__answer.is-wrong,
.lvf-knowledge-check__answer.is-wrong:hover,
.lvf-knowledge-check__answer.is-wrong:focus-visible,
.lvf-checkpoint-question__options button.is-wrong,
.lvf-checkpoint-question__options button.is-wrong:hover,
.lvf-checkpoint-question__options button.is-wrong:focus-visible {
  color: #7f2f2f !important;
  background: #fff5f5 !important;
  border-color: #e5aaaa !important;
}

/* Disabled/mastered options stay readable and stable; no hover surprises. */
.lvf-knowledge-check__answer:disabled,
.lvf-checkpoint-question__options button:disabled {
  color: #536174 !important;
  background: #f8faf9 !important;
  opacity: 1;
  cursor: default;
  transform: none;
  box-shadow: none;
}

.lvf-knowledge-check__answer.is-correct:disabled,
.lvf-checkpoint-question__options button.is-correct:disabled {
  color: var(--lvf-course-green-deep) !important;
  background: #edf9f1 !important;
}

/* Small consistency polish for authored question blocks. */
.lvf-checkpoint-authored-content [data-lvf-checkpoint-question] {
  padding: clamp(1rem, 2vw, 1.35rem);
}

@media (max-width: 760px) {
  .lvf-checkpoint-question__top {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .lvf-checkpoint-question__number {
    width: 36px;
    height: 36px;
  }

  .lvf-checkpoint-question__top h3,
  .lvf-checkpoint-question__top h4 {
    grid-column: 2;
  }

  .lvf-checkpoint-question__mastered {
    grid-column: 2;
    justify-self: start;
  }

  .lvf-checkpoint-authored-content > .lvf-review-box:first-child,
  .lvf-checkpoint-authored-content > [data-lvf-checkpoint-assessment-content] > .lvf-review-box:first-child {
    margin-top: 1rem;
  }
}


/* =========================================================
   v0.6.6 — Checkpoint Heading Alignment Hotfix
   Layout-only patch. The question number, title and mastery
   badge are forced into one flex row to avoid theme/grid
   interference in authored checkpoint content.
   ========================================================= */

.lvf-checkpoint-question__top {
  display: flex !important;
  flex-wrap: nowrap;
  align-items: flex-start !important;
  gap: .9rem !important;
  width: 100%;
  margin-bottom: 1rem;
}

.lvf-checkpoint-question__number {
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  margin: 0 !important;
  align-self: flex-start !important;
}

.lvf-checkpoint-question__top h3,
.lvf-checkpoint-question__top h4 {
  flex: 1 1 auto;
  min-width: 0;
  width: auto !important;
  margin: .18rem 0 0 !important;
  padding: 0 !important;
  align-self: flex-start;
  text-align: left !important;
}

.lvf-checkpoint-question__mastered {
  flex: 0 0 auto;
  margin-left: auto;
  align-self: flex-start !important;
  margin-top: .12rem;
}

@media (max-width: 760px) {
  .lvf-checkpoint-question__top {
    flex-wrap: wrap;
    gap: .7rem .75rem !important;
  }

  .lvf-checkpoint-question__number {
    flex-basis: 36px;
    width: 36px;
    height: 36px;
  }

  .lvf-checkpoint-question__top h3,
  .lvf-checkpoint-question__top h4 {
    flex: 1 1 calc(100% - 52px);
  }

  .lvf-checkpoint-question__mastered {
    margin-left: 48px;
    margin-right: auto;
  }
}

/* =========================================================
   v0.6.7 — Mobile UI polish
   UI-only patch:
   1) Center checkpoint summary mastery status on small screens.
   2) Prevent theme button hover/focus/active styles from turning
      the mobile Course Contents toggle blue or leaving it blue
      after interaction.
   ========================================================= */

@media (max-width: 780px) {
  .lvf-checkpoint-summary__action > span {
    width: 100%;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 1050px) {
  .lvf-course-navigator-toggle,
  .lvf-course-navigator-toggle:hover,
  .lvf-course-navigator-toggle:focus,
  .lvf-course-navigator-toggle:active,
  .lvf-course-navigator-toggle[aria-expanded='true'] {
    color: var(--lvf-course-green-deep) !important;
    background: var(--lvf-course-green-soft) !important;
    border-color: rgba(10, 122, 66, 0.24) !important;
    text-decoration: none !important;
    box-shadow: none !important;
  }

  .lvf-course-navigator-toggle:focus-visible {
    color: var(--lvf-course-green-deep) !important;
    background: var(--lvf-course-green-soft) !important;
    border-color: rgba(10, 122, 66, 0.44) !important;
    outline: 3px solid rgba(10, 122, 66, 0.14) !important;
    outline-offset: 2px;
    box-shadow: none !important;
  }
}


/* v0.6.8 — Course Navigator hover/focus color hardening */
.lvf-course-navigator__unit-toggle,
.lvf-course-navigator__unit-toggle:visited,
.lvf-course-navigator__unit-toggle:hover,
.lvf-course-navigator__unit-toggle:focus,
.lvf-course-navigator__unit-toggle:focus-visible,
.lvf-course-navigator__unit-toggle:active,
.lvf-course-navigator__unit.is-current-unit > .lvf-course-navigator__unit-toggle {
  color: var(--lvf-course-text) !important;
  text-decoration: none !important;
}

.lvf-course-navigator__unit-toggle:hover,
.lvf-course-navigator__unit-toggle:focus-visible,
.lvf-course-navigator__unit-toggle:active,
.lvf-course-navigator__unit.is-current-unit > .lvf-course-navigator__unit-toggle {
  background: var(--lvf-course-green-faint) !important;
}

.lvf-course-navigator__unit-toggle > span:first-child {
  color: var(--lvf-course-text) !important;
}

.lvf-course-navigator__unit-toggle .lvf-course-navigator__unit-meta,
.lvf-course-navigator__unit-toggle::after {
  color: var(--lvf-course-muted) !important;
}

.lvf-course-navigator__checkpoint-link,
.lvf-course-navigator__checkpoint-link:link,
.lvf-course-navigator__checkpoint-link:visited,
.lvf-course-navigator__checkpoint-link:hover,
.lvf-course-navigator__checkpoint-link:focus,
.lvf-course-navigator__checkpoint-link:focus-visible,
.lvf-course-navigator__checkpoint-link:active {
  color: #087a40 !important;
  text-decoration: none !important;
}

.lvf-course-navigator__checkpoint-link:hover,
.lvf-course-navigator__checkpoint-link:focus-visible,
.lvf-course-navigator__checkpoint-link:active {
  background: #eef8f2 !important;
  border-color: rgba(10, 122, 66, .42) !important;
}

.lvf-course-navigator__checkpoint-link > span,
.lvf-course-navigator__checkpoint-link:hover > span,
.lvf-course-navigator__checkpoint-link:focus-visible > span,
.lvf-course-navigator__checkpoint-link:active > span {
  color: #087a40 !important;
}


/* v0.7.1 production-content safeguards */
.lvf-unit-checkpoint__unconfigured {
  margin: 18px 0 0;
  padding: 18px 20px;
  border: 1px dashed #b9d9c8;
  border-radius: 16px;
  background: #f7fbf8;
  color: #355246;
}
.lvf-unit-checkpoint__unconfigured strong {
  display: block;
  margin-bottom: 4px;
  color: #086c3d;
}
.lvf-unit-checkpoint__unconfigured p { margin: 0; }
.lvf-lesson-completion-hint--missing {
  border-style: dashed;
}

/* ========================================================================== 
   v0.9.2 — Native Lesson Hub / Course Lessons archive
   ========================================================================== */
.lvf-course-shell--lesson-library {
  min-height: 60vh;
}

.lvf-lesson-library-hero__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.35rem;
}

.lvf-lesson-library-hero__stats span {
  display: inline-flex;
  align-items: baseline;
  gap: 0.28rem;
  padding: 0.48rem 0.72rem;
  border: 1px solid rgba(10, 122, 66, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: #496054;
  font-size: 0.88rem;
  font-weight: 720;
}

.lvf-lesson-library-hero__stats strong {
  color: var(--lvf-course-green-deep);
}

.lvf-lesson-library-tools {
  display: grid;
  grid-template-columns: minmax(240px, 0.85fr) minmax(0, 2fr);
  align-items: end;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-lesson-library-tools__copy h2 {
  margin: 0.28rem 0 0.4rem;
  color: var(--lvf-course-text);
  font-size: clamp(1.45rem, 2.5vw, 2rem);
  line-height: 1.1;
}

.lvf-lesson-library-tools__copy > p:last-child {
  margin: 0;
  color: var(--lvf-course-muted);
}

.lvf-lesson-library-search {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) minmax(180px, 0.9fr) auto;
  align-items: end;
  gap: 0.75rem;
}

.lvf-lesson-library-search__field {
  min-width: 0;
}

.lvf-lesson-library-search__field label {
  display: block;
  margin: 0 0 0.36rem;
  color: var(--lvf-course-text);
  font-size: 0.82rem;
  font-weight: 800;
}

.lvf-lesson-library-search input,
.lvf-lesson-library-search select {
  display: block;
  width: 100%;
  min-height: 48px;
  margin: 0;
  padding: 0.72rem 0.85rem;
  border: 1px solid #cfddd5;
  border-radius: 12px;
  outline: none;
  background: #fff;
  color: var(--lvf-course-text);
  font: inherit;
  box-shadow: none;
}

.lvf-lesson-library-search input:focus,
.lvf-lesson-library-search select:focus {
  border-color: rgba(10, 122, 66, 0.58);
  box-shadow: 0 0 0 4px var(--lvf-course-green-ring);
}

.lvf-lesson-library-search__clear {
  grid-column: 1 / -1;
  justify-self: end;
  color: var(--lvf-course-green-deep) !important;
  font-size: 0.84rem;
  font-weight: 800;
  text-decoration: none !important;
}

.lvf-lesson-library-groups {
  display: grid;
  gap: 1.45rem;
}

.lvf-lesson-course-group {
  overflow: hidden;
  border: 1px solid var(--lvf-course-line);
  border-radius: 22px;
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-lesson-course-group__header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.5rem;
  border-bottom: 1px solid var(--lvf-course-line);
  background:
    radial-gradient(circle at 94% 10%, rgba(10, 122, 66, 0.085), transparent 30%),
    var(--lvf-course-green-faint);
}

.lvf-lesson-course-group__header h2 {
  margin: 0.28rem 0 0;
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  line-height: 1.15;
}

.lvf-lesson-course-group__header h2 a {
  color: var(--lvf-course-text) !important;
  text-decoration: none !important;
}

.lvf-lesson-course-group__course-link {
  flex: 0 0 auto;
  color: var(--lvf-course-green-deep) !important;
  font-weight: 800;
  text-decoration: none !important;
}

.lvf-lesson-unit-group {
  padding: 1.35rem 1.5rem 1.5rem;
}

.lvf-lesson-unit-group + .lvf-lesson-unit-group {
  border-top: 1px solid var(--lvf-course-line);
}

.lvf-lesson-unit-group__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.lvf-lesson-unit-group__header h3 {
  margin: 0;
  color: var(--lvf-course-text);
  font-size: 1.12rem;
  font-weight: 850;
}

.lvf-lesson-unit-group__header span {
  color: var(--lvf-course-muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.lvf-lesson-library-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.lvf-lesson-library-card {
  display: flex;
  min-width: 0;
  overflow: hidden;
  flex-direction: column;
  border: 1px solid var(--lvf-course-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 6px 22px rgba(19, 49, 36, 0.045);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.lvf-lesson-library-card:hover {
  transform: translateY(-2px);
  border-color: rgba(10, 122, 66, 0.28);
  box-shadow: 0 14px 32px rgba(19, 49, 36, 0.08);
}

.lvf-lesson-library-card.is-completed {
  border-color: rgba(10, 122, 66, 0.34);
}

.lvf-lesson-library-card__image {
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--lvf-course-green-soft);
}

.lvf-lesson-library-card__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lvf-lesson-library-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
  padding: 1.05rem;
}

.lvf-lesson-library-card__topline,
.lvf-lesson-library-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
}

.lvf-lesson-library-card__number {
  color: var(--lvf-course-green-deep);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}

.lvf-lesson-state-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0.28rem 0.55rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 999px;
  color: #607069;
  background: #f8faf9;
  font-size: 0.7rem;
  font-weight: 850;
  line-height: 1;
  white-space: nowrap;
  text-transform: uppercase;
}

.lvf-lesson-library-card.is-visited .lvf-lesson-state-badge {
  border-color: rgba(10, 122, 66, 0.18);
  color: var(--lvf-course-green-deep);
  background: var(--lvf-course-green-soft);
}

.lvf-lesson-library-card.is-completed .lvf-lesson-state-badge {
  border-color: var(--lvf-course-green);
  color: #fff;
  background: var(--lvf-course-green);
}

.lvf-lesson-library-card__title {
  margin: 0.72rem 0 0.62rem;
  color: var(--lvf-course-text);
  font-size: 1.18rem;
  line-height: 1.25;
}

.lvf-lesson-library-card__title a {
  color: inherit !important;
  text-decoration: none !important;
}

.lvf-lesson-library-card__excerpt {
  margin: 0 0 1rem;
  color: var(--lvf-course-muted);
  font-size: 0.94rem;
  line-height: 1.55;
}

.lvf-lesson-library-card__footer {
  margin-top: auto;
  padding-top: 0.78rem;
  border-top: 1px solid #edf2ef;
}

.lvf-lesson-library-card__footer > span {
  color: var(--lvf-course-muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.lvf-lesson-library-card__footer a {
  color: var(--lvf-course-green-deep) !important;
  font-size: 0.88rem;
  font-weight: 850;
  text-decoration: none !important;
}

.lvf-lesson-library-pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem;
}

.lvf-lesson-library-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 42px;
  padding: 0.5rem 0.72rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 10px;
  background: #fff;
  color: var(--lvf-course-green-deep) !important;
  font-weight: 800;
  text-decoration: none !important;
}

.lvf-lesson-library-pagination .page-numbers.current {
  border-color: var(--lvf-course-green);
  background: var(--lvf-course-green);
  color: #fff !important;
}

.lvf-lesson-library-empty {
  padding: clamp(2rem, 5vw, 4rem);
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: #fff;
  text-align: center;
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-lesson-library-empty h2 {
  margin: 0.4rem 0 0.6rem;
  color: var(--lvf-course-text);
}

.lvf-lesson-library-empty > p:not(.lvf-course-card__eyebrow) {
  margin: 0 auto 1.1rem;
  color: var(--lvf-course-muted);
}

@media (max-width: 980px) {
  .lvf-lesson-library-tools {
    grid-template-columns: 1fr;
  }

  .lvf-lesson-library-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .lvf-course-shell--lesson-library {
    padding-inline: 0.75rem;
  }

  .lvf-lesson-library-search {
    grid-template-columns: 1fr;
  }

  .lvf-lesson-library-search .lvf-course-button,
  .lvf-lesson-library-search__clear {
    width: 100%;
    justify-self: stretch;
    text-align: center;
  }

  .lvf-lesson-course-group__header {
    align-items: flex-start;
    flex-direction: column;
  }

  .lvf-lesson-unit-group {
    padding: 1rem;
  }

  .lvf-lesson-library-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .lvf-lesson-library-hero__stats {
    display: grid;
    grid-template-columns: 1fr;
  }

  .lvf-lesson-library-hero__stats span {
    justify-content: center;
  }

  .lvf-lesson-unit-group__header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.25rem;
  }
}

/* ========================================================================== 
   v0.9.3 — Native Course Hub Refresh
   ========================================================================== */
.lvf-course-hub-hero__stats {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem;
  margin-top: 1.45rem;
}

.lvf-course-hub-hero__stats span {
  display: inline-flex;
  align-items: center;
  gap: .28rem;
  min-height: 42px;
  padding: .55rem .82rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: #365447;
  font-size: .9rem;
  font-weight: 750;
}

.lvf-course-hub-hero__stats strong { color: var(--lvf-course-green-deep); }

.lvf-course-hub-tools {
  display: grid;
  grid-template-columns: minmax(260px,.75fr) minmax(420px,1.25fr);
  gap: clamp(1.5rem,4vw,3.25rem);
  align-items: end;
  margin: 0 0 1.65rem;
  padding: clamp(1.5rem,3vw,2.35rem);
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-hub-tools__copy h2,
.lvf-course-hub-results__header h2,
.lvf-course-hub-guide h2 {
  margin: .35rem 0 .55rem;
  color: var(--lvf-course-text);
  font-size: clamp(1.65rem,3vw,2.25rem);
  line-height: 1.12;
}

.lvf-course-hub-tools__copy > p:last-child,
.lvf-course-hub-guide__intro > p:last-child {
  margin: 0;
  color: var(--lvf-course-muted);
}

.lvf-course-hub-search label {
  display: block;
  margin-bottom: .45rem;
  color: var(--lvf-course-text);
  font-size: .88rem;
  font-weight: 800;
}

.lvf-course-hub-search__row {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: .75rem;
}

.lvf-course-hub-search input[type="search"] {
  width: 100%;
  min-height: 52px;
  padding: .75rem 1rem;
  border: 1px solid #d7e4dd;
  border-radius: 13px;
  outline: none;
  background: #fff;
  color: var(--lvf-course-text);
  font: inherit;
}

.lvf-course-hub-search input[type="search"]:focus {
  border-color: rgba(10,122,66,.55);
  box-shadow: 0 0 0 4px var(--lvf-course-green-ring);
}

.lvf-course-hub-search__clear {
  display: inline-block;
  margin-top: .55rem;
  color: var(--lvf-course-green-deep);
  font-size: .88rem;
  font-weight: 800;
  text-decoration: none;
}

.lvf-course-hub-results {
  overflow: hidden;
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-hub-results__header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.65rem 1.9rem;
  border-bottom: 1px solid var(--lvf-course-line);
  background: linear-gradient(110deg,#fff 0%,#f0f9f4 100%);
}

.lvf-course-hub-results__lesson-link,
.lvf-course-card__details-link {
  color: var(--lvf-course-green-deep) !important;
  font-weight: 800;
  text-decoration: none !important;
}

.lvf-course-library-grid--hub {
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 0;
}

.lvf-course-card--hub {
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.lvf-course-card--hub:nth-child(odd) { border-right: 1px solid var(--lvf-course-line); }
.lvf-course-card--hub:nth-child(n+3) { border-top: 1px solid var(--lvf-course-line); }
.lvf-course-card--hub:hover { transform: none; box-shadow: none; }

.lvf-course-card__topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
}

.lvf-course-card__free-badge {
  flex: 0 0 auto;
  padding: .28rem .52rem;
  border-radius: 999px;
  color: var(--lvf-course-green-deep);
  background: var(--lvf-course-green-soft);
  font-size: .72rem;
  font-weight: 850;
}

.lvf-course-card--hub .lvf-course-card__title { font-size: clamp(1.45rem,2.5vw,1.8rem); }
.lvf-course-card--hub .lvf-course-card__excerpt { line-height: 1.65; }
.lvf-course-card--hub .lvf-course-card__meta { margin-top: .3rem; }
.lvf-course-card--hub .lvf-course-card__meta strong { color: var(--lvf-course-green-deep); }

.lvf-course-card__footer-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .9rem 1rem;
  margin-top: .2rem;
}

.lvf-course-local-progress--card { margin: .4rem 0 1rem; }

.lvf-course-hub-guide {
  margin-top: 1.65rem;
  padding: clamp(1.6rem,3.5vw,2.7rem);
  border: 1px solid rgba(10,122,66,.14);
  border-radius: var(--lvf-course-radius);
  background: linear-gradient(135deg,#f7fbf8 0%,#eef8f2 100%);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-hub-guide__intro { max-width: 900px; }

.lvf-course-hub-guide__grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 1rem;
  margin-top: 1.45rem;
}

.lvf-course-hub-guide__grid article {
  padding: 1.2rem 1.25rem;
  border: 1px solid rgba(10,122,66,.12);
  border-radius: 15px;
  background: rgba(255,255,255,.78);
}

.lvf-course-hub-guide__grid h3 {
  margin: 0 0 .45rem;
  color: var(--lvf-course-text);
  font-size: 1.08rem;
}

.lvf-course-hub-guide__grid p {
  margin: 0;
  color: #52685e;
  line-height: 1.65;
}

@media (max-width: 900px) {
  .lvf-course-hub-tools { grid-template-columns: 1fr; }
  .lvf-course-library-grid--hub { grid-template-columns: 1fr; }
  .lvf-course-card--hub:nth-child(odd) { border-right: 0; }
  .lvf-course-card--hub + .lvf-course-card--hub { border-top: 1px solid var(--lvf-course-line); }
}

@media (max-width: 680px) {
  .lvf-course-hub-search__row { grid-template-columns: 1fr; }
  .lvf-course-hub-search__row .lvf-course-button { width: 100%; }
  .lvf-course-hub-results__header { align-items: flex-start; flex-direction: column; padding: 1.35rem; }
  .lvf-course-hub-guide__grid { grid-template-columns: 1fr; }
  .lvf-course-card__topline { align-items: flex-start; }
}

/* =========================================================
   v1.0.4 — Mobile Lesson Density Optimization
   Reclaims horizontal space on phones without changing desktop.
   Keeps comfortable touch targets while reducing stacked gutters.
   ========================================================= */
@media (max-width: 680px) {
  /* Use nearly the full mobile viewport. */
  .lvf-course-engine-page .lvf-course-shell.lvf-course-shell--lesson {
    padding-left: 8px !important;
    padding-right: 8px !important;
  }

  .lvf-course-shell--lesson .lvf-course-shell__inner--lesson {
    width: 100% !important;
    max-width: none !important;
  }

  /* Hero and lesson body should not consume multiple nested gutters. */
  .lvf-course-shell--lesson .lvf-lesson-hero {
    padding: 1.25rem 1rem !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .lvf-course-shell--lesson .lvf-course-navigator-toggle {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .lvf-course-shell--lesson .lvf-lesson-layout,
  .lvf-course-shell--lesson .lvf-lesson-layout__main {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .lvf-course-shell--lesson .lvf-lesson-page__content {
    width: 100% !important;
    max-width: none !important;
    padding: 10px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    border-radius: 14px !important;
  }

  .lvf-course-shell--lesson .lvf-course-context {
    margin-left: 0 !important;
    margin-right: 0 !important;
    margin-bottom: 1rem !important;
    padding: .8rem .9rem !important;
  }

  /* Bottom lesson navigation also benefits from the recovered width. */
  .lvf-course-shell--lesson .lvf-course-sequential-nav {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

@media (max-width: 420px) {
  .lvf-course-engine-page .lvf-course-shell.lvf-course-shell--lesson {
    padding-left: 6px !important;
    padding-right: 6px !important;
  }

  .lvf-course-shell--lesson .lvf-lesson-page__content {
    padding: 8px !important;
  }
}

/* ========================================================================== 
   v1.3.4 — Archive / Landing Page Alignment Hardening

   IMPORTANT: archive templates use <main id="primary" class="lvf-course-shell ...">.
   The global Astra escape-hatch above intentionally zeroes #primary padding with
   !important, which also hits that same <main> element.  Restore Course Engine's
   own shell gutter explicitly after the escape-hatch so plugin-owned archives do
   not run flush to the viewport edge.
   ========================================================================== */
.lvf-course-engine-page #primary.lvf-course-shell.lvf-course-shell--library {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding-block: clamp(2rem, 4vw, 4.5rem) !important;
  padding-inline: clamp(1rem, 3vw, 2rem) !important;
  background: var(--lvf-course-bg) !important;
}

/* One common desktop content rail for every public LVF archive. */
.lvf-course-shell--library > .lvf-course-shell__inner {
  width: min(1280px, 100%) !important;
  max-width: 1280px !important;
  margin-inline: auto !important;
}

/* Keep the major learner-facing archive blocks on the same visual text rail. */
.lvf-course-shell--library {
  --lvf-library-section-pad: clamp(1.5rem, 3vw, 2.5rem);
}

.lvf-course-shell--library .lvf-course-library-hero,
.lvf-course-shell--library .lvf-course-hub-tools,
.lvf-course-shell--library .lvf-lesson-library-tools,
.lvf-course-shell--library .lvf-course-hub-guide {
  padding-inline: var(--lvf-library-section-pad) !important;
}

.lvf-course-shell--library .lvf-course-hub-results__header,
.lvf-course-shell--library .lvf-lesson-course-group__header,
.lvf-course-shell--library .lvf-lesson-unit-group {
  padding-inline: var(--lvf-library-section-pad) !important;
}

/* Flashcard hub used a legacy 1100px nested container, which visibly indented
   it relative to the shared hero/guide.  It now follows the same 1280px rail. */
.lvf-course-shell--flashcard-hub .lvf-fc-hub {
  width: 100% !important;
  max-width: none !important;
  margin: 0 0 1.65rem !important;
  padding: var(--lvf-library-section-pad) !important;
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-shell--flashcard-hub .lvf-fc-hub > header,
.lvf-course-shell--flashcard-hub .lvf-fc-hub-grid,
.lvf-course-shell--flashcard-hub .lvf-course-library-pagination,
.lvf-course-shell--flashcard-hub .lvf-course-empty-state {
  width: 100%;
  max-width: none;
  margin-inline: 0;
}

/* A single course should use the available results width instead of looking
   accidentally stranded in the left half of a two-column grid. */
.lvf-course-library-grid--hub > .lvf-course-card--hub:only-child {
  grid-column: 1 / -1;
  border-right: 0 !important;
}

@media (max-width: 720px) {
  .lvf-course-engine-page #primary.lvf-course-shell.lvf-course-shell--library {
    padding-block: 1rem !important;
    padding-inline: 0.7rem !important;
  }

  .lvf-course-shell--library {
    --lvf-library-section-pad: 1rem;
  }
}

/* ========================================================================== 
   v1.3.5 — Course + Lesson Hub Rail Alignment Hardening

   The course and lesson archives still mixed two visual alignment systems:
   split search/tool grids and shallower nested card/group padding.  On wide
   screens that made later sections appear to drift left/right even though the
   outer archive shell was centered.  This layer gives both hubs one explicit
   content rail from hero -> search -> results -> cards/groups -> guide.
   ========================================================================== */
.lvf-course-engine-page #primary.lvf-course-shell.lvf-course-shell--course-hub,
.lvf-course-engine-page #primary.lvf-course-shell.lvf-course-shell--lesson-library {
  --lvf-library-section-pad: clamp(1.5rem, 3vw, 2.5rem);
}

/* Discovery/search panels: copy starts on the same rail as the form instead of
   using a detached two-column layout that visually looked misaligned. */
.lvf-course-engine-page #primary.lvf-course-shell--course-hub .lvf-course-hub-tools,
.lvf-course-engine-page #primary.lvf-course-shell--lesson-library .lvf-lesson-library-tools {
  display: block !important;
  padding: var(--lvf-library-section-pad) !important;
}

.lvf-course-engine-page #primary.lvf-course-shell--course-hub .lvf-course-hub-tools__copy,
.lvf-course-engine-page #primary.lvf-course-shell--lesson-library .lvf-lesson-library-tools__copy {
  width: 100% !important;
  max-width: 900px !important;
  margin: 0 0 1.25rem !important;
}

.lvf-course-engine-page #primary.lvf-course-shell--course-hub .lvf-course-hub-search,
.lvf-course-engine-page #primary.lvf-course-shell--lesson-library .lvf-lesson-library-search {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
}

/* Course results: every textual layer now shares the same inset as the hero
   and discovery panel.  This is especially visible when only one course card
   spans the full results width. */
.lvf-course-engine-page #primary.lvf-course-shell--course-hub .lvf-course-hub-results__header,
.lvf-course-engine-page #primary.lvf-course-shell--course-hub .lvf-course-card--hub .lvf-course-card__body,
.lvf-course-engine-page #primary.lvf-course-shell--course-hub .lvf-course-hub-guide {
  padding-left: var(--lvf-library-section-pad) !important;
  padding-right: var(--lvf-library-section-pad) !important;
}

/* Lesson results: course heading, unit heading and lesson cards are all
   anchored to the exact same archive rail. */
.lvf-course-engine-page #primary.lvf-course-shell--lesson-library .lvf-lesson-course-group__header,
.lvf-course-engine-page #primary.lvf-course-shell--lesson-library .lvf-lesson-unit-group {
  padding-left: var(--lvf-library-section-pad) !important;
  padding-right: var(--lvf-library-section-pad) !important;
}

/* Remove the extra visual indentation inside lesson cards while retaining
   comfortable card padding.  The card grid itself is already on the rail. */
.lvf-course-engine-page #primary.lvf-course-shell--lesson-library .lvf-lesson-library-card__body {
  padding: 1.15rem !important;
}

@media (max-width: 720px) {
  .lvf-course-engine-page #primary.lvf-course-shell.lvf-course-shell--course-hub,
  .lvf-course-engine-page #primary.lvf-course-shell.lvf-course-shell--lesson-library {
    --lvf-library-section-pad: 1rem;
  }

  .lvf-course-engine-page #primary.lvf-course-shell--course-hub .lvf-course-hub-tools__copy,
  .lvf-course-engine-page #primary.lvf-course-shell--lesson-library .lvf-lesson-library-tools__copy {
    margin-bottom: 1rem !important;
  }
}


/* === v1.6.0 IELTS resource library + lesson applications === */
.lvf-course-engine-page .lvf-ielts-hero,
.lvf-course-engine-page .lvf-ielts-resource__hero{background:linear-gradient(135deg,#fff 0%,#f4fbf7 60%,#e9f8ef 100%);border:1px solid #d8ebdf;border-radius:28px;padding:3rem;box-shadow:0 18px 45px rgba(18,72,47,.08)}
.lvf-ielts-card-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1.25rem;margin-top:1.5rem}.lvf-ielts-card{display:flex;flex-direction:column;min-height:240px;padding:1.4rem;border:1px solid #dce9e1;border-radius:22px;background:#fff;box-shadow:0 12px 28px rgba(18,72,47,.06)}.lvf-ielts-card h3{margin:.5rem 0 .7rem;font-size:1.3rem}.lvf-ielts-card h3 a{color:#0f2444!important;text-decoration:none!important}.lvf-ielts-card__meta,.lvf-ielts-resource__badges{display:flex;flex-wrap:wrap;gap:.45rem}.lvf-ielts-card__meta span,.lvf-ielts-resource__badges span{display:inline-flex;padding:.34rem .62rem;border:1px solid #cfe7d8;border-radius:999px;background:#f4fbf7;color:#086b3c;font-size:.82rem;font-weight:700}.lvf-ielts-card__footer{display:flex;justify-content:space-between;gap:1rem;margin-top:auto;padding-top:1rem;border-top:1px solid #edf2ef}.lvf-ielts-card__footer a,.lvf-ielts-resource__footer a{color:#087a42!important;font-weight:800;text-decoration:none!important}.lvf-ielts-empty{margin-top:1.5rem;padding:2rem;border:1px dashed #b9d9c5;border-radius:20px;background:#fff}.lvf-ielts-resource{max-width:1100px;margin:0 auto}.lvf-ielts-resource__hero h1{margin:.35rem 0 1rem;color:#0f2444;font-size:clamp(2.2rem,5vw,4.4rem);line-height:1.05}.lvf-ielts-resource__vocab{margin:1.4rem 0;padding:1rem 1.25rem;border:1px solid #d7eadf;border-radius:18px;background:#f5fbf7}.lvf-ielts-resource__vocab p{margin:.35rem 0 0}.lvf-ielts-resource__content{margin:1.4rem 0;padding:2rem;border:1px solid #e0e9e3;border-radius:24px;background:#fff}.lvf-ielts-resource__footer{margin:1rem 0 2rem}
.lvf-structured-lesson .lvf-ielts-applications{display:grid;gap:1rem}.lvf-structured-lesson .lvf-ielts-application{padding:1.3rem;border:1px solid #cfe7d8;border-radius:20px;background:linear-gradient(180deg,#fbfefc 0%,#f5fbf7 100%);box-shadow:0 10px 25px rgba(18,72,47,.05)}.lvf-structured-lesson .lvf-ielts-application__top{display:flex;justify-content:space-between;align-items:flex-start;gap:1rem}.lvf-structured-lesson .lvf-ielts-application__eyebrow{margin:0 0 .3rem!important;color:#087a42!important;font-size:.82rem!important;font-weight:900!important;letter-spacing:.06em!important;text-transform:uppercase}.lvf-structured-lesson .lvf-ielts-application h3{margin:.2rem 0 .65rem!important;color:#0f2444!important}.lvf-structured-lesson .lvf-ielts-application__badges{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:.35rem}.lvf-structured-lesson .lvf-ielts-application__badges span{padding:.28rem .55rem;border:1px solid #cce5d5;border-radius:999px;background:#fff;color:#086b3c;font-size:.78rem;font-weight:800}.lvf-structured-lesson .lvf-ielts-application__prompt{margin:.8rem 0;padding:1rem;border-left:4px solid #0a7a42;border-radius:12px;background:#fff}.lvf-structured-lesson .lvf-ielts-application__prompt p{margin:.35rem 0 0}.lvf-structured-lesson .lvf-ielts-application__questions ol{margin:.5rem 0 0 1.25rem}.lvf-structured-lesson .lvf-ielts-application__details{margin-top:.7rem;border:1px solid #d8e9de;border-radius:12px;background:#fff}.lvf-structured-lesson .lvf-ielts-application__details summary{cursor:pointer;padding:.8rem 1rem;color:#075f36!important;font-weight:800}.lvf-structured-lesson .lvf-ielts-application__details>p,.lvf-structured-lesson .lvf-ielts-application__details>ul,.lvf-structured-lesson .lvf-ielts-application__details>ol{padding:0 1rem 1rem}.lvf-structured-lesson .lvf-ielts-application__targets{margin:.75rem 0}.lvf-structured-lesson .lvf-ielts-application__link{margin:1rem 0 0}.lvf-structured-lesson .lvf-ielts-application__link a{display:inline-flex!important;align-items:center!important;padding:.7rem 1rem!important;border:1px solid #bfe0cb!important;border-radius:999px!important;background:#fff!important;color:#087a42!important;font-weight:900!important;text-decoration:none!important}.lvf-structured-lesson .lvf-ielts-application__link a:hover,.lvf-structured-lesson .lvf-ielts-application__link a:focus{background:#0a7a42!important;color:#fff!important;border-color:#0a7a42!important}
@media(max-width:900px){.lvf-ielts-card-grid{grid-template-columns:1fr 1fr}.lvf-course-engine-page .lvf-ielts-hero,.lvf-course-engine-page .lvf-ielts-resource__hero{padding:2rem}.lvf-structured-lesson .lvf-ielts-application__top{flex-direction:column}.lvf-structured-lesson .lvf-ielts-application__badges{justify-content:flex-start}}@media(max-width:640px){.lvf-ielts-card-grid{grid-template-columns:1fr}.lvf-course-engine-page .lvf-ielts-hero,.lvf-course-engine-page .lvf-ielts-resource__hero{padding:1.35rem;border-radius:20px}.lvf-ielts-resource__content{padding:1.2rem}}


/* === v1.6.1 Structured IELTS long-form content rendering === */
.lvf-structured-lesson .lvf-ielts-application__passage{margin:.85rem 0;padding:1.15rem 1.2rem;border:1px solid #d7eadf;border-radius:16px;background:#fff}
.lvf-structured-lesson .lvf-ielts-application__content-label{margin:0 0 .35rem!important;color:#087a42!important;font-size:.78rem!important;font-weight:900!important;letter-spacing:.06em!important;text-transform:uppercase}
.lvf-structured-lesson .lvf-ielts-application__passage h4{margin:.1rem 0 .75rem!important;color:#0f2444!important;font-size:1.15rem!important}
.lvf-structured-lesson .lvf-ielts-application__passage p:not(.lvf-ielts-application__content-label){margin:.65rem 0 0!important;line-height:1.72!important}
.lvf-structured-lesson .lvf-ielts-transcript{display:grid!important;gap:.7rem!important;padding:0 1rem 1rem!important}
.lvf-structured-lesson .lvf-ielts-transcript__turn{padding:.75rem .85rem!important;border:1px solid #e3eee7!important;border-radius:12px!important;background:#f9fcfa!important}
.lvf-structured-lesson .lvf-ielts-transcript__speaker{display:block!important;margin:0 0 .2rem!important;color:#087a42!important;font-size:.8rem!important;font-weight:900!important;text-transform:uppercase!important;letter-spacing:.04em!important}
.lvf-structured-lesson .lvf-ielts-transcript__turn p{margin:0!important;line-height:1.65!important}


/* v1.6.2 — IELTS rail alignment + audio controls */
.lvf-course-shell--ielts-hub .lvf-ielts-library-panel{width:100%!important;max-width:none!important;margin:0 0 1.65rem!important;padding:var(--lvf-library-section-pad)!important;border:1px solid var(--lvf-course-line)!important;border-radius:var(--lvf-course-radius)!important;background:var(--lvf-course-surface)!important;box-shadow:var(--lvf-course-shadow-soft)!important}
.lvf-course-shell--ielts-hub .lvf-ielts-library-panel>p,.lvf-course-shell--ielts-hub .lvf-ielts-library-panel>h2,.lvf-course-shell--ielts-hub .lvf-ielts-card-grid,.lvf-course-shell--ielts-hub .lvf-ielts-empty,.lvf-course-shell--ielts-hub .navigation.pagination{width:100%!important;max-width:none!important;margin-left:0!important;margin-right:0!important}
.lvf-structured-lesson .lvf-ielts-audio{display:flex!important;align-items:center!important;flex-wrap:wrap!important;gap:.75rem!important;margin:.8rem 0 1rem!important}
.lvf-structured-lesson .lvf-ielts-audio__button{display:inline-flex!important;align-items:center!important;gap:.35rem!important}
.lvf-structured-lesson .lvf-ielts-audio__label{color:#075f36!important;font-weight:800!important}
.lvf-structured-lesson .lvf-ielts-audio audio,.lvf-ielts-resource__audio audio{width:min(100%,620px)!important}
.lvf-ielts-resource__audio{display:grid;gap:.65rem;margin:1.4rem 0;padding:1rem 1.25rem;border:1px solid #d7eadf;border-radius:18px;background:#f5fbf7}

/* v1.7.5 — standalone IELTS now reuses the exact single-lesson rail.
   IMPORTANT: do not put IELTS-specific width/padding rules on #primary.
   The main wrapper is intentionally identical to single-lvf_lesson.php so the
   shared .lvf-course-shell--lesson + .lvf-course-shell__inner--lesson rules own
   the page rail on every device. */
.lvf-ielts-resource-page{width:100%!important;max-width:none!important;margin:0!important}
.lvf-ielts-resource-page .lvf-ielts-resource__hero{margin-bottom:1.1rem!important}
.lvf-ielts-resource__subtitle{max-width:980px;margin:.1rem 0 1.2rem!important;color:#52657b!important;font-size:clamp(1rem,1.35vw,1.18rem)!important;line-height:1.7!important}
@media(max-width:680px){.lvf-ielts-resource__subtitle{margin-bottom:1rem!important;font-size:1rem!important;line-height:1.65!important}}


/* v1.7.5 — exact lesson hero geometry for standalone IELTS */
.lvf-course-engine-page .lvf-lesson-hero.lvf-ielts-resource__hero{
  display:flex!important;align-items:flex-end!important;justify-content:space-between!important;gap:1rem!important;
  margin:0 0 1.1rem!important;
  padding:clamp(1.7rem,4vw,2.7rem)!important;
  border:1px solid var(--lvf-course-line)!important;
  border-radius:22px!important;
  background:radial-gradient(circle at 93% 15%,rgba(10,122,66,.075),transparent 28%),var(--lvf-course-surface)!important;
  box-shadow:var(--lvf-course-shadow-soft)!important;
}
@media(max-width:680px){
  .lvf-course-engine-page .lvf-lesson-hero.lvf-ielts-resource__hero{padding:1.25rem 1rem!important;margin-left:0!important;margin-right:0!important;}
}


/* v1.7.8 — IELTS archive card footer refinement.
   Lighter, single-row metadata + CTA treatment that matches the restrained LVF card language. */
.lvf-course-shell--ielts-hub .lvf-ielts-card__footer{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto!important;
  align-items:center!important;
  column-gap:.9rem!important;
  row-gap:.45rem!important;
  padding-top:1rem!important;
}
.lvf-course-shell--ielts-hub .lvf-ielts-card__exam{
  display:block!important;
  min-width:0!important;
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  color:#52657b!important;
  font-size:.76rem!important;
  font-weight:700!important;
  line-height:1.35!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
.lvf-course-shell--ielts-hub .lvf-ielts-card__cta{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:flex-end!important;
  gap:.34rem!important;
  min-height:0!important;
  margin:0!important;
  padding:.22rem 0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  color:#087a42!important;
  font-size:.82rem!important;
  font-weight:800!important;
  line-height:1.25!important;
  text-decoration:none!important;
  white-space:nowrap!important;
  transition:color .18s ease,transform .18s ease!important;
}
.lvf-course-shell--ielts-hub .lvf-ielts-card__cta:hover,
.lvf-course-shell--ielts-hub .lvf-ielts-card__cta:focus{
  background:transparent!important;
  border-color:transparent!important;
  color:#056534!important;
  transform:translateX(2px)!important;
  outline:none!important;
}
@media(max-width:420px){
  .lvf-course-shell--ielts-hub .lvf-ielts-card__footer{
    grid-template-columns:minmax(0,1fr) auto!important;
    column-gap:.65rem!important;
  }
  .lvf-course-shell--ielts-hub .lvf-ielts-card__exam{font-size:.72rem!important;}
  .lvf-course-shell--ielts-hub .lvf-ielts-card__cta{font-size:.78rem!important;}
}

/* ========================================================================== 
   v1.7.9 — Smart archive discovery for IELTS + Flashcards
   Reuse the proven Course/Lesson library search language and rails so the new
   discovery controls feel native to the LVF Course Engine rather than bolted on.
   ========================================================================== */
.lvf-course-engine-page #primary.lvf-course-shell--ielts-hub,
.lvf-course-engine-page #primary.lvf-course-shell--flashcard-hub {
  --lvf-library-section-pad: clamp(1.5rem, 3vw, 2.5rem);
}

.lvf-course-engine-page #primary.lvf-course-shell--ielts-hub .lvf-ielts-library-tools,
.lvf-course-engine-page #primary.lvf-course-shell--flashcard-hub .lvf-flashcard-library-tools {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0 0 1.5rem !important;
  padding: var(--lvf-library-section-pad) !important;
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-engine-page #primary.lvf-course-shell--ielts-hub .lvf-ielts-library-tools .lvf-lesson-library-tools__copy,
.lvf-course-engine-page #primary.lvf-course-shell--flashcard-hub .lvf-flashcard-library-tools .lvf-course-hub-tools__copy {
  width: 100% !important;
  max-width: 900px !important;
  margin: 0 0 1.25rem !important;
}

.lvf-course-engine-page #primary.lvf-course-shell--ielts-hub .lvf-ielts-library-search,
.lvf-course-engine-page #primary.lvf-course-shell--flashcard-hub .lvf-flashcard-library-tools .lvf-course-hub-search {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
}

.lvf-ielts-library-search {
  grid-template-columns: minmax(220px, 1.45fr) minmax(145px, .65fr) minmax(180px, .8fr) auto;
}

.lvf-course-shell--ielts-hub .lvf-ielts-library-panel {
  margin-top: 0 !important;
}

@media (max-width: 1080px) {
  .lvf-ielts-library-search {
    grid-template-columns: minmax(220px, 1.35fr) minmax(145px, .65fr) minmax(180px, .8fr);
  }

  .lvf-ielts-library-search .lvf-course-button {
    grid-column: 1 / -1;
    justify-self: end;
  }
}

@media (max-width: 720px) {
  .lvf-ielts-library-search {
    grid-template-columns: 1fr;
  }

  .lvf-ielts-library-search .lvf-course-button,
  .lvf-ielts-library-search .lvf-lesson-library-search__clear {
    grid-column: auto;
    width: 100%;
    justify-self: stretch;
    text-align: center;
  }
}

/* v1.9.1 — standalone Flashcard Deck uses the same Course Engine rail as Lessons / IELTS */
.lvf-course-engine-page #primary.lvf-course-shell--flashcard-deck{
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  padding:clamp(2rem,4vw,4.5rem) clamp(1rem,3vw,2rem)!important;
}
.lvf-course-shell--flashcard-deck > .lvf-course-shell__inner--lesson{
  width:min(1320px,100%)!important;
  max-width:1320px!important;
  margin:0 auto!important;
}
@media(max-width:680px){
  .lvf-course-engine-page #primary.lvf-course-shell--flashcard-deck{padding-left:8px!important;padding-right:8px!important}
  .lvf-course-shell--flashcard-deck > .lvf-course-shell__inner--lesson{width:100%!important;max-width:none!important}
}

/* v2.0.1 — shared structured internal links */
.lvf-related-links{margin:24px 0;padding:18px 20px;border:1px solid rgba(10,122,66,.16);border-radius:18px;background:#f7fbf8}
.lvf-related-links h3{margin:0 0 12px;color:#113a2b;font-size:1.05rem}
.lvf-related-links__list{display:grid;gap:10px}
.lvf-related-link{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 14px;border:1px solid rgba(10,122,66,.14);border-radius:12px;background:#fff;color:#08783f;text-decoration:none;font-weight:700}
.lvf-related-link:hover,.lvf-related-link:focus{border-color:rgba(10,122,66,.35);box-shadow:0 8px 24px rgba(10,80,45,.08);text-decoration:none}
@media(max-width:720px){.lvf-related-links{padding:14px}.lvf-related-link{padding:11px 12px}}


/* ==========================================================
   v2.0.2 — Related-link theme override hardening
   Own every interactive state so Astra/global link rules cannot
   repaint native LVF related-learning cards blue on hover/focus.
   ========================================================== */
.lvf-course-engine-page a.lvf-related-link,
.lvf-course-shell a.lvf-related-link,
.lvf-ielts-native a.lvf-related-link,
.lvf-flashcard-page a.lvf-related-link,
.lvf-flashcards a.lvf-related-link,
a.lvf-related-link{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:16px!important;
  padding:12px 14px!important;
  border:1px solid rgba(10,122,66,.22)!important;
  border-radius:12px!important;
  background:#fff!important;
  color:#08783f!important;
  -webkit-text-fill-color:#08783f!important;
  text-decoration:none!important;
  font-weight:700!important;
  box-shadow:none!important;
  outline:none;
  transition:background-color .16s ease,border-color .16s ease,color .16s ease,box-shadow .16s ease,transform .16s ease!important;
}
.lvf-course-engine-page a.lvf-related-link:visited,
.lvf-course-shell a.lvf-related-link:visited,
.lvf-ielts-native a.lvf-related-link:visited,
.lvf-flashcard-page a.lvf-related-link:visited,
.lvf-flashcards a.lvf-related-link:visited,
a.lvf-related-link:visited{
  color:#08783f!important;
  -webkit-text-fill-color:#08783f!important;
}
.lvf-course-engine-page a.lvf-related-link:hover,
.lvf-course-engine-page a.lvf-related-link:focus,
.lvf-course-engine-page a.lvf-related-link:focus-visible,
.lvf-course-shell a.lvf-related-link:hover,
.lvf-course-shell a.lvf-related-link:focus,
.lvf-course-shell a.lvf-related-link:focus-visible,
.lvf-ielts-native a.lvf-related-link:hover,
.lvf-ielts-native a.lvf-related-link:focus,
.lvf-ielts-native a.lvf-related-link:focus-visible,
.lvf-flashcard-page a.lvf-related-link:hover,
.lvf-flashcard-page a.lvf-related-link:focus,
.lvf-flashcard-page a.lvf-related-link:focus-visible,
.lvf-flashcards a.lvf-related-link:hover,
.lvf-flashcards a.lvf-related-link:focus,
.lvf-flashcards a.lvf-related-link:focus-visible,
a.lvf-related-link:hover,
a.lvf-related-link:focus,
a.lvf-related-link:focus-visible{
  border-color:#0a7a42!important;
  background:#eef9f2!important;
  color:#075f35!important;
  -webkit-text-fill-color:#075f35!important;
  text-decoration:none!important;
  box-shadow:0 8px 24px rgba(10,80,45,.10)!important;
  transform:translateY(-1px)!important;
  outline:3px solid rgba(10,122,66,.14)!important;
  outline-offset:2px!important;
}
.lvf-course-engine-page a.lvf-related-link *,
.lvf-course-shell a.lvf-related-link *,
.lvf-ielts-native a.lvf-related-link *,
.lvf-flashcard-page a.lvf-related-link *,
.lvf-flashcards a.lvf-related-link *,
a.lvf-related-link *{
  color:inherit!important;
  -webkit-text-fill-color:inherit!important;
  text-decoration:none!important;
}

/* v2.0.5 — individual-course overview stack fix */
.lvf-course-hero__subtitle {
  max-width: 880px;
  margin: 1rem 0 0;
  color: var(--lvf-course-green-deep);
  font-size: clamp(1.08rem, 2vw, 1.32rem);
  font-weight: 600 !important;
  line-height: 1.45;
}

.lvf-course-seo-overview {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  gap: 1rem;
  margin: 0 0 1.5rem;
  padding: clamp(1.35rem, 3vw, 2.15rem);
  border: 1px solid var(--lvf-course-line);
  border-radius: var(--lvf-course-radius);
  background: var(--lvf-course-surface);
  box-shadow: var(--lvf-course-shadow-soft);
}

.lvf-course-seo-overview__lead {
  grid-column: 1 / -1;
  max-width: 950px;
}

.lvf-course-seo-overview__lead h2 {
  margin: 0.28rem 0 0.7rem;
  color: var(--lvf-course-text);
  font-size: clamp(1.55rem, 3vw, 2.2rem);
  line-height: 1.16;
}

.lvf-course-seo-card {
  grid-column: 1 / -1 !important;
  width: 100% !important;
  min-width: 0;
  padding: 1.15rem 1.25rem;
  border: 1px solid var(--lvf-course-line);
  border-radius: 16px;
  background: var(--lvf-course-green-faint);
}

.lvf-course-seo-card h3 {
  margin: 0 0 0.72rem;
  color: var(--lvf-course-text);
  font-size: 1.08rem;
  line-height: 1.3;
}

.lvf-course-seo-card ul {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--lvf-course-muted);
}

.lvf-course-seo-card li + li { margin-top: 0.42rem; }

.lvf-course-seo-card--topics { grid-column: 1 / -1 !important; }

.lvf-course-topic-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.lvf-course-topic-chips span {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0.38rem 0.7rem;
  border: 1px solid rgba(10, 122, 66, 0.16);
  border-radius: 999px;
  color: var(--lvf-course-green-deep);
  background: #fff;
  font-size: 0.9rem;
  font-weight: 750;
}

.lvf-course-page__content > .lvf-related-links {
  margin-top: 2rem;
}

@media (max-width: 680px) {
  .lvf-course-seo-overview {
    grid-template-columns: 1fr;
    border-radius: 16px;
  }

  .lvf-course-seo-card--topics,
  .lvf-course-seo-overview__lead {
    grid-column: auto;
  }
}
