Crossbencher reaches deal with prime minister after Wentworth byelection cost Coalition its one-seat majority