.demo-page {
  min-height: 100vh;
  background: var(--learning-surface);
  color: var(--navy);
  font: 16px/1.65 var(--font-sans);
}
.demo-page * {
  box-sizing: border-box;
}
.demo-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  padding: 18px clamp(18px, 4vw, 56px);
  background: white;
  border-bottom: 1px solid var(--line);
}
.demo-topbar > a {
  margin-left: auto;
  color: var(--navy);
  font-size: 14px;
  font-weight: 700;
}
.demo-shell {
  max-width: 1200px;
  margin: auto;
  padding: 32px clamp(18px, 4vw, 48px) 64px;
}
.demo-page h1 {
  font: 700 clamp(30px, 4vw, 46px)/1.15 var(--font-math);
  margin: 8px 0 16px;
}
.demo-page h2 {
  font-size: 24px;
  line-height: 1.3;
  margin: 10px 0;
}
.demo-kicker {
  color: var(--deep-accent);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.04em;
}
.demo-tag {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  background: var(--learning-chem-soft);
  color: var(--chem-label-ink);
  font-size: 14px;
  font-weight: 700;
}
.demo-subjects {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 24px 0;
}
.demo-card {
  padding: 24px;
  border: 1px solid var(--learning-border);
  border-radius: 18px;
  background: white;
  box-shadow: var(--shadow-sm);
  min-width: 0;
}
.demo-privacy {
  color: #48616c;
  font-size: 14px;
  margin-top: 24px;
}
.demo-page :focus-visible {
  outline: 3px solid var(--memory-gold);
  outline-offset: 4px;
}
.demo-page button,
.demo-page input,
.demo-page textarea {
  font: inherit;
}
.demo-page button {
  cursor: pointer;
  touch-action: manipulation;
}
.demo-page button:disabled {
  opacity: 0.55;
  cursor: default;
}
.demo-page h3 {
  font-size: 21px;
  line-height: 1.5;
  margin: 14px 0 20px;
}
.demo-page h4 {
  font-size: 18px;
  margin: 0 0 8px;
}
.demo-page p {
  margin: 12px 0;
}
.demo-page svg {
  display: block;
  width: 100%;
  height: auto;
}
.demo-toolbar,
.demo-help-actions,
.demo-lesson-switcher {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 24px;
}
.demo-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 16px;
  border: 1px solid var(--deep-accent);
  border-radius: 10px;
  background: var(--deep-accent);
  color: white;
  font-weight: 750 !important;
  line-height: 1.4;
}
.demo-button.secondary {
  color: var(--navy);
  background: white;
  border-color: #b5c8ca;
}
.demo-button[aria-current] {
  box-shadow: inset 0 0 0 2px var(--deep-accent);
}
.demo-notice {
  margin: 20px 0;
  background: var(--learning-chem-soft);
  border: 1px solid #c4d2e8;
  border-radius: 12px;
  padding: 20px;
}
.demo-notice blockquote {
  margin: 18px 0;
  padding: 15px;
  background: white;
  border-radius: 8px;
}
.demo-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin: 24px 0 8px;
}
.demo-stats > div {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
}
.demo-stats strong {
  display: block;
  font-size: 30px;
  line-height: 1.2;
  color: var(--deep-accent);
}
.demo-stats span {
  display: block;
  font-size: 14px;
  margin-top: 8px;
}
.demo-muted {
  font-size: 14px;
  color: #4d6570;
}
.demo-card-art {
  background: #eef6f5;
  border-radius: 12px;
  margin: 0 0 22px;
  padding: 10px;
}
.demo-card-art .demo-figure {
  max-width: 250px;
  margin: auto;
}
.demo-card-art .chem-visual {
  display: grid;
  align-content: center;
  min-height: 260px;
  margin: 0;
  padding: 0;
  border: 0;
  box-shadow: none;
  background: transparent;
}
.demo-card-art figcaption {
  display: none;
}
.demo-figure {
  max-width: 490px;
  margin: 20px auto;
}
.demo-figure figcaption {
  font-size: 14px;
  line-height: 1.5;
  color: #4c6570;
}
.demo-progress-label {
  font-size: 14px;
  display: block;
  margin: 20px 0;
}
.demo-page progress {
  display: block;
  width: 100%;
  height: 10px;
  margin: 10px 0;
  accent-color: var(--deep-accent);
}
.demo-lesson-list {
  display: grid;
  gap: 10px;
}
.demo-lesson-list button {
  display: flex;
  align-items: center;
  text-align: left;
  gap: 12px;
  padding: 14px;
  border: 1px solid #cdd9dd;
  background: #f7fafa;
  border-radius: 12px;
  color: var(--navy);
  line-height: 1.5;
}
.demo-lesson-list button:hover {
  background: #e9f4f0;
  border-color: var(--deep-accent);
}
.demo-lesson-list small {
  display: block;
  font-size: 14px;
  color: #536871;
  margin-top: 4px;
}
.demo-lesson-list button > span:last-child {
  margin-left: auto;
}
.demo-step-number {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  background: var(--teal-soft);
  color: var(--deep-accent);
  font-size: 14px;
  font-weight: 800;
  border-radius: 50%;
}
.demo-tabs [data-slot='tabs-list'] {
  display: flex;
  width: 100%;
  height: auto;
  margin: 12px 0 22px;
  padding: 6px;
  background: #e8eeee;
  border-radius: 12px;
}
.demo-tabs [data-slot='tabs-trigger'] {
  flex: 1;
  white-space: normal;
  font-size: 16px;
  min-height: 48px;
  border: 0;
  padding: 9px;
  border-radius: 8px;
  background: transparent;
  color: #34505c;
}
.demo-tabs [data-slot='tabs-trigger'][data-active] {
  background: white;
  color: var(--deep-accent);
  box-shadow: var(--shadow-sm);
}
.demo-tabs [data-slot='tabs-content'] {
  font-size: 16px;
  line-height: 1.75;
}
.demo-terms {
  background: #f0f7f5;
  padding: 18px;
  border-radius: 12px;
  display: grid;
  gap: 14px;
}
.demo-terms dt {
  font-weight: 800;
  color: var(--deep-accent);
}
.demo-terms dd {
  margin: 4px 0 0;
}
.demo-ideas {
  padding-left: 25px;
}
.demo-ideas li {
  margin: 18px 0;
  padding-left: 6px;
}
.demo-steps {
  padding: 0;
  list-style: none;
}
.demo-steps li {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 14px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
}
.demo-steps p {
  color: #385663;
}
.demo-equation {
  padding: 12px 16px;
  margin: 12px 0;
  background: #f0f5f5;
  border-radius: 10px;
  font-family: var(--font-math);
  font-size: 22px;
  overflow-wrap: anywhere;
}
.demo-answer {
  background: #e8f5ef;
  border: 1px solid #b9d8cd;
  padding: 20px;
  border-radius: 12px;
  margin: 18px 0;
}
.demo-answer p {
  margin: 8px 0 0;
}
.demo-question-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin: 16px 0;
  font-size: 14px;
}
.demo-question-nav > div {
  display: flex;
  gap: 8px;
}
.demo-question-nav button {
  width: 44px;
  height: 44px;
  border: 1px solid #b5c8ca;
  border-radius: 8px;
  color: var(--navy);
  background: white;
}
.demo-question-nav button[aria-current] {
  background: var(--deep-accent);
  color: white;
}
.demo-question-heading {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  color: #506774;
  font-size: 14px;
}
.demo-choices {
  border: 0;
  margin: 0 0 20px;
  padding: 0;
  display: grid;
  gap: 10px;
}
.demo-choices legend {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 10px;
}
.demo-choices label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  border: 1px solid #c3d2d4;
  border-radius: 10px;
  padding: 14px;
  cursor: pointer;
}
.demo-choices label.selected {
  background: var(--teal-soft);
  border-color: var(--deep-accent);
}
.demo-choices input {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  margin-top: 3px;
  accent-color: var(--deep-accent);
}
.demo-answer-input {
  display: grid;
  gap: 8px;
  font-weight: 700;
  margin: 16px 0;
}
.demo-answer-input input,
.demo-answer-input textarea {
  width: 100%;
  background: white;
  border: 1px solid #afc1c7;
  padding: 12px;
  border-radius: 10px;
  color: var(--navy);
  font-weight: 400;
  resize: vertical;
}
.demo-feedback {
  padding: 14px 18px;
  border-radius: 10px;
  background: #fff3d9;
}
.demo-feedback.positive {
  background: #e8f5ef;
}
.demo-help-actions {
  margin-top: 20px;
}
.demo-hints {
  border-left: 3px solid var(--mango);
  padding: 12px 18px 12px 38px;
  background: #fffaf0;
  border-radius: 8px;
}
.demo-hints li {
  padding: 5px 0;
}
.demo-teaching {
  margin-top: 24px;
  border-top: 2px solid var(--deep-accent);
  padding-top: 16px;
}
.demo-question-footer {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.demo-next {
  margin-top: 20px;
}
.demo-privacy {
  border-top: 1px solid var(--line);
  padding-top: 20px;
}
@media (max-width: 650px) {
  .demo-stats {
    grid-template-columns: 1fr 1fr;
  }
  .demo-card {
    padding: 18px;
  }
  .demo-tabs [data-slot='tabs-trigger'] {
    font-size: 14px;
    padding: 8px 5px;
  }
  .demo-lesson-switcher {
    display: grid;
  }
  .demo-toolbar .demo-button {
    flex: 1;
  }
  .demo-card-art .demo-figure {
    max-width: 220px;
  }
}
@media (max-width: 650px) {
  .demo-subjects {
    grid-template-columns: 1fr;
  }
  .demo-topbar {
    gap: 8px 14px;
  }
}
.demo-page svg.lucide {
  width: auto;
  height: 20px;
  flex-shrink: 0;
}
.demo-catalogue-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 26px;
}
.demo-catalogue-heading > div {
  max-width: 720px;
}
.demo-catalogue-heading > button {
  flex-shrink: 0;
}
.demo-catalogue-heading h1 {
  font-size: clamp(32px, 4vw, 48px);
}
.demo-button {
  gap: 10px;
  text-decoration: none;
}
.demo-catalogue-tabs > [data-slot='tabs-list'] {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  height: auto;
  width: 100%;
  background: #e5edf2;
  padding: 6px;
  border-radius: 14px;
  gap: 6px;
}
.demo-catalogue-tabs [data-slot='tabs-trigger'] {
  display: flex;
  gap: 8px;
  min-height: 60px;
  padding: 12px;
  font-size: 18px;
  color: #294956;
  border-radius: 9px;
}
.demo-catalogue-tabs [data-slot='tabs-trigger'] span {
  font-size: 14px;
  font-weight: 400;
}
.demo-catalogue-tabs [data-active] {
  background: white;
  box-shadow: 0 2px 6px #18354915;
}
.demo-catalogue-caption {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin: 24px 0 18px;
  color: #4b6370;
  font-size: 14px;
}
.demo-catalogue-caption span {
  display: inline-flex;
  gap: 7px;
  align-items: center;
}
.demo-topic-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.demo-topic-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #cddce2;
  border-radius: 18px;
  background: white;
}
.demo-topic-card.is-open {
  border-color: #6baba3;
}
.demo-topic-card.is-locked {
  cursor: pointer;
}
.demo-topic-card.is-locked:hover {
  border-color: #608aa0;
  box-shadow: 0 3px 15px #19354812;
}
.demo-member-features {
  margin-top: 40px;
  border-top: 1px solid #cedee5;
  padding-top: 24px;
}
.demo-member-features > div {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 20px 0;
}
.demo-member-features button {
  text-align: left;
  display: grid;
  gap: 12px;
  padding: 22px;
  border-radius: 14px;
  border: 1px solid #cddce2;
  background: #fff;
  color: #294f60;
}
.demo-member-features button strong {
  font-size: 18px;
}
.demo-member-features button span {
  font-size: 16px;
  color: #526b77;
}
.demo-member-features button b {
  font-size: 14px;
  color: #266e76;
}
@media (max-width: 700px) {
  .demo-member-features > div {
    grid-template-columns: 1fr;
  }
}
.demo-topic-art {
  position: relative;
  background: #eaf3f8;
  aspect-ratio: 1.6;
  padding: 20px 14px 30px;
  overflow: hidden;
}
.demo-topic-art > svg,
.demo-topic-art > div,
.demo-topic-art > figure {
  height: 100%;
  max-height: 100%;
  margin: 0;
}
.demo-topic-art svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.demo-topic-art figcaption {
  display: none;
}
.demo-access {
  position: absolute;
  display: inline-flex;
  gap: 7px;
  align-items: center;
  left: 16px;
  bottom: 10px;
  border-radius: 6px;
  background: #fff;
  padding: 4px 9px;
  font-size: 14px;
  font-weight: 750;
  color: #4c6271;
}
.demo-access.open {
  color: #12675d;
  background: #e0f5ed;
}
.demo-topic-copy {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 22px;
}
.demo-topic-copy h2 {
  font-size: 23px;
  margin-top: 0;
}
.demo-topic-copy > p:not(.demo-kicker) {
  color: #4e6671;
}
.demo-topic-copy .demo-kicker {
  margin: 0 0 8px;
}
.demo-topic-count {
  font-size: 14px;
  font-weight: 750;
  margin-top: auto;
  padding-top: 10px;
}
.demo-topic-includes {
  font-size: 14px;
}
.demo-topic-copy .demo-button {
  width: 100%;
  margin-top: 10px;
}
.demo-maths-art {
  display: grid;
  place-items: center;
  padding: 10px;
  font: 600 clamp(23px, 2vw, 30px)/1.3 var(--font-math);
  color: #265c71;
  text-align: center;
}
.demo-join-dialog {
  background: white;
  color: #173342;
  font: 16px/1.65 var(--font-sans);
  max-width: min(560px, calc(100vw - 32px));
  padding: 30px;
  border: 1px solid #c4d6dc;
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
}
.demo-join-dialog h2 {
  font-size: 26px;
}
.demo-join-dialog blockquote {
  margin: 0;
  background: #eef5f8;
  border-left: 3px solid #337f83;
  padding: 18px;
  border-radius: 8px;
}
.demo-lock-symbol {
  width: 52px;
  height: 52px;
  background: #eaf2f6;
  display: grid;
  place-items: center;
  border-radius: 12px;
}
.demo-subjects.single-topic {
  grid-template-columns: 1fr;
}
.single-topic .demo-card-art {
  float: right;
  width: min(300px, 38%);
  margin-left: 24px;
}
.single-topic .demo-lesson-list {
  clear: both;
}
.demo-memory-link {
  margin-top: 20px;
}
.demo-notes > section,
.demo-math-memory > section {
  margin: 22px 0;
}
.demo-notes-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.demo-math-memory > section {
  padding: 22px;
  background: white;
  border: 1px solid #d4e3e8;
  border-radius: 14px;
}
.demo-math-memory article {
  border-top: 1px solid #dce6ea;
  padding-top: 16px;
  margin-top: 16px;
}
.demo-before-example {
  background: #eef5f8;
  border: 1px solid #c9dce4;
  border-radius: 12px;
  padding: 18px;
  margin: 18px 0;
}
.demo-before-example summary {
  cursor: pointer;
  font-weight: 750;
}
.demo-math-builder {
  border: 1px solid #c1d5dc;
  border-radius: 12px;
  padding: 18px;
  margin-bottom: 18px;
}
.demo-math-builder legend {
  font-weight: 750;
}
.demo-math-builder label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 12px 0;
}
.demo-math-builder input {
  width: 100%;
  border: 1px solid #8eafb9;
  border-radius: 8px;
  padding: 12px;
  background: white;
}
.demo-answer-preview {
  border-top: 1px solid #cadce2;
  padding-top: 16px;
  overflow-wrap: anywhere;
}
.demo-page .demo-lesson-switcher {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.demo-lesson-switcher button {
  text-align: left;
  justify-content: flex-start;
}
.demo-page h3 {
  white-space: pre-line;
}
@media (max-width: 620px) {
  .demo-page .demo-lesson-switcher {
    grid-template-columns: 1fr;
  }
}
.demo-notes .bio-memory {
  margin-bottom: 24px;
}
.demo-notes .memory-map-kicker {
  font-size: 14px;
}
@media (max-width: 1000px) {
  .demo-topic-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .demo-catalogue-heading {
    align-items: start;
    flex-direction: column;
    gap: 12px;
  }
}
@media (max-width: 620px) {
  .demo-topic-grid {
    grid-template-columns: 1fr;
  }
  .demo-catalogue-tabs [data-slot='tabs-trigger'] {
    font-size: 16px;
    flex-direction: column;
    gap: 2px;
    padding: 10px 4px;
  }
  .demo-notes-heading {
    align-items: start;
    flex-direction: column;
  }
  .single-topic .demo-card-art {
    float: none;
    width: 100%;
    margin: 0 0 20px;
  }
}
@media print {
  .demo-topbar,
  .demo-toolbar,
  .demo-notes-heading > button,
  .demo-privacy {
    display: none !important;
  }
  .demo-notes section {
    break-inside: auto;
    box-shadow: none;
  }
  .demo-notes h2,
  .demo-notes h3 {
    break-after: avoid;
  }
  .demo-notes figure,
  .demo-notes svg,
  .demo-notes .memory-map-panel {
    break-inside: avoid;
  }
  .demo-page,
  .demo-shell {
    background: white;
    padding: 0;
  }
}
