There really is no point in going up to 1500 before painting, as any paint finish will need to be sanded back. And depending on the paint, you'll generally get a better paint to wood bod if it isn't too smooth. Certainly if you are staining, then you won't want anything above P240, and for me P180 is enough for stain and paint).

What you want when sanding is to a) remove any machining marks left from the factory (often more visible on the sides than the top and back) and b) to get the flat surfaces really flat (as opposed to very smooth but undulating) and the curved surfaces evely curved with no dips.

It should be quite obvious when you've removed any machining marks, but its harder to tell if a surface is really flat unless you first spray a light 'mist' coat on it of a contrasting colour, so that you can sand it back with sandpaper stuck to a flat board (sandpaper that comes on a roll is good for this task). You'll sand off the high spots firsts, and leave any dips still with paint in. You just keep sanding until all the paint in the dips has gone, and the surface should now be really flat. You don't leave any of the mist coat paint on the body, but its still a good idea to use the same type of paint as the finish for the mist coat, to prevent any risk of a reaction between incompatible paint types.

For the edges, a smaller sanding block can be used as that will still bridge dips when sanding.

I'd probably drop to P80 for the dip removal part, then move up to P120 and P180 (and probably P240 for the neck).

You sand with one grit until any marks left by the previous grit have gone, the move up to the next grit and repeat. If you move up a grit and you still can see sanding marks and they are taking ages to remove, then you've moved up too soon and need to step back a grit level.

P180 is normally considered a fine grit in general woodworking terms. Save the finer grits for the finish. Even if you sanded to P1500, the finish will still sink in unevenly, any you are bound to get some orange peel (if spraying) and uneven finish height application, so you'll need to still sand everything flat again. But if the wood is as flat and dip-free as it can be when the finish goes on, then the easier it is to sand back at the end. An uneven body can be very obvious when sanding back the finish, as you get obvious glossy spots left in the dips. And if you haven't got enough depth of finish, then it's easy to sand through the finish on the high spots of the body before you get to the bottom of the dips.