@import url("https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;600&family=Press+Start+2P&display=swap");

:root {
  --bg-color: #0f172a;
  --surface-color: #1e293b;
  --surface-hover: #334155;
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;

  --accent-color: #10b981;
  --boss-color: #ef4444;
  --gold-color: #fbbf24;

  --font-texto: "Fira Code", monospace;
  --font-titulo: "Press Start 2P", cursive;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  background-color: var(--bg-color);
  background-image: 
    linear-gradient(rgba(16, 185, 129, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 185, 129, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  background-position: center center;
  color: var(--text-primary);
  font-family: var(--font-texto);
  line-height: 1.6;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

html, body, .conquistas {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28'%3E%3Cpath d='M3 3l8 20 4-8 8-4-20-8z' fill='%230f172a' stroke='%2310b981' stroke-width='2' stroke-linejoin='round'/%3E%3C/svg%3E") 3 3, auto !important;
}

/* 2. Cursor Hover: Mira Sniper Dourada (Para botões e links) */
a, a *, button, button *, .mapa-ponto, .mapa-ponto *, .npc-sprite, .npc-sprite *, .slot, .slot *, .toggle-btn, .btn-filtro, .conquista-item, .conquista-item *, .logo-link {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32'%3E%3Ccircle cx='16' cy='16' r='10' fill='none' stroke='%23fbbf24' stroke-width='2'/%3E%3Cpath d='M16 2v6m0 16v6m-14-14h6m16 0h6' stroke='%23fbbf24' stroke-width='2' stroke-linecap='round'/%3E%3Ccircle cx='16' cy='16' r='3' fill='%23ef4444'/%3E%3C/svg%3E") 16 16, pointer !important;
}

/* 3. Cursor de Loot: Diamante Épico Ciano (Para os itens escondidos) */
.loot-item, .loot-item * {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32'%3E%3Cpath d='M16 2l3 9 9 3-9 3-3 9-3-9-9-3 9-3z' fill='%230ff' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round'/%3E%3Ccircle cx='16' cy='16' r='4' fill='%23ffffff'/%3E%3C/svg%3E") 16 16, crosshair !important;
}

::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-color);
  border-left: 1px solid var(--surface-hover);
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent-color) 0%, var(--gold-color) 100%);
  border-radius: 4px;
  border: 2px solid var(--bg-color); /* Cria um efeito de "cápsula" */
}
::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #0ff 0%, var(--accent-color) 100%);
} 

a:focus-visible,
button:focus-visible {
  outline: 2px dashed var(--accent-color);
  outline-offset: 4px;
}

/* ==========================================
   TERMINAL DE ADMIN (HACKER STYLE)
   ========================================== */
.terminal-box {
  background: rgba(10, 15, 20, 0.95);
  border: 1px solid #0ff;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.1), inset 0 0 15px rgba(0, 255, 255, 0.05);
  border-radius: 8px;
  width: 90%;
  max-width: 550px;
  overflow: hidden;
  font-family: var(--font-texto);
  animation: popupShow 0.4s ease-out forwards;
}

