Greetings all! It is very hard to explain what I am trying to do but any feedback from the community would save me around 5 hours of excell work

This is a sample of the data that I start with, notice the rows with "area codes" are repeated, this is actually of the same type of information:
before.GIF

The following is what I want to convert it to, bare in mind that I am talking of over 6000 rows of information, spanning across several excel files!
after.GIF

Notice I consolidate all the area code columns into one but preserving the rates, country values. I have done some serious excel manipulation in my time, but I have hit a roadblock after a lot of googling; The only way to explain what Im trying to do is those dumb pictures, any help would be appreciated