/* ===========================================================
   Персик — app shell, screens and teaching cards
   =========================================================== */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  background: var(--c-bg);
  background-image:
    radial-gradient(circle at 12% 8%,  rgba(255, 201, 60, .20)  0 22%, transparent 22.5%),
    radial-gradient(circle at 88% 14%, rgba(53, 183, 245, .16) 0 18%, transparent 18.5%),
    radial-gradient(circle at 78% 82%, rgba(255, 90, 54, .12)  0 24%, transparent 24.5%),
    radial-gradient(circle at 18% 88%, rgba(76, 198, 62, .14)  0 20%, transparent 20.5%);
  background-attachment: fixed;
  color: var(--c-ink);
  font-family: var(--font);
  font-weight: 700;
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3 { margin: 0 0 .4em; line-height: 1.15; font-weight: 900; }
h1 { font-size: 2rem; }
h2 { font-size: 1.5rem; }
p  { margin: 0 0 .8em; }

.emoji { font-family: var(--font-emoji); font-weight: 400; }

button { font-family: inherit; }

/* ---------- chunky 3-D buttons ---------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  min-height: 58px;
  padding: 0 28px;
  border: none;
  border-radius: var(--r-md);
  background: var(--c-persiq);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 900;
  letter-spacing: .02em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: var(--shadow-btn) var(--c-persiq-dk);
  transition: transform var(--t-fast) var(--ease),
              box-shadow var(--t-fast) var(--ease),
              filter var(--t-fast) var(--ease);
  user-select: none;
}
.btn:hover:not(:disabled)  { filter: brightness(1.06); }
.btn:active:not(:disabled) { transform: translateY(4px); box-shadow: 0 0 0 var(--c-persiq-dk); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn:focus-visible { outline: 4px solid var(--c-sun); outline-offset: 3px; }

.btn--grass { background: var(--c-grass);  box-shadow: var(--shadow-btn) var(--c-grass-dk); }
.btn--grass:active:not(:disabled) { box-shadow: 0 0 0 var(--c-grass-dk); }
.btn--sky   { background: var(--c-blip);   box-shadow: var(--shadow-btn) var(--c-blip-dk); }
.btn--sky:active:not(:disabled)   { box-shadow: 0 0 0 var(--c-blip-dk); }
.btn--sun   { background: var(--c-sun);    color: var(--c-ink); box-shadow: var(--shadow-btn) var(--c-sun-dk); }
.btn--sun:active:not(:disabled)   { box-shadow: 0 0 0 var(--c-sun-dk); }

.btn--ghost {
  background: var(--c-surface);
  color: var(--c-ink-soft);
  border: var(--border);
  box-shadow: var(--shadow-btn) var(--c-line);
}
.btn--ghost:active:not(:disabled) { box-shadow: 0 0 0 var(--c-line); }

.btn--sm { min-height: 46px; padding: 0 18px; font-size: .9rem; }
.btn--wide { width: 100%; }

/* round icon button (speaker etc.) */
.icon-btn {
  width: 58px; height: 58px;
  flex: 0 0 auto;
  display: grid; place-items: center;
  border: var(--border);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: var(--shadow-btn) var(--c-line);
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.icon-btn:hover  { background: var(--c-bg-deep); }
.icon-btn:active { transform: translateY(4px); box-shadow: 0 0 0 var(--c-line); }
.icon-btn.is-playing { animation: pulse .7s var(--ease) infinite; border-color: var(--c-theme); }
.icon-btn--sm { width: 44px; height: 44px; font-size: 1.1rem; }

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.11); }
}

/* ---------- layout --------------------------------------- */
.app { min-height: 100vh; display: flex; flex-direction: column; }

.screen {
  flex: 1;
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  padding: 20px 20px 56px;
  animation: screen-in .34s var(--spring) both;
}
@keyframes screen-in {
  from { opacity: 0; transform: translateY(14px) scale(.985); }
  to   { opacity: 1; transform: none; }
}

/* ---------- top bar -------------------------------------- */
/* `display:flex` would otherwise beat the [hidden] attribute */
.topbar[hidden] { display: none; }

