/* Money Map */
.map-inner { overflow-x: hidden; }

.map-finn {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}
.map-finn p { margin: 0; color: var(--ink); }

.map-node-btn,
.map-choice {
  width: 100%;
  min-height: 56px;
  padding: 10px 12px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  text-align: left;
  font: inherit;
  cursor: pointer;
}

.map-sheet {
  position: fixed;
  z-index: 80;
  inset: 0;
  display: grid;
  place-items: end center;
  padding: 12px 12px calc(76px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--bg) 72%, transparent);
}
.map-sheet-card {
  position: relative;
  width: min(100%, 420px);
  max-height: min(80dvh, 640px);
  overflow: auto;
  overflow-wrap: break-word;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--panel);
}
.map-sheet-card h2 {
  margin: 8px 0 0;
  font-family: var(--font-ui);
  font-size: 22px;
}
.map-sheet-card p { color: var(--ink); }
.map-kicker {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.map-choice { margin-top: 8px; min-height: 44px; }
.map-choice.is-right { border-color: var(--win); }
.map-choice.is-wrong { border-color: var(--action); }
.map-why { margin: 8px 0 0; }
.map-disclaimer {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 12px;
}
.map-score {
  margin: 8px 0 0;
  font-family: var(--font-ui); font-variant-numeric: tabular-nums;
  font-size: 28px;
  color: var(--coin-ink);
}
.map-sheet .finn { margin-bottom: 4px; }
.boss-meters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}
.boss-meter {
  min-width: 0;
  min-height: 44px;
  padding: 8px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--bg);
}
.boss-meter span {
  display: block;
  color: var(--muted);
  font-size: 11px;
}
.boss-meter b {
  display: block;
  margin-top: 2px;
  font-family: var(--font-ui); font-variant-numeric: tabular-nums;
  font-weight: 500;
  color: var(--info-ink);
}
.boss-hp-label {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin: 12px 0 4px;
  color: var(--ink);
  font-family: var(--font-ui);
}
.boss-hp {
  display: flex;
  gap: 4px;
  height: 16px;
}
.boss-hp > i {
  flex: 1 1 0;
  border-radius: 4px;
  background: var(--line);
}
.boss-hp > i.is-on { background: var(--action); }
.boss-character.is-enter { animation: boss-enter 300ms ease; }
.boss-character.is-hit { animation: boss-hit 200ms linear; }
.boss-character.is-defeated { animation: boss-defeat 400ms ease forwards; }
@keyframes boss-enter {
  0% { transform: translateX(36%); }
  70% { transform: translateX(-4px); }
  100% { transform: none; }
}
@keyframes boss-hit {
  0%, 100% { transform: translateX(0); }
  40% { transform: translateX(-6px); }
  70% { transform: translateX(4px); }
}
@keyframes boss-defeat {
  to { transform: translateY(16px) rotate(6deg); opacity: 0.4; }
}

.boss-note { margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.4; }
.boss-result {
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--bg);
}
.boss-result p { margin: 0; }
.boss-result.is-picked { border-color: var(--info); }
.boss-result .num {
  margin-top: 4px;
  font-family: var(--font-ui); font-variant-numeric: tabular-nums;
  color: var(--coin-ink);
}
.boss-badge {
  margin: 8px 0 0;
  color: var(--coin-ink);
  font-family: var(--font-ui);
}
@media (prefers-reduced-motion: reduce) {
  .boss-character.is-enter,
  .boss-character.is-hit,
  .boss-character.is-defeated { animation: none; }
}

