body:has(#soohawk-quest-demo[data-student-game]){margin:0;background:#123754}
#soohawk-quest-demo[data-student-game] .qi-preview:not(:has(.student-account)){display:none}
#soohawk-quest-demo[data-student-game] .qi-preview{position:fixed;min-height:48px;align-items:center;justify-content:flex-end;flex-wrap:nowrap;padding-top:calc(4px + env(safe-area-inset-top));padding-inline:max(clamp(15px,4vw,38px),env(safe-area-inset-left)) max(clamp(15px,4vw,38px),env(safe-area-inset-right))}
#soohawk-quest-demo[data-student-game] .student-play-brand {
  flex:none;
  margin-inline-end:auto;
  padding:0;
  font-size:clamp(20px,min(6vw,3.6svh),28px);
  letter-spacing:-.05em;
  text-shadow:0 .075em #79401c,0 .14em .08em #15324ce3;
}
#soohawk-quest-demo[data-student-game] .student-account{display:flex;align-items:center;gap:12px;min-width:0}
#soohawk-quest-demo[data-student-game] .student-account>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:35vw;font-size:14px;font-weight:650}
#soohawk-quest-demo[data-student-game] .student-signout{font:600 13px/1.2 'Segoe UI',system-ui,sans-serif;color:#f4fbff;min-height:44px;padding:3px 12px;border:1px solid #c0d8e577;background:#09233bcc;border-radius:100px}
#soohawk-quest-demo[data-student-game] .student-signout{white-space:nowrap;flex-shrink:0}
#soohawk-quest-demo[data-student-game] .student-screen{display:contents}
#soohawk-quest-demo[data-student-game] .sp-phone{padding-top:calc(54px + env(safe-area-inset-top))}
#soohawk-quest-demo[data-student-game]:not(:has(.student-account)) .sp-phone{padding-top:calc(clamp(16px,5svh,56px) + env(safe-area-inset-top))}
#soohawk-quest-demo[data-student-game] .sp-phone .sp-brand{
  font-size:clamp(36px,min(16vw,calc(16px + 5.8svh)),108px);
  letter-spacing:-.05em;
}
#soohawk-quest-demo[data-student-game] .sp-head{justify-content:space-between;gap:8px;padding-inline:14px;flex-wrap:wrap}
#soohawk-quest-demo[data-student-game] .sp-head button{min-height:42px}
#soohawk-quest-demo[data-student-game] .student-dashboard-head{display:grid;grid-template-columns:minmax(0,1fr) auto auto}
#soohawk-quest-demo[data-student-game] .student-dashboard-head .sp-profile{min-width:0;max-width:100%;justify-self:start}
#soohawk-quest-demo[data-student-game] .student-profile-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#soohawk-quest-demo[data-student-game] :is(.student-login,.student-list){position:relative;z-index:5;width:min(calc(100% - 28px),435px);margin:0 auto max(34px,8svh);padding:clamp(20px,5vw,30px);text-align:start;background:linear-gradient(135deg,#081d35ef,#153650df);border:1px solid #b3d9f08c;border-radius:23px;box-shadow:0 14px 34px #06213848}
#soohawk-quest-demo[data-student-game] .student-login h1,#soohawk-quest-demo[data-student-game] .student-list h1{font-size:clamp(26px,5.5vw,34px);margin:0 0 16px;letter-spacing:-.035em}
#soohawk-quest-demo[data-student-game] .student-login label{display:grid;gap:6px;margin:10px 0 15px;font-size:14px;font-weight:650;color:#eefaff}
#soohawk-quest-demo[data-student-game] .student-login input{font:inherit;font-size:16px;min-height:44px;width:100%;border:1px solid #a9d2e787;border-radius:10px;background:#102c43d9;color:white;padding:10px 13px}
#soohawk-quest-demo[data-student-game] .student-login input:focus-visible{outline:3px solid #ffb24c;outline-offset:2px}
#soohawk-quest-demo[data-student-game] .student-login button[type=submit]{margin-bottom:0}
/* The island takes the space left by the controls, notebook and navigation. */
#soohawk-quest-demo[data-student-game] .sp-phone[data-screen] {min-height:100dvh}
#soohawk-quest-demo[data-student-game] .sp-content {flex:1 0 auto}
#soohawk-quest-demo[data-student-game] .sp-phone[data-screen] .sp-content > .sp-world {
  flex:1 0 0px;
  height:0;
  min-height:0;
}
#soohawk-quest-demo[data-student-game] .sp-content > .sp-page:not(.student-homework) {
  margin-bottom:0;
}
#soohawk-quest-demo[data-student-game] .sp-content:has(> .sp-page:not(.student-homework))::after {
  content:"";
  flex:1 0 0px;
  max-height:clamp(14px,4svh,32px);
}
#soohawk-quest-demo[data-student-game] .sp-content:has(> .sp-page.student-login)::after {
  min-height:env(safe-area-inset-bottom);
  max-height:max(5svh,env(safe-area-inset-bottom));
}
#soohawk-quest-demo[data-student-game] .student-first-score {margin: 0 0 10px}
#soohawk-quest-demo[data-student-game] .sp-complete .sp-secondary {margin-top: 8px; min-height: 44px}
#soohawk-quest-demo[data-student-game] .student-list small{margin:6px 0 0}
#soohawk-quest-demo[data-student-game] .student-list .sp-assignment{min-height:76px}
#soohawk-quest-demo[data-student-game] .sp-phone:has(.student-homework) {
  height:100dvh;
  min-height:100dvh;
}
#soohawk-quest-demo[data-student-game] .sp-content:has(> .student-homework) {
  flex:1 1 0px;
  min-height:0;
  justify-content:center;
  padding-block:clamp(10px,3svh,48px);
}
#soohawk-quest-demo[data-student-game] .sp-phone[data-screen] .sp-content:has(> .student-homework) > .sp-world {
  position:absolute;
  inset:0;
  height:auto;
  pointer-events:none;
}
#soohawk-quest-demo[data-student-game] .sp-content > .student-homework {
  --gutter:max(14px,calc(12vw - 34px));
  display:flex;
  flex-direction:column;
  min-height:0;
  width:auto;
  margin:0 max(var(--gutter),env(safe-area-inset-right)) 0 max(var(--gutter),env(safe-area-inset-left));
  padding:clamp(14px,4.8svh,62px) clamp(16px,3.6vw,64px);
}
#soohawk-quest-demo[data-student-game] .student-homework-items {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(min(100%,19rem),1fr));
  align-content:start;
  gap:clamp(10px,1.7svh,20px);
  min-height:0;
  margin:0 -5px;
  padding:5px;
  list-style:none;
  overflow-y:auto;
  overscroll-behavior-y:contain;
  scrollbar-color:#94bdc7 #142f46;
}
#soohawk-quest-demo[data-student-game] .student-homework-items > li {min-width:0}
#soohawk-quest-demo[data-student-game] .student-homework-items .sp-assignment {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:clamp(8px,1.5vw,20px);
  margin:0;
  padding:clamp(14px,2.4svh,28px) clamp(12px,1.8vw,24px);
  overflow-wrap:anywhere;
}
#soohawk-quest-demo[data-student-game] .student-homework-items .student-past {margin:4px 0 0}
/* Leave room to reach a whole homework card even with a very short viewport. */
@media (max-height:320px) {
  #soohawk-quest-demo[data-student-game] .sp-phone:has(.student-homework) {height:auto}
  #soohawk-quest-demo[data-student-game] .sp-content:has(> .student-homework) {flex:1 0 auto}
  #soohawk-quest-demo[data-student-game] .student-homework-items {overflow-y:visible}
}
@media (orientation:landscape) and (max-height:520px) {
  #soohawk-quest-demo[data-student-game] .sp-content > .student-homework {padding-block:10px}
  #soohawk-quest-demo[data-student-game] .student-homework h1 {font-size:26px;margin-bottom:5px}
  #soohawk-quest-demo[data-student-game] .sp-nav button {flex-direction:row;min-height:44px;gap:6px}
  #soohawk-quest-demo[data-student-game] .sp-nav .sp-navemoji {font-size:18px}
}
#soohawk-quest-demo[data-student-game] .student-assignment-menu h1 {margin-bottom: 6px}
#soohawk-quest-demo[data-student-game] .student-assignment-menu > p {margin: 0 0 18px; color: #cee1ec}
#soohawk-quest-demo[data-student-game] .student-problem-actions {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  column-gap: 12px;
  margin-top: 6px;
}
#soohawk-quest-demo[data-student-game] .student-skip,
#soohawk-quest-demo[data-student-game] .student-skipped summary {
  min-height: 44px;
  padding: 12px 0;
  border: 0;
  background: transparent;
  color: #c4dbe5;
  font: 600 14px/1.4 'Segoe UI', system-ui, sans-serif;
  cursor: pointer;
}
#soohawk-quest-demo[data-student-game] .student-skip {text-decoration: underline; text-underline-offset: 3px}
#soohawk-quest-demo[data-student-game] .student-skipped[open] {flex-basis: 100%}
#soohawk-quest-demo[data-student-game] .student-skipped ul {list-style: none; margin: 0; padding: 0}
#soohawk-quest-demo[data-student-game] .student-return {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; min-height: 44px; padding: 10px 0;
  background: transparent; border: 0; border-bottom: 1px solid #718e9b82;
  color: #e4f5fc; text-align: left; font: 600 15px/1.4 'Segoe UI', system-ui, sans-serif; cursor: pointer;
}
#soohawk-quest-demo[data-student-game] .student-return span:last-child {color: #9de5d9}
#soohawk-quest-demo[data-student-game] .student-review > p {color: #d7e9ee}
#soohawk-quest-demo[data-student-game] .student-review .sp-primary {margin-top: 18px}
#soohawk-quest-demo[data-student-game] .student-assignment-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
#soohawk-quest-demo[data-student-game] .student-assignment-actions button {
  min-height: 48px;
  margin: 0;
  padding-inline: 8px;
  font-size: 16px;
}
#soohawk-quest-demo[data-student-game] .student-past{margin:6px 0 14px;text-align:left;color:#d4e5f2}
#soohawk-quest-demo[data-student-game] .student-past summary{padding:10px 5px;font-weight:650;cursor:pointer}
#soohawk-quest-demo[data-student-game] .student-past ul{margin:0;padding:0 5px;list-style:none}
#soohawk-quest-demo[data-student-game] .student-past li{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:8px 0;border-top:1px solid #91b8bc59}
#soohawk-quest-demo[data-student-game] .student-past li small{display:block;margin-top:2px}
#soohawk-quest-demo[data-student-game] .sp-nav{padding-bottom:max(10px,env(safe-area-inset-bottom))}
#soohawk-quest-demo[data-student-game] .student-summary .sp-skill h2{font-size:18px;margin-bottom:10px}
#soohawk-quest-demo[data-student-game] .student-summary .sp-skill small{display:block;margin-top:8px;font-size:13px}
#soohawk-quest-demo[data-student-game] .student-summary .sp-reward:has(+ .student-notice) {margin-bottom:0}
@media (max-height:620px) {
  #soohawk-quest-demo[data-student-game] .sp-content > .sp-page:not(.student-homework) {padding-block:clamp(12px,3svh,18px)}
  #soohawk-quest-demo[data-student-game] .student-summary .sp-reward {
    display:grid;
    grid-template-columns:auto minmax(0,1fr);
    align-items:center;
    column-gap:clamp(10px,3vw,18px);
    row-gap:4px;
    margin-block:12px;
    padding:clamp(10px,2.8svh,16px);
    text-align:start;
  }
  #soohawk-quest-demo[data-student-game] .sp-reward > :not(.sp-medal) {
    grid-column:2;
    min-width:0;
    margin-block:0;
    overflow-wrap:anywhere;
  }
  #soohawk-quest-demo[data-student-game] .sp-reward .sp-medal {
    grid-column:1;
    grid-row:1 / span 4;
    margin:0;
    font-size:clamp(36px,9svh,52px);
  }
  #soohawk-quest-demo[data-student-game] .sp-content > .sp-home-actions:not(.student-login) {
    padding-bottom:clamp(6px,2svh,12px);
  }
  #soohawk-quest-demo[data-student-game] .sp-home-actions:not(.student-login) .sp-primary {
    min-height:48px;
    padding-block:10px;
    margin-block:6px 8px;
  }
}
/* Keep the island in view while giving the mathematics its own reading surface. */
#soohawk-quest-demo[data-student-game] .student-problem {
  width: min(calc(100% - 24px), 590px);
  padding: clamp(15px, 3vw, 26px);
  border: 1px solid #c0dcef73;
  border-radius: 22px;
  background: linear-gradient(145deg, #112f47ef, #0b263ee8 55%, #163751db);
  box-shadow: 0 16px 42px #061a3654, inset 0 1px #e3f6ff24;
}
#soohawk-quest-demo[data-student-game] .student-problem-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: #f7fbff;
  font: 710 clamp(19px, 4.2vw, 25px)/1.2 'Segoe UI', system-ui, sans-serif;
  letter-spacing: -.025em;
  text-transform: none;
  text-align: left;
  scroll-margin-top: max(64px, calc(env(safe-area-inset-top) + 54px));
}
#soohawk-quest-demo[data-student-game] .student-stage {
  margin: 0 0 5px;
  color: #ffdc94;
  font: 700 13px/1.4 'Segoe UI', system-ui, sans-serif;
  letter-spacing: .025em;
  text-align: left;
}
#soohawk-quest-demo[data-student-game] .student-context {
  margin: 9px 0 0;
  color: #d4e5f2;
  font: 450 15px/1.5 'Segoe UI', system-ui, sans-serif;
  text-align: left;
}
#soohawk-quest-demo[data-student-game] .student-problem-complete .student-stage {
  color: #a3ebcc;
  margin-bottom: 8px;
}
#soohawk-quest-demo[data-student-game] .sp-phone:has(.student-problem-complete) {
  /* Clip the scenery without making a scroll container that traps the footer. */
  overflow: clip;
}
#soohawk-quest-demo[data-student-game] .student-review-label {
  margin: 22px 0 0;
  color: #edf8f2;
  font: 650 16px/1.4 'Segoe UI', system-ui, sans-serif;
  text-align: left;
}
#soohawk-quest-demo[data-student-game] .student-next-actions {
  position: sticky;
  bottom: max(8px,env(safe-area-inset-bottom));
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 18px;
  padding: 12px;
  border: 1px solid #91c4ba70;
  border-radius: 16px;
  background: #102e43f5;
  box-shadow: 0 6px 24px #04162470;
}
#soohawk-quest-demo[data-student-game] .student-next-actions .sp-primary {
  flex: 1;
  width: auto;
  min-height: 48px;
  margin: 0;
  padding: 12px 20px;
}
#soohawk-quest-demo[data-student-game] .student-countdown {
  display: grid;
  gap: 3px;
  max-width: 48%;
  text-align: left;
  color: #d4e5f2;
  font: 500 12px/1.3 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-countdown [role=timer] {font-size: 16px; font-variant-numeric: tabular-nums}
