Micro‐ and macroclimate interactively shape diversity, niches and traits of Orthoptera communities along elevational gradients

Temperature is one of the main drivers shaping species diversity and assembly processes. Yet, site‐specific effects of the local microclimate on species and trait compositions of insect communities have rarely been assessed along macroclimatic temperature clines.


| INTRODUC TI ON
Climate change is causing a restructuring and reassembly of biotic communities worldwide (Habel et al., 2016;Halsch et al., 2021;Hill et al., 2021).Mountain regions are particularly at risk as temperatures rise rapidly there (Nigrelli & Chiarle, 2021;Pepin et al., 2015) while they serve as exceptionally important refugia for cold-adapted and often endemic species (Berger et al., 2010;Laiolo et al., 2018;Trew & Maclean, 2021).Since air temperature declines steadily with elevation (lapse rate of ~−5.5 K/1000 m), gradients along mountain slopes can be used as space-for-time surrogates to study community assembly processes and anticipate species' responses to climate warming (Körner, 2007;Rahbek et al., 2019).However, the temperature conditions species are exposed to within their habitats are not only determined by the elevational macroclimatic gradient per se but also significantly modified by local conditions-the microclimate (Kankaanpää et al., 2021;Ohler et al., 2020;Scherrer et al., 2011).As the microclimate can buffer changes in the macroclimate (Bennie et al., 2013;Senf & Seidl, 2018;Stark & Fridley, 2022), neglecting it may lead to an overestimation of species' responses to climate warming (Scherrer et al., 2011).Yet, the scale at which species respond to climatic variation (micro vs. macro) depends on the size, area requirements and dispersal distances of species (Poggiato et al., 2023), and studies on how the interplay of both facets of climate shapes biological communities in mountain regions remain inconclusive (Potter et al., 2013).
Despite facing above-average temperature increase (Pepin et al., 2015), mountains provide a variety of microclimatic conditions in proximity based on differences in aspect/orientation/exposition and slope (topographic heterogeneity), radiation, wind speed, substrate and vegetation structure at the meso-and microscale (Albrich et al., 2020;Körner & Hiltbrunner, 2021;Ohler et al., 2020;Rita et al., 2021).Especially on sunny days, soil temperatures of northand south-facing slopes can differ starkly at similar elevations, comparable to differences expected from about 500 m elevational difference for seasonal average soil temperatures (Ohler et al., 2020;Scherrer et al., 2011), with hottest conditions reached at steep sunfacing slopes with low vegetation cover (Maclean et al., 2019).This climatic heterogeneity facilitates the persistence of species with diverging niches in proximity, resulting in high rates of β-diversity in mountains (Fontana et al., 2020;Sponsler et al., 2022;Tello et al., 2015;Zografou et al., 2017).Within such a mosaic of climatic conditions, species are known to match their climatic requirements by macroclimate-dependent preferences for specific suitable microclimates (relative niche consistency, Dobrowski, 2011;Feldmeier et al., 2020), but this has rarely been linked to species traits.
Rapid range shifts of insect communities to higher elevations in mountain regions due to temperature increase have been shown (Kerner et al., 2023;Maihoff et al., 2023;Ogan et al., 2022).
However, responses to increasing temperatures are species-specific (Engelhardt et al., 2022;Hickling et al., 2006;Neff et al., 2022;Poniatowski et al., 2020).Since certain ecological and morphological traits can be beneficial under either warm or cold climatic conditions, they determine distribution patterns of species along climatic gradients (Chichorro et al., 2022;Classen et al., 2017;Hoiss et al., 2012;Leingärtner et al., 2014;Peters et al., 2016).At high elevations, shortgrowing seasons and cold temperatures shorten the time available to complete a life cycle, demanding thermoregulatory adaptations (e.g.faster heating colour phenotypes, Dieker et al., 2018;Fernandez et al., 2023;Harris et al., 2013;Köhler & Schielzeth, 2020) and rapid development, which is associated with small adult body size (Berner et al., 2004;Levy & Nufio, 2015;Tiede et al., 2018), or early hatching phenology to prolong the season (Ingrisch & Köhler, 1998;Kankaanpää et al., 2021).Additionally, the reduction of wing length independent of body size is a common adaptation in cold environments (Laiolo et al., 2023;Leihy & Chown, 2020;Tiede et al., 2018), as it may be advantageous to allocate resources to reproduction rather than wing development (energy trade-off, Hodkinson, 2005;Laiolo et al., 2023;Tiede et al., 2018).Cold habitats may also require utilizing a broad range of food items, thus favouring less specialized species (König et al., 2022;Pitteloud et al., 2021;Rasmann et al., 2014).Despite the urge to understand the position of species' climatic niches to estimate potential threats for the systems in the context of climate change, it is largely neglected how microclimate interacts with macroclimate to form the climatic niches of species and how trait combinations promote or constrain the use of microclimatic refugia under a warmer macroclimate according to predictions.