/* Predict then reveal */
.predict-reveal {
  margin-top: 12px;
  padding: 12px;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  max-width: 100%;
}
.predict-finn {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.predict-ask,
.predict-detail,
.predict-note,
.predict-why,
.predict-disclaimer {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.45;
  color: var(--ink);
}
.predict-detail,
.predict-note,
.predict-disclaimer {
  color: var(--muted);
  font-size: 13px;
}
.predict-choices,
.predict-confs,
.predict-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}
.predict-choice,
.predict-conf,
.predict-lock,
.predict-skip {
  min-height: 44px;
  font: inherit;
  cursor: pointer;
}
.predict-choice,
.predict-conf,
.predict-lock {
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
}
.predict-choice {
  flex: 1 1 140px;
  text-align: left;
}
.predict-choice[aria-checked="true"],
.predict-conf[aria-checked="true"] {
  border-color: var(--info);
  box-shadow: inset 0 0 0 1px var(--info);
}
.predict-lock {
  background: var(--action);
  border-color: var(--action);
  color: var(--on-action);
  font-family: var(--font-ui);
  font-weight: 700;
}
.predict-lock:disabled {
  opacity: 0.45;
  cursor: default;
}
.predict-skip {
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 13px;
  text-decoration: underline;
}
.predict-skeleton {
  display: grid;
  gap: 8px;
  padding: 8px 0;
}
.predict-skeleton i {
  display: block;
  height: 12px;
  border-radius: 999px;
  background: var(--line);
}
.predict-skeleton i:nth-child(2) { width: 86%; }
.predict-skeleton i:nth-child(3) { width: 64%; }
.predict-held { min-height: 72px; }
.predict-unblur { animation: predict-unblur 250ms ease; }
@keyframes predict-unblur {
  from { filter: blur(8px); opacity: 0.45; }
  to { filter: blur(0); opacity: 1; }
}
.predict-choice:focus-visible,
.predict-conf:focus-visible,
.predict-lock:focus-visible,
.predict-skip:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
}
.xp-toast.is-hit,
.xp-toast.is-miss {
  border-radius: 16px;
  text-align: center;
}
.xp-toast.is-hit { color: var(--win-ink); border-color: var(--win); }
.xp-toast.is-miss { color: var(--coin-ink); border-color: var(--coin); }
.xp-toast strong {
  display: block;
  font-family: var(--font-ui);
}
.xp-toast-line {
  display: block;
  max-width: 260px;
  margin-top: 4px;
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 13px;
  line-height: 1.4;
  text-align: center;
}
@media (prefers-reduced-motion: reduce) {
  .predict-unblur { animation: none; }
}
.map-node-btn:focus-visible,
.map-choice:focus-visible,
.map-sheet-close:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
}

.world-scene,
.boss-scene {
  height: 200px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg);
}
.world-scene .art-frame,
.boss-scene .art-frame,
.world-scene .art-frame img,
.boss-scene .art-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.world-scene svg,
.boss-scene > svg.scene { width: 100%; height: 200px; display: block; }
.story-panel {
  margin-top: 12px;
  padding: 12px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: var(--panel);
}
.story-panel h3 {
  margin: 4px 0;
  font-family: var(--font-ui);
  font-size: 18px;
}

.map-seg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-dasharray: 2 1.6;
}
.map-seg.is-solid { stroke-dasharray: none; stroke-width: 2.4; }

.map-stars-row { display: inline-flex; gap: 3px; justify-content: center; }
.map-stars-row i {
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--line);
}
.map-stars-row i.is-on { background: var(--coin); }
.map-sheet-card.is-hp-flash { animation: hp-flash 420ms ease; }
@keyframes hp-flash {
  40% { box-shadow: inset 0 0 0 6px var(--flash, var(--action)); }
}

