/* «Город открытий»: мини-игры (gorod-play.js) — поиск, микроскоп и телескоп, реактив и опыты, полка книг, игры на работе. */
.gg-dlg.mg { width: min(780px, 100%); }
/* Отступы между кнопками — одни на все мини-игры: --mg-gap — между соседями в ряду, --mg-row — между рядами
   (у кнопок с резкой тенью снизу 3–4 px видимый промежуток всё равно 8 px и больше), --mg-sep — между блоками окна.
   Кольца-обводки кнопок рисуются внутри (inset) или учтены в промежутке — соседей они не задевают. */
.gg-mg { position: relative; --mg-gap: 10px; --mg-row: 12px; --mg-sep: 16px; }
.mg-head { display: flex; gap: 12px; align-items: center; margin: 0 0 10px; }
.mg-e { font-size: 44px; line-height: 1; flex: none; }
.mg-head b { display: block; font-size: 22px; line-height: 1.2; }
.mg-head small, .mg-do { display: block; margin-top: 3px; color: var(--ink); font-size: 17px; font-weight: 700; line-height: 1.35; }
.mg-note { min-height: 1.5em; margin: 10px 0 0; padding: 9px 13px; border-radius: 14px; background: var(--sky-2); font-size: 16px; line-height: 1.4; }
.mg-note:empty { display: none; }
.mg-note.ok { background: var(--leaf-soft); color: #24502a; }
.mg-note.warn { background: var(--sun-soft); color: #6a4a00; }
.mg-note.mg-new { animation: mg-note .35s ease; }
.mg-cnt { display: inline-block; margin-left: 4px; padding: 1px 9px; border-radius: 99px; background: #fff; color: var(--ink-soft); font-size: 14px; font-weight: 800; white-space: nowrap; }
.mg-btns { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--mg-row) 12px; margin: var(--mg-sep) 0 0; }
.mg-btns[hidden] { display: none; }
/* абзацы окна лежат внутри .card, а правило сайта «.card p { margin: 0 }» сильнее одного класса — отступы задаём через .gg-mg */
.gg-mg .mg-btns { margin: var(--mg-sep) 0 0; }
.gg-mg .mg-note { margin: 12px 0 0; }
.gg-mg .mg-count { margin: 10px 0 0; }
.mg-btns .btn { min-height: 48px; }
.mg-btns .btn:disabled { opacity: .5; cursor: default; }
/* отклик на нажатие */
.mg-shake { animation: mg-shake .4s ease; }
.mg-tap { animation: mg-tap .32s ease; }
/* у кнопок рамка стоит на месте и соседей не задевает: дрожит и подпрыгивает то, что внутри, а «не то» — ещё и красная обводка внутри рамки */
.gg-mg button.mg-shake { animation: mg-nope .45s ease; }
.gg-mg button.mg-tap { animation: none; }
.gg-mg button.mg-shake > *, .gg-mg .mg-bub.mg-shake::before { animation: mg-shake .4s ease; }
.gg-mg button.mg-tap > *, .gg-mg .mg-col.mg-tap::before { animation: mg-tap .32s ease; }
@keyframes mg-nope { 0%, 100% { outline: 3px solid transparent; outline-offset: -3px; } 20%, 70% { outline: 3px solid var(--coral); outline-offset: -3px; } }
.mg-fly { position: absolute; z-index: 3; translate: -50% -50%; pointer-events: none; font-size: 26px; font-weight: 900; line-height: 1; white-space: nowrap; color: var(--ink);
  text-shadow: 0 0 4px #fff, 0 0 8px #fff; animation: mg-fly .9s ease-out forwards; }
@keyframes mg-shake { 20%, 60% { translate: -6px 0; } 40%, 80% { translate: 6px 0; } }
@keyframes mg-tap { 50% { scale: 1.18; } }
@keyframes mg-fly { 0% { opacity: 0; transform: translateY(0) scale(.6); } 20% { opacity: 1; transform: translateY(-8px) scale(1.1); } 100% { opacity: 0; transform: translateY(-52px) scale(1); } }
@keyframes mg-note { from { opacity: .3; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes mg-pop { 0% { scale: .3; } 70% { scale: 1.25; } 100% { scale: 1; } }
@keyframes mg-pulse { 50% { scale: 1.18; } }
@keyframes mg-drip { 0% { translate: 0 0; } 50% { translate: 0 24px; } 100% { translate: 0 0; } }
@keyframes mg-twinkle { 50% { opacity: .35; } }
@keyframes mg-wiggle { 0%, 82%, 100% { rotate: 0deg; } 88% { rotate: -9deg; } 94% { rotate: 9deg; } }
/* строка хода: точки раундов и счёт */
.mg-prog { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 0 0 8px; font-size: 16px; }
.mg-prog:empty { display: none; }
.mg-dots { display: inline-flex; gap: 6px; }
.mg-dots i { width: 12px; height: 12px; border-radius: 50%; background: var(--line); }
.mg-dots i.on { background: var(--leaf); }
.mg-dots i.cur { background: var(--water); box-shadow: 0 0 0 3px var(--sky); }
.mg-dots:has(i:only-child) { display: none; }

/* найти в природе */
/* кружки мест растут вместе с рисунком (12% его ширины, 42…80 px), а места в SPOTS стоят не ближе 112 из 640 —
   промежуток между кружками на любом экране не меньше 10 px; качается и пульсирует рисунок внутри, сам кружок стоит на месте */
.mg-scene { position: relative; border-radius: 16px; overflow: hidden; container-type: inline-size; }
.mg-scene svg { display: block; width: 100%; height: auto; }
.mg-spot { --sz: clamp(42px, 12cqw, 80px); position: absolute; transform: translate(-50%, -50%); display: grid; place-items: center; width: var(--sz); height: var(--sz); padding: 0; border: 0;
  border-radius: 50%; background: rgba(255, 255, 255, .35); cursor: pointer; line-height: 1; font-size: calc(var(--sz) * .56); filter: drop-shadow(0 3px 3px rgba(29, 58, 85, .3)); }
@supports not (width: 1cqw) { .mg-spot { --sz: clamp(42px, 9vw, 80px); } }
.mg-spot > * { animation: mg-wiggle 3s ease-in-out infinite; }
.mg-spot:nth-child(2n) > * { animation-delay: -1.4s; }
.mg-spot:hover { background: rgba(255, 255, 255, .75); }
.mg-spot.seen { opacity: .55; filter: grayscale(.6); cursor: default; }
.mg-spot.seen > * { animation: none; }
.mg-spot.seen::after { content: "✓"; position: absolute; right: -2px; top: -2px; width: 20px; height: 20px; border-radius: 50%; background: #fff; color: var(--leaf);
  font: 900 14px/20px var(--text); text-align: center; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); }
.mg-spot.mg-tap > * { animation: mg-tap .32s ease; }
/* кольца подсказки и находки — внутри кружка: промежуток до соседей не меняется (сильнее фона из gorod-pics.css) */
.gg-mg .mg-scene .mg-spot.hint { box-shadow: inset 0 0 0 4px var(--sun), 0 2px 8px rgba(29, 58, 85, .2); background: rgba(255, 255, 255, .9); }
.mg-spot.hint > * { animation: mg-pulse .8s ease-in-out infinite; }
.gg-mg .mg-scene .mg-spot.found { background: #fff; box-shadow: inset 0 0 0 4px var(--leaf); opacity: 1; filter: none; }
.mg-spot.found > * { animation: mg-pop .6s ease; }
.mg-scene .mg-spot .mg-pic { width: 84%; height: 84%; }   /* найденное открытие — по размеру кружка */

/* микроскоп и телескоп */
.mg-eye { width: min(260px, 66vw); aspect-ratio: 1; margin: 0 auto; border-radius: 50%; border: 14px solid #1d3a55; overflow: hidden; background: #eef7ec;
  box-shadow: inset 0 0 30px rgba(0, 0, 0, .25); }
.mg-eye.sky { background: #1f2752; }
.mg-view { position: relative; width: 100%; height: 100%; display: grid; place-items: center; }
.mg-view.sharp { animation: mg-pop .5s ease; }
.mg-obj { font-size: clamp(80px, 22vw, 120px); line-height: 1; }
.mg-view i { position: absolute; font-style: normal; font-size: 30px; color: #6aa37a; }
.mg-eye.sky .mg-view i { color: #fff; font-size: 42px; }
.mg-meter { display: flex; align-items: center; gap: 10px; max-width: 440px; margin: 12px auto 0; font-size: 15px; font-weight: 800; color: var(--ink-soft); }
.mg-meter b { position: relative; flex: 1; height: 14px; border-radius: 99px; background: var(--sky); overflow: hidden; }
.mg-meter i { position: absolute; left: 0; top: 0; bottom: 0; width: 6%; border-radius: 99px; background: var(--coral); transition: width .25s ease, background .25s ease; }
.mg-meter b.near i { background: var(--sun); }
.mg-meter b.ok i { background: var(--leaf); }
.mg-knob { display: flex; gap: 10px; align-items: center; max-width: 440px; margin: 10px auto 0; }
.mg-knob input { flex: 1; min-width: 0; accent-color: var(--water); height: 44px; margin: 0; cursor: pointer; }
.mg-pm { flex: none; width: 50px; height: 50px; border-radius: 50%; border: 0; background: var(--sky); color: var(--ink); font-size: 28px; font-weight: 900; cursor: pointer;
  box-shadow: 0 3px 0 var(--line); }
.mg-pm:active { translate: 0 2px; box-shadow: none; }

/* пробирка, стакан, колба */
.mg-lab { display: flex; justify-content: center; align-items: flex-start; gap: 4px; margin-top: 6px; }
.mg-tube { width: 110px; height: auto; }
.mg-glass { width: 120px; height: auto; overflow: visible; }
.mg-paper { width: min(240px, 64vw); height: auto; }
.mg-flask { width: 150px; height: auto; }
.mg-liq { transition: fill .5s ease; }
.mg-pip { font-size: 40px; line-height: 1; }
.mg-pip.drip { animation: mg-drip .45s ease; }
.mg-gr { animation: mg-dissolve 1.1s ease-in forwards; }
.mg-gr.stay { animation: none; }
@keyframes mg-dissolve { 0% { opacity: 1; translate: 0 0; } 70% { opacity: .8; translate: 0 70px; } 100% { opacity: 0; translate: 0 90px; } }
.mg-egg { transition: transform .7s cubic-bezier(.3, 1.4, .5, 1); }
.mg-cr { transform-box: fill-box; transform-origin: center; animation: mg-pop .6s ease backwards; }
.mg-lay { transform-box: fill-box; transform-origin: bottom; animation: mg-pour .5s ease; }
@keyframes mg-pour { from { scale: 1 0; } }
.mg-flash { opacity: 0; }
.mg-flash.on { animation: mg-flash 1.4s ease; }
@keyframes mg-flash { 25% { opacity: .9; } 100% { opacity: 0; } }
.mg-scale { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 16px; margin-top: var(--mg-sep); }   /* обводки цветов 2…4 px учтены */
.mg-scale[hidden] { display: none; }
.mg-swi { display: grid; justify-items: center; gap: 4px; }
.mg-swi small { font-size: 14px; font-weight: 800; color: var(--ink-soft); }
.mg-sw { width: 64px; height: 64px; border-radius: 16px; border: 4px solid #fff; background: var(--c); box-shadow: 0 0 0 2px var(--line); cursor: pointer; }
.mg-sw.t { display: grid; justify-items: center; align-content: center; gap: 2px; width: auto; min-width: 104px; height: auto; min-height: 78px; padding: 8px 12px;
  border: 2px solid var(--line); background: #fff; box-shadow: 0 3px 0 var(--line); color: var(--ink); }
.mg-sw.t span { font-size: 30px; line-height: 1; }
.mg-sw.t b { font-size: 15px; }
.mg-sw.right { box-shadow: 0 0 0 4px var(--leaf); }
.mg-sw.t.right { border-color: var(--leaf); background: var(--leaf-soft); }

/* полка книг */
.mg-shelf { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--mg-row) var(--mg-gap); }
.mg-book { display: grid; align-content: start; gap: 4px; min-height: 112px; padding: 12px; border: 0; border-left: 12px solid var(--c); border-radius: 6px 14px 14px 6px;
  background: color-mix(in srgb, var(--c) 16%, #fff); color: var(--ink); text-align: left; font-size: 15px; line-height: 1.3; cursor: pointer;
  box-shadow: 0 3px 8px rgba(29, 58, 85, .1); transition: translate .2s ease, rotate .2s ease, opacity .2s ease; }
.mg-book span { font-size: 28px; }
.mg-book:hover { translate: 0 -4px; }
.mg-book.pulled { translate: 0 -4px; box-shadow: inset 0 0 0 4px var(--sun), 0 10px 20px rgba(29, 58, 85, .2); }   /* приподнята, но в своём ряду */
.mg-book.dim { opacity: .45; }

/* игры на работе */
.mg-play { position: relative; min-height: 200px; }
.mg-timer { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; font-weight: 900; font-size: 20px; }
.mg-timer b { position: relative; flex: 1; height: 12px; border-radius: 99px; background: var(--sky); overflow: hidden; }
.mg-timer i { position: absolute; left: 0; top: 0; bottom: 0; width: 100%; border-radius: 99px; background: var(--water); transition: width 1s linear; }
.mg-timer.low span { color: #c0392b; animation: mg-pulse 1s ease-in-out infinite; display: inline-block; }
.mg-timer.low i { background: var(--coral); }
.mg-done { display: grid; justify-items: center; gap: 8px; padding: 18px 6px 8px; text-align: center; }
.mg-stars { display: flex; gap: 6px; }
.mg-stars i { font-style: normal; font-size: 46px; line-height: 1; animation: mg-pop .5s ease backwards; animation-delay: calc(var(--i) * .25s + .1s); }
.mg-stars i.off { filter: grayscale(1); opacity: .3; }
.mg-done b { font-size: 21px; line-height: 1.3; }
.mg-fact { max-width: 520px; margin: 2px 0; padding: 10px 14px; border-radius: 14px; background: var(--sky-2); font-size: 16px; line-height: 1.4; text-align: left; }
.mg-done small { color: var(--ink-soft); font-size: 15px; }
.mg-done .btn { margin-top: 6px; min-height: 48px; }
/* повар */
.mg-cust { display: flex; gap: 12px; align-items: center; }
.mg-who { flex: none; display: inline-block; font-size: 52px; line-height: 1; }
.mg-order { padding: 10px 14px; border-radius: 16px 16px 16px 4px; background: #fff; box-shadow: var(--shadow); font-size: 17px; font-weight: 700; line-height: 1.35; }
.mg-wants { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.mg-want { position: relative; display: inline-grid; justify-items: center; min-width: 62px; padding: 4px 8px; border-radius: 12px; border: 2px dashed var(--line); font-size: 28px; line-height: 1.1; }
.mg-want small { font-size: 12px; font-weight: 800; color: var(--ink-soft); }
.mg-want.got { border-style: solid; border-color: var(--leaf); background: var(--leaf-soft); }
.mg-want.got::after { content: "✓"; position: absolute; top: -8px; right: -8px; width: 20px; height: 20px; border-radius: 50%; background: var(--leaf); color: #fff; font: 900 13px/20px var(--text); }
.mg-tray { display: flex; flex-wrap: wrap; gap: var(--mg-row) var(--mg-gap); justify-content: center; align-items: center; min-height: 66px; margin: 12px 0; padding: 8px; border-radius: 32px; background: #efe5d5;
  box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .06); }
.mg-tray small { color: var(--ink-soft); font-weight: 700; }
.mg-ti { min-width: 50px; min-height: 50px; font-size: 34px; line-height: 1; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 2px 4px rgba(0, 0, 0, .12); cursor: pointer; }
.mg-food { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--mg-row) var(--mg-gap); }
.mg-fd { display: grid; justify-items: center; min-height: 64px; font-size: 32px; line-height: 1.1; padding: 8px 2px; border-radius: 14px; border: 2px solid var(--line); background: #fff; cursor: pointer;
  box-shadow: 0 3px 0 var(--line); }
.mg-fd:active { translate: 0 2px; box-shadow: none; }
.mg-fd small { font-size: 12px; font-weight: 800; color: var(--ink-soft); }
/* садовник */
.mg-pots { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }   /* обводка горшка 2–3 px снаружи (gorod-pics.css) учтена */
.mg-pot { min-height: 66px; font-size: 42px; line-height: 1; padding: 10px 4px; border: 0; border-radius: 0 0 24px 24px; background: #e9c7a4; cursor: pointer;
  box-shadow: inset 0 -6px 0 rgba(0, 0, 0, .1); }
.mg-pot.dry { background: #d9b48e; }
.mg-pot.wet { background: #cfe6f5; }
/* библиотекарь */
.mg-pile { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-end; gap: var(--mg-row) var(--mg-gap); min-height: 92px; }
.mg-bk { flex: none; display: grid; place-items: center; width: 46px; height: 86px; padding: 0; border: 0; border-radius: 5px; background: var(--c); box-shadow: inset -6px 0 0 rgba(0, 0, 0, .15), 0 3px 0 rgba(0, 0, 0, .1);
  font-size: 22px; cursor: pointer; transition: translate .15s ease; }
.mg-bk span { padding: 3px; border-radius: 50%; background: rgba(255, 255, 255, .8); line-height: 1; }
.mg-bk.sel { outline: 4px solid var(--sun); outline-offset: -2px; translate: 0 -10px; }
/* надпись и корешки на полке — по своей ширине и по центру: подпрыгивают внутри рамки полки */
.mg-shelves { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--mg-gap); margin-top: var(--mg-sep); }
.mg-sh { display: grid; align-content: space-between; justify-items: center; gap: 6px; min-height: 108px; padding: 8px 6px; border: 0; border-bottom: 10px solid #b8875a; border-radius: 10px;
  background: color-mix(in srgb, var(--c) 18%, #fff); box-shadow: inset 0 0 0 3px color-mix(in srgb, var(--c) 45%, #fff); color: var(--ink); font-size: 16px; cursor: pointer; }
.mg-sh b { font-weight: 900; }
.mg-sh span { display: flex; gap: 3px; justify-content: center; min-height: 36px; align-items: flex-end; }
.mg-sh span i { width: 12px; height: 36px; border-radius: 3px; background: var(--c); animation: mg-pop .4s ease; }
/* мойщик */
/* пять пробирок в один ряд: столбцы сужаются на телефоне, обводка — внутри кнопки */
.mg-tubes { display: grid; grid-template-columns: repeat(5, minmax(0, 66px)); justify-content: center; gap: 14px; }
.mg-tb { position: relative; min-width: 0; min-height: 76px; padding: 10px 2px; border: 0; border-radius: 16px; background: #fff; font-size: 44px; line-height: 1; box-shadow: inset 0 0 0 2px var(--line); cursor: pointer; }
.mg-tb.dirty span { display: inline-block; filter: sepia(1) saturate(2.2) brightness(calc(.6 + (1 - var(--d, 1)) * .4)); }
.mg-tb.clean { box-shadow: inset 0 0 0 4px var(--leaf); background: var(--leaf-soft); }
.mg-tb i { position: absolute; top: 2px; right: 4px; font-size: 20px; font-style: normal; }
/* экскурсовод и метеостанция */
.mg-opts { display: grid; gap: var(--mg-row); margin-top: 12px; }
.mg-op { min-height: 48px; padding: 10px 14px; border-radius: 12px; border: 2px solid var(--line); background: #fff; color: var(--ink); font: 700 17px var(--text); text-align: left; cursor: pointer;
  box-shadow: 0 3px 0 var(--line); }
.mg-op:disabled { cursor: default; }
.mg-op.right { border-color: var(--leaf); background: var(--leaf-soft); }
.mg-op.wrong { border-color: var(--coral); background: var(--coral-soft); }
.mg-q { font-size: 17px; font-weight: 800; line-height: 1.35; }
.mg-row { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: center; }
.mg-row p { margin: 0; }
.mg-thermo { width: 124px; height: auto; }
.mg-vane { width: 190px; height: auto; }
/* химик */
.mg-count { margin: 8px 0 0; text-align: center; font-weight: 900; font-size: 18px; }
.mg-stop { min-width: 120px; }
/* микробиолог */
/* чашка во всю ширину (до 320 px); зона нажатия колонии — 14% чашки (40…46 px), точки в JS не ближе 18% (place) */
.mg-dish { position: relative; width: min(320px, 100%); aspect-ratio: 1; margin: 0 auto; border-radius: 50%; border: 8px solid #dfe9f1; background: radial-gradient(#fff6d8, #f1dba6);
  box-shadow: inset 0 0 0 10px rgba(255, 255, 255, .45); container-type: inline-size; }
.mg-col, .mg-bub { position: absolute; display: grid; place-items: center; width: 44px; height: 44px; width: clamp(40px, 14cqw, 46px); height: clamp(40px, 14cqw, 46px);
  transform: translate(-50%, -50%); padding: 0; border: 0; border-radius: 50%; background: none; color: #fff; font: 900 14px var(--text); cursor: pointer; }
.mg-col::before, .mg-bub::before { content: ""; position: absolute; inset: 0; margin: auto; border-radius: 50%; z-index: -1; }   /* по центру без translate — его занимает дрожание */
.mg-col::before { width: var(--s, 24px); height: var(--s, 24px); background: radial-gradient(circle at 35% 35%, #f5c56b, #d9902a); box-shadow: 0 1px 2px rgba(0, 0, 0, .2); }
.mg-col.on::before { width: 28px; height: 28px; background: var(--leaf); }
.mg-bub::before { width: 22px; height: 22px; background: radial-gradient(circle at 35% 35%, #fff, rgba(255, 255, 255, .15) 60%); border: 2px solid rgba(255, 255, 255, .9); }
.mg-dish { isolation: isolate; }
/* астроном */
.mg-astro { display: grid; grid-template-columns: minmax(0, 1fr) 170px; gap: 12px; align-items: start; }
.mg-astro .mg-sky { order: -1; }
.mg-map { padding: 8px; border-radius: 14px; background: var(--sky-2); text-align: center; }
.mg-map small { display: block; font-size: 13px; font-weight: 800; color: var(--ink-soft); }
.mg-map svg { display: block; width: 100%; height: auto; }
.mg-ms { fill: #fff; stroke: #1d3a55; stroke-width: 1.5; }
.mg-ms.on { fill: var(--sun); }
.mg-sky svg { display: block; width: 100%; height: auto; border-radius: 16px; cursor: pointer; }
.mg-hit { fill: transparent; }
.mg-dot { fill: #fff8d6; transform-box: fill-box; transform-origin: center; }
.mg-star .mg-dot { filter: drop-shadow(0 0 4px rgba(255, 248, 214, .9)); }
.mg-x .mg-dot { fill: #e8eefc; }
.mg-star.next .mg-dot { animation: mg-twinkle .8s ease-in-out infinite; stroke: var(--sun); stroke-width: 3; }
.mg-star.on .mg-dot { fill: var(--sun); }
.mg-star.mg-tap .mg-dot { animation: mg-tap .32s ease; }
.mg-sky .mg-shake { animation: none; }
.mg-sky .mg-shake .mg-dot { animation: mg-shake .4s ease; }
.mg-ln { stroke-dasharray: 400; stroke-dashoffset: 400; animation: mg-draw .5s ease forwards; }
@keyframes mg-draw { to { stroke-dashoffset: 0; } }
.mg-cname { transition: opacity .4s ease; }
/* научный сотрудник */
.mg-steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--mg-row) 12px; }
.mg-st { display: grid; gap: 2px; align-content: start; min-height: 48px; padding: 10px 14px; border-radius: 14px; border: 2px solid var(--line); background: #fff; color: var(--ink); text-align: left;
  font: 800 17px var(--text); cursor: pointer; box-shadow: 0 3px 0 var(--line); }
.mg-st small { font-size: 14px; font-weight: 600; line-height: 1.3; color: var(--ink-soft); }
/* отклик на верный шаг: подпрыгивает только название, от левого края — текст не выходит за рамку кнопки */
.mg-st b { justify-self: start; transform-origin: 0 50%; }
.gg-mg .mg-st.mg-tap > small { animation: none; }
.mg-st:disabled { cursor: default; }
.mg-st.right { border-color: var(--leaf); background: var(--leaf-soft); opacity: .75; }
.mg-st.hint { border-color: var(--sun); box-shadow: 0 3px 0 var(--sun); animation: mg-glow 1s ease-in-out infinite; }   /* мигает цветом, не растёт — соседей не задевает */
@keyframes mg-glow { 50% { background: var(--sun-soft); } }
.mg-plan { margin: 12px auto 0; max-width: 560px; padding-left: 24px; font-size: 15px; line-height: 1.4; }
.mg-plan li { margin: 3px 0; animation: mg-note .35s ease; }
@media (max-width: 600px) {
  .mg-e { font-size: 34px; }
  .mg-head b { font-size: 19px; }
  .mg-head small, .mg-do { font-size: 16px; }
  .mg-food { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .mg-shelf { grid-template-columns: 1fr 1fr; }
  .mg-row { grid-template-columns: 1fr; justify-items: center; }
  .mg-row .mg-opts { justify-items: stretch; }
  .mg-q { text-align: center; }
  .mg-thermo { width: 112px; }
  .mg-vane { width: 160px; }
  .mg-pot { font-size: 34px; padding: 8px 2px; }
  .mg-bk { width: 40px; height: 78px; flex: none; }   /* шесть книг на 360 px — в один ряд */
  .mg-sh { min-height: 96px; font-size: 14px; }
  .mg-sh b .gg-em { display: block; margin: 0 auto 4px; }   /* полки узкие: значок над названием у всех трёх одинаково */
  .mg-tb { min-height: 70px; padding: 8px 2px; font-size: 34px; }
  .mg-astro { grid-template-columns: 1fr; }
  .mg-map { max-width: 220px; margin: 0 auto; width: 100%; padding: 4px 8px; }
  .mg-steps { grid-template-columns: 1fr; }
  .mg-st { padding: 8px 12px; }
  .mg-sw.t { min-width: 92px; }
}
@media (prefers-reduced-motion: reduce) {
  .mg-spot > *, .mg-spot.hint > *, .mg-star.next .mg-dot, .mg-st.hint, .mg-timer.low span { animation: none; }
  .mg-fly { animation-duration: .01s; }
  .mg-egg, .mg-liq, .mg-meter i, .mg-timer i { transition: none; }
}
@media (max-width: 600px) { .mg-astro .mg-sky { order: 0; } }
.mg-pic { width: 200px; max-width: 70%; padding: 6px 8px; border-radius: 14px; background: #1f2752; }
.mg-pic svg { display: block; width: 100%; height: auto; }
.mg-pic .mg-ms { fill: #fff8d6; stroke: none; }
.mg-pic text { display: none; }
