Introduction

In arid and semi-arid regions, groundwater is one of the most critical sustainable sources of freshwater supply in domestic, agricultural, industrial, and other sectors (Chitsazan et al. 2017).

In recent years, many groundwater sources, especially aquifers located in the coastal belt, have been exposed to seawater intrusion (SWI) due to the increasing water demands resulting from the population growth and agricultural development (Chandra Pal et al. 2022; Desai and Desai 2012; Singh 2015).

The seawater intrusion, besides causing pollution in the aquifer freshwater, can leave irreparable effects on the condition of cultivable soil and the natural ecosystem of coastal areas. Failure to properly recognize and manage this phenomenon in the long term will destroy the stable conditions of the aquifer, which is one of the main components in the economic improvement of coastal communities (Siddha and Sahu 2020).

The development and increase of withdrawals by operation wells disturb the natural balance between salt and freshwater in unconfined coastal aquifers. This leads to a decrease in the freshwater thickness and the intrusion of saline water, resulting in an increase in salinity in groundwater resources (Asare et al. 2021; Tabari and Abyar 2022). According to the studies of Abd-Elaty et al. (2021), reducing the pumping from unconfined aquifers, increasing aquifer recharge using treated agricultural wastewater, and abstraction, desalination, and recharge (ADR) system can control the SWI. In confined and perched coastal aquifers, due to the existence of confining layers and clay lenses, hydrogeological processes are more complex, and geochemical processes lead to the SWI from the underlying layers (Sahour et al. 2020). Based on previous studies, several factors lead to the creation and development of salinity in coastal aquifers: the decrease in the groundwater level; the increase in the level of seawater as a result of climate change, dissolution of rocks, weathering, and ion exchange; and the rise of paleo-salinewater as a result of significant pumping of exploitation wells or anthropogenic factors such as the entry of agricultural, industrial, and urban wastewaters (Barkat et al. 2021; Guo et al. 2021; Hajji et al. 2021; Larsen et al. 2017; Mtoni et al. 2013). Therefore, knowing the sources and mechanisms in the salinization process of coastal aquifers is of great importance for effective and sustainable management. In order to investigate and monitor of the saltwater intrusion phenomenon in coastal aquifers, different approaches have been used in previous studies. Among them, the following studies can be mentioned: investigating factors affecting groundwater salinity and its modeling using multivariate regression method to make a salinity map in the Caspian southern coasts by Gholami et al. (2009). The results showed that the quality of recharged surface water (agricultural wastewater) is the most important factor of groundwater salinity in this region, and the decrease in rainfall from west to east of Mazandaran Province has led to an increase in the salinity of aquifer samples. In 2016, to delineate and evaluate the processes governing the intrusion of Mahrlu Lake saline water into the coastal aquifer located in its southern part, Jahanshahi and Zare (2016) examined the groundwater type, iso EC maps, iso ions and ion exchanges in the mixing process of salt and freshwater, and depth variations of salinity in coastal wells. The time variation of the physical and chemical parameters of groundwater showed that saline water has moved upward from the bottom of the aquifer and destroyed the groundwater quality due to overexploitation and the change of hydraulic gradient from the lake to the aquifer. Also, geological formations and evaporation from shallow groundwater were effective in increasing the salinity of the aquifer. The spatiotemporal distribution of salinity in Caspian Sea coastal aquifers using geostatistical analysis by Amiri-Bourkhani et al. (2017) was investigated. The results indicate an increase in the salinity of aquifers from south to north and west to east. Increasing agricultural land in the central and eastern parts and the long-term operation of groundwater resources, the percolation of agricultural wastewater, the high concentration of population, and, as a result, increasing extraction of groundwater have been introduced as the main factors of the salinity and SWI. Kanagaraj et al. (2018) used geophysical, geochemical, and stable isotope techniques to determine hydrogeochemical processes and the effect of SWI in coastal aquifers south of Chennai, India. The results showed that agricultural activities and geotechnical processes are the causes of SWI. Sahour et al. (2020) investigated the distribution of salinity in coastal aquifers of the southern Caspian Sea using hydrogeological and hydrological data, statistical techniques, and machine learning. Their findings indicate that the transmissibility of the aquifer is the most critical parameter affecting the salinity of the groundwater. Using classical integration methods and multivariate statistical analysis, Khairy and Janardhana (2021) investigated the qualitative details of the aquifer in terms of salinity and its controlling factors. Using quantitative indicators, Sarkar et al. (2021) measured the intensity of SWI in the coastal region of West Bengal, India, and traced its dominant mechanism. Accordingly, frequent storm surges, rising seawater, overexploitation of groundwater, and silicate weathering were considered as the main factors of SWI. Le et al. (2020) identified the spatial distribution and hydrogeochemical evolution process of saline water in a coastal four-layer aquifer in Southern Vietnam using the HFE-D diagram and GIS. Ghezelsofloo et al. (2021) evaluated the intrusion of saline water into the coastal aquifer wells of Kordkuy with hydrogeochemical methods and geophysical studies. The hydrogeochemical evolution of the Rhodope coastal aquifer based on the analysis of qualitative samples and multivariate statistical methods by Tziritis et al. (2023) was studied.

The surveys of relevant prior literature, as mentioned in the previous section, show that the approaches used in SWI evaluation can be divided into several categories: determination of the origin of salinity based on the hydrogeochemical facies governing the aquifer using diagrams like Piper, hydrochemical facies evolution (HFE), Stiff, Durov, and Gibbs (Biswas et al. 2023; Ghezelsofloo et al. 2021; Gimenez-Forcada 2010; Kelepertzis et al. 2023; Le et al. 2020; Li et al. 2020), multivariate statistical analysis and the use of correlation coefficients and relationships between qualitative parameters (Amiri et al. 2021; Parisi et al. 2023; Tziritis et al. 2023), geophysics-based methods (Kouzana et al. 2010; Kura et al. 2014; Meyer et al. 2019), the use of isotopes in identifying the origin and age of saltwater in the aquifer (Carol et al. 2009), and spatiotemporal investigation of salinity intrusion using GIS and modeling (Abba et al. 2023; Dhar and Datta 2009; Kawo and Karuppannan 2018; Xiong et al. 2023). The studies by the authors of this article indicate that the use of statistical methods and the analysis of chemical facies, employing qualitative samples, have become more prevalent in evaluating saltwater intrusion in coastal aquifers. The integrated utilization of the capabilities of the mentioned approaches allows for the accurate identification of the causes of salinity and the determination of the processes governing the aquifer’s exposure to salinity. Despite investigating different approaches to SWI assessment in the coastal aquifers, it is essential to study the status of Caspian Sea intrusion in the coastal aquifer of northern Iran and its effects. The Caspian Sea is the largest closed lake in the world, and its level is 27 m below the level of the open seas (Khairy and Janardhana 2013). Mazandaran Province in the northern coastal region of Iran, located on the southern shore of the Caspian Sea, due to having diverse vegetation and moderate climate, is considered one of the important areas in terms of the production of agricultural products (rice farms and citrus gardens) and tourism (Heidari Cherati 2020). In this province, the depth of the groundwater table level is less than 10 m, and for this reason, these water resources are exposed to salinity (Gholami et al. 2009).

This plain region has 600,210 ha of cultivated land (agricultural (74%) and garden (26%)). The strategic products of this region are rice and citrus fruits (with 36% and 44% of the IRAN production, respectively), which have been assigned the first rank of production in both products (Jehad 2020). In this area, the Ghaemshahar-Juybar (GH.-J.) aquifer is considered one of the six potential aquifers in the vicinity of the Caspian Sea, with suitable freshwater reserves. More than 10% of agricultural land in Mazandaran Province is located in this aquifer (Motevalli et al. 2019). The pressure on the groundwater resources of this aquifer has increased due to the decrease in rainfall in the last decade, overexploitation of groundwater, the construction of dams, the development of tourism, and the increase in the area under rice cultivation. This has led to the salinity of the soil and groundwater, as well as seawater intrusion (Golshan et al. 2018; Sahour et al. 2020). Considering the strong dependence of agricultural lands and urban areas of this region on groundwater, it is important to evaluate the spatiotemporal changes of salinity and its causative factors.

Reviewing previous studies, like Gholami et al. (2009), Moghimi et al. (2016), Motevalli et al. (2018), Nezhadnaderi (2018), Golshan et al. (2018), Janardhana and Khairy (2019), Moghimi (2017), Khairy and Janardhana (2021), Sahour et al. (2020), and Mazandaran regional water company (MRWC) reports, reveals that in the four-layer aquifer of the GH.-J. study area, a precise and specific study has not been done to determine the factors that cause salinity separately in all of the aquifers of this plain. In these studies, research has mainly been focused on the modeling of the western aquifers of the Caspian coastal strip and their hydrogeochemical investigation as a result of agricultural land development. Therefore, the development of an integrated approach of statistical tools and hydrogeochemical analyses using GIS to evaluate SWI in GH.-J. aquifer is proposed as a new research, and it is necessary to fill the existing research gaps in this field. Also, the identification of locations contaminated with salinity and susceptible to SWI for each of the four layers of the aquifer, along with determining their origin, is considered a new and innovative achievement. Furthermore, the results of this study not only raise awareness among farmers but they can also play a significant role in the proper management of land, promoting the adoption of sustainable policies in the operation of coastal aquifers. Due to the proximity of the studied aquifer to the Caspian Sea and its presence with multiple layers, this research investigated the behavioral changes in hydrogeochemical characteristics of the aquifer. This exploration aimed to identify the source of saltwater intrusion and understand the reasons behind its increase over a long-term period (2011–2020). To achieve this objective, we utilized a combination of results from statistical methods and principal components analysis, along with modified Piper diagram indexes (\({GQI}_{{\text{Piper}}\left({\text{mix}}\right)}\) and \({GQI}_{{\text{Piper}}\left({\text{dom}}\right)}\)), the intrusion of saltwater in coastal aquifers index (\({GQI}_{{\text{SWI}}}\)) (Tomaszkiewicz et al. 2014), and HFE-D (Gimenez-Forcada 2010; 2014). Additionally, we employed the GIS technique, which had not been previously considered in the study area. Based on the proposed approach, the salinity status and qualitative changes of the aquifer due to the effects of SWI and other geogenic or anthropogenic factors affecting it during a 10-year period were investigated by comparing and evaluating the methods mentioned above. The results of the applied methods were presented using the GIS technique in the form of spatiotemporal distribution of the aquifer freshening and intrusion phases. Therefore, the most important goals of the present study are:

  • • Identifying and distinguishing between various factors contributing to the salinity of aquifers in the studied area, based on the dominant qualitative type, ion ratios, correlation status, and principal component analysis

  • • Spatiotemporal investigation of changes in concentration of major ions related to geochemical evolution during saltwater intrusion process using \({GQI}_{{\text{SWI}}}\) index, modified Piper diagram, and HFE-D.

  • • Determining natural (geogenic) and artificial (anthropogenic) sources of salinity in different layers of the aquifer

The findings of the present research can offer a clear insight into understanding the origin and governing mechanisms of salinity in this multilayered coastal aquifer. Additionally, based on these findings, it is possible to formulate and develop operational instructions for the coastal aquifer, aiming to achieve a qualitative revival for sustainable harvesting.

Materials and methods

Description of the study area

