/* Mundo das Descobertas — identidade visual */
:root {
  --purple: #7C5CFC; --purple-ink: #5A3FE0; --blue: #38BDF8; --teal: #2DD4BF; --yellow: #FACC15; --coral: #FB7185;
  --bg: #F7F8FC; --ink: #24324B; --muted: #56627A; --card: #FFFFFF; --line: #E3E7F1; --soft: #EEF0FA;
  --ok: #0F9F7F; --ok-bg: #D9F8EF; --warn-bg: #FFF4D6;
  --radius: 22px; --radius-sm: 14px;
  --shadow: 0 2px 0 rgba(36, 50, 75, .06), 0 10px 24px -12px rgba(36, 50, 75, .25);
  --font: 'Nunito', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Baloo 2', 'Nunito', system-ui, sans-serif;
  --opt: 108px; --fs-prompt: 1.35rem; --tok: 48px;
  color-scheme: light;
}
[data-band="4-5"] { --opt: 132px; --fs-prompt: 1.55rem; --tok: 58px; }
[data-band="6-7"] { --opt: 116px; --fs-prompt: 1.4rem; --tok: 52px; }
[data-band="10-11"], [data-band="12-13"] { --radius: 16px; --radius-sm: 10px; --opt: 96px; --fs-prompt: 1.2rem; --tok: 44px; --font-display: 'Nunito', system-ui, sans-serif; }

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 17px; line-height: 1.45; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; min-height: 100vh; overflow-x: hidden; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
:focus-visible { outline: 3px solid var(--purple); outline-offset: 3px; border-radius: 10px; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; margin: 0 0 .4em; }
h1 { font-size: 1.7rem; } h2 { font-size: 1.3rem; } h3 { font-size: 1.12rem; }
h1:focus { outline: none; }
p { margin: 0 0 .7em; }
.muted { color: var(--muted); } .small { font-size: .88rem; }
.ico { width: 1.35em; height: 1.35em; flex: none; }
#app { min-height: 100vh; }
.wrap { max-width: 960px; margin: 0 auto; padding: 16px 16px 40px; }
.wrap.narrow { max-width: 620px; }
.h-center { text-align: center; }
.lead { font-size: 1.12rem; }
.note { background: var(--warn-bg); border-radius: 12px; padding: 10px 12px; font-size: .93rem; }

