>>53359356pretty terribly, it would be a bloodbath. contrary to popular belief, Swedes are actually much more willing to fight for their homeland compared to most of Europe, and an invasion would probably cause the vast majority of their population to rally behind the war effort against Russia. (see pic related)
this all being said, Sweden seems to have pretty good weaponry to defend their coast and Gotland. their diesel-electric subs are notoriously good, so much so that one of their Gotland class subs hypothetically "sank" the USS r*nald r*agan during a joint naval exercise. I know that people like to talk about how US exercises don't matter that much in real terms, but considering how the Moskva got faked out and destroyed by a couple Bayraktars and old tech British ASMs, I think Swedish subs would do remarkably well against Russian warships. then there's the issue of Sweden's own anti-ship missiles, notably the RBS-15. it can be launched from the ground or via air on JAS 39 jets, and has range roughly comparable to the US Harpoon ASM with a faster speed at about Mach 0.9. on top of that Sweden has like 150 CB90 small combat boats and an okay number of warships and patrol boats.
air defense/superiority seems like it could be one of the few issues. Sweden has a fairly large number of jets but Russia just has so many more. Swede AAMs seem pretty good but that probably wouldn't make big a difference. they also have bad SEAD capabilities, with pretty much no anti-radar air-surface munitions, compared to Ukraine which had plenty of ex-USSR systems. so Russia could pretty easily rely on its SAM networks while the Swedes would have to devote their jets almost solely for interception. Sweden doesn't have stuff like UCAVs or loiter munitions either, which would otherwise ease the issue of Russian air superiority
overall, Sweden could put up a decent defense of Gotland, but would have to hope for a Russian fuckup or Norway, Finland, and/or possible NATO involvement.