Adsorption of Brilliant Green Dye onto a Mercerized Biosorbent: Kinetic, Thermodynamic, and Molecular Docking Studies

This study reports the valorization of pistachio shell agricultural waste, aiming to develop an eco-friendly and cost-effective biosorbent for cationic brilliant green (BG) dye adsorption from aqueous media. Pistachio shells were mercerized in an alkaline environment, resulting in the treated adsorbent (PSNaOH). The morphological and structural features of the adsorbent were analyzed using scanning electron microscopy, Fourier transform infrared spectroscopy, and polarized light microscopy. The pseudo-first-order (PFO) kinetic model best described the adsorption kinetics of the BG cationic dye onto PSNaOH biosorbents. In turn, the equilibrium data were best fitted to the Sips isotherm model. The maximum adsorption capacity decreased with temperature (from 52.42 mg/g at 300 K to 46.42 mg/g at 330 K). The isotherm parameters indicated improved affinity between the biosorbent surface and BG molecules at lower temperatures (300 K). The thermodynamic parameters estimated on the basis of the two approaches indicated a spontaneous (ΔG < 0) and exothermic (ΔH < 0) adsorption process. The design of experiments (DoE) and the response surface methodology (RSM) were employed to establish optimal conditions (sorbent dose (SD) = 4.0 g/L and initial concentration (C0) = 10.1 mg/L), yielding removal efficiency of 98.78%. Molecular docking simulations were performed to disclose the intermolecular interactions between the BG dye and lignocellulose-based adsorbent.