Evidence for climatic filtering processes has been demonstrated
by approaches based on mean trait values without considering intraspecific variability, assuming that the difference in functional trait values between species is larger than within species (Jung et al., 2010).However, a growing number of studies have suggested that intraspecific variability can hint on underlying filtering mechanisms (Classen et al., 2017;Jung et al., 2010;Laiolo et al., 2023;Tiede et al., 2018).
preferences and phenology, highlighting the importance of mountains for conservation as climatic refugia where species with diverging niches can persist in proximity.
Hence, the distribution of Orthoptera species in Europe is predominantly determined by climatic conditions, leading to diversity decreases towards northern latitudes and high elevations, which are characterized by less favourable climatic conditions and, therefore, shorter seasons (Geppert et al., 2021;Hochkirch & Nieto, 2016).The specific demands of Orthoptera to the microclimate of their habitat make them suitable indicators for environmental changes (Bazelet & Samways, 2011;Fartmann et al., 2012).
Here, we ask: How does the interplay of macro-and microclimate drive diversity patterns and the assembly of insect herbivore communities?To answer this question, we studied orthopteran assemblages along an elevational gradient in a topographically heterogeneous  S1).(4) Intraspecifically, body sizes, wing lengths and coloration should follow the same clines as the community-level trait patterns.

| Study region & study sites
We studied Orthoptera communities at grassland sites on calcareous bedrock along elevational gradients in southern Germany (Bavaria).above sea level (m a.s.l.) elevation (Figure 1) (Hoiss et al., 2013).The tree line is on average just above 1500 m in this region (Sponsler et al., 2022).When selecting the sites, we took special care to ensure a balanced and even distribution of orientation and elevation spanning five elevational zones (submontane: 600-825 m a.s.l., montane: 825-1200 m a.s.l., high montane: 1200-1500 m a.s.l., subalpine: 1500-1825 m a.s.l. and alpine zone: 1825-2150 m a.s.l.).By focusing on a single mountain region, we attenuate large-scale spatial variation in the species pool resulting from historical or biogeographical circumstances, which allows direct inference on assembly processes caused by local climatic variation.All grassland sites were either extensively managed (n = 48; one cut per year on meadows, extensive cattle or sheep grazing on pastures with 0.5-1.5 livestock units per ha) or unmanaged (n = 45).The established grassland study sites covered 60 × 60 m each.

| Climatic variables
We used the mean elevation of the study sites as a proxy for macroclimatic temperature variation along the gradient (hereafter referred to as macroclimate/elevation, correlation with summer-seasonal mean temperature derived from a climate model based on neighbouring local climate station temperature data: r = −.98,df = 1,92, p < .001;Kerner et al., 2023).At each of the study sites, we additionally recorded temperature in 2-h intervals from June to October 2020 with three covered temperature loggers (ibuttons, Maxim Integrated) installed 2 cm above the soil level in the vegetation to account for average near ground temperature deviations from macroclimate resulting from vegetation structure, aspect/orientation, inclination/slope, exposition, topography, wind speed, solar radiation, atmospheric moisture and cloud cover (Hodkinson, 2005;Hoiss et al., 2013;König et al., 2022).
From the logged temperatures, we calculated the mean of daytime and nighttime temperatures during the sampling period from June to October.The local microclimate was defined as the residuals of a regression of the in-field measured average temperatures with the modelled macroclimatic temperatures at the site and therefore represents local temperature deviations near ground.Positive values for microclimate indicate, on average, warmer microclimatic temperature conditions at the study site than expected based on its elevation (Figure S1).

| Orthoptera field surveys
To record orthopteran communities, we conducted two surveys at all study sites.To ensure a comprehensive sampling of species across seasons, we pooled together the results of the two surveys, one early (beginning of July 2020 to end of August 2020) and one later in the season (end of August 2020 to end of October 2020).The order of sampling at the sites followed the phenology from the valleys to the summits.Each of the two variable transect counts per site consisted of five subtransects of 10 min within the plots margins to cover most of the microhabitat variation (König et al., 2022).We carried out the surveys on warm, sunny days, representing maximum activity conditions for most Orthoptera in the region (König & Krauss, 2019).
Orthoptera species were identified by their stridulation and visually in field.Additional late afternoon surveys with bat detectors and vegetation beatings were performed to also record species with late and high-pitched song activity as well as tree-dwelling species.
Grylloids and Tetrigids were additionally recorded in May and June by listening to their songs (evening/night) or specific search in suitable microhabitats, respectively.Due to low detectability, we excluded the soil-dwelling species Myrmecophilus acervorum from sampling results, leading to near complete assemblage assessments.
Recorded abundances of the species from the two surveys and the additional assessments were aggregated at site level to focus on community patterns along the climatic gradients.We restricted our analyses to data gathered on adult specimens as identification of nymphs in field is difficult for several species.
Species-level morphological traits included were mean female body size, relative wing length of females and the predominant body coloration of the species (brown/green).We decided to include morphometrical measurements (Detzel, 1998;Harz, 1969Harz, , 1975) ) of females rather than males due to the sexual dimorphisms of many Orthoptera species (Laiolo et al., 2013(Laiolo et al., , 2023)).Larger species are often capable of producing more offspring than smaller species (Ingrisch & Köhler, 1998).Relative wing length is considered as a measure of resource allocation, where short-winged species may be worse dispersers due to reduced flight ability but invest more into reproduction (Laiolo et al., 2023;Tiede et al., 2018).
Intraspecifically, we measured pronotum lengths as a proxy for body size and wing lengths of two grasshopper species that occur along a broad elevational range with digital callipers to the closest 0.1 mm in field.We selected the Common Green Grasshopper Omocestus viridulus (L., 1758), a graminivorous, long-winged species with broad elevational distribution and no clear preference for warmer sites, and the graminivorous, long-winged Rufous Grasshopper Gomphocerippus rufus (L., 1758), which prefers warm microclimates all along the elevational gradient.Wherever possible, we caught 10 individuals (males and females) at every site each of the two species was present, measuring each parameter twice to reduce measurement error.Additionally, we scored body coloration and colour morphs of O. viridulus (green, dorsal green-lateral brown, brown) in the field to calculate colour morph frequencies.This green/ non-green polymorphism is common in Orthoptera and similar ratios between the sexes in local populations suggest a shared genetic or environmental control (Dieker et al., 2018).
We started our analyses by assessing the impact of climatic variation on Orthoptera assemblages at the community level.First, we employed permutational multivariate analysis of variance (PERMANOVA, adonis2 function in the 'vegan' package) based on Bray-Curtis distances between Orthoptera communities, including elevation, microclimate and their interactive term as fixed effects to study the community compositional dissimilarity (β-diversity).To plot the ordination based on nonmetric multidimensional scaling (NMDS) of the Bray-Curtis dissimilarity matrix, we used the metaMDS function in the 'vegan' package.We then computed β-diversity rates as the abundance-based Bray-Curtis dissimilarities between all pairs of communities within a moving elevational distance window of 200 m to examine at which part of the elevational gradient community composition differences peaked (Descombes, Vittoz, et al., 2017;König et al., 2022).Therefore, we partitioned the total differences into balanced variation in abundances (turnover equivalent of incidence-based β-diversity) and abundance gradients, in which one community is a subset of another (nestednessresultant equivalent of incidence-based β-diversity) with the package 'betapart' (Baselga, 2017;König et al., 2022).Low values in balanced variation indicate a greater proportion of shared species abundances between site pairs, while high values of abundance gradients indicate that communities with low abundances are subsets of communities with high abundances of similar composition (Baselga, 2017;König et al., 2022).We related all β-diversity indices to the mean elevation of each pair of sites as well as to corresponding microclimatic differences and their interaction with beta-regressions (logit-link) using generalized additive models (Wood, 2023), constraining the number of basis functions to three as we expected low complexity of the functions underlying the β-diversity patterns a priori (Pedersen et al., 2019).