The studied area of GH.-J. is an example of a coastal aquifer at risk of saltwater intrusion, which is located in the coastal belt of the Caspian Sea. This aquifer is located in the north of Iran and between the two aquifers of Sari-Neka in the east and Babol-Amal in the west. The total area of the study area is about 3537 \({{\text{km}}}^{2}\), of which 935.5 \({{\text{km}}}^{2}\) is plain. The rest is the heights of the northern slopes of the Alborz Mountains (Fig. 1). The highest and lowest altitude of the this plain are 3929 and − 26 msl (mean sea level), respectively (Mazandaran Regional Water Organization 2010).

Fig. 1
figure 1

Geological map of the study area 

Considering the importance of this region in the production of agricultural products (especially citrus fruits and rice), it is necessary and worthy of attention to investigate the changes and reasons for the qualitative degradation of the groundwater resources of this plain. The coastal alluvial sediments of the studied area have created a multilayered aquifer system.

The highest layer is the unconfined aquifer, used for agriculture, drinking, industry, and aquaculture (fish farming) purposes. This layer has formed a perched aquifer in parts of the margin of the Caspian Sea due to the placement of fine-grained clay layers under it, which has good quality for drinking and agricultural purposes.

In the distance between the perched and unconfined, fossil saline waters are trapped in the alluvial layer and have formed a low-quality saline aquifer. The lowest layer is located in the southern part of the plain, which, due to being under the marl and clay impermeable layer, has formed a confined aquifer with good quality for agricultural and drinking purposes.

The 10-year average amount of annual precipitation in the studied plain is equal to 696.2 mm. The highest and lowest monthly precipitation occurs in November and June, with values of 216.7 and 0.3 mm, respectively. Based on the average data of 25 years, the amount of annual evaporation in the plain is 1060.34 mm, and the minimum and maximum temperature reported in the plain is for January and August with values of 7 \(^\circ{\rm C}\) and 25 \(^\circ{\rm C}\), respectively. The climate of the study area is considered to be moderate to very humid based on the Emberger climate classifications (Mazandaran Regional Water Organization 2010).

Geologic and hydrogeologic units

In the study area, there are various geological formations from the early carboniferous to the quaternary (Fig. 1). One-third of the heights is occupied by the Shamshak formation (sandstone, quartz sandstone, coal shales, and clay rocks), which has a quantitative and qualitative relationship with the plain aquifer due to the presence of numerous faults. The carbonate formations of Elika (shale and dolomitic limestone), Delichai (calcareous marl and marl limestone), and Lar (limestone and dolomitic limestone) have the most significant impact on the quality of the groundwater in terms of solubility.

Cretaceous Tizkoh formation (dolomite limestone, limestone with volcanic rocks) is observed on the border of mountains and plains. By moving towards the plain, quaternary sediments, including the Apsheron Formation (Lower quaternary), can be seen, which are formed from stiff clays, marl, sand, gravel layers, and a thin layer of volcanic ash in lake conditions. The water left over from the retreat of the Caspian Sea in different geological periods on Apsheron sediments and then covering these waters with new Caspian sediments has caused the formation of fossil saline aquifers. Apsheron formation is covered with lacustrine sediments, including sand, unhardened mud (New Caspian), and discontinuous sediments, which created the unconfined aquifer with relatively good permeability of GH.-J. plain (Fig. 1). In fact, the type of bedrock has not been determined in the studied area. The structure of the alluvial unconfined aquifer is formed from river alluvium and lake sediments containing freshwater, which are placed on fossil saltwater. Accordingly, the lower layer of this aquifer is formed by the saltwater arch.

In the southern part of the plain, due to the presence of clay and marl layers, a confined aquifer is formed under the unconfined aquifer. The expansion of saline aquifers or aquifers with poor quality has also been identified based on the groundwater qualitative data in the northern part of the plain.

The alluvium in the north of the GH.-J. plain and on the margin of the Caspian Sea is finer-grained with clay, forming the perched aquifer in this part. Therefore, in the studied area, four aquifers (perched, saline, unconfined, and confined) have been created, and the boundaries of these aquifers are shown in Fig. 2. In the GH.-J. plain, the alluvium in the surface parts of southern areas is fine-grained and becomes coarser in the depths (Fig. 3). Also, the greatest thickness of the aquifer has been identified in the middle part of the plain. The area of unconfined and confined aquifers is 614.24 and 376.13 \({{\text{km}}}^{2}\), respectively. The potential of the water withdrawal from groundwater in this plain is approximately 343,000 \({{\text{m}}}^{3}/{\text{year}}/{{\text{km}}}^{2}\) (Geological Survey of Iran 2003). In the study area, due to the low number of exploration wells, inappropriate dispersion in the plain, and limited geophysical information, it is not possible to accurately estimate the exact hydrogeological sections, the depth of discontinuous sediments, and the exact surface of the salt–freshwater interface. Figure 4 shows the schematic hydrogeological cross section of GH.-J. plain based on available geological information and exploration logs (Fig. 3) along the line from south to north (from Alborz mountain to Caspian Sea).

Fig. 2
figure 2

Location of the sampling points, piezometers, boreholes, and all of the aquifers located in the GH.-J. plain

Fig. 3
figure 3

Logs of boreholes located in the central part of GH.-J. plain

Fig. 4
figure 4

Schematic hydrogeological cross section along line S–N in the GH.-J. plain. The blue line denotes the hypothetical separation surface of fresh and saline groundwater, and the red arrows show saline groundwater flow directions from the fossil aquifers to the unconfined and confined aquifers

Water sampling and analyses

By early 2000, in the studied area, the number of observation wells and hydrochemical data in the aquifers in order to the quality situation monitoring was very few and limited. During 2000–2010, the quality monitoring wells in the unconfined aquifer increased somewhat, but the data related to the quality status of other aquifers was sporadically collected. In fact, during this period, sufficient data were not available in terms of the number and measurement of quality parameters to evaluate the quality of aquifers. Since 2010, with the increase in observation wells and regular sampling, a complete set of hydrochemical data was provided for the qualitative study of the plain and coastal aquifer management. In this study, the 49, 31, 30, and 30 samples from semi-deep wells of unconfined aquifer; 22, 15, 12, and 13 samples from deep wells of confined aquifer; and 13, 5, 2, and 5 samples from saline aquifer were collected during 2011, 2014, 2017, and 2020, respectively. Also, two samples were taken from the perched aquifer every 4 years. In early 2013, the number of wells was limited, and the hydrochemical data were incomplete. The decrease in the number of samples during different years is due to the drying up of some wells due to the excessive exploitation in recent years, making some of the wells unavailable.

Samples were collected by Mazandaran Regional Water Company, and their chemical analyses were performed according to American Public Health Association (APHA 2005) standards by the laboratory affiliated with this company. In this research, purging and sampling wells without plumbing, within the limit of suction, were done by the bailer. Before sampling, the purging process involved using a bailer conforming to the Standard Operating Procedure for Field Equipment Cleaning and Decontamination (SESDPROC-205). A closed-top Teflon bailer with Teflon-coated stainless steel leaders and a new nylon rope was lowered into the top of the water column, filled, and withdrawn, removing stagnant water from the well just before sampling. This process ensured its replacement by groundwater from the adjacent formation, representing actual aquifer conditions. It is critical that the bailer must be slowly and gently immersed into the top of the water column, particularly during the final stages of purging, to minimize turbidity and disturbance of volatile organic constituents. In this method, a bailer was used to purge and sample the wells, and a new bailer rope was not required between purging and sampling (Puls and Barcelona 1996). After purging, the bailer was gently immersed in the top of the water column until it was just filled. At this point, the bailer was slowly removed, and the contents were emptied into the appropriate sample containers (250-ml polyethylene bottles).

Temperature, pH, and EC parameters were measured in situ using the HACH Multimeter device (HACH, Germany). The collected samples were placed in an ice box and transferred to the water laboratory of Mazandaran Regional Water Company, Iran, in a short time and stored at 4 \(^\circ{\rm C}\) in the refrigerator for analysis. The concentrations of the main ions in this laboratory were analyzed employing APHA standard methods (APHA 2005): sodium and potassium using flame photometry, calcium, and magnesium by titration method with EDTA, alkalinity (\({{\text{HCO}}}_{3}\)) by volumetric titration with HCL and methyl orange, chloride by standard \({{\text{AgNO}}}_{3}\) titrations, and sulfate by the measured by \({{\text{BaCl}}}_{2}\) method using spectrophotometer.

Charge balance error (CBE) was used to evaluate the accuracy of the measured data (Asare et al. 2021; Chitsazan et al. 2017). Calculating the value of this index for all samples shows that the error rate is less than ± 5%, and therefore, the qualitative data have good accuracy for subsequent analyses.

The background of the used theoretical methods

Statistical techniques

In general, understanding hydrological and geochemical processes in coastal aquifers is very difficult due to their complexity. So, descriptive statistical methods can be very effective and helpful in analyzing complex hydrochemical processes in the groundwater by using hydrochemical data and correlation matrix analysis (CMA) between two or more variables. It should be noted that correlation analysis plays an important role in determining the origin of ions in groundwater sources (Islam et al. 2017; Li et al. 2020; Su et al. 2017).

Multivariate statistical methods are instrumental in obtaining significant information from hydrogeochemical data sets of aquifers and have good efficiency. In this study, principal component analysis (PCA) was applied to determine the relationships between variables in order to evaluate the processes that control water chemistry. So far, this method has been used by many researchers in hydrochemical research (Elemile et al. 2021; Mohammed Siraj Ansari and Saraswathi 2022; Nemati et al. 2022; Nguyen et al. 2020).

To identify the hydrogeochemical processes in coastal aquifers and determine the origin of important anions and cations in them, hydrogeochemical data are grouped using the PCA approach and according to the qualitative characteristics inherited from the groundwater or saltwater. The main goal of this method is to reduce the contribution of less significant variables to further simplify the data structure. This method begins by coding all variables with a mean of zero and a variance of one and finding the corresponding eigenvalues and eigenvectors. Then, the data is converted into components. Kaiser (1958) used the minimum acceptable eigenvalue of 1 as a criterion to determine the number of components (PCs). In this research, the extraction of components was done with the same criterion for the total number of samples (Mahlknecht et al. 2004). In this study, all the statistical analyses were performed using the Excel 2019 and IBM Statistic SPSS 26 software. Additional explanations related to the CMA and PCA are provided in part I of supplementary information.

Piper diagram and saltwater intrusion groundwater quality index ( \({{\varvec{G}}{\varvec{Q}}{\varvec{I}}}_{{\varvec{S}}{\varvec{W}}{\varvec{I}}}\) )

Hydrogeochemical concepts, utilizing environmental data and drawing them in the form of a single diagram, can help describe and understand the mechanisms of flow and transport of materials in groundwater systems. One of the widely used and handy diagrams for producing and determining the relationships between the concentration of different ions dissolved in water and classifying water based on their chemical properties is the Piper diagram. The Piper diagram allows for the determination of hydrogeochemical facies of water by assessing the relative characteristics of dominant ions in the collected samples (Amiri et al. 2015; Mohammadi Arasteh and Shoaei 2020; Piper 1944; Sarath Prasanth et al. 2012; Subramani et al. 2005).

This diagram consists of triangles of the main anions and cations, each side of which is divided linearly from 0 to 100. By placing the qualitative parameters related to the measured samples on this graph and determining their position, the state of sea saltwater intrusion, the possibility of salt and freshwater mixing, and the groundwater hydrochemical facies are determined. In this diagram, six regions representing different types of water can be identified (Fig. 5) (Amiri et al. 2015; Sarath Prasanth et al. 2012; Subramani et al. 2005). More details of the Piper diagram are described in part I of supplementary information.

