var _yt_player={};(function(g){var window=this;/* Copyright The Closure Library Authors. SPDX-License-Identifier: Apache-2.0 */ /* Copyright Google LLC SPDX-License-Identifier: Apache-2.0 */ /* Copyright Google LLC All Rights Reserved. Use of this source code is governed by an MIT-style license that can be found in the LICENSE file at https://angular.dev/license */ /* (The MIT License) Copyright (C) 2014 by Vitaly Puzrin Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ----------------------------------------------------------------------------- Ported from zlib, which is under the following license https://github.com/madler/zlib/blob/master/zlib.h zlib.h -- interface of the 'zlib' general purpose compression library version 1.2.8, April 28th, 2013 Copyright (C) 1995-2013 Jean-loup Gailly and Mark Adler This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. Jean-loup Gailly Mark Adler jloup@gzip.org madler@alumni.caltech.edu The data format used by the zlib library is described by RFCs (Request for Comments) 1950 to 1952 in the files http://tools.ietf.org/html/rfc1950 (zlib format), rfc1951 (deflate format) and rfc1952 (gzip format). */ /* The MIT License (MIT) Copyright (c) 2015-present Dan Abramov Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ 'use strict';var vw,vaa,lBu,fx,e6P,z6y,R6D,mPa,ka,Q7a,wu,I7,DB,t92,yqB,CDu,F2,Ya,fB9,gaa,kWB,wwD,xa,Lx,S9,GW,X2,Bw,$Pu,iD,a7,Hw,DPB,naw,Nu7,vA,ex,Jqw,u2w,tj,yQ,C1,cqD,qyw,FDW,AqB,YyP,bxD,xPa,pw7,wo,LDw,Im,Syu,ixu,Dy,UPw,Zxw,NG,j7w,cA,Fd,L1,Sx,Gv,Xd,aBD,Hxu,BA,Ub,iY,Eax,WD7,OxW,oax,Zy,s7u,am,HA,Eb,rqw,M9W,Ob,V9q,dPD,ew,PY9,Qv,v3q,lya,mc,eyw,hyq,zyB,$w,mGw,Qm6,kv6,No,g39,yjw,$GB,DGD,No7,u9,K$,qo,AK,F6,udw,cjD,Yw,b9,L$,Sw,Yba,GV,X6,BZ,i9,UE,xGw,a4,HZ,EE,OE,o4,rL,Gv9,Pv,lT,hQ,XA6,et,Box,i1q,zZ,vv,m9, R6,UG7,Q7,Z1w,y7,ayw,CV,fV,kh,E3x,JQ,Wyw,O1q,o3W,H17,Nu,I6,wK,smD,rjw,Toq,VxW,dGx,KV,cv,qu,P99,l7u,vw6,e2D,h2D,AQ,z26,mo7,Q4u,xh,bT,tw6,pV,LV,Xk,GZ,Ul,iT,ZI,Ol,jt,Hv,El,f7D,sl,gw9,rK,Mu,Pt,vt,l_,TZ,dK,V7,h5,C9D,zn,kV2,hj,mT,RY,a6,Wv,Qa,$ox,t5,I7a,my,C3,f3,gi,kK,wi,$K,IY,Doa,D_,nwu,n3,NLx,J5,Nr,K3,ct,qr,F9,A5,JKw,Kc2,b_,cK6,qED,xK,p3,Gn,AKu,YEw,X9,Lcx,XZD,b$7,GVP,SEy,pZy,xoD,BLw,i$D,Bt,Z_,UoP,Ur,aY,j4w,Ht,H$2,Er,Wt,Or,EwW,oY,Wcu,sr,O$P,oww,ri,s4x,Mr,Tn,di,PQ,Mw2,ei,doW,rKu,hw,mF,R_,vhW,QC,yC,lIW,h5w, z5a,Ci,fi,gO,kB,wO,$B,I_,R5w,Q6D,tty,yQB,DF,CTy,fIx,ni,NX,Jw,uQ,ghw,IIW,Du2,NKD,nh9,JQB,K9u,F_,Aw,YB,bQ,xB,Li,Si,AQq,X_,iQ,UN,ZF,a_,HQ,Yly,EN,WQ,o_,xuP,pvP,sN,MX,T0,dO,Pr,l6,ep,ZVq,j6D,aIw,HVD,h3,zA,Eh6,W9w,OVD,mt,Rv,Q3,t3,y3,wY,Iv,NT,KU,ohW,s6a,xr,rQ9,Uq,Zc,VtP,eV9,vKW,zVP,Hr,Eq,TA,QY6,y5x,tvq,dY,vi,C_B,Pi,mS,av,gKx,f_D,CS,yc,jp,fS,gQ,k7,wQ,knu,$7,$r6,nS,I_y,Jl,u5,KS,ci,Drw,Y7,FD,nKP,qV,Al,NiD,J5W,u99,LS,KTP,c5w,qry,A5D,FTx,pS,Su,G9,Yru,b36,xrx,XD,pta,Bi,wv2,kZw,i5,U1,ju,Wi,Gny,O1,oe,rQ,Xt9,Biu, MV,a_w,l0,Ury,jYB,dQ,Vc,md,Rp,H37,yF,EK7,C7,f7,WT2,oKP,$9,r5D,DP,n7,MvD,Tia,u0,cl,vBa,eoB,hoW,FQ,zo9,qU,tiD,NU,dr6,Qvq,Q_B,mXW,RoD,tpW,Rf7,At,lFw,x9,C69,fcx,gr7,kAu,wrD,GQ,$TW,Bl,Icq,NYa,J3q,i0,UU,ZP,EU,KtD,Wl,OU,op,c32,qqw,MU,Ft2,TQ,VF,bU9,pr9,Sq6,Lty,GAD,P_,ez,R3,t4,yA,CI,fI,gF,iUx,UTy,ku,ZUu,wF,$u,QA,I3,DG,nI,jv6,zv,Nl,ac7,uK,KI,Wtu,c_,ql,FF,OU2,oru,sva,r3w,Yu,bK,xu,pI,dTD,Vp7,P5D,v79,lH2,LI,egB,Mp7,Sz,hgD,zga,G7,Rg9,QeP,tuB,ylq,C5u,iK,fHW,g7D,k9q,wia,DVP,$V6,Ut,ZG,jz,a3,H_,Et,W_,Ot,NQq,Ml,rF, o3,T7,Jl7,VA,uDD,KSB,clw,q19,dF,vN,Y19,PN,bSD,lI,xVq,ej,h7,zt,mW,R9,Qr,Xiq,piw,fJ,G9y,gz,S16,CJ,t7,LSB,yr,wz,iSq,I9,$Y,uI,KJ,q$,jeD,cN,YY,aH9,bI,UV7,WS7,OSy,o72,LJ,Sj,Gt,seB,Xj,ZA,jj,a9,rla,HN,E3,WN,Mu7,TQ6,O3,VuW,lP7,v9a,eDW,hDB,zDw,dVD,RDw,o9,s3,rz,Qp9,Tt,M$,tC2,yt2,C0D,vF,fP6,lL,eK,g9q,hx,wl6,zX,kQy,$U6,IPa,DUq,mZ,RW,Qd,tx,yd,CC,fC,n9y,gs,k8,ws,N57,uQ2,Kda,IW,nC,DD,Jx,uL,KC,qUD,Fdw,cF,qL,FS,YUw,b7P,LdD,xUw,SU7,i77,Ax,B5D,GQW,Y8,bL,UUW,x8,Z79,pC,aPq,jpq,H7w,E9W,XS,BF,Wdq,O7B,o9w,iL,UJ,sp9,ZD,rt9, MCW,VCa,lGy,jK,eXw,hXy,zX2,mlP,RXu,EJ,Q3B,tzx,y4a,TX,ML,rs,CK9,fGD,gu7,Vd,ds,Pk,w_6,zU,mw,yO,Cn,fn,g1,IGy,Dl9,nuB,k1,$1,IF,Jv,uB,bB,J4u,K39,uFa,c49,qtW,Xm,F3W,A4D,Bk,Ytu,bI9,xl6,p_u,j8,Um,aF,Hk,Em,L3D,St6,G79,Wk,Om,X_D,oF,BFx,iIx,Ul7,sm,ZIw,r1,M_,j3u,aGB,HID,Eux,W3w,OIw,TU,VO,d1,vL,r4a,lx,eZ,Mzq,s3x,PL,TFu,hJ,z2,mU,QN,RA,VzD,dlw,PI7,tJ,lAx,yN,hJx,zJW,m$D,RJ7,Q9W,tj9,y7q,CIw,gP,kg,wP,gYw,fAx,kt9,wNa,IA,$$a,Db,IA2,D$u,nb,NR,JJ,nY7,ux,Kb,Nzu,cL,qR,Fa,AJ,Yg,bx,xg,pb,J7P,ujD,KW9,c7u,Lb,q3w,A7D,FWw,G2, Xa,bJw,Y37,LWa,XNq,GtP,BL,Bzq,iJ7,U$9,j97,ZJP,aAy,ix,HJw,EYB,Zb,WWu,OJa,oY6,s97,jZ,r72,aA,Mjw,HL,Ez,Vjx,WL,d$D,Oz,oA,PLu,v8w,sz,MR,eH2,T2,lDD,hHD,zHq,mLa,QW6,VN,tK6,v9,ln,CLP,fDy,wFw,$L7,eF,ha,zR,mo,Rj,Qo,ta,yo,CT,fT,gj,ks,wj,NsW,n8a,JxW,KZy,uSx,qJa,DLW,cx6,ID2,$s,Ij,Ax9,YJW,bCP,Ja,un,q7,Dq,pFq,Ys,FZB,SJw,GX9,LZW,bn,xs,pT,LT,XFx,xLx,Bsx,SF,iCu,ULa,ZCy,jWD,aD9,WZ6,OC6,o8D,sWW,GR,MKw,Tsx,dLq,PBD,B9,lO6,US,Xx,hiu,eix,Ri9,jF,H9,t82,yvD,CBD,fOa,kUq,OS,W9,wkx,g1B,IOy,n1w,N1W,umx,Avw,Vo,Ym7,TR,P7,bna,v7, ed,h8,x_7,pk2,Lww,Cz,Sm6,GUB,NF,XkW,iny,J8,U_D,ZnP,WwB,jF6,qF,F3,A8,b$,xk,M8y,pz,Lz,Sd,V8D,B7,d_6,PxD,i$,lbD,ZE,jd,aX,H7,e3u,E7,O7,oX,s7,rt,h3w,Tl,VD,dt,P0,v0,lO,z3x,mRu,R3W,QA9,tZ6,yJD,eS,Cx6,yp,fby,ggB,k2y,CK,g_,kI,w_,De,nK,NW,$Rq,KK,c0,qW,Ibx,DRw,F7,ng2,NPa,YI,YzP,bbw,xRD,bO,pLw,LUu,XLD,pK,ib9,BPD,SS,Zb2,jAD,abD,X7,B0,HbD,iO,U5,Ze,jS,aT,H0,O5,oT,s5,r_,MW,To,Vp,d_,EgW,WUw,ObB,vM,eN,oga,RZ,QS,tZ,yS,CG,g$,kN,TP9,w$,$N,IZ,dRw,VZq,sAB,Nc,nG,evx,JZ,xN,AZ,pG,LG,zva,Qjw,G_,CnP,tFD,yaw,gsD,D7P,kRD,$7P, Iqw,BM,Xt,nsW,Uk,Zp,jN,Njx,oZ,Jaq,sk,r$,T_,ux7,d$,Px,Ko9,vx,lZ,qSy,zT,Ru,QK,tB,yK,Ck,fk,gD,kd,wD,Aaa,$d,nk,Dd,bTy,SS2,p9D,LoD,GR7,X99,iTD,U7D,Bj9,jjD,uZ,Kk,Fz,aqa,HTw,q1,AB,Wo2,OTW,MFD,ra9,pk,Lk,SB,GT,Xz,iZ,VFD,d7D,P$7,Wx,OY,vky,lEW,ee7,TT,VK,dD,he7,zeD,Re2,tdw,eY,y8y,m_,hP,tP,y8,fR,C$y,nR,N4,JP,uH,ch,q4,AP,$Fa,IE6,bH,DFD,nku,pR,Nt6,J8w,LR,SY,u3D,KrW,q7W,iH,A89,Y7P,XA,bzx,xFD,LrB,p7a,aG,Fr6,Glx,X7D,sP,OP,BtP,izD,rn,M4,UF2,ZzP,dn,jX7,aEy,Hzq,Ekx,h6,Wr2,Ozq,oka,sXy,r8x,Mdw,Ttq,Vdx,mI,dFw,QR,vIW,leD, elw,hlq,zlu,t6,wW,Rlq,yr2,$z,COw,gIa,mWw,kou,w0W,$WB,QT2,tSa,yR,C9,kz,feW,gW,f9,Iey,DWW,nI9,N_2,Jry,u7x,ArW,K7P,NI,qI,A6,xWP,S5a,L7q,FU,xz,Go6,Sl,X0x,iK9,Uh,B_7,oID,UW2,OKx,Hs,sTW,T_7,Eh,aO,rrw,MS6,VS2,Oh,PaD,vNx,lpa,eRw,hRw,zRa,mcu,dW6,QZ2,tNw,yZ2,fpq,Ca9,k_q,MI,wMD,TJ,VR,dW,$cD,Ip7,lC,eg,nNa,DcB,h$,N$y,uta,cZD,KVw,qku,YkD,FV9,ny,uC,J$,bG7,NB,Ky,cY,qB,xcW,pMD,A$,Skx,xR,bC,Ly,Sg,Gj,G_u,Xv,iC,XMq,Zm,an,HY,B$D,iGw,Ucq,ZGw,E$,O$,jZw,on,s$,rm,HGx,MB,Tj,END,dm,ll,vu,Pu,e4,hG,oNP,dcx,vdW,VNw,T$W,PZ2,Qj, Cg,zIP,ldW,eIx,hID,OGD,kTW,JG,gdx,Ida,fdW,RM,ul,wc,ng,wxw,gc,rZ2,sZD,MNP,yj,CZ2,Fi,Kpq,AG,qYD,Fp2,ABW,bl,YYu,bkq,x19,Lpw,SYy,Lg,Xxx,S4,BDw,ikw,ZkW,juD,Xi,adB,Edq,Bu,WpD,il,Uc,wn,MBy,v6D,Wu,epw,m4w,oM,QGw,tYq,yPw,CH2,hz,f06,lE,p0W,Pp,e3,vp,sc,fv,Cv,kF,$F,kzq,Ir,nv,ND,wh9,$4P,Kv,D4q,n62,Nnq,JP6,uAx,K_a,cPW,qPP,F_9,APa,Az,YP6,YF,xF,bRy,x4w,phx,pv,L_P,SP6,Xq,Bp,iE,Gz2,UO,XhD,j3,iRw,Bna,Hp,EO,Wp,OO,U4D,or,sO,ZRD,jGw,rA,MD,W_7,a0y,E6q,HRu,TE,VB,dA,OR9,o6y,sGq,P$,MY6,d42,VYD,v$,l4,eP,hm,zL,Rq,QX,tm,yX,C2, f2,gX,PXy,vzD,lsx,kU,wX,$U,Iq,n2,Jm,zQD,hQD,K2,mIW,c$,qQ,F8,Am,YU,p2,L2,SP,GL,X8,B$,i4,UI,ZS,jP,aq,tlB,EI,OI,y6w,oq,fsy,gz6,kJP,$I6,DIB,dX,nzW,vI,PI,uUP,KIB,c6w,ee,hH,FIB,I5,Df,ns,Nd,YhP,JH,uo,Ks,b9a,cI,A6w,qd,F5,psu,xIw,AH,YS,bo,xS,Ls,Sh9,GJP,Gx,X5,io,Un,XsP,BI,UIw,Z9D,jOq,asw,H97,Ezq,WI6,je,Zf,i9D,sO6,a5,Ml2,TWa,o5,Vl9,En,WI,dID,sn,vRy,eqB,r9,Md,hq2,Tx,mBW,V1,fmD,y$w,Rqa,tg2,Qn2,Pq,vq,lh,e1,hf,zi,mn,Qn,kj6,ImP,Ca,v1D,fa,DBP,Nmx,ke,DX,wx,IH,$e,KXw,uv6,J$9,c$x,na,q$a,byw,Nb,uh,pYw,Ka,cq,qb,F$,LXu, Af,S$2,GjB,bh,S1,Gi,X$,Bq,ih,Ui,ZX,j1,aH,Hq,Ei,Wq,Oi,XY2,Bmw,oH,hS,zI,mq,Rd,Qg,iyP,UBW,tS,ge,amu,Hy9,kl,we,JS,ub,WX2,qj,Yl,Oyw,sn7,oRx,r$D,Mg6,Tmu,VgP,dB2,PlW,lxw,vt7,e07,ma9,QM9,z0P,xl,pt,yG7,t46,Lt,S2,GI,ClB,XY,BT,ib,gtw,kM6,U2,fx2,Zi,Ixa,j2,ad,HT,E2,WT,O2,od,s2,re,Mj,TI,Vg,de,PJ,vJ,l1,e$,hu,zH,m1,RR,Qm,tu,ym,CY,fY,gH,ky,wH,$y,IR,Dj,nY,NS,Ju,u1,KY,cJ,qS,Fw,Au,Yy,b1,pY,LY,S$,GH,Xw,BJ,i1,UK,Zj,j$,aR,HJ,EK,WJ,OK,oR,sK,rH,MS,TH,Vm,dH,P2,v2,lq,ey,hT,ms,RD,nta,Qf,V,tT,zf,yf,CF,fF,JGD,kO,Kby,g3,cG6,$O, qc9,DM,w3,nF,Nx,JT,KF,AG2,YcB,bgP,xaq,LF,Sy,YO,Gf,Lby,Scx,GMx,Xuw,FbW,BcB,uq,igx,Ua2,B2,aD,iq,qx,Zg6,c2,Xh,Uu,H2,axw,Fh,AT,jy,ZM,Hgw,Eu,W2,Ou,oD,Etw,r3,Mx,Tf,Vf,d3,Wb6,Oga,sMa,rGa,lc,eI,hn,zw,PEx,lWx,hay,zaq,Ro,RaD,Qr2,g4,t37,k4,w4,$4,Io,D5,ne,yzW,fW6,gFB,CE6,kEq,wpB,Ke,cb,FB,Y4,bc,x4,pe,$DB,Le,SI,qs,Bb,ic,UA,Z5,IWB,XB,nFD,jI,NAa,Jz7,ao,uqx,Hb,EA,KmB,czD,Wb,qOP,FmD,OA,AzD,YOD,bvw,xDw,oo,sA,ppD,Lm6,r4,Ms,Tw,SOa,VL,d4,Pz,vz,GEa,lp,eL,Xp2,hD,BA9,za,ivB,UDa,Zv2,jra,aWu,HvB,mL,EFW,WmD,Ovw,RS,oFw,QT,sra, tD,rzy,yT,M3D,TAB,CW,$q,V3w,IS,D1,dDW,nW,P46,Ng,JD,up,vUB,lSq,cz,qg,hbw,Fs,zbu,mQD,ebu,RbD,Qq6,tP9,Yq,ymP,bp,xq,pW,LW,C4y,SL,Ga,Bz,fSB,ip,U6,gUu,jL,E6,aS,s6,rl,kL7,Mg,Ta,VT,dl,w$W,vB,lf,$QD,hi,zN,O6,mz,Rb,Qu,ISa,ti,yu,C0,DQ6,f0,gJ,kJ,wJ,ab,Ea,WB,Oa,ob,nUy,NX2,JmD,u8W,TN,sa,Vu,dJ,KAP,cmW,qIy,PP,vP,lm,FAy,Amx,M6,YIB,b2q,eq,xQy,hU,z1,RV,Q$,tU,y$,CM,gZ,kG,$G,IV,Dk,nM,wZ,SIw,GLx,JU,um,KM,X$a,qk,i22,FH,AU,UQP,YG,bm,xG,LM,Z2y,pM,Sq,G1,XH,jqw,UC,H2u,EUD,WAW,Zk,jq,O2x,oUw,sq9,aV,MPy,cP,rm6,TX6,HP,VP9,EC,dQw, WP,Po2,vSx,lfa,ekx,hka,OC,mdy,zk9,oV,Mk,Rkw,T1,Q5u,V$,tew,yHu,dZ,Coq,ff9,gSy,kx2,PE,wIB,vE,If9,e5,hX,nSu,DdD,N97,JHu,u5x,m0,R2,Qt,KvD,cHw,qnq,FvD,AHD,Yn6,bsx,xd2,pIa,Lv6,Cl,fl,gU,Snw,Gxx,kW,wU,XIw,$W,I2,nl,B9W,Ni,JX,uz,isw,Kl,Ud7,cE,Zsu,qi,j5P,afx,Fg,Hs2,ESw,Wvu,AX,YW,bz,xW,pl,Osq,oS2,Ll,S5,G$,s59,Xg,BE,iz,Uw,Zt,rHq,Me9,j5,a2,T9y,HE,Ew,WE,Ow,otx,Vey,ddD,o2,Phw,veP,lXu,rU,Mi,T$,Vt,dU,P4,v4,lJ,e6,hA,zO,e17,h1D,fO,Nf,z1x,JA,Yj,KO,ChB,$bw,fXa,IXB,neD,NxD,Dbw,JfW,u$u,Knx,j6,Fnw,Yiw,xbw,pqx,LnP,EB,W4,Gi6, Xqa,Zau,OB,jHq,Bx9,oL,sB,rk,Mf,HaD,Oax,Eeq,rfD,liw,vlu,M1W,eMu,VM,V19,Txx,mjx,t22,QdD,gl2,yS2,dk,PX,Dja,ec,nlB,q27,cSa,Kqu,JSu,Y2D,ASD,uYD,S2W,Lq7,GI7,QH,itD,XTa,BeD,Nea,Ujy,Ztw,hF,m6,xjw,btD,pT2,jdD,zu,Fq6,Ht9,WqD,oly,rS2,V2D,dju,vy6,lj2,hxy,exD,t$W,mSP,zxD,yuq,gyB,kHu,wJD,$S7,Nz,AfD,nyy,Ijq,Kd,uw6,qz,cuD,qKy,K19,FR,F1y,AF,YC,Ns,bF,qiD,xC,pd,Ld,AuD,YKw,Sc,bYu,xS9,pJW,Gu,BX,iF,UW,Zo,jc,a8,HX,EW,L1W,SK7,WX,GHx,OW,rZ,o8,sW,BH2,XJq,ra,iYw,US2,Mz,Tu,ZY7,VH,jRw,aj6,baD,JuD,HYD,da,Jn,vb,tF,Eya,W1q,v1,IiW, vX,OYw,JF,uF,Cd,yH,TO,kC,M2D,P1D,fd,kIx,C1w,oy2,hMP,dbD,ls,NH7,H4,ruP,sR9,aX7,TeW,M$w,fj2,Do,wTD,$jw,RMW,sdq,OtP,sH2,Wny,UbD,iau,Si2,ai6,Pb9,Rxw,Cbx,fiD,$C,I8,wa,QR6,Elq,V$w,THB,en,zP,mk,RJ,Qz,C6,kf,wI,$f,D9,n6,tb,yz,IJ,Pq2,dSx,NE,us,vOa,lM9,K6,c1,qE,FP,Ab,Yf,bs,xf,mxw,L6,p6,Rh6,hhW,zhq,QDD,Sn,GP,tya,yTa,XP,Cq2,k6,gO7,fMB,w2a,IMa,DxD,$x2,nO6,uh2,aJ,H1,KsW,cTa,Eg,W1,quw,Fs2,ATw,Yu2,oJ,rI,ME,xxw,p2w,Gf9,B3D,iF9,X2u,dI,vn,Pn,Uxw,ZFx,TP,jDa,aM9,HFw,EO2,Vz,sDq,rTw,MyD,oOD,OF7,WsD,T32,Vy9,Ls2,dxP,SuD,Pcu, v4D,zLw,l59,eL2,hLw,Qo6,msw,RLx,tIx,ynu,eM,g4w,Cc2,kwy,f5D,wbD,$s7,I5a,Dsw,n4x,N42,JnD,uBq,K8y,cna,qAx,F89,hR,YAB,beu,xs2,Anw,pb6,L8a,Xb2,m4,tR,Cr,B49,fr,gG,k_,joq,He9,a5u,W8u,dsw,ug,$_,E4W,Zey,UsD,ieP,JR,Ia,N9,AR,Y_,l1a,bg,x_,FZ,mg2,ecw,hcW,Rcq,pr,Lr,tLD,Gc,XZ,Bn,ig,U_,Zh,jM,yDx,Cp6,aa,Hn,Wn,gqw,kaq,E_,O_,I1q,Dg7,oa,nq6,M9,Nl2,Tc,dG,JD9,Vy,PH,usD,ld,cDy,q6D,h_,z8,ys,AD7,R1,Co,gR,Y6a,wR,t_,fo,bWw,$2,xgw,I1,pz2,mK,Qs,FL9,k2,D6,LLa,S69,no,Ga9,NN,J_,ud,Ko,Xz2,qN,cH,FI,A_,BlB,iWD,Y2,bd,x2,po,Lo,Uga,SV, G8,ZWD,jSw,XI,BH,id,HWx,a19,U8,Eq2,WLu,OWx,Z6,oqB,sSy,rDw,MLW,Tlq,jV,a1,HH,E8,VL6,dgy,O8,Pfa,o1,s8,vJ7,lTw,rR,ezy,hzw,Qby,ts6,zzq,m6y,Rzy,T8,Vs,dR,Pj,yix,CfB,vj,fTx,kNw,gJB,zB,hp,$62,ITx,D6D,nJq,mg,NJq,Q5,tp,Jiw,Kz7,ci9,Cq,w6,Ya9,T4a,Dh,x6y,pBD,LzP,Sa6,GN2,wG,fq,XBy,Dl,nq,U67,Z0y,jba,Nt,WzW,aTa,H0q,oJ9,sbu,Jp,riW,O0q,Ms7,uM,Kq,cj,TJW,Vs7,qt,Fl,d6u,Ap,Pm9,bM,$T,Sa,vG9,VIw,OeP,GB,Xl,iM,Uo,Zl,aK,Hj,Bj,Oo,enq,r6,hn9,znx,mk2,Rnq,QV2,Mt,yUW,TB,fky,V5,k1q,wPB,gGu,CmP,$kW,Ika,Dkw,eE,nGD,NZq,uH6,hW,vqx,mx, cUW,FQW,Kr,AUa,YCy,QP,xkx,nr,bMu,o4D,rny,MID,KQa,tW,yP,CP,pPw,LQa,fP,SC9,kQ,w7,$Q,Iw,DY,G1D,nP,Ny,XPq,BZ2,JW,uy,KP,ca,qy,Fu,Uku,iMD,AW,ZMw,aku,YQ,HMx,jVB,ow,Wa,sM,My,TF,va,EG7,TZw,xO,OM,vo,vWB,eK6,GF,zk,SE,ml,EM,t0,Q2q,yW,C_,t5P,yX6,Czw,ftw,f_,gWx,k$W,gh,wE6,NU9,nWa,$iD,DiD,ItP,kH,JXD,wh,ug6,K0u,qwx,F06,AXD,L0q,N3,J0,XEW,uN,K_,BUu,Zlq,j2w,atx,Hl7,co,EWw,Ol6,oWa,Bo,lZq,TU9,V52,hAP,iN,zAa,RAD,mfD,QLq,Zv,Ho,t67,Uv,Ev,Wo,yAB,fZW,w4u,M3,vd,me,tc,YBP,bO7,gw,fj,$M,Ih,xfD,SBa,LfD,GOW,nj,DN,Bky,iOB,Ufw,jLw, X4w,uV,ZOB,aZD,HOu,qA,FV,WfD,rh,Jc,Kj,NkD,CJq,cA9,Lj,ww,ZN,Rh,OD,sD,rw,hWW,eWy,Qi,T6,Vi,zWB,dw,mzW,RWu,yi,p4q,l2,M69,kM,Q8D,IZW,$fq,gjB,eH,zy,DzB,IoW,NaW,JFw,tM,Cc,fc,yI,ki,wd,uRu,$i,cFw,I0,F62,Nh,qW9,u2,Kc,xzu,cS,SW2,Guw,AM,XX2,idx,Zn,a0,HS,WS,UzD,OR,o0,Ty,VI,dd,P6,Zdu,v6,lU,ECD,eT,he,W6x,OdB,z3,oCa,s8u,rFx,Mc7,mi,Ry,TaD,dzq,yh,CH,kD,wb,Ps6,$D,Iy,DL,nH,N8,vfx,l9P,Je,ejy,hjx,uU,mEy,zjB,Rj9,KH,tnu,QJy,c6,yby,q8,FO,Cs7,gfw,kPu,Ae,YD,bU,w1D,xD,I9a,LH,DED,nfD,pH,ST,G3,XO,Kkq,qgy,NIw,cbw,Fkw,JbD,uPu,AbD, Ygw,Ue,b6w,p1P,GP6,BIw,X1P,oy,Oe,M8,UEy,T3,Vh,db,jJw,P8,a9u,Z6w,v8,Wkx,lu,eX,O6D,hy,ofD,M5P,vjy,rbP,sJ2,TI2,Mn2,VnP,mJ,dEa,PgD,eGD,ty,yJ,C5,zGw,QaD,kv,wN,$v,yRB,tM2,f5,Cgx,fhw,g_2,wna,If,cRW,Jy,uu,x9w,jT,L4w,S_w,Gc7,Xn7,BG6,c8,ir9,qn,F4,Ay,U9D,xv,ZrD,jaB,p5,L5,aha,Hrw,E_9,W49,OrD,SX,bu,o_2,GG,rRq,MMu,TG2,X4,VMD,d9x,Pdw,v27,l67,edD,hdB,zd9,mNu,RdW,B8,tV6,iu,y_u,ZC,f62,H8,Q1y,Ux,Ex,W8,Ox,of,sx,rN,g2w,Mn,k8P,VJ,n2y,uI2,KKx,c_w,q87,vm,FK7,J_a,DNB,A_u,dN,Y8a,xNx,TG,Pm,$Nw,I6w,lW,pHu,LK9,NRB,wH7,S8P,hE, G82,zb,mP,XHy,Rc,UN2,BRP,io6,Ql,Zo2,tE,yl,CL,fL,j1q,a6y,HoD,gq,WKy,Oo7,kb,o2w,wq,$b,s1u,r_w,MV2,TRx,VV2,dN2,hFw,vTw,Lk7,D2,mtD,RF6,llu,eF9,PMw,JE,flw,NJ,nL,zFq,kB2,CMD,ypW,ta7,QKD,KL,wj6,ZL,cm,qJ,Fr,$t6,AE,Ilw,Yb,Dt7,rb,nTy,bW,H6,W6,xEy,LL,Gb,ul7,KgD,Xr,iW,SD,pL,Z2,xb,N6y,Jp9,jD,cpx,qoa,af,Cdw,ay,ac,FgW,Bm,Apw,Yo7,bq9,xt6,Hm,E9,Wm,Lgy,SoD,GBW,XjD,B62,bo2,oc,s9,rq,O9,Ut6,H6x,Efy,MJ,ZqD,jKB,alD,Hq2,Tb,ETw,Vl,Wga,oTw,dq,sKq,rpx,vU,May,PU,mM,dtB,VaD,lY2,vQ7,e4y,h4w,Py7,Rz,T6B,z4y,Q9,my6,tED,R4P,QwP,y9, saq,yW6,Cyw,fY2,gQy,kFy,YP,bS,xP,waD,pD,LD,$yD,SA,IYq,Dyq,GK,nQy,N7D,JWP,uuW,XK,RG9,BU,qM6,iS,cWw,UH,FxB,m9D,gN,AW2,Z$,az,xy7,bPD,MK,V9,TK,SMD,dg,GF7,XaD,UyW,ZPw,aYD,iPD,HPW,EQ6,Wx2,OPa,oQa,rWD,MEy,T7W,swP,vR,jA,dyP,B7W,PN9,jww,l7,lvy,VEa,PR,eC9,hCD,RC9,fvq,QID,t0D,gHx,CND,kky,zCy,eh,wou,m3y,Rt,nHD,J07,NhB,uXW,Klq,c0W,D3B,qv7,FlD,hg,A0w,Yvx,b_7,x3W,Svw,Lla,poP,tg,GkP,Bh2,i_W,U3x,Z_7,ff,gT,jX,jIw,avw,H_9,O_u,Wlx,EH2,oHw,r0a,M0B,sI6,m$,lS,V09,d3w,PVy,Rmw,emD,hmD,zmu,Qhy,yca,gT7,y4,lND,vMD,tr7,se,mAD, Ic,Ee,y02,wdB,k6y,$Ax,IND,DAB,nMy,XoW,zK,eA,fNa,Nww,gMD,JcW,OqD,uVu,Iv2,$3D,CVw,hs,$c,It,ccw,DQ,qDD,FeD,Acw,YDw,bju,pdy,Le9,Bw7,SDD,Xda,ij7,N5,aNw,Zj2,jh6,WeB,Ojq,oM2,shw,rca,nf,MrP,EM6,UA2,Jg,TwP,G6a,VrD,u7,P2x,viu,lnx,dA2,Kf,zsB,hsy,Q0D,RsD,mhy,tD6,yEa,cR,CWq,f2w,kbx,wmu,gb9,$Jq,JEW,DJy,nbD,Nq7,urw,KPy,cEu,FPw,q9B,AEP,Y9D,bLD,pm2,S9W,LPw,Gbq,xJW,Xmx,iLD,UJP,jcq,HLy,ZLu,Ag,Eba,WP7,Bqu,OLx,a2a,Yc,obD,scw,rED,MDw,Tqw,VD6,dJ9,vPw,erB,hra,zr2,mK6,Rrq,xc,QzB,pf,ysD,CSw,gPD,X1,wU6,$Ka,I$y,DKw,Ngy,nP9, KMy,csu,BR,UG,Jsw,uKq,qHB,jh,As9,FMy,YHP,bD7,xKB,SHP,pUw,Bgu,at,LMy,iDD,HR,a$P,WR,OG,HD2,EG,EP7,ot,oPw,ODD,ZD6,jzw,szD,rsy,MA6,UKD,Tgq,sG,VAD,WMw,kKD,ZQ,P7y,M5,vcD,lQ2,eua,huy,zuD,m5w,Rux,QtW,th6,ygy,T5,C76,fQ2,k5w,wR6,$5u,gcx,IQB,D59,ncw,NTx,Jgy,u1u,PC,LAw,K$w,cg2,vC,qG9,F$D,eW,bfD,x5u,h2,L$a,SGB,pRx,YGa,zd,lj,Ag7,Q_,RB,G52,t2,mC,U5w,aQD,Ec6,W$w,oc9,BTx,HfD,stD,if7,rg9,Mh7,kx,y_,Vh9,TTu,fZ,vxD,lgW,jtP,Zfy,Pj9,e7W,Ofx,XRD,wS,$x,IB,h7a,Dg,y2W,R79,Cja,QBu,mHB,fgw,z79,$Hx,gxx,nZ,IgB,nxP,J2y,uGW,KCB, FCP,KZ,A2u,c29,gS,xH6,pCW,Yx,vHW,NH,LCy,SLw,XCD,Gdw,BSB,bZy,qH,iZD,UH6,ZZu,aga,jBq,Thq,HZ2,cC,Exq,OZw,WCB,sBD,ox2,NS6,MWy,r2D,FG,J2,TSy,xx,dHw,Prq,v0B,lR7,eU9,bj,I2w,qLy,hUP,Ke7,CZ,zU2,mOx,RUq,QkW,t_2,pZ,LZ,CrW,fRa,g02,yku,krw,SW,DOP,$Ow,IRB,n0D,Gd,NM9,Jk7,u0x,XG,K59,qs9,F5q,Ak6,BC,ckw,ij,UL,Ys6,bXx,aB,Zg,jW,xOq,HC,pKu,L5D,Ssw,XKa,GrB,rS,iXD,UOq,BMw,ZX2,MH,jk2,Td,aRD,V_,HXa,E02,rkw,W5B,o0q,dS,OXa,sky,M_y,TM7,V_a,dOw,vK,P3B,hk,lr,vow,zr,m5,ePP,QV,tk,hPw,Rk,zP9,yV,RPq,mCP,fX,gM,k0,yYB,Q$a,tOw,wM,C3u, wWw,go2,fww,kYw,$0,IwD,N8w,JYW,Ik,ue7,K29,DC2,nou,F2w,AYD,YT9,bhB,xCD,NO,GYB,B8P,Jk,L26,STu,Zhx,nX,ur,KX,pW6,XWw,j$D,cK,qO,awD,Hhy,EoP,F0,W2y,Ohu,ooD,s$a,rYu,MOP,T82,Pe6,VOu,vLD,lzW,h_D,z_x,ir,Ce9,R_6,QgP,fz7,gLw,yC2,me9,kgW,$e9,wg6,IzW,KNx,ZR,FND,bw7,Y47,AC9,JC2,uCD,DeW,nLq,cCD,j_,ak,pg7,Lc,AFw,LN7,Es,Os,Gg6,S47,q4u,BCB,iwD,Uew,ok,ZwW,vW,az7,HwW,EL2,Owu,WN9,oL7,l3,eO,sgy,TCu,VQw,m2,MQy,deD,PPB,rCD,R$,yE,v$2,l4w,tY,e8y,h86,z8a,m06,QEy,R87,CPy,f4a,tfP,keD,wy2,ydW,g8,ko,$0W,D0u,w8,I4D,n$6,JdW,NVB,uWu, $o,KHD,cdD,qXD,I$,Dw,Ad9,FHy,YX6,bm2,pyx,x07,LHu,SXy,Gea,Xy9,BV9,U0w,NC,nh,JY,Zm2,jEx,imu,Oma,o$9,sEw,TV2,MfP,rdu,Vfq,d0W,u3,Kh,Pk7,v5P,luB,eNx,zNW,mpw,qC,RNW,cW,AY,hNx,QQq,tRW,yox,CkD,fua,b3,g52,k4a,Iu7,xo,DpW,$pD,ph,Lh,n5w,NEu,uf6,cow,JoB,Kha,GY,qfD,Aox,Yfq,xpy,p5y,Xe,BW,Lhx,FhP,X52,G4D,Sfw,i3,UT,iQa,BEW,Zw,jO,Upw,a$,ZQx,jQW,au9,HW,HQy,ET,E59,WW,OT,o5y,sQ6,rou,TEa,VRw,dpw,MRx,vVa,PtD,lJa,zYq,r8,RYy,m2P,eYP,hYw,QsD,tGx,MC,TY,yLB,Ctw,fJ9,gV2,khD,wVw,IJ9,D2w,Fjw,JLy,uLa,nVu,YZB,eQ,zg,Lj9,Qe,tC,SZy, buw,le,fw,Cw,mN,gC,BBx,U2P,iuW,kL,Rg,vg,XVB,ye,x2y,GhP,jsw,VE,wC,aJy,HuW,hC,pV6,$L,Ig,EVW,Dz,nw,Ne,Wjw,Ouu,ss7,rLy,oVa,JC,TBD,MGD,ue,VG2,Kw,cg,d22,PiB,vmq,lUu,eZx,zZw,RZ2,mZW,hZu,qe,QCP,y9x,tJD,FC,AC,CiW,gma,kSw,YL,fUW,we9,$Z6,IUy,DZ7,nm2,NyB,J9W,xL,pw,KYD,uc7,c96,Lw,SQ,qFP,FY7,YF9,A9D,bBD,XC,xZw,pe9,ie,LYa,SFB,GSy,Xew,Byq,iBD,ZBw,jC2,aU6,UZ7,HBy,EmD,WY2,OB6,om6,sC2,r9D,MJP,Hg,Tyy,VJP,dZB,l8x,mYy,hwy,vn6,O4,ewx,PRW,zw6,og,QUw,RwP,s4,t7D,yhq,CRq,q5,f87,gnw,DYu,nnB,Npw,rC,Jhu,Tg,Q4,ubq,Ve,KGx,Me,chq, qd7,pf7,lP,LGB,ef,hd,XfD,Gq6,FGD,ze,Bpx,iE7,ZEB,mH,jU9,a8a,HEw,Sdu,RE,WGq,Ena,Qx,bEB,Py,OEu,onu,sUD,rh6,M7x,Ahw,Ydy,vy,P8y,vAw,e$D,dY6,mvw,B6,iU,z5,tkB,yVx,Qx6,C8W,laD,R$7,TpW,faq,z$D,gAP,h$D,U9,pjw,d5y,td,yx,ts,V7D,wDP,nAD,fm,N2D,JVy,Iaa,k$,uMw,Kuw,ksP,cVu,Dvq,qQw,wV,gV,Fu6,YQw,AVW,Cm,xv9,D4,pDw,$$,nm,IE,N0,YLw,LuB,XDP,Gs9,i49,Uva,B2w,uP,Jd,jxD,aaD,H4x,Vky,sxu,rVy,O47,vpw,Wuw,q0,hTD,lKu,zTw,mqa,RT2,Ad,Y$,y12,tow,Qly,x$,T2u,Ge,fKP,Sf,bP,kCD,IKa,Dq7,PwD,wc7,iP,npa,Mk6,Cw9,pm,NvB,FW,J1w,uJu,Kaa,jf, aE,gpy,c17,Hy,EX,qp7,Lm,eT2,Fa6,A1B,Ypy,$q9,bA7,XW,xqq,By,nc,pcu,Spw,Wy,OX,GCa,Xc6,Bvx,Z4,UX,iAy,SQ6,Uqq,ZA2,jlx,aK9,HAx,oE,sX,OAw,r1u,TvD,Way,zOy,mMq,ROB,QPD,tm6,yN9,CGW,gEy,fV6,rV,M0,Te,kpP,wGB,$MW,sC,IVy,Vx,DMu,dV,P5,AD,v5,Pb,nEy,cX,DSP,Nfq,lF,JND,BP,im,P1,uTq,KB6,cNW,qj2,FB9,lk,Yjw,b8W,eR,z4,mh,xM9,Sj9,GpW,RQ,XG9,pGB,LB9,Bfa,i89,UMy,Z8B,jP7,Q2,H8u,DDw,An,lz,EEw,WBw,z$,aV6,Gw,O86,oEq,sPa,to,Nk,Mm7,Tf7,y2,CQ,Vmx,fQ,dMx,ho,Pv6,vZ6,aS6,gE,k5,l3a,wE,$5,eEP,IQ,hED,Du,nQ,zEW,mm9,$da,Np,REq,tbw,QN7,Jo, yOw,uk,KQ,CvD,f3y,gZu,kDP,wOw,$mB,I3u,nZ2,qp,Dm7,Nr2,JOy,uyP,KE2,AO6,cOy,q0W,FEw,bp6,pOP,LEu,S0y,xma,Ff,GDW,XOW,Br2,ipu,UmD,Y5,Zpx,bk,x5,pQ,jNw,a3y,EZw,WEP,OpP,oZ2,rO2,sNw,Mb9,LQ,SR,dm2,Try,Vb2,G4,PA6,vXw,Xf,B5,lra,ik,eta,Uf,htq,Zu,jR,ztD,aQ,H5,mwu,Rt2,Ef,W5,Qia,Of,tU2,yIu,Mp,CAW,fr7,gX9,$ww,w3P,T4,IrW,Dw9,nX7,cf7,kmw,JIW,un9,cIw,PDP,yw;vw=function(P){return function(){return PDP[P].apply(this,arguments)}}; g.e9=function(P,v){return PDP[P]=v}; vaa=function(P){var v=0;return function(){return v
>>7)];lO(P,m,l);Q=Qp[m];Q!==0&&(h-=tr[m],v0(P,h,Q))}}while(e
>>=1)if(v&1&&P.WV[l*2]!==0)return 0;if(P.WV[18]!==0||P.WV[20]!==0||P.WV[26]!==0)return 1;for(l=32;l<256;l++)if(P.WV[l*2]!==0)return 1;return 0}; CK=function(P,v,l){P.TW[P.ji+P.tA*2]=v>>>8&255;P.TW[P.ji+P.tA*2+1]=v&255;P.TW[P.VA+P.tA]=l&255;P.tA++;v===0?P.WV[l*2]++:(P.matches++,v--,P.WV[(hr[l]+256+1)*2]++,P.aA[(v<256?RT[v]:RT[256+(v>>>7)])*2]++);return P.tA===P.T3-1}; g_=function(P,v){P.msg=fK[v];return v}; kI=function(P){for(var v=P.length;--v>=0;)P[v]=0}; w_=function(P){var v=P.state,l=v.pending;l>P.eF&&(l=P.eF);l!==0&&(MF.aJ(P.output,v.TW,v.gB,l,P.al),P.al+=l,v.gB+=l,P.WO+=l,P.eF-=l,v.pending-=l,v.pending===0&&(v.gB=0))}; De=function(P,v){var l=P.g4>=0?P.g4:-1,e=P.Z5-P.g4,h=0;if(P.level>0){P.jF.cq===2&&(P.jF.cq=k2y(P));yp(P,P.W6);yp(P,P.m6);fby(P,P.WV,P.W6.GC);fby(P,P.aA,P.m6.GC);yp(P,P.Gh);for(h=18;h>=3&&P.j_[wL9[h]*2+1]===0;h--);P.OX+=3*(h+1)+5+5+4;var z=P.OX+3+7>>>3;var m=P.pG+3+7>>>3;m<=z&&(z=m)}else z=m=e+5;if(e+4<=z&&l!==-1)v0(P,v?1:0,3),tZ6(P,l,e);else if(P.strategy===4||m===z)v0(P,2+(v?1:0),3),Cx6(P,$I,IT);else{v0(P,4+(v?1:0),3);l=P.W6.GC+1;e=P.m6.GC+1;h+=1;v0(P,l-257,5);v0(P,e-1,5);v0(P,h-4,4);for(z=0;z>>8&255;P.TW[P.pending++]=v&255}; $Rq=function(P,v){var l=P.Px,e=P.Z5,h=P.VZ,z=P.U4,m=P.Z5>P.S_-262?P.Z5-(P.S_-262):0,Q=P.window,t=P.OT,y=P.nO,C=P.Z5+258,f=Q[e+h-1],k=Q[e+h];P.VZ>=P.SK&&(l>>=2);z>P.iQ&&(z=P.iQ);do{var w=v;if(Q[w+h]===k&&Q[w+h-1]===f&&Q[w]===Q[e]&&Q[++w]===Q[e+1]){e+=2;for(w++;Q[++e]===Q[++w]&&Q[++e]===Q[++w]&&Q[++e]===Q[++w]&&Q[++e]===Q[++w]&&Q[++e]===Q[++w]&&Q[++e]===Q[++w]&&Q[++e]===Q[++w]&&Q[++e]===Q[++w]&&e h){P.Qm=v;h=w;if(w>=z)break;f=Q[e+h-1];k=Q[e+h]}}}while((v=y[v&t])>m&&--l!== 0);return h<=P.iQ?h:P.iQ}; KK=function(P){var v=P.S_,l;do{var e=P.w5-P.iQ-P.Z5;if(P.Z5>=v+(v-262)){MF.aJ(P.window,P.window,v,v,0);P.Qm-=v;P.Z5-=v;P.g4-=v;var h=l=P.qk;do{var z=P.head[--h];P.head[h]=z>=v?z-v:0}while(--l);h=l=v;do z=P.nO[--h],P.nO[h]=z>=v?z-v:0;while(--l);e+=v}if(P.jF.XH===0)break;h=P.jF;l=P.window;z=P.Z5+P.iQ;var m=h.XH;m>e&&(m=e);m===0?l=0:(h.XH-=m,MF.aJ(l,h.input,h.iz,m,z),h.state.wrap===1?h.L6=Jr(h.L6,l,m,z):h.state.wrap===2&&(h.L6=uO(h.L6,l,m,z)),h.iz+=m,h.RC+=m,l=m);P.iQ+=l;if(P.iQ+P.mp>=3)for(e=P.Z5-P.mp, P.xC=P.window[e],P.xC=(P.xC< =3&&(P.xC=(P.xC< =3)if(l=CK(P,P.Z5-P.Qm,P.gN-3),P.iQ-=P.gN,P.gN<=P.yA&&P.iQ>=3){P.gN--;do P.Z5++,P.xC=(P.xC< =3&&(P.xC=(P.xC< 4096)&&(P.gN=2));if(P.VZ>=3&&P.gN<=P.VZ){e=P.Z5+P.iQ-3;l=CK(P,P.Z5-1-P.Wk,P.VZ-3);P.iQ-=P.VZ-1;P.VZ-=2;do++P.Z5<=e&&(P.xC=(P.xC< =3&&P.Z5>0&&(e=P.Z5-1,l=z[e],l===z[++e]&&l===z[++e]&&l===z[++e])){for(h=P.Z5+258;l===z[++e]&&l===z[++e]&&l===z[++e]&&l===z[++e]&&l===z[++e]&&l===z[++e]&&l===z[++e]&&l===z[++e]&&e P.iQ&&(P.gN=P.iQ)}P.gN>=3?(l=CK(P,1,P.gN-3),P.iQ-=P.gN,P.Z5+=P.gN,P.gN=0):(l=CK(P,0,P.window[P.Z5]),P.iQ--,P.Z5++);if(l&&(De(P,!1),P.jF.eF===0))return 1}P.mp=0;return v=== 4?(De(P,!0),P.jF.eF===0?3:4):P.tA&&(De(P,!1),P.jF.eF===0)?1:2}; DRw=function(P,v){for(var l;;){if(P.iQ===0&&(KK(P),P.iQ===0)){if(v===0)return 1;break}P.gN=0;l=CK(P,0,P.window[P.Z5]);P.iQ--;P.Z5++;if(l&&(De(P,!1),P.jF.eF===0))return 1}P.mp=0;return v===4?(De(P,!0),P.jF.eF===0?3:4):P.tA&&(De(P,!1),P.jF.eF===0)?1:2}; F7=function(P,v,l,e,h){this.IX=P;this.GG$=v;this.nYc=l;this.KZ$=e;this.func=h}; ng2=function(){this.jF=null;this.status=0;this.TW=null;this.wrap=this.pending=this.gB=this.mN=0;this.Wz=null;this.zd=0;this.method=8;this.SY=-1;this.OT=this.jE=this.S_=0;this.window=null;this.w5=0;this.head=this.nO=null;this.U4=this.SK=this.strategy=this.level=this.yA=this.Px=this.VZ=this.iQ=this.Qm=this.Z5=this.v1=this.Wk=this.gN=this.g4=this.uT=this.jq=this.Ni=this.qk=this.xC=0;this.WV=new MF.Fw(1146);this.aA=new MF.Fw(122);this.j_=new MF.Fw(78);kI(this.WV);kI(this.aA);kI(this.j_);this.Gh=this.m6= this.W6=null;this.Ke=new MF.Fw(16);this.HP=new MF.Fw(573);kI(this.HP);this.Hd=this.vI=0;this.depth=new MF.Fw(573);kI(this.depth);this.QG=this.OZ=this.mp=this.matches=this.pG=this.OX=this.ji=this.tA=this.T3=this.VA=0}; NPa=function(P,v){if(!P||!P.state||v>5||v<0)return P?g_(P,-2):-2;var l=P.state;if(!P.output||!P.input&&P.XH!==0||l.status===666&&v!==4)return g_(P,P.eF===0?-5:-2);l.jF=P;var e=l.SY;l.SY=v;if(l.status===42)if(l.wrap===2)P.L6=0,nK(l,31),nK(l,139),nK(l,8),l.Wz?(nK(l,(l.Wz.text?1:0)+(l.Wz.hp?2:0)+(l.Wz.extra?4:0)+(l.Wz.name?8:0)+(l.Wz.comment?16:0)),nK(l,l.Wz.time&255),nK(l,l.Wz.time>>8&255),nK(l,l.Wz.time>>16&255),nK(l,l.Wz.time>>24&255),nK(l,l.level===9?2:l.strategy>=2||l.level<2?4:0),nK(l,l.Wz.os& 255),l.Wz.extra&&l.Wz.extra.length&&(nK(l,l.Wz.extra.length&255),nK(l,l.Wz.extra.length>>8&255)),l.Wz.hp&&(P.L6=uO(P.L6,l.TW,l.pending,0)),l.zd=0,l.status=69):(nK(l,0),nK(l,0),nK(l,0),nK(l,0),nK(l,0),nK(l,l.level===9?2:l.strategy>=2||l.level<2?4:0),nK(l,3),l.status=113);else{var h=8+(l.jE-8<<4)<<8;h|=(l.strategy>=2||l.level<2?0:l.level<6?1:l.level===6?2:3)<<6;l.Z5!==0&&(h|=32);l.status=113;NW(l,h+(31-h%31));l.Z5!==0&&(NW(l,P.L6>>>16),NW(l,P.L6&65535));P.L6=1}if(l.status===69)if(l.Wz.extra){for(h= l.pending;l.zd<(l.Wz.extra.length&65535)&&(l.pending!==l.mN||(l.Wz.hp&&l.pending>h&&(P.L6=uO(P.L6,l.TW,l.pending-h,h)),w_(P),h=l.pending,l.pending!==l.mN));)nK(l,l.Wz.extra[l.zd]&255),l.zd++;l.Wz.hp&&l.pending>h&&(P.L6=uO(P.L6,l.TW,l.pending-h,h));l.zd===l.Wz.extra.length&&(l.zd=0,l.status=73)}else l.status=73;if(l.status===73)if(l.Wz.name){h=l.pending;do{if(l.pending===l.mN&&(l.Wz.hp&&l.pending>h&&(P.L6=uO(P.L6,l.TW,l.pending-h,h)),w_(P),h=l.pending,l.pending===l.mN)){var z=1;break}z=l.zd h&&(P.L6=uO(P.L6,l.TW,l.pending-h,h));z===0&&(l.zd=0,l.status=91)}else l.status=91;if(l.status===91)if(l.Wz.comment){h=l.pending;do{if(l.pending===l.mN&&(l.Wz.hp&&l.pending>h&&(P.L6=uO(P.L6,l.TW,l.pending-h,h)),w_(P),h=l.pending,l.pending===l.mN)){z=1;break}z=l.zd h&&(P.L6=uO(P.L6,l.TW,l.pending-h,h));z===0&&(l.status=103)}else l.status= 103;l.status===103&&(l.Wz.hp?(l.pending+2>l.mN&&w_(P),l.pending+2<=l.mN&&(nK(l,P.L6&255),nK(l,P.L6>>8&255),P.L6=0,l.status=113)):l.status=113);if(l.pending!==0){if(w_(P),P.eF===0)return l.SY=-1,0}else if(P.XH===0&&(v<<1)-(v>4?9:0)<=(e<<1)-(e>4?9:0)&&v!==4)return g_(P,-5);if(l.status===666&&P.XH!==0)return g_(P,-5);if(P.XH!==0||l.iQ!==0||v!==0&&l.status!==666){e=l.strategy===2?DRw(l,v):l.strategy===3?Ibx(l,v):Ar[l.level].func(l,v);if(e===3||e===4)l.status=666;if(e===1||e===3)return P.eF===0&&(l.SY= -1),0;if(e===2&&(v===1?(v0(l,2,3),lO(l,256,$I),l.QG===16?(P0(l,l.OZ),l.OZ=0,l.QG=0):l.QG>=8&&(l.TW[l.pending++]=l.OZ&255,l.OZ>>=8,l.QG-=8)):v!==5&&(v0(l,0,3),tZ6(l,0,0),v===3&&(kI(l.head),l.iQ===0&&(l.Z5=0,l.g4=0,l.mp=0))),w_(P),P.eF===0))return l.SY=-1,0}if(v!==4)return 0;if(l.wrap<=0)return 1;l.wrap===2?(nK(l,P.L6&255),nK(l,P.L6>>8&255),nK(l,P.L6>>16&255),nK(l,P.L6>>24&255),nK(l,P.RC&255),nK(l,P.RC>>8&255),nK(l,P.RC>>16&255),nK(l,P.RC>>24&255)):(NW(l,P.L6>>>16),NW(l,P.L6&65535));w_(P);l.wrap>0&& (l.wrap=-l.wrap);return l.pending!==0?0:1}; YI=function(P){if(!(this instanceof YI))return new YI(P);P=this.options=MF.assign({level:-1,method:8,chunkSize:16384,f1:15,Ta$:8,strategy:0,yH:""},P||{});P.raw&&P.f1>0?P.f1=-P.f1:P.xb&&P.f1>0&&P.f1<16&&(P.f1+=16);this.err=0;this.msg="";this.ended=!1;this.chunks=[];this.jF=new JJB;this.jF.eF=0;var v=this.jF;var l=P.level,e=P.method,h=P.f1,z=P.Ta$,m=P.strategy;if(v){var Q=1;l===-1&&(l=6);h<0?(Q=0,h=-h):h>15&&(Q=2,h-=16);if(z<1||z>9||e!==8||h<8||h>15||l<0||l>9||m<0||m>4)v=g_(v,-2);else{h===8&&(h=9); var t=new ng2;v.state=t;t.jF=v;t.wrap=Q;t.Wz=null;t.jE=h;t.S_=1< >=7;z<30;z++)for(tr[z]=m<<7,h=0;h<1< =y.S_&&(v===0&&(kI(y.head),y.Z5=0,y.g4=0,y.mp=0),l=new MF.Bv(y.S_),MF.aJ(l,z,m-y.S_,y.S_,0),z=l,m=y.S_);l=P.XH;e=P.iz;h=P.input;P.XH=m;P.iz=0;P.input=z;for(KK(y);y.iQ>=3;){z=y.Z5;m=y.iQ-2;do y.xC=(y.xC< =1&&(l[16]>9?((0,l[14])((0,l[18])((0,l[53])(l[64],l[3]),l[35],l[87],l[36]),l[18],(0,l[18])((0,l[18])((0,l[37])(l[9],l[12]),l[38],l[57],l[19]),l[47],l[46],(0,l[62])(),l[6]),l[new Date("1970-01-01T06:15:47.000+06:15")/1E3],l[87],(0,l[44])(),l[6]),l[39])((0,l[58])(l[60],l[3]),l[37],(0,l[37])(l[46],l[41]),l[46],l[40]):((((((((0,l[38])(l[46],l[24]),l[58])(l[1],l[57]),l[16])((0,l[36])(l[44], l[32]),l[33],l[1],l[31]),l[45])(l[7],(0,l[78])(),l[4]),l[33])(l[85],l[11]),l[33])(l[55],l[0]),l[56])(l[71],l[55]),l[76])(l[0],l[27])),l[6]>=0&&(((((0,l[28])(l[20]),l[11])(l[72],l[67]),l[72])(l[20],l[23]),((0,l[9])(l[61]),l[69])(l[59],l[77]),l[4])(l[new Date("1970-01-01T07:30:05.000+07:30")/1E3])===(((0,l[84])((0,l[84])((0,l[49])(l[48],l[56]),l[4],l[45]),l[23],l[33],l[53]),l[19])(l[71],l[46]),l[10])(l[72],l[68])*(0,l[10])(l[62],l[57])<<(0,l[33])(l[78],l[32])|(0,l[12])(l[55],l[16]),[])||(0,l[new Date("1970-01-01T04:46:26.000+04:45")/ 1E3])((0,l[86])((((((0,l[65])((0,l[84])(l[46],l[31]),l[6],l[56],(0,l[39])(),l[53]),l[6])(l[5],(0,l[21])(),l[53]),l[65])((0,l[6])(l[56],(0,l[3])(),l[53]),l[84],l[56],l[54]),l[6])(l[5],(0,l[21])(),l[53]),l[6])(l[46],(0,l[40])(),l[53]),l[57],(((0,l[84])(l[16],l[22]),l[6])(l[46],(0,l[25])(),l[53]),l[6])(l[5],(0,l[21])(),l[53]),l[16]),l[new Date("1969-12-31T12:31:25.000-11:30")/1E3],((0,l[17])(l[11],l[46]),l[84])(l[7],l[34]),l[7],l[37]),(l[new Date("1969-12-31T22:31:06.000-01:30")/1E3]===-2||((0,l[65])((0,l[65])((0,l[17])(l[51], l[5]),l[85],l[7],l[30]),l[82],l[24],l[72]),0))&&(((0,l[39])(l[38],(0,l[54])(),l[86]),l[2])(l[49]),(0,l[39])(l[1],(0,l[54])(),l[86])),l[21]>=0?(0,l[45])(l[34],l[82]):(0,l[50])(l[37],l[82])}catch(e){((0,l[39])(l[38],(0,l[54])(),l[86]),(0,l[2])(l[new Date("1969-12-31T13:16:19.000-10:45")/1E3]),l[39])(l[38],(0,l[58])(),l[86]),(0,l[29])(l[38],l[35])}try{l[28]>=7&&(l[56]<5||((0,l[31])((0,l[2])(l[38]),l[50],(0,l[45])(l[17],l[1]),l[59],l[49]),""))&&((0,l[42])(l[4],l[3]),l[23])((0,l[42])(l[51],l[81]),l[43], l[62],l[61]),l[18]<=-7&&(l[74]>=2&&((0,l[43])(l[62],l[34]),'"{')||(0,l[43])(l[53],l[82]))}catch(e){(0,l[60])(l[59],(0,l[6])(),l[19]),(0,l[40])(l[59])}try{l[69]<-1&&(l[33]==new Date("1970-01-01T08:44:59.000+08:45")/1E3&&((0,l[60])(l[59],(0,l[6])(),l[19]),1)||(0,l[48])(l[59],l[34])),(0,l[4])(l[59]),(0,l[50])(l[22],l[62])}catch(e){(l[78]!==9||(((0,l[52])((0,l[52])((0,l[66])(l[new Date("1969-12-31T20:00:33.000-04:00")/1E3],l[59]),l[51],(0,l[50])(l[12],l[72]),l[61],l[82]),l[60],(0,l[50])(l[15],l[29]), l[22],(0,l[79])(),l[19]),l[52])((0,l[60])(l[22],(0,l[5])(),l[19]),l[51],(0,l[71])(l[35],l[15]),l[15],l[68]),0))&&(((((0,l[23])(l[15]),((0,l[37])(l[65],l[24]),l[21])(l[0],l[75]),l[21])(l[63],l[75]),l[36])(l[65],l[57]),l[37])(l[75],l[23]),l[56])((0,l[36])(l[17],l[33]),l[30],l[11],l[60])}}catch(e){return"aUavRB8dYYom50B5OL-_w8_"+P}return v.join("")}; jAD=function(P){return P,"Content-Transfer-Encoding"[2+!!P]}; g.Go=function(P){this.name=P}; abD=function(P){this.fI=bT(P)}; X7=function(P){this.fI=bT(P)}; B0=function(P){this.fI=bT(P)}; HbD=function(P){this.fI=bT(P)}; iO=function(P){this.fI=bT(P)}; U5=function(P){this.fI=bT(P)}; Ze=function(P){this.fI=bT(P)}; jS=function(P){this.fI=bT(P)}; aT=function(P){this.fI=bT(P)}; H0=function(P){this.fI=bT(P)}; O5=function(P){this.fI=bT(P)}; oT=function(P){this.fI=bT(P)}; s5=function(P){this.fI=bT(P)}; r_=function(P){this.fI=bT(P)}; MW=function(P){this.fI=bT(P)}; To=function(P){this.fI=bT(P,500)}; Vp=function(P){this.fI=bT(P)}; d_=function(P){this.fI=bT(P)}; EgW=function(P){this.fI=bT(P)}; WUw=function(){return g.j9("yt.ads.biscotti.lastId_")||""}; ObB=function(P){g.ZB("yt.ads.biscotti.lastId_",P)}; vM=function(){var P=arguments,v=PM;P.length>1?v[P[0]]=P[1]:P.length===1&&Object.assign(v,P[0])}; g.la=function(P,v){return P in PM?PM[P]:v}; eN=function(P){var v=PM.EXPERIMENT_FLAGS;return v?v[P]:void 0}; oga=function(P){hZ.forEach(function(v){return v(P)})}; g.mV=function(P){return P&&window.yterr?function(){try{return P.apply(this,arguments)}catch(v){g.z_(v)}}:P}; g.z_=function(P){var v=g.j9("yt.logging.errors.log");v?v(P,"ERROR",void 0,void 0,void 0,void 0,void 0):(v=g.la("ERRORS",[]),v.push([P,"ERROR",void 0,void 0,void 0,void 0,void 0]),vM("ERRORS",v));oga(P)}; RZ=function(P,v,l,e,h){var z=g.j9("yt.logging.errors.log");z?z(P,"WARNING",v,l,e,void 0,h):(z=g.la("ERRORS",[]),z.push([P,"WARNING",v,l,e,void 0,h]),vM("ERRORS",z))}; QS=function(P,v){v=P.split(v);for(var l={},e=0,h=v.length;e 1?P[1]:P[0])):{}}; g$=function(P,v){return TP9(P,v||{},!0)}; kN=function(P,v){return TP9(P,v||{},!1)}; TP9=function(P,v,l){var e=P.split("#",2);P=e[0];e=e.length>1?"#"+e[1]:"";var h=P.split("?",2);P=h[0];h=yS(h[1]||"");for(var z in v)if(l||!g.Yr(h,z))h[z]=v[z];return g.r5(P,h)+e}; w$=function(P){if(!v)var v=window.location.href;var l=g.ap(1,P),e=g.Hl(P);l&&e?(P=P.match(jC),v=v.match(jC),P=P[3]==v[3]&&P[1]==v[1]&&P[4]==v[4]):P=e?g.Hl(v)===e&&(Number(g.ap(4,v))||null)===(Number(g.ap(4,P))||null):!0;return P}; $N=function(P){P||(P=document.location.href);P=g.ap(1,P);return P!==null&&P==="https"}; IZ=function(P){P=VZq(P);return P===null?!1:P[0]==="com"&&P[1].match(/^youtube(?:kids|-nocookie)?$/)?!0:!1}; dRw=function(P){P=VZq(P);return P===null?!1:P[1]==="google"?!0:P[2]==="google"?P[0]==="au"&&P[1]==="com"?!0:P[0]==="uk"&&P[1]==="co"?!0:!1:!1}; VZq=function(P){P=g.Hl(P);return P!==null?P.split(".").reverse():null}; sAB=function(P){return P&&P.match(PnB)?P:dO(P)}; Nc=function(P){var v=Dp;P=P===void 0?WUw():P;var l=Object,e=l.assign,h=nG(v);var z=v.W;try{var m=z.screenX;var Q=z.screenY}catch(q){}try{var t=z.outerWidth;var y=z.outerHeight}catch(q){}try{var C=z.innerWidth;var f=z.innerHeight}catch(q){}try{var k=z.screenLeft;var w=z.screenTop}catch(q){}try{C=z.innerWidth,f=z.innerHeight}catch(q){}try{var I=z.screen.availWidth;var J=z.screen.availTop}catch(q){}z=[k,w,m,Q,I,J,t,y,C,f];m=nuB(!1,v.W.top);Q={};var K=K===void 0?g.Uy:K;t=new P7;"SVGElement"in K&&"createElementNS"in K.document&&t.set(0);y=LdD();y["allow-top-navigation-by-user-activation"]&&t.set(1);y["allow-popups-to-escape-sandbox"]&&t.set(2);K.crypto&&K.crypto.subtle&&t.set(3);"TextDecoder"in K&&"TextEncoder"in K&&t.set(4);K=bna(t);v=(Q.bc=K,Q.bih=m.height,Q.biw=m.width,Q.brdim=z.join(),Q.vis=KC(v.K),Q.wgl=!!NL.WebGLRenderingContext,Q);l=e.call(l,h,v);l.ca_type="image";P&&(l.bid=P);return l}; nG=function(P){var v={};v.dt=vsw;v.flash="0";a:{try{var l=P.W.top.location.href}catch(C){P=2;break a}P=l?l===P.K.location.href?0:1:2}v=(v.frm=P,v);try{v.u_tz=-(new Date).getTimezoneOffset();var e=e===void 0?NL:e;try{var h=e.history.length}catch(C){h=0}v.u_his=h;var z;v.u_h=(z=NL.screen)==null?void 0:z.height;var m;v.u_w=(m=NL.screen)==null?void 0:m.width;var Q;v.u_ah=(Q=NL.screen)==null?void 0:Q.availHeight;var t;v.u_aw=(t=NL.screen)==null?void 0:t.availWidth;var y;v.u_cd=(y=NL.screen)==null?void 0: y.colorDepth}catch(C){}return v}; evx=function(){if(!lqx)return null;var P=lqx();return"open"in P?P:null}; g.ua=function(P){switch(JZ(P)){case 200:case 201:case 202:case 203:case 204:case 205:case 206:case 304:return!0;default:return!1}}; JZ=function(P){return P&&"status"in P?P.status:-1}; g.KG=function(P,v){typeof P==="function"&&(P=g.mV(P));return window.setTimeout(P,v)}; g.cM=function(P,v){typeof P==="function"&&(P=g.mV(P));return window.setInterval(P,v)}; g.qc=function(P){window.clearTimeout(P)}; g.Ft=function(P){window.clearInterval(P)}; g.YN=function(P){P=AZ(P);return typeof P==="string"&&P==="false"?!1:!!P}; g.ba=function(P,v){P=AZ(P);return P===void 0&&v!==void 0?v:Number(P||0)}; xN=function(){return g.la("EXPERIMENTS_TOKEN","")}; AZ=function(P){return g.la("EXPERIMENT_FLAGS",{})[P]}; pG=function(){for(var P=[],v=g.la("EXPERIMENTS_FORCED_FLAGS",{}),l=g.N(Object.keys(v)),e=l.next();!e.done;e=l.next())e=e.value,P.push({key:e,value:String(v[e])});l=g.la("EXPERIMENT_FLAGS",{});e=g.N(Object.keys(l));for(var h=e.next();!h.done;h=e.next())h=h.value,h.startsWith("force_")&&v[h]===void 0&&P.push({key:h,value:String(l[h])});return P}; LG=function(P,v,l,e,h,z,m,Q){function t(){(y&&"readyState"in y?y.readyState:0)===4&&v&&g.mV(v)(y)} l=l===void 0?"GET":l;e=e===void 0?"":e;Q=Q===void 0?!1:Q;var y=evx();if(!y)return null;"onloadend"in y?y.addEventListener("loadend",t,!1):y.onreadystatechange=t;g.YN("debug_forward_web_query_parameters")&&(P=hvu(P,window.location.search));y.open(l,P,!0);z&&(y.responseType=z);m&&(y.withCredentials=!0);l=l==="POST"&&(window.FormData===void 0||!(e instanceof FormData));if(h=zva(P,h))for(var C in h)y.setRequestHeader(C,h[C]),"content-type"===C.toLowerCase()&&(l=!1);l&&y.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");if(Q&&"setAttributionReporting"in XMLHttpRequest.prototype){P={eventSourceEligible:!0,triggerEligible:!1};try{y.setAttributionReporting(P)}catch(f){RZ(f)}}y.send(e);return y}; zva=function(P,v){v=v===void 0?{}:v;var l=w$(P),e=g.la("INNERTUBE_CLIENT_NAME"),h=g.YN("web_ajax_ignore_global_headers_if_set"),z;for(z in m77){var m=g.la(m77[z]),Q=z==="X-Goog-AuthUser"||z==="X-Goog-PageId";z!=="X-Goog-Visitor-Id"||m||(m=g.la("VISITOR_DATA"));var t;if(!(t=!m)){if(!(t=l||(g.Hl(P)?!1:!0))){t=P;var y;if(y=g.YN("add_auth_headers_to_remarketing_google_dot_com_ping")&&z==="Authorization"&&(e==="TVHTML5"||e==="TVHTML5_UNPLUGGED"||e==="TVHTML5_SIMPLY")&&dRw(t))t=ZP(g.ap(5,t))||"",t=t.split("/"), t="/"+(t.length>1?t[1]:""),y=t==="/pagead";t=y?!0:!1}t=!t}t||h&&v[z]!==void 0||e==="TVHTML5_UNPLUGGED"&&Q||(v[z]=m)}"X-Goog-EOM-Visitor-Id"in v&&"X-Goog-Visitor-Id"in v&&delete v["X-Goog-Visitor-Id"];if(l||!g.Hl(P))v["X-YouTube-Utc-Offset"]=String(-(new Date).getTimezoneOffset());if(l||!g.Hl(P)){try{var C=(new Intl.DateTimeFormat).resolvedOptions().timeZone}catch(f){}C&&(v["X-YouTube-Time-Zone"]=C)}document.location.hostname.endsWith("youtubeeducation.com")||!l&&g.Hl(P)||(v["X-YouTube-Ad-Signals"]= tZ(Nc()));return v}; Qjw=function(P,v){var l=g.Hl(P);g.YN("debug_handle_relative_url_for_query_forward_killswitch")||!l&&w$(P)&&(l=document.location.hostname);var e=ZP(g.ap(5,P));e=(l=l&&(l.endsWith("youtube.com")||l.endsWith("youtube-nocookie.com")))&&e&&e.startsWith("/api/");if(!l||e)return P;var h=yS(v),z={};g.f$(Rvw,function(m){h[m]&&(z[m]=h[m])}); return kN(P,z)}; G_=function(P,v){v.method="POST";v.postParams||(v.postParams={});return g.SN(P,v)}; CnP=function(P,v){if(window.fetch&&v.format!=="XML"){var l={method:v.method||"GET",credentials:"same-origin"};v.headers&&(l.headers=v.headers);v.priority&&(l.priority=v.priority);P=tFD(P,v);var e=yaw(P,v);e&&(l.body=e);v.withCredentials&&(l.credentials="include");var h=v.context||g.Uy,z=!1,m;fetch(P,l).then(function(Q){if(!z){z=!0;m&&g.qc(m);var t=Q.ok,y=function(C){C=C||{};t?v.onSuccess&&v.onSuccess.call(h,C,Q):v.onError&&v.onError.call(h,C,Q);v.onFinish&&v.onFinish.call(h,C,Q)}; (v.format||"JSON")==="JSON"&&(t||Q.status>=400&&Q.status<500)?Q.json().then(y,function(){y(null)}):y(null)}}).catch(function(){v.onError&&v.onError.call(h,{},{})}); P=v.timeout||0;v.onFetchTimeout&&P>0&&(m=g.KG(function(){z||(z=!0,g.qc(m),v.onFetchTimeout.call(v.context||g.Uy))},P))}else g.SN(P,v)}; g.SN=function(P,v){var l=v.format||"JSON";P=tFD(P,v);var e=yaw(P,v),h=!1,z=fqy(P,function(t){if(!h){h=!0;Q&&g.qc(Q);var y=g.ua(t),C=null,f=400<=t.status&&t.status<500,k=500<=t.status&&t.status<600;if(y||f||k)C=gsD(P,l,t,v.convertToSafeHtml);y&&(y=kRD(l,t,C));C=C||{};f=v.context||g.Uy;y?v.onSuccess&&v.onSuccess.call(f,t,C):v.onError&&v.onError.call(f,t,C);v.onFinish&&v.onFinish.call(f,t,C)}},v.method,e,v.headers,v.responseType,v.withCredentials); e=v.timeout||0;if(v.onTimeout&&e>0){var m=v.onTimeout;var Q=g.KG(function(){h||(h=!0,z.abort(),g.qc(Q),m.call(v.context||g.Uy,z))},e)}return z}; tFD=function(P,v){v.includeDomain&&(P=document.location.protocol+"//"+document.location.hostname+(document.location.port?":"+document.location.port:"")+P);var l=g.la("XSRF_FIELD_NAME");if(v=v.urlParams)v[l]&&delete v[l],P=g$(P,v);return P}; yaw=function(P,v){var l=g.la("XSRF_FIELD_NAME"),e=g.la("XSRF_TOKEN"),h=v.postBody||"",z=v.postParams,m=g.la("XSRF_FIELD_NAME"),Q;v.headers&&(Q=v.headers["Content-Type"]);v.excludeXsrf||g.Hl(P)&&!v.withCredentials&&g.Hl(P)!==document.location.hostname||v.method!=="POST"||Q&&Q!=="application/x-www-form-urlencoded"||v.postParams&&v.postParams[m]||(z||(z={}),z[l]=e);(g.YN("ajax_parse_query_data_only_when_filled")&&z&&Object.keys(z).length>0||z)&&typeof h==="string"&&(h=yS(h),g.Br(h,z),h=v.postBodyFormat&& v.postBodyFormat==="JSON"?JSON.stringify(h):g.sU(h));z=h||z&&!g.pU(z);!w9w&&z&&v.method!=="POST"&&(w9w=!0,g.z_(Error("AJAX request with postData should use POST")));return h}; gsD=function(P,v,l,e){var h=null;switch(v){case "JSON":try{var z=l.responseText}catch(m){throw e=Error("Error reading responseText"),e.params=P,RZ(e),m;}P=l.getResponseHeader("Content-Type")||"";z&&P.indexOf("json")>=0&&(z.substring(0,5)===")]}'\n"&&(z=z.substring(5)),h=JSON.parse(z));break;case "XML":if(P=(P=l.responseXML)?$7P(P):null)h={},g.f$(P.getElementsByTagName("*"),function(m){h[m.tagName]=Iqw(m)})}e&&D7P(h); return h}; D7P=function(P){if(g.Oy(P))for(var v in P)v==="html_content"||j7w(v,"_html")?P[v]=UN(P[v]):D7P(P[v])}; kRD=function(P,v,l){if(v&&v.status===204)return!0;switch(P){case "JSON":return!!l;case "XML":return Number(l&&l.return_code)===0;case "RAW":return!0;default:return!!l}}; $7P=function(P){return P?(P=("responseXML"in P?P.responseXML:P).getElementsByTagName("root"))&&P.length>0?P[0]:null:null}; Iqw=function(P){var v="";g.f$(P.childNodes,function(l){v+=l.nodeValue}); return v}; BM=function(P,v){var l=g.GA(v),e;return(new g.Jt(function(h,z){l.onSuccess=function(m){g.ua(m)?h(new nsW(m)):z(new Xt("Request failed, status="+JZ(m),"net.badstatus",m))}; l.onError=function(m){z(new Xt("Unknown request error","net.unknown",m))}; l.onTimeout=function(m){z(new Xt("Request timed out","net.timeout",m))}; e=g.SN(P,l)})).bY(function(h){if(h instanceof At){var z; (z=e)==null||z.abort()}return cl(h)})}; g.ia=function(P,v,l,e){function h(Q,t,y){return Q.bY(function(C){if(t<=0||JZ(C.xhr)===403)return cl(new Xt("Request retried too many times","net.retryexhausted",C.xhr,C));C=Math.pow(2,l-t+1)*y;var f=m>0?Math.min(m,C):C;return z(y).then(function(){return h(BM(P,v),t-1,f)})})} function z(Q){return new g.Jt(function(t){setTimeout(t,Q)})} var m=m===void 0?-1:m;return h(BM(P,v),l-1,e)}; Xt=function(P,v,l){wo.call(this,P+", errorCode="+v);this.errorCode=v;this.xhr=l;this.name="PromiseAjaxError"}; nsW=function(P){this.xhr=P}; Uk=function(P){this.W=P===void 0?null:P;this.G=0;this.K=null}; Zp=function(P){var v=new Uk;P=P===void 0?null:P;v.G=2;v.K=P===void 0?null:P;return v}; jN=function(P){var v=new Uk;P=P===void 0?null:P;v.G=1;v.K=P===void 0?null:P;return v}; g.Ek=function(P,v,l,e,h){aZ||HM.set(""+P,v,{HN:l,path:"/",domain:e===void 0?"youtube.com":e,secure:h===void 0?!1:h})}; g.WM=function(P,v){if(!aZ)return HM.get(""+P,v)}; g.Ok=function(P,v,l){aZ||HM.remove(""+P,v===void 0?"/":v,l===void 0?"youtube.com":l)}; Njx=function(){if(g.YN("embeds_web_enable_cookie_detection_fix")){if(!g.Uy.navigator.cookieEnabled)return!1}else if(!HM.isEnabled())return!1;if(!HM.isEmpty())return!0;g.YN("embeds_web_enable_cookie_detection_fix")?HM.set("TESTCOOKIESENABLED","1",{HN:60,kW3:"none",secure:!0}):HM.set("TESTCOOKIESENABLED","1",{HN:60});if(HM.get("TESTCOOKIESENABLED")!=="1")return!1;HM.remove("TESTCOOKIESENABLED");return!0}; g.a=function(P,v){if(P)return P[v.name]}; oZ=function(P){var v=g.la("INNERTUBE_HOST_OVERRIDE");v&&(P=String(v)+String(EU(P)));return P}; Jaq=function(P){var v={};g.YN("json_condensed_response")&&(v.prettyPrint="false");return P=kN(P,v)}; sk=function(P,v){var l=l===void 0?{}:l;P={method:v===void 0?"POST":v,mode:w$(P)?"same-origin":"cors",credentials:w$(P)?"same-origin":"include"};v={};for(var e=g.N(Object.keys(l)),h=e.next();!h.done;h=e.next())h=h.value,l[h]&&(v[h]=l[h]);Object.keys(v).length>0&&(P.headers=v);return P}; r$=function(){var P=/Chrome\/(\d+)/.exec(g.Y3());return P?parseFloat(P[1]):NaN}; T_=function(){return g.Mc("android")&&g.Mc("chrome")&&!(g.Mc("trident/")||g.Mc("edge/"))&&!g.Mc("cobalt")}; ux7=function(){return g.Mc("armv7")||g.Mc("aarch64")||g.Mc("android")}; g.VS=function(){return g.Mc("cobalt")}; d$=function(){return g.Mc("cobalt")&&g.Mc("appletv")}; Px=function(){return g.Mc("(ps3; leanback shell)")||g.Mc("ps3")&&g.VS()}; Ko9=function(){return g.Mc("(ps4; leanback shell)")||g.Mc("ps4")&&g.VS()}; g.cax=function(){return g.VS()&&(g.Mc("ps4 vr")||g.Mc("ps4 pro vr"))}; vx=function(){var P=/WebKit\/([0-9]+)/.exec(g.Y3());return!!(P&&parseInt(P[1],10)>=600)}; lZ=function(){var P=/WebKit\/([0-9]+)/.exec(g.Y3());return!!(P&&parseInt(P[1],10)>=602)}; qSy=function(){return g.Mc("iemobile")||g.Mc("windows phone")&&g.Mc("edge")}; zT=function(){return(eB||hB)&&g.Mc("applewebkit")&&!g.Mc("version")&&(!g.Mc("safari")||g.Mc("gsa/"))}; Ru=function(){return g.mp&&g.Mc("version/")}; QK=function(){return g.Mc("smart-tv")&&g.Mc("samsung")}; g.Mc=function(P){var v=g.Y3();return v?v.toLowerCase().indexOf(P)>=0:!1}; tB=function(){return Eh6()||zT()||Ru()?!0:g.la("EOM_VISITOR_DATA")?!1:!0}; yK=function(P,v){return v===void 0||v===null?P:v==="1"||v===!0||v===1||v==="True"?!0:!1}; Ck=function(P,v,l){for(var e in l)if(l[e]==v)return l[e];return P}; fk=function(P,v){return v===void 0||v===null?P:Number(v)}; gD=function(P,v){return v===void 0||v===null?P:v.toString()}; kd=function(P,v){if(v){if(P==="fullwidth")return Infinity;if(P==="fullheight")return 0}return P&&(v=P.match(FoD))&&(P=Number(v[2]),v=Number(v[1]),!isNaN(P)&&!isNaN(v)&&P>0)?v/P:NaN}; wD=function(P){var v=P.docid||P.video_id||P.videoId||P.id;if(v)return v;v=P.raw_player_response;v||(P=P.player_response)&&(v=JSON.parse(P));return v&&v.videoDetails&&v.videoDetails.videoId||null}; Aaa=function(P){return $d(P,!1)==="EMBEDDED_PLAYER_MODE_PFL"}; g.Iu=function(P){return P==="EMBEDDED_PLAYER_LITE_MODE_FIXED_PLAYBACK_LIMIT"||P==="EMBEDDED_PLAYER_LITE_MODE_DYNAMIC_PLAYBACK_LIMIT"?!0:!1}; $d=function(P,v){v=(v===void 0?0:v)?"EMBEDDED_PLAYER_MODE_DEFAULT":"EMBEDDED_PLAYER_MODE_UNKNOWN";window.location.hostname.includes("youtubeeducation.com")&&(v="EMBEDDED_PLAYER_MODE_PFL");var l=P.raw_embedded_player_response;if(!l&&(P=P.embedded_player_response))try{l=JSON.parse(P)}catch(e){return v}return l?Ck(v,l.embeddedPlayerMode,YSW):v}; nk=function(P){wo.call(this,P.message||P.description||P.name);this.isMissing=P instanceof Dd;this.isTimeout=P instanceof Xt&&P.errorCode=="net.timeout";this.isCanceled=P instanceof At}; Dd=function(){wo.call(this,"Biscotti ID is missing from server")}; bTy=function(){if(g.YN("disable_biscotti_fetch_entirely_for_all_web_clients"))return Error("Biscotti id fetching has been disabled entirely.");if(!tB())return Error("User has not consented - not fetching biscotti id.");var P=g.la("PLAYER_VARS",{});if(g.LU(P,"privembed",!1)=="1")return Error("Biscotti ID is not available in private embed mode");if(Aaa(P))return Error("Biscotti id fetching has been disabled for pfl.")}; SS2=function(){var P=bTy();if(P!==void 0)return cl(P);N1||(N1=BM("//googleads.g.doubleclick.net/pagead/id",x7x).then(p9D).bY(function(v){return LoD(2,v)})); return N1}; p9D=function(P){P=P.xhr.responseText;if(!NG(P,")]}'"))throw new Dd;P=JSON.parse(P.substr(4));if((P.type||1)>1)throw new Dd;P=P.id;ObB(P);N1=jN(P);GR7(18E5,2);return P}; LoD=function(P,v){v=new nk(v);ObB("");N1=Zp(v);P>0&&GR7(12E4,P-1);throw v;}; GR7=function(P,v){g.KG(function(){BM("//googleads.g.doubleclick.net/pagead/id",x7x).then(p9D,function(l){return LoD(v,l)}).bY(g.Ip)},P)}; X99=function(){try{var P=g.j9("yt.ads.biscotti.getId_");return P?P():SS2()}catch(v){return cl(v)}}; iTD=function(P){P&&(P.dataset?P.dataset[Bj9()]="true":xuP(P))}; U7D=function(P){return P?P.dataset?P.dataset[Bj9()]:P.getAttribute("data-loaded"):null}; Bj9=function(){return ZT9.loaded||(ZT9.loaded="loaded".replace(/\-([a-z])/g,function(P,v){return v.toUpperCase()}))}; jjD=function(){var P=document;if("visibilityState"in P)return P.visibilityState;var v=JB+"VisibilityState";if(v in P)return P[v]}; uZ=function(P,v){var l;iB(P,function(e){l=v[e];return!!l}); return l}; Kk=function(P){if(P.requestFullscreen)P=P.requestFullscreen(void 0);else if(P.webkitRequestFullscreen)P=P.webkitRequestFullscreen();else if(P.mozRequestFullScreen)P=P.mozRequestFullScreen();else if(P.msRequestFullscreen)P=P.msRequestFullscreen();else if(P.webkitEnterFullscreen)P=P.webkitEnterFullscreen();else return Promise.reject(Error("Fullscreen API unavailable"));return P instanceof Promise?P:Promise.resolve()}; Fz=function(P){var v;g.cx()?q1()==P&&(v=document):v=P;return v&&(P=uZ(["exitFullscreen","webkitExitFullscreen","mozCancelFullScreen","msExitFullscreen"],v))?(v=P.call(v),v instanceof Promise?v:Promise.resolve()):Promise.resolve()}; aqa=function(P){return g.om(["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],function(v){return"on"+v.toLowerCase()in P})}; HTw=function(){var P=document;return g.om(["fullscreenerror","webkitfullscreenerror","mozfullscreenerror","MSFullscreenError"],function(v){return"on"+v.toLowerCase()in P})}; g.cx=function(){return!!uZ(["fullscreenEnabled","webkitFullscreenEnabled","mozFullScreenEnabled","msFullscreenEnabled"],document)}; q1=function(P){P=P===void 0?!1:P;var v=uZ(["fullscreenElement","webkitFullscreenElement","mozFullScreenElement","msFullscreenElement"],document);if(P)for(;v&&v.shadowRoot;)v=v.shadowRoot.fullscreenElement;return v?v:null}; AB=function(P){this.type="";this.state=this.source=this.data=this.currentTarget=this.relatedTarget=this.target=null;this.charCode=this.keyCode=0;this.metaKey=this.shiftKey=this.ctrlKey=this.altKey=!1;this.rotation=this.clientY=this.clientX=0;this.scale=1;this.changedTouches=this.touches=null;try{if(P=P||window.event){this.event=P;for(var v in P)v in Esw||(this[v]=P[v]);this.scale=P.scale;this.rotation=P.rotation;var l=P.target||P.srcElement;l&&l.nodeType==3&&(l=l.parentNode);this.target=l;var e=P.relatedTarget; if(e)try{e=e.nodeName?e:null}catch(h){e=null}else this.type=="mouseover"?e=P.fromElement:this.type=="mouseout"&&(e=P.toElement);this.relatedTarget=e;this.clientX=P.clientX!=void 0?P.clientX:P.pageX;this.clientY=P.clientY!=void 0?P.clientY:P.pageY;this.keyCode=P.keyCode?P.keyCode:P.which;this.charCode=P.charCode||(this.type=="keypress"?this.keyCode:0);this.altKey=P.altKey;this.ctrlKey=P.ctrlKey;this.shiftKey=P.shiftKey;this.metaKey=P.metaKey;this.W=P.pageX;this.K=P.pageY}}catch(h){}}; Wo2=function(P){if(document.body&&document.documentElement){var v=document.body.scrollTop+document.documentElement.scrollTop;P.W=P.clientX+(document.body.scrollLeft+document.documentElement.scrollLeft);P.K=P.clientY+v}}; OTW=function(P,v,l,e){e=e===void 0?{}:e;P.addEventListener&&(v!="mouseenter"||"onmouseenter"in document?v!="mouseleave"||"onmouseenter"in document?v=="mousewheel"&&"MozBoxSizing"in document.documentElement.style&&(v="MozMousePixelScroll"):v="mouseout":v="mouseover");return xr(Yd,function(h){var z=typeof h[4]==="boolean"&&h[4]==!!e,m=g.Oy(h[4])&&g.Oy(e)&&g.Sp(h[4],e);return!!h.length&&h[0]==P&&h[1]==v&&h[2]==l&&(z||m)})}; g.bZ=function(P,v,l,e){e=e===void 0?{}:e;if(!P||!P.addEventListener&&!P.attachEvent)return"";var h=OTW(P,v,l,e);if(h)return h;h=++osq.count+"";var z=!(v!="mouseenter"&&v!="mouseleave"||!P.addEventListener||"onmouseenter"in document);var m=z?function(Q){Q=new AB(Q);if(!yc(Q.relatedTarget,function(t){return t==P},!0))return Q.currentTarget=P,Q.type=v,l.call(P,Q)}:function(Q){Q=new AB(Q); Q.currentTarget=P;return l.call(P,Q)}; m=g.mV(m);P.addEventListener?(v=="mouseenter"&&z?v="mouseover":v=="mouseleave"&&z?v="mouseout":v=="mousewheel"&&"MozBoxSizing"in document.documentElement.style&&(v="MozMousePixelScroll"),sjD()||typeof e==="boolean"?P.addEventListener(v,m,e):P.addEventListener(v,m,!!e.capture)):P.attachEvent("on"+v,m);Yd[h]=[P,v,l,m,e];return h}; MFD=function(P){return ra9(P,function(v){return g.gt(v,"ytp-ad-has-logging-urls")})}; ra9=function(P,v){var l=document.body||document;return g.bZ(l,"click",function(e){var h=yc(e.target,function(z){return z===l||v(z)},!0); h&&h!==l&&!h.disabled&&(e.currentTarget=h,P.call(h,e))})}; g.xd=function(P){P&&(typeof P=="string"&&(P=[P]),g.f$(P,function(v){if(v in Yd){var l=Yd[v],e=l[0],h=l[1],z=l[3];l=l[4];e.removeEventListener?sjD()||typeof l==="boolean"?e.removeEventListener(h,z,l):e.removeEventListener(h,z,!!l.capture):e.detachEvent&&e.detachEvent("on"+h,z);delete Yd[v]}}))}; pk=function(P){for(var v in Yd)Yd[v][0]==P&&g.xd(v)}; Lk=function(P){P=P||window.event;var v;P.composedPath&&typeof P.composedPath==="function"?v=P.composedPath():v=P.path;v&&v.length?P=v[0]:(P=P||window.event,P=P.target||P.srcElement,P.nodeType==3&&(P=P.parentNode));return P}; SB=function(P){this.j=P;this.W=null;this.Y=0;this.T=null;this.Z=0;this.K=[];for(P=0;P<4;P++)this.K.push(0);this.G=0;this.QW=g.bZ(window,"mousemove",(0,g.ru)(this.X,this));this.S=g.cM((0,g.ru)(this.Wg,this),25)}; GT=function(P){g.U.call(this);this.j=[];this.nI=P||this}; Xz=function(P,v,l,e){for(var h=0;h 0?l:0;l=e?Date.now()+e*1E3:0;if((e=e?(0,g.UY)():Zd())&&window.JSON){typeof v!=="string"&&(v=JSON.stringify(v,void 0));try{e.set(P,v,l)}catch(h){e.remove(P)}}}; g.au=function(P){var v=Zd(),l=(0,g.UY)();if(!v&&!l||!window.JSON)return null;try{var e=v.get(P)}catch(h){}if(typeof e!=="string")try{e=l.get(P)}catch(h){}if(typeof e!=="string")return null;try{e=JSON.parse(e,void 0)}catch(h){}return e}; d7D=function(){var P=(0,g.UY)();if(P&&(P=P.K("yt-player-quality")))return P.creation}; g.Hx=function(P){try{var v=Zd(),l=(0,g.UY)();v&&v.remove(P);l&&l.remove(P)}catch(e){}}; g.EY=function(){return g.au("yt-remote-session-screen-id")}; P$7=function(P){var v=this;this.K=void 0;this.W=!1;P.addEventListener("beforeinstallprompt",function(l){l.preventDefault();v.K=l}); P.addEventListener("appinstalled",function(){v.W=!0},{once:!0})}; Wx=function(){if(!g.Uy.matchMedia)return"WEB_DISPLAY_MODE_UNKNOWN";try{return g.Uy.matchMedia("(display-mode: standalone)").matches?"WEB_DISPLAY_MODE_STANDALONE":g.Uy.matchMedia("(display-mode: minimal-ui)").matches?"WEB_DISPLAY_MODE_MINIMAL_UI":g.Uy.matchMedia("(display-mode: fullscreen)").matches?"WEB_DISPLAY_MODE_FULLSCREEN":g.Uy.matchMedia("(display-mode: browser)").matches?"WEB_DISPLAY_MODE_BROWSER":"WEB_DISPLAY_MODE_UNKNOWN"}catch(P){return"WEB_DISPLAY_MODE_UNKNOWN"}}; OY=function(){this.Zl=!0}; vky=function(){OY.instance||(OY.instance=new OY);return OY.instance}; lEW=function(P){switch(P){case "DESKTOP":return 1;case "UNKNOWN_PLATFORM":return 0;case "TV":return 2;case "GAME_CONSOLE":return 3;case "MOBILE":return 4;case "TABLET":return 5}}; ee7=function(){this.W=g.la("ALT_PREF_COOKIE_NAME","PREF");this.K=g.la("ALT_PREF_COOKIE_DOMAIN","youtube.com");var P=g.WM(this.W);P&&this.parse(P)}; g.sY=function(){ou||(ou=new ee7);return ou}; g.rD=function(P,v){return!!((he7("f"+(Math.floor(v/31)+1))||0)&1< 0;)switch(P=IG.shift(),P.type){case "ERROR":gn.yG(P.payload);break;case "EVENT":gn.logEvent(P.eventType,P.payload)}}; nR=function(P){D0||(gn?gn.yG(P):(IG.push({type:"ERROR",payload:P}),IG.length>10&&IG.shift()))}; N4=function(P,v){D0||(gn?gn.logEvent(P,v):(IG.push({type:"EVENT",eventType:P,payload:v}),IG.length>10&&IG.shift()))}; JP=function(P){if(P.indexOf(":")>=0)throw Error("Database name cannot contain ':'");}; uH=function(P){return P.substr(0,P.indexOf(":"))||P}; g.KR=function(P,v,l,e,h){v=v===void 0?{}:v;l=l===void 0?fED[P]:l;e=e===void 0?gk6[P]:e;h=h===void 0?klW[P]:h;g.Ph.call(this,l,Object.assign({},{name:"YtIdbKnownError",isSw:self.document===void 0,isIframe:self!==self.top,type:P},v));this.type=P;this.message=l;this.level=e;this.W=h;Object.setPrototypeOf(this,g.KR.prototype)}; ch=function(P,v){g.KR.call(this,"MISSING_OBJECT_STORES",{expectedObjectStores:v,foundObjectStores:P},fED.MISSING_OBJECT_STORES);Object.setPrototypeOf(this,ch.prototype)}; q4=function(P,v){var l=Error.call(this);this.message=l.message;"stack"in l&&(this.stack=l.stack);this.index=P;this.objectStore=v;Object.setPrototypeOf(this,q4.prototype)}; AP=function(P,v,l,e){v=uH(v);var h=P instanceof Error?P:Error("Unexpected error: "+P);if(h instanceof g.KR)return h;P={objectStoreNames:l,dbName:v,dbVersion:e};if(h.name==="QuotaExceededError")return new g.KR("QUOTA_EXCEEDED",P);if(g.FA&&h.name==="UnknownError")return new g.KR("QUOTA_MAYBE_EXCEEDED",P);if(h instanceof q4)return new g.KR("MISSING_INDEX",Object.assign({},P,{objectStore:h.objectStore,index:h.index}));if(h.name==="InvalidStateError"&&w7u.some(function(z){return h.message.includes(z)}))return new g.KR("EXECUTE_TRANSACTION_ON_CLOSED_DB", P); if(h.name==="AbortError")return new g.KR("UNKNOWN_ABORT",P,h.message);h.args=[Object.assign({},P,{name:"IdbError",zH:h.name})];h.level="WARNING";return h}; g.Y6=function(P,v,l){var e=fR();return new g.KR("IDB_NOT_SUPPORTED",{context:{caller:P,publicName:v,version:l,hasSucceededOnce:e==null?void 0:e.hasSucceededOnce}})}; $Fa=function(P){if(!P)throw Error();throw P;}; IE6=function(P){return P}; bH=function(P){this.W=P}; g.x6=function(P){function v(h){if(e.state.status==="PENDING"){e.state={status:"REJECTED",reason:h};h=g.N(e.K);for(var z=h.next();!z.done;z=h.next())z=z.value,z()}} function l(h){if(e.state.status==="PENDING"){e.state={status:"FULFILLED",value:h};h=g.N(e.W);for(var z=h.next();!z.done;z=h.next())z=z.value,z()}} var e=this;this.state={status:"PENDING"};this.W=[];this.K=[];P=P.W;try{P(l,v)}catch(h){v(h)}}; DFD=function(P,v,l,e,h){try{if(P.state.status!=="FULFILLED")throw Error("calling handleResolve before the promise is fulfilled.");var z=l(P.state.value);z instanceof g.x6?pR(P,v,z,e,h):e(z)}catch(m){h(m)}}; nku=function(P,v,l,e,h){try{if(P.state.status!=="REJECTED")throw Error("calling handleReject before the promise is rejected.");var z=l(P.state.reason);z instanceof g.x6?pR(P,v,z,e,h):e(z)}catch(m){h(m)}}; pR=function(P,v,l,e,h){v===l?h(new TypeError("Circular promise chain detected.")):l.then(function(z){z instanceof g.x6?pR(P,v,z,e,h):e(z)},function(z){h(z)})}; Nt6=function(P,v,l){function e(){l(P.error);z()} function h(){v(P.result);z()} function z(){try{P.removeEventListener("success",h),P.removeEventListener("error",e)}catch(m){}} P.addEventListener("success",h);P.addEventListener("error",e)}; J8w=function(P){return new Promise(function(v,l){Nt6(P,v,l)})}; LR=function(P){return new g.x6(new bH(function(v,l){Nt6(P,v,l)}))}; SY=function(P,v){return new g.x6(new bH(function(l,e){function h(){var z=P?v(P):null;z?z.then(function(m){P=m;h()},e):l()} h()}))}; u3D=function(P,v){this.request=P;this.cursor=v}; KrW=function(P){return LR(P).then(function(v){return v?new u3D(P,v):null})}; g.c8D=function(P){P.cursor.continue(void 0);return KrW(P.request)}; q7W=function(P,v){this.W=P;this.options=v;this.transactionCount=0;this.G=Math.round((0,g.Gz)());this.K=!1}; g.Bh=function(P,v,l){P=P.W.createObjectStore(v,l);return new XA(P)}; iH=function(P,v){P.W.objectStoreNames.contains(v)&&P.W.deleteObjectStore(v)}; g.jY=function(P,v,l){return g.UP(P,[v],{mode:"readwrite",V7:!0},function(e){return g.Z0(e.objectStore(v),l)})}; g.UP=function(P,v,l,e){var h,z,m,Q,t,y,C,f,k,w,I,J;return g.p(function(K){switch(K.W){case 1:var q={mode:"readonly",V7:!1,tag:"IDB_TRANSACTION_TAG_UNKNOWN"};typeof l==="string"?q.mode=l:Object.assign(q,l);h=q;P.transactionCount++;z=h.V7?3:1;m=0;case 2:if(Q){K.ac(4);break}m++;t=Math.round((0,g.Gz)());g.NP(K,5);y=P.W.transaction(v,h.mode);q=new aG(y);q=Fr6(q,e);return g.b(K,q,7);case 7:return C=K.K,f=Math.round((0,g.Gz)()),A89(P,t,f,m,void 0,v.join(),h),K.return(C);case 5:k=g.Kx(K);w=Math.round((0,g.Gz)()); I=AP(k,P.W.name,v.join(),P.W.version);if((J=I instanceof g.KR&&!I.W)||m>=z)A89(P,t,w,m,I,v.join(),h),Q=I;K.ac(2);break;case 4:return K.return(Promise.reject(Q))}})}; A89=function(P,v,l,e,h,z,m){v=l-v;h?(h instanceof g.KR&&(h.type==="QUOTA_EXCEEDED"||h.type==="QUOTA_MAYBE_EXCEEDED")&&N4("QUOTA_EXCEEDED",{dbName:uH(P.W.name),objectStoreNames:z,transactionCount:P.transactionCount,transactionMode:m.mode}),h instanceof g.KR&&h.type==="UNKNOWN_ABORT"&&(l-=P.G,l<0&&l>=2147483648&&(l=0),N4("TRANSACTION_UNEXPECTEDLY_ABORTED",{objectStoreNames:z,transactionDuration:v,transactionCount:P.transactionCount,dbDuration:l}),P.K=!0),Y7P(P,!1,e,z,v,m.tag),nR(h)):Y7P(P,!0,e,z,v, m.tag)}; Y7P=function(P,v,l,e,h,z){N4("TRANSACTION_ENDED",{objectStoreNames:e,connectionHasUnknownAbortedTransaction:P.K,duration:h,isSuccessful:v,tryCount:l,tag:z===void 0?"IDB_TRANSACTION_TAG_UNKNOWN":z})}; XA=function(P){this.W=P}; g.Hh=function(P,v,l){P.W.createIndex(v,l,{unique:!1})}; bzx=function(P,v){return g.EP(P,{query:v},function(l){return l.delete().then(function(){return g.Wh(l)})}).then(function(){})}; xFD=function(P,v,l){var e=[];return g.EP(P,{query:v},function(h){if(!(l!==void 0&&e.length>=l))return e.push(h.getValue()),g.Wh(h)}).then(function(){return e})}; LrB=function(P){return"getAllKeys"in IDBObjectStore.prototype?LR(P.W.getAllKeys(void 0,void 0)):p7a(P)}; p7a=function(P){var v=[];return g.S7w(P,{query:void 0},function(l){v.push(l.cursor.primaryKey);return g.c8D(l)}).then(function(){return v})}; g.Z0=function(P,v,l){return LR(P.W.put(v,l))}; g.EP=function(P,v,l){P=P.W.openCursor(v.query,v.direction);return OP(P).then(function(e){return SY(e,l)})}; g.S7w=function(P,v,l){var e=v.query;v=v.direction;P="openKeyCursor"in IDBObjectStore.prototype?P.W.openKeyCursor(e,v):P.W.openCursor(e,v);return KrW(P).then(function(h){return SY(h,l)})}; aG=function(P){var v=this;this.W=P;this.G=new Map;this.K=!1;this.done=new Promise(function(l,e){v.W.addEventListener("complete",function(){l()}); v.W.addEventListener("error",function(h){h.currentTarget===h.target&&e(v.W.error)}); v.W.addEventListener("abort",function(){var h=v.W.error;if(h)e(h);else if(!v.K){h=g.KR;for(var z=v.W.objectStoreNames,m=[],Q=0;Q =l))return e.push(h.getValue()),g.Wh(h)}).then(function(){return e})}; g.oG=function(P,v,l){P=P.W.openCursor(v.query===void 0?null:v.query,v.direction===void 0?"next":v.direction);return OP(P).then(function(e){return SY(e,l)})}; sP=function(P,v){this.request=P;this.cursor=v}; OP=function(P){return LR(P).then(function(v){return v?new sP(P,v):null})}; g.Wh=function(P){P.cursor.continue(void 0);return OP(P.request)}; BtP=function(P,v,l){return new Promise(function(e,h){function z(){k||(k=new q7W(m.result,{closed:f}));return k} var m=v!==void 0?self.indexedDB.open(P,v):self.indexedDB.open(P);var Q=l.blocked,t=l.blocking,y=l.cQJ,C=l.upgrade,f=l.closed,k;m.addEventListener("upgradeneeded",function(w){try{if(w.newVersion===null)throw Error("Invariant: newVersion on IDbVersionChangeEvent is null");if(m.transaction===null)throw Error("Invariant: transaction on IDbOpenDbRequest is null");w.dataLoss&&w.dataLoss!=="none"&&N4("IDB_DATA_CORRUPTED",{reason:w.dataLossMessage||"unknown reason",dbName:uH(P)});var I=z(),J=new aG(m.transaction); C&&C(I,function(K){return w.oldVersion =K},J); J.done.catch(function(K){h(K)})}catch(K){h(K)}}); m.addEventListener("success",function(){var w=m.result;t&&w.addEventListener("versionchange",function(){t(z())}); w.addEventListener("close",function(){N4("IDB_UNEXPECTEDLY_CLOSED",{dbName:uH(P),dbVersion:w.version});y&&y()}); e(z())}); m.addEventListener("error",function(){h(m.error)}); Q&&m.addEventListener("blocked",function(){Q()})})}; izD=function(P,v,l){l=l===void 0?{}:l;return BtP(P,v,l)}; rn=function(P,v){v=v===void 0?{}:v;var l,e,h,z;return g.p(function(m){if(m.W==1)return g.NP(m,2),l=self.indexedDB.deleteDatabase(P),e=v,(h=e.blocked)&&l.addEventListener("blocked",function(){h()}),g.b(m,J8w(l),4); if(m.W!=2)return g.uD(m,0);z=g.Kx(m);throw AP(z,P,"",-1);})}; M4=function(P,v){this.name=P;this.options=v;this.G=!0;this.Z=this.Y=0}; UF2=function(P,v){return new g.KR("INCOMPATIBLE_DB_VERSION",{dbName:P.name,oldVersion:P.options.version,newVersion:v})}; g.Tz=function(P,v){if(!v)throw g.Y6("openWithToken",uH(P.name));return P.open()}; ZzP=function(P,v){var l;return g.p(function(e){if(e.W==1)return g.b(e,g.Tz(V8,v),2);l=e.K;return e.return(g.UP(l,["databases"],{V7:!0,mode:"readwrite"},function(h){var z=h.objectStore("databases");return z.get(P.actualName).then(function(m){if(m?P.actualName!==m.actualName||P.publicName!==m.publicName||P.userIdentifier!==m.userIdentifier:1)return g.Z0(z,P).then(function(){})})}))})}; dn=function(P,v){var l;return g.p(function(e){if(e.W==1)return P?g.b(e,g.Tz(V8,v),2):e.return();l=e.K;return e.return(l.delete("databases",P))})}; jX7=function(P,v){var l,e;return g.p(function(h){return h.W==1?(l=[],g.b(h,g.Tz(V8,v),2)):h.W!=3?(e=h.K,g.b(h,g.UP(e,["databases"],{V7:!0,mode:"readonly"},function(z){l.length=0;return g.EP(z.objectStore("databases"),{},function(m){P(m.getValue())&&l.push(m.getValue());return g.Wh(m)})}),3)):h.return(l)})}; aEy=function(P,v){return jX7(function(l){return l.publicName===P&&l.userIdentifier!==void 0},v)}; Hzq=function(){var P,v,l,e;return g.p(function(h){switch(h.W){case 1:P=fR();if((v=P)==null?0:v.hasSucceededOnce)return h.return(!0);if(Ps&&vx()&&!lZ()||g.vs)return h.return(!1);try{if(l=self,!(l.indexedDB&&l.IDBIndex&&l.IDBKeyRange&&l.IDBObjectStore))return h.return(!1)}catch(z){return h.return(!1)}if(!("IDBTransaction"in self&&"objectStoreNames"in IDBTransaction.prototype))return h.return(!1);g.NP(h,2);e={actualName:"yt-idb-test-do-not-use",publicName:"yt-idb-test-do-not-use",userIdentifier:void 0}; return g.b(h,ZzP(e,lX),4);case 4:return g.b(h,dn("yt-idb-test-do-not-use",lX),5);case 5:return h.return(!0);case 2:return g.Kx(h),h.return(!1)}})}; Ekx=function(){if(el!==void 0)return el;D0=!0;return el=Hzq().then(function(P){D0=!1;var v;if((v=CR())!=null&&v.W){var l;v={hasSucceededOnce:((l=fR())==null?void 0:l.hasSucceededOnce)||P};var e;(e=CR())==null||e.set("LAST_RESULT_ENTRY_KEY",v,2592E3,!0)}return P})}; h6=function(){return g.j9("ytglobal.idbToken_")||void 0}; g.zJ=function(){var P=h6();return P?Promise.resolve(P):Ekx().then(function(v){(v=v?lX:void 0)&&g.ZB("ytglobal.idbToken_",v);return v})}; Wr2=function(P){if(!g.lH())throw P=new g.KR("AUTH_INVALID",{dbName:P}),nR(P),P;var v=g.vh();return{actualName:P+":"+v,publicName:P,userIdentifier:v}}; Ozq=function(P,v,l,e){var h,z,m,Q,t,y;return g.p(function(C){switch(C.W){case 1:return z=(h=Error().stack)!=null?h:"",g.b(C,g.zJ(),2);case 2:m=C.K;if(!m)throw Q=g.Y6("openDbImpl",P,v),g.YN("ytidb_async_stack_killswitch")||(Q.stack=Q.stack+"\n"+z.substring(z.indexOf("\n")+1)),nR(Q),Q;JP(P);t=l?{actualName:P,publicName:P,userIdentifier:void 0}:Wr2(P);g.NP(C,3);return g.b(C,ZzP(t,m),5);case 5:return g.b(C,izD(t.actualName,v,e),6);case 6:return C.return(C.K);case 3:return y=g.Kx(C),g.NP(C,7),g.b(C,dn(t.actualName, m),9);case 9:g.uD(C,8);break;case 7:g.Kx(C);case 8:throw y;}})}; oka=function(P,v,l){l=l===void 0?{}:l;return Ozq(P,v,!1,l)}; sXy=function(P,v,l){l=l===void 0?{}:l;return Ozq(P,v,!0,l)}; r8x=function(P,v){v=v===void 0?{}:v;var l,e;return g.p(function(h){if(h.W==1)return g.b(h,g.zJ(),2);if(h.W!=3){l=h.K;if(!l)return h.return();JP(P);e=Wr2(P);return g.b(h,rn(e.actualName,v),3)}return g.b(h,dn(e.actualName,l),0)})}; Mdw=function(P,v,l){P=P.map(function(e){return g.p(function(h){return h.W==1?g.b(h,rn(e.actualName,v),2):g.b(h,dn(e.actualName,l),0)})}); return Promise.all(P).then(function(){})}; Ttq=function(P){var v=v===void 0?{}:v;var l,e;return g.p(function(h){if(h.W==1)return g.b(h,g.zJ(),2);if(h.W!=3){l=h.K;if(!l)return h.return();JP(P);return g.b(h,aEy(P,l),3)}e=h.K;return g.b(h,Mdw(e,v,l),0)})}; Vdx=function(P,v){v=v===void 0?{}:v;var l;return g.p(function(e){if(e.W==1)return g.b(e,g.zJ(),2);if(e.W!=3){l=e.K;if(!l)return e.return();JP(P);return g.b(e,rn(P,v),3)}return g.b(e,dn(P,l),0)})}; mI=function(P,v){M4.call(this,P,v);this.options=v;JP(P)}; dFw=function(P,v){var l;return function(){l||(l=new mI(P,v));return l}}; g.RO=function(P,v){return dFw(P,v)}; QR=function(P){return g.Tz(POx(),P)}; vIW=function(P,v,l,e){var h,z,m;return g.p(function(Q){switch(Q.W){case 1:return h={config:P,hashData:v,timestamp:e!==void 0?e:(0,g.Gz)()},g.b(Q,QR(l),2);case 2:return z=Q.K,g.b(Q,z.clear("hotConfigStore"),3);case 3:return g.b(Q,g.jY(z,"hotConfigStore",h),4);case 4:return m=Q.K,Q.return(m)}})}; leD=function(P,v,l,e,h){var z,m,Q;return g.p(function(t){switch(t.W){case 1:return z={config:P,hashData:v,configData:l,timestamp:h!==void 0?h:(0,g.Gz)()},g.b(t,QR(e),2);case 2:return m=t.K,g.b(t,m.clear("coldConfigStore"),3);case 3:return g.b(t,g.jY(m,"coldConfigStore",z),4);case 4:return Q=t.K,t.return(Q)}})}; elw=function(P){var v,l;return g.p(function(e){return e.W==1?g.b(e,QR(P),2):e.W!=3?(v=e.K,l=void 0,g.b(e,g.UP(v,["coldConfigStore"],{mode:"readwrite",V7:!0},function(h){return g.oG(h.objectStore("coldConfigStore").index("coldTimestampIndex"),{direction:"prev"},function(z){l=z.getValue()})}),3)):e.return(l)})}; hlq=function(P){var v,l;return g.p(function(e){return e.W==1?g.b(e,QR(P),2):e.W!=3?(v=e.K,l=void 0,g.b(e,g.UP(v,["hotConfigStore"],{mode:"readwrite",V7:!0},function(h){return g.oG(h.objectStore("hotConfigStore").index("hotTimestampIndex"),{direction:"prev"},function(z){l=z.getValue()})}),3)):e.return(l)})}; zlu=function(){return g.p(function(P){return g.b(P,Ttq("ytGcfConfig"),0)})}; t6=function(){g.U.call(this);this.K=[];this.W=[];var P=g.j9("yt.gcf.config.hotUpdateCallbacks");P?(this.K=[].concat(g.u(P)),this.W=P):(this.W=[],g.ZB("yt.gcf.config.hotUpdateCallbacks",this.W))}; wW=function(){var P=this;this.Z=!1;this.G=this.Y=0;this.T=new t6;this.Kh={XIg:function(){P.Z=!0}, FYc:function(){return P.W}, f$M:function(v){yR(P,v)}, kE:function(v){P.kE(v)}, UJ5:function(v){C9(P,v)}, MU:function(){return P.coldHashData}, Jr:function(){return P.hotHashData}, kI0:function(){return P.K}, Yd$:function(){return f9()}, JP6:function(){return gW()}, LJ6:function(){return g.j9("yt.gcf.config.coldHashData")}, Ze$:function(){return g.j9("yt.gcf.config.hotHashData")}, zUJ:function(){mWw(P)}, elW:function(){P.kE(void 0);kz(P);delete wW.instance}, gE$:function(v){P.G=v}, WJc:function(){return P.G}}}; Rlq=function(){if(!wW.instance){var P=new wW;wW.instance=P}return wW.instance}; yr2=function(P){var v;g.p(function(l){if(l.W==1)return g.YN("start_client_gcf")||g.YN("delete_gcf_config_db")?g.YN("start_client_gcf")?g.b(l,g.zJ(),3):l.ac(2):l.return();l.W!=2&&((v=l.K)&&g.lH()&&!g.YN("delete_gcf_config_db")?(P.Z=!0,mWw(P)):(QT2(P),tSa(P)));return g.YN("delete_gcf_config_db")?g.b(l,zlu(),0):l.ac(0)})}; $z=function(){var P;return(P=gW())!=null?P:g.la("RAW_HOT_CONFIG_GROUP")}; COw=function(P){var v,l,e,h,z,m;return g.p(function(Q){switch(Q.W){case 1:if(P.K)return Q.return(gW());if(!P.Z)return v=g.Y6("getHotConfig IDB not initialized"),RZ(v),Q.return(Promise.reject(v));l=h6();e=g.la("TIME_CREATED_MS");if(!l){h=g.Y6("getHotConfig token error");RZ(h);Q.ac(2);break}return g.b(Q,hlq(l),3);case 3:if((z=Q.K)&&z.timestamp>e)return yR(P,z.config),P.kE(z.hashData),Q.return(gW());case 2:tSa(P);if(!(l&&P.K&&P.hotHashData)){Q.ac(4);break}return g.b(Q,vIW(P.K,P.hotHashData,l,e),4);case 4:return P.K? Q.return(gW()):(m=new g.Ph("Config not available in ytConfig"),RZ(m),Q.return(Promise.reject(m)))}})}; gIa=function(P){var v,l,e,h,z,m;return g.p(function(Q){switch(Q.W){case 1:if(P.W)return Q.return(f9());if(!P.Z)return v=g.Y6("getColdConfig IDB not initialized"),RZ(v),Q.return(Promise.reject(v));l=h6();e=g.la("TIME_CREATED_MS");if(!l){h=g.Y6("getColdConfig");RZ(h);Q.ac(2);break}return g.b(Q,elw(l),3);case 3:if((z=Q.K)&&z.timestamp>e)return C9(P,z.config),feW(P,z.configData),kz(P,z.hashData),Q.return(f9());case 2:QT2(P);if(!(l&&P.W&&P.coldHashData&&P.configData)){Q.ac(4);break}return g.b(Q,leD(P.W, P.coldHashData,P.configData,l,e),4);case 4:return P.W?Q.return(f9()):(m=new g.Ph("Config not available in ytConfig"),RZ(m),Q.return(Promise.reject(m)))}})}; mWw=function(P){if(!P.K||!P.W){if(!h6()){var v=g.Y6("scheduleGetConfigs");RZ(v)}P.Y||(P.Y=g.dj.VG(function(){return g.p(function(l){switch(l.W){case 1:return g.NP(l,2),g.b(l,COw(P),4);case 4:g.uD(l,3);break;case 2:g.Kx(l);case 3:return g.NP(l,5),g.b(l,gIa(P),7);case 7:g.uD(l,6);break;case 5:g.Kx(l);case 6:P.Y&&(P.Y=0),g.nx(l)}})},100))}}; kou=function(P,v,l){var e,h,z;return g.p(function(m){switch(m.W){case 1:if(!g.YN("start_client_gcf")){m.ac(0);break}l&&yR(P,l);P.kE(v);e=h6();if(!e){m.ac(3);break}if(l){m.ac(4);break}return g.b(m,hlq(e),5);case 5:h=m.K,l=(z=h)==null?void 0:z.config;case 4:return g.b(m,vIW(l,v,e),3);case 3:if(l)for(var Q=l,t=g.N(P.T.W),y=t.next();!y.done;y=t.next())y=y.value,y(Q);g.nx(m)}})}; w0W=function(P,v,l){var e,h,z,m;return g.p(function(Q){if(Q.W==1){if(!g.YN("start_client_gcf"))return Q.ac(0);kz(P,v);return(e=h6())?l?Q.ac(4):g.b(Q,elw(e),5):Q.ac(0)}Q.W!=4&&(h=Q.K,l=(z=h)==null?void 0:z.config);if(!l)return Q.ac(0);m=l.configData;return g.b(Q,leD(l,v,m,e),0)})}; $WB=function(){var P=Rlq(),v=(0,g.Gz)()-P.G;if(!(P.G!==0&&v 0&&(v.request={internalExperimentFlags:l});DWW(P,void 0,v);nI9(void 0,v);N_2(void 0,v);Jry(P,void 0,v);u7x(void 0,v);g.YN("start_client_gcf")&&K7P(void 0,v);g.la("DELEGATED_SESSION_ID")&& !g.YN("pageid_as_header_web")&&(v.user={onBehalfOfUser:g.la("DELEGATED_SESSION_ID")});!g.YN("fill_delegate_context_in_gel_killswitch")&&(P=g.la("INNERTUBE_CONTEXT_SERIALIZED_DELEGATION_CONTEXT"))&&(v.user=Object.assign({},v.user,{serializedDelegationContext:P}));P=g.la("INNERTUBE_CONTEXT");var e;if(g.YN("enable_persistent_device_token")&&(P==null?0:(e=P.client)==null?0:e.rolloutToken)){var h;v.client.rolloutToken=P==null?void 0:(h=P.client)==null?void 0:h.rolloutToken}e=Object;h=e.assign;P=v.client; l={};for(var z=g.N(Object.entries(yS(g.la("DEVICE","")))),m=z.next();!m.done;m=z.next()){var Q=g.N(m.value);m=Q.next().value;Q=Q.next().value;m==="cbrand"?l.deviceMake=Q:m==="cmodel"?l.deviceModel=Q:m==="cbr"?l.browserName=Q:m==="cbrver"?l.browserVersion=Q:m==="cos"?l.osName=Q:m==="cosver"?l.osVersion=Q:m==="cplatform"&&(l.platform=Q)}v.client=h.call(e,P,l);return v}; DWW=function(P,v,l){P=P.OB;if(P==="WEB"||P==="MWEB"||P===1||P===2)if(v){l=zn(v,B0,96)||new B0;var e=Wx();e=Object.keys(cr2).indexOf(e);e=e===-1?null:e;e!==null&&IY(l,3,e);mT(v,B0,96,l)}else l&&(l.client.mainAppWebInfo=(e=l.client.mainAppWebInfo)!=null?e:{},l.client.mainAppWebInfo.webDisplayMode=Wx())}; nI9=function(P,v){var l=g.j9("yt.embedded_player.embed_url");l&&(P?(v=zn(P,aT,7)||new aT,wi(v,4,l),mT(P,aT,7,v)):v&&(v.thirdParty={embedUrl:l}))}; N_2=function(P,v){var l;if(g.YN("web_log_memory_total_kbytes")&&((l=g.Uy.navigator)==null?0:l.deviceMemory)){var e;l=(e=g.Uy.navigator)==null?void 0:e.deviceMemory;P?Ul(P,95,JQ(l*1E6)):v&&(v.client.memoryTotalKbytes=""+l*1E6)}}; Jry=function(P,v,l){if(P.appInstallData)if(v){var e;l=(e=zn(v,X7,62))!=null?e:new X7;wi(l,6,P.appInstallData);mT(v,X7,62,l)}else l&&(l.client.configInfo=l.client.configInfo||{},l.client.configInfo.appInstallData=P.appInstallData)}; u7x=function(P,v){var l=Re2();l&&(P?IY(P,61,q5B[l]):v&&(v.client.connectionType=l));g.YN("web_log_effective_connection_type")&&(l=tdw())&&(P?IY(P,94,F7P[l]):v&&(v.client.effectiveConnectionType=l))}; ArW=function(P,v,l){l=l===void 0?{}:l;var e={};g.la("EOM_VISITOR_DATA")?e={"X-Goog-EOM-Visitor-Id":g.la("EOM_VISITOR_DATA")}:e={"X-Goog-Visitor-Id":l.visitorData||g.la("VISITOR_DATA","")};if(v&&v.includes("www.youtube-nocookie.com"))return e;v=l.gp||g.la("AUTHORIZATION");v||(P?v="Bearer "+g.j9("gapi.auth.getToken")().access_token:(P=vky().W8(n9),g.YN("pageid_as_header_web")||delete P["X-Goog-PageId"],e=Object.assign({},e,P)));v&&(e.Authorization=v);return e}; K7P=function(P,v){var l=$WB();if(l){var e=l.coldConfigData,h=l.coldHashData;l=l.hotHashData;if(P){var z;v=(z=zn(P,X7,62))!=null?z:new X7;e=wi(v,1,e);wi(e,3,h).kE(l);mT(P,X7,62,v)}else v&&(v.client.configInfo=v.client.configInfo||{},e&&(v.client.configInfo.coldConfigData=e),h&&(v.client.configInfo.coldHashData=h),l&&(v.client.configInfo.hotHashData=l))}}; NI=function(P,v){this.version=P;this.args=v}; qI=function(P,v){this.topic=P;this.W=v}; A6=function(P,v){var l=FU();l&&l.publish.call(l,P.toString(),P,v)}; xWP=function(P){var v=Y5w,l=FU();if(!l)return 0;var e=l.subscribe(v.toString(),function(h,z){var m=g.j9("ytPubsub2Pubsub2SkipSubKey");m&&m==e||(m=function(){if(Yz[e])try{if(z&&v instanceof qI&&v!=h)try{var Q=v.W,t=z;if(!t.args||!t.version)throw Error("yt.pubsub2.Data.deserialize(): serializedData is incomplete.");try{if(!Q.XP){var y=new Q;Q.XP=y.version}var C=Q.XP}catch(f){}if(!C||t.version!=C)throw Error("yt.pubsub2.Data.deserialize(): serializedData version is incompatible.");try{z=Reflect.construct(Q, g.vZ(t.args))}catch(f){throw f.message="yt.pubsub2.Data.deserialize(): "+f.message,f;}}catch(f){throw f.message="yt.pubsub2.pubsub2 cross-binary conversion error for "+v.toString()+": "+f.message,f;}P.call(window,z)}catch(f){g.z_(f)}},bKw[v.toString()]?g.Q8()?g.dj.VG(m):g.KG(m,0):m())}); Yz[e]=!0;bX[v.toString()]||(bX[v.toString()]=[]);bX[v.toString()].push(e);return e}; S5a=function(){var P=p0W,v=xWP(function(l){P.apply(void 0,arguments);L7q(v)}); return v}; L7q=function(P){var v=FU();v&&(typeof P==="number"&&(P=[P]),g.f$(P,function(l){v.unsubscribeByKey(l);delete Yz[l]}))}; FU=function(){return g.j9("ytPubsub2Pubsub2Instance")}; xz=function(P,v,l){l=l===void 0?{sampleRate:.1}:l;Math.random() ZKw||m =EIy&&(jl++,g.YN("abandon_compression_after_N_slow_zips")?Zs===g.ba("compression_disable_point")&&jl>W79&&(Bs=!1):Bs=!1);OKx(v);e.headers||(e.headers={});e.headers["Content-Encoding"]="gzip";e.postBody=P;e.postParams=void 0;h(l,e)}; oID=function(P){var v=v===void 0?!1:v;var l=l===void 0?!1:l;var e=(0,g.Gz)(),h={startTime:e,ticks:{},infos:{}},z=v?g.j9("yt.logging.gzipForFetch",!1):!0;if(Bs&&z){if(!P.body)return P;try{var m=l?P.body:typeof P.body==="string"?P.body:JSON.stringify(P.body);z=m;if(!l&&typeof m==="string"){var Q=UW2(m);if(Q!=null&&(Q>ZKw||Q =EIy)if(jl++,g.YN("abandon_compression_after_N_slow_zips")||g.YN("abandon_compression_after_N_slow_zips_lr")){v=jl/Zs;var y=W79/g.ba("compression_disable_point");Zs>0&&Zs%g.ba("compression_disable_point")===0&&v>=y&&(Bs=!1)}else Bs=!1;OKx(h)}}P.headers=Object.assign({},{"Content-Encoding":"gzip"},P.headers||{});P.body=z;return P}catch(C){return RZ(C),P}}else return P}; UW2=function(P){try{return(new Blob(P.split(""))).size}catch(v){return RZ(v),null}}; OKx=function(P){g.YN("gel_compression_csi_killswitch")||!g.YN("log_gel_compression_latency")&&!g.YN("log_gel_compression_latency_lr")||xz("gel_compression",P,{sampleRate:.1})}; Hs=function(P){var v=this;this.Ol=this.W=!1;this.potentialEsfErrorCounter=this.K=0;this.handleError=function(){}; this.kD=function(){}; this.now=Date.now;this.bF=!1;this.Kh={Fmc:function(C){v.qv=C}, wL2:function(){v.sE()}, tZ:function(){v.bb()}, Rf:function(C){return g.p(function(f){return g.b(f,v.Rf(C),0)})}, GM:function(C,f){return v.GM(C,f)}, J_:function(){v.J_()}}; var l;this.Ev=(l=P.Ev)!=null?l:100;var e;this.Pk=(e=P.Pk)!=null?e:1;var h;this.ED=(h=P.ED)!=null?h:2592E6;var z;this.Jd=(z=P.Jd)!=null?z:12E4;var m;this.mM=(m=P.mM)!=null?m:5E3;var Q;this.qv=(Q=P.qv)!=null?Q:void 0;this.qI=!!P.qI;var t;this.c$=(t=P.c$)!=null?t:.1;var y;this.Ri=(y=P.Ri)!=null?y:10;P.handleError&&(this.handleError=P.handleError);P.kD&&(this.kD=P.kD);P.bF&&(this.bF=P.bF);P.Ol&&(this.Ol=P.Ol);this.l$=P.l$;this.bE=P.bE;this.r7=P.r7;this.LJ=P.LJ;this.sendFn=P.sendFn;this.Q9=P.Q9;this.QV= P.QV;aO(this)&&(!this.l$||this.l$("networkless_logging"))&&sTW(this)}; sTW=function(P){aO(P)&&!P.bF&&(P.W=!0,P.qI&&Math.random()<=P.c$&&P.r7.nj(P.qv),P.J_(),P.LJ.GA()&&P.sE(),P.LJ.listen(P.Q9,P.sE.bind(P)),P.LJ.listen(P.QV,P.bb.bind(P)))}; T_7=function(P,v){if(!aO(P))throw Error("IndexedDB is not supported: updateRequestHandlers");var l=v.options.onError?v.options.onError:function(){}; v.options.onError=function(h,z){var m,Q,t,y;return g.p(function(C){switch(C.W){case 1:m=rrw(z);(Q=MS6(z))&&P.l$&&P.l$("web_enable_error_204")&&P.handleError(Error("Request failed due to compression"),v.url,z);if(!(P.l$&&P.l$("nwl_consider_error_code")&&m||P.l$&&!P.l$("nwl_consider_error_code")&&P.potentialEsfErrorCounter<=P.Ri)){C.ac(2);break}if(!P.LJ.Ez){C.ac(3);break}return g.b(C,P.LJ.Ez(),3);case 3:if(P.LJ.GA()){C.ac(2);break}l(h,z);if(!P.l$||!P.l$("nwl_consider_error_code")||((t=v)==null?void 0: t.id)===void 0){C.ac(6);break}return g.b(C,P.r7.dO(v.id,P.qv,!1),6);case 6:return C.return();case 2:if(P.l$&&P.l$("nwl_consider_error_code")&&!m&&P.potentialEsfErrorCounter>P.Ri)return C.return();P.potentialEsfErrorCounter++;if(((y=v)==null?void 0:y.id)===void 0){C.ac(8);break}return v.sendCount =400&&P<=599?!1:!0}; MS6=function(P){var v;P=P==null?void 0:(v=P.error)==null?void 0:v.code;return!(P!==400&&P!==415)}; VS2=function(){if(Ws)return Ws();var P={};Ws=g.RO("LogsDatabaseV2",{Sq:(P.LogsRequestsStore={OW:2},P),shared:!1,upgrade:function(v,l,e){l(2)&&g.Bh(v,"LogsRequestsStore",{keyPath:"id",autoIncrement:!0});l(3);l(5)&&(e=e.objectStore("LogsRequestsStore"),e.W.indexNames.contains("newRequest")&&e.W.deleteIndex("newRequest"),g.Hh(e,"newRequestV2",["status","interface","timestamp"]));l(7)&&iH(v,"sapisid");l(9)&&iH(v,"SWHealthLog")}, version:9});return Ws()}; Oh=function(P){return g.Tz(VS2(),P)}; PaD=function(P,v){var l,e,h,z;return g.p(function(m){if(m.W==1)return l={startTime:(0,g.Gz)(),infos:{transactionType:"YT_IDB_TRANSACTION_TYPE_WRITE"},ticks:{}},g.b(m,Oh(v),2);if(m.W!=3)return e=m.K,h=Object.assign({},P,{options:JSON.parse(JSON.stringify(P.options)),interface:g.la("INNERTUBE_CONTEXT_CLIENT_NAME",0)}),g.b(m,g.jY(e,"LogsRequestsStore",h),3);z=m.K;l.ticks.tc=(0,g.Gz)();dW6(l);return m.return(z)})}; vNx=function(P,v){var l,e,h,z,m,Q,t,y;return g.p(function(C){if(C.W==1)return l={startTime:(0,g.Gz)(),infos:{transactionType:"YT_IDB_TRANSACTION_TYPE_READ"},ticks:{}},g.b(C,Oh(v),2);if(C.W!=3)return e=C.K,h=g.la("INNERTUBE_CONTEXT_CLIENT_NAME",0),z=[P,h,0],m=[P,h,(0,g.Gz)()],Q=IDBKeyRange.bound(z,m),t="prev",g.YN("use_fifo_for_networkless")&&(t="next"),y=void 0,g.b(C,g.UP(e,["LogsRequestsStore"],{mode:"readwrite",V7:!0},function(f){return g.oG(f.objectStore("LogsRequestsStore").index("newRequestV2"), {query:Q,direction:t},function(k){k.getValue()&&(y=k.getValue(),P==="NEW"&&(y.status="QUEUED",k.update(y)))})}),3); l.ticks.tc=(0,g.Gz)();dW6(l);return C.return(y)})}; lpa=function(P,v){var l;return g.p(function(e){if(e.W==1)return g.b(e,Oh(v),2);l=e.K;return e.return(g.UP(l,["LogsRequestsStore"],{mode:"readwrite",V7:!0},function(h){var z=h.objectStore("LogsRequestsStore");return z.get(P).then(function(m){if(m)return m.status="QUEUED",g.Z0(z,m).then(function(){return m})})}))})}; eRw=function(P,v,l,e){l=l===void 0?!0:l;var h;return g.p(function(z){if(z.W==1)return g.b(z,Oh(v),2);h=z.K;return z.return(g.UP(h,["LogsRequestsStore"],{mode:"readwrite",V7:!0},function(m){var Q=m.objectStore("LogsRequestsStore");return Q.get(P).then(function(t){return t?(t.status="NEW",l&&(t.sendCount+=1),e!==void 0&&(t.options.compress=e),g.Z0(Q,t).then(function(){return t})):g.x6.resolve(void 0)})}))})}; hRw=function(P,v){var l;return g.p(function(e){if(e.W==1)return g.b(e,Oh(v),2);l=e.K;return e.return(l.delete("LogsRequestsStore",P))})}; zRa=function(P){var v,l;return g.p(function(e){if(e.W==1)return g.b(e,Oh(P),2);v=e.K;l=(0,g.Gz)()-2592E6;return g.b(e,g.UP(v,["LogsRequestsStore"],{mode:"readwrite",V7:!0},function(h){return g.EP(h.objectStore("LogsRequestsStore"),{},function(z){if(z.getValue().timestamp<=l)return z.delete().then(function(){return g.Wh(z)})})}),0)})}; mcu=function(){g.p(function(P){return g.b(P,Ttq("LogsDatabaseV2"),0)})}; dW6=function(P){g.YN("nwl_csi_killswitch")||xz("networkless_performance",P,{sampleRate:1})}; QZ2=function(P){return g.Tz(RRu(),P)}; tNw=function(P){var v,l;g.p(function(e){if(e.W==1)return g.b(e,QZ2(P),2);v=e.K;l=(0,g.Gz)()-2592E6;return g.b(e,g.UP(v,["SWHealthLog"],{mode:"readwrite",V7:!0},function(h){return g.EP(h.objectStore("SWHealthLog"),{},function(z){if(z.getValue().timestamp<=l)return z.delete().then(function(){return g.Wh(z)})})}),0)})}; yZ2=function(P){var v;return g.p(function(l){if(l.W==1)return g.b(l,QZ2(P),2);v=l.K;return g.b(l,v.clear("SWHealthLog"),0)})}; g.oO=function(P,v,l,e,h,z,m){h=h===void 0?"":h;z=z===void 0?!1:z;m=m===void 0?!1:m;if(P)if(l&&!g.VS())RZ(new g.Ph("Legacy referrer-scrubbed ping detected")),P&&Ca9(P,void 0,{scrubReferrer:!0});else if(h)LG(P,v,"POST",h,e);else if(g.la("USE_NET_AJAX_FOR_PING_TRANSPORT",!1)||e||m)LG(P,v,"GET","",e,void 0,z,m);else{b:{try{var Q=new MKw({url:P});if(Q.Z?typeof Q.G!=="string"||Q.G.length===0?0:{version:3,We:Q.G,JZ:GR(Q.W,"act=1","ri=1",Tsx(Q))}:Q.T&&{version:4,We:GR(Q.W,"dct=1","suid="+Q.Y,""),JZ:GR(Q.W, "act=1","ri=1","suid="+Q.Y)}){var t=ZP(g.ap(5,P));var y=!(!t||!t.endsWith("/aclk")||TQ(P,"ri")!=="1");break b}}catch(C){}y=!1}y?fpq(P)?(v&&v(),l=!0):l=!1:l=!1;l||Ca9(P,v)}}; fpq=function(P,v){try{if(window.navigator&&window.navigator.sendBeacon&&window.navigator.sendBeacon(P,v===void 0?"":v))return!0}catch(l){}return!1}; Ca9=function(P,v,l){l=l===void 0?{}:l;var e=new Image,h=""+gNu++;sh[h]=e;e.onload=e.onerror=function(){v&&sh[h]&&v();delete sh[h]}; l.scrubReferrer&&(e.referrerPolicy="no-referrer");e.src=P}; k_q=function(P){var v;return((v=document.featurePolicy)==null?0:v.allowedFeatures().includes("attribution-reporting"))?P+"&nis=6":P+"&nis=5"}; MI=function(){rW||(rW=new y8("yt.offline"));return rW}; wMD=function(P){if(g.YN("offline_error_handling")){var v=MI().get("errors",!0)||{};v[P.message]={name:P.name,stack:P.stack};P.level&&(v[P.message].level=P.level);MI().set("errors",v,2592E3,!0)}}; TJ=function(){this.W=new Map;this.K=!1}; VR=function(){if(!TJ.instance){var P=g.j9("yt.networkRequestMonitor.instance")||new TJ;g.ZB("yt.networkRequestMonitor.instance",P);TJ.instance=P}return TJ.instance}; dW=function(){g.zQ.call(this);var P=this;this.K=!1;this.W=Ym7();this.W.listen("networkstatus-online",function(){if(P.K&&g.YN("offline_error_handling")){var v=MI().get("errors",!0);if(v){for(var l in v)if(v[l]){var e=new g.Ph(l,"sent via offline_errors");e.name=v[l].name;e.stack=v[l].stack;e.level=v[l].level;g.z_(e)}MI().set("errors",{},2592E3,!0)}}})}; $cD=function(){if(!dW.instance){var P=g.j9("yt.networkStatusManager.instance")||new dW;g.ZB("yt.networkStatusManager.instance",P);dW.instance=P}return dW.instance}; g.PY=function(P){P=P===void 0?{}:P;g.zQ.call(this);var v=this;this.W=this.Y=0;this.K=$cD();var l=g.j9("yt.networkStatusManager.instance.listen").bind(this.K);l&&(P.rateLimit?(this.rateLimit=P.rateLimit,l("networkstatus-online",function(){Ip7(v,"publicytnetworkstatus-online")}),l("networkstatus-offline",function(){Ip7(v,"publicytnetworkstatus-offline")})):(l("networkstatus-online",function(){v.dispatchEvent("publicytnetworkstatus-online")}),l("networkstatus-offline",function(){v.dispatchEvent("publicytnetworkstatus-offline")})))}; Ip7=function(P,v){P.rateLimit?P.W?(g.dj.UZ(P.Y),P.Y=g.dj.VG(function(){P.G!==v&&(P.dispatchEvent(v),P.G=v,P.W=(0,g.Gz)())},P.rateLimit-((0,g.Gz)()-P.W))):(P.dispatchEvent(v),P.G=v,P.W=(0,g.Gz)()):P.dispatchEvent(v)}; lC=function(){var P=Hs.call;vY||(vY=new g.PY({aZ$:!0,nq6:!0}));P.call(Hs,this,{r7:{nj:zRa,ip:hRw,uc:vNx,f5$:lpa,dO:eRw,set:PaD},LJ:vY,handleError:function(v,l,e){var h,z=e==null?void 0:(h=e.error)==null?void 0:h.code;if(z===400||z===415){var m;RZ(new g.Ph(v.message,l,e==null?void 0:(m=e.error)==null?void 0:m.code),void 0,void 0,void 0,!0)}else g.z_(v)}, kD:RZ,sendFn:DcB,now:g.Gz,nm:wMD,bE:g.RG(),Q9:"publicytnetworkstatus-online",QV:"publicytnetworkstatus-offline",qI:!0,c$:.1,Ri:g.ba("potential_esf_error_limit",10),l$:g.YN,bF:!(g.lH()&&g.Hl(document.location.toString())!=="www.youtube-nocookie.com")});this.G=new g.J4;g.YN("networkless_immediately_drop_all_requests")&&mcu();Vdx("LogsDatabaseV2")}; eg=function(){var P=g.j9("yt.networklessRequestController.instance");P||(P=new lC,g.ZB("yt.networklessRequestController.instance",P),g.YN("networkless_logging")&&g.zJ().then(function(v){P.qv=v;sTW(P);P.G.resolve();P.qI&&Math.random()<=P.c$&&P.qv&&tNw(P.qv);g.YN("networkless_immediately_drop_sw_health_store")&&nNa(P)})); return P}; nNa=function(P){var v;g.p(function(l){if(!P.qv)throw v=g.Y6("clearSWHealthLogsDb"),v;return l.return(yZ2(P.qv).catch(function(e){P.handleError(e)}))})}; DcB=function(P,v,l,e){e=e===void 0?!1:e;v=g.YN("web_fp_via_jspb")?Object.assign({},v):v;g.YN("use_cfr_monitor")&&N$y(P,v);if(g.YN("use_request_time_ms_header"))v.headers&&w$(P)&&(v.headers["X-Goog-Request-Time"]=JSON.stringify(Math.round((0,g.Gz)())));else{var h;if((h=v.postParams)==null?0:h.requestTimeMs)v.postParams.requestTimeMs=Math.round((0,g.Gz)())}l&&Object.keys(v).length===0?g.oO(P):v.compress?v.postBody?(typeof v.postBody!=="string"&&(v.postBody=JSON.stringify(v.postBody)),Uh(P,v.postBody, v,g.SN,e)):Uh(P,JSON.stringify(v.postParams),v,G_,e):g.SN(P,v)}; h$=function(P,v){g.YN("use_event_time_ms_header")&&w$(P)&&(v.headers||(v.headers={}),v.headers["X-Goog-Event-Time"]=JSON.stringify(Math.round((0,g.Gz)())));return v}; N$y=function(P,v){var l=v.onError?v.onError:function(){}; v.onError=function(h,z){VR().requestComplete(P,!1);l(h,z)}; var e=v.onSuccess?v.onSuccess:function(){}; v.onSuccess=function(h,z){VR().requestComplete(P,!0);e(h,z)}}; g.zj=function(P){this.config_=null;P?this.config_=P:Iey()&&(this.config_=g.IO())}; g.mX=function(P,v,l,e){function h(y){try{if((y===void 0?0:y)&&e.retry&&!e.networklessOptions.bypassNetworkless)z.method="POST",e.networklessOptions.writeThenSend?eg().writeThenSend(t,z):eg().sendAndWrite(t,z);else if(e.compress){var C=!e.networklessOptions.writeThenSend;if(z.postBody){var f=z.postBody;typeof f!=="string"&&(f=JSON.stringify(z.postBody));Uh(t,f,z,g.SN,C)}else Uh(t,JSON.stringify(z.postParams),z,G_,C)}else g.YN("web_all_payloads_via_jspb")?g.SN(t,z):G_(t,z)}catch(k){if(k.name==="InvalidAccessError")RZ(Error("An extension is blocking network request.")); else throw k;}} !g.la("VISITOR_DATA")&&v!=="visitor_id"&&Math.random()<.01&&RZ(new g.Ph("Missing VISITOR_DATA when sending innertube request.",v,l,e));if(!P.isReady())throw P=new g.Ph("innertube xhrclient not ready",v,l,e),g.z_(P),P;var z={headers:e.headers||{},method:"POST",postParams:l,postBody:e.postBody,postBodyFormat:e.postBodyFormat||"JSON",onTimeout:function(){e.onTimeout()}, onFetchTimeout:e.onTimeout,onSuccess:function(y,C){if(e.onSuccess)e.onSuccess(C)}, onFetchSuccess:function(y){if(e.onSuccess)e.onSuccess(y)}, onError:function(y,C){if(e.onError)e.onError(C)}, onFetchError:function(y){if(e.onError)e.onError(y)}, timeout:e.timeout,withCredentials:!0,compress:e.compress};z.headers["Content-Type"]||(z.headers["Content-Type"]="application/json");l="";var m=P.config_.yx;m&&(l=m);m=P.config_.h0||!1;var Q=ArW(m,l,e);Object.assign(z.headers,Q);z.headers.Authorization&&!l&&m&&(z.headers["x-origin"]=window.location.origin);var t=g$(""+l+("/youtubei/"+P.config_.innertubeApiVersion+"/"+v),{alt:"json"});g.j9("ytNetworklessLoggingInitializationOptions")&&JZu.isNwlInitialized?Ekx().then(function(y){h(y)}):h(!1)}; g.Cy=function(P,v,l){var e=g.Rn();if(e&&v){var h=e.subscribe(P,function(){function z(){QU[h]&&v.apply&&typeof v.apply=="function"&&v.apply(l||window,m)} var m=arguments;try{g.t$[P]?z():g.KG(z,0)}catch(Q){g.z_(Q)}},l); QU[h]=!0;yU[P]||(yU[P]=[]);yU[P].push(h);return h}return 0}; uta=function(P){var v=g.Cy("LOGGED_IN",function(l){P.apply(void 0,arguments);g.fy(v)})}; g.fy=function(P){var v=g.Rn();v&&(typeof P==="number"?P=[P]:typeof P==="string"&&(P=[parseInt(P,10)]),g.f$(P,function(l){v.unsubscribeByKey(l);delete QU[l]}))}; g.gm=function(P,v){var l=g.Rn();return l?l.publish.apply(l,arguments):!1}; cZD=function(P){var v=g.Rn();if(v)if(v.clear(P),P)KVw(P);else for(var l in yU)KVw(l)}; g.Rn=function(){return g.Uy.ytPubsubPubsubInstance}; KVw=function(P){yU[P]&&(P=yU[P],g.f$(P,function(v){QU[v]&&delete QU[v]}),P.length=0)}; g.kR=function(P,v,l){qku(P,v,l===void 0?null:l)}; qku=function(P,v,l){l=l===void 0?null:l;var e=FV9(P),h=document.getElementById(e),z=h&&U7D(h),m=h&&!z;z?v&&v():(v&&(z=g.Cy(e,v),v=""+g.sy(v),AZw[v]=z),m||(h=YkD(P,e,function(){U7D(h)||(iTD(h),g.gm(e),g.KG(function(){cZD(e)},0))},l)))}; YkD=function(P,v,l,e){e=e===void 0?null:e;var h=g.l5("SCRIPT");h.id=v;h.onload=function(){l&&setTimeout(l,0)}; h.onreadystatechange=function(){switch(h.readyState){case "loaded":case "complete":h.onload()}}; e&&h.setAttribute("nonce",e);g.ON(h,g.LK(P));P=document.getElementsByTagName("head")[0]||document.body;P.insertBefore(h,P.firstChild);return h}; FV9=function(P){var v=document.createElement("a");g.BQ(v,P);P=v.href.replace(/^[a-zA-Z]+:\/\//,"//");return"js-"+l6(P)}; ny=function(P,v){if(P===v)P=!0;else if(Array.isArray(P)&&Array.isArray(v))P=g.yv(P,v,ny);else if(g.Oy(P)&&g.Oy(v))a:if(g.A3(P).length!=g.A3(v).length)P=!1;else{for(var l in P)if(!ny(P[l],v[l])){P=!1;break a}P=!0}else P=!1;return P}; uC=function(P){var v=g.bD.apply(1,arguments);if(!NB(P)||v.some(function(e){return!NB(e)}))throw Error("Only objects may be merged."); v=g.N(v);for(var l=v.next();!l.done;l=v.next())J$(P,l.value)}; J$=function(P,v){for(var l in v)if(NB(v[l])){if(l in P&&!NB(P[l]))throw Error("Cannot merge an object into a non-object.");l in P||(P[l]={});J$(P[l],v[l])}else if(Ky(v[l])){if(l in P&&!Ky(P[l]))throw Error("Cannot merge an array into a non-array.");l in P||(P[l]=[]);bG7(P[l],v[l])}else P[l]=v[l];return P}; bG7=function(P,v){v=g.N(v);for(var l=v.next();!l.done;l=v.next())l=l.value,NB(l)?P.push(J$({},l)):Ky(l)?P.push(bG7([],l)):P.push(l);return P}; NB=function(P){return typeof P==="object"&&!Array.isArray(P)}; Ky=function(P){return typeof P==="object"&&Array.isArray(P)}; cY=function(P){g.U.call(this);this.K=P}; qB=function(P){cY.call(this,!0);this.W=P}; xcW=function(P,v){g.U.call(this);var l=this;this.G=[];this.j=!1;this.K=0;this.Z=this.T=this.Y=!1;this.Wg=null;var e=(0,g.ru)(P,v);this.W=new g.mr(function(){return e(l.Wg)},300); g.Z(this,this.W);this.X=this.S=Infinity}; pMD=function(P,v){if(!v)return!1;for(var l=0;l -1)throw Error("Deps cycle for: "+v);if(P.K.has(v))return P.K.get(v);if(!P.W.has(v)){if(e)return;throw Error("No provider for: "+v);}e=P.W.get(v);l.push(v);if(e.m0!==void 0)var h=e.m0;else if(e.iJc)h=e[BY]?XMq(P,e[BY],l):[],h=e.iJc.apply(e,g.u(h));else if(e.YR){h=e.YR;var z=h[BY]?XMq(P,h[BY],l):[];h=new (Function.prototype.bind.apply(h,[null].concat(g.u(z))))}else throw Error("Could not resolve providers for: "+v);l.pop();e.pLW||P.K.set(v,h); return h}; XMq=function(P,v,l){return v?v.map(function(e){return e instanceof Gj?iC(P,e.key,l,!0):iC(P,e,l)}):[]}; Zm=function(){U$||(U$=new G_u);return U$}; an=function(){var P,v;return"h5vcc"in jg&&((P=jg.h5vcc.traceEvent)==null?0:P.traceBegin)&&((v=jg.h5vcc.traceEvent)==null?0:v.traceEnd)?1:"performance"in jg&&jg.performance.mark&&jg.performance.measure?2:0}; HY=function(P){var v=an();switch(v){case 1:jg.h5vcc.traceEvent.traceBegin("YTLR",P);break;case 2:jg.performance.mark(P+"-start");break;case 0:break;default:m9(v,"unknown trace type")}}; B$D=function(P){var v=an();switch(v){case 1:jg.h5vcc.traceEvent.traceEnd("YTLR",P);break;case 2:v=P+"-start";var l=P+"-end";jg.performance.mark(l);jg.performance.measure(P,v,l);break;case 0:break;default:m9(v,"unknown trace type")}}; iGw=function(P){var v,l;(l=(v=window).onerror)==null||l.call(v,P.message,"",0,0,P)}; Ucq=function(P){var v=this;var l=l===void 0?0:l;var e=e===void 0?g.RG():e;this.G=l;this.scheduler=e;this.K=new g.J4;this.W=P;for(P={Um:0};P.Um =1E3?h():e>=P?kt||(kt=wc(function(){h();kt=void 0},0)):z-Q>=10&&(ldW(v,l.tier),m.Y=z)}; T$W=function(P,v){if(P.endpoint==="log_event"){g.YN("more_accurate_gel_parser")&&hG().storePayload({isJspb:!1},P.payload);RM(P);var l=Qj(P),e=new Map;e.set(l,[P.payload]);var h=sZD(P.payload)||"";v&&(fg=new v);return new g.Jt(function(z,m){fg&&fg.isReady()?eIx(e,fg,z,m,{bypassNetworkless:!0},!0,yj(h)):z()})}}; PZ2=function(P,v,l){if(v.endpoint==="log_event"){RM(void 0,v);var e=Qj(v,!0),h=new Map;h.set(e,[Z_(v.payload)]);l&&(fg=new l);return new g.Jt(function(z){fg&&fg.isReady()?hID(h,fg,z,{bypassNetworkless:!0},!0,yj(P)):z()})}}; Qj=function(P,v){var l="";if(P.dangerousLogToVisitorSession)l="visitorOnlyApprovedKey";else if(P.cttAuthInfo){if(v===void 0?0:v){v=P.cttAuthInfo.token;l=P.cttAuthInfo;var e=new d_;l.videoId?e.setVideoId(l.videoId):l.playlistId&&Pt(e,2,$t,KV(l.playlistId));IM[v]=e}else v=P.cttAuthInfo,l={},v.videoId?l.videoId=v.videoId:v.playlistId&&(l.playlistId=v.playlistId),Dx[P.cttAuthInfo.token]=l;l=P.cttAuthInfo.token}return l}; Cg=function(P,v,l){P=P===void 0?{}:P;v=v===void 0?!1:v;new g.Jt(function(e,h){var z=gc(v,l),m=z.G;z.G=!1;ng(z.K);ng(z.W);z.W=0;fg&&fg.isReady()?l===void 0&&g.YN("enable_web_tiered_gel")?zIP(e,h,P,v,300,m):zIP(e,h,P,v,l,m):(ldW(v,l),e())})}; zIP=function(P,v,l,e,h,z){var m=fg;l=l===void 0?{}:l;e=e===void 0?!1:e;h=h===void 0?200:h;z=z===void 0?!1:z;var Q=new Map,t=new Map,y={isJspb:e,cttAuthInfo:void 0,tier:h},C={isJspb:e,cttAuthInfo:void 0};if(e){v=g.N(Object.keys(tG));for(h=v.next();!h.done;h=v.next())h=h.value,t=g.YN("enable_web_tiered_gel")?hG().smartExtractMatchingEntries({keys:[y,C],sizeLimit:1E3}):hG().extractMatchingEntries({isJspb:!0,cttAuthInfo:h}),t.length>0&&Q.set(h,t),(g.YN("web_fp_via_jspb_and_json")&&l.writeThenSend||!g.YN("web_fp_via_jspb_and_json"))&& delete tG[h];hID(Q,m,P,l,!1,z)}else{Q=g.N(Object.keys(tG));for(y=Q.next();!y.done;y=Q.next())y=y.value,C=g.YN("enable_web_tiered_gel")?hG().smartExtractMatchingEntries({keys:[{isJspb:!1,cttAuthInfo:y,tier:h},{isJspb:!1,cttAuthInfo:y}],sizeLimit:1E3}):hG().extractMatchingEntries({isJspb:!1,cttAuthInfo:y}),C.length>0&&t.set(y,C),(g.YN("web_fp_via_jspb_and_json")&&l.writeThenSend||!g.YN("web_fp_via_jspb_and_json"))&&delete tG[y];eIx(t,m,P,v,l,!1,z)}}; ldW=function(P,v){function l(){Cg({writeThenSend:!0},P,v)} P=P===void 0?!1:P;v=v===void 0?200:v;var e=gc(P,v),h=e===m19||e===RI6?5E3:Quw;g.YN("web_gel_timeout_cap")&&!e.W&&(h=wc(function(){l()},h),e.W=h); ng(e.K);h=g.la("LOGGING_BATCH_TIMEOUT",g.ba("web_gel_debounce_ms",1E4));g.YN("shorten_initial_gel_batch_timeout")&&Na&&(h=tBu);h=wc(function(){g.ba("gel_min_batch_size")>0?hG().getSequenceCount({cttAuthInfo:void 0,isJspb:P,tier:v})>=yBw&&l():l()},h); e.K=h}; eIx=function(P,v,l,e,h,z,m){h=h===void 0?{}:h;var Q=Math.round((0,g.Gz)()),t=P.size,y=CZ2(m);P=g.N(P);var C=P.next();for(m={};!C.done;m={O2:void 0,batchRequest:void 0,dangerousLogToVisitorSession:void 0,Bp:void 0,zZ:void 0},C=P.next()){var f=g.N(C.value);C=f.next().value;f=f.next().value;m.batchRequest=g.XN({context:g.Ds(v.config_||g.IO())});if(!g.Ww(f)&&!g.YN("throw_err_when_logevent_malformed_killswitch")){e();break}m.batchRequest.events=f;(f=Dx[C])&&fdW(m.batchRequest,C,f);delete Dx[C];m.dangerousLogToVisitorSession= C==="visitorOnlyApprovedKey";gdx(m.batchRequest,Q,m.dangerousLogToVisitorSession);kTW(h);m.Bp=function(k){g.YN("start_client_gcf")&&g.dj.VG(function(){return g.p(function(w){return g.b(w,wxw(k),0)})}); t--;t||l()}; m.O2=0;m.zZ=function(k){return function(){k.O2++;if(h.bypassNetworkless&&k.O2===1)try{g.mX(v,y,k.batchRequest,JG({writeThenSend:!0},k.dangerousLogToVisitorSession,k.Bp,k.zZ,z)),Na=!1}catch(w){g.z_(w),e()}t--;t||l()}}(m); try{g.mX(v,y,m.batchRequest,JG(h,m.dangerousLogToVisitorSession,m.Bp,m.zZ,z)),Na=!1}catch(k){g.z_(k),e()}}}; hID=function(P,v,l,e,h,z){e=e===void 0?{}:e;var m=Math.round((0,g.Gz)()),Q={value:P.size},t=new Map([].concat(g.u(P)));t=g.N(t);for(var y=t.next();!y.done;y=t.next()){var C=g.N(y.value).next().value,f=P.get(C);y=new EgW;var k=v.config_||g.IO(),w=new oT,I=new iO;wi(I,1,k.MQ);wi(I,2,k.fP);IY(I,16,k.A0);wi(I,17,k.innertubeContextClientVersion);if(k.d$){var J=k.d$,K=new X7;J.coldConfigData&&wi(K,1,J.coldConfigData);J.appInstallData&&wi(K,6,J.appInstallData);J.coldHashData&&wi(K,3,J.coldHashData);J.hotHashData&& K.kE(J.hotHashData);mT(I,X7,62,K)}(J=g.Uy.devicePixelRatio)&&J!=1&&Ul(I,65,R6(J));J=xN();J!==""&&wi(I,54,J);J=pG();if(J.length>0){K=new jS;for(var q=0;q 65535&&(P=1);vM("BATCH_CLIENT_COUNTER",P);return P}; fdW=function(P,v,l){if(l.videoId)var e="VIDEO";else if(l.playlistId)e="PLAYLIST";else return;P.credentialTransferTokenTargetId=l;P.context=P.context||{};P.context.user=P.context.user||{};P.context.user.credentialTransferTokens=[{token:v,scope:e}]}; RM=function(P,v){if(!g.j9("yt.logging.transport.enableScrapingForTest")){var l=AZ("il_payload_scraping");if((l!==void 0?String(l):"")==="enable_il_payload_scraping")cu=[],g.ZB("yt.logging.transport.enableScrapingForTest",!0),g.ZB("yt.logging.transport.scrapedPayloadsForTesting",cu),g.ZB("yt.logging.transport.payloadToScrape","visualElementShown visualElementHidden visualElementAttached screenCreated visualElementGestured visualElementStateChanged".split(" ")),g.ZB("yt.logging.transport.getScrapedPayloadFromClientEventsFunction"), g.ZB("yt.logging.transport.scrapeClientEvent",!0);else return}l=g.j9("yt.logging.transport.scrapedPayloadsForTesting");var e=g.j9("yt.logging.transport.payloadToScrape");v&&(v=v.payload,(v=g.j9("yt.logging.transport.getScrapedPayloadFromClientEventsFunction").bind(v)())&&l.push(v));v=g.j9("yt.logging.transport.scrapeClientEvent");if(e&&e.length>=1)for(var h=0;h 0&&BDw(P,v,z)}else BDw(P,v)}; BDw=function(P,v,l){P=ikw(P);v=v?g.sU(v):"";l=l||5;tB()&&g.Ek(P,v,l)}; ikw=function(P){for(var v=g.N(U1P),l=v.next();!l.done;l=v.next())P=VF(P,l.value);return"ST-"+l6(P).toString(36)}; ZkW=function(P){if(P.name==="JavaException")return!0;P=P.stack;return P.includes("chrome://")||P.includes("chrome-extension://")||P.includes("moz-extension://")}; juD=function(){this.GI=[];this.DY=[]}; Xi=function(){if(!GM){var P=GM=new juD;P.DY.length=0;P.GI.length=0;adB(P,Hk7)}return GM}; adB=function(P,v){v.DY&&P.DY.push.apply(P.DY,v.DY);v.GI&&P.GI.push.apply(P.GI,v.GI)}; Edq=function(P){function v(){return P.charCodeAt(e++)} var l=P.length,e=0;do{var h=Bu(v);if(h===Infinity)break;var z=h>>3;switch(h&7){case 0:h=Bu(v);if(z===2)return h;break;case 1:if(z===2)return;e+=8;break;case 2:h=Bu(v);if(z===2)return P.substr(e,h);e+=h;break;case 5:if(z===2)return;e+=4;break;default:return}}while(e 500));e++);e=h}else if(typeof P==="object")for(h in P){if(P[h]){var z=h;var m=P[h],Q=v,t=l;z=typeof m!=="string"||z!=="clickTrackingParams"&&z!=="trackingParams"?0:(m=Edq(atob(m.replace(/-/g,"+").replace(/_/g,"/"))))?il(z+".ve",m,Q,t):0;e+=z;e+=il(h,P[h],v,l);if(e>500)break}}else l[v]=Uc(P),e+=l[v].length;else l[v]=Uc(P),e+=l[v].length;return e}; il=function(P,v,l,e){l+="."+P;P=Uc(v);e[l]=P;return l.length+P.length}; Uc=function(P){try{return(typeof P==="string"?P:String(JSON.stringify(P))).substr(0,500)}catch(v){return"unable to serialize "+typeof P+" ("+v.message+")"}}; wn=function(P){g.Zx(P)}; g.j4=function(P){g.Zx(P,"WARNING")}; g.Zx=function(P,v){var l=l===void 0?{}:l;l.name=g.la("INNERTUBE_CONTEXT_CLIENT_NAME",1);l.version=g.la("INNERTUBE_CONTEXT_CLIENT_VERSION");v=v===void 0?"ERROR":v;var e=!1;v=v===void 0?"ERROR":v;e=e===void 0?!1:e;if(P){P.hasOwnProperty("level")&&P.level&&(v=P.level);if(g.YN("console_log_js_exceptions")){var h=[];h.push("Name: "+P.name);h.push("Message: "+P.message);P.hasOwnProperty("params")&&h.push("Error Params: "+JSON.stringify(P.params));P.hasOwnProperty("args")&&h.push("Error args: "+JSON.stringify(P.args)); h.push("File name: "+P.fileName);h.push("Stacktrace: "+P.stack);window.console.log(h.join("\n"),P)}if(!(Ok9>=5)){h=odw;var z=pvP(P),m=z.message||"Unknown Error",Q=z.name||"UnknownError",t=z.stack||P.K||"Not available";if(t.startsWith(Q+": "+m)){var y=t.split("\n");y.shift();t=y.join("\n")}y=z.lineNumber||"Not available";z=z.fileName||"Not available";var C=0;if(P.hasOwnProperty("args")&&P.args&&P.args.length)for(var f=0;f =500);f++);else if(P.hasOwnProperty("params")&& P.params){var k=P.params;if(typeof P.params==="object")for(f in k){if(k[f]){var w="params."+f,I=Uc(k[f]);l[w]=I;C+=w.length+I.length;if(C>500)break}}else l.params=Uc(k)}if(h.length)for(f=0;f =500);f++);navigator.vendor&&!l.hasOwnProperty("vendor")&&(l["device.vendor"]=navigator.vendor);l={message:m,name:Q,lineNumber:y,fileName:z,stack:t,params:l,sampleWeight:1};h=Number(P.columnNumber);isNaN(h)||(l.lineNumber=l.lineNumber+":"+h);if(P.level==="IGNORED")P= 0;else a:{P=Xi();h=g.N(P.DY);for(m=h.next();!m.done;m=h.next())if(m=m.value,l.message&&l.message.match(m.lT)){P=m.weight;break a}P=g.N(P.GI);for(h=P.next();!h.done;h=P.next())if(h=h.value,h.callback(l)){P=h.weight;break a}P=1}l.sampleWeight=P;P=g.N(su7);for(h=P.next();!h.done;h=P.next())if(h=h.value,h.rF[l.name])for(Q=g.N(h.rF[l.name]),m=Q.next();!m.done;m=Q.next())if(f=m.value,m=l.message.match(f.zo)){l.params["params.error.original"]=m[0];Q=f.groups;f={};for(y=0;y 1E3&&g.j4(new g.Ph("IL Attach cache exceeded limit"))}Q= Pp(l,v);rc.has(Q)?vp(l,v):TM.set(Q,!0)}}e=e.filter(function(C){C.csn!==v?(C.csn=v,C=!0):C=!1;return C}); l={csn:v,parentVe:l.getAsJson(),childVes:g.LC(e,function(C){return C.getAsJson()})}; v==="UNDEFINED_CSN"?lE("visualElementAttached",z,l):P?Fi("visualElementAttached",l,P,z):g.$6("visualElementAttached",l,z)}; tYq=function(P,v,l,e,h){e3(l,v);e=sc({cttAuthInfo:Lg(v)||void 0},v);l={csn:v,ve:l.getAsJson(),eventType:1};h&&(l.clientData=h);v==="UNDEFINED_CSN"?lE("visualElementShown",e,l):P?Fi("visualElementShown",l,P,e):g.$6("visualElementShown",l,e)}; yPw=function(P,v,l,e){var h=(e=e===void 0?!1:e)?16:8;e=sc({cttAuthInfo:Lg(v)||void 0,endOfSequence:e},v);l={csn:v,ve:l.getAsJson(),eventType:h};v==="UNDEFINED_CSN"?lE("visualElementHidden",e,l):P?Fi("visualElementHidden",l,P,e):g.$6("visualElementHidden",l,e)}; CH2=function(P,v,l,e,h){hz(P,v,l,void 0,e,h)}; hz=function(P,v,l,e,h){e3(l,v);e=e||"INTERACTION_LOGGING_GESTURE_TYPE_GENERIC_CLICK";var z=sc({cttAuthInfo:Lg(v)||void 0},v);l={csn:v,ve:l.getAsJson(),gestureType:e};h&&(l.clientData=h);v==="UNDEFINED_CSN"?lE("visualElementGestured",z,l):P?Fi("visualElementGestured",l,P,z):g.$6("visualElementGestured",l,z)}; f06=function(){var P=A$(16);for(var v=[],l=0;l 0&&l.push(g.l5("BR"));l.push(g.eu(z))}):l.push(g.eu(e))}return l}; Ir=function(P,v,l,e){if(l==="child"){g.z9(v);var h;e===void 0?h=void 0:h=!Array.isArray(e)||e&&typeof e.L==="string"?[e]:e;l=kzq(P,h);l=g.N(l);for(P=l.next();!P.done;P=l.next())v.appendChild(P.value)}else l==="style"?g.DO(v,"cssText",e?e:""):e===null||e===void 0?v.removeAttribute(l):(P=e.toString(),l==="href"&&(P=g.pi(g.G0(P))),v.setAttribute(l,P))}; g.O=function(P){g.wA.call(this,P);this.KI=!0;this.Z=!1;this.listeners=[]}; g.DW=function(P){g.O.call(this,P);this.q5=new g.gA;g.Z(this,this.q5)}; nv=function(P,v,l,e,h,z,m){m=m===void 0?null:m;g.DW.call(this,v);this.api=P;this.macros={};this.componentType=l;this.j=this.S=null;this.Bg=m;this.layoutId=e;this.interactionLoggingClientData=h;this.Rc=z;this.h5=null;this.gO=new qB(this.element);g.Z(this,this.gO);this.U$=this.C(this.element,"click",this.onClick);this.T1=[];this.J5=new xcW(this.onClick,this);g.Z(this,this.J5);this.WK=!1;this.wM=this.Wg=null}; ND=function(P,v){P=P===void 0?null:P;v=v===void 0?null:v;if(P==null)return g.j4(Error("Got null or undefined adText object")),"";var l=g.vr(P.text);if(!P.isTemplated)return l;if(v==null)return g.j4(Error("Missing required parameters for a templated message")),l;P=g.N(Object.entries(v));for(v=P.next();!v.done;v=P.next()){var e=g.N(v.value);v=e.next().value;e=e.next().value;l=l.replace("{"+v+"}",e)}return l}; wh9=function(P){P=P===void 0?null:P;return P!=null&&(P=P.thumbnail,P!=null&&P.thumbnails!=null&&P.thumbnails.length!=0&&P.thumbnails[0].url!=null)?g.vr(P.thumbnails[0].url):""}; $4P=function(P){P=P===void 0?null:P;return P!=null&&(P=P.thumbnail,P!=null&&P.thumbnails!=null&&P.thumbnails.length!=0&&P.thumbnails[0].width!=null&&P.thumbnails[0].height!=null)?new g.Dc(P.thumbnails[0].width||0,P.thumbnails[0].height||0):new g.Dc(0,0)}; g.Jz=function(P){if(P.simpleText)return P.simpleText;if(P.runs){var v=[];P=g.N(P.runs);for(var l=P.next();!l.done;l=P.next())l=l.value,l.text&&v.push(l.text);return v.join("")}return""}; g.uE=function(P){if(P.simpleText)return P=document.createTextNode(P.simpleText),P;var v=[];if(P.runs)for(var l=0;l 1){for(var v=[P[0]],l=1;l 0&&(this.W=new g.mr(this.XA,v,this),g.Z(this,this.W));this.Z=new g.mr(this.XA,l,this);g.Z(this,this.Z);this.S=XkW(this.K,h,1,e);g.Z(this,this.S);this.j=XkW(this.K,0,e,1);g.Z(this,this.j);this.Y=new GT;g.Z(this,this.Y)}; gX=function(P,v,l){this.K=P;this.isAsync=v;this.W=l}; PXy=function(P){switch(P){case 2:return 0;case 1:return 2;case 0:return 3;case 4:case 3:return 1;default:m9(P,"unknown result type")}}; vzD=function(P,v){var l=1;P.isTrusted===!1&&(l=0);vM("ISDSTAT",l);kU(l,"i.s_",{triggerContext:"sk",metadata:v});return l}; lsx=function(P,v){var l=[];v?v.isTrusted===!0?l.push("BISCOTTI_BASED_DETECTION_STATE_AS_SEEK_EVENT_TRUSTED"):v.isTrusted===!1?l.push("BISCOTTI_BASED_DETECTION_STATE_AS_SEEK_EVENT_NOT_TRUSTED"):l.push("BISCOTTI_BASED_DETECTION_STATE_AS_SEEK_EVENT_TRUSTED_PROPERTY_UNDEFINED"):l.push("BISCOTTI_BASED_DETECTION_STATE_AS_SEEK_EVENT_UNDEFINED");kU(0,"a.s_",{metadata:P,states:l});vM("ASDSTAT",0)}; kU=function(P,v,l){v=eQw[v];var e,h,z={detected:P===0,source:""+v.K+((e=l.triggerContext)!=null?e:"")+((h=l.hM)!=null?h:""),detectionStates:l.states,durationMs:l.yg};l.metadata&&(z.contentCpn=l.metadata.contentCpn,z.adCpn=l.metadata.adCpn);g.$6("biscottiBasedDetection",z);v.W!==void 0&&(l=Number(g.la("CATSTAT",0)),v.W!==void 0?(v=v.W,P=PXy(P),P=l&~(3< 0}; Jm=function(P,v,l,e,h,z){eP.call(this,P,{L:"div",D:"ytp-ad-skip-button-slot"},"skip-button",v,l,e,h);var m=this;this.QW=null;this.kf=!1;this.Ic=z;this.T=this.api.N().experiments.l$("enable_modern_skip_button_on_web");this.A5=!1;this.G=new g.DW({L:"span",z1:["ytp-ad-skip-button-container"]});this.T&&this.G.element.classList.add("ytp-ad-skip-button-container-detached");this.api.V("enable_ad_pod_index_autohide")&&this.G.element.classList.add("ytp-ad-skip-button-container--clean-player");g.Z(this,this.G); this.G.E$(this.element);this.K=this.Y=null;this.D3=new g.mA(this.G,500,!1,100,function(){return m.hide()}); g.Z(this,this.D3);this.Hg=new f2(this.G.element,15E3,5E3,.5,.5,this.T);g.Z(this,this.Hg);this.hide()}; zQD=function(P){P=P.QW&&P.QW.adRendererCommands;return(P&&P.clickCommand&&g.a(P.clickCommand,g.u4)&&g.a(P.clickCommand,g.u4).commands||[]).some(function(v){return v.adLifecycleCommand?hQD(v.adLifecycleCommand):!1})}; hQD=function(P){return P.action==="END_LINEAR_AD"||P.action==="END_LINEAR_AD_PLACEMENT"}; K2=function(P,v,l,e,h,z){eP.call(this,P,{L:"div",D:"ytp-ad-skip-ad-slot"},"skip-ad",v,l,e,h);this.QW=z;this.Y=!1;this.T=0;this.G=this.K=null;this.hide()}; mIW=function(P,v){P.Y||(P.Y=!0,P.K&&(v?P.K.kf.hide():P.K.hide()),v?(P=P.G,P.D3.show(),P.show()):P.G.show())}; c$=function(P,v,l,e){iE.call(this,P,v,l,e,["ytp-ad-visit-advertiser-button"],"visit-advertiser")}; qQ=function(P,v,l,e,h,z,m){z=z===void 0?!1:z;m=m===void 0?!1:m;nv.call(this,P,{L:"span",D:"ytp-ad-simple-ad-badge"},"simple-ad-badge",v,l,e);this.G=h;this.W=this.cg("ytp-ad-simple-ad-badge");(this.K=z)&&this.W.classList.add("ytp-ad-simple-ad-badge--clean-player");m&&this.W.classList.add("ytp-ad-simple-ad-badge--survey");this.hide()}; F8=function(P,v,l,e,h){h=h===void 0?!1:h;fv.call(this,"player-overlay",P,{},v,e);this.videoAdDurationSeconds=l;this.interactionLoggingClientData=e;this.rd=h}; Am=function(P,v){g.gA.call(this);this.api=P;this.durationMs=v;this.W=null;this.Ub=new GT(this);g.Z(this,this.Ub);this.K=RQ9;this.Ub.C(this.api,"presentingplayerstatechange",this.j4);this.W=this.Ub.C(this.api,"onAdPlaybackProgress",this.sb)}; YU=function(P){g.gA.call(this);this.W=!1;this.CY=0;this.Ub=new GT(this);g.Z(this,this.Ub);this.durationMs=P;this.uC=new g.Y9(100);g.Z(this,this.uC);this.Ub.C(this.uC,"tick",this.sb);this.K={seekableStart:0,seekableEnd:P/1E3,current:0};this.start()}; g.b4=function(P,v){var l=Math.abs(Math.floor(P)),e=Math.floor(l/86400),h=Math.floor(l%86400/3600),z=Math.floor(l%3600/60);l=Math.floor(l%60);if(v){v="";e>0&&(v+=" "+e+" D\u00edas");if(e>0||h>0)v+=" "+h+" Horas";v+=" "+z+" Minutos";v+=" "+l+" Segundos";e=v.trim()}else{v="";e>0&&(v+=e+":",h<10&&(v+="0"));if(e>0||h>0)v+=h+":",z<10&&(v+="0");v+=z+":";l<10&&(v+="0");e=v+l}return P>=0?e:"-"+e}; g.xU=function(P){return(!("button"in P)||typeof P.button!=="number"||P.button===0)&&!("shiftKey"in P&&P.shiftKey)&&!("altKey"in P&&P.altKey)&&!("metaKey"in P&&P.metaKey)&&!("ctrlKey"in P&&P.ctrlKey)}; p2=function(P,v,l,e,h,z,m){eP.call(this,P,{L:"span",D:m?"ytp-ad-duration-remaining--clean-player":"ytp-ad-duration-remaining"},"ad-duration-remaining",v,l,e,h);this.videoAdDurationSeconds=z;this.K=null;this.api.V("clean_player_style_fix_on_web")&&this.element.classList.add("ytp-ad-duration-remaining--clean-player-with-light-shadow");m&&this.api.N().K&&(this.element.classList.add("ytp-ad-duration-remaining--mweb"),this.api.V("clean_player_style_fix_on_web")&&(this.element.classList.add("ytp-ad-duration-remaining--mweb-light"), Ps&&this.element.classList.add("ytp-ad-duration-remaining--mweb-ios")));this.hide()}; L2=function(P,v,l,e){v$.call(this,P,v,l,e,"ytp-video-ad-top-bar-title","ad-title");P.V("enable_ad_pod_index_autohide")&&this.element.classList.add("ytp-video-ad-top-bar-title--clean-player")}; SP=function(P){this.content=P.content;if(P.commandRuns){P=g.N(P.commandRuns);for(var v=P.next();!v.done;v=P.next())v=v.value,this.loggingDirectives=g.a(v,QOD),v.onTap&&(this.interaction={onTap:v.onTap})}}; GL=function(P,v,l,e){nv.call(this,P,{L:"div",D:"ad-simple-attributed-string"},"ad-simple-attributed-string",v,l,e);this.hide()}; X8=function(P,v,l,e,h){nv.call(this,P,{L:"span",D:h?"ytp-ad-badge--clean-player":"ytp-ad-badge"},"ad-badge",v,l,e);this.K=h;this.adBadgeText=new GL(this.api,this.layoutId,this.interactionLoggingClientData,this.Rc);this.adBadgeText.E$(this.element);g.Z(this,this.adBadgeText);h?(this.adBadgeText.element.classList.add("ytp-ad-badge__text--clean-player"),this.api.V("clean_player_style_fix_on_web")&&(this.adBadgeText.element.classList.add("ytp-ad-badge__text--clean-player-with-light-shadow"),Ps&&this.adBadgeText.element.classList.add("ytp-ad-badge--stark-clean-player-ios"))): this.adBadgeText.element.classList.add("ytp-ad-badge__text");this.hide()}; B$=function(P,v,l,e,h){nv.call(this,P,{L:"span",D:"ytp-ad-pod-index"},"ad-pod-index",v,l,e);this.K=h;this.api.N().K&&(this.element.classList.add("ytp-ad-pod-index--mweb"),this.api.V("clean_player_style_fix_on_web")&&(this.element.classList.add("ytp-ad-pod-index--mweb-light"),Ps&&this.element.classList.add("ytp-ad-pod-index--mweb-ios")));this.hide()}; i4=function(P,v,l,e){nv.call(this,P,{L:"div",D:"ytp-ad-disclosure-banner"},"ad-disclosure-banner",v,l,e);this.hide()}; UI=function(P,v){this.K=P;this.W=v}; ZS=function(P,v,l){if(!P.getLength())return l!=null?l:Infinity;P=(v-P.K)/P.getLength();return g.CU(P,0,1)}; jP=function(P,v,l,e){e=e===void 0?!1:e;g.DW.call(this,{L:"div",D:"ytp-ad-persistent-progress-bar-container",U:[{L:"div",D:"ytp-ad-persistent-progress-bar"}]});this.api=P;this.K=v;this.G=l;e&&this.element.classList.add("ytp-ad-persistent-progress-bar-container--clean-player");g.Z(this,this.K);this.progressBar=this.cg("ytp-ad-persistent-progress-bar");this.W=-1;this.C(P,"presentingplayerstatechange",this.onStateChange);this.hide();this.onStateChange()}; aq=function(P,v,l,e,h,z){nv.call(this,P,{L:"div",D:"ytp-ad-player-overlay",U:[{L:"div",D:"ytp-ad-player-overlay-flyout-cta"},{L:"div",D:"ytp-ad-player-overlay-instream-info"},{L:"div",D:"ytp-ad-player-overlay-skip-or-preview"},{L:"div",D:"ytp-ad-player-overlay-progress-bar"},{L:"div",D:"ytp-ad-player-overlay-instream-user-sentiment"},{L:"div",D:"ytp-ad-player-overlay-ad-disclosure-banner"}]},"player-overlay",v,l,e);this.QW=z;this.T=this.cg("ytp-ad-player-overlay-flyout-cta");this.T.classList.add("ytp-ad-player-overlay-flyout-cta-rounded"); this.W=this.cg("ytp-ad-player-overlay-instream-info");this.Y=null;tlB(this)&&(P=vi("div"),g.kk(P,"ytp-ad-player-overlay-top-bar-gradients"),this.api.V("disable_ad_preview_for_instream_ads")&&g.kk(P,"ytp-ad-player-overlay-top-bar-gradients--clean-player"),v=this.W,v.parentNode&&v.parentNode.insertBefore(P,v),(v=this.api.getVideoData(2))&&v.isListed&&v.title&&(l=new L2(this.api,this.layoutId,this.interactionLoggingClientData,this.Rc),l.E$(P),l.init(Cv("ad-title"),{text:v.title},this.macros),g.Z(this, l)),this.Y=P);this.G=null;this.X=this.cg("ytp-ad-player-overlay-skip-or-preview");this.Pg=this.cg("ytp-ad-player-overlay-progress-bar");this.Hg=this.cg("ytp-ad-player-overlay-instream-user-sentiment");this.kf=this.cg("ytp-ad-player-overlay-ad-disclosure-banner");this.K=h;g.Z(this,this.K);this.hide()}; tlB=function(P){P=P.api.N();return g.H$(P)&&P.K}; EI=function(P,v,l){var e={};v&&(e.v=v);l&&(e.list=l);P={name:P,locale:void 0,feature:void 0};for(var h in e)P[h]=e[h];e=g.r5("/sharing_services",P);g.oO(e)}; g.W$=function(P){P&=16777215;var v=[(P&16711680)>>16,(P&65280)>>8,P&255];P=v[0];var l=v[1];v=v[2];P=Number(P);l=Number(l);v=Number(v);if(P!=(P&255)||l!=(l&255)||v!=(v&255))throw Error('"('+P+","+l+","+v+'") is not a valid RGB color');l=P<<16|l<<8|v;return P<16?"#"+(16777216|l).toString(16).slice(1):"#"+l.toString(16)}; OI=function(P){this.W=new i$(P)}; y6w=function(){var P=!1;try{P=!!window.sessionStorage.getItem("session_logininfo")}catch(v){P=!0}return(g.la("INNERTUBE_CLIENT_NAME")==="WEB"||g.la("INNERTUBE_CLIENT_NAME")==="WEB_CREATOR")&&P}; oq=function(P){if(g.la("LOGGED_IN",!0)&&y6w()){var v=g.la("VALID_SESSION_TEMPDATA_DOMAINS",[]);var l=g.Hl(window.location.href);l&&v.push(l);l=g.Hl(P);g.ro(v,l)||!l&&NG(P,"/")?(v=EU(P),(v=KtD(v))?(v=ikw(v),v=(v=g.WM(v)||null)?yS(v):{}):v=null):v=null;v==null&&(v={});l=v;var e=void 0;y6w()?(e||(e=g.la("LOGIN_INFO")),e?(l.session_logininfo=e,l=!0):l=!1):l=!1;l&&S4(P,v)}}; g.CX2=function(P){var v=v===void 0?{}:v;var l=l===void 0?"":l;var e=e===void 0?window:e;P=g.r5(P,v);oq(P);l=g.G0(P+l);e=e.location;l=X_(l);l!==void 0&&(e.href=l)}; g.sI=function(P,v,l){v=v===void 0?{}:v;l=l===void 0?!1:l;var e=g.la("EVENT_ID");e&&(v.ei||(v.ei=e));v&&S4(P,v);l||(oq(P),g.CX2(P))}; g.rX=function(P,v,l,e,h){h=h===void 0?!1:h;l&&S4(P,l);l=g.G0(P);var z=g.pi(l);P!=z&&RZ(Error("Unsafe window.open URL: "+P));P=z;v=v||l6(P).toString(36);try{if(h){h=P;h=k_q(h);oq(h);g.ji(window,h,v,"attributionsrc");return}}catch(m){g.z_(m)}oq(P);g.ji(window,l,v,e)}; fsy=function(P){MQ=P}; gz6=function(P){TL=P}; kJP=function(P){VX=P}; $I6=function(){wsq=VX=TL=MQ=null}; DIB=function(){var P=P===void 0?window.location.href:P;if(g.YN("kevlar_disable_theme_param"))return null;var v=ZP(g.ap(5,P));if(g.YN("enable_dark_theme_only_on_shorts")&&v!=null&&v.startsWith("/shorts/"))return"USER_INTERFACE_THEME_DARK";try{var l=g.fG(P).theme;return Isu.get(l)||null}catch(e){}return null}; dX=function(){this.W={};if(this.K=Njx()){var P=g.WM("CONSISTENCY");P&&nzW(this,{encryptedTokenJarContents:P})}}; nzW=function(P,v){if(v.encryptedTokenJarContents&&(P.W[v.encryptedTokenJarContents]=v,typeof v.expirationSeconds==="string")){var l=Number(v.expirationSeconds);setTimeout(function(){delete P.W[v.encryptedTokenJarContents]},l*1E3); P.K&&g.Ek("CONSISTENCY",v.encryptedTokenJarContents,l,void 0,!0)}}; vI=function(){this.K=-1;var P=g.la("LOCATION_PLAYABILITY_TOKEN");g.la("INNERTUBE_CLIENT_NAME")==="TVHTML5"&&(this.localStorage=PI(this))&&(P=this.localStorage.get("yt-location-playability-token"));P&&(this.locationPlayabilityToken=P,this.W=void 0)}; PI=function(P){return P.localStorage===void 0?new y8("yt-client-location"):P.localStorage}; g.lo=function(P,v,l){v=v===void 0?!1:v;l=l===void 0?!1:l;var e=g.la("INNERTUBE_CONTEXT");if(!e)return g.Zx(Error("Error: No InnerTubeContext shell provided in ytconfig.")),{};e=g.XN(e);g.YN("web_no_tracking_params_in_shell_killswitch")||delete e.clickTracking;e.client||(e.client={});var h=e.client;h.clientName==="MWEB"&&h.clientFormFactor!=="AUTOMOTIVE_FORM_FACTOR"&&(h.clientFormFactor=g.la("IS_TABLET")?"LARGE_FORM_FACTOR":"SMALL_FORM_FACTOR");h.screenWidthPoints=window.innerWidth;h.screenHeightPoints= window.innerHeight;h.screenPixelDensity=Math.round(window.devicePixelRatio||1);h.screenDensityFloat=window.devicePixelRatio||1;h.utcOffsetMinutes=-Math.floor((new Date).getTimezoneOffset());var z=z===void 0?!1:z;g.sY();var m="USER_INTERFACE_THEME_LIGHT";g.rD(0,165)?m="USER_INTERFACE_THEME_DARK":g.rD(0,174)?m="USER_INTERFACE_THEME_LIGHT":!g.YN("kevlar_legacy_browsers")&&window.matchMedia&&window.matchMedia("(prefers-color-scheme)").matches&&window.matchMedia("(prefers-color-scheme: dark)").matches&& (m="USER_INTERFACE_THEME_DARK");z=z?m:DIB()||m;h.userInterfaceTheme=z;if(!v){if(z=Re2())h.connectionType=z;g.YN("web_log_effective_connection_type")&&(z=tdw())&&(e.client.effectiveConnectionType=z)}var Q;if(g.YN("web_log_memory_total_kbytes")&&((Q=g.Uy.navigator)==null?0:Q.deviceMemory)){var t;Q=(t=g.Uy.navigator)==null?void 0:t.deviceMemory;e.client.memoryTotalKbytes=""+Q*1E6}g.YN("web_gcf_hashes_innertube")&&(z=$WB())&&(t=z.coldConfigData,Q=z.coldHashData,z=z.hotHashData,e.client.configInfo=e.client.configInfo|| {},t&&(e.client.configInfo.coldConfigData=t),Q&&(e.client.configInfo.coldHashData=Q),z&&(e.client.configInfo.hotHashData=z));t=g.fG(g.Uy.location.href);!g.YN("web_populate_internal_geo_killswitch")&&t.internalcountrycode&&(h.internalGeo=t.internalcountrycode);h.clientName==="MWEB"||h.clientName==="WEB"?(h.mainAppWebInfo={graftUrl:g.Uy.location.href},g.YN("kevlar_woffle")&&P$7.instance&&(t=P$7.instance,h.mainAppWebInfo.pwaInstallabilityStatus=!t.W&&t.K?"PWA_INSTALLABILITY_STATUS_CAN_BE_INSTALLED": "PWA_INSTALLABILITY_STATUS_UNKNOWN"),h.mainAppWebInfo.webDisplayMode=Wx(),h.mainAppWebInfo.isWebNativeShareAvailable=navigator&&navigator.share!==void 0):h.clientName==="TVHTML5"&&(!g.YN("web_lr_app_quality_killswitch")&&(t=g.la("LIVING_ROOM_APP_QUALITY"))&&(h.tvAppInfo=Object.assign(h.tvAppInfo||{},{appQuality:t})),t=g.la("LIVING_ROOM_CERTIFICATION_SCOPE"))&&(h.tvAppInfo=Object.assign(h.tvAppInfo||{},{certificationScope:t}));if(!g.YN("web_populate_time_zone_itc_killswitch")){a:{if(typeof Intl!== "undefined")try{var y=(new Intl.DateTimeFormat).resolvedOptions().timeZone;break a}catch(S){}y=void 0}y&&(h.timeZone=y)}(y=xN())?h.experimentsToken=y:delete h.experimentsToken;y=pG();dX.instance||(dX.instance=new dX);e.request=Object.assign({},e.request,{internalExperimentFlags:y,consistencyTokenJars:g.FN(dX.instance.W)});!g.YN("web_prequest_context_killswitch")&&(y=g.la("INNERTUBE_CONTEXT_PREQUEST_CONTEXT"))&&(e.request.externalPrequestContext=y);h=g.sY();y=g.rD(0,58);h=h.get("gsml","");e.user=Object.assign({}, e.user);y&&(e.user.enableSafetyMode=y);h&&(e.user.lockedSafetyMode=!0);g.YN("warm_op_csn_cleanup")?l&&(v=g.pg())&&(e.clientScreenNonce=v):!v&&(v=g.pg())&&(e.clientScreenNonce=v);P&&(e.clickTracking={clickTrackingParams:P});if(P=g.j9("yt.mdx.remote.remoteClient_"))e.remoteClient=P;vI.getInstance().setLocationOnInnerTubeContext(e);try{var C=Nc(),f=C.bid;delete C.bid;e.adSignalsInfo={params:[],bid:f};for(var k=g.N(Object.entries(C)),w=k.next();!w.done;w=k.next()){var I=g.N(w.value),J=I.next().value, K=I.next().value;C=J;f=K;P=void 0;(P=e.adSignalsInfo.params)==null||P.push({key:C,value:""+f})}var q,A;if(((q=e.client)==null?void 0:q.clientName)==="TVHTML5"||((A=e.client)==null?void 0:A.clientName)==="TVHTML5_UNPLUGGED"){var x=g.la("INNERTUBE_CONTEXT");x.adSignalsInfo&&(e.adSignalsInfo.advertisingId=x.adSignalsInfo.advertisingId,e.adSignalsInfo.advertisingIdSignalType="DEVICE_ID_TYPE_CONNECTED_TV_IFA",e.adSignalsInfo.limitAdTracking=x.adSignalsInfo.limitAdTracking)}}catch(S){g.Zx(S)}return e}; uUP=function(P,v){if(!P)return!1;var l,e=(l=g.a(P,NW2))==null?void 0:l.signal;if(e&&v.oC)return!!v.oC[e];var h;if((l=(h=g.a(P,J6u))==null?void 0:h.request)&&v.Xr)return!!v.Xr[l];for(var z in P)if(v.dS[z])return!0;return!1}; KIB=function(P){var v={"Content-Type":"application/json"};g.la("EOM_VISITOR_DATA")?v["X-Goog-EOM-Visitor-Id"]=g.la("EOM_VISITOR_DATA"):g.la("VISITOR_DATA")&&(v["X-Goog-Visitor-Id"]=g.la("VISITOR_DATA"));v["X-Youtube-Bootstrap-Logged-In"]=g.la("LOGGED_IN",!1);g.la("DEBUG_SETTINGS_METADATA")&&(v["X-Debug-Settings-Metadata"]=g.la("DEBUG_SETTINGS_METADATA"));P!=="cors"&&((P=g.la("INNERTUBE_CONTEXT_CLIENT_NAME"))&&(v["X-Youtube-Client-Name"]=P),(P=g.la("INNERTUBE_CONTEXT_CLIENT_VERSION"))&&(v["X-Youtube-Client-Version"]= P),(P=g.la("CHROME_CONNECTED_HEADER"))&&(v["X-Youtube-Chrome-Connected"]=P),(P=g.la("DOMAIN_ADMIN_STATE"))&&(v["X-Youtube-Domain-Admin-State"]=P),g.la("ENABLE_LAVA_HEADER_ON_IT_EXPANSION")&&(P=g.la("SERIALIZED_LAVA_DEVICE_CONTEXT"))&&(v["X-YouTube-Lava-Device-Context"]=P));return v}; c6w=function(){this.W={}}; ee=function(){this.mappings=new c6w}; hH=function(P){return function(){return new P}}; FIB=function(P){var v=v===void 0?"UNKNOWN_INTERFACE":v;if(P.length===1)return P[0];var l=qhD[v];if(l){l=new RegExp(l);for(var e=g.N(P),h=e.next();!h.done;h=e.next())if(h=h.value,l.exec(h))return h}var z=[];Object.entries(qhD).forEach(function(m){var Q=g.N(m);m=Q.next().value;Q=Q.next().value;v!==m&&z.push(Q)}); l=new RegExp(z.join("|"));P.sort(function(m,Q){return m.length-Q.length}); e=g.N(P);for(h=e.next();!h.done;h=e.next())if(h=h.value,!l.exec(h))return h;return P[0]}; g.$S=function(P){return"/youtubei/v1/"+FIB(P)}; I5=function(){}; Df=function(){}; ns=function(){}; Nd=function(P){return g.j9("ytcsi."+(P||"")+"data_")||A6w(P)}; YhP=function(){var P=Nd();P.info||(P.info={});return P.info}; JH=function(P){P=Nd(P);P.metadata||(P.metadata={});return P.metadata}; uo=function(P){P=Nd(P);P.tick||(P.tick={});return P.tick}; Ks=function(P){P=Nd(P);if(P.gel){var v=P.gel;v.gelInfos||(v.gelInfos={});v.gelTicks||(v.gelTicks={})}else P.gel={gelTicks:{},gelInfos:{}};return P.gel}; b9a=function(P){P=Ks(P);P.gelInfos||(P.gelInfos={});return P.gelInfos}; cI=function(P){var v=Nd(P).nonce;v||(v=g.YR(16),Nd(P).nonce=v);return v}; A6w=function(P){var v={tick:{},info:{}};g.ZB("ytcsi."+(P||"")+"data_",v);return v}; qd=function(){var P=g.j9("ytcsi.debug");P||(P=[],g.ZB("ytcsi.debug",P),g.ZB("ytcsi.reference",{}));return P}; F5=function(P){P=P||"";var v=xIw();if(v[P])return v[P];var l=qd(),e={timerName:P,info:{},tick:{},span:{},jspbInfo:[]};l.push(e);return v[P]=e}; psu=function(P){P=P||"";var v=xIw();v[P]&&delete v[P];var l=qd(),e={timerName:P,info:{},tick:{},span:{},jspbInfo:[]};l.push(e);v[P]=e}; xIw=function(){var P=g.j9("ytcsi.reference");if(P)return P;qd();return g.j9("ytcsi.reference")}; AH=function(P){return LI7[P]||"LATENCY_ACTION_UNKNOWN"}; YS=function(P,v){NI.call(this,1,arguments);this.uC=v}; bo=function(){this.W=0}; xS=function(){bo.instance||(bo.instance=new bo);return bo.instance}; Ls=function(P,v){ps[v]=ps[v]||{count:0};var l=ps[v];l.count++;l.time=(0,g.Gz)();P.W||(P.W=g.zz(0,function(){var e=(0,g.Gz)(),h;for(h in ps)ps[h]&&e-ps[h].time>6E4&&delete ps[h];P&&(P.W=0)},5E3)); return l.count>5?(l.count===6&&Math.random()*1E5<1&&(l=new g.Ph("CSI data exceeded logging limit with key",v.split("_")),v.indexOf("plev")>=0||g.j4(l)),!0):!1}; Sh9=function(){this.timing={};this.clearResourceTimings=function(){}; this.webkitClearResourceTimings=function(){}; this.mozClearResourceTimings=function(){}; this.msClearResourceTimings=function(){}; this.oClearResourceTimings=function(){}}; GJP=function(){var P;if(g.YN("csi_use_performance_navigation_timing")||g.YN("csi_use_performance_navigation_timing_tvhtml5")){var v,l,e,h=Se==null?void 0:(P=Se.getEntriesByType)==null?void 0:(v=P.call(Se,"navigation"))==null?void 0:(l=v[0])==null?void 0:(e=l.toJSON)==null?void 0:e.call(l);h?(h.requestStart=Gx(h.requestStart),h.responseEnd=Gx(h.responseEnd),h.redirectStart=Gx(h.redirectStart),h.redirectEnd=Gx(h.redirectEnd),h.domainLookupEnd=Gx(h.domainLookupEnd),h.connectStart=Gx(h.connectStart), h.connectEnd=Gx(h.connectEnd),h.responseStart=Gx(h.responseStart),h.secureConnectionStart=Gx(h.secureConnectionStart),h.domainLookupStart=Gx(h.domainLookupStart),h.isPerformanceNavigationTiming=!0,P=h):P=Se.timing}else P=g.YN("csi_performance_timing_to_object")?JSON.parse(JSON.stringify(Se.timing)):Se.timing;return P}; Gx=function(P){return Math.round(X5()+P)}; X5=function(){return(g.YN("csi_use_time_origin")||g.YN("csi_use_time_origin_tvhtml5"))&&Se.timeOrigin?Math.floor(Se.timeOrigin):Se.timing.navigationStart}; io=function(P,v){BI("_start",P,v)}; Un=function(P,v){if(!g.YN("web_csi_action_sampling_enabled")||!Nd(v).actionDisabled){var l=F5(v||"");uC(l.info,P);P.loadType&&(l=P.loadType,JH(v).loadType=l);uC(b9a(v),P);l=cI(v);v=Nd(v).cttAuthInfo;xS().info(P,l,v)}}; XsP=function(){var P,v,l,e;return((e=Zm().resolve(new Gj(wW))==null?void 0:(P=$z())==null?void 0:(v=P.loggingHotConfig)==null?void 0:(l=v.csiConfig)==null?void 0:l.debugTicks)!=null?e:[]).map(function(h){return Object.values(h)[0]})}; BI=function(P,v,l){if(!g.YN("web_csi_action_sampling_enabled")||!Nd(l).actionDisabled){var e=cI(l),h;if(h=g.YN("web_csi_debug_sample_enabled")&&e){(Zm().resolve(new Gj(wW))==null?0:$z())&&!BWw&&(BWw=!0,BI("gcfl",(0,g.Gz)(),l));var z,m,Q;h=(Zm().resolve(new Gj(wW))==null?void 0:(z=$z())==null?void 0:(m=z.loggingHotConfig)==null?void 0:(Q=m.csiConfig)==null?void 0:Q.debugSampleWeight)||0;if(z=h!==0)b:{z=XsP();if(z.length>0)for(m=0;m l.duration?e:l},{duration:0}))&&v.startTime>0&&v.responseEnd>0&&(BI("wffs",Gx(v.startTime)),BI("wffe",Gx(v.responseEnd)))}; Ezq=function(P,v,l){Se&&Se.measure&&(P.startsWith("measure_")||(P="measure_"+P),l?Se.measure(P,v,l):v?Se.measure(P,v):Se.measure(P))}; WI6=function(P){var v=Zf("aft",P);if(v)return v;v=g.la((P||"")+"TIMING_AFT_KEYS",["ol"]);for(var l=v.length,e=0;e 0&&Un(v);v={isNavigation:!0,actionType:AH(g.la("TIMING_ACTION"))};var l=g.la("PREVIOUS_ACTION");l&&(v.previousAction=AH(l));if(l=g.la("CLIENT_PROTOCOL"))v.httpProtocol=l;if(l=g.la("CLIENT_TRANSPORT"))v.transportProtocol=l;(l=g.pg())&&l!=="UNDEFINED_CSN"&&(v.clientScreenNonce=l);l=Z9D();if(l===1||l===-1)v.isVisible= !0;l=JH().loadType==="cold";var e=YhP();l||(l=e.yt_lt==="cold");if(l){v.loadType="cold";l=YhP();e=GJP();var h=X5(),z=g.la("CSI_START_TIMESTAMP_MILLIS",0);z>0&&!g.YN("embeds_web_enable_csi_start_override_killswitch")&&(h=z);h&&(BI("srt",e.responseStart),l.prerender!==1&&io(h));l=sO6();l>0&&BI("fpt",l);l=GJP();l.isPerformanceNavigationTiming&&Un({performanceNavigationTiming:!0},void 0);BI("nreqs",l.requestStart,void 0);BI("nress",l.responseStart,void 0);BI("nrese",l.responseEnd,void 0);l.redirectEnd- l.redirectStart>0&&(BI("nrs",l.redirectStart,void 0),BI("nre",l.redirectEnd,void 0));l.domainLookupEnd-l.domainLookupStart>0&&(BI("ndnss",l.domainLookupStart,void 0),BI("ndnse",l.domainLookupEnd,void 0));l.connectEnd-l.connectStart>0&&(BI("ntcps",l.connectStart,void 0),BI("ntcpe",l.connectEnd,void 0));l.secureConnectionStart>=X5()&&l.connectEnd-l.secureConnectionStart>0&&(BI("nstcps",l.secureConnectionStart,void 0),BI("ntcpe",l.connectEnd,void 0));Se&&"getEntriesByType"in Se&&H97();l=[];if(document.querySelector&& Se&&Se.getEntriesByName)for(var m in HI)HI.hasOwnProperty(m)&&(e=HI[m],asw(m,e)&&l.push(e));if(l.length>0)for(v.resourceInfo=[],m=g.N(l),l=m.next();!l.done;l=m.next())v.resourceInfo.push({resourceCache:l.value})}Un(v);v=Ks();v.preLoggedGelInfos||(v.preLoggedGelInfos=[]);m=v.preLoggedGelInfos;v=b9a();l=void 0;for(e=0;e -1&&(delete n["@type"],r=n);J&&P.K.has(J)&&P.K.delete(J);((du=v.config)==null?0:du.Lf$)&&WI(v.config.Lf$);if(r||(K1=P.G)==null||!K1.YqW(v.input,v.Oq)){Aq.ac(15);break}return g.b(Aq,P.G.Tu3(v.input,v.Oq),16);case 16:r=Aq.K;case 15:return fmD(P,r,v),((f1=v.config)==null?0:f1.h3W)&&WI(v.config.h3W),e(),Aq.return(r|| void 0)}})}; Rqa=function(P,v){a:{P=P.nB;var l,e=(l=g.a(v,NW2))==null?void 0:l.signal;if(e&&P.oC&&(l=P.oC[e])){var h=l();break a}var z;if((l=(z=g.a(v,J6u))==null?void 0:z.request)&&P.Xr&&(z=P.Xr[l])){h=z();break a}for(h in v)if(P.dS[h]&&(v=P.dS[h])){h=v();break a}h=void 0}if(h!==void 0)return Promise.resolve(h)}; tg2=function(P,v,l){var e,h,z,m,Q,t,y;return g.p(function(C){if(C.W==1){z=((e=v)==null?void 0:(h=e.gr)==null?void 0:h.identity)||n9;t=(m=v)==null?void 0:(Q=m.gr)==null?void 0:Q.sessionIndex;var f=g.K7(P.W.W8(z,{sessionIndex:t}));return g.b(C,f,2)}y=C.K;return C.return(Promise.resolve(Object.assign({},KIB(l),y)))})}; Qn2=function(P,v,l){var e,h=(v==null?void 0:(e=v.gr)==null?void 0:e.identity)||n9,z;v=v==null?void 0:(z=v.gr)==null?void 0:z.sessionIndex;P=P.W.W8(h,{sessionIndex:v});return Object.assign({},KIB(l),P)}; Pq=function(){}; vq=function(){}; lh=function(P){this.T=P}; e1=function(){}; hf=function(){}; zi=function(){}; mn=function(){}; g.RH=function(P,v){var l=g.bD.apply(2,arguments);P=P===void 0?0:P;g.Ph.call(this,v,l);this.errorType=P;Object.setPrototypeOf(this,this.constructor.prototype)}; Qn=function(P,v,l){this.W=P;this.K=v;this.G=l}; kj6=function(P,v,l){if(P.W){var e=ZP(g.ap(5,VF(v,"key")))||"/UNKNOWN_PATH";P.W.start(e)}P=l;g.YN("wug_networking_gzip_request")&&(P=oID(l));return new window.Request(v,P)}; g.yn=function(P,v){if(!tf){var l=Zm();Xv(l,{YZ:wYw,YR:Qn});var e={dS:{feedbackEndpoint:hH(e1),modifyChannelNotificationPreferenceEndpoint:hH(hf),playlistEditEndpoint:hH(zi),shareEntityEndpoint:hH(lh),subscribeEndpoint:hH(Pq),unsubscribeEndpoint:hH(vq),webPlayerShareEntityServiceEndpoint:hH(mn)}},h=vI.getInstance(),z={};h&&(z.client_location=h);P===void 0&&(P=vky());v===void 0&&(v=l.resolve(wYw));mBW(e,v,P,z);Xv(l,{YZ:$Bq,m0:Tx.instance});tf=l.resolve($Bq)}return tf}; ImP=function(P){var v=new nI;if(P.interpreterJavascript){var l=XLD(P.interpreterJavascript);l=EN(l).toString();var e=new I3;wi(e,6,l);mT(v,I3,1,e)}else P.interpreterUrl&&(l=pK(P.interpreterUrl),l=bQ(l).toString(),e=new DG,wi(e,4,l),mT(v,DG,2,e));P.interpreterHash&&$K(v,3,P.interpreterHash);P.program&&$K(v,4,P.program);P.globalName&&$K(v,5,P.globalName);P.clientExperimentsStateBlob&&$K(v,7,P.clientExperimentsStateBlob);return v}; Ca=function(P){var v={};P=P.split("&");P=g.N(P);for(var l=P.next();!l.done;l=P.next())l=l.value.split("="),l.length===2&&(v[l[0]]=l[1]);return v}; v1D=function(){if(g.YN("bg_st_hr"))return"havuokmhhs-0";var P,v=((P=performance)==null?void 0:P.timeOrigin)||0;return"havuokmhhs-"+Math.floor(v)}; fa=function(P){this.W=P}; DBP=function(){return new Promise(function(P){var v=window.top;v.ntpevasrs!==void 0?P(new fa(v.ntpevasrs)):(v.ntpqfbel===void 0&&(v.ntpqfbel=[]),v.ntpqfbel.push(function(l){P(new fa(l))}))})}; Nmx=function(){if(!g.YN("disable_biscotti_fetch_for_ad_blocker_detection")&&!g.YN("disable_biscotti_fetch_entirely_for_all_web_clients")&&tB()){var P=g.la("PLAYER_VARS",{});if(g.LU(P,"privembed",!1)!="1"&&!Aaa(P)){var v=function(){gx=!0;"google_ad_status"in window?vM("DCLKSTAT",1):vM("DCLKSTAT",2)}; try{g.kR("//static.doubleclick.net/instream/ad_status.js",v)}catch(l){}nRx.push(g.dj.VG(function(){if(!(gx||"google_ad_status"in window)){try{if(v){var l=""+g.sy(v),e=AZw[l];e&&g.fy(e)}}catch(h){}gx=!0;vM("DCLKSTAT",3)}},5E3))}}}; ke=function(){var P=Number(g.la("DCLKSTAT",0));return isNaN(P)?0:P}; DX=function(P,v,l){var e=this;this.network=P;this.options=v;this.K=l;this.W=null;if(v.mRM){var h=new g.J4;this.W=h.promise;g.Uy.ytAtRC&&hP(function(){var z,m;return g.p(function(Q){if(Q.W==1){if(!g.Uy.ytAtRC)return Q.return();z=wx(null);return g.b(Q,$e(e,z),2)}m=Q.K;g.Uy.ytAtRC&&g.Uy.ytAtRC(JSON.stringify(m));g.nx(Q)})},2); DBP().then(function(z){var m,Q,t,y;return g.p(function(C){if(C.W==1)return z.bindInnertubeChallengeFetcher(function(f){return $e(e,wx(f))}),g.b(C,B9(),2); m=C.K;Q=z.getLatestChallengeResponse();t=Q.challenge;if(!t)throw Error("BGE_MACIL");y={challenge:t,UY:Ca(t),hk:m,bgChallenge:new nI};h.resolve(y);z.registerChallengeFetchedCallback(function(f){f=f.challenge;if(!f)throw Error("BGE_MACR");f={challenge:f,UY:Ca(f),hk:m,bgChallenge:new nI};e.W=Promise.resolve(f)}); g.nx(C)})})}else v.preload&&J$9(this,new Promise(function(z){g.zz(0,function(){z(IH(e))},0)}))}; wx=function(P){var v={engagementType:"ENGAGEMENT_TYPE_UNBOUND"};P&&(v.interpreterHash=P);return v}; IH=function(P,v){v=v===void 0?0:v;var l,e,h,z,m,Q,t,y,C,f,k,w;return g.p(function(I){switch(I.W){case 1:l=wx(ql().W);if(g.YN("att_fet_ks"))return g.NP(I,7),g.b(I,$e(P,l),9);g.NP(I,4);return g.b(I,uv6(P,l),6);case 6:m=I.K;h=m.c3J;z=m.Tv$;e=m;g.uD(I,3);break;case 4:return g.Kx(I),g.j4(Error("Failed to fetch attestation challenge after "+(v+" attempts; not retrying for 24h."))),na(P,864E5),I.return({challenge:"",UY:{},hk:void 0,bgChallenge:void 0});case 9:e=I.K;if(!e)throw Error("Fetching Attestation challenge returned falsy"); if(!e.challenge)throw Error("Missing Attestation challenge");h=e.challenge;z=Ca(h);if("c1a"in z&&(!e.bgChallenge||!e.bgChallenge.program))throw Error("Expected bg challenge but missing.");g.uD(I,3);break;case 7:Q=g.Kx(I);g.j4(Q);v++;if(v>=5)return g.j4(Error("Failed to fetch attestation challenge after "+(v+" attempts; not retrying for 24h."))),na(P,864E5),I.return({challenge:"",UY:{},hk:void 0,bgChallenge:void 0});t=1E3*Math.pow(2,v-1)+Math.random()*1E3;return I.return(new Promise(function(J){g.zz(0, function(){J(IH(P,v))},t)})); case 3:y=Number(z.t)||7200;na(P,y*1E3);C=void 0;if(!("c1a"in z&&e.bgChallenge)){I.ac(10);break}f=ImP(e.bgChallenge);g.NP(I,11);return g.b(I,FF(ql(),f),13);case 13:g.uD(I,12);break;case 11:return k=g.Kx(I),g.j4(k),I.return({challenge:h,UY:z,hk:C,bgChallenge:f});case 12:return g.NP(I,14),C=new uK({challenge:f,J$:{TJ:"aGIf"}}),g.b(I,C.KG,16);case 16:g.uD(I,10);break;case 14:w=g.Kx(I),g.j4(w),C=void 0;case 10:return I.return({challenge:h,UY:z,hk:C,bgChallenge:f})}})}; $e=function(P,v){var l;return g.p(function(e){l=P.K;if(!l||l.GA())return e.return($e(P.network,v));Md("att_pna",void 0,"attestation_challenge_fetch");return e.return(new Promise(function(h){l.cN("publicytnetworkstatus-online",function(){$e(P.network,v).then(h)})}))})}; KXw=function(P){if(!P)throw Error("Fetching Attestation challenge returned falsy");if(!P.challenge)throw Error("Missing Attestation challenge");var v=P.challenge,l=Ca(v);if("c1a"in l&&(!P.bgChallenge||!P.bgChallenge.program))throw Error("Expected bg challenge but missing.");return Object.assign({},P,{c3J:v,Tv$:l})}; uv6=function(P,v){var l,e,h,z,m;return g.p(function(Q){switch(Q.W){case 1:l=void 0,e=0,h={};case 2:if(!(e<5)){Q.ac(4);break}if(!(e>0)){Q.ac(5);break}h.K_=1E3*Math.pow(2,e-1)+Math.random()*1E3;return g.b(Q,new Promise(function(t){return function(y){g.zz(0,function(){y(void 0)},t.K_)}}(h)),5); case 5:return g.NP(Q,7),g.b(Q,$e(P,v),9);case 9:return z=Q.K,Q.return(KXw(z));case 7:l=m=g.Kx(Q),m instanceof Error&&g.j4(m);case 8:e++;h={K_:void 0};Q.ac(2);break;case 4:throw l;}})}; J$9=function(P,v){P.W=v}; c$x=function(P){var v,l,e;return g.p(function(h){if(h.W==1)return g.b(h,Promise.race([P.W,null]),2);v=h.K;var z=IH(P);P.W=z;(l=v)==null||(e=l.hk)==null||e.dispose();g.nx(h)})}; na=function(P,v){function l(){var h;return g.p(function(z){h=e-Date.now();return h<1E3?g.b(z,c$x(P),0):(hP(l,0,Math.min(h,6E4)),z.ac(0))})} var e=Date.now()+v;l()}; q$a=function(P,v){return new Promise(function(l){g.zz(0,function(){l(v())},P)})}; g.FXa=function(P,v){var l;return g.p(function(e){var h=g.j9("yt.aba.att");return(l=h?h:DX.instance!==void 0?DX.instance.G.bind(DX.instance):null)?e.return(l("ENGAGEMENT_TYPE_PLAYBACK",P,v)):e.return(Promise.resolve({error:"ATTESTATION_ERROR_API_NOT_READY"}))})}; g.A$P=function(){var P;return(P=(P=g.j9("yt.aba.att2"))?P:DX.instance!==void 0?DX.instance.Y.bind(DX.instance):null)?P():Promise.resolve(!1)}; byw=function(P,v){var l=g.j9("ytDebugData.callbacks");l||(l={},g.ZB("ytDebugData.callbacks",l));if(g.YN("web_dd_iu")||Y$7.includes(P))l[P]=v}; Nb=function(){var P=xB2;var v=v===void 0?[]:v;var l=l===void 0?[]:l;v=bbw.apply(null,[xRD.apply(null,g.u(v))].concat(g.u(l)));this.store=LUu(P,void 0,v)}; g.Jf=function(P,v,l){for(var e=Object.assign({},P),h=g.N(Object.keys(v)),z=h.next();!z.done;z=h.next()){z=z.value;var m=P[z],Q=v[z];if(Q===void 0)delete e[z];else if(m===void 0)e[z]=Q;else if(Array.isArray(Q)&&Array.isArray(m))e[z]=l?[].concat(g.u(m),g.u(Q)):Q;else if(!Array.isArray(Q)&&g.Oy(Q)&&!Array.isArray(m)&&g.Oy(m))e[z]=g.Jf(m,Q,l);else if(typeof Q===typeof m)e[z]=Q;else return v=new g.Ph("Attempted to merge fields of differing types.",{name:"DeepMergeError",key:z,vEJ:m,updateValue:Q}),g.Zx(v), P}return e}; uh=function(P){var v=this;P=P===void 0?[]:P;this.XL=[];this.Sb=this.FH=0;this.Fa=void 0;this.totalLength=0;P.forEach(function(l){v.append(l)})}; pYw=function(P,v){return P.XL.length===0?!1:(P=P.XL[P.XL.length-1])&&P.buffer===v.buffer&&P.byteOffset+P.length===v.byteOffset}; Ka=function(P,v){v=g.N(v.XL);for(var l=v.next();!l.done;l=v.next())P.append(l.value)}; cq=function(P,v,l){return P.split(v).o5.split(l).xS}; qb=function(P){P.Fa=void 0;P.FH=0;P.Sb=0}; F$=function(P,v,l){P.isFocused(v);return v-P.Sb+l<=P.XL[P.FH].length}; LXu=function(P){if(!P.Fa){var v=P.XL[P.FH];P.Fa=new DataView(v.buffer,v.byteOffset,v.length)}return P.Fa}; Af=function(P,v,l){P=P.Yt(v===void 0?0:v,l===void 0?-1:l);v=new Uint8Array(P.length);try{v.set(P)}catch(e){for(l=0;l >10;z=56320|z&1023}xe[h++]=z}}z=String.fromCharCode.apply(String,xe); h<1024&&(z=z.substring(0,h));l.push(z)}return l.join("")}; S1=function(P,v){var l;if((l=La)==null?0:l.encodeInto)return v=La.encodeInto(P,v),v.read >6|192:((h&64512)===55296&&e+1 >18|240,v[l++]=h>>12&63|128):v[l++]=h>>12|224,v[l++]=h>>6&63|128),v[l++]=h&63|128)}return l}; Gi=function(P){if(La)return La.encode(P);var v=new Uint8Array(Math.ceil(P.length*1.2)),l=S1(P,v);v.length l&&(v=v.subarray(0,l));return v}; X$=function(P){this.W=P;this.pos=0;this.K=-1}; Bq=function(P){var v=P.W.getUint8(P.pos);++P.pos;if(v<128)return v;for(var l=v&127,e=1;v>=128;)v=P.W.getUint8(P.pos),++P.pos,e*=128,l+=(v&127)*e;return l}; ih=function(P,v){var l=P.K;for(P.K=-1;P.W.Du(P.pos,1);){l<0&&(l=Bq(P));var e=l>>3,h=l&7;if(e===v)return!0;if(e>v){P.K=l;break}l=-1;switch(h){case 0:Bq(P);break;case 1:P.pos+=8;break;case 2:e=Bq(P);P.pos+=e;break;case 5:P.pos+=4}}return!1}; Ui=function(P,v){if(ih(P,v))return Bq(P)}; ZX=function(P,v){if(ih(P,v))return!!Bq(P)}; j1=function(P,v){if(ih(P,v)){v=Bq(P);var l=P.W.Yt(P.pos,v);P.pos+=v;return l}}; aH=function(P,v){if(P=j1(P,v))return g.pa(P)}; Hq=function(P,v,l){if(P=j1(P,v))return l(new X$(new uh([P])))}; Ei=function(P,v){for(var l=[];ih(P,v);)l.push(Bq(P));return l.length?l:void 0}; Wq=function(P,v,l){for(var e=[],h;h=j1(P,v);)e.push(l(new X$(new uh([h]))));return e.length?e:void 0}; Oi=function(P,v){P=P instanceof Uint8Array?new uh([P]):P;return v(new X$(P))}; XY2=function(P,v,l){if(v&&l&&l.buffer===v.exports.memory.buffer){var e=v.realloc(l.byteOffset,P);if(e)return new Uint8Array(v.exports.memory.buffer,e,P)}P=v?new Uint8Array(v.exports.memory.buffer,v.malloc(P),P):new Uint8Array(P);l&&P.set(l);return P}; Bmw=function(P,v){this.X_=v;this.pos=0;this.K=[];this.W=XY2(P===void 0?4096:P,v);this.view=new DataView(this.W.buffer,this.W.byteOffset,this.W.byteLength)}; oH=function(P,v){v=P.pos+v;if(!(P.W.length>=v)){for(var l=P.W.length*2;l 268435455){oH(P,4);for(var l=v&1073741823,e=0;e<4;e++)P.view.setUint8(P.pos,l&127|128),l>>=7,P.pos+=1;v=Math.floor(v/268435456)}for(oH(P,4);v>127;)P.view.setUint8(P.pos,v&127|128),v>>=7,P.pos+=1;P.view.setUint8(P.pos,v);P.pos+=1}; zI=function(P,v,l){l!==void 0&&(hS(P,v*8),hS(P,l))}; mq=function(P,v,l){l!==void 0&&zI(P,v,l?1:0)}; Rd=function(P,v,l){l!==void 0&&(hS(P,v*8+2),v=l.length,hS(P,v),oH(P,v),P.W.set(l,P.pos),P.pos+=v)}; Qg=function(P,v,l){l!==void 0&&(iyP(P,v,Math.ceil(Math.log2(l.length*4+2)/7)),oH(P,l.length*1.2),v=S1(l,P.W.subarray(P.pos)),P.pos+v>P.W.length&&(oH(P,v),v=S1(l,P.W.subarray(P.pos))),P.pos+=v,UBW(P))}; iyP=function(P,v,l){l=l===void 0?2:l;hS(P,v*8+2);P.K.push(P.pos);P.K.push(l);P.pos+=l}; UBW=function(P){for(var v=P.K.pop(),l=P.K.pop(),e=P.pos-l-v;v--;){var h=v?128:0;P.view.setUint8(l++,e&127|h);e>>=7}}; tS=function(P,v,l,e,h){l&&(iyP(P,v,h===void 0?3:h),e(P,l),UBW(P))}; g.yg=function(P,v,l){l=new Bmw(4096,l);v(l,P);return new Uint8Array(l.W.buffer,l.W.byteOffset,l.pos)}; g.Ct=function(P){var v=new X$(new uh([No(decodeURIComponent(P))]));P=aH(v,2);v=Ui(v,4);var l=ZyD[v];if(typeof l==="undefined")throw P=new g.Ph("Failed to recognize field number",{name:"EntityKeyHelperError",A82:v}),g.Zx(P),P;return{nC:v,entityType:l,entityId:P}}; g.ft=function(P,v){var l=new Bmw;Rd(l,2,Gi(P));P=jnu[v];if(typeof P==="undefined")throw v=new g.Ph("Failed to recognize entity type",{name:"EntityKeyHelperError",entityType:v}),g.Zx(v),v;zI(l,4,P);zI(l,5,1);v=new Uint8Array(l.W.buffer,l.W.byteOffset,l.pos);return encodeURIComponent(g.D7(v))}; ge=function(P,v,l,e){if(e===void 0)return e=Object.assign({},P[v]||{}),l=(delete e[l],e),e={},Object.assign({},P,(e[v]=l,e));var h={},z={};return Object.assign({},P,(z[v]=Object.assign({},P[v],(h[l]=e,h)),z))}; amu=function(P,v,l,e,h){var z=P[v];if(z==null||!z[l])return P;e=g.Jf(z[l],e,h==="REPEATED_FIELDS_MERGE_OPTION_APPEND");h={};z={};return Object.assign({},P,(z[v]=Object.assign({},P[v],(h[l]=e,h)),z))}; Hy9=function(P,v){P=P===void 0?{}:P;switch(v.type){case "ENTITY_LOADED":return v.payload.reduce(function(e,h){var z,m=(z=h.options)==null?void 0:z.persistenceOption;if(m&&m!=="ENTITY_PERSISTENCE_OPTION_UNKNOWN"&&m!=="ENTITY_PERSISTENCE_OPTION_INMEMORY_AND_PERSIST")return e;if(!h.entityKey)return g.Zx(Error("Missing entity key")),e;if(h.type==="ENTITY_MUTATION_TYPE_REPLACE"){if(!h.payload)return g.Zx(new g.Ph("REPLACE entity mutation is missing a payload",{entityKey:h.entityKey})),e;var Q=g.qT(h.payload); return ge(e,Q,h.entityKey,h.payload[Q])}if(h.type==="ENTITY_MUTATION_TYPE_DELETE"){a:{h=h.entityKey;try{var t=g.Ct(h).entityType;Q=ge(e,t,h);break a}catch(f){if(f instanceof Error){g.Zx(new g.Ph("Failed to deserialize entity key",{entityKey:h,K8:f.message}));Q=e;break a}throw f;}Q=void 0}return Q}if(h.type==="ENTITY_MUTATION_TYPE_UPDATE"){if(!h.payload)return g.Zx(new g.Ph("UPDATE entity mutation is missing a payload",{entityKey:h.entityKey})),e;Q=g.qT(h.payload);var y,C;return amu(e,Q,h.entityKey, h.payload[Q],(y=h.fieldMask)==null?void 0:(C=y.mergeOptions)==null?void 0:C.repeatedFieldsMergeOption)}return e},P); case "REPLACE_ENTITY":var l=v.payload;return ge(P,l.entityType,l.key,l.wj);case "REPLACE_ENTITIES":return Object.keys(v.payload).reduce(function(e,h){var z=v.payload[h];return Object.keys(z).reduce(function(m,Q){return ge(m,h,Q,z[Q])},e)},P); case "UPDATE_ENTITY":return l=v.payload,amu(P,l.entityType,l.key,l.wj,l.ts6);default:return P}}; kl=function(P,v,l){return P[v]?P[v][l]||null:null}; we=function(P){return window.Int32Array?new Int32Array(P):Array(P)}; JS=function(P){g.U.call(this);this.counter=[0,0,0,0];this.K=new Uint8Array(16);this.W=16;if(!ERD){var v,l=new Uint8Array(256),e=new Uint8Array(256);var h=1;for(v=0;v<256;v++)l[h]=v,e[v]=h,h^=h<<1^(h>>7&&283);$l=new Uint8Array(256);Id=we(256);Di=we(256);nt=we(256);Nj=we(256);for(var z=0;z<256;z++){h=z?e[255^l[z]]:0;h^=h<<1^h<<2^h<<3^h<<4;h=h&255^h>>>8^99;$l[z]=h;v=h<<1^(h>>7&&283);var m=v^h;Id[z]=v<<24|h<<16|h<<8|m;Di[z]=m<<24|Id[z]>>>8;nt[z]=h<<24|Di[z]>>>8;Nj[z]=h<<24|nt[z]>>>8}ERD=!0}h=we(44);for(l= 0;l<4;l++)h[l]=P[4*l]<<24|P[4*l+1]<<16|P[4*l+2]<<8|P[4*l+3];for(e=1;l<44;l++)P=h[l-1],l%4||(P=($l[P>>16&255]^e)<<24|$l[P>>8&255]<<16|$l[P&255]<<8|$l[P>>>24],e=e<<1^(e>>7&&283)),h[l]=h[l-4]^P;this.key=h}; ub=function(P,v){for(var l=0;l<4;l++)P.counter[l]=v[l*4]<<24|v[l*4+1]<<16|v[l*4+2]<<8|v[l*4+3];P.W=16}; WX2=function(P){for(var v=P.key,l=P.counter[0]^v[0],e=P.counter[1]^v[1],h=P.counter[2]^v[2],z=P.counter[3]^v[3],m=3;m>=0&&!(P.counter[m]=-~P.counter[m]);m--);for(var Q,t,y=4;y<40;)m=Id[l>>>24]^Di[e>>16&255]^nt[h>>8&255]^Nj[z&255]^v[y++],Q=Id[e>>>24]^Di[h>>16&255]^nt[z>>8&255]^Nj[l&255]^v[y++],t=Id[h>>>24]^Di[z>>16&255]^nt[l>>8&255]^Nj[e&255]^v[y++],z=Id[z>>>24]^Di[l>>16&255]^nt[e>>8&255]^Nj[h&255]^v[y++],l=m,e=Q,h=t;P=P.K;m=v[40];P[0]=$l[l>>>24]^m>>>24;P[1]=$l[e>>16&255]^m>>16&255;P[2]=$l[h>>8&255]^ m>>8&255;P[3]=$l[z&255]^m&255;m=v[41];P[4]=$l[e>>>24]^m>>>24;P[5]=$l[h>>16&255]^m>>16&255;P[6]=$l[z>>8&255]^m>>8&255;P[7]=$l[l&255]^m&255;m=v[42];P[8]=$l[h>>>24]^m>>>24;P[9]=$l[z>>16&255]^m>>16&255;P[10]=$l[l>>8&255]^m>>8&255;P[11]=$l[e&255]^m&255;m=v[43];P[12]=$l[z>>>24]^m>>>24;P[13]=$l[l>>16&255]^m>>16&255;P[14]=$l[e>>8&255]^m>>8&255;P[15]=$l[h&255]^m&255}; qj=function(){if(!Kt&&!g.vs){if(cT)return cT;var P;cT=(P=window.crypto)==null?void 0:P.subtle;var v,l,e;if(((v=cT)==null?0:v.importKey)&&((l=cT)==null?0:l.sign)&&((e=cT)==null?0:e.encrypt))return cT;cT=void 0}}; g.FY=function(P){this.Y=P}; g.AS=function(P){this.K=P}; Yl=function(P){this.Z=new Uint8Array(64);this.G=new Uint8Array(64);this.Y=0;this.T=new Uint8Array(64);this.K=0;this.Z.set(P);this.G.set(P);for(P=0;P<64;P++)this.Z[P]^=92,this.G[P]^=54;this.reset()}; Oyw=function(P,v,l){for(var e=P.j,h=P.W[0],z=P.W[1],m=P.W[2],Q=P.W[3],t=P.W[4],y=P.W[5],C=P.W[6],f=P.W[7],k,w,I,J=0;J<64;)J<16?(e[J]=I=v[l]<<24|v[l+1]<<16|v[l+2]<<8|v[l+3],l+=4):(k=e[J-2],w=e[J-15],I=e[J-7]+e[J-16]+((k>>>17|k<<15)^(k>>>19|k<<13)^k>>>10)+((w>>>7|w<<25)^(w>>>18|w<<14)^w>>>3),e[J]=I),k=f+bb[J]+I+((t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7))+(t&y^~t&C),w=((h>>>2|h<<30)^(h>>>13|h<<19)^(h>>>22|h<<10))+(h&z^h&m^z&m),f=k+w,Q+=k,J++,J<16?(e[J]=I=v[l]<<24|v[l+1]<<16|v[l+2]<<8|v[l+3],l+=4):(k= e[J-2],w=e[J-15],I=e[J-7]+e[J-16]+((k>>>17|k<<15)^(k>>>19|k<<13)^k>>>10)+((w>>>7|w<<25)^(w>>>18|w<<14)^w>>>3),e[J]=I),k=C+bb[J]+I+((Q>>>6|Q<<26)^(Q>>>11|Q<<21)^(Q>>>25|Q<<7))+(Q&t^~Q&y),w=((f>>>2|f<<30)^(f>>>13|f<<19)^(f>>>22|f<<10))+(f&h^f&z^h&z),C=k+w,m+=k,J++,J<16?(e[J]=I=v[l]<<24|v[l+1]<<16|v[l+2]<<8|v[l+3],l+=4):(k=e[J-2],w=e[J-15],I=e[J-7]+e[J-16]+((k>>>17|k<<15)^(k>>>19|k<<13)^k>>>10)+((w>>>7|w<<25)^(w>>>18|w<<14)^w>>>3),e[J]=I),k=y+bb[J]+I+((m>>>6|m<<26)^(m>>>11|m<<21)^(m>>>25|m<<7))+(m&Q^ ~m&t),w=((C>>>2|C<<30)^(C>>>13|C<<19)^(C>>>22|C<<10))+(C&f^C&h^f&h),y=k+w,z+=k,J++,J<16?(e[J]=I=v[l]<<24|v[l+1]<<16|v[l+2]<<8|v[l+3],l+=4):(k=e[J-2],w=e[J-15],I=e[J-7]+e[J-16]+((k>>>17|k<<15)^(k>>>19|k<<13)^k>>>10)+((w>>>7|w<<25)^(w>>>18|w<<14)^w>>>3),e[J]=I),k=t+bb[J]+I+((z>>>6|z<<26)^(z>>>11|z<<21)^(z>>>25|z<<7))+(z&m^~z&Q),w=((y>>>2|y<<30)^(y>>>13|y<<19)^(y>>>22|y<<10))+(y&C^y&f^C&f),I=f,f=Q,Q=I,I=C,C=m,m=I,I=y,y=z,z=I,t=h+k,h=k+w,J++;P.W[0]=h+P.W[0]|0;P.W[1]=z+P.W[1]|0;P.W[2]=m+P.W[2]|0;P.W[3]= Q+P.W[3]|0;P.W[4]=t+P.W[4]|0;P.W[5]=y+P.W[5]|0;P.W[6]=C+P.W[6]|0;P.W[7]=f+P.W[7]|0}; sn7=function(P){var v=new Uint8Array(32),l=64-P.K;P.K>55&&(l+=64);var e=new Uint8Array(l);e[0]=128;for(var h=P.Y*8,z=1;z<9;z++){var m=h%256;e[l-z]=m;h=(h-m)/256}P.update(e);for(l=0;l<8;l++)v[l*4]=P.W[l]>>>24,v[l*4+1]=P.W[l]>>>16&255,v[l*4+2]=P.W[l]>>>8&255,v[l*4+3]=P.W[l]&255;oRx(P);return v}; oRx=function(P){P.W=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225];P.j=[];P.j.length=64;P.Y=0;P.K=0}; r$D=function(P){this.W=P}; Mg6=function(P,v,l){P=new Yl(P.W);P.update(v);P.update(l);v=sn7(P);P.update(P.Z);P.update(v);v=sn7(P);P.reset();return v}; Tmu=function(P){this.K=P}; VgP=function(P,v,l,e){var h,z,m;return g.p(function(Q){switch(Q.W){case 1:if(P.W){Q.ac(2);break}return g.b(Q,e.importKey("raw",P.K,{name:"HMAC",hash:"SHA-256"},!1,["sign"]),3);case 3:P.W=Q.K;case 2:return h=new Uint8Array(v.length+l.length),h.set(v),h.set(l,v.length),z={name:"HMAC",hash:"SHA-256"},g.b(Q,e.sign(z,P.W,h),4);case 4:return m=Q.K,Q.return(new Uint8Array(m))}})}; dB2=function(P,v,l){P.G||(P.G=new r$D(P.K));return Mg6(P.G,v,l)}; PlW=function(P,v,l){var e,h;return g.p(function(z){if(z.W==1){e=qj();if(!e)return z.return(dB2(P,v,l));g.NP(z,3);return g.b(z,VgP(P,v,l,e),5)}if(z.W!=3)return z.return(z.K);h=g.Kx(z);g.j4(h);Kt=!0;return z.return(dB2(P,v,l))})}; lxw=function(P){for(var v="",l=0;l =1?P[P.length-1]:null;for(var e=g.N(P),h=e.next();!h.done;h=e.next())if(h=h.value,h.width&&h.height&&(l&&h.width>=v||!l&&h.height>=v))return h;for(v=P.length-1;v>=0;v--)if(l&&P[v].width||!l&&P[v].height)return P[v];return P[0]}; pt=function(){this.state=1;this.hk=null}; yG7=function(P,v,l,e,h,z){var m=m===void 0?"trayride":m;l?(P.As(2),g.kR(l,function(){if(window[m])t46(P,e,m,h);else{P.As(3);var Q=FV9(l),t=document.getElementById(Q);t&&(cZD(Q),t.parentNode.removeChild(t));g.j4(new g.Ph("Unable to load Botguard","from "+l))}},z)):v?(z=g.l5("SCRIPT"),v instanceof HQ?(z.textContent=EN(v),WQ(z)):z.textContent=v,z.nonce=a_(document),document.head.appendChild(z),document.head.removeChild(z),window[m]?t46(P,e,m,h):(P.As(4),g.j4(new g.Ph("Unable to load Botguard from JS")))): g.j4(new g.Ph("Unable to load VM; no url or JS provided"))}; t46=function(P,v,l,e){P.As(5);try{var h=new uK({program:v,globalName:l,J$:{disable:!g.YN("att_web_record_metrics"),TJ:"aGIf"}});h.KG.then(function(){P.As(6);e&&e(v)}); P.zS(h)}catch(z){P.As(7),z instanceof Error&&g.j4(z)}}; Lt=function(){var P=g.j9("yt.abuse.playerAttLoader");return P&&["bgvma","bgvmb","bgvmc"].every(function(v){return v in P})?P:null}; S2=function(){pt.apply(this,arguments)}; GI=function(){}; ClB=function(P,v,l){for(var e=!1,h=g.N(P.D0.entries()),z=h.next();!z.done;z=h.next())z=g.N(z.value).next().value,z.slotType==="SLOT_TYPE_PLAYER_BYTES"&&z.i$==="core"&&(e=!0);if(e){a:if(!l){P=g.N(P.D0.entries());for(l=P.next();!l.done;l=P.next())if(e=g.N(l.value),l=e.next().value,e=e.next().value,l.slotType==="SLOT_TYPE_IN_PLAYER"&&l.i$==="core"){l=e.layoutId;break a}l=void 0}l?v.xi(l):Iq("No triggering layout ID available when attempting to mute.")}}; XY=function(P,v){this.EY=P;this.xd=v}; BT=function(){}; ib=function(){}; gtw=function(P){g.U.call(this);var v=this;this.q2=P;this.W=new Map;U2(this,"commandExecutorCommand",function(l,e,h){fx2(v,l.commands,e,h)}); U2(this,"clickTrackingParams",function(){})}; kM6=function(P,v){U2(P,v.Ed(),function(l,e,h){v.qR(l,e,h)})}; U2=function(P,v,l){P.s$();P.W.get(v)&&g.Zx(Error("Extension name "+v+" already registered"));P.W.set(v,l)}; fx2=function(P,v,l,e){v=v===void 0?[]:v;P.s$();var h=[],z=[];v=g.N(v);for(var m=v.next();!m.done;m=v.next())m=m.value,g.a(m,wuD)||g.a(m,$au)?h.push(m):z.push(m);h=g.N(h);for(v=h.next();!v.done;v=h.next())Zi(P,v.value,l,e);z=g.N(z);for(h=z.next();!h.done;h=z.next())Zi(P,h.value,l,e)}; Zi=function(P,v,l,e){P.s$();v.loggingUrls&&Ixa(P,"loggingUrls",v.loggingUrls,l,e);v=g.N(Object.entries(v));for(var h=v.next();!h.done;h=v.next()){var z=g.N(h.value);h=z.next().value;z=z.next().value;h==="openPopupAction"?P.q2.get().Qu("innertubeCommand",{openPopupAction:z}):h==="confirmDialogEndpoint"?P.q2.get().Qu("innertubeCommand",{confirmDialogEndpoint:z}):Dau.hasOwnProperty(h)||Ixa(P,h,z,l,e)}}; Ixa=function(P,v,l,e,h){if((P=P.W.get(v))&&typeof P==="function")try{P(l,e,h)}catch(z){g.Zx(z)}else v=new g.Ph("Unhandled field",v),g.j4(v)}; j2=function(P,v,l){this.UF=P;this.W=v;this.VW=l}; ad=function(P){this.value=P}; HT=function(P){this.value=P}; E2=function(P){this.value=P}; WT=function(P){this.value=P}; O2=function(P){this.value=P}; od=function(P){this.value=P}; s2=function(P){this.value=P}; re=function(){ad.apply(this,arguments)}; Mj=function(P){this.value=P}; TI=function(P){this.value=P}; Vg=function(P){this.value=P}; de=function(P){this.value=P}; PJ=function(P){this.value=P}; vJ=function(P){this.value=P}; l1=function(P){this.value=P}; e$=function(P){this.value=P}; hu=function(P){this.value=P}; zH=function(P){this.value=P}; m1=function(){ad.apply(this,arguments)}; RR=function(P){this.value=P}; Qm=function(P){this.value=P}; tu=function(P){this.value=P}; ym=function(P){this.value=P}; CY=function(P){this.value=P}; fY=function(P){this.value=P}; gH=function(P){this.value=P}; ky=function(P){this.value=P}; wH=function(P){this.value=P}; $y=function(P){this.value=P}; IR=function(P){this.value=P}; Dj=function(P){this.value=P}; nY=function(P){this.value=P}; NS=function(P){this.value=P}; Ju=function(P){this.value=P}; u1=function(P){this.value=P}; KY=function(P){this.value=P}; cJ=function(P){this.value=P}; qS=function(P){this.value=P}; Fw=function(P){this.value=P}; Au=function(P){this.value=P}; Yy=function(P){this.value=P}; b1=function(P){this.value=P}; pY=function(P){this.value=P}; LY=function(P){this.value=P}; S$=function(P){this.value=P}; GH=function(P){this.value=P}; Xw=function(P){this.value=P}; BJ=function(P){this.value=P}; i1=function(P){this.value=P}; UK=function(P){this.value=P}; Zj=function(P){this.value=P}; j$=function(P){this.value=P}; aR=function(P){this.value=P}; HJ=function(P){this.value=P}; EK=function(P){this.value=P}; WJ=function(P){this.value=P}; OK=function(P){this.value=P}; oR=function(){ad.apply(this,arguments)}; sK=function(P){this.value=P}; rH=function(){ad.apply(this,arguments)}; MS=function(){ad.apply(this,arguments)}; TH=function(){ad.apply(this,arguments)}; Vm=function(){ad.apply(this,arguments)}; dH=function(){ad.apply(this,arguments)}; P2=function(P){this.value=P}; v2=function(P){this.value=P}; lq=function(P){this.value=P}; ey=function(P){this.value=P}; hT=function(P){this.value=P}; ms=function(P,v,l){if(l&&!l.includes(P.layoutType))return!1;v=g.N(v);for(l=v.next();!l.done;l=v.next())if(!zf(P.clientMetadata,l.value))return!1;return!0}; RD=function(){return""}; nta=function(P,v){switch(P){case "TRIGGER_CATEGORY_LAYOUT_EXIT_NORMAL":return 0;case "TRIGGER_CATEGORY_LAYOUT_EXIT_USER_SKIPPED":return 1;case "TRIGGER_CATEGORY_LAYOUT_EXIT_USER_MUTED":return 2;case "TRIGGER_CATEGORY_SLOT_EXPIRATION":return 3;case "TRIGGER_CATEGORY_SLOT_FULFILLMENT":return 4;case "TRIGGER_CATEGORY_SLOT_ENTRY":return 5;case "TRIGGER_CATEGORY_LAYOUT_EXIT_USER_INPUT_SUBMITTED":return 6;case "TRIGGER_CATEGORY_LAYOUT_EXIT_USER_CANCELLED":return 7;default:return v(P),8}}; Qf=function(P,v,l,e){e=e===void 0?!1:e;wo.call(this,P);this.FV=l;this.F5=e;this.args=[];v&&this.args.push(v)}; V=function(P,v,l,e){e=e===void 0?!1:e;wo.call(this,P);this.FV=l;this.F5=e;this.args=[];v&&this.args.push(v)}; tT=function(P){var v=new Map;P.forEach(function(l){v.set(l.getType(),l)}); this.W=v}; zf=function(P,v){return P.W.has(v)}; yf=function(P,v){P=P.W.get(v);if(P!==void 0)return P.get()}; CF=function(P){return Array.from(P.W.keys())}; fF=function(P,v,l){if(l&&l!==P.slotType)return!1;v=g.N(v);for(l=v.next();!l.done;l=v.next())if(!zf(P.clientMetadata,l.value))return!1;return!0}; JGD=function(P){var v;return((v=Nc6.get(P))==null?void 0:v.xJ)||"ADS_CLIENT_EVENT_TYPE_UNSPECIFIED"}; kO=function(P,v){var l={type:v.slotType,controlFlowManagerLayer:uiw.get(v.i$)||"CONTROL_FLOW_MANAGER_LAYER_UNSPECIFIED"};v.slotEntryTrigger&&(l.entryTriggerType=v.slotEntryTrigger.triggerType);v.slotPhysicalPosition!==1&&(l.slotPhysicalPosition=v.slotPhysicalPosition);if(P){l.debugData={slotId:v.slotId};if(P=v.slotEntryTrigger)l.debugData.slotEntryTriggerData=g3(P);P=v.slotFulfillmentTriggers;l.debugData.fulfillmentTriggerData=[];P=g.N(P);for(var e=P.next();!e.done;e=P.next())l.debugData.fulfillmentTriggerData.push(g3(e.value)); v=v.slotExpirationTriggers;l.debugData.expirationTriggerData=[];v=g.N(v);for(P=v.next();!P.done;P=v.next())l.debugData.expirationTriggerData.push(g3(P.value))}return l}; Kby=function(P,v){var l={type:v.layoutType,controlFlowManagerLayer:uiw.get(v.i$)||"CONTROL_FLOW_MANAGER_LAYER_UNSPECIFIED"};P&&(l.debugData={layoutId:v.layoutId});return l}; g3=function(P,v){var l={type:P.triggerType};v!=null&&(l.category=v);P.triggeringSlotId!=null&&(l.triggerSourceData||(l.triggerSourceData={}),l.triggerSourceData.associatedSlotId=P.triggeringSlotId);P.triggeringLayoutId!=null&&(l.triggerSourceData||(l.triggerSourceData={}),l.triggerSourceData.associatedLayoutId=P.triggeringLayoutId);return l}; cG6=function(P,v,l,e){v={opportunityType:v};P&&(e||l)&&(e=g.LC(e||[],function(h){return kO(P,h)}),v.debugData=Object.assign({},l&&l.length>0?{associatedSlotId:l}:{},e.length>0?{slots:e}:{})); return v}; $O=function(P,v){return function(l){return qc9(w3(P),v.slotId,v.slotType,v.slotPhysicalPosition,v.i$,v.slotEntryTrigger,v.slotFulfillmentTriggers,v.slotExpirationTriggers,l.layoutId,l.layoutType,l.i$)}}; qc9=function(P,v,l,e,h,z,m,Q,t,y,C){return{adClientDataEntry:{slotData:kO(P,{slotId:v,slotType:l,slotPhysicalPosition:e,i$:h,slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:Q,clientMetadata:new tT([])}),layoutData:Kby(P,{layoutId:t,layoutType:y,i$:C,layoutExitNormalTriggers:[],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],XJ:new Map,clientMetadata:new tT([]),ra:{}})}}}; DM=function(P){this.L0=P;P=Math.random();var v=this.L0.get();v=g.ID(v.J.N().experiments,"html5_debug_data_log_probability");v=Number.isFinite(v)&&v>=0&&v<=1?v:0;this.W=P 1){g.j4(new g.Ph("Exit already started",{current:P.currentState}));var l=!1}else l=!0;if(!l)return!1;P.currentState=2;P.W=v;return!0}; up=function(P){if(P.currentState!==2)return!1;P.currentState=3;return!0}; vUB=function(P,v){var l=new Map;P=g.N(P);for(var e=P.next();!e.done;e=P.next()){e=e.value;if(e.layoutType==="LAYOUT_TYPE_MEDIA")var h="v";else e.layoutType==="LAYOUT_TYPE_MEDIA_BREAK"?(h=yf(e.clientMetadata,"metadata_type_linked_in_player_layout_type"),h=h==="LAYOUT_TYPE_ENDCAP"||h==="LAYOUT_TYPE_VIDEO_INTERSTITIAL"?"e":h==="LAYOUT_TYPE_SURVEY"?"s":h==="LAYOUT_TYPE_VIDEO_INTERSTITIAL_BUTTONED_LEFT"?"si":"u"):h="u";l.set(e.layoutId,h);if(h==="u"){var z={};h=v;e=(z.c=e.layoutId,z);h.J.f0("uct",e)}}P= v.QZ();KW={contentCpn:P,Qy:l};e={};l=(e.ct=l.size,e.c=P,e);v.J.f0("acc",l)}; lSq=function(){KW={contentCpn:"",Qy:new Map}}; cz=function(P){var v;return(v=KW.Qy.get(P))!=null?v:"u"}; qg=function(P,v,l){P.J.f0(v,l);ebu(P)}; hbw=function(P){var v=P.layoutId,l=P.AP;if(P.jk){var e={};qg(P.UF,"slso",(e.ec=v,e.is=l,e.ctp=cz(v),e))}}; Fs=function(P){var v=P.layoutId,l=P.AP;if(P.jk){var e={};qg(P.UF,"slse",(e.ec=v,e.is=l,e.ctp=cz(v),e))}}; zbu=function(P){var v=P.layoutId,l=P.AP,e=P.UF;P.jk&&(P={},qg(e,"sleo",(P.xc=v,P.is=l,P.ctp=cz(v),P)),ebu(e))}; mQD=function(P){var v=P.cpn,l=P.UF;P=P.AP;var e=l.QZ(),h={};qg(l,"ce",(h.ec=v,h.ia=v!==e,h.r=KW.Qy.has(v),h.is=P,h.ctp=cz(v),h))}; ebu=function(P){if(P.QZ()!==KW.contentCpn){var v={};v=(v.c=KW.contentCpn,v);P.J.f0("ccm",v)}}; RbD=function(P){var v=P.cpn,l=P.UF;P=P.AP;var e=l.QZ(),h={};qg(l,"cx",(h.xc=v,h.ia=v!==e,h.r=KW.Qy.has(v),h.is=P,h.ctp=cz(v),h))}; Qq6=function(P){this.params=P;this.W=new Set}; tP9=function(P,v,l){if(!P.W.has(v)){P.W.add(v);var e={};P.params.bZ.Lq(v,Object.assign({},l,(e.p_ac=P.params.adCpn,e.p_isv=P.params.x5M&&P.params.zQ,e)))}}; Yq=function(P,v,l){if(AD(P.params.bZ.L0.get(),!0)){var e=l.flush,h={};tP9(P,v,(h.cts=l.currentTimeSec,h.f=e,h))}}; ymP=function(P,v){this.UF=P;this.L0=v}; bp=function(P){var v=[];if(P){P=g.N(Object.entries(P));for(var l=P.next();!l.done;l=P.next()){var e=g.N(l.value);l=e.next().value;e=e.next().value;e!==void 0&&(e=typeof e==="boolean"?""+ +e:(""+e).replace(/[:,=]/g,"_"),v.push(l+"."+e))}}return v.join(";")}; xq=function(P,v,l){v=v===void 0?{}:v;this.errorCode=P;this.details=v;this.severity=l===void 0?0:l}; pW=function(P){return P===1||P===2}; LW=function(P,v){v=v===void 0?0:v;if(P instanceof xq)return P;P=P&&P instanceof Error?P:Error(""+P);pW(v)?g.Zx(P):g.j4(P);return new xq(v===1?"player.fatalexception":"player.exception",{name:""+P.name,message:""+P.message},v)}; C4y=function(P,v){function l(){var e=g.bD.apply(0,arguments);P.removeEventListener("playing",l);v.apply(null,g.u(e))} P.addEventListener("playing",l)}; SL=function(){var P=g.j9("yt.player.utils.videoElement_");P||(P=g.l5("VIDEO"),g.ZB("yt.player.utils.videoElement_",P));return P}; Ga=function(P){var v=SL();return!!(v&&v.canPlayType&&v.canPlayType(P))}; Bz=function(P){if(/opus/.test(P)&&g.Xs&&!Sd("38")&&!g.VS())return!1;if(window.MediaSource&&window.MediaSource.isTypeSupported)return window.MediaSource.isTypeSupported(P);if(window.ManagedMediaSource&&window.ManagedMediaSource.isTypeSupported)return window.ManagedMediaSource.isTypeSupported(P);if(/webm/.test(P)&&!Ko9())return!1;P==='audio/mp4; codecs="mp4a.40.2"'&&(P='video/mp4; codecs="avc1.4d401f"');return!!Ga(P)}; fSB=function(P){try{var v=Bz('video/mp4; codecs="avc1.42001E"')||Bz('video/webm; codecs="vp9"');return(Bz('audio/mp4; codecs="mp4a.40.2"')||Bz('audio/webm; codecs="opus"'))&&(v||!P)||Ga('video/mp4; codecs="avc1.42001E, mp4a.40.2"')?null:"fmt.noneavailable"}catch(l){return"html5.missingapi"}}; ip=function(){var P=SL();return!(!P.webkitSupportsPresentationMode||typeof P.webkitSetPresentationMode!=="function")}; U6=function(){var P=SL();try{var v=P.muted;P.muted=!v;return P.muted!==v}catch(l){}return!1}; gUu=function(){var P;return((P=navigator.connection)==null?void 0:P.type)||""}; g.Z1=function(){GT.apply(this,arguments)}; jL=function(P,v,l,e,h,z,m){this.sampleRate=P===void 0?0:P;this.numChannels=v===void 0?0:v;this.spatialAudioType=l===void 0?"SPATIAL_AUDIO_TYPE_NONE":l;this.W=e===void 0?!1:e;this.G=h===void 0?0:h;this.K=z===void 0?0:z;this.audioQuality=m===void 0?"AUDIO_QUALITY_UNKNOWN":m}; E6=function(P,v,l,e,h,z,m,Q,t){this.width=P;this.height=v;this.quality=z||aS(P,v);this.W=g.Hz[this.quality];this.fps=l||0;this.stereoLayout=!h||e!=null&&e!=="UNKNOWN"&&e!=="RECTANGULAR"?0:h;this.projectionType=e?e==="EQUIRECTANGULAR"&&h===2?"EQUIRECTANGULAR_THREED_TOP_BOTTOM":e:"UNKNOWN";(P=m)||(P=g.Hz[this.quality],P===0?P="Autom\u00e1tica":(v=this.fps,l=this.projectionType,P=P.toString()+(l==="EQUIRECTANGULAR"||l==="EQUIRECTANGULAR_THREED_TOP_BOTTOM"||l==="MESH"?"s":"p")+(v>55?"60":v>49?"50":v> 39?"48":"")));this.qualityLabel=P;this.K=Q||"";this.primaries=t||""}; aS=function(P,v){var l=Math.max(P,v);P=Math.min(P,v);v=Wz[0];for(var e=0;e =Math.floor(z*16/9)*1.3||P>=z*1.3)return v;v=h}return"tiny"}; s6=function(P,v,l){l=l===void 0?{}:l;this.id=P;this.mimeType=v;l.FJ>0||(l.FJ=16E3);Object.assign(this,l);P=g.N(this.id.split(";"));this.itag=P.next().value;this.W=P.next().value;this.containerType=O6(v);this.dM=oS[this.itag]||""}; rl=function(P){return P.dM==="9"||P.dM==="("||P.dM==="9h"||P.dM==="(h"}; kL7=function(P){return P.dM==="H"||P.dM==="h"}; Mg=function(P){return P.dM==="9h"||P.dM==="(h"}; Ta=function(P){return P.dM==="1"||P.dM==="1h"}; VT=function(P){return P.dM==="mac3"||P.dM==="meac3"||P.dM==="m"||P.dM==="i"}; dl=function(P){return P.dM==="MAC3"||P.dM==="MEAC3"||P.dM==="M"||P.dM==="I"}; g.PB=function(P){return P.containerType===1}; w$W=function(P){return P.dM==="("||P.dM==="(h"||P.dM==="H"}; vB=function(P){return P.mimeType==="application/x-mpegURL"}; lf=function(P){P=P.mimeType;return P.includes("vtt")||P.includes("text/mp4")}; g.es=function(P,v){return{itag:+P.itag,lmt:v?0:P.lastModified,xtags:P.W||""}}; $QD=function(P){var v=navigator.mediaCapabilities;if(v==null||!v.decodingInfo||P.dM==="f")return Promise.resolve();var l={type:P.audio&&P.video?"file":"media-source"};P.video&&(l.video={contentType:P.mimeType,width:P.video.width||640,height:P.video.height||360,bitrate:P.FJ*8||1E6,framerate:P.video.fps||30});P.audio&&(l.audio={contentType:P.mimeType,channels:""+(P.audio.numChannels||2),bitrate:P.FJ*8||128E3,samplerate:P.audio.sampleRate||44100});return v.decodingInfo(l).then(function(e){P.K=e})}; hi=function(P){return/(opus|mp4a|dtse|ac-3|ec-3|iamf)/.test(P)}; zN=function(P){return/(vp9|vp09|vp8|avc1|av01)/.test(P)}; O6=function(P){return P.indexOf("/mp4")>=0?1:P.indexOf("/webm")>=0?2:P.indexOf("/x-flv")>=0?3:P.indexOf("/vtt")>=0?4:0}; mz=function(P,v,l,e,h,z){var m=new jL;v in g.Hz||(v="small");v==="light"&&(v="tiny");e&&h?(h=Number(h),e=Number(e)):(h=g.Hz[v],e=Math.round(h*16/9));z=new E6(e,h,0,null,void 0,v,z);P=unescape(P.replace(/"/g,'"'));return new s6(l,P,{audio:m,video:z})}; Rb=function(P){var v="id="+P.id;P.video&&(v+=", res="+P.video.qualityLabel);var l,e;return v+", byterate=("+((l=P.X5)==null?void 0:l.toFixed(0))+", "+((e=P.FJ)==null?void 0:e.toFixed(0))+")"}; Qu=function(P,v){return{start:function(l){return P[l]}, end:function(l){return v[l]}, length:P.length}}; ISa=function(P,v,l){for(var e=[],h=[],z=0;z =v)return l}catch(e){}return-1}; C0=function(P,v){return yu(P,v)>=0}; DQ6=function(P,v){if(!P)return NaN;v=yu(P,v);return v>=0?P.start(v):NaN}; f0=function(P,v){if(!P)return NaN;v=yu(P,v);return v>=0?P.end(v):NaN}; gJ=function(P){return P&&P.length?P.end(P.length-1):NaN}; kJ=function(P,v){P=f0(P,v);return P>=0?P-v:0}; wJ=function(P,v,l){for(var e=[],h=[],z=0;z l||(e.push(Math.max(v,P.start(z))-v),h.push(Math.min(l,P.end(z))-v));return Qu(e,h)}; ab=function(P,v,l,e){g.gA.call(this);var h=this;this.N2=P;this.start=v;this.end=l;this.isActive=e;this.appendWindowStart=0;this.appendWindowEnd=Infinity;this.timestampOffset=0;this.Qx={error:function(){!h.s$()&&h.isActive&&h.publish("error",h)}, updateend:function(){!h.s$()&&h.isActive&&h.publish("updateend",h)}}; this.N2.UW(this.Qx);this.i4=this.isActive}; Ea=function(P,v,l,e,h,z){g.gA.call(this);var m=this;this.mZ=P;this.aZ=v;this.id=l;this.containerType=e;this.dM=h;this.zQ=z;this.u6=this.Kp=this.lM=null;this.Tw=!1;this.appendWindowStart=this.timestampOffset=0;this.rS=Qu([],[]);this.cG=!1;this.WN=[];this.dT=HB?[]:void 0;this.Ub=function(t){return m.publish(t.type,m)}; var Q;if((Q=this.mZ)==null?0:Q.addEventListener)this.mZ.addEventListener("updateend",this.Ub),this.mZ.addEventListener("error",this.Ub)}; WB=function(){return window.SourceBuffer?!!SourceBuffer.prototype.changeType:!1}; Oa=function(P,v){this.JR=P;this.W=v===void 0?!1:v;this.K=!1}; ob=function(P,v,l){l=l===void 0?!1:l;g.U.call(this);this.mediaElement=P;this.u$=v;this.isView=l;this.T=0;this.Y=!1;this.Z=!0;this.X=0;this.callback=null;this.S=!1;this.u$||(this.aZ=this.mediaElement.YY());this.events=new g.Z1(this);g.Z(this,this.events);this.G=new Oa(this.u$?window.URL.createObjectURL(this.u$):this.aZ.webkitMediaSourceURL,!0);P=this.u$||this.aZ;Xz(this.events,P,["sourceopen","webkitsourceopen"],this.i6J);Xz(this.events,P,["sourceclose","webkitsourceclose"],this.Rg2);this.j={updateend:this.un}}; nUy=function(){return!!(window.MediaSource||window.ManagedMediaSource||window.WebKitMediaSource||window.HTMLMediaElement&&HTMLMediaElement.prototype.webkitSourceAddId)}; NX2=function(P,v){sa(P)?g.w5(function(){v(P)}):P.callback=v}; JmD=function(P,v,l){if(rJ){var e;M6(P.mediaElement,{l:"mswssb",sr:(e=P.mediaElement.M5)==null?void 0:e.Pf()},!1);v.UW(P.j,P);l.UW(P.j,P)}P.W=v;P.K=l;g.Z(P,v);g.Z(P,l)}; u8W=function(P,v,l,e){e=v.mimeType+(e===void 0?"":e);var h=l.mimeType;v=v.dM;l=l.dM;var z;P.Wg=(z=P.u$)==null?void 0:z.addSourceBuffer(h);var m;P.QW=e.split(";")[0]==="fakesb"?void 0:(m=P.u$)==null?void 0:m.addSourceBuffer(e);P.aZ&&(P.aZ.webkitSourceAddId("0",h),P.aZ.webkitSourceAddId("1",e));z=new Ea(P.Wg,P.aZ,"0",O6(h),l,!1);e=new Ea(P.QW,P.aZ,"1",O6(e),v,!0);JmD(P,z,e)}; TN=function(P){return!!P.W||!!P.K}; sa=function(P){try{return Vu(P)==="open"}catch(v){return!1}}; Vu=function(P){if(P.u$)return P.u$.readyState;switch(P.aZ.webkitSourceState){case P.aZ.SOURCE_OPEN:return"open";case P.aZ.SOURCE_ENDED:return"ended";default:return"closed"}}; dJ=function(){return!(!window.MediaSource||!window.MediaSource.isTypeSupported)||window.ManagedMediaSource}; KAP=function(P){sa(P)&&(P.u$?P.u$.endOfStream():P.aZ.webkitSourceEndOfStream(P.aZ.EOS_NO_ERROR))}; cmW=function(P,v,l,e){if(!P.W||!P.K)return null;var h=P.W.isView()?P.W.N2:P.W,z=P.K.isView()?P.K.N2:P.K,m=new ob(P.mediaElement,P.u$,!0);m.G=P.G;JmD(m,new ab(h,v,l,e),new ab(z,v,l,e));sa(P)||P.W.I3(P.W.fh());return m}; qIy=function(P){var v;(v=P.W)==null||v.Pj();var l;(l=P.K)==null||l.Pj();P.Z=!1}; PP=function(){var P=this;this.xX=this.wJ=LDw;this.promise=new g.Jt(function(v,l){P.wJ=v;P.xX=l})}; vP=function(){g.U.call(this);this.lW=!1;this.JR=null;this.j=this.T=!1;this.Y=new g.zQ;this.M5=null;g.Z(this,this.Y)}; lm=function(P){P=P.Ju();return P.length<1?NaN:P.end(P.length-1)}; FAy=function(P){!P.K&&nUy()&&(P.G?P.G.then(function(){return FAy(P)}):P.Dc()||(P.K=P.fg()))}; Amx=function(P){P.K&&(P.K.dispose(),P.K=void 0)}; M6=function(P,v,l){var e;((e=P.M5)==null?0:e.vK())&&P.M5.f0("rms",v,l===void 0?!1:l)}; YIB=function(P,v,l){P.isPaused()||P.getCurrentTime()>v||l>10||(P.play(),g.KG(function(){YIB(P,P.getCurrentTime(),l+1)},500))}; b2q=function(P,v){P.JR&&P.JR.ZA(v)||(P.JR&&P.JR.dispose(),P.JR=v)}; eq=function(P){return kJ(P.AB(),P.getCurrentTime())}; xQy=function(P,v){if(P.lY()===0||P.hasError())return!1;var l=P.getCurrentTime()>0;return v>=0&&(P=P.Ju(),P.length||!l)?C0(P,v):l}; hU=function(P){P.Dc()&&(P.M5&&P.M5.Nm("rs_s"),Ps&&P.getCurrentTime()>0&&P.seekTo(0),P.MY(),P.load(),b2q(P,null));delete P.G}; z1=function(P){switch(P.nJ()){case 2:return"progressive.net.retryexhausted";case 3:return P=P.fX(),(P==null?0:P.includes("MEDIA_ERR_CAPABILITY_CHANGED"))||p$9&&(P==null?0:P.includes("audio_output_change"))?"capability.changed":"fmt.decode";case 4:return"fmt.unplayable";case 5:return"drm.unavailable";case 1E3:return"capability.changed";default:return null}}; g.mQ=function(P,v,l){this.xF=v===void 0?null:v;this.seekSource=l===void 0?null:l;this.state=P||64}; RV=function(P,v,l){l=l===void 0?!1:l;return LAw(P,v.getCurrentTime(),(0,g.Gz)(),eq(v),l)}; Q$=function(P,v,l,e){if(!(v===P.state&&l===P.xF&&e===P.seekSource||v!==void 0&&(v&128&&!l||v&2&&v&16))){var h;if(h=v)h=v||P.state,h=!!(h&16||h&32);P=new g.mQ(v,l,h?e?e:P.seekSource:null)}return P}; tU=function(P,v,l){return Q$(P,P.state|v,null,l===void 0?null:l)}; y$=function(P,v){return Q$(P,P.state&~v,null,null)}; CM=function(P,v,l,e){return Q$(P,(P.state|v)&~l,null,e===void 0?null:e)}; g.M=function(P,v){return!!(P.state&v)}; g.fM=function(P,v){return v.state===P.state&&v.xF===P.xF}; gZ=function(P){return P.isPlaying()&&!g.M(P,16)&&!g.M(P,32)}; kG=function(P){return g.M(P,128)?-1:g.M(P,2)?0:g.M(P,2048)?3:g.M(P,64)?-1:g.M(P,1)&&!g.M(P,32)?3:g.M(P,8)?1:g.M(P,4)?2:-1}; $G=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I,J,K){g.U.call(this);var q=this;this.F6=P;this.slot=v;this.layout=l;this.VW=e;this.GG=h;this.vg=z;this.t5=m;this.cR=Q;this.tR=t;this.u3=y;this.position=f;this.T=k;this.L0=w;this.UN=I;this.jd=J;this.context=K;this.RY=!0;this.Z=!1;this.D5="not_rendering";this.K=!1;this.G=new Ng;P=yf(this.layout.clientMetadata,"metadata_type_ad_placement_config");this.e2=new Le(l.XJ,this.VW,P,l.layoutId);var A;P=((A=wZ(this))==null?void 0:A.progressCommands)||[];this.Y=new xDw(t, P,l.layoutId,function(){return q.Wd()}); this.W=new Qq6({adCpn:this.layout.layoutId,bZ:K.bZ,x5M:this.UN,zQ:this.layout.layoutType==="LAYOUT_TYPE_MEDIA"})}; IV=function(P){return{layoutId:P.QR(),AP:P.UN,UF:P.vg.get(),jk:P.QI()}}; Dk=function(P,v){return v.layoutId!==P.layout.layoutId?(P.F6.Cb(P.slot,v,new Qf("Tried to start rendering an unknown layout, this adapter requires LayoutId: "+P.layout.layoutId+("and LayoutType: "+P.layout.layoutType),void 0,"ADS_CLIENT_ERROR_MESSAGE_UNKNOWN_LAYOUT"),"ADS_CLIENT_ERROR_TYPE_ENTER_LAYOUT_FAILED"),!1):!0}; nM=function(P){P.D5="rendering_start_requested";P.u3(-1)}; wZ=function(P){return yf(P.layout.clientMetadata,"METADATA_TYPE_INTERACTIONS_AND_PROGRESS_LAYOUT_COMMANDS")}; SIw=function(P){Iq("Received layout exit signal when not in layout exit flow.",P.slot,P.layout)}; GLx=function(P){var v;return((v=Nk(P.vg.get(),2))==null?void 0:v.clientPlaybackNonce)||""}; JU=function(P,v){switch(v){case "normal":P.AR("complete");break;case "skipped":P.AR("skip");break;case "abandoned":UA(P.e2,"impression")&&P.AR("abandon")}}; um=function(P,v){P.Z||(v=new g.DS(v.state,new g.mQ),P.Z=!0);return v}; KM=function(P,v){IS(v)?P.u3(1):g.NQ(v,4)&&!g.NQ(v,2)&&P.R1();n2(v,4)<0&&!(n2(v,2)<0)&&P.ea()}; X$a=function(P){P.position===0&&(P.cR.get(),P=yf(P.layout.clientMetadata,"metadata_type_ad_placement_config").kind,P={adBreakType:cP(P)},WI("ad_bl"),g.On(P))}; qk=function(P,v){Bb(P.e2,v,!P.K)}; i22=function(P){var v;return(((v=wZ(P))==null?void 0:v.progressCommands)||[]).findIndex(function(l){return!!g.a(l==null?void 0:l.command,BXx)})!==-1}; FH=function(P,v){var l=yf(P.clientMetadata,"metadata_type_eligible_for_ssap");return l===void 0?(Iq("Expected SSAP eligibility in PlayerBytes factory",P),!1):v.QI(l)}; AU=function(P,v){if(!Pb(v.get(),"html5_ssap_pass_transition_reason"))return 3;switch(P){case "skipped":case "muted":case "user_input_submitted":return 3;case "normal":return 2;case "error":return Iq("Unexpected error from cPACF during rendering"),6;case "abandoned":return 5;case "user_cancelled":case "unknown":return Iq("Unexpected layout exit reason",void 0,void 0,{layoutExitReason:P}),3;default:m9(P,"unknown layoutExitReason")}}; UQP=function(P){Iq("getExitReason: unexpected reason",void 0,void 0,{reason:P})}; YG=function(P,v){if(Pb(v.get(),"html5_ssap_pass_transition_reason"))switch(P){case 2:return"normal";case 4:case 6:case 7:return"error";case 5:return UQP(P),"abandoned";case 3:case 1:return UQP(P),"error";default:m9(P,"unexpected transition reason")}else switch(P){case 2:return"normal";case 4:return"error";case 5:case 3:case 1:case 6:case 7:return Iq("getExitReason: unexpected reason",void 0,void 0,{reason:P}),"error";default:m9(P,"unexpected transition reason")}}; bm=function(P,v,l){sn(P,l)||Md(P,v,l);sn(P,"video_to_ad")||Md(P,v,"video_to_ad");sn(P,"ad_to_video")||Md(P,v,"ad_to_video");sn(P,"ad_to_ad")||Md(P,v,"ad_to_ad")}; xG=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I,J,K,q){$G.call(this,P,v,l,e,h,z,m,Q,y,C,f,k,w,I,J,K,q);var A=this;this.q2=t;this.Xp=f;this.g$=!0;this.oB=this.CY=0;this.El=n7(function(){hbw(IV(A));A.F6.eS(A.slot,A.layout)}); this.HG=n7(function(){zbu(IV(A));A.D5!=="rendering_stop_requested"&&A.Xp(A);A.layoutExitReason?A.F6.Js(A.slot,A.layout,A.layoutExitReason):SIw(A)}); this.uC=new g.Y9(200);this.uC.listen("tick",function(){A.sb()}); g.Z(this,this.uC)}; LM=function(P){P.oB=Date.now();pM(P,P.CY);P.uC.start()}; Z2y=function(P){P.CY=P.Wd();P.il(P.CY/1E3,!0);pM(P,P.CY)}; pM=function(P,v){v={current:v/1E3,duration:P.Wd()/1E3};P.q2.get().Qu("onAdPlaybackProgress",v)}; Sq=function(P){xG.call(this,P.F6,P.slot,P.pX,P.VW,P.GG,P.vg,P.t5,P.cR,P.q2,P.tR,P.u3,P.Xp,P.AA,P.md,P.L0,P.UN,P.jd,P.context)}; G1=function(P){xG.call(this,P.F6,P.slot,P.pX,P.VW,P.GG,P.vg,P.t5,P.cR,P.q2,P.tR,P.u3,P.Xp,P.AA,P.md,P.L0,P.UN,P.jd,P.context)}; XH=function(){G1.apply(this,arguments)}; jqw=function(P){return FH(P.slot,P.L0.get())?new XH(P):new Sq(P)}; UC=function(P){$G.call(this,P.callback,P.slot,P.pX,P.VW,P.GG,P.vg,P.t5,P.cR,P.tR,P.u3,P.Xp,P.AA,P.md,P.L0,P.UN,P.jd,P.context);var v=this;this.adCpn="";this.RF=0;this.Lc=!1;this.gD=0;this.El=n7(function(){hbw(IV(v));v.F6.eS(v.slot,v.layout)}); this.HG=n7(function(){zbu(IV(v));v.D5!=="rendering_stop_requested"&&v.Xp(v);v.layoutExitReason?v.F6.Js(v.slot,v.layout,v.layoutExitReason):SIw(v)}); this.Pl=P.Pl;this.RV=P.RV;this.nh=P.nh;this.q2=P.q2;this.wz=P.wz;this.Xp=P.Xp;if(!this.QI()){Pb(this.L0.get(),"html5_disable_media_load_timeout")||(this.P6=new g.mr(function(){v.Nt("load_timeout",new Qf("Media layout load timeout.",{},"ADS_CLIENT_ERROR_MESSAGE_MEDIA_LAYOUT_LOAD_TIMEOUT",!0),"ADS_CLIENT_ERROR_TYPE_ENTER_LAYOUT_FAILED")},1E4)); P=BP(this.L0.get());var l=im(this.L0.get());P&&l&&(this.Lx=new g.mr(function(){var e=yf(v.layout.clientMetadata,"metadata_type_preload_player_vars");e&&v.RV.get().J.preloadVideoByPlayerVars(e,2,300)}))}}; H2u=function(P,v){var l=yf(v.clientMetadata,"metadata_type_ad_video_id"),e=yf(v.clientMetadata,"metadata_type_legacy_info_card_vast_extension");l&&e&&P.wz.get().J.N().Hg.add(l,{Zk:e});(v=yf(v.clientMetadata,"metadata_type_sodar_extension_data"))&&Wb6(P.Pl.get(),v);aS6(P.t5.get(),!1)}; EUD=function(P){aS6(P.t5.get(),!0);var v;((v=P.shrunkenPlayerBytesConfig)==null?0:v.shouldRequestShrunkenPlayerBytes)&&P.t5.get().bR(!1)}; WAW=function(P){var v=yf(P.xY().clientMetadata,"metadata_type_player_bytes_slot_metadata");v===void 0&&Iq("PlayerBytesSlotMetadata is not filled",P.xY(),P.xf());return(v==null?void 0:v.NR)===!0}; Zk=function(){UC.apply(this,arguments)}; jq=function(){Zk.apply(this,arguments)}; O2x=function(P){return jqw(Object.assign({},P,{F6:P.callback,u3:function(){}}))}; oUw=function(P){return new UC(Object.assign({},P,{u3:function(v){P.q2.get().Qu("onAdIntroStateChange",v)}}))}; sq9=function(P){function v(l){P.q2.get().LS(l)} return FH(P.slot,P.L0.get())?new jq(Object.assign({},P,{u3:v})):new UC(Object.assign({},P,{u3:v}))}; aV=function(P){for(var v=P.pX,l=["METADATA_TYPE_MEDIA_BREAK_LAYOUT_DURATION_MILLISECONDS"],e=g.N(SI()),h=e.next();!h.done;h=e.next())l.push(h.value);if(lp(v,{OQ:l,y4:["LAYOUT_TYPE_MEDIA_BREAK"]}))return O2x(P);v=P.pX;l=["metadata_type_player_vars","metadata_type_player_bytes_callback_ref"];e=g.N(SI());for(h=e.next();!h.done;h=e.next())l.push(h.value);if(lp(v,{OQ:l,y4:["LAYOUT_TYPE_MEDIA"]}))return zf(P.pX.clientMetadata,"metadata_type_ad_intro")?oUw(P):sq9(P)}; MPy=function(P){var v=yf(P.clientMetadata,"metadata_type_ad_placement_config").kind,l=yf(P.clientMetadata,"metadata_type_linked_in_player_layout_type");return{cpn:P.layoutId,adType:rm6(l),adBreakType:cP(v)}}; cP=function(P){switch(P){case "AD_PLACEMENT_KIND_START":return"LATENCY_AD_BREAK_TYPE_PREROLL";case "AD_PLACEMENT_KIND_MILLISECONDS":case "AD_PLACEMENT_KIND_COMMAND_TRIGGERED":case "AD_PLACEMENT_KIND_CUE_POINT_TRIGGERED":return"LATENCY_AD_BREAK_TYPE_MIDROLL";case "AD_PLACEMENT_KIND_END":return"LATENCY_AD_BREAK_TYPE_POSTROLL";default:return"LATENCY_AD_BREAK_TYPE_UNKNOWN"}}; rm6=function(P){switch(P){case "LAYOUT_TYPE_ENDCAP":return"adVideoEnd";case "LAYOUT_TYPE_SURVEY":return"surveyAd";case "LAYOUT_TYPE_VIDEO_INTERSTITIAL_BUTTONED_LEFT":return"surveyInterstitialAd";default:return"unknown"}}; TX6=function(P){try{return new HP(P.qJ,P.slot,P.layout,P.kC,P.Wl,P.vg,P.GK,P.RV,P.SS,P.t5,P.QZJ,P)}catch(v){}}; HP=function(P,v,l,e,h,z,m,Q,t,y,C,f){g.U.call(this);this.qJ=P;this.slot=v;this.layout=l;this.kC=e;this.Wl=h;this.vg=z;this.GK=m;this.RV=Q;this.SS=t;this.t5=y;this.params=f;this.RY=!0;P=aV(C);if(!P)throw Error("Invalid params for sublayout");this.yD=P}; VP9=function(){this.W=1;this.K=new Ng}; EC=function(P,v,l,e,h,z,m,Q,t,y,C,f,k){g.U.call(this);this.callback=P;this.vg=v;this.GK=l;this.RV=e;this.t5=h;this.cR=z;this.Sk=m;this.slot=Q;this.layout=t;this.kC=y;this.k5=C;this.SS=f;this.L0=k;this.RY=!0;this.Xx=!1;this.oZ=[];this.X0=-1;this.GU=!1;this.GR=new VP9}; dQw=function(P){var v;return(v=P.layout.xq)!=null?v:yf(P.layout.clientMetadata,"metadata_type_sub_layouts")}; WP=function(P){return{UF:P.vg.get(),AP:!1,jk:P.QI()}}; Po2=function(P,v,l){if(P.Mj()===P.oZ.length-1){var e,h;Iq("Unexpected skip requested during the last sublayout",(e=P.I0())==null?void 0:e.xY(),(h=P.I0())==null?void 0:h.xf(),{requestingSlot:v,requestingLayout:l})}}; vSx=function(P,v,l){return l.layoutId!==OC(P,v,l)?(Iq("onSkipRequested for a PlayerBytes layout that is not currently active",P.xY(),P.xf()),!1):!0}; lfa=function(P){P.Mj()===P.oZ.length-1&&Iq("Unexpected skip with target requested during the last sublayout")}; ekx=function(P,v,l){return l.renderingContent===void 0&&l.layoutId!==OC(P,v,l)?(Iq("onSkipWithAdPodSkipTargetRequested for a PlayerBytes layout that is not currently active",P.xY(),P.xf(),{requestingSlot:v,requestingLayout:l}),!1):!0}; hka=function(P,v,l,e){var h=yf(v.xf().clientMetadata,"metadata_type_ad_pod_skip_target");if(h&&h>0&&h 0)){Iq("Invalid index for playLayoutAtIndexOrExit when no ad has played yet.",P.slot,P.layout,{indexToPlay:v,layoutId:P.layout.layoutId});break a}P.X0=v;v=P.I0();if(P.Mj()>0&&!P.QI()){var l=P.cR.get();l.K=!1;var e={};l.W&&l.videoId&&(e.cttAuthInfo={token:l.W,videoId:l.videoId});o5("ad_to_ad",e)}P.Db(v)}}; Mk=function(P){EC.call(this,P.qJ,P.vg,P.GK,P.RV,P.t5,P.cR,P.Sk,P.slot,P.layout,P.kC,P.k5,P.SS,P.L0)}; Rkw=function(P){(P=P.I0())&&P.ZI()}; T1=function(P){EC.call(this,P.qJ,P.vg,P.GK,P.RV,P.t5,P.cR,P.Sk,P.slot,P.layout,P.kC,P.k5,P.SS,P.L0);this.Kb=void 0}; Q5u=function(P,v){P.AO()&&!up(P.GR.K)||P.callback.Js(P.slot,P.layout,v)}; V$=function(P){return Pb(P.L0.get(),"html5_ssap_pass_transition_reason")}; tew=function(P,v,l){v.kd().currentState<2&&(l=YG(l,P.L0),v.d9(v.xf(),l));l=v.kd().W;P.B7(P.slot,v.xf(),l)}; yHu=function(P,v){if(P.GR.K.currentState<2){var l=YG(v,P.L0);l==="error"?P.callback.Cb(P.slot,P.layout,new Qf("Player transition with error during SSAP composite layout.",{playerErrorCode:"non_video_expired",transitionReason:v},"ADS_CLIENT_ERROR_MESSAGE_PLAYER_TRANSITION_WITH_ERROR"),"ADS_CLIENT_ERROR_TYPE_ERROR_DURING_RENDERING"):rZ(P.k5,P.layout,l)}}; dZ=function(P,v,l){v.kd().currentState>=2||(v.d9(v.xf(),l),up(v.kd())&&(Sy(P.Sk,P.slot,v.xf(),l),P.Kb=void 0))}; Coq=function(P,v){P.GR.W===2&&v!==P.QZ()&&Iq("onClipEntered: unknown cpn",P.slot,P.layout,{cpn:v})}; ff9=function(P,v){var l=P.I0();if(l){var e=l.xf().layoutId,h=P.Mj()+1;P.AO()?dZ(P,l,v):l.d9(l.xf(),v);h>=0&&h h&&m.v4(C,h-e);return C}; JHu=function(P,v,l){var e=yf(v.clientMetadata,"metadata_type_sodar_extension_data");if(e)try{Wb6(l,e)}catch(h){Iq("Unexpected error when loading Sodar",P,v,{error:h})}}; u5x=function(P,v,l,e,h,z,m){m0(P,v,new g.DS(l,new g.mQ),e,h,m,!1,z)}; m0=function(P,v,l,e,h,z,m,Q){m=m===void 0?!0:m;IS(l)&&D1(h,0,null)&&(!UA(P,"impression")&&Q&&Q(),P.AR("impression"));UA(P,"impression")&&(g.NQ(l,4)&&!g.NQ(l,2)&&P.qN("pause"),n2(l,4)<0&&!(n2(l,2)<0)&&P.qN("resume"),g.NQ(l,16)&&h>=.5&&P.qN("seek"),m&&g.NQ(l,2)&&R2(P,l.state,v,e,h,z))}; R2=function(P,v,l,e,h,z,m,Q){UA(P,"impression")&&(z?(z=h-e,z=z>=-1&&z<=2):z=Math.abs(e-h)<=1,Qt(P,v,z?e:h,l,e,m,Q&&z),z&&P.AR("complete"))}; Qt=function(P,v,l,e,h,z,m){ic(P,l*1E3,m);h<=0||l<=0||(v==null?0:g.M(v,16))||(v==null?0:g.M(v,32))||(D1(l,h*.25,e)&&(z&&!UA(P,"first_quartile")&&z("first"),P.AR("first_quartile")),D1(l,h*.5,e)&&(z&&!UA(P,"midpoint")&&z("second"),P.AR("midpoint")),D1(l,h*.75,e)&&(z&&!UA(P,"third_quartile")&&z("third"),P.AR("third_quartile")))}; KvD=function(P,v){UA(P,"impression")&&P.qN(v?"fullscreen":"end_fullscreen")}; cHw=function(P){UA(P,"impression")&&P.qN("clickthrough")}; qnq=function(P){P.qN("active_view_measurable")}; FvD=function(P){UA(P,"impression")&&!UA(P,"seek")&&P.qN("active_view_fully_viewable_audible_half_duration")}; AHD=function(P){UA(P,"impression")&&!UA(P,"seek")&&P.qN("active_view_viewable")}; Yn6=function(P){UA(P,"impression")&&!UA(P,"seek")&&P.qN("audio_audible")}; bsx=function(P){UA(P,"impression")&&!UA(P,"seek")&&P.qN("audio_measurable")}; xd2=function(P,v,l,e,h,z,m,Q,t,y,C,f){this.callback=P;this.slot=v;this.layout=l;this.GK=e;this.e2=h;this.t5=z;this.u7=m;this.GG=Q;this.Pl=t;this.L0=y;this.VW=C;this.vg=f;this.g$=!0;this.lq=this.D5=null;this.adCpn=void 0;this.W=!1}; pIa=function(P,v,l){var e;z$(P.VW.get(),"ads_qua","cpn."+yf(P.layout.clientMetadata,"metadata_type_content_cpn")+";acpn."+((e=Nk(P.vg.get(),2))==null?void 0:e.clientPlaybackNonce)+";qt."+v+";clr."+l)}; Lv6=function(P,v){var l,e;z$(P.VW.get(),"ads_imp","cpn."+yf(P.layout.clientMetadata,"metadata_type_content_cpn")+";acpn."+((l=Nk(P.vg.get(),2))==null?void 0:l.clientPlaybackNonce)+";clr."+v+";skp."+!!g.a((e=yf(P.layout.clientMetadata,"metadata_type_instream_ad_player_overlay_renderer"))==null?void 0:e.skipOrPreviewRenderer,tX))}; Cl=function(P){return P.L0.get().J.N().experiments.l$("increase_completion_ping_firing_window")&&Nk(P.vg.get(),1).DR}; fl=function(P){return{enterMs:yf(P.clientMetadata,"metadata_type_layout_enter_ms"),exitMs:yf(P.clientMetadata,"metadata_type_layout_exit_ms")}}; gU=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w){vE.call(this,P,v,l,e,h,m,Q,t,y,f);this.u7=z;this.Pl=C;this.GG=k;this.L0=w;this.lq=this.D5=null}; Snw=function(P,v){var l;z$(P.VW.get(),"ads_imp","acpn."+((l=Nk(P.vg.get(),2))==null?void 0:l.clientPlaybackNonce)+";clr."+v)}; Gxx=function(P,v,l){var e;z$(P.VW.get(),"ads_qua","cpn."+yf(P.layout.clientMetadata,"metadata_type_content_cpn")+";acpn."+((e=Nk(P.vg.get(),2))==null?void 0:e.clientPlaybackNonce)+";qt."+v+";clr."+l)}; kW=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I,J,K,q,A,x,S){this.SS=P;this.kC=v;this.k5=l;this.vg=e;this.GK=h;this.t5=z;this.VW=m;this.u7=Q;this.oo=t;this.GG=y;this.Pl=C;this.RV=f;this.nh=k;this.cR=w;this.q2=I;this.tR=J;this.wz=K;this.L0=q;this.W=A;this.context=x;this.jd=S}; wU=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I,J,K,q){this.SS=P;this.kC=v;this.k5=l;this.VW=e;this.GG=h;this.Pl=z;this.RV=m;this.vg=Q;this.t5=t;this.nh=y;this.cR=C;this.q2=f;this.tR=k;this.wz=w;this.L0=I;this.GK=J;this.context=K;this.jd=q}; XIw=function(P,v,l,e){fv.call(this,"survey-interstitial",P,v,l,e)}; $W=function(P,v,l,e,h){cb.call(this,l,P,v,e);this.VW=h;P=yf(v.clientMetadata,"metadata_type_ad_placement_config");this.e2=new Le(v.XJ,h,P,v.layoutId)}; I2=function(P){return Math.round(P.width)+"x"+Math.round(P.height)}; nl=function(P,v,l){l=l===void 0?Dt:l;l.width P.width*P.height*.2)return{Zr:3,IE:501,errorMessage:"ad("+I2(l)+") to container("+I2(P)+") ratio exceeds limit."};if(l.height>P.height/3-v)return{Zr:3,IE:501,errorMessage:"ad("+I2(l)+") covers container("+I2(P)+") center."}}; B9W=function(P,v){var l=yf(P.clientMetadata,"metadata_type_ad_placement_config");return new Le(P.XJ,v,l,P.layoutId)}; Ni=function(P){return yf(P.clientMetadata,"metadata_type_invideo_overlay_ad_renderer")}; JX=function(P,v,l,e){fv.call(this,"invideo-overlay",P,v,l,e);this.interactionLoggingClientData=e}; uz=function(P,v,l,e,h,z,m,Q,t,y,C,f){cb.call(this,z,P,v,h);this.VW=l;this.Y=m;this.t5=Q;this.tR=t;this.L0=y;this.T=C;this.Z=f;this.e2=B9W(v,l)}; isw=function(){var P=["metadata_type_invideo_overlay_ad_renderer"];SI().forEach(function(v){P.push(v)}); return{OQ:P,y4:["LAYOUT_TYPE_IN_VIDEO_TEXT_OVERLAY","LAYOUT_TYPE_IN_VIDEO_ENHANCED_TEXT_OVERLAY"]}}; Kl=function(P,v,l,e,h,z,m,Q,t,y,C,f,k){cb.call(this,z,P,v,h);this.VW=l;this.Y=m;this.S=Q;this.t5=t;this.tR=y;this.L0=C;this.T=f;this.Z=k;this.e2=B9W(v,l)}; Ud7=function(){for(var P=["metadata_type_invideo_overlay_ad_renderer"],v=g.N(SI()),l=v.next();!l.done;l=v.next())P.push(l.value);return{OQ:P,y4:["LAYOUT_TYPE_IN_VIDEO_IMAGE_OVERLAY"]}}; cE=function(P){this.t5=P;this.W=!1}; Zsu=function(P,v,l){fv.call(this,"survey",P,{},v,l)}; qi=function(P,v,l,e,h,z,m){cb.call(this,l,P,v,e);this.Y=h;this.t5=z;this.L0=m}; j5P=function(P,v,l,e,h,z,m,Q,t,y){this.M2=P;this.t5=v;this.VW=l;this.Y=e;this.GG=h;this.K=z;this.G=m;this.tR=Q;this.L0=t;this.W=y}; afx=function(P,v,l,e,h,z,m,Q,t,y){this.M2=P;this.t5=v;this.VW=l;this.Y=e;this.GG=h;this.K=z;this.G=m;this.tR=Q;this.L0=t;this.W=y}; Fg=function(P,v,l,e,h,z,m,Q,t,y){QT.call(this,P,v,l,e,h,z,m,t);this.Bs=Q;this.vg=y}; Hs2=function(){var P=sra();P.OQ.push("metadata_type_ad_info_ad_metadata");return P}; ESw=function(P,v,l,e,h,z,m){this.M2=P;this.t5=v;this.VW=l;this.K=e;this.Bs=h;this.W=z;this.vg=m}; Wvu=function(P,v,l,e,h,z,m,Q){this.M2=P;this.t5=v;this.VW=l;this.K=e;this.Bs=h;this.W=z;this.L0=m;this.vg=Q}; AX=function(P,v){this.slotId=v;this.triggerType="TRIGGER_TYPE_AD_BREAK_STARTED";this.triggerId=P(this.triggerType)}; YW=function(P,v){this.adPodIndex=P;this.W=v.length;this.adBreakLengthSeconds=v.reduce(function(e,h){return e+h},0); var l=0;for(P+=1;P 0}; fO=function(P){return!!(P.r5$&&P.slot&&P.layout)}; Nf=function(P){var v,l=(v=P.config)==null?void 0:v.adPlacementConfig;P=P.renderer;return!(!l||l.kind==null||!P)}; z1x=function(P){if(!zO(P.adLayoutMetadata))return!1;P=P.renderingContent;return g.a(P,kq)||g.a(P,wl)||g.a(P,fW)||g.a(P,gl)?!0:!1}; JA=function(P){return P.playerVars!==void 0&&P.pings!==void 0&&P.externalVideoId!==void 0}; Yj=function(P){if(!zO(P.adLayoutMetadata))return!1;P=P.renderingContent;var v=g.a(P,uJ);return v?KO(v):(v=g.a(P,c4))?JA(v):(v=g.a(P,qf))?v.playerVars!==void 0:(v=g.a(P,kq))?v.durationMilliseconds!==void 0:g.a(P,FE)||g.a(P,AA)?!0:!1}; KO=function(P){P=(P.sequentialLayouts||[]).map(function(v){return g.a(v,bJ)}); return P.length>0&&P.every(Yj)}; ChB=function(P){if(!zO(P.adLayoutMetadata))return!1;if(g.a(P.renderingContent,mb6)||g.a(P.renderingContent,R1w))return!0;var v=g.a(P.renderingContent,xj);return g.a(P.renderingContent,pO)||g.a(v==null?void 0:v.sidePanel,QH2)||g.a(v==null?void 0:v.sidePanel,t19)||g.a(v==null?void 0:v.sidePanel,yfx)?!0:!1}; $bw=function(P){var v;(v=!P)||(v=P.adSlotMetadata,v=!((v==null?void 0:v.slotId)!==void 0&&(v==null?void 0:v.slotType)!==void 0));if(v||!(fXa(P)||P.slotEntryTrigger&&P.slotFulfillmentTriggers&&P.slotExpirationTriggers))return!1;var l;P=(l=P.fulfillmentContent)==null?void 0:l.fulfilledLayout;return(l=g.a(P,bJ))?Yj(l):(l=g.a(P,LO))?ChB(l):(l=g.a(P,ge2))?z1x(l):(l=g.a(P,kiy))?e17(l):(P=g.a(P,wqD))?zO(P.adLayoutMetadata)?g.a(P.renderingContent,mf)?!0:!1:!1:!1}; fXa=function(P){var v;P=g.a((v=P.fulfillmentContent)==null?void 0:v.fulfilledLayout,LO);var l;return P&&((l=P.adLayoutMetadata)==null?void 0:l.layoutType)==="LAYOUT_TYPE_PANEL_QR_CODE"&&P.layoutExitNormalTriggers===void 0}; IXB=function(P){var v;return(P==null?void 0:(v=P.adSlotMetadata)==null?void 0:v.slotType)==="SLOT_TYPE_IN_PLAYER"}; neD=function(P,v){var l;if((l=P.questions)==null||!l.length||!P.playbackCommands||(v===void 0||!v)&&P.questions.length!==1)return!1;P=g.N(P.questions);for(v=P.next();!v.done;v=P.next()){v=v.value;var e=l=void 0,h=((l=g.a(v,S6))==null?void 0:l.surveyAdQuestionCommon)||((e=g.a(v,GO))==null?void 0:e.surveyAdQuestionCommon);if(!Dbw(h))return!1}return!0}; NxD=function(P){P=((P==null?void 0:P.playerOverlay)||{}).instreamSurveyAdRenderer;var v;if(P)if(P.playbackCommands&&P.questions&&P.questions.length===1){var l,e=((v=g.a(P.questions[0],S6))==null?void 0:v.surveyAdQuestionCommon)||((l=g.a(P.questions[0],GO))==null?void 0:l.surveyAdQuestionCommon);v=Dbw(e)}else v=!1;else v=!1;return v}; Dbw=function(P){if(!P)return!1;P=g.a(P.instreamAdPlayerOverlay,XE);var v=g.a(P==null?void 0:P.skipOrPreviewRenderer,tX),l=g.a(P==null?void 0:P.adInfoRenderer,B4);return(g.a(P==null?void 0:P.skipOrPreviewRenderer,iJ)||v)&&l?!0:!1}; JfW=function(P){return P.linearAds!=null&&zO(P.adLayoutMetadata)}; u$u=function(P){return P.linearAd!=null&&P.adVideoStart!=null}; Knx=function(P){if(isNaN(Number(P.timeoutSeconds))||!P.text||!P.ctaButton||!g.a(P.ctaButton,g.UB)||!P.brandImage)return!1;var v;return P.backgroundImage&&g.a(P.backgroundImage,ZZ)&&((v=g.a(P.backgroundImage,ZZ))==null?0:v.landscape)?!0:!1}; j6=function(P,v,l,e,h,z,m){g.U.call(this);this.L0=P;this.W=v;this.G=e;this.vg=h;this.Y=z;this.K=m}; Fnw=function(P,v,l){var e,h=((e=l.adSlots)!=null?e:[]).map(function(Q){return g.a(Q,aL)}); if(l.Hy)if(yf(v.clientMetadata,"metadata_type_allow_pause_ad_break_request_slot_reschedule"))Ns(P.W.get(),"OPPORTUNITY_TYPE_AD_BREAK_SERVICE_RESPONSE_RECEIVED",function(){return[]},v.slotId); else{if(P.L0.get().J.N().V("h5_check_forecasting_renderer_for_throttled_midroll")){var z=l.UT.filter(function(Q){var t;return((t=Q.renderer)==null?void 0:t.clientForecastingAdRenderer)!=null}); z.length!==0?cf7(P.K,z,h,v.slotId,l.ssdaiAdsConfig):Ns(P.W.get(),"OPPORTUNITY_TYPE_AD_BREAK_SERVICE_RESPONSE_RECEIVED",function(){return[]},v.slotId)}else Ns(P.W.get(),"OPPORTUNITY_TYPE_AD_BREAK_SERVICE_RESPONSE_RECEIVED",function(){return[]},v.slotId); qiD(P.Y,v)}else{var m;e={Ga:Math.round(((z=yf(v.clientMetadata,"metadata_type_ad_break_request_data"))==null?void 0:z.Ga)||0),KR:(m=yf(v.clientMetadata,"metadata_type_ad_break_request_data"))==null?void 0:m.KR};cf7(P.K,l.UT,h,v.slotId,l.ssdaiAdsConfig,e)}}; Yiw=function(P,v,l,e,h,z,m){var Q=Nk(P.vg.get(),1);Ns(P.W.get(),"OPPORTUNITY_TYPE_AD_BREAK_SERVICE_RESPONSE_RECEIVED",function(){return AfD(P.G.get(),l,e,h,Q.clientPlaybackNonce,Q.FW,Q.daiEnabled,Q,z,m)},v)}; xbw=function(P,v,l,e,h,z,m){v=baD(v,z,Number(e.prefetchMilliseconds)||0,m);P=v instanceof V?v:H4(P,e,h,v,l);return P instanceof V?P:[P]}; pqx=function(P,v,l,e,h){var z=Jn(P.K.get(),"SLOT_TYPE_AD_BREAK_REQUEST");e=[new aR({getAdBreakUrl:e.getAdBreakUrl,Ga:0,KR:0}),new lq(!0)];P=v.pauseDurationMs?v.lactThresholdMs?{slotId:z,slotType:"SLOT_TYPE_AD_BREAK_REQUEST",slotPhysicalPosition:2,slotEntryTrigger:new P4(P.W,z),slotFulfillmentTriggers:[new oS2(P.W)],slotExpirationTriggers:[new Ow(P.W,h),new T$(P.W,z)],i$:"core",clientMetadata:new tT(e),adSlotLoggingData:l}:new V("AdPlacementConfig for Pause Ads is missing lact_threshold_ms"):new V("AdPlacementConfig for Pause Ads is missing pause_duration_ms"); return P instanceof V?P:[P]}; LnP=function(P){var v,l;return((v=P.renderer)==null?void 0:(l=v.adBreakServiceRenderer)==null?void 0:l.getAdBreakUrl)!==void 0}; EB=function(P,v,l){if(P.beforeContentVideoIdStartedTrigger)P=P.beforeContentVideoIdStartedTrigger?new bz(RD,v,P.id):new V("Not able to create BeforeContentVideoIdStartedTrigger");else{if(P.layoutIdExitedTrigger){var e;v=(e=P.layoutIdExitedTrigger)!=null&&e.triggeringLayoutId?new Xg(RD,P.layoutIdExitedTrigger.triggeringLayoutId,P.id):new V("Not able to create LayoutIdExitedTrigger")}else{if(P.layoutExitedForReasonTrigger){var h,z;((h=P.layoutExitedForReasonTrigger)==null?0:h.triggeringLayoutId)&&((z= P.layoutExitedForReasonTrigger)==null?0:z.layoutExitReason)?(v=s59(P.layoutExitedForReasonTrigger.layoutExitReason),P=v instanceof V?v:new G$(RD,P.layoutExitedForReasonTrigger.triggeringLayoutId,[v],P.id)):P=new V("Not able to create LayoutIdExitedForReasonTrigger")}else{if(P.onLayoutSelfExitRequestedTrigger){var m;v=(m=P.onLayoutSelfExitRequestedTrigger)!=null&&m.triggeringLayoutId?new WE(RD,P.onLayoutSelfExitRequestedTrigger.triggeringLayoutId,P.id):new V("Not able to create OnLayoutSelfExitRequestedTrigger")}else{if(P.onNewPlaybackAfterContentVideoIdTrigger)P= P.onNewPlaybackAfterContentVideoIdTrigger?new Ow(RD,v,P.id):new V("Not able to create OnNewPlaybackAfterContentVideoIdTrigger");else{if(P.skipRequestedTrigger){var Q;v=(Q=P.skipRequestedTrigger)!=null&&Q.triggeringLayoutId?new rU(RD,P.skipRequestedTrigger.triggeringLayoutId,P.id):new V("Not able to create SkipRequestedTrigger")}else if(P.slotIdEnteredTrigger){var t;v=(t=P.slotIdEnteredTrigger)!=null&&t.triggeringSlotId?new Mi(RD,P.slotIdEnteredTrigger.triggeringSlotId,P.id):new V("Not able to create SlotIdEnteredTrigger")}else if(P.slotIdExitedTrigger){var y; v=(y=P.slotIdExitedTrigger)!=null&&y.triggeringSlotId?new T$(RD,P.slotIdExitedTrigger.triggeringSlotId,P.id):new V("Not able to create SkipRequestedTrigger")}else if(P.surveySubmittedTrigger){var C;v=(C=P.surveySubmittedTrigger)!=null&&C.triggeringLayoutId?new lJ(RD,P.surveySubmittedTrigger.triggeringLayoutId,P.id):new V("Not able to create SurveySubmittedTrigger")}else{if(P.mediaResumedTrigger)P=P.mediaResumedTrigger&&P.id?new rHq(P.id):new V("Not able to create MediaResumedTrigger");else{if(P.closeRequestedTrigger){var f; v=(f=P.closeRequestedTrigger)!=null&&f.triggeringLayoutId?new xW(RD,P.closeRequestedTrigger.triggeringLayoutId,P.id):new V("Not able to create CloseRequestedTrigger")}else if(P.slotIdScheduledTrigger){var k;v=(k=P.slotIdScheduledTrigger)!=null&&k.triggeringSlotId?new P4(RD,P.slotIdScheduledTrigger.triggeringSlotId,P.id):new V("Not able to create SlotIdScheduledTrigger")}else{if(P.mediaTimeRangeTrigger){var w;e=Number((w=P.mediaTimeRangeTrigger)==null?void 0:w.offsetStartMilliseconds);var I;m=Number((I= P.mediaTimeRangeTrigger)==null?void 0:I.offsetEndMilliseconds);isFinite(e)&&isFinite(m)?(I=m,I===-1&&(I=l),l=e>I?new V("AD_PLACEMENT_KIND_MILLISECONDS endMs needs to be >= startMs.",{offsetStartMs:e,offsetEndMs:I},"ADS_CLIENT_ERROR_MESSAGE_AD_PLACEMENT_END_SHOULD_GREATER_THAN_START",I===l&&e-500<=I):new pz(e,I),P=l instanceof V?l:new j5(RD,v,l,!1,P.id)):P=new V("Not able to create MediaTimeRangeTrigger")}else if(P.contentVideoIdEndedTrigger)P=P.contentVideoIdEndedTrigger?new pl(RD,v,!1,P.id):new V("Not able to create ContentVideoIdEndedTrigger"); else{if(P.layoutIdEnteredTrigger){var J;v=(J=P.layoutIdEnteredTrigger)!=null&&J.triggeringLayoutId?new S5(RD,P.layoutIdEnteredTrigger.triggeringLayoutId,P.id):new V("Not able to create LayoutIdEnteredTrigger")}else if(P.timeRelativeToLayoutEnterTrigger){var K;v=(K=P.timeRelativeToLayoutEnterTrigger)!=null&&K.triggeringLayoutId?new e6(RD,Number(P.timeRelativeToLayoutEnterTrigger.durationMs),P.timeRelativeToLayoutEnterTrigger.triggeringLayoutId,P.id):new V("Not able to create TimeRelativeToLayoutEnterTrigger")}else if(P.onDifferentLayoutIdEnteredTrigger){var q; v=(q=P.onDifferentLayoutIdEnteredTrigger)!=null&&q.triggeringLayoutId&&P.onDifferentLayoutIdEnteredTrigger.slotType&&P.onDifferentLayoutIdEnteredTrigger.layoutType?new HE(RD,P.onDifferentLayoutIdEnteredTrigger.triggeringLayoutId,P.onDifferentLayoutIdEnteredTrigger.slotType,P.onDifferentLayoutIdEnteredTrigger.layoutType,P.id):new V("Not able to create CloseRequestedTrigger")}else{if(P.liveStreamBreakStartedTrigger)P=P.liveStreamBreakStartedTrigger&&P.id?new Zt(RD,P.id):new V("Not able to create LiveStreamBreakStartedTrigger"); else if(P.liveStreamBreakEndedTrigger)P=P.liveStreamBreakEndedTrigger&&P.id?new BE(RD,P.id):new V("Not able to create LiveStreamBreakEndedTrigger");else{if(P.liveStreamBreakScheduledDurationMatchedTrigger){var A;v=(A=P.liveStreamBreakScheduledDurationMatchedTrigger)!=null&&A.breakDurationMs?new iz(Number(P.liveStreamBreakScheduledDurationMatchedTrigger.breakDurationMs||"0")||0,P.id):new V("Not able to create LiveStreamBreakScheduledDurationMatchedTrigger")}else if(P.liveStreamBreakScheduledDurationNotMatchedTrigger){var x; v=(x=P.liveStreamBreakScheduledDurationNotMatchedTrigger)!=null&&x.breakDurationMs?new Uw(Number(P.liveStreamBreakScheduledDurationNotMatchedTrigger.breakDurationMs||"0")||0,P.id):new V("Not able to create LiveStreamBreakScheduledDurationNotMatchedTrigger")}else if(P.newSlotScheduledWithBreakDurationTrigger){var S;v=(S=P.newSlotScheduledWithBreakDurationTrigger)!=null&&S.breakDurationMs?new a2(Number(P.newSlotScheduledWithBreakDurationTrigger.breakDurationMs||"0")||0,P.id):new V("Not able to create NewSlotScheduledWithBreakDurationTrigger")}else v= P.prefetchCacheExpiredTrigger?new o2(RD,P.id):new V("Not able to convert an AdsControlflowTrigger.");P=v}v=P}P=v}v=P}P=v}v=P}P=v}v=P}P=v}v=P}P=v}return P}; W4=function(P,v){v.W>=2&&(P.slot_pos=v.adPodIndex);P.autoplay="1"}; Gi6=function(P,v,l,e,h,z,m,Q){return v===null?new V("Invalid slot type when get discovery companion fromActionCompanionAdRenderer",{slotType:v,ActionCompanionAdRenderer:e}):[Si2(P,v,m,z,function(t){var y=t.slotId;t=Q(t);var C=e.adLayoutLoggingData,f=new tT([new HT(e),new vJ(h)]);y=vb(l.K.get(),"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON",y);var k={layoutId:y,layoutType:"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON",i$:"core"};return{layoutId:y,layoutType:"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON",XJ:new Map, layoutExitNormalTriggers:[new Ow(l.W,m)],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:f,ra:t(k),adLayoutLoggingData:C}})]}; Xqa=function(P,v,l,e,h,z,m,Q){return v===null?new V("Invalid slot type when get discovery companion fromTopBannerImageTextIconButtonedLayoutViewModel",{slotType:v,TopBannerImageTextIconButtonedLayoutViewModel:e}):[Si2(P,v,m,z,function(t){var y=t.slotId;t=Q(t);var C=e.adLayoutLoggingData,f=new tT([new E2(e),new vJ(h)]);y=vb(l.K.get(),"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON",y);var k={layoutId:y,layoutType:"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON",i$:"core"};return{layoutId:y,layoutType:"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON", XJ:new Map,layoutExitNormalTriggers:[new Ow(l.W,m)],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:f,ra:t(k),adLayoutLoggingData:C}})]}; Zau=function(P,v,l,e,h,z){if(!z)for(v=g.N(v),z=v.next();!z.done;z=v.next())z=z.value,OB(P,z.renderer,z.config.adPlacementConfig.kind);P=Array.from(P.values()).filter(function(C){return Bx9(C)}); v=[];z=g.N(P);for(var m=z.next(),Q={};!m.done;Q={Gj:void 0},m=z.next()){Q.Gj=m.value;m=g.N(Q.Gj.KT);for(var t=m.next(),y={};!t.done;y={F2:void 0},t=m.next())y.F2=t.value,t=function(C,f){return function(k){return C.F2.QL(k,f.Gj.instreamVideoAdRenderer.elementId,C.F2.QC)}}(y,Q),y.F2.isContentVideoCompanion?v.push(iau(l,e,h,Q.Gj.instreamVideoAdRenderer.elementId,y.F2.associatedCompositePlayerBytesLayoutId,y.F2.adSlotLoggingData,t)):P.length>1?v.push(UbD(l,e,h,Q.Gj.instreamVideoAdRenderer.elementId,y.F2.adSlotLoggingData, function(C,f){return function(k){return C.F2.QL(k,f.Gj.instreamVideoAdRenderer.elementId,C.F2.QC,C.F2.associatedCompositePlayerBytesLayoutId)}}(y,Q))):v.push(UbD(l,e,h,Q.Gj.instreamVideoAdRenderer.elementId,y.F2.adSlotLoggingData,t))}return v}; OB=function(P,v,l){if(v=jHq(v)){v=g.N(v);for(var e=v.next();!e.done;e=v.next())if((e=e.value)&&e.externalVideoId){var h=oL(P,e.externalVideoId);h.instreamVideoAdRenderer||(h.instreamVideoAdRenderer=e,h.Dv=l)}else Iq("InstreamVideoAdRenderer without externalVideoId")}}; jHq=function(P){var v=[],l=P.sandwichedLinearAdRenderer&&P.sandwichedLinearAdRenderer.linearAd&&g.a(P.sandwichedLinearAdRenderer.linearAd,c4);if(l)return v.push(l),v;if(P.instreamVideoAdRenderer)return v.push(P.instreamVideoAdRenderer),v;if(P.linearAdSequenceRenderer&&P.linearAdSequenceRenderer.linearAds){P=g.N(P.linearAdSequenceRenderer.linearAds);for(l=P.next();!l.done;l=P.next())l=l.value,g.a(l,c4)&&v.push(g.a(l,c4));return v}return null}; Bx9=function(P){if(P.instreamVideoAdRenderer===void 0)return Iq("AdPlacementSupportedRenderers without matching InstreamVideoAdRenderer"),!1;for(var v=g.N(P.KT),l=v.next();!l.done;l=v.next()){l=l.value;if(l.QL===void 0)return!1;if(l.QC===void 0)return Iq("AdPlacementConfig for AdPlacementSupportedRenderers that matches an InstreamVideoAdRenderer is undefined"),!1;if(P.Dv===void 0||l.xj===void 0||P.Dv!==l.xj&&l.xj!=="AD_PLACEMENT_KIND_SELF_START")return!1;if(P.instreamVideoAdRenderer.elementId===void 0)return Iq("InstreamVideoAdRenderer has no elementId", void 0,void 0,{kind:P.Dv,"matching APSR kind":l.xj}),!1}return!0}; oL=function(P,v){P.has(v)||P.set(v,{instreamVideoAdRenderer:void 0,Dv:void 0,adVideoId:v,KT:[]});return P.get(v)}; sB=function(P,v,l,e,h,z,m,Q,t){h?oL(P,h).KT.push({gBM:v,xj:l,isContentVideoCompanion:e,QC:m,associatedCompositePlayerBytesLayoutId:z,adSlotLoggingData:Q,QL:t}):Iq("Companion AdPlacementSupportedRenderer without adVideoId")}; rk=function(P){var v=0;P=g.N(P.questions);for(var l=P.next();!l.done;l=P.next())if(l=l.value,l=g.a(l,S6)||g.a(l,GO)){var e=void 0;v+=((e=l.surveyAdQuestionCommon)==null?void 0:e.durationMilliseconds)||0}return v}; Mf=function(P){var v,l,e,h,z=((l=g.a((v=P.questions)==null?void 0:v[0],S6))==null?void 0:l.surveyAdQuestionCommon)||((h=g.a((e=P.questions)==null?void 0:e[0],GO))==null?void 0:h.surveyAdQuestionCommon),m;v=[].concat(g.u(((m=P.playbackCommands)==null?void 0:m.instreamAdCompleteCommands)||[]),g.u((z==null?void 0:z.timeoutCommands)||[]));var Q,t,y,C,f,k,w,I,J,K,q,A,x,S,B,E,r,hq,R7,Pw;return{impressionCommands:(Q=P.playbackCommands)==null?void 0:Q.impressionCommands,errorCommands:(t=P.playbackCommands)== null?void 0:t.errorCommands,muteCommands:(y=P.playbackCommands)==null?void 0:y.muteCommands,unmuteCommands:(C=P.playbackCommands)==null?void 0:C.unmuteCommands,pauseCommands:(f=P.playbackCommands)==null?void 0:f.pauseCommands,rewindCommands:(k=P.playbackCommands)==null?void 0:k.rewindCommands,resumeCommands:(w=P.playbackCommands)==null?void 0:w.resumeCommands,skipCommands:(I=P.playbackCommands)==null?void 0:I.skipCommands,progressCommands:(J=P.playbackCommands)==null?void 0:J.progressCommands,c8c:(K= P.playbackCommands)==null?void 0:K.clickthroughCommands,fullscreenCommands:(q=P.playbackCommands)==null?void 0:q.fullscreenCommands,activeViewViewableCommands:(A=P.playbackCommands)==null?void 0:A.activeViewViewableCommands,activeViewMeasurableCommands:(x=P.playbackCommands)==null?void 0:x.activeViewMeasurableCommands,activeViewFullyViewableAudibleHalfDurationCommands:(S=P.playbackCommands)==null?void 0:S.activeViewFullyViewableAudibleHalfDurationCommands,activeViewAudioAudibleCommands:(B=P.playbackCommands)== null?void 0:(E=B.activeViewTracking)==null?void 0:E.activeViewAudioAudibleCommands,activeViewAudioMeasurableCommands:(r=P.playbackCommands)==null?void 0:(hq=r.activeViewTracking)==null?void 0:hq.activeViewAudioMeasurableCommands,endFullscreenCommands:(R7=P.playbackCommands)==null?void 0:R7.endFullscreenCommands,abandonCommands:(Pw=P.playbackCommands)==null?void 0:Pw.abandonCommands,completeCommands:v}}; HaD=function(P,v,l,e,h,z,m){return function(Q,t){return aX7(P,t.slotId,Q,z,function(y,C){var f=t.layoutId;y=m(y);return TO(v,f,C,h,y,"LAYOUT_TYPE_SURVEY",[new IR(l),e],l.adLayoutLoggingData)})}}; Oax=function(P,v,l,e,h,z,m){if(!Eeq(P))return new V("Invalid InstreamVideoAdRenderer for SlidingText.",{instreamVideoAdRenderer:P});var Q=P.additionalPlayerOverlay.slidingTextPlayerOverlayRenderer;return[Wny(z,v,l,e,function(t){var y=t.slotId;t=m(t);y=vb(h.K.get(),"LAYOUT_TYPE_SLIDING_TEXT_PLAYER_OVERLAY",y);var C={layoutId:y,layoutType:"LAYOUT_TYPE_SLIDING_TEXT_PLAYER_OVERLAY",i$:"core"},f=new Xg(h.W,e);return{layoutId:y,layoutType:"LAYOUT_TYPE_SLIDING_TEXT_PLAYER_OVERLAY",XJ:new Map,layoutExitNormalTriggers:[f], layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:new tT([new Dj(Q)]),ra:t(C)}})]}; Eeq=function(P){P=g.a(P==null?void 0:P.additionalPlayerOverlay,oex);if(!P)return!1;var v=P.slidingMessages;return P.title&&v&&v.length!==0?!0:!1}; rfD=function(P,v,l,e,h){var z;if((z=P.playerOverlay)==null||!z.instreamSurveyAdRenderer)return function(){return[]}; if(!NxD(P))return function(){return new V("Received invalid InstreamVideoAdRenderer for DAI survey.",{instreamVideoAdRenderer:P})}; var m=P.playerOverlay.instreamSurveyAdRenderer,Q=rk(m);return Q<=0?function(){return new V("InstreamSurveyAdRenderer should have valid duration.",{instreamSurveyAdRenderer:m})}:function(t,y){var C=sH2(t,l,e,function(f){var k=f.slotId; f=y(f);var w=Mf(m);k=vb(h.K.get(),"LAYOUT_TYPE_SURVEY",k);var I={layoutId:k,layoutType:"LAYOUT_TYPE_SURVEY",i$:"core"},J=new Xg(h.W,e),K=new rU(h.W,k),q=new lJ(h.W,k),A=new ddD(h.W);return{layoutId:k,layoutType:"LAYOUT_TYPE_SURVEY",XJ:new Map,layoutExitNormalTriggers:[J,A],layoutExitSkipTriggers:[K],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[q],VD:[],i$:"core",clientMetadata:new tT([new $y(m),new vJ(v),new WJ(Q/1E3),new rH(w)]),ra:f(I),adLayoutLoggingData:m.adLayoutLoggingData}}); t=Oax(P,l,C.slotId,e,h,t,y);return t instanceof V?t:[C].concat(g.u(t))}}; liw=function(P,v,l,e,h,z,m){m=m===void 0?!1:m;var Q=[];try{var t=[];if(l.renderer.linearAdSequenceRenderer)var y=function(J){J=M1W(J.slotId,l,v,h(J),e,z,m);t=J.LpW;return J.FB}; else if(l.renderer.instreamVideoAdRenderer)y=function(J){var K=J.slotId;J=h(J);var q=m,A=l.config.adPlacementConfig,x=Txx(A),S=x.g8,B=x.Mb;x=l.renderer.instreamVideoAdRenderer;var E;if(x==null?0:(E=x.playerOverlay)==null?0:E.instreamSurveyAdRenderer)throw new TypeError("Survey overlay should not be set on single video.");var r=VM(x,q);E=Math.min(S+r.videoLengthSeconds*1E3,B);q=new YW(0,[r.videoLengthSeconds]);B=r.videoLengthSeconds;var hq=r.playerVars,R7=r.instreamAdPlayerOverlayRenderer,Pw=r.playerOverlayLayoutRenderer, H=r.adVideoId,T=V19(l),n=r.XJ;r=r.Fv;var W=x==null?void 0:x.adLayoutLoggingData;x=x==null?void 0:x.sodarExtensionData;K=vb(v.K.get(),"LAYOUT_TYPE_MEDIA",K);var du={layoutId:K,layoutType:"LAYOUT_TYPE_MEDIA",i$:"core"};return{layoutId:K,layoutType:"LAYOUT_TYPE_MEDIA",XJ:n,layoutExitNormalTriggers:[new BE(v.W)],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:new tT([new RR(e),new Yy(B),new b1(hq),new S$(S),new GH(E),R7&&new Qm(R7), Pw&&new tu(Pw),new vJ(A),new m1(H),new l1(q),new Zj(T),x&&new LY(x),new cJ({current:null}),new BJ({}),new Vm(r)].filter(dbD)),ra:J(du),adLayoutLoggingData:W}}; else throw new TypeError("Expected valid AdPlacementRenderer for DAI");var C=Pb9(P,e,l.adSlotLoggingData,y);Q.push(C);for(var f=g.N(t),k=f.next();!k.done;k=f.next()){var w=k.value,I=w(P,h);if(I instanceof V)return I;Q.push.apply(Q,g.u(I))}}catch(J){return new V(J,{errorMessage:J.message,AdPlacementRenderer:l,numberOfSurveyRenderers:vlu(l)})}return Q}; vlu=function(P){P=(P.renderer.linearAdSequenceRenderer||{}).linearAds;return P!=null&&P.length?P.filter(function(v){var l,e;return((l=g.a(v,c4))==null?void 0:(e=l.playerOverlay)==null?void 0:e.instreamSurveyAdRenderer)!=null}).length:0}; M1W=function(P,v,l,e,h,z,m){var Q=v.config.adPlacementConfig,t=Txx(Q),y=t.g8,C=t.Mb;t=(v.renderer.linearAdSequenceRenderer||{}).linearAds;if(t==null||!t.length)throw new TypeError("Expected linear ads");var f=[],k={Je:y,AA:0,Kp5:f};t=t.map(function(I){return eMu(P,I,k,l,e,Q,h,C,m)}).map(function(I,J){J=new YW(J,f); return I(J)}); var w=t.map(function(I){return I.gg}); return{FB:hMP(l,P,y,w,Q,V19(v),e,C,z),LpW:t.map(function(I){return I.YR$})}}; eMu=function(P,v,l,e,h,z,m,Q,t){var y=VM(g.a(v,c4),t),C=l.Je,f=l.AA,k=Math.min(C+y.videoLengthSeconds*1E3,Q);l.Je=k;l.AA++;l.Kp5.push(y.videoLengthSeconds);var w,I,J=(w=g.a(v,c4))==null?void 0:(I=w.playerOverlay)==null?void 0:I.instreamSurveyAdRenderer;if(y.adVideoId==="nPpU29QrbiU"&&J==null)throw new TypeError("Survey slate media has no survey overlay");return function(K){W4(y.playerVars,K);var q,A,x=y.videoLengthSeconds,S=y.playerVars,B=y.XJ,E=y.Fv,r=y.instreamAdPlayerOverlayRenderer,hq=y.playerOverlayLayoutRenderer, R7=y.adVideoId,Pw=(q=g.a(v,c4))==null?void 0:q.adLayoutLoggingData;q=(A=g.a(v,c4))==null?void 0:A.sodarExtensionData;A=vb(e.K.get(),"LAYOUT_TYPE_MEDIA",P);var H={layoutId:A,layoutType:"LAYOUT_TYPE_MEDIA",i$:"adapter"};K={layoutId:A,layoutType:"LAYOUT_TYPE_MEDIA",XJ:B,layoutExitNormalTriggers:[],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"adapter",clientMetadata:new tT([new RR(m),new Yy(x),new b1(S),new S$(C),new GH(k),new Xw(f),new cJ({current:null}), r&&new Qm(r),hq&&new tu(hq),new vJ(z),new m1(R7),new l1(K),q&&new LY(q),J&&new TH(J),new BJ({}),new Vm(E)].filter(dbD)),ra:h(H),adLayoutLoggingData:Pw};x=rfD(g.a(v,c4),z,m,K.layoutId,e);return{gg:K,YR$:x}}}; VM=function(P,v){if(!P)throw new TypeError("Expected instream video ad renderer");if(!P.playerVars)throw new TypeError("Expected player vars in url encoded string");var l=yS(P.playerVars),e=Number(l.length_seconds);if(isNaN(e))throw new TypeError("Expected valid length seconds in player vars");var h=Number(P.trimmedMaxNonSkippableAdDurationMs);e=isNaN(h)?e:Math.min(e,h/1E3);h=P.playerOverlay||{};h=h.instreamAdPlayerOverlayRenderer===void 0?null:h.instreamAdPlayerOverlayRenderer;var z=P.playerOverlay|| {};z=z.playerOverlayLayoutRenderer===void 0?null:z.playerOverlayLayoutRenderer;var m=l.video_id;m||(m=(m=P.externalVideoId)?m:void 0);if(!m)throw new TypeError("Expected valid video id in IVAR");if(v&&e===0){var Q;v=(Q=zMa[m])!=null?Q:e}else v=e;return{playerVars:l,videoLengthSeconds:v,instreamAdPlayerOverlayRenderer:h,playerOverlayLayoutRenderer:z,adVideoId:m,XJ:P.pings?pe(P.pings):new Map,Fv:x4(P.pings)}}; V19=function(P){P=Number(P.driftRecoveryMs);return isNaN(P)||P<=0?null:P}; Txx=function(P){var v=P.adTimeOffset||{};P=v.offsetEndMilliseconds;v=Number(v.offsetStartMilliseconds);if(isNaN(v))throw new TypeError("Expected valid start offset");P=Number(P);if(isNaN(P))throw new TypeError("Expected valid end offset");return{g8:v,Mb:P}}; mjx=function(P){var v,l=(v=yf(P.clientMetadata,"metadata_type_player_bytes_callback_ref"))==null?void 0:v.current;if(!l)return null;v=yf(P.clientMetadata,"metadata_type_ad_pod_skip_target_callback_ref");var e=P.layoutId,h=yf(P.clientMetadata,"metadata_type_content_cpn"),z=yf(P.clientMetadata,"metadata_type_instream_ad_player_overlay_renderer"),m=yf(P.clientMetadata,"metadata_type_player_underlay_renderer"),Q=yf(P.clientMetadata,"metadata_type_ad_placement_config"),t=yf(P.clientMetadata,"metadata_type_video_length_seconds"); var y=zf(P.clientMetadata,"metadata_type_layout_enter_ms")&&zf(P.clientMetadata,"metadata_type_layout_exit_ms")?(yf(P.clientMetadata,"metadata_type_layout_exit_ms")-yf(P.clientMetadata,"metadata_type_layout_enter_ms"))/1E3:void 0;return{h8:e,contentCpn:h,z4:l,Gp:v,instreamAdPlayerOverlayRenderer:z,instreamAdPlayerUnderlayRenderer:m,adPlacementConfig:Q,videoLengthSeconds:t,m3:y,inPlayerLayoutId:yf(P.clientMetadata,"metadata_type_linked_in_player_layout_id"),inPlayerSlotId:yf(P.clientMetadata,"metadata_type_linked_in_player_slot_id")}}; t22=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I){e=Jn(e,"SLOT_TYPE_PLAYER_BYTES");P=RMW(h,P,m,l,e,t,y);if(P instanceof V)return P;var J;y=(J=yf(P.clientMetadata,"metadata_type_fulfilled_layout"))==null?void 0:J.layoutId;if(!y)return new V("Invalid adNotify layout");v=QdD(y,h,z,l,Q,v,t,C,f,k,w,I,m);return v instanceof V?v:[P].concat(g.u(v))}; QdD=function(P,v,l,e,h,z,m,Q,t,y,C,f,k){l=yS2(v,l,e,z,m,Q,t,y,C,f,k);if(l instanceof V)return l;P=Cbx(v,P,m,h,l);return P instanceof V?P:[].concat(g.u(P.J3),[P.Mx])}; gl2=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w){v=yS2(P,v,l,h,z,Q,t,y,C,f,k,w);if(v instanceof V)return v;P=fiD(P,l,z,m,e,Q.Ei,v);return P instanceof V?P:P.J3.concat(P.Mx)}; yS2=function(P,v,l,e,h,z,m,Q,t,y,C,f){var k=dk(e,l,y);return k instanceof Qf?new V(k):y.J.N().experiments.l$("html5_refactor_in_player_slot_generation")?function(w){var I=new YW(0,[k.zg]);w=kIx(v,k.layoutId,k.QT,l,PX(k.playerVars,k.eR,z,t,I),k.zg,h,I,m(w),Q.get(k.QT.externalVideoId),f);I=[];if(k.QT.playerOverlay.instreamAdPlayerOverlayRenderer){var J=mjx(w);if(!J)return Iq("Expected MediaLayout to carry valid data to create InPlayerSlot and PlayerOverlayForMediaLayout",void 0,w),{layout:w,J3:[]}; I=[wTD(P,J.contentCpn,J.h8,function(q){return vX(v,q.slotId,"core",J,$O(C,q))},J.inPlayerSlotId)].concat(g.u(I)); if(J.instreamAdPlayerUnderlayRenderer&&lF(y)){var K=J.instreamAdPlayerUnderlayRenderer;I=[$jw(P,J.contentCpn,J.h8,function(q){return IiW(v,q.slotId,K,J.adPlacementConfig,J.h8,$O(C,q))})].concat(g.u(I))}}return{layout:w, J3:I}}:function(w){var I=new YW(0,[k.zg]); return{layout:kIx(v,k.layoutId,k.QT,l,PX(k.playerVars,k.eR,z,t,I),k.zg,h,I,m(w),Q.get(k.QT.externalVideoId),f),J3:[]}}}; dk=function(P,v,l){if(!P.playerVars)return new Qf("No playerVars available in InstreamVideoAdRenderer.");var e,h;if(P.elementId==null||P.playerVars==null||P.playerOverlay==null||((e=P.playerOverlay)==null?void 0:e.instreamAdPlayerOverlayRenderer)==null&&((h=P.playerOverlay)==null?void 0:h.playerOverlayLayoutRenderer)==null||P.pings==null||P.externalVideoId==null)return new Qf("Received invalid VOD InstreamVideoAdRenderer",{instreamVideoAdRenderer:P});e=yS(P.playerVars);h=Number(e.length_seconds); isNaN(h)&&(h=0,Iq("Expected valid length seconds in player vars but got NaN"));if(l.QI(v.kind==="AD_PLACEMENT_KIND_START")){if(P.layoutId===void 0)return new Qf("Expected server generated layout ID in instreamVideoAdRenderer");v=P.layoutId}else v=P.elementId;return{layoutId:v,QT:P,playerVars:e,eR:P.playerVars,zg:h}}; PX=function(P,v,l,e,h){P.iv_load_policy=e;v=yS(v);if(v.cta_conversion_urls)try{P.cta_conversion_urls=JSON.parse(v.cta_conversion_urls)}catch(z){Iq(z)}l.e_&&(P.ctrl=l.e_);l.wY&&(P.ytr=l.wY);l.Jw&&(P.ytrcc=l.Jw);l.isMdxPlayback&&(P.mdx="1");P.vvt&&(P.vss_credentials_token=P.vvt,l.R3&&(P.vss_credentials_token_type=l.R3),l.mdxEnvironment&&(P.mdx_environment=l.mdxEnvironment));W4(P,h);return P}; Dja=function(P){var v=new Map;P=g.N(P);for(var l=P.next();!l.done;l=P.next())(l=l.value.renderer.remoteSlotsRenderer)&&l.hostElementId&&v.set(l.hostElementId,l);return v}; ec=function(P){return P.adSlotMetadata.slotType==="SLOT_TYPE_PLAYER_BYTES"}; nlB=function(P){return P!=null}; q27=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w){for(var I=[],J=g.N(P),K=J.next();!K.done;K=J.next())if(K=K.value,!fXa(K)&&!IXB(K)){var q=ec(K)&&!!K.slotEntryTrigger.beforeContentVideoIdStartedTrigger,A=t.QI(q),x=Nea(K,y,e,l.FW,A);if(x instanceof V)return x;var S=void 0,B={slotId:K.adSlotMetadata.slotId,slotType:K.adSlotMetadata.slotType,slotPhysicalPosition:(S=K.adSlotMetadata.slotPhysicalPosition)!=null?S:1,i$:"core",slotEntryTrigger:x.slotEntryTrigger,slotFulfillmentTriggers:x.slotFulfillmentTriggers, slotExpirationTriggers:x.slotExpirationTriggers},E=g.a(K.fulfillmentContent.fulfilledLayout,bJ);if(E){if(!Yj(E))return new V("Invalid PlayerBytesAdLayoutRenderer");S=f&&!(ec(K)&&K.slotEntryTrigger.beforeContentVideoIdStartedTrigger);x=x.slotFulfillmentTriggers.some(function(r){return r instanceof iz}); A=S?JSu(B,K.adSlotMetadata.triggerEvent,E,l,e,z,y,P,A,k,x,w):uYD(B,K.adSlotMetadata.triggerEvent,E,v,l,e,h,z,m,Q,t,y,P,C,A,K.adSlotMetadata.triggeringSourceLayoutId);if(A instanceof V)return A;x=[];ec(K)&&x.push(new ey({NR:ec(K)&&!!K.slotEntryTrigger.beforeContentVideoIdStartedTrigger}));S&&x.push(new BJ({}));l.Ei&&x.push(new MS({}));x.push(new v2(q));K=Object.assign({},B,{clientMetadata:new tT(x),fulfilledLayout:A.layout,adSlotLoggingData:K.adSlotMetadata.adSlotLoggingData});I.push.apply(I,g.u(A.J3)); I.push(K)}else if(q=g.a(K.fulfillmentContent.fulfilledLayout,LO)){if(!ChB(q))return new V("Invalid PlayerUnderlayAdLayoutRenderer");q=Kqu(q,e,l.FW,z,B,K.adSlotMetadata.triggerEvent,K.adSlotMetadata.triggeringSourceLayoutId);if(q instanceof V)return q;K=Object.assign({},B,{clientMetadata:new tT([]),fulfilledLayout:q,adSlotLoggingData:K.adSlotMetadata.adSlotLoggingData});I.push(K)}else if(q=g.a(K.fulfillmentContent.fulfilledLayout,kiy)){if(!e17(q))return new V("Invalid AboveFeedAdLayoutRenderer");q= cSa(q,e,l.FW,z,B,K.adSlotMetadata.triggerEvent,K.adSlotMetadata.triggeringSourceLayoutId);if(q instanceof V)return q;K=Object.assign({},B,{clientMetadata:new tT([]),fulfilledLayout:q,adSlotLoggingData:K.adSlotMetadata.adSlotLoggingData});I.push(K)}else if(q=g.a(K.fulfillmentContent.fulfilledLayout,wqD)){if(!zO(q.adLayoutMetadata)||!g.a(q.renderingContent,mf))return new V("Invalid BelowPlayerAdLayoutRenderer");q=cSa(q,e,l.FW,z,B,K.adSlotMetadata.triggerEvent,K.adSlotMetadata.triggeringSourceLayoutId); if(q instanceof V)return q;K=Object.assign({},B,{clientMetadata:new tT([]),fulfilledLayout:q,adSlotLoggingData:K.adSlotMetadata.adSlotLoggingData});I.push(K)}else return new V("Unable to retrieve a client slot ["+B.slotType+"] from a given AdSlotRenderer")}return I}; cSa=function(P,v,l,e,h,z,m){var Q={layoutId:P.adLayoutMetadata.layoutId,layoutType:P.adLayoutMetadata.layoutType,i$:"core"};v=hF(P,v,l);if(v instanceof V)return v;l=[];l.push(new vJ(zu(z)));z==="SLOT_TRIGGER_EVENT_LAYOUT_ID_ENTERED"&&m!==void 0&&l.push(new nY(m));return Object.assign({},Q,{renderingContent:P.renderingContent,XJ:new Map([["impression",Fq6(P)]])},v,{ra:$O(e,h)(Q),clientMetadata:new tT(l),adLayoutLoggingData:P.adLayoutMetadata.adLayoutLoggingData})}; Kqu=function(P,v,l,e,h,z,m){if(P.adLayoutMetadata.layoutType==="LAYOUT_TYPE_DISMISSABLE_PANEL_TEXT_PORTRAIT_IMAGE")if(m=g.a(P.renderingContent,xj))if(m=g.a(m.sidePanel,t19)){var Q={layoutId:P.adLayoutMetadata.layoutId,layoutType:P.adLayoutMetadata.layoutType,i$:"core"};v=hF(P,v,l);P=v instanceof V?v:Object.assign({},Q,{renderingContent:P.renderingContent,XJ:new Map([["impression",m.impressionPings||[]],["resume",m.resumePings||[]]])},v,{ra:$O(e,h)(Q),clientMetadata:new tT([new vJ(zu(z))]),adLayoutLoggingData:P.adLayoutMetadata.adLayoutLoggingData})}else P= new V("DismissablePanelTextPortraitImageRenderer is missing");else P=new V("SqueezebackPlayerSidePanelRenderer is missing");else P.adLayoutMetadata.layoutType==="LAYOUT_TYPE_DISPLAY_TRACKING"?g.a(P.renderingContent,mb6)?(m={layoutId:P.adLayoutMetadata.layoutId,layoutType:P.adLayoutMetadata.layoutType,i$:"core"},v=hF(P,v,l),P=v instanceof V?v:Object.assign({},m,{renderingContent:P.renderingContent,XJ:new Map},v,{ra:$O(e,h)(m),clientMetadata:new tT([new vJ(zu(z))]),adLayoutLoggingData:P.adLayoutMetadata.adLayoutLoggingData})): P=new V("CounterfactualRenderer is missing"):P.adLayoutMetadata.layoutType==="LAYOUT_TYPE_PANEL_QR_CODE"?P=new V("PlayerUnderlaySlot cannot be created because adUxReadyApiProvider is null"):P.adLayoutMetadata.layoutType==="LAYOUT_TYPE_PANEL_QR_CODE_CAROUSEL"?P=new V("PlayerUnderlaySlot cannot be created because adUxReadyApiProvider is null"):P.adLayoutMetadata.layoutType==="LAYOUT_TYPE_DISPLAY_UNDERLAY_TEXT_GRID_CARDS"?g.a(P.renderingContent,pO)?(z={layoutId:P.adLayoutMetadata.layoutId,layoutType:P.adLayoutMetadata.layoutType, i$:"core"},v=hF(P,v,l),P=v instanceof V?v:m?Object.assign({},z,{renderingContent:P.renderingContent,XJ:new Map},v,{ra:$O(e,h)(z),clientMetadata:new tT([new nY(m)]),adLayoutLoggingData:P.adLayoutMetadata.adLayoutLoggingData}):new V("Not able to parse an SDF PlayerUnderlay layout because the triggeringMediaLayoutId in AdSlotMetadata is missing")):P=new V("DisplayUnderlayTextGridCardsLayoutViewModel is missing"):P.adLayoutMetadata.layoutType==="LAYOUT_TYPE_VIDEO_AD_INFO"?g.a(P.renderingContent,R1w)? (z={layoutId:P.adLayoutMetadata.layoutId,layoutType:P.adLayoutMetadata.layoutType,i$:"core"},v=hF(P,v,l),P=v instanceof V?v:Object.assign({},z,{renderingContent:P.renderingContent,XJ:new Map([])},v,{ra:$O(e,h)(z),adLayoutLoggingData:P.adLayoutMetadata.adLayoutLoggingData,clientMetadata:new tT([])})):P=new V("AdsEngagementPanelSectionListViewModel is missing"):P=new V("LayoutType ["+P.adLayoutMetadata.layoutType+"] is invalid for PlayerUnderlaySlot");return P}; JSu=function(P,v,l,e,h,z,m,Q,t,y,C,f){if((f==null?void 0:f.Ga)===void 0||(f==null?void 0:f.KR)===void 0)return new V("Cached ad break range from cue point is missing");var k=hF(l,h,e.FW);if(k instanceof V)return k;k={layoutExitMuteTriggers:[],layoutExitNormalTriggers:k.layoutExitNormalTriggers,layoutExitSkipTriggers:[],VD:[],layoutExitUserInputSubmittedTriggers:[]};if(g.a(l.renderingContent,c4))return P=ASD(P,v,l,k,h,z,Q,t,e.FW,m,f.Ga,f.KR),P instanceof V?P:P.m_===void 0?new V("Expecting associatedInPlayerSlot for single DAI media layout"): {layout:P.layout,J3:[P.m_]};var w=g.a(l.renderingContent,uJ);if(w){if(!zO(l.adLayoutMetadata))return new V("Invalid ad layout metadata");if(!KO(w))return new V("Invalid sequential layout");w=w.sequentialLayouts.map(function(I){return I.playerBytesAdLayoutRenderer}); P=Y2D(P,v,l,k,w,h,e,z,m,t,Q,y,f.Ga,f.KR,C);return P instanceof V?P:{layout:P.Sp,J3:P.J3}}return new V("Not able to convert a sequential layout")}; Y2D=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I){var J=btD(h,k,w);if(J instanceof V)return J;var K=[],q=[];J=g.N(J);for(var A=J.next();!A.done;A=J.next()){var x=A.value;A=P;var S=h[x.AA],B=x,E=v;x=z;var r=m,hq=Q,R7=t,Pw=y,H=C,T=m6(S);if(T instanceof V)A=T;else{var n={layoutId:S.adLayoutMetadata.layoutId,layoutType:S.adLayoutMetadata.layoutType,i$:"adapter"};B=xjw(E,S,B,x);B instanceof V?A=B:(A=Object.assign({},n,R8,{XJ:T,renderingContent:S.renderingContent,clientMetadata:new tT(B),ra:$O(hq,A)(n),adLayoutLoggingData:S.adLayoutMetadata.adLayoutLoggingData}), A=(S=QH(H,A,x,r.FW,hq,R7,Pw,void 0,!0))?S instanceof V?S:{layout:A,m_:S}:new V("Expecting associatedInPlayerSlot"))}if(A instanceof V)return A;K.push(A.layout);q.push(A.m_)}h={layoutId:l.adLayoutMetadata.layoutId,layoutType:l.adLayoutMetadata.layoutType,i$:"core"};v=[new Zj(Number(l.driftRecoveryMs)),new S$(k),new GH(w),new vJ(zu(v)),new P2(f),new BJ({})];I&&v.push(new hT({}));return{Sp:Object.assign({},h,e,{xq:K,XJ:new Map,clientMetadata:new tT(v),ra:$O(Q,P)(h)}),J3:q}}; ASD=function(P,v,l,e,h,z,m,Q,t,y,C,f){if(!Yj(l))return new V("Invalid PlayerBytesAdLayoutRenderer");var k=m6(l);if(k instanceof V)return k;var w={layoutId:l.adLayoutMetadata.layoutId,layoutType:l.adLayoutMetadata.layoutType,i$:"core"},I=g.a(l.renderingContent,c4);if(!I)return new V("Invalid rendering content for DAI media layout");I=VM(I,!1);C={P$:I,AA:0,Je:C,Lv:Math.min(C+I.videoLengthSeconds*1E3,f),Hw:new YW(0,[I.videoLengthSeconds])};var J;f=(J=Number(l.driftRecoveryMs))!=null?J:void 0;v=xjw(v, l,C,h,f);if(v instanceof V)return v;P=Object.assign({},w,e,{XJ:k,renderingContent:l.renderingContent,clientMetadata:new tT(v),ra:$O(z,P)(w),adLayoutLoggingData:l.adLayoutMetadata.adLayoutLoggingData});return(h=QH(m,P,h,t,z,y,Q,void 0,!0))?h instanceof V?h:{layout:P,m_:h}:new V("Expecting associatedInPlayerSlot")}; uYD=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I,J){var K=hF(l,z,h.FW);if(K instanceof V)return K;if(g.a(l.renderingContent,c4)){t=pT2([l],h,t);if(t instanceof V)return t;if(t.length!==1)return new V("Only expected one media layout.");P=Lq7(P,v,l,K,t[0],void 0,"core",e,z,m,Q,y,k,w,I,h.FW,f,void 0,J);return P instanceof V?P:{layout:P.layout,J3:P.m_?[P.m_]:[]}}var q=g.a(l.renderingContent,uJ);if(q){if(!zO(l.adLayoutMetadata))return new V("Invalid ad layout metadata");if(!KO(q))return new V("Invalid sequential layout"); q=q.sequentialLayouts.map(function(A){return A.playerBytesAdLayoutRenderer}); P=S2W(P,v,l.adLayoutMetadata,K,q,e,z,h,t,m,Q,y,C,f,I,k,w,J);return P instanceof V?P:{layout:P.Sp,J3:P.J3}}return new V("Not able to convert a sequential layout")}; S2W=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w,I,J,K,q){var A=new zH({current:null}),x=pT2(h,Q,t);if(x instanceof V)return x;t=[];for(var S=[],B=void 0,E=0;E 0&&(E.push(q),E.push(new hu(B.adPodSkipTarget)));(z=y.get(B.externalVideoId))&&E.push(new EK(z));z=E}else z=new V("Invalid vod media renderer")}if(z instanceof V)return z;P=Object.assign({},m,e,{XJ:x,renderingContent:l.renderingContent,clientMetadata:new tT(z),ra:$O(C,P)(m),adLayoutLoggingData:l.adLayoutMetadata.adLayoutLoggingData});l=g.a(l.renderingContent,c4);if(!l||!JA(l))return new V("Invalid meida renderer");f=oL(f,l.externalVideoId);f.instreamVideoAdRenderer=l;f.Dv="AD_PLACEMENT_KIND_START";return w?(t=QH(k,P,t,J,C,K,I,q,!1),t instanceof V?t:BeD(P.layoutId,k)&&t?{layout:Object.assign({},P,{clientMetadata:new tT(z.concat(new fY(t)))})}:{layout:P,m_:t}): {layout:P}}; GI7=function(P,v,l,e,h){if(!Yj(v))return new V("Invalid PlayerBytesAdLayoutRenderer");var z=g.a(v.renderingContent,kq);if(!z||z.durationMilliseconds===void 0)return new V("Invalid endcap renderer");var m={layoutId:v.adLayoutMetadata.layoutId,layoutType:v.adLayoutMetadata.layoutType,i$:"adapter"};e=[new OK(z.durationMilliseconds),new rH({impressionCommands:void 0,abandonCommands:z.abandonCommands?[{commandExecutorCommand:z.abandonCommands}]:void 0,completeCommands:z.completionCommands}),new vJ(e), new Ju("LAYOUT_TYPE_ENDCAP")];if(h){e.push(new e$(h.Hw.adPodIndex-1));e.push(new Xw(h.Hw.adPodIndex));var Q;e.push(new hu((Q=h.adPodSkipTarget)!=null?Q:-1))}return Object.assign({},m,R8,{renderingContent:v.renderingContent,clientMetadata:new tT(e),XJ:z.skipPings?new Map([["skip",z.skipPings]]):new Map,ra:$O(l,P)(m),adLayoutLoggingData:v.adLayoutMetadata.adLayoutLoggingData})}; QH=function(P,v,l,e,h,z,m,Q,t){P=P.filter(function(C){return C.adSlotMetadata.slotType==="SLOT_TYPE_IN_PLAYER"&&C.adSlotMetadata.triggeringSourceLayoutId===v.layoutId}); if(P.length!==0){if(P.length!==1)return new V("Invalid InPlayer slot association for the given PlayerBytes layout");P=P[0];m=Nea(P,z,l,e,m);if(m instanceof V)return m;var y;z={slotId:P.adSlotMetadata.slotId,slotType:P.adSlotMetadata.slotType,slotPhysicalPosition:(y=P.adSlotMetadata.slotPhysicalPosition)!=null?y:1,i$:"core",slotEntryTrigger:m.slotEntryTrigger,slotFulfillmentTriggers:m.slotFulfillmentTriggers,slotExpirationTriggers:m.slotExpirationTriggers};y=g.a(P.fulfillmentContent.fulfilledLayout, ge2);if(!y||!z1x(y))return new V("Invalid InPlayerAdLayoutRenderer");m={layoutId:y.adLayoutMetadata.layoutId,layoutType:y.adLayoutMetadata.layoutType,i$:"core"};l=hF(y,l,e);if(l instanceof V)return l;e=[];t&&e.push(new BJ({}));if(y.adLayoutMetadata.layoutType==="LAYOUT_TYPE_MEDIA_LAYOUT_PLAYER_OVERLAY")e.push.apply(e,g.u(itD(P.adSlotMetadata.triggerEvent,v)));else if(y.adLayoutMetadata.layoutType==="LAYOUT_TYPE_ENDCAP")e.push(new vJ(zu(P.adSlotMetadata.triggerEvent))),Q&&e.push(Q);else return new V("Not able to parse an SDF InPlayer layout"); h=Object.assign({},m,l,{renderingContent:y.renderingContent,XJ:new Map,ra:$O(h,z)(m),clientMetadata:new tT(e),adLayoutLoggingData:y.adLayoutMetadata.adLayoutLoggingData});return Object.assign({},z,{fulfilledLayout:h,clientMetadata:new tT([])})}}; itD=function(P,v){var l=[];l.push(new vJ(zu(P)));l.push(new nY(v.layoutId));(P=yf(v.clientMetadata,"metadata_type_player_bytes_callback_ref"))&&l.push(new cJ(P));(P=yf(v.clientMetadata,"metadata_type_ad_pod_skip_target_callback_ref"))&&l.push(new zH(P));(P=yf(v.clientMetadata,"metadata_type_remote_slots_data"))&&l.push(new EK(P));(P=yf(v.clientMetadata,"metadata_type_ad_next_params"))&&l.push(new od(P));(P=yf(v.clientMetadata,"metadata_type_ad_video_clickthrough_endpoint"))&&l.push(new s2(P));(P= yf(v.clientMetadata,"metadata_type_ad_pod_info"))&&l.push(new l1(P));(v=yf(v.clientMetadata,"metadata_type_ad_video_id"))&&l.push(new m1(v));return l}; XTa=function(P,v,l,e,h,z){function m(y){return tF(v,y)} var Q=e.AF.inPlayerSlotId,t={layoutId:e.AF.inPlayerLayoutId,layoutType:"LAYOUT_TYPE_ENDCAP",i$:"core"};l={slotId:Q,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:new S5(m,P),slotFulfillmentTriggers:[new Mi(m,Q)],slotExpirationTriggers:[new T$(m,Q),new Ow(m,l)]};P=Object.assign({},t,{layoutExitNormalTriggers:[new Xg(m,P)],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],XJ:new Map,clientMetadata:new tT([new ky(e.AF), new vJ(e.adPlacementConfig),h]),ra:$O(z,l)(t),adLayoutLoggingData:e.AF.adLayoutLoggingData});return Object.assign({},l,{clientMetadata:new tT([new j$(P)])})}; BeD=function(P,v){v=g.N(v);for(var l=v.next();!l.done;l=v.next())if(l=l.value,l.adSlotMetadata.slotType==="SLOT_TYPE_PLAYER_UNDERLAY"){var e=g.a(l.fulfillmentContent.fulfilledLayout,LO);if(e&&(e=g.a(e.renderingContent,xj))&&e.associatedPlayerBytesLayoutId===P)return l}}; Nea=function(P,v,l,e,h){var z=Ujy(EB(P.slotEntryTrigger,l,e),h,P,v);if(z instanceof V)return z;for(var m=[],Q=g.N(P.slotFulfillmentTriggers),t=Q.next();!t.done;t=Q.next()){t=EB(t.value,l,e);if(t instanceof V)return t;m.push(t)}m=Ztw(m,h,P,v);v=[];P=g.N(P.slotExpirationTriggers);for(h=P.next();!h.done;h=P.next()){h=EB(h.value,l,e);if(h instanceof V)return h;v.push(h)}return{slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:v}}; Ujy=function(P,v,l,e){return v&&l.adSlotMetadata.slotType==="SLOT_TYPE_PLAYER_BYTES"&&P instanceof bz?new AX(function(h){return tF(e,h)},l.adSlotMetadata.slotId):P}; Ztw=function(P,v,l,e){return v&&l.adSlotMetadata.slotType==="SLOT_TYPE_PLAYER_BYTES"?P.map(function(h){return h instanceof Mi?new P4(function(z){return tF(e,z)},l.adSlotMetadata.slotId):h}):P}; hF=function(P,v,l){for(var e=[],h=g.N(P.layoutExitNormalTriggers||[]),z=h.next();!z.done;z=h.next()){z=EB(z.value,v,l);if(z instanceof V)return z;e.push(z)}h=[];z=g.N(P.layoutExitSkipTriggers||[]);for(var m=z.next();!m.done;m=z.next()){m=EB(m.value,v,l);if(m instanceof V)return m;h.push(m)}z=[];m=g.N(P.layoutExitMuteTriggers||[]);for(var Q=m.next();!Q.done;Q=m.next()){Q=EB(Q.value,v,l);if(Q instanceof V)return Q;z.push(Q)}m=[];P=g.N(P.layoutExitUserInputSubmittedTriggers||[]);for(Q=P.next();!Q.done;Q= P.next()){Q=EB(Q.value,v,l);if(Q instanceof V)return Q;m.push(Q)}return{layoutExitNormalTriggers:e,layoutExitSkipTriggers:h,layoutExitMuteTriggers:z,layoutExitUserInputSubmittedTriggers:m,VD:[]}}; m6=function(P){var v=g.a(P.renderingContent,c4);if(v==null?0:v.pings)return pe(v.pings);P=g.a(P.renderingContent,kq);return(P==null?0:P.skipPings)?new Map([["skip",P.skipPings]]):new Map}; xjw=function(P,v,l,e,h){v=g.a(v.renderingContent,c4);if(!v)return new V("Invalid rendering content for DAI media layout");P=[new RR(e),new Yy(l.P$.videoLengthSeconds),new b1(l.P$.playerVars),new S$(l.Je),new GH(l.Lv),new Xw(l.AA),new vJ(zu(P)),new m1(l.P$.adVideoId),new l1(l.Hw),v.sodarExtensionData&&new LY(v.sodarExtensionData),new cJ({current:null}),new BJ({}),new Vm(x4(v.pings))].filter(nlB);h!==void 0&&P.push(new Zj(h));return P}; btD=function(P,v,l){P=P.map(function(t){return VM(g.a(t.renderingContent,c4),!1)}); var e=P.map(function(t){return t.videoLengthSeconds}),h=e.map(function(t,y){return new YW(y,e)}),z=v,m=l,Q=[]; P.forEach(function(t,y){m=Math.min(z+t.videoLengthSeconds*1E3,l);W4(t.playerVars,h[y]);Q.push({P$:t,Je:z,Lv:m,AA:y,Hw:h[y]});z=m}); return Q}; pT2=function(P,v,l){for(var e=[],h=g.N(P),z=h.next();!z.done;z=h.next())if(z=g.a(z.value.renderingContent,c4)){if(!JA(z))return new V("Invalid vod media renderer");e.push(jdD(z))}h=e.map(function(f){return f.zg}); z=[];for(var m=0,Q=0;Q 0?Pw:-1;else if(n=g.a(T,kq)){T=V2D(P,v,l,n,z,J,Q,r,Pw);if(T instanceof V){w= T;break a}T=T(k);K.push(T.pX);q=[].concat(g.u(T.Fj),g.u(q));A=[].concat(g.u(T.Bf),g.u(A));T.m_&&(R7=[T.m_].concat(g.u(R7)))}else if(n=g.a(T,FE)){if(w===void 0){w=new V("Composite Survey must already have a Survey Bundle with required metadata.",{instreamSurveyAdRenderer:n});break a}T=vy6(P,v,l,z,n,E,Q,w,J,Pb(C,"supports_multi_step_on_desktop"));if(T instanceof V){w=T;break a}T=T(k);K.push(T.pX);T.m_&&R7.push(T.m_);q=[].concat(g.u(T.Fj),g.u(q));A=[].concat(g.u(T.Bf),g.u(A));x=[].concat(g.u(T.qz),g.u(x)); S=[].concat(g.u(T.oJ),g.u(S));B=[E].concat(g.u(B))}else if(T=g.a(T,AA)){T=lj2(P,v,l,z,T,E,Q,J);if(T instanceof V){w=T;break a}T=T(k);K.push(T.pX);T.m_&&R7.push(T.m_);A=[].concat(g.u(T.Bf),g.u(A))}else{w=new V("Unsupported linearAd found in LinearAdSequenceRenderer.");break a}w={xq:K,layoutExitSkipTriggers:q,layoutExitUserInputSubmittedTriggers:x,VD:S,layoutExitMuteTriggers:A,jf:B,J3:R7}}}else a:if(J=yuq(e,l,C),J instanceof V)w=J;else{K=0;q=[];A=[];x=[];S=[];B=[];E=[];r=new qS({current:null});hq=new zH({current:null}); R7=!1;H=[];Pw=-1;I=g.N(e);for(T=I.next();!T.done;T=I.next())if(T=T.value,g.a(T,qf)){T=dju(v,l,g.a(T,qf),Q);if(T instanceof V){w=T;break a}T=T(k);q.push(T.pX);A=[].concat(g.u(T.Fj),g.u(A));x=[].concat(g.u(T.Bf),g.u(x));T.m_&&(H=[T.m_].concat(g.u(H)))}else if(g.a(T,c4)){Pw=dk(g.a(T,c4),l,C);if(Pw instanceof Qf){w=new V(Pw);break a}T=new YW(K,J);T=C1w(v,Pw.layoutId,Pw.QT,l,PX(Pw.playerVars,Pw.eR,m,y,T),Pw.zg,z,T,Q(k),hq,t.get(Pw.QT.externalVideoId),void 0,f);K++;q.push(T.pX);A=[].concat(g.u(T.Fj),g.u(A)); x=[].concat(g.u(T.Bf),g.u(x));R7||(E.push(hq),R7=!0);Pw=(Pw=Pw.QT.adPodSkipTarget)&&Pw>0?Pw:-1}else if(g.a(T,kq)){T=V2D(P,v,l,g.a(T,kq),z,K,Q,hq,Pw);if(T instanceof V){w=T;break a}T=T(k);q.push(T.pX);A=[].concat(g.u(T.Fj),g.u(A));x=[].concat(g.u(T.Bf),g.u(x));T.m_&&(H=[T.m_].concat(g.u(H)))}else if(g.a(T,FE)){if(w===void 0){w=new V("Composite Survey must already have a Survey Bundle with required metadata.",{instreamSurveyAdRenderer:g.a(T,FE)});break a}T=vy6(P,v,l,z,g.a(T,FE),r,Q,w,K,Pb(C,"supports_multi_step_on_desktop")); if(T instanceof V){w=T;break a}T=T(k);q.push(T.pX);T.m_&&H.push(T.m_);A=[].concat(g.u(T.Fj),g.u(A));x=[].concat(g.u(T.Bf),g.u(x));S=[].concat(g.u(T.qz),g.u(S));B=[].concat(g.u(T.oJ),g.u(B));E=[r].concat(g.u(E))}else if(g.a(T,AA)){T=lj2(P,v,l,z,g.a(T,AA),r,Q,K);if(T instanceof V){w=T;break a}T=T(k);q.push(T.pX);T.m_&&H.push(T.m_);x=[].concat(g.u(T.Bf),g.u(x))}else{w=new V("Unsupported linearAd found in LinearAdSequenceRenderer.");break a}w={xq:q,layoutExitSkipTriggers:A,layoutExitUserInputSubmittedTriggers:S, VD:B,layoutExitMuteTriggers:x,jf:E,J3:H}}w instanceof V?k=w:(B=k.slotId,J=w.xq,K=w.layoutExitSkipTriggers,q=w.layoutExitMuteTriggers,A=w.layoutExitUserInputSubmittedTriggers,x=w.jf,k=Q(k),S=h?h.layoutType:"LAYOUT_TYPE_COMPOSITE_PLAYER_BYTES",B=h?h.layoutId:vb(v.K.get(),S,B),E={layoutId:B,layoutType:S,i$:"core"},k={layout:{layoutId:B,layoutType:S,XJ:new Map,layoutExitNormalTriggers:[new WE(v.W,B)],layoutExitSkipTriggers:K,layoutExitMuteTriggers:q,layoutExitUserInputSubmittedTriggers:A,VD:[],i$:"core", clientMetadata:new tT([new Fw(J)].concat(g.u(x))),ra:k(E)},J3:w.J3});return k}}; yuq=function(P,v,l){var e=[];P=g.N(P);for(var h=P.next();!h.done;h=P.next())if(h=h.value,g.a(h,c4)){h=dk(g.a(h,c4),v,l);if(h instanceof Qf)return new V(h);e.push(h.zg)}return e}; gyB=function(P,v,l,e,h,z,m,Q){if(!neD(l,Q===void 0?!1:Q))return new V("Received invalid InstreamSurveyAdRenderer for VOD single survey.",{InstreamSurveyAdRenderer:l});var t=rk(l);if(t<=0)return new V("InstreamSurveyAdRenderer should have valid duration.",{instreamSurveyAdRenderer:l});var y=new qS({current:null}),C=HaD(P,v,l,y,e,z,m);return fj2(P,e,z,t,h,function(f,k){var w=f.slotId,I=Mf(l);f=m(f);var J,K=(J=kC(v,e,l.layoutId,"createMediaBreakLayoutAndAssociatedInPlayerSlotForVodSurvey"))!=null?J: vb(v.K.get(),"LAYOUT_TYPE_MEDIA_BREAK",w);w={layoutId:K,layoutType:"LAYOUT_TYPE_MEDIA_BREAK",i$:"core"};J=C(K,k);var q=yf(J.clientMetadata,"metadata_type_fulfilled_layout");q||Iq("Could not retrieve overlay layout ID during VodMediaBreakLayout for survey creation. This should never happen.");I=[new vJ(e),new OK(t),new rH(I),y];q&&I.push(new Ju(q.layoutType));return{ZIg:{layoutId:K,layoutType:"LAYOUT_TYPE_MEDIA_BREAK",XJ:new Map,layoutExitNormalTriggers:[new WE(v.W,K)],layoutExitSkipTriggers:[new rU(v.W, k.layoutId)],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[new lJ(v.W,k.layoutId)],VD:[],i$:"core",clientMetadata:new tT(I),ra:f(w)},z6$:J}})}; kHu=function(P){if(!u$u(P))return!1;var v=g.a(P.adVideoStart,nd);return v?g.a(P.linearAd,c4)&&fO(v)?!0:(Iq("Invalid Sandwich with notify"),!1):!1}; wJD=function(P){if(P.linearAds==null)return!1;P=g.a(P.adStart,nd);return P?fO(P)?!0:(Iq("Invalid LASR with notify"),!1):!1}; $S7=function(P){if(!JfW(P))return!1;P=g.a(P.adStart,nd);return P?fO(P)?!0:(Iq("Invalid LASR with notify"),!1):!1}; Nz=function(P,v,l,e,h,z,m,Q,t,y){this.Y=P;this.K=v;this.W=l;this.L0=e;this.dN=h;this.G=z;this.t5=m;this.OL=Q;this.wv=t;this.loadPolicy=y===void 0?1:y}; AfD=function(P,v,l,e,h,z,m,Q,t,y){var C=[];if(v.length===0&&e.length===0&&l.length===0)return C;v=v.filter(Nf);var f=l.filter($bw),k=e.filter(Nf),w=new Map,I=Dja(v),J=l.some(function(n){var W;return(n==null?void 0:(W=n.adSlotMetadata)==null?void 0:W.slotType)==="SLOT_TYPE_PLAYER_BYTES"}),K=l.some(function(n){var W; return(n==null?void 0:(W=n.adSlotMetadata)==null?void 0:W.slotType)==="SLOT_TYPE_PLAYER_UNDERLAY"}),q=l.some(function(n){var W; return(n==null?void 0:(W=n.adSlotMetadata)==null?void 0:W.slotType)==="SLOT_TYPE_IN_PLAYER"}); l=l.some(function(n){var W,du;return(n==null?void 0:(W=n.adSlotMetadata)==null?void 0:W.slotType)==="SLOT_TYPE_BELOW_PLAYER"||(n==null?void 0:(du=n.adSlotMetadata)==null?void 0:du.slotType)==="SLOT_TYPE_ABOVE_FEED"}); if(J||K||q||l)y=q27(f,v,Q,h,I,P.dN.get(),P.loadPolicy,w,P.L0.get(),P.Y.get(),q,m,t,y),y instanceof V?Iq(y,void 0,void 0,{contentCpn:h}):C.push.apply(C,g.u(y));y=g.N(v);for(l=y.next();!l.done;l=y.next())l=l.value,K=Ijq(P,w,l,h,z,m,J,Q,I,t,f),K instanceof V?Iq(K,void 0,void 0,{renderer:l.renderer,config:l.config.adPlacementConfig,kind:l.config.adPlacementConfig.kind,contentCpn:h,daiEnabled:m}):C.push.apply(C,g.u(K));DSP(P.L0.get())||(z=nyy(P,k,h,Q,I,w),C.push.apply(C,g.u(z)));if(P.G===null||m&&!Q.hT){var A, x,S;P=Q.Ei&&v.length===1&&((A=v[0].config)==null?void 0:(x=A.adPlacementConfig)==null?void 0:x.kind)==="AD_PLACEMENT_KIND_CUE_POINT_TRIGGERED"&&((S=v[0].renderer)==null?void 0:S.adBreakServiceRenderer);if(!C.length&&!P){var B,E,r,hq;Iq("Expected slots parsed from AdPlacementRenderers for DAI",void 0,void 0,{"AdPlacementRenderer count":v.length,contentCpn:h,"first APR kind":(B=v[0])==null?void 0:(E=B.config)==null?void 0:(r=E.adPlacementConfig)==null?void 0:r.kind,renderer:(hq=v[0])==null?void 0:hq.renderer})}return C}A= e.filter(Nf);C.push.apply(C,g.u(Zau(w,A,P.K.get(),P.G,h,J)));if(!C.length){var R7,Pw,H,T;Iq("Expected slots parsed from AdPlacementRenderers",void 0,void 0,{"AdPlacementRenderer count":v.length,contentCpn:h,daiEnabled:m.toString(),"first APR kind":(R7=v[0])==null?void 0:(Pw=R7.config)==null?void 0:(H=Pw.adPlacementConfig)==null?void 0:H.kind,renderer:(T=v[0])==null?void 0:T.renderer})}return C}; nyy=function(P,v,l,e,h,z){function m(k){return $O(P.dN.get(),k)} var Q=[];v=g.N(v);for(var t=v.next();!t.done;t=v.next()){t=t.value;var y=t.renderer,C=y.sandwichedLinearAdRenderer,f=y.linearAdSequenceRenderer;C&&kHu(C)?(Iq("Found AdNotify with SandwichedLinearAdRenderer"),f=g.a(C.adVideoStart,nd),C=g.a(C.linearAd,c4),OB(z,y,t.config.adPlacementConfig.kind),y=void 0,f=QdD((y=f)==null?void 0:y.layout.layoutId,P.K.get(),P.W.get(),t.config.adPlacementConfig,t.adSlotLoggingData,C,l,e,m,h,P.loadPolicy,P.L0.get(),P.dN.get()),f instanceof V?Iq(f):Q.push.apply(Q,g.u(f))): f&&(!f.adLayoutMetadata&&wJD(f)||f.adLayoutMetadata&&$S7(f))&&(Iq("Found AdNotify with LinearAdSequenceRenderer"),OB(z,y,t.config.adPlacementConfig.kind),y=void 0,C=exD((y=g.a(f.adStart,nd))==null?void 0:y.layout.layoutId,P.K.get(),P.W.get(),t.config.adPlacementConfig,t.adSlotLoggingData,f.linearAds,zO(f.adLayoutMetadata)?f.adLayoutMetadata:void 0,l,e,m,h,P.loadPolicy,P.L0.get()),C instanceof V?Iq(C):Q.push.apply(Q,g.u(C)))}return Q}; Ijq=function(P,v,l,e,h,z,m,Q,t,y,C){function f(q){return $O(P.dN.get(),q)} var k=l.renderer,w=l.config.adPlacementConfig,I=w.kind,J=l.adSlotLoggingData,K=Q.hT&&I==="AD_PLACEMENT_KIND_START";K=z&&!K;if(k.adsEngagementPanelRenderer!=null)return sB(v,l.elementId,I,k.adsEngagementPanelRenderer.isContentVideoEngagementPanel,k.adsEngagementPanelRenderer.adVideoId,k.adsEngagementPanelRenderer.associatedCompositePlayerBytesLayoutId,w,J,function(q,A,x,S){var B=P.W.get(),E=q.slotId,r=k.adsEngagementPanelRenderer;q=$O(P.dN.get(),q);return JF(B,E,"LAYOUT_TYPE_PANEL_TEXT_ICON_IMAGE_TILES_BUTTON", new WT(r),A,x,r.impressionPings,q,k.adsEngagementPanelRenderer.adLayoutLoggingData,S)}),[]; if(k.adsEngagementPanelLayoutViewModel)return sB(v,l.elementId,I,k.adsEngagementPanelLayoutViewModel.isContentVideoEngagementPanel,k.adsEngagementPanelLayoutViewModel.adVideoId,k.adsEngagementPanelLayoutViewModel.associatedCompositePlayerBytesLayoutId,w,J,function(q,A,x,S){var B=P.W.get(),E=q.slotId,r=k.adsEngagementPanelLayoutViewModel;q=$O(P.dN.get(),q);return uF(B,E,"LAYOUT_TYPE_PANEL",new O2(r),A,x,q,k.adsEngagementPanelLayoutViewModel.adLayoutLoggingData,S)}),[]; if(k.actionCompanionAdRenderer!=null){if(k.actionCompanionAdRenderer.showWithoutLinkedMediaLayout)return Gi6(P.K.get(),P.G,P.W.get(),k.actionCompanionAdRenderer,w,J,e,f);sB(v,l.elementId,I,k.actionCompanionAdRenderer.isContentVideoCompanion,k.actionCompanionAdRenderer.adVideoId,k.actionCompanionAdRenderer.associatedCompositePlayerBytesLayoutId,w,J,function(q,A,x,S){var B=P.W.get(),E=q.slotId,r=k.actionCompanionAdRenderer;q=$O(P.dN.get(),q);return JF(B,E,"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON", new HT(r),A,x,r.impressionPings,q,k.actionCompanionAdRenderer.adLayoutLoggingData,S)})}else if(k.topBannerImageTextIconButtonedLayoutViewModel!==void 0){if(k.topBannerImageTextIconButtonedLayoutViewModel.showWithoutLinkedMediaLayout)return Xqa(P.K.get(),P.G,P.W.get(),k.topBannerImageTextIconButtonedLayoutViewModel,w,J,e,f); sB(v,l.elementId,I,k.topBannerImageTextIconButtonedLayoutViewModel.isContentVideoCompanion,k.topBannerImageTextIconButtonedLayoutViewModel.adVideoId,k.topBannerImageTextIconButtonedLayoutViewModel.associatedCompositePlayerBytesLayoutId,w,J,function(q,A,x,S){var B=P.W.get(),E=q.slotId,r=k.topBannerImageTextIconButtonedLayoutViewModel;q=$O(P.dN.get(),q);return uF(B,E,"LAYOUT_TYPE_COMPANION_WITH_ACTION_BUTTON",new E2(r),A,x,q,k.topBannerImageTextIconButtonedLayoutViewModel.adLayoutLoggingData,S)})}else if(k.imageCompanionAdRenderer)sB(v, l.elementId,I,k.imageCompanionAdRenderer.isContentVideoCompanion,k.imageCompanionAdRenderer.adVideoId,k.imageCompanionAdRenderer.associatedCompositePlayerBytesLayoutId,w,J,function(q,A,x,S){var B=P.W.get(),E=q.slotId,r=k.imageCompanionAdRenderer; q=$O(P.dN.get(),q);return JF(B,E,"LAYOUT_TYPE_COMPANION_WITH_IMAGE",new Mj(r),A,x,r.impressionPings,q,k.imageCompanionAdRenderer.adLayoutLoggingData,S)}); else if(k.bannerImageLayoutViewModel)sB(v,l.elementId,I,k.bannerImageLayoutViewModel.isContentVideoCompanion,k.bannerImageLayoutViewModel.adVideoId,k.bannerImageLayoutViewModel.associatedCompositePlayerBytesLayoutId,w,J,function(q,A,x,S){var B=P.W.get(),E=q.slotId,r=k.bannerImageLayoutViewModel;q=$O(P.dN.get(),q);return uF(B,E,"LAYOUT_TYPE_COMPANION_WITH_IMAGE",new TI(r),A,x,q,k.bannerImageLayoutViewModel.adLayoutLoggingData,S)}); else if(k.shoppingCompanionCarouselRenderer)sB(v,l.elementId,I,k.shoppingCompanionCarouselRenderer.isContentVideoCompanion,k.shoppingCompanionCarouselRenderer.adVideoId,k.shoppingCompanionCarouselRenderer.associatedCompositePlayerBytesLayoutId,w,J,function(q,A,x,S){var B=P.W.get(),E=q.slotId,r=k.shoppingCompanionCarouselRenderer;q=$O(P.dN.get(),q);return JF(B,E,"LAYOUT_TYPE_COMPANION_WITH_SHOPPING",new Vg(r),A,x,r.impressionPings,q,k.shoppingCompanionCarouselRenderer.adLayoutLoggingData,S)}); else if(k.adBreakServiceRenderer){if(!LnP(l))return[];if(I==="AD_PLACEMENT_KIND_PAUSE")return pqx(P.K.get(),w,J,l.renderer.adBreakServiceRenderer,e);if(I!=="AD_PLACEMENT_KIND_CUE_POINT_TRIGGERED"&&I!=="AD_PLACEMENT_KIND_PREFETCH_TRIGGERED")return xbw(P.K.get(),w,J,l.renderer.adBreakServiceRenderer,e,h,z);Q.Ei||Iq("Received non-live cue point triggered AdBreakServiceRenderer",void 0,void 0,{kind:I,adPlacementConfig:w,daiEnabledForContentVideo:String(z),isServedFromLiveInfra:String(Q.Ei),clientPlaybackNonce:Q.clientPlaybackNonce}); if(I==="AD_PLACEMENT_KIND_PREFETCH_TRIGGERED"){if(!P.t5)return new V("Received AD_PLACEMENT_KIND_PREFETCH_TRIGGERED with no playerControlsApiProvider set for interface");if(!P.wv)return new V("Received AD_PLACEMENT_KIND_PREFETCH_TRIGGERED with no PrefetchTriggerAdapter set for interface");P.wv.VV({adPlacementRenderer:l,contentCpn:e,FW:h});h=P.t5.get().getCurrentTimeSec(1,!1);return NH7(P.K.get(),l.renderer.adBreakServiceRenderer,w,h,e,J,z)}if(!P.OL)return new V("Received AD_PLACEMENT_KIND_CUE_POINT_TRIGGERED with no CuePointOpportunityAdapter set for interface"); P.OL.VV({adPlacementRenderer:l,contentCpn:e,FW:h})}else{if(k.clientForecastingAdRenderer)return WqD(P.K.get(),P.W.get(),w,J,k.clientForecastingAdRenderer,e,h,f);if(k.invideoOverlayAdRenderer)return rS2(P.K.get(),P.W.get(),w,J,k.invideoOverlayAdRenderer,e,h,f);if(k.instreamAdPlayerOverlayRenderer)return oly(P.K.get(),P.W.get(),w,J,k.instreamAdPlayerOverlayRenderer,e,f);if((k.linearAdSequenceRenderer||k.instreamVideoAdRenderer)&&K)return liw(P.K.get(),P.W.get(),l,e,f,y,!P.L0.get().J.N().V("html5_override_ad_video_length_killswitch")); if(k.linearAdSequenceRenderer&&!K){if(m)return[];OB(v,k,I);if(k.linearAdSequenceRenderer.adLayoutMetadata){if(!JfW(k.linearAdSequenceRenderer))return new V("Received invalid LinearAdSequenceRenderer.")}else if(k.linearAdSequenceRenderer.linearAds==null)return new V("Received invalid LinearAdSequenceRenderer.");if(g.a(k.linearAdSequenceRenderer.adStart,nd)){Iq("Found AdNotify in LinearAdSequenceRenderer");l=g.a(k.linearAdSequenceRenderer.adStart,nd);if(!h1D(l))return new V("Invalid AdMessageRenderer."); z=k.linearAdSequenceRenderer.linearAds;return hxy(P.Y.get(),P.K.get(),P.W.get(),P.dN.get(),w,J,l,zO(k.linearAdSequenceRenderer.adLayoutMetadata)?k.linearAdSequenceRenderer.adLayoutMetadata:void 0,z,e,h,Q,f,t,P.loadPolicy,P.L0.get())}return t$W(P.K.get(),P.W.get(),w,J,k.linearAdSequenceRenderer.linearAds,zO(k.linearAdSequenceRenderer.adLayoutMetadata)?k.linearAdSequenceRenderer.adLayoutMetadata:void 0,e,h,Q,f,t,P.loadPolicy,P.L0.get(),C)}if(!k.remoteSlotsRenderer||z){if(k.instreamVideoAdRenderer&& !K){if(m)return[];OB(v,k,I);return gl2(P.K.get(),P.W.get(),w,J,k.instreamVideoAdRenderer,e,h,Q,f,t,P.loadPolicy,P.L0.get(),P.dN.get(),C)}if(k.instreamSurveyAdRenderer)return gyB(P.K.get(),P.W.get(),k.instreamSurveyAdRenderer,w,J,e,f,Pb(P.L0.get(),"supports_multi_step_on_desktop"));if(k.sandwichedLinearAdRenderer!=null)return u$u(k.sandwichedLinearAdRenderer)?g.a(k.sandwichedLinearAdRenderer.adVideoStart,nd)?(Iq("Found AdNotify in SandwichedLinearAdRenderer"),l=g.a(k.sandwichedLinearAdRenderer.adVideoStart, nd),h1D(l)?(z=g.a(k.sandwichedLinearAdRenderer.linearAd,c4))?t22(l,z,w,P.Y.get(),P.K.get(),P.W.get(),P.dN.get(),J,e,h,Q,f,t,P.loadPolicy,P.L0.get()):new V("Missing IVAR from Sandwich"):new V("Invalid AdMessageRenderer.")):t$W(P.K.get(),P.W.get(),w,J,[k.sandwichedLinearAdRenderer.adVideoStart,k.sandwichedLinearAdRenderer.linearAd],void 0,e,h,Q,f,t,P.loadPolicy,P.L0.get()):new V("Received invalid SandwichedLinearAdRenderer.");if(k.videoAdTrackingRenderer!=null)return Q=Pb(P.L0.get(),"enable_h5_shorts_ad_terminal_events")&& Q.Go,Ht9(P.K.get(),P.W.get(),k.videoAdTrackingRenderer,w,J,e,h,Q,f)}}return[]}; Kd=function(P,v,l,e,h,z,m,Q){g.U.call(this);var t=this;this.K=P;this.G=v;this.oo=e;this.t5=h;this.L0=z;this.VW=m;this.GK=Q;this.W=null;l.get().addListener(this);this.addOnDisposeCallback(function(){l.s$()||l.get().removeListener(t)}); e.get().addListener(this);this.addOnDisposeCallback(function(){e.s$()||e.get().removeListener(t)})}; uw6=function(P,v,l){var e=P.t5.get().getCurrentTimeSec(1,!1);P.L0.get().J.N().vK()&&z$(P.VW.get(),"sdai","onopp.1;evt."+l.event+";start."+l.startSecs.toFixed(3)+";d."+l.Er.toFixed(3));Ns(P.K.get(),"OPPORTUNITY_TYPE_LIVE_STREAM_BREAK_SIGNAL",function(){var h=P.G.get(),z=v.adPlacementRenderer.renderer.adBreakServiceRenderer,m=v.contentCpn,Q=v.adPlacementRenderer.adSlotLoggingData,t=cX(P.L0.get()),y=P.VW;if(h.L0.get().J.N().experiments.l$("enable_smearing_expansion_dai")){var C=g.ID(h.L0.get().J.N().experiments, "max_prefetch_window_sec_for_livestream_optimization");var f=g.ID(h.L0.get().J.N().experiments,"min_prefetch_offset_sec_for_livestream_optimization");t={b3:JuD(l),iJ:!1,cueProcessedMs:e*1E3};var k=l.startSecs+l.Er;if(e===0)t.xB=new pz(0,k*1E3);else{f=l.startSecs-f;var w=f-e;t.xB=w<=0?new pz(f*1E3,k*1E3):new pz(Math.floor(e+Math.random()*Math.min(w,C))*1E3,k*1E3)}C=t}else C={b3:JuD(l),iJ:!1},k=l.startSecs+l.Er,l.startSecs<=e?t=new pz((l.startSecs-4)*1E3,k*1E3):(f=Math.max(0,l.startSecs-e-10),t=new pz(Math.floor(e+ Math.random()*(t?e===0?0:Math.min(f,5):f))*1E3,k*1E3)),C.xB=t;h=H4(h,z,m,C,Q,[new Au(l)]);y.get().J.Za(C.xB.start/1E3-e,l.startSecs-e);return[h]})}; qz=function(P){var v,l=(v=yf(P.clientMetadata,"metadata_type_player_bytes_callback_ref"))==null?void 0:v.current;if(!l)return null;v=yf(P.clientMetadata,"metadata_type_ad_pod_skip_target_callback_ref");var e=P.layoutId,h=yf(P.clientMetadata,"metadata_type_content_cpn"),z=yf(P.clientMetadata,"metadata_type_instream_ad_player_overlay_renderer"),m=yf(P.clientMetadata,"metadata_type_player_overlay_layout_renderer"),Q=yf(P.clientMetadata,"metadata_type_player_underlay_renderer"),t=yf(P.clientMetadata, "metadata_type_ad_placement_config"),y=yf(P.clientMetadata,"metadata_type_video_length_seconds");var C=zf(P.clientMetadata,"METADATA_TYPE_MEDIA_LAYOUT_DURATION_seconds")?yf(P.clientMetadata,"METADATA_TYPE_MEDIA_LAYOUT_DURATION_seconds"):zf(P.clientMetadata,"metadata_type_layout_enter_ms")&&zf(P.clientMetadata,"metadata_type_layout_exit_ms")?(yf(P.clientMetadata,"metadata_type_layout_exit_ms")-yf(P.clientMetadata,"metadata_type_layout_enter_ms"))/1E3:void 0;return{h8:e,contentCpn:h,z4:l,Gp:v,instreamAdPlayerOverlayRenderer:z, playerOverlayLayoutRenderer:m,instreamAdPlayerUnderlayRenderer:Q,adPlacementConfig:t,videoLengthSeconds:y,m3:C,inPlayerLayoutId:yf(P.clientMetadata,"metadata_type_linked_in_player_layout_id"),inPlayerSlotId:yf(P.clientMetadata,"metadata_type_linked_in_player_slot_id")}}; cuD=function(P,v){return K19(P,v)}; qKy=function(P,v){v=K19(P,v);if(!v)return null;var l;v.m3=(l=yf(P.clientMetadata,"metadata_type_ad_pod_info"))==null?void 0:l.adBreakRemainingLengthSeconds;return v}; K19=function(P,v){var l,e=(l=yf(P.clientMetadata,"metadata_type_player_bytes_callback_ref"))==null?void 0:l.current;if(!e)return null;l=WmD(P,v);return{g3:EFW(P,v),adPlacementConfig:yf(P.clientMetadata,"metadata_type_ad_placement_config"),Os:l,contentCpn:yf(P.clientMetadata,"metadata_type_content_cpn"),inPlayerLayoutId:yf(P.clientMetadata,"metadata_type_linked_in_player_layout_id"),inPlayerSlotId:yf(P.clientMetadata,"metadata_type_linked_in_player_slot_id"),instreamAdPlayerOverlayRenderer:yf(P.clientMetadata, "metadata_type_instream_ad_player_overlay_renderer"),playerOverlayLayoutRenderer:void 0,instreamAdPlayerUnderlayRenderer:void 0,m3:void 0,z4:e,h8:P.layoutId,videoLengthSeconds:yf(P.clientMetadata,"metadata_type_video_length_seconds")}}; FR=function(P,v,l,e,h,z,m,Q,t){g.U.call(this);this.Y=P;this.T=v;this.Z=l;this.G=e;this.W=h;this.K=z;this.dN=m;this.L0=Q;this.vg=t;this.RY=!0}; F1y=function(P,v,l){return $jw(P.W.get(),v.contentCpn,v.h8,function(e){return IiW(P.K.get(),e.slotId,l,v.adPlacementConfig,v.h8,$O(P.dN.get(),e))})}; AF=function(P,v,l,e,h,z,m,Q){g.U.call(this);this.K=P;this.W=v;this.G=l;this.L0=e;this.Y=h;this.vg=z;this.t5=m;this.cR=Q}; YC=function(P){g.U.call(this);this.W=P}; Ns=function(P,v,l,e){P.W().nX(v,e);l=l();P=P.W();P.PK.zb("ADS_CLIENT_EVENT_TYPE_OPPORTUNITY_PROCESSED",v,e,l);v=g.N(l);for(l=v.next();!l.done;l=v.next())a:{e=P;l=l.value;e.PK.Dj("ADS_CLIENT_EVENT_TYPE_SLOT_RECEIVED",l);e.PK.Dj("ADS_CLIENT_EVENT_TYPE_SCHEDULE_SLOT_REQUESTED",l);try{var h=e.W;if(g.Jj(l.slotId))throw new V("Slot ID was empty",void 0,"ADS_CLIENT_ERROR_MESSAGE_INVALID_SLOT");if(qx(h,l))throw new V("Duplicate registration for slot.",{slotId:l.slotId,slotEntryTriggerType:l.slotEntryTrigger.triggerType}, "ADS_CLIENT_ERROR_MESSAGE_DUPLICATE_SLOT");if(!h.kM.zR.has(l.slotType))throw new V("No fulfillment adapter factory registered for slot of type: "+l.slotType,void 0,"ADS_CLIENT_ERROR_MESSAGE_NO_FULFILLMENT_ADAPTER_REGISTERED");if(!h.kM.Rd.has(l.slotType))throw new V("No SlotAdapterFactory registered for slot of type: "+l.slotType,void 0,"ADS_CLIENT_ERROR_MESSAGE_NO_SLOT_ADAPTER_REGISTERED");H2(h,"TRIGGER_CATEGORY_SLOT_ENTRY",l.slotEntryTrigger?[l.slotEntryTrigger]:[]);H2(h,"TRIGGER_CATEGORY_SLOT_FULFILLMENT", l.slotFulfillmentTriggers);H2(h,"TRIGGER_CATEGORY_SLOT_EXPIRATION",l.slotExpirationTriggers);var z=e.W,m=l.slotType+"_"+l.slotPhysicalPosition,Q=iq(z,m);if(qx(z,l))throw new V("Duplicate slots not supported",void 0,"ADS_CLIENT_ERROR_MESSAGE_DUPLICATE_SLOT");Q.set(l.slotId,new Ua2(l));z.W.set(m,Q)}catch(hq){hq instanceof V&&hq.FV?(e.PK.iX("ADS_CLIENT_ERROR_TYPE_REGISTER_SLOT_FAILED",hq.FV,l),Iq(hq,l,void 0,void 0,hq.F5)):(e.PK.iX("ADS_CLIENT_ERROR_TYPE_REGISTER_SLOT_FAILED","ADS_CLIENT_ERROR_MESSAGE_UNEXPECTED_ERROR", l),Iq(hq,l));break a}qx(e.W,l).T=!0;try{var t=e.W,y=qx(t,l),C=l.slotEntryTrigger,f=t.kM.hA.get(C.triggerType);f&&(f.r4("TRIGGER_CATEGORY_SLOT_ENTRY",C,l,null),y.J5.set(C.triggerId,f));for(var k=g.N(l.slotFulfillmentTriggers),w=k.next();!w.done;w=k.next()){var I=w.value,J=t.kM.hA.get(I.triggerType);J&&(J.r4("TRIGGER_CATEGORY_SLOT_FULFILLMENT",I,l,null),y.Wg.set(I.triggerId,J))}for(var K=g.N(l.slotExpirationTriggers),q=K.next();!q.done;q=K.next()){var A=q.value,x=t.kM.hA.get(A.triggerType);x&&(x.r4("TRIGGER_CATEGORY_SLOT_EXPIRATION", A,l,null),y.X.set(A.triggerId,x))}var S=t.kM.zR.get(l.slotType).get().build(t.G,l);y.j=S;var B=t.kM.Rd.get(l.slotType).get().build(t.Z,l);B.init();y.K=B}catch(hq){hq instanceof V&&hq.FV?(e.PK.iX("ADS_CLIENT_ERROR_TYPE_SCHEDULE_SLOT_FAILED",hq.FV,l),Iq(hq,l,void 0,void 0,hq.F5)):(e.PK.iX("ADS_CLIENT_ERROR_TYPE_SCHEDULE_SLOT_FAILED","ADS_CLIENT_ERROR_MESSAGE_UNEXPECTED_ERROR",l),Iq(hq,l));uq(e,l,!0);break a}e.PK.Dj("ADS_CLIENT_EVENT_TYPE_SLOT_SCHEDULED",l);e.W.PP(l);for(var E=g.N(e.K),r=E.next();!r.done;r= E.next())r.value.PP(l);YO(e,l)}}; bF=function(P,v,l,e,h){g.U.call(this);var z=this;this.K=P;this.G=v;this.nh=l;this.context=h;this.W=new Map;e.get().addListener(this);this.addOnDisposeCallback(function(){e.s$()||e.get().removeListener(z)})}; qiD=function(P,v){var l=0x8000000000000;var e=0;for(var h=g.N(v.slotFulfillmentTriggers),z=h.next();!z.done;z=h.next())z=z.value,z instanceof j5?(l=Math.min(l,z.W.start),e=Math.max(e,z.W.end)):Iq("Found unexpected fulfillment trigger for throttled slot.",v,null,{fulfillmentTrigger:z});e=new pz(l,e);l="throttledadcuerange:"+v.slotId;P.W.set(l,v);P.nh.get().addCueRange(l,e.start,e.end,!1,P);AD(P.context.L0.get())&&(v=e.start,e=e.end,h={},P.context.bZ.Lq("tcrr",(h.cid=l,h.sm=v,h.em=e,h)))}; xC=function(){g.U.apply(this,arguments);this.RY=!0;this.D0=new Map;this.W=new Map}; pd=function(P,v){P=g.N(P.D0.values());for(var l=P.next();!l.done;l=P.next())if(l.value.layoutId===v)return!0;return!1}; Ld=function(P,v){P=g.N(P.W.values());for(var l=P.next();!l.done;l=P.next()){l=g.N(l.value);for(var e=l.next();!e.done;e=l.next())if(e=e.value,e.layoutId===v)return e}Iq("Trying to retrieve an unknown layout",void 0,void 0,{isEmpty:String(g.Jj(v)),layoutId:v})}; AuD=function(){this.W=new Map}; YKw=function(P,v){this.callback=P;this.slot=v}; Sc=function(){}; bYu=function(P,v,l){this.callback=P;this.slot=v;this.t5=l}; xS9=function(P,v,l){this.callback=P;this.slot=v;this.t5=l;this.K=!1;this.W=0}; pJW=function(P,v,l){this.callback=P;this.slot=v;this.t5=l}; Gu=function(P){this.t5=P}; BX=function(P){g.U.call(this);this.ya=P;this.HK=new Map}; iF=function(P,v){for(var l=[],e=g.N(P.HK.values()),h=e.next();!h.done;h=e.next()){h=h.value;var z=h.trigger;z instanceof lJ&&z.triggeringLayoutId===v&&l.push(h)}l.length?Gf(P.ya(),l):Iq("Survey is submitted but no registered triggers can be activated.")}; UW=function(P,v,l){BX.call(this,P);var e=this;this.L0=l;v.get().addListener(this);this.addOnDisposeCallback(function(){v.s$()||v.get().removeListener(e)})}; Zo=function(P){g.U.call(this);this.W=P;this.RY=!0;this.HK=new Map;this.Z=new Set;this.G=new Set;this.Y=new Set;this.T=new Set;this.K=new Set}; jc=function(P){g.U.call(this);this.W=P;this.HK=new Map}; a8=function(P,v){for(var l=[],e=g.N(P.HK.values()),h=e.next();!h.done;h=e.next())h=h.value,h.trigger.W===v.layoutId&&l.push(h);l.length&&Gf(P.W(),l)}; HX=function(P,v,l){g.U.call(this);var e=this;this.W=P;this.context=l;this.HK=new Map;v.get().addListener(this);this.addOnDisposeCallback(function(){v.s$()||v.get().removeListener(e)})}; EW=function(P,v,l,e,h){g.U.call(this);var z=this;this.K=P;this.nh=v;this.t5=l;this.vg=e;this.context=h;this.RY=!0;this.HK=new Map;this.W=new Set;l.get().addListener(this);this.addOnDisposeCallback(function(){l.s$()||l.get().removeListener(z)})}; L1W=function(P,v,l,e,h,z,m,Q,t,y){if(Nk(P.vg.get(),1).clientPlaybackNonce!==t)throw new V("Cannot register CueRange-based trigger for different content CPN",{trigger:l});P.HK.set(l.triggerId,{Jo:new hA(v,l,e,h),cueRangeId:z});P.nh.get().addCueRange(z,m,Q,y,P);AD(P.context.L0.get())&&(t={},P.context.bZ.Lq("crr",(t.ca=v,t.tt=l.triggerType,t.st=e.slotType,t.lt=h==null?void 0:h.layoutType,t.cid=z,t.sm=m,t.em=Q,t)))}; SK7=function(P,v){P=g.N(P.HK.entries());for(var l=P.next();!l.done;l=P.next()){var e=g.N(l.value);l=e.next().value;e=e.next().value;if(v===e.cueRangeId)return l}return""}; WX=function(P,v){g.U.call(this);var l=this;this.Y=P;this.K=new Map;this.G=new Map;this.W=null;v.get().addListener(this);this.addOnDisposeCallback(function(){v.s$()||v.get().removeListener(l)}); var e;this.W=((e=v.get().Tj)==null?void 0:e.slotId)||null}; GHx=function(P,v){var l=[];P=g.N(P.values());for(var e=P.next();!e.done;e=P.next())e=e.value,e.slot.slotId===v&&l.push(e);return l}; OW=function(P){g.U.call(this);this.W=P;this.RY=!0;this.HK=new Map}; rZ=function(P,v,l){v=v.layoutId;for(var e=[],h=g.N(P.HK.values()),z=h.next();!z.done;z=h.next())if(z=z.value,z.trigger instanceof WE){var m;if(m=z.trigger.layoutId===v){m=l;var Q=puw.get(z.category);m=Q?Q===m:!1}m&&e.push(z)}e.length&&Gf(P.W(),e)}; o8=function(P){g.U.call(this);this.W=P;this.RY=!0;this.HK=new Map}; sW=function(P,v,l,e,h){g.U.call(this);var z=this;this.Z=P;this.oo=v;this.t5=l;this.VW=e;this.W=null;this.RY=!0;this.HK=new Map;this.G=new Map;v.get().addListener(this);this.addOnDisposeCallback(function(){v.s$()||v.get().removeListener(z)}); h.get().addListener(this);this.addOnDisposeCallback(function(){h.s$()||h.get().removeListener(z)})}; BH2=function(P){P.W&&(P.K&&(P.K.stop(),P.K.start()),XJq(P,"TRIGGER_TYPE_PREFETCH_CACHE_EXPIRED"))}; XJq=function(P,v){for(var l=[],e=g.N(P.HK.values()),h=e.next();!h.done;h=e.next())h=h.value,h.trigger.triggerType===v&&l.push(h);l.length>0&&Gf(P.Z(),l)}; ra=function(P,v,l,e,h){h=h===void 0?!0:h;for(var z=[],m=g.N(P.HK.values()),Q=m.next();!Q.done;Q=m.next()){Q=Q.value;var t=Q.trigger;if(t.triggerType===v){if(t instanceof iz||t instanceof Uw||t instanceof a2){if(h&&t.breakDurationMs!==l)continue;if(!h&&t.breakDurationMs===l)continue;if(e.has(t.triggerId))continue}z.push(Q)}}z.length>0&&Gf(P.Z(),z)}; iYw=function(P){P=P.adPlacementRenderer.config.adPlacementConfig;if(!P.prefetchModeConfig||!P.prefetchModeConfig.cacheFetchSmearingDurationMs)return 0;P=Number(P.prefetchModeConfig.cacheFetchSmearingDurationMs);return isNaN(P)||P<=0?0:Math.floor(Math.random()*P)}; US2=function(P){P=P.adPlacementRenderer.config.adPlacementConfig;if(P.prefetchModeConfig&&P.prefetchModeConfig.cacheFetchRefreshDurationMs&&(P=Number(P.prefetchModeConfig.cacheFetchRefreshDurationMs),!(isNaN(P)||P<=0)))return P}; Mz=function(P){P.W=null;P.HK.clear();P.G.clear();P.K&&P.K.stop();P.Y&&P.Y.stop()}; Tu=function(P){g.U.call(this);this.G=P;this.RY=!0;this.HK=new Map;this.W=new Map;this.K=new Map}; ZY7=function(P,v){var l=[];if(v=P.W.get(v.layoutId)){v=g.N(v);for(var e=v.next();!e.done;e=v.next())(e=P.K.get(e.value.triggerId))&&l.push(e)}return l}; VH=function(P){g.U.call(this);this.W=P;this.HK=new Map}; jRw=function(P,v){for(var l=[],e=g.N(P.HK.values()),h=e.next();!h.done;h=e.next())h=h.value,h.trigger instanceof AX&&h.trigger.slotId===v&&l.push(h);l.length>=1&&Gf(P.W(),l)}; aj6=function(P,v){var l={slotId:Jn(v,"SLOT_TYPE_IN_PLAYER"),slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,slotEntryTrigger:void 0,slotFulfillmentTriggers:[],slotExpirationTriggers:[],i$:"surface",clientMetadata:new tT([])},e=Object,h=e.assign;v=vb(v,"LAYOUT_TYPE_TEXT_BANNER_OVERLAY",l.slotId);v={layoutId:v,layoutType:"LAYOUT_TYPE_TEXT_BANNER_OVERLAY",XJ:new Map,layoutExitNormalTriggers:[],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"surface", clientMetadata:new tT([]),ra:qc9(!1,l.slotId,l.slotType,l.slotPhysicalPosition,l.i$,l.slotEntryTrigger,l.slotFulfillmentTriggers,l.slotExpirationTriggers,v,"LAYOUT_TYPE_TEXT_BANNER_OVERLAY","surface")};return h.call(e,{},P,{r5$:!0,slot:l,layout:v})}; baD=function(P,v,l,e){var h=P.kind;e=e?!1:!P.hideCueRangeMarker;switch(h){case "AD_PLACEMENT_KIND_START":return e={b3:new pz(-0x8000000000000,-0x8000000000000),iJ:e},l!=null&&(e.xB=new pz(-0x8000000000000,-0x8000000000000)),e;case "AD_PLACEMENT_KIND_END":return e={b3:new pz(0x7ffffffffffff,0x8000000000000),iJ:e},l!=null&&(e.xB=new pz(Math.max(0,v-l),0x8000000000000)),e;case "AD_PLACEMENT_KIND_MILLISECONDS":h=P.adTimeOffset;h.offsetStartMilliseconds||Iq("AD_PLACEMENT_KIND_MILLISECONDS missing start milliseconds."); h.offsetEndMilliseconds||Iq("AD_PLACEMENT_KIND_MILLISECONDS missing end milliseconds.");P=Number(h.offsetStartMilliseconds);h=Number(h.offsetEndMilliseconds);h===-1&&(h=v);if(Number.isNaN(P)||Number.isNaN(h)||P>h)return new V("AD_PLACEMENT_KIND_MILLISECONDS endMs needs to be >= startMs.",{offsetStartMs:P,offsetEndMs:h},"ADS_CLIENT_ERROR_MESSAGE_AD_PLACEMENT_END_SHOULD_GREATER_THAN_START",h===v&&P-500<=h);e={b3:new pz(P,h),iJ:e};if(l!=null){P=Math.max(0,P-l);if(P===h)return e;e.xB=new pz(P,h)}return e; default:return new V("AdPlacementKind not supported in convertToRange.",{kind:h,adPlacementConfig:P})}}; JuD=function(P){var v=P.startSecs*1E3;return new pz(v,v+P.Er*1E3)}; HYD=function(P){if(!P||!P.adPlacements&&!P.adSlots)return!1;for(var v=g.N(P.adPlacements||[]),l=v.next();!l.done;l=v.next())if(l=l.value)if(l=l.adPlacementRenderer,l!=null&&(l.config&&l.config.adPlacementConfig&&l.config.adPlacementConfig.kind)==="AD_PLACEMENT_KIND_START")return!0;P=g.N(P.adSlots||[]);for(v=P.next();!v.done;v=P.next()){var e=l=void 0;if(((l=g.a(v.value,aL))==null?void 0:(e=l.adSlotMetadata)==null?void 0:e.triggerEvent)==="SLOT_TRIGGER_EVENT_BEFORE_CONTENT")return!0}return!1}; da=function(P){this.L0=P;this.K=new Map;this.W=new Map;this.G=new Map}; Jn=function(P,v){if(P1(P.L0.get())){var l=P.K.get(v)||0;l++;P.K.set(v,l);return v+"_"+l}return g.YR(16)}; vb=function(P,v,l){if(P1(P.L0.get())){var e=P.W.get(v)||0;e++;P.W.set(v,e);return l+"_"+v+"_"+e}return g.YR(16)}; tF=function(P,v){if(P1(P.L0.get())){var l=P.G.get(v)||0;l++;P.G.set(v,l);return v+"_"+l}return g.YR(16)}; Eya=function(P){var v=[new nY(P.h8),new KY(P.z4),new vJ(P.adPlacementConfig),new Yy(P.videoLengthSeconds),new WJ(P.m3)];P.instreamAdPlayerOverlayRenderer&&v.push(new Qm(P.instreamAdPlayerOverlayRenderer));P.playerOverlayLayoutRenderer&&v.push(new tu(P.playerOverlayLayoutRenderer));P.Gp&&v.push(new zH(P.Gp));return v}; W1q=function(P,v,l,e,h,z){P=l.inPlayerLayoutId?l.inPlayerLayoutId:vb(z,"LAYOUT_TYPE_MEDIA_LAYOUT_PLAYER_OVERLAY",P);var m,Q,t=l.instreamAdPlayerOverlayRenderer?(m=l.instreamAdPlayerOverlayRenderer)==null?void 0:m.adLayoutLoggingData:(Q=l.playerOverlayLayoutRenderer)==null?void 0:Q.adLayoutLoggingData;m={layoutId:P,layoutType:"LAYOUT_TYPE_MEDIA_LAYOUT_PLAYER_OVERLAY",i$:v};return{layoutId:P,layoutType:"LAYOUT_TYPE_MEDIA_LAYOUT_PLAYER_OVERLAY",XJ:new Map,layoutExitNormalTriggers:[new Xg(function(y){return tF(z, y)},l.h8)], layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:v,clientMetadata:e,ra:h(m),adLayoutLoggingData:t}}; v1=function(P,v){var l=this;this.K=P;this.L0=v;this.W=function(e){return tF(l.K.get(),e)}}; IiW=function(P,v,l,e,h,z){l=new tT([new ym(l),new vJ(e)]);v=vb(P.K.get(),"LAYOUT_TYPE_UNDERLAY_TEXT_ICON_BUTTON",v);e={layoutId:v,layoutType:"LAYOUT_TYPE_UNDERLAY_TEXT_ICON_BUTTON",i$:"core"};return{layoutId:v,layoutType:"LAYOUT_TYPE_UNDERLAY_TEXT_ICON_BUTTON",XJ:new Map,layoutExitNormalTriggers:[new Xg(function(m){return tF(P.K.get(),m)},h)], layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:l,ra:z(e),adLayoutLoggingData:void 0}}; vX=function(P,v,l,e,h){var z=Eya(e);return W1q(v,l,e,new tT(z),h,P.K.get())}; OYw=function(P,v,l,e,h){var z=Eya(e);z.push(new de(e.g3));z.push(new PJ(e.Os));return W1q(v,l,e,new tT(z),h,P.K.get())}; JF=function(P,v,l,e,h,z,m,Q,t,y){v=vb(P.K.get(),l,v);var C={layoutId:v,layoutType:l,i$:"core"},f=new Map;m&&f.set("impression",m);m=[new HE(P.W,h,"SLOT_TYPE_PLAYER_BYTES","LAYOUT_TYPE_MEDIA")];y&&m.push(new G$(P.W,y,["normal"]));return{layoutId:v,layoutType:l,XJ:f,layoutExitNormalTriggers:m,layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:new tT([e,new vJ(z),new nY(h)]),ra:Q(C),adLayoutLoggingData:t}}; uF=function(P,v,l,e,h,z,m,Q,t){v=vb(P.K.get(),l,v);var y={layoutId:v,layoutType:l,i$:"core"},C=[new HE(P.W,h,"SLOT_TYPE_PLAYER_BYTES","LAYOUT_TYPE_MEDIA")];t&&C.push(new G$(P.W,t,["normal"]));return{layoutId:v,layoutType:l,XJ:new Map,layoutExitNormalTriggers:C,layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:new tT([e,new vJ(z),new nY(h)]),ra:m(y),adLayoutLoggingData:Q}}; Cd=function(P,v,l){var e=[];e.push(new Ew(P.W,l));v&&e.push(v);return e}; yH=function(P,v,l,e,h,z,m){var Q={layoutId:v,layoutType:l,i$:"core"};return{layoutId:v,layoutType:l,XJ:new Map,layoutExitNormalTriggers:m,layoutExitSkipTriggers:[new xW(P.W,v)],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:new tT([new re(e),new vJ(h)]),ra:z(Q),adLayoutLoggingData:e.adLayoutLoggingData}}; TO=function(P,v,l,e,h,z,m,Q){var t={layoutId:v,layoutType:z,i$:"core"};return{layoutId:v,layoutType:z,XJ:new Map,layoutExitNormalTriggers:[new Xg(P.W,l)],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:new tT([new vJ(e)].concat(g.u(m))),ra:h(t),adLayoutLoggingData:Q}}; kC=function(P,v,l,e){if(P.L0.get().QI(v.kind==="AD_PLACEMENT_KIND_START"))if(l===void 0)Iq("Expected SSAP layout ID in renderer",void 0,void 0,{caller:e});else return l}; M2D=function(P,v,l,e,h,z,m,Q,t,y,C,f,k){P=fd(P,v,l,h,z,m,Q,t,f,kC(P,l,e.layoutId,"createSubLayoutVodSkippableMediaBreakLayoutForEndcap"),k);v=P.jf;l=new NS(P.wF);e=P.layoutExitSkipTriggers;y>0&&(v.push(l),v.push(new hu(y)),e=[]);v.push(new e$(C));return{pX:{layoutId:P.layoutId,layoutType:P.layoutType,XJ:P.XJ,layoutExitNormalTriggers:[],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:P.i$,clientMetadata:new tT(v),ra:P.ra,adLayoutLoggingData:P.adLayoutLoggingData}, Fj:e,Bf:P.layoutExitMuteTriggers,qz:P.layoutExitUserInputSubmittedTriggers,oJ:P.VD,m_:P.m_}}; P1D=function(P,v,l,e,h,z,m,Q,t,y){v=fd(P,v,l,e,z,new Map,m,function(C){return Q(C,t)},void 0,kC(P,l,h.layoutId,"createSubLayoutVodSkippableMediaBreakLayoutForVodSurvey")); P=new lJ(P.W,v.wF);l=new NS(v.wF);y=new e$(y);return{pX:{layoutId:v.layoutId,layoutType:v.layoutType,XJ:v.XJ,layoutExitNormalTriggers:[],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:v.i$,clientMetadata:new tT([].concat(g.u(v.jf),[l,y])),ra:v.ra,adLayoutLoggingData:v.adLayoutLoggingData},Fj:v.layoutExitSkipTriggers,Bf:v.layoutExitMuteTriggers,qz:[].concat(g.u(v.layoutExitUserInputSubmittedTriggers),[P]),oJ:v.VD,m_:v.m_}}; fd=function(P,v,l,e,h,z,m,Q,t,y,C){v=y!=null?y:vb(P.K.get(),"LAYOUT_TYPE_MEDIA_BREAK",v);y={layoutId:v,layoutType:"LAYOUT_TYPE_MEDIA_BREAK",i$:"adapter"};Q=Q(v);var f=yf(Q.clientMetadata,"metadata_type_fulfilled_layout");f||Iq("Could not retrieve overlay layout ID during VodSkippableMediaBreakLayout creation. This should never happen.");var k=f?f.layoutId:"";l=[new vJ(l),new OK(e),new rH(h)];f&&l.push(new Ju(f.layoutType));C&&l.push(new Xw(C));return{layoutId:v,layoutType:"LAYOUT_TYPE_MEDIA_BREAK", XJ:z,layoutExitNormalTriggers:[],layoutExitSkipTriggers:[new rU(P.W,k)],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"adapter",jf:l,ra:m(y),adLayoutLoggingData:t,m_:Q,wF:k}}; kIx=function(P,v,l,e,h,z,m,Q,t,y,C){P=oy2(P,v,"core",l,e,h,z,m,Q,t,y,void 0,C);return{layoutId:P.layoutId,layoutType:P.layoutType,XJ:P.XJ,layoutExitNormalTriggers:P.layoutExitNormalTriggers,layoutExitSkipTriggers:P.layoutExitSkipTriggers,layoutExitMuteTriggers:P.layoutExitMuteTriggers,layoutExitUserInputSubmittedTriggers:P.layoutExitUserInputSubmittedTriggers,VD:P.VD,i$:P.i$,clientMetadata:new tT(P.n_),ra:P.ra,adLayoutLoggingData:P.adLayoutLoggingData}}; C1w=function(P,v,l,e,h,z,m,Q,t,y,C,f,k){v=oy2(P,v,"adapter",l,e,h,z,m,Q,t,C,f,k);e=v.layoutExitSkipTriggers;h=v.n_;l.adPodSkipTarget&&l.adPodSkipTarget>0&&(h.push(y),h.push(new hu(l.adPodSkipTarget)),e=[]);h.push(new e$(Q.adPodIndex));l.isCritical&&(e=[new G$(P.W,v.layoutId,["error"])].concat(g.u(e)));return{pX:{layoutId:v.layoutId,layoutType:v.layoutType,XJ:v.XJ,layoutExitNormalTriggers:[],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:v.i$,clientMetadata:new tT(h), ra:v.ra,adLayoutLoggingData:v.adLayoutLoggingData},Fj:e,Bf:v.layoutExitMuteTriggers,qz:v.layoutExitUserInputSubmittedTriggers,oJ:v.VD}}; oy2=function(P,v,l,e,h,z,m,Q,t,y,C,f,k){var w={layoutId:v,layoutType:"LAYOUT_TYPE_MEDIA",i$:l};h=[new vJ(h),new l1(t),new m1(e.externalVideoId),new RR(Q),new rH({impressionCommands:e.impressionCommands,abandonCommands:e.onAbandonCommands,completeCommands:e.completeCommands,progressCommands:e.adVideoProgressCommands}),new b1(z),new cJ({current:null}),new Yy(m)];(z=e.playerOverlay.instreamAdPlayerOverlayRenderer)&&h.push(new Qm(z));(m=e.playerOverlay.playerOverlayLayoutRenderer)&&h.push(new tu(m)); f&&h.push(new pY(f));(f=e.playerUnderlay)&&h.push(new ym(f));Q=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER");f=(f=z?z.elementId:m==null?void 0:m.layoutId)?f:vb(P.K.get(),"LAYOUT_TYPE_MEDIA_LAYOUT_PLAYER_OVERLAY",Q);h.push(new NS(f));h.push(new u1(Q));h.push(new Xw(t.adPodIndex));e.adNextParams&&h.push(new od(e.adNextParams));e.shrunkenPlayerBytesConfig&&h.push(new gH(e.shrunkenPlayerBytesConfig));e.clickthroughEndpoint&&h.push(new s2(e.clickthroughEndpoint));e.legacyInfoCardVastExtension&&h.push(new oR(e.legacyInfoCardVastExtension)); e.sodarExtensionData&&h.push(new LY(e.sodarExtensionData));C&&h.push(new EK(C));h.push(new Vm(x4(e.pings)));t=pe(e.pings);if(k){a:{k=g.N(k);for(C=k.next();!C.done;C=k.next())if(C=C.value,C.adSlotMetadata.slotType==="SLOT_TYPE_PLAYER_UNDERLAY"&&(z=g.a(C.fulfillmentContent.fulfilledLayout,LO))&&(z=g.a(z.renderingContent,xj))&&z.associatedPlayerBytesLayoutId===v){k=C;break a}k=void 0}k&&h.push(new CY(k))}return{layoutId:v,layoutType:"LAYOUT_TYPE_MEDIA",XJ:t,layoutExitNormalTriggers:[new WE(P.W,v)],layoutExitSkipTriggers:e.skipOffsetMilliseconds? [new rU(P.W,f)]:[],layoutExitMuteTriggers:[new rU(P.W,f)],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:l,n_:h,ra:y(w),adLayoutLoggingData:e.adLayoutLoggingData}}; hMP=function(P,v,l,e,h,z,m,Q,t){e.every(function(C){return ms(C,[],["LAYOUT_TYPE_MEDIA"])})||Iq("Unexpect subLayout type for DAI composite layout"); v=vb(P.K.get(),"LAYOUT_TYPE_COMPOSITE_PLAYER_BYTES",v);var y={layoutId:v,layoutType:"LAYOUT_TYPE_COMPOSITE_PLAYER_BYTES",i$:"core"};return{layoutId:v,layoutType:"LAYOUT_TYPE_COMPOSITE_PLAYER_BYTES",XJ:new Map,layoutExitNormalTriggers:[new BE(P.W)],layoutExitSkipTriggers:[],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],VD:[],i$:"core",clientMetadata:new tT([new S$(l),new GH(Q),new Fw(e),new vJ(h),new Zj(z),new BJ({}),new P2(t)]),ra:m(y)}}; dbD=function(P){return P!=null}; ls=function(P,v,l){var e=this;this.K=P;this.G=v;this.L0=l;this.W=function(h){return tF(e.K.get(),h)}}; NH7=function(P,v,l,e,h,z,m){if(!l.prefetchModeConfig)return new V("AdPlacementConfig for Live Prefetch is missing prefetch_config");l=l.prefetchModeConfig;e*=1E3;var Q=[];if(!l.breakLengthMs)return new V("AdPlacementConfig for Live Prefetch is missing break_length_ms");for(var t=g.N(l.breakLengthMs),y=t.next();!y.done;y=t.next())if(y=y.value,Number(y)>0){var C=e+Number(l.startTimeOffsetMs),f=C+Number(l.cacheFetchSmearingDurationMs);y={b3:new pz(f,f+Number(y)),iJ:!1,xB:new pz(Math.floor(C+Math.random()* Number(l.cacheFetchSmearingDurationMs)),f),cueProcessedMs:e?e:C};C=[];C.push(new hT({}));f=[];f.push(new o2(P.W));f.push(new Osq(P.W));m&&C.push(new BJ({}));Q.push(H4(P,v,h,y,z,C,f))}return Q}; H4=function(P,v,l,e,h,z,m){z=z===void 0?[]:z;m=m===void 0?[]:m;var Q=Jn(P.K.get(),"SLOT_TYPE_AD_BREAK_REQUEST"),t=[];m=g.N(m);for(var y=m.next();!y.done;y=m.next())t.push(y.value);e.xB&&e.xB.start!==e.b3.start&&t.push(new j5(P.W,l,new pz(e.xB.start,e.b3.start),!1));t.push(new j5(P.W,l,new pz(e.b3.start,e.b3.end),e.iJ));e={getAdBreakUrl:v.getAdBreakUrl,Ga:e.b3.start,KR:e.b3.end,cueProcessedMs:e.cueProcessedMs};v=new dU(P.W,Q);z=[new aR(e)].concat(g.u(z));return{slotId:Q,slotType:"SLOT_TYPE_AD_BREAK_REQUEST", slotPhysicalPosition:1,slotEntryTrigger:v,slotFulfillmentTriggers:t,slotExpirationTriggers:[new Ow(P.W,l),new T$(P.W,Q),new Vt(P.W,Q)],i$:"core",clientMetadata:new tT(z),adSlotLoggingData:h}}; ruP=function(P,v,l){var e=[];l=g.N(l);for(var h=l.next();!h.done;h=l.next())e.push(sR9(P,v,h.value));return e}; sR9=function(P,v,l){return l.triggeringSlotId!=null&&l.triggeringSlotId===P?l.clone(v):l}; aX7=function(P,v,l,e,h){return M$w(P,v,l,e,h)}; TeW=function(P,v,l,e){var h=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER");return M$w(P,h,v,l,e)}; M$w=function(P,v,l,e,h){var z=new S5(P.W,l),m=[new Mi(P.W,v)];P=[new T$(P.W,v),new Ow(P.W,e)];return{slotId:v,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(h({slotId:v,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:P},l))]),adSlotLoggingData:void 0}}; fj2=function(P,v,l,e,h,z){var m=Jn(P.K.get(),"SLOT_TYPE_PLAYER_BYTES"),Q=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER"),t=vb(P.K.get(),"LAYOUT_TYPE_SURVEY",Q);e=en(P,v,l,e);var y=[new Mi(P.W,m)];l=[new T$(P.W,m),new Ow(P.W,l),new xW(P.W,t)];if(e instanceof V)return e;Q=z({slotId:m,slotType:"SLOT_TYPE_PLAYER_BYTES",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:e,slotFulfillmentTriggers:y,slotExpirationTriggers:l},{slotId:Q,layoutId:t});z=Q.ZIg;Q=Q.z6$;return[{slotId:m,slotType:"SLOT_TYPE_PLAYER_BYTES",slotPhysicalPosition:1, slotEntryTrigger:$C(P,v,m,e),slotFulfillmentTriggers:I8(P,v,m,y),slotExpirationTriggers:l,i$:"core",clientMetadata:new tT([new j$(z),new v2(Do(v)),new ey({NR:P.NR(v)})]),adSlotLoggingData:h},Q]}; Do=function(P){return P.kind==="AD_PLACEMENT_KIND_START"}; wTD=function(P,v,l,e,h){h=h?h:Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER");l=new S5(P.W,l);var z=[new Mi(P.W,h)];P=[new Ow(P.W,v),new T$(P.W,h)];return{slotId:h,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,slotEntryTrigger:l,slotFulfillmentTriggers:z,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(e({slotId:h,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:l,slotFulfillmentTriggers:z,slotExpirationTriggers:P}))])}}; $jw=function(P,v,l,e){var h=Jn(P.K.get(),"SLOT_TYPE_PLAYER_UNDERLAY");l=new S5(P.W,l);var z=[new Mi(P.W,h)];P=[new Ow(P.W,v),new T$(P.W,h)];return{slotId:h,slotType:"SLOT_TYPE_PLAYER_UNDERLAY",slotPhysicalPosition:1,slotEntryTrigger:l,slotFulfillmentTriggers:z,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(e({slotId:h,slotType:"SLOT_TYPE_PLAYER_UNDERLAY",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:l,slotFulfillmentTriggers:z,slotExpirationTriggers:P}))])}}; RMW=function(P,v,l,e,h,z,m){var Q=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER"),t=vb(P.K.get(),"LAYOUT_TYPE_TEXT_BANNER_OVERLAY",Q);e=THB(P,e,z,m,t);if(e instanceof V)return e;m=[new Mi(P.W,Q)];h=[new Ow(P.W,z),new Mi(P.W,h),new v4(P.W,h)];l=$O(l,{slotId:Q,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:e,slotFulfillmentTriggers:m,slotExpirationTriggers:h});P=P.G.get();z={layoutId:t,layoutType:"LAYOUT_TYPE_TEXT_BANNER_OVERLAY",i$:"core"};v={layoutId:t,layoutType:"LAYOUT_TYPE_TEXT_BANNER_OVERLAY", XJ:new Map,layoutExitNormalTriggers:[new Phw(P.W,t,v.durationMs)],layoutExitSkipTriggers:[new lXu(P.W,t,v.durationMs)],VD:[new veP(P.W,t)],layoutExitMuteTriggers:[],layoutExitUserInputSubmittedTriggers:[],i$:"core",clientMetadata:new tT([new sK(v)]),ra:l(z)};return{slotId:Q,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:e,slotFulfillmentTriggers:m,slotExpirationTriggers:h,clientMetadata:new tT([new j$(v)])}}; sdq=function(P,v,l,e,h,z){v=en(P,v,l,e);if(v instanceof V)return v;var m=v instanceof j5?new T9y(P.W,l,v.W):null;e=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER");var Q=[new Mi(P.W,e)];P=[new Ow(P.W,l),new T$(P.W,e)];z=z({slotId:e,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:v,slotFulfillmentTriggers:Q,slotExpirationTriggers:P},m);return z instanceof Qf?new V(z):{slotId:e,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,slotEntryTrigger:v,slotFulfillmentTriggers:Q,slotExpirationTriggers:P, i$:"core",clientMetadata:new tT([new j$(z)]),adSlotLoggingData:h}}; OtP=function(P,v,l,e){var h=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER"),z=new bz(P.W,v),m=[new P4(P.W,h)];P=[new Ow(P.W,v),new T$(P.W,h)];return{slotId:h,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(e({slotId:h,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:P}))]),adSlotLoggingData:l}}; sH2=function(P,v,l,e){var h=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER");l=new S5(P.W,l);var z=[new Mi(P.W,h)],m=[new T$(P.W,h),new Ow(P.W,v)];z={slotId:h,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:l,slotFulfillmentTriggers:z,slotExpirationTriggers:m};return{slotId:h,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,slotEntryTrigger:l,slotFulfillmentTriggers:[new Mi(P.W,h)],slotExpirationTriggers:[new Ow(P.W,v),new T$(P.W,h)],i$:"core",clientMetadata:new tT([new j$(e(z))])}}; Wny=function(P,v,l,e,h){var z=Jn(P.K.get(),"SLOT_TYPE_IN_PLAYER");l=new Ll(P.W,e,l);e=[new Mi(P.W,z)];P=[new Ow(P.W,v)];return{slotId:z,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,slotEntryTrigger:l,slotFulfillmentTriggers:e,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(h({slotId:z,slotType:"SLOT_TYPE_IN_PLAYER",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:l,slotFulfillmentTriggers:e,slotExpirationTriggers:P}))])}}; UbD=function(P,v,l,e,h,z){var m=Jn(P.K.get(),v);return zP(P,m,v,new S5(P.W,e),[new Ow(P.W,l),new T$(P.W,m),new G$(P.W,e,["error"])],h,z)}; iau=function(P,v,l,e,h,z,m){var Q=Jn(P.K.get(),v);return zP(P,Q,v,new G$(P.W,h,["normal"]),[new Ow(P.W,l),new T$(P.W,Q),new G$(P.W,e,["error"])],z,m)}; Si2=function(P,v,l,e,h){var z=Jn(P.K.get(),v);return zP(P,z,v,new bz(P.W,l),[new Ow(P.W,l),new T$(P.W,z)],e,h)}; ai6=function(P,v,l,e,h){l=l?"SLOT_TYPE_PLAYER_BYTES_SEQUENCE_ITEM":"SLOT_TYPE_PLAYBACK_TRACKING";var z=Jn(P.K.get(),l);v=new bz(P.W,v);var m=[new Mi(P.W,z)];P=[new T$(P.W,z)];return{slotId:z,slotType:l,slotPhysicalPosition:1,slotEntryTrigger:v,slotFulfillmentTriggers:m,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(h({slotId:z,slotType:l,slotPhysicalPosition:1,i$:"core",slotEntryTrigger:v,slotFulfillmentTriggers:m,slotExpirationTriggers:P}))]),adSlotLoggingData:e}}; Pb9=function(P,v,l,e){var h=Jn(P.K.get(),"SLOT_TYPE_PLAYER_BYTES"),z=new Zt(P.W),m=[new P4(P.W,h)];P=[new Ow(P.W,v)];return{slotId:h,slotType:"SLOT_TYPE_PLAYER_BYTES",slotPhysicalPosition:1,slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(e({slotId:h,slotType:"SLOT_TYPE_PLAYER_BYTES",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:z,slotFulfillmentTriggers:m,slotExpirationTriggers:P})),new BJ({})]),adSlotLoggingData:l}}; Rxw=function(P,v){return DSP(P.L0.get())?new G$(P.W,v,["normal","error","skipped"]):new G$(P.W,v,["normal"])}; Cbx=function(P,v,l,e,h){v=Rxw(P,v);P=wa(P,v,l);h=h({slotId:P.slotId,slotType:P.slotType,slotPhysicalPosition:P.slotPhysicalPosition,slotEntryTrigger:P.slotEntryTrigger,slotFulfillmentTriggers:P.slotFulfillmentTriggers,slotExpirationTriggers:P.slotExpirationTriggers,i$:P.i$});return h instanceof V?h:{Mx:Object.assign({},P,{clientMetadata:new tT([new j$(h.layout)]),adSlotLoggingData:e}),J3:h.J3}}; fiD=function(P,v,l,e,h,z,m){l=QR6(P,v,l,e);if(l instanceof V)return l;m=m({slotId:l.slotId,slotType:l.slotType,slotPhysicalPosition:l.slotPhysicalPosition,slotEntryTrigger:l.slotEntryTrigger,slotFulfillmentTriggers:l.slotFulfillmentTriggers,slotExpirationTriggers:l.slotExpirationTriggers,i$:l.i$});if(m instanceof V)return m;e=[new v2(Do(v)),new j$(m.layout),new ey({NR:P.NR(v)})];z&&e.push(new MS({}));return{Mx:{slotId:l.slotId,slotType:l.slotType,slotPhysicalPosition:l.slotPhysicalPosition,slotEntryTrigger:$C(P, v,l.slotId,l.slotEntryTrigger),slotFulfillmentTriggers:I8(P,v,l.slotId,l.slotFulfillmentTriggers),slotExpirationTriggers:l.slotExpirationTriggers,i$:l.i$,clientMetadata:new tT(e),adSlotLoggingData:h},J3:m.J3}}; $C=function(P,v,l,e){return P.L0.get().QI(Do(v))?new AX(P.W,l):e}; I8=function(P,v,l,e){return P.L0.get().QI(Do(v))?[new P4(P.W,l)]:e}; wa=function(P,v,l){var e=Jn(P.K.get(),"SLOT_TYPE_PLAYER_BYTES"),h=[new Mi(P.W,e)];P=[new T$(P.W,e),new Ow(P.W,l)];return{slotId:e,slotType:"SLOT_TYPE_PLAYER_BYTES",slotPhysicalPosition:1,slotEntryTrigger:v,slotFulfillmentTriggers:h,slotExpirationTriggers:P,i$:"core"}}; QR6=function(P,v,l,e){v=en(P,v,l,e);return v instanceof V?v:wa(P,v,l)}; Elq=function(P,v,l,e,h,z){var m=Jn(P.K.get(),"SLOT_TYPE_FORECASTING");v=en(P,v,l,e);if(v instanceof V)return v;e=[new Mi(P.W,m)];P=[new T$(P.W,m),new Ow(P.W,l)];return{slotId:m,slotType:"SLOT_TYPE_FORECASTING",slotPhysicalPosition:1,slotEntryTrigger:v,slotFulfillmentTriggers:e,slotExpirationTriggers:P,i$:"core",clientMetadata:new tT([new j$(z({slotId:m,slotType:"SLOT_TYPE_FORECASTING",slotPhysicalPosition:1,i$:"core",slotEntryTrigger:v,slotFulfillmentTriggers:e,slotExpirationTriggers:P}))]),adSlotLoggingData:h}}; V$w=function(P,v,l,e,h){var z=!v.hideCueRangeMarker;switch(v.kind){case "AD_PLACEMENT_KIND_START":return new bz(P.W,l);case "AD_PLACEMENT_KIND_MILLISECONDS":return P=baD(v,e),P instanceof V?P:h(P.b3,z);case "AD_PLACEMENT_KIND_END":return new pl(P.W,l,z);default:return new V("Cannot construct entry trigger",{kind:v.kind})}}; THB=function(P,v,l,e,h){return V$w(P,v,l,e,function(z,m){return new Me9(P.W,l,z,m,h)})}; en=function(P,v,l,e){return V$w(P,v,l,e,function(h,z){return new j5(P.W,l,h,z)})}; zP=function(P,v,l,e,h,z,m){P=[new P4(P.W,v)];return{slotId:v,slotType:l,slotPhysicalPosition:1,slotEntryTrigger:e,slotFulfillmentTriggers:P,slotExpirationTriggers:h,i$:"core",clientMetadata:new tT([new j$(m({slotId:v,slotType:l,slotPhysicalPosition:1,i$:"core",slotEntryTrigger:e,slotFulfillmentTriggers:P,slotExpirationTriggers:h}))]),adSlotLoggingData:z}}; mk=function(P,v){g.U.call(this);this.L0=P;this.W=v;this.eventCount=0}; RJ=function(P,v,l,e){mk.call(this,P,v);this.L0=P;this.vg=l;this.context=e}; Qz=function(){this.W=new Map}; C6=function(P,v){var l=this;this.currentState="wait";this.onSuccess=[];this.onFailure=[];this.currentState=P;this.result=v.result;this.error=v.error;v.promise&&v.promise.then(function(e){tb(l,e)},function(e){yz(l,e)})}; kf=function(P){if(f6(P)){if(P instanceof C6)return P;if(gI(P))return new C6("wait",{promise:P})}return new C6("done",{result:P})}; wI=function(P){return new C6("fail",{error:P})}; $f=function(P){try{return kf(P())}catch(v){return wI(v)}}; D9=function(P,v){var l=new C6("wait",{});P.onSuccess.push(function(e){try{var h=v(e);tb(l,h)}catch(z){yz(l,z)}}); P.onFailure.push(function(e){yz(l,e)}); IJ(P);return l}; n6=function(P,v){var l=new C6("wait",{});P.onSuccess.push(function(e){tb(l,e)}); P.onFailure.push(function(e){try{var h=v(e);tb(l,h)}catch(z){yz(l,z)}}); IJ(P);return l}; tb=function(P,v){if(f6(v)){if(gI(v)){v.then(function(l){tb(P,l)},function(l){yz(P,l)}); return}if(v instanceof C6){D9(v,function(l){tb(P,l)}); n6(v,function(l){yz(P,l)}); return}}P.currentState="done";P.result=v;IJ(P)}; yz=function(P,v){P.currentState="fail";P.error=v;IJ(P)}; IJ=function(P){if(P.currentState==="done"){var v=P.onSuccess;P.onSuccess=[];P.onFailure=[];v=g.N(v);for(var l=v.next();!l.done;l=v.next())l=l.value,l(P.result)}else if(P.currentState==="fail")for(v=P.onFailure,P.onSuccess=[],P.onFailure=[],v=g.N(v),l=v.next();!l.done;l=v.next())l=l.value,l(P.error)}; Pq2=function(P){return function(){return dSx(P.apply(this,g.bD.apply(0,arguments)))}}; dSx=function(P){return $f(function(){return NE(P,P.next())})}; NE=function(P,v){return v.done?kf(v.value):n6(D9(v.value.Uy,function(l){return NE(P,P.next(l))}),function(l){return NE(P,P.throw(l))})}; us=function(P){var v=P.hours||0;var l=P.minutes||0,e=P.seconds||0;v=e+l*60+v*3600+(P.days||0)*86400+(P.weeks||0)*604800+(P.months||0)*2629800+(P.years||0)*31557600;v<=0?v={hours:0,minutes:0,seconds:0}:(P=v,v=Math.floor(P/3600),P%=3600,l=Math.floor(P/60),e=Math.floor(P%60),v={hours:v,minutes:l,seconds:e});var h=v.hours===void 0?0:v.hours;l=v.minutes===void 0?0:v.minutes;P=v.seconds===void 0?0:v.seconds;e=h>0;v=[];if(e){h=(new Intl.NumberFormat("en-u-nu-latn")).format(h);var z=["fr"],m="az bs ca da de el es eu gl hr id is it km lo mk nl pt-BR ro sl sr sr-Latn tr vi".split(" "); h="af be bg cs et fi fr-CA hu hy ka kk ky lt lv no pl pt-PT ru sk sq sv uk uz".split(" ").includes(Jb)?h.replace(",","\u00a0"):z.includes(Jb)?h.replace(",","\u202f"):m.includes(Jb)?h.replace(",","."):h;v.push(h)}e=e===void 0?!1:e;l=(["af","be","lt"].includes(Jb)||e)&&l<10?vOa().format(l):(new Intl.NumberFormat("en-u-nu-latn")).format(l);v.push(l);l=vOa().format(P);v.push(l);l=":";"da fi id si sr sr-Latn".split(" ").includes(Jb)&&(l=".");return v.join(l)}; vOa=function(){return new Intl.NumberFormat("en-u-nu-latn",{minimumIntegerDigits:2})}; lM9=function(P,v){var l,e;P=((l=P.watchEndpointSupportedAuthorizationTokenConfig)==null?void 0:(e=l.videoAuthorizationToken)==null?void 0:e.credentialTransferTokens)||[];for(l=0;l v;P=l}else P=!1;return P}; nO6=function(P){P=P.split("");Ug.YD(P,79);Ug.Kr(P,38);Ug.R9(P,2);Ug.YD(P,74);Ug.R9(P,3);Ug.Kr(P,17);Ug.YD(P,71);return P.join("")}; g.Z9=function(P,v){return P.J5+"timedtext_video?ref=player&v="+v.videoId}; g.N37=function(P){var v=this;this.videoData=P;P={};this.W=(P.c1a=function(){var l=[];if(g.B1.isInitialized()){var e="";v.videoData&&v.videoData.Q8&&(e=v.videoData.Q8+("&r1b="+v.videoData.clientPlaybackNonce));var h={};e=(h.atr_challenge=e,h);Md("bg_v",void 0,"player_att");(e=DxD(e))?(Md("bg_s",void 0,"player_att"),l.push("r1a="+e)):(Md("bg_e",void 0,"player_att"),l.push("r1c=2"))}else Md("bg_e",void 0,"player_att"),window.trayride||window.botguard?l.push("r1c=1"):l.push("r1c=4");l.push("r1d="+g.B1.getState()); return l.join("&")},P.c6a=function(l){return"r6a="+(Number(l.c)^ke())},P.c6b=function(l){return"r6b="+(Number(l.c)^Number(g.la("CATSTAT",0)))},P); this.videoData&&this.videoData.Q8?this.UY=yS(this.videoData.Q8):this.UY={}}; g.JTD=function(P){if(P.videoData&&P.videoData.Q8){for(var v=[P.videoData.Q8],l=g.N(Object.keys(P.W)),e=l.next();!e.done;e=l.next())e=e.value,P.UY[e]&&P.W[e]&&(e=P.W[e](P.UY))&&v.push(e);return v.join("&")}return null}; g.jn=function(P,v){IMa(P,{Nv3:g.ID(v.experiments,"bg_vm_reinit_threshold"),cspNonce:v.cspNonce})}; uh2=function(){var P=XMLHttpRequest.prototype.fetch;return!!P&&P.length===3}; aJ=function(P){P=P===void 0?2592E3:P;if(P>0&&!(d7D()>(0,g.Gz)()-P*1E3))return 0;P=g.au("yt-player-quality");if(typeof P==="string"){if(P=g.Hz[P],P>0)return P}else if(P instanceof Object)return P.quality;return 0}; H1=function(){var P=g.au("yt-player-proxima-pref");return P==null?null:P}; KsW=function(){var P=g.au("yt-player-quality");if(P instanceof Object&&P.quality&&P.previousQuality){if(P.quality>P.previousQuality)return 1;if(P.quality 0&&v[0]?P.getAutoplayPolicy(v[0]):P.getAutoplayPolicy("mediaelement");if(bFw[l])return bFw[l]}}catch(e){}return"AUTOPLAY_BROWSER_POLICY_UNSPECIFIED"}; ME=function(P){return P.XE||P.tq||P.mutedAutoplay}; xxw=function(P,v){return ME(P)?v!==1&&v!==2&&v!==0?"AUTOPLAY_STATUS_UNAVAILABLE":P.lB?"AUTOPLAY_STATUS_BLOCKED":"AUTOPLAY_STATUS_OCCURRED":"AUTOPLAY_STATUS_NOT_ATTEMPTED"}; p2w=function(P,v,l){var e=v.N();P.thirdParty||(P.thirdParty={});e.ancestorOrigins&&(P.thirdParty.embeddedPlayerContext=Object.assign({},P.thirdParty.embeddedPlayerContext,{ancestorOrigins:e.ancestorOrigins}));e.V("embeds_enable_autoplay_and_visibility_signals")&&(e.yY!=null&&(P.thirdParty.embeddedPlayerContext=Object.assign({},P.thirdParty.embeddedPlayerContext,{visibilityFraction:Number(e.yY)})),e.h1&&(P.thirdParty.embeddedPlayerContext=Object.assign({},P.thirdParty.embeddedPlayerContext,{visibilityFractionSource:e.h1})), P.thirdParty.embeddedPlayerContext=Object.assign({},P.thirdParty.embeddedPlayerContext,{autoplayBrowserPolicy:rI(),autoplayIntended:ME(v),autoplayStatus:xxw(v,l)}))}; Gf9=function(P,v){tS(P,2,v.YL,TP,3);tS(P,3,v.W2,Ls2,3);Rd(P,4,v.onesieUstreamerConfig);Rd(P,9,v.YB);tS(P,10,v.kP,Vz,3);tS(P,15,v.reloadPlaybackParams,SuD,3)}; B3D=function(P,v){tS(P,1,v.formatId,dI,3);zI(P,2,v.startTimeMs);zI(P,3,v.durationMs);zI(P,4,v.vV);zI(P,5,v.IY);tS(P,9,v.fwW,X2u,3);tS(P,11,v.IZ1,Pn,1);tS(P,12,v.ZN,Pn,1)}; iF9=function(P,v){Qg(P,1,v.videoId);zI(P,2,v.lmt)}; X2u=function(P,v){if(v.AM)for(var l=0;l >31));zI(P,16,v.R6$);zI(P,17,v.detailedNetworkType);zI(P,18,v.ju);zI(P,19,v.rg);zI(P,21,v.OJf);zI(P,23,v.cS);zI(P,28,v.n8);zI(P,29,v.EM6);zI(P,34,v.visibility);l=v.playbackRate;if(l!==void 0){var e=new ArrayBuffer(4);(new Float32Array(e))[0]=l;l=(new Uint32Array(e))[0];if(l!==void 0)for(hS(P,285),oH(P,4),e=0;e<4;)P.view.setUint8(P.pos,l&255),l>>=8,P.pos+=1,e+=1}zI(P,36,v.Z6); tS(P,38,v.mediaCapabilities,jDa,3);zI(P,39,v.kAM);zI(P,40,v.iF);zI(P,44,v.playerState);mq(P,46,v.YQ);zI(P,48,v.Vs);zI(P,50,v.W5);zI(P,51,v.ys);zI(P,54,v.r0);mq(P,56,v.EY3);zI(P,57,v.qB);mq(P,58,v.ek);zI(P,59,v.gH);zI(P,60,v.Rj);mq(P,61,v.isPrefetch);zI(P,62,v.CT);Rd(P,63,v.sabrLicenseConstraint);zI(P,64,v.e65);zI(P,66,v.i01);zI(P,67,v.HRM);zI(P,68,v.WZ6);Qg(P,69,v.audioTrackId);mq(P,71,v.KW);tS(P,72,v.e3M,ZFx,1);zI(P,74,v.sx);zI(P,75,v.z3)}; jDa=function(P,v){if(v.videoFormatCapabilities)for(var l=0;l >31));Qg(P,2,v.message)}; MyD=function(P,v){zI(P,1,v.clientState);tS(P,2,v.zlM,sDq,1)}; oOD=function(P,v){Rd(P,1,v.Hbc);tS(P,2,v.tgJ,rTw,3);tS(P,3,v.coldStartInfo,MyD,3)}; OF7=function(P,v){zI(P,1,v.type);Rd(P,2,v.value)}; WsD=function(P,v){Qg(P,1,v.hl);Qg(P,12,v.deviceMake);Qg(P,13,v.deviceModel);zI(P,16,v.clientName);Qg(P,17,v.clientVersion);Qg(P,18,v.osName);Qg(P,19,v.osVersion)}; T32=function(P,v){Qg(P,1,v.name);Qg(P,2,v.value)}; Vy9=function(P,v){Qg(P,1,v.url);if(v.BA)for(var l=0;l 1&&(this.Z=P[1]==="2")}; m4=function(P,v,l,e,h){this.K=P;this.W=v;this.G=l;this.reason=e;this.FJ=h===void 0?0:h}; g.Ra=function(P,v,l,e){return new m4(g.Hz[P]||0,g.Hz[v]||0,l,e)}; tR=function(P){if(Qy&&P.FJ)return!1;var v=g.Hz.auto;return P.K===v&&P.W===v}; Cr=function(P){return yy[P.W||P.K]||"auto"}; B49=function(P,v){v=g.Hz[v];return P.K<=v&&(!P.W||P.W>=v)}; fr=function(P){return"["+P.K+"-"+P.W+", override: "+(P.G+", reason: "+P.reason+"]")}; gG=function(P,v,l){this.videoInfos=P;this.W=v;this.audioTracks=[];if(this.W){P=new Set;l==null||l({ainfolen:this.W.length});v=g.N(this.W);for(var e=v.next();!e.done;e=v.next())if(e=e.value,!e.Rt||P.has(e.Rt.id)){var h=void 0,z=void 0,m=void 0;(m=l)==null||m({atkerr:!!e.Rt,itag:e.itag,xtag:e.W,lang:((h=e.Rt)==null?void 0:h.name)||"",langid:((z=e.Rt)==null?void 0:z.id)||""})}else h=new g.zc(e.id,e.Rt),P.add(e.Rt.id),this.audioTracks.push(h);l==null||l({atklen:this.audioTracks.length})}}; k_=function(){g.U.apply(this,arguments);this.W=null}; joq=function(P,v,l,e,h,z,m){if(P.W)return P.W;var Q={},t=new Set,y={};if(wG(e)){for(var C in e.W)e.W.hasOwnProperty(C)&&(P=e.W[C],y[P.info.dM]=[P.info]);return y}C=ieP(v,e,Q);z&&h({aftsrt:$_(C)});for(var f={},k=g.N(Object.keys(C)),w=k.next();!w.done;w=k.next()){w=w.value;for(var I=g.N(C[w]),J=I.next();!J.done;J=I.next()){J=J.value;var K=J.itag,q=void 0,A=w+"_"+(((q=J.video)==null?void 0:q.fps)||0);f.hasOwnProperty(A)?f[A]===!0?y[w].push(J):Q[K]=f[A]:(q=Ia(v,J,l,e.isLive,t),q!==!0?(m.add(w),Q[K]=q, q==="disablevp9hfr"&&(f[A]="disablevp9hfr")):(y[w]=y[w]||[],y[w].push(J),f[A]=!0))}}z&&h({bfflt:$_(y)});for(var x in y)y.hasOwnProperty(x)&&(e=x,y[e]&&y[e][0].zQ()&&(y[e]=y[e],y[e]=UsD(v,y[e],Q),y[e]=Zey(y[e],Q)));z&&Object.keys(Q).length>0&&(v.Nd?h({rjr:bp(Q)}):h(Q));v=g.N(t.values());for(e=v.next();!e.done;e=v.next())(e=l.K.get(e.value))&&--e.Vf;z&&h({aftflt:$_(y)});P.W=g.u6(y,function(S){return!!S.length}); return P.W}; He9=function(P,v,l,e,h,z,m,Q){Q=Q===void 0?!1:Q;if(v.oV&&m&&m.length>1&&!(v.gH>0||v.S)){for(var t=v.K||!!h,y=t&&v.CI?z:void 0,C=ieP(v,e),f=[],k=[],w={},I=0;I 0&&k&&h&&(C=[m,l],K=h.concat(k).filter(function(q){return q})); if(K.length&&!v.ek){N9(K,C);if(t){t=[];v=g.N(K);for(e=v.next();!e.done;e=v.next())t.push(e.value.itag);z({hbdfmt:t.join(".")})}return jN(new gG(K,P,y))}K=VIw(v);K=g.om(K,Q);if(!K){if(f[m])return z=f[m],N9(z),jN(new gG(z,P,y));t&&z({novideo:1});return Zp()}v.MV&&(K==="1"||K==="1h")&&f[l]&&(m=JR(f[K]),C=JR(f[l]),C>m?K=l:C===m&&dsw(f[l])&&(K=l));K==="9"&&f.h&&JR(f.h)>JR(f["9"])&&(K="h");v.TG&&e.isLive&&K==="("&&f.H&&JR(f["("])<1440&&(K="H");t&&z({vfmly:ug(K)});v=f[K];if(!v.length)return t&&z({novfmly:ug(K)}), Zp();N9(v);return jN(new gG(v,P,y))}; W8u=function(P,v){var l=!(!P.m&&!P.M),e=!(!P.mac3&&!P.MAC3),h=!(!P.meac3&&!P.MEAC3);P=!(!P.i&&!P.I);v.SN=P;return l||e||h||P}; dsw=function(P){P=g.N(P);for(var v=P.next();!v.done;v=P.next())if(v=v.value,v.itag&&PpB.has(v.itag))return!0;return!1}; ug=function(P){switch(P){case "*":return"v8e";case "(":return"v9e";case "(h":return"v9he";default:return P}}; $_=function(P){var v=[],l;for(l in P)if(P.hasOwnProperty(l)){var e=l;v.push(ug(e));e=g.N(P[e]);for(var h=e.next();!h.done;h=e.next())v.push(h.value.itag)}return v.join(".")}; E4W=function(P,v,l,e,h,z){var m={},Q={};g.J3(v,function(t,y){t=t.filter(function(C){var f=C.itag;if(!C.EQ)return Q[f]="noenc",!1;if(z.jS&&C.dM==="(h"&&z.WK)return Q[f]="lichdr",!1;if(C.dM==="("||C.dM==="(h"){if(P.Y&&l&&l.flavor==="widevine"){var k=C.mimeType+"; experimental=allowed";(k=!!C.EQ[l.flavor]&&!!l.W[k])||(Q[f]=C.EQ[l.flavor]?"unspt":"noflv");return k}if(!Kr(P,cn.CRYPTOBLOCKFORMAT)&&!P.wM||P.J5)return Q[f]=P.J5?"disvp":"vpsub",!1}return l&&C.EQ[l.flavor]&&l.W[C.mimeType]?!0:(Q[f]=l?C.EQ[l.flavor]? "unspt":"noflv":"nosys",!1)}); t.length&&(m[y]=t)}); e&&Object.entries(Q).length&&(z.Nd?h({rjr:bp(Q)}):h(Q));return m}; Zey=function(P,v){var l=GX(P,function(e,h){return h.video.fps>32?Math.min(e,h.video.width):e},Infinity); l 32||e.video.width P.T)return"max"+P.T;if(P.U$&&v.dM==="h"&&v.video&&v.video.W>1080)return"blkhigh264";if(v.dM==="(h"&&!l.T)return"enchdr";if((e===void 0?0:e)&&dl(v)&&!P.q5)return"blk51live";if((v.dM==="MAC3"||v.dM==="mac3")&&!P.Y)return"blkac3";if((v.dM==="MEAC3"||v.dM==="meac3")&&!P.Z)return"blkeac3";if((v.dM==="M"||v.dM==="m")&&!P.QW)return"blkaac51";if((v.dM=== "so"||v.dM==="sa")&&!P.J5)return"blkamb";if(!P.jS&&v.EQ&&v.EQ.fairplay&&(v.dM==="("||v.dM==="(h"||v.dM==="A"||v.dM==="MEAC3"))return"cbc";if((v.dM==="i"||v.dM==="I")&&!P.It)return"blkiamf";if(v.itag==="774"&&!P.kf)return"blkouh";var z,m;if(P.A5&&(v.dM==="1"||v.dM==="1h")&&((z=v.video)==null?0:z.W)&&((m=v.video)==null?void 0:m.W)>P.A5)return"av1cap";if((e=l.K.get(v.dM))&&e.Vf>0)return h.add(v.dM),"byerr";var Q;if((Q=v.video)==null?0:Q.fps>32){if(!l.kf&&!Kr(l,cn.FRAMERATE))return"capHfr";if(P.D3&&v.video.W>= 4320)return"blk8khfr";if(rl(v)){if(P.GP&&v.EQ&&v.video.W>=1440)return"disablevp9hfr";if(P.XE&&g.Mc("appletv5")&&v.EQ)return"atv5sfr"}}if(P.FJ&&v.FJ>P.FJ)return"ratecap";P=vqx(l,v);return P!==!0?P:!0}; N9=function(P,v){v=v===void 0?[]:v;g.tK(P,function(l,e){var h=e.FJ-l.FJ;if(!l.zQ()||!e.zQ())return h;var z=e.video.height*e.video.width-l.video.height*l.video.width;!z&&v&&v.length>0&&(l=v.indexOf(l.dM)+1,e=v.indexOf(e.dM)+1,z=l===0||e===0?e||-1:l-e);z||(z=h);return z})}; g.q9=function(P,v){this.K=P;this.Y=v===void 0?!1:v;this.G=this.path=this.scheme="";this.W={};this.url=""}; AR=function(P){FZ(P);return P.G}; Y_=function(P){return P.K?P.K.startsWith("local"):P.scheme==="local"}; l1a=function(P){FZ(P);return g.cr(P.W,function(v){return v!==null})}; bg=function(P){FZ(P);var v=decodeURIComponent(P.get("mn")||"").split(",");return P.path==="/videoplayback"&&v.length>1&&!!v[1]}; x_=function(P,v){v=v===void 0?!1:v;FZ(P);if(P.path!=="/videoplayback"){var l=P.clone();l.set("playerfallback","1");return l}var e=P.sQ();l=new g.DA(e);var h=P.get("fvip"),z=decodeURIComponent(P.get("mn")||"").split(",");if(h&&z&&z.length>1&&z[1])return e=l.W,P=e.replace(/^[^.]*/,""),g.N$(l,(e.indexOf("rr")===0?"rr":"r")+h+"---"+z[1]+P),l=new g.q9(l.toString()),l.set("fallback_count","1"),l;if(v)return l=P.clone(),l.set("fallback_count","1"),l;h=l.W.match("\\.a1\\.googlevideo\\.com$");l.W.match("\\.googlevideo\\.com$")? (g.N$(l,"redirector.googlevideo.com"),e=l.toString()):l.W.match("rr?[1-9].*\\.c\\.youtube\\.com$")?(g.N$(l,"www.youtube.com"),e=l.toString()):(l=zaq(e),zw(l)&&(e=l));l=new g.q9(e);l.set("cmo=pf","1");h&&l.set("cmo=td","a1.googlevideo.com");return l}; FZ=function(P){if(P.K){if(!zw(P.K)&&!P.K.startsWith("local"))throw new g.Ph("Untrusted URL",P.K);var v=g.A7(P.K);P.scheme=v.Z;P.G=v.W+(v.G!=null?":"+v.G:"");var l=v.K;if(l.startsWith("/videoplayback"))P.path="/videoplayback",l=l.slice(14);else if(l.startsWith("/initplayback"))P.path="/initplayback",l=l.slice(13);else if(l.startsWith("/api/manifest")){var e=l.indexOf("/",12),h=l.indexOf("/",e+1);e>0&&h>0?(P.path=l.slice(0,h),l=l.slice(h+1)):(P.path=l,l="")}else P.path=l,l="";e=P.W;P.W=ecw(l);Object.assign(P.W, hcW(v.Y.toString()));Object.assign(P.W,e);P.W.file==="index.m3u8"&&(delete P.W.file,P.path+="/file/index.m3u8");P.K="";P.url="";P.Y&&(v=jAD(),FZ(P),l=P.W[v]||null)&&(l=zc6[0](l),P.set(v,l),P.Y||jAD(""))}}; mg2=function(P){FZ(P);var v=P.scheme+(P.scheme?"://":"//")+P.G+P.path;if(l1a(P)){var l=[];g.J3(P.W,function(e,h){e!==null&&l.push(h+"="+e)}); v+="?"+l.join("&")}return v}; ecw=function(P){P=P.split("/");var v=0;P[0]||v++;for(var l={};v 0?Rcq(v,e.slice(0,h),e.slice(h+1)):e&&(v[e]="")}return v}; Rcq=function(P,v,l){if(v==="cmo"){var e;(e=l.indexOf("="))>=0?(v="cmo="+l.slice(0,e),l=l.slice(e+1)):(e=l.indexOf("%3D"))>=0&&(v="cmo="+l.slice(0,e),l=l.slice(e+3))}P[v]=l}; pr=function(P){var v=g.a(P,QSD)||P.signatureCipher;P={Gf:!1,pZ:"",M9:"",s:""};if(!v)return P;v=yS(v);P.Gf=!0;P.pZ=v.url;P.M9=v.sp;P.s=v.s;return P}; Lr=function(P,v,l,e,h,z,m,Q,t,y){this.n0=P;this.startTime=v;this.duration=l;this.ingestionTime=e;this.sourceURL=h;this.Or=t;this.W=y;this.endTime=v+l;this.K=m||0;this.range=z||null;this.pending=Q||!1;this.Or=t||null}; g.SM=function(){this.segments=[];this.W=null;this.K=!0;this.G=""}; tLD=function(P,v){if(v>P.vR())P.segments=[];else{var l=Ob(P.segments,function(e){return e.n0>=v},P); l>0&&P.segments.splice(0,l)}}; Gc=function(P,v,l,e,h){h=h===void 0?!1:h;this.data=P;this.offset=v;this.size=l;this.type=e;this.W=(this.K=h)?0:8;this.dataOffset=this.offset+this.W}; XZ=function(P){var v=P.data.getUint8(P.offset+P.W);P.W+=1;return v}; Bn=function(P){var v=P.data.getUint16(P.offset+P.W);P.W+=2;return v}; ig=function(P){var v=P.data.getInt32(P.offset+P.W);P.W+=4;return v}; U_=function(P){var v=P.data.getUint32(P.offset+P.W);P.W+=4;return v}; Zh=function(P){var v=P.data;var l=P.offset+P.W;v=v.getUint32(l)*4294967296+v.getUint32(l+4);P.W+=8;return v}; jM=function(P,v){v=v===void 0?NaN:v;if(isNaN(v))var l=P.size;else for(l=P.W;l 1?Math.ceil(h*v):Math.floor(h*v))}P.skip(1);l=XZ(P)<<16|Bn(P);if(l&256){e=l&1;h=l&4;var z=l&512,m=l&1024,Q=l&2048;l=U_(P);e&&P.skip(4);h&&P.skip(4);e=(z?4:0)+(m?4:0)+(Q?4:0);for(h=0;h 1?Math.ceil(m*v):Math.floor(m*v)),P.skip(e)}}}; M9=function(P){P=new DataView(P.buffer,P.byteOffset,P.byteLength);return(P=g.s_(P,0,1836476516))?g.rG(P):NaN}; Nl2=function(P){var v=g.s_(P,0,1937011556);if(!v)return null;v=Tc(P,v.dataOffset+8,1635148593)||Tc(P,v.dataOffset+8,1635135537);if(!v)return null;var l=Tc(P,v.dataOffset+78,1936995172),e=Tc(P,v.dataOffset+78,1937126244);if(!e)return null;v=null;if(l)switch(l.skip(4),XZ(l)){default:v=0;break;case 1:v=2;break;case 2:v=1;break;case 3:v=255}var h=l=null,z=null;if(e=Tc(P,e.dataOffset,1886547818)){var m=Tc(P,e.dataOffset,1886546020),Q=Tc(P,e.dataOffset,2037673328);if(!Q&&(Q=Tc(P,e.dataOffset,1836279920), !Q))return null;m&&(m.skip(4),l=ig(m)/65536,z=ig(m)/65536,h=ig(m)/65536);P=yDx(Q);P=new DataView(P.buffer,P.byteOffset+8,P.byteLength-8);return new Dg7(v,l,z,h,P)}return null}; Tc=function(P,v,l){for(;Vy(P,v);){var e=dG(P,v);if(e.type===l)return e;v+=e.size}return null}; g.s_=function(P,v,l){for(;Vy(P,v);){var e=dG(P,v);if(e.type===l)return e;v=PH(e.type)?v+8:v+e.size}return null}; g.vH=function(P){if(P.data.getUint8(P.dataOffset)){var v=P.data;P=P.dataOffset+4;v=v.getUint32(P)*4294967296+v.getUint32(P+4)}else v=P.data.getUint32(P.dataOffset+4);return v}; dG=function(P,v){var l=P.getUint32(v),e=P.getUint32(v+4);return new Gc(P,v,l,e)}; g.rG=function(P){var v=P.data.getUint8(P.dataOffset)?20:12;return P.data.getUint32(P.dataOffset+v)}; JD9=function(P){P=new Gc(P.data,P.offset,P.size,P.type,P.K);var v=XZ(P);P.skip(7);var l=U_(P);if(v===0){v=U_(P);var e=U_(P)}else v=Zh(P),e=Zh(P);P.skip(2);for(var h=Bn(P),z=[],m=[],Q=0;Q 122)return!1}return!0}; PH=function(P){return P===1701082227||P===1836019558||P===1836019574||P===1835297121||P===1835626086||P===1937007212||P===1953653094||P===1953653099||P===1836475768}; usD=function(P){P.skip(4);return{EF1:jM(P,0),value:jM(P,0),b7:U_(P),hl5:U_(P),PR1:U_(P),id:U_(P),IS:jM(P),offset:P.offset}}; g.KLw=function(P){var v=Tc(P,0,1701671783);if(!v)return null;var l=usD(v),e=l.EF1;l=oa(l.IS);if(P=Tc(P,v.offset+v.size,1701671783))if(P=usD(P),P=oa(P.IS),l&&P){v=g.N(Object.keys(P));for(var h=v.next();!h.done;h=v.next())h=h.value,l[h]=P[h]}return l?new Wn(l,e):null}; ld=function(P,v){for(var l=Tc(P,0,v);l;){var e=l;e.type=1936419184;e.data.setUint32(e.offset+4,1936419184);l=Tc(P,l.offset+l.size,v)}}; g.eV=function(P,v){for(var l=0,e=[];Vy(P,l);){var h=dG(P,l);h.type===v&&e.push(h);l=PH(h.type)?l+8:l+h.size}return e}; cDy=function(P,v){var l=g.s_(P,0,1937011556),e=g.s_(P,0,1953654136);if(!l||!e||P.getUint32(l.offset+12)>=2)return null;var h=new DataView(v.buffer,v.byteOffset,v.length),z=g.s_(h,0,1937011556);if(!z)return null;v=h.getUint32(z.dataOffset+8);e=h.getUint32(z.dataOffset+12);if(e!==1701733217&&e!==1701733238)return null;e=new Cp6(P.byteLength+v);aa(e,P,0,l.offset+12);e.data.setInt32(e.offset,2);e.offset+=4;aa(e,P,l.offset+16,l.size-16);aa(e,h,h.byteOffset+z.dataOffset+8,v);aa(e,P,l.offset+l.size,P.byteLength- (l.offset+l.size));l=g.N([1836019574,1953653099,1835297121,1835626086,1937007212,1937011556]);for(h=l.next();!h.done;h=l.next())h=g.s_(P,0,h.value),e.data.setUint32(h.offset,h.size+v);P=g.s_(e.data,0,1953654136);e.data.setUint32(P.offset+16,2);return e.data}; q6D=function(P){var v=g.s_(P,0,1937011556);if(!v)return null;var l=P.getUint32(v.dataOffset+12);if(l!==1701733217&&l!==1701733238)return null;v=Tc(P,v.offset+24+(l===1701733217?28:78),1936289382);if(!v)return null;l=Tc(P,v.offset+8,1935894637);if(!l||P.getUint32(l.offset+12)!==1667392371)return null;v=Tc(P,v.offset+8,1935894633);if(!v)return null;v=Tc(P,v.offset+8,1952804451);if(!v)return null;l=new Uint8Array(16);for(var e=0;e<16;e++)l[e]=P.getInt8(v.offset+16+e);return l}; h_=function(P,v){this.W=P;this.pos=0;this.start=v||0}; z8=function(P){return P.pos>=P.W.byteLength}; ys=function(P,v,l){var e=new h_(l);if(!mK(e,P))return!1;e=R1(e);if(!Qs(e,v))return!1;for(P=0;v;)v>>>=8,P++;v=e.start+e.pos;var h=t_(e,!0);e=P+(e.start+e.pos-v)+h;e=e>9?FL9(e-9,8):FL9(e-2,1);P=v-P;l.setUint8(P++,236);for(v=0;v l;h++)l=l*256+wR(P),e*=128;return v?l-e:l}; fo=function(P){var v=t_(P,!0);P.pos+=v}; bWw=function(P){if(!Qs(P,440786851,!0))return null;var v=P.pos;t_(P,!1);var l=t_(P,!0)+P.pos-v;P.pos=v+l;if(!Qs(P,408125543,!1))return null;t_(P,!0);if(!Qs(P,357149030,!0))return null;var e=P.pos;t_(P,!1);var h=t_(P,!0)+P.pos-e;P.pos=e+h;if(!Qs(P,374648427,!0))return null;var z=P.pos;t_(P,!1);var m=t_(P,!0)+P.pos-z,Q=new Uint8Array(l+12+h+m),t=new DataView(Q.buffer);Q.set(new Uint8Array(P.W.buffer,P.W.byteOffset+v,l));t.setUint32(l,408125543);t.setUint32(l+4,33554431);t.setUint32(l+8,4294967295); Q.set(new Uint8Array(P.W.buffer,P.W.byteOffset+e,h),l+12);Q.set(new Uint8Array(P.W.buffer,P.W.byteOffset+z,m),l+12+h);return Q}; $2=function(P){var v=P.pos;P.pos=0;var l=1E6;mK(P,[408125543,357149030,2807729])&&(l=Co(P));P.pos=v;return l}; xgw=function(P,v){var l=P.pos;P.pos=0;if(P.W.getUint8(P.pos)!==160&&!I1(P)||!Qs(P,160))return P.pos=l,NaN;t_(P,!0);var e=P.pos;if(!Qs(P,161))return P.pos=l,NaN;t_(P,!0);wR(P);var h=wR(P)<<8|wR(P);P.pos=e;if(!Qs(P,155))return P.pos=l,NaN;e=Co(P);P.pos=l;return(h+e)*v/1E9}; I1=function(P){if(!pz2(P)||!Qs(P,524531317))return!1;t_(P,!0);return!0}; pz2=function(P){if(P.rl()){if(!Qs(P,408125543))return!1;t_(P,!0)}return!0}; mK=function(P,v){for(var l=0;l 0){var e=hcW(v.substring(l+1));g.J3(e,function(h,z){this.set(z,h)},P); v=v.substring(0,l)}v=ecw(v);g.J3(v,function(h,z){this.set(z,h)},P)}; S69=function(P){var v=P.P9.sQ(),l=[];g.J3(P.W,function(h,z){l.push(z+"="+h)}); if(!l.length)return v;var e=l.join("&");P=l1a(P.P9)?"&":"?";return v+P+e}; no=function(P,v){var l=new g.q9(v);(v=l.get("req_id"))&&P.set("req_id",v);g.J3(P.W,function(e,h){l.set(h,null)}); return l}; Ga9=function(){this.Y=this.K=this.W=this.timedOut=this.started=this.Z=this.G=0}; NN=function(P){P.Z=(0,g.Gz)();P.started=0;P.timedOut=0;P.W=0}; J_=function(P,v){var l=P.started+P.W*4;v&&(l+=P.K);l=Math.max(0,l-3);return Math.pow(1.6,l)}; ud=function(P,v){P[v]||(P[v]=new Ga9);return P[v]}; Ko=function(P){this.X=this.j=this.Z=this.K=0;this.S=this.T=!1;this.W=P;this.G=P.clone()}; Xz2=function(P,v,l){if(Y_(P.W))return!1;var e=ud(l,AR(P.W));if(e.timedOut<1&&e.W<1)return!1;e=e.timedOut+e.W;P=cH(P,v);l=ud(l,AR(P));return l.timedOut+l.W+0 1?v=v.iY:(l=ud(l,FI(P,P.qZ(v,l),v)),v=Math.max(P.Z,l.timedOut)+v.x0*(P.K-P.Z)+.25*P.j,v=v>3?1E3*Math.pow(1.6,v-3):0);return v===0?!0:P.X+v<(0,g.Gz)()}; BlB=function(P,v,l){P.W.set(v,l);P.G.set(v,l);P.Y&&P.Y.set(v,l)}; iWD=function(P,v,l,e,h){++P.K;v&&++P.Z;AR(l.P9).startsWith("redirector.")&&(P.W=P.G.clone(),delete P.Y,e.mO&&delete h[AR(P.W)])}; Y2=function(P){return P?(P.itag||"")+";"+(P.lmt||0)+";"+(P.xtags||""):""}; bd=function(P,v,l,e){this.initRange=l;this.indexRange=e;this.W=null;this.G=!1;this.T=0;this.Y=this.oe=this.K=null;this.info=v;this.JR=new Ko(P)}; x2=function(P,v){this.start=P;this.end=v;this.length=v-P+1}; po=function(P){P=P.split("-");var v=Number(P[0]),l=Number(P[1]);if(!isNaN(v)&&!isNaN(l)&&P.length===2&&(P=new x2(v,l),!isNaN(P.start)&&!isNaN(P.end)&&!isNaN(P.length)&&P.length>0))return P}; Lo=function(P,v){return new x2(P,P+v-1)}; Uga=function(P){return P.end==null?{start:String(P.start)}:{start:String(P.start),end:String(P.end)}}; SV=function(P){if(!P)return new x2(0,0);var v=Number(P.start);P=Number(P.end);if(!isNaN(v)&&!isNaN(P)&&(v=new x2(v,P),v.length>0))return v}; G8=function(P,v,l,e,h,z,m,Q,t,y,C,f){e=e===void 0?"":e;this.type=P;this.W=v;this.range=l;this.source=e;this.mu=C;this.clipId=f===void 0?"":f;this.j=[];this.Z="";this.n0=-1;this.S=this.X=0;this.Z=e;this.n0=h>=0?h:-1;this.startTime=z||0;this.duration=m||0;this.K=Q||0;this.G=t>=0?t:this.range?this.range.length:NaN;this.Y=this.range?this.K+this.G===this.range.length:y===void 0?!!this.G:y;this.range?(this.ao=this.startTime+this.duration*this.K/this.range.length,this.T=this.duration*this.G/this.range.length, this.EF=this.ao+this.T):ZWD(this)}; ZWD=function(P){P.ao=P.startTime;P.T=P.duration;P.EF=P.ao+P.T}; jSw=function(P,v,l){var e=!(!v||v.W!==P.W||v.type!==P.type||v.n0!==P.n0);return l?e&&!!v&&(P.range&&v.range?v.range.end===P.range.end:v.range===P.range)&&v.K+v.G===P.K+P.G:e}; XI=function(P){return P.type===1||P.type===2}; BH=function(P){return P.type===3||P.type===6}; id=function(P,v){return P.W===v.W?P.range&&v.range?P.range.start+P.K+P.G===v.range.start+v.K:P.n0===v.n0?P.K+P.G===v.K:P.n0+1===v.n0&&v.K===0&&P.Y:!1}; HWx=function(P,v){return P.n0!==v.n0&&v.n0!==P.n0+1||P.type!==v.type?!1:id(P,v)?!0:Math.abs(P.ao-v.ao)<=1E-6&&P.n0===v.n0?!1:a19(P,v)}; a19=function(P,v){return id(P,v)||Math.abs(P.EF-v.ao)<=1E-6||P.n0+1===v.n0&&v.K===0&&P.Y?!0:!1}; U8=function(P){return P.n0+(P.Y?1:0)}; Eq2=function(P){P.length===1||g.SK(P,function(l){return!!l.range}); for(var v=1;v =v.range.start+v.K&&P.range.start+P.K+P.G<=v.range.start+v.K+v.G:P.n0===v.n0&&P.K>=v.K&&(P.K+P.G<=v.K+v.G||v.Y)}; Tlq=function(P,v){return P.W!==v.W?!1:P.type===4&&v.type===3&&P.W.cP()?(P=P.W.Cx(P),iB(P,function(l){return Tlq(l,v)})):P.n0===v.n0&&!!v.G&&v.K+v.G>P.K&&v.K+v.G<=P.K+P.G}; jV=function(P,v){var l=v.n0;P.Z="updateWithSegmentInfo";P.n0=l;if(P.startTime!==v.startTime||P.duration!==v.duration)P.startTime=v.startTime+P.X,P.duration=v.duration,ZWD(P)}; a1=function(P,v){var l=this;this.N5=P;this.Y=this.W=null;this.Z=this.WB=NaN;this.qZ=this.requestId=null;this.Kh={oLc:function(){return l.range}}; this.JR=P[0].W.JR;this.K=v||"";this.N5[0].range&&this.N5[0].G>0&&(WLu(P)?(this.range=Eq2(P),this.G=this.range.length):(this.range=this.N5[this.N5.length-1].range,this.G=OWx(P)))}; HH=function(P){return!XI(P.N5[P.N5.length-1])}; E8=function(P){return P.N5[P.N5.length-1].type===4}; g.WH=function(P,v,l){l=P.qZ===null?P.JR.qZ(v,l,P.N5[0].type):P.qZ;if(P.W){v=l?x_(P.W,v.kB):P.W;var e=new D6(v);e.get("alr")||e.set("alr","yes");P.K&&LLa(e,P.K)}else/http[s]?:\/\//.test(P.K)?e=new D6(new g.q9(P.K)):(e=qN(P.JR,l,v),P.K&&LLa(e,P.K));(v=P.range)?e.set("range",v.toString()):P.N5[0].W.Ye()&&P.N5.length===1&&P.N5[0].K&&e.set("range",P.N5[0].K+"-");P.requestId&&e.set("req_id",P.requestId);isNaN(P.WB)||e.set("headm",P.WB.toString());isNaN(P.Z)||e.set("mffa",P.Z+"ms");P.urlParams&&g.J3(P.urlParams, function(h,z){e.set(z,h)}); return e}; VL6=function(P){if(P.range)return P.G;P=P.N5[0];return Math.round(P.T*P.W.info.FJ)}; dgy=function(P,v){return Math.max(0,P.N5[0].ao-v)}; O8=function(P,v,l,e,h,z){z=z===void 0?0:z;bd.call(this,P,v,e,void 0);this.Z=l;this.rY=z;this.index=h||new g.SM}; Pfa=function(P,v,l,e,h){this.n0=P;this.startSecs=v;this.Er=l;this.W=e||NaN;this.K=h||NaN}; o1=function(P,v,l){for(;P;P=P.parentNode)if(P.attributes&&(!l||P.nodeName===l)){var e=P.getAttribute(v);if(e)return e}return""}; s8=function(P,v){for(;P;P=P.parentNode){var l=P.getElementsByTagName(v);if(l.length>0)return l[0]}return null}; vJ7=function(P){if(!P)return 0;var v=P.match(/PT(([0-9]*)H)?(([0-9]*)M)?(([0-9.]*)S)?/);return v?(Number(v[2])|0)*3600+(Number(v[4])|0)*60+(Number(v[6])|0):Number(P)|0}; lTw=function(P){return P.match(/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})\.(\d{3})$/)?P+"Z":P}; rR=function(){this.W=[];this.K=null;this.T=0;this.G=[];this.Z=!1;this.j="";this.Y=-1}; ezy=function(P){var v=P.G;P.G=[];return v}; hzw=function(){this.Y=[];this.W=null;this.K={};this.G={}}; Qby=function(P,v){var l=[];v=Array.from(v.getElementsByTagName("SegmentTimeline"));v=g.N(v);for(var e=v.next();!e.done;e=v.next()){e=e.value;var h=e.parentNode.parentNode,z=null;h.nodeName==="Period"?z=zzq(P):h.nodeName==="AdaptationSet"?(h=h.getAttribute("id")||h.getAttribute("mimetype")||"",z=m6y(P,h)):h.nodeName==="Representation"&&(h=h.getAttribute("id")||"",z=Rzy(P,h));if(z==null)return;z.update(e);g.l9(l,ezy(z))}g.l9(P.Y,l);lya(P.Y,function(m){return m.startSecs*1E3+m.W})}; ts6=function(P){P.W&&(P.W.W=[]);g.J3(P.K,function(v){v.W=[]}); g.J3(P.G,function(v){v.W=[]})}; zzq=function(P){P.W||(P.W=new rR);return P.W}; m6y=function(P,v){P.K[v]||(P.K[v]=new rR);return P.K[v]}; Rzy=function(P,v){P.G[v]||(P.G[v]=new rR);return P.G[v]}; T8=function(P){var v=P===void 0?{}:P;P=v.rY===void 0?0:v.rY;var l=v.fk===void 0?!1:v.fk;var e=v.ZY===void 0?0:v.ZY;var h=v.Mv===void 0?0:v.Mv;var z=v.UR===void 0?Infinity:v.UR;var m=v.Kx===void 0?0:v.Kx;var Q=v.cz===void 0?!1:v.cz;v=v.oE===void 0?!1:v.oE;g.SM.call(this);this.Tm=this.Fp=-1;this.aY=P;this.ZY=e;this.fk=l;this.Mv=h;this.UR=z;this.Kx=m;((this.cz=Q)||isFinite(z)&&this.UR>0)&&l&&MN&&(this.K=!1,this.G="postLive");this.oE=v}; Vs=function(P,v){return Qv(P.segments,function(l){return v-l.n0})}; dR=function(P,v,l){l=l===void 0?{}:l;O8.call(this,P,v,"",void 0,void 0,l.rY||0);this.index=new T8(l)}; Pj=function(P,v,l){bd.call(this,P,v);this.Z=l;P=this.index=new g.SM;P.K=!1;P.G="d"}; yix=function(P,v,l){var e=P.index.Hr(v),h=P.index.getStartTime(v),z=P.index.getDuration(v);l?z=l=0:l=P.info.FJ*z;return new a1([new G8(3,P,void 0,"otfCreateRequestInfoForSegment",v,h,z,0,l)],e)}; CfB=function(P,v){if(!P.index.isLoaded()){var l=[],e=v.Y;v=v.Z.split(",").filter(function(C){return C.length>0}); for(var h=0,z=0,m=0,Q=/^(\d+)/,t=/r=(\d+)/,y=0;y 0&&(v-=P.timestampOffset);var l=g.ea(P)+v;gJB(P,l);P.timestampOffset=v}; gJB=function(P,v){g.PB(P.info.W.info)||P.info.W.info.C6();P.G=v;if(g.PB(P.info.W.info)){var l=P.f6();P=P.info.W.W;for(var e=NaN,h=NaN,z=0;Vy(l,z);){var m=dG(l,z);isNaN(e)&&(m.type===1936286840?e=m.data.getUint32(m.dataOffset+8):m.type===1836476516&&(e=g.rG(m)));if(m.type===1952867444){!e&&P&&(e=M9(P));var Q=g.vH(m);isNaN(h)&&(h=Math.round(v*e)-Q);var t=m;Q+=h;if(t.data.getUint8(t.dataOffset)){var y=t.data;t=t.dataOffset+4;y.setUint32(t,Math.floor(Q/4294967296));y.setUint32(t+4,Q&4294967295)}else t.data.setUint32(t.dataOffset+ 4,Q)}z=PH(m.type)?z+8:z+m.size}return!0}l=new h_(P.f6());P=P.Z?l:new h_(new DataView(P.info.W.W.buffer));e=$2(P);P=l.pos;l.pos=0;if(I1(l)&&Qs(l,231))if(h=t_(l,!0),v=Math.floor(v*1E9/e),Math.ceil(Math.log(v)/Math.log(2)/8)>h)v=!1;else{for(e=h-1;e>=0;e--)l.W.setUint8(l.pos+e,v&255),v>>>=8;l.pos=P;v=!0}else v=!1;return v}; zB=function(P,v){v=v===void 0?!1:v;var l=hp(P);P=v?0:P.info.T;return l||P}; hp=function(P){g.PB(P.info.W.info)||P.info.W.info.C6();if(P.K&&P.info.type===6)return P.K.rY;if(g.PB(P.info.W.info)){var v=P.f6();var l=0;v=g.eV(v,1936286840);v=g.N(v);for(var e=v.next();!e.done;e=v.next())e=JD9(e.value),l+=e.Ug[0]/e.b7;l=l||NaN;if(!(l>=0))a:{l=P.f6();v=P.info.W.W;for(var h=e=0,z=0;Vy(l,e);){var m=dG(l,e);if(m.type===1836476516)h=g.rG(m);else if(m.type===1836019558){!h&&v&&(h=M9(v));if(!h){l=NaN;break a}var Q=Tc(m.data,m.dataOffset,1953653094),t=Q;Q=h;var y=Tc(t.data,t.dataOffset, 1952868452);t=Tc(t.data,t.dataOffset,1953658222);var C=ig(y);ig(y);C&2&&ig(y);y=C&8?ig(y):0;var f=ig(t),k=f&1;C=f&4;var w=f&256,I=f&512,J=f&1024;f&=2048;var K=U_(t);k&&ig(t);C&&ig(t);for(var q=k=0;q 2048?"":v.indexOf("https://")===0?v:""}; Cq=function(P,v,l){v.match(Fzu);return P(v,l).then(function(e){var h=g.qa9(e.xhr);return h?Cq(P,h,l):e.xhr})}; w6=function(P,v,l){P=P===void 0?"":P;v=v===void 0?null:v;l=l===void 0?!1:l;g.gA.call(this);var e=this;this.sourceUrl=P;this.isLivePlayback=l;this.h5=this.duration=0;this.isPremiere=this.cz=this.Y=this.isLiveHeadPlayable=this.isLive=this.K=!1;this.UR=this.Mv=0;this.isOtf=this.Ei=!1;this.q5=(0,g.Gz)();this.Wg=Infinity;this.W={};this.G=new Map;this.state=this.zW=0;this.timeline=null;this.isManifestless=!1;this.J5=[];this.T=null;this.T1=0;this.Z="";this.kf=NaN;this.Hg=this.It=this.timestampOffset=this.j= 0;this.h1=this.Gq=NaN;this.Xq=0;this.Ic=this.X=!1;this.wM=[];this.Pg={};this.QW=NaN;this.Kh={Xw2:function(Q){fq(e,Q)}}; var h;this.A5=(h=v)==null?void 0:h.l$("html5_use_network_error_code_enums");Aiu=!!v&&v.l$("html5_modern_vp9_mime_type");var z;g6=!((z=v)==null||!z.l$("html5_enable_flush_during_seek"))&&g.VS();var m;kT=!((m=v)==null||!m.l$("html5_enable_reset_audio_decoder"))&&g.VS()}; Ya9=function(P){return g.cr(P.W,function(v){return!!v.info.video&&v.info.video.W>=2160})}; T4a=function(P){return g.cr(P.W,function(v){return!!v.info.video&&v.info.video.isHdr()})}; Dh=function(P){return g.cr(P.W,function(v){return!!v.info.EQ})}; g.b0D=function(P){return g.cr(P.W,function(v){return lf(v.info)})}; x6y=function(P){return g.cr(P.W,function(v){return v.info.video?v.info.video.projectionType==="EQUIRECTANGULAR":!1})}; pBD=function(P){return g.cr(P.W,function(v){return v.info.video?v.info.video.projectionType==="EQUIRECTANGULAR_THREED_TOP_BOTTOM":!1})}; LzP=function(P){return g.cr(P.W,function(v){return v.info.video?v.info.video.projectionType==="MESH":!1})}; Sa6=function(P){return g.cr(P.W,function(v){return v.info.video?v.info.video.stereoLayout===1:!1})}; GN2=function(P){return ohW(P.W,function(v){return v.info.video?v.kX():!0})}; wG=function(P){return g.cr(P.W,function(v){return Y_(v.JR.W)})}; fq=function(P,v){P.W[v.info.id]=v;P.G.set(Y2(g.es(v.info,P.Ei)),v)}; XBy=function(P,v){return Y2({itag:v.itag,lmt:P.Ei?0:v.lmt||0,xtags:v.xtags})}; Dl=function(P,v,l){l=l===void 0?0:l;var e=P.mimeType||"",h=P.itag;var z=P.xtags;h=h?h.toString():"";z&&(h+=";"+z);z=h;if(zN(e)){var m=P.width||640;h=P.height||360;var Q=P.fps,t=P.qualityLabel,y=P.colorInfo,C=P.projectionType,f;P.stereoLayout&&(f=BJx[P.stereoLayout]);var k=Kz7(P)||void 0;if(y==null?0:y.primaries)var w=i0W[y.primaries]||void 0;m=new E6(m,h,Q,C,f,void 0,t,k,w);e=$T(e,m,oS[P.itag||""]);g6&&(e+="; enableflushduringseek=true");kT&&(e+="; enableresetaudiodecoder=true")}var I;if(hi(e)){var J= P.audioSampleRate;f=P.audioTrack;J=new jL(J?+J:void 0,P.audioChannels,P.spatialAudioType,P.isDrc,P.loudnessDb,P.trackAbsoluteLoudnessLkfs,P.audioQuality||"AUDIO_QUALITY_UNKNOWN");f&&(w=f.displayName,h=f.id,f=f.audioIsDefault,w&&(I=new g.y5(w,h||"",!!f)))}var K;P.captionTrack&&(t=P.captionTrack,f=t.displayName,w=t.vssId,h=t.languageCode,Q=t.kind,t=t.id,f&&w&&h&&(K=new Jiw(f,w,h,Q,P.xtags,t)));f=Number(P.bitrate)/8;w=Number(P.contentLength);h=Number(P.lastModified);t=P.drmFamilies;Q=P.type;l=l&&w?w/ l:0;P=Number(P.approxDurationMs);if(v&&t){var q={};t=g.N(t);for(y=t.next();!y.done;y=t.next())(y=IK[y.value])&&(q[y]=v[y])}return new s6(z,e,{audio:J,video:m,Rt:I,EQ:q,FJ:f,X5:l,contentLength:w,lastModified:h,captionTrack:K,streamType:Q,approxDurationMs:P})}; nq=function(P,v,l){l=l===void 0?0:l;var e=P.type;var h=P.itag;var z=P.xtags;z&&(h=P.itag+";"+z);if(zN(e)){var m=(P.size||"640x360").split("x");m=new E6(+m[0],+m[1],+P.fps,P.projection_type,+P.stereo_layout,void 0,P.quality_label,P.eotf,P.primaries);e=$T(e,m,oS[P.itag]);g6&&(e+="; enableflushduringseek=true");kT&&(e+="; enableresetaudiodecoder=true")}var Q;if(hi(e)){var t=new jL(+P.audio_sample_rate||void 0,+P.audio_channels||0,P.spatial_audio_type,!!P.drc);P.name&&(Q=new g.y5(P.name,P.audio_track_id, P.isDefault==="1"))}var y;P.caption_display_name&&P.caption_vss_id&&P.caption_language_code&&(y=new Jiw(P.caption_display_name,P.caption_vss_id,P.caption_language_code,P.caption_kind,P.xtags,P.caption_id));z=Number(P.bitrate)/8;var C=Number(P.clen),f=Number(P.lmt);l=l&&C?C/l:0;if(v&&P.drm_families){var k={};for(var w=g.N(P.drm_families.split(",")),I=w.next();!I.done;I=w.next())I=I.value,k[I]=v[I]}return new s6(h,e,{audio:t,video:m,Rt:Q,EQ:k,FJ:z,X5:l,contentLength:C,lastModified:f,captionTrack:y, streamType:P.stream_type,approxDurationMs:Number(P.approx_duration_ms)})}; U67=function(P){return iB(P,function(v){return"FORMAT_STREAM_TYPE_OTF"===v.stream_type})?"FORMAT_STREAM_TYPE_OTF":"FORMAT_STREAM_TYPE_UNKNOWN"}; Z0y=function(P){return iB(P,function(v){return"FORMAT_STREAM_TYPE_OTF"===v.type})?"FORMAT_STREAM_TYPE_OTF":"FORMAT_STREAM_TYPE_UNKNOWN"}; jba=function(P,v){return P.timeline?ew(P.timeline.Y,v):P.J5.length?ew(P.J5,v):[]}; Nt=function(P,v,l){v=v===void 0?"":v;l=l===void 0?"":l;P=new g.q9(P,!0);P.set("alr","yes");l&&(l=nO6(decodeURIComponent(l)),P.set(v,encodeURIComponent(l)));return P}; WzW=function(P,v){var l=o1(v,"id");l=l.replace(":",";");var e=o1(v,"mimeType"),h=o1(v,"codecs");e=h?e+'; codecs="'+h+'"':e;h=Number(o1(v,"bandwidth"))/8;var z=Number(s8(v,"BaseURL").getAttribute(P.Z+":contentLength")),m=P.duration&&z?z/P.duration:0;if(zN(e)){var Q=Number(o1(v,"width"));var t=Number(o1(v,"height")),y=Number(o1(v,"frameRate")),C=aTa(o1(v,P.Z+":projectionType"));a:switch(o1(v,P.Z+":stereoLayout")){case "layout_left_right":var f=1;break a;case "layout_top_bottom":f=2;break a;default:f= 0}Q=new E6(Q,t,y,C,f)}if(hi(e)){var k=Number(o1(v,"audioSamplingRate"));var w=Number(o1(v.getElementsByTagName("AudioChannelConfiguration")[0],"value"));t=H0q(o1(v,P.Z+":spatialAudioType"));k=new jL(k,w,t);a:{w=o1(v,"lang")||"und";if(t=s8(v,"Role"))if(C=o1(t,"value")||"",g.Yr(EJ6,C)){t=w+"."+EJ6[C];y=C==="main";P=o1(v,P.Z+":langName")||w+" - "+C;w=new g.y5(P,t,y);break a}w=void 0}}if(v=s8(v,"ContentProtection"))if(v.getAttribute("schemeIdUri")==="http://youtube.com/drm/2012/10/10"){var I={};for(v= v.firstChild;v!=null;v=v.nextSibling)v instanceof Element&&/SystemURL/.test(v.nodeName)&&(P=v.getAttribute("type"),t=v.textContent,P&&t&&(I[P]=t.trim()))}else I=void 0;return new s6(l,e,{audio:k,video:Q,Rt:w,EQ:I,FJ:h,X5:m,contentLength:z})}; aTa=function(P){switch(P){case "equirectangular":return"EQUIRECTANGULAR";case "equirectangular_threed_top_bottom":return"EQUIRECTANGULAR_THREED_TOP_BOTTOM";case "mesh":return"MESH";case "rectangular":return"RECTANGULAR";default:return"UNKNOWN"}}; H0q=function(P){switch(P){case "spatial_audio_type_ambisonics_5_1":return"SPATIAL_AUDIO_TYPE_AMBISONICS_5_1";case "spatial_audio_type_ambisonics_quad":return"SPATIAL_AUDIO_TYPE_AMBISONICS_QUAD";case "spatial_audio_type_foa_with_non_diegetic":return"SPATIAL_AUDIO_TYPE_FOA_WITH_NON_DIEGETIC";default:return"SPATIAL_AUDIO_TYPE_NONE"}}; oJ9=function(P,v){v=v===void 0?"":v;P.state=1;P.q5=(0,g.Gz)();return ci9(v||P.sourceUrl).then(function(l){if(!P.s$()){P.zW=l.status;l=l.responseText;var e=new DOMParser;l=T0(e,ib9(l),"text/xml").getElementsByTagName("MPD")[0];P.Wg=vJ7(o1(l,"minimumUpdatePeriod"))*1E3||Infinity;b:{if(l.attributes){e=g.N(l.attributes);for(var h=e.next();!h.done;h=e.next())if(h=h.value,h.value==="http://youtube.com/yt/2012/10/10"){e=h.name.split(":")[1];break b}}e=""}P.Z=e;P.isLive=P.Wg =P.Wg}; riW=function(P){P.T&&P.T.stop()}; O0q=function(P){var v=P.Wg;isFinite(v)&&(Jp(P)?P.refresh():(v=Math.max(0,P.q5+v-(0,g.Gz)()),P.T||(P.T=new g.mr(P.refresh,v,P),g.Z(P,P.T)),P.T.start(v)))}; Ms7=function(P){P=P.W;for(var v in P){var l=P[v].index;if(l.isLoaded())return l.vR()+1}return 0}; uM=function(P){return P.It?P.It-(P.j||P.timestampOffset):0}; Kq=function(P){return P.Hg?P.Hg-(P.j||P.timestampOffset):0}; cj=function(P){if(!isNaN(P.kf))return P.kf;var v=P.W,l;for(l in v){var e=v[l].index;if(e.isLoaded()&&!lf(v[l].info)){v=0;for(l=e.EW();l<=e.vR();l++)v+=e.getDuration(l);v/=e.Gi();v=Math.round(v/.5)*.5;e.Gi()>10&&(P.kf=v);return v}if(P.isLive&&(e=v[l],e.rY))return e.rY}return NaN}; TJW=function(P,v){P=rQ9(P.W,function(e){return e.index.isLoaded()}); if(!P)return NaN;P=P.index;var l=P.lh(v);return P.getStartTime(l)===v?v:l =0&&h.segments.splice(z,1)}}}; d6u=function(P){for(var v in P.W)lf(P.W[v].info)||tLD(P.W[v].index,Infinity)}; Ap=function(P,v,l){for(var e in P.W){var h=P.W[e].index,z=v,m=l;h.fk&&(z&&(h.Fp=Math.max(h.Fp,z)),m&&(h.Tm=Math.max(h.Tm||0,m)))}l&&(P.QW=l/1E3)}; Pm9=function(P){P.Hg=0;P.It=0;P.Xq=0}; bM=function(P){return P.Ic&&P.isManifestless?P.isLiveHeadPlayable:P.isLive}; $T=function(P,v,l){xT===null&&(xT=window.MediaSource&&MediaSource.isTypeSupported&&MediaSource.isTypeSupported('video/webm; codecs="vp09.02.51.10.01.09.16.09.00"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.02.51.10.01.09.99.99.00"'));if(Aiu&&window.MediaSource&&MediaSource.isTypeSupported!==void 0)return xT||l!=="9"&&l!=="("?xT||l!=="9h"&&l!=="(h"||(P='video/webm; codecs="vp9.2"'):P='video/webm; codecs="vp9"',P;if(!xT&&!pq||P!=='video/webm; codecs="vp9"'&&P!=='video/webm; codecs="vp9.2"')return P; l="00";var e="08",h="01",z="01",m="01";P==='video/webm; codecs="vp9.2"'&&(l="02",e="10",v.primaries==="bt2020"&&(m=h="09"),v.K==="smpte2084"&&(z="16"),v.K==="arib-std-b67"&&(z="18"));return'video/webm; codecs="'+["vp09",l,"51",e,"01",h,z,m,"00"].join(".")+'"'}; Sa=function(P,v,l){P=""+P+(v>49?"p60":v>32?"p48":"");v=Eg()[P];if(v!=null&&v>0)return v;v=Lq.get(P);if(v!=null&&v>0)return v;l=l==null?void 0:l.get(P);return l!=null&&l>0?l:8192}; vG9=function(P){this.Z3=P;this.zK=this.ek=this.Pg=this.Z=this.Y=this.QW=this.nI=this.h5=this.J5=!1;this.j=this.T=0;this.U$=!1;this.T1=!0;this.D3=!1;this.gH=0;this.ex=this.wM=!1;this.MV=!0;this.Ic=this.q5=!1;this.W={};this.aV=this.disableAv1=this.WK=this.SN=this.Bg=this.TG=this.K=this.S=!1;this.bC=this.Z3.V("html5_disable_aac_preference");this.Xq=Infinity;this.Hg=0;this.CI=this.Z3.vK();this.jS=this.Z3.experiments.l$("html5_enable_vp9_fairplay");this.Ro=this.Z3.V("html5_force_av1_for_testing");this.A5= g.ID(this.Z3.experiments,"html5_av1_ordinal_cap");this.GP=this.Z3.V("html5_disable_hfr_when_vp9_encrypted_2k4k_unsupported");this.oV=this.Z3.V("html5_account_onesie_format_selection_during_format_filter");this.FJ=g.ID(this.Z3.experiments,"html5_max_byterate");this.X=this.Z3.V("html5_sunset_aac_high_codec_family");this.kf=this.Z3.V("html5_sunset_aac_high_codec_family");this.It=this.Z3.V("html5_enable_iamf_audio");this.hs=this.Z3.experiments.l$("html5_allow_capability_merge");this.Nd=this.Z3.V("html5_log_format_filter_rejection_reason_as_string"); this.XE=this.Z3.V("html5_prefer_vp9_sfr")}; VIw=function(P){if(P.h5)return["f"];var v="9h 9 h 8 (h ( H *".split(" ");P.wM&&(v.unshift("1"),v.unshift("1h"));P.ek&&v.unshift("h");P.Wg&&(v=(lka[P.Wg]||[P.Wg]).concat(v));return v}; OeP=function(P){var v=["o","a","A"];P.Hg===1&&(P.QW&&(v=["m","M"].concat(v)),P.Y&&(v=["mac3","MAC3"].concat(v)),P.Z&&(v=["meac3","MEAC3"].concat(v)),P.It&&(v=["i","I"].concat(v)));P.J5&&(v=["so","sa"].concat(v));!P.zK||P.Pg||P.G||P.bC||v.unshift("a");P.nI&&!P.X&&v.unshift("ah");P.G&&(v=(lka[P.G]||[P.G]).concat(v));return v}; GB=function(P,v,l,e){v=v===void 0?{}:v;if(e===void 0?0:e)return v.disabled=1,0;if(Kr(P.Z,cn.AV1_CODECS)&&Kr(P.Z,cn.HEIGHT)&&Kr(P.Z,cn.BITRATE))return v.isCapabilityUsable=1,8192;try{var h=Yu2();if(h)return v.localPref=h}catch(Q){}e=1080;h=navigator.hardwareConcurrency;h<=2&&(e=480);v.coreCount=h;if(h=g.ID(P.experiments,"html5_default_av1_threshold"))e=v["default"]=h;!P.V("html5_disable_av1_arm_check")&&ux7()&&(v.isArm=1,e=240);if(P=P.Z.QW)v.mcap=P,e=Math.max(e,P);if(l){var z,m;if(P=(z=l.videoInfos.find(function(Q){return Ta(Q)}))== null?void 0:(m=z.K)==null?void 0:m.powerEfficient)e=8192,v.isEfficient=1; l=l.videoInfos[0].video;z=Math.min(Sa("1",l.fps),Sa("1",30));v.perfCap=z;e=Math.min(e,z);l.isHdr()&&!P&&(v.hdr=1,e*=.75)}else l=Sa("1",30),v.perfCap30=l,e=Math.min(e,l),l=Sa("1",60),v.perfCap60=l,e=Math.min(e,l);return v.av1Threshold=e}; Xl=function(P,v,l,e){this.flavor=P;this.keySystem=v;this.K=l;this.experiments=e;this.W={};this.h5=this.keySystemAccess=null;this.N1=this.S9=-1;this.S6=null;this.G=!!e&&e.l$("edge_nonprefixed_eme");e&&e.l$("html5_enable_vp9_fairplay")}; iM=function(P){return P.G?!1:!P.keySystemAccess&&!!Bj()&&P.keySystem==="com.microsoft.playready"}; Uo=function(P){return P.keySystem==="com.microsoft.playready"}; Zl=function(P){return!P.keySystemAccess&&!!Bj()&&P.keySystem==="com.apple.fps.1_0"}; aK=function(P){return P.keySystem==="com.youtube.fairplay"}; Hj=function(P){return P.keySystem==="com.youtube.fairplay.sbdl"}; g.Eo=function(P){return P.flavor==="fairplay"}; Bj=function(){var P=window,v=P.MSMediaKeys;vx()&&!v&&(v=P.WebKitMediaKeys);return v&&v.isTypeSupported?v:null}; Oo=function(P){if(!navigator.requestMediaKeySystemAccess)return!1;if(g.Xs&&!g.VS())return Sd("45");if(g.vs||g.u$)return P.l$("edge_nonprefixed_eme");if(g.Wj)return Sd("47");if(g.FA){if(P.l$("html5_enable_safari_fairplay"))return!1;if(P=g.ID(P,"html5_safari_desktop_eme_min_version"))return Sd(P)}return!0}; enq=function(P,v,l,e){var h=d$(),z=(l=h||l&&vx())?["com.youtube.fairplay"]:["com.widevine.alpha"];v&&z.unshift("com.youtube.widevine.l3");h&&e&&z.unshift("com.youtube.fairplay.sbdl");return l?z:P?[].concat(g.u(z),g.u(oK.playready)):[].concat(g.u(oK.playready),g.u(z))}; r6=function(){this.K=this.Wi=0;this.W=Array.from({length:so.length}).fill(0)}; hn9=function(){}; znx=function(){this.startTimeMs=(0,g.Gz)();this.W=!1}; mk2=function(){this.W=new hn9}; Rnq=function(P,v,l,e){e=e===void 0?1:e;l>=0&&(v in P.W||(P.W[v]=new r6),P.W[v].PT(l,e))}; QV2=function(P,v,l,e,h){var z=(0,g.Gz)(),m=h?h(v):void 0,Q;h=(Q=m==null?void 0:m.Wi)!=null?Q:1;if(h!==0){var t;Q=(t=m==null?void 0:m.profile)!=null?t:l;Rnq(P,Q,z-e,h)}return v}; Mt=function(P,v,l,e,h){if(v&&typeof v==="object"){var z=function(m){return QV2(P,m,l,e,h)}; if(gI(v))return v.then(z);if(tqx(v))return D9(v,z)}return QV2(P,v,l,e,h)}; yUW=function(){}; TB=function(P,v,l,e,h){e=e===void 0?!1:e;g.U.call(this);this.Z3=v;this.useCobaltWidevine=e;this.f0=h;this.K=[];this.G={};this.W={};this.callback=null;this.Z=!1;this.Y=[];this.initialize(P,!l)}; fky=function(P,v){P.callback=v;P.Y=[];Oo(P.Z3.experiments)?V5(P):CmP(P)}; V5=function(P){if(!P.s$())if(P.K.length===0)P.callback(P.Y);else{var v=P.K[0],l=P.G[v],e=gGu(P,l);if(d6&&d6.keySystem===v&&d6.Kf6===JSON.stringify(e))P.f0("remksa",{re:!0}),k1q(P,l,d6.keySystemAccess);else{var h,z;P.f0("remksa",{re:!1,ok:(z=(h=d6)==null?void 0:h.keySystem)!=null?z:""});d6=void 0;(Pa.isActive()?Pa.PU("emereq",function(){return navigator.requestMediaKeySystemAccess(v,e)}):navigator.requestMediaKeySystemAccess(v,e)).then(c1(function(m){k1q(P,l,m,e)}),c1(function(){P.Z=!P.Z&&P.G[P.K[0]].flavor=== "widevine"; P.Z||P.K.shift();V5(P)}))}}}; k1q=function(P,v,l,e){if(!P.s$()){e&&(d6={keySystem:v.keySystem,keySystemAccess:l,Kf6:JSON.stringify(e)});v.keySystemAccess=l;if(Uo(v)){l=SL();e=g.N(Object.keys(P.W[v.flavor]));for(var h=e.next();!h.done;h=e.next())h=h.value,v.W[h]=!!l.canPlayType(h)}else{l=v.keySystemAccess.getConfiguration();if(l.audioCapabilities)for(e=g.N(l.audioCapabilities),h=e.next();!h.done;h=e.next())wPB(P,v,h.value);if(l.videoCapabilities)for(l=g.N(l.videoCapabilities),e=l.next();!e.done;e=l.next())wPB(P,v,e.value)}P.Y.push(v); P.useCobaltWidevine||P.V("html5_enable_vp9_fairplay")&&Hj(v)?(P.K.shift(),V5(P)):P.callback(P.Y)}}; wPB=function(P,v,l){P.V("log_robustness_for_drm")?v.W[l.contentType]=l.robustness||!0:v.W[l.contentType]=!0}; gGu=function(P,v){var l={initDataTypes:["cenc","webm"],audioCapabilities:[],videoCapabilities:[]};if(P.V("html5_enable_vp9_fairplay")&&aK(v))return l.audioCapabilities.push({contentType:'audio/mp4; codecs="mp4a.40.5"'}),l.videoCapabilities.push({contentType:'video/mp4; codecs="avc1.4d400b"'}),[l];Uo(v)&&(l.initDataTypes=["keyids","cenc"]);for(var e=g.N(Object.keys(P.W[v.flavor])),h=e.next();!h.done;h=e.next()){h=h.value;var z=h.indexOf("audio/")===0,m=z?l.audioCapabilities:l.videoCapabilities;v.flavor!== "widevine"||P.Z?m.push({contentType:h}):z?m.push({contentType:h,robustness:"SW_SECURE_CRYPTO"}):(g.Xs&&g.Mc("windows nt")&&!P.V("html5_drm_enable_moho")||m.push({contentType:h,robustness:"HW_SECURE_ALL"}),z=h,P.V("html5_enable_cobalt_experimental_vp9_decoder")&&h.includes("vp09")&&(z=h+"; experimental=allowed"),m.push({contentType:z,robustness:"SW_SECURE_DECODE"}),va(P.Z3)==="MWEB"&&(Ru()||T_())&&(P.f0("swcrypto",{}),m.push({contentType:h,robustness:"SW_SECURE_CRYPTO"})))}return[l]}; CmP=function(P){if(Bj()&&(g.FA||eB&&P.V("html5_drm_support_ios_mweb")))P.Y.push(new Xl("fairplay","com.apple.fps.1_0","",P.Z3.experiments));else{var v=$kW(),l=g.om(P.K,function(e){var h=P.G[e],z=!1,m=!1,Q;for(Q in P.W[h.flavor])v(Q,e)&&(h.W[Q]=!0,z=z||Q.indexOf("audio/")===0,m=m||Q.indexOf("video/")===0);return z&&m}); l&&P.Y.push(P.G[l]);P.K=[]}P.callback(P.Y)}; $kW=function(){var P=Bj();if(P){var v=P.isTypeSupported;return function(e,h){return v(h,e)}}var l=SL(); return l&&(l.addKey||l.webkitAddKey)?function(e,h){return!!l.canPlayType(e,h)}:function(){return!1}}; Ika=function(P){this.experiments=P;this.W=2048;this.Y=0;this.QW=(this.X=this.V("html5_streaming_resilience"))?.5:.25;var v=v===void 0?0:v;this.G=g.ID(this.experiments,"html5_media_time_weight_prop")||v;this.Z=this.V("html5_app_limited_aware_bwe");this.T1=g.ID(this.experiments,"html5_sabr_timeout_penalty_factor")||1;this.J5=(this.T=this.experiments.l$("html5_consider_end_stall"))&&ly;this.K=this.experiments.l$("html5_measure_max_progress_handling");this.Wg=this.V("html5_treat_requests_pre_elbow_as_metadata"); this.j=this.V("html5_media_time_weight")||!!this.G;this.S=g.ID(this.experiments,"html5_streaming_fallback_byterate");this.V("html5_sabr_live_audio_early_return_fix")&&ly&&(this.W=65536)}; Dkw=function(P,v){this.W=void 0;this.experimentIds=P?P.split(","):[];this.flags=QS(v||"","&");P={};v=g.N(this.experimentIds);for(var l=v.next();!l.done;l=v.next())P[l.value]=!0;this.experiments=P}; g.ID=function(P,v){P=P.flags[v];JSON.stringify(P);return Number(P)||0}; eE=function(P,v){return(P=P.flags[v])?P.toString():""}; nGD=function(P){if(P=P.flags.html5_web_po_experiment_ids)if(P=P.replace(/\[ *(.*?) *\]/,"$1"))return P.split(",").map(Number);return[]}; NZq=function(P){if(P.W)return P.W;if(P.experimentIds.length<=1)return P.W=P.experimentIds,P.W;var v=[].concat(g.u(P.experimentIds)).map(function(e){return Number(e)}); v.sort();for(var l=v.length-1;l>0;--l)v[l]-=v[l-1];P.W=v.map(function(e){return e.toString()}); P.W.unshift("v1");return P.W}; uH6=function(P){return JU6.then(P)}; hW=function(P,v,l){this.experiments=P;this.kf=v;this.wM=l===void 0?!1:l;this.Wg=!!g.j9("cast.receiver.platform.canDisplayType");this.S={};this.j=!1;this.K=new Map;this.T=!0;this.G=this.Y=!1;this.W=new Map;this.QW=0;this.J5=this.experiments.l$("html5_disable_vp9_encrypted");P=g.j9("cast.receiver.platform.getValue");this.T1=g.ID(this.experiments,"html5_kaios_max_resolution");this.Z=!this.Wg&&P&&P("max-video-resolution-vpx")||null;KQa(this)}; vqx=function(P,v,l){l=l===void 0?1:l;var e=v.itag;if(e==="0")return!0;var h=v.mimeType;if(v.C6()&&d$()&&P.experiments.l$("html5_appletv_disable_vp9"))return"dwebm";if(Ta(v)&&P.j)return"dav1";if(v.video&&(v.video.isHdr()||v.video.primaries==="bt2020")&&!(Kr(P,cn.EOTF)||window.matchMedia&&(window.matchMedia("(dynamic-range: high), (video-dynamic-range: high)").matches||window.screen.pixelDepth>24&&window.matchMedia("(color-gamut: p3)").matches)))return"dhdr";if(e==="338"&&!(g.Xs?Sd(53):g.Wj&&Sd(64)))return"dopus"; var z;if(P.T1&&zF&&((z=v.video)==null?void 0:z.W)>P.T1)return"kaios";z=l;z=z===void 0?1:z;l={};v.video&&(v.video.width&&(l[cn.WIDTH.name]=v.video.width),v.video.height&&(l[cn.HEIGHT.name]=v.video.height),v.video.fps&&(l[cn.FRAMERATE.name]=v.video.fps*z),v.video.K&&(l[cn.EOTF.name]=v.video.K),v.FJ&&(l[cn.BITRATE.name]=v.FJ*8*z),v.dM==="("&&(l[cn.CRYPTOBLOCKFORMAT.name]="subsample"),v.video.projectionType==="EQUIRECTANGULAR"||v.video.projectionType==="EQUIRECTANGULAR_THREED_TOP_BOTTOM"||v.video.projectionType=== "MESH")&&(l[cn.DECODETOTEXTURE.name]="true");v.audio&&v.audio.numChannels&&(l[cn.CHANNELS.name]=v.audio.numChannels);P.Y&&rl(v)&&(l[cn.EXPERIMENTAL.name]="allowed");z=g.N(Object.keys(cn));for(var m=z.next();!m.done;m=z.next()){m=cn[m.value];var Q;if(Q=l[m.name])if(Q=!(m===cn.EOTF&&v.mimeType.indexOf("vp09.02")>0)){Q=m;var t=v;Q=!(P.experiments.l$("html5_ignore_h264_framerate_cap")&&Q===cn.FRAMERATE&&kL7(t))}if(Q)if(Kr(P,m))if(P.Z){if(P.Z[m.name] 1080&&v.EQ&&(h+="; hdcp=2.2");return e==="227"?"hqcenc":e!=="585"&&e!=="588"&&e!=="583"&&e!=="586"&&e!=="584"&&e!=="587"&&e!=="591"&&e!=="592"||P.experiments.l$("html5_enable_new_hvc_enc")?P.isTypeSupported(h)?!0:"tpus":"newhvc"}; mx=function(){var P=T_()&&!Sd(29),v=g.Mc("google tv")&&g.Mc("chrome")&&!Sd(30);return P||v?!1:nUy()}; cUW=function(P,v,l){var e=480;v=g.N(v);for(var h=v.next();!h.done;h=v.next()){h=h.value;var z=h.video.W;z<=1080&&z>e&&vqx(P,h,l)===!0&&(e=z)}return e}; g.Rw=function(P,v){v=v===void 0?!1:v;return mx()&&P.isTypeSupported('audio/mp4; codecs="mp4a.40.2"')||!v&&P.canPlayType(SL(),"application/x-mpegURL")?!0:!1}; FQW=function(P){qCu(function(){for(var v=g.N(Object.keys(cn)),l=v.next();!l.done;l=v.next())Kr(P,cn[l.value])})}; Kr=function(P,v){v.name in P.S||(P.S[v.name]=AUa(P,v));return P.S[v.name]}; AUa=function(P,v){if(P.Z)return!!P.Z[v.name];if(v===cn.BITRATE&&P.isTypeSupported('video/webm; codecs="vp9"; width=3840; height=2160; bitrate=2000000')&&!P.isTypeSupported('video/webm; codecs="vp9"; width=3840; height=2160; bitrate=20000000'))return!1;if(v===cn.AV1_CODECS)return P.isTypeSupported("video/mp4; codecs="+v.valid)&&!P.isTypeSupported("video/mp4; codecs="+v.nk);if(v.video){var l='video/webm; codecs="vp9"';P.isTypeSupported(l)||(l='video/mp4; codecs="avc1.4d401e"')}else l='audio/webm; codecs="opus"', P.isTypeSupported(l)||(l='audio/mp4; codecs="mp4a.40.2"');return P.isTypeSupported(l+"; "+v.name+"="+v.valid)&&!P.isTypeSupported(l+"; "+v.name+"="+v.nk)}; YCy=function(P){P.Y||(P.Y=!0,QP(P))}; QP=function(P){P.G=!0;P.experiments.l$("html5_ssap_update_capabilities_on_change")&&bMu(P)}; xkx=function(P,v){var l=0;P.K.has(v)&&(l=P.K.get(v).y6);P.K.set(v,{y6:l+1,Vf:Math.pow(2,l+1)});QP(P)}; nr=function(P){for(var v=[],l=g.N(P.W.keys()),e=l.next();!e.done;e=l.next()){e=e.value;var h=P.W.get(e);v.push(e+"_"+h.maxWidth+"_"+h.maxHeight)}return v.join(".")}; bMu=function(P){P.X=[];for(var v=g.N(P.W.values()),l=v.next();!l.done;l=v.next()){l=l.value;var e=l.dM;P.experiments.l$("html5_ssap_force_mp4_aac")&&e!=="a"&&e!=="h"||P.K.has(e)||(!P.j||e!=="1"&&e!=="1h")&&P.X.push(l)}}; o4D=function(P,v){for(var l=new Map,e=g.N(P.W.keys()),h=e.next();!h.done;h=e.next()){h=h.value;var z=h.split("_")[0];v.has(z)||l.set(h,P.W.get(h))}P.W=l}; rny=function(P,v,l){var e,h=((e=l.video)==null?void 0:e.fps)||0;e=v+"_"+h;var z=!!l.audio,m={itag:l.itag,dM:v,h3:z};if(z)m.numChannels=l.audio.numChannels;else{var Q=l.video;m.maxWidth=Q==null?void 0:Q.width;m.maxHeight=Q==null?void 0:Q.height;m.maxFramerate=h;Kr(P,cn.BITRATE)&&(m.maxBitrateBps=l.FJ*8);m.dC=Q==null?void 0:Q.isHdr()}Q=P.W.get(e);Q?z||(l=Math.max(Q.maxWidth||0,Q.maxHeight||0)>Math.max(m.maxWidth||0,m.maxHeight||0)?Q:m,v={itag:l.itag,dM:v,h3:z,maxWidth:Math.max(Q.maxWidth||0,m.maxWidth|| 0),maxHeight:Math.max(Q.maxHeight||0,m.maxHeight||0),maxFramerate:h,dC:l.dC},Kr(P,cn.BITRATE)&&(v.maxBitrateBps=l.maxBitrateBps),P.W.set(e,v)):P.W.set(e,m)}; MID=function(P,v,l){var e,h=((e=l.video)==null?void 0:e.fps)||0;e=v+"_"+h;var z=!!l.audio,m=P.W.get(e);a:{var Q=P.W.get(e),t=!!l.audio;if(Q){if(t){var y=!1;break a}var C;if(!t&&((y=l.video)==null?0:y.height)&&Q.maxHeight&&Q.maxHeight>=((C=l.video)==null?void 0:C.height)){y=!1;break a}}y=!0}y&&(y=l.itag,v=m?m:{itag:y,dM:v,h3:z},z?v.numChannels=l.audio.numChannels:(z=l.video,v.maxWidth=z==null?void 0:z.width,v.maxHeight=z==null?void 0:z.height,v.maxFramerate=h,Kr(P,cn.BITRATE)&&(v.maxBitrateBps=l.FJ* 8),v.dC=z==null?void 0:z.isHdr()),P.W.set(e,v))}; KQa=function(P){var v;(v=navigator.mediaCapabilities)!=null&&v.decodingInfo&&navigator.mediaCapabilities.decodingInfo({type:"media-source",video:{contentType:'video/mp4; codecs="av01.0.12M.08"',width:3840,height:2160,bitrate:32E6,framerate:60}}).then(function(l){l.smooth&&l.powerEfficient&&(P.QW=2160)})}; tW=function(){g.gA.call(this);this.items={}}; yP=function(){g.FY.apply(this,arguments)}; CP=function(){g.AS.apply(this,arguments)}; pPw=function(P,v,l){this.encryptedClientKey=v;this.Z=l;this.W=new Uint8Array(P.buffer,0,16);this.G=new Uint8Array(P.buffer,16)}; LQa=function(P){P.K||(P.K=new yP(P.W));return P.K}; fP=function(P){try{return No(P)}catch(v){return null}}; SC9=function(P,v){if(!v&&P)try{v=JSON.parse(P)}catch(h){}if(v){P=v.clientKey?fP(v.clientKey):null;var l=v.encryptedClientKey?fP(v.encryptedClientKey):null,e=v.keyExpiresInSeconds?Number(v.keyExpiresInSeconds)*1E3+(0,g.Gz)():null;P&&l&&e&&(this.W=new pPw(P,l,e));v.onesieUstreamerConfig&&(this.onesieUstreamerConfig=fP(v.onesieUstreamerConfig)||void 0);this.baseUrl=v.baseUrl}}; kQ=function(){this.data=new Uint8Array(2048);this.pos=0;g7||(g7=Gi("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_."))}; w7=function(P,v){P.add(v==null||isNaN(v)?0:v+1)}; $Q=function(P){this.W=this.K=0;this.alpha=Math.exp(Math.log(.5)/P)}; Iw=function(P){this.K=P===void 0?15:P;this.values=new Float64Array(176);this.W=new Float64Array(11);this.G=new Float64Array(16)}; DY=function(P,v,l,e){l=l===void 0?.5:l;e=e===void 0?0:e;this.resolution=v;this.K=0;this.G=!1;this.JP=!0;this.W=Math.round(P*this.resolution);this.values=Array(this.W);for(P=0;P 0)v=P.byterate,this.Wg=!0;else{var e; l=(((e=navigator.connection)==null?void 0:e.downlink)||0)*64*1024;l>0&&(v=l,this.Wg=!0)}this.G.mG(this.policy.T,v);P.delay>0&&this.S.mG(1,Math.min(P.delay,2));P.stall>0&&this.j.mG(1,P.stall);P.init>0&&(this.Hg=Math.min(P.init,this.Hg));P.interruptions&&(this.Y=this.Y.concat(P.interruptions),this.Y.length>16&&this.Y.pop());this.QW=(0,g.Gz)();this.policy.j>0&&(this.Pg=new g.mr(this.Ic,this.policy.j,this),g.Z(this,this.Pg),this.Pg.start())}; Ny=function(P,v,l,e){P.G.mG(e===void 0?v:e,l/v);P.T=(0,g.Gz)()}; XPq=function(P){P.Z||(P.Z=(0,g.Gz)());P.policy.X&&(P.T=(0,g.Gz)())}; BZ2=function(P,v){if(P.Z){var l=v-P.Z;if(l<6E4){if(l>1E3){var e=P.interruptions;e.push(Math.ceil(l));e.sort(function(h,z){return z-h}); e.length>16&&e.pop()}P.T1+=l}}P.Z=v}; JW=function(P,v,l,e,h,z){z=z===void 0?!1:z;P.wM.mG(v,l/v);P.T=(0,g.Gz)();h||P.X.mG(1,v-e);z||(P.Z=0);P.QW>-1&&(0,g.Gz)()-P.QW>3E4&&iMD(P)}; uy=function(P,v,l){v=Math.max(v,P.K.W);P.j.mG(1,l/v)}; KP=function(P){P=P.S.y_()+P.kf.y_()||0;P=isNaN(P)?.5:P;return P=Math.min(P,5)}; ca=function(P,v,l){isNaN(l)||(P.J5+=l);isNaN(v)||(P.q5+=v)}; qy=function(P){P=P.G.y_();return P>0?P:1}; Fu=function(P,v,l){v=v===void 0?!1:v;l=l===void 0?1048576:l;var e=qy(P);e=1/((P.j.y_()||0)*P.policy.Wg+1/e);var h=P.wM.y_();h=h>0?h:1;var z=Math.max(e,h);P.policy.Z>0&&h =4E3}; ZMw=function(P){this.experiments=P;this.W=17;this.G=13E4;this.T=.5;this.K=!1;this.QW=this.V("html5_use_histogram_for_bandwidth");this.Y=!1;this.Z=g.ID(this.experiments,"html5_auxiliary_estimate_weight");this.Wg=g.ID(this.experiments,"html5_stall_factor")||1;this.j=g.ID(this.experiments,"html5_check_for_idle_network_interval_ms");this.S=this.experiments.l$("html5_trigger_loader_when_idle_network");this.X=this.experiments.l$("html5_sabr_fetch_on_idle_network_preloaded_players")}; aku=function(P,v){P=P===void 0?{}:P;v=v===void 0?{}:v;g.U.call(this);var l=this;this.values=P;this.rW=v;this.K={};this.G=this.W=0;this.Y=new g.mr(function(){jVB(l)},1E4); g.Z(this,this.Y)}; YQ=function(P,v){HMx(P,v);return P.values[v]&&P.rW[v]?P.values[v]/Math.pow(2,P.W/P.rW[v]):0}; HMx=function(P,v){P.values[v]||(v=cTa(),P.values=v.values||{},P.rW=v.halfLives||{},P.K=v.values?Object.assign({},v.values):{})}; jVB=function(P){var v=cTa();if(v.values){v=v.values;for(var l={},e=g.N(Object.keys(P.values)),h=e.next();!h.done;h=e.next())h=h.value,v[h]&&P.K[h]&&(P.values[h]+=v[h]-P.K[h]),l[h]=YQ(P,h);P.K=l}v=P.rW;l={};l.values=P.K;l.halfLives=v;g.jB("yt-player-memory",l,2592E3)}; ow=function(P,v,l,e,h){g.U.call(this);this.webPlayerContextConfig=v;this.N_=e;this.csiServiceName=this.csiPageType="";this.userAge=NaN;this.Zj=this.It=this.A5=this.MZ=this.userDisplayName=this.userDisplayImage=this.rH="";this.W={};this.Nd={};this.controlsType="0";this.MV=NaN;this.nI=!1;this.uM=(0,g.Gz)();this.CI=0;this.d4=this.cw=!1;this.Nq=!0;this.preferGapless=this.RK=this.jg=this.G=this.iY=this.Hl=!1;this.lE=[];this.vl=!1;P=P?g.GA(P):{};v&&v.csiPageType&&(this.csiPageType=v.csiPageType);v&&v.csiServiceName&& (this.csiServiceName=v.csiServiceName);v&&v.preferGapless&&(this.preferGapless=v.preferGapless);this.experiments=new Dkw(v?v.serializedExperimentIds:P.fexp,v?v.serializedExperimentFlags:P.fflags);this.forcedExperiments=v?v.serializedForcedExperimentIds:gD("",P.forced_experiments)||void 0;this.cspNonce=(v==null?0:v.cspNonce)?v.cspNonce:gD("",P.csp_nonce);this.V("web_player_deprecated_uvr_killswitch");try{var z=document.location.toString()}catch(r){z=""}this.XE=z;this.ancestorOrigins=(e=window.location.ancestorOrigins)? Array.from(e):[];this.Y=yK(!1,v?v.isEmbed:P.is_embed);if(v&&v.device){if(e=v.device,e.androidOsExperience&&(this.W.caoe=""+e.androidOsExperience),e.androidPlayServicesVersion&&(this.W.capsv=""+e.androidPlayServicesVersion),e.brand&&(this.W.cbrand=e.brand),e.browser&&(this.W.cbr=e.browser),e.browserVersion&&(this.W.cbrver=e.browserVersion),e.cobaltReleaseVehicle&&(this.W.ccrv=""+e.cobaltReleaseVehicle),this.W.c=e.interfaceName||"WEB",this.W.cver=e.interfaceVersion||"html5",e.interfaceTheme&&(this.W.ctheme= e.interfaceTheme),this.W.cplayer=e.interfacePlayerType||"UNIPLAYER",e.model&&(this.W.cmodel=e.model),e.network&&(this.W.cnetwork=e.network),e.os&&(this.W.cos=e.os),e.osVersion&&(this.W.cosver=e.osVersion),e.platform&&(this.W.cplatform=e.platform),z=eE(this.experiments,"html5_log_vss_extra_lr_cparams_freq"),z==="all"||z==="once")e.chipset&&(this.Nd.cchip=e.chipset),e.cobaltAppVersion&&(this.Nd.ccappver=e.cobaltAppVersion),e.firmwareVersion&&(this.Nd.cfrmver=e.firmwareVersion),e.deviceYear&&(this.Nd.crqyear= e.deviceYear)}else this.W.c=P.c||"web",this.W.cver=P.cver||"html5",this.W.cplayer="UNIPLAYER";this.loaderUrl=v?this.Y||EG7(this)&&v.loaderUrl?v.loaderUrl||"":this.XE:this.Y||EG7(this)&&P.loaderUrl?gD("",P.loaderUrl):this.XE;this.Y&&g.ZB("yt.embedded_player.embed_url",this.loaderUrl);this.j=eI(this.loaderUrl,WQB);e=this.loaderUrl;var m=m===void 0?!1:m;this.J8=lc(eI(e,OMw),e,m,"Trusted Ad Domain URL");this.zK=yK(!1,P.privembed);this.protocol=this.XE.indexOf("http:")===0?"http":"https";this.J5=hn((v? v.customBaseYoutubeUrl:P.BASE_YT_URL)||"")||hn(this.XE)||this.protocol+"://www.youtube.com/";m=v?v.eventLabel:P.el;e="detailpage";m==="adunit"?e=this.Y?"embedded":"detailpage":m==="embedded"||this.j?e=Ck(e,m,oGy):m&&(e="embedded");this.wM=e;Skx();m=null;e=v?v.playerStyle:P.ps;z=g.ro(sVw,e);!e||z&&!this.j||(m=e);this.playerStyle=m;this.T=g.ro(sVw,this.playerStyle);this.houseBrandUserStatus=v==null?void 0:v.houseBrandUserStatus;this.QW=this.T&&this.playerStyle!=="play"&&this.playerStyle!=="jamboard"; this.Gq=!this.QW;this.Pg=yK(!1,P.disableplaybackui);this.disablePaidContentOverlay=yK(!1,v==null?void 0:v.disablePaidContentOverlay);this.disableSeek=yK(!1,v==null?void 0:v.disableSeek);this.enableSpeedOptions=(v==null?void 0:v.enableSpeedOptions)||(SL().defaultPlaybackRate?by||g.mp||zF?g.Wj&&Sd("20")||g.Xs&&Sd("4")||g.xQ&&Sd("11")||lZ():!(g.xQ&&!g.Mc("chrome")||by||g.Mc("android")||g.Mc("silk")):!1);this.au=yK(!1,P.enable_faster_speeds);var Q;this.supportsVarispeedExtendedFeatures=(Q=v==null?void 0: v.supportsVarispeedExtendedFeatures)!=null?Q:!1;this.K=yK(this.playerStyle==="blazer",P.is_html5_mobile_device||v&&v.isMobileDevice);this.Ic=zT()||Ru();this.KO=this.V("mweb_allow_background_playback")?!1:this.K&&!this.T;this.q5=U6();this.NH=g.pP;var t;this.S6=!!(v==null?0:(t=v.embedsHostFlags)==null?0:t.optOutApiDeprecation);var y;this.Ep=!!(v==null?0:(y=v.embedsHostFlags)==null?0:y.allowPfpImaIntegration);this.qP=this.V("embeds_web_enable_ve_conversion_logging_tracking_no_allow_list");var C;v?v.hideInfo!== void 0&&(C=!v.hideInfo):C=P.showinfo;this.Dh=g.LP(this)&&!this.S6||yK(!SE(this)&&!GF(this)&&!this.T,C);this.UL=v?!!v.mobileIphoneSupportsInlinePlayback:yK(!1,P.playsinline);Q=this.K&&Xu&&Ba!=null&&Ba>0&&Ba<=2.3;t=v?v.useNativeControls:P.use_native_controls;this.S=g.LP(this)&&this.K;y=this.K&&!this.S;t=g.iy(this)||!Q&&yK(y,t)?"3":"1";this.disableOrganicUi=!(v==null||!v.disableOrganicUi);y=v?v.controlsType:P.controls;this.controlsType=this.disableOrganicUi?"0":y!=="0"&&y!==0?t:"0";this.lr=this.K;this.color= Ck("red",v?v.progressBarColor:P.color,rUD);this.mY=this.controlsType==="3";this.aV=!this.Y;this.Cg=(t=!this.aV&&!GF(this)&&!this.QW&&!this.T&&!SE(this))&&!this.mY&&this.controlsType==="1";this.SN=g.UM(this)&&t&&this.controlsType==="0"&&!this.Cg&&!(v==null?0:v.embedsEnableEmc3ds);this.BU=this.iR=Q;this.oV=(this.controlsType==="3"||this.K||yK(!1,P.use_media_volume))&&!this.S;this.dn=eB&&!g.I4(601)?!1:!0;this.Bw=this.Y||!1;this.D3=GF(this)?"":(this.loaderUrl||P.post_message_origin||"").substring(0,128); this.widgetReferrer=gD("",v?v.widgetReferrer:P.widget_referrer);var f;v?v.disableCastApi&&(f=!1):f=P.enablecastapi;f=!this.j||yK(!0,f);Q=!0;v&&v.disableMdxCast&&(Q=!1);this.jb=this.V("enable_cast_for_web_unplugged")&&g.ZY(this)&&Q||g.H$(this)&&Q||f&&Q&&this.controlsType==="1"&&!this.K&&(GF(this)||g.UM(this)||g.jE(this));this.Uq=!!window.document.pictureInPictureEnabled||ip();f=v?!!v.supportsAutoplayOverride:yK(!1,P.autoplayoverride);this.Xf=!(this.K&&!g.LP(this))&&!g.Mc("nintendo wiiu")||f;this.sR= (v?!!v.enableMutedAutoplay:yK(!1,P.mutedautoplay))&&!1;f=(GF(this)||SE(this))&&this.playerStyle==="blazer";this.q_=v?!!v.disableFullscreen:!yK(!0,P.fs);Q=g.Iu(g.aw(this))&&g.LP(this);this.jS=!this.q_&&(f||g.cx())&&!Q;f=T_()&&Sd(58)&&!Ru();Q=Ps||typeof MediaSource==="undefined";this.sZ=this.V("uniplayer_block_pip")&&(f||Q);f=g.LP(this)&&!this.S6;var k;v?v.disableRelatedVideos!==void 0&&(k=!v.disableRelatedVideos):k=P.rel;this.hs=f||yK(!this.T,k);this.l3=yK(!1,v?v.enableContentOwnerRelatedVideos:P.co_rel); this.X=Ru()&&Ba>0&&Ba<=4.4?"_top":"_blank";this.Ff=g.jE(this);this.eb=yK(this.playerStyle==="blazer",v?v.enableCsiLogging:P.enablecsi);switch(this.playerStyle){case "blogger":k="bl";break;case "gmail":k="gm";break;case "gac":k="ga";break;case "books":k="gb";break;case "docs":case "flix":k="gd";break;case "duo":k="gu";break;case "google-live":k="gl";break;case "google-one":k="go";break;case "play":k="gp";break;case "chat":k="hc";break;case "hangouts-meet":k="hm";break;case "photos-edu":case "picasaweb":k= "pw";break;default:k="yt"}this.Wg=k;this.T1=gD("",v?v.authorizedUserIndex:P.authuser);this.Xq=g.LP(this)&&(this.zK||!Njx()||this.Ic);var w;v?v.disableWatchLater!==void 0&&(w=!v.disableWatchLater):w=P.showwatchlater;this.bC=((k=!this.Xq)||!!this.T1&&k)&&yK(!this.QW,this.j?w:void 0);this.Ro=v?v.isMobileDevice||!!v.disableKeyboardControls:yK(!1,P.disablekb);this.loop=yK(!1,P.loop);this.pageId=gD("",v?v.initialDelegatedSessionId:P.pageid);this.So=yK(!0,P.canplaylive);this.U$=yK(!1,P.livemonitor);this.disableSharing= yK(this.T,v?v.disableSharing:P.ss);(w=v&&this.V("fill_video_container_size_override_from_wpcc")?v.videoContainerOverride:P.video_container_override)?(k=w.split("x"),k.length!==2?w=null:(w=Number(k[0]),k=Number(k[1]),w=isNaN(w)||isNaN(k)||w*k<=0?null:new g.Dc(w,k))):w=null;this.SI=w;this.mute=v?!!v.startMuted:yK(!1,P.mute);this.storeUserVolume=!this.mute&&yK(this.controlsType!=="0",v?v.storeUserVolume:P.store_user_volume);w=v?v.annotationsLoadPolicy:P.iv_load_policy;this.annotationsLoadPolicy=this.controlsType=== "3"?3:Ck(void 0,w,Ha);this.captionsLanguagePreference=v?v.captionsLanguagePreference||"":gD("",P.cc_lang_pref);w=Ck(2,v?v.captionsLanguageLoadPolicy:P.cc_load_policy,Ha);this.controlsType==="3"&&w===2&&(w=3);this.WK=w;this.TG=v?v.hl||"en_US":gD("en_US",P.hl);this.region=v?v.contentRegion||"US":gD("US",P.cr);this.hostLanguage=v?v.hostLanguage||"en":gD("en",P.host_language);this.Tg=!this.zK&&Math.random() =480;this.schedule=new nP(Q,new Ika(this.experiments),h);g.Z(this,this.schedule);var I;this.enableSafetyMode=(I=v==null?void 0:v.initialEnableSafetyMode)!=null? I:yK(!1,P.enable_safety_mode);h=this.Pg?!1:GF(this)&&this.playerStyle!=="blazer";var J;v?v.disableAutonav!=null&&(J=!v.disableAutonav):J=P.allow_autonav;this.GP=yK(h,!this.QW&&J);this.sendVisitorIdHeader=v?!!v.sendVisitorIdHeader:yK(!1,P.send_visitor_id_header);var K;this.playerStyle==="docs"&&(v?K=v.disableNativeContextMenu:K=P.disable_native_context_menu);this.disableNativeContextMenu=yK(!1,K);this.t4=xO(this)&&this.V("enable_skip_intro_button");this.embedConfig=gD("",v?v.serializedEmbedConfig: P.embed_config);this.kf=$d(P,g.LP(this));this.G=this.kf==="EMBEDDED_PLAYER_MODE_PFL";this.embedsErrorLinks=!(v==null||!v.embedsErrorLinks);this.IK=yK(!1,P.full_window);var q;this.Bg=!((q=this.webPlayerContextConfig)==null?0:q.chromeless);var A;this.livingRoomAppMode=Ck("LIVING_ROOM_APP_MODE_UNSPECIFIED",P.living_room_app_mode||(v==null?void 0:(A=v.device)==null?void 0:A.livingRoomAppMode),Vq6);var x;J=fk(NaN,v==null?void 0:(x=v.device)==null?void 0:x.deviceYear);isNaN(J)||(this.deviceYear=J);this.transparentBackground= v?!!v.transparentBackground:yK(!1,P.transparent_background);this.showMiniplayerButton=v?!!v.showMiniplayerButton:yK(!1,P.show_miniplayer_button);var S;g.LP(this)&&!(v==null?0:(S=v.embedsHostFlags)==null?0:S.allowSetFauxFullscreen)?this.externalFullscreen=!1:this.externalFullscreen=v?!!v.externalFullscreen:yK(!1,P.external_fullscreen);this.showMiniplayerUiWhenMinimized=v?!!v.showMiniplayerUiWhenMinimized:yK(!1,P.use_miniplayer_ui);var B;this.Nq=(B=P.show_loop_video_toggle)!=null?B:!0;this.HU=Math.random()< 1E-4;this.hN=P.onesie_hot_config||(v==null?0:v.onesieHotConfig)?new SC9(P.onesie_hot_config,v==null?void 0:v.onesieHotConfig):void 0;this.isTectonic=v?!!v.isTectonic:!!P.isTectonic;this.playerCanaryState=l;this.playerCanaryStage=v==null?void 0:v.canaryStage;this.t3=new aku;g.Z(this,this.t3);this.iY=yK(!1,P.force_gvi);this.datasyncId=(v==null?void 0:v.datasyncId)||g.la("DATASYNC_ID");this.A1=g.la("LOGGED_IN",!1);this.Yy=(v==null?void 0:v.allowWoffleManagement)||!1;this.RO=Infinity;this.ir=NaN;this.livingRoomPoTokenId= v==null?void 0:v.livingRoomPoTokenId;this.V("html5_high_res_logging_always")?this.jg=!0:this.jg=Math.random()*100 =0&&P 0&&P.HU&&(e.sort(),g.j4(new g.Ph("Player client parameters changed after startup",e)));P.userAge=fk(P.userAge,v.user_age);P.rH=gD(P.rH,v.user_display_email);P.userDisplayImage=gD(P.userDisplayImage,v.user_display_image);g.m8(P.userDisplayImage)||(P.userDisplayImage= "");P.userDisplayName=gD(P.userDisplayName,v.user_display_name);P.MZ=gD(P.MZ,v.user_gender);P.csiPageType=gD(P.csiPageType,v.csi_page_type);P.csiServiceName=gD(P.csiServiceName,v.csi_service_name);P.eb=yK(P.eb,v.enablecsi);P.pageId=gD(P.pageId,v.pageid);if(l=v.enabled_engage_types)P.enabledEngageTypes=new Set(l.split(","));v.living_room_session_po_token&&(P.FL=v.living_room_session_po_token.toString())}; sM=function(P,v){return!P.T&&T_()&&Sd(55)&&P.controlsType==="3"&&!v}; g.r7=function(P){P=EM(P.J5);return P==="www.youtube-nocookie.com"?"www.youtube.com":P}; My=function(P,v,l){return P.protocol+"://i1.ytimg.com/vi/"+v+"/"+(l||"hqdefault.jpg")}; TF=function(P){return GF(P)&&!g.ZY(P)}; g.iy=function(P){return P.V("html5_local_playsinline")?eB&&!g.I4(602)&&!("playsInline"in SL()):eB&&!P.UL||g.Mc("nintendo wiiu")?!0:!1}; va=function(P){return P.W.c}; g.pF=function(P){return/^TVHTML5/.test(va(P))}; g.VP=function(P){return va(P)==="TVHTML5"}; EG7=function(P){return va(P)==="TVHTML5_SIMPLY_EMBEDDED_PLAYER"}; TZw=function(P){return P.W.cmodel==="CHROMECAST ULTRA/STEAK"||P.W.cmodel==="CHROMECAST/STEAK"}; g.d7=function(){return window.devicePixelRatio>1?window.devicePixelRatio:1}; xO=function(P){return/web/i.test(va(P))}; g.Po=function(P){return va(P).toUpperCase()==="WEB"}; OM=function(P){return va(P)==="WEB_KIDS"}; g.ZY=function(P){return va(P)==="WEB_UNPLUGGED"}; vo=function(P){return va(P)==="TVHTML5_UNPLUGGED"}; g.bq=function(P){return g.ZY(P)||va(P)==="TV_UNPLUGGED_CAST"||vo(P)}; g.H$=function(P){return va(P)==="WEB_REMIX"}; g.lN=function(P){return va(P)==="WEB_EMBEDDED_PLAYER"}; g.h0=function(P){return(P.deviceIsAudioOnly||!g.Xs||Ps||P.controlsType==="3"?!1:g.mp?P.Y&&g.I4(51):!0)||(P.deviceIsAudioOnly||!g.Wj||Ps||P.controlsType==="3"?!1:g.mp?P.Y&&g.I4(48):g.I4(38))||(P.deviceIsAudioOnly||!g.xQ||Ps||P.controlsType==="3"?!1:g.mp?P.Y&&g.I4(37):g.I4(27))||!P.deviceIsAudioOnly&&g.e0&&!qSy()&&g.I4(11)||!P.deviceIsAudioOnly&&g.FA&&g.I4("604.4")}; vWB=function(P){if(g.UM(P)&&Xu)return!1;if(g.Wj){if(!g.I4(47)||!g.I4(52)&&g.I4(51))return!1}else if(g.FA)return!1;return window.AudioContext||window.webkitAudioContext?!0:!1}; eK6=function(P,v){return P.enabledEngageTypes.has(v.toString())||ltW.includes(v)}; GF=function(P){return P.wM==="detailpage"}; g.UM=function(P){return P.wM==="embedded"}; zk=function(P){return P.wM==="leanback"}; SE=function(P){return P.wM==="adunit"||P.playerStyle==="gvn"}; g.jE=function(P){return P.wM==="profilepage"}; g.LP=function(P){return P.Y&&g.UM(P)&&!SE(P)&&!P.T}; ml=function(P){if(!P.userDisplayImage)return"";var v=P.userDisplayImage.split("/");if(v.length===5)return P=v[v.length-1].split("="),P[1]="s20-c",v[v.length-1]=P.join("="),v.join("/");if(v.length===8)return v.splice(7,0,"s20-c"),v.join("/");if(v.length===9)return v[7]+="-s20-c",v.join("/");g.j4(new g.Ph("Profile image not a FIFE URL.",P.userDisplayImage));return P.userDisplayImage}; g.RI=function(P){var v=g.r7(P);hKu.includes(v)&&(v="www.youtube.com");return P.protocol+"://"+v}; g.QW=function(P,v){v=v===void 0?"":v;if(P.N_){var l=new PP,e,h=P.N_();h.signedOut?e="":h.token?e=h.token:h.pendingResult.then(function(z){h.signedOut?l.resolve(""):l.resolve(z.token)},function(z){g.j4(new g.Ph("b189348328_oauth_callback_failed",{error:z})); l.resolve(v)}); return e!==void 0?jN(e):new Uk(l)}return jN(v)}; EM=function(P){var v=g.Hl(P);return(P=Number(g.ap(4,P))||null)?v+":"+P:v}; t0=function(P,v){v=v===void 0?!1:v;var l=oS[P],e=zKW[l],h=miB[P];if(!h||!e)return null;v=new E6(v?h.height:h.width,v?h.width:h.height,h.fps);e=$T(e,v,l);return new s6(P,e,{video:v,FJ:h.bitrate/8})}; Q2q=function(P){var v=zKW[oS[P]],l=RKy[P];return l&&v?new s6(P,v,{audio:new jL(l.audioSampleRate,l.numChannels)}):null}; yW=function(P){this.W=P}; C_=function(P,v,l,e){if(l)return Zp();l={};var h=SL();v=g.N(v);for(var z=v.next();!z.done;z=v.next())if(z=z.value,P.canPlayType(h,z.getInfo().mimeType)||e){var m=z.W.video.quality;if(!l[m]||l[m].getInfo().C6())l[m]=z}P=[];l.auto&&P.push(l.auto);e=g.N(Wz);for(h=e.next();!h.done;h=e.next())(h=l[h.value])&&P.push(h);return P.length?jN(P):Zp()}; t5P=function(P){this.itag=P.itag;this.url=P.url;this.codecs=P.codecs;this.width=P.width;this.height=P.height;this.fps=P.fps;this.bitrate=P.bitrate;var v;this.K=((v=P.audioItag)==null?void 0:v.split(","))||[];this.vy=P.vy;this.EQ=P.EQ||"";this.Rt=P.Rt;this.audioChannels=P.audioChannels;this.W=""}; yX6=function(P,v,l,e){v=v===void 0?!1:v;l=l===void 0?!0:l;e=e===void 0?{}:e;var h={};P=g.N(P);for(var z=P.next();!z.done;z=P.next()){z=z.value;if(v&&MediaSource&&MediaSource.isTypeSupported){var m=z.type;z.audio_channels&&(m=m+"; channels="+z.audio_channels);if(!MediaSource.isTypeSupported(m)){e[z.itag]="tpus";continue}}if(l||!z.drm_families||z.eotf!=="smpte2084"&&z.eotf!=="arib-std-b67"){m=void 0;var Q={bt709:"SDR",bt2020:"SDR",smpte2084:"PQ","arib-std-b67":"HLG"},t=z.type.match(/codecs="([^"]*)"/); t=t?t[1]:"";z.audio_track_id&&(m=new g.y5(z.name,z.audio_track_id,!!z.is_default));var y=z.eotf;z=new t5P({itag:z.itag,url:z.url,codecs:t,width:Number(z.width),height:Number(z.height),fps:Number(z.fps),bitrate:Number(z.bitrate),audioItag:z.audio_itag,vy:y?Q[y]:void 0,EQ:z.drm_families,Rt:m,audioChannels:Number(z.audio_channels)});h[z.itag]=h[z.itag]||[];h[z.itag].push(z)}else e[z.itag]="enchdr"}return h}; Czw=function(P,v,l,e,h){this.G=P;this.K=v;this.Z=l;this.cpn=e;this.T=h;this.Y=0;this.W=""}; ftw=function(P,v){P.G.some(function(l){var e;return((e=l.Rt)==null?void 0:e.getId())===v}); P.W=v}; f_=function(P,v,l){P.cpn&&(v=g.r5(v,{cpn:P.cpn}));l&&(v=g.r5(v,{paired:l}));return v}; gWx=function(P,v){P=P.itag.toString();v!==null&&(P+=v.itag.toString());return P}; k$W=function(P){for(var v=[],l=[],e=g.N(P.K),h=e.next();!h.done;h=e.next())h=h.value,h.bitrate<=P.Y?v.push(h):l.push(h);v.sort(function(z,m){return m.bitrate-z.bitrate}); l.sort(function(z,m){return z.bitrate-m.bitrate}); P.K=v.concat(l)}; gh=function(P,v,l){this.W=P;this.K=v;this.expiration=l;this.JR=null}; wE6=function(P,v){if(!(Ps||vx()||d$()))return null;P=yX6(v,P.V("html5_filter_fmp4_in_hls"));if(!P)return null;v=[];for(var l={},e=g.N(Object.keys(P)),h=e.next();!h.done;h=e.next()){h=g.N(P[h.value]);for(var z=h.next();!z.done;z=h.next()){var m=z.value;m.Rt&&(z=m.Rt.getId(),l[z]||(m=new g.zc(z,m.Rt),l[z]=m,v.push(m)))}}return v.length>0?v:null}; NU9=function(P,v,l,e,h,z,m){if(!(Ps||vx()||d$()))return Zp();var Q={},t=$iD(l),y=yX6(l,P.V("html5_filter_fmp4_in_hls"),P.Z.T,Q);if(!y)return m({noplst:1}),Zp();ItP(y);l={};var C=(l.fairplay="https://youtube.com/api/drm/fps?ek=uninitialized",l),f;l=[];var k=[],w=[],I=null,J="";e=e&&e.match(/hls_timedtext_playlist/)?new t5P({itag:"0",url:e,codecs:"vtt",width:0,height:0,fps:0,bitrate:0,Rt:new g.y5("English","en",!1)}):null;for(var K=g.N(Object.keys(y)),q=K.next();!q.done;q=K.next())if(q=q.value,!P.V("html5_disable_drm_hfr_1080")|| q!=="383"&&q!=="373"){q=g.N(y[q]);for(var A=q.next();!A.done;A=q.next())if(A=A.value,A.width){for(var x=g.N(A.K),S=x.next();!S.done;S=x.next())if(S=S.value,y[S]){A.W=S;break}A.W||(A.W=DiD(y,A));if(x=y[A.W])if(l.push(A),A.EQ==="fairplay"&&(f=C),S="",A.vy==="PQ"?S="smpte2084":A.vy==="HLG"&&(S="arib-std-b67"),S&&(J=S),w.push(nWa(x,[A],e,z,A.itag,A.width,A.height,A.fps,t,void 0,void 0,f,S)),!I||A.width*A.height*A.fps>I.width*I.height*I.fps)I=A}else k.push(A)}else Q[q]="disdrmhfr";w.reduce(function(B, E){return E.getInfo().isEncrypted()&&B},!0)&&(f=C); h=Math.max(h,0);C=I||{};y=C.fps===void 0?0:C.fps;I=C.width===void 0?0:C.width;C=C.height===void 0?0:C.height;K=P.V("html5_native_audio_track_switching");w.push(nWa(k,l,e,z,"93",I,C,y,t,"auto",h,f,J,K));Object.entries(Q).length&&m(Q);return C_(P.Z,w,sM(P,v),!1)}; nWa=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w){for(var I=0,J="",K=g.N(P),q=K.next();!q.done;q=K.next())q=q.value,J||(J=q.itag),q.audioChannels&&q.audioChannels>I&&(I=q.audioChannels,J=q.itag);h=new s6(h,"application/x-mpegURL",{audio:new jL(0,I),video:new E6(z,m,Q,null,void 0,y,void 0,k),EQ:f,Ra:J});P=new Czw(P,v,l?[l]:[],e,!!w);P.Y=C?C:1369843;return new gh(h,P,t)}; $iD=function(P){P=g.N(P);for(var v=P.next();!v.done;v=P.next())if(v=v.value,v.url&&(v=v.url.split("expire/"),!(v.length<=1)))return+v[1].split("/")[0];return NaN}; DiD=function(P,v){for(var l=g.N(Object.keys(P)),e=l.next();!e.done;e=l.next()){e=e.value;var h=P[e][0];if(!h.width&&h.EQ===v.EQ&&!h.audioChannels)return e}return""}; ItP=function(P){for(var v=new Set,l=g.N(Object.values(P)),e=l.next();!e.done;e=l.next())e=e.value,e.length&&(e=e[0],e.height&&e.codecs.startsWith("vp09")&&v.add(e.height));l=[];if(v.size){e=g.N(Object.keys(P));for(var h=e.next();!h.done;h=e.next())if(h=h.value,P[h].length){var z=P[h][0];z.height&&v.has(z.height)&&!z.codecs.startsWith("vp09")&&l.push(h)}}v=g.N(l);for(l=v.next();!l.done;l=v.next())delete P[l.value]}; kH=function(P,v){this.W=P;this.K=v}; JXD=function(P,v,l,e){var h=[];l=g.N(l);for(var z=l.next();!z.done;z=l.next()){var m=z.value;if(m.url){z=new g.q9(m.url,!0);if(m.s){var Q=z,t=m.sp,y=nO6(decodeURIComponent(m.s));Q.set(t,encodeURIComponent(y))}Q=g.N(Object.keys(e));for(t=Q.next();!t.done;t=Q.next())t=t.value,z.set(t,e[t]);m=mz(m.type,m.quality,m.itag,m.width,m.height);h.push(new kH(m,z))}}return C_(P.Z,h,sM(P,v),!1)}; wh=function(P,v){this.W=P;this.K=v}; ug6=function(P,v,l){var e=[];l=g.N(l);for(var h=l.next();!h.done;h=l.next())if((h=h.value)&&h.url){var z=mz(h.type,"medium","0");e.push(new wh(z,h.url))}return C_(P.Z,e,sM(P,v),!1)}; K0u=function(P,v){var l=[],e=mz(v.type,"auto",v.itag);l.push(new wh(e,v.url));return C_(P.Z,l,!1,!0)}; qwx=function(P){return P&&cX7[P]?cX7[P]:null}; F06=function(P){if(P=P.commonConfig)this.url=P.url,this.urlQueryOverride=P.urlQueryOverride,P.ustreamerConfig&&(this.YB=fP(P.ustreamerConfig)||void 0)}; AXD=function(P,v){var l;if(v=v==null?void 0:(l=v.watchEndpointSupportedOnesieConfig)==null?void 0:l.html5PlaybackOnesieConfig)P.ME=new F06(v)}; g.$H=function(P){P=P===void 0?{}:P;this.languageCode=P.languageCode||"";this.languageName=P.languageName||null;this.kind=P.kind||"";this.name=P.name===void 0?null:P.name;this.displayName=P.displayName||null;this.id=P.id||null;this.W=P.is_servable||!1;this.isTranslateable=P.is_translateable||!1;this.url=P.url||null;this.vssId=P.vss_id||"";this.isDefault=P.is_default||!1;this.translationLanguage=P.translationLanguage||null;this.xtags=P.xtags||"";this.captionId=P.captionId||""}; g.Dv=function(P){var v={languageCode:P.languageCode,languageName:P.languageName,displayName:g.II(P),kind:P.kind,name:P.name,id:P.id,is_servable:P.W,is_default:P.isDefault,is_translateable:P.isTranslateable,vss_id:P.vssId};P.xtags&&(v.xtags=P.xtags);P.captionId&&(v.captionId=P.captionId);P.translationLanguage&&(v.translationLanguage=P.translationLanguage);return v}; g.n_=function(P){return P.translationLanguage?P.translationLanguage.languageCode:P.languageCode}; g.YwP=function(P){var v=P.vssId;P.translationLanguage&&v&&(v="t"+v+"."+g.n_(P));return v}; g.II=function(P){var v=[];if(P.displayName)v.push(P.displayName);else{var l=P.languageName||"";v.push(l);P.kind==="asr"&&l.indexOf("(")===-1&&v.push(" (Subt\u00edtulos autom\u00e1ticos)");P.name&&v.push(" - "+P.name)}P.translationLanguage&&v.push(" >> "+P.translationLanguage.languageName);return v.join("")}; L0q=function(P,v,l,e){P||(P=v&&blw.hasOwnProperty(v)&&xi6.hasOwnProperty(v)?xi6[v]+"_"+blw[v]:void 0);v=P;if(!v)return null;P=v.match(pE7);if(!P||P.length!==5)return null;if(P=v.match(pE7)){var h=Number(P[3]),z=[7,8,10,5,6];P=!(Number(P[1])===1&&h===8)&&z.indexOf(h)>=0}else P=!1;return l||e||P?v:null}; N3=function(P,v){for(var l={},e=g.N(Object.keys(Sw2)),h=e.next();!h.done;h=e.next()){h=h.value;var z=v?v+h:h;z=P[z+"_webp"]||P[z];g.m8(z)&&(l[Sw2[h]]=z)}return l}; J0=function(P){var v={};if(!P||!P.thumbnails)return v;P=P.thumbnails.filter(function(Q){return!!Q.url}); P.sort(function(Q,t){return Q.width-t.width||Q.height-t.height}); for(var l=g.N(Object.keys(G$w)),e=l.next();!e.done;e=l.next()){var h=Number(e.value);e=G$w[h];for(var z=g.N(P),m=z.next();!m.done;m=z.next())if(m=m.value,m.width>=h){h=XEW(m.url);g.m8(h)&&(v[e]=h);break}}(P=P.pop())&&P.width>=1280&&(P=XEW(P.url),g.m8(P)&&(v["maxresdefault.jpg"]=P));return v}; XEW=function(P){return P.startsWith("//")?"https:"+P:P}; uN=function(P){return P&&P.baseUrl||""}; K_=function(P){P=g.fG(P);for(var v=g.N(Object.keys(P)),l=v.next();!l.done;l=v.next()){l=l.value;var e=P[l];P[l]=Array.isArray(e)?e[0]:e}return P}; BUu=function(P,v){P.botguardData=v.playerAttestationRenderer.botguardData;v=v.playerAttestationRenderer.challenge;v!=null&&(P.Q8=v)}; Zlq=function(P,v){v=g.N(v);for(var l=v.next();!l.done;l=v.next()){l=l.value;var e=l.interstitials.map(function(m){var Q=g.a(m,ilq);if(Q)return{is_yto_interstitial:!0,raw_player_response:Q};if(m=g.a(m,Uiy))return Object.assign({is_yto_interstitial:!0},yS(m))}); e=g.N(e);for(var h=e.next();!h.done;h=e.next())switch(h=h.value,l.podConfig.playbackPlacement){case "INTERSTITIAL_PLAYBACK_PLACEMENT_PRE":P.interstitials=P.interstitials.concat({time:0,playerVars:h,Ki:5});break;case "INTERSTITIAL_PLAYBACK_PLACEMENT_POST":P.interstitials=P.interstitials.concat({time:0x7ffffffffffff,playerVars:h,Ki:6});break;case "INTERSTITIAL_PLAYBACK_PLACEMENT_INSERT_AT_VIDEO_TIME":var z=Number(l.podConfig.timeToInsertAtMillis);P.interstitials=P.interstitials.concat({time:z,playerVars:h, Ki:z===0?5:7})}}}; j2w=function(P,v){if(v=v.find(function(l){return!(!l||!l.tooltipRenderer)}))P.tooltipRenderer=v.tooltipRenderer}; atx=function(P,v){v.subscribeCommand&&(P.subscribeCommand=v.subscribeCommand);v.unsubscribeCommand&&(P.unsubscribeCommand=v.unsubscribeCommand);v.addToWatchLaterCommand&&(P.addToWatchLaterCommand=v.addToWatchLaterCommand);v.removeFromWatchLaterCommand&&(P.removeFromWatchLaterCommand=v.removeFromWatchLaterCommand);v.getSharePanelCommand&&(P.getSharePanelCommand=v.getSharePanelCommand)}; Hl7=function(P,v){v!=null?(P.Iu=v,P.eg=!0):(P.Iu="",P.eg=!1)}; co=function(P,v){this.type=P||"";this.id=v||""}; g.q3=function(P){return new co(P.substring(0,2),P.substring(2))}; g.FX=function(P,v){this.Z3=P;this.author="";this.DS=null;this.playlistLength=0;this.W=this.sessionData=null;this.X={};this.title="";if(v){this.author=v.author||v.playlist_author||"";this.title=v.playlist_title||"";if(P=v.session_data)this.sessionData=QS(P,"&");var l;this.W=((l=v.thumbnail_ids)==null?void 0:l.split(",")[0])||null;this.X=N3(v,"playlist_");this.videoId=v.video_id||void 0;if(l=v.list)switch(v.listType){case "user_uploads":this.playlistId=(new co("UU","PLAYER_"+l)).toString();break;default:if(P= v.playlist_length)this.playlistLength=Number(P)||0;this.playlistId=g.q3(l).toString();if(v=v.video)this.videoId=(v[0]||null).video_id||void 0}else v.playlist&&(this.playlistLength=v.playlist.toString().split(",").length)}}; g.A0=function(P,v){this.Z3=P;this.fl=this.author="";this.DS=null;this.isUpcoming=this.isLivePlayback=!1;this.lengthSeconds=0;this.z$=this.lengthText="";this.sessionData=null;this.X={};this.title="";if(v){this.ariaLabel=v.aria_label||void 0;this.author=v.author||"";this.fl=v.fl||"";if(P=v.endscreen_autoplay_session_data)this.DS=QS(P,"&");this.CZ=v.CZ;this.isLivePlayback=v.live_playback==="1";this.isUpcoming=!!v.isUpcoming;if(P=v.length_seconds)this.lengthSeconds=typeof P==="string"?Number(P):P;this.lengthText= v.lengthText||"";this.z$=v.z$||"";this.publishedTimeText=v.publishedTimeText||void 0;if(P=v.session_data)this.sessionData=QS(P,"&");this.shortViewCount=v.short_view_count_text||void 0;this.X=N3(v);this.title=v.title||"";this.videoId=v.docid||v.video_id||v.videoId||v.id||void 0;this.watchUrl=v.watchUrl||void 0}}; EWw=function(P){var v,l,e=(v=P.getWatchNextResponse())==null?void 0:(l=v.contents)==null?void 0:l.twoColumnWatchNextResults,h,z,m,Q,t;P=(h=P.getWatchNextResponse())==null?void 0:(z=h.playerOverlays)==null?void 0:(m=z.playerOverlayRenderer)==null?void 0:(Q=m.endScreen)==null?void 0:(t=Q.watchNextEndScreenRenderer)==null?void 0:t.results;if(!P){var y,C;P=e==null?void 0:(y=e.endScreen)==null?void 0:(C=y.endScreen)==null?void 0:C.results}return P}; g.bN=function(P){var v,l,e;P=g.a((v=P.getWatchNextResponse())==null?void 0:(l=v.playerOverlays)==null?void 0:(e=l.playerOverlayRenderer)==null?void 0:e.decoratedPlayerBarRenderer,YH);return g.a(P==null?void 0:P.playerBar,W0B)}; Ol6=function(P){this.W=P.playback_progress_0s_url;this.G=P.playback_progress_2s_url;this.K=P.playback_progress_10s_url}; oWa=function(){if(xH===void 0){try{window.localStorage.removeItem("yt-player-lv")}catch(v){}a:{try{var P=!!self.localStorage}catch(v){P=!1}if(P&&(P=g.W7(g.vh()+"::yt-player"))){xH=new OI(P);break a}xH=void 0}}return xH}; g.p_=function(){var P=oWa();if(!P)return{};try{var v=P.get("yt-player-lv");return JSON.parse(v||"{}")}catch(l){return{}}}; g.s2y=function(P){var v=oWa();v&&(P=JSON.stringify(P),v.set("yt-player-lv",P))}; g.L_=function(P){return g.p_()[P]||0}; g.S0=function(P,v){var l=g.p_();v!==l[P]&&(v!==0?l[P]=v:delete l[P],g.s2y(l))}; g.Gk=function(P){return g.p(function(v){return v.return(g.Tz(rX7(),P))})}; Bo=function(P,v,l,e,h,z,m,Q){var t,y,C,f,k,w;return g.p(function(I){switch(I.W){case 1:return t=g.L_(P),t===4?I.return(4):g.b(I,g.zJ(),2);case 2:y=I.K;if(!y)throw g.Y6("wiac");if(!Q||m===void 0){I.ac(3);break}return g.b(I,M5P(Q,m),4);case 4:m=I.K;case 3:return C=l.lastModified||"0",g.b(I,g.Gk(y),5);case 5:return f=I.K,g.NP(I,6),XX++,g.b(I,g.UP(f,["index","media"],{mode:"readwrite",tag:"IDB_TRANSACTION_TAG_WIAC",V7:!0},function(J){if(z!==void 0&&m!==void 0){var K=""+P+"|"+v.id+"|"+C+"|"+String(z).padStart(10, "0");K=g.Z0(J.objectStore("media"),m,K)}else K=g.x6.resolve(void 0);var q=TU9(P,v.zQ()),A=TU9(P,!v.zQ()),x={fmts:V52(e),format:l||{}};q=g.Z0(J.objectStore("index"),x,q);var S=e.downloadedEndTime===-1;x=S?J.objectStore("index").get(A):g.x6.resolve(void 0);var B={fmts:"music",format:{}};J=S&&h&&!v.zQ()?g.Z0(J.objectStore("index"),B,A):g.x6.resolve(void 0);return g.x6.all([J,x,K,q]).then(function(E){E=g.N(E);E.next();E=E.next().value;XX--;var r=g.L_(P);if(r!==4&&S&&h||E!==void 0&&g.di9(E.fmts))r=1,g.S0(P, r);return r})}),8); case 8:return I.return(I.K);case 6:k=g.Kx(I);XX--;w=g.L_(P);if(w===4)return I.return(w);g.S0(P,4);throw k;}})}; g.PJ6=function(P){var v,l;return g.p(function(e){if(e.W==1)return g.b(e,g.zJ(),2);if(e.W!=3){v=e.K;if(!v)throw g.Y6("ri");return g.b(e,g.Gk(v),3)}l=e.K;return e.return(g.UP(l,["index"],{mode:"readonly",tag:"IDB_TRANSACTION_TAG_LMRI"},function(h){var z=IDBKeyRange.bound(P+"|",P+"~");return h.objectStore("index").getAll(z).then(function(m){return m.map(function(Q){return Q?Q.format:{}})})}))})}; lZq=function(P,v,l,e,h){var z,m,Q;return g.p(function(t){if(t.W==1)return g.b(t,g.zJ(),2);if(t.W!=3){z=t.K;if(!z)throw g.Y6("rc");return g.b(t,g.Gk(z),3)}m=t.K;Q=g.UP(m,["media"],{mode:"readonly",tag:"IDB_TRANSACTION_TAG_LMRM"},function(y){var C=""+P+"|"+v+"|"+l+"|"+String(e).padStart(10,"0");return y.objectStore("media").get(C)}); return h?t.return(Q.then(function(y){if(y===void 0)throw Error("No data from indexDb");return vjy(h,y)}).catch(function(y){throw new g.Ph("Error while reading chunk: "+y.name+", "+y.message); })):t.return(Q)})}; g.di9=function(P){return P?P==="music"?!0:P.includes("dlt=-1")||!P.includes("dlt="):!1}; TU9=function(P,v){return""+P+"|"+(v?"v":"a")}; V52=function(P){var v={};return tZ((v.dlt=P.downloadedEndTime.toString(),v.mket=P.maxKnownEndTime.toString(),v.avbr=P.averageByteRate.toString(),v))}; hAP=function(P){var v={},l={};P=g.N(P);for(var e=P.next();!e.done;e=P.next()){var h=e.value,z=h.split("|");h.match(g.eAw)?(e=Number(z.pop()),isNaN(e)?l[h]="?":(z=z.join("|"),(h=v[z])?(z=h[h.length-1],e===z.end+1?z.end=e:h.push({start:e,end:e})):v[z]=[{start:e,end:e}])):l[h]="?"}P=g.N(Object.keys(v));for(e=P.next();!e.done;e=P.next())e=e.value,l[e]=v[e].map(function(m){return m.start+"-"+m.end}).join(","); return l}; iN=function(P){g.gA.call(this);this.W=null;this.G=new s7;this.W=null;this.T=new Set;this.crossOrigin=P||""}; zAa=function(P,v,l){for(l=Uv(P,l);l>=0;){var e=P.levels[l];if(e.isLoaded(Zv(e,v))&&(e=g.j0(e,v)))return e;l--}return g.j0(P.levels[0],v)}; RAD=function(P,v,l){l=Uv(P,l);for(var e,h;l>=0;l--)if(e=P.levels[l],h=Zv(e,v),!e.isLoaded(h)){e=P;var z=l,m=z+"-"+h;e.T.has(m)||(e.T.add(m),e.G.enqueue(z,{LA:z,lN:h}))}mfD(P)}; mfD=function(P){if(!P.W&&!P.G.isEmpty()){var v=P.G.remove();P.W=QLq(P,v)}}; QLq=function(P,v){var l=document.createElement("img");P.crossOrigin&&(l.crossOrigin=P.crossOrigin);l.src=P.levels[v.LA].sQ(v.lN);l.onload=function(){var e=v.LA,h=v.lN;P.W!==null&&(P.W.onload=null,P.W=null);e=P.levels[e];e.loaded.add(h);mfD(P);var z=e.columns*e.rows;h*=z;e=Math.min(h+z-1,e.Wr()-1);h=[h,e];P.publish("l",h[0],h[1])}; return l}; g.aI=function(P,v,l,e){this.level=P;this.Y=v;this.loaded=new Set;this.level=P;this.Y=v;P=l.split("#");this.width=Math.floor(Number(P[0]));this.height=Math.floor(Number(P[1]));this.frameCount=Math.floor(Number(P[2]));this.columns=Math.floor(Number(P[3]));this.rows=Math.floor(Number(P[4]));this.W=Math.floor(Number(P[5]));this.G=P[6];this.signature=P[7];this.videoLength=e}; Zv=function(P,v){return Math.floor(v/(P.columns*P.rows))}; g.j0=function(P,v){v>=P.RP()&&P.Yc();var l=Zv(P,v),e=P.columns*P.rows,h=v%e;v=h%P.columns;h=Math.floor(h/P.columns);var z=P.Yc()+1-e*l;if(z 1&&this.levels[0].isDefault()&&this.levels.splice(0,1)}; t67=function(P,v,l){return(P=P.levels[v])?P.P0(l):-1}; Uv=function(P,v){var l=P.Y.get(v);if(l)return l;l=P.levels.length;for(var e=0;e =v)return P.Y.set(v,e),e;P.Y.set(v,l-1);return l-1}; Ev=function(P,v,l,e){l=l.split("#");l=[l[1],l[2],0,l[3],l[4],-1,l[0],""].join("#");g.aI.call(this,P,v,l,0);this.K=null;this.Z=e?2:0}; Wo=function(P,v,l,e){Ho.call(this,P,0,void 0,v,!(e===void 0||!e));for(P=0;P (l!=null?l:50)&&(l=DfD.shift())&&dh.delete(l),l=h),h!==l&&P.Ph("ssei","dcpn_"+h+"_"+l+"_"+P.clientPlaybackNonce),l)}; M3=function(P,v){var l=v.raw_watch_next_response;if(!l){var e=v.watch_next_response;e&&(l=JSON.parse(e))}if(l){P.Pg=l;var h=P.Pg.playerCueRangeSet;h&&g.Pd(P,h);var z=P.Pg.playerOverlays;if(z){var m=z.playerOverlayRenderer;if(m){var Q=m.autonavToggle;Q&&(P.autoplaySwitchButtonRenderer=g.a(Q,njB),P.V("web_player_autonav_use_server_provided_state")&&vd(P)&&(P.autonavState=P.autoplaySwitchButtonRenderer.enabled?2:1));var t=m.videoDetails;if(t){var y=t.embeddedPlayerOverlayVideoDetailsRenderer;var C=t.playerOverlayVideoDetailsRenderer; C&&(C.title&&(v.title=g.Jz(C.title)),C.subtitle&&(v.subtitle=g.Jz(C.subtitle)))}g.UM(P.Z3)&&(P.bC=!!m.addToMenu);NkD(P,m.shareButton);m.startPosition&&m.endPosition&&(P.progressBarStartPosition=m.startPosition,P.progressBarEndPosition=m.endPosition);var f=m.gatedActionsOverlayRenderer;f&&(P.Dy=g.a(f,JAy));var k,w,I,J=g.a((k=P.getWatchNextResponse())==null?void 0:(w=k.playerOverlays)==null?void 0:(I=w.playerOverlayRenderer)==null?void 0:I.infoPanel,uEy);if(J){P.jB=Number(J==null?void 0:J.durationMs)|| NaN;if(J==null?0:J.infoPanelOverviewViewModel)P.jg=J==null?void 0:J.infoPanelOverviewViewModel;if(J==null?0:J.infoPanelDetailsViewModel)P.ir=J==null?void 0:J.infoPanelDetailsViewModel}P.showSeekingControls=!!m.showSeekingControls}}var K,q,A=(K=P.getWatchNextResponse())==null?void 0:(q=K.contents)==null?void 0:q.twoColumnWatchNextResults;if(A){var x=A.desktopOverlay&&g.a(A.desktopOverlay,Kf6);x&&(x.suppressShareButton&&(P.showShareButton=!1),x.suppressWatchLaterButton&&(P.bC=!1))}y&&cA9(P,v,y);var S= fk(0,v.autoplay_count),B=P.getWatchNextResponse(),E,r=(E=B.contents)==null?void 0:E.twoColumnWatchNextResults,hq,R7,Pw,H=(hq=B.playerOverlays)==null?void 0:(R7=hq.playerOverlayRenderer)==null?void 0:(Pw=R7.autoplay)==null?void 0:Pw.playerOverlayAutoplayRenderer,T=EWw(P),n,W=(n=B.contents)==null?void 0:n.singleColumnWatchNextResults;if(W){var du;if(((du=W.autoplay)==null?0:du.autoplay)&&!W.playlist){var K1=W.autoplay.autoplay.sets,f1={},Aq=new g.A0(P.N()),MP=null,lY;if(K1){for(var $3=g.N(K1),c=$3.next();!c.done;c= $3.next()){var F=c.value.autoplayVideoRenderer;if(F&&F.compactVideoRenderer){MP=F.compactVideoRenderer;break}}if(lY=K1[0].autoplayVideo){var Y=lY.clickTrackingParams;Y&&(f1.itct=Y);f1.autonav="1";f1.playnext=String(S)}}else f1.feature="related-auto";var L=g.a(lY,g.lV);if(MP){Aq.videoId=MP.videoId;var X=MP.shortBylineText;X&&(Aq.author=g.Jz(X));var lD=MP.title;lD&&(Aq.title=g.Jz(lD))}else L!=null&&L.videoId&&(Aq.videoId=L.videoId);Aq.DS=f1;P.suggestions=[];P.v3=Aq}}if(T){for(var zW=[],mD=g.N(T),G= mD.next();!G.done;G=mD.next()){var Cx=G.value,$a=void 0,tq=null;if(Cx.endScreenVideoRenderer){var px=Cx.endScreenVideoRenderer,go=px.title;tq=new g.A0(P.N());tq.videoId=px.videoId;tq.lengthSeconds=px.lengthInSeconds||0;var jx=px.publishedTimeText;jx&&(tq.publishedTimeText=g.Jz(jx));var kw=px.shortBylineText;kw&&(tq.author=g.Jz(kw));var Ey=px.shortViewCountText;Ey&&(tq.shortViewCount=g.Jz(Ey));if(go){tq.title=g.Jz(go);var Z7=go.accessibility;if(Z7){var ya=Z7.accessibilityData;ya&&ya.label&&(tq.ariaLabel= ya.label)}}var St=px.navigationEndpoint;if(St){$a=St.clickTrackingParams;var Wr=g.a(St,g.lV),fU=g.a(St,g.ar);Wr?tq.CZ=Wr:fU!=null&&(tq.watchUrl=fU.url)}var ae=px.thumbnailOverlays;if(ae)for(var jw=g.N(ae),Hi=jw.next();!Hi.done;Hi=jw.next()){var NV=Hi.value.thumbnailOverlayTimeStatusRenderer;if(NV)if(NV.style==="LIVE"){tq.isLivePlayback=!0;break}else if(NV.style==="UPCOMING"){tq.isUpcoming=!0;break}}tq.X=J0(px.thumbnail)}else if(Cx.endScreenPlaylistRenderer){var gY=Cx.endScreenPlaylistRenderer,p7= gY.navigationEndpoint;if(!p7)continue;var gK=g.a(p7,g.lV);if(!gK)continue;var L7=gK.videoId;tq=new g.FX(P.N());tq.playlistId=gY.playlistId;tq.playlistLength=Number(gY.videoCount)||0;tq.W=L7||null;tq.videoId=L7;var BN=gY.title;BN&&(tq.title=g.Jz(BN));var iI=gY.shortBylineText;iI&&(tq.author=g.Jz(iI));$a=p7.clickTrackingParams;tq.X=J0(gY.thumbnail)}tq&&($a&&(tq.sessionData={itct:$a}),zW.push(tq))}P.suggestions=zW}if(H){P.mE=!!H.preferImmediateRedirect;P.vl=P.vl||!!H.webShowNewAutonavCountdown;P.iY= P.iY||!!H.webShowBigThumbnailEndscreen;if(P.vl||P.iY){var A4=r||null,Vv=new g.A0(P.N());Vv.videoId=H.videoId;var E1=H.videoTitle;if(E1){Vv.title=g.Jz(E1);var zV=E1.accessibility;if(zV){var KT=zV.accessibilityData;KT&&KT.label&&(Vv.ariaLabel=KT.label)}}var E5=H.byline;E5&&(Vv.author=g.Jz(E5));var wL=H.publishedTimeText;wL&&(Vv.publishedTimeText=g.Jz(wL));var $J=H.shortViewCountText;$J&&(Vv.shortViewCount=g.Jz($J));var Ib=H.thumbnailOverlays;if(Ib)for(var DT=g.N(Ib),zx=DT.next();!zx.done;zx=DT.next()){var RF= zx.value.thumbnailOverlayTimeStatusRenderer;if(RF)if(RF.style==="LIVE"){Vv.isLivePlayback=!0;break}else if(RF.style==="UPCOMING"){Vv.isUpcoming=!0;break}else if(RF.style==="DEFAULT"&&RF.text){Vv.lengthText=g.Jz(RF.text);var mv=RF.text.accessibility;if(mv){var R5=mv.accessibilityData;R5&&R5.label&&(Vv.z$=R5.label||"")}break}}Vv.X=J0(H.background);var n0=H.nextButton;if(n0){var N6=n0.buttonRenderer;if(N6){var Ji=N6.navigationEndpoint;if(Ji){var uf=g.a(Ji,g.lV);uf&&(Vv.CZ=uf)}}}if(H.topBadges){var K0= H.topBadges[0];if(K0){var cB=g.a(K0,qBq);cB&&cB.style==="BADGE_STYLE_TYPE_PREMIUM"&&(Vv.iXc=!0)}}var ah=H.alternativeTitle;ah&&(Vv.fl=g.Jz(ah));var c9={autonav:"1",playnext:String(S)};Vv.playlistId&&(c9.autoplay="1");if(A4){var Hd,Oq,Q1,q6,tH=(Hd=A4.autoplay)==null?void 0:(Oq=Hd.autoplay)==null?void 0:(Q1=Oq.sets)==null?void 0:(q6=Q1[0])==null?void 0:q6.autoplayVideo;if(tH){var Fp=tH.clickTrackingParams;Fp&&(c9.itct=Fp);var y1=g.a(tH,g.lV);y1&&(Vv.f_=y1)}}else if(H){var Ai,YJ,bf,xJ=(Ai=H.nextButton)== null?void 0:(YJ=Ai.buttonRenderer)==null?void 0:(bf=YJ.navigationEndpoint)==null?void 0:bf.clickTrackingParams;xJ&&(c9.itct=xJ)}c9.itct||(c9.feature="related-auto");Vv.DS=c9;P.suggestions||(P.suggestions=[]);P.v3=Vv}H.countDownSecs!=null&&(P.dF=H.countDownSecs*1E3);H.countDownSecsForFullscreen!=null&&(P.j0=H.countDownSecsForFullscreen>=0?H.countDownSecsForFullscreen*1E3:-1);P.V("web_autonav_color_transition")&&H.watchToWatchTransitionRenderer&&(P.watchToWatchTransitionRenderer=g.a(H.watchToWatchTransitionRenderer, Ff7))}var Cs=EWw(P);if(Cs){var p0,ED,L0,fs=Cs==null?void 0:(p0=Cs[0])==null?void 0:(ED=p0.endScreenVideoRenderer)==null?void 0:(L0=ED.navigationEndpoint)==null?void 0:L0.clickTrackingParams,Ss=g.er(P);fs&&Ss&&(Ss.sessionData={itct:fs})}P.Pg.currentVideoThumbnail&&(P.X=J0(P.Pg.currentVideoThumbnail));var GN,Fx,u_,Aa,g9,J6=(GN=P.Pg)==null?void 0:(Fx=GN.contents)==null?void 0:(u_=Fx.twoColumnWatchNextResults)==null?void 0:(Aa=u_.results)==null?void 0:(g9=Aa.results)==null?void 0:g9.contents;if(J6&&J6[1]){var uX, K9,Xp,QO,cs=(uX=J6[1].videoSecondaryInfoRenderer)==null?void 0:(K9=uX.owner)==null?void 0:(Xp=K9.videoOwnerRenderer)==null?void 0:(QO=Xp.thumbnail)==null?void 0:QO.thumbnails;cs&&cs.length&&(P.profilePicture=cs[cs.length-1].url)}var Wd=wD(v),BB,U3=(BB=P.getWatchNextResponse())==null?void 0:BB.onResponseReceivedEndpoints;if(U3)for(var Ua=g.N(U3),kS=Ua.next();!kS.done;kS=Ua.next()){var w9=kS.value;g.a(w9,hc)&&(P.pD=g.a(w9,hc));var tv=g.a(w9,AAD),ZT=void 0;if((ZT=tv)==null?0:ZT.entityKeys)P.ke=tv.entityKeys|| [],tv.visibleOnLoadKeys&&(P.visibleOnLoadKeys=tv.visibleOnLoadKeys)}if(P.V("web_key_moments_markers")){var oh=g.z6.getState().entities,js=g.ft("visibility_override","markersVisibilityOverrideEntity");var W0=kl(oh,"markersVisibilityOverrideEntity",js);P.D3=(W0==null?void 0:W0.videoId)===(P.videoId||Wd)&&(W0==null?0:W0.visibilityOverrideMarkersKey)?W0.visibilityOverrideMarkersKey:P.visibleOnLoadKeys;P.visibleOnLoadKeys=[].concat(g.u(P.D3))}}}; vd=function(P){var v;return((v=P.autoplaySwitchButtonRenderer)==null?void 0:v.enabled)!==void 0}; me=function(P){return!!(P.G&&P.G.videoInfos&&P.G.videoInfos.length)}; g.Cj=function(P){var v=P.S;P.V("html5_gapless_unlimit_format_selection")&&Rh(P)&&(v=!1);var l=!!P.W&&P.W.Ei,e=P.Z3,h=P.JU(),z=Qi(P),m=P.nI,Q=v,t=P.isOtf();v=P.ex();var y=P.U$,C=P.getUserAudio51Preference(),f=tc(P),k=new vG9(e);if(e.vK()||e.V("html5_logging_format_selection"))k.K=!0;k.h5=z;k.nI=m&&e.j;k.Hg=C;g.Mc("windows nt 5.1")&&!g.Wj&&(k.ek=!0);if(z=h)z=g.h0(e)?vWB(e):!1;z&&(k.J5=!0);Q&&(k.ek=!0,k.zK=!0);t&&!e.V("html5_otf_prefer_vp9")&&(k.ek=!0);e.playerStyle==="picasaweb"&&(t&&(k.ek=!1),k.T1= !1);y&&(k.ek=!0);Kr(e.Z,cn.CHANNELS)&&(e.V("html5_enable_aac51")&&(k.QW=!0),e.V("html5_enable_ac3")&&(k.Y=!0),e.V("html5_enable_eac3")&&(k.Z=!0),e.V("html5_enable_ac3_gapless")&&(k.Pg=!0));e.V("html5_block_8k_hfr")&&(k.D3=!0);k.T=g.ID(e.experiments,"html5_max_selectable_quality_ordinal");k.j=g.ID(e.experiments,"html5_min_selectable_quality_ordinal");zF&&(k.Xq=480);if(l||h)k.T1=!1;k.U$=!1;k.disableAv1=f;l=GB(e,k.W,void 0,k.disableAv1);l>0&&l<2160&&(WB()||e.V("html5_format_hybridization"))&&(k.W.supportsChangeType= +WB(),k.gH=l);l>=2160&&(k.wM=!0);Yu2()&&(k.W.serveVp9OverAv1IfHigherRes=0,k.MV=!1);k.ex=v;k.Ic=g.vs||QK()&&!v?!1:!0;k.S=e.V("html5_format_hybridization");k.TG=e.V("html5_disable_encrypted_vp9_live_non_2k_4k");yi(P)&&(k.aV=P.V("html5_prefer_language_over_codec"));d$()&&P.playerResponse&&P.playerResponse.playerConfig&&P.playerResponse.playerConfig.webPlayerConfig&&P.playerResponse.playerConfig.webPlayerConfig.useCobaltTvosDogfoodFeatures&&(k.Y=!0,k.Z=!0);P.S&&P.isAd()&&(P.ET&&(k.Wg=P.ET),P.kV&&(k.G= P.kV));k.q5=P.isLivePlayback&&P.d7()&&P.Z3.V("html5_drm_live_audio_51");k.WK=P.N$;return P.Hl=k}; tc=function(P){return P.Z3.V("html5_disable_av1")||P.V("html5_gapless_shorts_disable_av1")&&Rh(P)?!0:!1}; YBP=function(P){WI("drm_pb_s",void 0,P.q5);P.h5||P.W&&Dh(P.W);var v={};P.W&&(v=joq(P.Rr,g.Cj(P),P.Z3.Z,P.W,function(l){return P.publish("ctmp","fmtflt",l)},!0,new Set)); v=new TB(v,P.Z3,P.T8,P.useCobaltWidevine?d$()?fj(P):!1:!1,function(l,e){P.f0(l,e)}); g.Z(P,v);P.Tg=!1;P.loading=!0;fky(v,function(l){WI("drm_pb_f",void 0,P.q5);for(var e=g.N(l),h=e.next();!h.done;h=e.next())switch(h=h.value,h.flavor){case "fairplay":h.h5=P.h5;h.S9=P.S9;h.N1=P.N1;break;case "widevine":h.S6=P.S6}P.qP=l;if(P.qP.length>0&&(P.Z=P.qP[0],P.Z3.vK())){l={};e=g.N(Object.entries(P.Z.W));for(h=e.next();!h.done;h=e.next()){var z=g.N(h.value);h=z.next().value;z=z.next().value;var m="unk";(h=h.match(/(.*)codecs="(.*)"/))&&(m=h[2]);l[m]=z}P.f0("drmProbe",l)}P.sj()})}; bO7=function(P,v){if(v.length===0||gw(P))return null;kM(P,"html5_enable_cobalt_experimental_vp9_decoder")&&(pq=!0);var l=P.EQ;var e=P.lengthSeconds,h=P.isLivePlayback,z=P.cz,m=P.Z3,Q=Z0y(v);if(h||z){m=m.experiments;e=new w6("",m,!0);e.K=!z;e.Ei=!0;e.isManifestless=!0;e.isLive=!z;e.cz=z;v=g.N(v);for(h=v.next();!h.done;h=v.next()){var t=h.value;h=Dl(t,l);Q=pr(t);Q=Nt(Q.pZ||t.url||"",Q.M9,Q.s);var y=Q.get("id");y&&y.includes("%7E")&&(e.X=!0);var C=void 0;y=(C=m)==null?void 0:C.l$("html5_max_known_end_time_rebase"); C=Number(t.targetDurationSec||5);t=Number(t.maxDvrDurationSec||14400);var f=Number(Q.get("mindsq")||Q.get("min_sq")||"0"),k=Number(Q.get("maxdsq")||Q.get("max_sq")||"0")||Infinity;e.Mv=e.Mv||f;e.UR=e.UR||k;var w=!lf(h);Q&&fq(e,new dR(Q,h,{rY:C,fk:w,ZY:t,Mv:f,UR:k,Kx:300,cz:z,oE:y}))}l=e}else if(Q==="FORMAT_STREAM_TYPE_OTF"){e=e===void 0?0:e;z=new w6("",m.experiments,!1);z.duration=e||0;m=g.N(v);for(e=m.next();!e.done;e=m.next())e=e.value,v=Dl(e,l,z.duration),h=pr(e),(h=Nt(h.pZ||e.url||"",h.M9,h.s))&& (v.streamType==="FORMAT_STREAM_TYPE_OTF"?fq(z,new Pj(h,v,"sq/0")):fq(z,new tp(h,v,SV(e.initRange),SV(e.indexRange))));z.isOtf=!0;l=z}else{e=e===void 0?0:e;z=new w6("",m.experiments,!1);z.duration=e||0;m=g.N(v);for(e=m.next();!e.done;e=m.next())Q=e.value,e=Dl(Q,l,z.duration),v=SV(Q.initRange),h=SV(Q.indexRange),y=pr(Q),(Q=Nt(y.pZ||Q.url||"",y.M9,y.s))&&fq(z,new tp(Q,e,v,h));l=z}z=P.isLivePlayback&&!P.cz&&!P.wM&&!P.isPremiere;P.V("html5_live_head_playable")&&(!ww(P)&&z&&P.f0("missingLiveHeadPlayable", {}),P.Z3.Wg==="yt"&&(l.Ic=!0));return l}; gw=function(P){return d$()?!fj(P):vx()?!(!P.h5||!P.V("html5_enable_safari_fairplay")&&mx()):!1}; fj=function(P){return P.V("html5_tvos_skip_dash_audio_check")||MediaSource.isTypeSupported('audio/webm; codecs="opus"')}; g.Pd=function(P,v){v=g.N(v);for(var l=v.next();!l.done;l=v.next())if(l=l.value,l.cueRangeSetIdentifier){var e=void 0;P.Vl.set(l.cueRangeSetIdentifier,(e=l.playerCueRanges)!=null?e:[])}}; $M=function(P){return!(!P.W||!P.W.isManifestless)}; Ih=function(P){return P.aV?P.isLowLatencyLiveStream&&P.W!=null&&cj(P.W)>=5:P.isLowLatencyLiveStream&&P.W!=void 0&&cj(P.W)>=5}; xfD=function(P){return d$()&&fj(P)?!1:gw(P)&&(g.bq(P.Z3)?!P.isLivePlayback:P.hlsvp)||!mx()||P.DX?!0:!1}; SBa=function(P){P.loading=!0;P.oz=!1;if(p4q(P))g.PJ6(P.videoId).then(function(e){LfD(P,e)}).then(function(){P.sj()}); else{zw(P.zK)||g.j4(new g.Ph("DASH MPD Origin invalid: ",P.zK));var v=P.zK,l=g.ID(P.Z3.experiments,"dash_manifest_version")||4;v=g.r5(v,{mpd_version:l});P.isLowLatencyLiveStream&&P.latencyClass!=="NORMAL"||(v=g.r5(v,{pacing:0}));sbu(v,P.Z3.experiments,P.isLivePlayback).then(function(e){P.s$()||(DN(P,e,!0),WI("mrc",void 0,P.q5),P.sj())},function(e){P.s$()||(P.loading=!1,P.publish("dataloaderror",new xq("manifest.net.retryexhausted",{backend:"manifest", rc:e.status},1)))}); WI("mrs",void 0,P.q5)}}; LfD=function(P,v){var l=v.map(function(t){return t.itag}),e; if((e=P.playerResponse)!=null&&e.streamingData){e=[];if(P.V("html5_offline_always_use_local_formats")){l=0;for(var h=g.N(v),z=h.next();!z.done;z=h.next()){z=z.value;var m=Object.assign({},z);m.signatureCipher="";e.push(m);m=g.N(P.playerResponse.streamingData.adaptiveFormats);for(var Q=m.next();!Q.done;Q=m.next())if(Q=Q.value,z.itag===Q.itag&&z.xtags===Q.xtags){l+=1;break}}l C&&(C=w.getInfo().audio.numChannels)}C>2&&P.f0("hlschl",{mn:C});var K;((K=P.Hl)==null?0:K.K)&&P.f0("hlsfmtaf",{itags:f.join(".")});var q;if(P.V("html5_enable_vp9_fairplay")&&((q=P.Z)==null?0:Hj(q)))for(P.f0("drm",{sbdlfbk:1}),C=g.N(P.qP),f=C.next();!f.done;f=C.next())if(f=f.value,aK(f)){P.Z=f;break}uV(P,y)})}return Zp()}; Ufw=function(P){if(P.isExternallyHostedPodcast&&P.FL){var v=Jc(P.FL);if(!v[0])return Zp();P.mV=v[0];return K0u(P.Z3,v[0]).then(function(l){uV(P,l)})}return P.d4&&P.LD?ug6(P.Z3,P.isAd(),P.d4).then(function(l){uV(P,l)}):Zp()}; jLw=function(P){if(P.isExternallyHostedPodcast)return Zp();var v=Jc(P.FL,P.fp);if(P.hlsvp){var l=yAB(P.hlsvp,P.clientPlaybackNonce,P.MV);v.push(l)}return JXD(P.Z3,P.isAd(),v,ZOB(P)).then(function(e){uV(P,e)})}; X4w=function(P,v){P.G=v;if(P.G){v=g.N(P.G.videoInfos);for(var l=v.next();!l.done;l=v.next()){l=l.value;var e=l.containerType;e!==0&&(P.xI[e]=l.id)}}Kj(P);if(P.Z&&P.G&&P.G.videoInfos&&!(P.G.videoInfos.length<=0)&&(v=vB(P.G.videoInfos[0]),P.Z.flavor==="fairplay"!==v))for(l=g.N(P.qP),e=l.next();!e.done;e=l.next())if(e=e.value,v===(e.flavor==="fairplay")){P.Z=e;break}}; uV=function(P,v){P.hs=v;X4w(P,new gG(g.LC(P.hs,function(l){return l.getInfo()})))}; ZOB=function(P){var v={cpn:P.clientPlaybackNonce,c:P.Z3.W.c,cver:P.Z3.W.cver};P.E6&&(v.ptk=P.E6,v.oid=P.tM,v.ptchn=P.EV,v.pltype=P.HQ,P.D2&&(v.m=P.D2));return v}; g.cd=function(P){return gw(P)&&P.h5?(P={},P.fairplay="https://youtube.com/api/drm/fps?ek=uninitialized",P):P.K&&P.K.EQ||null}; aZD=function(P){var v=qA(P);return v&&v.text?g.Jz(v.text):P.paidContentOverlayText}; HOu=function(P){var v=qA(P);return v&&v.durationMs?ep(v.durationMs):P.paidContentOverlayDurationMs}; qA=function(P){var v,l,e;return P.playerResponse&&P.playerResponse.paidContentOverlay&&P.playerResponse.paidContentOverlay.paidContentOverlayRenderer||g.a((v=P.Pg)==null?void 0:(l=v.playerOverlays)==null?void 0:(e=l.playerOverlayRenderer)==null?void 0:e.playerDisclosure,Ejw)||null}; FV=function(P){var v="";if(P.yE)return P.yE;P.isLivePlayback&&(v=P.allowLiveDvr?"dvr":P.isPremiere?"lp":P.wM?"window":"live");P.cz&&(v="post");return v}; g.Ac=function(P,v){return typeof P.keywords[v]!=="string"?null:P.keywords[v]}; WfD=function(P){return!!P.Yy||!!P.NG||!!P.G_||!!P.YJ||P.S5||P.j.focEnabled||P.j.rmktEnabled}; g.YM=function(P){return!!(P.zK||P.FL||P.d4||P.hlsvp||P.l2())}; rh=function(P){if(P.V("html5_onesie")&&P.errorCode)return!1;var v=g.ro(P.T1,"ypc");P.ypcPreview&&(v=!1);return P.n6()&&!P.loading&&(g.YM(P)||g.ro(P.T1,"heartbeat")||v)}; Jc=function(P,v){P=CG(P);var l={};if(v){v=g.N(v.split(","));for(var e=v.next();!e.done;e=v.next())(e=e.value.match(/^([0-9]+)\/([0-9]+)x([0-9]+)(\/|$)/))&&(l[e[1]]={width:e[2],height:e[3]})}v=g.N(P);for(e=v.next();!e.done;e=v.next()){e=e.value;var h=l[e.itag];h&&(e.width=h.width,e.height=h.height)}return P}; Kj=function(P){var v=P.getAvailableAudioTracks();v=v.concat(P.A1);for(var l=0;l 0:v||P.adFormat!=="17_8"||P.isAutonav||g.lN(P.Z3)||P.Nf?P.Ro?!1:P.Z3.Xf||P.Z3.sR||!g.LP(P.Z3)?!v&&ZN(P)==="adunit"&&P.Yy?!1:!0:!1:!1:(P.Ro?0:P.XE)&&g.LP(P.Z3)?!0:!1;P.V("html5_log_detailpage_autoplay")&&ZN(P)==="detailpage"&&P.f0("autoplay_info",{autoplay:P.tq,autonav:P.isAutonav,wasDompaused:P.Ro,result:v});return v}; g.MA=function(P){return P.oauthToken||P.Z3.Zj}; hWW=function(P){if(P.V("html5_stateful_audio_normalization")){var v=1,l=g.ID(P.Z3.experiments,"html5_default_ad_gain");l&&P.isAd()&&(v=l);var e;if(l=((e=P.Y)==null?void 0:e.audio.K)||P.N9){e=(0,g.Gz)();P.kB=2;var h=e-P.Z3.ir<=P.maxStatefulTimeThresholdSec*1E3;P.applyStatefulNormalization&&h?P.kB=4:h||(P.Z3.RO=Infinity,P.Z3.ir=NaN);h=(P.kB===4?g.CU(P.Z3.RO,P.minimumLoudnessTargetLkfs,P.loudnessTargetLkfs):P.loudnessTargetLkfs)-l;if(P.kB!==4){var z,m,Q,t,y=((z=P.playerResponse)==null?void 0:(m=z.playerConfig)== null?void 0:(Q=m.audioConfig)==null?void 0:(t=Q.loudnessNormalizationConfig)==null?void 0:t.statelessLoudnessAdjustmentGain)||0;h+=y}h=Math.min(h,0);P.preserveStatefulLoudnessTarget&&(P.Z3.RO=l+h,P.Z3.ir=e);P=Math.min(1,Math.pow(10,h/20))||v}else P=eWy(P)}else P=eWy(P);return P}; eWy=function(P){var v=1,l=g.ID(P.Z3.experiments,"html5_default_ad_gain");l&&P.isAd()&&(v=l);var e;if(l=((e=P.Y)==null?void 0:e.audio.G)||P.sZ)P.kB=1;return Math.min(1,Math.pow(10,-l/20))||v}; Qi=function(P){var v=["MUSIC_VIDEO_TYPE_ATV","MUSIC_VIDEO_TYPE_PRIVATELY_OWNED_TRACK"],l=va(P.Z3)==="TVHTML5_SIMPLY"&&P.Z3.W.ctheme==="MUSIC";P.Ff||!g.H$(P.Z3)&&!l||!v.includes(P.musicVideoType)&&!P.isExternallyHostedPodcast||(P.Ff=!0);if(v=g.VS())v=/Starboard\/([0-9]+)/.exec(g.Y3()),v=(v?parseInt(v[1],10):NaN)<10;l=P.Z3;l=(va(l)==="TVHTML5_CAST"||va(l)==="TVHTML5"&&(l.W.cver.startsWith("6.20130725")||l.W.cver.startsWith("6.20130726")))&&P.Z3.W.ctheme==="MUSIC";var e;if(e=!P.Ff)l||(l=P.Z3,l=va(l)=== "TVHTML5"&&l.W.cver.startsWith("7")),e=l;e&&!v&&(v=P.musicVideoType==="MUSIC_VIDEO_TYPE_PRIVATELY_OWNED_TRACK",l=(P.V("cast_prefer_audio_only_for_atv_and_uploads")||P.V("kabuki_pangea_prefer_audio_only_for_atv_and_uploads"))&&P.musicVideoType==="MUSIC_VIDEO_TYPE_ATV",v||l||P.isExternallyHostedPodcast)&&(P.Ff=!0);return P.Z3.deviceIsAudioOnly||P.Ff&&P.Z3.j}; T6=function(P){var v,l,e;return!!((v=P.playerResponse)==null?0:(l=v.playerConfig)==null?0:(e=l.mediaCommonConfig)==null?0:e.splitScreenEligible)}; Vi=function(P){var v;return!((v=P.playerResponse)==null||!v.compositePlayabilityStatus)}; zWB=function(P){return isNaN(P)?0:Math.max((Date.now()-P)/1E3-30,0)}; dw=function(P){return!(!P.Nq||!P.Z3.j)&&P.l2()}; mzW=function(P){return P.enablePreroll&&P.enableServerStitchedDai}; RWu=function(P){return P.V("html5_enable_sabr_from_watch_server")&&P.Uf&&!P.VK}; yi=function(P){var v=P.V("html5_enable_sabr_on_drive")&&P.Z3.Wg==="gd";if(P.dE)return P.V("html5_enable_sabr_from_watch_server")&&P.f0("fds",{fds:!0},!0),!1;if(P.Z3.Wg!=="yt"&&!v)return P.V("html5_enable_sabr_from_watch_server")&&P.f0("dsvn",{ns:P.Z3.Wg},!0),!1;if(P.cotn||!P.W||P.W.isOtf||P.jx&&!P.V("html5_enable_sabr_csdai"))return!1;if(P.V("html5_use_sabr_requests_for_debugging"))return!0;if(P.V("html5_enable_sabr_from_watch_server")){v=P.Uf&&!!P.VK;P.f0("esfw",{usbc:P.Uf,hsu:!!P.VK},!0);if(!P.V("html5_combine_client_check_for_sabr"))return v; if(v)return!0;P.Ph("sabr","esfc")}var l=!P.W.Ei&&!P.d7();v=l&&ly&&P.V("html5_enable_sabr_vod_streaming_xhr");l=l&&!ly&&P.V("html5_enable_sabr_vod_non_streaming_xhr");var e=g.PS(P),h=P.V("html5_enable_sabr_drm_vod_streaming_xhr")&&ly&&P.d7()&&!P.W.Ei&&(P.hN==="1"?!1:!0);(v=v||l||e||h)&&!P.VK&&P.f0("sabr",{loc:"m"},!0);return v&&!!P.VK}; g.PS=function(P){var v;if(!(v=ly&&P.Ei()&&P.d7()&&(P.hN==="1"?!1:!0)&&P.V("html5_sabr_live_drm_streaming_xhr"))){v=P.Ei()&&!P.d7()&&ly;var l=P.Ei()&&P.latencyClass!=="ULTRALOW"&&!P.isLowLatencyLiveStream&&P.V("html5_sabr_live_normal_latency_streaming_xhr"),e=P.isLowLatencyLiveStream&&P.V("html5_sabr_live_low_latency_streaming_xhr"),h=P.latencyClass==="ULTRALOW"&&P.V("html5_sabr_live_ultra_low_latency_streaming_xhr");v=v&&(l||e||h)}l=v;v=P.enableServerStitchedDai&&l&&P.V("html5_enable_sabr_ssdai_streaming_xhr"); l=!P.enableServerStitchedDai&&l;e=P.Ei()&&!ly&&P.V("html5_enable_sabr_live_non_streaming_xhr");P=ly&&(P.DR()||T6(P)&&P.V("html5_enable_sabr_for_lifa_eligible_streams"));return v||l||e||P}; g.VW=function(P){return P.cC&&yi(P)}; p4q=function(P){var v;if(v=!!P.cotn)v=P.videoId,v=!!v&&g.L_(v)===1;return v&&!P.Nq}; g.vS=function(P){if(!P.W||!P.K||!P.Y)return!1;var v=P.W.W,l=!!v[P.K.id]&&Y_(v[P.K.id].JR.W);v=!!v[P.Y.id]&&Y_(v[P.Y.id].JR.W);return(P.K.itag==="0"||l)&&v}; l2=function(P){return P.q4?["OK","LIVE_STREAM_OFFLINE"].includes(P.q4.status):!0}; M69=function(P){return(P=P.dn)&&P.showError?P.showError:!1}; kM=function(P,v){return P.V(v)?!0:(P.fflags||"").includes(v+"=true")}; Q8D=function(P){return P.V("html5_heartbeat_iff_heartbeat_params_filled")}; IZW=function(P,v){v.inlineMetricEnabled&&(P.inlineMetricEnabled=!0);v.playback_progress_0s_url&&(P.YJ=new Ol6(v));if(v=v.video_masthead_ad_quartile_urls)P.NG=v.quartile_0_url,P.rp=v.quartile_25_url,P.jH=v.quartile_50_url,P.vQ=v.quartile_75_url,P.PQ=v.quartile_100_url,P.G_=v.quartile_0_urls,P.kI=v.quartile_25_urls,P.tf=v.quartile_50_urls,P.s5=v.quartile_75_urls,P.TL=v.quartile_100_urls}; $fq=function(P){var v={};P=g.N(P);for(var l=P.next();!l.done;l=P.next()){l=l.value;var e=l.split("=");e.length===2?v[e[0]]=e[1]:v[l]=!0}return v}; gjB=function(P){if(P){if(hay(P))return P;P=zaq(P);if(hay(P,!0))return P}return""}; g.tcq=function(P){return P.captionsLanguagePreference||P.Z3.captionsLanguagePreference||g.Ac(P,"yt:cc_default_lang")||P.Z3.TG}; eH=function(P){return!(!P.isLivePlayback||!P.hasProgressBarBoundaries())}; g.er=function(P){var v;return P.v3||((v=P.suggestions)==null?void 0:v[0])||null}; g.hM=function(P){return P.eg&&(P.V("embeds_enable_pfp_always_unbranded")||P.Z3.Ep)}; zy=function(P,v){P.V("html5_log_autoplay_src")&&Rh(P)&&P.f0("apsrc",{src:v})}; g.mO=function(P){var v,l;return!!((v=P.embeddedPlayerConfig)==null?0:(l=v.embeddedPlayerFlags)==null?0:l.enableMusicUx)}; g.QI=function(P){var v=P.N(),l=g.R0(v),e=v.D3;(v.V("embeds_web_enable_iframe_api_send_full_embed_url")||v.V("embeds_web_enable_rcat_validation_in_havs")||v.V("embeds_enable_autoplay_and_visibility_signals"))&&g.UM(v)&&(e&&(l.thirdParty=Object.assign({},l.thirdParty,{embedUrl:e})),p2w(l,P));if(e=P.kf)l.clickTracking={clickTrackingParams:e};e=l.client||{};var h="EMBED",z=ZN(P);z==="leanback"?h="WATCH":v.V("gvi_channel_client_screen")&&z==="profilepage"?h="CHANNEL":P.U$?h="LIVE_MONITOR":z==="detailpage"? h="WATCH_FULL_SCREEN":z==="adunit"?h="ADUNIT":z==="sponsorshipsoffer"&&(h="UNKNOWN");e.clientScreen=h;if(v=P.kidsAppInfo)e.kidsAppInfo=JSON.parse(v);(h=P.au)&&!v&&(e.kidsAppInfo={contentSettings:{ageUpMode:yFw[h]}});if(v=P.SZ)e.unpluggedAppInfo={enableFilterMode:!0};(h=P.unpluggedFilterModeType)&&!v&&(e.unpluggedAppInfo={filterModeType:CFw[h]});if(v=P.Wg)e.unpluggedLocationInfo=v;l.client=e;e=l.request||{};P.oV&&(e.isPrefetch=!0);if(v=P.mdxEnvironment)e.mdxEnvironment=v;if(v=P.mdxControlMode)e.mdxControlMode= foq[v];l.request=e;e=l.user||{};if(v=P.QW)e.credentialTransferTokens=[{token:v,scope:"VIDEO"}];if(v=P.Bg)e.delegatePurchases={oauthToken:v},e.kidsParent={oauthToken:v};l.user=e;if(e=P.contextParams)l.activePlayers=[{playerContextParams:e}];if(P=P.clientScreenNonce)l.clientScreenNonce=P;return l}; g.R0=function(P){var v=g.lo(),l=v.client||{};if(P.forcedExperiments){var e=P.forcedExperiments.split(","),h=[];e=g.N(e);for(var z=e.next();!z.done;z=e.next())h.push(Number(z.value));l.experimentIds=h}if(h=P.homeGroupInfo)l.homeGroupInfo=JSON.parse(h);if(h=P.getPlayerType())l.playerType=h;if(h=P.W.ctheme)l.theme=h;if(h=P.livingRoomAppMode)l.tvAppInfo=Object.assign({},l.tvAppInfo,{livingRoomAppMode:h});h=P.deviceYear;P.V("html5_propagate_device_year")&&h&&(l.tvAppInfo=Object.assign({},l.tvAppInfo,{deviceYear:h})); if(h=P.livingRoomPoTokenId)l.tvAppInfo=Object.assign({},l.tvAppInfo,{livingRoomPoTokenId:h});v.client=l;l=v.user||{};P.enableSafetyMode&&(l=Object.assign({},l,{enableSafetyMode:!0}));P.pageId&&(l=Object.assign({},l,{onBehalfOfUser:P.pageId}));v.user=l;l=P.D3;P.V("embeds_web_enable_iframe_api_send_full_embed_url")||P.V("embeds_web_enable_rcat_validation_in_havs")||P.V("embeds_enable_autoplay_and_visibility_signals")||!l||(v.thirdParty={embedUrl:l});return v}; DzB=function(P,v,l){var e=P.videoId,h=g.QI(P),z=P.N(),m={html5Preference:"HTML5_PREF_WANTS",lactMilliseconds:String(Ly()),referer:document.location.toString(),signatureTimestamp:20123};g.sY();P.isAutonav&&(m.autonav=!0);g.rD(0,141)&&(m.autonavState=g.rD(0,140)?"STATE_OFF":"STATE_ON");m.autoCaptionsDefaultOn=g.rD(0,66);rw(P)&&(m.autoplay=!0);z.j&&P.cycToken&&(m.cycToken=P.cycToken);z.enablePrivacyFilter&&(m.enablePrivacyFilter=!0);P.isFling&&(m.fling=!0);var Q=P.forceAdsUrl;if(Q){var t={},y=[];Q=Q.split(","); Q=g.N(Q);for(var C=Q.next();!C.done;C=Q.next()){C=C.value;var f=C.split("|");f.length!==3||C.includes("=")||(f[0]="breaktype="+f[0],f[1]="offset="+f[1],f[2]="url="+f[2]);C={adtype:"video_ad"};f=g.N(f);for(var k=f.next();!k.done;k=f.next()){var w=g.N(k.value.split("="));k=w.next().value;w=z6y(w);C[k]=w.join("=")}f=C.url;k=C.presetad;w=C.viralresponseurl;var I=Number(C.campaignid);if(C.adtype==="in_display_ad")f&&(t.url=f),k&&(t.presetAd=k),w&&(t.viralAdResponseUrl=w),I&&(t.viralCampaignId=String(I)); else if(C.adtype==="video_ad"){var J={offset:{kind:"OFFSET_MILLISECONDS",value:String(Number(C.offset)||0)}};if(C=gCq[C.breaktype])J.breakType=C;f&&(J.url=f);k&&(J.presetAd=k);w&&(J.viralAdResponseUrl=w);I&&(J.viralCampaignId=String(I));y.push(J)}}m.forceAdParameters={videoAds:y,inDisplayAd:t}}P.isInlinePlaybackNoAd&&(m.isInlinePlaybackNoAd=!0);P.isLivingRoomDeeplink&&(m.isLivingRoomDeeplink=!0);t=P.R4;if(t!=null){t={startWalltime:String(t)};if(y=P.eb)t.manifestDuration=String(y||14400);m.liveContext= t}if(P.mutedAutoplay&&(m.mutedAutoplay=!0,P.V("embeds_enable_full_length_inline_muted_autoplay"))){t=z.getWebPlayerContextConfig();var K,q;(t==null?0:(K=t.embedsHostFlags)==null?0:K.allowMutedAutoplayDurationMode)&&(t==null?0:(q=t.embedsHostFlags)==null?0:q.allowMutedAutoplayDurationMode.includes(kuD[P.mutedAutoplayDurationMode]))&&(m.mutedAutoplayDurationMode=kuD[P.mutedAutoplayDurationMode])}if(P.Ro?0:P.XE)m.splay=!0;K=P.vnd;K===5&&(m.vnd=K);K={};if(q=P.isMdxPlayback)K.triggeredByMdx=q;if(q=P.Jw)K.skippableAdsSupported= q.split(",").includes("ska");if(y=P.wY){q=P.w1;t=[];y=g.N(L8a(y));for(Q=y.next();!Q.done;Q=y.next()){Q=Q.value;C=Q.platform;Q={applicationState:Q.P_?"INACTIVE":"ACTIVE",clientFormFactor:wX6[C]||"UNKNOWN_FORM_FACTOR",clientName:Gw9[Q.Ov]||"UNKNOWN_INTERFACE",clientVersion:Q.deviceVersion||"",platform:$za[C]||"UNKNOWN_PLATFORM"};C={};if(q){f=void 0;try{f=JSON.parse(q)}catch(A){g.j4(A)}f&&(C={params:[{key:"ms",value:f.ms}]},f.advertising_id&&(C.advertisingId=f.advertising_id),f.limit_ad_tracking!==void 0&& f.limit_ad_tracking!==null&&(C.limitAdTracking=f.limit_ad_tracking),Q.osName=f.os_name,Q.userAgent=f.user_agent,Q.windowHeightPoints=f.window_height_points,Q.windowWidthPoints=f.window_width_points)}t.push({adSignalsInfo:C,remoteClient:Q})}K.remoteContexts=t}q=P.sourceContainerPlaylistId;t=P.serializedMdxMetadata;if(q||t)y={},q&&(y.mdxPlaybackContainerInfo={sourceContainerPlaylistId:q}),t&&(y.serializedMdxMetadata=t),K.mdxPlaybackSourceContext=y;m.mdxContext=K;K=v.width;K>0&&(m.playerWidthPixels= Math.round(K));if(v=v.height)m.playerHeightPixels=Math.round(v);l!==0&&(m.vis=l);if(l=z.widgetReferrer)m.widgetReferrer=l.substring(0,128);g.LP(z)&&m&&(m.ancestorOrigins=z.ancestorOrigins);P.defaultActiveSourceVideoId&&(m.compositeVideoContext={defaultActiveSourceVideoId:P.defaultActiveSourceVideoId});if(z=z.getWebPlayerContextConfig())m.encryptedHostFlags=z.encryptedHostFlags;e={videoId:e,context:h,playbackContext:{contentPlaybackContext:m}};P.reloadPlaybackParams&&(e.playbackContext.reloadPlaybackContext= {reloadPlaybackParams:P.reloadPlaybackParams});P.contentCheckOk&&(e.contentCheckOk=!0);if(h=P.clientPlaybackNonce)e.cpn=h;if(h=P.playerParams)e.params=h;if(h=P.playlistId)e.playlistId=h;P.racyCheckOk&&(e.racyCheckOk=!0);h=P.N();if(m=h.embedConfig)e.serializedThirdPartyEmbedConfig=m;e.captionParams={};m=g.rD(g.sY(),65);P.deviceCaptionsOn!=null?e.captionParams.deviceCaptionsOn=P.deviceCaptionsOn:g.Po(h)&&(e.captionParams.deviceCaptionsOn=m!=null?!m:!1);P.Gx&&(e.captionParams.deviceCaptionsLangPref= P.Gx);P.CV.length?e.captionParams.viewerSelectedCaptionLangs=P.CV:g.Po(h)&&(m=g.Og(),m==null?0:m.length)&&(e.captionParams.viewerSelectedCaptionLangs=m);m=P.fetchType==="onesie"&&P.V("html5_onesie_attach_po_token");z=P.fetchType!=="onesie"&&P.V("html5_non_onesie_attach_po_token");if(m||z)m=P.N(),m.FL&&(e.serviceIntegrityDimensions={},e.serviceIntegrityDimensions.poToken=m.FL);h.V("fetch_att_independently")&&(e.attestationRequest={omitBotguardData:!0});if(h.V("html5_enable_sabr_from_watch_server")|| h.V("html5_report_supports_vp9_encoding"))e.playbackContext||(e.playbackContext={}),e.playbackContext.devicePlaybackCapabilities=IoW(P);return e}; IoW=function(P){var v=!(P==null?0:P.ex())&&(P==null?void 0:P.Ei())&&QK(),l;if(l=P==null?0:P.V("html5_report_supports_vp9_encoding")){if(P==null)l=0;else{l=g.Cj(P);P=P.N().Z;var e=t0("243");l=e?Ia(l,e,P,!0)===!0:!1}l=l&&!v}return{supportsVp9Encoding:!!l,supportXhr:ly}}; NaW=function(P,v){var l,e,h;return g.p(function(z){if(z.W==1)return l={context:g.R0(P.N()),engagementType:"ENGAGEMENT_TYPE_PLAYBACK",ids:[{playbackId:{videoId:P.videoId,cpn:P.clientPlaybackNonce}}]},e=g.$S(nCy),g.b(z,g.d9(v,l,e),2);h=z.K;return z.return(h)})}; JFw=function(P,v,l){var e=g.ID(v.experiments,"bg_vm_reinit_threshold");(!is||(0,g.Gz)()-is>e)&&NaW(P,l).then(function(h){h&&(h=h.botguardData)&&g.jn(h,v)},function(h){P.s$()||(h=LW(h),P.f0("attf",h.details))})}; tM=function(P,v){g.U.call(this);this.app=P;this.state=v}; Cc=function(P,v,l){P.state.W.hasOwnProperty(v)||yI(P,v,l);P.state.j[v]=function(){return l.apply(P,g.bD.apply(0,arguments))}; P.state.T.add(v)}; fc=function(P,v,l){P.state.W.hasOwnProperty(v)||yI(P,v,l);P.app.N().j&&(P.state.S[v]=function(){return l.apply(P,g.bD.apply(0,arguments))},P.state.T.add(v))}; yI=function(P,v,l){P.state.W[v]=function(){return l.apply(P,g.bD.apply(0,arguments))}}; g.gd=function(P,v,l){return P.state.W[v].apply(P.state.W,g.u(l))}; ki=function(){g.Gl.call(this);this.Z=new Map}; wd=function(){g.U.apply(this,arguments);this.element=null;this.T=new Set;this.j={};this.S={};this.W={};this.X=new Set;this.G=new ki;this.K=new ki;this.Y=new ki;this.Z=new ki}; uRu=function(P,v,l){typeof P==="string"&&(P={mediaContentUrl:P,startSeconds:v,suggestedQuality:l});a:{if((v=P.mediaContentUrl)&&(v=/\/([ve]|embed)\/([^#?]+)/.exec(v))&&v[2]){v=v[2];break a}v=null}P.videoId=v;return $i(P)}; $i=function(P,v,l){if(typeof P==="string")return{videoId:P,startSeconds:v,suggestedQuality:l};v={};l=g.N(K62);for(var e=l.next();!e.done;e=l.next())e=e.value,P[e]&&(v[e]=P[e]);return v}; cFw=function(P,v,l,e){if(g.Oy(P)&&!Array.isArray(P)){v="playlist list listType index startSeconds suggestedQuality".split(" ");l={};for(e=0;e 32&&e.push("hfr");v.isHdr()&&e.push("hdr");v.primaries==="bt2020"&&e.push("wcg");l.video_quality_features=e}}if(P=P.getPlaylistId())l.list=P;return l}; u2=function(){I0.apply(this,arguments)}; Kc=function(P,v){var l={};if(P.app.N().QW){P=g.N(YW7);for(var e=P.next();!e.done;e=P.next())e=e.value,v.hasOwnProperty(e)&&(l[e]=v[e]);if(v=l.qoe_cat)P="",typeof v==="string"&&v.length>0&&(P=v.split(",").filter(function(h){return bdw.includes(h)}).join(",")),l.qoe_cat=P; xzu(l)}else for(P=g.N(pXu),e=P.next();!e.done;e=P.next())e=e.value,v.hasOwnProperty(e)&&(l[e]=v[e]);return l}; xzu=function(P){var v=P.raw_player_response;if(!v){var l=P.player_response;l&&(v=JSON.parse(l))}delete P.player_response;delete P.raw_player_response;if(v){P.raw_player_response={streamingData:v.streamingData};var e;if((e=v.playbackTracking)==null?0:e.qoeUrl)P.raw_player_response=Object.assign({},P.raw_player_response,{playbackTracking:{qoeUrl:v.playbackTracking.qoeUrl}});var h;if((h=v.videoDetails)==null?0:h.videoId)P.raw_player_response=Object.assign({},P.raw_player_response,{videoDetails:{videoId:v.videoDetails.videoId}})}}; cS=function(P,v,l){var e=P.app.lC(l);if(!e)return 0;P=e-P.app.getCurrentTime(l);return v-P}; SW2=function(P){var v=v===void 0?5:v;return P?L66[P]||v:v}; g.qh=function(){u2.apply(this,arguments)}; Guw=function(P){yI(P,"getInternalApiInterface",P.getInternalApiInterface);yI(P,"addEventListener",P.Qv);yI(P,"removeEventListener",P.Bv0);yI(P,"cueVideoByPlayerVars",P.dg);yI(P,"loadVideoByPlayerVars",P.d5$);yI(P,"preloadVideoByPlayerVars",P.bbg);yI(P,"getAdState",P.getAdState);yI(P,"sendAbandonmentPing",P.sendAbandonmentPing);yI(P,"setLoopRange",P.setLoopRange);yI(P,"getLoopRange",P.getLoopRange);yI(P,"setAutonavState",P.setAutonavState);yI(P,"seekTo",P.sY2);yI(P,"seekBy",P.tc5);yI(P,"seekToLiveHead", P.seekToLiveHead);yI(P,"requestSeekToWallTimeSeconds",P.requestSeekToWallTimeSeconds);yI(P,"seekToStreamTime",P.seekToStreamTime);yI(P,"startSeekCsiAction",P.startSeekCsiAction);yI(P,"getStreamTimeOffset",P.getStreamTimeOffset);yI(P,"getVideoData",P.PD);yI(P,"setInlinePreview",P.setInlinePreview);yI(P,"getAppState",P.getAppState);yI(P,"updateLastActiveTime",P.updateLastActiveTime);yI(P,"setBlackout",P.setBlackout);yI(P,"setUserEngagement",P.setUserEngagement);yI(P,"updateSubtitlesUserSettings",P.updateSubtitlesUserSettings); yI(P,"getPresentingPlayerType",P.kS);yI(P,"canPlayType",P.canPlayType);yI(P,"updatePlaylist",P.updatePlaylist);yI(P,"updateVideoData",P.updateVideoData);yI(P,"updateEnvironmentData",P.updateEnvironmentData);yI(P,"sendVideoStatsEngageEvent",P.moc);yI(P,"productsInVideoVisibilityUpdated",P.productsInVideoVisibilityUpdated);yI(P,"setSafetyMode",P.setSafetyMode);yI(P,"isAtLiveHead",function(v){return P.isAtLiveHead(void 0,v)}); yI(P,"getVideoAspectRatio",P.getVideoAspectRatio);yI(P,"getPreferredQuality",P.getPreferredQuality);yI(P,"getPlaybackQualityLabel",P.getPlaybackQualityLabel);yI(P,"setPlaybackQualityRange",P.qr$);yI(P,"onAdUxClicked",P.onAdUxClicked);yI(P,"getFeedbackProductData",P.getFeedbackProductData);yI(P,"getStoryboardFrame",P.getStoryboardFrame);yI(P,"getStoryboardFrameIndex",P.getStoryboardFrameIndex);yI(P,"getStoryboardLevel",P.getStoryboardLevel);yI(P,"getNumberOfStoryboardLevels",P.getNumberOfStoryboardLevels); yI(P,"getCaptionWindowContainerId",P.getCaptionWindowContainerId);yI(P,"getAvailableQualityLabels",P.getAvailableQualityLabels);yI(P,"addCueRange",P.addCueRange);yI(P,"addUtcCueRange",P.addUtcCueRange);yI(P,"showAirplayPicker",P.showAirplayPicker);yI(P,"dispatchReduxAction",P.dispatchReduxAction);yI(P,"getPlayerResponse",P.pU);yI(P,"getWatchNextResponse",P.oX);yI(P,"getHeartbeatResponse",P.LU);yI(P,"getCurrentTime",P.WD);yI(P,"getDuration",P.E9);yI(P,"getPlayerState",P.getPlayerState);yI(P,"getPlayerStateObject", P.aX);yI(P,"getVideoLoadedFraction",P.getVideoLoadedFraction);yI(P,"getProgressState",P.getProgressState);yI(P,"getVolume",P.getVolume);yI(P,"setVolume",P.Vz);yI(P,"isMuted",P.isMuted);yI(P,"mute",P.yJ);yI(P,"unMute",P.Uz);yI(P,"loadModule",P.loadModule);yI(P,"unloadModule",P.unloadModule);yI(P,"getOption",P.oR);yI(P,"getOptions",P.getOptions);yI(P,"setOption",P.setOption);yI(P,"loadVideoById",P.pA);yI(P,"loadVideoByUrl",P.aS);yI(P,"playVideo",P.tj);yI(P,"loadPlaylist",P.loadPlaylist);yI(P,"nextVideo", P.nextVideo);yI(P,"previousVideo",P.previousVideo);yI(P,"playVideoAt",P.playVideoAt);yI(P,"getDebugText",P.getDebugText);yI(P,"getWebPlayerContextConfig",P.getWebPlayerContextConfig);yI(P,"notifyShortsAdSwipeEvent",P.notifyShortsAdSwipeEvent);yI(P,"getVideoContentRect",P.getVideoContentRect);yI(P,"setSqueezeback",P.setSqueezeback);yI(P,"toggleSubtitlesOn",P.toggleSubtitlesOn);yI(P,"isSubtitlesOn",P.isSubtitlesOn);yI(P,"reportPlaybackIssue",P.reportPlaybackIssue);yI(P,"setAutonav",P.setAutonav);yI(P, "isNotServable",P.isNotServable);yI(P,"channelSubscribed",P.channelSubscribed);yI(P,"channelUnsubscribed",P.channelUnsubscribed);yI(P,"togglePictureInPicture",P.togglePictureInPicture);yI(P,"supportsGaplessAudio",P.supportsGaplessAudio);yI(P,"supportsGaplessShorts",P.supportsGaplessShorts);yI(P,"enqueueVideoByPlayerVars",function(v){return void P.enqueueVideoByPlayerVars(v)}); yI(P,"clearQueue",P.clearQueue);yI(P,"getAudioTrack",P.Be);yI(P,"setAudioTrack",P.PA6);yI(P,"getAvailableAudioTracks",P.XK);yI(P,"getMaxPlaybackQuality",P.getMaxPlaybackQuality);yI(P,"getUserPlaybackQualityPreference",P.getUserPlaybackQualityPreference);yI(P,"getSubtitlesUserSettings",P.getSubtitlesUserSettings);yI(P,"resetSubtitlesUserSettings",P.resetSubtitlesUserSettings);yI(P,"setMinimized",P.setMinimized);yI(P,"setOverlayVisibility",P.setOverlayVisibility);yI(P,"confirmYpcRental",P.confirmYpcRental); yI(P,"queueNextVideo",P.queueNextVideo);yI(P,"handleExternalCall",P.handleExternalCall);yI(P,"logApiCall",P.logApiCall);yI(P,"isExternalMethodAvailable",P.isExternalMethodAvailable);yI(P,"setScreenLayer",P.setScreenLayer);yI(P,"getCurrentPlaylistSequence",P.getCurrentPlaylistSequence);yI(P,"getPlaylistSequenceForTime",P.getPlaylistSequenceForTime);yI(P,"shouldSendVisibilityState",P.shouldSendVisibilityState);yI(P,"syncVolume",P.syncVolume);yI(P,"highlightSettingsMenuItem",P.highlightSettingsMenuItem); yI(P,"openSettingsMenuItem",P.openSettingsMenuItem);yI(P,"getEmbeddedPlayerResponse",P.getEmbeddedPlayerResponse);yI(P,"getVisibilityState",P.getVisibilityState);yI(P,"isMutedByMutedAutoplay",P.isMutedByMutedAutoplay);P.V("embeds_enable_emc3ds_muted_autoplay")&&yI(P,"isMutedByEmbedsMutedAutoplay",P.isMutedByEmbedsMutedAutoplay);yI(P,"setGlobalCrop",P.setGlobalCrop);yI(P,"setInternalSize",P.setInternalSize);yI(P,"setFauxFullscreen",P.setFauxFullscreen);yI(P,"setAppFullscreen",P.setAppFullscreen)}; AM=function(P,v,l){P=g.Fo(P.FE(),v);return l?(l.addOnDisposeCallback(P),null):P}; g.Yi=function(P,v,l){return P.app.N().Ro?v:g.uc("$DESCRIPTION\u00a0($SHORTCUT)",{DESCRIPTION:v,SHORTCUT:l})}; XX2=function(P){P.FE().element.setAttribute("aria-live","polite")}; g.b2=function(P,v){g.qh.call(this,P,v);Guw(this);fc(this,"addEventListener",this.Gt);fc(this,"removeEventListener",this.gv$);fc(this,"cueVideoByPlayerVars",this.Su);fc(this,"loadVideoByPlayerVars",this.S$J);fc(this,"preloadVideoByPlayerVars",this.ov0);fc(this,"loadVideoById",this.pA);fc(this,"loadVideoByUrl",this.aS);fc(this,"playVideo",this.tj);fc(this,"loadPlaylist",this.loadPlaylist);fc(this,"nextVideo",this.nextVideo);fc(this,"previousVideo",this.previousVideo);fc(this,"playVideoAt",this.playVideoAt); fc(this,"getVideoData",this.DB);fc(this,"seekBy",this.HXf);fc(this,"seekTo",this.wP3);fc(this,"showControls",this.showControls);fc(this,"hideControls",this.hideControls);fc(this,"cancelPlayback",this.cancelPlayback);fc(this,"getProgressState",this.getProgressState);fc(this,"isInline",this.isInline);fc(this,"setInline",this.setInline);fc(this,"setLoopVideo",this.setLoopVideo);fc(this,"getLoopVideo",this.getLoopVideo);fc(this,"getVideoContentRect",this.getVideoContentRect);fc(this,"getVideoStats",this.vD); fc(this,"getCurrentTime",this.KU);fc(this,"getDuration",this.E9);fc(this,"getPlayerState",this.HD);fc(this,"getVideoLoadedFraction",this.jw);fc(this,"mute",this.yJ);fc(this,"unMute",this.Uz);fc(this,"setVolume",this.Vz);fc(this,"loadModule",this.loadModule);fc(this,"unloadModule",this.unloadModule);fc(this,"getOption",this.oR);fc(this,"getOptions",this.getOptions);fc(this,"setOption",this.setOption);fc(this,"addCueRange",this.addCueRange);fc(this,"getDebugText",this.getDebugText);fc(this,"getStoryboardFormat", this.getStoryboardFormat);fc(this,"toggleFullscreen",this.toggleFullscreen);fc(this,"isFullscreen",this.isFullscreen);fc(this,"getPlayerSize",this.getPlayerSize);fc(this,"toggleSubtitles",this.toggleSubtitles);fc(this,"setCenterCrop",this.setCenterCrop);fc(this,"setFauxFullscreen",this.setFauxFullscreen);fc(this,"setSizeStyle",this.setSizeStyle);fc(this,"handleGlobalKeyDown",this.handleGlobalKeyDown);fc(this,"handleGlobalKeyUp",this.handleGlobalKeyUp);F62(this)}; g.xi=function(P){P=P.Oi();var v=P.NV.get("endscreen");return v&&v.yc()?!0:P.UC()}; g.pc=function(P,v){P.getPresentingPlayerType()===3?P.publish("mdxautoplaycancel"):P.C0("onAutonavCancelled",v)}; g.SH=function(P){var v=Lc(P.Oi());return P.app.fq&&!P.isFullscreen()||P.getPresentingPlayerType()===3&&v&&v.JI()&&v.Up()||!!P.getPlaylist()}; g.Gy=function(P,v){g.gd(P,"addEmbedsConversionTrackingParams",[v])}; g.BS=function(P){return(P=g.Xo(P.Oi()))?P.zs():{}}; g.BaP=function(P){P=(P=P.getVideoData())&&P.K;return!!P&&!(!P.audio||!P.video)&&P.mimeType!=="application/x-mpegURL"}; g.i2=function(P,v,l){P=P.S2().element;var e=Qv(P.children,function(h){h=Number(h.getAttribute("data-layer"));return l-h||1}); e<0&&(e=-(e+1));mS(P,v,e);v.setAttribute("data-layer",String(l))}; g.UR=function(P){var v=P.N();if(!v.GP)return!1;var l=P.getVideoData();if(!l||P.getPresentingPlayerType()===3)return!1;var e=(!l.isLiveDefaultBroadcast||v.V("allow_poltergust_autoplay"))&&!eH(l);e=l.isLivePlayback&&(!v.V("allow_live_autoplay")||!e);var h=l.isLivePlayback&&v.V("allow_live_autoplay_on_mweb");P=P.getPlaylist();P=!!P&&P.JI();var z=l.Pg&&l.Pg.playerOverlays||null;z=!!(z&&z.playerOverlayRenderer&&z.playerOverlayRenderer.autoplay);z=l.eg&&z;return!l.ypcPreview&&(!e||h)&&!g.ro(l.T1,"ypc")&& !P&&(!g.LP(v)||z)}; idx=function(P){P=P.app.yW();if(!P)return!1;var v=P.getVideoData();if(!v.K||!v.K.video||v.K.video.W<1080||v.XN)return!1;var l=/^qsa/.test(v.clientPlaybackNonce),e="r";v.K.id.indexOf(";")>=0&&(l=/^[a-p]/.test(v.clientPlaybackNonce),e="x");return l?(P.f0("iqss",{trigger:e},!0),!0):!1}; Zn=function(){OY.apply(this,arguments);this.requestHeaders={}}; a0=function(){jH||(jH=new Zn);return jH}; HS=function(P,v){v?P.requestHeaders.Authorization="Bearer "+v:delete P.requestHeaders.Authorization}; g.ER=function(P,v,l,e){e=e===void 0?!1:e;g.DW.call(this,v);var h=this;this.J=P;this.T1=e;this.S=new g.Z1(this);this.Wg=new g.mA(this,l,!0,void 0,void 0,function(){h.Jx()}); g.Z(this,this.S);g.Z(this,this.Wg)}; WS=function(P){var v=P.J.getRootNode();return P.J.V("web_enable_auto_pip")||P.J.V("web_enable_pip_on_miniplayer")||P.J.V("web_shorts_pip")?av(v):document}; UzD=function(P){P.K&&(document.activeElement&&g.Qc(P.element,document.activeElement)&&P.K.focus(),P.K.setAttribute("aria-expanded","false"),P.K=void 0);g.Bx(P.S);P.X=void 0}; OR=function(P,v,l){P.cV()?P.zG():P.uq(v,l)}; o0=function(P,v,l,e){e=new g.O({L:"div",z1:["ytp-linked-account-popup-button"],Yf:e,B:{role:"button",tabindex:"0"}});v=new g.O({L:"div",D:"ytp-linked-account-popup",B:{role:"dialog","aria-modal":"true",tabindex:"-1"},U:[{L:"div",D:"ytp-linked-account-popup-title",Yf:v},{L:"div",D:"ytp-linked-account-popup-description",Yf:l},{L:"div",D:"ytp-linked-account-popup-buttons",U:[e]}]});g.ER.call(this,P,{L:"div",D:"ytp-linked-account-popup-container",U:[v]},100);var h=this;this.dialog=v;g.Z(this,this.dialog); e.listen("click",function(){h.zG()}); g.Z(this,e);g.i2(this.J,this.element,4);this.hide()}; g.rd=function(P,v,l,e){g.DW.call(this,P);this.priority=v;l&&g.sR(this,l);e&&this.Dx(e)}; g.Mh=function(P,v,l,e){P=P===void 0?{}:P;v=v===void 0?[]:v;l=l===void 0?!1:l;e=e===void 0?!1:e;v.push("ytp-menuitem");var h=P;"role"in h||(h.role="menuitem");l||(h=P,"tabindex"in h||(h.tabindex="0"));P={L:l?"a":"div",z1:v,B:P,U:[{L:"div",D:"ytp-menuitem-icon",Yf:"{{icon}}"},{L:"div",D:"ytp-menuitem-label",Yf:"{{label}}"},{L:"div",D:"ytp-menuitem-content",Yf:"{{content}}"}]};e&&P.U.push({L:"div",D:"ytp-menuitem-secondary-icon",Yf:"{{secondaryIcon}}"});return P}; g.sR=function(P,v){P.updateValue("label",v)}; Ty=function(P){g.rd.call(this,g.Mh({"aria-haspopup":"true"},["ytp-linked-account-menuitem"]),2);var v=this;this.J=P;this.K=this.W=!1;this.LI=P.Kg();P.createServerVe(this.element,this,!0);this.C(this.J,"settingsMenuVisibilityChanged",function(l){v.qd(l)}); this.C(this.J,"videodatachange",this.Y);this.listen("click",this.onClick);this.Y()}; VI=function(P){return P?g.Jz(P):""}; dd=function(P){g.U.call(this);this.api=P}; P6=function(P){dd.call(this,P);var v=this;yI(P,"setAccountLinkState",function(l){v.setAccountLinkState(l)}); yI(P,"updateAccountLinkingConfig",function(l){v.updateAccountLinkingConfig(l)}); P.addEventListener("videodatachange",function(l,e){v.onVideoDataChange(e)}); P.addEventListener("settingsMenuInitialized",function(){v.menuItem=new Ty(v.api);g.Z(v,v.menuItem)})}; Zdu=function(P){this.api=P;this.W={}}; v6=function(P,v,l,e){v in P.W||(l=new g.tn(l,e,{id:v,priority:2,namespace:"appad"}),P.api.iC([l],1),P.W[v]=l)}; lU=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(this);g.Z(this,this.events);this.W=new Zdu(this.api);this.events.C(this.api,"legacyadtrackingpingreset",function(){v.W.W={}}); this.events.C(this.api,"legacyadtrackingpingchange",function(l){var e=v.W;v6(e,"part2viewed",1,0x8000000000000);v6(e,"engagedview",Math.max(1,l.TG*1E3),0x8000000000000);if(!l.isLivePlayback){var h=l.lengthSeconds*1E3;Rh(l)&&e.api.V("html5_shorts_gapless_ads_duration_fix")&&(h=e.api.getProgressState().seekableEnd*1E3-l.YW);v6(e,"videoplaytime25",h*.25,h);v6(e,"videoplaytime50",h*.5,h);v6(e,"videoplaytime75",h*.75,h);v6(e,"videoplaytime100",h,0x8000000000000);v6(e,"conversionview",h,0x8000000000000); v6(e,"videoplaybackstart",1,h);v6(e,"videoplayback2s",2E3,h);v6(e,"videoplayback10s",1E4,h)}}); this.events.C(this.api,g.Ce("appad"),this.K);this.events.C(this.api,g.fe("appad"),this.K)}; ECD=function(P,v,l){if(!(l in v))return!1;v=v[l];Array.isArray(v)||(v=[v]);v=g.N(v);for(l=v.next();!l.done;l=v.next()){l=l.value;var e={CPN:P.api.getVideoData().clientPlaybackNonce};l=g.Zq(l,e);e=void 0;e=e===void 0?!1:e;(e=lc(eI(l,j8a),l,e,"Active View 3rd Party Integration URL"))||(e=void 0,e=e===void 0?!1:e,e=lc(eI(l,ao9),l,e,"Google/YouTube Brand Lift URL"));e||(e=void 0,e=e===void 0?!1:e,e=lc(eI(l,HdD),l,e,"Nielsen OCR URL"));g.oO(l,void 0,e)}return!0}; eT=function(P,v){W6x(P,v).then(function(l){g.oO(v,void 0,void 0,l)})}; he=function(P,v){v.forEach(function(l){eT(P,l)})}; W6x=function(P,v){return g.pF(P.api.N())&&IZ(v)&&$N(v)?g.QW(P.api.N(),g.MA(P.api.getVideoData())).then(function(l){var e;l&&(e={Authorization:"Bearer "+l});return e},void 0):jN()}; OdB=function(P){dd.call(this,P);this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"videoready",function(v){if(P.getPresentingPlayerType()===1){var l,e,h={playerDebugData:{pmlSignal:!!((l=v.getPlayerResponse())==null?0:(e=l.adPlacements)==null?0:e.some(function(z){var m;return z==null?void 0:(m=z.adPlacementRenderer)==null?void 0:m.renderer})), contentCpn:v.clientPlaybackNonce}};g.$6("adsClientStateChange",h)}})}; z3=function(P){g.O.call(this,{L:"button",z1:["ytp-button"],B:{title:"{{title}}","aria-label":"{{label}}","data-priority":"2","data-tooltip-target-id":"ytp-autonav-toggle-button"},U:[{L:"div",D:"ytp-autonav-toggle-button-container",U:[{L:"div",D:"ytp-autonav-toggle-button",B:{"aria-checked":"true"}}]}]});this.J=P;this.K=[];this.W=!1;this.isChecked=!0;P.createClientVe(this.element,this,113681);this.C(P,"presentingplayerstatechange",this.GL);this.listen("click",this.onClick);this.J.N().V("web_player_autonav_toggle_always_listen")&& oCa(this);AM(P,this.element,this);this.GL()}; oCa=function(P){P.K.push(P.C(P.J,"videodatachange",P.GL));P.K.push(P.C(P.J,"videoplayerreset",P.GL));P.K.push(P.C(P.J,"onPlaylistUpdate",P.GL));P.K.push(P.C(P.J,"autonavchange",P.ev))}; s8u=function(P){P.isChecked=P.isChecked;P.cg("ytp-autonav-toggle-button").setAttribute("aria-checked",String(P.isChecked));var v=P.isChecked?"Reproducci\u00f3n autom\u00e1tica activada":"Reproducci\u00f3n autom\u00e1tica desactivada";P.updateValue("title",v);P.updateValue("label",v);P.J.RZ()}; rFx=function(P){return P.J.N().V("web_player_autonav_use_server_provided_state")&&vd(P.IV())}; Mc7=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"standardControlsInitialized",function(){var l=new z3(P);g.Z(v,l);P.po(l,"RIGHT_CONTROLS_LEFT")})}; mi=function(P,v){g.rd.call(this,g.Mh({role:"menuitemcheckbox","aria-checked":"false"}),v,P,{L:"div",D:"ytp-menuitem-toggle-checkbox"});this.checked=!1;this.enabled=!0;this.listen("click",this.onClick)}; Ry=function(P,v){P.checked=v;P.element.setAttribute("aria-checked",String(P.checked))}; TaD=function(P){var v=!P.N().q_&&P.getPresentingPlayerType()!==3;return P.isFullscreen()||v}; g.Qh=function(P,v,l,e){var h=P.currentTarget;if((l===void 0||!l)&&g.xU(P))return P.preventDefault(),!0;v.pauseVideo();P=h.getAttribute("href");g.sI(P,e,!0);return!1}; g.te=function(P,v,l){if(TF(v.N())&&v.getPresentingPlayerType()!==2){if(g.xU(l))return v.isFullscreen()&&!v.N().externalFullscreen&&v.toggleFullscreen(),l.preventDefault(),!0}else{var e=g.xU(l);e&&v.pauseVideo();g.sI(P,void 0,!0);e&&(g.rX(P),l.preventDefault())}return!1}; dzq=function(){var P=VcB.includes("es")?{L:"svg",B:{height:"100%",version:"1.1",viewBox:"0 0 36 36",width:"100%"},U:[{L:"path",QD:!0,B:{d:"M11,11 C9.89,11 9,11.9 9,13 L9,23 C9,24.1 9.89,25 11,25 L25,25 C26.1,25 27,24.1 27,23 L27,13 C27,11.9 26.1,11 25,11 L11,11 Z M17,17 L15.5,17 L15.5,16.5 L13.5,16.5 L13.5,19.5 L15.5,19.5 L15.5,19 L17,19 L17,20 C17,20.55 16.55,21 16,21 L13,21 C12.45,21 12,20.55 12,20 L12,16 C12,15.45 12.45,15 13,15 L16,15 C16.55,15 17,15.45 17,16 L17,17 L17,17 Z M24,17 L22.5,17 L22.5,16.5 L20.5,16.5 L20.5,19.5 L22.5,19.5 L22.5,19 L24,19 L24,20 C24,20.55 23.55,21 23,21 L20,21 C19.45,21 19,20.55 19,20 L19,16 C19,15.45 19.45,15 20,15 L23,15 C23.55,15 24,15.45 24,16 L24,17 L24,17 Z", fill:"#fff"}}]}:{L:"svg",B:{height:"100%",version:"1.1",viewBox:"0 0 36 36",width:"100%"},U:[{L:"path",QD:!0,B:{d:"M11,11 C9.9,11 9,11.9 9,13 L9,23 C9,24.1 9.9,25 11,25 L25,25 C26.1,25 27,24.1 27,23 L27,13 C27,11.9 26.1,11 25,11 L11,11 Z M11,17 L14,17 L14,19 L11,19 L11,17 L11,17 Z M20,23 L11,23 L11,21 L20,21 L20,23 L20,23 Z M25,23 L22,23 L22,21 L25,21 L25,23 L25,23 Z M25,19 L16,19 L16,17 L25,17 L25,19 L25,19 Z",fill:"#fff"}}]};P.D="ytp-subtitles-button-icon";return P}; yh=function(){return{L:"div",D:"ytp-spinner-container",U:[{L:"div",D:"ytp-spinner-rotator",U:[{L:"div",D:"ytp-spinner-left",U:[{L:"div",D:"ytp-spinner-circle"}]},{L:"div",D:"ytp-spinner-right",U:[{L:"div",D:"ytp-spinner-circle"}]}]}]}}; CH=function(P){if(document.createRange){var v=document.createRange();v&&(v.selectNodeContents(P),P=window.getSelection())&&(P.removeAllRanges(),P.addRange(v))}}; kD=function(P){var v=P.V("web_player_use_cinematic_label_2")?"Modo Ambiente":"Iluminaci\u00f3n cinem\u00e1tica";mi.call(this,v,g.fH.NL);var l=this;this.J=P;this.W=!1;this.K=new g.mr(function(){g.$k(l.element,"ytp-menuitem-highlighted")},0); this.LI=P.Kg();this.setIcon({L:"svg",B:{height:"24",viewBox:"0 0 24 24",width:"24"},U:[{L:"path",B:{d:"M21 7v10H3V7h18m1-1H2v12h20V6zM11.5 2v3h1V2h-1zm1 17h-1v3h1v-3zM3.79 3 6 5.21l.71-.71L4.5 2.29 3.79 3zm2.92 16.5L6 18.79 3.79 21l.71.71 2.21-2.21zM19.5 2.29 17.29 4.5l.71.71L20.21 3l-.71-.71zm0 19.42.71-.71L18 18.79l-.71.71 2.21 2.21z",fill:"white"}}]});this.subscribe("select",this.G,this);this.listen(gb,this.Y);g.Z(this,this.K)}; wb=function(P){dd.call(this,P);var v=this;this.W=!1;P.addEventListener("settingsMenuInitialized",function(){Ps6(v)}); P.addEventListener("highlightSettingsMenu",function(l){Ps6(v);var e=v.menuItem;l==="menu_item_cinematic_lighting"&&(g.kk(e.element,"ytp-menuitem-highlighted"),g.kk(e.element,"ytp-menuitem-highlight-transition-enabled"),e.K.start())}); yI(P,"updateCinematicSettings",function(l){v.updateCinematicSettings(l)})}; Ps6=function(P){P.menuItem||(P.menuItem=new kD(P.api),g.Z(P,P.menuItem),P.menuItem.b$(P.W))}; $D=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"applicationvideodatachange",function(l,e){v.L7(l,e)})}; Iy=function(P){dd.call(this,P);this.events=new g.Z1(P);g.Z(this,this.events);yI(P,"setCreatorEndscreenVisibility",this.setCreatorEndscreenVisibility.bind(this));yI(P,"setCreatorEndscreenHideButton",this.W.bind(this))}; DL=function(P,v,l,e){mi.call(this,"Volumen estable",g.fH.hY);g.kk(this.element,"ytp-drc-menu-item");this.LI=P.Kg();this.Y=v;this.W=l;this.hasDrcAudioTrack=e;P.addEventListener("videodatachange",this.K.bind(this));P.V("mta_drc_mutual_exclusion_removal")&&this.C(P,"onPlaybackAudioChange",this.K);P=this.W()===1&&this.hasDrcAudioTrack();this.setEnabled(this.hasDrcAudioTrack());this.setIcon({L:"svg",B:{height:"24",viewBox:"0 0 24 24",width:"24"},U:[{L:"path",B:{d:"M7 13H5v-2h2v2zm3-4H8v6h2V9zm3-3h-2v12h2V6zm3 2h-2v8h2V8zm3 2h-2v4h2v-4zm-7-7c-4.96 0-9 4.04-9 9s4.04 9 9 9 9-4.04 9-9-4.04-9-9-9m0-1c5.52 0 10 4.48 10 10s-4.48 10-10 10S2 17.52 2 12 6.48 2 12 2z", fill:"white"}}]});this.subscribe("select",this.G,this);Ry(this,P);this.LI.w9(this)}; nH=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);P.V("html5_show_drc_toggle")&&P.addEventListener("settingsMenuInitialized",function(){v.menuItem||(v.menuItem=new DL(v.api,v.setDrcUserPreference.bind(v),v.getDrcUserPreference.bind(v),v.K.bind(v)),g.Z(v,v.menuItem))}); yI(this.api,"setDrcUserPreference",function(e){v.setDrcUserPreference(e)}); yI(this.api,"getDrcUserPreference",function(){return v.getDrcUserPreference()}); yI(this.api,"hasDrcAudioTrack",function(){return v.K()}); var l;this.W=(l=g.au("yt-player-drc-pref"))!=null?l:1;this.updateEnvironmentData()}; N8=function(P){dd.call(this,P);var v=this;this.W={};this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"videodatachange",function(){v.onVideoDataChange()}); this.events.C(P,g.Ce("embargo"),function(l){v.api.ri(!0);var e,h=(e=v.W[l.id])!=null?e:[];e=g.N(h);for(h=e.next();!h.done;h=e.next()){var z=h.value;v.api.hideControls();v.api.VI("auth",2,"This video isn't available in your current playback area",bp({embargoed:1,id:l.id,idx:l.K,start:l.start}));h=void 0;(z=(h=z.embargo)==null?void 0:h.onTrigger)&&v.api.C0("innertubeCommand",z)}})}; vfx=function(P,v){var l;return(l=v.onEnter)==null?void 0:l.some(P.K)}; l9P=function(P,v){v=g.N(v);for(var l=v.next();!l.done;l=v.next()){l=l.value;var e=void 0,h=Number((e=l.playbackPosition)==null?void 0:e.utcTimeMillis)/1E3,z=void 0;e=h+Number((z=l.duration)==null?void 0:z.seconds);z="embargo_"+h;P.api.addUtcCueRange(z,h,e,"embargo",!1);l.onEnter&&(P.W[z]=l.onEnter.filter(P.K))}}; Je=function(P){dd.call(this,P);var v=this;this.W=[];this.events=new g.Z1(P);g.Z(this,this.events);yI(P,"addEmbedsConversionTrackingParams",function(l){v.api.N().qP&&v.addEmbedsConversionTrackingParams(l)}); this.events.C(P,"veClickLogged",function(l){v.api.hasVe(l)&&(l=my(l.visualElement.getAsJspb(),2),v.W.push(l))})}; ejy=function(P){dd.call(this,P);yI(P,"isEmbedsShortsMode",function(){return P.isEmbedsShortsMode()})}; hjx=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"initialvideodatacreated",function(l){xf(bs(),16623);v.W=g.pg();var e=P.N().Xf&&!l.Ro;if(sD(l)&&e){xf(bs(),27240,void 0,{implicitGestureType:"INTERACTION_LOGGING_GESTURE_TYPE_AUTOMATED"});if(l.getWatchNextResponse()){var h,z=(h=l.getWatchNextResponse())==null?void 0:h.trackingParams;z&&L6(z)}if(l.getPlayerResponse()){var m;(l=(m=l.getPlayerResponse())==null?void 0:m.trackingParams)&&L6(l)}}else xf(bs(), 32594,void 0,{implicitGestureType:"INTERACTION_LOGGING_GESTURE_TYPE_AUTOMATED"}),l.getEmbeddedPlayerResponse()&&(m=(z=l.getEmbeddedPlayerResponse())==null?void 0:z.trackingParams)&&L6(m)}); this.events.C(P,"loadvideo",function(){xf(bs(),27240,void 0,{implicitGestureType:"INTERACTION_LOGGING_GESTURE_TYPE_AUTOMATED",parentCsn:v.W})}); this.events.C(P,"cuevideo",function(){xf(bs(),32594,void 0,{implicitGestureType:"INTERACTION_LOGGING_GESTURE_TYPE_AUTOMATED",parentCsn:v.W})}); this.events.C(P,"largeplaybuttonclicked",function(l){xf(bs(),27240,l.visualElement)}); this.events.C(P,"playlistnextbuttonclicked",function(l){xf(bs(),27240,l.visualElement)}); this.events.C(P,"playlistprevbuttonclicked",function(l){xf(bs(),27240,l.visualElement)}); this.events.C(P,"playlistautonextvideo",function(){xf(bs(),27240,void 0,{implicitGestureType:"INTERACTION_LOGGING_GESTURE_TYPE_AUTOMATED"})})}; uU=function(P,v){g.U.call(this);var l=this;this.W=null;this.G=v;v=[];for(var e=0;e<=100;e++)v.push(e/100);v={threshold:v,trackVisibility:!0,delay:1E3};(this.K=window.IntersectionObserver?new IntersectionObserver(function(h){h=h[h.length-1];typeof h.isVisible==="undefined"?document.visibilityState==="visible"&&h.isIntersecting&&h.intersectionRatio>0?l.W=h.intersectionRatio:document.visibilityState==="hidden"?l.W=0:l.W=null:l.W=h.isVisible?h.intersectionRatio:0;typeof l.G==="function"&&l.G(l.W)},v): null)&&this.K.observe(P)}; mEy=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"applicationInitialized",function(){zjB(v)})}; zjB=function(P){var v=P.api.getRootNode(),l=v;if(!P.api.V("embeds_emc3ds_inview_ks")){var e;l=P.api.getWebPlayerContextConfig().embedsEnableEmc3ds?((e=v.parentElement)==null?void 0:e.parentElement)||v:v}P.W=new uU(l,function(h){h!=null&&(P.api.N().yY=h,P.api.N().h1="EMBEDDED_PLAYER_VISIBILITY_FRACTION_SOURCE_INTERSECTION_OBSERVER")}); g.Z(P,P.W);P.events.C(P.api,"videoStatsPingCreated",function(h){var z=P.W;z=z.W==null?null:Math.round(z.W*100)/100;h.inview=z!=null?z:void 0;z=P.api.getPlayerSize();if(z.height>0&&z.width>0){z=[Math.round(z.width),Math.round(z.height)];var m=g.d7();m>1&&z.push(m);z=z.join(":")}else z=void 0;h.size=z})}; Rj9=function(P){var v;return((v=((P==null?void 0:P.messageRenderers)||[]).find(function(l){return!!l.timeCounterRenderer}))==null?void 0:v.timeCounterRenderer)||null}; KH=function(P){g.O.call(this,{L:"div",z1:["ytp-player-content","ytp-iv-player-content"],U:[{L:"div",D:"ytp-free-preview-countdown-timer",U:[{L:"span",Yf:"{{label}}"},{L:"span",D:"ytp-free-preview-countdown-timer-separator",Yf:"\u2022"},{L:"span",Yf:"{{duration}}"}]}]});this.api=P;this.W=null;this.G=this.K=0;this.C(this.api,"videodatachange",this.onVideoDataChange);this.api.createClientVe(this.element,this,191284)}; tnu=function(P,v){P.W||(P.K=v,P.G=(0,g.Gz)(),P.W=new g.zl(function(){QJy(P)},null),QJy(P))}; QJy=function(P){var v=Math,l=v.round,e=Math.min((0,g.Gz)()-P.G,P.K);v=l.call(v,(P.K-e)/1E3);P.updateValue("duration",us({seconds:v}));v<=0&&P.W?c6(P):P.W&&P.W.start()}; c6=function(P){P.W&&(P.W.dispose(),P.W=null)}; yby=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"basechromeinitialized",function(){v.W=new KH(P);g.Z(v,v.W);g.i2(P,v.W.element,4);v.W.hide()})}; q8=function(P){g.O.call(this,{L:"button",z1:["ytp-fullerscreen-edu-button","ytp-button"],U:[{L:"div",z1:["ytp-fullerscreen-edu-text"],Yf:"Desliza hacia abajo para ver m\u00e1s detalles"},{L:"div",z1:["ytp-fullerscreen-edu-chevron"],U:[{L:"svg",B:{height:"100%",viewBox:"0 0 24 24",width:"100%"},U:[{L:"path",B:{d:"M7.41,8.59L12,13.17l4.59-4.58L18,10l-6,6l-6-6L7.41,8.59z",fill:"#fff"}}]}]}],B:{"data-priority":"1"}});this.j2=P;this.W=new g.mA(this,250,void 0,100);this.G=this.K=!1;P.createClientVe(this.element, this,61214);g.Z(this,this.W);this.C(P,"fullscreentoggled",this.b$);this.C(P,"presentingplayerstatechange",this.b$);this.listen("click",this.onClick);this.b$()}; FO=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);yI(this.api,"updateFullerscreenEduButtonSubtleModeState",function(e){v.updateFullerscreenEduButtonSubtleModeState(e)}); yI(this.api,"updateFullerscreenEduButtonVisibility",function(e){v.updateFullerscreenEduButtonVisibility(e)}); var l=P.N();P.V("external_fullscreen_with_edu")&&l.externalFullscreen&&TF(l)&&l.controlsType==="1"&&this.events.C(P,"standardControlsInitialized",function(){v.W=new q8(P);g.Z(v,v.W);P.po(v.W)})}; Cs7=function(P){g.O.call(this,{L:"div",D:"ytp-gated-actions-overlay",U:[{L:"div",D:"ytp-gated-actions-overlay-background",U:[{L:"div",D:"ytp-gated-actions-overlay-background-overlay"}]},{L:"button",z1:["ytp-gated-actions-overlay-miniplayer-close-button","ytp-button"],B:{"aria-label":"Cerrar"},U:[g.Fq()]},{L:"div",D:"ytp-gated-actions-overlay-bar",U:[{L:"div",D:"ytp-gated-actions-overlay-text-container",U:[{L:"div",D:"ytp-gated-actions-overlay-title",Yf:"{{title}}"},{L:"div",D:"ytp-gated-actions-overlay-subtitle", Yf:"{{subtitle}}"}]},{L:"div",D:"ytp-gated-actions-overlay-button-container"}]}]});var v=this;this.api=P;this.background=this.cg("ytp-gated-actions-overlay-background");this.K=this.cg("ytp-gated-actions-overlay-button-container");this.W=[];this.C(this.cg("ytp-gated-actions-overlay-miniplayer-close-button"),"click",function(){v.api.C0("onCloseMiniplayer")}); this.hide()}; gfw=function(P,v){var l=0;l=0;for(var e={};l h&&(h=Q.width,z="url("+Q.url+")")}l.background.style.backgroundImage=z;gfw(l,e.actionButtons||[]);l.show()}else l.hide()}); g.i2(this.api,this.W.element,4)}; Ae=function(P){dd.call(this,P);var v=this;fc(this.api,"getSphericalProperties",function(){return v.getSphericalProperties()}); fc(this.api,"setSphericalProperties",function(){v.setSphericalProperties.apply(v,g.u(g.bD.apply(0,arguments)))}); Cc(this.api,"getSphericalProperties",function(){return v.api.getPresentingPlayerType()===2?{}:v.getSphericalProperties()}); Cc(this.api,"setSphericalProperties",function(){var l=g.bD.apply(0,arguments);v.api.getPresentingPlayerType()!==2&&v.setSphericalProperties.apply(v,g.u(l))})}; YD=function(P){dd.call(this,P);yI(P,"createClientVe",this.createClientVe.bind(this));yI(P,"createServerVe",this.createServerVe.bind(this));yI(P,"destroyVe",this.destroyVe.bind(this));yI(P,"hasVe",this.hasVe.bind(this));yI(P,"logClick",this.logClick.bind(this));yI(P,"logVisibility",this.logVisibility.bind(this));yI(P,"setTrackingParams",this.setTrackingParams.bind(this))}; bU=function(P,v,l,e){function h(m){var Q=!(m.status!==204&&m.status!==200&&!m.response),t;m={succ:""+ +Q,rc:m.status,lb:((t=m.response)==null?void 0:t.byteLength)||0,rt:((0,g.Gz)()-z).toFixed(),shost:g.Hl(P),trigger:v};w1D(m,P);l&&l(m);e&&!Q&&e(new xq("pathprobe.net",m))} var z=(0,g.Gz)();g.SN(P,{format:"RAW",responseType:"arraybuffer",timeout:1E4,onFinish:h,onTimeout:h})}; w1D=function(P,v){var l;((l=window.performance)==null?0:l.getEntriesByName)&&(v=performance.getEntriesByName(v))&&v.length&&(v=v[0],P.pedns=(v.domainLookupEnd-v.startTime).toFixed(),P.pecon=(v.connectEnd-v.domainLookupEnd).toFixed(),P.perqs=(v.requestStart-v.connectEnd).toFixed(),$Ex&&(P.perqsa=v.requestStart+(performance.timeOrigin||performance.timing.navigationStart)))}; xD=function(P,v){this.Ob=P;this.policy=v;this.playbackRate=1}; I9a=function(P,v){var l=Math.min(2.5,KP(P.Ob));P=pH(P);return v-l*P}; LH=function(P,v,l,e,h){h=h===void 0?!1:h;if(P.policy.BU)return Math.ceil(P.policy.BU*v);P.policy.Nq&&(e=Math.abs(e));e/=P.playbackRate;var z=1/Fu(P.Ob);l=Math.max(.9*(e-3),KP(P.Ob)+P.Ob.K.W*z)/z*.8/(v+l);l=Math.min(l,e);P.policy.VK>0&&h&&(l=Math.max(l,P.policy.VK));return DED(P,l,v)}; DED=function(P,v,l){return Math.ceil(Math.max(Math.max(P.policy.RO,P.policy.E6*l),Math.min(Math.min(P.policy.q5,31*l),Math.ceil(v*l))))||P.policy.RO}; nfD=function(P,v,l){l=LH(P,v.W.info.FJ,l.W.info.FJ,0);var e=KP(P.Ob)+l/Fu(P.Ob);return Math.max(e,e+P.policy.hf-l/v.W.info.FJ)}; pH=function(P){return Fu(P.Ob,!P.policy.jb,P.policy.ke)}; ST=function(P){return pH(P)/P.playbackRate}; G3=function(P,v,l){var e=P.policy.playbackStartPolicy.resumeMinReadaheadPolicy||[],h=P.policy.playbackStartPolicy.startMinReadaheadPolicy||[];P=Infinity;v=g.N(v&&e.length>0?e:h);for(e=v.next();!e.done;e=v.next())e=e.value,h=e.minReadaheadMs||0,l<(e.minBandwidthBytesPerSec||0)||P>h&&(P=h);return P 0&&(this.K=l.q1)}; Kkq=function(P,v,l,e,h){if(!e.info.Y){if(l.length===0)l.push(e);else{var z;(P=(z=l.pop())==null?void 0:g.lM(z,e))?l.push(P):l.push(e)}return h}var m;(l=(m=l.pop())==null?void 0:g.lM(m,e))||(l=e);if(P.policy.MV&&l.info.K)return P.logger&&P.logger({incompleteSegment:l.info.WR()}),h;m=P.s1(l);e=m.formatId;h=m.n0;l=m.clipId;z=m.LC;m=m.startTimeMs;if(!P.policy.Xf&&P.policy.K&&P.PR){var Q=B6(P.PR,l);m+=Q}e={clipId:l,formatId:e,startTimeMs:m,durationMs:z,vV:h,IY:h,uJ:m,jR:z};h=NIw(v,e.startTimeMs);(l=h>= 0?v[h]:null)&&JbD(P,l,e)?e=l:(h+=1,v.splice(h,0,e));l=0;for(z=h+1;z =y+m.K?m=!0:C+m.K =0?P:-P-2}; cbw=function(P,v){if(P.mZ){var l=P.mZ.Io();if(l.length!==0){if(P.G&&v){var e=P.G,h=e.info.ao;!C0(l,h)&&e.info.T>0&&(0,g.Gz)()-P.T<5E3&&(P.logger&&P.logger({dend:e.info.WR()}),l=ISa(l,h,h+.01))}P.policy.UL&&P.logger&&P.logger({cbri:""+P.W});e=[];for(var z=h=0;h =m){var C=0;if(P.PR){var f=iU(P.PR,t*1E3);f&&(C=f.zr/1E3)}f=Object.assign({},P.hR[z]);var k=P.rM.G.get(Y2(P.hR[z].formatId)), w=Math.max(t,m);m=k.index.lh(w+P.K/1E3-C);t=k.index.getStartTime(m)+C;var I=m+ +(Math.abs(t-w)>P.K/1E3);w=I+P.Y;I=(k.index.getStartTime(I)+C)*1E3;z!==P.W||v?(f.vV=w,f.startTimeMs=I):(P.logger&&P.logger({pEvict:"1",og:f.startTimeMs,adj:t*1E3}),f.vV=m+P.Y,f.startTimeMs=t*1E3);f.uJ=f.startTimeMs;m=void 0;t=((m=P.G)==null?void 0:m.info.duration)||11;z===P.W&&Q P.K/1E3);m=t+P.Y;C=(k.index.f3(t)+C)*1E3;f.IY=m;f.durationMs=C-f.startTimeMs;f.jR=f.durationMs;f.vV<=f.IY&&e.push(f)}y P.K)return!1;if(uPu(P,v.formatId,l.formatId))return v.durationMs=Math.max(e,h)-v.startTimeMs,v.jR=v.durationMs,v.IY=Math.max(v.IY,l.IY),!0;if(Math.abs(v.startTimeMs-l.startTimeMs)<=P.K){if(v.durationMs>l.durationMs+P.K){P=v.formatId;var z=v.vV,m=v.IY;v.formatId=l.formatId;v.durationMs=l.durationMs;v.vV=l.vV;v.jR=l.durationMs;v.IY=l.IY;l.formatId=P;l.startTimeMs=h;l.uJ=h;l.durationMs=e-h;l.jR=l.durationMs; l.vV=z;l.IY=m;return!1}v.formatId=l.formatId;return!0}e>l.startTimeMs&&(v.durationMs=l.startTimeMs-v.startTimeMs,v.jR=v.durationMs,P.policy.E5&&v.clipId===l.clipId&&(v.IY=l.vV-1));return!1}; uPu=function(P,v,l){return v.itag!==l.itag||v.xtags!==l.xtags?!1:P.rM.Ei||v.lmt===l.lmt}; AbD=function(P,v,l){if(P.logger){for(var e=[],h=0;h=0&&H6(P.audioTrack,P.W)>=0&&z?((P.videoTrack.Z||P.audioTrack.Z)&&P.K0.f0("iterativeSeeking",{status:"done",count:P.seekCount}),P.videoTrack.Z=!1,P.audioTrack.Z=!1):e&&g.w5(function(){if(P.K||!P.policy.TG)Oe(P);else{var m=v.startTime,Q=v.duration;if(!P.policy.T){var t=l?P.videoTrack.Z:P.audioTrack.Z,y=P.videoTrack.T!==-1&&P.audioTrack.T!==-1,C=P.W>=m&&P.W 432E3&&Pm9(P.rM);P.G&&(h=P.G,P.G=0);g.w5(function(){P.policy.T||oy(P,h,102)}); P.K0.f0("initManifestlessSync",{st:h,ost:h+P.K0.fh(),a:P.audioTrack.T,v:P.videoTrack.T});P.Y&&(P.Y.resolve(h+.1),P.Y=null);P.policy.T&&oy(P,h,102)}}}; M8=function(P,v){var l=this;this.Md=P;this.requestNumber=++i62;this.W=this.now();this.X=this.Wg=NaN;this.j=this.W;this.G=this.It=this.Z=0;this.T=this.W;this.Pg=this.S=this.T1=this.Xq=this.Nd=this.kf=this.K=this.Y=0;this.QW=this.isActive=!1;this.TG=this.U$=0;this.Kh={YX6:function(){return l.QQ}}; this.Ob=v.Ob;this.snapshot=Uku(this.Ob);this.policy=this.Ob.K;this.Lk=!!v.Lk;this.u_=v.u_;this.sY=v.sY||0;this.aY=v.aY||0;v.Ie&&(this.wM=new kQ);var e;this.QQ=(e=v.QQ)!=null?e:!1;this.Lk||XPq(this.Ob)}; UEy=function(P){P.T1=Math.max(P.T1,P.Z-P.Nd);P.S=Math.max(P.S,P.j-P.Xq);P.kf=0}; T3=function(P,v,l){BZ2(P.Ob,v);P.wM&&(P.wM.add(Math.ceil(v)-Math.ceil(P.j)),P.wM.add(Math.max(0,Math.ceil(l/1024)-Math.ceil(P.Z/1024))));var e=v-P.j,h=l-P.Z;P.It=h;P.Pg=Math.max(P.Pg,h/(e+.01)*1E3);P.j=v;P.Z=l;P.kf&&l>P.kf&&UEy(P)}; Vh=function(P,v){P.url=v;window.performance&&!performance.onresourcetimingbufferfull&&(performance.onresourcetimingbufferfull=function(){performance.clearResourceTimings()})}; db=function(P,v){M8.call(this,P,v);this.nI=this.jS=!1;this.q5=this.J5=Infinity;this.Ic=NaN;this.WK=!1;this.D3=NaN;this.CI=this.Hg=this.h5=0;this.Sf=v.Sf||1;this.G4=v.G4||this.Sf;this.HT=v.HT;this.n0=v.n0;this.WB=v.WB;Z6w(this);this.hj(this.W);this.Bg=(this.D3-this.W)/1E3}; jJw=function(P){var v=P.Hg||P.h5;return v?P.snapshot.delay+Math.min(P.aY,(P.X-P.Wg)/1E3)+v:P.Bg}; P8=function(P,v,l){if(!P.Lk){v=Math.max(v,.01);var e=P.sY?Math.max(v,l/P.sY):v,h=P.Ob.K.G;h&&(e=v,P.sY&&(e=Math.max(v,l/P.sY*h)));Ny(P.Ob,v,l,e)}}; a9u=function(P){return(P.T-P.W)/1E3}; Z6w=function(P){P.Ic=P.W+P.snapshot.delay*1E3;P.WK=!1}; v8=function(P,v){if(P.HT&&P.n0!==void 0&&P.WB!==void 0){var l=Math,e=l.min,h=P.J5;var z=P.HT;var m=P.W;if(H6x(z,P.n0))z=v;else{var Q=0;z.dH&&(Q=.2);z=m+(z.aY+Q)*1E3}P.J5=e.call(l,h,z);l=Math;e=l.min;h=P.q5;z=P.HT;m=P.W;Q=Efy(z,P.n0,P.WB);Q!==2&&(v=Q?v:m+z.aY*1E3,z.dH&&(v+=z.aY*1E3));P.q5=e.call(l,h,v);P.J5<=P.W?Z6w(P):(P.Ic=P.J5,P.WK=!0)}}; Wkx=function(P,v){if(P.Du(v,1)){var l=P.getUint8(v);l=l<128?1:l<192?2:l<224?3:l<240?4:5}else l=0;if(l<1||!P.Du(v,l))return[-1,v];if(l===1)P=P.getUint8(v++);else if(l===2)l=P.getUint8(v++),P=P.getUint8(v++),P=(l&63)+64*P;else if(l===3){l=P.getUint8(v++);var e=P.getUint8(v++);P=P.getUint8(v++);P=(l&31)+32*(e+256*P)}else if(l===4){l=P.getUint8(v++);e=P.getUint8(v++);var h=P.getUint8(v++);P=P.getUint8(v++);P=(l&15)+16*(e+256*(h+256*P))}else l=v+1,P.focus(l),F$(P,l,4)?P=LXu(P).getUint32(l-P.Sb,!0):(e= P.getUint8(l+2)+256*P.getUint8(l+3),P=P.getUint8(l)+256*(P.getUint8(l+1)+256*e)),v+=5;return[P,v]}; lu=function(P){this.Md=P;this.W=new uh}; eX=function(P,v){this.info=P;this.callback=v;this.state=1;this.vE=this.Cf=!1;this.KX=null}; O6D=function(P){return g.SK(P.info.N5,function(v){return v.type===3})}; hy=function(P,v,l,e){var h=this;e=e===void 0?{}:e;this.policy=v;this.Md=l;this.status=0;this.W=new uh;this.K=0;this.s$=this.Y=this.G=!1;this.xhr=new XMLHttpRequest;this.xhr.open(e.method||"GET",P);if(e.headers)for(P=e.headers,v=g.N(Object.keys(P)),l=v.next();!l.done;l=v.next())l=l.value,this.xhr.setRequestHeader(l,P[l]);this.xhr.withCredentials=!0;this.xhr.onreadystatechange=function(){return h.zC()}; this.xhr.onload=function(){return h.onDone()}; this.xhr.onerror=function(){return h.onError()}; this.xhr.fetch(function(z){h.W.append(z);h.K+=z.length;z=(0,g.Gz)();h.Md.Xd(z,h.K)},function(){},e.body||null)}; ofD=function(P,v){this.K=(new TextEncoder).encode(P);this.W=(new TextEncoder).encode(v)}; M5P=function(P,v){var l,e,h;return g.p(function(z){if(z.W==1){if(!v)return z.return(v);l=zG.TO();e=new g.FY(P.K);return g.b(z,e.encrypt(v,P.W),2)}h=z.K;zG.Bj("woe",l,Math.ceil(v.byteLength/16));return z.return(h)})}; vjy=function(P,v){var l,e,h;return g.p(function(z){if(z.W==1){if(!v)return z.return(v);l=zG.TO();e=new g.FY(P.K);return g.b(z,e.decrypt(v,P.W),2)}h=z.K;zG.Bj("wod",l,Math.ceil(v.byteLength/16));return z.return(h)})}; rbP=function(P,v){var l=this;this.W=P;this.Md=v;this.loaded=this.status=0;this.error="";P=po(this.W.get("range")||"");if(!P)throw Error("bad range");this.range=P;this.K=new uh;sJ2(this).then(function(){l.Md.h6()},function(e){l.error=""+e||"unknown_err"; l.Md.h6()})}; sJ2=function(P){var v,l,e,h,z,m,Q,t,y,C,f,k,w,I,J;return g.p(function(K){if(K.W==1){P.status=200;v=P.W.get("docid");l=dO(P.W.get("fmtid")||"");e=P.W.get("lmt")||"0";h=+(P.W.get("csz")||0);if(!v||!l||!h)throw Error("Invalid local URL");P.W.get("ck")&&P.W.get("civ")&&(z=new ofD(P.W.get("ck"),P.W.get("civ")));m=P.range;Q=Math.floor(m.start/h);t=Math.floor(m.end/h);y=Q}if(K.W!=5)return y<=t?g.b(K,lZq(v,l,e,y,z),5):K.ac(0);C=K.K;if(C===void 0)throw Error("invariant: data is undefined");f=y*h;k=(y+1)*h; w=Math.max(0,m.start-f);I=Math.min(m.end+1,k)-(w+f);J=new Uint8Array(C.buffer,w,I);P.K.append(J);P.loaded+=I;P.loaded 0&&(h.W=Math.min(h.W+m,10),h.K=z);h.W>0?(h.W--,h=!0):h=!1;if(h)typeof e==="function"&&(e=e()),console.log("plyr."+v,e);else{var Q;e=((Q=hGy.get(v))!=null?Q:0)+1;hGy.set(v,e);e%100===1&&console.warn("plyr","plyr."+v+" is chatty, dropping logs.")}}}; eGD=function(){this.W=10;this.K=Date.now()}; ty=function(P,v){g.U.call(this);var l=this;this.policy=P;this.N5=v;this.K=0;this.W=null;this.mx=[];this.G=null;this.Kh={D7:function(){return l.N5}}; this.N5.length===1||g.SK(this.N5,function(e){return!!e.range})}; yJ=function(P,v,l){P.W&&(Ka(P.W,v),v=P.W,P.W=null);for(var e=0,h=0,z=g.N(P.N5),m=z.next();!m.done;m=z.next())if(m=m.value,m.range&&e+m.G<=P.K)e+=m.G;else{v.getLength();if(XI(m)&&!l&&P.K+v.getLength()-h =400?(P.lastError="net.badstatus",!0):(h===void 0?0:h)?(P.lastError="ump.spsrejectfailure",!0):l||e!==void 0&&e?!1:(P.lastError=v===204?"net.nocontent":"net.connect",!0)}; $v=function(P,v){if(P.policy.e0)return!1;var l=v.getResponseHeader("content-type"),e=v.KH();P=!e||e<=P.policy.ET;return(!v.DC()||!l||l.indexOf("text/plain")!==-1)&&P}; yRB=function(P,v){var l="";v=v.vu();v.getLength()<=P.policy.ET&&(l=tM2(P,v.Yt()));return l}; tM2=function(P,v){var l=bh(v);return zw(l)?(P.logger.debug(function(){return"Redirecting to "+l}),l):""}; f5=function(P){return ud(P.G,AR(P.K6.P9))}; Cgx=function(P){var v=P.timing.WI();v.shost=AR(P.K6.P9);return v}; fhw=function(P,v){return(P==null?void 0:P.maxWidth)>(v==null?void 0:v.maxWidth)||(P==null?void 0:P.maxHeight)>(v==null?void 0:v.maxHeight)}; g_2=function(P,v){for(var l=g.N(v.keys()),e=l.next();!e.done;e=l.next())if(e=v.get(e.value),e.length!==0){g.tK(e,function(Q,t){return t.maxFramerate-Q.maxFramerate}); for(var h=[e[0]],z=0,m=1;m P.W||l.push(e)}return l}; If=function(P,v,l){var e=$9w[P]||[];l.V("html5_shorts_onesie_mismatched_fix")&&(e=IhD[P]||[]);v.push.apply(v,g.u(e));l.V("html5_early_media_for_drm")&&v.push.apply(v,g.u(D9y[P]||[]))}; cRW=function(P,v){var l=g.Cj(P),e=P.N(),h=e.Z;e=e.V("html5_shorts_onesie_mismatched_fix");var z=P.Go();if(e){if(!h.G){if(z&&DC)return DC;if(n5)return n5}}else if(n5&&!h.G)return n5;var m=[],Q=[],t={},y=Nn.concat(n_w);e&&(y=Nn.concat(NGy));P.V("html5_early_media_for_drm")&&(y=y.concat(JRB),P.V("allow_vp9_1080p_mq_enc")&&y.push(uZW));var C=[].concat(g.u(K4q));if(l.X)for(var f=0;f l.gH)){var J=g.ID(P.N().experiments,"html5_drm_byterate_soft_cap");J>0&&w$W(I)&&I.FJ>J||(f?(m.push(w),If(w,m,P)):(I=Ia(l,I,h),I===!0?(f=!0,m.push(w),If(w,m,P)):t[w]=I))}}}C=g.N(C);for(y=C.next();!y.done;y=C.next())for(y=g.N(y.value),f=y.next();!f.done;f=y.next())if(f= f.value,(k=Q2q(f))&&k.audio&&(P.V("html5_onesie_51_audio")||!VT(k)&&!dl(k)))if(k=Ia(l,k,h),k===!0){Q.push(f);If(f,Q,P);break}else t[f]=k;l.K&&v("orfmts",t);if(e)return h.G&&(h.G=!1,DC=n5=void 0),z?DC={video:m,audio:Q}:n5={video:m,audio:Q};n5={video:m,audio:Q};h.G=!1;return n5}; g.AR6=function(P,v,l){var e=l.Z,h=[],z=[],m=l.V("html5_shorts_onesie_mismatched_fix");P=P.Go();var Q=Nn.concat(n_w);m&&(Q=Nn.concat(NGy));l.V("html5_early_media_for_drm")&&(Q=Q.concat(JRB),l.V("allow_vp9_1080p_mq_enc")&&Q.push(uZW));var t=[].concat(g.u(K4q));if(v.X)for(var y=0;y 0&&w$W(f)&&f.FJ>k)&&Ia(v,f,e)===!0){h.push({videoCodec:q_a[oS[C]],maxWidth:f.video.width,maxHeight:f.video.height,maxFramerate:f.video.fps});break}}}}m=g.N(t);for(P=m.next();!P.done;P=m.next())for(P=g.N(P.value),t=P.next();!t.done;t=P.next())if(t=t.value,(Q=Q2q(t))&&Q.audio&&(l.V("html5_onesie_51_audio")||!VT(Q)&&!dl(Q))&&Ia(v,Q,e)=== !0){z.push({audioCodec:F4W[oS[t]],numChannels:Q.audio.numChannels});break}return{videoFormatCapabilities:h,audioFormatCapabilities:z}}; Jy=function(P){var v={},l=P.M5,e=P.Z3,h=l.getVideoData(),z=aJ(0),m=l.getPlayerSize(),Q=l.getVisibilityState();z&&(v.R6$=z,v.lastManualDirection=KsW(),z=d7D()||0,z>0&&(z=(e.V("html5_use_date_now_for_local_storage")?Date.now():(0,g.Gz)())-z,e.V("html5_use_date_now_for_local_storage")?z>0&&(v.timeSinceLastManualFormatSelectionMs=z):v.timeSinceLastManualFormatSelectionMs=z));v.OJf=aJ();z=e.V("html5_use_streamer_bandwidth_for_low_latency_live")&&h.isLowLatencyLiveStream;if(e.schedule.Wg&&!z){var t;z=e.V("html5_disable_bandwidth_cofactors_for_sabr_live")? !((t=P.iq)==null||!t.jb):!1;v.cS=Fu(e.schedule,!z)}t=g.d7();var y=g.Hz.medium,C=Math.floor(y*16/9);z=h.Go()?y:C;y=h.Go()?C:y;v.ju=Math.max(m.width*t,z);v.rg=Math.max(m.height*t,y);v.visibility=Q;v.kAM=Ly();v.Z6=l.HI()*1E3;var f;if((f=P.iq)==null?0:f.Jn){m=P.M5.ST(!0);var k,w,I,J,K,q;v.e3M={defaultPolicy:((k=m.Oy)==null?void 0:k.W)||0,smooth:((w=m.NzM)==null?void 0:w.W)||0,visibility:((I=m.SR0)==null?void 0:I.W)||0,He:((J=m.sy)==null?void 0:J.W)||0,performance:((K=m.Eo)==null?void 0:K.W)||0,speed:((q= m.Bz5)==null?void 0:q.W)||0}}else{var A;if((A=P.iq)==null?0:A.NH){var x;v.CT=((x=P.M5.ST().Eo)==null?void 0:x.W)||0}}e.V("html5_enable_sabr_drm_hd720p")&&P.sabrLicenseConstraint&&(v.sabrLicenseConstraint=P.sabrLicenseConstraint);if(e.V("html5_onesie_media_capabilities")||e.V("html5_enable_server_format_filter"))v.iF=3;e.V("html5_onesie_audio_only_playback")&&Qi(h)&&(v.iF=1);var S;((S=P.iq)==null?0:S.yY)&&h.Ei()&&P.uJM&&(v.iF=v.iF===void 0?7:v.iF|4);k=h.Hl?h.Hl:g.Cj(h);e.V("html5_onesie_media_capabilities")&& (v.mediaCapabilities=g.AR6(h,k,e));var B;if((B=P.iq)==null?0:B.W&&B.Ro){I=e.Z;B=[];w=[];J=new Map;e.V("html5_ssap_update_capabilities_on_change")?(I.X||bMu(I),K=I.X||[]):K=Array.from(I.W.values());K=g.N(K);for(q=K.next();!q.done;q=K.next())S=q.value,S.h3?w.push({audioCodec:F4W[S.dM],numChannels:S.numChannels,spatialCapabilityBitmask:Y_u[S.dM]}):(m=q_a[S.dM],q={videoCodec:m,maxWidth:S.maxWidth||0,maxHeight:S.maxHeight||0,maxFramerate:S.maxFramerate||0,is10BitSupported:S.dC||!1},S.maxBitrateBps&&(q.maxBitrateBps= S.maxBitrateBps,Q=t0(S.itag),f=void 0,((f=Q)==null?0:f.video)&&Ia(k,Q,I)===!0&&(Q=Q.FJ*8,Q>q.maxBitrateBps&&(q.maxBitrateBps=Q))),S=m+"_"+S.dC,m=J.get(S)||[],m.push(q),J.set(S,m));B=g_2(B,J);I={};e.V("html5_ssff_denylist_opus_low")&&(I={itagDenylist:[249,350]});v.mediaCapabilities={videoFormatCapabilities:B,audioFormatCapabilities:w,hdrModeBitmask:3,perPlaybackAttributes:I}}var E;if((E=P.iq)==null?0:E.W){v.ek=k.ek;var r;v.gH=(r=P.iq)==null?void 0:r.gH}e.vl&&(v.YQ=e.vl);v.n8=P.rV;v.sx=P.sx;v.z3=P.z3; v.Vs=P.Vs;if(e.V("html5_fix_time_since_last_seek_reporting")?P.Yq!==void 0:P.Yq)v.EM6=(0,g.Gz)()-P.Yq;P.isPrefetch&&e.V("html5_report_prefetch_requests")&&(v.isPrefetch=!0);ly||(v.EY3=!0);E=KP(e.schedule)*1E3;E>0&&(v.qB=E);var hq;((hq=P.iq)==null?0:hq.Sm)&&P.Rj&&P.Rj 0?R7:e.schedule.interruptions[0]||0);var Pw;if((Pw=P.iq)==null?0:Pw.It)v.KW=P.KW;var H;((H=P.iq)==null?0:H.DG)&&h.NH&&(v.audioTrackId=h.NH);var T;if((T=P.iq)==null?0:T.cC)if(P=gUu())v.detailedNetworkType=br6[P]||br6.other;return v}; uu=function(P,v,l,e,h,z,m){var Q={};v&&(Q.ol=v);if(!P)return Q;Q.playbackCookie=l==null?void 0:l.playbackCookie;h&&(Q.G9=h);Q.nG=[];Q.n9=[];if(m==null?0:m.size)for(v=g.N(m.values()),l=v.next();!l.done;l=v.next())Q.n9.push(l.value);if((g.VW(P)||P.Sx)&&P.sabrContextUpdates.size>0)for(v=g.N(P.sabrContextUpdates.values()),l=v.next();!l.done;l=v.next())x9w(Q,l.value,e);yi(P)&&!g.VW(P)&&P.V("html5_enable_sabr_request_pipelining")&&z&&x9w(Q,z,e);P.eZ&&(Q.lA0=P.eZ);e=P.N().W;Q.clientInfo={clientName:pnD[e.c.toUpperCase()]|| 0};e.cbrand&&(Q.clientInfo.deviceMake=e.cbrand);e.cmodel&&(Q.clientInfo.deviceModel=e.cmodel);e.cver&&(Q.clientInfo.clientVersion=e.cver);e.cos&&(Q.clientInfo.osName=e.cos);e.cosver&&(Q.clientInfo.osVersion=e.cosver);e=P.N();e.V("html5_sabr_enable_server_xtag_selection")&&e.TG&&(Q.clientInfo.hl=e.TG);P.YB&&(Q.YB=P.YB);return Q}; x9w=function(P,v,l){var e=v.type||0;(l==null?0:l.has(e))?P.n9.push(v):P.nG.push(e)}; jT=function(P,v,l,e,h,z){var m=z===void 0?{}:z;var Q=m.Xt===void 0?[]:m.Xt;var t=m.Lr===void 0?!1:m.Lr;var y=m.MX===void 0?0:m.MX;var C=m.poToken===void 0?"":m.poToken;var f=m.Of===void 0?void 0:m.Of;var k=m.Ze===void 0?"":m.Ze;var w=m.tQ===void 0?0:m.tQ;var I=m.Mw===void 0?new Uint8Array(0):m.Mw;var J=m.oh===void 0?!1:m.oh;z=m.Tq===void 0?0:m.Tq;m=m.ol===void 0?void 0:m.ol;eX.call(this,v,h);var K=this;this.policy=P;this.logger=new g.Rf("dash/request");this.vj=this.zW=0;this.xW=!1;this.Tm=this.Fp= null;this.pc=!1;this.Mw=this.tQ=null;this.SL=this.Sa=!1;this.MI=null;this.Tq=this.kK=0;this.T$=!1;this.Kh={As:function(A){K.As(A)}, xgg:function(){return K.KX}, Q25:function(A){K.KX=A}, WPc:function(A){K.zW=A}, MnJ:function(A){K.Eb.lastError=A}, rX:function(){return K.xhr}}; this.timing=new db(this,l);this.Lr=t;this.tQ=w;this.Mw=I;this.K6=g.WH(this.info,this.policy,e);this.K6.set("rn",this.Qp().toString());this.K6.set("rbuf",(y*1E3).toFixed().toString());this.Lr&&this.K6.set("smb","1");this.policy.SI&&C&&this.K6.set("pot",C);k&&this.K6.set("bbs",k);this.policy.useUmp&&!Y_(this.K6.P9)&&(this.I5=new lu(this),this.K6.set("ump","1"),this.K6.set("srfvp","1"));if(P=this.policy.CO?this.policy.Gx&&!isNaN(this.info.WB)&&this.info.WB>this.policy.Vl?!1:!0:!1)v=null,this.policy.NG&& this.policy.M_?v=[1]:J&&(v=[]),v!=null&&(this.policy.dF&&v.push(2),this.K6.set("defsel",v.join(",")));this.Eb=new C5(this,this.policy,this.K6,this.info.JR,this.timing,this.logger,e,f);this.Xt=Q||null;this.vE=L4w(this);zGw(this.Eb);e=void 0;if(this.policy.jx||this.I5||this.policy.Hg)e={method:"POST"},Q=(0,g.K5)([120,0]),f={},this.policy.jB&&m&&(m=uu(void 0,m),f.kP=m),this.policy.YJ&&this.Mw&&(f.videoPlaybackUstreamerConfig=this.Mw),this.policy.Hg&&(m=this.info.Y)&&Object.assign(f,m),Object.keys(f).length> 0?e.body=g.yg(f,g.lg):e.body=Q;if(this.tQ&&this.Mw){this.K6.set("iwts","1");e={method:"POST"};m={Vs:this.tQ*1E3};var q;Q=(q=this.info.Y)==null?void 0:q.o3;q=g.yg({YL:m,o3:Q||void 0,videoPlaybackUstreamerConfig:this.Mw},g.lg);e.body=q}try{this.xhr=mJ(this.K6,this.policy.S,this.timing,P,e),this.Eb.K.start(),z&&(this.YA=new g.mr(this.uN,z,this),this.YA.start(z+(this.timing.Ob.S.y_()||0)*1E3)),this.policy.C1&&Vh(this.timing,this.sQ()),this.logger.debug(function(){return"Sent, itag="+K.K6.get("itag")+ " seg="+K.info.N5[0].n0+" range="+K.K6.get("range")+" time="+Math.round(K.info.N5[0].ao)+"-"+Math.round(g.WA(K.info.N5).EF)+" rtp="+(K.timing.Eh()-Date.now()).toFixed(0)}),g.w5(function(){})}catch(A){S_w(this,A,!0)}}; L4w=function(P){if(!(E8(P.info)&&P.info.QQ()&&P.policy.Hl&&P.Xt)||P.info.JR.K>=2||aJ()>0||!ATw())return!1;var v=P.K6.get("aitags");if(!v)return!1;v=dO(v).split(",");for(var l=[],e=g.N(P.Xt),h=e.next();!h.done;h=e.next())h=h.value,g.ro(v,h)&&l.push(h);if(!l.length)return!1;P.K6.set("altitags",g.VC(l.join(",")));return!0}; S_w=function(P,v,l){l=l===void 0?!1:l;g.Zx(v);P.Eb.lastError="player.exception";P.errorMessage=v.name+"_"+v.message;l?g.w5(function(){kv(P.Eb)}):kv(P.Eb)}; Gc7=function(P,v){P.timing.QW=!0;P.xhr.DC()&&P.timing.jA();if(P.policy.hs){var l;(l=P.YA)==null||l.stop()}yJ(P.KX,v,!1)}; Xn7=function(P,v){P.info=v;if(P.KX){var l=P.KX;v=v.N5;(v.length!==l.N5.length||v.length 0){v=g.N(v.N5);for(var l=v.next();!l.done;l=v.next()){var e=void 0;P+=((e=l.value.range)==null?void 0:e.length)||0}return P}if(v.wB.length>0)for(l=g.N(v.wB),e=l.next();!e.done;e=l.next())P+=e.value.pR||0;return P+v.qD}; p5=function(P,v){if(Yv){var l=0;P=P.r9.get(v);if(P==null||!P.JN)return 0;P=g.N(P.JN.values());for(v=P.next();!v.done;v=P.next())l+=v.value.data.getLength();return l}return((l=P.r9.get(v))==null?void 0:l.mx.getLength())||0}; L5=function(P,v){P=P.r9.get(v);if(Yv){if(P==null||!P.g1)return!1;v=P.JN.size>0;return P.Ij.length>0||v}return!(P==null||!P.g1)&&!(P==null||!P.mx.getLength())}; aha=function(P,v){var l=P.r9.get(v),e=jaB(P,v),h=!e&&!!l.bytesReceived;if(Yv){var z;if((z=P.rM)==null?0:z.Ei){P=g.N(l.JN.values());for(v=P.next();!v.done;v=P.next())if(!v.value.G$)return!1;return h}}else if(z=P.M4(v),h&&P.W&&z!==void 0)return z;return(h||l.bytesReceived===e)&&l.z7+p5(P,v)===l.bytesReceived}; Hrw=function(P,v,l){P.r9.set(v,{mx:new uh,z7:0,bytesReceived:0,qD:0,je:!1,iA:!1,M4:!1,h3:l,WW:[],N5:[],wB:[],g1:!1,JN:new Map,X4:new Map,Ij:[]});P.logger.debug(function(){return"[initStream] formatId: "+v})}; E_9=function(P,v,l,e){l.N5.push.apply(l.N5,g.u(e));if(Yv){l.X4.has(v)||l.X4.set(v,[]);var h;(h=l.X4.get(v)).push.apply(h,g.u(e))}else if(l.KX)for(P=g.N(e),v=P.next();!v.done;v=P.next())l.KX.N5.push(v.value);else{l.KX=new ty(P.iq,[].concat(g.u(l.N5)));var z;((z=P.iq)==null?0:z.eb)&&g.Z(P,l.KX)}}; W49=function(P,v,l){var e,h=(e=P.rM)==null?void 0:e.G.get(v);if(!h)return[];if(l.rl){var z;return((z=h.oA(0,l.clipId))==null?void 0:z.N5)||[]}if(h.k9()){var m=l.startMs,Q=l.durationMs,t=1E3,y;if(((y=P.iq)==null?0:y.W)&&l.timeRange){var C;m=(C=l.timeRange.No)!=null?C:-1;var f;Q=(f=l.timeRange.xU)!=null?f:-1;var k;t=(k=l.timeRange.b7)!=null?k:-1}if(l.BE<0||l.Ck<0||Q<0||m<0||l.pR<0||t<0)return xv(P,v),[];P=Lo(l.BE,l.pR);v=l.U0||0;return[new G8(3,h,P,"makeSliceInfosMediaBytes",l.Ck-1,m/t,Q/t,v,P.length- v,void 0,l.mu,l.clipId)]}if(l.Ck<0)return xv(P,v),[];var w;return((w=P.rM)==null?0:w.Ei)?(v=h.rY,y=v*h.info.FJ,C=((m=P.iq)==null?0:m.MV)?l.U0:void 0,((t=P.iq)==null?0:t.K1)&&l.timeRange&&!C&&(Q=l.timeRange.No/l.timeRange.b7),[new G8(3,h,void 0,"makeSliceInfosMediaBytes",l.Ck,Q,v,C,y,!0,l.mu,l.clipId)]):[]}; OrD=function(P,v,l){P.rM=v;P.iq=l;v=g.N(P.r9);for(l=v.next();!l.done;l=v.next()){var e=g.N(l.value);l=e.next().value;e=e.next().value;for(var h=g.N(e.WW),z=h.next();!z.done;z=h.next()){z=z.value;var m=W49(P,l,z);E_9(P,z.gq,e,m)}}}; SX=function(P,v,l,e){P.logger.debug(function(){return"[addStreamData] formatId: "+l+",headerId: "+v+" bytes: "+e.getLength()}); (P=P.r9.get(l))&&!P.iA&&(Yv?(P.JN.has(v)||P.JN.set(v,{data:new uh,fL:0,G$:!1}),Ka(P.JN.get(v).data,e)):Ka(P.mx,e),P.bytesReceived+=e.getLength(),P.je=!0)}; bu=function(P,v){P.logger.debug(function(){return"[closeStream] formatId: "+v}); var l=P.r9.get(v);l&&!l.iA&&(l.iA=!0,l.mf&&l.mf(),o_2(P)&&P.Y.FU())}; o_2=function(P){P=g.N(P.r9.values());for(var v=P.next();!v.done;v=P.next())if(!v.value.iA)return!1;return!0}; GG=function(P,v,l,e,h,z,m,Q){g.U.call(this);this.policy=P;this.info=v;this.rM=l;this.Md=h;this.vx=Q;this.logger=new g.Rf("sabr");this.I5=new lu(this);this.vk=new F4(this);this.Dg=new Ay(this);this.state=1;this.uL=!1;this.ij=0;this.clipId="";this.xA=this.lZ=-1;this.td=0;this.ZD=-1;this.T$=this.UV=!1;this.JH=0;this.BY=!1;this.policy.P4?this.F_=new c8(this,z):this.F_=new db(this,z);this.K6=this.policy.It?v.p$:saq(v,this.policy,e);this.K6.set("rn",""+this.Qp());this.K6.set("alr","yes");OrD(this.Dg,l, P);this.Eb=new C5(this,this.policy,this.K6,v.JR,this.F_,this.logger,e,m,this.policy.enableServerDrivenRequestCancellation);zGw(this.Eb);var t;if((t=this.policy)==null?0:t.eb)g.Z(this,this.Dg),g.Z(this,this.Eb);P=v.K;v={method:"POST",body:P};P&&(this.td=P.length);try{this.xhr=mJ(this.K6,this.policy.S,this.F_,ly,v),this.policy.C1&&Vh(this.F_,this.sQ()),this.Eb.K.start()}catch(y){g.j4(y)}}; rRq=function(P){P.policy.G_&&P.cX&&!P.BY?P.BY=!0:P.F_.jA()}; MMu=function(P,v){var l=-1,e=-1,h=-1,z;if((z=P.RQ)==null?0:z.items)for(P=g.N(P.RQ.items),z=P.next();!z.done;z=P.next())z=z.value,v =Q,t=P.rM.isManifestless&&P.policy.D2, m){var y;if(((y=P.W)==null?void 0:y.Or.event)==="predictStart"&&P.W.n0 P.Z&&(P.Z=NaN,P.j=NaN);if(P.W&&P.W.n0===v)if(e=P.W,!P.policy.mA||h&&e){var m=e.Or;z=h.pE(m);m.event==="predictStart"&&(P.QW=v);P.f0("sdai",{onqevt:m.event,sq:v,mt:l,gab:z,cst:m.startSecs,cueid:P.policy.xI&&(z||m.event==="start")?m.identifier:void 0});if(z)if(m.event!=="predictStart")m.event==="start"&&P.QW===v-1&&P.f0("sdai",{gabonstart:v}), e.EG?Ux(P,4,"cue"):(P.Z=v,P.j=l,P.f0("sdai",{joinad:P.K,sg:P.Z,st:P.j.toFixed(3)}),P.X=Date.now(),Ux(P,2,"join"),h.jJ(e.Or));else{var Q=v+Math.max(Math.ceil(-m.W/5E3),1);z=Math.floor(l-m.W/1E3);P.policy.Z?P.G=z:P.Y=Q;P.f0("sdai",{onpred:l,estsq:Q,estmt:z.toFixed(3)});P.policy.N_&&jX(P.K0,z,z,Q);P.X=Date.now();Ux(P,3,"predict");h.jJ(e.Or)}else P.K===1?((Q=P.T)==null?0:Q.Hq(l))?(jX(P.K0,l,l,v),Ux(P,4,"sk2had")):Ux(P,5,"nogab"):m.event==="predictStart"&&(P.policy.Z&&P.G>0?(l=Math.floor(l-m.W/1E3),P.G!== l&&P.f0("sdai",{updateSt:l,old:P.G}),P.G=l):P.Y>0&&(l=v+Math.max(Math.ceil(-m.W/5E3),1),P.Y!==l&&(P.f0("sdai",{updateSt:l,old:P.Y}),P.Y=l)));var t,y;if(P.DR&&m.event==="start"&&((t=P.W)==null?void 0:t.Or.event)!=="predictStart"&&((y=P.W)==null?void 0:y.n0)===v-1){var C;P.f0("sdai",{ovlpst:(C=P.W)==null?void 0:C.Or.event,sq:v})}}else P.f0("sdai",{nulldec:1,sq:v,mt:l.toFixed(3),evt:(e==null?void 0:(m=e.Or)==null?void 0:m.event)||"none"});else P.K===1&&Ux(P,5,"noad")}; f62=function(P,v,l){if(P.K===1||P.K===2)return!1;if(P.K!==0&&v===P.audioTrack){if(P.policy.Z)return Cdw(P.videoTrack,l)||Cdw(P.videoTrack,l+1);P=af(P.videoTrack);if(l>(P?P.n0:-1))return!1}return!0}; H8=function(P,v,l){return(l<0||l===P.Z)&&!isNaN(P.j)?P.j:v}; Q1y=function(P,v){if(P.W){var l=P.W.Or.Er-(v.startTime+P.S-P.W.Or.startSecs);l<=0||(l=new Hn(P.W.Or.startSecs-(isNaN(P.S)?0:P.S),l,P.W.Or.context,P.W.Or.identifier,"stop",P.W.Or.W+v.duration*1E3),P.f0("cuepointdiscontinuity",{segNum:v.n0}),iu(P,l,v.n0))}}; Ux=function(P,v,l){P.K!==v&&(P.f0("sdai",{setsst:v,old:P.K,r:l}),P.K=v)}; Ex=function(P,v,l,e){(e===void 0?0:e)?Ux(P,1,"seek"):v>0&&Math.abs(v-l)>=5&&P.K===4&&Ux(P,5,"sk2t."+v.toFixed(2)+";ct."+l.toFixed(2))}; W8=function(P,v,l){this.audio=P;this.video=v;this.reason=l}; Ox=function(P,v,l){this.W=P;this.reason=v;this.token=l;this.videoId=void 0}; of=function(P,v,l){g.U.call(this);this.policy=P;this.Y=v;this.f0=l;this.G=new Map;this.Z=0;this.T=!1;this.W="";this.K=!1}; sx=function(P,v,l){if(l===void 0?0:l)P.T=!0;++P.Z;l=6E4*Math.pow(2,P.Z);l=(0,g.Gz)()+l;P.G.set(v.info.id,l)}; rN=function(P){for(var v=g.N(P.G.entries()),l=v.next();!l.done;l=v.next()){var e=g.N(l.value);l=e.next().value;e=e.next().value;e<(0,g.Gz)()&&P.G.delete(l)}return P.G}; g2w=function(P){return P.T&&rN(P).size>0}; Mn=function(P,v){P.W!==v&&(P.W=v,P.K=!0)}; k8P=function(P,v){var l;v&&(l=g.om(P.Y.W,function(h){return h.id===v})); if(!l&&(l=g.om(P.Y.W,function(h){var z;return!((z=h.Rt)==null||!z.isDefault)}),v)){var e; P.f0("iaf",{id:v,sid:(e=l)==null?void 0:e.id})}return l}; VJ=function(P,v,l,e,h,z){var m=this;z=z===void 0?[]:z;this.K0=P;this.J5=v;this.policy=l;this.rM=e;this.T=h;this.D3=z;this.logger=new g.Rf("dash/abr");this.W=Ov;this.G=this.j=null;this.X=-1;this.Hg=!1;this.nextVideo=this.K=null;this.Y=[];this.q5=new Set;this.wM={};this.A5=new $Q(1);this.S=0;this.Ic=this.QW=this.Wg=!1;this.T1=0;this.h5=!1;this.kf=new Set;this.Pg=!1;this.Kh={oM:function(){TG(m)}}; this.Z=new of(this.policy,h,function(Q,t){m.K0.f0(Q,t)})}; n2y=function(P,v,l){dN(P,v);v=k8P(P.Z,l);l||v||(v=wH7(P));v=v||P.T.W[0];P.K=P.rM.W[v.id];TG(P);P.j=P.K;$Nw(P);I6w(P);P.G=P.nextVideo;P.j=P.K;return DNB(P)}; uI2=function(P,v){if(NRB(P,v))return null;if(v.reason==="m"&&v.isLocked())return P.logger.debug(function(){return"User sets constraint to: "+fr(v)}),dN(P,v),P.S=P.Y.length-1,TG(P),Pm(P),P.QW=P.QW||P.G!==P.nextVideo,P.G=P.nextVideo,new W8(P.K,P.G,v.reason); v.reason==="r"&&(P.X=-1);dN(P,v);Pm(P);if(v.reason==="r"&&P.nextVideo===P.G)return new W8(P.K,P.nextVideo,v.reason);J_a(P);return null}; KKx=function(P,v,l){P.K=P.rM.W[v];P.j=P.K;return new W8(P.j,P.G,l?"t":"m")}; c_w=function(P,v){if(v.info.video){if(P.G!==v)return P.G=v,DNB(P)}else P.Ic=P.j!==v,P.j=v;return null}; q87=function(P,v){if(v.W.info.video&&v.Y){var l=(v.K+v.G)/v.duration,e=v.W.info.FJ;l&&e&&(P.A5.mG(1,l/e),P.policy.G&&l/e>1.5&&P.K0.f0("overshoot",{sq:v.n0,br:l,max:e}))}}; vm=function(P,v,l){sx(P.Z,v,l===void 0?!1:l);P.X=-1;dN(P,P.W)}; FK7=function(P,v){return new W8(P.j,P.G,v||P.W.reason)}; J_a=function(P){if(P.G&&P.nextVideo&&lW(P,P.G.info) P.policy.gH,Q=h<=P.policy.gH?Ta(e):rl(e);if(!z||m||Q)l[h]=e}return l}; dN=function(P,v){P.W=v;var l=P.T.videoInfos;if(!P.W.isLocked()){var e=(0,g.Gz)();l=g.$g(l,function(Q){if(Q.FJ>this.policy.FJ)return!1;var t=this.rM.W[Q.id];return rN(this.Z).get(Q.id)>e?!1:t.JR.K>4||t.T>4?(this.logger.debug(function(){return"Remove "+Rb(Q)+"; 4 load failures"}),!1):this.kf.has(+Q.itag)?!1:!0},P); g2w(P.Z)&&(l=g.$g(l,function(Q){return Q.video.width<=854&&Q.video.height<=480}))}l.length||(l=P.T.videoInfos); var h=l;P.policy.Rm&&(h=Y8a(P,h,v));h=g.$g(h,v.Y,v);if(P.W.isLocked()&&P.Z.W){var z=g.om(l,function(Q){return Q.id===P.Z.W}); z?h=[z]:Mn(P.Z,"")}P.policy.Rm||(h=Y8a(P,h,v));h.length||(h=[l[0]]);h.sort(function(Q,t){return lW(P,Q)-lW(P,t)}); v={};for(l=1;l v.wS.video.width?(g.MG(h,l),l--):lW(P,v.X$)*P.policy.X>lW(P,v.wS)&&(g.MG(h,l-1),l--);var m=h[h.length-1];P.h5=!!P.G&&!!P.G.info&&P.G.info.dM!==m.dM;P.logger.debug(function(){return"Constraint: "+fr(P.W)+", "+h.length+" fmts selectable, max selectable fmt: "+Rb(m)}); P.Y=h;P.q5.clear();v=!1;for(l=0;l =1080&&(v=!0);bo2(P.policy,m,P.rM.Ei)}; Y8a=function(P,v,l){var e=l.reason==="m"||l.reason==="s";P.policy.Ai&&eD&&g.FA&&(!e||l.W<1080)&&(v=v.filter(function(y){return y.video&&(!y.K||y.K.powerEfficient)})); if(v.length>0)if(WB()){var h=A_u(P,v);v=v.filter(function(y){return!!y&&!!y.video&&y.dM===h[y.video.W].dM})}else{var z,m,Q=(z=v[0])==null?void 0:(m=z.video)==null?void 0:m.W; if(Q){l=v.filter(function(y){return!!y&&!!y.video&&y.video.W===Q}); var t=A_u(P,l)[Q].dM;v=v.filter(function(y){return!!y&&!!y.video&&y.dM===t})}}return v}; xNx=function(P,v){for(var l=0;l+1 e}; TG=function(P){if(!P.K||!P.policy.Y&&!P.K.info.Rt){var v=P.T.W;P.K&&(v=v.filter(function(e){return e.audio.W===P.K.info.audio.W}),v.length||(v=P.T.W)); P.K=P.rM.W[v[0].id];if(v.length>1){if(P.policy.Cg){if(P.policy.nI)return;var l=g.om(v,function(e){return e.audio.audioQuality!=="AUDIO_QUALITY_HIGH"}); l&&(P.K=P.rM.W[l.id])}l=!1;if(l=P.policy.SN?!0:P.W.isLocked()?P.W.W<240:xNx(P,P.K))P.K=P.rM.W[g.WA(v).id]}}}; Pm=function(P){if(!P.nextVideo||!P.policy.Y)if(P.W.isLocked())P.nextVideo=P.W.W<=360?P.rM.W[P.Y[0].id]:P.rM.W[g.WA(P.Y).id],P.logger.debug(function(){return"Select max fmt: "+Rb(P.nextVideo.info)}); else{for(var v=Math.min(P.S,P.Y.length-1),l=ST(P.J5),e=lW(P,P.K.info),h=l/P.policy.Wg-e;v>0&&!(lW(P,P.Y[v])<=h);v--);for(var z=l/P.policy.X-e;v =z);v++);P.nextVideo=P.rM.W[P.Y[v].id];P.S!==v&&P.logger.info(function(){return"Adapt to: "+Rb(P.nextVideo.info)+", bandwidth: "+l.toFixed(0)+", bandwidth to downgrade: "+h.toFixed(0)+", bandwidth to upgrade: "+z.toFixed(0)+", constraint: "+fr(P.W)}); P.S=v}}; $Nw=function(P){var v=P.policy.Wg,l=ST(P.J5),e=l/v-lW(P,P.K.info);v=g.sb(P.Y,function(h){return lW(this,h) z?h=0:e[m]>P.buffered[m]&&(m===z-1?h=2:m===z-2&&e[m+1]>P.buffered[m+1]&&(h=3))}P.W.add(v<<3|(l&&4)|h);v=Math.ceil(P.track.HI()*1E3);P.W.add(v-P.Z);P.Z=v;if(h===1)for(P.W.add(z),m=v=0;m =2&&P.W.add(e[z- 1]-P.buffered[z-1]);l&&P.W.add(l);P.buffered=e}; mP=function(P,v,l){var e=this;this.policy=P;this.W=v;this.T1=l;this.Y=this.K=0;this.lM=null;this.Wg=new Set;this.X=[];this.indexRange=this.initRange=null;this.S=new PP;this.QW=this.J5=!1;this.Kh={udg:function(){return e.G}, B0W:function(){return e.chunkSize}, lwg:function(){return e.j}, eP5:function(){return e.T}}; (v=XHy(this))?(this.chunkSize=v.csz,this.G=Math.floor(v.clen/v.csz),this.j=v.ck,this.T=v.civ):(this.chunkSize=P.fH,this.G=0,this.j=g.YR(16),this.T=g.YR(16));this.Z=new Uint8Array(this.chunkSize);this.j&&this.T&&(this.crypto=new ofD(this.j,this.T))}; XHy=function(P){if(P.policy.FL&&P.policy.fp)for(var v=g.N(P.policy.FL),l=v.next(),e={};!l.done;e={D9:void 0,Yp:void 0},l=v.next())if(l=g.fG(l.value),e.D9=+l.clen,e.Yp=+l.csz,e.D9>0&&e.Yp>0&&P.policy.Y===l.docid&&P.W.info.id===l.fmtid&&P.W.info.lastModified===+l.lmt)return P={},P.clen=e.D9,P.csz=e.Yp,P.ck=l.ck,P.civ=l.civ,P}; Rc=function(P){return!!P.lM&&P.lM.c9()}; UN2=function(P,v){if(!Rc(P)&&!P.s$()){if(!(P.J5||(P.J5=!0,P.G>0))){var l=Ql(P);l=Bo(P.policy.Y,P.W.info,tE(P),l,P.policy.D3);yl(P,l)}if(v.info.type===1){if(P.lM){CL(P,Error("Woffle: Expect INIT slices to always start us off"));return}P.initRange=Lo(0,v.W.getLength())}else if(v.info.type===2)P.lM&&P.lM.type===1||CL(P,Error("Woffle: Index before init")),P.indexRange=Lo(P.initRange.end+1,v.W.getLength());else if(v.info.type===3){if(!P.lM){CL(P,Error("Woffle: Expect MEDIA slices to always have lastSlice")); return}if(P.lM.type===3&&!id(P.lM,v.info)&&(P.X=[],v.info.n0!==U8(P.lM)||v.info.K!==0))return;if(v.info.Y){l=g.N(P.X);for(var e=l.next();!e.done;e=l.next())BRP(P,e.value);P.X=[]}else{P.X.push(v);P.lM=v.info;return}}else{CL(P,Error("Woffle: Unexpected slice type"));return}P.lM=v.info;BRP(P,v);io6(P)}}; BRP=function(P,v){var l=0,e=v.W.Yt();if(P.Y =e.length)return;if(l<0)throw Error("Missing data");P.Y=P.G;P.K=0}for(h={};l 0){var m=e.getUint32(l+28);z+=m*16+4}var Q=e.getUint32(l+z-4);try{var t=E29(v.subarray(l+z,l+z+Q));if(t!==null){var y=t;break a}}catch(C){}}l+=h}y=null;break a}catch(C){y=null;break a}y=void 0}if(y!=null)for(v=kh(Xk(y,7)),v==null||P.C6||(P.cryptoPeriodIndex=v),v=kh(Xk(y,10)),v!=null&&v>0&&!P.C6&&(P.W=v),y=Ol(y, 2,f7D,void 0===wZ7?2:4),y=g.N(y),v=y.next();!v.done;v=y.next())P.G.push(g.D7(AK(v.value),4))}; Oo7=function(P){return isNaN(P.cryptoPeriodIndex)?g.D7(P.initData):""+P.cryptoPeriodIndex}; kb=function(P,v,l){var e=l===void 0?{}:l;l=e.videoDuration===void 0?0:e.videoDuration;var h=e.Qi===void 0?void 0:e.Qi;e=e.eJ===void 0?!1:e.eJ;this.videoId=P;this.status=v;this.videoDuration=l;this.Qi=h;this.eJ=e}; o2w=function(P,v,l,e,h){this.videoId=P;this.A9=v;this.K=l;this.bytesDownloaded=e;this.W=h}; wq=function(P){this.W=P;this.offset=0}; $b=function(P){if(P.offset>=P.W.getLength())throw Error();return P.W.getUint8(P.offset++)}; s1u=function(P,v){v=v===void 0?!1:v;var l=$b(P);if(l===1){v=-1;for(l=0;l<7;l++){var e=$b(P);v===-1&&e!==255&&(v=0);v>-1&&(v=v*256+e)}return v}e=128;for(var h=0;h<6&&e>l;h++)l=l*256+$b(P),e*=128;return v?l:l-e}; r_w=function(P){try{var v=s1u(P,!0),l=s1u(P,!1);return{id:v,size:l}}catch(e){return{id:-1,size:-1}}}; MV2=function(P){for(var v=new wq(P),l=-1,e=0,h=0;!e||!h;){var z=r_w(v),m=z.id;z=z.size;if(m<0)return;if(m===176){if(z!==2)return;e=v.Ws()}else if(m===186){if(z!==2)return;h=v.Ws()}m===374648427?l=v.Ws()+z:m!==408125543&&m!==174&&m!==224&&v.skip(z)}v=Af(P,0,l);l=new DataView(v.buffer);l.setUint16(e,3840);l.setUint16(h,2160);e=new uh([v]);Ka(e,P);return e}; TRx=function(P,v,l){var e=this;this.K0=P;this.policy=v;this.T=l;this.logger=new g.Rf("dash");this.K=[];this.W=null;this.J5=-1;this.X=0;this.kf=NaN;this.Wg=0;this.G=NaN;this.S=this.Hg=0;this.h5=-1;this.wM=this.Z=this.Y=this.T1=null;this.A5=this.Ic=NaN;this.j=this.QW=this.q5=this.D3=null;this.U$=!1;this.Pg=this.timestampOffset=0;this.Kh={IR:function(){return e.K}}; if(this.policy.Y){var h=this.T,z=this.policy.Y;this.policy.D3&&P.f0("atv",{ap:this.policy.D3});this.j=new mP(this.policy,h,function(m,Q,t){Ic(P,new kb(e.policy.Y,2,{Qi:new o2w(z,m,h.info,Q,t)}))}); this.j.S.promise.then(function(m){e.j=null;m===1?Ic(P,new kb(e.policy.Y,m)):e.K0.f0("offlineerr",{status:m.toString()})},function(m){var Q=(m.message||"none").replace(/[+]/g,"-").replace(/[^a-zA-Z0-9;.!_-]/g,"_"); m instanceof fL&&!m.W?(e.logger.info(function(){return"Assertion failed: "+Q}),e.K0.f0("offlinenwerr",{em:Q}),D2(e),Ic(P,new kb(e.policy.Y,4))):(e.logger.info(function(){return"Failed to write to disk: "+Q}),e.K0.f0("dldbwerr",{em:Q}),D2(e),Ic(P,new kb(e.policy.Y,4,{eJ:!0})))})}}; VV2=function(P){return P.K.length?P.K[0]:null}; dN2=function(P,v){return P.K.some(function(l){return l.info.n0===v})}; hFw=function(P,v,l,e){e=e===void 0?0:e;if(P.Z){var h=P.Z.K+P.Z.G;if(l.info.K>0)if(l.info.n0===P.Z.n0&&l.info.K =0&&P.Z.n0>=0&&!id(P.Z,l.info))throw new g.Ph("improper_continuation",P.Z.WR(),l.info.WR());HWx(P.Z,l.info)||nL(P,"d")}else if(l.info.K>0)throw new g.Ph("continuation_of_null",l.info.WR());P.Z=l.info;P.T=l.info.W;if(l.info.K===0){if(P.W)if(!P.K0.isOffline()||P.policy.xt)P.K0.f0("slice_not_fully_processed",{buffered:P.W.info.WR(), push:l.info.WR()});else throw new g.Ph("slice_not_fully_processed",P.W.info.WR(),l.info.WR());NJ(P);P.Hg=e}else{if(P.Hg&&e&&P.Hg!==e)throw P=new g.Ph("lmt_mismatch",l.info.n0,P.Hg,e),P.level="WARNING",P;!l.info.W.k9()&&P.Y&&(e=l.info,h=P.Y.lZ,e.Z="updateWithEmsg",e.n0=h)}if(P.W){e=g.lM(P.W,l);if(!e)throw new g.Ph("failed_to_merge",P.W.info.WR(),l.info.WR());P.W=e}else P.W=l;a:{l=g.PB(P.W.info.W.info);if(P.W.info.type!==3){if(!P.W.info.Y)break a;P.W.info.type===6?PMw(P,v,P.W):vTw(P,P.W);P.W=null}for(;P.W;){e= P.W.W.getLength();if(P.J5<=0&&P.X===0){var z=P.W.W,m=-1;h=-1;if(l){for(var Q=0;Q+8 0))break;if(f!==408125543)if(f===524531317)Q=!0,C>=0&&(h=z.Ws()+C,t=!0);else{if(Q&&(f===160||f===163)&&(m<0&&(m=y),t))break;f===163&&(m=Math.max(0,m),h=z.Ws()+C);if(f===160){m<0&&(h=m=z.Ws()+C);break}z.skip(C)}}m<0&&(h=-1)}if(m< 0)break;P.J5=m;P.X=h-m}if(P.J5>e)break;P.J5?(e=llu(P,P.J5),e.Z&&eF9(P,e),PMw(P,v,e),JE(P,e),P.J5=0):P.X&&(e=llu(P,P.X<0?Infinity:P.X),P.X-=e.W.getLength(),JE(P,e))}}P.W&&P.W.info.Y&&(JE(P,P.W),P.W=null)}; vTw=function(P,v){!v.info.W.k9()&&v.info.K===0&&(g.PB(v.info.W.info)||v.info.W.info.C6())&&D6D(v);if(v.info.type===1)try{eF9(P,v),zFq(P,v)}catch(h){g.Zx(h);var l=Z6(v.info);l.hms="1";P.K0.handleError("fmt.unparseable",l||{},1)}l=v.info.W;l.Ix(v);P.j&&UN2(P.j,v);if(l.cP()&&P.policy.W)a:{P=P.K0.rM;v=v.info.clipId;l=g.es(l.info,P.Ei);if(v){var e=XBy(P,l);if(P.Pg[e])break a;P.Pg[e]=v}P.wM.push(l)}}; Lk7=function(P,v,l){if(P.K.length!==0&&(l||P.K.some(function(z){return z.info.ao =KL(m)+Q):v=P.getDuration()>=m.getDuration(),v=!v;v&&QKD(l)&&(v=P.T1,uW?(Q=$62(l),m=1/Q,Q=KL(P,Q),v=KL(v)+m-Q):v=v.getDuration()- P.getDuration(),v=1+v/l.info.duration,nq6(l.f6(),v))}else{m=!1;P.Y||(D6D(l),l.K&&(P.Y=l.K,m=!0,z=l.info,e=l.K.lZ,z.Z="updateWithEmsg",z.n0=e,z=l.K,z.c9&&(e=P.T.index,e.K=!z.c9,e.G="emsg"),z=l.info.W.info,e=l.f6(),g.PB(z)?ld(e,1701671783):z.C6()&&ys([408125543],307544935,e)));a:if((z=zB(l,P.policy.Nd))&&ITx(l))Q=ta7(P,l),P.S+=Q,z-=Q,P.Wg+=z,P.G=P.policy.ir?P.G+z:NaN;else{if(P.policy.eZ){if(e=t=P.K0.VT(g.ea(l),1),P.G>=0&&l.info.type!==6){if(P.policy.ir&&isNaN(P.Ic)){g.j4(new g.Ph("Missing duration while processing previous chunk", l.info.WR()));P.K0.isOffline()&&!P.policy.xt||ypW(P,l,e);nL(P,"m");break a}var y=t-P.G,C=y-P.S,f=l.info.n0,k=P.wM?P.wM.n0:-1,w=P.A5,I=P.Ic,J=P.policy.Z2&&y>P.policy.Z2,K=Math.abs(C)>10,q=Math.abs(P.G-e)<1E-7;if(Math.abs(C)>1E-4){P.Pg+=1;var A=(h=P.Y)==null?void 0:O_(h);h={audio:""+ +P.h3(),sq:f.toFixed(),sliceStart:t,lastSq:k.toFixed(),lastSliceStart:w,lastSliceDuration:I,totalDrift:(y*1E3).toFixed(),segDrift:(C*1E3).toFixed(),skipRewrite:""+ +(J||K)};if(A==null?0:A.length)h.adCpn=A[0];P.K0.handleError("qoe.avsync", h);P.h5=f}J||K||q||(e=P.G);h=ta7(P,l,t);z-=h;P.S=y+h;P.policy.G&&(C&&!q||h)&&(y=(Q=P.Y)==null?void 0:O_(Q),P.K0.f0("discontinuityRewrite",{adCpn:(y==null?0:y.length)?y.join("."):"",itag:l.info.W.info.itag,sq:l.info.n0,originalStartTime:t,rewrittenStartTime:e,startTimeAdjustment:e-t,segDrift:(C*1E3).toFixed(),originalDuration:z+h,rewrittenDuration:z,durationAdjustment:h}))}}else e=isNaN(P.G)?l.info.startTime:P.G;ypW(P,l,e)&&(P.Wg+=z,P.G=e+z,P.policy.L1&&P.Pg>=P.policy.L1&&(P.Pg=0,P.K0.DH({resetForRewrites:"count"})))}P.wM= l.info;P.Ic=hp(l);l.G>=0&&(P.A5=l.G);if(m&&P.Y){m=CMD(P,!0);jV(l.info,m);P.W&&jV(P.W.info,m);v=g.N(v);for(Q=v.next();!Q.done;Q=v.next())Q=Q.value,h=void 0,P.policy.T&&Q.n0!==((h=P.Y)==null?void 0:h.lZ)||jV(Q,m);(l.info.Y||P.W&&P.W.info.Y)&&l.info.type!==6||(P.QW=m,P.policy.A5?(v=flw(P.Y),P.K0.K2(P.T,m,v)):(v=P.K0,v.rM.isManifestless&&gT7(v,m,null,!!P.T.info.video)),P.policy.vl||kB2(P))}}zFq(P,l);P.timestampOffset&&kNw(l,P.timestampOffset)}; JE=function(P,v){if(v.info.Y){P.D3=v.info;if(P.Y){var l=P.Y,e=CMD(P,!1);l=flw(l);P.K0.K2(P.T,e,l);P.QW||P.policy.vl||kB2(P);P.QW=null}NJ(P)}P.j&&UN2(P.j,v);if(e=P.iE())if(e=g.lM(e,v,P.policy.cw)){P.K.pop();P.K.push(e);return}P.K.push(v)}; flw=function(P){if(P.EG()){var v=P.data["Stitched-Video-Id"]?P.data["Stitched-Video-Id"].split(",").slice(0,-1):[],l=O_(P),e=[];if(P.data["Stitched-Video-Duration-Us"])for(var h=g.N(P.data["Stitched-Video-Duration-Us"].split(",").slice(0,-1)),z=h.next();!z.done;z=h.next())e.push((Number(z.value)||0)/1E6);h=[];if(P.data["Stitched-Video-Start-Frame-Index"]){z=g.N(P.data["Stitched-Video-Start-Frame-Index"].split(",").slice(0,-1));for(var m=z.next();!m.done;m=z.next())h.push(Number(m.value)||0)}h=[]; if(P.data["Stitched-Video-Start-Time-Within-Ad-Us"])for(z=g.N(P.data["Stitched-Video-Start-Time-Within-Ad-Us"].split(",").slice(0,-1)),m=z.next();!m.done;m=z.next())h.push((Number(m.value)||0)/1E6);P=new HoD(v,l,e,h,g.wzu(P),g.$g7(P))}else P=null;return P}; NJ=function(P){P.W=null;P.J5=-1;P.X=0;P.Y=null;P.kf=NaN;P.Wg=0;P.QW=null}; nL=function(P,v){v={rst4disc:v,cd:P.S.toFixed(3),sq:P.wM?P.wM.n0:-1};P.G=NaN;P.S=0;P.h5=-1;P.wM=null;P.A5=NaN;P.Ic=NaN;P.q5=null;P.K0.f0("mdstm",v)}; zFq=function(P,v){if(P.T.info.EQ){if(v.info.W.info.C6()){var l=new h_(v.f6());if(mK(l,[408125543,374648427,174,28032,25152,20533,18402])){var e=t_(l,!0);l=e!==16?null:k2(l,e)}else l=null;e="webm"}else v.info.j=j1q(v.f6()),l=a6y(v.info.j),e="cenc";l&&l.length&&(l=new gq(l,e),P.policy.Sx&&g.PB(v.info.W.info)&&(e=q6D(v.f6()))&&(l.K=e),l.C6=v.info.W.info.C6(),v.K&&v.K.cryptoPeriodIndex&&(l.cryptoPeriodIndex=v.K.cryptoPeriodIndex),v.K&&v.K.K&&(l.W=v.K.K),P.K0.EK(l))}}; kB2=function(P){var v=P.Y,l=gqw(v);l&&(l.startSecs+=P.kf,P.K0.yV(P.T,l,v.lZ,v.EG()))}; CMD=function(P,v){var l,e=P.Y;if(l=gqw(e))l.startSecs+=P.kf;var h=P.kf,z=v?e.rY:P.Wg;P=P.policy.SZ&&e.EG()?2:1;return new Lr(e.lZ,h,z,e.ingestionTime,"sq/"+e.lZ,void 0,void 0,v,l,P)}; ypW=function(P,v,l){if(!gJB(v,l))return v=Z6(v.info),v.smst="1",P.K0.handleError("fmt.unparseable",v||{},1),!1;isNaN(P.kf)&&(P.kf=l);return!0}; ta7=function(P,v,l){var e=0;if(v.info.W.info.C6()&&!ITx(v))return 0;if(P.T1&&!P.h3()){var h=0;l&&g.PB(v.info.W.info)?h=l-P.G:v.info.W.info.C6()&&(h=P.S);var z=v.info.n0;l=zB(v,P.policy.Nd);var m=P.T1;var Q=m.h5;m=m.S;var t=Math.abs(m-h)>.02;if((z===Q||z>Q&&z>P.h5)&&t){e=Math.max(.95,Math.min(1.05,(l-(m-h))/l));if(g.PB(v.info.W.info))nq6(v.f6(),e);else if(v.info.W.info.C6()&&(z=h-m,!g.PB(v.info.W.info)&&(v.info.W.info.C6(),e=new h_(v.f6()),Q=v.Z?e:new h_(new DataView(v.info.W.W.buffer)),zB(v,!0)))){var y= z*1E3,C=$2(Q);Q=e.pos;e.pos=0;if(e.W.getUint8(e.pos)===160||I1(e))if(Qs(e,160))if(t_(e,!0),Qs(e,155)){if(z=e.pos,t=t_(e,!0),e.pos=z,y=y*1E9/C,C=Co(e),y=C+Math.max(-C*.7,Math.min(C,y)),y=Math.sign(y)*Math.floor(Math.abs(y)),!(Math.ceil(Math.log(y)/Math.log(2)/8)>t)){e.pos=z+1;for(z=t-1;z>=0;z--)e.W.setUint8(e.pos+z,y&255),y>>>=8;e.pos=Q}}else e.pos=Q;else e.pos=Q;else e.pos=Q}e=zB(v,P.policy.Nd);e=l-e}e&&v.info.W.info.C6()&&P.K0.f0("webmDurationAdjustment",{durationAdjustment:e,videoDrift:h+e,audioDrift:m})}return e}; QKD=function(P){return P.info.W.k9()&&P.info.n0===P.info.W.index.vR()}; KL=function(P,v){v=(v=v===void 0?0:v)?Math.round(P.timestampOffset*v)/v:P.timestampOffset;P.T.Y&&v&&(v+=P.T.Y.W);return v+P.getDuration()}; wj6=function(P,v){v<0||(P.K.forEach(function(l){kNw(l,v)}),P.timestampOffset=v)}; ZL=function(P,v,l,e,h){eX.call(this,l,h);var z=this;this.policy=P;this.formatId=v;this.Dg=e;this.lastError=null;this.mf=function(){z.s$()||(z.Dg.r9.has(z.formatId)?(z.isComplete()||z.W.start(),L5(z.Dg,z.formatId)&&z.kx(2),z.Dg.iA(z.formatId)&&(aha(z.Dg,z.formatId)?z.As(4):(z.lastError="net.closed",z.As(5)))):(z.lastError="player.exception",z.As(5)))}; this.W=new g.mr(function(){z.isComplete()||(z.lastError="net.timeout",z.As(5))},this.policy.U5); this.W.start();U9D(this.Dg,this.formatId,this.mf);g.w5(this.mf)}; cm=function(P,v,l,e){g.U.call(this);var h=this;this.K0=P;this.policy=v;this.W=l;this.timing=e;this.logger=new g.Rf("dash");this.G=[];this.J5=[];this.K=this.mZ=null;this.Hg=!1;this.Pg=this.q5=0;this.T=-1;this.QW=!1;this.kf=-1;this.T1=this.wM=null;this.Wg=NaN;this.Kh={Kf:function(){return h.Y}, rPJ:function(){return h.G}, dHW:function(){return h.S}}; this.Y=new TRx(P,v,l);this.policy.W&&(this.S=new XO(this.Y,this.K0.getManifest(),this.policy,function(z){h.policy.DZ&&h.f0("buftl",z)})); this.policy.U$&&(this.X=new hE(this));this.FJ=l.info.FJ;this.j=this.policy.J5?!1:l.yR();this.isManifestless=l.yR();this.Z=this.j;g.Z(this,this.wM)}; qJ=function(P,v,l){l=l===void 0?!1:l;v&&uW&&wj6(P.Y,v.VF());if(!l){var e;(e=P.S)==null||Ygw(e)}P.mZ=v;(v=P.S)!=null&&(v.mZ=P.mZ)}; Fr=function(P){var v=P.mZ&&P.mZ.E1();if(P.policy.YV){if((P=P.S)==null)P=void 0;else{var l;P=(l=P.G)==null?void 0:l.info}return P||null}return v}; $t6=function(P){for(var v={},l=0;l 4&&P.J5.shift()}; Ilw=function(P,v){if(v.Ps()){var l=v.vT();l=g.N(l);for(var e=l.next();!e.done;e=l.next())e=e.value,P.policy.G&&v instanceof ZL&&P.f0("omblss",{s:e.info.WR()}),Yb(P,v.info.N5,e,v.HA())}}; Yb=function(P,v,l,e){e=e===void 0?0:e;isNaN(P.Wg)||(P.f0("aswm",{sq:v[0].n0,id:v[0].W.info.itag,xtag:v[0].W.info.W,ep:Date.now()-P.Wg}),P.Wg=NaN);switch(l.info.type){case 1:case 2:Dt7(P,l);break;case 4:var h=l.info.W,z=h.Rg(l),m;((m=P.K)==null?0:m.type===4)&&MLW(l.info,P.K)&&(P.K=h.Cx(P.K).pop());l=g.N(z);for(h=l.next();!h.done;h=l.next())Yb(P,v,h.value,e);break;case 3:l.info.W.info.video?(h=P.timing,h.T1||(h.T1=(0,g.Gz)(),bm("fvb_r",h.T1,h.W))):(h=P.timing,h.T||(h.T=(0,g.Gz)(),bm("fab_r",h.T,h.W))); hFw(P.Y,v,l,e);P.policy.W&&nTy(P);break;case 6:hFw(P.Y,v,l,e),P.K=l.info}}; Dt7=function(P,v){if(v.info.type===1)if(v.info.W.info.video){var l=P.timing;l.wM||(l.wM=(0,g.Gz)(),bm("vis_r",l.wM,l.W))}else l=P.timing,l.S||(l.S=(0,g.Gz)(),bm("ais_r",l.S,l.W));vTw(P.Y,v);P=P.K0;P.videoTrack.W.cP()&&P.audioTrack.W.cP()&&P.policy.W&&!P.rM.Ei&&(v=P.audioTrack.getDuration(),l=P.videoTrack.getDuration(),Math.abs(v-l)>1&&P.f0("trBug",{af:""+g.es(P.audioTrack.W.info,!1),vf:""+g.es(P.videoTrack.W.info,!1),a:""+v,v:""+l}))}; rb=function(P){return VV2(P.Y)}; nTy=function(P){P.G.length?P.K=g.WA(g.WA(P.G).info.N5):P.Y.K.length?P.K=P.Y.iE().info:P.K=Fr(P)}; bW=function(P,v){var l={hR:[],wi:[]},e;if((P=P.S)==null)P=void 0;else{AbD(P,P.hR,"og");cbw(P,v);AbD(P,P.hR,"trim");var h=Fkw(P);v=h.hR;h=h.Vp;for(var z=[],m=0;m 0){var k=yu(f,t);k>=0&&(C=(f.end(k)-t+.1)*1E3)}z.push({formatId:g.es(Q.info.W.info,P.rM.Ei),mu:Q.info.mu, sequenceNumber:Q.info.n0+P.Y,dc:y,Yo:Q.info.G,O9:C})}P={hR:v,wi:z}}return(e=P)!=null?e:l}; H6=function(P,v,l){l=l===void 0?!1:l;if(P.mZ){var e=P.mZ.Io(),h=f0(e,v),z=NaN,m=Fr(P);m&&(z=f0(e,m.W.index.getStartTime(m.n0)));if(h===z&&P.K&&P.K.G&&N6y(xb(P),0))return v}P=Jp9(P,v,l);return P>=0?P:NaN}; W6=function(P,v,l){P.W.cP();var e=Jp9(P,v);if(e>=0)return e;var h;(h=P.S)==null||qgy(h,v,l);l=Math;e=l.min;h=P.Y;if(h.j)if(h=h.j,h.lM&&h.lM.type===3)h=h.lM.startTime;else if(h.G>0){var z=h.W.index;z=g.R4(z.offsets.subarray(0,z.count),h.G*h.chunkSize);h=h.W.index.getStartTime(z>=0?z:Math.max(0,-z-2))}else h=0;else h=Infinity;v=e.call(l,v,h);if(P.policy.K){var m,Q;l=(m=P.K0.A3())==null?void 0:(Q=iU(m,v))==null?void 0:Q.clipId;P.K=P.W.wW(v,void 0,l).N5[0]}else P.K=P.policy.J5?null:P.W.wW(v).N5[0];pL(P)&& P.mZ&&P.mZ.abort();P.Pg=0;return P.K?P.K.startTime:v}; xEy=function(P){P.j=!0;P.Z=!0;P.T=-1;W6(P,Infinity)}; LL=function(P){for(var v=0,l=g.N(P.G),e=l.next();!e.done;e=l.next())v+=VL6(e.value.info);return v+=mtD(P.Y)}; Gb=function(P,v){v=v===void 0?!1:v;var l=P.K0.getCurrentTime(),e=P.Y.iE(),h=(e==null?void 0:e.info.EF)||0;P.policy.R7&&(e==null?0:e.info.W.yR())&&!e.info.Y&&(h=e.info.ao);if(P.policy.K&&e&&e.info.clipId){var z,m=(((z=P.K0.A3())==null?void 0:B6(z,e.info.clipId))||0)/1E3;h+=m}if(!P.mZ)return P.policy.W&&v&&!isNaN(l)&&e?h-l:0;if((z=Fr(P))&&SD(P,z))return z.EF;m=P.mZ.Io(!0);if(v&&e)return z=0,P.policy.W&&(z=kJ(m,h+.02)),z+h-l;h=kJ(m,l);P.policy.q$&&z&&(v=yu(m,l),m=yu(m,z.ao-.02),v===m&&(l=z.EF-l,P.policy.G&& l>h+.02&&P.f0("abh",{bh:h,bhtls:l}),h=Math.max(h,l)));return h}; ul7=function(P){var v=Fr(P);return v?v.EF-P.K0.getCurrentTime():0}; KgD=function(P,v){if(P.G.length){if(P.G[0].info.N5[0].startTime<=v)return;ay(P)}for(var l=P.Y,e=l.K.length-1;e>=0;e--)l.K[e].info.startTime>v&&l.K.pop();nTy(P);P.K&&v =0;m--){var Q=h.K[m];Q.info.n0>=v&&(h.K.pop(),h.G-=zB(Q,h.policy.Nd),z=Q.info)}z&&(h.Z=h.K.length>0?h.K[h.K.length-1].info:h.q5,h.K.length!==0||h.Z||nL(h,"r"));h.K0.f0("mdstm",{rollbk:1,itag:z?z.W.info.itag:"",popped:z?z.n0:-1,sq:v,lastslc:h.Z?h.Z.n0:-1,lastfraget:h.G.toFixed(3)});if(P.policy.W)return P.K=null,!0;e>l?W6(P,e):P.K=P.W.UX(v-1,!1).N5[0]}catch(t){return v=LW(t),v.details.reason= "rollbkerr",P.K0.handleError(v.errorCode,v.details,v.severity),!1}return!0}; iW=function(P,v){var l;for(l=0;l 0?l||v.n0>=P.kf:l}; Z2=function(P){var v;return pL(P)||SD(P,(v=P.Y.iE())==null?void 0:v.info)}; xb=function(P){var v=[],l=Fr(P);l&&v.push(l);v=g.PZ(v,P.Y.D7());l=g.N(P.G);for(var e=l.next();!e.done;e=l.next()){e=e.value;for(var h=g.N(e.info.N5),z=h.next(),m={};!z.done;m={nS:void 0},z=h.next())m.nS=z.value,e.Cf&&(v=g.$g(v,function(Q){return function(t){return!MLW(t,Q.nS)}}(m))),(BH(m.nS)||m.nS.type===4)&&v.push(m.nS)}P.K&&!jSw(P.K,g.WA(v),P.K.W.k9())&&v.push(P.K); return v}; N6y=function(P,v){if(!P.length)return!1;for(v+=1;v =v){v=z;break a}}v=h}return v<0?NaN:N6y(P,l?v:0)?P[v].startTime:NaN}; jD=function(P){return!(!P.K||P.K.W===P.W)}; cpx=function(P){return jD(P)&&P.W.cP()&&P.K.W.info.FJ v&&e.EF 1080&&!P.AX&&(P.Pg=36700160,P.Bg=5242880,P.q5=Math.max(4194304,P.q5),P.AX=!0);v.video.W>2160&&!P.yd&&(P.Pg=104857600,P.FJ=13107200,P.yd=!0);g.ID(P.Z3.experiments,"html5_samsung_kant_limit_max_bitrate")!==0?v.isEncrypted()&&g.VS()&&g.Mc("samsung")&&(g.Mc("kant")||g.Mc("muse"))&&(P.FJ=g.ID(P.Z3.experiments,"html5_samsung_kant_limit_max_bitrate")):v.isEncrypted()&&g.VS()&&g.Mc("kant")&&(P.FJ=1310720);P.Gq!==0&&v.isEncrypted()&&(P.FJ=P.Gq);P.J8!==0&&v.isEncrypted()&& l&&(P.FJ=P.J8);v.FJ&&(P.ke=Math.max(P.RO,Math.min(P.q5,5*v.FJ)))}; oc=function(P){return P.W&&P.Yy&&P.playbackStartPolicy}; s9=function(P){return P.K||P.W&&P.Ro}; rq=function(P,v,l,e){P.Yy&&(P.playbackStartPolicy=v,P.f5=l,P.Al=e)}; O9=function(P,v,l){l=l===void 0?0:l;return g.ID(P.Z3.experiments,v)||l}; Ut6=function(P){var v=P===void 0?{}:P;P=v.M_;var l=v.dH;var e=v.aY;var h=v.vR;v=v.u2;this.M_=P;this.dH=l;this.aY=e;this.vR=h;this.u2=v}; H6x=function(P,v){if(v<0)return!0;var l=P.vR();return v 0)return 2;if(v<0)return 1;l=P.vR();return v (0,g.Gz)()?0:1}; Tb=function(P,v,l,e,h,z,m,Q,t,y,C,f,k,w){w=w===void 0?null:w;g.U.call(this);var I=this;this.K0=P;this.policy=v;this.videoTrack=l;this.audioTrack=e;this.Y=h;this.W=z;this.timing=m;this.Z=Q;this.schedule=t;this.rM=y;this.G=C;this.Wg=f;this.oh=k;this.Mw=w;this.QW=!1;this.Ze="";this.HT=null;this.WB=NaN;this.J5=!1;this.K=null;this.tQ=this.X=NaN;this.Tq=this.T=0;this.logger=new g.Rf("dash");this.Kh={tU:function(J,K){return I.tU(J,K)}}; this.policy.v3>0&&(this.Ze=g.YR(this.policy.v3));this.policy.MZ&&(this.S=new MJ(this.K0,this.policy,this.schedule),g.Z(this,this.S))}; ETw=function(P,v,l){var e=v.K?v.K.W.JR:v.W.JR;var h=P.Y,z;(z=!P.policy.uB)||(z=AR(e.W)===AR(e.G));z?e=!1:(h=ud(h,AR(e.G)),z=6E4*Math.pow(h.Y,1.6),(0,g.Gz)() =h.Y?(h.f0("sdai",{haltrq:z+1,est:h.Y}),e=!1):e=h.K!==2;if(!e||!A_(v.K?v.K.W.JR:v.W.JR,P.policy,P.Y,P.K0.Aw())||P.K0.isSuspended&&(!AW(P.schedule)||P.K0.v$))return!1;if(P.policy.Y&&XX>=5)return g.RX(P.K0.a$),!1;if(P.rM.isManifestless){if(v.G.length>0&&v.K&&v.K.n0===-1||v.G.length>=P.policy.G5||!P.policy.u1&&v.G.length>0&&!P.policy.S.dH)return!1;if(v.j)return!P.rM.isLive||!isNaN(P.WB)}if(bq9(v))return P.logger.debug("Pending request with server-selectable format found"), !1;if(!v.K){if(!v.W.cP())return!1;W6(v,P.K0.getCurrentTime())}if(rb(v)&&(v.iE()!==rb(v)||P.K0.isSuspended))return!1;h=(e=P.policy.Hb)&&!v.G.length&&Gb(v,!0) =P.policy.kV)return!1;e=v.K;if(!e)return!0;e.type===4&&e.W.cP()&&(v.K=g.WA(e.W.Cx(e)),e=v.K);if(!e.c9()&&!e.W.Ss(e))return!1;z=P.rM.cz||P.rM.Y;if(P.rM.isManifestless&&z){z=v.W.index.vR();var m=l.W.index.vR(); z=Math.min(z,m);if(v.W.index.Qt()>0&&z>0&&e.n0>=z)return v.kf=z,l.kf=z,!1}if(e.W.info.audio&&e.type===4||e.c9())return!1;z=!v.Z&&!l.Z;if(h=!h)h=e.EF,h=!!(l.K&&!SD(l,l.K)&&l.K.EF Wga(P,v)?(Wga(P,v),!1):(P=v.mZ)&&P.isLocked()?!1:!0}; Wga=function(P,v){var l=P.W;l=l.W?l.W.Or:null;if(P.policy.kf&&l)return l.startSecs+l.Er+15;v=Ee(P.K0,v);P.policy.jS>0&&(l=((0,g.Gz)()-P.K0.Yq)/1E3,v=Math.min(v,P.policy.jS+P.policy.wl*l));l=P.K0.getCurrentTime()+v;return P.policy.hX&&(v=OqD(P.K0)+P.policy.hX,v =0||v.JR.Ts("defrag")==="1"||v.JR.Ts("otf")==="1"){v=null;break a}h=Lo(0,4096)}h=new a1([new G8(5,e.W,h,"createProbeRequestInfo"+e.Z,e.n0)],v.K);h.qZ=l;h.W=v.W;v=h}v&&dq(P,v)}}; dq=function(P,v){P.K0.BH(v);var l=VL6(v),e=P.K0.a8();l={Ob:P.schedule,Sf:l,G4:I9a(P.Z,l),QQ:XI(v.N5[0]),Lk:Y_(v.JR.W),Ie:P.policy.G,u_:function(m,Q){P.K0.pS(m,Q)}}; if(P.schedule.K.j){var h,z;l.sY=(((h=P.videoTrack.W)==null?void 0:h.info.FJ)||0)+(((z=P.audioTrack.W)==null?void 0:z.info.FJ)||0)}P.HT&&(l.n0=v.N5[0].n0,l.WB=v.WB,l.HT=P.HT);e={MX:dgy(v,P.K0.getCurrentTime()),Xt:P.policy.Hl&&E8(v)&&v.N5[0].W.info.video?LK9(P.G):void 0,Lr:P.policy.kf,poToken:P.K0.lw(),Of:P.K0.LN(),Ze:P.Ze,tQ:isNaN(P.tQ)?null:P.tQ,Mw:P.Mw,oh:P.oh,Tq:P.Tq,ol:e};return new jT(P.policy,v,l,P.Y,function(m,Q){try{a:{var t=m.info.N5[0].W,y=t.info.video?P.videoTrack:P.audioTrack;if(!(m.state>= 2)||m.isComplete()||m.zI()||!(!P.K0.u$||P.K0.isSuspended||Gb(y)>3)){var C=alD(m,P.policy,P.Y);C===1&&(P.J5=!0);oTw(P,m,C);if(m.isComplete()||m.s$()&&Q<3){if(P.policy.G){var f=m.timing.WI();f.rst=m.state;f.strm=m.xhr.DC();f.cncl=m.xhr&&m.Eb.Y?1:0;P.K0.f0("rqs",f)}m.xW&&P.K0.f0("sbwe3",{},!0)}if(!P.s$()&&m.state>=2){mNu(P.timing,m,t);var k=P.K0;P.tQ&&m.MI&&k&&(P.tQ=NaN,P.K0.tE(m.MI),P.K0.kU(),P.K0.f0("cabrUtcSeek",{mediaTimeSeconds:m.MI}));m.Uj&&P.tQ&&m.Uj&&!m.Uj.action&&(P.K0.Wh(P.tQ),P.tQ=NaN,P.K0.f0("cabrUtcSeekFallback", {targetUtcTimeSeconds:P.tQ}));m.I7&&P.K0.zB(m.I7);P.policy.hs&&(P.Tq=m.Tq);if(m.state===3){iW(y,m);E8(m.info)&&PU(P,y,t,!0);if(P.K){var w=m.info.gZ();w&&P.K.Lw(m.info.N5[0].n0,t.info.id,w)}P.K0.p6()}else if(m.isComplete()&&m.info.N5[0].type===5){if(m.state!==4)m.Tr()&&P.K0.handleError(m.nJ(),m.h4());else{var I=(m.info.N5[0].W.info.video?P.videoTrack:P.audioTrack).G[0]||null;I&&I instanceof jT&&I.zI()&&I.UK(!0)}m.dispose()}else{m.Tr()||sKq(P,m);var J;((J=m.Bd)==null?0:J.itagDenylist)&&P.K0.Mr(m.Bd.itagDenylist); if(m.state===4)vU(P,m),P.W&&y_u(P.W,m.info,P.K);else if(P.policy.CO&&m.Ps()&&!m.isComplete()&&!vU(P,m)&&!m.Tr())break a;m.Tr()&&(rpx(P,m),isNaN(P.tQ)||(P.K0.Wh(P.tQ),P.tQ=NaN));P.policy.Xq&&!m.isComplete()?lS(P.K0):P.K0.p6();var K=Hq2(m,P.policy,P.Y);oTw(P,m,K)}}}}}catch(q){Q=P.QW?1:0,P.QW=!0,m=pW(Q),Q=LW(q,Q),P.K0.handleError(Q.errorCode,Q.details,Q.severity),m||P.K0.uZ()}},e)}; sKq=function(P,v){if(v.vE&&v.state>=2&&v.state!==3){var l=v.xhr.getResponseHeader("X-Response-Itag");if(l){P.logger.debug(function(){return"Applying streamer-selected format "+l}); var e=pHu(P.G,l),h=v.info.G;h&&(h-=e.Ge(),e.G=!0,v.info.N5[0].W.G=!1,Xn7(v,e.oA(h)),eA(P.K0,P.videoTrack,e),xt6(P.videoTrack,e),P.K0.f8(e.info.video.quality),(h=v.HA())&&e.info.lastModified&&e.info.lastModified!==+h&&iW(P.videoTrack,v))}else v.vE=!1}}; rpx=function(P,v){var l=v.info.N5[0].W,e=v.nJ();if(Y_(l.JR.W)){var h=g.n$(v.fX(),3);P.K0.f0("dldbrerr",{em:h||"none"})}h=v.info.N5[0].n0;var z=H8(P.W,v.info.N5[0].ao,h);e==="net.badstatus"&&(P.T+=1);if(v.canRetry()&&hs(P.K0)){if(!(v.info.JR.K>=P.policy.dJ&&P.K&&v.info.isDecorated()&&e==="net.badstatus"&&P.K.Co(z,h))){h=(l.info.video&&l.JR.K>1||v.zW===410||v.zW===500||v.zW===503)&&!(rN(P.G.Z).size>0)&&!Y_(l.JR.W);z=v.h4();var m=l.info.video?P.videoTrack:P.audioTrack;h&&(z.stun="1");P.K0.handleError(e, z);P.s$()||(h&&(P.logger.debug(function(){return"Stunning format "+l.info.id}),vm(P.G,l)),iW(m,v),P.K0.p6())}}else m=1,P.K&&v.info.isDecorated()&&e==="net.badstatus"&&P.K.Co(z,h)&&(m=0),P.rM.isLive&&v.nJ()==="net.badstatus"&&P.T<=P.policy.lE*2?(d6u(P.rM),P.rM.cz||P.rM.isPremiere?se(P.K0,0,{mD:"badStatusWorkaround"}):P.rM.Y?se(P.K0,P.rM.Hg,{mD:"badStatusWorkaround", VT:!0}):zK(P.K0)):P.K0.handleError(e,v.h4(),m)}; vU=function(P,v){if(P.policy.useUmp&&v.s$())return!1;try{var l=v.info.N5[0].W,e=l.info.video?P.videoTrack:P.audioTrack;if(P.rM.isManifestless&&e){P.T=0;e.j&&(v.s$(),v.isComplete()||v.Ps(),e.j=!1);v.DD()&&P.K0.Eu.mG(1,v.DD());var h=v.Qt(),z=v.zY();Ap(P.rM,h,z)}if(v.info.QQ()&&!HH(v.info))for(var m=g.N(v.vT()),Q=m.next();!Q.done;Q=m.next())Dt7(e,Q.value);for(P.K0.getCurrentTime();e.G.length&&e.G[0].state===4;){var t=e.G.shift();Ilw(e,t);e.q5=t.aR()}e.G.length&&Ilw(e,e.G[0]);var y=!!rb(e);y&&v instanceof ZL&&(l.info.h3()?d9x(P.timing):VMD(P.timing));return y}catch(C){v=v.h4();v.origin="hrhs";a:{P=P.K0;l=C;if(l instanceof Error){v.msg||(v.msg=""+l.message);v.name||(v.name=""+l.name);if(l instanceof g.Ph&&l.args)for(e=g.N(Object.entries(l.args)),h=e.next();!h.done;h=e.next())z=g.N(h.value),h=z.next().value,z=z.next().value,v["arg"+h]=""+z;g.j4(l);if(l.level==="WARNING"){P.M5.DH(v);break a}}P.handleError("fmt.unplayable",v,1)}return!1}}; May=function(P){var v=P.videoTrack.W.index;P.HT=new Ut6({M_:P.policy.M_,dH:P.policy.S.dH,aY:v.uP(),vR:function(){return v.vR()}, u2:function(){return v.u2()}})}; PU=function(P,v,l,e){if(!(l.cP()||l.DI()||l.G||!A_(l.JR,P.policy,P.Y)||l.info.dM==="f"||P.policy.W)){if(e){e=P.Z;var h=l.info;e=DED(e,h.video?e.policy.T5:e.policy.UU,h.FJ)}else e=0;e=l.oA(e);P=dq(P,e);HH(e)&&AE(v,P);l.G=!0}}; mM=function(P,v,l,e,h,z,m,Q){g.U.call(this);var t=this;this.K0=P;this.iq=v;this.videoTrack=l;this.audioTrack=e;this.rM=h;this.X=z;this.isAudioOnly=m;this.j=Q;this.K=Ov;this.J5=!1;this.logger=new g.Rf("sabr");this.S=this.QW=this.Wg=!1;this.videoInfos=this.Z=this.X.videoInfos;this.G=this.T1=this.X.W;this.W=new of(v,z,function(y,C){t.K0.f0(y,C)}); this.iq.RK||T6B(this);this.isAudioOnly&&VaD(this,this.rM.W["0"])}; dtB=function(P,v){var l=[];v=g.N(v);for(var e=v.next();!e.done;e=v.next())l.push(g.es(e.value,P.rM.Ei));return l}; VaD=function(P,v,l){v!==P.Y&&(P.Y&&(P.J5=!0),P.Y=v,P.f2(v,P.videoTrack,l))}; lY2=function(P,v){P.logger.debug("setConstraint: "+fr(v));s9(P.iq)&&(P.QW=v.reason==="m"||v.reason==="l"?!0:!1);v.reason==="m"?v.isLocked()&&Py7(P,v.W):vQ7(P,v)?Rz(P,v.K,v.W):P.videoInfos=P.Z;P.K=v}; vQ7=function(P,v){return P.iq.NH&&v.reason==="b"||P.iq.lB?!1:P.iq.pV?!0:v.reason==="l"||v.reason==="b"||v.reason==="o"}; e4y=function(P,v){return v.isLocked()&&P.W.K||P.K===void 0?!1:v.ZA(P.K)}; h4w=function(P,v){var l,e=(l=P.Y)==null?void 0:l.info.video.W;return P.J5?!0:P.Y?v!==e?!0:!P.W.K||P.iq.sZ&&P.W.W===P.Y.info.itag?!1:!0:!1}; Py7=function(P,v){var l=P.W.W;if(l){P.videoInfos=P.Z;var e=g.om(P.videoInfos,function(h){return h.id===l}); e&&e.video.W===v?P.videoInfos=[e]:(e=P.videoInfos.map(function(h){return h.id}),P.K0.f0("sabrpf",{pfid:""+l, vfids:""+e.join(".")}),Rz(P,v,v),Mn(P.W,""))}else Rz(P,v,v)}; Rz=function(P,v,l){P.videoInfos=P.Z;P.videoInfos=g.$g(P.videoInfos,function(e){return e.video.W>=v&&e.video.W<=l})}; T6B=function(P){var v=k8P(P.W,P.j);v&&(P.G=[v])}; z4y=function(P,v,l){if(P.iq.RK){if(P.j){var e=g.$g(P.G,function(h){return h.id===P.j}); return Q9(e,l).includes(v)}e=g.$g(P.G,function(h){var z;return!((z=h.Rt)==null||!z.isDefault)}); if(e.length>0)return Q9(e,l).includes(v)}return Q9(P.G,l).includes(v)}; Q9=function(P,v){return P.map(function(l){return Y2(g.es(l,v))})}; my6=function(P){var v;if((v=P.K)==null?0:v.isLocked())return P.videoInfos;var l=rN(P.W);v=g.$g(P.videoInfos,function(e){return e.FJ>P.iq.FJ?!1:!l.has(e.id)}); g2w(P.W)&&(v=g.$g(v,function(e){return e.video.width<=854&&e.video.height<=480})); return v}; tED=function(P,v,l,e){var h=P.rM,z=P.M5.getVideoData(),m=g.VW(z),Q=P.qT,t=Jy({Z3:z.N(),M5:P.M5,rV:P.rV,iq:P.iq,Yq:P.Yq,Rj:P.Rj,W5:P.W5,ys:P.ys,r0:P.r0,isPrefetch:P.isPrefetch,CT:P.CT,sabrLicenseConstraint:z.sabrLicenseConstraint,Vs:P.Vs,KW:P.KW,sx:P.sx,z3:P.z3,uJM:!!Q}),y=uu(z,P.ol,P.nextRequestPolicy,P.J1,P.G9,P.Wfc,P.R6);e&&l&&(e=y.n9?y.n9.map(function(J){return J.type}):[],l("ssap",{stmctxt:e.join("_"), unsntctxt:y.nG?y.nG.join("_"):""}));e=P.o9;var C=P.I9;if(C===void 0&&e===void 0){var f;C=R4P(h.Ei,(f=P.pj)==null?void 0:f.video);var k;e=R4P(h.Ei,(k=P.pj)==null?void 0:k.audio)}if(z.Mw)var w=z.Mw;z={YL:t,wi:P.wi,o9:e,I9:C,qT:Q,videoPlaybackUstreamerConfig:w,kP:y};P.o3&&(z.o3=P.o3);if(m&&v){m=new Map;var I=g.N(h.wM);for(Q=I.next();!Q.done;Q=I.next())Q=Q.value,(t=h.Pg[XBy(h,Q)]||"")?(m.has(t)||m.set(t,[]),m.get(t).push(Q)):l&&l("ssap",{nocid4fmt:(Q.itag||"")+"_"+(Q.lmt||0)+"_"+(Q.xtags||"")});h=new Map; I=g.N(P.hR);for(Q=I.next();!Q.done;Q=I.next())Q=Q.value,t=Q.startTimeMs||0,y=void 0,f=(y=v)==null?void 0:iU(y,t),y=f.clipId,f=f.zr,y?(h.has(y)||(k=m.get(y)||[],h.set(y,{clipId:y,hR:[],O6:k})),f!==0&&(Q.startTimeMs=t-f),h.get(y).hR.push(Q)):l&&(y=void 0,l("ssap",{nocid4range:"1",fmt:((y=Q.formatId)==null?void 0:y.itag)||"",st:t.toFixed(3),d:(Q.durationMs||0).toFixed(3),timeline:ts(v)}));z.W4=[];h=g.N(h.entries());for(m=h.next();!m.done;m=h.next())m=g.N(m.value),m.next(),m=m.next().value,z.W4.push(m); if(P.hR.length&&!z.W4.length){l&&l("ssap",{nobfrange:"1",br:QwP(P.hR),timeline:ts(v)});return}P.L5&&(z.L5=P.L5);P.K5&&(z.K5=P.K5)}else z.hR=P.hR,z.O6=h.wM,m&&((I=P.hR)==null?void 0:I.length)>0&&!v&&l&&l("ssap",{bldmistlm:"1"});return z}; R4P=function(P,v){return v?[g.es(v.info,P)]:[]}; QwP=function(P){var v="";P=g.N(P);for(var l=P.next();!l.done;l=P.next()){l=l.value;var e=void 0,h=void 0,z=void 0;v+="fmt."+(((e=l.formatId)==null?void 0:e.itag)||"")+"_"+(((h=l.formatId)==null?void 0:h.lmt)||0)+"_"+(((z=l.formatId)==null?void 0:z.xtags)||"")+";st."+(l.startTimeMs||0).toFixed(3)+";d."+(l.durationMs||0).toFixed(3)+";"}return v}; y9=function(P,v,l){var e=this;this.requestType=P;this.JR=v;this.Md=l;this.K=null;this.Kh={Ga2:function(){var h;return(h=e.data)==null?void 0:h.isPrefetch}, G9:function(){var h;return(h=e.data)==null?void 0:h.G9}}}; saq=function(P,v,l){v=qN(P.JR,yW6(P,v,l),v);P.Iq()&&v.set("probe","1");return v}; yW6=function(P,v,l){P.qZ===void 0&&(P.qZ=P.JR.qZ(v,l));return P.qZ}; Cyw=function(P){var v,l;return((v=P.W)==null?void 0:(l=v.YL)==null?void 0:l.n8)||0}; fY2=function(P){var v,l;return!!((v=P.W)==null?0:(l=v.YL)==null?0:l.Vs)}; gQy=function(P){var v={},l=[],e=[];if(!P.data)return v;for(var h=0;h 0;t--)l.push(Q)}l.length!==m?v.error=!0:(z=l.slice(-z),l.length=h,xy7(v,l,z));break;case 1:xy7(v,HU,EH);break;case 0:V9(v, v.W&7);l=MK(v,16);h=MK(v,16);(l^h)!==65535&&(v.error=!0);v.output.set(v.data.subarray(v.K,v.K+l),v.G);v.K+=l;v.G+=l;break;default:v.error=!0}P.G>P.output.length&&(P.output=new Uint8Array(P.G*2),P.G=0,P.K=0,P.Y=!1,P.W=0,P.register=0)}P.output.length!==P.G&&(P.output=P.output.subarray(0,P.G));return P.error?new Uint8Array(0):P.output}; xy7=function(P,v,l){v=TK(v);l=TK(l);for(var e=P.data,h=P.output,z=P.G,m=P.register,Q=P.W,t=P.K;;){if(Q<15){if(t>e.length){P.error=!0;break}m|=(e[t+1]<<8)+e[t]< >=7;y<0;)y=v[(m&1)-y],m>>=1;else m>>=y&15;Q-=y&15;y>>=4;if(y<256)h[z++]=y;else if(P.register=m,P.W=Q,P.K=t,y>256){m=OH[y];m+=MK(P,WU[y]);t=bPD(P,l);Q=sH[t];Q+=MK(P,oz[t]);if(LxP&&ml.length&&(P.error=!0);P.register|=(l[e+1]<<8)+l[e]<=0)return V9(P,l&15),l>>4;for(V9(P,7);l<0;)l=v[MK(P,1)-l];return l>>4}; MK=function(P,v){for(;P.W =P.data.length)return P.error=!0,0;P.register|=P.data[P.K++]< >=v;P.W-=v;return l}; V9=function(P,v){P.W-=v;P.register>>=v}; TK=function(P){for(var v=[],l=g.N(P),e=l.next();!e.done;e=l.next())e=e.value,v[e]||(v[e]=0),v[e]++;var h=v[0]=0;l=[];var z=0;e=0;for(var m=1;m 7&&(z+=v[m]);for(h=1;h >t&1;Q=z<<4|m;if(m<=7)for(t=1<<7-m;t--;)e[t< >=7;m--;){e[t]||(e[t]=-v,v+=2);var y=h&1;h>>=1;t=y-e[t]}e[t]=Q}}return e}; SMD=function(P){var v,l,e,h,z,m,Q;return g.p(function(t){switch(t.W){case 1:if(!("DecompressionStream"in window))return t.return(g.pa6(new g.rg(P)));v=new DecompressionStream("gzip");l=v.writable.getWriter();l.write(P);l.close();e=v.readable.getReader();h=new uh([]);case 2:return g.b(t,e.read(),5);case 5:z=t.K;m=z.value;if(Q=z.done){t.ac(4);break}h.append(m);t.ac(2);break;case 4:return t.return(h.Yt())}})}; dg=function(P,v){this.W=P;this.X_=v}; GF7=function(P){return n6(n6($f(function(){return D9(P.X_,function(v){return P.bO(P.W,v)})}),function(){return P.v_(P.W)}),function(){return P.uO(P.W)})}; XaD=function(P,v){return GF7(new dg(P,v))}; UyW=function(P){qn.call(this,"onesie");this.Lh=P;this.W={};this.G=!0;this.Y=null;this.queue=new Z$(this);this.Z={};this.T=Pq2(function(v,l){var e=this;return function z(){var m,Q,t,y,C,f,k,w,I,J,K,q,A,x,S,B,E,r,hq,R7;return gaa(z,function(Pw){switch(Pw.W){case 1:g.Jq(Pw,2);e.Lh.GH();m=function(H){return function(T){throw{name:H,message:T};}}; Q=v.Yt();g.NP(Pw,4,5);if(!l){Pw.ac(7);break}return t92(Pw,n6(B7W(e.Lh,Q,e.iv),m("DecryptError")).wait(),8);case 8:t=Pw.K;case 7:if(!e.Lh.enableCompression){Pw.ac(9);break}return t92(Pw,n6(XaD((f=t)!=null?f:Q,e.Lh.N().oz),m("DecompressError")).wait(),10);case 10:y=Pw.K;case 9:C=Oi((w=(k=y)!=null?k:t)!=null?w:Q,dxP);case 5:g.cw(Pw,0,2);if(J=(I=e.Lh.N())==null?void 0:I.X_)((K=t)==null?void 0:K.buffer)===J.exports.memory.buffer&&J.free(t.byteOffset),((q=y)==null?void 0:q.buffer)===J.exports.memory.buffer&& J.free(y.byteOffset);g.qP(Pw,6);break;case 4:throw x=A=g.Kx(Pw),new xq("onesie.response.parse",{name:(r=x.name)!=null?r:"unknown",message:(hq=x.message)!=null?hq:"unknown",wasm:((S=e.Lh.N())==null?0:S.X_)?((B=e.Lh.N())==null?0:(E=B.X_)==null?0:E.MH)?"1js":"1":"0",enc:e.G,gz:e.Lh.enableCompression,webcrypto:!!qj()});case 6:return iPD(C),R7=g.pa(C.body),Pw.return(R7);case 2:g.cw(Pw),g.qP(Pw,0)}})}()})}; ZPw=function(P){var v=P.queue;v.W.length&&v.W[0].isEncrypted&&!v.K&&(v.W.length=0);v=g.N(Object.keys(P.W));for(var l=v.next();!l.done;l=v.next()){l=l.value;var e=P.W[l];if(!e.Y$){var h=P.queue;h.W.push({videoId:e.videoId,formatId:l,isEncrypted:!1});h.K||az(h)}}}; aYD=function(P,v){var l=v.getLength(),e=!1;switch(P.Y){case 0:P.Lh.V("html5_future_onesie_ump_handler_on_player_response")?n6(D9(P.T(v,P.G),function(h){jww(P.Lh,h)}),function(h){P.Lh.qw(h)}):P.GH(v,P.G).then(function(h){jww(P.Lh,h)},function(h){P.Lh.qw(h)}); break;case 2:P.g9("ormk");v=v.Yt();P.queue.decrypt(v);break;default:e=!0}P.Lh.JA&&P.Lh.f0("ombup","id.11;pt."+P.Y+";len."+l+(e?";ignored.1":""));P.Y=null}; iPD=function(P){if(P.hH!==1)throw new xq("onesie.response.badproxystatus",{st:P.hH,webcrypto:!!qj(),textencoder:!!g.Uy.TextEncoder});if(P.wD!==200)throw new xq("onesie.response.badstatus",{st:P.wD});}; HPW=function(P){return new Promise(function(v){setTimeout(v,P)})}; EQ6=function(P,v){var l=P.N();l=P.oV&&l.V("html5_onesie_preload_use_content_owner");var e=P.ME,h=eE(v.O$.experiments,"debug_bandaid_hostname");if(h)v=BU(v,h);else if((l===void 0?0:l)&&(e==null?0:e.url)&&!v.K){var z=AR(new g.q9(e.url));v=BU(v,z)}else v=(z=v.W.get(0))==null?void 0:z.location.clone();if(v&&P.videoId){z=fP(P.videoId);P=[];if(z)for(z=g.N(z),l=z.next();!l.done;l=z.next())P.push(l.value.toString(16).padStart(2,"0"));v.set("id",P.join(""));return v}}; Wx2=function(P,v,l){l=l===void 0?0:l;var e,h;return g.p(function(z){if(z.W==1)return e=[],e.push(v.load()),l>0&&e.push(HPW(l)),g.b(z,Promise.race(e),2);h=EQ6(P,v);return z.return(h)})}; OPa=function(P,v,l,e){e=e===void 0?!1:e;P.set("cpn",v.clientPlaybackNonce);P.set("opr","1");var h=v.N();P.set("por","1");qj()||P.set("onem","1");v.startSeconds>0&&P.set("osts",""+v.startSeconds);e||(h.V("html5_onesie_disable_partial_segments")&&P.set("oses","1"),v=h.V("html5_gapless_onesie_no_media_bytes")&&Rh(v)&&v.oV,l&&!v?(v=l.audio,P.set("pvi",l.video.join(",")),h.V("html5_onesie_disable_audio_bytes")||P.set("pai",v.join(",")),ly||P.set("osh","1")):(P.set("oad","0"),P.set("ovd","0"),P.set("oaad", "0"),P.set("oavd","0")))}; oQa=function(P,v,l,e,h){h=h===void 0?!1:h;var z="https://youtubei.googleapis.com/youtubei/"+v.xt.innertubeApiVersion+"/player",m=[{name:"Content-Type",value:"application/json"}];e&&m.push({name:"Authorization",value:"Bearer "+e});m.push({name:"User-Agent",value:g.Y3()});g.la("EOM_VISITOR_DATA")?m.push({name:"X-Goog-EOM-Visitor-Id",value:g.la("EOM_VISITOR_DATA")}):(l=l.visitorData||g.la("VISITOR_DATA"))&&m.push({name:"X-Goog-Visitor-Id",value:l});(l=g.la("SERIALIZED_LAVA_DEVICE_CONTEXT"))&&m.push({name:"X-YouTube-Lava-Device-Context", value:l});(v=eE(v.experiments,"debug_sherlog_username"))&&m.push({name:"X-Youtube-Sherlog-Username",value:v});P=Gi(JSON.stringify(P));return{url:z,BA:m,postBody:P,R31:h,Ji:h}}; rWD=function(P,v,l,e,h,z){var m=g.yg(P,Vy9,P.Ji?void 0:l.X_),Q={encryptedClientKey:v.W.encryptedClientKey,IM:!0,UM:!0,ws:swP(l,!!P.Ji),Lm:l.experiments.l$("html5_use_jsonformatter_to_parse_player_response")};if(P.Ji)Q.vMc=m;else{P=v.encrypt(m);var t;if(((t=l.X_)==null?void 0:t.exports.memory.buffer)===m.buffer&&P.byteOffset!==m.byteOffset){var y;(y=l.X_)==null||y.free(m.byteOffset)}var C;P=((C=l.X_)==null?void 0:C.XT(P))||P;m=Q.F8=P;(0,g.Gz)();m=Mg6(new r$D(v.W.G),m,v.iv);Q.H_=m;Q.iv=v.iv}v=e.getVideoData(); l=Jy({Z3:l,M5:e,rV:v.startSeconds*1E3});h={W2:Q,YL:l,onesieUstreamerConfig:h,YB:z,kP:uu(v)};v.reloadPlaybackParams&&(h.reloadPlaybackParams=v.reloadPlaybackParams);return h}; MEy=function(P,v,l){var e,h,z;return g.p(function(m){if(m.W==1)return e=g.yg(v,Vy9),g.b(m,N7D(l,e),2);if(m.W!=3)return h=m.K,g.b(m,JWP(l,h),3);z=m.K;return m.return({F8:h,encryptedClientKey:l.W.encryptedClientKey,iv:l.iv,H_:z,IM:!0,UM:!0,ws:swP(P,!!v.Ji),Lm:P.experiments.l$("html5_use_jsonformatter_to_parse_player_response")})})}; T7W=function(P,v,l,e,h,z){var m,Q,t,y;return g.p(function(C){if(C.W==1)return g.b(C,MEy(l,P,v),2);m=C.K;Q=e.getVideoData();t=Jy({Z3:l,M5:e,rV:Q.startSeconds*1E3});y={W2:m,YL:t,onesieUstreamerConfig:h,YB:z,kP:uu(Q)};Q.reloadPlaybackParams&&(y.reloadPlaybackParams=Q.reloadPlaybackParams);return C.return(y)})}; swP=function(P,v){P=Fu(P.schedule,!0);v=v||!!qj()&&P>1572864;return"DecompressionStream"in window||!v}; vR=function(P,v){g.U.call(this);var l=this;this.M5=P;this.playerRequest=v;this.O$=this.M5.N();this.videoData=this.M5.getVideoData();this.logger=new g.Rf("onesie");this.JA=this.O$.vK();this.LB=this.O$.hN;this.PE=new GK(this.LB.W,this.O$.oz,kFy(this.O$));this.xhr=null;this.state=1;this.A8=new PP;this.Tf=!1;this.playerResponse="";this.I5=new lu(this);this.zm=new UyW(this);this.b4=this.O$.V("html5_onesie_check_timeout");this.x3=new g.mr(this.wg,500,this);this.dB=new g.mr(this.Rx,1E4,this);this.Ew=new g.mr(function(){if(!l.isComplete()){var e= PR(l);l.qw(new xq("net.timeout",e))}},g.ID(this.O$.experiments,"html5_onesie_request_timeout_ms")); this.yB=new g.mr(this.LZ1,2E3,this);this.Vc="";this.Fg=this.eV=!1;this.sG=this.M5.LN();this.Wc="";this.mj=this.V("html5_onesie_wait_for_media_availability");this.enableCompression=this.i6=this.xD=!1;this.ZG=[];this.xA=this.lZ=-1;g.Z(this.videoData,this);g.Z(this,this.x3);g.Z(this,this.dB);g.Z(this,this.yB);g.Z(this,this.PE);P=mx();ly&&P&&!this.O$.V("html5_disable_onesie_media_bytes")&&(this.WP=new Map);this.cH=new Map;this.CA=new Map;this.Hk=new Map;this.xp=new Map}; jA=function(P,v){var l;return(l=P.WP)==null?void 0:l.get(v)}; dyP=function(P,v,l){var e;return g.p(function(h){if(h.W==1)return P.g9("oprd_s"),VEa(P)?g.b(h,uuW(P.PE,v,l),3):(e=P.PE.decrypt(v,l),h.ac(2));h.W!=2&&(e=h.K);P.g9("oprd_c");return h.return(e)})}; B7W=function(P,v,l){P.g9("oprd_s");v=nQy(P.PE).encrypt(v,l);D9(v,function(){P.g9("oprd_c")}); return v}; PN9=function(P){return P.V("html5_onesie_host_probing")||P.JA?ly:!1}; jww=function(P,v){P.g9("oprr");P.playerResponse=v;P.i6||(P.mj=!1);l7(P)}; l7=function(P){if(!P.playerResponse)return!1;if(P.xD)return!0;var v=P.videoData.V("html5_onesie_audio_only_playback")&&Qi(P.videoData);if(P.WP&&P.mj){if(!P.WP.has(P.Vc))return!1;var l=P.WP.get(P.Vc),e;if(e=l){e=!1;for(var h=g.N(l.r9.keys()),z=h.next();!z.done;z=h.next())if(z=l.r9.get(z.value))for(var m=g.N(z.wB),Q=m.next();!Q.done;Q=m.next())Q.value.pR>0&&(z.h3?e=!0:v=!0);e=!(v&&e)}if(e)return!1}P.g9("ofr");P.A8.resolve(P.playerResponse);if(!P.b4){var t;(t=P.Ew)==null||t.start();P.dB.start()}return P.xD= !0}; lvy=function(P){if(P.WP&&!P.V("html5_onesie_media_capabilities")){P.g9("ogsf_s");var v=cRW(P.M5.getVideoData(),function(e,h){P.f0(e,h)}),l=vHW(P.M5); v.video=wna(l,v.video);P.g9("ogsf_c");if(v.video.length)return v;P.f0("ombspf","l."+l.K+";u."+l.W+";o."+l.G+";r."+l.reason)}}; VEa=function(P,v){return P.V("html5_onesie_sync_request_encryption")||(v==null?0:v.Ji)||g.lN(P.O$)&&P.V("html5_embed_onesie_use_sync_encryption")?!1:!!qj()}; PR=function(P){if(!P.F_)return{};var v=P.F_.WI(),l;v.d=(l=P.F_.wM)==null?void 0:l.vB();v.shost=P.p$;v.ty="o";return v}; eC9=function(P,v){var l,e;(e=(P=(l=P.WP)==null?void 0:l.get(v))==null)||(v=P.G?!1:P.G=!0,e=!v);return!e}; hCD=function(P,v,l,e,h,z,m,Q,t,y,C){g.U.call(this);var f=this;this.M5=P;this.K0=v;this.policy=l;this.audioTrack=e;this.videoTrack=h;this.rM=z;this.Ob=m;this.h5=Q;this.G=t;this.timing=y;this.X=C;this.W=[];this.T={};this.q5=this.Ic=!1;this.J1=new Set;this.Z=this.Pg=this.Wg=this.r0=0;this.Y=null;this.J5={hR:[],wi:[]};this.T1={hR:[],wi:[]};this.j=null;this.Hg=[];this.Kh={IY5:function(){return f.W}, fYJ:function(){return f.T}, ZO3:function(){f.W.length=0}, ELJ:function(){return f.J1}, TWf:function(){return f.Wg}, Ol6:function(k){f.Wg=k}, KP$:function(k){f.Z=k}, Dd:function(k){f.j=k}}; this.videoData=this.M5.getVideoData();this.policy.MZ&&(this.wM=new MJ(this.K0,this.policy,this.Ob),g.Z(this,this.wM))}; RC9=function(P,v){v=v===void 0?!1:v;if(zCy(P,v)){P.policy.j&&P.K0.f0("sabrcrq",{create:1});var l=new y9(0,P.rM.S,P);P.policy.uM>0&&P.Z++;v=m3y(P,l,v);P.W.push(v);var e;(e=P.wM)==null||ZqD(e,P.rM.S)}}; fvq=function(P,v){var l=QID(P);if(P.policy.BV){var e=P.J5;var h=P.T1}else e=eh(P,P.audioTrack),h=eh(P,P.videoTrack);var z=[].concat(g.u(e.hR),g.u(h.hR));t0D(P)&&z.push.apply(z,g.u(P.Hg));var m=[].concat(g.u(e.wi),g.u(h.wi)),Q=P.K0.a8(),t,y,C=P.M5,f=P.rM,k=P.K,w=P.J1,I=P.policy,J=P.K0.Yq,K=OqD(P.K0)*1E3,q=(t=P.kf)==null?void 0:t.W5;t=(y=P.kf)==null?void 0:y.ys;var A;y=Number((A=P.G.Y)==null?void 0:A.info.itag)||0;var x;A=Number((x=P.G.T)==null?void 0:x.info.itag)||0;v={M5:C,rM:f,hR:z,wi:m,rV:l,nextRequestPolicy:k, J1:w,iq:I,Yq:J,Rj:K,W5:q,ys:t,r0:P.r0,isPrefetch:v||P.K0.isSuspended,L5:y,K5:A,ol:Q,R6:P.M5.NA()};l=P.K0.lw();z=fP(l);l&&(v.G9=z);if(l=P.M5.qX())v.Vs=l*1E3;var S;l=P.G;z=l.Wg;if((l.iq.K&&l.iq.xP||((S=l.iq)==null?0:S.W&&S.Ro))&&!z)for(S=g.N(l.G),m=S.next();!m.done;m=S.next())if(m.value.Rt){z=!0;break}S=s9(l.iq)&&!z?[]:dtB(l,l.G);v.o9=S;S=P.G;s9(S.iq)&&!S.QW?S=[]:(l=my6(S),l.length===0&&(l=S.Z),S=dtB(S,l));v.I9=S;v.qT=t0D(P)?[P.j]:void 0;P.policy.Zf&&(v.sx=y02(P.K0,P.audioTrack),v.z3=y02(P.K0,P.videoTrack)); if(P.policy.Z){e=CND(P,e.hR,h.hR);var B;if(h=(B=P.Y)==null?void 0:B.ze(e))v.o3=h}P.policy.QW&&P.W.length>0&&P.W[0].ub()&&(v.Wfc=P.W[0].Ee());return v}; QID=function(P){var v,l=P.policy.T&&((v=P.K0)==null?void 0:v.F3());v=P.K0.getCurrentTime()||0;v=gHx(P,v);var e=P.K0.fh()||0;v+=e;e=Lj(P.videoData)||g.pj(P.videoData);var h=0;l?(e&&(h=Number.MAX_SAFE_INTEGER),P.videoData.wM&&(h=Math.ceil(P.videoData.Hg*1E3))):h=Math.ceil(v*1E3);return Math.min(Number.MAX_SAFE_INTEGER,h)}; t0D=function(P){return P.policy.yY&&P.videoData.Ei()&&!!P.j}; gHx=function(P,v){if(P.K0.isSeeking())return v;var l=P.M5.ZR();if(!l)return v;l=l.AB();if(l.length===0||C0(l,v))return v;if(!Hm(P.videoTrack,v)&&!Hm(P.audioTrack,v))return P.K0.f0("sundrn",{b:0,lt:v}),v;for(var e=v,h=Infinity,z=0;z v)){var m=v-l.end(z);m =20)?(P.K0.handleError("player.exception",{reason:"bufferunderrunexceedslimit"}),v):e}; CND=function(P,v,l){var e=P.K0.getCurrentTime()||0;v=kky(P,v,e);P=kky(P,l,e);return Math.min(v,P)}; kky=function(P,v,l){P=P.K0.fh()||0;v=g.N(v);for(var e=v.next();!e.done;e=v.next()){var h=e.value;e=h.startTimeMs?h.startTimeMs/1E3-P:0;h=e+(h.durationMs?h.durationMs/1E3:0);if(e<=l&&l<=h)return h}return l}; zCy=function(P,v){if(P.policy.uM>0){var l=Math.floor((0,g.Gz)()/1E4);if(l===P.Pg){if(P.Z>=P.policy.uM){if(P.Z===P.policy.uM){var e={reason:"toomanyrequests"};e.limit=P.Z;P.K0.handleError("player.exception",e);P.Z+=1}return!1}}else P.Pg=l,P.Z=0}v=!v&&!AW(P.Ob);if(P.K0.isSuspended&&(P.K0.v$||v)||P.QW&&(0,g.Gz)() 0&&(!P.policy.QW||P.W.length!==1||!P.W[0].ub()))return!1;var h;if((h=P.rM.S)==null||!A_(h,P.policy,P.T,P.K0.Aw()))return!1;h=P.policy.ud&&P.policy.K&&P.K0.A3();if(Z2(P.audioTrack)&& Z2(P.videoTrack)&&!h)return!1;if(P.policy.K&&P.S&&!P.K0.A3())return P.Lq("ssap",{pauseontlm:1}),!1;if(hg(P,P.audioTrack)&&hg(P,P.videoTrack))return P.policy.G&&P.K0.f0("sabrHeap",{a:""+LL(P.audioTrack),v:""+LL(P.videoTrack)}),!1;if(h=P.policy.Z)h=!1,P.X.K===2?h=!0:P.X.K===3&&(QID(P),P.K0.fh(),v=CND(P,bW(P.audioTrack,P.K0.isSeeking()).hR,bW(P.videoTrack,P.K0.isSeeking()).hR),l=P.X,v>=l.G?(l.f0("sdai",{haltrq:v,est:l.G}),v=!0):v=!1,v&&(h=!0)),h&&P.policy.j&&P.K0.f0("sabrcrq",{waitad:1});if(h)return!1; P.policy.BV&&(P.J5=eh(P,P.audioTrack),P.T1=eh(P,P.videoTrack));if(!P.K)return P.policy.j&&P.K0.f0("sabrcrq",{nopolicy:1}),!0;if(P.M5.qX())return P.policy.j&&P.K0.f0("sabrcrq",{utc:1}),!0;if(P.G.S)return P.policy.j&&P.K0.f0("sabrcrq",{audio:1}),!0;if(!P.K.targetAudioReadaheadMs||!P.K.targetVideoReadaheadMs)return P.policy.j&&P.K0.f0("sabrcrq",{noreadahead:1}),!0;if(P.policy.T&&P.K0.F3())return P.policy.j&&P.K0.f0("sabrcrq",{seekToHead:1}),!0;h=Math.min(Ee(P.K0,P.audioTrack)*1E3,P.K.targetAudioReadaheadMs); v=Math.min(Ee(P.K0,P.videoTrack)*1E3,P.K.targetVideoReadaheadMs);var z=Math.min(h,v);l=Gb(P.audioTrack,!0)*1E3;var m=Gb(P.videoTrack,!0)*1E3;if(P.policy.BV){var Q=P.M5.getCurrentTime()*1E3;var t=wou(P.J5.hR,Q);Q=wou(P.T1.hR,Q)}else t=l,Q=m;var y=t v||e>=0&&h.vV>e+1)break;l=Math.max(l,h.startTimeMs+h.durationMs);e=Math.max(e,h.IY)}return Math.max(0,l-v)}; m3y=function(P,v,l){var e={Ob:P.Ob,u_:function(t,y){P.M5.pS(t,y)}, QQ:P.policy.KO,Ie:P.policy.G};P.Ob.K.j&&(e.sY=(P.videoTrack.W.info.FJ||0)+(P.audioTrack.W.info.FJ||0));P.policy.lr&&(e.aY=P.audioTrack.W.index.uP(),e.QQ=!1);var h=yW6(v,P.policy,P.T)?2:1;h!==P.Wg&&(P.Wg=h,D3B(P));l=fvq(P,l);if((P.policy.K||P.policy.QW)&&P.policy.G&&l.J1){for(var z=h="",m=g.N(l.J1),Q=m.next();!Q.done;Q=m.next())Q=Q.value,P.videoData.sabrContextUpdates.has(Q)?h+="_"+Q:z+="_"+Q;P.K0.f0("sabrbldrqs",{ctxts:h,misctxts:z})}v.setData(l,P.K0.A3(),P.policy,P.T)||!P.policy.K&&!P.policy.QW|| P.K0.handleError("player.exception",{reason:"buildsabrrequestdatafailed"},1);e=new GG(P.policy,v,P.rM,P.T,P,e,P.K0.LN(),P.policy.Xf?P.K0.A3():void 0);X4(P.timing);P.policy.j&&P.K0.f0("sabrcrq",{rn:e.Qp(),probe:v.Iq()});return e}; Rt=function(P,v){if(v.s$()||P.s$())P.policy.qP||(P.policy.T?m$(P.K0):P.K0.p6());else{if(P.policy.G&&v.isComplete()&&v instanceof GG){var l=P.K0,e=l.f0,h,z,m=Object.assign(v.F_.WI(),{rst:v.state,strm:v.xhr.DC(),d:(h=v.F_.wM)==null?void 0:h.vB(),cncl:v.xhr&&v.Eb.Y?1:0,rqb:v.td,cwt:v.JH,swt:(z=v.cX)==null?void 0:z.vO});h=Object.assign(gQy(v.info),m);e.call(l,"rqs",h)}if(v.isComplete()&&v.Iq()&&v instanceof GG)P.policy.aV?v.SV()?(v.dispose(),P.W.length===0?P.K0.p6():(P=P.W[0],P instanceof GG&&P.zI()&& P.UK(!1))):v.Tr()&&P.K0.handleError(v.nJ(),v.h4()):(v.dispose(),P.K0.p6());else{if(v.dD())v instanceof GG&&mNu(P.timing,v),D3B(P),nHD(P);else if(v.Tr())l=P.M5.qX(),v instanceof GG&&fY2(v.info)&&l&&P.K0.Wh(l),v instanceof vR?P.W.pop():(l=1,v.canRetry()&&hs(P.K0)&&(NhB(P,v),l=0),P.K0.handleError(v.nJ(),v.h4(),l));else{if(P.K0.isSuspended&&!v.isComplete())return;nHD(P)}v.s$()||v instanceof vR||(v.isComplete()?l=Hq2(v,P.policy,P.T):(l=alD(v,P.policy,P.T),l===1&&(P.Ic=!0)),l!==0&&(e=new y9(1,v.info.JR), e.qZ=l===2,m3y(P,e)));P.policy.Xq&&!v.isComplete()?lS(P.K0):P.K0.p6()}}}; nHD=function(P){for(;P.W.length&&P.W[0].D_(P.sF());){var v=P.W.shift();J07(P,v);if(P.policy.Z){var l=P;if(!l.policy.A5&&v.D_(l.sF())){var e=v.Qp();if(l.A5!==e){var h=v.eK();v=h.lZ;var z=h.xA;h=h.isDecorated;!l.Y||z<0||(l.A5=e,e=H8(l.X,z/1E3,v),z=l.K0.fh()||0,ZC(l.X,v,e-z,h,l.Y))}}}}P.W.length&&J07(P,P.W[0])}; J07=function(P,v){var l=new Set(v.Vy(P.sF()));l=g.N(l);for(var e=l.next();!e.done;e=l.next()){var h=e.value;if(!(e=!(v instanceof vR))){e=P.G;var z=e.rM.Ei,m=Q9(e.videoInfos,z);e=z4y(e,h,z)||m.includes(h)}if(e&&(e=v.D7(h,P.sF()),z=P.policy.yY&&lf(e[0].W.info),(!(!z&&P.policy.yl&&e.length>0&&(e[0].W.info.h3()?Gb(P.audioTrack):Gb(P.videoTrack))>3)||v.isComplete())&&v.Ps(h,P.sF()))){h=v.vT(h,P.sF());if(P.policy.K){m=e[0].W.info;var Q=P.K0.A3();if(Q&&m){var t=v.TY();Q.api.V("html5_ssap_set_format_info_on_video_data")&& t===U9(Q)&&(m.h3()?Q.playback.getVideoData().Y=m:Q.playback.getVideoData().K=m);if(Q=Q4(Q.timeline,t))if(Q=Q[0].getVideoData())m.h3()?Q.Y=m:Q.K=m}}h=g.N(h);for(m=h.next();!m.done;m=h.next())if(m=m.value,P.policy.G&&v instanceof vR&&P.K0.f0("omblss",{s:m.info.WR()}),z)Q=P,Q.videoData.Ei()&&Q.j&&Y2(Q.j)===Y2(g.es(m.info.W.info,Q.rM.Ei))&&Q.M5.publish("sabrCaptionsDataLoaded",m,Q.yf.bind(Q));else{Q=m.info.W.info.h3();var y=m.info.W;if(Q){t=void 0;var C=P.G,f=(t=v.Te(P.sF()))==null?void 0:t.token;C.S= !1;y!==C.T&&(C.T=y,C.f2(y,C.audioTrack,f))}else t=void 0,VaD(P.G,y,(t=v.Te(P.sF()))==null?void 0:t.token);t=Q?P.audioTrack:P.videoTrack;v instanceof vR&&(t.j=!1,v instanceof vR&&(Q?d9x(P.timing):VMD(P.timing)));if(P.policy.Jh)try{Yb(t,e,m)}catch(k){m=LW(k),P.K0.handleError(m.errorCode,m.details,m.severity),t.uZ(),P.Jm(!1,"pushSlice"),m$(P.K0)}else Yb(t,e,m)}}}}; NhB=function(P,v){P.policy.QW?P.W.splice(P.W.indexOf(v)).forEach(function(l){l.dispose()}):(P.W.pop(),v==null||v.dispose())}; uXW=function(P,v,l){for(var e=[],h=0;h 0)for(var v=g.N(P.videoData.sabrContextUpdates.keys()),l=v.next();!l.done;l=v.next()){l=l.value;var e=void 0;((e=P.videoData.sabrContextUpdates.get(l))==null?0:e.sendByDefault)&&P.J1.add(l)}if(P.policy.QW&&P.W.length)for(v=g.N(P.W),l=v.next();!l.done;l=v.next())(l=l.value.Ee())&&l.type&&l.sendByDefault&&P.J1.add(l.type)}; qv7=function(P){P.policy.zK&&(P.kf=void 0,P.r0=0)}; FlD=function(P,v){if(v.Tr()||v.s$()){var l=P.K0,e=l.f0,h=v.state;P=P.sF();var z,m;if((v=(z=v.WP)==null?void 0:z.get(P))==null)v=void 0;else{z=0;P=v.Vy();for(var Q=0;Q =P.policy.M1,m=!1;if(z){var Q=0;!isNaN(v)&&v>P.Z&&(Q=v-P.Z,P.Z=v);Q/h =P.policy.S6&&!P.G;if(!z&&!l&&poP(P,v))return NaN;l&&(P.G=!0);a:{e=m;l=(0,g.Gz)()/1E3-(P.vj.y_()||0)-P.j.W-P.policy.oV;z=P.K.startTime;l=z+l;if(e){if(isNaN(v)){tg(P,NaN,"n",v);z=NaN;break a}e=v-P.policy.d4;e =z.ao&&e<=z.EF){e=!0;break a}e=!1}e=!e}if(e)return P.f0("ostmf",{ct:P.getCurrentTime(),a:v.W.info.h3()}),!1;(P=P.QW)!=null&&(P.r9.get(l).g1=!0);return!0}; U3x=function(P){if(!P.rM.Ei)return!0;var v=P.M5.getVideoData();if(v.V("html5_skip_live_preroll_onesie")&&P.M5.Pi()||v.V("html5_skip_live_preroll_onesie_post_live")&&P.M5.Pi()&&(v.cz||v.isPremiere))return P.f0("ombpa",{}),!1;var l,e;if(P.policy.X3&&!!((l=P.Wg)==null?0:(e=l.JW)==null?0:e.j0$)!==P.rM.cz)return P.f0("ombplmm",{}),!1;l=v.jS||v.liveUtcStartSeconds||v.GP;if(P.rM.cz&&l)return P.f0("ombplst",{}),!1;if(P.rM.X)return P.f0("ombab",{}),!1;l=Date.now();return bM(P.rM)&&!isNaN(P.J5)&&l-P.J5>P.policy.d1* 1E3?(P.f0("ombttl",{}),!1):P.rM.Mv&&P.rM.Y||!P.policy.XN&&P.rM.isPremiere||!(nj(v)===0||P.policy.W&&v.V("html5_enable_onesie_media_for_sabr_proxima_optin"))||v.V("html5_disable_onesie_media_for_mosaic")&&Vi(v)||v.V("html5_disable_onesie_media_for_ssdai")&&v.isDaiEnabled()&&v.enableServerStitchedDai?!1:!0}; Z_7=function(P,v){var l=v.W,e=P.rM.Ei;if(U3x(P))if(P.QW&&P.QW.r9.has(Y2(g.es(l.info,e)))){if(e=Y2(g.es(l.info,e)),i_W(P,v)){var h=new a1(P.QW.D7(e)),z=function(m){try{if(m.Tr())P.handleError(m.nJ(),m.h4()),iW(v,m),E8(m.info)&&PU(P.Z,v,l,!0),P.p6();else if(vU(P.Z,m)){var Q;(Q=P.Y)==null||y_u(Q,m.info,P.S);P.p6()}}catch(t){m=LW(t),P.handleError(m.errorCode,m.details,m.severity),P.uZ()}}; l.G=!0;HH(h)&&(AE(v,new ZL(P.policy,e,h,P.QW,z)),X4(P.timing))}}else P.f0("ombfmt",{})}; ff=function(P,v){v=v||P.videoTrack&&P.videoTrack.K&&P.videoTrack.K.startTime||P.getCurrentTime();var l=eA,e=P.videoTrack,h=P.W;v=h.nextVideo&&h.nextVideo.index.lh(v)||0;h.T1!==v&&(h.wM={},h.T1=v,dN(h,h.W));v=!h.W.isLocked()&&h.X>-1&&(0,g.Gz)()-h.X v.W&&v.reason==="b";e||h||l?(P.M5.DH({reattachOnConstraint:e?"u":h?"drm":"perf",lo:v.K,up:v.W}),P.policy.sZ||(P.K.W.K=!1)):(P.policy.sZ&&(P.K.W.K=!1),m$(P))}}else if(!NRB(P.W,v)&&P.videoTrack){P.logger.debug(function(){return"Setting constraint: r="+v.reason+" u="+v.W}); l=P.W.W;sI6(P,uI2(P.W,v));ff(P);e=v.isLocked()&&v.reason==="m"&&P.W.QW;h=P.policy.rH&&v.reason==="l"&&jD(P.videoTrack);l=l.W>v.W&&v.reason==="b";var z=P.W.h5&&!WB();e||h||l||z?P.M5.DH({reattachOnConstraint:e?"u":h?"drm":z?"codec":"perf"}):m$(P)}}; M0B=function(P,v,l){if((!P.u$||sa(P.u$)&&!P.policy.Ep)&&!P.oY.isSeeking()&&(P.policy.W||jD(v)&&v.W.cP()&&P.W.Wg)){var e=P.getCurrentTime()+nfD(P.X,v,l);P.logger.debug(function(){return"Clearing back to "+e.toFixed(3)}); KgD(v,e)}}; sI6=function(P,v){v&&(P.logger.debug(function(){return"Logging new format: "+Rb(v.video.info)}),Thq(P.M5,new Ox(v.video,v.reason))); if(P.W.Ic){var l=FK7(P.W,"a");P.M5.B1(new Ox(l.audio,l.reason))}}; m$=function(P){g.RX(P.WK)}; lS=function(P){P.policy.Xq&&P.policy.CO&&Math.min(ul7(P.videoTrack),ul7(P.audioTrack))*1E3>P.policy.bd?g.RX(P.nI):P.p6()}; V09=function(P,v){var l=(0,g.Gz)()-v,e=Gb(P.audioTrack,!0)*1E3,h=Gb(P.videoTrack,!0)*1E3;P.logger.debug(function(){return"Appends paused for "+l}); if(P.policy.G&&(P.f0("apdpe",{dur:l.toFixed(),abuf:e.toFixed(),vbuf:h.toFixed()}),oc(P.policy))){var z=ST(P.X);P.f0("sdps",{ct:v,ah:e.toFixed(),vh:h.toFixed(),mr:G3(P.X,P.xL,z),bw:z.toFixed(),js:P.isSeeking(),re:+P.xL,ps:(P.policy.f5||"").toString(),rn:(P.policy.Al||"").toString()})}}; d3w=function(P){if(P.policy.K&&E9(P.videoTrack)&&E9(P.audioTrack))return"ssap";if(bq9(P.videoTrack))return P.logger.debug("Pausing appends for server-selectable format"),"ssf";if(P.policy.Ic&&Wm(P.videoTrack)&&Wm(P.audioTrack))return"updateEnd";if(Z2(P.audioTrack)||Z2(P.videoTrack)&&P.videoTrack.W.info.dM!=="f")return"";if(P.oY.isSeeking()){var v=P.X;var l=P.videoTrack;var e=P.audioTrack;if(v.policy.W){var h=v.policy.IK;oc(v.policy)&&(h=G3(v,!1,ST(v)));v=h;l=Gb(e,!0)>=v&&Gb(l,!0)>=v}else l.G.length|| e.G.length?(h=l.W.info.FJ+e.W.info.FJ,h=10*(1-ST(v)/h),v=Math.max(h,v.policy.IK),l=Gb(e,!0)>=v&&Gb(l,!0)>=v):l=!0;if(!l)return"abr";l=P.videoTrack;if(l.G.length>0&&l.Y.K.length===1&&VV2(l.Y).info.T 360);e=oc(P.policy)&&P.policy.Bw;if(!P.xL||!e&&l)return"";l=P.policy.q_;oc(P.policy)&&(l=G3(P.X,P.xL,ST(P.X)));l=qoa(P.videoTrack, P.getCurrentTime(),l)||qoa(P.audioTrack,P.getCurrentTime(),l);return oc(P.policy)?l?"mbnm":"":(P.videoTrack.G.length>0||P.audioTrack.G.length>0||Vl(P.Z,P.videoTrack,P.audioTrack)||Vl(P.Z,P.audioTrack,P.videoTrack))&&l?"nord":""}; PVy=function(P){if(P.j){var v=P.j.p6(P.audioTrack,gJ(P.u$.K.Io()));v&&P.M5.seekTo(v,{gt:!0,mD:"pollSubsegmentReadahead",VT:!0})}}; Rmw=function(P,v,l){if(P.policy.Ic&&Wm(v))return!1;if(l.Yr())return!0;if(!l.LL())return!1;var e=rb(v);if(!e||e.info.type===6)return!1;var h=P.policy.oy;if(h&&!e.info.Y){var z=e.info.ao-P.getCurrentTime();if(e.info.T z)return P.policy.W&&emD(P,v),P.policy.fW&&Lk7(v.Y,z,!1),!1;hmD(P,v);var Q;P.policy.t3&&l===((Q=P.u$)==null?void 0:Q.W)&&P.h5&&(l.Pr()===0?(P.h5=!1,P.policy.t3=!1):P.A5=l.Pr());if(!zmu(P,l,e,v))return!1;P.policy.Ic&&e.info.c9()?(P.M5.N().vK()&&P.f0("eosl",{ls:e.info.WR()}), e.isLocked=!0):(v.mm(e),q87(P.W,e.info),P.logger.debug(function(){return"Appended "+e.info.WR()+", buffered: "+ti(l.Io())})); h&&mAD(P,e.info.W.oe);return!0}; emD=function(P,v){v===P.videoTrack?P.Hg=P.Hg||(0,g.Gz)():P.kf=P.kf||(0,g.Gz)()}; hmD=function(P,v){v===P.videoTrack?P.Hg=0:P.kf=0}; zmu=function(P,v,l,e){var h=P.policy.U$?(0,g.Gz)():0,z=l.Z&&l.info.W.W||void 0,m=l.W;l.Z&&(m=Qhy(P,l,m)||m);var Q=m.Yt();m=P.policy.U$?(0,g.Gz)():0;v=tr7(P,v,Q,l.info,z);(e=e.X)!=null&&(z=l.info,h=m-h,m=(0,g.Gz)()-m,!e.K||HWx(e.K,z)&&e.K.n0===z.n0||e.flush(),e.Y+=h,e.G+=m,h=1,!e.K&&z.K&&(h=2),zb(e,h,v),m=Math.ceil(z.K/1024),h===2&&e.W.add(m),e.W.add(Math.ceil((z.K+z.G)/1024)-m),e.K=z);P.T1=0;if(v===0)return P.Pg&&(P.logger.debug("Retry succeed, back to normal append logic."),P.Pg=!1,P.Bg=!1),P.U$= 0,!0;if(v===2||v===5)return yca(P,"checked",v,l.info),!1;if(v===1){if(!P.Pg)return P.logger.debug("QuotaExceeded, retrying."),P.Pg=!0,!1;if(!P.Bg)return P.Bg=!0,P.M5.seekTo(P.getCurrentTime(),{mD:"quotaExceeded",VT:!0}),!1;l.info.zQ()?(h=P.policy,h.Pg=Math.floor(h.Pg*.8),h.T1=Math.floor(h.T1*.8)):(h=P.policy,h.Bg=Math.floor(h.Bg*.8),h.T1=Math.floor(h.T1*.8));P.policy.W?sx(P.K.W,l.info.W,!1):vm(P.W,l.info.W)}P.M5.DH({reattachOnAppend:v});return!1}; Qhy=function(P,v,l){var e;if(e=P.policy.Nx&&P.u$&&!P.u$.S&&!P.M5.xT())v=v.info.W.info,e=v.C6()&&rl(v)&&v.video&&v.video.width<3840&&v.video.width>v.video.height;if(e&&(P.u$.S=!0,Bz('video/webm; codecs="vp09.00.50.08.01.01.01.01.00"; width=3840; height=2160')))return l=MV2(l),P.policy.G&&P.f0("sp4k",{s:!!l}),l}; yca=function(P,v,l,e){var h="fmt.unplayable",z=1;l===5||l===3?(h="fmt.unparseable",P.policy.W?!e.W.info.video||rN(P.K.W).size>0||sx(P.K.W,e.W,!1):!e.W.info.video||rN(P.W.Z).size>0||vm(P.W,e.W)):l===2&&(P.U$<15?(P.U$++,h="html5.invalidstate",z=0):h="fmt.unplayable");e=Z6(e);var m;e.mrs=(m=P.u$)==null?void 0:Vu(m);e.origin=v;e.reason=l;P.handleError(h,e,z)}; gT7=function(P,v,l,e,h){var z=P.rM;var m=P.policy.W,Q=!1,t=-1,y;for(y in z.W){var C=lf(z.W[y].info)||z.W[y].info.zQ();if(e===C)if(C=z.W[y].index,C.Zh(v.n0)){Q=C;var f=v,k=Q.OU(f.n0);k&&k.startTime!==f.startTime?(Q.segments=[],Q.Vk(f),Q=!0):Q=!1;Q?t=v.n0:!v.pending&&m&&(f=C.getDuration(v.n0),f!==v.duration&&(z.publish("clienttemp","mfldurUpdate",{itag:z.W[y].info.itag,seg:v.n0,od:f,nd:v.duration},!1),C.Vk(v),Q=!0))}else C.Vk(v),Q=!0}t>=0&&(m={},z.publish("clienttemp","resetMflIndex",(m[e?"v":"a"]= t,m),!1));z=Q;BIw(P.oY,v,e,z);P.Y.K2(v,l,e,h);v.n0===P.rM.Mv&&z&&Kq(P.rM)&&v.startTime>Kq(P.rM)&&(P.rM.Hg=v.startTime+(isNaN(P.timestampOffset)?0:P.timestampOffset),P.oY.isSeeking()&&P.oY.W 5)return P.T1=0,P.M5.DH({initSegStuck:1,as:e.info.WR()}),!0}else P.T1=0,P.jS=e;P.policy.gJ&&(l.abort(),(m=v.X)!=null&&(zb(m,4),m.flush()));h=tr7(P,l,z,t,h);var y;(y=v.X)==null||G82(y,h,t);if(h!==0)return CVw(P,h,e),!0;e.info.zQ()?l67(P.timing):edD(P.timing);P.logger.debug(function(){return"Appended init for "+e.info.W.info.id}); mAD(P,e.info.W.oe);return l.pw()}; vMD=function(P,v,l){if(v.jm()==null){P=Fr(P);if(!(v=!P||P.W!==l.info.W)){a:if(P=P.j,l=l.info.j,P.length!==l.length)l=!1;else{for(v=0;v 1)return 6;t.wM=new g.mr(function(){var C=rb(t);P.s$()||C==null||!C.isLocked?P.M5.N().vK()&&P.f0("eosl",{delayA:C==null?void 0:C.info.WR()}):fNa(t)?(P.M5.N().vK()&&P.f0("eosl",{dunlock:C==null?void 0:C.info.WR()}),gMD(P, t===P.audioTrack)):(P.f0("nue",{ls:C.info.WR()}),C.info.S+=1,P.u$&&P.xx())},1E4,P); P.M5.N().vK()&&P.f0("eosl",{delayS:e.WR()});t.wM.start()}if(P.policy.l7&&(e==null?0:e.c9())){var y;if((y=t.T1)==null?0:y.isActive())g.QD(t.T1),P.f0("sbac",{as:e.WR()});t.T1=new g.mr(function(){P.f0("sbum5s",{as:e.WR()})},5E3,P); t.T1.start()}P.policy.JX&&(e==null?void 0:e.W)instanceof O8&&e.c9()&&P.f0("poseos",{itag:e.W.info.itag,seg:e.n0,lseg:e.W.index.vR(),es:e.W.index.G});v.appendBuffer(l,e,h)}catch(C){if(C instanceof DOMException){if(C.code===11)return 2;if(C.code===12)return 5;if(C.code===22||C.message.indexOf("Not enough storage")===0)return v=Object.assign({name:"QuotaExceededError",buffered:ti(v.Io()).replace(/,/g,"_"),vheap:LL(P.videoTrack),aheap:LL(P.audioTrack),message:g.n$(C.message,3),track:P.u$?v===P.u$.K?"v": "a":"u"},GkP()),P.handleError("player.exception",v),1;g.Zx(C)}return 4}return P.u$.iA()?3:0}; se=function(P,v,l){P.M5.seekTo(v,l)}; mAD=function(P,v){v&&P.M5.EK(new gq(v.key,v.type))}; Ic=function(P,v){P.M5.Q$(v)}; Ee=function(P,v){if(P.Pg&&!P.xL)return 3;if(P.isSuspended)return 1;var l;if((l=P.u$)==null?0:l.u$&&l.u$.streaming===!1)return 4;l=(v.W.info.audio?P.policy.Bg:P.policy.Pg)/(v.FJ*P.policy.Tg);if(P.policy.rr>0&&P.u$&&sa(P.u$)&&(v=v.W.info.video?P.u$.K:P.u$.W)&&!v.pw()){v=v.Io();var e=yu(v,P.getCurrentTime());e>=0&&(v=P.getCurrentTime()-v.start(e),l+=Math.max(0,Math.min(v-P.policy.rr,P.policy.Iy)))}P.policy.T1>0&&(l=Math.min(l,P.policy.T1));return l}; y02=function(P,v){return(Ee(P,v)+P.policy.r$)*v.FJ}; wdB=function(P){P.Ic&&!P.isSuspended&&AW(P.schedule)&&(k6y(P,P.Ic),P.Ic="")}; k6y=function(P,v){bU(v,"cms",function(l){P.policy.G&&P.f0("pathprobe",l)},function(l){P.M5.handleError(l)})}; $Ax=function(P,v){if(P.u$&&P.u$.Y&&!P.u$.iA()&&(v.MX=Gb(P.videoTrack),v.K=Gb(P.audioTrack),P.policy.G)){var l=LL(P.videoTrack),e=LL(P.audioTrack),h=ti(P.u$.K.Io(),"_",5),z=ti(P.u$.W.Io(),"_",5);Object.assign(v.W,{lvq:l,laq:e,lvb:h,lab:z})}v.bandwidthEstimate=pH(P.X);var m;(m=P.audioTrack.X)==null||m.flush();var Q;(Q=P.videoTrack.X)==null||Q.flush();P.logger.debug(function(){return bp(v.W)})}; IND=function(P,v){P.S=v;P.Y&&(P.Y.T=v);P.S.nQ(P.videoTrack.W.info.C6());P.Z.K=P.S;P.policy.Z&&(P.G.Y=P.S)}; DAB=function(P,v){if(P.u$&&P.u$.K){if(P.policy.R4){var l=GBW(P.audioTrack);if(l&&l.h3()){var e=P.M5;e.WG&&(e.WG.W=l,e.uQ(e.WG.videoId).Ej(e.WG))}}P.policy.eh&&(l=GBW(P.videoTrack))&&l.zQ()&&(e=P.M5,e.xw&&(e.xw.W=l,e.uQ(e.xw.videoId).mT(e.xw)));v-=isNaN(P.timestampOffset)?0:P.timestampOffset;P.getCurrentTime()!==v&&P.resume();P.oY.isSeeking()&&P.u$&&!P.u$.iA()&&(l=P.getCurrentTime()<=v&&v =v&&XoW(P,e.startTime,!1)}); return l&&l.startTime P.getCurrentTime())return l.start/1E3;return Infinity}; uVu=function(P){var v=Fr(P.videoTrack),l=Fr(P.audioTrack);return v&&!SoD(P.videoTrack)?v.startTime:l&&!SoD(P.audioTrack)?l.startTime:NaN}; Iv2=function(P){if(P.M5.getVideoData().isLivePlayback)return!1;var v=P.M5.ZR();if(!v)return!1;v=v.getDuration();return $3D(P,v)}; $3D=function(P,v){if(!P.u$||!P.u$.W||!P.u$.K)return!1;var l=P.getCurrentTime(),e=P.u$.W.Io();P=P.u$.K.Io();e=e?f0(e,l):l;l=P?f0(P,l):l;l=Math.min(e,l);return isNaN(l)?!1:l>=v-.01}; CVw=function(P,v,l){P.policy.yE&&Rh(P.M5.getVideoData())?(P.M5.EB()||yca(P,"sepInit",v,l.info),Ke7(P.M5,"sie")):yca(P,"sepInit",v,l.info)}; hs=function(P){return P.M5.Aw() 0){var h=e.W.shift();qDD(e,h.info)}e.W.length>0&&(h=e.W[0].time-(0,g.Gz)(),e.K.start(Math.max(0,h)))}},0); g.Z(this,this.K);v.subscribe("widevine_set_need_key_info",this.Z,this)}; qDD=function(P,v){a:{var l=v.cryptoPeriodIndex;if(isNaN(l)&&P.G.size>0)l=!0;else{for(var e=g.N(P.G.values()),h=e.next();!h.done;h=e.next())if(h.value.cryptoPeriodIndex===l){l=!0;break a}l=!1}}P.publish("log_qoe",{wvagt:"reqnews",canskip:l});l||P.publish("rotated_need_key_info_ready",v)}; FeD=function(){var P={};var v=P.url;var l=P.interval;P=P.retries;this.url=v;this.interval=l;this.retries=P}; Acw=function(P,v){this.statusCode=P;this.message=v;this.K=this.heartbeatParams=this.errorMessage=null;this.W={};this.nextFairplayKeyId=null}; YDw=function(P,v,l){l=l===void 0?"":l;g.U.call(this);this.message=P;this.requestNumber=v;this.uC=l;this.onError=this.onSuccess=null;this.W=new g.b5(5E3,2E4,.2)}; bju=function(P,v,l){P.onSuccess=v;P.onError=l}; pdy=function(P,v,l,e){var h={timeout:3E4,onSuccess:function(z){if(!P.s$()){WI("drm_net_r",void 0,P.uC);var m=z.status==="LICENSE_STATUS_OK"?0:9999,Q=null;if(z.license)try{Q=No(z.license)}catch(I){g.Zx(I)}if(m!==0||Q){Q=new Acw(m,Q);m!==0&&z.reason&&(Q.errorMessage=z.reason);if(z.authorizedFormats){m={};for(var t=[],y={},C=g.N(z.authorizedFormats),f=C.next();!f.done;f=C.next())if(f=f.value,f.trackType&&f.keyId){var k=xAq[f.trackType];if(k){k==="HD"&&z.isHd720&&(k="HD720");f.isHdr&&(k+="HDR");m[k]|| (t.push(k),m[k]=!0);var w=null;try{w=No(f.keyId)}catch(I){g.Zx(I)}w&&(y[g.D7(w,4)]=k)}}Q.K=t;Q.W=y}z.nextFairplayKeyId&&(Q.nextFairplayKeyId=z.nextFairplayKeyId);z.sabrLicenseConstraint&&(Q.sabrLicenseConstraint=No(z.sabrLicenseConstraint));z=Q}else z=null;if(z)P.onSuccess(z,P.requestNumber);else P.onError(P,"drm.net","t.p;p.i")}}, onError:function(z){if(!P.s$())if(z&&z.error)z=z.error,P.onError(P,"drm.net.badstatus","t.r;p.i;c."+z.code+";s."+z.status,z.code);else P.onError(P,"drm.net.badstatus","t.r;p.i;c.n")}, onTimeout:function(){P.onError(P,"drm.net","rt.req."+P.requestNumber)}}; e&&(h.gp="Bearer "+e);g.mX(l,"player/get_drm_license",v,h)}; Le9=function(P,v,l,e){g.gA.call(this);this.videoData=P;this.O$=v;this.X=l;this.sessionId=e;this.Z={};this.cryptoPeriodIndex=NaN;this.url="";this.requestNumber=0;this.j=this.QW=!1;this.G=null;this.T1=[];this.Y=[];this.S=!1;this.W={};this.J5=NaN;this.status="";this.T=NaN;this.K=P.Z;this.cryptoPeriodIndex=l.cryptoPeriodIndex;P={};Object.assign(P,this.O$.W);P.cpn=this.videoData.clientPlaybackNonce;this.videoData.QW&&(P.vvt=this.videoData.QW,this.videoData.mdxEnvironment&&(P.mdx_environment=this.videoData.mdxEnvironment)); this.O$.T1&&(P.authuser=this.O$.T1);this.O$.pageId&&(P.pageid=this.O$.pageId);isNaN(this.cryptoPeriodIndex)||(P.cpi=this.cryptoPeriodIndex.toString());var h=(h=/_(TV|STB|GAME|OTT|ATV|BDP)_/.exec(g.Y3()))?h[1]:"";h==="ATV"&&(P.cdt=h);this.Z=P;this.Z.session_id=e;this.Wg=!0;this.K.flavor==="widevine"&&(this.Z.hdr="1");this.K.flavor==="playready"&&(v=Number(eE(v.experiments,"playready_first_play_expiration")),!isNaN(v)&&v>=0&&(this.Z.mfpe=""+v),this.Wg=!1);v="";g.Eo(this.K)?Hj(this.K)?(e=l.K)&&(v="https://www.youtube.com/api/drm/fps?ek="+ UPw(e)):(v=l.initData.subarray(4),v=new Uint16Array(v.buffer,v.byteOffset,v.byteLength/2),v=String.fromCharCode.apply(null,v).replace("skd://","https://")):v=this.K.K;this.baseUrl=v;this.fairplayKeyId=TQ(this.baseUrl,"ek")||"";if(v=TQ(this.baseUrl,"cpi")||"")this.cryptoPeriodIndex=Number(v);this.kf=this.videoData.V("html5_use_drm_retry");this.T1=l.C6?[g.D7(l.initData,4)]:l.G;nf(this,{sessioninit:l.cryptoPeriodIndex});this.status="in"}; Bw7=function(P,v){nf(P,{createkeysession:1});P.status="gr";WI("drm_gk_s",void 0,P.videoData.q5);P.url=SDD(P);try{P.G=v.createSession(P.X,function(l){nf(P,{m:l})})}catch(l){v="t.g"; l instanceof DOMException&&(v+=";c."+l.code);P.publish("licenseerror","drm.unavailable",1,v,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK");return}P.G&&(G6a(P.G,function(l,e){Xda(P,l,e)},function(l,e,h){if(!P.s$()){e=void 0; var z=1;g.Eo(P.K)&&g.ZY(P.O$)&&P.O$.V("html5_enable_safari_fairplay")&&h===1212433232&&(e="ERROR_HDCP",z=P.O$.V("html5_safari_fairplay_ignore_hdcp")?0:z);P.error("drm.keyerror",z,l,e)}},function(){P.s$()||(nf(P,{onkyadd:1}),P.j||(P.publish("sessionready"),P.j=!0))},function(l){P.a7(l)}),g.Z(P,P.G))}; SDD=function(P){var v=P.baseUrl;lWx(v)||P.error("drm.net",2,"t.x");if(!TQ(v,"fexp")){var l=["23898307","23914062","23916106","23883098"].filter(function(h){return P.O$.experiments.experiments[h]}); l.length>0&&(P.Z.fexp=l.join())}l=g.N(Object.keys(P.Z));for(var e=l.next();!e.done;e=l.next())e=e.value,v=bU9(v,e,P.Z[e]);return v}; Xda=function(P,v,l){if(!P.s$())if(v){nf(P,{onkmtyp:l});P.status="km";switch(l){case "license-renewal":case "license-request":case "license-release":break;case "individualization-request":ij7(P,v);return;default:P.publish("ctmp","message_type",{t:l,l:v.byteLength})}P.QW||(WI("drm_gk_f",void 0,P.videoData.q5),P.QW=!0,P.publish("newsession",P));if(Uo(P.K)&&(v=UA2(v),!v))return;v=new YDw(v,++P.requestNumber,P.videoData.q5);bju(v,function(e){Zj2(P,e)},function(e,h,z){if(!P.s$()){var m=0,Q; (Q=e.W.K>=3)||(Q=P.kf&&(0,g.Gz)()-P.J5>36E4);Q&&(m=1,h="drm.net.retryexhausted");nf(P,{onlcsrqerr:h,info:z});P.error(h,m,z);P.shouldRetry(pW(m),e)&&jh6(P,e)}}); g.Z(P,v);aNw(P,v)}else P.error("drm.unavailable",1,"km.empty")}; ij7=function(P,v){nf(P,{sdpvrq:1});P.T=Date.now();if(P.K.flavor!=="widevine")P.error("drm.provision",1,"e.flavor;f."+P.K.flavor+";l."+v.byteLength);else{var l={cpn:P.videoData.clientPlaybackNonce};Object.assign(l,P.O$.W);l=g.r5("https://www.googleapis.com/certificateprovisioning/v1/devicecertificates/create?key=AIzaSyB-5OLKTx2iU5mko18DfdwK5611JIjbUhE",l);v={format:"RAW",headers:{"content-type":"application/json"},method:"POST",postBody:JSON.stringify({signedRequest:String.fromCharCode.apply(null, v)}),responseType:"arraybuffer"};g.ia(l,v,3,500).then(c1(function(e){e=e.xhr;if(!P.s$()){e=new Uint8Array(e.response);var h=String.fromCharCode.apply(null,e);try{var z=JSON.parse(h)}catch(m){}z&&z.signedResponse?(P.publish("ctmp","drminfo",{provisioning:1}),z=(Date.now()-P.T)/1E3,P.T=NaN,P.publish("ctmp","provs",{et:z.toFixed(3)}),P.G&&P.G.update(e)):(z=z&&z.error&&z.error.message,e="e.parse",z&&(e+=";m."+z),P.error("drm.provision",1,e))}}),c1(function(e){P.s$()||P.error("drm.provision",1,"e."+e.errorCode+ ";c."+(e.xhr&&e.xhr.status))}))}}; N5=function(P){var v;if(v=P.Wg&&P.G!=null)P=P.G,v=!(!P.W||!P.W.keyStatuses);return v}; aNw=function(P,v){P.status="km";WI("drm_net_s",void 0,P.videoData.q5);var l=new g.zj(P.O$.xt),e={context:g.Ds(l.config_||g.IO())};e.drmSystem=Hjq[P.K.flavor];e.videoId=P.videoData.videoId;e.cpn=P.videoData.clientPlaybackNonce;e.sessionId=P.sessionId;e.licenseRequest=g.D7(v.message);e.drmParams=P.videoData.drmParams;isNaN(P.cryptoPeriodIndex)||(e.isKeyRotated=!0,e.cryptoPeriodIndex=P.cryptoPeriodIndex);var h,z,m=!!((h=P.videoData.K)==null?0:(z=h.video)==null?0:z.isHdr());e.drmVideoFeature=m?"DRM_VIDEO_FEATURE_PREFER_HDR": "DRM_VIDEO_FEATURE_SDR";if(e.context&&e.context.client){if(h=P.O$.W)e.context.client.deviceMake=h.cbrand,e.context.client.deviceModel=h.cmodel,e.context.client.browserName=h.cbr,e.context.client.browserVersion=h.cbrver,e.context.client.osName=h.cos,e.context.client.osVersion=h.cosver;e.context.user=e.context.user||{};e.context.request=e.context.request||{};P.videoData.QW&&(e.context.user.credentialTransferTokens=[{token:P.videoData.QW,scope:"VIDEO"}]);e.context.request.mdxEnvironment=P.videoData.mdxEnvironment|| e.context.request.mdxEnvironment;P.videoData.Bg&&(e.context.user.kidsParent={oauthToken:P.videoData.Bg});g.Eo(P.K)&&(e.fairplayKeyId=g.D7(Zxw(P.fairplayKeyId)));g.QW(P.O$,g.MA(P.videoData)).then(function(Q){pdy(v,e,l,Q);P.status="rs"})}else P.error("drm.net",2,"t.r;ic.0")}; Zj2=function(P,v){if(!P.s$())if(nf(P,{onlcsrsp:1}),P.status="rr",v.statusCode!==0)P.error("drm.auth",1,"t.f;c."+v.statusCode,v.errorMessage||void 0);else{WI("drm_kr_s",void 0,P.videoData.q5);if(v.heartbeatParams&&v.heartbeatParams.url&&P.videoData.V("outertube_streaming_data_always_use_staging_license_service")){var l=P.K.K.match(/(.*)youtube.com/g);l&&(v.heartbeatParams.url=l[0]+v.heartbeatParams.url)}v.heartbeatParams&&P.publish("newlicense",v.heartbeatParams);v.K&&(P.Y=v.K,P.videoData.X3||P.publish("newlicense", new FeD),P.videoData.X3=!0,P.S=iB(P.Y,function(e){return e.includes("HDR")})); v.W&&(P.O$.V("html5_enable_vp9_fairplay")&&Hj(P.K)?(l=g.D7(Zxw(P.fairplayKeyId),4),P.W[l]={type:v.W[l],status:"unknown"}):P.W=KU(v.W,function(e){return{type:e,status:"unknown"}})); aK(P.K)&&(v.message=GjB(g.D7(v.message)));P.G&&(nf(P,{updtks:1}),P.status="ku",P.G.update(v.message).then(function(){WI("drm_kr_f",void 0,P.videoData.q5);N5(P)||(nf(P,{ksApiUnsup:1}),P.publish("keystatuseschange",P))},function(e){e="msuf.req."+P.requestNumber+";msg."+g.n$(e.message,3); P.error("drm.keyerror",1,e)})); P.j&&(P.J5=(0,g.Gz)());g.Eo(P.K)&&P.publish("fairplay_next_need_key_info",P.baseUrl,v.nextFairplayKeyId);P.O$.V("html5_enable_vp9_fairplay")&&Hj(P.K)&&P.publish("qualitychange",EM6(P.Y));v.sabrLicenseConstraint&&P.publish("sabrlicenseconstraint",v.sabrLicenseConstraint)}}; jh6=function(P,v){var l=v.W.getValue();l=new g.mr(function(){aNw(P,v)},l); g.Z(P,l);l.start();g.x7(v.W);nf(P,{rtyrq:1})}; WeB=function(P,v){for(var l=[],e=g.N(Object.keys(P.W)),h=e.next();!h.done;h=e.next())h=h.value,l.push(h+"_"+P.W[h].type+"_"+P.W[h].status);return l.join(v)}; Ojq=function(P){var v={};v[P.status]=N5(P)?WeB(P,"."):P.Y.join(".");return v}; oM2=function(P,v){switch(P){case "highres":case "hd2880":P="UHD2";break;case "hd2160":case "hd1440":P="UHD1";break;case "hd1080":case "hd720":P="HD";break;case "large":case "medium":case "small":case "light":case "tiny":P="SD";break;default:return""}v&&(P+="HDR");return P}; shw=function(P,v){for(var l in P.W)if(P.W[l].status==="usable"&&P.W[l].type===v)return!0;return!1}; rca=function(P,v){for(var l in P.W)if(P.W[l].type===v)return P.W[l].status}; nf=function(P,v){var l=l===void 0?!1:l;bp(v);(l||P.O$.vK())&&P.publish("ctmp","drmlog",v)}; MrP=function(P){var v=P[0];P[0]=P[3];P[3]=v;v=P[1];P[1]=P[2];P[2]=v;v=P[4];P[4]=P[5];P[5]=v;v=P[6];P[6]=P[7];P[7]=v}; EM6=function(P){return g.ro(P,"UHD2")||g.ro(P,"UHD2HDR")?"highres":g.ro(P,"UHD1")||g.ro(P,"UHD1HDR")?"hd2160":g.ro(P,"HD")||g.ro(P,"HDHDR")?"hd1080":g.ro(P,"HD720")||g.ro(P,"HD720HDR")?"hd720":"large"}; UA2=function(P){for(var v="",l=0;l '.charCodeAt(e);P=P.G.createSession("video/mp4",v,l);return new Jg(null,null,null,null,P)}; lnx=function(P,v){var l=P.T[v.sessionId];!l&&P.Y&&(l=P.Y,P.Y=null,l.sessionId=v.sessionId,P.T[v.sessionId]=l);return l}; dA2=function(P,v){var l=P.subarray(4);l=new Uint16Array(l.buffer,l.byteOffset,l.byteLength/2);l=String.fromCharCode.apply(null,l).match(/ek=([0-9a-f]+)/)[1];for(var e="",h=0;h =0&&P.push(e);P=parseFloat(P.join("."))}else P=NaN;P>19.2999?(P=l.S9,l=l.N1,l>=P&&(l=P*.75),v=(P-l)*.5,l=new It(v,P,P-v-l,this)):l=null;break a;case "widevine":l=new DQ(v,this,P);break a;default:l=null}if(this.Z=l)g.Z(this,this.Z),this.Z.subscribe("rotated_need_key_info_ready",this.DP,this),this.Z.subscribe("log_qoe",this.B9,this);Oo(this.O$.experiments);this.B9({cks:this.W.getInfo()})}; hsy=function(P){var v=P.Y.aW();v?v.then(c1(function(){mhy(P)}),c1(function(l){if(!P.s$()){g.Zx(l); var e="t.a";l instanceof DOMException&&(e+=";n."+l.name+";m."+l.message);P.publish("licenseerror","drm.unavailable",1,e,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK")}})):(P.B9({mdkrdy:1}),P.X=!0); P.Wg&&(v=P.Wg.aW())}; Q0D=function(P,v,l){P.Pg=!0;l=new gq(v,l);P.O$.V("html5_eme_loader_sync")&&(P.T.get(v)||P.T.set(v,l));RsD(P,l)}; RsD=function(P,v){if(!P.s$()){P.B9({onInitData:1});if(P.O$.V("html5_eme_loader_sync")&&P.videoData.G&&P.videoData.G.W){var l=P.j.get(v.initData);v=P.T.get(v.initData);if(!l||!v)return;v=l;l=v.initData;P.T.remove(l);P.j.remove(l)}P.B9({initd:v.initData.length,ct:v.contentType});if(P.W.flavor==="widevine")if(P.kf&&!P.videoData.isLivePlayback)cR(P);else{if(!(P.O$.V("vp9_drm_live")&&P.videoData.isLivePlayback&&v.C6)){P.kf=!0;l=v.cryptoPeriodIndex;var e=v.W;WKy(v);v.C6||(e&&v.W!==e?P.publish("ctmp","cpsmm", {emsg:e,pssh:v.W}):l&&v.cryptoPeriodIndex!==l&&P.publish("ctmp","cpimm",{emsg:l,pssh:v.cryptoPeriodIndex}));P.publish("widevine_set_need_key_info",v)}}else P.DP(v)}}; mhy=function(P){if(!P.s$())if(P.O$.V("html5_drm_set_server_cert")||Hj(P.W)){var v=P.Y.setServerCertificate();v?v.then(c1(function(l){P.O$.vK()&&P.publish("ctmp","ssc",{success:l})}),c1(function(l){P.publish("ctmp","ssce",{n:l.name, m:l.message})})).then(c1(function(){tD6(P)})):tD6(P)}else tD6(P)}; tD6=function(P){P.s$()||(P.X=!0,P.B9({onmdkrdy:1}),cR(P))}; yEa=function(P){return P.W.flavor==="widevine"&&P.videoData.V("html5_drm_cpi_license_key")}; cR=function(P){if((P.Pg||P.O$.V("html5_widevine_use_fake_pssh"))&&P.X&&!P.T1){for(;P.G.length;){var v=P.G[0],l=yEa(P)?Oo7(v):g.D7(v.initData);if(Hj(P.W)&&!v.K)P.G.shift();else{if(P.K.get(l))if(P.W.flavor!=="fairplay"||Hj(P.W)){P.G.shift();continue}else P.K.delete(l);WKy(v);break}}P.G.length&&P.createSession(P.G[0])}}; CWq=function(P){var v;if(v=g.VS()){var l;v=!((l=P.Y.K)==null||!l.getMetrics)}v&&(v=P.Y.getMetrics())&&(v=g.pa(v),P.publish("ctmp","drm",{metrics:v}))}; f2w=function(){var P=jjD();return!(!P||P==="visible")}; kbx=function(P){var v=gb9();v&&document.addEventListener(v,P,!1)}; wmu=function(P){var v=gb9();v&&document.removeEventListener(v,P,!1)}; gb9=function(){if(document.visibilityState)var P="visibilitychange";else{if(!document[JB+"VisibilityState"])return"";P=JB+"visibilitychange"}return P}; $Jq=function(P){g.U.call(this);var v=this;this.M5=P;this.Yl=0;this.T=this.K=this.Z=!1;this.Y=0;this.Z3=this.M5.N();this.videoData=this.M5.getVideoData();this.G=g.ID(this.Z3.experiments,"html5_delayed_retry_count");this.W=new g.mr(function(){v.M5.hB()},g.ID(this.Z3.experiments,"html5_delayed_retry_delay_ms")); g.Z(this,this.W)}; JEW=function(P,v,l){var e=P.videoData.K,h=P.videoData.Y;Rh(P.M5.getVideoData())&&P.Z3.V("html5_gapless_fallback_on_qoe_restart")&&Ke7(P.M5,"pe");if((v==="progressive.net.retryexhausted"||v==="fmt.unplayable"||v==="fmt.decode")&&!P.M5.nw.Z&&e&&e.itag==="22")return P.M5.nw.Z=!0,P.x_("qoe.restart",{reason:"fmt.unplayable.22"}),P.M5.g2(),!0;var z=!1;if(P.videoData.isExternallyHostedPodcast){if(z=P.videoData.mV)l.mimeType=z.type,P.f0("3pp",{url:z.url});l.ns="3pp";P.M5.VI(v,1,"VIDEO_UNAVAILABLE",bp((new xq(v, l,1)).details));return!0}var m=P.Yl+3E4<(0,g.Gz)()||P.W.isActive();if(P.Z3.V("html5_empty_src")&&P.videoData.isAd()&&v==="fmt.unplayable"&&/Empty src/.test(""+l.msg))return l.origin="emptysrc",P.x_("auth",l),!0;m||q5(P.M5.QK())||(l.nonfg="paused",m=!0,P.M5.pauseVideo());(v==="fmt.decode"||v==="fmt.unplayable")&&(h==null?0:VT(h)||dl(h))&&(xkx(P.Z3.Z,h.dM),l.acfallexp=h.dM,z=m=!0);!m&&P.G>0&&(P.W.start(),m=!0,l.delayed="1",--P.G);h=P.M5.K0;!m&&((e==null?0:Ta(e))||(e==null?0:rl(e)))&&(xkx(P.Z3.Z,e.dM), z=m=!0,l.cfallexp=e.dM);if(P.Z3.V("html5_ssap_ignore_decode_error_for_next_video")&&g.VW(P.videoData)&&v==="fmt.unplayable"&&l.cid&&l.ccid&&q5(P.M5.QK())){if(l.cid!==l.ccid)return l.ignerr="1",P.x_("ssap.transitionfailure",l),!0;P.x_("ssap.transitionfailure",l);if(I2w(P.M5,v))return!0}if(!m)return DJy(P,l);if(P.Z3.V("html5_ssap_skip_decoding_clip_with_incompatible_codec")&&g.VW(P.videoData)&&v==="fmt.unplayable"&&l.cid&&l.ccid&&l.cid!==l.ccid&&q5(P.M5.QK())&&(P.x_("ssap.transitionfailure",l),I2w(P.M5, v)))return!0;m=!1;P.Z?P.Yl=(0,g.Gz)():m=P.Z=!0;var Q=P.videoData;if(Q.A5){Q=Q.A5.tx();var t=Date.now()/1E3+1800;Q=Q 6048E5&&q9B(P,"signature");return!1}; q9B=function(P,v){try{window.location.reload(),P.x_("qoe.restart",{detail:"pr."+v})}catch(l){}}; AEP=function(P,v){v=v===void 0?"fmt.noneavailable":v;var l=P.Z3.Z;l.T=!1;QP(l);P.x_("qoe.restart",{e:v,detail:"hdr"});P.M5.hB(!0)}; Y9D=function(P,v,l,e,h,z){this.videoData=P;this.W=v;this.reason=l;this.K=e;this.token=h;this.videoId=z}; bLD=function(P,v,l){this.O$=P;this.LG=v;this.M5=l;this.S=this.T=this.W=this.Y=this.j=this.K=0;this.Z=!1;this.X=g.ID(this.O$.experiments,"html5_displayed_frame_rate_downgrade_threshold")||45;this.G=new Map}; pm2=function(P,v,l){!P.O$.V("html5_tv_ignore_capable_constraint")&&g.pF(P.O$)&&(l=l.compose(xJW(P,v)));return l}; S9W=function(P,v){var l,e=LPw(P,(l=v.W)==null?void 0:l.videoInfos);l=P.M5.getPlaybackRate();return l>1&&e?(P=cUW(P.O$.Z,v.W.videoInfos,l),new m4(0,P,!0,"o")):new m4(0,0,!1,"o")}; LPw=function(P,v){return v&&g.pF(P.O$)?v.some(function(l){return l.video.fps>32}):!1}; Gbq=function(P,v){var l=P.M5.Mk();P.V("html5_use_video_quality_cap_for_ustreamer_constraint")&&l&&l.PO>0&&tR(v.videoData.W3)&&(P=l.PO,v.videoData.W3=new m4(0,P,!1,"u"));return v.videoData.W3}; xJW=function(P,v){if(g.pF(P.O$)&&Kr(P.O$.Z,cn.HEIGHT))var l=v.W.videoInfos[0].video.W;else{var e=!!v.W.W;var h;g.iy(P.O$)&&(h=window.screen&&window.screen.width?new g.Dc(window.screen.width,window.screen.height):null);h||(h=P.O$.SI?P.O$.SI.clone():P.LG.CJ());(eB||eD||e)&&h.scale(g.d7());e=h;Qi(v.videoData)||dw(v.videoData);v=v.W.videoInfos;if(v.length){h=g.ID(P.O$.experiments,"html5_override_oversend_fraction")||.85;var z=v[0].video;z.projectionType!=="MESH"&&z.projectionType!=="EQUIRECTANGULAR"&& z.projectionType!=="EQUIRECTANGULAR_THREED_TOP_BOTTOM"||Xu||(h=.45);P=g.ID(P.O$.experiments,"html5_viewport_undersend_maximum");for(z=0;z 0&&(l=Math.min(l,e));if(e=g.ID(P.O$.experiments,"html5_max_vertical_resolution")){P=4320;for(h=0;h e&&(P=Math.min(P,z.video.W));if(P<4320){for(h=e=0;h 32){h=!0;break a}}h=!1}h&&(l=Math.min(l,e));(e=g.ID(P.O$.experiments,"html5_live_quality_cap"))&&v.videoData.isLivePlayback&&(l=Math.min(l,e));l=Bqu(P,v,l);P=g.ID(P.O$.experiments,"html5_byterate_soft_cap");return new m4(0,l===4320?0:l,!1,"d",P)}; UJP=function(P){var v,l,e,h;return g.p(function(z){switch(z.W){case 1:return P.W.W&&typeof((v=navigator.mediaCapabilities)==null?void 0:v.decodingInfo)==="function"?g.b(z,Promise.resolve(),2):z.return(Promise.resolve());case 2:l=g.N(P.W.videoInfos),e=l.next();case 3:if(e.done){z.ac(0);break}h=e.value;return g.b(z,$QD(h),4);case 4:e=l.next(),z.ac(3)}})}; jcq=function(P,v){if(!v.videoData.K||P.V("html5_disable_performance_downgrade"))return!1;Date.now()-P.j>6E4&&(P.K=0);P.K++;P.j=Date.now();if(P.K!==4)return!1;ZLu(P,v.videoData.K);return!0}; HLy=function(P,v,l,e){if(!v||!l||!v.videoData.K)return!1;var h=g.ID(P.O$.experiments,"html5_df_downgrade_thresh"),z=P.V("html5_log_media_perf_info");if(!((0,g.Gz)()-P.Y<5E3?0:z||h>0))return!1;var m=((0,g.Gz)()-P.Y)/1E3;P.Y=(0,g.Gz)();l=l.getVideoPlaybackQuality();if(!l)return!1;var Q=l.droppedVideoFrames-P.T,t=l.totalVideoFrames-P.S;P.T=l.droppedVideoFrames;P.S=l.totalVideoFrames;var y=l.displayCompositedVideoFrames===0?0:l.displayCompositedVideoFrames||-1;z&&P.O$.vK()&&P.M5.f0("ddf",{dr:l.droppedVideoFrames, de:l.totalVideoFrames,comp:y});if(e)return P.W=0,!1;if((t-Q)/m>P.X||!h||g.pF(P.O$))return!1;P.W=(t>60?Q/t:0)>h?P.W+1:0;if(P.W!==3)return!1;ZLu(P,v.videoData.K);P.M5.f0("dfd",Object.assign({dr:l.droppedVideoFrames,de:l.totalVideoFrames},a2a()));return!0}; ZLu=function(P,v){var l=v.dM,e=v.video.fps,h=v.video.W-1,z=P.G;v=""+l+(e>49?"p60":e>32?"p48":"");l=Sa(l,e,z);h>0&&(l=Math.min(l,h));if(!F1.has(v)&&W1().includes(v)){var m=l;l=Eg();+l[v]>0&&(m=Math.min(+l[v],m));l[v]!==m&&(l[v]=m,g.jB("yt-player-performance-cap",l,2592E3))}else if(F1.has(v)||z==null){a:{m=m===void 0?!0:m;e=W1().slice();if(m){if(e.includes(v))break a;e.push(v)}else{if(!e.includes(v))break a;e.splice(e.indexOf(v),1)}g.jB("yt-player-performance-cap-active-set",e,2592E3)}Lq.set(v,l)}else F1.add(v), z==null||z.set(v,l);P.M5.MP()}; Ag=function(P,v){if(!v.W.W)return P.Z?new m4(0,360,!1,"b"):Ov;for(var l=!1,e=!1,h=g.N(v.W.videoInfos),z=h.next();!z.done;z=h.next())Ta(z.value)?l=!0:e=!0;l=l&&e;e=0;h=g.ID(P.O$.experiments,"html5_performance_cap_floor");h=P.O$.K?240:h;v=g.N(v.W.videoInfos);for(z=v.next();!z.done;z=v.next()){var m=z.value;if(!l||!Ta(m))if(z=Sa(m.dM,m.video.fps,P.G),m=m.video.W,Math.max(z,h)>=m){e=m;break}}return new m4(0,e,!1,"b")}; Eba=function(P,v){var l=P.M5.QK();return l.isInline()&&!v.lf?new m4(0,480,!1,"v"):l.isBackground()&&Ly()/1E3>60&&!g.pF(P.O$)?new m4(0,360,!1,"v"):Ov}; WP7=function(P,v,l){if(P.O$.experiments.l$("html5_disable_client_autonav_cap_for_onesie")&&v.fetchType==="onesie"||g.pF(P.O$)&&(aJ(-1)>=1080||v.osid))return Ov;var e=g.ID(P.O$.experiments,"html5_autonav_quality_cap"),h=g.ID(P.O$.experiments,"html5_autonav_cap_idle_secs");return e&&v.isAutonav&&Ly()/1E3>h?(l&&(e=Bqu(P,l,e)),new m4(0,e,!1,"e")):Ov}; Bqu=function(P,v,l){if(P.V("html5_optimality_defaults_chooses_next_higher")&&l)for(P=v.W.videoInfos,v=1;v =0||(P.provider.M5.getVisibilityState()===3?P.Z=!0:(P.W=g.b7(P.provider),P.delay.start()))}; scw=function(P){if(!(P.K<0)){var v=g.b7(P.provider),l=v-P.Y;P.Y=v;P.playerState.state===8?P.playTimeSecs+=l:P.playerState.isBuffering()&&!g.M(P.playerState,16)&&(P.rebufferTimeSecs+=l)}}; rED=function(P){var v;switch((v=P.O$.playerCanaryStage)==null?void 0:v.toLowerCase()){case "xsmall":return"HTML5_PLAYER_CANARY_STAGE_XSMALL";case "small":return"HTML5_PLAYER_CANARY_STAGE_SMALL";case "medium":return"HTML5_PLAYER_CANARY_STAGE_MEDIUM";case "large":return"HTML5_PLAYER_CANARY_STAGE_LARGE";default:return"HTML5_PLAYER_CANARY_STAGE_UNSPECIFIED"}}; MDw=function(P){return window.PressureObserver&&new window.PressureObserver(P)}; Tqw=function(P,v){v=v===void 0?MDw:v;g.U.call(this);var l=this;if(this.Z=P)try{this.W=v(function(z){l.K=z.at(-1)}); var e;this.G=(e=this.W)==null?void 0:e.observe("cpu",{sampleInterval:2E3}).catch(function(z){z instanceof DOMException&&(l.Y=z)})}catch(z){z instanceof DOMException&&(this.Y=z)}else{this.W=v(function(z){l.K=z.at(-1)}); var h;this.G=(h=this.W)==null?void 0:h.observe("cpu",{sampleInterval:2E3})}}; VD6=function(P){var v={},l=window.h5vcc;v.hwConcurrency=navigator.hardwareConcurrency;P.Y&&(v.cpe=P.Y.message);P.K&&(v.cpt=P.K.time,v.cps=P.K.state);if(l==null?0:l.cVal)v.cb2s=l.cVal.getValue("CPU.Total.Usage.IntervalSeconds.2"),v.cb5s=l.cVal.getValue("CPU.Total.Usage.IntervalSeconds.5"),v.cb30s=l.cVal.getValue("CPU.Total.Usage.IntervalSeconds.30");return v}; dJ9=function(P){var v;g.p(function(l){switch(l.W){case 1:if(!P.Z)return g.b(l,P.G,3);g.NP(l,4);return g.b(l,P.G,6);case 6:g.uD(l,3);break;case 4:g.Kx(l);l.ac(3);break;case 3:(v=P.W)==null||v.disconnect(),g.nx(l)}})}; vPw=function(P,v){v?PSa.test(P):(P=g.fG(P),Object.keys(P).includes("cpn"))}; erB=function(P,v,l,e,h,z,m){var Q={format:"RAW"},t={};if(w$(P)&&$N()){if(m){var y;((y=l$9.uaChPolyfill)==null?void 0:y.state.type)!==2?m=null:(m=l$9.uaChPolyfill.state.data.values,m={"Synth-Sec-CH-UA-Arch":m.architecture,"Synth-Sec-CH-UA-Model":m.model,"Synth-Sec-CH-UA-Platform":m.platform,"Synth-Sec-CH-UA-Platform-Version":m.platformVersion,"Synth-Sec-CH-UA-Full-Version":m.uaFullVersion});t=Object.assign(t,m);Q.withCredentials=!0}(m=g.la("EOM_VISITOR_DATA"))?t["X-Goog-EOM-Visitor-Id"]=m:e?t["X-Goog-Visitor-Id"]= e:g.la("VISITOR_DATA")&&(t["X-Goog-Visitor-Id"]=g.la("VISITOR_DATA"));l&&(t["X-Goog-PageId"]=l);(e=v.T1)&&!vo(v)&&(t["X-Goog-AuthUser"]=e);h&&(t.Authorization="Bearer "+h);v.V("enable_datasync_id_header_in_web_vss_pings")&&v.A1&&v.datasyncId&&(t["X-YouTube-DataSync-Id"]=v.datasyncId);m||t["X-Goog-Visitor-Id"]||h||l||e?Q.withCredentials=!0:v.V("html5_send_cpn_with_options")&&PSa.test(P)&&(Q.withCredentials=!0)}Object.keys(t).length>0&&(Q.headers=t);z&&(Q.onFinish=z);return Object.keys(Q).length>1? Q:null}; hra=function(P,v,l,e,h,z,m,Q){$N()&&l.token&&(P=g$(P,{ctt:l.token,cttype:l.f4,mdx_environment:l.mdxEnvironment}));e.V("net_pings_low_priority")&&(v||(v={}),v.priority="low");z||Q&&e.V("nwl_skip_retry")?(v==null?v={}:vPw(P,e.V("html5_assert_cpn_with_regex")),m?eg().sendAndWrite(P,v):eg().sendThenWrite(P,v,Q)):v?(vPw(P,e.V("html5_assert_cpn_with_regex")),e.V("net_pings_use_fetch")?CnP(P,v):g.SN(P,v)):g.oO(P,h)}; zr2=function(P){for(var v=[],l=0;l 0&&l>0&&!P.K&&P.G<1E7)try{P.Y=P.Z({sampleInterval:v,maxBufferSize:l});var e;(e=P.Y)==null||e.addEventListener("samplebufferfull",function(){return g.p(function(h){if(h.W==1)return g.b(h,P.stop(),2);QzB(P);g.nx(h)})})}catch(h){P.K=Rrq(h.message)}}; pf=function(P,v){var l,e;return!!((l=window.h5vcc)==null?0:(e=l.settings)==null?0:e.set(P,v))}; ysD=function(){var P,v,l,e=(P=window.h5vcc)==null?void 0:(v=P.settings)==null?void 0:(l=v.getPersistentSettingAsString)==null?void 0:l.call(v,"cpu_usage_tracker_intervals");if(e!=null){var h;P=(h=JSON.parse(e))!=null?h:[];h=P.filter(function(y){return y.type==="total"}).map(function(y){return y.seconds}); v=g.N(tA7);for(l=v.next();!l.done;l=v.next())l=l.value,h.indexOf(l)===-1&&P.push({type:"total",seconds:l});var z,m;(z=window.h5vcc)==null||(m=z.settings)==null||m.set("cpu_usage_tracker_intervals_enabled",1);var Q,t;(Q=window.h5vcc)==null||(t=Q.settings)==null||t.set("cpu_usage_tracker_intervals",JSON.stringify(P))}}; CSw=function(){var P=window.H5vccPlatformService,v="";if(P&&P.has("dev.cobalt.coat.clientloginfo")&&(P=P.open("dev.cobalt.coat.clientloginfo",function(){}))){var l=P.send(new ArrayBuffer(0)); l&&(v=String.fromCharCode.apply(String,g.u(new Uint8Array(l))));P.close()}return v}; g.G5=function(P,v){g.U.call(this);var l=this;this.provider=P;this.logger=new g.Rf("qoe");this.W={};this.sequenceNumber=1;this.T=NaN;this.Ak="N";this.X=this.h$=this.ym=this.TG=this.Z=0;this.CI=this.Hg=this.j=this.q5="";this.Xq=this.Pg=NaN;this.Nd=0;this.zK=-1;this.aV=1;this.playTimeSecs=this.rebufferTimeSecs=0;this.Bg=this.isEmbargoed=this.kf=this.isOffline=this.isBuffering=!1;this.oV=[];this.QW=null;this.U$=this.G=this.D3=this.S=!1;this.K=-1;this.h5=!1;this.MV=new g.mr(this.O05,750,this);this.Wg= this.adCpn=this.J5=this.contentCpn="";this.adFormat=void 0;this.bC=0;this.hs=new Set("cl fexp drm drm_system drm_product ns el adformat live cat shbpslc".split(" "));this.SN=new Set(["gd"]);this.serializedHouseBrandPlayerServiceLoggingContext="";this.nI=!1;this.It=NaN;this.wM=0;this.WK=!1;this.T1=0;this.remoteConnectedDevices=[];this.remoteControlMode=void 0;this.jS=!1;this.Kh={gF:function(h){l.gF(h)}, He2:function(){return l.Y}, QZ:function(){return l.contentCpn}, XUc:function(){return l.J5}, reportStats:function(){l.reportStats()}, Sq6:function(){return l.W.cat}, Ts:function(h){return l.W[h]}, dg$:function(){return l.T1}}; var e=g.ID(this.provider.O$.experiments,"html5_qoe_proto_mock_length");e&&!Lf.length&&(Lf=zr2(e));g.Z(this,this.MV);try{navigator.getBattery().then(function(h){l.QW=h})}catch(h){}g.Sh(this,0,"vps",["N"]); P.O$.vK()&&(this.wM=(0,g.Gz)(),this.It=g.cM(function(){var h=(0,g.Gz)(),z=h-l.wM;z>500&&l.f0("vmlock",{diff:z.toFixed()});l.wM=h},250)); P.M5.A3()&&v&&(this.T1=v-Math.round(g.b7(P)*1E3));this.provider.videoData.e_&&(this.remoteControlMode=f$u[this.provider.videoData.e_]||0);this.provider.videoData.wY&&(v=Xb2(this.provider.videoData.wY),v==null?0:v.length)&&(this.remoteConnectedDevices=v);if(P.O$.vK()||P.V("html5_log_cpu_info"))this.A5=new Tqw(P.V("html5_catch_cpu_info_errors")),g.Z(this,this.A5);v=g.ID(P.O$.experiments,"html5_js_self_profiler_sample_interval_ms");P=g.ID(P.O$.experiments,"html5_js_self_profiler_max_samples");v>0&&P> 0&&(this.Ic=new xc(v,P),g.Z(this,this.Ic))}; g.Sh=function(P,v,l,e){var h=P.W[l];h||(h=[],P.W[l]=h);h.push(v.toFixed(3)+":"+e.join(":"))}; gPD=function(P,v){var l=P.adCpn||P.provider.videoData.clientPlaybackNonce,e=P.provider.getCurrentTime(l);g.Sh(P,v,"cmt",[e.toFixed(3)]);e=P.provider.xv(l);if(P.Y&&e*1E3>P.Y.St+100&&P.Y){var h=P.Y;l=h.isAd;e=e*1E3-h.St;P.QO=v*1E3-h.cB5-e-h.SF3;h=(0,g.Gz)()-e;v=P.QO;e=P.provider.videoData;var z=e.isAd();if(l||z){z=(l?"ad":"video")+"_to_"+(z?"ad":"video");var m={};e.T&&(m.cttAuthInfo={token:e.T,videoId:e.videoId});m.startTime=h-v;o5(z,m);g.On({targetVideoId:e.videoId,targetCpn:e.clientPlaybackNonce}, z);WI("pbs",h,z)}else h=P.provider.M5.w7(),h.T!==e.clientPlaybackNonce?(h.Z=e.clientPlaybackNonce,h.K=v):e.Go()||g.j4(new g.Ph("CSI timing logged before gllat",{cpn:e.clientPlaybackNonce}));P.f0("gllat",{l:P.QO.toFixed(),prev_ad:+l});delete P.Y}}; X1=function(P,v){v=v===void 0?NaN:v;v=v>=0?v:g.b7(P.provider);var l=P.provider.M5.rC(),e=l.xE-(P.Pg||0);e>0&&g.Sh(P,v,"bwm",[e,(l.d2-(P.Xq||0)).toFixed(3)]);isNaN(P.Pg)&&l.xE&&P.isOffline&&P.gF(!1);P.Pg=l.xE;P.Xq=l.d2;isNaN(l.bandwidthEstimate)||g.Sh(P,v,"bwe",[l.bandwidthEstimate.toFixed(0)]);P.provider.O$.vK()&&Object.keys(l.W).length!==0&&P.f0("bwinfo",l.W);if(P.provider.O$.vK()||P.provider.O$.V("html5_log_meminfo"))e=GkP(),Object.values(e).some(function(z){return z!==void 0})&&P.f0("meminfo", e); if(P.provider.O$.vK()||P.provider.O$.V("html5_log_cpu_info")){var h;(e=(h=P.A5)==null?void 0:VD6(h))&&Object.values(e).some(function(z){return z!=null})&&P.f0("cpuinfo",e)}P.Ic&&P.f0("jsprof",P.Ic.flush()); P.QW&&g.Sh(P,v,"bat",[P.QW.level,P.QW.charging?"1":"0"]);h=P.provider.M5.getVisibilityState();P.zK!==h&&(g.Sh(P,v,"vis",[h]),P.zK=h);gPD(P,v);(h=kKD(P.provider))&&h!==P.Nd&&(g.Sh(P,v,"conn",[h]),P.Nd=h);wU6(P,v,l)}; wU6=function(P,v,l){if(!isNaN(l.MX)){var e=l.MX;l.K
96E3&&(new g.mr(P.reportStats,0,P)).start()}; DKw=function(P){P.provider.videoData.oV&&BR(P,"prefetch");P.provider.videoData.Nd&&P.f0("reload",{r:P.provider.videoData.reloadReason,ct:P.provider.videoData.Nd});P.provider.videoData.U$&&BR(P,"monitor");P.provider.videoData.isLivePlayback&&BR(P,"live");ly&&BR(P,"streaming");P.provider.videoData.e_&&P.f0("ctrl",{mode:P.provider.videoData.e_},!0);if(P.provider.videoData.wY){var v=P.provider.videoData.wY.replace(/,/g,"_");P.f0("ytp",{type:v},!0)}P.provider.videoData.B_&&(v=P.provider.videoData.B_.replace(/,/g, "."),P.f0("ytrexp",{ids:v},!0));var l=P.provider.videoData;v=P.provider.O$.V("enable_white_noise")||P.provider.O$.V("enable_webgl_noop");l=g.NA(l)||g.Sr(l)||g.G6(l)||g.XV(l);(v||l)&&(v=(0,g.i7)())&&(P.W.gpu=[v]);dw(P.provider.videoData)&&g.Sh(P,g.b7(P.provider),"dt",["1"]);P.provider.O$.vK()&&(v=(0,g.Gz)()-P.provider.O$.uM,P.f0("playerage",{secs:Math.pow(1.6,Math.round(Math.log(v/1E3)/Math.log(1.6))).toFixed()}));P.G=!0;P.T=g.cM(function(){P.reportStats()},1E4)}; Ngy=function(P,v,l){var e=g.b7(P.provider);nP9(P,e,v,0,l);X1(P,e);I$y(P)}; nP9=function(P,v,l,e,h){var z=P.provider.O$.W.cbrver;P.provider.O$.W.cbr==="Chrome"&&/^96[.]/.test(z)&&l==="net.badstatus"&&/rc\.500/.test(h)&&Jsw(P,3);P.provider.O$.V("html5_use_ump")&&/b248180278/.test(h)&&Jsw(P,4);z=P.provider.getCurrentTime(P.adCpn||P.provider.videoData.clientPlaybackNonce);e=e===1?"fatal":"";l=[l,e,z.toFixed(3)];e&&(h+=";a6s."+ke());h&&l.push(uKq(h));g.Sh(P,v,"error",l);P.G=!0}; KMy=function(P){P.K>=0||(P.provider.O$.Hl||P.provider.M5.getVisibilityState()!==3?P.K=g.b7(P.provider):P.h5=!0)}; csu=function(P,v,l,e){if(l!==P.Ak){v =10&&P.playTimeSecs<=180&&(P.W.qoealert=["1"],P.Bg=!0)),l!=="B"||P.Ak!=="PL"&&P.Ak!=="PB"||(P.isBuffering=!0),P.Z=v);P.Ak==="PL"&&(l==="B"||l==="S")||P.provider.O$.vK()?X1(P,v):(P.nI||l!=="PL"||(P.nI=!0,wU6(P,v,P.provider.M5.rC())),gPD(P,v));l==="PL"&&g.RX(P.MV);var h=[l];l==="S"&&e&&h.push("ss."+e);g.Sh(P,v,"vps",h);P.Ak=l; P.TG=v;P.Z=v;P.G=!0}}; BR=function(P,v){var l=P.W.cat||[];l.push(v);P.W.cat=l}; UG=function(P,v,l,e,h,z){var m=g.b7(P.provider);l!==1&&l!==3&&l!==5||g.Sh(P,m,"vps",[P.Ak]);var Q=P.W.xvt||[];Q.push("t."+m.toFixed(3)+";m."+z.toFixed(3)+";g."+v+";tt."+l+";np.0;c."+e+";d."+h);P.W.xvt=Q}; Jsw=function(P,v){if(!P.U$){var l=P.W.fcnz;l||(l=[],P.W.fcnz=l);l.push(String(v));P.U$=!0}}; uKq=function(P){/[^a-zA-Z0-9;.!_-]/.test(P)&&(P=P.replace(/[+]/g,"-").replace(/[^a-zA-Z0-9;.!_-]/g,"_"));return P}; qHB=function(P){this.provider=P;this.j=!1;this.W=0;this.Y=-1;this.LO=NaN;this.G=0;this.segments=[];this.T=this.Z=0;this.previouslyEnded=!1;this.X=this.provider.M5.getVolume();this.S=this.provider.M5.isMuted()?1:0;this.K=ZQ(this.provider)}; jh=function(P){P.K.startTime=P.G;P.K.endTime=P.W;var v=!1;P.segments.length&&g.WA(P.segments).isEmpty()?(P.segments[P.segments.length-1].previouslyEnded&&(P.K.previouslyEnded=!0),P.segments[P.segments.length-1]=P.K,v=!0):P.segments.length&&P.K.isEmpty()||(P.segments.push(P.K),v=!0);v?P.K.endTime===0&&(P.previouslyEnded=!1):P.K.previouslyEnded&&(P.previouslyEnded=!0);P.Z+=P.W-P.G;P.K=ZQ(P.provider);P.K.previouslyEnded=P.previouslyEnded;P.previouslyEnded=!1;P.G=P.W}; As9=function(P){FMy(P);P.T=g.cM(function(){P.update()},100); P.LO=g.b7(P.provider);P.K=ZQ(P.provider)}; FMy=function(P){g.Ft(P.T);P.T=NaN}; YHP=function(P,v,l){l-=P.LO;return v===P.W&&l>.5}; bD7=function(P,v,l,e){this.O$=v;this.CI=l;this.segments=[];this.experimentIds=[];this.Ic=this.jS=this.isFinal=this.delayThresholdMet=this.nI=this.zK=this.autoplay=this.autonav=!1;this.Nd="yt";this.T=[];this.j=this.X=null;this.sendVisitorIdHeader=this.h5=!1;this.S=this.pageId="";this.Z=l==="watchtime";this.G=l==="playback";this.J5=l==="atr";this.t3=l==="engage";this.sendVisitorIdHeader=!1;this.uri=this.J5?"/api/stats/"+l:"//"+v.UU+"/api/stats/"+l;e&&(this.jS=e.fs,e.rtn&&(this.j=e.rtn),this.Z?(this.playerState= e.state,e.rti>0&&(this.X=e.rti)):(this.Hl=e.mos,this.FL=e.volume,e.at&&(this.adType=e.at)),e.autonav&&(this.autonav=e.autonav),e.inview!=null&&(this.aV=e.inview),e.size&&(this.Xq=e.size),e.playerwidth&&(this.playerWidth=e.playerwidth),e.playerheight&&(this.playerHeight=e.playerheight));this.SN=g.GA(v.W);this.S=eE(v.experiments,"html5_log_vss_extra_lr_cparams_freq");if(this.S==="all"||this.S==="once")this.WK=g.GA(v.Nd);this.XE=v.D3;this.experimentIds=NZq(v.experiments);this.q5=v.TG;this.Nd=v.Wg;this.region= v.region;this.userAge=v.userAge;this.D3=v.MZ;this.oV=Ly();this.sendVisitorIdHeader=v.sendVisitorIdHeader;this.T1=v.V("vss_pings_using_networkless")||v.V("kevlar_woffle");this.jg=v.V("vss_final_ping_send_and_write");this.kf=v.V("vss_use_send_and_write");this.pageId=v.pageId;this.uM=v.V("vss_playback_use_send_and_write");v.livingRoomAppMode&&(this.livingRoomAppMode=v.livingRoomAppMode);this.Ro=v.Y&&v.V("embeds_append_synth_ch_headers");g.LP(v)&&(this.Hg=v.kf);g.Iu(g.aw(v))&&this.T.push(1);this.accessToken= g.MA(P);P.Ep[this.CI]?this.Y=P.Ep[this.CI]:P.Ep.playback&&(this.Y=P.Ep.playback);this.adFormat=P.adFormat;this.adQueryId=P.adQueryId;this.autoplay=rw(P);this.G&&(this.zK=(P.V("html5_enable_log_server_autoplay")||P.V("enable_cleanup_masthead_autoplay_hack_fix"))&&P.Nf&&ZN(P)==="adunit"?!0:!1);this.autonav=P.isAutonav||this.autonav;this.contentVideoId=OD(P);this.clientPlaybackNonce=P.clientPlaybackNonce;this.nI=P.eg;P.T&&(this.Wg=P.T,this.Bg=P.R3);P.mdxEnvironment&&(this.mdxEnvironment=P.mdxEnvironment); this.W=P.sR;this.TG=P.TG;P.K&&(this.hs=P.K.itag,P.Y&&P.Y.itag!==this.hs&&(this.U$=P.Y.itag));P.W&&wG(P.W)&&(this.offlineDownloadUserChoice="1");this.eventLabel=ZN(P);this.Ic=P.Ro?!1:P.XE;this.bC=P.l3;if(v=FV(P))this.vl=v;this.GP=P.Z2;this.partnerId=P.partnerId;this.eventId=P.eventId;this.playlistId=P.Ve||P.playlistId;this.AK=P.AK;this.e_=P.e_;this.wY=P.wY;this.HU=P.HU;this.subscribed=P.subscribed;this.videoId=P.videoId;this.videoMetadata=P.videoMetadata;this.visitorData=P.visitorData;this.osid=P.osid; this.CG=P.CG;this.referrer=P.referrer;this.KO=P.t0||P.KO;this.A5=P.E5;this.dJ=P.dJ;this.userGenderAge=P.userGenderAge;this.P3=P.P3;this.embedsRct=P.embedsRct;this.embedsRctn=P.embedsRctn;g.LP(this.O$)&&P.mutedAutoplay&&(P.V("embeds_enable_full_length_inline_muted_autoplay")&&P.mutedAutoplayDurationMode===2&&P.limitedPlaybackDurationInSeconds===0&&P.endSeconds===0?this.T.push(7):this.T.push(2));P.isEmbedsShortsMode(new g.Dc(this.playerWidth,this.playerHeight),!!this.playlistId)&&this.T.push(3);g.mO(P)&& this.T.push(4);this.Pg=P.u1;P.compositeLiveIngestionOffsetToken&&(this.compositeLiveIngestionOffsetToken=P.compositeLiveIngestionOffsetToken)}; xKB=function(P,v){var l=P.sendVisitorIdHeader?P.visitorData:void 0;return g.QW(P.O$,P.accessToken).then(function(e){return erB(P.uri,P.O$,P.pageId,l,e,v,P.Ro)})}; SHP=function(P,v){return function(){P.O$.V("html5_simplify_pings")?(P.W=P.wM,P.MV=v(),P.oV=0,P.send()):xKB(P).then(function(l){var e=pUw(P);e.cmt=e.len;e.lact="0";var h=v().toFixed(3);e.rt=Number(h).toString();e=g.r5(P.uri,e);P.O$.V("vss_through_gel_double")&&LMy(e);P.T1?(l==null&&(l={}),P.kf?eg().sendAndWrite(e,l):eg().sendThenWrite(e,l)):l?g.SN(e,l):g.oO(e)})}}; pUw=function(P){var v={ns:P.Nd,el:P.eventLabel,cpn:P.clientPlaybackNonce,ver:2,cmt:P.K(P.W),fmt:P.hs,fs:P.jS?"1":"0",rt:P.K(P.MV),adformat:P.adFormat,content_v:P.contentVideoId,euri:P.XE,lact:P.oV,live:P.vl,cl:(722885260).toString(),mos:P.Hl,state:P.playerState,volume:P.FL};P.subscribed&&(v.subscribed="1");Object.assign(v,P.SN);P.S==="all"?Object.assign(v,P.WK):P.S==="once"&&P.G&&Object.assign(v,P.WK);P.autoplay&&(v.autoplay="1");P.zK&&(v.sautoplay="1");P.nI&&(v.dni="1");!P.Z&&P.Hg&&(v.epm=GKx[P.Hg]); P.isFinal&&(v["final"]="1");P.Ic&&(v.splay="1");P.TG&&(v.delay=P.TG);P.q5&&(v.hl=P.q5);P.region&&(v.cr=P.region);P.userGenderAge&&(v.uga=P.userGenderAge);P.userAge!==void 0&&P.D3&&(v.uga=P.D3+P.userAge);P.wM!==void 0&&(v.len=P.K(P.wM));!P.Z&&P.experimentIds.length>0&&(v.fexp=P.experimentIds.toString());P.j!==null&&(v.rtn=P.K(P.j));P.KO&&(v.feature=P.KO);P.e_&&(v.ctrl=P.e_);P.wY&&(v.ytr=P.wY);P.U$&&(v.afmt=P.U$);P.offlineDownloadUserChoice&&(v.ODUC=P.offlineDownloadUserChoice);P.It&&(v.lio=P.K(P.It)); P.Z?(v.idpj=P.bC,v.ldpj=P.GP,P.delayThresholdMet&&(v.dtm="1"),P.X!=null&&(v.rti=P.K(P.X)),P.P3&&(v.ald=P.P3),P.compositeLiveIngestionOffsetToken&&(v.clio=P.compositeLiveIngestionOffsetToken)):P.adType!==void 0&&(v.at=P.adType);P.Xq&&(P.G||P.Z)&&(v.size=P.Xq);P.G&&P.T.length&&(v.pbstyle=P.T.join(","));P.aV!=null&&(P.G||P.Z)&&(v.inview=P.K(P.aV));P.Z&&(v.volume=at(P,g.LC(P.segments,function(e){return e.volume})),v.st=at(P,g.LC(P.segments,function(e){return e.startTime})),v.et=at(P,g.LC(P.segments,function(e){return e.endTime})), iB(P.segments,function(e){return e.playbackRate!==1})&&(v.rate=at(P,g.LC(P.segments,function(e){return e.playbackRate}))),iB(P.segments,function(e){return e.W!=="-"})&&(v.als=g.LC(P.segments,function(e){return e.W}).join(",")),iB(P.segments,function(e){return e.previouslyEnded})&&(v.pe=g.LC(P.segments,function(e){return""+ +e.previouslyEnded}).join(","))); v.muted=at(P,g.LC(P.segments,function(e){return e.muted?1:0})); iB(P.segments,function(e){return e.visibilityState!==0})&&(v.vis=at(P,g.LC(P.segments,function(e){return e.visibilityState}))); iB(P.segments,function(e){return e.connectionType!==0})&&(v.conn=at(P,g.LC(P.segments,function(e){return e.connectionType}))); iB(P.segments,function(e){return e.K!==0})&&(v.blo=at(P,g.LC(P.segments,function(e){return e.K}))); iB(P.segments,function(e){return!!e.G})&&(v.blo=g.LC(P.segments,function(e){return e.G}).join(",")); iB(P.segments,function(e){return!!e.compositeLiveStatusToken})&&(v.cbs=g.LC(P.segments,function(e){return e.compositeLiveStatusToken}).join(",")); iB(P.segments,function(e){return e.Z!=="-"})&&(v.cc=g.LC(P.segments,function(e){return e.Z}).join(",")); iB(P.segments,function(e){return e.clipId!=="-"})&&(v.clipid=g.LC(P.segments,function(e){return e.clipId}).join(",")); if(iB(P.segments,function(e){return!!e.Y})){var l="au"; P.G&&(l="au_d");v[l]=g.LC(P.segments,function(e){return e.Y}).join(",")}$N()&&P.Wg&&(v.ctt=P.Wg,v.cttype=P.Bg,v.mdx_environment=P.mdxEnvironment); P.t3&&(v.etype=P.QW!==void 0?P.QW:0);P.A5&&(v.uoo=P.A5);P.livingRoomAppMode&&P.livingRoomAppMode!=="LIVING_ROOM_APP_MODE_UNSPECIFIED"&&(v.clram=XUD[P.livingRoomAppMode]||P.livingRoomAppMode);P.Y?Bgu(P,v):(v.docid=P.videoId,v.referrer=P.referrer,v.ei=P.eventId,v.of=P.CG,v.osid=P.osid,v.vm=P.videoMetadata,P.adQueryId&&(v.aqi=P.adQueryId),P.autonav&&(v.autonav="1"),P.playlistId&&(v.list=P.playlistId),P.HU&&(v.ssrt="1"),P.dJ&&(v.upt=P.dJ));P.G&&(P.embedsRct&&(v.rct=P.embedsRct),P.embedsRctn&&(v.rctn= P.embedsRctn),P.compositeLiveIngestionOffsetToken&&(v.clio=P.compositeLiveIngestionOffsetToken));P.Pg&&(v.host_cpn=P.Pg);return v}; Bgu=function(P,v){if(v&&P.Y){var l=new Set(["q","feature","mos"]),e=new Set("autoplay cl len fexp delay el ns adformat".split(" ")),h=new Set(["aqi","autonav","list","ssrt","upt"]);P.Y.ns==="3pp"&&(v.ns="3pp");for(var z=g.N(Object.keys(P.Y)),m=z.next();!m.done;m=z.next())m=m.value,e.has(m)||l.has(m)||h.has(m)&&!P.Y[m]||(v[m]=P.Y[m])}}; at=function(P,v){return g.LC(v,P.K).join(",")}; LMy=function(P){P.indexOf("watchtime")!==-1&&g.$6("gelDebuggingEvent",{vss3debuggingEvent:{vss2Ping:P}})}; iDD=function(P,v){P.attestationResponse&&xKB(P).then(function(l){l=l||{};l.method="POST";l.postParams={atr:P.attestationResponse};P.T1?P.kf?eg().sendAndWrite(v,l):eg().sendThenWrite(v,l):g.SN(v,l)})}; HR=function(P){g.U.call(this);this.provider=P;this.T="paused";this.Z=NaN;this.j=[10,10,10,40];this.X=this.S=0;this.QW=this.T1=this.J5=this.Wg=this.G=!1;this.K=this.Y=NaN;this.W=new qHB(P)}; a$P=function(P){if(!P.G){P.provider.videoData.rL===16623&&g.j4(Error("Playback for EmbedPage"));var v=EG(P,"playback");a:{if(P.provider.O$.V("web_player_use_server_vss_schedule")){var l,e=(l=P.provider.videoData.getPlayerResponse())==null?void 0:l.playbackTracking,h=e==null?void 0:e.videostatsScheduledFlushWalltimeSeconds;e=e==null?void 0:e.videostatsDefaultFlushIntervalSeconds;if(h&&h.length>0&&e){l=[];var z=P.provider.videoData.l3,m=P.provider.videoData.Z2,Q=-z;h=g.N(h);for(var t=h.next();!t.done;t= h.next())t=t.value,l.push(t-Q),Q=t;l.push(e+m-z);l.push(e);P.j=l;break a}}P.j=[10+P.provider.videoData.l3,10,10,40+P.provider.videoData.Z2-P.provider.videoData.l3,40]}As9(P.W);v.j=WR(P);P.K>0&&(v.W-=P.K);v.send();P.provider.videoData.E6&&(v=P.provider.O$,e=P.provider.videoData,l={html5:"1",video_id:e.videoId,cpn:e.clientPlaybackNonce,ei:e.eventId,ptk:e.E6,oid:e.tM,ptchn:e.EV,pltype:e.HQ,content_v:OD(e)},e.D2&&Object.assign(l,{m:e.D2}),v=g.r5(v.J5+"ptracking",l),UKD(P,v));P.provider.videoData.TG|| (ZD6(P),jzw(P),P.Ww());P.G=!0;v=P.W;v.W=v.provider.M5.xv();v.LO=g.b7(v.provider);!(v.G===0&&v.W<5)&&v.W-v.G>2&&(v.G=v.W);v.j=!0;P.provider.O$.V("html5_log_vss_details")&&P.provider.M5.f0("vssinit",{})}}; WR=function(P,v){v=v===void 0?NaN:v;var l=g.b7(P.provider);v=isNaN(v)?l:v;v=Math.ceil(v);var e=P.j[P.S];P.S+1 1E3;!(z.length>1)&&z[0].isEmpty()||Q||(m.j=WR(P,h));m.send();P.X++}},(h-l)*1E3); return P.Y=h}; OG=function(P){g.qc(P.Z);P.Z=NaN}; HD2=function(P){P.W.update();P=P.W;P.segments.length&&P.W===P.G||jh(P);var v=P.segments;P.segments=[];return v}; EG=function(P,v){var l=WMw(P.provider);Object.assign(l,{state:P.T});v=new bD7(P.provider.videoData,P.provider.O$,v,l);v.W=P.provider.M5.xv();l=P.provider.videoData.clientPlaybackNonce;v.W=P.provider.M5.Fm(l);P.provider.videoData.isLivePlayback||(v.wM=P.provider.M5.getDuration(l));P.provider.videoData.W&&(l=P.provider.videoData.W.lC(v.W))&&(v.It=l-v.W);v.MV=g.b7(P.provider);v.segments=[ZQ(P.provider)];return v}; EP7=function(P,v){var l=EG(P,"watchtime");ODD(P)&&(l.delayThresholdMet=!0,P.J5=!0);if(P.K>0){for(var e=g.N(v),h=e.next();!h.done;h=e.next())h=h.value,h.startTime-=P.K,h.endTime-=P.K;l.W-=P.K}else l.W=P.W.QF();l.segments=v;return l}; ot=function(P,v){var l=oPw(P,!isNaN(P.Y));v&&(P.Y=NaN);return l}; oPw=function(P,v){var l=EP7(P,HD2(P));!isNaN(P.Y)&&v&&(l.X=P.Y);return l}; ODD=function(P){var v;if(v=P.provider.videoData.isLoaded()&&P.provider.videoData.TG&&P.G&&!P.J5)v=P.W,v=v.Z+v.provider.M5.xv()-v.G>=P.provider.videoData.TG;return!!v}; ZD6=function(P){P.provider.videoData.youtubeRemarketingUrl&&!P.T1&&(UKD(P,P.provider.videoData.youtubeRemarketingUrl),P.T1=!0)}; jzw=function(P){P.provider.videoData.googleRemarketingUrl&&!P.QW&&(UKD(P,P.provider.videoData.googleRemarketingUrl),P.QW=!0)}; szD=function(P){P.provider.O$.V("html5_log_vss_details")&&P.provider.M5.f0("vssfi",{});if(!P.s$()&&P.G){P.T="paused";var v=ot(P);v.isFinal=!0;v.send();P.dispose()}}; rsy=function(P,v){if(!P.s$())if(g.M(v.state,2)||g.M(v.state,512)){if(P.T="paused",g.NQ(v,2)||g.NQ(v,512))g.NQ(v,2)&&(P.W.previouslyEnded=!0),P.G&&(OG(P),ot(P).send(),P.Y=NaN)}else if(g.M(v.state,8)){P.T="playing";var l=P.G&&isNaN(P.Z)?WR(P):NaN;!isNaN(l)&&(n2(v,64)<0||n2(v,512)<0)&&(P=oPw(P,!1),P.j=l,P.send())}else P.T="paused"}; MA6=function(P,v,l){if(!P.Wg){l||(l=EG(P,"atr"));l.attestationResponse=v;try{l.send()}catch(e){if(e.message!=="Unknown Error")throw e;}P.Wg=!0}}; UKD=function(P,v){var l=P.provider.O$;g.QW(P.provider.O$,g.MA(P.provider.videoData)).then(function(e){var h=P.provider.O$.pageId,z=P.provider.O$.sendVisitorIdHeader?P.provider.videoData.visitorData:void 0,m=P.provider.O$.V("vss_pings_using_networkless")||P.provider.O$.V("kevlar_woffle"),Q=P.provider.O$.V("allow_skip_networkless");e=erB(v,l,h,z,e);hra(v,e,{token:P.provider.videoData.T,f4:P.provider.videoData.R3,mdxEnvironment:P.provider.videoData.mdxEnvironment},l,void 0,m&&!Q,!1,!0)})}; Tgq=function(){this.endTime=this.startTime=-1;this.Z="-";this.playbackRate=1;this.visibilityState=0;this.Y="";this.K=0;this.compositeLiveStatusToken=this.G=void 0;this.volume=this.connectionType=0;this.muted=!1;this.W=this.clipId="-";this.previouslyEnded=!1}; sG=function(P,v,l){this.videoData=P;this.O$=v;this.M5=l;this.W=void 0}; g.b7=function(P){return VAD(P)()}; VAD=function(P){if(!P.W){var v=g.TW(function(e){var h=(0,g.Gz)();e&&h<=631152E6&&(P.M5.f0("ytnerror",{issue:28799967,value:""+h}),h=(new Date).getTime()+2);return h},P.O$.V("html5_validate_yt_now")),l=v(); P.W=function(){return Math.round(v()-l)/1E3}; P.M5.Di()}return P.W}; WMw=function(P){var v=P.M5.V8()||{};v.fs=P.M5.fO();v.volume=P.M5.getVolume();v.muted=P.M5.isMuted()?1:0;v.mos=v.muted;v.clipid=P.M5.FI();var l;v.playerheight=((l=P.M5.getPlayerSize())==null?void 0:l.height)||0;var e;v.playerwidth=((e=P.M5.getPlayerSize())==null?void 0:e.width)||0;P=P.videoData;l={};P.K&&(l.fmt=P.K.itag,P.Y&&(P.aV?P.Y.itag!==P.K.itag:P.Y.itag!=P.K.itag)&&(l.afmt=P.Y.itag));l.ei=P.eventId;l.list=P.playlistId;l.cpn=P.clientPlaybackNonce;P.videoId&&(l.v=P.videoId);P.xt&&(l.infringe=1); (P.Ro?0:P.XE)&&(l.splay=1);(e=FV(P))&&(l.live=e);P.Nf&&(l.sautoplay=1);P.tq&&(l.autoplay=1);P.AK&&(l.sdetail=P.AK);P.partnerId&&(l.partnerid=P.partnerId);P.osid&&(l.osid=P.osid);P.e0&&(l.cc=g.YwP(P.e0));return Object.assign(v,l)}; kKD=function(P){var v=gUu();if(v)return dKW[v]||dKW.other;if(g.pF(P.O$)){P=navigator.userAgent;if(/[Ww]ireless[)]/.test(P))return 3;if(/[Ww]ired[)]/.test(P))return 30}return 0}; ZQ=function(P){var v=new Tgq,l;v.Z=((l=WMw(P).cc)==null?void 0:l.toString())||"-";v.playbackRate=P.M5.getPlaybackRate();l=P.M5.getVisibilityState();l!==0&&(v.visibilityState=l);P.O$.nI&&(v.K=1);v.G=P.videoData.G5;v.compositeLiveStatusToken=P.videoData.compositeLiveStatusToken;l=P.M5.getAudioTrack();l.Rt&&l.Rt.id&&l.Rt.id!=="und"&&(v.Y=l.Rt.id);v.connectionType=kKD(P);v.volume=P.M5.getVolume();v.muted=P.M5.isMuted();v.clipId=P.M5.FI()||"-";v.W=P.videoData.bd||"-";return v}; g.rT=function(P,v){g.U.call(this);var l=this;this.provider=P;this.Y=!1;this.G=new Map;this.Ak=new g.mQ;this.Kh={vLc:function(){return l.qoe}, NWJ:function(){return l.W}, cP1:function(){return l.K}}; this.provider.videoData.n6()&&!this.provider.videoData.d4&&(this.W=new HR(this.provider),this.W.K=this.provider.videoData.SN/1E3,g.Z(this,this.W),this.qoe=new g.G5(this.provider,v),g.Z(this,this.qoe),this.provider.videoData.enableServerStitchedDai&&(this.qo=this.provider.videoData.clientPlaybackNonce)&&this.G.set(this.qo,this.W));if(P.O$.playerCanaryState==="canary"||P.O$.playerCanaryState==="holdback")this.K=new Yc(this.provider),g.Z(this,this.K)}; P7y=function(P){return!!P.W&&!!P.qoe}; M5=function(P){P.K&&obD(P.K);P.qoe&&KMy(P.qoe)}; vcD=function(P){if(P.qoe){P=P.qoe;for(var v=P.provider.videoData,l=P.provider.O$,e=g.N(l.lE),h=e.next();!h.done;h=e.next())BR(P,h.value);if(P.provider.V("html5_enable_qoe_cat_list"))for(e=g.N(v.Bw),h=e.next();!h.done;h=e.next())BR(P,h.value);else v.lE&&BR(P,P.provider.videoData.lE);v.Ei()&&(e=v.W,$M(v)&&BR(P,"manifestless"),e&&cj(e)&&BR(P,"live-segment-"+cj(e).toFixed(1)));yi(v)?BR(P,"sabr"):P.p9(nj(v));if(T6(v)||v.DR())v.DR()&&BR(P,"ssa"),BR(P,"lifa");v.gatewayExperimentGroup&&(e=v.gatewayExperimentGroup, e==="EXPERIMENT_GROUP_SPIKY_AD_BREAK_EXPERIMENT"?e="spkadtrt":e==="EXPERIMENT_GROUP_SPIKY_AD_BREAK_CONTROL"&&(e="spkadctrl"),BR(P,e));l.Wg!=="yt"&&(P.W.len=[v.lengthSeconds.toFixed(2)]);v.cotn&&!dw(v)&&P.gF(!0);l.vK()&&(v=CSw())&&P.f0("cblt",{m:v});if(l.V("html5_log_screen_diagonal")){l=P.f0;var z;v=((z=window.H5vccScreen)==null?0:z.GetDiagonal)?window.H5vccScreen.GetDiagonal():0;l.call(P,"cbltdiag",{v:v})}}}; lQ2=function(P){if(P.provider.M5.A3()){if(P.Y)return;P.Y=!0}P.W&&a$P(P.W);if(P.K){P=P.K;var v=g.b7(P.provider);P.W<0&&(P.W=v,P.delay.start());P.K=v;P.Y=v}}; eua=function(P,v){P.W&&(P=P.W,v===58?P.W.update():P.G&&(OG(P),ot(P).send(),P.Y=NaN))}; huy=function(P,v){if(g.NQ(v,1024)||g.NQ(v,512)||g.NQ(v,4)){if(P.K){var l=P.K;l.K>=0||(l.W=-1,l.delay.stop())}P.qoe&&(l=P.qoe,l.S||(l.K=-1))}if(P.provider.videoData.enableServerStitchedDai&&P.qo){var e;(e=P.G.get(P.qo))==null||rsy(e,v)}else P.W&&rsy(P.W,v);if(P.qoe){e=P.qoe;l=v.state;var h=g.b7(e.provider),z=e.getPlayerState(l);csu(e,h,z,l.seekSource||void 0);z=l.xF;g.M(l,128)&&z&&(z.Sz=z.Sz||"",nP9(e,h,z.errorCode,z.Nu,z.Sz));(g.M(l,2)||g.M(l,128))&&e.reportStats(h);l.isPlaying()&&!e.S&&(e.K>=0&& (e.W.user_intent=[e.K.toString()]),e.S=!0);I$y(e)}P.K&&(e=P.K,scw(e),e.playerState=v.state,e.K>=0&&g.NQ(v,16)&&e.seekCount++,v.state.isError()&&e.send());P.provider.M5.A3()&&(P.Ak=v.state)}; zuD=function(P){if(P.provider.videoData.enableServerStitchedDai&&P.qo){var v;(v=P.G.get(P.qo))!=null&&jh(v.W)}else P.W&&jh(P.W.W)}; m5w=function(P){P.K&&P.K.send();if(P.qoe){var v=P.qoe;if(v.G){v.Ak==="PL"&&(v.Ak="N");var l=g.b7(v.provider);g.Sh(v,l,"vps",[v.Ak]);v.S||(v.K>=0&&(v.W.user_intent=[v.K.toString()]),v.S=!0);v.provider.O$.vK()&&v.f0("finalized",{});v.kf=!0;v.reportStats(l)}}if(P.provider.videoData.enableServerStitchedDai)for(v=g.N(P.G.values()),l=v.next();!l.done;l=v.next())szD(l.value);else P.W&&szD(P.W);P.dispose()}; Rux=function(P,v){P.W&&MA6(P.W,v)}; QtW=function(P){if(!P.W)return null;var v=EG(P.W,"atr");return function(l){P.W&&MA6(P.W,l,v)}}; th6=function(P,v,l,e){l.adFormat=l.CI;var h=v.M5;v=new HR(new sG(l,v.O$,{getDuration:function(){return l.lengthSeconds}, getCurrentTime:function(){return h.getCurrentTime()}, xv:function(){return h.xv()}, Fm:function(){return h.Fm()}, A3:function(){return h.A3()}, rC:function(){return h.rC()}, getPlayerSize:function(){return h.getPlayerSize()}, getAudioTrack:function(){return l.getAudioTrack()}, getPlaybackRate:function(){return h.getPlaybackRate()}, qe:function(){return h.qe()}, getVisibilityState:function(){return h.getVisibilityState()}, w7:function(){return h.w7()}, V8:function(){return h.V8()}, getVolume:function(){return h.getVolume()}, isMuted:function(){return h.isMuted()}, fO:function(){return h.fO()}, FI:function(){return h.FI()}, getProximaLatencyPreference:function(){return h.getProximaLatencyPreference()}, Di:function(){h.Di()}, f0:function(z,m){h.f0(z,m)}, iy:function(){return h.iy()}})); v.K=e;g.Z(P,v);return v}; ygy=function(){this.MX=0;this.G=this.d2=this.xE=this.K=NaN;this.W={};this.bandwidthEstimate=NaN}; T5=function(P,v,l){g.U.call(this);var e=this;this.O$=P;this.M5=v;this.K=l;this.W=new Map;this.qo="";this.Kh={t6:function(){return Array.from(e.W.keys())}}}; C76=function(P,v){P.W.has(v)&&(m5w(P.W.get(v)),P.W.delete(v))}; fQ2=function(){this.W=g.yL;this.array=[]}; k5w=function(P,v,l){var e=[];for(v=gcx(P,v);v l)break}return e}; wR6=function(P,v){var l=[];P=g.N(P.array);for(var e=P.next();!e.done&&!(e=e.value,e.contains(v)&&l.push(e),e.start>v);e=P.next());return l}; $5u=function(P){return P.array.slice(gcx(P,0x7ffffffffffff),P.array.length)}; gcx=function(P,v){P=Qv(P.array,function(l){return v-l.start||1}); return P<0?-(P+1):P}; IQB=function(P,v){var l=NaN;P=g.N(P.array);for(var e=P.next();!e.done;e=P.next())if(e=e.value,e.contains(v)&&(isNaN(l)||e.end v&&(isNaN(l)||e.start P.mediaTime+P.Z&&v 1)P.Y=!0;if((h===void 0?0:h)||isNaN(P.K))P.K=v;if(P.W)v!==P.mediaTime&&(P.W=!1);else if(v>0&&P.mediaTime===v){h=1500;if(P.O$.V("html5_buffer_underrun_transition_fix")){h=g.ID(P.O$.experiments,"html5_min_playback_advance_for_steady_state_secs");var z=g.ID(P.O$.experiments,"html5_min_underrun_buffered_pre_steady_state_ms");h=h>0&&z>0&&Math.abs(v-P.K) (e||!P.Y?h:400)}P.mediaTime=v;P.G=l;return!1}; K$w=function(P,v){this.videoData=P;this.W=v}; cg2=function(P,v,l){return v.Fz(l).then(function(){return jN(new K$w(v,v.G))},function(e){e instanceof Error&&g.j4(e); var h=Ga('video/mp4; codecs="avc1.42001E, mp4a.40.2"'),z=Bz('audio/mp4; codecs="mp4a.40.2"'),m=h||z,Q=v.isLivePlayback&&!g.Rw(P.Z,!0);e="fmt.noneavailable";Q?e="html5.unsupportedlive":m||(e="html5.missingapi");m=Q||!m?2:1;h={buildRej:"1",a:v.l2(),d:!!v.zK,drm:v.d7(),f18:v.FL.indexOf("itag=18")>=0,c18:h};v.W&&(v.d7()?(h.f142=!!v.W.W["142"],h.f149=!!v.W.W["149"],h.f279=!!v.W.W["279"]):(h.f133=!!v.W.W["133"],h.f140=!!v.W.W["140"],h.f242=!!v.W.W["242"]),h.cAAC=z,h.cAVC=Bz('video/mp4; codecs="avc1.42001E"'), h.cVP9=Bz('video/webm; codecs="vp9"'));v.Z&&(h.drmsys=v.Z.keySystem,z=0,v.Z.W&&(z=Object.keys(v.Z.W).length),h.drmst=z);return new xq(e,h,m)})}; vC=function(P){this.data=window.Float32Array?new Float32Array(P):Array(P);this.K=this.W=P-1}; qG9=function(P){return P.data[P.W]||0}; F$D=function(P){this.Z=P;this.G=this.K=0;this.Y=new vC(50)}; eW=function(P,v,l){g.gA.call(this);this.videoData=P;this.experiments=v;this.T=l;this.K=[];this.Y=0;this.G=!0;this.Z=!1;this.j=0;l=new Ag7;P.latencyClass==="ULTRALOW"&&(l.Y=!1);P.U$?l.K=3:g.pj(P)&&(l.K=2);P.latencyClass==="NORMAL"&&(l.T=!0);var e=g.ID(v,"html5_liveness_drift_proxima_override");if(nj(P)!==0&&e){l.W=e;var h;((h=P.W)==null?0:Ya9(h))&&l.W--}yi(P)&&v.l$("html5_sabr_parse_live_metadata_playback_boundaries")&&(l.X=!0);if(g.Mc("trident/")||g.Mc("edge/"))h=g.ID(v,"html5_platform_minimum_readahead_seconds")|| 3,l.G=Math.max(l.G,h);g.ID(v,"html5_minimum_readahead_seconds")&&(l.G=g.ID(v,"html5_minimum_readahead_seconds"));g.ID(v,"html5_maximum_readahead_seconds")&&(l.S=g.ID(v,"html5_maximum_readahead_seconds"));v.l$("html5_force_adaptive_readahead")&&(l.Y=!0);if(h=g.ID(v,"html5_liveness_drift_chunk_override"))l.W=h;Ih(P)&&(l.W=(l.W+1)/5,P.latencyClass==="LOW"&&(l.W*=2));if(P.latencyClass==="ULTRALOW"||P.latencyClass==="LOW")l.Z=g.ID(v,"html5_low_latency_adaptive_liveness_adjustment_segments")||1,l.j=g.ID(v, "html5_low_latency_max_allowable_liveness_drift_chunks")||10;this.policy=l;this.S=this.policy.K!==1;this.W=lj(this,YGa(this,isNaN(P.liveChunkReadahead)?3:P.liveChunkReadahead,P))}; bfD=function(P,v){if(v)return v=P.videoData,v=YGa(P,isNaN(v.liveChunkReadahead)?3:v.liveChunkReadahead,v),lj(P,v);if(P.K.length){if(Math.min.apply(null,P.K)>1)return lj(P,P.W-1);if(P.policy.Y)return lj(P,P.W+1)}return P.W}; x5u=function(P,v){if(!P.K.length)return!1;var l=P.W;P.W=bfD(P,v===void 0?!1:v);if(v=l!==P.W)P.K=[],P.Y=0;return v}; h2=function(P,v){return v>=P.Gr()-pRx(P)}; L$a=function(P,v,l){v=h2(P,v);l||v?v&&(P.G=!0):P.G=!1;P.S=P.policy.K===2||P.policy.K===3&&P.G}; SGB=function(P,v){v=h2(P,v);P.Z!==v&&P.publish("livestatusshift",v);P.Z=v}; pRx=function(P){var v=P.policy.W;P.Z||(v=Math.max(v-1,0));return v*zd(P)}; YGa=function(P,v,l){l.U$&&v--;Ih(l)&&(v=1);if(nj(l)!==0&&(P=g.ID(P.experiments,"html5_live_chunk_readahead_proxima_override"))){v=P;var e;((e=l.W)==null?0:Ya9(e))&&v++}return v}; zd=function(P){return P.videoData.W?cj(P.videoData.W)||5:5}; lj=function(P,v){v=Math.max(Math.max(1,Math.ceil(P.policy.G/zd(P))),v);return Math.min(Math.min(8,Math.floor(P.policy.S/zd(P))),v)}; Ag7=function(){this.G=0;this.S=Infinity;this.Y=!0;this.W=2;this.K=1;this.T=!1;this.j=10;this.X=!1;this.Z=1}; Q_=function(P){g.U.call(this);this.M5=P;this.W=0;this.K=null;this.T=this.Y=0;this.G={};this.O$=this.M5.N();this.Z=new g.mr(this.p6,1E3,this);this.U$=new mC({delayMs:g.ID(this.O$.experiments,"html5_seek_timeout_delay_ms")});this.kf=new mC({delayMs:g.ID(this.O$.experiments,"html5_long_rebuffer_threshold_ms")});this.Bg=RB(this,"html5_seek_set_cmt");this.q5=RB(this,"html5_seek_jiggle_cmt");this.h5=RB(this,"html5_seek_new_elem");this.It=RB(this,"html5_unreported_seek_reseek");this.J5=RB(this,"html5_long_rebuffer_jiggle_cmt"); this.wM=RB(this,"html5_long_rebuffer_ssap_clip_not_match");this.T1=new mC({delayMs:2E4});this.Ic=RB(this,"html5_seek_new_elem_shorts");this.D3=RB(this,"html5_seek_new_media_source_shorts_reuse");this.A5=RB(this,"html5_seek_new_media_element_shorts_reuse");this.Pg=RB(this,"html5_reseek_after_time_jump");this.S=RB(this,"html5_gapless_handoff_close_end_long_rebuffer");this.Wg=RB(this,"html5_gapless_slow_seek");this.X=RB(this,"html5_gapless_slice_append_stuck");this.QW=RB(this,"html5_gapless_slow_start"); this.j=RB(this,"html5_ads_preroll_lock_timeout");this.jS=RB(this,"html5_ssap_ad_longrebuffer_new_element");this.nI=new mC({delayMs:g.ID(this.O$.experiments,"html5_skip_slow_ad_delay_ms")||5E3,hJ:!this.O$.V("html5_report_slow_ads_as_error")});this.WK=new mC({delayMs:g.ID(this.O$.experiments,"html5_skip_slow_ad_delay_ms")||5E3,hJ:!this.O$.V("html5_skip_slow_buffering_ad")});this.TG=new mC({delayMs:g.ID(this.O$.experiments,"html5_slow_start_timeout_delay_ms")});this.Hg=RB(this,"html5_slow_start_no_media_source"); g.Z(this,this.Z)}; RB=function(P,v){var l=g.ID(P.O$.experiments,v+"_delay_ms");P=P.O$.V(v+"_cfl");return new mC({delayMs:l,hJ:P})}; G52=function(P,v){P.W=v}; t2=function(P,v,l,e,h,z,m,Q){v.test(l)?(P.x_(h,v,m),v.hJ||z()):(v.Qz&&v.K&&!v.Y?(l=(0,g.Gz)(),e?v.W||(v.W=l):v.W=0,z=!e&&l-v.K>v.Qz,l=v.W&&l-v.W>v.Aj||z?v.Y=!0:!1):l=!1,l&&(Q=Object.assign({},P.Ui(v),Q),Q.wn=m,Q.we=h,Q.wsuc=e,P.M5.f0("workaroundReport",Q),e&&(v.reset(),P.G[h]=!1)))}; mC=function(P){var v=P===void 0?{}:P;P=v.delayMs===void 0?0:v.delayMs;var l=v.Aj===void 0?1E3:v.Aj;var e=v.Qz===void 0?3E4:v.Qz;v=v.hJ===void 0?!1:v.hJ;this.W=this.K=this.G=this.startTimestamp=0;this.Y=!1;this.Z=Math.ceil(P/1E3);this.Aj=l;this.Qz=e;this.hJ=v}; U5w=function(P){g.U.call(this);var v=this;this.M5=P;this.T=this.W=this.K0=this.mediaElement=this.playbackData=null;this.Y=0;this.Z=this.Wg=this.G=null;this.QW=!1;this.nI=0;this.S=!1;this.timestampOffset=0;this.j=!0;this.q5=0;this.h5=this.TG=!1;this.X=0;this.D3=!1;this.J5=0;this.O$=this.M5.N();this.videoData=this.M5.getVideoData();this.policy=new XRD;this.T1=new Q_(this.M5);this.U$=this.Pg=this.Hg=this.K=NaN;this.wM=new g.mr(function(){BTx(v,!1)},2E3); this.WK=new g.mr(function(){y_(v)}); this.Ic=new g.mr(function(){v.QW=!0;if7(v,{})}); this.Bg=NaN;this.kf=new g.mr(function(){var l=v.O$.t3;l.W+=1E4/36E5;l.W-l.G>1/6&&(jVB(l),l.G=l.W);v.kf.start()},1E4); g.Z(this,this.T1);g.Z(this,this.wM);g.Z(this,this.Ic);g.Z(this,this.WK);g.Z(this,this.kf)}; aQD=function(P,v){P.playbackData=v;P.videoData.isLivePlayback&&(P.T=new F$D(function(){a:{if(P.playbackData&&P.playbackData.W.W){if($M(P.videoData)&&P.K0){var l=P.K0.Eu.y_()||0;break a}if(P.videoData.W){l=P.videoData.W.T1;break a}}l=0}return l}),P.W=new eW(P.videoData,P.O$.experiments,function(){return P.Jk(!0)})); CZ(P.M5)?(v=Zfy(P),v.fF?(P.V("html5_sabr_enable_utc_seek_requests")&&yi(P.videoData)&&P.b_(v.fF,v.startSeconds),P.Y=v.startSeconds):v.startSeconds>0&&P.seekTo(v.startSeconds,{mD:"seektimeline_startPlayback",seekSource:15}),P.j=!1):jtP(P)||(P.Y=P.Y||(g.VW(P.videoData)?0:P.videoData.startSeconds)||0)}; Ec6=function(P,v){(P.K0=v)?HfD(P,!0):fZ(P)}; W$w=function(P,v){g.RX(P.T1.Z);P.V("html5_exponential_memory_for_sticky")&&(v.state.isPlaying()?g.RX(P.kf):P.kf.stop());if(P.mediaElement)if(v.oldState.state===8&&gZ(v.state)&&v.state.isBuffering()){v=P.mediaElement.getCurrentTime();var l=P.mediaElement.AB();var e=P.V("manifestless_post_live_ufph")||P.V("manifestless_post_live")?yu(l,Math.max(v-3.5,0)):yu(l,v-3.5);e>=0&&v>l.end(e)-1.1&&e+1 0?(gS(P.M5,P.getCurrentTime()+P.videoData.limitedPlaybackDurationInSeconds),P.h5=!0):P.videoData.isLivePlayback&&P.videoData.endSeconds>0&&(gS(P.M5,P.getCurrentTime()+P.videoData.endSeconds),P.h5=!0))}; oc9=function(P,v){var l=P.getCurrentTime(),e=P.isAtLiveHead(l);if(P.T&&e){var h=P.T;if(h.W&&!(l>=h.K&&l 50&&h.K.shift())),h=P.W,L$a(h,l,v===void 0?!0:v),SGB(h,l),v&&BTx(P,!0));e!==P.TG&&(v=P.getCurrentTime()-P.U$<=500,l=P.nI>=1E3,v||l||(v=P.M5.uQ(),v.qoe&&(v=v.qoe,l=g.b7(v.provider), g.Sh(v,l,"lh",[e?"1":"0"])),P.TG=e,P.nI++,P.U$=P.getCurrentTime()))}; BTx=function(P,v){if(P.W){var l=P.W;var e=P.getCurrentTime();!h2(l,e)&&l.QH()?(l.policy.T&&(l.policy.W=Math.max(l.policy.W+l.policy.Z,l.policy.j)),l=Infinity):l=e 0&&lm(P.mediaElement)>0&&(P.K=kx(P,P.K,!1)),!P.mediaElement||!Vh9(P))P.WK.start(750);else if(!isNaN(P.K)&&isFinite(P.K)){var v=P.Pg-(P.K-P.timestampOffset);if(!(v===0||P.V("html5_enable_new_seek_timeline_logic")&&Math.abs(v)<.005))if(v=P.mediaElement.getCurrentTime()-P.K,Math.abs(v)<=P.q5||P.V("html5_enable_new_seek_timeline_logic")&&Math.abs(v)<.005)P.G&&P.G.resolve(P.mediaElement.getCurrentTime()); else{if(P.videoData.S0)P.videoData.S0=!1;else if(!ww(P.videoData)&&P.K>=P.Jk()-.1){P.K=P.Jk();P.G.resolve(P.Jk());P.M5.mR();return}try{var l=P.K-P.timestampOffset;P.mediaElement.seekTo(l);P.T1.W=l;P.Pg=l;P.Y=P.K;P.V("html5_enable_new_seek_timeline_logic")&&(P.S=!1)}catch(e){}}}}; Vh9=function(P){if(!P.mediaElement||P.mediaElement.lY()===0||P.mediaElement.hasError())return!1;var v=P.mediaElement.getCurrentTime()>0;if(!(P.videoData.G&&P.videoData.G.W||P.videoData.isLivePlayback)&&P.videoData.d7())return v;if(P.K>=0){var l=P.mediaElement.Ju();if(l.length||!v)return C0(l,P.K-P.timestampOffset)}return v}; TTu=function(P,v){P.Z&&(P.Z.resolve(v),P.M5.NS(),P.O$.vK()&&(v=P.Ui(),v["native"]=""+ +P.S,v.otgt=""+(P.K+P.timestampOffset),P.M5.f0("seekEnd",v)));fZ(P)}; fZ=function(P){P.K=NaN;P.Pg=NaN;P.G=null;P.Wg=null;P.Z=null;P.QW=!1;P.S=!1;P.q5=0;P.wM.stop();P.Ic.stop()}; vxD=function(P,v,l){var e=P.mediaElement,h=v.type;switch(h){case "seeking":var z=e.getCurrentTime()+P.timestampOffset;if(!P.G||P.S&&z!==P.K){var m=!!P.G;P.G=new PP;P.V("html5_enable_new_seek_timeline_logic")&&P.G.then(function(t){TTu(P,t)},function(){fZ(P)}); if(P.videoData.isAd()){var Q;lsx({adCpn:P.videoData.clientPlaybackNonce,contentCpn:(Q=P.videoData.u1)!=null?Q:""},v.W)}P.Pg=z;G52(P.T1,e.getCurrentTime());P.seekTo(z,{seekSource:104,mD:"seektimeline_mediaElementEvent"});l&&d5y(l,z*1E3,!!m);P.S=!0}break;case "seeked":P.G&&P.G.resolve(P.mediaElement.getCurrentTime());break;case "loadedmetadata":CZ(P.M5)||Pj9(P);y_(P);break;case "progress":y_(P);break;case "pause":P.X=P.getCurrentTime()}P.X&&((h==="play"||h==="playing"||h==="timeupdate"||h==="progress")&& P.getCurrentTime()-P.X>10&&(P.V("html5_enable_new_media_element_puase_jump")?(P.M5.x_(new xq("qoe.restart",{reason:"pauseJump"})),P.M5.hB()):P.seekTo(P.X,{mD:"pauseJump"})),h!=="pause"&&h!=="play"&&h!=="playing"&&h!=="progress"&&(P.X=0))}; lgW=function(P){return(Lj(P.videoData)||!!P.videoData.liveUtcStartSeconds)&&(!!P.videoData.liveUtcStartSeconds||jtP(P))&&!!P.videoData.W}; jtP=function(P){return!!P.videoData.startSeconds&&isFinite(P.videoData.startSeconds)&&P.videoData.startSeconds>1E9}; Zfy=function(P){var v=0,l=NaN,e="";if(!P.j)return{startSeconds:v,fF:l,source:e};P.videoData.wM?v=P.videoData.Hg:ww(P.videoData)&&(v=Infinity);if(g.pj(P.videoData))return{startSeconds:v,fF:l,source:e};P.videoData.startSeconds?(e="ss",v=P.videoData.startSeconds):P.videoData.GP&&(e="stss",v=P.videoData.GP);P.videoData.liveUtcStartSeconds&&(l=P.videoData.liveUtcStartSeconds);if(isFinite(v)&&(v>P.Jk()||v P.Jk()||l 0?(e.onesie="0",P.handleError(new xq("html5.missingapi",e)),!1):!0}; Cja=function(P){var v=a0();HS(v,P);return g.yn(v,tya())}; QBu=function(P,v){var l,e,h,z,m,Q,t,y,C,f,k,w,I,J,K,q,A,x,S,B,E,r,hq,R7,Pw,H;return g.p(function(T){if(T.W==1)return v.fetchType="onesie",l=DzB(v,P.getPlayerSize(),P.getVisibilityState()),e=new vR(P,l),g.b(T,e.fetch(),2);h=T.K;z={player_response:h};v.loading=!1;m=P.jN.KE;if(e.WP){Q=g.N(e.WP.entries());for(t=Q.next();!t.done;t=Q.next())y=t.value,C=g.N(y),f=C.next().value,k=C.next().value,w=f,I=k,m.W.set(w,I,180),w===v.videoId&&(J=I.Vy(),v.lI=J);m.Xj=e}K=g.N(e.cH.entries());for(q=K.next();!q.done;q= K.next())A=q.value,x=g.N(A),S=x.next().value,B=x.next().value,E=S,r=B,m.K.set(E,r,180);g.Tk(v,z,!0);if(v.loading||rh(v))return T.return(Promise.resolve());m.W.removeAll();m.K.removeAll();v.lI=[];hq={};R7="onesie.response";Pw=0;v.errorCode?(R7="auth",hq.ec=v.errorCode,hq.ed=v.errorDetail,hq.es=v.ZH||"",Pw=2):(hq.successButUnplayable="1",hq.disposed=""+ +v.s$(),hq.afmts=""+ +/adaptiveFormats/.test(h),hq.cpn=v.clientPlaybackNonce);H=new xq(R7,hq,Pw);return T.return(Promise.reject(H))})}; mHB=function(P,v){var l,e,h,z,m,Q,t,y,C,f,k;return g.p(function(w){switch(w.W){case 1:l=v.isAd(),e=!l,h=l?1:3,z=0;case 2:if(!(z 0)){w.ac(5);break}return g.b(w,x9(5E3),6);case 6:m=new g.Ph("Retrying OnePlatform request",{attempt:z}),g.j4(m);case 5:return g.NP(w,7),g.b(w,fgw(P,v),9);case 9:return w.return();case 7:Q=g.Kx(w);t=LW(Q);y=t.errorCode;C=P.N();f=C.V("html5_use_network_error_code_enums")?401:"401";e&&y==="manifest.net.badstatus"&&t.details.rc===f&&(e=!1,z===h-1&&(h+= 1));if(z===h-1)return k=gxx(l,t.details),k.details.backend="op",k.details.originec=y,w.return(Promise.reject(k));if(y==="auth"||y==="manifest.net.retryexhausted")return w.return(Promise.reject(t));P.handleError(t);if(pW(t.severity)){w.ac(4);break}case 3:z++;w.ac(2);break;case 4:return w.return(Promise.reject(gxx(l,{backend:"op"})))}})}; fgw=function(P,v){function l(R7){R7.readyState===2&&P.g9("ps_c")} var e,h,z,m,Q,t,y,C,f,k,w,I,J,K,q,A,x,S,B,E,r,hq;return g.p(function(R7){switch(R7.W){case 1:v.fetchType="gp";e=P.N();h=g.QW(e,g.MA(v));if(!h.W){z=h.getValue();R7.ac(2);break}return g.b(R7,h.W,3);case 3:z=R7.K;case 2:return m=z,Q=Cja(m),t=DzB(v,P.getPlayerSize(),P.getVisibilityState()),y=g.$S(kd9),C=g.MA(v),f=(0,g.Gz)(),k=!1,w="empty",I=0,P.g9("psns"),J={zC:l},g.b(R7,g.d9(Q,t,y,void 0,J),4);case 4:K=R7.K;P.g9("psnr");if(v.s$())return R7.return();K?"error"in K&&K.error?(k=!0,w="esf:"+K.error.message, I=K.error.code):K.errorMetadata&&(k=!0,w="its",I=K.errorMetadata.status):k=!0;if(k)return q=0,A=((0,g.Gz)()-f).toFixed(),x={},x=e.V("html5_use_network_error_code_enums")?{backend:"op",rc:I,rt:A,reason:w,has_kpt:v.Bg?"1":"0",has_mdx_env:v.mdxEnvironment?"1":"0",has_omit_key_flag:g.la("INNERTUBE_OMIT_API_KEY_WHEN_AUTH_HEADER_IS_PRESENT")?"1":"0",has_page_id:e.pageId?"1":"0",has_token:C?"1":"0",has_vvt:v.QW?"1":"0",is_mdx:v.isMdxPlayback?"1":"0",mdx_ctrl:v.e_||"",token_eq:C===g.MA(v)?"1":"0"}:{backend:"op", rc:""+I,rt:A,reason:w,has_kpt:v.Bg?"1":"0",has_mdx_env:v.mdxEnvironment?"1":"0",has_omit_key_flag:g.la("INNERTUBE_OMIT_API_KEY_WHEN_AUTH_HEADER_IS_PRESENT")?"1":"0",has_page_id:e.pageId?"1":"0",has_token:C?"1":"0",has_vvt:v.QW?"1":"0",is_mdx:v.isMdxPlayback?"1":"0",mdx_ctrl:v.e_||"",token_eq:C===g.MA(v)?"1":"0"},S="manifest.net.connect",I===429?(S="auth",q=2):I>200&&(S="manifest.net.badstatus",I===400&&(q=2)),R7.return(Promise.reject(new xq(S,x,q)));v.loading=!1;g.Tk(v,{raw_player_response:K},!0); B=K;g.UM(v.N())&&B&&B.trackingParams&&L6(B.trackingParams);if(v.errorCode)return E={ec:v.errorCode,ed:v.errorDetail,es:v.ZH||""},R7.return(Promise.reject(new xq("auth",E,2)));if(!v.loading&&!rh(v))return r=v.isAd()?"auth":"manifest.net.retryexhausted",hq=v.isAd()?2:1,R7.return(Promise.reject(new xq(r,{successButUnplayable:"1",hasMedia:g.YM(v)?"1":"0"},hq)));g.nx(R7)}})}; z79=function(P,v,l){function e(I){I=LW(I);if(pW(I.severity))return Promise.reject(I);P.handleError(I);return!1} function h(){return!0} var z,m,Q,t,y,C,f,k,w;return g.p(function(I){switch(I.W){case 1:var J=P.N(),K=P.getPlayerSize(),q=P.getVisibilityState();P.isFullscreen();var A=window.location.search;if(v.partnerId===38&&J.playerStyle==="books")A=v.videoId.indexOf(":"),A=g.r5("//play.google.com/books/volumes/"+v.videoId.slice(0,A)+"/content/media",{aid:v.videoId.slice(A+1),sig:v.O8});else if(v.partnerId===30&&J.playerStyle==="docs")A=g.r5("https://docs.google.com/get_video_info",{docid:v.videoId,authuser:v.RI,authkey:v.Fe,eurl:J.D3}); else if(v.partnerId===33&&J.playerStyle==="google-live")A=g.r5("//google-liveplayer.appspot.com/get_video_info",{key:v.videoId});else{J.Wg!=="yt"&&g.Zx(Error("getVideoInfoUrl for invalid namespace: "+J.Wg));var x={html5:"1",video_id:v.videoId,cpn:v.clientPlaybackNonce,eurl:J.D3,ps:J.playerStyle,el:ZN(v),hl:J.TG,list:v.playlistId,agcid:v.f5,aqi:v.adQueryId,sts:20123,lact:Ly()};Object.assign(x,J.W);J.forcedExperiments&&(x.forced_experiments=J.forcedExperiments);v.QW?(x.vvt=v.QW,v.mdxEnvironment&&(x.mdx_environment= v.mdxEnvironment)):g.MA(v)&&(x.access_token=g.MA(v));v.adFormat&&(x.adformat=v.adFormat);v.slotPosition>=0&&(x.slot_pos=v.slotPosition);v.breakType&&(x.break_type=v.breakType);v.Hb!==null&&(x.ad_id=v.Hb);v.nV!==null&&(x.ad_sys=v.nV);v.fH!==null&&(x.encoded_ad_playback_context=v.fH);J.captionsLanguagePreference&&(x.cc_lang_pref=J.captionsLanguagePreference);J.WK&&J.WK!==2&&(x.cc_load_policy=J.WK);var S=g.rD(g.sY(),65);g.Po(J)&&S!=null&&!S&&(x.device_captions_on="1");J.mute&&(x.mute=J.mute);v.annotationsLoadPolicy&& J.annotationsLoadPolicy!==2&&(x.iv_load_policy=v.annotationsLoadPolicy);v.C1&&(x.endscreen_ad_tracking=v.C1);(S=J.Hg.get(v.videoId))&&S.iV&&(x.ic_track=S.iV);v.kf&&(x.itct=v.kf);rw(v)&&(x.autoplay="1");v.mutedAutoplay&&(x.mutedautoplay=v.mutedAutoplay);v.isAutonav&&(x.autonav="1");v.P4&&(x.noiba="1");v.isMdxPlayback&&(x.mdx="1",x.ytr=v.wY);v.mdxControlMode&&(x.mdx_control_mode=v.mdxControlMode);v.Jw&&(x.ytrcc=v.Jw);v.xP&&(x.utpsa="1");v.isFling&&(x.is_fling="1");v.isInlinePlaybackNoAd&&(x.mute="1"); v.vnd&&(x.vnd=v.vnd);v.forceAdsUrl&&(S=v.forceAdsUrl.split("|").length===3,x.force_ad_params=S?v.forceAdsUrl:"||"+v.forceAdsUrl);v.oV&&(x.preload=v.oV);K.width&&(x.width=K.width);K.height&&(x.height=K.height);(v.Ro?0:v.XE)&&(x.splay="1");v.ypcPreview&&(x.ypc_preview="1");OD(v)&&(x.content_v=OD(v));v.U$&&(x.livemonitor=1);J.T1&&(x.authuser=J.T1);J.pageId&&(x.pageid=J.pageId);J.A5&&(x.ei=J.A5);J.Y&&(x.iframe="1");v.contentCheckOk&&(x.cco="1");v.racyCheckOk&&(x.rco="1");J.j&&v.R4&&(x.live_start_walltime= v.R4);J.j&&v.eb&&(x.live_manifest_duration=v.eb);J.j&&v.playerParams&&(x.player_params=v.playerParams);J.j&&v.cycToken&&(x.cyc=v.cycToken);J.j&&v.Iy&&(x.tkn=v.Iy);q!==0&&(x.vis=q);J.enableSafetyMode&&(x.enable_safety_mode="1");v.Bg&&(x.kpt=v.Bg);v.au&&(x.kids_age_up_mode=v.au);v.kidsAppInfo&&(x.kids_app_info=v.kidsAppInfo);v.SZ&&(x.upg_content_filter_mode="1");J.widgetReferrer&&(x.widget_referrer=J.widgetReferrer.substring(0,128));v.Wg?(K=v.Wg.latitudeE7!=null&&v.Wg.longitudeE7!=null?v.Wg.latitudeE7+ ","+v.Wg.longitudeE7:",",K+=","+(v.Wg.clientPermissionState||0)+","+(v.Wg.locationRadiusMeters||"")+","+(v.Wg.locationOverrideToken||"")):K=null;K&&(x.uloc=K);v.UU&&(x.internalipoverride=v.UU);J.embedConfig&&(x.embed_config=J.embedConfig);J.l3&&(x.co_rel="1");J.ancestorOrigins.length>0&&(x.ancestor_origins=Array.from(J.ancestorOrigins).join(","));J.homeGroupInfo!==void 0&&(x.home_group_info=J.homeGroupInfo);J.livingRoomAppMode!==void 0&&(x.living_room_app_mode=J.livingRoomAppMode);J.enablePrivacyFilter&& (x.enable_privacy_filter="1");v.isLivingRoomDeeplink&&(x.is_living_room_deeplink="1");v.AX&&v.yd&&(x.clip=v.AX,x.clipt=v.yd);v.e9&&(x.disable_watch_next="1");v.SI&&(x.forced_by_var="1");for(var B in x)!wCq.has(B)&&x[B]&&String(x[B]).length>512&&(g.j4(Error("GVI param too long: "+B)),x[B]="");B=J.J5;g.ZY(J)&&(B=hn(B.replace(/\b(?:www|web)([.-])/,"tv$1"))||J.J5);J=g.r5(B+"get_video_info",x);A&&(J=Qjw(J,A));A=J}z=A;Q=(m=v.isAd())?1:3;t=0;case 2:if(!(t 0)){I.ac(5);break}return g.b(I, x9(5E3),6);case 6:C={playerretry:t,playerretrysrc:l},m||(C.recover="embedded"),y=kN(z,C);case 5:return g.b(I,$Hx(v,y).then(h,e),7);case 7:if(f=I.K)return I.return();t++;I.ac(2);break;case 4:k=m?"auth":"manifest.net.retryexhausted";w=m?2:1;if(!m&&Math.random()<1E-4)try{g.j4(new g.Ph("b/152131571",btoa(z)))}catch(E){}return I.return(Promise.reject(new xq(k,{backend:"gvi"},w)))}})}; $Hx=function(P,v){function l(K){return e(K.xhr)} function e(K){if(!P.s$()){K=K?K.status:-1;var q=0,A=((0,g.Gz)()-C).toFixed();A=h.V("html5_use_network_error_code_enums")?{backend:"gvi",rc:K,rt:A}:{backend:"gvi",rc:""+K,rt:A};var x="manifest.net.connect";K===429?(x="auth",q=2):K>200&&(x="manifest.net.badstatus",K===400&&(q=2));return Promise.reject(new xq(x,A,q))}} var h,z,m,Q,t,y,C,f,k,w,I,J;return g.p(function(K){if(K.W==1){P.fetchType="gvi";h=P.N();var q={};P.w1&&(q.ytrext=P.w1);(Q=g.pU(q)?void 0:q)?(z={format:"RAW",method:"POST",withCredentials:!0,timeout:3E4,postParams:Q},m=kN(v,{action_display_post:1})):(z={format:"RAW",method:"GET",withCredentials:!0,timeout:3E4},m=v);t={};h.sendVisitorIdHeader&&P.visitorData&&(t["X-Goog-Visitor-Id"]=P.visitorData);(y=eE(h.experiments,"debug_sherlog_username"))&&(t["X-Youtube-Sherlog-Username"]=y);Object.keys(t).length> 0&&(z.headers=t);C=(0,g.Gz)();return g.b(K,Cq(BM,m,z).then(void 0,l),2)}f=K.K;if(!f||!f.responseText)return K.return(e(f));P.loading=!1;k=yS(f.responseText);g.Tk(P,k,!0);if(P.errorCode)return w={ec:P.errorCode,ed:P.errorDetail,es:P.ZH||""},K.return(Promise.reject(new xq("auth",w,2)));if(!P.loading&&!rh(P))return I=P.isAd()?"auth":"manifest.net.retryexhausted",J=P.isAd()?2:1,K.return(Promise.reject(new xq(I,{successButUnplayable:"1"},J)));g.nx(K)})}; gxx=function(P,v){return new xq(P?"auth":"manifest.net.retryexhausted",v,P?2:1)}; nZ=function(P,v,l){l=l===void 0?!1:l;var e,h,z,m;g.p(function(Q){if(Q.W==1){e=P.N();if(l&&(!g.lN(e)||ZN(v)!=="embedded")||v.e9||ZN(v)!=="adunit"&&(g.pF(e)||OM(e)||g.H$(e)||g.ZY(e)||va(e)==="WEB_CREATOR"))return Q.return();h=g.QW(e,g.MA(v));return h.W?g.b(Q,h.W,3):(z=h.getValue(),Q.ac(2))}Q.W!=2&&(z=Q.K);m=z;return Q.return(IgB(P,v,m))})}; IgB=function(P,v,l){var e,h,z,m,Q;return g.p(function(t){if(t.W==1){g.NP(t,2);e=Cja(l);var y=v.N();g.sY();var C={context:g.QI(v),videoId:v.videoId,racyCheckOk:v.racyCheckOk,contentCheckOk:v.contentCheckOk,autonavState:"STATE_NONE"};ZN(v)==="adunit"&&(C.isAdPlayback=!0);y.embedConfig&&(C.serializedThirdPartyEmbedConfig=y.embedConfig);y.l3&&(C.showContentOwnerOnly=!0);v.rA&&(C.showShortsOnly=!0);g.rD(0,141)&&(C.autonavState=g.rD(0,140)?"STATE_OFF":"STATE_ON");if(g.Po(y)){var f=g.rD(0,65);f=f!=null? !f:!1;var k=!!g.au("yt-player-sticky-caption");C.captionsRequested=f&&k}var w;if(y=(w=y.getWebPlayerContextConfig())==null?void 0:w.encryptedHostFlags)C.playbackContext={encryptedHostFlags:y};h=C;z=g.$S(DHx);P.g9("wn_s");return g.b(t,g.d9(e,h,z),4)}if(t.W!=2)return m=t.K,P.g9("wn_r"),!m||"error"in m&&m.error||(Q=m,g.UM(v.N())&&Q.trackingParams&&L6(Q.trackingParams),g.Tk(v,{raw_watch_next_response:m},!1)),g.uD(t,0);g.Kx(t);g.nx(t)})}; nxP=function(P){P.g9("vir");P.g9("ps_s");Md("vir",void 0,"video_to_ad");var v=y2W(P);v.then(function(){P.g9("virc");Md("virc",void 0,"video_to_ad");P.g9("ps_r");Md("ps_r",void 0,"video_to_ad")},function(){P.g9("virc"); Md("virc",void 0,"video_to_ad")}); return v}; g.uj=function(P,v,l,e,h,z,m,Q,t,y){t=t===void 0?new g.oI(P):t;y=y===void 0?!0:y;g.gA.call(this);var C=this;this.O$=P;this.playerType=v;this.pI=l;this.LG=e;this.getVisibilityState=z;this.visibility=m;this.jN=Q;this.videoData=t;this.Es=y;this.logger=new g.Rf("VideoPlayer");this.LZ=new u1u(this.O$);this.qV=null;this.bJ=new Kf;this.cI=null;this.nw=new bLD(this.O$,this.LG,this);this.Kc=!0;this.u$=this.K0=null;this.zq=[];this.MJ=new Dg;this.Sg=this.Ux=null;this.Wo=new Dg;this.oi=null;this.k$=this.Cl=!1; this.qr=NaN;this.dK=!1;this.playerState=new g.mQ;this.At=[];this.uI=new g.Z1;this.OY=new $Jq(this);this.mediaElement=null;this.m1=new g.mr(this.zq$,15E3,this);this.M0=this.C5=!1;this.K9=NaN;this.NF=!1;this.E3=0;this.Ne=!1;this.QJ=NaN;this.N0=new wS(new Map([["bufferhealth",function(){return Ofx(C.k_)}], ["bandwidth",function(){return C.e8()}], ["networkactivity",function(){return C.O$.schedule.J5}], ["livelatency",function(){return C.isAtLiveHead()&&C.isPlaying()?NS6(C):NaN}], ["rawlivelatency",function(){return NS6(C)}]])); this.Yl=0;this.loop=!1;this.playbackRate=1;this.O4=0;this.k_=new U5w(this);this.Mp=!1;this.xO=[];this.jr=this.S$=0;this.F1=this.ML=!1;this.d2=this.xE=0;this.VS=-1;this.BQ="";this.MW=new g.mr(this.Ar,0,this);this.Q1=!1;this.gM=this.PR=null;this.md$=[this.uI,this.MW,this.m1,this.N0];this.xw=this.WG=null;this.Nv=function(){var f=C.uQ();f.provider.O$.Hl||f.provider.M5.getVisibilityState()===3||(f.provider.O$.Hl=!0);zuD(f);if(f.K){var k=f.K;k.Z&&k.W<0&&k.provider.M5.getVisibilityState()!==3&&obD(k)}f.qoe&& (f=f.qoe,f.h5&&f.K<0&&f.provider.O$.Hl&&KMy(f),f.G&&X1(f));C.K0&&NH(C);C.O$.KO&&!C.videoData.backgroundable&&C.mediaElement&&!C.KJ()&&(C.isBackground()&&C.mediaElement.Et()?(C.f0("bgmobile",{suspend:1}),C.jM(!0,!0)):C.isBackground()||J2(C)&&C.f0("bgmobile",{resume:1}))}; this.Kh={a7:function(f){C.a7(f)}, Xo1:function(f){C.qV=f}, zE1:function(){return C.Oj}, KN:function(){return C.M8}, fg:function(){return C.u$}, DH0:function(){return C.H7}, CR5:function(){return C.s3}, P7$:function(){}, N:function(){return C.O$}, ZR:function(){return C.mediaElement}, rm6:function(f){C.ai(f)}, eE5:function(){return C.LG}}; this.logger.debug(function(){return"creating, type "+v}); this.ih=new g.V4(function(){return C.getCurrentTime()},function(){return C.getPlaybackRate()},function(){return C.getPlayerState()},function(f,k){f!==g.Ce("endcr")||g.M(C.playerState,32)||C.mR(); h(f,k,C.playerType)},function(f,k){g.VW(C.videoData)&&C.f0(f,k)}); g.Z(this,this.ih);g.Z(this,this.k_);J2y(this,t);this.videoData.subscribe("dataupdated",this.Mg6,this);this.videoData.subscribe("dataloaded",this.Ac,this);this.videoData.subscribe("dataloaderror",this.handleError,this);this.videoData.subscribe("ctmp",this.f0,this);this.videoData.subscribe("ctmpstr",this.Ph,this);this.H$();kbx(this.Nv);this.visibility.subscribe("visibilitystatechange",this.Nv);this.H7=new g.mr(this.k0,g.ID(this.O$.experiments,"html5_player_att_initial_delay_ms")||4500,this);this.s3= new g.mr(this.k0,g.ID(this.O$.experiments,"html5_player_att_retry_delay_ms")||4500,this);this.KY=new g.dT(this)}; J2y=function(P,v){if(P.playerType===2||P.O$.J8)v.LD=!0;var l=L0q(v.CI,v.Qd,P.O$.Y,P.O$.j);l&&(v.adFormat=l);P.playerType===2&&(v.tq=!0);if(P.isFullscreen()||P.O$.Y)l=g.au("yt-player-autonavstate"),v.autonavState=l||(P.O$.Y?2:P.videoData.autonavState);v.endSeconds&&v.endSeconds>v.startSeconds&&gS(P,v.endSeconds)}; uGW=function(P){m5w(P.Oj);g.Rm(P.Oj);for(var v=P.M8,l=g.N(v.W.values()),e=l.next();!e.done;e=l.next())m5w(e.value);v.W.clear();g.Rm(P.M8)}; KCB=function(P){var v=P.videoData;nxP(P).then(void 0,function(l){P.videoData!==v||v.s$()||(l=LW(l),l.errorCode==="auth"&&P.videoData.errorDetail?P.VI(l.errorCode,2,unescape(P.videoData.errorReason),bp(l.details),P.videoData.errorDetail,P.videoData.ZH||void 0):P.handleError(l))})}; FCP=function(P){if(!g.M(P.playerState,128))if(P.videoData.isLoaded(),P.logger.debug("finished loading playback data"),P.zq=g.vZ(P.videoData.T1),g.YM(P.videoData)){P.pI.tick("bpd_s");KZ(P).then(function(){P.pI.tick("bpd_c");if(!P.s$()){P.Cl&&(P.Y_(tU(tU(P.playerState,512),1)),J2(P));var e=P.videoData;e.endSeconds&&e.endSeconds>e.startSeconds&&gS(P,e.endSeconds);P.MJ.finished=!0;cC(P,"dataloaded");P.Wo.Sn()&&c29(P);OLx(P.nw,P.Sg)}}); P.V("html5_log_media_perf_info")&&P.f0("loudness",{v:P.videoData.sZ.toFixed(3)},!0);var v,l=(v=P.mediaElement)==null?void 0:v.YY();l&&"disablePictureInPicture"in l&&P.V("html5_disable_pip_with_standard_api")&&(l.disablePictureInPicture=P.O$.sZ&&!P.videoData.backgroundable);qLy(P)}else cC(P,"dataloaded")}; KZ=function(P){qH(P);P.Sg=null;var v=cg2(P.O$,P.videoData,P.KJ());P.Ux=v;P.Ux.then(function(l){A2u(P,l)},function(l){P.s$()||(l=LW(l),P.visibility.isBackground()?(FG(P,"vp_none_avail"),P.Ux=null,P.MJ.reset()):(P.MJ.finished=!0,P.VI(l.errorCode,l.severity,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",bp(l.details))))}); return v}; A2u=function(P,v){if(!P.s$()&&!v.videoData.s$()){P.logger.debug("finished building playback data");P.Sg=v;aQD(P.k_,P.Sg);if(P.videoData.isLivePlayback){var l=YLw(P.jN.KE,P.videoData.videoId)||P.K0&&!isNaN(P.K0.J5);l=P.V("html5_onesie_live")&&l;CZ(P)||P.videoData.jS>0&&!$M(P.videoData)||l||P.seekTo(P.Jk(),{mD:"videoplayer_playbackData",seekSource:18})}if(P.videoData.G.W){if(P.V("html5_sabr_report_missing_url_as_error")&&RWu(P.videoData)){P.handleError(new xq("fmt.missing",{missabrurl:"1"},2));return}P.K0? g.j4(Error("Duplicated Loader")):(l=g.ID(P.O$.experiments,"html5_onesie_defer_content_loader_ms"))&&P.Pi()&&YLw(P.jN.KE,P.videoData.Ks)?g.KG(function(){P.s$()||P.K0||bZy(P)},l):bZy(P)}else!P.videoData.G.W&&dw(P.videoData)&&P.Q$(new kb(P.videoData.videoId||"",4)); P.yu();UJP(v).then(function(){var e={};P.MP(e);P.O$.vK()&&P.V("html5_log_media_perf_info")&&P.f0("av1Info",e);NH(P)})}}; c29=function(P){P.s$();P.logger.debug("try finish readying playback");if(P.Wo.finished)P.logger.debug("already finished readying");else if(P.MJ.finished)if(g.M(P.playerState,128))P.logger.debug("cannot finish readying because of error");else if(P.zq.length)P.logger.debug(function(){return"cannot finish readying because of pending preroll: "+P.zq}); else if(P.ih.started||ncw(P.ih),P.Zt())P.logger.debug("cannot finish readying because cuemanager has pending prerolls");else{P.K0&&(P.k$=RdW(P.K0.timing));P.Wo.finished||(P.Wo.finished=!0);var v=P.V("html5_onesie_live")&&P.K0&&!isNaN(P.K0.J5);!P.videoData.isLivePlayback||P.videoData.jS>0&&!$M(P.videoData)||v||CZ(P)||(P.logger.debug("seek to head for live"),P.seekTo(Infinity,{mD:"videoplayer_readying",seekSource:18}),P.isBackground()&&(P.M0=!0));vcD(P.uQ());P.logger.debug("finished readying playback"); P.publish("playbackready",P);sn("pl_c",P.pI.timerName)||(P.pI.tick("pl_c"),Md("pl_c",void 0,"video_to_ad"));sn("pbr",P.pI.timerName)||(P.pI.tick("pbr"),Md("pbr",void 0,"video_to_ad"))}else P.logger.debug("playback data not loaded")}; gS=function(P,v){P.cI&&xH6(P);P.cI=new g.tn(v*1E3,0x7ffffffffffff);P.cI.namespace="endcr";P.addCueRange(P.cI)}; xH6=function(P){P.removeCueRange(P.cI);P.cI=null}; pCW=function(P,v,l,e,h){var z=P.uQ(h),m=g.VW(P.videoData)?z.getVideoData():P.videoData;m.K=l;var Q=g.A2(P);l=new Y9D(m,l,v,Q?Q.itag:"",e);P.O$.experiments.l$("html5_refactor_sabr_video_format_selection_logging")?(l.videoId=h,P.xw=l):z.mT(l);h=P.nw;h.K=0;h.W=0;P.publish("internalvideoformatchange",m,v==="m")}; g.A2=function(P){var v=Yx(P);return tR(v)||!P.Sg?null:g.om(P.Sg.W.videoInfos,function(l){return v.Y(l)})}; Yx=function(P){if(P.Sg){var v=P.nw;var l=P.Sg;P=P.v5();if(v.M5.QK().isInline())var e=Ov;else v.V("html5_exponential_memory_for_sticky")?e=YQ(v.O$.t3,"sticky-lifetime")<.5?"auto":yy[aJ()]:e=yy[aJ()],e=g.Ra("auto",e,!1,"s");if(tR(e)){if(e=xJW(v,l).compose(Xmx(v,l)).compose(iLD(v,l)).compose(Eba(v,l.videoData)).compose(WP7(v,l.videoData,l)).compose(Ag(v,l)).compose(S9W(v,l)),tR(P)||v.V("html5_apply_pbr_cap_for_drm"))e=e.compose(Gbq(v,l))}else v.V("html5_perf_cap_override_sticky")&&(e=e.compose(Ag(v, l))),v.V("html5_ustreamer_cap_override_sticky")&&(e=e.compose(Gbq(v,l)));e=e.compose(S9W(v,l));v=l.videoData.M1.compose(e).compose(l.videoData.mO).compose(P)}else v=Ov;return v}; vHW=function(P){var v=P.nw;P=P.videoData;var l=Eba(v,P);v.V("html5_disable_client_autonav_cap_for_onesie")||l.compose(WP7(v,P));return l}; NH=function(P){if(P.videoData.G&&P.videoData.G.W){var v=Yx(P);P.K0&&r0a(P.K0,v)}}; LCy=function(P){var v;return!!(P.V("html5_native_audio_track_switching")&&g.FA&&((v=P.videoData.K)==null?0:vB(v)))}; SLw=function(P){if(!LCy(P))return!1;var v;P=(v=P.mediaElement)==null?void 0:v.audioTracks();return!!(P&&P.length>1)}; XCD=function(P){var v=Gdw(P);if(v)return P.videoData.getAvailableAudioTracks().find(function(l){return l.Rt.getName()===v})}; Gdw=function(P){var v;if(P=(v=P.mediaElement)==null?void 0:v.audioTracks())for(v=0;v0&&(v.FL=e.L1)); v.rH=e.RO;v.gH=GB(l,{},e.G||void 0,tc(e));v.D3=Qi(e)&&g.H$(l);v.zL=l.V("html5_catch_errors_for_rollback");yi(e)&&(l.V("html5_sabr_allow_video_keyframe_without_audio")&&(v.bC=!0),l.V("html5_sabr_report_partial_segment_estimated_duration")&&(v.zj=!0),v.W=!0,v.So=l.V("html5_sabr_enable_utc_seek_requests"),v.iR=l.V("html5_sabr_enable_live_clock_offset"),v.Bw=l.V("html5_disable_client_resume_policy_for_sabr"),v.Uf=l.V("html5_trigger_loader_when_idle_network"),v.Ir=l.V("html5_sabr_parse_live_metadata_playback_boundaries"), v.xV=l.V("html5_enable_platform_backpressure_with_sabr"),v.t4=l.V("html5_consume_onesie_next_request_policy_for_sabr"),v.Sm=l.V("html5_sabr_report_next_ad_break_time"),v.DZ=l.V("html5_log_high_res_buffer_timeline"),v.fW=l.V("html5_remove_stuck_slices_beyond_max_buffer_limits"),v.YV=l.V("html5_gapless_sabr_btl_last_slice")&&Rh(e),$M(e)?(v.S9=!0,v.KO=l.V("html5_disable_variability_tracker_for_live"),v.h5=l.V("html5_sabr_use_accurate_slice_info_params"),l.V("html5_simplified_backup_timeout_sabr_live")&& (v.h1=!0,v.jg=v.i7)):v.aV=l.V("html5_probe_request_on_sabr_request_progress"),v.Rr=l.V("html5_serve_start_seconds_seek_for_post_live_sabr"),v.CI=l.V("html5_flush_index_on_updated_timestamp_offset"),v.QW=l.V("html5_enable_sabr_request_pipelining")&&!g.VW(e),v.R7=l.V("html5_ignore_partial_segment_from_live_readahead"),v.JX=l.V("html5_use_non_active_broadcast_for_post_live"),v.wM=l.V("html5_use_centralized_player_time"),v.oz=l.V("html5_consume_onesie_sabr_seek"),v.J5=l.V("html5_enable_sabr_seek_loader_refactor"), v.K1=l.V("html5_update_segment_start_time_from_media_header"),e.enableServerStitchedDai&&(v.Z=!0,v.AK=l.V("html5_reset_server_stitch_state_for_non_sabr_seek"),v.N1=l.V("html5_remove_ssdai_append_pause"),v.A5=l.V("html5_consume_ssdai_info_with_streaming"),v.hN=l.V("html5_process_all_cuepoints")));v.T=v.W&&l.V("html5_sabr_live");Kr(l.Z,cn.BITRATE)&&(v.FJ=NaN);if(Q=g.ID(l.experiments,"html5_request_size_max_kb"))v.q5=Q*1024;l.Z.Y?v.XE="; "+cn.EXPERIMENTAL.name+"=allowed":l.V("html5_enable_cobalt_tunnel_mode")&& (v.XE="; tunnelmode=true");Q=e.serverPlaybackStartConfig;(Q==null?0:Q.enable)&&(Q==null?0:Q.playbackStartPolicy)&&(v.Yy=!0,rq(v,Q.playbackStartPolicy,2));Q=BSB(P);P.bJ.removeAll();a:{l=P.jN.KE;if(e=P.videoData.videoId)if(h=l.W.get(e)){l.W.remove(e);l=h;break a}l=void 0}P.K0=new g.Cf(P,P.O$.schedule,v,P.videoData.W,P.videoData.G,Yx(P),Q,P.videoData.enableServerStitchedDai,l,P.videoData.q5);v=P.videoData.V("html5_disable_preload_for_ssdai_with_preroll")&&P.videoData.isLivePlayback&&P.Pi()?!0:P.Cl&& g.pF(P.O$)&&P.videoData.isLivePlayback;P.K0.initialize(P.getCurrentTime(),Yx(P),v);P.videoData.probeUrl&&(P.K0.Ic=P.videoData.probeUrl);if(P.zq.length||P.Cl)P.videoData.cotn||bj(P,!1);Ec6(P.k_,P.K0);P.PR&&(IND(P.K0,new g.wT(P.PR)),P.V("html5_check_decorator_on_cuepoint")&&P.f0("sdai",{sdl:1}));P.gM&&(P.K0.CS(P.gM),P.k_.j=!1);g.vS(P.videoData)&&(P=P.K0,P.policy.lE=P.policy.CV)}; qH=function(P){P.K0&&(P.K0.dispose(),P.K0=null,Ec6(P.k_,null));P.Pf()?iZD(P):P.LR()}; iZD=function(P){if(P.u$)if(P.logger.debug("release media source"),P.DM(),P.u$.Z)try{P.O$.vK()&&P.f0("rms",{l:"vprms",sr:P.Pf(),rs:Vu(P.u$)});P.u$.clear();var v;(v=P.mediaElement)!=null&&(v.K=P.u$);P.u$=null}catch(l){v=new g.Ph("Error while clearing Media Source in VideoPlayer: "+l.name+", "+l.message),v=LW(v),P.handleError(v),P.LR()}else P.LR()}; UH6=function(P,v){v=v===void 0?!1:v;if(P.u$)return P.u$.G;P.logger.debug("update media source");a:{v=v===void 0?!1:v;try{g.VS()&&P.videoData.JU()&&Amx(P.mediaElement);var l=P.mediaElement.fg(P.kL(),P.UP())}catch(h){if(JEW(P.OY,"html5.missingapi",{updateMs:"1"}))break a;console.error("window.URL object overwritten by external code",h);P.VI("html5.missingapi",2,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK","updateMs.1");break a}P.eD(l,!1,!1,v)}var e;return((e=P.fg())==null?void 0:e.G)||null}; ZZu=function(P,v){v=v===void 0?!1:v;if(P.K0){var l=P.getCurrentTime()-P.fh();P.K0.seek(l,{hP:v}).bY(function(){})}else bZy(P)}; aga=function(P,v,l,e){l=l===void 0?!1:l;e=e===void 0?!1:e;if(P.u$&&(!v||P.u$===v)){P.logger.debug("media source opened");var h=P.getDuration();!h&&$M(P.videoData)&&(h=25200);if(P.u$.isView){var z=h;P.logger.debug(function(){return"Set media source duration to "+z+", video duration "+h}); z>P.u$.getDuration()&&jBq(P,z)}else jBq(P,h);O_u(P.K0,P.u$,l,e);P.publish("mediasourceattached")}}; jBq=function(P,v){if(P.u$){P.u$.vU(v);var l;(l=P.K0)!=null&&l.policy.wM&&(l.T=v)}}; Thq=function(P,v){pCW(P,v.reason,v.W.info,v.token,v.videoId)}; HZ2=function(P,v){P.O$.experiments.l$("enable_adb_handling_in_sabr")&&(P.pauseVideo(!0),P.K7(),v&&P.VI("sabr.config",1,"BROWSER_OR_EXTENSION_ERROR"))}; cC=function(P,v){P.publish("internalvideodatachange",v===void 0?"dataupdated":v,P,P.videoData)}; Exq=function(P){for(var v=g.N("loadstart loadedmetadata play playing progress pause ended suspend seeking seeked timeupdate durationchange ratechange error waiting resize".split(" ")),l=v.next();!l.done;l=v.next())P.uI.C(P.mediaElement,l.value,P.ai,P);P.O$.BV&&P.mediaElement.n1()&&(P.uI.C(P.mediaElement,"webkitplaybacktargetavailabilitychanged",P.vYW,P),P.uI.C(P.mediaElement,"webkitcurrentplaybacktargetiswirelesschanged",P.bI2,P))}; OZw=function(P){g.Ft(P.qr);WCB(P)||(P.qr=g.cM(function(){return WCB(P)},100))}; WCB=function(P){var v=P.mediaElement;v&&P.C5&&!P.videoData.J5&&!sn("vfp",P.pI.timerName)&&v.lY()>=2&&!v.isEnded()&&gJ(v.AB())>0&&P.pI.tick("vfp");return(v=P.mediaElement)&&!P.videoData.J5&&v.getDuration()>0&&(v.isPaused()&&v.lY()>=2&&gJ(v.AB())>0&&(sn("pbp",P.pI.timerName)||P.pI.tick("pbp"),!P.videoData.lr||P.dK||v.isSeeking()||(P.dK=!0,P.publish("onPlaybackPauseAtStart"))),v=v.getCurrentTime(),PC(P.LZ,v))?(P.df(),!0):!1}; sBD=function(P){P.uQ().mf();if(ww(P.videoData)&&Date.now()>P.O4+6283){if(!(!P.isAtLiveHead()||P.videoData.W&&Jp(P.videoData.W))){var v=P.uQ();if(v.qoe){v=v.qoe;var l=v.provider.M5.rC(),e=g.b7(v.provider);wU6(v,e,l);l=l.G;isNaN(l)||g.Sh(v,e,"e2el",[l.toFixed(3)])}}P.V("html5_alc_live_log_rawlat")?(v=P.videoData,v=g.bq(v.N())?!0:g.VP(v.N())?v.hN==="6":!1):v=g.bq(P.O$);v&&P.f0("rawlat",{l:IB(P.N0,"rawlivelatency").toFixed(3)});P.O4=Date.now()}P.videoData.K&&vB(P.videoData.K)&&(v=P.yU())&&v.videoHeight!== P.jr&&(P.jr=v.videoHeight,pCW(P,"a",ox2(P,P.videoData.A5)))}; ox2=function(P,v){if(v.W.video.quality==="auto"&&vB(v.getInfo())&&P.videoData.hs)for(var l=g.N(P.videoData.hs),e=l.next();!e.done;e=l.next())if(e=e.value,e.getHeight()===P.jr&&e.W.video.quality!=="auto")return e.getInfo();return v.getInfo()}; NS6=function(P){if(!ww(P.videoData))return NaN;var v=0;P.K0&&P.videoData.W&&(v=$M(P.videoData)?P.K0.Eu.y_()||0:P.videoData.W.T1);return(0,g.Gz)()/1E3-P.lC()-v}; MWy=function(P){P.mediaElement&&P.mediaElement.KJ()&&(P.QJ=(0,g.Gz)());P.O$.NH?g.KG(function(){r2D(P)},0):r2D(P)}; r2D=function(P){var v;if((v=P.u$)==null||!v.pg()){if(P.mediaElement)try{P.oi=P.mediaElement.playVideo()}catch(e){FG(P,"err."+e)}if(P.oi){var l=P.oi;l.then(void 0,function(e){P.logger.debug(function(){return"playMediaElement failed: "+e}); if(!g.M(P.playerState,4)&&!g.M(P.playerState,256)&&P.oi===l)if(e&&e.name==="AbortError"&&e.message&&e.message.includes("load"))P.logger.debug(function(){return"ignore play media element failure: "+e.message}); else{var h="promise";e&&e.name&&(h+=";m."+e.name);FG(P,h);P.Mp=!0;P.videoData.Ro=!0}})}}}; FG=function(P,v){g.M(P.playerState,128)||(P.Y_(CM(P.playerState,1028,9)),P.f0("dompaused",{r:v}),P.publish("onAutoplayBlocked"))}; J2=function(P,v){v=v===void 0?!1:v;if(!P.mediaElement||!P.videoData.G)return!1;var l=v;l=l===void 0?!1:l;var e=null;var h;if((h=P.videoData.G)==null?0:h.W){e=UH6(P,l);var z;(z=P.K0)==null||z.resume()}else qH(P),P.videoData.A5&&(e=P.videoData.A5.KV());h=P.mediaElement.Et();l=!1;h&&h.ZA(e)||(TSy(P,e),l=!0);g.M(P.playerState,2)||(e=P.k_,v=v===void 0?!1:v,e.Z||!(e.Y>0)||e.mediaElement&&e.mediaElement.getCurrentTime()>0||(v={mD:"seektimeline_resumeTime",hP:v},e.videoData.J5||(v.seekSource=15),e.seekTo(e.Y, v)));a:{v=l;if(yi(P.videoData)){if(!P.videoData.d7())break a}else if(!g.cd(P.videoData))break a;if(P.mediaElement)if((e=P.videoData.Z)&&P.mediaElement.n1()){h=P.mediaElement.YY();if(P.qV)if(h!==P.qV.element)xx(P);else if(v&&e.flavor==="fairplay"&&!d$())xx(P);else break a;if(P.V("html5_report_error_for_unsupported_tvos_widevine")&&d$()&&e.flavor==="widevine")P.VI("fmt.unplayable",1,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK","drm.unspttvoswidevine");else{P.qV=new zsB(h,P.videoData,P.O$);P.qV.subscribe("licenseerror", P.Wu,P);P.qV.subscribe("qualitychange",P.Hh$,P);P.qV.subscribe("heartbeatparams",P.I$,P);P.qV.subscribe("keystatuseschange",P.a7,P);P.qV.subscribe("ctmp",P.f0,P);P.V("html5_widevine_use_fake_pssh")&&!P.videoData.isLivePlayback&&e.flavor==="widevine"&&P.qV.EK(new gq(VWD,"cenc",!1));v=g.N(P.bJ.keys);for(e=v.next();!e.done;e=v.next())e=P.bJ.get(e.value),P.qV.EK(e);P.V("html5_eme_loader_sync")||P.bJ.removeAll()}}else P.VI("fmt.unplayable",1,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK","drm.1")}return l}; TSy=function(P,v){P.pI.tick("vta");Md("vta",void 0,"video_to_ad");P.getCurrentTime()>0&&stD(P.k_,P.getCurrentTime());P.mediaElement.activate(v);P.u$&&tP(0,4);!P.videoData.J5&&P.playerState.isOrWillBePlaying()&&P.m1.start();if(LCy(P)){var l;if(v=(l=P.mediaElement)==null?void 0:l.audioTracks())v.onchange=function(){P.publish("internalaudioformatchange",P.videoData,!0)}}}; xx=function(P){P.qV&&(P.qV.dispose(),P.qV=null)}; dHw=function(P){var v=v===void 0?!1:v;P.logger.debug("reattachVideoSource");P.mediaElement&&(P.u$?(xx(P),P.LR(),UH6(P,v)):(P.videoData.A5&&P.videoData.A5.KQ(),P.mediaElement.stopVideo()),P.playVideo())}; Prq=function(P,v){P.O$.V("html5_log_rebuffer_reason")&&(v={r:v,lact:Ly()},P.mediaElement&&(v.bh=eq(P.mediaElement)),P.f0("bufreason",v))}; v0B=function(P,v){if(P.O$.vK()&&P.mediaElement){var l=P.mediaElement.Ui();l.omt=(P.mediaElement.getCurrentTime()+P.fh()).toFixed(3);l.ps=P.playerState.state.toString(16);l.rt=(g.b7(P.uQ().provider)*1E3).toFixed();l.e=v;P.xO[P.S$++%5]=l}try{if(v==="timeupdate"||v==="progress")return}catch(e){}P.logger.debug(function(){return"video element event "+v})}; lR7=function(P){if(P.O$.vK()){P.xO.sort(function(e,h){return+e.rt-+h.rt}); for(var v=g.N(P.xO),l=v.next();!l.done;l=v.next())l=l.value,P.f0("vpe",Object.assign({t:l.rt},l));P.xO=[];P.S$=0}}; eU9=function(P){if(g.Mc("cobalt")&&g.Mc("nintendo switch")){var v=!window.matchMedia("screen and (max-height: 720px) and (min-resolution: 200dpi)").matches;P.f0("nxdock",{d:v})}}; bj=function(P,v){var l;(l=P.K0)==null||gT(l,v)}; I2w=function(P,v){return g.VW(P.videoData)&&P.gM?P.gM.handleError(v,void 0):!1}; qLy=function(P){kM(P.videoData,"html5_set_debugging_opt_in")&&(P=g.sY(),g.rD(0,183)||(TT(183,!0),P.save()))}; hUP=function(P){return g.VW(P.videoData)&&P.gM?z5(P.gM):P.videoData.Jk()}; Ke7=function(P,v){P.jN.Aq()||(P.f0("sgap",{f:v}),P.jN.clearQueue(!1,v==="pe"))}; CZ=function(P){return P.V("html5_disable_video_player_initiated_seeks")&&yi(P.videoData)}; zU2=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);yI(this.api,"isLifaAdPlaying",function(){return v.api.isLifaAdPlaying()}); this.events.C(P,"serverstitchedvideochange",function(){v.api.isLifaAdPlaying()?(v.playbackRate=v.api.getPlaybackRate(),v.api.setPlaybackRate(1)):v.api.setPlaybackRate(v.playbackRate)}); this.playbackRate=1}; mOx=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);yI(this.api,"seekToChapterWithAnimation",function(l){v.seekToChapterWithAnimation(l)}); yI(this.api,"seekToTimeWithAnimation",function(l,e){v.seekToTimeWithAnimation(l,e)}); yI(this.api,"renderChapterSeekingAnimation",function(l,e,h){v.api.renderChapterSeekingAnimation(l,e,h)}); yI(this.api,"setMacroMarkers",function(l){v.setMacroMarkers(P,l)}); yI(this.api,"changeMarkerVisibility",function(l,e,h){v.changeMarkerVisibility(l,e,h)}); yI(this.api,"isSameMarkerTypeVisible",function(l){return v.isSameMarkerTypeVisible(l)})}; RUq=function(P,v,l){var e=P.api.getCurrentTime()*1E3 0&&h>0&&(l.width+=h,g.DO(v.element,"width",l.width+"px")));P.size=l}}; g.oB=function(P,v){var l=P.W[P.W.length-1];l!==v&&(P.W.push(v),Ssw(P,l,v))}; g.sL=function(P){if(!(P.W.length<=1)){var v=P.W.pop(),l=P.W[0];P.W=[l];Ssw(P,v,l,!0)}}; Ssw=function(P,v,l,e){GrB(P);v&&(v.unsubscribe("size-change",P.rP,P),v.unsubscribe("back",P.Rz,P));l.subscribe("size-change",P.rP,P);l.subscribe("back",P.Rz,P);if(P.KI){g.kk(l.element,e?"ytp-panel-animate-back":"ytp-panel-animate-forward");l.E$(P.element);l.focus();P.element.scrollLeft=0;P.element.scrollTop=0;var h=P.size;L5D(P);g.Ln(P.element,h);P.T=new g.mr(function(){XKa(P,v,l,e)},20,P); P.T.start()}else l.E$(P.element),v&&v.detach()}; XKa=function(P,v,l,e){P.T.dispose();P.T=null;g.kk(P.element,"ytp-popup-animating");e?(g.kk(v.element,"ytp-panel-animate-forward"),g.$k(l.element,"ytp-panel-animate-back")):(g.kk(v.element,"ytp-panel-animate-back"),g.$k(l.element,"ytp-panel-animate-forward"));g.Ln(P.element,P.size);P.j=new g.mr(function(){g.$k(P.element,"ytp-popup-animating");v.detach();g.IX(v.element,["ytp-panel-animate-back","ytp-panel-animate-forward"]);P.j.dispose();P.j=null},250,P); P.j.start()}; GrB=function(P){P.T&&g.QD(P.T);P.j&&g.QD(P.j)}; rS=function(P){g.OL.call(this,P,"ytp-shopping-product-menu");this.SF=new g.EL(this.J);g.Z(this,this.SF);this.hide();g.oB(this,this.SF);g.i2(this.J,this.element,4)}; iXD=function(P,v,l){var e,h=v==null?void 0:(e=v.text)==null?void 0:e.simpleText;h&&(l=BMw(P,l,h,v==null?void 0:v.icon,v==null?void 0:v.secondaryIcon),v.navigationEndpoint&&l.listen("click",function(){P.J.C0("innertubeCommand",v.navigationEndpoint);P.hide()},P))}; UOq=function(P,v,l){var e,h=v==null?void 0:(e=v.text)==null?void 0:e.simpleText;h&&BMw(P,l,h,v==null?void 0:v.icon).listen("click",function(){var z;(v==null?void 0:(z=v.icon)==null?void 0:z.iconType)==="HIDE"?P.J.publish("featuredproductdismissed"):v.serviceEndpoint&&P.J.C0("innertubeCommand",v.serviceEndpoint);P.hide()},P)}; BMw=function(P,v,l,e,h){v=new g.rd(g.Mh({},[],!1,!!h),v,l);h&&v.updateValue("secondaryIcon",ZX2(h));v.setIcon(ZX2(e));g.Z(P,v);P.SF.w9(v,!0);return v}; ZX2=function(P){if(!P)return null;switch(P.iconType){case "ACCOUNT_CIRCLE":return{L:"svg",B:{height:"24",viewBox:"0 0 24 24",width:"24"},U:[{L:"path",B:{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 1c4.96 0 9 4.04 9 9 0 1.42-.34 2.76-.93 3.96-1.53-1.72-3.98-2.89-7.38-3.03A3.99 3.99 0 0016 9c0-2.21-1.79-4-4-4S8 6.79 8 9c0 1.97 1.43 3.6 3.31 3.93-3.4.14-5.85 1.31-7.38 3.03C3.34 14.76 3 13.42 3 12c0-4.96 4.04-9 9-9zM9 9c0-1.65 1.35-3 3-3s3 1.35 3 3-1.35 3-3 3-3-1.35-3-3zm3 12c-3.16 0-5.94-1.64-7.55-4.12C6.01 14.93 8.61 13.9 12 13.9c3.39 0 5.99 1.03 7.55 2.98C17.94 19.36 15.16 21 12 21z", fill:"#fff"}}]};case "FLAG":return{L:"svg",B:{fill:"none",height:"24",viewBox:"0 0 24 24",width:"24"},U:[{L:"path",B:{d:"M13.18 4L13.42 5.2L13.58 6H14.4H19V13H13.82L13.58 11.8L13.42 11H12.6H6V4H13.18ZM14 3H5V21H6V12H12.6L13 14H20V5H14.4L14 3Z",fill:"white"}}]};case "HELP":return cPW();case "HIDE":return{L:"svg",B:{"enable-background":"new 0 0 24 24",fill:"#fff",height:"24",viewBox:"0 0 24 24",width:"24"},U:[{L:"g",U:[{L:"path",B:{d:"M16.24,9.17L13.41,12l2.83,2.83l-1.41,1.41L12,13.41l-2.83,2.83l-1.41-1.41L10.59,12L7.76,9.17l1.41-1.41L12,10.59 l2.83-2.83L16.24,9.17z M4.93,4.93c-3.91,3.91-3.91,10.24,0,14.14c3.91,3.91,10.24,3.91,14.14,0c3.91-3.91,3.91-10.24,0-14.14 C15.17,1.02,8.83,1.02,4.93,4.93z M18.36,5.64c3.51,3.51,3.51,9.22,0,12.73s-9.22,3.51-12.73,0s-3.51-9.22,0-12.73 C9.15,2.13,14.85,2.13,18.36,5.64z"}}]}]}; case "OPEN_IN_NEW":return xF()}}; MH=function(P){aB.call(this,P,!1,!0);this.isCounterfactual=this.K=this.isVisible=this.isInitialized=this.shouldShowOverflowButton=this.shouldHideDismissButton=!1;this.S=!0;this.overflowButton=new g.O({L:"button",z1:["ytp-featured-product-overflow-icon","ytp-button"],B:{"aria-haspopup":"true"}});this.overflowButton.hide();g.Z(this,this.overflowButton);this.badge.element.classList.add("ytp-suggested-action");this.thumbnailImage=new g.O({L:"img",D:"ytp-suggested-action-badge-img",B:{src:"{{url}}"}}); this.thumbnailImage.hide();g.Z(this,this.thumbnailImage);this.thumbnailIcon=new g.O({L:"div",D:"ytp-suggested-action-badge-icon"});this.thumbnailIcon.hide();g.Z(this,this.thumbnailIcon);this.banner=new g.O({L:"a",D:"ytp-suggested-action-container",U:[this.thumbnailImage,this.thumbnailIcon,{L:"div",D:"ytp-suggested-action-details",U:[{L:"text",D:"ytp-suggested-action-title",Yf:"{{title}}"},{L:"text",D:"ytp-suggested-action-subtitle",Yf:"{{subtitle}}"},{L:"text",D:"ytp-suggested-action-metadata-text", Yf:"{{metadata}}"}]},this.dismissButton,this.overflowButton]});g.Z(this,this.banner);this.banner.E$(this.G.element);this.C(this.J,"videodatachange",this.onVideoDataChange);this.C(this.J,g.Ce("suggested_action_view_model"),this.LDg);this.C(this.J,g.fe("suggested_action_view_model"),this.Zh0);this.C(this.overflowButton.element,"click",this.hv);this.C(P,"featuredproductdismissed",this.TB);this.J.createServerVe(this.banner.element,this.banner,!0)}; jk2=function(P){P.isInitialized&&(P.enabled=P.isVisible,P.QW=P.isVisible,jW(P),P.xg(),P.thumbnailImage.BK(P.isVisible),P.shouldHideDismissButton||P.dismissButton.BK(P.isVisible),P.shouldShowOverflowButton&&P.overflowButton.BK(P.isVisible))}; Td=function(){MH.apply(this,arguments)}; aRD=function(P){dd.call(this,P);this.W=new Td(this.api);g.Z(this,this.W);g.i2(this.api,this.W.element,4)}; V_=function(P){dd.call(this,P);var v=this;this.K="";this.G=!0;this.W=this.api.V("html5_enable_audio_track_stickiness_phase_two");var l=new g.Z1(P);g.Z(this,l);l.C(P,"internalaudioformatchange",function(e,h){HXa(v,e,h)}); l.C(P,"videoplayerreset",function(){var e;(v.K||v.W&&((e=oJ())==null?0:e.size))&&E02(v)}); l.C(P,"videodatachange",function(e,h){v.onVideoDataChange(e,h)})}; HXa=function(P,v,l){if(l){var e="";W5B(P,v)&&(e=v,P.W||(P.K=v),P.api.V("html5_sabr_enable_server_xtag_selection")&&(l=P.api.getVideoData(void 0,!0)))&&(l.NH=v);P.W&&e&&OXa(P,e)&&o0q(P)!==e&&(sky([{settingItemId:dS(P),settingOptionValue:{stringValue:v}}]),D9(P.Z0(),function(h){QM9(h,dS(P),{stringValue:e})}))}}; E02=function(P){if(P.W){var v;(v=o0q(P))&&OXa(P,v)&&(P=P.api.getVideoData(void 0,!0))&&(P.NH=v)}else if(v=P.api.getVideoData(void 0,!0))v.NH=P.K}; rkw=function(P){n6(D9(D9(P.Z0(),function(v){return ma9(v,[dS(P)])}),function(v){if(v){v=g.N(v); for(var l=v.next();!l.done;l=v.next()){var e=l.value;l=e.key;e=e.value;l&&e&&sky([{settingItemId:l,settingOptionValue:e}])}}}),function(){P.G=!0})}; W5B=function(P,v){P=P.api.getAvailableAudioTracks();P=g.N(P);for(var l=P.next();!l.done;l=P.next())if(l=l.value,l.getLanguageInfo().getId()===v)return l;return null}; o0q=function(P){P=dS(P);var v=oJ();P=v?v.get(P):void 0;return P&&P.stringValue?P.stringValue:""}; dS=function(P){var v=(484).toString();P.api.N().A1&&(v=(483).toString());return v}; OXa=function(P,v){var l;return v.split(".")[0]!==""&&((l=P.api.getVideoData())==null?void 0:!Vi(l))}; sky=function(P){var v=oJ();v||(v=new Map);P=g.N(P);for(var l=P.next();!l.done;l=P.next())l=l.value,v.set(l.settingItemId,l.settingOptionValue);v=JSON.stringify(Object.fromEntries(v));g.jB("yt-player-user-settings",v,2592E3)}; g.PK=function(P,v,l,e,h,z,m){g.rd.call(this,g.Mh({"aria-haspopup":"true"}),v,P);this.LI=e;this.S=!1;this.G=null;this.options={};this.K=new g.EL(l,void 0,P,h,z,m);g.Z(this,this.K);this.listen("keydown",this.R_);this.listen("click",this.open)}; M_y=function(P){if(P.G){var v=P.options[P.G];v.element.getAttribute("aria-checked");v.element.setAttribute("aria-checked","false");P.G=null}}; TM7=function(P,v){g.PK.call(this,"Temporizador de suspensi\u00f3n",g.fH.SLEEP_TIMER,P,v);this.J=P;this.X={};this.T=this.fN("Off");this.j=this.W="";P.V("web_settings_menu_icons")&&this.setIcon({L:"svg",B:{height:"24",viewBox:"0 0 24 24",width:"24"},U:[{L:"path",B:{d:"M16.67,4.31C19.3,5.92,21,8.83,21,12c0,4.96-4.04,9-9,9c-2.61,0-5.04-1.12-6.72-3.02C5.52,17.99,5.76,18,6,18 c6.07,0,11-4.93,11-11C17,6.08,16.89,5.18,16.67,4.31 M14.89,2.43C15.59,3.8,16,5.35,16,7c0,5.52-4.48,10-10,10 c-1,0-1.97-0.15-2.89-0.43C4.77,19.79,8.13,22,12,22c5.52,0,10-4.48,10-10C22,7.48,19,3.67,14.89,2.43L14.89,2.43z M12,6H6v1h4.5 L6,10.99v0.05V12h6v-1H7.5L12,7.01V6.98V6L12,6z", fill:"#fff"}}]});this.Y=new g.O({L:"div",z1:["ytp-menuitem-label-wrapper"],U:[{L:"div",Yf:"Final del v\u00eddeo"},{L:"div",z1:["ytp-menuitem-sublabel"],Yf:"{{content}}"}]});g.Z(this,this.Y);this.listen("click",this.onClick);this.C(P,"videodatachange",this.onVideoDataChange);this.C(P,"presentingplayerstatechange",this.b$);this.C(P,"settingsMenuVisibilityChanged",this.qQW);P.createClientVe(this.element,this,218889);this.b$();this.J.C0("onSleepTimerFeatureAvailable")}; V_a=function(P){var v="Off 10 15 20 30 45 60".split(" "),l;((l=P.J.getVideoData())==null?0:l.isLivePlayback)||v.push("End of video");l=P.J.getPlaylist();var e;l&&((e=l.listId)==null?void 0:e.type)!=="RD"&&v.push("End of playlist");P.Cw(g.LC(v,P.fN));P.X=g.gL(v,P.fN,P);v=P.fN("End of video");P.options[v]&&g.sR(P.options[v],P.Y)}; dOw=function(P,v){var l=P.X[v],e=l==="End of video"||l==="End of playlist";l==="Off"&&(P.W="");P.J.getPlayerState()!==0&&P.J.getPlayerState()!==5||!e?(P.T=v,g.PK.prototype.BP.call(P,v),P.W9(v),P.J.C0("onSleepTimerSettingsChanged",l)):P.J.C0("innertubeCommand",{openPopupAction:{popupType:"TOAST",popup:{notificationActionRenderer:{responseText:{simpleText:"El v\u00eddeo ya ha acabado"}}}}})}; vK=function(P){dd.call(this,P);var v=this;P.addEventListener("settingsMenuInitialized",function(){v.menuItem||(v.menuItem=new TM7(v.api,v.api.Kg()),g.Z(v,v.menuItem))}); P.addEventListener("openSettingsMenuItem",function(l){if(l==="menu_item_sleep_timer"){if(!v.menuItem){var e;(e=v.api.Kg())==null||e.uq()}v.menuItem.open()}}); yI(P,"resetSleepTimerMenuSettings",function(){v.resetSleepTimerMenuSettings()}); yI(P,"setSleepTimerTimeLeft",function(l){v.setSleepTimerTimeLeft(l)}); yI(P,"setVideoTimeLeft",function(l){v.setVideoTimeLeft(l)})}; P3B=function(P){dd.call(this,P);var v=this;this.events=new g.Z1(P);g.Z(this,this.events);this.events.C(P,"onSnackbarMessage",function(l){switch(l){case 1:l=v.api.getPlayerStateObject(),l.isBuffering()&&g.M(l,8)&&g.M(l,16)&&v.api.C0("innertubeCommand",{openPopupAction:{popup:{notificationActionRenderer:{responseText:{runs:[{text:"\u00bfEl v\u00eddeo se interrumpe?"}]},actionButton:{buttonRenderer:{style:"STYLE_OVERLAY",size:"SIZE_DEFAULT",text:{runs:[{text:"Saber por qu\u00e9"}]},navigationEndpoint:{commandMetadata:{webCommandMetadata:{url:"https://support.google.com/youtube/answer/3037019#check_ad_blockers&zippy=%2Ccheck-your-extensions-including-ad-blockers", webPageType:"WEB_PAGE_TYPE_UNKNOWN"}},urlEndpoint:{url:"https://support.google.com/youtube/answer/3037019#check_ad_blockers&zippy=%2Ccheck-your-extensions-including-ad-blockers",target:"TARGET_NEW_WINDOW"}},loggingDirectives:{clientVeSpec:{uiType:232471}}}},loggingDirectives:{clientVeSpec:{uiType:232470}}}},durationHintMs:5E3,popupType:"TOAST"}})}})}; g.e_=function(P,v,l,e,h){v=v===void 0?!1:v;e=e===void 0?!1:e;h=h===void 0?!1:h;g.gA.call(this);this.X=h;this.j=!1;this.Y=new GT(this);this.Z=this.T=null;this.G=this.K=!1;g.Z(this,this.Y);this.target=P;this.W=v;this.S=l||P;this.j=e;v&&(g.V3&&this.target.setAttribute("draggable","true"),h||(this.target.style.touchAction="none"));lr(this)}; hk=function(P){g.Bx(P.Y,!P.W)}; lr=function(P){P.Z=null;P.T=null;P.C(zr("over"),P.Ag);P.C("touchstart",P.lS);P.W&&P.C(zr("down"),P.HIc)}; vow=function(P,v){for(var l=0;l h.start&&l >=5;q+=x}I=q.substr(0,4)+" "+q.substr(4,4)+" "+q.substr(8,4)+" "+(q.substr(12,4)+" "+q.substr(16, 4))}else I="";t={video_id_and_cpn:String(v.videoId)+" / "+I,codecs:"",dims_and_frames:"",bandwidth_kbps:t.toFixed(0)+" Kbps",buffer_health_seconds:C.toFixed(2)+" s",date:""+(new Date).toString(),drm_style:f?"":"display:none",drm:f,debug_info:l,extra_debug_info:"",bandwidth_style:w,network_activity_style:w,network_activity_bytes:y.toFixed(0)+" KB",shader_info:k,shader_info_style:k?"":"display:none",playback_categories:""};y=e.clientWidth+"x"+e.clientHeight+(h>1?"*"+h.toFixed(2):"");C="-";m.totalVideoFrames&& (C=(m.droppedVideoFrames||0)+" dropped of "+m.totalVideoFrames);t.dims_and_frames=y+" / "+C;P=P.getVolume();m=hWW(v);var B;y=((B=v.Y)==null?0:B.audio.W)?"DRC":Math.round(P*m)+"%";B=Math.round(P)+"% / "+y;P=v.sZ.toFixed(1);isFinite(Number(P))&&(B+=" (content loudness "+P+"dB)");t.volume=B;t.resolution=e.videoWidth+"x"+e.videoHeight;if(e=v.K){if(B=e.video)P=B.fps,P>1&&(t.resolution+="@"+P),(P=z.J35)&&P.video&&(t.resolution+=" / "+P.video.width+"x"+P.video.height,P.video.fps>1&&(t.resolution+="@"+P.video.fps)), t.codecs=mCP(e),!v.Y||e.audio&&e.video?e.Ra&&(t.codecs+=" / "+e.Ra+"A"):t.codecs+=" / "+mCP(v.Y),B.K||B.primaries?(P=B.K||"unknown",P==="smpte2084"?P+=" (PQ)":P==="arib-std-b67"&&(P+=" (HLG)"),t.color=P+" / "+(B.primaries||"unknown"),t.color_style=""):t.color_style="display:none";if(e.debugInfo)for(t.fmt_debug_info="",e=g.N(e.debugInfo),B=e.next();!B.done;B=e.next())B=B.value,t.fmt_debug_info+=B.label+":"+B.text+" ";t.fmt_debug_info_style=t.fmt_debug_info&&t.fmt_debug_info.length>0?"":"display:none"}e= v.isLivePlayback;B=v.cz;t.live_mode_style=e||B?"":"display:none";t.live_latency_style=e?"":"display:none";if(B)t.live_mode="Post-Live"+($M(v)?" Manifestless":"");else if(e){B=IB(Q,"livelatency");t.live_latency_secs=B.toFixed(2)+"s";e=$M(v)?"Manifestless, ":"";v.wM&&(e+="Windowed, ");P="Uncertain";if(B>=0&&B<120)if(v.latencyClass&&v.latencyClass!=="UNKNOWN")switch(v.latencyClass){case "NORMAL":P="Optimized for Normal Latency";break;case "LOW":P="Optimized for Low Latency";break;case "ULTRALOW":P="Optimized for Ultra Low Latency"; break;default:P="Unknown Latency Setting"}else P=v.isLowLatencyLiveStream?"Optimized for Low Latency":"Optimized for Smooth Streaming";e+=P;(B=z.PMW)&&(e+=", seq "+B.sequence);t.live_mode=e}!z.isGapless||Rh(v)&&z.Aq||(t.playback_categories+="Gapless ");t.playback_categories_style=t.playback_categories?"":"display:none";t.bandwidth_samples=$x(Q,"bandwidth");t.network_activity_samples=$x(Q,"networkactivity");t.live_latency_samples=$x(Q,"livelatency");t.buffer_health_samples=$x(Q,"bufferhealth");z=g.vS(v); if(v.cotn||z)t.cotn_and_local_media=(v.cotn?v.cotn:"null")+" / "+z;t.cotn_and_local_media_style=t.cotn_and_local_media?"":"display:none";kM(v,"web_player_release_debug")?(t.release_name="youtube.player.web_20250203_01_RC00",t.release_style=""):t.release_style="display:none";t.debug_info&&J.length>0&&t.debug_info.length+J.length<=60?t.debug_info+=" "+J:t.extra_debug_info=J;t.extra_debug_info_style=t.extra_debug_info&&t.extra_debug_info.length>0?"":"display:none";return t}; mCP=function(P){var v=/codecs="([^"]*)"/.exec(P.mimeType);return v&&v[1]?v[1]+" ("+P.itag+")":P.itag}; fX=function(P,v,l,e,h){g.O.call(this,{L:"div",D:"ytp-horizonchart"});this.j=v;this.sampleCount=l;this.Y=e;this.T=h;this.index=0;this.heightPx=-1;this.G=this.K=null;this.W=Math.round(P/l);this.element.style.width=this.W*this.sampleCount+"px";this.element.style.height=this.j+"em"}; gM=function(P,v){if(P.heightPx===-1){var l=null;try{l=g.l5("CANVAS"),P.K=l.getContext("2d")}catch(Q){}if(P.K){var e=P.W*P.sampleCount;P.G=l;P.G.width=e;P.G.style.width=e+"px";P.element.appendChild(P.G)}else for(P.sampleCount=Math.floor(P.sampleCount/4),P.W*=4,l=0;l