A double slit setup is shown in the figure. One of the slits is in medium $2$ of refractive index $n_2$. The other slit is at the interface of this medium with another medium $1$ of refractive index $n_1\left(\neq n_2\right)$. The line joining the slits is perpendicular to the interface and the distance between the slits is $d$. The slit widths are much smaller than $d$. A monochromatic parallel beam of light is incident on the slits from medium $1$. A detector is placed in medium $2$ at a large distance from the slits, and at an angle $\theta$ from the line joining them, so that $\theta$ equals the angle of refraction of the beam. Consider two approximately parallel rays from the slits received by the detector.
Which of the following statement($s$) is (are) correct?
$(A)$ The phase difference between the two rays is independent of $d$.
$(B)$ The two rays interfere constructively at the detector.
$(C)$ The phase difference between the two rays depends on $n _1$ but is independent of $n_2$.
$(D)$ The phase difference between the two rays vanishes only for certain values of $d$ and the angle of incidence of the beam, with $\theta$ being the corresponding angle of refraction.
