Green spaces and smart design choices can help cities prepare for more weather extremes. And studies find that the investment is well worth the cost.