Deviations from an intercept-only model indicate non-constant
Bray-Curtis dissimilarity, balanced variation or abundance gradients rates with temperature and microclimate (Descombes, Marchon, et al., 2017;König et al., 2022).Additionally, we tested the effect of elevational difference and microclimatic differences on compositional dissimilarities with permutational mantel tests based on Pearson product-moment correlation.
Second, we used a multivariate hierarchical generalized linear mixed modelling approach (latent variable model) fitted with Bayesian inference to jointly model species elevational and microclimatic niches to assess the impact of climatic variation on species richness, abundance and species-specific responses (Hmsc, Drag et al., 2023;Ovaskainen et al., 2017;Tikhonov et al., 2020).When assessing the impact of the environment on traits, it is necessary to control for the tendency of related species to resemble each other more than species drawn at random from the same tree (phylogenetic independence, Abrego et al., 2017;Münkemüller et al., 2012;Ovaskainen et al., 2017).Therefore, we reconstructed a phylogeny of the occurring Orthoptera species (Appendix S1).
We excluded eight species with low prevalence (occurrence ≤ 10 sites) from the recorded communities, as statistical inference may not be trustworthy, resulting in a data set of occurrences and abundances of 32 Orthoptera species at 93 study sites.
As sampling units, we aggregated the abundances observed at the individual visits to the study sites to yield one abundance estimation per species and study site.Due to zero inflation of our count data, we applied a hurdle approach, that is, one model for presence-absence (probit regression) and another one for abundance conditional on presence (abundance COP model, linear regression of abundances with log-normal error distribution, declaring zeros as missing data, Whalen et al., 2023).
We included the mean elevation of the study sites (linear and quadratic effect) and the sites' microclimatic temperature deviations (microclimate) as focal fixed effects.We allowed microclimate to interact with elevation to capture elevation-dependent differences in microclimatic niches.The site-level random effect controls for additional unexplained variation at the site level on top of the explicitly modelled, uncorrelated climatic covariates (Figure S2A).
Hierarchical modelling of species communities includes a hierarchical structure assessing how species' responses to environmental covariates depend on species traits and phylogenetic relationships (Abrego et al., 2017).Thus, we examined if species with a similar set of traits had more similar climatic niches than species with converging trait expressions.As uncorrelated traits, we included body size, relative wing length, coloration, moisture preference, dietary specialization and hatching phenology (Figure S2B).After determining the phylogenetic signal in the traits (Figure S3), we examined if the variation in species niches after accounting for the species' traits was phylogenetically structured, that is, if closely related species had more similar climatic niches than distantly related species.
We fitted the HMSC hurdle model with the R package 'Hmsc' (Tikhonov et al., 2020)  To address our main study question, how and which traits modulate species responses to elevation and microclimate, we first examined (1) the peak elevations of all species' abundances (elevational/ macroclimatic optima).As we included the first-and second-order polynomial term of elevation, we did not directly infer elevational patterns from the β-and γ-parameters of the single models but derived the predicted elevational peak within the range of sampled elevations for each species from the combined models' full posterior predictive distribution (total effect).( 2) We further assessed which species showed a positive or negative response to microclimate (microclimate slope) with at least 0.95 posterior probability (linear effect across the range of elevations, weighted by the sample frequency within the five elevation bins, resulting in 1000 slopes summarized as median and 0.95 credible intervals (CIs)).( 3) We calculated the elevational abundance peak shift due to microclimate, addressing the interaction between macro-and microclimate as a third climatic niche parameter from the models' posterior distribution.Therefore, we derived the differences between predicted peak elevations for warm microclimate (+1 SD) and for cold microclimate (−1 SD).
Then, we asked if the elevational distribution of median values of species' abundance peaks, their peak shifts and their microclimate slopes (posterior median) could be explained by their traits using phylogenetic generalized least squares regression with maximum likelihood estimation of the phylogenetic signal λ (Orme et al., 2018), since the residual errors are not independent.
To examine the effect of elevation and microclimate on intraspecific trait distributions, we used Bayesian generalized mixed effects models fitted with 'brms' (Brückner, 2018).Thus, we used the empirically measured body sizes, relative wing lengths (tegmen length divided by pronotum length, Gaussian regression with identity-link) and body colouration score frequencies (logistic regression with logit-link) as responses and the mean elevation, microclimatic temperatures and the corresponding three-way interaction with sex as explanatory variables.Furthermore, we included the sampling site as random factor, as well as the species identity as random effect in the models where necessary.
Orthopteran species richness decreased with decreasing macroclimatic temperature along the elevational gradient from 16 to three species (Figure 3a) and abundances decreased from more than 500 to five individuals (Figure 3b).At similar elevations, species richness and abundance were higher at sites with warmer microclimates than at sites with colder microclimates, implying additive effects of micro-and macroclimate on α-diversity (Figure 3).Thus, species richness and abundances approached zero faster at cold sites of high elevations than at sun/south-exposed sites.
Community composition changed along the elevational gradient, with sites characterized by a warm microclimate harbouring different Orthoptera communities compared to those from cold sites, especially in the submontane and montane zone (Figure 3c).
Therefore, Orthoptera β-diversity rates were pronounced at midelevations (where balanced variation of abundances between sites peaked) and decreased towards high elevations (with increasing abundance gradients; Figure 3d, Figure S4, Table S3).The balanced variation of abundances component of β-diversity increased with elevational distance and with microclimatic differences between the study sites (Figure S5).

