Judge orders US border agents to improve arrest documentation