Wigan failed to shake off determined Castleford as the Tigers claimed a creditable engage Super League point at the Jungle.
The struggling Tigers, three points adrift at the bottom of the table before the game, led for most of a blustery afternoon after tries from Ryan McGoldrick, Andrew Henderson and Peter Lupton.
Yet Wigan were much stronger in the second half and fought back to twice take the lead through Pat Richards, Trent Barrett, Micky Higham and Thomas Leuluai.
Crucially for Castleford, Craig Huby landed four goals.
Castleford, surprise winners over Leeds, Warrington and St Helens this season, looked in the mood to take another notable scalp early on.
The Tigers had much the better of the first and led from the fifth minute as McGoldrick, sporting a distinctive mohawk hairstyle, dived onto a Brent Sherwin and clung on to touch down.
Henderson doubled the lead midway through the opening period when he spotted a gap from dummy half 10 metres out and ran through to the line unchallenged.
Huby converted both tries to give the Tigers a healthy early lead.
Wigan worked a smart move to allow Richards to halve the deficit. The winger broke clear down the left, cut inside and then won the chase to his own kick to score his 10th try of the season. The Australian himself converted from out wide.
Yet it was Castleford who still finished the half stronger. Huby made it 14-6 with a penalty and Luke Dorn was stopped just short of the line after being put through by a McGoldrick pass.
Huby was then held over the line on the next tackle as Wigan prevented further damage.
The Warriors pulled themselves right back into the game within three minutes of the restart as Trent Barrett made a dart for the line.
The stand-off was clipped by substitute Ryan Boyle but regained his feet and dived under the posts for a try easily improved by Richards.
Yet Wigan could not gain firm control and it took desperate defending to prevent Henderson stretching over for a second try. Cas also showed efficiency at the other end of the field when Sherwin coolly dealt with a kick from Thomas Leuluai.
A hole was found just after the hour, however, as George Carmonc burst through a tackle, he was hauled down by Michael Shenton but Higham scooped up the loose ball to put Wigan ahead for the first time.
Castleford responded with Sherwin catching the defence flat footed and sending Lupton crashing over and Huby's conversion gave the Tigers a two-point lead.
The lead changed hands again with eight minutes remaining as Wigan worked the ball along the line and Leuluai wriggled through a gap to make his way to the line.
Yet Richards was unable to add the extra points and Huby levelled the scores with a penalty soon after.
Sherwin attempted to win the game as the clock ran down but Stuart Fielden blocked his drop-goal attempt.