/* FESTIVAIS na wiki (festivais_rotas.py, festivais.js) — complementa janelas.css; tudo com o prefixo jn-fest- */

/* lista: calendário que filtra por mês */
.jn-fest-cal { display: flex; flex-wrap: wrap; gap: .4rem; margin: var(--s-3) 0 0; }
.jn-fest-mes { position: relative; min-width: 3.4rem; padding: .45rem .7rem; border-radius: var(--r-pill, 999px); border: 1px solid rgba(255, 255, 255, .14);
  background: var(--surface); color: var(--text); font: 600 var(--fs-sm)/1 var(--font-titulo, inherit); cursor: pointer;
  transition: transform .2s var(--mola, ease), background .2s, border-color .2s; }
.jn-fest-mes i { position: absolute; top: -.45rem; right: -.35rem; min-width: 1.2rem; padding: .1rem .3rem; border-radius: 999px; background: #e8a33a;
  color: #1b1206; font: 700 .7rem/1.1 system-ui, sans-serif; font-style: normal; }
.jn-fest-mes:hover:not(:disabled) { transform: translateY(-2px); border-color: #e8a33a; }
.jn-fest-mes.ativo { background: linear-gradient(180deg, #f3c25a, #c97a1e); color: #1b1206; border-color: transparent; }
.jn-fest-mes.vazio { opacity: .4; cursor: default; }
.jn-fest-agora { box-shadow: 0 0 0 2px #e8a33a, 0 10px 30px rgba(232, 163, 58, .18); }
.jn-fest-tag-agora { background: linear-gradient(180deg, #f3c25a, #c97a1e); color: #1b1206; animation: jn-fest-pulsa 2s ease-in-out infinite; }
.jn-fest-nada { margin-top: var(--s-3); }
.jn-lista [hidden], .jn-fest-nada[hidden] { display: none !important; }

/* página: roda do ano no herói */
.jn-fest-ano { position: relative; width: min(100%, 320px); aspect-ratio: 1; margin: 0 auto; }
.jn-fest-roda { list-style: none; margin: 0; padding: 0; position: absolute; inset: 0; border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 0, 0, .35) 0 46%, rgba(255, 255, 255, .04) 47% 70%, transparent 71%);
  animation: jn-fest-gira 60s linear infinite; }
.jn-fest-roda li { position: absolute; left: 50%; top: 50%; width: 3.1rem; height: 3.1rem; margin: -1.55rem 0 0 -1.55rem; display: grid; place-items: center;
  border-radius: 50%; background: var(--surface); border: 1px solid rgba(255, 255, 255, .12); color: var(--text); opacity: .55;
  font: 700 var(--fs-xs)/1 var(--font-titulo, inherit);
  transform: rotate(calc(var(--jn-fest-i, 0) * 30deg - 90deg)) translate(min(42vw, 128px)) rotate(calc(var(--jn-fest-i, 0) * -30deg + 90deg)); }
.jn-fest-roda li span { display: block; animation: jn-fest-gira 60s linear infinite reverse; }
.jn-fest-roda li.aberto { opacity: 1; background: linear-gradient(180deg, #f3c25a, #c97a1e); color: #1b1206; border-color: transparent;
  box-shadow: 0 0 18px rgba(243, 194, 90, .55); }
.jn-fest-roda li.hoje { outline: 2px solid #fff; outline-offset: 3px; }
.jn-fest-roda li.hoje.aberto { animation: jn-fest-pulsa 1.6s ease-in-out infinite; }
.jn-fest-centro { position: absolute; inset: 30%; display: grid; place-content: center; text-align: center; border-radius: 50%; }
.jn-fest-centro b { font: 800 var(--fs-lg)/1 var(--font-titulo, inherit); color: #f3c25a; }
.jn-fest-centro span { font-size: var(--fs-xs); opacity: .85; }

/* quando abre */
.jn-fest-meses { list-style: none; margin: var(--s-2) 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.jn-fest-meses li { padding: .35rem .8rem; border-radius: 999px; background: var(--surface); border: 1px solid rgba(255, 255, 255, .14); font-weight: 600; }
.jn-fest-meses li.hoje { background: linear-gradient(180deg, #f3c25a, #c97a1e); color: #1b1206; border-color: transparent; }
.jn-fest-meses li span { font-weight: 400; }

/* as abas */
.jn-fest-regra { margin-top: var(--s-3); padding: var(--s-3) var(--s-4); border-radius: var(--r-md); background: rgba(0, 0, 0, .18);
  border-left: 3px solid #e8a33a; animation: jn-fest-entra .35s var(--mola, ease); }
.jn-fest-regra p { margin: 0 0 .5rem; }
.jn-fest-regra.fechada { border-left-color: #777; opacity: .85; }
.jn-fest-ver { font-size: var(--fs-sm); }
.wk-abas .jn-fest-fechada { opacity: .65; }
.wk-pagina [data-fest-painel][hidden] { display: none !important; }

/* janela: aba fechada */
.jn-fest-faixa { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) rotate(-6deg); padding: .6rem 2.4rem; z-index: 5;
  background: rgba(20, 14, 6, .88); color: #f3c25a; border: 2px solid #c97a1e; border-radius: 6px; font: 800 22px/1.2 var(--font-titulo, inherit);
  letter-spacing: .02em; pointer-events: none; box-shadow: 0 10px 40px rgba(0, 0, 0, .6); white-space: nowrap; }
.jn-fest-faixa[hidden] { display: none; }
.jn-btn.jn-fest-tab:hover { box-shadow: inset 0 0 0 2px rgba(243, 194, 90, .8); }
.jn-fest-chip-agora { border-color: #e8a33a; }

@keyframes jn-fest-gira { to { transform: rotate(360deg); } }
@keyframes jn-fest-pulsa { 50% { box-shadow: 0 0 26px rgba(243, 194, 90, .85); } }
@keyframes jn-fest-entra { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) {
  .jn-fest-roda, .jn-fest-roda li span, .jn-fest-tag-agora, .jn-fest-roda li.hoje.aberto, .jn-fest-regra { animation: none; }
}
.wk-abas.jn-fest-listas { flex-wrap: wrap; overflow: visible; }
.wk-abas.jn-fest-listas button { white-space: normal; }
/* fileira de abas desenhada sobre a janela (as do SWF são posicionadas pelo jogo em código) */
.jn-fest-abajogo { position: absolute; z-index: 4; padding: 0 8px; border-radius: 8px 8px 4px 4px; cursor: pointer;
  border: 2px solid #6b3a12; background: linear-gradient(180deg, #8a5524, #5a3313); color: #f6e3b4;
  font: 700 13px/1.05 var(--font-titulo, inherit); text-shadow: 0 1px 0 #000; box-shadow: 0 3px 8px rgba(0, 0, 0, .45);
  overflow: hidden; white-space: normal; transition: transform .15s, filter .15s; }
.jn-fest-abajogo:hover { transform: translateY(-2px); filter: brightness(1.12); }
.jn-fest-abajogo.ativa { background: linear-gradient(180deg, #ffd96b, #e09a26); color: #3a1d03; border-color: #fff3c4; text-shadow: none;
  box-shadow: 0 0 14px rgba(255, 217, 107, .75); }
.jn-fest-abajogo.fechada { filter: grayscale(.8); opacity: .8; }
.jn-fest-meses li { border-color: var(--border-2, rgba(0, 0, 0, .14)); }
