PORTLAND — Authorities shut down the inbound lanes of the Casco Bay Bridge for nearly three hours Wednesday during the height of the evening commute between Portland and South Portland because of a suicide threat.

About a half-dozen uniformed and plainclothed police officers were on the bridge talking to a man who was threatening to jump, beginning around 5 p.m. The man was seen hanging on the outside of the guardrail, with his feet on the base of the walkway.

Both lanes into Portland were blocked, and police were diverting pedestrian and bicycle traffic. The southbound lanes of the bridge headed toward South Portland remained open.

Negotiators talked the man off the bridge around 7:45 p.m. He was taken to Maine Medical Center for evaluation.