1 Introduction

The annual estimated worldwide dye production is around 7 × 105 tons [1]. The dyeing process usually releases 15% of used dyes into the nearest aquatic system affecting water-dwelling flora and fauna [2,3,4]. Azo dyes are named on the account of their chemical configuration and containing countless (–N=N–) azo groups [5, 6]. Azo complexes are the most widely used colorants, particularly Congo red (CR) which is used in numerous trades such as textile, leather, plastic, foods industry, medical industry, paper, and printing [7, 8]. The CR interacts with water ecosystem, induces physicochemical (temperature, salinity and pH), and changes and disrupts various biological parameters [9]. The CR is difficult to separate from wastewater, due to its good solubility in water and degradation-resistant property [10, 11]. The discharge of dyes in the water environment causes severe problems for aquatic organisms and human health. It should be noted that dyes are toxic, carcinogenic, mutagenic, and allergenic [12,13,14]. Further, dyes with concentration levels lower than 1 mg L− 1 are easily observed and they can easily prevent several biological processes [15]. The color of textile effluents exacerbates this problem, mainly due to their biodegradable properties [16].

Consequently, it is necessary to eliminate the effluent containing dyes before mixing them with unpolluted natural water. Thus, the already developed physiochemical technologies like adsorption on activated carbon, oxidation, coagulation, precipitation, filtration, electrochemical, etc. [17] have been used to process taint water. But these processes are not reliable as they could not remove the color to an acceptable level. They also have high-cost investment, low selectivity, and difficulty in regeneration, making them unfit for the dye removal [18]. Adsorption has been advocated as a highly efficient process for the removal of inorganic and organic pollutants from wastewater based on its efficiency, simplicity, design flexibility, and cost-effectiveness [19, 20].

Agricultural solid wastes have gained tremendous interest for their potential to remove contaminants from aqueous solutions, their reuse as fertilizer, and their conversion to biofuel [21]. Using agricultural solid waste-based adsorbents, as an alternative, has several advantages, including low cost, high degradability, high regeneration ability, and porous structures and functional groups that lead to high adsorption activity [22, 23]. Furthermore, using these adsorbents for wastewater treatment is a long-term solution for lowering the accumulation of agricultural wastes [24]. Among these agricultural solid wastes, Argan nutshell (ArS) and Almond shell (AmS), are available and abundant in Morocco. The ArS and AmS were excellent potential adsorbents to remove dyes from wastewaters [25, 26] and were rapid to remove cationic dyes (10 min) compared to anionic dyes (60 min) following a second-order kinetic model [27, 28]. The ArS and AmS are porous structures (porosity over 85%) and have a density equal to (0.5‒1 kg L− 1) [26]. This shell type is recognized with its porous structure and its large surface, making the adsorption process feasible [27]. Over the recent decades, Argan nutshell and Almond shell have been used to adsorb various pollutants such as heavy metals [29], humic acid [30], and dyes [25].

The present work was carried out to investigate the desorption efficiency of Congo red from dye covered Argan nutshell (ArS) and Almond shell (AmS) adsorbents, by using sodium hydroxide (NaOH). Fourier Transform Infra-Red (FTIR) spectroscopy and Scanning Electron Microscopy (SEM) were used to identify the surface functional groups and the surface morphologies of the two adsorbents. Further, various parameters affecting the dye desorption process such as the CR-adsorbent dose, the contact time, and the NaOH concentration, were investigated. The kinetic desorption models (pseudo-first-order and pseudo-second-order) were also conducted. Firstly, the desorption of CR was optimized by the response surface methodology (RSM) integrated central composite design (CCD). Possible mechanisms of ArS and AmS adsorption and desorption of CR are then proposed based on the RSM-CCD results. Finally, the potential reusability of ArS and AmS adsorbents to remove the CR from wastewater were also evaluated.

2 Experimental

2.1 Chemicals

Congo red (CR), hydrochloric acid (HCl), and sodium hydroxide (NaOH) have been purchased from Sigma-Aldrich and have analytical quality. The water solubility of the used CR dye is 6.97 g L− 1.

2.2 ArS and AmS Preparation and Characterization

