Australia took the late wicket of Tagenarine Chanderpaul to even the contest after a fascinating second day's play in the second Test against the West Indies in Brisbane on Friday.
At stumps, the West Indies were 13-1, a lead of 35 runs, after Chanderpaul was given out on review for the faintest of edges off Josh Hazlewood in the last over of the night.
After bowling the West Indies out for 311 in their first innings midway through the opening session of the day-night Test, Australia staged a lower innings recovery, allowing captain Pat Cummins to declare at 289-9 late in the night session.
That decision paid off with the late dismissal of Chanderpaul.
The Australians had got away to a disastrous start to their first innings and were reduced to 24-4 and 54-5.
Kemar Roach, who took three of the first four wickets to fall, said the inexperienced West Indies side wanted to show they belong in Test cricket.
"They want to do well against the number one team in the world, so the guys are really up for the challenge," he said.
"I'm glad of the energy we brought today and it puts us in a pretty even position."
- Carey rescues Australia -
After their poor start, the Australians were rescued by a counterattacking innings from wicketkeeper Alex Carey, who smashed 65 from just 49 balls
"I felt like I reacted well to what was bowled at me and had good intent," Carey said.
"It would have been nice to get a few more but I think to be where are after a difficult start -- we're certainly in this game of cricket."
When Carey was dismissed with the score on 150, the Australians were still 161 runs behind and the West Indies looked certain to take a big lead into the second innings.
But Cummins had other ideas and he and Usman Khawaja (75) took Australia to 242 before the opener edged to first slip to become off-spinner Kevin Sinclair's first Test wicket.
The dismissal sparked a spectacular celebration from Sinclair that included a sprint to cover followed by a round-off and back somersault.
Khawaja's wicket was the signal for Cummins to go even further on the attack and he raced to his highest Test score of 64 in an innings that combined regulation cricket shots with agricultural swipes.
When Nathan Lyon edged Alzarri Joseph to wicketkeeper Joshua Da Silva to become the ninth wicket down, Cummins had had enough and declared to allow his bowlers 35 minutes under lights at the West Indians.
Earlier, Roach rocked the Australians with three quick wickets as the West Indies dismissed Steve Smith, Marnus Labuschagne, Cameron Green and Travis Head before dinner, leaving the Australian reply in tatters.
After hitting a beautiful straight drive off Roach to the boundary in the opening over, Smith was hit on the pad next ball, drawing a huge appeal from the West Indies.
Umpire Nitin Menon said not out but the West Indies reviewed immediately and replays showed the ball would have crashed into middle stump, leaving Australia 6-1.
It was 11-2 in the next over when Labuschagne got a thick edge to fourth slip off Joseph, where Kevin Sinclair took a brilliant diving catch to his right.
Green drove Roach on the up to give a simple catch to Kraigg Brathwaite at mid-off, before Head, who smashed a brilliant 119 in the first Test, was out first ball, tickling a delivery down the leg side.
Mitchell Marsh smashed his way to 21 off just 19 balls but on his 20th, he miscued a pull shot and got a leading edge to mid-off, giving Joseph his second wicket and leaving Australia 54-5.
But like the West Indian first innings, the lower half of the table were able to recover and put the Australians back in the game.