PID pairs of rings and maximal non-PID subrings