Trophic level and specialization moderate effects of habitat loss and landscape diversity on cavity‐nesting bees, wasps and their parasitoids

Habitat loss is a primary driver of biodiversity decline, but differences in species responses to habitat loss from local to landscape scales are poorly understood. Trophic level, food and habitat specialization have been suggested to be important predictors of species responses to habitat loss, landscape diversity and landscape scale. Using cavity‐nesting communities of bees, wasps and their parasitoids on calcareous grasslands as a model system allowed us to compare responses of species differing regarding their trophic level, and degree of specialization on habitat and food. We found that species from higher trophic levels experienced semi‐natural habitat at larger spatial scales than those of lower trophic levels, but only, when they were generalists (abundance of bees, 150 m radius, vs. wasps feeding on herbivores, 450 m radius), not specialists (bees, 150 m, vs. bee parasitoids, 150 m). Parasitoids, which are typically more specialized regarding their food resources (hosts), compared to predators such as predatory wasps, responded to habitat loss at the same spatial scales as their hosts, suggesting strong bottom‐up effects of resource availability, that is, host availability driving parasitoid abundance. Bees were mostly habitat specialists of calcareous grasslands and mainly driven by local habitat loss, whereas wasps as habitat generalists were mostly affected by landscape diversity. Our study highlights the need to consider the different spatial scales contingent on trophic level and specialization of target species groups, maintaining or restoring both local habitat and landscape diversity, as this is needed for their successful conservation.


INTRODUCTION
Habitat loss is a primary driver of local and global biodiversity decline (Brondizio et al., 2019;Dobson et al., 2006).However, differences in species responses to habitat loss, such as the strength of their population decline, are difficult to predict.One reason species respond differently to habitat loss is their trophic position in food webs and the spatial scale at which they experience the surrounding landscape, which drives their response to habitat loss at local and landscape scales (Cagnolo et al., 2009;Mayr et al., 2020;Steckel et al., 2014;van Nouhuys, 2005).A reduction in local spatial extent of habitat (within a few hundred metres) should mostly affect species at lower tropic levels, such as bees as primary consumers, which often have lower dispersal abilities and thus are dependent on plants as locally available resources (Holt, 2009;Raffaelli, 2004).By contrast, species at higher trophic levels, such as predators or parasitoids, ought to be more mobile to follow their prey and to switch between prey populations (Holt, 1996).Consequently, species at higher trophic levels should often perceive the landscape at larger spatial scales.Their occurrence is therefore not only dependent on local habitat quantity but also on the availability of habitat patches and habitat diversity at the landscape scale (Grass et al., 2018;Tscharntke et al., 2005).
However, the notion that the spatial scale at which species respond to habitat loss increases with their trophic position is not always true and does not appear to apply to all food webs (Thies et al., 2003).A potential reason is that the scale at which the landscape is perceived by predators also depends on their level of food and habitat specialization.Regarding food, parasitoids, for example, which are often specialized on one or few host species, are strongly affected by host availability, and hence may experience the landscape at similar scales as their hosts (Thies et al., 2003).By contrast, more generalist predators may be more mobile to switch between prey populations (Fornoff et al., 2021;Grass et al., 2018;Green, 2009;Holt, 1996;Rand & Tscharntke, 2007).Regarding habitat specialization, habitat area has been shown to be the most important for habitat specialist species, while generalists are mainly driven by habitat diversity and connectivity (Holzschuh et al., 2010;Steffan-Dewenter, 2003).
Trap nests for bees, wasps and their parasitoids, which are of high ecological importance providing ecosystem services such as pollination and pest control (Klein et al., 2007;Staab et al., 2018;Tscharntke et al., 1998), provide the opportunity to study and compare a small and well-defined community of species from different trophic levels, from primary to quaternary consumers and with different grades of specialization in a standardized manner (Fornoff et al., 2021;Staab et al., 2018;Steckel et al., 2014;Tscharntke et al., 1998) (Figure 1a).These artificial nesting resources for cavity-nesting insects are often made from common reed and placed at study sites to attract females to build nests, which can then be studied (MacIvor, 2017).Trap nests enable us to compare responses of both specialized (parasitoids), as well as generalist (hosts) species (Krombein, 1967).In addition, the community of trap-nesting insects can be related to the spatial scale at which species from different trophic levels experience local-and landscape-level habitat amount (Holzschuh et al., 2010).
Calcareous grasslands are hotspots of plant and insect diversity in central Europe (Steffan-Dewenter & Tscharntke, 2002;WallisDeVries et al., 2002).Most of the calcareous grasslands have greatly decreased in area and distribution as a result of agricultural intensification in the 20th century, because of which today mostly small and isolated fragments can be found in the agricultural landscape (Grass et al., 2018;Krauss et al., 2010;Poschlod & WallisDeVries, 2002).In this study, we use trap nests on calcareous grasslands to study the effects of habitat loss and habitat diversity at local and landscape scales on species responses at different trophic levels.
Differences between trophic levels regarding their responses to habitat loss, diversity and spatial scales may be expected because their food resources are either directly (bees as herbivores) or more indirectly (wasps as carnivores) driven by the habitat types (Kruess & Tscharntke, 2000;Raffaelli, 2004).More specialized consumers with a more narrow diet breadth such as parasitoids can be expected to be more closely linked to the availability and distribution of their food resources (hosts), and to be more affected by landscape change (Kruess & Tscharntke, 2000), compared to more generalist predators.
Regarding responses to habitat loss and habitat diversity, primary consumers such as bees have been shown to be affected mainly by habitat availability, while secondary and tertiary consumers (wasps) respond positively to higher landscape heterogeneity (Holzschuh et al., 2010).The responses of species from the same trophic level with different grades of specialization (e.g., bee parasitoids and wasps feeding on herbivorous prey, both being secondary consumers) to habitat loss and diversity can also be expected to differ.Compared to the responses of primary consumers (here, bees), bee parasitoids can be expected to respond at similar scales due to the strong tie to their hosts, while the generalist wasps may respond at larger scales.The following hypotheses were addressed: 1. Generalist species of higher trophic levels, that is, wasps, perceive the landscape at larger scales compared to species at lower trophic levels (bees), while specialist species at higher trophic levels, that is, parasitoids, are affected at similar scales as their hosts.
2. Bee abundance in trap nests is more strongly driven by calcareous grassland area than additional semi-natural habitats in the surrounding landscape, making bees habitat specialists.
3. Bees, which are mainly habitat specialists on calcareous grasslands, are mainly driven by local habitat loss, while habitat generalists (predatory wasps) are mostly affected by habitat diversity at the landscape scale.

