Vertically polarized waves in inhomogeneous media with critical coupling regions