Brahim played a pivotal role in Morocco's 2-0 away victory over Lesotho during the second round of qualifying for the 2027 Africa Cup of Nations. The Real Madrid forward started the match, which took place in Bloemfontein, South Africa, and scored the opening goal just before halftime. He capitalized on a rebound off the opposing defense inside the box to make it 1-0 in the 45th minute. Brahim was substituted in the 69th minute. Later, Ounahi secured Morocco's win by scoring the second goal in the 82nd minute, sealing the 2-0 scoreline. This result gives the Moroccan national team a total of six points in Group A, significantly strengthening their position in the qualifiers.