Robbie Neilson bade the fondest farewell possible to Hearts as his final game in charge of the Gorgie club left them in second place in the Scottish Premiership after a vibrant and richly deserved victory over Rangers.
Goals either side of half-time from Robbie Muirhead – the 20-year-old striker’s first for Hearts since signing at the start of the season – inflicted a first defeat in eight league games for Mark Warburton’s side who slip back into third spot in the table.
It was a largely disjointed display from the visitors, whose credentials as challengers for Europa League qualification now face another stern examination against Aberdeen on Saturday.
Neilson, expected to complete his move to become the manager of MK Dons today, can feel justified pride and contentment at the job he did at Hearts after becoming their head coach in the second tier of Scottish football two and a half years ago.
Hearts fully merited the advantage provided by Muirhead in the closing stages of a first half in which they had grown increasingly dangerous and dominant.
There had been little to choose between the sides in the frenetic opening exchanges when both were guilty of losing possession cheaply. But Hearts, unchanged from Saturday’s win over Motherwell, did always appear more comfortable with the unrelenting pace of proceedings.
They were first to threaten when Muirhead, having seen a powerful run illegally halted by Andy Halliday, took the free-kick himself and sent it over Wes Foderingham’s crossbar.
Rangers, who struggled to find any fluency between the midfield and front three, responded when Kenny Miller blazed wildly over the top from a James Tavernier cross.
While the visitors found it difficult to play their way into positive attacking situations, Hearts always carried a hint of menace through the physicality and aerial prowess of Bjorn Johnsen at the focal point of their front line.
The big American flicked on a Callum Paterson throw-in to create another sight of goal for Muirhead but he was off target at the back post.
Tavernier came close with a shot from distance after a decent move involving Lee Wallace, Harry Forrester and Jason Holt, but it was a rare moment of fluency from the visitors.
Hearts were firmly in the ascendancy in the final 15 minutes of the first half, a spell of control sparked by a wriggle and turn in the box from Jamie Walker, whose shot was held by Foderingham. Matt Crooks, making his first starting appearance for Rangers, received the first booking of the night for a calculated foul on Paterson as Hearts began to crank up the pressure.
Foderingham was suddenly a busy man, the Rangers keeper spilling a shot from Paterson before Wallace cleared the danger, then making a couple of saves from close-range Johnsen headers – the second of them an outstanding reflex intervention.
He then made another crucial stop at the feet of Johnsen but just as it seemed Hearts would go in at the break frustrated, they made their 44th-minute breakthrough.
Arnaud Djoum might have had a decent claim for a penalty had he gone down in the area when bumped in the back by Andy Halliday.
But his decision to stay on his feet proved a sound one as he held the ball up before finding Johnsen, whose cross from the right found its way beyond a flat-footed Rangers defence to the far post where Muirhead smashed a close-range shot beyond Foderingham.
Jack Hamilton was forced into his first save of the match in first-half stoppage time, holding a deflected effort from Forrester as Rangers tried to find a quick response.
Although Hearts resumed after the break on the front foot, with Walker almost immediately forcing another save from Foderingham, the Ibrox men thought they had equalised in the 52nd minute.
Hamilton was unconvincing when he parried a shot from Miller straight into the path of Joe Dodoo. The former Leicester striker, who had made little impact up until that point, seized on the loose ball and drove a precise shot beyond Hamilton’s left hand into the corner of the net.
But after a delay of several seconds, Rangers’ celebrations were halted when referee Craig Thomson signalled the goal was disallowed as Forrester had been in an offside position close to the Hearts keeper.
The previous pattern of play soon resumed as Foderingham made another fine save to keep out a shot from Johnsen. The momentum remained firmly with Hearts and they doubled their lead on the hour mark.
Paterson, being watched by Derby County manager Steve MacLaren, won possession on the right and found Walker as the Rangers defence were yet again caught on their heels. Walker’s low cross found Muirhead unmarked at the back post for a simple tap-in from six yards.
Warburton sent on Michael O’Halloran, Joe Garner and Barrie McKay in a bid to turn the tide in the closing stages. But although Rangers managed to secure greater control of territory and were denied by a couple of goal-line clearances from Faycal Rherras, Hearts were worthy of the winning send-off they gave to their head coach.