Title hopefuls Middlesex are facing a battle to avoid defeat after Derbyshire dominated day two of their LV= County Championship Division One clash.
The hosts' last two wickets added 101 in 12 overs at Derby - leading them to a total of 385 - before Middlesex were reduced to 197-6 by the close of play.
Tim Groenewald hit 49 off 48 balls and then removed both Middlesex openers, while Matt Higginbottom took 3-51 in his second Championship game.
Derbyshire skipper and overnight centurion Wayne Madsen finished unbeaten on 138 and although Adam Voges made 69, Middlesex were still 188 runs behind at stumps.
The visitors would have expected to keep Derbyshire under 300 after Tim Murtagh (3-63) snared his 50th Championship victim of the season and James Harris also struck early in the day - but the wheels came off as Groenewald plundered some poor bowling.
Groenewald made a mockery of his batting average of six this summer with some crunching drives that earned the home side two extra bonus points.
By the time Ollie Rayner had the 29-year-old caught behind, he had smashed nine fours and dominated a stand of 66 in 12 overs with Madsen - but there was more frustration to come for Middlesex as No 11 Mark Footitt hit 19 off 16 balls.
Derbyshire carried the momentum over into the Middlesex innings as they removed Sam Robson (16) before lunch and Joe Denly (4) shortly after the interval.
Middlesex's position would have been even more precarious if Richard Johnson had held two difficult catches at second slip when Voges was on 16 and Eoin Morgan on 25.
Morgan could not capitalise on the reprieve and eventually fell for 28, but Voges went on to pass his half-century.
However, the visitors lost three wickets in 29 balls to slip to 154-6 as Neil Dexter (21) was bowled by a full length ball from Footitt and Higginbotham removed both Voges and Gareth Berg (2).
John Simpson (30 not out) and Rayner (22no) survived 15 overs and added 43 runs but Middlesex closed 39 runs short of avoiding the follow-on.