.topbar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 14px;
  padding: 12px 20px;
  background: rgba(255, 247, 236, .92);
  backdrop-filter: blur(8px);
  border-bottom: var(--border);
}
.topbar__brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 900; font-size: 1.1rem;
  margin-right: auto;
  background: none; border: none; padding: 0; cursor: pointer;
  color: var(--c-ink); font-family: inherit;
}
.topbar__brand svg { width: 38px; height: 38px; }
.topbar__stat {
  display: flex; align-items: center; gap: 6px;
  font-weight: 900; font-size: 1.05rem;
  padding: 6px 12px;
  border-radius: var(--r-pill);
  background: var(--c-surface);
  border: var(--border);
  white-space: nowrap;
}
.topbar__stat--xp     { color: var(--c-sun-dk); }
.topbar__stat--streak { color: var(--c-flame); }
.topbar__stat--hearts { color: var(--c-wrong); }

/* ---------- onboarding ----------------------------------- */
.hello {
  display: flex; flex-direction: column; align-items: center;
  text-align: center;
  padding-top: 24px;
}
.hello__art { width: 210px; height: 210px; }
.hello__art svg { width: 100%; height: 100%; }
.hello h1 { font-size: 2.3rem; color: var(--c-persiq); }
.hello__sub { color: var(--c-ink-soft); max-width: 34ch; margin-bottom: 26px; }

.field {
  width: 100%; max-width: 420px;
  display: flex; flex-direction: column; gap: 10px; align-items: stretch;
}
.field label { font-weight: 900; text-align: left; }
.field input {
  width: 100%;
  min-height: 62px;
  padding: 0 18px;
  font-family: inherit; font-size: 1.25rem; font-weight: 800;
  color: var(--c-ink);
  background: var(--c-surface);
  border: var(--border);
  border-radius: var(--r-md);
  transition: border-color var(--t-fast) var(--ease);
}
.field input:focus {
  outline: none;
  border-color: var(--c-persiq);
  box-shadow: 0 0 0 4px var(--c-persiq-lt);
}

/* ---------- speech bubble (shared with mascot.js) --------- */
.bubble-row { display: flex; align-items: flex-end; gap: 12px; }
.bubble-row svg { flex: 0 0 auto; }
.bubble {
  position: relative;
  background: var(--c-surface);
  border: var(--border);
  border-radius: var(--r-lg);
  padding: 14px 18px;
  font-weight: 800;
  box-shadow: var(--shadow-card);
}
.bubble::before,
.bubble::after {
  content: '';
  position: absolute; left: -13px; bottom: 18px;
  border: 7px solid transparent;
  border-right-color: var(--c-line);
}
.bubble::after {
  left: -8px;
  border-right-color: var(--c-surface);
}

/* ---------- lesson map ----------------------------------- */
.map__head {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 26px;
  padding: 18px 20px;
  background: var(--c-surface);
  border: var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}
.map__head svg { width: 78px; height: 78px; flex: 0 0 auto; }
.map__hi { font-size: 1.35rem; font-weight: 900; }
.map__hi span { color: var(--c-persiq); }
.map__sub { color: var(--c-ink-soft); font-size: .95rem; }

.unit {
  margin: 30px 0 18px;
  display: flex; align-items: center; gap: 12px;
}
.unit__label {
  padding: 7px 18px;
  border-radius: var(--r-pill);
  background: var(--c-theme);
  color: #fff;
  font-weight: 900;
  font-size: .9rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  box-shadow: 0 3px 0 var(--c-theme-dk);
}
.unit__rule { flex: 1; height: 3px; background: var(--c-line); border-radius: 2px; }

.path { display: flex; flex-direction: column; gap: 4px; }

.node {
  display: flex; align-items: center; gap: 16px;
  width: 100%;
  padding: 14px 18px;
  background: var(--c-surface);
  border: var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  cursor: pointer;
  text-align: left;
  font-family: inherit; color: inherit;
  transition: transform var(--t-fast) var(--spring),
              border-color var(--t-fast) var(--ease);
}
.node:hover:not(.node--locked) { transform: translateX(6px); border-color: var(--c-theme); }
.node:focus-visible { outline: 4px solid var(--c-sun); outline-offset: 3px; }
.node--locked { opacity: .55; cursor: not-allowed; filter: grayscale(.5); }
.node--done { border-color: var(--c-grass); }

