body {
  background: #1a1a1a;
  color: #eee;
  font-size: 50px;
  font-family: "Helvetica Bold", Helvetica, Arial, sans-serif;
  margin: 0;
  padding: 20px;
  font-weight: bold;
  overflow-x: hidden;
  text-align: center; /* center inline/inline-block elements */

}

h1 {
  font-size: 120px;
  text-align: center;
  margin: 0 0 20px 0;
  font-weight: bold;
  color: #fff;
}

h2 {
  display: inline-block;
  padding: 15px 30px;
  font-size: 30px;
  font-weight: bold;
  text-align: center;
  color: #ffffff;                   /* text color */
  background-color: transparent;    /* no background */
  border: 2px solid #ffffff;        /* white outline */
  border-radius: 12px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  margin: 40px auto 20px auto;
}

.container {
  display: flex;
  justify-content: space-around;
  margin-top: 20px;
}

.horizontalContainer {
  display: flex;
  justify-content: space-evenly;

}

.leftColumn {
  display: flex;
  flex-direction: column;
}

.rightColumn {
  display: flex;
  flex-direction: column;
}

.panel {
  background: #49494983;
  padding: 20px;
  border-radius: 12px;
  width: 40%;
  min-height: 300px;
  position: relative;
}

.panel h3 {
  text-align: center;
  font-weight: bold;
  font-size: 36px;
  margin-bottom: 15px;
}

#miirymInput {
  font-size: 50px;
  font-weight: bold;
  color: #000000;
  background: #ffffff;
  margin-left: 20px;
  border: none;
  border-radius: 8px;
  width: 100px;
  height: 90px;
  text-align: center;
}

#dragonInput {
  font-size: 50px;
  font-weight: bold;
  color: #000000;
  background: #ffffff;
  margin-left: 20px;
  border: none;
  border-radius: 8px;
  width: 100px;
  height: 90px;
  text-align: center;
}

#throneInput {
  font-size: 50px;
  font-weight: bold;
  color: #000000;
  background: #ffffff;
  margin-left: 20px;
  border: none;
  border-radius: 8px;
  width: 100px;
  height: 90px;
  text-align: center;
}

button {
  font-weight: bold;
  padding: 20px 15px;
  margin: 5px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-size: 24px;
  height: 90px;
}

#resolveButtons button:nth-child(1) {
    background: #ffffff;
    color: rgb(0, 0, 0);
}

#resolveButtons button:nth-child(2) {
    background: #ffffff;
    color: rgb(0, 0, 0);
}

#resolveButtons button:nth-child(3) {
    background: #ffffff;
    color: rgb(0, 0, 0);
}


#resolveButtons button:hover {
    opacity: 0.8;
}

button:hover { opacity: 0.8; }

.etb { background: #fff; color: #000; }
.resolve { background: #fff; color: #000; }


#resolveButtons {
  text-align: center;
}

#resolveButtons button {
  display: inline-block;
  margin: 5px;
}

.damage {
  font-size: 28px;
  font-weight: bold;
  color: #fff;
  display: inline-block;
  transition: transform 0.2s ease;
  transform-origin: center;
}

.pulse { transform: scale(1.2); }

#damageDisplay {
  font-size: 60px;
  display: block;
  clear: both;
  margin-top: 20px;
  text-align: center;
}

#topAbilityDamage {
  font-size: 40px;
  display: block;
  clear: both;
  text-align: center;
}

#battlefield {
  position: relative;
  width: 90%;          /* take most of the screen width */
  max-width: 650px;    /* max width for big screens */
  margin: auto;
  min-height: 400px;
}

#battlefield img {
  position: absolute;
  width: 150px;
  border-radius: 6px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.7);
}

#stack { position: relative; }

.ability {
  position: absolute;
  width: 200px;
  opacity: 0;
  transform: translateX(-300px);
  transition: transform 0.1s ease-out, opacity 0.1s ease;
  box-shadow: 0 14px 18px rgba(0,0,0,0.7);
}

.ability.show { opacity: 1; transform: translateX(0); }

.battlefield-creature {
  position: absolute;
  width: 200px;
  border-radius: 6px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.7);
  opacity: 0;
  transform: translateX(-500px) scale(1.5);
  transition: transform 0.1s ease, opacity 0.1s ease;
}

.battlefield-creature.show {
  opacity: 1;
  transform: translateX(0) scale(1);
}

.engine-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.cast {
    position: relative;
    width: 260px;
    height: 90px;
    font-family: "Helvetica Bold", Helvetica, Arial, sans-serif;
    font-weight: bold;
    color: white;
    border: none;
    cursor: pointer;
    overflow: hidden;
    border-radius: 12px;
    font-size: 14px;
    letter-spacing: 1px;
}

#controls {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 30px;
  align-items: center; /* keep rows on the left */
}

.control-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.control-row label {
  width: 500px; /* fixed width for all labels to align inputs/buttons */
  text-align: right; /* right-align text inside labels */
  font-size: 36px;
  white-space: nowrap;
}

.control-row input {
  margin-left: 20px;
}

.control-row button {
  margin-left: 10px;
}
.cast span,
.cast {
    position: relative;
    z-index: 2;
}

.scourge-btn {
    background: linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)), url("valkas.png") center/cover no-repeat;
    background-size: 122%;
    background-position: center 15%;
}

.terror-btn {
    background: linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)), url("terror.png") center/cover no-repeat;
    background-size: 120%;
    background-position: center 30%;
}

.miirym-btn {
    background: linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)), url("miirym.png") center/cover no-repeat;
    background-size: 120%;
    background-position: center 30%;
}

.dragon-btn {
    background: linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)), url("dragon.png") center/cover no-repeat;
    background-size: 125%;
    background-position: center 30%;
}

.throne-btn {
    background: linear-gradient(rgba(0,0,0,0.35), rgba(0,0,0,0.35)), url("throne.png") center/cover no-repeat;
    background-size: 125%;
    background-position: center 23%;
}


/* Hover glow effect */
.cast:hover {
    opacity:0.8
}