.aifk-lesson {
  margin-top: 32px;
  --lesson-ink: #0f172a;
  --lesson-muted: #64748b;
  --lesson-accent: #1a73e8;
  --lesson-accent-strong: #1d4ed8;
  --lesson-accent-soft: #dbeafe;
  --lesson-warm: #f97316;
  --lesson-card: hsla(0, 0%, 100%, 0.88);
  background-color: #e8eaed;
  color: var(--lesson-ink);
  display: grid;
  font-family: var(--ff-primary);
  gap: 10px;
  grid-template-areas: "sidebar content";
  grid-template-columns: 1fr minmax(0, 5fr);
  padding-bottom: 48px;
}
/* If wdith > 992px */

/* @media screen and (min-width: 992px) {
  .aifk-lesson {
    padding: 0px 16px 32px;
  }
} */
.aifk-lesson--no-sidebar {
  grid-template-areas: "content";
  grid-template-columns: minmax(0, 1fr);
}
.aifk-lesson #aiforkids-sidebar {
  grid-area: sidebar;
  position: sticky;
  top: 72px;
  height: calc(100vh - 72px);
}
.lesson-container {
  grid-area: content;
  margin-top: 3.6rem;
}
.lesson-hero {
  border-radius: 5px;
  overflow: visible;
  position: relative;
}
.lesson-hero__mesh {
  background: radial-gradient(
    circle at 30% 30%,
    hsla(0, 0%, 100%, 0.8),
    transparent 60%
  );
  inset: 0;
  position: absolute;
  z-index: 0;
}
.lesson-hero__inner {
  padding: 22px;
  position: relative;
  z-index: 1;
}
.lesson-breadcrumbs {
  align-items: center;
  color: var(--lesson-muted);
  display: flex;
  flex-wrap: wrap;
  font-size: 13px;
}
.lesson-breadcrumbs a {
  color: var(--lesson-ink);
  text-decoration: none;
}
.aiforkids-breadcrumb-seperator,
.lesson-breadcrumbs {
  vertical-align: middle;
}
.lesson-breadcrumbs span[aria-hidden="true"] {
  color: #cbd5f5;
}
.lesson-breadcrumbs a:hover {
  color: var(--lesson-accent);
}
.lesson-hero__grid {
  align-items: stretch;
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
}
.lesson-hero__content {
  animation: lesson-rise 0.8s ease both;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.lesson-kicker {
  color: var(--lesson-muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.lesson-title {
  font-family: var(--ff-secondary);
  font-size: clamp(28px, 3.2vw, 42px);
  font-weight: 400;
  line-height: 1.08;
  margin: 0;
}
.lesson-excerpt {
  color: var(--lesson-muted);
  font-size: 16px;
  line-height: 1.6;
  margin-top: 4px;
  max-width: min(68ch, 100%);
}
.lesson-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.lesson-chip {
  align-items: center;
  background: hsla(0, 0%, 100%, 0.9);
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  display: inline-flex;
  font-size: 12px;
  font-weight: 600;
  gap: 6px;
  padding: 7px 14px;
}
.lesson-chip--accent {
  background: var(--lesson-accent);
  border-color: transparent;
  color: #fff;
}
.lesson-chip--soft {
  background: var(--lesson-accent-soft);
  border-color: transparent;
}
.lesson-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: start;
  margin-top: 6px;
}
.lesson-primary,
.lesson-secondary {
  align-items: center;
  border-radius: 999px;
  display: inline-flex;
  font-weight: 600;
  justify-content: center;
  padding: 10px 20px;
  text-decoration: none;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}
.lesson-primary {
  background: linear-gradient(
    130deg,
    var(--lesson-accent),
    var(--lesson-accent-strong)
  );
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.25);
  color: #fff;
}
.lesson-secondary {
  background: hsla(0, 0%, 100%, 0.9);
  border: 1px solid #dbe3ee;
  color: var(--lesson-ink);
}
.lesson-actions--card {
  gap: 12px;
  margin-top: 6px;
}
.lesson-primary:hover,
.lesson-secondary:hover {
  box-shadow: 0 10px 18px rgba(31, 42, 58, 0.12);
  transform: translateY(-2px);
}
.lesson-hero__card {
  animation: lesson-rise 0.8s ease both;
  animation-delay: 0.1s;
  background: #fff;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 24px;
  box-shadow:
    0 18px 32px rgba(15, 23, 42, 0.12),
    0 4px 10px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 14px;
  padding: 14px;
}
.lesson-card__media {
  aspect-ratio: 16/9;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 15px;
  display: grid;
  /* min-height: 160px; */
  overflow: hidden;
  place-items: center;
}
.lesson-card__media img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}
.lesson-card__media-fallback {
  color: var(--lesson-ink);
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.lesson-card__progress {
  align-items: center;
  display: grid;
  font-size: 12px;
  font-weight: 600;
  gap: 12px;
  grid-template-columns: auto 1fr auto;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.lesson-card__progress,
.lesson-card__progress-label {
  color: var(--lesson-muted);
}
.lesson-card__progress-track {
  background: #e2e8f0;
  border-radius: 999px;
  height: 8px;
  overflow: hidden;
  position: relative;
}
.lesson-card__progress-track span {
  background: linear-gradient(90deg, var(--lesson-accent), var(--lesson-warm));
  border-radius: inherit;
  inset: 0;
  position: absolute;
}
.lesson-card__progress-value {
  color: var(--lesson-ink);
  font-weight: 700;
}
.lesson-cta {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}
.lesson-pill {
  align-items: center;
  background: #fff;
  border: 1px solid #dbe3ee;
  border-radius: 12px;
  color: var(--lesson-ink);
  display: inline-flex;
  font-size: 13px;
  font-weight: 600;
  gap: 10px;
  letter-spacing: 0.01em;
  min-height: 44px;
  padding: 0 16px;
  text-decoration: none;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease,
    background 0.15s ease;
}
.lesson-pill:hover {
  box-shadow:
    0 2px 4px rgba(15, 23, 42, 0.1),
    0 10px 18px rgba(15, 23, 42, 0.16);
  transform: translateY(-1px);
}
.lesson-pill__icon {
  align-items: center;
  background: #f1f5f9;
  border-radius: 9px;
  color: #f1f5f9;
  display: inline-flex;
  height: 28px;
  justify-content: center;
  width: 28px;
}
.lesson-pill__icon svg {
  display: block;
  height: 16px;
  width: 16px;
}
.lesson-pill__label {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.lesson-pill__title {
  font-weight: 600;
  letter-spacing: 0.01em;
}
.lesson-pill__sub {
  color: rgba(31, 41, 55, 0.7);
  font-size: 11px;
  font-weight: 500;
}
.lesson-pill--primary {
  background: #eef6ff;
  border-color: #cfe3ff;
  color: #1a5fd0;
}
.lesson-pill--primary .lesson-pill__icon {
  background: #dbeafe;
  color: #1a5fd0;
}
.lesson-pill--primary .lesson-pill__sub {
  color: rgba(26, 95, 208, 0.72);
}
.lesson-pill--youtube {
  background: #fff4f4;
  border-color: #ffd6d6;
  color: #c81e1e;
}
.lesson-pill--youtube .lesson-pill__icon {
  background: #ffe0e0;
  color: #c81e1e;
}
.lesson-pill--youtube .lesson-pill__sub {
  color: rgba(200, 30, 30, 0.7);
}
.lesson-pill--youtube:hover {
  box-shadow: 0 8px 16px rgba(200, 30, 30, 0.18);
}
.lesson-share {
  position: relative;
}
.lesson-share summary {
  cursor: pointer;
  list-style: none;
}
.lesson-share summary::-webkit-details-marker {
  display: none;
}
.lesson-pill--share {
  background: #f1f3f4;
  border-color: #dbe3ee;
  color: #1f2937;
}
.lesson-pill--share .lesson-pill__icon {
  background: linear-gradient(135deg, #e2e8f0, #f8fafc);
  color: #475569;
}
.lesson-pill--share:after {
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid;
  content: "";
  height: 0;
  margin-left: 6px;
  width: 0;
}
.lesson-share[open] .lesson-pill--share {
  box-shadow:
    0 2px 4px rgba(15, 23, 42, 0.1),
    0 10px 18px rgba(15, 23, 42, 0.16);
}
.lesson-share__menu {
  backdrop-filter: blur(14px);
  background: hsla(0, 0%, 100%, 0.94);
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 18px;
  box-shadow: 0 24px 36px rgba(15, 23, 42, 0.18);
  display: grid;
  gap: 10px;
  min-width: 260px;
  padding: 12px;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 10;
}
.lesson-share__menu:before {
  background: inherit;
  border-left: 1px solid rgba(148, 163, 184, 0.32);
  border-top: 1px solid rgba(148, 163, 184, 0.32);
  content: "";
  height: 12px;
  position: absolute;
  right: 22px;
  top: -6px;
  transform: rotate(45deg);
  width: 12px;
}
.lesson-share__header {
  color: #94a3b8;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  padding: 2px 4px;
  text-transform: uppercase;
}
.lesson-share__grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.lesson-share__item {
  align-items: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 14px;
  color: #1f2937;
  display: flex;
  flex-direction: column;
  font-size: 12px;
  font-weight: 600;
  gap: 0;
  padding: 6px;
  text-decoration: none;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}
.lesson-share__item:hover {
  background: rgba(248, 250, 252, 0.8);
  border-color: rgba(203, 213, 245, 0.8);
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.12);
  transform: translateY(-2px);
}
.lesson-share__icon {
  align-items: center;
  background: #0f172a;
  border-radius: 50%;
  box-shadow: 0 10px 18px rgba(15, 23, 42, 0.18);
  color: #fff;
  display: inline-flex;
  height: 40px;
  justify-content: center;
  width: 40px;
}
.lesson-share__icon svg {
  height: 16px;
  width: 16px;
}
.lesson-share__item--x .lesson-share__icon {
  background: #0f172a;
}
.lesson-share__item--facebook .lesson-share__icon {
  background: #1877f2;
}
.lesson-share__item--linkedin .lesson-share__icon {
  background: #0a66c2;
}
.lesson-share__item--whatsapp .lesson-share__icon {
  background: #25d366;
}
.lesson-layout {
  margin-top: 15px;
  overflow: visible;
}
.lesson-layout__inner {
  align-items: start;
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(0, 3fr) minmax(0, 1fr);
}
.lesson-layout__inner > * {
  min-width: 0;
}
.lesson-body__card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 5px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  padding: 22px;
}
.lesson-body__header {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 20px;
}
.lesson-body__eyebrow {
  color: var(--lesson-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.lesson-body__badge {
  background: #ecfdf3;
  border-radius: 999px;
  color: #166534;
  font-size: 12px;
  font-weight: 600;
  padding: 8px 16px;
}
.lesson-body__content {
  color: #1c2735;
  font-family: var(--ff-primary);
  font-size: 17px;
  line-height: 1.6;
  margin-top: 16px;
}
.lesson-body__content h2,
.lesson-body__content h3 {
  font-family: var(--ff-secondary);
  margin-top: 24px;
}
.lesson-body__content a {
  color: var(--lesson-accent);
}
.lesson-body__content img,
.lesson-body__content video,
.lesson-body__content iframe {
  height: auto;
  max-width: 100%;
}
.lesson-body__content pre {
  max-width: 100%;
  overflow-x: auto;
}
.lesson-body__content table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  width: 100%;
}
.lesson-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}
.lesson-sidebar {
  align-self: start;
  display: grid;
  gap: 16px;
  min-width: 0;
  position: sticky;
  top: 85px;
}
.lesson-sidebar__stack {
  background: white;
  /* border: 2px solid #bcdff6; */
  border-radius: 18px;
  box-shadow: none;
  display: grid;
  /* gap: 10px; */
  padding: 0;
  overflow: hidden;
  --panel-active-bg: transparent;
  --cut-size: 28px;
  --cut-radius: 22px;
  max-width: 100%;
  min-width: 0;
  width: 100%;
}
.lesson-sidebar__switch {
  display: flex;
  align-items: center;
  gap: 0;
  /* background: #f2f8ff; */
  border: 0;
  border-radius: 0;
  box-shadow: none;
  position: relative;
}
.lesson-sidebar__stack[data-active="nav"] .lesson-sidebar__switch,
.lesson-sidebar__stack[data-active="toc"] .lesson-sidebar__switch {
  background: var(--panel-active-bg);
}
.lesson-sidebar__switch:before {
  content: none;
}
.lesson-switch {
  border: 0;
  background: transparent;
  flex: 1;
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #1f2937;
  padding: 8px 12px;
  border-radius: 0;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s ease;
  position: relative;
  z-index: 1;
  box-shadow: none;
}
.lesson-switch:not(.is-active) {
  background: #ffffff;
}
.lesson-sidebar__stack[data-active="nav"]
  .lesson-switch:last-of-type:not(.is-active) {
  background:
    radial-gradient(
        var(--cut-size) var(--cut-size) at 0 100%,
        transparent 0 var(--cut-radius),
        #ffffff calc(var(--cut-radius) + 1px)
      )
      no-repeat,
    #ffffff;
  background-size: var(--cut-size) var(--cut-size);
  background-position: 0 100%;
}
.lesson-sidebar__stack[data-active="toc"]
  .lesson-switch:first-of-type:not(.is-active) {
  background:
    radial-gradient(
        var(--cut-size) var(--cut-size) at 100% 100%,
        transparent 0 var(--cut-radius),
        #ffffff calc(var(--cut-radius) + 1px)
      )
      no-repeat,
    #ffffff;
  background-size: var(--cut-size) var(--cut-size);
  background-position: 100% 100%;
}
.lesson-switch.is-active {
  z-index: 3;
}
.lesson-switch.is-active::before {
  z-index: 2;
}
.lesson-switch.is-active::after {
  z-index: 4;
}
.lesson-switch:not(.is-active) {
  z-index: 1;
}
.lesson-switch::before,
.lesson-switch::after {
  pointer-events: none;
}
/* .lesson-switch:first-of-type active */
.lesson-switch.is-active:first-of-type {
  box-shadow: inset #0095ff14 11px 20px 20px 0px;
}
.lesson-switch:first-of-type {
  margin-right: 0;
  padding-right: 30px;
}
.lesson-switch:last-of-type {
  margin-left: 0;
  padding-left: 30px;
}
.lesson-switch.is-active {
  background: var(--panel-active-bg);
  border: 0;
  border-radius: 0;
  color: var(--lesson-accent-strong);
  box-shadow: none;
}
.lesson-switch:first-of-type.is-active {
  border-top-right-radius: 16px;
  border-bottom-right-radius: 0;
  border-left: 0;
  border-top: 0;
  border-bottom: 0;
}
.lesson-switch.is-active:not(first-of-type) {
  box-shadow: inset #0095ff14 -2px 20px 20px 0px;
}
.lesson-switch:first-of-type.is-active::before {
  content: "";
  position: absolute;
  background: var(--panel-active-bg);
  z-index: 17;
}
.lesson-switch:first-of-type.is-active::before {
  content: "";
  position: absolute;
  width: 27px;
  left: 99.3%;
  height: 27px;
  top: 48%;
  /* border-left: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-bottom: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-bottom-left-radius: 19px; */
  background: transparent;
}
.lesson-switch:first-of-type.is-active::after {
  content: "";
  position: absolute;
  right: -1px;
  top: -3px;
  width: 29px;
  height: 29px;
  border-right: 2px solid #bcdff6;
  border-top: 2px solid #bcdff6;
  border-top-right-radius: 16px;
  background: transparent;
}
.lesson-switch:last-of-type.is-active {
  border-top-left-radius: 16px;
  border-bottom-left-radius: 0;
  border-right: 0;
  border-top: 0;
  border-bottom: 0;
}
.lesson-switch:last-of-type.is-active::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--panel-active-bg);
  border-top-left-radius: 16px;
  border-bottom-left-radius: 0;
  box-shadow: 0 0 0 2px var(--panel-active-bg);
  z-index: 2;
}
.lesson-switch:last-of-type.is-active::after {
  content: "";
  position: absolute;
  left: -1px;
  top: -3px;
  width: 29px;
  height: 29px;
  border-left: 2px solid #bcdff6;
  border-top: 2px solid #bcdff6;
  border-top-left-radius: 18px;
  background: transparent;
}
.lesson-switch:first-of-type:not(.is-active) {
  border-bottom: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-top: 0;
  border-left: 0;
  border-bottom-right-radius: 19px;
  border-top-right-radius: 0;
}
.lesson-switch:first-of-type:not(.is-active)::after {
  content: "";
  position: absolute;
  right: -1px;
  bottom: -2px;
  width: 28px;
  height: 28px;
  border-right: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-bottom: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-bottom-right-radius: 19px;
  background: transparent;
}
.lesson-switch:last-of-type:not(.is-active) {
  border-bottom: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-top: 0;
  border-right: 0;
  border-bottom-left-radius: 19px;
  border-top-left-radius: 0;
}
.lesson-switch:last-of-type:not(.is-active)::after {
  content: "";
  position: absolute;
  left: -1px;
  bottom: -2px;
  width: 28px;
  height: 28px;
  border-left: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-bottom: 2px solid color(srgb 0.7324 0.8678 0.9594);
  border-bottom-left-radius: 19px;
  background: transparent;
}
.lesson-switch.is-disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.lesson-sidebar__panel {
  background: #ffffff;
  /* border: 1px solid rgba(148, 163, 184, 0.18); */
  border-radius: 18px;
  /* box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08); */
  box-sizing: border-box;
  font-family: var(--ff-primary);
  font-size: 14px;
  max-width: 100%;
  min-width: 0;
  overflow-x: hidden;
  padding: 16px 16px 18px;
  width: 100%;
}
.lesson-sidebar__panel--nav,
.lesson-sidebar__panel--toc {
  max-height: calc(100vh - 240px);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.lesson-sidebar__panel--nav,
.lesson-sidebar__panel--toc {
  scrollbar-width: thin;
  scrollbar-color: #d5d9e3 transparent;
}
.lesson-sidebar__panel--nav::-webkit-scrollbar,
.lesson-sidebar__panel--toc::-webkit-scrollbar {
  width: 6px;
}
.lesson-sidebar__panel--nav::-webkit-scrollbar-thumb,
.lesson-sidebar__panel--toc::-webkit-scrollbar-thumb {
  background: #d5d9e3;
  border-radius: 999px;
}
.lesson-sidebar__panel--nav::-webkit-scrollbar-track,
.lesson-sidebar__panel--toc::-webkit-scrollbar-track {
  background: transparent;
}
.lesson-sidebar__panel.is-active {
  background: #ffffff;
  border-color: rgba(26, 115, 232, 0.22);
}
.lesson-sidebar__panel.is-active .lesson-sidebar__title h3,
.lesson-sidebar__panel.is-active .lesson-sidebar__title span {
  color: var(--lesson-accent-strong);
}
.lesson-sidebar__panel.is-active .lesson-sidebar__title {
  position: relative;
  z-index: 3;
}
.lesson-sidebar__panel.is-hidden {
  display: none;
}
.lesson-sidebar__stack .lesson-sidebar__panel {
  border-radius: 18px;
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
  padding: 16px 16px 18px;
}
.lesson-sidebar__title {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}
.lesson-sidebar__title h3 {
  color: var(--lesson-ink);
  font-family: var(--ff-secondary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  margin: 0;
  text-transform: uppercase;
}
.lesson-sidebar__title span {
  background: #f1f5f9;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  color: #5b6b82;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  text-transform: uppercase;
}
.lesson-nav {
  display: grid;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0 0 0 20px;
  position: relative;
}
.lesson-nav:before {
  background: rgba(191, 219, 254, 0.7);
  bottom: 6px;
  content: "";
  left: 9px;
  position: absolute;
  top: 6px;
  width: 1px;
}
.lesson-nav__item {
  align-items: center;
  background: linear-gradient(135deg, #f7fbff, #ffffff);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 16px;
  display: grid;
  gap: 5px;
  grid-template-columns: 24px 1fr auto;
  padding: 6px 4px 6px 8px;
  position: relative;
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.06);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}
.lesson-nav__item a {
  color: #1e293b;
  font-family: var(--ff-primary);
  font-size: 14px !important;
  font-weight: 500;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
  text-decoration: none;
}
.lesson-nav__index {
  background: #eef2ff;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 999px;
  color: #475569;
  display: grid;
  font-size: 12px;
  font-weight: 700;
  height: 20px;
  place-items: center;
  width: 20px;
}
.lesson-nav__item:before {
  background: var(--lesson-accent-soft);
  border: 2px solid #f8fafc;
  border-radius: 999px;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
  content: "";
  height: 8px;
  left: -18px;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
}
.lesson-nav__item:hover {
  background: #f5faff;
  border-color: rgba(37, 99, 235, 0.32);
  box-shadow: 0 12px 20px rgba(37, 99, 235, 0.12);
  transform: translateY(-1px);
}
.lesson-nav__item.is-current {
  background: #e8f1ff;
  border-color: rgba(37, 99, 235, 0.35);
  /* box-shadow: 0 14px 24px rgba(37, 99, 235, 0.18); */
}
.lesson-nav__item.is-current .lesson-nav__index,
.lesson-nav__item.is-current a {
  color: var(--lesson-accent-strong);
}
.lesson-nav__item.is-current .lesson-nav__index {
  background: #2563eb;
  border-color: #1d4ed8;
  color: #fff;
}
.lesson-nav__item.is-current:before {
  background: #2563eb;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.2);
}
.lesson-nav__item.is-practical {
  border-color: rgba(16, 185, 129, 0.35);
}
.lesson-nav__tag {
  background: #eafff2;
  border: 1px solid rgba(16, 185, 129, 0.22);
  border-radius: 999px;
  color: #15803d;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 4px 8px;
  text-transform: uppercase;
}
.lesson-nav__tag--practical {
  background: #dcfce7;
  color: #15803d;
}
.lesson-toc__count {
  background: #f1f5f9;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  color: #5b6b82;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  text-transform: uppercase;
}
.lesson-toc__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
}
.lesson-toc__item {
  --toc-indent: 0px;
  display: flex;
  align-items: center;
  position: relative;
  padding: 3px 8px 3px calc(18px + var(--toc-indent));
  border-radius: 10px;
  transition:
    background 0.2s ease,
    color 0.2s ease;
}
.lesson-toc__item::before {
  content: "";
  position: absolute;
  left: calc(6px + var(--toc-indent));
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: #92a6f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.08);
}
.lesson-toc__link {
  color: #1e293b;
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.01em;
  font-family: var(--ff-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
  text-overflow: ellipsis;
}
.lesson-toc__item--h2 {
  --toc-indent: 0px;
}
.lesson-toc__item--h3 {
  --toc-indent: 14px;
}
.lesson-toc__item--h4 {
  --toc-indent: 26px;
}
.lesson-toc__item--h3 .lesson-toc__link {
  font-size: 14px;
  color: #4e596a;
  -webkit-line-clamp: 1;
}
.lesson-toc__item--h4 .lesson-toc__link {
  font-size: 14px;
  color: #5c6e88;
  -webkit-line-clamp: 1;
  font-weight: 500;
}
.lesson-toc__item:hover {
  background: rgba(226, 232, 240, 0.5);
}
.lesson-toc__link:hover {
  color: var(--lesson-accent);
}
.lesson-toc__item.is-active::before {
  background: var(--lesson-accent);
}
.lesson-toc__item.is-active .lesson-toc__link {
  color: var(--lesson-accent-strong);
}
.lesson-toc__item.is-active {
  background: rgba(219, 234, 254, 0.7);
}
.lesson-toc__empty {
  margin: 8px 0 0;
  font-size: 12px;
  color: var(--lesson-muted);
}
.lesson-sidebar__panel--cta {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}
.lesson-sidebar__panel--cta h3 {
  font-size: 16px;
  font-weight: 700;
  margin-top: 0;
}
@keyframes lesson-rise {
  0% {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 600px) {
  .lesson-hero__grid {
    grid-template-columns: 1fr;
  }
  .lesson-actions {
    flex-direction: column;
  }
  .lesson-body__card {
    padding: 14px;
  }
  .lesson-share__menu {
    left: 0;
    min-width: 0;
    right: auto;
    width: calc(100vw - 24px);
  }
  .lesson-share__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 992px) {
  .aifk-lesson {
    grid-template-areas: "content";
    grid-template-columns: minmax(0, 1fr);
    padding: 0;
  }
  .lesson-container {
    margin-top: 2.2rem;
    padding-right: 0;
  }
  .lesson-layout__inner {
    grid-template-columns: 1fr;
  }
  .lesson-sidebar {
    position: static;
    top: auto;
  }
  .lesson-body__card {
    padding: 16px;
  }
  .lesson-hero__inner {
    padding: 16px;
  }
  .lesson-hero__grid {
    grid-template-columns: 1fr;
  }
  .lesson-hero__card {
    order: 2;
  }
  .lesson-cta {
    flex-direction: row;
    align-items: stretch;
  }
  .lesson-pill {
    /* width: 100%; */
    justify-content: flex-start;
  }
  .lesson-share__menu {
    left: 0;
    min-width: 0;
    right: auto;
    width: min(320px, calc(100vw - 32px));
  }
}
@media (max-width: 700px) {
  .lesson-card__media {
    aspect-ratio: 1;
  }
  .lesson-nav__item {
    grid-template-columns: 20px minmax(0, 1fr);
    padding: 8px;
  }
  .lesson-nav__tag {
    grid-column: 2 / 3;
    justify-self: start;
    margin-top: 2px;
  }
}
@media (max-width: 1450px) {
  .aifk-lesson {
    grid-template-columns: 0fr minmax(0, 5fr);
  }
}

@media (max-width: 1200px) {
  .lesson-actions--card {
    flex-direction: column;
  }
}
.lesson-breadcrumbs__list {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.lesson-breadcrumbs__item {
  align-items: center;
  color: var(--lesson-ink);
  display: flex;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  max-width: 100%;
  padding: 4px 10px;
}
.lesson-breadcrumbs__item:not(:last-child)::after {
  content: none;
}
.lesson-breadcrumbs__link {
  align-items: center;
  color: inherit;
  display: inline-flex;
  gap: 6px;
  text-decoration: none;
}
.lesson-breadcrumbs__link:hover {
  color: var(--lesson-accent);
}
.lesson-breadcrumbs__icon {
  font-size: 14px;
  line-height: 1;
}
.lesson-breadcrumbs__text {
  color: inherit;
  overflow-wrap: anywhere;
  word-break: break-word;
}
button.lesson-switch {
  padding: 12px 35px 12px;
}
