How do I get the 7th grandma in cookie clicker

You need 7 different grandma types, not just 7 grandmas. The different types unlocks when you reach 15 of each of the other buildings.

Read more here https://cookieclicker.fandom.com/wiki/Upgrades#Grandma_types