/* King James 2 — Battle UI */

.kj-battle {
  gap: 8px;
}
.kj-battle-enemies,
.kj-battle-party {
  display: flex;
  gap: 8px;
  justify-content: center;
  padding: 6px;
  flex-wrap: wrap;
}
.kj-cb-card {
  background: rgba(255,255,255,0.12);
  border: 2px solid rgba(255,255,255,0.25);
  border-radius: 12px;
  padding: 8px 6px;
  width: 100px;
  text-align: center;
  transition: opacity 0.3s;
}
.kj-cb-card.ko { opacity: 0.35; filter: grayscale(1); }
.kj-cb-emoji { font-size: 42px; line-height: 1; }
.kj-cb-name  { font-size: 12px; font-weight: bold; margin: 4px 0 6px; }
.kj-cb-hpbar {
  width: 100%;
  height: 10px;
  background: rgba(0,0,0,0.5);
  border-radius: 6px;
  overflow: hidden;
}
.kj-cb-hpfill {
  height: 100%;
  background: linear-gradient(90deg, #2ecc71, #f1c40f, #e74c3c);
  background-size: 200% 100%;
  background-position: 0% 0%;
  transition: width 0.35s;
}
.kj-cb-hpnum { font-size: 11px; margin-top: 3px; color: rgba(255,255,255,0.85); }

.kj-telegraph {
  background: rgba(231, 76, 60, 0.25);
  border: 2px solid #e74c3c;
  border-radius: 10px;
  padding: 8px 10px;
  margin: 6px 8px;
  font-weight: bold;
  color: #fff;
  text-align: center;
  animation: kj-pulse 1.4s ease-in-out infinite;
}

.kj-battle-log {
  background: rgba(0,0,0,0.45);
  border-radius: 10px;
  padding: 10px 12px;
  margin: 6px 8px;
  min-height: 64px;
  color: #fff;
  font-size: 14px;
  line-height: 1.4;
}

.kj-battle-actions {
  padding: 8px;
}
.kj-battle-prompt {
  font-size: 16px;
  color: gold;
  margin-bottom: 8px;
  text-align: center;
}
.kj-move-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.kj-move-btn {
  padding: 10px 6px;
  background: linear-gradient(135deg, #3498db, #2980b9);
  color: #fff;
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 10px;
  font-weight: bold;
  font-size: 14px;
  line-height: 1.3;
  cursor: pointer;
  min-height: 54px;
}
.kj-move-btn:active { transform: scale(0.96); }
.kj-move-btn small { display: block; font-weight: normal; font-size: 11px; opacity: 0.85; }

/* Move effectiveness colors: kids can see at a glance */
.kj-move-super {
  background: linear-gradient(135deg, #27ae60, #145a32);
  border-color: #2ecc71;
  box-shadow: 0 0 10px rgba(46,204,113,0.6);
}
.kj-move-weak {
  background: linear-gradient(135deg, #7f8c8d, #454f50);
  border-color: #95a5a6;
  opacity: 0.9;
}
.kj-move-heal {
  background: linear-gradient(135deg, #e67e22, #d35400);
  border-color: #f39c12;
}

/* Weakness tag under enemy card */
.kj-cb-weak {
  font-size: 10px;
  color: #ffdd66;
  margin-top: 3px;
  font-weight: normal;
  letter-spacing: 0.3px;
}

/* Sparks (James only, below HP) */
.kj-cb-sparks {
  font-size: 12px;
  letter-spacing: 1px;
  margin-top: 2px;
  color: #ffd700;
}
.kj-move-cost {
  font-size: 11px;
  color: #ffd700;
  background: rgba(0,0,0,0.35);
  padding: 0 4px;
  border-radius: 4px;
  margin-left: 4px;
}
.kj-move-btn:disabled .kj-move-cost {
  opacity: 0.5;
}

/* Status effect pips beneath HP bar */
.kj-cb-statuses {
  display: flex;
  justify-content: center;
  gap: 2px;
  flex-wrap: wrap;
  margin-top: 3px;
  min-height: 16px;
}
.kj-status-pip {
  display: inline-block;
  font-size: 13px;
  line-height: 1;
  background: rgba(0,0,0,0.35);
  border-radius: 4px;
  padding: 1px 3px;
}
.kj-status-pip sub {
  font-size: 8px;
  color: #ffe;
  margin-left: 1px;
}

/* Target picker (shows when kid picks a move in multi-enemy battle) */
.kj-target-grid {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  padding: 6px 0;
}
.kj-target-btn {
  flex: 1 1 calc(33.3% - 10px);
  min-width: 100px;
  max-width: 150px;
  padding: 12px 8px;
  background: linear-gradient(135deg, #8e5ed4, #5d3a90);
  border: 3px solid rgba(255,255,255,0.35);
  border-radius: 14px;
  color: #fff;
  font-family: inherit;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.kj-target-btn:active { transform: scale(0.95); }
.kj-target-btn.super {
  background: linear-gradient(135deg, #27ae60, #145a32);
  border-color: #2ecc71;
  box-shadow: 0 0 12px rgba(46,204,113,0.7);
}
.kj-target-btn.weak {
  background: linear-gradient(135deg, #7f8c8d, #454f50);
  border-color: #95a5a6;
  opacity: 0.85;
}
.kj-target-face { font-size: 34px; line-height: 1; }
.kj-target-name { font-size: 12px; }
.kj-target-dmg  { font-size: 13px; opacity: 0.9; }

/* Rescue screen */
.kj-rescue-crown {
  font-size: 110px;
  text-align: center;
  padding: 20px;
  animation: kj-pulse 1.6s ease-in-out infinite;
  filter: drop-shadow(0 0 10px gold);
}
