:root {
  color-scheme: light;
  --bg: #f6f0e6;
  --paper: #fffdf8;
  --ink: #1f1a15;
  --muted: #6d6054;
  --line: #e3d7c4;
  --accent: #2b6567;
  --accent-2: #8d6a3f;
  --soft: #edf3ef;
  --locked: #8d857b;
  --shadow: 0 16px 40px rgba(70, 55, 35, 0.08);
  --body-font: "HarmonyOS Sans SC", "MiSans", "PingFang SC", "Microsoft YaHei", sans-serif;
  --display-font: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
  font-family: var(--body-font);
}

/* V1.0 cohort learning loop */
.cohort-switcher {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin: 10px 0;
}

.cohort-switcher button {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.cohort-switcher button.active {
  border-color: var(--forest);
  background: var(--forest-soft);
  color: var(--forest);
  font-weight: 700;
}

.learning-panel-head span,
.learning-hub-hero > span,
.assignment-editor-page > header > span,
.section-heading > span,
.feedback-panel > span {
  color: var(--bronze);
  font-size: 12px;
  font-weight: 750;
}

.assignment-status-list {
  display: grid;
  gap: 2px;
  margin-top: 20px;
  border-top: 1px solid var(--line);
}

.assignment-status-list div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 44px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.assignment-status-list strong {
  color: var(--ink);
  font-size: 15px;
}

.sidebar-action {
  width: 100%;
  min-height: 42px;
  margin-top: 18px;
  border: 1px solid var(--forest);
  border-radius: 5px;
  background: transparent;
  color: var(--forest);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.community-section-switch {
  display: grid;
  gap: 4px;
  margin: 18px 0;
}

.community-section-switch button {
  min-height: 42px;
  border: 0;
  border-left: 3px solid transparent;
  background: transparent;
  color: var(--muted);
  text-align: left;
  padding: 0 12px;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.community-section-switch button.active {
  border-left-color: var(--forest);
  background: var(--forest-soft);
  color: var(--forest);
}

.community-sidebar-note {
  display: flex;
  align-items: baseline;
  gap: 7px;
  margin-top: 28px;
  color: var(--muted);
}

.community-sidebar-note strong {
  color: var(--forest);
  font-family: var(--display-font);
  font-size: 32px;
}

.learning-hub-page,
.assignment-editor-page,
.submission-detail-page {
  width: min(100%, 1040px);
  margin: 0 auto;
  padding: 62px 7% 100px;
}

.learning-hub-hero,
.assignment-editor-page > header,
.submission-detail-page > header {
  max-width: 780px;
  margin-bottom: 46px;
}

.learning-hub-hero h1,
.assignment-editor-page h1,
.submission-detail-page h1 {
  margin: 12px 0 18px;
  color: var(--ink);
  font-family: var(--display-font);
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: 0;
}

.learning-hub-hero p,
.assignment-editor-page > header p,
.submission-detail-page > header p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.8;
}

.cohort-mode-notice {
  margin: -18px 0 30px;
  border-left: 3px solid var(--bronze);
  background: #faf4e8;
  color: var(--bronze);
  padding: 13px 16px;
  font-size: 13px;
  font-weight: 700;
}

.assignment-course-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
}

.assignment-course-card {
  min-width: 0;
  min-height: 164px;
  border: 0;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  padding: 24px 26px;
  text-align: left;
  cursor: pointer;
}

.assignment-course-card:nth-child(2n) {
  border-right: 0;
}

.assignment-course-card:hover,
.assignment-course-card:focus-visible {
  background: var(--forest-soft);
}

.assignment-course-card > span {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.assignment-course-card > span b {
  color: var(--forest);
  font-size: 11px;
}

.assignment-course-card > strong {
  display: block;
  margin: 16px 0 12px;
  font-size: 17px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.assignment-course-card > small {
  color: var(--muted);
  line-height: 1.6;
}

.back-link {
  margin-bottom: 34px;
  border: 0;
  background: transparent;
  color: var(--forest);
  padding: 0;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.submission-state-line {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 24px;
  color: var(--muted);
  font-size: 12px;
}

.submission-state-line b {
  border-radius: 999px;
  background: var(--forest-soft);
  color: var(--forest);
  padding: 5px 9px;
}

.assignment-form {
  display: grid;
  gap: 24px;
  max-width: 820px;
}

.assignment-form > label,
.feedback-form > label {
  display: grid;
  gap: 9px;
}

.assignment-form label > span,
.feedback-form label > span,
.assignment-form legend {
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

.assignment-form label em {
  color: var(--muted);
  font-style: normal;
  font-weight: 400;
}

.assignment-form input[type="text"],
.assignment-form input[type="url"],
.assignment-form input:not([type]),
.assignment-form textarea,
.feedback-form textarea,
.comment-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: var(--ink);
  padding: 13px 14px;
  font: inherit;
  font-size: 15px;
  line-height: 1.7;
  resize: vertical;
}

.assignment-form input:focus,
.assignment-form textarea:focus,
.feedback-form textarea:focus,
.comment-form textarea:focus {
  border-color: var(--forest);
  outline: 2px solid rgba(16, 101, 90, 0.1);
}

.assignment-form label > small {
  color: var(--muted);
  font-size: 12px;
}

.assignment-form fieldset {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  border: 0;
  padding: 0;
}

.assignment-form fieldset label {
  color: var(--muted);
  font-size: 14px;
}

.assignment-form-actions,
.feedback-form > div {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.secondary-action {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: var(--ink);
  padding: 0 18px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.feedback-panel,
.feedback-list,
.comment-section,
.feedback-form {
  max-width: 820px;
  margin-top: 48px;
}

.feedback-list article,
.comment-list article {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}

.feedback-list article > div,
.comment-list article > div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  font-size: 12px;
}

.feedback-list p,
.comment-list p {
  color: var(--ink);
  line-height: 1.8;
}

.feedback-list article > b {
  color: var(--bronze);
  font-size: 12px;
}

.quiet-empty {
  color: var(--muted);
  line-height: 1.8;
}

.submitted-reading,
.submission-body {
  max-width: 820px;
  color: var(--ink);
  font-size: 17px;
  line-height: 2;
}

.submitted-reading blockquote,
.submission-reflection {
  margin: 24px 0 34px;
  border-left: 3px solid var(--bronze);
  background: #faf4e8;
  padding: 20px 24px;
  color: var(--ink);
  font-family: var(--display-font);
  font-size: 19px;
  line-height: 1.85;
}

.submission-detail-page > header > div {
  display: flex;
  gap: 12px;
  color: var(--bronze);
  font-size: 13px;
  font-weight: 700;
}

.submission-detail-page > header > div b {
  border-radius: 999px;
  background: #faf1df;
  padding: 3px 8px;
}

.work-link {
  display: inline-flex;
  margin-top: 28px;
  color: var(--forest);
  font-weight: 700;
}

.feedback-form {
  display: grid;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding-top: 32px;
}

.feedback-form .featured-check {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.section-heading {
  margin-bottom: 22px;
}

.section-heading h2 {
  margin: 6px 0 0;
  font-family: var(--display-font);
  font-size: 28px;
  font-weight: 600;
}

.community-work-section + .community-work-section {
  margin-top: 56px;
}

.community-work-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.community-work-card {
  min-width: 0;
  min-height: 210px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  padding: 24px;
  text-align: left;
  cursor: pointer;
}

.community-work-card:hover,
.community-work-card:focus-visible {
  border-color: rgba(16, 101, 90, 0.45);
  box-shadow: 0 10px 28px rgba(20, 65, 57, 0.07);
}

.community-work-card > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--forest);
  font-size: 12px;
  font-weight: 700;
}

.community-work-card > div b {
  color: var(--bronze);
}

.community-work-card > strong {
  display: block;
  margin: 16px 0 10px;
  color: var(--ink);
  font-family: var(--display-font);
  font-size: 21px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.community-work-card p,
.community-work-card small {
  color: var(--muted);
  line-height: 1.7;
}

.comment-section {
  border-top: 1px solid var(--line);
  padding-top: 38px;
}

.comment-form {
  display: grid;
  justify-items: end;
  gap: 12px;
  margin-top: 24px;
}

.online-assignment-entry {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin: 40px 0 80px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 26px 0;
}

.online-assignment-entry > div {
  display: grid;
  gap: 6px;
}

.online-assignment-entry span {
  color: var(--bronze);
  font-size: 12px;
  font-weight: 750;
}

.online-assignment-entry strong {
  color: var(--ink);
  font-size: 18px;
}

.online-assignment-entry p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

@media (max-width: 960px) {
  .primary-nav {
    overflow-x: auto;
    scrollbar-width: none;
  }

  .primary-nav button {
    flex: 0 0 auto;
  }

  .assignment-course-grid,
  .community-work-grid {
    grid-template-columns: 1fr;
  }

  .assignment-course-card,
  .assignment-course-card:nth-child(2n) {
    border-right: 0;
  }
}

@media (max-width: 640px) {
  .learning-hub-page,
  .assignment-editor-page,
  .submission-detail-page {
    padding: 34px 20px 80px;
  }

  .learning-hub-hero h1,
  .assignment-editor-page h1,
  .submission-detail-page h1 {
    font-size: 30px;
  }

  .assignment-course-card {
    min-height: 142px;
    padding: 20px 4px;
  }

  .community-work-card {
    padding: 20px;
  }

  .online-assignment-entry {
    align-items: stretch;
    flex-direction: column;
  }

  .online-assignment-entry .primary-action,
  .assignment-form-actions button,
  .feedback-form > div button {
    flex: 1;
  }
}

/* Course completion and in-site resource reading. */
.week-course-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 20px;
}

.week-course-meta em {
  color: var(--forest);
  font-size: 12px;
  font-style: normal;
  font-weight: 650;
}

.week-course-meta b,
.course-status-line b {
  border: 1px solid rgba(16, 101, 90, 0.22);
  border-radius: 999px;
  background: #edf7f4;
  color: var(--forest);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  padding: 4px 7px;
}

.course-status-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}

.course-status-line > span {
  color: var(--bronze);
  font-size: 13px;
  font-weight: 700;
}

.course-hero-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 22px;
}

.course-completion-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--muted);
  padding: 0 13px;
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}

.course-completion-toggle:hover,
.course-completion-toggle.is-complete {
  border-color: rgba(16, 101, 90, 0.35);
  background: #edf7f4;
  color: var(--forest);
}

.resource-list button {
  display: grid;
  width: 100%;
  gap: 7px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: inherit;
  padding: 17px 0;
  text-align: left;
  cursor: pointer;
}

.resource-list button:hover strong {
  color: var(--forest);
}

.resource-list button strong {
  font-size: 15px;
  line-height: 1.55;
}

.resource-list button small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.resource-list button em {
  color: var(--forest);
  font-size: 12px;
  font-style: normal;
  font-weight: 650;
}

.resource-drawer.has-reader {
  width: min(920px, calc(100vw - 64px));
}

.resource-reader-loading {
  padding: 56px 0;
  color: var(--muted);
  text-align: center;
}

.course-resource-reader {
  width: min(760px, 100%);
  margin: 0 auto;
  padding: 18px 0 60px;
}

.resource-reader-back {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 0;
  background: transparent;
  color: var(--forest);
  padding: 0 0 24px;
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}

.resource-reader-back .back-icon {
  transform: rotate(180deg);
}

.course-resource-reader > header {
  padding: 10px 0 30px;
  border-bottom: 1px solid var(--line);
}

.course-resource-reader > header > span {
  color: var(--bronze);
  font-size: 13px;
  font-weight: 700;
}

.course-resource-reader > header h2 {
  max-width: 18em;
  margin: 10px 0 12px;
  font-family: var(--display-font);
  font-size: clamp(30px, 4vw, 46px);
  font-weight: 600;
  line-height: 1.2;
}

.course-resource-reader > header p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
}

.course-resource-sections > section {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 22px;
  padding: 36px 0;
  border-bottom: 1px solid var(--line);
}

.resource-section-marker {
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
  padding-top: 7px;
}

.course-resource-sections h3 {
  margin: 0 0 20px;
  font-family: var(--display-font);
  font-size: 26px;
  font-weight: 600;
  line-height: 1.35;
}

@media (max-width: 720px) {
  .course-hero-actions {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .resource-drawer.has-reader {
    width: 100%;
  }

  .course-resource-reader > header h2 {
    font-size: 30px;
  }

  .course-resource-sections > section {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 28px 0;
  }

  .course-resource-sections h3 {
    font-size: 23px;
  }
}

/* In-site reading for method materials and FAQ. */
.material-card-button {
  width: 100%;
  appearance: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.material-card-button:hover {
  border-color: rgba(15, 91, 84, 0.48);
  background: #f8fbf9;
  transform: translateY(-2px);
}

.material-card .material-open-hint {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  align-self: end;
  color: var(--accent);
  font-weight: 600;
}

.material-open-hint .ui-icon {
  width: 15px;
  height: 15px;
}

.material-detail-page {
  width: min(980px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 0;
}

.material-back-button {
  width: max-content;
  min-height: 40px;
  margin-bottom: 18px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 0;
  background: transparent;
  color: var(--accent);
  font-weight: 600;
}

.material-back-button .back-icon {
  width: 16px;
  height: 16px;
  transform: rotate(180deg);
}

.material-detail-hero {
  padding: 36px 0 40px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.material-detail-hero > span {
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 600;
}

.material-detail-hero h1 {
  max-width: 820px;
  margin: 10px 0 0;
  color: var(--ink);
  font-family: var(--display-font);
  font-size: 42px;
  font-weight: 600;
  line-height: 1.3;
}

.material-detail-hero p {
  max-width: 760px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.material-reader-section {
  padding: 42px 0;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 24px;
  border-bottom: 1px solid var(--line);
}

.material-reader-marker {
  color: var(--accent-2);
  font-size: 12px;
  font-weight: 600;
}

.material-reader-body {
  min-width: 0;
}

.material-reader-body h2 {
  margin: 0 0 22px;
  color: var(--ink);
  font-family: var(--display-font);
  font-size: 28px;
  font-weight: 600;
  line-height: 1.45;
}

.material-reader-body .lesson-text-block,
.material-reader-body .lesson-list-block li,
.material-reader-body .lesson-note-block {
  font-weight: 400;
}

@media (max-width: 720px) {
  .material-detail-hero {
    padding: 28px 0 32px;
  }

  .material-detail-hero h1 {
    font-size: 31px;
  }

  .material-detail-hero p {
    font-size: 15px;
  }

  .material-reader-section {
    padding: 34px 0;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .material-reader-marker {
    display: block;
  }

  .material-reader-body h2 {
    font-size: 24px;
  }
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(43, 101, 103, 0.07) 0 1px, transparent 1px 100%),
    linear-gradient(180deg, rgba(141, 106, 63, 0.05) 0 1px, transparent 1px 100%),
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.88), transparent 42%),
    linear-gradient(135deg, #fffdf8, #f5efe6 52%, #eef3ed);
  background-size: 36px 36px, 36px 36px, auto, auto;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.boot-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 18px;
  color: var(--muted);
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-row strong,
.brand-row span {
  display: block;
}

.brand-row strong {
  font-size: 15px;
}

.brand-row span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  letter-spacing: 0;
}

.auth-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.8fr);
}

.auth-visual {
  min-height: 100vh;
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    linear-gradient(140deg, rgba(30, 27, 24, 0.72), rgba(39, 99, 91, 0.48)),
    radial-gradient(circle at 74% 26%, rgba(255, 255, 255, 0.32), transparent 26%),
    linear-gradient(135deg, #365e58, #c9784a);
  color: #fff;
}

.auth-visual .brand-row span {
  color: rgba(255, 255, 255, 0.72);
}

.auth-visual .brand-mark {
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.cover-copy {
  max-width: 760px;
}

.cover-copy h1 {
  margin: 0;
  font-family: var(--display-font);
  font-size: clamp(42px, 6vw, 76px);
  line-height: 1.02;
  letter-spacing: 0;
}

.cover-copy p {
  max-width: 620px;
  margin: 24px 0 0;
  font-size: 18px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.82);
}

.cover-media {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 14px;
}

.media-card {
  min-height: 118px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px);
}

.media-card span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.media-card strong {
  font-size: 18px;
  line-height: 1.35;
}

.auth-panel {
  min-height: 100vh;
  padding: 56px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: rgba(255, 253, 249, 0.84);
  box-shadow: -18px 0 60px rgba(67, 52, 37, 0.08);
}

.auth-panel h2 {
  margin: 0;
  font-family: var(--display-font);
  font-size: 30px;
  letter-spacing: 0;
}

.auth-panel p {
  color: var(--muted);
  line-height: 1.7;
}

.login-form {
  margin-top: 28px;
  display: grid;
  gap: 12px;
}

.login-form label {
  font-size: 14px;
  font-weight: 700;
}

.login-form input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  outline: none;
}

.login-form input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(39, 99, 91, 0.12);
}

