Context: In Islam people must be identified by their paternal lineage, meaning one’s patronym/last name/however their culture identifies paternal ancestry must tie to their father. This is because the Quran says “call them by the names of their fathers” (Quran 33:5), and while the verse was talking about adoption the principle is unanimously interpreted to apply in general.


Spain has the best system. Everyone has two last names, one from father and one from mother. Women keep their names after marriage. Children get first last name of the father and first last name of the mother.
That’s not uncommon for latin countries, it’s the same for italy, brasil, argentina
only, in brasil at least, by custom, the mom’s last name comes first