  The various patterns of internal solitary wave interactions are complex
phenomena in the ocean, susceptible to the influence of shear flow and density
distributions. Satellite imagery serves as an effective tool for investigating
these interactions, but usually does not provide information on the structure
of internal waves and their associated dynamics. Considering a three-layer
configuration that approximates ocean stratification, we analytically
investigate two-dimensional internal solitary waves (ISW) in a three-layer
fluid with shear flow and continuous density distribution using the
(2+1)-dimensional Kadomtsev-Petviashvili (KP) model. Firstly, the KP equation
is derived from the basic governing equations which include mass and momentum
conservations, along with free surface boundary conditions. The coefficients of
the KP equation are determined by the vertical distribution of fluid density,
shear flow, and layer depth. Secondly, it is found that the interactions of ISW
can be carefully classified into five types: ordinary interactions including
O-type, asymmetric interactions including P-type, TP-type and TO-type, and
Miles resonance. The genuine existence of these interaction types is observed
from satellite images in the Andaman Sea, the Malacca Strait, and the coast of
Washington state. Finally, the ``bright" and ``dark" internal solitary
interactions are discovered in the three-layer fluid, which together constitute
the fluctuating forms of oceanic ISW. It is revealed that shear flow is the
primary factor to determine whether these types of interactions are ``bright"
or ``dark". Besides, a detailed analysis is conducted to show how the ratio of
densities influences the properties of these interactions, such as amplitude,
angle, and wave width.
