It is about time: effects of thermal fluctuations resulting from climate change on trophic interactions with a focus on host–parasitoid interactions

Climate change alters many environmental parameters with strong consequences for ecological interactions, from species interactions to community dynamics. Temperature is crucial in determining ecosystem dynamics, especially for those involving ectothermic species such as plants or insects. Phenotypic plasticity, the capacity of one genotype to produce different phenotypes in response to environmental conditions, is a common mechanism by which individuals adapt to changing environments and is observed in multiple traits. The capacity of genotypes to adapt to novel temperature conditions plays a crucial role in structuring ecosystem dynamics and species persistence in adverse conditions. It is well recognised that temperature in natural ecosystems fluctuates over multiple time scales (e.g., hour, day, season, year). These fluctuations can follow predictable patterns or be unpredictable, with different consequences for phenotypic plasticity and ecosystem dynamics. Among trophic interactions, host–parasitoid interactions represent a special case because of the intimate symbiosis of the parasitoid larvae with their host. Understanding how and to what extent phenotypic plasticity structures species’ ecological niches is of utmost importance in the context of rapid climate change. With a particular focus on host–parasitoid interactions, this review discusses the literature on the role of phenotypic plasticity in fluctuating environments, highlighting the role of temporal dynamics. While we discuss literature on phenotypic plasticity at large, this review emphasises the fundamental effects of extreme temperatures in driving biochemical rates underlying phenotypic plasticity.


Introduction
Temperature is an important environmental parameter that plays a crucial role in ecological processes, especially for ectothermic organisms such as insects, whose body temperature is directly affected by ambient thermal conditions (Huey and Berrigan 2001;Kingsolver and Huey 2008;Angilletta 2009). Temperature governs physiological processes of ectothermic species, such as metabolism (Brown et al. 2004). Metabolic activity influences fitness and, following a thermal performance curve (TPC), increases with temperature up to a maximum and drops as the temperature continues to increase (see Box 1) (Gillooly et al. 2001;Clarke and Fraser 2004). In response to changing thermal regimes, species may track suitable thermal conditions spatially, or adapt locally to the new conditions (Parmesan 2006). Physiological processes may allow organisms to mitigate the effects of temperature fluctuations on their fitness. This may be achieved by differentially activating physiological processes in response to changes in temperature.
At the individual level, phenotypic plasticity represents the capacity of one genotype to express different phenotypes when exposed to various environments (Stearns 1989;Agrawal 2001;DeWitt and Scheiner 2004;Whitman and Agrawal 2009). Phenotypic plasticity can be subdivided into reversible and irreversible (or developmental) plasticity resulting from the past and present environmental conditions an individual has experienced throughout its ontogeny (DeWitt and Scheiner 2004). For example, when caterpillars of the pipevine swallowtail butterfly, Battus philenor (Lepidoptera: Papilionidae) are exposed to ambient temperatures above 30 °C they switch from black to red phenotype (Nice and Fordyce 2006). This type of phenotypic plasticity is known as polyphenism and is commonly observed in insects (Stearns 1989). In contrast to morphological traits, behavioural or physiological traits are rapidly reversible (Whitman and Agrawal 2009). When phenotypic traits vary continuously along an environmental gradient (i.e. continuous plasticity), the relationship can be depicted as a reaction norm (Box 1). For example, the temperaturesize rule describes the relationship between developmental temperature and insect body size (Atkinson 1994). The change in phenotype expressed by one species in response to a change in thermal conditions will likely have fitness consequences and will affect interactions with other species, such as trophic interactions (Ma et al. 2021).
Insects have evolved an extensive suite of physiological and behavioural adaptations to cope with thermal constraints (Angilletta et al. 2002;Angilletta 2009;Abram et al. 2017). Thermal tolerance has a polygenic basis, and underlying mechanisms conferring thermal tolerance include, for instance, the production of protective molecules such as Heat Shock Proteins (HSPs) (Stanton-Geddes et al. 2016). The thermal responses at the cellular or gene transcriptional levels depend on an individual's body temperature. Although ambient thermal conditions affect insect body temperature, individuals can modulate it using various thermoregulatory mechanisms (May 1979). Behavioural thermoregulation relates to the behavioural strategies an individual uses to regulate its body temperature, and relies on the capacity to sense and select appropriate thermal environments (Abram et al. 2017).
Insect parasitoids and their insect hosts provide excellent study systems to assess the role of phenotypic plasticity in response to fluctuating thermal regimes and high-temperature extremes. Parasitic wasps are a very diverse group of arthropods and contribute significantly to regulating other insect populations (Jervis 2005;Quicke 2014;Forbes et al. 2018). They are often specialised in attacking one or a few host species, and even specific larval stages within these host species. As juveniles, parasitoids feed on their host (parasitic stage), which represents a limited source of nutrients; thus, their traits have tightly coevolved with those of their hosts (Godfray 1994). For species that have such an intimate interaction where one species develops within a developing individual of another species, the effects of phenotypic changes will have important consequences for this ecological interaction. For instance, the developmental rate of the host, including moulting, affects the nutritional environment of parasitoid larvae present in the host. Our goal is to assess how phenotypic plasticity in thermally fluctuating environments influences host-parasitoid interactions, including the effects of high-temperature extremes, highlighting the role of temporal dynamics. We focus on host-parasitoid interactions because of the importance of parasitoids as a functional group and their role in the population dynamics of herbivorous insects (Hance et al. 2007;Jervis and Ferns 2004;and references therein). To reach this goal, we will first address the kinetic and behavioural responses to thermal fluctuation and extremes at the level of individuals. Then we scale up from individual plastic responses to species interactions and discuss the consequences for population dynamics and community structure. We conclude this review by presenting promising frameworks to analyse and interpret complex multifactorial effects of thermal fluctuations and extremes on species' realised ecological niches.
Box 1 Thermal Performance Curves, Jensen's inequality, and insect thermotolerance Temperature governs the rates of biochemical reactions and physiological processes (Brown et al. 2004;Angilletta 2009). The effect of temperature on insect metabolism and, more widely, on phenotypic traits is depicted using reaction norms, also called thermal performance curves (TPC) when applied to performance-related traits (Kingsolver et al. 2004;Angilletta 2009;Lande 2014). The shape of thermal reaction norms varies from species to species and from trait to trait (Berger et al. 2008;Iltis et al. 2019;Romero-Mujalli et al. 2021). TPCs are useful to depict the thermal tolerance of individuals, defined by the thermal breadth composed of two critical temperatures (lower and upper thermal limits) (Sinclair et al. 2016) (solid black line in Fig. 1). Due to the non-linearity of the relationship, the thermal performance at the mean temperature will be higher or lower than the averaged thermal performance at each end of the thermal fluctuation, depending on the shape of the thermal reaction norms (i.e. the convex or concave part). This well-known phenomenon is referred to as the Jensen's inequality (Jensen 1906;Ruel and Ayres 1999;Denny 2017) (depicted by the dotted and solid coloured lines in Fig. 1). A parasitoid and its host may have different TPCs that are shifted along the temperature range resulting in a thermal mismatch in part of the temperature range (Furlong & Zalucki 2017).