.map-star-pop {
  position: absolute;
  left: 50%;
  top: 0;
  z-index: 2;
  pointer-events: none;
  animation: star-pop 600ms ease forwards;
}
@keyframes star-pop {
  0% { transform: translate(-50%, -8px) scale(1.6); opacity: 0; }
  55% { transform: translate(-50%, 0) scale(0.92); opacity: 1; }
  100% { transform: translate(-50%, 0) scale(1); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .map-star-pop,
  .map-sheet-card.is-hp-flash{ animation: none; }
}

.map-motion {
  position: absolute;
  inset: 0;
  z-index: 2;
  overflow: hidden;
  pointer-events: none;
}

.map-draw {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  color: var(--coin-ink);
}
.map-seg.is-draw {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: path-draw 700ms ease forwards;
}
@keyframes path-draw { to { stroke-dashoffset: 0; } }

.map-inner art-placeholder {
  background-image: none;
  background-color: var(--raised);
}

.comic-strip {
  position: absolute;
  top: 0;
  left: calc(50% + 76px);
  width: 124px;
  z-index: 2;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  color: var(--ink);
}

.comic-strip .map-kicker { line-height: 1.2; }
.comic-panels { display: flex; gap: 4px; margin-top: 4px; }
.comic-panels .art-frame {
  flex: 1 1 0;
  width: auto;
  height: 36px;
  min-width: 0;
  overflow: hidden;
}
.comic-panels art-placeholder,
.comic-panels .art-frame img {
  overflow: hidden;
  width: 100%;
  height: 100%;
  object-fit: cover;
  padding: 2px;
  font-size: 8px;
  line-height: 1.1;
}
.comic-caption {
  display: -webkit-box;
  margin: 4px 0 0;
  overflow: hidden;
  color: var(--ink);
  font-size: 11px;
  line-height: 1.3;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}
.comic-done {
  position: absolute;
  left: 50%;
  top: 128px;
  width: 132px;
  margin: 0;
  padding: 4px 6px;
  transform: translateX(-50%);
  border-radius: 8px;
  background: var(--panel);
  color: var(--ink);
  text-align: center;
}
.comic-done p {
  margin: 0;
  font-size: 11px;
  line-height: 1.3;
}
@media (prefers-reduced-motion: reduce) {
  
  .motion-bit,
  .map-seg.is-draw {
    animation: none;
  }
}

.map-sheet.is-stage { padding: 0; }
.map-sheet.is-stage .map-sheet-card {
  width: min(420px, 100%);
  min-height: 100%;
  margin: 0 auto;
  border-radius: 0;
}
.boss-scene { position: relative; margin: 0 0 12px; }
.boss-scene > svg.scene { display: block; width: 100%; height: 200px; }
.boss-scene .boss-character {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 72px;
  height: 72px;
}
.boss-scene .art-frame.boss-character img {
  width: 72px;
  height: 72px;
  object-fit: contain;
}
.boss-meter i,
.practice-bar i {
  display: block;
  height: 8px;
  margin-top: 6px;
  border-radius: 999px;
  background: var(--info);
  transition: width 600ms ease;
}
.practice-bars { margin-top: 12px; }
.practice-bar { margin-top: 8px; }
.practice-bar span { display: block; color: var(--muted); font-size: 12px; }
.practice-bar.is-picked i { background: var(--win); }
.boss-badge-card {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--coin);
  border-radius: var(--radius-md);
  background: var(--raised);
  transform: rotateY(90deg);
}
.boss-badge-card.is-in { transform: none; transition: transform 400ms ease; }
.map-beat { display: block; margin: 8px 0; }
.map-beat-slider { width: 100%; min-height: 44px; }
.map-order { list-style: none; margin: 8px 0; padding: 0; }
.map-order-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  margin: 8px 0;
}
.map-order-row button { min-height: 44px; min-width: 44px; }
@media (prefers-reduced-motion: reduce) {
  .boss-meter i,
  .practice-bar i,
  .boss-hp > i,
  .boss-character,
  .boss-badge-card { transition: none; transform: none; animation: none; }
}

/* Journey is one continuous world (docs/redesign/CANVAS.md 3.1). */
.journey { padding: 12px 0 0; }

/* The stop sheet (docs/redesign/CANVAS.md 3.2). */
.stop-sheet { z-index: var(--z-sheet); background: var(--scrim); }
.stop-sheet-card { display: grid; gap: 8px; }
.stop-sheet-card h2 { margin: 0; font-family: var(--font-display); font-weight: 800; letter-spacing: var(--tracking-head); font-size: 26px; }
.stop-learn { margin: 0; font-size: 17px; line-height: 1.4; }
.stop-best { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 700; color: var(--muted); }
.stop-best .map-stars-row i { width: 14px; height: 14px; }
.stop-story { margin-top: 4px; }
.stop-story .comic-strip { margin: 0; }
.stop-sheet-card .sheet-primary { margin-top: 8px; width: 100%; }
.stop-sheet-card .btn-text { min-height: 44px; }
/* Inside the sheet the story is a normal block: bigger panels, the whole caption. */
.stop-story .comic-strip {
  position: static;
  width: auto;
  padding: 10px;
  border-radius: var(--r-control);
  background: var(--paper);
  transform: none;
}
.stop-story .comic-panels { gap: 6px; margin-top: 6px; }
.stop-story .comic-panels .art-frame { height: 96px; border-radius: 8px; }
.stop-story .comic-caption { display: block; overflow: visible; -webkit-line-clamp: unset; font-size: 15px; }
.stop-story .comic-done { position: static; transform: none; width: auto; margin: 0 0 6px; }

