Metals producers, from miners to smelters, are grappling with increasingly tough and costly environmental demands imposed by banks seeking cleaner investments. While the transition may prove overwhelming for smaller producers, larger companies are playing a long game, casting ahead to a period where greener technology helps slash their costs.