1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7177],{2003:(e,t,n)=>{"use strict";n.d(t,{default:()=>w});var o=n(95155),r=n(12115),a=n(88992),i=n(83045),s=n(74992),l=n(88472),c=n(51745),d=n(53455),u=n(56600);let p=function(){let{hasConsent:e=!0}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{setGeoLocationData:t}=(0,u.A)();(0,d.useQuery)({enabled:e,queryFn:async()=>{let e=await fetch("/nwapi/geolocation");if(!e.ok)throw Error("Failed to fetch geolocation data");let n=await e.json();return t(n),n},queryKey:["geolocation"]})},g=()=>((0,r.useEffect)(()=>{window.cmpUtils||function(){var e,t;(null==(e=performance)?void 0:e.mark)&&performance.mark("app.cmp.started");let n=document,o=window;o.cmpUtils={bypassed:!1,cmpQueue:[],consentInfo:{},debug:[],formRequestTypes:["Global DNS","Do Not Sell My Information","Delete My Personal Information","Access My Personal Information"],gcmDefaultsSet:!1,hasWwwInHostName:o.location.hostname.startsWith("www"),haveConsent:!1,interactionResponsWaitTime:100,locale:{site:"",user:""},timerStart:Date.now(),wrapperInit:!1,checkTCFApi(e,t){var n;let r=(n,r)=>{if(r&&("tcloaded"===n.eventStatus||"useractioncomplete"===n.eventStatus)){var a,i;let r=(null==n||null==(a=n.vendor)?void 0:a.consents)||{};null==(i=o.__tcfapi)||i.call(o,"removeEventListener",2,()=>{},n.listenerId),r&&o.cmpUtils.checkVendorConsent(r,e,()=>t({},!0),!1)}};null==(n=o.__tcfapi)||n.call(o,"ping",2,()=>{var e;null==(e=o.__tcfapi)||e.call(o,"addEventListener",2,r)})},checkVendorConsent(e,t,n){let r=!(arguments.length>3)||void 0===arguments[3]||arguments[3];return!0!==e[t]||o.CMP_GPP_OPTOUT||o.CMP_GPC_SET?(o.cmpUtils.log("cmpUtils
1- checkVendorConsent","consent DECLINED","vendorId ".concat(t," = ").concat(e[t])),r&&o.addEventListener("cmp.consent.change",()=>{o.cmpUtils.checkVendorConsent(e,t,()=>n({},!0),!1)},{once:!0}),!1):(o.cmpUtils.log("cmpUtils - checkVendorConsent","consent","vendorId ".concat(t," = ").concat(e[t])),n({},!0),!0)},emitEvent:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};o.dispatchEvent(new CustomEvent(e,{detail:t}))},formCompletionHandler(e){if(!e.origin.includes("onetrust"))return;o.cmpUtils.log("formCompletionHandler","event",e);let{data:t}=e,n=null;try{n=JSON.parse(t)}catch(e){if(e instanceof SyntaxError)return void o.cmpUtils.log("formCompletionHandler error","error",e)}if(n&&(o.scrollTo(0,0),o.cmpUtils.formRequestTypes.filter(e=>n.requestTypes.includes(e)).length>0)){var r;o.cmpUtils.emitEvent("cmp.consent.submit"),null==(r=o.Optanon)||r.RejectAll(),o.removeEventListener("click",o.cmpUtils.formCompletionHandler)}},getAlertBoxCookieValue:()=>o.cmpUtils.getCookieMatch("OptanonAlertBoxClosed"),getCookieMatch:e=>n.cookie.match("[; ]*".concat(e,"=([^;]+)")),getCMPConsent(e,t,n){let r=!(arguments.length>3)||void 0===arguments[3]||arguments[3],a=!o.GDPR&&!o.CMP_GPP_OPTOUT&&!o.CMP_GPC_SET,i=()=>{r&&o.addEventListener("cmp.consent.change",()=>{"function"==typeof n&&n(!0)},{once:!0})};if(!t)return"function"==typeof n&&n(!!a||!!o.CMP_CONSENT),i(),!0;switch(e){case"category":try{var s;if(a||(null==(s=o.CMP_CONSENT_GROUPS)?void 0:s.includes(String(t))))return o.cmpUtils.log("cmpUtils
1- getCMPConsent","category '".concat(t,"' consent"),!0),n&&n(!0),!0;i();break}catch(e){break}case"vendor":if(a&&n)return n(!0),!0;return void 0===o.__tcfapi?o.cmpUtils.cmpQueue.push([Number(t),()=>n&&n(!0)]):o.cmpUtils.checkTCFApi(Number(t),()=>n&&n(!0)),!0}return!1},getConsentGroups(){let e="",t=o.cmpUtils.getCookieMatch("OptanonConsent");if(t){let n=t[1].match(/groups=(.*?)(&|$)/);n&&decodeURIComponent(n[1]).split(",").forEach(function(t){if(t.includes(":")){let n=t.split(":");"1"===n[1]&&(e+=(e?",":"")+n[0])}})}return{cmpConsentGroups:e}},getGPCStatus:()=>!!navigator.globalPrivacyControl,getHdmCookie(e){let t=o.cmpUtils.getCookieMatch(e);return t?JSON.parse(t[1]):""},getUserCountry(){let e=o.cmpUtils.getHdmCookie("location_data"),t=null==e?void 0:e.country_code;return o.cmpUtils.log("cmpUtils","getUserCountry - countryCode",t||""),!!t&&t.toLowerCase()},gpp:{getOptOut(){let e=o.cmpUtils.getHdmCookie("hdm_cmp"),t=!1;if(e&&"object"==typeof e&&"gpp"in e){var n;t=null==(n=e.gpp)?void 0:n.optOut}return!!t&&(o.cmpUtils.log("cmpUtils
1- GPP","getOptOut - hdmCmp.gpp.optOut",!!t),!!t)},getSection:()=>o.cmpUtils.gpp.section,getSupportedAPISectionName(e,t){let[n]=e,o="";return t.forEach(e=>{let[t,r]=e.split(":");parseInt(t,10)===n&&(o=r)}),o},init(){var e;o.cmpUtils.log("cmpUtils - GPP","init",!0),null==(e=o.__gpp)||e.call(o,"addEventListener",o.cmpUtils.gpp.setOptOut),o.cmpUtils.gpp.listenerSet=!0},listenerSet:!1,section:void 0,setOptOut(e){o.cmpUtils.log("cmpUtils - GPP","setOptOut - evt",e);let{pingData:t}=e,n=!1;if(t&&"loaded"===t.cmpStatus){let{applicableSections:e,parsedSections:r,supportedAPIs:a}=t;o.cmpUtils.log("cmpUtils - GPP","setOptOut - applicableSections: ",e),o.cmpUtils.gpp.section=o.cmpUtils.gpp.getSupportedAPISectionName(e,a),o.cmpUtils.log("cmpUtils - GPP","setOptOut - section: ",o.cmpUtils.gpp.section);let i=r[o.cmpUtils.gpp.section];if(i){o.cmpUtils.log("cmpUtils - GPP","setOptOut - parsedInfo: ",i);let{PersonalDataConsents:e,SaleOptOut:t,SharingOptOut:r,TargetedAdvertisingOptOut:a}=i;n=1===t||1===r||1===e||1===a}o.cmpUtils.log("cmpUtils
1- GPP","setOptOut - optOut: ",n),o.cmpUtils.gpp.updateHdmCmpCookie(n)}},updateHdmCmpCookie(e){if(!o.cmpUtils.getHdmCookie("hdm_cmp")||o.CMP_GPP_OPTOUT!==e){let t={gpp:{optOut:e,section:o.cmpUtils.gpp.getSection(),usNatOptOut:e,uspNatOptOut:e}};o.CMP_GPP_OPTOUT=e,o.cmpUtils.setHdmCmpCookie(t)}}},hasModal:()=>!!n.querySelector("#onetrust-banner-sdk"),interactionResponse:()=>new Promise(e=>{setTimeout(e,o.cmpUtils.interactionResponsWaitTime),requestAnimationFrame(()=>{setTimeout(e,0)})}),isUSSiteAndUser:()=>"us"===o.cmpUtils.locale.site&&"us"===o.cmpUtils.locale.user,log(e,t,n){let r=Date.now()-o.cmpUtils.timerStart;o.cmpUtils.debug.push({evt:t,msg:n,name:e,ts:r})},setCookie(e){var t;let{minutes:n,name:r,value:a}=e,i="".concat(r,"=").concat(a);if(n){let e;e=new Date("delete"===n?0:Date.now()+60*n*1e3),i+="; expires=".concat(e.toUTCString())}let s=o.cmpUtils.hasWwwInHostName?o.location.hostname.replace(/(www-stage)|(www)/,""):"";i+=s?"; domain=".concat(s):"";let l=null==(t=o.__SITE)?void 0:t.locale_path;i+="; path=".concat(l?"/".concat(l,"/"):"/"),o.cmpUtils.log("cmpUtils
1- setCookie","cookie","".concat(i,";")),document.cookie="".concat(i,";")},setDeclinedConsentState(){o.cmpUtils.log("cmpUtils - setDeclinedConsentState","Optanon",!!o.Optanon),o.Optanon&&(o.cmpUtils.log("cmpUtils - setDeclinedConsentState","Reject All - Optanon",o.Optanon),o.Optanon.RejectAll())},setGlobalValues(){let e=!!o.CMP_CONSENT;o.cmpUtils.log("cmpUtils - setGlobalValues","currentConsent",e);let t=!!o.CMP_WITHDRAWN;o.cmpUtils.log("cmpUtils - setGlobalValues","currentWithdrawn",t),o.GDPR_CONSENT_MODAL=o.cmpUtils.hasModal,o.CMP_CONSENT_MODAL=o.cmpUtils.hasModal;let{cmpConsentGroups:n}=o.cmpUtils.getConsentGroups();o.cmpUtils.log("cmpUtils - setGlobalValues","cmpConsentGroups",n),o.GDPR_CONSENT_GROUPS=n,o.CMP_CONSENT_GROUPS=n,o.cmpUtils.isUSSiteAndUser()&&(o.CMP_GPP_OPTOUT=!!o.DO_NOT_SELL||o.cmpUtils.gpp.getOptOut(),o.cmpUtils.log("cmpUtils - setGlobalValues","win.CMP_GPP_OPTOUT",o.CMP_GPP_OPTOUT)),o.CMP_GPC_SET=o.cmpUtils.getGPCStatus(),o.cmpUtils.log("cmpUtils - setGlobalValues","win.CMP_GPC_SET",o.CMP_GPC_SET),o.cmpUtils.haveConsent=!!/C0002|C0003|C0004|C0005/.test(n),o.cmpUtils.log("cmpUtils
1- setGlobalValues","cmpUtils.haveConsent",o.cmpUtils.haveConsent),o.GDPR_CONSENT=!!o.cmpUtils.haveConsent,o.CMP_CONSENT=!!o.cmpUtils.haveConsent,o.cmpUtils.log("cmpUtils - setGlobalValues","win.CMP_CONSENT",o.CMP_CONSENT);let r=o.cmpUtils.getAlertBoxCookieValue();o.GDPR_WITHDRAWN=!!(!o.cmpUtils.haveConsent&&r),o.CMP_WITHDRAWN=!!(!o.cmpUtils.haveConsent&&r),o.cmpUtils.log("cmpUtils - setGlobalValues","win.CMP_WITHDRAWN",o.CMP_WITHDRAWN),(o.CMP_CONSENT!==e||o.CMP_WITHDRAWN!==t)&&(o.cmpUtils.log("cmpUtils - setGlobalValues","event","cmp.consent.change"),o.cmpUtils.emitEvent("cmp.consent.change"))},setGoogleConsentModeDefaults(){var e,t;if(null==(t=window)||null==(e=t.gptLayer)?void 0:e.gcmDefaultsSet)return o.cmpUtils.gcmDefaultsSet=!0,!1;let n=new Date;o.dataLayer=o.dataLayer||[],o.gtag=function(){o.dataLayer.push(arguments)},o.gtag("js",n);let r="granted",a={};o.GDPR?r="denied":o.DO_NOT_SELL&&"us"===o.cmpUtils.locale.site&&(r="denied"),o.cmpUtils.isUSSiteAndUser()&&(a={region:["US"]});let i={ad_personalization:r,ad_storage:r,ad_user_data:r,analytics_storage:r,functionality_storage:r,personalization_storage:r,security_storage:r,wait_for_update:500,...a};return o.gtag("consent","default",i),o.cmpUtils.gcmDefaultsSet=!0,o.cmpUtils.log("cmpUtils
1- setGoogleConsentModeDefaults","defaults",i),!0},updateGoogleConsentMode(){if(!o.gtag||!o.cmpUtils.gcmDefaultsSet||o.GDPR||!o.DO_NOT_SELL||"us"!==o.cmpUtils.locale.site)return!1;let e={ad_personalization:"denied",ad_storage:"denied",ad_user_data:"denied",analytics_storage:"denied",functionality_storage:"denied",personalization_storage:"denied",security_storage:"denied"};return o.gtag("consent","update",e),o.cmpUtils.log("cmpUtils - updateGoogleConsentMode","update",e),!0},setHdmCmpCookie(e){if(!e)return;let t=o.cmpUtils.getHdmCookie("hdm_cmp"),n={minutes:525600,name:"hdm_cmp",value:JSON.stringify({..."object"==typeof t&&t?t:{},...e})};o.cmpUtils.log("cmpUtils - setHdmCmpCookie","cookieInfo",n),o.cmpUtils.setCookie(n)},useDeclinedConsentState(){var e,t,n,r;let a=(null==(r=o.HRST)||null==(n=r.adConfig)||null==(t=n.modules)||null==(e=t.oneTrust)?void 0:e.declinedConsentState)||!1;return o.cmpUtils.log("cmpUtils - useDeclinedConsentState","hasDeclinedConsentState",a),a},waitForOTCookie(e){let t=0;return new Promise(function n(r,a){t>=1e3&&a("".concat(e," does not exist")),o.cmpUtils.getCookieMatch(e)?r(!0):t<1e3&&(t+=100,setTimeout(n.bind(null,r,a),100))})},waitForTCF(){if(void 0!==o.__tcfapi){o.cmpUtils.cmpQueue.length&&(o.cmpUtils.cmpQueue.forEach(e=>{Array.isArray(e)&&o.cmpUtils.checkTCFApi(...e)}),o.cmpUtils.cmpQueue=[]);return}setTimeout(o.cmpUtils.waitForTCF,100)}},function(){var e,t,n;(null==(e=performance)?void 0:e.mark)&&performance.mark("app.cmp.logic.started");let o=window,r=document;o.cmpUtils.log("loadCmpScript - loaded","cmpUtils",o.cmpUtils),o.cmpUtils.locale={site:(null==(n=o.__SITE)||null==(t=n.locale)?void 0:t.split("-").pop())||"us",user:o.cmpUtils.getUserCountry()||"us"},o.cmpUtils.setGoogleConsentModeDefaults(),o.cmpUtils.setGlobalValues(),o.getCMPConsent=o.cmpUtils.getCMPConsent,window.GDPR&&o.cmpUtils.waitForTCF();let a=r.querySelector(".ot-sdk-show-settings");a&&a.addEventListener("click",async function(){await o.cmpUtils.interactionResponse(),o.cmpUtils.emitEvent("onetrust_pc_modal")},!1),o.OptanonWrapper=function(){o.cmpUtils.log("loadCmpScript - OptanonWrapper","started - cmpUtils.wrapperInit",o.cmpUtils.wrapperInit),o.cmpUtils.wrapperInit=!0,o.cmpUtils.waitForOTCookie("OptanonConsent").then(()=>{var e;
1let t=o.cmpUtils.getAlertBoxCookieValue();o.cmpUtils.useDeclinedConsentState()&&!t&&o.cmpUtils.setDeclinedConsentState(),o.cmpUtils.setGlobalValues();let n=t?new Date(t[1]).getTime():0,a=!!n&&Date.now()-n<250,i=/C0002|C0003|C0004|C0005/.test(o.OptanonActiveGroups||""),s=o.cmpUtils.hasModal();if(s){o.ga_modal_tracking||(o.ONETRUST_MODAL=!0,o.cmpUtils.log("loadCmpScript - OptanonWrapper","modal event","onetrust_modal"),o.cmpUtils.emitEvent("onetrust_modal"));let e=r.querySelector("#onetrust-pc-btn-handler");e&&e.addEventListener("click",function(){o.cmpUtils.log("loadCmpScript - OptanonWrapper","modal event","onetrust_pc_modal"),o.cmpUtils.emitEvent("onetrust_pc_modal")},{once:!0})}s&&a&&(i?(o.cmpUtils.log("loadCmpScript - OptanonWrapper","modal event","onetrust_accept"),o.cmpUtils.emitEvent("onetrust_accept")):(o.cmpUtils.log("loadCmpScript - OptanonWrapper","modal event","onetrust_reject"),o.cmpUtils.emitEvent("onetrust_reject"))),o.cmpUtils.consentInfo={consentGroups:o.CMP_CONSENT_GROUPS||"",gpcSet:o.CMP_GPC_SET||!1,haveConsent:!!o.cmpUtils.haveConsent},o.cmpUtils.isUSSiteAndUser()&&(o.cmpUtils.consentInfo.gpp={optOut:o.CMP_GPP_OPTOUT||!1,section:o.cmpUtils.gpp.getSection()||""}),o.cmpUtils.setHdmCmpCookie(o.cmpUtils.consentInfo),o.cmpUtils.emitEvent("gdpr.consent.set",o.cmpUtils.consentInfo),o.cmpUtils.emitEvent("cmp.consent.set",o.cmpUtils.consentInfo),(null==(e=performance)?void 0:e.mark)&&performance.mark("app.cmp.logic.finished")})},o.cmpUtils.wrapperInit||o.OptanonWrapper(),o.addEventListener("consent.onetrust",e=>{o.cmpUtils.log("loadCmpScript","Event - consent.onetrust - e",e)},!1),o.addEventListener("OneTrustGroupsUpdated",e=>{o.cmpUtils.isUSSiteAndUser()&&o.__gpp&&!o.cmpUtils.gpp.listenerSet&&(o.cmpUtils.gpp.init(),o.cmpUtils.log("loadCmpScript","Event - OneTrustGroupsUpdated - init GPP",!0)),o.cmpUtils.log("loadCmpScript","Event - OneTrustGroupsUpdated - e",e)},!1),o.addEventListener("message",o.cmpUtils.formCompletionHandler,!1)}(),o.cmpUtils.emitEvent("app.cmpScriptLoaded"),(null==(t=performance)?void 0:t.mark)&&performance.mark("app.cmp.end")}()},[]),null);var m=n(86535);let w=(0,a.withErrorBoundary)(()=>{let{hasConsent:e}=(0,c.S)({id:i.Ok.PERSONALIZATION,type:"category"});return p({hasConsent:!!e}),(0,r.useEffect)(()=>{try{s.Y.initialize(),(0,l.G)(),s.Y.track("Application initialized successfully",{context:{timestamp:new Date().toISOString()},tags:["app-init"]})}catch(e){s.Y.error(e instanceof Error?e:Error("Initialization failed"),{tags:["app-init","error"]})}},[]),(0,o.jsx)(g,{})},{FallbackComponent:m.c,onError:(e,t)=>{s.Y.error(e,{context:{componentStack:t.componentStack},tags:["app-init","error-boundary"]})}})},10423:(e,t,n)=>{"use strict";n.d(t,{Z:()=>r});var o=n(58718);let r=e=>e[o.w4]},18498:(e,t,n)=>{"use strict";n.d(t,{K:()=>r});var o=n(95847);let r=(e,t)=>{if(!o.A)return null;t=t||window.location.search;let n=e.replace(/[[]]/g,"\\$&"),r=new RegExp("[?&]".concat(n,"(=([^&#]*)|&|#|$)")).exec(t);return r?r[2]?decodeURIComponent(r[2].replace(/\+/g," ")):"":null}},24217:(e,t,n)=>{"use strict";n.d(t,{default:()=>w});var o=n(12115),r=n(99776),a=n(31306);let i={},s=e=>{var t;let n=null!=(t=null==e?void 0:e.sub)?t:null==e?void 0:e.myloUsername;return n?"cmp_account_".concat(n):null},l=e=>{let t=s(e);if(!t)return i;try{return JSON.parse(window.sessionStorage.getItem(t)||"{}")||{}}catch(e){return{}}},c=(e,t)=>{let n=s(e);if(!n){i={...i,...t};return}try{let o={...l(e),...t};window.sessionStorage.setItem(n,JSON.stringify(o))}catch(e){i={...i,...t}}},d=e=>null!=e&&!!e.ccpaOptOut||!!l(e).optOut||!!window.DO_NOT_SELL;var u=n(84573);let p=["https://privacyportal.onetrust.com"],g=/C0002|C0004|C0005/,m=function(){var e,t,n,o,r,a,i;let s=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;if(!window.GDPR){if(null==(e=window.Optanon)?void 0:e.RejectAll){(!window.DO_NOT_SELL||g.test(window.OptanonActiveGroups||""))&&(window.DO_NOT_SELL=!0,window.Optanon.RejectAll(),null==(i=window.cmpUtils)||null==(a=i.updateGoogleConsentMode)||a.call(i));return}if(s<20)return void window.setTimeout(()=>m(s+1),100);window.DO_NOT_SELL=!0,null==(n=window.cmpUtils)||null==(t=n.setDeclinedConsentState)||t.call(n),null==(r=window.cmpUtils)||null==(o=r.updateGoogleConsentMode)||o.call(r)}},w=()=>{var e;let{data:t}=(0,u.Q)(),n=(0,r.useQueryClient)(),i=null!=(e=null==t?void 0:t.isAuthenticated)&&e,s=(0,o.useRef)(!1),g=(0,o.useCallback)(()=>{!(!i||d(t))&&(s.current||(s.current=!0,(0,a.OT)("/nwapi/privacy/ccpa-optout",{method:"POST"}).then(()=>{c(t,{gpcSyncAttempted:!0,optOut:!0}),n.setQueryData(["session"],e=>e?{...e,ccpaOptOut:!0}:e),m()}).catch(e=>{(e=>{l(e).gpcSyncAttempted&&c(e,{gpcSyncAttempted:!1})})(t),console.error("Failed to persist CCPA opt-out to CIAM",e)}).finally(()=>{s.current=!1})))},[i,t,n]),w=(0,o.useCallback)(()=>{let e=window.cmpUtils;return!!e&&(!!(!i||!t||l(t).gpcSyncAttempted||!e.isUSSiteAndUser()||!e.getGPCStatus()||d(t))||(c(t,{gpcSyncAttempted:!0}),g(),!0))},[i,t,g]);return(0,o.useEffect)(()=>{d(t)&&m();let e=()=>{d(t)&&m()};return window.addEventListener("OneTrustGroupsUpdated",e),()=>window.removeEventListener("OneTrustGroupsUpdated",e)},[t]),(0,o.useEffect)(()=>
1{if(!i||!t)return;let e=()=>w();return e(),window.addEventListener("cmp.consent.set",e),window.addEventListener("app.cmpScriptLoaded",e),()=>{window.removeEventListener("cmp.consent.set",e),window.removeEventListener("app.cmpScriptLoaded",e)}},[i,t,w]),(0,o.useEffect)(()=>{let e=e=>{if(!p.includes(e.origin))return;let t=!1;try{var n,o;let{requestTypes:r}=JSON.parse(e.data),a=null!=(o=null==(n=window.cmpUtils)?void 0:n.formRequestTypes)?o:[];r&&Array.isArray(r)&&(t=r.some(e=>a.includes(e)))}catch(e){console.error("failed to parse onetrust form submission data",e);return}t&&(g(),window.scrollTo(0,0),console.warn("Consent being removed for user as OptOut form has been submitted."),setTimeout(()=>{window.OneTrust&&"function"==typeof window.OneTrust.RejectAll?window.OneTrust.RejectAll():console.warn("OneTrust.RejectAll is not available"),window.cmpUtils&&"function"==typeof window.cmpUtils.emitEvent?window.cmpUtils.emitEvent("cmp.consent.submit"):console.warn("window.cmpUtils is not available to emit consent submit event"),window.location.replace("/")},3e3))};return window.addEventListener("message",e),()=>window.removeEventListener("message",e)},[g]),(0,o.useEffect)(()=>{let e=()=>g();return window.addEventListener("cmp.consent.submit",e),()=>window.removeEventListener("cmp.consent.submit",e)},[g]),null}},26159:(e,t,n)=>{"use strict";n.d(t,{Permutive:()=>i});var o=n(12115),r=n(83045),a=n(23114);let i=()=>((0,o.useEffect)(()=>{(0,a.A)("/ad-scripts/moapt-permutive.js",[r.Ok.ADVERTISEMENT],{async:!0}).catch(e=>{console.error("Failed to load ComScore script:",e)})},[]),null)},28359:(e,t,n)=>{"use strict";n.d(t,{G:()=>r});var o=n(18498);let r=async()=>{let e="_ga_clk",t=["fbclid","gclid","msclkid"],n=(()=>{for(let r of t){var e,n;let t=(0,o.K)(r);if(t&&(null==(n=window.gptLayer)||null==(e=n.utils)?void 0:e.MD5))return{hid:window.gptLayer.utils.MD5(t),id:t,type:r}}return null})()||(()=>{let t=(e=>{let t=document.cookie.split("; ").find(t=>t.startsWith("".concat(e,"=")));return t?decodeURIComponent(t.split("=")[1]):null})(e);try{return t?JSON.parse(t):null}catch(e){return null}})();return n?(((e,t,n)=>{let o=new Date;o.setTime(o.getTime()+60*n*6e4);let r=encodeURIComponent(t);document.cookie="".concat(e,"=").concat(r,"; expires=").concat(o.toUTCString(),"; path=/; SameSite=Lax")})(e,JSON.stringify(n),.5),n):{}}},37146:(e,t,n)=>{"use strict";n.d(t,{default:()=>es});var o=n(95155),r=n(12115),a=n(20063),i=n(68321),s=n(88992),l=n(81981),c=n(82411),d=n(12881),u=n(6214),p=n(72143),g=n(70131),m=n(57373);function w(){let e=window.gptLayer;return(0,g.T)()||(0,p.f)()||!!window.CMP_GPP_OPTOUT||!!window.CMP_GPC_SET||!!window.CMP_WITHDRAWN||!!(null==e?void 0:e.cmpGppOptOut)||!!(null==e?void 0:e.cmpGpcSet)||(0,m.DA)()||(0,m.Ev)()}var h=n(58553),f=n(80946),v=n(56600),C=n(58718);let _=e=>{let t=v.A.getState()[C.yL][C.JE.RefreshIntervalId]||{};if(e)return void clearInterval(t[e]);Object.entries(t).forEach(e=>{let[,t]=e;clearInterval(t)})};var E=n(61562),S=n(4979);let U=0;function b(e){return!(0>=U)&&e.getSlotElementId().includes(E.B2.MobileAdhesion)}v.A.subscribe(e=>e.embeddedGalleryModalDepth,e=>{U=e},{equalityFn:S.x,fireImmediately:!0});let y=e=>!!(b(e)||e.getTargeting(c.t.IsCurrentlyVisible).indexOf("false")>-1||e.getTargeting("sponsored").indexOf("true")>-1||e.getTargeting("sect").indexOf("video")>-1||e.getTargeting("subs").indexOf("rankings")>-1||e.getTargeting("k").indexOf("buyersguide")>-1||e.getTargeting("fluid").indexOf("bottom_adhesion")>-1||e.getTargeting("sect").indexOf("homepage")>-1||e.getTargeting("slot").indexOf("nod")>-1),T=e=>!(b(e)||e.getTargeting("sponsored").indexOf("true")>-1||e.getTargeting("sect").indexOf("video")>-1||e.getTargeting("subs").indexOf("rankings")>-1||e.getTargeting("k").indexOf("buyersguide")>-1||e.getTargeting("fluid").indexOf("bottom_adhesion")>-1||e.getTargeting("fluid").indexOf("stm")>-1||e.getTargeting("sect").indexOf("homepage")>-1||e.getTargeting("slot").indexOf("nod")>-1);var x=n(18498),P=n(88472),N=n(37645);let A=e=>{let{slot:t}=e,n=t.getSlotElementId(),o=t.getAdUnitPath(),r=new Date,a=(0,x.K)("disableAdRefresh"),i="1"===a||"true"===a||""===a;if(f.X.NEXT_PUBLIC_FEATURE_AD_REFRESH){_(n);let o=setInterval(()=>{y(t)||googletag.cmd.push(()=>{(0,N.S$)(t,N.IS.NoInteraction),i||googletag.pubads().refresh([t])})},l.h.NEXT_PUBLIC_AD_REFRESH_FREQUENCY);
1v.A.getState().setGptRefreshIntervalId(e,o),T(t)&&window.googletag.cmd.push(()=>{t.setTargeting(c.t.HasBecomeViewable,"true")})}v.A.getState().setGptImpressionViewableTime(e,r),(0,P.e)("ImpressionViewableEvent",{adPath:o,slotId:n})},O=e=>{let t=e.slot.getSlotElementId(),n=e.slot.getAdUnitPath();(0,P.e)("SlotOnLoad",{adPath:n,slotId:t})};var L=n(15692),I=n(31547);let k=e=>{let{slot:t}=e,n=t.getSlotElementId(),o=t.getAdUnitPath();(0,I.F)("mtAdRequested","true"),(0,P.e)("SlotRequested",{adPath:o,slotId:n}),f.X.NEXT_PUBLIC_FEATURE_AD_REFRESH&&(t.getTargeting(c.t.HasBecomeViewable).indexOf("true")>-1&&window.googletag.cmd.push(()=>{t.clearTargeting(c.t.HasBecomeViewable)}),t.getTargeting(c.t.HasLeftViewportOnce).indexOf("true")>-1&&window.googletag.cmd.push(()=>{t.clearTargeting(c.t.HasLeftViewportOnce)}))},R=e=>{let t=e.slot.getSlotElementId(),n=e.slot.getAdUnitPath(),{advertiserId:o,campaignId:r,creativeId:a,creativeTemplateId:i,lineItemId:s}=e.slot.getResponseInformation()||{};(0,P.e)("SlotResponseReceived",{adPath:n,advertiserId:o,campaignId:r,creativeId:a,creativeTemplateId:i,lineItemId:s,slotId:t})};var M=n(98898);let D=e=>{let{inViewPercentage:t,slot:n}=e,o=n.getSlotElementId();t>=50?(v.A.getState().setGptSlotVisibility(o,C.q8.Visible),(0,M.X3)(n)):v.A.getState().setGptSlotVisibility(o,C.q8.NotVisible),f.X.NEXT_PUBLIC_FEATURE_AD_REFRESH&&f.X.NEXT_PUBLIC_AD_REFRESH_OUT_OF_VIEWPORT&&T(n)&&(0===t&&n.getTargeting(c.t.HasBecomeViewable).indexOf("true")>-1&&window.googletag.cmd.push(()=>{n.setTargeting(c.t.HasLeftViewportOnce,"true")}),n.getTargeting(c.t.HasLeftViewportOnce).indexOf("true")>-1&&t>0&&n.getTargeting(c.t.NoOutOfViewportRefresh).indexOf("false")>-1&&window.googletag.cmd.push(()=>{(0,N.S$)(n,N.IS.OutOfViewport),googletag.pubads().refresh([n]),(0,P.e)("SlotRefreshed",{slotId:o})})),t>=50?(n.setTargeting(c.t.IsCurrentlyVisible,"true"),v.A.getState().setGptImpressionViewableTime(e,new Date)):n.setTargeting(c.t.IsCurrentlyVisible,"false")};var j=n(95847),G=n(83045),V=n(23114),B=n(6889),H=n(28359);let F=async()=>{let{hid:e,type:t}=await (0,H.G)();"undefined"!=typeof googletag&&googletag.pubads&&e&&t&&googletag.cmd.push(()=>{googletag.pubads().setTargeting("clid","".concat(t,"-").concat(e))})};var W=n(17670),Z=n(51371);let{NEXT_PUBLIC_AD_BUNDLE_PATH:K,NEXT_PUBLIC_AD_BUNDLE_PREFIX:Y}=l.h;function X(e){let t=new URLSearchParams(window.location.search).get("adbundle_pr");if(!e)return;let n=Y;return t&&n.includes(".com")&&(n=n.replace(".com",".net")),"".concat(n,"/").concat(t||K,"/").concat(e)}var z=n(35857),$=n(51745),J=n(82196),q=n(92062),Q=n(580),ee=n.n(Q),et=n(22654),en=n.n(et),eo=n(37575),er=n(86535);let ea={fetchMarginPercent:l.h.NEXT_PUBLIC_AD_FETCH_MARGIN,mobileScaling:l.h.NEXT_PUBLIC_AD_MOBILE_SCALING,renderMarginPercent:l.h.NEXT_PUBLIC_AD_RENDER_MARGIN},ei={fetchMarginPercent:l.h.NEXT_PUBLIC_AD_FETCH_MARGIN_FEATURED,mobileScaling:l.h.NEXT_PUBLIC_AD_MOBILE_SCALING_FEATURED,renderMarginPercent:l.h.NEXT_PUBLIC_AD_RENDER_MARGIN_FEATURED},es=(0,s.withErrorBoundary)(()=>{let e=(0,a.usePathname)(),t=X("autos/motortrend/nod.js"),n=X("autos/motortrend/suggestive-selling.js"),{hasConsent:s}=(0,$.S)({id:G.Ok.ADVERTISEMENT,type:"category"}),{isUS:p}=(0,J.Ay)(),g=(0,r.useRef)(void 0);return(0,r.useEffect)(()=>{!g.current||s||p||(googletag.cmd.push(()=>{googletag.destroySlots()}),window.location.reload()),g.current=s},[s,p]),(0,r.useEffect)(()=>{(0,h.A)(),function(){if(window.superHeroNativeAds)return;let e={createListeners:()=>{window.addEventListener("message",t=>{let{origin:n}=t;if(n.indexOf("googlesyndication")>-1){let o=t.data;"nauloaded"===o.task&&o.adUnit&&o.adUnit.indexOf("36117602")>-1&&e.handleAdMessage(t,n)}},!1)},getIframe(e){if(!e)return null;let t=document.getElementsByTagName("iframe");for(let n=0;n<t.length;n++)if(t[n].contentWindow===e)return t[n];return null},handleAdMessage(t,n){let o=t.data,{source:r}=t,{height:a}=o;if(a){let t=e.getIframe(r);if(!t)return;let o=t.parentElement;if(!o)return;t.style.height="".concat(a,"px"),o.style.height="".concat(a,"px"),(0,P.e)("SuperHeroNative:resize",{height:a,origin:n})}},init(){e.createListeners()}};e.init(),window.superHeroNativeAds=!0}();let t=(0,z.ms)(e||""),n=!!e&&((e=>{let t=e.split("/").filter(e=>e);if(3!==t.length&&4!==t.length)return!1;let n="cars"===t[0],o=t[t.length-1],r=/^\d{4}$/.test(o)||/^[a-zA-Z0-9-]+$/.test(o);return n&&r})(e)||(e=>{let t=e.split("/").filter(e=>e);if(2!==t.length)return!1;let n="cars"===t[0],o=t[t.length-1],r=/^[a-zA-Z0-9-]+$/.test(o);return n&&r})(e)),o="/"===e;googletag.cmd.push(()=>{var e,r,a,i,s,d,u,p,g,m,h,f,v,C,_,E,S,U,b,y,T,x,P;googletag.destroySlots(),googletag.pubads().setTargeting(c.t.PhotoSlided,"false"),googletag.pubads().setTargeting(c.t.NoOutOfViewportRefresh,String(t)),googletag.pubads().setTargeting(c.t.NoTabSwitchRefresh,String(t)),googletag.pubads().setTargeting(c.t.NoUserActivityRefresh,String(t)),googletag.pubads().enableLazyLoad(n||o?ei:ea),googletag.pubads().collapseEmptyDivs();let N=(0,Z.T)();0!==Object.keys(N).length&&Object.entries({...N}
1).forEach(e=>{let[t,n]=e;googletag.pubads().setTargeting(t,n)}),F();let A=null!=(T=null==(i=window)||null==(a=i.HRST)||null==(r=a.article)||null==(e=r.tags)?void 0:e.filter(e=>null!=e))?T:[],O=null!=(x=(null==(p=window)||null==(u=p.HRST)||null==(d=u.landing)||null==(s=d.value)?void 0:s.url)||(null==(f=window)||null==(h=f.HRST)||null==(m=h.article)||null==(g=m.collection)?void 0:g.map(e=>null==e?void 0:e.url).filter(e=>null!=e)))?x:[],L=null!=(P=null==(S=window)||null==(E=S.HRST)||null==(_=E.article)||null==(C=_.contextualTags)||null==(v=C.hctx)?void 0:v.filter(e=>null!=e))?P:[],I=(null==(b=window)||null==(U=b.HRST)?void 0:U.contentId)||"";googletag.pubads().setTargeting("content",I||[]),googletag.pubads().setTargeting("cat",A||[]),googletag.pubads().setTargeting("clc",O||[]),googletag.pubads().setTargeting("hctx",L||[]),googletag.pubads().setTargeting("browserlanguage",(null==(y=navigator)?void 0:y.language)||"en-US");let k=function(){window.abValues=window.abValues||{};let e=window.abValues.rnd||(window.abValues.rnd=Math.ceil(10*Math.random()).toString()),t=window.abValues.rndSop||(window.abValues.rndSop=Math.ceil(100*Math.random()).toString());t=String(t).padStart(3,"0");let n="undefined"==typeof document?null:document.cookie.match("[; ]*".concat("gpt_session_ab","=([^;]+)")),o=n?n[1]:"s".concat(Math.ceil(10*Math.random()).toString()),r=new Date(Date.now()+18e5);return document.cookie="gpt_session_ab=".concat(o,"; expires=").concat(r.toUTCString(),"; path=/;"),[e,"sop".concat(t),o]}();k.length>0&&googletag.pubads().setTargeting("ab",k),Object.keys(N).some(e=>"test"===e.toLowerCase())||W.O_||googletag.pubads().setTargeting("test",l.h.NEXT_PUBLIC_AD_TEST_FIELD_VALUE),googletag.pubads().enableSingleRequest();let R=w();googletag.pubads().setPrivacySettings({nonPersonalizedAds:R,restrictDataProcessing:R})}),(0,d.Y1)()},[e]),(0,r.useEffect)(()=>{let e=()=>{(0,h.A)(),googletag.cmd.push(()=>{let e=w();googletag.pubads().setPrivacySettings({nonPersonalizedAds:e,restrictDataProcessing:e})})};return window.addEventListener("cmp.consent.change",e),window.addEventListener("OneTrustGroupsUpdated",e),window.addEventListener("consent.onetrust",e),()=>{window.removeEventListener("cmp.consent.change",e),window.removeEventListener("OneTrustGroupsUpdated",e),window.removeEventListener("consent.onetrust",e)}},[]),(()=>{let{setLastScrollTime:e}=(0,v.A)(),t=(0,r.useCallback)(()=>v.A.getState()[C.yL][C.JE.ImpressionViewableTime]||{},[]),n=(0,r.useCallback)(()=>{let n=new Date,o=t();googletag.cmd.push(()=>{let e=[];for(let[t,r]of Object.entries(o)){let o=new Date(r).getTime(),a=(0,eo.A)(t);f.X.NEXT_PUBLIC_AD_REFRESH_ON_INTERACTION&&a&&n.getTime()-o>l.h.NEXT_PUBLIC_AD_REFRESH_FREQUENCY_ALT&&a.getTargeting(c.t.NoUserActivityRefresh).indexOf("false")>-1&&(e.push(t),_(t),y(a)||((0,N.S$)(a,N.IS.UserInteraction),googletag.pubads().refresh([a])))}e.forEach(e=>{v.A.getState().resetGptImpressionViewableTime(e)})}),e(n)},[e,t]),o=(0,r.useCallback)(()=>{n()},[n]),a=(0,r.useMemo)(()=>en()(()=>{n()},200,{leading:!0,trailing:!0}),[n]),i=(0,r.useCallback)(()=>{let e=t();document.hidden||googletag.cmd.push(()=>{let t=[];for(let n of Object.keys(e)){let e=(0,eo.A)(n);e&&T(e)&&e.getTargeting(c.t.NoTabSwitchRefresh).indexOf("false")>-1&&(t.push(n),(0,N.S$)(e,N.IS.TabSwitch),googletag.pubads().refresh([e]))}t.forEach(e=>{v.A.getState().resetGptImpressionViewableTime(e)})})},[t]);(0,r.useEffect)(()=>{if(!W.fL){if(window.addEventListener("visibilitychange",i),f.X.NEXT_PUBLIC_FEATURE_AD_REFRESH){let e="onscrollend"in window,t=e?"scrollend":"scroll",n=e?o:a;return window.addEventListener(t,n),()=>{window.removeEventListener(t,n),a.cancel&&a.cancel()}}return()=>{window.removeEventListener("visibilitychange",i)}}},[a,o,i])})(),(()=>{let e=(e=>"2xl"===e?"xl":e)((0,q.dv)()),[t,n]=(0,r.useState)(e),o=(0,r.useMemo)(()=>ee()(()=>{window.googletag=window.googletag||{cmd:[]},window.googletag.cmd.push(function(){let e=window.googletag.pubads().getSlots(),t=U>0?e.filter(e=>!b(e)):e;t.length>0&&window.googletag.pubads().refresh(t,{changeCorrelator:!1})})},500),[]);(0,r.useEffect)(()=>{e!==t&&(o(),n(e))},[e,t,o])})(),(0,r.useEffect)(()=>((0,h.A)(),(0,u.Ay)(),j.A&&(window.__iasPET=window.__iasPET||{},window.__iasPET.queue=window.__iasPET.queue||[],window.__iasPET.pubId="931688",(0,V.A)("https://cdn.adsafeprotected.com/iasPET.1.js",[G.Ok.PERSONALIZATION])),googletag.cmd.push(function(){l.h.NEXT_PUBLIC_AD_HEADER_BIDDING&&googletag.pubads().disableInitialLoad(),googletag.pubads().addEventListener("slotOnload",O),googletag.pubads().addEventListener("slotRequested",k),googletag.pubads().addEventListener("slotRenderEnded",L.A),googletag.pubads().addEventListener("slotResponseReceived",R),googletag.pubads().addEventListener("slotVisibilityChanged",D),googletag.pubads().addEventListener("impressionViewable",A)}),()=>{googletag.cmd.push(function(){googletag.pubads().removeEventListener("slotOnload",O),googletag.pubads().removeEventListener("slotVisibilityChanged",D),googletag.pubads().removeEventListener("slotRequested",k),googletag.pubads().removeEventListener("slotRenderEnded",L.A),googletag.pubads().removeEventListener("slotResponseReceived",R),googletag.pubads().removeEventListener("impressionViewable",A)})}),[]),l.h.NEXT_PUBLIC_AD_HEADER_BIDDING&&(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(i.default,{"ccpa-opt-out-ids":"C0004","ccpa-opt-out-lspa":"true",onError:B.dP,onLoad:B.ii,src:t}),(0,o.jsx)(i.default,{"ccpa-opt-out-ids":"C0004","ccpa-opt-out-lspa":"true",onError:B.Qn,onLoad:B.rX,src:n}),(0,o.jsx)(i.default,{"ccpa-opt-out-ids":"C0004","ccpa-opt-out-lspa":"true",onError:e=>{(0,B.at)(e)},onLoad:()=>{(0,B.Rf)()},src:"https://c.amazon-adsystem.com/aax2/apstag.js"})]})},{FallbackComponent:er.c})},39006:(e,t,n)=>{"use strict";n.d(t,{PrivacyBanner:()=>C});var o=n(95155),r=n(12115),a=n(81981);let i="owner_transfer_banner_served=",s="us_mags_privacy_banner_served=",l="".concat(i,"true; Max-Age=").concat(86400*(a.h.NEXT_PUBLIC_PRIVACY_BANNER_RUN_DAYS||30),"; Path=/; SameSite=Lax"),c="".concat(s,"true; Max-Age=").concat(86400*(a.h.NEXT_PUBLIC_US_MAGS_PRIVACY_BANNER_RUN_DAYS||90),"; Path=/; SameSite=Lax");var d=n(82196),u=n(92062),p=n(2821),g=n(65121),m=n(92117),w=n(14e3);let h=e=>{let{onManualClose:t}=e,[n,s]=(0,r.useState)(!0),[c,h]=(0,r.useState)(!1),{geoData:f}=(0,d.Ay)();if((0,r.useEffect)(()=>{var e;if(a.h.NEXT_PUBLIC_PRIVACY_BANNER_FEATURE&&(null==f||null==(e=f.country)?void 0:e.toUpperCase())==="US"&&((e,t)=>{let n=new Date(e);if(isNaN(n.getTime()))return!1;let o=new Date(n);o.setDate(n.getDate()+t);let r=new Date,a=new Date(r.getFullYear(),r.getMonth(),r.getDate());return a>=n&&a<=o})(a.h.NEXT_PUBLIC_PRIVACY_BANNER_START_DATE,a.h.NEXT_PUBLIC_PRIVACY_BANNER_RUN_DAYS)){if(document.cookie.split(";").map(e=>e.trim()).some(e=>e.startsWith(i)))return void s(!1);let{hostname:e}=window.location,t=e.split(".").slice(-2).join(".");
1document.cookie=(e=>e.includes(".")&&!e.endsWith("localhost")&&e.split(".").length>2)(e)?"".concat(l,"; Domain=.").concat(t):l;let n=setTimeout(()=>void s(!1),a.h.NEXT_PUBLIC_PRIVACY_BANNER_DISPLAY_MILLISEC+700);return h(!0),()=>clearTimeout(n)}},[null==f?void 0:f.country]),!n)return null;let v=(0,m.A)("".concat(w.Z2.OwnerTransferBanner.Welcome," {termsOfUse} ").concat(w.Z2.OwnerTransferBanner.IncludingOur," {disputeResolutionProcedures} ").concat(w.Z2.OwnerTransferBanner.AndYouAcknowledge," {privacyNotice} ").concat(w.Z2.OwnerTransferBanner.PleaseReadOur," {privacyNotice} ").concat(w.Z2.OwnerTransferBanner.ToLearnMore),{disputeResolutionProcedures:(0,o.jsx)(u.N_,{"data-id":g.Co.PrivacyDisputeResolutionLink,"data-parent":g.Co.PrivacyOwnerTransferBanner,href:"https://www.hearst.com/-/us-magazines-terms-of-use#_DISPUTE_RESOLUTION",children:w.Z2.OwnerTransferBanner.DisputeResolutionProcedures}),privacyNotice:(0,o.jsx)(u.N_,{"data-id":g.Co.PrivacyNoticeLink,"data-parent":g.Co.PrivacyOwnerTransferBanner,href:"https://www.hearst.com/-/us-magazines-privacy-notice",children:w.Z2.OwnerTransferBanner.PrivacyNotice}),termsOfUse:(0,o.jsx)(u.N_,{"data-id":g.Co.PrivacyTermsOfUseLink,"data-parent":g.Co.PrivacyOwnerTransferBanner,href:"https://www.hearst.com/-/us-magazines-terms-of-use",children:w.Z2.OwnerTransferBanner.TermsOfUse})});return(0,o.jsxs)(u.o5,{as:"div",className:(0,p.A)("bg-neutral-1 text-neutral-8 fixed bottom-0 left-0 z-50 flex w-full items-center px-6 py-4 text-center text-sm transition-all duration-500 md:px-6 md:py-4 md:text-base",c&&n?"translate-y-0":"translate-y-full"),children:[(0,o.jsx)("span",{className:"m-auto max-w-4xl md:flex-none",children:v}),(0,o.jsx)("button",{"aria-label":"Close",className:"ml-2 flex-shrink-0 cursor-pointer text-xl md:ml-4 md:text-2xl","data-id":g.Co.PrivacyOwnerTransferBannerCloseButton,"data-parent":g.Co.PrivacyOwnerTransferBanner,onClick:function(){s(!1),null==t||t()},children:"\xd7"})]})};var f=n(56600);let v=()=>{var e;let[t,n]=(0,r.useState)(!1),{geoData:i,loading:l}=(0,d.Ay)(),h=(0,u.dv)(),{Sticky:v}=(0,f.A)(),C=(null!=(e=null==v?void 0:v.bottomAdhesion)?e:0)>0;function _(){n(!1)}if((0,r.useEffect)(()=>{var e;if(l)return;if(!a.h.NEXT_PUBLIC_US_MAGS_PRIVACY_BANNER_FEATURE||(null==i||null==(e=i.country)?void 0:e.toUpperCase())!=="US"||document.cookie.split(";").map(e=>e.trim()).some(e=>e.startsWith(s)))return void n(!1);n(!0);let{hostname:t}=window.location,o=t.split(".").slice(-2).join("."),r=(e=>e.includes(".")&&!e.endsWith("localhost")&&e.split(".").length>2)(t)?"".concat(c,"; Domain=.").concat(o):c;document.cookie=r;let d=setTimeout(()=>_(),a.h.NEXT_PUBLIC_US_MAGS_PRIVACY_BANNER_DISPLAY_MILLISEC+700);return()=>clearTimeout(d)},[null==i?void 0:i.country,l]),!t)return null;let E=(0,m.A)(w.Z2.USMagazinesPrivacyBanner.MainText,{disputeResolution:(0,o.jsx)(u.N_,{"data-id":g.Co.PrivacyDisputeResolutionLink,"data-parent":g.Co.PrivacyNoticeLinkUSMags,href:"https://www.hearst.com/-/us-magazines-terms-of-use#_DISPUTE_RESOLUTION",target:"_blank",children:w.Z2.USMagazinesPrivacyBanner.DisputeResolution}),noticeLink:(0,o.jsx)(u.N_,{"data-id":g.Co.PrivacyNoticeLink,"data-parent":g.Co.PrivacyNoticeLinkUSMags,href:"https://www.hearst.com/-/us-magazines-privacy-notice",target:"_blank",children:w.Z2.USMagazinesPrivacyBanner.NoticeLink}),termsLink:(0,o.jsx)(u.N_,{"data-id":g.Co.PrivacyTermsOfUseLink,"data-parent":g.Co.PrivacyNoticeLinkUSMags,href:"https://www.hearst.com/-/us-magazines-terms-of-use",target:"_blank",children:w.Z2.USMagazinesPrivacyBanner.TermsLink})});return(0,o.jsxs)(u.o5,{as:"div",className:(0,p.A)("bg-neutral-1 text-neutral-8 fixed left-0 z-50 flex w-full items-center justify-center text-left text-sm transition-all duration-500 md:p-6 md:text-base","lg"!==h&&"xl"!==h&&"2xl"!==h&&C?"bottom-[55px] px-2 py-2":"bottom-0 px-6 py-4",t?"translate-y-0":"translate-y-full"),children:[(0,o.jsx)("span",{className:"m-auto max-w-4xl md:flex-none",children:E}),(0,o.jsx)("button",{"aria-label":"Close",className:"ml-2 flex-shrink-0 cursor-pointer text-xl md:ml-4 md:text-2xl","data-id":g.Co.PrivacyMagsBannerCloseButton,"data-parent":g.Co.PrivacyNoticeLinkUSMags,onClick:_,children:"\xd7"})]})},C=()=>{let[e,t]=(0,r.useState)(!1),[n,l]=(0,r.useState)(!1),[c,u]=(0,r.useState)(!1),{geoData:p}=(0,d.Ay)();return((0,r.useEffect)(()=>{var e;if((null==p||null==(e=p.country)?void 0:e.toUpperCase())==="US"){let e=document.cookie.split(";").map(e=>e.trim()),n=e.some(e=>e.startsWith(i)),o=e.some(e=>e.startsWith(s));a.h.NEXT_PUBLIC_US_MAGS_PRIVACY_BANNER_FEATURE&&!o?(l(!0),u(!0)):n||o||(t(!0),u(!0))}},[null==p?void 0:p.country]),(0,r.useEffect)(()=>
1{if(e){let e=setTimeout(()=>{t(!1),setTimeout(()=>{l(!0)},100)},a.h.NEXT_PUBLIC_PRIVACY_BANNER_DISPLAY_MILLISEC);return()=>clearTimeout(e)}},[e]),(0,r.useEffect)(()=>{if(n){let e=setTimeout(()=>{l(!1)},a.h.NEXT_PUBLIC_US_MAGS_PRIVACY_BANNER_DISPLAY_MILLISEC);return()=>clearTimeout(e)}},[n]),c)?(0,o.jsxs)(o.Fragment,{children:[e&&(0,o.jsx)(h,{onManualClose:function(){t(!1),setTimeout(()=>{l(!0)},100)}}),n&&(0,o.jsx)(v,{})]}):null}},40269:(e,t,n)=>{"use strict";n.d(t,{HRSTSetupClient:()=>d});var o=n(12115),r=n(20063),a=n(88992),i=n(80946),s=n(98898),l=n(74992),c=n(86535);let d=(0,a.withErrorBoundary)(e=>{let{adConfig:t,brandSlug:n}=e,a=(0,r.usePathname)();return(0,o.useEffect)(()=>{let e={};try{var o;let r=document.querySelector("#__HRST_DATA__");(null==r?void 0:r.textContent)&&(e=JSON.parse(r.textContent)||{});let a=null==(o=document.querySelector('link[rel="canonical"]'))?void 0:o.href;e.adConfig=t,e.article={canonicalUrl:a,pageUrl:window.location.href,...e.article||{}},e.site={...e.site||{},brand_slug:n};let l=Object.entries(i.X).reduce((e,t)=>{let[n,o]=t;return n.startsWith("NEXT_PUBLIC_FEATURE")&&(e[n]=o),e},{});e.flags=Object.freeze(l),window.HRST=e,(0,s.aY)()&&window.dispatchEvent(new CustomEvent("jamdataloaded"))}catch(t){l.Y.log({error:t instanceof Error?t:Error(String(t)),level:"error",msg:"Error in HRSTSetupClient effect"}),window.HRST=e}},[a,t,n]),(0,o.useEffect)(()=>{let e=()=>{window.dispatchEvent(new CustomEvent("hrstandjamdataloaded"))};return window.addEventListener("jamdataloaded",e),()=>{window.removeEventListener("jamdataloaded",e)}},[]),null},{FallbackComponent:c.c})},45836:()=>{},46858:(e,t,n)=>{"use strict";n.d(t,{PushlySetup:()=>c});var o=n(12115),r=n(17670),a=n(65121),i=n(83045),s=n(23114),l=n(74992);let c=()=>((0,o.useEffect)(()=>{window.Nitrous=window.Nitrous||[],window.Nitrous.push(async()=>{try{var e,t,n,o;let c=r.O_?"domainKey":"nonProdDomainKey",d=null==(o=window.HRST)||null==(n=o.adConfig)||null==(t=n.modules)||null==(e=t.pushly)?void 0:e[c];if(d&&await window.Nitrous.getFeatureFlag(a.of.pushly)){(0,s.A)("https://cdn.p-n.io/pushly-sdk.min.js?domain_key=".concat(d),[i.Ok.ADVERTISEMENT],{async:!0}).catch(e=>{l.Y.error(Error("Failed to load pushly script:",{cause:e}))});let e=window.Nitrous.getDeviceId();window.PushlySDK=window.PushlySDK||[],window.pushly=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];window.PushlySDK.push(t)},window.pushly("load",{domainKey:d,...e&&{externalId:e}})}}catch(e){}})},[]),null)},51745:(e,t,n)=>{"use strict";n.d(t,{S:()=>a});var o=n(12115),r=n(83045);function a(e){let{id:t,type:n}=e,[a,i]=(0,o.useState)(!1),[s,l]=(0,o.useState)(!1),[c,d]=(0,o.useState)("");(0,o.useEffect)(()=>{let e=()=>{try{let e=document.cookie.match(/OptanonConsent=([^;]+)/);if(!e){i(!1),l(!0),d("");return}let o=decodeURIComponent(e[1]);if(o===c&&s)return;d(o);let a=o.match(/groups=([^&]+)/);if(!a){i(!1),l(!0);return}let u=decodeURIComponent(a[1]).split(","),p=r.hs[t];if("category"===n){let e=u.find(e=>e.startsWith("".concat(p,":")));if(e){let[,t]=e.split(":");i("1"===t)}else i(!1)}else i(!1);l(!0)}catch(e){console.error("Error checking consent:",e),i(!1),l(!0)}};e();let o=()=>{setTimeout(e,100)};window.addEventListener("OneTrustGroupsUpdated",o),window.addEventListener("consent.onetrust",o);let a=setInterval(e,250),u=window.OptanonWrapper;return window.OptanonWrapper=function(){u&&u(),setTimeout(e,200)},()=>{window.removeEventListener("OneTrustGroupsUpdated",o),window.removeEventListener("consent.onetrust",o),clearInterval(a),u&&(window.OptanonWrapper=u)}},[t,n,s,c]);let u=(0,o.useCallback)(()=>{window.cmpUtils&&"function"==typeof window.cmpUtils.emitEvent?window.cmpUtils.emitEvent("cmp.consent.submit"):console.warn("window.cmpUtils is not available to emit consent submit event")},[]);return{hasConsent:a,isReady:s,rejectAllConsent:(0,o.useCallback)(()=>{window.Optanon&&"function"==typeof window.Optanon.RejectAll&&window.Optanon.RejectAll()},[]),submitConsentChange:u}}},56065:(e,t,n)=>{"use strict";n.d(t,{default:()=>l});var o=n(12115),r=n(20063),a=n(88992),i=n(86535),s=n(56600);let l=(0,a.withErrorBoundary)(()=>{let{setNavigation:e}=(0,s.A)(),t=(0,r.usePathname)(),n=(0,o.useRef)(t);return(0,o.useEffect)(()=>
1{if(t!==n.current){var o;e({previousPath:null!=(o=n.current)?o:""}),n.current=t}},[t,e]),null},{FallbackComponent:i.c})},66420:(e,t,n)=>{"use strict";n.d(t,{MoaptSetup:()=>m});var o=n(12115),r=n(20063);let a=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:window.location.href;try{let o=new URL(n);return o.searchParams.get(e)?o.searchParams.get(e):t}catch(r){let o=new RegExp("[&?]".concat(e,"=?([^&]*)?")).exec(n);if(null===o)return t;return void 0===o[1]||o[1]}};function i(e,t){var n,o,r;let a=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!!t&&("object"!=typeof t||0!==t.length)&&(window.gptLayer=window.gptLayer||{},window.gptLayer.kv=window.gptLayer.kv||{},window.gptLayer.kv[e]=window.gptLayer.kv[e]||[],Array.isArray(t)||(t=[t]),t.forEach(t=>{var n,o,r,a,i;null!=t&&""!==t&&""!==(t=(t=String(t)).replace(/[^\w\s-.\\/]/gi,""))&&(!Array.isArray(null==(o=window.gptLayer)||null==(n=o.kv)?void 0:n[e])||(null==(i=window.gptLayer)||null==(a=i.kv)||null==(r=a[e])?void 0:r.includes(t))||window.gptLayer.kv[e].push(t))}),a&&(n=e,(o=t)&&("object"!=typeof o||0!==o.length)&&((null==(r=window.gptLayer)?void 0:r.template)==="vehicle-category-rankings"&&function(e){var t,n;let o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["mak","mod"],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return o.includes(e)&&!!(null==(t=window.gptLayer)?void 0:t.videoKVP)&&!!(null==(n=window.gptLayer)?void 0:n.videoKVP[e])&&Array.isArray(window.gptLayer.videoKVP[e])&&window.gptLayer.videoKVP[e].length>=r}(n,["mak","mod"])||(window.gptLayer=window.gptLayer||{},window.gptLayer.videoKVP=window.gptLayer.videoKVP||{},window.gptLayer.videoKVP[n]=window.gptLayer.videoKVP[n]||[],Array.isArray(o)||(o=[o]),o.forEach(e=>{var t,o;null!=e&&""!==e&&""!==(e=(e=String(e)).replace(/[^\w\s-.\\/]/gi,""))&&Array.isArray(null==(o=window.gptLayer)||null==(t=o.videoKVP)?void 0:t[n])&&!window.gptLayer.videoKVP[n].includes(e)&&window.gptLayer.videoKVP[n].push(e)})))),!0)}function s(e,t){var n;window.gptLayer=window.gptLayer||{},window.gptLayer.kv=window.gptLayer.kv||{},delete window.gptLayer.kv[e],t&&(n=e,window.gptLayer=window.gptLayer||{},window.gptLayer.videoKVP=window.gptLayer.videoKVP||{},delete window.gptLayer.videoKVP[n])}let l={domain:()=>document.domain||window.location.hostname,get(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];for(let n=document.cookie.split(";"),o=0;o<n.length;o++){let[r,...a]=n[o].replace(/^\s+/,"").split("="),i=a.join("=");if(r===e)return t?i:decodeURIComponent(i)}return""},set(e,t,n){let o="".concat(e,"=").concat(t);if(void 0!==n){let e=new Date(Date.now()+60*n*1e3);o+="; expires=".concat(e.toUTCString())}return document.cookie="".concat(o,"; path=/"),this.get(e)===t},test(e){return!!this.get(e)}};function c(e,t,n){var o;let r={evt:t,msg:n,name:e,ts:Date.now()-((null==(o=window.gptLayer)?void 0:o.timerStart)||Date.now())},i=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"background: #27323A; color: #A3F7BF":"background: #A3F7BF; color: #27323A";(()=>{let e=a("ads_debug")||l.get("ads_debug"),t=!1;return"true"===e&&(t=!0),l.set("ads_debug",e,"true"===e?60:-1),t})()&&console.log("%c%s",i,"".concat((r.ts/1e3).toFixed(2),"s - [ADS] - ").concat(r.name," - ").concat(r.evt," - "),"string"==typeof r.msg?r.msg.substring(0,750):r.msg)}let d={m:0,t:760,d:980},u={...d,d:1024},p=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=Array.from(document.scripts).find(t=>t.src===e||t.getAttribute("src")===e);if(o)return void o.addEventListener("load",t,{once:!0});let r=document.createElement("script");r.src=e,r.async=!0,Object.entries(n).forEach(e=>{let[t,n]=e;r.setAttribute(t,n)}),r.addEventListener("load",t,{once:!0}),document.head.appendChild(r)},g=["AF","AL","DZ","AS","AD","AO","AI","AQ","AG","AM","AW","AZ","BH","BD","BB","BY","BZ","BJ","BM","BT","BO","BA","BW","BR","IO","VG","BN","BG","BF","BI","CV","KH","CM","BQ","KY","CF","TD","CN","CC","KM","CK","CI","HR","CW","CY","CZ","CD","DJ","DM","DO","EG","SV","GQ","ER","EE","SZ","ET","FK","FO","FJ","FI","GF","PF","GA","GE","GH","GI","GR","GL","GD","GP","GU","GT","GG","GN","GW","GY","HT","HN","HU","IS","ID","IQ","IM","IL","JM","JE","JO","KZ","KE","KI","XK","KW","KG","LA","LV","LB","LS","LR","LY","LI","LT","LU","MO","MG","MW","MV","ML","MT","MH","MQ","MR","MU","YT","FM","MD","MC","MN","ME","MS","MA","MZ","MM","NA","NR","NP","NC","NI","NE","NG","NU","NF","MK","MP","OM","PK","PW","PS","PA","PG","PY","PN","QA","CG","RE","RW","BL","SH","KN","LC","MF","PM","VC","WS","SM","ST","SN","RS","SC","SL","SX","SK","SI","SB","SO","SS","LK","SD","SR","SJ","TJ","TZ","BS","GM","TL","TG","TO","TT","TN","TR","TM","TC","TV","VI","UG","UA","UY","UZ","VU","VE","VN","WF","EH","YE","ZM","ZW"],m=()=>{let e=(0,r.usePathname)();return(0,o.useEffect)(()=>{try{(()=>{let e=["gad_source","gad_campaignid","gbraid","utm_campaign","utm_medium","utm_source"];
1e.forEach(e=>{s(e,!0)});let t="gpt_utm",n={};try{let e=l.get(t);e&&(n=JSON.parse(e))}catch(e){n={}}let o=e.reduce((e,t)=>{let o=a(t)||n[t];return o&&(i(t,o,!0),e[t]=o),e},{});return 0!==Object.keys(o).length&&l.set(t,JSON.stringify(o),30)})(),(()=>{s("pt",!0);let e=((e,t)=>{let n="utm_".concat(e),o=a(n,"",null!=t?t:window.location.href);if(o)return String(o);try{let t=l.get("gpt_utm");if(t){let o=JSON.parse(t);return o[n]||o[e]||""}}catch(t){c("Utils","getUtmVal - error parsing gpt_utm cookie for ".concat(e),t)}return""})("campaign");if(!e)return;let t=[{pattern:/^ign/i,value:"ign"},{pattern:/^dda/i,value:"dda"},{pattern:/^mgu.*_prog(_|$)/i,value:"mgua"},{pattern:/^mgu.*_comm(_|$)/i,value:"mguc"},{pattern:/^mgu/i,value:"mgu"}].find(t=>{let{pattern:n}=t;return n.test(e)});t&&i("pt",t.value,!0)})()}catch(e){c("moaptAdLoader","something went wrong",e)}!function(){var e,t;null==(e=(t=window).getCMPConsent)||e.call(t,"vendor",815,()=>{(()=>{var e,t,n,o,r,a;let i,s=null==(o=window.HRST)||null==(n=o.adConfig)||null==(t=n.modules)||null==(e=t.blockthrough)?void 0:e.id;if(s&&(null==(a=window.HRST)||null==(r=a.article)?void 0:r.template)!=="videohub"&&"d"===(e=>{var t,n;let o,r=e||d;!e&&(null==(n=window)||null==(t=n.gptLayer)?void 0:t.isHDS)&&(r=u);let a=window.innerWidth;return Object.keys(r).forEach(e=>{a>=r[e]&&(o=e)}),o})())return!(window.GDPR||(i=(()=>{let e=l.get("location_data");if(e)try{return JSON.parse(e).country_code}catch(e){}return!1})())&&g.includes(i))&&(performance.mark("BT loader - start"),p("https://btloader.com/tag?o=".concat(s,"&upapi=true"),()=>{performance.mark("BT loader - end")}))})()})}(),window.googletag=window.googletag||{cmd:[]},window.googletag.cmd.push(()=>{var e,t;(null==(e=window.gptLayer)?void 0:e.kv)&&Object.entries(null==(t=window.gptLayer)?void 0:t.kv).forEach(e=>{let[t,n]=e;null!=n&&googletag.pubads().setTargeting(t,n)})})},[e]),null}},66944:(e,t,n)=>{"use strict";n.d(t,{AIChatbot:()=>k});var o=n(95155),r=n(12115),a=n(20063),i=n(92062),s=n(40667),l=n(65121),c=n(61562),d=n(74992);function u(e){let t=JSON.parse(localStorage.getItem(c.UZ.AIChatbotMessages)||"[]");try{localStorage.setItem(c.UZ.AIChatbotMessages,JSON.stringify([...t,e]))}catch(e){d.Y.log({error:e,level:"error",msg:"Error saving message to localStorage"})}}var p=n(14e3),g=n(85409),m=n(89440),w=n.n(m);function h(e){let{handleSubmit:t,initialAutoScroll:n,input:r,isLoading:a,setInput:s}=e;return(0,o.jsxs)("form",{className:"flex w-full flex-row items-center gap-x-2 pt-2 sm:pt-4",onSubmit:e=>{e.preventDefault(),e.stopPropagation(),t(e)},children:[(0,o.jsx)("input",{className:"border-neutral-6 bg-neutral-8 placeholder:text-neutral-5 dark:border-neutral-5 dark:bg-neutral-2 dark:shadow-neutral-1 h-[40px] w-full resize-none overflow-y-auto rounded-lg border border-solid px-[15px] py-[5px] text-base shadow-lg placeholder:text-base disabled:cursor-not-allowed dark:shadow-md",onChange:e=>s(e.target.value),placeholder:p.U$.InputPlaceholder,ref:e=>{n&&(null==e||e.focus())},value:r}),(0,o.jsx)(i.K0,{"aria-label":"Send Message Button","data-id":l.Co.AIChatbotSendMessageButton,"data-parent":l.Co.AIChatbotForm,disabled:a,type:"submit",children:(0,o.jsx)(w(),{path:g.hI8,size:"100%"})})]})}function f(){return(0,o.jsx)("svg",{className:"stroke-[#141416] stroke-[1.5] dark:stroke-[#FCFCFD]",fill:"none",height:"24",viewBox:"0 0 24 24",width:"24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)("path",{d:"M2.00606 4.03779C2.79665 3.61577 3.44372 2.95231 3.85775 2.14491C4.26987 2.95211 4.91395 3.61569 5.70136 4.0378C4.9142 4.45797 4.26999 5.11845 3.85776 5.92224C3.44363 5.11823 2.79642 4.45786 2.00606 4.03779ZM12.1508 4.78183C13.2653 8.55748 16.1499 11.5412 19.8139 12.6813C16.1506 13.8158 13.2654 16.7849 12.1508 20.5435C11.0307 16.7843 8.13138 13.8157 4.45179 12.6812C8.1321 11.5413 11.0309 8.55812 12.1508 4.78183ZM18.3825 20.0378C19.1731 19.6158 19.8202 18.9523 20.2342 18.1449C20.6463 18.9521 21.2904 19.6157 22.0778 20.0378C21.2906 20.458 20.6464 21.1185 20.2342 21.9222C19.8201 21.1182 19.1729 20.4579 18.3825 20.0378Z",id:"Union"})})}function v(e){let{handleClose:t}=e;return(0,o.jsxs)("div",{className:"border-neutral-6 dark:border-neutral-4 flex w-full items-center border-b border-solid pb-2 sm:pb-4",children:[(0,o.jsxs)("div",{className:"flex flex-1 flex-row items-center gap-1",children:[(0,o.jsx)(f,{}),(0,o.jsxs)("span",{className:"flex items-center",children:[(0,o.jsx)(i.o5,{className:"text-neutral-4 dark:text-neutral-5 text-[1.5rem]",disableColorScheme:!0,style:{fontWeight:300},children:p.U$.HeaderAsk}),(0,o.jsx)(i.o5,{className:"text-primary-2 text-[1.5rem]",disableColorScheme:!0,style:{fontWeight:900},children:p.U$.HeaderAIChatbot}),(0,o.jsx)(i.o5,{className:"bg-neutral-4 text-neutral-6 -translate-y-2 scale-75 rounded-sm px-2 py-1 text-xs uppercase",disableColorScheme:!0,variant:"caption2",children:p.cu.AIChatbotBetaText})]})]}),t&&(0,o.jsx)(i.K0,{"aria-label":"Close Button",colorScheme:"transparent","data-id":l.Co.AIChatbotCloseIconButton,"data-parent":l.Co.AIChatbotHeader,onClick:t,children:(0,o.jsx)(w(),{path:g.hyP,size:"100%"})})]})}var C=n(2821),_=n(63629),E=n(17670);function S(){return(0,o.jsxs)("svg",{fill:"none",height:"40",viewBox:"0 0 40 40",width:"40",xmlns:"http://www.w3.org/2000/svg",children:[(0,o.jsx)("title",{children:"MotorTrend AI"}),(0,o.jsx)("rect",{fill:"#E90C17",height:"40",rx:"20",width:"40"}),(0,o.jsx)("path",{d:"M18.078 8.91306L14.9084 20.1036H14.7061L14.9084 8.91306H9.37843L6.14136 31.087H10.1877L12.076 18.3076H12.2109L12.0085 31.087H14.5712L18.0106 18.3076H18.2129L16.3246 31.087H20.371L23.608 8.91306H18.078ZM24.6196 8.91306L24.0801 12.5742H26.4405L23.7429 31.087H28.2613L30.9589 12.5742H33.3192L33.8587 8.91306H24.6196Z",fill:"#FCFCFD"})]})}var U=n(70856);let b=(0,r.memo)(function(e){let{children:t}=e;return(0,o.jsx)(U.oz,{components:{a:e=>{let{children:t,href:n,...r}=e;return(0,o.jsx)(i.N_,{className:"break-words wrap-anywhere","data-id":l.Co.AIChatbotLink,"data-parent":l.Co.AIChatbotMessage,href:n,rel:"noopener noreferrer",target:"_blank",...r,children:t})},h3:e=>{let{children:t,node:n,...r}=e;return(0,o.jsx)(i.o5,{as:"span",variant:"subtitle1",...r,children:t})},li:e=>{let{children:t,node:n,...r}=e;return(0,o.jsx)("li",{className:"mt-3 grid",...r,children:-1!==Array.from(n.children).findIndex(e=>"p"===e.tagName)?t:(0,o.jsx)(i.o5,{as:"span",variant:"body3",...r,children:t})})},ol:e=>{let{children:t,node:n,...r}=e;return(0,o.jsx)("ol",{className:"mb-3 inline-grid",...r,children:t})},p:e=>{let{children:t,node:n,...r}=e;return(0,o.jsx)(i.o5,{as:"span",variant:"body3",...r,children:t})},ul:e=>{let{children:t,node:n,...r}=e;return(0,o.jsx)("ul",{className:"mb-3 inline-grid",...r,children:t})}},children:t})},(e,t)=>e.children===t.children);
1function y(e){let{containerClassName:t,message:n}=e,{children:a,content:s,role:c}=n,[d,u]=(0,r.useState)(!1);return(a||s)&&(!s||"string"==typeof s)&&(!s||(null==s?void 0:s.trim()))?(0,o.jsxs)(_.P.div,{animate:{opacity:1,y:0},className:(0,C.A)("flex w-full items-end gap-2",{"flex-row-reverse":"assistant"===c,"ml-auto":"assistant"===c}),"data-testid":"chat-message",initial:{opacity:0,y:5},children:[(0,o.jsx)("span",{className:"flex-1 shrink-0",children:(0,o.jsx)(i.eu,{className:"bg-neutral-6 dark:bg-neutral-2 shrink-0",height:2.5,ignoreTheme:!0,width:2.5,children:"assistant"===c?(0,o.jsx)(S,{}):(0,o.jsx)(w(),{className:"text-neutral-1 dark:text-neutral-6",path:g.Gbn,size:1})})}),(0,o.jsxs)("div",{className:"relative w-full",children:[(0,o.jsx)("div",{className:(0,C.A)("border-neutral-6 bg-neutral-7 dark:bg-neutral-2 w-full rounded-lg border border-solid p-4 text-left break-words whitespace-pre-wrap dark:border-transparent",t),children:null!=a?a:(0,o.jsx)(b,{children:String(s)})}),"assistant"===c&&s&&(0,o.jsxs)("div",{className:"mt-1 flex items-center",children:[(0,o.jsx)(i.K0,{"aria-label":d?"Copied!":"Copy message",className:(0,C.A)("!border-neutral-6 !bg-neutral-7 dark:!bg-neutral-2 !size-8 rounded-lg border border-solid opacity-70 hover:opacity-100 dark:!border-transparent",d&&"!text-primary-2 opacity-100"),colorScheme:"transparent","data-id":l.Co.AIChatbotCopyButton,"data-parent":l.Co.AIChatbotMessage,onClick:()=>{let e=s||(null==a?void 0:a.toString())||"";navigator.clipboard.writeText(e).then(()=>{u(!0),setTimeout(()=>u(!1),1e3)})},size:"small",children:(0,o.jsx)(w(),{path:d?g.Tfj:g.$BT,size:.8})}),(0,o.jsx)(i.o5,{className:"text-neutral-3 dark:text-neutral-6 pl-1",variant:"caption1",children:d?"Copied!":"Copy response"})]})]}),(0,o.jsx)("span",{className:"size-[40px] shrink-0"})]}):null}let T="chatbot_error";function x(e){let{error:t}=e;return((0,r.useEffect)(()=>{t&&(window.Nitrous.push(()=>{window.Nitrous.logEvent({custom_attributes:{error:t,error_stack:t.stack},event_name:T})}),d.Y.error(t,{context:{error:t,error_stack:t.stack,eventName:T}}))},[t]),t)?(0,o.jsx)(y,{containerClassName:"!bg-error-4 dark:!bg-error-2",message:{children:(0,o.jsx)(i.o5,{className:"text-error-2 dark:text-error-4",disableColorScheme:!0,variant:"caption1",children:"There was an error processing your request. Please try again."}),role:"assistant"}}):null}function P(){return(0,o.jsx)("svg",{fill:"none",height:"48",viewBox:"0 0 48 48",width:"48",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsxs)("g",{id:"export_notes",children:[(0,o.jsx)("mask",{height:"48",id:"mask0_8536_93625",maskUnits:"userSpaceOnUse",style:{maskType:"alpha"},width:"48",x:"0",y:"0",children:(0,o.jsx)("rect",{fill:"#D9D9D9",height:"48",id:"Bounding box",width:"48"})}),(0,o.jsx)("g",{mask:"url(#mask0_8536_93625)",children:(0,o.jsx)("path",{d:"M32.4 41L38 35.4V40H40V32H32V34H36.6L31 39.6L32.4 41ZM10 42C8.9 42 7.95833 41.6083 7.175 40.825C6.39167 40.0417 6 39.1 6 38V10C6 8.9 6.39167 7.95833 7.175 7.175C7.95833 6.39167 8.9 6 10 6H38C39.1 6 40.0417 6.39167 40.825 7.175C41.6083 7.95833 42 8.9 42 10V23.4C41.3667 23.1 40.7167 22.8417 40.05 22.625C39.3833 22.4083 38.7 22.25 38 22.15V10H10V38H22.1C22.2 38.7333 22.3583 39.4333 22.575 40.1C22.7917 40.7667 23.05 41.4 23.35 42H10ZM10 38V10V22.15V22V38ZM14 34H22.15C22.25 33.3 22.4083 32.6167 22.625 31.95C22.8417 31.2833 23.0833 30.6333 23.35 30H14V34ZM14 26H26.2C27.2667 25 28.4583 24.1667 29.775 23.5C31.0917 22.8333 32.5 22.3833 34 22.15V22H14V26ZM14 18H34V14H14V18ZM36 46C33.2333 46 30.875 45.025 28.925 43.075C26.975 41.125 26 38.7667 26 36C26 33.2333 26.975 30.875 28.925 28.925C30.875 26.975 33.2333 26 36 26C38.7667 26 41.125 26.975 43.075 28.925C45.025 30.875 46 33.2333 46 36C46 38.7667 45.025 41.125 43.075 43.075C41.125 45.025 38.7667 46 36 46Z",fill:"#E90C17",id:"export_notes_2"})})]})})}function N(){return(0,o.jsx)("svg",{fill:"none",height:"48",viewBox:"0 0 48 48",width:"48",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsxs)("g",{id:"gallery_thumbnail",children:[(0,o.jsx)("mask",{height:"48",id:"mask0_8536_93630",maskUnits:"userSpaceOnUse",style:{maskType:"alpha"},width:"48",x:"0",y:"0",children:(0,o.jsx)("rect",{fill:"#E90C17",height:"48",id:"Bounding box",width:"48"})}),(0,o.jsx)("g",{mask:"url(#mask0_8536_93630)",children:(0,o.jsx)("path",{d:"M6 38C4.9 38 3.95833 37.6083 3.175 36.825C2.39167 36.0417 2 35.1 2 34V14C2 12.9 2.39167 11.9583 3.175 11.
1175C3.95833 10.3917 4.9 10 6 10H26C27.1 10 28.0417 10.3917 28.825 11.175C29.6083 11.9583 30 12.9 30 14V34C30 35.1 29.6083 36.0417 28.825 36.825C28.0417 37.6083 27.1 38 26 38H6ZM36 22C35.4333 22 34.9583 21.8083 34.575 21.425C34.1917 21.0417 34 20.5667 34 20V12C34 11.4333 34.1917 10.9583 34.575 10.575C34.9583 10.1917 35.4333 10 36 10H44C44.5667 10 45.0417 10.1917 45.425 10.575C45.8083 10.9583 46 11.4333 46 12V20C46 20.5667 45.8083 21.0417 45.425 21.425C45.0417 21.8083 44.5667 22 44 22H36ZM38 18H42V14H38V18ZM6 34H26V14H6V34ZM8 30H24L18.75 23L15 28L12.25 24.35L8 30ZM36 38C35.4333 38 34.9583 37.8083 34.575 37.425C34.1917 37.0417 34 36.5667 34 36V28C34 27.4333 34.1917 26.9583 34.575 26.575C34.9583 26.1917 35.4333 26 36 26H44C44.5667 26 45.0417 26.1917 45.425 26.575C45.8083 26.9583 46 27.4333 46 28V36C46 36.5667 45.8083 37.0417 45.425 37.425C45.0417 37.8083 44.5667 38 44 38H36ZM38 34H42V30H38V34Z",fill:"#E90C17",id:"gallery_thumbnail_2"})})]})})}function A(e){let{isLoading:t}=e;return t?(0,o.jsx)(y,{message:{children:(0,o.jsx)("div",{className:"flex items-center justify-end gap-x-[6px]",children:Array.from({length:3}).map((e,t)=>(0,o.jsx)("div",{className:(0,C.A)("animate-ai-loading bg-neutral-4 dark:bg-neutral-7 h-3 w-3 rounded-full",{"delay-0":0===t,"delay-150":1===t,"delay-300":2===t})},t))}),role:"assistant"}}):null}function O(e){let{messages:t}=e;return t.map((e,t)=>{let{content:n,toolName:r,...a}=e;return(0,o.jsx)(y,{message:{...a,content:r?"":n}},t)})}function L(e){let{append:t,disableAutoScroll:n=!1,error:a,isLoading:s,messages:d,persistHistory:u=!0,showSuggestedActions:g=!0,welcomeMessage:m}=e,[w,h]=function(){let e=(0,r.useRef)(null),t=(0,r.useRef)(null);return(0,r.useEffect)(()=>{let n=e.current,o=t.current;if(n&&o){o.scrollIntoView({behavior:"smooth"});let e=new MutationObserver(()=>{o.scrollIntoView({behavior:"smooth"})});return e.observe(n,{childList:!0,subtree:!0}),()=>e.disconnect()}},[]),[e,t]}(),f=[{icon:P,text:p.U$.SuggestedAction1},{icon:N,text:p.U$.SuggestedAction2},{icon:P,text:p.U$.SuggestedAction3},{icon:P,text:p.U$.SuggestedAction4}],v=(0,r.useMemo)(()=>{var e;return!u||E.fL?[]:JSON.parse(null!=(e=window.localStorage.getItem(c.UZ.AIChatbotMessages))?e:"[]")},[u]);return(0,o.jsxs)("div",{className:(0,C.A)("flex flex-1 shrink-0 flex-col space-y-4 overflow-hidden overflow-y-auto break-words",{"px-0":!d.length&&!v.length&&!g,"px-2":d.length>0||v.length>0||g,"px-5":!d.length&&!v.length&&g}),ref:n?void 0:w,role:"log",children:[d.length||v.length?null:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(_.P.div,{animate:{opacity:1,y:0},className:(0,C.A)("w-full",g?"border-neutral-6 bg-neutral-7 dark:bg-neutral-2 rounded-lg border border-solid p-4 text-center dark:border-transparent":"mb-0 pl-0 text-left"),exit:{opacity:0,y:5},initial:{opacity:0,y:5},children:(0,o.jsx)(i.o5,{className:"text-neutral-3 dark:text-neutral-6",disableColorScheme:!0,variant:"body2",children:m})}),g&&(0,o.jsx)(_.P.div,{animate:{opacity:1,y:0},className:"mt-4 grid gap-4 md:grid-cols-2",exit:{opacity:0,y:5},initial:{opacity:0,y:5},transition:{delay:.5},children:f.map((e,n)=>(0,o.jsxs)(_.P.div,{animate:{opacity:1,y:0},className:"border-neutral-6 bg-neutral-7 dark:bg-neutral-2 flex w-full cursor-pointer items-center gap-2 rounded-lg border border-solid p-6 text-center dark:border-transparent","data-id":l.Co.AIChatbotSuggestedPrompt,"data-nitrous-position":n+1,"data-parent":l.Co.AIChatbotForm,initial:{opacity:0,y:20},onClick:()=>{t({content:e.text,role:"user"})},transition:{delay:.2*n},children:[(0,o.jsx)(i.o5,{className:"text-neutral-2 dark:text-neutral-6 text-left",disableColorScheme:!0,variant:"body3",children:e.text}),(0,o.jsx)("div",{className:"ml-auto shrink-0",children:(0,o.jsx)(e.icon,{})})]},n))})]}),(0,o.jsx)(O,{messages:v}),d.map((e,t)=>(0,o.jsxs)(r.Fragment,{children:[(0,o.jsx)(y,{message:e},e.id),t===d.length-1&&"assistant"===e.role&&""===e.content?(0,o.jsx)(A,{isLoading:s}):null]},e.id)),(0,o.jsx)(x,{error:a}),(0,o.jsx)("div",{ref:n?void 0:h})]})}let I=e=>{window.Nitrous.push(()=>{window.Nitrous.logChatbotReportIssue(e)})};function k(){let{carContext:e,inline:t=!1,persistHistory:n,showSuggestedActions:g=!0,welcomeMessage:m=p.U$.WelcomeMessage}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},w=(0,r.useId)(),f=(0,a.useRouter)(),C=(0,a.usePathname)(),_=(0,a.useSearchParams)(),E=(null==_?void 0:_.get("
1chatbot"))==="true",{append:S,error:U,handleSubmit:b,input:y,isLoading:T,messages:x,setInput:P}=(0,s.Y_)({api:"/nwapi/chat",body:{carContext:e,id:w},id:w,initialMessages:[],keepLastMessageOnError:!0,maxSteps:3,onFinish:(e,t)=>{var n;if(null==(n=e.toolInvocations)?void 0:n[0]){let t=e.toolInvocations[0],{state:n}=t;if("result"===n){let{result:n}=t;u({content:JSON.stringify(n),id:e.id,role:e.role,toolName:t.toolName})}}if("tool-calls"!==t.finishReason){let e=function(){let e=JSON.parse(localStorage.getItem(c.UZ.AIChatbotMessages)||"[]");try{var t;return{toolName:e[e.length-1].toolName,userMessage:null==(t=e.slice().reverse().find(e=>"user"===e.role))?void 0:t.content}}catch(e){d.Y.log({error:e,level:"error",msg:"Error retrieving user message from localStorage"})}}();window.Nitrous.push(()=>{window.Nitrous.logChatbotPrompt((null==e?void 0:e.userMessage)||"",(null==e?void 0:e.toolName)||"none",t.usage.totalTokens)})}"string"==typeof e.content&&e.content.trim().length&&u({content:e.content,id:e.id,role:e.role})}});(0,r.useEffect)(()=>{E&&window.Nitrous.push(()=>{window.Nitrous.logChatbotOpen()})},[E]);let N=()=>{window.Nitrous.push(()=>{window.Nitrous.logChatbotClose()}),C?f.push(C):f.push("/")},A=null!=n?n:!t;return t?(0,o.jsxs)("div",{className:"border-neutral-6 bg-neutral-7 dark:bg-neutral-2 mx-auto mb-4 flex w-full flex-col gap-2 rounded-lg border px-2 py-4 break-words md:px-6 md:py-6",children:[(0,o.jsx)(L,{append:e=>{let{content:t,role:n}=e,o={content:t,id:w,role:n};A&&u(o),S(o)},disableAutoScroll:!0,error:U,isLoading:T,messages:x,persistHistory:A,showSuggestedActions:g,welcomeMessage:m}),(0,o.jsx)(h,{handleSubmit:e=>{y&&""!==y.trim()&&(A&&u({content:y,id:w,role:"user"}),b(e,{}))},input:y,isLoading:T,setInput:P}),(0,o.jsxs)(i.o5,{as:"div",className:"text-neutral-3 dark:text-neutral-5 px-2 pt-2",disableColorScheme:!0,variant:"caption1",children:[p.U$.FeedbackMessage,"\xa0",(0,o.jsx)(i.My,{action:I,"data-id":l.Co.AIChatbotFeedback,promptText:p.U$.Text,title:p.U$.FeedbackHeader,trigger:"link",triggerText:p.U$.FeedbackLink})]})]}):(0,o.jsxs)(i.lG,{className:"px-6",onClose:N,open:E,showCloseButton:!1,children:[(0,o.jsxs)(i.L3,{className:"!m-0 flex flex-col space-y-2 !border-none !pb-0",children:[(0,o.jsx)(v,{handleClose:N}),(0,o.jsx)(h,{handleSubmit:e=>{y&&""!==y.trim()&&(A&&u({content:y,id:w,role:"user"}),b(e,{}))},input:y,isLoading:T,setInput:P})]}),(0,o.jsx)(i.Cf,{className:"!p-0 md:min-h-[20rem]",children:(0,o.jsx)(L,{append:e=>{let{content:t,role:n}=e,o={content:t,id:w,role:n};A&&u(o),S(o)},error:U,isLoading:T,messages:x,persistHistory:A,showSuggestedActions:g,welcomeMessage:m})}),(0,o.jsx)(i.Es,{className:"w-full !justify-start !gap-0 !p-0",children:(0,o.jsxs)(i.o5,{as:"div",className:"text-neutral-3 dark:text-neutral-5 px-2",disableColorScheme:!0,variant:"caption1",children:[p.U$.FeedbackMessage,"\xa0",(0,o.jsx)(i.My,{action:I,"data-id":l.Co.AIChatbotFeedback,promptText:p.U$.Text,title:p.U$.FeedbackHeader,trigger:"link",triggerText:p.U$.FeedbackLink})]})})]})}},67793:(e,t,n)=>{"use strict";let o;n.d(t,{Providers:()=>f,ScriptProviders:()=>v});var r=n(95155),a=n(99776),i=n(12115),s=n(31461),l=n(34049);function c(){return new s.E({defaultOptions:{queries:{gcTime:9e5,refetchOnWindowFocus:!1,staleTime:6e4}}})}function d(e){let{children:t}=e,n=l.S$?(0,i.cache)(c)():(o||(o=c()),o);return(0,r.jsx)(a.QueryClientProvider,{client:n,children:t})}var u=n(65539),p=n(83045),g=n(56600),m=n(10423);let w=(0,i.createContext)(void 0),h=e=>{let{children:t}=e,{brand:n}=(0,g.A)(m.Z),[o,a]=(0,i.useState)({brand:u.mz.Motortrend,scriptId:p.z1});return(0,i.useEffect)(()=>{let e=p.z1,t=!1,o="30px";n===u.mz.Hotrod?(e=p.rJ,t=!0,o="0px"):e=p.z1;let r="/logo/".concat(n,"-og.png");a({brand:n,scriptId:e}),t&&(document.documentElement.style.setProperty("--brand-logo-url","url('".concat(r,"')")),document.documentElement.style.setProperty("--logo-margin-left",o))},[n]),(0,r.jsx)(w.Provider,{value:o,children:t})};function f(e){let{children:t}=e;return(0,r.jsx)(d,{children:t})}function v(e){let{children:t}=e;return(0,r.jsx)(h,{children:t})}},82196:(e,t,n)=>{"use strict";n.d(t,{Ay:()=>i,J$:()=>a});var o=n(12115);n(56600);let r=["AT","BE","BG","HR","CY","CZ","DK","EE","FI","FR","DE","GR","HU","IE","IT","LV","LT","LU","MT","NL","PL","PT","RO","SK","SI","ES","SE"];function a(){let[e,t]=(0,o.useState)({country:"",state:"",stateName:""}),[n,a]=(0,o.useState)(!0);(0,o.useEffect)(()=>{let e,n=0,o=()=>{var o;if(null==(o=window.OneTrust)?void 0:o.getGeolocationData){let n=window.OneTrust.getGeolocationData();
1if(n&&n.country)return t({country:n.country||"",state:n.state||"",stateName:n.stateName||""}),a(!1),e&&clearInterval(e),!0}return++n>=20&&(console.warn("OneTrust geolocation data not available after maximum attempts"),a(!1),e&&clearInterval(e)),!1};o()||(e=setInterval(o,500));let r=()=>{setTimeout(o,100)};return window.addEventListener("OneTrustLoaded",r),window.addEventListener("OneTrustGroupsUpdated",r),window.addEventListener("consent.onetrust",r),()=>{e&&clearInterval(e),window.removeEventListener("OneTrustLoaded",r),window.removeEventListener("OneTrustGroupsUpdated",r),window.removeEventListener("consent.onetrust",r)}},[]);let i="US"===e.country.toUpperCase(),s=r.includes(e.country.toUpperCase());return{geoData:e,isEU:s,isUS:i,loading:n}}let i=a},82723:()=>{},84573:(e,t,n)=>{"use strict";n.d(t,{Q:()=>d,q:()=>u});var o=n(12115),r=n(99776),a=n(53455),i=n(31306),s=n(80946),l=n(61562);let c=new BroadcastChannel("auth-events");function d(){let e=(0,r.useQueryClient)(),t=s.X.NEXT_PUBLIC_FEATURE_AUTH_ENABLED;return(0,o.useEffect)(()=>{if(!c||!t)return;let n=t=>{"logout"===t.data&&e.setQueryData(["session"],null)};return c.addEventListener("message",n),()=>c.removeEventListener("message",n)},[e,t]),(0,a.useQuery)({enabled:t,queryFn:async()=>{try{return await (0,i.OT)("/nwapi/auth/session",{responseType:"json",retry:!1})}catch(e){if((null==e?void 0:e.status)===401)return null;throw e}},queryKey:["session"],refetchOnReconnect:!0,refetchOnWindowFocus:!0,retry:1,staleTime:5*l.kp})}function u(){null==c||c.postMessage("logout")}},90836:(e,t,n)=>{Promise.resolve().then(n.bind(n,61105)),Promise.resolve().then(n.bind(n,18742)),Promise.resolve().then(n.bind(n,25126)),Promise.resolve().then(n.bind(n,98323)),Promise.resolve().then(n.bind(n,92744)),Promise.resolve().then(n.bind(n,4356)),Promise.resolve().then(n.bind(n,58739)),Promise.resolve().then(n.bind(n,22294)),Promise.resolve().then(n.bind(n,95229)),Promise.resolve().then(n.bind(n,32947)),Promise.resolve().then(n.bind(n,881)),Promise.resolve().then(n.bind(n,66944)),Promise.resolve().then(n.bind(n,2003)),Promise.resolve().then(n.bind(n,37146)),Promise.resolve().then(n.bind(n,40269)),Promise.resolve().then(n.bind(n,66420)),Promise.resolve().then(n.bind(n,56065)),Promise.resolve().then(n.bind(n,91998)),Promise.resolve().then(n.bind(n,24217)
1),Promise.resolve().then(n.bind(n,26159)),Promise.resolve().then(n.bind(n,39006)),Promise.resolve().then(n.bind(n,46858)),Promise.resolve().then(n.bind(n,68332)),Promise.resolve().then(n.bind(n,98202)),Promise.resolve().then(n.bind(n,57445)),Promise.resolve().then(n.t.bind(n,41402,23)),Promise.resolve().then(n.bind(n,76454)),Promise.resolve().then(n.bind(n,67793)),Promise.resolve().then(n.t.bind(n,82723,23)),Promise.resolve().then(n.t.bind(n,94861,23)),Promise.resolve().then(n.t.bind(n,45836,23)),Promise.resolve().then(n.bind(n,3904)),Promise.resolve().then(n.bind(n,46772))},91998:(e,t,n)=>{"use strict";n.d(t,{NitrousSetup:()=>l});var o=n(12115),r=n(81981),a=n(17670),i=n(66768),s=n(23114);let l=()=>((0,o.useEffect)(()=>{window.nitrousOnLoad=()=>{window.Nitrous.init({apiKey:r.h.NEXT_PUBLIC_AMPLITUDE_API_KEY,appName:"NextWeb",appVersion:r.h.NEXT_PUBLIC_VERSION,environment:a.O_?"production":"development"});let e=(0,i.N)();e&&window.Nitrous.setUserAttributes({mtid:e})};let e="".concat(window.location.origin,"/_assets/nitrous/nitrous-sdk.js");(0,s.A)(e,void 0,{async:!0}).catch(e=>{console.error("Failed to load nitrous script:",e)})},[]),null)},92117:(e,t,n)=>{"use strict";n.d(t,{A:()=>r});var o=n(12115);let r=function(e,t){let n,r,a,i;return Object.values(t).some(o.isValidElement)?(n=e,r=t,n.split(/({(?:\w+)})/g).map((e,t)=>{let n=e.match(/{(\w+)}/);if(n){let a=n[1],i=r[a];return(0,o.isValidElement)(i)?(0,o.cloneElement)(i,{key:"".concat(a,"-").concat(t)}):null==i?e:String(i)}return e})):(a=e,i=t,a.replace(/{(\w+)}/g,(e,t)=>{let n=i[t];return null==n?e:String(n)}))}},94861:()=>{}},e=>{e.O(0,[3540,3864,5779,9910,3511,2062,4500,1029,6356,9286,2152,5539,8248,1562,6600,4365,8441,5597,2469,7358],()=>e(e.s=90836)),_N_E=e.O()}]); 2//# sourceMappingURL=layout-9e084aba06bbde46.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.