@font-face {
  font-family: "Vitalora Quicksand";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/assets/fonts/quicksand/Quicksand-VariableFont_wght.woff2") format("woff2");
}

:root {
  --sidebar-w: 360px;
  --sidebar-bg: #2954b3;
  --sidebar-border: rgba(255, 255, 255, 0.14);
  --sidebar-text: #d7e5f3;
  --sidebar-active: #f4f9ff;
  --sidebar-muted: #a9c1d9;
  --sidebar-hover: rgba(255, 255, 255, 0.05);
  --sidebar-selected: rgba(58, 154, 234, 0.24);
  --brand: #3a9aea;
  --brand-dark: #2954b3;
  --brand-rgb: 58, 154, 234;
  --content-bg: #f8f5f0;
  --surface: #ffffff;
  --ink: #18222c;
  --body-text: #56645f;
  --muted: #8b9994;
  --line: #e5e0d8;
  --line-light: #eee9e2;
  --soft-brand: rgba(var(--brand-rgb), 0.1);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
  background: var(--content-bg);
}

body {
  display: flex;
  min-width: 320px;
  min-height: 100vh;
  height: 100vh;
  height: 100dvh;
  margin: 0;
  overflow: hidden;
  color: var(--ink);
  background: var(--content-bg);
  font-family: "Vitalora Quicksand", "Quicksand", system-ui, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

button {
  font: inherit;
}

/* Sidebar */
.sidebar {
  position: relative;
  top: 0;
  z-index: 30;
  display: flex;
  flex: 0 0 var(--sidebar-w);
  align-self: flex-start;
  flex-direction: column;
  width: var(--sidebar-w);
  min-height: 100vh;
  height: 100vh;
  height: 100dvh;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  scrollbar-width: none;
  color: var(--sidebar-text);
  background: var(--sidebar-bg);
  border-right: 1px solid var(--sidebar-border);
}

.sidebar::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.s-brand {
  flex-shrink: 0;
  padding: 22px 22px 18px;
  border-bottom: 1px solid var(--sidebar-border);
}

.ambience-toggle {
  display: none;
}

.s-logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--sidebar-active);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: color 0.16s ease;
}

.s-logo:hover {
  color: var(--sidebar-active);
}

.s-logo svg {
  flex: 0 0 12px;
  width: 12px;
  height: 12px;
}

.s-course {
  margin-top: 2px;
  color: #fff;
  font-size: 11.5px;
  font-weight: 500;
}

.s-prog {
  flex-shrink: 0;
  padding: 14px 22px;
  border-bottom: 1px solid var(--sidebar-border);
}

.s-prog-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.s-prog-label,
.s-ch-label {
  color: var(--sidebar-muted);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.s-prog-label {
  color: var(--sidebar-active);
}

.s-prog-count {
  color: var(--sidebar-active);
  font-size: 11px;
  font-weight: 700;
}

.s-track {
  height: 2px;
  margin-top: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.07);
  border-radius: 1px;
}

.s-track-fill {
  width: 0;
  height: 100%;
  background: var(--brand);
  border-radius: inherit;
  transition: width 0.2s ease;
}

.s-nav {
  flex: 0 0 auto;
  min-height: 0;
  padding: 4px 0 20px;
  overflow: visible;
}

.s-ch-label {
  padding: 16px 22px 5px;
  color: var(--sidebar-active);
  font-weight: 700;
}

.s-lesson {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  min-height: 0;
  padding: 7px 22px;
  color: var(--sidebar-text);
  border-left: 2px solid transparent;
  font-size: 12.5px;
  line-height: 1.2;
  text-decoration: none;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.s-lesson:hover {
  color: var(--sidebar-active);
  background: var(--sidebar-hover);
}

.s-lesson.active {
  color: var(--sidebar-active);
  background: var(--sidebar-selected);
  border-left-color: var(--sidebar-active);
}

.s-lesson.complete .s-dot {
  background: #fff;
  border-color: #fff;
}

.s-num {
  flex: 0 0 18px;
  color: var(--sidebar-muted);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.s-lesson.active .s-num {
  color: var(--sidebar-active);
}

.s-lesson-title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.s-dot {
  flex: 0 0 7px;
  width: 7px;
  height: 7px;
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 50%;
}

/* Main reader */
.main {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  height: 100vh;
  height: 100dvh;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  background: var(--content-bg);
}

.rbar {
  position: sticky;
  top: 0;
  z-index: 22;
  height: 2px;
  background: var(--line-light);
}

.rbar-fill {
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--brand), var(--brand-dark));
  transition: width 0.1s linear;
}