.node__badge {
  width: 66px; height: 66px; flex: 0 0 auto;
  display: grid; place-items: center;
  border-radius: var(--r-pill);
  background: var(--c-theme);
  color: #fff;
  font-size: 1.9rem;
  box-shadow: 0 4px 0 var(--c-theme-dk);
}
.node--locked .node__badge { background: var(--c-line); box-shadow: 0 4px 0 #cdc4b6; }
.node__body { flex: 1; min-width: 0; }
.node__n { font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--c-ink-soft); }
.node__title { font-size: 1.12rem; font-weight: 900; }
.node__sub { font-size: .9rem; color: var(--c-ink-soft); }
.node__stars { font-size: 1.05rem; letter-spacing: 2px; white-space: nowrap; }

.path__link {
  width: 4px; height: 16px;
  margin-left: 50px;
  background: var(--c-line);
  border-radius: 2px;
}

/* ---------- lesson player -------------------------------- */
.lesson__bar {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 22px;
}
.progress {
  flex: 1; height: 18px;
  background: var(--c-bg-deep);
  border: var(--border);
  border-radius: var(--r-pill);
  overflow: hidden;
}
.progress__fill {
  height: 100%;
  width: 0;
  background: var(--c-theme);
  border-radius: var(--r-pill);
  transition: width var(--t-med) var(--ease);
}
.lesson__count { font-size: .9rem; color: var(--c-ink-soft); white-space: nowrap; }

.card {
  background: var(--c-surface);
  border: var(--border);
  border-radius: var(--r-xl);
  padding: 30px 26px;
  box-shadow: var(--shadow-card);
  text-align: center;
  animation: card-in .36s var(--spring) both;
}
@keyframes card-in {
  from { opacity: 0; transform: translateY(22px) scale(.96); }
  to   { opacity: 1; transform: none; }
}

.card__kicker {
  font-size: .78rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--c-theme-dk); font-weight: 900; margin-bottom: 10px;
}

/* letter card */
.letter-hero {
  display: inline-flex; align-items: baseline; gap: 10px;
  padding: 14px 34px;
  border-radius: var(--r-lg);
  background: var(--c-theme);
  color: #fff;
  box-shadow: 0 5px 0 var(--c-theme-dk);
  margin-bottom: 16px;
}
.letter-hero b { font-size: 4.6rem; font-weight: 900; line-height: 1; }
.letter-hero i { font-size: 3.2rem; font-weight: 900; font-style: normal; line-height: 1; opacity: .9; }

.letter-meta {
  display: flex; justify-content: center; gap: 12px; flex-wrap: wrap;
  margin-bottom: 14px;
}
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px;
  border-radius: var(--r-pill);
  background: var(--c-bg-deep);
  border: 3px solid var(--c-line);
  font-weight: 900; font-size: .98rem;
}
.chip small { font-weight: 800; color: var(--c-ink-soft); font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; }

.note {
  color: var(--c-ink-soft);
  max-width: 46ch;
  margin: 0 auto 20px;
  font-weight: 700;
}

.examples { display: flex; flex-direction: column; gap: 10px; }
.example {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 16px;
  background: var(--c-bg);
  border: 3px solid var(--c-line);
  border-radius: var(--r-md);
  cursor: pointer;
  text-align: left;
  font-family: inherit; color: inherit; font-size: 1rem;
  transition: transform var(--t-fast) var(--spring), border-color var(--t-fast) var(--ease);
}
.example:hover  { border-color: var(--c-theme); transform: translateY(-2px); }
.example:active { transform: translateY(1px); }
.example__emoji { font-size: 2.1rem; font-family: var(--font-emoji); }
.example__en { font-weight: 900; font-size: 1.15rem; }
.example__ru { color: var(--c-ink-soft); font-size: .95rem; }
.example__spk { margin-left: auto; font-size: 1.3rem; opacity: .55; }

/* word card */
.word-hero { font-size: 5rem; line-height: 1; font-family: var(--font-emoji); margin-bottom: 8px; }
.word-en {
  font-size: 3rem; font-weight: 900; letter-spacing: .04em;
  color: var(--c-theme-dk); cursor: pointer;
  background: none; border: none; font-family: inherit;
  display: inline-flex; align-items: center; gap: 12px;
}
.word-ru { font-size: 1.3rem; color: var(--c-ink-soft); margin-bottom: 18px; }

