replying in good faith here
first off, yes, the fic should have been tagged/warned about more appropriately, and that is fully on the author. they should have reiterated the warning, and specified that it was going to include straight up smut. that is fully on them, and something that they should fix in the future.
now, the fact is, that children (especially young teens), are going to want to explore sexual themes (often times without the most subtlety or skill), because it's something that is talked about, something that they're often curious about, and it's something that is ancored in our society as something that people do. let me remind you, a fourteen year old is a freshman in high school. a fourteen year old most likely has already been attracted to someone, and a fourteen year old might very soon be in a relationship with someone where sex is on the table.
fan(fiction) is a safe way for young teenager to explore (their) sexuality freely without risking their wellbeing or someone elses*. it allows them to imagine scenarios that are one step removed from themself, as they might not wish to imagine those situations in first person for a variety of reasons. it allows for a total freedom of experimentation, without being limited by their bodies, their awkwardness, and sometimes, frankly, by the fact that their parents are in the same house and they don't want to experiment on themself in those conditions.
you are entirely in your right to dislike the idea of smut for the kotlc characters. you are entirely within your right to find it grosses you out. you are entirely within your right to click away from the (fan)fic. but disgust is not a moral judgement. it's not wrong for a 12-14 year old to write sexual situations, and it's not wrong for them to write people their own age being in sexual situations -- just the same as it's not wrong to write about those characters committing murder.
*with the caveat that the smut should be advertised as such, to be avoided by those who wish to do so