  Slowly pulsating B stars (SPB) and $\gamma$ Dor stars pulsate in high-order
gravity (g-) modes. The frequencies of g-modes are sensitive to the detailed
structure and evolution history of stars having convective cores. Receding
convective cores in OB-type stars leave behind a chemically inhomogenous
$\nabla_\mu>0$ radiative zone. Once a g-mode has radial nodes near the
boundaries of these layers, the mode gets trapped and its period deviates from
asymptotic period spacing. Careful study of such trapped modes allows
constraining the extent of such layers by fitting individual pulsation
frequencies. We employ 19 consecuitve dipole g-modes of a very rich Kepler SPB
pulsator, KIC 10526294, to demonstrate the power of mode trapping in B-stars in
studying the thermal and chemical stratification in the overshooting layer.
