Plenty of second and third sons have ended up king. And yes, Naples allowed female succession—I don't believe there had been any change in the laws and customs of the kingdom when Alfonso I became king, and Naples had some precedence for female succession among the Capetians (Joanna I and Joanna II), but I wasn't even suggesting that Mary herself would become queen regnant, but rather she has a chance to become consort and sire a possible king. Of course, it's a downgrade from being Maximilian's future consort, but hey—Naples was a pretty wealthy kingdom. It's true Frederick's brother Alfonso has two sons, but Ferdinand II didn't even marry until his ascension. He ended up dying from an illness, not sure what it was. Of course, he could end up living longer, but it's also possible he didn't. Alfonso's second son was still alive when Frederick IV became King, he was by-passed in the succession for some reason. But given Frederick is quite far from the crown in 1482, he'd made a viable husband as he could join Mary in Burgundy. Would definitely hamper any attempts for him to take the crown. If the Italian Wars still occur in some fashion, it's possible for Ferdinand II to live longer, but if Mary has any issue with Frederick they will have claims to the throne of Naples if the main branch blows up.
Apparently Louis XI also encouraged the suit because it would give him a chance to exchange the claims of Anjou in exchange for Burgundian territories in Maine—not sure what territories, though, as I wasn't aware that Burgundy had any fiefs in that region. By 1482, the Duchy of Anjou and Provence are firmly attached to the French crown, and with Charles the Bold's death, Louis XI had occupied the Burgundian fiefs in France, so it'd be interesting to see where he goes when Mary is left without a husband.