Thanks for posting your query.
From description , it seems you might develop cervical strain.
I would suggest getting this evaluated by an orthopedician for an accurate diagnosis and appropriate management. You may get the X-ray/MRI
of the area affected under his/her guidance.
You can take analgesic
and muscle relaxant
after discussing with your doctor.
I also advice-
Do not sit for prolonged period of time in stressful posture
Do not lift heavy weights on head or back
Do the exercises prescribed regularly
Do use firm mattress, thin pillow or butterfly shaped pillow.
Wishing you good health.
Dr Saurabh Gupta.