If the craziest and most contentious presidential election in modern history is making you feel somewhat lightheaded, a little disoriented, maybe even a tiny bit stoned, well, just you wait.

Lost amid the endless (and sometimes endlessly entertaining) stream of insults, scandals, and outright atrocities of the 2016 campaign is the fact that it isn't just the leadership of the free world at stake on Nov 8. Voters in California, Massachusetts, Maine, Arizona, and Nevada will also decide whether to legalize recreational marijuana—and it looks like most will vote yes although Nevada is still iffy. (Update: The measures passed in every state but Arizona.)

They'd be joining Alaska, Colorado, Oregon, and Washington, which permit the recreational use and sale of marijuana. Washington, DC, allows recreational use but not retail sales.

Samples on display at Farma, a marijuana dispensary in Portland, Oregon. Josh Edelson/AFP/Getty Images

Why should everyone, even cannabis abstainers, care? Because when it comes to housing, economics, and lifestyle, this could be a national game changer.

If these ballot initiatives pass on Tuesday, some form of legal marijuana will be available in about half the states in the nation—not only making stoners happy but potentially creating more than 100,000 new jobs and billions of dollars in new tax revenues. California, the most populous state in the U.S., boasts the sixth-largest economy in the world. (The Golden State was also the first to legalize medical marijuana, in 1996.)

Although marijuana remains a Schedule 1 drug that is illegal under federal law, state legalization opens the door to new, above-board industries, adding jobs and tax revenue, while toking tourists in the communities where it will be sold. (Sales of the green stuff might be allowed in a state, but not in every municipality.)

And yes, legalization of recreational marijuana is likely to have a big impact on home buyers, owners, and sellers. Home prices have already risen in the four states where it's legal.

But that doesn't mean that all homeowners in states getting the ganja go-ahead will benefit equally. The realtor.com® data team analyzed residential real estate in the recreational marijuana states and found that certain kinds of cities typically benefit more than others.

Also, a home's proximity to a marijuana business affects its value—although not always in the way you'd think.

So let's light this up, shall we?

How pot gets home valuations higher

The prospects of employment—as well as the desire to legally grow, buy, enjoy, and otherwise self-medicate with weed—have led to an increased demand for housing. Simply put, more people seem to move to states with legalized marijuana, boosting home prices.

"The legalization affects both the demand and the supply in the residential housing market," says University of Mississippi economics professor Cheng Cheng, one of the authors of a study on how legalizing retail marijuana in Colorado has given a lift to local real estate. Areas where it's legal are "going to attract more home buyers, including marijuana users as well as entrepreneurs and job seekers."

states-01

Legal marijuana draws transplants to Colorado

The state of Colorado provides the best data on what happens when recreational marijuana is permitted, since it has been legal there the longest. The Centennial State legalized medical marijuana in 2000 and then medical dispensaries in 2010. Two years later, voters approved recreational sales of the green stuff. (Check realtor.com economic portal for Colorado home price).

Since the first shops opened their doors on Jan. 1, 2014, the median home sale price in the state has shot up from $248,000 in the first half of 2014 to $298,000 in the first half of 2016, according to the realtor.com analysis.

That's partly due to the state's population surge, rising 1.9% from July 1, 2014, to July 1, 2015, according to the U.S. Census. That makes it the second-fastest-growing state in the nation, just behind North Dakota. There's no direct evidence tying the legalization of the drug to the population boom, but real estate agents say more of their clients are relocating to the state because of it.

"About 60% to 70% of my clients are buyers coming in from out of state," says real estate broker Rona Hanson, of Need Room to Grow Realty in the Denver suburb of Lakewood, CO. She specializes in selling homes where buyers can grow their own cannabis.

The Clinic, one of the larger marijuana retailers in Denver. John Leyba/The Denver Post via Getty Images

Of course, marijuana isn't the only lure. The state has a reputation for being an outdoorsy paradise, and many tech, financial, and other large companies are expanding operations there. It's also receiving refugees from more expensive cities such as San Francisco and New York.

For many Colorado transplants, the ability to pick up a bag of legal weed or some cannabis-laced edibles is "an added bonus," says Boulder-based Realtor® Jennifer Egbert of Re/Max Alliance Downtown. But she adds that many marijuana-using transplants fall in the medical category.