Physiological and behavioural responses to fluctuating thermal regimes
The fundamental role of metabolism in determining life-history traits and fitness at the individual level is central in assessing species distribution and abundance across climatic regimes (Brown et al. 2004). TPCs represent an excellent tool to depict species' thermal tolerance and have been used extensively to predict the impact of climate change on species (Schulte et al. 2011;Sinclair et al. 2016;von Schmalensee et al. 2021). For instance, the climate variability hypothesis (CVH), stating that species living at high latitudes display wider thermal tolerances than species at lower latitudes allowing them to withstand larger thermal fluctuations, was confirmed by Addo-Bediako et al. (2000), who reviewed 1 3 the thermal tolerance of ectotherms across their latitudinal distribution. Although TPCs are useful in depicting the thermal responses of an individual, they suffer from several shortcomings (Dowd et al. 2015;Sinclair et al. 2016). An essential drawback of TPCs is the lack of temporal dynamics required to accurately measure lagged temperature effects on fitness-related traits throughout ontogeny (Schulte et al. 2011;Kingsolver and Woods 2016). In this section, we will review the physiological effects of temperature on thermal tolerance with the concept of acclimation and rapid heat hardening. Then we will explore the molecular background of heat tolerance in insects. Lastly we will discuss the special case of diapause and aestivation.

Physiological effects of fluctuating thermal regimes
The physiological effects of temperature on insect metabolism are well-described and widely used to predict the impact of climate change on the geographical distribution of species (Furlong and Zalucki 2017;Macfadyen et al. 2018). However, the precision of these models depends on a correct assessment of the non-lethal effects of temperature on physiology (Jørgensen et al. 2022) as well as on the inclusion of species interactions and their consequences for the realised ecological niches (Section "Consequences of fluctuating thermal regimes for species interactions and community structure", Davis et al. 1998a, b;Woodin et al. 2013;Tylianakis and Binzer 2014). Because temperature fluctuates daily in a  Fig. 1 Fictive curve of thermal performance (solid black line) expressed as a function of temperature. The thermal performances for two hypothetical thermal ranges represented by the blue and orange solid lines are plotted on the Y-axis. The dotted black lines represent the performance values taken at the average temperature of each thermal range and are denoted P1 and P2. The dotted blue and orange lines represent the thermal performances, P 1J and P 2J , calculated as averages from performances at the minimal and maximal temperature value of each thermal range t1 min and t1 max or t2 min and t2 max . The + and − signs emphasise the Jensen's inequality's positive and negative effects, respectively, compared to performances at the mean temperatures 1 3 predictable way (e.g. day-night) as well as in an unpredictable stochastic way (e.g. extreme events), insects often have to face significant thermal variation during their life cycle. Potter et al. (2011) found variable but significant effects on egg development time and initial larval growth rate after having exposed eggs of Manduca sexta (Lepidoptera: Sphingidae) to cycling temperatures and heat shocks. The demographic rate and life-history traits of Sitobion avenae (Hemiptera: Aphididae) exposed to a factorial combination of hot and 'normal' days were driven by the balance between hot and normal days. Increasing the period of hot days had negative fitness consequences but was dependent on their clustering . It emphasises the temporal distributions and quantitative patterns of temperature on insect population dynamics (Stoks et al. 2017;Ma et al. 2018; Clusella-Trullas 2022) (Fig. 2). The following section discusses the effects of thermal fluctuations and extremes on the physiological mechanisms of thermal tolerance.

