FILE - In this Sept. 22, 2016, file photo, business owners in the new marijuana industry mingle at a political fundraiser in Denver. Denver has approved a first-in-the-nation law allowing people to use marijuana in bars and restaurants. Denver voters weighed in on Proposition 300 as eight other states legalized marijuana for medical or recreational purposes last week. The city measure would let a certain number of bars and restaurants to apply to allow marijuana use. Some ballots remained uncounted. (AP Photo/Kristen Wyatt, File)

DENVER (AP) — A glass of wine with dinner? Or maybe some marijuana?

Denver voters have approved a first-in-the-nation law allowing willing bars and restaurants to give patrons the option to use marijuana alongside a cocktail or meal. The catch: Smoking pot won’t be allowed inside, and the locations would have to first get the approval of neighbors.

Denver voters approved Proposition 300 on the same day that the nation’s largest state of California and two others legalized pot for all adults and five more states approved pot for sick people — signs of society’s increasing tolerance for the drug.

“It’s the sensible thing to do,” said Emmett Reistroffer, a Denver marijuana consultant and campaign manager for the pot-in-bars measure. “This is about personal responsibility and respecting adults who want to have a place to enjoy cannabis.”

Denver’s measure takes effect immediately, but it has a lot of caveats.

First, interested bars and restaurants would have to show they have neighborhood support before getting a license to allow marijuana use. In addition, patrons would have to bring their own weed to comply with state law banning the sale of both pot and food or drink at a single location.

Patrons at participating bars could use pot inside as long as it isn’t smoked. The law does provide for the possibility of outside smoking areas under restrictive circumstances. The law also allows for non-service establishments, such as yoga galleries or art galleries, to set up pot-smoking areas or hold events serving both pot and food and drink.

Mason Tvert, a spokesman for the national Marijuana Policy Project and a Denver proponent of the consumption law, said the measure would reduce instances of tourists smoking pot on sidewalks and in parks because they have nowhere private to consume weed.

A Denver billboard promoting the measure featured a large arrow pointing to a sidewalk below, telling voters that without a provision for social pot use, folks will keep smoking pot in plain view.

“We are setting up a system that is still more restrictive than what we see with alcohol consumption,” Tvert said.

Supporters of the measure had no guess on how many establishments would apply for the permits or how long it would take for them to demonstrate community acceptance and receive permits. So it could take many months before Denver sees any Amsterdam-style coffee shops.

The measure sunsets in 2020, unless city officials renew the licenses or voters make the pot-in-bars measure permanent.

Current Colorado law allows jurisdictions to decide for themselves when pot could be used in public. The result is a hodgepodge of local ordinances related to marijuana clubs.

Denver is the first city to allow use in bars and restaurants.

“The entire goal of this initiative is to provide adults with private places where they can consume cannabis so they’re not consuming in public,” said Tvert, who said the initiative helps not just tourists but adults who may not want to use pot in front of their kids, or tenants whose landlords exercise their right to ban pot use.

Alaska is the only state that expressly regulates on-site consumption at pot retailers. However, the state doesn’t allow use in bars or restaurants, and it’s still working on rules for how those pot-shop “tasting rooms” would operate.

Opponents of the Denver measure predicted neighborhoods would resist bars, restaurants and other venues seeking pot licenses. They warned the measure won’t properly protect the public from stoned patrons leaving a bar that allows smoking and drinking at the same time.

“How can these businesses possibly monitor patrons for marijuana intoxication?” opponent Rachel O’Bryan said in a statement Tuesday.

The measure would require any interested bar or restaurant to specially train staff in marijuana use and submit an operations plan to show how it would prevent marijuana use by underage patrons. Applicants must also specify strategies and procedures for identifying and responding to the potential over-intoxication of consumers.

Colorado lawmakers are expected to consider a bill next year to give all jurisdictions a green light for allowing pot clubs or cafes, though marijuana activists hoped for a similar measure last session and were disappointed.