As for pirate types, I completely forgot another important option... Roll up a monk and play the ship's cook!
That's good, because that's one of the classes that I had trouble coming up with a good idea for.
So, yeah, it's somewhat harder to fully realize a concept when limited to just PHB, but even if you don't have the exact right tool for the job, having a tool that will still do the job, just not as well, is still pretty good. So, here are some ideas I have for making the PHB classes piratical, or at least vaguely nautical. You'll probably want to also take the pirate or sailor background with these, and can probably take whatever race you prefer or need to enhance the build.
1. Barbarian: Honestly, a berserker isn't bad for a general brawler tough guy pirate, but I think the best theming here comes from eagle totem. When you take it at 3rd level, it gives you a lot of mobility and skirmishing ability that works well for a swashbuckling combat style. And at 6th level, it gives you great long range eyesight, perfect for someone who spends a lot of time at sea. Then, if you make it to 14th level, you get a limited flight ability, which can effectively be considered some sort of fantastic jumping ability if you want. It's either this or an aggro or a knockdown ability.
2. Bard: The nice thing about bards is that they have some capability in both weapon combat and spellcasting, and they can also take a few spells from other spell lists. As you've mentioned, you can either go Lore and do insult sword fighting, or go Valor and do actual sword fighting. I don't have much more to add, other than to share the spell list for a 15th level pirate-themed valor bard I made for a previous campaign.
0. mending (for sails and such), message, mage hand, vicious mockery 1. thunderwave (tried to make damage spells vaguely sea/storm related where possible), shield (not especially piratey, but such a good spell), find familiar (parrot), dissonant whispers, cure wounds 2. invisibility, blindness/deafness, shatter 3. bestow curse (the black spot), fear, major image 4. Leomund's secret chest ('cause you gotta keep that booty somewhere), greater invisibility, dimension door 5. mass cure wounds, hold monster 6. programmed illusion 7. etherealness 8. tsunami
3. Cleric: I'll keep this short and say you probably want Tempest domain. Possibly Trickery instead if you want to play more of a trickstery bastard, but, yeah, this one isn't too complicated.
4. Druid: Circle of Land: Coast works pretty well for this, especially since there's nothing about it that says you actually have to be anywhere near a coast to use it. Alternatively, if you want to focus on turning into sea creatures, there's Circle of the Moon (you can still turn into them as a Land Druid, you're just not as good at it).
5. Fighter: Probably your best bet is to go Battlemaster and be the sort of pirate who uses a bunch of fancy tricks in combat to mess with your opponent. Most of the abilities are even named for fencing maneuvers, so this is a pretty good fit.
6. Monk: I personally didn't have any great ideas for monk, just going Four Elements and taking water and/or air abilities to focus on the sea theme.
7. Paladin: Paladins in the PHB really do not fit the pirate ideal. Vengeance is probably the only one that could possibly get away with being a pirate without breaking their oath.
8. Ranger: The matter of favored terrain has been discussed already and I really don't care to get into it. If you want to actually be competent, go Hunter. Theoretically you could go Beast Master and ride some sea beast, but, for some reason, they limited your beast to medium size at best, so you'd have to be large, and the only creatures in the Monster Manual with swim speed under the maximum challenge rating are giant crab, giant frog, and giant poisonous snake. If you can get your DM to allow creatures from Volo's Guide, there's also a dimetrodon and dolphin. Of those, probably only giant crab and dolphin make any sense. And, if you're limited to just core, then I guess congratulations on your giant crab companion.
9. Rogue: Swashbuckler is basically the ideal pirate rogue, but, if you only have PHB, a Thief can somewhat fill its place, with good mobility from Second Story Work and other abilities let them use their wits and subterfuge. Or you can be an Assassin if you like killing things before they react and dressing up, which I suppose can describe certain pirates.
10. Sorcerer: Since Storm Sorcerer is out, I suppose the most piratical option in the PHB is Wild Mage. Mostly focus on the idea of superstition and altering luck, along with adding thematic spells if you can.
11. Warlock: Yeah, I don't know, maybe go Great Old One and say your patron lives under the sea? Or maybe Fiend could work, since I think some pirates were thought to have some connection to hell. You at least have good access to spells involving tentacles.
12. Wizard: No option for wizard really calls out pirate explicitly, but you could probably make any School work. I suppose Diviner is good if you want a fortune teller sort of pirate or Necromancy if you want to be a voodoo priest. Probably the best thing for a pirate is the spell list, though you can probably take what you need of it as a bard.