Plasticity in thermal tolerance: acclimation and heat hardening
The thermal environment experienced by an individual during development affects the adult phenotype and thermal tolerance. Developmental acclimation can lower the resting metabolic rates of individuals reared in warm conditions compared to those reared in milder conditions (Berrigan 1997;le Lann et al. 2011;Moiroux et al. 2012). This allows insects to reduce their energy consumption for maintenance; however, this depends on the nutritional status and evolutionary history of insect population. Indeed, Moiroux et al. (2012), found that the metabolic rates of geographically distinct populations of Leptopilina boulardi (Hymenoptera: Figitidae), a parasitoid of Drosophila melanogaster (Diptera: Drosophilidae), differed with parasitoids from warm and dry habitats having a higher metabolic rate than populations originating from milder and more humid habitats. However, the  Fig. 2 Overview of Section "Physiological effects of fluctuating thermal regimes" on the effects of timing of the environmental signal (e.g., temperature) on an individual's phenotype and its resulting fitness (from left to right). As insect species are engaged in interaction networks with other species, a feedback loop was added from phenotype (middle box) to biotic environment (see Section "Behavioural effects of fluctuating thermal regimes") 1 3 former populations unlike the latter displayed de novo lipid synthesis in the adult stage. Most of these studies have only tested developmental acclimation of metabolic rates under constant temperature. MacLean et al. (2017) compared the effects of long-term and shortterm exposure during various life stages on the adult critical lower or upper temperature (Box 1 and Fig. 1) of D. melanogaster, the host of L. boulardi. Long-term but not shortterm cold and heat exposure increased the fly's critical lower and upper thermal limit, respectively (MacLean et al. 2017). The thermal tolerance of an individual differs whether it is measured by ramping or plunging assays (Terblanche et al. 2011;Bahar et al. 2013;Nguyen et al. 2014). Plunging assays (i.e. insects are placed without acclimation at the new temperature) are better suited to determine basal heat tolerance, while ramping assays are performed by gradually increasing temperature and assessing rapid heat hardening (Bahar et al. 2013;Manenti et al. 2018).

Fitness
Rapid heat hardening is a plastic response occurring within hours that can improve insect survival and fitness or maintain activity such as feeding under adverse thermal conditions (see Section "The thermal landscape and its importance"). Temporal variation in thermal exposure during development (i.e. number of hot days and number of critical exposure hours within these days) had inconsistent ("zig-zag") effects on the body size and fecundity response in Plutella xylostella (Lepidoptera: Plutellidae) (Chen et al. 2019).
Global warming leads to a faster increase of night temperatures compared to day temperatures. In naturally fluctuating environments, night-time warming is likely to draw species closer to their thermal optimum, thus having beneficial effects on their performance (Speights et al. 2017). On the other hand, night-time warming can reduce recovery time after acute heat exposure during the day (Zhao et al. 2014; Barton and Schmitz 2018;Ma et al. 2021). Recent work assessing the effects of alternating consecutive hot days and recovery days on the performance of the grain aphid (Sitobion avenae Fabricius) showed that recovery could occur when the insects were gradually exposed to milder thermal conditions ). Additionally, time-specific behaviour and activity patterns could mediate the effect of day versus night warming, especially considering diurnal or nocturnal species (Whitney-Johnson et al. 2005;Speights et al. 2017). For example, some species can shift their foraging time to the night, while others may be constrained to diurnal foraging with severe consequences for the thermal physiological effects they will experience (Speights et al. 2017).

Thermal tolerance and ontogeny
Variation in thermal tolerance throughout ontogeny and the timing of extreme events relative to the individual developmental stage may affect host-parasitoid interactions and subsequently fitness (Potter et al. 2011;Zhang et al. 2015;Cavieres et al. 2016). The mechanistic principles behind the variation in thermal tolerance through ontogeny are not entirely elucidated but expected to be linked with allometric scaling in body size. In terrestrial ecosystems, individuals with larger body sizes are usually more thermotolerant than smaller ones (Klockmann et al. 2017;Kingsolver and Buckley 2020). Moreover, many insects exhibit modular life cycles, meaning that their development is characterised by distinct stages between which partial physiological restructuring occurs. Consequently, they can isolate, to some extent, the adverse effects of thermal stress from one stage to the next (Bowler & Terblanche, 2008;Potter et al. 2011). Higher temperatures usually lead to faster development and smaller body sizes than in cooler environments (Kingsolver and Huey 2008). This phenomenon was extensively reviewed by Atkinson (1994) and described as the Temperature Size Rule. The reasons behind the production of smaller body sizes in warmer climatic conditions are thought to involve energetic trade-offs between growth rate, mortality and reproduction. The adaptive value of smaller body sizes lies in more effective thermal exchange (Atkinson 1994, but see Diamond and Kingsolver 2011 for a counter-example).

