The odd thing is that after all the years of being staunchly British, Gibraltar might well accept. They were 95% in favour of the EU. Having that border heavily restricted will be a nightmare for them.
If there's another Scottish independence referendum, Scotland would gain independence from a NON-EU country (UK) and then apply to join. This is similar to the situation with Slovenia, which gained independence from Yugoslavia and then joined the EU. Spain didn't veto that.
Very slim chance though, seeing as it was mostly the Labour heartland that voted for Leave.