Fig. 5
figure 5

Description of created Piper domains based on \({GQI}_{{\text{Piper}}\left({\text{mix}}\right)}\) and \({GQI}_{{\text{Piper}}\left({\text{dom}}\right)}\) indexes (redesign based on Tomaszkiewicz et al. (2014))

In order to determine the amount of seawater intrusion, \({GQI}_{{\text{flake}}}\) index was proposed by Appelo and Postma (2004) using the theoretical mixing percentage and considering chloride as a conservative ion (Eq. 2). This index is based on Tomaszkiewicz et al. (2014) due to its high sensitivity to the chlorine parameter; it cannot independently detect the dominant hydrogeochemical reactions in the phenomenon of seawater intrusion and has weaknesses. Based on this, they proposed a combination of \({GQI}_{{\text{f}}lake}\) and \({GQI}_{{\text{Piper}}({\text{mix}})}\) under the title of \({GQI}_{{\text{SWI}}}\) index (Eq. 3). This index shows a more representative index for seawater mixing by using the strengths of two combined indices and compensating for their weaknesses.

$${f}_{{\text{lake}}}=\frac{{C}_{{\text{Cl}},{\text{sample}}}-{C}_{{\text{Cl}},{\text{fresh}}}}{{C}_{{\text{Cl}},{\text{lake}}}-{C}_{{\text{Cl}},{\text{fresh}}}}\times 100$$
(1)
$${GQI}_{{\text{flake}}}=(1-{f}_{{\text{lake}}})\times 100$$
(2)
$${GQI}_{{\text{SWI}}}=\frac{{GQI}_{{\text{Piper}}({\text{mix}})}+{GQI}_{{\text{flake}}}}{2}$$
(3)

where \({C}_{{\text{Cl}},{\text{sample}}}\) and \({C}_{{\text{Cl}},{\text{fresh}}}\) are the chloride concentrations in the sample and Caspian Sea (\(6500\mathrm{ mg}/{\text{l}})\), respectively (Table 1). The \({C}_{{\text{Cl}},{\text{fresh}}}\) is the chloride concentration in the groundwater.