.terminal-header {
  background: #0f172a;
  border-bottom: 1px solid #0ff;
  padding: 0.8rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.terminal-title {
  color: #0ff;
  font-size: 0.9rem;
  font-weight: bold;
}

.btn-fechar-terminal {
  background: transparent;
  border: none;
  color: #ef4444;
  cursor: pointer;
  font-size: 1.2rem;
  transition: transform 0.2s;
}

.btn-fechar-terminal:hover { 
  transform: scale(1.2); 
}

.terminal-body {
  padding: 1.5rem;
  position: relative;
}

/* Efeito de TV de Tubo / Scanlines dentro do terminal */
.terminal-body::before {
  content: "";
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(rgba(0, 255, 255, 0.03) 50%, transparent 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 10;
}

.terminal-text {
  color: #0ff;
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
}

.terminal-text span.offline { color: #ef4444; font-weight: bold; }
.terminal-text span.online { color: #10b981; font-weight: bold; }

.terminal-input {
  width: 100%;
  background: rgba(0, 20, 20, 0.6);
  border: 1px solid rgba(0, 255, 255, 0.3);
  color: #fff;
  padding: 0.8rem;
  margin-bottom: 1rem;
  border-radius: 4px;
  font-family: var(--font-texto);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.3s, box-shadow 0.3s;
  position: relative;
  z-index: 20;
}

.terminal-input:focus {
  border-color: #0ff;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.2);
}

.terminal-row {
  display: flex;
  gap: 1rem;
}

.btn-terminal {
  width: 100%;
  background: rgba(0, 255, 255, 0.1);
  border: 1px solid #0ff;
  color: #0ff;
  padding: 0.8rem;
  cursor: pointer;
  font-family: var(--font-texto);
  font-weight: bold;
  transition: all 0.3s;
  border-radius: 4px;
  position: relative;
  z-index: 20;
}

.btn-terminal:hover {
  background: rgba(229, 255, 0, 0.15); /* Fundo levemente preenchido em vez de sólido */
  color: #000; /* Texto branco para um contraste mais suave */
  box-shadow: 0 0 8px rgba(0, 255, 255, 0.4); /* Brilho reduzido pela metade e mais transparente */
}

.terminal-actions {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.btn-terminal.success { border-color: #10b981; color: #10b981; }
.btn-terminal.success:hover { background: #10b981; color: #000; box-shadow: 0 0 15px #10b981; }

.btn-terminal.danger { border-color: #ef4444; color: #ef4444; }
.btn-terminal.danger:hover { background: #ef4444; color: #000; box-shadow: 0 0 15px #ef4444; }

.terminal-box::-webkit-scrollbar {
  width: 6px;
}

.terminal-box::-webkit-scrollbar-track {
  background: rgba(10, 15, 20, 0.95);
  border-left: 1px solid rgba(0, 255, 255, 0.1);
}

.terminal-box::-webkit-scrollbar-thumb {
  background: #0ff;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.8);
}

.terminal-box::-webkit-scrollbar-thumb:hover {
  background: #fff;
}

.hidden {
  display: none !important;
}

.item-delete {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(239, 68, 68, 0.05);
  border: 1px solid rgba(239, 68, 68, 0.3);
  padding: 0.5rem 0.8rem;
  margin-bottom: 0.4rem;
  border-radius: 4px;
}

.item-delete-titulo {
  color: #fff;
  font-size: 0.85rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 75%;
}

.btn-deletar-item {
  background: #ef4444;
  color: #000;
  border: none;
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s;
}

.btn-deletar-item:hover {
  background: #fff;
  box-shadow: 0 0 10px #ef4444;
}

select.terminal-input {
  appearance: none;
  -webkit-appearance: none;
  background-color: rgba(0, 255, 255, 0.05);
  border: 1px solid #0ff;
  color: #0ff;
  cursor: pointer;
  font-weight: bold;
  letter-spacing: 1px;
  /* Seta customizada via código SVG direto no CSS */
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2300ffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1.2em;
  transition: all 0.3s ease;
  text-align-last: center; /* Centraliza o texto no Chrome/Edge */
}

/* Fundo escuro nas opções quando a lista abre */
select.terminal-input option {
  background-color: #0a0f14;
  color: #0ff;
  font-weight: bold;
}

/* 2. Select Principal de Injeção (Módulo - Amarelo/Dourado) */
#tipoDado {
  background-color: rgba(234, 179, 8, 0.1) !important;
  border-color: #eab308 !important;
  color: #eab308 !important;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23eab308' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e") !important;
  font-size: 1rem;
  text-transform: uppercase;
}

#tipoDado:focus, 
#tipoDado:hover {
  background-color: rgba(234, 179, 8, 0.2) !important;
  box-shadow: 0 0 15px rgba(234, 179, 8, 0.4), inset 0 0 10px rgba(234, 179, 8, 0.2) !important;
  outline: none;
}

#tipoDado option { color: #eab308; }

/* 3. Select de Exclusão (Lixeira - Vermelho) */
#tipoExclusao {
  background-color: rgba(239, 68, 68, 0.1) !important;
  border-color: #ef4444 !important;
  color: #ef4444 !important;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ef4444' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e") !important;
  margin-bottom: 0 !important;
}

#tipoExclusao:focus, 
#tipoExclusao:hover {
  background-color: rgba(239, 68, 68, 0.2) !important;
  box-shadow: 0 0 15px rgba(239, 68, 68, 0.4), inset 0 0 10px rgba(239, 68, 68, 0.2) !important;
  outline: none;
}

#tipoExclusao option { color: #ef4444; }

main {
  margin-top: 100px;
  padding: 0 2rem 4rem 2rem;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.insert-coin-overlay {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background-color: #050505; /* Preto profundo estilo tubo desligado */
  background-image: 
    radial-gradient(circle, transparent 20%, #000 120%),
    linear-gradient(rgba(16, 185, 129, 0.05) 1px, transparent 1px);
  background-size: 100% 100%, 4px 4px;
  z-index: 9999999; 
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.8s ease-out;
  cursor: pointer; /* O mouse vira uma mãozinha na tela toda */
}

.arcade-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.arcade-title {
  font-size: 3rem !important;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}

.arcade-subtitle {
  font-family: var(--font-titulo);
  color: var(--text-secondary);
  font-size: 0.8rem;
  letter-spacing: 2px;
  margin-bottom: 4rem;
}

.blinking-insert-coin {
  color: var(--gold-color);
  font-family: var(--font-titulo);
  font-size: 1.2rem;
  text-shadow: 0 0 15px var(--gold-color);
  animation: blinkCoin 1s step-end infinite;
}

/* O clássico efeito de piscar seco dos arcades */
@keyframes blinkCoin {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.fase {
  padding: 4rem 0;
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275), transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.fase.visivel {
  opacity: 1;
  transform: translateY(0);
}

.fase-header h2 {
  font-family: var(--font-titulo);
  font-size: 1.2rem;
  color: var(--gold-color);
  margin-bottom: 2rem;
  border-bottom: 2px dashed var(--surface-hover);
  padding-bottom: 1rem;
  display: inline-block;
  position: relative;
}

/* Brilho extra no título das fases */
.fase-header h2::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-color);
  transition: width 0.5s ease;
  box-shadow: 0 0 10px var(--accent-color);
}

.fase.visivel .fase-header h2::after {
  width: 100%;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.fullscreen-fase {
  min-height: calc(100vh - 100px);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==========================================
   HUD E NAVEGAÇÃO
   ========================================== */
.hud {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(12px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  border-bottom: 2px solid var(--surface-color);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

.hud-brand {
  display: flex;
  align-items: center;
}

.dev-level {
  font-family: var(--font-titulo);
  font-size: 1rem;
  margin-left: 25px;
  color: var(--accent-color);
  text-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
  animation: pulseNeon 2s infinite alternate;
}

@keyframes pulseNeon {
  from { text-shadow: 0 0 5px rgba(16, 185, 129, 0.5); }
  to { text-shadow: 0 0 15px rgba(16, 185, 129, 1), 0 0 25px rgba(16, 185, 129, 0.8); }
}

.xp-flutuante {
  position: fixed; 
  color: var(--accent-color);
  font-family: var(--font-titulo);
  font-size: 1.5rem;
  font-weight: bold;
  pointer-events: none; 
  z-index: 999999; 
  text-shadow: 0 0 10px var(--accent-color), 0 0 20px #fff;
  /* Tempo aumentado para 2.5s */
  animation: floatUpXP 2.5s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

/* Animação: Dá o pulo rápido, segura na tela subindo devagar e só some no final */
@keyframes floatUpXP {
  0% {
    opacity: 0;
    transform: translate(-50%, 0) scale(0.5);
  }
  15% { /* Pula e cresce rápido */
    opacity: 1;
    transform: translate(-50%, -30px) scale(1.2);
  }
  30% { /* Volta ao tamanho normal */
    opacity: 1;
    transform: translate(-50%, -50px) scale(1);
  }
  80% { /* Fica visível até os 80% do tempo subindo devagar */
    opacity: 1;
    transform: translate(-50%, -100px) scale(1);
  }
  100% { /* Desaparece suavemente no topo */
    opacity: 0;
    transform: translate(-50%, -140px) scale(1);
    filter: blur(2px);
  }
}

@keyframes levelUpPulse {
  0% { transform: scale(1); box-shadow: 0 0 0 rgba(251, 191, 36, 0); }
  50% { 
    transform: scale(1.15); 
    box-shadow: 0 0 20px rgba(251, 191, 36, 1); 
    background-color: var(--gold-color); 
    color: #000; 
  }
  100% { transform: scale(1); box-shadow: 0 0 0 rgba(251, 191, 36, 0); }
}

.level-up-glow {
  /* Faz o botão pulsar 2 vezes rapidamente */
  animation: levelUpPulse 0.6s ease-out 2; 
}

.hud-nav {
  background-image: 
    linear-gradient(rgba(0, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 20px 20px;
  background-position: center 0;
  /* Borda sutil para parecer uma tela de vidro */
  border-left: 1px solid rgba(0, 255, 255, 0.1);
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.hud-nav a {
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem;
  border-radius: 6px;
}

.hud-nav a:hover {
  color: var(--accent-color);
  transform: translateY(-2px);
}

/* 3. Animação de Ícones no Hover (Nav) */
.hud-nav a:hover i { 
  animation: bounceIcon 0.5s ease infinite alternate; 
}

@keyframes bounceIcon {
  from { transform: translateY(0); }
  to { transform: translateY(-3px); }
}

.btn-som {
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 1.2rem;
  cursor: pointer;
  margin: 0;
  padding: 0 0.5rem;
  transition: all 0.3s;
}

.btn-som:hover {
  color: var(--accent-color);
  transform: scale(1.2) rotate(10deg);
}

.btn-som.mutado {
  color: var(--boss-color);
}

.btn-menu {
  display: none;
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 1.8rem;
  cursor: pointer;
}

.btn-menu:hover {
  color: var(--accent-color);
}

.logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.header-logo {
  height: 45px;
  width: 40px;
  margin-left: 15px;
  object-fit: contain;
  filter: drop-shadow(0 0 5px rgba(16, 185, 129, 0.4));
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), filter 0.4s;
}

.header-logo:hover {
  transform: scale(1.15) rotate(-5deg);
  filter: drop-shadow(0 0 15px rgba(16, 185, 129, 0.9));
}

.btn-filtro, .toggle-btn {
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.btn-filtro:hover, .toggle-btn:hover {
  background: var(--accent-color);
  color: var(--bg-color);
  border-color: var(--accent-color);
  box-shadow: 0 5px 15px rgba(16, 185, 129, 0.4);
  transform: translateY(-3px);
}

/* 3. Animação de Ícones no Hover (Botões de Filtro/Toggle) */
.btn-filtro:hover i, .toggle-btn:hover i {
  animation: bounceIcon 0.5s ease infinite alternate;
}

.btn-filtro.btn-acao {
  background: var(--accent-color);
  color: var(--bg-color);
  box-shadow: 0 0 15px var(--accent-color);
  border-color: var(--accent-color);
}

/* ==========================================
   CARDS E EFEITOS
   ========================================== */
.card {
  background: var(--surface-color);
  border: 2px solid var(--surface-hover);
  border-radius: 8px;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), border-color 0.4s, box-shadow 0.4s;
}

/* EFEITO NOVO: Brilho passando pelo Card no Hover */
.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -150%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: skewX(-25deg);
  transition: all 0.6s ease;
  z-index: 1;
  pointer-events: none;
}

.card:hover::before {
  left: 150%;
}

.card:hover {
  transform: translateY(-8px);
  border-color: var(--accent-color);
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.2);
}

.card h3 {
  color: var(--accent-color);
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  position: relative;
  z-index: 2;
}

.card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  position: relative;
  z-index: 2;
}

.player-card {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

#inicio .player-card {
  position: relative;
}

#inicio .player-card .avatar {
  position: relative;
  z-index: 2;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  border: 4px solid var(--accent-color);
  background-color: var(--surface-color);
  margin-bottom: 1rem;
  object-fit: cover;
  transition: all 0.3s ease-in-out;
}

#inicio .player-card::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: calc(1.5rem - 4px);
  left: 50%;
  width: 158px;
  height: 158px;
  border-radius: 50%;
  background: conic-gradient(#0ff, #f0f, #0ff, #f0f, #0ff);
  opacity: 0;
  filter: blur(4px);
  transition: opacity 0.4s ease-in-out;
  transform: translateX(-50%);
  will-change: transform;
}

#inicio .player-card:hover .avatar {
  border-color: transparent;
  transform: scale(1.05); 
  box-shadow: none;
}

#inicio .player-card:hover::before {
  opacity: 1;
  animation: rotate-border 1.5s linear infinite;
}

@keyframes rotate-border {
  0% {
    transform: translateX(-50%) rotate(0deg);
  }
  100% {
    transform: translateX(-50%) rotate(360deg);
  }
}

/* ==========================================
   BOTÕES E COMPONENTES
   ========================================== */
button,
.btn-batalha,
.btn-reset,
.btn-toggle-tema {
  background: var(--surface-hover);
  color: var(--text-primary);
  border: 2px solid var(--text-secondary);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-family: var(--font-texto);
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  text-decoration: none;
  display: inline-block;
  margin-top: 1rem;
  position: relative;
  z-index: 2;
  overflow: hidden;
}

button:active, .btn-batalha:active {
  transform: scale(0.95);
}

.btn-acao {
  background: rgba(16, 185, 129, 0.1);
  color: var(--accent-color);
  border-color: var(--accent-color);
}

.btn-acao:hover, .btn-batalha:hover {
  background: var(--accent-color);
  color: var(--bg-color);
  box-shadow: 0 0 15px var(--accent-color);
  border-color: var(--accent-color);
  transform: translateY(-3px);
}

/* 3. Animação de Ícones no Hover (Botões Principais) */
.btn-acao:hover i, .btn-batalha:hover i {
  animation: bounceIcon 0.5s ease infinite alternate;
}

/* ==========================================
   SKILLS ANIMADAS
   ========================================== */
.skill-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.5rem;
  position: relative;
  z-index: 2;
}

.skill-header h3 {
  margin-bottom: 0;
  font-size: 1.1rem;
}

.skill-badge {
  font-size: 1.8rem;
  color: var(--accent-color);
  background: rgba(16, 185, 129, 0.1);
  padding: 0.6rem;
  border-radius: 8px;
  border: 1px solid var(--accent-color);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.2);
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
}

.card.skill:hover .skill-badge {
  transform: scale(1.15) rotate(10deg);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.8);
  background: rgba(16, 185, 129, 0.3);
}

.skill .barra {
  width: 100%;
  height: 14px;
  background: var(--bg-color);
  border-radius: 8px;
  margin-top: 1rem;
  overflow: hidden;
  border: 1px solid var(--surface-hover);
  position: relative;
  z-index: 2;
}

/* EFEITO NOVO: Barras de progresso com listras em movimento */
.skill .progresso {
  height: 100%;
  background-color: var(--accent-color);
  background-image: linear-gradient(
    45deg, 
    rgba(255, 255, 255, 0.15) 25%, 
    transparent 25%, 
    transparent 50%, 
    rgba(255, 255, 255, 0.15) 50%, 
    rgba(255, 255, 255, 0.15) 75%, 
    transparent 75%, 
    transparent
  );
  background-size: 1rem 1rem;
  border-radius: 6px;
  transition: width 1.5s cubic-bezier(0.22, 1, 0.36, 1);
  animation: moveStripes 1s linear infinite;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

@keyframes moveStripes {
  0% { background-position: 1rem 0; }
  100% { background-position: 0 0; }
}

/* ==========================================
   MINI-MAPA COM RADAR
   ========================================== */
.mini-mapa {
  position: fixed;
  left: 1.5rem;
  top: 40%;
  transform: translateY(-50%);
  z-index: 90;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.mapa-linha {
  position: absolute;
  top: 10px;
  bottom: 10px;
  width: 4px;
  background-color: var(--surface-hover);
  z-index: -1;
  border-radius: 2px;
}

.mapa-ponto {
  width: 40px;
  height: 40px;
  background-color: var(--surface-color);
  border: 3px solid var(--surface-hover);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 1rem;
 will-change: transform;
  transition: background-color 0.3s, box-shadow 0.3s !important;
  cursor: pointer;
  position: relative;
}

.mapa-ponto:hover {
  transform: scale(1.2);
  border-color: var(--accent-color);
  color: var(--accent-color);
}

.mapa-ponto.explorado {
  border-color: var(--accent-color);
  color: var(--accent-color);
  background-color: rgba(16, 185, 129, 0.1);
}

/* EFEITO NOVO: Pulso de Radar na Fase Atual */
.mapa-ponto.ativo {
  border-color: var(--gold-color);
  color: var(--gold-color);
  background-color: rgba(251, 191, 36, 0.2);
  transform: scale(1.1);
  animation: radarPulse 2s infinite;
}

@keyframes radarPulse {
  0% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.6); }
  70% { box-shadow: 0 0 0 15px rgba(251, 191, 36, 0); }
  100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); }
}

.slot:not(.preenchido)[data-tooltip]:hover::after,
.slot:not(.preenchido)[data-tooltip]:hover::before {
  opacity: 1 !important; 
  filter: grayscale(100%);
}

/* 2. Deixa as letras do texto "Slot Vazio (Loot 1/3)" mais apagadas, igual às conquistas */
.slot:not(.preenchido)[data-tooltip]::after {
  color: var(--text-secondary) !important;
}

/* ==========================================
   BOSS CARDS
   ========================================== */
.card.boss {
  border-color: #7f1d1d;
  background: linear-gradient(180deg, var(--surface-color) 0%, rgba(127, 29, 29, 0.1) 100%);
}

.card.boss:hover {
  border-color: var(--boss-color);
  box-shadow: 0 10px 25px rgba(239, 68, 68, 0.3);
}

.card.boss h3 {
  color: var(--boss-color);
  text-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
}

.card.boss[data-derrotado="true"] {
  filter: grayscale(1);
  opacity: 0.6;
  border-color: var(--surface-hover);
  background: var(--surface-color);
}

.card.boss[data-derrotado="true"]:hover {
  transform: translateY(-5px); /* Mantém uma interação suave */
  box-shadow: none;
}

.card.boss:not([data-derrotado="true"]):hover h3 {
  animation: glitch-anim-1 0.2s infinite linear alternate-reverse;
  color: #fff;
  text-shadow: -2px 0 var(--boss-color), 2px 0 #0ff;
}

/* ==========================================
   TEMA GAMEBOY (ULTRA 8-BIT EDITION)
   ========================================== */
body.theme-gameboy {
  /* Paleta Clássica do Gameboy DMG-01 */
  --bg-color: #8bac0f;
  --surface-color: #9bbc0f;
  --surface-hover: #306230;
  --text-primary: #0f380f;
  --text-secondary: #306230;
  --accent-color: #0f380f;
  --boss-color: #0f380f;
  --gold-color: #0f380f;

  /* Força a fonte primária a ser a pixelada */
  font-family: var(--font-titulo), 'Courier New', monospace;
  background-image: none;
  background-color: var(--bg-color);
}

/* 1. MATA TRANSIÇÕES MODERNAS (8-bit é duro e seco) */
body.theme-gameboy * {
  transition: none !important;
}

/* 2. EFEITO CRT / SCANLINES (Mais imersivo com a paleta verde) */
body.theme-gameboy::after {
  content: " ";
  display: block;
  position: fixed;
  top: 0; left: 0; bottom: 0; right: 0;
  background: linear-gradient(rgba(15, 56, 15, 0) 50%, rgba(15, 56, 15, 0.1) 50%);
  z-index: 9999999;
  background-size: 100% 4px;
  pointer-events: none;
}

/* 3. SCROLLBAR EM BLOCOS RETRÔ */
body.theme-gameboy::-webkit-scrollbar { width: 12px; }
body.theme-gameboy::-webkit-scrollbar-track { background: #8bac0f; border-left: 4px solid #0f380f; }
body.theme-gameboy::-webkit-scrollbar-thumb { background: #0f380f; }

/* 4. CARDS DE 8 BITS VERDADEIROS (Sem cantos arredondados) */
body.theme-gameboy .card, 
body.theme-gameboy .terminal-box,
body.theme-gameboy .npc-balao {
  border: 4px solid #0f380f !important;
  border-radius: 0 !important;
  background: #9bbc0f !important;
  box-shadow: 6px 6px 0px #0f380f !important;
  color: #0f380f !important;
}

/* Remove os brilhos neon modernos */
body.theme-gameboy .card::before,
body.theme-gameboy .terminal-box::before { display: none !important; }

/* 5. BOTÕES "CLICÁVEIS" (Física de 8-bit) */
body.theme-gameboy .btn,
body.theme-gameboy .btn-terminal,
body.theme-gameboy .btn-batalha,
body.theme-gameboy .btn-toggle-tema {
  background: #306230 !important;
  color: #9bbc0f !important;
  border: 4px solid #0f380f !important;
  border-radius: 0 !important;
  box-shadow: 4px 4px 0px #0f380f !important;
  text-transform: uppercase;
  font-weight: bold;
}

/* Hover: Inverte as cores */
body.theme-gameboy .btn:hover,
body.theme-gameboy .btn-terminal:hover,
body.theme-gameboy .btn-batalha:hover,
body.theme-gameboy .btn-toggle-tema:hover {
  background: #0f380f !important;
  color: #8bac0f !important;
}

/* Active (O Truque: O botão "afunda" e a sombra some quando clica) */
body.theme-gameboy .btn:active,
body.theme-gameboy .btn-terminal:active,
body.theme-gameboy .btn-batalha:active,
body.theme-gameboy .btn-toggle-tema:active {
  transform: translate(4px, 4px) !important;
  box-shadow: 0px 0px 0px #0f380f !important;
}

/* 7. HUD, MINIMAPA E MENUS */
body.theme-gameboy .hud, 
body.theme-gameboy .hud-nav,
body.theme-gameboy .mini-mapa {
  background: #9bbc0f !important; 
  border-color: #0f380f !important; 
  backdrop-filter: none !important;
  border-width: 4px !important;
}

body.theme-gameboy .dev-level,
body.theme-gameboy .hud nav a,
body.theme-gameboy .btn-som,
body.theme-gameboy .btn-menu,
body.theme-gameboy .mapa-ponto {
  color: #0f380f !important; 
  text-shadow: none !important; 
  background: #8bac0f !important;
  border: 4px solid #0f380f !important;
  border-radius: 0 !important;
}

/* Desliga a animação de radar suave, mantendo duro */
body.theme-gameboy .mapa-ponto.ativo {
  background: #0f380f !important;
  color: #9bbc0f !important;
  animation: none !important; 
}

/* 8. OCULTA ELEMENTOS QUE QUEBRAM A IMERSÃO */
body.theme-gameboy .loot-item,
body.theme-gameboy .slot,
body.theme-gameboy .mapa-linha { display: none !important; }

body.theme-gameboy [data-tooltip]::after {
  background: #0f380f !important; color: #8bac0f !important; border-radius: 0 !important; border: 2px solid #9bbc0f;
}
body.theme-gameboy [data-tooltip]::before { border-left-color: #9bbc0f !important; }

/* 1. Tira a caixa de volta do Nível (HUD) */
body.theme-gameboy .dev-level {
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
  padding: 0 !important;
}

/* 2. Tira a caixa da Logo (seja texto ou imagem) */
body.theme-gameboy .logo,
body.theme-gameboy .hud h1,
body.theme-gameboy .hud img {
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
}

/* 3. Tira a caixa de volta do Sprite do NPC (O personagem) */
body.theme-gameboy .npc-sprite,
body.theme-gameboy .npc-sprite img {
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
  /* Garante que o fundo dele fique invisível como num jogo antigo */
}

/* 1. O Botão de Reset (Agora 100% legível e bruto) */
body.theme-gameboy #resetJornada {
  background: #0f380f !important; /* Verde mais escuro */
  color: #9bbc0f !important;      /* Letra verde clara */
  border: 4px solid #0f380f !important;
  box-shadow: 4px 4px 0px #306230 !important;
  border-radius: 0 !important;
  text-transform: uppercase;
}

body.theme-gameboy #resetJornada:hover {
  background: #306230 !important;
  color: #8bac0f !important;
}

/* 2. O Painel Principal de Conquistas */
body.theme-gameboy .conquistas {
  background: #8bac0f !important; /* Fundo base da tela do Gameboy */
  border: 6px solid #0f380f !important;
  border-radius: 0 !important;
  box-shadow: -8px 8px 0px rgba(15, 56, 15, 0.8) !important; /* Sombra dura */
}

/* Títulos e textos dentro do painel */
body.theme-gameboy .conquistas h2,
body.theme-gameboy .conquistas p {
  color: #0f380f !important;
  font-family: var(--font-titulo), 'Courier New', monospace !important;
  text-shadow: none !important;
}

/* 3. Os Itens da Lista de Conquistas */
body.theme-gameboy .conquista-item {
  background: #9bbc0f !important;
  border: 4px solid #0f380f !important;
  border-radius: 0 !important;
  color: #0f380f !important;
  margin-bottom: 10px !important;
  box-shadow: 2px 2px 0px #0f380f !important;
}

/* Conquistas Desbloqueadas (Brilham mais na tela do Gameboy) */
body.theme-gameboy .conquista-item.desbloqueada {
  background: #9bbc0f !important;
  color: #0f380f !important;
}
body.theme-gameboy .conquista-item.desbloqueada i {
  color: #0f380f !important; /* Ícone do troféu escuro */
}

/* Conquistas Bloqueadas (Aparência apagada/tracejada) */
body.theme-gameboy .conquista-item.bloqueada {
  background: #306230 !important;
  color: #8bac0f !important;
  border: 4px dashed #0f380f !important; /* Borda tracejada de "falta descobrir" */
  box-shadow: none !important;
}
body.theme-gameboy .conquista-item.bloqueada i {
  color: #0f380f !important; /* Cadeado escuro */
}

/* 4. Botão de Fechar o Menu Mobile (X) */
body.theme-gameboy #fecharConquistasMobile {
  background: transparent !important;
  color: #0f380f !important;
  border: none !important;
  box-shadow: none !important;
}

body.theme-gameboy #fecharConquistasMobile:hover {
  transform: scale(1.2) !important;
  color: #306230 !important;
}

/* ==========================================
   ANIMAÇÕES E OVERLAYS (MANTIDOS INTACTOS)
   ========================================== */
.glitch-text { position: relative; display: inline-block; font-family: var(--font-titulo); font-size: 1.5rem; color: var(--accent-color); letter-spacing: 2px; margin-bottom: 1rem; }
.glitch-text::before, .glitch-text::after { content: attr(data-text); position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: transparent; opacity: 0; pointer-events: none; }
.glitch-text::before { left: 3px; text-shadow: -2px 0 #0ff; animation: glitch-anim-1 2s infinite linear alternate-reverse; }
.glitch-text::after { left: -3px; text-shadow: -2px 0 #f0f; animation: glitch-anim-2 3s infinite linear alternate-reverse; }
.player-card:hover .glitch-text::before, .player-card:hover .glitch-text::after { opacity: 1; }
@keyframes glitch-anim-1 { 0% { clip-path: inset(20% 0 80% 0); } 20% { clip-path: inset(60% 0 10% 0); } 40% { clip-path: inset(40% 0 50% 0); } 60% { clip-path: inset(80% 0 5% 0); } 80% { clip-path: inset(10% 0 70% 0); } 100% { clip-path: inset(30% 0 50% 0); } }
@keyframes glitch-anim-2 { 0% { clip-path: inset(10% 0 60% 0); } 20% { clip-path: inset(30% 0 20% 0); } 40% { clip-path: inset(70% 0 10% 0); } 60% { clip-path: inset(20% 0 50% 0); } 80% { clip-path: inset(50% 0 30% 0); } 100% { clip-path: inset(5% 0 80% 0); } }

.npc-container { position: fixed; bottom: 2rem; left: 2rem; z-index: 998; display: flex; flex-direction: column; align-items: flex-start; gap: 1rem; }
.npc-sprite { width: 70px; height: 70px; background: rgba(30, 41, 59, 0.8); border: 2px solid var(--accent-color); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 0 15px rgba(16, 185, 129, 0.4); animation: float 3s ease-in-out infinite; transition: transform 0.2s, box-shadow 0.2s; overflow: hidden; will-change: transform; }
.npc-sprite:hover { transform: scale(1.1); box-shadow: 0 0 25px rgba(16, 185, 129, 0.8); }
.npc-img { width: 80%; height: auto; object-fit: contain; image-rendering: pixelated; }
.npc-balao { background: rgba(15, 23, 42, 0.95); border: 2px solid var(--text-primary); border-radius: 8px 8px 8px 0; padding: 1rem 2rem 1rem 1rem; max-width: 250px; box-shadow: 4px 4px 0px var(--accent-color); position: relative; opacity: 1; visibility: visible; transform: translateY(0); transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s; }
.npc-balao.hidden { opacity: 0; visibility: hidden; pointer-events: none; transform: translateY(15px); }
.npc-balao p { font-size: 0.9rem; color: var(--text-primary); line-height: 1.4; margin: 0; }
.btn-fechar-npc { position: absolute; top: 5px; right: 5px; background: transparent; border: none; color: var(--boss-color); cursor: pointer; font-size: 1.2rem; padding: 0; margin: 0; }
.btn-fechar-npc:hover { transform: scale(1.1); color: #f87171; }
@keyframes float { 
  0% { transform: translateY(0px) scale(1); } 
  50% { transform: translateY(-10px) scale(1.05); } /* Ele "enche o peito" ao subir */
  100% { transform: translateY(0px) scale(1); } 
}

.progresso-jornada { position: fixed; top: 0; left: 0; width: 100%; height: 4px; background: transparent; z-index: 101; }
#barraProgresso { height: 100%; background: var(--accent-color); width: 0%; transition: width 0.1s ease-out; box-shadow: 0 0 10px var(--accent-color); }
.progresso-fases-container { height: 8px; background: var(--bg-color); border-radius: 4px; margin-top: 1rem; overflow: hidden; }
#barraFases { height: 100%; background: var(--gold-color); width: 0%; transition: width 0.5s ease; box-shadow: 0 0 10px rgba(251, 191, 36, 0.5); }

.filtros { display: flex; gap: 1rem; margin-bottom: 2rem; flex-wrap: wrap; }
.timeline { position: relative; max-width: 900px; margin: 0 auto; padding: 2rem 0; }
.timeline::after { content: ""; position: absolute; width: 4px; background-color: var(--surface-hover); top: 0; bottom: 0; left: 50%; margin-left: -2px; box-shadow: 0 0 8px var(--surface-hover); }
.timeline-item { padding: 10px 40px; position: relative; width: 50%; }
.timeline-item:nth-child(odd) { left: 0; }
.timeline-item:nth-child(even) { left: 50%; }
.timeline-icon { position: absolute; width: 45px; height: 45px; right: -22px; background-color: var(--bg-color); border: 4px solid var(--accent-color); border-radius: 50%; top: 15px; z-index: 1; display: flex; align-items: center; justify-content: center; color: var(--accent-color); font-size: 1.2rem; box-shadow: 0 0 10px rgba(16, 185, 129, 0.4); transition: transform 0.3s; }
.timeline-item:hover .timeline-icon { transform: scale(1.2) rotate(360deg); background: var(--accent-color); color: var(--bg-color); }
.timeline-item:nth-child(even) .timeline-icon { left: -22px; }
.timeline-content h4 { color: var(--gold-color); font-size: 1.1rem; margin-bottom: 0.2rem; }
.timeline-content .muted { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 1rem; }
.timeline-content .details { display: none; list-style-type: square; margin-left: 1.5rem; margin-bottom: 1rem; color: var(--text-primary); }
.timeline-content .details.open { display: block; animation: fadeIn 0.3s ease-in; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

.conquistas { position: fixed; right: 2rem; top: 130px; width: 250px; background: rgba(30, 41, 59, 0.8); border: 2px solid var(--surface-hover); padding: 1rem; border-radius: 8px; display: none; z-index: 110; backdrop-filter: blur(5px); }
.conquistas h2 { font-size: 1rem; color: var(--gold-color); margin-bottom: 1rem; }
#listaConquistas { list-style: none; margin-top: 1rem; display: flex; flex-direction: column; gap: 0.8rem; padding: 0; }
.conquista-item { display: flex; align-items: center; gap: 0.8rem; padding: 0.6rem; border-radius: 6px; background: var(--surface-color); border: 1px solid var(--surface-hover); transition: all 0.3s; font-size: 0.85rem; font-family: var(--font-texto); }
.conquista-item.desbloqueada { border-color: var(--gold-color); color: var(--gold-color); box-shadow: 0 0 10px rgba(251, 191, 36, 0.2); background: rgba(251, 191, 36, 0.1); }
.conquista-item.desbloqueada i { color: var(--gold-color); font-size: 1.1rem; text-shadow: 0 0 5px var(--gold-color); }
.conquista-item.bloqueada { color: var(--text-secondary); }
.conquista-item.bloqueada i, .conquista-item.bloqueada span { opacity: 0.5; filter: grayscale(100%); transition: opacity 0.3s; }
.conquista-item.bloqueada i { color: var(--surface-hover); font-size: 1.1rem; }
.conquista-item.bloqueada[data-tooltip]:hover::after,
.conquista-item.bloqueada[data-tooltip]:hover::before {
  opacity: 1 !important; 
  filter: grayscale(100%);
}
.conquistas:hover .conquista-item.bloqueada i, .conquistas:hover .conquista-item.bloqueada span { opacity: 0.8; }
.conquista-item:hover { z-index: 10; transform: translateX(-5px); }

.nav-icons { display: flex; align-items: center; justify-content: center; }
.btn-fechar-mobile { position: absolute; top: 2px; right: 12px; background: transparent; border: none; color: var(--boss-color); font-size: 1.2rem; cursor: pointer; display: none; padding: 0.5rem; }
.btn-fechar-mobile:hover { transform: scale(1.1); }
.conquistas.aberta { display: block !important; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 90%; max-width: 340px; max-height: 85vh; overflow-y: auto; z-index: 9999; background: #1e293b !important;backdrop-filter: none !important; 
  -webkit-backdrop-filter: none !important; border: 2px solid var(--gold-color); border-radius: 8px; box-shadow: 0 0 30px rgba(0, 0, 0, 0.9); padding: 1.5rem; }
.conquistas.aberta .btn-fechar-mobile { display: block; }
.conquistas.aberta::-webkit-scrollbar { width: 4px; }
.inventario-container { margin-top: 2rem; border-top: 2px dashed var(--surface-hover); padding-top: 1rem; }
.inventario-slots { display: flex; gap: 0.8rem; margin-top: 1rem; }
.slot { width: 45px; height: 45px; background: var(--bg-color); border: 2px solid var(--surface-hover); border-radius: 6px; display: flex; justify-content: center; align-items: center; color: var(--surface-hover); font-size: 1.2rem; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.slot.preenchido { border-color: var(--gold-color); color: var(--gold-color); background: rgba(251, 191, 36, 0.1); box-shadow: 0 0 15px rgba(251, 191, 36, 0.5); transform: scale(1.15); }
.loot-item { position: absolute; cursor: pointer; opacity: 0.2; font-size: 1.5rem; color: var(--text-secondary); transition: all 0.3s; z-index: 10; animation: floatLoot 2s ease-in-out infinite alternate; }
@keyframes floatLoot { from { transform: translateY(0px); } to { transform: translateY(-5px); } }
.loot-item:hover { opacity: 1; color: var(--gold-color); transform: scale(1.5) rotate(15deg) !important; text-shadow: 0 0 15px var(--gold-color); animation: none; }
#loot-chave { top: 20px; left: 20px; }
#loot-pergaminho { top: 10px; right: -40px; }
#loot-pocao { bottom: 20px; right: 50px; }

[data-tooltip] { position: relative; cursor: help; }
[data-tooltip]::before, [data-tooltip]::after { position: absolute; visibility: hidden; opacity: 0; transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); z-index: 999; pointer-events: none; }
[data-tooltip]::after { content: attr(data-tooltip); width: max-content; max-width: 220px; background: #0f172a !important; color: var(--text-primary); border: 1px solid var(--accent-color); padding: 0.6rem 0.8rem; border-radius: 6px; font-size: 0.75rem; font-family: var(--font-texto); line-height: 1.4; box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6); right: 110%; top: 50%; transform: translateY(-50%) translateX(15px); }
[data-tooltip]::before { content: ""; border: 6px solid transparent; border-left-color: var(--accent-color); right: calc(110% - 12px); top: 50%; transform: translateY(-50%) translateX(15px); }
[data-tooltip]:hover::before, [data-tooltip]:hover::after { visibility: visible; opacity: 1; transform: translateY(-50%) translateX(0); }

.notificacao { position: fixed; bottom: 2rem; right: -900px; background: var(--surface-color); border-left: 5px solid var(--gold-color); padding: 1rem 1.5rem; border-radius: 4px; box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8); display: flex; align-items: center; gap: 1rem; z-index: 999; transition: right 0.6s cubic-bezier(0.68, -0.55, 0.27, 1.55); }
.notificacao.show { right: 2rem; }
.notificacao i { color: var(--gold-color); font-size: 1.5rem; animation: pulseNeon 1s infinite alternate; }

.quest-overlay, .game-over-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; backdrop-filter: blur(8px); display: flex; align-items: center; justify-content: center; opacity: 1; visibility: visible; transition: opacity 0.5s ease; will-change: opacity, visibility; }
.quest-overlay.hidden, .game-over-overlay.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.quest-overlay { background: rgba(15, 23, 42, 0.85); z-index: 9999; }
.quest-box { background: var(--surface-color); border: 2px solid var(--gold-color); padding: 2.5rem 2rem; border-radius: 8px; max-width: 450px; text-align: center; box-shadow: 0 0 30px rgba(251, 191, 36, 0.3); animation: popupShow 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; }
.quest-actions { display: flex; gap: 1rem; justify-content: center; margin-top: 1.5rem; flex-wrap: wrap; }
.quest-actions button { margin-top: 0; }
.quest-overlay.aceitando { animation: flashFundo 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards !important; }
.quest-overlay.aceitando .quest-box { animation: acceptQuestExplosion 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards !important; pointer-events: none; }

@keyframes flashFundo { 0% { background: rgba(15, 23, 42, 0.85); } 50% { background: rgba(16, 185, 129, 0.6); } 100% { background: transparent; opacity: 0; } }
@keyframes acceptQuestExplosion { 0% { transform: scale(1); box-shadow: 0 0 30px rgba(251, 191, 36, 0.3); opacity: 1; } 30% { transform: scale(0.9); box-shadow: 0 0 50px var(--accent-color); } 60% { transform: scale(1.2); box-shadow: 0 0 100px var(--accent-color), 0 0 200px var(--accent-color); background: var(--accent-color); color: var(--bg-color); border-color: var(--accent-color); } 100% { transform: scale(1.8) translateY(-30px); opacity: 0; filter: blur(15px); } }

.game-over-overlay { background: rgba(0, 0, 0, 0.98); z-index: 10000;

.game-over-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin: auto; /* Força o elemento a ficar no meio absoluto */
}

.game-over-content button {
  margin-top: 2rem; /* Afasta o botão do texto para ficar simétrico */
} }
.game-over-overlay:not(.hidden) .game-over-content { animation: deathScreen 1.5s ease-out forwards; }
.game-over-content h2 { font-family: var(--font-titulo); font-size: 3.5rem; color: var(--boss-color); text-shadow: 0 0 20px rgba(239, 68, 68, 0.8); margin-bottom: 1rem; }
.game-over-content p { color: var(--text-secondary); font-size: 1.2rem; margin-bottom: 2rem; }
@keyframes popupShow { 0% { transform: scale(0.5); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes deathScreen { 0% { transform: scale(0.5); opacity: 0; filter: blur(10px); } 50% { transform: scale(1.05); filter: blur(0px); text-shadow: 0 0 40px red; } 100% { transform: scale(1); opacity: 1; } }
.quest-overlay.hidden .quest-box { transform: scale(0.8) translateY(30px); }
.quest-box h2 { color: var(--gold-color); margin-bottom: 1rem; font-family: var(--font-titulo); font-size: 1rem; line-height: 1.5; }
.quest-items { list-style: none; margin: 1.5rem 0; padding: 0; display: flex; flex-direction: column; gap: 0.8rem; text-align: left; display: inline-block; }
.quest-items li { color: var(--text-primary); font-size: 1.1rem; }
.quest-items i { color: var(--accent-color); width: 30px; text-align: center; font-size: 1.2rem; }
.quest-box button { margin-top: 1.5rem; font-size: 1rem; padding: 0.8rem 1.5rem; }

.final-card { text-align: center; max-width: 700px; width: 100%; padding: 3rem 2rem; border-color: var(--gold-color); box-shadow: 0 0 30px rgba(251, 191, 36, 0.15); }
.final-card .fase-header h2 { border-bottom: none; margin-bottom: 1rem; }
.contact-buttons { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin: 2.5rem 0; }
.contact-btn { display: flex; align-items: center; gap: 0.5rem; font-size: 1rem; padding: 0.8rem 1.5rem; background: var(--bg-color); border: 2px solid var(--surface-hover); color: var(--text-primary); border-radius: 8px; transition: all 0.3s ease; text-decoration: none; position: relative; overflow: hidden; z-index: 1; }
.contact-btn::before { content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255, 255, 255, 0.1); z-index: -1; transform: scaleY(0); transition: transform 0.3s ease; transform-origin: bottom; }
.contact-btn:hover::before { transform: scaleY(1); }
.contact-btn.whatsapp:hover { border-color: #25d366; color: #25d366; box-shadow: 0 0 20px rgba(37, 211, 102, 0.4); }
.contact-btn.github:hover { border-color: #ffffff; color: #ffffff; box-shadow: 0 0 20px rgba(255, 255, 255, 0.4); }
.contact-btn.linkedin:hover { border-color: #0a66c2; color: #0a66c2; box-shadow: 0 0 20px rgba(10, 102, 194, 0.4); }
.contact-btn.email:hover { border-color: #ea4335; color: #ea4335; box-shadow: 0 0 20px rgba(234, 67, 53, 0.4); }
.btn-reset { background: transparent; border-color: var(--boss-color); color: var(--boss-color); margin-top: 1rem; }
.btn-reset:hover { background: var(--boss-color); color: var(--text-primary); box-shadow: 0 0 20px rgba(239, 68, 68, 0.5); }

.site-footer { background-color: var(--surface-color); border-top: 2px solid var(--surface-hover); padding: 1.5rem 2rem; margin-top: 4rem; position: relative; z-index: 10; }
.footer-inner { max-width: 1200px; margin: 0 auto; display: flex; justify-content: center; align-items: center; }
.footer-brand { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; justify-content: center; }
.footer-logo { height: 50px; width: auto; object-fit: contain; filter: drop-shadow(0 0 5px rgba(16, 185, 129, 0.3)); transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.footer-logo:hover { transform: scale(1.1) translateY(-5px); filter: drop-shadow(0 5px 15px rgba(16, 185, 129, 0.6)); }
.footer-brand p { color: var(--text-secondary); font-size: 0.85rem; display: flex; align-items: center; gap: 0.5rem; }
.divisor { color: var(--surface-hover); }

/* ==========================================
   MEDIA QUERIES (RESPONSIVIDADE)
   ========================================== */
@media (min-width: 1300px) {
  .conquistas { display: block; }
  main { margin-right: 300px; }
  #btnConquistasToggle { display: none; }
}

@media (max-width: 1024px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .mini-mapa { top: 50%; display: flex; left: auto; right: 1.5rem; }
  [data-tooltip]::after { right: auto; left: 50%; top: 130%; transform: translateX(-50%) translateY(-10px); width: 220px; text-align: center; z-index: 99999; }
  [data-tooltip]::before { right: auto; left: 50%; top: calc(130% - 12px); transform: translateX(-50%) translateY(-10px); border: 6px solid transparent; border-bottom-color: var(--accent-color); }
  [data-tooltip]:hover::after, [data-tooltip]:hover::before { transform: translateX(-50%) translateY(0); }
  .conquistas.aberta { padding-bottom: 3.5rem; }
  #loot-pergaminho { top: 2rem; right: 10%; }
  .slot[data-tooltip]::after {
    top: auto !important;
    bottom: 140% !important; /* Vai para cima do quadradinho */
    left: 50% !important;
    transform: translateX(-50%) translateY(10px) !important;
  }
  
  /* Arruma a setinha (triângulo) para apontar para baixo em direção ao slot */
  .slot[data-tooltip]::before {
    top: auto !important;
    bottom: calc(140% - 12px) !important;
    left: 50% !important;
    transform: translateX(-50%) translateY(10px) !important;
    border: 6px solid transparent !important;
    border-top-color: var(--accent-color) !important; /* A cor fica na parte de cima agora */
    border-bottom-color: transparent !important;
  }

.inventario-slots .slot[data-tooltip]::after {
    width: 140px !important; 
    max-width: 140px !important;
    white-space: normal !important; /* Garante que o texto longo vai para a linha de baixo */
    text-align: center !important;
    padding: 10px !important;
    line-height: 1.3 !important;
  }

  /* 2. Slot 1 (Esquerda) - Alinha a caixa pela quina esquerda do botão */
  .inventario-slots .slot:nth-child(1)[data-tooltip]::after {
    left: 0 !important;
    right: auto !important;
    transform: translateY(10px) !important;
  }
  .inventario-slots .slot:nth-child(1)[data-tooltip]:hover::after {
    transform: translateY(0) !important;
  }

  /* 3. Slot 2 (Meio) - Continua perfeitamente centralizado */
  .inventario-slots .slot:nth-child(2)[data-tooltip]::after {
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) translateY(10px) !important;
  }
  .inventario-slots .slot:nth-child(2)[data-tooltip]:hover::after {
    transform: translateX(-50%) translateY(0) !important;
  }

  /* 4. Slot 3 (Direita) - Alinha a caixa pela quina direita do botão */
  .inventario-slots .slot:nth-child(3)[data-tooltip]::after {
    left: auto !important;
    right: 0 !important;
    transform: translateY(10px) !important;
  }
  .inventario-slots .slot:nth-child(3)[data-tooltip]:hover::after {
    transform: translateY(0) !important;
  }

  /* 5. A setinha (triângulo) continua acompanhando o centro exato de cada botão */
  .inventario-slots .slot[data-tooltip]::before {
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) translateY(10px) !important;
  }
  .inventario-slots .slot[data-tooltip]:hover::before {
    transform: translateX(-50%) translateY(0) !important;
  }

 .terminal-box {
    width: 85%;
    max-width: 500px;
    height: 90%; /* O limite que você definiu */
    overflow-y: auto; /* A MÁGICA: Cria a barra de rolagem vertical! */
  }
}

@media (max-width: 768px) {
  body { padding-bottom: 60px; }
  .hud { flex-direction: row; padding: 1rem; gap: 1rem; }
  .btn-menu { display: block; }
  .hud-nav { position: absolute; top: 100%; left: 0; width: 100%; background: rgba(15, 23, 42, 0.95); backdrop-filter: blur(8px); flex-direction: column; align-items: center; padding: 1.5rem; gap: 1.5rem; border-bottom: 2px solid var(--accent-color); transform: translateY(-150%); opacity: 0; pointer-events: none; transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); z-index: -1; }
  .hud-nav.menu-aberto { transform: translateY(0); opacity: 1; pointer-events: auto; }
  main { margin-top: 100px; padding: 0 1.5rem 2rem 1.5rem; }
  .grid { grid-template-columns: 1fr; }
  .fase-header h2 { font-size: 1rem; }
  .mini-mapa { display: flex; top: auto; bottom: 0; left: 0; width: 100%; transform: none; flex-direction: row; justify-content: center; gap: 1.2rem; background: var(--surface-color); padding: 0.5rem 0; border-top: 2px solid var(--surface-hover); z-index: 99; box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.5); }
  .mapa-linha { display: none; }
  .mapa-ponto { width: 35px; height: 35px; font-size: 0.85rem; border-width: 2px; }
  .fase, .site-footer { position: relative; }
  #loot-chave { top: 5rem; left: auto; right: 1.5rem; }
  #loot-pergaminho { top: 2rem; right: 1.5rem; }
  #loot-pocao { bottom: auto; top: 1.5rem; right: 1.5rem; }
  [data-tooltip]::after { right: auto; left: 50%; top: 130%; transform: translateX(-50%) translateY(-10px); width: 220px; text-align: center; z-index: 99999; }
  [data-tooltip]::before { right: auto; left: 50%; top: calc(130% - 12px); transform: translateX(-50%) translateY(-10px); border: 6px solid transparent; border-bottom-color: var(--accent-color); }
  [data-tooltip]:hover::after, [data-tooltip]:hover::before { transform: translateX(-50%) translateY(0); }
  .conquistas.aberta { padding-bottom: 3.5rem; }
  .npc-container { 
  position: fixed; 
  bottom: 80px !important; /* Levanta o NPC para dar bastante folga do minimapa */
    left: 1rem;
  z-index: 998; 
  display: flex; 
  flex-direction: column; 
  align-items: flex-start; 
  gap: 1rem; 
  /* NOVA REGRA: A caixa principal vira um fantasma e não bloqueia cliques! */
  pointer-events: none; 
}

.npc-sprite { 
  width: 70px; height: 70px; background: rgba(30, 41, 59, 0.8); border: 2px solid var(--accent-color); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 0 15px rgba(16, 185, 129, 0.4); animation: float 3s ease-in-out infinite; transition: transform 0.2s, box-shadow 0.2s; overflow: hidden; will-change: transform; 
  /* NOVA REGRA: O bonequinho em si continua sendo clicável */
  pointer-events: auto; 
}

.npc-balao { 
  background: rgba(15, 23, 42, 0.95); border: 2px solid var(--text-primary); border-radius: 8px 8px 8px 0; padding: 1rem 2rem 1rem 1rem; max-width: 250px; box-shadow: 4px 4px 0px var(--accent-color); position: relative; opacity: 1; visibility: visible; transform: translateY(0); transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s; 
  /* NOVA REGRA: O balão visível também é clicável (para podermos fechá-lo) */
  pointer-events: auto;
}
  .notificacao.show { right: 1rem; left: 1rem; bottom: 75px; }
  .timeline::after { left: 31px; }
  .timeline-item { width: 100%; padding-left: 70px; padding-right: 0; left: 0 !important; }
  .timeline-item:nth-child(even) .timeline-icon, .timeline-item:nth-child(odd) .timeline-icon { left: 8px; }
  .contact-buttons { flex-direction: column; }
  .contact-btn { justify-content: center; }
  .footer-brand { flex-direction: column; text-align: center; gap: 0.5rem; }
  .divisor { display: none; }
  .slot[data-tooltip]:hover::after, 
  .slot[data-tooltip]:hover::before {
    transform: translateX(-50%) translateY(0) !important;
  }

  .terminal-box {
    width: 95%;
    /* Se o formulário ficar muito grande, cria um scroll dentro do próprio terminal */
    max-height: 85vh; 
    overflow-y: auto; 
  }

  .terminal-header {
    padding: 0.8rem;
  }

  .terminal-title {
    font-size: 0.75rem; /* Diminui a fonte do "root@lucas-server" pra não quebrar a linha */
  }

  .terminal-body {
    padding: 1rem; /* Ganha um pouco mais de espaço útil nas bordas */
  }

  /* Quebra a linha de "Categoria e URL" para ficarem um embaixo do outro */
  .terminal-row {
    flex-direction: column;
    gap: 0; /* O gap é zerado porque o margin-bottom do input já faz o espaçamento */
  }

  /* Empilha os botões de Salvar e Sair e aumenta a área de clique para o dedo */
  .terminal-actions {
    flex-direction: column;
    gap: 0.8rem;
    margin-top: 1rem;
  }

  .btn-terminal {
    padding: 1rem;
    font-size: 0.95rem;
  }
  
  /* Mantém o efeito CRT (scanlines) fixo no fundo mesmo se o usuário rolar a tela */
  .terminal-body::before {
    position: fixed;
  }
  
}