By in-show chronology, NX-01 would probably be the first. She never had any problem maneuvering in an atmosphere; altitudes down to a couple of hundred feet were shown.
By in-show technobabble, there's no particular reason why starships couldn't fly in an atmosphere. Or under water. Or through solid rock for that matter. If they can take impulse accelerations and disruptor blasts, they should have no problem whatsoever hovering steadily in a gale above a planet that has a couple of hundred times Earth's gravity.
However, the shape of NCC-1701 isn't conductive of landings or takeoffs. Which is why I like the way they did it in Brad Ferguson's A Flag Full of Stars
, with the TOS saucer refitted for TMP on the ground and flown under her own power to the secondary hull which stayed in space the whole time. The original TOS saucer could have been flown up that way, too - although it sounds a bit odd that they would build the nacelles in the same place and tow those up to orbit as well.
As for references to San Francisco yards, those could be on Andoria for all we know. It's just a name, folks. It's not as if Earth Station McKinley sits atop Mount McKinley, either. Or as if Columbia Pictures studios are located in Columbia. Probably the SF Yards have facilities all over the Sol system, although not necessarily in San Francisco itself.