| Species climatic niches
The diversity patterns emerged from underlying species-level climatic niches.Accounting only for positive and negative effects with 0.95 posterior probability, 94% of the species were more abundant at the low than at the high range limit of the elevational gradient.However, 12 of the 32 species analysed had broad elevational ranges and occurred in all elevational zones along the entire 1.5 km gradient.On average, species abundances showed a hump-shaped pattern and peaked between the submontane and montane elevational zone at around 824 m a.s.l.(range: <600-1410 m a.s.l., Figure 4, Figures S6   and S7, Table S4).
Warmer microclimates were favourable for a high proportion (41%) of the species across the entire elevational gradient (e.g.

Chorthippus eisentrauti, Decticus verrucivorus, Gryllus campestris,
Psophus stridulus, Stenobothrus lineatus, Tetrix tenuicornis), while the remaining 59% did not differ in abundance between warm and cold microclimate with high statistical support, which could either result from a preference for intermediate microclimate, indifferent behaviour or a change in preference with elevation (Figures S6, S8 and S9, Table S5).
Despite relatively broad elevational ranges, our assessment revealed narrow temperature niches for some species, which they either find at sites with cooler conditions in low elevations or at higher, more sun-exposed sites (e.g.Miramella alpina, Omocestus viridulus, Pholidoptera aptera, Pseudochorthippus montanus, Tettigonia cantans).Hence, microclimate effects depended on elevation for those species.Elevational distributions along gradients with warm microclimatic conditions were higher up than those along gradients with cold conditions for most species (Figures S6 and S10).None of the species had a higher occurrence probability with 0.95 posterior probability nor a higher abundance under cold microclimatic conditions at high elevations in the subalpine and alpine zone (Figures S6   and S10, Table S6).

| Trait-environment interactions
Species ecological traits influenced species' climatic niche parameters.Especially, moisture preferences and hatching phenology of species were important predictors for species responses, since brown-coloured, xerophilic and late-hatching species were likely to increase in occurrence probability and abundance at sites with warm microclimates (Table 1).Less xerophilic and mesophilic species peaked in abundance further up the elevational gradient at sites with warm microclimates than at cold microclimates (Table 1).
Akin the effect of microclimate, the warm macroclimate at low elevations supported late hatching species.Likewise, long-winged species mainly occurred in the valleys (Table 1).Although average body sizes at community level got smaller with increasing elevation, the morphological trait body size did not systematically affect the responses to any of the environmental covariates with high statistical support on species level (Table 1).
Furthermore, the predicted community-weighted mean traits changed along the elevational gradient, revealing a consistently higher share of xerophilic, large and late-hatching individuals within the communities at warm microclimate sites (Figure 5).belt around 1500 m a.s.l.; above this elevation, predicted communities mainly consisted of the alpine specialist Miramella alpina and two species with broad environmental niches, Gomphocerippus rufus and prominently Omocestus viridulus, shaping the communities' traits (Figure 5).

Empirical morphometric measurements of pronotum lengths and
relative wing lengths of two Orthoptera species revealed changes for females, but not males, along the elevational and microclimatic gradient with high statistical support (Figure 6, Table S7).Females were generally larger than males and tended to be smaller and with shorter wings (only Gomphocerippus rufus) at high elevations than at low elevations, particularly when microclimatic conditions were cold, whereas male size did neither vary systematically along the macro-nor microclimatic gradient.The proportion of brown colour morphs in Omocestus viridulus populations did not systematically vary with elevation but was higher when the microclimate was warmer (Figure S11, Table S8).
Concerning trait-environment interactions, we detected a moderate phylogenetic signal only for the effect of species moisture preferences on the microclimate slopes and for the effect of diet breadth on the elevational distribution (Table 1).

