It's illegal only if ...
... you spend USD$$. It's not illegal for US citizens to go to Cuba but its illegal to "trade with the enemy", meaning : spend US money there as it a highly tradable currency that can be used to train terrorists worldwide (tonugue in cheek comment, but very serious with the US govt.). Then again, it's only illegal if you get caught.
E.