Related: How does the Schengen 90/180 rule work?
I am in Ukraine
I have 70 days left on my shengen visa
My 180 day period ends in 40 days
I want to travel to Spain for as long as possible
If I travel to spain right now, how long can I stay there?
40 days? Or 70 days? Or Do I have to take a plane home in 40 days and then a plane to Spain the next day to enjoy 90 more days? Seems nonsensical, right?
This answer quotes
The 6 month (or 180 days to be precise) period starts on the day of the first entry into the Schengen zone (Note that the day of first entry means the day you physically arrive in the zone and not the day the validity of the visa starts). In that 6 month period, you can only stay in the Schengen zone for a maximum of 90 days, irrespective of whether you have a new Schengen visa issued by the same or a different Schengen country that is valid beyond this 6 month period. At the end of this 6 month period, a NEW 6 month period starts and you can again spend a maximum of 90 days in the Schengen zone, provided you have a valid visa. If your stay duration overlaps two 6 month periods, then you must individually satisfy the 90 day limit in BOTH periods. All following 6 months period will be calculated back to back from the date of the first entry, until you remain outside the Schengen zone for at least 6 months. When you stay outside for at least 6 months (continuously) and THEN enter the Schengen zone, the six month period again starts from the day of the entry. It would be as if you were entering the Schengen zone for the first time.
What does the "you must individually satisfy the 90 day limit in BOTH periods" actually mean? Does it mean that I must be 90 days in one and 90 days max in other visa, or 90 days in both visas combined or what?
But the link is not clear enough for me to understand.
I even read the official doc and used it's calculator, which seems to give off random numbers.
How am I supposed to follow the rules if no one seems to know them.
Edit: There is no such thing as a period overlap, it's just that you can't stay for more than 90 days in the last 180 days, that's the only rule.