F I G U R E 3
Effect of microclimatic variation on community-level patterns of Orthoptera communities along an elevational macroclimatic gradient.Predicted species richness (a) and abundance (b) decreased with elevation and were both consistently higher under warm (red lines) than under intermediate (purple lines) and cold microclimatic conditions (blue lines) at similar elevations (numbers indicate the posterior probability of a positive impact of microclimate within each elevational zone).Both elevation (F = 22.97, p < .001,R 2 = .19)and microclimate (F = 6.42, p < .001,R 2 = .06)as well as their interaction (F = 2.86, p = .010,R 2 = .02)influenced the composition of Orthoptera assemblages (c).Compositional dissimilarity between Orthoptera communities was high at mid-elevations, reflected in the abundance-based β-diversity rate (d), which peaked at intermediate elevations and was higher when microclimatic conditions between sites differed, except at high elevations (Table S3).Point colours represent microclimatic conditions at the sites (red = warm, purple = intermediate, blue = cold).Vertical dashed lines separate the submontane, montane, high-montane, subalpine and alpine elevational zone from left to right in (a, b and d).
There is growing evidence that microclimatic conditions modulate the response of species to macroclimatic variation and, therefore, to climate change (Bennie et al., 2013;Mammola et al., 2019Mammola et al., , 2021;;Montejo-Kovacevich et al., 2020;Pincebourde & Woods, 2020;Suggitt et al., 2018).Our study revealed strong patterns of elevational structure in the richness, abundance and β-diversity of mountain Orthoptera communities.Although richness and abundance of Orthoptera peaked in the valleys, community dissimilarity was highest in the montane and high-montane zone.By extending our macroclimatic analysis with microclimatic contrasts between sites, we were able to empirically disentangle effects of local microclimatic and macroclimatic variation not only on the distribution but also on the abundance of a functionally important insect group.Especially sites with warm microclimate supported almost the full spectrum of species, while some were regularly absent at sites with colder microclimate.Thus, we found additive effects of macro-and microclimate for diversity, but many species experienced interactive effects, highlighting an elevation-dependent effect of microclimate, which suggests narrower temperature niches than the elevational distribution indicates.Particularly, moisture preferences and hatching phenology were linked to the differentiation of climatic niches.While both traits explained the response to microclimate, the phenology and wing length also determined the position of the species' macroclimatic niches.

| Orthoptera diversity thrives under warm climatic conditions: Additive and interactive effects of the local microclimate and macroclimate
Mountains are ecological theatres where the interplay of orientation and slope affect the local temperature and water balance, leading to heterogeneous microclimates at small spatial scales (Scherrer et al., 2011).Such topography-based combinations of micro-and macroclimates in mountain areas enable species to track thermally optimal habitats within short distances (Rebaudo et al., 2016).Temperature had the expected strong impact on Orthoptera communities in our study system.Like in many other taxa (Kerner et al., 2023;Maihoff et al., 2023), Orthoptera richness and abundance exhibited an almost monotonic decline with elevation (Descombes, Marchon, et al., 2017;Geppert et al., 2021;Pitteloud et al., 2020), decelerating in the valleys.As mostly thermophilic insects, they are favoured by the rising mean annual temperature towards the valleys since low ambient temperatures limit available biomass and physiological processes, such as metabolism or enzyme activity, leading to reduced performance and fitness (Berner et al., 2004;Ingrisch & Köhler, 1998;Willott, 1997;Willott & Hassall, 1998).Meeting our expectations, our results imply that higher temperatures due to climate warming result in a diversification of temperature-limited mountain communities.Since most species peaked in abundance between the submontane and montane zone, richness and abundance did not continue to increase in the valley, which could hint on a lack of more thermophilic (stenothermal) species in the regional species pool or a lack of suitable microhabitats at the lowest elevations.Although most species were more abundant at lower elevations, many had broad elevational distribution ranges (thermal generalists), spanning the entire 1.5 km gradient which highlights their ability to survive in colder macroclimates by utilizing sun-exposed sites with warm microclimate.
Local microclimatic conditions close to the ground varied considerably (up to 5°C) at similar elevations across the entire elevational gradient, equalling several hundred metres of elevational difference in atmospheric temperature.Such variation can buffer against the effects of regional warming, as species that evade unsuitable warm macroclimatic conditions can survive at colder sites within short distances (e.g.north-facing slopes in the northern hemisphere), making them potential stepping stones or recolonization nuclei (Albrich et al., 2020;Bennie et al., 2013;Körner & Hiltbrunner, 2021;Scherrer et al., 2011;Senf & Seidl, 2018;Stark & Fridley, 2022;Suggitt et al., 2018).Like for macroclimate, we expected consistent effects of microclimate on the Orthoptera species.As predicted, we found more individuals and species when microclimatic conditions were warmer throughout the entire gradient (Weiss et al., 2013).
However, not all taxa reacted equally to the microclimate along the gradient.Especially species that are vertically oriented and usually dwell in longer swards were more abundant at sites with a colder microclimate or did not profit from warm microclimate, particularly at low elevations.If the climatic niche of species is narrow and stable, this would imply that their microclimate preference changes with elevation.While for some species microclimate had no impact or colder sites were favoured under warm macroclimatic conditions, this effect vanished at the high-elevation tail of the TA B L E 1 Effects of traits on median values of climatic niche parameters derived from joint species distribution modelling.Note: Peak elevation describes the median elevation, where predicted abundances of the species peaked, microclimate slope represents the median estimate of a species' response to warming microclimate and peak shift is the median of the predicted difference between abundance peak elevations, if microclimate is either warm or cold.We highlight effects of the phylogenetic generalized least squares regression which are significantly positive in red or negative in blue and marginally significant slopes (p < 0.1) in pale (light red/blue).Significance levels: *p < 0.1, **p < 0.01, ***p < 0.001.
species' distributions or even changed to a positive impact of warm microclimate, a phenomenon referred to as elevation-dependent microclimate preference (Dobrowski, 2011;Feldmeier et al., 2020).

