Hibernian have reached the Scottish Cup semi-finals after beating Kilmarnock in a six-goal encounter at Rugby Park.
Leigh Griffiths opened the scoring for Hibs before James Dayton levelled.
Matt Done regained the advantage for the visitors, but this was cancelled out by Paul Heffernan's penalty.
Griffiths grabbed a second, before Ross Barbour saw red for a pull on the striker, with a William Gros handball allowing Griffiths to score a last-minute penalty and claim a hat-trick.
Hibs join Celtic, Dundee United and Falkirk in Monday's draw for the last four.
Kilmarnock had the better of a scrappy opening to the game, but, despite winning free-kicks in promising areas, could not trouble the Hibs goal.
However, the talismanic Griffiths capitalised on a simple long ball from David Wotherspoon to slot the ball under Killie keeper Cammy Bell and claim his 20th goal of the season.
Killie put pressure on the Hibs defence in search of an equaliser, and the Ayrshiremen drew level when Dayton rifled home on the rebound after Hibs keeper Ben Williams had parried a long-range effort from Gros.
Griffiths at Hibs
Leigh Griffiths is in his second season on loan at Hibernian from Wolves. The 22-year-old former Livingston and Dundee forward has scored 33 goals in 68 games for the Edinburgh side
After a pattern of midfield deadlock, a disastrous mix-up between Bell and Sissoko left a loose ball at Done's feet 12 yards from an empty net, and the midfielder made no mistake.
Heffernan almost dragged his side level on the stroke of half-time, juggling the ball inside the Hibs box before rifling a volley inches past Williams' right-hand post.
The home defence continued to look jittery as the second half opened, and, after losing possession again, Griffiths waltzed into the box, but Bell scrambled his shot away.
Full-back Barbour broke forward for Killie, as the home side's play became more urgent, but his left-footed effort from a tight angle blazed wide of the mark.
New signing Kris Boyd had to wait to make his Killie return though, as Cillian Sheridan replaced McKeown.
The attacking gamble proved wise as Dayton forced a great save from Williams from a left-footed strike at the edge of the box.
However, the officials judged that Lewis Stevenson had bundled over Heffernan as he went for the rebound, and the striker lashed the penalty into the net.
Griffiths then passed up a great chance for Hibs, opting to shoot from a narrow angle with Done waiting in the six-yard box.
But the striker was not to be denied, outpacing Sissoko and robbing the ball from Bell's despairing grasp to slip the ball into the net.
The goal prompted Shiels to bring on Boyd, but the striker was unable to rescue the tie for the hosts.
Barbour saw red as the late drama continued, pulling back Griffiths in a dangerous position.
Then Gros handled as part of the defensive wall at the free-kick, giving Griffiths the chance of a hat-trick, which he claimed with an emphatic penalty strike.
- 01 Bell Booked
- 02 Tesselaar (Boyd - 84' )
- 04 Fowler
- 23 McKeown (Sheridan - 65' )
- 25 Barbour Dismissed
- 88 Sissoko Booked
- 08 Clingan
- 10 Dayton
- 28 Winchester (O'Hara - 79' )
- 09 Gross Booked
- 14 Heffernan
- 17 Letheren
- 03 Hay
- 38 O'Hara
- 11 Boyd
- 12 Sheridan
- 01 Williams
- 03 McGivern
- 06 McPake
- 18 Maybury
- 08 Claros Booked
- 14 Wotherspoon
- 16 Stevenson Booked
- 17 Done Booked (Doyle - 79' )
- 20 Taiwo (Deegan - 79' )
- 28 Robertson
- 09 Griffiths (Harris - 90' )
- 31 Murdoch
- 37 Forster
- 07 Deegan
- 33 Harris
- 10 Doyle
Live Text Commentary
Full Time The final whistle is blown by the referee.90:00 +2:48
The official flags Kris Boyd offside. Ben Williams takes the free kick.90:00 +1:17
James Dayton takes the outswinging corner, Ryan McGivern makes a clearance.89:11 Substitution
Substitution Leigh Griffiths leaves the field to be replaced by Alex Harris.88:47 Goal scored
Goal! - Leigh Griffiths - Kilmarnock 2 - 4 Hibernian Placed penalty scored by Leigh Griffiths. Kilmarnock 2-4 Hibernian.88:16 Booking
Booking William Gros receives a yellow card for unsporting behaviour.88:12
William Gros is penalised for handball and concedes a .86:52
Strike comes in from Leigh Griffiths from the free kick, William Gros gets a block in.86:52 Dismissal
Dismissal The referee shows Ross Barbour a red card for serious foul play.86:50
Leigh Griffiths fouled by Ross Barbour, the ref awards a free kick.85:50
Kris Boyd challenges James McPake unfairly and gives away a free kick. James McPake takes the direct free kick.85:01
William Gros produces a left-footed shot from just outside the box that misses to the right of the net.83:16
Inswinging corner taken by James Dayton from the right by-line, David Wotherspoon manages to make a clearance.83:16 Substitution
Substitution Kris Boyd comes on in place of Jeroen Tesselaar.81:51
The assist for the goal came from James McPake.81:51 Goal scored
Goal! - Leigh Griffiths - Kilmarnock 2 - 3 Hibernian Leigh Griffiths finds the back of the net with a goal from inside the six-yard box to the bottom left corner of the goal. Kilmarnock 2-3 Hibernian.80:07
Inswinging corner taken left-footed by Leigh Griffiths from the right by-line to the near post, Close range headed effort by James McPake misses to the right of the target.78:04 Substitution
Substitution Gary Deegan is brought on as a substitute for Tom Taiwo.78:04 Substitution
Substitution Eoin Doyle comes on in place of Matt Done.78:04 Substitution
Substitution Mark O'Hara is brought on as a substitute for Jude Winchester.
The ball is crossed by Paul Heffernan.75:20
Leigh Griffiths takes a shot. Save made by Cameron Bell.71:36 Goal scored
Goal! - Paul Heffernan - Kilmarnock 2 - 2 Hibernian Power penalty scored by Paul Heffernan. Kilmarnock 2-2 Hibernian.70:36 Booking
Booking Lewis Stevenson is cautioned by the ref for unsporting behaviour.70:23
James Dayton takes a shot. Save by Ben Williams. Penalty awarded for a foul by Lewis Stevenson on Paul Heffernan.69:00
David Wotherspoon fouled by Jeroen Tesselaar, the ref awards a free kick. Free kick taken by Jorge Claros.68:01
Ross Barbour fouled by Leigh Griffiths, the ref awards a free kick. Direct free kick taken by Ross Barbour.66:28
Jude Winchester concedes a free kick for a foul on Tom Taiwo. Free kick crossed by Leigh Griffiths, James Fowler makes a clearance.65:36
Sammy Clingan delivers the ball from the free kick right-footed from right channel, clearance made by James McPake.65:36 Booking
Booking Matt Done is booked.65:21
Free kick awarded for an unfair challenge on William Gros by Tom Taiwo.63:47
Free kick taken by Cameron Bell.63:47 Substitution
Substitution Cillian Sheridan comes on in place of Rory McKeown.63:47
Scott Robertson is flagged offside by the assistant referee.62:54
Leigh Griffiths produces a strike on goal direct from the free kick.62:54 Booking
Booking Booking for Mohamadou Sissoko.62:50
Unfair challenge on Leigh Griffiths by Mohamadou Sissoko results in a free kick.60:57
Matt Done gives away a free kick for an unfair challenge on Mohamadou Sissoko. Mohamadou Sissoko takes the direct free kick.60:19
Scott Robertson gives away a free kick for an unfair challenge on Jeroen Tesselaar. Cameron Bell takes the direct free kick.56:31
Free kick awarded for a foul by David Wotherspoon on Rory McKeown. Jeroen Tesselaar restarts play with the free kick.53:56
Inswinging corner taken by James Dayton from the right by-line, clearance by Matt Done.52:59
William Gros produces a left-footed shot from just outside the penalty box that misses to the left of the goal.51:12
The assistant referee signals for offside against Leigh Griffiths. Cameron Bell takes the indirect free kick.49:58
Effort on goal by Ross Barbour from deep inside the penalty area misses to the right of the target.48:25
Paul Heffernan is ruled offside. Ben Williams takes the indirect free kick.47:59
Lewis Stevenson gives away a free kick for an unfair challenge on William Gros. Direct free kick taken by James Fowler.47:07
Leigh Griffiths takes a shot. Blocked by Cameron Bell.45:01
The referee gets the second half underway.45:00 +1:13 Half time
Half Time The whistle is blown to end the first half.43:11
Effort from deep inside the area by Paul Heffernan misses to the left of the goal.41:19
Matt Done produces a cross, save made by Cameron Bell.39:21 Booking
Booking Booking for Cameron Bell for unsporting behaviour.38:21
Leigh Griffiths provided the assist for the goal.38:21 Goal scored
Goal! - Matt Done - Kilmarnock 1 - 2 Hibernian Matt Done finds the back of the net with a goal from close in to the bottom left corner of the goal. Kilmarnock 1-2 Hibernian.33:00
Matt Done takes a shot. Blocked by Sammy Clingan.25:54
William Gros provided the assist for the goal. James Dayton takes a outswinging corner.25:54 Goal scored
Goal! - James Dayton - Kilmarnock 1 - 1 Hibernian James Dayton finds the net with a goal from close in to the top left corner of the goal. Kilmarnock 1-1 Hibernian.25:52
William Gros takes a shot. Save by Ben Williams.25:05
Mohamadou Sissoko fouled by Leigh Griffiths, the ref awards a free kick. Sammy Clingan restarts play with the free kick.23:16
The referee blows for offside. Indirect free kick taken by Jeroen Tesselaar.19:03
The referee blows for offside against James Dayton. Ben Williams restarts play with the free kick.18:11
James Dayton takes a inswinging corner from the right by-line to the near post, clearance made by Jorge Claros.17:14
Shot comes in from Sammy Clingan from the free kick.17:14 Booking
Booking Jorge Claros receives a caution for dissent.17:00
Free kick awarded for a foul by Ryan McGivern on Paul Heffernan.16:35
The offside flag is raised against Matt Done. Mohamadou Sissoko restarts play with the free kick.14:54
Assist by James McPake.14:54 Goal scored
Goal! - Leigh Griffiths - Kilmarnock 0 - 1 Hibernian Leigh Griffiths finds the back of the net with a goal from deep inside the penalty box to the bottom left corner of the goal. Kilmarnock 0-1 Hibernian.13:51
Foul by Jude Winchester on Jorge Claros, free kick awarded. Free kick crossed by Jorge Claros, save made by Cameron Bell.11:15
Corner taken by Leigh Griffiths from the right by-line, clearance made by William Gros.10:20
Foul by Ross Barbour on Matt Done, free kick awarded. Leigh Griffiths crosses the ball in from the free kick, Jeroen Tesselaar makes a clearance.9:25
Leigh Griffiths produces a left-footed shot from outside the penalty box and misses left.9:05
Leigh Griffiths is flagged offside by the assistant referee. Sammy Clingan restarts play with the free kick.6:21
Paul Heffernan concedes a free kick for a foul on James McPake. Direct free kick taken by Ben Williams.4:59
Scott Robertson concedes a free kick for a foul on Jude Winchester. James Fowler crosses the ball from the free kick right-footed from left wing, James McPake makes a clearance.4:05
Alan Maybury concedes a free kick for a foul on James Dayton. James Fowler takes the free kick.0:36
Free kick awarded for an unfair challenge on James Dayton by Jorge Claros. James Fowler restarts play with the free kick.0:00
The game kicks-off.
Live data and text provided by our data suppliers