it happens quite a bit in games that mex ownership swaps quickly. sometimes area build will let you get it even if it always says red when usually. most of the time it doesn't have anything to do with how close your buildings are to the metal spot when it happens.
Something I noticed with area build, if a particular mex point denies you construction, expanding the circle to include another mex point which you can build on allows you to build on the bugged mex. This is a pretty consistent work around for me. The problem is that if the other mex you include on the circle is also bugged, then you need to expand the circle further and hope for a valid mex point in the circle.