An age of consent makes little sense, quite often it is breached and nothing is done about it.
That is, it is not always enforced
The age of consent gets its justification from the concept that the child is in custody of the parents/state till it is ready to survive on its own.
But age is so arbitrary, there are kids that are very knowledgeable and responsible, and adults that are ignorant and irresponsible. A better option would be to give everyone a test like a driving test. If they pass the test they may have sex at any age. If they do not, they may still have sex at the age that custody of the parent/state stops.
The test should not be arbitrary
There is no way that the law can represent the complexities of this whole area, hence the differences.
the Criminal Law Amendment Act of 1885. Before then, since the 13th Century, the age of consent had been 12. It was raised at a stroke to 16 because of a pushy investigative journalist's campaign about child prostitution in the Pall Mall Gazette, the ancestor of our Evening Standard.
The series of articles entitled The Maiden Tribute of Modern Babylon was probably as inaccurate and exaggerated as some more recent newspaper campaigns have been in the area of child sex. But the articles kick-started pressure to reform, so the age of consent was raised, while, with a certain illogicality, the minimum age of marriage for girls remained 12 until 1929.