This answer is meant to put some order to my comments that, lets fragmented, appeared cryptic to the OP.
Moreover I try to answer without editing. The involved calculations just require second degree equations thus every reader can easily figure them.
The OP is forced to confusion because he assumed that the kinetic energy KE of one particle must be reflected in temperature T. This is a wrong assumption as for in a statistical ensemble of particles, a number of them have KE lower or higher than the average value, which is the one related to the macroscopic value T of the system.
See, for instance, https://physics.stackexchange.com/questions/65690/can-a-single-molecule-have-a-temperature
where all the answers deserve attention but the most voted one suffices to the current discussion.
The wrong assumption, once made, drives OP to think that the dissociation A --> B + C, being endothermic, results in a lower T of the products, or in other words the process takes energy at cost of the KE of the particles.
This is true for an ensemble in which collisions occur but obviously not in the system under consideration.
The only way for A dissociating is to input energy into the balance.
The system is easily treated supposing molecule A at rest, either isolated or in the ideal box as in the question.
Nothing happens to it unless the enthalpy of reaction DeltaH is inputted to the system in a way or another, let us assume is already in the box if we want to keep it closed and isolating.
In this case the conservation of momentum requires
mBvB = mCvC
and the conservation of energy
DeltaH = KEB + KEC.
There is not a disequality (forced by the vicious assumption endothermic process => T decreases => KE decreases) but just energy conservation.
In the case of A moving with an initial speed the treatment is the same. It suffices to treat the system in a new reference frame applying galilean relativity.
The thermochemistry and the physics of the process remains exactly the same.
In short, the term (a - 5)^2 sketched as example by the OP equals DeltaH.
A more realistic scenario is as follows. Let us open a small hole to the box and shoot A through it with a certain speed. As soon as A enter the box the aperture is closed and the box is isolating.
Now we can wait until A collides to the wall. Assuming KE of A is enough, the collision with the wall*** (not the following dissociation!) can be treated as an elastic one which solely triggers the dissociation reaction itself. In this case the DeltaH is taken at expense of kinetic energy, but indeed there is a collision transferring the required amount of energy. In a way the scenario is more similar to that of a statistical system of particles (equipartition and microscopic interpretation of T do not hold, tough and still).
The equations are now***
mAvA = mBvB + mCvC
and
KEA - DeltaH = KEB + KEC
Ideally B and C will recombine along their trajectory giving back A and so on. However no work no heat can be extracted.
Although the real molecule(s) have other channels to store/transfer energy, the above arguments shall answer the question.
***for the treatment of the collision to the wall, and specifically for the reversal of velocities, the trick is as for the elastic bouncing of a small ball against a rigid and much more massive body.