Sounds like possibly pleurisy, or possibly an irritation of the Vagas nerve, possibly related to indigestion. Do you happen to drink anything caffeinated or carbonated right before bed?
Hi, it sort of sounds like pleurisy to me, but there are all kinds of lung disorders and inflamatory things that can affect the lungs and ribcage etc. and only a lung doctor or your regular doctor can properly diagnosis that.
Once in my twenties I had pleurisy and it really was uncomfortable to breathe I can't remember going to the doctor (I would now) and it just went away. Just to be on the safe side, I would go see a doctor. Hope you feel better soon. Sharon