Maryland is one step closer to becoming the first U.S. state to ban foam containers, a move that would push restaurants to find alternatives for their takeout boxes and could lead to more states to similar action by others states.

The state House of Delegates on Wednesday passed a bill that would ban polystyrene containers and cups. If Republican Gov. Larry Hogan signs the bill into law, county officials could issue $250 fines to offenders. The bill includes several exceptions, such as products packaged outside of Maryland.

Polystyrene foam take-out containers and cups are durable and waterproof — but also difficult and costly to recycle. The foam can also break down into tiny pieces, polluting streets and waterways.

While Maryland could be the first state to ban foam containers, some cities have imposed their own bans, including New York, Seattle, Washington and Minneapolis.

It isn't just lawmakers pushing for more sustainable restaurants. Consumers want to spend their money without harming the environment. According to a Nielsen survey, 48 percent of Americans said they would definitely or probably change their spending habits to reduce their environmental impact. Last year, consumer pressure led companies like Starbucks and Disney to ditch plastic straws.

Despite the consumer demand for greener restaurants, the industry has largely been slow to respond. Swapping out foam takeout containers and cups will likely be costly for restaurateurs already struggling with razor-thin profits.

However, Green Restaurant Association CEO Michael Oshman said choosing a holistic approach to sustainability, including switching to toilets that use less water and using more efficient lightbulbs, usually offsets the additional costs of adapting and even helps the bottom line.

Some affected by foam bans will likely opt for another type of single-use plastic container or cup, but the restriction also offers the opportunity to make a greener choice to appeal to consumers who care about the environment.

As the adage "reduce, reuse, recycle" goes, the first and best option should be to reduce usage. But with the swell of delivery thanks to third-party services, that's not likely to happen.

The second, reuse, is a little more difficult to implement when it comes to takeout cups and containers. One possible option is deposit systems that encourage customers to return reusable packaging or containers. But Oshman said those are still in their infancy, with less than a fraction of 1 percent of the industry choosing to handle the problem that way.

That leaves recycling. Restaurants can opt for containers that are easily recycled or made from recycled material. Chains like Sweetgreen are adopting compostable containers.

But that option comes with its own difficulties. Some compostable containers require industrial composting that uses higher temperatures to break the material down, instead of biodegrading in an at-home compost heap. And most customers taking their food home or back to the office won't have access to a compost heap.

"Curbside composting is not there yet," Oshman said. "That compostable product ends up in the garbage."

Restaurants will also have to navigate consumer reactions. Amid 2018's plastic straw debate, some Starbucks customers reacted less than enthusiastically to the news that the coffee chain was phasing out straws for most of its drinks in favor of a new sippy cup-esque lid.

Disability rights advocates expressed concern that the move would mean that customers with disabilities could face difficulties drinking iced beverages. Others pointed out that the new lid would actually use more plastic than the straw and old lid combined.

Starbucks listened to the concerns. It tweaked the design of the new lid, which is also made of more recoverable material than a straw, and offers compostable plastic straws upon request.

"We have worked to lightweight that lid, so we're able to validate that the solution, at the end of the day, has a net negative plastic use," Starbucks' global director of environment Rebecca Zimmer said last month.