/* Thaloria: same palette as the Wyrmfell engine (motor/mundo.js) and the videos */
@font-face { font-family: "Silk"; src: url(fonts/Silkscreen-Bold.ttf) format("truetype"); font-display: swap; }
@font-face { font-family: "SilkR"; src: url(fonts/Silkscreen-Regular.ttf) format("truetype"); font-display: swap; }
@font-face { font-family: "Open Sans"; src: url(fonts/OpenSans-latin.woff2) format("woff2"); font-weight: 300 800; font-display: swap; }

:root {
  --noite: #0d1611;        /* forest at night, page background */
  --mata: #162b20;
  --mata-2: #22402c;
  --ouro: #ffcf4a;
  --ouro-2: #e0a82a;
  --tinta: #2a1a0e;        /* ink on parchment */
  --tinta-2: #5a3a22;
  --madeira: #865a33;
  --madeira-esc: #3e2414;
  --borda: #120c06;        /* sprite outline */
  --perg: #eadbb4;         /* parchment */
  --perg-2: #dccb9e;
  --perg-3: #f3e8c8;
  --texto: #e8e2cc;
  --texto-2: #b9c4b4;
  --brasa: #ff6a3a;
  --px: 4px;               /* "pixel" for borders */
  --perg-tex: none;        /* parchment texture, generated in app.js */
  --sombra: 0 10px 24px rgba(0, 0, 0, .45);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; overflow-x: clip; background: var(--noite); color: var(--texto);
  font: 16px/1.6 "Open Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}
::selection { background: var(--ouro); color: var(--borda); }
* { scrollbar-color: var(--madeira) var(--noite); }
a { color: var(--ouro); text-underline-offset: .25em; text-decoration-thickness: 2px; }
a:hover { color: #fff1b8; }
:focus-visible { outline: var(--px) solid var(--ouro); outline-offset: 3px; }
h1, h2, h3, .botao, .abas a, .brand, .where, .tag-mundo, [data-relogio], .selo, .qa b, .rumor-dia { -webkit-font-smoothing: none; }
h1, h2, h3 { font-family: "Silk", monospace; font-weight: 400; line-height: 1.1; margin: 0; text-wrap: balance; letter-spacing: .01em; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
input { font: inherit; caret-color: var(--tinta); }

/* ---------------------------------------------------------------- top bar */
.bar {
  position: fixed; inset: 0 0 auto; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: max(10px, env(safe-area-inset-top)) 18px 10px; background: rgba(10, 16, 12, .86);
  border-bottom: var(--px) solid var(--mata-2); backdrop-filter: blur(6px);
}
.brand { font-family: "Silk"; font-size: 20px; color: var(--ouro); text-decoration: none; letter-spacing: .06em; }
.where { font-size: 11px; color: var(--texto-2); text-transform: uppercase; white-space: nowrap; }

/* ---------------------------------------------------------------- live village */
.vila { position: relative; height: 100svh; min-height: 560px; overflow: hidden; background: #0b140d; }
#mundo { position: absolute; inset: 0; width: 100%; height: 100%; image-rendering: pixelated; touch-action: pan-y; cursor: pointer; }
.ao-vivo {
  position: absolute; top: calc(max(10px, env(safe-area-inset-top)) + 58px); left: 16px; margin: 0; z-index: 3;
  display: inline-flex; align-items: center; gap: 10px; padding: 6px 12px; font: 11px/1 "Silk"; max-width: calc(100% - 32px); text-transform: uppercase; letter-spacing: .08em;
  color: #ffd2c2; background: rgba(18, 12, 6, .82); border: 2px solid #e2502a;
}
.ponto { width: 8px; height: 8px; background: #ff5030; animation: pulso 1.6s steps(2) infinite; }
@keyframes pulso { 50% { opacity: .25; } }
.tag-mundo {
  position: absolute; z-index: 4; margin: 0; transform: translate(-50%, calc(-100% - 8px)); pointer-events: none;
  font: 15px/1 "Silk"; color: var(--ouro); background: #1e140a; padding: 9px 12px 8px; white-space: nowrap; text-transform: uppercase;
  border: 3px solid var(--ouro); outline: 3px solid var(--borda);
}
.tag-mundo::after { content: ""; position: absolute; left: 50%; top: 100%; width: 10px; height: 6px; margin: 3px 0 0 -5px; background: var(--borda); }

.busca { position: absolute; left: 0; right: 0; bottom: 0; z-index: 5; padding: 18px 16px max(18px, env(safe-area-inset-bottom)); background: linear-gradient(to top, rgba(10, 16, 12, .95) 55%, rgba(10, 16, 12, 0)); }
.busca input, #filtro {
  display: block; width: 100%; max-width: 560px; margin: 0 auto; padding: 16px 18px; font-size: 16px; color: var(--tinta);
  background: var(--perg-3) var(--perg-tex); border: var(--px) solid var(--madeira-esc); outline: var(--px) solid var(--borda); border-radius: 0;
  -webkit-appearance: none; appearance: none;
}
.busca input::placeholder, #filtro::placeholder { color: #7d6a50; }
.busca input:focus-visible, #filtro:focus-visible { outline-color: var(--ouro); }
.dica { margin: 12px auto 0; text-align: center; font-size: 12px; color: var(--texto-2); text-transform: uppercase; }
.sugestoes {
  position: absolute; left: 16px; right: 16px; bottom: calc(100% - 12px); max-width: 560px; margin: 0 auto; padding: 0; list-style: none;
  background: var(--perg) var(--perg-tex); border: var(--px) solid var(--madeira-esc); outline: var(--px) solid var(--borda); box-shadow: var(--sombra);
  max-height: 46svh; overflow: auto;
}
.sugestoes li { display: flex; align-items: center; gap: 12px; padding: 8px 14px; cursor: pointer; color: var(--tinta); }
.sugestoes li + li { border-top: 2px solid var(--perg-2); }
.sugestoes li[aria-selected="true"], .sugestoes li:hover { background: #fff3cf; }
.sugestoes img { width: 30px; height: 36px; image-rendering: pixelated; flex: none; }
.sugestoes b { font: 15px/1.2 "Silk"; text-transform: uppercase; }
.sugestoes small { display: block; font-size: 12px; color: var(--tinta-2); }
.sugestoes .nada { cursor: default; font-size: 13px; line-height: 1.5; }

/* the sheet: parchment that rises from the bottom */
.ficha {
  position: absolute; z-index: 6; left: 12px; right: 12px; bottom: 12px; max-width: 560px; margin: 0 auto; padding: 22px 20px 20px;
  color: var(--tinta); background: var(--perg) var(--perg-tex); border: var(--px) solid var(--madeira-esc); outline: var(--px) solid var(--borda);
  box-shadow: var(--sombra); animation: sobe .42s cubic-bezier(.16, 1, .3, 1);
}
.ficha[hidden] { display: none; }
@keyframes sobe { from { transform: translateY(40px); opacity: 0; clip-path: inset(30% 0 0 0); } to { transform: none; opacity: 1; clip-path: inset(0); } }
@media (prefers-reduced-motion: reduce) { .ficha { animation: none; } }
.fechar { position: absolute; top: 8px; right: 8px; width: 44px; height: 44px; display: grid; place-items: center; color: var(--tinta-2); background: none; border: 0; cursor: pointer; }
.fechar:hover { color: var(--tinta); }
.ficha-topo { display: flex; gap: 18px; align-items: center; padding-right: 44px; }
.retrato { width: 90px; height: 108px; image-rendering: pixelated; flex: none; }
.ficha-nome { font-size: 26px; text-transform: uppercase; overflow-wrap: break-word; }
.ficha-nome.longo { font-size: 20px; }
.ficha-oficio { margin: 6px 0 0; font: 15px/1.2 "Silk"; color: var(--madeira); text-transform: uppercase; }
.ficha-ig { margin: 6px 0 0; font-size: 14px; color: var(--tinta-2); }
.ficha-sobre { margin: 18px 0 0; font-size: 15px; line-height: 1.55; }
.ficha-sobre:empty { display: none; }
.ficha-cena { margin-top: 16px; padding-top: 14px; border-top: 3px solid #c9b48a; }
.ficha-cena[hidden] { display: none; }
.ficha-cena h3 { font-size: 12px; color: var(--madeira); text-transform: uppercase; letter-spacing: .1em; }
.ficha-cena p { margin: 6px 0 0; font: 600 15px/1.45 "Open Sans", sans-serif; }

/* ---------------------------------------------------------------- register */
.registro { padding: 72px 12px 64px; background: #16120c; }
.livro {
  max-width: 760px; margin: 0 auto; padding: 40px 18px 28px; color: var(--tinta);
  background: var(--perg) var(--perg-tex); border: 6px solid var(--madeira-esc); outline: var(--px) solid var(--borda); box-shadow: var(--sombra);
}
.livro h2 { text-align: center; font-size: clamp(34px, 9vw, 56px); color: #5a2414; text-transform: uppercase; }
.livro h2 span { display: block; margin-top: 8px; font-size: .5em; color: var(--madeira); }
.conta { text-align: center; margin: 14px 0 18px; font-size: 13px; color: var(--tinta-2); text-transform: uppercase; }
#filtro { margin-bottom: 18px; }
.lista { list-style: none; margin: 0; padding: 0; }
.lista > li { border-top: 2px solid #d2bd8c; }
.lista > li:nth-child(odd) { background: rgba(255, 248, 225, .45); }
.linha { width: 100%; display: grid; grid-template-columns: 26px 40px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 10px 8px; background: none; border: 0; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.linha:hover { background: rgba(255, 243, 207, .8); }
.linha .num { font: 13px "Silk"; color: #8a7656; text-align: right; font-variant-numeric: tabular-nums; }
.linha img { width: 40px; height: 48px; image-rendering: pixelated; }
.linha b { display: block; font: 16px/1.15 "Silk"; text-transform: uppercase; overflow-wrap: anywhere; }
.linha small { display: block; margin-top: 3px; font-size: 12px; overflow-wrap: anywhere; color: var(--tinta-2); text-transform: uppercase; }
.selo { font: 10px/1 "Silk"; color: var(--perg-3); background: #5a2414; padding: 6px 8px; text-transform: uppercase; white-space: nowrap; }
.detalhe { padding: 0 12px 16px 86px; font-size: 14px; line-height: 1.55; }
.detalhe p { margin: 0 0 10px; }
.detalhe .cena { font: 13px/1.35 "Silk"; color: #5a2414; }
.ver { font: 13px "Silk"; text-transform: uppercase; color: var(--tinta); background: var(--ouro); border: 3px solid var(--borda); padding: 10px 14px; cursor: pointer; }
.ver:hover { background: #ffe07a; }
.vazio { text-align: center; padding: 22px 8px 6px; font-size: 14px; }
.vazio a { color: #5a2414; }

/* ---------------------------------------------------------------- days */
.dias, .regioes { padding: 80px 18px; max-width: 980px; margin: 0 auto; }
.dias h2, .regioes h2, .entrar h2 { font-size: clamp(32px, 8vw, 52px); color: var(--ouro); text-transform: uppercase; }
.lead { margin: 14px 0 32px; color: var(--texto-2); font-size: 15px; max-width: 46ch; }
.dias-lista { list-style: none; margin: 0; padding: 0; display: grid; gap: 28px; }
@media (min-width: 720px) { .dias-lista { grid-template-columns: 1fr 1fr; } }
.dias-lista a { display: block; text-decoration: none; color: var(--texto); }
.dias-lista img { display: block; width: 100%; height: auto; aspect-ratio: 1; image-rendering: pixelated; border: var(--px) solid var(--mata-2); outline: var(--px) solid var(--borda); transition: transform .5s cubic-bezier(.16, 1, .3, 1), filter .5s; }
.dias-lista a:hover img { transform: translateY(-4px); filter: brightness(1.12); }
.dia-n { display: block; margin-top: 16px; font: 26px "Silk"; color: var(--ouro); text-transform: uppercase; }
.dia-t { display: block; margin-top: 6px; font-size: 14px; color: var(--texto-2); }

/* ---------------------------------------------------------------- how to move in: a notice nailed to wood */
.entrar { padding: 40px 12px 80px; background: #3e2414 var(--madeira-tex) repeat; background-size: 384px 128px; image-rendering: pixelated; }
.aviso {
  position: relative; max-width: 640px; margin: 0 auto; padding: 44px 24px 34px; color: var(--tinta);
  background: var(--perg) var(--perg-tex); outline: var(--px) solid var(--borda); box-shadow: var(--sombra); transform: rotate(-.6deg);
}
.aviso::before, .aviso::after { content: ""; position: absolute; top: 14px; width: 10px; height: 10px; background: #2a2c36; box-shadow: inset 3px 3px #9aa0ad; }
.aviso::before { left: 14px; } .aviso::after { right: 14px; }
.entrar .aviso h2 { color: #5a2414; text-align: center; }
.passos { margin: 26px 0 0; padding: 0; list-style: none; counter-reset: p; }
.passos li { counter-increment: p; position: relative; padding: 14px 0 14px 54px; font-size: 15px; line-height: 1.5; border-top: 2px solid #d2bd8c; }
.passos li::before { content: counter(p); position: absolute; left: 6px; top: 12px; width: 32px; height: 32px; display: grid; place-items: center; font: 16px "Silk"; color: var(--perg-3); background: #5a2414; }
.passos strong { font-family: "Silk"; font-weight: 400; }
.passos a { color: #5a2414; }
.exemplo { margin: 18px 0 26px; padding: 14px 16px; background: rgba(255, 248, 225, .6); font-size: 15px; }
.exemplo span { display: block; font: 12px "Silk"; color: var(--madeira); text-transform: uppercase; margin-bottom: 4px; }
.botao { display: block; text-align: center; padding: 18px 20px 16px; font: 20px "Silk"; text-transform: uppercase; text-decoration: none; color: var(--tinta); background: var(--ouro); border: var(--px) solid var(--borda); box-shadow: inset 0 -8px 0 var(--ouro-2); transition: transform .2s; }
.botao:hover { color: var(--tinta); background: #ffe07a; transform: translateY(-2px); }

/* ---------------------------------------------------------------- regions of Thaloria */
.mapa { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.mapa li { min-width: 0; padding: 4px; aspect-ratio: 3 / 4; display: grid; place-content: center; text-align: center; gap: 6px; font: 26px "Silk"; color: #7d8a94; text-transform: uppercase;
  background: #18211d; border: var(--px) solid #24302a; position: relative; overflow: hidden; }
.mapa li.nevoa canvas { position: absolute; inset: 0; width: 100%; height: 100%; image-rendering: pixelated; }
.mapa li.nevoa span { position: relative; font: clamp(10px, 2.4vw, 13px) "Silk"; color: #c8d0dc; text-shadow: 0 2px 0 var(--borda), 0 -2px 0 var(--borda), 2px 0 0 var(--borda), -2px 0 0 var(--borda); }
.mapa li.achada { color: var(--ouro); font-size: clamp(11px, 2.6vw, 18px); background: url(img/day1.webp) center / cover; border-color: var(--ouro); position: relative; }
.mapa li.achada span, .mapa li.achada small { position: relative; padding: 0 4px; text-shadow: 0 2px 0 var(--borda), 0 -2px 0 var(--borda), 2px 0 0 var(--borda), -2px 0 0 var(--borda); }
.mapa li.achada::before { content: ""; position: absolute; inset: 0; background: rgba(10, 16, 12, .45); }
.mapa small { font: 10px/1.3 "SilkR"; color: var(--texto); }

.rodape { padding: 36px 18px max(36px, env(safe-area-inset-bottom)); border-top: var(--px) solid var(--mata-2); color: var(--texto-2); font-size: 13px; text-align: center; }
.rodape p { margin: 6px auto; max-width: 60ch; }

@media (min-width: 900px) {
  .bar { padding: 14px 32px; }
  .brand { font-size: 26px; }
  .where { font-size: 14px; }
  .ao-vivo { left: 32px; top: 86px; }
  .ficha { left: auto; right: 32px; bottom: 190px; width: 420px; }
  .linha { padding: 12px 18px; }
}

@media (max-width: 420px) { .linha { gap: 9px; padding: 9px 4px; } .detalhe { padding-left: 12px; } }
@media (min-width: 900px) { .linha { grid-template-columns: 34px 46px minmax(0, 1fr) auto; } .linha img { width: 45px; height: 54px; } .detalhe { padding-left: 104px; } }
input[type=search]::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
.agora { margin: 8px 0 0; font-size: 13px; color: var(--tinta-2); }
.agora:empty { display: none; }
.lista.curta > li:nth-child(n+13) { display: none; }
.mais { display: block; width: 100%; margin: 18px 0 4px; padding: 16px; font: 16px "Silk"; text-transform: uppercase; color: var(--perg-3); background: #5a2414; border: var(--px) solid var(--borda); cursor: pointer; }
.mais:hover { background: #6e2e1a; }
.mais[hidden] { display: none; }
.busca-rotulo { display: table; margin: 0 auto 10px; padding: 7px 12px 6px; font: 15px "Silk"; color: var(--ouro); text-transform: uppercase; letter-spacing: .06em; background: rgba(18, 12, 6, .88); }
@media (min-width: 900px) { .busca-rotulo { font-size: 18px; } }
.linha .ig { color: var(--tinta-2); }
.linha small.teve-cena { color: #5a2414; font-family: "Silk"; font-size: 11px; margin-top: 5px; }
.legenda { text-align: center; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 10px; margin: -10px 0 20px; font-size: 12px; color: var(--tinta-2); }
.detalhe .entrou { font-size: 13px; color: var(--tinta-2); }

/* ---------------------------------------------------------------- the first winter */
.inverno { padding: 72px 16px 64px; background: #10181f; border-top: var(--px) solid #24323c; border-bottom: var(--px) solid #24323c; }
.inverno-in { max-width: 760px; margin: 0 auto; }
.inverno h2 { font-size: clamp(30px, 8vw, 50px); color: #e9f0ff; text-transform: uppercase; }
.inverno .lead { color: #b9c6d4; max-width: 52ch; }
.sub { margin: 34px 0 14px; font-size: 14px; color: var(--ouro); text-transform: uppercase; letter-spacing: .08em; }
.previsao { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.previsao li { display: grid; justify-items: center; gap: 6px; padding: 10px 2px; background: #18232c; border: 2px solid #24323c; text-align: center; }
.previsao li:first-child { border-color: var(--ouro); }
.previsao img { width: 36px; height: 36px; image-rendering: pixelated; }
.pd { font: 10px/1.1 "Silk"; color: #c8d0dc; text-transform: uppercase; }
.pt { font-size: 11px; color: #e9f0ff; font-variant-numeric: tabular-nums; white-space: nowrap; }
.estoques { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.estoques li { padding: 16px; background: #18232c; border: 2px solid #24323c; }
.estoques li.risco { border-color: #8a3a24; }
.et { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.et b { font: 18px "Silk"; color: #e9f0ff; text-transform: uppercase; font-weight: 400; }
.et span { font-size: 13px; color: #c8d0dc; font-variant-numeric: tabular-nums; }
.estoques p { margin: 10px 0 0; font-size: 14px; color: #b9c6d4; }
.linha-tempo { position: relative; height: 14px; margin-top: 12px; background: #0b1116; border: 2px solid #2c3c48; }
.linha-tempo i { position: absolute; top: 0; bottom: 0; }
.linha-tempo .cheio { left: 0; background: var(--ouro); box-shadow: inset 0 -4px 0 var(--ouro-2); }
.linha-tempo .falta { right: 0; background: repeating-linear-gradient(90deg, #5a2414 0 6px, #3e1a10 6px 12px); }
.linha-tempo .agora { width: 3px; margin-left: -1px; top: -6px; bottom: -6px; background: #e9f0ff; }
.camas { display: flex; flex-wrap: wrap; gap: 3px; margin-top: 12px; }
.camas i { width: 9px; height: 9px; background: #3a2018; }
.camas i.ok { background: var(--ouro); }
.pedido { margin: 22px 0 0; padding: 14px 16px; font-size: 15px; color: #e9f0ff; background: #1e2a33; border-left: 0; outline: 2px solid #3a4c5a; }
.pedido b { font-family: "Silk"; font-weight: 400; color: var(--ouro); }
.rumores { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.rumores li { padding: 12px 14px; font-size: 14px; line-height: 1.55; color: #d8dfe8; background: #18232c; }
.nota-clima { margin: 30px 0 0; font-size: 12px; color: #8a98a6; }
@media (max-width: 560px) { .previsao { grid-template-columns: repeat(4, minmax(0, 1fr)); } .previsao li:first-child { grid-column: span 1; } }

.populacao { max-width: 560px; margin: 0 auto 10px; text-align: center; font-size: 13px; color: var(--texto); text-shadow: 0 2px 0 var(--borda); }
.populacao b { font: 16px "Silk"; font-weight: 400; color: var(--ouro); }
.marco, .decisao { margin-top: 8px; }
.marco p { margin: 0; font-size: 15px; color: #e9f0ff; }
.marco-barra { height: 14px; margin: 12px 0 8px; background: #0b1116; border: 2px solid #2c3c48; }
.marco-barra i { display: block; height: 100%; background: #9ab8d8; box-shadow: inset 0 -4px 0 #6e8eae; }
.marco-num { font-size: 12px !important; color: #b9c6d4 !important; font-variant-numeric: tabular-nums; }
.pergunta { margin: 0 0 12px; font: 18px/1.3 "Silk"; color: #e9f0ff; }
.opcoes { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.opcoes li { padding: 14px; background: #18232c; border: 2px solid var(--ouro); }
.opcoes b { display: block; font: 22px "Silk"; font-weight: 400; color: var(--ouro); }
.opcoes span { display: block; margin-top: 6px; font-size: 13px; color: #c8d0dc; }
.como { margin: 12px 0 0; font-size: 13px; color: #b9c6d4; }
.decididas { list-style: none; margin: 14px 0 0; padding: 0; font-size: 13px; color: #b9c6d4; }
.decididas:empty { display: none; }

/* ================================================================ tabs (phase 1.1): one section at a time */
:root { --nav: 62px; }
.painel[hidden] { display: none !important; }
.painel:not(.vila) { min-height: 100svh; padding-top: calc(76px + env(safe-area-inset-top)); padding-bottom: calc(var(--nav) + 40px + env(safe-area-inset-bottom)); }
.vila { height: 100svh; }
.abas { position: fixed; z-index: 30; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(5, 1fr);
  height: calc(var(--nav) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: rgba(10, 16, 12, .96); border-top: var(--px) solid var(--mata-2); }
.abas a { display: grid; place-content: center; justify-items: center; gap: 5px; text-decoration: none; color: #8fa094; font: 10px "Silk"; text-transform: uppercase; letter-spacing: .04em; }
.abas svg { width: 22px; height: 22px; }
.abas a[aria-current="page"] { color: var(--ouro); background: rgba(255, 207, 74, .08); box-shadow: inset 0 3px 0 var(--ouro); }
.abas a:hover { color: #fff1b8; }
.busca { bottom: calc(var(--nav) + env(safe-area-inset-bottom)); padding-bottom: 14px; }
.ficha { bottom: calc(var(--nav) + 12px + env(safe-area-inset-bottom)); }
.sugestoes { max-height: 40svh; }
@media (min-width: 900px) {
  :root { --nav: 0px; }
  .abas { top: 0; bottom: auto; left: auto; right: 24px; height: 62px; padding: 0; grid-template-columns: repeat(5, auto); gap: 4px; background: none; border: 0; }
  .abas a { grid-auto-flow: column; gap: 8px; padding: 0 14px; font-size: 12px; }
  .abas a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--ouro); background: none; }
  .where { display: none; }
  .busca { bottom: 0; }
  .ficha { bottom: 190px; }
}

/* ---------------------------------------------------------------- winter: less text, more drawing */
.inverno { border: 0; }
.inverno h2 { margin-bottom: 10px; }
.calendario { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin: 0 0 24px; }
.calendario b { font: 20px "Silk"; font-weight: 400; color: var(--ouro); }
.calendario span { font-size: 13px; color: #b9c6d4; }
.estoques { margin-top: 22px; gap: 12px; }
.estoques li { display: grid; grid-template-columns: 64px 1fr; gap: 14px; align-items: center; padding: 14px; }
.estoques .ico { width: 64px; height: auto; image-rendering: pixelated; justify-self: center; }
.ec { min-width: 0; }
.ate { margin: 8px 0 0 !important; font-size: 12px !important; color: #c8d0dc !important; }
.estoques li.risco .ate { color: #ffb08a !important; }
.linha-tempo { margin-top: 10px; }
.pedido { margin: 22px 0 0; padding: 16px; outline: 0; background: #1e2a33; border: 2px solid #3a4c5a; text-align: center; }
.pedido > p { margin: 0 0 12px; font-size: 14px; color: #e9f0ff; }
.precisa { list-style: none; margin: 0 0 16px; padding: 0; display: flex; justify-content: center; gap: 22px; flex-wrap: wrap; }
.precisa li { display: grid; justify-items: center; gap: 4px; }
.precisa img { width: 45px; height: 57px; image-rendering: pixelated; }
.precisa b { font: 20px "Silk"; font-weight: 400; color: var(--ouro); }
.precisa span { font-size: 11px; color: #c8d0dc; text-transform: uppercase; }
.botao-escuro { font-size: 15px; }
.marco { display: grid; grid-template-columns: 96px 1fr; gap: 14px; align-items: center; margin-top: 22px; padding: 14px; background: #18232c; border: 2px solid #24323c; }
.marco-arte { width: 96px; height: 60px; image-rendering: pixelated; }
.marco-barra { margin: 10px 0 6px; }
.rumores li { display: grid; grid-template-columns: 112px 1fr; gap: 14px; align-items: center; padding: 10px; }
.rumores canvas { width: 112px; height: 70px; image-rendering: pixelated; border: 2px solid #24323c; }
.rumores p { margin: 0; font-size: 13px; line-height: 1.5; }
.nota-clima { margin-top: 22px; }
@media (max-width: 420px) { .rumores li { grid-template-columns: 96px 1fr; } .rumores canvas { width: 96px; height: 60px; } }

/* ---------------------------------------------------------------- how to move in: illustrated steps */
.entrar { padding-left: 12px; padding-right: 12px; }
.passos li { display: grid; grid-template-columns: 112px 1fr; gap: 14px; align-items: center; padding: 14px 0; }
.passos li::before { display: none; }
.passos canvas { width: 112px; height: 68px; image-rendering: pixelated; border: 3px solid var(--madeira-esc); }
.passos p { margin: 0; font-size: 14px; line-height: 1.5; }
.passos strong { display: block; margin-bottom: 4px; font-size: 15px; }
.dias .t-regioes { margin-top: 56px; }
.dias .rodape { margin-top: 48px; padding: 24px 0 0; }

/* ================================================================ hierarchy: story (reading) · quest (one goal, numbered steps) · context (muted) */
/* home: one line of story + the quest chip; the main action stays the search */
.resumo { position: absolute; z-index: 3; left: 16px; right: 16px; top: calc(max(10px, env(safe-area-inset-top)) + 166px); display: grid; justify-items: start; gap: 8px; pointer-events: none; }
.resumo a { pointer-events: auto; }
.historia-linha { max-width: 34ch; padding: 8px 12px; font-size: 13px; line-height: 1.45; color: var(--texto); text-decoration: none; background: rgba(18, 12, 6, .78); }
.historia-linha:hover { color: #fff; }
.quest-chip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; font: 11px/1 "Silk"; text-transform: uppercase; color: #e9f0ff; text-decoration: none; background: rgba(16, 24, 31, .9); border: 2px solid #3a4c5a; }
.qc-tag { padding: 4px 6px; color: var(--tinta); background: var(--ouro); }
.quest-chip:hover { border-color: var(--ouro); color: #fff; }
@media (min-width: 900px) { .resumo { left: 32px; top: 190px; } }

/* quest: objective, then numbered steps; only the active step carries a button */
.inverno h2 { font-size: clamp(28px, 7.5vw, 46px); }
.objetivo { margin: 0 0 26px; font-size: 15px; line-height: 1.55; color: #c8d4e0; max-width: 46ch; }
.objetivo span { color: #e9f0ff; }
.etapas { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.etapas > li { display: grid; grid-template-columns: 30px 56px 1fr; gap: 12px; align-items: start; padding: 14px; background: #141e26; border: 2px solid #24323c; }
.etapas .num { width: 30px; height: 30px; display: grid; place-items: center; font: 15px "Silk"; color: #8fa0b0; background: #0b1116; border: 2px solid #2c3c48; }
.etapas .ico { width: 56px; height: auto; image-rendering: pixelated; margin-top: 2px; }
.etapas h3 { font: 16px/1.2 "Silk"; color: #e9f0ff; text-transform: uppercase; }
.etapas .estado { margin: 6px 0 0; font-size: 13px; color: #b9c6d4; }
.etapas .estoque { margin: 6px 0 0; font-size: 12px; color: #8a98a6; }
.etapas .precisa-linha { margin: 8px 0 0; font: 12px "Silk"; color: #ffb08a; text-transform: uppercase; }
.etapas li.urgente .estado { color: #ffb08a; }
.etapas li.ok .estado { color: #9fd08a; }
.etapas li.bonus { background: #121a20; border-style: dashed; }
.etapas li.bonus h3 { color: #b9c6d4; }
.etapas li.ativa { border-color: var(--ouro); background: #1a2530; }
.etapas li.ativa .num { color: var(--tinta); background: var(--ouro); border-color: var(--ouro); }
.etapas li.ativa h3 { font-size: 18px; }
.acao { grid-column: 1 / -1; display: grid; grid-template-columns: 52px 1fr; gap: 12px; align-items: center; margin-top: 6px; padding-top: 14px; border-top: 2px solid #2c3c48; }
.acao img { width: 45px; height: 57px; image-rendering: pixelated; justify-self: center; }
.acao p { margin: 0; font-size: 13px; line-height: 1.45; color: #c8d4e0; }
.acao p b { display: block; margin-bottom: 4px; font: 15px "Silk"; font-weight: 400; color: var(--ouro); text-transform: uppercase; }
.acao .botao { grid-column: 1 / -1; font-size: 15px; }
/* context: weather and the next milestone, quieter, no action */
.contexto { margin-top: 40px; padding-top: 24px; border-top: 2px solid #1e2a33; }
.sub-calmo { margin: 0 0 12px; font-size: 12px; color: #8fa0b0; text-transform: uppercase; letter-spacing: .08em; }
.sub-calmo span { color: #b9c6d4; }
.contexto .previsao li { background: #121a20; border-color: #1e2a33; }
.contexto .previsao li:first-child { border-color: #5a6a78; }
.contexto .marco { margin-top: 16px; background: #121a20; border-color: #1e2a33; }
.contexto .marco p { color: #c8d4e0; font-size: 13px; }
/* story */
.dias .t-rumores { margin-top: 56px; margin-bottom: 18px; }
.dias .rumores li { background: #141e19; }
.dias .rumores p { color: #d8dfd4; }
.dias .t-rumores, .dias .t-regioes { font-size: clamp(22px, 6vw, 32px); }

/* how you can help: the 3 jobs as options, one button */
.ajudar { margin-top: 22px; padding: 20px 16px; text-align: center; background: #1a2530; border: 2px solid var(--ouro); }
.ajudar h3 { font: 20px "Silk"; color: var(--ouro); text-transform: uppercase; }
.ajudar > p { margin: 8px 0 0; font-size: 14px; color: #c8d4e0; }
.ajudar-lista { list-style: none; margin: 16px 0 18px; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.ajudar-lista li { display: grid; justify-items: center; align-content: start; gap: 4px; padding: 12px 4px 10px; background: #141e26; border: 2px solid #2c3c48; }
.ajudar-lista li.mais-precisa { border-color: var(--ouro); }
.ajudar-lista img { width: 45px; height: 57px; image-rendering: pixelated; }
.ajudar-lista b { font: 13px "Silk"; font-weight: 400; color: #e9f0ff; text-transform: uppercase; }
.ajudar-lista .ajuda-passo { font-size: 11px; color: #8fa0b0; }
.ajudar-lista .ajuda-qtd { font: 10px "Silk"; color: #ffb08a; text-transform: uppercase; }
.ajudar-lista li.mais-precisa .ajuda-qtd { color: var(--tinta); background: var(--ouro); padding: 3px 5px; }
.ajudar .botao { font-size: 15px; }
.ajudar-nota { font-size: 12px !important; color: #8fa0b0 !important; margin-top: 12px !important; }
.ajudar-lista b { font-size: 11px; letter-spacing: 0; overflow-wrap: anywhere; }
.ajudar-lista .ajuda-qtd { font-size: 9px; letter-spacing: 0; }
@media (min-width: 560px) { .ajudar-lista b { font-size: 13px; } .ajudar-lista .ajuda-qtd { font-size: 10px; } }
.ajudar-lista { gap: 6px; }
.ajudar-lista li { padding: 12px 2px 10px; }
.ajudar-lista b { font-size: 10px; letter-spacing: -.03em; overflow-wrap: normal; white-space: nowrap; }
@media (min-width: 560px) { .ajudar-lista b { font-size: 13px; letter-spacing: 0; } }

/* register: who got a scene shines; and the invitation to tell more */
.lista > li.destaque, .lista > li.destaque:nth-child(odd) { background: #f6dc8c; }
.lista > li.destaque .linha:hover { background: #f9e6a8; }
.linha small.teve-cena { display: inline-block; margin-top: 6px; padding: 4px 7px; font: 10px/1 "Silk"; color: var(--tinta); background: var(--ouro); box-shadow: inset 0 -2px 0 var(--ouro-2); text-transform: uppercase; }
.incentivo { margin: 0 0 18px; padding: 16px; background: #f6dc8c var(--perg-tex); border: 3px solid #b8902e; }
.incentivo h3 { font: 18px "Silk"; color: #5a2414; text-transform: uppercase; }
.incentivo p { margin: 8px 0 12px; font-size: 14px; line-height: 1.5; color: var(--tinta); }
.incentivo blockquote { margin: 0; padding: 12px; font-size: 13px; line-height: 1.5; color: var(--tinta); background: #fff3cf; }
.incentivo blockquote span { display: inline-block; margin-top: 8px; padding: 4px 7px; font: 10px/1 "Silk"; color: var(--tinta); background: var(--ouro); text-transform: uppercase; }
.filtros { display: flex; gap: 8px; margin: 0 0 12px; }
.filtro-pilula { flex: 1; padding: 10px 8px; font: 13px "Silk"; text-transform: uppercase; color: var(--tinta-2); background: #f3e8c8; border: 3px solid #c9b48a; cursor: pointer; }
.filtro-pilula span { color: #8a7656; }
.filtro-pilula[aria-pressed="true"] { color: var(--perg-3); background: #5a2414; border-color: #3e1a10; }
.filtro-pilula[aria-pressed="true"] span { color: var(--ouro); }
.filtro-pilula[data-f="destaque"][aria-pressed="true"] { color: var(--tinta); background: var(--ouro); border-color: #b8902e; }
.filtro-pilula[data-f="destaque"][aria-pressed="true"] span { color: #5a2414; }

/* music button */
.som { display: grid; place-items: center; width: 40px; height: 40px; margin-left: 4px; padding: 0; color: #8fa094; background: none; border: 2px solid #2c3c34; cursor: pointer; }
.som svg { width: 20px; height: 20px; }
.som .ondas { display: none; } .som .mudo { display: inline; }
.som[aria-pressed="true"] { color: var(--ouro); border-color: var(--ouro); }
.som[aria-pressed="true"] .ondas { display: inline; } .som[aria-pressed="true"] .mudo { display: none; }
.som.espera { animation: pulso 1.6s steps(2) infinite; }
.bar { gap: 10px; }
.bar .where { margin-left: auto; }
@media (min-width: 900px) { .som { margin-left: 18px; } .bar { justify-content: flex-start; } }

/* map: drag, zoom, back to the village */
#mundo { touch-action: none; cursor: grab; }
#mundo:active { cursor: grabbing; }
.mapa-ctrl { position: absolute; z-index: 4; right: 12px; bottom: calc(var(--nav) + 150px + env(safe-area-inset-bottom)); display: grid; gap: 6px; }
.mc { display: grid; place-items: center; width: 40px; height: 40px; padding: 0; color: #e9f0ff; background: rgba(16, 24, 31, .88); border: 2px solid #3a4c5a; cursor: pointer; }
.mc svg { width: 18px; height: 18px; }
.mc:hover { border-color: var(--ouro); color: var(--ouro); }
.mc-volta { color: var(--tinta); background: var(--ouro); border-color: var(--borda); }
.mc[hidden] { display: none; }
@media (min-width: 900px) { .mapa-ctrl { right: 32px; bottom: 140px; } }

.ajudar-lista { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 560px) { .ajudar-lista { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ajudar-lista b { font-size: 12px; }

/* ---------------------------------------------------------------- 03/11: reading font, needs without order, season, bigger rumor pictures */
.where, .tag-mundo, [data-relogio] { font-family: "Silk"; }
.sub-quest { margin: 26px 0 4px; font-size: 18px; color: #e9f0ff; text-transform: uppercase; }
.quest-dica { margin: 0 0 14px; font-size: 14px; color: #9fb0c0; }
.needs { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.need { padding: 14px 14px 12px; background: #141e26; border: 2px solid #24323c; border-left-width: 8px; }
.need.alerta { border-left-color: var(--brasa); }
.need.ok { border-left-color: #6f9a5e; }
.need.extra { border-left-color: #5a6a78; }
.need-top { display: grid; grid-template-columns: 52px minmax(0, 1fr); column-gap: 12px; row-gap: 8px; align-items: center; }
.need-tit { min-width: 0; }
.need .ico { width: 52px; height: auto; image-rendering: pixelated; }
.need h3 { font-size: 17px; color: #e9f0ff; text-transform: uppercase; }
.need-estoque { margin: 4px 0 0; font-size: 13px; color: #8fa0b0; }
.selo { grid-column: 2; justify-self: start; font: 11px/1.2 "Silk"; text-transform: uppercase; padding: 6px 8px 5px; }
.need.alerta .selo { color: var(--borda); background: var(--brasa); }
.need.ok .selo { color: #cfe8c2; background: #2a4428; }
.need.extra .selo { color: #c8d4e0; background: #26323c; }
.need .linha-tempo { margin-top: 12px; }
.need-txt { margin: 10px 0 0; font-size: 14px; line-height: 1.5; color: #c8d4e0; }
.need.alerta .need-txt { color: #ffd2bd; }
.quem-ajuda { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; padding-top: 10px; border-top: 2px solid #22303a; }
.qa-label { font-size: 12px; color: #8fa0b0; margin-right: 2px; }
.qa { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 4px; background: #0f171d; border: 2px solid #2c3c48; }
.qa img { width: 22px; height: 28px; image-rendering: pixelated; }
.qa b { font: 11px "Silk"; font-weight: 400; color: #e9f0ff; text-transform: uppercase; }
.need.alerta .qa { border-color: #7a3a26; }
.inverno .ajudar { margin-top: 12px; text-align: left; border: 2px solid #2c3c48; background: #1a2530; }
.inverno .ajudar > p { margin: 0 0 14px; font-size: 14px; color: #c8d4e0; }
.estacao { margin: 0; font-size: 15px; color: #c8d4e0; }
.rumores { grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 18px; }
.dias .rumores li, .rumores li { display: block; padding: 10px 10px 14px; background: #efe6cc; color: var(--tinta); box-shadow: var(--sombra); }
.rumores li:nth-child(odd) { transform: rotate(-1deg); } .rumores li:nth-child(even) { transform: rotate(.8deg); }
.rumores canvas { display: block; width: 100%; height: auto; aspect-ratio: 8 / 5; image-rendering: pixelated; border: 0; }
.rumores p, .dias .rumores p { margin: 10px 2px 0; font-size: 13px; line-height: 1.45; color: var(--tinta); }
.rumor-dia { display: block; margin-bottom: 3px; font: 11px "Silk"; color: #8a3a1e; text-transform: uppercase; }
@media (max-width: 420px) { .rumores li { grid-template-columns: none; } .rumores canvas { width: 100%; height: auto; } }
@media (prefers-reduced-motion: reduce) { .rumores li { transform: none !important; } }

/* share a villager */
.partilha { margin-top: 16px; padding-top: 14px; border-top: 3px solid #c9b48a; }
.partilha[hidden] { display: none; }
.partilha-btn { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 10px 16px; font: 14px "Silk"; text-transform: uppercase; color: var(--perg-3); background: var(--madeira-esc); border: var(--px) solid var(--borda); cursor: pointer; -webkit-font-smoothing: none; }
.partilha-btn:hover, .partilha-btn[aria-expanded="true"] { background: #5a3820; }
.partilha-menu { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; margin-top: 10px; }
.partilha-menu[hidden] { display: none; }
.partilha-menu button { min-height: 44px; padding: 8px 10px; font: 600 14px "Open Sans", sans-serif; color: var(--tinta); background: var(--perg-3); border: 2px solid var(--madeira); cursor: pointer; text-align: left; }
.partilha-menu button:hover { background: #fff6dc; border-color: var(--madeira-esc); }
.partilha-menu button[data-s="ig"] { grid-column: 1 / -1; background: var(--ouro); border-color: var(--borda); font-weight: 700; }
.partilha-aviso { margin: 8px 0 0; font-size: 13px; color: var(--tinta-2); }
.partilha-aviso:empty { display: none; }

/* day panel: sky window + wooden planks (pixel art) */
.hud { position: absolute; z-index: 3; top: calc(max(10px, env(safe-area-inset-top)) + 58px); left: 12px; display: flex; align-items: center; pointer-events: none; filter: drop-shadow(0 4px 0 rgba(0, 0, 0, .35)); }
@media (min-width: 900px) { .hud { left: 28px; top: 82px; } }
.hud-ceu { position: relative; z-index: 1; width: 90px; height: 90px; image-rendering: pixelated; margin-right: -10px; }
.hud-tabuas { display: grid; gap: 4px; padding: 6px 8px 6px 16px; background: #b8722f; border: 3px solid #2a140a; box-shadow: inset 0 3px 0 #e8a24a, inset 0 -3px 0 #8a4a1e; }
.hud-tab { margin: 0; display: flex; align-items: center; justify-content: center; gap: 6px; min-width: 128px; height: 24px; padding: 0 8px; font: 13px/1 "Silk"; color: #4a2410; background: #f6e2b0; border: 2px solid #6a3416; box-shadow: inset 0 2px 0 #fff3d0, inset 0 -2px 0 #e2c48a; -webkit-font-smoothing: none; white-space: nowrap; }
.hud-tab .ponto { width: 6px; height: 6px; }
.hud-icos { justify-content: space-between; padding: 0 6px; }
.hud-icos img { width: 18px; height: 18px; image-rendering: pixelated; }
.hud-hora { font-size: 15px; letter-spacing: .04em; }

/* the Day's story line: a small wooden tab that opens the text */
.resumo { gap: 6px; }
.resumo-btn { pointer-events: auto; display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 6px 10px; font: 12px/1 "Silk"; text-transform: uppercase; letter-spacing: .04em; color: #4a2410; background: #f6e2b0; border: 3px solid #2a140a; box-shadow: inset 0 2px 0 #fff3d0, inset 0 -3px 0 #c89a5a, 0 3px 0 rgba(0, 0, 0, .35); cursor: pointer; -webkit-font-smoothing: none; }
.resumo-btn:hover { background: #fff0c8; }
.resumo-sinal { display: grid; place-items: center; width: 16px; height: 16px; margin-left: 2px; font: 14px/1 "Silk"; font-weight: 400; color: #f6e2b0; background: #8a4a1e; }
.resumo-txt[hidden] { display: none; }
.resumo-txt .historia-linha { display: block; }
.hud-tab:first-child { height: 28px; font-size: 17px; letter-spacing: .06em; color: #5a1e0a; }
.hud-hora { font-size: 13px; }

/* panel drawer: tab with an arrow under the planks; the story drops down in parchment */
.hud { display: grid; grid-template-columns: auto auto; align-items: center; }
.hud-ceu { grid-column: 1; grid-row: 1; }
.hud-tabuas { grid-column: 2; grid-row: 1; }
.hud-gaveta { grid-column: 1 / -1; grid-row: 2; pointer-events: auto; max-width: 262px; margin: -3px 0 0 18px; padding: 10px 12px 12px; color: #4a2410; background: #f6e2b0; border: 3px solid #2a140a; box-shadow: inset 0 2px 0 #fff3d0, inset 0 -3px 0 #e2c48a; }
.hud-gaveta[hidden] { display: none; }
.hud-gaveta-tit { margin: 0 0 6px; font: 11px/1 "Silk"; text-transform: uppercase; letter-spacing: .06em; color: #8a4a1e; -webkit-font-smoothing: none; }
.hud-gaveta-txt { margin: 0; font-size: 13px; line-height: 1.45; }
.hud-gaveta-link { display: inline-block; margin-top: 8px; font-size: 12px; font-weight: 600; color: #8a3a12; }
.hud-puxa { grid-column: 2; grid-row: 3; justify-self: center; position: relative; pointer-events: auto; display: grid; place-items: center; width: 56px; height: 26px; margin-top: -3px; padding: 0; color: #f6e2b0; background: #b8722f; border: 3px solid #2a140a; border-top-width: 0; box-shadow: inset 0 -3px 0 #8a4a1e; cursor: pointer; }
.hud-puxa:hover { background: #c8823a; }
.hud-puxa.aberta svg { transform: rotate(180deg); }
.hud-novo { display: none; position: absolute; top: 2px; right: -14px; width: 18px; height: 18px; place-items: center; font: 12px/1 "Silk"; color: #2a140a; background: var(--ouro); border: 2px solid #2a140a; -webkit-font-smoothing: none; animation: pulso 1.6s steps(2) infinite; }
.hud-puxa.novo .hud-novo { display: grid; }
@media (prefers-reduced-motion: reduce) { .hud-novo { animation: none; } }
/* the drawer never widens the panel: it takes the panel's width (width 0 + min-width) */
.hud-gaveta { width: 0; min-width: calc(100% - 18px); max-width: none; box-sizing: border-box; }

/* the Day's parchment: dark backdrop, wooden rollers, paper unrolling downward in pixel steps */
.hud-puxa { width: 56px; height: 30px; }
.perg-fundo { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; padding: 20px 14px calc(var(--nav, 0px) + 20px); background: rgba(6, 10, 8, 0); transition: background .3s; }
.perg-fundo[hidden] { display: none; }
.perg-fundo.aberto { background: rgba(6, 10, 8, .72); }
.perg { width: min(440px, 100%); display: grid; filter: drop-shadow(0 10px 0 rgba(0, 0, 0, .35)); }
.perg-rolo { position: relative; z-index: 2; height: 20px; margin: 0 -12px; background: linear-gradient(#e0a050 0 4px, #b8722f 4px 12px, #8a4a1e 12px 16px, #5a2a10 16px); border: 3px solid #2a140a; }
.perg-rolo::before, .perg-rolo::after { content: ""; position: absolute; top: -6px; width: 12px; height: 26px; background: #5a2a10; border: 3px solid #2a140a; }
.perg-rolo::before { left: -12px; } .perg-rolo::after { right: -12px; }
.perg-corpo { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .55s steps(11); margin: -3px 0; }
.perg-fundo.aberto .perg-corpo { grid-template-rows: 1fr; }
.perg-fundo.fechando .perg-corpo { grid-template-rows: 0fr; transition-duration: .3s; }
.perg-papel { position: relative; min-height: 0; overflow: hidden; max-height: calc(100dvh - 190px); overflow-y: auto; padding: 0 22px; color: var(--tinta); background: var(--perg) var(--perg-tex); border-left: 3px solid #c9b48a; border-right: 3px solid #c9b48a; }
.perg-papel > :first-child { margin-top: 18px; }
.perg-sobre { margin: 18px 0 2px; font: 11px/1 "Silk"; text-transform: uppercase; letter-spacing: .08em; color: var(--madeira); -webkit-font-smoothing: none; }
.perg h2 { font-size: 34px; color: #5a1e0a; text-transform: uppercase; }
.perg-img { display: block; width: 100%; height: auto; margin: 14px 0 0; image-rendering: pixelated; border: 3px solid var(--madeira-esc); }
.perg-img[hidden] { display: none; }
.perg-txt { margin: 14px 0 0; font-size: 16px; line-height: 1.55; }
.perg-acoes { display: grid; gap: 10px; justify-items: center; margin: 18px 0 22px; }
.perg-ver { width: 100%; font-size: 16px; padding: 14px 16px 12px; }
.perg-todos { font-size: 14px; font-weight: 600; color: #8a3a12; }
.perg-fechar { position: absolute; top: 8px; right: 8px; width: 44px; height: 44px; display: grid; place-items: center; color: var(--tinta-2); background: none; border: 0; cursor: pointer; }
.perg-fechar:hover { color: var(--tinta); }
@media (prefers-reduced-motion: reduce) { .perg-corpo { transition: none; } .perg-fundo { transition: none; } }
/* parchment, take 2: the body opens by max-height (set in JS to the paper's real height), so the bottom roller always sits right under the paper */
.perg { outline: none; }
.perg-corpo { display: block; max-height: 0; overflow: hidden; transition: max-height .55s steps(11); }
.perg-fundo.aberto .perg-corpo, .perg-fundo.fechando .perg-corpo { grid-template-rows: none; }
.perg-papel { max-height: calc(100dvh - 150px); scrollbar-width: thin; scrollbar-color: var(--madeira) transparent; }
.perg-img { max-height: 32vh; object-fit: cover; }
@media (prefers-reduced-motion: reduce) { .perg-corpo { transition: none; } }

/* Quadro da Guilda (aba Quest + popup da vila) */
.guilda { margin: 0 0 26px; }
.guilda-lista, .guilda-mini { list-style: none; margin: 10px 0 14px; padding: 0; display: grid; gap: 10px; }
.gq { display: grid; grid-template-columns: 44px 1fr; gap: 12px; padding: 12px; background: var(--perg) var(--perg-tex); color: var(--tinta); border: 3px solid var(--madeira-esc); }
.gq.feito { opacity: .85; }
.gq-ico { width: 44px; height: 44px; image-rendering: pixelated; }
.gq-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.gq h4 { margin: 0; font: 15px/1.2 "Silk"; color: #5a1e0a; text-transform: uppercase; }
.gq .selo { flex: none; padding: 2px 6px; font: 10px/1.2 "Silk"; text-transform: uppercase; color: #fff; background: #9b2f22; }
.gq.feito .selo { background: #4a7a3a; }
.gq-por { margin: 2px 0 0; font-size: 13px; color: var(--madeira); }
.gq-hist { margin: 6px 0 0; font-size: 14px; line-height: 1.45; }
.gq-barra { height: 10px; margin: 8px 0 0; background: #d9c08a; border: 2px solid var(--madeira-esc); }
.gq-barra i { display: block; height: 100%; background: #c98a2a; }
.gq.feito .gq-barra i { background: #4a7a3a; }
.gq-num { margin: 4px 0 0; font: 12px/1.3 "Silk"; color: var(--tinta); }
.gq-como { margin: 6px 0 0; font-size: 14px; line-height: 1.45; font-weight: 600; }
.gq-nomes { margin: 4px 0 0; font-size: 13px; color: var(--madeira); }
.gq-nomes:empty, .gq-hist:empty { display: none; }
.gq.mini { padding: 8px 10px; background: rgba(255, 255, 255, .25); border-width: 2px; }
.guilda-mini { margin-top: 14px; }