/* Journey (Deep Blue item 6): night-lit world cards, the current world's path, the boss card. */
#mapScreen .journey { display: grid; gap: var(--space-5); padding: var(--space-4) var(--space-4) var(--space-6); }
@media (min-width: 1024px) { #mapScreen .journey { padding-inline: var(--space-6); } }
.journey-head { display: grid; gap: var(--space-1); }
.journey-h1 { margin: 0; font-size: var(--fs-24); font-weight: 800; letter-spacing: var(--tracking-head); color: var(--text-1); }
.journey-sub { margin: 0; font-size: var(--fs-14); color: var(--text-2); }

.world-cards {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(148px, 42%);
  gap: var(--space-3);
  margin: 0 calc(-1 * var(--space-4));
  padding: 2px var(--space-4) var(--space-2);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}
.world-cards::-webkit-scrollbar { display: none; }
@media (min-width: 1024px) {
  .world-cards { grid-auto-flow: row; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0; padding: 0; overflow: visible; }
}
.world-card {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--border-card);
  border-radius: var(--r-18);
  background: var(--surface);
  color: var(--text-body);
  font: inherit;
  text-align: left;
  cursor: pointer;
  scroll-snap-align: start;
  transition: transform var(--motion-fast) var(--ease-out), border-color var(--motion-fast) var(--ease-out);
}
.world-card:not([disabled]):hover { transform: translateY(var(--lift)); border-color: var(--link); }
.world-card:not([disabled]):active { transform: scale(var(--press)); }
.world-card[aria-current="true"] { border-color: var(--link); box-shadow: 0 0 0 1px var(--link); }
.world-card[disabled] { cursor: default; }
.world-card-art { display: block; aspect-ratio: 16 / 11; overflow: hidden; }
.world-card-art .art-frame,
.world-card-art img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }  /* moon and island both in frame */
.world-card[disabled] .world-card-art img { opacity: 0.55; }
.world-card-text { display: grid; align-content: start; gap: 2px; padding: var(--space-3); }
.world-card-name { font-size: var(--fs-15); font-weight: 800; color: var(--text-1); }
.world-card-plain { font-size: var(--fs-12); color: var(--text-2); }
.world-card-status { display: inline-flex; align-items: center; gap: var(--space-1); margin-top: var(--space-1); font-size: var(--fs-12); font-weight: 700; color: var(--text-2); }
.world-card-stars { margin-top: var(--space-1); font-size: var(--fs-12); color: var(--text-2); }
.world-card-stars .num { color: var(--gold); font-weight: 700; }
.world-card-bar { display: block; height: 4px; margin-top: var(--space-1); overflow: hidden; border-radius: var(--r-pill); background: var(--surface-soft); }
.world-card-bar i { display: block; height: 100%; border-radius: inherit; background: var(--gold); }

.journey-world {
  display: grid;
  gap: var(--space-4);
  padding: var(--space-5);
  border: 1px solid var(--border-card);
  border-radius: var(--r-22);
  background: var(--surface);
}
.journey-world-head { display: grid; gap: var(--space-1); justify-items: start; }
.journey-kicker { font-size: var(--fs-11); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-2); }
.journey-world-title { margin: 0; font-size: var(--fs-20); font-weight: 800; letter-spacing: var(--tracking-head); color: var(--text-1); }
.journey-world-meta { margin: 0; font-size: var(--fs-13); color: var(--text-2); }
.journey-check {
  margin-top: var(--space-2);
  min-height: 44px;
  padding: 0 var(--space-4);
  border: 1px solid var(--border-card);
  border-radius: var(--r-pill);
  background: var(--surface-soft);
  color: var(--text-1);
  font: 600 var(--fs-13)/1 var(--font-ui);
  cursor: pointer;
}
.journey-check:hover { border-color: var(--link); }

