As a precondition to admission , the border with Gibraltar was reopened in 1985 after a 16-year hiatus , and Spain was admitted to the EU in 1986 .
The border was reopened and Spain was allowed into the EU .