You have to keep the auto for the left/right part of the margin.
auto
That error message is a little confusing I agree.