This is the problem known as launch trajectory optimization. That is a complicated problem mostly requiring a numerical simulation. That does however not mean we can obtain some useful figures and insights from an analytical approach!
To begin, we can with an inaccurate but usable estimate. The flawed assumption is as follows: "Our rocket is fighting against gravity for a time of $T$, so the lost $\Delta v=Tg$"
The Atlas rocket is flying for $253s+926s=1179s$, so the lost $\Delta v=1179s \cdot g=11500\frac{m}{s}$. That is more than the total $\Delta v$ of the rocket...
So what is the problem? Turns out force is a vector quantity and not a scalar. Our rocket is mostly not accelerating in the direct opposite direction of gravity, in fact, we want to gain velocity normal to gravity to reach an orbit.
If we draw some force vectors we can clearly see that the total acceleration is larger than the value we get from simple subtraction, depending on the angle. (Accelerating downwards, we even get a small bonus from gravity).

Complication 1: $\Delta v$ loss depends on trajectory
But there are more things to consider than this. For instance, why does the rocket not have to fight gravity anymore? Well, it has gained orbital velocity. But "orbital velocity" is not a binary toggle, everything is an orbit, the slower ones just happen to intersect Earth, not desirable for a satellite.
Instead, we are thrusting against a "vertical acceleration" (The direction of course varies while we are orbiting, so we are viewing this in a rotating frame of reference). We can express this from the circular orbital velocity, $v_c$:
$$a_{vertical} = 1 - \frac{v_{horizontal}^2}{v_c^2}$$
Complication 2: The vertical acceleration depends on velocity
So, an ideal strategy would be to gain horizontal velocity as fast as possible, with just enough vertical acceleration to counteract gravity. This is not very useful though as the drag is going to be extremely large and your rocket will end up crashing into the side of a mountain.
A compromise is to start in an almost vertical position, and always accelerate parallel to the current velocity vector. This is efficient as adding together vectors in parallel gives the longest resulting vector. Thir trajectory also has the nice property that the gravitational acceleration is going to slowly turn the rocket horizontal. With some planning, the rocket ends up with orbital velocity at the target altitude. This is known as a gravity turn.
You now have:
- Horizontal acceleration, depending on gravity and vertical velocity
- Gravity, depending on altitude, depending on vertical acceleration over time
- ...
- And a ton more.
The resulting system of differential equations is way to complicated to solve properly.
On top of that, you have to consider the atmosphere, as that affects your trajectory (and $I_{SP}$...)
TL;DR You must use a numerical simulation.
So then, how could such a simulation be implemented? Here is a quick sketch: (svg source in answer source for anybody wanting to improve it)

- Initial ascent (red). Accelerate vertically, and simulate drag losses. Most of those should be here.
- Gravity turn (blue). Start to pick up some horizontal velocity, and let gravity turn your rocket over. Repeat this for multiple angles to get your preferred final altitude. Ignore drag for this part.
- Final orbit (pink). No more acceleration required.