Table 1 Mean concentration of solution elements in oceans and seas (Hem 1985) and Caspian Sea (Ministry of Jihad-e-Agriculture 2006

The status of the water type in terms of salt and freshwater mixing based on the \({GQI}_{{\text{SWI}}}\) index is as follows:

  • \({0<GQI}_{{\text{SWI}}}<10\): freshwater

  • \({10<GQI}_{{\text{SWI}}}<50\): mixed groundwater

  • \({50<GQI}_{{\text{SWI}}}<75\): saline groundwater

  • \({75<GQI}_{{\text{SWI}}}<100\): seawater

Hydro-chemical facies evolution diagram (HFE-D) to assess the evolution of seawater intrusion and freshening stages

The chemical composition of aquifers qualitatively changes along its flow path from recharge areas to a discharge point. This change results from the long interaction of water and rock, evapotranspiration, and the effects of seawater. Therefore, in a closed system, the hydrochemical changes of the main ions can indicate the gradual expansion of pollutants in the regional flow system (Asare et al. 2021). In coastal aquifers affected by seawater intrusion, a sequence of geochemical reactions occur when freshwater is replaced by seawater. These chemical changes can be attributed to variations in the chemical characteristics of the recharge source, aquifer constituents, and fluctuations in groundwater level. Based on the literature review, the HFE-D can present the process of these changes much more useful than the Piper diagram method (Hajji et al. 2021; Le et al. 2020).

This diagram, which was first proposed by Gimenez-Forcada (2010), is a simple and robust method to identify the condition of coastal aquifers exposed to seawater intrusion, the percentage of salt and freshwater mixing, and checking the interference positions of sea saltwater using the distribution of anion and cation percentages in the form of a specific diagram (Giménez-Forcada and Sánchez San Román 2015). During the process of sea saltwater intrusion (intrusion stage), the aquifer is affected by two simultaneous processes: salinity increase due to the rapid exchange of \({{\text{Na}}}^{+}\) with \({{\text{Ca}}}^{2+}\) and reverse exchange reactions (lines II and VI in Fig. 6). As a result of these processes, the Ca–Cl facies is developed. After that, the qualitative composition of the groundwater becomes \({{\text{Na}}}^{+}-{{\text{CL}}}^{-}\) facies due to the movement towards the salty seawater (line III in Fig. 6). In other words, when a saltwater intrusion occurs in coastal aquifers, hydrochemical facies change from \({{\text{Ca}}}^{2+}-{{\text{HCO}}}_{3}^{-}\) to \({{\text{Ca}}}^{2+}-{{\text{CL}}}^{-}\) and finally to \({{\text{Na}}}^{+}-{{\text{CL}}}^{-}\).

Fig. 6
figure 6

Hydrochemical facies evolution diagram (HFE-D) (redesign based on Amiri et al. (2015); Le et al. (2020))

During the freshening process, freshwater recharge leads to direct exchange reactions (lines V and IV in Fig. 6) and the formation of \({{\text{Na}}}^{+}-{{\text{HCO}}}_{3}^{-}\) facies. Finally, the water becomes freshwater due to mixing with the aquifer (line I) (Amiri et al. 2015; Gimenez-Forcada 2010). Accordingly, when freshwater feeding is dominant in coastal aquifers, \({{\text{Na}}}^{+}\) replaces \({{\text{Ca}}}^{2+}\), and the hydrochemical facies change from \({{\text{Na}}}^{+}-{{\text{CL}}}^{-}\) to \({{\text{Na}}}^{+}-{{\text{HCO}}}_{3}^{-}\).

According to the above explanations and based on the percentage of main ions (sum of sodium and potassium, calcium, bicarbonate, and chloride), the qualitative samples of the aquifer can be divided into 16 hydrochemical facies, and if magnesium and sulfate are also considered, the number of hydrochemical facies increases to 32. If the percentage of calculated ions is greater than 50%, four main facies can be identified in the HFE-D diagram, which is as follows: \({{\text{Na}}}^{+}-{{\text{HCO}}}_{3}^{-}\) (saltwater under the influence of direct cation exchanges), \({{\text{Na}}}^{+}-{{\text{Cl}}}^{-}\) (seawater), \({{\text{Ca}}}^{2+}-{{\text{HCO}}}_{3}^{-}\) (freshwater), and \({{\text{Ca}}}^{2+}-{{\text{Cl}}}^{-}\) (Saltwater under the influence of reverse cation exchange). If the the calculated percentage for some of the mentioned anions and cations is less than 50%, while simultaneously exceeding 50% for others, the facies are identified with the mix prefix (Le et al. 2020).

On the HFE-D diagram, the line that separates the saltwater and freshwater of the aquifer is considered the conservative mixing line (CML). Its position is determined by analyzing the chemical composition of samples taken from the aquifer (Gimenez-Forcada 2010).

The two arrows around the CML line represent the evolutionary reactions of water hydrogeochemical changes during intrusion (reverse exchange reactions) and freshening (direct exchange reactions). The sediments in the groundwater aquifers of the study area have a mixed marine-alluvial origin, characterized by interlayers of clay, silt, sand, and coarse to fine sand. (Mazandaran Regional Water Organization 2010). Clay minerals in sediments provide suitable chemical conditions for direct and reverse cation exchanges.

To closely examine the governing processes during the freshening and intrusion stages on the HFE-D diagram, these stages are subdivided into sub-stages that illustrate the spread of salinity based on the percentage of ions. With this information, the sub-stages marked with “i” and “f” represent the intrusion and freshening stages, respectively (Giménez-Forcada 2019).

In this study, in order to show the spatial distribution of dominant facies in the intrusion and freshening processes, each of the sub-stages was given a score from 1 to 10. In this scoring, the minimum and maximum assigned to freshwater (FW) and seawater (SW) are equal to 1 and 10, respectively. Also, for sub-stages f4, f3, f2, and f1, scores in the range of 2 to 5, and for sub-stage i1, i2, i3, and i4, scores from 6 to 9 were considered. According to the coloring of each of the sub-stages and extracting the spatial distribution of different water types using ArcGIS 10.8, it becomes possible to identify each of the sub-stages related to the intrusion and freshening processes (Table 2). The stages for assessing potential seawater intrusion in the GH.-J. multilayered aquifer, as described above, are presented in Fig. 7.

Table 2 Values and colors considered to identify miscellaneous hydrochemical facies based on Giménez-Forcada (2014) and Le et al. (2020) studies

Results and discussion

Chemical composition of groundwater samples of the coastal multilayered aquifer of GH.-J.

Analyzing qualitative samples drawn between 2011 and 2020 on the modified Piper diagram (Fig. 13) reveals that the predominant water type in the unconfined aquifer is mixed Ca–Mg–Cl and Ca–\({{\text{HCO}}}_{3}\); in the saline aquifer, it is mixed Ca–Mg–Cl; in the perched aquifer, it is Ca–\({{\text{HCO}}}_{3}\); and in the confined aquifer, it is mixed Ca–Mg–Cl and Ca–\({{\text{HCO}}}_{3}\). Furthermore, significant changes have been observed in the chemical composition and salinity of groundwater samples across various layers of the studied aquifers.

The range of variations of the main cations and anions, as well as the minimum and maximum values of TDS (mg/l) and EC (µs/cm) of four aquifers during a 10-year period, is according to Table 3. In most areas, a TDS value greater than 1000 mg/l typically indicates salinity, except in dry regions where water scarcity is prevalent, and low-quality water is commonly utilized. (Elgettafi et al. 2012). The pH value of all aquifers is in the neutral range between 6 and 8. The dominant cations and anions of the groundwater in the four aquifers are \({{\text{Ca}}}^{2+}\), \({{\text{Na}}}^{+}\), \({{\text{HCO}}}_{3}^{-}\), and \({{\text{Cl}}}^{-}\). Overall, in the studied area, the concentration of \({{\text{Ca}}}^{2+}\) cation in unconfined, confined, and perched aquifers exceeds that of \({{\text{Na}}}^{+}\), except in the saline aquifer, the concentration of \({{\text{Na}}}^{+}\) surpasses that of \({{\text{Ca}}}^{2+}\) in the years 2011 and 2017. The concentration of \({{\text{NO}}}_{3}^{-}\) in the years 2014 and 2020 significantly increases in many wells across all aquifers. This suggests that the pollution is local and temporary and is caused by the elevated use of nitrogen-containing urea fertilizer in agricultural farms for rice cultivation.

Table 3 The decreasing order of major cations and anions in unconfined, confined, saline, and perched aquifers in 2011, 2014, 2017, and 2020 years

To explore the reasons for changes in the concentration of various ions and investigate the sources of their release in groundwater, creating scatter plots of different ions versus chloride ions, as well as examining the ratio of different ion pairs and saturation index, can offer valuable insights into the origin of salinity and its intrusion (Figs. 1, 2, 3, 4, 5, 6 and 7, along with Fig. 8, are presented in part II of Supplementary information).

  • Based on the scatter plots drawn between anions and cations relative to the stable ion \({{\text{Cl}}}^{-}\), it can be seen that \({{\text{Cl}}}^{-}\) has a strong positive correlation with TDS, EC, and \({{\text{Na}}}^{+}\). Therefore, this ion is the controller of EC in the studied coastal aquifer (Carol and Kruse 2012). Also, chloride ion shows a weak positive correlation with \({{\text{Ca}}}^{2+}\), \({{\text{Mg}}}^{2+}\), \({{\text{NO}}}_{3}^{-}\), \({{\text{HCO}}}_{3}^{-}\), and \({{\text{SO}}}_{4}^{2-}\). The correlation of \({{\text{Mg}}}^{2+}\) ion with \({{\text{Na}}}^{+}\), \({{\text{K}}}^{+}\), and \({{\text{Ca}}}^{2+}\) is positive but not strong. This is attributed to the influence of other sources, in addition to sea saltwater intrusion, contributing to the increased salinity of the aquifer. (Asare et al. 2021).

  • A TDS versus EC plot showing a slope above 0.99, significantly exceeding the range of 0.55–0.75 reported by Hem (1970), can be indicative of saline water intrusion into the aquifer, possibly from the Caspian Sea or fossil saline water.

  • Scatter plots of \({{\text{Na}}}^{+}\) versus \({{\text{Cl}}}^{-}\) reveal a linear increase in \({{\text{Na}}}^{+}\) with \({{\text{Cl}}}^{-}\), following the 1:1 line in all four aquifers. Based on the graphs drawn, in unconfined, perched, and saline aquifers, \({{\text{Na}}}^{+}\) and \({{\text{Cl}}}^{-}\) show a correlation with \({R}^{2}\) equal to or above 0.80 and in confined aquifers with \({R}^{2}\) above 0.90 (except for 2017). Therefore, it can be found that the controller process of the \({{\text{Cl}}}^{-}\) ion in the confined aquifer is more influenced by the \({{\text{Na}}}^{+}\) from fossil saline water located at the aquifer bedrock (Khairy and Janardhana 2013), whereas the \({{\text{Na}}}^{+}\) ion in other aquifers originates from various sources, in addition to sea salt water.

  • Scatter plots of Na/Cl to \({{\text{Cl}}}^{-}\) can provide additional insights into the sources of \({{\text{Na}}}^{+}\) increase in groundwater (El-Fadel et al. 2014; Klassen et al. 2014; Sarkar et al. 2021). If this ratio is equal to one, it indicates the dissolution of halite minerals. The dissolving of other minerals and the cation exchange process can change this ratio. Since chloride is a relatively stable ion, Na/Cl > 1 can occur for two reasons: the dissolution of evaporite minerals containing \({{\text{Na}}}^{+}-{{\text{SO}}}_{4}^{2-}\) and direct cation exchange between \({{\text{Ca}}}^{2+}\mathrm{ and N}{{\text{a}}}^{+}\) due to infiltration of freshwater (Elgettafi et al. 2012). According to the graphs drawn in the studied area, this ratio is greater than one in some wells and less than one in others. As evaporite minerals containing sodium are absent in the studied area, the increase in the Na/Cl ratio in some wells can be attributed to direct cation exchanges due to feeding the aquifer with freshwater. Also, in wells where Na/Cl < 1, it can indicate the reverse cation exchange process due to saltwater infiltration into the coastal aquifer. Investigations on the number of samples with a Na/Cl > 1 show that their number has increased from 48 and 40% in 2011 to 60 and 53% in 2020 in unconfined and confined aquifers, respectively. This indicates the development of anthropogenic activities in creating aquifer pollution and increasing the Na/Cl ratio. When salty seawater intrudes freshwater coastal aquifers, chemical exchange processes occur between coastal aquifer rocks and seawater, resulting in calcium replacing sodium. Thus, due to the stability of chloride concentration and sodium concentration decreases, the Na/Cl ratio decreases (Asare et al. 2021; Ghezelsofloo et al. 2021).

  • Under saltwater intrusion conditions in coastal aquifers, cationic exchange reactions occur in the form of Ca–Na and Ca–Mg. During exchange reactions between cations, the concentration of sodium and magnesium decreases, and the concentration of calcium increases (Carol and Kruse 2012). Examining the \({{\text{Ca}}}^{2+}\) versus Na scatter diagram of the studied aquifers during the years 2011, 2014, 2017, and 2020 shows the mixing process between the freshwater of the aquifer and the saltwater of the Caspian Sea. Based on these graphs, the groundwater in four aquifers shows more enrichment in \({{\text{Ca}}}^{2+}\) than \({{\text{Na}}}^{+}\), which reflects the intrusion of saltwater (Shin et al. 2020) and reverse cation exchange in the aquifers. It should be noted that this process has also been mentioned as one of the factors of increasing salinity concentration in the aquifer in Sarkar et al. (2021) research. Nevertheless, the low correlation between chloride and calcium, suggests that, aside from seawater intrusion, other factors also contribute to the degradation of the quality of this coastal aquifer.

  • The scatter diagrams of Mg/Ca versus \({{\text{Cl}}}^{-}\) for both unconfined and confined aquifers during the studied period show that the average of this ratio in the unconfined aquifer for the years 2011, 2014, 2017, and 2020 is 0.66, 0.31, 0.49, and 0.48, while in the confined aquifer, it is 0.39, 0.23, 0.4, and 0.82, respectively. The ratio of Mg/Ca > 1 in the samples indicates the dissolution of dolomite in the groundwater (Elgettafi et al. 2012; Jahanshahi and Zare 2016). Given that the average of this ratio in both aquifers is less than one, it indicates that the origin of \({{\text{Mg}}}^{2+}\) in the aquifers is not from the dissolution of dolomite but primarily reflects reverse cation exchange processes in the aquifer (Pulido-Leboeuf et al. 2003). It is worth noting that seawater typically has a high Mg/Ca ratio, ranging between 4.5 and 2.5. The low Mg/Ca ratio in the aquifer is also a result of sulfate reduction (El-Fadel et al. 2014). As the Ca/Mg ratio of the collected samples from all studied aquifers is greater than one, one of the reasons for the increase in calcium can be as a result of the seawater intrusion (Ghezelsofloo et al. 2021).

  • Based on the scatter diagrams of \({{\text{Ca}}}^{2+}\) and \({{\text{Mg}}}^{2+}+{{\text{Ca}}}^{2+}\) versus \({{\text{HCO}}}_{3}^{-}\), if the presence of these ions in the groundwater is the result of calcite dissolution, the plotted points should lie on a line with a slope of 1:1 (Elgettafi et al. 2012; Jahanshahi and Zare 2016). Considering that the samples of the studied area did not follow this trend and showed a weak correlation with each other, it can be concluded that the concentration of \({{\text{Ca}}}^{2+}\) or \({{\text{Mg}}}^{2+}\) in the groundwater has originated from other sources, such as reverse cation exchange. Therefore, the equilibrium reaction of the calcite and dolomite dissolution/deposition process is carried out in the left direction, and as a result, the amount of \({{\text{HCO}}}_{3}^{-}\) in the aquifer decreases (Jahanshahi and Zare 2016).

    $${{\text{CO}}}_{2}+{{\text{H}}}_{2}{\text{O}}+{{\text{CaCO}}}_{3}\leftrightarrow {{\text{Ca}}}^{2+}+2{{\text{HCO}}}_{3}^{-}$$
    (4)
    $${{\text{CO}}}_{2}+{{\text{H}}}_{2}{\text{O}}+{\text{CaMg}}{({{\text{CO}}}_{3})}_{2}\leftrightarrow {{\text{Ca}}}^{2+}+{{\text{Mg}}}^{2+}+4{{\text{HCO}}}_{3}^{-}$$
    (5)
Fig. 7
figure 7

Flowchart of proposed methodology to assess potential seawater intrusion

Fig. 8
figure 8

Scatters plots of chemical constituent relationships in the unconfined aquifer (2011)

  • Soluble sedimentary minerals that can release \({{\text{Ca}}}^{2+}\) and \({{\text{SO}}}_{4}^{2-}\) ions in water due to dissolution include gypsum (\({{\text{CaSO}}}_{4}^{2-}.2{{\text{H}}}_{2}{\text{O}}\)) and anhydrite (\({{\text{CaSO}}}_{4}^{2-}\)). By drawing a scatter diagram of \({{\text{Ca}}}^{2+}\) and \({{\text{SO}}}_{4}^{2-}\) ions, one can determine the origin of these ions. If gypsum dissolution has occurred in groundwater, samples should be placed along the 1:1 line (Elgettafi et al. 2012). According to Fig. 8 and Figs. 1, 2, 3, 4, 5, 6 and 7 presented in part II of Supplementary information, none of the samples was located along the 1:1 line. However, all the samples were located along the vertical axis of the \({{\text{Ca}}}^{2+}\) ion. Therefore, the \({{\text{Ca}}}^{2+}\) concentration of the samples has increased, or the \({{\text{SO}}}_{4}^{2-}\) concentration has decreased. Therefore, the origin of \({{\text{Ca}}}^{2+}\) and \({{\text{SO}}}_{4}^{2-}\) ions cannot be attributed to the dissolution of gypsum and anhydrite minerals. The low concentration of \({{\text{SO}}}_{4}^{2-}\) may be a result of biological reduction in the region. Also, the increase in \({{\text{Ca}}}^{2+}\) can be related to the dissolution of calcite dolomite, as well as reverse cation exchange reactions. Based on the results of scatter diagrams for \({{\text{Ca}}}^{2+}\) and \({{\text{Ca}}}^{2+}+{{\text{Mg}}}^{2+}\) versus \({{\text{HCO}}}_{3}^{-}\) in the studied area, the only plausible reason for the rise in \({{\text{Ca}}}^{2+}\) appears to be reversed cation exchanges reactions. In order to investigate the cause of the increase in the \({{\text{Ca}}}^{2+}\) and \({{\text{Mg}}}^{2+}\) ions as a result of the dissolution of calcite and dolomite or other minerals, the scatter diagram of \({{\text{Ca}}}^{2+}+{{\text{Mg}}}^{2+}\) vs \({{\text{SO}}}_{4}^{2-}-{{\text{HCO}}}_{3}^{-}\) was drawn. If the dissolution of calcite, dolomite, and gypsum are in equilibrium conditions, the samples are drawn along a line with a slope of 4:7, and the following relationship is established (Jahanshahi and Zare 2016):

$${3{\text{CO}}}_{2}+3{{\text{H}}}_{2}{\text{O}}+{{\text{CaCO}}}_{3}+{\text{CaMg}}{({{\text{CO}}}_{3})}_{2}+{{\text{CaSO}}}_{4}\leftrightarrow 3{{\text{Ca}}}^{2+}+{{\text{Mg}}}^{2+}+6{{\text{HCO}}}_{3}^{-}+{{\text{SO}}}_{4}^{2-}$$
(6)

The scatter diagrams that are drawn in Figs. 6, 7, 8, 9, 10, 11, 12 and 13 show that most of the samples are on the left side of this line, and based on this, it can be concluded that in the studied area, the source of increasing the concentration of \({{\text{Ca}}}^{2+}\), \({{\text{Mg}}}^{2+}\), and \({{\text{SO}}}_{4}^{2-}\) ions are not the dissolution of calcite, dolomite, and gypsum minerals.

Fig. 9
figure 9

Mean saturation indices of evaporate minerals in the unconfined and confined aquifers of GH.-J. plain (from 2011 to 2020)

Fig. 10
figure 10

Scree plots of the physicochemical variables in the unconfined aquifer (a, b, c, and d) and confined aquifer (e, f, g, and h)

Fig. 11
figure 11

Varimax loading of the physicochemical variable’s factors in three-dimensional space in the confined and unconfined aquifer

Fig. 12
figure 12

Variations of precipitation, measured water table, and piezometric level in the confined and unconfined aquifers of GH.-J. aquifer (2011–2020)

Fig. 13
figure 13

Representation of groundwater sampled from four aquifers in a 2011, b 2014, c 2017, and d 2020 on Piper diagram

In order to confirm the results of the scatter plots and ion ratios, the saturation index (SI) is calculated. Saturation index can show the effect of rock weathering on water chemistry and can be measured with the help of Eq. 7 (Ghosh et al. 2022; Zhang et al. 2020).

$$SI=\frac{{K}_{{\text{IAP}}}}{{K}_{{\text{SP}}}}$$
(7)

where KIAP and KSP are ion’s activity products for a mineral reaction and the solubility product of that mineral, respectively. The PHREEQC software (v. 3.3.7) is handy for calculating the SI of minerals in the water (Parkhurst and Appelo 1999). The SI value indicates the nature of water and mineral chemical equilibrium with water–rock interaction. SI < 0 indicates an unsaturated state where the minerals undergo continuous weathering by the groundwater or surface water; Conversely, SI > 0 states the supersaturated state when the minerals start to precipitate. Moreover, SI close to 0 indicates the equilibrium states of the mineral phase.

The values of the saturation index of every mineral genuinely represent the actual phenomena of rock-water interaction and their contribution to the evolution of groundwater hydrochemistry. The SI values for calcite, aragonite, dolomite, halite, sylvite, and gypsum in both unconfined and confined aquifers consistently fall within the negative range, signifying an unsaturated state. Therefore, the dissolution of these minerals can determine the amount of \({{\text{Na}}}^{+}\), \({{\text{K}}}^{+}\), \({{\text{Ca}}}^{2+}\), \({{\text{Mg}}}^{2+}\), \({{\text{SO}}}_{4}^{2-}\), \({{\text{Cl}}}^{-}\), and \({{\text{HCO}}}_{3}^{-}\) in the groundwater in both aquifers. Nevertheless, considering that there are no evaporate formations such as halite, sylvite, gypsum, and anhydrite in the case study, it can be concluded that significant concentrations of \({{\text{Na}}}^{+}\), \({{\text{K}}}^{+}\), \({{\text{Ca}}}^{2+}\), \({{\text{Mg}}}^{2+}\), \({{\text{Cl}}}^{-}\), and \({{\text{SO}}}_{4}^{2-}\) are attributable to saline fluids from fossil aquifer and the intrusion of saltwater.

Due to the higher SI for calcite and aragonite minerals compared to other minerals in the recharge zone (located in the southern part of the plain), the effect of the dissolution of carbonate-containing rocks (the limestone and marl formations of the highlands) on the development of groundwater is determined. The higher value of the SI of the confined aquifer, compared to the unconfined aquifer, shows that this aquifer is more affected by the intrusion of saltwater and fossil saline aquifer (Fig. 9).

Major controllers on groundwater chemical composition in the GH.-J. plain aquifers

Pearson’s correlation matrix analysis (CMA) was performed to find relationships between two or more variables using IBM Statistic SPSS 26.0 software in unconfined and confined aquifers during the years 2011, 2014, 2017, and 2020 (Tables 1, 2, 3, 4, 5, 6 and 7, along with Table 4 (refer to supplementary information Part II for details)). It should be noted that the correlation value greater and smaller than 0.6 indicates a strong and weak correlation between the variables, respectively (Elgettafi et al. 2012). Considering the strong correlation of EC with \({{\text{HCO}}}_{3}^{-}\), \({{\text{Na}}}^{+}\), \({{\text{K}}}^{+}\), \({{\text{Cl}}}^{-}\), and TDS, it can be found that these parameters are the main sources of salinity in the studied area. Also, these parameters show a strong correlation with each other. This shows that the water of different samples has similar geochemical properties. Also, the strong correlation of these parameters with \({{\text{Cl}}}^{-}\) suggests minimal interaction of water with the rocks in the porous media since the water enters the aquifers.

Table 4 Pearson’s correlation matrix of the unconfined aquifer hydrochemical parameters in 2011

In order to investigate the main factors controlling the chemical composition of groundwater in the unconfined and confined aquifers and their variations during the study period, principal component analysis (PCA) was applied to all samples. The results of the Scree test, as shown in Fig. 10, confirm that only the two first principal components should be considered as salinity factors. This implies that the controlling factors for salinity, with the exception of the unconfined aquifer in 2017) are reduced to two components. Because the eigenvalue accounted by the third component is smaller than the minimum eigenvalue (i.e., 1), it is ignored. This factor analysis reduced the dimensions of 13 physicochemical parameters to two principal components (PCs) that account for more than 83% of the variance of the entire data set during different years. In this analysis, a factor loading greater than + 0.6 is considered significant (Elemile et al. 2021). Consequently, only parameters deemed significant based on the factor load value are presented in Table 8 and 9 (refer to supplementary information part II). The Varimax loading of the physicochemical variable’s factors in three-dimensional space is shown in Fig. 11. It should be noted that analysis of main components in saline and perched aquifers has not been applicable due to the minimal number of samples.

