Measure the height and width of the window opening, with the old windows still in place. Move the sashes up and down as needed to get at the widest portions of the opening. Order your new windows using those measurements. (Note: The existing windows need to stay in place until the new window unit arrives.)
Pry off the trim from around the inner edge of the opening with your hammer and pry bar. Keep the trim intact as you remove it. Set it aside. Pull out the sashes. You should be left with a window opening unobstructed except for a border of trim around the exterior edge of the opening.
Set the new window unit in the opening, putting the bottom in first and then pushing the top in. Let it come to rest against the exterior border of trim. Square the unit by setting a level against it and inserting shims all around until it's level and plumb.
Tuck fiberglass insulation into the spaces all around the window unit. Secure the unit by shooting wood screws though the holes in the sides, and into the surrounding wall frame.
Reinstall the interior border of trim that you pried off earlier, using your finish nailer to set it back in place, "trapping" the new unit.
Caulk all around the lines where the trim on the outside and inside of the window unit meet the window and the surrounding walls. Also caulk where the exterior siding meets the exterior trim, to ensure rain can't get in there.