St Johnstone battled back to claim a Scottish Cup fifth-round replay against top flight rivals Hearts.
David Templeton beat Peter Enckelman at his near post to give the home side a 10th-minute lead.
St Johnstone captain Dave MacKay was sent off on 74 minutes after picking up two bookings.
However, the visitors managed to find an equaliser when Cillian Sheridan beat the offside trap and tucked home three minutes later.
The two sides will meet again at McDiarmid Park on 14 February.
Hearts were lively from the off and made the breakthrough when Templeton cut in from the left and dispatched a low shot past Enckelman.
Saints probed in search of an equaliser but Francisco Sandaza took a fresh-air swipe at David Robertson's cross.
Templeton almost created a second for his side with a burst into the box but Scott Robinson mis-hit his shot.
Sandaza headed against the crossbar from substitute Sheridan's cross early in the second half.
Hearts then claimed unsuccessfully for a handball against MacKay in the St Johnstone box.
David McCracken headed over and Liam Craig drew a save from Jamie MacDonald as the Hearts goal came under continued pressure.
At the other end, Stephen Elliott could not get enough purchase on his header after meeting Templeton's lofted cross.
St Johnstone's chances suffered a blow when MacKay's high boot connected with Templeton and the defender was punished with a second yellow and subsequent red card.
Moments later, Sandaza got in behind the Hearts defence but his downward volley lacked power and MacDonald gathered.
But Sheridan, who had replaced Robertson, was more successful in front of goal after running on to Sandaza's pass and placing the ball round MacDonald as the keeper came off his line.
A weaving run and shot by Templeton was claimed at the second attempt by Enckelman as the action became frantic in the closing stages.
But there to be no more goals before close of play.