Thermal tolerance: the molecular level
Molecular tools such as omic techniques can give a complete phenotypic and genotypic picture of an individual at a given time in a given environment, and their use significantly improves the understanding of the physiological effects of environmental variables on phenotypic plasticity (Hayward 2014). Among the different physiological responses to temperature stress that were identified (recently reviewed in González-Tokman et al. (2020), HSPs have received most attention (Feder and Hofmann 1999;Ju et al. 2011;King and MacRae 2015;Tian et al. 2021). HSPs are molecular chaperone proteins protecting proteins and cells against the destabilising effect of high temperature, thus playing an important role in insect heat tolerance, rapid hardening, and developmental acclimation (Feder and Hofmann 1999;Sørensen et al. 2003). The extent to which HSP gene expression is induced in response to heat shocks seems to be lower for individuals maintained in fluctuating thermal regimes than for individuals held in constant thermal regimes (Sørensen et al. 2003). The induction of HSP genes is dependent on the circadian rhythm. Thus, heat protection gained by inducing HSPs varies within the 24 h thermal cycle (Manenti et al. 2018;de Alba et al. 2021). Transcriptome analysis of Drosophila species under constant or fluctuating thermal regimes showed that a large proportion of the transcriptome was affected by differences in constant temperature. Only a small proportion was affected by fluctuating temperatures (Sørensen et al. 2016;Manenti et al. 2018). The large proportion of genes affected by differences in constant temperature probably results from the fundamental effects of temperature on physiological rates. Regarding the proportion of genes whose transcription was affected by fluctuating temperatures, Drosophila simulans Sturtevant gene ontology analysis showed that egg-chorion-related genes were downregulated, and those related to cellular heat tolerance were up-regulated (Manenti et al. 2018). These were driven by Turandot genes involved in heat tolerance but with a slower activation rate than HSP genes. Their slower activation rates could prevent maladaptive heat tolerance expression under fluctuating thermal regimes (Feder and Hofmann 1999;Sørensen et al. 2003;Manenti et al. 2018).

The special case of diapause and aestivation
Climate change alters seasonal temperature variation affecting the evolution of parasitoid diapausing strategies (Vasseur et al. 2014;Wang and Dillon 2014). These changes affect the seasonal ecology of insect parasitoids and their hosts by altering voltinism, diapause, quiescence, and winter survival. The adaptive value of diapause in a novel thermal environment is likely to be species-specific (Tougeron et al. 2020). The increase in mean winter temperatures and host availability led to the increase in winter activity of its associated parasitoid species and a reduction in diapause (Andrade et al. 2016;Tougeron et al. 2017). Parasitoid diapause can be linked or not with host diapause leading to a gradient of host-parasitoid synchronisms (Corley et al. 2004). In trophic interactions where different species respond differentially to warming, a mismatch may occur (Parmesan 2006). This is especially relevant for species that live together during an important part of their life such as parasitoids and their hosts. The mismatch in thermal performance between host and parasitoid associated with warmer spring temperatures increased the synchrony of the parasitoid Cotesia melitaearum (Hymenoptera: Braconidae) with its host Melitaea cinxia (Lepidoptera: Nymphalidae) affecting the strength of host-parasitoid interaction, in this case favouring the parasitoid (Nouhuys and Lei 2004). The duration of host or parasitoid diapause regulated the stability of host-parasitoid systems by preventing a proportion of the population from being parasitised (e.g. in the case of prolonged host diapause) (Corley et al. 2004;le Lann et al. 2021). The diapausing strategy adopted by a parasitoid is expected to match the expected environmental conditions (e.g. host density and temperatures). An increase in the frequency of extreme weather events can therefore select for different overwintering strategies such as undergoing diapause in the juvenile stage of the host, entering quiescence as an adult or remaining active to reproduce (Tougeron et al. 2020). For example, the parasitoid Platygaster demades (Hymenoptera: Plastigastridae) regulates the frequency and duration of aestivating and non-aestivating phenotypes to produce uni-, bi-, tri-or quadri-voltine phenotypes over the season matching the expected host shortage, thus avoiding negative fitness consequences (He et al. 2010). An increase in the frequency of unpredicted climatic events should select for bet-hedging strategies with individuals either displaying prolonged or simple diapausing (aestivating) or non-diapausing (non-aestivating) phenotypes, reducing the risk for negative fitness consequences due to harsh environmental conditions at the population levels (le Lann et al. 2021). However, the response of their host to changing environmental conditions as well as the ancestry's genetic constraints, will determine the evolution of parasitoid life-history strategies in response to climate change (Stearns 1989;le Lann et al. 2021).

Behavioural effects of fluctuating thermal regimes
Insects have thermoreceptors on various body parts depending on the insect species and life stage (e.g., on the antennae or wings). Thermoreceptors sense ambient temperature and transmit the information to the central nervous system that initiates integrated behavioural and physiological responses of the whole organism (reviewed in Abram et al., 2017;González-Tokman et al. 2020). This section will focus on the influence of thermal fluctuations on integrated behavioural responses (Fig. 2, left and middle frames). First, activity levels and thermoregulatory behaviour will be reviewed, then we will discuss the impacts of extreme temperatures on host-parasitoid foraging and learning behaviours. Finally, the importance of the thermal landscape and microclimatic conditions on insect thermal tolerance and behavioural responses to climate change will be highlighted.

Activity levels and thermoregulation
Behavioural responses to thermal changes range from alteration of diel activity patterns to the modification of foraging strategies. Disentangling behavioural from physiological responses to temperature variations is intrinsically difficult (Augustin et al. 2020). For example, several studies have observed changes in walking speed and attack rates of parasitoids with changes in temperatures, likely driven by metabolic rates (le Lann et al. 2014a; Moiroux et al. 2016;Abram et al. 2017) (see Box 1). Moreover, D. melanogaster exposed to long or short thermal stress during their larval stage displayed altered activity levels in the adult stage (MacLean et al. 2017). Insects can alter their behaviour and regulate body temperature by sensing their thermal environment (González-Tokman et al. 2020). Rojas et al. (2014) studied in the field the exploratory response of the isopod Porcellio laevis (Isopoda: Porcellionidae) acclimated to different thermal fluctuations. The acclimated isopod displayed reduced exploratory behaviour, supposedly to reduce the risk of exposure to adverse temperatures (Rojas et al. 2014).
Behavioural thermoregulation is probably the best known mechanism by which insects regulate their body temperature (May 1979;Nice and Fordyce 2006;Kearney et al. 2009;Turlure et al. 2011;Woods et al. 2015;Kleckova and Klecka 2016). Behavioural thermoregulation can take various forms, such as habitat selection, orientation to solar radiation (basking), temporal shift in activity patterns, or increased metabolism (e.g., flight) (May 1979;Casey and Knapp 1987). For example, the social caterpillar Malacosoma disstria Hübner (Lepidoptera: Lasiocampidae) optimised its thermal gains to promote growth via shifts between basking in a tight cluster along a thermal gradient and foraging time on the food source (McClure et al. 2011). Behavioural thermoregulation in warm environments allows individuals to avoid harmful temperatures or select optimal foraging locations (Kearney et al. 2009). However, it mainly relies on spatio-temporal thermal heterogeneity of the environment (Potter et al. 2013;Caillon et al. 2014;Woods et al. 2015;Pincebourde and Woods 2020).
Thermoregulation can be employed by insects to maximise their growth and resource acquisition. Casey (1976) studied the thermoregulatory behaviour of two desert caterpillars, M. sexta and Hyles lineata (Lepidoptera: Sphingidae), linking it to their activity patterns, ambient air and body temperatures. Hyles lineata thermoregulated by selecting microclimatic conditions on or near the food plant as well as regulating its feeding activity level with ambient temperature (Casey 1976). Insect nutritional requirements vary with the thermal environment they are experiencing and are predicted to shift nutrient demand from nitrogen-rich to carbohydrate-rich resources (Schmitz and Rosenblatt 2017). The nutritional status of an individual plays a crucial role in its fitness as well as in its phenotypic plasticity, as M. sexta feeding on high-or low-quality host plants showed opposite bodysize response to temperature with the former following the temperature size rule while the latter had smaller body-size at lower temperatures (Diamond and Kingsolver 2010). Digestive and assimilative performances for nitrogen or carbon had specific thermal reaction norms depending on the host plant (Clissold et al. 2013;Clissold and Simpson 2015). Furthermore, when deficient in either protein or carbohydrate, Locusta migratoria (Orthoptera: Acrididae) nymphs thermoregulated accordingly to maximise the intake of one or the other (Clissold et al. 2013). Upon parasitisation, parasitoids may change the behaviour of their hosts (Frederic et al. 2009), for example their response to temperature: Acyrthosiphon pisum Harris aphids parasitised by the parasitoid Aphidius ervi Haliday (Hymenoptera: Braconidae) selected a temperature that was most suitable for the parasitoid, suggesting that the parasitoid manipulated aphid temperature selection behaviour (Lagos et al. 2001).

Foraging and learning strategies
Parasitoid foraging strategies affect their fitness since reproductive success relies on the location of suitable hosts by parasitoid females (Godfray 1994). Parasitoid foraging behaviour depends on physiological status, especially life expectancy and nutritional status. Challenging environmental conditions reducing life expectancy or imposing higher metabolic costs can thus induce risk-prone behaviour (Giraldeau and Boivin 2008). Risk-prone behaviour increases fitness when an individual in a given environmental context faces low survival odds or intense physiological stress. For example, in response to warmer rearing or foraging conditions, host selection by the aphid parasitoid A. ervi shifted towards hosts of lower quality (i.e., instar selection) (Moiroux et al. 2015). Overall, the foraging strategy adopted to maximise fitness in challenging thermal environments is correlated to habitat quality and, more specifically, linked to the energetic costs of interpatch travel (Denis et al. 2011).
Female hymenopteran parasitoids can control the sex of their offspring as a result of their haplodiploid sex-determination system (Godfray 1994). Sex allocation of offspring by female parasitoids varies based on environmental conditions such as local mate competition, host quality or temperature (Shuker et al. 2007;Gols and Harvey 2009;Moiroux et al. 2014). The egg parasitoid Trichogramma euproctidis Girault (Hymenoptera: Trichogrammatidae), foraging at high temperatures, displayed an intentional male bias in offspring sex ratio, while this was not the case at lower temperatures (Moiroux et al. 2014). The realised sex ratio of T. euproctidis at low temperatures was also male-biased, most likely caused by other physiological mechanisms such as egg fertilisation or sperm viability (Moiroux et al. 2014;Sales et al. 2018). Alteration in offspring sex ratio under warm temperatures may have lasting consequences for parasitoid population dynamics by altering competition for mates between males and regulation of host populations.
Learning and memory can significantly improve host location by parasitoids, but forgetting associations between cues and hosts is equally essential as it integrates the temporal and spatial variation in cue reliability, such as a shift in volatile blend emitted by hostinfested plants (Kraemer and Golding 1997;Dunlap et al. 2009;Soravia et al. 2021). Following a temperature shock, the egg parasitoid Trissolcus basalis Wollaston retained its learned cues significantly longer than wasps held in control conditions (Abram et al. 2015). These results support the hypothesis that individuals living in an energetically costly environment retain information longer than those living in less costly environments (Dunlap et al. 2009). Snell-Rood et al. (2011) showed diverging resource allocation in the butterfly Pieris rapae (Lepidoptera: Pieridae) when foraging in a complex environment (i.e. new hosts or non-host environment). Females foraging in complex environments showed higher flight muscle development and, after gaining experience in this environment, increased offspring investment (higher egg size and lipid reserves) compared to females foraging in the control environment (Snell-Rood et al. 2011). The observed decrease in lifetime fecundity associated with an increase in cognition and learning capacities will lead to complex evolutionary life-history trade-offs in thermally costly environments (Dunlap et al. 2009;Snell-Rood et al. 2013).

The thermal landscape and its importance
Microclimatic thermal heterogeneity is affected by complex interactions between biotic and abiotic factors (Pincebourde and Woods 2012). Small herbivorous insects experience temperatures of the leaf surface (Pincebourde and Woods 2020). Although abiotic conditions drive leaf temperature, the plant, by regulating its transpiration, can have a cooler or warmer surface than the ambient air temperature (Cook and Dixon 1964;Leuzinger and Körner 2007;Pincebourde and Woods 2012). Field temperature measurements showed that the diversity in microclimatic conditions was correlated to the degree of landscape complexity, and aphid populations inhabiting these different microclimatic zones differed in thermotolerance (Tougeron et al. 2016). Feeding strategies used by herbivorous insects will impact the stomatal conductance and alter leaf surface temperature. Thus, feeding strategies can affect the microclimate that the herbivore experiences Casas 2006, 2019;Pincebourde et al. 2007). The adaptive nature of thermoregulation and micro-habitat selection needs to be considered in the broader context of species interactions (Woods et al. 2015;Pincebourde and Casas 2019). Moreover, organisms can shift their diel activity patterns to match favourable thermal conditions (e.g. night feeding, mid-day quiescence) using temporal variation in microclimatic conditions (Scheffers et al. 2017). The benefits of selecting better microclimatic conditions at both spatial and temporal scales need to be considered in terms of species interactions, as antagonistic interactions such as predation, parasitism, or competition can offset the beneficial effects of thermoregulation (Choutt et al. 2011).
Individuals can alter their thermal tolerance through various mechanisms to cope with their thermal environment. However, the type of strategy used or the adaptive value of these strategies will ultimately alter species interactions (Tituskin et al. 2022). Moreover, the community composition and the thermal responses of the species present will feedback on the ability of a given (or target) species to respond to shifts in thermal regimes (Davis et al. 1998b).

