Shoo, have you considered the Walther P-99/ S&W 990? I picked up a used 990L in .40 S&W under $350 last spring. It's been carried, but is far from worn out, has night sights and three 12 round mags. If you prefer 9mm, they are likely more easily found and maybe a little cheaper. IDK if they all have a rail, but the 990L does....
If you want pre-ban hi-cap mags, most of the Ruger P series guns can be found around three bills in my neck of the woods. Plus, if you run out of ammo, it makes a great club.