Methods and technology have been developed to solve a wide range of problems in the dynamics of sea currents and to assess their "impact" on objects in the marine environment. Technology can be used for monitoring and forecasting sea currents, for solving the problems of minimizing risks and analyzing marine disasters associated with the choice of the optimal course of the ship, and assessing the pollution of coastal zones, etc. The technology includes a numerical model of marine circulation with improved resolution of coastal zones, a method for solving the inverse problem of contamination of the sea with a passive impurity, and a variational algorithm for constructing the optimal trajectory of the vessel. The methods and technology are illustrated by solving problems of Baltic Sea dynamics. The model of sea dynamics is governed by primitive equations that are solved on a grid with an improved resolution of the selected coastal zone-in this case, the Gulf of Finland. The equations of the model are formulated in a bipolar orthogonal coordinate system with an arbitrary arrangement of poles and the sigma coordinate in the vertical direction. An increase in the horizontal resolution of the allocated zone is achieved due to the displacement of the north pole in the vicinity of the city of St. Petersburg. A class of dangerous technogenic situations and natural phenomena (sea accidents, which can be investigated with the help of the proposed methodology), includes tanker accidents in the case of a possible collision with a stationary object (with "dynamic danger") or a moving object (including another ship), accidents on oil-producing platforms and oil pipelines, and coastal pollution.