.blend { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.blend__part {
  min-width: 74px;
  padding: 12px 14px;
  border-radius: var(--r-md);
  background: var(--c-bg-deep);
  border: 3px solid var(--c-line);
  cursor: pointer;
  font-family: inherit; color: inherit;
  transition: transform var(--t-fast) var(--spring), border-color var(--t-fast) var(--ease);
}
.blend__part:hover { border-color: var(--c-theme); transform: translateY(-3px); }
.blend__part b { display: block; font-size: 1.9rem; font-weight: 900; line-height: 1; }
.blend__part span { display: block; font-size: .95rem; color: var(--c-ink-soft); margin-top: 4px; }
.blend__plus { align-self: center; font-size: 1.4rem; color: var(--c-ink-soft); font-weight: 900; }

/* phrase card */
.phrase-en {
  font-size: 2.1rem; font-weight: 900; color: var(--c-theme-dk);
  background: none; border: none; font-family: inherit; cursor: pointer;
  display: inline-flex; align-items: center; gap: 14px; flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 6px;
}
.phrase-ru { font-size: 1.2rem; color: var(--c-ink-soft); margin-bottom: 16px; }

/* tip card */
.card--tip { background: var(--c-sun); border-color: var(--c-sun-dk); text-align: left; }
.card--tip .note { color: var(--c-ink); max-width: none; }
.card--tip h2 { color: var(--c-ink); }

/* card navigation */
.lesson__nav {
  display: flex; gap: 12px; align-items: center;
  margin-top: 24px;
}
.lesson__nav .btn { flex: 1; }

/* ---------- lesson intro / outro ------------------------- */
.goals { list-style: none; padding: 0; margin: 0 0 22px; text-align: left; }
.goals li {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 12px 16px; margin-bottom: 10px;
  background: var(--c-bg);
  border: 3px solid var(--c-line);
  border-radius: var(--r-md);
  font-weight: 800;
}
.goals li::before {
  content: '✓';
  flex: 0 0 auto;
  width: 28px; height: 28px;
  display: grid; place-items: center;
  border-radius: var(--r-pill);
  background: var(--c-grass); color: #fff;
  font-size: .95rem;
}

.result-stars { font-size: 3.4rem; letter-spacing: 8px; margin: 6px 0 4px; font-family: var(--font-emoji); }
.result-score { font-size: 1.25rem; color: var(--c-ink-soft); margin-bottom: 8px; }
.result-xp {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; margin-bottom: 22px;
  border-radius: var(--r-pill);
  background: var(--c-sun); color: var(--c-ink);
  font-weight: 900; font-size: 1.1rem;
  box-shadow: 0 4px 0 var(--c-sun-dk);
}
.downloads { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }

/* ---------- misc ----------------------------------------- */
.stack   { display: flex; flex-direction: column; gap: 14px; }
.center  { text-align: center; }
.muted   { color: var(--c-ink-soft); }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.toast {
  position: fixed; left: 50%; bottom: 26px;
  transform: translateX(-50%) translateY(120%);
  z-index: 90;
  padding: 14px 24px;
  border-radius: var(--r-pill);
  background: var(--c-ink); color: #fff;
  font-weight: 800;
  box-shadow: var(--shadow-pop);
  max-width: 90vw; text-align: center;
  /* opacity + visibility, not the transform alone: an empty toast is too
     short for a percentage translate to clear the bottom of the viewport,
     so it used to peek above the edge. */
  opacity: 0;
  visibility: hidden;
  transition: transform .32s var(--spring),
              opacity .22s var(--ease),
              visibility 0s linear .32s;
}
.toast.is-open {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  visibility: visible;
  transition: transform .32s var(--spring),
              opacity .22s var(--ease),
              visibility 0s linear 0s;
}

/* confetti for the completion screen */
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 80; overflow: hidden; }
.confetti i {
  position: absolute; top: -14px;
  width: 11px; height: 16px;
  border-radius: 3px;
  animation: fall linear forwards;
}
@keyframes fall {
  to { transform: translateY(105vh) rotate(720deg); opacity: .25; }
}

/* ---------- responsive ----------------------------------- */
@media (max-width: 640px) {
  body { font-size: 16px; }
  .screen { padding: 16px 14px 44px; }
  .topbar { padding: 10px 14px; gap: 8px; }
  .topbar__brand span { display: none; }
  .topbar__stat { padding: 5px 10px; font-size: .95rem; }
  .card { padding: 22px 16px; border-radius: var(--r-lg); }
  .letter-hero b { font-size: 3.4rem; }
  .letter-hero i { font-size: 2.4rem; }
  .word-en { font-size: 2.3rem; }
  .phrase-en { font-size: 1.6rem; }
  .node__badge { width: 56px; height: 56px; font-size: 1.55rem; }
  .hello__art { width: 165px; height: 165px; }
  .lesson__nav { flex-direction: column-reverse; }
  .lesson__nav .btn { width: 100%; }
}

