Constraining the equation of state of nuclear matter from fusion hindrance in reactions leading to the production of superheavy elements