MATERIALS AND METHODS
The study took place in the agricultural landscapes of the surroundings of the city of Göttingen, central Germany (lat: 51.532717, long: 9.935154, 20 km radius around the city).The region is dominated by intensive agricultural land use.There are 285 extensively managed calcareous grasslands in the study region making up 0.26% of the total area (Krauss et al., 2003).Twenty-three of these grassland fragments were used as study sites (see Figure 1b for an example; see Figure 2 for a map of the study area and distribution of study sites in the landscape).
The sites were selected along independent gradients (≙ treatments) of grassland area (minimum: 82 m 2 , maximum: 50673 m 2 , mean 6902 m 2 and median 3465 m 2 ), amount of other semi-natural habitat in the surroundings and landscape diversity (based on Shannon Index of habitat types) (Table A1).The intensity of the management of the sites (grazing or mowing) was required to not differ substantially to avoid differences in habitat quality.All sites were more than 300 m apart from each other (2406 ± 444 m; mean ± 1 standard error), and spatial independence was ensured by calculating spatial autocorrelation for all relevant variables and for residuals of all models (Moran's I with p > 0.05 in all cases).Adjacent forest fragments or hedgerows offered nesting habitat for cavity-nesting bees and wasps at all sites.Six trap nests were set up at each site in mid-April 2017.They were evenly spread across each site, and placed in spots that were not shaded most of the day and close to vegetation to resemble preferred natural nesting sites.Each trap nest consisted of two plastic tubes with a diameter of 10.5 cm, which were filled with common reed (Phragmites australis (Cav.)Trin.ex Steud.; approximately 200 reeds per tube) with diameters between 2 and 10 mm, cut to the length of the tube (20 cm) and attached to a wooden post 1.3 m above the ground (Figure 1c) (Staab et al., 2018;Tscharntke et al., 1998).Sites were sampled every 3 weeks, starting from end of May 2017 (when we noted the first nests had been plugged, meaning closed by a bee or wasp using natural materials such as mud or resin, indicating a nest was built and completed) until mid-October 2017 (when nesting had stopped; total of seven sampling rounds).Plugged nests were collected and replaced with reeds of a similar diameter, to ensure the constant availability of nesting sites, and to not miss the nests of the first generation of those species that have two generations per year.Plugged nests were brought to the lab and dissected, to determine the identity of host species, number of brood cells, parasitoid species and number of parasitized brood cells.Nest inhabitants (hosts and parasitoids) were identified to species level, if possible, using a stereomicroscope (for literature used for identification, see Table A2).For later analyses, nests were categorized into species groups based on the type of food provided to the larvae.The six groups were bees (providing larvae with pollen and nectar), wasps hunting herbivorous prey (such as aphids), wasps hunting carnivorous prey (spiders) and their respective parasitoids (parasitoids of bees, of wasps hunting herbivorous prey and of wasps hunting carnivorous prey).For the analyses, all nests from a site were pooled across sampling rounds and trap nests to obtain total abundance (number of brood cells ≙ sampling unit) for each of the species groups.et al., 2019).The maximum scale of 500 m was chosen to avoid spatial autocorrelation between sites, and has been shown to be suitable resembling the maximum foraging distance for most bee species of trap nests (Gathmann & Tscharntke, 2002;Zurbuchen et al., 2010).

Statistical analysis
First, to determine the spatial scales at which the species groups at the different trophic levels were affected by the landscape composition, the correlation coefficients (using the Spearman method) of abundance (using brood cell numbers in trap nests) and the proportion of semi-natural habitat (including extensively managed grasslands) and the landscape diversity within different radii around the centre of each grassland were calculated (Figure 3a,b).The most appropriate scales (highest correlation coefficients, but choosing the same scale for parasitoids and hosts of one trophic level) were used as variables for further analyses.The correlation coefficients of the hosts and respective parasitoids for the chosen scale were for semi-natural habitats: 0.50 and 0.57 for bees (150 m scale), 0.32 and 0.35 for wasps feeding their larvae with herbivorous prey (450 m scale) and À0.20 and 0.08 for wasps feeding their larvae with carnivorous prey (450 m scale); and for landscape diversity: 0.37 and 0.36 for bees (200 m scale), 0.38 and 0.45 for wasps feeding their larvae with herbivorous prey (200 m scale) and 0.23 and 0.13 for wasps feeding their larvae with carnivorous prey (100 m scale) (see Figure 3).
Trap nest inhabitants were split into three groups based on their trophic levels: bees, wasps feeding their larvae with herbivorous prey and wasps feeding their larvae with carnivorous prey.All three groups were attacked by parasitoids.Effects of grassland area, proportion of semi-natural habitat (excluding extensively managed grasslands) in the surrounding landscape and landscape diversity on species abundance were analysed separately for each group.Generalized linear models (GLMs) with negative binomial distribution were used.All models included the three explanatory variables: grassland area, semi-natural habitat and landscape diversity.All predictors were scaled to zero mean and unit variance to be able to compare effect sizes, and grassland area was additionally log-transformed.Model assumptions of GLMs were met and we tested for potential collinearity of predictor variables for all models.We refer to results as statistically significant when p < 0.05 and marginally statistically significant when 0.05 ≤ p < 0.10.

RESULTS
From the 138 trap nests (23 sites Â 6 trap nests each), 3124 nests were collected throughout the study period, containing 10,736 brood cells.Of these, 6470 brood cells belonged to bees, 438 of which to their parasitoids, 1874 to wasps hunting herbivorous prey, 544 of which to their parasitoids and 2392 to wasp hunting carnivorous prey, 733 of which to their parasitoids.
There were 26 species of wasps hunting herbivorous prey, with Ancistrocerus nigricornis (Curtis, 1826) (Vespidae) being the most abundant (43% of all brood cells belonging to this species), followed by Ancistro-

Note:
The effects of grassland area, semi-natural habitat excluding extensive grasslands in the surrounding landscape and landscape diversity on the abundances (brood cell numbers) are shown.All three predictor variables were scaled to zero mean and unit variance and additionally, grassland area was log-transformed.Estimates, standard errors, Z values and p-values rounded to three digits after the comma are reported.Significant and marginally significant predictors ( p < 0.10) are shown in bold.
Saxony (Jacobs, 2007;Tischendorf et al., 2015), and seem to be moving north, presumably due to climate change.See Table A3 for a full list of species and their abundances.Because of trap nests being a system relatively poor in species numbers, especially, when the community is split into sub-groups, we focused on abundances, and did not consider species richness here.
Abundances of bees (primary consumers) and their parasitoids were most strongly positively correlated with semi-natural habitat (including extensively managed grasslands) at small scales (150 m; Figure 3a).Wasps feeding on herbivores (secondary consumers) and their parasitoids were similarly positively affected by semi-natural habitats, but at larger scales (450 m; Figure 3a) and landscape diversity at small to medium scales (200 m; Figure 3b).When splitting up this group into sub-groups based on prey type, it became apparent that this pattern was driven by the most numerous group of wasps feeding on Microlepidoptera larvae, and not by those feeding on aphids or Chrysomelidae larvae (Figure A1).Abundances of wasps feeding on carnivores (tertiary consumers) and their parasitoids were not well predicted by semi-natural habitat and landscape diversity (correlation coefficient <0.3) (Figure 3a,b).
Regarding local and landscape effects, bee and bee parasitoid abundances were significantly positively correlated with the local area of the focal grassland fragments (p < 0.001; Figure 4a,d; Table 1).The host species from higher trophic levels and their parasitoids were not significantly correlated with local grassland area (Figure 4b,c,e,f; Table 1).
Regarding landscape diversity, no significant correlations were found for bees and their parasitoids (Figure 5a,d; Table 1).The parasitoids of wasps feeding on herbivores were marginally significantly correlated with landscape diversity (p = 0.06; Figure 5e; Table 1), while their hosts were not (Figure 5b; Table 1).Wasps feeding on carnivores and their parasitoids were positively affected by landscape diversity (marginally significant for parasitoids; p = 0.01; p = 0.07; Figure 5c,f; Table 1).
None of the groups were significantly correlated with semi-natural habitat other than the focal grassland (Table 1).
In general, the patterns of hosts and their parasitoids were similar, while the host species from different trophic levels showed different patterns regarding responses to scale, grassland area and landscape diversity (Figures 3-5; Table 1).

DISCUSSION
We found in this study that species from different trophic levels and with different food and habitat specializations are differently affected by habitat area and landscape diversity.Using cavitynesting bees, wasps and their parasitoids on calcareous grasslands as model systems, we found that species at different trophic levels perceive habitat loss and landscape diversity of the agricultural landscape at different spatial scales.Depending on the target species/ community, maintaining and restoring local habitat islands may not be sufficient for conservation, but the landscape must be considered as well, especially for species of higher trophic levels and habitat generalists.
Bee and wasp abundance was influenced by the availability of semi-natural habitats, with species of higher trophic levels (wasps) perceiving the landscape at larger spatial scales than those of lower trophic levels (bees).This is in line with the concept by Holt (1996), stating that higher trophic levels perceive the landscape at larger spatial scales, which is assumed to be caused by the higher mobility of the predators' prey and the predators' need to switch between prey populations, compared to herbivores that feed on non-mobile food, that is, sessile plants.Comparing trophic levels of parasitoids and their hosts, no differences regarding the landscape scale best suited to explain their abundances were found.This has been shown before and is likely due to the typically high food specialization of parasitoids on their hosts, causing them to be tied more closely to the spatial scale at which their hosts respond to local-and landscape-level habitat availability than generalists (Grass et al., 2018;Holt, 2009;Rand & Tscharntke, 2007;Steffan-Dewenter & Tscharntke, 2000;Thies et al., 2003).These results suggest that in addition to the trophic level of consumers, the degree of food specialization mediates how species experience the landscape.
We found that the scales at which abundances of the same trophic level relate to different landscape variables can be quite different.
This could be shown by their responses to the amount of semi-natural habitat and landscape diversity.This contrast was most distinct for wasps feeding on herbivores, representing the trophic level of secondary consumers, being affected at large scales by semi-natural habitat, and at smaller scales by landscape diversity.This may be caused by flexible foraging strategies.The availability of large amounts of seminatural habitat at larger scales seem to be sufficient for providing herbivorous prey to the wasps.When large amounts of semi-natural habitat are not available, a high diversity of habitats at smaller scales may be needed, with edge habitats providing both food sources and ensuring connectivity and permeability of the landscape (Krewenka et al., 2011;Mallinger et al., 2016).When further dividing the group of wasps feeding on herbivores by prey type, different responses are revealed, with wasps feeding on Microlepidoptera larvae responding strongly to semi-natural habitat, which may be because of the association of their prey with (fruit) trees and shrubs, which are abundant at semi-natural habitats (Hoffmann et al., 2018;MacKay, 1962).Wasps feeding on aphids and Chrysomelidae larvae on the other hand are not associated with semi-natural habitat, which can be explained by their prey not being associated with semi-natural habitats, but with annual crop plants (e.g., aphids as pest species in wheat fields) (Dedryver et al., 2010;Jolivet et al., 2012).
Bee abundance was strongly correlated to grassland area, but not to the amount of additional semi-natural habitats in the surrounding landscape, suggesting that the studied cavity-nesting bees are habitat specialists of the calcareous grasslands.As we provided artificial nesting sites at all sites, food requirements can be expected as the limiting factor for bee occurrence.Bees rely on flowering plants offering nectar and pollen, which were widely available at the focal grasslands (Steffan-Dewenter & Tscharntke, 2002;WallisDeVries et al., 2002).
Solitary bees, depending on their body size, can have maximum foraging ranges of up to 1100 m, however, realized foraging distances may be much lower, when resources are available in close proximity to the nest, as was the case at the calcareous grasslands (Gathmann & Tscharntke, 2002;Zurbuchen et al., 2010).
By contrast, abundances of wasp species were not positively correlated to grassland area, which may be due to their higher trophic level and hence higher mobility weakening species-area relationships, as suggested by Holt (2009).It has also been shown and is supported by our results that habitat specialists (in our case bees) are mainly driven by local habitat loss, while habitat generalists (wasps) are mostly affected by landscape diversity and connectivity (Holzschuh et al., 2010;Steffan-Dewenter, 2003).Furthermore, the prey of most cavity-nesting wasps, such as aphids, Chrysomelidae larvae and spiders, is mostly not associated with extensively managed grasslands, but annual crop fields, suggesting the wasps to use the grasslands for nesting and feeding, but not as much for hunting (Dedryver et al., 2010;Hoffmann et al., 2018;Jolivet et al., 2012).

CONCLUSIONS
In conclusion, we showed that trophic level and specialization moderate species' responses to local habitat loss and landscape diversity and that they perceive the landscape at different scales.These findings highlight the need for conservation or restoration projects to foster habitat heterogeneity, providing resources essential either in close proximity for less mobile species from lower trophic levels and their specialist antagonists or within the wider landscape, while also ensuring high landscape diversity and permeability, for more mobile species from higher trophic levels.
T A B L E A 2 Literature used for the identification of nest inhabitants.
T A B L E A 3 List of species recorded at different trophic levels in trap nests and their total brood cell numbers.

F
I G U R E 1 (a) Overview of the trophic levels in the food chain and their representatives in the trap nest system.(b) A calcareous grassland fragment (centre) embedded in the agricultural landscape.(c) A trap nest consisting of two plastic tubes filled with reeds attached to a wooden post, and protected from grazing animals by a fence.
Map of the location of the study region within Germany (top left); locations of the calcareous grasslands studied in the surroundings of the city of Göttingen, with 500 m buffers showing the landscape types (centre), and detailed maps of contrasting landscapes around two sample sites (right).Basemap© ESRI.

F
I G U R E 3 Correlation coefficient of abundance of the different groups (brood cell numbers in trap nests per site; n = 23 sites) and (a) seminatural habitat (including focal grasslands) and (b) landscape diversity respectively, at different scales (radii around centre of focal grasslands).Scales most correlated (using the same scale for each pair of host and parasitoid) and used for further analyses for the different trophic levels are pointed out by arrows.F I G U R E 4 Abundance (number of brood cells per site) of different trophic levels in relation to grassland area (log-transformed).Solid lines represent significant relationships (p < 0.05).Envelopes show 95% confidence intervals.The landscape within a 500 m radius around each study site was mapped by ground-truthing.Habitats were categorized in 16 categories: oilseed rape field, grain field, maize field, other crop field, open canopy forest, closed canopy forest, field margin, hedgerow, pasture, nutrient poor grassland, orchard, settlement, water body, street, field road and quarry.The landscape data was digitized and analysed using the software QGIS, version 2.14.3 (QGIS Development Team, 2016) and R (R Core Team, 2020).The variables open canopy forest, field margin, hedgerow, nutrient poor grassland, orchard, field road and quarry were combined to semi-natural habitats.The proportion of semi-natural habitat (excluding the focal grassland), and the diversity of landscape types were calculated for different scales (from 100 to 500 m, 50 m steps) using the R package 'landscapemetrics' (Hesselbarth

F
I G U R E 5 Abundance (number of brood cells per site) of different trophic levels in relation to the diversity of the surrounding landscape (different radii).Solid lines represent significant relationships ( p < 0.05).Dashed lines represent marginally significant relationships ( p ≥ 0.05 and <0.10).Envelopes show 95% confidence intervals.