Introduction
The consequences of urbanization, rapid population growth, and the concomitant need for economic development have led to the significant pollution of natural waters. Therefore, the development of sustainable methods for water and wastewater treatment is imperative nowadays [1]. Along with the progress of the industrial sector, most naturalorigin dyes have been supplanted by synthetic dyes as a result of rising demands and prohibitive costs associated with extracting natural compounds [2]. Therefore, synthetic dyes are considered a worrisome polluting factor in wastewater, as they are widely used in various industries (e.g., textiles, pharmaceuticals, cosmetics, paper, plastic, paint, and leather) [2][3][4]. It is estimated that the textile industry alone utilizes more than 10 7 kg of dye per year worldwide, of which 10 6 kg is discharged into water streams [5]. As a consequence, synthetic dyes from wastewater have led to an increase in waterborne diseases worldwide, and implicitly in morbidity and mortality [6][7][8].
Cationic dyes are recognized to be more harmful than anionic dyes, possessing high tinctorial values (1 mg/L) [9]. Among these is brilliant green (BG), a triphenylmethane dye with widespread usage in human and veterinary medicine when used in low-concentration solutions (e.g., antiseptic, antifungal, and anthelmintic properties) [10,11]. Additionally, BG is extensively used as a coloring agent for textile materials and paper (approximately 1 kg/ton of paper), as well as in the rubber and plastic industries [12][13][14]. However, this dye is classified as highly toxic, causing harmful effects in humans when in contact with the skin and eyes, by inhalation, or by ingestion (the probable lethal dose is 50-500 mg/kg) [15,16]. It has been demonstrated that the toxic effect of BG dye found in green paper towels (which are frequently used in hospitals, factories, and other facilities) involves transdermal penetration of the skin, even during brief exposure intervals (30-300 s) [17]. Similar effects were obtained for the consumption of fish contaminated with this dye, due to its illicit use in aquaculture [17]. Despite being hazardous to aquatic organisms, BG is easily integrated into aquatic systems due to its high solubility (100 g/L) [15,18]. Moreover, its extreme volatility pollutes the atmosphere, and its decomposition products (sulfur and nitrogen oxides, as well as carbon dioxide) are damaging to the environment [13][14][15]18]. Thus, removing this dye from wastewater has become a major challenge.
In the last few decades, different treatment technologies have been performed in order to remove BG dye from aqueous media, such as biological [19] and oxidative [20] processes, electrocoagulation [21], sono-catalytic degradation [22], membrane separation [23], and adsorption [7]. Weighing the advantages and limitations of the mentioned methods, absorption on the solid surface of the dye is one of the most effective methods in terms of simplicity and low costs [10]. In addition, for the adsorption process of BG to become economically feasible, researchers have focused on biodegradable, renewable, sustainable, easily available, and low-cost adsorbents, such as guava seeds [5], banana peels [7], kaolin [10], bagasse fly ash [12], sawdust [13], rice straw [15], medlar nucleus [17], Saklıkent mud [18], cashew nut shell [24], or acorn-based [25] materials. The adsorption technique has also been shown to be remarkable in the removal of other dye pollutants from aqueous solutions [4,8,[26][27][28]. For example, environmentally friendly modifications to lignocellulosic materials such as walnut shells resulted in improved adsorption capabilities of two other cationic dyes with expanded medicinal applications (crystal violet and methylene blue) [26]. Furthermore, lignin-based magnetic biochar demonstrated significant Congo red removal efficiency in simulated wastewater [27], as well as excellent selective adsorption capability for methylene blue in binary, ternary, and quaternary dye systems [28]. However, for the treatment of contaminated waters, biosorbents derived from agricultural waste represent a valuable, affordable, and ecological alternative [29]. Pistachio (Pistacia vera L.) is considered one of the most valuable agricultural products from an economic standpoint in countries such as Iran, the US, Turkey, and Syria, which are responsible for almost 90% of the worldwide production [30,31]. The global demand for pistachio is increasing, mainly due to its beneficial impacts on human health (rich in nutrients and bioactive compounds) [32,33]. Considering their wide production and the shell/nut ratio of about 45%, large amounts of organic waste biomass are usually discharged by the processing industries to landfills (around 30 million tons/year) [8,31]. Furthermore, the chemical composition of pistachio shells, which contains abundant functional groups primarily provided by cellulose (40%), hemicellulose (25%), and lignin (16%) [8,34], can easily provide high added value and improved properties for dye adsorption processes.
The synthesis of sulfuric-acid-based activated carbon using pistachio shells was studied for methylene blue and brilliant green adsorption [35]. Due to its high adsorption capacity and increased surface area, activated carbon is one of the most widely utilized adsorbents; however, its high cost makes this technique uneconomical for commercial applications [10]. In this context, this study aimed to create a novel, simple, cost-effective, and environmentally friendly modified adsorbent based on pistachio shells for the removal of carcinogenic brilliant green from aqueous solutions. As far as we know, this is the first study to report the adsorption of brilliant green on a pistachio shell biosorbent obtained through simple grinding and mercerization processes. In addition to the characterization of the biosorbent from a physicochemical point of view, this study also reports the optimization of the separation process, as well as molecular docking simulations (to disclose the adsorption mechanism). Moreover, the thermodynamic parameters of adsorption were determined using two approaches: the classical one and the one based on the modified Langmuir isotherm proposed by Azizian et al. [36]. Both approaches take into account the saturation concentration of the investigated sorbate and lead to the same conclusions regarding the thermodynamics of the process.

Modification of Pistachio Shells by Mercerization (PS NaOH )
To provide a cost-effective and practical solution for removing harmful cationic brilliant green dye from wastewater, pistachio shell waste was employed. This material was chosen for two reasons. First, large amounts of biomass are commonly discarded as agrowaste, leading to significant environmental concerns [31]. Second, pistachio shells possess diverse functional groups, such as cellulose (hydroxyl) and lignin content (hydroxyl, carbonyl, metoxyl, and carboxyl [34]). These functional groups make surface modification possible, which in turn can enable the acquisition of new properties that are suitable for cationic dye absorption procedures [37].
The alkaline treatment of pistachio shells was selected to improve the adhesive properties of the surface, providing a rough topography as a result of the removal of natural and artificial impurities from the surfaces of the pistachio shells [38]. Furthermore, this method is commonly used to activate cellulose by immersing the lignocellulosic biomass in NaOH solutions with concentrations ranging from 5 to 7% [39]. In this study, a concentration of 5% (NaOH) was used to reduce the environmental impact; also, the mercerized pistachio shells (PS NaOH ) were carefully washed with water to eliminate the excess of NaOH. In contrast to other chemical agents, the use of NaOH as a surface modification agent also has benefits, including lower corrosion capacity, a lower environmental impact during its life cycle, and economic viability [40].

Characterization of PS NaOH Biosorbent
The surface morphological characteristics of the untreated and alkali-treated pistachio shells (PS and PS NaOH , respectively) were assessed through scanning electron microscopy (SEM), as shown in Figure 1a,b. A heterogeneous surface characteristic of lignocellulosic materials was visible in the untreated PS sample, as illustrated in Figure 1a. Along with the rough texture of the PS sample, the presence of irregularly shaped impurities was noticed. These have been assigned mainly to the crushing and grinding process of pistachio shells, given that similar outcomes were also observed for walnut shells subjected to this process [26]. By comparison with the raw PS sample, the SEM image of PS NaOH (Figure 1b) reveals the ability of the NaOH to remove the solid impurities from the biosorbent surface. Moreover, the alkali treatment of pistachio shells led to a smoother, wavy surface with the exposure of open pores, which are expected to increase the adsorption capacity of organic molecules.
FTIR spectroscopy was used to investigate the structural changes at the surface of the PS NaOH biosorbent induced by the alkali treatment. As depicted in Figure 1c, the PS NaOH biosorbent's spectrum was analyzed by comparison to the unmodified pistachio shell's (PS) spectrum. Due to their structural complexity, both spectra have been represented with breaks to highlight the two characteristic regions, namely the OH and CH stretching vibrations in the region of 3700-2700 cm −1 and the "fingerprint" region in the range of 1800-600 cm −1 . The corresponding assignments for the absorption bands are detailed in Table S1. In brief, the spectrum of raw PS shows distinctive absorption bands, which indicate the presence of cellulose, hemicellulose, and lignin components [40][41][42][43][44]. As a consequence of the alkaline treatment, a series of spectral changes for PS NaOH have been observed, as shown in Figure 1c. As expected, the partial dissolution of lignin and hemicellulose occurred, as proven by the reduction in intensity and shifting of characteristic bands (1744 cm −1 and 1235 cm −1 ). This can be explained by the cleavage of the aliphatic side chains in lignin and the breakage of the C-O-C bonds between the two monomers during hemicellulose hydrolysis in an alkaline solution [43]. Moreover, it was noted that the intensities of the peaks at 1421 cm −1 and 896 cm −1 had increased, indicating the higher content of cellulose in the treated samples. Similar findings were made when shea nut shells were alkali-treated [45]. Moreover, the increase in the intensities of the hydroxyl and carbonyl functionalities at the biosorbent surface (3343 cm −1 and 1030 cm −1 ) is expected to improve the adsorption capacity of the PS NaOH biosorbent.
Molecules 2023, 28, x FOR PEER REVIEW 4 of 22 range of 1800-600 cm −1 . The corresponding assignments for the absorption bands are detailed in Table S1. In brief, the spectrum of raw PS shows distinctive absorption bands, which indicate the presence of cellulose, hemicellulose, and lignin components [40][41][42][43][44]. As a consequence of the alkaline treatment, a series of spectral changes for PSNaOH have been observed, as shown in Figure 1c. As expected, the partial dissolution of lignin and hemicellulose occurred, as proven by the reduction in intensity and shifting of characteristic bands (1744 cm −1 and 1235 cm −1 ). This can be explained by the cleavage of the aliphatic side chains in lignin and the breakage of the C-O-C bonds between the two monomers during hemicellulose hydrolysis in an alkaline solution [43]. Moreover, it was noted that the intensities of the peaks at 1421 cm −1 and 896 cm −1 had increased, indicating the higher content of cellulose in the treated samples. Similar findings were made when shea nut shells were alkali-treated [45]. Moreover, the increase in the intensities of the hydroxyl and carbonyl functionalities at the biosorbent surface (3343 cm −1 and 1030 cm −1 ) is expected to improve the adsorption capacity of the PSNaOH biosorbent. The water vapor sorption capacity (W%) of the PS NaOH sample was slightly higher by comparison with the PS sample (as given in Table S2). In addition, the Brunauer-Emmett- Teller kinetic (BET) and the Barrett-Joyner-Halenda (BJF) models were applied to calculate the specific surface area, the weight of water forming a monolayer, and the average pore size, respectively (following a protocol described in a previous work [46]). As shown in Table S2, the alkali treatment of pistachio shells led to a specific surface area of 253.2 m 2 /g and 323.5 m 2 /g for PS NaOH and raw PS materials, respectively. However, one may say that the NaOH treatment of pistachio shells led to greater surface areas when compared with pistachio shells treated with H 2 O 2 and NaOH or with HCl and HClO 4 [40]. In addition, the average pore size was observed to increase after NaOH treatment from 1.210 nm to 1.563 nm (Table S2). Besides these outcomes, the alkaline treatment has the benefit of cleaning the pistachio shells' surfaces of contaminants, which qualifies PS NaOH for use in environmental applications.

. Adsorption Kinetics and Isotherms
Brilliant green (BG) cationic dye revealed three absorbance wavelengths (318, 426, and 624 nm, respectively), as highlighted by Figure S1a in the Supplementary Materials. To ensure the accuracy of the data, the adsorption investigations employed the band at 624 nm. Thus, the concentration of BG in the solution was measured based on the calibration curve depicted ( Figure S1b).
The BG adsorption kinetics onto the PS NaOH biosorbent were evaluated, taking into consideration the influence of the contact time t (min) upon the adsorption capacity q t (mg/g). Thus, Figure 2a shows an increase in adsorption capacity over time, corresponding to three stages [47]. The first stage is characterized by rapid adsorption (in the first 30 min), mainly due to the large number of available sites on the PS NaOH surface. With the depletion of active adsorption sites, the second stage begins and is represented by a slower adsorption process (between 30 and 120 min). The BG molecules try to diffuse into the pores and are gradually adsorbed by the inner pores until equilibrium is established (>120 min). The plateau zone at equilibrium is achieved in this final stage due to the saturation of the biosorbent's reactive groups with BG molecules. A similar trend was observed by others when investigating BG adsorption onto chemically modified areca nut husk [48] and raw soybean milk residues [49]. The isotherm experiments were carried out at two temperatures (300 and 330 K) and represent the adsorption capacity at equilibrium (qe, mg/g) as a function of the concentration of BG dye at equilibrium (Ce, mg/L), as illustrated in Figure 2b. As a result of the kinetic study (Figure 2a), the contact time was set at 240 min to ensure the adsorption equilibrium of the process. According to experimental isotherm data, the adsorption capacity at equilibrium (qe) decreased with temperature, changing from 52.42 mg/g (at 300 K) to 46.42 mg/g (at 330 K). This might be attributed to the higher kinetic energy of the BG To investigate the rate of adsorption and better understand the adsorption mechanism, pseudo-first-order (PFO), pseudo-second-order (PSO), intra-particle diffusion (ID), and  Table S3 (Supplementary Materials). Furthermore, the chisquared (χ 2 ) statistical test was used to determine the agreement between predicted and experimental data. Given the smallest value of χ 2 (Table S3) and the observations from Figure 2a, it is possible to conclude that the PFO model best describes the adsorption kinetics of BG onto the PS NaOH biosorbent. The theoretical equilibrium adsorption capacity (q e (calc) = 11.74 mg/g) estimated by the PFO model is closest to the experimental result (q e (obs) = 11.49 mg/g) (see Table S3 in Supplementary Materials). These findings suggest that the adsorption mechanism of BG onto the PS NaOH biosorbent is not predominantly based on diffusion (ID) [50].
The isotherm experiments were carried out at two temperatures (300 and 330 K) and represent the adsorption capacity at equilibrium (q e , mg/g) as a function of the concentration of BG dye at equilibrium (C e , mg/L), as illustrated in Figure 2b. As a result of the kinetic study (Figure 2a), the contact time was set at 240 min to ensure the adsorption equilibrium of the process. According to experimental isotherm data, the adsorption capacity at equilibrium (q e ) decreased with temperature, changing from 52.42 mg/g (at 300 K) to 46.42 mg/g (at 330 K). This might be attributed to the higher kinetic energy of the BG molecule when the temperature rises, which can reduce the electrostatic attraction and separate the solute from the biosorbent's surface [47]. These findings support the previously discussed kinetic results, corroborating that the increment in temperature does not cause the dye molecules to diffuse more inside the pores of the biosorbents. Other studies' outcomes revealed the opposite temperature dependency behavior [48,49]. However, the greater adsorption capacities of BG dye at moderate temperatures (closer to those found in the environment) may be advantageous when used in wastewater treatment applications.
To further explore the adsorption process of BG cationic dye on the PS NaOH biosorbent, the experimental data were interpolated by the Langmuir, Freundlich, Sips, and Temkin isotherm models, as plotted in Figure 2b. The non-linear equations of these models and the obtained isotherm parameters are detailed in Table S4 (Supplementary Materials). According to the calculated chi-square (χ 2 ) values (see Table S4), the Sips isotherm model provided the best accuracy of data interpolation. Given that the Sips model combines the Langmuir (homogenous monolayer adsorption) and Freundlich (heterogeneous multilayer adsorption) models [51], it can be inferred that the BG molecules were adsorbed on the PS NaOH surface in both manners, i.e., in homogeneous and heterogeneous layers.
In addition, the computed values of the R L separation factor (0 < R L < 1) and of the n F Freundlich isotherm constant (2 < n F < 10) support the assertion of a favorable adsorption process (see Table S4 in Supplementary Materials) [48]. However, the values for the constants of Langmuir (K L ), Freundlich (K F ), and Temkin (K T ), given in Table S4, are decreasing with increasing temperature, confirming the presence of a stronger interaction and improved affinity between the biosorbent surface and BG molecules at a lower temperature (of 300 K). To elucidate the adsorption mechanism (physical, ion exchange, or chemisorption [52]), the Dubinin-Radushkevich (D-R) model was applied, and the mean free energy (E S , kJ/mol) was calculated (Table S4). Given the values of E S ranging between 8 and 16 kJ/mol (~13 kJ/mol), it can be concluded that the adsorption process of BG cationic dye onto the PS biosorbent is mainly reliant on an ion-exchange mechanism between the surface acidic functional groups (e.g., −COO − ) of the adsorbent and positively charged nitrogen atoms from the brilliant green cationic dye.
The increased adsorption capacity of the PS NaOH biosorbent with increasing concentrations of BG cationic dye in the aqueous solution was evidenced by polarized light microscopy (PoLM). As a triphenylmethane dye, brilliant green ( Figure 3a) is known for its use as a fluorochrome in biological molecular labeling [53]. By comparison with the non-loaded (pristine) PS NaOH biosorbent (Figure 3b), we observed the uniform adsorption of the BG dye onto the surface of the biosorbent (Figure 3c,d) after performing the isotherm study. One aspect to be noted is that after submerging the biosorbent in low concentrations of BG solution (10 mg/L for 240 min), the dye's absorption was reduced, but light could still travel through the sample (Figure 3c). On the other hand, immersion in a concentrated solution with 500 mg/L of BG dye resulted in enhanced adsorption capacity (mg/g), which blocked the penetration of light (Figure 3d).
The increased adsorption capacity of the PSNaOH biosorbent with increasing concentrations of BG cationic dye in the aqueous solution was evidenced by polarized light microscopy (PoLM). As a triphenylmethane dye, brilliant green ( Figure 3a) is known for its use as a fluorochrome in biological molecular labeling [53]. By comparison with the non-loaded (pristine) PSNaOH biosorbent (Figure 3b), we observed the uniform adsorption of the BG dye onto the surface of the biosorbent (Figure 3c,d) after performing the isotherm study. One aspect to be noted is that after submerging the biosorbent in low concentrations of BG solution (10 mg/L for 240 min), the dye's absorption was reduced, but light could still travel through the sample (Figure 3c). On the other hand, immersion in a concentrated solution with 500 mg/L of BG dye resulted in enhanced adsorption capacity (mg/g), which blocked the penetration of light (Figure 3d).  In addition, a comparative literature review on the maximum adsorption capacities of brilliant green (BG) on different lignocellulosic materials was carried out. As shown in Table 1, higher adsorption capacities (80-250 mg/g) were obtained for activated-carbonderived materials from guava seeds [5], pistachio shells [35], and cashew nut shells [24]. However, in recent decades, researchers have concentrated on replacing expensive activated carbons with low-cost modified lignocellulosic materials. Thus, cost-effective modifications were approached (cleaning with distilled water, hot water treatment, NaOH, Na 2 CO 3 , or HCl treatment), yielding relevant adsorption capacities ranging from 18 to 59 mg/g [13,15,47,[54][55][56]. Among these, sawdust from Indian Eucalyptus wood treated with NaOH had the highest value of BG adsorption (58.48 mg/g), followed by the PS NaOH biosorbent employed in this investigation and similarly treated (54.74 mg/g). These findings support the use of PS NaOH for the efficient removal of BG from aqueous solutions.

Thermodynamic Parameters
Assessing the principal thermodynamic parameters (such as Gibbs free energy, enthalpy, and entropy) provides useful information regarding the energetic changes that occur during the adsorption [26,[57][58][59][60][61]. In order to ascertain these thermodynamic parameters, it is necessary to take into consideration the adsorption equilibrium constants at a minimum of two distinct levels of temperature (e.g., 300 and 330 K).
In this study, the adsorption equilibrium constant (K ad ) and consequently the thermodynamic parameters were estimated on the basis of two approaches. In the first approach, the adsorption equilibrium constant (K ad ) was approximated assuming the Langmuir equilibrium parameter K L , which was converted from the (L/mg) unit to the (L/mol) unit according to Equation (1) [26]: where M w (g/mol) is the molecular weight of the pollutant subjected to adsorption (i.e., BG dye). Afterward, the dimensionless adsorption equilibrium constant (K ad ) was estimated in conformity with Equation (2) [26,58]: where γ represents the activity coefficient ascertained on the basis of the ionic strength [36,58,60] and (C S ) [36]. For example, the water solubility of the brilliant green (BG) dye is about 100 g/L (0.2072 mol/L). Thus, in the first approach, we calculated the adsorption equilibrium constant (K ad ) by using Equation (2) and considering the saturated solution as the reference concentration (that is, C ref = C S , mol/L). Regarding the activity coefficient (γ), this was calculated by the Davis relationship [58].
In the second approach, the adsorption equilibrium constant (K ad ) was considered to be equal to the dimensionless equilibrium parameter K ML from the revised Langmuir isotherm model (i.e., K ad = K ML ). This revised Langmuir isotherm model was proposed and validated in 2018 by Azizian and co-workers [36], and the revised equation can be expressed as where q e (mg/g) is the adsorption capacity at equilibrium, q m (mg/g) is the model parameter representing the maximum adsorption capacity as a monolayer, C e (mg/L) is the concentration of the pollutant (or adsorbate) at equilibrium, C S (mg/L) is the solubility of the pollutant (or adsorbate) in water (a saturated solution) and K ML (dimensionless) is the modified Langmuir constant representing the ratio between the elementary rate constants of adsorption (k a ) and desorption (k d )-that is, The key difference between the modified Langmuir constant K LM and the classical Langmuir constant K L relies on the fact that K LM is a dimensionless quantity, whereas K L has specific units (L/mg) [36]. Therefore, the K LM constant can be directly employed in thermodynamic calculations, without additional mathematical transformations [36]. Thus, two approaches, (1) K ad = K L × C S × γ −1 and (2) K ad = K ML , were further used to assess the thermodynamic parameters. Consequently, the changes in the Gibbs free energy of adsorption (∆G) were computed as [26,36,58,60] where K ad is the equilibrium constant of adsorption (dimensionless), T is the absolute temperature (K), and R g is the universal gas constant (R g = 8.314 J/(K·mol)). The variation in the enthalpy (∆H) for the adsorption process was calculated by considering the isochore equation of Van't Hoff, which may be expressed by Equation (5) [60]: where T 1 and T 2 are two different values of temperature; consequently, K ad,T 1 and K ad,T 2 are adsorption equilibrium constants established for the corresponding temperatures. The modification of the entropy (∆S ad ) was assessed using the following thermodynamic equation [36,58,59]: The computed values of the thermodynamic parameters resulting from the two approaches are reported in Table 2. Both approaches revealed similar results, i.e., the calculated thermodynamic parameters by different methods were close in value ( Table 2). It should be mentioned herein that the calculations according to the second approach (K ad = K ML ) were faster since there was no need to compute the ionic strength and the activity coefficient separately. As summarized in Table 2, the negative values for the Gibbs free energy (∆G ad < 0) indicated that the studied adsorption processes were spontaneous (exergonic). Moreover, the ∆G ad values less than −20 kJ/mol might suggest the presence of the ion-exchange phenomenon [61]. The calculated values of the enthalpies were found to be negative (∆H ad < 0), indicating the exothermic nature of the studied adsorption processes. As reported in Table 2, the entropy change was positive (∆S ad > 0) for all cases, highlighting the increase in randomness (at the solid-liquid interface) that contributed to the spontaneity of the process. Table 2. Thermodynamic parameters for the adsorption of BG dye onto PS NaOH biosorbent; thermodynamic calculations performed via two approaches. The revised Langmuir isotherm model (given by Equation (3)) was used to interpolate the experimental data obtained in the isotherm study (Section 2.3.1) and the isotherm curves are evidenced in Figure S2, while the corresponding parameters are detailed in Table S5 in the Supplementary Materials. As a result, the theoretical values for the maximum adsorption capacity (q m , mg/g) obtained by this approach are very close to those obtained by the classical Langmuir approach. However, it should be mentioned that the revised Langmuir isotherm model provides better data interpolation (smaller chi-square (χ 2 ) values) for experiments conducted at low temperatures (e.g., 300 K).

Design of Experiments (DoE) for Data-Driven Modeling and Optimization
The effectiveness of an adsorption process in wastewater treatment is largely determined by the optimal conditions [62]. In this study, the synergetic effect of two key factors, influencing the adsorption performance, was explored to establish the optimal conditions, i.e., (1) sorbent dose (SD, g/L) and (2) initial pollutant concentration C 0 (mg/L). For adsorption process optimization, the design of experiments (DoE) and the response surface methodology (RSM) approach were adopted [63,64]. Brilliant green dye (BG) was employed as a target organic pollutant dissolved in the contaminant water, and the adsorption process was investigated in a systematic way. In this respect, a central composite design (CCD) of the rotatable type was applied for experimentation ( Table 3). As detailed in Table 3, the operating variables (factors) are reported in terms of actual values (SD and C 0 ) and coded values (x 1 and x 2 ). The experimental design listed in Table 3 involved 11 experimental runs. For each run, both factors (SD and C 0 ) were varied simultaneously, recording the process response (Y,%). The central runs (9-11) from CCD (Table 3) were carried out at the midpoints of factor intervals to assess the reproducibility of the experiment. Thus, the reproducibility test was conducted in triplicate, as reported for runs 9, 10, and 11 (Table 3), which were carried out in the center of the experimental region. According to the reproducibility assay (runs 9, 10, and 11), the average value for the removal efficiency was equal to 93.68 ± 0.47%, which corresponded to an adsorption capacity of 33.48 ± 0.18 mg/g. Hence, the reproducibility error was less than 0.55%.
Based on the numerical data given in Table 3 (experimental matrix), a mathematical model was built using the multiple regression method [63,64]. In this regard, the multiple regression computations were performed using the Design Expert (v.10) program. The developed model, with two variables, is of the polynomial type and contains the following terms: (1) main (linear) effects, (2) curvature (quadratic), and (3) pairwise (two-variable) interaction. The model can be expressed in terms of coded variables (x 1 and x 2 ) as follows: subjected to : −1.414 ≤ x j ≤ 1.414; (j = 1, 2) The resulting polynomial model (Equation (7)) was checked, regarding whether it was significant, by using the statistical test based on the analysis of variance (ANOVA) [63]. The main ANOVA statistical estimators are given in Table S6. As a result, the F-value of 26.51 and a small p-value of 0.0013 indicated a significant model from a statistical point of view. Consequently, the model can be used to navigate the design space through simulations. The value of the multiple correlation coefficient R 2 (0.963) disclosed that about 96% of the variability in the sum of squares could be explained by the factors under consideration. After applying the mathematical substitution technique, the final empirical model with natural factors can be written as follows: subjected to : 1.17 ≤ SD ≤ 6.83 (g/L); 8.6 ≤ C 0 ≤ 291.4 (mg/L) The estimations given by the data-driven model are shown in Figure 4. As highlighted in Figure 4a, there is reasonable agreement between the experimental data (actual response) and model estimations, since the data are scattered around the bisector (45 • straight line). Figure 4b reveals that the main effect of the initial concentration (C 0 ) factor is negative, while the main effect of the SD factor is positive with respect to the estimated response (Ŷ, %). In other words, the greater the C 0 factor, the lower the estimated response. In turn, as the sorbent dose factor (SD) increases, the estimated response becomes higher (Figure 4b). The quadratic effects of both factors induce curvature in the response surface. In addition, there is an interaction effect between factors SD and C 0 . In accordance with this two-factor interaction effect, the influence of the SD factor is more noticeable at higher values of the initial concentration of BG dye. Instead, the effect of the C 0 factor is more pronounced at smaller amounts of sorbent (Figure 4b).
Lastly, the constructed mathematical model was employed for process optimization. To this end, the numerical optimization was carried out by means of the direct search algorithm included in the Design Expert program. The model-based optimization results suggested the following optimal conditions: SD = 4.0 g/L and C 0 = 10.1 mg/L. For these optimal conditions, the computed response was equal toŶ = 104.98% (the predicted value), while the observed removal efficiency (recorded after 120 min of contact time) was Y = 98.78% (the actual value). The difference of about 6.20% represented the residual error between the model and the experiment. Note that the actual value of the response (98.78%) determined for the optimal conditions was the highest value compared to any value reported in Table 3.
straight line). Figure 4b reveals that the main effect of the initial concentration (C0) factor is negative, while the main effect of the SD factor is positive with respect to the estimated response ( , %). In other words, the greater the C0 factor, the lower the estimated response. In turn, as the sorbent dose factor (SD) increases, the estimated response becomes higher (Figure 4b). The quadratic effects of both factors induce curvature in the response surface. In addition, there is an interaction effect between factors SD and C0. In accordance with this two-factor interaction effect, the influence of the SD factor is more noticeable at higher values of the initial concentration of BG dye. Instead, the effect of the C0 factor is more pronounced at smaller amounts of sorbent (Figure 4b).
(a) (b) Lastly, the constructed mathematical model was employed for process optimization. To this end, the numerical optimization was carried out by means of the direct search algorithm included in the Design Expert program. The model-based optimization results suggested the following optimal conditions: SD = 4.0 g/L and C0 = 10.1 mg/L. For these optimal conditions, the computed response was equal to = 104.98% (the predicted value), while the observed removal efficiency (recorded after 120 min of contact time) was = 98.78% (the actual value). The difference of about 6.20% represented the residual error between the model and the experiment. Note that the actual value of the response (98.78%) determined for the optimal conditions was the highest value compared to any value reported in Table 3.
Following the determination of the optimal adsorption conditions for BG on the PSNaOH biosorbent, the influence of the pH on the removal efficiency of BG was evaluated. Lower removal efficiency values were found at more acidic or alkaline pH levels, as indicated in Figure S3 (Supplementary Materials), as compared to the maximum value corresponding to the natural pH ≈ 6 (used in all the experiments by dissolving BG powder in distilled water). Once the pH is lowered (towards pH 2), additional H + ions compete for the available adsorption sites (negatively charged) with the positively charged BG molecules, resulting in a decrease in dye removal efficiency [28]. By contrast, more adsorption sites (negatively charged) become accessible as the pH of the solution rises. These adsorption sites produce an electrostatic attraction with the cationic dye molecules, Following the determination of the optimal adsorption conditions for BG on the PS NaOH biosorbent, the influence of the pH on the removal efficiency of BG was evaluated. Lower removal efficiency values were found at more acidic or alkaline pH levels, as indicated in Figure S3 (Supplementary Materials), as compared to the maximum value corresponding to the natural pH ≈ 6 (used in all the experiments by dissolving BG powder in distilled water). Once the pH is lowered (towards pH 2), additional H + ions compete for the available adsorption sites (negatively charged) with the positively charged BG molecules, resulting in a decrease in dye removal efficiency [28]. By contrast, more adsorption sites (negatively charged) become accessible as the pH of the solution rises. These adsorption sites produce an electrostatic attraction with the cationic dye molecules, increasing the removal efficiency. Such a scenario was observed at pH 6, followed by decreasing removal efficiency for pH > 8, when the opposite effect (electrostatic repulsion) might occur [28,48]. However, it should be mentioned that PS NaOH exhibited excellent BG adsorption ability with removal efficiency higher than 90% in a wide pH range (4)(5)(6)(7)(8), similar to the wastewater pH range.
In addition, the influence of coexisting anions (Cl − , NO 2 − , and SO 4 2− ), cations (Na + , Ca 2+ , and Fe 2+ ), or organic matter (humic acid) on BG removal onto the PS NaOH biosorbent was assessed [27,28]. As depicted in Figure S4 in the Supplementary Materials, the addition of different salts led to a decrease in BG removal efficiency from 98.87% (in the absence of supplemental ions) to values in the range of 34.52-86.57% (in the presence of coexisting ions) and to 88.08% in the presence of humic acid ( Figure S4). However, PS NaOH demonstrated good removal efficiency of BG in the presence of different ions (except CaCl 2 ) and organic matter, highlighting its practical applicability in wastewater treatment.

Molecular Modeling and Docking
Molecular modeling is a pivotal tool for performing simulations at the atomistic level to explore conformational geometries and electronic structures, as well as to grasp intraand intermolecular interactions.
In the subsequent molecular modeling procedures, the BG molecule (cationic form) was considered the ligand for molecular docking computations. To this end, its optimized geometry (at the DFT level) was taken as the starting structure for these simulations. Likewise, for the molecular docking computations, we considered two receptors: (1) cellulose oligomer (cellotetraose) and (2) lignin. The outcomes of the molecular docking are illustrated in Figures 5 and 6 for the cellotetraose receptor and lignin receptor, respectively. In these figures, the best poses of the docked complexes are given, detailing the intermolecular interactions between the ligand (BG) and receptors. As shown in Figure 5, the hydrogen bonds (H-bonds) are present inside the cellotetraose receptor (intramolecular interactions) and are rendered as dotted yellow lines. The intermolecular interactions between cellotetraose and the BG molecule rely on hydrophobic contacts (highlighted in Figure 5 as solid green lines). These hydrophobic contacts can be correlated with the physical adsorption (on the basis of van-der-Waals forces) of BG dye onto cellulose. Computational results revealed for the docked complex cellotetraose-BG a binding energy (E b ) of −2.84 kcal/mol and a dissociation constant (K d ) equal to 8.27 mM. The large value of the dissociation constant (K d = 8.27 mM) suggests that the interaction between the ligand and cellotetraose receptor is not strong and that the dissociation of the docked complex is possible.  For the second case, the docked complex lignin-BG is illustrated in Figure 6. Compared to the previous complex (cellotetraose-BG), the interaction between the lignin receptor and BG ligand was stronger, disclosing lower values for the affinity parameters (i.e., E b = −4.59 kcal/mol and K d = 0.43 mM). Moreover, molecular docking results indicated that, for this case, beyond the hydrophobic contacts, π-π stacking interactions can emerge between the lignin and BG (rendered in Figure 6 as red lines). These types of interactions (π-π stacking) refer to the presumptive attractive, non-covalent interactions (orbital overlap) between the π bonds of aromatic rings. The π-π interactions might be associated with chemisorption. It should be mentioned that the simulations also revealed intramolecular H-bond formation in the conformation of the lignin receptor ( Figure 6).   In addition, the interaction energies between the ligand (BG) and receptors (cellotetraose and lignin) were calculated at the level of the YASARA force field in order to account for the contributions of the van-der-Waals and Coulomb forces. In this respect, the interaction energy (∆E) between the ligand and receptor (relying on the molecular force field) was calculated according to [66] where ∆E is the energy of interaction between the ligand and receptor, E COMPLEX denotes the potential energy of the docked complex, E RECEPTOR is the potential energy of the receptor, and E LIGAND is the potential energy of the ligand. Note that each term (from Equation (9)) includes both intramolecular and intermolecular contributions. The latter one involves two individual energy components for van-der-Waals (vdW) and Coulomb forces, which are responsible for distance-dependent attractive/repulsive interactions and electrostatic effects, respectively [66]. In general, the lower the interaction energy, the stronger the interaction between the ligand and receptor. Table 4 gives the energies of intermolecular interactions between the BG dye (ligand) and both receptors. As reported in Table 4, the interaction between BG and cellotetraose is based principally on vdW forces (∆E vdW = −9.00 kcal/mol). In turn, the electrostatic interactions for the cellotetraose-BG complex are minor (∆E CL = −0.97 kcal/mol). For the second case of lignin binding with BG, the major role is attributed to electrostatic interactions (∆E CL = −21.30 kcal/mol), whereas the vdW forces (∆E vdW = −8.21 kcal/mol) were of secondary importance. The docking results for the lignin-BG system were in good agreement with the D-R isotherm results that suggested a mechanism of adsorption based on ion exchange (i.e., electrostatic interactions). The overall intermolecular interaction energy (∆E = ∆E vdW + ∆E CL ) was lower for the lignin-BG complex ( Table 4), indicating that the ligand (BG dye) interacted more strongly with lignin compared to cellotetraose.

Materials
Brilliant green (BG) and sodium hydroxide ≥ 97.0% were purchased from Merck Chemical (Saint Louis, MO, USA). A stock experimental solution of BG cationic dye was prepared by using distilled water (concentration of 1 g/L). The pistachio shells (acquired from a local grocery store) were subjected to mechanical grinding using a Pulverisette 11 knife mill (Fritsch, Idar-Oberstein, Germany) after pre-washing with distilled water and drying at 378 K in a laboratory oven. Pistachio shells (PS) were further subjected to an alkaline treatment by being immersed in a 5% NaOH aqueous solution and magnetically stirred (150 rpm) for 48 h at room temperature. The final alkali-treated PS NaOH biosorbent was produced after the grains were filtered, thoroughly rinsed with bi-distilled water (to remove excess sodium hydroxide), and dried at 338 K for 24 h in an oven. Grains with sizes between 0.5 and 1.5 mm were obtained ( Figure S6 in the Supplementary Materials).

PS NaOH Biosorbent Characterization
The surface morphological properties of the alkali-treated biosorbent were examined using a Quanta 200 Scanning Electron Microscope (Brno, Czech Republic). A structural investigation was performed using a Bruker Vertex 70 Fourier Transform Infrared Spectrophotometer (Ettlingen, Germany) in the range of 4000-600 cm −1 in attenuated total reflectance mode (2 cm −1 resolution and 64 scans). Brilliant green adsorption onto the PS NaOH biosorbent was evidenced using a polarized optical microscope (Leica Microsystems, Wetzlar, Germany). The water vapor sorption capacities of the PS and PS NaOH samples were determined in the dynamic regime by using IGAsorp fully automated gravimetric equipment (Hiden Analytical, Warrington, UK).

Adsorption of Brilliant Green onto PS NaOH Biosorbent
Brilliant green adsorption onto the PS NaOH biosorbent was employed by using an orbital shaker incubator, the Biosan ES-20/60 (Riga, Latvia). A Hitachi U-3900 dual-beam UV-VIS spectrophotometer (Hitachinaka, Japan) was used to measure the dye content in the aqueous solutions, using previously determined calibration curves and the detection of adsorption bands (318, 426, and 624 nm), as depicted in Figure S1.
Kinetic experiments were carried out in batch mode to determine the adsorption capacity of the sorbent over time (T = 300 K). Thus, 0.2 g of PS NaOH biosorbent was introduced in 50 mL of 50 mg/L BG solution (orbital shaker, 180 rpm, 4 h). The dye concentration in the solution was determined by taking aliquots from the dye solutions at various predetermined contact times. The adsorption kinetics as a function of time were calculated according to Equation (9): where q t (mg/g) is the amount of dye absorbed at time t (min); C 0 and C t (mg/L) are the dye concentrations in the initial and final solutions (after contact time t), respectively; V (mL) is the volume of the immersion medium, and m (g) represents the weight of the PS NaOH biosorbent. The adsorption isotherms were measured at two different temperatures: 300 K and 330 K. As a result, for the same 0.2 g amount of biosorbent, the initial concentrations of the dye solutions ranged between 10 and 500 mg/L (contact time was set at 4 h, 180 rpm). The adsorption capacity at equilibrium (q e , mg/g) was calculated based on Equation (9) (by introducing the C e concentration at equilibrium instead of the C t concentration at time t).
The effect of coexisting anions (Cl − , NO 2 − , and SO 4 2− ) and cations (Na + , Ca 2+ , and Fe 2+ ) from different salt species was investigated in a 50 mL solution of 10 mg/L BG (with 200 mg/L of NaCl, CaCl 2 , NaNO 2 , or FeSO 4 salt content and a 4 g/L sorbent dose). Similarly, the effect of organic matter was evaluated using humic acid (20 mg/L).

Optimization of the Adsorption Process
The adsorption process' optimization was carried out by applying the design of experiments (DoE) and the response surface methodology (RSM) [63,64]. Brilliant green dye (BG) was used as a model organic pollutant and was dissolved in an aqueous medium. The experiments were done at a temperature of 300 K and at a naturally occurring pH of 6.0 ± 0.2. The adsorption performance was quantified via the color removal efficiency Y (response of the process), which was determined experimentally after a contact time of 120 min. The aim of the optimization was to maximize the color removal efficiency Y (%), which can be expressed as where C 0 denotes the initial concentration of the BG dye (organic pollutant), and C t is the residual concentration of the BG dye determined after a contact time of t = 120 min. For modeling purposes, the sorbent dose (SD, g/L) and initial pollutant concentration C 0 (mg/L) were investigated as the main factors and were transformed into coded (dimensionless) variables x 1 and x 2 . This conversion was carried out to compare the effects of the factors using the same dimensionless scale. The mathematical relationships adopted for the conversion of actual factors into coded variables have been detailed by others [63,64].

Molecular Modeling of Brilliant Green Cationic Dye
The initial 3D conformer of BG, in its cationic form (C 27 H 23 N 2 + ), was downloaded from the PubChem database [65] (PubChem CID 12449) and then subjected to molecular modeling at the level of density functional theory (DFT). The molecular modeling simulations were performed on a Dell Precision workstation T7910 with 32 CPU threads.
The quantum chemical calculations by the DFT method were carried out using the Gaussian16 software package [67]. The density functional with spherical atom dispersion terms APFD [68] was applied in this case by considering a split-valence (triple-zeta) basis set with polarization functions, i.e., APFD/6-311G(2d,p). The outcomes of DFT simulations were visualized and analyzed using the GaussView 6 program [69].

Molecular Docking
The molecular docking simulations were performed by using the AutoDock VINA algorithm [70] inbuilt into the YASARA-Structure program (v.20.8.23) for modeling and visualization [71,72]. The molecular conformation of the first receptor (cellulose oligomer) was optimized at the level of the YASARA force field, starting from the crystallographic data of cellotetraose already reported [73]. Regarding the reference structure of lignin (the second receptor), this was retrieved from the PubChem platform [34] (PubChem CID: 73555271), and then it was subjected to a minor modification by adding a moiety (-COO − ) in order to simulate the presence of one carboxylic group. Subsequently, the conformation (3D structure) of this second receptor was subjected to energy minimization (for geometry optimization) at the level of the YASARA force field. Molecular docking simulations were carried out in the YASARA-Structure program environment. In this regard, for each system, a total of 100 docking poses were assayed at the level of molecular mechanics theory using the YASARA force field. In the course of the molecular docking simulations, the ligand (BG molecule) was treated as a flexible body, while both receptors were treated as rigid bodies. The parameters for the modeled structures were generated automatically by means of the algorithm "AutoSMILES" included in the YASARA-Structure program.

Conclusions
Pistachio shells (lignocellulosic waste) were subjected to grinding and alkaline treatment to obtain an efficient, low-cost biosorbent (PS NaOH ). The morphological and structural modifications were explored via the SEM, FTIR, and PoLM characterization techniques. Brilliant green (BG) cationic dye was used in the adsorption experiments as a hazardous organic pollutant dissolved in water. The investigated adsorption process followed pseudofirst-order (PFO) kinetics. The experimental data on adsorption isotherms revealed a maximum adsorption capacity of 52.42 mg/g at 300 K. The Sips isotherm model provided the best accuracy of data interpolation. The values of the mean free energy of sorption (E S , resulting from the Dubinin-Raduschevich isotherm) were around 13.1 kJ/mol, indicating that the adsorption mechanism was mainly based on ion exchange.
Two approaches were applied to assess the adsorption equilibrium constant (K ad ) and, consequently, the thermodynamic parameters. Both methods revealed similar results regarding the values of thermodynamic parameters. For the approach relying on the revised Langmuir isotherm model, there is no need to compute the activity coefficient. The negative values for the Gibbs free energy (∆G ad < 0) and for the enthalpy (∆H ad < 0) indicated that the studied adsorption processes were spontaneous and exothermic.
The process optimization based on the response surface methodology (RSM) indicated the optimal conditions for the adsorption of BG onto the PS NaOH (i.e., SD = 4.0 g/L and C 0 = 10.1 mg/L). The experimental results confirmed that under the optimal conditions established, the effective removal efficiency was Y = 98.78%, which was the maximum value observed in this study.
The outcomes of the molecular docking computations revealed the possible intermolecular interactions between lignocellulosic receptors (cellulose oligomer or lignin) and the BG molecule. For the cellotetraose-BG docked complex, the interactions were based mainly on hydrophobic contacts (vdW forces). Instead, the lignin-BG docked complex was stabilized by hydrophobic contacts, π-π stacking, and electrostatic (Coulomb) interactions.