#soohawk-quest-demo[data-student-game] .student-countdown strong {color: #fff3cc; font-size: 23px}
#soohawk-quest-demo[data-student-game] .student-figure {
  display: block;
  width: min(100%, 360px);
  height: auto;
  margin: 12px auto;
  background: #102b3b;
  border: 1px solid #759aa54f;
  border-radius: 12px;
}
#soohawk-quest-demo[data-student-game] .student-problem-title::before {
  content: "";
  flex: 0 0 8px;
  height: 8px;
  border: 1px solid #ffedba;
  background: #efc373;
  transform: rotate(45deg);
  box-shadow: 0 0 10px #f9c77350;
}
#soohawk-quest-demo[data-student-game] .student-lines {
  list-style: none;
  margin: 14px 0 0;
  padding: 0;
  font: 450 16px/1.5 'Segoe UI', system-ui, sans-serif;
  text-align: left;
}
#soohawk-quest-demo[data-student-game] .student-solution {
  display: grid;
  row-gap: .5lh;
  box-sizing: border-box;
  width: fit-content;
  max-width: min(100%, 36rem);
  margin: 16px auto;
  padding: 12px clamp(10px, 3vw, 22px);
  border: 1px solid #9ab8c450;
  border-radius: 14px;
  background: #0a2537b8;
  font-size: clamp(14px, 1.6vw, 15px);
}
#soohawk-quest-demo[data-student-game] .student-lines:empty {display: none}
#soohawk-quest-demo[data-student-game] .student-lines li {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0,1fr);
  gap: 8px;
  align-items: baseline;
  padding: 0 0 .5lh;
  color: #d0e4e6;
}
#soohawk-quest-demo[data-student-game] .student-completed-solution .student-lines li::before {
  content: '';
  position: absolute;
  inset: 14px auto -4px 8px;
  width: 1px;
  background: #83c4b157;
}
#soohawk-quest-demo[data-student-game] .student-line-check {
  position: relative;
  color: #9de9cc;
  background: #173d46;
  border-radius: 50%;
  text-align: center;
  font: 700 12px/18px system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-solution li {
  padding: 0;
  color: #bdd1dc;
}
#soohawk-quest-demo[data-student-game] .student-solution li:last-child {
  font-size: clamp(18px, 2.1vw, 21px);
  color: #fff3cc;
}
#soohawk-quest-demo[data-student-game] .student-line-work {overflow-wrap: anywhere}
#soohawk-quest-demo[data-student-game] .student-active {
  position: relative;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #b0d8e142;
}
#soohawk-quest-demo[data-student-game] .student-solution:not(:empty) + .student-active {
  margin-top: 0;
  padding-top: 0;
  border: 0;
}
#soohawk-quest-demo[data-student-game] .student-paused-prompt {
  margin: 0 0 12px;
  color: #e0e8ed;
  font: 500 16px/1.5 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-quick-check {
  margin-left: 7px;
  padding: 11px 0 0 clamp(8px,2vw,16px);
  border-left: 2px solid #76cdb9;
}
#soohawk-quest-demo[data-student-game] .student-branch-label {
  margin: 0 0 3px;
  color: #a3ebdd;
  font: 650 13px/1.4 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-quick-check h2 {
  margin: 0 0 8px;
  font: 700 18px/1.3 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-completed {
  margin: 0 0 16px;
  text-align: left;
}
#soohawk-quest-demo[data-student-game] .sp-complete .student-completed {margin: 18px 0 0}
#soohawk-quest-demo[data-student-game] .student-completed-solution {
  min-width: 0;
  padding: 6px 0;
  border-bottom: 1px solid #9ac7cf4b;
}
#soohawk-quest-demo[data-student-game] .student-completed-solution summary {padding: 5px 0;cursor: pointer;color: #b5ded1}
#soohawk-quest-demo[data-student-game] .student-completed-name {font: 600 14px/1.3 'Segoe UI', system-ui, sans-serif}
#soohawk-quest-demo[data-student-game] .student-completed-name::before {content:'✓ ';color:#99e6c5}
#soohawk-quest-demo[data-student-game] .student-result-line {
  display: block;
  margin: 5px 0 0 16px;
  color: #eef8f3;
  font: 450 15px/1.5 'Segoe UI', system-ui, sans-serif;
  overflow-wrap: anywhere;
}
#soohawk-quest-demo[data-student-game] details[open] > summary .student-result-line {display: none}
#soohawk-quest-demo[data-student-game] .student-completed-solution .student-lines li:last-child::before {display: none}
@media(prefers-reduced-motion:no-preference) {
  #soohawk-quest-demo[data-student-game] .student-new-line {animation: student-line-in 240ms ease-out both}
  @keyframes student-line-in {
    from {opacity: .25; transform: translateY(5px)}
    to {opacity: 1; transform: translateY(0)}
  }
}
#soohawk-quest-demo[data-student-game] .student-formula {
  position: relative;
  margin: 12px 0 10px;
  padding: 10px 4px 14px;
  color: #fff1cc;
  text-align: center;
  font-size: clamp(24px, 4.2vw, 32px);
  line-height: 1.3;
  background: radial-gradient(ellipse at center, #739da11e, transparent 72%);
}
#soohawk-quest-demo[data-student-game] .student-formula::after {
  position: absolute;
  content: "";
  inset: auto 5% 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, #c0ad7c94 35%, #c0ad7c94 65%, transparent);
}
#soohawk-quest-demo[data-student-game] .student-formula-givens {
  display: grid;
  grid-template-columns: minmax(0,1fr);
  row-gap: 0.5lh;
  font-size: clamp(18px, 3.6vw, 23px);
}
#soohawk-quest-demo[data-student-game] .student-formula .katex-display {margin: 0}
#soohawk-quest-demo[data-student-game] .student-formula .katex-display > .katex {white-space: normal}
#soohawk-quest-demo[data-student-game] .student-problem .katex,
#soohawk-quest-demo[data-student-game] .student-problem .katex * {box-sizing: content-box; letter-spacing: normal; text-shadow: none}
#soohawk-quest-demo[data-student-game] .student-prompt {
  margin: 0;
  color: #f0f6fc;
  font-size: 16px;
  line-height: 1.5;
  text-align: left;
}
#soohawk-quest-demo[data-student-game] .student-prompt:focus-visible {outline: 2px solid #ffdc94; outline-offset: 2px}
#soohawk-quest-demo[data-student-game] .student-choices {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}
#soohawk-quest-demo[data-student-game] .student-choices .sp-choice {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  min-width: 0;
  min-height: 50px;
  margin: 0;
  padding: 11px 12px;
  border: 1px solid #96c5d86b;
  border-radius: 13px;
  background: linear-gradient(115deg, #23465ed9, #15344cb8);
  text-shadow: none;
}
#soohawk-quest-demo[data-student-game] .student-choices .sp-choice:disabled {opacity: 1}
#soohawk-quest-demo[data-student-game] .student-choices .sp-choice[data-answer-state=picked] {
  border-color: #a6d9ed;
  box-shadow: inset 0 0 0 1px #b3dde377;
}
#soohawk-quest-demo[data-student-game] .student-choices .sp-choice[data-answer-state=picked] .student-choice-letter {
  background: #c4e8fa;
  color: #123246;
}
#soohawk-quest-demo[data-student-game] .student-choices .sp-choice[data-answer-state=retry] {
  border-color: #eeb68b;
}
#soohawk-quest-demo[data-student-game] .student-feedback-tag {
  display: block;
  margin-top: 3px;
  color: #ffe0bb;
  font: 700 13px/1.3 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-waiting-choice {min-width: 0}
