Ben Crooks scored a hat-trick in a losing cause for the second successive match as Hull FC were beaten 27-26 by Wakefield Trinity Wildcats.
Lee Smith's nerveless drop-goal with two minutes remaining settled a dramatic encounter at the KC Stadium.
Winger Peter Fox scored two of the visitors' five tries, while Paul Sykes, Oliver Wilkes and Smith also crossed.
Tom Lineham and Kirk Yeaman were the other scorers for Hull, who missed the chance to go fifth in Super League.
But Wakefield's dreams of emulating their late charge for the play-offs in 2012 remain very much alive, victory taking them within two points of the top eight.
The hosts were in front inside five minutes through young centre Crooks, who crossed four times in the
He continued his impressive scoring form for the Black and Whites, collecting a short pass from hooker Danny Houghton to touch down.
Fox soon levelled with a try in the corner after inventive work from Tim Smith and Dean Collis, before half-back Sykes broke clear and held off a tackle to score.
But Fox turned from hero to villain when his knock-on near his own line gave Hull a free play on the resulting first tackle, which they utilised fully as Lineham strode over unopposed.
The visitors took a six-point lead into the interval as Wilkes evaded Danny Tickle's limp challenge to burst over from close range.
Early in the second period, Crooks scored the try of the match, sprinting the length of the field to bring the hosts back on terms with his second try of the evening and his 18th of a hugely-profitable season.
Hull got over the loss of stand-off Daniel Holdsworth to injury by taking the lead once more, and again it was Houghton the architect for Crooks to complete his hat-trick.
Shortly after Wakefield's Justin Poore had been placed on report for a dangerous tackle on Shannon McDonnell, Richard Agar's men struck again.
Tim Smith's 40-20 kick provided the platform for a set of six that saw Lee Smith dive over, but they remained two points behind as his conversion sailed wide.
However, the Wildcats would edge ahead again with less than 10 minutes remaining, as Kyle Amor broke the line near the halfway line and Fox collected Tim Smith's high bomb to touch down.
Home debutant Jacob Miller produced a stunning high kick of his own that Wakefield failed to deal with and Yeaman pounced, racing in from 20 metres. Tickle's kick went wide and the scores were all square at 26-26 with six minutes to play.
Just as the game looked to be heading for a draw, home full-back McDonnell dropped the ball deep inside his own territory and Lee Smith nailed the drop-goal attempt to seal a last-gasp win for the Wildcats.
VIEW FROM THE DRESSING ROOM
Hull FC head coach Peter Gentle:
"I believe the effort is there but the execution is just nowhere near good enough.
"I'll give them a bit of slack because Jacob Miller has only just come in, but our execution was disgraceful and we're compounding the problem with penalties.
"It's extremely disappointing at the moment. I think we've lost a bit of confidence. I brought the senior players back but I expected more tonight and I don't think we got it.
"We're all frustrated, we've just got to continue to try to get it right. We need to stand up as a team."
Wakefield head coach Richard Agar:
"On balance, I thought we probably had the best of the play.
"It was a scrappy game, and the levels for both sides was not up to where it should be, but I can't fault my players for effort and commitment.
"In the second half we didn't commit as many errors, which was a feature of the game, and when we needed some plays our big players came up with them.
"Hull kicked better than us but we came up with a couple of kicks that won the game."
Hull FC: McDonnell; Lineham, Crooks, Yeaman, T Briscoe; Holdsworth, Miller; Watts, Houghton, O'Meley, Ellis, Westerman, Galea.
Replacements: Lynch, Tickle, Johnson, Heremaia.
Wakefield: Mathers; Fox, Collis, L. Smith, Cockayne; Sykes, T Smith; Poore, Aiton, Amor, Mariano, Kirmond, Washbrook.
Replacements: Raleigh, Lauitiiti, Wood, Wilkes.
Referee: Tim Roby (RFL).