The Florida Supreme Court approved a sweeping overhaul of the state's congressional districts on Wednesday, a move that will upend the political landscape ahead of the pivotal 2016 elections.

The justices ruled 5–2 in favor of the new boundaries for many of Florida's 27 districts. The ruling signs off on the map that Circuit Judge Terry Lewis approved earlier this year.

The map would likely force Central Florida Rep. Dan Webster (R-District 10) to move districts to remain in office. It also could lead to the end of Rep. Gwen Graham's (D-District 2) rising career and would make it harder for South Florida U.S. Rep. Carlos Curbelo (R-District 26) to get re-elected.

Some hope the ruling will end nearly four years of lawsuits, hearings and special sessions over the districts.

Justice Barbara Pariente, who wrote the majority opinion, said the ruling should "bring much needed finality to litigation concerning this state's congressional redistricting that has now spanned nearly four years in state courts."

But the new map could quickly come under further legal attack. U.S. Rep. Corinne Brown (D-District 5), whose district would be shifted from a north-south alignment that reaches into Orlando to one that stretches from Jacksonville to Tallahassee, has already promised to resume a federal lawsuit against the proposal. She said the map violates federal law.

Side-by-side comparison of some heavily impacted regions

Use the sliders below to compare the current districts with the approved map.

District 5 (Current Rep. Corrine Brown, D)

District 10 (Current Rep. Dan Webster, R)

Districts 13 (Current Rep. David Jolly, R) and 14 (Current Rep. Kathy Castor, D)

Districts 26 (Current Rep. Carlos Curbelo, R) and 27 (Current Rep. Ileana Ros-Lehtinen, R)

Florida voters in 2010 approved the "Fair Districts" standards, which say that legislators cannot draw districts intended to help incumbents or a member of a political party. A coalition of groups, including the League of Women Voters of Florida, challenged that the congressional map first approved by legislators in 2012 violated the new standards.

Legislators approved a second map, but in a stinging ruling in July, the state court said GOP operatives had "tainted" previous efforts to draw up maps and ordered that eight districts be redrawn.

GOP leaders returned during an August special session to adopt a third map, but they deadlocked over which map to pass. Lewis recommended a map similar to one proposed by legislators, but he endorsed changes to South Florida congressional districts including Curbelo's.

While the majority of justices approved the map, two dissented from the decision. Justice Ricky Polston sharply criticized the decision because Lewis had relied on a map that was drawn with the help of a firm that works for Democratic candidates. He said that decision violates the standards adopted by voters that were intended to rid the process of partisan influence.

Read the Florida Supreme Court's Final Opinion