Consequences of fluctuating thermal regimes for species interactions and community structure
Species-specific physiological and behavioural responses to thermal fluctuation and extremes at the organismal level will influence species interactions, both trophic and nontrophic, with consequences at the community level (Gillespie et al. 2012) (Figure 3).

Consequences for trophic interactions
Consumer-resource interactions are at the heart of food web processes, and shifts in resource physiology and behaviour are likely to induce a change in consumer physiology and behaviour (Rosenblatt and Schmitz 2016). Temperature can alter an individual's nutritional requirements and nutritional value for its natural enemies by altering the physiological processes of both organisms. For example, higher temperatures may reduce leaf carbohydrate levels leading to an increased tissue consumption by herbivores (i.e. compensatory feeding) to reach their nutritional requirements (Bauerfeind and Fischer 2013;Jamieson et al. 2015). First, we discuss the effects of extreme temperatures on nutritional stoichiometry in tritrophic interactions, then we approach the specific case of the temperature size rule and its consequences for consumer-resource interactions. Finally, the role of behaviour on host-parasitoid trophic interactions is discussed in the light of changing climatic conditions.

Phytochemistry and nutritional status
Plant phytochemical composition is a strong driver of ecological processes and mediates plant-pollinator-natural enemy interactions via bottom-up processes (Rosenblatt and Schmitz 2016;Jamieson et al. 2017;Han et al. 2019). Plant phytochemistry fluctuates over time (e.g. year, season, day), allowing plants to optimise their metabolic activity to match their environmental conditions (Gols et al. 2007;Doghri et al. 2021). Mechanical wounding of Lima bean (Phaseolus lunatus L.; Fabaceae) leaves as a mimic of herbivore damage during the photo-or scotophase resulted in differential emission of herbivore-induced plant volatiles (HIPVs) (Arimura et al. 2008). Similarly, plant metabolite composition varies across time, differentially affecting the fitness of hosts and parasitoids (Liebelt et al. 2019). The composition of secondary metabolites in Brassicaceae crops in response to herbivory by Mamestra brassicae L. (Lepidoptera: Noctuidae) peaked at dawn or dusk compared to mid-day, suggesting that plants may anticipate potential threats to match their defences with the timing of a likely attack (Doghri et al. 2021). Recent studies indicate that plants having coevolved with multiple herbivore species may use circadian and seasonal rhythms to anticipate and adapt their defence strategies (Mertens et al. 2021;Philbin et al. 2021).
Besides mediating trophic interactions, plant chemical composition mediates herbivore immune responses against parasitoids and pathogens . Feeding on different plant species was found to alter the herbivore immune system and mediate parasitoid intrinsic larval competition . Immune responses and growth of immuno-challenged M. sexta caterpillars feeding on diverging resource quality showed a significant change in the encapsulation capacity of larvae feeding on the high-quality diet as opposed to the low-quality diet (Diamond and Kingsolver 2011). Host (and host-plant) selection and thermal conditions will likely drive novel host-parasitoid interaction strength and metacommunity structure. An increase in rearing temperature led to an increased egg  Fig. 3 Overview of Section "Consequences of fluctuating thermal regimes for species interactions and community structure" with the causal links between dynamic environmental signals and phenotype fitness and consequences for species interactions and community structure and dynamics encapsulation of the parasitoid Tranosema rostrale Brishke (Hymenoptera: Ichneumonidae) by its larval host Choristoneura fumiferana Clemens (Lepidoptera: Tortricidae) (Seehausen et al. 2017). Thermal stress can alter parasitoid attack rates and the defensive behavioural responses of hosts (Bannerman et al. 2011;le Lann et al. 2014a). Extreme temperature events may not always destabilise consumer-resource interactions due to opposite thermal effects on the interacting species (Bannerman et al. 2011;Boukal et al. 2019;Gvoždík and Boukal 2021).