The Argan nut and Almond shells were washed with distilled water to remove surface impurities and dust particles. Then, the washed biomaterials were placed in an oven at 105 °C for 24 h, thereafter they were grinded on a laboratory mill Retsch SM10 and they were sieved to 50–100 μm on a laboratory sieve. In the final step, the sieved shells particles were placed in a 1% HCl solution for 24 h and then washed several times with distilled water to eliminate dust particles and other impurities trapped in the shell pores. The analysis of the biomaterials by FTIR spectroscopy (FTIR, Jasco 4100) was carried out in order to identify the different chemical functions of the molecules present on the shells surfaces. The surface textures of ArS and AmS were analyzed by scanning electron microscopy (SEM, SUPRA 40 VP). The point of zero charge (PZC) values of ArS and AmS have been determined as reported elsewhere by El Messaoudi et al. [9].

2.3 Adsorption Tests

To study the adsorption process, 0.8 g of ArS or AmS was first added to a 50 mL of CR solution at a concentration of 100 mg L–1 in an Erlenmeyer flask glass (250 mL). The solution pH was adjusted at 4 by using 0.1 M NaOH or HCl aqueous solutions. The mixture was agitated at 170 rpm at 23 ± 1 °C and pH = 4 for 60 min. Samples were taken at regular intervals to measure the absorbance of the supernatant solution using a visible UV spectrophotometer (2300/Techcomp), at wavelength (λmax = 498 nm) of Congo red maximum absorbance. Equation (1) was employed to determine the amounts of the CR adsorbed qe,a (mg g− 1) on the ArS or AmS. In addition, the adsorption efficiency of each adsorbent was calculated using Eq. (2).

$${q}_{e,a}=\frac{\left({C}_{0}-{C}_{e}\right)\times V}{W}$$
(1)
$$\% Adsorption=\frac{\left({C}_{0}-{C}_{e}\right)}{{C}_{0}}\times 100$$
(2)

where C0 (mg L− 1) refers to the initial concentration of CR, Ce (mg L− 1) is the concentration at the equilibrium of CR, V (L) is the solution volume, and W (g) is the amount of adsorbent.

Fig. 1
figure 1

FTIR spectra of ArS, CR-ArS (a) and AmS, CR-AmS (b)

2.4 Desorption Experiments

After test adsorption, the CR-loaded adsorbent was dried at 80 °C for 24 h. Then 0.8 g of the dried CR-loaded adsorbent was added to 50 mL of 0.1 M NaOH aqueous solution. The resulted mixture was stirred at 150 rpm at 23 ± 1 °C for 50 min. The filtrate from each sample was then collected and centrifuged for 5 min at 3000 rpm, and the clear supernatant was used to examine desorption efficiency by spectrophotometry. The amount of CR desorbed qe,d (mg g− 1) and CR desorption efficiency (%) were calculated using Eqs. (3) and (4), respectively:

$${q}_{e,d}=\frac{{C}_{d}\times V}{W}$$
(3)
$$\% Desoption=\frac{{q}_{e,d}}{{q}_{e,a}}\times 100$$
(4)

where Cd (mg L− 1) refers to the desorbed concentration of CR.

2.5 CR Desorption Analyzes by CCD and RSM Methods

In this study, contact time (X1), NaOH concentration (X2), and CR-adsorbent dose (X3), were considered as input variables, and CR desorption efficiency was regarded as the response variable. Design-Expert version 12.0.3 software and the CCD approach were employed to design the experiments and investigate the effect of input variables on response variables. RSM is a statistical method used to perform experiment analysis, modeling, and process optimization [31]. The ranges of the considered variables and the corresponding observed responses are summarized in Table 1. In RSM, the most complex model is the quadratic model, which includes the relationship between response and independent variables (‒α, ‒1, 0, 1, and + α). The quadratic model is expressed by Eq. (5) [32, 33]:

Table 1 The actual and coded values of independent variables
$$D\left(\%\right)= {\beta }_{0 }+\sum _{I = 1}^{k}{\beta }_{i }{X}_{i }+ \sum _{I = 1}^{k}{\beta }_{ii }{{{X}_{i }}^{2}}_{ }+\sum _{i < j}{\beta }_{ij }{X}_{i }{X}_{j } + \epsilon$$
(5)

where D (%) refers to the CR desorption efficiency.

3 Results and Discussion

3.1 FTIR and SEM Analyzes

