> Apparently they had no idea it was bad in medieval times.

Tell me more, how do we know this to be true?

> The wealthy were particularly afflicted, as lead was used in glazes

Sure .. but you're saying that "the wealthy" purchased poorly fired earthenware and had high acid diets?

  Traditional pottery and other forms of ceramicware are made with earthenware, a porous form of clay which must be glazed in order for the pottery to hold food or liquid. Glazing applies and fuses a thin, glass-like coating onto the surface of the clay to seal its pores. The glaze – which may contain lead to facilitate the melting of glaze particles – fuses to the pottery when it is fired in a kiln, a special oven used to bake clay. When the pottery is fired at the proper temperature for the proper amount of time, essentially all the lead is bound into the glaze.
~ https://www.fda.gov/food/environmental-contaminants-food/que...

To the best of my knowledge it takes continuous leaching by > ~ 4% acetic acid (from acidic food and drink) of poorly fired lead glaze earthenware for lead glaze to become "potentially hazardous"

> The common folk weren't spared though, as they were caught up in production.

I would have though production would be where the worst actual exposure occurred, breathing in fumes from liquid mercury.

That would be the more extreme acute exposure, that was known about as problematic in medieval times (at least to those people who read and copied earlier manuscripts regarding minerals, processing, health, etc).