/* CORDEL · papel, tinta e madeira. Toda a interface parece folheto de feira. */
:root {
  --papel: #efe3c6;
  --papel2: #e4d3ae;
  --papel3: #d9c59b;
  --tinta: #1c1611;
  --tinta2: #2b231b;
  --vermelho: #b8352a;
  --ocre: #c98f2e;
  --amarelo: #e0b03c;
  --verde: #4d7a39;
  --azul: #2e5b85;
  --rosa: #cd6c88;
  --ouro: #d6a531;
  --serif: 'Alegreya', Georgia, 'Times New Roman', serif;
  --sc: 'Alegreya SC', 'Alegreya', Georgia, serif;
  --madeira: 'Alfa Slab One', 'Rockwell', Georgia, serif;
  --serrilha: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='8'%3E%3Cpath d='M0 8 L8 0 L16 8Z' fill='%231c1611'/%3E%3C/svg%3E");
  --grao: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.11 0 0 0 0 0.09 0 0 0 0 0.07 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--tinta); color: var(--tinta); font-family: var(--serif); -webkit-tap-highlight-color: transparent; }
body { touch-action: none; user-select: none; -webkit-user-select: none; }
canvas#jogo { position: fixed; inset: 0; width: 100vw; height: 100vh; display: block; cursor: crosshair; }
#ui { position: fixed; inset: 0; pointer-events: none; font-size: 16px; }
#ui > * { pointer-events: auto; }
#ui .vazado { pointer-events: none; }
button { font-family: var(--sc); cursor: pointer; }
input, textarea { font-family: var(--serif); }