To elucidate the interaction of functional groups of ArS and AmS with the CR dye molecules. FTIR analysis was carried out. The FTIR spectra of ArS, CR-ArS, AmS, and CR-AmS are shown in Fig. 1a,b, respectively. The broad bands at around 3332, 3345, 2924, and 2915 cm− 1 are assigned to a −O−H group [34, 35] and −C−H [36,37,38] stretching, respectively. The peaks at 1718 and 1630 cm− 1 for ArS and 1743 and 1626 cm− 1 for AmS represent stretching vibrations of –C=O of esters and acids [39, 40] and aromatic –C=C [41], respectively. The peaks at 1442, 1254, and 1020 cm− 1 for ArS and 1454, 1245, and 1021 cm− 1 for AmS are attributed to aliphatic –C–O–C, –C–O–H, –C–O stretching, respectively [42,43,44]. These results confirm the presence of ‒OH, C=O, and ‒C‒O functional groups [27, 28, 45]. After adsorption of CR (CR-ArS and CR-AmS), the band intensity of ‒O‒H, ‒C=O, and ‒C‒O stretching vibrations are considerably reduced along with a slight shifting of bands to lower frequencies, indicating an interaction between CR molecules and functional groups on ArS and AmS probably involving hydrogen bonding, which authenticates the adsorption process [46].

Fig. 2
figure 2

SEM images of ArS (a) and AmS (b)

Argan nutshells and Almond shells were analyzed by scanning electron microscopy to scrutinize their morphologies. Thus, SEM images of ArS and AmS are depicted in Fig. 2a, b and they show the surface texture of the biomaterials. It can be seen that ArS and AmS have heterogeneous surfaces, irregular forms, they are porous, and they contain micropores (50–100 μm). The nature of surface charge depends on the adsorbent PZC values, which are 5.2 and 5.7, respectively, for Argan nutshell Almond shell [27, 28].

Fig. 3
figure 3

Effect of CR-adsorbent dose on CR desorption (C(NaOH) = 0.5 M, T = 23 ± 1 °C, t = 120 min)

3.2 Desorption

3.2.1 Dye-Adsorbent Dose Effect

An important factor related to the desorption process is the dye-adsorbent dosage. In Fig. 3, when the following parameters are kept constant (NaOH concentration = 0.5 M, contact time = 120 min, temperature = 23 ± 1 °C), it is shown that by increasing the CR-adsorbent dosage from 4 to 16 g L− 1, the desorption of CR from CR-ArS and CR-AmS increased from 88.53% to 98.08% and from 87.61% to 98.43%, respectively. In fact, increasing the adsorbent dosage, in a specific volume of liquid, increases the number of available sites, improving the probability of repulsion between CR molecules dye and ArS and AmS [47]. However, we observe a decrease in CR desorption after a CR-adsorbent dosage of 16 g L− 1 due to the decrease in the active desorption sites on the adsorbent surface [48].

Fig. 4
figure 4

Effect of contact on CR desorption. (C(NaOH) = 0.1 M, T = 23 ± 1 °C, CR-adsorbent dose = 16 g L− 1)

3.2.2 Desorption Kinetics

According to the results illustrated in Fig. 4, it can be seen that increasing the contact time from 0 to 50 min leads to improving the CR desorption from the adsorbent. The possible reason for this improvement is the increased probability with contact time of the CR dye molecules repulsion from the adsorbent surface [9]. However, the decreased desorption efficiency was observed with further contact time. The lower CR desorption rate at higher contact times may result from the decrease of the desorption active sites, since they are available mainly at the beginning of the desorption process [11]. The desorption sites decrease with increasing contact time and lead to the reduction of the desorption efficiency [49].

Fig. 5
figure 5

Effect of NaOH concentration on CR desorption (t = 50 min, T = 23 ± 1 °C, CR-adsorbent = 16 g L− 1)

The pseudo-first-order and pseudo-second-order models are two well-known models for evaluating the desorption kinetics of CR from CR-ArS and CR-AmS. The Pseudo-first-order model is expressed by the following Eq. (6) and the pseudo-second-order model is given by the following Eq. (7) [19, 36, 50].

$${Log(q}_{e,d}-{q}_{t,d})={Log(q}_{e,d})-\frac{{K}_{1}}{2.303}t$$
(6)
$$\frac{t}{{q}_{t,d}}=\frac{1}{{K}_{2}{{ q}_{e,d}}^{2}}+\frac{1}{{q}_{e,d}}t$$
(7)

