/* ================= Плагін museum: «Музей містечка» (docs/design/screens/museum.md) ================= */
.mu-host, .mu-words { background: var(--glass-bg); box-shadow: var(--glass-edge), var(--glass-shadow); border-radius: var(--r); }
.mu-host { display: flex; gap: 12px; align-items: center; padding: 12px 16px; margin: 0 0 16px; }
.mu-host-av { flex: none; width: 56px; display: grid; place-items: center; }
.mu-host-av svg { width: 56px; height: 70px; }
.mu-host-say { margin: 0; max-width: 52ch; font-size: 16px; font-weight: 600; line-height: 1.4; color: var(--label); }
.mu-host-say b { font-weight: 800; }

.mu-halls { margin: 0 0 12px; }
.mu-halls button { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; position: relative; }
.mu-halls button svg { width: 18px; height: 18px; flex: none; }
.mu-halls button.on { box-shadow: 0 3px 0 color-mix(in srgb, var(--accent) 65%, #000), inset 0 -4px 0 var(--c, transparent); }
.mu-halls button:focus-visible, .mu-ex:focus-visible, .mu-words:focus-visible, .mu-close:focus-visible, .mu-card .btn:focus-visible { outline: 3px solid var(--label); outline-offset: 2px; }

.mu-words { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 64px; padding: 10px 12px; margin: 0 0 8px; text-align: left; color: var(--label); }
.mu-words > b { font-size: 15px; font-weight: 800; }
.mu-wrow { flex: 1; display: flex; gap: 6px; justify-content: space-around; min-width: 0; }
.mu-wpill { display: flex; flex-direction: column; align-items: center; line-height: 1.15; }
.mu-we { display: flex; align-items: center; gap: 3px; font-size: 18px; }
.mu-we em { font-style: normal; font-size: 17px; font-weight: 800; font-variant-numeric: tabular-nums; }
.mu-wpill small { font-size: 12px; color: var(--label2); }
.mu-chev { flex: none; color: var(--label2); display: grid; }
.mu-chev svg { width: 16px; height: 16px; }

.mu-shelf { margin: 18px 0 8px; }
.mu-h { display: flex; align-items: center; gap: 8px; margin: 0 0 4px; font-size: 20px; font-weight: 800; color: var(--label); }
.mu-hi { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--fill); color: var(--label2); }
.mu-hi svg { width: 16px; height: 16px; }
.mu-shelf.solid .mu-hi { background: var(--green); color: #fff; }
.mu-shelf.growing .mu-hi { background: #fdf1d2; color: #7a4f0a; }
.mu-shelf-note { margin: 0 0 10px; font-size: 14px; color: var(--label2); line-height: 1.4; }

.mu-grid { --cols: 3; display: grid; gap: 8px; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); }
.mu-plank { height: 8px; margin: 8px 0 0; border-radius: 4px; background: #c98a55; box-shadow: 0 0 0 2px #3b2f2a; }
.mu-empty { display: flex; align-items: center; gap: 10px; min-height: 64px; padding: 14px 16px; border: 2px dashed var(--fill2); border-radius: 16px; font-size: 14px; color: var(--label2); }
.mu-empty svg { width: 20px; height: 20px; flex: none; }

.mu-ex { display: flex; flex-direction: column; align-items: center; gap: 4px; min-height: 148px; padding: 8px 6px 10px; border-radius: 18px; color: var(--label);
  background: var(--glass-bg); box-shadow: var(--glass-edge), var(--glass-shadow); transition: transform .15s var(--ease); }
.mu-ex:hover { transform: translateY(-2px); }
.mu-ex:active { transform: scale(.97); }
.mu-case { position: relative; width: 100%; max-width: 96px; aspect-ratio: 1; border-radius: 14px; display: grid; place-items: center; }
.mu-case .town-svg { width: 80px; height: 80px; }
.mu-plinth { position: absolute; left: 50%; bottom: 0; width: 64px; height: 8px; transform: translateX(-50%); border-radius: 3px; background: #d9d0c4; box-shadow: 0 0 0 2px #3b2f2a; }
.mu-ex-t { display: flex; align-items: center; justify-content: center; gap: 4px; font-size: 14px; font-weight: 800; text-align: center; line-height: 1.2; }
.mu-ex-t > span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mu-ex-t svg { width: 14px; height: 14px; flex: none; }
.mu-ex-s { font-size: 12px; font-weight: 700; color: var(--label2); }

.mu-ex.solid .mu-case, .mu-ex.shining .mu-case, .mu-ex.restore .mu-case { background: #fff; box-shadow: inset 0 0 0 2px var(--glass-border, rgba(90,60,30,.14)); }
.mu-ex.solid .mu-case::after, .mu-ex.shining .mu-case::after, .mu-ex.restore .mu-case::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(135deg, rgba(255,255,255,.7) 0 18%, transparent 18% 100%); }
.mu-ex.shining .mu-case { box-shadow: inset 0 0 0 3px #f2c14e; }
.mu-ex.restore { background: #fdf1d2; }
.mu-ex.restore .mu-case { box-shadow: inset 0 0 0 2px rgba(122,79,10,.25); background: #fff; }
.mu-ex.restore .mu-ex-s { color: #7a4f0a; background: #fff; padding: 1px 8px; border-radius: 99px; }
.mu-ex.growing .mu-case { background: var(--fill); border: 2px dashed var(--fill2); }
.mu-ex.next { background: transparent; box-shadow: none; }
.mu-ex.next .mu-case { background: var(--fill); border: 2px dashed var(--fill2); }
.mu-ex.next .mu-case .town-svg, .mu-card-hero.next .town-svg { filter: brightness(0) opacity(.14); }

.mu-badge { position: absolute; top: -6px; right: -6px; z-index: 1; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; box-shadow: 0 0 0 2px #3b2f2a; }
.mu-badge svg { width: 16px; height: 16px; }
.mu-badge.gold { background: #f2c14e; color: var(--label); }
.mu-badge.try { background: #fdf1d2; color: #7a4f0a; box-shadow: 0 0 0 2px #7a4f0a; }

.mu-deco { display: flex; align-items: center; gap: 4px; }
.mu-deco b { font-size: 12px; color: var(--label2); }
.mu-dot { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-style: normal; border: 1.5px dashed var(--fill2); opacity: .55; overflow: hidden; }
.mu-dot.got { opacity: 1; border: 1.5px solid var(--green); background: #fff; }
.mu-dot svg { width: 12px; height: 12px; }
.mu-emo { line-height: 1; }

/* ----- Картка експоната ----- */
.mu-card { display: flex; flex-direction: column; gap: 0; }
.mu-card h3 { margin: 14px 0 6px; font-size: 15px; font-weight: 800; }
.mu-close { width: 48px; height: 48px; }
.mu-close::after { display: none; }
.mu-card-sub { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--label2); padding: 0 4px; }
.mu-card-sub svg { width: 16px; height: 16px; flex: none; }
.mu-card-hero { display: grid; place-items: center; margin: 8px 0 0; }
.mu-card-hero .mu-case { width: 176px; max-width: none; border-radius: 22px; }
.mu-card-hero .mu-case .town-svg { width: 160px; height: 160px; }
.mu-card-hero .mu-plinth { width: 112px; height: 10px; }
.mu-card-hero.solid .mu-case, .mu-card-hero.shining .mu-case { background: #fff; box-shadow: inset 0 0 0 2px var(--glass-border, rgba(90,60,30,.14)); }
.mu-card-hero.shining .mu-case { box-shadow: inset 0 0 0 3px #f2c14e; }
.mu-card-hero.restore .mu-case { background: #fdf1d2; box-shadow: inset 0 0 0 2px rgba(122,79,10,.25); }
.mu-card-hero.growing .mu-case, .mu-card-hero.next .mu-case { background: var(--fill); border: 2px dashed var(--fill2); }
.mu-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.mu-wchip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border-radius: 99px; background: var(--fill); }
.mu-wchip b { font-size: 15px; font-weight: 700; }
.mu-wchip small { font-size: 13px; color: var(--label2); }
.mu-desc { margin: 0; font-size: 15px; line-height: 1.4; }
.mu-decor { display: flex; gap: 8px; justify-content: space-between; }
.mu-dc { display: flex; flex-direction: column; align-items: center; gap: 4px; flex: 1; min-width: 0; }
.mu-dcc { position: relative; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--fill); border: 2px dashed var(--fill2); }
.mu-dcc > svg { width: 32px; height: 32px; }
.mu-dcc .mu-emo { font-size: 22px; }
.mu-dc.got .mu-dcc { background: #fff; border: 2px solid var(--green); }
.mu-dc.next .mu-dcc { border-color: var(--accent); }
.mu-dc.next .mu-dcc > :not(.mu-tick) { opacity: .55; }
.mu-dc.later .mu-dcc > :not(.mu-tick) { opacity: .3; }
.mu-tick { position: absolute; right: -4px; bottom: -4px; width: 16px; height: 16px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; }
.mu-tick svg { width: 10px; height: 10px; }
.mu-dcl { font-size: 12px; font-weight: 700; text-align: center; }
.mu-dc.later .mu-dcl { color: var(--label2); }
.mu-card-say { margin: 14px 0 0; font-size: 16px; line-height: 1.4; }
.mu-locked { margin: 14px 0 8px; font-size: 15px; line-height: 1.4; }
.mu-act { position: sticky; bottom: 0; padding-top: 10px; margin-top: 10px; background: var(--glass-strong, var(--glass-bg)); }
.mu-act .btn { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 56px; }
.mu-act .btn:not(.ghost) { background: #b4532e; color: #fff; }

/* ----- Помилка ----- */
.mu-error { display: flex; gap: 12px; align-items: center; padding: 16px; border-radius: var(--r); background: var(--glass-bg); box-shadow: var(--glass-edge), var(--glass-shadow); }
.mu-error p { margin: 4px 0 10px; color: var(--label2); }

/* ----- Розкладки ----- */
@media (min-width: 560px) { .mu-grid { --cols: 5; } }
@media (max-width: 420px) {
  .mu-host-av { width: 48px; } .mu-host-av svg { width: 48px; height: 60px; } .mu-host-say { font-size: 15px; }
  .mu-wpill small { display: none; }
  .mu-case { max-width: none; }
}

/* ----- Теми ----- */

/* ----- Рух ----- */
@media (prefers-reduced-motion: reduce) { .mu-ex { transition: none; } .mu-ex:hover { transform: none; } }
html.no-motion .mu-ex { transition: none; }
html.no-motion .mu-ex:hover { transform: none; }
