/* The selection changes the primary action without replacing its button. */
#battle-root .spell-panel-battle .battle-action.wait-action {
  color:#f9faf7;
  background:linear-gradient(150deg,#89918d,#727e7b);
  border:2px solid #e7ece7;
  box-shadow:inset 0 1px 0 #ffffff55,0 0 0 1px #85918c;
  animation:valgard-wait-edge 1.15s ease-in-out infinite alternate;
}
#battle-root .spell-panel-battle .battle-action.wait-action small {color:#f0f3ef;}
#battle-root .spell-panel-battle .battle-action.wait-action:disabled {animation:none;opacity:.65;}
@keyframes valgard-wait-edge {
  to {border-color:#aeb8b3;box-shadow:inset 0 1px 0 #ffffff88,0 0 0 2px #f4f8f1b8;}
}

/* The field remains in its grid track while the journal unfolds over it. */
#battle-root .spell-panel-battle > .battle-console {
  transition:height .24s cubic-bezier(.22,.72,.25,1),margin-top .24s cubic-bezier(.22,.72,.25,1);
}
#battle-root .spell-panel-battle .combat-action-panel,
#battle-root .spell-panel-battle #battle-actions {
  transition:height .24s cubic-bezier(.22,.72,.25,1),max-height .24s cubic-bezier(.22,.72,.25,1);
}
#battle-root .spell-panel-battle .battle-log,
#battle-root .spell-panel-battle .battle-log.log-expanded {
  transition:height .24s cubic-bezier(.22,.72,.25,1),max-height .24s cubic-bezier(.22,.72,.25,1);
}
#battle-root .spell-panel-battle .battle-log-content {transition:opacity .14s ease;}

/* Movement stays within the silhouette; avoid rectangular flashes around art. */
#battle-root .spell-panel-battle .battle-effect .effect-painting {
  -webkit-mask-image:radial-gradient(ellipse 68% 68% at center,#000 67%,transparent 100%);
  mask-image:radial-gradient(ellipse 68% 68% at center,#000 67%,transparent 100%);
}
#battle-root .spell-panel-battle .battle-actor.dodging {filter:drop-shadow(4px 2px 3px #acc7c477);}
#battle-root .spell-panel-battle .battle-actor.waiting-turn {transform-origin:50% 95%;}
#battle-root .spell-panel-battle .monster-unit.entering .ground-shadow {
  animation:valgard-arrival-dust .25s ease-out both;
}
@keyframes valgard-arrival-dust {
  from {opacity:0;transform:scale(.35);}
  65% {opacity:.75;transform:scale(1.25);}
  to {opacity:1;transform:scale(1);}
}
#battle-root .spell-panel-battle .monster-unit.dying .monster-sprite {
  -webkit-mask-image:radial-gradient(ellipse 70% 69% at center,#000 76%,transparent 100%);
  mask-image:radial-gradient(ellipse 70% 69% at center,#000 76%,transparent 100%);
}
@media(prefers-reduced-motion:reduce){
  #battle-root .spell-panel-battle .battle-action.wait-action,
  #battle-root .spell-panel-battle .monster-unit.entering .ground-shadow{animation:none;}
  #battle-root .spell-panel-battle > .battle-console,
  #battle-root .spell-panel-battle .battle-log,
  #battle-root .spell-panel-battle .combat-action-panel,
  #battle-root .spell-panel-battle #battle-actions{transition:none;}
}
