@import url("https://fonts.googleapis.com/css2?family=Atkinson+Hyperlegible:wght@400;700&family=Nunito:wght@700;800&display=swap");
:root { --bg: #FBF7F1; --ink: #2F2A26; --mut: #6B625A; --acc: #8A5A3B; --card: #fff; --line: #E8DFD3; --soft: #EFE6DA; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: "Atkinson Hyperlegible", system-ui, sans-serif; font-size: 18px; line-height: 1.5; }
.app.big { font-size: 22px; }
.app { min-height: 100vh; padding-bottom: 96px; font-size: inherit; }
h2, h3, .brand, .tile-title { font-family: Nunito, sans-serif; }
h2 { font-size: 1.6em; margin: 0; scroll-margin-top: 80px; }
h3 { margin: 0 0 10px; font-size: 1.1em; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid #2F6FB0; outline-offset: 3px; }
.topbar { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; padding: 12px 16px; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.brand { color: var(--acc); font-weight: 800; }
.prefs { display: flex; gap: 6px; flex-wrap: wrap; }
.main { max-width: 960px; margin: 0 auto; padding: 20px 16px; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.center { align-items: center; text-align: center; }
.row { display: flex; gap: 10px; align-items: center; }
.wrap { flex-wrap: wrap; }
.small { font-size: .85em; color: var(--mut); margin: 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 18px; box-shadow: 0 4px 14px rgba(80,60,40,.06); }
.input { font: inherit; padding: 10px 12px; border: 2px solid var(--line); border-radius: 12px; background: #fff; width: 100%; }
.btn { border: 0; background: var(--acc); color: #fff; padding: 14px 20px; border-radius: 16px; font-weight: 700; min-height: 52px; }
.btn.soft { background: var(--soft); color: var(--ink); }
.btn.ghost { background: transparent; border: 2px solid var(--line); color: var(--ink); }
.chip { border: 2px solid var(--line); background: #fff; padding: 8px 14px; border-radius: 999px; min-height: 44px; }
.chip.on, .chip[aria-pressed="true"] { background: #F3E3D3; border-color: var(--acc); font-weight: 700; }
.audio { border: 0; background: #fff; border-radius: 999px; width: 44px; height: 44px; box-shadow: 0 1px 4px rgba(0,0,0,.12); flex: none; vertical-align: middle; }
.hero { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; background: linear-gradient(135deg, #F6E9DA, #E7EEF3); border-radius: 28px; padding: 20px; }
.chars { display: flex; align-items: flex-end; }
.bubble { background: #fff; border-radius: 20px; padding: 14px 16px; margin: 0; flex: 1; min-width: 200px; display: flex; gap: 10px; align-items: center; justify-content: space-between; }
.bubble.big { font-size: 1.15em; font-weight: 700; }
.say { display: flex; gap: 10px; align-items: center; }
.tiles { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.tile { position: relative; background: #fff; border: 2px solid var(--line); border-radius: 24px; padding: 20px; display: flex; flex-direction: column; gap: 6px; min-height: 170px; cursor: pointer; }
.tile:hover { border-color: var(--acc); }
.tile .audio { position: absolute; top: 12px; right: 12px; }
.tile-emoji { font-size: 48px; }
.tile-title { font-size: 1.2em; font-weight: 800; }
.tile-desc { color: var(--mut); }
.motto { text-align: center; color: var(--mut); font-style: italic; }
.emogrid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.emo { border: 2px solid transparent; border-radius: 20px; padding: 14px 8px; display: flex; flex-direction: column; align-items: center; gap: 4px; font-weight: 700; min-height: 110px; }
.emo.plain { background: #fff; border-color: var(--line); font-weight: 400; }
.emo-face { font-size: 40px; }
.emo-card p { margin: 0 0 8px; }
.scale { display: flex; gap: 8px; flex-wrap: wrap; }
.lvl { flex: 1; min-width: 56px; border: 2px solid var(--line); background: #fff; border-radius: 16px; padding: 10px 4px; display: flex; flex-direction: column; align-items: center; gap: 6px; font-weight: 700; justify-content: flex-end; min-height: 90px; }
.lvl .dot { border-radius: 50%; background: #B9A48E; }
.lvl.on { border-color: var(--acc); background: #F3E3D3; }
.needs { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.need { text-align: left; border: 2px solid var(--line); background: #fff; border-radius: 16px; padding: 14px; min-height: 60px; display: flex; gap: 10px; align-items: center; }
.need span { font-size: 28px; }
.need.on { border-color: var(--acc); background: #F3E3D3; font-weight: 700; }
.answer { margin-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.breath { width: 120px; height: 120px; border-radius: 50%; background: #BFD9E8; margin: 30px; }
.breath.run { animation: breathe ease-in-out infinite alternate; }
@keyframes breathe { from { transform: scale(.7); } to { transform: scale(1.35); } }
.field-inline { display: flex; gap: 8px; align-items: center; }
.field-inline .input { width: auto; }
.pause { background: #EEF0EC; border-radius: 16px; padding: 30px 16px; }
.timer { font-size: 2em; font-weight: 700; margin: 0; }
.move-card { background: #F4EEE6; border-radius: 20px; padding: 24px; display: flex; flex-direction: column; align-items: center; gap: 8px; max-width: 420px; }
.move-card > span { font-size: 56px; }
.move-card p { margin: 0; font-size: 1.1em; }
.place { height: 260px; border-radius: 20px; }
.showbig { position: fixed; inset: 0; background: #FFFDF8; z-index: 20; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 24px; padding: 24px; text-align: center; }
.showbig p { font-size: clamp(32px, 7vw, 64px); font-weight: 800; font-family: Nunito, sans-serif; margin: 0; }
.rest { background: #EFEDE8; border-radius: 28px; padding: 40px 16px; }
.help-list { margin: 0; padding-left: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.help-list li { background: #fff; border-radius: 14px; padding: 12px; border: 1px solid var(--line); }
.navbar { position: fixed; bottom: 0; left: 0; right: 0; display: grid; grid-template-columns: repeat(4, 1fr); background: #fff; border-top: 1px solid var(--line); z-index: 10; }
.navbar button { border: 0; background: none; padding: 10px 4px; display: flex; flex-direction: column; align-items: center; font-weight: 700; font-size: 15px; min-height: 68px; }
.navbar button span { font-size: 24px; }
.navbar button:disabled { opacity: .4; }
.app.calm { --bg: #F2F1EE; --acc: #5E6A72; --soft: #E4E4E0; }
.app.calm .hero { background: #E9E9E5; }
.app.calm .emo { background: #fff !important; border-color: var(--line); }
.app.calm .breath.run { animation: none; }
@media (prefers-reduced-motion: reduce) { .breath.run { animation-duration: 20s !important; } }
