.course-tool-context { display: none; }

html[data-course-tool-embed="true"] body { overflow: auto; }
html[data-course-tool-embed="true"] .app { min-height: 100vh; height: auto; }
html[data-course-tool-embed="true"] .topbar { display: none !important; }
html[data-course-tool-embed="true"] .course-tool-context {
  display: block;
  margin: .75rem clamp(.75rem, 2vw, 1.5rem) 0;
  padding: .8rem 1rem;
  border: 2px solid #b8d8ff;
  border-radius: 14px;
  background: #eef7ff;
  color: #14304f;
}
html[data-course-tool-embed="true"] .course-tool-context[hidden] { display: none !important; }
html[data-course-tool-embed="true"] .course-tool-context strong { display: block; font-size: 1.05rem; }
html[data-course-tool-embed="true"] .course-tool-context p { margin: .35rem 0 0; }
html[data-course-tool-embed="true"] .course-tool-return { display:inline-flex;min-height:42px;align-items:center;margin-top:.65rem;padding:.35rem .75rem;border:2px solid #0878a8;border-radius:8px;background:#0878a8;color:#fff;font-weight:800;text-decoration:none; }
html[data-course-tool-embed="true"] #randomButton,
html[data-course-tool-embed="true"] #newQuestionButton,
html[data-course-tool-embed="true"] #wmNewButton,
html[data-course-tool-embed="true"] #wmPrintWorksheetButton,
html[data-course-tool-embed="true"] #ebNewButton,
html[data-course-tool-embed="true"] #ebResetButton,
html[data-course-tool-embed="true"] #ebPrintWorksheetButton,
html[data-course-tool-embed="true"] #ebSolutionButton,
html[data-course-tool-embed="true"] .eb-mode-group,
html[data-course-tool-embed="true"] .eb-structure-field,
html[data-course-tool-embed="true"] #revealAnswerButton,
html[data-course-tool-embed="true"] [data-random],
html[data-course-tool-embed="true"] [data-new-question],
html[data-course-tool-embed="true"] [data-reveal-answer] { display: none !important; }
html[data-course-tool-embed="true"] details:has(.questions-panel),
html[data-course-tool-embed="true"] .mode-controls,
html[data-course-tool-embed="true"] .stat-toggle,
html[data-course-tool-embed="true"] #totalsToggle,
html[data-course-tool-embed="true"] label[for="stackCountInput"],
html[data-course-tool-embed="true"] #stackCountInput { display: none !important; }
html[data-course-tool-embed="true"] details:has(.question-type-toggle),
html[data-course-tool-embed="true"] #printWorksheetButton,
html[data-course-tool-embed="true"] #questionsMenu,
html[data-course-tool-embed="true"]:has(#coordinateGridModel) #clearButton { display: none !important; }

html[data-course-tool-surface="session-teach"],
html[data-course-tool-surface="session-teach"] body { width:100%; height:100%; min-height:0; overflow:hidden; }
html[data-course-tool-surface="session-teach"] body { background:#fff; }
html[data-course-tool-surface="session-teach"] .app { width:100%; height:100%; min-height:0; overflow:hidden; }
/* The Session Player prompt owns the visible learning instruction. Keep each
   registered model caption in the accessibility tree without repeating it on
   the classroom board. Standalone tools do not carry this surface marker. */
html[data-course-tool-surface="session-teach"] figure.question-visual > figcaption {
  position:absolute !important;
  width:1px !important;
  height:1px !important;
  padding:0 !important;
  margin:-1px !important;
  overflow:hidden !important;
  clip:rect(0,0,0,0) !important;
  clip-path:inset(50%) !important;
  white-space:nowrap !important;
  border:0 !important;
}
html[data-course-tool-surface="session-teach"] .course-tool-context {
  margin:0;
  padding:.38rem .7rem;
  border-width:0 0 1px;
  border-radius:0;
}
html[data-course-tool-surface="session-teach"] .course-tool-context strong {
  font-size:clamp(1.25rem,2.5vw,1.55rem); line-height:1.16;
  white-space:normal; overflow-wrap:anywhere;
}
html[data-course-tool-surface="session-teach"] .course-tool-context p,
html[data-course-tool-surface="session-teach"] .course-tool-return { display:none !important; }
html[data-course-tool-surface="session-teach"] .course-tool-session-actions {
  display:flex; flex:0 0 auto; align-items:stretch; justify-content:flex-start;
  order:2; gap:7px; flex-wrap:nowrap; margin:0 0 0 auto;
}
html[data-course-tool-surface="session-teach"] .course-tool-session-action {
  min-height:48px; padding:6px 10px; border:1px solid #9fb8c8; border-radius:8px;
  background:#fff; color:#102131; font:800 clamp(.72rem,1.35vw,.9rem)/1.05 Arial,sans-serif; cursor:pointer;
}
html[data-course-tool-surface="session-teach"] .course-tool-session-action:hover,
html[data-course-tool-surface="session-teach"] .course-tool-session-action:focus-visible {
  outline:4px solid rgba(20,155,215,.24); outline-offset:1px;
}
html[data-course-tool-surface="session-teach"] .course-tool-session-action { font-size:1rem; }
html[data-course-tool-surface="session-teach"] .course-tool-session-mode[aria-pressed="true"] {
  border-color:#0878a8; background:#ccefff; color:#052b42;
}
html[data-course-tool-surface="session-teach"] .course-tool-session-mode-picker {
  min-width:0; min-height:48px; display:flex; align-items:center; overflow:hidden;
  border:1px solid #9fb8c8; border-radius:8px; background:#fff; color:#102131;
  font:800 1rem/1.05 Arial,sans-serif;
}
html[data-course-tool-surface="session-teach"] .course-tool-session-mode-picker > span {
  padding:0 7px; color:#365364;
}
html[data-course-tool-surface="session-teach"] .course-tool-session-mode-select {
  min-width:0; height:46px; padding:4px 30px 4px 8px; border:0; border-left:1px solid #c4d4dd;
  background:#fff; color:#102131; font:800 1rem/1.05 Arial,sans-serif; cursor:pointer;
}
html[data-course-tool-surface="session-teach"] .course-tool-session-mode-select:focus-visible {
  outline:4px solid rgba(20,155,215,.28); outline-offset:-4px;
}
html[data-course-tool-surface="session-teach"] [data-place-value-control-profile="programme-scaling-teach"] .course-tool-session-actions {
  order:0; margin-left:auto;
}
html[data-course-tool-surface="session-teach"] [data-place-value-control-profile="programme-scaling-teach"] #calcBtn { order:1; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) #gattegnoChartTool {
  height:100%; min-height:0; display:grid; grid-template-rows:auto minmax(0,1fr); gap:7px; padding:7px;
}
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) #gattegnoChartTool > .course-tool-session-actions {
  width:100%; margin:0; order:0;
}
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .gattegno-interactive,
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .gattegno-model-host,
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .question-visual,
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .diagram-frame,
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) svg { min-height:0; height:100%; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .question-visual { width:100%; margin:0; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) svg.diagram-visual { width:100% !important; max-width:none !important; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .gattegno-interactive { display:grid; grid-template-rows:minmax(0,1fr) auto; overflow:hidden; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .gattegno-relationship { margin:4px 8px; font:800 clamp(1.05rem,2vw,1.35rem)/1.15 Arial,sans-serif; text-align:center; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) figcaption { position:absolute; left:-10000px; width:1px; height:1px; overflow:hidden; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .gattegno-place-label { font-size:18px !important; font-weight:800; }
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .gattegno-value,
html[data-course-tool-surface="session-teach"]:has(#gattegnoChartTool) .gattegno-change { font-size:14px !important; font-weight:800; }
html[data-course-tool-surface="session-teach"] .rnc-app > .course-tool-context {
  margin:0; padding:6px 12px; border:0; border-bottom:1px solid #c9dbe6; border-radius:0; background:#eef7ff;
}
html[data-course-tool-surface="session-teach"] .rnc-app > .course-tool-context strong {
  font-size:clamp(1.15rem,1.9vw,1.3rem); line-height:1.08; white-space:nowrap; overflow-wrap:normal;
}
html[data-course-tool-surface="session-teach"] #printWorksheetButton,
html[data-course-tool-surface="session-teach"] #rnlPrintWorksheet,
html[data-course-tool-surface="session-teach"] .nrg-worksheet-button { display:none !important; }

/* Session Players own task selection. Embedded tools expose only the
   interaction needed to teach the preloaded, reviewed example. */
html[data-course-tool-surface="session-teach"] .rnc-choice-field,
html[data-course-tool-surface="session-teach"] .rnc-select-label,
html[data-course-tool-surface="session-teach"] .rnc-target-field,
html[data-course-tool-surface="session-teach"] .rnc-repair-config,
html[data-course-tool-surface="session-teach"] #rncApplyTarget,
html[data-course-tool-surface="session-teach"] #rncNew,
html[data-course-tool-surface="session-teach"] #rncClear,
html[data-course-tool-surface="session-teach"] .rnc-prompt-card { display:none !important; }
html[data-course-tool-surface="session-teach"]:has(#romanNumeralComposerModel) .app {
  grid-template-rows:minmax(0,1fr) !important;
}
html[data-course-tool-surface="session-teach"] #romanNumeralComposerModel { height:100%; min-height:0; }
html[data-course-tool-surface="session-teach"] .rnc-app {
  min-height:0 !important; height:100% !important; display:grid !important;
  grid-template-rows:auto auto minmax(0,1fr) !important; overflow:hidden;
}
html[data-course-tool-surface="session-teach"] .rnc-toolbar { min-height:0; justify-content:flex-start; padding:5px 8px; }
html[data-course-tool-surface="session-teach"] .rnc-toolbar-actions { flex:0 1 auto; }
html[data-course-tool-surface="session-teach"] .rnc-workspace {
  height:100%; gap:7px; padding:7px;
  grid-template-columns:minmax(250px,.52fr) minmax(0,1.48fr) !important;
  grid-template-rows:minmax(0,1fr) !important;
}
html[data-course-tool-surface="session-teach"] .rnc-work-panel { overflow:hidden; padding:8px; }
html[data-course-tool-surface="session-teach"] .rnc-response-card { margin-bottom:5px; padding:7px; }
html[data-course-tool-surface="session-teach"] .rnc-step-heading {
  gap:5px;
  margin-bottom:8px;
  padding-bottom:7px;
}
html[data-course-tool-surface="session-teach"] .rnc-step-heading span {
  font-size:clamp(.92rem,1.65vw,1.08rem); line-height:1.08;
}
html[data-course-tool-surface="session-teach"] .rnc-step-heading strong {
  font-size:clamp(1.16rem,2.05vw,1.36rem); line-height:1.12;
}
html[data-course-tool-surface="session-teach"] .rnc-numeric-entry label,
html[data-course-tool-surface="session-teach"] .rnc-roman-entry-heading > p,
html[data-course-tool-surface="session-teach"] .rnc-combine-entry > p {
  font-size:clamp(1rem,1.8vw,1.16rem); line-height:1.15;
}
html[data-course-tool-surface="session-teach"] .rnc-numeric-entry label {
  gap:clamp(9px,1.3vh,12px);
}
html[data-course-tool-surface="session-teach"] .rnc-combine-entry > p {
  margin-bottom:7px;
}
html[data-course-tool-surface="session-teach"] .rnc-roman-entry {
  display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:5px;
}
html[data-course-tool-surface="session-teach"] .rnc-roman-entry-heading {
  grid-column:1/-1; justify-content:flex-end; margin:0;
}
html[data-course-tool-surface="session-teach"] .rnc-roman-entry-heading > p { display:none; }
html[data-course-tool-surface="session-teach"] .rnc-group-token { min-height:54px; }
html[data-course-tool-surface="session-teach"] .rnc-attempt-row {
  gap:5px 8px; margin-top:7px; padding-top:7px;
}
html[data-course-tool-surface="session-teach"] .rnc-attempt {
  min-width:0; overflow:hidden; white-space:nowrap; overflow-wrap:normal;
  font-size:clamp(.95rem,1.65vw,1.2rem); letter-spacing:.03em;
}
html[data-course-tool-surface="session-teach"] #rncUndoWhole {
  min-width:90px; padding-inline:10px;
}
html[data-course-tool-surface="session-teach"] .rnc-roman-entry-heading > p,
html[data-course-tool-surface="session-teach"] .rnc-symbol-values-toggle {
  min-width:0;
}
html[data-course-tool-surface="session-teach"] .rnc-symbol-values-toggle {
  white-space:normal;
}
html[data-course-tool-surface="session-teach"] .rnc-numeric-entry input {
  font-size:clamp(1.35rem,2.4vw,1.6rem);
}
html[data-course-tool-surface="session-teach"] .rnc-current-entry {
  grid-column:1/-1; min-height:44px; margin:0;
}
html[data-course-tool-surface="session-teach"] .rnc-palette { display:contents; }
html[data-course-tool-surface="session-teach"] .rnc-symbol-button {
  min-width:0; min-height:44px; padding:2px;
}
html[data-course-tool-surface="session-teach"] .rnc-symbol-button span {
  font-size:clamp(1.35rem,2.15vw,1.6rem);
}
html[data-course-tool-surface="session-teach"] .rnc-undo {
  width:auto; min-width:0; min-height:44px; margin:0; padding:0;
  font-size:1.65rem; line-height:1;
}
html[data-course-tool-surface="session-teach"] .rnc-feedback:empty,
html[data-course-tool-surface="session-teach"] .rnc-feedback[data-tone="success"] {
  display:none;
}
html[data-course-tool-surface="session-teach"] .rnc-symbol-values-toggle,
html[data-course-tool-surface="session-teach"] .rnc-group-token small {
  font-size:clamp(.9rem,1.55vw,1rem); line-height:1.1;
}
html[data-course-tool-surface="session-teach"] .rnc-hint {
  margin-top:5px; font-size:clamp(1rem,1.75vw,1.12rem); line-height:1.18;
}
html[data-course-tool-surface="session-teach"] .rnc-feedback {
  min-height:44px; margin-top:3px; padding:6px 8px;
  font-size:clamp(1rem,1.75vw,1.12rem); line-height:1.18;
}
html[data-course-tool-surface="session-teach"] .rnc-model-panel { min-height:0 !important; height:auto !important; overflow:hidden; padding:6px; }
html[data-course-tool-surface="session-teach"] .rnc-model-host,
html[data-course-tool-surface="session-teach"] .rnc-model-host .diagram-frame,
html[data-course-tool-surface="session-teach"] .rnc-model-host svg { min-height:0; }
html[data-course-tool-surface="session-teach"] .rnc-model-host .question-visual,
html[data-course-tool-surface="session-teach"] .rnc-model-host .diagram-frame {
  width:100%; height:100% !important; min-height:0; overflow:hidden;
}
html[data-course-tool-surface="session-teach"] .rnc-model-host .question-visual {
  display:flex; align-items:center; justify-content:center;
}
html[data-course-tool-surface="session-teach"] .rnc-model-host svg {
  width:100% !important; height:100% !important; max-height:100% !important;
}
html[data-course-tool-surface="session-teach"] .rnc-step-heading span,
html[data-course-tool-surface="session-teach"] .rnc-group-token small {
  font-size:max(1rem,1.65vw);
}
html[data-course-tool-surface="session-teach"] .rnc-work-panel p {
  font-size:max(1rem,1.8vw);
}
html[data-course-tool-surface="session-teach"] .rnc-model-host .roman-part-whole-title {
  font-size:24px !important;
}
html[data-course-tool-surface="session-teach"] .rnc-model-host .roman-part-whole-label {
  font-size:22px !important;
}
html[data-course-tool-surface="session-teach"] .rnc-model-host .roman-paired-equivalence {
  font-size:22px !important;
}

html[data-course-tool-surface="session-teach"] .nrg-number-entry,
html[data-course-tool-surface="session-teach"] .nrg-menu { display:none !important; }
html[data-course-tool-surface="session-teach"] .nrg-toolbar { min-height:0; justify-content:flex-end; padding:5px 8px; }
html[data-course-tool-surface="session-teach"] .nrg-history-controls { margin-left:0; }
html[data-course-tool-surface="session-teach"] .nrg-workspace { padding:6px 8px; }
html[data-course-tool-surface="session-teach"] .nrg-button { font-size:1rem; }
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-number-words-profile="true"] #numberWordsPrompt,
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-number-words-profile="true"] #numberWordsNewButton {
  display:none !important;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-practice-actions-in-toolbar="true"] .nrg-number-words-toolbar {
  display:none !important;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-practice-actions-in-toolbar="true"] .nrg-practice {
  display:contents;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-practice-actions-in-toolbar="true"] .nrg-toolbar > .nrg-practice-actions {
  grid-column:auto;
  order:1;
  min-width:0;
  justify-content:flex-end;
  flex-wrap:nowrap;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-practice-actions-in-toolbar="true"] .nrg-toolbar > .nrg-practice-actions .nrg-button {
  min-width:100px;
}
@media (min-width:880px) {
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .nrg-toolbar {
    display:grid;
    grid-template-columns:minmax(260px,280px) minmax(300px,1fr) auto;
    align-items:center;
    gap:6px;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .nrg-activity-select {
    width:auto;
    max-width:none;
    min-width:0;
    align-self:center;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .nrg-number-words-toolbar,
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .nrg-direction-switch,
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .nrg-segmented-control {
    width:100%;
    min-width:0;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .nrg-segmented-control label {
    min-width:0;
    flex:1 1 0;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .nrg-segmented-control label > span {
    width:100%;
    padding-inline:6px;
    white-space:nowrap;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .course-tool-session-actions {
    margin-left:0;
    gap:6px;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel .course-tool-session-action {
    box-sizing:border-box;
    height:48px;
    padding-inline:4px;
    white-space:nowrap;
  }
}
html[data-course-tool-surface="session-teach"] .number-representation-grid-visual .number-representation-row-label {
  font-size:27px !important; font-weight:900; text-anchor:end;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-toolbar {
  display:flex;
  align-items:stretch;
  justify-content:flex-end;
  gap:7px;
  min-height:58px;
  padding-block:5px;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-toolbar > :not(.course-tool-session-actions):not([data-nrg-toolbar-partition-actions="true"]) {
  display:none !important;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-toolbar > .course-tool-session-actions {
  order:0;
  margin:0;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-toolbar > [data-nrg-toolbar-partition-actions="true"] {
  order:1;
  flex:1 1 auto;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-toolbar > [data-nrg-toolbar-partition-actions="true"] .nrg-button {
  padding-inline:5px;
  font-size:clamp(.9rem,1.25vw,1rem);
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-workspace {
  padding-top:8px;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-session-partition-comparison p {
  font-size:clamp(1.18rem,2.3vw,1.55rem);
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-model-host .number-representation-grid-visual {
  height:100% !important;
  max-height:100% !important;
}
html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-model-layout {
  height:auto;
  align-self:stretch;
}
@media (max-width:560px) {
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-toolbar {
    flex-wrap:wrap;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-toolbar > [data-nrg-toolbar-partition-actions="true"] {
    flex:1 1 100%;
  }
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-model-scroll,
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-model-host,
  html[data-course-tool-surface="session-teach"] #numberRepresentationGridModel[data-nrg-session-partitioning="true"] .nrg-model-host .question-visual {
    height:100% !important;
    min-height:0 !important;
    max-height:100% !important;
  }
}

/* A full denomination cannot remain board-readable inside a 12-28px counter.
   The adjacent place-value heading owns that label on Session Player screens. */
html[data-course-tool-surface="session-teach"] .place-value-counter-label { display:none; }

html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .app {
  height:100vh !important; height:100dvh !important; min-height:0 !important;
  grid-template-rows:max-content max-content minmax(0,1fr) !important;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) #placeValueCountersModel {
  width:100%; min-width:0; display:grid !important; grid-row:3; height:auto; min-height:0;
  grid-template-rows:auto minmax(0,1fr);
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) body { overflow:hidden; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .toolbar { width:100%; min-width:0; min-height:0; padding:5px 8px; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .toolbar-right,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .toolbar-left > .tool-menu,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) #rowBButton,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) #clearButton,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .panel-heading,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .side-card { display:none !important; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .workspace { width:100%; min-width:0; padding:6px; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .pvc-stage {
  width:100%; min-width:0; grid-template-columns:1fr; grid-template-rows:auto minmax(0,1fr); gap:6px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette { display:block; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-list,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-list.is-dense {
  height:auto; grid-template-columns:repeat(auto-fit,minmax(92px,1fr)); grid-auto-rows:54px; gap:4px; padding:4px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-button { min-height:54px; height:54px; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-counter-visual { width:34px; height:34px; flex-basis:34px; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-more-less {
  min-height:54px; height:54px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-more-less .palette-exchange-value {
  min-width:0; min-height:0; padding:2px 4px; gap:4px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-regroup {
  min-height:54px; height:54px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-regroup .palette-exchange-value {
  min-width:0; min-height:0; padding:2px 4px; gap:4px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar:has(.course-tool-session-actions[data-session-action-layout="single-row"]),
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar:has(.course-tool-session-actions[data-session-action-layout="single-row"]) .toolbar-left,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar:has(.course-tool-session-actions[data-session-action-layout="single-row"]) .control-group,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-actions[data-session-action-layout="single-row"] {
  flex-wrap:nowrap; gap:5px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar:has(.course-tool-session-actions[data-session-action-layout="single-row"]) .wide-button {
  min-height:48px; padding-inline:5px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-actions[data-session-action-layout="single-row"] {
  min-width:0; margin-left:auto;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-mode-picker {
  flex:1 1 205px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-mode-select {
  width:145px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-actions[data-session-action-layout="single-row"] .course-tool-session-action {
  padding-inline:8px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-list,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-list.is-dense {
  grid-template-columns:repeat(auto-fit,minmax(130px,1fr));
}
@media (min-width:481px) {
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-exchange-card {
    grid-template-columns:minmax(0,1fr) 34px 34px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-exchange-value {
    padding-inline:4px; gap:4px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-counter-visual {
    width:28px; height:28px; flex-basis:28px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-exchange-label small {
    display:none;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-exchange-step {
    min-width:34px; min-height:44px; font-size:1.1rem;
  }
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .chart-scroll { overflow:hidden; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .place-chart,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .place-chart.shared-place-value-chart { min-width:0; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .workspace,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .pvc-stage,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .chart-card,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .chart-scroll,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .place-chart { min-height:0; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .workspace {
  height:auto; overflow:hidden;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .pvc-stage,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .chart-scroll,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .place-chart { height:100% !important; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .pvc-stage { height:100% !important; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .place-chart > figure {
  box-sizing:border-box; width:100%; height:100%; min-height:0; margin:0; padding:6px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .place-chart > figure > svg {
  width:100%; height:100%; max-height:100%;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-more-less="true"]) .place-value-chart-header-label {
  font-size:18px !important; font-weight:800 !important;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .workspace,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .pvc-stage,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .chart-card,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .chart-scroll,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .place-chart { min-height:0; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .workspace {
  height:100%; overflow:hidden;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .pvc-stage,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .chart-scroll,
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .place-chart { height:100% !important; }
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .place-chart > figure {
  box-sizing:border-box; width:100%; height:100%; min-height:0; margin:0; padding:6px;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .place-chart > figure > svg {
  width:100%; height:100%; max-height:100%;
}
html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .place-value-chart-header-label {
  font-size:18px !important; font-weight:800 !important;
}

@media (max-width:480px) {
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .toolbar,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .toolbar-left { flex-wrap:nowrap; gap:3px; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar-left,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-actions {
    flex-wrap:wrap;
    max-width:100%;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar {
    display:grid;
    grid-template-columns:minmax(0,1fr);
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar-left,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .control-group {
    width:100%; min-width:0;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .control-group {
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .toolbar-left .wide-button {
    min-width:0; min-height:42px; padding-inline:3px; white-space:normal; font-size:.8rem;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-actions {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto auto;
    flex:1 1 100%;
    width:100%;
    margin-left:0;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-action {
    flex:1 1 auto;
    min-width:0;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-mode-picker {
    width:100%; min-width:0; flex:1 1 100%;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-mode-picker > span { display:none; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .course-tool-session-mode-select {
    width:100%; min-width:0; flex:1 1 auto; border-left:0; font-size:.82rem;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) #undoButton,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) #redoButton,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .display-strip { display:none !important; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .toolbar-left .small-button { min-height:40px; padding:0 7px; font-size:.78rem; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-list,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-list.is-dense {
    grid-template-columns:repeat(7,minmax(0,1fr));
    grid-auto-rows:42px;
    height:42px;
    gap:2px;
    padding:2px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-button { min-width:0; height:42px; padding:1px; gap:2px; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-counter-visual { width:22px; height:22px; flex-basis:22px; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-button > span:last-child { font-size:.68rem; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-more-less {
    min-height:42px; height:42px; grid-template-columns:minmax(0,1fr) 18px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-more-less .palette-exchange-value {
    padding:1px; gap:1px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-more-less .palette-exchange-label strong { font-size:.62rem; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-more-less .palette-exchange-label small { display:none; }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel) .palette-exchange-card.is-session-more-less .palette-exchange-step {
    min-width:18px; width:18px; font-size:.58rem;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-list,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-list.is-dense {
    grid-template-columns:repeat(2,minmax(0,1fr));
    grid-auto-rows:54px;
    height:auto;
    gap:3px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-exchange-card {
    grid-template-columns:minmax(0,1fr) 40px 40px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-unitise="true"]) .palette-exchange-step {
    min-width:40px; min-height:40px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .palette {
    display:none;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .toolbar {
    display:grid; grid-template-columns:minmax(0,1fr); gap:4px;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .toolbar-left,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .control-group,
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .course-tool-session-actions {
    width:100%; min-width:0;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .toolbar-left {
    order:1;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .control-group {
    display:grid; grid-template-columns:repeat(3,minmax(0,1fr));
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) .course-tool-session-actions {
    order:2; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); margin-left:0;
  }
  html[data-course-tool-surface="session-teach"]:has(#placeValueCountersModel[data-place-value-session-regroup="true"]) #undoButton {
    display:inline-flex !important;
  }
}

html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .brand-panel,
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .controls > :not(.locate-controls):not(.hint):not(.course-tool-session-actions),
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .locate-controls > .field,
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #locateNew { display:none !important; }
html[data-course-tool-surface="session-teach"] body:has(#number-lineModel) {
  display:grid; grid-template-rows:auto minmax(0,1fr);
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #number-lineModel {
  height:100%; min-height:0; overflow:hidden;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .wrap {
  width:100%; height:100%; min-height:0; display:grid; grid-template-rows:auto minmax(0,1fr); overflow:hidden;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .header { display:contents; }
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .header .controls {
  min-width:0; display:flex; justify-content:flex-end; padding:5px 8px;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .locate-controls { display:flex !important; gap:8px; }
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .hint:not(:empty) {
  display:flex !important;
  flex:1 1 360px;
  min-width:260px;
  font-size:1rem;
  line-height:1.25;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #breadcrumb { display:none !important; }
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .stage {
  width:calc(100% - 12px); height:calc(100% - 12px); min-height:0; display:grid; grid-template-rows:minmax(0,1fr); margin:6px; padding:8px; overflow:hidden;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .canvas {
  height:100%; min-height:0; display:flex; align-items:center; justify-content:center; overflow:hidden;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #modelHost,
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #modelHost .zooming-number-line-model {
  width:100%; height:100%; min-height:0; display:flex; align-items:center; justify-content:center;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #modelHost .diagram-visual {
  width:100% !important; height:100% !important; max-width:100% !important; max-height:100% !important;
}

html[data-course-tool-surface="session-teach"] .con-toolbar {
  display:flex !important; min-height:0; justify-content:flex-start; padding:5px 8px;
}
html[data-course-tool-surface="session-teach"] .con-toolbar > .con-toolbar-group { display:none !important; }
html[data-course-tool-surface="session-teach"] .con-toolbar:has(.con-session-response-actions) {
  align-items:center; gap:7px; flex-wrap:nowrap;
}
html[data-course-tool-surface="session-teach"] .con-session-response-actions { order:0; }
html[data-course-tool-surface="session-teach"] .con-toolbar:has(.con-session-response-actions) > .course-tool-session-actions {
  order:1; margin:0;
}
html[data-course-tool-surface="session-teach"] .con-session-workspace {
  grid-template-columns:minmax(0,1fr); grid-template-rows:auto minmax(0,1fr);
}
html[data-course-tool-surface="session-teach"]:has(#compareOrderNumbersModel) .con-model-stack.is-count-2 {
  grid-template-rows:minmax(0,1.55fr) minmax(88px,.45fr);
}
html[data-course-tool-surface="session-teach"] .con-prompt h2 { font-size:1.35rem; }
html[data-course-tool-surface="session-teach"] .con-prompt p,
html[data-course-tool-surface="session-teach"] .con-model-guide,
html[data-course-tool-surface="session-teach"] .con-reveal-answer { font-size:1rem; }
html[data-course-tool-surface="session-teach"] .con-kicker { font-size:1rem; }
html[data-course-tool-surface="session-teach"] .place-comparison-heading { font-size:16px !important; }
html[data-course-tool-surface="session-teach"] .place-comparison-digit { font-size:16px !important; }
html[data-course-tool-surface="session-teach"] .place-comparison-number-label { font-size:16px !important; }
html[data-course-tool-surface="session-teach"] .place-comparison-highlight-label { font-size:16px !important; }
html[data-course-tool-surface="session-teach"] .comparison-sentence-term-label,
html[data-course-tool-surface="session-teach"] .comparison-sentence-visual.is-expanded .comparison-sentence-term-label { font-size:15px !important; }

html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #modelHost .zoom-line-value {
  font-size:12px !important;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #modelHost .compact-wide-scale-labels .zoom-line-value {
  font-size:11px !important;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #modelHost .zoom-line-marker-label {
  font-size:16px !important;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) #modelHost .zoom-line-benchmark-label {
  font-size:10px !important;
}
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .msg,
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .t-title,
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .t-body,
html[data-course-tool-surface="session-teach"]:has(#number-lineModel) .toast button { font-size:1rem; }

html[data-course-tool-surface="session-teach"] .rnl-prompt,
html[data-course-tool-surface="session-teach"] .rnl-step[disabled],
html[data-course-tool-surface="session-teach"] .rnl-step.is-locked,
html[data-course-tool-surface="session-teach"] .rnl-step.is-complete { display:none !important; }
html[data-course-tool-surface="session-teach"] .rnl-toolbar {
  display:flex !important; min-height:0; justify-content:flex-start; padding:5px 8px;
}
html[data-course-tool-surface="session-teach"] .rnl-toolbar > :not(.course-tool-session-actions) { display:none !important; }
html[data-course-tool-surface="session-teach"] .rnl-tool { min-height:0 !important; height:100% !important; grid-template-rows:auto minmax(0,1fr); }
html[data-course-tool-surface="session-teach"] .rnl-workspace { gap:7px; padding:7px; }
html[data-course-tool-surface="session-teach"] .rnl-reasoning,
html[data-course-tool-surface="session-teach"] .rnl-model-panel { overflow:hidden; padding:8px; }
html[data-course-tool-surface="session-teach"] .rnl-model-host,
html[data-course-tool-surface="session-teach"] .rnl-model-host .diagram-frame,
html[data-course-tool-surface="session-teach"] .rnl-model-host svg { min-height:0; }
html[data-course-tool-surface="session-teach"] .rnl-step label { font-size:1rem; }
html[data-course-tool-surface="session-teach"] .rnl-model-host .rounding-line-label { font-size:17px !important; }
html[data-course-tool-surface="session-teach"] .rnl-model-host .rounding-line-point-label { font-size:19px !important; }
html[data-course-tool-surface="session-teach"] .rnl-model-host .rounding-line-arrow-label,
html[data-course-tool-surface="session-teach"] .rnl-model-host .rounding-line-distances text { font-size:16px !important; }

/* The signed-scale Session Player owns the example, stage navigation and
   teacher configuration. Keep the exact current prompt and the model's
   pupil-facing interaction, while removing the standalone tool chrome. */
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) #negativeNumberLineModel,
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .negative-number-lab {
  height:100%; min-height:0; overflow:hidden;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-toolbar {
  display:flex !important; min-height:0; justify-content:flex-start; padding:5px 8px;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-toolbar > :not(.course-tool-session-actions):not(.nnl-session-representation-toggle) {
  display:none !important;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-session-representation-toggle {
  min-width:0;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-session-representation-toggle .nnl-button {
  min-height:44px; padding-inline:12px;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .course-tool-session-actions {
  margin-left:auto;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-workspace {
  gap:7px; padding:7px;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-pupil-panel {
  overflow:hidden; padding:8px;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-model-panel {
  overflow:hidden; padding:4px;
}
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-model-panel,
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-representations,
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-representation,
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-model-panel figure,
html[data-course-tool-surface="session-teach"]:has(#negativeNumberLineModel) .nnl-model-panel svg {
  min-height:0;
}

@media (max-width: 700px) {
  html[data-course-tool-embed="true"] .course-tool-context { margin: .5rem; padding: .7rem .8rem; }
  html[data-course-tool-surface="session-teach"] .course-tool-context { margin:0; padding:.32rem .55rem; }
  html[data-course-tool-surface="session-teach"] .rnc-app > .course-tool-context strong { white-space:normal; overflow-wrap:anywhere; }
  html[data-course-tool-surface="session-teach"] .course-tool-session-actions { gap:4px; }
  html[data-course-tool-surface="session-teach"] .course-tool-session-action { min-height:44px; padding:4px 5px; font-size:clamp(.62rem,2.7vw,.72rem); }
  html[data-course-tool-surface="session-teach"] .con-toolbar:has(.con-session-response-actions) { gap:4px; }
  html[data-course-tool-surface="session-teach"] .con-session-response-actions { gap:4px; }
  html[data-course-tool-surface="session-teach"] .con-session-response-actions .con-button { min-height:44px; padding-inline:5px; font-size:clamp(.62rem,2.7vw,.72rem); }
  html[data-course-tool-surface="session-teach"] .rnc-app { height:auto !important; min-height:100% !important; overflow:visible; }
  html[data-course-tool-surface="session-teach"] .rnc-workspace {
    height:auto; min-height:0; grid-template-columns:1fr !important; grid-template-rows:auto minmax(620px,1fr) !important;
  }
  html[data-course-tool-surface="session-teach"] .rnc-work-panel { overflow:visible; }
  html[data-course-tool-surface="session-teach"] .rnc-model-panel { min-height:620px !important; }
  html[data-course-tool-surface="session-teach"] .rnc-model-host,
  html[data-course-tool-surface="session-teach"] .rnc-model-host .diagram-frame,
  html[data-course-tool-surface="session-teach"] .rnc-model-host svg { min-height:600px; }
  html[data-course-tool-surface="session-teach"] .rnl-workspace {
    height:100%; min-height:0; grid-template-columns:1fr !important; grid-template-rows:auto minmax(0,1fr); gap:5px; padding:5px;
  }
  html[data-course-tool-surface="session-teach"] .rnl-reasoning { height:auto; max-height:none; overflow:hidden; }
  html[data-course-tool-surface="session-teach"] .rnl-model-panel { min-height:0 !important; height:auto !important; overflow:hidden; }
  html[data-course-tool-surface="session-teach"] .rnl-tool[data-comparison-active="true"] { height:auto !important; min-height:100% !important; }
  html[data-course-tool-surface="session-teach"] .rnl-tool[data-comparison-active="true"] .rnl-workspace {
    height:auto; grid-template-rows:auto 360px;
  }
  html[data-course-tool-surface="session-teach"] .rnl-tool[data-comparison-active="true"] .rnl-model-panel {
    min-height:360px !important; height:360px !important;
  }
}

@media (min-width:701px) and (max-width:900px) {
  html[data-course-tool-surface="session-teach"] .con-workspace {
    grid-template-columns:minmax(230px,.72fr) minmax(0,1.28fr);
    grid-template-rows:minmax(0,1fr);
  }
  html[data-course-tool-surface="session-teach"] .con-left-panel {
    display:flex;
  }
  html[data-course-tool-surface="session-teach"] .con-prompt,
  html[data-course-tool-surface="session-teach"] .con-model-panel,
  html[data-course-tool-surface="session-teach"] .con-response-panel {
    order:initial;
  }
  html[data-course-tool-surface="session-teach"] .con-response-panel {
    margin-top:auto;
  }
  html[data-course-tool-surface="session-teach"] .con-model-stack.is-count-2 {
    grid-template-rows:minmax(0,1.55fr) minmax(88px,.45fr);
  }

  html[data-course-tool-surface="session-teach"] .rnl-workspace {
    height:100%; min-height:0;
    grid-template-columns:minmax(260px,.78fr) minmax(0,1.22fr);
    grid-template-rows:minmax(0,1fr);
  }
  html[data-course-tool-surface="session-teach"] .rnl-reasoning,
  html[data-course-tool-surface="session-teach"] .rnl-model-panel {
    min-height:0; height:auto; overflow:hidden;
  }
}
