Exceptional preservation in Quaternary Atacama Desert Tufas: Evidence for increased groundwater and surface water in the Calama Basin, Atacama, Chile

Exceptionally well‐preserved tufas located west of Calama, Atacama Desert, Chile, designated Santa Juana tufas, record episodic wetter conditions, relative to today, over the past 500,000 years. Globally, tufa architecture and depositional details are poorly understood as most described tufas have been degraded by weathering and erosion. In the hyperarid Atacama, post‐depositional alteration is negligible, therefore, the exceptional preservation of Santa Juana tufas documented in this study provides new information about tufa facies and their complex interactions. Santa Juana facies include microbial stromatolites, phytoherms, cascadestone, flowstone and porous limestone. Phytoherms, consisting of former plant stems coated with calcite, developed in channels, within pools, and along spring discharge aprons. Cascadestone, representing former waterfalls, preserves microbial filaments and delicate V‐shaped calcite crystals. Flowstone lines shallow subvertical to subhorizontal channels, representing sites of rapidly sluicing water flow. Porous limestone, containing sparse calcite and/or gypsum and anhydrite cement crystals, represents detrital accumulations. Stable isotope results, coupled with U/Th ages, show that by the Quaternary, relative to the Neogene, groundwater was less supercharged with volcanogenic CO2 so degassing was moderated. The δ18O ratios from Miocene–Pliocene palustrine and lacustrine freshwater carbonates that underlie Santa Juana tufas indicate significant evaporation, but the tufa δ18O signal indicates a less evaporative trend due to shorter atmosphere exposure time. Biological fractionation in δ13C is largely masked by the region's volcanogenic carbon footprint, although tufa petrography shows well‐preserved microbial filaments and laminations. The range of tufa ages in this study shows that there were wetter time periods within the drainage basin headwater area in the Quaternary, but that by the late Pleistocene to early Holocene, aridity to hyperaridity became established. The lack of diagenesis or alteration within the Santa Juana tufas indicates that there has been minimal rainfall since their deposition.