In an unconfined aquifer in 2011, the first principal component (PC1) shows a significant and high positive factor loading with \({{\text{Na}}}^{+}\), \({{\text{K}}}^{+}\), \({{\text{Cl}}}^{-}\), TDS, and EC and includes 55.86% of the variance of the entire dataset. The high positive correlation between the parameters \({{\text{Na}}}^{+}\), \({{\text{K}}}^{+}\), \({{\text{Cl}}}^{-}\), TDS, and EC and the lack of significant correlation between \({{\text{Cl}}}^{-}\) and \({{\text{Ca}}}^{2+}\), \({{\text{Mg}}}^{2+}\), and \({{\text{SO}}}_{4}^{2-}\) indicate that the first source of the salinity of this aquifer in 2011 is the infiltration of fossil saline water from bedrock and seawater intrusion. The second factor, which accounts for about 29.14%, includes \({{\text{Ca}}}^{2+}\), \({{\text{Mg}}}^{2+}\), and \({{\text{SO}}}_{4}^{2-}\) parameters. Chloride has not shown a strong significant correlation with these parameters, and therefore, it cannot originate from seawater or fossil saline water. On the other hand, based on the scatter diagrams drawn in the previous section, the factor of producing these parameters cannot be the dissolution of minerals such as calcite, dolomite, and gypsum. Based on the available evidence, it can be concluded that the second source of groundwater salinity in 2011 was the reverse cation exchange process due to the favorable lithological conditions in the aquifer (the presence of clay minerals and carbonaceous organic materials).

In 2014, PC1 shows a significant positive factor loading with \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, TDS, \({{\text{K}}}^{+}\), \({{\text{SO}}}_{4}^{2-}\), and includes 62.14% of the total data variance. The high positive correlation between the parameters \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, TDS, \({{\text{K}}}^{+}\), and \({{\text{SO}}}_{4}^{2-}\) and the lack of significant correlation between \({{\text{Cl}}}^{-}\), \({{\text{NO}}}_{3}^{-}\), and \({{\text{HCO}}}_{3}^{-}\) indicate that the first source of groundwater salinity in the unconfined aquifer in 2014 is seawater and fossil saltwater trapped in the coastal unconfined aquifer sediments. In fact, since 2013, due to the establishment of the water supply network of the Alborz dam (WSNA) in the plain, the use of groundwater for agriculture has been reduced (shahnazari et al. 2018). As a result, it has prevented the entry of seawater and fossil saltwater from bedrock into the aquifer. Therefore, salty waters that have already remained among the sediments are considered the first salinity cause this year. The second factor, which accounts for 22.5%, includes \({{\text{NO}}}_{3}^{-}\) and \({{\text{HCO}}}_{3}^{-}\) parameters. Similar to the reasons presented in the second factor related to 2011, the origin of these parameters is not from seawater or fossil saline water. Also, based on the scatter diagrams of \({{\text{Ca}}}^{2+}\) and \({{\text{Mg}}}^{2+}+{{\text{Ca}}}^{2+}\) versus \({{\text{HCO}}}_{3}^{-}\) and the existence of a weak correlation between them, the cause of \({{\text{HCO}}}_{3}^{-}\) production cannot be the dissolution of minerals such as calcite, dolomite, and gypsum. Based on the available evidence, it can be concluded that the second source of salinity in 2014 is the high volume of sugar urea fertilizer consumption (with 46% absorbable nitrogen content) in rice fields and the penetration of nitrates into the groundwater through agricultural return flow (affected by the establishment of the WSNA since 2013).

In 2017, the PC1 showed a significant and high positive factor loading with \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, TDS, \({{\text{K}}}^{+}\), and \({{\text{SO}}}_{4}^{2-}\) and accounts for 52.610% of the total data variance. The strong positive correlation among these parameters, along with the absence of a significant correlation between \({{\text{Cl}}}^{-}\) and other parameters, indicates that the utilization of water from the WSNA on the plain, coupled with reduced groundwater extraction, has stopped the penetration of salty water from the sea and bedrock to the coastal aquifer. As a result, the first source of salinity in the unconfined aquifer in 2017 is similar to the salinity source in 2014. In 2017, PC2 accounted for 18.7% of the total variance and included \({{\text{HCO}}}_{3}^{-}\) and \({{\text{Mg}}}^{2+}\) parameters. The absence of a strong significant correlation of chloride with these parameters, and also based on a scatter plot (\({{\text{Ca}}}^{2+}+{{\text{Mg}}}^{2+}\)) to \({{\text{HCO}}}_{3}^{-}\), can be seen that the origin of these parameters is not from seawater, fossil saline water, and dissolution of dolomite. Therefore, the second salinity factor in 2017 was reverse cation exchange in the unconfined aquifer. The third principal component (PC3) shows a significant and high positive factor loading with \({{\text{NO}}}_{3}^{-}\) and includes 12.08% of the variance of the entire data set. As this parameter has not demonstrated a strong and significant correlation with other parameters, the presence of nitrate can be attributed to agricultural activities and the extensive use of nitrate fertilizers, leading to their infiltration into groundwater through agricultural return flow. On the other hand, the establishment of the WSNA in 2013 has been effective in better transfer of nitrate in chemical fertilizers to groundwater.

In 2020, the PC1 showed a significant and high positive factor loading with \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, TDS, \({{\text{K}}}^{+}\), and \({{\text{HCO}}}_{3}^{-}\) and accounting for 62.97% of the total data variance. The high positive correlation between these parameters together and the lack of significant correlation between \({{\text{Cl}}}^{-}\), \({{\text{NO}}}_{3}^{-}\), and \({{\text{SO}}}_{4}^{2-}\) indicate that the primary source of the salinity of the unconfined aquifer in 2020 is still sea saltwater and fossil waters trapped in the sediments of this aquifer. The PC2 with accounting for 20.06% includes \({{\text{NO}}}_{3}^{-}\) and \({{\text{SO}}}_{4}^{2-}\) parameters. Chloride does not show a strong significant correlation with these parameters, so the origin of these parameters cannot be from seawater or fossil saline water. On the other hand, the weak correlation between \({{\text{Ca}}}^{2+}\) and \({{\text{SO}}}_{4}^{2-}\) shows that the origin of the \({{\text{SO}}}_{4}^{2-}\) cannot be from the dissolution of gypsum. Therefore, the sole factor capable of elevating the concentration of \({{\text{NO}}}_{3}^{-}\) and \({{\text{SO}}}_{4}^{2-}\) is the extensive use of nitrated chemical fertilizers, triple superphosphate (a combination of sulfuric acid and natural phosphate), and potassium sulfate in agricultural lands.