/* ---------- Botões ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: 52px; padding: 10px 22px; border-radius: 999px; border: 0; font-weight: 800; font-size: 1.02rem; background: var(--soft); color: var(--ink); transition: transform .12s, box-shadow .12s, background .12s; }
.btn:active:not(:disabled) { transform: translateY(2px); }
.btn-primary { background: var(--purple); color: #fff; box-shadow: 0 4px 0 #5A3FE0; }
.btn-primary:disabled { background: #B9AEF5; box-shadow: none; }
.btn-soft { background: #fff; color: var(--purple-ink); box-shadow: inset 0 0 0 2.5px #CFC4FF; }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--line); }
.btn-danger { background: #E11D48; color: #fff; }
.btn-danger-ghost { background: transparent; color: #BE123C; box-shadow: inset 0 0 0 2px #FECDD3; }
.btn-lg { min-height: 60px; font-size: 1.12rem; padding: 12px 28px; }
.btn-sm { min-height: 44px; padding: 8px 14px; font-size: .92rem; }
.row-btns { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 18px; }
.row-btns.col { flex-direction: column; align-items: stretch; max-width: 420px; margin-left: auto; margin-right: auto; }
.link-guardian, .link-small { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; color: var(--muted); font-weight: 700; padding: 12px; min-height: 44px; }
.link-guardian { margin: 22px auto 0; display: flex; }

/* ---------- Barra superior ---------- */
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: rgba(247, 248, 252, .92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); min-height: 64px; }
.tb-title { flex: 1; font-weight: 800; text-align: center; font-size: 1.02rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tb-right { display: flex; gap: 6px; }
.tb-spacer { width: 44px; }
.tb-btn, .tool { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; min-width: 56px; min-height: 52px; padding: 4px 8px; border: 0; background: #fff; border-radius: 14px; box-shadow: inset 0 0 0 2px var(--line); font-size: .72rem; font-weight: 800; color: var(--ink); }
.tb-btn .ico, .tool .ico { width: 24px; height: 24px; }
[data-band="10-11"] .topbar, [data-band="12-13"] .topbar { background: rgba(36, 50, 75, .96); border-color: #33415c; color: #fff; }
[data-band="10-11"] .tb-btn, [data-band="12-13"] .tb-btn { background: #33415c; color: #fff; box-shadow: none; }

/* ---------- Avatar ---------- */
.avatar { position: relative; display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--av); box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .12), 0 0 0 3px #fff; flex: none; }
.av-e { font-size: 28px; line-height: 1; }
.av-acc { position: absolute; top: -12px; right: -8px; font-size: 22px; transform: rotate(12deg); }
.avatar.av-lg { width: 84px; height: 84px; } .av-lg .av-e { font-size: 50px; } .av-lg .av-acc { font-size: 34px; top: -16px; right: -10px; }
.avatar.av-xl { width: 116px; height: 116px; } .av-xl .av-e { font-size: 70px; } .av-xl .av-acc { font-size: 44px; top: -20px; right: -12px; }

/* ---------- Mascote ---------- */
.mascot { display: block; }
.m-welcome { width: 150px; height: 150px; margin: 0 auto; }
.m-map { width: 70px; height: 70px; flex: none; }
.m-prompt { width: 64px; height: 64px; flex: none; }
.m-bubble { width: 58px; height: 58px; flex: none; }
.m-win, .m-result { width: 110px; height: 110px; margin: 0 auto; }
.m-help { width: 64px; height: 64px; }
.m-rest { width: 120px; height: 120px; }
.float { animation: float 3.4s ease-in-out infinite; }
.pop { animation: pop .5s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes float { 50% { transform: translateY(-8px) rotate(-3deg); } }
@keyframes pop { 0% { transform: scale(.4); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }

/* ---------- Boas-vindas ---------- */
.screen-welcome { background: radial-gradient(circle at 50% 30%, #FFFFFF 0, #EAF6FF 38%, #CDEBFB 100%); }
.welcome { position: relative; min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px 16px; overflow: hidden; }
.w-sky { position: absolute; inset: 0; pointer-events: none; }
.w-isl { position: absolute; width: 150px; opacity: .9; }
.w-isl svg { width: 100%; height: auto; }
.w1 { top: 5%; left: -20px; } .w2 { top: 8%; right: -24px; width: 130px; } .w3 { bottom: 12%; left: -10px; width: 120px; } .w4 { bottom: 6%; right: -16px; }
.w-center { position: relative; text-align: center; max-width: 520px; background: rgba(255, 255, 255, .72); backdrop-filter: blur(4px); border-radius: 32px; padding: 20px 22px 28px; box-shadow: var(--shadow); }
.w-title { font-size: clamp(2.1rem, 8vw, 3.2rem); color: var(--purple-ink); margin: 6px 0 4px; letter-spacing: -.5px; }
.w-title span { display: block; font-size: .55em; color: var(--ink); letter-spacing: 0; }
.w-sub { color: var(--muted); font-size: 1.08rem; }
.btn-play { background: var(--yellow); color: var(--ink); font-size: 1.35rem; min-height: 70px; padding: 14px 36px; border-radius: 999px; box-shadow: 0 6px 0 #D9A800, 0 16px 30px -12px rgba(0, 0, 0, .3); font-family: var(--font-display); }
.btn-play .ico { width: 30px; height: 30px; }

/* ---------- Perfis ---------- */
.profile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; margin-top: 12px; }
.profile-card { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 20px 12px 16px; background: var(--card); border: 0; border-radius: var(--radius); box-shadow: var(--shadow); font-size: 1.1rem; position: relative; min-height: 190px; justify-content: center; }
.profile-card.add { background: transparent; box-shadow: inset 0 0 0 3px #D4CCFB; border: 0; color: var(--purple-ink); }
.add-ico { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: #EDE9FE; }
.add-ico .ico { width: 34px; height: 34px; }
.pill { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 800; background: color-mix(in srgb, var(--c) 22%, #fff); color: var(--ink); box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--c) 60%, #fff); }
.pc-badge { font-size: .75rem; font-weight: 800; color: var(--purple-ink); }

/* ---------- Formulários ---------- */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; margin-bottom: 14px; }
.form-card { display: flex; flex-direction: column; gap: 8px; }
.lbl { font-weight: 900; font-size: 1.08rem; } .lbl.sm { font-size: .95rem; margin-top: 8px; }
.input { min-height: 56px; border-radius: 14px; border: 2px solid var(--line); padding: 10px 16px; font-size: 1.15rem; background: #fff; }
.input:focus { border-color: var(--purple); outline: none; }
.form-err { color: #BE123C; font-weight: 800; min-height: 1.3em; text-align: center; }
.av-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(58px, 1fr)); gap: 8px; }
.av-opt { height: 60px; font-size: 32px; border-radius: 16px; border: 0; background: var(--soft); }
.av-opt[aria-checked="true"] { background: #EDE9FE; box-shadow: inset 0 0 0 3px var(--purple); }
.col-pick { display: flex; flex-wrap: wrap; gap: 10px; }
.col-opt { width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--c); box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .12); }
.col-opt[aria-checked="true"] { box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--ink); }
.av-preview { display: grid; place-items: center; padding: 14px 0 4px; }
.age-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.age-opt { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px 14px; border-radius: 16px; border: 0; background: color-mix(in srgb, var(--c) 14%, #fff); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c) 45%, #fff); text-align: left; min-height: 96px; }
.age-opt b { font-size: 1.05rem; } .age-opt span:last-child { font-size: .88rem; color: var(--muted); font-weight: 700; }
.age-emo { font-size: 26px; }
.age-opt[aria-checked="true"] { box-shadow: inset 0 0 0 3px var(--ink); background: color-mix(in srgb, var(--c) 30%, #fff); }
.age-opt[aria-checked="true"]::after { content: '✓ escolhida'; font-size: .78rem; font-weight: 900; }

/* ---------- Mapa ---------- */
.screen-map { background: linear-gradient(180deg, #E0F4FF 0, #CDEBFB 60%, #BFE4F8 100%); }
[data-band="10-11"] .screen-map, [data-band="12-13"] .screen-map { background: radial-gradient(circle at 20% 0, #34507A 0, #24324B 55%, #1B2740 100%); color: #fff; }
.map-top .me { flex: 1; display: flex; align-items: center; gap: 10px; min-width: 0; }
.map-top .me b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stars-pill { display: inline-block; font-weight: 900; font-size: .9rem; background: #FEF3C7; color: var(--ink); padding: 1px 10px; border-radius: 999px; }
.map-main { max-width: 1040px; margin: 0 auto; padding: 16px 16px 40px; }
.map-head { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.map-head h1 { font-size: 1.45rem; margin: 0; }
.map-head p { margin: 2px 0 0; }
[data-band="10-11"] .map-head .muted, [data-band="12-13"] .map-head .muted { color: #C7D2E5; }
.compass { font-size: 44px; }
.continue-card { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 18px; margin-bottom: 16px; border: 0; border-radius: var(--radius); background: var(--yellow); color: var(--ink); text-align: left; font-size: 1rem; box-shadow: 0 5px 0 #D9A800; }
.cc-ico { width: 48px; height: 48px; border-radius: 50%; background: #fff; display: grid; place-items: center; flex: none; }
.island-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (min-width: 760px) { .island-grid { grid-template-columns: repeat(3, 1fr); gap: 18px; } }
.island-card { display: flex; flex-direction: column; align-items: flex-start; text-align: left; padding: 10px 12px 14px; border: 0; border-radius: var(--radius); background: #fff; box-shadow: 0 5px 0 color-mix(in srgb, var(--ic) 35%, #fff), var(--shadow); position: relative; animation: rise .45s both; animation-delay: calc(var(--d) * 60ms); color: var(--ink); }
.island-card:nth-child(even) { transform: translateY(10px); }
.ic-art { width: 100%; background: var(--it); border-radius: calc(var(--radius) - 8px); display: block; margin-bottom: 8px; }
.ic-art svg { width: 100%; height: auto; display: block; }
.ic-name { font-family: var(--font-display); font-size: 1.12rem; line-height: 1.15; color: var(--ink); }
.ic-desc { font-size: .88rem; color: var(--muted); margin: 3px 0 8px; }
.ic-meta { display: flex; flex-wrap: wrap; gap: 6px; font-size: .78rem; font-weight: 800; }
.ic-meta span { background: var(--soft); padding: 2px 8px; border-radius: 999px; }
[data-band="4-5"] .ic-desc { display: none; }
@keyframes rise { from { opacity: 0; translate: 0 16px; } }
.map-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 28px; }

/* ---------- Introdução / resultado ---------- */
.intro, .result, .rest { text-align: center; }
.intro-art { background: var(--it); border-radius: 28px; padding: 10px; max-width: 320px; margin: 8px auto 14px; }
.intro-art svg { width: 100%; display: block; }
.intro-meta { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 8px 0; }
.chip { display: inline-flex; align-items: center; gap: 4px; background: #fff; box-shadow: inset 0 0 0 2px var(--line); border-radius: 999px; padding: 6px 12px; font-weight: 800; font-size: .92rem; color: var(--ink); }
.chip.bad { background: #FFE4E6; box-shadow: inset 0 0 0 2px #FDA4AF; }
.res-hero { margin-top: 10px; }
.res-stars { display: inline-flex; align-items: center; gap: 8px; background: #FEF3C7; border-radius: 999px; padding: 8px 20px; font-size: 1.4rem; margin: 6px 0 14px; }
.res-stars b { font-size: 1.6rem; }
.res-list { list-style: none; padding: 0; margin: 0 auto; text-align: left; max-width: 480px; display: grid; gap: 8px; }
.res-list li { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 14px; padding: 10px 12px; box-shadow: inset 0 0 0 2px var(--line); }
.res-n { width: 30px; height: 30px; border-radius: 50%; background: var(--it); display: grid; place-items: center; font-weight: 900; flex: none; }
.res-t { flex: 1; font-weight: 800; } .res-t em { display: block; font-style: normal; font-weight: 600; font-size: .82rem; color: var(--muted); }
.res-b { font-size: .82rem; font-weight: 800; white-space: nowrap; }
.praise { font-weight: 800; margin: 14px 0; }
.unlock { display: flex; align-items: center; gap: 14px; text-align: left; background: #fff; border-radius: 18px; padding: 12px 16px; margin: 10px auto; max-width: 480px; box-shadow: inset 0 0 0 3px #FDE68A; }
.unlock p { margin: 0; }
.un-e { font-size: 40px; }
.rest-art { position: relative; display: inline-block; margin: 10px 0; }
.rest-art .moon { position: absolute; left: -40px; top: 0; font-size: 40px; }
.rest-art .zz { position: absolute; right: -30px; top: 6px; font-weight: 900; color: var(--purple); font-size: 1.3rem; }
.breathe { display: grid; place-items: center; height: 120px; }
.breathe span { width: 60px; height: 60px; border-radius: 50%; background: radial-gradient(circle, #99F6E4, #2DD4BF); animation: breathe 8s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.7); } }

/* ---------- Atividade ---------- */
.play-top { gap: 10px; }
.progress { flex: 1; display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; }
.progress .dot { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: .85rem; background: #fff; box-shadow: inset 0 0 0 2px var(--line); color: var(--muted); }
.progress .dot.done { background: var(--teal); color: var(--ink); box-shadow: none; }
.progress .dot.now { background: var(--purple); color: #fff; box-shadow: 0 0 0 3px #DDD6FE; }
.play-main { max-width: 820px; margin: 0 auto; padding: 12px 16px 120px; }
.prompt-card { display: flex; gap: 12px; align-items: flex-start; background: #fff; border-radius: var(--radius); padding: 14px 16px; box-shadow: var(--shadow); }
.prompt { font-size: var(--fs-prompt); margin: 0 0 4px; font-family: var(--font-display); }
.how { margin: 0; color: var(--muted); font-weight: 700; font-size: .98rem; }
.rules { margin: 8px 0 0; padding-left: 20px; font-weight: 700; }
.rules li { margin: 2px 0; }
.tools { display: flex; gap: 8px; justify-content: flex-end; margin: 10px 0; flex-wrap: wrap; }
.tool { flex-direction: row; gap: 6px; font-size: .92rem; min-height: 48px; padding: 6px 14px; border-radius: 999px; }
.tool:disabled { opacity: .5; }
.tool-hint { background: #FEF3C7; box-shadow: inset 0 0 0 2px #FDE68A; }
.stage { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; min-height: 200px; display: flex; flex-direction: column; gap: 16px; align-items: center; }
.action { position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; display: flex; justify-content: center; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: linear-gradient(180deg, rgba(247, 248, 252, 0), var(--bg) 35%); pointer-events: none; }
.action .btn { pointer-events: auto; min-width: min(360px, 100%); }
.action:empty { display: none; }

/* ---------- Tokens ---------- */
.tok { display: inline-grid; place-items: center; width: var(--tok); height: var(--tok); flex: none; line-height: 1; }
.tok-emo { font-size: calc(var(--tok) * .78); }
.tok-emo.size-s { font-size: calc(var(--tok) * .42); } .tok-emo.size-m { font-size: calc(var(--tok) * .7); } .tok-emo.size-l { font-size: calc(var(--tok) * 1.05); }
.tok-shape .shape { display: block; margin: auto; }
.tok-num { font-weight: 900; font-size: calc(var(--tok) * .6); font-family: var(--font-display); width: auto; min-width: var(--tok); padding: 0 6px; }
.tok-nd { display: inline-flex; flex-direction: column; gap: 4px; height: auto; }
.tok-nd b { font-size: calc(var(--tok) * .8); line-height: 1; }
.tok-nd i { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; max-width: 70px; }
.tok-nd s { width: 12px; height: 12px; border-radius: 50%; background: var(--purple); text-decoration: none; display: block; }
.tok-text { width: auto; height: auto; min-height: var(--tok); padding: 6px 12px; font-weight: 900; font-size: 1.12rem; white-space: nowrap; }
.tok-group { display: flex; flex-wrap: wrap; gap: 2px; justify-content: center; width: auto; max-width: 150px; height: auto; min-height: var(--tok); padding: 8px; background: #F1F5F9; border-radius: 50%; font-size: calc(var(--tok) * .5); }
.tok-sil { filter: brightness(0) opacity(.78); }
.tok-peek { position: relative; overflow: hidden; }
.tok-peek .wall { position: absolute; left: -6%; right: -6%; bottom: 0; height: 52%; background: repeating-linear-gradient(0deg, #C2410C 0 12px, #FDBA74 12px 14px), #C2410C; border-top: 3px solid #7C2D12; background-size: 100% 14px; }
.tok-peek .wall::after { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(90deg, transparent 0 22px, #FDBA74 22px 24px); }
.tok-away { position: relative; opacity: .45; transform: translateY(-10px) rotate(8deg); }
.tok-away b { position: absolute; top: -6px; right: -4px; font-size: 16px; color: var(--ink); opacity: 1; }
.tok-svgw { width: calc(var(--tok) * 1.5); height: calc(var(--tok) * 1.4); }
.tok-svgw svg, .tok-svg { width: 100%; height: 100%; }
.tok-art { width: 150px; height: 150px; }
.tok-lamps { width: auto; height: auto; }
.tok-lamps svg { width: 150px; height: 46px; }
.tok-person { display: inline-flex; flex-direction: row; gap: 8px; width: auto; height: auto; padding: 6px 12px 6px 6px; background: #fff; border-radius: 999px; box-shadow: inset 0 0 0 2px var(--line); font-weight: 900; font-size: 1.02rem; }
.pdot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: var(--ink); font-weight: 900; }
.tok-weight { position: relative; width: 62px; height: 60px; }
.tok-weight svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.tok-weight b { position: relative; top: 8px; font-size: .9rem; font-weight: 900; color: #fff; text-shadow: 0 1px 0 #24324B, 0 0 3px #24324B; }
.tok-q { border-radius: 16px; border: 3px dashed var(--purple); color: var(--purple-ink); font-weight: 900; font-size: calc(var(--tok) * .55); background: #F5F3FF; animation: pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(124, 92, 252, .15); } }
.tok-wrap { display: inline-flex; flex-direction: column; align-items: center; gap: 4px; }
.tok-cap { font-size: .86rem; font-weight: 800; text-align: center; line-height: 1.2; max-width: 150px; }

/* ---------- Cenas ---------- */
.scene-seq, .scene-row { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; align-items: center; padding: 10px; background: var(--soft); border-radius: var(--radius-sm); width: 100%; }
.scene-seq > span { display: inline-flex; }
.scene-col { display: flex; flex-direction: column; gap: 6px; align-items: center; background: var(--soft); border-radius: var(--radius-sm); padding: 10px; }
.scene-big { display: grid; place-items: center; padding: 14px; background: var(--soft); border-radius: var(--radius); min-width: 170px; }
.scene-big .tok { --tok: 110px; }
.scene-big .tok-text { font-size: 1.6rem; }
.scene-grid { display: grid; grid-template-columns: repeat(var(--cols), auto); gap: 6px; background: var(--soft); padding: 10px; border-radius: var(--radius-sm); }
.scene-grid .cell { display: grid; place-items: center; background: #fff; border-radius: 10px; padding: 4px; min-width: calc(var(--tok) + 8px); min-height: calc(var(--tok) + 8px); }
.scene-clues { list-style: none; margin: 0; padding: 0; width: 100%; display: grid; gap: 8px; }
.scene-clues li { display: flex; gap: 10px; align-items: flex-start; background: #FFFBEB; border-radius: 12px; padding: 10px 12px; font-weight: 800; box-shadow: inset 4px 0 0 var(--yellow); }
.clue-ico { flex: none; }
.scene-text { font-weight: 800; margin: 0; }
.scene-table-wrap { width: 100%; overflow-x: auto; }
.scene-table { border-collapse: separate; border-spacing: 0; width: 100%; background: #fff; border-radius: 12px; overflow: hidden; box-shadow: inset 0 0 0 2px var(--line); font-size: .98rem; }
.scene-table th, .scene-table td { padding: 8px 10px; text-align: center; border-bottom: 1px solid var(--line); }
.scene-table th { background: var(--soft); font-weight: 900; }
.scene-table tr:last-child td { border-bottom: 0; }
.scene-bars { display: flex; align-items: flex-end; justify-content: center; gap: 12px; height: 180px; width: 100%; padding: 8px 8px 0; background: var(--soft); border-radius: var(--radius-sm); }
.bar { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; flex: 1; max-width: 70px; }
.bar b { font-size: .95rem; }
.bar span { width: 100%; background: repeating-linear-gradient(45deg, var(--blue) 0 8px, #5CCBFA 8px 16px); border-radius: 8px 8px 0 0; min-height: 4px; box-shadow: inset 0 0 0 2px rgba(36, 50, 75, .25); }
.bar em { font-style: normal; font-weight: 800; font-size: .85rem; padding: 4px 0; }

/* ---------- Opções ---------- */
.options { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; width: 100%; }
.opt { position: relative; display: grid; place-items: center; min-width: var(--opt); min-height: var(--opt); padding: 10px; border: 0; border-radius: var(--radius); background: #fff; box-shadow: inset 0 0 0 3px var(--line), 0 5px 0 var(--line); transition: transform .12s, box-shadow .12s; }
.opt:hover:not(:disabled) { box-shadow: inset 0 0 0 3px #C4B5FD, 0 5px 0 #C4B5FD; }
.opt:active { transform: translateY(3px); }
.opt .mark { position: absolute; top: -10px; right: -10px; width: 34px; height: 34px; border-radius: 50%; display: none; place-items: center; font-weight: 900; font-size: 1.1rem; }
.opt.correct { background: var(--ok-bg); box-shadow: inset 0 0 0 4px var(--ok), 0 5px 0 var(--ok); }
.opt.correct .mark { display: grid; background: var(--ok); color: #fff; }
.opt.tried { background: #F8FAFC; box-shadow: inset 0 0 0 3px #CBD5E1; border: 0; opacity: .75; }
.opt.tried::after { content: ''; position: absolute; inset: 6px; border: 2px dashed #94A3B8; border-radius: calc(var(--radius) - 6px); }
.opt.tried .mark { display: grid; background: #E2E8F0; color: var(--ink); }
.opt.selected { background: #EDE9FE; box-shadow: inset 0 0 0 4px var(--purple), 0 5px 0 var(--purple); }
.opt.selected .mark { display: grid; background: var(--purple); color: #fff; }
.opt.dim { opacity: .45; }
.opt-text { flex-direction: column; align-items: stretch; }
.opt-text .opt { display: flex; align-items: center; gap: 12px; text-align: left; min-height: 60px; font-weight: 800; font-size: 1.02rem; padding: 12px 16px; }
.opt-letter { width: 32px; height: 32px; border-radius: 50%; background: var(--soft); display: grid; place-items: center; font-weight: 900; flex: none; }
.opt-cards .opt { width: calc(50% - 6px); min-height: 110px; }
.opt-cards .tok-cap { max-width: none; }
.multi-info { font-weight: 900; background: var(--soft); border-radius: 999px; padding: 8px 16px; margin: 0; text-align: center; }

/* ---------- Número ---------- */
.num-display { display: flex; align-items: baseline; justify-content: center; gap: 8px; min-width: 180px; padding: 10px 20px; border-radius: 16px; background: var(--soft); box-shadow: inset 0 0 0 3px var(--line); }
.num-display span { font-size: 2.4rem; font-weight: 900; font-family: var(--font-display); min-width: 1ch; }
.num-display em { font-style: normal; font-weight: 800; color: var(--muted); }
.num-display.correct { background: var(--ok-bg); box-shadow: inset 0 0 0 3px var(--ok); }
.keypad { display: grid; grid-template-columns: repeat(3, 76px); gap: 10px; justify-content: center; }
.key { height: 64px; border: 0; border-radius: 18px; background: #fff; box-shadow: inset 0 0 0 2px var(--line), 0 4px 0 var(--line); font-size: 1.5rem; font-weight: 900; }
.key:active { transform: translateY(3px); }
.key-soft { background: var(--soft); }

/* ---------- Memória ---------- */
.mem-info { margin: 0; font-weight: 800; text-align: center; min-height: 1.4em; }
.mem-grid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 10px; width: 100%; max-width: 520px; }
.mcard { position: relative; aspect-ratio: 3 / 3.6; border: 0; border-radius: 16px; padding: 0; background: transparent; perspective: 600px; }
.mcard > span { position: absolute; inset: 0; display: grid; place-items: center; border-radius: 16px; backface-visibility: hidden; transition: transform .35s; }
.mback { background: linear-gradient(135deg, var(--purple), #9F87FF); box-shadow: 0 4px 0 #5A3FE0; }
.mback svg { width: 44%; }
.mface { background: #fff; box-shadow: inset 0 0 0 3px var(--line); transform: rotateY(180deg); }
.mface .tok { --tok: 46px; }
.mface .tok-text { font-size: 1rem; white-space: normal; text-align: center; }
.mface .tok-group { --tok: 36px; background: none; }
.mcard.open .mback { transform: rotateY(180deg); }
.mcard.open .mface { transform: rotateY(360deg); }
.mcard.matched .mface { background: var(--ok-bg); box-shadow: inset 0 0 0 3px var(--ok); }
.mcard.matched .mface::after { content: '✓'; position: absolute; top: 4px; right: 8px; font-weight: 900; color: var(--ok); }

/* ---------- Onde estava ---------- */
.memo-box { text-align: center; width: 100%; }
.memo-title { font-weight: 900; font-size: 1.1rem; margin: 0 0 10px; text-align: center; }
.memo-row { margin-bottom: 8px; }
.ask { display: flex; align-items: center; gap: 10px; font-weight: 900; font-size: 1.1rem; background: #FFFBEB; padding: 8px 16px; border-radius: 999px; }
.where-grid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 8px; width: 100%; max-width: 440px; }
.wcell { aspect-ratio: 1; border: 0; border-radius: 14px; background: var(--soft); display: grid; place-items: center; box-shadow: inset 0 0 0 2px var(--line); }
.where-grid.hidden .wcell { background: linear-gradient(135deg, #DDD6FE, #C4B5FD); box-shadow: 0 4px 0 #A78BFA; }
.where-grid .wcell.correct { background: var(--ok-bg); box-shadow: inset 0 0 0 4px var(--ok); }
.where-grid .wcell.tried { background: #F1F5F9; box-shadow: inset 0 0 0 2px #CBD5E1; }
.where-grid .wcell.dim { opacity: .5; }
.wq { font-weight: 900; color: var(--purple-ink); font-size: 1.4rem; }
.wcell .tok { --tok: 40px; }
[data-band="4-5"] .wcell .tok { --tok: 64px; }

/* ---------- Posicionar peças ---------- */
.slots { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; width: 100%; }
.slot { flex: 1 1 140px; min-width: 110px; border-radius: var(--radius-sm); background: var(--soft); box-shadow: inset 0 0 0 3px transparent; padding: 8px; display: flex; flex-direction: column; gap: 6px; transition: box-shadow .12s, background .12s; cursor: pointer; }
.slot.over { background: #EDE9FE; box-shadow: inset 0 0 0 3px var(--purple); }
.slot-head { display: flex; align-items: center; justify-content: center; gap: 6px; font-weight: 900; text-align: center; min-height: 30px; flex-wrap: wrap; }
.slot-ico .tok { --tok: 30px; }
.slot-emo { font-size: 1.3rem; }
.slot-n { width: 32px; height: 32px; border-radius: 50%; background: #fff; display: grid; place-items: center; box-shadow: inset 0 0 0 2px var(--line); padding: 0 4px; width: auto; min-width: 32px; }
.slot-body { flex: 1; display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; align-content: center; min-height: calc(var(--tok) + 22px); border: 2.5px dashed #C7CEDF; border-radius: 12px; padding: 6px; background: #fff; }
.slot-empty { color: #A0AAC0; font-size: 1.4rem; font-weight: 900; }
.slot-sum { font-size: .82rem; font-weight: 900; background: #fff; border-radius: 999px; padding: 1px 8px; box-shadow: inset 0 0 0 2px var(--line); }
.slot-sum.over { background: #FFE4E6; box-shadow: inset 0 0 0 2px #FB7185; }
.slots.lay-order { display: grid; grid-template-columns: repeat(3, 1fr); }
.slots.lay-order.n2 { grid-template-columns: repeat(2, 1fr); }
.slots.lay-order.n4 { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 560px) { .slots.lay-order.n4 { grid-template-columns: repeat(4, 1fr); } .slots.lay-order.n5 { grid-template-columns: repeat(5, 1fr); } .slots.lay-order.n6 { grid-template-columns: repeat(6, 1fr); } }
.lay-order .slot { min-width: 0; padding: 6px; }
.lay-order .slot-body { padding: 4px; }
.lay-assign { flex-direction: column; } .lay-assign .slot { flex-direction: row; align-items: center; flex: none; } .lay-assign .slot-head { min-width: 110px; justify-content: flex-start; } .lay-assign .slot-body { min-height: calc(var(--tok) + 16px); }
.steps { display: inline-flex; align-items: flex-end; gap: 3px; height: 30px; }
.steps i { width: 10px; background: var(--teal); border-radius: 3px; }
.steps i:nth-child(1) { height: 10px; } .steps i:nth-child(2) { height: 20px; } .steps i:nth-child(3) { height: 30px; }
.tray { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; width: 100%; padding: 12px; border-radius: var(--radius-sm); background: #FFFBEB; box-shadow: inset 0 0 0 2px #FDE68A; min-height: calc(var(--tok) + 40px); align-items: center; }
.tray.over { box-shadow: inset 0 0 0 3px var(--yellow); }
.ptok { display: inline-grid; place-items: center; padding: 6px; border: 0; background: #fff; border-radius: 14px; box-shadow: inset 0 0 0 2px var(--line), 0 3px 0 var(--line); touch-action: none; user-select: none; -webkit-user-select: none; min-width: 56px; min-height: 56px; }
.ptok.sel { box-shadow: inset 0 0 0 4px var(--purple), 0 0 0 4px #DDD6FE; background: #F5F3FF; transform: translateY(-3px); }
.ptok.dragging { opacity: .35; }
.ptok.ghost { position: fixed; z-index: 100; pointer-events: none; opacity: .95; transform: scale(1.06) rotate(-2deg); box-shadow: 0 16px 30px -8px rgba(0, 0, 0, .35); }
.ptok .tok-cap { max-width: 120px; font-size: .8rem; }
.solved .slot-body, .solved .pz-board { box-shadow: 0 0 0 4px var(--ok); border-color: var(--ok); }
.pz-board { display: grid; grid-template-columns: repeat(var(--cols), 1fr); width: min(100%, 420px); border-radius: 12px; overflow: hidden; position: relative; background: #F1F5F9; box-shadow: inset 0 0 0 2px var(--line); }
.pz-board.guide::before { content: ''; position: absolute; inset: 0; background-image: var(--guide); background-size: 100% 100%; opacity: .18; filter: grayscale(.4); pointer-events: none; }
.pz-slot { position: relative; outline: 1.5px dashed rgba(36, 50, 75, .25); outline-offset: -1px; border-radius: 0; background: transparent; padding: 0; display: block; min-width: 0; }
.pz-slot.over { background: rgba(124, 92, 252, .18); }
.pz-slot .piece { width: 100%; height: 100%; border-radius: 0; box-shadow: none; padding: 0; min-width: 0; min-height: 0; display: block; }
.pz-slot .piece.sel { box-shadow: inset 0 0 0 4px var(--purple); transform: none; }
.tray-pz .piece { width: clamp(64px, 22vw, 110px); padding: 0; background-repeat: no-repeat; min-width: 0; min-height: 0; }
.pz-ref { display: flex; align-items: center; gap: 8px; }
.pz-thumb { display: block; width: 120px; background-size: 100% 100%; border-radius: 8px; box-shadow: inset 0 0 0 2px var(--line); }

/* ---------- Caminhos ---------- */
.path-status { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.energy { width: min(100%, 420px); height: 12px; background: #E2E8F0; border-radius: 999px; overflow: hidden; }
.energy b { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), var(--yellow)); transition: width .2s; }
.path-grid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 4px; width: min(100%, 460px); background: #D1FAE5; padding: 6px; border-radius: 16px; }
.pcell { aspect-ratio: 1; border: 0; border-radius: 10px; background: #F0FDF4; display: grid; place-items: center; font-size: clamp(16px, 5vw, 28px); padding: 0; position: relative; }
.pcell.wall { background: #A7F3D0; }
.pcell.avoid { background: #DBEAFE; }
.pcell.mud { background: #E7D3B8; }
.pcell.goal { background: #FEF3C7; }
.pcell.must { background: #EDE9FE; }
.pcell.must.got { color: var(--ok); font-weight: 900; }
.pcell.trail::before { content: ''; position: absolute; width: 26%; height: 26%; border-radius: 50%; background: var(--purple); opacity: .55; }
.pcell.sol { box-shadow: inset 0 0 0 3px var(--ok); }
.pcell.adj { box-shadow: inset 0 0 0 2.5px #A78BFA; }
.pcell.here { background: #fff; box-shadow: inset 0 0 0 3px var(--purple); z-index: 1; }
.pcell.here::before { display: none; }
.hero { font-size: 1.15em; }
.path-grid.solved { box-shadow: 0 0 0 4px var(--ok); }
.dpad { display: grid; grid-template-columns: repeat(3, 84px); grid-template-rows: repeat(2, 56px); gap: 6px; justify-content: center; }
.dkey { display: flex; flex-direction: column; align-items: center; justify-content: center; border: 0; border-radius: 14px; background: #fff; box-shadow: inset 0 0 0 2px var(--line), 0 3px 0 var(--line); font-size: .72rem; font-weight: 800; }
.dkey[data-d="0,-1"] { grid-column: 2; grid-row: 1; }
.dkey[data-d="-1,0"] { grid-column: 1; grid-row: 2; }
.dkey[data-d="0,1"] { grid-column: 2; grid-row: 2; }
.dkey[data-d="1,0"] { grid-column: 3; grid-row: 2; }

/* ---------- Overlays ---------- */
.overlay { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; background: rgba(36, 50, 75, .45); opacity: 0; transition: opacity .2s; padding: 12px; }
.overlay.show { opacity: 1; }
.sheet { background: #fff; border-radius: 28px; width: 100%; max-width: 560px; max-height: 92vh; overflow: auto; padding: 22px 20px 20px; box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .35); transform: translateY(20px); transition: transform .25s; text-align: center; margin-bottom: env(safe-area-inset-bottom); }
.overlay.show .sheet { transform: none; }
@media (min-width: 700px) { .overlay { align-items: center; } }
.ov-peek { background: rgba(36, 50, 75, .25); }
.bubble { display: flex; gap: 12px; align-items: flex-start; text-align: left; background: #FFFBEB; border-radius: 20px; padding: 12px 14px; box-shadow: inset 0 0 0 2px #FDE68A; }
.bubble b { font-family: var(--font-display); font-size: 1.05rem; }
.bubble p { margin: 2px 0 0; font-weight: 700; font-size: 1.05rem; }
.retry h2 { color: var(--ink); }
.retry-msg { font-weight: 800; background: var(--soft); padding: 8px 12px; border-radius: 12px; }
.win h2 { font-size: 1.7rem; color: var(--purple-ink); margin-top: 6px; }
.star-earn { font-weight: 900; font-size: 1.15rem; margin: 0 0 10px; }
.why { background: var(--ok-bg); border-radius: 18px; padding: 12px 16px; text-align: left; }
.why b { font-family: var(--font-display); }
.why p { margin: 2px 0 0; font-weight: 700; font-size: 1.05rem; }
.reveal .why { background: #EFF6FF; }
.pause .toggles { display: grid; gap: 8px; margin-top: 18px; }
.toggle { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 16px; border: 0; border-radius: 14px; background: var(--soft); font-weight: 800; text-align: left; }
.toggle[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--purple); background: #F5F3FF; }
.help-head { display: flex; align-items: center; gap: 10px; justify-content: center; }
.help-list { list-style: none; padding: 0; margin: 12px 0; display: grid; gap: 8px; text-align: left; }
.help-list li { display: flex; gap: 12px; align-items: center; background: var(--soft); border-radius: 14px; padding: 10px 12px; }
.hl-ico { width: 44px; height: 44px; border-radius: 12px; background: #fff; display: grid; place-items: center; flex: none; font-size: 22px; }
#toast { position: fixed; left: 50%; top: 16px; transform: translate(-50%, -80px); background: var(--ink); color: #fff; font-weight: 800; padding: 10px 18px; border-radius: 999px; z-index: 200; transition: transform .25s; max-width: calc(100% - 32px); text-align: center; }
#toast.show { transform: translate(-50%, 0); }
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 60; overflow: hidden; }
.confetti i { position: absolute; top: 45%; width: 12px; height: 12px; border-radius: 3px; animation: conf 1.2s ease-out forwards; }
.confetti i:nth-child(3n) { border-radius: 50%; } .confetti i:nth-child(3n+1) { clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); width: 16px; height: 16px; }
@keyframes conf { 0% { transform: translate(0, 0) scale(.5); opacity: 1; } 100% { transform: translate(var(--dx), -260px) rotate(300deg) scale(1); opacity: 0; } }

/* ---------- Meu cantinho ---------- */
.corner-grid { display: grid; gap: 14px; }
@media (min-width: 820px) { .corner-grid { grid-template-columns: 1fr 1fr; align-items: start; } }
.av-stage { display: flex; align-items: center; gap: 16px; padding: 10px 0 6px; }
.acc-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; }
.acc-opt { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px; min-height: 70px; border: 0; border-radius: 14px; background: var(--soft); }
.acc-opt span { font-size: 26px; } .acc-opt em { font-style: normal; font-size: .78rem; font-weight: 800; }
.acc-opt[aria-checked="true"] { box-shadow: inset 0 0 0 3px var(--purple); background: #F5F3FF; }
.acc-opt:disabled { opacity: .55; filter: grayscale(1); }
.shelf { background: var(--it); border-radius: 16px; padding: 10px 12px; margin-bottom: 10px; }
.shelf-name { font-weight: 900; font-size: .9rem; }
.shelf-items { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 6px; border-bottom: 6px solid color-mix(in srgb, var(--ic) 45%, #fff); padding-bottom: 6px; }
.shelf-item { display: flex; flex-direction: column; align-items: center; font-size: 30px; color: #A0AAC0; font-weight: 900; }
.shelf-item em { font-style: normal; font-size: .68rem; font-weight: 800; color: var(--muted); text-align: center; line-height: 1.1; }
.shelf-item:not(.has) { font-size: 24px; }

/* ---------- Responsáveis ---------- */
.gate { text-align: center; }
.gate-ico { width: 72px; height: 72px; border-radius: 50%; background: #EDE9FE; color: var(--purple-ink); display: grid; place-items: center; margin: 10px auto; }
.gate-ico .ico { width: 36px; height: 36px; }
.pin-dots { display: flex; gap: 14px; justify-content: center; margin: 14px 0 6px; }
.pin-dots span { width: 20px; height: 20px; border-radius: 50%; box-shadow: inset 0 0 0 3px var(--ink); }
.pin-dots span.on { background: var(--ink); }
.tabs { display: flex; gap: 6px; background: var(--soft); padding: 5px; border-radius: 999px; margin: 6px 0 16px; overflow-x: auto; }
.tabs button { flex: 1; min-height: 46px; border: 0; background: transparent; border-radius: 999px; font-weight: 800; white-space: nowrap; padding: 0 14px; }
.tabs button[aria-selected="true"] { background: #fff; box-shadow: var(--shadow); color: var(--purple-ink); }
.kids { display: grid; gap: 14px; }
@media (min-width: 900px) { .kids { grid-template-columns: 1fr 1fr; align-items: start; } }
.kid-head { display: flex; align-items: center; gap: 12px; }
.kid-head > div { flex: 1; } .kid-head h3 { margin: 0 0 2px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 14px 0; }
.kpis div { background: var(--soft); border-radius: 12px; padding: 8px; text-align: center; }
.kpis b { display: block; font-size: 1.4rem; font-family: var(--font-display); }
.kpis span { font-size: .72rem; font-weight: 700; color: var(--muted); line-height: 1.1; display: block; }
@media (max-width: 460px) { .kpis { grid-template-columns: repeat(2, 1fr); } }
details { border-top: 1px solid var(--line); padding: 10px 0; }
summary { font-weight: 900; cursor: pointer; min-height: 32px; display: flex; align-items: center; }
.skill-bars { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 6px; }
.skill-bars li { display: grid; grid-template-columns: 1fr 1fr 28px; gap: 8px; align-items: center; font-size: .9rem; font-weight: 700; }
.skill-bars i { height: 10px; background: var(--soft); border-radius: 999px; overflow: hidden; }
.skill-bars b { display: block; height: 100%; background: var(--teal); border-radius: 999px; }
.skill-bars em { font-style: normal; font-weight: 900; text-align: right; }
.help-needed { padding-left: 18px; margin: 8px 0; }
.help-needed li { margin-bottom: 6px; }
.settings { display: grid; gap: 4px; margin-top: 6px; }
.set { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 50px; padding: 4px 0; font-weight: 700; border-bottom: 1px dashed var(--line); }
.set input[type="checkbox"] { width: 26px; height: 26px; accent-color: var(--purple); flex: none; }
.set select { min-height: 44px; border-radius: 12px; border: 2px solid var(--line); padding: 4px 8px; background: #fff; max-width: 60%; }
.kid-foot { display: flex; gap: 8px; flex-wrap: wrap; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 4px; }
.plain { padding-left: 18px; } .plain li { margin-bottom: 4px; }

/* ---------- Tema maduro (10 a 13 anos) ---------- */
[data-band="10-11"] body, [data-band="12-13"] body { background: #EEF1F7; }
[data-band="10-11"] .prompt-card, [data-band="12-13"] .prompt-card { border-left: 6px solid var(--purple); }
[data-band="12-13"] .prompt-card { border-left-color: var(--coral); }
[data-band="10-11"] .island-card, [data-band="12-13"] .island-card { box-shadow: 0 4px 0 rgba(0, 0, 0, .25); }
[data-band="10-11"] .continue-card, [data-band="12-13"] .continue-card { box-shadow: 0 4px 0 #A07C00; }

/* ---------- Telas pequenas ---------- */
@media (max-width: 420px) {
  body { font-size: 16px; }
  .tb-btn span { font-size: .66rem; }
  .tb-btn { min-width: 50px; padding: 4px 6px; }
  .opt-cards .opt { min-height: 96px; padding: 8px 6px; }
  .keypad { grid-template-columns: repeat(3, 70px); }
  .stage { padding: 12px; }
  .island-card { padding: 8px 8px 12px; }
  .ic-name { font-size: 1rem; }
  .lay-assign .slot-head { min-width: 86px; }
}

/* ---------- Movimento reduzido ---------- */
.reduce-motion *, .reduce-motion *::before, .reduce-motion *::after { animation: none !important; transition: none !important; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
.q-filled { display: inline-flex; border-radius: 16px; background: var(--ok-bg); box-shadow: inset 0 0 0 3px var(--ok); }
.small-t { font-size: .85rem; } .small-t td:first-child, .small-t th:first-child { text-align: left; }

/* ---------- Diferenças e pintura ---------- */
.diff-info { margin: 0; font-weight: 900; text-align: center; }
.diff-wrap, .paint-wrap { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; width: 100%; }
.diff-wrap figure, .paint-wrap figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.diff-wrap figcaption, .paint-wrap figcaption { font-weight: 900; font-size: .9rem; color: var(--muted); }
.diff-grid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 4px; background: var(--soft); padding: 6px; border-radius: 14px; }
.dcell { width: clamp(40px, 12vw, 58px); aspect-ratio: 1; display: grid; place-items: center; background: #fff; border: 0; border-radius: 10px; padding: 0; box-shadow: inset 0 0 0 2px var(--line); position: relative; }
.dcell .tok { --tok: clamp(28px, 8vw, 40px); }
.dcell.found { box-shadow: inset 0 0 0 4px var(--ok); background: var(--ok-bg); }
.dcell.found::after { content: '✓'; position: absolute; top: -6px; right: -4px; background: var(--ok); color: #fff; border-radius: 50%; width: 20px; height: 20px; font-size: .75rem; font-weight: 900; display: grid; place-items: center; }
.dcell.tried { box-shadow: inset 0 0 0 3px #94A3B8; background: #F1F5F9; }
.paint-grid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 3px; background: var(--soft); padding: 6px; border-radius: 14px; position: relative; }
.paint-grid.axis::after { content: ''; position: absolute; top: 2px; bottom: 2px; left: 50%; width: 4px; margin-left: -2px; background: var(--coral); border-radius: 2px; pointer-events: none; }
.pcell2 { width: clamp(30px, 9vw, 44px); aspect-ratio: 1; border: 0; border-radius: 6px; background: #fff; box-shadow: inset 0 0 0 2px var(--line); padding: 0; display: block; }
.paint-grid.model .pcell2 { width: clamp(22px, 6vw, 32px); }
.pcell2.on { background: var(--purple) repeating-linear-gradient(45deg, rgba(255,255,255,.18) 0 4px, transparent 4px 8px); box-shadow: inset 0 0 0 2px #5A3FE0; }
.pcell2.lock { background-color: #A78BFA; cursor: default; }

/* ---------- Segurança dos dados ---------- */
.recovery-code { font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace; font-size: clamp(1.4rem, 7vw, 2.1rem); font-weight: 800; letter-spacing: .08em; text-align: center; background: #fff; border: 3px dashed var(--purple); border-radius: 16px; padding: 14px 10px; margin: 14px 0; user-select: all; -webkit-user-select: all; }
.check-line { justify-content: flex-start; border: 0; gap: 10px; }
.row-btns.start { justify-content: flex-start; }
.note.banner { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; justify-content: space-between; margin-bottom: 12px; }
.import-preview .scene-table td { vertical-align: middle; }
.import-preview .avatar { width: 30px; height: 30px; box-shadow: none; } .import-preview .av-e { font-size: 18px; } .import-preview .av-acc { display: none; }

/* grades de pintura largas (até 10 colunas) cabem em telas de 320 px */
.paint-grid.play .pcell2 { width: min(44px, calc((100vw - 110px) / var(--cols))); }
.paint-grid.model .pcell2 { width: min(32px, calc((100vw - 110px) / var(--cols) * .7)); }

/* ---------- Marca Pequenos Hábitos ---------- */
.brand-tag { display: inline-flex; align-items: center; gap: 10px; margin: 14px 0 0; position: relative; text-align: left; color: var(--ink); font-size: .95rem; line-height: 1.25; background: rgba(255, 255, 255, .9); border-radius: 999px; padding: 6px 16px 6px 6px; box-shadow: 0 4px 14px -8px rgba(36, 50, 75, .35); z-index: 1; }
.brand-tag .brand-logo { width: 40px; height: 40px; flex: none; }
.brand-tag b { color: #5646D6; font-family: var(--font-display); }
.brand-tag em { display: block; font-style: normal; font-size: .82rem; color: var(--muted); }
.brand-about { background: #F3F1FE; margin-top: 10px; }

/* ---------- Rodapé padrão da família Pequenos Hábitos ---------- */
.ph-foot { position: relative; z-index: 1; text-align: center; margin: 18px auto 0; padding: 8px 16px; background: rgba(255, 255, 255, .78); border-radius: 18px; width: fit-content; }
.ph-brand { display: inline-flex; align-items: center; gap: 7px; text-decoration: none; font-weight: 800; font-size: .95rem; color: #5646D6; }
.ph-brand .ph-logo { width: 22px; height: 22px; flex: none; }
.ph-meta { margin-top: 4px; font-weight: 700; font-size: .82rem; color: var(--muted); }
.ph-meta a { color: inherit; text-decoration: none; }
