I think maybe an easier example to consider would to be to put 'fuck' and 'shit' aside (since its even harder to understand how these were ever really taboo), and instead consider the older more religiously inspired curses like 'damn it', 'blood the mary', etc.
These curses (in certain circles) were hugely taboo because in the worldview of the times, they were deeply harmful to use on a metaphysical / spiritual level. You were doing real harm in the world by exclaiming "damn it to hell!" or telling someone "go to hell!".
This is perhaps hard for us in our current culture where even even amongst people who claim to be religious, almost everyone would just view those as empty words, but I do think there's a real case to be made that our ancestors would have understood such curses in a very similar way to the way we understand and treat slurs today.
I do know people who think "g-- damn it" is a far worse thing to say than 'fucking piece of shit' for example.
That would be my mother. Hasn't been to church in decades, curses like a sailor, but will never take the lord's name in vain.
Although, maybe with enough time, she will, it took her until she was 60 before she started saying 'fuck.'
To your point, I know groups who would find the slur less offensive than "g-- damn it."