.login-form button,
.primary-action {
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 750;
}

.form-hint {
  margin: 6px 0 0;
  font-size: 13px;
}

.form-error {
  min-height: 22px;
  margin: 0;
  color: #a13b23;
  font-weight: 700;
}

.auth-page {
  width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr;
  place-items: center;
  padding: 24px;
}

.auth-panel {
  width: min(100%, 430px);
  min-height: auto;
  padding: 40px;
  display: grid;
  gap: 28px;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.94);
  box-shadow: 0 24px 70px rgba(67, 52, 37, 0.11);
}

.auth-brand {
  display: grid;
  justify-items: center;
  gap: 12px;
  text-align: center;
}

.auth-brand .brand-mark {
  width: 54px;
  height: 54px;
  border-radius: 14px;
}

.auth-panel h1 {
  margin: 0;
  font-family: var(--display-font);
  font-size: 30px;
  line-height: 1.22;
  letter-spacing: 0;
}

.auth-panel p {
  margin: 0;
}

.login-form {
  margin-top: 0;
}

.app-shell {
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  min-height: 72px;
  padding: 0 28px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  background: rgba(255, 253, 249, 0.9);
  border-bottom: 1px solid rgba(222, 215, 204, 0.78);
  backdrop-filter: blur(18px);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.main-nav button {
  min-height: 34px;
  padding: 0 14px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.main-nav button.active {
  background: var(--accent);
  color: #fff;
}

.student-chip {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 10px;
}

.student-chip span {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
  font-size: 14px;
}

.student-chip button {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

main {
  width: min(1440px, calc(100vw - 40px));
  margin: 0 auto;
}

.overview-band {
  padding: 42px 0 28px;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.75fr) 260px;
  gap: 22px;
  align-items: stretch;
}

.today-study-card,
.today-task-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.today-study-card {
  padding: 30px;
  display: grid;
  align-content: space-between;
  gap: 18px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(23, 33, 29, 0.96), rgba(22, 88, 79, 0.88)),
    var(--ink);
}

.today-study-card span,
.today-task-panel span {
  color: inherit;
  opacity: 0.72;
  font-size: 13px;
  font-weight: 850;
}

.today-study-card h1 {
  max-width: 920px;
  margin: 0;
  font-family: var(--display-font);
  font-size: clamp(32px, 4.4vw, 58px);
  line-height: 1.12;
  letter-spacing: 0;
}

.today-study-card p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 17px;
  line-height: 1.75;
}

.today-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.today-actions .primary-action {
  background: #fff;
  color: var(--accent);
}

.today-actions small {
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.6;
}

.today-task-panel {
  padding: 24px;
  display: grid;
  align-content: start;
  gap: 12px;
  background:
    linear-gradient(180deg, rgba(255, 248, 241, 0.98), rgba(255, 253, 249, 0.94));
  border-color: rgba(192, 90, 55, 0.22);
}

.today-task-panel strong {
  font-size: 24px;
}

.today-task-panel p {
  margin: 0;
  color: #51362d;
  line-height: 1.72;
}

.progress-panel,
.rhythm-band,
.welcome-card,
.loading-card,
.error-card,
.source-card,
.media-panel,
.route-card,
.concept-card,
.comparison-card,
.role-section,
.task-card,
.case-section,
.transcript-card,
.related-course-card,
.material-note {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.88);
  box-shadow: var(--shadow);
}

.progress-panel {
  padding: 24px;
  display: grid;
  align-content: center;
  gap: 8px;
}

.progress-panel span,
.task-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.progress-panel strong {
  font-size: 38px;
}

.progress-meter {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e1e7e0;
}

.progress-meter i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
}

.progress-panel small {
  color: var(--muted);
  line-height: 1.6;
}

.rhythm-band {
  margin: 0 0 22px;
  padding: 22px;
}

.rhythm-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 420px);
  gap: 18px;
  align-items: end;
}

.rhythm-head span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.rhythm-head h2 {
  margin: 4px 0 0;
  font-family: var(--display-font);
  font-size: 26px;
}

.rhythm-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.week-track {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.week-chip {
  position: relative;
  min-height: 132px;
  padding: 16px;
  display: grid;
  align-content: space-between;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(250, 253, 250, 0.96));
  overflow: hidden;
}

.week-chip::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: var(--locked);
}

.week-chip.is-open {
  border-color: rgba(39, 99, 91, 0.38);
  background:
    linear-gradient(180deg, rgba(231, 241, 236, 0.96), rgba(255, 254, 250, 0.98));
}

.week-chip.is-open::before {
  background: var(--accent);
}

.week-chip.is-locked {
  color: var(--locked);
  background: #eef1ed;
}

.week-chip span,
.week-chip small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.week-chip strong {
  line-height: 1.35;
}

.workspace-grid {
  padding: 0 0 48px;
  display: grid;
  grid-template-columns: 390px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  scroll-margin-top: 92px;
}

.side-panel {
  position: sticky;
  top: 92px;
  max-height: calc(100vh - 110px);
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.76);
}

.panel-head h2 {
  margin: 0;
  font-size: 20px;
}

.panel-head p {
  margin: 8px 0 18px;
  color: var(--muted);
  line-height: 1.6;
  font-size: 14px;
}

.course-list,
.replay-list {
  display: grid;
  gap: 10px;
}

.course-week {
  display: grid;
  gap: 10px;
}

.course-week + .course-week {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.course-week-head {
  display: grid;
  gap: 4px;
}

.course-week-head strong {
  font-size: 15px;
}

.course-week-head span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.course-row {
  position: relative;
  width: 100%;
  padding: 15px 15px 15px 18px;
  display: grid;
  gap: 8px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 254, 250, 0.94);
  color: var(--ink);
  transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.course-row::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 4px 4px 0;
  background: var(--accent);
}

.course-row:hover {
  transform: translateY(-1px);
  border-color: rgba(22, 88, 79, 0.34);
  box-shadow: 0 12px 28px rgba(38, 63, 54, 0.1);
}

.course-row strong {
  font-size: 15px;
  line-height: 1.42;
}

.course-row small,
.row-meta {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.course-row.selected {
  border-color: var(--accent);
  background: #fbfffb;
  box-shadow: 0 0 0 3px rgba(22, 88, 79, 0.13), 0 16px 34px rgba(38, 63, 54, 0.12);
}

.course-row.is-locked {
  color: var(--locked);
  background: #eef1ed;
}

.course-row.is-locked::before {
  background: #a8b0aa;
}

.course-row.is-locked:hover {
  transform: none;
  box-shadow: none;
}

.detail-panel {
  min-width: 0;
  scroll-margin-top: 94px;
}

.welcome-card,
.loading-card,
.error-card {
  min-height: 420px;
  padding: 36px;
  display: grid;
  align-content: center;
  gap: 18px;
}

.welcome-card h2 {
  margin: 0;
  font-family: var(--display-font);
  font-size: 34px;
}

.welcome-learning > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.welcome-card p,
.empty {
  max-width: 620px;
  color: var(--muted);
  line-height: 1.8;
}

.welcome-current {
  max-width: 720px;
  padding: 18px;
  display: grid;
  gap: 10px;
  border: 1px solid rgba(22, 88, 79, 0.18);
  border-radius: 8px;
  background: #f7fbf8;
}

.welcome-current strong {
  line-height: 1.45;
}

.welcome-current small {
  color: var(--muted);
  line-height: 1.65;
}

.primary-action {
  width: fit-content;
  padding: 0 20px;
}

.lesson-page {
  display: grid;
  gap: 18px;
  scroll-margin-top: 94px;
}

.source-card {
  padding: 18px;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  align-items: center;
  gap: 18px;
}

.source-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.source-card strong {
  display: block;
  margin-top: 4px;
}

.source-card p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.source-actions {
  flex: 0 0 auto;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.source-card a {
  flex: 0 0 auto;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--accent);
  background: #fff;
  font-weight: 800;
  text-decoration: none;
}

.lesson-hero {
  padding: 30px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 170px;
  gap: 24px;
  align-items: start;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
}

.lesson-meta {
  color: rgba(255, 255, 255, 0.66);
  font-size: 13px;
  font-weight: 750;
}

.lesson-hero h2 {
  margin: 12px 0 0;
  font-family: var(--display-font);
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.12;
  letter-spacing: 0;
}

.lesson-hero p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.75;
}

.lesson-stat {
  padding: 18px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
}

.lesson-stat span,
.lesson-stat strong {
  display: block;
}

.lesson-stat span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
}

.lesson-stat strong {
  margin-top: 8px;
  font-size: 24px;
}

.lesson-compass {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(260px, 0.9fr);
  gap: 14px;
}

.lesson-compass article {
  min-height: 150px;
  padding: 20px;
  display: grid;
  align-content: start;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.9);
  box-shadow: var(--shadow);
}

.lesson-compass span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.lesson-compass strong {
  font-size: 18px;
  line-height: 1.55;
}

.lesson-compass p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.lesson-compass .compass-task {
  border-color: rgba(192, 90, 55, 0.24);
  background: #fff8f1;
}

.lesson-compass .compass-task span,
.lesson-compass .compass-task strong {
  color: #7f3b27;
}

.lesson-reading-shell {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
  gap: 26px;
  align-items: start;
  scroll-margin-top: 112px;
}

.lesson-module-nav {
  position: sticky;
  top: 92px;
  padding: 18px;
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.94);
  box-shadow: var(--shadow);
}

.lesson-module-nav > span,
.lesson-lead-card > span,
.module-head > span,
.module-card > span,
.module-task-panel span,
.module-takeaways > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.lesson-module-nav strong {
  font-family: var(--display-font);
  font-size: 24px;
  line-height: 1.25;
}

.lesson-module-nav p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.lesson-module-nav nav {
  display: grid;
  gap: 8px;
}

.lesson-module-nav a {
  min-width: 0;
  padding: 10px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--ink);
  text-decoration: none;
}

.lesson-module-nav a:hover {
  border-color: rgba(22, 88, 79, 0.18);
  background: var(--soft);
}

.lesson-module-nav em {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}

.lesson-module-nav a span {
  min-width: 0;
  overflow-wrap: anywhere;
  font-weight: 800;
  line-height: 1.45;
}

.lesson-module-list {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.lesson-lead-card {
  margin-bottom: 10px;
  padding: 30px;
  border-radius: 8px;
  color: #fff;
  scroll-margin-top: 112px;
  background:
    linear-gradient(135deg, rgba(23, 33, 29, 0.96), rgba(39, 99, 91, 0.9)),
    var(--ink);
}

.lesson-lead-card > span {
  color: rgba(255, 255, 255, 0.68);
}

.lesson-lead-card h3 {
  max-width: 840px;
  margin: 10px 0 0;
  font-family: var(--display-font);
  font-size: clamp(28px, 3.7vw, 44px);
  line-height: 1.12;
}

.lesson-lead-card p {
  max-width: 760px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.8;
}

.lesson-lead-card ul {
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  list-style: none;
}

.lesson-lead-card li {
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  line-height: 1.6;
}

.lesson-module {
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 112px;
}

.lesson-module:first-of-type {
  border-top: 1px solid var(--line);
}

.module-head {
  max-width: 860px;
  display: grid;
  gap: 10px;
}

.module-head > span {
  color: var(--accent-2);
}

.module-head h3 {
  margin: 0;
  font-family: var(--display-font);
  font-size: clamp(26px, 3.4vw, 38px);
  line-height: 1.18;
}

.module-head p,
.module-text {
  margin: 0;
  color: #312d28;
  font-size: 17px;
  line-height: 1.92;
}

.module-body {
  margin-top: 18px;
  display: grid;
  gap: 16px;
}

.module-quote {
  margin: 0;
  padding: 18px 20px;
  border-left: 5px solid var(--accent-2);
  border-radius: 0 8px 8px 0;
  background: #fff8f1;
  color: #573828;
  font-family: var(--display-font);
  font-size: 20px;
  line-height: 1.72;
}

.module-callout,
.module-prompt-card,
.module-takeaways {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffefa;
}

.module-callout {
  border-color: rgba(22, 88, 79, 0.18);
  background: #f7fbf8;
}

.module-callout strong,
.module-prompt-card strong,
.module-task-panel strong {
  display: block;
  font-size: 18px;
  line-height: 1.45;
}

.module-callout p,
.module-prompt-card p,
.module-card p,
.module-task-panel p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.76;
}

.module-card-grid,
.module-task-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.module-card,
.module-task-panel article {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.module-card strong {
  display: block;
  margin-top: 6px;
  font-size: 18px;
  line-height: 1.45;
}

.module-steps,
.module-checklist,
.module-takeaways ul {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  list-style: none;
}

.module-steps {
  counter-reset: module-step;
}

.module-steps li,
.module-checklist li,
.module-takeaways li {
  min-width: 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  line-height: 1.72;
  overflow-wrap: anywhere;
}

.module-steps li {
  counter-increment: module-step;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 12px;
}

.module-steps li::before {
  content: counter(module-step, decimal-leading-zero);
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.module-steps li strong,
.module-steps li span {
  grid-column: 2;
}

.module-steps li strong {
  align-self: end;
}

.module-steps li span {
  color: var(--muted);
}

.module-checklist li {
  padding-left: 42px;
  position: relative;
}

.module-checklist li::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 21px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
}

.module-table-wrap {
  max-width: 100%;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.module-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  background: #fff;
}

.module-table th,
.module-table td {
  padding: 14px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: left;
  line-height: 1.66;
  vertical-align: top;
}

.module-table th {
  background: var(--soft);
  color: var(--accent);
  font-weight: 850;
}

.module-table th:last-child,
.module-table td:last-child {
  border-right: 0;
}

.module-table tr:last-child td {
  border-bottom: 0;
}

.module-prompt-card pre {
  margin: 12px 0 0;
  padding: 14px;
  border-radius: 8px;
  background: #17211d;
  color: #fff;
  line-height: 1.68;
}

.module-task-panel small {
  display: block;
  margin-top: 10px;
  color: var(--accent-2);
  font-weight: 850;
  line-height: 1.5;
}

.module-takeaways h3 {
  margin: 8px 0 16px;
  font-family: var(--display-font);
  font-size: 26px;
}

.media-switch {
  display: flex;
  gap: 8px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.media-switch button {
  flex: 1;
  min-width: 92px;
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: 750;
  white-space: nowrap;
  word-break: keep-all;
}

.media-switch button.active {
  background: var(--accent);
  color: #fff;
}

.media-switch button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.media-panel,
.route-card,
.comparison-card,
.role-section,
.task-card,
.case-section,
.transcript-card {
  padding: 26px;
}

.route-card h3,
.comparison-card h3,
.role-section h3,
.case-section h3,
.transcript-card h3 {
  margin: 0 0 14px;
  font-family: var(--display-font);
  font-size: 22px;
}

.media-panel p,
.route-card li,
.concept-card p,
.task-card p,
.case-card p,
.case-card dd,
.transcript-card pre {
  line-height: 1.78;
}

audio,
video {
  width: 100%;
  margin-top: 14px;
  border-radius: 8px;
  background: #111;
}

video {
  max-height: 520px;
}

.prompt-card {
  margin: 0 0 18px;
  padding: 0;
  border-radius: 8px;
  background: transparent;
}

.prompt-card > strong {
  display: block;
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 15px;
}

.sync-note {
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent) !important;
  font-weight: 750;
}

pre {
  white-space: pre-wrap;
  word-break: break-word;
  font-family: "Cascadia Mono", "SFMono-Regular", Consolas, monospace;
}

.full-text {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.full-text summary {
  font-weight: 800;
}

.course-manuscript {
  display: grid;
  gap: 18px;
}

.lesson-body-cover {
  padding: 26px;
  border-radius: 8px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(23, 33, 29, 0.96), rgba(22, 88, 79, 0.9)),
    var(--ink);
}

.lesson-body-cover span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
  font-weight: 850;
}

