A 40-year-old man is evaluated in the emergency department for a headache that started 1 day ago while he was lifting weights. He first experienced a severe, sharp, right periorbital pain associated with nausea and ipsilateral neck pain. Although the pain has lessened in intensity, it has persisted, and this morning he had an episode of right monocular visual loss resolving spontaneously after several minutes. The patient has a history of monthly migraine without aura that typically lasts 6 hours and is characterized by bilateral frontotemporal throbbing, pain associated with photophobia, and nausea. He says that his current headache pain is “different” from the pain he experiences during migraine episodes and that the neck pain is new. His only medication is naproxen as needed.

On physical examination, blood pressure is 130/86 mm Hg and pulse rate is 72/min. Palpation of the neck elicits pain. Right ptosis and miosis are noted, but all other physical examination findings are unremarkable.

A CT scan of the head shows normal findings.

Which of the following is the most likely diagnosis?