with qe,d (mg g− 1) is the quantity desorbed at equilibrium, qt,d (mg g− 1) is the quantity desorbed at time t (mg/g), t(min) is the contact time, K1 (min− 1) as constant for pseudo-first-order rate and K2 (g mg− 1 min− 1) refers to pseudo-second-order. The constants and parameters for kinetic models are presented in Table 2. From Table 2, the correlation coefficients show that the pseudo-second-order model is the one that best describes the desorption process of CR from ArS and AmS. In this case, correlation coefficients very close to 1 are obtained. The analysis of the kinetic data is in good agreement with those of the literature, which indicates that the desorption of CR was best fitted pseudo-second-order model [51].

Table 2 Constants and parameters of the kinetic models for CR desorption

3.2.3 Effect of NaOH Concentration

The variation of CR desorption efficiency based on the concentration of NaOH solution is shown in Fig. 5. According to the results, it can be found that increasing the NaOH concentration from 0.01 to 0.1 M leads to lower desorption efficiency of CR from CR-ArS and CR-AmS. Such behaviors may result from the fact that the adsorbent has a specific and limited number [52] of desorption sites which are more available at low NaOH concentrations, leading to increased values of the desorption efficiency [53]. Increasing the NaOH concentration leads to lower desorption sites [54]. Similar decreases in the desorption efficiency by increasing the NaOH concentration of NaOH, were also observed by others authors, Amran et al. [55]; Munagapati et al. [56], and Khanjani et al. [57].

Fig. 6
figure 6

Actual versus predicted responses (a), 3D surface response plots of CR desorption efficiency from CR-ArS: NaOH concentration with contact time (b), CR-adsorbent dose with contact time (c), and CR-adsorbent dose with NaOH concentration (d)

3.3 Optimization analysis of CR desorption

The predicated CR desorption efficiencies from CR-ArS and CR-AmS were obtained by the developed model given below, respectively:

$$\begin{aligned} D(\% ) &= 98.45 + 2.28{X_1} + 12.11{X_2} + 6.68{X_3}\\&\quad + 2.69{X_1}{X_2}-1.19{X_1}{X_3}{-}13.46{X_2}{X_3}\\&\quad -3.51{X_1}^2{-}9.58{X_2}^2{-}4.27{X_3}^2 \end{aligned}$$
(8)
$$\begin{aligned} D(\% ) &= 98.86 + 2.27{X_1} + 11.80{X_2} + 7.25{X_3}\\&\quad + 2.18{X_1}{X_2}{-}0.9225{X_1}{X_3}{-}12.45{X_2}{X_3}\\&\quad{-}2.83{X_1}^2{-}8.73{X_2}^2{-}4.83{X_3}^2 \end{aligned}$$
(9)

where D (%) is the CR desorption efficiency, X1 is the contact time, X2 is the NaOH concentration, X3 is the CR-adsorbent dose, X1X2 is the interaction between contact time and NaOH concentration, X1X3 is the interaction between contact time and CR-adsorbent dose, and X2X3 is the interaction between NaOH concentration and CR-adsorbent dose. The results obtained are presented in Table 3 for CR-ArS and in Table 4 for CR-AmS. The regression analysis showed that the effect of linear terms on CR desorption efficiency was from highest to lowest as X1, X2, and X3 [31]. In addition, the impact coefficients of interaction terms from highest to lowest were found to be X1X3, X2X3, and X1X2, respectively; their effect was negative, positive, and positive, respectively. The effect of quartic terms from highest to lowest was related to X32, X22, and X12, which have a positive, negative, and negative impact. According to the statistical analysis, some regression components, including X1X2, X32, X22, and X12 had a non-significant effect (p-value > 0.05), while the other components, especially X1, X2, and X3 had a significant impact (p-value < 0.05) [18]. Based on the obtained coefficients (obtained coefficient) and given the positive or negative effects of the independent variables, the final regression model related to CR-ArS and CR-AmS is presented in Tables 3 and 4, respectively. The values of adequate precision (> 4) and R2 (> 95%) obtained for the regression models indicated the high accuracy of the accepted models [31].

Table 3 CCD-RSM analysis for CR desorption from CR-ArS
Table 4 CCD-RSM analysis for CR desorption from CR-AmS

