:root {
  --paper: #f4f3ed;
  --ink: #203c35;
  --muted: #69776e;
  --accent: #2f755d;
  --bright: #d9ee99;
  --line: #dce2d5;
  --card: #fffef9;
  --shadow: 0 16px 50px #253a2010;
  font-family: ui-rounded, "Avenir Next", "Trebuchet MS", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
a {
  font: inherit;
}
button,
a {
  touch-action: manipulation;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
  opacity: 0.45;
}
button:focus-visible,
a:focus-visible,
canvas:focus-visible {
  outline: 3px solid #df923d;
  outline-offset: 4px;
}
button {
  color: inherit;
}
a {
  color: inherit;
  text-decoration: none;
}
[hidden] {
  display: none !important;
}
.topbar {
  max-width: 1512px;
  padding: 24px 4.5%;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line);
}
.brand {
  font-size: 15px;
  letter-spacing: 1.3px;
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}
.brand b {
  font-weight: 850;
}
.brand-mark {
  background: var(--ink);
  color: var(--bright);
  display: grid;
  place-items: center;
  width: 33px;
  height: 33px;
  border-radius: 10px;
  margin-right: 8px;
  font-size: 25px;
}
.edition {
  font-size: 8px;
  letter-spacing: 1.7px;
  color: var(--muted);
  margin-left: 14px;
  width: 78px;
  white-space: normal;
  line-height: 1.5;
}
nav {
  display: flex;
  gap: 7px;
}
.nav {
  background: none;
  border: 0;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 700;
  border-radius: 20px;
  color: var(--muted);
}
.nav.active {
  background: #e4e9db;
  color: var(--ink);
}
.utilities {
  display: flex;
  gap: 8px;
}
.icon {
  background: transparent;
  border: 1px solid var(--line);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 19px;
}
.icon:hover {
  background: white;
}
main {
  max-width: 1400px;
  margin: auto;
  padding: 38px 4.5% 16px;
}
.intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 30px;
}
.eyebrow {
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 2px;
  margin: 0 0 13px;
  color: var(--accent);
}
h1 {
  font-size: clamp(32px, 3.2vw, 48px);
  letter-spacing: -1.7px;
  line-height: 1.05;
  margin: 0 0 12px;
  font-weight: 850;
}
#subheading {
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
  color: var(--muted);
}
.profile-block {
  min-width: 325px;
}
.profile-switch {
  display: flex;
  padding: 6px;
  background: #e9eae1;
  border: 1px solid var(--line);
  border-radius: 17px;
  gap: 8px;
}
.profile {
  display: flex;
  align-items: center;
  gap: 11px;
  border: 1px solid transparent;
  background: none;
  padding: 12px 16px;
  border-radius: 12px;
  text-align: left;
  flex: 1;
  font-size: 15px;
  font-weight: 800;
  min-height: 65px;
}
.profile.active {
  background: var(--card);
  box-shadow: 0 3px 9px #2437210a;
  border-color: #dde3d6;
}
.profile small {
  font-size: 8px;
  letter-spacing: 1.2px;
  display: block;
  margin-top: 5px;
  color: var(--muted);
  white-space: nowrap;
}
.avatar {
  display: grid;
  place-items: center;
  width: 33px;
  height: 37px;
  border-radius: 11px;
  color: white;
  font-weight: 900;
  box-shadow: inset 0 -4px #0002;
}
.avatar.willow {
  background: #58836a;
}
.avatar.tempest {
  background: #5965a2;
}
.profile-meta {
  display: flex;
  justify-content: space-between;
  padding: 14px 8px 0;
  font-size: 11px;
  color: var(--muted);
}
#wallet {
  color: var(--accent);
  font-weight: 800;
}
.adventure-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.85fr) minmax(290px, 1fr);
  gap: 24px;
  align-items: stretch;
}
.world-card {
  position: relative;
  overflow: hidden;
  border-radius: 23px;
  background: #dbead9;
  min-width: 0;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow);
}
.world-topline,
.world-bottomline {
  position: absolute;
  left: 25px;
  right: 25px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  pointer-events: none;
  z-index: 1;
}
.world-topline {
  top: 23px;
}
.world-tag {
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 1.5px;
  color: #325b48;
}
.world-status {
  font-size: 8px;
  background: #ffffff9e;
  border: 1px solid #fff8;
  border-radius: 15px;
  padding: 7px 10px;
  font-weight: 800;
  letter-spacing: 1px;
  color: #456152;
}
.world-bottomline {
  bottom: 19px;
  color: #5f7e68;
  font-size: 10px;
}
#world-controls {
  font-size: 9px;
  opacity: 0.85;
}
#world {
  width: 100%;
  height: 100%;
  min-height: 430px;
  display: block;
  object-fit: contain;
  outline-offset: -5px;
}
.mission-panel {
  border: 1px solid var(--line);
  border-radius: 23px;
  background: var(--card);
  padding: 27px;
  box-shadow: var(--shadow);
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.panel-kicker {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 9px;
  letter-spacing: 1.5px;
  font-weight: 850;
  color: var(--accent);
}
.pill {
  padding: 6px 9px;
  border-radius: 20px;
  background: #edf1e5;
  font-size: 9px;
  letter-spacing: 0.5px;
}
.mission-panel h2 {
  font-size: 27px;
  letter-spacing: -0.8px;
  line-height: 1.13;
  margin: 0;
}
.mission-panel p {
  font-size: 13px;
  line-height: 1.65;
  color: var(--muted);
  margin: 0;
}
.mission-panel .primary {
  margin-top: auto;
}
.primary,
.secondary {
  border: 0;
  border-radius: 12px;
  padding: 15px 17px;
  min-height: 49px;
  font-size: 13px;
  font-weight: 800;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}
.primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 5px 0 #183a2d16;
  transition:
    transform 0.15s,
    filter 0.15s;
}
.primary:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}
.secondary {
  background: #edf0e7;
  color: var(--ink);
  border: 1px solid var(--line);
}
.quiet {
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 11px;
  text-decoration: underline;
  text-underline-offset: 3px;
  padding: 8px;
}
.track-choices {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.track {
  border: 1px solid var(--line);
  background: none;
  border-radius: 11px;
  padding: 13px;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 10px;
}
.track.selected {
  border-color: var(--accent);
  background: #eef3e6;
}
.track .check {
  border: 1px solid #c5cfc0;
  border-radius: 50%;
  height: 16px;
  width: 16px;
  display: grid;
  place-items: center;
  font-size: 10px;
}
.track.selected .check {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}
.track strong {
  font-size: 12px;
  display: block;
}
.track small {
  font-size: 10px;
  display: block;
  margin-top: 4px;
  color: var(--muted);
}
.settings-inline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 11px;
  color: var(--muted);
}
.segmented {
  display: flex;
  background: #edf0e7;
  padding: 3px;
  border-radius: 8px;
}
.segmented button {
  border: 0;
  background: none;
  padding: 7px 9px;
  font-size: 10px;
  border-radius: 6px;
}
.segmented .selected {
  background: white;
  box-shadow: 0 1px 4px #0001;
  font-weight: 800;
}
.reward-preview {
  display: flex;
  gap: 12px;
  align-items: center;
  border-top: 1px dashed var(--line);
  padding-top: 15px;
}
.reward-token {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  background: #f3e9c9;
  border-radius: 12px;
  color: #b18831;
  font-size: 25px;
}
.reward-preview strong {
  font-size: 11px;
  display: block;
}
.reward-preview small {
  font-size: 10px;
  color: var(--muted);
  display: block;
  margin-top: 4px;
}
.team-button {
  width: 100%;
  background: transparent;
  border: 1px dashed #afbdac;
  border-radius: 11px;
  padding: 13px;
  font-size: 11px;
  font-weight: 750;
  color: var(--accent);
}
footer {
  display: flex;
  align-items: center;
  gap: 25px;
  justify-content: space-between;
  margin: 24px 0 0;
  color: #899184;
  font-size: 10px;
}
footer button {
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 10px;
  cursor: pointer;
}
.steps {
  display: flex;
  gap: 5px;
  margin-bottom: 4px;
}
.step {
  height: 5px;
  flex: 1;
  border-radius: 4px;
  background: #e8eddf;
}
.step.done {
  background: var(--accent);
}
.step.current {
  background: #c3dba6;
}
.destination {
  display: flex;
  text-align: left;
  align-items: center;
  gap: 13px;
  padding: 15px;
  border: 1px solid var(--line);
  background: white;
  border-radius: 13px;
  min-height: 64px;
}
.destination:hover {
  border-color: var(--accent);
  background: #f5f8ef;
}
.destination strong {
  font-size: 13px;
  display: block;
}
.destination small {
  font-size: 10px;
  color: var(--muted);
  display: block;
  margin-top: 4px;
}
.destination-icon {
  font-size: 23px;
  width: 31px;
  text-align: center;
}
.mission-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.mission-top button {
  border: 0;
  background: #edf0e7;
  border-radius: 7px;
  padding: 7px;
  font-size: 11px;
}
.resource-row {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
}
.resource {
  font-size: 10px;
  padding: 7px 10px;
  background: #eef0e6;
  border-radius: 8px;
  font-weight: 700;
}
.prompt {
  font-size: 18px !important;
  line-height: 1.4 !important;
  color: var(--ink) !important;
  font-weight: 750;
}
.math-visual {
  min-height: 82px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #f5f7ee;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 7px;
}
.array {
  display: grid;
  gap: 3px;
  width: fit-content;
  max-width: 100%;
}
.array i {
  width: 15px;
  height: 15px;
  background: #87b393;
  border-radius: 3px;
  border: 1px solid #568a6d;
}
.array i.flower {
  background: #e6ac60;
  border-color: #c98136;
}
.array i.dim {
  background: #e5e7d9;
  border-color: #ced3c0;
}
.math-visual small {
  color: var(--muted);
  font-size: 10px;
}
.visual-equation {
  font-size: 26px;
  font-weight: 850;
  letter-spacing: 2px;
}
.ratio-table {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  width: 100%;
  text-align: center;
  font-size: 14px;
}
.ratio-table b {
  padding: 6px;
  background: white;
  border-radius: 6px;
}
.ratio-table small {
  display: block;
  font-size: 9px;
}
.number-line {
  display: flex;
  width: 100%;
  justify-content: space-around;
  padding: 8px 0;
  border-bottom: 2px solid #b8c4ae;
  font-size: 16px;
}
.number-line b {
  padding: 5px 8px;
  border-radius: 6px;
  background: #dce9cb;
}
.answer-label {
  font-size: 10px;
  font-weight: 800;
  color: var(--muted);
  display: block;
  margin-bottom: 7px;
}
.answer-entry {
  display: flex;
  gap: 8px;
}
.answer-entry input {
  width: 0;
  min-width: 0;
  flex: 1;
  padding: 12px;
  border: 2px solid var(--line);
  border-radius: 10px;
  font-size: 20px;
  background: white;
  color: var(--ink);
}
.answer-entry input:focus {
  outline: none;
  border-color: var(--accent);
}
.answer-entry button {
  margin: 0 !important;
  padding: 12px 15px;
}
.input-help {
  font-size: 10px !important;
  margin-top: 6px !important;
}
.hint {
  background: #fff0d0;
  border-left: 3px solid #dca85e;
  border-radius: 0 8px 8px 0;
  padding: 12px;
  font-size: 12px;
  line-height: 1.6;
  color: #755b29;
}
.feedback {
  font-size: 12px;
  line-height: 1.5;
  padding: 10px;
  border-radius: 9px;
  background: #eff3e9;
}
.feedback.good {
  background: #e3efcf;
  color: #3c6038;
}
.actions-row {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}
.positive-icon {
  font-size: 32px;
  color: var(--accent);
  background: #e6efd7;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  display: grid;
  place-items: center;
}
.toast {
  position: absolute;
  left: 50%;
  bottom: 62px;
  transform: translateX(-50%);
  padding: 11px 17px;
  background: #fcfff5ed;
  border-radius: 30px;
  color: #2d5d43;
  font-size: 12px;
  font-weight: 750;
  box-shadow: 0 6px 20px #26452018;
  max-width: 85%;
  text-align: center;
  opacity: 0;
  transition: opacity 0.2s;
  pointer-events: none;
}
.toast.visible {
  opacity: 1;
}
.overlay {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: #10271c80;
  backdrop-filter: blur(7px);
  display: grid;
  place-items: center;
  padding: 22px;
}
.modal {
  max-width: 460px;
  width: 100%;
  background: var(--card);
  border-radius: 24px;
  padding: 33px;
  box-shadow: 0 25px 80px #0003;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.modal h2 {
  font-size: 30px;
  letter-spacing: -1px;
  margin: 0;
}
.modal p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
}
.modal .primary {
  width: 100%;
}
.handoff-avatar {
  font-size: 44px;
  border-radius: 19px;
  width: 70px;
  height: 70px;
  display: grid;
  place-items: center;
  background: #e8eddb;
  color: var(--accent);
}
.view-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin: 0 0 25px;
}
.view-heading h2 {
  font-size: 30px;
  margin: 0 0 8px;
  letter-spacing: -1px;
}
.view-heading p {
  font-size: 13px;
  color: var(--muted);
  margin: 0;
}
.collection-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.item-card {
  padding: 24px;
  background: var(--card);
  border-radius: 20px;
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.item-art {
  height: 110px;
  display: grid;
  place-items: center;
  font-size: 57px;
  border-radius: 13px;
  background: #edf0e4;
}
.item-card h3 {
  margin: 0;
  font-size: 16px;
}
.item-card p {
  font-size: 11px;
  color: var(--muted);
  margin: 0;
}
.item-card button {
  width: 100%;
  margin-top: auto;
}
.journal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 25px;
}
.journal-card {
  background: var(--card);
  padding: 27px;
  border: 1px solid var(--line);
  border-radius: 20px;
}
.journal-card h3 {
  margin: 0 0 20px;
  font-size: 18px;
}
.skill-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
}
.skill-dots {
  display: flex;
  gap: 4px;
}
.skill-dots i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #d6dfca;
}
.skill-dots i.done {
  background: var(--accent);
}
.session {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.session small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  margin-top: 5px;
}
.empty {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.7;
}
.journal-actions {
  display: flex;
  gap: 10px;
  margin-top: 22px;
  flex-wrap: wrap;
}
.storage-warning {
  background: #fff0d0;
  color: #755b29;
  padding: 12px 5%;
  font-size: 12px;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}