| High community dissimilarity in the montane and high-montane elevational zones
The peak of β-diversity of Orthoptera communities at intermediate elevations probably reflects the fading dominance of typical low-elevation species like most grasshoppers and crickets, and simultaneously a highly diverse mountain community at midelevations, which could result from the interplay of macro-and microclimate in this transition zone.Decreasing richness and abundance with elevation suggest that harsh abiotic conditions close to the summits formed specific communities out of a small species pool, leading to more similar communities at high elevations (Fontana et al., 2020;Laiolo et al., 2023;Tello et al., 2015).
However, we also found an impact of the microclimate on the dissimilarity at site pairs in low and mid-elevation zones, probably As thermophilic species require a sufficient amount of external heat, they are more strongly bound/restricted to warm microclimate sites (Geppert et al., 2021).Warm microclimatic conditions facilitate their presence at higher elevations such as the montane and high-montane zone, where cold sites harbour only a subset of the species in the pool, which increases the dissimilarity between sites.Interestingly, the tree line did not constitute a discrete transition to a new equilibrium of species composition, but rather the beginning of an accelerating decline in abundance as found for bumblebees (Sponsler et al., 2022).This implies that communities decrease in the total number of individuals but are of similar composition, probably because elevational distributions of many species were rather broad in contrast to other taxonomic groups (Fontana et al., 2020).

| Eco-morphological trait interactions with climatic niches
As season length declines along elevational or latitudinal gradients, univoltine insects with a long generation time are expected to follow the converse of Bergmann's rule (Classen et al., 2017).Thus, predominantly positive effects of larger body sizes on fecundity, thermoregulatory ability and desiccation resistance prevail under warm conditions (Schellenberger Costa et al., 2018;Tiede et al., 2018).
While there was no clear evidence of smaller body sizes of species that inhabit high elevations or cold microclimates than their low elevation relatives, we found a higher share of large individuals within communities at warm, low elevation sites, and similar intraspecific body size clines for female grasshoppers.This matches findings of Levy and Nufio (2015) that larger females react stronger than males to climatic variation because their fitness may be more sensitive to changes in season length and climatic conditions (Laiolo et al., 2013), Gomphocerippus rufus.Females were on average smaller at higher elevations than at low elevations (Table S7).In G. rufus females, wing length decreased with elevation, stronger when microclimate was cold.Solid lines were used in cases the 0.95 credible intervals of the elevation slope estimates did not include zero.
or to decreases in nutritional quality of food plants resulting from elevational turnover.The mechanism behind the body size reduction at high elevations was shown to be a local adaptation in form of lower size thresholds to adult moulting (Berner et al., 2004).
Since high temperatures facilitate insect flight (Prinster et al., 2020), we expected a wing length reduction with elevation and microclimate.Indeed, long-winged species occurred more often in low elevations, corroborating findings of Tiede et al. (2018) and Laiolo et al. (2023), but not at sites with warmer microclimate.As reported in other studies, however, relative wing lengths of longwinged species did not vary with elevation intraspecifically.There it was argued that only species with low dispersal ability are locally adapted and show reductions in wing lengths with increasing elevation, highlighting the impact of dispersal potential on size clines (Levy & Nufio, 2015).While there may be frequent genetic exchange of long-winged dispersing species along elevational gradients (Levy & Nufio, 2015), especially species of low mobility contribute to βdiversity patterns (Marini et al., 2012).
We expected a higher share of darker animals in cold environments based on thermoregulatory benefits (Köhler & Schielzeth, 2020).However, no consistent effect of macro-and microclimate on body coloration and colour morph frequencies was detected, neither for species distributions nor community traits.
Intra-and interspecifically, warm microclimates were associated with a higher proportion of brown individuals, contrary to our expectation.That doesn't necessarily exclude the proposed impact of local microclimate and macroclimate on the coloration as found in other studies (Köhler et al., 2017), but suggests that other effects such as the advantage of matching background/vegetation colour features to avoid predators, UV protection or precipitation differences interfere with temperature effects (Dieker et al., 2018).This phenomenon is referred to as crypsis-thermoregulation trade-off (camouflage, background-matching, predator avoidance) (Dieker et al., 2018;Köhler & Schielzeth, 2020), underlining the multifaceted nature of colour patterns and morph frequencies.
We found a strong impact of hatching phenology on the climatic niche parameters and community patterns.A later hatching may be risky for univoltine species, as the summer season length may be too short to complete their development and reproduce successfully in cold and high elevation habitats.Much of the differences in hatching phenology could be explained by differences in post-diapausedevelopment, development speed and oviposition sites (Ingrisch & Köhler, 1998;Kankaanpää et al., 2021).
Since the study area is humid with high levels of summer and winter precipitation, we found that xerophilic species had higher abundances at sites with a warm microclimate.This is in line with our prediction and could be caused by drier conditions at microclimatically warm sites due to run-off dynamics, increased evaporation or lower vegetation cover (e.g. at sun-exposed, steep sites; Häring et al., 2013), or because xerophilic species are often also thermophilic (Ingrisch & Köhler, 1998).Following the same line of argumentation, hygrophilic species were more restricted to northexposed, cool sites at low elevations, but the effect of microclimate changed with increasing elevation, leading to upslope shifts in the distributions from cold to warm microclimate sites.This elevationdependent preference for microclimate or aspect was especially evident for less xerophilic species.
The elevational-niche breadth hypothesis suggests broader dietary spectra of species which occur further up the mountain (Rasmann et al., 2014).However, a recent empirical study on dietary specialization, which includes a broader climatic range and phylogenetic relationships of food plants, suggests a unimodal relationship with most pronounced dietary specialization at intermediate elevations (König et al., 2022), offering explanations for the lack of such a pattern.For several traits, species niches and community mean patterns differed.
Such differences may result from intraspecific trait variation (Classen et al., 2017) or variation in elevational niche breadths of different species, as some species such as Omocestus viridulus displayed broader climatic niches than others such as the specialist Miramella alpina, but dominate the communities in terms of numbers of individuals, potentially blurring the understanding of environmental filters.
Trait expressions are often correlated with evolutionary relationships between species, as also demonstrated in our study, since closely related species often share similar characteristics.However, we also found evidence for phylogenetic signals in trait-environment interactions, highlighting that not only the traits we focused on contribute to species' climatic niches (e.g.thermal tolerances, thermoregulatory capacities).

