It doesn't work for dealt heads up hands because SB = 9 and BB = 8 and in this one case SB is in position on BB. That's why I added the check for absolute position - if you're in absolute position you're always in relative position, so the entire problem vanishes.
(1) This should also work. This works because if you check and then face a cbet, you must be out of position.
(2) Either one should work just fine - it's a matter of preference. It's like writing 2 + 2 vs 2 * 2 vs 2 ^ 2. They all give you the same result
(3) Questions answered with numbers per your request