.topbar {
  position: sticky;
  top: 2px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 50px;
  padding: 0 56px;
  color: var(--muted);
  background: rgba(248, 245, 240, 0.92);
  border-bottom: 1px solid var(--line-light);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.topbar-l,
.rt-badge,
.tags {
  display: flex;
  align-items: center;
}

.topbar-l {
  min-width: 0;
  gap: 10px;
}

.tb-label,
.lesson-num-label,
.sec-eyebrow {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.tb-label {
  color: var(--brand);
  font-size: 11px;
  letter-spacing: 0.07em;
}

.tb-sep {
  color: #b8c4cf;
}

.tb-title {
  max-width: 340px;
  overflow: hidden;
  color: var(--body-text);
  font-size: 13px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rt-badge {
  gap: 6px;
  flex-shrink: 0;
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 500;
}

.mobile-menu {
  display: none;
  width: 32px;
  height: 32px;
  padding: 0;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 7px;
}

.wrap {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 0 56px 64px;
}

.lesson-head {
  padding-top: 52px;
  padding-bottom: 44px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 56px;
}

.lesson-num-label {
  margin-bottom: 12px;
  color: var(--muted);
}

.lesson-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-bottom: 12px;
}

.lesson-meta .lesson-num-label {
  margin-bottom: 0;
}

h1.title {
  margin: 0 0 17px;
  color: var(--ink);
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.13;
  white-space: nowrap;
}

.lesson-lead {
  max-width: 540px;
  margin: 0 0 24px;
  color: var(--body-text);
  font-size: 16.5px;
  font-weight: 400;
  line-height: 1.65;
}

.tags {
  flex-wrap: wrap;
  gap: 7px;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 500;
  white-space: nowrap;
}

.tag svg {
  flex: 0 0 12px;
  width: 12px;
  height: 12px;
}

.tag-g {
  color: var(--brand-dark);
  background: var(--soft-brand);
  border: 1px solid rgba(var(--brand-rgb), 0.3);
}

.tag-o {
  color: var(--body-text);
  background: var(--surface);
  border: 1px solid var(--line);
}

.lesson-duration {
  margin: 0;
}

.content {
  color: var(--body-text);
}

.content p,
.content li {
  font-size: 16px;
  line-height: 1.88;
}

.content p {
  margin: 0 0 22px;
}

.content p:last-child {
  margin-bottom: 0;
}

.content h2,
.content h3,
.content h4 {
  color: var(--ink);
  line-height: 1.25;
}

.content h2 {
  margin: 0 0 20px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.content h3 {
  margin: 36px 0 12px;
  color: var(--ink);
  font-size: 19px;
  font-weight: 650;
}

.content h4 {
  margin: 28px 0 8px;
  font-size: 16px;
  font-weight: 650;
}

.content ul,
.content ol {
  margin: 20px 0;
  padding-left: 0;
}

.content li {
  margin: 0;
}

.content ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.content ul li {
  display: flex;
  align-items: flex-start;
  gap: 13px;
}

.content ul li::before {
  content: '';
  width: 5px;
  height: 5px;
  flex: 0 0 5px;
  margin-top: 11px;
  background: var(--brand);
  border-radius: 50%;
}

.content strong {
  color: var(--ink);
  font-weight: 700;
}

.content blockquote,
.content .pq {
  margin: 28px 0;
  padding: 16px 24px;
  color: var(--body-text);
  background: var(--surface);
  border-left: 2px solid var(--brand);
  border-radius: 0 7px 7px 0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.content blockquote p,
.content .pq p {
  margin: 0;
  font-style: italic;
  font-size: 15.5px;
  line-height: 1.7;
}

.content .sec {
  margin-bottom: 60px;
}

.content .sec:last-child {
  margin-bottom: 0;
}

.lesson-arrival {
  position: relative;
  margin: 0 0 34px;
  padding: 22px 24px 22px 27px;
  overflow: hidden;
  background: linear-gradient(135deg, #fff9f3 0%, #f7eee5 100%);
  border: 1px solid #ead9ca;
  border-left: 3px solid var(--brand);
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(91, 61, 39, 0.07);
}

.lesson-arrival::after {
  content: '';
  position: absolute;
  right: -36px;
  bottom: -52px;
  width: 128px;
  height: 128px;
  background: rgba(var(--brand-rgb), 0.075);
  border-radius: 50%;
}

.lesson-arrival span {
  position: relative;
  z-index: 1;
  display: block;
  margin-bottom: 7px;
  color: #9a5b3d;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.lesson-arrival p {
  position: relative;
  z-index: 1;
  margin: 0;
  color: #3f4549;
  font-size: 15.5px;
  line-height: 1.72;
}

.lesson-opening {
  margin: 0 0 52px;
  padding: 0 0 30px;
  border-bottom: 1px solid var(--line);
}

.lesson-opening p:first-child {
  color: var(--ink);
  font-size: 17px;
  line-height: 1.82;
}

.lesson-callout {
  margin: 28px 0 0;
  padding: 18px 20px;
  background: rgba(var(--brand-rgb), 0.075);
  border: 1px solid rgba(var(--brand-rgb), 0.2);
  border-radius: 10px;
}

.lesson-callout-warning {
  background: #fff7f2;
  border-color: #eed6c7;
}

.lesson-callout p {
  margin: 4px 0 0;
  font-size: 14.5px;
  line-height: 1.7;
}

.callout-label,
.action-kicker,
.remember-kicker {
  color: var(--brand-dark);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.lesson-callout-warning .callout-label {
  color: #a74d27;
}

.course-figure {
  margin: -10px 0 60px;
}

.course-figure img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(24, 34, 44, 0.1);
}

.course-figure figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.55;
}

.lesson-action {
  margin: 68px 0 34px;
  padding: 28px 30px 30px;
  color: var(--body-text);
  background: linear-gradient(145deg, rgba(var(--brand-rgb), 0.12), rgba(var(--brand-rgb), 0.055));
  border: 1px solid rgba(var(--brand-rgb), 0.23);
  border-radius: 14px;
}

.action-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 12px;
}

.action-time {
  color: var(--brand-dark);
  font-size: 11.5px;
  font-weight: 600;
}

.lesson-action h2,
.lesson-remember h2,
.lesson-sources h2 {
  margin: 0 0 14px;
}

.lesson-action > p {
  margin-bottom: 18px;
  font-size: 14.5px;
  line-height: 1.7;
}

.content ol.step-list {
  counter-reset: lesson-step;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 22px 0 0;
  list-style: none;
}

.content ol.step-list li {
  counter-increment: lesson-step;
  display: grid;
  grid-template-columns: 27px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  font-size: 14.5px;
  line-height: 1.65;
}

.content ol.step-list li::before {
  content: counter(lesson-step);
  display: grid;
  place-items: center;
  width: 27px;
  height: 27px;
  margin-top: 1px;
  color: #fff;
  background: var(--brand);
  border-radius: 50%;
  font-size: 10.5px;
  font-weight: 700;
}

.reflection {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(var(--brand-rgb), 0.2);
}

.reflection > span {
  color: var(--brand-dark);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.reflection p {
  margin: 5px 0 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.6;
}

.lesson-remember {
  margin: 34px 0;
  padding: 26px 0 30px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.lesson-remember .flist {
  margin-bottom: 0;
}

.lesson-remember .flist li {
  color: var(--ink);
  font-size: 14.5px;
  font-weight: 550;
  line-height: 1.6;
}

.lesson-sources {
  margin: 36px 0 20px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--line-light);
  border-radius: 10px;
}

.lesson-sources h2 {
  font-size: 18px;
}

.lesson-sources > p {
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.content .lesson-sources ul {
  gap: 8px;
  margin: 0;
}

.content .lesson-sources li {
  display: block;
  font-size: 13px;
  line-height: 1.5;
}

.content .lesson-sources li::before {
  display: none;
}

.lesson-sources a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 9px 0;
  color: var(--brand-dark);
  border-bottom: 1px solid var(--line-light);
  font-weight: 600;
  text-decoration: none;
}

.lesson-sources li:last-child a {
  border-bottom: 0;
}

.lesson-sources a:hover {
  color: var(--brand);
}

.sec-eyebrow {
  margin-bottom: 8px;
  color: var(--brand);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.reader-error {
  padding: 18px;
  color: #b42318;
  background: #fff8f7;
  border: 1px solid #f1c5bf;
  border-radius: 8px;
}

.sidebar-scrim {
  display: none;
}

/* Clean Reset: warm winter reading room. Scoped so every other course keeps its own design. */
html.clean-reset-reader {
  --sidebar-w: 352px;
  --sidebar-bg: #253129;
  --sidebar-border: rgba(255, 248, 236, 0.11);
  --sidebar-text: #ddd8cd;
  --sidebar-active: #fff8ed;
  --sidebar-muted: #acb5a8;
  --sidebar-hover: rgba(255, 248, 236, 0.055);
  --sidebar-selected: rgba(191, 118, 84, 0.19);
  --brand: #bf7654;
  --brand-dark: #7a4b3a;
  --brand-rgb: 191, 118, 84;
  --content-bg: #f4eee6;
  --surface: #fffbf6;
  --ink: #292a25;
  --body-text: #625f57;
  --muted: #8b867b;
  --line: #ddd2c4;
  --line-light: #e9e1d6;
  --soft-brand: rgba(191, 118, 84, 0.1);
  background: #1f2924;
}

html.clean-reset-reader body {
  background: #1f2924;
}

html.clean-reset-reader .sidebar {
  border-right: 0;
  background:
    radial-gradient(circle at 13% 0%, rgba(201, 143, 104, 0.22), transparent 28%),
    linear-gradient(178deg, #303d35 0%, #253129 48%, #1d2722 100%);
  box-shadow: inset -1px 0 rgba(255, 255, 255, 0.035);
}

html.clean-reset-reader .s-brand {
  position: relative;
  padding: 25px 24px 20px;
  background: rgba(255, 250, 242, 0.018);
}

html.clean-reset-reader .ambience-toggle {
  position: absolute;
  top: 17px;
  right: 18px;
  isolation: isolate;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  color: #d8c9b8;
  background: rgba(255, 250, 242, 0.045);
  border: 1px solid rgba(255, 248, 236, 0.15);
  border-radius: 12px;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.05);
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease, box-shadow 240ms ease, transform 180ms ease;
}

html.clean-reset-reader .ambience-toggle::after {
  content: '';
  position: absolute;
  top: 29px;
  left: 50%;
  z-index: -1;
  width: 118px;
  height: 88px;
  background: radial-gradient(ellipse at 50% 0%, rgba(255, 215, 139, 0.9), rgba(246, 169, 73, 0.42) 38%, transparent 72%);
  filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) scale(0.72);
  transform-origin: 50% 0;
  transition: opacity 300ms ease, transform 380ms ease;
}

html.clean-reset-reader .ambience-toggle:hover {
  color: #f6dfca;
  background: rgba(255, 250, 242, 0.09);
  transform: translateY(-1px);
}

html.clean-reset-reader .ambience-toggle:focus-visible {
  outline: 2px solid #f0c7a5;
  outline-offset: 3px;
}

html.clean-reset-reader .ambience-lamp {
  position: relative;
  display: block;
  width: 24px;
  height: 25px;
}

html.clean-reset-reader .ambience-lamp-shade {
  position: absolute;
  top: 1px;
  left: 2px;
  width: 20px;
  height: 11px;
  background: #c9baa8;
  clip-path: polygon(24% 0, 76% 0, 100% 100%, 0 100%);
  transition: background 220ms ease, filter 220ms ease;
}

html.clean-reset-reader .ambience-lamp-shade::after {
  content: '';
  position: absolute;
  right: 4px;
  bottom: 0;
  left: 4px;
  height: 2px;
  background: rgba(255, 255, 255, 0.32);
}

html.clean-reset-reader .ambience-lamp-stem {
  position: absolute;
  top: 12px;
  left: 11px;
  width: 2px;
  height: 8px;
  background: currentColor;
  border-radius: 2px;
}

html.clean-reset-reader .ambience-lamp-base {
  position: absolute;
  bottom: 2px;
  left: 5px;
  width: 14px;
  height: 3px;
  background: currentColor;
  border-radius: 50% 50% 2px 2px;
}

html.clean-reset-reader.ambience-on .ambience-toggle {
  color: #ffe1a6;
  background: rgba(224, 147, 56, 0.28);
  border-color: rgba(255, 207, 127, 0.72);
  box-shadow:
    0 0 0 6px rgba(235, 164, 75, 0.12),
    0 8px 32px rgba(255, 185, 86, 0.5),
    inset 0 1px rgba(255, 255, 255, 0.12);
}

html.clean-reset-reader.ambience-on .ambience-toggle::after {
  opacity: 1;
  transform: translateX(-50%) scale(1);
}

html.clean-reset-reader.ambience-on .ambience-lamp-shade {
  background: #ffc873;
  filter: drop-shadow(0 0 8px rgba(255, 193, 94, 0.98));
}

html.clean-reset-reader .s-logo {
  gap: 10px;
  color: #fffaf2;
  font-size: 16px;
  font-weight: 700;
}

html.clean-reset-reader .s-logo svg {
  color: #d8aa86;
}

html.clean-reset-reader .s-course {
  margin-top: 4px;
  color: #cfc8ba;
  font-size: 11.5px;
  letter-spacing: 0.015em;
}

html.clean-reset-reader .s-prog {
  padding: 16px 24px 18px;
  background: rgba(255, 250, 242, 0.025);
}

html.clean-reset-reader .s-prog-label,
html.clean-reset-reader .s-prog-count {
  color: #f7eadc;
}

html.clean-reset-reader .s-track {
  height: 3px;
  margin-top: 10px;
  background: rgba(255, 248, 236, 0.09);
}

html.clean-reset-reader .s-track-fill {
  background: linear-gradient(90deg, #d8a27b, #efd0aa);
}

html.clean-reset-reader .s-nav {
  padding: 7px 0 24px;
}

html.clean-reset-reader .s-ch-label {
  padding: 17px 24px 7px;
  color: #d8b99e;
  font-size: 9px;
  letter-spacing: 0.14em;
}

html.clean-reset-reader .s-lesson {
  width: calc(100% - 24px);
  margin: 1px 12px;
  padding: 8px 12px;
  color: #d4d2c9;
  border-left: 0;
  border-radius: 9px;
}

html.clean-reset-reader .s-lesson:hover {
  background: rgba(255, 248, 236, 0.06);
}

html.clean-reset-reader .s-lesson.active {
  color: #fffaf2;
  background: linear-gradient(90deg, rgba(191, 118, 84, 0.24), rgba(191, 118, 84, 0.08));
  border-left-color: transparent;
  box-shadow: inset 3px 0 #d9a17b;
}

html.clean-reset-reader .s-num {
  color: #9da99e;
}

html.clean-reset-reader .s-dot {
  border-color: #aab5a9;
}

html.clean-reset-reader .s-lesson.active .s-dot {
  background: #d9a17b;
  border-color: #e9c3a5;
}

html.clean-reset-reader .main {
  position: relative;
  isolation: isolate;
  scrollbar-color: #c8baaa transparent;
  background:
    radial-gradient(circle at 82% 2%, rgba(218, 177, 137, 0.15), transparent 29%),
    linear-gradient(180deg, #f8f3ec 0%, #f3ece3 100%);
  box-shadow: none;
}

html.clean-reset-reader .main::before {
  content: '';
  position: fixed;
  inset: 0 0 0 var(--sidebar-w);
  z-index: 15;
  background:
    radial-gradient(ellipse 116% 88% at 0% 3%, rgba(255, 220, 139, 0.68) 0, rgba(250, 191, 92, 0.42) 27%, rgba(239, 155, 65, 0.17) 51%, rgba(236, 145, 55, 0.04) 66%, transparent 79%),
    linear-gradient(115deg, rgba(255, 239, 202, 0.36) 0%, rgba(255, 222, 158, 0.18) 47%, transparent 74%);
  opacity: 0;
  pointer-events: none;
  mix-blend-mode: normal;
  transition: opacity 420ms ease;
}

html.clean-reset-reader .main::after {
  content: '';
  position: fixed;
  inset: 0 0 0 var(--sidebar-w);
  z-index: 16;
  background:
    radial-gradient(ellipse 92% 82% at 12% 11%, transparent 0%, transparent 51%, rgba(75, 47, 22, 0.075) 100%),
    linear-gradient(90deg, transparent 0%, transparent 70%, rgba(70, 43, 21, 0.055) 100%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 420ms ease;
}

html.clean-reset-reader.ambience-on .main::before,
html.clean-reset-reader.ambience-on .main::after {
  opacity: 1;
}

html.clean-reset-reader.ambience-on .sidebar {
  box-shadow:
    inset -1px 0 rgba(255, 224, 172, 0.16),
    16px 0 46px rgba(218, 140, 48, 0.12);
}

html.clean-reset-reader.ambience-on .topbar {
  background: rgba(250, 227, 189, 0.95);
  border-bottom-color: rgba(181, 112, 48, 0.24);
  box-shadow: 0 10px 34px rgba(150, 91, 36, 0.12);
}

html.clean-reset-reader.ambience-on .tag-o {
  background: rgba(255, 241, 211, 0.92);
  border-color: rgba(196, 125, 58, 0.28);
  box-shadow: 0 5px 15px rgba(140, 82, 38, 0.08);
}

html.clean-reset-reader.ambience-on .lesson-arrival {
  background:
    radial-gradient(circle at 94% 88%, rgba(213, 140, 65, 0.17), transparent 28%),
    linear-gradient(135deg, #fff8e9 0%, #fae3bd 100%);
  border-color: rgba(197, 126, 60, 0.34);
  box-shadow:
    0 18px 46px rgba(137, 78, 31, 0.16),
    0 0 42px rgba(238, 166, 77, 0.12);
}

html.clean-reset-reader.ambience-on .lesson-hero .course-figure img,
html.clean-reset-reader.ambience-on .course-figure img {
  filter: saturate(1.06) sepia(0.08) brightness(1.035);
  box-shadow:
    0 0 0 5px rgba(255, 250, 243, 0.92),
    0 25px 60px -24px rgba(143, 78, 37, 0.55),
    0 0 58px rgba(231, 162, 92, 0.2);
}

html.clean-reset-reader .main::-webkit-scrollbar {
  width: 11px;
}

html.clean-reset-reader .main::-webkit-scrollbar-track {
  background: transparent;
}

html.clean-reset-reader .main::-webkit-scrollbar-thumb {
  background: #c8baaa;
  background-clip: content-box;
  border: 4px solid transparent;
  border-radius: 20px;
}

html.clean-reset-reader .rbar {
  background: rgba(122, 75, 58, 0.08);
}

html.clean-reset-reader .rbar-fill {
  background: linear-gradient(90deg, #bd7251, #d8a27b);
}

html.clean-reset-reader .topbar {
  height: 54px;
  padding: 0 48px;
  background: rgba(248, 243, 236, 0.9);
  border-bottom-color: rgba(126, 93, 72, 0.12);
  box-shadow: 0 8px 30px rgba(87, 63, 45, 0.035);
}

html.clean-reset-reader .tb-label {
  color: #a95f42;
}

html.clean-reset-reader .tb-sep {
  color: #c4b7a8;
}

html.clean-reset-reader .tb-title,
html.clean-reset-reader .rt-badge {
  color: #746f66;
}

html.clean-reset-reader .wrap {
  position: relative;
  z-index: 17;
  max-width: 1000px;
  padding: 0 54px 92px;
}

html.clean-reset-reader .lesson-head {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(290px, 0.94fr);
  gap: 46px;
  align-items: center;
  margin-bottom: 48px;
  padding-top: 50px;
  padding-bottom: 52px;
  border-bottom: 0;
}

html.clean-reset-reader .lesson-head::after {
  content: '';
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, #d8cabc 14%, #d8cabc 86%, transparent);
}

html.clean-reset-reader .lesson-meta {
  margin-bottom: 16px;
}

html.clean-reset-reader h1.title {
  margin-bottom: 18px;
  color: #292a25;
  font-size: clamp(34px, 3.1vw, 46px);
  font-weight: 650;
  letter-spacing: -0.04em;
  line-height: 1.08;
  white-space: normal;
}

html.clean-reset-reader .lesson-lead {
  margin-bottom: 0;
  color: #69655d;
  font-size: 16.5px;
  line-height: 1.72;
}

html.clean-reset-reader .tag-o {
  color: #716a60;
  background: rgba(255, 251, 246, 0.78);
  border-color: #dfd3c5;
  box-shadow: 0 4px 12px rgba(79, 58, 43, 0.035);
}

html.clean-reset-reader .lesson-hero:empty {
  display: none;
}

html.clean-reset-reader .lesson-hero .course-figure {
  margin: 0;
}

html.clean-reset-reader .lesson-hero .course-figure img {
  aspect-ratio: 4 / 3;
}

html.clean-reset-reader .content {
  width: 100%;
  max-width: 740px;
  margin: 0 auto;
  color: #625f57;
}

html.clean-reset-reader .content p,
html.clean-reset-reader .content li {
  font-size: 16.5px;
  line-height: 1.86;
}

html.clean-reset-reader .content h2,
html.clean-reset-reader .content h3,
html.clean-reset-reader .content h4 {
  color: #30312b;
}

html.clean-reset-reader .content h2 {
  font-size: 25px;
  font-weight: 650;
}

html.clean-reset-reader .content .sec {
  margin-bottom: 66px;
}

html.clean-reset-reader .sec-eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  color: #a75f43;
}

html.clean-reset-reader .sec-eyebrow::after {
  content: '';
  width: 34px;
  height: 1px;
  background: #d8b49b;
}

html.clean-reset-reader .content ul li::before {
  background: #bf7654;
}

html.clean-reset-reader .lesson-arrival {
  margin-bottom: 42px;
  padding: 28px 31px 27px;
  background:
    radial-gradient(circle at 94% 88%, rgba(191, 118, 84, 0.1), transparent 26%),
    linear-gradient(135deg, #fffaf3 0%, #f4e8da 100%);
  border: 1px solid #e5d2bf;
  border-left: 1px solid #e5d2bf;
  border-radius: 18px;
  box-shadow: 0 16px 38px rgba(91, 61, 39, 0.09);
}

html.clean-reset-reader .lesson-arrival::before {
  content: '';
  position: absolute;
  top: 0;
  left: 31px;
  width: 44px;
  height: 3px;
  background: #bf7654;
  border-radius: 0 0 4px 4px;
}

html.clean-reset-reader .lesson-arrival::after {
  right: -44px;
  bottom: -62px;
  width: 154px;
  height: 154px;
  background: rgba(111, 132, 114, 0.09);
}

html.clean-reset-reader .lesson-arrival span {
  margin-bottom: 9px;
  color: #985339;
}

html.clean-reset-reader .lesson-arrival p {
  color: #504e48;
  font-size: 16px;
  line-height: 1.75;
}

html.clean-reset-reader .lesson-opening {
  margin-bottom: 50px;
  padding-bottom: 34px;
  border-bottom-color: #ded3c6;
}

html.clean-reset-reader .lesson-opening p:first-child {
  color: #373832;
}

html.clean-reset-reader .course-figure {
  margin: 0 0 66px;
}

html.clean-reset-reader .course-figure img {
  background: #fffaf3;
  border: 6px solid rgba(255, 251, 246, 0.94);
  border-radius: 19px;
  box-shadow: 0 20px 48px rgba(62, 47, 35, 0.16);
}

html.clean-reset-reader .lesson-callout {
  padding: 20px 22px;
  background: #f4eadf;
  border-color: #e0cebc;
  border-radius: 13px;
}

html.clean-reset-reader .lesson-callout-warning {
  background: #fff4eb;
  border-color: #e7c9b5;
}

html.clean-reset-reader .callout-label,
html.clean-reset-reader .action-kicker,
html.clean-reset-reader .remember-kicker,
html.clean-reset-reader .reflection > span {
  color: #8c513c;
}

html.clean-reset-reader .lesson-action {
  padding: 31px 32px 33px;
  background:
    radial-gradient(circle at 100% 0%, rgba(92, 113, 96, 0.11), transparent 34%),
    linear-gradient(145deg, #f0e2d2, #f8efe5);
  border-color: #dcc5b0;
  border-radius: 18px;
  box-shadow: 0 14px 34px rgba(89, 63, 44, 0.07);
}

html.clean-reset-reader .action-time {
  color: #6d776c;
}

html.clean-reset-reader .content ol.step-list li::before {
  background: #4c6254;
  box-shadow: 0 3px 10px rgba(45, 65, 53, 0.16);
}

html.clean-reset-reader .reflection {
  border-top-color: rgba(122, 75, 58, 0.17);
}

html.clean-reset-reader .lesson-remember {
  padding: 27px 29px 30px;
  background: rgba(255, 250, 243, 0.68);
  border: 1px solid #e1d5c8;
  border-radius: 16px;
}

html.clean-reset-reader .lesson-sources {
  padding: 27px;
  background: rgba(255, 251, 246, 0.78);
  border-color: #e1d6ca;
  border-radius: 14px;
}

html.clean-reset-reader .lesson-sources a {
  color: #7a4b3a;
  border-bottom-color: #e7ddd2;
}

@media (min-width: 761px) {
  html.clean-reset-reader body {
    gap: 0;
    padding: 0;
  }

  html.clean-reset-reader .sidebar {
    min-height: 100vh;
    min-height: 100dvh;
    height: 100vh;
    height: 100dvh;
  }

  html.clean-reset-reader .main {
    height: 100vh;
    height: 100dvh;
    border-radius: 0;
  }

  html.clean-reset-reader .topbar {
    border-radius: 0;
  }
}

@media (min-width: 761px) and (max-width: 1180px) {
  html.clean-reset-reader .wrap {
    max-width: 760px;
    padding-right: 46px;
    padding-left: 46px;
  }

  html.clean-reset-reader .lesson-head {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  html.clean-reset-reader .lesson-hero .course-figure img {
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 760px) {
  body {
    display: block;
    height: auto;
    overflow: visible;
  }

  .sidebar {
    position: relative;
    top: auto;
    width: 100%;
    min-height: 0;
    height: auto;
    overflow: visible;
    overscroll-behavior: auto;
    box-shadow: none;
  }

  .main {
    min-height: 100vh;
    height: auto;
    overflow: visible;
    overscroll-behavior: auto;
  }

  .mobile-menu {
    display: none;
  }

  .sidebar-scrim {
    display: none;
  }

  .topbar {
    height: 54px;
    padding: 0 14px;
  }

  .topbar-l {
    gap: 7px;
  }

  .tb-title {
    max-width: 160px;
  }

  .rt-badge {
    display: none;
  }

  .wrap {
    max-width: 100%;
    padding: 0 20px;
  }

  .lesson-head {
    padding-top: 40px;
    padding-bottom: 30px;
    margin-bottom: 35px;
  }

  h1.title {
    font-size: clamp(28px, 9vw, 38px);
    white-space: normal;
  }

  .lesson-lead {
    font-size: 14.5px;
  }

  .content p,
  .content li {
    font-size: 14.5px;
    line-height: 1.72;
  }

  .lesson-opening {
    margin-bottom: 40px;
    padding-bottom: 22px;
  }

  .lesson-opening p:first-child {
    font-size: 15.5px;
    line-height: 1.72;
  }

  .lesson-action {
    margin-top: 48px;
    padding: 23px 20px 24px;
  }

  .course-figure {
    margin-bottom: 44px;
  }

}

@media (max-width: 760px) {
  html.clean-reset-reader body {
    padding: 0;
    background: #1f2924;
  }

  html.clean-reset-reader .main,
  html.clean-reset-reader .topbar {
    border-radius: 0;
  }

  html.clean-reset-reader .main::before,
  html.clean-reset-reader .main::after {
    left: 0;
  }

  html.clean-reset-reader .main::before {
    background:
      radial-gradient(ellipse 122% 72% at 4% 2%, rgba(255, 220, 139, 0.62) 0, rgba(250, 191, 92, 0.36) 27%, rgba(239, 155, 65, 0.14) 51%, transparent 77%),
      linear-gradient(118deg, rgba(255, 239, 202, 0.31) 0%, rgba(255, 222, 158, 0.14) 48%, transparent 76%);
  }

  html.clean-reset-reader .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 50;
    width: min(88vw, 352px);
    min-height: 100vh;
    min-height: 100dvh;
    height: 100vh;
    height: 100dvh;
    overflow-x: hidden;
    overflow-y: auto;
    border-radius: 0 18px 18px 0;
    box-shadow: 22px 0 60px rgba(12, 22, 17, 0.3);
    transform: translateX(-105%);
    transition: transform 0.24s ease;
  }

  html.clean-reset-reader body.sidebar-open {
    overflow: hidden;
  }

  html.clean-reset-reader body.sidebar-open .sidebar {
    transform: translateX(0);
  }

  html.clean-reset-reader .mobile-menu {
    position: fixed;
    top: 14px;
    left: 14px;
    z-index: 60;
    display: grid;
    width: 44px;
    height: 44px;
    padding: 0;
    place-items: center;
    color: #fffaf3;
    background: rgba(37, 49, 41, 0.96);
    border-color: rgba(255, 248, 238, 0.22);
    border-radius: 13px;
    box-shadow: 0 12px 28px rgba(20, 28, 23, 0.24);
    cursor: pointer;
  }

  html.clean-reset-reader .sidebar-scrim {
    position: fixed;
    inset: 0;
    z-index: 45;
    display: block;
    background: rgba(22, 31, 26, 0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
  }

  html.clean-reset-reader body.sidebar-open .sidebar-scrim {
    opacity: 1;
    pointer-events: auto;
  }

  html.clean-reset-reader .wrap {
    padding: 0 20px 58px;
  }

  html.clean-reset-reader .lesson-head {
    display: block;
    margin-bottom: 38px;
    padding-top: 38px;
    padding-bottom: 38px;
  }

  html.clean-reset-reader h1.title {
    font-size: clamp(30px, 9vw, 38px);
  }

  html.clean-reset-reader .lesson-hero {
    margin-top: 28px;
  }

  html.clean-reset-reader .lesson-hero .course-figure img {
    aspect-ratio: 16 / 9;
  }

  html.clean-reset-reader .content p,
  html.clean-reset-reader .content li {
    font-size: 14.5px;
    line-height: 1.76;
  }

  html.clean-reset-reader .lesson-arrival {
    margin-bottom: 34px;
    padding: 23px 22px 22px;
    border-radius: 15px;
  }

  html.clean-reset-reader .lesson-arrival::before {
    left: 22px;
  }

  html.clean-reset-reader .lesson-arrival p {
    font-size: 14.5px;
  }

  html.clean-reset-reader .course-figure img {
    border-width: 4px;
    border-radius: 15px;
  }

  html.clean-reset-reader .lesson-action {
    padding: 24px 21px 26px;
  }

  html.clean-reset-reader .lesson-remember,
  html.clean-reset-reader .lesson-sources {
    padding: 23px 21px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
