Taipei - Kunming - Hong Kong
When I apply for the 72 hour free transit, does it matter where I began traveling, or is it only the most recent flight that brings me to mainland China that matters? ie if I fly from Tokyo to Kunming, but my itinerary includes a short flight change and layover in Hong Kong, but then I plan to return to Hong Kong, does that count as 3 countries? is it Japan - China - Hong Kong, or does the layover in Hong Kong mean that officially it's Hong Kong - China - Hong Kong, which isn't allowed for the transit visa?
Alternatively, would Tokyo to Kunming (direct flight, no stopover), followed by flying from Kunming to Tokyo via a layover in Hong Kong count as Japan - China - Japan, or Japan - China - Hong Kong?
Any information you can provide would be great! Thank you.