* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}

body {
  min-height: 100vh;
  background: radial-gradient(circle at top, #3a1f0f, #0f0a07);
  color: #f5e6c8;
  display: flex;
  justify-content: center;
  align-items: center;
}

.container {
  width: 100%;
  max-width: 1200px;
  padding: 40px 20px;
}

h1 {
  text-align: center;
  font-size: 2.5rem;
  color: #e6c27a;
  margin-bottom: 40px;
}

.subtitulo {
  text-align: center;
  margin-bottom: 40px;
  opacity: 0.8;
}

.battlefield {
  display: grid;
  grid-template-columns: 180px minmax(320px, 1fr) auto minmax(320px, 1fr) 180px;
  gap: 20px;
  align-items: center;
  margin-bottom: 30px;
  justify-content: center;
}

.vs {
  font-size: 3rem;
  color: #e6c27a;
  text-align: center;
  animation: pulse 2s infinite;
  filter: drop-shadow(0 0 10px rgba(230, 194, 122, 0.6));
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.battle-card {
  background: linear-gradient(145deg, #2b1b13, #1a0f0a);
  border: 2px solid #8b5a2b;
  border-radius: 18px;
  padding: 25px;
  box-shadow:
    inset 0 0 25px rgba(139, 69, 19, 0.4),
    0 15px 40px rgba(0, 0, 0, 0.6);
}

.battle-card.atacante,
.battle-card.defensor {
  min-width: 320px;
}


.battle-card.atacante {
  border-left: 6px solid #b22222;
}

.battle-card.defensor {
  border-left: 6px solid #3b6ea5;
}

.battle-card h2 {
  text-align: center;
  margin-bottom: 20px;
  color: #e6c27a;
}

.battle-card input[type="text"],
.battle-card input[type="number"] {
  width: 100%;
  padding: 10px 14px;
  margin-bottom: 12px;
  border-radius: 8px;
  border: 1px solid #b88a44;
  background: linear-gradient(145deg, #1b0f08, #120904);
  color: #f5e6c8;
  box-shadow: inset 0 0 8px rgba(0, 0, 0, 0.6);
}

.battle-card input {
  font-size: 0.95rem;
}


.battle-card input::placeholder {
  color: #cbb890;
}

.battle-card input:focus {
  outline: none;
  border-color: #e6c27a;
  box-shadow: 0 0 12px rgba(230, 194, 122, 0.6);
}

.checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 10px;
  font-size: 0.9rem;
  border-radius: 10px;
  border: 1px solid rgba(59, 110, 165, 0.6);
  background: rgba(59, 110, 165, 0.1);
}

.vida-label {
  font-size: 0.85rem;
  opacity: 0.9;
  margin-bottom: 4px;
  display: inline-block;
}

.life-bar {
  width: 100%;
  height: 16px;
  background: #2a0b0b;
  border: 1px solid #8b2222;
  border-radius: 12px;
  overflow: hidden;
  margin: 6px 0 14px;
  box-shadow: inset 0 0 6px rgba(0,0,0,0.8);
}

.life-fill {
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #ff4d4d, #b22222);
  transition: width 0.4s ease;
}

.btn-batalha {
  display: block;
  margin: 30px auto;
  padding: 14px 40px;
  border-radius: 30px;
  border: none;
  background: linear-gradient(145deg, #b22222, #7a1414);
  color: #fff;
  font-size: 1rem;
  font-weight: bold;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.btn-batalha:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(178, 34, 34, 0.6);
  background: linear-gradient(145deg, #ff3b3b, #7a1414);
}

.resultado {
  text-align: center;
  margin-top: 20px;
  font-size: 1.1rem;
  min-height: 40px;
}

.flash {
  animation: flashCritico 0.3s ease;
}

@keyframes flashCritico {
  0% { background-color: rgba(255, 0, 0, 0.35); }
  100% { background-color: transparent; }
}

.critico {
  animation: shakeCritico 0.4s ease;
}

@keyframes shakeCritico {
  0% { transform: translate(0); }
  20% { transform: translate(-12px, 4px); }
  40% { transform: translate(12px, -4px); }
  60% { transform: translate(-10px, 2px); }
  80% { transform: translate(10px, -2px); }
  100% { transform: translate(0); }
}

.explosao {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  font-size: 6rem;
  pointer-events: none;
  z-index: 999;
  opacity: 0;
}

.explosao.ativa {
  animation: explosao 0.6s ease-out;
}

@keyframes explosao {
  0% { transform: translate(-50%, -50%) scale(0); opacity: 0; }
  30% { transform: translate(-50%, -50%) scale(1.6); opacity: 1; }
  100% { transform: translate(-50%, -50%) scale(2.4); opacity: 0; }
}

.sangue-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
}

.sangue {
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: radial-gradient(circle, #ff3b3b 20%, #7a0000 70%);
  filter: drop-shadow(0 0 8px rgba(255, 0, 0, 0.9));
  animation: sangueExplode 0.8s ease-out forwards;
}

@keyframes sangueExplode {
  0% { transform: scale(1) translate(0,0); opacity: 1; }
  100% { transform: scale(0.4) translate(var(--x), var(--y)); opacity: 0; }
}

.power-menu {
  background: linear-gradient(145deg, #1b0f08, #120904);
  border: 1px solid #b88a44;
  border-radius: 14px;
  padding: 15px;
  text-align: center;
  box-shadow: inset 0 0 15px rgba(0,0,0,0.6);
  align-self: center;
}

.power-menu h3 {
  margin-bottom: 10px;
  color: #f5d48e;
  font-size: 1rem;
}

.power-menu select {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  background: #120904;
  color: #f5d48e;
  border: 1px solid #b88a44;
}

@media (max-width: 768px) {
  .battlefield {
    grid-template-columns: 1fr;
  }

  .vs {
    display: none;
  }
}







