
685 N.W.2d 467 (2004)
COUNCIL OF INDEPENDENT TOBACCO MANUFACTURERS OF AMERICA, et al., Appellants,
v.
The STATE of Minnesota, et al., Respondents.
No. A03-2020.
Court of Appeals of Minnesota.
August 24, 2004.
*470 Thomas H. Boyd, Karl E. Robinson, Winthrop Weinstine, P.A., Suite Minneapolis, MN and Anthony F. Troy, Troutman Sanders, LLP, 1122, Richmond, VA, for appellants.
Mike Hatch, Attorney General, Hilary Lindell Caligiuri, Deputy Attorney General, Bradford S. Delapena, Assistant Attorney General, St. Paul, MN, for respondents.
Walter A. Pickhardt, Faegre Benson, LLP, Minneapolis, MN, for amicus curiae Brown Williamson Tobacco Corporation.
Considered and decided by STONEBURNER, Presiding Judge; SCHUMACHER, Judge; and FORSBERG, Judge.[*]

OPINION
ROBERT H. SCHUMACHER, Judge.
Appellants Council of Independent Tobacco Manufacturers of America, Carolina Tobacco Company, and Winner Tobacco Wholesale, Inc. brought this action to prohibit enforcement of Minn.Stat. ?297F.24 (Supp.2003), alleging that the statute violates the First Amendment, Equal Protection and state uniformity clauses. Appellants further contend that the statute is a bill of attainder and unconstitutional special legislation.
Minn.Stat. ?297F.24 is not a direct attempt to regulate speech but has a legitimate legislative purpose and therefore is not an infringement of appellants' rights to free speech. The statute creates classifications based on genuine and substantial distinctions, does not violate the Equal Protection or state uniformity clauses, and is not special legislation. Finally, because the statute seeks to regulate prospective rather than past conduct, it is not a bill of attainder. We affirm.

FACTS
Appellants are manufacturers and distributors of cigarettes who were not parties to State by Humphrey v. Philip Morris, Inc., No. C1-94-8565 (Minn.Dist.Ct. May 8, 1998), which ended in settlement in May 1998. In that matter, the state sued Philip Morris, Inc., R.J. Reynolds Tobacco Co., Brown & Williamson Tobacco Corporation, and Lorillard Tobacco Co., the so-called "major manufacturers," as well as Liggett Group, Inc., asserting claims for costs associated with the tobacco companies' conduct in denying the deadly and addictive nature of their products and attempting to conceal this information.
The state settled with Liggett on March 20, 1997. Liggett agreed to make annual payments of $100,000, publicly acknowledge the dangers of nicotine, restrict its advertising, and cooperate with the state in its action against the major manufacturers. After trial, but before a verdict was returned, the state entered into a settlement agreement with the major manufacturers ("Minnesota settlement").
Broadly stated, the major manufacturers agreed to make six one-time payments, as well as annual payments in perpetuity, amounting to approximately $6.1 *471 billion over 25 years. The annual payment amount is based on the national market share of each of the major manufacturers. In addition, the major manufacturers agreed not to oppose legislative proposals designed to reduce tobacco use by children, to challenge certain existing laws or rules governing tobacco, or to support national legislation designed to override the settlement agreement. The major manufacturers further agreed to discontinue advertising on billboards and in transit facilities, refrain from paying for product placement in movies, and cease sales of products bearing logos of their products. In return for these agreements, the state agreed to release the major manufacturers from all past and future tobacco-related claims.
Six months after the Minnesota settlement, 46 states and 6 United States territories settled with the major manufacturers in the "Master Settlement Agreement." Like the Minnesota settlement, the Master Settlement Agreement involved settlement payments, annual payments in perpetuity, and restrictions on lobbying and advertising activities in exchange for releases from claims. The Master Settlement Agreement also permits manufacturers other than the majors to join in the settlement by making annual payments. The Master Settlement Agreement encouraged all participating states to draft a "qualifying statute" which would neutralize the cost advantages a non-participating manufacturer would otherwise enjoy.
Within four years after the Minnesota settlement, the market share of the major manufacturers had fallen from about 98% to about 88% of the state market. Smaller manufacturers not party to the settlement agreement had apparently been able to capture a much larger share of the market based on lower prices. In 2003, the state legislature enacted Minn.Stat. § 297F.24 (Supp.2003) to counteract this trend. This statute imposes a 1.75¢ per cigarette or 35?per pack fee on cigarettes, payable by distributors of tobacco products that are manufactured by companies not subject to the Minnesota settlement. The stated purposes of the statute are to make "non-settlement" cigarette manufacturers pay fees comparable to the costs attributable to the use of their cigarettes, prevent non-settlement manufacturers from undermining the state's policy of discouraging youthful smokers by supplying low-priced cigarettes, and fund other appropriate purposes. Minn.Stat. § 297F.24, subd. 1(b)(1)(2)(3).
The statute permits a manufacturer not a party to the Minnesota settlement to voluntarily enter into an agreement with the state on similar terms. Minn.Stat. § 297F.24, subd. 2(2). Respondent Dan Salomone, in his official capacity as the Commissioner of the Minnesota Department of Revenue, has interpreted this to mean that the nonparty manufacturer must make annual payments equal to at least 75% of the payments required from parties to the original agreement and must also agree to the lobbying and advertising restrictions. As of September 2003, the 75% payment would be equal to 48¢ per pack, but the manufacturer would not have to pay the 35¢ fee otherwise imposed by the act. Respondent State of Minnesota would be obligated to release the manufacturer from all past and future tobacco-related claims.
The model act proposed by the Master Settlement Agreement provides that monies collected under the qualifying statute from non-participating manufacturers would be escrowed for 25 years to provide a fund for payment if a state successfully sues a non-participating member for health-care costs. If no costs accrue over *472 the 25-year period, the money is returned to the non-participating manufacturer. The Minnesota law, on the other hand, acts like an excise tax; the money collected through the 35¢ fee belongs to the state and can be used for general purposes. Further, the fee is collected from distributors, not manufacturers, and will not be returned to the distributor. In theory, although the tax is on distributors, a non-settling manufacturer will be forced to raise the price of its cigarettes to cover the fee, thus decreasing the economic advantage of the non-settling manufacturers.
Appellants sought a temporary restraining order and temporary injunction to prohibit enforcement of the statute. The district court denied appellants' motions. Both appellants and respondents made cross-motions for summary judgment. The district court denied appellants' motion and granted summary judgment to respondents.

