It sounds like you are experiencing a post-infective cough. This is a persistent cough that continues after the acute illness is complete. It appears that your cough is slowly self resolving, which is good to hear. It can take 3-6 weeks to completely resolve.
The cough tends to be worse at night because of post nasal drip
. This is when mucus from your nasal passages drop back onto your throat (especially if you are lying flat on your back) and stimulate a cough reflex. If these symptoms are disturbing your sleep try taking a cough suppressant (like Robutussin) or sleeping with your head slightly elevated at a 45 degree angle.
You are also experiencing coughing headaches
. These are usually short, sharp stabbing headaches that appear suddenly with a coughing fit. If this sounds like what you are experiencing, then they tend resolve spontaneously. If your headaches are severe you may benefit from a beta blocker
(eg.propanalol) that relax the vessels and reduce the pressure in the brain. Please see a doctor before starting any medication.
If you are experiencing any dizziness
, blurred vision
or any abnormal sensation with this headache it is important that you see a doctor.