— Be aware that your HOA is most likely a corporation with articles of incorporation and CC&Rs that in total, require you to be a member as long as you own a lot within the boundaries of the HOA. You can confirm whether the HOA is a corporation by going to the Idaho Secretary of State (SOS) site and using the business lookup section. At the SoS site, you also want to confirm if the corporation is in good standing. “Good standing” (or not) might be quite relevant.
— The corporation, not you or any other natural person, would be the plaintiff.
— If the HOA brought suit pursuant to its governing documents (declaration, bylaws and articles of incorporation), then I see no way for an individual owner to “opt-out” from the suit.
— But there are questions about whether the decision was made per the governing documents. Do the Bylaws require a vote of the owners before the HOA can file suit? Nationwide with HOAs, requiring such a vote would be unusual. Usually the board and the board alone has the legal authority to file suit. Though some boards might conduct an “advisory vote” (with no legal force) so owners can weigh in at least a bit.
— In the two Idaho statutes that are most relevant (the Idaho HOA Act and the Idaho Nonprofit Corporation Act), I see nothing that helps.
— Your best chances for halting the lawsuit likely lie in getting together others who feel as you do and trying to win a majority of seats on the board.
— If you quote exactly what your bylaws and Declaration say about bringing suit, I might be able to say more.