Near Union Square I would recommend Cockscomb, Cafe Claude, Liholiho Yacht Club.
For more traditional SF seafood, you could trek to Swan's Oyster Depot (prepare to wait in line and eat at a counter) or Tadich Grill. The seafood at Tadich can be hit or miss but the sand dabs are great and are local to SF bay. The cioppino is an SF classic as well.
Another SF classic (but you'll have to travel a bit) is Zuni Cafe.
Lastly, if you want a bit of an adventure I would try State Bird Provisions. People line up early (4:30ish) but it's a bit of a camaraderie in line. It's a cart-based dim sum style dining, but with American dishes. The CA state bird is quail and that's their signature dish.
Keep in mind SF is a real food city. There are more than 4,000 restaurants and probably half of those are within a mile of Union Square.
Have fun!