@font-face {
  font-family: Capyo Lesson;
  src: url('/assets/fonts/Quicksand-Variable.ttf') format('truetype');
  font-weight: 300 700;
  font-display: swap;
}
.teaching-demo {
  --lesson-bg: #fff;
  --lesson-ink: #3c3c3c;
  --lesson-muted: #777;
  --lesson-line: #e5e5e5;
  --lesson-grid: #f0f0ed;
  --lesson-accent: #dd6b20;
  --lesson-button: #58b500;
  --lesson-button-edge: #438c00;
  --lesson-button-text: #fff;
  --lesson-speech: #fff;
}
.teaching-grade10 {
  --lesson-ink: #173c38;
  --lesson-muted: #647773;
  --lesson-line: #dfe8e4;
  --lesson-grid: #edf1ef;
  --lesson-accent: #23866c;
}
.teaching-university {
  --lesson-bg: #202023;
  --lesson-ink: #f3f3f5;
  --lesson-muted: #b4b4bc;
  --lesson-line: #424247;
  --lesson-grid: #303035;
  --lesson-accent: #70c7ef;
  --lesson-speech: #252529;
  --lesson-button: #86cc3d;
  --lesson-button-edge: #5b9624;
  --lesson-button-text: #17320c;
}
.teaching-demo [data-slot='page-body'] .rounded-xl.border.bg-card {
  padding: 24px 28px 28px !important;
  zoom: 1 !important;
  background: var(--lesson-bg) !important;
}
.duo-lesson {
  display: grid;
  grid-template-rows: 36px 35px 100px minmax(0, 1fr) 50px 54px;
  gap: 18px;
  flex: 1;
  min-height: 0;
  color: var(--lesson-ink);
  font-family: 'Capyo Lesson', sans-serif;
  font-weight: 600;
  -webkit-font-smoothing: antialiased;
}
.lesson-top {
  display: flex;
  align-items: center;
  gap: 16px;
}
.duo-lesson button {
  font:
    700 16px/1.2 'Capyo Lesson',
    sans-serif;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.lesson-back {
  border: 0;
  background: none;
  color: var(--lesson-muted);
  height: 40px;
  width: 28px;
  flex: none;
  font-size: 38px !important;
  line-height: 1 !important;
}
.lesson-back:disabled {
  opacity: 0.35;
  cursor: default;
}
.lesson-progress {
  height: 16px;
  flex: 1;
  background: var(--lesson-line);
  border-radius: 20px;
  overflow: hidden;
}
.lesson-progress > span {
  display: block;
  height: 100%;
  width: 25%;
  background: var(--lesson-button);
  border-radius: 20px;
  position: relative;
}
.lesson-progress > span:after {
  content: '';
  position: absolute;
  top: 3px;
  left: 8px;
  right: 8px;
  height: 4px;
  border-radius: 8px;
  background: #fff5;
}
.lesson-count {
  font-size: 14px;
  font-weight: 700;
  color: var(--lesson-muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  min-width: 36px;
  text-align: right;
}
.duo-lesson .lesson-title {
  font:
    700 29px/1.2 'Capyo Lesson',
    sans-serif;
  letter-spacing: -0.025em;
  margin: 0;
  color: var(--lesson-ink);
  min-height: 35px;
  outline: none;
}
.lesson-mentor {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  align-items: center;
  gap: 17px;
}
.lesson-mentor img {
  width: 82px;
  height: 92px;
  object-fit: contain;
  image-rendering: auto;
}
.lesson-speech {
  font-size: 17px;
  line-height: 1.4;
  border: 2px solid var(--lesson-line);
  border-radius: 17px;
  padding: 13px 16px;
  position: relative;
  background: var(--lesson-speech);
  min-height: 83px;
  display: block;
  align-content: center;
}
.lesson-speech:before {
  content: '';
  position: absolute;
  left: -8px;
  top: 33px;
  width: 13px;
  height: 13px;
  background: var(--lesson-speech);
  border-left: 2px solid var(--lesson-line);
  border-bottom: 2px solid var(--lesson-line);
  transform: rotate(45deg);
}
.lesson-speech strong,
.lesson-note strong {
  font-weight: 700;
  color: var(--lesson-ink);
}
.lesson-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 0;
}
.lesson-diagram {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 290px;
  overflow: visible;
  color: var(--lesson-ink);
}
.lesson-diagram text {
  font-family: 'Capyo Lesson', sans-serif;
  fill: currentColor;
  font-weight: 700;
  font-size: 18px;
}
.lesson-diagram .big-number {
  font-size: 66px;
  fill: var(--lesson-accent);
}
.lesson-diagram #pizza-top + path + text {
  fill: var(--lesson-ink);
}
.lesson-diagram .pizza-caption,
.lesson-diagram .curve-caption {
  font-size: 17px;
  fill: var(--lesson-muted);
}
.lesson-diagram .diagram-grid {
  fill: none;
  stroke: var(--lesson-grid);
  stroke-width: 1;
}
.lesson-diagram .diagram-axis {
  fill: none;
  stroke: var(--lesson-muted);
  stroke-width: 1.5;
}
.lesson-diagram .axis-label {
  font-size: 14px;
  fill: var(--lesson-muted);
}
.lesson-diagram .root-label {
  font-size: 21px;
  fill: var(--lesson-accent);
}
.lesson-diagram .supply-label {
  fill: var(--lesson-accent);
}
.lesson-note {
  font-size: 17px;
  line-height: 1.45;
  text-align: center;
  color: var(--lesson-muted);
  display: block;
  align-content: center;
  max-width: 100%;
  text-wrap: pretty;
}
.lesson-actions {
  display: flex;
  gap: 14px;
  align-items: stretch;
}
.lesson-next {
  min-height: 52px;
  flex: 1;
  border: 0;
  border-bottom: 5px solid var(--lesson-button-edge);
  border-radius: 14px;
  background: var(--lesson-button);
  color: var(--lesson-button-text);
  letter-spacing: 0.04em;
  font-size: 14px !important;
  padding: 12px 16px 10px;
}
.lesson-next:hover {
  filter: brightness(1.04);
}
.lesson-next:active {
  border-bottom-width: 2px;
  transform: translateY(3px);
}
.lesson-replay {
  width: 54px;
  flex: none;
  border: 2px solid var(--lesson-line);
  border-bottom-width: 5px;
  border-radius: 14px;
  background: var(--lesson-bg);
  color: var(--lesson-muted);
  font-size: 29px !important;
}
.lesson-replay:active {
  border-bottom-width: 2px;
  transform: translateY(3px);
}
.duo-lesson button:focus-visible {
  outline: 3px solid var(--lesson-accent) !important;
  outline-offset: 4px;
}
.factor-stage {
  width: 100%;
  text-align: center;
}
.factor-stage[hidden] {
  display: none;
}
.factor-product {
  font-size: 30px;
  font-weight: 700;
  white-space: nowrap;
}
.factor-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 35px;
}
.factor-pair > div {
  display: grid;
  gap: 14px;
  font-size: 21px;
}
.factor-pair strong {
  font-size: 30px;
  color: var(--lesson-accent);
}
@media (max-height: 650px) {
  .teaching-demo [data-slot='page-body'] .rounded-xl.border.bg-card {
    padding: 18px 24px 22px !important;
  }
  .duo-lesson {
    gap: 13px;
    grid-template-rows: 30px auto 86px minmax(140px, 1fr) 42px 48px;
  }
  .duo-lesson .lesson-title {
    font-size: 26px;
  }
  .lesson-mentor {
    grid-template-columns: 68px minmax(0, 1fr);
    gap: 14px;
  }
  .lesson-mentor img {
    width: 68px;
    height: 78px;
  }
  .lesson-speech {
    font-size: 15px;
    padding: 10px 13px;
    min-height: 74px;
  }
  .lesson-note {
    font-size: 15px;
  }
  .lesson-next {
    min-height: 48px;
    font-size: 13px !important;
  }
}

.lesson-diagram .graph-equation {
  font-size: 16px;
  fill: var(--lesson-ink);
}
