Hardly is not the adverb of hard. Hardly means very little, almost none.
Hard means difficult.
- ‘How much money have we got?’ ‘Hardly any.’
(Very little, almost none.) - The test was very hard.
(difficult) - I need to go to the shops, there is hardly anything in the cupboard.
- It was very hard for me to sleep last night.