Costs and attorney fees may be awarded to either party as justice and equity require. The court may order that the amount be paid directly to the attorney, who may enforce the order in the attorney’s name in the same case.