The predicted versus actual values and the mutual effects of the three experimental parameters (contact time, NaOH concentration, and CR-adsorbent dose) on CR desorption from CR-ArS and CR-AmS were analyzed using the 3D response surface, as presented in Figs. 6 and 7, respectively. The experimental values for the responses were in good agreement with the amounts predicted by the RSM model. The predicted values obtained were closer to the experimental values, as shown by the high R2-value [58, 59]. The desorption of CR was 98.45% for CR-ArS and 98.86% for CR-AmS obtained using CCD-RSM optimization. The minimum amount of the above parameters should be 13 g L− 1, 35 min, and 0.07 M for CR-ArS and 12.4 g L− 1, 32 min, and 0.06 M for CR-AmS Figs. 6 and 7 illustrate the dimensional response surfaces that show the effects of the significant variables (contact time, NaOH concentration, and CR-adsorbent dose).

Fig. 7
figure 7

Actual versus predicted responses (a), 3D surface response plots of CR desorption efficiency from CR-ArS: NaOH concentration with contact time (b), CR-adsorbent dose with contact time (c), and CR-adsorbent dose with NaOH concentration (d)

Fig. 8
figure 8

Interactions between CR and adsorbents at pH = 4

3.4 Adsorption and Desorption Mechanisms of CR

Based on the FTIR analysis of ArS and AmS, we proposed CR adsorption and desorption mechanisms from the surface of CR-ArS and CR-AmS (Fig. 8) at pH = 4. The binding between Congo red, and the OH, –COOH and SO3 surface groups of Argan nut and Almond shells, occurs mainly by attraction electrostatic, hydrogen bond, and Van der Waals bond. The following reaction illustrates the proposed mechanism [47, 60]. The desorption breaks these interactions between the CR molecules and the adsorbent surface upon the addition of NaOH.

Fig. 9
figure 9

Regeneration and reusability of ArS (a) and AmS (b): adsorption (adsorbent dose = 16 g L− 1, C0 = 100 mg L− 1, pH = 4, t = 30 min, T = 23 ± 1 °C) and desorption. (CR-adsorbent dose = 16 g L− 1, C(NaOH) = 0.1 M, t = 50 min, T = 23 ± 1 °C)

3.5 Recyclability of ArS and AmS

The adsorbent regeneration is necessary to make the sorption process economical and applicable at large scale [33, 49]. The assessment of the recycling efficiencies of ArS and AmS, for the CR molecules removal, upon the NaOH addition, at a concentration of 0.1 M, were carried out and the results are depicted in Fig. 9. Hence, after six cycles, The CR adsorption efficiency gradually decreased from 88.37 to 71.26% for ArS and from 85.06 to 69.71% for AmS. Similarly, other anionic dyes can also realize batch adsorption and desorption [61]. To locate our materials, we have grouped in Table 5 the regeneration and reusability of some adsorbents which were used to remove CR. As can be observed in Table 5, our bio adsorbents Argan and Almond shells are among the efficient adsorbents, proving that they are suitable for the CR molecules removal from wastewater.

Table 5 Comparison of regeneration of some adsorbents for the CR removal

4 Conclusions

The present investigation has provided an insight into the adsorption efficiency of the Argan nutshell and Almond shell, as exceptional bio sorbents, for Congo red removal from aqueous solutions. After the adsorption process, the desorption of CR from the dye-loaded adsorbents were studied. In addition, the desorption efficiency of the CR dye was monitored under the optimal conditions (CR-adsorbent dose, contact time, and NaOH concentration). To achieve CR desorption efficiencies over 98% by CR-ArS and CR-AmS, the minimum of the CR-adsorbent dose, the contact time and the NaOH concentration should be 16 g L− 1, 50 min, and 0.1 M, respectively. From the comparison of the experimental results to the desorption kinetic models, it was found that the CR desorption data were best fitted to the pseudo-second-order kinetic model. Hence, CR desorption efficiencies of 98.45% and 98.86% were obtained, respectively, for CR-ArS and CR-AmS, by using CCD-RSM optimization, and the minimum amount of the above parameters should be 13 g L− 1, 35 min, and 0.07 M for CR-ArS and 12.4 g L− 1, 32 min, and 0.06 M for CR-AmS. A reusability study in six cycles confirmed the efficacy of Argan nutshell and Almond shell to remove Congo red from aqueous solutions. The above results are advantageous for developing economically viable and eco-friendly techniques for the remediation of wide variety of pollutants.