| INTRODUCTION
The Atacama Desert is the driest place on earth, where extremely soluble salts, including nitrates and sulphate, derived from dry atmospheric deposition accumulate on the land surface (Jordan et al., 2020;Michalski et al., 2004;Pfeiffer et al., 2021). Yet only ca 8 Myr ago there were freshwater lakes and wetlands scattered across the region, and as recently as 1,000 years ago people were farming and exploiting riparian forest environments (Tully et al., 2019).
Non-marine limestones in the Calama Basin, a 12,900 km 2 basin located between the High Andes to the east and the Precordillera highlands to the west, provide a record of the past ca 10 Myr of climate change (de Wet et al., 2015(de Wet et al., , 2020Godfrey et al., 2021;Rech et al., 2002Rech et al., , 2010) ( Figure 1A). This paper documents a suite of previously undescribed Quaternary freshwater tufas from this arid environment and discusses their significance within the context of the region's recent past and potentially changing future climate.
In the western Calama Basin, Atacama Desert, Chile, ambient temperature freshwater limestones, known as tufas, are precipitating along two small, modern, flowing rivers ( Figure 1A). Where waterflow has ceased, Quaternary-aged fossil tufas form curtains over cliff faces and line dry gullies. These exceptionally well-preserved, Quaternary-age fossil tufas are informally named the Santa Juana tufas, adopting the name of an intersection south-west of Calama city (Tomlinson et al., 2018), as the field area has not yet been mapped in detail and the rocks do not yet have a formal stratigraphic designation.
This detailed study of fossil tufa enhances our understanding of aridity changes within the Calama Basin over the past ca 550,000 years, and provides insight into tufa complexes elsewhere that may not be as well preserved. Understanding aridity changes in the Calama region is important in light of rapid regional climate change today; for example, long considered the driest place on Earth, the Atacama centre typically receives <5 mm of precipitation per year (Houston, 2006;Jordan et al., 2020;Ritter et al., 2019), but over the past 7 years the region has experienced three significant rainfall events (Jordan et al., 2019(Jordan et al., , 2020Pfeiffer et al., 2021), and in 2019 parts of the Calama region were green with ephemeral vegetation due to unusual levels of precipitation. Azua-Bustos et al. (2018) show that a recent rainfall event had a deleterious effect on microbial life, which is adapted to Atacama hyperaridity, and flooding has caused infrastructure destruction and disruption to human activity (Barrett et al., 2016;Bozkurt et al., 2016;Wilcox et al., 2016). Therefore, increased understanding of past climate fluctuations in the Calama Basin (de Wet et al., 2020) is important in understanding potential consequences of future climate change.
This study uses Pedley's (1990) and Ford and Pedley's (1996) widely accepted tufa classification system, with the term tufa reflecting carbonate deposits forming from ambient temperature waters and travertine being reserved for calcareous deposits that form from warm to hot water (Pedley, 1990;Riding, 2000) (for an alternative perspective see Pentecost, 2005). According to Pedley (1990) and Pedley et al. (2003), tufas may be classified as fluvial, perched springline (slope), lacustrine, paludal and cascade. Fluvial and perched springline deposits represent end members with others forming a continuum in between; it is common for tufas to exhibit a blend of more than one type, as they modify their environment through ongoing deposition (Ford & Pedley, 1996;Pedley et al., 2003). For example, phytoherm deposition in a fluvial channel may form a dam where in situ carbonate-cemented plant material accumulates, thereby ponding water upstream, resulting in a wetland or lake, yielding paludal or lacustrine carbonate deposits (Pentecost, 2005). Barrages may also result from stromatolite development perpendicular to the flow direction where boundstone tufas impede water flow, facilitating phytoherm deposits in the lower-energy, upstream pooled water environment (Pedley, 1990). Cascade tufa, associated with waterfalls at topographic steps, is often paired with high rates of CO 2 degassing and inorganic calcite precipitation (Arp et al., 2001;Oste et al., 2021;Zhang et al., 2001). Flowstone is associated with a continuously flowing stream or rivulet of fast-flowing water where carbonate precipitates (Baker & Smart, 1995) and syndepositional carbonate precipitation may cement channel sediments or lithify tufa detrital aprons, producing porous wackestone, grainstone or rudstone deposits (Oste et al., 2021).
Tufas provide valuable palaeoclimate and palaeoenvironmental information as they record the wide range of physical and biological characteristics of the freshwater system from which they precipitate (Rogerson et al., 2010). They may serve as a proxy for rainfall and/or groundwater alteration within the Santa Juana tufas indicates that there has been minimal rainfall since their deposition. volume as they form in streams, or sites of spring discharge, and thus reflect precipitation locally or regionally within the recharge area (Pedley, 1990). Their fabrics may yield information about turbulent versus calm water conditions, for example, cascade or flowstone fabrics indicate rapid water flow whereas stromatolitic or oncoidrich tufas indicate less agitated depositional conditions . Stable carbon and oxygen isotopes can be used to track evaporation/precipitation budgets, often in closed lake basins, but are effective where evaporation rates are high, and they may help to determine the primary source of carbon and the extent of biomediation (Ashley et al., 2016;Martin-Bello et al., 2019). Tufa precipitation rates have the potential to record small scale temperature and/or salinity variations, given that precipitation rates may be positively correlated with temperature (Arenas et al., 2013;Capezzuoli et al., 2014) and salinity with evaporation, linking hydrologic budgets and temperature (Andrews & Brasier, 2005). Although diagenesis, weathering and erosion typically alter or degrade primary tufa fabrics (Pedley et al., 2003), the Santa Juana carbonates are essentially pristine due to the Atacama's hyperaridity, preserving their original depositional and geochemical characteristics.
This study draws on stratigraphic relationships, tufa morphologies, biological and geochemical characteristics and depositional environmental interpretations to provide new insight into palaeoclimate and palaeoenvironmental conditions in the western Calama Basin over the past 550,000 years. The Calama Basin was chosen as a study area because it has experienced rapid climate evolution, including intense aridification, over the past hundreds of thousands of years, and has well-preserved freshwater carbonate deposits across a broad time span, thus providing a record of humidity changes throughout the late Neogene-Quaternary (de Wet et al., 2015(de Wet et al., , 2020Godfrey et al., 2021;Jordan et al., 2022). This hyperarid region is thus optimal for studying climate-responsive freshwater carbonates since small shifts in humidity have significant implications for limestone deposition (de Wet et al., 2015(de Wet et al., , 2020.

| Location
The study area is located in the west branch of the Calama sedimentary basin (Jordan et al., 2015) ( Figure 1A,B,C). Calama Basin rocks are capped by the Upper Miocene-Pliocene Opache Formation, which formed in a shallow lake-wetland system (de Wet et al., 2015(de Wet et al., , 2020; locally fluvial and spring tufas, and fluvial terraces, overlie the Opache rocks ( Figure 2). Santa Juana tufas are the focus of this study. The city of Calama, located between the Andean volcanic arc to the east and the Precordillera mountains to the west, occurs where the basin changes orientation from approximately N-S to E-W (Jordan et al., 2015) ( Figure 1A). West of Calama city, the basin is drained through two major canyons which run parallel to one another only 5 km apart. Small rivers, the San Salvador and Loa, flow westward in the canyons. Between these parallel rivers there is an upland surface that dips gently to the west, which is covered in a network of braided and anastomosing gullies with no active water flow ( Figure 1B). After crossing the Precordillera Mountains, the San Salvador and Loa rivers join westward where the Calama Basin transitions into the Central Depression, situated between the Coastal Cordillera and the Precordillera ( Figure 1A).
In the early Pleistocene, 1.2-0.87 Ma, the Loa River breached the Coastal Cordillera mountains to reach the Pacific Ocean (Jordan et al., 2022;Vásquez et al., 2018). The ensuing incision led to draining of the Miocene-Pliocene shallow lake-wetland system of the Calama Basin (de Wet et al., 2020;Domínguez-Villar et al., 2012;May et al., 2005), as well as producing the present canyon topography.

| Climate
The Atacama region has been arid to hyperarid since at least the Miocene due to its location in a stable high pressure area, the strong rain shadow effect from the Andes F I G U R E 2 Regional chronostratigraphic framework for Oligocene to Holocene deposits. The tufas in this study are informally referred to as Santa Juana deposits, but do not have formal formation status.
Mountains to the east, and the cold Humboldt Current offshore of the Pacific coast which inhibits moisture migration inland (Quade et al., 2017;Ritter et al., 2019). The opening of the Drake Passage ca 50 Ma initiated a shift in global ocean circulation and established the Peru-Chile Current system, setting up the region's longlived hyperaridity (Diederich et al., 2020). Pacific-derived moisture is trapped below 1,000 m elevation due to a sustained atmospheric inversion layer and coastal mountain range (Diederich et al., 2020;Houston, 2006), at 2,300 m elevation, the Calama Basin lies above the threshold for this moisture, contributing to the basin's aridity. High evaporation rates in the Atacama Desert amplify the environmental consequences of the low rainfall (Diederich et al., 2020).
Hyperaridity from the Miocene to the present was punctuated by pluvial periods of increased humidity that have been recognised in the region, with multiple such periods documented in Jordan et al. (2014), Evenstar et al. (2017), Ritter et al. (2018) and Godfrey et al. (2021). Diederich et al. (2020) note that in the northern Atacama, orbital-scale and millennial-scale precipitation changes occurred over the past 68 kyr, with wetter periods between 61 ka and 68 ka, several short, wet periods from 33.6 to 58 ka and from 16.4 to 28.5 ka, with the driest period from 8 ka to the present. Previous studies in the eastern Atacama area show that this area was arid for most of the Miocene-Pliocene but as shown in de Wet et al.'s (2020) study, wetter episodes alternated with very arid periods, reflecting short-term climate fluctuations that may mirror Quaternary and ongoing climate changes. This study and ongoing research contribute to filling a gap in knowledge of Mid-Pleistocene climate for the central Atacama, with proxy data that document previously unrecognised regional wetter periods.

| Hydrology
All rivers in the Loa River catchment are small by global standards. The Loa River, and its tributary the Salado, are fed by drainage from the High Andes plus extensive contact with several aquifers (Godfrey et al., 2021;Houston, 2006;Jordan et al., 2015). West of Calama city, the Loa River flows along the southern side of the study area. The San Salvador River, sourced from a spring located just north-west of Calama, flows along the northern side of the study area. The hydrology is spatially decoupled from the regional climate zones. Whereas the lowlands of the Calama Basin are hyperarid (<5 mm/year precipitation), the surface water and groundwater budgets are controlled by the climate of the mountain headwaters region, where climate is less arid (90-200 mm/ year precipitation) (Diederich et al., 2020;Houston & Hartley, 2003).
Assessment of how the Calama Basin hydrological system will respond to climate change in the near and more distant future is made difficult by dramatic human alteration of stream flow and spring discharges during the 20th and 21st centuries. A natural baseline against which to evaluate change is lacking. During the 20th century, most of the water of the Loa River and its tributaries was diverted into mining projects and to supply water for distant communities, as was groundwater that naturally fed the Loa (reviewed by Jordan et al., 2015). In the early 20th century, the Loa River, below its junction with the San Salvador River, west of the study area, carried about 2,200 L/s during low-flow season, but near the end of the century it carried only 690 L/s (Jordan et al., 2015). Impacts are evident not only in the Loa River itself, but also at springs near Calama city. For example, in the mid-20th century, a small hydroelectric power plant was installed to exploit the water flow from major springs at Ojo Opache (Maino & Recabarren, 2011), a focus area for this study, and today only a trickle discharges at the spring. Likewise, an indigenous irrigated agricultural area on the west side of Calama was traditionally very productive, but today the Loa River carries so little water that many of those farms have been abandoned.

| Field work
One hundred nineteen fossil tufa samples were georeferenced and collected from: (1) numerous locations along an 11 km long stretch of a large, dry gully between the modern Loa and San Salvador rivers, here referred to as Major Middle Gully (MMG), (2) a site near the San Salvador River, the Ojo Opache tufa complex, (3) the western reaches of the basin and (4) locations adjacent the Loa River ( Figure 1A). Detailed measured sections were made of representative tufa successions in MMG and the Ojo Opache location (Figures 1B,C and 3A,B); they are the focus of this paper, and the geochemical analyses and age dates presented here are from these successions; other locations are addressed in a forthcoming paper. Preliminary tufa morphology designations were made in the field based on all of the field sites, and subsequently substantiated through petrography. Five mappable tufa morphologies were recognised: (1) stromatolite boundstone, with laminated mound to flat lying and pencil-like morphologies; (2) encrusted stem phytoherms; (3) rough textured carbonate in curtain-like macroforms, referred to as cascadestone; (4) smooth textured flowstone; and (5) porous limestone.

| Microscopy and imaging
Thin sections (n = 75) were stained with potassium ferricyanide and Alizarin Red-S (Dickson, 1966). Photomicrographs were taken using a Leica DM EP microscope and ProgRes CF Jenoptik camera system. Microbial filament lengths and diameters were measured taking 30 replicates per thin section with the ProgRes CapturePro 2.8.8 Jenoptik software. Fossil microbe identifications were made by comparison with modern and ancient examples in the literature (Freytet & Verrechia, 1998;Gradziński, 2010).

| Diatom identification
Samples for which thin sections revealed large diatom populations were selected for diatom concentration and identification. Samples were twice-dissolved in an acid bath of 10% HCl for 24 h, rinsed with deionised water after each dissolution step, and filtered. Siliceous residue was hand-picked under a microscope, gold coated and imaged. Processed samples were permanently mounted to slides using NaphraxTM. Using a Zeiss Axioskop, a minimum of 300 diatom valves were counted at 1,000X magnification. Diatoms were identified to species level using regional and cosmopolitan floras. For statistical analysis, diatom counts were transformed to relative abundances (%) to analyse differences in the dominant species between samples. Diatom species found in <3% F I G U R E 3 (A) Field photograph of part of MMG showing where detailed stratigraphic sections 1-3 were measured. The brown highlighted colour denotes Santa Juana tufa deposits. Note the road in the upper left corner, this is the same location in Figure 1B where the road crosses the MMG gully. Blue arrows indicate palaeowater flow direction. The vertical height of section 1 is 4.8 m. (B) Field photograph of the Ojo Opache location showing the Santa Juana tufa complex overlying layered Miocene-Pliocene Opache Formation palustrine limestone. The brown highlighted colour and dashed orange line denotes Santa Juana tufa deposits. Orange arrows indicate the direction of past water flow over the cliff and down the tufa valley slope. The escarpment is 10 m high and the valley extends for 320 m. This escarpment is the bright line within the tufa complex close to its southern margin seen on Figure 1C (on Figure 1C, 4th blue arrow from right is pointing at the bright line of the escarpment). A B | 681 de WET et al. abundance were required to occur in at least two samples to be included in the analysis. Diatom relative abundances were subsequently Hellinger transformed to stabilise their variances (Legendre & Gallagher, 2001). A principal components analysis (PCA) was run to visualise patterns in diatom communities between tufa facies. Results are in Table 1.

| Mineralogical, elemental and isotopic analytical methods
Twenty-five tufa samples from the measured sections were powdered for X-ray diffraction (XRD) analysis to determine the polymorph(s) of calcium carbonate present and verify the presence of evaporites, such as gypsum and anhydrite, noted petrographically. Twenty microsamples representing each carbonate lithology were obtained using a Dremel Microdrill 285 at low rpm. Each sample was drilled under a magnifying glass to avoid visibly different constituents. Samples were run at Franklin and Marshall College on a PANalytical X'pert Pro PW3040 XRD spectrometer using Cu K Alpha radiation, an automated diffraction slit and a X'Celerator detector, according to standard procedures (scans from 6 to 70 o 2θ with a NIST traceable Si metal used to check goniometer accuracy). Results are in Table 2.
Thirty-four samples (some field samples have multiple geochemical samples, Table 2), representative of the range of tufa morphologies and referenced to the appropriate thin section, were drilled using a Dremel Multipro 285 microdrill at low speed to obtain 0.05 g for inductively coupled plasma (ICP) analysis of calcite trace elements (Mn, Fe, Mg and Sr). Samples were drilled under a magnifying glass to avoid siliciclastic contamination, dissolved in 10% HNO 3 and analysed at Franklin and Marshall College on a SPECTROBLUE ICP-optical emission spectrometer (ICP-OES), with 750 mm focal length, a Paschen-Runge optical system, and 15 linear charge coupled device array detectors. Calibrations were made to seven standards, diluted to appropriate concentrations, from Specpure commercial stock solutions referenced to known standards. The ICP-OES was calibrated before each run with a tuning solution to account for instrumental drift. Standard curves with 5+ points were compiled for each element with correlation coefficients >0.998. Standards JLs-1 and JDo-1 were run at the beginning and end of the run and were within <5% relative standard deviation (RSD) error of established values. Duplicate samples were within <1% RSD. Results are reported in parts per million (ppm).
Twenty-nine micro-drilled samples were analysed for stable carbon and oxygen isotopes (some field samples had multiple isotope analyses, Table 2). Isotope compositions were measured using a multi-prep device coupled to an Optima dual inlet mass spectrometer at Rutgers University. The CaCO 3 was reacted in 100% phosphoric acid at 90°C for 800 s. Values are reported in per mil (‰) relative to the Vienna Pee Dee Belemnite (V-PDB) standard (Table 2). Long term standard deviations on the internal laboratory standard are 0.05‰ and 0.08‰ for δ 13 C and δ 18 O respectively.
Fifteen samples were dated using 230 Th −234 U −238 U at Rutgers University. Samples were either micro-drilled or lightly crushed and handpicked. Selection favoured carbonate that was largely free of visible detrital material to avoid, as much as possible, any addition of U that can result in spuriously old or young ages respectively (Livnat & Kronfeld, 1985). The samples were dissolved in 7 M HNO 3 and centrifuged to remove insoluble material before a 233 U-229 Th spike and Fe(III) were added. The sample and spike equilibrated over at least 48 h on a hotplate and then dried with additions of H 2 O 2 to oxidise organic material. The samples were redissolved in 7 M HNO 3 and the pH adjusted with NH 4 OH to exceed 8, forming an Fe precipitate which coprecipitated U and Th from solution. The precipitate was separated by centrifugation, twice washed with water and dissolved in 7 M HNO 3 . Uranium and Th were individually isolated by ion chromatography (Mortlock et al., 2005). Results are in Tables 2 and 3. All reagents were ultrapure (BDH Aristar ultra) and concentrations adjusted with milli-Q water with added Element pod. Uranium and Th were analysed using a ThermoScientific Neptune Plus MC-ICPMS with standards U010 and CRM 129 for U, and SGS for Th (Mondal et al., 2018). Dates were calculated following the methodology outlined in Ludwig and Paces (2002), which subtracts detrital Th and U, assumes all 232 Th is detrital, that detrital material has a 232 Th/ 238 U atomic crustal ratio of 3.8, and is in secular equilibrium. Results were generated using Isoplot 2.49 (Ludwig, 2001).
Twenty-three samples were used to acquire dates for this selection of Santa Juana tufa by U-Th dating. The ages range from 2.2 ka to more than 550 ka, the point where the U-Th decay system becomes imprecise (Claes et al., 2020;Ludwig & Paces, 2002). The lack of diagenesis, confirmed by petrography, and the region's extreme aridity, that is, lack of rainwater, prevents leaching or addition of U, thus providing confidence in the reliability of age estimates. Detrital material, estimated from 232 Th/ 238 U AR ratios, is between 0.003 and 0.094, but most have ratios close to 0.028. The 234 U/ 238 U AR ratios range between 1.11 and 2.46, but notably it is only samples from Ojo Opache that have 234 U/ 238 U AR ratios greater than 1.90. There is no correlation between 232 Th/ 238 U AR ratios and calculated age. Results are in Tables 2 and 3.  Finely laminated stromatolite boundstone occurs as flat lying to wavy bedded, to mounded structures, up to 0.5 m high ( Figure 4A,B). Flat lying to wavy bedded boundstones may extend laterally for up to a metre on gully floors or as discrete horizons in gully sidewall deposits. Centimetre-scale mounded forms occur on gully floors, often perpendicular to the sidewalls as barrages. Elongate, vertically oriented, laminated boundstones, with a pencil-like erect, straight-sided shape form beds composed of single columns, or multiple stacks of columns ( Figure 4C). Individual columns range from 3 to 75 cm in height with diameters of ca 1 cm ( Figure 4D).

| Encrusted plant stems as phytoherms
Fossil phytoherms are composed of calcite-encrusted in situ and detrital former plant stems, forming 0.5 to 8 m high deposits. Phytoherm masses may be within gullies, where they typically align in a downstream orientation, ( Figure 6A) or adjacent to the gully walls, where broken stems have a random orientation, ( Figure 6B) producing deposits <0.5 to 2 m long. Stem encrustation diameters are bimodal; small stem tubules consist of <5 mm to ca 1 cm diameter moulds ( Figure 6B) and large tubules have an average diameter sp. and Mastogloia species (so in general higher amounts of unattached moderately to highly motile species of benthic habitat). Group 2 is similar to group 1, but has a distinctly lower amount of D. thermalis, higher abundances of smaller D. subtilis, Nitzschia species and Encyonopsis, a larger contribution of small fragilarioid taxa (so in general we see a switch towards prostrate or attached forms and increases in tychoplankton). Group 3 was more diverse than the other two groups, and is dominated by C. placentula, Planothidium species, small fragilarioid taxa, Navicula and Nitschia species. Aside from Navicula, a majority of the species live prostrate (attached) and are only slightly to moderately motile. of 5.5 cm ( Figure 6C). Carbonate crust thickness is highly variable, ranging from 5 mm to 11 cm diameter around the central cavity. Stem moulds are generally unfilled, yielding high intraparticle porosity, but may have micrite +/− detrital sands and silts, diatoms, gastropod shell fragments or ostracods inside ( Figure 6D). Petrographically, the calcite encrustations consist of concentric layers of light and dark microstromatolitic or micritic laminations ( Figure 6E), rich in filaments and/or clotted fabrics. Filaments average 5 μm in diameter, with an average length of 0.15 mm.

| Cascadestone
Fossil waterfall deposits, or tufa cascadestone, are composed of millimetre to centimetre-scale interlocking, triangular calcite clusters that coalesce to form curtains that drape over gully walls or in gully channels where there is a substantial change in elevation ( Figure 7A). Cascadestone has a rough surface texture characterised by overlapping V-shaped calcite crystal bundles that point in a downflow direction ( Figure 7B). The clusters have a rough texture due to millimetre-scale microrelief over a network of micron to millimetre-scale (average 24 μm in diameter and 0.3 mm in length) calcite-encrusted algal or cyanobacterial filaments ( Figure 7C). Filaments tend to be aligned in one direction and may be flattened into a semi-circular cross-section with high porosity between them ( Figure 7D). Cascadestone is poorly lithified and friable, with thin sparry calcite rims around filaments. Small gaps between filaments may contain angular to subangular detrital silt and sand grains, diatoms and micrite.

| Flowstone
Flowstone occurs in small sinuous channels within larger fossil tufa deposits. It is most prominent as gully sidewall deposits where it forms a 1-10 cm thick veneer over previously deposited tufa or the Opache Formation carbonate rock ( Figure 8A). The veneer is a smooth surface that coats cobbles, fills in cracks and crevices, and may produce small terracettes. Petrographically, dense, evenly laminated microcrystalline calcite is interlayered with microstromatolitic laminations, and dark, dense coatings alternate between millimetre-thick calcite crystal arrays ( Figure 8B). Silt to fine sand-sized detrital grains, ostracod and diatom fossils occur within small depressions or are adhered to laminations.

| Porous limestone
Coarse-grained, poorly cemented, porous, sand, gravel and rudstone Santa Juana deposits occur in patches on the present land surface or, in gullies, as lenses in other Santa Juana facies. On the present land surface it forms a centimetre-thick blanket of poorly cemented, porous sand and gravel, rich in Opache Formation clasts and tufa intraclasts, directly on top of the Opache Formation ( Figure 9A). Within gullies, carbonate-dominated sand, silt and gravel accumulations occur between other tufa lithologies, particularly in low areas or behind barriers. Petrographically, these limestones contain silt and sandsized, angular to subangular detrital mineral grains, igneous rock fragments, Opache Formation clasts, tufa intraclasts, oncoids, micritised intraclasts and/or ostracod or gastropod shell fragments. Dogtooth to equant calcite spar forms isopachous cements ( Figure 9B), and gypsum or anhydrite partially occludes primary porosity in some intergranular pores ( Figure 9C). Gypsum and anhydrite are the only post-depositional diagenetic features.

| Diatom assemblages
Three different diatom communities were identified from the PCA ( Figure 10A,B,C). The first principal components explained a total variance of 63.73% (PCA1 = 51.84%, PCA2 = 11.89%). On the PCA1 axis, higher scores are associated with species typical of cool, freshwater, mineralpoor environments and prostrate to weakly mobile life-habits; negative scores are associated with species typical of warm, mineral-rich waters and unattached highly mobile-life habits. Separation of sites along the PC2 axis may reflect habitat; more negative scores are associated with species capable of growing aerophytically. Based on the PCA scores, three groups are designated. Group 1 contains higher relative abundances (%) of Achanthes thermalis var. rumrichorum (mean = 19%), Amphora atacamae (mean = 3%), Brachysira atacamae (mean = 16%), Denticula thermalis (mean = 24%), Frustulia

| Geochemistry
The XRD results show that Santa Juana tufas are composed of calcite, with minor Mg-rich calcite. Gypsum and anhydrite are present but are less abundant.
Aragonite was not detected (

| δ 13 C and δ 18 O stable isotopes
Collectively, O and C stable isotopes range from −8.8 to −1.44‰ and −3.8 to +6.4‰, respectively ( Figure 11A,B). Based upon average compositions, there is no distinction in the isotope compositions among different facies, but phytoherms and stromatolites tend to have more enriched δ 18 O, whereas flowstone, and possibly cascadestone, are the least enriched. Positive correlations are observed between δ 13 C and δ 18 O for stromatolites and flowstone (excluding CH 98-19 which has very high δ 13 C), but phytoherms do not show correlation, due to their nearly invariant δ 13 C.

| Age dating
Twenty-three samples were used to acquire dates for this selection of Santa Juana tufa by U-Th. The ages range from 2.2 ka to more than 550 ka, the age beyond which the U-Th decay system becomes imprecise (Claes et al., 2020;Ludwig & Paces, 2002). The lack of diagenesis, confirmed by petrography, and the region's extreme aridity, that is, lack of rainwater, prevents leaching or addition of U, thus providing confidence in the reliability of the age estimates. Detrital material, estimated from 232 Th/ 238 U AR ratios, is    Arenas et al., 2019;Camuera et al., 2015;Freytet & Plet, 1996;Oste et al., 2021). The presence of ostracod and diatom fossils adhering to Santa Juana stromatolite filaments indicates that the stromatolites grew subaqueously, hosting a thriving biota, implying oxic conditions within the photic zone. The presence of gastropod shells suggest that the stromatolites were grazed by snails, as occurs in modern South American rivers (Bórquez & Brante, 2017;Ovando & Gregoric, 2012). The Loa, San Salvador and other nearby rivers have stromatolite-like hemispheres forming low barrages that result in a series of stepped pools a few metres downstream from each other ( Figure 12A,B). Similarly, Santa Juana mounded stromatolites occur where field evidence indicates the former presence of pools, with fossil stromatolites forming pool barriers, analogous to barrages in the modern local rivers, and are thus interpreted as barrage stromatolites. Flat-lying Santa Juana boundstones are analogous to algal/cyanobacterial mats observed coating portions of the local river channels. Santa Juana pencil-like laminated deposits are an unusual form of boundstone with a distinct length to width ratio, although they are petrographically similar to the flat lying to mounded stromatolites. Narbonne et al. (2000) report similar pencil-like stromatolites from Neoproterozoic patch reefs in Arctic Canada, describing them as erect, straight sided columns, 7-8 mm in diameter. They interpret them as indicative of relatively low energy water conditions due to their delicate form (Narbonne et al., 2000). Kah et al. (2009) also interpret Proterozoic narrow branching columnar stromatolites, with similar length to width ratios as in the San Juana deposits, as having formed under moderate energy conditions in relatively shallow water. Casanova (1986) similarly interprets East African Plio-Pleistocene columnar stromatolites as having formed in low energy, sub-lacustrine settings, relative to more high energy lake margin shorelines or fluvial channels which are dominated by mat-like stromatolites. Thus the Santa Juana pencil-like stromatolites with their thin, delicate shape, are similarly interpreted as having formed in relatively low energy water, probably ponded behind barrage tufas. San Juana flat-lying and mounded stromatolites are more robust and may reflect higher energy conditions.
The pencil-like stromatolites grew subaqueously based on the diatom and ostracod assemblage associated  (Rech et al., 2010) and data for the late Miocene-Pliocene Opache Formation to the west and east of the city of Calama is from de Wet et al. (2015Wet et al. ( , 2020.
with them, and may provide an approximation of water depth based on their vertical height. Assuming that they did not extend above the top of the water, then the water they grew in must have been a minimum of ca 0.25 m deep. However, micro-unconformities within the Santa Juana stromatolites may represent episodic exposure, and their height might only approximate palaeowater depth.
Although it is unclear whether the Loa River's living microbial deposits ( Figure 12B) are actively calcifying, the fine-scale preservation of Santa Juana fossil stromatolite's internal structure, including delicate filament moulds, indicates that they calcified syndepositionally to preserve such structures. Numerous studies show that filament-rich laminations and clots indicate biologically mediated calcite precipitation; in freshwater, specifically, Phormidium incrustatum is often associated with stromatolitic tufas (Arp et al., 2001;Caudwell et al., 2001;Martin-Bello et al., 2019). Phormidium is an encrusting cyanobacteria that typically forms filaments perpendicular to a substrate, with rapid spring and summer growth, yielding lighter, porous laminations, and thinner, denser laminations which are produced during colder, less productive months (Martin-Bello et al., 2019;Pentecost, 2003;Whitton & Potts, 2000). Santa Juana microbial filaments have an average diameter of 5 μm and length of 0.15 mm, typical of Phormidium (Brasier et al., 2011;Freytet & Verrechia, 1998), therefore, similar strands in the Santa Juana stromatolites are interpreted as having formed by Phormidium. Lighter-coloured, thicker bands within the Santa Juana stromatolites are probably formed by β Phormidium, associated with nearly vertical growth, whereas α Phormidium forms darker bands, which exhibit shorter, sometimes cross-cutting filaments (Brasier et al., 2011;Freytet & Verrechia, 1998).
Rivularia haematites is a freshwater encrusting cyanobacteria with characteristic hemispherical distribution of filaments around a calcification centre (Pentecost, 1987). Some Santa Juana stromatolites contain microbial features with roughly spherical or fan-shaped petrographic fabrics and are interpreted as R. haematites based on their similar shape and size.

| Phytoherms
In the active Loa and San Salvador rivers phytoherms are typically composed of encrusted aquatic reeds that grow up to a metre tall above the water surface ( Figure 12C). These very abundant reed phytoherms form clusters that build out into the river channel and impede water flow, or line the river bank. They are partially cemented with incipient calcite and lime mud below the water line. Clusters of in situ fossil plant stem encrustations in the Santa Juana tufas are interpreted as sites of former reed colonies, which grew in gently flowing or standing water, based on direct comparison with reed thickets forming today. If the fossil phytoherms reflect similar conditions to the modern reeds, then the palaeo-stream channel must have been on the order of centimetres to ca 1.0 m deep, based on the length of some Santa Juana fossil stem encrustations. Petrographically, the encrustations consist of microbial clots and filaments that form dark and light coloured roughly concentric rings. Dark rings consist of dense filamentous laminations, light-coloured ones are more porous. Carbonate-encrusted stems are commonly ascribed to cyanobacteria, algae, and/or plant-driven CaCO 3 reactions due to photosynthesis and biologic CO 2 drawdown (Pedley et al., 2003). In the Santa Juana encrustations, filaments form felt-like carbonate laminations, which, based on the size and shape of the fossil filaments within the carbonate, are interpreted as having a biomediated origin. As noted above, P. incrustatum cyanobacteria is abundant in freshwater carbonate systems and in the Santa Juana boundstones, thus similar filaments in the encrustations are attributed to Phormidum. Some of the phytoherm encrustations also contain radially arranged filaments, suggestive of R. haematites, indicating that both types of cyanobacteria were probably present around reed stems.

| Cascadestone
Modern waterfall tufa currently precipitates in the Loa River ( Figure 12D), providing a direct analogue for Santa Juana cascadestone. Cascade tufas form in waterfalls where inorganic physiochemical degassing due to high water velocity and turbulence releases CO 2 , facilitating carbonate precipitation (Chen et al., 2004;Della Porta, 2015). This degassing leads to supersaturation and rapid precipitation of calcite, creating a porous and light framework that commonly precipitates on a biological substrate (Della Porta, 2015;Fouke et al., 2000;Gradziński, 2010). In humid climates, bryophytes and algae may construct calcite curtains when they become encrusted during growth (Valero Garcés et al., 2008). Gradziński's (2010) work on modern cascades documents how the alga Vaucheria acts as a substrate for calcite precipitation in cascade curtains. Freytet and Plet (1996) show Phormidium serving the same function in Paris Basin waterfalls; in Belgium, waterfall tufas contain abundant moss and other bryophytes (Janssen et al., 1999). In the arid Atacama region, cyanobacteria +/− algae replace bryophytes but serve a similar role as a substrate for calcite precipitation. The importance of biofilms in modern waterfall tufas is discussed in Gradziński (2010).
Santa Juana fossil cascadestone is associated with sites of relief change within dry gullies, and where tufas drape from the upland plain into gullies (Figures 3B and  7A). Although these tufas represent locations of intense water turbulence, the presence of delicate, aligned filaments within them suggests that biofilm activity was an important factor in carbonate precipitation. The filaments must have been calcifying syndepositionally to create a robust substrate to host precipitating calcite, as well as the next generation of microbial growth, considering the tufa is forming in mid-air. Samples of cascadestone from MMG and Ojo Opache contain well-preserved filaments of P. incrustatum, clusters of R. haematites, and possible Vaucheria algae, based on size and shape comparison with modern examples. The lack of secondary pore-filling calcite cement within Santa Juana cascadestone pore spaces indicates that once waterfall flow ceased, there were no diagenetic fluids moving through this facies, which is logical since they are now suspended in air as tufa curtains.

| Flowstone
Santa Juana tufa forms as a coating over pre-existing tufa or Opache Formation limestone, just as in the Loa River ( Figure 12D). It is characterised by layers of smooth, dense calcite, suggestive of rapid crystallisation (Baker & Smart, 1995). Channels with nearly vertical slopes, such as those in Stratigraphic Section 2, must have had very fast water flow rates, which would result in turbulence and degassing of CO 2 . Direct association with substrate limestone commonly facilitates carbonate nucleation (Baker & Smart, 1995;Boch & Spotl, 2011), and multiple generations of laminated, microstromatolitic layers in the flowstone indicate prolonged water flow. Similar features reported by Leslie et al. (1992) from Triassic flowstone in Wales are interpreted as flowstone generated by fastflowing spring waters. Santa Juana flowstone is interpreted as having formed in locations where water sluiced downslope but was not free falling as at waterfall sites.

| Porous limestone
This facies consists of porous and friable sandy rudstone and gravel composed of Santa Juana intraclasts, and mineral and lithic detrital grains, including clasts of Opache Formation limestone. The sandy rudstone/gravel generally occurs as centimetre-thick beds within other tufa facies, and is interpreted as detrital accumulations washed into tufa-forming sites, analogous to sediment accumulations in dry parts of the modern river bed ( Figure 12E). Episodic pluvial events capable of eroding and transporting Opache Formation and tufa material, as well as detrital mineral grains from outside the basin, must have occurred to produce the variable lithologic grains in these deposits. Post-depositional lithification was minimal based on the single generation of sparry calcite cement surrounding grains, and minor gypsum precipitation in pores. Porous rudstone/gravel that occurs along the feather-edge of fossil tufas on the modern landscape indicate the widest extent of Santa Juana carbonate-rich water (refer to Figure 15C for an illustration). Spillover from surface springs and seeps allowed water to cement surficial deposits but the lack of lateral continuity between these deposits indicates that the whole Calama basin floor was never covered in Santa Juana-aged water.

| Interpretation of microbial assemblages
As illustrated in Figures 5, 6D Lamination with distinct filaments, tubules and/or clots, organised into dense, dark-coloured laminae alternating with porous, lighter laminae is commonly attributed to seasonal temperature changes in tufa-forming water (Pentecost, 1987). Studies from temperate latitudes interpret P. incrustatum alternations of dense and porous laminae as reflecting seasonal change on an annual basis (Pentecost, 2003;Whitton & Potts, 2000), and Pentecost (1987) noted a correlation between Rivularia's laminated growth and water temperature. Both P. incrustatum and R. haematites are common in fluvial and spring environments (Freytet & Verrechia, 1998;Oste et al., 2021;Pentecost, 1987) and are often responsible for bio-mediated calcite precipitation in such settings (Manzo et al., 2012;Martin-Bello et al., 2019). Although Arenas et al. (2019) and Vennin et al. (2019) note that alternating laminations may reflect seasonal changes, they also suggest that alternating laminations may indicate variation in calcite precipitation rates. Caudwell et al. (2001) found that Rivularia laminations may reflect changing environmental conditions unrelated to seasonal water temperature and Muñoz-Martin et al. (2020) observe that Rivularia can form irregular layers in fluvial and tufa environments that may reflect local water salinity or energy variations more than seasonal change.
Most Santa Juana Rivularia and Phormidium-rich facies contain alternating light and dark laminations which probably reflect seasonal changes plus/minus calcite precipitation rates, based on modern monthly temperature variation in the Calama region (Weatherspark, 2022). Winter low temperatures are near freezing on average, and are below freezing 25% of the year. Local rainfall varies little, but river flow increases during summer wet season due to Andean rains and snows. Santa Juana microbial-mediated tufa laminations may reflect a systematic response to seasonal changes in stream/spring flow, +/− temperature changes, but Muñoz-Martin et al. (2020) report that Rivularia may produce large-scale, irregular laminations unrelated to temperature changes.
Both Rivularia and Phormidium thrive when submerged in moderately flowing water, where they typically form a thick felt coating on organic matter or rock surfaces, but they can survive periods of subaerial exposure (Pentecost, 1987(Pentecost, , 2003. In the Santa Juana stromatolite boundstone, phytoherm, and cascadestone facies, unconformities are not common, suggesting that water flow in these facies was relatively constant while they were being deposited, and microbial colonies were thriving. Modern tufas in Poland and Slovakia have the alga Vaucheria serving as a substrate for calcite precipitation (Gradziński, 2010). There, Vaucheria filaments are oriented parallel to water flow direction in turbulent settings (Gradziński, 2010), similar to filament orientation observed in Santa Juana cascadestone. Based on size, morphology and setting comparisons, some of the Santa Juana cascadestone filaments are interpreted as possible fossil Vaucheria algae.

| Interpretation of diatom assemblages
Three diatom assemblages were identified, therefore implying three main diatom habitats. However, when compared to the tufa facies, there is no clear trend between diatom species composition and facies type, perhaps due to the smaller sample size used for diatom counts (n = 16, Figure 10). However, there are some general patterns that can be observed.
All of the diatom species are typical of shallow water settings, supporting water depths of <1 m. Group 1 and 2 diatoms have been observed in modern salars (salt flats) on the Chilean Atacama, saline fumaroles, rivers and a palaeo-lake on the Chilean Altiplano, and in mineral-rich thermal springs in Yugoslavia (Angel et al., 2018;Feitl et al., 2019;Reid et al., 2021;Stavreva-Veselinovska & Todorovska, 2010). Their association with the porous limestone facies, and correspondence with minor increases in high-Mg calcite, may support a warmer water source for these tufa deposits. The aerophytic diatoms observed in Group 2 suggest periods of subaerial exposure, which also corresponds to porous limestone deposition along the farthest extent of the spring waters. Group 3 diatoms, being the most diverse, represent a range of conditions. This group tends to be non-motile, thus indicating low concentrations of suspended solids in the water; non-motile benthic diatoms are indicators of relatively clear water bodies, as these taxa will become buried by suspended sediment if the sediment load is too high (Dickman et al., 2005). Group 3 species have been observed on the Chilean Altiplano in cool, low salinity rivers and in lakes on the dry Interandean Plateau in the northern Andes (Angel et al., 2018;Benito et al., 2018). The group's association with phytoherms and stromatolites (particularly the pencil-like stromatolites) supports the presence of calm, shallow pools creating the diverse habitat necessary for these species to co-exist. Therefore, the diatom assemblages support higher energy flow conditions in the flowstone facies, and evaporationprone porous limestone deposits, as opposed to shallow, moderate energy conditions for stromatolite and phytoherm development. They also add support for variable water temperature and chemistry during the creation of these tufas. Figure 13A is a conceptual sketch summarising the Santa Juana facies characteristics. Figure 13B illustrates each of the facies and their distinguishing features; water energy conditions for each facies are interpreted. Diagenesis is limited to syn-depositional lithification, with or without significant microbial mediation, except in the porous limestone facies where gypsum and/or anhydrite occurs within some intergranular pore spaces.

| XRD and trace elements from ICP
The XRD data show precipitated calcite as the primary CaCO 3 polymorph, commonly attributed to ambient temperature springs, whereas aragonite more often precipitates from warm-hot spring travertines (Shiraishi et al., 2019). The presence of minor amounts of high-Mg calcite, as seen in the porous limestone facies, may indicate a possible increase in water temperature (Ihlenfeld et al., 2003), and/or porewater concentration due to evaporation whereby gypsum precipitation removes Ca, enriching the fluid in Mg 2+ (de Wet et al., 2020). Since gypsum and anhydrite are the final pore filling cements in these deposits, it is probable that the high-Mg calcite precipitated due to evaporative porewater concentration, prior to sulphate precipitation. Gypsum and anhydrite, characteristic of high aridity and evaporation, are forming on the desert surface in the Atacama today, and may be remobilised by the wind (Rech et al., 2003). In the Santa Juana carbonates, however, gypsum and anhydrite are present as intrapore crystal cements suggesting that when Santa Juana water flow ceased, carbonate cementation ceased, and gypsum and anhydrite precipitated via intrapore moisture evaporation. This is the only evidence for post-depositional, diagenetic cementation in the tufas, indicating that once MMGrelated water flow ceased and evaporation dried out the deposits, diagenesis essentially stopped, supporting field evidence that once surface water flow ceased, arid conditions prevailed. Santa Juana tufas contain higher trace element concentrations than is typical in average stream water (Veizer, 1983). This is not surprising given the quantity of

A B
potentially reactive volcanic material in the Andean catchment area. Elevated Sr 2+ concentrations may also reflect leaching from numerous regional gypsum-rich deposits (Banat & Obeidat, 1996). Iron and enriched Mn concentrations are probably sourced from weathering of volcanics within the watershed, coupled with elements sourced from the underlying Opache Formation limestone aquifer ( Figure 14A,B). The Opache Limestone hosts the upper aquifer in the Calama Basin and the Opache freshwater limestones have relatively high trace element concentrations, ca 1,500 ppm Sr 2+ , ca 200 ppm Mn 2+ , ca 3,000 ppm Fr 2+ , and up to 30,000 ppm Mg 2+ (de Wet et al., 2020). Consequently, it is not surprising if Opache Formation dissolution and groundwater circulation, with faults serving as conduits, brought water that transported locally derived cations to the Santa Juana tufa system ( Figure 14A,B).

| Stable isotopes
If the water's δ 18 O was similar at the time of tufa formation to the modern river (ca −8‰; Herrera et al., 2021), F I G U R E 1 4 Conceptual model of the long-term flow of water to the Santa Juana tufa region. (A) 3D perspective image, view looking north-eastward, of the tufa accumulation area (crosshatched region) between the San Salvador and Loa canyons. The topographic model is based on ALOS elevation data, with sun illumination from the north-west and 3X vertical exaggeration. (B) Generalised cross-section X″-X′-X illustrates a topographic profile along the land surface between the canyons, and north-eastward across the Calama valley, and the combination of groundwater paths and surface water flow to and through the tufa accumulation region. Sector X′ to X (after Jordan et al., 2015) summarises today's flow from the Andean uplands (X) to the eastern sector of the tufa depositional area (X′). Sector X″ to X′ illustrates that units with the potential to act as aquifers exist farther west, underlying the area with tufa. Nevertheless, there is no known direct evidence of springs west of Ojo Opache. Hence the path by which surface water (purple arrows) fed the tufa on the upland surface west of Ojo Opache spring is speculative. the most negative δ 18 O value measured on the tufa indicates an ambient temperature <30°C, which is consistent with calcite as the primary polymorph (Andrews & Brasier, 2005). If the changes in δ 18 O were due to temperature alone, the difference between cascadestone's δ 18 O of −6.8‰ and the phytoherm average δ 18 O of −4.1‰ would be equivalent to 11°C, with cascadestone in particular indicating warmer temperatures. However, an assumption of no change in the δ 18 O of water is very improbable given that warmer temperatures are also more likely to coincide with more evaporation. Evaporation is typically more important in defining δ 18 O and δ 13 C in arid environments than temperature due to rather small changes in mean daily temperature relative to the large changes in water budgets (precipitation-evaporation). Evaporation increases δ 13 C as well as δ 18 O due to the decrease in CO 2 solubility as evaporation increases salinity and the water warms and becomes more saline, leading to 12 CO 2 enriched gas evasion. Sample CH 98-19 near the top of the scarp at the Ojo Opache escarpment has very high δ 13 C, which suggests that the water from which it precipitated may have recently emerged from the carbonate-dominated Opache Formation aquifer which was over-pressured in CO 2 . Dry environments also limit the potential for biogenic CO 2 input from soil microbes, which is enriched in 12 CO 2 compared to the atmosphere. The lower δ 18 O and δ 13 C of cascadestone and flowstone compared to stromatolite and phytoherms is consistent with increased surface flow, while quiescent periods and/or ponding by vegetative damming promoted evaporation (Andrews, 2006) ( Figure 11A).
It is hypothesised that Santa Juana tufas associated with the MMG represent a proximal (east) to distal (west) palaeo-channel that contained tufa-depositing flowing water throughout the Quaternary. In contrast, it is suggested that the Ojo Opache location preserves a record of Holocene tufa formation from a spring +/− stream site. Relatively recent climate drying, coupled with increased demand for water resources in the Calama area, may have reduced water flow in both locations. In MMG, all five of the Santa Juana facies are recognised, and based on analogy with the modern Loa River, the MMG is interpreted as having once been the site of a similar flowing stream. At Ojo Opache, water flow decreased from what was enough to produce a dynamic waterfall complex to the present intermittent trickle within a few 1,000 years. These hypotheses were investigated using case studies with detailed stratigraphic, sedimentological, geochemical and age relationships from sites along the MMG and Ojo Opache location.

| Case studies: Tufa complexes at measured sections in major middle gully and at Ojo Opache
Two locations with varied tufa facies were chosen for detailed sampling; three sections were measured along MMG, and Ojo Opache, with its large cascadestone complex, was also chosen. The MMG is incised into the Opache Formation (and older units), like the present Loa River, and is abundantly adorned with fossil tufa complexes along its side walls and floor ( Figures 1B and 3A), similar to the distribution of modern tufas forming in the Loa River now. Sample locations are shown on the stratigraphic sections, which are referenced to locations in Figures 1A,B,C and 3A,B.
Three measured sections through tufa complexes were made within a 1 km stretch of MMG to compare and contrast their facies laterally and vertically ( Figure 3A). The Ojo Opache site is a 50 m wide, 10 m high semi-circular erosional scarp with a gently sloping valley floor, covered with tufa deposits (Figures 1C, 3B and 7A). The tufas formed on top of collapsed Opache Formation strata and were described and sampled from the base of the valley floor to near the top of the escarpment. In MMG and at Ojo Opache, fossil tufa morphologies interweave with each other, changing both laterally and vertically from one form to another, within a few centimetres, illustrating the complexities of tufa construction even within a very restricted geographic area. Measured sections were logged from the base to the top to be consistent with stratigraphic convention, but because of the complex way that tufas form, older strata may be at the top and/or behind younger tufa coatings which precipitate when the gully deepens or the water volume changes. Detailed age dates, coupled with stratigraphy, are important for unravelling this complexity, as we illustrate below. MMG measured sections 1, 2, 3 4.11.1 | Measured section 1 ( Figure 3A) The 4.8 m high tufa outcrop ( Figure 15A) consists of phytoherm deposits on the gully floor, overlain by a thin porous limestone. This is overlain by another phytoherm, overlain by stromatolite, followed by phytoherm, stromatolite, phytoherm and another porous limestone. Stratigraphically above, phytoherm, transitioning to flat-lying stromatolite, is overlain by a bed of pencil stromatolites ( Figure 4C,D) overlain by phytoherm, followed by porous limestone, a thin phytoherm, and porous limestone cap ( Figure 15A). These units change laterally over <5 m into one or another morphology. Porous limestone horizons are not traceable laterally for more than a metre. A phytoherm encrusted stem from the base of the section yielded an age of 541.7 ka. An age of 243.6 ka was obtained from laminated stromatolite 2.75 m up from the base, and a pencil stromatolite 1.1 m farther up section yielded an age of 334.9 ka. The δ 18 O and δ 13 C compositions range between −6.5‰ to −3.1‰ and −3.3‰ to −1.2‰ and correlate. Phytoherms have higher δ 18 O values compared to stromatolites (−4.2 ± 0.8‰ compared to −5.8 ± 0.5‰), but have indistinguishable δ 13 C values. Increasingly negative δ 18 O values were measured up-section, until a reversal occurs at the top, possibly due to a change in facies sampled (Table 2).

| Measured section 2
This tufa ( Figure 3A) consists of an 8.5 m high, 15.0 m wide tufa complex with well-defined lateral margins, consisting of multiple tufa facies ( Figure 15B). The base of the complex, at the contact with the present gully floor, consists of stromatolite boundstone and phytoherm overlain by a shallow depression floored with mudcracked lime mud. Laterally adjacent is a flowstone-lined, nearly vertical sluiceway that can be traced up the gully wall to a flat lying tufa shelf containing a 9 × 12 m mudcrack-lined depression, which is connected to the sluiceway by a 1.5 m high stromatolitic boundstone and phytoherm complex. The channel takes a sinuous path winding between the stromatolites and phytoherms ( Figure 6A). Behind the large depression, the vertical gully wall is draped with cascadestone and flowstone deposits that can be traced to the top of the gully wall. On the land surface there is a 3.5 cm thick porous limestone that directly connects to the cascadestone and feathers outward over the Opache Formation landscape surface ( Figure 15C,D). The complexity of tufa formation is illustrated by U-Th dates obtained from Section 2. Phytoherm stems 1 m up from the base of the complex yield an age of 100.3 ka. Three metres above the base, flowstone has an age of 348.7 ka, 4 m above the base stromatolites gave a date of 332.6 ka, another phytoherm layer located 6.5 m above the section base is dated 252.6 ka, and a stromatolitic lens in the porous limestone near the top has a measured age of 276.8 ka. Older and younger deposits are intermixed, illustrating how tufa precipitation may produce a pastiche of simultaneous and overlapping deposits, rather than constructing a simple vertical stratigraphy. The δ 18 O and δ 13 C compositions range between −5.7‰ to −1.4‰ and −2.1‰ to +1.6‰. Sample CH-80-19 has higher δ 18 O and δ 13 C values than other samples, and for the other samples, there is no correlation between δ 18 O and δ 13 C values. Unlike Section 1, phytoherms have lower δ 18 O values than stromatolites (−4.9 ± 0.6‰ compared to −1.4 ± 1.8‰), although the phytoherm compositions are similar to those of Section 1. A single sample of flowstone has similar δ 18 O values to phytoherms, but its δ 13 C value is closer to that of the stromatolites (Table 2) ( Figure 11A,B).

| Measured section 3
Forty metres ( Figure 3A) to the west, the MMG narrows to 2 m in width ( Figure 16A,B). A 0.5 m high stromatolitic boundstone crosses the centre of the gully at this channel pinch point ( Figure 16B). Fossil phytoherms, 8 m high, extend into the gully and line the side wall; small diameter stem moulds are abundant in the lower half of the phytoherms, the upper half consists of large diameter stem moulds ( Figures 6C and 16A). Two dated horizons suggest this stratigraphic section is younger than Sections 1 or 2. Flowstone collected just above the level of the stromatolite boundstone on the northern side of the gully yields an age of 92.9 and 94.0 ka, and phytoherm calcite 7 m up from the channel floor yields an age of 207 ka. The δ 18 O and δ 13 C compositions range between −8.8‰ to −6.6‰ and −2.3‰ to −1.2‰. The phytoherm facies has higher δ 18 O and δ 13 C values than the flowstone, −6.7 ± 0.2‰ versus −8.2 ± 0.5‰, and − 1.3 ± 0.1‰ versus −2.0 ± 0.2‰. A negative correlation is apparent in δ 18 O and δ 13 C values for the flowstone samples. Unlike in Section 1, phytoherms have lower δ 18 O values than stromatolites (−4.9 ± 0.6‰ compared to −1.4 ± 1.8‰) ( Table 2) ( Figure 11A,B).

| Case study: Ojo Opache location (Figure 3B)
The Ojo Opache site is a 50 m wide, 10 m high semi-circular erosional scarp ( Figures 1C, 3B and 7A) characterised by block collapse and slumping; metre-scale blocks of Opache Formation limestone are dislocated and rotated downslope, re-cemented in place with tufa carbonate (Figure 17). Groundwater is actively seeping out from one sidewall, precipitating halite dripstone on the cliff wall, and water is slowly dripping from a broken pipe stuck into the tufa near the top of the headwall. Spectacular cascadestone and flowstone tufa coats the headwall ( Figure 7A); the tufa-covered slope from the base of the cascadestone, down an inclined surface, to the end of the deposit is 320 m long. Smaller cascadestone, flowstone, phytoherm, sandy porous limestone lenses, and flat-lying to mound stromatolite deposits occur in the middle area of the sloped surface ( Figure 17).
Tufa formation at Ojo Opache is generally more recent than ages indicate from the MMG measured sections, although Pleistocene-aged flowstone from Section 3 in MMG was dated at 94 and 92 ka. At Ojo Opache, faunal remains indicate incision into the Opache Formation by the late Pleistocene (López et al., 2010, López & Rojas, 2018 and two dated phytoherm samples, collected from the Ojo Opache tufa slope, have ages between 2.42 ka and 2.27 ka (Tables 2 and 3). Cascadestone from the escarpment gave ages of 2.5 and 2.56 ka. The phytoherm δ 18 O value is lower than that of the cascadestone or flowstone, but its δ 13 C value is intermediate between the high value for flowstone (+6.4‰) and cascadestone. There is no correlation between δ 18 O and δ 13 C values (Table 2) ( Figure 11A,B).

| Interpretation of MMG stratigraphic sections and the Ojo Opache site
Major Middle Gully is incised into the landscape, the walls are lined with tufa in patches along much of its 11 km length, and tufa covers parts of the gully floor (Figures 1B,3A and 15E). Tufa structures such as cascadestone and flowstone that drape down the gully walls provide clear evidence that water was flowing into the gully from sidewall springs or streams ( Figures 3A, 4B,C and 8A). In situ stromatolites ( Figure 4A) and phytoherms ( Figure 6B) on the gully floor indicate a perennial stream with minimum water depths of ca 0.5 m. Deposits with flow directional indicators, such as phytoherm stems bent downstream, show that water was flowing from east to west.
Stratigraphic Section 1 ( Figure 15A) consists of multiple shallowing upward tufa facies in vertical succession; phytoherms and stromatolites indicate standing or gently flowing water, porous limestone represents a hiatus in tufa formation and possible subaerial exposure. The succession indicates that phytoherm or stromatolite-rich pools formed, then became inactive, resulting in deposition of a thin cap of porous limestone, until another phase of tufa formation began. This is commonly seen in modern tufa complexes where active water flow moves laterally when obstacles block flow in one location (Pedley et al., 2003).
Measured Section 2 ( Figure 15B), located 30 m downstream from Section 1, consists of cascadestone draping from the top of the gully wall, indicating the former presence of a waterfall that debouched into a stromatolitedammed pool. Water overflow coursed through a narrow stromatolite and phytoherm lined channel, spilling downslope in a flowstone-lined sluiceway into smaller pools, ultimately joining the flowing MMG stream below. This section also contains evidence for depositional hiatuses, as indicated by horizons of porous limestone within the tufa complex. Hiatuses represent periods of non-tufa precipitation rather than erosion because details of the tufa complex are perfectly preserved, with no evidence for erosion or dissolution. Mudcracks in the sediment on pool floors also show that there were periods when water flow stopped and the pools dried out. Since there is no tufa on top of the mudcracked surfaces, it is probable that they represent the demise of the MMG river system, or at least the end of water flow in this location.
The range in U/Th determined ages (92.9-541.7 ka) suggests that tufa was being deposited over a time span of ca 400 kyr and that there was active water flow as recently as 100,000 years ago. Age dates from just below upper porous limestone horizons in measured Sections 1 and 2 are nearly identical (within analytical error, or 6,000 years of each other, 334.9 and 276.8 ka respectively) suggesting that they may represent the beginning of a particularly dry period. Similarly, ages from stromatolite and phytoherm calcite from Sections 1 and 2 are within 3,000 years of each other, suggesting they represent a more humid period of time.
Measured Section 3 ( Figure 16) is 40 m downstream from Section 2. At Section 3 there is a pinchpoint in the MMG channel where a stromatolite barrage tufa partially blocks the channel between thick phytoherms on either sidewall. This is interpreted as a place where MMG stream water was at least partially dammed, forming a pool on the upstream side. In the former stream channel, detrital wackestone laps up against the stromatolite barrage, F I G U R E 1 6 (A) Sketch of stratigraphic section 3 with facies distribution, sample numbers, and U/Th dates. (B) Field photograph showing the MMG pinchpoint, as seen in Figure 3A. In this figure, looking upstream, stratigraphic section 3 on the left side, and a stromatolite barrage tufa goes across the middle of the gully channel (upstream blue arrow is pointing at the barrage).

A B
interpreted as detrital material carried downstream until being trapped behind the barrage. As water began to pond and plants took root in the wackestone sediment, phytoherms expanded. Ponded water generated stable conditions for plant growth and ensuing calcite encrustation. Stem tubules in the upper part of the section are particularly large here (up to 11.5 cm diameter), supporting the interpretation that plants were well established and longlived. Flowstone on the adjacent gully walls indicates that water flowed around the phytoherms, as observed in the Loa River today. Ages from Section 3 samples indicate that it is younger than the tufas in Sections 1 and 2. The lower δ 18 O values of phytoherms at Section 3, compared to upstream Sections 1 and 2, suggest inflow of water with lower δ 18 O values represented, in part, by the flowstone, perhaps indicative of water with a different isotopic composition due to the age difference between the sections. Isotopic inheritance of δ 18 O values from Opache Formation carbonate is unlikely to be recognisable due to the presence of other sources of oxygen from both CO 2 and H 2 O, which make it isotopically difficult to determine specific oxygen sources.
Recall Figure 13A,B as a summary of tufa facies. In MMG, the facies mirror those in the modern Loa River. Although the river paths and springs which brought water to the MMG palaeo-river are not established, Figure 14 illustrates the sources for groundwater and surface water to the western branch of today's Calama Basin. A topographic profile along the upland surface between the canyons, and north-eastward across the Calama valley, shows the combination of groundwater paths and surface water flow to and through the MMG region. At the time the MMG tufas accumulated, the San Salvador canyon may have existed, but the narrower Loa canyon, with steeper walls and cracks suggesting imminent collapse of large blocks tens of metres across of the surface Opache limestone suggests its incision is relatively recent, and possibly contemporaneous with deposition of the Santa Juana tufa. At the time the MMG tufas accumulated, the degree of incision of the San Salvador canyon is not well constrained. Whereas Tully et al. (2019) revealed at a location farther upstream in the San Salvador drainage system where the canyon is 30 m deep that incision continued more recently than 11.1 k BP, the best constraint on the history of incision of the >200 m deep San Salvador canyon is only that it post-dates the Late Pliocene Opache Formation. The incision of the San Salvador canyon is thought to predate initial incision of the Loa canyon near the study site because of the relative widths of the San Salvador canyon (e.g. 1,200 m wide immediately north of the eastern end of MMG) compared to the neighbouring, parallel Loa canyon (e.g. 600 m wide immediately south of eastern end of MMG) and the much deeper incision of San Salvador (120 m differential). That comparison suggests that that the San Salvador has been actively eroding longer than the Loa River. Furthermore, locally vertical walls and cracks suggesting imminent collapse of large blocks tens of metres across of the surface Opache limestone adjacent the Loa canyon suggest its incision is relatively recent. Given also that the abandoned MMG gully connects to the Loa canyon, it is thought that (a) incision of the San Salvador canyon initiated first, at an unspecified time following the end of Opache Formation accumulation; (b) incision of the Loa canyon initiated second, and that early in the incision activity the MMG was a part of the main Loa headward expansion; (c) incision of both the Loa and San Salvador canyons continued contemporaneously with Santa Juana accumulation.
Today, exchange of water between the Loa River and groundwater is important and groundwater discharges at the Ojo Opache (O.O. on Figure 14B) spring, but there is no direct evidence for recent active springs west of Ojo Opache. Thus, the path by which Pleistocene surface water ( Figure 14B, purple arrows) fed the tufas on the upland surface west of Ojo Opache is speculative.
The Santa Juana tufas of Ojo Opache are much younger, and the Ojo Opache site is an area of ongoing spring discharge, groundwater sapping, cliff collapse and tufa precipitation. Modern crevasses on the top of the cliff, fallen blocks and breccias demonstrate that this remains an unstable area. Shallow groundwater seeps from a side wall and from the top of the cliff, and a small diameter pipe carries a trickle of water from another seep at the top of the cliff to the base of the slope where the water disappears into porous sands and gravels ( Figure 17). The large size of the Ojo Opache tufa complex, with 20 m wide cascadestone deposits, indicates that surface water poured over the upper escarpment in the past. Godfrey et al. (2021) and Jordan et al. (2015) provide evidence that the San Salvador River is sourced by a groundwater-fed spring where the Precordillera Highlands and the West Fault bring groundwater to the surface ( Figure 14B).
In summary, the Ojo Opache tufa complex is interpreted as a perched spring +/− surface water stream site where a major waterfall, with minor side cascades, flowed over a 20 m high escarpment. Fossil cascadestone represents the former waterfalls, and phytoherms represent adjacent reed colonies. Below the waterfall, stromatolites, plant clusters and sandy detritus built up a tufa slope apron. The lower slope had extensive reed thickets that dissected water flow paths and reduced water velocity. The U/Th dates show that tufa was actively forming ca 2,500 years ago.

| DISCUSSION
This study is important in documenting that significantly more water flowed in the area west of Calama within the past ca 550 kyr, and that water was organised in clearly defined channels and spring locations. Fossil tufa deposits line a former river channel, the MMG, designated as a third river based on its location between the active San Salvador and Loa rivers. Tufa distribution shows that the gully channel must have been in place, at roughly its current depth, prior to most of the tufa's formation because tufa fabrics clearly drape into the channel and terminate at the gully floor. Smaller, side gullies also contain tufa deposits, indicating that they were once stream tributaries.
Much more recently, starting at 2.5 ka and into historical times, the large waterfall complex at Ojo Opache created pools and tufa deposits. This is consistent with other proxy records which indicate that Calama city was an oasis site for Late Holocene prehistoric societies (Tully et al., 2019).
At each of the measured sections in MMG, the range in age probably indicates that the tufa records not only wet periods, but also defines periods when carbonate ceased deposition. For example, at Stratigraphic Site 2, stromatolites, phytoherm and flowstone yield ages that range from 348.7 to 252.6 ka but at the base of the section, the phytoherm is only 100.3 ka, suggesting that it may have formed from water flowing in the third river well after water flow from the cliff above ceased.
Understanding fluvial tufa temporal relationships is challenging because river incision allows younger tufa to be deposited below (at a lower gravitational position than) older deposits (Pedley et al., 2003), and tufas may form overlapping structures over time (Della Porta, 2015). Such relationships can be seen in the Loa River channel, where actively precipitating tufa is intermixed with very young fossil tufas. While stratigraphic techniques cannot always be applied to tufas, detailed age data can constrain their stratigraphic architecture. Santa Juana results show that fossil tufas were deposited before 550,000 years ago, with clusters of younger ages that suggest time periods when greater surface water flow occurred. Ongoing U/Th results indicate that MMG tufas are generally younger to the east, closer to Calama. Within the measured sections or tufa complex at Ojo Opache, ages exhibit a relatively narrow range, for example, at the Ojo Opache complex, construction occurred within a few thousand years. In MMG, tufa construction went on for considerably longer; over 250,000 years at Sections 1 and 2 or over 100,000 years at Section 3. Because tufa architecture is complex, carbonate precipitation may occur at a given site, while only centimetres away, water flow may cease and no tufa is deposited. So although tufa deposition can be rapid, it is dependent upon sufficient water being present at any given location within the overall tufa complex.
The role of microbes in tufa formation is an ongoing area of research, revolving around the question of which is more important; algal, cyanobacterial and/ or plant photosynthesis metabolic uptake of CO 2 that drives CaCO 3 precipitation in freshwater systems, or degassing +/− evaporation? Chen et al. (2004) argue that degassing at waterfall sites increases calcification rates by a process of water pressure reduction, jet-flow effects and aeration effects. Collectively, effective collisions between dissolved ions are increased, accelerating their reactions, thus increasing carbonate precipitation. But studies by Rogerson et al. (2008), Gradziński (2010), Arenas et al. (2019), and Shiraishi et al. (2019) indicate that bio-mediated precipitation is important in most tufa deposits. Rogerson et al. (2008) note that although degassing regulates supersaturation, their experimental results suggest that biofilms accumulate ions such as Ca, Ba, Sr and Mg, and that without microbial enhancement, carbonate precipitation would be diminished. The presence of well-preserved microbial filaments in most of the Santa Juana tufa facies suggests that biologically mediated or at least biologically influenced calcite precipitation was important, even in high energy facies such as cascadestone and flowstone. In those turbulent settings, inorganic CO 2 degassing must also have been a driving force for calcite precipitation. Nevertheless, a photosynthesis-derived, microbially contributed, isotopic signal is hard to recognise because the isotope signature of degassing of high levels of volcanogenic CO 2 overwhelmed the isotopic contribution from biogenic sources (Godfrey et al., 2021).
The Santa Juana tufa deposited over much of the plateau between the San Salvador and Loa rivers west of Calama contrasts isotopically with latest Pleistocene carbonate deposited within terraces adjacent to the Loa River immediately east of Calama (Rech et al., 2010). These terraced deposits overlap with the highest δ 18 O of the Santa Juana tufa, but their δ 13 C values are similar to only the most 13 C enriched tufa deposited at Ojo Opache. The Loa River is currently oversaturated with respect to calcite; its dissolved inorganic carbon is enriched in 13 C and poor in 14 C due to large volcanogenic inputs of CO 2 from the nearby Andes (Aravena & Suzuki, 1990;Godfrey et al., 2021). River water, whose δ 13 C and δ 18 O signature was affected by surface evaporation, infiltrates sediment and precipitates carbonate, preserving the river's δ 13 C signature. The Loa River is also an important source of water to the aquifers in the Calama Basin which discharge at Ojo Opache (Herrera et al., 2021;Jordan et al., 2015), so the similar δ 13 C compositions are not surprising (Aravena & Suzuki, 1990;Herrera et al., 2021;Jordan et al., 2015). The δ 18 O composition of Sant Juana tufa and water sampled at Ojo Opache, which is the same as the Loa River at Calama, is consistent with calcite precipitation temperatures similar to the summer average of 18°C (Herrera et al., 2021). The higher δ 18 O values of carbonate precipitated in Rech et al.'s (2010) Loa River terraces can be explained by increased evaporation from surface and infiltrating water, compared to groundwater as it emanates at springs, per the Santa Juana limestones.
The range in δ 18 O and δ 13 C values of the Santa Juana tufa is slightly wider than the combined western and eastern sectors of the late Miocene to Pliocene carbonate Opache Formation, which preceded deposition of the tufa (de Wet et al., 2015(de Wet et al., , 2020Rech et al., 2010) (Figure 12B). The range in δ 18 O values of the Opache Formation is quite similar to the Santa Juana tufa data presented here, but is shifted to more positive values by 2-3.5‰. The range in δ 13 C values measured in the Santa Juana fossil tufas, excluding 13 C-enriched sample CH 98-19, is similar to the Opache Formation but the cross-plot of δ 18 O and δ 13 C values shows that the Santa Juana tufa forms a near parallel trend to the Opache Formation, with lower δ 13 C values by 4-6‰ ( Figure 12B). Regional volcanic activity reached a maximum between 8.5 Ma and 2.8 Ma (Breitkreuz et al., 2014) during deposition of the Opache Formation. While the fact that Santa Juana δ 13 C-δ 18 O array plots below that of the Opache Formation is consistent with less pervasive CO 2 in the hydrological system due to waning volcanism by the Quaternary, that does not account for the river terrace carbonates of Rech et al. (2010) which support continued high levels of CO 2 . The Santa Juana tufa is deposited in gullies incised within a relatively flat area, where vegetation frequently caused water to pond. In addition to a microbial mechanism of carbonate precipitation which itself could add biogenic sources of CO 2 , the increased residence time of water due to low gradients and the decay of vegetation also promoted the imprint of biogenic CO 2 on the Santa Juana δ 13 C values.
Climate during the deposition of the Opache Formation was episodically more humid, as evidenced by the geographic extent of the wetlands and shallow lakes (de Wet et al., 2015(de Wet et al., , 2020. Due to standing water in lakes and wetlands, evaporation had a substantial impact on δ 18 O and δ 13 C values. The Santa Juana samples also form an evaporation trend, suggesting that surface water within the gullies also evaporated, but the lowest δ 18 O value, assuming it is least affected by evaporation, suggests the water was more depleted in 18 O than water currently in this region. Either average temperatures when calcite precipitated have decreased by about 4°C since the Pliocene, or the vapour from which watershed precipitation condensed was isotopically depleted relative to the late Miocene-Pliocene aged Opache Formation precipitation. Moisture generally reaches the Calama Basin recharge area today most often from the east, passing over the Andes from Atlantic sources, although occasional extreme weather events also bring Pacific sourced rain (Jordan et al., 2019). In contrast, a Pacific-dominated source was argued for precipitation responsible for the Opache Formation hydrologic system (de Wet et al., 2015(de Wet et al., , 2020Sáez et al., 2016), with a short moisture path and less rain-out effects (Rozanski et al., 1993). With an assumed temperature of calcification of 18°C, the lowest δ 18 O value suggests that the δ 18 O composition of the water was −9.7‰, lower than modern local water, but similar to the upper reaches of the Loa River where it collects water from the mountains. This suggests that the times of increased moisture which led to formation of tufa probably coincided with increased rainfall on the mountains rather than local precipitation, although this cannot be excluded.
The U/Th ages obtained from the Santa Juana fossil tufas provide important new regional age constraints for the post Neogene, pre-200,000 year time interval. The 14 C dates constrained younger deposits from the last 50,000 years (Gayo et al., 2012;Nester et al., 2007;Pfeiffer et al., 2018). Even using sparse U-Series dates on halite (Bobst et al., 2001;Lowenstein et al., 2003) from a very specialised groundwater fed system in the Salar de Atacama, the palaeo-hydrological record has been dated primarily over the last 100,000 years, with a single data point stretching the record back to 325,000 years. This study helps fill the gap, providing much more insight into the region's hydrological history for the past ca 550 kyr.
At some point in time between the time when deposition of the Opache Formation ceased and the first Santa Juana tufa formed in gullies incised into the Opache Formation surface, the amount of water available to the western Calama Basin decreased. The cessation of the Opache Formation depositional system could be due to regional drying, or a change in base level and drainage capture (Evenstar et al., 2015). In the neighbouring Salar de Atacama Basin, the coeval Vilama Formation continued deposition for as much as another million years after Opache Formation deposition ceased, although the chronology for the end of Opache deposition is only loosely constrained. Stable isotope data for Holocene tufa at Ojo Opache suggest a very similar environment to the modern, which is near-hyperaridity at the elevation of Calama, while it is semi-arid in the Andes. By 550 ka, this study shows that there was more water than today, based on the tufas documented here. Those tufas formed from water which was isotopically more similar to rainwater that today falls at high elevation over the mountains, rather than the slightly more enriched water that reaches Calama now. Overall, the distribution of δ 13 C and δ 18 O values, the calcium sulphate cements in the porous limestone associated with the tufa, and the episodic flow of surface water as indicated by the U/Th chronology suggests that the Santa Juana tufas formed when climate in the mountain catchment was wetter, and that tufa did not form when conditions were drier in the mountains (Placzek et al., 2006).

| CONCLUSIONS
Based on analogues in the Loa River, it is possible to recreate specific tufa-depositing environments and facies associations in the Santa Juana limestones. Exceptional preservation in the region's hyperarid climate means that post-depositional diagenesis has been negligible, preserving detailed sedimentary features, diatoms, fossil microbes, trace element values and stable isotopes. Wellpreserved gypsum and anhydrite cements as final diagenetic products within the porous limestone facies suggest that, within the lowland sectors of the Calama Basin, hyperaridity has not been interrupted by significant rainfall or prolonged wet periods. This lack of rain in the lowlands contrasts with evidence for times of increased and decreased surface water flow due to changes in precipitation in the mountain catchment area.
Recognition of five types of tufa and interpreting them in terms of water flow energy along a perched spring to fluvial continuum allows for reconstruction of Quaternary hydrology and climate in this part of the Calama Basin and palaeoclimate in the mountain headwaters. Cascadestone formed at waterfalls, boundstone represents microbial stromatolite growth, phytoherm deposits are the sites of former plant colonies, flowstone shows where water was sluicing in channels, and porous limestone indicates places where water, supersaturated with calcium carbonate, cemented detrital debris, including Opache Formation and Santa Juana clasts. Collectively, these facies associations allow for detailed depositional environmental reconstructions. For example, the MMG pinchpoint and stromatolite channel barrage ponded water behind it, permitting longlived plant colonies to develop along the channel sides. Farther upstream, an older pool created quiet water conditions ideal for pencil-like stromatolites to develop. Cliff and slope environments produced a pastiche of waterfalls, plant colonies, small channels and stromatolites, as documented from Stratigraphic Section 2 and Ojo Opache. Diatom associations confirm a range of water flow conditions, and the abundant suite of microbial fossils show that the tufa system was well oxygenated and within the photic zone. A combination of degassing, evaporation and biologically mediated processes caused rapid calcite precipitation, creating large calcite tufa complexes. Stable isotope results indicate that, relative to the open water environments present in the Miocene-Pliocene Opache Formation, evaporation was less of a factor in the Santa Juana system once groundwater reached the surface. Similarly, although degassing of CO 2 -rich waters was a factor in tufa formation, particularly at waterfall sites, waters were either less dominated by volcanogenic CO 2 than in the Neogene or vegetation was key in retaining water, and at the same time, imparted its biogenic signature. Alternating light and dark laminations within microbially dominated tufa facies suggests Quaternary seasonality, perhaps similar to the present regional climate where cold winter nights contrast to more uniform summer temperatures. This study documents a third river flowing between today's two active rivers, and interprets this as a reflection of greater surface and groundwater flow, relative to today. Human water use has reduced the amount of water flowing westward past Calama over the past few hundred to tens of years, but the third river shows that during Quaternary pluvial episodes, more water was flowing west of Calama.
The U/Th dates obtained from the Santa Juana tufas provide new regional constraints on wetter pluvial periods. Dates from the MMG tufas show that there were multiple periods of increased rainfall in the high Andean headwaters of the Loa River between 541.7 ka and 92.9 ka. This study suggests that surface and/or groundwater flow through the Loa catchment decreased ca 200 ka, with the consequence that tufa deposition west of Calama became limited to the Ojo Opache spring site and within the active San Salvador and Loa River channels.

DATA AVAILABILITY STATEMENT
The data that support the findings of this study are available from the corresponding author upon reasonable request.