| Caveats: The scale of microclimate and associated covariates
We found the highest number of species at sun-exposed extensive pastures in line with other studies (Chisté et al., 2016;Gardiner & Dover, 2008;Klein et al., 2020;Marini et al., 2009;Weiss et al., 2013), conditions which offer a mosaic of warm microclimate but also facilitate structurally rich vegetation, that could be used as shelter.Within-site microclimatic variation at even smaller scales than measured in our study (0.01-1 m) could also be crucial for the persistence of certain species, as shown for plants in alpine habitats (Ohler et al., 2020;Scherrer et al., 2011), possibly dampening the microclimate response we measured with this study.Likewise, species responses derived may be interfered by factors interacting with climate, such as moisture (Dvořák et al., 2022;Powell et al., 2007), management (Humbert et al., 2021;Marini et al., 2009), vegetation structure (Gardiner, 2022;Löffler & Fartmann, 2017;Schirmel et al., 2019), composition (Tobisch et al., 2023) and diversity (Fournier et al., 2017;Ramos et al., 2021).

| CON CLUS IONS
The limited potential of montane assemblages to respond to climate change is of major concern to conservationists.Our nuanced findings imply that macroclimatic as well as microclimatic changes in temperature have the potential to restructure, reassemble, and replace Orthoptera communities in temperate mountain grasslands.
Here, we demonstrate additive effects on diversity, but also community composition and functional traits are affected, as the interaction of elevation and microclimate shapes species niches.Since species can shift their elevational distribution not only upward but also northward to sites with cooler microclimates, climate change impacts might be mitigated by the complex topography in mountain areas (Feldmeier et al., 2020;Suggitt et al., 2018).Our results suggest that this turnover is the result of differences in abiotic conditions at similar elevations, highlighting the importance of mountains as climatic refugia, which support species with diverging preferences or requirements in proximity.Under future climate warming, we expect a less pronounced dissimilarity pattern in low elevations, as thermophobic species retreat and thermophilic species equally spread.This is referred to as biotic homogenization (Thorn et al., 2022).At higher elevations, the arrival of thermophilic species at warm-microclimatesites and the retreat of thermophobic species to cold-microclimatesites is expected, increasing dissimilarity in the high-montane zone.
Furthermore, our results underline the extraordinary value of traditional extensive pastoral systems including different slope exposures and therefore contrasting microclimatic conditions to conserve biodiversity in mountains.
Our results suggest that microclimate preferences of a species in its core distribution are not always reflected at the edges, where they may be more specialized.For example, less demanding species concerning temperature conditions in their core distribution may be more restricted at the edges.Therefore, possible shifts of microclimate preferences should be acknowledged not to overestimate range reductions or expansions.Since microclimate data and smallscale modelling approaches become available (Maclean et al., 2019;Senior et al., 2019;Zellweger et al., 2019), and local deviations to downscaled macroclimate are often high (±2°C), there is an urgent need to incorporate high-resolution microclimate data into species distribution models for an accurate estimation of the availability of suitable conditions for future species distributions (Stark & Fridley, 2022).
Combinations of traits help explain species' complex ecological niches and thus should prove useful in predicting their responses to future climatic changes in their habitats.Increasing temperatures in combination with drought events will likely increase diversity and the fraction of xerophilic Orthoptera species, but possibly force moisture dependent and high-temperature sensitive species to retreat to higher elevations and/or north-facing slopes.As macroclimatic average temperatures are increasing with climate change, so does the frequency of extreme weather events, which can differentially affect future distributions of species (Feldmeier et al., 2018).In the course of climate change, upslope shifts and population growth of thermophilic species at higher elevations is likely but can also be hampered or reversed by late snowfall or unsuitable extreme events, which regularly occur in mountain systems.
mountain region in southern Germany to test the following expectations: (1) The diversity and abundance of Orthoptera increase with micro-and macroclimatic temperature since species' climatic niches are constrained by harsh temperature conditions at cold sites or high elevations.Due to the overall cold and humid macroclimate and the complex topography in the northern Alps, we expect microclimatic effects to be particularly evident.(2) Differences in community compositions between sites peak at mid-elevations, where lowland species are still fostered by warm microclimate and overlap with mountain species.(3) Climatic niche parameters are related to species traits.Cold micro-& macroclimatic conditions filter the species pool towards smaller (body size), short-winged (wing length), less specialized (dietary breadth), early-hatching (phenology), darker (coloration) and less xerophilic (moisture preference) species (predictions Table Within a region of heterogeneous landscapes in the Northern Limestone Alps (Berchtesgaden Alps), characterized by tessellated mountain pastures in a matrix of (mainly) coniferous forest and bare rock, we selected 93 study sites along the slopes of several mountains, covering a gradient of 7-0°C mean annual temperature, 1500-2600 mm annual precipitation and ranging from 600-2150 m F I G U R E 1 Location of the 93 study sites along elevational gradients ranging from 600 to 2150 m a.s.l.(greyscale) in the Northern Limestone Alps (Berchtesgaden, Bavaria, Germany).All study sites were either extensively managed (grazed/ mown) or unmanaged open grassland sites.Point colour scale corresponds to measured local microclimatic conditions (red = warm, purple = intermediate, blue = cold).Example images of study sites from the five sampled elevational zones were added from low to high elevation (left to right: submontane, montane, highmontane, subalpine and alpine zone).
assuming default prior distributions and generating a total of 1000 posterior samples after thinning (model fitting and validation details in the Appendix S1; Ovaskainen & Abrego, 2020).Combining both statistically independent parts of the hurdle model, we predicted Orthoptera species abundances from the models' β-parameters, species richness, cumulative abundance and community-weighted mean trait patterns along the elevational gradient for cold (−1 standard deviation (SD) of microclimate), intermediate and warm (+1 SD) microclimate by multiplying the predictions for occurrence probabilities of each species from the presence-absence model with the conditional abundance predictions from the abundance COP model using the full 1000 posterior samples.
Average community hatching phenology and diet breadth decreased along the elevational gradient, while moisture preference and wing length increased (Figure5).Body sizes and wing lengths of individuals within communities were larger only at warm sites of low elevations, but not in high elevations.A distinct change in community-level trait patterns became evident in the subalpineF I G U R E 2Orthoptera communities recorded at the study sites.Circle size is proportional to the abundance of the species recorded during surveys.Sites are ordered vertically according to their mean elevation from valleys (bottom) to summits (top), where dashed horizontal lines delimit the submontane, montane, high-montane, subalpine and alpine elevational zones.Species richness is shown as bars on the left and summed abundances on the right.Orthoptera species are ordered and coloured according to their phylogeny with representative species images (from the left to the right: Gomphocerinae, Oedipodinae, Melanoplinae, Tetriginae, Gryllotalpinae, Gryllinae, Phaneropterinae, Tettigoniinae, Conocephalinae and Meconematinae).