.lesson-body-cover h3 {
  max-width: 860px;
  margin: 8px 0 0;
  font-family: var(--display-font);
  font-size: clamp(26px, 3.6vw, 40px);
  line-height: 1.18;
}

.lesson-body-cover p {
  max-width: 720px;
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.78;
}

.lesson-outline {
  padding: 14px;
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.lesson-outline a {
  max-width: 100%;
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.45;
  text-decoration: none;
}

.lesson-outline a:hover {
  background: var(--soft);
}

.lesson-outline .outline-level-1 {
  color: var(--ink);
  font-size: 15px;
}

.lesson-outline .outline-level-2 {
  padding-left: 18px;
}

.lesson-outline .outline-level-3,
.lesson-outline .outline-level-4 {
  padding-left: 34px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.lesson-sections {
  display: grid;
  gap: 16px;
}

.lesson-section {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 16px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(231, 241, 236, 0.3), transparent 24%),
    #fff;
}

.lesson-section-marker {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-weight: 900;
}

.lesson-section-body {
  min-width: 0;
}

.lesson-section h4 {
  margin: 2px 0 14px;
  font-family: var(--display-font);
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.26;
}

.lesson-section.level-3 {
  background: #fff;
}

.lesson-section.level-3 .lesson-section-marker {
  background: #f5f1ea;
  color: var(--accent-2);
}

.lesson-section.level-3 h4 {
  font-size: clamp(20px, 2.4vw, 26px);
}

.lesson-text-block,
.lesson-note-block,
.lesson-step-block,
.lesson-kicker-block,
.lesson-link-block,
.lesson-prompt-block,
.lesson-quote-block,
.lesson-list-block {
  overflow-wrap: anywhere;
}

.lesson-paragraph-group {
  display: grid;
  gap: 10px;
}

.lesson-text-block {
  margin: 0;
  color: #312d28;
  font-size: 17px;
  line-height: 2;
}

.lesson-note-block,
.lesson-step-block,
.lesson-kicker-block,
.lesson-link-block,
.lesson-prompt-block {
  margin: 14px 0 0;
  padding: 14px 16px;
  border-radius: 8px;
  line-height: 1.78;
}

.lesson-note-block {
  border: 1px solid rgba(180, 83, 42, 0.2);
  background: #fff8f1;
  color: var(--accent-2);
  font-weight: 400;
}

.lesson-quote-block {
  margin: 14px 0 0;
  padding: 14px 16px;
  border-left: 4px solid var(--accent);
  border-radius: 0 8px 8px 0;
  background: #f7fbf8;
  color: #31413b;
  line-height: 1.78;
}

.lesson-list-block {
  margin: 12px 0 0;
  padding: 16px 18px 16px 34px;
  border-radius: 8px;
  background: #fafcf9;
}

.lesson-list-block.rich-list {
  margin: 0;
  display: grid;
  gap: 10px;
  list-style: none;
  padding: 16px;
  border: 1px solid rgba(43, 101, 103, 0.14);
}

.lesson-list-block.rich-list li {
  position: relative;
  margin: 0;
  padding-left: 18px;
}

.lesson-list-block.rich-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.78em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.lesson-list-block li {
  margin: 6px 0;
  line-height: 1.76;
}

.lesson-step-block {
  background: var(--soft);
  color: var(--accent);
  font-weight: 850;
}

.lesson-kicker-block {
  border-left: 4px solid var(--accent);
  background: #f8fbf8;
  color: var(--accent);
  font-weight: 850;
}

.lesson-link-block {
  background: #f5f1ea;
  font-weight: 750;
}

.lesson-prompt-block {
  margin: 14px 0 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(39, 99, 91, 0.22);
  border-radius: 8px;
  background: #17211d;
  color: #fff;
}

.prompt-block-head {
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.prompt-block-head span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  font-weight: 850;
}

.prompt-block-head button {
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 13px;
  font-weight: 750;
}

.lesson-prompt-block pre {
  margin: 0;
  padding: 16px;
  color: #fff;
  font-size: 14px;
  line-height: 1.82;
  white-space: pre-wrap;
  word-break: break-word;
}

.lesson-section a {
  color: var(--accent);
  font-weight: 800;
}

.course-seven-manuscript {
  gap: 20px;
}

.curated-outline {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.curated-outline a {
  padding: 10px 12px;
  border: 1px solid rgba(43, 101, 103, 0.12);
  background: #fbfaf7;
}

.curated-sections {
  display: grid;
  gap: 18px;
}

.curated-section {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.curated-section.intro-section {
  background:
    linear-gradient(120deg, rgba(231, 241, 236, 0.78), rgba(255, 255, 255, 0.88) 60%),
    #fff;
}

.section-kicker {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
}

.curated-section h3 {
  margin: 0 0 14px;
  font-family: var(--display-font);
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.28;
}

.curated-lead,
.section-copy,
.closing-copy {
  max-width: 850px;
  color: #312d28;
  font-size: 17px;
  line-height: 1.95;
}

.curated-lead {
  display: grid;
  gap: 10px;
}

.curated-lead p,
.section-copy,
.closing-copy {
  margin: 0;
}

.signal-card {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(240px, 0.8fr);
  gap: 16px;
  margin-top: 18px;
}

.signal-card > div,
.standard-grid article,
.source-grid article,
.flow-steps article,
.decision-ladder article,
.summary-grid article,
.prep-grid article,
.principle-grid article,
.inbox-grid article,
.movement-timeline article {
  padding: 18px;
  border: 1px solid rgba(43, 101, 103, 0.14);
  border-radius: 8px;
  background: #fbfdfb;
}

.signal-card strong,
.source-grid strong,
.flow-steps strong,
.summary-grid strong,
.prep-grid strong,
.principle-grid strong,
.inbox-grid strong {
  display: block;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.5;
}

.signal-card span,
.standard-grid span,
.flow-steps span,
.decision-ladder span,
.movement-timeline span {
  display: inline-flex;
  margin-bottom: 8px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
}

.signal-card p,
.standard-grid p,
.source-grid p,
.flow-steps p,
.decision-ladder p,
.summary-grid p,
.prep-grid p,
.principle-grid p,
.inbox-grid p,
.movement-timeline p {
  margin: 8px 0 0;
  color: #433d36;
  line-height: 1.82;
}

.standard-grid,
.source-grid,
.flow-steps,
.decision-ladder,
.summary-grid,
.prep-grid,
.principle-grid,
.inbox-grid,
.movement-timeline {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.standard-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.source-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.flow-steps {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.prep-grid,
.principle-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.inbox-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.decision-ladder,
.summary-grid,
.movement-timeline {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.curated-callout {
  margin-top: 18px;
  padding: 18px 20px;
  border-left: 4px solid var(--accent-2);
  border-radius: 0 8px 8px 0;
  background: #fff8f1;
}

.curated-callout strong {
  color: var(--accent-2);
  font-size: 17px;
}

.curated-callout p {
  margin: 8px 0 0;
  color: #4b4035;
  line-height: 1.82;
}

.inline-resource-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.inline-resource-grid a {
  padding: 18px;
  border: 1px solid rgba(43, 101, 103, 0.16);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
}

.inline-resource-grid span,
.material-embed-list summary span {
  display: block;
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
}

.inline-resource-grid strong {
  display: block;
  margin-top: 8px;
  font-size: 18px;
  line-height: 1.45;
}

.inline-resource-grid small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}

.material-embed-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.material-embed-list details {
  border: 1px solid rgba(43, 101, 103, 0.14);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.material-embed-list summary {
  padding: 18px 20px;
  cursor: pointer;
  list-style-position: outside;
}

.material-embed-list summary strong {
  display: block;
  margin-top: 6px;
  font-size: 19px;
  line-height: 1.45;
}

.embedded-material-body {
  display: grid;
  gap: 14px;
  padding: 0 20px 20px;
  color: #312d28;
  line-height: 1.86;
}

.embedded-material-body p,
.embedded-material-body h4 {
  margin: 0;
}

.embedded-material-body h4 {
  margin-top: 8px;
  color: var(--ink);
  font-size: 18px;
}

.embedded-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.embedded-list article {
  padding: 16px;
  border: 1px solid rgba(43, 101, 103, 0.12);
  border-radius: 8px;
  background: #fbfdfb;
}

.embedded-list strong {
  display: block;
  color: var(--ink);
  line-height: 1.5;
}

.embedded-list p {
  margin-top: 8px;
  color: #433d36;
  line-height: 1.75;
}

.embedded-ordered-list {
  margin: 0;
  padding-left: 24px;
}

.embedded-ordered-list li {
  margin: 8px 0;
  line-height: 1.78;
}

.embedded-para {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.question-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.question-list li {
  padding: 14px 16px;
  border: 1px solid rgba(43, 101, 103, 0.14);
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-weight: 850;
  line-height: 1.55;
}

.source-grid dl {
  display: grid;
  gap: 6px;
  margin: 14px 0 0;
}

.source-grid dt {
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
}

.source-grid dd {
  margin: 0 0 8px;
  color: #433d36;
  line-height: 1.7;
}

.decision-ladder {
  position: relative;
}

.decision-ladder article {
  background: #fffaf2;
}

.inbox-grid article {
  background: #f8fbf8;
}

.movement-timeline article {
  background: linear-gradient(180deg, #fffaf2, #fff);
}

.closing-copy {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-weight: 750;
}

.lesson-table-wrap {
  max-width: 100%;
  margin: 16px 0 0;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.lesson-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  background: #fff;
}

.lesson-table th,
.lesson-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  text-align: left;
  line-height: 1.62;
  vertical-align: top;
}

.lesson-table th {
  background: var(--soft);
  color: var(--accent);
  font-weight: 850;
}

.lesson-table th:last-child,
.lesson-table td:last-child {
  border-right: 0;
}

.lesson-table tr:last-child td {
  border-bottom: 0;
}

.route-card ol {
  margin: 0;
  padding-left: 24px;
}

.route-card li + li {
  margin-top: 8px;
}

.visual-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.concept-card {
  padding: 22px;
}

.concept-card h3 {
  margin: 0;
  font-size: 20px;
}

.comparison-table {
  display: grid;
  grid-template-columns: 0.7fr 1fr 1fr;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.comparison-table > div {
  padding: 14px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
  line-height: 1.6;
}

.comparison-table > div:nth-child(3n) {
  border-right: 0;
}

.table-head {
  background: var(--soft) !important;
  font-weight: 850;
}

.role-grid,
.case-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.role-grid article,
.case-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.role-grid strong,
.case-card h4 {
  margin: 0;
  font-size: 18px;
}

.task-card {
  border-color: rgba(180, 83, 42, 0.32);
  background: #fff8f1;
}

.task-card-head {
  display: grid;
  gap: 6px;
}

.task-card h3 {
  margin: 0;
  font-family: var(--display-font);
  font-size: 24px;
  line-height: 1.3;
}

.task-card p {
  margin: 8px 0 0;
  font-size: 17px;
  white-space: normal;
}

.task-section-grid {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.task-section {
  min-width: 0;
  padding: 16px;
  border: 1px solid rgba(180, 83, 42, 0.18);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.78);
}

.task-section strong {
  display: block;
  color: #7f3b27;
  font-size: 16px;
  line-height: 1.45;
}

.task-section ul {
  margin: 10px 0 0;
  padding: 0;
  display: grid;
  gap: 8px;
  list-style: none;
}

.task-section li {
  position: relative;
  padding-left: 16px;
  color: #51362d;
  line-height: 1.68;
}

.task-section li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-2);
}

.course-seven-task-flow {
  display: grid;
  gap: 16px;
  margin-top: 18px;
}

.task-major-section {
  padding: 20px;
}

.task-major-head {
  display: grid;
  gap: 8px;
}

.task-major-head span {
  width: fit-content;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(180, 83, 42, 0.12);
  color: #7f3b27;
  font-size: 12px;
  font-weight: 900;
}

.task-major-head strong {
  font-size: 20px;
}

.task-major-head p {
  max-width: 780px;
  margin: 0;
  color: #6f6258;
  line-height: 1.78;
}

.task-capture-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.task-capture-list section {
  padding: 16px;
  border: 1px solid rgba(180, 83, 42, 0.14);
  border-radius: 8px;
  background: #fffdf8;
}

.task-capture-list strong {
  color: #7f3b27;
  font-size: 17px;
}

.task-footer-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.case-card dl {
  margin: 16px 0 0;
  display: grid;
  gap: 10px;
}

.case-card dt {
  color: var(--accent);
  font-weight: 850;
}

.case-card dd {
  margin: 0;
  color: var(--muted);
}

.transcript-card pre {
  max-height: 620px;
  overflow: auto;
  padding: 18px;
  border-radius: 8px;
  background: #fff;
}

.share-manuscript {
  display: grid;
  gap: 18px;
}

.share-cover {
  padding: 24px;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), #203f4a);
}

.share-cover span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  font-weight: 850;
}

.share-cover h3 {
  max-width: 820px;
  margin: 8px 0 0;
  font-size: clamp(26px, 4vw, 42px);
  line-height: 1.14;
}

.share-cover p {
  max-width: 680px;
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.75;
}

.share-outline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.share-outline a {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.share-sections {
  display: grid;
  gap: 16px;
}

.share-section {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 16px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.share-section-marker {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: var(--accent);
  font-weight: 900;
}

.share-section h4 {
  margin: 4px 0 12px;
  font-size: 24px;
  line-height: 1.28;
}

.share-section p {
  margin: 10px 0 0;
  line-height: 1.88;
}

.share-speaker {
  padding-left: 14px;
  border-left: 4px solid var(--accent);
  color: var(--ink);
  font-weight: 650;
}

.share-note,
.share-step {
  padding: 14px 16px;
  border-radius: 8px;
}

.share-note {
  background: #fff8f1;
  color: var(--accent-2);
  font-weight: 750;
}

.share-step {
  background: var(--soft);
  color: var(--accent);
  font-weight: 850;
}

.share-list {
  margin: 10px 0 0;
  padding-left: 22px;
}

.share-list li {
  margin-top: 7px;
  line-height: 1.76;
}

.share-section code {
  padding: 2px 5px;
  border-radius: 5px;
  background: var(--soft);
  color: var(--accent);
}

.related-course-card {
  padding: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.related-course-card span,
.materials-hero span,
.section-title-row span,
.material-card span,
.material-card small {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.related-course-card strong {
  display: block;
  margin-top: 6px;
  font-size: 20px;
  line-height: 1.4;
}

.related-course-card p {
  max-width: 760px;
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.materials-page {
  display: grid;
  gap: 18px;
}

.materials-hero {
  padding: 30px;
  border-radius: 8px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(22, 88, 79, 0.94), rgba(23, 33, 29, 0.96)),
    var(--accent);
}

.materials-hero span {
  color: rgba(255, 255, 255, 0.72);
}

.materials-hero h2 {
  max-width: 820px;
  margin: 8px 0 0;
  font-family: var(--display-font);
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.16;
}

.materials-hero p {
  max-width: 760px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.78;
}

.material-section {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.88);
  box-shadow: var(--shadow);
}

.section-title-row {
  margin-bottom: 16px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
}

.section-title-row h3 {
  margin: 0;
  font-family: var(--display-font);
  font-size: 24px;
}

.material-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.material-card {
  min-height: 190px;
  padding: 20px;
  display: grid;
  align-content: start;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.material-card.accent {
  border-color: rgba(22, 88, 79, 0.28);
  background: #f7fbf8;
}

.material-card.warm {
  border-color: rgba(192, 90, 55, 0.28);
  background: #fff8f1;
}

.material-card h4 {
  margin: 0;
  font-size: 18px;
  line-height: 1.45;
}

.material-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.72;
}

.material-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-self: end;
}

.material-actions a,
.material-actions button {
  min-height: 36px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(22, 88, 79, 0.24);
  border-radius: 7px;
  background: #fff;
  color: var(--accent);
  font-size: 14px;
  font-weight: 850;
  text-decoration: none;
}

.material-note {
  padding: 20px;
  display: grid;
  gap: 8px;
}

.material-note span {
  color: var(--muted);
  line-height: 1.7;
}

@media (max-width: 1080px) {
  .auth-page,
  .overview-band,
  .rhythm-head,
  .workspace-grid,
  .lesson-hero,
  .lesson-compass,
  .lesson-reading-shell {
    grid-template-columns: 1fr;
  }

  .lesson-module-nav {
    position: relative;
    top: 0;
  }

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

  .week-track {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .auth-visual {
    min-height: 58vh;
  }

  .auth-panel {
    min-height: auto;
  }

  .side-panel {
    position: relative;
    top: 0;
    max-height: none;
  }

  .topbar {
    grid-template-columns: 1fr;
    padding: 14px 20px;
  }

  .main-nav,
  .student-chip {
    justify-self: stretch;
  }

  .student-chip {
    justify-content: space-between;
  }
}

@media (max-width: 760px) {
  main {
    width: min(100% - 24px, 1440px);
  }

  .auth-visual,
  .auth-panel {
    padding: 28px;
  }

  .cover-media,
  .visual-grid,
  .week-track,
  .role-grid,
  .case-grid,
  .task-section-grid,
  .lesson-lead-card ul,
  .module-card-grid,
  .module-task-panel,
  .lesson-module-nav nav {
    grid-template-columns: 1fr;
  }

  .source-card {
    display: grid;
    grid-template-columns: 1fr;
  }

  .source-actions {
    justify-content: flex-start;
  }

  .related-course-card {
    display: grid;
  }

  .lesson-section,
  .share-section {
    grid-template-columns: 1fr;
  }

  .lesson-section-marker,
  .share-section-marker {
    width: 38px;
    height: 38px;
  }

  .lesson-body-cover,
  .lesson-section,
  .lesson-lead-card {
    padding: 20px;
  }

  .lesson-module {
    padding: 24px 0;
  }

  .module-steps li {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .cover-copy h1 {
    font-size: 38px;
  }

  .overview-band {
    padding-top: 26px;
  }

  .overview-band h1,
  .lesson-hero h2 {
    font-size: 30px;
  }

  .main-nav {
    overflow-x: auto;
  }

  .topbar-trail {
    flex-wrap: wrap;
    white-space: normal;
    overflow: visible;
    line-height: 1.6;
  }

  .topbar-trail span {
    padding-left: 0;
  }

  .topbar-trail span::before {
    content: "";
  }

  .topbar-trail .current {
    flex-basis: 100%;
  }

  .topbar-tools {
    justify-self: stretch;
    flex-wrap: wrap;
  }

  .tool-chip,
  .progress-pill {
    flex: 1 1 160px;
    justify-content: center;
  }

  .main-nav button {
    white-space: nowrap;
  }

  .media-switch {
    display: flex;
    overflow-x: auto;
  }

  .comparison-table {
    display: block;
    overflow-x: auto;
  }

  .comparison-table > div {
    min-width: 240px;
  }

  .material-grid {
    grid-template-columns: 1fr;
  }
}

.course-shell .topbar,
.legacy-shell .topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 72px;
  padding: 0 22px;
  display: grid;
  grid-template-columns: minmax(240px, 360px) minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  background: rgba(255, 252, 246, 0.86);
  border-bottom: 1px solid rgba(227, 215, 196, 0.88);
  backdrop-filter: blur(18px);
}

.topbar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-brand strong {
  display: block;
  font-size: 15px;
}

.topbar-brand span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.topbar-trail {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  overflow: hidden;
  white-space: nowrap;
}

.topbar-trail span {
  position: relative;
  padding-left: 18px;
}

.topbar-trail span::before {
  content: ">";
  position: absolute;
  left: 0;
  color: rgba(109, 96, 84, 0.55);
}

.topbar-trail span:first-child {
  padding-left: 0;
}

.topbar-trail span:first-child::before {
  content: "";
}

.topbar-trail .current {
  color: var(--ink);
  font-weight: 800;
}

.topbar-tools {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-self: end;
}

.tool-chip,
.progress-pill,
.avatar-chip {
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.96);
}

.tool-chip {
  min-height: 38px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
}

.tool-chip span {
  font-size: 16px;
  line-height: 1;
}

.tool-chip strong {
  font-size: 13px;
  font-weight: 750;
}

.progress-pill {
  min-width: 160px;
  padding: 8px 12px;
  display: grid;
  gap: 6px;
}

.progress-pill span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.progress-pill i,
.sidebar-progress .progress-meter {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5ddd1;
}

.progress-pill b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), #3e8b88);
}

.avatar-chip {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: #275f61;
  color: #fff;
  font-weight: 800;
}

.course-layout {
  width: min(1540px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 18px 0 40px;
}

.course-week-overview {
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.9);
  box-shadow: var(--shadow);
}

.week-overview-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.week-overview-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.week-overview-head strong {
  font-family: var(--display-font);
  font-size: 21px;
}

.week-overview-track {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(7, minmax(132px, 1fr));
  gap: 10px;
}

.week-overview-card {
  position: relative;
  min-height: 116px;
  padding: 14px;
  display: grid;
  align-content: space-between;
  gap: 8px;
  text-align: left;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: #fffdf8;
  color: var(--ink);
  overflow: hidden;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.week-overview-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: var(--accent);
}

.week-overview-card.is-locked {
  background: #f4f0e9;
}

.week-overview-card.is-locked::before {
  background: #b6aa99;
}

.week-overview-card span,
.week-overview-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.week-overview-card strong {
  font-size: 14px;
  line-height: 1.45;
}

.week-overview-card.selected {
  border-color: rgba(43, 101, 103, 0.55);
  box-shadow: 0 0 0 3px rgba(43, 101, 103, 0.12);
}

.week-overview-card:hover {
  transform: translateY(-1px);
  border-color: rgba(43, 101, 103, 0.35);
}

.week-course-expander {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(227, 215, 196, 0.95);
}

.week-course-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: baseline;
}

.week-course-head span,
.week-course-head small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.week-course-head strong {
  font-size: 16px;
  line-height: 1.45;
}

.week-course-list {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.week-course-button {
  min-width: 0;
  min-height: 112px;
  padding: 13px;
  display: grid;
  align-content: space-between;
  gap: 8px;
  text-align: left;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
}

.week-course-button span,
.week-course-button small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.week-course-button strong {
  font-size: 14px;
  line-height: 1.45;
}

.week-course-button.selected {
  border-color: var(--accent);
  background: #f6fbf8;
  box-shadow: 0 0 0 3px rgba(43, 101, 103, 0.11);
}

.week-course-button.is-locked {
  color: var(--locked);
  background: #f2eee7;
}

.course-page {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
}

.course-sidebar,
.course-rail {
  position: sticky;
  top: 92px;
  display: grid;
  gap: 16px;
  max-height: calc(100vh - 112px);
  overflow: auto;
  scrollbar-width: thin;
}

.course-sidebar {
  padding-right: 2px;
}

.course-rail {
  padding-left: 2px;
}

.sidebar-card,
.sidebar-panel,
.course-detail,
.lesson-reading-shell,
.media-panel,
.task-card,
.case-section,
.source-card,
.comparison-card,
.role-section,
.route-card,
.visual-grid,
.welcome-card,
.loading-card,
.error-card {
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.92);
  box-shadow: var(--shadow);
}

.sidebar-card,
.sidebar-panel {
  padding: 18px;
}

.overview-card {
  display: grid;
  gap: 14px;
}

.sidebar-kicker,
.rail-title span,
.module-strip-head span,
.lesson-meta,
.task-card span,
.module-head > span,
.module-takeaways > span {
  color: var(--accent-2);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.overview-card h2 {
  margin: 0;
  font-family: var(--display-font);
  font-size: 24px;
  line-height: 1.28;
}

.overview-card p,
.sidebar-note p,
.rail-title strong + p,
.resource-list small,
.course-map small {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  font-size: 14px;
}

.sidebar-progress {
  display: grid;
  gap: 10px;
}

.sidebar-progress strong {
  font-size: 14px;
}

.sidebar-panel .panel-head h2,
.sidebar-card .panel-head h2 {
  margin: 0;
  font-size: 18px;
}

.sidebar-panel .panel-head p,
.sidebar-card .panel-head p {
  margin: 6px 0 14px;
  color: var(--muted);
  line-height: 1.6;
  font-size: 13px;
}

.current-course-card {
  padding: 14px;
  display: grid;
  gap: 9px;
  border: 1px solid rgba(43, 101, 103, 0.2);
  border-radius: 8px;
  background: linear-gradient(180deg, #f7fbfa, #fffdf8);
}

.current-course-card span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

.current-course-card strong {
  font-size: 15px;
  line-height: 1.5;
}

.current-course-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.ghost-button,
.primary-action {
  border: 1px solid rgba(43, 101, 103, 0.18);
  border-radius: 8px;
  background: #275f61;
  color: #fff;
  font-weight: 750;
}

.ghost-button {
  min-height: 42px;
  padding: 0 14px;
  width: 100%;
  background: #fff;
  color: var(--accent);
}

.course-detail {
  padding: 22px 22px 26px;
  display: grid;
  gap: 18px;
}

.course-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 150px;
  gap: 18px;
  align-items: start;
}

.course-hero h1 {
  margin: 10px 0 0;
  font-family: var(--display-font);
  font-size: clamp(30px, 3.6vw, 48px);
  line-height: 1.12;
}

.course-hero p {
  margin: 12px 0 0;
  max-width: 880px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.lesson-stat {
  padding: 16px;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: #fffaf2;
}

.lesson-stat strong {
  margin-top: 8px;
  display: block;
  font-size: 24px;
  line-height: 1.2;
}

.lesson-compass {
  padding: 18px;
  display: block;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: #fffdf8;
}

.module-strip-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.module-strip-head strong {
  font-size: 18px;
  line-height: 1.3;
}

.module-strip {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.lesson-compass .module-strip-card {
  min-width: 0;
  min-height: 112px;
  padding: 14px;
  display: grid;
  gap: 8px;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: #fff;
}

.lesson-compass .module-strip-card span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

.lesson-compass .module-strip-card strong {
  font-size: 15px;
  line-height: 1.4;
}

.lesson-compass .module-strip-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.lesson-compass .module-strip-card.task {
  border-color: rgba(43, 101, 103, 0.22);
  background: linear-gradient(180deg, #f7fbfa, #fff);
}

.lesson-compass .module-strip-card.warm {
  border-color: rgba(141, 106, 63, 0.24);
  background: linear-gradient(180deg, #fff9f2, #fff);
}

.lesson-reading-shell {
  padding: 18px;
  grid-template-columns: minmax(220px, 264px) minmax(0, 1fr);
  gap: 22px;
}

.lesson-module-nav {
  position: sticky;
  top: 96px;
  align-self: start;
  padding: 16px;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: #fffdf8;
  box-shadow: none;
}

.lesson-module-nav strong {
  font-size: 21px;
}

.lesson-module-list {
  gap: 12px;
}

.lesson-lead-card {
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(43, 101, 103, 0.96), rgba(45, 86, 78, 0.96));
}

.lesson-lead-card h3 {
  font-size: clamp(24px, 3vw, 40px);
}

.media-switch {
  display: inline-flex;
  gap: 0;
  width: fit-content;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.media-switch button {
  min-height: 44px;
  padding: 0 20px;
  border: 0;
  border-right: 1px solid rgba(227, 215, 196, 0.95);
  background: transparent;
  color: var(--muted);
  font-weight: 750;
}

.media-switch button:last-child {
  border-right: 0;
}

.media-switch button.active {
  background: #f4faf7;
  color: var(--accent);
}

.media-panel,
.route-card,
.visual-grid,
.task-card,
.case-section,
.source-card,
.comparison-card,
.role-section {
  padding: 18px;
}

.media-panel h3,
.route-card h3,
.case-section h3,
.role-section h3,
.comparison-card h3 {
  margin: 0 0 10px;
  font-size: 18px;
}

.media-panel p,
.route-card li,
.task-card p,
.task-card li,
.case-card p,
.source-card p {
  color: var(--muted);
  line-height: 1.78;
}

.media-panel pre,
.module-prompt-card pre {
  border-radius: 8px;
}

.course-rail .course-map {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  list-style: none;
}

.course-map li {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 10px 0;
}

.course-map li span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 999px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.course-map li.current span {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.course-map strong {
  display: block;
  font-size: 14px;
  line-height: 1.45;
}

.task-rail .task-checklist {
  margin: 12px 0 14px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.task-rail .task-checklist li {
  padding-left: 18px;
  position: relative;
  color: var(--ink);
  line-height: 1.5;
}

.task-rail .task-checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--accent);
}

.resource-list {
  display: grid;
  gap: 10px;
}

.resource-list a {
  padding: 10px 12px;
  display: grid;
  gap: 3px;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  text-decoration: none;
}

.resource-list a strong {
  font-size: 13px;
  line-height: 1.45;
}

.resource-list small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-card,
.source-card,
.case-section,
.comparison-card,
.role-section {
  border-radius: 8px;
}

.task-card {
  background: #fffaf3;
}

.transcript-panel > h3 {
  margin-bottom: 14px;
  font-family: var(--display-font);
  font-size: 24px;
}

.task-card {
  display: grid;
  gap: 14px;
}

.task-card-head {
  display: grid;
  gap: 6px;
}

.task-card-head h3 {
  margin: 0;
  font-family: var(--display-font);
  font-size: 24px;
  line-height: 1.35;
}

.task-detail-list {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  list-style: none;
}

.task-detail-list li {
  position: relative;
  padding: 12px 14px 12px 36px;
  border: 1px solid rgba(227, 215, 196, 0.95);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  line-height: 1.72;
}

.task-detail-list li::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 22px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.course-shell .overview-band,
.course-shell .rhythm-band {
  display: none;
}

@media (max-width: 1280px) {
  .week-overview-track {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .week-course-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .course-page {
    grid-template-columns: minmax(220px, 260px) minmax(0, 1fr);
  }

  .course-rail {
    grid-column: 1 / -1;
    position: static;
    max-height: none;
  }

  .module-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 960px) {
  .course-shell .topbar,
  .legacy-shell .topbar {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 14px 16px;
  }

  .topbar-tools {
    justify-self: start;
    flex-wrap: wrap;
  }

  .course-layout {
    width: min(100vw - 16px, 100%);
    padding-top: 12px;
  }

  .course-page,
  .week-overview-track,
  .week-course-list {
    grid-template-columns: 1fr;
  }

  .course-sidebar,
  .course-rail {
    position: static;
    max-height: none;
  }

  .course-hero,
  .lesson-reading-shell,
  .source-card {
    grid-template-columns: 1fr;
  }

  .signal-card,
  .standard-grid,
  .source-grid,
  .flow-steps,
  .decision-ladder,
  .summary-grid,
  .prep-grid,
  .principle-grid,
  .inbox-grid,
  .movement-timeline,
  .inline-resource-grid,
  .embedded-list,
  .embedded-para,
  .task-footer-grid,
  .question-list {
    grid-template-columns: 1fr;
  }

  .module-strip-head {
    flex-direction: column;
    align-items: start;
  }
}

@media (max-width: 640px) {
  .module-strip {
    grid-template-columns: 1fr;
  }

  .progress-pill {
    min-width: 0;
    width: 100%;
  }

  .topbar-tools {
    width: 100%;
  }

  .tool-chip {
    flex: 1 1 auto;
    justify-content: center;
  }

  .course-detail,
  .lesson-compass,
  .lesson-reading-shell,
  .media-panel,
  .task-card,
  .case-section,
  .source-card,
  .comparison-card,
  .role-section,
  .sidebar-card,
  .sidebar-panel {
    padding: 14px;
  }

  .curated-section {
    padding: 18px;
  }

  .curated-outline {
    grid-template-columns: 1fr;
  }
}

/* PRD V0.3 production learning workspace */
:root {
  --bg: #f2f4f1;
  --paper: #ffffff;
  --ink: #17201c;
  --muted: #5f6b65;
  --line: #d8dfda;
  --accent: #0f5b54;
  --accent-2: #a65f2b;
  --soft: #edf5f2;
  --locked: #7b837f;
  --shadow: 0 10px 28px rgba(28, 48, 40, 0.07);
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  background: var(--bg) !important;
  overflow-x: clip;
}

button,
a,
input {
  -webkit-tap-highlight-color: transparent;
}

button:active,
.resource-list a:active,
.material-card a:active {
  transform: translateY(1px);
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 3px solid rgba(15, 91, 84, 0.24);
  outline-offset: 2px;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-family: var(--body-font);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0;
}

.auth-page {
  min-height: 100svh;
  padding: 24px;
  background: #f5f6f4;
}

.auth-panel {
  width: min(100%, 420px);
  padding: 42px;
  gap: 30px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.auth-brand .brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 8px;
  font-size: 15px;
}

.auth-panel h1 {
  font-size: 30px;
}

.auth-panel p {
  color: var(--muted);
}

.login-form {
  display: grid;
  gap: 10px;
}

.login-form label {
  color: var(--ink);
  font-size: 14px;
  font-weight: 750;
}

.login-form input {
  min-height: 50px;
  border: 1px solid #aeb9b3;
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
}

.login-form input::placeholder {
  color: #707b75;
}

.login-form input[aria-invalid="true"] {
  border-color: #b43d32;
}

.login-form button {
  min-height: 50px;
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
}

.form-error {
  min-height: 22px;
  color: #a63229 !important;
  font-size: 13px;
}

.course-shell .topbar,
.library-shell .topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: 64px;
  padding: 0 20px;
  display: grid;
  grid-template-columns: minmax(236px, auto) auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(16px);
}

.topbar-brand {
  padding: 0;
  display: flex;
  align-items: center;
  gap: 11px;
  border: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.topbar-brand strong {
  font-size: 15px;
  white-space: nowrap;
}

.topbar-brand span {
  margin-top: 2px;
  font-size: 11px;
}

.primary-nav {
  height: 64px;
  display: flex;
  align-items: stretch;
}

.primary-nav button {
  position: relative;
  padding: 0 13px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  white-space: nowrap;
}

.primary-nav button::after {
  content: "";
  position: absolute;
  right: 13px;
  bottom: 0;
  left: 13px;
  height: 3px;
  background: transparent;
}

.primary-nav button.active {
  color: var(--accent);
}

.primary-nav button.active::after {
  background: var(--accent);
}

.topbar-trail {
  font-size: 12px;
}

.topbar-tools {
  gap: 10px;
}

.tool-chip,
.progress-pill,
.avatar-chip {
  border-color: var(--line);
  background: #fff;
}

.tool-chip {
  min-height: 36px;
  padding: 0 13px;
  border-radius: 6px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 750;
}

.progress-pill {
  min-width: 142px;
  padding: 6px 10px;
  border-radius: 6px;
}

.progress-pill i,
.sidebar-progress .progress-meter {
  background: #dfe5e1;
}

.progress-pill b,
.sidebar-progress .progress-meter i {
  background: var(--accent);
}

.account-control {
  position: relative;
}

.avatar-chip {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: var(--accent);
}

.account-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 70;
  width: 220px;
  padding: 16px;
  display: grid;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.account-menu strong {
  font-size: 14px;
}

.account-menu span {
  color: var(--muted);
  font-size: 12px;
}

.account-menu button {
  margin-top: 10px;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: #8b2f28;
  font-weight: 750;
}

.global-notice {
  position: sticky;
  top: 64px;
  z-index: 40;
  min-height: 44px;
  padding: 8px max(20px, calc((100vw - 1540px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid #e4c9a7;
  background: #fff7ea;
  color: #6d421d;
  font-size: 14px;
}

.global-notice button {
  border: 0;
  background: transparent;
  color: inherit;
  font-weight: 750;
}

.cohort-mode-notice {
  justify-content: center;
  text-align: center;
}

.cohort-mode-notice strong {
  margin-right: 6px;
  color: var(--bronze);
}

.course-layout {
  width: min(1540px, calc(100vw - 32px));
  padding: 14px 0 48px;
}

.course-week-overview {
  margin-bottom: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
}

.week-overview-head strong {
  font-family: var(--body-font);
  font-size: 15px;
}

.week-overview-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(150px, 1fr);
  grid-template-columns: none;
  gap: 8px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: thin;
  scroll-snap-type: x proximity;
}

.week-overview-card {
  min-width: 150px;
  min-height: 92px;
  padding: 12px;
  gap: 5px;
  border-color: var(--line);
  border-radius: 6px;
  background: #fff;
  scroll-snap-align: start;
}

.week-overview-card::before {
  display: none;
}

.week-overview-card.selected {
  border-color: var(--accent);
  background: var(--soft);
  box-shadow: inset 0 3px 0 var(--accent);
}

.week-overview-card.is-locked {
  background: #f4f5f3;
}

.week-overview-card strong {
  font-size: 13px;
  line-height: 1.4;
}

.week-course-expander {
  margin-top: 12px;
  padding-top: 12px;
}

.week-course-head {
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.week-course-list {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(250px, 1fr);
  grid-template-columns: none;
  gap: 8px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: thin;
  scroll-snap-type: x proximity;
}

.week-course-button {
  min-width: 250px;
  min-height: 90px;
  padding: 12px;
  gap: 6px;
  border-color: var(--line);
  border-radius: 6px;
  scroll-snap-align: start;
}

.week-course-button.selected {
  border-color: var(--accent);
  background: var(--soft);
  box-shadow: inset 3px 0 0 var(--accent);
}

.course-page {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr) 270px;
  grid-template-areas: "sidebar stage rail";
  gap: 16px;
  align-items: start;
}

.course-stage {
  grid-area: stage;
  min-width: 0;
}

.course-sidebar {
  grid-area: sidebar;
}

.course-rail {
  grid-area: rail;
}

.course-sidebar,
.course-rail {
  top: 78px;
  max-height: calc(100vh - 94px);
  gap: 12px;
}

.sidebar-card,
.sidebar-panel,
.course-detail,
.lesson-reading-shell,
.media-panel,
.task-card,
.case-section,
.source-card,
.comparison-card,
.role-section,
.route-card,
.visual-grid,
.welcome-card,
.loading-card,
.error-card {
  border-color: var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
}

.sidebar-card,
.sidebar-panel {
  padding: 16px;
}

.overview-card h2 {
  font-family: var(--body-font);
  font-size: 20px;
}

.sidebar-outline {
  display: grid;
  gap: 2px;
}

.sidebar-outline a {
  padding: 7px 8px;
  border-left: 2px solid transparent;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
  text-decoration: none;
}

.sidebar-outline a:hover,
.sidebar-outline a:focus-visible {
  border-left-color: var(--accent);
  background: var(--soft);
  color: var(--accent);
}

.sidebar-outline .level-2,
.sidebar-outline .level-3 {
  padding-left: 18px;
  font-size: 12px;
}

.ghost-button,
.primary-action {
  border-radius: 6px;
  background: var(--accent);
}

.ghost-button {
  background: #fff;
  border-color: var(--accent);
}

.course-detail {
  padding: 26px 30px 34px;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  min-width: 0;
}

.course-hero {
  grid-template-columns: minmax(0, 1fr) 126px;
  gap: 24px;
  padding-bottom: 6px;
  min-width: 0;
}

.course-hero-body,
.lesson-compass,
.media-switch,
#learningPanel,
.course-manuscript,
.lesson-sections,
.task-card {
  min-width: 0;
}

.course-hero h1 {
  max-width: 900px;
  font-size: clamp(32px, 3.1vw, 44px);
  line-height: 1.16;
}

.course-hero p {
  font-size: 16px;
  line-height: 1.75;
}

.lesson-stat {
  padding: 14px;
  border-color: var(--line);
  border-radius: 6px;
  background: #f7f3ec;
}

.lesson-stat strong {
  font-size: 20px;
}

.lesson-compass {
  padding: 16px 0;
  border: 1px solid var(--line);
  border-width: 1px 0;
  border-radius: 0;
  background: transparent;
}

.module-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  overflow: visible;
  gap: 8px;
  scrollbar-width: thin;
}

.lesson-compass .module-strip-card {
  height: 154px;
  padding: 12px;
  overflow: hidden;
  border-color: var(--line);
  border-radius: 6px;
  background: #fff;
}

.lesson-compass .module-strip-card p {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}

.lesson-compass button.module-strip-card {
  width: 100%;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.lesson-compass button.module-strip-card:hover,
.lesson-compass button.module-strip-card:focus-visible {
  border-color: var(--accent);
  background: #eef5f2;
  outline: none;
}

.lesson-compass .module-strip-card.task,
.lesson-compass .module-strip-card.warm {
  border-color: var(--line);
  background: #f8faf8;
}

.media-switch {
  border-color: #b8c5bf;
  border-radius: 6px;
}

.media-switch button {
  min-width: 92px;
  min-height: 42px;
  padding: 0 18px;
  border-right-color: #cbd4cf;
  white-space: nowrap;
  word-break: keep-all;
}

.media-switch button.active {
  background: var(--accent);
  color: #fff;
}

#learningPanel {
  min-width: 0;
}

.media-panel {
  padding: 0;
  border: 0;
  background: transparent;
}

.media-player-panel {
  padding: 16px;
  border: 1px solid var(--line);
  background: #f7f9f7;
}

.media-player-panel audio,
.media-player-panel video {
  display: block;
  width: 100%;
}

.course-manuscript {
  gap: 0;
}

.lesson-outline {
  display: none;
}

.lesson-sections,
.curated-sections {
  gap: 0;
}

.lesson-section,
.curated-section {
  scroll-margin-top: 86px;
}

.lesson-section {
  padding: 30px 0;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 16px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}

.lesson-section:first-child {
  padding-top: 8px;
}

.lesson-section-marker {
  color: var(--accent);
  font-size: 12px;
  font-weight: 850;
}

.lesson-section-body h2,
.lesson-section-body h3,
.lesson-section-body h4 {
  margin: 0 0 16px;
  color: var(--ink);
  font-family: var(--display-font);
  letter-spacing: 0;
}

.lesson-section-body h2 {
  font-size: 30px;
}

.lesson-section-body h3 {
  font-size: 25px;
}

.lesson-section-body h4 {
  font-size: 20px;
}

.lesson-text-block,
.lesson-paragraph-group p,
.curated-section p,
.curated-section li {
  color: #3f4944;
  font-size: 16px;
  line-height: 1.9;
}

.lesson-prompt-block {
  margin: 22px 0;
  border: 1px solid #abc1b8;
  border-radius: 6px;
  background: #f3f8f6;
}

.lesson-prompt-block pre {
  max-width: 100%;
  overflow-x: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: #183e37;
}

.prompt-block-head button {
  min-width: 92px;
  white-space: nowrap;
}

.course-seven-manuscript .curated-outline {
  display: none;
}

.curated-section {
  padding: 34px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}

.curated-section h3 {
  font-size: 28px;
}

.standard-grid,
.source-grid,
.summary-grid,
.prep-grid,
.principle-grid,
.inbox-grid,
.movement-timeline,
.flow-steps,
.decision-ladder,
.inline-resource-grid,
.embedded-list,
.embedded-para {
  gap: 10px;
}

.standard-grid article,
.source-grid article,
.summary-grid article,
.prep-grid article,
.principle-grid article,
.inbox-grid article,
.movement-timeline article,
.flow-steps article,
.decision-ladder article,
.inline-resource-grid a,
.embedded-list article {
  border-color: var(--line);
  border-radius: 6px;
  background: #f8faf8;
}

.task-card {
  scroll-margin-top: 86px;
  padding: 26px;
  gap: 18px;
  border-color: #e2cdb5;
  background: #fffaf4;
}

#courseTask {
  scroll-margin-top: 86px;
}

.task-flow-list,
.course-seven-task-flow {
  display: grid;
  gap: 12px;
}

.task-section-grid {
  grid-template-columns: 1fr;
}

.task-section {
  padding: 18px;
  border-color: #e4d6c7;
  border-radius: 6px;
  background: #fff;
}

.task-section > strong {
  display: block;
  margin-bottom: 10px;
  color: #713f22;
}

.task-section ul {
  margin: 0;
}

.task-capture-list {
  grid-template-columns: 1fr;
}

.task-footer-grid {
  grid-template-columns: 1fr;
}

.rail-title {
  display: grid;
  gap: 4px;
}

.rail-title strong {
  font-size: 15px;
}

.resource-list a {
  padding: 12px;
  gap: 5px;
  border-color: var(--line);
  border-radius: 6px;
  background: #fff;
}

.resource-list a:hover {
  border-color: #9bb7ad;
  background: var(--soft);
}

.resource-type {
  color: var(--accent-2);
  font-size: 11px;
  font-weight: 800;
}

.resource-list small {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  font-size: 12px;
  line-height: 1.55;
}

.resource-list em {
  color: var(--accent);
  font-size: 12px;
  font-style: normal;
  font-weight: 750;
}

.locked-course-state {
  min-height: 520px;
  padding: 60px;
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.locked-course-state > span {
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 800;
}

.locked-course-state h1 {
  margin: 0;
  max-width: 800px;
  font-family: var(--display-font);
  font-size: 40px;
  line-height: 1.25;
}

.locked-course-state p {
  margin: 0;
  max-width: 720px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.75;
}

.locked-date {
  padding: 14px 18px;
  display: grid;
  gap: 4px;
  border-left: 3px solid var(--accent-2);
  background: #fff6e9;
}

.locked-date strong {
  font-size: 18px;
}

.locked-date small {
  color: var(--muted);
}

.library-layout {
  width: min(1240px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 24px 0 48px;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  grid-template-areas: "sidebar stage";
  gap: 18px;
  align-items: start;
}

.library-sidebar {
  grid-area: sidebar;
  position: sticky;
  top: 82px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.library-stage {
  grid-area: stage;
  min-width: 0;
}

.library-section-nav {
  display: grid;
  gap: 4px;
}

.library-section-nav a {
  padding: 10px;
  border-radius: 6px;
  color: var(--ink);
  text-decoration: none;
}

.library-section-nav a:hover {
  background: var(--soft);
  color: var(--accent);
}

.materials-page,
.lesson-page {
  display: grid;
  gap: 18px;
}

.materials-hero,
.material-section,
.lesson-page > section,
.lesson-page > div {
  border-color: var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
}

.materials-hero {
  padding: 28px;
  color: var(--ink);
  background: #fff;
}

.materials-hero span {
  color: var(--accent);
}

.materials-hero h2 {
  max-width: 760px;
  margin-top: 6px;
  color: var(--ink);
  font-size: 30px;
  line-height: 1.3;
}

.materials-hero p {
  max-width: 720px;
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.7;
}

.material-section {
  scroll-margin-top: 82px;
}

.search-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  padding: 72px 20px 20px;
  display: grid;
  place-items: start center;
  background: rgba(14, 24, 20, 0.56);
}

.search-dialog {
  width: min(720px, 100%);
  max-height: calc(100vh - 100px);
  padding: 22px;
  display: grid;
  gap: 18px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(14, 24, 20, 0.24);
}

.search-dialog-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 20px;
}

.search-dialog-head span {
  color: var(--accent-2);
  font-size: 12px;
  font-weight: 800;
}

.search-dialog-head h2 {
  margin: 4px 0 0;
  font-family: var(--display-font);
  font-size: 26px;
}

.search-dialog-head button {
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
}

.search-input-wrap {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 750;
}

.search-input-wrap input {
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid #aeb9b3;
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
}

.search-results {
  display: grid;
  gap: 6px;
}

.search-result {
  padding: 12px 14px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  text-align: left;
}

.search-result span {
  color: var(--muted);
  font-size: 11px;
}

.search-result strong {
  grid-column: 1;
  font-size: 14px;
}

.search-result small {
  grid-row: 1 / span 2;
  grid-column: 2;
  align-self: center;
  color: var(--accent);
  font-size: 12px;
}

@media (max-width: 1280px) {
  .course-shell .topbar,
  .library-shell .topbar {
    grid-template-columns: minmax(220px, auto) auto minmax(0, 1fr) auto;
    gap: 14px;
  }

  .topbar-trail {
    display: none;
  }

  .course-page {
    grid-template-columns: 220px minmax(0, 1fr) 250px;
    grid-template-areas: "sidebar stage rail";
  }

  .course-rail {
    grid-column: auto;
    position: sticky;
    max-height: calc(100vh - 94px);
  }
}

@media (max-width: 1100px) {
  .course-page {
    grid-template-columns: minmax(0, 1fr) 260px;
    grid-template-areas: "stage rail";
  }

  .course-sidebar {
    display: none;
  }
}

@media (max-width: 960px) {
  html {
    scroll-padding-top: 118px;
  }

  .course-shell .topbar,
  .library-shell .topbar {
    min-height: 104px;
    padding: 8px 12px 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand tools"
      "nav nav";
    gap: 6px 10px;
  }

  .topbar-brand {
    grid-area: brand;
    min-width: 0;
  }

  .primary-nav {
    grid-area: nav;
    width: 100%;
    height: 44px;
  }

  .primary-nav button {
    flex: 1;
    padding: 0 8px;
  }

  .topbar-tools {
    grid-area: tools;
    justify-self: end;
    flex-wrap: nowrap;
  }

  .progress-pill,
  .topbar-trail {
    display: none;
  }

  .global-notice {
    top: 104px;
    padding: 8px 12px;
  }

  .course-layout {
    width: 100%;
    padding: 8px 0 28px;
  }

  .course-week-overview {
    margin: 0 8px 8px;
    padding: 12px;
  }

  .week-overview-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 154px;
    grid-template-columns: none;
    overflow-x: auto;
  }

  .week-course-head {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .week-course-head small {
    grid-column: 1 / -1;
  }

  .week-course-list {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(250px, 82vw);
    grid-template-columns: none;
    overflow-x: auto;
  }

  .course-page {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .course-stage {
    order: 1;
    width: 100%;
  }

  .course-sidebar {
    order: 2;
    display: grid;
    width: calc(100% - 16px);
    margin: 0 8px;
  }

  .course-rail {
    order: 3;
    position: static;
    width: calc(100% - 16px);
    max-height: none;
    margin: 0 8px;
  }

  .course-outline-panel {
    display: none;
  }

  .course-detail {
    margin: 0 8px;
    padding: 22px;
  }

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

  .lesson-stat {
    width: fit-content;
  }

  .module-strip {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 160px;
    grid-template-columns: none;
    overflow-x: auto;
  }

  .lesson-outline,
  .course-seven-manuscript .curated-outline {
    padding: 12px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #f8faf8;
  }

  .lesson-outline a {
    border: 0;
    background: transparent;
  }

  .lesson-section,
  .curated-section,
  #courseTask {
    scroll-margin-top: 122px;
  }

  .library-layout {
    width: 100%;
    padding: 8px;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-areas:
      "stage"
      "sidebar";
  }

  .library-sidebar {
    position: static;
  }

  .search-overlay {
    padding: 16px;
    place-items: center;
  }

  .search-dialog {
    max-height: calc(100svh - 32px);
  }
}

@media (max-width: 640px) {
  .topbar-brand .brand-mark {
    width: 34px;
    height: 34px;
    font-size: 11px;
  }

  .topbar-brand strong {
    max-width: 180px;
    overflow: hidden;
    font-size: 13px;
    text-overflow: ellipsis;
  }

  .topbar-brand span {
    display: none;
  }

  .tool-chip {
    min-height: 34px;
    padding: 0 10px;
  }

  .avatar-chip {
    width: 34px;
    height: 34px;
  }

  .week-overview-head {
    align-items: center;
  }

  .week-overview-head span {
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .course-detail {
    padding: 18px;
  }

  .course-hero h1 {
    font-size: 30px;
    line-height: 1.22;
  }

  .course-hero p {
    font-size: 15px;
  }

  .module-strip-head strong {
    font-size: 16px;
  }

  .media-switch {
    width: 100%;
  }

  .media-switch button {
    min-width: 0;
    flex: 1;
    padding: 0 12px;
    white-space: nowrap;
  }

  .lesson-section {
    grid-template-columns: 1fr;
    padding: 26px 0;
  }

  .lesson-section-marker {
    display: none;
  }

  .lesson-section-body h2 {
    font-size: 26px;
  }

  .lesson-section-body h3,
  .curated-section h3 {
    font-size: 23px;
  }

  .lesson-section-body h4 {
    font-size: 19px;
  }

  .lesson-text-block,
  .lesson-paragraph-group p,
  .curated-section p,
  .curated-section li {
    font-size: 15px;
    line-height: 1.85;
  }

  .task-card {
    padding: 18px;
  }

  .task-card-head h3 {
    font-size: 22px;
  }

  .locked-course-state {
    min-height: 430px;
    margin: 0 8px;
    padding: 32px 22px;
  }

  .locked-course-state h1 {
    font-size: 29px;
  }

  .search-dialog {
    padding: 16px;
  }

  .search-dialog-head h2 {
    font-size: 22px;
  }

  .search-result {
    grid-template-columns: 1fr;
  }

  .search-result small {
    grid-row: auto;
    grid-column: auto;
  }

  .lesson-table-wrap,
  .module-table-wrap,
  .comparison-table {
    max-width: 100%;
    overflow-x: auto;
  }
}

/* The document already reserves space for the sticky header. Keep anchors from
   adding the same offset a second time. */
.lesson-section,
.curated-section,
#courseTask {
  scroll-margin-top: 12px;
}

/* 2026-07-13: immersive editorial learning experience */
:root {
  --canvas: #f8f7f3;
  --surface: #ffffff;
  --ink-strong: #171914;
  --ink-soft: #545a52;
  --rule: #dfddd5;
  --rule-strong: #c9c6bb;
  --forest: #155f56;
  --forest-soft: #eaf2ef;
  --bronze: #9a6127;
  --bronze-soft: #f5eee4;
  --reading-width: 760px;
  --shell-width: 1380px;
}

html {
  background: var(--canvas);
  scroll-behavior: smooth;
}

body {
  overflow-x: hidden;
  background: var(--canvas);
  color: var(--ink-strong);
  letter-spacing: 0;
}

.ui-icon {
  width: 18px;
  height: 18px;
  display: block;
  flex: 0 0 auto;
}

.app-shell.course-shell {
  min-height: 100vh;
  background: var(--canvas);
}

.course-shell .topbar {
  min-height: 72px;
  padding: 0 28px;
  display: grid;
  grid-template-columns: auto minmax(320px, 1fr) auto;
  align-items: center;
  gap: 44px;
  position: sticky;
  top: 0;
  z-index: 70;
  border-bottom: 1px solid var(--rule);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: none;
  backdrop-filter: blur(14px);
}

.course-shell .topbar-brand {
  min-width: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 0;
  background: transparent;
  color: var(--ink-strong);
  text-align: left;
}

.course-shell .topbar-brand .brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 6px;
  background: var(--forest);
  font-size: 12px;
  box-shadow: none;
}

.course-shell .topbar-brand strong {
  display: block;
  font-family: var(--display-font);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.course-shell .primary-nav {
  height: 72px;
  display: flex;
  align-items: stretch;
  gap: 36px;
}

.course-shell .primary-nav button {
  min-width: 0;
  padding: 2px 0 0;
  position: relative;
  border: 0;
  background: transparent;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0;
}

.course-shell .primary-nav button::after {
  width: 0;
  height: 2px;
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  margin: auto;
  background: var(--forest);
  content: "";
  transition: width 160ms ease;
}

.course-shell .primary-nav button:hover,
.course-shell .primary-nav button.active {
  color: var(--forest);
}

.course-shell .primary-nav button.active::after {
  width: 100%;
}

.course-shell .topbar-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
}

.course-shell .tool-chip {
  min-height: 38px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--rule);
  border-radius: 5px;
  background: #fff;
  color: var(--ink-strong);
  font-size: 13px;
  font-weight: 600;
}

.course-shell .tool-chip:hover {
  border-color: var(--forest);
  color: var(--forest);
}

.course-shell .progress-pill {
  width: 178px;
  padding: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 12px;
  border: 0;
  background: transparent;
  color: var(--ink-soft);
  font-size: 13px;
}

.course-shell .progress-pill i {
  height: 4px;
  overflow: hidden;
  border-radius: 2px;
  background: #e7e8e3;
}

.course-shell .progress-pill b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--forest);
}

.course-shell .avatar-chip {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: var(--forest);
  color: #fff;
  font-weight: 700;
}

.course-shell .account-menu {
  top: 48px;
  right: 0;
  border: 1px solid var(--rule);
  border-radius: 6px;
  box-shadow: 0 18px 50px rgba(31, 35, 29, 0.12);
}

.course-layout {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0 0 120px;
}

.course-week-overview {
  width: 100%;
  margin: 0;
  padding: 0 24px;
  border: 0;
  border-bottom: 1px solid var(--rule);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: none;
}

.week-overview-track {
  width: min(100%, var(--shell-width));
  min-height: 142px;
  margin: 0 auto;
  padding: 30px 0 24px;
  display: grid;
  grid-template-columns: repeat(7, minmax(116px, 1fr));
  position: relative;
  overflow-x: auto;
  scrollbar-width: thin;
}

.week-overview-track::before {
  height: 1px;
  position: absolute;
  top: 52px;
  right: 7%;
  left: 7%;
  background: var(--rule-strong);
  content: "";
}

.week-overview-card {
  min-width: 116px;
  min-height: 88px;
  padding: 0 12px;
  display: grid;
  grid-template-rows: 14px auto auto;
  justify-items: center;
  align-content: start;
  gap: 7px;
  position: relative;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink-soft);
  text-align: center;
  box-shadow: none;
}

.week-overview-card > i {
  width: 12px;
  height: 12px;
  z-index: 1;
  border: 2px solid var(--rule-strong);
  border-radius: 50%;
  background: var(--surface);
}

.week-overview-card span {
  margin-top: 6px;
  font-family: var(--display-font);
  font-size: 15px;
  font-weight: 700;
}

.week-overview-card small {
  color: #787b73;
  font-size: 12px;
  white-space: nowrap;
}

.week-overview-card:hover,
.week-overview-card.selected {
  background: transparent;
  color: var(--forest);
}

.week-overview-card.selected > i {
  border-color: #fff;
  background: var(--forest);
  box-shadow: 0 0 0 2px var(--forest);
}

.week-overview-card.selected::after {
  width: 76px;
  height: 2px;
  position: absolute;
  bottom: -24px;
  background: var(--forest);
  content: "";
}

.week-course-expander {
  width: min(100%, var(--shell-width));
  margin: 0 auto;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  border-top: 1px solid var(--rule);
  background: transparent;
}

.week-course-head {
  min-width: 0;
  padding: 20px 26px 20px 6px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  background: transparent;
}

.week-course-head span {
  color: var(--ink-soft);
  font-size: 12px;
  white-space: nowrap;
}

.week-course-head strong {
  overflow: hidden;
  color: var(--ink-strong);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.week-course-list {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.week-course-button {
  min-width: 0;
  min-height: 68px;
  padding: 15px 22px;
  display: grid;
  align-content: center;
  gap: 5px;
  position: relative;
  border: 0;
  border-left: 1px solid var(--rule);
  border-radius: 0;
  background: transparent;
  color: var(--ink-soft);
  text-align: left;
  box-shadow: none;
}

.week-course-button span {
  color: #777b73;
  font-size: 11px;
  white-space: nowrap;
}

.week-course-button strong {
  overflow: hidden;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  text-overflow: ellipsis;
  white-space: normal;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.week-course-button:hover,
.week-course-button.selected {
  background: transparent;
  color: var(--forest);
}

.week-course-button.selected::after {
  height: 2px;
  position: absolute;
  right: 20px;
  bottom: 0;
  left: 20px;
  background: var(--forest);
  content: "";
}

.course-page {
  width: min(100%, 1320px);
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
  align-items: start;
  gap: 48px;
}

.course-sidebar {
  width: auto;
  margin: 0;
  position: sticky;
  top: 104px;
  z-index: 12;
}

.chapter-rail {
  padding-top: 48px;
  max-height: calc(100vh - 128px);
  overflow-y: auto;
  padding-right: 10px;
  scrollbar-width: thin;
  scrollbar-color: #c9cec8 transparent;
}

.chapter-rail-head {
  margin-bottom: 22px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink-strong);
  font-size: 13px;
  font-weight: 700;
}

.chapter-rail-head .ui-icon {
  width: 16px;
  height: 16px;
}

.sidebar-outline {
  display: grid;
  position: relative;
}

.sidebar-outline::before {
  width: 1px;
  position: absolute;
  top: 13px;
  bottom: 13px;
  left: 5px;
  background: var(--rule);
  content: "";
}

.sidebar-outline a {
  min-height: 0;
  padding: 10px 0 10px 24px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-content: center;
  position: relative;
  border: 0;
  background: transparent;
  color: #7b7e76;
  text-decoration: none;
}

.sidebar-outline a > i {
  width: 9px;
  height: 9px;
  position: absolute;
  top: 15px;
  left: 1px;
  z-index: 1;
  border: 1px solid #92958d;
  border-radius: 50%;
  background: var(--canvas);
}

.sidebar-outline a > span {
  color: var(--bronze);
  font-size: 11px;
}

.sidebar-outline a > strong {
  overflow: visible;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.55;
  overflow-wrap: anywhere;
  text-overflow: clip;
  white-space: normal;
}

.sidebar-outline a:hover,
.sidebar-outline a.is-active {
  color: var(--forest);
}

.sidebar-outline a:hover > i,
.sidebar-outline a.is-active > i,
.sidebar-outline a:first-child > i {
  border-color: var(--forest);
  background: var(--forest);
}

.course-stage {
  min-width: 0;
  width: 100%;
  order: initial;
}

.course-detail {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0 0 120px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.course-hero {
  width: 100%;
  min-height: 320px;
  margin-left: 0;
  padding: 54px 0 38px;
  display: grid;
  grid-template-columns: 1fr;
  align-content: center;
  border-bottom: 1px solid var(--rule);
  text-align: left;
}

.course-hero-body {
  min-width: 0;
}

.course-hero .lesson-meta {
  display: block;
  color: var(--bronze);
  font-size: 13px;
  font-weight: 700;
}

.course-hero h1 {
  max-width: 820px;
  margin: 24px 0 18px;
  font-family: var(--display-font);
  font-size: clamp(38px, 3vw, 43px);
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: 0;
}

.course-hero-body > p {
  max-width: 760px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 1.8;
}

.lesson-duration {
  margin-top: 20px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 600;
}

.lesson-duration .ui-icon {
  width: 17px;
  height: 17px;
}

.lesson-objectives {
  padding: 4px 0 4px 30px;
  border-left: 1px solid var(--rule);
}

.lesson-objectives > span {
  color: var(--bronze);
  font-size: 13px;
  font-weight: 700;
}

.lesson-objectives ol {
  margin: 18px 0 24px;
  padding-left: 22px;
  display: grid;
  gap: 12px;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.55;
}

.lesson-objectives button {
  min-height: 44px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 5px;
  background: var(--forest);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}

.lesson-objectives button:hover {
  background: #0d4e47;
}

.lesson-objectives button .ui-icon {
  filter: brightness(0) invert(1);
}

.media-switch {
  width: fit-content;
  margin: 0;
  padding: 26px 0 0;
  display: flex;
  align-items: stretch;
  gap: 0;
  border: 0;
  background: transparent;
}

.course-hero .media-switch {
  margin-top: 30px;
  padding-top: 0;
}

.media-switch button {
  min-width: 132px;
  min-height: 56px;
  padding: 0 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  position: relative;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink-soft);
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
}

.media-switch button + button::before {
  width: 1px;
  height: 18px;
  position: absolute;
  top: 19px;
  left: 0;
  background: var(--rule);
  content: "";
}

.media-switch button::after {
  height: 2px;
  position: absolute;
  right: 28px;
  bottom: 0;
  left: 28px;
  background: transparent;
  content: "";
}

.media-switch button:hover,
.media-switch button.active {
  background: transparent;
  color: var(--forest);
}

.media-switch button.active .ui-icon {
  filter: none;
}

.media-switch button.active::after {
  background: var(--forest);
}

#learningPanel {
  scroll-margin-top: 84px;
}

.media-panel {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.media-player-panel {
  width: min(100%, var(--reading-width));
  min-height: 340px;
  margin: 48px auto 0;
  padding: 36px;
  display: grid;
  align-content: center;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: #fff;
}

.media-player-panel audio,
.media-player-panel video {
  width: 100%;
  max-height: 520px;
}

.media-unavailable {
  width: min(100%, var(--reading-width));
  min-height: 220px;
  margin: 48px auto 0;
  padding: 34px 0;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.media-unavailable .ui-icon {
  width: 24px;
  height: 24px;
  color: var(--forest);
}

.media-unavailable h2 {
  margin: 0 0 10px;
  font-family: var(--display-font);
  font-size: 24px;
  font-weight: 600;
}

.media-unavailable p {
  max-width: 620px;
  margin: 0;
  color: var(--ink-muted);
  line-height: 1.8;
}

.course-manuscript {
  margin-top: 16px;
}

.mobile-course-outline {
  display: none;
}

.course-manuscript > .lesson-outline,
.course-seven-manuscript > .curated-outline {
  display: none;
}

.lesson-sections,
.curated-sections {
  width: min(100%, var(--reading-width));
  margin: 0 auto;
}

.lesson-section,
.curated-section {
  width: 100%;
  min-width: 0;
  padding: 42px 0;
  display: block;
  border: 0;
  background: transparent;
  scroll-margin-top: 96px;
}

.lesson-section-body,
.lesson-paragraph-group,
.lesson-text-block {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.curated-section.intro-section {
  background: transparent;
}

.lesson-section-marker {
  margin-bottom: 14px;
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.lesson-section-body h2,
.lesson-section-body h3,
.lesson-section-body h4,
.curated-section h3,
.curated-section h4 {
  margin: 0 0 22px;
  color: var(--ink-strong);
  font-family: var(--display-font);
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: 0;
}

.lesson-section-body h2,
.curated-section h3 {
  font-size: 30px;
}

.lesson-section-body h3 {
  font-size: 26px;
}

.lesson-section-body h4,
.curated-section h4 {
  margin-top: 30px;
  font-size: 21px;
}

.section-kicker {
  margin-bottom: 14px;
  display: block;
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.lesson-text-block,
.lesson-paragraph-group p,
.curated-section p,
.curated-section li,
.section-copy,
.curated-lead p {
  margin: 0 0 16px;
  color: #3f453e;
  font-size: 16px;
  line-height: 1.95;
  letter-spacing: 0;
}

.curated-lead,
.section-copy {
  max-width: 100%;
}

.curated-callout,
.lesson-note-block,
.module-callout {
  margin: 28px 0;
  padding: 20px 24px;
  border: 0;
  border-left: 3px solid var(--bronze);
  border-radius: 0;
  background: var(--bronze-soft);
  color: var(--ink-strong);
}

.curated-callout strong,
.lesson-note-block .lesson-note-label {
  display: block;
  margin-bottom: 6px;
  color: var(--ink-strong);
  font-weight: 600;
}

.curated-callout p,
.lesson-note-block {
  margin-bottom: 0;
}

.lesson-note-block > span {
  color: #3f453e;
  font-weight: 400;
  line-height: 1.9;
}

.lesson-inline-label {
  color: var(--ink-strong);
  font-weight: 600;
}

.prompt-block-head > span,
.prompt-block-head button {
  font-weight: 600;
}

.prompt-block-head button span {
  color: inherit;
  font-weight: inherit;
}

.lesson-step-block,
.lesson-kicker-block {
  font-weight: 600;
}

.lesson-link-block {
  font-weight: 400;
}

.lesson-section-body strong,
.curated-section strong {
  color: var(--ink-strong);
  font-weight: 600;
}

.lesson-section a {
  font-weight: 600;
}

.lesson-section.level-3 {
  background: transparent;
}

.lesson-section.level-3 .lesson-section-body h4 {
  margin-top: 0;
  font-size: 22px;
  font-weight: 600;
}

.prep-grid,
.principle-grid,
.flow-steps,
.summary-grid,
.standard-grid,
.source-grid,
.inbox-grid,
.embedded-list,
.task-footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.prep-grid article,
.principle-grid article,
.flow-steps article,
.summary-grid article,
.standard-grid article,
.source-grid article,
.inbox-grid article,
.embedded-list article {
  padding: 24px 0;
  border: 0;
  border-bottom: 1px solid var(--rule);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.standard-grid,
.summary-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 32px;
}

.source-grid article dl {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 8px 18px;
}

.question-list {
  margin: 24px 0;
  padding: 0;
  list-style: none;
}

.question-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--rule);
}

.inline-resource-grid {
  margin: 30px 0 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.inline-resource-grid a {
  min-height: 150px;
  padding: 22px;
  display: grid;
  align-content: start;
  gap: 10px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: #fff;
  color: var(--ink-strong);
  text-decoration: none;
}

.inline-resource-grid a:hover {
  border-color: var(--forest);
}

.inline-resource-grid span {
  color: var(--bronze);
  font-size: 11px;
  font-weight: 700;
}

.inline-resource-grid small {
  color: var(--ink-soft);
  line-height: 1.6;
}

.lesson-prompt-block {
  min-width: 0;
  max-width: 100%;
  margin: 28px 0;
  overflow: hidden;
  border: 1px solid #cbded5;
  border-left: 3px solid var(--forest);
  border-radius: 6px;
  background: #f6faf8;
  box-shadow: none;
}

.prompt-block-head {
  min-height: 48px;
  padding: 10px 16px 10px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 0;
  background: #eaf4ef;
}

.prompt-block-head > span {
  min-width: 0;
  color: var(--ink-strong);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.prompt-block-head button {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 8px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 0;
  background: transparent;
  color: var(--forest);
  font-size: 12px;
  font-weight: 700;
}

.prompt-block-head .ui-icon {
  width: 15px;
  height: 15px;
}

.lesson-prompt-block pre {
  max-height: none;
  margin: 0;
  padding: 22px;
  overflow: auto;
  color: #25302b;
  background: #f6faf8;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 14px;
  line-height: 1.75;
  white-space: pre-wrap;
  user-select: text;
}

.prompt-block-head > span,
.prompt-block-head button,
.prompt-block-head button span {
  font-weight: 600;
}

.decision-ladder,
.movement-timeline {
  margin: 28px 0;
  display: grid;
  grid-template-columns: 1fr;
  border-top: 1px solid var(--rule);
}

.decision-ladder article,
.movement-timeline article {
  padding: 18px 0;
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 24px;
  border: 0;
  border-bottom: 1px solid var(--rule);
  background: transparent;
}

.decision-ladder article span,
.movement-timeline article span {
  color: var(--bronze);
  font-weight: 700;
}

.material-embed-list {
  display: grid;
  gap: 12px;
}

.material-embed-list details {
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: #fff;
}

.material-embed-list summary {
  padding: 18px 20px;
  display: grid;
  gap: 6px;
  cursor: pointer;
}

.material-embed-list summary span {
  color: var(--bronze);
  font-size: 11px;
  font-weight: 700;
}

.embedded-material-body {
  padding: 20px;
  border-top: 1px solid var(--rule);
}

.task-card {
  width: min(100%, var(--reading-width));
  margin: 56px auto 0;
  padding: 44px 0 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  scroll-margin-top: 84px;
}

.task-card-head {
  margin-bottom: 28px;
}

.task-card-head > span {
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.task-card-head h3 {
  margin: 10px 0 12px;
  font-family: var(--display-font);
  font-size: 30px;
  font-weight: 600;
  line-height: 1.45;
}

.task-card-head p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.8;
}

.course-seven-task-flow,
.task-flow-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.task-section,
.task-major-section,
.task-footer-grid .task-section {
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: #fff;
  box-shadow: none;
}

.task-major-head {
  min-height: 64px;
  padding: 0 18px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  list-style: none;
}

.task-major-head::-webkit-details-marker {
  display: none;
}

.task-major-head > span {
  padding: 4px 7px;
  border-radius: 3px;
  background: var(--forest-soft);
  color: var(--forest);
  font-size: 11px;
  font-weight: 700;
}

.task-major-head > strong {
  font-size: 15px;
}

.task-major-head .ui-icon {
  width: 16px;
  height: 16px;
  transition: transform 160ms ease;
}

.task-major-section[open] .task-major-head .ui-icon {
  transform: rotate(90deg);
}

.task-summary-copy {
  margin: 0;
  padding: 0 20px 18px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.75;
}

.task-capture-list {
  padding: 0 20px 20px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.task-capture-list section {
  padding: 20px 0;
  border: 0;
  border-top: 1px solid var(--rule);
  background: transparent;
}

.task-capture-list section strong,
.task-section > strong {
  display: block;
  margin-bottom: 10px;
}

.task-capture-list ul,
.task-section ul {
  margin: 0;
  padding-left: 20px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.75;
}

.task-footer-grid {
  gap: 12px;
}

.task-footer-grid .task-section,
.task-flow-list .task-section {
  padding: 20px;
}

.course-utilities {
  position: fixed;
  right: 22px;
  bottom: 24px;
  z-index: 45;
  display: grid;
  gap: 8px;
}

.course-utilities button {
  min-height: 42px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--rule-strong);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--ink-strong);
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 8px 28px rgba(36, 39, 33, 0.08);
}

.course-utilities button:hover {
  border-color: var(--forest);
  color: var(--forest);
}

.course-utilities .ui-icon {
  width: 16px;
  height: 16px;
}

.resource-drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  justify-content: flex-end;
  background: rgba(20, 25, 22, 0.28);
}

.resource-drawer {
  width: min(430px, 92vw);
  height: 100%;
  padding: 28px;
  overflow-y: auto;
  border-left: 1px solid var(--rule);
  background: #fff;
  box-shadow: -18px 0 54px rgba(24, 29, 25, 0.16);
}

.resource-drawer-head {
  margin-bottom: 24px;
  padding-bottom: 22px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--rule);
}

.resource-drawer-head span,
.resource-drawer-head strong {
  display: block;
}

.resource-drawer-head span {
  margin-bottom: 5px;
  color: var(--bronze);
  font-size: 11px;
  font-weight: 700;
}

.resource-drawer-head strong {
  font-family: var(--display-font);
  font-size: 22px;
}

.resource-drawer-head button {
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid var(--rule);
  border-radius: 4px;
  background: #fff;
  color: var(--ink-soft);
  font-size: 12px;
}

.resource-drawer .rail-stack,
.resource-drawer .resources-card {
  display: grid;
  gap: 16px;
}

.resource-drawer .sidebar-card {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.resource-drawer .rail-title {
  padding: 0;
}

.resource-drawer .rail-title span,
.resource-drawer .rail-title strong {
  display: block;
}

.resource-drawer .rail-title span {
  color: var(--bronze);
  font-size: 11px;
}

.resource-drawer .rail-title strong {
  margin-top: 4px;
  font-size: 15px;
}

.resource-drawer .resource-list {
  display: grid;
  gap: 0;
}

.resource-drawer .resource-list a {
  padding: 18px 0;
  display: grid;
  gap: 6px;
  border: 0;
  border-bottom: 1px solid var(--rule);
  border-radius: 0;
  background: transparent;
  color: var(--ink-strong);
  text-decoration: none;
}

.resource-drawer .resource-list a:hover strong {
  color: var(--forest);
}

.resource-drawer .resource-type,
.resource-drawer .resource-list em {
  color: var(--bronze);
  font-size: 11px;
  font-style: normal;
}

.resource-drawer .resource-list small {
  color: var(--ink-soft);
  line-height: 1.55;
}

@media (max-width: 1120px) {
  .course-shell .topbar {
    grid-template-columns: auto minmax(270px, 1fr) auto;
    gap: 24px;
  }

  .course-shell .progress-pill {
    display: none;
  }

  .course-page {
    grid-template-columns: 210px minmax(0, 1fr);
    gap: 34px;
  }

  .course-hero {
    width: 100%;
    margin-left: 0;
  }
}

@media (max-width: 960px) {
  .course-shell .topbar {
    min-height: 108px;
    padding: 12px 18px 0;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: 44px 52px;
    gap: 0 16px;
  }

  .course-shell .primary-nav {
    height: 52px;
    grid-row: 2;
    grid-column: 1 / -1;
    justify-content: space-around;
    gap: 0;
  }

  .course-shell .primary-nav button {
    flex: 1;
  }

  .course-shell .topbar-tools {
    grid-row: 1;
    grid-column: 2;
  }

  .course-shell .tool-chip span {
    display: none;
  }

  .course-shell .tool-chip {
    width: 38px;
    padding: 0;
    justify-content: center;
  }

  .week-overview-track {
    min-height: 122px;
    padding-top: 24px;
    grid-auto-flow: column;
    grid-auto-columns: 132px;
    grid-template-columns: none;
  }

  .week-overview-track::before {
    top: 46px;
    right: 60px;
    left: 60px;
    min-width: 760px;
  }

  .week-overview-card.selected::after {
    bottom: -18px;
  }

  .week-course-expander {
    grid-template-columns: 1fr;
  }

  .week-course-head {
    padding: 14px 6px;
    border-bottom: 1px solid var(--rule);
  }

  .week-course-list {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(250px, 72vw);
    grid-template-columns: none;
    overflow-x: auto;
  }

  .week-course-button:first-child {
    border-left: 0;
  }

  .course-page {
    width: min(100%, 920px);
    padding: 0 24px;
    display: flex;
    flex-direction: column;
  }

  .course-stage {
    order: 1;
  }

  .course-sidebar {
    display: none;
  }

  .mobile-course-outline {
    width: min(100%, var(--reading-width));
    margin: 24px auto 0;
    display: block;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
  }

  .mobile-course-outline summary {
    padding: 17px 0;
    display: grid;
    grid-template-columns: 18px 1fr auto;
    gap: 9px;
    align-items: center;
    color: var(--ink-strong);
    cursor: pointer;
    list-style: none;
  }

  .mobile-course-outline summary::-webkit-details-marker {
    display: none;
  }

  .mobile-course-outline summary .ui-icon {
    width: 16px;
    height: 16px;
  }

  .mobile-course-outline summary span {
    font-size: 14px;
    font-weight: 700;
  }

  .mobile-course-outline summary small {
    color: var(--ink-muted);
    font-size: 12px;
  }

  .mobile-course-outline nav {
    max-height: 54vh;
    padding: 0 0 14px;
    display: grid;
    overflow-y: auto;
  }

  .mobile-course-outline nav a {
    padding: 9px 0;
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    color: var(--ink-muted);
    text-decoration: none;
  }

  .mobile-course-outline nav a.is-active {
    color: var(--forest);
  }

  .mobile-course-outline nav a span {
    color: var(--bronze);
    font-size: 11px;
  }

  .mobile-course-outline nav a strong {
    font-size: 13px;
    font-weight: 500;
    line-height: 1.55;
    overflow-wrap: anywhere;
  }

  .course-hero {
    width: 100%;
    min-height: 0;
    margin-left: 0;
    padding: 56px 0 42px;
  }
}

@media (max-width: 680px) {
  .course-shell .topbar {
    padding-right: 12px;
    padding-left: 12px;
  }

  .course-shell .topbar-brand {
    gap: 9px;
  }

  .course-shell .topbar-brand .brand-mark {
    width: 34px;
    height: 34px;
  }

  .course-shell .topbar-brand strong {
    max-width: 188px;
    overflow: hidden;
    font-size: 15px;
    text-overflow: ellipsis;
  }

  .course-shell .primary-nav button {
    font-size: 13px;
  }

  .course-week-overview {
    padding: 0 12px;
  }

  .week-course-list {
    grid-auto-columns: minmax(250px, 84vw);
  }

  .course-page {
    padding: 0 18px;
  }

  .course-hero {
    padding: 42px 0 34px;
  }

  .course-hero h1 {
    margin-top: 18px;
    font-size: 35px;
    line-height: 1.32;
  }

  .course-hero-body > p {
    font-size: 15px;
  }

  .lesson-objectives {
    padding: 26px 0 0;
    border-top: 1px solid var(--rule);
    border-left: 0;
  }

  .lesson-objectives button {
    width: 100%;
    justify-content: center;
  }

  .media-switch {
    width: 100%;
    justify-content: stretch;
  }

  .media-switch button {
    min-width: 0;
    flex: 1;
    padding: 0 10px;
    font-size: 14px;
    white-space: nowrap;
  }

  .media-switch button::after {
    right: 10px;
    left: 10px;
  }

  .lesson-section,
  .curated-section {
    padding: 40px 0;
  }

  .lesson-section-body h2,
  .curated-section h3 {
    font-size: 26px;
  }

  .lesson-section-body h3 {
    font-size: 23px;
  }

  .lesson-text-block,
  .lesson-paragraph-group p,
  .curated-section p,
  .curated-section li,
  .section-copy,
  .curated-lead p {
    font-size: 15px;
    line-height: 1.9;
  }

  .standard-grid,
  .summary-grid,
  .inline-resource-grid {
    grid-template-columns: 1fr;
  }

  .decision-ladder article,
  .movement-timeline article {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .lesson-prompt-block pre {
    padding: 18px;
    font-size: 13px;
  }

  .prompt-block-head {
    padding-left: 16px;
  }

  .task-card {
    margin-top: 44px;
    padding-top: 34px;
  }

  .task-card-head h3 {
    font-size: 26px;
  }

  .task-major-head {
    min-height: 70px;
    grid-template-columns: auto minmax(0, 1fr) auto;
  }

  .course-utilities {
    margin: 24px 18px 0;
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .course-utilities button {
    width: auto;
    min-height: 44px;
    padding: 0 12px;
    justify-content: center;
  }

  .course-utilities button span {
    display: inline;
  }

  .resource-drawer {
    width: 100%;
    padding: 22px 18px;
  }

  .media-player-panel {
    min-height: 260px;
    margin-top: 36px;
    padding: 18px;
  }
}

/* V0.4 community learning archive */
.library-shell .primary-nav {
  display: flex;
  align-items: stretch;
  gap: 30px;
}

.library-shell .primary-nav button {
  white-space: nowrap;
}

.library-layout {
  width: min(1320px, calc(100vw - 48px));
  padding: 36px 0 72px;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 42px;
}

.library-sidebar {
  top: 96px;
  max-height: calc(100vh - 122px);
  padding: 24px 18px;
  overflow-y: auto;
  border-color: var(--rule);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: none;
  scrollbar-width: thin;
}

.community-panel-head > span {
  display: block;
  margin-bottom: 6px;
  color: var(--bronze);
  font-size: 11px;
  font-weight: 700;
}

.community-panel-head h2,
.library-sidebar .panel-head h2 {
  font-family: var(--display-font);
  font-size: 24px;
  font-weight: 600;
}

.highlight-list {
  display: grid;
  gap: 24px;
}

.highlight-week-group {
  display: grid;
  gap: 2px;
}

.highlight-week-group > strong {
  padding: 0 8px 9px;
  color: var(--ink-soft);
  font-size: 12px;
}

.highlight-row {
  width: 100%;
  min-height: 46px;
  padding: 12px 10px;
  display: flex;
  align-items: center;
  border: 0;
  border-bottom: 1px solid var(--rule);
  border-radius: 0;
  background: transparent;
  color: var(--ink-strong);
  text-align: left;
}

.highlight-row span {
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.highlight-row strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.highlight-row:hover,
.highlight-row.selected {
  padding-left: 14px;
  background: var(--forest-soft);
  box-shadow: inset 3px 0 0 var(--forest);
}

.community-welcome,
.community-article {
  width: min(100%, 900px);
  margin: 0 auto;
}

.community-welcome {
  min-height: 520px;
  padding: 72px;
  display: grid;
  align-content: center;
  gap: 16px;
  border-top: 3px solid var(--forest);
  background: #fff;
}

.community-welcome > span,
.community-hero > span,
.community-keypoints span {
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.community-welcome h2 {
  max-width: 620px;
  margin: 0;
  font-family: var(--display-font);
  font-size: 38px;
  font-weight: 600;
  line-height: 1.38;
}

.community-welcome p {
  max-width: 620px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 1.85;
}

.community-article {
  padding: 0 52px 70px;
  background: #fff;
}

.community-hero {
  padding: 68px 0 48px;
  border-bottom: 1px solid var(--rule-strong);
}

.community-hero h1 {
  margin: 14px 0 18px;
  font-family: var(--display-font);
  font-size: 44px;
  font-weight: 600;
  line-height: 1.3;
}

.community-hero p {
  max-width: 700px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 17px;
  line-height: 1.9;
}

.community-tags {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.community-tags em {
  color: var(--forest);
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
}

.community-keypoints {
  margin: 48px 0 12px;
  padding: 30px 34px;
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 36px;
  background: var(--forest-soft);
}

.community-keypoints h2 {
  margin: 8px 0 0;
  font-family: var(--display-font);
  font-size: 23px;
  font-weight: 600;
  line-height: 1.45;
}

.community-keypoints ol {
  margin: 0;
  padding-left: 22px;
  display: grid;
  gap: 14px;
  color: #3f453e;
  font-size: 15px;
  line-height: 1.75;
}

.community-sections {
  display: grid;
}

.community-section {
  padding: 44px 0;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 22px;
  border-bottom: 1px solid var(--rule);
}

.community-section > span {
  padding-top: 7px;
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.community-section h2 {
  margin: 0 0 18px;
  font-family: var(--display-font);
  font-size: 29px;
  font-weight: 600;
  line-height: 1.45;
}

.community-section p,
.community-section li {
  margin: 0 0 14px;
  color: #3f453e;
  font-size: 16px;
  line-height: 1.95;
}

.community-section ul {
  padding-left: 22px;
}

.community-source {
  margin-top: 48px;
}

.community-source-header {
  padding: 0 0 26px;
  border-bottom: 1px solid var(--rule-strong);
}

.community-source-header span {
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.community-source-header h2 {
  margin: 8px 0 0;
  font-family: var(--display-font);
  font-size: 31px;
  font-weight: 600;
  line-height: 1.4;
}

.community-source-sections {
  display: grid;
}

.community-source-section {
  padding: 46px 0;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 22px;
  border-bottom: 1px solid var(--rule);
  scroll-margin-top: 96px;
}

.community-source-section > span {
  padding-top: 8px;
  color: var(--bronze);
  font-size: 12px;
  font-weight: 700;
}

.community-source-section h2 {
  margin: 0 0 22px;
  font-family: var(--display-font);
  font-size: 29px;
  font-weight: 600;
  line-height: 1.45;
}

.highlight-source-block {
  margin: 0 0 16px;
  color: #3f453e;
  font-size: 16px;
  line-height: 1.95;
  overflow-wrap: anywhere;
}

.highlight-source-block.is-labeled {
  margin-top: 26px;
}

.highlight-source-label {
  margin-right: 0.38em;
  color: var(--ink-strong);
  font-weight: 600;
}

.highlight-source-block.is-labeled > span {
  display: block;
  margin-top: 7px;
  color: #3f453e;
  font-weight: 400;
}

.highlight-mention {
  color: #2468a2;
  font-weight: 600;
}

.highlight-source-subheading {
  margin: 34px 0 16px;
  color: var(--ink-strong);
  font-family: var(--display-font);
  font-size: 20px;
  font-weight: 600;
  line-height: 1.6;
}

.highlight-source-quote {
  margin: 0 0 18px;
  padding: 18px 20px;
  border: 0;
  border-left: 3px solid #8bad9f;
  border-radius: 0 4px 4px 0;
  background: #f4f8f6;
}

.highlight-source-quote p {
  margin: 0;
  color: #33423d;
  font-size: 16px;
  line-height: 1.9;
  overflow-wrap: anywhere;
}

.highlight-source-quote footer {
  margin-top: 10px;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.6;
}

.highlight-source-list {
  margin: 2px 0 20px;
  padding-left: 1.5em;
  color: #3f453e;
}

.highlight-source-list li {
  padding-left: 0.35em;
  font-size: 16px;
  line-height: 1.85;
}

.highlight-source-list li + li {
  margin-top: 6px;
}

.highlight-source-block a,
.highlight-source-prompt a {
  color: var(--forest);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.highlight-source-prompt {
  margin: 24px 0;
  padding: 22px 22px 18px;
  display: grid;
  gap: 18px;
  border: 1px solid #cbded8;
  border-left: 3px solid var(--forest);
  border-radius: 4px;
  background: var(--forest-soft);
}

.highlight-source-prompt strong {
  display: block;
  margin-bottom: 12px;
  color: var(--forest);
  font-size: 15px;
  font-weight: 600;
}

.highlight-source-prompt p {
  margin: 0 0 10px;
  color: #33423d;
  font-size: 15px;
  line-height: 1.85;
  white-space: pre-wrap;
}

.highlight-source-prompt button {
  width: fit-content;
  min-height: 38px;
  padding: 8px 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #b7d0c8;
  border-radius: 4px;
  color: var(--forest);
  background: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.highlight-source-prompt button:hover {
  border-color: var(--forest);
}

.highlight-source-prompt .ui-icon {
  width: 15px;
  height: 15px;
}

.community-quote {
  margin: 46px 0 28px;
  padding: 24px 28px;
  border: 0;
  border-left: 3px solid var(--bronze);
  background: var(--bronze-soft);
  color: var(--ink-strong);
  font-family: var(--display-font);
  font-size: 22px;
  line-height: 1.7;
}

.source-trace-link {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  color: var(--forest);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.source-trace-link:hover {
  text-decoration: underline;
}

.library-stage .lesson-hero {
  min-height: 0;
  padding: 34px 36px;
  display: block;
  color: var(--ink-strong);
  background: #fff;
}

.library-stage .lesson-hero .lesson-meta {
  color: var(--bronze);
}

.library-stage .lesson-hero h2 {
  max-width: 820px;
  margin: 14px 0 10px;
  color: var(--ink-strong);
  font-size: clamp(30px, 3.4vw, 44px);
  line-height: 1.28;
}

.library-stage .lesson-hero p {
  margin: 10px 0 0;
  color: var(--ink-soft);
}

.replay-subtitle {
  display: block;
  margin: 0 0 12px;
  color: var(--ink-soft);
  font-size: 18px;
  font-weight: 500;
}

.replay-duration {
  margin-top: 18px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 600;
}

.replay-duration .ui-icon {
  width: 16px;
  height: 16px;
}

.official-replay-entry {
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.official-replay-entry div {
  display: grid;
  gap: 6px;
}

.official-replay-entry span,
.official-replay-entry small {
  color: var(--ink-soft);
  font-size: 12px;
}

.official-replay-entry strong {
  color: var(--ink-strong);
  font-size: 15px;
}

.official-replay-entry a {
  min-height: 42px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  border-radius: 5px;
  background: var(--forest);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 960px) {
  .library-shell .primary-nav {
    width: 100%;
    justify-content: space-around;
    gap: 0;
  }

  .library-shell .primary-nav button {
    flex: 1;
    padding-right: 6px;
    padding-left: 6px;
  }

  .library-layout {
    width: 100%;
    padding: 16px 12px 48px;
    grid-template-columns: 1fr;
    grid-template-areas:
      "sidebar"
      "stage";
    gap: 18px;
  }

  .library-sidebar {
    position: static;
    max-height: none;
    overflow: hidden;
  }

  .highlight-list,
  .replay-list {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scrollbar-width: thin;
  }

  .highlight-week-group {
    display: contents;
  }

  .highlight-week-group > strong {
    display: none;
  }

  .highlight-row,
  .replay-list .course-row {
    min-width: min(300px, 78vw);
    border: 1px solid var(--rule);
    border-radius: 5px;
  }

  .community-article {
    padding: 0 34px 56px;
  }
}

@media (max-width: 680px) {
  .library-shell .primary-nav button {
    font-size: 12px;
  }

  .community-welcome {
    min-height: 420px;
    padding: 42px 24px;
  }

  .community-welcome h2 {
    font-size: 31px;
  }

  .community-article {
    padding: 0 20px 46px;
  }

  .community-hero {
    padding: 44px 0 34px;
  }

  .community-hero h1 {
    font-size: 34px;
  }

  .community-hero p {
    font-size: 15px;
  }

  .community-keypoints {
    margin-top: 34px;
    padding: 24px;
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .community-section {
    padding: 34px 0;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .community-section h2 {
    font-size: 25px;
  }

  .community-section p,
  .community-section li {
    font-size: 15px;
    line-height: 1.85;
  }

  .community-source {
    margin-top: 34px;
  }

  .community-source-header h2 {
    font-size: 27px;
  }

  .community-source-section {
    padding: 36px 0;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .community-source-section h2 {
    font-size: 25px;
  }

  .highlight-source-block {
    font-size: 15px;
    line-height: 1.88;
  }

  .highlight-source-prompt {
    padding: 18px;
  }

  .highlight-source-prompt button {
    width: 100%;
    justify-content: center;
  }

  .community-quote {
    font-size: 19px;
  }

  .official-replay-entry {
    align-items: stretch;
    flex-direction: column;
  }

  .official-replay-entry a {
    justify-content: center;
  }
}
