قَرَأَ إِمَامُ الْمَسْجِدِ خُطْبَةً طَوِيلَةً
The mosque's imam read a long sermon.
● Verb: قَرَأَ
● Compound subject: إِمَامُ الْمَسْجِدِ
● Compound object: خُطْبَةً طَوِيلَةً
The adjective طَوِيلَةً belongs with the object and agrees with it. Read the sentence in blocks rather than assigning every word a separate sentence role.