The Jerusalem Magistrate’s Court on Monday heard allegations against four minors — three boys aged 17, 15 and 13 and a 15-year-old girl — held in connection with last week’s brutal beating of an Arab youth in downtown Jerusalem.

The victim of the attack, 17-year-old Jamal Julani of East Jerusalem, was severely injured in the brawl — and nearly died, Channel 2 reported. Julani has a heart condition, which exacerbated his injuries.

“He cursed my mother; I don’t care if he dies,” one of the suspects said at the hearing, referring to Julani. “There were 40 or 50 kids there, and they were all beating him. I was in the square, I was involved. If I catch him I’ll beat him. He’s an Arab.”

Police said they were increasingly convinced that the attack was unprovoked, and that Julani was set upon simply because he is an Arab.

Two of the four minors were remanded into custody. The other two were set to be released to house arrest on Tuesday, but police were preparing to appeal this, and present new evidence to justify their further remands.

Two additional minors were arrested in Jerusalem on Monday in connection with the incident.

The police said about 10-15 Jewish youngsters were involved in the attack, and a few dozen other people stood around watching. Police said the incident reflected profound hatred among Jewish youths in Jerusalem for local Arabs.

Chief Superintendent Ronen Avnieli of the Jerusalem Police said the events began at Kikar Hahatulot, a downtown square where young people often congregate, and ended at Zion Square, a few hundred meters away.

A girl of 15, one of the six being held, incited and egged the youths to attack Arabs, after claiming she was raped by a different group of Arab youths in the past, police said. The police had no information as to whether there was any truth to her claim. Her lawyer told the court she denied inciting the violence.

In addition to the six minors, police also arrested a 19-year-old on Saturday on suspicion of assaulting Julani. The suspect, whose name was not released, appeared before the Jerusalem Magistrate’s Court on Sunday and his detention was extended by four days.

Jerusalem Mayor Nir Barkat told Army Radio on Sunday that he strongly condemned Thursday’s incident, but cautioned against jumping to early conclusions about the motive of the attack.

Asher Zeiger and Yifa Yaakov contributed to this report.