.path-list { position: relative; display: grid; gap: var(--space-2); margin: 0; padding: 0; list-style: none; }
.path-list::before {
  content: "";
  position: absolute;
  top: 22px;
  bottom: 22px;
  left: 29px;
  width: 2px;
  background: var(--border);
}
.path-row { position: relative; }
.path-row-btn {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  min-height: 60px;
  padding: var(--space-2) var(--space-3);
  border: 1px solid transparent;
  border-radius: var(--r-14);
  background: transparent;
  color: var(--text-body);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.path-row-btn:not([disabled]):hover { border-color: var(--border); background: var(--surface-soft); }
.path-row-btn[disabled] { cursor: default; }
.path-row.is-current .path-row-btn { border-color: var(--border-card); background: var(--surface-soft); }
.path-marker {
  position: relative;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 2px solid var(--border);
  border-radius: 50%;
  background: var(--surface-solid);
  color: var(--text-2);
  font-size: var(--fs-13);
}
.path-row.is-done .path-marker { border-color: var(--mint); background: var(--mint-bg); color: var(--mint); }
.path-row.is-current .path-marker { border-color: var(--link); box-shadow: 0 0 0 4px var(--blue-bg); color: var(--link); }
.path-text { display: grid; gap: 2px; min-width: 0; }
.path-title { font-size: var(--fs-15); font-weight: 700; color: var(--text-1); }
.path-row.is-locked .path-title { color: var(--text-2); }
.path-kind { font-size: var(--fs-12); color: var(--text-2); }
.path-meta { display: inline-flex; align-items: center; gap: var(--space-1); font-size: var(--fs-12); color: var(--text-2); white-space: nowrap; }
.path-row.is-current .path-meta { color: var(--gold); font-weight: 700; }
.path-meta .map-stars-row i { width: 10px; height: 10px; }
.path-row.is-glow .path-marker { box-shadow: 0 0 0 4px var(--gold-bg); }

.boss-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid color-mix(in srgb, var(--gold) 35%, transparent);
  border-radius: var(--r-18);
  background: var(--gold-bg);
}
.boss-card.is-locked { border-color: var(--border); background: var(--surface-soft); }
.boss-crown {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--surface-solid);
  color: var(--gold);
}
.boss-card.is-locked .boss-crown { color: var(--text-2); }
.boss-text { display: grid; gap: 2px; min-width: 0; }
.boss-kicker { font-size: var(--fs-11); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold); }
.boss-card.is-locked .boss-kicker { color: var(--text-2); }
.boss-title { font-size: var(--fs-16); font-weight: 800; color: var(--text-1); }
.boss-line { font-size: var(--fs-13); color: var(--text-2); }
.boss-lock { display: inline-flex; align-items: center; gap: var(--space-1); font-size: var(--fs-12); font-weight: 700; color: var(--text-2); }
.boss-play { min-height: 44px; }
@media (max-width: 420px) {
  .boss-card { grid-template-columns: auto minmax(0, 1fr); }
  .boss-card .boss-play, .boss-card .boss-lock { grid-column: 1 / -1; justify-self: stretch; justify-content: center; }
}

/* A stop opens a bottom sheet on phones and a centred modal on desktop. */
.stop-sheet .stop-sheet-card { border-color: var(--border-card); background: var(--surface-solid); box-shadow: var(--shadow-raised); }
.stop-sheet-card h2 { font-family: var(--font-ui); font-size: var(--fs-24); color: var(--text-1); }
.stop-learn { font-size: var(--fs-16); color: var(--text-body); }
.stop-best { color: var(--text-2); }
.stop-sheet-card .btn-play { display: inline-flex; justify-content: center; align-items: center; gap: var(--space-2); min-height: 48px; }
@media (min-width: 1024px) {
  .stop-sheet { place-items: center; padding: var(--space-6); }
  .stop-sheet .stop-sheet-card { width: min(100%, 480px); padding: var(--space-6); border-radius: var(--r-22); }
}

/* Round 3, R3-6: the lesson. In the stage the card no longer scrolls inside itself (the stage scrolls), the scene
   is a short strip, the story is one line, and the question and its controls come straight after. */