/* ── papel e moldura ─────────────────────────────────────────────────────────────────────── */
.papel { background: var(--papel) var(--grao); color: var(--tinta); border: 3px solid var(--tinta); box-shadow: 0 0 0 3px var(--papel), 0 0 0 6px var(--tinta), 8px 10px 0 6px rgba(0,0,0,.35); }
.serrilha { height: 8px; background: var(--serrilha) repeat-x; background-size: 16px 8px; }
.serrilha.baixo { transform: scaleY(-1); }
.madeira { font-family: var(--madeira); letter-spacing: .04em; font-weight: 400; }
.sc { font-family: var(--sc); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4em; font-family: var(--sc); font-weight: 800; font-size: 17px; letter-spacing: .03em; color: var(--papel); background: var(--tinta); border: 3px solid var(--tinta); padding: .55em 1.2em; border-radius: 3px; box-shadow: 3px 3px 0 var(--vermelho); transition: transform .06s, box-shadow .06s, background .1s; }
.btn:hover { background: var(--vermelho); border-color: var(--tinta); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--vermelho); }
.btn.claro { color: var(--tinta); background: var(--papel); box-shadow: 3px 3px 0 var(--tinta); }
.btn.claro:hover { background: var(--papel2); }
.btn.peq { font-size: 14px; padding: .3em .8em; box-shadow: 2px 2px 0 var(--vermelho); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.campo { display: block; width: 100%; font-size: 19px; padding: .5em .7em; background: #f7efdc; border: 2px solid var(--tinta); border-radius: 2px; color: var(--tinta); outline: none; }
.campo:focus { box-shadow: 0 0 0 3px var(--ocre); }
label.rot { display: block; font-family: var(--sc); font-size: 14px; margin: .7em 0 .25em; letter-spacing: .04em; }
.erro { color: var(--vermelho); font-weight: 600; min-height: 1.4em; margin: .4em 0; }
.dica { font-style: italic; opacity: .8; font-size: 14px; }

/* ── telas cheias (título, família, criação, morte) ──────────────────────────────────────── */
.tela { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; padding: 16px; overflow: auto; }
.tela canvas.fundo { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.tela > .conteudo { position: relative; z-index: 1; }
.titulo-bloco { text-align: center; color: var(--tinta); }
.titulo-bloco h1 { margin: 0; font-family: var(--madeira); font-weight: 400; font-size: clamp(64px, 13vw, 168px); line-height: .9; letter-spacing: .04em; color: var(--tinta); text-shadow: 4px 4px 0 var(--vermelho); }
.titulo-bloco .lema { font-family: var(--sc); font-size: clamp(18px, 2.4vw, 28px); margin-top: .35em; letter-spacing: .12em; }
.titulo-bloco .sub { font-style: italic; margin-top: .4em; font-size: 16px; opacity: .85; }
.cartao { width: min(460px, 94vw); padding: 22px 26px 18px; }
.cartao h2 { font-family: var(--madeira); font-weight: 400; margin: 0 0 .2em; font-size: 30px; letter-spacing: .03em; }
.abas { display: flex; gap: 6px; margin-bottom: 10px; }
.abas button { flex: 1; background: transparent; border: 0; border-bottom: 3px solid transparent; font-size: 17px; font-weight: 800; padding: .4em; color: var(--tinta); opacity: .55; }
.abas button.on { border-bottom-color: var(--vermelho); opacity: 1; }
.rodape { position: fixed; bottom: 10px; left: 0; right: 0; text-align: center; font-size: 13px; color: var(--tinta); opacity: .7; pointer-events: none; }

/* família */
.familia { width: min(980px, 96vw); max-height: 94vh; overflow: auto; padding: 22px 26px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 22px; }
.familia h2 { grid-column: 1 / -1; font-family: var(--madeira); font-weight: 400; font-size: clamp(30px, 5vw, 46px); margin: 0; text-align: center; letter-spacing: .03em; }
.familia .fama { grid-column: 1 / -1; text-align: center; font-family: var(--sc); margin-top: -10px; }
.herdeiro { border: 3px solid var(--tinta); padding: 14px; text-align: center; background: #f6edd7; }
.herdeiro canvas { width: 180px; height: 200px; display: block; margin: 0 auto; }
.herdeiro .nome { font-family: var(--madeira); font-size: 26px; }
.ancestrais { max-height: 52vh; overflow: auto; padding-right: 6px; }
.ancestrais h3, .familia h3 { font-family: var(--sc); margin: 0 0 8px; font-size: 18px; letter-spacing: .05em; border-bottom: 2px solid var(--tinta); }
.ancestral { border-left: 4px solid var(--tinta); padding: 6px 10px; margin: 0 0 10px; background: rgba(0,0,0,.035); }
.ancestral .quem { font-weight: 800; }
.ancestral .epit { font-style: italic; }
.ancestral pre { font-family: var(--serif); white-space: pre-wrap; margin: 6px 0 0; font-size: 14px; line-height: 1.3; }
.dons { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.dom { font-size: 13px; border: 2px solid var(--tinta); padding: 2px 8px; border-radius: 12px; background: #f6edd7; }
.dom.off { opacity: .35; }

/* criação */
.criar { width: min(1020px, 97vw); max-height: 96vh; overflow: auto; padding: 18px 22px; display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 20px; }
.criar h2 { grid-column: 1 / -1; font-family: var(--madeira); font-weight: 400; margin: 0; font-size: 34px; text-align: center; }
.criar .previa { text-align: center; }
.criar .previa canvas { width: 240px; height: 280px; border: 3px solid var(--tinta); background: var(--papel); }
.oficios { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.oficio { border: 3px solid var(--tinta); background: #f6edd7; padding: 8px; text-align: left; font-family: var(--serif); color: var(--tinta); font-size: 14px; line-height: 1.25; }
.oficio b { display: block; font-family: var(--madeira); font-weight: 400; font-size: 17px; margin-bottom: 2px; }
.oficio i { display: block; font-size: 12px; opacity: .8; margin-bottom: 3px; }
.oficio.on { background: var(--tinta); color: var(--papel); box-shadow: 4px 4px 0 var(--vermelho); }
.amostras { display: flex; flex-wrap: wrap; gap: 6px; }
.amostra { width: 34px; height: 34px; border: 3px solid var(--tinta); border-radius: 50%; }
.amostra.on { box-shadow: 0 0 0 3px var(--papel), 0 0 0 6px var(--vermelho); }
.trat { display: flex; gap: 6px; }
.trat button { flex: 1; }
.trat button.on { background: var(--tinta); color: var(--papel); }

/* ── HUD ─────────────────────────────────────────────────────────────────────────────────── */
.hud-eu { position: fixed; left: 12px; top: 12px; display: flex; gap: 10px; align-items: flex-start; pointer-events: none; }
.retrato { width: 76px; height: 76px; border: 3px solid var(--tinta); background: var(--papel); box-shadow: 3px 3px 0 var(--tinta); }
.barras { min-width: 220px; }
.barras .nome { font-family: var(--madeira); font-size: 18px; color: var(--papel); text-shadow: 2px 2px 0 var(--tinta), -1px -1px 0 var(--tinta), 1px -1px 0 var(--tinta), -1px 1px 0 var(--tinta); line-height: 1.1; }
.barras .nome small { font-family: var(--sc); font-size: 13px; }
.barra { position: relative; height: 16px; margin-top: 4px; border: 2px solid var(--tinta); background: var(--papel2); box-shadow: 2px 2px 0 rgba(0,0,0,.4); overflow: hidden; }
.barra > i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--vermelho); transition: width .15s; }
.barra > i.fantasma { background: #e8a08c; transition: width .6s .25s; }
.barra.folego > i { background: var(--ocre); }
.barra.escudo > i { background: var(--azul); }
.barra > span { position: absolute; inset: 0; text-align: center; font: 700 12px/12px var(--serif); color: var(--tinta); text-shadow: 0 0 3px var(--papel), 0 0 2px var(--papel); }
.barra.xp { height: 7px; margin-top: 3px; }
.barra.xp > i { background: var(--tinta); }
.efeitos { display: flex; gap: 4px; margin-top: 5px; flex-wrap: wrap; }
.efeito { font: 700 11px var(--serif); padding: 1px 6px; border: 2px solid var(--tinta); background: var(--papel); }
.efeito.ruim { background: #f0c9bf; }

.relogio { position: fixed; left: 50%; top: 8px; transform: translateX(-50%); text-align: center; pointer-events: none; }
.relogio canvas { width: 220px; height: 64px; display: block; }
.relogio .regiao { font-family: var(--sc); font-weight: 800; font-size: 14px; color: var(--papel); text-shadow: 1px 1px 0 var(--tinta), -1px -1px 0 var(--tinta), 1px -1px 0 var(--tinta), -1px 1px 0 var(--tinta); margin-top: -4px; letter-spacing: .05em; }
.chefe-barra { position: fixed; left: 50%; top: 86px; z-index: 5; transform: translateX(-50%); width: min(560px, 80vw); text-align: center; pointer-events: none; }
.chefe-barra .nome { font-family: var(--madeira); color: var(--papel); font-size: 22px; text-shadow: 2px 2px 0 var(--tinta), -1px -1px 0 var(--tinta), 1px -1px 0 var(--tinta), -1px 1px 0 var(--tinta); }
.chefe-barra .barra { height: 18px; }

.mini { position: fixed; right: 12px; top: 12px; width: 190px; pointer-events: none; }
.mini canvas { width: 190px; height: 190px; display: block; border: 3px solid var(--tinta); box-shadow: 3px 3px 0 var(--tinta); background: var(--papel); }
.mini .online { font: 700 12px var(--serif); color: var(--papel); text-shadow: 1px 1px 0 var(--tinta), -1px -1px 0 var(--tinta); text-align: right; margin-top: 3px; }
.causos { position: fixed; right: 12px; top: 232px; width: 250px; pointer-events: none; }
.causo { background: rgba(239, 227, 198, .9); border: 2px solid var(--tinta); padding: 6px 9px; margin-bottom: 6px; font-size: 13.5px; line-height: 1.25; box-shadow: 2px 2px 0 rgba(0,0,0,.35); }
.causo b { font-family: var(--sc); font-size: 14px; display: block; }
.causo .pronto { color: var(--verde); font-weight: 800; }
.causo .passo.ok { text-decoration: line-through; opacity: .6; }

.barra-acoes { position: fixed; left: 50%; bottom: 12px; transform: translateX(-50%); display: flex; gap: 6px; align-items: flex-end; }
.slot { position: relative; width: 62px; height: 62px; border: 3px solid var(--tinta); background: var(--papel); box-shadow: 3px 3px 0 var(--tinta); }
.slot canvas { width: 100%; height: 100%; display: block; }
.slot .tecla { position: absolute; left: 2px; top: 1px; font: 800 12px var(--sc); color: var(--tinta); text-shadow: 0 0 2px var(--papel), 0 0 2px var(--papel); }
.slot .cd { position: absolute; inset: 0; background: conic-gradient(rgba(28,22,17,.72) var(--p, 0%), transparent 0); }
.slot .cd-num { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font: 800 20px var(--madeira); color: var(--papel); text-shadow: 2px 2px 0 var(--tinta); }
.slot.semfolego { filter: grayscale(.8) brightness(.8); }
.slot.peq { width: 46px; height: 46px; }
.slot .qtd { position: absolute; right: 3px; bottom: 1px; font: 800 13px var(--serif); text-shadow: 0 0 2px var(--papel), 0 0 2px var(--papel); }
.slot.flash { animation: flash .25s; }
@keyframes flash { from { box-shadow: 0 0 0 4px var(--amarelo), 3px 3px 0 var(--tinta); } }
.folego-mini { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%); width: 360px; height: 6px; border: 2px solid var(--tinta); background: var(--papel2); pointer-events: none; }
.folego-mini > i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--ocre); }

.prompt { position: fixed; left: 50%; bottom: 104px; transform: translateX(-50%); background: var(--papel); border: 2px solid var(--tinta); padding: 4px 12px; font-weight: 600; box-shadow: 2px 2px 0 var(--tinta); pointer-events: none; white-space: nowrap; }
.prompt kbd { font-family: var(--sc); font-weight: 800; background: var(--tinta); color: var(--papel); padding: 0 6px; border-radius: 2px; margin-right: 6px; }
.progresso { position: fixed; left: 50%; bottom: 140px; transform: translateX(-50%); width: 200px; height: 12px; border: 2px solid var(--tinta); background: var(--papel); pointer-events: none; }
.progresso > i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--verde); }

.chat { position: fixed; left: 12px; bottom: 12px; width: min(420px, 42vw); pointer-events: none; }
.chat .linhas { max-height: 190px; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; font-size: 14px; line-height: 1.3; }
.chat .linha { background: rgba(239, 227, 198, .82); padding: 2px 8px; margin-top: 2px; border-left: 3px solid var(--tinta); transition: opacity 1s; }
.chat .linha.sistema { border-left-color: var(--ocre); font-style: italic; }
.chat .linha.sertao { border-left-color: var(--azul); }
.chat .linha.verso { border-left-color: var(--vermelho); }
.chat .linha .de { font-weight: 800; }
.chat .linha.apaga { opacity: 0; }
.chat input { pointer-events: auto; margin-top: 4px; width: 100%; font-size: 15px; padding: 5px 8px; border: 2px solid var(--tinta); background: var(--papel); display: none; }
.chat.digitando input { display: block; }
.chat.digitando .linha.apaga { opacity: 1; }

.avisos { position: fixed; left: 50%; top: 96px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: none; width: min(640px, 92vw); }
.aviso { background: var(--papel); border: 3px solid var(--tinta); padding: 6px 14px; font-weight: 600; text-align: center; box-shadow: 3px 3px 0 var(--tinta); animation: entra .25s ease-out; }
.aviso.anuncio { font-family: var(--sc); font-size: 18px; background: var(--tinta); color: var(--papel); box-shadow: 4px 4px 0 var(--vermelho); }
.aviso.verso { font-style: italic; }
.aviso.sai { animation: sai .4s ease-in forwards; }
@keyframes entra { from { transform: translateY(-12px) scale(.96); opacity: 0; } }
@keyframes sai { to { transform: translateY(-10px); opacity: 0; } }

.faixa-regiao { position: fixed; left: 50%; top: 34%; transform: translate(-50%, -50%); text-align: center; pointer-events: none; animation: faixa 4.2s ease forwards; }
.faixa-regiao .t { font-family: var(--madeira); font-size: clamp(36px, 6vw, 72px); color: var(--papel); text-shadow: 4px 4px 0 var(--tinta), -2px -2px 0 var(--tinta), 2px -2px 0 var(--tinta), -2px 2px 0 var(--tinta); letter-spacing: .05em; }
.faixa-regiao .s { font-family: var(--sc); font-size: clamp(16px, 2vw, 22px); color: var(--tinta); background: var(--papel); display: inline-block; padding: 2px 14px; border: 2px solid var(--tinta); margin-top: 4px; }
@keyframes faixa { 0% { opacity: 0; transform: translate(-50%, -40%) scale(.9); } 12% { opacity: 1; transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -56%); } }

/* ── janelas ─────────────────────────────────────────────────────────────────────────────── */
.janela { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(720px, 94vw); max-height: 86vh; display: flex; flex-direction: column; z-index: 20; }
.janela .cabeca { display: flex; align-items: center; gap: 10px; padding: 10px 14px 6px; }
.janela .cabeca h3 { margin: 0; flex: 1; font-family: var(--madeira); font-weight: 400; font-size: 24px; letter-spacing: .03em; }
.janela .fechar { background: var(--tinta); color: var(--papel); border: 0; width: 32px; height: 32px; font-size: 18px; line-height: 1; font-family: var(--madeira); }
.janela .corpo { padding: 8px 16px 16px; overflow: auto; }
.grade-itens { display: grid; grid-template-columns: repeat(auto-fill, 54px); gap: 6px; }
.item { position: relative; width: 54px; height: 54px; border: 2px solid var(--tinta); background: #f6edd7; cursor: pointer; }
.item canvas { width: 100%; height: 100%; display: block; }
.item.vazio { background: rgba(0,0,0,.05); border-style: dashed; cursor: default; }
.item .n { position: absolute; right: 2px; bottom: 0; font: 800 12px var(--serif); text-shadow: 0 0 2px #fff, 0 0 2px #fff; }
.item.r-bom { box-shadow: inset 0 0 0 3px var(--verde); }
.item.r-raro { box-shadow: inset 0 0 0 3px var(--azul); }
.item.r-lendario { box-shadow: inset 0 0 0 3px var(--vermelho), 0 0 8px var(--ouro); }
.item.sel { outline: 3px solid var(--ocre); outline-offset: 1px; }
.equip { display: grid; grid-template-columns: repeat(5, 54px); gap: 6px; margin-bottom: 10px; }
.equip .item::after { content: attr(data-slot); position: absolute; left: 0; right: 0; top: -15px; text-align: center; font: 700 10px var(--sc); }
.detalhe { margin-top: 12px; border-top: 2px solid var(--tinta); padding-top: 8px; min-height: 92px; font-size: 14.5px; }
.detalhe .nome { font-family: var(--sc); font-weight: 800; font-size: 17px; }
.detalhe .r-bom { color: var(--verde); } .detalhe .r-raro { color: var(--azul); } .detalhe .r-lendario { color: var(--vermelho); }
.detalhe ul { margin: 4px 0; padding-left: 18px; }
.detalhe .acoes { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.linha-loja { display: flex; align-items: center; gap: 10px; padding: 5px 0; border-bottom: 1px dashed rgba(0,0,0,.3); }
.linha-loja .item { flex: none; }
.linha-loja .nome { flex: 1; }
.linha-loja .preco { font-weight: 800; }
.reis { font-weight: 800; color: #7a5a12; }
.stat { display: flex; justify-content: space-between; border-bottom: 1px dotted rgba(0,0,0,.3); padding: 2px 0; }

/* conversa */
.dialogo { position: fixed; left: 50%; bottom: 100px; transform: translateX(-50%); width: min(760px, 94vw); display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 12px; padding: 14px 16px; z-index: 15; }
.dialogo canvas { width: 110px; height: 128px; border: 3px solid var(--tinta); background: var(--papel2); }
.dialogo .quem { font-family: var(--madeira); font-size: 22px; }
.dialogo .quem small { font-family: var(--sc); font-size: 14px; margin-left: 6px; }
.dialogo .fala { font-size: 17.5px; line-height: 1.4; min-height: 3em; white-space: pre-wrap; }
.dialogo .ops { display: flex; flex-direction: column; gap: 5px; margin-top: 10px; }
.dialogo .op { text-align: left; font-family: var(--serif); font-size: 16px; font-weight: 600; background: transparent; border: 2px solid var(--tinta); padding: 5px 10px; color: var(--tinta); }
.dialogo .op:hover, .dialogo .op.foco { background: var(--tinta); color: var(--papel); }
.dialogo .op .k { font-family: var(--sc); opacity: .7; margin-right: 8px; }
.dialogo .op.novo::before { content: '! '; color: var(--vermelho); font-weight: 800; }
.dialogo .op.pronto::before { content: '✔ '; color: var(--verde); font-weight: 800; }

/* folheto (livro de versos) */
.folheto .corpo { columns: 2 280px; column-gap: 26px; }
.estrofe { break-inside: avoid; margin: 0 0 18px; padding: 10px 12px; border: 2px solid var(--tinta); background: #f6edd7; }
.estrofe canvas { width: 100%; height: 90px; display: block; border-bottom: 2px solid var(--tinta); margin-bottom: 6px; }
.estrofe pre { font-family: var(--serif); font-size: 15.5px; line-height: 1.35; margin: 0; white-space: pre-wrap; }
.estrofe .ass { font-family: var(--sc); font-size: 12px; margin-top: 6px; opacity: .75; }
.estrofe.primeiro { box-shadow: inset 0 0 0 3px var(--ouro); }

/* morte */
.morte { background: var(--papel) var(--grao); }
.morte .conteudo { width: min(720px, 94vw); text-align: center; }
.morte canvas.prensa { width: min(560px, 90vw); height: 300px; display: block; margin: 0 auto; }
.morte pre { font-family: var(--serif); font-size: clamp(18px, 2.4vw, 24px); line-height: 1.4; white-space: pre-wrap; margin: 12px auto; min-height: 9em; }
.morte .lugar { font-family: var(--sc); }

/* toque */
.toque { position: fixed; inset: 0; pointer-events: none; display: none; }
body.touch .toque { display: block; }
.joystick { position: fixed; left: 24px; bottom: 24px; width: 140px; height: 140px; border-radius: 50%; border: 3px solid rgba(28,22,17,.55); background: rgba(239,227,198,.25); pointer-events: auto; }
.joystick i { position: absolute; left: 50%; top: 50%; width: 56px; height: 56px; margin: -28px; border-radius: 50%; background: rgba(28,22,17,.65); }
.botoes-toque { position: fixed; right: 14px; bottom: 14px; display: grid; grid-template-columns: repeat(4, 54px); gap: 7px; pointer-events: auto; }
.botoes-toque button { width: 54px; height: 54px; border-radius: 50%; border: 3px solid var(--tinta); background: rgba(239,227,198,.88); font: 800 16px var(--madeira); color: var(--tinta); }
.botoes-toque button.grande { background: var(--tinta); color: var(--papel); }
.menu-toque { position: fixed; right: 14px; top: 150px; width: 46px; height: 46px; border-radius: 50%; border: 3px solid var(--tinta); background: rgba(239,227,198,.9); font: 800 18px var(--madeira); pointer-events: auto; display: none; }
body.touch .menu-toque { display: block; }
body.touch .mini { width: 120px; } body.touch .mini canvas { width: 120px; height: 120px; }
body.touch .mini .online { display: none; }
body.touch .retrato { width: 52px; height: 52px; }
body.touch .barras { min-width: 170px; }
body.touch .folego-mini, body.touch .relogio { display: none; }
body.touch .prompt { bottom: 16px; }
.dica-tutor { position: fixed; left: 12px; top: 128px; max-width: 330px; text-align: left; pointer-events: auto; font-size: 15px; }
body.touch .dica-tutor { top: 92px; max-width: 290px; font-size: 13.5px; }
@media (max-height: 520px) {
  .aviso { font-size: 13px; padding: 4px 10px; }
  .avisos { top: 70px; }
  .dialogo { bottom: 8px; grid-template-columns: 80px minmax(0, 1fr); padding: 10px 12px; }
  .dialogo canvas { width: 80px; height: 94px; }
  .dialogo .fala { font-size: 15px; }
  .janela { max-height: 94vh; }
}
body.touch .barra-acoes { display: none; }
body.touch .chat { width: 60vw; bottom: 180px; }
body.touch .causos { display: none; }

@media (max-width: 760px) {
  .mini { width: 120px; } .mini canvas { width: 120px; height: 120px; }
  .causos { top: 160px; width: 190px; }
  .barras { min-width: 150px; }
  .retrato { width: 56px; height: 56px; }
  .familia, .criar { grid-template-columns: minmax(0, 1fr); }
  .relogio { display: none; }
  .slot { width: 50px; height: 50px; }
}

body.chefe-on .avisos { top: 150px; }
body.chefe-on .faixa-regiao { display: none; }
