You say " When we calculate the action as the integral of the Lagrangian for a wiggly trajectory, the velocity is obviously dependent on time and so is the Lagrangian".
How exactly is the velocity dependent on time? Before applying the least action principle and find the trajectory of the object, we have a Lagrangian dependent on velocity (through the kinetic energy term), and position and (eventually) time (through the potential energy). We have no idea if and how the velocity depends on time. There is a continuum of forms of dependences, because there is a continuum of forms of trajectories that the object may follow in principle. This is why, before minimizing the action, we take in the Lagrangian the velocity as a variable in itself.
We don't know the trajectory before minimizing the action, s.t. we have no relationship between velocity and time.