@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@600;800&family=Rajdhani:wght@600;700&display=swap');

* { box-sizing: border-box; margin: 0; padding: 0; user-select: none; }

body {
  width: 100vw;
  height: 100vh;
  background: #050508;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  font-family: 'Rajdhani', sans-serif;
  overflow: hidden;
  color: #fff;
}

.game-title {
  position: absolute;
  top: 10px;
  left: 20px;
  font-family: 'Orbitron', sans-serif;
  color: #00f0ff;
  font-size: 1.2rem;
  letter-spacing: 2px;
  text-shadow: 0 0 8px #00f0ff;
}

/* Banner do Evento */
.event-banner {
  position: absolute;
  top: 15px;
  left: 50%;
  transform: translateX(-50%) translateY(-100px);
  background: linear-gradient(90deg, #ffe600, #ff0055);
  color: #000;
  font-family: 'Orbitron', sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  padding: 12px 24px;
  border-radius: 30px;
  box-shadow: 0 0 25px rgba(255, 230, 0, 0.9);
  opacity: 0;
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  pointer-events: none;
  z-index: 100;
  text-align: center;
}

.event-banner.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.game-dashboard {
  width: 1300px;
  max-width: 95vw;
  height: 840px;
  max-height: 94vh;
  background: rgba(8, 12, 22, 0.95);
  border: 1px solid rgba(0, 240, 255, 0.3);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  padding: 8px;
  box-shadow: 0 0 30px rgba(0, 240, 255, 0.15);
}

.top-bar {
  height: 60px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.btn-home {
  background: rgba(255, 255, 255, 0.08);
  color: #00f0ff;
  border: 1px solid rgba(0, 240, 255, 0.3);
  padding: 8px 14px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-family: 'Orbitron', sans-serif;
}

.mode-selector { display: flex; gap: 4px; background: #000; padding: 4px; border-radius: 8px; }
.btn-mode {
  background: transparent;
  color: #aaa;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Orbitron', sans-serif;
  font-size: 0.8rem;
}
.btn-mode.active { background: #00f0ff; color: #000; font-weight: bold; }

/* Info do Nível */
.level-info {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.9rem;
  color: #a855f7;
  background: rgba(168, 85, 247, 0.1);
  border: 1px solid #a855f7;
  padding: 8px 14px;
  border-radius: 10px;
  text-shadow: 0 0 8px rgba(168, 85, 247, 0.6);
}

.timer-container, .score-box {
  height: 48px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: 'Orbitron', sans-serif;
  font-weight: 800;
  padding: 0 14px;
  background: rgba(5, 10, 20, 0.9);
  border: 2px solid #00f0ff;
  color: #00f0ff;
}

.score-container { display: flex; gap: 8px; }
.pvp-only { display: none; }
.score-box.active-player { border-color: #ffe600; box-shadow: 0 0 10px rgba(255, 230, 0, 0.5); }

.controls-container { margin-left: auto; }
.ui-button { font-family: 'Orbitron', sans-serif; padding: 8px 16px; border: none; border-radius: 8px; cursor: pointer; font-weight: bold; }
.btn-skip { background: #ff007f; color: #fff; }

/* Grid */
.cards-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: repeat(5, 1fr);
  gap: 3px;
  perspective: 1000px;
}

.card {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.5s ease;
  cursor: pointer;
}

.card.flipped { transform: rotateY(180deg); }

.card-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Orbitron', sans-serif;
  border: 2px solid rgba(0, 240, 255, 0.3);
}

.card-back {
  background: linear-gradient(135deg, #0d1b2a, #1b263b);
  color: #00f0ff;
  font-size: 1.8rem;
  box-shadow: inset 0 0 12px rgba(0, 240, 255, 0.2);
}

.card-back::after { content: '❓'; }

.card-front {
  background: #ffffff;
  transform: rotateY(180deg);
  font-size: 3.8rem;
  border-color: #00f0ff;
}

.card.matched .card-front {
  background: #e2f8ff;
  border-color: #00ff88;
  box-shadow: 0 0 12px rgba(0, 255, 136, 0.4);
}

/* Modal */
.modal { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.85); justify-content: center; align-items: center; z-index: 100; }
.modal-content { background: #0f172a; padding: 30px; border-radius: 16px; border: 2px solid #00f0ff; text-align: center; max-width: 500px; }
.modal-content h2 { font-family: 'Orbitron', sans-serif; color: #00f0ff; margin-bottom: 15px; }
.modal-content p { color: #cbd5e1; margin-bottom: 10px; font-size: 1.1rem; }
.button-group { display: flex; gap: 12px; justify-content: center; margin-top: 20px; }
.btn { font-family: 'Orbitron', sans-serif; padding: 12px 24px; background: linear-gradient(135deg, #00f0ff, #0088ff); border: none; border-radius: 10px; cursor: pointer; font-weight: bold; color: #000; font-size: 1rem; }
.btn:hover { transform: scale(1.05); box-shadow: 0 0 25px rgba(0, 240, 255, 0.6); }

/* PLACAR GERAL */
.placar-geral {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9999;
  background: rgba(10, 10, 26, 0.92);
  border: 2px solid #00f0ff;
  border-radius: 12px;
  padding: 10px 16px;
  min-width: 180px;
  font-family: 'Orbitron', sans-serif;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.4), inset 0 0 15px rgba(0, 240, 255, 0.1);
  backdrop-filter: blur(8px);
}
.placar-titulo { color: #ffe600; font-size: 0.75rem; letter-spacing: 2px; text-align: center; margin-bottom: 6px; text-shadow: 0 0 8px rgba(255, 230, 0, 0.7); }
.placar-linha { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 4px; }
.placar-label { color: #ff007f; font-size: 0.7rem; letter-spacing: 1px; text-shadow: 0 0 6px rgba(255, 0, 127, 0.6); }
.placar-valor { color: #00f0ff; font-size: 1.1rem; font-weight: 800; text-shadow: 0 0 10px rgba(0, 240, 255, 0.8); }
.placar-rodada .placar-label { color: #a855f7; text-shadow: 0 0 6px rgba(168, 85, 247, 0.6); }
.placar-rodada .placar-valor { color: #a855f7; text-shadow: 0 0 10px rgba(168, 85, 247, 0.8); font-size: 0.95rem; }