/* ═══════════════════════════════════════════════
   UMBLE LEARN — Lesson Page
   ═══════════════════════════════════════════════ */

/* ── SCROLL PROGRESS ── */
.scroll-progress {
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--fog-06);
  z-index: 99;
}

.scroll-progress-fill {
  height: 100%;
  background: var(--cat-accent);
  width: 0%;
  transition: width 0.1s linear;
}

/* ── LESSON HEADER ── */
.lesson-header {
  padding: 100px 48px 48px;
  max-width: 760px;
  margin: 0 auto;
}

.lesson-header-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 16px;
  font-weight: 500;
  color: var(--cat-accent);
}

.lesson-header-title {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--fog);
  margin-bottom: 20px;
}

.lesson-header-meta {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* ── LESSON CONTENT ── */
.lesson-content {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 48px 80px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* Text block */
.block-text {
  font-size: 16px;
  font-weight: 300;
  line-height: 1.75;
  color: var(--fog-80);
}

.block-text strong {
  color: var(--fog);
  font-weight: 500;
}

/* Callout block */
.block-callout {
  padding: 20px 24px;
  background: rgba(0,82,204,0.06);
  border: 1px solid rgba(0,82,204,0.15);
  border-left: 3px solid var(--cat-accent);
  border-radius: 0 4px 4px 0;
}

.block-callout-label {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.18em;
  color: var(--cat-accent);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.block-callout-text {
  font-size: 14px;
  font-weight: 300;
  line-height: 1.7;
  color: var(--fog-60);
}

.block-callout-text strong {
  color: var(--fog);
  font-weight: 500;
}

/* Image block */
.block-image {
  background: var(--illus-bg);
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid var(--fog-10);
}

.block-image img {
  width: 100%;
  display: block;
}

.block-image-caption {
  padding: 12px 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fog-40);
  border-top: 1px solid var(--fog-10);
}

/* Data block */
.block-data {
  background: var(--surface);
  border: 1px solid var(--fog-10);
  border-radius: 4px;
  padding: 24px;
  display: flex;
  align-items: baseline;
  gap: 16px;
}

.block-data-value {
  font-family: var(--font-mono);
  font-size: 36px;
  font-weight: 600;
  color: var(--cat-accent);
}

.block-data-label {
  font-size: 14px;
  font-weight: 300;
  color: var(--fog-60);
  line-height: 1.5;
}

/* Expandable block */
.block-expand {
  border: 1px solid var(--fog-10);
  border-radius: 4px;
  overflow: hidden;
}

.block-expand summary {
  padding: 16px 20px;
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 500;
  color: var(--fog);
  cursor: pointer;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: space-between;
  list-style: none;
  transition: background 0.2s;
}

.block-expand summary::-webkit-details-marker { display: none; }

.block-expand summary::after {
  content: '+';
  font-family: var(--font-mono);
  font-size: 18px;
  color: var(--fog-40);
  transition: transform 0.3s;
}

.block-expand[open] summary::after {
  content: '-';
}

.block-expand summary:hover { background: var(--surface-2); }

.block-expand-body {
  padding: 20px;
  font-size: 14px;
  font-weight: 300;
  line-height: 1.7;
  color: var(--fog-60);
  border-top: 1px solid var(--fog-10);
}

.block-expand-body strong {
  color: var(--fog);
  font-weight: 500;
}

/* Quiz block */
.block-quiz {
  background: var(--surface);
  border: 1px solid var(--fog-10);
  border-radius: 4px;
  padding: 28px;
}

.block-quiz-label {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.18em;
  color: var(--fog-40);
  text-transform: uppercase;
  margin-bottom: 12px;
}

.block-quiz-question {
  font-size: 16px;
  font-weight: 500;
  color: var(--fog);
  margin-bottom: 16px;
  line-height: 1.5;
}

.quiz-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.quiz-option {
  padding: 12px 16px;
  border: 1px solid var(--fog-10);
  border-radius: 4px;
  font-size: 14px;
  font-weight: 300;
  color: var(--fog-60);
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 12px;
}

.quiz-option:hover {
  border-color: var(--fog-20);
  color: var(--fog);
}

.quiz-option-marker {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--fog-20);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fog-40);
}

.quiz-option.correct {
  border-color: var(--data-green);
  background: rgba(0,200,150,0.06);
  color: var(--fog);
}

.quiz-option.correct .quiz-option-marker {
  border-color: var(--data-green);
  background: var(--data-green);
  color: #fff;
}

.quiz-option.incorrect {
  border-color: rgba(255,80,80,0.4);
  background: rgba(255,80,80,0.06);
}

.quiz-option.incorrect .quiz-option-marker {
  border-color: #FF5050;
  color: #FF5050;
}

.quiz-feedback {
  font-family: var(--font-mono);
  font-size: 12px;
  padding: 10px 14px;
  border-radius: 4px;
  display: none;
}

.quiz-feedback.show { display: block; }

.quiz-feedback.correct {
  background: rgba(0,200,150,0.1);
  color: var(--data-green);
  border: 1px solid rgba(0,200,150,0.25);
}

.quiz-feedback.incorrect {
  background: rgba(255,80,80,0.08);
  color: #FF6B6B;
  border: 1px solid rgba(255,80,80,0.25);
}

/* Step block */
.block-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  padding-left: 32px;
}

.block-steps::before {
  content: '';
  position: absolute;
  left: 11px;
  top: 16px;
  bottom: 16px;
  width: 1px;
  background: var(--fog-10);
}

.block-step {
  position: relative;
  padding: 16px 0;
}

.block-step-marker {
  position: absolute;
  left: -32px;
  top: 16px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--cat-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--cat-accent);
  z-index: 1;
}

.block-step-title {
  font-size: 15px;
  font-weight: 500;
  color: var(--fog);
  margin-bottom: 6px;
}

.block-step-text {
  font-size: 14px;
  font-weight: 300;
  line-height: 1.65;
  color: var(--fog-60);
}

/* ── LESSON NAV ── */
.lesson-nav {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 48px 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--fog-10);
  padding-top: 32px;
}

.lesson-nav-btn {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--fog-60);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s;
}

.lesson-nav-btn:hover { color: var(--fog); }

.btn-complete {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: #fff;
  background: var(--data-green);
  border: none;
  padding: 12px 24px;
  border-radius: 2px;
  cursor: pointer;
  transition: opacity 0.2s;
}

.btn-complete:hover { opacity: 0.9; }

.btn-complete.done {
  background: var(--surface);
  border: 1px solid var(--data-green);
  color: var(--data-green);
  cursor: default;
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  .lesson-header { padding: 100px 24px 32px; }
  .lesson-content { padding: 0 24px 64px; }
  .lesson-nav { padding: 0 24px 64px; padding-top: 32px; }
  .lesson-header-title { font-size: 28px; }
}

@media (max-width: 640px) {
  .lesson-nav { flex-direction: column; align-items: stretch; text-align: center; }
}