#soohawk-quest-demo[data-student-game] .student-waiting-choice > button {width: 100%}
#soohawk-quest-demo[data-student-game] .student-preparing {
  display: flex;
  gap: 8px;
  align-items: center;
  color: #d8f3ed;
  text-align: left;
  font: 650 14px/1.35 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-thinking-owl {
  flex: none;
  width: clamp(76px, 18vw, 90px);
  aspect-ratio: 1;
  background: url('/quest-art/study-owl-thinking.webp') center / contain no-repeat;
}
#soohawk-quest-demo[data-student-game] .student-preparing .student-skip {
  display: block;
  margin: 4px 0 0;
}
#soohawk-quest-demo[data-student-game] .student-thinking-owl:has(video) {background-image: none}
#soohawk-quest-demo[data-student-game] .student-thinking-owl video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

#soohawk-quest-demo[data-student-game] .student-choices .student-choice-letter {
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  border-radius: 8px;
  border: 1px solid #acd2de65;
  background: #103248;
  color: #d3f3ee;
  font: 720 13px/1 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-choices .sp-solution {
  min-width: 0;
  color: #eef6fc;
  font: 450 16px/1.5 'Segoe UI', system-ui, sans-serif;
  letter-spacing: 0;
}
#soohawk-quest-demo[data-student-game] .student-choices .sp-solution small {font: inherit}
#soohawk-quest-demo[data-student-game] .student-choices .sp-solution small + small {margin-top: 5px}
#soohawk-quest-demo[data-student-game] .student-choices .sp-solution small:has(.katex) + small:has(.katex) {margin-top: 0.5lh}
#soohawk-quest-demo[data-student-game] :is(.sp-solution, .student-prompt) .katex {font-size: 1.08em}
@media(min-width: 860px) {
  #soohawk-quest-demo[data-student-game] .student-problem {width: min(calc(100% - 64px), 822px)}
  #soohawk-quest-demo[data-student-game] .student-choices {grid-template-columns: repeat(2, minmax(0, 1fr))}
}
#soohawk-quest-demo[data-student-game] .student-notice:not(:empty){font-size:14px;line-height:1.5;color:#fff2c9;padding:7px 0}
#soohawk-quest-demo[data-student-game] .student-notice button{margin-top:6px}
#soohawk-quest-demo[data-student-game] .sp-feedback:not(:empty){font-size:14px;line-height:1.4;margin:8px 0 2px}
#soohawk-quest-demo[data-student-game] .sp-phone[data-screen=solve] .student-problem {
  margin-bottom:env(safe-area-inset-bottom,0px);
}
#soohawk-quest-demo[data-student-game] .sp-phone[data-screen=complete] .sp-complete {margin-bottom:0}
#soohawk-quest-demo[data-student-game] .sp-phone:is([data-screen=solve],[data-screen=complete]) .sp-content::after {
  content:"";
  flex:1 0 0px;
  max-height:clamp(12px,3svh,32px);
}
@media(max-width:600px){
  #soohawk-quest-demo[data-student-game] .qi-preview{background:linear-gradient(#071c35ce,#071c355c)}
  #soohawk-quest-demo[data-student-game] .sp-phone[data-screen=solve] .sp-content::after{max-height:12px}
}

