JUSTICE RICE
delivered the Opinion of the Court.
¶1 The City of Helena (City) appeals from the Judgment of the First Judicial Court, Lewis & Clark County, denying its cross-motion for summary judgment and concluding as a matter of law that it had no legal authority to adopt or enforce Helena City Code § 11-42-2. Scott Svee and Megan Svee (Svees) cross-appeal from the Judgment for dismissing their constitutional claims and denying their claim for attorney’s fees. We affirm in part, and reverse and remand in part, and restate the issues as follows:
1. Did the District Court err by determining that Helena City Code § 11-42-2 was an impermissible building code, and not a zoning ordinance?
2. Did the District Court err by holding that the Svees were ineligible for an award of attorney fees under § 27-8-313, MCA?
3. Did the District Court err by failing to address and dismissing the Svees’s constitutional arguments?
FACTUAL AND PROCEDURAL BACKGROUND
¶2 In January 2009, the Helena City Commission adopted an amendment to its existing zoning ordinance, § 11-41-1 of the Helena City Code, which created a wildland-urban interface district (WUI district) encompassing the corporate limits of the city of Helena and overlaying the City’s other zoning districts. As part thereof, the City also adopted § 11-41-2, which provides, in pertinent part, as follows:
A Structures located within the wildland-urban interface district may not have exposed, wooden roofing materials, whether treated or untreated, and must have noncombustible or fire resistant roofing materials that are rated Class C or higher in accordance with ANSI/UL 790 or ASTM E 108 or any equivalent test.
*160B. Existing roofs that undergo renovation, alteration, or repairs that involve more than ten percent (10%) of the square footage of the affected roof plane must meet the requirements of this chapter. If the renovation, alteration, or repair involves more than fifty percent (50%) of the square footage of the area of the entire roof, then the entire roof must comply with the requirements of this chapter.
Helena, Mont., City Code § 11-41-2. The challenge in this case is made only to § 11-41-2, and the limitations it places on roofing materials, not to the creation of the WUI district itself.
¶3 The Svees are homeowners whose property is situated within the WUI zoning district. After receiving notice that their homeowners insurance policy would be canceled due to the condition of their roof, the Svees, due to personal financial constraints, limited repairs to the portion of the roof most in need of improvement, replacing old wooden shingles on the south plane of the roof with new wooden shingles. The project began on August 12,2011.
¶4 On August 15, 2011, a city building official observed the Svees’ repair project and issued a stop-work notice. By the time the Svees received the notice, they had finished the roof repair. The City filed criminal complaints against the Svees for re-roofing without a permit, serving them on September 8,2011. Then, on November 7,2011, the Helena City Commission voted to file a civil action against the Svees in addition to pursuing criminal charges. On December 6, 2011, the City filed a six-count complaint against the Svees in the First Judicial District Court, alleging failure to obtain a building permit; violation of the International Residential Code by failing to obtain a building permit; violation of the International Residential Code by installing new roof covering over an existing roof covering; violation of the International Residential code by using excess applications of roof covering; violation of Helena Cfty Code by using illegal roofing materials; and public nuisance. The Svees answered the civil complaint in January 2012 and petitioned the District Court for a declaratory judgment that the Ordinance was invalid on statutory and constitutional grounds. On February 13, 2012, the criminal charges were dismissed on the motion of the City.
¶5 Svees moved for summary judgment on their Petition for Declaratory Judgment and the City countered by moving for summary judgment while simultaneously withdrawing five of the counts alleged in its complaint, leaving only the count alleging violation of the Ordinance. The parties agreed that there were no genuine issues of material fact, and that the validity of § 11-41-2 was a question of law. *161Based on a statutory analysis, the District Court denied the City’s motion and granted the Svees’, reasoning:
[WJhen the plain language of the statutes are applied in conjunction with one another, the Court concludes that the logical conclusion is that § 11-41-2 is a building regulation, i.e., an ordinance relating to the design, construction, alternation, or repair of buildings, and the materials to be used therefor.... The statute does not authorize the City to adopt building regulations under the guise of a zoning ordinance.
The court did not address the constitutional claims raised by the Svees. ¶6 On October 25,2013, the District Court entered a final Judgment, declaring “the Svees’ claims seeking a declaration that the City had no legal authority to adopt or enforce Helena City Code § 11-41-2 ... are GRANTED.” OnNovember 5,2013, the Svees filed a motion requesting attorney fees, which the District Court denied. Subsequently, the City filed a notice of appeal from the judgment invalidating the Ordinance, and the Svees filed a cross-appeal challenging the dismissal of their constitutional arguments and the denial of attorney fees.
STANDARD OF REVIEW
¶7 This Court reviews the grant of summary judgment de novo, using the same M. R. Civ. P. 56 criteria used by a district court. Albert v. City of Billings, 2012 MT 159, ¶ 15, 365 Mont. 454, 282 P.3d 704. Summary judgment is appropriate when the moving party demonstrates an absence of any genuine issue of material act and entitlement to judgment as a matter of law. Albert, ¶ 15. When no dispute exists as to the material facts, this Court reviews whether the district court correctly applied the law. Kalispell Educ. Ass’n v. Bd. of Trustees, 2011 MT 154, ¶ 9, 361 Mont. 115, 255 P.3d 199. A district court’s ruling on a summary judgment is not a discretionary function that merits deferential review. Lorang v. Fortis Ins. Co., 2008 MT 252, ¶ 53, 345 Mont. 12, 192 P.3d 186. This Court reviews for correctness a district court’s conclusion regarding the existence of legal authority to award attorney fees. Hughes v. Ahlgren, 2011 MT 189, ¶ 10, 361 Mont. 319, 258 P.3d 439 (citation omitted). If legal authority exists, we review for an abuse of discretion a district court’s order granting or denying attorney fees. Hughes, ¶ 10.
DISCUSSION
¶8 1. Did the District Court err by determining that Helena City Code § 11-42-2 was an impermissible building code, and not a zoning *162 ordinance?
¶9 In 1969, Montana adopted a state building code designed to "provide reasonably uniform standards and requirements for construction and construction materials consistent with accepted standards of design, engineering, and fire prevention practices.” Section 50-60-201(1), MCA. Section 50-60-202, MCA, designates the Department of Labor and Industry as "the only state agency that may promulgate building regulations....” The Legislature has authorized counties, cities, and towns to locally adopt and enforce only those building codes that have been "adopted by the department.” Sections 50-60-301(2), MCA; 50-60-302(a), MCA. "Building regulations” are defined as "any law, rule, resolution, regulation, ordinance, or code, general or special ... relating to the design, construction, reconstruction, alteration, conversion, repair, inspection, or use of buildings and installation of equipment in buildings.” Section 50-60-101(3Xa), MCA. This definition "does not include zoning ordinances.” Section 50-60-101(3Xb), MCA.
¶10 The City interprets the District Court’s order as holding that “the creation of the WUI zoning district was nothing more than the adoption of ‘a building regulation!] under the guise of a zoning ordinance,’ ” (emphasis added), which the City challenges as error. The City argues that the key issue is "whether the WUI zoning overlay district is a valid zoning ordinance under Montana law,” and notes that municipalities are authorized, pursuant to their delegated zoning authority, to regulate the height and size of buildings and other structures, § 76-2-301, MCA, as well as “the erection, construction, reconstruction, alteration, repair, or use of buildings.” Section 76-2-302, MCA. Positing that its WUI district falls squarely within statutorily authorized municipal zoning, the City then cites the qualification within the definition of "building regulations” in § 50-60-101(3)(b), MCA, as “not includ[ing] zoning ordinances,” and reasons that this exclusion eliminates any possible classification of the WUI zoning district as a building code regulation, as well as any conflict with state law.
¶11 The first problem with the City’s overbroad argument, as noted by Svees, is that Svees did not challenge and the District Court did not invalidate the entire WUI zoning district as an impermissible building regulation that conflicted with state law. Bather, they challenged and the District Court invalidated only the portion of the WUI ordinance that regulated building construction materials, that being § 11-42-2. While the District Court’s decision may have removed the “teeth” of the WUI district as now enacted, the district itself remains valid and the *163City is not precluded from exploring other mechanisms to secure fire protections in the district. Thus, the City’s assertion that it is “absurd” to conclude that the WUI district is not a valid exercise of the City’s zoning authority is falsely premised — the District Court did not so hold, and that issue is not before us here. The further flaws in the City’s arguments, as discussed below, are that neither the general municipal zoning authority set forth in §§ 76-2-301, -302, MCA, nor the distinguishing of zoning ordinances within the definition of “building regulations” in § 50-60-101(3)(b), MCA, supplant the Legislature’s clearly demonstrated intention to occupy this area of the law by enacting a statewide building code and by expressly prohibiting local governments from adopting regulations that deviate from the state code.
¶12 The City emphasizes the language of § 76-2-302, MCA, which authorizes municipalities to “regulate and restrict the erection, construction, reconstruction, alteration, repair, or use of buildings, structures or land.”1 As the District Court reasoned, on first blush this language appears to support the City’s position, but ultimately fails under further analysis. Section 76-2-302, MCA, clarifies that these powers are granted “[flor the purposes of 76-2-301,” which in turn empowers municipalities to regulate the size, location and use of all structures and land; the size of yards, courts, and other open spaces; and the occupancy on land and density of population. Section 76-2-301, MCA. This statute neither mentions nor authorizes municipalities to regulate building materials that are expressly governed by the state building code. The exclusion of zoning ordinances from the definition of “building regulations” in § 50-60-101(3)0)), MCA, simply distinguishes zoning ordinances that properly regulate structures within the sphere of authority provided by § 76-2-301, MCA.
¶13 The City next argues that § 11- 41-2 is a valid ordinance under this Court’s holding in Virginia City v. Estate of Olsen, 2009 MT 3, 348 Mont. 279, 201 P.3d 115. There, a homeowner challenged building requirements imposed by two building permits issued pursuant to Virginia City’s zoning ordinances, including its Design Review Zoning Ordinance, by which the City regulated construction to ensure consistency with the City’s historic character. Virginia City, ¶¶ 3, 9-10. The ordinance regulated such matters as “setback distances, height, *164window size and placement, and general structure.” Virginia City, ¶ 9. We affirmed the District Court’s rejection of the homeowner’s challenge to the requirements of the building permits and entry of summary judgment against the homeowner. Virginia City, ¶¶ 20, 23, 25. The City reasons that, if ordinances may be legitimately enacted to “regulate such things as ‘window size and placement’... then the City of Helena can legitimately regulate the use of structures with wooden roofing materials through the very same municipal zoning authorities for the safety of life and property.”
¶14 Svees correctly argue that our holding in Virginia City concerned the homeowner’s failure to adhere to the terms of the building permits, not the propriety of the zoning ordinances. We explained that the parties had agreed that the permits controlled the issues before the Court, that “to the extent that any requirement in the permits and accompanying documents is at variance with the provisions of Ordinance 503 or other City ordinances, the provisions of the permits control,” Virginia City, ¶ 17, and thus “Defendants’ counterclaims and arguments relating to the validity and enforceability of the ordinances have no bearing on whether the City may enforce the terms of the permits.” Virginia City, ¶ 37. Consequently, we did not address the validity of the subject ordinances in Virginia City. It is further notable that the actual building issues resolved in that case involved setback and structural requirements, which are zoning-related questions not at issue here. Virginia City, ¶¶ 18-24.
¶15 The Svees note that two attorney general opinions are consistent with the District Court’s holding. In 40 Attorney General Opinion 76, the Attorney General concluded that the enactment of the state building code in 1969 effectively repealed § 7-33-4203, MCA, which granted local governments the power to regulate the construction of combustible buildings, opining that “the authority to adopt rules for the construction of all buildings was vested in the state under [Montana law]. These provisions leave no room for a local government to prescribe rules dealing with building construction.” 40 Op. Att’y Gen. at 3; see also Opinion No. 81, 37 Op. Att’y Gen. 2 (1977). The Legislature thereafter agreed, subsequently repealing § 7-33-4203, MCA. Sec. 156, Ch. 370, L. 1987.
¶16 Section 7-1-113(1), MCA, provides “[a] local government with self-government powers is prohibited the exercise of any power in any manner inconsistent with state law or administrative regulation in areas of law affirmatively subjected by law to state regulation or control.” Section 11-41-2 of the Helena City Code expressly limits the *165materials that may be used in the construction or repair of a building. The Ordinance thus exceeds the zoning authority granted to municipalities by statute and trespasses into subject matter that had been made the exclusive domain of the Department of Labor and Industry by the Legislature. The District Court correctly granted summary judgment in favor of Svees.2
¶17 2. Did the District Court err by concluding the Svees viere ineligible for an award of attorney fees under § 27-8-313, MCA?
¶18 As a general rule, attorney fees are considered to be the burden of the respective litigants in a case. Montana follows the “American Rule,” which provides that, absent statutory or contractual authority, attorney fees will not be awarded to the prevailing parly in a lawsuit. Western Tradition P’ship, Inc. v. Att’y Gen. of Mont., 2012 MT 271, ¶ 9, 367 Mont. 112, 291 P.3d 545. We have recognized equitable exceptions to this rule, but construe them narrowly “lest they swallow the rule.” Trustees oflnd. Univ. v. Buxbaum, 2003 MT 97, ¶ 19, 315 Mont. 210, 69 P.3d 663; Jacobsen v. Allstate Ins. Co., 2009 MT 248, ¶ 23, 351 Mont. 464, 215 P.3d 649. We have rejected the expansion of such equitable exceptions when the effect would “drive a stake into the heart of the American Rule.” Jacobsen, ¶ 22 (quoting Mountain West Farm Bureau Mut. Ins. Co. v. Brewer, 2003 MT 98, ¶ 40, 315 Mont. 231, 69 P.3d 652).
¶19 Svees moved for recoveiy of costs and attorney fees in the District Court on three bases: 1) The supplemental relief provision of the Uniform Declaratory Judgments Act (UDJA); 2) § 25-10-711(1), MCA (relating to recovery from a governmental entity when a suit or defense was frivolous or in bad faith); and 3) the Foy exception to the American Rule. The District Court denied relief on all three grounds. We conclude Svees are entitled to attorney fees under the UDJA, and *166address that single basis for relief.
¶20 As we explained in United Nat'l Ins. Co. v. St. Paul Fire Marine Ins. Co., 2009 MT 269, ¶ 38, 352 Mont. 105, 214 P.3d 1260, the threshold question for an award of attorney fees is "whether the equities support an award.” One of these equitable considerations is whether the parties are similarly situated. In United Nafl, we reasoned that because the parties were similarly situated, the equities did not support an award of attorney fees. United Nat'l, ¶ 39. Similarly, in Mungas v. Great Falls Clinic, LLP, 2009 MT 426, ¶ 46, 354 Mont. 50, 221 P.3d 1230, we held the equities did not support an award of attorney fees where the subject action involved partnership agreements entered into by sophisticated and well-informed parties dealing with one another on equal footing. Likewise, in Ahlgren, ¶ 19 and New Hope Lutheran Ministry v. Faith Lutheran Church of Great Falls, Inc., 2014 MT 69, ¶ 76,374 Mont. 229,328 P.3d 586, we denied attorney fees because the parties to the cases were situated in similar positions and on equal footing.
¶21 The case here is distinguishable from those noted above in that the parties here are clearly not similarly situated or on equal footing. The Svees sought to accomplish a low-cost repair of their roof in response to a notice from their insurance company about cancellation of their coverage. By so doing, they were named as defendants in both criminal and civil actions filed by the municipal government, in comparison to whom they had significantly less resources to litigate the alleged violation of the ordinance. As such, the equitable threshold consideration is satisfied.
¶22 The next step is to apply the tangible parameters test articulated in Buxbaum. There, this Court recognized the propriety of an attorney fee award in declaratory judgment actions. We held that district courts possess authority to award attorney fees under the supplemental relief provisions of the UDJA as “necessaiy or proper.” Buxbaum, ¶ 46. We stated that while supplemental relief provisions are typically provided in the context of an insurer/insured relationship, "we need not limit application” to that arrangement. Buxbaum, ¶ 42. Noting that the “necessary or proper” language is nebulous, we adopted an analytical framework from the Ohio Court of Appeals to articulate tangible parameters for trial courts to use when analyzing this issue. Buxbaum, ¶ 43. These parameters contemplated a situation in which the “necessary or proper” requirement would be satisfied. Buxbaum, ¶ 44. We restated those tangible parameters in Renville v. Farmers Ins. Exch. as situations in which: 1) an insurance company possesses what *167the plaintiffs sought in the declaratory relief action; 2) it is necessary to seek a declaration showing the plaintiffs are entitled to the relief sought; and 3) the declaratory relief sought was necessary in order to change the status quo. 2004 MT 366, ¶ 27, 324 Mont. 509,105 P.3d 280.
¶23 The District Court concluded that Svees were not entitled to attorney fees, reasoning that:
The firstfactor of the tangible parameters test does not apply here because there is no insurer or self-insurer involved. Further, a declaratory judgment action was the procedural course chosen by the Svees, who could have opted to litigate their position in the context of the suit filed by the City. A declaratory judgment action was not necessary to address the validity of the ordinance ... . Svees’ decision to litigate the validity of the ordinance through the UDJA does not entitle them to attorney fees per se. If such were the case, attorney fees should arguably be awarded in every declaratory judgment action challenging a government action.
¶24 Contrary to the District Court’s reasoning, we stated in Buxbaum, as noted above, that we did not intend to define the exclusive circumstances that would justify an award, specifically, to only the insurance context. Buxbaum, ¶ 42. Buxbaum was limited in this regard, describing but one instance in which attorney fees are “necessary or proper” under the terms of the UDJA. The court’s conclusion that the first prong of the tangible parameters could not be met because it was inapplicable was incorrect.
¶25 With respect to the second prong of the test, we conclude that a declaratory action was necessary. At the instance of notice from their insurer, Svees undertook a small project to replace damaged wooden shingles on their roof, and limited the scope of their repairs due to personal financial constraints. As a result, the Svees found themselves defending legal actions brought by the City, first a criminal action and then a six-count civil action, resulting in three years of litigation and the incurrence of substantial legal fees by Svees. While the District Court reasoned that the Svees could have opted to litigate within the context of the legal action initiated by the City, it was both appropriate and necessary for the Svees to file a declaratory action to get to the root of the City’s multiple claims — the validity of the ordinance itself, from which the City drew its authority. A declaratory action solely challenging the ordinance was the quickest and most direct path to resolution and relief, in light of the City’s multiple enforcement actions.
¶26 The final prong of the test is satisfied when a declaratory *168judgment action is necessaxy to change the status quo. Here, the city initiated legal proceedings based upon the "status quo” — the enacted ordinance. In order to change the status quo, Svees initiated this action to challenge the validity of the ordinance. In Martin v. SAIF Corp., 2007 MT 234, ¶ 27, 339 Mont. 167, 167 P.3d 916, we held that attorney fees in favor of SAIF were inappropriate because the declaratory action at issue failed to change the status quo with respect to SAIF. There, the Oregon Worker's Compensation Board (Board) had determined SAIF (a state-chartered worker’s compensation insurance company) was entitled to a share of Martin’s third-party tort action award as subrogation for benefits paid to Martin following an accident. Martin, ¶ 7. Because SAIF was already entitled to its portion of the tort settlement per the Board’s decision, it was not necessary for SAIF to seek a declaration from the Montana court in order to change the status quo, and, thus, the third prong of the tangible parameters test was not met. Martin, ¶ 27. Unlike the situation in Martin, Svees did not initiate this action to enforce the status quo, but rather sought to alter it. The third prong of the tangible parameters test is thus satisfied.
¶27 Because the equitable considerations merit an award of attorney fees and the Svees have satisfied the tangible parameters test, we conclude it was an abuse of discretion for the District Court to deny an award of attorney fees. While § 11-41-2 has been found invalid, the Svees have technically prevailed but are left only with a legally patched roof and significant legal bills. Accordingly, we reverse the District Court’s decision to deny attorney fees and remand for proceedings to determine the appropriate amount of fees to be awarded.
¶28 3. Did. the District Court err when denying and dismissing the Svees’s constitutional arguments?
¶29 The Svees made several constitutional claims for relief within their motion for summary judgment, which the District Court dismissed. The District Court stated that it would be "inappropriate... to address or resolve any constitutional challenges” because the order granting summary judgment in favor of the Svees effectively “resolve[d] the case in the Svees’ favor on non-constitutional grounds.” ¶30 Svees cross-appeal the denial and dismissal of those claims, but acknowledge in tkeir briefing that, if the District Court’s order is affirmed, then it is unnecessary for this Court to address their constitutional claims. This Court has repeatedly recognized that courts should avoid constitutional issues whenever possible. Merlin Myers *169 Revocable Trust v. Yellowstone Cnty., 2002 MT 201, ¶ 24, 311 Mont. 194, 53 P.3d 1268. Accordingly, the District Court’s dismissal of these claims is likewise affirmed.
¶31 Affirmed in part, reversed and remanded in part.
JUSTICES COTTER, McKINNON and SHEA concur.