Europe: Do 90 days of Schengen apply automatically after expiration of Student visa?

This question might have already been answered but I cannot seem one to perfectly fit my situation. I am an albanian citizen and currently staying in Austria with a D Visa which is available for 6 months. It expires on June 30th. I have a flight to take on June 23rd to Italy where I need to stay till July 6th. Which means, my visa will expire when I’m in Italy. My question is, do my 90 days of Schengen apply directly after my visa expires or should I first go to Albania and then return for them to start being counted? If I wasn’t clear enough tell me and I will answer as soon as possible Thanks in advance