/* A single optional worked picture sits where the learner's current choice was. */
#soohawk-quest-demo[data-student-game] .student-hint-open,
#soohawk-quest-demo[data-student-game] .student-hint-controls button {
  width: auto;
  min-height: 42px;
  margin: 0;
  padding: 8px 15px;
  border: 1px solid #92d5ca;
  border-radius: 12px;
  background: #244d55;
  color: #eafffa;
  font: 650 14px/1.3 'Segoe UI', system-ui, sans-serif;
  text-shadow: none;
  cursor: pointer;
}
#soohawk-quest-demo[data-student-game] .student-hint-open {margin-top: 9px}
#soohawk-quest-demo[data-student-game] .student-hint-open > span {margin-right: .25em; color: #ffe09a}
#soohawk-quest-demo[data-student-game] .student-hint-reader {
  box-sizing: border-box;
  max-width: 30rem;
  margin: 0 auto;
  padding: clamp(10px, 3vw, 16px);
  border: 1px solid #81bdb77d;
  border-radius: 16px;
  background: #123448;
  color: #f2f9fc;
  text-align: left;
}
#soohawk-quest-demo[data-student-game] .student-hint-head,
#soohawk-quest-demo[data-student-game] .student-hint-controls {display: flex; align-items: center; justify-content: space-between; gap: 8px}
#soohawk-quest-demo[data-student-game] .student-hint-head h2 {
  margin: 0; color: #f4faff; font: 700 18px/1.25 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-hint-head span {
  flex: none; color: #b0e9de; font: 650 14px/1.5 system-ui, sans-serif; font-variant-numeric: tabular-nums;
}
#soohawk-quest-demo[data-student-game] .student-hint-reader figure {margin: 12px 0 14px}
#soohawk-quest-demo[data-student-game] .student-hint-visual {
  overflow: hidden; border: 1px solid #82aaa84a; border-radius: 10px; background: #102b3b;
}
#soohawk-quest-demo[data-student-game] .student-hint-visual img,
#soohawk-quest-demo[data-student-game] .student-hint-visual video {
  display: block; width: 100%; height: auto; aspect-ratio: 304 / 158; object-fit: contain;
}
#soohawk-quest-demo[data-student-game] .student-hint-reader [hidden] {display: none}
#soohawk-quest-demo[data-student-game] .student-hint-reader figcaption {
  margin: 10px 0 0; font: 600 16px/1.4 'Segoe UI', system-ui, sans-serif;
}
#soohawk-quest-demo[data-student-game] .student-hint-controls {flex-wrap: wrap}
#soohawk-quest-demo[data-student-game] .student-hint-controls button {padding-inline: 11px}
#soohawk-quest-demo[data-student-game] .student-hint-controls .student-hint-primary {
  margin-left: auto; background: #a9ebd7; color: #133836; border-color: #c9ffe9;
}
#soohawk-quest-demo[data-student-game] .student-hint-controls .student-hint-back {border-color: #698d98; background: transparent}
#soohawk-quest-demo[data-student-game] :is(.student-hint-open,.student-hint-controls button,.student-hint-head h2):focus-visible {
  outline: 2px solid #ffe69c; outline-offset: 2px;
}

.math-data-table { box-sizing: border-box; padding: 12px; background: #102b3b; color: #eff6fc; border-radius: 12px; }
.math-data-table table { width: 100%; border-collapse: collapse; font: 14px/1.5 system-ui,sans-serif; table-layout: fixed; }
.math-data-table th,.math-data-table td { padding: 8px 4px; text-align: center; border: 1px solid #315363; overflow-wrap: anywhere; }
.math-data-table figcaption { font: 12px/1.4 system-ui,sans-serif; color: #b2ccd7; margin-top: 8px; }