F
Effect of microclimatic variation on four representative Orthoptera species along an elevational macroclimatic gradient.(a) The Field Grasshopper (Chorthippus brunneus) exhibited a broad elevational range and without specific microclimatic preference, (b) the Woodland Grasshopper (Omocestus rufipes) was found exclusively at warmer low elevation sites, (c) the Common Green Grasshopper (Omocestus viridulus) avoided warmer sites at low elevations and (d) the Common Mountain Grasshopper (Podisma pedestris) was prevalent at mid-elevation sites with warm microclimate.Shown are model predictions for warm (red line), intermediate (purple line) and cold microclimatic conditions (blue line) along the elevational gradient (numbers indicate the posterior probability of a positive impact of microclimate within each elevational zone).Point colours represent microclimatic conditions at the sites (red = warm, purple = intermediate, blue = cold).Vertical dashed lines separate the submontane, montane, high-montane, subalpine and alpine elevational zone from left to right in each panel.Individual responses of all 32 species are shown in Figure S6.

F
Effect of microclimatic variation on community-level abundance-weighted Orthoptera traits along an elevational macroclimatic gradient.Shown are model predictions for warm (red line), intermediate (purple line) and cold microclimatic conditions (blue line) along the elevational gradient (numbers indicate the posterior probability of a positive impact of microclimate within each elevational zone).Xerophilic, large and late-individuals had a higher share of the communities at sites with warm microclimate.Point colours represent microclimatic conditions at the sites (red = warm, purple = intermediate, blue = cold).Vertical dashed lines separate the submontane, montane, high-montane, subalpine and alpine elevational zone from left to right in each panel.reflecting reciprocal abundance patterns of thermophilic and thermophobic species in a zone where ambient temperatures are suitable to facilitate the development of many different species.
I G U R E 6 Empirical morphometric measurements of pronotum lengths (a), tegmen lengths (b) and their index, relative wing length (c) of two grasshopper species along an elevational macroclimatic gradient.The left panels show Omocestus viridulus and the right panels show