Everton substitute Bernard's extra-time strike sealed a 5-4 victory over Tottenham in an FA Cup fifth-round thriller at Goodison Park. The 28-year-old Brazilian has been on the fringes of the Everton squad, but settled a see-saw tie with a powerful left-footed strike in the 97th minute. It meant Tottenham's wait for a first FA Cup triumph since 1991 goes on, but kept alive Everton's hopes of winning the trophy for the first time since 1995. Tottenham, who battled back from 3-1 and 4-3 down having taken the lead in the third minute, have now lost four of their last five games and while they played some admirable attacking football, they were undone by defensive frailties. "I enjoyed it, and I didn't enjoy it!" Tottenham manager Jose Mourinho, who was up against respected rival Carlo Ancelotti, said of a breathless tie. "We scored goals, created more chances, great character to fight against incredible mistakes. But attacking football only wins matches when you don't make more defensive mistakes than what you create. We scored four goals, but was not enough." Everton were not at the races in the opening minutes and they fell behind in the third minute when Tottenham defender Davinson Sanchez headed past Robin Olsen. Tottenham could have been further ahead but their night fell apart in seven first-half minutes. Dominic Calvert-Lewin levelled in the 36th minute when the excellent Gylfi Sigurdsson teed him up and his shot, though directed at Tottenham keeper Hugo Lloris, was too powerful for the Frenchman. Two minutes later Calvert-Lewin's flick opened up space for Richarlison, who beat Lloris with an angled low drive. Sigurdsson then appeared to have dealt a hammer blow to his old club when he tucked home a penalty after Pierre-Emile Hojbjerg had tripped Calvert-Lewin. Erik Lamela's close-range finish in first-half stoppage time swung the momentum back to Tottenham though. Defender Sanchez, who had scored only once in 137 appearances for Spurs, poked home his second of the night in the 53rd minute to haul Tottenham level. Richarlison put Everton ahead again 10 minutes later when another great ball by Sigurdsson sent him clear. Harry Kane had been left on the bench by Mourinho until the 53rd minute and he inevitably got Tottenham back into the tie when he headed in a superb cross from Son Heung-min in the 83rd minute. The frenetic pace dropped a little in extra time but there were still chances for both sides. But it was Bernard who decided it when Sigurdsson's deft pass cut out the Spurs defence and the Brazilian struck the ball across Lloris and into the net.