@media print { .topbar, .lesson__nav, .btn { display: none !important; } }

/* ---------- answer feedback bar --------------------------- */
.fb {
  position: sticky;
  bottom: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
  padding: 16px 18px;
  border: var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  animation: fb-in .3s var(--spring) both;
}
.fb--ok { background: var(--c-grass-lt); border-color: var(--c-grass); }
.fb--no { background: var(--c-wrong-lt); border-color: var(--c-wrong); }

.fb__art { flex: 0 0 auto; width: 64px; height: 64px; }
.fb__art svg { width: 100%; height: 100%; }

.fb__text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.fb__text b { font-size: 1.15rem; font-weight: 900; }
.fb--ok .fb__text b { color: var(--c-grass-dk); }
.fb--no .fb__text b { color: var(--c-wrong-dk); }
.fb__text span { font-size: .95rem; color: var(--c-ink-soft); }

.fb .btn { flex: 0 0 auto; }

@keyframes fb-in {
  from { opacity: 0; transform: translateY(26px); }
  to   { opacity: 1; transform: none; }
}

@media (max-width: 640px) {
  .fb { flex-wrap: wrap; }
  .fb__art { width: 48px; height: 48px; }
  .fb .btn { width: 100%; order: 3; }
}

/* Keep lesson labels readable and account controls usable on small screens. */
.node__body { display: flex; flex-direction: column; gap: 3px; }
@media (max-width: 520px) {
  .topbar { flex-wrap: wrap; }
  .topbar form .btn { padding: 8px 12px; font-size: .8rem; }
}

/* Course navigation remains visible at phone and desktop sizes. */
.home-button{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:44px;padding:8px 12px;border:2px solid var(--c-line);border-radius:12px;background:var(--c-surface);color:var(--c-ink);font:inherit;font-weight:800;text-decoration:none;cursor:pointer;white-space:nowrap}.home-button:focus-visible,.course-unit:focus-visible{outline:3px solid var(--c-sky);outline-offset:3px}.course-units{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:16px;margin:24px 0}.course-unit{display:flex;flex-direction:column;gap:10px;padding:20px;border:var(--border);border-radius:var(--r-lg);background:var(--c-surface);color:var(--c-ink);font:inherit;text-align:left;cursor:pointer}.course-unit[aria-pressed="true"]{border-color:var(--c-flame);box-shadow:var(--shadow-card)}.course-unit strong{font-size:1.1rem}.course-unit__eyebrow{font-size:.8rem;color:var(--c-ink-soft)}.course-unit progress{width:100%;accent-color:var(--c-grass)}.course-intro{margin:30px 0 20px}.course-intro h1{font-size:1.65rem}.course-intro p{color:var(--c-ink-soft)}
@media(max-width:600px){.topbar{flex-wrap:wrap}.home-button{font-size:.85rem;padding:8px 10px}.course-intro h1{font-size:1.4rem}}

