It's possible that mechanim's humanoid system prefers the bones to have a particular orientation to them, and it's automatically trying to fit your bones to that orientation, which causes the arms to rotate backwards.
In blender, go to edit mode of the armature and enable Object Data > Display > Axis. This allows you to see the current roll of each of your bones. Then in the properties panel > Transform with a bone selected, you can change the roll of that bone. If the arms are rotating 180 degrees in unity, then I would suggest rolling each of the arm bones by 180 degrees to see if this fixes the problem.
Also, it is helpful for ik solvers (like what mechanim uses) if the resting pose of the appendages are slightly bent indicating which way the appendage should bend toward. For example, you could change the t-pose of your character to have slightly bent elbows which would indicate to the solver the the arms should bend in that particular way, and this could help Unity set up the orientations correctly.