Through statistical and factor analysis conducted on the unconfined aquifer samples over a 10-year period, it is evident that the main factors of salinity and the variations in water chemical composition of this aquifer differ across various years. The entry of saline water from the Caspian Sea into the unconfined aquifer and the rise of fossil saline water from the bedrock under the influence of the increase in the exploitation of agricultural wells were identified as the leading causes of salinity in all the studied years. The variation of groundwater level and piezometric level (Fig. 12) shows that the piezometric surface of the confined aquifer is higher than the water level of the unconfined aquifer. Therefore, according to the geological and lithological conditions in the studied area, there is a possibility of saltwater leakage from the salted confined aquifer to the unconfined aquifer in the parts where there are leakage layers.

In 2011 and 2017, the reverse cation exchange process, and in 2014 and 2020, the impact of domestic sewage, agricultural activities, and nitrate-containing chemical fertilizers were identified as the second factor of salinity and changes in the chemical composition of an unconfined aquifer. In 2017, agricultural activities and the extensive use of nitrate fertilizers were considered as the third factor of salinity. Therefore, the parameters of the first factor during these 10 years, as well as the parameters of the second factor in the years 2011 and 2017, according to their origin, indicate the general trend of groundwater (natural) and the influence of geological formations on it (Geogenic and hydro-geochemical processes). The effective parameters in the second factor in 2014 and 2020 and the third-factor parameter in 2017 show the effect of human or agricultural activities (anthropogenic origin) in increasing salinity (Table 5).

Table 5 Main pollution sources governing the quality of GH.-J. plain aquifers

In this section, the results of the PCA on the confined aquifer samples in 2011, 2014, 2017, and 2020 are described as follows.

In the confined aquifer in 2011, the first rotated component (PC1) shows a positive, significant, and high factor loading with \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, and TDS and accounting for 54.1% of the total data variance. The high positive correlation between these parameters together and the lack of significant correlation between \({{\text{Cl}}}^{-}\), \({{\text{Ca}}}^{2+}\), \({{\text{K}}}^{+}\), and \({{\text{HCO}}}_{3}^{-}\) indicates that although the water quality of this aquifer has been good until 2011, evidence of the progress of the intrusion phase can be seen in it. Therefore, the first source of the groundwater salinity of this aquifer in 2011 is the upcoming of the deep saline water into the confined aquifer under the influence of excessive groundwater pumping by agricultural wells in some parts of the plain. The second rotated component (PC2) which accounts for 39.69%, has strong positive loading with \({{\text{Ca}}}^{2+}\), \({{\text{K}}}^{+}\), and \({{\text{HCO}}}_{3}^{-}\). Therefore, it can be concluded that the second source of groundwater salinity in 2011 was reverse cation exchange due to the local upcoming of fossil saline water from bedrock to the confined aquifer and under favorable lithological conditions.

In 2014 and 2017, PC1 showed a positive, significant, and high factor loading with \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, and TDS, accounting for 51.75% and 52.86% of the total data variance, respectively. There is a high positive correlation between parameters \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, and TDS, together, expressing the local progress of the intrusion phase and the rise of fossil saline water from the bedrock in 2014 and its development in 2017. Also, in 2014 and 2017, PC2 accounted for 40.07% and 39.9% of the total data variance, respectively. Considering the influential parameters within this factor, the second source of aquifer salinity encompasses domestic sewage, agricultural activities, and the extensive use of nitrate-containing chemical fertilizers, triple superphosphate (a combination of sulfuric acid and natural phosphate), and potassium sulfate.

The evaluation of the PC1 of 2020 shows that there is a high positive correlation between \({{\text{Na}}}^{+}\), \({{\text{Cl}}}^{-}\), EC, TDS, and \({{\text{Mg}}}^{2+}\) parameters. Also, there is no significant correlation between \({{\text{Cl}}}^{-}\) with \({{\text{Ca}}}^{2+}\), \({{\text{K}}}^{+}\), and \({{\text{HCO}}}_{3}^{-}\). Therefore, the progression of the intrusion phase and the rise of fossil saline water continues. According to PC2, the second source of confined aquifer salinity in 2020 is the progress of reverse cation exchanges due to the intrusion of fossil saline water.

Based on the statistical and factor analysis performed on the confined aquifer samples in 10 years, two main factors were identified for the origin of salinity and the change in the chemical composition of this aquifer. The rising fossil saline water from bedrock under the influence of increasing operation of agricultural wells is considered the first factor of salinity. The second most effective factor in 2011 and 2020 is associated with the reverse cation exchange process. In contrast, in 2014 and 2017, domestic wastewater, agricultural activities, and the use of nitrate fertilizers emerge as the primary contributors to this factor. Therefore, according to their origin, the factors of confined aquifer salinity in 2011 and 2020 were geogenic and hydro-geochemical, and in 2014 and 2017, they were anthropogenic (Table 5).

Evolution of potential seawater intrusion based on Piper diagram and \({GQI}_{{\text{SWI}}}\) index.

By calculating the groundwater quality indicators \({GQI}_{{\text{Piper}}\left({\text{mix}}\right)}\) and \({GQI}_{{\text{Piper}}\left({\text{dom}}\right)}\) based on the quality samples collected from four aquifers during the years 2011, 2014, 2017 and 2020, the modified Piper diagram was drawn according to Fig. 13. Also, the spatiotemporal distribution of the obtained water types for the four studied aquifers is presented in Figs. 15 and 16.

The separated results of the water quality type based on this diagram (Table 6) show that in the unconfined aquifer in 2011, 50% of the samples were in IV (mixed Ca–Mg–Cl waters), which these conditions reflect the visible impact of the intrusion phenomenon and the reverse cation exchange process in this coastal aquifer.

Table 6 Water type in all wells in unconfined, confined, saline, and perched aquifers based on the Piper diagram using GQIPiper(mix) and GQIPiper(dom) indices in 2011, 2014, 2017, and 2020

In 2014, 57.10% of the samples were in IV (Ca–Mg–Cl mixed waters), and 38.10% of samples were in I (freshwater). According to the increase in the percentage of samples located in the IV and I zones compared to 2011, it can be found that the intrusion process and the invasion of the saltwater in the unconfined aquifer from 2011 to 2014 experienced a decrease. This receding in the saline water intrusion has been affected by the establishment of the WSNA in the plain since May 2013 (Table 6) and the use of surface water in the irrigation of agricultural lands and gardens (by covering more than 98% of the plain area) (Fig. 14). These conditions indicate the ability of the freshwater to push back the saltwater front.

Fig. 14
figure 14

Representation of land-use map of the case study

From the increase in the percentage of samples located in zone I (freshwater) in 2017 compared to 2014, it can be seen that the effects of the WSNA are continuing in the pushing back the seawater intrusion (Table 7). In 2020, 52.4% and 4.8% of the samples were in zone IV (Ca–Mg–Cl mixed waters) and zone II (water salt), respectively. Therefore, intrusion on the plain has slightly increased from 2017 to 2020 due to decreased in inflow from WSNA in 2020 (Table 7; Fig. 15).

Table 7 The performance of the WSNA in the Ghaemshahr-Juybar plain
Fig. 15
figure 15

Spatial distribution of water chemistry types in GH.-J. plain based on Piper diagram using \({GQI}_{{\text{Piper}}\left({\text{mix}}\right)}\) and \({GQI}_{{\text{Piper}}\left({\text{dom}}\right)}\) indices in the perched, saline, and unconfined aquifers in a 2011, b 2014, c 2017, and d 2020

The only fresh aquifer in the studied area is the perched aquifer, located at the shortest distance from the Caspian Sea. However, the water in this aquifer has consistently remained fresh in all years, thanks to the presence of an alluvial layer covering the clay lenses. Although the effects of intrusion were observed in 2011 and 2014, during the following years, the amount of intrusion decreased so that in 2020, Ca \(-{{\text{HCO}}}_{3}\) was the dominant water type detected in this aquifer. Field investigations show that the chemical composition of this aquifer has also been improved with the establishment of the WSNA and the use of surface water in the irrigation of agricultural lands and gardens during these years.

The saline aquifer, located between the perched and unconfined aquifer, has consistently exhibited salinity over the years. However, similar to other aquifers in the plain, the salinity of this aquifer has been affected by the establishment of the WSNA. From 2014 to 2020, it has experienced a sharp decrease in salinity, leading to an improvement in groundwater quality (Fig. 15).

In 2011, the confined aquifer, characterized by the predominance of the Ca \(-{{\text{HCO}}}_{3}\) type in comparison to other available types (mixed Ca–Mg–Cl, Na–Cl), indicates minimal influence from saltwater intrusion. The cause behind this phenomenon is the overexploitation of groundwater through pumping wells and rise of the saltwater arch, acting as the bedrock in this aquifer. Consequently, the intrusion phenomenon is observed locally in some parts of the aquifer. The trend of decreasing the percentage of Ca \(-{{\text{HCO}}}_{3}\)-type samples and increasing the percentage of Na–Cl-type samples during 2014 to 2020 suggests an escalation in intrusion, attributable to the factors outlined in 2011 (Fig. 16).

Fig. 16
figure 16

Spatial distribution of water chemistry types in GH.-J, plain based on Piper diagram using \({GQI}_{{\text{Piper}}\left({\text{mix}}\right)}\) and \({GQI}_{{\text{Piper}}\left({\text{dom}}\right)}\) indices in the confined aquifer in a 2011, b 2014, c 2017, and d 2020

The investigation of the \({GQI}_{{\text{SWI}}}\) index in four aquifers and drawing its spatiotemporal distribution (Figs. 17 and 18) over 10 years reveals that a sample is not included in the group of seawater and saline groundwater (Table 8). Compared to the modified Piper diagram results, the groundwater samples of each aquifer are classified into two groups: freshwater and mixed ground water.

Fig. 17
figure 17

Spatial distribution of \({GQI}_{{\text{SWI}}}\) index in perched, saline, and unconfined aquifers for 2011 (a), 2014 (b), 2017 (c), and 2020 (d)

Fig. 18
figure 18

Spatial distribution of \({GQI}_{{\text{SWI}}}\) index in the confined aquifer for 2011 (a), 2014 (b), 2017 (c), and 2020 (d)

In unconfined aquifer, with the improvement of the water quality, the composition of freshwater has experienced an increasing trend of 79.17, 66.67, 78.26, and 82.6% during the 4 years (2011, 2014, 2017, and 2020). Also, in this aquifer, with the gradual reduction of sea saltwater intrusion, the chemical type of 20.83, 33.33, 21.74, and 17.40% of the samples was changed to mixed groundwater (Table 8; Fig. 17).

The saline aquifer affected by the freshwater of the Alborz irrigation network, which feeds the aquifers, has led to the creation of freshwater composition in 41.67, 40, 80, and 100% of the samples during 4 years, respectively. The positive effects of constructing irrigation networks on increasing the groundwater table level have also been confirmed in the Ghobadian et al. (2014) and YariPilmaraei et al. (2011) studies. Overexploitation from deep wells has led to saltwater rising from the lower layers and the intensification of saltwater intrusion phenomenon in the confined aquifer. This led to a decrease in the composition of freshwater from 95.45% in 2011 to 69.23% in 2020 in the samples of this aquifer. Therefore, the intrusion of poor-quality water available in the saltwater arch led to an increase in the composition of mixed groundwater from 4.55% in 2011 to 30.76% in 2020 (Fig. 18).