body[data-player="Tempest"] {
  --ink: #29364f;
  --accent: #535dad;
  --bright: #b8dff0;
  --muted: #747d90;
  --line: #dcdfe7;
}
.world-card.tempest {
  background: #222f50;
}
.tempest .world-tag {
  color: #a5c5e2;
}
.tempest .world-status {
  background: #3c517696;
  border-color: #57799d55;
  color: #afd9e6;
}
.tempest .world-bottomline {
  color: #9bb3d0;
}
.compact .intro {
  margin-bottom: 20px;
}
.compact h1 {
  font-size: 32px;
}
.compact #subheading {
  font-size: 12px;
}
.compact .eyebrow {
  margin-bottom: 8px;
}
.compact .mission-panel {
  gap: 14px;
}
.compact .mission-panel h2 {
  font-size: 24px;
}
.compact #world {
  min-height: 485px;
}
.team-progress {
  font-size: 12px;
  font-weight: 750;
  padding: 12px;
  background: #f0ebd9;
  border-radius: 9px;
  color: #81713e;
}
.mini-stars {
  font-size: 22px;
  color: #bea04d;
  letter-spacing: 5px;
}
.reward-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.reward-summary div {
  background: #f0f3e8;
  border-radius: 10px;
  padding: 14px;
  font-size: 10px;
  color: var(--muted);
}
.reward-summary b {
  display: block;
  font-size: 23px;
  color: var(--ink);
  margin-bottom: 4px;
}
@media (min-width: 1450px) {
  main {
    padding-top: 42px;
  }
  .world-card {
    min-height: 530px;
  }
}
@media (max-width: 1000px) {
  .edition {
    display: none;
  }
  .topbar {
    padding: 18px 4%;
    gap: 12px;
  }
  .nav {
    padding: 9px 10px;
    font-size: 12px;
  }
  .adventure-layout {
    grid-template-columns: minmax(0, 1.4fr) minmax(275px, 1fr);
    gap: 16px;
  }
  .mission-panel {
    padding: 21px;
  }
  .world-topline,
  .world-bottomline {
    left: 18px;
    right: 18px;
  }
  #world-controls {
    display: none;
  }
  .collection-grid {
    grid-template-columns: 1fr 1fr;
  }
  .profile-block {
    min-width: 290px;
  }
  .profile {
    padding: 10px;
  }
  .profile-switch {
    gap: 3px;
  }
}
@media (max-width: 740px) {
  .topbar {
    flex-wrap: wrap;
    padding: 16px 5%;
    gap: 14px;
  }
  .brand {
    font-size: 13px;
    flex: 1;
  }
  .utilities {
    order: 1;
  }
  .topbar nav {
    order: 2;
    width: 100%;
    justify-content: space-between;
    border-top: 1px solid var(--line);
    padding-top: 12px;
  }
  .nav {
    padding: 8px 14px;
  }
  .intro {
    flex-direction: column;
    align-items: stretch;
    gap: 22px;
    margin-bottom: 23px;
  }
  main {
    padding: 25px 5% 16px;
  }
  h1 {
    font-size: 37px;
  }
  .intro br {
    display: none;
  }
  #subheading {
    font-size: 13px;
    max-width: 300px;
  }
  .profile-block {
    min-width: 0;
  }
  .profile-meta {
    font-size: 10px;
  }
  .profile-switch {
    max-width: none;
  }
  .profile {
    padding: 11px 18px;
  }
  .adventure-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .world-card {
    min-height: 0;
  }
  .world-topline {
    top: 17px;
  }
  #world,
  .compact #world {
    height: auto;
    min-height: 0;
    aspect-ratio: 1.45;
  }
  .world-bottomline {
    bottom: 15px;
    font-size: 9px;
  }
  .world-status {
    font-size: 7px;
    padding: 5px 8px;
  }
  .world-tag {
    font-size: 8px;
  }
  .mission-panel {
    padding: 23px;
    gap: 18px;
  }
  .mission-panel h2 {
    font-size: 28px;
  }
  .compact .intro {
    gap: 15px;
  }
  .compact h1 {
    font-size: 27px;
  }
  .compact .profile-block {
    display: none;
  }
  .compact #subheading {
    max-width: none;
  }
  .compact .eyebrow {
    font-size: 9px;
  }
  .world-card {
    border-radius: 18px;
  }
  .journal-grid {
    grid-template-columns: 1fr;
  }
  .collection-grid {
    gap: 12px;
  }
  .item-card {
    padding: 15px;
    gap: 12px;
  }
  .item-art {
    height: 90px;
    font-size: 45px;
  }
  .item-card h3 {
    font-size: 14px;
  }
  .item-card button {
    font-size: 11px;
    padding: 12px 8px;
  }
  .view-heading {
    align-items: flex-start;
    gap: 16px;
  }
  .view-heading h2 {
    font-size: 25px;
  }
  .view-heading .secondary {
    font-size: 11px;
    padding: 12px;
  }
  footer {
    font-size: 9px;
    gap: 10px;
  }
  footer span:first-child {
    display: none;
  }
  .answer-entry input {
    min-height: 49px;
  }
  .array i {
    width: 19px;
    height: 19px;
  }
  .prompt {
    font-size: 19px !important;
  }
  .toast {
    font-size: 10px;
    bottom: 42px;
  }
  .team-button {
    min-height: 48px;
  }
  .icon {
    min-width: 35px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

.mission-panel {
  scroll-margin-top: 14px;
}
