/* style.css */
:root {
    --bg-dark: #0a0a12;
    --neon-blue: #00f7ff;
    --neon-blue-dim: rgba(0, 247, 255, 0.3);
    --neon-cyan: #e0ffff;
    --neon-red: #ff2a6d;
    --neon-green: #05ffa1;
    --neon-pink: #ff00ff;
    --glass-bg: rgba(10, 20, 30, 0.4);
}

* { margin: 0; padding: 0; box-sizing: border-box; user-select: none; }

body {
    background: #050505;
    font-family: 'Orbitron', sans-serif;
    height: 100vh;
    overflow: hidden;
    color: var(--neon-blue);
    touch-action: none;
}

/* --- FUNDO INTERATIVO --- */
#canvas-efeitos {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: -1;
    pointer-events: none;
    opacity: 0.6;
}

.interface-jogo {
    position: relative; z-index: 10;
    width: 100%; height: 100%;
    display: flex; flex-direction: column;
    justify-content: space-between; align-items: center;
    padding: 30px;
}

/* --- HUD --- */
.hud-top {
    display: flex; gap: 40px; padding: 15px 30px;
    background: var(--glass-bg); backdrop-filter: blur(4px);
    border-bottom: 1px solid var(--neon-blue-dim);
    border-radius: 0 0 20px 20px; margin-top: -30px;
}
.status-module { display: flex; flex-direction: column; align-items: center; width: 120px; }
.label { font-size: 0.6rem; color: rgba(255, 255, 255, 0.7); margin-bottom: 5px; letter-spacing: 2px; }
.bar-frame { width: 100%; height: 6px; background: rgba(255, 255, 255, 0.1); border-radius: 2px; overflow: hidden; }
.bar-fill { height: 100%; width: 100%; transition: width 0.5s; box-shadow: 0 0 10px currentColor; }
.energia { background: var(--neon-blue); } .fome { background: var(--neon-green); } .diversao { background: var(--neon-red); }

/* --- ROBÔ --- */
.robo-area { position: relative; display: flex; justify-content: center; align-items: center; pointer-events: none; }
.robo-area.repair-mode { cursor: crosshair; }