ISSUES
1. Is Minn.Stat. § 297F.24 (Supp.2003), an unconstitutional abridgement of appellants' First Amendment rights?
2. Does Minn.Stat. § 297F.24 violate principles of equal protection or the state's uniformity clause?
3. Is Minn.Stat. § 297F.24 unlawful under the United States Constitution or the Minnesota Constitution as a bill of attainder?
4. Is Minn.Stat. § 297F.24 a violation of the Minnesota Constitution's prohibition against special legislation?

ANALYSIS
1. We evaluate a statute's constitutionality as a matter of law. Granville v. Minneapolis Pub. Schs., 668 N.W.2d 227, 230 (Minn.App.2003), review denied (Minn. Nov. 18, 2003). Statutes are presumed to be constitutional. Kismet Investors, Inc. v. County of Benton, 617 N.W.2d 85, 93 (Minn.App.2000), review denied (Minn. Nov. 15, 2000). If the constitutional challenge involves a fundamental right, the reviewing court applies a strict scrutiny analysis. State ex rel. Morrow v. LaFleur, 590 N.W.2d 787, 796 (Minn.1999). If no fundamental right is involved, an appellate court reviews the statute under a rational basis standard. Kolton v. County of Anoka, 645 N.W.2d 403, 411 (Minn.2002).
The first question is whether Minn.Stat. § 297F.24 (Supp.2003), abridges appellants' First Amendment right of free speech, a fundamental right.[1] A government entity "may not condition a tax exemption on the renunciation of an individual's right to free speech." PTI, Inc. v. Philip Morris, Inc., 100 F.Supp.2d 1179, 1206 (C.D.Cal.2000) (citing Speiser v. Randall, 357 U.S. 513, 518, 78 S.Ct. 1332, 1338, 2 L.Ed.2d 1460 (1958)). But the usual case where an unconstitutional tax exemption is found involves a direct attack on speech, rather than limitation as a collateral consequence. See FCC v. League of Women Voters, 468 U.S. 364, 383-84, 104 S.Ct. 3106, 3119, 82 L.Ed.2d 278 (1984) (requiring ban on editorial speech on public *473 broadcasting stations in order to maintain tax-exempt status); Speiser, 357 U.S. at 518, 78 S.Ct. at 1338 (requiring oath from veterans that they have not advocated overthrow of government before grant of tax exemption).
The United States Supreme Court stated that although lobbying is speech, a government entity need not provide a tax exemption, which the Court described as a subsidy, in order to permit an individual to more fully exercise the protected right. Regan v. Taxation With Representation of Wash., 461 U.S. 540, 545, 103 S.Ct. 1997, 2001, 76 L.Ed.2d 129 (1983). The Court noted: "We have held in several contexts that a legislature's decision not to subsidize the exercise of a fundamental right does not infringe the right, and thus is not subject to strict scrutiny." Id. at 549, 103 S.Ct. at 2003. The Court stated: "Where governmental [denial of a tax exemption] is not aimed at the suppression of dangerous ideas, its power to encourage actions deemed to be in the public interest is necessarily far broader." Id. at 550, 103 S.Ct. at 2003 (citation and quotation omitted). The Court went on to examine the organization's claims using a rational basis standard, concluding that Congress had a rational reason to limit tax-free status. Id. at 549-50, 103 S.Ct. at 2003.
Thus, where a statute has a legitimate purpose that is not a direct attempt to stifle speech, the court applies a rational basis review standard. Applying that standard, the purpose of Minn.Stat. § 297F.24, as set forth in subdivision 1(b), is to require non-settlement manufacturers to pay fees comparable to the costs incurred by the state that are attributable to the use of cigarettes and to prevent non-settlement manufacturers from flooding the state with cheap cigarettes, thereby undermining the state's policy of discouraging youth smokers. This is a legitimate purpose within the state's power and, because it is not a direct attempt to regulate speech, does not offend the First Amendment.
2. This court reviews claims under the Equal Protection and state uniformity clauses to decide whether the classification is rationally related to a legitimate government interest. U.S. Const. amend. XIV, § 1; Minn. Const. art. I, § 7, art. X, § 1; Star Scientific, Inc. v. Beales, 278 F.3d 339, 348 (4th Cir.2002). Under Minnesota decisions, the rational basis test requires:
(1) The distinctions which separate those included within the classification from those excluded must not be manifestly arbitrary or fanciful but must be genuine and substantial, thereby providing a natural and reasonable basis to justify legislation adapted to peculiar conditions and needs; (2) the classification must be genuine or relevant to the purpose of the law; that is, there must be an evident connection between the distinctive needs peculiar to the class and the prescribed remedy; (3) the purpose of the statute must be one that the state can legitimately attempt to achieve.
Westling v. County of Mille Lacs, 581 N.W.2d 815, 820 (Minn.1998) (quoting Miller Brewing Co. v. State, 284 N.W.2d 353, 356 (Minn.1979)).
"[C]ourts are especially deferential in the context of classifications made by complex tax laws." John Hancock Mut. Life Ins. Co. v. Comm'r of Revenue, 497 N.W.2d 250, 253 (Minn.1993) (quotation omitted); see also Regan, 461 U.S. at 547, 103 S.Ct. at 2002 ("Legislatures have especially broad latitude in creating classifications and distinctions in tax statutes."). Even where the effect on particular groups within a class is uneven, there is no constitutional violation so long as the basic classification *474 is reasonable. John Hancock, 497 N.W.2d at 253.
Here, the two classifications are settling and non-settling manufacturers. Using the rational-basis test, we first address whether the distinctions between the two are reasonable. Settling manufacturers are making annual payments in perpetuity, while the non-settling manufacturers are not. This provides a reasonable basis for the distinction that is not manifestly arbitrary or fanciful.
As to the second factor, whether the classification is relevant to the purpose of the law, the stated purpose of the law is to discourage the sale of cigarettes at prices attractive to youthful smokers and to compel the non-settling manufacturers to pay fees comparable to the costs incurred by the state from the sale and use of cigarettes. As the state points out, the settling manufacturers are providing annual payments that provide a source of revenue to the state to use for preventative purposes and recovery of health costs and that also force the price of their cigarettes to remain higher and thus less attractive to youthful smokers. Without the cigarette fee, the non-settling manufacturers avoid assuming responsibility for the hidden costs of smoking and can maintain their prices at a lower level. Thus, the classification is relevant to the purposes of the law.
The third prong of the analysis, whether the purpose is something the state can legitimately hope to achieve, is subject to extremely deferential review. Westling, 581 N.W.2d at 822. Unless the purpose is "invidious or arbitrary," it will be sustained. Id. The purpose of Minn.Stat. § 297F.24 is related to the health and well-being of its citizens, particularly youth, which is a legitimate interest of the state.
The state's classifications are rationally related to a legitimate state purpose and do not offend either the Equal Protection Clause or the state uniformity clause.
3. Both the United States Constitution and the Minnesota Constitution prohibit passage of any bill of attainder. U.S. Const. art. I, § 11; Minn. Const. art. I, § 11. A bill of attainder is defined as "a law that legislatively determines guilt and inflicts punishment upon an identifiable individual without provision of the protections of a judicial trial." Nixon v. Adm'r of Gen. Servs., 433 U.S. 425, 468, 97 S.Ct. 2777, 2803, 53 L.Ed.2d 867 (1977). The prohibition against bills of attainder is grounded in the separation of powers doctrine; it is designed to prevent a legislative body from usurping the role of the judiciary by legislatively determining issues of guilt and punishment. Id. at 469, 97 S.Ct. at 2803.
Generally, a bill of attainder requires proof of three things: (1) singling out or specification of an identifiable individual or group; (2) punishment; and (3) lack of a judicial trial. Selective Serv. Sys. v. Minn. Pub. Interest Research Group, 468 U.S. 841, 847, 104 S.Ct. 3348, 3352, 82 L.Ed.2d 632 (1984). Although it is not unlawful per se to single out a group for a legislative purpose, it is unlawful to single out a group for punishment based on past conduct. Id. Thus, if a law is intended to legislatively punish an individual or group solely because of past conduct, it is a bill of attainder. Id. But if an affected group can escape the regulation by altering their conduct, the proscription is not a bill of attainder, because it addresses future, not past, conduct. WMX Techs., Inc. v. Gasconade County, 105 F.3d 1195, 1202 (8th Cir.1997).
To determine if a law has a punitive purpose, a court makes three inquiries: (1) whether the law imposes punishment such as death, imprisonment, *475 banishment, confiscation of property, or barring participation in certain employment or occupations; (2) whether the law furthers a non-punitive legislative purpose; and (3) whether the legislative body had a punitive motive in passing the law. Id. at 1202-03.
First, appellants here are not barred from engaging in their chosen occupations. They may sell cigarettes and pay a tax, refrain from selling in the state, or join in the settlement agreement. A legislative prohibition is not a bill of attainder if it can be avoided by simply not engaging in the affected conduct. See Selective Serv. Sys., 468 U.S. at 856-57, 104 S.Ct. at 3357.
Next, the statute sets forth two primary legislative purposes: to discourage youthful smokers by preventing cigarettes from being too attractively priced and to recover some of the state's costs resulting from cigarette smoking. Minn.Stat. ?297F.24, subd. 1(b). Neither of these purposes have a punitive intent.
Finally, a legislative body's punitive motivation can be inferred if the law suggests intent to punish an affected party for past conduct. WMX, 105 F.3d at 1203. Once again, this law applies to future sales of cigarettes and is not based on appellants' past conduct. Although the law requires appellants to pay taxes not previously imposed on them, "[f]orbidden legislative punishment is not involved merely because [an act] imposes burdensome consequences." Nixon, 433 U.S. at 472, 97 S.Ct. at 2805.
Because the statute is not punitive in nature and seeks to regulate future rather than past conduct, we conclude that it is not a bill of attainder.
4. Appellants also argue that Minn.Stat. § 297F.24 is unlawful because it violates the prohibition against special legislation. Article 12, section 1 of the Minnesota Constitution states:
In all cases when a general law can be made applicable, a special law shall not be enacted.... Whether a general law could have been made applicable in any case shall be judicially determined without regard to any legislative assertion on that subject. The legislature shall pass no local or special law ... granting to any private corporation, association, or individual any special or exclusive privilege, immunity or franchise whatever.
Although the legislature is prohibited from enacting special legislation, it is nevertheless lawful to create different classes and apply different rules to them, so long as the classification is based on substantial distinctions. In re Tveten, 402 N.W.2d 551, 558 (Minn.1987). In order to determine whether an appropriate classification has been made, the reviewing court applies a three-part rational basis test:
(a) the classification applies to and embraces all who are similarly situated with respect to conditions or wants justifying appropriate legislation; (b) the distinctions are not manifestly arbitrary or fanciful but are genuine and substantial so as to provide a natural and reasonable basis justifying the distinction; and (c) there is an evident connection between the distinctive needs peculiar to the class and the remedy or regulations therefor which the law purports to provide.
Id. at 558-59 (quotation omitted).
This review is similar to the standard applied above on the equal protection/uniformity question. We have already concluded that the classifications in the statute between settling manufacturers, who pay annual fees that subsidize the costs to the state of smoking and act to raise cigarette prices to discourage youthful *476 smokers, and non-settling manufacturers, who do not, create a genuine and substantial distinction tied to a legitimate state interest. As such, Minn.Stat. ?297F.24 is not special legislation prohibited by the Minnesota Constitution.

DECISION
Minn.Stat. ?297F.24 (Supp.2003) does not abridge appellants' First Amendment rights or violate the Equal Protection and state uniformity clauses and is neither a bill of attainder nor special legislation in violation of the Minnesota Constitution.
Affirmed.
NOTES
[*]  Retired judge of the Minnesota Court of Appeals, serving by appointment pursuant to Minn. Const. art. VI, ?10.
[1]  Appellants argue that the district court erred by placing the burden of proof on them rather than respondents. When a statute infringes on First Amendment rights, the government bears the burden of proving the constitutionality of the statute. Kismet, 617 N.W.2d at 93. This is true even where the restriction impinges on commercial speech, which is generally accorded a lesser standard of protection. State by Humphrey v. Casino Mktg., 491 N.W.2d 882, 885 (Minn.1992). Even assuming, however, that the district court erred in placing the burden of proof on appellants, this court can still evaluate the merits of this appeal, applying the appropriate standard. See id. at 885-86.
