When a body is moving in a straight line and slowing down, its velocity vector is getting shorter and shorter. Since acceleration is the change in velocity, the acceleration must be shrinking the velocity vector. Thus, the acceleration must be parallel to the velocity vector but in the opposite direction. In the animation below, you can see that the direction of the acceleration of the body opposes the direction of its motion. The acceleration is shown with an imaginary arm, with which it is making the magnitude of the velocity shorter.
Whenever an object is moving in a straight line and slowing down, the acceleration direction is opposite the object's motion.