Or wisdom test.
The graduated scale is okay. I'd also say that any adult 5 or more years older than the child should not be having sex with said child.
Now, once the kid turns 18, s/he is allowed to use his/her own judgement.
Because we cannot test for wisdom or maturity, we will allow sufficient time for the individual to develop before okay'ing the predators.