body.collection {
  --world: #ced9d3;
  --light: #fff5dd;
  --ink: #344f50;
  --accent: #386d64;
  --muted: #607575;
  background: var(--world);
  color: var(--ink);
}
body.theme-starlight {
  --world: #cbc5e2;
  --light: #f3edfc;
  --ink: #514466;
  --accent: #806494;
}
body.theme-sweet {
  --world: #efd2d0;
  --light: #fff3dc;
  --ink: #744a50;
  --accent: #a95367;
}
body.theme-workshop {
  --world: #bcd9de;
  --light: #fff0d1;
  --ink: #3a5766;
  --accent: #42798e;
}
body.theme-orchard {
  --world: #d6dfb4;
  --light: #fff0cf;
  --ink: #506236;
  --accent: #648044;
}
body.theme-robot {
  --world: #c0d9e0;
  --light: #eaf4ef;
  --ink: #36596c;
  --accent: #477e9b;
}
body.theme-music {
  --world: #d6d4e4;
  --light: #fcf1dc;
  --ink: #65506b;
  --accent: #97729f;
}
body.theme-crystal {
  --world: #b4b9d5;
  --light: #e5dced;
  --ink: #464966;
  --accent: #686492;
}
body.theme-polar {
  --world: #c2dfeb;
  --light: #f2f6ee;
  --ink: #39596f;
  --accent: #547d97;
}
body.theme-safari {
  --world: #d6dfc0;
  --light: #faf2d9;
  --ink: #4d6443;
  --accent: #6c8652;
}
.collection .game-shell {
  background: radial-gradient(
    ellipse at 35% 15%,
    var(--light),
    var(--world) 85%
  );
  max-width: 600px;
}
.collection header {
  padding: 10px 13px;
  gap: 6px;
}
.collection .round-button {
  width: 44px;
  height: 44px;
  min-height: 44px;
  border-radius: 15px;
  background: #fff9e52e;
}
.collection .brand {
  font-size: 14px;
  line-height: 1.05;
  gap: 7px;
}
.collection .brand > span {
  font-size: 23px;
}
.collection .brand small {
  font-size: 6px;
  letter-spacing: 1.3px;
  margin-top: 5px;
}
.collection .mission-card {
  margin: 0 13px;
  padding: 10px 13px;
  flex-shrink: 0;
  background: #fff9e8a8;
  border: 1px solid #ffffff60;
  border-radius: 19px;
}
.collection .chapter-row {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}
.collection #chapter-name {
  font-size: 9px;
  letter-spacing: 0.6px;
  font-weight: bold;
}
.collection #count {
  font-size: 12px;
  color: var(--accent);
  white-space: nowrap;
}
.collection #mission {
  font-size: 13px;
  line-height: 1.4;
  font-weight: bold;
  margin: 7px 0;
  min-height: 36px;
}
.collection .progress-track {
  height: 4px;
  margin: 0;
  background: #a38b831c;
}
.collection #progress {
  background: var(--accent);
}
.collection #stage {
  min-height: 0;
}
.collection .scene-caption {
  top: 13px;
  font-size: 7px;
  letter-spacing: 1.5px;
}
.collection #ribbon {
  position: absolute;
  left: 10px;
  right: 10px;
  top: 32px;
  z-index: 2;
  display: flex;
  gap: 5px;
  justify-content: center;
  align-items: center;
  font-size: 19px;
  font-weight: bold;
  pointer-events: none;
}
.note-chip {
  font-size: 11px;
  padding: 7px;
  border-radius: 9px;
  background: #fff9e9a6;
}
.note-chip.current {
  background: var(--accent);
  color: white;
  box-shadow: 0 0 0 3px #ffffff70;
}
.note-chip.done {
  background: #83b899;
  color: #193c2e;
}
.collection .dock {
  padding: 8px 13px 3px;
  background: #fff6df55;
  border-top: 1px solid #ffffff88;
  flex-shrink: 0;
}
#choices,
#tool-tabs,
.action-row,
.collection-bottom {
  display: flex;
  gap: 7px;
}
#choices,
#tool-tabs {
  margin-bottom: 6px;
}
#choices button,
#tool-tabs button {
  flex: 1;
  min-width: 0;
}
.choice-button,
.utility-button,
.chapter-button {
  min-height: 44px;
  border: 1px solid #ffffffaa;
  border-radius: 12px;
  background: #fff9e6bf;
  color: var(--ink);
  font-size: 12px;
  padding: 6px 9px;
}
.choice-button[aria-pressed="true"] {
  background: var(--accent);
  color: #fffaf0;
  border-color: var(--accent);
}
#tool-tabs .choice-button {
  font-size: 11px;
  min-height: 44px;
}
.collection .primary {
  background: var(--accent);
  color: #fffaf0;
  min-height: 48px;
  font-size: 13px;
  padding: 10px 12px;
  box-shadow: 0 4px 14px #29495118;
}
.action-row .primary {
  flex: 2;
  min-width: 0;
  min-height: 44px;
}
.action-row .utility-button {
  flex: 1;
}
.collection-bottom {
  justify-content: space-between;
}
.collection-bottom button {
  background: transparent;
  color: var(--ink);
  border: 0;
  min-height: 44px;
  font-size: 10px;
  padding: 5px;
}
.collection button:disabled {
  opacity: 0.48;
  cursor: default;
}
.collection-target {
  position: absolute;
  transform: translate(-50%, -50%);
  min-height: 48px;
  min-width: 48px;
  pointer-events: auto;
  border-radius: 14px;
  border: 1px solid #ffffffbb;
  background: #fff8e5aa;
  color: var(--ink);
  font-size: 12px;
  font-weight: bold;
  padding: 5px;
  touch-action: manipulation;
}
.collection-target:active {
  transform: translate(-50%, -50%) scale(0.96);
}
.collection-target:disabled {
  opacity: 0.55;
}
.dots-target {
  border-radius: 50%;
  font-size: 18px;
  background: #fff8df;
}
.track-target,
.beam-target {
  background: transparent;
  border: 0;
  padding-top: 33px;
  color: #294b61;
}
.beam-target {
  color: #fff3ce;
}
.music-target {
  background: transparent;
  border: 0;
  min-width: 50px;
  padding-top: 18px;
}
.photo-target {
  font-size: 10px;
  min-width: 48px;
  background: #fff8e577;
}
.maze-target {
  font-size: 10px;
  background: #fff8e555;
}
.maze-target.reachable {
  box-shadow: 0 0 0 2px #f0bc65;
}
.guided {
  outline: 3px solid #df9441 !important;
  outline-offset: 3px;
}
.listening {
  background: #fff6a4 !important;
  box-shadow: 0 0 18px #fff1ac;
}
.collection .intro {
  background: linear-gradient(transparent 8%, var(--world) 68%);
  padding: 20px 24px 33px;
}
.collection .intro-card {
  max-width: 390px;
}
.collection .intro h1 {
  font-size: 36px;
  line-height: 1.05;
  margin: 9px 0 13px;
  max-width: 350px;
}
.collection .intro p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink);
  margin: 0 0 18px;
}
.collection .eyebrow {
  font-size: 8px;
  letter-spacing: 1.5px;
}
.intro-benefits {
  display: flex;
  gap: 5px;
  justify-content: center;
  margin-top: 14px;
  font-size: 9px;
}
.intro-benefits span {
  padding: 6px;
  border: 1px solid #ffffff70;
  border-radius: 8px;
}
#chapter-list {
  display: grid;
  gap: 7px;
  margin: 12px 0;
}
.chapter-button {
  text-align: left;
}
.collection #announcement {
  bottom: 185px;
  max-width: 85%;
  font-size: 12px;
  background: var(--ink);
  color: white;
}
@media (max-width: 360px) {
  .collection header {
    padding: 8px 10px;
  }
  .collection .brand {
    font-size: 11px;
  }
  .collection .brand > span {
    font-size: 18px;
  }
  .collection .brand small {
    font-size: 5px;
    letter-spacing: 0.5px;
  }
  .collection .mission-card {
    margin: 0 10px;
    padding: 8px 11px;
  }
  .collection #mission {
    font-size: 12px;
    min-height: 33px;
  }
  .collection #chapter-name {
    font-size: 8px;
  }
  .collection .dock {
    padding: 6px 10px 0;
  }
  .choice-button {
    font-size: 10px;
    padding: 5px;
  }
  .collection .intro h1 {
    font-size: 30px;
  }
  .collection .intro p {
    font-size: 12px;
  }
  .collection #ribbon {
    font-size: 16px;
  }
}
@media (max-height: 650px) {
  .collection .intro {
    padding-bottom: 18px;
  }
  .collection .intro h1 {
    font-size: 27px;
  }
  .collection .intro p {
    font-size: 12px;
    margin-bottom: 12px;
  }
  .collection .scene-caption {
    top: 7px;
  }
  .collection #ribbon {
    top: 22px;
  }
  .note-chip {
    font-size: 10px;
    padding: 5px;
  }
}
@media (orientation: landscape) and (max-height: 550px) {
  .collection .game-shell {
    max-width: none;
  }
  .collection header {
    padding: 6px 12px;
  }
  .collection .mission-card,
  .collection.playing .mission-card {
    top: 61px;
    left: 0;
    width: 240px;
    margin: 0 10px;
  }
  .collection #mission {
    font-size: 11px;
    min-height: 0;
  }
  .collection .dock {
    width: 260px;
    padding: 3px 10px;
    bottom: 0;
  }
  .collection #stage {
    margin-left: 270px;
    margin-top: 58px;
    margin-bottom: 8px;
  }
  .collection .intro {
    background: linear-gradient(90deg, var(--world) 30%, transparent 85%);
    padding: 55px 20px 10px;
  }
  .collection .intro-card {
    max-width: 255px;
  }
  .collection .intro h1 {
    font-size: 26px;
  }
  .collection .intro p {
    font-size: 11px;
  }
  .collection #ribbon {
    top: 3px;
    font-size: 15px;
  }
  .collection #announcement {
    left: 65%;
    bottom: 15px;
  }
  .collection .collection-bottom button {
    font-size: 9px;
  }
  .collection .dialog-backdrop > section {
    overflow: auto;
  }
  .collection .dialog-backdrop .primary {
    min-height: 44px;
  }
}

.note-chip[data-note="0"] {
  --note-color: #eeb3c6;
}
.note-chip[data-note="1"] {
  --note-color: #edcf89;
}
.note-chip[data-note="2"] {
  --note-color: #a1ceba;
}
.note-chip[data-note="3"] {
  --note-color: #a5cfdf;
}
.note-chip:not(.done) {
  background: var(--note-color);
  color: #344f50;
}
.note-chip.current {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