Home prices tend to be higher in the roughly 60 Colorado cities and towns where cannabis is legal than the more than 200 where it's not.

For example, where cannabis is legal, the median sold price was $302,500 in the second quarter of 2016, according to the realtor.com analysis. That's 13% higher than the $267,200 median sold price in the more than 200 localities where the green stuff is illegal.

In addition, homes have been appreciating by 12% annually since 2014 where it's legal. That's compared with just 9% in areas where it's illegal.

colorado-01

But some marijuana businesses are bad for local home values

So it's nothing but green, resin-coated pastures, right?

Not so fast. Within the areas that have legalized marijuana, there's a bit of a cannabis caste system.

Colorado homes within a half-mile of a marijuana business often have lower property value than homes in the same county that are farther out. But not all marijuana business are a buzzkill for home values.

Neighborhoods with grow houses are the least desirable, with an 8.4% price discount. But retail shops, especially with the rise of the new generation of stylish pot boutiques, have almost no negative impact.

states-02

Just look at Denver's marijuana business locations in the map below. Grow houses (blue dots) tend to bypass the most desirable, upscale neighborhoods and find their way into more inexpensive ones. The places with the highest number of marijuana businesses per capita are Elyria Swansea, Globeville, and west Northeast Park Hill, according to the Denver Post. All three are low-income neighborhoods.

Perhaps that's partly due to the literally stinky business of growing cannabis—even with the use of air purification systems, the odor tends to permeate the immediate area, so many folks don't want to live near large grow sites.

"I believe what we are seeing is that the marijuana industry is buying up real estate. And in Denver, those three neighborhoods are really the cheapest you can buy,” says Candi CdeBaca, a longtime resident of Globeville whose home faces a large marijuana grow operation.

Since the areas are cheap to begin with, there is more potential for home price growth—CdeBaca says her property taxes have been soaring.

denver-01

There wasn't enough data available to run similar analyses in Alaska and Oregon, where recreational shops only opened last month. Our data team didn't include Washington state because the list of cities that permit sales was murky, as some cities where it was legal have now issued a moratorium on sales licenses.

Ajoya is a new marijuana dispensary in Louisville, CO, designed by Roth Sheppard Architects. Cyrus McCrimmon/The Denver Post via Getty Images

Why small towns can get the biggest highs

But while marijuana businesses themselves may be associated with lower home values, they can give sorely needed economic support to struggling small towns.

In Colorado's rural Clear Creek County, a local mine that has provided the bulk of the county's tax revenue plans to close within the next few years. However, some of that money is being replaced by the marijuana industry, which kicked in more than $125,000 this year through August, according to the state's Department of Revenue.

"We have more tax revenue for schools," says area Realtor Joshua Spinner, of Clear Creek Realty Colorado. "There are people moving to our county because it is more rural and they do want to grow."

Another big beneficiary is Edgewater, just 15 minutes outside Denver. The tiny town has about a half-dozen dispensaries that stay open hours later than those in Denver. Could it be a coincidence that median sold home prices in Edgewater have jumped 18% annually since 2014, compared with 13% in Denver?

The new green economy may not be all it's cracked up to be

Many of the jobs created by legalized marijuana are lower-paying positions, like store clerks. Jeffrey Rotman/Getty Images

However, it's not all peace, love, and high home prices. Many of the jobs created by the marijuana industry tend to be menial, like shop clerks, drivers, and agricultural workers.

In Oregon, for example, the more than 2,100 jobs created by the cannabis industry are expected to earn about $46 million in 2016, according to the Oregon Cannabis Jobs Report. But only about 1,300 of those employees work full time. And many of them, such as bud tenders and managers, make only $11 to $25 an hour—which is just $22,880 to $52,000 a year.

Those lower salaries can make buying a home, let alone paying rent each month, quite a challenge.

Still, as more lenient attitudes toward marijuana take hold across the nation, it may benefit an area's image to get on the legalization bandwagon.

"We see a lot of people looking to move to Portland, and one of the attractions is the fact that we have legalized marijuana," says real estate broker Lathen Gorbett of M Realty in Portland, OR, adding that many of these folks aren't even smokers.

"They see that we are a liberal, forward-thinking city."