Brain activity during visuospatial working memory in congenital adrenal hyperplasia

decoding of the visuospatial task, while females showed decreased activity in these regions. Conclusions: Long-term cortisol imbalances do not seem to have a major impact on the functional brain responses during working memory in CAH. However, activity of the left dorsal visual stream in particular might be affected depending on sex. As the task employed may have been relatively easy, larger studies using more complex tasks are needed to further investigate this.


1.
Introduction Glucocorticoid (GC) replacement therapy (hydrocortisone, prednisolone or sometimes dexamethasone) in combination with mineralocorticoids (fludrocortisone) is the basic therapy for classic congenital adrenal hyperplasia (CAH), a condition characterized by cortisol deficiency. Though beneficial, treatment may also lead to metabolic and cognitive risks, due to difficulties in gaining adequate control, resulting in the administration of excessive GC doses in a non-physiological pattern.
Impairment of general intellectual ability, working memory and executive functions has been demonstrated in several CAH cohorts (Browne et al., 2015;Collaer et al., 2016;Helleday et al., 1994;Johannsen et al., 2006;Karlsson et al., 2017). However, outcomes vary between studies and may depend on age at the time of testing, the type of GC that is used in treatment, the cumulative GC dose during the life-time span, and whether the individual has experienced any salt-wasting crisis. Recently it was demonstrated that verbal working memory capacity is reduced in young children with CAH (7e11 years) when compared with relatives without CAH (Browne et al., 2015). This was repeated in a cohort of adolescents and young adults (12e20 years) and in adults above the age of 20 years (20e45 years), though the effect sizes were much larger in the older age group (Cohen's d of .36 versus 1.7) (Collaer et al., 2016). In a group of adult individuals with CAH (16e32 years), compared to population controls, we have also shown performance deficits in verbal and visual spatial working memory tasks (WAIS-IV Digit Span; WMS-III Span Board Test), as well as inhibitory control (Stroop test) (Karlsson et al., 2017). However, patients performed similar to controls on other skills such as short and long-term verbal memory and semantic knowledge (WMS-III List learning and Long-term memory; WAIS-IV Vocabulary), processing speed (WAIS-IV Coding), and reasoning/problem solving (WAIS-IV Matrices) (Karlsson et al., 2017). Cognitive problems in CAH therefore seem to be especially prominent for verbal and visuospatial working memory, and have generally been found in both males and females (Browne et al., 2015;Collaer et al., 2016;Karlsson et al., 2017). However, one study found males in particular to be affected on non-verbal intelligence (Karlsson et al., 2017).
The underlying neural mechanisms leading to cognitive impairments in individuals with CAH have not yet been fully elucidated. Glucocorticoids are known to impact structural development of the brain by affecting neuronal differentiation, cell proliferation and dendritic arborisation (Morsi et al., 2018;Shirazi et al., 2015), which might ultimately lead to changes in grey matter density (Stomby et al., 2016). In addition, optimal cognitive performance requires precisely regulated blood levels of cortisol (Het et al., 2005), which are not easily attained by standard GC replacement therapy. Elevated cortisol levels affect the functional organisation of the brain, both at rest and during memory performance and emotion regulation (Hakamata et al., 2017;Veer et al., 2012;Wu et al., 2015). Thus, GCs could alter both the structural development of the brain and the functional activation during cognitive tasks.
Several reports, mostly based on single cases, have found an increased incidence of white matter abnormalities and temporal lobe atrophy in subjects with CAH (Bergamaschi et al., 2006;Mnif et al., 2013;Nass et al., 1997;Samia et al., 2010). Further, female CAH patients have been found to have impairments in white matter microstructure and reduced volume of subcortical regions and the cerebellum (Webb et al., 2018). Recently, using automated quantitative analyses of T1 data, we have shown structural alterations of grey matter, in both male and female CAH patients, in fronto-parietal and default-mode networks that are known to be involved in working memory function ( Van't Westeinde et al., 2019). Indeed, working memory performance correlated with structure of some of these regions, in particular in the superior occipital and parietal cortex ( Van't Westeinde et al., 2019). Alterations in brain structure may emerge already at a young age, since a study on youth with CAH between 8 and 18 years old found smaller relative volumes of the bilateral middle frontal cortex, left hippocampus and sub-regions of the hippocampus (CA1, subiculum) and amygdala (lateral nucleus) (Herting et al., 2020). These observations suggest that the working memory network is particularly vulnerable for imbalances in GC exposure during development. The observed structural changes might underlie differences in functional activation of the brain, leading to aberrant performance on visuospatial and verbal working memory in patients with CAH.
The aim of the present study is to investigate differences in functional activation of the brain during verbal and visuospatial working memory performance between patients with CAH and controls using functional magnetic resonance imaging (fMRI). In addition, we aim to test if sex modulates this effect. Based on our previous work, we expect reduced working memory performance in patients with CAH, and differences between CAH and control patients in functional activation in particular in the fronto-parietal networks during working memory performance.

Subjects
We report how we determined our sample size, all data exclusions, all inclusion/exclusion criteria, whether inclusion/ exclusion criteria were established prior to data analysis, all manipulations, and all measures in the study. Participants were recruited as part of a longitudinal medical study investigating the long-term consequences of pre-and postnatal glucocorticoid treatment of CAH. The general study includes patients with CAH, subjects at risk of CAH treated prenatally with dexamethasone (DEX), both with and without CAH, and untreated controls (C) from the Swedish population. For this report, we focussed on patients with CAH, treated with GC postnatally but not with DEX prenatally, and untreated controls, all !16 years of age. Subjects with a reported history of neuropsychological problems and/or current medication for a psychiatric disorder or central stimulant treatment were excluded from the MRI analyses (2 CAH, 5 C). Moreover, 10 subjects (7 CAH, 3 C) were excluded from the analyses because c o r t e x 1 5 9 ( 2 0 2 3 ) 1 e1 5 of excessive head movements during the scanning sessions (i.e. head displacement > 3 mm). One participant was excluded due to ventricular dilation, and one participant was excluded due to signal loss in the frontal cortex related to metallic braces. Included in the final analysis were 29 patients with CAH without DEX treatment (17 female) and 40 controls (24 female). Among the CAH group, there were two pairs of siblings. Among the control group, there were two subjects who are siblings to two individuals in the CAH group. All subjects were 16 years or older (mean age ¼ 21.88 y standard deviation ¼ 4.09 y, range ¼ 16e33). Groups differed in terms of age (F (1.67) ¼ 12.18, p < .001), with patients being approximately three years older than controls (mean age CAH ¼ 23.76 y, SD 4.98, range ¼ 16e33; mean age controls ¼ 20.53 y, SD 2.64, range ¼ 16e25).
In the control group, two subjects had Arnold-Chiari malformation type 1, four had minor white matter changes, and two had a Rathkes cyst. In the CAH group, three subjects had Arnold-Chiari malformation type 1, and five had minor white matter changes. Testing times for participants ranged between 9am and 6pm and did not differ significantly between patients with CAH and controls (t ¼ À.800, p ¼ .427). In the patient group, 24 were right-handed, one was left-handed and for 3 participants handedness information was missing. In the control group, 36 were right-handed, 3 were left-handed and for one participant handedness information was missing. Demographic information is presented in Table 1. Patients with CAH had a higher education level. There were no differences between groups regarding general well-being or consumption of alcohol, drugs or smoking. All participants, and parents of minors, gave their informed consent to take part in the study. The study was approved by the Regional Ethical Committee of Karolinska Institutet (Dnr 99e153 and 2011/1764e32).

Procedures
The present manuscript follows the same procedure as has been described in an earlier publication ( Van'tWesteinde et al., 2020). For ease of understanding, we briefly summarize the procedures here. Participants underwent magnetic resonance imaging (MRI) to obtain anatomical (T1), diffusion tensor imaging (DTI) and functional MRI (fMRI) scans (task fMRI, resting-state fMRI). Imaging was followed by questionnaires measuring wellbeing/life style. This session took about 120 min, including 70 min in the MR scanner. Other sessions conducting psychological testing on the participants are described elsewhere (Karlsson et al., 2017).

Working memory tasks
Participants completed one verbal working memory (WM) and one visuospatial WM task during the fMRI session. Both tasks followed a similar setup during which participants were asked to remember a series of 5 items (verbal WM: letters; visuospatial WM: dot locations on a 4 Â 4 grid, see Fig. 1) and were afterwards probed for the position of one of the items, e.g. "was the third letter a B?", or "was the second dot in this location"? Participants were asked this question on half of the trials, so-called "probe" trials. Participants responded by button press, using their right index and middle fingers for yes or no respectively. Trials belonged either to the experimental or the control condition, where the control conditions always consisted of 5 of the same items in a row. Per task, 96 stimuli were shown (48 experimental/working memory trials, 48 control trials; 24 0 probe-trials' each). After half of the trials, a 1min break was introduced. Therefore, task duration was close to 16 min, depending on participants' response speed. Further details may be found in (Van'tWesteinde et al., 2020).

Behavioural analyses of the working memory tasks
Behavioural performance during WM tasks was monitored and stored for offline analyses using R (v3.6.1) software (Team, 2013). Reaction times (RT) were calculated from correct responses in probe trials and accuracy was measured as the number of correct responses. One male control and one male CAH patient were excluded from the analysis of the spatial WM task due to less than 50% response of the trials, presumably due to incorrect finger placement on the response device (button box).
General task effects were analysed on reaction times and accuracy by using Student's t-test to compare performance between the two tasks across all participants. In addition, separate t-tests were conducted to test the effect of trial type (experimental vs control) on accuracy and reaction time on both tasks separately. Inverse efficiency (reaction time/accuracy) was calculated given the possibility of speed-accuracy trade-offs. Efficiency is higher when subjects have higher accuracy at the same reaction time, or respond with the same accuracy in shorter time.
Group differences in working memory performance were analysed using linear regression models to predict accuracy, reaction time and inverse efficiency on the verbal and visuospatial working memory tasks with diagnosis (CAH or control), and with sex, age, education level and time of the day at which participants were scanned as covariates. Time of scanning was considered because performance improved and brain activity increased when tested in the afternoon compared to in the morning in healthy controls (data not shown). The interaction effect between CAH and sex, while controlling for age and time of scanning, was tested on accuracy, reaction time and inverse efficiency. These estimates were assessed for experimental and control trials separately.
Estimates were considered to be significant at p < .05.

Image acquisition and analyses
The same imaging acquisition and analyses pipeline was followed as in a previous publication ( Van'tWesteinde et al., 2020). Briefly, all images were acquired on a 3 T Discovery MR750 scanner (GE Healthcare, Little Chalfont, UK), with an 8channel head-coil. Anatomical T1 images were acquired with a T1-weighted BRAVO sequence (176 slices, voxel size: 1 Â 1x1 mm) and two fMRI scans during execution of a working memory task each (480 volumes, 16 min each, wholebrain T2*-weighted echo-planar images (TR ¼ 2 sec, Table 1 e Demographic data. CAH (congenital adrenal hyperplasia); C (control); f (female); m (male).

Pre-processing
Analyses were done with FSL 6.0's FEAT tool (Woolrich et al., 2001(Woolrich et al., , 2004. Exclusion criteria for image quality were established prior to analyses. Only scans from people with <3 mm head displacement were included. Anatomical scans were brain-extracted (FSL brain extraction tool) (Smith, 2002), segmented (FAST) (Zhang et al., 2001), and normalised to the MNI standard brain. Pre-processing of functional images consisted of MCFLIRT motion correction, slice-time correction (interleaved), and co-registration the structural image. Functional image normalizations to the MNI template were calculated and spatial smoothing was applied (5 mm fullwidth-at-half-maximum Gaussian kernel). ICA-AROMA was used to remove noise components (Pruim et al., 2015a(Pruim et al., , 2015b. The cleaned time series were used in the first-level FEAT analyses. Linear regression models showed there was no difference between CAH and controls, and no interaction between diagnostic group and sex, for absolute (mm) nor for relative (mm) motion as assessed by FEAT, for neither the verbal nor the visuospatial scan.

First level analyses
For each WM task, custom wave functions were constructed for the encoding and decoding phases of each trial type, where the encoding phase consisted of the time during which the participants viewed and learned the trial, while the decoding phase consisted of the time during which the question was asked and participants responded, which was set to a time of 0s (immediate), and for the button press, the rest-period inbetween blocks, missed responses and six motion parameters from MCFLIRT. All regressors were convolved with a double gamma haemodynamic response function (HRF) and its temporal derivative. Temporal filtering was applied by high-pass filtering with a cut-off of 128s. In an additional analysis, the encoding and decoding phases were collapsed. Parameters estimates (PEs), reflecting brain activity during working memory performance, were obtained by maximum likelihood estimation for the contrasts experimental vs control (and vice versa) for encoding and decoding, and for encoding and decoding combined.

Second level analyses
The group difference (CAH vs Control) on parameter estimates for all contrasts (experimental vs control, for encoding and decoding, and for encoding and decoding collapsed) was tested using FSL's randomise tool with 10.000 permutations (Winkler et al., 2014;Woolrich et al., 2004), with sex, age, time of scanning and education level as covariates. In addition, we tested the interaction between diagnostic group and sex. Threshold free cluster enhancement (TFCE) was applied with an alpha level of <.05. Significant clusters were localized with the HarvardeOxford cortical and subcortical atlases and clusters are reported that exceeded a z-threshold of 3.1. For the contrasts revealing a significant interaction with sex, posthoc t-tests were conducted on the extracted parameter estimates of the significant clusters to compare patients to controls for males and females separately.

Group characterisation and association between brain activity and WM performance
Due to the small sample size, we were interested in investigating which individual participants were contributing to the observed differences. Mean parameter estimates were therefore extracted from the clusters where a significant group difference was found, i.e. estimates of the mean activity in each cluster for each individual, using Featquery, and plotted for males and females separately. To do this, region of interest masks were created for each of the five clusters where we found a significant difference, using fslmaths. Featquery gui was then used to obtain an estimate of mean "activity" from each participants' first-level analyses, within these ROIs. We used linear regression models to test if there was an association between mean parameter estimates in those clusters and age, medication dose, medication group (hydrocortisone or prednisolone), phenotype and genotype, within the CAH male and female groups. We further used linear regression models to test the association between parameter estimates of the clusters and performance on the working memory tasks for males and females with CAH. For all analyses of mean PE's, R (v3.6.1) software was used (Team, 2013).

Brain structure associated with task activation
Previously we have shown that differences in brain structure exist between subjects with CAH and controls (Van't c o r t e x 1 5 9 ( 2 0 2 3 ) 1 e1 5 Westeinde et al., 2019). We were interested in testing if those structural differences are associated with the functional activation during the WM task, as they might be related to the between group difference in activity. We therefore created seven regions of interests (ROIs) corresponding to the regions found in our previous publication, but based on the Desikan atlas in FreeSurfer (Desikan et al., 2006), to avoid overestimation of the associations. These gave mean cortical thickness of the bilateral rostral middle frontal gyrus, left superior parietal cortex and right inferior parietal cortex; mean cortical volume of the left precuneus; and mean cortical surface area of the left cuneus and right pericalcarine cortex. We tested the association between mean structural estimates of these 7 regions with mean activity (PEs) of the clusters that showed a significant group difference in the CAH female and male groups separately, using linear regression models with ROIs predicting PEs, with age as a covariate. FDR correction for 7 structural ROIs was applied.

3.1.
Behavioural results of the working memory tasks General task effects: Reaction times for the verbal task were longer than reaction times for the visuospatial task (df ¼ 66, t ¼ À15.31, p < .001), whereas accuracy was comparable between the verbal and visuospatial tasks (df ¼ 66, t ¼ 1.53, p ¼ .132). Moreover, we observed significant effects of trial type on both outcome measures, with longer reaction times and lower accuracy for experimental trials compared to control trials (Spatial Task:  There were no interactions between diagnostic group and sex (all p > .05) on any of the tasks, estimates and trial types.

3.2.
Neuroimaging resultseverbal working memory Overall, the task activated an expected network spanning left and right prefrontal cortex, inferior and superior parietal cortex, inferior occipital gyri, thalamus and cerebellum (Fig. 3A, blue colours). No group differences in brain activity between CAH and controls were observed during the verbal working memory task, and not when only including patients with SW CAH either. There were no interactions between diagnostic group and sex.

Neuroimaging resultsevisuospatial working memory
The visuospatial task elicited a similar expected network as the verbal task, however it was more elaborate and included regions involved in the dorsal visual stream, in particular the superior occipital gyrus (Fig. 3A, yellow-red colours). No significant group differences were observed between CAH and controls when assessing the whole group, and not when only including patients with SW CAH either. However, there was a significant interaction between diagnostic group and sex in the entire cohort during the decoding phase of the experimental condition in five clusters with >100 voxels.

3.4.
Group characterisation and association between brain activity and WM performance Table 2 displays the mean parameter estimates (PE) and demographics for males and females with CAH. We plotted the overall mean activity in the regions that showed a significant interaction between group and sex, for males and females separately (Fig. 5). The increased activity in the all clusters is observed in all the CAH males (Fig. 5, left panel). For example, even the CAH male with the lowest activity in the Left Parietal-Occipital Cortex (À370.8) had a mean PE well above the average of controls (À508). Thus, there was no specific group of individuals driving the group difference for the males. Linear regression within the CAH male group showed a negative association between mean parameter estimate for the Left Parietal-Occipital Cluster and age (B ¼ À162.14, p ¼ .010), suggesting that older CAH males had less strong activation during decoding in this cluster only. When correcting for age, activity in the Right Lateral Superior Occipital Cortex was associated with slower reaction times (B ¼ .20, p ¼ .002), but greater inverse efficiency (B ¼ .22, p ¼ .005). There was no association between mean PE of any of the clusters and genotype, phenotype or medication dose or medication type (hydrocortisone or prednisolone) in CAH males. In females, there was a bit more overlap between CAH females and control females, but still, all but three to four CAH females showed a mean PE lower than the average of control females (Table 2B and Fig. 5, right panel). Linear models showed there were no relationships of any of the clusters with age, genotype, phenotype or medication dose, medication type (hydrocortisone or prednisolone) or working memory task performance in CAH females. Fig. 2 e Performance during the experimental condition of the A) verbal working memory task and B) visuo-spatial working memory task. Reaction times are given in milliseconds, and accuracy as number of correct responses. Each individual is represented as a dot. The limits of the box show the borders of the third and first percentile, while the line in the middle represents the median. The upward whisker extending from the box represents the largest value within 1.5 times the interquartile range above the third quartile (75%), while the downward whisker represents the smallest value within 1.5 times the interquartile range below the first quartile (25%). c o r t e x 1 5 9 ( 2 0 2 3 ) 1 e1 5 3.5.

Brain structure associated with task activation
Because a significant interaction between CAH and sex was observed for the contrast experimental vs control during decoding of the visuospatial working memory task, structureefunction associations were tested in males and females with CAH separately for this test only, for regions of interest based on our previous group comparison ( Van't Westeinde et al., 2019). No associations between function and structure survived FDR correction in either sex.

Discussion
The present study assessed brain activity during verbal and visuospatial working memory in patients with CAH. Patients responded faster on the verbal task compared to controls, but there were no differences for accuracy or efficiency. There were no group differences in brain activity during verbal working memory, and not during the encoding phase of the visuo-spatial task either. Sex specific differences in brain Fig. 3 e A) Activation maps of the two working memory tasks in patients with CAH encoding (top, right hemisphere is shown on the sagittal plane) and decoding (bottom, left hemisphere is shown on the sagittal plane) of the verbal WM task (blue), visuospatial WM task (yellow-red), and the overlap between verbal and visuospatial (green). B) Examples of regions with a significant interaction between group (CAH; control) and sex (male; female) during decoding of the visuospatial working memory task. Clusters were considered significant at p < .05 TFCE corrected. Activation in the image is limited at z ¼ 2.57 (p < .01). The colour bars indicate z-scores: red-yellow indicates increased activity; the more yellow indicates a greater z-score (i.e. a lower p-value).
activity were identified in patients only for the decoding phase of the visuospatial working memory task. Males with CAH had increased activity compared to control males in a brain network encompassing the left inferior parietal cortex, precuneus, cuneus and posterior cingulate cortex, bilateral lateral superior occipital cortex, bilateral cerebellum (Crus I and VI) and right frontal pole, while females with CAH showed decreased activity in these areas compared to control females. The faster responses on the verbal task do not correspond to our previous findings of impaired verbal and visuospatial working memory in the same cohort (Karlsson et al., 2017). In that study, we found reduced accuracy of patients with CAH, whilst in the present study, patients are faster, but not significantly less accurate or efficient. High accuracy from both controls (around 90% correct) and CAH patients (around 85% correct) suggests that the task performed in the scanner may have been relatively easy compared to the WAIS Digit Span and the WMS Span Board test used in our previous assessment where we did find impairments in patients with CAH (Karlsson et al., 2017). Importantly though, these working memory tasks, i.e. the Span Board test and the Digit Span, are only assessing accuracy and not reaction time. It is therefore possible that patients do in fact respond faster during working memory tasks, which may be due to differences in motivation, or actual biological effects.
The lack of an overall group difference in brain activity during working memory suggests that patients are able to achieve a similar level of brain activity as controls, as reflected in the BOLD response, despite having smaller brains and thinner cortices in key nodes of the working memory network that we found previously in this cohort (Van't Westeinde et al., 2019). However, we did find significant interactions between diagnostic group and sex in functional activity in a brain network encompassing the left inferior parietal cortex, precuneus, cuneus and posterior cingulate cortex, bilateral lateral superior occipital cortex, bilateral cerebellum (Crus I and VI) and right frontal pole during the decoding phase of the visuospatial task. The observed regions are well known to be involved in visual working memory (Machizawa, Driver, & Watanabe, 2020), are part of the fronto-parietal working memory network (Eriksson et al., 2015) and were also active during the encoding phase of the tasks in both patients and controls. The bilateral superior occipital cortex and the angular-and supramarginal gyri are part of the dorsal visual stream (Milner & Goodale, 2008;Sack & Schuhmann, 2012;Valyear et al., 2006), while the precuneus is a major brain-hub Fig. 4 e Bars represent mean parameter estimates of activity of each of the clusters where a significant interaction between CAH and Sex was observed, per group, per sex. Error bars indicate standard errors of the mean. Left Parietal-Occipital Cortex ¼ the combined mean parameter estimates of the local maxima in the left parietal and left lateral superior occipital cortex. A parameter estimate has an arbitrary unit as it is unrelated to the cluster size but rather depicts "activity". A.u. ¼ arbitrary unit. *** ¼ p < .001, ** ¼ p < .01, P* ¼ p < .05, ns ¼ not significant, the p-values are based on post-hoc t-tests. c o r t e x 1 5 9 ( 2 0 2 3 ) 1 e1 5 involved both in the default-mode network at rest, and the fronto-parietal network during working memory performance, when it helps divert attentional resources towards sensory integration areas (Utevsky et al., 2014). Further, the posterior cingulate cortex is a major node of the default mode network itself (Raichle, 2015). Activity of the left parietal and lateral superior occipital cortex in particular have been associated with both capacity and precision of items that can be retained in visual memory (Galeano Weber et al., 2016Machizawa et al., 2020;Todd & Marois, 2005), though even the right lateral superior occipital cortex was differentially activated in our sample.
As there were no group differences in performance for the visuo-spatial task, it might be suspected that the differences in BOLD signal are a compensatory mechanism, even though it is not clear why this would entail increased activation in males, but decreased activation in females. Such compensatory mechanisms have also been observed in patients with mild cognitive decline due to aging, where a minor pathological change can still be compensated for by increased effort (Cl ement et al., 2013). However, within the male group, stronger activity was associated with slower reaction times. Thus, males with more "normal" brain activity actually were faster. This makes it unlikely that the activity differences are part of a genuine compensation mechanism. Moreover, female patients had reduced activity compared to controls, which is hard to explain in terms of compensatory activity, although not much is known about nature of compensation mechanisms themselves. It may also be noted that increased brain activity has been found during working memory in association with increased motivation (Krawczyk & D'Esposito, 2013). We cannot exclude the possibility that (male) patients may have been more motivated to perform the task. On the other hand, motivation does not explain the difference of effect between the sexes either.
The opposite effects in terms of BOLD responses between males and females are interesting given that the observed regions seem to display an inherent sex-difference in terms of their intrinsic organisation. For example, healthy women appear to have higher functional connectivity in the cuneus, precuneus, supramarginal gyrus and inferior parietal cortex, along with higher grey matter density in the parietal and occipital cortexes, despite having smaller brain volumes (Tomasi & Volkow, 2012). Such inherent organisational differences might go hand in hand with different responses to illness, in particular in terms of brain function, potentially in response to changes in structure that are apparently found in both sexes ( Van't Westeinde et al., 2019). Excess androgen levels could be a potential contributor to this gender incoherence (Bejerot et al., 2012;Nordenstrom et al., 2002), even though it is nowadays thought that the impact of the disease and GC treatment likely overrides the impact of excess androgen exposure. This idea is further in line with the lack of sex difference in cognitive function and brain structure in our cohort.
The differentially activated regions in patients partly correspond to the regions showing alterations in grey matter structure in the same, slightly larger, cohort, where patients with CAH had reduced volume of the left precuneus and reduced thickness of the bilateral middle frontal gyrus, left  individual is represented as a dot, to visualize the variation of mean cluster activity between participants. The limits of the box show the borders of the third and first percentile, while the line in the middle represents the median. The upward whisker extending from the box represents the largest value within 1.5 times the interquartile range above the third quartile (75%), while the downward whisker represents the smallest value within 1.5 times the interquartile range below the first quartile (25%).
c o r t e x 1 5 9 ( 2 0 2 3 ) 1 e1 5 superior parietal cortex and right inferior parietal cortex ( Van't Westeinde et al., 2019). We therefore considered the possibility that altered activity in the left precuneus, superior occipital and inferior parietal network might be associated with, or is a result of, reduced volume and thickness in these regions, or functions as a compensatory mechanism for reduced thickness in other regions of the network, such as the middle frontal gyrus and right inferior parietal cortex. However, none of the associations were significant after multiple comparisons correction. The precise relationships between structure and function therefore need to be studied in future analyses based on larger cohorts using multi-modal independent component analyses or other methods to assess structureefunction correlations. Indeed, even though structure and function may contribute independently to working memory performance (Evangelista et al., 2020), long-term illness may lead to large-scale brain reorganisation with complex interactions between structural and functional networks (Menon, 2011). The mechanisms underlying the observed alterations remain to be elucidated. They might be the outcome of a longterm developmental process in which glucocorticoid disturbances, salt-wasting crises and imbalances in other metabolites have contributed to alterations in both brain structure and functional networks at adult age. Interestingly, the dorsal visual stream, which develops from around 7 weeks after birth, might be more sensitive than other paths to disturbances in early life and might therefore be particularly affected by neonatal salt-wasting crises or sub-optimal glucocorticoid replacement (Braddick et al., 2003). Further, as suggested in our previous report, parietal areas, in particular the precuneus, might be more vulnerable to cortisol imbalances due to the high energetic demand, rather than the density of GC-receptors per se (Van't Westeinde et al., 2019). Indeed, altered cortisol levels have been shown to affect the metabolic rate in the middle frontal gyrus and precuneus (Liu et al., 2018), as well as the coupling between cerebral blood flow and functional connectivity of the precuneus, potentially due to the effect of cortisol on neurovascular coupling (Zhang et al., 2020).
However, overall, we found very few differences between patients and controls in terms of brain activity in the present study, with patients responding faster than controls on one of the tasks. Therefore, the interaction between CAH and sex found during this specific part of one of the tasks needs to be seen as a finding from an exploratory analysis that may be used as inspiration for future studies.

Limitations
Firstly, our sample is small due to the rarity of CAH and power calculations are at the moment difficult and hard to interpret for fMRI studies. Sub-group analyses should therefore be considered as merely exploratory in nature. The high accuracy in the experimental conditions of the tasks suggests that the employed tasks may have been relatively easy. Employing a more difficult working memory task, such as an n-back task, might lead to more profound differences between groups, both in terms of behavioural performance, as well as in terms of neural activity. Further, we did not measure cortisol levels and hence, we are not able to investigate the relationship between current cortisol levels and performance on the task or brain activity. Finally, the CAH group was older than the control group, which, even though age was used as a covariate, could have reduced the power to find group differences. In addition, patients had on average achieved higher education, which was most likely an age-related difference. In our sample, older male patients had reduced activity in one of the clusters. Hence, real group differences between patients and controls may have been obscured because of the age difference.

Conclusion
Individuals with CAH have largely similar neural activity during working memory as controls, but there may be sexspecific changes during visuo-spatial WM. These findings add to the evidence that long-term glucocorticoid imbalances lead to brain and cognitive changes, especially related to working memory function.

Data availability
The datasets generated during and/or analyzed during the current study are not publicly available but are available from the corresponding author on request. Our GDPR regulation specified in the informed consent signed by participants explicitly states that all data is available only to members of the research group. To obtain the data, a data transfer agreement needs to be made with Karolinska Institute, requiring new approval based on the research plan provided by the researcher requesting the data. Experimental stimuli and analysis code are stored in an OSF storage: https://osf.io/ g876p.

Pre-registration
No part of the study procedures or analyses have been preregistered prior to the research being conducted.

Statement of ethics
The study was approved by the Regional Ethics Committee of Stockholm (no. 99e153 and 1658e32) and all participants and parents of children <18 years of age gave their informed consent before study inclusion.

Funding sources
This work was supported by the Marianne and Marcus Wallenberg Foundation, the International Fund raising for Congenital Adrenal Hyperplasia (IFCAH)/European Society for Pediatric Endocrinology (ESPE), the Stockholm County Council (ALF-SLL), Swedish Research Council (DNR 2021e02440), c o r t e x 1 5 9 ( 2 0 2 3 ) 1 e1 5