/* Winding course and lesson maps; ordered HTML stops remain keyboard accessible. */
.world-map,.lesson-map{position:relative;margin:26px 0;padding:26px 12px;border:2px solid #e4decd;border-radius:32px;background:radial-gradient(ellipse at 10% 36%,#dcefc9 0 9%,transparent 9.3%),radial-gradient(ellipse at 90% 72%,#dcefc9 0 11%,transparent 11.3%),#f8f9ed;overflow:hidden}.world-map{background:radial-gradient(ellipse at 8% 80%,#c7e8f4 0 13%,transparent 13.3%),radial-gradient(ellipse at 95% 15%,#c7e8f4 0 12%,transparent 12.3%),#eaf6f8}.journey-heading{position:relative;text-align:center;max-width:580px;margin:0 auto 26px;padding:0 12px}.journey-heading h1,.journey-heading h2{font-size:1.65rem;line-height:1.3;margin:8px 0}.journey-heading p{font-size:.95rem;color:var(--c-ink-soft);margin:8px 0}.journey-heading .eyebrow{font-size:.75rem;text-transform:uppercase;letter-spacing:.1em}.journey.course-units{display:block;margin:0;position:relative}.journey{position:relative;max-width:720px;margin:0 auto}.journey-trail{position:absolute;inset:0;width:100%;height:100%;overflow:visible;pointer-events:none}.journey-trail path{fill:none;vector-effect:non-scaling-stroke;stroke-linecap:round}.journey-trail__edge{stroke:#d5c6a1;stroke-width:18}.journey-trail__dots{stroke:#fff7de;stroke-width:5;stroke-dasharray:2 14}.world-map .journey-trail__edge{stroke:#acd3df}.world-map .journey-trail__dots{stroke:#f6fdff}.journey-stops{list-style:none;padding:0;margin:0}.journey-stop{position:absolute;transform:translateX(-50%);width:190px;text-align:center}.island-stop,.lesson-stop{position:relative;display:flex;flex-direction:column;align-items:center;gap:12px;width:100%;border:0;padding:0;background:none;font:inherit;color:var(--c-ink);cursor:pointer}.island-stop__land{display:grid;place-items:center;width:106px;height:82px;background:#ccebb0;border:3px solid #85b65e;border-radius:48% 52% 43% 46%;box-shadow:0 9px 0 #6d9855,0 14px 0 #bddfe5;font-size:2.9rem;transition:transform .18s}.island-stop[aria-pressed=true] .island-stop__land{outline:4px solid var(--c-flame);outline-offset:7px}.island-stop--locked .island-stop__land{background:#e1e4db;border-color:#b1b7a7;box-shadow:0 9px 0 #9ca48f,0 14px 0 #bddfe5}.island-stop__label,.lesson-stop__label{display:flex;flex-direction:column;gap:3px;border-radius:14px;padding:7px 10px;background:#fffdf4f5;box-shadow:0 2px 0 #ddd5c5;line-height:1.25}.island-stop__label strong{font-size:.96rem}.island-stop__label small,.island-stop__label>span{font-size:.75rem;color:var(--c-ink-soft)}.lesson-stop__disc{display:grid;place-items:center;position:relative;width:80px;height:80px;border:4px solid #fff8e6;border-radius:50%;background:var(--c-theme,var(--c-sun));box-shadow:0 7px 0 #b29f75,0 0 0 3px #d3c5a5;font-size:2rem;transition:transform .18s}.lesson-stop__disc b{position:absolute;right:-7px;bottom:-8px;background:#fffdf4;border:2px solid #d3c5a5;border-radius:50%;width:28px;height:28px;display:grid;place-items:center;font-size:.8rem}.lesson-stop__label strong{font-size:.98rem}.lesson-stop__label small{font-size:.8rem;color:#76551e}.lesson-stop--locked{cursor:not-allowed;color:#737267}.lesson-stop--locked .lesson-stop__disc{background:#e0e2d8;box-shadow:0 7px 0 #b4baaa,0 0 0 3px #c5cbbd}.lesson-stop--done .lesson-stop__disc{box-shadow:0 7px 0 #67984a,0 0 0 3px #83b764}.lesson-stop--current .lesson-stop__disc{outline:3px dashed var(--c-flame);outline-offset:9px}.lesson-stop--current .lesson-stop__label{border:2px solid var(--c-flame)}.lesson-stop:hover:not(:disabled) .lesson-stop__disc,.island-stop:hover .island-stop__land{transform:translateY(-4px)}.lesson-stop:focus-visible,.island-stop:focus-visible{outline:3px solid var(--c-sky);outline-offset:8px;border-radius:20px}.journey-finish{display:flex;flex-direction:column;align-items:center;gap:5px;text-align:center;color:var(--c-ink-soft)}.journey-finish>span:first-child{font-size:2.5rem}.journey-finish strong{color:var(--c-ink)}.journey-finish>span:last-child{font-size:.85rem}@media(max-width:600px){.world-map,.lesson-map{padding:24px 6px;border-radius:24px}.journey-stop{width:142px}.island-stop__label strong,.lesson-stop__label strong{font-size:.86rem}.island-stop__land{width:88px;height:72px;font-size:2.5rem}.journey-heading h1,.journey-heading h2{font-size:1.35rem}.lesson-stop__disc{width:70px;height:70px}}@media(prefers-reduced-motion:reduce){.lesson-stop__disc,.island-stop__land{transition:none}}
.lesson-map{scroll-margin-top:150px}

/* Mobile player toolbar: navigation above a balanced row of learning controls. */
@media (max-width:640px){
  #topbar:not([hidden]){display:grid;grid-template-columns:repeat(3,minmax(0,1fr)) 44px;gap:8px;padding:10px 14px;align-items:center}
  #topbar .topbar__brand{display:none}
  #topbar .home-button{grid-column:1 / 3;grid-row:1;justify-self:start;min-height:44px;margin:0}
  #topbar form{grid-column:3 / 5;grid-row:1;justify-self:end;margin:0}
  #topbar form .btn{min-height:44px;padding:8px 14px;box-shadow:none;margin:0;font-size:.8rem}
  #topbar .topbar__stat{grid-row:2;min-width:0;height:40px;box-sizing:border-box;justify-content:center;padding:6px;gap:5px;font-size:.9rem;white-space:nowrap}
  #topbar .topbar__stat--streak{grid-column:1}
  #topbar .topbar__stat--xp{grid-column:2}
  #topbar .topbar__stat--hearts{grid-column:3}
  #topbar #mute-btn{grid-column:4;grid-row:2;width:44px;height:44px;margin:0}
}

/* A single upward-growing world: unreached terrain is not rendered. */
.climbing-map{position:relative;overflow:hidden;border:2px solid #ced8b9;border-radius:32px;background:#edf3dc;margin:24px 0 0}.map-frontier{position:relative;z-index:2;text-align:center;padding:24px 16px 12px;background:linear-gradient(#f8fcf2,#edf3dc);display:flex;flex-direction:column;gap:9px}.map-frontier strong{font-size:1rem;color:#536c48}.map-frontier>span{font-size:.8rem;color:#6d7f61}.climbing-world{position:relative;max-width:900px;margin:auto;background:radial-gradient(ellipse at 0 40%,#dfebc9 0 15%,transparent 15.3%),radial-gradient(ellipse at 100% 70%,#e0eccb 0 13%,transparent 13.3%)}.climbing-road__verge{stroke:#cfddb5;stroke-width:58}.climbing-road__shadow{stroke:#c1ab7b;stroke-width:43}.climbing-road__sand{stroke:#e9d5a5;stroke-width:38}.climbing-road__light{stroke:#f7e6be;stroke-width:25}.climbing-road__stones{stroke:#d6bd88;stroke-width:3;stroke-dasharray:1 28;opacity:.65}.map-scenery{position:absolute;width:88px;transform:translateX(-50%);pointer-events:none;user-select:none}.map-scenery svg{width:100%;height:110px}.map-pond{display:grid;place-items:center;width:100px;height:65px;border-radius:55% 45% 60% 40%;background:#addbd5;border:6px solid #cddfb8;box-shadow:inset 0 4px 0 #95c9c5,0 4px 0 #d4e1bf;font-size:1.7rem;transform:rotate(-12deg)}.map-garden{display:flex;align-items:end;gap:2px;font-size:2rem;filter:drop-shadow(0 4px 0 #ceddb5)}.map-garden small{font-size:1.25rem}.map-unit-gate{position:absolute;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:12px;width:min(84%,360px);padding:16px 20px;background:#fff7e3;border:3px solid #d7bd8b;border-radius:20px;box-shadow:0 6px 0 #b9a176;z-index:1}.map-unit-gate>span{font-size:2rem}.map-unit-gate small{font-size:.75rem;color:#826942}.map-unit-gate h2{font-size:1.05rem;margin:4px 0 0;line-height:1.3}.climbing-map .journey-stop{z-index:1}.climbing-map .lesson-stop__label{border:1px solid #e0d5b7;box-shadow:0 3px 0 #cabf9d}.climbing-map .lesson-stop--current .lesson-stop__label{border:2px solid var(--c-flame)}.map-origin{position:absolute;bottom:20px;left:0;right:0;display:flex;align-items:center;justify-content:center;gap:10px;font-size:1.5rem;color:#6f785a}.map-origin strong{font-size:.85rem}@media(max-width:640px){.climbing-map{border-radius:24px}.map-scenery{width:60px}.map-scenery svg{height:82px}.map-pond{width:58px;height:44px;border-width:4px;font-size:1.2rem}.map-garden{font-size:1.4rem}.map-garden small{font-size:1rem}.map-unit-gate{padding:12px;gap:8px}.map-unit-gate h2{font-size:.9rem}.map-frontier strong{font-size:.9rem}.climbing-map .journey-stop{width:136px}}