.robo-cabeca {
    pointer-events: auto; width: 280px; height: 200px;
    background: linear-gradient(145deg, #3a3a45, #1a1a22);
    border-radius: 40px; border: 3px solid #333;
    display: flex; flex-direction: column; align-items: center;
    padding-top: 30px; box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    transition: transform 0.1s, box-shadow 0.3s; position: relative;
}
.robo-cabeca.anim-pulo { animation: glitch-hop 0.4s ease; }
@keyframes glitch-hop { 0% { transform: scale(1); } 50% { transform: scale(0.95) translateY(10px); } 100% { transform: scale(1); } }
.visor-area { display: flex; gap: 20px; background: #000; padding: 15px; border-radius: 20px; border: 2px solid #333; }
.olho-tela { width: 70px; height: 70px; background: #050510; border-radius: 10px; position: relative; overflow: hidden; border: 1px solid rgba(0,247,255,0.2); }

.pupila-digital {
    position: absolute;
    top: 50%; left: 50%;
    width: 40%; height: 40%;
    background: var(--neon-blue);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--neon-blue);
    transition: transform 0.2s ease-out; 
    transform: translate(-50%, -50%);
}

.palpebra-digital {
    position: absolute;
    top: -100%; left: 0;
    width: 100%; height: 100%;
    background-color: #1a1a2e;
    z-index: 10;
    transition: top 0.3s;
}

.antena { position: absolute; top: -30px; width: 8px; height: 30px; background: #333; }
.luz-antena { width: 15px; height: 15px; background: var(--neon-blue); border-radius: 50%; position: absolute; top: -10px; left: -3.5px; box-shadow: 0 0 10px var(--neon-blue); transition: background 0.3s; }

/* --- BOCA DIGITAL (EQUALIZADOR) --- */
#boca-robo {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
    z-index: 10;
}

.voice-bar {
    width: 6px;
    height: 4px; 
    background-color: var(--neon-blue);
    border-radius: 2px;
    box-shadow: 0 0 5px var(--neon-blue);
    transition: all 0.1s ease;
}

.falando .voice-bar {
    background-color: var(--neon-cyan);
    box-shadow: 0 0 10px var(--neon-cyan);
    animation: voice-wave 0.5s infinite ease-in-out;
}

@keyframes voice-wave {
    0%, 100% { height: 4px; }
    50% { height: 25px; } 
}

.falando .voice-bar:nth-child(1) { animation-duration: 0.4s; }
.falando .voice-bar:nth-child(2) { animation-duration: 0.5s; }
.falando .voice-bar:nth-child(3) { animation-duration: 0.35s; }
.falando .voice-bar:nth-child(4) { animation-duration: 0.5s; }
.falando .voice-bar:nth-child(5) { animation-duration: 0.4s; }

.tonto #boca-robo .voice-bar {
    background-color: var(--neon-red);
    box-shadow: 0 0 10px var(--neon-red);
}

.robo-cabeca.dormindo { filter: brightness(0.5); }

/* --- REPARO & ITENS --- */
.oleo { position: absolute; width: 50px; height: 50px; background: radial-gradient(circle, #000 30%, #333 100%); border-radius: 50%; opacity: 0.9; filter: drop-shadow(0 0 5px #000); z-index: 20; display: none; pointer-events: auto; }
#oleo-1 { top: 10px; left: 10px; transform: scale(1.2); } #oleo-2 { bottom: 20px; right: 10px; transform: scale(0.8) skew(20deg); }
#item-drop { position: absolute; font-size: 3rem; color: var(--neon-blue); text-shadow: 0 0 20px var(--neon-blue); z-index: 30; top: -50px; transition: top 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.5s; }
.hidden { opacity: 0; pointer-events: none; }

.repair-layer { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 50; pointer-events: none; }
.spark-glitch { position: absolute; width: 40px; height: 40px; background: #fff; pointer-events: auto; cursor: crosshair; clip-path: polygon(20% 0%, 80% 0%, 100% 20%, 60% 100%, 0% 100%, 20% 60%); background: linear-gradient(135deg, #ffeb3b, #ff9800); box-shadow: 0 0 15px #ff9800; animation: tremer 0.1s infinite; }
@keyframes tremer { 0% { transform: translate(0, 0) rotate(0deg); } 25% { transform: translate(2px, 2px) rotate(5deg); } 50% { transform: translate(-2px, -2px) rotate(-5deg); } 75% { transform: translate(-2px, 2px) rotate(5deg); } 100% { transform: translate(2px, -2px) rotate(-5deg); } }
.consertado-fx { position: absolute; width: 50px; height: 50px; border: 2px solid var(--neon-blue); border-radius: 50%; animation: ripple 0.5s ease-out forwards; pointer-events: none; }
@keyframes ripple { 0% { transform: scale(0); opacity: 1; border-width: 5px; } 100% { transform: scale(2); opacity: 0; border-width: 0px; } }

/* --- CONTROLES (BOTÕES) --- */
.painel-controle { display: flex; justify-content: center; gap: 20px; width: 100%; background: transparent; z-index: 100; }
.btn-tech { background: var(--glass-bg); backdrop-filter: blur(5px); color: rgba(255, 255, 255, 0.8); padding: 12px 25px; font-family: 'Orbitron'; font-size: 0.7rem; cursor: pointer; border: none; border-bottom: 2px solid var(--neon-blue-dim); clip-path: polygon(10% 0, 100% 0, 100% 70%, 90% 100%, 0 100%, 0 30%); display: flex; flex-direction: column; align-items: center; gap: 8px; transition: all 0.3s ease; min-width: 80px; }
.btn-tech:hover { background: rgba(0, 247, 255, 0.15); border-bottom: 2px solid var(--neon-blue); color: #fff; transform: translateY(-3px); }
.btn-tech:active { transform: scale(0.95); }
.icon { font-size: 1.2rem; }

/* --- BOLA --- */
.bola { width: 60px; height: 60px; background: radial-gradient(circle at 30% 30%, #fff, var(--neon-red)); border-radius: 50%; position: absolute; box-shadow: 0 0 20px var(--neon-red), inset 0 0 10px #000; cursor: grab; z-index: 100; top: 50%; left: 50%; transform: translate(-50%, -50%); will-change: transform, left, top; transition: transform 0.1s; }
.bola:active { cursor: grabbing; transform: translate(-50%, -50%) scale(1.1); box-shadow: 0 0 40px var(--neon-red); }
.robo-cabeca.feliz { border-color: var(--neon-red); box-shadow: 0 0 30px var(--neon-red); transform: scale(0.95); }

/* --- CHAT --- */
.chat-layer { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 200; background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(5px); display: flex; justify-content: center; align-items: center; animation: fadeIn 0.3s ease; }
.chat-window { width: 90%; max-width: 400px; height: 500px; background: rgba(10, 20, 30, 0.9); border: 1px solid var(--neon-blue); box-shadow: 0 0 30px rgba(0, 247, 255, 0.2); border-radius: 15px; display: flex; flex-direction: column; overflow: hidden; }
.chat-header { background: rgba(0, 247, 255, 0.1); padding: 15px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--neon-blue-dim); font-size: 0.8rem; }
.btn-close { background: none; border: none; color: var(--neon-red); font-size: 1.2rem; cursor: pointer; }
.chat-messages { flex: 1; padding: 15px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; font-family: 'Courier New', monospace; }
.msg { max-width: 80%; padding: 10px; border-radius: 5px; font-size: 0.9rem; }
.msg.robo { align-self: flex-start; background: rgba(0, 247, 255, 0.1); border-left: 3px solid var(--neon-blue); color: #fff; }
.msg.user { align-self: flex-end; background: rgba(255, 255, 255, 0.1); border-right: 3px solid #fff; color: #ccc; text-align: right; }
.chat-input-area { padding: 15px; display: flex; gap: 10px; background: rgba(0,0,0,0.3); }
#user-input { flex: 1; background: transparent; border: 1px solid #444; color: #fff; padding: 10px; border-radius: 5px; outline: none; font-family: 'Orbitron'; }
.chat-input-area button { background: var(--neon-blue); color: #000; border: none; padding: 10px 20px; border-radius: 5px; cursor: pointer; font-weight: bold; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* --- BARRA DE CHAT --- */
.chat-input-bar {
    position: absolute;
    bottom: 100px;
    width: 90%; max-width: 500px;
    background: rgba(10, 20, 30, 0.8); backdrop-filter: blur(10px);
    border: 1px solid var(--neon-blue); border-radius: 30px;
    padding: 10px 20px;
    display: flex; align-items: center; gap: 10px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    z-index: 200;
    transition: transform 0.3s, opacity 0.3s;
}

.chat-input-bar.hidden { transform: translateY(20px); opacity: 0; pointer-events: none; }
#user-input { flex: 1; background: transparent; border: none; color: #fff; font-family: 'Orbitron'; font-size: 0.9rem; outline: none; }
.chat-input-bar button { background: var(--neon-blue); border: none; border-radius: 50%; width: 35px; height: 35px; cursor: pointer; font-weight: bold; color: #000; display: flex; align-items: center; justify-content: center; }
.btn-close-small { background: transparent !important; border: 1px solid var(--neon-red) !important; color: var(--neon-red) !important; }

/* --- BALÃO DE FALA --- */
.balao {
    position: absolute; bottom: 110%; left: 50%;
    transform: translateX(-50%) scale(0.8);
    width: max-content; max-width: 250px;
    background: rgba(10, 15, 30, 0.95);
    border: 1px solid var(--neon-blue); color: #fff;
    padding: 15px; border-radius: 15px;
    text-align: center; font-size: 14px; line-height: 1.4;
    z-index: 100; box-shadow: 0 0 15px rgba(0, 247, 255, 0.3);
    opacity: 0; pointer-events: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.balao::after { content: ''; position: absolute; top: 100%; left: 50%; margin-left: -8px; border-width: 8px; border-style: solid; border-color: var(--neon-blue) transparent transparent transparent; }
.balao.visivel { opacity: 1; transform: translateX(-50%) scale(1); bottom: 120%; }

/* --- ROBÔ TONTO --- */
@keyframes shake-head { 0% { transform: rotate(0deg); } 25% { transform: rotate(15deg); } 50% { transform: rotate(-15deg); } 75% { transform: rotate(5deg); } 100% { transform: rotate(0deg); } }
@keyframes spin-eyes { 0% { transform: translate(-50%, -50%) rotate(0deg); } 100% { transform: translate(-50%, -50%) rotate(360deg); } }
.robo-cabeca.tonto { animation: shake-head 0.5s infinite ease-in-out; }
.robo-cabeca.tonto .pupila-digital { left: 50% !important; top: 50% !important; transform-origin: center center; width: 20px; height: 20px; background: var(--neon-red); box-shadow: 0 0 15px var(--neon-red); animation: spin-eyes 0.5s infinite linear !important; }

/* --- JOGOS NOVOS --- */
/* ========================================= */
/* --- GAME: CYBER EXTERMINADOR (NOVO) --- */
/* ========================================= */

/* O Inimigo (Vírus) */
.bug-digital {
    position: absolute;
    font-size: 35px; /* Maior para facilitar o toque */
    cursor: crosshair;
    user-select: none;
    z-index: 100;
    filter: drop-shadow(0 0 5px var(--neon-red));
    transition: transform 0.1s linear; /* Movimento fluido */
    will-change: top, left;
}

/* Efeito de Morte (Explosão) */
.bug-dead {
    pointer-events: none;
    animation: bug-explode 0.3s forwards;
}

@keyframes bug-explode {
    0% { transform: scale(1); opacity: 1; filter: hue-rotate(0deg); }
    50% { transform: scale(1.5); opacity: 0.8; filter: hue-rotate(90deg); }
    100% { transform: scale(2); opacity: 0; filter: hue-rotate(180deg); }
}

/* Placar Flutuante durante o jogo */
.game-score-panel {
    position: fixed;
    top: 80px; /* Abaixo do HUD */
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid var(--neon-red);
    color: var(--neon-red);
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 1.2rem;
    font-weight: bold;
    z-index: 150;
    box-shadow: 0 0 15px rgba(255, 42, 109, 0.3);
    pointer-events: none;
}

/* Efeito de Dano no Robô */
.robo-damage {
    animation: damage-shake 0.4s ease-in-out;
    filter: sepia(1) hue-rotate(-50deg) saturate(5) !important; /* Fica vermelho */
}

@keyframes damage-shake {
    0% { transform: translateX(0); }
    25% { transform: translateX(-10px) rotate(-5deg); }
    50% { transform: translateX(10px) rotate(5deg); }
    75% { transform: translateX(-10px); }
    100% { transform: translateX(0); }
}
body.modo-festa { animation: disco-flash 0.5s infinite; }
body.modo-festa #robo { filter: hue-rotate(90deg) drop-shadow(0 0 20px #fff); }

/* --- MENU NEON --- */
.menu-neon {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    background: rgba(0, 10, 20, 0.95); border: 2px solid var(--neon-blue);
    box-shadow: 0 0 20px var(--neon-blue); padding: 20px; border-radius: 15px;
    z-index: 2000; text-align: center; width: 250px; display: flex; flex-direction: column; gap: 10px;
}
.menu-neon h3 { color: var(--neon-blue); margin-bottom: 10px; text-shadow: 0 0 5px var(--neon-blue); }
.menu-neon button { background: transparent; border: 1px solid var(--neon-blue); color: #fff; padding: 10px; cursor: pointer; border-radius: 8px; font-family: inherit; transition: 0.3s; }
.menu-neon button:hover { background: var(--neon-blue); color: #000; box-shadow: 0 0 15px var(--neon-blue); }
.menu-neon .btn-fechar { border-color: var(--neon-red); color: var(--neon-red); margin-top: 10px; }
.menu-neon .btn-fechar:hover { background: var(--neon-red); color: #fff; box-shadow: 0 0 15px var(--neon-red); }
.hidden { display: none !important; }

/* --- RECARGA ÉPICA --- */
@keyframes electric-shake {
    0% { transform: translate(1px, 1px) rotate(0deg); filter: brightness(1) hue-rotate(0deg); }
    10% { transform: translate(-3px, -2px) rotate(-1deg); }
    20% { transform: translate(-3px, 0px) rotate(1deg); filter: brightness(2) hue-rotate(90deg) drop-shadow(0 0 20px yellow); }
    30% { transform: translate(3px, 2px) rotate(0deg); }
    40% { transform: translate(1px, -1px) rotate(1deg); }
    50% { transform: translate(-1px, 2px) rotate(-1deg); filter: brightness(3) hue-rotate(180deg) drop-shadow(0 0 40px cyan); }
    60% { transform: translate(-3px, 1px) rotate(0deg); }
    70% { transform: translate(3px, 1px) rotate(-1deg); }
    80% { transform: translate(-1px, -1px) rotate(1deg); filter: brightness(2) hue-rotate(270deg) drop-shadow(0 0 20px magenta); }
    90% { transform: translate(1px, 2px) rotate(0deg); }
    100% { transform: translate(1px, -2px) rotate(-1deg); filter: brightness(1) hue-rotate(0deg); }
}
.modo-carga { animation: electric-shake 0.3s infinite; }
.raio-particle { position: absolute; font-size: 40px; pointer-events: none; animation: subir-sumir 1s forwards; z-index: 1000; text-shadow: 0 0 10px #ffff00; }
@keyframes subir-sumir { 0% { transform: scale(0.5) translateY(0); opacity: 1; } 100% { transform: scale(1.5) translateY(-100px); opacity: 0; } }

/* --- CORREÇÃO DA BOLA --- */
#bola, .bola, .bola-neon { z-index: 5000 !important; }

/* ========================================= */
/* --- MINIGAME DE FIOS (CORREÇÃO DE CLIQUE) --- */
/* ========================================= */
.wire-panel { 
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); 
    width: 320px; height: 350px; background: #1a1a1d; border: 2px solid #444; border-radius: 10px; 
    display: flex; justify-content: space-between; padding: 20px; box-shadow: 0 0 30px rgba(0,0,0,0.9); 
    z-index: 2000; user-select: none;
    /* AQUI ESTÁ A CORREÇÃO: Garante que o jogo receba o clique, não o robô */
    pointer-events: auto !important; 
}
.wire-column { display: flex; flex-direction: column; justify-content: space-around; width: 60px; z-index: 20; }
.wire-socket { 
    width: 100%; height: 40px; background: #333; border: 2px solid #555; position: relative; cursor: pointer; box-shadow: inset 0 0 5px #000; 
    pointer-events: auto; /* Garante clique no soquete */
}
.wire-socket::after { content: ''; position: absolute; width: 15px; height: 15px; border-radius: 50%; top: 50%; transform: translateY(-50%); background: inherit; border: 2px solid #fff; }
.wire-column.left .wire-socket::after { right: -10px; }
.wire-column.right .wire-socket::after { left: -10px; }
.wire-svg-container { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 10; pointer-events: none; }
.wire-red { background: #e74c3c; box-shadow: 0 0 10px #e74c3c; }
.wire-blue { background: #3498db; box-shadow: 0 0 10px #3498db; }
.wire-yellow { background: #f1c40f; box-shadow: 0 0 10px #f1c40f; }
.wire-green { background: #2ecc71; box-shadow: 0 0 10px #2ecc71; }

/* --- MODO FESTA & ESTILOS DE DANÇA --- */
.cx-som { position: absolute; bottom: 20%; width: 120px; height: 180px; background: #111; border: 3px solid #333; border-radius: 10px; z-index: 5; display: flex; justify-content: center; align-items: center; box-shadow: 0 0 20px rgba(0,0,0,0.8); }
.cx-som.esquerda { left: 10%; transform: rotate(5deg); }
.cx-som.direita { right: 10%; transform: rotate(-5deg); }
.woofer-frame { width: 90px; height: 90px; background: #222; border-radius: 50%; border: 2px solid var(--neon-pink); display: flex; justify-content: center; align-items: center; box-shadow: 0 0 10px var(--neon-pink); }
.woofer-cone { width: 70px; height: 70px; background: radial-gradient(circle, #444 0%, #000 100%); border-radius: 50%; border: 1px solid #555; transition: transform 0.05s ease; }
.modo-festa-luzes { animation: strobo 0.1s infinite; }
@keyframes strobo { 0% { background-color: #050510; } 50% { background-color: #1a0510; } 100% { background-color: #050510; } }

/* 1. O Clássico (Ginga de lado) */
@keyframes danca-ginga {
    0%, 100% { transform: rotate(0deg) translateX(0); }
    25% { transform: rotate(5deg) translateX(10px); }
    75% { transform: rotate(-5deg) translateX(-10px); }
}
/* 2. O Pulo (Batida forte) */
@keyframes danca-pulo {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-15px) scale(1.05); }
}
/* 3. O Twist (Giro rápido) */
@keyframes danca-twist {
    0% { transform: rotate(0deg); }
    25% { transform: rotate(10deg); }
    50% { transform: rotate(0deg); }
    75% { transform: rotate(-10deg); }
    100% { transform: rotate(0deg); }
}
/* 4. O Tremilique (Vibração Tech) */
@keyframes danca-tremilique {
    0% { transform: translate(1px, 1px); }
    25% { transform: translate(-1px, -2px); }
    50% { transform: translate(-3px, 0px); }
    75% { transform: translate(3px, 2px); }
    100% { transform: translate(1px, -1px); }
}

/* CLASSES DE DANÇA (JS vai alternar entre elas) */
.move-1 #robo { animation: danca-ginga 0.8s infinite ease-in-out; }
.move-2 #robo { animation: danca-pulo 0.4s infinite ease-out; }
.move-3 #robo { animation: danca-twist 0.6s infinite linear; }
.move-4 #robo { animation: danca-tremilique 0.2s infinite; }

.modo-festa-ativo .olho-digital { animation: pisca-colorido 0.5s infinite; }
@keyframes pisca-colorido {
    0% { background: var(--neon-blue); box-shadow: 0 0 10px var(--neon-blue); }
    50% { background: var(--neon-pink); box-shadow: 0 0 15px var(--neon-pink); }
    100% { background: var(--neon-green); box-shadow: 0 0 10px var(--neon-green); }
}

/* ========================================================= */
/* --- SISTEMA DE ANÚNCIOS INTELIGENTE & BOTÃO DE DOAÇÃO --- */
/* ========================================================= */

/* --- BOTÃO DE DOAÇÃO (DISCRETO / GHOST) --- */
.btn-donate {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(0, 247, 255, 0.2);
    color: rgba(0, 247, 255, 0.5);
    padding: 5px 12px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.6rem;
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 1px;
    text-transform: uppercase;
    z-index: 1000;
    transition: all 0.4s ease;
    backdrop-filter: blur(2px);
    display: flex; align-items: center; gap: 6px; cursor: pointer;
}
.btn-donate::before { content: '💎'; font-size: 0.8rem; filter: grayscale(100%); transition: 0.4s; }
.btn-donate:hover {
    background: rgba(0, 247, 255, 0.1);
    border-color: var(--neon-blue);
    color: #fff;
    box-shadow: 0 0 10px rgba(0, 247, 255, 0.2);
}
.btn-donate:hover::before { filter: grayscale(0%); transform: rotate(15deg); }

/* --- ANÚNCIOS LATERAIS (PC - PADRÃO) --- */
.ad-side {
    position: fixed; top: 50%; transform: translateY(-50%);
    width: 160px; height: 600px;
    z-index: 5;
    display: flex; flex-direction: column; align-items: center;
}
.ad-side.left { left: 10px; }
.ad-side.right { right: 10px; }

.ad-label-v { font-size: 0.5rem; color: var(--neon-blue-dim); letter-spacing: 2px; margin-bottom: 5px; transform: rotate(-90deg); white-space: nowrap; }
.ad-slot-v {
    width: 100%; height: 100%;
    background: rgba(0, 5, 10, 0.5); border: 1px dashed var(--neon-blue-dim);
    display: flex; justify-content: center; align-items: center;
    text-align: center; font-size: 0.7rem; color: rgba(255, 255, 255, 0.2);
    border-radius: 5px; transition: all 0.3s ease;
}
.ad-slot-v:hover { border-color: var(--neon-blue); box-shadow: 0 0 15px rgba(0, 247, 255, 0.1); }

/* --- ANÚNCIO DE RODAPÉ (MOBILE - CORRIGIDO) --- */
.ad-container { 
    display: flex !important;
    position: fixed !important; /* Garante que fica na tela */
    bottom: 0 !important; /* Cola no chão */
    left: 0 !important;
    width: 100% !important; /* Ocupa toda a largura */
    height: 60px !important;
    background: #000; /* Fundo preto pra destacar */
    border-top: 1px solid var(--neon-blue); /* Linha neon em cima */
    z-index: 2000 !important; /* Fica acima de tudo */
    transform: none !important; /* Remove centralização antiga que bugava */
    justify-content: center;
    padding-top: 5px;
    pointer-events: auto;
}
.ad-label { font-size: 0.5rem; color: var(--neon-blue-dim); letter-spacing: 2px; margin-bottom: 2px; position: absolute; top: -15px; left: 5px; }
.ad-slot {
    border: none !important;
    background: transparent !important;
    width: 320px;
    height: 50px;
}

/* ========================================= */
/* --- REGRAS DE EXIBIÇÃO (MEDIA QUERIES) --- */
/* ========================================= */

/* PC (Telas Grandes > 768px) */
@media (min-width: 769px) {
    .ad-container { display: none !important; }
    .ad-side { display: flex !important; }
}

/* MOBILE (Telas Pequenas <= 768px) */
@media (max-width: 768px) {
    /* Esconde as laterais */
    .ad-side { display: none !important; }
    
    /* Mostra o banner de baixo */
    .ad-container { display: flex !important; }

    /* Ajuste de Posição do Robô */
    #area-robo, .robo-area {
        position: absolute !important; left: 50% !important; top: 35% !important;
        transform: translate(-50%, -50%) !important; width: auto !important; height: auto !important;
    }
    .robo-cabeca, #robo { transform: scale(0.7) !important; margin: 0 !important; }

    /* SOBE OS BOTÕES PARA NÃO COBRIR O ANÚNCIO (CRÍTICO) */
    .painel-controle {
        width: 100% !important;
        position: fixed !important;
        bottom: 70px !important; /* Espaço livre de 70px para o banner */
        left: 0 !important;
        display: flex !important; flex-wrap: wrap !important; justify-content: center !important;
        gap: 8px !important; padding: 0 10px !important;
        box-sizing: border-box !important; z-index: 100 !important; background: transparent !important;
    }

    /* SOBE O CHAT */
    .chat-input-bar {
        position: fixed !important;
        bottom: 130px !important; 
        left: 0 !important; width: 100% !important; padding: 10px !important;
        z-index: 1000 !important; transform: none !important; background: #000 !important;
    }

    /* Botão VIP vira ícone pequeno no celular */
    .btn-donate { 
        top: 10px; right: 10px; padding: 4px 8px; 
        font-size: 0px; /* Esconde o texto */
        border: 1px solid rgba(255, 255, 255, 0.1); background: rgba(0,0,0,0.5);
    }
    .btn-donate::before { font-size: 1rem; margin: 0; } /* Mostra só o ícone */

    #user-input { font-size: 16px !important; }
    .hud-top { width: 96% !important; top: 15px !important; padding: 10px !important; }

    /* Ajuste caixas de som mobile */
    .cx-som { width: 80px; height: 120px; bottom: 55%; }
    .cx-som.esquerda { left: -10px; }
    .cx-som.direita { right: -10px; }
    .woofer-frame { width: 60px; height: 60px; }
    .woofer-cone { width: 45px; height: 45px; }
}

/* ========================================= */
/* --- SISTEMA PREMIUM (GOLD EDITION) --- */
/* ========================================= */

body.premium-mode {
    --neon-blue: #ffd700; 
    --neon-blue-dim: rgba(255, 215, 0, 0.3);
    --neon-cyan: #fffbe0;
}

body.premium-mode .ad-container,
body.premium-mode .ad-side {
    display: none !important;
}

body.premium-mode .btn-donate {
    border-color: rgba(255, 215, 0, 0.3);
    color: rgba(255, 215, 0, 0.6);
    pointer-events: none;
    background: transparent;
    box-shadow: none;
}
body.premium-mode .btn-donate::before { filter: none; content: '👑'; }

body.premium-mode .btn-tech {
    border-color: #ffd700 !important;
    color: #ffd700 !important;
}
body.premium-mode .btn-tech:hover {
    background: rgba(255, 215, 0, 0.2) !important;
    color: #fff !important;
}

/* ========================================= */
/* --- MODAL TERMINAL HACKER (NOVO) --- */
/* ========================================= */

.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85); backdrop-filter: blur(5px);
    z-index: 2000; display: flex; justify-content: center; align-items: center;
    animation: fadeIn 0.3s ease;
}

.terminal-window {
    width: 90%; max-width: 400px;
    background: #0a0a12; border: 1px solid var(--neon-blue);
    box-shadow: 0 0 30px rgba(0, 247, 255, 0.2); border-radius: 10px;
    font-family: 'Courier New', monospace; overflow: hidden;
    transform: scale(1); transition: transform 0.2s;
}

.terminal-header {
    background: rgba(0, 247, 255, 0.1); padding: 10px 15px;
    border-bottom: 1px solid var(--neon-blue-dim);
    display: flex; justify-content: space-between; align-items: center;
    color: var(--neon-blue); font-size: 0.8rem; font-weight: bold; letter-spacing: 1px;
}

.btn-close-terminal {
    background: transparent; border: none; color: var(--neon-red);
    cursor: pointer; font-size: 1.2rem;
}

.terminal-body { padding: 20px; display: flex; flex-direction: column; gap: 15px; }

.term-text, .term-list li { color: #ccc; font-size: 0.9rem; margin: 0; }
.term-list { padding-left: 20px; }

.term-link {
    color: var(--neon-green); text-decoration: none; font-weight: bold;
    text-align: center; border: 1px dashed var(--neon-green); padding: 10px;
    margin: 5px 0; transition: 0.3s;
}
.term-link:hover { background: rgba(5, 255, 161, 0.1); box-shadow: 0 0 10px var(--neon-green); }

.input-line {
    display: flex; align-items: center; background: #000;
    border: 1px solid #333; padding: 10px; border-radius: 5px;
}

.prompt-sign { color: var(--neon-green); margin-right: 10px; font-size: 0.8rem; }

#input-codigo {
    background: transparent; border: none; color: #fff; flex: 1; outline: none;
    font-family: 'Courier New', monospace; text-transform: uppercase;
}

.btn-hack {
    background: var(--neon-blue); color: #000; border: none; padding: 12px;
    font-weight: bold; font-family: 'Orbitron', sans-serif; cursor: pointer;
    transition: 0.3s; letter-spacing: 2px;
}
.btn-hack:hover { background: #fff; box-shadow: 0 0 15px #fff; }

.error-msg { color: var(--neon-red); font-weight: bold; text-align: center; animation: tremer 0.2s; }


/* --- BOTÃO DE MICROFONE --- */
#btn-mic {
    transition: all 0.3s ease;
    background: transparent;
    border: 1px solid var(--neon-blue);
    color: var(--neon-blue);
}

/* Classe ativada quando está ouvindo */
#btn-mic.ouvindo {
    background: var(--neon-red);
    color: #fff;
    border-color: var(--neon-red);
    box-shadow: 0 0 15px var(--neon-red);
    animation: pulso-mic 1s infinite;
}

@keyframes pulso-mic {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}


/* ========================================= */
/* --- ÁREA DE SUPORTE / FEEDBACK --- */
/* ========================================= */

.term-input-area {
    width: 100%;
    height: 100px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #333;
    color: #0f0; /* Texto verde terminal */
    font-family: 'Courier New', monospace;
    padding: 10px;
    resize: none; /* Impede arrastar */
    outline: none;
    margin-bottom: 10px;
}

.term-input-area:focus {
    border-color: var(--neon-green);
    box-shadow: 0 0 5px rgba(5, 255, 161, 0.2);
}

.feedback-options {
    display: flex;
    justify-content: space-around;
    margin-bottom: 15px;
    color: #ccc;
    font-size: 0.8rem;
    font-family: 'Orbitron';
}

.feedback-options label {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
}

.feedback-options input[type="radio"] {
    accent-color: var(--neon-blue); /* Cor da bolinha */
}


/* ========================================= */
/* --- CORREÇÃO DE ERROS A-ADS E CLIQUES --- */
/* ========================================= */

/* Força os anúncios laterais (PC) a ficarem ACIMA da interface do jogo */
.ad-side {
    z-index: 150 !important;
    pointer-events: auto !important;
}

/* Garante que o anúncio Mobile não seja coberto */
.ad-container {
    z-index: 150 !important;
    background-color: #000 !important;
    pointer-events: auto !important;
}

/* Ajuste de segurança para o iframe */
.ad-slot iframe, .ad-slot-v iframe {
    pointer-events: auto !important;
    display: block !important;
    z-index: 151 !important;
}

/* --- FIX DE CLIQUES (Importante) --- */
/* Adicionamos #bola e .bola aqui para garantir que funcione em qualquer tela */
.menu-neon, .chat-input-bar, #bola, .bola {
    pointer-events: auto !important;
    cursor: grab; /* Mostra a mãozinha na bola */
}

/* Garante que a interface do jogo não bloqueie cliques nas laterais (PC) */
@media (min-width: 769px) {
    .interface-jogo {
        width: calc(100% - 340px) !important;
        margin: 0 auto !important;
        pointer-events: none; /* A caixa do jogo é fantasma */
    }
    
    /* REATIVA CLIQUES NOS ELEMENTOS INTERNOS DO JOGO */
    /* Adicionamos #bola e .bola na lista de exceções */
    .painel-controle, .robo-cabeca, .hud-top, .btn-donate, .menu-neon, .chat-input-bar, #bola, .bola {
        pointer-events: auto !important;
    }
}


/* ========================================= */
/* --- ARENA JOKENPÔ (NOVO) --- */
/* ========================================= */

.jokenpo-arena {
    width: 95%; max-width: 500px;
    background: #0a0a15;
    border: 2px solid var(--neon-pink);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 0 50px rgba(255, 0, 255, 0.2);
    display: flex; flex-direction: column; align-items: center;
    position: relative;
    pointer-events: auto; /* Garante clique */
}

.jk-header {
    width: 100%; display: flex; justify-content: space-between;
    color: var(--neon-pink); font-size: 1.2rem; margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 0, 255, 0.3); padding-bottom: 10px;
}

.jk-battle-area {
    display: flex; justify-content: center; align-items: center; gap: 20px;
    margin-bottom: 20px; width: 100%;
}

.jk-side { display: flex; flex-direction: column; align-items: center; }

.jk-label { font-size: 0.8rem; color: #666; margin-bottom: 10px; letter-spacing: 2px; }

.jk-hand {
    font-size: 80px;
    transition: transform 0.2s;
}

/* Animação de Balançar (JO-KEN-PÔ) */
@keyframes shakeHandUser {
    0% { transform: rotate(90deg) translateX(0); }
    50% { transform: rotate(90deg) translateX(-20px); }
    100% { transform: rotate(90deg) translateX(0); }
}

@keyframes shakeHandBot {
    0% { transform: rotate(-90deg) scaleX(-1) translateX(0); }
    50% { transform: rotate(-90deg) scaleX(-1) translateX(-20px); }
    100% { transform: rotate(-90deg) scaleX(-1) translateX(0); }
}

/* Mão do Usuário (Vira pra direita) */
#hand-user { transform: rotate(90deg); }
.shaking #hand-user { animation: shakeHandUser 0.5s infinite; }

/* Mão do Bot (Vira pra esquerda) */
#hand-bot { transform: rotate(-90deg) scaleX(-1); }
.shaking #hand-bot { animation: shakeHandBot 0.5s infinite; }

.jk-vs { font-size: 2rem; color: #333; font-style: italic; font-weight: bold; }

.jk-result-text {
    font-size: 1.5rem; color: #fff; margin-bottom: 20px; min-height: 40px;
    text-shadow: 0 0 10px rgba(255,255,255,0.5);
}

.jk-controls { display: flex; gap: 10px; width: 100%; justify-content: center; }

.btn-jk {
    background: transparent;
    border: 1px solid var(--neon-blue);
    color: #fff;
    padding: 15px;
    border-radius: 10px;
    cursor: pointer;
    flex: 1;
    display: flex; flex-direction: column; align-items: center; gap: 5px;
    transition: 0.2s;
    font-family: 'Orbitron';
}

.btn-jk:hover { background: var(--neon-blue); color: #000; transform: translateY(-5px); }
.btn-jk:disabled { opacity: 0.5; cursor: not-allowed; filter: grayscale(1); }
.jk-icon { font-size: 1.5rem; }