Temperature-size-rule and consumer-resource interactions
Warmer thermal regimes affect growth rate and usually yield smaller body sizes in many ectothermic species (Kingsolver and Huey 2008). Body size is a known parameter to mediate prey-predator or host-parasitoid interactions. Smaller-sized prey may induce a shift in predation rate for bigger alternate prey species, or inversely smaller sized predators cannot attack bigger-sized prey (Boukal et al. 2019). The Temperature Size Rule can thus alter the strength of consumer-resource interactions by differentially affecting species growth rates (Atkinson 1994). Placing the different thermal responses in a trophic context, the trophic rank hypothesis holds that higher trophic levels are less thermo-tolerant than lower trophic levels; predators are expected to display a more substantial reduction in size than their prey (Voigt et al. 2003;Furlong and Zalucki 2017). However, the effects on trophic interactions seem more pronounced in aquatic ecosystems than in terrestrial ones (Boukal et al. 2019). In host-parasitoid interactions, host body size does not always correlate with the quantity of resources available for the parasitoid larvae. Koinobiont parasitoids can manipulate their host development to optimise growth and development time, unlike idiobiont parasitoids that arrest host development via paralysis (Harvey et al. 2004). Recent studies suggest that under extremely high temperatures, parasitoid larvae failed to control host development leading to increased mortality and abnormal host physiology (Moore et al. 2021;Wang et al. 2022). For idiobiont parasitoids that paralyse their host upon parasitisation, host body size represents a good proxy for the quantity of resources available to the larvae, that are likely more exposed to the thermal response of their host (Brodeur and Boivin 2004). New climatic patterns and increased unpredictability of extreme temperature events will likely disrupt coevolved interactions, thus influencing host-parasitoid community dynamics (Liebelt et al. 2019).

