/* ===========================================================
   DESBLOQUEIOS (badges nos botões do hub) + CARTÃO DA LUA
   =========================================================== */

/* ---------- botões bloqueados ---------- */
.modulo-btn .modulo-circulo { position: relative; }
.modulo-btn.bloqueado .modulo-circulo img,
.modulo-btn.bloqueado .modulo-circulo .modulo-fallback {
  filter: brightness(.72) grayscale(.3);
}
.modulo-btn.bloqueado .modulo-nome { opacity: .85; }

.desbloqueio-badge {
  position: absolute;
  z-index: 2;
  pointer-events: none;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .45);
}
.desbloqueio-badge.badge-dias {
  top: -4px;
  left: 50%;
  transform: translateX(-50%);
  padding: 3px 7px;
  border-radius: 999px;
  font-size: .7rem;
  background: #7a4a91;
  color: #f3e5ff;
  border: 1px solid rgba(233, 196, 106, .7);
}
.desbloqueio-badge.badge-cadeado {
  top: -2px;
  right: -2px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .72rem;
  background: rgba(15, 12, 27, .92);
  border: 1px solid rgba(233, 196, 106, .6);
}

/* ---------- aviso de bloqueio: vidro fosco com a flor (custom-modal do mapa) ---------- */
.custom-modal {
  display: flex;
  position: fixed;
  inset: 0;
  z-index: 100000;
  background-color: rgba(0, 0, 0, .15);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  justify-content: center;
  align-items: center;
  padding: 16px;
  opacity: 0;
  transition: opacity .3s ease;
}
.custom-modal.show { opacity: 1; }
.custom-modal-content {
  background: rgba(255, 255, 255, .3);
  border: 1px solid rgba(255, 255, 255, .4);
  padding: 36px 26px 28px;
  border-radius: 24px;
  text-align: center;
  box-shadow: 0 15px 35px rgba(0, 0, 0, .1);
  max-width: 380px;
  width: 100%;
  transform: scale(.9);
  transition: transform .3s ease-out;
}
.custom-modal.show .custom-modal-content { transform: scale(1); }
.custom-modal-icon {
  display: block;
  width: 84px;
  height: 84px;
  object-fit: contain;
  margin: 0 auto 16px;
  filter: drop-shadow(0 0 12px rgba(255, 255, 255, .6));
  animation: flor-flutuar 3s ease-in-out infinite;
}
@keyframes flor-flutuar { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.custom-modal-content h2 {
  color: #fff;
  font-size: 1.6rem;
  font-weight: 700;
  margin: 0 0 12px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, .15);
}
.custom-modal-content p {
  color: rgba(255, 255, 255, .95);
  font-size: 1.08rem;
  line-height: 1.6;
  margin: 0 0 26px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, .15);
}
.custom-modal-content strong { color: #fff; font-weight: 700; }
.custom-modal-content button {
  display: block;
  width: 100%;
  background: rgba(255, 255, 255, .2);
  border: 1px solid rgba(255, 255, 255, .3);
  color: #b58d7c;
  padding: 14px 30px;
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 16px;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, .05);
  transition: background .2s ease, transform .1s ease, box-shadow .2s ease;
}
.custom-modal-content button + button { margin-top: 10px; }
.custom-modal-content button:hover { background: rgba(255, 255, 255, .3); box-shadow: 0 6px 15px rgba(0, 0, 0, .1); }
.custom-modal-content button:active { transform: scale(.98); background: rgba(255, 255, 255, .15); }
.custom-modal-content .aviso-mais { background: transparent; border-color: rgba(255, 255, 255, .22); color: rgba(255, 255, 255, .85); }
.custom-modal-content .aviso-fechar { color: #f3d9c9; }

/* No tema claro o fundo é quase branco: um véu violeta suave mantém o texto branco legível */
html[data-tema="claro"] .custom-modal { background-color: rgba(46, 26, 85, .5); }
html[data-tema="claro"] .custom-modal-content .aviso-fechar { color: #fff; background: rgba(255, 255, 255, .25); }

/* ---------- cartão da lua ---------- */
.cartao-lua {
  margin: 4px 0 18px;
  padding: 16px 18px;
  border-radius: 20px;
  background:
    radial-gradient(circle at 88% 12%, rgba(245, 215, 122, .18), transparent 45%),
    linear-gradient(160deg, var(--violet-mid, #2a1450), var(--violet-deep, #150a2e));
  border: 1px solid rgba(207, 159, 63, .25);
  box-shadow: 0 18px 40px rgba(15, 6, 26, .45);
}
.cartao-lua[hidden] { display: none; }
.lua-topo { display: flex; align-items: center; gap: 12px; }
.lua-icone {
  font-size: 2.1rem;
  line-height: 1;
  filter: drop-shadow(0 0 10px rgba(245, 215, 122, .45));
}
.lua-titulos { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lua-etiqueta {
  font-family: 'Cinzel', serif;
  font-size: .66rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--beige-dim, #cbb8e0);
}
.cartao-lua h2 { margin: 0; font-size: 1.12rem; color: var(--gold-bright, #f5d77a); }
.lua-frase { margin: 10px 0 4px; line-height: 1.45; font-size: .92rem; color: var(--beige, #f3e9ff); }
.lua-duracao { margin: 0; font-size: .8rem; color: var(--beige-dim, #cbb8e0); }
.lua-rodape {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed rgba(207, 159, 63, .3);
  text-align: center;
}
.lua-bloqueio { font-size: .8rem; font-weight: 600; color: #f0a6c8; }
.lua-botao {
  display: inline-block;
  padding: 9px 20px;
  border-radius: 999px;
  background: linear-gradient(135deg, #d4af37, #b8860b);
  color: #1a0b2e;
  font-weight: 700;
  font-size: .85rem;
  text-decoration: none;
}
html[data-tema="claro"] .lua-bloqueio { color: #b22974; }

/* o cartão da lua é ele próprio o botão para os Reflexos Lunares */
.cartao-lua { cursor: pointer; transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; -webkit-tap-highlight-color: transparent; }
.cartao-lua:hover, .cartao-lua:focus-visible { border-color: rgba(207, 159, 63, .6); outline: none; }
.cartao-lua:active { transform: scale(.985); }
.cartao-lua.bloqueado { cursor: default; }
.cartao-lua.bloqueado:active { transform: none; }
.lua-convite { font-size: .85rem; font-weight: 700; color: var(--gold-bright, #f5d77a); letter-spacing: .02em; }

/* botão "Desbloquear 1 acesso por X 💎" e mensagem */
.custom-modal-content .aviso-cristais {
  background: linear-gradient(135deg, rgba(212, 175, 55, .55), rgba(155, 89, 182, .45));
  border-color: rgba(255, 255, 255, .45);
  color: #fff;
  margin-bottom: 10px;
}
.custom-modal-content .aviso-cristais:disabled { opacity: .7; cursor: wait; }
.custom-modal-content .aviso-cristais-msg { font-size: .88rem; margin: -2px 0 12px; line-height: 1.45; }