Investigating the spatial distribution of the qualitative composition of samples using the \({GQI}_{{\text{SWI}}}\) index shows that the process of saltwater intrusion in all aquifers has been an increasing trend from 2011 to 2014. This trend is attributed to the rising utilization of groundwater for agricultural purposes.

The process of increasing salinity and reducing the water quality of unconfined, perched, and saline aquifers affected by the establishment of the Alborz water supply network to allocate surface water for agricultural purposes from 2014 to 2020 has largely stopped and led to the improvement of the quality conditions of the mentioned aquifers. While in the confined aquifer, this trend is not true, and from 2014 to 2020, an increase in the mixing, infiltration, and intrusion of saltwater can be seen. According to the obtained results, it can be found that although both methods (modified Piper diagram and \({GQI}_{{\text{SWI}}}\) index) can indicate changes in groundwater quality, the modified Piper diagram demonstrates a higher degree of accuracy and detail in classifying the quality of groundwater compared to the \({GQI}_{{\text{SWI}}}\) index.

Table 8 Results of GQISWI index for GH.-J. groundwater samples in 2011, 2014, 2017, and 2020

Assessment of the hydrochemical facies evolution using HFE-D

Generally, using methods such as the modified Piper diagram and calculating the \({GQI}_{{\text{SWI}}}\) index, it is impossible to accurately identify the evolution sequence of hydrochemical facies during the process of intrusion and freshening. For this purpose, Gimenez-Forcada (2010) suggested that the HFE-D diagram can determine the evolution of the intrusion and freshening processes more accurately and comprehensively than other methods. This diagram is a graphical approach to finding hydrochemical facies and spatiotemporal dynamics of seawater intrusion processes in coastal aquifers (Giménez-Forcada 2019). The range of hydrochemical composition of aquifers expresses the difference in the evolution process of hydrochemical facies and the salinity potential of aquifers.

According to the HFE-D diagram, freshwater belongs to Ca \(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type in the zone (13) (sub-stage “f4”), and saline water belongs to the Na–Cl type in the zone (4) (sub-stage “i4”). During the intrusion phase, primary freshwater (Ca–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\)) in zone (13) (sub-stage “f4”) with Ca–Cl, MixCa–Cl, MixNa–Cl, and Na–Cl in the zone (16 and 8, 12, 4) (sub-stage “i3” and “i4”) is replaced. While in the freshening phase, facies with Na–Cl type in the zone (4) (sub-stage “f1”) evolve to Na–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\), MixNa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\), MixCa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\), and Ca–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) in the zone (13, 1, 5, 9) (sub-stage “f4”).

In order to evaluate the chemical composition of the groundwater during the intrusion and freshening processes, the HFE diagram was drawn for all four aquifers in the GH.-J. plain (Fig. 19). Also, based on this diagram, the number and percentage of facies in different aquifers were identified and presented in Table 9. In this evaluation, the samples from the years 2011, 2014, 2017, and 2020 were examined to assess the long-term changes that were not discernible through the modified Piper chart method and the \({GQI}_{SWI}\) index.

Fig. 19
figure 19figure 19

HFE-D to identify saltwater intrusion in unconfined, perched, and saline aquifers in 2011 (a), 2014 (b), 2017 (c), and 2020 (d) and in confined aquifer in 2011 (e), 2014 (f), 2017 (g), and 2020 (h)

Table 9 Hydrochemical facies of GH.-J. groundwater samples based on the HFE diagram

Most of the groundwater samples during these 10 years belong to the facies along the mixing line (13–10–7–4), which indicates simple mixing of fresh and salt water with little or no effect of cation exchanges. The position of the conservative mixing line (CML) in the four aquifers (Fig. 19) is different from the standard diagram presented by Gimenez-Forcada (2010) and Giménez-Forcada (2014). It should be noted that the position of this line depends on the selected freshwater end-member composition in a specific case study.

The mixing line in the diagram related to the unconfined aquifer in 2011 (Fig. 19a) is placed in the intrusion phase, which shows the salinity conditions prevail in this aquifer. The results of HFE-D (Table 9) show that in the unconfined aquifer in 2011, approximately 54% of the samples are in the freshening phase of the HFE chart and are plotted above the FW-SW mixing line. This shows that the intrusion phase is progressing, and freshwater recharge has been able to repel the intrusion phase partially. The observation of the two dominant types, MixCa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) and MixCa–Cl, in the aquifer confirms that this aquifer is affected by two factors: precipitation and saltwater infiltration.

The position of this mixing line in 2014 is transferred to the position of the mixing line of the standard Gime’nez-Forcada diagram, which indicates the sweetening of groundwater compared to 2011 under the influence of freshwater recharge (Fig. 19b). In 2014, although almost 65% of the samples in the intrusion phase are plotted below the FW-SW mixing line, two water types of Ca–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) and MixCa–Cl have increased significantly compared to 2011. It shows that the aquifer is reviving itself by feeding through the fresh surface water that entered the plain with the establishment of the Alborz water supply network. Also, the freshening process by direct cation exchange reactions is progressing and overcoming the intrusion phase. This result is consistent with the findings of shahnazari et al. (2018), which confirms the increase in the groundwater table level after implementing of the Alborz irrigation network construction plan.

