“We’ve agreed on the basics, but we need to hammer out the details.”

Hammering something out suggests working hard on something and getting it finished quickly. Imagine a blacksmith hammering at a piece of metal. He has to work hard, and he must work quickly before the metal cools down too much.