Yes it’s legal. Just call the feds and let them know we are leaving. Of course it would help if a few like minded states joined in.
The country has become to populous to have 600 people in DC tell 350 million what to do and how to live their lives and how much of our labor we will be allowed to keep.
At the time of the constitution the US had a population about the size of Ct.
Also, consider that only a subset of that CT-sized population was able to vote.