The role of behaviour
Although foraging activity, host-handling time and walking speed are strongly correlated to temperature following the principle of thermodynamics, changes in behaviour, such as activity levels and spatial orientation, alter the exploited ecological niche by a focal species and can have important consequences on trophic interactions (Moiroux et al. 2012). In a mesocosm experiment, Barton and Schmitz (2018) studied the spatial distribution of grasshoppers and spiders in response to day or night warming. In the reference and night warming treatments, grasshopper and spider spatial distributions on the plant overlapped during their diurnal activity, while in the day-warming treatment, spiders retreated to lower parts of the plant canopy resulting in a spatial mismatch with their prey. In the night-warming treatment, but not in the reference or day-warming treatments, spider and grasshopper distributions on the plant overlapped during nocturnal activity (Barton and Schmitz 2018). Females of the host Boloria eunomia (Lepidoptera: Nymphalidae) tend to lay their eggs in a sub-optimal habitat for their offspring but with lower parasitism prevalence by the parasitoid Cotesia eunomiae (Hymenoptera: Braconidae) (Choutt et al. 2011). Similarly, a study on P. xylostella oviposition preference showed that females selected oviposition sites based on the leaf position while the neonates foraged on leaves based on leaf developmental stage (young vs. mature) (Ang et al. 2014). A shift in the foraging time of the host or its parasitoid caused by a shift in microclimatic variables can potentially create a temporal or spatial mismatch, preventing the parasitoid to locate or access its hosts.
Overall, temperature effects on plant metabolites are context-specific as they interact with other abiotic and biotic stresses affecting insect community structure. Species-specific differences in thermal sensitivity will drive responses of complex consumer-resource interactions to changing climatic conditions. The thermal responses of parasitoid foraging efficiency, herbivore feeding rates and plant growth will play a crucial role in determining host-parasitoid population dynamics (Berggren et al. 2009). Over time, variation in plant phytochemistry evolved to optimise plant defences against herbivores, either direct defences caused by secondary metabolites and/or indirect defences mediated by volatile emissions (Mertens et al. 2021), but further research is needed to assess the impact of changing climatic conditions on tri-trophic interactions.
Research has mainly focused on bottom-up processes mediated by plant chemical profiles on host-parasitoid interactions, and less is known about the effects of thermal variation on top-down processes. It is important to note that thermal stress influences the emission of plant volatiles: in the brassicaceous plant Brassica nigra L. thermal stress resulted in a shift from terpenoids towards glucosinolate-derived volatiles being emitted (Kask et al. 2016). Volatile blend composition is known to influence behavioural responses of both herbivores and their parasitoids (Dicke and Lucas-Barbosa 2020). Top-down effects of herbivory via feeding and foraging strategies influence plant chemical profiles (Zhu et al. 2014). We can expect that a shift in these strategies, due to changes in thermal conditions, may prevent plants from mounting efficient chemical defences against herbivores (Rosenblatt and Schmitz 2016;Chidawanyika et al. 2019). However, thermal alterations in feeding strategies are constrained by other environmental factors, among which non-trophic interactions are important (Heinrich 1979;Greeney et al. 2012).

Consequences for non-trophic interactions
Non-trophic interactions between species, such as predator avoidance, are important for population dynamics and community structure (Sentis et al. 2017). The ecological niche a species occupies within a given environment partly depends on the non-consumptive effects that natural enemies have on their resources as well as mutualistic or antagonistic interactions with other species, for example as competitors (Dajoz 2006;Laughlin and Messier 2015). First the effects of warming conditions interacting with non-consumptive effects of parasitoids on their host as well as the potential cascading effects on community composition are discussed. Then, we explore the effects of differences in thermal tolerance on the competition between species. Finally, mutualistic interactions altering thermal tolerance and the outcome of trophic interactions in the context of climate change are explored.

Non-consumptive effects and apparent competition
In a 2-year mesocosm experiment, Barton and Schmitz (2018) recorded higher plant diversity in the day-warming treatment and lower in the night-warming treatments compared to the ambient-temperature mesocosm driven by changes in plant-plant competition affected by herbivory. The timing of warming influenced spatial niche exploitation of the spiders, which changed their non-consumptive effects on grasshoppers resulting in higher or lower herbivory pressure on the dominant species in the system, leading to changes in the plant community (Barton and Schmitz 2018). This shift in the ecological niche exploited by one species is likely to destabilise species interactions and community composition. Non-consumptive effects are common in insect communities (Laws 2017). The presence of parasitoids can alter host and non-host feeding behaviour and nutritional ecology (Ingerslew and Finke 2018;Cuny et al. 2019). However, little is known on the effects of thermal extremes on non-consumptive effects in parasitoids and on host apparent competition.