In 2017, the mixing line was again transferred to the intrusion phase, but the percentage of freshening phase samples above the FW–SW mixing line has increased to 68% (Fig. 19c; Table 9). Also, the number of samples from zone (13) with Ca\(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type has increased, and the samples from zone (12) with MixCa–Cl type have been transferred to zones (11 and 9) with MixCa–MixCl and MixCa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type. The chemical evolutions observed indicate the freshwater recharge of the aquifer, the continuation of the freshening process, and direct cation exchange reactions within the aquifer. These changes are attributed to the influence of receiving fresh surface water from the Alborz water supply network.

In 2020, the percentage of intrusion phase samples increased again and reached 65%, which reflects the predominance of the intrusion phase and reverse cation exchanges (Fig. 19d). The dominant types of aquifer in this year are similar to 2017, with the distinction that the number of samples of zone (13) with Ca \(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type has decreased, while zones (9 and 11) with MixCa–MixCl and MixCa \(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) types have seen an increase. This could indicate a mixing and intrusion process.

In 2011, in the confined aquifer, 55% of the samples were plotted below the FW–SW mixing line and in the intrusion phase of the HFE diagram. The observation of the two dominant types of Ca \(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) and MixCa–HCO3/SO4 in zones (13) and (9) indicates that although the water of this aquifer has been good quality in 2011, but the intrusion phase and reverse cation exchange is progressing in this aquifer (Fig. 19e; Table 9).

In 2014, approximately 86% of the samples in the intrusion phase were plotted below the FW–SW mixing line, which shows the progress of the intrusion phase. Also, the dominant type this year is the Ca \(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\). According to the drawn HFE-D diagram, it can be seen that one sample in the zone (11) with MixCa–MixCl type, one sample in the zone (16) with Ca–Cl type, and finally, two samples in the zone (4) with Na–Cl type are located (Fig. 19f). This expresses the progression of the intrusion phase and the inverse cation exchanges as locally. Considering that the confined aquifer is located in the southern part of the plain and far from the Caspian Sea, the cause of the intrusion cannot be interference with the Caspian Sea. Due to the overexploitation of the deep wells and the rising of the saltwater arch that plays the bedrock in the aquifers of the GH.-J. plain, this aquifer has become locally saline.

In 2017, the percentage of samples above and below the mixing line reached 50 (Table 9), indicating the equilibrium between the two phases of intrusion and freshening. The dominant type this year remains the Ca–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) zone type (13), but the percentage of samples of this type has significantly decreased compared to 2014. The transfer of several samples from the zone (13) with Ca–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type to zone (14) with Ca–Mix \({{\text{HCO}}}_{3}\)/Mix \({{\text{SO}}}_{4}\) type indicates the progress of the intrusion process and the reverse cation exchange resulting from excessive extraction from deep wells and localized saltwater upconing. Furthermore, transferring the composition of a sample from zone (4) with Na–Cl type to zone (5) with MixNa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type and a sample from zone (16) with Ca–Cl type to zone (9) with MixCa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type reflects the freshening conditions and direct cation exchange caused by fresh surface water feeding from limited recharge areas of the confined aquifer (Fig. 19g).

In 2020, the percentage of samples above the FW–SW mixing line will reach 62% (Table 9), which indicates the predominance of the freshening phase. Also, by doubling the percentage of samples located in the zone (13) with Ca–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type compared to 2017, the effect of feeding from the Alborz water supply network can be seen. It is worth noting that due to the limited feeding area of the confined aquifer compared to the unconfined aquifer, the effect of fresh surface water percolation is observed with more delay than the unconfined aquifer. Observing samples with MixNa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type (zone 5) and MixCa–\({{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) type (zone 9) indicates the progress of the freshening process and direct cation exchanges. On the other hand, the observation of MixCa–Cl type (zone 12) and the Na–Cl type (zone 4) proves the progress of the intrusion process and the reverse cation exchange locally (Fig. 19h).

In the saline aquifer, the lack of sufficient freshwater recharge has caused the intrusion phase to dominate in this aquifer during 2011–2020 (The position of the mixing line in HFE-D (Fig. 19a–d) further corroborates this situation). In 2011, the dominant type of the aquifer was Na–Cl (zone 4), which indicates the complete salinization due to the intrusion process and reverse cation exchanges. The samples taken from this aquifer by Heidari Cherati (2020) also prove that this area has been affected by seawater intrusion due to excessive harvesting for agricultural purposes.

The transfer of the hydrochemical composition of the samples from zone (4) with Na–Cl type in 2011 to zone (8) with MixNa–Cl type in 2014 shows the mixing of saltwater with freshwater fed to the aquifer under the influence of the WSNA and the progress of the freshening phase in the saline aquifer. Finally, in 2020, with the continuation of the freshening process, the samples have shifted to zones (10) and (13) with the combination of MixCa–Mix \({{\text{HCO}}}_{3}\)/Mix \({{\text{SO}}}_{4}\) and \({{\text{Ca}}-{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) (freshwater), indicating the progress of freshening and direct cation exchange.

The samples in the perched aquifer in 2011, similar to the unconfined aquifer, are located above the FW–SW mixing line and in zones (7) and (10) with the combination of MixNa–MixCl and MixCa–Mix \({{\text{HCO}}}_{3}\)/Mix \({{\text{SO}}}_{4}\). This indicates that the aquifer is affected by the simple mixing of fresh and salt water with little or no effect of cation exchanges.

With the establishment of the WSNA in 2013, the freshwater front in the unconfined aquifer has become stronger and has moved in the direction of the hydraulic gradient from the south to the north (Caspian Sea). As a result, it causes a mixing of the freshwater of the perched aquifer with the saltwater of the saline aquifer. Therefore, as a result of intrusion and reverse cation exchanges, the Na–Cl and Na–MixCl types emerged in 2014.

In 2017, the perched aquifer altered its composition to MixNa–Cl (zone 8) and Ca \(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) (freshwater) (zone 13) by continuing to feed unconfined and saline aquifers with fresh surface waters and the progress of the freshening phase. This indicates the strengthening of the freshwater front and the repulsion of the saltwater from the perched aquifer. From 2017 to 2020, the freshening process continued so that in 2020, only Ca \(-{{\text{HCO}}}_{3}\)/\({{\text{SO}}}_{4}\) (zone 13) was observed in this aquifer. Indeed, it can be observed that the freshening process and direct cation exchanges are progressing in this aquifer located near the sea.

In order to evaluate the spatiotemporal distribution of hydrochemical facies using the sub-stages of the HFE-D diagram, the sampling points were ranked according to Table 2. Vulnerability maps of aquifers to saltwater intrusion were then created based on HFE-D for four selected years. The data were transformed into zoning maps using the kriging interpolation method. The spatiotemporal variations of freshening and intrusion conditions in four aquifers have been shown in Fig. 20. The relationship between coastal aquifers and seawater is a dynamic balance that relies on variations in recharge and discharge variations over time. This is evident in the boundary between freshening and intrusion depicted on the maps for each aquifer.

Fig. 20
figure 20

Spatial distribution of hydrochemical facies sub-stages in 2011, 2014, 2017, and 2020 in perched, saline, and unconfined aquifers (a, b, c, d) and confined aquifer (e, f, g, and h). Larger and small pink circles indicate more and less annual discharge, respectively

In 2011, within the unconfined aquifer, the boundaries between freshening and intrusion phases expanded significantly, encompassing a substantial portion of the unconfined aquifer, a significant segment of the saline aquifer, and limited areas to the east of the perched aquifer. This expansion is attributed to the overexploitation of wells for agricultural purposes. Only a tiny area in the south and north of the plain has been spared from intrusion (Fig. 20a). This shows that the feeding of the aquifer through precipitation and runoff was not enough for freshening to overcome intrusion. Also, considering that the Talar and Siah rivers feed the aquifer in the southern part and drain the aquifer in the middle and northern parts of the plain (Fig. 21); therefore, the evolution of hydrochemical facies in the unconfined aquifer is affected by this phenomenon. Consequently, freshening prevails in the southern part of the aquifer.

Fig. 21
figure 21

Groundwater table level map of the unconfined aquifer in 2020

It should be noted that the aquifer drainage by the mentioned rivers in the area of the saline aquifer can be considered a factor in intensifying the intrusion phase in this part of the aquifer. Therefore, the zone of freshening and intrusion along the course of the rivers indicates the effective hydraulic connection between the river and these aquifers. According to the surface water quality data obtained from the MRWC, the type of water in Talar and Siah Roud rivers exhibits a transition in composition. Upstream, it is characterized as calcium bicarbonate, in the middle as calcium sulfate, and downstream and close to the coastline as a combination of calcium chloride and sodium chloride, respectively. Additionally, throughout the study period, the EC and TDS values of these rivers are the lowest in the upstream, increase in the middle of the plain, and show a significant increase in downstream of the plain.

In 2014, the process of evolution of the hydrochemical facies of the unconfined aquifer has progressed in the direction of freshening due to freshwater recharge from the WSNA. The freshwater front from the south of the plain has strengthened and pushed the boundary between the two phases of freshening and intrusion. Consequently, this boundary in the unconfined aquifer has extended to areas near the center of the plain. Also, the freshwater front from the south of the plain and in the direction of the hydraulic gradient exerted pressure on the saltwater of the saline aquifer and brought the saltwater front to the perched aquifer. As a result, it can be seen that although the quality of unconfined and saline aquifers improved compared to 2011, the quality of perched aquifer decreased. These results show the evolution of the hydrochemical facies in the unconfined aquifer influenced by freshwater recharge (Fig. 20b).

The impact of continuous and increased freshwater recharge on the evolution of hydrochemical facies and the enhancement of the water quality in unconfined, saline, and perched aquifers in 2017 and 2020 can be seen in Fig. 20c, d. So that in 2017, with the increase of freshwater recharge, the strong freshwater front moved in the direction of the hydraulic gradient from the south to the north of the plain and split the saltwater zone. During this year, the effects of the intrusion phase are observed only in parts of the east and southwest of the saline aquifer and in the eastern and northwestern areas of the unconfined aquifer. Ultimately, the freshening phase prevails in the perched aquifer.

The increase of freshwater recharge in 2020 and its effect on the strengthening of the freshwater front, coupled with the retreat of the saltwater front in the eastern and western parts of the plain, affirm that the hydrochemical facies pattern in these three aquifers is more influenced by recharge factor and factors. Other factors such as aquifer lithology and the extent of groundwater drawdown appear to be less critical (Fig. 20d).

The hydrochemical facies pattern of the confined aquifer, situated in the southern area of the plain beneath the unconfined aquifer, is more responsive to fluctuations in groundwater levels caused by excessive pumping from deep wells in this aquifer than to the amount of recharge. This could be attributed to the limited extent of the recharge area for this aquifer and its considerable distance from the primary recharge source, predominantly recharged from the heights of the southern border of the plain.

In 2011 and 2014, the confined aquifer was balanced (Fig. 20e, f), and no traces of intrusion can be observed in it. In 2017, the intrusion phase was observed in two distinct areas, one in the east and the other in the west of the aquifer. Notably, these areas coincide with locations characterized by intensive pumping, where there is a scarcity of fresh surface water for agricultural and domestic use. Despite the increase in rainfall and freshwater recharge from the Alborz water supply network in the current year, the intrusion phase prevails in the western and eastern parts of the study area. This dominance is attributed to the substantial drawdown in groundwater levels resulting from the excessive extraction of deep wells and the rising of the saltwater arch in the confined aquifer (Fig. 20g).

The increasing trend of the intrusion phase continues in the western and eastern parts of the studied area in 2020 (Fig. 20h). Therefore, it seems that the confined aquifer lacks direct local recharge compared to the other three aquifers. The confirmation of these findings is evident in the HFE-D diagram, the position of the mixing line, the percentage of samples in each zone, and the sub-stage in all four aquifers as depicted in Fig. 20.

The role of lithostratigraphy formations in groundwater hydrochemical evolution

The GH.-J. catchment area is composed chiefly of limestone, marl, and dolomite formations in the highlands and alluvial fans in the plain, which consist of coarse-grained and permeable sediments. Towards the center of the plain, fine-grained sand, silty and clay sediments (new Caspian sediments) and below that, the sediments of the Apsheron formation are composed of clay, marl, unhardened sand, and conglomerate. According to the lithostratigraphy and geology of the case study, the chemical composition of the groundwater of GH.-J. plain can be described from the recharge zone to the discharge area.

In the recharge zone, the type of water is Ca \(-{{\text{HCO}}}_{3}\) due to the dissolution of carbonate minerals, with its quantity decreasing from the south to the north of the plain. In the middle part, the water type transitions to more Ca–Mg–Cl. The hydrochemical evolution is influenced by two main factors: the infiltration of saline water from the fossil saline aquifer and the process of cation exchange between groundwater and the alluvial layers containing clay. In this section, due to the absence of evaporite minerals, the dissolution process has not played a role in the evolution of groundwater hydrochemistry. At the end of the middle section, the water type shifts to Na–Cl. This is attributed to both the direct infiltration of saline water from the fossil saline aquifer and the exchange of cations between the groundwater and alluvial layers containing clay in this area, resulting in the formation of the saline aquifer. In the final part of the plain and the vicinity of the Caspian Sea, the placement of clay lenses on the alluvial layers has given rise to a perched aquifer with Ca–\({{\text{HCO}}}_{3}\) water type. The hydrochemical composition of this aquifer has changed over the years, influenced by factors such as the infiltration of salty seawater, cation exchanges, and agricultural activities. The results obtained from the scatter diagrams, PCA, saturation index, the modified Piper diagram, and HFE-D methods confirm the aforementioned findings.

Conclusions

The evolution of the hydrochemical facies governing the multilayered aquifer of GH.-J. coastal plain as a result of the Caspian sea saltwater intrusion and other saltwater sources were analyzed using combined methods. Based on this, the most important reasons for the salinity of aquifers and variations in its quality can be summarized as follows:

  • The results of PCA analysis shows that the primary factors of salinity in the unconfined aquifer are geogenic processes, hydrogeochemical exchange between the aquifer and the Caspian Sea as a result of seawater intrusion, and fossil saline waters trapped between sediments. The second influential factor, confirmed by the increase in \({{\text{NO}}}_{3}^{-}\) concentration, is the excessive development of agricultural lands, increasing the use of nitrogenous urea fertilizer, and the significant feeding of the aquifer by the resulting effluents. It should be noted that the increase in the Na/Cl ratio indicates the development of anthropogenic activities in creating aquifer pollution as a result of direct cation exchanges. Urban sewage and hydrogeochemical processes with natural origin have also been effective in this qualitative degradation of the aquifer. The analysis of the evolution of hydrochemical facies in the unconfined aquifer indicates that the establishment of the water supply network of Alborz Dam has significantly contributed to reducing the infiltration rate of saltwater from the sea and the underlying rock into the unconfined aquifer.

  • In the saline aquifer, the results from the HFE-D diagram indicate the predominance of the intrusion phase over the freshening due to insufficient freshwater recharge throughout the four investigated time periods. The important factor of the salinity of this aquifer is the direct effect of intrusion and reverse cation exchanges due to geogenic factors and hydrogeochemical processes governing the aquifer. Similar to the unconfined aquifer, the establishment of the Alborz water supply network has a positive impact on this aquifer, leading to a significant decrease in salinity and an improvement in the quality of groundwater. In the saline aquifer of GH.-J. plain, under the influence of surface water feeding, the type of water changed from Na–Cl and Mixed Ca–Mg–Cl in 2011 to Mixed Ca–Mg–Cl and freshwater in 2020.

  • In the northern parts of the plain and near the shores of the Caspian Sea, there is a perched aquifer of freshwater. Despite its proximity to the sea, the alluvial layer’s placement on the clay lenses has ensured the containment of freshwater throughout the years. The mixed groundwater composition, as assessed through the \({GQI}_{{\text{SWI}}}\) index and Piper diagram, displaying MixNa–MixCl and MixCa–Mix \({{\text{HCO}}}_{3}\)/Mix \({{\text{SO}}}_{4}\) composition, indicates that this aquifer is influenced by the simple mixing of fresh and salt water with little or no impact from cation exchanges. The trend of spatiotemporal changes of the hydrogeochemical facies of this aquifer is similar to the unconfined aquifer. This indicates the reinforcement of the freshwater front and the retreat of the saltwater front from the perched aquifer due to the infusion of freshwater from the Alborz network.

  • In the confined aquifer, saltwater and freshwater intrusions are seen. The first factor of this phenomenon is the geological processes due to the rising of fossil saline waters in the bedrock of this aquifer due to excessive exploitation of deep wells. The second reason is the reverse cation exchange process, human activities, and the use of nitrate-containing chemical fertilizers, which confirms the results of HFE-D. It should be noted that the intrusion phenomenon in this aquifer is not influenced by the sea, given its considerable distance from the coastline.

The findings showed that the simultaneous analysis of the results of statistical methods, the developed indicators in the modified Piper diagram, and the use of the HFE-D diagram is very effective in identifying the phenomenon of the interaction between salt and freshwater in coastal aquifers with marine or non-marine origin. The developed methodology can also unveil the reasons behind exchange processes and the concealed knowledge within them, shedding light on the factors causing changes in the spatiotemporal behavior of the hydrogeochemical facies governing the coastal aquifers. The obtained results can be considered as a foundation for developing both quantitative and qualitative policies for the operational management of coastal aquifers. These policies aim to remediate, protect, and efficiently manage groundwater resources, particularly in the coastal aquifers under the risk of saltwater intrusion.