.stage-play-body > .map-sheet-card { max-height: none; overflow: visible; }
.world-scene.is-strip { height: 96px; }
.story-line {
  margin: 10px 0 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--muted);
  font-size: 14px;
}
.story-line b { color: var(--ink); font-weight: 700; }
.map-sheet-card.is-lesson h2 { margin-top: 10px; }
.lesson-prompt { margin: 6px 0 4px; font-size: 16px; line-height: 1.45; }
.map-answers { display: grid; }
.map-choice.is-picked { border-color: var(--link); box-shadow: 0 0 0 2px var(--link) inset; }
.lesson-help { margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--line); }

/* How sure you are: round pills in a row, a different shape and size from the answer cards. */
.sure-row { margin-top: 14px; }
.sure-label { margin: 0 0 6px; color: var(--muted); font-size: 13px; font-weight: 700; }
.sure-chips { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sure-chip {
  display: grid;
  justify-items: center;
  gap: 0;
  min-height: 48px;
  padding: 4px 6px;
  border: 1px dashed var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
  line-height: 1.15;
  cursor: pointer;
}
.sure-chip b { font-size: 15px; }
.sure-chip.is-picked { border-style: solid; border-color: var(--link); background: color-mix(in srgb, var(--link) 18%, transparent); }
.sure-chip:focus-visible { outline: 3px solid var(--link); outline-offset: 2px; }

/* Hold to lock: a 600 ms ring fills while you hold; let go early and nothing is sent. Orange: a game action. */
.lock-row { margin-top: 14px; display: grid; gap: 6px; }
.lock-hold {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: 56px;
  padding: 6px 16px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--play-from), var(--play-to));
  color: var(--on-bright);
  font: inherit;
  font-size: 17px;
  font-weight: 800;
  cursor: pointer;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}
.lock-hold:disabled { opacity: .45; cursor: not-allowed; }
.lock-hold:focus-visible { outline: 3px solid var(--link); outline-offset: 3px; }
.lock-ring { flex: none; width: 32px; height: 32px; transform: rotate(-90deg); }
.lock-ring circle { fill: none; stroke-width: 5; }
.lock-ring-track { stroke: color-mix(in srgb, var(--on-bright) 25%, transparent); }
.lock-ring-fill { stroke: var(--on-bright); stroke-dasharray: 100; stroke-dashoffset: 100; stroke-linecap: round; }
.lock-hold.is-holding .lock-ring-fill { stroke-dashoffset: 0; transition: stroke-dashoffset 600ms linear; }
.lock-hold.is-locked .lock-ring-fill { stroke-dashoffset: 0; }
.lock-hint { margin: 0; color: var(--muted); font-size: 13px; text-align: center; }

/* The result: Finn's reaction, stars that pop in one by one, a one-line why, the source small, XP that flies. */
.lesson-result { display: grid; justify-items: center; gap: 10px; text-align: center; }
.result-finn { display: flex; align-items: center; gap: 10px; text-align: left; }
.result-finn-line { margin: 0; font-weight: 700; }
.result-stars { display: flex; gap: 8px; }
.result-star { color: var(--text-3, var(--muted)); }
.result-star.is-on { color: var(--gold); animation: result-star-pop 420ms cubic-bezier(.2, 1.5, .4, 1) both; animation-delay: calc(var(--i) * 160ms); }
.result-star.is-on svg { fill: var(--gold); }
@keyframes result-star-pop { from { transform: scale(0) rotate(-30deg); opacity: 0; } to { transform: none; opacity: 1; } }
.lesson-result h2 { margin: 0; }
.result-why { margin: 0; font-size: 16px; line-height: 1.45; }
.result-source { margin: 0; color: var(--muted); font-size: 12px; }
.result-xp { margin: 0; }
.result-xp-chip {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--gold-bg);
  color: var(--gold);
  font-weight: 800;
}
.result-xp-chip.is-flying { transition: transform 520ms cubic-bezier(.4, 0, .2, 1), opacity 520ms ease-in; pointer-events: none; }
.lesson-result .btn-game { width: 100%; }
@media (prefers-reduced-motion: reduce) {
  .result-star.is-on { animation: none; }
}