Thermal tolerance and interspecific competition
Based on the principle of mutual exclusion, two species with a perfectly overlapping ecological niche cannot coexist in the same environment, and one superior competitor dominates the interaction (Dajoz 2006). Thus individuals and species tend to reduce their niche overlap by attacking different stages of the same host or shifting their time of activity or spatial niche (Hood et al. 2021). However, environmental filtering is expected to reduce the range of an organism's phenotype (i.e. trait values), leading to converging functional traits at the community or guild level. le Lann et al. (2014b) compared several functional traits (i.e. development time, body mass, egg load, metabolic rate and energy use) between four coexisting parasitoid species of Drosophila exposed to higher constant temperatures. The reduction in trait divergence at higher temperatures resulted in an increase in competition between individuals and parasitoid species (le Lann et al. 2014b). A warming experiment involving two ant species showed that the less thermotolerant species suffered indirectly from warming through antagonistic interaction with a more thermotolerant ant species (Diamond et al. 2017). Thermal variation and extremes are likely to alter temporal and spatial resource partitioning between species, thus changing species' coexistence via thermal asymmetries in competitive interactions (Smith and Amarasekare 2018).

Mutualistic interactions
Despite the high degree of host specialisation, parasitoid species display overlapping niches competing for shared hosts. The plant species' identity or the presence of specific symbionts will reduce competition between competing species creating cryptic niches (Harvey et al. 2013;Poelman et al. 2014). Microorganisms such as bacteria, fungi or viruses interact with many insects and plants species in various ways Frago et al. 2020). These associations mediate various ecological interactions ranging from protecting the host against a parasitoid (e.g., Hamiltonella defensa Moran (Enterobacteriaceae)) via altering host physiology and nutritional properties, to increasing thermotolerance (Corbin et al. 2017;Frago et al. 2020). A recent study assessed the impact of day and night warming using fluctuating thermal regimes on the fitness gain provided by the protective symbiont H. defensa to the aphid A. pisum in the presence or absence of its endoparasitoid A. ervi (Higashi et al. 2020). Carrying H. defensa reduced aphid survival under all warming treatments regardless of the timing of warming. Moreover, H. defensa influenced parasitoid mummification success with a higher proportion under the warming treatment (Higashi et al. 2020). Mechanisms through which symbionts alter the thermotolerance may involve the higher physiological cost of carrying protective symbionts when the organism faces physiological stress (Corbin et al. 2017). Symbiont-mediated interactions and the effects of thermal fluctuation and temperature extremes on these interactions add another layer of complexity to the effects of thermal stress on parasitoid-host interactions.

Concluding remarks and future perspectives
Phenotypic plasticity is central to ecosystem functioning and should be included in studies aiming to predict eco-evolutionary responses of organisms to new thermal conditions. This paper highlights the importance of thermal variation and thermal history on species-specific fitness-related traits and performance. On a short time scale (a few hours) the damage caused by high-extreme temperatures can be repaired or compensated for during milder thermal periods (Bai et al. 2019;Ma et al. 2018). However, when the stress is prolonged for several days, different physiological responses can occur, allowing acclimation to warmer conditions, e.g., accumulation of heat shock proteins and metabolic compensation (le Lann et al. 2011;Pazouki et al. 2016;Stanton-Geddes et al. 2016;Tian et al. 2021). Moreover, the biotic context in which species develop affects the thermal performance of the focal species having consequences for community dynamics. The diversity of species interactions taking place in ecosystems makes predictions about community dynamics under climate change challenging.
The thermal environment influences ecological dynamics in countless ways through phenotypic plasticity at all levels of biological organisation. Here, we present promising avenues for future research on assessing species and community responses to thermal extremes such as heatwaves. Communities are often highly diverse, however, few species play a central role in the structuring and dynamics within these communities (Poelman and Kessler 2016). Assessing the phenotypic responses to changing environmental conditions of such keystone species, as well as the cascading effects on community dynamics are likely to give valuable insights into the processes at play and their relative importance. As plants are at the basis of most ecosystems, they represent a common link between various species. Their chemical profiles play a major role in shaping insect interactions and community dynamics. However, little is known about the effects of the timing of extreme events on plants and the (seasonal) dynamics of insect communities they sustain. This paper focused on the effects of variable thermal conditions on host-parasitoid interactions. The microclimatic heterogeneity and the capacity of arthropods to move across the thermal landscape can mitigate or exacerbate the effects of changing thermal conditions (Pincebourde et al. 2007;Rebaudo et al. 2016;Tougeron et al. 2016). Moreover, more accurate measurements of microclimatic conditions will inform the modelling of temperature effects on physiology and plasticity of insects that are ultimately dependent on body temperatures (von Schmalensee et al. 2021).
Thermal variation in natural ecosystems is characterised by periodic and stochastic fluctuations. The predictability of environmental variation is thought to favour adaptive phenotypic plasticity. In contrast, stochastic environments are thought to favour bet-hedging strategies. Bet-hedging produces various phenotypes in response to change itself and is not 1 3 necessarily adaptive (Bond et al. 2021;le Lann et al. 2021). Cyclical variation of environmental conditions seems to maintain higher intra-population trait variation than in stochastic environments, although populations originating from the latter displayed similar levels of plasticity (Bond et al. 2021;Park and Wootton 2021). This further highlights the importance of periodicity of environmental variation for life-history trait variation. One of the consequences of anthropogenic climate change is an increase in the frequency and magnitude of extreme weather events, thus an increase in stochasticity (Vasseur et al. 2014). Trophic interactions shape ecological communities and the effects of thermal variation on phenotypic plasticity will have consequences for such interactions. Parasitoid-host interactions are very intimate interactions where the parasitoid is integrated in the biology of the host. Parasitism represents a dominant lifestyle and is a very common interaction in various ecological communities (Forbes et al. 2018). Studying how dynamic changes in the thermal environment affect host and parasitoid separately is not adequate to fully understand how parasitoids influence the way that hosts deal with thermal variation and vice versa. Such understanding is crucial to appreciate how thermal variation influences ecological communities.