@ctrl/dom 0.3.12 → 0.3.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,50 +0,0 @@
1
- import{AsyncResource as e}from"node:async_hooks";import{clearTimeout as t,setTimeout as n}from"node:timers";import{addAbortListener as r}from"node:events";import{availableParallelism as i}from"node:os";var a=Object.defineProperty,__name=(e,t)=>a(e,`name`,{value:t,configurable:!0}),__exportAll=(e,t)=>{let n={};for(var r in e)a(n,r,{get:e[r],enumerable:!0});return t||a(n,Symbol.toStringTag,{value:`Module`}),n};const o=1,s=2,c=3,l=4,u=5,d=6,m=7,h=8,_=9,v=10,y=11,b=12,x=1,S=2,C=4,w=8,T=16,ee=32,E=`http://www.w3.org/1999/xhtml`,D=`http://www.w3.org/2000/svg`,te=`http://www.w3.org/1998/Math/MathML`,O=`http://www.w3.org/1999/xlink`,k=`http://www.w3.org/XML/1998/namespace`,ne=`http://www.w3.org/2000/xmlns/`,A=1,re=2,ie=4,ae=8,oe=16,se=32,ce=64,le=128,ue=256,de=512,fe=1024,pe=2048,me=4096,he=16384,ge=32768,_e=65536,ve=8192,ye=1<<17,be=1<<18,xe=1<<19,Se=1<<22,Ce=1<<20,we=1<<21,Te=3145728,Ee=1<<23,De=1<<24;function exposeMembers(...e){for(let t of e){let e=t.prototype;for(let t of Object.getOwnPropertyNames(e)){if(t===`constructor`||t.charCodeAt(0)===95)continue;let n=Object.getOwnPropertyDescriptor(e,t);!n.enumerable&&n.configurable&&Object.defineProperty(e,t,{enumerable:!0})}}}function defineInterfaceShape(e,t={}){Object.defineProperty(e.prototype,Symbol.toStringTag,{value:e.name,configurable:!0}),setLength(e,Object.hasOwn(t,`constructor`)?t.constructor:0);for(let n of[e.prototype,e])for(let e of Object.getOwnPropertyNames(n)){if(e===`constructor`||e===`prototype`||e===`length`||e===`name`)continue;let r=Object.getOwnPropertyDescriptor(n,e);typeof r.value==`function`&&setLength(r.value,Object.hasOwn(t,e)?t[e]:0)}}function defineConstants(e,t){for(let n of Object.keys(t)){let r={value:t[n],writable:!1,enumerable:!0,configurable:!1};Object.defineProperty(e,n,r),Object.defineProperty(e.prototype,n,r)}}function setLength(e,t){e.length!==t&&Object.defineProperty(e,"length",{value:t,configurable:!0})}function hideInternals(e){for(let t of Reflect.ownKeys(e))(typeof t==`symbol`||t.charCodeAt(0)===95)&&Oe.call(e,t)&&Object.defineProperty(e,t,{enumerable:!1})}const Oe=Object.prototype.propertyIsEnumerable;function defineHidden(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0,enumerable:!1})}function argumentsRequired(e,t,n,r){throw TypeError(`Failed to execute '${e}' on '${t}': ${n} argument${n===1?``:`s`} required, but only ${r} present.`)}const ke=globalThis.setTimeout,Ae=globalThis.clearTimeout,je=globalThis.setImmediate,Me=globalThis.queueMicrotask,Ne=process.nextTick,Pe=globalThis.performance,Fe=Pe.now.bind(Pe),Ie=process.getActiveResourcesInfo.bind(process),Le=Symbol(`ctrl-dom.clock`);var TimerRecord=class{id;due;seq;delay;repeat;callback;args;ref;index;clock;handle;real;realDue;context;constructor(t,n,r,i,a,o,s,c){this.id=n,this.due=r,this.seq=i,this.delay=a,this.repeat=o,this.callback=s,this.args=c,this.ref=!0,this.index=-1,this.clock=t,this.handle=new VirtualTimeout(t,this),this.real=null,this.realDue=0,this.context=new e(`Timeout`)}invoke(){this.args.length===0?this.context.runInAsyncScope(this.callback,this.handle):this.context.runInAsyncScope(Reflect.apply,null,this.callback,this.handle,this.args)}},FiredTimers=class{records=/* @__PURE__ */ new WeakMap};const Re=Symbol(`timerRecord`),ze=Symbol(`timerFired`),Be=Symbol(`timerCleared`);var VirtualTimeout=class{#e;#t;#n=!0;constructor(e,t){this.#e=t,this.#t=t.id}get[Re](){let e=this.#e;return e instanceof FiredTimers?e.records?.get(this):e??void 0}[ze](e,t){this.#e!==t&&(t.records.set(this,e),this.#e=t)}[Be](){this.#e instanceof FiredTimers&&this.#e.records?.delete(this),this.#e=null}ref(){this.#n=!0;let e=this[Re];return e?.clock._setRef(e,!0),this}unref(){this.#n=!1;let e=this[Re];return e?.clock._setRef(e,!1),this}hasRef(){return this.#n}get _destroyed(){let e=this[Re];return e===void 0||e.index===-1&&e.real===null}refresh(){let e=this[Re];return e?.clock._refresh(e),this}close(){return this[Re]?.clock.clear(this),this}[Symbol.toPrimitive](){return this.#t}[Symbol.dispose](){this[Re]?.clock.clear(this)}};function before(e,t){return e.due<t.due||e.due===t.due&&e.seq<t.seq}var VirtualClock=class{fired=null;skipped;epochOffset;skip;heap;indexed=null;nextId;seq;refCount;hostTimer;hostDue;hostRefd;continuation;driverScheduled;driverImmediate;idleTurns;disposed;ioTypes;ioBaseline;ioCounts;constructor(e={}){this.skipped=0,this.epochOffset=Date.now()-Fe(),this.skip=e.skip===!0,this.heap=[],this.nextId=1,this.seq=0,this.refCount=0,this.hostTimer=null,this.hostDue=1/0,this.hostRefd=!0,this.continuation=!1,this.driverScheduled=!1,this.driverImmediate=!1,this.idleTurns=0,this.disposed=!1,this.ioTypes=[],this.ioBaseline=[],this.skip&&(typeof process==`object`&&(process.stdin,process.stdout,process.stderr),countIO(this.ioTypes,this.ioBaseline)),this.ioCounts=Array(this.ioTypes.length).fill(0)}now(){return Fe()+this.skipped}epochNow(){return Math.floor(this.epochOffset+Fe()+this.skipped)}schedule(e,t,n,r){let i=Number(t)|0;i<1&&(i=1);let a=new TimerRecord(this,this.nextId++,this.now()+i,this.seq++,i,r,e,n);return this.disposed?(a.handle[Be](),a.handle):(this.indexed?.set(a.id,a),this.refCount++,this.push(a),this.armHost(),this.kickDriver(),a.handle)}get byId(){if(this.indexed!==null)return this.indexed;let e=/* @__PURE__ */ new Map;for(let t of this.heap)e.set(t.id,t);return this.indexed=e}clear(e){let t=e instanceof VirtualTimeout?e[Re]:typeof e==`number`?this.byId.get(e):void 0;return t===void 0||t.clock!==this||t.index===-1&&t.real===null?!1:(this.indexed?.delete(t.id),t.handle[Be](),t.ref&&this.refCount--,t.real!==null&&(Ae(t.real),t.real=null),t.index!==-1&&(this.remove(t),this.armHost()),!0)}skipIdle(e){let t=this.heap[0];return t!==void 0&&t.due<=this.now()+e?!1:(this.skipped+=e,!0)}get size(){return this.indexed?.size??this.heap.length}_setRef(e,t){if(e.ref===t)return;e.ref=t;let n=e.index!==-1||e.real!==null;n&&(this.refCount+=t?1:-1),n&&this.skip&&(!t&&e.index!==-1?this.toRealTrack(e,Math.max(0,e.due-this.now())):t&&e.real!==null&&this.toVirtualTrack(e)),this.updateHostRef()}toRealTrack(e,t){this.byId.set(e.id,e),e.index!==-1&&(this.remove(e),this.armHost()),e.realDue=Fe()+t;let n=ke(()=>this.fireReal(e),t);n.unref?.(),e.real=n}toVirtualTrack(e){Ae(e.real),e.real=null,e.due=this.now()+Math.max(0,e.realDue-Fe()),e.seq=this.seq++,this.push(e),this.armHost(),this.kickDriver()}fireReal(e){e.real=null,!this.disposed&&this.byId.has(e.id)&&(e.repeat?this.toRealTrack(e,e.delay):this.complete(e),e.invoke())}complete(e){this.indexed?.delete(e.id),e.handle[ze](e,this.fired??=new FiredTimers)}_refresh(e){if(!this.disposed){if(e.real!==null)Ae(e.real),e.real=null,this.toRealTrack(e,e.delay);else{if(e.index===-1){if(this.indexed?.set(e.id,e),e.ref)this.refCount++;else if(this.skip){this.toRealTrack(e,e.delay);return}}else this.remove(e);e.due=this.now()+e.delay,e.seq=this.seq++,this.push(e),this.armHost(),this.kickDriver()}}}clearAll(){this.fired!==null&&(this.fired.records=null,this.fired=null);for(let e of this.indexed?.values()??this.heap)e.real!==null&&Ae(e.real),e.real=null,e.handle[Be](),e.index=-1;this.hostTimer!==null&&Ae(this.hostTimer),this.hostTimer=null,this.hostDue=1/0,this.heap.length=0,this.indexed?.clear(),this.refCount=0}dispose(){this.disposed=!0,this.clearAll(),j===this&&(j=null)}armHost(){if(this.disposed||this.continuation)return;let e=this.heap[0];e===void 0?(this.hostTimer!==null&&Ae(this.hostTimer),this.hostTimer=null,this.hostDue=1/0):(this.hostTimer!==null&&this.hostDue===e.due||(this.hostTimer!==null&&Ae(this.hostTimer),this.hostDue=e.due,this.hostTimer=ke(this.onHostTimer,Math.max(0,e.due-this.now())),this.hostRefd=!0),this.updateHostRef())}updateHostRef(){let e=this.hostTimer,t=this.refCount>0;e!==null&&t!==this.hostRefd&&(this.hostRefd=t,t?e.ref?.():e.unref?.())}fireContinuation=()=>{this.fireNext()};onHostTimer=()=>{He=Fe(),this.hostTimer=null,this.hostDue=1/0,this.fireNext()};fireNext(){if(this.continuation=!1,this.disposed)return;let e=this.heap[0];if(e===void 0||e.due>this.now()+1){this.armHost();return}this.skip&&e.due>this.now()&&(this.skipped+=e.due-this.now()),this.pop(),e.repeat?(e.due=this.now()+e.delay,e.seq=this.seq++,this.push(e)):(this.complete(e),e.ref&&this.refCount--);let t=this.heap[0];t!==void 0&&t.due<=this.now()+ +!!this.skip?(this.continuation=!0,je(this.fireContinuation)):this.armHost(),e.invoke()}kickDriver(){!this.skip||this.driverScheduled||this.disposed||(this.driverScheduled=!0,this.driverImmediate=!0,je(this.driverTurn))}get ownImmediates(){return+!!this.driverImmediate+ +!!this.continuation}driverTurn=()=>{if(He=Fe(),this.driverScheduled=!1,this.driverImmediate=!1,this.disposed||this.heap.length===0){this.idleTurns=0;return}let e=this.busy();if(e!==null){this.idleTurns=0,e===`immediate`?this.kickDriver():(this.driverScheduled=!0,ke(()=>{this.driverScheduled=!1,this.kickDriver()},1));return}if(++this.idleTurns<2){this.kickDriver();return}this.idleTurns=0;let t=this.heap[0].due-this.now();t>0&&(this.skipped+=t),this.hostTimer!==null&&Ae(this.hostTimer),this.hostTimer=null,this.hostDue=1/0;try{this.fireNext()}finally{this.kickDriver()}};busy(e=0){let t=Ie(),n=this.ioTypes,r=this.ioBaseline,i=this.ioCounts;for(let e=0;e<i.length;e++)i[e]=0;let a=!1,o=0;for(let s=0;s<t.length;s++){let c=t[s];if(c===`Immediate`){if(++o>e)return`immediate`;continue}if(a||c===`Timeout`)continue;let l=0;for(;l<n.length&&n[l]!==c;)l++;(l===n.length||++i[l]>r[l])&&(a=!0)}return a?`io`:null}push(e){let t=this.heap;e.index=t.length,t.push(e),this.up(e.index)}pop(){let e=this.heap,t=e[0],n=e.pop();return t.index=-1,n!==t&&(e[0]=n,n.index=0,this.down(0)),t}remove(e){let t=this.heap,n=e.index,r=t.pop();e.index=-1,r!==e&&(t[n]=r,r.index=n,this.down(n),this.up(r.index))}up(e){let t=this.heap,n=t[e];for(;e>0;){let r=e-1>>1;if(!before(n,t[r]))break;t[e]=t[r],t[e].index=e,e=r}t[e]=n,n.index=e}down(e){let t=this.heap,n=t.length,r=t[e];for(;;){let i=2*e+1;if(i>=n)break;let a=i+1,o=a<n&&before(t[a],t[i])?a:i;if(!before(t[o],r))break;t[e]=t[o],t[e].index=e,e=o}t[e]=r,r.index=e}};function countIO(e,t){for(let n of Ie()){if(n===`Timeout`||n===`Immediate`)continue;let r=e.indexOf(n);r===-1?(e.push(n),t.push(1)):t[r]++}}let j=null;function clockNow(){return j===null?Fe():j.now()}function queueUserAgentTask(e){j===null?n(e,0):j.schedule(e,0,[],!1)}const Ve={setTimeout(e,t){return j===null?n(e,t):j.schedule(e,t,[],!1)},clearTimeout(e){j!==null&&j.clear(e)||t(e)}};function clockSkipping(){return j!==null}function skipIdleTime(e){return j===null||j.skipIdle(e)}function canSkipZeroDelayWait(e){let t=j;if(t===null||!isClockTimer(e.setTimeout))return!1;let n=e.setImmediate;if(typeof n!=`function`||n.clock!==void 0||n._isMockFunction===!0||t.busy(t.ownImmediates)!==null)return!1;let r=t.heap[0];return r===void 0||r.due>t.now()+1}function skipZeroDelayWait(e){return canSkipZeroDelayWait(e)&&j.skipIdle(1)}function isClockTimer(e){return j!==null&&typeof e==`function`&&e[Le]===j}function foreignImmediatesPending(){let e=Ie(),t=0;for(let n=0;n<e.length;n++)e[n]===`Immediate`&&t++;return t>(j===null?0:j.ownImmediates)}let He=0;function loopTurn(e){let t=j;t===null?realTurn(e):Me(()=>Ne(settleTurn,t,e))}function settleTurn(e,t){if(j===e&&Fe()-He<=1&&e.busy(e.ownImmediates)===null){let n=e.heap[0];if(n===void 0||n.due>e.now()){t();return}}realTurn(t)}function realTurn(e){je(()=>{He=Fe(),e()})}function clockSkipped(){return j===null?0:j.skipped}function clearActiveClockTimers(){j?.clearAll()}function clockStats(){return j===null?null:{skippedMs:j.skipped,pendingTimers:j.size}}function virtualDate(e,t){function Date(...n){if(new.target===void 0)return new t(e.epochNow()).toString();let r=n.length===0?new t(e.epochNow()):Reflect.construct(t,n,t);return new.target!==Date&&Object.setPrototypeOf(r,new.target.prototype),r}return Object.defineProperties(Date,{length:{value:7},prototype:{value:t.prototype,writable:!1},now:{value:()=>e.epochNow(),writable:!0,configurable:!0},parse:{value:t.parse,writable:!0,configurable:!0},UTC:{value:t.UTC,writable:!0,configurable:!0}}),Date}function virtualPerformance(e,t){let n=Object.create(Object.getPrototypeOf(t));for(let e=t;e!==null&&e!==Object.prototype;e=Object.getPrototypeOf(e))for(let r of Reflect.ownKeys(e)){if(r===`constructor`||r in n&&Object.hasOwn(n,r))continue;let i=Object.getOwnPropertyDescriptor(e,r);typeof i.value==`function`?Object.defineProperty(n,r,{value:i.value.bind(t),writable:!0,configurable:!0,enumerable:i.enumerable}):i.get!==void 0&&Object.defineProperty(n,r,{get:()=>Reflect.get(t,r),configurable:!0,enumerable:i.enumerable})}Object.defineProperty(n,"now",{value:()=>e.now(),writable:!0,configurable:!0,enumerable:!0});let r=t.mark.bind(t),i=t.measure.bind(t);return Object.defineProperty(n,"mark",{value:(t,n)=>r(t,n?.startTime===void 0?{...n,startTime:e.now()}:n),writable:!0,configurable:!0,enumerable:!0}),Object.defineProperty(n,"measure",{value:(t,n,r)=>{if(typeof n==`object`&&n){let r=n.end===void 0&&n.duration===void 0;return i(t,r?{...n,end:e.now()}:n)}return r===void 0?i(t,n===void 0?{end:e.now()}:{start:n,end:e.now()}):i(t,n,r)},writable:!0,configurable:!0,enumerable:!0}),n}function installClock(e,t){let n=/* @__PURE__ */ new Map,define=(e,r)=>{n.set(e,Object.getOwnPropertyDescriptor(t,e)),Object.defineProperty(t,e,{value:r,writable:!0,enumerable:!0,configurable:!0})},r=globalThis.clearInterval,i={setTimeout(t,n,...r){if(typeof t!=`function`)throw TypeError(`The "callback" argument must be of type function`);return e.disposed?0:e.schedule(t,n,r,!1)},setInterval(t,n,...r){if(typeof t!=`function`)throw TypeError(`The "callback" argument must be of type function`);return e.disposed?0:e.schedule(t,n,r,!0)},clearTimeout(t){t!=null&&(e.clear(t)||Ae(t))},clearInterval(t){t!=null&&(e.clear(t)||r(t))}};Object.defineProperty(i.setTimeout,Symbol.for(`nodejs.util.promisify.custom`),{value:(t,n)=>new Promise(r=>e.schedule(r,t,[n],!1))}),Object.defineProperty(i.setTimeout,Le,{value:e}),Object.defineProperty(i.setInterval,Le,{value:e});for(let e of[`setTimeout`,`setInterval`,`clearTimeout`,`clearInterval`])define(e,i[e]);return e.skip&&(define(`Date`,virtualDate(e,typeof t.Date==`function`?t.Date:Date)),define(`performance`,virtualPerformance(e,t.performance??Pe)),j=e),{clock:e,uninstall(){for(let[e,r]of n)r===void 0?delete t[e]:Object.defineProperty(t,e,r);n.clear(),j===e&&(j=null),e.dispose()}}}function toDOMString(e){if(typeof e==`string`)return e;if(typeof e==`symbol`)throw TypeError(`Cannot convert a Symbol value to a string`);return String(e)}function toDouble(e,t){let n=Number(e);if(!Number.isFinite(n))throw TypeError(`${t} is not a finite floating-point value.`);return n}function toFloat(e,t){let n=Math.fround(toDouble(e,t));if(!Number.isFinite(n))throw TypeError(`${t} is outside the range of a float.`);return n}function toLong(e){return Number(e)|0}function toUnsignedLong$1(e){return Number(e)>>>0}__name(toUnsignedLong$1,`toUnsignedLong`);function toShort(e){return Number(e)<<16>>16}function toUnsignedShort(e){return Number(e)&65535}const Ue=Symbol.for(`ctrl-dom._proto__`),We=Symbol.for(`ctrl-dom.aboutBase`),Ge=Symbol.for(`ctrl-dom.active`),Ke=Symbol.for(`ctrl-dom.assocGen`),qe=Symbol.for(`ctrl-dom.attr`),Je=Symbol.for(`ctrl-dom.attributes`),Ye=Symbol.for(`ctrl-dom.availableToElementInternals`),Xe=Symbol.for(`ctrl-dom.baseFor`),Ze=Symbol.for(`ctrl-dom.baseOverride`),Qe=Symbol.for(`ctrl-dom.baseURL`),$e=Symbol.for(`ctrl-dom.baseVersion`),et=Symbol.for(`ctrl-dom.benign`),M=Symbol.for(`ctrl-dom.block`),tt=Symbol.for(`ctrl-dom.blockParsed`),nt=Symbol.for(`ctrl-dom.blockText`),rt=Symbol.for(`ctrl-dom.byCtor`),it=Symbol.for(`ctrl-dom.byName`),at=Symbol.for(`ctrl-dom.cache`),ot=Symbol.for(`ctrl-dom.callback`),st=Symbol.for(`ctrl-dom.childNodes`),ct=Symbol.for(`ctrl-dom.childWindows`),lt=Symbol.for(`ctrl-dom.children`),ut=Symbol.for(`ctrl-dom.classList`),dt=Symbol.for(`ctrl-dom.clipboard`),ft=Symbol.for(`ctrl-dom.clonable`),pt=Symbol.for(`ctrl-dom.closed`),mt=Symbol.for(`ctrl-dom.compiled`),ht=Symbol.for(`ctrl-dom.compiledFor`),gt=Symbol.for(`ctrl-dom.condition`),_t=Symbol.for(`ctrl-dom.constructed`),vt=Symbol.for(`ctrl-dom.constructingEntryList`),yt=Symbol.for(`ctrl-dom.contentType`),bt=Symbol.for(`ctrl-dom.controlsCache`),xt=Symbol.for(`ctrl-dom.controlsDoc`),St=Symbol.for(`ctrl-dom.coll`),Ct=Symbol.for(`ctrl-dom.controlsVersion`),wt=Symbol.for(`ctrl-dom.cookieJar`),Tt=Symbol.for(`ctrl-dom.cookies`),Et=Symbol.for(`ctrl-dom.css`),Dt=Symbol.for(`ctrl-dom.current`),Ot=Symbol.for(`ctrl-dom.customElements`),kt=Symbol.for(`ctrl-dom.customValidity`),At=Symbol.for(`ctrl-dom.cx`),jt=Symbol.for(`ctrl-dom.data`),Mt=Symbol.for(`ctrl-dom.dataset`),Nt=Symbol.for(`ctrl-dom.declarative`),Pt=Symbol.for(`ctrl-dom.defaultNamespace`),Ft=Symbol.for(`ctrl-dom.defaultValueOverride`),It=Symbol.for(`ctrl-dom.delegatesFocus`),Lt=Symbol.for(`ctrl-dom.devicePixelRatio`),Rt=Symbol.for(`ctrl-dom.dirtiness`),N=Symbol.for(`ctrl-dom.control`),zt=Symbol.for(`ctrl-dom.disabled`),Bt=Symbol.for(`ctrl-dom.disallowModification`),Vt=Symbol.for(`ctrl-dom.derived`),Ht=Symbol.for(`ctrl-dom.doc`),Ut=Symbol.for(`ctrl-dom.dropEffect`),P=Symbol.for(`ctrl-dom.ec`),Wt=Symbol.for(`ctrl-dom.effectAllowed`),F=Symbol.for(`ctrl-dom.el`),Gt=Symbol.for(`ctrl-dom.elements`),Kt=Symbol.for(`ctrl-dom.entries`),I=Symbol.for(`ctrl-dom.eo`),qt=Symbol.for(`ctrl-dom.error`),Jt=Symbol.for(`ctrl-dom.externalFormNames`),Yt=Symbol.for(`ctrl-dom.file`),Xt=Symbol.for(`ctrl-dom.files`),Zt=Symbol.for(`ctrl-dom.fill`),Qt=Symbol.for(`ctrl-dom.filter`),$t=Symbol.for(`ctrl-dom.firingSubmissionEvents`),L=Symbol.for(`ctrl-dom.focused`),en=Symbol.for(`ctrl-dom.form`),tn=Symbol.for(`ctrl-dom.formControlsVersion`),nn=Symbol.for(`ctrl-dom.labelsVersion`),rn=Symbol.for(`ctrl-dom.controlNamesVersion`),an=Symbol.for(`ctrl-dom.nameBlanked`),sn=Symbol.for(`ctrl-dom.nameBlankedValue`),cn=Symbol.for(`ctrl-dom.formAttrSeen`),ln=Symbol.for(`ctrl-dom.forLabels`),un=Symbol.for(`ctrl-dom.forms`),dn=Symbol.for(`ctrl-dom.frameCallbacks`),fn=Symbol.for(`ctrl-dom.frameElement`),pn=Symbol.for(`ctrl-dom.frameId`),mn=Symbol.for(`ctrl-dom.frameTask`),hn=Symbol.for(`ctrl-dom.frameTime`),gn=Symbol.for(`ctrl-dom.generation`),_n=Symbol.for(`ctrl-dom.globalObject`),vn=Symbol.for(`ctrl-dom.height`),yn=Symbol.for(`ctrl-dom.history`),bn=Symbol.for(`ctrl-dom.home`),R=Symbol.for(`ctrl-dom.host`),xn=Symbol.for(`ctrl-dom.href`),Sn=Symbol.for(`ctrl-dom.id`),Cn=Symbol.for(`ctrl-dom.idleCallbacks`),wn=Symbol.for(`ctrl-dom.idleId`),Tn=Symbol.for(`ctrl-dom.ids`),z=Symbol.for(`ctrl-dom.impl`),En=Symbol.for(`ctrl-dom.implementation`),Dn=Symbol.for(`ctrl-dom.index`),On=Symbol.for(`ctrl-dom.indexed`),kn=Symbol.for(`ctrl-dom.inflight`),An=Symbol.for(`ctrl-dom.info`),jn=Symbol.for(`ctrl-dom.innerHeight`),Mn=Symbol.for(`ctrl-dom.innerWidth`),Nn=Symbol.for(`ctrl-dom.isHTML`),B=Symbol.for(`ctrl-dom.items`),Pn=Symbol.for(`ctrl-dom.keyText`),Fn=Symbol.for(`ctrl-dom.kind`),In=Symbol.for(`ctrl-dom.labels`),Ln=Symbol.for(`ctrl-dom.layerName`),Rn=Symbol.for(`ctrl-dom.list`),zn=Symbol.for(`ctrl-dom.listeners`),Bn=Symbol.for(`ctrl-dom.listenerTypesChanged`),Vn=Symbol.for(`ctrl-dom.localStorage`),Hn=Symbol.for(`ctrl-dom.location`),Un=Symbol.for(`ctrl-dom.lockedForReset`),Wn=Symbol.for(`ctrl-dom.matches`),Gn=Symbol.for(`ctrl-dom.media`),Kn=Symbol.for(`ctrl-dom.mediaQueryLists`),qn=Symbol.for(`ctrl-dom.mode`),Jn=Symbol.for(`ctrl-dom.name`),Yn=Symbol.for(`ctrl-dom.names`),Xn=Symbol.for(`ctrl-dom.namespaces`),Zn=Symbol.for(`ctrl-dom.navigator`),Qn=Symbol.for(`ctrl-dom.nodes`),$n=Symbol.for(`ctrl-dom.onchange`),V=Symbol.for(`ctrl-dom.options`),er=Symbol.for(`ctrl-dom.owner`),tr=Symbol.for(`ctrl-dom.ownerNode`),nr=Symbol.for(`ctrl-dom.ownerRule`),H=Symbol.for(`ctrl-dom.parent`),rr=Symbol.for(`ctrl-dom.parentRule`),ir=Symbol.for(`ctrl-dom.parentWindow`),ar=Symbol.for(`ctrl-dom.pastNames`),or=Symbol.for(`ctrl-dom.pointerBeforeReference`),sr=Symbol.for(`ctrl-dom.prefix`),cr=Symbol.for(`ctrl-dom.prelude`),lr=Symbol.for(`ctrl-dom.presentationStyle`),ur=Symbol.for(`ctrl-dom.pseudo`),dr=Symbol.for(`ctrl-dom.queries`),fr=Symbol.for(`ctrl-dom.radios`),pr=Symbol.for(`ctrl-dom.ranges`),mr=Symbol.for(`ctrl-dom.readonly`),hr=Symbol.for(`ctrl-dom.readyState`),gr=Symbol.for(`ctrl-dom.rebuildVersion`),_r=Symbol.for(`ctrl-dom.record`),vr=Symbol.for(`ctrl-dom.records`),yr=Symbol.for(`ctrl-dom.reference`),br=Symbol.for(`ctrl-dom.result`),xr=Symbol.for(`ctrl-dom.root`),U=Symbol.for(`ctrl-dom.rules`),Sr=Symbol.for(`ctrl-dom.running`),Cr=Symbol.for(`ctrl-dom.runningFrame`),W=Symbol.for(`ctrl-dom.sc`),wr=Symbol.for(`ctrl-dom.screen`),Tr=Symbol.for(`ctrl-dom.scrollRestoration`),Er=Symbol.for(`ctrl-dom.scrollX`),Dr=Symbol.for(`ctrl-dom.scrollY`),Or=Symbol.for(`ctrl-dom.selectedOptions`),kr=Symbol.for(`ctrl-dom.selectedness`),Ar=Symbol.for(`ctrl-dom.selection`),jr=Symbol.for(`ctrl-dom.selector`),Mr=Symbol.for(`ctrl-dom.serializable`),Nr=Symbol.for(`ctrl-dom.sessionStorage`),Pr=Symbol.for(`ctrl-dom.settled`),Fr=Symbol.for(`ctrl-dom.optionsTail`),Ir=Symbol.for(`ctrl-dom.optionsCount`),Lr=Symbol.for(`ctrl-dom.optionsOnly`),Rr=Symbol.for(`ctrl-dom.selectionEpoch`),G=Symbol.for(`ctrl-dom.shadowRoot`),zr=Symbol.for(`ctrl-dom.shed`),Br=Symbol.for(`ctrl-dom.sheet`),Vr=Symbol.for(`ctrl-dom.sheets`),Hr=Symbol.for(`ctrl-dom.slotAssignment`),K=Symbol.for(`ctrl-dom.so`),Ur=Symbol.for(`ctrl-dom.states`),Wr=Symbol.for(`ctrl-dom.style`),Gr=Symbol.for(`ctrl-dom.styleVersion`),Kr=Symbol.for(`ctrl-dom.supportsText`),qr=Symbol.for(`ctrl-dom.systemId`),Jr=Symbol.for(`ctrl-dom.target`),Yr=Symbol.for(`ctrl-dom.tasks`),Xr=Symbol.for(`ctrl-dom.templateContentsOwner`),Zr=Symbol.for(`ctrl-dom.timers`),Qr=Symbol.for(`ctrl-dom.title`),$r=Symbol.for(`ctrl-dom.transients`),ei=Symbol.for(`ctrl-dom.treeVersion`),ti=Symbol.for(`ctrl-dom.type`),ni=Symbol.for(`ctrl-dom.types`),ri=Symbol.for(`ctrl-dom.updating`),ii=Symbol.for(`ctrl-dom.updatingSelectedContent`),ai=Symbol.for(`ctrl-dom.uri`),q=Symbol.for(`ctrl-dom.url`),oi=Symbol.for(`ctrl-dom.userActivation`),si=Symbol.for(`ctrl-dom.userValidity`),ci=Symbol.for(`ctrl-dom.validity`),li=Symbol.for(`ctrl-dom.value`),J=Symbol.for(`ctrl-dom.version`),ui=Symbol.for(`ctrl-dom.visualViewport`),di=Symbol.for(`ctrl-dom.w`),fi=Symbol.for(`ctrl-dom.whatToShow`),pi=Symbol.for(`ctrl-dom.whenDefined`),mi=Symbol.for(`ctrl-dom.width`),Y=Symbol.for(`ctrl-dom.window`),hi=Symbol.for(`ctrl-dom.writeBuffer`),gi=Symbol.for(`ctrl-dom.x`),_i=Symbol.for(`ctrl-dom.xhr`),vi=Symbol.for(`ctrl-dom.y`),yi=Symbol.for(`ctrl-dom.z`);var EventState=class{flags;type;target;relatedTarget;currentTarget;eventPhase;pathStart;pathLength;touchTargets;timeStamp;constructor(e,t){this.flags=t,this.type=e,this.target=null,this.relatedTarget=null,this.currentTarget=null,this.eventPhase=0,this.pathStart=-1,this.pathLength=0,this.touchTargets=null,this.timeStamp=clockNow()}};function exposedPathItem(e){let t=X[e];return X[e+4]&16?exposedWindow(t):t}function exposedWindow(e){return e[_n]??e}const X=[],bi={top:0};let xi=!1;function withInternalConstruct(e){let t=xi;xi=!0;try{return e()}finally{xi=t}}function setInternalConstruct(e){let t=xi;return xi=e,t}function isInternalConstruct(){return xi}var Event=class{static NONE=0;static CAPTURING_PHASE=1;static AT_TARGET=2;static BUBBLING_PHASE=3;#e;isTrusted=!1;get _s(){return this.#e}constructor(e,t){if(arguments.length===0)throw TypeError(`Failed to construct '${new.target.name}': 1 argument required, but only 0 present.`);let n=toDOMString(e),r=32;if(t!=null){if(typeof t!=`object`&&typeof t!=`function`)throw TypeError(`Failed to construct '${new.target.name}': The provided value is not of type '${new.target.name}Init'.`);t.bubbles&&(r|=256),t.cancelable&&(r|=512),t.composed&&(r|=16)}this.#e=new EventState(n,r)}get type(){return this._s.type}get target(){return this._s.target}get srcElement(){return this._s.target}get currentTarget(){return this._s.currentTarget}get eventPhase(){return this._s.eventPhase}get bubbles(){return!!(this._s.flags&256)}get cancelable(){return!!(this._s.flags&512)}get composed(){return!!(this._s.flags&16)}get timeStamp(){return this._s.timeStamp}get defaultPrevented(){return!!(this._s.flags&4)}get returnValue(){return!(this._s.flags&4)}set returnValue(e){e||setCanceledFlag(this._s)}get cancelBubble(){return!!(this._s.flags&1)}set cancelBubble(e){e&&(this._s.flags|=1)}stopPropagation(){this._s.flags|=1}stopImmediatePropagation(){this._s.flags|=3}preventDefault(){setCanceledFlag(this._s)}composedPath(){let e=this._s,t=[],n=e.pathLength;if(n===0||e.pathStart<0)return t;let r=e.pathStart,i=e.currentTarget;if(i===null)return t;let a=0,o=0;for(let e=n-1;e>=0;e--){let t=r+e*5,n=X[t+4];if(n&2&&o++,exposedPathItem(t)===i){a=e;break}n&4&&o--}let s=o,c=o,l=[];for(let e=a-1;e>=0;e--){let t=r+e*5,n=X[t+4];n&2&&s++,s<=c&&l.push(exposedPathItem(t)),n&4&&(s--,s<c&&(c=s))}for(let e=l.length-1;e>=0;e--)t.push(l[e]);t.push(i),s=o,c=o;for(let e=a+1;e<n;e++){let n=r+e*5,i=X[n+4];i&4&&s++,s<=c&&t.push(exposedPathItem(n)),i&2&&(s--,s<c&&(c=s))}return t}initEvent(e,t=!1,n=!1){if(arguments.length===0)throw TypeError(`Failed to execute 'initEvent' on 'Event': 1 argument required, but only 0 present.`);this._s.flags&64||initializeEvent(this,toDOMString(e),!!t,!!n)}};Object.defineProperties(Event.prototype,{NONE:{value:0,enumerable:!0},CAPTURING_PHASE:{value:1,enumerable:!0},AT_TARGET:{value:2,enumerable:!0},BUBBLING_PHASE:{value:3,enumerable:!0},[Symbol.toStringTag]:{value:`Event`,configurable:!0}});function setCanceledFlag(e){(e.flags&520)==512&&(e.flags|=4)}function initializeEvent(e,t,n,r){let i=e._s,a=(i.flags|32)&-904;n&&(a|=256),r&&(a|=512),i.flags=a,e.isTrusted=!1,i.target=null,i.type=t}function setTrusted(e,t=!0){t?e._s.flags|=128:e._s.flags&=-129,e.isTrusted=t}function setToStringTag(e,t){Object.defineProperty(e.prototype,Symbol.toStringTag,{value:e.name,configurable:!0}),t!==void 0&&Object.defineProperty(e,"length",{value:t,configurable:!0})}setToStringTag(Event,1),exposeMembers(Event);const Si=/* @__PURE__ */ `abort.auxclick.beforeinput.beforematch.beforetoggle.blur.cancel.canplay.canplaythrough.change.click.close.command.contextlost.contextmenu.contextrestored.copy.cuechange.cut.dblclick.drag.dragend.dragenter.dragleave.dragover.dragstart.drop.durationchange.emptied.ended.error.focus.formdata.input.invalid.keydown.keypress.keyup.load.loadeddata.loadedmetadata.loadstart.mousedown.mouseenter.mouseleave.mousemove.mouseout.mouseover.mouseup.paste.pause.play.playing.progress.ratechange.reset.resize.scroll.scrollend.securitypolicyviolation.seeked.seeking.select.slotchange.stalled.submit.suspend.timeupdate.toggle.volumechange.waiting.webkitanimationend.webkitanimationiteration.webkitanimationstart.webkittransitionend.wheel.gotpointercapture.lostpointercapture.pointerdown.pointermove.pointerrawupdate.pointerup.pointercancel.pointerover.pointerout.pointerenter.pointerleave.touchstart.touchend.touchmove.touchcancel.animationstart.animationiteration.animationend.animationcancel.transitionrun.transitionstart.transitionend.transitioncancel.selectstart.selectionchange`.split(`.`),Ci=[`afterprint`,`beforeprint`,`beforeunload`,`hashchange`,`languagechange`,`message`,`messageerror`,`offline`,`online`,`pagehide`,`pagereveal`,`pageshow`,`pageswap`,`popstate`,`rejectionhandled`,`storage`,`unhandledrejection`,`unload`];let wi=0;function listenerSeqLimit(){return wi}var Listener=class{callback;flags;next;seq;id;constructor(e,t,n){this.callback=t,this.flags=n,this.next=null,this.seq=wi++,this.id=e}},SignalListener=class extends Listener{target;signal;ref;constructor(e,t,n,r,i){super(e,t,n|16),this.target=r,this.signal=i,this.ref=new AbortRef(this)}},AbortRef=class extends WeakRef{signal;previous=null;next;constructor(e){super(e);let t=e.signal;this.next=Ti.get(t)??null,this.next===null?this.signal=new WeakRef(t):(this.signal=this.next.signal,this.next.previous=this),Ti.set(t,this),Ei.register(e,this,this)}};const Ti=/* @__PURE__ */ new WeakMap,Ei=new FinalizationRegistry(e=>{let t=e.signal.deref();t!==void 0&&dropAbortStep(t,e)});function dropAbortStep(e,t){t.previous===null?t.next===null?(Ti.delete(e),e.removeEventListener(`abort`,runAbortSteps)):Ti.set(e,t.next):t.previous.next=t.next,t.next!==null&&(t.next.previous=t.previous),t.previous=t.next=null}function runAbortSteps(){if(!this.aborted){r(this,runAbortSteps);return}let e=Ti.get(this)??null;if(e!==null){for(;e.next!==null;)e=e.next;for(;e!==null;){let t=e.previous,n=e.deref();n!==void 0&&removeListener(n.target,n),e=t}}}function listenerAborted(e){return!!(e.flags&16)&&e.signal.aborted}const Di=/* @__PURE__ */ new Map;for(let e of[...Si,...Ci,`compositionend`,`compositionstart`,`compositionupdate`,`dragexit`,`encrypted`,`focusin`,`focusout`,`fullscreenchange`,`fullscreenerror`,`readystatechange`,`textInput`,`visibilitychange`,`webkitAnimationEnd`,`webkitAnimationIteration`,`webkitAnimationStart`,`webkitTransitionEnd`])Di.set(e,-1);let Oi=0;function idForType(e){let t=Di.get(e);return t===-1?(Di.set(e,Oi),Oi++):t??e}function typeIdOf(e){return Di.get(e)??e}function firstListener(e,t){if(!Array.isArray(e))return e.id===t?e:void 0;let n=e.length;if(n<=4){for(let r=0;r<n;r++)if(e[r].id===t)return e[r]}else return typeof t==`string`?e.custom?.get(t):t>>>0<n?e[t]:void 0}function setIndexedHead(e,t,n){typeof t==`number`?e[t]=n:n===void 0?e.custom?.delete(t)&&e.custom.size===0&&(e.custom=void 0):(e.custom??=/* @__PURE__ */ new Map).set(t,n)}function setFirstListener(e,t,n,r){if(!Array.isArray(t)){t.id===n?e[zn]=r:r!==void 0&&(e[zn]=[t,r]);return}let i=t.length;if(i>4)setIndexedHead(t,n,r);else{for(let a=0;a<i;a++)if(t[a].id===n){r===void 0?i===2?e[zn]=t[1-a]:t.splice(a,1):t[a]=r;return}if(r!==void 0){if(i<4){let n=Array(i+1);for(let e=0;e<i;e++)n[e]=t[e];n[i]=r,e[zn]=n}else{let i=[,,,,,];for(let e of t)setIndexedHead(i,e.id,e);setIndexedHead(i,n,r),e[zn]=i}}}}function eachHead(e,t){if(!Array.isArray(e))return t(e);for(let n of e)n!==void 0&&t(n);e.custom?.forEach(t)}function flattenCapture(e){return typeof e==`boolean`?e:e==null?!1:typeof e!=`object`&&typeof e!=`function`?!!e:!!e.capture}function defaultPassiveValue(e,t){if(e!==`touchstart`&&e!==`touchmove`&&e!==`wheel`&&e!==`mousewheel`)return!1;let n=t,r=n[z];if(r===void 0){let e=n.document;return e!=null&&e[Y]===t}if(r.type===9)return!0;let i=r.doc;return i.documentElement===t||i.body===t}function checkCallback(e,t){if(typeof e!=`function`&&(typeof e!=`object`||!e))throw TypeError(`Failed to execute '${t}' on 'EventTarget': parameter 2 is not of type 'Object'.`)}function addEventListener(e,t,n,r){if(r===null||typeof r!=`object`&&typeof r!=`function`){if(n==null)return;checkCallback(n,`addEventListener`),addFlattened(e,t,n,!!r,!1,null,null);return}let i=!!r.capture,a=!!r.once,o=r.passive,s=r.signal;if(s!==void 0){if(typeof s!=`object`||!s||typeof s.aborted!=`boolean`||typeof s.addEventListener!=`function`)throw TypeError(`Failed to execute 'addEventListener' on 'EventTarget': member signal is not of type 'AbortSignal'.`);if(s.aborted)return}n!=null&&(checkCallback(n,`addEventListener`),addFlattened(e,t,n,i,a,o===void 0?null:!!o,s??null))}function addFlattened(e,t,n,i,a,o,s){let c=+!!i,l=idForType(t),u=e[zn],d=u==null?void 0:firstListener(u,l);if(d!==void 0)for(;;){if(d.callback===n&&(d.flags&1)===c)return listenerAborted(d)?(removeListener(e,d),addFlattened(e,t,n,i,a,o,s)):void 0;let r=d.next;if(r===null)break;d=r}let m=c|(a?2:0)|((o===null?defaultPassiveValue(t,e):o)?4:0),h=s===null?new Listener(l,n,m):new SignalListener(l,n,m,e,s);d===void 0?u==null?e[zn]=h:setFirstListener(e,u,l,h):d.next=h,s!==null&&h.ref.next===null&&r(s,runAbortSteps),d===void 0&&e[Bn]?.()}function removeEventListener(e,t,n,r){let i=+!!flattenCapture(r);if(n==null)return;checkCallback(n,`removeEventListener`);let a=e[zn];if(a==null)return;let o=typeIdOf(t),s=null;for(let t=firstListener(a,o)??null;t!==null;s=t,t=t.next)if(t.callback===n&&(t.flags&1)===i){unlink$1(e,a,o,s,t);return}}function removeListener(e,t){if(t.flags&8)return;let n=e[zn];if(n!=null){let r=t.id,i=null;for(let a=firstListener(n,r)??null;a!==null;i=a,a=a.next)if(a===t){unlink$1(e,n,r,i,a);return}}t.flags|=8}function unlink$1(e,t,n,r,i){markRemoved(i),r===null?(setFirstListener(e,t,n,i.next??void 0),i.next===null&&e[Bn]?.()):r.next=i.next}__name(unlink$1,`unlink`);function markRemoved(e){if(e.flags|=8,e.flags&16){let t=e;Ei.unregister(t.ref),dropAbortStep(t.signal,t.ref)}}function removeAllEventListeners(e){let t=e[zn];t!=null&&(e[zn]=null,eachHead(t,e=>{for(let t=e;t!==null;t=t.next)markRemoved(t)}),e[Bn]?.())}function hasListeners(e,t){let n=e[zn];return n!=null&&firstListener(n,typeIdOf(t))!==void 0}function reusableElement(e,t){let n=e[z];return n===void 0||n.parent!==null||n.first!==null||n.attrs!==null||n.flags&2048||e[G]!=null?!1:listenerCount(e)===t}function listenerCount(e){let t=e[zn];if(t==null)return 0;let n=0;return eachHead(t,e=>{for(let t=e;t!==null;t=t.next)n++}),n}function hasAnyListener(e){let t=e[zn];if(t==null)return!1;let n=!1;return eachHead(t,()=>{n=!0}),n}const ki=/* @__PURE__ */ `.a.abbr.address.area.article.aside.audio.b.base.bdi.bdo.blockquote.body.br.button.canvas.caption.cite.code.col.colgroup.data.datalist.dd.del.details.dfn.dialog.div.dl.dt.em.embed.fieldset.figcaption.figure.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.iframe.img.input.ins.kbd.label.legend.li.link.main.map.mark.menu.meta.meter.nav.noscript.object.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.script.search.section.select.slot.small.source.span.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.title.tr.track.u.ul.var.video.wbr.svg.math.frame.frameset.noframes.marquee.font.center.dir.applet.basefont.bgsound.big.blink.keygen.listing.menuitem.nobr.noembed.param.plaintext.rb.rtc.strike.tt.xmp.image.selectedcontent`.split(`.`),Ai=/* @__PURE__ */ new Map;for(let e=1;e<ki.length;e++)Ai.set(ki[e],e);function tagId(e){return Ai.get(e)??0}function tagName(e){return ki[e]??``}const Z=Object.fromEntries(ki.map((e,t)=>[e,t])),ji=/* @__PURE__ */ new Uint8Array(256);for(let e of[Z.a,Z.area,Z.button,Z.input,Z.label,Z.summary])ji[e]=1;function mayHaveActivationBehavior(e){return ji[e]===1}const ifaceName=e=>typeof e==`string`?e:e.name;function requireArgs$1(e,t,n){if(e<t)throw TypeError(`Failed to construct '${ifaceName(n)}': ${t} argument${t>1?`s`:``} required, but only ${e} present.`)}__name(requireArgs$1,`requireArgs`);function dict(e,t){if(e==null)return null;if(typeof e!=`object`&&typeof e!=`function`)throw TypeError(`Failed to construct '${t}': The provided value is not of type '${t}Init'.`);return e}function isWindow(e){if(typeof e!=`object`||!e)return!1;let t=e;return t.window===e||t.document!=null&&t.document[Y]===e}function viewMember(e,t){if(e==null)return null;if(!isWindow(e))throw TypeError(`Failed to construct '${ifaceName(t)}': member view is not of type Window.`);return e}function targetMember(e){return e??null}const Mi=Object.freeze({}),Ni=/* @__PURE__ */ __name((e,t)=>e===void 0?t:toDOMString(e),`str`),Pi=/* @__PURE__ */ __name((e,t=0)=>e===void 0?t:toLong(e),`long`),Fi=/* @__PURE__ */ __name(e=>e===void 0?0:toUnsignedLong$1(e),`ulong`),double=(e,t,n,r=0)=>e===void 0?r:typeof e==`number`&&Number.isFinite(e)?e:toDouble(e,`Failed to construct '${ifaceName(n)}': member ${t}`),float=(e,t,n,r=0)=>{if(e===void 0)return r;if(typeof e==`number`){let t=Math.fround(e);if(Number.isFinite(t))return t}return toFloat(e,`Failed to construct '${ifaceName(n)}': member ${t}`)},Ii=[[`ctrlKey`,1],[`shiftKey`,2],[`altKey`,4],[`metaKey`,8],[`modifierAltGraph`,16],[`modifierCapsLock`,32],[`modifierFn`,64],[`modifierFnLock`,128],[`modifierHyper`,256],[`modifierNumLock`,512],[`modifierScrollLock`,1024],[`modifierSuper`,2048],[`modifierSymbol`,4096],[`modifierSymbolLock`,8192]];function modifiers(e){let t=0;return e.altKey&&(t|=4),e.ctrlKey&&(t|=1),e.metaKey&&(t|=8),e.modifierAltGraph&&(t|=16),e.modifierCapsLock&&(t|=32),e.modifierFn&&(t|=64),e.modifierFnLock&&(t|=128),e.modifierHyper&&(t|=256),e.modifierNumLock&&(t|=512),e.modifierScrollLock&&(t|=1024),e.modifierSuper&&(t|=2048),e.modifierSymbol&&(t|=4096),e.modifierSymbolLock&&(t|=8192),e.shiftKey&&(t|=2),t}function modifierState(e,t){let n;switch(t){case`Control`:n=1;break;case`Shift`:n=2;break;case`Alt`:n=4;break;case`Meta`:n=8;break;default:{let e=Ii.find(e=>e[0]===`modifier`+t);if(e===void 0)return!1;n=e[1]}}return(e&n)!==0}function legacyMods(e,t,n,r,i){let a=i&-16;return e&&(a|=1),t&&(a|=4),n&&(a|=2),r&&(a|=8),a}var UIEvent=class extends Event{#e;#t;#n;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t??Mi;this.#t=Pi(n.detail),this.#e=viewMember(n.view,new.target),this.#n=Fi(n.which)}get view(){return this.#e}get detail(){return this.#t}get which(){return this.#n}initUIEvent(e,t=!1,n=!1,r=null,i=0){if(arguments.length===0)throw TypeError(`Failed to execute 'initUIEvent' on 'UIEvent': 1 argument required, but only 0 present.`);if(r!=null&&!isWindow(r))throw TypeError(`Failed to execute 'initUIEvent' on '${this.constructor.name}': parameter 4 is not of type 'Window'.`);this._s.flags&64||(initializeEvent(this,toDOMString(e),!!t,!!n),this.#e=r??null,this.#t=toLong(i))}};setToStringTag(UIEvent,1);var FocusEvent=class extends UIEvent{constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this._s.relatedTarget=targetMember(t?.relatedTarget)}get relatedTarget(){return this._s.relatedTarget}};setToStringTag(FocusEvent,1);var MouseEvent=class extends UIEvent{#e;#t;#n;#r;#i;#a;#o;#s;#c;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t??Mi,r=new.target;this.#i=modifiers(n);let i=n.button;this.#a=i===void 0?0:toShort(i);let a=n.buttons;this.#o=a===void 0?0:toUnsignedShort(a),this.#n=double(n.clientX,`clientX`,r),this.#r=double(n.clientY,`clientY`,r),this.#s=double(n.movementX,`movementX`,r),this.#c=double(n.movementY,`movementY`,r);let o=this._s;o.relatedTarget=targetMember(n.relatedTarget),this.#e=double(n.screenX,`screenX`,r),this.#t=double(n.screenY,`screenY`,r),o.flags|=1024}get screenX(){return this.#e}get screenY(){return this.#t}get clientX(){return this.#n}get clientY(){return this.#r}get x(){return this.#n}get y(){return this.#r}get pageX(){return this.#n}get pageY(){return this.#r}get offsetX(){return this.#n}get offsetY(){return this.#r}get movementX(){return this.#s}get movementY(){return this.#c}get ctrlKey(){return!!(this.#i&1)}get shiftKey(){return!!(this.#i&2)}get altKey(){return!!(this.#i&4)}get metaKey(){return!!(this.#i&8)}get button(){return this.#a}get buttons(){return this.#o}get relatedTarget(){return this._s.relatedTarget}getModifierState(e){return modifierState(this.#i,toDOMString(e))}initMouseEvent(e,t=!1,n=!1,r=null,i=0,a=0,o=0,s=0,c=0,l=!1,u=!1,d=!1,m=!1,h=0,_=null){if(arguments.length===0)throw TypeError(`Failed to execute 'initMouseEvent' on 'MouseEvent': 1 argument required, but only 0 present.`);this._s.flags&64||(this.initUIEvent(e,t,n,r,i),this.#e=toLong(a),this.#t=toLong(o),this.#n=toLong(s),this.#r=toLong(c),this.#i=legacyMods(l,u,d,m,this.#i),this.#a=toShort(h),this._s.relatedTarget=targetMember(_))}};setToStringTag(MouseEvent,1);const Li=180/Math.PI,Ri=Object.freeze([]);function spherical2tilt(e,t){let n=0,r=0,i=Math.PI;if(e===0)(t===0||t===2*i)&&(n=i/2),t===i/2&&(r=i/2),t===i&&(n=-i/2),t===3*i/2&&(r=-i/2),t>0&&t<i/2&&(n=i/2,r=i/2),t>i/2&&t<i&&(n=-i/2,r=i/2),t>i&&t<3*i/2&&(n=-i/2,r=-i/2),t>3*i/2&&t<2*i&&(n=i/2,r=-i/2);else{let i=Math.tan(e);n=Math.atan(Math.cos(t)/i),r=Math.atan(Math.sin(t)/i)}return[Math.round(n*Li),Math.round(r*Li)]}function tilt2spherical(e,t){let n=e/Li,r=t/Li,i=0;e===0?t>0?i=Math.PI/2:t<0&&(i=3*Math.PI/2):t===0?e<0&&(i=Math.PI):Math.abs(e)===90||Math.abs(t)===90?i=0:(i=Math.atan2(Math.tan(r),Math.tan(n)),i<0&&(i+=2*Math.PI));let a;return a=Math.abs(e)===90||Math.abs(t)===90?0:e===0?Math.PI/2-Math.abs(r):t===0?Math.PI/2-Math.abs(n):Math.atan(1/Math.sqrt(Math.tan(n)**2+Math.tan(r)**2)),[a,i]}var PointerEvent=class extends MouseEvent{#e;#t;#n;#r;#i;#a;#o;#s;#c;#l;#u;#d;#f;#p;#m;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t??Mi,r=new.target,i=n.altitudeAngle,a=double(i,`altitudeAngle`,r,Math.PI/2),o=n.azimuthAngle,s=double(o,`azimuthAngle`,r,0),c=n.coalescedEvents;this.#p=c==null?Ri:Array.from(c),this.#n=double(n.height,`height`,r,1),this.#d=!!n.isPrimary,this.#f=Pi(n.persistentDeviceId),this.#e=Pi(n.pointerId),this.#u=Ni(n.pointerType,``);let l=n.predictedEvents;this.#m=l==null?Ri:Array.from(l),this.#r=float(n.pressure,`pressure`,r),this.#i=float(n.tangentialPressure,`tangentialPressure`,r);let u=n.tiltX,d=Pi(u),m=n.tiltY,h=Pi(m);this.#s=Pi(n.twist),this.#t=double(n.width,`width`,r,1);let _=u!==void 0||m!==void 0,v=i!==void 0||o!==void 0;_&&!v?[a,s]=tilt2spherical(d,h):v&&!_&&([d,h]=spherical2tilt(a,s)),this.#a=d,this.#o=h,this.#c=a,this.#l=s}get pointerId(){return this.#e}get width(){return this.#t}get height(){return this.#n}get pressure(){return this.#r}get tangentialPressure(){return this.#i}get tiltX(){return this.#a}get tiltY(){return this.#o}get twist(){return this.#s}get altitudeAngle(){return this.#c}get azimuthAngle(){return this.#l}get pointerType(){return this.#u}get isPrimary(){return this.#d}get persistentDeviceId(){return this.#f}getCoalescedEvents(){return this.#p.slice()}getPredictedEvents(){return this.#m.slice()}};setToStringTag(PointerEvent,1);var WheelEvent=class extends MouseEvent{static DOM_DELTA_PIXEL=0;static DOM_DELTA_LINE=1;static DOM_DELTA_PAGE=2;#e;#t;#n;#r;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t??Mi,r=new.target;this.#r=Fi(n.deltaMode),this.#e=double(n.deltaX,`deltaX`,r),this.#t=double(n.deltaY,`deltaY`,r),this.#n=double(n.deltaZ,`deltaZ`,r)}get deltaX(){return this.#e}get deltaY(){return this.#t}get deltaZ(){return this.#n}get deltaMode(){return this.#r}};setToStringTag(WheelEvent,1),Object.defineProperties(WheelEvent.prototype,{DOM_DELTA_PIXEL:{value:0,enumerable:!0},DOM_DELTA_LINE:{value:1,enumerable:!0},DOM_DELTA_PAGE:{value:2,enumerable:!0}});var DragEvent=class extends MouseEvent{#e;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=t?.dataTransfer??null}get dataTransfer(){return this.#e}};setToStringTag(DragEvent,1);var KeyboardEvent=class extends UIEvent{static DOM_KEY_LOCATION_STANDARD=0;static DOM_KEY_LOCATION_LEFT=1;static DOM_KEY_LOCATION_RIGHT=2;static DOM_KEY_LOCATION_NUMPAD=3;#e;#t;#n;#r;#i;#a;#o;#s;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t??Mi;this.#r=modifiers(n),this.#o=Fi(n.charCode),this.#t=Ni(n.code,``),this.#a=!!n.isComposing,this.#e=Ni(n.key,``),this.#s=Fi(n.keyCode),this.#n=Fi(n.location),this.#i=!!n.repeat}get key(){return this.#e}get code(){return this.#t}get location(){return this.#n}get ctrlKey(){return!!(this.#r&1)}get shiftKey(){return!!(this.#r&2)}get altKey(){return!!(this.#r&4)}get metaKey(){return!!(this.#r&8)}get repeat(){return this.#i}get isComposing(){return this.#a}get charCode(){return this.#o}get keyCode(){return this.#s}getModifierState(e){return modifierState(this.#r,toDOMString(e))}initKeyboardEvent(e,t=!1,n=!1,r=null,i=``,a=0,o=!1,s=!1,c=!1,l=!1){if(arguments.length===0)throw TypeError(`Failed to execute 'initKeyboardEvent' on 'KeyboardEvent': 1 argument required, but only 0 present.`);this._s.flags&64||(this.initUIEvent(e,t,n,r,0),this.#e=toDOMString(i),this.#n=toUnsignedLong$1(a),this.#r=legacyMods(o,s,c,l,this.#r))}};setToStringTag(KeyboardEvent,1),Object.defineProperties(KeyboardEvent.prototype,{DOM_KEY_LOCATION_STANDARD:{value:0,enumerable:!0},DOM_KEY_LOCATION_LEFT:{value:1,enumerable:!0},DOM_KEY_LOCATION_RIGHT:{value:2,enumerable:!0},DOM_KEY_LOCATION_NUMPAD:{value:3,enumerable:!0}});var InputEvent=class extends UIEvent{#e;#t;#n;#r;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t??Mi,r=n.data;this.#e=r==null?null:toDOMString(r),this.#r=n.dataTransfer??null,this.#n=Ni(n.inputType,``),this.#t=!!n.isComposing}get data(){return this.#e}get isComposing(){return this.#t}get inputType(){return this.#n}get dataTransfer(){return this.#r}};setToStringTag(InputEvent,1);var CompositionEvent=class extends UIEvent{#e;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=Ni((t??Mi).data,``)}get data(){return this.#e}initCompositionEvent(e,t=!1,n=!1,r=null,i=``){if(arguments.length===0)throw TypeError(`Failed to execute 'initCompositionEvent' on 'CompositionEvent': 1 argument required, but only 0 present.`);this._s.flags&64||(this.initUIEvent(e,t,n,r,0),this.#e=toDOMString(i))}};setToStringTag(CompositionEvent,1);var TextEvent=class extends UIEvent{#e;constructor(e,t){if(!isInternalConstruct())throw TypeError(`Illegal constructor`);super(e,t),this.#e=``}get data(){return this.#e}initTextEvent(e,t=!1,n=!1,r=null,i=`undefined`){this._s.flags&64||(this.initUIEvent(e,t,n,r,0),this.#e=toDOMString(i))}};setToStringTag(TextEvent,1);var Touch=class{#e;#t;#n;#r;#i;#a;#o;#s;#c;#l;#u;#d;#f;#p;#m;constructor(e){requireArgs$1(arguments.length,1,`Touch`);let t=dict(e,`Touch`);if(t===null||t.identifier===void 0)throw TypeError(`Failed to construct 'Touch': required member identifier is undefined.`);if(t.target===void 0)throw TypeError(`Failed to construct 'Touch': required member target is undefined.`);let n=`Touch`;this.#f=double(t.altitudeAngle,`altitudeAngle`,n),this.#p=double(t.azimuthAngle,`azimuthAngle`,n),this.#n=double(t.clientX,`clientX`,n),this.#r=double(t.clientY,`clientY`,n),this.#d=float(t.force,`force`,n),this.#e=toLong(t.identifier),this.#o=double(t.pageX,`pageX`,n),this.#s=double(t.pageY,`pageY`,n),this.#c=float(t.radiusX,`radiusX`,n),this.#l=float(t.radiusY,`radiusY`,n),this.#u=float(t.rotationAngle,`rotationAngle`,n),this.#i=double(t.screenX,`screenX`,n),this.#a=double(t.screenY,`screenY`,n),this.#t=t.target,this.#m=Ni(t.touchType,`direct`)}get identifier(){return this.#e}get target(){return this.#t}get clientX(){return this.#n}get clientY(){return this.#r}get screenX(){return this.#i}get screenY(){return this.#a}get pageX(){return this.#o}get pageY(){return this.#s}get radiusX(){return this.#c}get radiusY(){return this.#l}get rotationAngle(){return this.#u}get force(){return this.#d}get altitudeAngle(){return this.#f}get azimuthAngle(){return this.#p}get touchType(){return this.#m}};setToStringTag(Touch,1);var zi=class TouchList{#e;constructor(){if(!isInternalConstruct())throw TypeError(`Illegal constructor`);this.#e=[]}static _create(e){let t=isInternalConstruct()?new TouchList:withInternalConstruct(()=>new TouchList);t.#e=e;for(let n=0;n<e.length;n++)Object.defineProperty(t,n,{value:e[n],enumerable:!0,configurable:!0});return t}get length(){return this.#e.length}item(e){return this.#e[toUnsignedLong$1(e)]??null}[Symbol.iterator](){return this.#e[Symbol.iterator]()}};setToStringTag(zi);function touchSequence(e,t){if(e==null)return[];let n=Array.from(e);for(let e of n)if(e===null||typeof e!=`object`&&typeof e!=`function`)throw TypeError(`Failed to construct 'TouchEvent': Failed to read the '${t}' property from 'TouchEventInit': Failed to convert value to 'Touch'.`);return n}var TouchEvent=class extends UIEvent{#e;#t;#n;#r;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t??Mi;this.#r=modifiers(n),this.#n=zi._create(touchSequence(n.changedTouches,`changedTouches`)),this.#t=zi._create(touchSequence(n.targetTouches,`targetTouches`)),this.#e=zi._create(touchSequence(n.touches,`touches`)),this._s.flags|=2048}get touches(){return this.#e}get targetTouches(){return this.#t}get changedTouches(){return this.#n}get altKey(){return!!(this.#r&4)}get metaKey(){return!!(this.#r&8)}get ctrlKey(){return!!(this.#r&1)}get shiftKey(){return!!(this.#r&2)}getModifierState(e){return modifierState(this.#r,toDOMString(e))}_touchTargetList(){let e=[];for(let t of[this.#e,this.#t,this.#n])for(let n of t){let t=n.target;typeof t==`object`&&t&&e.push(t)}return e}};setToStringTag(TouchEvent,1);var ClipboardEvent=class extends Event{#e;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=t?.clipboardData??null}get clipboardData(){return this.#e}};setToStringTag(ClipboardEvent,1),exposeMembers(UIEvent,FocusEvent,MouseEvent,PointerEvent,WheelEvent,DragEvent,KeyboardEvent,InputEvent,CompositionEvent,TextEvent,Touch,zi,TouchEvent,ClipboardEvent);const get=(e,t)=>e?.[t],Bi=/* @__PURE__ */ __name((e,t,n=``)=>{let r=get(e,t);return r===void 0?n:toDOMString(r)},`str`),Vi=/* @__PURE__ */ __name((e,t)=>{let n=get(e,t);return n==null?null:toDOMString(n)},`nullableStr`),dbl=(e,t,n)=>{let r=get(e,t);return r===void 0?0:typeof r==`number`&&Number.isFinite(r)?r:toDouble(r,`Failed to construct '${n.name}': member ${t}`)};function required(e,t,n){let r=get(e,t);if(r===void 0)throw TypeError(`Failed to construct '${n}': required member ${t} is undefined.`);return r}var CustomEvent=class extends Event{#e;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t?.detail;this.#e=n===void 0?null:n}get detail(){return this.#e}initCustomEvent(e,t=!1,n=!1,r=null){if(arguments.length===0)throw TypeError(`Failed to execute 'initCustomEvent' on 'CustomEvent': 1 argument required, but only 0 present.`);this._s.flags&64||(initializeEvent(this,toDOMString(e),!!t,!!n),this.#e=r)}};setToStringTag(CustomEvent,1);var ErrorEvent=class extends Event{#e;#t;#n;#r;#i;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t;this.#e=Bi(n,`message`),this.#t=Bi(n,`filename`);let r=get(n,`lineno`),i=get(n,`colno`);this.#n=r===void 0?0:toUnsignedLong$1(r),this.#r=i===void 0?0:toUnsignedLong$1(i),this.#i=get(n,`error`)}get message(){return this.#e}get filename(){return this.#t}get lineno(){return this.#n}get colno(){return this.#r}get error(){return this.#i}};setToStringTag(ErrorEvent,1);var PromiseRejectionEvent=class extends Event{#e;#t;constructor(e,t){requireArgs$1(arguments.length,2,new.target);let n=required(t,`promise`,new.target.name);if(n===null||typeof n!=`object`&&typeof n!=`function`)throw TypeError(`Failed to construct '${new.target.name}': member promise is not an object.`);super(e,t),this.#e=n,this.#t=get(t,`reason`)}get promise(){return this.#e}get reason(){return this.#t}};setToStringTag(PromiseRejectionEvent,2);var MessageEvent=class extends Event{#e;#t;#n;#r;#i;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=t,r=get(n,`data`);this.#e=r===void 0?null:r,this.#t=Bi(n,`origin`),this.#n=Bi(n,`lastEventId`),this.#r=get(n,`source`)??null;let i=get(n,`ports`);this.#i=Object.freeze(i==null?[]:Array.from(i))}get data(){return this.#e}get origin(){return this.#t}get lastEventId(){return this.#n}get source(){return this.#r}get ports(){return this.#i}initMessageEvent(e,t=!1,n=!1,r=null,i=``,a=``,o=null,s=[]){this._s.flags&64||(initializeEvent(this,toDOMString(e),!!t,!!n),this.#e=r,this.#t=toDOMString(i),this.#n=toDOMString(a),this.#r=o,this.#i=Object.freeze(Array.from(s)))}};setToStringTag(MessageEvent,1);var ProgressEvent=class extends Event{#e;#t;#n;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=!!get(t,`lengthComputable`),this.#t=dbl(t,`loaded`,new.target),this.#n=dbl(t,`total`,new.target)}get lengthComputable(){return this.#e}get loaded(){return this.#t}get total(){return this.#n}};setToStringTag(ProgressEvent,1);var AnimationEvent=class extends Event{#e;#t;#n;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=Bi(t,`animationName`),this.#t=dbl(t,`elapsedTime`,new.target),this.#n=Bi(t,`pseudoElement`)}get animationName(){return this.#e}get elapsedTime(){return this.#t}get pseudoElement(){return this.#n}};setToStringTag(AnimationEvent,1);var TransitionEvent=class extends Event{#e;#t;#n;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=Bi(t,`propertyName`),this.#t=dbl(t,`elapsedTime`,new.target),this.#n=Bi(t,`pseudoElement`)}get propertyName(){return this.#e}get elapsedTime(){return this.#t}get pseudoElement(){return this.#n}};setToStringTag(TransitionEvent,1);var PopStateEvent=class extends Event{#e;#t;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t);let n=get(t,`state`);this.#e=n===void 0?null:n,this.#t=!!get(t,`hasUAVisualTransition`)}get state(){return this.#e}get hasUAVisualTransition(){return this.#t}};setToStringTag(PopStateEvent,1);var HashChangeEvent=class extends Event{#e;#t;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=Bi(t,`oldURL`),this.#t=Bi(t,`newURL`)}get oldURL(){return this.#e}get newURL(){return this.#t}};setToStringTag(HashChangeEvent,1);var PageTransitionEvent=class extends Event{#e;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=!!get(t,`persisted`)}get persisted(){return this.#e}};setToStringTag(PageTransitionEvent,1);var StorageEvent=class extends Event{#e;#t;#n;#r;#i;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=Vi(t,`key`),this.#t=Vi(t,`oldValue`),this.#n=Vi(t,`newValue`),this.#r=Bi(t,`url`),this.#i=get(t,`storageArea`)??null}get key(){return this.#e}get oldValue(){return this.#t}get newValue(){return this.#n}get url(){return this.#r}get storageArea(){return this.#i}initStorageEvent(e,t=!1,n=!1,r=null,i=null,a=null,o=``,s=null){this._s.flags&64||(initializeEvent(this,toDOMString(e),!!t,!!n),this.#e=r===null?null:toDOMString(r),this.#t=i===null?null:toDOMString(i),this.#n=a===null?null:toDOMString(a),this.#r=toDOMString(o),this.#i=s)}};setToStringTag(StorageEvent,1);var SubmitEvent=class extends Event{#e;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=get(t,`submitter`)??null}get submitter(){return this.#e}};setToStringTag(SubmitEvent,1);var FormDataEvent=class extends Event{#e;constructor(e,t){requireArgs$1(arguments.length,2,new.target);let n=required(t,`formData`,new.target.name);super(e,t),this.#e=n}get formData(){return this.#e}};setToStringTag(FormDataEvent,2);var ToggleEvent=class extends Event{#e;#t;#n;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=Bi(t,`oldState`),this.#t=Bi(t,`newState`),this.#n=get(t,`source`)??null}get oldState(){return this.#e}get newState(){return this.#t}get source(){return this.#n}};setToStringTag(ToggleEvent,1);var BeforeUnloadEvent=class extends Event{#e;constructor(e,t){if(!isInternalConstruct())throw TypeError(`Illegal constructor`);super(e,t),this.#e=``}get returnValue(){return this.#e}set returnValue(e){this.#e=toDOMString(e)}};setToStringTag(BeforeUnloadEvent,1);var CloseEvent=class extends Event{#e;#t;#n;constructor(e,t){requireArgs$1(arguments.length,1,new.target),super(e,t),this.#e=!!get(t,`wasClean`);let n=get(t,`code`);this.#t=n===void 0?0:toUnsignedShort(n),this.#n=Bi(t,`reason`)}get wasClean(){return this.#e}get code(){return this.#t}get reason(){return this.#n}};setToStringTag(CloseEvent,1),exposeMembers(CustomEvent,ErrorEvent,PromiseRejectionEvent,MessageEvent,ProgressEvent,AnimationEvent,TransitionEvent,PopStateEvent,HashChangeEvent,PageTransitionEvent,StorageEvent,SubmitEvent,FormDataEvent,ToggleEvent,BeforeUnloadEvent,CloseEvent);let Hi=null;function setCurrentWindow(e){Hi=e}function currentWindow(){if(Hi===null)throw TypeError(`No active @ctrl/dom window. Create one with createWindow().`);return Hi}function currentDocument(){return currentWindow().document}function currentWindowOrNull(){return Hi}function defaultUncaughtExceptionHandler(e){let t=typeof e==`object`&&e?e.stack:void 0;console.error(typeof t==`string`?t:`Uncaught ${String(e)}`)}let Ui=defaultUncaughtExceptionHandler;function setUncaughtExceptionHandler(e){Ui=e??defaultUncaughtExceptionHandler}const Wi=/* @__PURE__ */ new WeakSet;function windowFor(e){if(e!==null){let t=e;if(t[z]!==void 0)return t[z].doc[Y];let n=t.document;if(n!=null&&n[Y]===e)return e}try{return currentWindow()}catch{return null}}function parseLocation(e){let t=typeof e==`object`&&e?e.stack:void 0;if(typeof t==`string`){let e=t.split(`
2
- `);for(let t=1;t<e.length;t++){let n=/at (?:.+\s+)?\(?(.+?):(\d+):(\d+)\)?$/.exec(e[t].trim());if(n!==null)return{filename:n[1],lineno:Number(n[2]),colno:Number(n[3])}}}return{filename:``,lineno:0,colno:0}}function reportException$1(e,t){let n=windowFor(t);if(n===null||Wi.has(n)){Ui(e,null);return}let{filename:r,lineno:i,colno:a}=parseLocation(e),o=new ErrorEvent(`error`,{cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?e.message:`Uncaught ${String(e)}`,filename:r,lineno:i,colno:a,error:e});setTrusted(o),Wi.add(n);let s=!1;try{s=!dispatch(o,n)}finally{Wi.delete(n)}s||Ui(e,o)}__name(reportException$1,`reportException`);function noteChangeDispatch(e){switch(e.tag){case Z.input:case Z.textarea:case Z.select:e.node[si]=!0}}function hasUserValidity(e){switch(e.tag){case Z.input:case Z.textarea:case Z.select:return e.node[si]===!0}return!1}function setUserValidity(e,t){switch(e.tag){case Z.input:case Z.textarea:case Z.select:(t||hasUserValidity(e))&&(e.node[si]=t)}}let Gi;function getCurrentEvent(){return Gi}let Ki=null;function setPostDispatchHook(e){Ki=e}let qi=null;function setAssignedSlotLookup(e){qi=e}const Ji=[];function listenerHead(e,t){let n=e[zn];return n==null?void 0:firstListener(n,t)}function assignedSlot$1(e){if(qi===null)return null;let t=e.parent;return t===null||!(t.flags&512)||e.type!==1&&e.type!==3?null:qi(e)}__name(assignedSlot$1,`assignedSlot`);function isAssigned(e){return assignedSlot$1(e)!==null}function treeRoot$1(e){for(;e.parent!==null;)e=e.parent;return e}__name(treeRoot$1,`treeRoot`);function nodeParentOf(e,t,n){let r=e.parent;if(r!==null&&r.flags&512){let t=assignedSlot$1(e);if(t!==null)return t}if(e.flags&32){let r=n._s;if(!(r.flags&16)&&r.pathLength>0){let t=X[r.pathStart][z];if(t!==void 0&&treeRoot$1(t)===e)return null}return t[R]}return r?.node??null}function nodeGetTheParent(e,t){return nodeParentOf(e[z],e,t)}function isShadowIncludingInclusiveAncestor$4(e,t){let n=t;for(;n!==null;){if(n===e)return!0;if(n.parent!==null)n=n.parent;else if(n.flags&32){let e=n.node[R];n=e===null||e[z]===void 0?null:e[z]}else n=null}return!1}__name(isShadowIncludingInclusiveAncestor$4,`isShadowIncludingInclusiveAncestor`);function inShadowTree(e){if(e===null)return!1;let t=e[z];return t!==void 0&&!!(treeRoot$1(t).flags&32)}function retarget(e,t){for(;;){if(e===null)return null;let n=e[z];if(n===void 0)return e;let r=treeRoot$1(n);if(!(r.flags&32))return e;let i=t[z];if(i!==void 0&&isShadowIncludingInclusiveAncestor$4(r,i))return e;e=r.node[R]}}function retargetList(e,t){let n=[];for(let r=0;r<e.length;r++)n.push(retarget(e[r],t));return n}function isWindowInstance(e){return e[_n]!==void 0}function hasActivationBehavior(e,t){return t!==void 0&&mayHaveActivationBehavior(t.tag)&&e._hasActivationBehavior===!0}function appendToEventPath(e,t,n,r,i,a){let o=bi.top,s=0;a!==null&&a.flags&32&&(s|=1,e[z]===a&&e.mode===`closed`&&(s|=2)),i&&(s|=4),X[o]=e,t===null?X[o+1]=X[o+1-5]:(s|=8,X[o+1]=t),X[o+2]=n,X[o+3]=r,X[o+4]=s,bi.top=o+5}function appendLight(e){let t=bi.top;X.length<t+5&&growPath(t+5),X[t]=e,X[t+1]=X[t+1-5],X[t+4]=0,bi.top=t+5}function growPath(e){for(;X.length<e;)X.push(null)}function dispatch(e,t,n=!1){let r=e._s,i=t;r.flags|=64;let a=n?t.document??t:t,o=null,s,c=r.relatedTarget,l=inShadowTree(c),u=l?retarget(c,t):c,d=!1,m=bi.top,h=!1;try{if(t!==u||t===c){let n=r.flags&2048?e._touchTargetList():null;h=c===null&&n===null,r.pathStart=m,r.pathLength=0;let i=t[z],_=i===void 0?null:treeRoot$1(i),v=_,y=v!==null&&!!(v.flags&32),b=i===void 0&&isWindowInstance(t);appendToEventPath(t,b?exposedWindow(t):a,u,n===null?null:retargetList(n,t),!1,_),b&&(X[m+4]=X[m+4]|16),r.pathLength=1;let x=m,S=!!(r.flags&1024)&&r.type===`click`,C=!!(r.flags&256);S&&hasActivationBehavior(t,i)&&(o=t);let w=i!==void 0&&isAssigned(i),T=!1;i!==void 0&&r.type===`change`&&noteChangeDispatch(i);let ee=t,E=i;for(;;){let r,i,a;if(E===void 0||E.type===9)r=ee._getTheParent(e),i=r===null?void 0:r[z],a=!1;else{let t=E.parent;t!==null&&!(t.flags&512)?(r=t.node,i=t,a=!0):(r=nodeParentOf(E,ee,e),i=r===null?void 0:r[z],a=i!==void 0&&i===t)}if(r===null)break;let s=i===void 0?null:a?_:treeRoot$1(i);w&&(w=!1,s!==null&&s.flags&32&&s.node.mode===`closed`&&(T=!0)),i!==void 0&&isAssigned(i)&&(w=!0),u=l?retarget(c,r):c;let d=n===null?null:retargetList(n,r);if(i===void 0||v!==null&&(!y||isShadowIncludingInclusiveAncestor$4(v,i)))S&&C&&o===null&&hasActivationBehavior(r,i)&&(o=r),h&&(s===null||!(s.flags&32))?appendLight(r):appendToEventPath(r,null,u,d,T,s),i===void 0&&isWindowInstance(r)&&(X[bi.top-5+4]=X[bi.top-5+4]|16);else if(r===u)break;else t=r,v=s,y=v!==null&&!!(v.flags&32),S&&o===null&&hasActivationBehavior(t,i)&&(o=t),x=bi.top,appendToEventPath(r,t,u,d,T,s);ee=r,E=i,_=s,T=!1}let D=bi.top;r.pathLength=(D-m)/5;{let e=x;if(inShadowTree(X[e+1])||inShadowTree(X[e+2]))d=!0;else{let t=X[e+3];if(t!==null)for(let e=0;e<t.length;e++)inShadowTree(t[e])&&(d=!0)}}o!==null&&(s=o._legacyPreActivationBehavior?.());let te=typeIdOf(r.type),O=r.flags&128?legacyType(r.type):null;if(te===-1&&O!==null&&typeIdOf(O)!==-1&&(te=idForType(r.type)),te!==-1){let t=listenerSeqLimit(),n=!1;for(let t=D-5;t>=m;t-=5){let i=listenerHead(X[t],te);if(Ji[t]=i,(i!==void 0||O!==null)&&(r.eventPhase=X[t+4]&8?2:1,invoke$1(e,r,t,i,1,O),r.flags&1)){n=!0;break}}if(!n)for(let n=m;n<D;n+=5){let i=X[n+4];if(!(i&8)&&!C)continue;let a=listenerSeqLimit()===t?Ji[n]:listenerHead(X[n],te);if((a!==void 0||O!==null)&&(r.eventPhase=i&8?2:3,invoke$1(e,r,n,a,3,O),r.flags&1))break}}let k=C?D-5:x;r.target=X[k+1],r.relatedTarget=X[k+2],r.touchTargets=X[k+3]}}finally{for(let e=m,t=bi.top;e<t;e+=5)X[e]=null,X[e+1]=null,Ji[e]=void 0,h||(X[e+2]=null,X[e+3]=null);bi.top=m,r.eventPhase=0,r.currentTarget=null,r.pathStart=-1,r.pathLength=0,r.flags&=-76}if(d&&(r.target=null,r.relatedTarget=null,r.touchTargets=null),o!==null){let t=o;r.flags&4?t._legacyCanceledActivationBehavior?.(s):t._activationBehavior?.(e,s)}return Ki!==null&&Ki(e,i),!(r.flags&4)}function legacyType(e){switch(e){case`animationend`:return`webkitAnimationEnd`;case`animationiteration`:return`webkitAnimationIteration`;case`animationstart`:return`webkitAnimationStart`;case`transitionend`:return`webkitTransitionEnd`;default:return null}}function invoke$1(e,t,n,r,i,a){let o=X[n];if(t.target=X[n+1],t.relatedTarget=X[n+2],t.touchTargets=X[n+3],t.flags&1)return;let s=X[n+4],c=s&16?exposedWindow(o):o;t.currentTarget=c;let l=!!(s&1);if(!(r!==void 0&&innerInvoke(e,t,o,c,r,i,l))&&a!==null){let n=listenerHead(o,typeIdOf(a));if(n===void 0)return;let r=t.type;t.type=a;try{innerInvoke(e,t,o,c,n,i,l)}finally{t.type=r}}}__name(invoke$1,`invoke`);function innerInvoke(e,t,n,r,i,a,o){let s=!1,c=listenerSeqLimit();for(let l=i;l!==null&&l.seq<c;l=l.next){let i=l.flags;if(i&8||listenerAborted(l)||(s=!0,i&1?a!==1:a===1))continue;i&2&&removeListener(n,l);let c=Gi;o||(Gi=e),i&4&&(t.flags|=8);let u=l.callback;try{if(typeof u==`function`)u.call(r,e);else{let t=u.handleEvent;if(typeof t!=`function`)throw TypeError(`The provided callback is not a function and has no callable 'handleEvent' property.`);t.call(u,e)}}catch(e){reportException$1(e,n)}if(t.flags&=-9,Gi=c,t.flags&2)break}return s}var EventTarget=class{constructor(){}addEventListener(e,t,n){if(arguments.length<2)throw TypeError(`Failed to execute 'addEventListener' on 'EventTarget': 2 arguments required, but only ${arguments.length} present.`);addEventListener(this,typeof e==`string`?e:toDOMString(e),t,n)}removeEventListener(e,t,n){if(arguments.length<2)throw TypeError(`Failed to execute 'removeEventListener' on 'EventTarget': 2 arguments required, but only ${arguments.length} present.`);removeEventListener(this,typeof e==`string`?e:toDOMString(e),t,n)}dispatchEvent(e){if(!(e instanceof Event))throw TypeError(`Failed to execute 'dispatchEvent' on 'EventTarget': parameter 1 is not of type 'Event'.`);let t=e._s;if(!(t.flags&32))throw new DOMException(`Failed to execute 'dispatchEvent' on 'EventTarget': The event provided is uninitialized.`,`InvalidStateError`);if(t.flags&64||t.eventPhase!==0)throw new DOMException(`Failed to execute 'dispatchEvent' on 'EventTarget': The event is already being dispatched.`,`InvalidStateError`);return setTrusted(e,!1),dispatch(e,this)}_getTheParent(e){return null}};Object.defineProperty(EventTarget.prototype,Symbol.toStringTag,{value:`EventTarget`,configurable:!0}),exposeMembers(EventTarget);var AttrRare=class{name;ns;prefix;attr;constructor(e,t,n){this.name=e,this.ns=t,this.prefix=n,this.attr=null}},AttrRecord=class{localName;value;rare;constructor(e,t,n,r){this.localName=e,this.value=t,this.rare=n===null&&r===null?null:new AttrRare(r===null?e:r+`:`+e,n,r)}get name(){let e=this.rare;return e===null?this.localName:e.name}get ns(){let e=this.rare;return e===null?null:e.ns}get prefix(){let e=this.rare;return e===null?null:e.prefix}get attr(){let e=this.rare;return e===null?null:e.attr}set attr(e){if(this.rare===null){if(e===null)return;this.rare=new AttrRare(this.localName,null,null)}this.rare.attr=e}},NodeImpl=class{node;type;doc;parent;first;last;prev;next;childCount;flags;tag;name;ns;prefix;attrs;data;id;classes;cache;constructor(e,t,n){this.node=e,this.type=t,this.doc=n,this.parent=null,this.first=null,this.last=null,this.prev=null,this.next=null,this.childCount=0,this.flags=0,this.tag=0,this.name=``,this.ns=null,this.prefix=null,this.attrs=null,this.data=``,this.id=``,this.classes=null,this.cache=null}};function nextInTree(e,t){let n=e.first;return n===null?nextSkippingChildren(e,t):n}function nextSkippingChildren(e,t){let n=e;for(;n!==null&&n!==t;){let e=n.next;if(e!==null)return e;n=n.parent}return null}function previousInTree(e,t){if(e===t)return null;let n=e.prev;if(n===null)return e.parent;for(;n.last!==null;)n=n.last;return n}function nextElementInTree(e,t){let n=nextInTree(e,t);for(;n!==null&&n.type!==1;)n=nextInTree(n,t);return n}function firstElementChild(e){let t=e.first;for(;t!==null&&t.type!==1;)t=t.next;return t}function lastElementChild(e){let t=e.last;for(;t!==null&&t.type!==1;)t=t.prev;return t}function nextElementSibling(e){let t=e.next;for(;t!==null&&t.type!==1;)t=t.next;return t}function previousElementSibling(e){let t=e.prev;for(;t!==null&&t.type!==1;)t=t.prev;return t}function siblingPrecedes(e,t){if(t.next===null)return!0;if(t.prev===null)return!1;let n=e.next,r=e.prev;for(;n!==null&&r!==null;){if(n===t)return!0;if(r===t)return!1;n=n.next,r=r.prev}return r===null}function treeRoot(e){let t=e;for(;t.parent!==null;)t=t.parent;return t}function isInclusiveAncestor(e,t){if(e===t)return!0;let n=t.parent;if(n===e)return!0;if(n===null||e.first===null||e.parent===n||e.doc!==t.doc)return!1;for(let t=n.parent;t!==null;t=t.parent)if(t===e)return!0;return!1}function indexOf(e){if(e.next===null&&e.parent!==null)return e.parent.childCount-1;let t=0;for(let n=e.prev;n!==null;n=n.prev)t++;return t}function childAt(e,t){let n=e.childCount;if(t<0||t>=n)return null;if(t<n>>1){let n=e.first;for(let e=0;e<t;e++)n=n.next;return n}let r=e.last;for(let e=n-1;e>t;e--)r=r.prev;return r}function snapshotChildren(e,t=0,n=e.childCount){let r=Array(n-t),i=t===0?e.first:childAt(e,t);for(let e=0;e<r.length;e++)r[e]=i,i=i.next;return r}function relativeTreePosition(e,t){if(e===t)return 0;if(e.parent!==t.parent){let n=0;for(let r=e.parent;r!==null;r=r.parent){if(r===t)return 10;n++}for(let r=t.parent;r!==null;r=r.parent){if(r===e)return 20;n--}for(;n>0;n--)e=e.parent;for(;n<0;n++)t=t.parent;for(;e.parent!==t.parent;)e=e.parent,t=t.parent}return e.parent===null?1:siblingPrecedes(e,t)?4:2}function compareTreeOrder(e,t){let n=relativeTreePosition(e,t);return n===0?0:n&4?-1:1}let Yi=null;function setElementClassLookup(e){Yi=e}function createElementImpl(e,t,n,r){return new(Yi(t,n))(e,t,n,r)[z]}let Xi=!1,Zi=null;function setCEReactionsPending(e){Xi=e}function setCEReactionsFlush(e){Zi=e}function flushCEReactions(){Zi!==null&&Zi()}let Qi=null;function setCustomElementCreate(e){Qi=e}function createElementImplSync(e,t,n,r,i){if(Qi!==null){let a=Qi(e,t,n,r,i);if(a!==null)return a}return createElementImpl(e,t,n,r)}let $i=!1;function setCEActive(){$i=!0}let ea=null,ta=null;function setCustomElementCloneHooks(e,t){ea=e,ta=t}function createCloneElementImpl(e,t){return ea(e,t)}function ceParserCreated(e){ta(e)}function indexGetterTable(e,t,n=32){let r={proto:e,count:0,item:t};return ensureIndexGetters(r,n),r}function ensureIndexGetters(e,t){if(t<=e.count)return;let n=Math.max(t,e.count*2),r=e.item;for(let t=e.count;t<n;t++)Object.defineProperty(e.proto,t,{get(){return r(this,t)},enumerable:!1,configurable:!0});e.count=n}var CollectionIterator=class extends Iterator{#e;#t;#n;constructor(e,t){super(),this.#e=e,this.#t=0,this.#n=t}next(){let e=this.#e;if(e!==null){let t=this.#t,n=this.#n?e._snapshot():e;if(t<n.length)return this.#t=t+1,{value:n[t],done:!1};this.#e=null}return{value:void 0,done:!0}}};Object.defineProperty(CollectionIterator.prototype,Symbol.toStringTag,{value:`Array Iterator`,configurable:!0});function iterableTarget(e){if(e==null)throw TypeError(`values method called on null or undefined`);return Object(e)}const na=Array.prototype.forEach,ra={forEach(e,t){if(this===null||this===void 0)return na.call(this,e,t);let n=Object(this),r=Math.min(Math.max(Math.trunc(Number(n.length))||0,0),2**53-1);if(typeof e!=`function`)na.call(n,e,t);else for(let i=0;i<r;i++)i in n&&e.call(t,n[i],i,n)}}.forEach,ia=/* @__PURE__ */ new WeakMap;function lazyItem(e,t){let n=e._snapshot();return t<n.length?n[t]:void 0}var aa=class NodeList{#e;#t;#n;constructor(e,t){this.#e=e,this.#t=0;let n=new.target!==NodeList;this.#n=n,n&&!ia.has(new.target.prototype)&&ia.set(new.target.prototype,indexGetterTable(new.target.prototype,lazyItem,64))}static _static(e){let t=new NodeList(null),n=e.length;for(let r=0;r<n;r++)t[r]=e[r];return t.#t=n,t}static _isNodeList(e){return e!==null&&#t in e}static _staticFromImpls(e){let t=new NodeList(null),n=e.length;for(let r=0;r<n;r++)t[r]=e[r].node;return t.#t=n,t}static _live(e){let t=new NodeList(e);return e.flags|=256,t.#r(),t}#r(){let e=this,t=this.#e,n=0;for(let r=t.first;r!==null;r=r.next)e[n++]=r.node;let r=this.#t;for(let t=n;t<r;t++)delete e[t];this.#t=n}static _appended(e,t){e[e.#t++]=t}static _popped(e){delete e[--e.#t]}static _rebuild(e){e.#e!==null&&e.#r()}_snapshot(){let e=this.#t,t=Array(e);for(let n=0;n<e;n++)t[n]=this[n];return t}get length(){if(this.#n){let e=this._snapshot().length,t=ia.get(Object.getPrototypeOf(this));return e>t.count&&ensureIndexGetters(t,e),e}return this.#t}item(e){let t=Number(e)>>>0;return this.#n?this._snapshot()[t]??null:t<this.#t?this[t]:null}static _values(e){let t=iterableTarget(e);return new CollectionIterator(t,#n in t&&t.#n)}};const oa={values(){return aa._values(this)}}.values;Object.defineProperties(aa.prototype,{forEach:{value:ra,writable:!0,enumerable:!0,configurable:!0},entries:{value:Array.prototype.entries,writable:!0,enumerable:!0,configurable:!0},keys:{value:Array.prototype.keys,writable:!0,enumerable:!0,configurable:!0},values:{value:oa,writable:!0,enumerable:!0,configurable:!0},[Symbol.iterator]:{value:oa,writable:!0,configurable:!0},[Symbol.toStringTag]:{value:`NodeList`,configurable:!0}});function recordNodeList(e){if(Array.isArray(e))return aa._staticFromImpls(e);let t=new aa(null);return e!==null&&aa._appended(t,e.node),t}var sa=class MutationRecord{#e;#t;#n;#r;#i;#a;#o;#s;#c;constructor(e,t,n,r,i,a,o,s,c){if(new.target!==MutationRecord||arguments.length===0)throw TypeError(`Illegal constructor`);this.#e=e,this.#t=t,this.#n=n,this.#r=r,this.#i=i,this.#a=a,this.#o=o,this.#s=s,this.#c=c}get type(){return this.#e}get target(){return this.#t.node}get addedNodes(){return aa._isNodeList(this.#a)||(this.#a=recordNodeList(this.#a)),this.#a}get removedNodes(){return aa._isNodeList(this.#o)||(this.#o=recordNodeList(this.#o)),this.#o}get previousSibling(){let e=this.#s;return e===null?null:e.node}get nextSibling(){let e=this.#c;return e===null?null:e.node}get attributeName(){return this.#n}get attributeNamespace(){return this.#r}get oldValue(){return this.#i}};Object.defineProperty(sa.prototype,Symbol.toStringTag,{value:`MutationRecord`,configurable:!0});let ca=0,la=0;var ObservedNode=class extends WeakRef{nodes;subtree;constructor(e,t,n){super(e),this.nodes=t,this.subtree=n,t.size===0&&ca++,t.add(this),n&&la++}};function forgetNode(e){e.nodes.delete(e),e.nodes.size===0&&ca--,e.subtree&&la--}const ua=new FinalizationRegistry(forgetNode);var RegisteredObserver=class{observer;options;source;target;constructor(e,t,n,r){this.observer=t,this.options=n,this.source=r,this.target=new ObservedNode(e,t[Qn],n.subtree),r===null?ua.register(e,this.target,this.target):(t[$r]??=[]).push(this)}updateOptions(e){this.target.subtree!==e.subtree&&(la+=e.subtree?1:-1,this.target.subtree=e.subtree),this.options=e}},NormalizedOptions=class{childList;attributes;characterData;subtree;attributeOldValue;characterDataOldValue;attributeFilter;constructor(e,t,n){this.childList=!!e.childList,this.attributes=t,this.characterData=n,this.subtree=!!e.subtree,this.attributeOldValue=!!e.attributeOldValue,this.characterDataOldValue=!!e.characterDataOldValue,this.attributeFilter=e.attributeFilter===void 0?null:Array.from(e.attributeFilter,String)}};const da=/* @__PURE__ */ new WeakMap;function registeredObserverList(e){return e.flags&2048?da.get(e)??null:null}function addRegistration(e,t){let n=registeredObserverList(e);n===null&&(n=[],da.set(e,n),e.flags|=pe),n.push(t)}function removeRegistration(e){let t=e.deref();if(t!==void 0){let n=da.get(t),r=n.findIndex(t=>t.target===e);n.splice(r,1),n.length===0&&(da.delete(t),t.flags&=-2049)}ua.unregister(e),forgetNode(e)}let fa=[],pa=[],ma=!1;function queueMutationRecord(e,t,n,r,i,a,o,s,c){let l=null,u=null,d=null,m=null,h=la!==0;for(let a=t;a!==null;a=h?a.parent:null){if(!(a.flags&2048))continue;let o=da.get(a);if(o!==void 0)for(let s=0;s<o.length;s++){let c=o[s],h=c.options;if(a!==t&&!h.subtree)continue;if(e===0){if(!h.attributes)continue;let e=h.attributeFilter;if(e!==null&&(r!==null||!e.includes(n)))continue}else if(e===1){if(!h.characterData)continue}else if(!h.childList)continue;let _=c.observer,v=e===0&&h.attributeOldValue||e===1&&h.characterDataOldValue;if(l===null||l===_){l=_,v&&(u=i);continue}d===null&&(d=[],m=[]);let y=d.indexOf(_);y===-1&&(y=d.length,d.push(_),m.push(null)),v&&(m[y]=i)}}if(l===null)return;let _=e===0?`attributes`:e===1?`characterData`:`childList`,v=1+(d?.length??0);for(let e=0;e<v;e++){let i=e===0?l:d[e-1],h=new sa(_,t,n,r,e===0?u:m[e-1],a,o,s,c),v=i[vr];v.length===0&&!fa.includes(i)&&fa.push(i),v.push(h)}queueMutationObserverMicrotask()}function queueTreeMutationRecord(e,t,n,r,i){queueMutationRecord(2,e,null,null,null,t,n,r,i)}function queueAttributeMutationRecord(e,t,n,r){queueMutationRecord(0,e,t,n,r,null,null,null,null)}function queueCharacterDataMutationRecord(e,t){queueMutationRecord(1,e,null,null,t,null,null,null,null)}function addTransientObservers(e,t){if(la!==0)for(let n=e;n!==null;n=n.parent){if(!(n.flags&2048))continue;let e=da.get(n);if(e!==void 0)for(let n=0;n<e.length;n++){let r=e[n];if(!r.options.subtree)continue;let i=r.observer,a=r.source??r;hasTransientWithSource(t,a)||(addRegistration(t,new RegisteredObserver(t,i,a.options,a)),fa.includes(i)||fa.push(i),queueMutationObserverMicrotask())}}}function hasTransientWithSource(e,t){let n=registeredObserverList(e);if(n===null)return!1;for(let e=0;e<n.length;e++)if(n[e].source===t)return!0;return!1}function signalSlotChange(e){pa.includes(e)||pa.push(e),queueMutationObserverMicrotask()}function queueMutationObserverMicrotask(){ma||(ma=!0,queueMicrotask(notifyMutationObservers))}function notifyMutationObservers(){ma=!1;let e=fa;fa=[],e.length>1&&e.sort((e,t)=>e[Sn]-t[Sn]);let t=pa;pa=[];for(let t=0;t<e.length;t++){let n=e[t],r=n[vr];if(n[vr]=[],removeTransientRegistrations(n),r.length!==0)try{n[ot].call(n,r,n)}catch(e){reportException$1(e,null)}}for(let e=0;e<t.length;e++)t[e].node.dispatchEvent(new Event(`slotchange`,{bubbles:!0}))}function removeTransientRegistrations(e,t){let n=e[$r];if(n===null)return;let r=0;for(let e of n)t===void 0||e.source===t?removeRegistration(e.target):n[r++]=e;r===0?e[$r]=null:n.length=r}function dropPending(e){let t=fa.indexOf(e);t!==-1&&fa.splice(t,1)}let ha=0,ga=0,_a=[];function homeOf(e){return e.doc}function file(e,t){let n=e[pr];n===null?n=e[pr]={refs:[],sweepAt:64}:n.refs.length>=n.sweepAt&&(compact(e,n),n.sweepAt=Math.max(64,n.refs.length*2)),n.refs.push(t),ha++}function markBoundary(e){e.flags&1048576||(e.flags|=Ce,e.parent!==null&&markRangeAncestors(e.parent))}function markRangeAncestors(e){for(let t=e;t!==null&&!(t.flags&2097152);t=t.parent)t.flags|=we}function registerLiveRange(e){markBoundary(e[W]),markBoundary(e[P]);let t=homeOf(e[W]);e[bn]=t,file(t,new WeakRef(e))}function retireLiveRange(e){e[bn]=null}function refileRange(e){markBoundary(e[W]),markBoundary(e[P]);let t=homeOf(e[W]);e[bn]!==t&&e[bn]!==null&&(e[bn]=t,file(t,new WeakRef(e)))}let va=64;function registerNodeIterator(e){if(_a.length>=va){let e=0;for(let t=0;t<_a.length;t++)_a[t].deref()!==void 0&&(_a[e++]=_a[t]);_a.length=e,va=Math.max(64,e*2)}_a.push(new WeakRef(e)),ga=_a.length}function compact(e,t,n){let r=t.refs,i=0;for(let t=0;t<r.length;t++){let a=r[t].deref();a!==void 0&&a[bn]===e&&(r[i++]=r[t],n?.(a))}ha-=r.length-i,r.length=i}function updateLiveRanges(e,t){let n=homeOf(e),r=n[pr];if(r===null)return;compact(n,r,t);let i=r.refs.length;i===0?n[pr]=null:r.sweepAt>64&&i*4<r.sweepAt&&(r.sweepAt=Math.max(64,i*2))}function rangesAdopt(e,t){let n=t,r=homeOf(e),i=n[pr];if(i===null||n===r)return;let a=i.refs,o=0;for(let t=0;t<a.length;t++){let i=a[t].deref();i===void 0||i[bn]!==n?ha--:isInclusiveAncestor(e,i[W])||isInclusiveAncestor(e,i[P])?(i[bn]=r,ha--,file(r,a[t])):a[o++]=a[t]}a.length=o,o===0&&(n[pr]=null)}function offsetAfterChild(e,t,n){return e>0&&(e===t.childCount||e>n())}function rangesAfterInsert(e,t,n){let r,getIndex=()=>r??=indexOf(t);updateLiveRanges(e,t=>{t[W]===e&&offsetAfterChild(t[K],e,getIndex)&&(t[K]+=n),t[P]===e&&offsetAfterChild(t[I],e,getIndex)&&(t[I]+=n)})}function rangesBeforeRemove(e,t){let n,getIndex=()=>n??=indexOf(e),r=!!(e.flags&we);updateLiveRanges(t,n=>{let i=n[W],a=n[P],o=i===e||r&&isInclusiveAncestor(e,i),s=i===a?o:a===e||r&&isInclusiveAncestor(e,a);(o||s)&&markBoundary(t),o?(n[W]=t,n[K]=getIndex()):i===t&&offsetAfterChild(n[K],t,getIndex)&&n[K]--,s?(n[P]=t,n[I]=getIndex()):a===t&&offsetAfterChild(n[I],t,getIndex)&&n[I]--})}function rangesReplaceData(e,t,n,r){let i=t+n;updateLiveRanges(e,a=>{a[W]===e&&a[K]>t&&a[K]<=i&&(a[K]=t),a[P]===e&&a[I]>t&&a[I]<=i&&(a[I]=t),a[W]===e&&a[K]>i&&(a[K]+=r-n),a[P]===e&&a[I]>i&&(a[I]+=r-n)})}function rangesSplitText(e,t,n,r){let i;updateLiveRanges(e,a=>{a[W]===e&&a[K]>n&&(a[W]=t,a[K]-=n,markBoundary(t)),a[P]===e&&a[I]>n&&(a[P]=t,a[I]-=n,markBoundary(t)),(a[W]===r||a[P]===r)&&(i??=indexOf(e)+1,a[W]===r&&a[K]===i&&a[K]++,a[P]===r&&a[I]===i&&a[I]++)})}function rangesNormalizeMerge(e,t,n){let r=t.parent,i;updateLiveRanges(e,a=>{(a[W]===r||a[P]===r)&&(i??=indexOf(t)),a[W]===t?(a[K]+=n,a[W]=e):a[W]===r&&a[K]===i&&(a[W]=e,a[K]=n),a[P]===t?(a[I]+=n,a[P]=e):a[P]===r&&a[I]===i&&(a[P]=e,a[I]=n),(a[W]===e||a[P]===e)&&markBoundary(e)})}function iteratorsBeforeRemove(e){let t=0,n=e.doc;for(let r=0;r<_a.length;r++){let i=_a[r].deref();i!==void 0&&(_a[t++]=_a[r],i[xr].doc===n&&(preRemovingSteps(i,i,e),i[kn]!==null&&preRemovingSteps(i,i[kn],e)))}_a.length=t,ga=t}function preRemovingSteps(e,t,n){if(!isInclusiveAncestor(n,t[yr])||isInclusiveAncestor(n,e[xr]))return;if(t[or]){let r=nextSkippingChildren(n,e[xr]);if(r!==null){t[yr]=r;return}t[or]=!1}let r=n.prev;if(r===null)t[yr]=n.parent;else{let e=r;for(;e.last!==null;)e=e.last;t[yr]=e}}const ya=/* @__PURE__ */ new WeakMap;function noteInlineStyle(e,t){ya.set(e,(ya.get(e)??0)+t)}function inlineStyleCount(e){return ya.get(e)??0}var ShadowAttributeUses=class{counts=/* @__PURE__ */ new Map;collected=new FinalizationRegistry(e=>this.remove(e));remove(e){for(let t of e){let e=this.counts.get(t);e===1?this.counts.delete(t):this.counts.set(t,e-1)}}},ShadowAttributeNames=class extends Set{uses;constructor(e,t){super(),this.uses=e,e.collected.register(t,this,this)}add(e){return this.has(e)||(this.uses.counts.set(e,(this.uses.counts.get(e)??0)+1),super.add(e)),this}release(){this.uses.collected.unregister(this),this.uses.remove(this)}};function ariaOrData(e){if(e.length<6||e.charCodeAt(4)!==45)return!1;let t=e.charCodeAt(0);return t===97?e.charCodeAt(1)===114&&e.charCodeAt(2)===105&&e.charCodeAt(3)===97:t===100&&e.charCodeAt(1)===97&&e.charCodeAt(2)===116&&e.charCodeAt(3)===97}let ba=!1;function noteStyleRecordCached(){ba=!0}function styleBlindAttribute(e,t){if(!ariaOrData(t))return!1;let n=e[Et];return!n?.main.index?.attributeNames?.has(t)&&!n?.shadowAttributeUses?.counts.has(t)}const xa=[`hidden`,`text`,`search`,`tel`,`url`,`email`,`password`,`date`,`month`,`week`,`time`,`datetime-local`,`number`,`range`,`color`,`checkbox`,`radio`,`file`,`submit`,`image`,`reset`,`button`],Sa=/* @__PURE__ */ new Map;for(let e=0;e<xa.length;e++)Sa.set(xa[e],e);function inputTypeFromAttr(e){if(e===null)return 1;let t=Sa.get(e);return t===void 0?Sa.get(asciiLowercase$1(e))??1:t}function inputType(e){return inputTypeFromAttr(attr(e,`type`))}function valueMode(e){switch(e){case 0:case 18:case 19:case 20:case 21:return 1;case 15:case 16:return 2;case 17:return 3;default:return 0}}function supportsSelectionType(e){return e===1||e===2||e===3||e===4||e===6}function isTextualType(e){return e>=1&&e<=6}function isNumericType(e){return e>=7&&e<=13}function lengthApplies(e){return e>=1&&e<=6}function readonlyApplies(e){return e>=1&&e<=12}function requiredApplies(e){return e>=1&&e<=12||e===15||e===16||e===17}function placeholderApplies(e){return e>=1&&e<=6||e===12}function listApplies(e){return e>=1&&e<=5||e>=7&&e<=14}function isListed(e){let t=e.tag;return!!(e.flags&16384)||t===Z.input||t===Z.button||t===Z.select||t===Z.textarea||t===Z.fieldset||t===Z.output||t===Z.object}function isSubmittable(e){let t=e.tag;return!!(e.flags&16384)||t===Z.input||t===Z.button||t===Z.select||t===Z.textarea}function isResettable(e){let t=e.tag;return!!(e.flags&16384)||t===Z.input||t===Z.select||t===Z.textarea||t===Z.output}function isLabelable(e){switch(e.tag){case Z.button:case Z.meter:case Z.output:case Z.progress:case Z.select:case Z.textarea:return!0;case Z.input:return inputType(e)!==0}return!!(e.flags&he)}function elementByIdInTree(e,t){if(t===``)return null;let n=treeRoot(e);return n.type===9?e.doc._idLookup(t):walkForId(n,t)}function walkForId(e,t){for(let n=nextElementInTree(e,e);n!==null;n=nextElementInTree(n,e))if(n.id===t)return n;return null}function formOwner(e){if(e.flags&16777216&&e.tag!==Z.form){let t=Ca.get(e),n=t.deref();if(n!==void 0&&Ca.get(n)===t&&(e.tag===Z.img||attr(e,`form`)===null)&&treeRoot(e)===treeRoot(n))return n;clearParserAssociation(e)}if(e.tag!==Z.img){let t=attr(e,`form`);if(t!==null&&e.flags&1){let n=elementByIdInTree(e,t);return n!==null&&n.tag===Z.form?n:null}}for(let t=e.parent;t!==null;t=t.parent)if(t.tag===Z.form)return t;return null}const Ca=/* @__PURE__ */ new WeakMap;function parserAssociateForm(e,t){if(t.tag!==Z.form)return;let n=Ca.get(t);n===void 0&&Ca.set(t,n=new WeakRef(t)),Ca.set(e,n),e.doc[tn]++,e.flags|=16777220,t.flags|=16777220}function clearParserAssociation(e){e.flags&16777216&&(e.flags&=-16777217,Ca.delete(e))}function formOwnerScope(e,t){return!(e.flags&16777216)&&(!t||e.id===``||!e.doc[cn])?e:treeRoot(e)}function formControls(e,t,n){let r=formOwnerScope(e,!0);for(let i=r.type===1?r:nextElementInTree(r,r);i!==null;i=nextElementInTree(i,r))i.tag===Z.img&&!n&&(t.hasImage=!0),isListed(i)&&(n||i.tag!==Z.input||inputType(i)!==19)&&formOwner(i)===e&&t.push(i);return t}function firstLegend(e){for(let t=e.first;t!==null;t=t.next)if(t.tag===Z.legend)return t;return null}function inDisabledFieldset(e){let t=e;for(let n=e.parent;n!==null;t=n,n=n.parent)if(n.tag===Z.fieldset&&attr(n,`disabled`)!==null){if(t.tag===Z.legend&&firstLegend(n)===t)continue;return!0}return!1}function isActuallyDisabled(e){if(e.flags&16384)return attr(e,`disabled`)!==null||inDisabledFieldset(e);switch(e.tag){case Z.button:case Z.input:case Z.select:case Z.textarea:case Z.fieldset:return attr(e,`disabled`)!==null||inDisabledFieldset(e);case Z.optgroup:return attr(e,`disabled`)!==null;case Z.option:{if(attr(e,`disabled`)!==null)return!0;let t=e.parent;return t!==null&&t.tag===Z.optgroup&&attr(t,`disabled`)!==null}}return!1}function hasDatalistAncestor(e){for(let t=e.parent;t!==null;t=t.parent)if(t.tag===Z.datalist)return!0;return!1}function labeledControl(e){let t=attr(e,`for`);if(t!==null){let n=elementByIdInTree(e,t);return n!==null&&isLabelable(n)?n:null}for(let t=nextElementInTree(e,e);t!==null;t=nextElementInTree(t,e))if(isLabelable(t))return t;return null}function radioIndexAdd(e,t,n){let r=e.get(t);r===void 0?e.set(t,(/* @__PURE__ */ new Set()).add(n)):r.add(n)}function radioIndexRemove(e,t,n){let r=e.get(t);r.size===1?e.delete(t):r.delete(n)}function labelsFor(e){let t=[];if(e.id!==``&&!(e.flags&1)){let n=treeRoot(e);for(let r=n.type===1?n:nextElementInTree(n,n);r!==null;r=nextElementInTree(r,n))r.tag===Z.label&&labeledControl(r)===e&&t.push(r);return t}for(let n=e.parent;n!==null;n=n.parent)n.tag===Z.label&&attr(n,`for`)===null&&labeledControl(n)===e&&t.unshift(n);let n=e.id===``?void 0:e.doc[ln]?.get(e.id);if(n===void 0)return t;if(Array.isArray(n))for(let r of n)labeledControl(r)===e&&t.push(r);else labeledControl(n)===e&&t.push(n);return t.length>1&&t.sort(compareTreeOrder),t}var PastName=class extends WeakRef{history;names;constructor(e,t,n){super(n),this.history=e,this.names=t}};const wa=/* @__PURE__ */ new WeakMap;function markNamedAncestors(e){for(let t=e;t!==null&&!(t.flags&8388608);t=t.parent)t.flags|=Ee}function rememberName(e,t,n){let r=e[ar]??=/* @__PURE__ */ new Map,i=wa.get(n);if(i?.names===t&&i.history===r)return;let a=r.get(t);if(a!==void 0){if(a===i)return;let e=a.deref();e!==void 0&&(typeof a.names==`string`?releaseBinding(e,a):(a.names.splice(a.names.indexOf(t),1),a.names.length===1&&(a.names=a.names[0])))}i===void 0?(i=new PastName(r,t,n),wa.set(n,i),markNamedAncestors(n),watchExternalName(n,i,e[z])):typeof i.names==`string`?i.names=[i.names,t]:i.names.push(t),r.set(t,i)}var ExternalWatch=class extends WeakRef{registry;key;constructor(e,t,n){super(e),this.registry=t,this.key=n}check(){let e=this.deref();e!==void 0&&checkNamedOwner(e)}},ExternalNames=class{groups=/* @__PURE__ */ new Map;collected=new FinalizationRegistry(e=>this.remove(e));add(e,t){let n=this.groups.get(t),r=new ExternalWatch(e,this,t);return n===void 0?this.groups.set(t,r):n instanceof Set?n.add(r):this.groups.set(t,/* @__PURE__ */ new Set([n,r])),this.collected.register(e,r,r),r}remove(e){let t=this.groups.get(e.key);(t===e||t instanceof Set&&t.delete(e)&&t.size===0)&&this.groups.delete(e.key),this.collected.unregister(e)}check(e){let t=this.groups.get(e);if(t instanceof Set)for(let e of t)e.check();else t?.check()}};function releaseBinding(e,t){wa.delete(e),t.external?.registry.remove(t.external)}function watchExternalName(e,t,n){let r;e.flags&524288&&e.tag!==Z.img&&(r=attr(e,`form`)??void 0),r===void 0&&e.flags&16777216&&!isInclusiveAncestor(n,e)&&(r=null);let i=t.external;if(i!==void 0){if(i.key===r&&i.registry===e.doc[Jt])return;i.registry.remove(i),t.external=void 0}r!==void 0&&(t.external=(e.doc[Jt]??=new ExternalNames).add(e,r))}function checkNamedOwner(e){let t=wa.get(e);if(t===void 0)return;let n=formOwner(e);if(n!==null&&n.node[ar]===t.history)watchExternalName(e,t,n);else{if(typeof t.names==`string`)t.history.delete(t.names);else for(let e of t.names)t.history.delete(e);releaseBinding(e,t)}}function checkNamesInSubtree(e){for(let t=e;t!==null;)t.flags&8388608?(checkNamedOwner(t),t=nextInTree(t,e)):t=nextSkippingChildren(t,e)}function checkExternalSubtree(e,t){for(let n=e;n!==null;n=nextInTree(n,e))n.id!==``&&t.check(n.id),n.tag===Z.form&&t.check(null),n.flags&8388608&&n.flags&17301504&&checkNamedOwner(n),n.flags&512&&checkExternalSubtree(n.node[G][z],t)}function addToElementIndex(e,t,n){let r=e.get(t);r===void 0?e.set(t,n):Array.isArray(r)?r.push(n):e.set(t,[r,n])}function removeFromElementIndex(e,t,n){let r=e.get(t);if(r===n)e.delete(t);else if(Array.isArray(r)){let i=r.indexOf(n);i!==-1&&r.splice(i,1),r.length===1&&e.set(t,r[0])}}function asciiLowercase$1(e){let t=e.length;for(let n=0;n<t;n++){let t=e.charCodeAt(n);if(t>=65&&t<=90)return asciiLowercaseFrom(e,n)}return e}__name(asciiLowercase$1,`asciiLowercase`);function asciiLowercaseFrom(e,t){let n=!0,r=e.length;for(let i=t;i<r;i++)if(e.charCodeAt(i)>=128){n=!1;break}if(n)return e.toLowerCase();let i=e.slice(0,t);for(let n=t;n<r;n++){let t=e.charCodeAt(n);i+=t>=65&&t<=90?String.fromCharCode(t+32):e[n]}return i}function isValidAttributeLocalName(e){let t=e.length;if(t===0)return!1;for(let n=0;n<t;n++){let t=e.charCodeAt(n);if(t===32||t===9||t===10||t===12||t===13||t===0||t===47||t===61||t===62)return!1}return!0}function findAttributeByName(e,t){let n=e.attrs;if(n===null)return null;for(let e=0;e<n.length;e++){let r=n[e],i=r.rare;if((i===null?r.localName:i.name)===t)return r}return null}function findAttributeByNamespace(e,t,n){let r=e.attrs;if(r===null)return null;for(let e=0;e<r.length;e++){let i=r[e],a=i.rare;if(i.localName===n&&(a===null?t===null:a.ns===t))return i}return null}function getAttribute(e,t){let n=e.attrs;if(n===null)return null;let r=e.flags&2?asciiLowercase$1(t):t;for(let e=0;e<n.length;e++){let t=n[e],i=t.rare;if((i===null?t.localName:i.name)===r)return t.value}return null}function prefixFlag(e){switch(e.length){case 4:if(e===`form`)return xe;if(e===`role`)return Se;break;case 5:if(e===`inert`)return be;break;case 8:if(e===`tabindex`)return ve;break;case 15:if(e===`contenteditable`)return ye}if(e.length<5||e.charCodeAt(4)!==45)return 0;let t=e.charCodeAt(0);return t===97?e.charCodeAt(1)===114&&e.charCodeAt(2)===105&&e.charCodeAt(3)===97?ge:0:t===100&&e.charCodeAt(1)===97&&e.charCodeAt(2)===116&&e.charCodeAt(3)===97?_e:0}function attr(e,t){let n=e.attrs;if(n===null)return null;for(let e=0;e<n.length;e++){let r=n[e],i=r.rare;if(i===null?r.localName===t:i.ns===null&&i.name===t)return r.value}return null}function ariaAttr(e,t){return e.flags&32768?attr(e,t):null}function hasAttr(e,t){return attr(e,t)!==null}const Ta=/* @__PURE__ */ new Map;function setAttribute(e,t,n){let r=Ta.get(t);if(r===void 0){if(!isValidAttributeLocalName(t))throw new DOMException(`"${t}" is not a valid attribute name.`,`InvalidCharacterError`);r=asciiLowercase$1(t),Ta.size===1024&&Ta.clear(),Ta.set(t,r)}let i=e.flags&2?r:t,a=findAttributeByName(e,i);a===null?appendAttribute(e,new AttrRecord(i,n,null,null)):changeAttribute(e,a,n)}function changeAttribute(e,t,n){let r=t.value;t.value=n,handleAttributeChanges(e,t,r,n)}function addRecord(e,t){let n=prefixFlag(t.localName);n!==0&&(e.flags|=n,n===524288&&(e.doc[cn]=!0));let r=e.attrs;if(r===null){let n=[,];n[0]=t,e.attrs=n;return}let i=r.length;if(i>=16){r.push(t);return}let a=Array(i+1);for(let e=0;e<i;e++)a[e]=r[e];a[i]=t,e.attrs=a}function appendAttribute(e,t){addRecord(e,t),handleAttributeChanges(e,t,null,t.value)}function removeAttributeRecord(e,t){let n=e.attrs,r=n.length,i=prefixFlag(t.localName);if(r===1)e.attrs=null,i!==0&&(e.flags&=~i);else{let a=Array(r-1),o=!1;for(let e=0,s=0;e<r;e++){let r=n[e];r!==t&&(a[s++]=r,i!==0&&!o&&prefixFlag(r.localName)===i&&(o=!0))}e.attrs=a,i!==0&&!o&&(e.flags&=~i)}t.attr!==null&&t.attr._detach(),handleAttributeChanges(e,t,t.value,null)}function removeAttribute(e,t){if(e.attrs===null)return null;let n=findAttributeByName(e,e.flags&2?asciiLowercase$1(t):t);return n!==null&&removeAttributeRecord(e,n),n}function findAttributeByLocalName(e,t){let n=e.attrs;if(n===null)return null;for(let e=0;e<n.length;e++){let r=n[e];if(r.localName===t){let e=r.rare;if(e===null||e.ns===null)return r}}return null}function setAttributeValue(e,t,n){let r=findAttributeByLocalName(e,t);r===null?appendAttribute(e,new AttrRecord(t,n,null,null)):changeAttribute(e,r,n)}function removeAttributeByLocalName(e,t){let n=findAttributeByLocalName(e,t);n!==null&&removeAttributeRecord(e,n)}function handleAttributeChanges(e,t,n,r){let i=t.rare,a=i===null?null:i.ns;ca!==0&&queueAttributeMutationRecord(e,t.localName,a,n),a===null&&(coreAttributeSteps(e,t.localName,n,r),(t.localName===`form`||t.localName===`id`&&e.doc[cn])&&n!==r&&(e.doc[tn]++,t.localName===`form`?(e.flags&16777216&&isListed(e)&&clearParserAssociation(e),e.flags&8388608&&checkNamedOwner(e)):e.doc[Jt]!==void 0&&(n&&e.doc[Jt].check(n),r&&e.doc[Jt].check(r))),Da!==0&&slotsAttributeChanged(e,t.localName,n,r)),e.flags&8&&e.node._attributeChangedSteps(t.localName,n,r,a);let o=e.doc;o[J]++,ba&&a===null&&styleBlindAttribute(o,t.localName)&&o[et]++,Xi&&flushCEReactions()}function noteNameChange(e,t,n,r){let i=e.doc,a=i[an];if(a!==null){if(i[an]=null,a===e&&t===`name`&&n===``&&r===i[sn])return}else if(t===`name`&&r===``&&n!==null){i[an]=e,i[sn]=n;return}i[rn]++}function flushBlankedName(e){e[an]!==null&&(e[an]=null,e[rn]++)}function coreAttributeSteps(e,t,n,r){switch(t){case`id`:{let i=!!(e.flags&1);i&&e.id!==``&&e.doc._idRemove(e),e.id=r??``,i&&e.id!==``&&e.doc._idAdd(e),n!==r&&(e.doc[nn]++,noteNameChange(e,t,n,r));break}case`class`:e.classes=null;break;case`style`:r===null||r===``?(e.flags&64&&noteInlineStyle(e.doc,-1),e.flags&=-65):(e.flags&64||noteInlineStyle(e.doc,1),e.flags|=64),e.node[Wr]?._attributeChanged(r);break;case`name`:n!==r&&noteNameChange(e,t,n,r)}}function appendAttributeDetached(e,t,n,r,i){addRecord(e,new AttrRecord(t,n,r,i)),r===null&&(t===`id`?e.id=n:t===`style`&&n!==``&&!(e.flags&64)&&(e.flags|=64,noteInlineStyle(e.doc,1)))}const Ea=[];function classTokens(e){let t=e.classes;if(t!==null)return t;let n=attr(e,`class`);return t=n===null||n===``?Ea:splitOnAsciiWhitespace(n),e.classes=t,t}function splitOnAsciiWhitespace(e){let t=[],n=e.length,r=0;for(;r<n;){for(;r<n&&isAsciiWhitespace(e.charCodeAt(r));)r++;if(r>=n)break;let i=r;for(;r<n&&!isAsciiWhitespace(e.charCodeAt(r));)r++;if(i===0&&r===n)return[e];t.push(e.slice(i,r))}return t}function isAsciiWhitespace(e){return e===32||e===9||e===10||e===12||e===13}let Da=0;function _shadowRootAttached(){Da++}const Oa=/* @__PURE__ */ new WeakMap,ka=/* @__PURE__ */ new WeakMap;var ManualAssignment=class extends WeakRef{slot;constructor(e,t){super(e),this.slot=t}};const Aa=/* @__PURE__ */ new WeakMap,ja=/* @__PURE__ */ new WeakMap,Ma=new FinalizationRegistry(e=>{let t=e.slot.deref();t!==void 0&&Aa.get(t)?.delete(e)}),Na=[];function isSlot(e){return e.type===1&&e.tag===Z.slot&&e.ns===`http://www.w3.org/1999/xhtml`}function isSlottable(e){return e.type===1||e.type===3}function shadowOf(e){return e.flags&512?e.node[G]??null:null}function slotName(e){return attr(e,`name`)??``}function slottableName(e){return e.type===1?attr(e,`slot`)??``:``}function findSlot(e,t){let n=e.parent;if(n===null)return null;let r=shadowOf(n);if(r===null||t&&r.mode!==`open`)return null;let i=r[z];if(r.slotAssignment===`manual`){let t=ja.get(e)?.slot.deref();return t!==void 0&&treeRoot(t)===i?t:null}let a=slottableName(e);for(let e=i.first;e!==null;e=nextInTree(e,i))if(isSlot(e)&&slotName(e)===a)return e;return null}function findSlottables(e){let t=[],n=treeRoot(e);if(!(n.flags&32))return t;let r=n.node,i=r[R][z];if(r.slotAssignment===`manual`){let n=Aa.get(e);if(n!==void 0)for(let e of n){let n=e.deref();n?.parent===i&&t.push(n)}return t}let a=null;for(let n=i.first;n!==null;n=n.next)isSlottable(n)&&(a??=firstSlotsByName(r[z]),a.get(slottableName(n))===e&&t.push(n));return t}function firstSlotsByName(e){let t=/* @__PURE__ */ new Map;for(let n=e.first;n!==null;n=nextInTree(n,e)){if(!isSlot(n))continue;let e=slotName(n);t.has(e)||t.set(e,n)}return t}function findFlattenedSlottables(e){let t=[];if(!(treeRoot(e).flags&32))return t;let n=findSlottables(e);if(n.length===0){n=[];for(let t=e.first;t!==null;t=t.next)isSlottable(t)&&n.push(t)}for(let e of n)if(isSlot(e)&&treeRoot(e).flags&32)for(let n of findFlattenedSlottables(e))t.push(n);else t.push(e);return t}function assignSlottables(e){let t=findSlottables(e),n=Oa.get(e)??Na,r=n.length===t.length;if(r){for(let e=0;e<n.length;e++)if(n[e]!==t[e]){r=!1;break}}if(!r&&(signalSlotChange(e),n.length!==0)){let r=new Set(t);for(let t of n)ka.get(t)===e&&!r.has(t)&&ka.delete(t)}t.length===0?Oa.delete(e):Oa.set(e,t);for(let n of t)ka.set(n,e)}function assignSlottablesForTree(e){for(let t=e;t!==null;t=nextInTree(t,e))isSlot(t)&&assignSlottables(t)}function assignASlot(e){let t=findSlot(e,!1);t!==null&&assignSlottables(t)}function assignAppended(e,t){if(t.slotAssignment===`manual`||ka.has(e))return!1;let n=findSlot(e,!1);if(n===null)return!0;let r=Oa.get(n);return r===void 0?Oa.set(n,[e]):r.push(e),ka.set(e,n),signalSlotChange(n),!0}function unassignRemoved(e,t){let n=Oa.get(t);n.length===1?Oa.delete(t):n.splice(n.indexOf(e),1),ka.delete(e),signalSlotChange(t)}function hasSlotDescendant(e){for(let t=e;t!==null;t=nextInTree(t,e))if(isSlot(t))return!0;return!1}function isEmptyShadowSlot(e){return isSlot(e)&&!!(treeRoot(e).flags&32)&&(Oa.get(e)??Na).length===0}function slotsAfterInsert(e,t,n){let r=n===null?1:n.length;for(let i=0;i<r;i++){let r=n===null?t:n[i];if(r.parent!==e)continue;let a=shadowOf(e);if(a!==null&&isSlottable(r)&&(r.next!==null||!assignAppended(r,a))&&assignASlot(r),isEmptyShadowSlot(e)&&signalSlotChange(e),hasSlotDescendant(r)){let e=treeRoot(r);e.flags&32&&assignSlottablesForTree(e)}}}function slotsAfterRemove(e,t){let n=ka.get(e);if(n!==void 0&&unassignRemoved(e,n),isEmptyShadowSlot(t)&&signalSlotChange(t),hasSlotDescendant(e)){let n=treeRoot(t);n.flags&32&&assignSlottablesForTree(n),assignSlottablesForTree(e)}}function slotsAttributeChanged(e,t,n,r){if(t===`name`&&isSlot(e)){if((n??``)===(r??``))return;let t=treeRoot(e);t.flags&32&&assignSlottablesForTree(t)}else if(t===`slot`){if((n??``)===(r??``))return;let t=ka.get(e);t!==void 0&&assignSlottables(t),assignASlot(e)}}function assignedSlot(e){return ka.get(e)??null}function assignedNodes(e,t){return t?findFlattenedSlottables(e):(Oa.get(e)??Na).slice()}function assignedElements(e,t){return assignedNodes(e,t).filter(e=>e.type===1)}function assignManually(e,t){let n=Aa.get(e),r=/* @__PURE__ */ new Set,i,a;for(let n of t){let t=ja.get(n);if(t===void 0)t=new ManualAssignment(n,i??=new WeakRef(e)),ja.set(n,t),Ma.register(n,t,t);else{let n=t.slot.deref();n===e?i??=t.slot:(n!==void 0&&(Aa.get(n).delete(t),(a??=/* @__PURE__ */ new Set).add(n)),t.slot=i??=new WeakRef(e))}r.add(t)}if(n!==void 0)for(let e of n){if(r.has(e))continue;let t=e.deref();t!==void 0&&ja.delete(t),Ma.unregister(e)}r.size===0?Aa.delete(e):Aa.set(e,r);let o=treeRoot(e);if(o.flags&32&&assignSlottablesForTree(o),a!==void 0)for(let e of a)treeRoot(e)!==o&&assignSlottables(e)}function assignedSlotForEventPath(e){if(Da===0)return null;let t=e.parent;return t===null||!(t.flags&512)?null:ka.get(e)??null}function isShadowRootImpl(e){return e.type===11&&!!(e.flags&32)}function hierarchyError$1(e){return new DOMException(e,`HierarchyRequestError`)}__name(hierarchyError$1,`hierarchyError`);function isCharacterData$1(e){return e===3||e===4||e===8||e===7}__name(isCharacterData$1,`isCharacterData`);function isHostIncludingInclusiveAncestor(e,t){let n=t;for(;n!==null;){if(n===e)return!0;let t=n.parent;if(t===null&&n.type===11){let e=n.node[R];n=e?e[z]:null}else n=t}return!1}function hasElementChild(e){for(let t=e.first;t!==null;t=t.next)if(t.type===1)return!0;return!1}function hasDoctypeChild(e){for(let t=e.first;t!==null;t=t.next)if(t.type===10)return!0;return!1}function doctypeFollows(e){for(let t=e.next;t!==null;t=t.next)if(t.type===10)return!0;return!1}function elementPrecedes(e){for(let t=e.prev;t!==null;t=t.prev)if(t.type===1)return!0;return!1}function ensurePreInsertionValidity(e,t,n){let r=t.type;if(r!==9&&r!==11&&r!==1)throw hierarchyError$1(`The parent is not a Document, DocumentFragment or Element.`);if(isHostIncludingInclusiveAncestor(e,t))throw hierarchyError$1(`The new child is an ancestor of the parent.`);if(n!==null&&n.parent!==t)throw new DOMException(`The reference child is not a child of this node.`,`NotFoundError`);let i=e.type;if(i!==11&&i!==10&&i!==1&&!isCharacterData$1(i))throw hierarchyError$1(`Nodes of this type cannot be inserted.`);if((i===3||i===4)&&r===9||i===10&&r!==9)throw hierarchyError$1(`Nodes of this type cannot be inserted into this parent.`);r===9&&checkDocumentChildConstraints(e,t,n,null)}function checkDocumentChildConstraints(e,t,n,r){let otherElement=()=>{for(let e=t.first;e!==null;e=e.next)if(e.type===1&&e!==r)return!0;return!1},otherDoctype=()=>{for(let e=t.first;e!==null;e=e.next)if(e.type===10&&e!==r)return!0;return!1};switch(e.type){case 11:{let i=0;for(let t=e.first;t!==null;t=t.next)if(t.type===1)i++;else if(t.type===3||t.type===4)throw hierarchyError$1(`A document cannot contain text children.`);if(i>1)throw hierarchyError$1(`A document can have only one document element.`);if(i===1){if(r===null){if(hasElementChild(t)||n!==null&&(n.type===10||doctypeFollows(n)))throw hierarchyError$1(`A document can have only one document element.`)}else if(otherElement()||doctypeFollows(r))throw hierarchyError$1(`A document can have only one document element.`)}break}case 1:if(r===null){if(hasElementChild(t)||n!==null&&(n.type===10||doctypeFollows(n)))throw hierarchyError$1(`A document can have only one document element.`)}else if(otherElement()||doctypeFollows(r))throw hierarchyError$1(`A document can have only one document element.`);break;case 10:if(r===null){if(hasDoctypeChild(t)||n!==null&&elementPrecedes(n)||n===null&&hasElementChild(t))throw hierarchyError$1(`A document can have only one doctype, before the document element.`)}else if(otherDoctype()||elementPrecedes(r))throw hierarchyError$1(`A document can have only one doctype, before the document element.`)}}function ensureReplaceAllValidity(e,t){if(t.type!==9){ensurePreInsertionValidity(e,t,null);return}if(isHostIncludingInclusiveAncestor(e,t))throw hierarchyError$1(`The new child is an ancestor of the parent.`);let n=e.type;if(n!==11&&n!==10&&n!==1&&!isCharacterData$1(n))throw hierarchyError$1(`Nodes of this type cannot be inserted.`);if(n===3||n===4)throw hierarchyError$1(`Nodes of this type cannot be inserted into this parent.`);if(n===11){let t=0;for(let n=e.first;n!==null;n=n.next)if(n.type===1)t++;else if(n.type===3||n.type===4)throw hierarchyError$1(`A document cannot contain text children.`);if(t>1)throw hierarchyError$1(`A document can have only one document element.`)}}function preInsert(e,t,n){ensurePreInsertionValidity(e,t,n);let r=n;return r===e&&(r=e.next),insert(e,t,r,!1),e}function append(e,t){return preInsert(e,t,null)}function link(e,t,n){if(e.parent=t,e.flags&8388608&&markNamedAncestors(t),e.flags&3145728&&markRangeAncestors(t),n===null){let n=t.last;e.prev=n,e.next=null,n===null?t.first=e:n.next=e,t.last=e}else{let r=n.prev;e.prev=r,e.next=n,n.prev=e,r===null?t.first=e:r.next=e}if(t.childCount++,t.flags&256){let r=t.node[st];n===null?aa._appended(r,e.node):aa._rebuild(r)}}function unlink(e){let t=e.parent,n=e.prev,r=e.next;if(n===null?t.first=r:n.next=r,r===null?t.last=n:r.prev=n,e.parent=null,e.prev=null,e.next=null,t.childCount--,t.flags&256){let e=t.node[st];r===null?aa._popped(e):aa._rebuild(e)}}function suspendChildList(e){let t=e.flags&256;return e.flags&=-257,t}function resumeChildList(e,t){t!==0&&(e.flags|=256,aa._rebuild(e.node[st]))}function insert(e,t,n,r){let i=e.type===11,a=i?e.childCount:1;if(a===0)return;let o=null;if(i){o=snapshotChildren(e);let t=suspendChildList(e);for(let e=0;e<o.length;e++)remove(o[e],!0);resumeChildList(e,t),ca!==0&&queueTreeMutationRecord(e,null,o,null,null)}ha!==0&&n!==null&&t.flags&1048576&&rangesAfterInsert(t,n,a);let s=n===null?t.last:n.prev,c=t.doc,l=!!(t.flags&1);if(o===null)insertOne(e,t,n,c,l);else{let e=a>1&&n!==null?suspendChildList(t):0;for(let e=0;e<o.length;e++)insertOne(o[e],t,n,c,l);resumeChildList(t,e)}Da!==0&&slotsAfterInsert(t,o===null?e:null,o),!r&&ca!==0&&queueTreeMutationRecord(t,o??e,null,s,n),childrenChanged(t),c[J]++,c[ei]++;let u=c[Jt];if(u?.groups.size){if(o===null)checkExternalSubtree(e,u);else for(let e of o)checkExternalSubtree(e,u)}Xi&&flushCEReactions()}function insertOne(e,t,n,r,i){(e.parent!==null||e.doc!==r)&&adopt(e,r),link(e,t,n),i&&connectSubtree(e,r)}let Pa=null;function connectingRoot(){return Pa}function connectSubtree(e,t){let n=Pa;Pa=e;try{connectNodes(e,t)}finally{Pa=n}}function connectNodes(e,t){for(let n=e;n!==null;n=nextInTree(n,e))n.flags|=1,n.type===1&&(n.id!==``&&t._idAdd(n),n.flags&4&&n.node._connectedSteps(),n.flags&512&&connectSubtree(n.node[G][z],t))}function connectDetachedChildren(e){let t=e.node;for(let n=e.first;n!==null;n=n.next)connectSubtree(n,t);t[J]++,t[ei]++,t[Jt]?.groups.size&&checkExternalSubtree(e,t[Jt])}function disconnectSubtree(e,t){for(let n=e;n!==null;n=nextInTree(n,e))n.flags&=-2,n.type===1&&(n.id!==``&&t._idRemove(n),t[L]===n&&(t[L]=null),n.flags&4&&n.node._disconnectedSteps(),n.flags&512&&disconnectSubtree(n.node[G][z],t))}function childrenChanged(e){e.flags&16&&e.node._childrenChangedSteps()}function preRemove(e,t){if(e.parent!==t)throw new DOMException(`The node to be removed is not a child of this node.`,`NotFoundError`);return remove(e,!1),e}function remove(e,t){let n=e.parent,r=n.doc;ha!==0&&(e.flags&3145728||n.flags&1048576)&&rangesBeforeRemove(e,n),ga!==0&&iteratorsBeforeRemove(e),r[an]!==null&&(r[an]=null,r[rn]++);let i=e.prev,a=e.next;unlink(e),Da!==0&&slotsAfterRemove(e,n);let o=!!(e.flags&1);o&&disconnectSubtree(e,r),e.flags&8388608&&checkNamesInSubtree(e),ca!==0&&(addTransientObservers(n,e),t||queueTreeMutationRecord(n,null,e,i,a)),childrenChanged(n),r[J]++,r[ei]++,r[Jt]?.groups.size&&checkExternalSubtree(e,r[Jt]),r[Vt]=null,Xi&&o&&flushCEReactions()}function shadowIncludingRoot(e){let t=treeRoot(e);for(;t.flags&32;){let e=t.node[R];if(e===null)break;t=treeRoot(e[z])}return t}function move(e,t,n){if(shadowIncludingRoot(t)!==shadowIncludingRoot(e))throw hierarchyError$1(`The new parent is not in the same shadow-including tree as the node to move.`);if(isHostIncludingInclusiveAncestor(e,t))throw hierarchyError$1(`The node to move is an ancestor of the new parent.`);if(n!==null&&n.parent!==t)throw new DOMException(`The reference child is not a child of this node.`,`NotFoundError`);let r=e.type;if(r!==1&&!isCharacterData$1(r))throw hierarchyError$1(`Only elements and character data nodes can be moved.`);if(t.type===9){if(r===3)throw hierarchyError$1(`Nodes of this type cannot be moved into a document.`);if(r===1&&(hasElementChild(t)||n!==null&&(n.type===10||doctypeFollows(n))))throw hierarchyError$1(`A document can have only one document element.`)}let i=e.parent,a=t.doc;ha!==0&&(e.flags&3145728||i.flags&1048576)&&rangesBeforeRemove(e,i),ga!==0&&iteratorsBeforeRemove(e);let o=e.prev,s=e.next;unlink(e),Da!==0&&slotsAfterRemove(e,i),ca!==0&&addTransientObservers(i,e),ha!==0&&n!==null&&t.flags&1048576&&rangesAfterInsert(t,n,1);let c=n===null?t.last:n.prev;link(e,t,n),Da!==0&&slotsAfterInsert(t,e,null);for(let t=e;t!==null;t=nextInTree(t,e))t.type===1&&t.flags&4&&t.node._movingSteps(t===e,i);e.flags&8388608&&checkNamesInSubtree(e),ca!==0&&(queueTreeMutationRecord(i,null,e,o,s),queueTreeMutationRecord(t,e,null,c,n)),childrenChanged(i),t!==i&&childrenChanged(t),a[J]++,a[ei]++,a[Jt]?.groups.size&&checkExternalSubtree(e,a[Jt]),Xi&&flushCEReactions()}function replace(e,t,n){let r=n.type;if(r!==9&&r!==11&&r!==1)throw hierarchyError$1(`The parent is not a Document, DocumentFragment or Element.`);if(isHostIncludingInclusiveAncestor(t,n))throw hierarchyError$1(`The new child is an ancestor of the parent.`);if(e.parent!==n)throw new DOMException(`The node to be replaced is not a child of this node.`,`NotFoundError`);let i=t.type;if(i!==11&&i!==10&&i!==1&&!isCharacterData$1(i))throw hierarchyError$1(`Nodes of this type cannot be inserted.`);if((i===3||i===4)&&r===9||i===10&&r!==9)throw hierarchyError$1(`Nodes of this type cannot be inserted into this parent.`);r===9&&checkDocumentChildConstraints(t,n,null,e);let a=e.next;a===t&&(a=t.next);let o=e.prev;o===t&&(o=t.prev),(t.parent!==null||t.doc!==n.doc)&&adopt(t,n.doc);let s=null;e.parent!==null&&(s=e,remove(e,!0));let c=t.type===11?snapshotChildren(t):t;return insert(t,n,a,!0),ca!==0&&queueTreeMutationRecord(n,c,s,o,a),e}function replaceAll(e,t){if(t.first===null){e!==null&&insert(e,t,null,!1);return}let n=snapshotChildren(t),r=e?.type===11?snapshotChildren(e):e,i=suspendChildList(t);for(let e=0;e<n.length;e++)remove(n[e],!0);e!==null&&insert(e,t,null,!0),resumeChildList(t,i),ca!==0&&queueTreeMutationRecord(t,r,n,null,null)}function adopt(e,t){let n=e.doc;if(e.parent!==null&&remove(e,!1),n!==t){n[Vt]=null,t[J]<=n[J]&&(t[J]=n[J]+1);let r=t[Nn];for(let n=e;n!==null;n=nextInTree(n,e))if(n.doc=t,n.type===1){n.ns===`http://www.w3.org/1999/xhtml`&&r?n.flags|=2:n.flags&=-3,n.flags&524288&&(t[cn]=!0);let e=n.attrs;if(e!==null)for(let n=0;n<e.length;n++){let r=e[n].attr;r!==null&&(r[z].doc=t)}n.flags&512&&adoptShadowTree(n.node[G][z],t)}n[Jt]?.groups.size&&checkExternalSubtree(e,n[Jt]),ha!==0&&rangesAdopt(e,n),runAdoptingSteps(e,n)}}function runAdoptingSteps(e,t){for(let n=e;n!==null;n=nextInTree(n,e))n.flags&4096&&n.node._adoptingSteps(t),n.flags&512&&runAdoptingSteps(n.node[G][z],t)}function adoptShadowTree(e,t){let n=e.doc[Et];for(let n=e;n!==null;n=nextInTree(n,e))if(n.doc=t,n.type===1){n.ns===`http://www.w3.org/1999/xhtml`&&t[Nn]?n.flags|=2:n.flags&=-3,n.flags&524288&&(t[cn]=!0);let e=n.attrs;if(e!==null)for(let n=0;n<e.length;n++){let r=e[n].attr;r!==null&&(r[z].doc=t)}n.flags&512&&adoptShadowTree(n.node[G][z],t)}n?.adoptShadowRoot(e)}function appendDetached(e,t){link(e,t,null)}function insertDetached(e,t,n){link(e,t,n)}function cloneNode(e,t,n){let r=cloneTree(e,t,n);return Xi&&flushCEReactions(),r}function cloneTree(e,t,n){let r=cloneOne(e,t,n);if(n){for(let n=e.first;n!==null;n=n.next)appendDetached(cloneTree(n,r.type===9?r.node:t,!0),r);r.type===9&&r.first!==null&&connectDetachedChildren(r)}if(e.flags&512){let n=e.node[G];if(n[ft]){let e=r.node.attachShadow({mode:n[qn],clonable:!0,serializable:n[Mr],delegatesFocus:n[It],slotAssignment:n[Hr]});e[Nt]=n[Nt];for(let r=n[z].first;r!==null;r=r.next)appendDetached(cloneTree(r,t,!0),e[z])}}return r}function cloneOne(e,t,n){switch(e.type){case 1:{let r=$i?createCloneElementImpl(t,e):createElementImpl(t,e.name,e.ns,e.prefix),i=e.attrs;if(i!==null){let t=Array(i.length);for(let e=0;e<i.length;e++){let n=i[e];t[e]=new AttrRecord(n.localName,n.value,n.ns,n.prefix)}r.attrs=t,r.id=e.id,r.flags|=e.flags&5218368,e.flags&524288&&(r.doc[cn]=!0)}return e.node._cloningSteps(r.node,n),r}case 3:return t.createTextNode(e.data)[z];case 4:return new e.node.constructor(e.data,t)[z];case 8:return t.createComment(e.data)[z];case 7:return t.createProcessingInstruction(e.name,e.data)[z];case 11:return t.createDocumentFragment()[z];case 10:{let n=e.node;return t.implementation.createDocumentType(n.name,n.publicId,n.systemId)[z]}case 9:return e.node._cloneDocument()[z];case 2:{let n=t.createAttributeNS(e.ns,e.prefix===null?e.name:e.prefix+`:`+e.name);return n.value=e.data,n[z]}}throw new DOMException(`Cannot clone this node.`,`NotSupportedError`)}function isEqualNode(e,t){if(e===t)return!0;if(e.type!==t.type)return!1;switch(e.type){case 10:{let n=e.node,r=t.node;if(n.name!==r.name||n.publicId!==r.publicId||n.systemId!==r.systemId)return!1;break}case 1:{if(e.ns!==t.ns||e.prefix!==t.prefix||e.name!==t.name)return!1;let n=e.attrs,r=t.attrs;if(n===r)break;if(n===null||r===null||n.length!==r.length)return!1;let i=0;for(;i<n.length;i++){let e=n[i],t=r[i];if(e.localName!==t.localName||e.ns!==t.ns)break;if(e.value!==t.value)return!1}for(;i<n.length;i++){let e=n[i],r=findAttributeByNamespace(t,e.ns,e.localName);if(r===null||r.value!==e.value)return!1}break}case 2:if(e.ns!==t.ns||e.name!==t.name||e.data!==t.data)return!1;break;case 7:if(e.name!==t.name||e.data!==t.data)return!1;break;case 3:case 4:case 8:if(e.data!==t.data)return!1}if(e.childCount!==t.childCount)return!1;for(let n=e.first,r=t.first;n!==null&&r!==null;n=n.next,r=r.next)if(!isEqualNode(n,r))return!1;return!0}function replaceData(e,t,n,r){let i=e.data,a=i.length;if(t>a)throw new DOMException(`The offset ${t} is greater than the node's length (${a}).`,`IndexSizeError`);t+n>a&&(n=a-t),ca!==0&&queueCharacterDataMutationRecord(e,i),t===a?e.data=i+r:(e.data=t===0&&n===a?r:i.slice(0,t)+r+i.slice(t+n),ha!==0&&e.flags&1048576&&rangesReplaceData(e,t,n,r.length));let o=e.parent;o!==null&&o.flags&16&&o.node._childrenChangedSteps();let s=e.doc;s[J]++,i.length!==0&&e.data.length!==0&&s[et]++}function splitText(e,t){let n=e.data.length;if(t>n)throw new DOMException(`The offset ${t} is larger than the Text node's length.`,`IndexSizeError`);let r=n-t,i=e.data.slice(t),a=e.doc.createTextNode(i)[z],o=e.parent;return o!==null&&(insert(a,o,e.next,!1),ha!==0&&(e.flags|o.flags)&1048576&&rangesSplitText(e,a,t,o)),replaceData(e,t,r,``),a}function quote(e,t){let n=e.length>t?e.slice(0,t)+`…`:e;return JSON.stringify(n)}function ctorName(e){return e.node.constructor?.name??`Node`}function inspectNode(e,t,n,r){switch(e.type){case 1:{let t=e.prefix===null?e.name:e.prefix+`:`+e.name,n=ctorName(e)+` <`+t,r=e.attrs;if(r!==null)for(let e=0;e<r.length;e++)n+=` `+r[e].name+`=`+quote(r[e].value,40);return n+(e.first===null?` />`:`>`)}case 3:return`#text `+quote(e.data,60);case 4:return`#cdata-section `+quote(e.data,60);case 8:return`#comment `+quote(e.data,60);case 7:return`ProcessingInstruction <?`+e.name+` `+e.data.slice(0,60)+`?>`;case 9:return`#document `+quote(e.node.URL??``,80);case 10:return`<!DOCTYPE `+e.name+`>`;case 11:return e.flags&32?`#shadow-root (`+e.node.mode+`)`:`#document-fragment (`+e.childCount+(e.childCount===1?` child)`:` children)`);case 2:return`Attr `+(e.prefix===null?e.name:e.prefix+`:`+e.name)+`=`+quote(e.node.value,40)}return ctorName(e)}var Node=class extends EventTarget{static ELEMENT_NODE=1;static ATTRIBUTE_NODE=2;static TEXT_NODE=3;static CDATA_SECTION_NODE=4;static ENTITY_REFERENCE_NODE=5;static ENTITY_NODE=6;static PROCESSING_INSTRUCTION_NODE=7;static COMMENT_NODE=8;static DOCUMENT_NODE=9;static DOCUMENT_TYPE_NODE=10;static DOCUMENT_FRAGMENT_NODE=11;static NOTATION_NODE=12;static DOCUMENT_POSITION_DISCONNECTED=1;static DOCUMENT_POSITION_PRECEDING=2;static DOCUMENT_POSITION_FOLLOWING=4;static DOCUMENT_POSITION_CONTAINS=8;static DOCUMENT_POSITION_CONTAINED_BY=16;static DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC=32;[z];constructor(e,t){if(t===void 0)throw TypeError(`Illegal constructor`);super(),this[z]=new NodeImpl(this,e,t??this)}get nodeType(){return this[z].type}get nodeName(){let e=this[z];switch(e.type){case 1:return htmlUppercasedQualifiedName(e);case 3:return`#text`;case 8:return`#comment`;case 2:return e.prefix===null?e.name:e.prefix+`:`+e.name;case 4:return`#cdata-section`;case 9:return`#document`;case 11:return`#document-fragment`;default:return e.name}}get baseURI(){return this[z].doc.baseURI}get isConnected(){return!!(this[z].flags&1)}get ownerDocument(){let e=this[z];return e.type===9?null:e.doc}getRootNode(e){let t=treeRoot(this[z]);if(e?.composed)for(;t.flags&32;){let e=t.node[R];t=treeRoot(e[z])}return t.node}get parentNode(){let e=this[z].parent;return e===null?null:e.node}get parentElement(){let e=this[z].parent;return e!==null&&e.type===1?e.node:null}hasChildNodes(){return this[z].first!==null}get childNodes(){return this[st]??=aa._live(this[z])}get firstChild(){let e=this[z].first;return e===null?null:e.node}get lastChild(){let e=this[z].last;return e===null?null:e.node}get previousSibling(){let e=this[z].prev;return e===null?null:e.node}get nextSibling(){let e=this[z].next;return e===null?null:e.node}get nodeValue(){let e=this[z];switch(e.type){case 2:return attrValue(this);case 3:case 4:case 7:case 8:return e.data;default:return null}}set nodeValue(e){let t=this[z];switch(t.type){case 2:setAttrValue(this,e==null?``:String(e));return;case 3:case 4:case 7:case 8:replaceData(t,0,t.data.length,e==null?``:String(e));return}}get textContent(){let e=this[z];switch(e.type){case 1:case 11:return descendantTextContent(e);case 3:case 4:case 7:case 8:return e.data;case 2:return attrValue(this);default:return null}}set textContent(e){let t=this[z],n=e==null?``:String(e);switch(t.type){case 1:case 11:replaceAll(n===``?null:t.doc.createTextNode(n)[z],t);return;case 3:case 4:case 7:case 8:replaceData(t,0,t.data.length,n);return;case 2:setAttrValue(this,n);return}}normalize(){let e=this[z],t=e.first;for(;t!==null;){if(t.type!==3){t=nextInTree(t,e);continue}let n=t.data.length;if(n===0){let n=nextSkippingSelf(t,e);remove(t,!1),t=n;continue}let r=t.next;if(r===null||r.type!==3){t=nextInTree(t,e);continue}let i=``;for(let e=r;e!==null&&e.type===3;e=e.next)i+=e.data;replaceData(t,n,0,i);let a=r;for(;a!==null&&a.type===3;)ha!==0&&(a.flags|a.parent.flags)&1048576&&rangesNormalizeMerge(t,a,n),n+=a.data.length,a=a.next;for(;r!==null&&r.type===3;){let e=r.next;remove(r,!1),r=e}t=nextInTree(t,e)}}cloneNode(e=!1){if(this[z].flags&32)throw new DOMException(`Shadow roots cannot be cloned.`,`NotSupportedError`);return cloneNode(this[z],this[z].doc,e).node}isEqualNode(e){return e!==null&&isEqualNode(this[z],e[z])}isSameNode(e){return this===e}compareDocumentPosition(e){if(this===e)return 0;let t=e[z],n=this[z],r=null,i=null;if(t.type===2&&(r=t,t=ownerElementImpl(t)),n.type===2&&(i=n,n=ownerElementImpl(n),r!==null&&t!==null&&n===t))for(let e of n.attrs??[]){if(e.attr?.[z]===r)return 34;if(e.attr?.[z]===i)return 36}if(t!==null&&n!==null){if(t===n)return r===null?10:20;let e=relativeTreePosition(n,t);if(e!==1)return r!==null&&e&8?2:i!==null&&e&16?4:e}return 33|(stableOrder(t??r,n??i)?2:4)}contains(e){return this===e||e!==null&&isInclusiveAncestor(this[z],e[z])}lookupPrefix(e){if(e==null||e===``)return null;let t=namespaceContextElement(this[z]);return t===null?null:locatePrefix(t,String(e))}lookupNamespaceURI(e){let t=e==null||e===``?null:String(e);return locateNamespace(this[z],t)}isDefaultNamespace(e){let t=e==null||e===``?null:String(e);return locateNamespace(this[z],null)===t}insertBefore(e,t){return preInsert(e[z],this[z],t===null?null:t[z]),e}appendChild(e){return preInsert(e[z],this[z],null),e}replaceChild(e,t){return replace(t[z],e[z],this[z]),t}removeChild(e){return preRemove(e[z],this[z]),e}_getTheParent(e){return nodeGetTheParent(this,e)}[Symbol.for(`nodejs.util.inspect.custom`)](e,t,n){return inspectNode(this[z],e,t,n)}_replaceAll(e){replaceAll(e===null?null:e[z],this[z])}};for(let e of Object.getOwnPropertyNames(Node))/^[A-Z_]+$/.test(e)&&Object.defineProperty(Node.prototype,e,{value:Node[e],enumerable:!0});function nextSkippingSelf(e,t){let n=e;for(;n!==null&&n!==t;){if(n.next!==null)return n.next;n=n.parent}return null}function namespaceContextElement(e){switch(e.type){case 1:return e;case 9:for(let t=e.first;t!==null;t=t.next)if(t.type===1)return t;return null;case 10:case 11:return null;case 2:return ownerElementImpl(e);default:{let t=e.parent;return t!==null&&t.type===1?t:null}}}function locatePrefix(e,t){for(let n=e;n!==null;){if(n.ns===t&&n.prefix!==null)return n.prefix;let e=n.attrs;if(e!==null)for(let n=0;n<e.length;n++){let r=e[n];if(r.prefix===`xmlns`&&r.value===t)return r.localName}let r=n.parent;n=r!==null&&r.type===1?r:null}return null}function locateNamespace(e,t){let n=namespaceContextElement(e);for(;n!==null;){if(t===`xml`)return k;if(t===`xmlns`)return ne;if(n.ns!==null&&n.prefix===t)return n.ns;let e=n.attrs;if(e!==null)for(let n=0;n<e.length;n++){let r=e[n];if(r.ns===`http://www.w3.org/2000/xmlns/`&&(r.prefix===`xmlns`&&r.localName===t||t===null&&r.prefix===null&&r.localName===`xmlns`))return r.value===``?null:r.value}let r=n.parent;n=r!==null&&r.type===1?r:null}return null}function ownerElementImpl(e){let t=e.node.ownerElement;return t===null?null:t[z]}const Fa=/* @__PURE__ */ new WeakMap;let Ia=0;function stableOrder(e,t){let n=Fa.get(e);n===void 0&&Fa.set(e,n=Ia++);let r=Fa.get(t);return r===void 0&&Fa.set(t,r=Ia++),n<r}function descendantTextContent(e){let t=``;for(let n=e.first;n!==null;n=nextInTree(n,e))(n.type===3||n.type===4)&&(t+=n.data);return t}function attrValue(e){let t=e[_r];return t===null?e[z].data:t.value}function setAttrValue(e,t){let n=e[_r],r=e[er];n===null||r===null?e[z].data=t:changeAttribute(r[z],n,t)}const La=/* @__PURE__ */ new Map;function htmlUppercasedQualifiedName(e){if(e.prefix===null){if(!(e.flags&2))return e.name;let t=La.get(e.name);return t===void 0&&(La.size>=1024&&La.clear(),La.set(e.name,t=asciiUppercase(e.name))),t}let t=e.prefix+`:`+e.name;return e.flags&2?asciiUppercase(t):t}function asciiUppercase(e){let t=``;for(let n=0;n<e.length;n++)if(e.charCodeAt(n)>=128){for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t+=r>=97&&r<=122?String.fromCharCode(r-32):e[n]}return t}return e.toUpperCase()}function derivedCache(e,t,n){let r=e[Vt];r===null&&(e[Vt]=r=/* @__PURE__ */ new WeakMap);let i=r.get(t);return i===void 0&&r.set(t,i=n()),i}function peekDerivedCache(e,t){let n=e[Vt];return n===null?void 0:n.get(t)}function cachedSnapshot(e,t,n){let r=e[Vt]?.get(t);return r?.version===n?r.items:void 0}function storeSnapshot(e,t,n,r){(e[Vt]??=/* @__PURE__ */ new WeakMap).set(t,{version:n,items:r})}var Token=class{type;value;num;isInt;flag;start;constructor(e,t,n){this.type=e,this.value=t,this.num=0,this.isInt=!1,this.flag=!1,this.start=n}};function isDigit$1(e){return e>=48&&e<=57}__name(isDigit$1,`isDigit`);function isHexDigit$1(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}__name(isHexDigit$1,`isHexDigit`);function hexValue$1(e){return e<=57?e-48:e<=70?e-65+10:e-97+10}__name(hexValue$1,`hexValue`);function isIdentStart$1(e){return e>=97&&e<=122||e>=65&&e<=90||e===95||e>=128||e===0}__name(isIdentStart$1,`isIdentStart`);function isIdentChar$1(e){return isIdentStart$1(e)||isDigit$1(e)||e===45}__name(isIdentChar$1,`isIdentChar`);function isNewline$1(e){return e===10||e===13||e===12}__name(isNewline$1,`isNewline`);function isWhitespace$1(e){return e===32||e===9||isNewline$1(e)}__name(isWhitespace$1,`isWhitespace`);function isNonPrintable$1(e){return e>=0&&e<=8||e===11||e>=14&&e<=31||e===127}__name(isNonPrintable$1,`isNonPrintable`);var Tokenizer$1=class{static{__name(this,`Tokenizer`)}src;pos;len;constructor(e){this.src=e,this.pos=0,this.len=e.length}code(e){return e>=this.len?-1:this.src.charCodeAt(e)}validEscape(e){return this.code(e)===92&&!isNewline$1(this.code(e+1))}startsIdent(e){let t=this.code(e);if(t===45){let t=this.code(e+1);return isIdentStart$1(t)||t===45||this.validEscape(e+1)}return isIdentStart$1(t)?!0:this.validEscape(e)}startsNumber(e){let t=this.code(e);if(t===43||t===45){let t=this.code(e+1);return isDigit$1(t)?!0:t===46&&isDigit$1(this.code(e+2))}return isDigit$1(t===46?this.code(e+1):t)}consumeEscape(){let e=this.code(this.pos);if(e===-1)return`�`;if(isHexDigit$1(e)){let e=0,t=0;for(;t<6&&isHexDigit$1(this.code(this.pos));)e=e*16+hexValue$1(this.code(this.pos)),this.pos++,t++;let n=this.code(this.pos);return n===13&&this.code(this.pos+1)===10?this.pos+=2:isWhitespace$1(n)&&this.pos++,e===0||e>=55296&&e<=57343||e>1114111?`�`:String.fromCodePoint(e)}if(this.pos++,e===0)return`�`;if(e>=55296&&e<=56319){let e=this.code(this.pos);if(e>=56320&&e<=57343)return this.pos++,this.src.slice(this.pos-2,this.pos)}return String.fromCharCode(e)}consumeName(){let e=``,t=this.pos,n=t;for(;;){let t=this.code(this.pos);if(t!==-1&&t!==0&&isIdentChar$1(t))this.pos++;else if(this.validEscape(this.pos))e+=this.src.slice(n,this.pos),this.pos++,e+=this.consumeEscape(),n=this.pos;else if(t===0)e+=this.src.slice(n,this.pos)+`�`,this.pos++,n=this.pos;else break}return n===t?this.src.slice(t,this.pos):e+this.src.slice(n,this.pos)}consumeNumber(e){let t=this.pos,n=!0,r=this.code(this.pos);for((r===43||r===45)&&(e.flag=!0,this.pos++);isDigit$1(this.code(this.pos));)this.pos++;if(this.code(this.pos)===46&&isDigit$1(this.code(this.pos+1)))for(n=!1,this.pos+=2;isDigit$1(this.code(this.pos));)this.pos++;if(r=this.code(this.pos),r===69||r===101){let e=this.code(this.pos+1);if(isDigit$1(e))for(n=!1,this.pos+=2;isDigit$1(this.code(this.pos));)this.pos++;else if((e===43||e===45)&&isDigit$1(this.code(this.pos+2)))for(n=!1,this.pos+=3;isDigit$1(this.code(this.pos));)this.pos++}e.num=Number(this.src.slice(t,this.pos)),e.isInt=n}consumeString(e,t){let n=``,r=this.pos;for(;;){let i=this.code(this.pos);if(i===e||i===-1)return n+=this.src.slice(r,this.pos),i!==-1&&this.pos++,new Token(5,n,t);if(isNewline$1(i))return new Token(6,``,t);if(i===92){n+=this.src.slice(r,this.pos);let e=this.code(this.pos+1);e===-1?this.pos++:isNewline$1(e)?this.pos+=e===13&&this.code(this.pos+2)===10?3:2:(this.pos++,n+=this.consumeEscape()),r=this.pos}else i===0?(n+=this.src.slice(r,this.pos)+`�`,this.pos++,r=this.pos):this.pos++}}consumeBadUrl(e){for(;;){let e=this.code(this.pos);if(e===-1)break;if(e===41){this.pos++;break}this.validEscape(this.pos)?(this.pos++,this.consumeEscape()):this.pos++}return new Token(8,``,e)}consumeUrl(e){for(;isWhitespace$1(this.code(this.pos));)this.pos++;let t=``;for(;;){let n=this.code(this.pos);if(n===41||n===-1)return n!==-1&&this.pos++,new Token(7,t,e);if(isWhitespace$1(n)){for(;isWhitespace$1(this.code(this.pos));)this.pos++;let n=this.code(this.pos);return n===41||n===-1?(n!==-1&&this.pos++,new Token(7,t,e)):this.consumeBadUrl(e)}if(n===34||n===39||n===40||isNonPrintable$1(n))return this.consumeBadUrl(e);if(n===92){if(this.validEscape(this.pos))this.pos++,t+=this.consumeEscape();else return this.consumeBadUrl(e)}else t+=n===0?`�`:this.src[this.pos],this.pos++}}consumeIdentLike(e){let t=this.consumeName();if(this.code(this.pos)===40){if(this.pos++,t.length===3&&asciiLower$1(t)===`url`){let n=this.pos;for(;isWhitespace$1(this.code(n))&&isWhitespace$1(this.code(n+1));)n++;let r=this.code(n),i=isWhitespace$1(r)?this.code(n+1):r;return i===34||i===39?(this.pos=n,new Token(2,t,e)):this.consumeUrl(e)}return new Token(2,t,e)}return new Token(1,t,e)}consumeNumeric(e){let t=new Token(10,``,e);return this.consumeNumber(t),this.startsIdent(this.pos)?(t.type=12,t.value=this.consumeName()):this.code(this.pos)===37&&(this.pos++,t.type=11),t}next(){for(;this.code(this.pos)===47&&this.code(this.pos+1)===42;){let e=this.src.indexOf(`*/`,this.pos+2);this.pos=e===-1?this.len:e+2}let e=this.pos,t=this.code(this.pos);if(t===-1)return new Token(0,``,e);if(isWhitespace$1(t)){for(this.pos++;isWhitespace$1(this.code(this.pos));)this.pos++;return new Token(13,` `,e)}switch(t){case 34:case 39:return this.pos++,this.consumeString(t,e);case 35:{let t=this.code(this.pos+1);if(t!==-1&&isIdentChar$1(t)||t===0||this.validEscape(this.pos+1)){this.pos++;let t=new Token(4,``,e);return t.flag=this.startsIdent(this.pos),t.value=this.consumeName(),t}return this.pos++,new Token(9,`#`,e)}case 40:return this.pos++,new Token(21,`(`,e);case 41:return this.pos++,new Token(22,`)`,e);case 43:return this.startsNumber(this.pos)?this.consumeNumeric(e):(this.pos++,new Token(9,`+`,e));case 44:return this.pos++,new Token(18,`,`,e);case 45:return this.startsNumber(this.pos)?this.consumeNumeric(e):this.code(this.pos+1)===45&&this.code(this.pos+2)===62?(this.pos+=3,new Token(15,`-->`,e)):this.startsIdent(this.pos)?this.consumeIdentLike(e):(this.pos++,new Token(9,`-`,e));case 46:return this.startsNumber(this.pos)?this.consumeNumeric(e):(this.pos++,new Token(9,`.`,e));case 58:return this.pos++,new Token(16,`:`,e);case 59:return this.pos++,new Token(17,`;`,e);case 60:return this.code(this.pos+1)===33&&this.code(this.pos+2)===45&&this.code(this.pos+3)===45?(this.pos+=4,new Token(14,`<!--`,e)):(this.pos++,new Token(9,`<`,e));case 64:return this.startsIdent(this.pos+1)?(this.pos++,new Token(3,this.consumeName(),e)):(this.pos++,new Token(9,`@`,e));case 91:return this.pos++,new Token(19,`[`,e);case 92:return this.validEscape(this.pos)?this.consumeIdentLike(e):(this.pos++,new Token(9,`\\`,e));case 93:return this.pos++,new Token(20,`]`,e);case 123:return this.pos++,new Token(23,`{`,e);case 125:return this.pos++,new Token(24,`}`,e)}if(isDigit$1(t))return this.consumeNumeric(e);if(isIdentStart$1(t)||t===0)return this.consumeIdentLike(e);if(this.pos++,t>=55296&&t<=56319){let t=this.code(this.pos);if(t>=56320&&t<=57343)return this.pos++,new Token(9,this.src.slice(this.pos-2,this.pos),e)}return new Token(9,this.src[e],e)}};function tokenize$1(e){let t=new Tokenizer$1(e),n=[];for(;;){let e=t.next();if(n.push(e),e.type===0)break}return n}__name(tokenize$1,`tokenize`);function asciiLower$1(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n>=65&&n<=90)return e.toLowerCase()}return e}__name(asciiLower$1,`asciiLower`);var Simple=class{kind;name;nsKind;nsPrefix;op;value;caseFlag;pseudo;a;b;list;args;constructor(e,t){this.kind=e,this.name=t,this.nsKind=0,this.nsPrefix=``,this.op=0,this.value=``,this.caseFlag=0,this.pseudo=0,this.a=0,this.b=0,this.list=null,this.args=[]}},Compound=class{simples;pseudoElementIndex;constructor(){this.simples=[],this.pseudoElementIndex=-1}},Complex=class{compounds;combinators;leading;text;invalid;constructor(){this.compounds=[],this.combinators=[],this.leading=0,this.text=``,this.invalid=!1}},SelectorList=class{items;constructor(){this.items=[]}};function allowedAfterPseudoElement(e,t){return e===3?!isStructural(t):e===2?!1:t===37||t===38||t===39||t===41||t===40||t===1||t===2||t===3}function pseudoClassId(e){switch(e){case`first-child`:return 20;case`last-child`:return 21;case`only-child`:return 22;case`first-of-type`:return 23;case`last-of-type`:return 24;case`only-of-type`:return 25;case`empty`:return 26;case`root`:return 27;case`scope`:return 28;case`host`:return 29;case`link`:return 30;case`any-link`:return 31;case`visited`:return 32;case`target`:return 34;case`target-within`:return 35;case`defined`:return 36;case`hover`:return 37;case`active`:return 38;case`focus`:return 39;case`focus-within`:return 40;case`focus-visible`:return 41;case`checked`:return 50;case`indeterminate`:return 51;case`default`:return 52;case`disabled`:return 53;case`enabled`:return 54;case`required`:return 55;case`optional`:return 56;case`read-only`:return 57;case`read-write`:return 58;case`placeholder-shown`:return 59;case`valid`:return 60;case`invalid`:return 61;case`in-range`:return 62;case`out-of-range`:return 63;case`user-valid`:return 64;case`user-invalid`:return 65;case`autofill`:return 66;case`-webkit-autofill`:return 66;case`open`:return 70;case`popover-open`:return 72;case`modal`:return 73;case`fullscreen`:return 74;case`picture-in-picture`:return 75;case`playing`:return 76;case`paused`:return 77;case`muted`:return 78;case`seeking`:return 79;case`buffering`:return 80;case`stalled`:return 81;case`volume-locked`:return 82;case`current`:return 83;case`past`:return 84;case`future`:return 85;case`has-slotted`:return 86;case`target-current`:return 87;case`heading`:return 88}return 0}function functionalPseudoClassId(e){switch(e){case`is`:return 1;case`matches`:return 1;case`-webkit-any`:return 1;case`where`:return 2;case`not`:return 3;case`has`:return 4;case`nth-child`:return 5;case`nth-last-child`:return 6;case`nth-of-type`:return 7;case`nth-last-of-type`:return 8;case`host`:return 9;case`host-context`:return 10;case`lang`:return 11;case`dir`:return 12;case`state`:return 13;case`current`:return 83;case`heading`:return 88}return 0}function isStructural(e){return e>=20&&e<=25||e===26||e===27||e===4||e>=5&&e<=8}function isKnownPseudoElement(e){switch(e){case`before`:case`after`:case`first-line`:case`first-letter`:case`marker`:case`placeholder`:case`selection`:case`backdrop`:case`file-selector-button`:case`target-text`:case`spelling-error`:case`grammar-error`:case`cue`:case`cue-region`:case`details-content`:case`checkmark`:case`picker-icon`:case`scroll-marker`:case`scroll-marker-group`:case`column`:case`view-transition`:return!0}return e.startsWith(`-webkit-`)||e.startsWith(`-moz-`)}function isKnownFunctionalPseudoElement(e){switch(e){case`slotted`:return 2;case`part`:return 3;case`highlight`:case`picker`:case`scroll-button`:case`cue`:case`cue-region`:case`view-transition-group`:case`view-transition-image-pair`:case`view-transition-old`:case`view-transition-new`:return 4}return 0}function isLegacyPseudoElement(e){return e===`before`||e===`after`||e===`first-line`||e===`first-letter`}var SelectorParser=class{src;toks;i;error;constructor(e){this.src=e,this.toks=tokenize$1(e),this.i=0,this.error=``}fail(e){this.error===``&&(this.error=e)}peek(){return this.toks[this.i]}peekType(){return this.toks[this.i].type}isDelim(e){let t=this.toks[this.i];return t.type===9&&t.value===e}isDelimAt(e,t){let n=this.toks[e];return n.type===9&&n.value===t}skipWs(){for(;this.toks[this.i].type===13;)this.i++}expectClose(e){let t=this.toks[this.i].type;return t===e?(this.i++,!0):t===0||(this.fail(`expected closing bracket`),!1)}parseSelectorList(){let e=this.parseComplexList(0,!1);return e===null?null:this.peekType()===0?e:(this.fail(`unexpected token`),null)}parseRelativeSelectorList(){let e=this.parseComplexList(3,!0);return e===null?null:this.peekType()===0?e:(this.fail(`unexpected token`),null)}parseComplexList(e,t){let n=new SelectorList;for(;;){this.skipWs();let r=this.parseComplex(e,t);if(r===null)return null;if(n.items.push(r),this.skipWs(),this.peekType()===18)this.i++;else break}return n}parseForgivingList(e){let t=new SelectorList;for(;;){this.skipWs();let n=this.peekType();if(n===22||n===0){if(t.items.length!==0){let e=new Complex;e.invalid=!0,t.items.push(e)}break}let r=this.i,i=this.error,a=this.parseComplex(e,!1);this.skipWs();let o=this.peekType();if(a!==null&&(o===18||o===22||o===0))t.items.push(a);else{if(this.error=i,this.i=r,!this.skipToTopLevelCommaOrClose())return this.fail(`unterminated block in forgiving selector list`),t;let e=new Complex;e.invalid=!0,e.text=trimWs(this.src.slice(this.toks[r].start,this.peek().start)),t.items.push(e)}if(this.peekType()===18)this.i++;else break}return t}skipToTopLevelCommaOrClose(){let e=[];for(;;){let t=this.peekType();if(t===0)return e.length===0;if(e.length===0&&(t===18||t===22))return!0;t===2||t===21?e.push(22):t===19?e.push(20):t===23?e.push(24):e.length!==0&&t===e[e.length-1]&&e.pop(),this.i++}}parseCombinator(){let e=!1;for(;this.peekType()===13;)this.i++,e=!0;let t=this.peek();if(t.type===9){if(t.value===`>`)return this.i++,this.skipWs(),2;if(t.value===`+`)return this.i++,this.skipWs(),3;if(t.value===`~`)return this.i++,this.skipWs(),4}return+!!e}parseComplex(e,t){let n=new Complex,r=this.peek().start;if(t){let e=this.parseCombinator();n.leading=e===0?1:e}for(;;){let t=this.parseCompound(e);if(t===null)return null;n.compounds.push(t);let r=this.i,i=this.parseCombinator(),a=this.peekType();if(i===0||a===18||a===22||a===0){if(i!==0&&i!==1)return this.fail(`dangling combinator`),null;this.i=r;break}if(t.pseudoElementIndex!==-1)return this.fail(`combinator after pseudo-element`),null;if(e&12)return this.fail(`expected a compound selector`),null;n.combinators.push(i)}let i=this.peek().start;return n.text=trimWs(this.src.slice(r,i)),n}parseTypeSelector(e){let t=this.peek(),n=0,r=``;if(t.type===9&&t.value===`|`){let e=this.toks[this.i+1];if(e.type===1||e.type===9&&e.value===`*`)n=2,this.i++;else return!1}else if((t.type===1||t.type===9&&t.value===`*`)&&this.isDelimAt(this.i+1,`|`)){let e=this.toks[this.i+2];(e.type===1||e.type===9&&e.value===`*`)&&(t.type===1?(n=3,r=t.value):n=1,this.i+=2)}let i=this.peek();if(i.type===1){let t=new Simple(1,i.value);return t.nsKind=n,t.nsPrefix=r,e.simples.push(t),this.i++,!0}if(i.type===9&&i.value===`*`){let t=new Simple(2,`*`);return t.nsKind=n,t.nsPrefix=r,e.simples.push(t),this.i++,!0}return n!==0&&this.fail(`expected a type selector after namespace prefix`),!1}parseCompound(e){let t=new Compound,n=!!(e&8);if(n||this.parseTypeSelector(t),this.error!==``)return null;for(;;){let r=this.peek(),i=t.pseudoElementIndex!==-1;if(n&&r.type!==16)break;if(r.type===4){if(i)break;if(!r.flag)return this.fail(`invalid id selector`),null;t.simples.push(new Simple(3,r.value)),this.i++}else if(r.type===9&&r.value===`.`){if(i)break;let e=this.toks[this.i+1];if(e.type!==1)return this.fail(`invalid class selector`),null;t.simples.push(new Simple(4,e.value)),this.i+=2}else if(r.type===19){if(i)break;this.i++;let e=this.parseAttribute();if(e===null)return null;t.simples.push(e)}else if(r.type===16){if(this.toks[this.i+1].type===16){if(this.i+=2,e&2)return this.fail(`pseudo-element not allowed here`),null;let n=this.parsePseudoElement(e);if(n===null)return null;if(t.pseudoElementIndex===-1)t.pseudoElementIndex=t.simples.length;else if(!this.chainablePseudoElement(t,n))return this.fail(`invalid pseudo-element chain`),null;t.simples.push(n)}else{this.i++;let n=this.parsePseudoClass(i?e|8:e);if(n===null)return null;if(n.kind===7){if(e&2||i)return this.fail(`pseudo-element not allowed here`),null;t.pseudoElementIndex=t.simples.length}else if(i&&!allowedAfterPseudoElement(this.lastPseudoElement(t),n.pseudo))return this.fail(`pseudo-class not allowed after pseudo-element`),null;t.simples.push(n)}}else break}return t.simples.length===0?(this.fail(`expected a selector`),null):t}lastPseudoElement(e){for(let t=e.simples.length-1;t>=0;t--){let n=e.simples[t];if(n.kind===7)return n.pseudo}return 0}chainablePseudoElement(e,t){let n=null;for(let t=e.simples.length-1;t>=0;t--){let r=e.simples[t];if(r.kind===7){n=r;break}}return n===null?!0:n.pseudo===3||n.pseudo===2?t.pseudo===1||t.pseudo===4:!1}parseAttribute(){this.skipWs();let e=new Simple(5,``),t=this.peek();t.type===9&&t.value===`|`&&this.toks[this.i+1].type===1?(e.nsKind=2,this.i++):t.type===9&&t.value===`*`&&this.isDelimAt(this.i+1,`|`)&&this.toks[this.i+2].type===1?(e.nsKind=1,this.i+=2):t.type===1&&this.isDelimAt(this.i+1,`|`)&&this.toks[this.i+2].type===1&&(e.nsKind=3,e.nsPrefix=t.value,this.i+=2);let n=this.peek();if(n.type!==1)return this.fail(`expected attribute name`),null;e.name=n.value,this.i++,this.skipWs();let r=this.peek();if(r.type===20||r.type===0)return r.type===20&&this.i++,e;if(r.type!==9)return this.fail(`expected attribute matcher`),null;let i=-1;if(r.value===`=`)i=1,this.i++;else if(this.isDelimAt(this.i+1,`=`)){switch(r.value){case`~`:i=2;break;case`|`:i=3;break;case`^`:i=4;break;case`$`:i=5;break;case`*`:i=6}i!==-1&&(this.i+=2)}if(i===-1)return this.fail(`invalid attribute matcher`),null;e.op=i,this.skipWs();let a=this.peek();if(a.type!==1&&a.type!==5)return this.fail(`expected attribute value`),null;e.value=a.value,this.i++,this.skipWs();let o=this.peek();if(o.type===1){let t=asciiLower$1(o.value);if(t===`i`)e.caseFlag=1;else if(t===`s`)e.caseFlag=2;else return this.fail(`invalid attribute modifier`),null;this.i++,this.skipWs()}return this.expectClose(20)?e:null}parsePseudoClass(e){let t=this.peek();if(t.type===1){let e=asciiLower$1(t.value);this.i++;let n=pseudoClassId(e);if(n!==0){let t=new Simple(6,e);return t.pseudo=n,t}if(isLegacyPseudoElement(e)){let t=new Simple(7,e);return t.pseudo=1,t}return this.fail(`unknown pseudo-class :`+e),null}if(t.type===2){let n=asciiLower$1(t.value);this.i++;let r=functionalPseudoClassId(n);if(r===0)return this.fail(`unknown pseudo-class :`+n+`()`),null;let i=new Simple(6,n);return i.pseudo=r,this.parsePseudoClassArgs(i,e)?i:null}return this.fail(`expected pseudo-class name`),null}parsePseudoClassArgs(e,t){let n=e.pseudo;if(n===1||n===2)return e.list=this.parseForgivingList(t|2),this.error===``&&this.expectClose(22);if(n===3){if(this.skipWs(),this.peekType()===22)return this.fail(`:not() requires an argument`),!1;let n=this.parseComplexList(t|2,!1);return n!==null&&(e.list=n,this.skipWs(),this.expectClose(22))}if(n===4){if(t&1)return this.fail(`:has() cannot be nested`),!1;if(this.skipWs(),this.peekType()===22)return this.fail(`:has() requires an argument`),!1;let n=this.parseComplexList(t|3,!0);return n!==null&&(e.list=n,this.skipWs(),this.expectClose(22))}if(n===5||n===6||n===7||n===8){if(this.skipWs(),!this.parseAnPlusB(e))return!1;this.clampAnb(e),this.skipWs();let r=this.peek();if((n===5||n===6)&&r.type===1&&asciiLower$1(r.value)===`of`){if(this.i++,this.peekType()!==13)return this.fail(`expected whitespace after 'of'`),!1;this.skipWs();let n=this.parseComplexList(t|2,!1);if(n===null)return!1;e.list=n,this.skipWs()}return this.expectClose(22)}if(n===9||n===10){this.skipWs();let n=this.parseComplexList(t|6,!1);return n===null?!1:n.items.length===1?(e.list=n,this.skipWs(),this.expectClose(22)):(this.fail(`expected a single compound selector`),!1)}if(n===11){for(;;){this.skipWs();let t=this.peek();if(t.type===1||t.type===5)e.args.push(t.value),this.i++;else return this.fail(`expected language range`),!1;if(this.skipWs(),this.peekType()===18)this.i++;else break}return this.expectClose(22)}if(n===12||n===13){this.skipWs();let t=this.peek();return t.type===1?(e.args.push(n===12?asciiLower$1(t.value):t.value),this.i++,this.skipWs(),this.expectClose(22)):(this.fail(`expected identifier`),!1)}if(n===88){for(;;){this.skipWs();let t=this.peek();if(t.type!==10||!t.isInt)return this.fail(`expected heading level`),!1;if(e.args.push(String(t.num)),this.i++,this.skipWs(),this.peekType()===18)this.i++;else break}return this.expectClose(22)}return n===83?(e.list=this.parseForgivingList(t|2),this.expectClose(22)):(this.fail(`unsupported functional pseudo-class`),!1)}parsePseudoElement(e){let t=this.peek();if(t.type===1){let e=asciiLower$1(t.value);if(this.i++,!isKnownPseudoElement(e))return this.fail(`unknown pseudo-element ::`+e),null;let n=new Simple(7,e);return n.pseudo=1,n}if(t.type===2){let n=asciiLower$1(t.value);this.i++;let r=isKnownFunctionalPseudoElement(n);if(r===0)return this.fail(`unknown pseudo-element ::`+n+`()`),null;let i=new Simple(7,n);if(i.pseudo=r,this.skipWs(),r===2){let t=this.parseComplexList(e|6,!1);if(t===null)return null;if(t.items.length!==1)return this.fail(`expected a single compound selector`),null;i.list=t}else{for(;this.peekType()===1;)i.args.push(this.peek().value),this.i++,this.skipWs();if(r===3&&i.args.length===0)return this.fail(`::part() requires an identifier`),null;if(this.peekType()!==22&&this.peekType()!==0){if(r===3)return this.fail(`invalid ::part() argument`),null;this.skipToTopLevelCommaOrClose()}}return this.skipWs(),this.expectClose(22)?i:null}return this.fail(`expected pseudo-element name`),null}parseAnPlusB(e){let t=this.peek();if(t.type===1){let n=asciiLower$1(t.value);if(n===`odd`)return e.a=2,e.b=1,this.i++,!0;if(n===`even`)return e.a=2,e.b=0,this.i++,!0}if(t.type===10)return t.isInt?(e.a=0,e.b=t.num,this.i++,!0):this.anbFail();let n=0,r=``;if(t.type===12){if(!t.isInt)return this.anbFail();let e=asciiLower$1(t.value);if(e.charCodeAt(0)!==110)return this.anbFail();n=t.num,r=e.slice(1),this.i++}else if(t.type===1){let e=asciiLower$1(t.value);if(e.charCodeAt(0)===110)n=1,r=e.slice(1);else if(e.charCodeAt(0)===45&&e.charCodeAt(1)===110)n=-1,r=e.slice(2);else return this.anbFail();this.i++}else if(t.type===9&&t.value===`+`){let e=this.toks[this.i+1];if(e.type!==1)return this.anbFail();let t=asciiLower$1(e.value);if(t.charCodeAt(0)!==110)return this.anbFail();n=1,r=t.slice(1),this.i+=2}else return this.anbFail();if(e.a=n,r===``){let t=this.i;this.skipWs();let n=this.peek();if(n.type===10&&n.isInt&&n.flag)return e.b=n.num,this.i++,!0;if(n.type===9&&(n.value===`+`||n.value===`-`)){this.i++,this.skipWs();let t=this.peek();return t.type===10&&t.isInt&&!t.flag?(e.b=n.value===`-`?-t.num:t.num,this.i++,!0):this.anbFail()}return this.i=t,e.b=0,!0}if(r===`-`){this.skipWs();let t=this.peek();return t.type===10&&t.isInt&&!t.flag?(e.b=-t.num,this.i++,!0):this.anbFail()}if(r.charCodeAt(0)===45&&r.length>1){let t=0;for(let e=1;e<r.length;e++){let n=r.charCodeAt(e);if(!isDigit$1(n))return this.anbFail();t=t*10+(n-48)}return e.b=-t,!0}return this.anbFail()}clampAnb(e){e.a>2147483647?e.a=2147483647:e.a<-2147483648&&(e.a=-2147483648),e.b>2147483647?e.b=2147483647:e.b<-2147483648&&(e.b=-2147483648)}anbFail(){return this.fail(`invalid An+B`),!1}};function trimWs(e){let t=0,n=e.length;for(;t<n&&isWhitespace$1(e.charCodeAt(t));)t++;for(;n>t&&isWhitespace$1(e.charCodeAt(n-1));)n--;return t===0&&n===e.length?e:e.slice(t,n)}function wrapperProp(e,t){return e.node[t]}const Ra={hovered:null,active:null};function shadowHost(e){let t=wrapperProp(e,R);return t==null?null:t[z]}function parentOrHost$1(e){let t=e.parent;return t===null?null:t.flags&32?shadowHost(t):t}__name(parentOrHost$1,`parentOrHost`);function isShadowIncludingInclusiveAncestor$3(e,t){for(;t!==null;t=parentOrHost$1(t))if(t===e)return!0;return!1}__name(isShadowIncludingInclusiveAncestor$3,`isShadowIncludingInclusiveAncestor`);function hover(e){let t=Ra.hovered;return t!==null&&isShadowIncludingInclusiveAncestor$3(e,t)}function active(e){let t=Ra.active;return t!==null&&isShadowIncludingInclusiveAncestor$3(e,t)}function anyLink(e){return e.tag===Z.a||e.tag===Z.area?attr(e,`href`)!==null:e.ns===`http://www.w3.org/2000/svg`&&e.name===`a`&&e.attrs!==null&&(attr(e,`href`)!==null||findAttributeByNamespace(e,`http://www.w3.org/1999/xlink`,`href`)!==null)}function never(e){return!1}function targetElement(e){let t=e.doc[q],n=t.indexOf(`#`);if(n===-1||n===t.length-1)return null;let r=t.slice(n+1);try{r=decodeURIComponent(r)}catch{}let i=e.doc,a=i._idLookup(r);if(a!==null)return a;let o=i[z];for(let e=o.first;e!==null;e=nextInTree(e,o))if(e.type===1&&e.tag===Z.a&&attr(e,`name`)===r)return e;return null}function target(e){return e.doc[q].indexOf(`#`)!==-1&&targetElement(e)===e}function targetWithin(e){if(e.doc[q].indexOf(`#`)===-1)return!1;let t=targetElement(e);return t!==null&&isShadowIncludingInclusiveAncestor$3(e,t)}function inputTypeName(e){let t=attr(e,`type`);if(t===null)return`text`;let n=asciiLowercase$1(t);switch(n){case`hidden`:case`text`:case`search`:case`tel`:case`url`:case`email`:case`password`:case`date`:case`month`:case`week`:case`time`:case`datetime-local`:case`number`:case`range`:case`color`:case`checkbox`:case`radio`:case`file`:case`submit`:case`image`:case`reset`:case`button`:return n}return`text`}function isHTML(e){return e.tag!==0}function controlValue$1(e){let t=wrapperProp(e,`value`);if(typeof t==`string`)return t;if(e.tag===Z.textarea){let t=``;for(let n=e.first;n!==null;n=n.next)n.type===3&&(t+=n.data);return t}return attr(e,`value`)??``}__name(controlValue$1,`controlValue`);function open(e){return(e.tag===Z.details||e.tag===Z.dialog)&&attr(e,`open`)!==null}function isMedia(e){return e.tag===Z.audio||e.tag===Z.video}function paused(e){return isMedia(e)&&wrapperProp(e,`paused`)!==!1}function playing(e){return isMedia(e)&&wrapperProp(e,`paused`)===!1}function muted(e){if(!isMedia(e))return!1;let t=wrapperProp(e,`muted`);return typeof t==`boolean`?t:attr(e,`muted`)!==null}function customState(e,t){let n=za.of(e);return n!==null&&n.has(t)}const za={of:e=>null};function elementLanguage(e){for(let t=e;t!==null;t=parentOrHost$1(t)){if(t.type!==1)continue;let e=t.attrs;if(e===null)continue;let n=null;for(let r=0;r<e.length;r++){let i=e[r];if(i.ns===`http://www.w3.org/XML/1998/namespace`&&i.localName===`lang`)return i.value;(i.ns===null&&i.localName===`lang`&&t.flags&2||i.ns===null&&i.localName===`lang`&&t.tag!==0)&&(n=i.value)}if(n!==null)return n}return null}function extendedFilter(e,t){if(e===``)return t===``;if(t===``)return!1;let n=asciiLowercase$1(e).split(`-`),r=asciiLowercase$1(t).split(`-`);for(let e=0;e<r.length;e++)if(r[e].length>8||r[e].length===0)return!1;if(n[0]!==`*`&&n[0]!==r[0])return!1;let i=1,a=1;for(;i<n.length;)if(n[i]===`*`)i++;else{if(a>=r.length)return!1;if(n[i]===r[a])i++,a++;else{if(r[a].length===1)return!1;a++}}return!0}function matchesLang(e,t){let n=elementLanguage(e);if(n===null)return!1;for(let e=0;e<t.length;e++)if(extendedFilter(t[e],n))return!0;return!1}function strongDirection(e){return e>=65&&e<=90||e>=97&&e<=122?1:e<192?0:e>=1424&&e<=2303||e>=64285&&e<=65023||e>=65136&&e<=65278||e>=67584&&e<=69631||e>=124928&&e<=126975?2:e===215||e===247||e>=8192&&e<=11263||e>=12288&&e<=12351||e>=65024&&e<=65135?0:1}function textDirection(e){for(let t=0;t<e.length;t++){let n=e.codePointAt(t);n>65535&&t++;let r=strongDirection(n);if(r!==0)return r}return 0}function hasValidDir(e){let t=attr(e,`dir`);if(t===null)return!1;let n=asciiLowercase$1(t);return n===`ltr`||n===`rtl`||n===`auto`}function autoDirectionality(e){if(e.tag===Z.textarea||e.tag===Z.input&&usesValueForDirectionality(inputTypeName(e))){let t=textDirection(controlValue$1(e));return t===0?1:t}if(e.tag===Z.input)return 0;for(let t=e.first;t!==null;){if(t.type===1){if(t.tag===Z.bdi||t.tag===Z.script||t.tag===Z.style||t.tag===Z.textarea||hasValidDir(t)){t=nextSkippingChildren(t,e);continue}}else if(t.type===3){let e=textDirection(t.data);if(e!==0)return e}t=nextInTree(t,e)}return 0}function directionality(e){for(let t=e;t!==null&&t.type===1;){let e=isHTML(t)?attr(t,`dir`):null,n=e===null?null:asciiLowercase$1(e);if(n!==null&&n!==`ltr`&&n!==`rtl`&&n!==`auto`&&(n=t.tag===Z.bdi?`auto`:null),n!==null){let e=n;if(e===`ltr`)return 1;if(e===`rtl`)return 2;if(e===`auto`){let e=autoDirectionality(t);if(e!==0)return e;if(t.tag===Z.input||t.tag===Z.textarea)return 1}}else if(t.tag===Z.bdi){let e=autoDirectionality(t);return e===0?1:e}else if(t.tag===Z.input&&inputTypeName(t)===`tel`)return 1;let r=parentOrHost$1(t);if(r===null||r.type===9)break;t=r}return 1}function usesValueForDirectionality(e){switch(e){case`hidden`:case`text`:case`search`:case`tel`:case`url`:case`email`:case`password`:case`submit`:case`reset`:case`button`:return!0}return!1}const Ba={hover,active,focus:never,"focus-within":never,"focus-visible":never,link:anyLink,"any-link":anyLink,visited:never,target,"target-within":targetWithin,defined:never,checked:never,indeterminate:never,default:never,disabled:never,enabled:never,required:never,optional:never,"read-only":never,"read-write":never,"placeholder-shown":never,valid:never,invalid:never,"in-range":never,"out-of-range":never,"user-valid":never,"user-invalid":never,autofill:never,"-webkit-autofill":never,open,"popover-open":never,modal:never,fullscreen:never,"picture-in-picture":never,playing,paused,muted,seeking:never,buffering:never,stalled:never,"volume-locked":never,current:never,past:never,future:never,"has-slotted":never,"target-current":never};function hash(e,t){let n=2166136261^t;for(let t=0;t<e.length;t++)n=Math.imul(n^e.charCodeAt(t),16777619);return(n^n>>>16)&4095}function tagHash(e){return hash(e,625341585)}function idHash(e){return hash(e,1821285621)}function classHash(e){return hash(e,461845907)}const Va=[];function elementTagHash(e){if(e.tag!==0&&e.flags&2){let t=Va[e.tag];return t===void 0?Va[e.tag]=tagHash(e.name):t}return tagHash(asciiLowercase$1(e.name))}let Ha=/* @__PURE__ */ new Int32Array,Ua=0;const Wa=[];function buildAncestorFilter(e){(++Ua===2147483647||Ha.length===0)&&(Ha.length===0?Ha=/* @__PURE__ */ new Int32Array(4096):Ha.fill(0),Ua=1);let t=Ua,n=0;for(let r=e.parent;r!==null&&r.type===1;r=r.parent){let e=elementTagHash(r);if(Ha[e]=t,Wa[n++]=e,r.id!==``){let e=idHash(r.id);Ha[e]=t,Wa[n++]=e}if(r.attrs!==null){let e=classTokens(r);for(let r=0;r<e.length;r++){let i=classHash(e[r]);Ha[i]=t,Wa[n++]=i}}}return Wa.length=n,Wa}function mayMatchAncestors(e,t,n,r){let i=Ua;return e<0?!0:Ha[e]===i?t<0?!0:Ha[t]===i?n<0?!0:Ha[n]===i?r<0||Ha[r]===i:!1:!1:!1}const Ga=/* @__PURE__ */ new Set(/* @__PURE__ */ `accept.accept-charset.align.alink.axis.bgcolor.charset.checked.clear.codetype.color.compact.declare.defer.dir.direction.disabled.enctype.face.frame.hreflang.http-equiv.lang.language.link.media.method.multiple.nohref.noresize.noshade.nowrap.readonly.rel.rev.rules.scope.scrolling.selected.shape.target.text.type.valign.valuetype.vlink`.split(`.`)),Ka=/* @__PURE__ */ new Set([30,31,32,53,54,55,56,57,58,52,70]);var Test=class{op;name;lower;nsCheck;ns;attrOp;value;valueLower;valueCase;a;b;list;fn;args;memoEl;memoIdx;memoVersion;memoParent;memoCount;memoCountVersion;volatileTest;constructor(e){this.op=e,this.name=``,this.lower=``,this.nsCheck=!1,this.ns=null,this.attrOp=0,this.value=``,this.valueLower=``,this.valueCase=0,this.a=0,this.b=0,this.list=null,this.fn=null,this.args=qa,this.memoEl=null,this.memoIdx=0,this.memoVersion=-1,this.memoParent=null,this.memoCount=0,this.memoCountVersion=-1,this.volatileTest=!1}};const qa=[];var CComplex=class{comps;combs;last;leading;hasDomain;pseudoElement;specificity;text;fn;constructor(){this.comps=[],this.combs=[],this.last=0,this.leading=0,this.hasDomain=0,this.pseudoElement=``,this.specificity=0,this.text=``,this.fn=e=>{let t=complexFn(this,0);return this.fn=t,t(e)}}},CList=class{items;fn;constructor(){this.items=[],this.fn=e=>{let t=listFn(this);return this.fn=t,t(e)}}},CompileInfo=class{treeOnly=!0;volatile;usesScope;nthTests;resolve;defaultNs;error;forgivingDropped;constructor(){this.volatile=!1,this.usesScope=!1,this.nthTests=[],this.resolve=null,this.defaultNs=void 0,this.error=``,this.forgivingDropped=!1}};function unpackSpecificity(e){return[Math.floor(e/1048576),Math.floor(e/1024)%1024,e%1024]}function listSpecificity(e){if(e===null)return 0;let t=0;for(let n=0;n<e.items.length;n++){if(e.items[n].invalid)continue;let r=complexSpecificity(e.items[n]);r>t&&(t=r)}return t}function complexSpecificity(e){let t=0;for(let n=0;n<e.compounds.length;n++)t+=compoundSpecificity(e.compounds[n]);return t}const Ja=1024;function compoundSpecificity(e){let t=0;for(let n=0;n<e.simples.length;n++){let r=e.simples[n];switch(r.kind){case 3:t+=1048576;break;case 4:case 5:t+=Ja;break;case 1:t+=1;break;case 2:break;case 7:t+=1+listSpecificity(r.list);break;case 6:switch(r.pseudo){case 2:break;case 1:case 3:case 4:case 83:t+=listSpecificity(r.list);break;case 5:case 6:case 9:case 10:t+=Ja+listSpecificity(r.list);break;default:t+=Ja}}}return t}function fail(e,t){e.error===``&&(e.error=t)}function resolvePrefix(e,t){return e.resolve===null?void 0:e.resolve(t)}function compileList(e,t){let n=new CList;for(let r=0;r<e.items.length;r++){let i=e.items[r];i.invalid||n.items.push(compileComplex(i,t))}return n}function compileForgivingList(e,t){let n=new CList;for(let r=0;r<e.items.length;r++){let i=e.items[r];if(i.invalid){t.forgivingDropped=!0;continue}let a=t.error,o=compileComplex(i,t);t.error===a?n.items.push(o):(t.error=a,t.forgivingDropped=!0)}return n}function compileComplex(e,t){let n=new CComplex,r=e.compounds.length;for(let i=r-1;i>=0;i--){let a=e.compounds[i];n.comps.push(compileCompound(a,t,n,i===r-1)),i>0&&n.combs.push(e.combinators[i-1])}return n.last=r-1,n.leading=e.leading,n.specificity=complexSpecificity(e),n.text=e.text,e.leading!==0&&(n.hasDomain=hasDomain(e)),n}function hasDomain(e){let t=!1;for(let n=0;n<e.combinators.length;n++){let r=e.combinators[n];(r===2||r===1)&&(t=!0)}switch(e.leading){case 2:return t?1:2;case 1:return 1;case 3:return t?5:e.combinators.length===0?3:4;default:return t?5:4}}function compileCompound(e,t,n,r){let i=[],a=e.pseudoElementIndex===-1?e.simples.length:e.pseudoElementIndex;for(let o=0;o<e.simples.length;o++){let s=e.simples[o];if(o>=a&&s.kind===7){r&&(n.pseudoElement=n.pseudoElement===``?s.name:n.pseudoElement+`::`+s.name);continue}let c=compileSimple(s,t);c!==null&&i.push(c)}if(t.defaultNs!==void 0&&needsImpliedNamespace(e,a)){let e=new Test(1);e.nsCheck=!0,e.ns=t.defaultNs,i.push(e)}return i}function needsImpliedNamespace(e,t){let n=t>0;for(let r=0;r<t;r++){let t=e.simples[r];if(t.kind===1||t.kind===2)return!1;(t.kind!==6||t.pseudo!==29&&t.pseudo!==9&&t.pseudo!==10)&&(n=!1)}return!n}function compileSimple(e,t){switch(e.kind!==1&&e.kind!==2&&(t.treeOnly=!1),e.kind){case 2:case 1:{let n=!1,r=null;switch(e.nsKind){case 0:t.defaultNs!==void 0&&(n=!0,r=t.defaultNs);break;case 1:break;case 2:n=!0,r=null;break;case 3:{let i=resolvePrefix(t,e.nsPrefix);if(i===void 0)return fail(t,`undeclared namespace prefix `+e.nsPrefix),new Test(0);n=!0,r=i;break}}if(e.kind===2){if(!n)return null;let e=new Test(1);return e.nsCheck=!0,e.ns=r,e}let i=new Test(2);return i.name=e.name,i.lower=asciiLowercase$1(e.name),i.a=tagId(i.lower),i.nsCheck=n,i.ns=r,i}case 3:{let t=new Test(3);return t.name=e.name,t.lower=asciiLowercase$1(e.name),t}case 4:{let t=new Test(4);return t.name=e.name,t.lower=asciiLowercase$1(e.name),t}case 5:return compileAttribute(e,t);case 6:return compilePseudoClass(e,t);case 7:return null}return null}function compileAttribute(e,t){let n=new Test(5);switch(n.name=e.name,n.lower=asciiLowercase$1(e.name),e.nsKind){case 0:case 2:n.nsCheck=!1;break;case 1:n.nsCheck=!0,n.ns=`*`;break;case 3:{let r=resolvePrefix(t,e.nsPrefix);if(r===void 0)return fail(t,`undeclared namespace prefix `+e.nsPrefix),new Test(0);r===null?n.nsCheck=!1:(n.nsCheck=!0,n.ns=r);break}}return n.attrOp=e.op,n.value=e.value,n.valueLower=asciiLowercase$1(e.value),n.valueCase=e.caseFlag===1?1:e.caseFlag===2?0:Ga.has(n.lower)?2:0,(e.op===4||e.op===5||e.op===6)&&e.value===``||e.op===2&&(e.value===``||hasWhitespace(e.value))?new Test(0):n}function hasWhitespace(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n===32||n===9||n===10||n===12||n===13)return!0}return!1}function compilePseudoClass(e,t){switch(e.pseudo){case 1:case 2:case 83:{let n=new Test(7);return n.list=compileForgivingList(e.list,t),n}case 3:{let n=new Test(8);return n.list=compileList(e.list,t),n}case 4:{let n=new Test(9);return n.list=compileList(e.list,t),n}case 5:case 6:case 7:case 8:return nthTest(e.pseudo,e.a,e.b,e.list,t);case 20:return nthTest(5,0,1,null,t);case 21:return nthTest(6,0,1,null,t);case 23:return nthTest(7,0,1,null,t);case 24:return nthTest(8,0,1,null,t);case 22:{let e=new Test(7),n=new CList,r=new CComplex;return r.comps.push([nthTest(5,0,1,null,t),nthTest(6,0,1,null,t)]),n.items.push(r),e.list=n,e}case 25:{let e=new Test(7),n=new CList,r=new CComplex;return r.comps.push([nthTest(7,0,1,null,t),nthTest(8,0,1,null,t)]),n.items.push(r),e.list=n,e}case 26:return new Test(14);case 27:return new Test(15);case 28:return t.usesScope=!0,new Test(16);case 29:return new Test(20);case 9:case 10:{let n=new Test(e.pseudo===9?21:22);return n.list=compileList(e.list,t),n}case 11:{let t=new Test(17);return t.args=e.args,t}case 12:{t.volatile=!0;let n=e.args[0];if(n!==`ltr`&&n!==`rtl`)return new Test(0);let r=new Test(18);return r.volatileTest=!0,r.a=n===`rtl`?2:1,r}case 88:{let t=new Test(23);return t.args=e.args,t}case 13:{t.volatile=!0;let n=new Test(19);return n.volatileTest=!0,n.name=e.args[0],n}}let n=Ba[e.name];if(n===void 0)return fail(t,`unsupported pseudo-class :`+e.name),new Test(0);let r=new Test(6);return Ka.has(e.pseudo)||(t.volatile=!0,r.volatileTest=!0),r.fn=n,r.name=e.name,r}function nthTest(e,t,n,r,i){let a=new Test(e===5?10:e===6?11:e===7?12:13);return a.a=t,a.b=n,r!==null&&(a.list=compileList(r,i)),i.nthTests.push(a),a}function resetMemos(e){let t=e.nthTests;for(let e=0;e<t.length;e++){let n=t[e];n.memoEl=null,n.memoParent=null,n.memoVersion=-1,n.memoCountVersion=-1}}var StateDeps=class{tests;els;results;constructor(){this.tests=[],this.els=[],this.results=[]}};let Ya=!1,Xa=null;function logDep(e,t,n){let r=Xa??=new StateDeps;r.tests.push(e),r.els.push(t),r.results.push(n)}function beginStateDeps(){let e=Ya?Xa:!1;return Ya=!0,Xa=null,e}function endStateDeps(e){let t=Xa;if(e===!1)Ya=!1,Xa=null;else if(Xa=e,t!==null)for(let e=0;e<t.tests.length;e++)logDep(t.tests[e],t.els[e],t.results[e]);return t}function stateDepsHold(e){let t=Ya;Ya=!1;let n=!0,r=e.tests;for(let t=0;t<r.length;t++)if(matchTest(r[t],e.els[t])!==e.results[t]){n=!1;break}return Ya=t,n}let Za=null,Qa=null,$a=null;function setScope(e){let t=Za;return Za=e,t}function setHostContext(e){let t=$a;return $a=e,t}function matchList(e,t){return e.fn(t)}function matchComplex(e,t){return e.fn(t)}const NEVER=()=>!1,ALWAYS=()=>!0;function listFn(e){let t=e.items;if(t.length===0)return NEVER;if(t.length===1){let e=t[0];return t=>e.fn(t)}return tagDispatch(t)??(e=>matchesAnyItem(t,e))}function matchesAnyItem(e,t){for(let n=0;n<e.length;n++)if(e[n].fn(t))return!0;return!1}function subjectTagTest(e){if(e.leading!==0)return null;let t=e.comps[0];for(let e=0;e<t.length;e++){let n=t[e];if(n.op===2)return!n.nsCheck&&n.a!==0?n:null}return null}function tagDispatch(e){let t=0,n=0,r=0;for(let i=0;i<e.length;i++){let a=subjectTagTest(e[i]);a!==null&&(n++,e[i].last===0&&e[i].comps[0].length===1&&r++,a.a>t&&(t=a.a))}if(n===0)return null;let i=new Uint8Array(t+1);if(r===e.length){for(let t of e)i[t.comps[0][0].a]=1;return t=>t.flags&2?i[t.tag]===1:matchesAnyItem(e,t)}let a=Array(t+1).fill(void 0),o=[];for(let t=0;t<e.length;t++){let n=e[t],r=subjectTagTest(n);r===null?o.push(n):n.last===0&&n.comps[0].length===1?i[r.a]=1:(a[r.a]??=[]).push(n)}return n=>{if(!(n.flags&2))return matchesAnyItem(e,n);let r=n.tag;if(r!==0&&r<=t){if(i[r]===1)return!0;let e=a[r];if(e!==void 0){for(let t=0;t<e.length;t++)if(e[t].fn(n))return!0}}for(let e=0;e<o.length;e++)if(o[e].fn(n))return!0;return!1}}function testFn(e){switch(e.op){case 2:{let t=e.lower,n=e.name;if(!e.nsCheck)return e=>e.flags&2?e.name===t:e.name===n;let r=e.ns;return e=>(e.flags&2?e.name===t:e.name===n)&&e.ns===r}case 4:{let t=e.name;return n=>{let r=classTokens(n);for(let e=0;e<r.length;e++)if(r[e]===t)return!0;return r.length!==0&&isQuirks$1(n.doc)&&quirksClassMatch(r,e.lower)}}case 3:{let t=e.name,n=e.lower;return e=>e.id===t||e.id!==``&&isQuirks$1(e.doc)&&asciiLowercase$1(e.id)===n}case 5:{if(e.nsCheck||e.valueCase!==0||e.attrOp!==0&&e.attrOp!==1)return t=>matchAttribute(e,t);let t=e.lower,n=e.name;if(e.attrOp===0)return e=>{let r=e.attrs;if(r===null)return!1;let i=e.flags&2?t:n;for(let e=0;e<r.length;e++)if(r[e].localName===i&&r[e].ns===null)return!0;return!1};let r=e.value;return e=>{let i=e.attrs;if(i===null)return!1;let a=e.flags&2?t:n;for(let e=0;e<i.length;e++){let t=i[e];if(t.localName===a&&t.ns===null)return t.value===r}return!1}}case 1:{let t=e.ns;return e=>e.ns===t}case 6:return e.volatileTest?t=>matchTest(e,t):e.fn;case 7:{let t=e.list;return e=>t.fn(e)}case 8:{let t=e.list;return e=>!t.fn(e)}case 9:{let t=e.list;return e=>matchHas(t,e)}case 10:case 11:case 12:case 13:return t=>matchNth(e,t);case 16:return e=>e===Za;case 0:return NEVER}return t=>matchTest(e,t)}function compoundFn(e){switch(e.length){case 0:return ALWAYS;case 1:return testFn(e[0]);case 2:{let t=testFn(e[0]),n=testFn(e[1]);return e=>t(e)&&n(e)}case 3:{let t=testFn(e[0]),n=testFn(e[1]),r=testFn(e[2]);return e=>t(e)&&n(e)&&r(e)}}let t=e.map(testFn);return e=>{for(let n=0;n<t.length;n++)if(!t[n](e))return!1;return!0}}function complexFn(e,t){let n=compoundFn(e.comps[t]);if(t===e.last){if(e.leading===0)return n;let t=e.leading;return e=>n(e)&&relatesToAnchor(t,e)}let r=t+1,i=complexFn(e,r);switch(e.combs[t]){case 1:return t=>{if(!n(t))return!1;for(let n=t.parent;n!==null;n=n.parent){if(n.type!==1)return hostStep(e,r,n);if(i(n))return!0}return!1};case 2:return t=>{if(!n(t))return!1;let a=t.parent;return a===null?!1:a.type===1?i(a):hostStep(e,r,a)};case 3:return e=>{if(!n(e))return!1;let t=e.prev;for(;t!==null&&t.type!==1;)t=t.prev;return t!==null&&i(t)};case 4:return e=>{if(!n(e))return!1;for(let t=e.prev;t!==null;t=t.prev)if(t.type===1&&i(t))return!0;return!1}}return NEVER}function hostStep(e,t,n){if(!(n.flags&32)||t!==e.last)return!1;let r=shadowHost(n);if(r===null)return!1;let i=$a;$a=r;let a=matchCompound(e.comps[t],r)&&(e.leading===0||relatesToAnchor(e.leading,r));return $a=i,a}function relatesToAnchor(e,t){let n=Qa;if(n===null)return!1;switch(e){case 2:return t.parent===n;case 1:for(let e=t.parent;e!==null;e=e.parent)if(e===n)return!0;return!1;case 3:{let e=t.prev;for(;e!==null&&e.type!==1;)e=e.prev;return e===n}case 4:for(let e=t.prev;e!==null;e=e.prev)if(e===n)return!0;return!1}return!1}function matchCompound(e,t){if($a!==null&&t===$a)return matchFeatureless(e,t);for(let n=0;n<e.length;n++)if(!matchTest(e[n],t))return!1;return!0}function matchFeatureless(e,t){return featurelessCompound(e,t)===1}function matchFeaturelessHost(e,t){let n=$a;$a=t;let r=featurelessComplex(e,t)===1;return $a=n,r}function featurelessComplex(e,t){return e.last!==0||e.leading!==0?-1:featurelessCompound(e.comps[0],t)}function featurelessList(e,t){let n=-1;for(let r=0;r<e.items.length;r++){let i=featurelessComplex(e.items[r],t);if(i===1)return 1;i===0&&(n=0)}return n}function featurelessCompound(e,t){let n=!1,r=1;for(let i=0;i<e.length;i++){let a=e[i];switch(a.op){case 20:case 21:case 22:n=!0,r===1&&!matchTest(a,t)&&(r=0);break;case 9:{let e=t.node[G];r===1&&!matchHas(a.list,e?e[z]:t)&&(r=0);break}case 7:{let e=featurelessList(a.list,t);if(e===-1)return-1;n=!0,e===0&&(r=0);break}case 8:{let e=featurelessList(a.list,t);if(e===-1)return-1;n=!0,e===1&&(r=0);break}default:return-1}}return n?r:-1}function isQuirks$1(e){return e[qn]===`quirks`}__name(isQuirks$1,`isQuirks`);function quirksClassMatch(e,t){for(let n=0;n<e.length;n++)if(asciiLowercase$1(e[n])===t)return!0;return!1}function matchTest(e,t){switch(e.op){case 2:return(t.flags&2?t.name!==e.lower:t.name!==e.name)?!1:!e.nsCheck||t.ns===e.ns;case 4:{let n=classTokens(t),r=e.name;for(let e=0;e<n.length;e++)if(n[e]===r)return!0;return n.length!==0&&isQuirks$1(t.doc)&&quirksClassMatch(n,e.lower)}case 3:return t.id===e.name||t.id!==``&&isQuirks$1(t.doc)&&asciiLowercase$1(t.id)===e.lower;case 5:return matchAttribute(e,t);case 1:return t.ns===e.ns;case 6:{let n=e.fn(t);return Ya&&e.volatileTest&&logDep(e,t,n),n}case 7:return matchList(e.list,t);case 8:return!matchList(e.list,t);case 9:return matchHas(e.list,t);case 10:case 11:case 12:case 13:return matchNth(e,t);case 14:for(let e=t.first;e!==null;e=e.next)if(e.type===1||(e.type===3||e.type===4)&&e.data.length!==0)return!1;return!0;case 15:{let e=t.parent;return e!==null&&e.type===9}case 16:return t===Za;case 17:return matchesLang(t,e.args);case 18:{let n=directionality(t)===e.a;return Ya&&logDep(e,t,n),n}case 19:{let n=customState(t,e.name);return Ya&&logDep(e,t,n),n}case 20:return $a!==null&&t===$a;case 21:{if($a===null||t!==$a)return!1;let n=$a;$a=null;let r=matchList(e.list,t);return $a=n,r}case 22:{if($a===null||t!==$a)return!1;let n=$a;$a=null;let r=!1;for(let n=t;n!==null&&!r;n=parentOrHost$1(n))n.type===1&&matchList(e.list,n)&&(r=!0);return $a=n,r}case 23:{let n=headingLevel(t);if(n===0)return!1;let r=e.args;if(r.length===0)return!0;for(let e=0;e<r.length;e++)if(Number(r[e])===n)return!0;return!1}case 0:return!1}return!1}function headingLevel(e){if(e.tag===0||e.name.length!==2||e.name.charCodeAt(0)!==104)return 0;let t=e.name.charCodeAt(1)-48;if(t<1||t>6)return 0;let n=t+headingOffset(e);return n>9?9:n}function headingOffset(e){let t=0;for(let n=e;n!==null;n=parentOrHost$1(n)){if(n.type!==1||n.tag===0||n.attrs===null)continue;let e=attr(n,`headingoffset`);if(e!==null){let n=parseNonNegativeInteger$1(e);n>0&&(t+=n)}if(attr(n,`headingreset`)!==null)break}return t}function parseNonNegativeInteger$1(e){let t=0;for(;t<e.length&&isWs$2(e.charCodeAt(t));)t++;t<e.length&&e.charCodeAt(t)===43&&t++;let n=-1;for(;t<e.length;t++){let r=e.charCodeAt(t)-48;if(r<0||r>9)break;n=(n===-1?0:n*10)+r}return n}__name(parseNonNegativeInteger$1,`parseNonNegativeInteger`);function matchAttribute(e,t){let n=t.attrs;if(n===null)return!1;let r=!!(t.flags&2),i=r?e.lower:e.name;for(let t=0;t<n.length;t++){let a=n[t];if(a.localName!==i)continue;if(e.nsCheck){if(e.ns!==`*`&&a.ns!==e.ns)continue}else if(a.ns!==null)continue;if(e.attrOp===0)return!0;let o=e.valueCase===1||e.valueCase===2&&r&&a.ns===null;if(attrValueMatches(e,o?asciiLowercase$1(a.value):a.value,o?e.valueLower:e.value))return!0;if(!e.nsCheck)return!1}return!1}function attrValueMatches(e,t,n){switch(e.attrOp){case 1:return t===n;case 2:{let e=t.length,r=n.length,i=0;for(;i<e;){for(;i<e&&isWs$2(t.charCodeAt(i));)i++;let a=i;for(;i<e&&!isWs$2(t.charCodeAt(i));)i++;if(i-a===r&&t.startsWith(n,a))return!0}return!1}case 3:return t===n||t.length>n.length&&t.charCodeAt(n.length)===45&&t.startsWith(n);case 4:return t.startsWith(n);case 5:return t.endsWith(n);case 6:return t.includes(n)}return!1}function isWs$2(e){return e===32||e===9||e===10||e===12||e===13}__name(isWs$2,`isWs`);function anb(e,t,n){if(e===0)return n===t;let r=n-t;return r/e>=0&&r%e===0}function sameType(e,t){return e.name===t.name&&e.ns===t.ns}function matchNth(e,t){let n=e.list;if(n!==null&&!matchList(n,t))return!1;let r=t.doc[J],i=e.op===12||e.op===13,a=e.op===11||e.op===13,o=1,s=t.prev;for(;s!==null&&!(s.type===1&&(i?sameType(s,t):n===null||matchList(n,s)));)s=s.prev;if(s!==null){if(s===e.memoEl&&e.memoVersion===r)o=e.memoIdx+1;else{o=2;for(let e=s.prev;e!==null;e=e.prev)e.type===1&&(i?sameType(e,t):n===null||matchList(n,e))&&o++}}if(e.memoEl=t,e.memoIdx=o,e.memoVersion=r,!a)return anb(e.a,e.b,o);let c=t.parent,l;if(!i&&n===null&&c!==null&&c===e.memoParent&&e.memoCountVersion===r)l=e.memoCount;else{l=o;for(let e=t.next;e!==null;e=e.next)e.type===1&&(i?sameType(e,t):n===null||matchList(n,e))&&l++;!i&&n===null&&(e.memoParent=c,e.memoCount=l,e.memoCountVersion=r)}return anb(e.a,e.b,l-o+1)}function matchHas(e,t){let n=Qa;Qa=t;let r=!1,i=e.items;for(let e=0;e<i.length&&!r;e++){let n=i[e];switch(n.hasDomain){case 2:for(let e=t.first;e!==null;e=e.next)if(e.type===1&&n.fn(e)){r=!0;break}break;case 1:for(let e=t.first;e!==null;){if(e.type===1&&n.fn(e)){r=!0;break}e=nextIn(e,t)}break;case 3:{let e=t.next;for(;e!==null&&e.type!==1;)e=e.next;r=e!==null&&n.fn(e);break}case 4:for(let e=t.next;e!==null;e=e.next)if(e.type===1&&n.fn(e)){r=!0;break}break;case 5:for(let e=t.next;e!==null&&!r;e=e.next)if(e.type===1){if(n.fn(e)){r=!0;break}for(let t=e.first;t!==null;){if(t.type===1&&n.fn(t)){r=!0;break}t=nextIn(t,e)}}}}return Qa=n,r}function nextIn(e,t){let n=e.first;if(n!==null)return n;let r=e;for(;r!==null&&r!==t;){let e=r.next;if(e!==null)return e;r=r.parent}return null}function subjectKey(e){let t=e.comps[0],n=``,r=``;for(let e=0;e<t.length;e++){let i=t[e];if(i.op===3)return{kind:1,value:i.name};i.op===4&&n===``?n=i.name:i.op===2&&r===``&&(r=i.lower)}return n===``?r===``?{kind:0,value:``}:{kind:3,value:r}:{kind:2,value:n}}function ancestorHashes(e){let t=[];if(e.leading!==0)return t;for(let n=0;n<3&&t.length<4;n++)for(let r=1;r<=e.last&&t.length<4;r++){let i=e.combs[r-1];if(i!==1&&i!==2)continue;let a=e.comps[r];for(let e=0;e<a.length&&t.length<4;e++){let r=a[e],i=-1;n===0&&r.op===3?i=idHash(r.name):n===1&&r.op===4?i=classHash(r.name):n===2&&r.op===2&&(i=tagHash(r.lower)),i!==-1&&t.indexOf(i)===-1&&t.push(i)}}return t}function idRootOf(e){if(e.items.length!==1)return``;let t=e.items[0];if(t.leading!==0)return``;for(let e=1;e<=t.last;e++){let n=t.combs[e-1];if(n!==1&&n!==2)return``;let r=t.comps[e];for(let e=0;e<r.length;e++)if(r[e].op===3)return r[e].name}return``}function attributeNamesIn(e,t){for(let n=0;n<=e.last;n++){let r=e.comps[n];for(let e=0;e<r.length;e++){let n=r[e];n.op===5&&(t(n.name),n.lower!==n.name&&t(n.lower));let i=n.list;if(i!==null)for(let e=0;e<i.items.length;e++)attributeNamesIn(i.items[e],t)}}}function subjectType(e){if(e.items.length!==1)return null;let t=e.items[0].comps[0];for(let e=0;e<t.length;e++){let n=t[e];if(n.op===2&&!n.nsCheck)return n}return null}function fastShape(e){if(e.items.length!==1)return 0;let t=e.items[0];if(t.last!==0)return 0;let n=t.comps[0];if(n.length===0)return 1;if(n.length!==1)return 0;let r=n[0];switch(r.op){case 3:return 2;case 4:return 3;case 2:return r.nsCheck?0:4;case 5:return r.nsCheck?0:r.attrOp===0||r.attrOp===1&&r.valueCase===0?5:0}return 0}function fastTest(e){return e.items[0].comps[0][0]}var Query=class{list;info;fast;fastT;hasMemos;idRoot;subject;indexedId;constructor(e,t){let n=new CList;for(let t=0;t<e.items.length;t++){let r=e.items[t];r.pseudoElement===``&&n.items.push(r)}this.list=n,this.info=t,this.fast=t.usesScope?0:fastShape(n),this.fastT=this.fast===0||this.fast===1?null:fastTest(n),this.hasMemos=t.nthTests.length!==0,this.idRoot=this.fast===0&&!t.usesScope?idRootOf(n):``,this.subject=this.fast===0?subjectType(n):null;let r=this.fastT;this.indexedId=this.fast===2?r.name:this.fast===5&&r.attrOp===1&&r.name===`id`?r.value:``}};const eo=/* @__PURE__ */ new Map;function clearSelectorCaches(){eo.clear()}function compileQuery(e){let t=new SelectorParser(e).parseSelectorList();if(t===null)return null;let n=new CompileInfo,r=compileList(t,n);return n.error===``?new Query(r,n):null}function interfaceName(e){return e.type===9?`Document`:e.type===1?`Element`:`DocumentFragment`}function syntaxError$1(e,t,n){return new DOMException(`Failed to execute '${t}' on '${interfaceName(n)}': '${e}' is not a valid selector.`,`SyntaxError`)}__name(syntaxError$1,`syntaxError`);function getQuery(e,t,n){let r=eo.get(e);if(r===void 0&&(r=compileQuery(e),eo.size>=2048&&eo.clear(),eo.set(e,r)),r===null)throw syntaxError$1(e,t,n);return r}function scopeFor(e){if(e.type===1)return e;if(e.type===9){for(let t=e.first;t!==null;t=t.next)if(t.type===1)return t}return null}function next(e,t){let n=e.first;if(n!==null)return n;let r=e;for(;r!==t;){let e=r.next;if(e!==null)return e;r=r.parent}return null}function hasClass(e,t){let n=classTokens(e);for(let e=0;e<n.length;e++)if(n[e]===t)return!0;return!1}function attrMatch(e,t,n){let r=e.attrs;if(r===null)return!1;let i=e.flags&2?t.lower:t.name;for(let e=0;e<r.length;e++){let a=r[e];if(a.localName===i&&a.ns===null)return n||a.value===t.value}return!1}function isQuirks(e){return e.doc[qn]===`quirks`}function run$1(e,t,n,r){if(t.indexedId!==``&&(t.fast!==2||!isQuirks(e))){let i=indexedDescendantById(e,t.indexedId);if(i!==void 0){if(i!==null){if(n)return i;r.push(i)}return null}}switch(t.fast){case 1:for(let t=e.first;t!==null;t=next(t,e))if(t.type===1){if(n)return t;r.push(t)}return null;case 2:{let i=t.fastT.name;if(!isQuirks(e)){for(let t=e.first;t!==null;t=next(t,e))if(t.type===1&&t.id===i){if(n)return t;r.push(t)}return null}break}case 3:{if(isQuirks(e))break;let i=t.fastT.name;for(let t=e.first;t!==null;t=next(t,e))if(t.type===1&&t.attrs!==null&&hasClass(t,i)){if(n)return t;r.push(t)}return null}case 4:{let i=t.fastT,a=i.lower,o=i.name;for(let t=e.first;t!==null;t=next(t,e))if(t.type===1&&(t.flags&2?t.name===a:t.name===o)){if(n)return t;r.push(t)}return null}case 5:{let i=t.fastT,a=i.attrOp===0;for(let t=e.first;t!==null;t=next(t,e))if(t.type===1&&attrMatch(t,i,a)){if(n)return t;r.push(t)}return null}}let i=t.list;if(i.items.length===0)return null;let a=e;if(t.idRoot!==``){let n=idRootFor(e,t.idRoot);if(n===null)return null;a=n}let o=setScope(t.info.usesScope?scopeFor(e):null);try{if(t.subject!==null&&a.type===9){let e=elementsOfType(a,t.subject);for(let t=0;t<e.length;t++){let a=e[t];if(matchList(i,a)){if(n)return a;r.push(a)}}return null}for(let e=a.first;e!==null;e=next(e,a))if(e.type===1&&matchList(i,e)){if(n)return e;r.push(e)}return null}finally{setScope(o),t.hasMemos&&resetMemos(t.info)}}__name(run$1,`run`);function indexedDescendantById(e,t){if(!(e.flags&1)||connectingRoot()!==null)return;let n=e.doc[Tn].get(t);if(n===void 0)return null;if(!Array.isArray(n)){for(let t=n.parent;t!==null;t=t.parent)if(t===e)return n;return null}}function idRootFor(e,t){if(!(e.flags&1)||isQuirks(e))return e;if(e.type!==9){let t=e;for(;t.parent!==null;)t=t.parent;if(t.type!==9)return e}let n=e.doc[Tn].get(t);if(n===void 0)return null;if(Array.isArray(n)||n===e)return e;for(let t=n.parent;t!==null;t=t.parent)if(t===e)return n;for(let t=e.parent;t!==null;t=t.parent)if(t===n)return e;return null}const to=[];var ResultEntry=class{version;all;first;constructor(e){this.version=e,this.all=null,this.first=void 0}},TypeList=class{version;elements;constructor(e,t){this.version=e,this.elements=t}};const no={},newTypes=()=>/* @__PURE__ */ new Map;function elementsOfType(e,t){let n=e.doc,r=derivedCache(n,no,newTypes),i=t.lower===t.name?t.name:`${t.lower}\n${t.name}`,a=n[ei],o=r.get(i);if(o!==void 0&&o.version===a)return o.elements;let s=t.lower,c=t.name,l=[];for(let t=e.first;t!==null;t=next(t,e))t.type===1&&(t.flags&2?t.name===s:t.name===c)&&l.push(t);return r.set(i,new TypeList(a,l)),l}const ro={},newResults=()=>/* @__PURE__ */ new WeakMap;function cacheable(e){return!e.info.volatile&&e.fast!==2}function cachedEntry(e,t,n){let r=e.doc,i=n?derivedCache(r,ro,newResults):peekDerivedCache(r,ro);if(i===void 0)return null;let a=i.get(e);if(a===void 0){if(!n)return null;a=/* @__PURE__ */ new Map,i.set(e,a)}let o=t.info.treeOnly?r[ei]:r[J],s=a.get(t);return s!==void 0&&s.version===o?s:n?(s===void 0?(a.size>=64&&a.clear(),s=new ResultEntry(o),a.set(t,s)):(s.version=o,s.all=null,s.first=void 0),s):null}function querySelector(e,t){let n=getQuery(t,`querySelector`,e);if(!cacheable(n))return run$1(e,n,!0,to);let r=cachedEntry(e,n,!1);if(r!==null){if(r.first!==void 0)return r.first;if(r.all!==null)return r.first=r.all.length===0?null:r.all[0]}let i=run$1(e,n,!0,to);return cachedEntry(e,n,!0).first=i,i}function querySelectorAll(e,t){return aa._staticFromImpls(allImpls(e,getQuery(t,`querySelectorAll`,e)))}function allImpls(e,t){if(!cacheable(t)){let n=[];return run$1(e,t,!1,n),n}let n=cachedEntry(e,t,!1);if(n!==null&&n.all!==null)return n.all;let r=[];run$1(e,t,!1,r);let i=cachedEntry(e,t,!0);return i.all=r,i.first=r.length===0?null:r[0],r}function matches(e,t){let n=getQuery(t,`matches`,e),r=n.list;if(!n.info.usesScope&&!n.hasMemos)return r.fn(e);if(r.items.length===0)return!1;let i=setScope(e);try{return matchList(r,e)}finally{setScope(i),n.hasMemos&&resetMemos(n.info)}}function closest(e,t){let n=getQuery(t,`closest`,e),r=n.list;if(r.items.length===0)return null;if(!n.info.usesScope&&!n.hasMemos)return closestMatch(e,r);let i=setScope(e);try{return closestMatch(e,r)}finally{setScope(i),n.hasMemos&&resetMemos(n.info)}}function closestMatch(e,t){for(let n=e;n!==null&&n.type===1;n=n.parent)if(t.fn(n))return n;return null}var CollectionState=class{root;childrenOnly;filter;structural;constructor(e,t,n,r){this.root=e,this.childrenOnly=t,this.filter=n,this.structural=r}},io=class HTMLCollection{constructor(e,t=!1,n=null,r=!1){Object.defineProperty(this,St,{value:new CollectionState(e,t,n,r)}),oo===null&&(oo=indexGetterTable(HTMLCollection.prototype,tableItem,256))}get _s(){return this[St]}get _rootImpl(){return this[St].root}static _childrenOf(e){return new HTMLCollection(e,!0,null,!0)}static _descendants(e,t,n){return new HTMLCollection(e,!1,n,t)}_collect(e){let t=this[St],n=t.root;if(t.childrenOnly){for(let t=n.first;t!==null;t=t.next)t.type===1&&e.push(t.node);return}let r=t.filter;if(r===null)for(let t=nextElementInTree(n,n);t!==null;t=nextElementInTree(t,n))e.push(t.node);else for(let t=nextElementInTree(n,n);t!==null;t=nextElementInTree(t,n))r(t)&&e.push(t.node)}_snapshot(){let e=this[St],t=e.root.doc,n=e.structural?t[ei]:t[J],r=cachedSnapshot(t,e,n);if(r!==void 0)return r;let i=[];return this._collect(i),storeSnapshot(t,e,n,i),i.length>oo.count&&ensureIndexGetters(oo,i.length),i}get length(){let e=this._snapshot().length;return e>oo.count&&ensureIndexGetters(oo,e),e}item(e){let t=this._snapshot(),n=Number(e)>>>0;return n<t.length?t[n]:null}namedItem(e){let t=String(e);if(t===``)return null;let n=this._snapshot();for(let e=0;e<n.length;e++){let r=n[e][z];if(r.id===t||r.ns===`http://www.w3.org/1999/xhtml`&&attr(r,`name`)===t)return n[e]}return null}_supportedPropertyNames(){let e=[],t=this._snapshot();for(let n=0;n<t.length;n++){let r=t[n][z];if(r.id!==``&&!e.includes(r.id)&&e.push(r.id),r.ns===`http://www.w3.org/1999/xhtml`){let t=attr(r,`name`);t!==null&&t!==``&&!e.includes(t)&&e.push(t)}}return e}};const ao={values(){let e=iterableTarget(this);return new CollectionIterator(e,e instanceof io)}}.values;Object.defineProperties(io.prototype,{[Symbol.iterator]:{value:ao,writable:!0,configurable:!0},[Symbol.toStringTag]:{value:`HTMLCollection`,configurable:!0}});let oo=null;function tableItem(e,t){let n=e._snapshot();return t<n.length?n[t]:void 0}function ensureCollectionIndexGetters(e){oo!==null&&ensureIndexGetters(oo,e)}function isArrayIndex$1(e){let t=e.charCodeAt(0);if(t<48||t>57)return!1;let n=Number(e);return Number.isInteger(n)&&n>=0&&n<4294967295&&String(n)===e}__name(isArrayIndex$1,`isArrayIndex`);function withNamedProperties(e){return new Proxy(e,so)}const so={get(e,t){let n=t===`length`?e.length:e[t];return n!==void 0||typeof t==`symbol`||t in e?n:isArrayIndex$1(t)?e.item(Number(t))??void 0:e.namedItem(t)??void 0},has(e,t){return typeof t==`string`&&!(t in e)?isArrayIndex$1(t)?Number(t)<e.length:e.namedItem(t)!==null:typeof t==`string`&&isArrayIndex$1(t)?Number(t)<e.length:Reflect.has(e,t)},ownKeys(e){let t=[],n=e.length;for(let e=0;e<n;e++)t.push(String(e));for(let n of e._supportedPropertyNames())n in e||t.push(n);for(let n of Reflect.ownKeys(e))t.push(n);return t},getOwnPropertyDescriptor(e,t){if(typeof t==`string`){if(isArrayIndex$1(t)){let n=e.item(Number(t));return n===null?void 0:{value:n,writable:!1,enumerable:!0,configurable:!0}}if(!(t in e)){let n=e.namedItem(t);if(n!==null)return{value:n,writable:!1,enumerable:!1,configurable:!0}}}return Reflect.getOwnPropertyDescriptor(e,t)},set(e,t,n){return typeof t==`string`&&(isArrayIndex$1(t)||e.namedItem(t)!==null)?!1:Reflect.set(e,t,n,e)},defineProperty(e,t,n){return typeof t==`string`&&(isArrayIndex$1(t)||e.namedItem(t)!==null)?!1:Reflect.defineProperty(e,t,n)},deleteProperty(e,t){return typeof t==`string`&&isArrayIndex$1(t)?Number(t)>=e.length:typeof t==`string`&&!(t in e)&&e.namedItem(t)!==null?!1:Reflect.deleteProperty(e,t)}};function define(e,t){for(let n of Reflect.ownKeys(t))Object.defineProperty(e.prototype,n,Object.getOwnPropertyDescriptor(t,n))}function convertNodesIntoNode(e,t){if(e.length===1)return toNode(e[0],t)[z];let n=t.createDocumentFragment();for(let r of e)n.appendChild(toNode(r,t));return n[z]}function toNode(e,t){return typeof e==`object`&&e&&z in e?e:t.createTextNode(String(e))}function nodeArg(e,t,n,r){if(typeof e==`object`&&e&&z in e)return e[z];throw TypeError(`Failed to execute '${t}' on '${parentNodeInterface(r)}': parameter ${n} is not of type 'Node'.`)}function parentNodeInterface(e){return e.type===1?`Element`:e.type===11?`DocumentFragment`:`Document`}function wrap(e){return e===null?null:e.node}const co={get children(){let e=this;return e[lt]??=io._childrenOf(e[z])},get firstElementChild(){return wrap(firstElementChild(this[z]))},get lastElementChild(){return wrap(lastElementChild(this[z]))},get childElementCount(){let e=0;for(let t=this[z].first;t!==null;t=t.next)t.type===1&&e++;return e},prepend(...e){let t=this[z];preInsert(convertNodesIntoNode(e,t.doc),t,t.first)},append(...e){let t=this[z];preInsert(convertNodesIntoNode(e,t.doc),t,null)},replaceChildren(...e){let t=this[z],n=convertNodesIntoNode(e,t.doc);ensureReplaceAllValidity(n,t),replaceAll(n,t)},moveBefore(e,t){arguments.length<2&&argumentsRequired(`moveBefore`,parentNodeInterface(this[z]),2,arguments.length);let n=nodeArg(e,`moveBefore`,1,this[z]),r=t===null?null:nodeArg(t,`moveBefore`,2,this[z]);r===n&&(r=n.next),move(n,this[z],r)},querySelector(e){return arguments.length===0&&argumentsRequired(`querySelector`,parentNodeInterface(this[z]),1,0),wrap(querySelector(this[z],String(e)))},querySelectorAll(e){return arguments.length===0&&argumentsRequired(`querySelectorAll`,parentNodeInterface(this[z]),1,0),querySelectorAll(this[z],String(e))}},lo={before(...e){let t=this[z],n=t.parent;if(n===null)return;let r=t.prev;for(;r!==null&&e.includes(r.node);)r=r.prev;preInsert(convertNodesIntoNode(e,t.doc),n,r===null?n.first:r.next)},after(...e){let t=this[z],n=t.parent;if(n===null)return;let r=t.next;for(;r!==null&&e.includes(r.node);)r=r.next;preInsert(convertNodesIntoNode(e,t.doc),n,r)},replaceWith(...e){let t=this[z],n=t.parent;if(n===null)return;let r=t.next;for(;r!==null&&e.includes(r.node);)r=r.next;let i=convertNodesIntoNode(e,t.doc);t.parent===n?replace(t,i,n):preInsert(i,n,r)},remove(){let e=this[z];e.parent!==null&&remove(e,!1)}},uo={get previousElementSibling(){return wrap(previousElementSibling(this[z]))},get nextElementSibling(){return wrap(nextElementSibling(this[z]))}},fo={getElementById(e){let t=this[z],n=String(e);if(n===``)return null;if(t.type!==11)return wrap(this._idLookup(n));for(let e=nextElementInTree(t,t);e!==null;e=nextElementInTree(e,t))if(e.id===n)return e.node;return null}};function installParentNode(e){define(e,co),addUnscopables(e,[`prepend`,`append`,`replaceChildren`])}function installChildNode(e){define(e,lo),addUnscopables(e,[`before`,`after`,`replaceWith`,`remove`])}function addUnscopables(e,t){let n=e.prototype,r=Object.getOwnPropertyDescriptor(n,Symbol.unscopables)?.value;r===void 0&&(r=Object.create(null),Object.defineProperty(n,Symbol.unscopables,{value:r,configurable:!0}));for(let e of t)r[e]=!0}function installNonDocumentTypeChildNode(e){define(e,uo)}function installNonElementParentNode(e){define(e,fo)}function arity$1(e,t,n){throw TypeError(`Failed to execute '${e}' on 'CharacterData': ${t} argument${t===1?``:`s`} required, but only ${n} present.`)}__name(arity$1,`arity`);function nodeDocumentFor(e){return typeof e==`object`&&e&&e[z]?.type===9?e:currentDocument()}var CharacterData=class extends Node{get data(){return this[z].data}set data(e){let t=this[z];replaceData(t,0,t.data.length,e===null?``:String(e))}get length(){return this[z].data.length}substringData(e,t){arguments.length<2&&arity$1(`substringData`,2,arguments.length);let n=this[z].data;if(e>>>=0,t>>>=0,e>n.length)throw new DOMException(`Offset is greater than the node's length.`,`IndexSizeError`);return n.substring(e,e+t)}appendData(e){arguments.length<1&&arity$1(`appendData`,1,0);let t=this[z],n=String(e);replaceData(t,t.data.length,0,n)}insertData(e,t){arguments.length<2&&arity$1(`insertData`,2,arguments.length),replaceData(this[z],e>>>0,0,String(t))}deleteData(e,t){arguments.length<2&&arity$1(`deleteData`,2,arguments.length),replaceData(this[z],e>>>0,t>>>0,``)}replaceData(e,t,n){arguments.length<3&&arity$1(`replaceData`,3,arguments.length),replaceData(this[z],e>>>0,t>>>0,String(n))}};installChildNode(CharacterData),installNonDocumentTypeChildNode(CharacterData);var Text=class extends CharacterData{constructor(e=``,t){super(3,nodeDocumentFor(t)),this[z].data=String(e)}splitText(e){return splitText(this[z],Number(e)>>>0).node}get wholeText(){let e=this[z];for(;e.prev!==null&&(e.prev.type===3||e.prev.type===4);)e=e.prev;let t=``;for(let n=e;n!==null&&(n.type===3||n.type===4);n=n.next)t+=n.data;return t}get assignedSlot(){if(Da===0)return null;let e=assignedSlot(this[z]);if(e===null)return null;let t=this[z].parent,n=t===null?null:t.node[G];return n!=null&&n.mode===`open`?e.node:null}},CDATASection=class extends Text{constructor(e=``,t=currentDocument()){super(e,t),this[z].type=4}},Comment=class extends CharacterData{constructor(e=``,t){super(8,nodeDocumentFor(t)),this[z].data=String(e)}},ProcessingInstruction=class extends CharacterData{constructor(e,t,n=currentDocument()){super(7,n),this[z].name=e,this[z].data=t}get target(){return this[z].name}},DocumentFragment=class extends Node{[R];constructor(e=currentDocument()){super(11,e),this[R]=null}};installParentNode(DocumentFragment),installNonElementParentNode(DocumentFragment);var DocumentType=class extends Node{[qr];constructor(e,t,n,r){super(10,e);let i=this[z];i.name=t,i.data=n,this[qr]=r}get name(){return this[z].name}get publicId(){return this[z].data}get systemId(){return this[qr]}};installChildNode(DocumentType);const po=`AElig,AElig;,AMP,AMP;,Aacute,Aacute;,Abreve;,Acirc,Acirc;,Acy;,Afr;,Agrave,Agrave;,Alpha;,Amacr;,And;,Aogon;,Aopf;,ApplyFunction;,Aring,Aring;,Ascr;,Assign;,Atilde,Atilde;,Auml,Auml;,Backslash;,Barv;,Barwed;,Bcy;,Because;,Bernoullis;,Beta;,Bfr;,Bopf;,Breve;,Bscr;,Bumpeq;,CHcy;,COPY,COPY;,Cacute;,Cap;,CapitalDifferentialD;,Cayleys;,Ccaron;,Ccedil,Ccedil;,Ccirc;,Cconint;,Cdot;,Cedilla;,CenterDot;,Cfr;,Chi;,CircleDot;,CircleMinus;,CirclePlus;,CircleTimes;,ClockwiseContourIntegral;,CloseCurlyDoubleQuote;,CloseCurlyQuote;,Colon;,Colone;,Congruent;,Conint;,ContourIntegral;,Copf;,Coproduct;,CounterClockwiseContourIntegral;,Cross;,Cscr;,Cup;,CupCap;,DD;,DDotrahd;,DJcy;,DScy;,DZcy;,Dagger;,Darr;,Dashv;,Dcaron;,Dcy;,Del;,Delta;,Dfr;,DiacriticalAcute;,DiacriticalDot;,DiacriticalDoubleAcute;,DiacriticalGrave;,DiacriticalTilde;,Diamond;,DifferentialD;,Dopf;,Dot;,DotDot;,DotEqual;,DoubleContourIntegral;,DoubleDot;,DoubleDownArrow;,DoubleLeftArrow;,DoubleLeftRightArrow;,DoubleLeftTee;,DoubleLongLeftArrow;,DoubleLongLeftRightArrow;,DoubleLongRightArrow;,DoubleRightArrow;,DoubleRightTee;,DoubleUpArrow;,DoubleUpDownArrow;,DoubleVerticalBar;,DownArrow;,DownArrowBar;,DownArrowUpArrow;,DownBreve;,DownLeftRightVector;,DownLeftTeeVector;,DownLeftVector;,DownLeftVectorBar;,DownRightTeeVector;,DownRightVector;,DownRightVectorBar;,DownTee;,DownTeeArrow;,Downarrow;,Dscr;,Dstrok;,ENG;,ETH,ETH;,Eacute,Eacute;,Ecaron;,Ecirc,Ecirc;,Ecy;,Edot;,Efr;,Egrave,Egrave;,Element;,Emacr;,EmptySmallSquare;,EmptyVerySmallSquare;,Eogon;,Eopf;,Epsilon;,Equal;,EqualTilde;,Equilibrium;,Escr;,Esim;,Eta;,Euml,Euml;,Exists;,ExponentialE;,Fcy;,Ffr;,FilledSmallSquare;,FilledVerySmallSquare;,Fopf;,ForAll;,Fouriertrf;,Fscr;,GJcy;,GT,GT;,Gamma;,Gammad;,Gbreve;,Gcedil;,Gcirc;,Gcy;,Gdot;,Gfr;,Gg;,Gopf;,GreaterEqual;,GreaterEqualLess;,GreaterFullEqual;,GreaterGreater;,GreaterLess;,GreaterSlantEqual;,GreaterTilde;,Gscr;,Gt;,HARDcy;,Hacek;,Hat;,Hcirc;,Hfr;,HilbertSpace;,Hopf;,HorizontalLine;,Hscr;,Hstrok;,HumpDownHump;,HumpEqual;,IEcy;,IJlig;,IOcy;,Iacute,Iacute;,Icirc,Icirc;,Icy;,Idot;,Ifr;,Igrave,Igrave;,Im;,Imacr;,ImaginaryI;,Implies;,Int;,Integral;,Intersection;,InvisibleComma;,InvisibleTimes;,Iogon;,Iopf;,Iota;,Iscr;,Itilde;,Iukcy;,Iuml,Iuml;,Jcirc;,Jcy;,Jfr;,Jopf;,Jscr;,Jsercy;,Jukcy;,KHcy;,KJcy;,Kappa;,Kcedil;,Kcy;,Kfr;,Kopf;,Kscr;,LJcy;,LT,LT;,Lacute;,Lambda;,Lang;,Laplacetrf;,Larr;,Lcaron;,Lcedil;,Lcy;,LeftAngleBracket;,LeftArrow;,LeftArrowBar;,LeftArrowRightArrow;,LeftCeiling;,LeftDoubleBracket;,LeftDownTeeVector;,LeftDownVector;,LeftDownVectorBar;,LeftFloor;,LeftRightArrow;,LeftRightVector;,LeftTee;,LeftTeeArrow;,LeftTeeVector;,LeftTriangle;,LeftTriangleBar;,LeftTriangleEqual;,LeftUpDownVector;,LeftUpTeeVector;,LeftUpVector;,LeftUpVectorBar;,LeftVector;,LeftVectorBar;,Leftarrow;,Leftrightarrow;,LessEqualGreater;,LessFullEqual;,LessGreater;,LessLess;,LessSlantEqual;,LessTilde;,Lfr;,Ll;,Lleftarrow;,Lmidot;,LongLeftArrow;,LongLeftRightArrow;,LongRightArrow;,Longleftarrow;,Longleftrightarrow;,Longrightarrow;,Lopf;,LowerLeftArrow;,LowerRightArrow;,Lscr;,Lsh;,Lstrok;,Lt;,Map;,Mcy;,MediumSpace;,Mellintrf;,Mfr;,MinusPlus;,Mopf;,Mscr;,Mu;,NJcy;,Nacute;,Ncaron;,Ncedil;,Ncy;,NegativeMediumSpace;,NegativeThickSpace;,NegativeThinSpace;,NegativeVeryThinSpace;,NestedGreaterGreater;,NestedLessLess;,NewLine;,Nfr;,NoBreak;,NonBreakingSpace;,Nopf;,Not;,NotCongruent;,NotCupCap;,NotDoubleVerticalBar;,NotElement;,NotEqual;,NotEqualTilde;,NotExists;,NotGreater;,NotGreaterEqual;,NotGreaterFullEqual;,NotGreaterGreater;,NotGreaterLess;,NotGreaterSlantEqual;,NotGreaterTilde;,NotHumpDownHump;,NotHumpEqual;,NotLeftTriangle;,NotLeftTriangleBar;,NotLeftTriangleEqual;,NotLess;,NotLessEqual;,NotLessGreater;,NotLessLess;,NotLessSlantEqual;,NotLessTilde;,NotNestedGreaterGreater;,NotNestedLessLess;,NotPrecedes;,NotPrecedesEqual;,NotPrecedesSlantEqual;,NotReverseElement;,NotRightTriangle;,NotRightTriangleBar;,NotRightTriangleEqual;,NotSquareSubset;,NotSquareSubsetEqual;,NotSquareSuperset;,NotSquareSupersetEqual;,NotSubset;,NotSubsetEqual;,NotSucceeds;,NotSucceedsEqual;,NotSucceedsSlantEqual;,NotSucceedsTilde;,NotSuperset;,NotSupersetEqual;,NotTilde;,NotTildeEqual;,NotTildeFullEqual;,NotTildeTilde;,NotVerticalBar;,Nscr;,Ntilde,Ntilde;,Nu;,OElig;,Oacute,Oacute;,Ocirc,Ocirc;,Ocy;,Odblac;,Ofr;,Ograve,Ograve;,Omacr;,Omega;,Omicron;,Oopf;,OpenCurlyDoubleQuote;,OpenCurlyQuote;,Or;,Oscr;,Oslash,Oslash;,Otilde,Otilde;,Otimes;,Ouml,Ouml;,OverBar;,OverBrace;,OverBracket;,OverParenthesis;,PartialD;,Pcy;,Pfr;,Phi;,Pi;,PlusMinus;,Poincareplane;,Popf;,Pr;,Precedes;,PrecedesEqual;,PrecedesSlantEqual;,PrecedesTilde;,Prime;,Product;,Proportion;,Proportional;,Pscr;,Psi;,QUOT,QUOT;,Qfr;,Qopf;,Qscr;,RBarr;,REG,REG;,Racute;,Rang;,Rarr;,Rarrtl;,Rcaron;,Rcedil;,Rcy;,Re;,ReverseElement;,ReverseEquilibrium;,ReverseUpEquilibrium;,Rfr;,Rho;,RightAngleBracket;,RightArrow;,RightArrowBar;,RightArrowLeftArrow;,RightCeiling;,RightDoubleBracket;,RightDownTeeVector;,RightDownVector;,RightDownVectorBar;,RightFloor;,RightTee;,RightTeeArrow;,RightTeeVector;,RightTriangle;,RightTriangleBar;,RightTriangleEqual;,RightUpDownVector;,RightUpTeeVector;,RightUpVector;,RightUpVectorBar;,RightVector;,RightVectorBar;,Rightarrow;,Ropf;,RoundImplies;,Rrightarrow;,Rscr;,Rsh;,RuleDelayed;,SHCHcy;,SHcy;,SOFTcy;,Sacute;,Sc;,Scaron;,Scedil;,Scirc;,Scy;,Sfr;,ShortDownArrow;,ShortLeftArrow;,ShortRightArrow;,ShortUpArrow;,Sigma;,SmallCircle;,Sopf;,Sqrt;,Square;,SquareIntersection;,SquareSubset;,SquareSubsetEqual;,SquareSuperset;,SquareSupersetEqual;,SquareUnion;,Sscr;,Star;,Sub;,Subset;,SubsetEqual;,Succeeds;,SucceedsEqual;,SucceedsSlantEqual;,SucceedsTilde;,SuchThat;,Sum;,Sup;,Superset;,SupersetEqual;,Supset;,THORN,THORN;,TRADE;,TSHcy;,TScy;,Tab;,Tau;,Tcaron;,Tcedil;,Tcy;,Tfr;,Therefore;,Theta;,ThickSpace;,ThinSpace;,Tilde;,TildeEqual;,TildeFullEqual;,TildeTilde;,Topf;,TripleDot;,Tscr;,Tstrok;,Uacute,Uacute;,Uarr;,Uarrocir;,Ubrcy;,Ubreve;,Ucirc,Ucirc;,Ucy;,Udblac;,Ufr;,Ugrave,Ugrave;,Umacr;,UnderBar;,UnderBrace;,UnderBracket;,UnderParenthesis;,Union;,UnionPlus;,Uogon;,Uopf;,UpArrow;,UpArrowBar;,UpArrowDownArrow;,UpDownArrow;,UpEquilibrium;,UpTee;,UpTeeArrow;,Uparrow;,Updownarrow;,UpperLeftArrow;,UpperRightArrow;,Upsi;,Upsilon;,Uring;,Uscr;,Utilde;,Uuml,Uuml;,VDash;,Vbar;,Vcy;,Vdash;,Vdashl;,Vee;,Verbar;,Vert;,VerticalBar;,VerticalLine;,VerticalSeparator;,VerticalTilde;,VeryThinSpace;,Vfr;,Vopf;,Vscr;,Vvdash;,Wcirc;,Wedge;,Wfr;,Wopf;,Wscr;,Xfr;,Xi;,Xopf;,Xscr;,YAcy;,YIcy;,YUcy;,Yacute,Yacute;,Ycirc;,Ycy;,Yfr;,Yopf;,Yscr;,Yuml;,ZHcy;,Zacute;,Zcaron;,Zcy;,Zdot;,ZeroWidthSpace;,Zeta;,Zfr;,Zopf;,Zscr;,aacute,aacute;,abreve;,ac;,acE;,acd;,acirc,acirc;,acute,acute;,acy;,aelig,aelig;,af;,afr;,agrave,agrave;,alefsym;,aleph;,alpha;,amacr;,amalg;,amp,amp;,and;,andand;,andd;,andslope;,andv;,ang;,ange;,angle;,angmsd;,angmsdaa;,angmsdab;,angmsdac;,angmsdad;,angmsdae;,angmsdaf;,angmsdag;,angmsdah;,angrt;,angrtvb;,angrtvbd;,angsph;,angst;,angzarr;,aogon;,aopf;,ap;,apE;,apacir;,ape;,apid;,apos;,approx;,approxeq;,aring,aring;,ascr;,ast;,asymp;,asympeq;,atilde,atilde;,auml,auml;,awconint;,awint;,bNot;,backcong;,backepsilon;,backprime;,backsim;,backsimeq;,barvee;,barwed;,barwedge;,bbrk;,bbrktbrk;,bcong;,bcy;,bdquo;,becaus;,because;,bemptyv;,bepsi;,bernou;,beta;,beth;,between;,bfr;,bigcap;,bigcirc;,bigcup;,bigodot;,bigoplus;,bigotimes;,bigsqcup;,bigstar;,bigtriangledown;,bigtriangleup;,biguplus;,bigvee;,bigwedge;,bkarow;,blacklozenge;,blacksquare;,blacktriangle;,blacktriangledown;,blacktriangleleft;,blacktriangleright;,blank;,blk12;,blk14;,blk34;,block;,bne;,bnequiv;,bnot;,bopf;,bot;,bottom;,bowtie;,boxDL;,boxDR;,boxDl;,boxDr;,boxH;,boxHD;,boxHU;,boxHd;,boxHu;,boxUL;,boxUR;,boxUl;,boxUr;,boxV;,boxVH;,boxVL;,boxVR;,boxVh;,boxVl;,boxVr;,boxbox;,boxdL;,boxdR;,boxdl;,boxdr;,boxh;,boxhD;,boxhU;,boxhd;,boxhu;,boxminus;,boxplus;,boxtimes;,boxuL;,boxuR;,boxul;,boxur;,boxv;,boxvH;,boxvL;,boxvR;,boxvh;,boxvl;,boxvr;,bprime;,breve;,brvbar,brvbar;,bscr;,bsemi;,bsim;,bsime;,bsol;,bsolb;,bsolhsub;,bull;,bullet;,bump;,bumpE;,bumpe;,bumpeq;,cacute;,cap;,capand;,capbrcup;,capcap;,capcup;,capdot;,caps;,caret;,caron;,ccaps;,ccaron;,ccedil,ccedil;,ccirc;,ccups;,ccupssm;,cdot;,cedil,cedil;,cemptyv;,cent,cent;,centerdot;,cfr;,chcy;,check;,checkmark;,chi;,cir;,cirE;,circ;,circeq;,circlearrowleft;,circlearrowright;,circledR;,circledS;,circledast;,circledcirc;,circleddash;,cire;,cirfnint;,cirmid;,cirscir;,clubs;,clubsuit;,colon;,colone;,coloneq;,comma;,commat;,comp;,compfn;,complement;,complexes;,cong;,congdot;,conint;,copf;,coprod;,copy,copy;,copysr;,crarr;,cross;,cscr;,csub;,csube;,csup;,csupe;,ctdot;,cudarrl;,cudarrr;,cuepr;,cuesc;,cularr;,cularrp;,cup;,cupbrcap;,cupcap;,cupcup;,cupdot;,cupor;,cups;,curarr;,curarrm;,curlyeqprec;,curlyeqsucc;,curlyvee;,curlywedge;,curren,curren;,curvearrowleft;,curvearrowright;,cuvee;,cuwed;,cwconint;,cwint;,cylcty;,dArr;,dHar;,dagger;,daleth;,darr;,dash;,dashv;,dbkarow;,dblac;,dcaron;,dcy;,dd;,ddagger;,ddarr;,ddotseq;,deg,deg;,delta;,demptyv;,dfisht;,dfr;,dharl;,dharr;,diam;,diamond;,diamondsuit;,diams;,die;,digamma;,disin;,div;,divide,divide;,divideontimes;,divonx;,djcy;,dlcorn;,dlcrop;,dollar;,dopf;,dot;,doteq;,doteqdot;,dotminus;,dotplus;,dotsquare;,doublebarwedge;,downarrow;,downdownarrows;,downharpoonleft;,downharpoonright;,drbkarow;,drcorn;,drcrop;,dscr;,dscy;,dsol;,dstrok;,dtdot;,dtri;,dtrif;,duarr;,duhar;,dwangle;,dzcy;,dzigrarr;,eDDot;,eDot;,eacute,eacute;,easter;,ecaron;,ecir;,ecirc,ecirc;,ecolon;,ecy;,edot;,ee;,efDot;,efr;,eg;,egrave,egrave;,egs;,egsdot;,el;,elinters;,ell;,els;,elsdot;,emacr;,empty;,emptyset;,emptyv;,emsp13;,emsp14;,emsp;,eng;,ensp;,eogon;,eopf;,epar;,eparsl;,eplus;,epsi;,epsilon;,epsiv;,eqcirc;,eqcolon;,eqsim;,eqslantgtr;,eqslantless;,equals;,equest;,equiv;,equivDD;,eqvparsl;,erDot;,erarr;,escr;,esdot;,esim;,eta;,eth,eth;,euml,euml;,euro;,excl;,exist;,expectation;,exponentiale;,fallingdotseq;,fcy;,female;,ffilig;,fflig;,ffllig;,ffr;,filig;,fjlig;,flat;,fllig;,fltns;,fnof;,fopf;,forall;,fork;,forkv;,fpartint;,frac12,frac12;,frac13;,frac14,frac14;,frac15;,frac16;,frac18;,frac23;,frac25;,frac34,frac34;,frac35;,frac38;,frac45;,frac56;,frac58;,frac78;,frasl;,frown;,fscr;,gE;,gEl;,gacute;,gamma;,gammad;,gap;,gbreve;,gcirc;,gcy;,gdot;,ge;,gel;,geq;,geqq;,geqslant;,ges;,gescc;,gesdot;,gesdoto;,gesdotol;,gesl;,gesles;,gfr;,gg;,ggg;,gimel;,gjcy;,gl;,glE;,gla;,glj;,gnE;,gnap;,gnapprox;,gne;,gneq;,gneqq;,gnsim;,gopf;,grave;,gscr;,gsim;,gsime;,gsiml;,gt,gt;,gtcc;,gtcir;,gtdot;,gtlPar;,gtquest;,gtrapprox;,gtrarr;,gtrdot;,gtreqless;,gtreqqless;,gtrless;,gtrsim;,gvertneqq;,gvnE;,hArr;,hairsp;,half;,hamilt;,hardcy;,harr;,harrcir;,harrw;,hbar;,hcirc;,hearts;,heartsuit;,hellip;,hercon;,hfr;,hksearow;,hkswarow;,hoarr;,homtht;,hookleftarrow;,hookrightarrow;,hopf;,horbar;,hscr;,hslash;,hstrok;,hybull;,hyphen;,iacute,iacute;,ic;,icirc,icirc;,icy;,iecy;,iexcl,iexcl;,iff;,ifr;,igrave,igrave;,ii;,iiiint;,iiint;,iinfin;,iiota;,ijlig;,imacr;,image;,imagline;,imagpart;,imath;,imof;,imped;,in;,incare;,infin;,infintie;,inodot;,int;,intcal;,integers;,intercal;,intlarhk;,intprod;,iocy;,iogon;,iopf;,iota;,iprod;,iquest,iquest;,iscr;,isin;,isinE;,isindot;,isins;,isinsv;,isinv;,it;,itilde;,iukcy;,iuml,iuml;,jcirc;,jcy;,jfr;,jmath;,jopf;,jscr;,jsercy;,jukcy;,kappa;,kappav;,kcedil;,kcy;,kfr;,kgreen;,khcy;,kjcy;,kopf;,kscr;,lAarr;,lArr;,lAtail;,lBarr;,lE;,lEg;,lHar;,lacute;,laemptyv;,lagran;,lambda;,lang;,langd;,langle;,lap;,laquo,laquo;,larr;,larrb;,larrbfs;,larrfs;,larrhk;,larrlp;,larrpl;,larrsim;,larrtl;,lat;,latail;,late;,lates;,lbarr;,lbbrk;,lbrace;,lbrack;,lbrke;,lbrksld;,lbrkslu;,lcaron;,lcedil;,lceil;,lcub;,lcy;,ldca;,ldquo;,ldquor;,ldrdhar;,ldrushar;,ldsh;,le;,leftarrow;,leftarrowtail;,leftharpoondown;,leftharpoonup;,leftleftarrows;,leftrightarrow;,leftrightarrows;,leftrightharpoons;,leftrightsquigarrow;,leftthreetimes;,leg;,leq;,leqq;,leqslant;,les;,lescc;,lesdot;,lesdoto;,lesdotor;,lesg;,lesges;,lessapprox;,lessdot;,lesseqgtr;,lesseqqgtr;,lessgtr;,lesssim;,lfisht;,lfloor;,lfr;,lg;,lgE;,lhard;,lharu;,lharul;,lhblk;,ljcy;,ll;,llarr;,llcorner;,llhard;,lltri;,lmidot;,lmoust;,lmoustache;,lnE;,lnap;,lnapprox;,lne;,lneq;,lneqq;,lnsim;,loang;,loarr;,lobrk;,longleftarrow;,longleftrightarrow;,longmapsto;,longrightarrow;,looparrowleft;,looparrowright;,lopar;,lopf;,loplus;,lotimes;,lowast;,lowbar;,loz;,lozenge;,lozf;,lpar;,lparlt;,lrarr;,lrcorner;,lrhar;,lrhard;,lrm;,lrtri;,lsaquo;,lscr;,lsh;,lsim;,lsime;,lsimg;,lsqb;,lsquo;,lsquor;,lstrok;,lt,lt;,ltcc;,ltcir;,ltdot;,lthree;,ltimes;,ltlarr;,ltquest;,ltrPar;,ltri;,ltrie;,ltrif;,lurdshar;,luruhar;,lvertneqq;,lvnE;,mDDot;,macr,macr;,male;,malt;,maltese;,map;,mapsto;,mapstodown;,mapstoleft;,mapstoup;,marker;,mcomma;,mcy;,mdash;,measuredangle;,mfr;,mho;,micro,micro;,mid;,midast;,midcir;,middot,middot;,minus;,minusb;,minusd;,minusdu;,mlcp;,mldr;,mnplus;,models;,mopf;,mp;,mscr;,mstpos;,mu;,multimap;,mumap;,nGg;,nGt;,nGtv;,nLeftarrow;,nLeftrightarrow;,nLl;,nLt;,nLtv;,nRightarrow;,nVDash;,nVdash;,nabla;,nacute;,nang;,nap;,napE;,napid;,napos;,napprox;,natur;,natural;,naturals;,nbsp,nbsp;,nbump;,nbumpe;,ncap;,ncaron;,ncedil;,ncong;,ncongdot;,ncup;,ncy;,ndash;,ne;,neArr;,nearhk;,nearr;,nearrow;,nedot;,nequiv;,nesear;,nesim;,nexist;,nexists;,nfr;,ngE;,nge;,ngeq;,ngeqq;,ngeqslant;,nges;,ngsim;,ngt;,ngtr;,nhArr;,nharr;,nhpar;,ni;,nis;,nisd;,niv;,njcy;,nlArr;,nlE;,nlarr;,nldr;,nle;,nleftarrow;,nleftrightarrow;,nleq;,nleqq;,nleqslant;,nles;,nless;,nlsim;,nlt;,nltri;,nltrie;,nmid;,nopf;,not,not;,notin;,notinE;,notindot;,notinva;,notinvb;,notinvc;,notni;,notniva;,notnivb;,notnivc;,npar;,nparallel;,nparsl;,npart;,npolint;,npr;,nprcue;,npre;,nprec;,npreceq;,nrArr;,nrarr;,nrarrc;,nrarrw;,nrightarrow;,nrtri;,nrtrie;,nsc;,nsccue;,nsce;,nscr;,nshortmid;,nshortparallel;,nsim;,nsime;,nsimeq;,nsmid;,nspar;,nsqsube;,nsqsupe;,nsub;,nsubE;,nsube;,nsubset;,nsubseteq;,nsubseteqq;,nsucc;,nsucceq;,nsup;,nsupE;,nsupe;,nsupset;,nsupseteq;,nsupseteqq;,ntgl;,ntilde,ntilde;,ntlg;,ntriangleleft;,ntrianglelefteq;,ntriangleright;,ntrianglerighteq;,nu;,num;,numero;,numsp;,nvDash;,nvHarr;,nvap;,nvdash;,nvge;,nvgt;,nvinfin;,nvlArr;,nvle;,nvlt;,nvltrie;,nvrArr;,nvrtrie;,nvsim;,nwArr;,nwarhk;,nwarr;,nwarrow;,nwnear;,oS;,oacute,oacute;,oast;,ocir;,ocirc,ocirc;,ocy;,odash;,odblac;,odiv;,odot;,odsold;,oelig;,ofcir;,ofr;,ogon;,ograve,ograve;,ogt;,ohbar;,ohm;,oint;,olarr;,olcir;,olcross;,oline;,olt;,omacr;,omega;,omicron;,omid;,ominus;,oopf;,opar;,operp;,oplus;,or;,orarr;,ord;,order;,orderof;,ordf,ordf;,ordm,ordm;,origof;,oror;,orslope;,orv;,oscr;,oslash,oslash;,osol;,otilde,otilde;,otimes;,otimesas;,ouml,ouml;,ovbar;,par;,para,para;,parallel;,parsim;,parsl;,part;,pcy;,percnt;,period;,permil;,perp;,pertenk;,pfr;,phi;,phiv;,phmmat;,phone;,pi;,pitchfork;,piv;,planck;,planckh;,plankv;,plus;,plusacir;,plusb;,pluscir;,plusdo;,plusdu;,pluse;,plusmn,plusmn;,plussim;,plustwo;,pm;,pointint;,popf;,pound,pound;,pr;,prE;,prap;,prcue;,pre;,prec;,precapprox;,preccurlyeq;,preceq;,precnapprox;,precneqq;,precnsim;,precsim;,prime;,primes;,prnE;,prnap;,prnsim;,prod;,profalar;,profline;,profsurf;,prop;,propto;,prsim;,prurel;,pscr;,psi;,puncsp;,qfr;,qint;,qopf;,qprime;,qscr;,quaternions;,quatint;,quest;,questeq;,quot,quot;,rAarr;,rArr;,rAtail;,rBarr;,rHar;,race;,racute;,radic;,raemptyv;,rang;,rangd;,range;,rangle;,raquo,raquo;,rarr;,rarrap;,rarrb;,rarrbfs;,rarrc;,rarrfs;,rarrhk;,rarrlp;,rarrpl;,rarrsim;,rarrtl;,rarrw;,ratail;,ratio;,rationals;,rbarr;,rbbrk;,rbrace;,rbrack;,rbrke;,rbrksld;,rbrkslu;,rcaron;,rcedil;,rceil;,rcub;,rcy;,rdca;,rdldhar;,rdquo;,rdquor;,rdsh;,real;,realine;,realpart;,reals;,rect;,reg,reg;,rfisht;,rfloor;,rfr;,rhard;,rharu;,rharul;,rho;,rhov;,rightarrow;,rightarrowtail;,rightharpoondown;,rightharpoonup;,rightleftarrows;,rightleftharpoons;,rightrightarrows;,rightsquigarrow;,rightthreetimes;,ring;,risingdotseq;,rlarr;,rlhar;,rlm;,rmoust;,rmoustache;,rnmid;,roang;,roarr;,robrk;,ropar;,ropf;,roplus;,rotimes;,rpar;,rpargt;,rppolint;,rrarr;,rsaquo;,rscr;,rsh;,rsqb;,rsquo;,rsquor;,rthree;,rtimes;,rtri;,rtrie;,rtrif;,rtriltri;,ruluhar;,rx;,sacute;,sbquo;,sc;,scE;,scap;,scaron;,sccue;,sce;,scedil;,scirc;,scnE;,scnap;,scnsim;,scpolint;,scsim;,scy;,sdot;,sdotb;,sdote;,seArr;,searhk;,searr;,searrow;,sect,sect;,semi;,seswar;,setminus;,setmn;,sext;,sfr;,sfrown;,sharp;,shchcy;,shcy;,shortmid;,shortparallel;,shy,shy;,sigma;,sigmaf;,sigmav;,sim;,simdot;,sime;,simeq;,simg;,simgE;,siml;,simlE;,simne;,simplus;,simrarr;,slarr;,smallsetminus;,smashp;,smeparsl;,smid;,smile;,smt;,smte;,smtes;,softcy;,sol;,solb;,solbar;,sopf;,spades;,spadesuit;,spar;,sqcap;,sqcaps;,sqcup;,sqcups;,sqsub;,sqsube;,sqsubset;,sqsubseteq;,sqsup;,sqsupe;,sqsupset;,sqsupseteq;,squ;,square;,squarf;,squf;,srarr;,sscr;,ssetmn;,ssmile;,sstarf;,star;,starf;,straightepsilon;,straightphi;,strns;,sub;,subE;,subdot;,sube;,subedot;,submult;,subnE;,subne;,subplus;,subrarr;,subset;,subseteq;,subseteqq;,subsetneq;,subsetneqq;,subsim;,subsub;,subsup;,succ;,succapprox;,succcurlyeq;,succeq;,succnapprox;,succneqq;,succnsim;,succsim;,sum;,sung;,sup1,sup1;,sup2,sup2;,sup3,sup3;,sup;,supE;,supdot;,supdsub;,supe;,supedot;,suphsol;,suphsub;,suplarr;,supmult;,supnE;,supne;,supplus;,supset;,supseteq;,supseteqq;,supsetneq;,supsetneqq;,supsim;,supsub;,supsup;,swArr;,swarhk;,swarr;,swarrow;,swnwar;,szlig,szlig;,target;,tau;,tbrk;,tcaron;,tcedil;,tcy;,tdot;,telrec;,tfr;,there4;,therefore;,theta;,thetasym;,thetav;,thickapprox;,thicksim;,thinsp;,thkap;,thksim;,thorn,thorn;,tilde;,times,times;,timesb;,timesbar;,timesd;,tint;,toea;,top;,topbot;,topcir;,topf;,topfork;,tosa;,tprime;,trade;,triangle;,triangledown;,triangleleft;,trianglelefteq;,triangleq;,triangleright;,trianglerighteq;,tridot;,trie;,triminus;,triplus;,trisb;,tritime;,trpezium;,tscr;,tscy;,tshcy;,tstrok;,twixt;,twoheadleftarrow;,twoheadrightarrow;,uArr;,uHar;,uacute,uacute;,uarr;,ubrcy;,ubreve;,ucirc,ucirc;,ucy;,udarr;,udblac;,udhar;,ufisht;,ufr;,ugrave,ugrave;,uharl;,uharr;,uhblk;,ulcorn;,ulcorner;,ulcrop;,ultri;,umacr;,uml,uml;,uogon;,uopf;,uparrow;,updownarrow;,upharpoonleft;,upharpoonright;,uplus;,upsi;,upsih;,upsilon;,upuparrows;,urcorn;,urcorner;,urcrop;,uring;,urtri;,uscr;,utdot;,utilde;,utri;,utrif;,uuarr;,uuml,uuml;,uwangle;,vArr;,vBar;,vBarv;,vDash;,vangrt;,varepsilon;,varkappa;,varnothing;,varphi;,varpi;,varpropto;,varr;,varrho;,varsigma;,varsubsetneq;,varsubsetneqq;,varsupsetneq;,varsupsetneqq;,vartheta;,vartriangleleft;,vartriangleright;,vcy;,vdash;,vee;,veebar;,veeeq;,vellip;,verbar;,vert;,vfr;,vltri;,vnsub;,vnsup;,vopf;,vprop;,vrtri;,vscr;,vsubnE;,vsubne;,vsupnE;,vsupne;,vzigzag;,wcirc;,wedbar;,wedge;,wedgeq;,weierp;,wfr;,wopf;,wp;,wr;,wreath;,wscr;,xcap;,xcirc;,xcup;,xdtri;,xfr;,xhArr;,xharr;,xi;,xlArr;,xlarr;,xmap;,xnis;,xodot;,xopf;,xoplus;,xotime;,xrArr;,xrarr;,xscr;,xsqcup;,xuplus;,xutri;,xvee;,xwedge;,yacute,yacute;,yacy;,ycirc;,ycy;,yen,yen;,yfr;,yicy;,yopf;,yscr;,yucy;,yuml,yuml;,zacute;,zcaron;,zcy;,zdot;,zeetrf;,zeta;,zfr;,zhcy;,zigrarr;,zopf;,zscr;,zwj;,zwnj;`,mo=`1Æ1Æ1&1&1Á1Á1Ă1Â1Â1А2𝔄1À1À1Α1Ā1⩓1Ą2𝔸1⁡1Å1Å2𝒜1≔1Ã1Ã1Ä1Ä1∖1⫧1⌆1Б1∵1ℬ1Β2𝔅2𝔹1˘1ℬ1≎1Ч1©1©1Ć1⋒1ⅅ1ℭ1Č1Ç1Ç1Ĉ1∰1Ċ1¸1·1ℭ1Χ1⊙1⊖1⊕1⊗1∲1”1’1∷1⩴1≡1∯1∮1ℂ1∐1∳1⨯2𝒞1⋓1≍1ⅅ1⤑1Ђ1Ѕ1Џ1‡1↡1⫤1Ď1Д1∇1Δ2𝔇1´1˙1˝1\`1˜1⋄1ⅆ2𝔻1¨1⃜1≐1∯1¨1⇓1⇐1⇔1⫤1⟸1⟺1⟹1⇒1⊨1⇑1⇕1∥1↓1⤓1⇵1̑1⥐1⥞1↽1⥖1⥟1⇁1⥗1⊤1↧1⇓2𝒟1Đ1Ŋ1Ð1Ð1É1É1Ě1Ê1Ê1Э1Ė2𝔈1È1È1∈1Ē1◻1▫1Ę2𝔼1Ε1⩵1≂1⇌1ℰ1⩳1Η1Ë1Ë1∃1ⅇ1Ф2𝔉1◼1▪2𝔽1∀1ℱ1ℱ1Ѓ1>1>1Γ1Ϝ1Ğ1Ģ1Ĝ1Г1Ġ2𝔊1⋙2𝔾1≥1⋛1≧1⪢1≷1⩾1≳2𝒢1≫1Ъ1ˇ1^1Ĥ1ℌ1ℋ1ℍ1─1ℋ1Ħ1≎1≏1Е1IJ1Ё1Í1Í1Î1Î1И1İ1ℑ1Ì1Ì1ℑ1Ī1ⅈ1⇒1∬1∫1⋂1⁣1⁢1Į2𝕀1Ι1ℐ1Ĩ1І1Ï1Ï1Ĵ1Й2𝔍2𝕁2𝒥1Ј1Є1Х1Ќ1Κ1Ķ1К2𝔎2𝕂2𝒦1Љ1<1<1Ĺ1Λ1⟪1ℒ1↞1Ľ1Ļ1Л1⟨1←1⇤1⇆1⌈1⟦1⥡1⇃1⥙1⌊1↔1⥎1⊣1↤1⥚1⊲1⧏1⊴1⥑1⥠1↿1⥘1↼1⥒1⇐1⇔1⋚1≦1≶1⪡1⩽1≲2𝔏1⋘1⇚1Ŀ1⟵1⟷1⟶1⟸1⟺1⟹2𝕃1↙1↘1ℒ1↰1Ł1≪1⤅1М1 1ℳ2𝔐1∓2𝕄1ℳ1Μ1Њ1Ń1Ň1Ņ1Н1​1​1​1​1≫1≪1
3
- 2𝔑1⁠1\xA01ℕ1⫬1≢1≭1∦1∉1≠2≂̸1∄1≯1≱2≧̸2≫̸1≹2⩾̸1≵2≎̸2≏̸1⋪2⧏̸1⋬1≮1≰1≸2≪̸2⩽̸1≴2⪢̸2⪡̸1⊀2⪯̸1⋠1∌1⋫2⧐̸1⋭2⊏̸1⋢2⊐̸1⋣2⊂⃒1⊈1⊁2⪰̸1⋡2≿̸2⊃⃒1⊉1≁1≄1≇1≉1∤2𝒩1Ñ1Ñ1Ν1Œ1Ó1Ó1Ô1Ô1О1Ő2𝔒1Ò1Ò1Ō1Ω1Ο2𝕆1“1‘1⩔2𝒪1Ø1Ø1Õ1Õ1⨷1Ö1Ö1‾1⏞1⎴1⏜1∂1П2𝔓1Φ1Π1±1ℌ1ℙ1⪻1≺1⪯1≼1≾1″1∏1∷1∝2𝒫1Ψ1"1"2𝔔1ℚ2𝒬1⤐1®1®1Ŕ1⟫1↠1⤖1Ř1Ŗ1Р1ℜ1∋1⇋1⥯1ℜ1Ρ1⟩1→1⇥1⇄1⌉1⟧1⥝1⇂1⥕1⌋1⊢1↦1⥛1⊳1⧐1⊵1⥏1⥜1↾1⥔1⇀1⥓1⇒1ℝ1⥰1⇛1ℛ1↱1⧴1Щ1Ш1Ь1Ś1⪼1Š1Ş1Ŝ1С2𝔖1↓1←1→1↑1Σ1∘2𝕊1√1□1⊓1⊏1⊑1⊐1⊒1⊔2𝒮1⋆1⋐1⋐1⊆1≻1⪰1≽1≿1∋1∑1⋑1⊃1⊇1⋑1Þ1Þ1™1Ћ1Ц1 1Τ1Ť1Ţ1Т2𝔗1∴1Θ2  1 1∼1≃1≅1≈2𝕋1⃛2𝒯1Ŧ1Ú1Ú1↟1⥉1Ў1Ŭ1Û1Û1У1Ű2𝔘1Ù1Ù1Ū1_1⏟1⎵1⏝1⋃1⊎1Ų2𝕌1↑1⤒1⇅1↕1⥮1⊥1↥1⇑1⇕1↖1↗1ϒ1Υ1Ů2𝒰1Ũ1Ü1Ü1⊫1⫫1В1⊩1⫦1⋁1‖1‖1∣1|1❘1≀1 2𝔙2𝕍2𝒱1⊪1Ŵ1⋀2𝔚2𝕎2𝒲2𝔛1Ξ2𝕏2𝒳1Я1Ї1Ю1Ý1Ý1Ŷ1Ы2𝔜2𝕐2𝒴1Ÿ1Ж1Ź1Ž1З1Ż1​1Ζ1ℨ1ℤ2𝒵1á1á1ă1∾2∾̳1∿1â1â1´1´1а1æ1æ1⁡2𝔞1à1à1ℵ1ℵ1α1ā1⨿1&1&1∧1⩕1⩜1⩘1⩚1∠1⦤1∠1∡1⦨1⦩1⦪1⦫1⦬1⦭1⦮1⦯1∟1⊾1⦝1∢1Å1⍼1ą2𝕒1≈1⩰1⩯1≊1≋1'1≈1≊1å1å2𝒶1*1≈1≍1ã1ã1ä1ä1∳1⨑1⫭1≌1϶1‵1∽1⋍1⊽1⌅1⌅1⎵1⎶1≌1б1„1∵1∵1⦰1϶1ℬ1β1ℶ1≬2𝔟1⋂1◯1⋃1⨀1⨁1⨂1⨆1★1▽1△1⨄1⋁1⋀1⤍1⧫1▪1▴1▾1◂1▸1␣1▒1░1▓1█2=⃥2≡⃥1⌐2𝕓1⊥1⊥1⋈1╗1╔1╖1╓1═1╦1╩1╤1╧1╝1╚1╜1╙1║1╬1╣1╠1╫1╢1╟1⧉1╕1╒1┐1┌1─1╥1╨1┬1┴1⊟1⊞1⊠1╛1╘1┘1└1│1╪1╡1╞1┼1┤1├1‵1˘1¦1¦2𝒷1⁏1∽1⋍1\\1⧅1⟈1•1•1≎1⪮1≏1≏1ć1∩1⩄1⩉1⩋1⩇1⩀2∩︀1⁁1ˇ1⩍1č1ç1ç1ĉ1⩌1⩐1ċ1¸1¸1⦲1¢1¢1·2𝔠1ч1✓1✓1χ1○1⧃1ˆ1≗1↺1↻1®1Ⓢ1⊛1⊚1⊝1≗1⨐1⫯1⧂1♣1♣1:1≔1≔1,1@1∁1∘1∁1ℂ1≅1⩭1∮2𝕔1∐1©1©1℗1↵1✗2𝒸1⫏1⫑1⫐1⫒1⋯1⤸1⤵1⋞1⋟1↶1⤽1∪1⩈1⩆1⩊1⊍1⩅2∪︀1↷1⤼1⋞1⋟1⋎1⋏1¤1¤1↶1↷1⋎1⋏1∲1∱1⌭1⇓1⥥1†1ℸ1↓1‐1⊣1⤏1˝1ď1д1ⅆ1‡1⇊1⩷1°1°1δ1⦱1⥿2𝔡1⇃1⇂1⋄1⋄1♦1♦1¨1ϝ1⋲1÷1÷1÷1⋇1⋇1ђ1⌞1⌍1$2𝕕1˙1≐1≑1∸1∔1⊡1⌆1↓1⇊1⇃1⇂1⤐1⌟1⌌2𝒹1ѕ1⧶1đ1⋱1▿1▾1⇵1⥯1⦦1џ1⟿1⩷1≑1é1é1⩮1ě1≖1ê1ê1≕1э1ė1ⅇ1≒2𝔢1⪚1è1è1⪖1⪘1⪙1⏧1ℓ1⪕1⪗1ē1∅1∅1∅1 1 1 1ŋ1 1ę2𝕖1⋕1⧣1⩱1ε1ε1ϵ1≖1≕1≂1⪖1⪕1=1≟1≡1⩸1⧥1≓1⥱1ℯ1≐1≂1η1ð1ð1ë1ë1€1!1∃1ℰ1ⅇ1≒1ф1♀1ffi1ff1ffl2𝔣1fi2fj1♭1fl1▱1ƒ2𝕗1∀1⋔1⫙1⨍1½1½1⅓1¼1¼1⅕1⅙1⅛1⅔1⅖1¾1¾1⅗1⅜1⅘1⅚1⅝1⅞1⁄1⌢2𝒻1≧1⪌1ǵ1γ1ϝ1⪆1ğ1ĝ1г1ġ1≥1⋛1≥1≧1⩾1⩾1⪩1⪀1⪂1⪄2⋛︀1⪔2𝔤1≫1⋙1ℷ1ѓ1≷1⪒1⪥1⪤1≩1⪊1⪊1⪈1⪈1≩1⋧2𝕘1\`1ℊ1≳1⪎1⪐1>1>1⪧1⩺1⋗1⦕1⩼1⪆1⥸1⋗1⋛1⪌1≷1≳2≩︀2≩︀1⇔1 1½1ℋ1ъ1↔1⥈1↭1ℏ1ĥ1♥1♥1…1⊹2𝔥1⤥1⤦1⇿1∻1↩1↪2𝕙1―2𝒽1ℏ1ħ1⁃1‐1í1í1⁣1î1î1и1е1¡1¡1⇔2𝔦1ì1ì1ⅈ1⨌1∭1⧜1℩1ij1ī1ℑ1ℐ1ℑ1ı1⊷1Ƶ1∈1℅1∞1⧝1ı1∫1⊺1ℤ1⊺1⨗1⨼1ё1į2𝕚1ι1⨼1¿1¿2𝒾1∈1⋹1⋵1⋴1⋳1∈1⁢1ĩ1і1ï1ï1ĵ1й2𝔧1ȷ2𝕛2𝒿1ј1є1κ1ϰ1ķ1к2𝔨1ĸ1х1ќ2𝕜2𝓀1⇚1⇐1⤛1⤎1≦1⪋1⥢1ĺ1⦴1ℒ1λ1⟨1⦑1⟨1⪅1«1«1←1⇤1⤟1⤝1↩1↫1⤹1⥳1↢1⪫1⤙1⪭2⪭︀1⤌1❲1{1[1⦋1⦏1⦍1ľ1ļ1⌈1{1л1⤶1“1„1⥧1⥋1↲1≤1←1↢1↽1↼1⇇1↔1⇆1⇋1↭1⋋1⋚1≤1≦1⩽1⩽1⪨1⩿1⪁1⪃2⋚︀1⪓1⪅1⋖1⋚1⪋1≶1≲1⥼1⌊2𝔩1≶1⪑1↽1↼1⥪1▄1љ1≪1⇇1⌞1⥫1◺1ŀ1⎰1⎰1≨1⪉1⪉1⪇1⪇1≨1⋦1⟬1⇽1⟦1⟵1⟷1⟼1⟶1↫1↬1⦅2𝕝1⨭1⨴1∗1_1◊1◊1⧫1(1⦓1⇆1⌟1⇋1⥭1‎1⊿1‹2𝓁1↰1≲1⪍1⪏1[1‘1‚1ł1<1<1⪦1⩹1⋖1⋋1⋉1⥶1⩻1⦖1◃1⊴1◂1⥊1⥦2≨︀2≨︀1∺1¯1¯1♂1✠1✠1↦1↦1↧1↤1↥1▮1⨩1м1—1∡2𝔪1℧1µ1µ1∣1*1⫰1·1·1−1⊟1∸1⨪1⫛1…1∓1⊧2𝕞1∓2𝓂1∾1μ1⊸1⊸2⋙̸2≫⃒2≫̸1⇍1⇎2⋘̸2≪⃒2≪̸1⇏1⊯1⊮1∇1ń2∠⃒1≉2⩰̸2≋̸1ʼn1≉1♮1♮1ℕ1\xA01\xA02≎̸2≏̸1⩃1ň1ņ1≇2⩭̸1⩂1н1–1≠1⇗1⤤1↗1↗2≐̸1≢1⤨2≂̸1∄1∄2𝔫2≧̸1≱1≱2≧̸2⩾̸2⩾̸1≵1≯1≯1⇎1↮1⫲1∋1⋼1⋺1∋1њ1⇍2≦̸1↚1‥1≰1↚1↮1≰2≦̸2⩽̸2⩽̸1≮1≴1≮1⋪1⋬1∤2𝕟1¬1¬1∉2⋹̸2⋵̸1∉1⋷1⋶1∌1∌1⋾1⋽1∦1∦2⫽⃥2∂̸1⨔1⊀1⋠2⪯̸1⊀2⪯̸1⇏1↛2⤳̸2↝̸1↛1⋫1⋭1⊁1⋡2⪰̸2𝓃1∤1∦1≁1≄1≄1∤1∦1⋢1⋣1⊄2⫅̸1⊈2⊂⃒1⊈2⫅̸1⊁2⪰̸1⊅2⫆̸1⊉2⊃⃒1⊉2⫆̸1≹1ñ1ñ1≸1⋪1⋬1⋫1⋭1ν1#1№1 1⊭1⤄2≍⃒1⊬2≥⃒2>⃒1⧞1⤂2≤⃒2<⃒2⊴⃒1⤃2⊵⃒2∼⃒1⇖1⤣1↖1↖1⤧1Ⓢ1ó1ó1⊛1⊚1ô1ô1о1⊝1ő1⨸1⊙1⦼1œ1⦿2𝔬1˛1ò1ò1⧁1⦵1Ω1∮1↺1⦾1⦻1‾1⧀1ō1ω1ο1⦶1⊖2𝕠1⦷1⦹1⊕1∨1↻1⩝1ℴ1ℴ1ª1ª1º1º1⊶1⩖1⩗1⩛1ℴ1ø1ø1⊘1õ1õ1⊗1⨶1ö1ö1⌽1∥1¶1¶1∥1⫳1⫽1∂1п1%1.1‰1⊥1‱2𝔭1φ1ϕ1ℳ1☎1π1⋔1ϖ1ℏ1ℎ1ℏ1+1⨣1⊞1⨢1∔1⨥1⩲1±1±1⨦1⨧1±1⨕2𝕡1£1£1≺1⪳1⪷1≼1⪯1≺1⪷1≼1⪯1⪹1⪵1⋨1≾1′1ℙ1⪵1⪹1⋨1∏1⌮1⌒1⌓1∝1∝1≾1⊰2𝓅1ψ1 2𝔮1⨌2𝕢1⁗2𝓆1ℍ1⨖1?1≟1"1"1⇛1⇒1⤜1⤏1⥤2∽̱1ŕ1√1⦳1⟩1⦒1⦥1⟩1»1»1→1⥵1⇥1⤠1⤳1⤞1↪1↬1⥅1⥴1↣1↝1⤚1∶1ℚ1⤍1❳1}1]1⦌1⦎1⦐1ř1ŗ1⌉1}1р1⤷1⥩1”1”1↳1ℜ1ℛ1ℜ1ℝ1▭1®1®1⥽1⌋2𝔯1⇁1⇀1⥬1ρ1ϱ1→1↣1⇁1⇀1⇄1⇌1⇉1↝1⋌1˚1≓1⇄1⇌1‏1⎱1⎱1⫮1⟭1⇾1⟧1⦆2𝕣1⨮1⨵1)1⦔1⨒1⇉1›2𝓇1↱1]1’1’1⋌1⋊1▹1⊵1▸1⧎1⥨1℞1ś1‚1≻1⪴1⪸1š1≽1⪰1ş1ŝ1⪶1⪺1⋩1⨓1≿1с1⋅1⊡1⩦1⇘1⤥1↘1↘1§1§1;1⤩1∖1∖1✶2𝔰1⌢1♯1щ1ш1∣1∥1­1­1σ1ς1ς1∼1⩪1≃1≃1⪞1⪠1⪝1⪟1≆1⨤1⥲1←1∖1⨳1⧤1∣1⌣1⪪1⪬2⪬︀1ь1/1⧄1⌿2𝕤1♠1♠1∥1⊓2⊓︀1⊔2⊔︀1⊏1⊑1⊏1⊑1⊐1⊒1⊐1⊒1□1□1▪1▪1→2𝓈1∖1⌣1⋆1☆1★1ϵ1ϕ1¯1⊂1⫅1⪽1⊆1⫃1⫁1⫋1⊊1⪿1⥹1⊂1⊆1⫅1⊊1⫋1⫇1⫕1⫓1≻1⪸1≽1⪰1⪺1⪶1⋩1≿1∑1♪1¹1¹1²1²1³1³1⊃1⫆1⪾1⫘1⊇1⫄1⟉1⫗1⥻1⫂1⫌1⊋1⫀1⊃1⊇1⫆1⊋1⫌1⫈1⫔1⫖1⇙1⤦1↙1↙1⤪1ß1ß1⌖1τ1⎴1ť1ţ1т1⃛1⌕2𝔱1∴1∴1θ1ϑ1ϑ1≈1∼1 1≈1∼1þ1þ1˜1×1×1⊠1⨱1⨰1∭1⤨1⊤1⌶1⫱2𝕥1⫚1⤩1‴1™1▵1▿1◃1⊴1≜1▹1⊵1◬1≜1⨺1⨹1⧍1⨻1⏢2𝓉1ц1ћ1ŧ1≬1↞1↠1⇑1⥣1ú1ú1↑1ў1ŭ1û1û1у1⇅1ű1⥮1⥾2𝔲1ù1ù1↿1↾1▀1⌜1⌜1⌏1◸1ū1¨1¨1ų2𝕦1↑1↕1↿1↾1⊎1υ1ϒ1υ1⇈1⌝1⌝1⌎1ů1◹2𝓊1⋰1ũ1▵1▴1⇈1ü1ü1⦧1⇕1⫨1⫩1⊨1⦜1ϵ1ϰ1∅1ϕ1ϖ1∝1↕1ϱ1ς2⊊︀2⫋︀2⊋︀2⫌︀1ϑ1⊲1⊳1в1⊢1∨1⊻1≚1⋮1|1|2𝔳1⊲2⊂⃒2⊃⃒2𝕧1∝1⊳2𝓋2⫋︀2⊊︀2⫌︀2⊋︀1⦚1ŵ1⩟1∧1≙1℘2𝔴2𝕨1℘1≀1≀2𝓌1⋂1◯1⋃1▽2𝔵1⟺1⟷1ξ1⟸1⟵1⟼1⋻1⨀2𝕩1⨁1⨂1⟹1⟶2𝓍1⨆1⨄1△1⋁1⋀1ý1ý1я1ŷ1ы1¥1¥2𝔶1ї2𝕪2𝓎1ю1ÿ1ÿ1ź1ž1з1ż1ℨ1ζ2𝔷1ж1⇝2𝕫2𝓏1‍1‌`;let ho=!1,_o=/* @__PURE__ */ new Int32Array,vo=/* @__PURE__ */ new Int32Array,yo=/* @__PURE__ */ new Uint8Array,bo=/* @__PURE__ */ new Int32Array;const xo=/* @__PURE__ */ new Int32Array(128);let So=/* @__PURE__ */ new Int32Array;const Co=[];let wo=0,To=0;function newNode(e){let t=wo++;return _o[t]=-1,vo[t]=-1,yo[t]=e,bo[t]=-1,t}function build(){ho=!0;let e=18872;_o=new Int32Array(e),vo=new Int32Array(e),yo=new Uint8Array(e),bo=new Int32Array(e),xo.fill(-1);let t=0;for(let e=0;e<2231;e++){let e=mo.charCodeAt(t)-48;Co.push(mo.slice(t+1,t+1+e)),t+=1+e}let n=0,r=0,i=18871;for(;n<i;){let e=po.charCodeAt(n),t=xo[e];for(t<0&&(t=newNode(e),xo[e]=t),n++;n<i;){let e=po.charCodeAt(n);if(e===44)break;let r=_o[t],i=-1,a=-1;for(;r>=0;){if(yo[r]===e){i=r;break}a=r,r=vo[r]}i<0&&(i=newNode(e),a<0?_o[t]=i:vo[a]=i),t=i,n++}bo[t]=r++,n++}So=(/* @__PURE__ */ new Int32Array(16384)).fill(-1);for(let e=0;e<128;e++){let t=xo[e];if(!(t<0))for(let n=_o[t];n>=0;n=vo[n])So[e*128+yo[n]]=n}}function matchNamedReference(e,t){ho||build(),To=0;let n=e.length;if(t>=n)return-1;let r=e.charCodeAt(t);if(r>=128)return-1;let i=xo[r];if(i<0)return-1;let a=-1,o=0,s=t+1;if(bo[i]>=0&&(a=bo[i],o=1),s<n){let t=e.charCodeAt(s),n=t<128?So[r*128+t]:-1;if(n<0)return To=o,a;i=n,s++,bo[i]>=0&&(a=bo[i],o=2)}for(;s<n;){let n=e.charCodeAt(s),r=_o[i];for(;r>=0&&yo[r]!==n;)r=vo[r];if(r<0)break;i=r,s++,bo[i]>=0&&(a=bo[i],o=s-t)}return To=o,a}function matchedLength(){return To}function entityValue(e){return Co[e]}const Eo=new Int32Array([8364,129,8218,402,8222,8230,8224,8225,710,8240,352,8249,338,141,381,143,144,8216,8217,8220,8221,8226,8211,8212,732,8482,353,8250,339,157,382,376]);function numericReferenceValue(e){return e===0||e>1114111||e>=55296&&e<=57343?`�`:e>=128&&e<=159?String.fromCharCode(Eo[e-128]):String.fromCodePoint(e)}const Do=/* @__PURE__ */ `.a.abbr.address.applet.area.article.aside.audio.b.base.basefont.bgsound.big.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.data.datalist.dd.del.details.dfn.dialog.dir.div.dl.dt.em.embed.fieldset.figcaption.figure.font.footer.form.frame.frameset.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.iframe.image.img.input.ins.kbd.keygen.label.legend.li.link.listing.main.map.mark.marquee.math.menu.menuitem.meta.meter.nav.nobr.noembed.noframes.noscript.object.ol.optgroup.option.output.p.param.picture.plaintext.pre.progress.q.rb.rp.rt.rtc.ruby.s.samp.script.search.section.select.selectedcontent.slot.small.source.span.strike.strong.style.sub.summary.sup.svg.table.tbody.td.template.textarea.tfoot.th.thead.time.title.tr.track.tt.u.ul.var.video.wbr.xmp.path.g.circle.rect.line.polyline.polygon.ellipse.defs.use.symbol.clippath.lineargradient.radialgradient.stop.mask.pattern.text.tspan.textpath.foreignobject.desc.mi.mo.mn.ms.mtext.mrow.annotation-xml.mglyph.malignmark`.split(`.`),Oo=/* @__PURE__ */ `.id.class.style.type.name.value.href.src.alt.title.role.for.placeholder.disabled.checked.selected.readonly.required.multiple.hidden.tabindex.lang.dir.width.height.action.method.target.rel.content.charset.colspan.rowspan.data-testid.aria-label.aria-labelledby.aria-describedby.aria-hidden.aria-expanded.aria-selected.aria-checked.aria-pressed.aria-disabled.aria-controls.aria-live.aria-current.aria-haspopup.aria-invalid.aria-required.aria-valuenow.aria-valuemin.aria-valuemax.aria-level.aria-modal.aria-owns.aria-busy.aria-orientation.aria-roledescription.autocomplete.autofocus.min.max.step.pattern.maxlength.minlength.size.accept.label.open.draggable.contenteditable.xmlns.viewbox.d.fill.stroke.x.y.cx.cy.r.points.transform.xlink:href.focusable.form.list.datetime.headers.scope.span.start.reversed.download.enctype.novalidate.inputmode.spellcheck.translate.inert.popover.slot.is.part.loading.decoding.srcset.sizes.media.async.defer.nonce.integrity.crossorigin.referrerpolicy.sandbox.allow.poster.controls.autoplay.loop.muted.kind.srclang.default.wrap.rows.cols.high.low.optimum.shape.coords.usemap.ismap.accesskey.enterkeyhint.itemprop.itemscope.itemtype.http-equiv.property.stroke-width.stroke-linecap.stroke-linejoin.fill-rule.clip-rule.xmlns:xlink.version.preserveaspectratio.encoding.definitionurl.color.face.shadowrootmode`.split(`.`),ko=1023,Ao=/* @__PURE__ */ new Int32Array(1024),jo=/* @__PURE__ */ new Int32Array(1024);function hashName(e){let t=0;for(let n=0;n<e.length;n++)t=Math.imul(t,31)+e.charCodeAt(n)|0;return t}function fillTable(e,t){for(let n=1;n<t.length;n++){let r=hashName(t[n])&ko;for(;e[r]!==0;)r=r+1&ko;e[r]=n}}fillTable(Ao,Do),fillTable(jo,Oo);function fixName(e){let t=``;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t+=r>=65&&r<=90?String.fromCharCode(r+32):r===0?`�`:e[n]}return t}function isAsciiAlpha(e){return e>=97&&e<=122||e>=65&&e<=90}function isAsciiAlnum(e){return e>=97&&e<=122||e>=65&&e<=90||e>=48&&e<=57}function isWs$1(e){return e===32||e===10||e===9||e===12}__name(isWs$1,`isWs`);function lower$1(e){return e>=65&&e<=90?e+32:e}__name(lower$1,`lower`);function normalizeNewlines$1(e){let t=e.indexOf(`\r`);if(t<0)return e;let n=``,r=0,i=e.length;for(;t>=0;)n+=e.slice(r,t)+`
4
- `,r=t+1,r<i&&e.charCodeAt(r)===10&&r++,t=e.indexOf(`\r`,r);return n+e.slice(r)}__name(normalizeNewlines$1,`normalizeNewlines`);function ciMatch(e,t,n){if(t+n.length>e.length)return!1;for(let r=0;r<n.length;r++)if(lower$1(e.charCodeAt(t+r))!==n.charCodeAt(r))return!1;return!0}var Tokenizer=class{src;pos;len;state;allowCDATA;processingInstructions;lastStartTag;type;pendingType;text;textHasNull;name;tagId;selfClosing;attrNames;attrValues;attrCount;data;hasName;publicId;hasPublicId;systemId;hasSystemId;forceQuirks;textStart;textBuf;tagStart;nameStart;nameHash;nameFix;isEndTag;valueStart;valueBuf;dropAttr;tempBuf;constructor(){this.src=``,this.pos=0,this.len=0,this.state=0,this.allowCDATA=!1,this.processingInstructions=!1,this.lastStartTag=``,this.type=0,this.pendingType=0,this.text=``,this.textHasNull=!1,this.name=``,this.tagId=0,this.selfClosing=!1,this.attrNames=[],this.attrValues=[],this.attrCount=0,this.data=``,this.hasName=!1,this.publicId=``,this.hasPublicId=!1,this.systemId=``,this.hasSystemId=!1,this.forceQuirks=!1,this.textStart=-1,this.textBuf=``,this.tagStart=0,this.nameStart=0,this.nameHash=0,this.nameFix=!1,this.isEndTag=!1,this.valueStart=-1,this.valueBuf=``,this.dropAttr=!1,this.tempBuf=``}reset(e){this.src=normalizeNewlines$1(e),this.pos=0,this.len=this.src.length,this.state=0,this.allowCDATA=!1,this.lastStartTag=``,this.type=0,this.pendingType=0,this.text=``,this.textHasNull=!1,this.textStart=-1,this.textBuf=``,this.attrCount=0}release(){this.src=``,this.text=``,this.data=``,this.textBuf=``,this.valueBuf=``,this.attrNames.length=0,this.attrValues.length=0,this.attrCount=0}flushRaw(e){let t=this.textStart;t>=0&&(e>t&&(this.textBuf+=this.src.slice(t,e)),this.textStart=-1)}appendText(e,t){this.flushRaw(t),this.textBuf+=e}startRun(e){this.textStart<0&&(this.textStart=e)}emit(e,t){this.flushRaw(t),this.textBuf.length===0?this.type=e:(this.text=this.textBuf,this.textBuf=``,this.type=1,this.pendingType=e)}emitTextNow(e){return this.flushRaw(e),this.textBuf.length!==0&&(this.text=this.textBuf,this.textBuf=``,this.type=1,!0)}finishTagName(e){let t=this.nameStart,n=e-t,r=this.nameHash&ko;if(!this.nameFix){for(;;){let e=Ao[r];if(e===0)break;let i=Do[e];if(i.length===n&&this.src.startsWith(i,t)){this.name=i,this.tagId=e;return}r=r+1&ko}this.name=this.src.slice(t,e),this.tagId=0;return}let i=fixName(this.src.slice(t,e));for(;;){let e=Ao[r];if(e===0)break;if(Do[e]===i){this.name=Do[e],this.tagId=e;return}r=r+1&ko}this.name=i,this.tagId=0}finishAttrName(e){let t=this.nameStart,n=e-t,r=``,i=this.nameHash&ko,a=!1;if(this.nameFix)r=fixName(this.src.slice(t,e));else{for(;;){let e=jo[i];if(e===0)break;let o=Oo[e];if(o.length===n&&this.src.startsWith(o,t)){r=o,a=!0;break}i=i+1&ko}a||(r=this.src.slice(t,e))}let o=this.attrNames,s=this.attrCount;for(let e=0;e<s;e++)if(o[e]===r){this.dropAttr=!0;return}this.dropAttr=!1,s<o.length?(o[s]=r,this.attrValues[s]=``):(o.push(r),this.attrValues.push(``)),this.attrCount=s+1}startValue(){this.valueStart=this.pos,this.valueBuf=``}flushValue(e){this.valueStart>=0&&(e>this.valueStart&&(this.valueBuf+=this.src.slice(this.valueStart,e)),this.valueStart=-1)}finishValue(e){let t=``;this.valueBuf.length===0?t=this.valueStart>=0&&e>this.valueStart?this.src.slice(this.valueStart,e):``:(this.flushValue(e),t=this.valueBuf),this.valueStart=-1,this.valueBuf=``,this.dropAttr||(this.attrValues[this.attrCount-1]=t)}appendValue(e,t){this.flushValue(t),this.valueBuf+=e,this.valueStart=this.pos}newTag(e){this.isEndTag=e,this.selfClosing=!1,this.attrCount=0,this.nameStart=this.pos,this.nameHash=0,this.nameFix=!1}emitTag(){this.isEndTag?this.emit(3,this.tagStart):(this.lastStartTag=this.name,this.emit(2,this.tagStart)),this.state=0}eofInTag(){this.flushRaw(this.tagStart),this.state=0}isAppropriateEndTag(){let e=this.lastStartTag,t=this.nameStart;if(e.length===0||this.pos-t!==e.length)return!1;for(let n=0;n<e.length;n++)if(lower$1(this.src.charCodeAt(t+n))!==e.charCodeAt(n))return!1;return!0}endTagNameStep(){let e=this.pos<this.len?this.src.charCodeAt(this.pos):-1;return isAsciiAlpha(e)?(this.pos++,-2):(isWs$1(e)||e===47||e===62)&&this.isAppropriateEndTag()?(this.name=this.lastStartTag,this.tagId=0,this.isEndTag=!0,this.selfClosing=!1,this.attrCount=0,this.pos++,e===62?(this.finishEndTagId(),this.emitTag(),0):(this.finishEndTagId(),isWs$1(e)?31:39)):-1}finishEndTagId(){let e=this.name,t=hashName(e)&ko;for(;;){let n=Ao[t];if(n===0)break;if(Do[n]===e){this.tagId=n;return}t=t+1&ko}this.tagId=0}charRef(e){let t=this.src,n=this.pos,r=this.len;if(n>=r)return null;let i=t.charCodeAt(n);if(isAsciiAlnum(i)){if(i===108&&t.charCodeAt(n+1)===116&&t.charCodeAt(n+2)===59)return this.pos=n+3,`<`;if(i===103&&t.charCodeAt(n+1)===116&&t.charCodeAt(n+2)===59)return this.pos=n+3,`>`;if(i===97&&t.startsWith(`mp;`,n+1))return this.pos=n+4,`&`;if(i===113&&t.startsWith(`uot;`,n+1))return this.pos=n+5,`"`;if(i===110&&t.startsWith(`bsp;`,n+1))return this.pos=n+5,`\xA0`;let a=matchNamedReference(t,n);if(a<0)return null;let o=n+matchedLength(),s=t.charCodeAt(o-1);if(e&&s!==59&&o<r){let e=t.charCodeAt(o);if(e===61||isAsciiAlnum(e))return null}return this.pos=o,entityValue(a)}if(i!==35)return null;let a=n+1,o=!1;if(a<r){let e=t.charCodeAt(a);(e===120||e===88)&&(o=!0,a++)}let s=0,c=a;for(;a<r;){let e=t.charCodeAt(a),n=-1;if(e>=48&&e<=57?n=e-48:o&&e>=97&&e<=102?n=e-87:o&&e>=65&&e<=70&&(n=e-55),n<0)break;s=s*(o?16:10)+n,s>1114111&&(s=1114112),a++}return a===c?null:(a<r&&t.charCodeAt(a)===59&&a++,this.pos=a,numericReferenceValue(s))}next(){if(this.pendingType!==0)return this.type=this.pendingType,this.pendingType=0,this.textHasNull=!1,this.type;if(this.type===6)return 6;for(this.textHasNull=!1,this.type=0;this.type===0;)this.step();return this.type}step(){let e=this.src,t=this.len;switch(this.state){case 0:{let n=this.pos;for(;;){if(n>=t){this.pos=n,this.emit(6,t);return}let r=e.charCodeAt(n);if(r===60){this.textStart<0&&(this.textStart=n),this.tagStart=n,this.pos=n+1,this.state=5;return}if(r===38){this.pos=n+1;let e=this.charRef(!1);e===null?(this.textStart<0&&(this.textStart=n),n++):(this.appendText(e,n),n=this.pos)}else for(this.textStart<0&&(this.textStart=n),r===0&&(this.textHasNull=!0),n++;n<t;){let t=e.charCodeAt(n);if(t===60||t===38||t===0)break;n++}}}case 1:{let n=this.pos;for(;;){if(n>=t){this.pos=n,this.emit(6,t);return}let r=e.charCodeAt(n);if(r===60){this.textStart<0&&(this.textStart=n),this.tagStart=n,this.pos=n+1,this.state=8;return}if(r===38){this.pos=n+1;let e=this.charRef(!1);e===null?(this.textStart<0&&(this.textStart=n),n++):(this.appendText(e,n),n=this.pos)}else r===0?(this.appendText(`�`,n),n++):(this.textStart<0&&(this.textStart=n),n++)}}case 2:case 3:case 4:{let n=this.state,r=this.pos;for(;;){if(r>=t){this.pos=r,this.emit(6,t);return}let i=e.charCodeAt(r);if(i===60&&n!==4){this.textStart<0&&(this.textStart=r),this.tagStart=r,this.pos=r+1,this.state=n===2?11:14;return}i===0?(this.appendText(`�`,r),r++):(this.textStart<0&&(this.textStart=r),r++)}}case 5:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===33?(this.pos++,this.state=41):n===47?(this.pos++,this.state=6):isAsciiAlpha(n)?(this.newTag(!1),this.state=7):n===63?this.processingInstructions?(this.tempBuf=``,this.pos++,this.state=69):(this.data=``,this.state=40):this.state=0;return}case 6:{let n=this.pos<t?e.charCodeAt(this.pos):-1;isAsciiAlpha(n)?(this.newTag(!0),this.state=7):n===62?(this.flushRaw(this.tagStart),this.pos++,this.state=0):n===-1?this.state=0:(this.data=``,this.state=40);return}case 7:{let n=this.pos,r=this.nameHash;for(;;){if(n>=t){this.pos=n,this.eofInTag();return}let i=e.charCodeAt(n);if(i===62||i===47||isWs$1(i)){this.nameHash=r,this.finishTagName(n),this.pos=n+1,i===62?this.emitTag():this.state=i===47?39:31;return}i>=65&&i<=90||i===0?(this.nameFix=!0,r=Math.imul(r,31)+(i===0?65533:i+32)|0):r=Math.imul(r,31)+i|0,n++}}case 8:case 11:(this.pos<t?e.charCodeAt(this.pos):-1)===47?(this.pos++,this.state=this.state===8?9:12):this.state=this.state===8?1:2;return;case 9:case 12:case 15:case 23:{let n=this.pos<t?e.charCodeAt(this.pos):-1,r=this.state;isAsciiAlpha(n)?(this.nameStart=this.pos,this.state=r===9?10:r===12?13:r===15?16:24):this.state=r===9?1:r===12?2:r===15?3:19;return}case 10:case 13:case 16:case 24:{let e=this.state;for(;;){let t=this.endTagNameStep();if(t!==-2){t===-1?this.state=e===10?1:e===13?2:e===16?3:19:t!==0&&(this.state=t);return}}}case 14:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===47?(this.pos++,this.state=15):n===33?(this.pos++,this.state=17):this.state=3;return}case 17:case 18:(this.pos<t?e.charCodeAt(this.pos):-1)===45?(this.startRun(this.pos),this.pos++,this.state=this.state===17?18:21):this.state=3;return;case 19:case 20:case 21:case 26:case 27:case 28:{let n=this.state,r=n>=26,i=r?26:19,a=this.pos;if(a>=t){this.emit(6,t);return}let o=e.charCodeAt(a);o===45?(this.startRun(a),this.pos++,this.state=n===i?i+1:i+2):o===60?(this.startRun(a),this.tagStart=a,this.pos++,this.state=r?29:22):o===62&&n===i+2?(this.startRun(a),this.pos++,this.state=3):o===0?(this.appendText(`�`,a),this.pos++,this.state=i):(this.startRun(a),this.pos++,this.state=i);return}case 22:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===47?(this.pos++,this.state=23):isAsciiAlpha(n)?(this.tempBuf=``,this.state=25):this.state=19;return}case 25:case 30:{let n=this.state===25,r=this.pos<t?e.charCodeAt(this.pos):-1;if(isWs$1(r)||r===47||r===62){this.startRun(this.pos),this.pos++;let e=this.tempBuf===`script`;this.state=n?e?26:19:e?19:26}else isAsciiAlpha(r)?(this.startRun(this.pos),this.tempBuf+=String.fromCharCode(lower$1(r)),this.pos++):this.state=n?19:26;return}case 29:(this.pos<t?e.charCodeAt(this.pos):-1)===47?(this.startRun(this.pos),this.pos++,this.tempBuf=``,this.state=30):this.state=26;return;case 31:{let n=this.pos;for(;n<t&&isWs$1(e.charCodeAt(n));)n++;this.pos=n;let r=n<t?e.charCodeAt(n):-1;if(r===47||r===62||r===-1){this.state=33;return}this.nameStart=n,this.nameHash=0+r|0,this.nameFix=r===0||r>=65&&r<=90,this.nameFix&&(this.nameHash=r===0?65533:r+32),this.pos=n+1,this.state=32;return}case 32:{let n=this.pos,r=this.nameHash;for(;;){let i=n<t?e.charCodeAt(n):-1;if(i===-1||isWs$1(i)||i===47||i===62){this.nameHash=r,this.finishAttrName(n),this.pos=n,this.state=33;return}if(i===61){this.nameHash=r,this.finishAttrName(n),this.pos=n+1,this.state=34;return}i>=65&&i<=90||i===0?(this.nameFix=!0,r=Math.imul(r,31)+(i===0?65533:i+32)|0):r=Math.imul(r,31)+i|0,n++}}case 33:{let n=this.pos;for(;n<t&&isWs$1(e.charCodeAt(n));)n++;if(this.pos=n,n>=t){this.eofInTag();return}let r=e.charCodeAt(n);r===47?(this.pos++,this.state=39):r===61?(this.pos++,this.state=34):r===62?(this.pos++,this.emitTag()):this.state=31;return}case 34:{let n=this.pos;for(;n<t&&isWs$1(e.charCodeAt(n));)n++;this.pos=n;let r=n<t?e.charCodeAt(n):-1;r===34?(this.pos++,this.startValue(),this.state=35):r===39?(this.pos++,this.startValue(),this.state=36):r===62?(this.pos++,this.emitTag()):(this.startValue(),this.state=37);return}case 35:case 36:{let n=this.state===35?34:39,r=this.pos;for(;;){if(r>=t){this.pos=r,this.eofInTag();return}let i=e.charCodeAt(r);if(i===n){this.finishValue(r),this.pos=r+1,this.state=38;return}if(i===38){this.pos=r+1;let e=this.charRef(!0);e===null?r++:(this.appendValue(e,r),r=this.pos)}else i===0&&(this.pos=r+1,this.appendValue(`�`,r)),r++}}case 37:{let n=this.pos;for(;;){if(n>=t){this.pos=n,this.eofInTag();return}let r=e.charCodeAt(n);if(isWs$1(r)){this.finishValue(n),this.pos=n+1,this.state=31;return}if(r===62){this.finishValue(n),this.pos=n+1,this.emitTag();return}if(r===38){this.pos=n+1;let e=this.charRef(!0);e===null?n++:(this.appendValue(e,n),n=this.pos)}else r===0&&(this.pos=n+1,this.appendValue(`�`,n)),n++}}case 38:{let n=this.pos<t?e.charCodeAt(this.pos):-1;isWs$1(n)?(this.pos++,this.state=31):n===47?(this.pos++,this.state=39):n===62?(this.pos++,this.emitTag()):n===-1?this.eofInTag():this.state=31;return}case 39:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===62?(this.pos++,this.selfClosing=!0,this.emitTag()):n===-1?this.eofInTag():this.state=31;return}case 40:{let n=this.pos,r=e.indexOf(`>`,n);r<0&&(r=t);let i=e.slice(n,r);i.indexOf(`\0`)>=0&&(i=i.replaceAll(`\0`,`�`)),this.data+=i,this.pos=r<t?r+1:t,this.emit(4,this.tagStart),this.state=0;return}case 41:{if(this.emitTextNow(this.tagStart))return;let n=this.pos;n+1<t&&e.charCodeAt(n)===45&&e.charCodeAt(n+1)===45?(this.pos=n+2,this.data=``,this.state=42):ciMatch(e,n,`doctype`)?(this.pos=n+7,this.state=52):e.startsWith(`[CDATA[`,n)?(this.pos=n+7,this.allowCDATA?this.state=68:(this.data=`[CDATA[`,this.state=40)):(this.data=``,this.state=40);return}case 42:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===45?(this.pos++,this.state=43):n===62?(this.pos++,this.emitComment()):this.state=44;return}case 43:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===45?(this.pos++,this.state=50):n===62?(this.pos++,this.emitComment()):n===-1?this.emitComment():(this.data+=`-`,this.state=44);return}case 44:{let n=this.pos,r=n;for(;n<t;){let t=e.charCodeAt(n);if(t===60||t===45||t===0)break;n++}if(n>r&&(this.data+=e.slice(r,n)),this.pos=n,n>=t){this.emitComment();return}let i=e.charCodeAt(n);this.pos++,i===60?(this.data+=`<`,this.state=45):i===45?this.state=49:this.data+=`�`;return}case 45:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===33?(this.pos++,this.data+=`!`,this.state=46):n===60?(this.pos++,this.data+=`<`):this.state=44;return}case 46:(this.pos<t?e.charCodeAt(this.pos):-1)===45?(this.pos++,this.state=47):this.state=44;return;case 47:(this.pos<t?e.charCodeAt(this.pos):-1)===45?(this.pos++,this.state=48):this.state=49;return;case 48:this.state=50;return;case 49:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===45?(this.pos++,this.state=50):n===-1?this.emitComment():(this.data+=`-`,this.state=44);return}case 50:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===62?(this.pos++,this.emitComment()):n===33?(this.pos++,this.state=51):n===45?(this.pos++,this.data+=`-`):n===-1?this.emitComment():(this.data+=`--`,this.state=44);return}case 51:{let n=this.pos<t?e.charCodeAt(this.pos):-1;n===45?(this.pos++,this.data+=`--!`,this.state=49):n===62?(this.pos++,this.emitComment()):n===-1?this.emitComment():(this.data+=`--!`,this.state=44);return}case 52:{this.name=``,this.hasName=!1,this.publicId=``,this.hasPublicId=!1,this.systemId=``,this.hasSystemId=!1,this.forceQuirks=!1;let n=this.pos<t?e.charCodeAt(this.pos):-1;isWs$1(n)?(this.pos++,this.state=53):n===-1?(this.forceQuirks=!0,this.emitDoctype()):this.state=53;return}case 53:{let n=this.pos;for(;n<t&&isWs$1(e.charCodeAt(n));)n++;this.pos=n;let r=n<t?e.charCodeAt(n):-1;r===-1?(this.forceQuirks=!0,this.emitDoctype()):r===62?(this.pos++,this.forceQuirks=!0,this.emitDoctype()):(this.hasName=!0,this.name=``,this.state=54);return}case 54:{let n=this.pos;for(;;){if(n>=t){this.pos=n,this.forceQuirks=!0,this.emitDoctype();return}let r=e.charCodeAt(n);if(isWs$1(r)){this.pos=n+1,this.state=55;return}if(r===62){this.pos=n+1,this.emitDoctype();return}r>=65&&r<=90?this.name+=String.fromCharCode(r+32):r===0?this.name+=`�`:this.name+=e[n],n++}}case 55:{let n=this.pos;for(;n<t&&isWs$1(e.charCodeAt(n));)n++;this.pos=n;let r=n<t?e.charCodeAt(n):-1;r===-1?(this.forceQuirks=!0,this.emitDoctype()):r===62?(this.pos++,this.emitDoctype()):ciMatch(e,n,`public`)?(this.pos+=6,this.state=56):ciMatch(e,n,`system`)?(this.pos+=6,this.state=62):(this.forceQuirks=!0,this.state=67);return}case 56:case 62:{let n=this.state===56,r=this.pos<t?e.charCodeAt(this.pos):-1;isWs$1(r)?(this.pos++,this.state=n?57:63):r===34||r===39?(this.pos++,this.startDoctypeId(n,r)):r===62?(this.pos++,this.forceQuirks=!0,this.emitDoctype()):r===-1?(this.forceQuirks=!0,this.emitDoctype()):(this.forceQuirks=!0,this.state=67);return}case 57:case 63:{let n=this.state===57,r=this.pos;for(;r<t&&isWs$1(e.charCodeAt(r));)r++;this.pos=r;let i=r<t?e.charCodeAt(r):-1;i===34||i===39?(this.pos++,this.startDoctypeId(n,i)):i===62?(this.pos++,this.forceQuirks=!0,this.emitDoctype()):i===-1?(this.forceQuirks=!0,this.emitDoctype()):(this.forceQuirks=!0,this.state=67);return}case 58:case 59:case 64:case 65:{let n=this.state,r=n===58||n===59,i=n===58||n===64?34:39,a=this.pos,o=``;for(;;){if(a>=t){this.pos=a,this.appendDoctypeId(r,o),this.forceQuirks=!0,this.emitDoctype();return}let n=e.charCodeAt(a);if(n===i){this.pos=a+1,this.appendDoctypeId(r,o),this.state=r?60:66;return}if(n===62){this.pos=a+1,this.appendDoctypeId(r,o),this.forceQuirks=!0,this.emitDoctype();return}o+=n===0?`�`:e[a],a++}}case 60:case 61:{let n=this.state===61,r=this.pos;if(n){for(;r<t&&isWs$1(e.charCodeAt(r));)r++;this.pos=r}let i=r<t?e.charCodeAt(r):-1;!n&&isWs$1(i)?(this.pos++,this.state=61):i===62?(this.pos++,this.emitDoctype()):i===34||i===39?(this.pos++,this.startDoctypeId(!1,i)):i===-1?(this.forceQuirks=!0,this.emitDoctype()):(this.forceQuirks=!0,this.state=67);return}case 66:{let n=this.pos;for(;n<t&&isWs$1(e.charCodeAt(n));)n++;this.pos=n;let r=n<t?e.charCodeAt(n):-1;r===62?(this.pos++,this.emitDoctype()):r===-1?(this.forceQuirks=!0,this.emitDoctype()):this.state=67;return}case 67:{let n=e.indexOf(`>`,this.pos);this.pos=n<0?t:n+1,this.emitDoctype();return}case 68:{let n=this.pos,r=e.indexOf(`]]>`,n);if(r<0&&(r=t),r>n&&(this.startRun(n),e.indexOf(`\0`,n)>=0&&e.indexOf(`\0`,n)<r&&(this.textHasNull=!0),this.flushRaw(r)),r>=t){this.pos=t,this.emit(6,t);return}this.pos=r+3,this.state=0;return}case 69:{let n=this.pos<t?e.charCodeAt(this.pos):-1;isAsciiAlpha(n)||n===95?this.state=70:n===-1?(this.flushRaw(this.tagStart),this.state=0):(this.data=`?`+this.tempBuf,this.state=40);return}case 70:{let n=this.pos<t?e.charCodeAt(this.pos):-1;if(isWs$1(n)||n===63||n===62){let e=this.tempBuf,t=fixName(e);t===`xml`||t===`xml-stylesheet`?(this.data=`?`+e,this.state=40):(this.name=e,this.data=``,this.state=71)}else isAsciiAlnum(n)||n===45||n===95?(this.tempBuf+=e[this.pos],this.pos++):n===-1?(this.flushRaw(this.tagStart),this.state=0):(this.data=`?`+this.tempBuf,this.state=40);return}case 71:{let n=this.pos;for(;n<t&&isWs$1(e.charCodeAt(n));)n++;this.pos=n,this.state=72;return}case 72:case 73:{let n=this.pos<t?e.charCodeAt(this.pos):-1;if(n===-1){this.flushRaw(this.tagStart),this.state=0;return}if(this.state===73){if(n===62){this.pos++,this.emit(7,this.tagStart),this.state=0;return}this.data+=`?`,this.state=72;return}this.pos++,n===63?this.state=73:n===62?(this.emit(7,this.tagStart),this.state=0):this.data+=e[this.pos-1];return}default:throw Error(`unknown tokenizer state `+String(this.state))}}emitComment(){this.emit(4,this.tagStart),this.state=0}emitDoctype(){this.emit(5,this.tagStart),this.state=0}startDoctypeId(e,t){e?(this.publicId=``,this.hasPublicId=!0,this.state=t===34?58:59):(this.systemId=``,this.hasSystemId=!0,this.state=t===34?64:65)}appendDoctypeId(e,t){e?this.publicId+=t:this.systemId+=t}};const Mo=1024,No=/* @__PURE__ */ new Int32Array(178);function mark(e,t){for(let n=0;n<t.length;n++)No[t[n]]|=e}mark(1,[4,19,56,119,121,125,73,84,106,122,169,170,171,172,173,174,175,176,177]),mark(2,[85,133]),mark(4,[17]),mark(8,[56,119,122]),mark(16,[3,4,5,6,7,10,11,12,14,15,16,17,19,20,23,24,27,29,32,33,34,35,37,38,39,40,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,58,60,61,64,67,68,69,70,73,75,77,79,81,82,83,84,85,89,90,92,93,103,104,105,106,110,114,116,119,120,121,122,123,124,125,126,128,129,130,133,136,137,169,170,171,172,173,174,175,176,177]),mark(32,[27,35,67,86,87,89,96,97,98,99]),mark(64,[19,24,27,35,67,86,87,89,96,97,98,99,120,121,124,125,126,129]),mark(128,[1,9,13,22,36,41,57,80,101,109,112,113,131,132]),mark(256,[9,13,14,15,16,20,22,27,33,34,35,36,37,46,47,48,49,50,51,52,55,57,60,67,69,75,77,80,85,89,93,100,101,109,111,113,112,115,117,119,131,132,133,134]),mark(512,[17,38,61,84,88,106,123,60]),mark(Mo,[17,38,61,84,88,106,123]);const Po=/* @__PURE__ */ new Map;for(let e=1;e<Do.length;e++)Po.set(Do[e],e);function parserTagId(e){let t=Po.get(e);return t===void 0?0:t}const Fo=/* @__PURE__ */ `attributeName.attributeType.baseFrequency.baseProfile.calcMode.clipPathUnits.diffuseConstant.edgeMode.filterUnits.glyphRef.gradientTransform.gradientUnits.kernelMatrix.kernelUnitLength.keyPoints.keySplines.keyTimes.lengthAdjust.limitingConeAngle.markerHeight.markerUnits.markerWidth.maskContentUnits.maskUnits.numOctaves.pathLength.patternContentUnits.patternTransform.patternUnits.pointsAtX.pointsAtY.pointsAtZ.preserveAlpha.preserveAspectRatio.primitiveUnits.refX.refY.repeatCount.repeatDur.requiredExtensions.requiredFeatures.specularConstant.specularExponent.spreadMethod.startOffset.stdDeviation.stitchTiles.surfaceScale.systemLanguage.tableValues.targetX.targetY.textLength.viewBox.viewTarget.xChannelSelector.yChannelSelector.zoomAndPan`.split(`.`),Io=/* @__PURE__ */ `altGlyph.altGlyphDef.altGlyphItem.animateColor.animateMotion.animateTransform.clipPath.feBlend.feColorMatrix.feComponentTransfer.feComposite.feConvolveMatrix.feDiffuseLighting.feDisplacementMap.feDistantLight.feDropShadow.feFlood.feFuncA.feFuncB.feFuncG.feFuncR.feGaussianBlur.feImage.feMerge.feMergeNode.feMorphology.feOffset.fePointLight.feSpecularLighting.feSpotLight.feTile.feTurbulence.foreignObject.glyphRef.linearGradient.radialGradient.textPath`.split(`.`),Lo=/* @__PURE__ */ new Map;for(let e=0;e<Fo.length;e++)Lo.set(Fo[e].toLowerCase(),Fo[e]);const Ro=/* @__PURE__ */ new Map;for(let e=0;e<Io.length;e++)Ro.set(Io[e].toLowerCase(),Io[e]);const zo=/* @__PURE__ */ `+//silmaril//dtd html pro v0r11 19970101//,-//as//dtd html 3.0 aswedit + extensions//,-//advasoft ltd//dtd html 3.0 aswedit + extensions//,-//ietf//dtd html 2.0 level 1//,-//ietf//dtd html 2.0 level 2//,-//ietf//dtd html 2.0 strict level 1//,-//ietf//dtd html 2.0 strict level 2//,-//ietf//dtd html 2.0 strict//,-//ietf//dtd html 2.0//,-//ietf//dtd html 2.1e//,-//ietf//dtd html 3.0//,-//ietf//dtd html 3.2 final//,-//ietf//dtd html 3.2//,-//ietf//dtd html 3//,-//ietf//dtd html level 0//,-//ietf//dtd html level 1//,-//ietf//dtd html level 2//,-//ietf//dtd html level 3//,-//ietf//dtd html strict level 0//,-//ietf//dtd html strict level 1//,-//ietf//dtd html strict level 2//,-//ietf//dtd html strict level 3//,-//ietf//dtd html strict//,-//ietf//dtd html//,-//metrius//dtd metrius presentational//,-//microsoft//dtd internet explorer 2.0 html strict//,-//microsoft//dtd internet explorer 2.0 html//,-//microsoft//dtd internet explorer 2.0 tables//,-//microsoft//dtd internet explorer 3.0 html strict//,-//microsoft//dtd internet explorer 3.0 html//,-//microsoft//dtd internet explorer 3.0 tables//,-//netscape comm. corp.//dtd html//,-//netscape comm. corp.//dtd strict html//,-//o'reilly and associates//dtd html 2.0//,-//o'reilly and associates//dtd html extended 1.0//,-//o'reilly and associates//dtd html extended relaxed 1.0//,-//sq//dtd html 2.0 hotmetal + extensions//,-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//,-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//,-//spyglass//dtd html 2.0 extended//,-//sun microsystems corp.//dtd hotjava html//,-//sun microsystems corp.//dtd hotjava strict html//,-//w3c//dtd html 3 1995-03-24//,-//w3c//dtd html 3.2 draft//,-//w3c//dtd html 3.2 final//,-//w3c//dtd html 3.2//,-//w3c//dtd html 3.2s draft//,-//w3c//dtd html 4.0 frameset//,-//w3c//dtd html 4.0 transitional//,-//w3c//dtd html experimental 19960712//,-//w3c//dtd html experimental 970421//,-//w3c//dtd w3 html//,-//w3o//dtd w3 html 3.0//,-//webtechs//dtd mozilla html 2.0//,-//webtechs//dtd mozilla html//`.split(`,`);function asciiLower(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n>=65&&n<=90){let n=e.slice(0,t);for(let r=t;r<e.length;r++){let t=e.charCodeAt(r);n+=t>=65&&t<=90?String.fromCharCode(t+32):e[r]}return n}}return e}function isWsCode(e){return e===32||e===10||e===9||e===12||e===13}function isAllWs(e){for(let t=0;t<e.length;t++)if(!isWsCode(e.charCodeAt(t)))return!1;return!0}function hasNonWsNonNull(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(!isWsCode(n)&&n!==0)return!0}return!1}function removeNulls(e){return e.indexOf(`\0`)<0?e:e.replaceAll(`\0`,``)}var TreeSink=class{createElement(e,t,n,r,i,a,o,s,c){return-1}insert(e,t,n){}insertText(e,t,n){}insertComment(e,t,n){}insertProcessingInstruction(e,t,n,r){}insertDoctype(e,t,n,r){}remove(e){}hasParent(e){return!1}reparentChildren(e,t){}addMissingAttributes(e,t,n,r){}templateContents(e){return e}attachDeclarativeShadowRoot(e,t,n,r,i,a){return-1}associateForm(e,t){}setDocumentMode(e){}},ParseOptions=class{scripting;allowDeclarativeShadowRoots;processingInstructions;iframeSrcdoc;constructor(){this.scripting=!1,this.allowDeclarativeShadowRoots=!1,this.processingInstructions=!1,this.iframeSrcdoc=!1}},TreeBuilder=class{sink;tok;hNs;hTag;hName;hIP;hContents;stack;afe;afeTok;ptName;ptId;ptAttrStart;ptAttrCount;poolNames;poolValues;templateModes;mode;originalMode;docHandle;headElement;formElement;fragmentContext;framesetOk;fosterParenting;documentMode;scripting;allowDSD;iframeSrcdoc;stopped;skipNewline;reprocess;ttype;chars;cpos;charsHasNull;pendingTableText;pendingTableNonWs;locParent;locRef;fNames;fValues;fNs;emptyStrings;emptyNumbers;constructor(e){this.sink=e,this.tok=new Tokenizer,this.hNs=[],this.hTag=[],this.hName=[],this.hIP=[],this.hContents=[],this.stack=[],this.afe=[],this.afeTok=[],this.ptName=[],this.ptId=[],this.ptAttrStart=[],this.ptAttrCount=[],this.poolNames=[],this.poolValues=[],this.templateModes=[],this.mode=0,this.originalMode=0,this.docHandle=-1,this.headElement=-1,this.formElement=-1,this.fragmentContext=-1,this.framesetOk=!0,this.fosterParenting=!1,this.documentMode=0,this.scripting=!1,this.allowDSD=!1,this.iframeSrcdoc=!1,this.stopped=!1,this.skipNewline=!1,this.reprocess=!1,this.ttype=0,this.chars=``,this.cpos=0,this.charsHasNull=!1,this.pendingTableText=``,this.pendingTableNonWs=!1,this.locParent=-1,this.locRef=-1,this.fNames=[],this.fValues=[],this.fNs=[],this.emptyStrings=[],this.emptyNumbers=[]}resetState(e){this.hNs.length=0,this.hTag.length=0,this.hName.length=0,this.hIP.length=0,this.hContents.length=0,this.stack.length=0,this.afe.length=0,this.afeTok.length=0,this.ptName.length=0,this.ptId.length=0,this.ptAttrStart.length=0,this.ptAttrCount.length=0,this.poolNames.length=0,this.poolValues.length=0,this.templateModes.length=0,this.mode=0,this.originalMode=0,this.docHandle=-1,this.headElement=-1,this.formElement=-1,this.fragmentContext=-1,this.framesetOk=!0,this.fosterParenting=!1,this.documentMode=0,this.scripting=e.scripting,this.allowDSD=e.allowDeclarativeShadowRoots,this.iframeSrcdoc=e.iframeSrcdoc,this.stopped=!1,this.skipNewline=!1,this.pendingTableText=``,this.pendingTableNonWs=!1,this.tok.processingInstructions=e.processingInstructions}setMeta(e,t,n,r,i){for(;this.hNs.length<=e;)this.hNs.push(0),this.hTag.push(0),this.hName.push(``),this.hIP.push(!1),this.hContents.push(-1);this.hNs[e]=t,this.hTag[e]=n,this.hName[e]=r,this.hIP[e]=i,this.hContents[e]=-1}parseDocument(e,t,n){this.resetState(n),this.docHandle=t,this.setMeta(t,0,0,`#document`,!1),this.tok.reset(e),this.run()}parseFragment(e,t,n,r,i,a,o,s,c){if(this.resetState(c),this.documentMode=s,this.setMeta(t,0,56,`html`,!1),this.setContextMeta(n,r,i,a),this.fragmentContext=n,this.tok.reset(e),i===0){let e=this.hTag[n];e===128||e===123?this.tok.state=1:e===114||e===137||e===58||e===81||e===82?this.tok.state=2:e===103?this.tok.state=3:e===83?this.scripting&&(this.tok.state=2):e===92&&(this.tok.state=4)}this.stack.push(t),i===0&&this.hTag[n]===122&&this.templateModes.push(15),this.resetInsertionMode(),this.formElement=o,this.tok.allowCDATA=this.hNs[this.adjustedCurrentNode()]!==0,this.run()}setContextMeta(e,t,n,r){n===0?this.setMeta(e,n,parserTagId(t),t,!1):(this.setMeta(e,n,0,t,!1),this.setForeignFacts(e,n,t,r))}setForeignFacts(e,t,n,r){let i=0,a=!1;if(t===2){if(n===`mi`)i=169;else if(n===`mo`)i=170;else if(n===`mn`)i=171;else if(n===`ms`)i=172;else if(n===`mtext`)i=173;else if(n===`annotation-xml`){i=174;let e=asciiLower(r);a=e===`text/html`||e===`application/xhtml+xml`}}else t===1&&(n===`foreignObject`?i=175:n===`desc`?i=176:n===`title`&&(i=177),a=i!==0);this.hTag[e]=i,this.hIP[e]=a}run(){let e=this.tok;for(;!this.stopped;){let t=e.next();if(this.ttype=t,t===1){if(this.chars=e.text,this.cpos=0,this.charsHasNull=e.textHasNull,this.skipNewline&&(this.skipNewline=!1,this.chars.charCodeAt(0)===10)){if(this.chars.length===1)continue;this.cpos=1}}else this.skipNewline=!1;if(this.processToken(),t===6)break;e.allowCDATA=this.stack.length!==0&&this.hNs[this.adjustedCurrentNode()]!==0}this.stack.length=0,e.release(),this.chars=``,this.pendingTableText=``}processToken(){do this.reprocess=!1,this.useHtmlRules()?this.dispatchMode(this.mode):this.foreignContent();while(this.reprocess&&!this.stopped)}useHtmlRules(){if(this.stack.length===0)return!0;let e=this.adjustedCurrentNode();if(this.hNs[e]===0)return!0;let t=this.ttype;if(t===6)return!0;let n=this.hTag[e];return!!(n>=169&&n<=173&&(t===1||t===2&&this.tok.tagId!==167&&this.tok.tagId!==168)||n===174&&t===2&&this.tok.tagId===118||this.hIP[e]&&(t===2||t===1))}dispatchMode(e){switch(e){case 0:return this.initial();case 1:return this.beforeHtml();case 2:return this.beforeHead();case 3:return this.inHead();case 4:return this.inHeadNoscript();case 5:return this.afterHead();case 6:return this.inBody();case 7:return this.text();case 8:return this.inTable();case 9:return this.inTableText();case 10:return this.inCaption();case 11:return this.inColumnGroup();case 12:return this.inTableBody();case 13:return this.inRow();case 14:return this.inCell();case 15:return this.inTemplate();case 16:return this.afterBody();case 17:return this.inFrameset();case 18:return this.afterFrameset();case 19:return this.afterAfterBody();case 20:return this.afterAfterFrameset()}}currentNode(){return this.stack[this.stack.length-1]}adjustedCurrentNode(){let e=this.stack;return this.fragmentContext>=0&&e.length===1?this.fragmentContext:e[e.length-1]}isHtml(e,t){return this.hTag[e]===t&&this.hNs[e]===0}isHtmlNamedAsToken(e){if(this.hNs[e]!==0)return!1;let t=this.tok.tagId;return t===0?this.hName[e]===this.tok.name:this.hTag[e]===t}currentIs(e){return this.isHtml(this.currentNode(),e)}pop(){this.stack.pop()}popUntil(e){let t=this.stack;for(;t.length!==0;){let n=t.pop();if(this.hTag[n]===e&&this.hNs[n]===0)return}}popUntilNode(e){let t=this.stack;for(;t.length!==0;)if(t.pop()===e)return}popUntilNamedAsToken(){let e=this.stack;for(;e.length!==0;){let t=e.pop();if(this.isHtmlNamedAsToken(t))return}}stackIndexOf(e){let t=this.stack;for(let n=t.length-1;n>=0;n--)if(t[n]===e)return n;return-1}inScope(e,t){let n=this.stack;for(let r=n.length-1;r>=0;r--){let i=n[r],a=this.hTag[i];if(a===e&&this.hNs[i]===0)return!0;let o=No[a];if(t===8){if(o&8&&this.hNs[i]===0)return!1}else if(o&(1|t)&&(o&1||this.hNs[i]===0))return!1}return!1}tokenNameInScope(e){let t=this.tok.tagId;if(t!==0)return this.inScope(t,e);let n=this.stack,r=this.tok.name;for(let t=n.length-1;t>=0;t--){let i=n[t];if(this.hNs[i]===0&&this.hTag[i]===0&&this.hName[i]===r)return!0;let a=No[this.hTag[i]];if(e===8){if(a&8&&this.hNs[i]===0)return!1}else if(a&(1|e)&&(a&1||this.hNs[i]===0))return!1}return!1}nodeInScope(e){let t=this.stack;for(let n=t.length-1;n>=0;n--){let r=t[n];if(r===e)return!0;if(No[this.hTag[r]]&1)return!1}return!1}isSpecial(e){return!!(No[this.hTag[e]]&16)&&(this.hNs[e]===0||this.hTag[e]>=169)}templateInStack(){let e=this.stack;for(let t=e.length-1;t>=0;t--)if(this.isHtml(e[t],122))return!0;return!1}parsingTemplateContents(){if(this.templateInStack())return!0;let e=this.fragmentContext;return e>=0&&this.isHtml(e,122)}generateImpliedEndTags(e){let t=this.stack;for(;;){let n=t[t.length-1],r=this.hTag[n];if(this.hNs[n]!==0||!(No[r]&32)||r===e)return;t.pop()}}generateImpliedEndTagsThoroughly(){let e=this.stack;for(;;){let t=e[e.length-1];if(this.hNs[t]!==0||!(No[this.hTag[t]]&64))return;e.pop()}}closePElement(){this.generateImpliedEndTags(89),this.popUntil(89)}closePIfInButtonScope(){this.inScope(89,4)&&this.closePElement()}resetInsertionMode(){let e=this.stack;for(let t=e.length-1;t>=0;t--){let n=e[t],r=t===0;if(r&&this.fragmentContext>=0&&(n=this.fragmentContext),this.hNs[n]===0)switch(this.hTag[n]){case 121:case 125:if(!r){this.mode=14;return}break;case 129:this.mode=13;return;case 120:case 126:case 124:this.mode=12;return;case 19:this.mode=10;return;case 24:this.mode=11;return;case 119:this.mode=8;return;case 122:this.mode=this.templateModes[this.templateModes.length-1];return;case 52:if(!r){this.mode=3;return}break;case 15:this.mode=6;return;case 45:this.mode=17;return;case 56:this.mode=this.headElement<0?2:5;return}if(r){this.mode=6;return}}this.mode=6}appropriatePlace(e){let t=e>=0?e:this.currentNode();if(this.locRef=-1,this.fosterParenting&&this.hNs[t]===0){let e=this.hTag[t];if(e===119||e===120||e===124||e===126||e===129){let e=this.stack,n=-1,r=-1;for(let t=e.length-1;t>=0;t--){let i=e[t];if(this.hNs[i]===0&&(n<0&&this.hTag[i]===122&&(n=t),r<0&&this.hTag[i]===119&&(r=t),n>=0&&r>=0))break}if(n>=0&&(r<0||n>r))t=e[n];else if(r<0){this.locParent=e[0];return}else if(this.sink.hasParent(e[r])){this.locParent=-1,this.locRef=e[r];return}else t=e[r-1]}}if(this.hNs[t]===0&&this.hTag[t]===122){let e=this.hContents[t];e>=0&&(t=e)}this.locParent=t}insertChars(e){e.length!==0&&(this.appropriatePlace(-1),this.locParent!==this.docHandle&&this.sink.insertText(this.locParent,this.locRef,e))}insertComment(e){e>=0?this.sink.insertComment(e,-1,this.tok.data):(this.appropriatePlace(-1),this.sink.insertComment(this.locParent,this.locRef,this.tok.data))}insertPI(e){e>=0?this.sink.insertProcessingInstruction(e,-1,this.tok.name,this.tok.data):(this.appropriatePlace(-1),this.sink.insertProcessingInstruction(this.locParent,this.locRef,this.tok.name,this.tok.data))}recordElement(e,t,n,r){e===this.hNs.length?(this.hNs.push(t),this.hTag.push(n),this.hName.push(r),this.hIP.push(!1),this.hContents.push(-1)):this.setMeta(e,t,n,r,!1)}createHtmlElement(e,t,n){let r=this.tok,i=this.sink.createElement(e,0,this.locParent,this.locRef,n?r.attrNames:this.emptyStrings,n?r.attrValues:this.emptyStrings,this.emptyNumbers,n?r.attrCount:0,!1);this.recordElement(i,0,t,e),t===122&&(this.hContents[i]=this.sink.templateContents(i));let a=this.formElement;return a>=0&&No[t]&512&&this.fragmentContext<0&&!this.parsingTemplateContents()&&(No[t]&Mo&&n&&this.tokenHasAttr(`form`)||this.sink.associateForm(i,a)),i}tokenHasAttr(e){let t=this.tok;for(let n=0;n<t.attrCount;n++)if(t.attrNames[n]===e)return!0;return!1}tokenAttr(e){let t=this.tok;for(let n=0;n<t.attrCount;n++)if(t.attrNames[n]===e)return t.attrValues[n];return null}insertHtmlElement(){this.appropriatePlace(-1);let e=this.tok,t=this.createHtmlElement(e.name,e.tagId,!0);return this.sink.insert(this.locParent,this.locRef,t),this.stack.push(t),t}insertHtmlElementNamed(e,t){this.appropriatePlace(-1);let n=this.createHtmlElement(e,t,!1);return this.sink.insert(this.locParent,this.locRef,n),this.stack.push(n),n}insertVoidHtmlElement(){this.insertHtmlElement(),this.stack.pop()}insertForeignElement(e,t){let n=this.tok,r=n.name;if(e===1&&t){let e=Ro.get(r);e!==void 0&&(r=e)}let i=this.fNames,a=this.fValues,o=this.fNs;i.length=0,a.length=0,o.length=0;let s=``;for(let t=0;t<n.attrCount;t++){let r=n.attrNames[t],c=n.attrValues[t],l=0;if(e===2)r===`definitionurl`?r=`definitionURL`:r===`encoding`&&(s=c);else if(e===1){let e=Lo.get(r);e!==void 0&&(r=e)}r.charCodeAt(0)===120&&(r===`xlink:actuate`||r===`xlink:arcrole`||r===`xlink:href`||r===`xlink:role`||r===`xlink:show`||r===`xlink:title`||r===`xlink:type`?(l=1,r=r.slice(6)):r===`xml:lang`||r===`xml:space`?(l=2,r=r.slice(4)):r===`xmlns`?l=3:r===`xmlns:xlink`&&(l=3,r=`xlink`)),i.push(r),a.push(c),o.push(l)}this.appropriatePlace(-1);let c=this.sink.createElement(r,e,this.locParent,this.locRef,i,a,o,i.length,!0);return this.recordElement(c,e,0,r),this.setForeignFacts(c,e,r,s),this.sink.insert(this.locParent,this.locRef,c),this.stack.push(c),c}storeToken(){let e=this.tok,t=this.ptName.length;this.ptName.push(e.name),this.ptId.push(e.tagId),this.ptAttrStart.push(this.poolNames.length),this.ptAttrCount.push(e.attrCount);for(let t=0;t<e.attrCount;t++)this.poolNames.push(e.attrNames[t]),this.poolValues.push(e.attrValues[t]);return t}sameAsToken(e){let t=this.tok;if(this.ptName[e]!==t.name)return!1;let n=this.ptAttrCount[e];if(n!==t.attrCount)return!1;let r=this.ptAttrStart[e];for(let e=0;e<n;e++){let i=this.poolNames[r+e],a=!1;for(let o=0;o<n;o++)if(t.attrNames[o]===i){a=t.attrValues[o]===this.poolValues[r+e];break}if(!a)return!1}return!0}pushFormatting(e){let t=this.afe,n=0,r=-1;for(let e=t.length-1;e>=0&&t[e]!==-1;e--)this.sameAsToken(this.afeTok[e])&&(n++,r=e);n>=3&&(t.splice(r,1),this.afeTok.splice(r,1)),t.push(e),this.afeTok.push(this.storeToken())}insertMarker(){this.afe.push(-1),this.afeTok.push(-1)}clearToLastMarker(){let e=this.afe;for(;e.length!==0;)if(this.afeTok.pop(),e.pop()===-1)return}afeIndexOf(e){let t=this.afe;for(let n=t.length-1;n>=0;n--)if(t[n]===e)return n;return-1}createFromStored(e){let t=this.ptAttrStart[e],n=this.ptAttrCount[e],r=this.emptyStrings,i=this.emptyStrings;n!==0&&(r=this.poolNames.slice(t,t+n),i=this.poolValues.slice(t,t+n));let a=this.ptName[e],o=this.ptId[e],s=this.sink.createElement(a,0,this.locParent,this.locRef,r,i,this.emptyNumbers,n,!1);return this.recordElement(s,0,o,a),s}reconstructFormatting(){let e=this.afe,t=e.length;if(t===0)return;let n=e[t-1];if(n===-1||this.stackIndexOf(n)>=0)return;let r=t-1;for(;r>0;)if(r--,n=e[r],n===-1||this.stackIndexOf(n)>=0){r++;break}for(;r<e.length;r++){this.appropriatePlace(-1);let t=this.createFromStored(this.afeTok[r]);this.sink.insert(this.locParent,this.locRef,t),this.stack.push(t),e[r]=t}}adoptionAgency(){let e=this.stack,t=this.afe,n=this.currentNode();if(this.isHtmlNamedAsToken(n)&&this.afeIndexOf(n)<0)e.pop();else for(let n=0;n<8;n++){let n=-1;for(let e=t.length-1;e>=0;e--){let r=t[e];if(r===-1)break;if(this.isHtmlNamedAsToken(r)){n=e;break}}if(n<0){this.anyOtherEndTagInBody();return}let r=t[n],i=this.stackIndexOf(r);if(i<0){t.splice(n,1),this.afeTok.splice(n,1);return}if(!this.nodeInScope(r))return;let a=-1;for(let t=i+1;t<e.length;t++)if(this.isSpecial(e[t])){a=t;break}if(a<0){e.length=i,t.splice(n,1),this.afeTok.splice(n,1);return}let o=e[a],s=e[i-1],c=n,l=o,u=o,d=a,m=0;for(;m++,d--,l=e[d],l!==r;){let n=this.afeIndexOf(l);if(m>3&&n>=0&&(t.splice(n,1),this.afeTok.splice(n,1),n<c&&c--,n=-1),n<0){e.splice(d,1);continue}this.locParent=s,this.locRef=-1;let r=this.createFromStored(this.afeTok[n]);t[n]=r,e[d]=r,l=r,u===o&&(c=n+1),this.sink.insert(l,-1,u),u=l}this.appropriatePlace(s),this.sink.insert(this.locParent,this.locRef,u),n=this.afeIndexOf(r),this.locParent=o,this.locRef=-1;let h=this.afeTok[n],_=this.createFromStored(h);this.sink.reparentChildren(o,_),this.sink.insert(o,-1,_),t.splice(n,1),this.afeTok.splice(n,1),n<c&&c--,t.splice(c,0,_),this.afeTok.splice(c,0,h),e.splice(this.stackIndexOf(r),1),e.splice(this.stackIndexOf(o)+1,0,_)}}skipWs(){let e=this.chars,t=this.cpos;for(;t<e.length&&isWsCode(e.charCodeAt(t));)t++;return this.cpos=t,t<e.length}insertLeadingWs(){let e=this.chars,t=this.cpos,n=t;for(;n<e.length&&isWsCode(e.charCodeAt(n));)n++;return n>t&&this.insertChars(t===0&&n===e.length?e:e.slice(t,n)),this.cpos=n,n<e.length}restChars(){return this.cpos===0?this.chars:this.chars.slice(this.cpos)}bodyChars(e){this.charsHasNull&&(e=removeNulls(e)),e.length!==0&&(this.reconstructFormatting(),this.insertChars(e),this.framesetOk&&!isAllWs(e)&&(this.framesetOk=!1))}initial(){let e=this.tok;switch(this.ttype){case 1:if(!this.skipWs())return;break;case 4:this.insertComment(this.docHandle);return;case 7:this.insertPI(this.docHandle);return;case 5:if(this.sink.insertDoctype(this.docHandle,e.hasName?e.name:``,e.publicId,e.systemId),!this.iframeSrcdoc){let e=this.doctypeMode();e!==0&&this.setDocumentMode(e)}this.mode=1;return}this.iframeSrcdoc||this.setDocumentMode(1),this.mode=1,this.reprocess=!0}setDocumentMode(e){this.documentMode=e,this.sink.setDocumentMode(e)}doctypeMode(){let e=this.tok;if(e.forceQuirks||!e.hasName||e.name!==`html`)return 1;let t=e.hasPublicId?asciiLower(e.publicId):``,n=e.hasSystemId?asciiLower(e.systemId):``;if(e.hasPublicId){if(t===`-//w3o//dtd w3 html strict 3.0//en//`||t===`-/w3c/dtd html 4.0 transitional/en`||t===`html`)return 1;for(let e=0;e<zo.length;e++)if(t.startsWith(zo[e]))return 1}if(e.hasSystemId&&n===`http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd`)return 1;if(e.hasPublicId){let r=t.startsWith(`-//w3c//dtd html 4.01 frameset//`)||t.startsWith(`-//w3c//dtd html 4.01 transitional//`),i=!e.hasSystemId||n===``;if(i&&r)return 1;if(t.startsWith(`-//w3c//dtd xhtml 1.0 frameset//`)||t.startsWith(`-//w3c//dtd xhtml 1.0 transitional//`)||!i&&r)return 2}return 0}beforeHtml(){let e=this.tok;switch(this.ttype){case 5:return;case 4:this.insertComment(this.docHandle);return;case 7:this.insertPI(this.docHandle);return;case 1:if(!this.skipWs())return;break;case 2:if(e.tagId===56){this.locParent=this.docHandle,this.locRef=-1;let e=this.createHtmlElement(`html`,56,!0);this.sink.insert(this.docHandle,-1,e),this.stack.push(e),this.mode=2;return}break;case 3:{let t=e.tagId;if(t!==52&&t!==15&&t!==56&&t!==16)return;break}}this.locParent=this.docHandle,this.locRef=-1;let t=this.createHtmlElement(`html`,56,!1);this.sink.insert(this.docHandle,-1,t),this.stack.push(t),this.mode=2,this.reprocess=!0}beforeHead(){let e=this.tok;switch(this.ttype){case 1:if(!this.skipWs())return;break;case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 5:return;case 2:if(e.tagId===56){this.inBody();return}if(e.tagId===52){this.headElement=this.insertHtmlElement(),this.mode=3;return}break;case 3:{let t=e.tagId;if(t!==52&&t!==15&&t!==56&&t!==16)return;break}}this.headElement=this.insertHtmlElementNamed(`head`,52),this.mode=3,this.reprocess=!0}genericTextElement(e){this.insertHtmlElement(),this.tok.state=e,this.originalMode=this.mode,this.mode=7}inHead(){let e=this.tok;switch(this.ttype){case 1:if(!this.insertLeadingWs())return;break;case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 5:return;case 2:switch(e.tagId){case 56:this.inBody();return;case 10:case 11:case 12:case 68:case 77:this.insertVoidHtmlElement();return;case 128:this.genericTextElement(1);return;case 83:this.scripting?this.genericTextElement(2):(this.insertHtmlElement(),this.mode=4);return;case 82:case 114:this.genericTextElement(2);return;case 103:this.genericTextElement(3);return;case 122:this.templateStartTag();return;case 52:return}break;case 3:switch(e.tagId){case 52:this.pop(),this.mode=5;return;case 15:case 56:case 16:break;case 122:this.templateEndTag();return;default:return}}this.pop(),this.mode=5,this.reprocess=!0}templateStartTag(){this.insertMarker(),this.framesetOk=!1,this.mode=15,this.templateModes.push(15);let e=this.currentNode(),t=e===this.stack[0],n=this.allowDSD&&!t?this.tokenAttr(`shadowrootmode`):null,r=n===null?``:asciiLower(n);if(r===`open`||r===`closed`){this.appropriatePlace(-1);let t=this.sink.attachDeclarativeShadowRoot(e,r,this.tokenHasAttr(`shadowrootdelegatesfocus`),this.tokenHasAttr(`shadowrootserializable`),asciiLower(this.tokenAttr(`shadowrootslotassignment`)??``)===`manual`?`manual`:`named`,this.tokenHasAttr(`shadowrootclonable`));if(t>=0){let e=this.createHtmlElement(this.tok.name,122,!0);this.recordElement(t,0,0,`#shadow-root`),this.hContents[e]=t,this.stack.push(e);return}}this.insertHtmlElement()}templateEndTag(){this.templateInStack()&&(this.generateImpliedEndTagsThoroughly(),this.popUntil(122),this.clearToLastMarker(),this.templateModes.pop(),this.resetInsertionMode())}inHeadNoscript(){let e=this.tok;switch(this.ttype){case 5:return;case 2:switch(e.tagId){case 56:this.inBody();return;case 11:case 12:case 68:case 77:case 82:case 114:this.inHead();return;case 52:case 83:return}break;case 3:if(e.tagId===83){this.pop(),this.mode=3;return}if(e.tagId!==16)return;break;case 1:if(!this.insertLeadingWs())return;break;case 4:case 7:this.inHead();return}this.pop(),this.mode=3,this.reprocess=!0}afterHead(){let e=this.tok;switch(this.ttype){case 1:if(!this.insertLeadingWs())return;break;case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 5:return;case 2:switch(e.tagId){case 56:this.inBody();return;case 15:this.insertHtmlElement(),this.framesetOk=!1,this.mode=6;return;case 45:this.insertHtmlElement(),this.mode=17;return;case 10:case 11:case 12:case 68:case 77:case 82:case 103:case 114:case 122:case 128:{let e=this.headElement;this.stack.push(e),this.inHead();let t=this.stackIndexOf(e);t>=0&&this.stack.splice(t,1);return}case 52:return}break;case 3:switch(e.tagId){case 122:this.inHead();return;case 15:case 56:case 16:break;default:return}}this.insertHtmlElementNamed(`body`,15),this.framesetOk=!0,this.mode=6,this.reprocess=!0}inBody(){switch(this.ttype){case 1:this.bodyChars(this.restChars());return;case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 5:return;case 6:if(this.templateModes.length!==0){this.inTemplate();return}this.stopped=!0;return;case 2:this.inBodyStartTag();return;case 3:this.inBodyEndTag();return}}inBodyStartTag(){let e=this.tok,t=this.stack;switch(e.tagId){case 56:if(this.templateInStack())return;this.sink.addMissingAttributes(t[0],e.attrNames,e.attrValues,e.attrCount);return;case 10:case 11:case 12:case 68:case 77:case 82:case 103:case 114:case 122:case 128:this.inHead();return;case 15:if(t.length===1||!this.isHtml(t[1],15)||this.templateInStack())return;this.framesetOk=!1,this.sink.addMissingAttributes(t[1],e.attrNames,e.attrValues,e.attrCount);return;case 45:if(t.length===1||!this.isHtml(t[1],15)||!this.framesetOk)return;this.sink.remove(t[1]),t.length=1,this.insertHtmlElement(),this.mode=17;return;case 3:case 6:case 7:case 14:case 20:case 29:case 31:case 32:case 33:case 34:case 38:case 39:case 40:case 42:case 53:case 54:case 70:case 75:case 79:case 85:case 89:case 104:case 105:case 116:case 133:this.closePIfInButtonScope(),this.insertHtmlElement();return;case 46:case 47:case 48:case 49:case 50:case 51:{this.closePIfInButtonScope();let e=this.currentNode(),t=this.hTag[e];this.hNs[e]===0&&t>=46&&t<=51&&this.pop(),this.insertHtmlElement();return}case 93:case 69:this.closePIfInButtonScope(),this.insertHtmlElement(),this.skipNewline=!0,this.framesetOk=!1;return;case 43:{let e=this.parsingTemplateContents();if(this.formElement>=0&&!e)return;this.closePIfInButtonScope();let t=this.insertHtmlElement();e||(this.formElement=t);return}case 67:case 27:case 35:{this.framesetOk=!1;let n=e.tagId===67;for(let e=t.length-1;e>=0;e--){let r=t[e],i=this.hNs[r]===0?this.hTag[r]:-1;if(n?i===67:i===27||i===35){this.generateImpliedEndTags(i),this.popUntil(i);break}if(this.isSpecial(r)&&i!==3&&i!==33&&i!==89)break}this.closePIfInButtonScope(),this.insertHtmlElement();return}case 92:this.closePIfInButtonScope(),this.insertHtmlElement(),e.state=4;return;case 17:this.inScope(17,0)&&(this.generateImpliedEndTags(0),this.popUntil(17)),this.reconstructFormatting(),this.insertHtmlElement(),this.framesetOk=!1;return;case 1:{let e=this.afe;for(let n=e.length-1;n>=0;n--){let r=e[n];if(r===-1)break;if(this.isHtml(r,1)){this.adoptionAgency();let n=this.afeIndexOf(r);n>=0&&(e.splice(n,1),this.afeTok.splice(n,1));let i=this.stackIndexOf(r);i>=0&&t.splice(i,1);break}}this.reconstructFormatting(),this.pushFormatting(this.insertHtmlElement());return}case 9:case 13:case 22:case 36:case 41:case 57:case 101:case 109:case 112:case 113:case 131:case 132:this.reconstructFormatting(),this.pushFormatting(this.insertHtmlElement());return;case 80:this.reconstructFormatting(),this.inScope(80,0)&&(this.adoptionAgency(),this.reconstructFormatting()),this.pushFormatting(this.insertHtmlElement());return;case 4:case 73:case 84:this.reconstructFormatting(),this.insertHtmlElement(),this.insertMarker(),this.framesetOk=!1;return;case 119:this.documentMode!==1&&this.closePIfInButtonScope(),this.insertHtmlElement(),this.framesetOk=!1,this.mode=8;return;case 5:case 16:case 37:case 60:case 64:case 136:this.reconstructFormatting(),this.insertVoidHtmlElement(),this.framesetOk=!1;return;case 61:{let e=this.fragmentContext;if(e>=0&&this.isHtml(e,106))return;this.inScope(106,0)&&this.popUntil(106),this.reconstructFormatting(),this.insertVoidHtmlElement();let t=this.tokenAttr(`type`);(t===null||asciiLower(t)!==`hidden`)&&(this.framesetOk=!1);return}case 90:case 110:case 130:this.insertVoidHtmlElement();return;case 55:this.closePIfInButtonScope(),this.inScope(106,0)&&this.generateImpliedEndTags(0),this.insertVoidHtmlElement(),this.framesetOk=!1;return;case 59:e.name=`img`,e.tagId=60,this.reprocess=!0;return;case 123:this.insertHtmlElement(),this.skipNewline=!0,e.state=1,this.originalMode=this.mode,this.framesetOk=!1,this.mode=7;return;case 137:this.closePIfInButtonScope(),this.reconstructFormatting(),this.framesetOk=!1,this.genericTextElement(2);return;case 58:this.framesetOk=!1,this.genericTextElement(2);return;case 81:this.genericTextElement(2);return;case 83:if(this.scripting){this.genericTextElement(2);return}break;case 106:{let e=this.fragmentContext;if(e>=0&&this.isHtml(e,106))return;if(this.inScope(106,0)){this.popUntil(106);return}this.reconstructFormatting(),this.insertHtmlElement(),this.framesetOk=!1;return}case 87:this.inScope(106,0)?this.generateImpliedEndTags(86):this.currentIs(87)&&this.pop(),this.reconstructFormatting(),this.insertHtmlElement();return;case 86:this.inScope(106,0)?this.generateImpliedEndTags(0):this.currentIs(87)&&this.pop(),this.reconstructFormatting(),this.insertHtmlElement();return;case 96:case 99:this.inScope(100,0)&&this.generateImpliedEndTags(0),this.insertHtmlElement();return;case 97:case 98:this.inScope(100,0)&&this.generateImpliedEndTags(99),this.insertHtmlElement();return;case 74:this.reconstructFormatting(),this.insertForeignElement(2,!1),e.selfClosing&&this.pop();return;case 118:this.reconstructFormatting(),this.insertForeignElement(1,!1),e.selfClosing&&this.pop();return;case 19:case 23:case 24:case 44:case 52:case 120:case 121:case 124:case 125:case 126:case 129:return}this.reconstructFormatting(),this.insertHtmlElement()}inBodyEndTag(){let e=this.tok;switch(e.tagId){case 122:this.inHead();return;case 15:if(!this.inScope(15,0))return;this.mode=16;return;case 56:if(!this.inScope(15,0))return;this.mode=16,this.reprocess=!0;return;case 3:case 6:case 7:case 14:case 17:case 20:case 29:case 31:case 32:case 33:case 34:case 38:case 39:case 40:case 42:case 53:case 54:case 69:case 70:case 75:case 79:case 85:case 93:case 104:case 105:case 106:case 116:case 133:{let t=e.tagId;if(!this.inScope(t,0))return;this.generateImpliedEndTags(0),this.popUntil(t);return}case 43:if(this.parsingTemplateContents()){if(!this.inScope(43,0))return;this.generateImpliedEndTags(0),this.popUntil(43)}else{let e=this.formElement;if(this.formElement=-1,e<0||!this.nodeInScope(e))return;this.generateImpliedEndTags(0);let t=this.stackIndexOf(e);t>=0&&this.stack.splice(t,1)}return;case 89:this.inScope(89,4)||this.insertHtmlElementNamed(`p`,89),this.closePElement();return;case 67:if(!this.inScope(67,2))return;this.generateImpliedEndTags(67),this.popUntil(67);return;case 27:case 35:{let t=e.tagId;if(!this.inScope(t,0))return;this.generateImpliedEndTags(t),this.popUntil(t);return}case 46:case 47:case 48:case 49:case 50:case 51:{if(!this.inScope(46,0)&&!this.inScope(47,0)&&!this.inScope(48,0)&&!this.inScope(49,0)&&!this.inScope(50,0)&&!this.inScope(51,0))return;this.generateImpliedEndTags(0);let e=this.stack;for(;e.length!==0;){let t=e.pop(),n=this.hTag[t];if(this.hNs[t]===0&&n>=46&&n<=51)break}return}case 1:case 9:case 13:case 22:case 36:case 41:case 57:case 80:case 101:case 109:case 112:case 113:case 131:case 132:this.adoptionAgency();return;case 4:case 73:case 84:{let t=e.tagId;if(!this.inScope(t,0))return;this.generateImpliedEndTags(0),this.popUntil(t),this.clearToLastMarker();return}case 16:e.attrCount=0,this.ttype=2,this.reconstructFormatting(),this.insertVoidHtmlElement(),this.framesetOk=!1;return}this.anyOtherEndTagInBody()}anyOtherEndTagInBody(){let e=this.stack;for(let t=e.length-1;t>=0;t--){let n=e[t];if(this.isHtmlNamedAsToken(n)){let n=this.tok.tagId;this.generateImpliedEndTags(n===0?-1:n),e.length=t;return}if(this.isSpecial(n))return}}text(){switch(this.ttype){case 1:this.insertChars(this.restChars());return;case 6:this.pop(),this.mode=this.originalMode,this.reprocess=!0;return;case 3:this.pop(),this.mode=this.originalMode;return}}clearStackBackTo(e,t,n){let r=this.stack;for(;;){let i=r[r.length-1];if(this.hNs[i]===0){let r=this.hTag[i];if(r===e||r===t||r===n||r===122||r===56)return}r.pop()}}inTable(){let e=this.tok;switch(this.ttype){case 1:{let e=this.currentNode();if(this.hNs[e]===0){let t=this.hTag[e];if(t===119||t===120||t===122||t===124||t===126||t===129){this.pendingTableText=``,this.pendingTableNonWs=!1,this.originalMode=this.mode,this.mode=9,this.reprocess=!0;return}}break}case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 5:return;case 2:switch(e.tagId){case 19:this.clearStackBackTo(119,119,119),this.insertMarker(),this.insertHtmlElement(),this.mode=10;return;case 24:this.clearStackBackTo(119,119,119),this.insertHtmlElement(),this.mode=11;return;case 23:this.clearStackBackTo(119,119,119),this.insertHtmlElementNamed(`colgroup`,24),this.mode=11,this.reprocess=!0;return;case 120:case 124:case 126:this.clearStackBackTo(119,119,119),this.insertHtmlElement(),this.mode=12;return;case 121:case 125:case 129:this.clearStackBackTo(119,119,119),this.insertHtmlElementNamed(`tbody`,120),this.mode=12,this.reprocess=!0;return;case 119:if(!this.inScope(119,8))return;this.popUntil(119),this.resetInsertionMode(),this.reprocess=!0;return;case 114:case 103:case 122:this.inHead();return;case 61:{let e=this.tokenAttr(`type`);if(e===null||asciiLower(e)!==`hidden`)break;this.insertVoidHtmlElement();return}case 43:{let e=this.parsingTemplateContents();if(this.formElement>=0&&!e)return;let t=this.insertHtmlElement();e||(this.formElement=t),this.pop();return}}break;case 3:switch(e.tagId){case 119:if(!this.inScope(119,8))return;this.popUntil(119),this.resetInsertionMode();return;case 15:case 19:case 23:case 24:case 56:case 120:case 121:case 124:case 125:case 126:case 129:return;case 122:this.inHead();return}break;case 6:this.inBody();return}this.fosterParenting=!0,this.inBody(),this.fosterParenting=!1}inTableText(){if(this.ttype===1){let e=this.restChars();if(this.charsHasNull&&(e=removeNulls(e)),e.length===0)return;this.pendingTableText+=e,!this.pendingTableNonWs&&!isAllWs(e)&&(this.pendingTableNonWs=!0);return}let e=this.pendingTableText;if(this.pendingTableText=``,e.length!==0){if(this.pendingTableNonWs){let t=this.charsHasNull;this.charsHasNull=!1,this.fosterParenting=!0,this.bodyChars(e),this.fosterParenting=!1,this.charsHasNull=t}else this.insertChars(e)}this.mode=this.originalMode,this.reprocess=!0}inCaption(){let e=this.tok,t=this.ttype;if(t===3&&e.tagId===19){if(!this.inScope(19,8))return;this.generateImpliedEndTags(0),this.popUntil(19),this.clearToLastMarker(),this.mode=8;return}let n=e.tagId;if(t===2&&(n===19||n===23||n===24||n===120||n===121||n===124||n===125||n===126||n===129)||t===3&&n===119){if(!this.inScope(19,8))return;this.generateImpliedEndTags(0),this.popUntil(19),this.clearToLastMarker(),this.mode=8,this.reprocess=!0}else(t!==3||n!==15&&n!==23&&n!==24&&n!==56&&n!==120&&n!==121&&n!==124&&n!==125&&n!==126&&n!==129)&&this.inBody()}inColumnGroup(){let e=this.tok;switch(this.ttype){case 1:if(!this.insertLeadingWs())return;break;case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 5:return;case 2:if(e.tagId===56){this.inBody();return}if(e.tagId===23){this.insertVoidHtmlElement();return}if(e.tagId===122){this.inHead();return}break;case 3:if(e.tagId===24){if(!this.currentIs(24))return;this.pop(),this.mode=8;return}if(e.tagId===23)return;if(e.tagId===122){this.inHead();return}break;case 6:this.inBody();return}this.currentIs(24)&&(this.pop(),this.mode=8,this.reprocess=!0)}inTableBody(){let e=this.tok,t=this.ttype,n=e.tagId;if(t===2){if(n===129){this.clearStackBackTo(120,124,126),this.insertHtmlElement(),this.mode=13;return}if(n===125||n===121){this.clearStackBackTo(120,124,126),this.insertHtmlElementNamed(`tr`,129),this.mode=13,this.reprocess=!0;return}if(n===19||n===23||n===24||n===120||n===124||n===126){if(!this.inScope(120,8)&&!this.inScope(126,8)&&!this.inScope(124,8))return;this.clearStackBackTo(120,124,126),this.pop(),this.mode=8,this.reprocess=!0;return}}else if(t===3){if(n===120||n===124||n===126){if(!this.inScope(n,8))return;this.clearStackBackTo(120,124,126),this.pop(),this.mode=8;return}if(n===119){if(!this.inScope(120,8)&&!this.inScope(126,8)&&!this.inScope(124,8))return;this.clearStackBackTo(120,124,126),this.pop(),this.mode=8,this.reprocess=!0;return}if(n===15||n===19||n===23||n===24||n===56||n===121||n===125||n===129)return}this.inTable()}inRow(){let e=this.tok,t=this.ttype,n=e.tagId;if(t===2){if(n===125||n===121){this.clearStackBackTo(129,129,129),this.insertHtmlElement(),this.mode=14,this.insertMarker();return}if(n===19||n===23||n===24||n===120||n===124||n===126||n===129){if(!this.inScope(129,8))return;this.clearStackBackTo(129,129,129),this.pop(),this.mode=12,this.reprocess=!0;return}}else if(t===3){if(n===129){if(!this.inScope(129,8))return;this.clearStackBackTo(129,129,129),this.pop(),this.mode=12;return}if(n===119){if(!this.inScope(129,8))return;this.clearStackBackTo(129,129,129),this.pop(),this.mode=12,this.reprocess=!0;return}if(n===120||n===124||n===126){if(!this.inScope(n,8)||!this.inScope(129,8))return;this.clearStackBackTo(129,129,129),this.pop(),this.mode=12,this.reprocess=!0;return}if(n===15||n===19||n===23||n===24||n===56||n===121||n===125)return}this.inTable()}closeCell(){this.generateImpliedEndTags(0);let e=this.stack;for(;e.length!==0;){let t=e.pop();if(this.hNs[t]===0&&(this.hTag[t]===121||this.hTag[t]===125))break}this.clearToLastMarker(),this.mode=13}inCell(){let e=this.tok,t=this.ttype,n=e.tagId;if(t===3){if(n===121||n===125){if(!this.inScope(n,8))return;this.generateImpliedEndTags(0),this.popUntil(n),this.clearToLastMarker(),this.mode=13;return}if(n===15||n===19||n===23||n===24||n===56)return;if(n===119||n===120||n===124||n===126||n===129){if(!this.inScope(n,8))return;this.closeCell(),this.reprocess=!0;return}}else if(t===2&&(n===19||n===23||n===24||n===120||n===121||n===124||n===125||n===126||n===129)){if(!this.inScope(121,8)&&!this.inScope(125,8))return;this.closeCell(),this.reprocess=!0;return}this.inBody()}inTemplate(){let e=this.tok;switch(this.ttype){case 1:case 4:case 7:case 5:this.inBody();return;case 2:switch(e.tagId){case 10:case 11:case 12:case 68:case 77:case 82:case 103:case 114:case 122:case 128:this.inHead();return;case 19:case 24:case 120:case 124:case 126:this.switchTemplateMode(8);return;case 23:this.switchTemplateMode(11);return;case 129:this.switchTemplateMode(12);return;case 121:case 125:this.switchTemplateMode(13);return}this.switchTemplateMode(6);return;case 3:e.tagId===122&&this.inHead();return;case 6:if(!this.templateInStack()){this.stopped=!0;return}this.popUntil(122),this.clearToLastMarker(),this.templateModes.pop(),this.resetInsertionMode(),this.reprocess=!0;return}}switchTemplateMode(e){this.templateModes.pop(),this.templateModes.push(e),this.mode=e,this.reprocess=!0}afterBody(){let e=this.tok;switch(this.ttype){case 1:if(!this.skipWsViaBody())return;break;case 4:this.insertComment(this.stack[0]);return;case 7:this.insertPI(this.stack[0]);return;case 5:return;case 2:if(e.tagId===56){this.inBody();return}break;case 3:if(e.tagId===56){if(this.fragmentContext>=0)return;this.mode=19;return}break;case 6:this.stopped=!0;return}this.mode=6,this.reprocess=!0}skipWsViaBody(){let e=this.chars,t=this.cpos,n=t;for(;n<e.length&&isWsCode(e.charCodeAt(n));)n++;return n>t&&this.bodyChars(e.slice(t,n)),this.cpos=n,n<e.length}inFrameset(){let e=this.tok;switch(this.ttype){case 1:this.insertWsOnly();return;case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 2:switch(e.tagId){case 56:this.inBody();return;case 45:this.insertHtmlElement();return;case 44:this.insertVoidHtmlElement();return;case 82:this.inHead();return}return;case 3:if(e.tagId===45){if(this.currentNode()===this.stack[0])return;this.pop(),this.fragmentContext<0&&!this.currentIs(45)&&(this.mode=18)}return;case 6:this.stopped=!0;return}}insertWsOnly(){let e=this.restChars(),t=``,n=!0;for(let t=0;t<e.length;t++)if(!isWsCode(e.charCodeAt(t))){n=!1;break}if(n)t=e;else for(let n=0;n<e.length;n++)isWsCode(e.charCodeAt(n))&&(t+=e[n]);this.insertChars(t)}afterFrameset(){let e=this.tok;switch(this.ttype){case 1:this.insertWsOnly();return;case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 2:e.tagId===56?this.inBody():e.tagId===82&&this.inHead();return;case 3:e.tagId===56&&(this.mode=20);return;case 6:this.stopped=!0;return}}afterAfterBody(){let e=this.tok;switch(this.ttype){case 4:this.insertComment(this.docHandle);return;case 7:this.insertPI(this.docHandle);return;case 5:this.inBody();return;case 1:if(!this.skipWsViaBody())return;break;case 2:if(e.tagId===56){this.inBody();return}break;case 6:this.stopped=!0;return}this.mode=6,this.reprocess=!0}afterAfterFrameset(){let e=this.tok;switch(this.ttype){case 4:this.insertComment(this.docHandle);return;case 7:this.insertPI(this.docHandle);return;case 5:this.inBody();return;case 1:{let e=this.restChars(),t=``;for(let n=0;n<e.length;n++)isWsCode(e.charCodeAt(n))&&(t+=e[n]);t.length!==0&&this.bodyChars(t);return}case 2:e.tagId===56?this.inBody():e.tagId===82&&this.inHead();return;case 6:this.stopped=!0;return}}foreignContent(){let e=this.tok;switch(this.ttype){case 1:{let e=this.restChars();this.charsHasNull&&(e=e.replaceAll(`\0`,`�`)),this.insertChars(e),this.framesetOk&&hasNonWsNonNull(this.restChars())&&(this.framesetOk=!1);return}case 4:this.insertComment(-1);return;case 7:this.insertPI(-1);return;case 5:return;case 2:{let t=e.tagId,n=!!(No[t]&256);if(!n&&t===41&&(n=this.tokenHasAttr(`color`)||this.tokenHasAttr(`face`)||this.tokenHasAttr(`size`)),n){this.popToHtmlOrIntegrationPoint(),this.dispatchMode(this.mode);return}let r=this.adjustedCurrentNode(),i=this.hNs[r];this.insertForeignElement(i,!0),e.selfClosing&&this.pop();return}case 3:{let t=e.tagId;if(t===16||t===89){this.popToHtmlOrIntegrationPoint(),this.dispatchMode(this.mode);return}let n=this.stack,r=n.length-1,i=n[r];if(t===103&&this.hNs[i]===1&&this.hName[i]===`script`){this.pop();return}for(;;){if(r===0)return;if(asciiLower(this.hName[i])===e.name){n.length=r;return}if(r--,i=n[r],this.hNs[i]===0){this.dispatchMode(this.mode);return}}}}}popToHtmlOrIntegrationPoint(){let e=this.stack;for(;;){let t=e[e.length-1],n=this.hTag[t];if(this.hNs[t]===0||this.hIP[t]||n>=169&&n<=173)return;e.pop()}}},XMLParseError=class extends Error{};const Bo={lt:`<`,gt:`>`,amp:`&`,quot:`"`,apos:`'`};function isNameStartCode(e){return e>=97&&e<=122||e>=65&&e<=90||e===58||e===95||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=767||e>=880&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=55296&&e<=56319}function isNameCode(e){return isNameStartCode(e)||e>=48&&e<=57||e===45||e===46||e===183||e>=768&&e<=879||e>=8255&&e<=8256||e>=56320&&e<=57343}function isWs(e){return e===32||e===9||e===10||e===13}function checkChars(e,t){for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);r<32&&r!==9&&r!==10&&r!==13&&t.fail(`invalid character`),(r===65534||r===65535)&&t.fail(`invalid character`)}}var XMLParser=class{src;pos;doc;entities;constructor(e,t){this.src=e.replace(/\r\n?/g,`
5
- `),this.pos=0,this.doc=t,this.entities=/* @__PURE__ */ new Map}fail(e){let t=this.src.slice(0,this.pos),n=t.split(`
6
- `).length;throw new XMLParseError(`${e} (line ${n}, column ${this.pos-t.lastIndexOf(`
7
- `)})`)}startsWith(e){return this.src.startsWith(e,this.pos)}skipWs(){let e=this.pos;for(;this.pos<this.src.length&&isWs(this.src.charCodeAt(this.pos));)this.pos++;return this.pos>e}name(){let e=this.src,t=this.pos;for((t>=e.length||!isNameStartCode(e.charCodeAt(t)))&&this.fail(`expected a name`),this.pos++;this.pos<e.length&&isNameCode(e.charCodeAt(this.pos));)this.pos++;return e.slice(t,this.pos)}expect(e){this.startsWith(e)||this.fail(`expected "${e}"`),this.pos+=e.length}reference(){this.pos++;let e=this.src;if(e.charCodeAt(this.pos)===35){this.pos++;let t=!1;e.charCodeAt(this.pos)===120&&(t=!0,this.pos++);let n=this.pos;for(;this.pos<e.length&&e.charCodeAt(this.pos)!==59;)this.pos++;let r=e.slice(n,this.pos);r!==``&&(t?/^[0-9a-fA-F]+$/:/^[0-9]+$/).test(r)||this.fail(`invalid character reference`),this.expect(`;`);let i=parseInt(r,t?16:10);return i===9||i===10||i===13||i>=32&&i<=55295||i>=57344&&i<=65533||i>=65536&&i<=1114111||this.fail(`character reference to an invalid character`),String.fromCodePoint(i)}let t=this.name();this.expect(`;`);let n=Bo[t];if(n!==void 0)return n;let r=this.entities.get(t);if(r!==void 0)return r;this.fail(`undefined entity "${t}"`)}comment(e){this.pos+=4;let t=this.src.indexOf(`--`,this.pos);t<0&&this.fail(`unterminated comment`),this.src.charCodeAt(t+2)!==62&&(this.pos=t,this.fail(`"--" is not allowed in comments`));let n=this.src.slice(this.pos,t);checkChars(n,this),appendDetached(new Comment(n,this.doc)[z],e),this.pos=t+3}pi(e){this.pos+=2;let t=this.name();t.includes(`:`)&&this.fail(`processing instruction target contains a colon`);let n=``;if(this.startsWith(`?>`))this.pos+=2;else{this.skipWs()||this.fail(`expected whitespace after the processing instruction target`);let e=this.src.indexOf(`?>`,this.pos);e<0&&this.fail(`unterminated processing instruction`),n=this.src.slice(this.pos,e),this.pos=e+2}if(t.toLowerCase()===`xml`){if(e===null)return;this.fail(`XML declaration not at the start of the document`)}checkChars(n,this),e!==null&&appendDetached(new ProcessingInstruction(t,n,this.doc)[z],e)}quoted(){let e=this.src.charCodeAt(this.pos);e!==34&&e!==39&&this.fail(`expected a quoted string`);let t=this.src.indexOf(e===34?`"`:`'`,this.pos+1);t<0&&this.fail(`unterminated quoted string`);let n=this.src.slice(this.pos+1,t);return this.pos=t+1,n}doctype(e){this.pos+=9,this.skipWs()||this.fail(`expected whitespace after DOCTYPE`);let t=this.name(),n=``,r=``;this.skipWs(),this.startsWith(`PUBLIC`)?(this.pos+=6,this.skipWs(),n=this.quoted(),this.skipWs()||this.fail(`expected whitespace and a system literal after the public identifier`),r=this.quoted()):this.startsWith(`SYSTEM`)&&(this.pos+=6,this.skipWs(),r=this.quoted()),this.skipWs(),this.src.charCodeAt(this.pos)===91&&(this.internalSubset(),this.skipWs()),this.expect(`>`),appendDetached(new DocumentType(this.doc,t,n,r)[z],e)}internalSubset(){let e=this.src;for(this.pos++;this.pos<e.length;){if(e.charCodeAt(this.pos)===93){this.pos++;return}if(this.startsWith(`<!--`)){let t=e.indexOf(`-->`,this.pos+4);t<0&&this.fail(`unterminated comment`),this.pos=t+3}else if(this.startsWith(`<!ENTITY`)){this.pos+=8,this.skipWs();let t=!1;e.charCodeAt(this.pos)===37&&(t=!0,this.pos++,this.skipWs());let n=this.name();if(this.skipWs(),e.charCodeAt(this.pos)===34||e.charCodeAt(this.pos)===39){let e=this.quoted();t||this.entities.has(n)||e.includes(`<`)||e.includes(`&`)||this.entities.set(n,e)}this.skipToDeclEnd()}else if(this.startsWith(`<?`)){let t=e.indexOf(`?>`,this.pos);t<0&&this.fail(`unterminated processing instruction`),this.pos=t+2}else this.startsWith(`<!`)?(this.pos+=2,this.skipToDeclEnd()):this.pos++}this.fail(`unterminated DOCTYPE internal subset`)}skipToDeclEnd(){let e=this.src;for(;this.pos<e.length;){let t=e.charCodeAt(this.pos);if(t===34||t===39)this.quoted();else if(t===62){this.pos++;return}else this.pos++}this.fail(`unterminated markup declaration`)}lookup(e,t){let n=e.bindings.get(t);return n===void 0||n===``?null:n}element(e,t){let n=this.src;this.pos++;let r=this.name(),i=[],a=[],o=!1;for(;;){let e=this.skipWs();this.pos>=n.length&&this.fail(`unexpected end of input in a start tag`);let t=n.charCodeAt(this.pos);if(t===62){this.pos++;break}if(t===47){this.expect(`/>`),o=!0;break}e||this.fail(`expected whitespace between attributes`);let r=this.name();this.skipWs(),this.expect(`=`),this.skipWs();let s=this.attributeValue();i.includes(r)&&this.fail(`duplicate attribute "${r}"`),i.push(r),a.push(s)}let s=t;for(let e=0;e<i.length;e++){let n=i[e];if(n===`xmlns`||n.startsWith(`xmlns:`)){s===t&&(s={bindings:new Map(t.bindings)});let r=n===`xmlns`?``:n.slice(6),i=a[e];r===`xml`&&i!==`http://www.w3.org/XML/1998/namespace`&&this.fail(`the xml prefix cannot be rebound`),r===`xmlns`&&this.fail(`the xmlns prefix cannot be declared`),r!==``&&i===``&&this.fail(`empty namespace for prefix "${r}"`),(i===`http://www.w3.org/2000/xmlns/`||i===`http://www.w3.org/XML/1998/namespace`&&r!==`xml`)&&this.fail(`reserved namespace`),s.bindings.set(r,i)}}let c=r.indexOf(`:`),l=null,u=r,d;c>=0?(l=r.slice(0,c),u=r.slice(c+1),(l===``||u===``||u.includes(`:`))&&this.fail(`invalid qualified name "${r}"`),d=this.lookup(s,l),d===null&&this.fail(`unbound namespace prefix "${l}"`)):d=this.lookup(s,``);let m=createElementImpl(this.doc,u,d,l),h=/* @__PURE__ */ new Set;for(let e=0;e<i.length;e++){let t=i[e],n=t.indexOf(`:`),r=null,o=t,c=null;t===`xmlns`?c=ne:n>=0&&(r=t.slice(0,n),o=t.slice(n+1),(r===``||o===``||o.includes(`:`))&&this.fail(`invalid attribute name "${t}"`),r===`xmlns`?c=ne:r===`xml`?c=k:(c=this.lookup(s,r),c===null&&this.fail(`unbound namespace prefix "${r}"`)));let l=(c??``)+` `+o;h.has(l)&&this.fail(`duplicate attribute "${t}"`),h.add(l),appendAttributeDetached(m,o,a[e],c,r)}appendDetached(m,e),!o&&(this.content(m,s),this.expect(`</`),this.name()!==r&&this.fail(`mismatched end tag: expected "</${r}>"`),this.skipWs(),this.expect(`>`))}attributeValue(){let e=this.src,t=e.charCodeAt(this.pos);t!==34&&t!==39&&this.fail(`expected a quoted attribute value`),this.pos++;let n=``,r=this.pos;for(;;){this.pos>=e.length&&this.fail(`unterminated attribute value`);let i=e.charCodeAt(this.pos);if(i===t)break;i===60&&this.fail(`"<" is not allowed in attribute values`),i===38?(n+=e.slice(r,this.pos),n+=this.reference(),r=this.pos):((i===9||i===10||i===13)&&(n+=e.slice(r,this.pos)+` `,r=this.pos+1),this.pos++)}return n+=e.slice(r,this.pos),this.pos++,checkChars(n,this),n}content(e,t){let n=this.src,r=``;for(;;){this.pos>=n.length&&this.fail(`unexpected end of input: unclosed element`);let i=n.charCodeAt(this.pos);if(i===60){if(n.charCodeAt(this.pos+1)===47)break;if(this.flushText(e,r),r=``,this.startsWith(`<!--`))this.comment(e);else if(this.startsWith(`<![CDATA[`)){let t=n.indexOf(`]]>`,this.pos+9);t<0&&this.fail(`unterminated CDATA section`);let r=n.slice(this.pos+9,t);checkChars(r,this),appendDetached(new CDATASection(r,this.doc)[z],e),this.pos=t+3}else this.startsWith(`<?`)?this.pi(e):this.startsWith(`<!`)?this.fail(`unexpected markup declaration`):this.element(e,t);continue}if(i===38){r+=this.reference();continue}let a=this.pos;for(;this.pos<n.length;){let e=n.charCodeAt(this.pos);if(e===60||e===38)break;this.pos++}let o=n.slice(a,this.pos);o.includes(`]]>`)&&(this.pos=a+o.indexOf(`]]>`),this.fail(`"]]>" is not allowed in content`)),r+=o}this.flushText(e,r)}flushText(e,t){if(t===``)return;checkChars(t,this);let n=e.last;n!==null&&n.type===3?n.data+=t:appendDetached(new Text(t,this.doc)[z],e)}parseDocument(e){let t=this.src;t.charCodeAt(0)===65279&&(this.pos=1),this.startsWith(`<?xml`)&&isWs(t.charCodeAt(this.pos+5))&&this.pi(null);let n={bindings:/* @__PURE__ */ new Map([[`xml`,k]])},r=!1,i=!1;for(;this.skipWs(),!(this.pos>=t.length);)this.startsWith(`<!--`)?this.comment(e):this.startsWith(`<?`)?this.pi(e):this.startsWith(`<!DOCTYPE`)?((i||r)&&this.fail(`unexpected DOCTYPE`),i=!0,this.doctype(e)):t.charCodeAt(this.pos)===60&&this.pos+1<t.length&&isNameStartCode(t.charCodeAt(this.pos+1))?(r&&this.fail(`junk after document element`),r=!0,this.element(e,n)):r?this.fail(`junk after document element`):this.fail(t.charCodeAt(this.pos)===60?`not well-formed`:`text outside of the document element`);r||this.fail(`no root element found`)}parseFragment(e,t){this.src+=`</`,this.content(e,t),this.pos!==this.src.length-2&&this.fail(`not well-formed`)}};function parseXML(e,t,n){let r=new DocumentFragment(t)[z];try{new XMLParser(String(e).toWellFormed(),t).parseDocument(r)}catch(e){if(!(e instanceof XMLParseError))throw e;let n=createElementImpl(t,`parsererror`,`http://www.mozilla.org/newlayout/xml/parsererror.xml`,null);appendDetached(new Text(e.message,t)[z],n),append(n,t[z]);return}append(r,t[z])}function parseXMLFragment(e,t){let n=t.doc,r=new DocumentFragment(n)[z],i=/* @__PURE__ */ new Map([[`xml`,k]]),a=[];for(let e=t;e!==null;e=e.parent)e.type===1&&a.push(e);for(let e=a.length-1;e>=0;e--){let t=a[e];t.prefix!==null&&t.ns!==null&&i.set(t.prefix,t.ns);let n=t.attrs;if(n!==null)for(let e of n)e.ns===`http://www.w3.org/2000/xmlns/`&&i.set(e.prefix===null?``:e.localName,e.value)}i.set(``,t.type===1?t.ns??``:E);try{new XMLParser(String(e),n).parseFragment(r,{bindings:i})}catch(e){throw e instanceof XMLParseError?new DOMException(`The provided markup is not well-formed XML: ${e.message}.`,`SyntaxError`):e}return r}var DomSink=class extends TreeSink{nodes;hooked;modeTarget;otherNs;constructor(){super(),this.nodes=[],this.hooked=[],this.modeTarget=null,this.otherNs=null}begin(e){this.nodes.length=0,this.hooked.length=0,this.modeTarget=e,this.otherNs=null}finish(){let e=this.hooked;for(let t=0;t<e.length;t++)e[t].node._childrenChangedSteps();e.length=0,this.nodes.length=0,this.modeTarget=null}register(e){let t=this.nodes;return t.push(e),t.length-1}parentOf(e,t){return e>=0?this.nodes[e]:this.nodes[t].parent}createElement(e,t,n,r,i,a,o,s,c){let l=this.parentOf(n,r).doc,u=createElementImpl(l,e,t===0?E:t===1?D:t===2?te:this.otherNs,null);if(c)for(let e=0;e<s;e++){let t=o[e];t===0?appendAttributeDetached(u,i[e],a[e],null,null):t===1?appendAttributeDetached(u,i[e],a[e],O,`xlink`):t===2?appendAttributeDetached(u,i[e],a[e],k,`xml`):t===3&&appendAttributeDetached(u,i[e],a[e],ne,i[e]===`xmlns`?null:`xmlns`)}else for(let e=0;e<s;e++)appendAttributeDetached(u,i[e],a[e],null,null);return $i&&t===0&&ceParserCreated(u),u.flags&16&&this.hooked.push(u),this.register(u)}insert(e,t,n){let r=this.nodes[n],i=this.parentOf(e,t);r.parent!==null&&remove(r,!0),r.doc!==i.doc&&adopt(r,i.doc),t<0?appendDetached(r,i):insertDetached(r,i,this.nodes[t])}insertText(e,t,n){let r=this.parentOf(e,t),i=t>=0?this.nodes[t]:null,a=i===null?r.last:i.prev;if(a!==null&&a.type===3){a.data+=n;return}let o=new Text(n,r.doc)[z];i===null?appendDetached(o,r):insertDetached(o,r,i)}insertComment(e,t,n){let r=this.parentOf(e,t),i=new Comment(n,r.doc)[z];t<0?appendDetached(i,r):insertDetached(i,r,this.nodes[t])}insertProcessingInstruction(e,t,n,r){let i=this.parentOf(e,t),a=new ProcessingInstruction(n,r,i.doc)[z];t<0?appendDetached(a,i):insertDetached(a,i,this.nodes[t])}insertDoctype(e,t,n,r){let i=this.nodes[e];for(let e=i.first;e!==null;e=e.next)if(e.type===1||e.type===10)return;appendDetached(new DocumentType(i.doc,t,n,r)[z],i)}remove(e){let t=this.nodes[e];t.parent!==null&&remove(t,!0)}hasParent(e){return this.nodes[e].parent!==null}reparentChildren(e,t){let n=this.nodes[e],r=this.nodes[t];for(let e=n.first;e!==null;e=n.first)remove(e,!0),appendDetached(e,r)}addMissingAttributes(e,t,n,r){let i=this.nodes[e];if(i.type===1)for(let e=0;e<r;e++)findAttributeByName(i,t[e])===null&&appendAttributeDetached(i,t[e],n[e],null,null)}templateContents(e){let t=this.nodes[e].node.content;return t==null?e:this.register(t[z])}attachDeclarativeShadowRoot(e,t,n,r,i,a){let o=this.nodes[e].node;if(o[G]!=null)return-1;try{let e=attachShadowRoot(o,t===`closed`?`closed`:`open`,a,r,n,i===`manual`?`manual`:`named`);return e[Nt]=!0,e[Ye]=!0,this.register(e[z])}catch{return-1}}associateForm(e,t){let n=this.nodes[e].node;typeof n._parserAssociateForm==`function`&&n._parserAssociateForm(this.nodes[t].node)}setDocumentMode(e){let t=this.modeTarget;t!==null&&(t[qn]=e===1?`quirks`:e===2?`limited-quirks`:`no-quirks`)}};let Vo=null,Ho=!1;function acquire(){return Ho?new TreeBuilder(new DomSink):(Ho=!0,Vo??=new TreeBuilder(new DomSink))}function release(e){e===Vo&&(Ho=!1)}const Uo=new ParseOptions,Wo=new ParseOptions;function toOptions(e){if(e===void 0)return Uo;let t=Wo;return t.scripting=e.scripting===!0,t.allowDeclarativeShadowRoots=e.allowDeclarativeShadowRoots===!0,t.processingInstructions=e.processingInstructions===!0,t.iframeSrcdoc=!1,t}function nsCode(e){return e===`http://www.w3.org/1999/xhtml`?0:e===`http://www.w3.org/2000/svg`?1:e===`http://www.w3.org/1998/Math/MathML`?2:3}function parseFragment(e,t,n){let r=t.doc;if(!r[Nn])return parseXMLFragment(e,t);let i=new DocumentFragment(r)[z],a=acquire(),o=a.sink;try{o.begin(null);let s=o.register(i),c=o.register(t),l=nsCode(t.ns);l===3&&(o.otherNs=t.ns);let u=-1;for(let e=t;e!==null;e=e.parent)if(e.type===1&&e.tag===Z.form&&e.ns===`http://www.w3.org/1999/xhtml`){u=o.register(e);break}let d=r[qn]===`quirks`?1:r[qn]===`limited-quirks`?2:0,m=l===2?attr(t,`encoding`)??``:``;a.parseFragment(e,s,c,t.name,l,m,u,d,toOptions(n)),o.finish()}finally{o.nodes.length=0,release(a)}return i}function parseDocument(e,t,n){let r=new DocumentFragment(t)[z],i=acquire(),a=i.sink;try{a.begin(t),t[qn]=`no-quirks`;let o=a.register(r);i.parseDocument(e,o,toOptions(n)),a.finish()}finally{a.nodes.length=0,release(i)}append(r,t[z])}function setHTMLUnsafe(e,t){let n=e;if(e.type!==1){let t=e.node[R];if(t===null)throw TypeError(`setHTMLUnsafe: no context element`);n=t[z]}let r=parseFragment(t,n,{allowDeclarativeShadowRoots:!0}),i=e;if(e.type===1&&e.tag===Z.template&&e.ns===`http://www.w3.org/1999/xhtml`){let t=e.node.content;t!==void 0&&(i=t[z])}i.node._replaceAll(r.node)}function parseHTMLUnsafe(e,t){parseDocument(e,t,{allowDeclarativeShadowRoots:!0})}function isVoidTag(e){switch(e){case Z.area:case Z.base:case Z.basefont:case Z.bgsound:case Z.br:case Z.col:case Z.embed:case Z.frame:case Z.hr:case Z.img:case Z.input:case Z.keygen:case Z.link:case Z.meta:case Z.param:case Z.source:case Z.track:case Z.wbr:return!0}return!1}function isRawTextTag(e){switch(e){case Z.style:case Z.script:case Z.xmp:case Z.iframe:case Z.noembed:case Z.noframes:case Z.plaintext:return!0}return!1}function escapeText(e){let t=e.length,n=0;for(;n<t;n++){let t=e.charCodeAt(n);if(t===38||t===60||t===62||t===160)break}if(n===t)return e;let r=e.slice(0,n),i=n;for(;n<t;n++){let t=e.charCodeAt(n),a=``;if(t===38)a=`&amp;`;else if(t===60)a=`&lt;`;else if(t===62)a=`&gt;`;else if(t===160)a=`&nbsp;`;else continue;r+=e.slice(i,n)+a,i=n+1}return r+e.slice(i)}function escapeAttribute(e){let t=e.length,n=0;for(;n<t;n++){let t=e.charCodeAt(n);if(t===38||t===34||t===60||t===62||t===160)break}if(n===t)return e;let r=e.slice(0,n),i=n;for(;n<t;n++){let t=e.charCodeAt(n),a=``;if(t===38)a=`&amp;`;else if(t===34)a=`&quot;`;else if(t===60)a=`&lt;`;else if(t===62)a=`&gt;`;else if(t===160)a=`&nbsp;`;else continue;r+=e.slice(i,n)+a,i=n+1}return r+e.slice(i)}function serializedAttrName(e,t,n){return e===null?n:e===`http://www.w3.org/XML/1998/namespace`?`xml:`+n:e===`http://www.w3.org/2000/xmlns/`?n===`xmlns`?`xmlns`:`xmlns:`+n:e===`http://www.w3.org/1999/xlink`?`xlink:`+n:t}function templateContentsOf(e){let t=e.node.content;return t==null?e:t[z]}let Go=``,Ko=!1,qo=null;function htmlChildren(e){if(e.type===1){if(e.ns===`http://www.w3.org/1999/xhtml`&&isVoidTag(e.tag))return;(Ko||qo!==null)&&htmlShadowRoot(e),e.tag===Z.template&&e.ns===`http://www.w3.org/1999/xhtml`&&(e=templateContentsOf(e))}for(let t=e.first;t!==null;t=t.next)switch(t.type){case 1:htmlElement(t);break;case 3:case 4:{let e=t.parent;e!==null&&e.type===1&&e.ns===`http://www.w3.org/1999/xhtml`&&isRawTextTag(e.tag)?Go+=t.data:Go+=escapeText(t.data);break}case 8:Go+=`<!--`+t.data+`-->`;break;case 7:Go+=`<?`+t.name+` `+t.data+`?>`;break;case 10:Go+=`<!DOCTYPE `+t.name+`>`}}function htmlElement(e){let t=e.ns,n=t===`http://www.w3.org/1999/xhtml`||t===`http://www.w3.org/2000/svg`||t===`http://www.w3.org/1998/Math/MathML`||e.prefix===null?e.name:e.prefix+`:`+e.name,r=`<`+n,i=e.attrs;if(i!==null)for(let e=0;e<i.length;e++){let t=i[e];r+=` `+(t.ns===null?t.localName:serializedAttrName(t.ns,t.name,t.localName))+`="`+escapeAttribute(t.value)+`"`}Go+=r+`>`,!(t===`http://www.w3.org/1999/xhtml`&&isVoidTag(e.tag))&&(htmlChildren(e),Go+=`</`+n+`>`)}function htmlShadowRoot(e){let t=e.node[G];if(t==null||!(Ko&&t[Mr]||qo!==null&&qo.includes(t)))return;let n=`<template shadowrootmode="`+(t[qn]===`open`?`open`:`closed`)+`"`;t[It]&&(n+=` shadowrootdelegatesfocus=""`),t[Mr]&&(n+=` shadowrootserializable=""`),t[Hr]===`manual`&&(n+=` shadowrootslotassignment="manual"`),t[ft]&&(n+=` shadowrootclonable=""`),Go+=n+`>`,htmlChildren(t[z]),Go+=`</template>`}function runHtml(e,t,n,r){let i=Go,a=Ko,o=qo;Go=``,Ko=t,qo=n;try{if(r)switch(e.type){case 1:htmlElement(e);break;case 9:case 11:htmlChildren(e);break;default:{let t=e.parent;e.type===3||e.type===4?Go=t!==null&&t.type===1&&t.ns===`http://www.w3.org/1999/xhtml`&&isRawTextTag(t.tag)?e.data:escapeText(e.data):e.type===8?Go=`<!--`+e.data+`-->`:e.type===7?Go=`<?`+e.name+` `+e.data+`?>`:e.type===10&&(Go=`<!DOCTYPE `+e.name+`>`)}}else htmlChildren(e);return Go}finally{Go=i,Ko=a,qo=o}}function inHTMLDocument(e){return e.doc[Nn]}function serializeChildren(e){if(inHTMLDocument(e))return runHtml(e,!1,null,!1);let t=``,n=e;e.type===1&&e.tag===Z.template&&e.ns===`http://www.w3.org/1999/xhtml`&&(n=templateContentsOf(e));for(let e=n.first;e!==null;e=e.next)t+=serializeXML(e,!0);return t}function serializeNode(e){return inHTMLDocument(e)?runHtml(e,!1,null,!0):serializeXML(e,!0)}function getHTML(e,t){let n=t?.serializableShadowRoots===!0,r=t?.shadowRoots;return runHtml(e,n,r!==void 0&&r.length!==0?r:null,!1)}var XmlError=class extends Error{};function invalid(e){throw new XmlError(e)}function copyMap(e){let t=/* @__PURE__ */ new Map;for(let[n,r]of e)t.set(n,r.slice());return t}function preferredPrefix(e,t,n){let r=e.get(n);if(r===void 0||r.length===0)return null;for(let e=0;e<r.length;e++)if(r[e]===t)return r[e];return r[r.length-1]}function prefixFound(e,t,n){let r=e.get(n);return r!==void 0&&r.includes(t)}function addPrefix(e,t,n){let r=e.get(n);r===void 0?e.set(n,[t]):r.push(t)}var PrefixIndex=class{value=1};function generatePrefix(e,t,n){let r=`ns`+String(n.value++);return addPrefix(e,r,t),r}function hasInvalidXmlChars(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n!==9&&n!==10&&n!==13){if(n<32||n===65534||n===65535)return!0;if(n>=55296&&n<=56319){let n=t+1<e.length?e.charCodeAt(t+1):0;if(n<56320||n>57343)return!0;t++}else if(n>=56320&&n<=57343)return!0}}return!1}function isNameStart(e){return e>=97&&e<=122||e>=65&&e<=90||e===58||e===95||e>=192&&e!==215&&e!==247}function isXmlName(e){if(e.length===0||!isNameStart(e.charCodeAt(0)))return!1;for(let t=1;t<e.length;t++){let n=e.charCodeAt(t);if(!(isNameStart(n)||n>=48&&n<=57||n===45||n===46||n===183))return!1}return!0}function escapeXmlText(e){let t=``,n=0;for(let r=0;r<e.length;r++){let i=e.charCodeAt(r),a=``;if(i===38)a=`&amp;`;else if(i===60)a=`&lt;`;else if(i===62)a=`&gt;`;else continue;t+=e.slice(n,r)+a,n=r+1}return n===0?e:t+e.slice(n)}function serializeAttrValue(e,t){if(e===null)return``;t&&hasInvalidXmlChars(e)&&invalid(`attribute value contains invalid characters`);let n=``,r=0;for(let t=0;t<e.length;t++){let i=e.charCodeAt(t),a=``;if(i===38)a=`&amp;`;else if(i===34)a=`&quot;`;else if(i===60)a=`&lt;`;else if(i===62)a=`&gt;`;else if(i===9)a=`&#x9;`;else if(i===10)a=`&#xA;`;else if(i===13)a=`&#xD;`;else continue;n+=e.slice(r,t)+a,r=t+1}return r===0?e:n+e.slice(r)}function prefixBound(e,t){for(let n of e.values())if(n.includes(t))return!0;return!1}const Jo=/* @__PURE__ */ new Set([`area`,`base`,`basefont`,`bgsound`,`br`,`col`,`embed`,`frame`,`hr`,`img`,`input`,`keygen`,`link`,`menuitem`,`meta`,`param`,`source`,`track`,`wbr`]);function recordNamespaceInformation(e,t,n){let r=null,i=e.attrs;if(i===null)return null;for(let e=0;e<i.length;e++){let a=i[e];if(a.ns!==`http://www.w3.org/2000/xmlns/`)continue;if(a.prefix===null){r=a.value;continue}let o=a.localName,s=a.value;s!==`http://www.w3.org/XML/1998/namespace`&&(s===``&&(s=null),!prefixFound(t,o,s)&&(addPrefix(t,o,s),n.set(o,s??``)))}return r}function serializeAttributes(e,t,n,r,i,a){let o=``,s=e.attrs;if(s===null)return o;let c=a?/* @__PURE__ */ new Set:null;for(let e=0;e<s.length;e++){let l=s[e];if(c!==null){let e=(l.ns??``)+`\0`+l.localName;c.has(e)&&invalid(`duplicate attribute`),c.add(e)}let u=l.ns;if(u===null&&l.localName===`xmlns`){a&&invalid(`invalid attribute name`);continue}let d=null;if(u!==null){if(d=preferredPrefix(t,l.prefix,u),u===`http://www.w3.org/2000/xmlns/`){if(l.value===`http://www.w3.org/XML/1998/namespace`||l.prefix===null&&i||l.prefix!==null&&(!r.has(l.localName)||r.get(l.localName)!==l.value))continue;a&&l.value===`http://www.w3.org/2000/xmlns/`&&invalid(`xmlns namespace declared as a value`),a&&l.value===``&&invalid(`empty namespace declaration`),l.prefix===`xmlns`&&(d=`xmlns`)}else d===null&&(u===`http://www.w3.org/1999/xlink`&&l.prefix!==null&&!r.has(l.prefix)&&!prefixBound(t,l.prefix)?(d=l.prefix,addPrefix(t,d,u)):d=generatePrefix(t,u,n),o+=` xmlns:`+d+`="`+serializeAttrValue(u,a)+`"`)}o+=` `,d!==null&&(o+=d+`:`),a&&(l.localName.includes(`:`)||!isXmlName(l.localName)||l.localName===`xmlns`&&u===null)&&invalid(`invalid attribute name`),o+=l.localName+`="`+serializeAttrValue(l.value,a)+`"`}return o}function serializeElementXML(e,t,n,r,i){let a=e.name;i&&(a.includes(`:`)||!isXmlName(a))&&invalid(`invalid element name`);let o=`<`,s=``,c=!1,l=!1;n=copyMap(n);let u=/* @__PURE__ */ new Map,d=recordNamespaceInformation(e,n,u),m=t,h=e.ns;if(m===h)d!==null&&(l=!0),s=h===`http://www.w3.org/XML/1998/namespace`?`xml:`+a:a,o+=s;else{let t=e.prefix,c=preferredPrefix(n,t,h);t===`xmlns`&&(i&&invalid(`element prefix xmlns`),c=t),c===null?t===null?d===null||d!==h?(l=!0,s=a,m=h,o+=s+` xmlns="`+serializeAttrValue(h,i)+`"`):(s=a,m=h,o+=s):(u.has(t)?t=generatePrefix(n,h,r):addPrefix(n,t,h),s=t+`:`+a,o+=s+` xmlns:`+t+`="`+serializeAttrValue(h,i)+`"`,d!==null&&(m=d===``?null:d)):(s=c+`:`+a,d!==null&&d!==`http://www.w3.org/XML/1998/namespace`&&(m=d===``?null:d),o+=s)}o+=serializeAttributes(e,n,r,u,l,i);let _=h===`http://www.w3.org/1999/xhtml`&&a===`template`?templateContentsOf(e):e;if(h===`http://www.w3.org/1999/xhtml`&&_.first===null&&Jo.has(a)?(o+=` /`,c=!0):h!==`http://www.w3.org/1999/xhtml`&&_.first===null&&(o+=`/`,c=!0),o+=`>`,c)return o;for(let e=_.first;e!==null;e=e.next)o+=xmlNode(e,m,n,r,i);return o+`</`+s+`>`}function xmlNode(e,t,n,r,i){switch(e.type){case 1:return serializeElementXML(e,t,n,r,i);case 9:{if(i){let t=!1;for(let n=e.first;n!==null;n=n.next)n.type===1&&(t=!0);t||invalid(`document without a document element`)}let a=``;for(let o=e.first;o!==null;o=o.next)a+=xmlNode(o,t,n,r,i);return a}case 11:{let a=``;for(let o=e.first;o!==null;o=o.next)a+=xmlNode(o,t,n,r,i);return a}case 8:{let t=e.data;return i&&(hasInvalidXmlChars(t)||t.includes(`--`)||t.endsWith(`-`))&&invalid(`invalid comment`),`<!--`+t+`-->`}case 3:{let t=e.data;return i&&hasInvalidXmlChars(t)&&invalid(`invalid text`),escapeXmlText(t)}case 4:return`<![CDATA[`+e.data+`]]>`;case 10:{let t=e.node;i&&(hasInvalidXmlChars(t.publicId)&&invalid(`invalid doctype public id`),(hasInvalidXmlChars(t.systemId)||t.systemId.includes(`"`)&&t.systemId.includes(`'`))&&invalid(`invalid doctype system id`));let n=`<!DOCTYPE `+e.name;return t.publicId!==``&&(n+=` PUBLIC "`+t.publicId+`"`),t.systemId!==``&&t.publicId===``&&(n+=` SYSTEM`),t.systemId!==``&&(n+=` "`+t.systemId+`"`),n+`>`}case 7:return i&&(e.name.includes(`:`)||e.name.toLowerCase()===`xml`||hasInvalidXmlChars(e.data)||e.data.includes(`?>`))&&invalid(`invalid processing instruction`),`<?`+e.name+` `+e.data+`?>`}return``}function serializeXML(e,t){let n=/* @__PURE__ */ new Map;n.set(k,[`xml`]);try{return xmlNode(e,null,n,new PrefixIndex,t)}catch(e){throw e instanceof XmlError?new DOMException(`The node could not be serialized as XML: ${e.message}.`,`InvalidStateError`):e}}let Yo=null;function setShadowHostCustomStateCheck(e){Yo=e}var ShadowRoot=class extends DocumentFragment{[qn];[It];[Hr];[ft];[Mr];[Nt];[Ye];constructor(e,t,n,r,i,a,o){if(arguments.length<3)throw TypeError(`Illegal constructor`);super(e);let s=this[z];s.flags|=32,t[z].flags&1&&(s.flags|=1),this[R]=t,this[qn]=n,this[It]=r,this[Hr]=i,this[ft]=a,this[Mr]=o,this[Nt]=!1,this[Ye]=Yo!==null&&Yo(t)}get mode(){return this[qn]}get host(){return this[R]}get delegatesFocus(){return this[It]}get slotAssignment(){return this[Hr]}get clonable(){return this[ft]}get serializable(){return this[Mr]}get innerHTML(){return serializeChildren(this[z])}set innerHTML(e){let t=parseFragment(e===null?``:String(e),this[R][z]);this._replaceAll(t.node)}getHTML(e){return getHTML(this[z],e)}setHTMLUnsafe(e){setHTMLUnsafe(this[z],String(e))}get activeElement(){let e=this[z],t=e.doc[L];for(;t!==null;){let n=treeRoot(t);if(n===e)return t.node;if(!(n.flags&32))return null;let r=n.node[R];t=r===null?null:r[z]}return null}elementFromPoint(e,t){return null}elementsFromPoint(e,t){return[]}};Object.defineProperty(ShadowRoot.prototype,Symbol.toStringTag,{value:`ShadowRoot`,configurable:!0});const Xo=[];function orderedSet(e){let t=e.length;if(t<2)return e;if(t>16){let n=new Set(e);return n.size===t?e:[...n]}for(let n=1;n<t;n++){let t=e[n];for(let r=0;r<n;r++)if(e[r]===t){let t=[];for(let n of e)t.includes(n)||t.push(n);return t}}return e}function validateToken(e){if(e===``)throw new DOMException(`The token provided must not be empty.`,`SyntaxError`);for(let t=0;t<e.length;t++)if(isAsciiWhitespace(e.charCodeAt(t)))throw new DOMException(`The token provided ('${e}') contains HTML space characters, which are not valid in tokens.`,`InvalidCharacterError`)}let Zo=null;var Qo=class DOMTokenList{#e;#t;#n;#r;#i;constructor(e,t,n=null){this.#e=e,this.#t=t,this.#n=n,this.#r=null,this.#i=Xo,Zo===null&&(Zo=indexGetterTable(DOMTokenList.prototype,(e,t)=>e.item(t)??void 0,16))}#a(){let e=this.#e;if(this.#t===`class`){let t=classTokens(e);return t!==this.#r&&(this.#r=t,this.#i=orderedSet(t)),this.#i}let t=attr(e,this.#t);return t!==this.#r&&(this.#r=t,this.#i=t===null||t===``?Xo:orderedSet(splitOnAsciiWhitespace(t))),this.#i}#o(e){let t=this.#e;(e.length!==0||attr(t,this.#t)!==null)&&setAttribute(t,this.#t,e.join(` `))}get length(){let e=this.#a().length;return e>Zo.count&&ensureIndexGetters(Zo,e),e}item(e){let t=this.#a(),n=Number(e)>>>0;return n<t.length?t[n]:null}contains(e){return this.#a().includes(String(e))}add(...e){let t=e.map(String);for(let e of t)validateToken(e);let n=this.#a().slice();for(let e of t)n.includes(e)||n.push(e);this.#o(n)}remove(...e){let t=e.map(String);for(let e of t)validateToken(e);let n=this.#a().filter(e=>!t.includes(e));this.#o(n)}toggle(e,t){let n=String(e);validateToken(n);let r=this.#a();return r.includes(n)?t===void 0||!t?(this.#o(r.filter(e=>e!==n)),!1):!0:t===void 0||t?(this.#o([...r,n]),!0):!1}replace(e,t){let n=String(e),r=String(t);if(n===``||r===``)throw new DOMException(`The token provided must not be empty.`,`SyntaxError`);validateToken(n),validateToken(r);let i=this.#a();if(!i.includes(n))return!1;let a=[],o=!1;for(let e of i)e===n||e===r?o||=(a.push(r),!0):a.push(e);return this.#o(a),!0}supports(e){let t=this.#n;if(t===null)throw TypeError(`'${this.#t}' attribute has no supported tokens`);return t.includes(String(e).toLowerCase())}get value(){return attr(this.#e,this.#t)??``}set value(e){setAttribute(this.#e,this.#t,String(e))}toString(){return this.value}_clear(){removeAttribute(this.#e,this.#t)}};Object.defineProperties(Qo.prototype,{forEach:{value:ra,writable:!0,enumerable:!0,configurable:!0},entries:{value:Array.prototype.entries,writable:!0,enumerable:!0,configurable:!0},keys:{value:Array.prototype.keys,writable:!0,enumerable:!0,configurable:!0},values:{value:Array.prototype.values,writable:!0,enumerable:!0,configurable:!0},[Symbol.iterator]:{value:Array.prototype.values,writable:!0,configurable:!0},[Symbol.toStringTag]:{value:`DOMTokenList`,configurable:!0}});function toAttributeName(e){let t=`data-`;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t+=r>=65&&r<=90?`-`+String.fromCharCode(r+32):e[n]}return t}function toPropertyName(e){if(!e.startsWith(`data-`))return null;let t=``;for(let n=5;n<e.length;n++){let r=e.charCodeAt(n);if(r>=65&&r<=90)return null;if(r===45&&n+1<e.length){let r=e.charCodeAt(n+1);if(r>=97&&r<=122){t+=String.fromCharCode(r-32),n++;continue}}t+=e[n]}return t}function getNamed(e,t){let n=e.attrs;if(n!==null)for(let e=0;e<n.length;e++){let r=n[e];if(r.ns===null&&toPropertyName(r.localName)===t)return r.value}}function supportedNames(e){let t=[],n=e.attrs;if(n===null)return t;for(let e=0;e<n.length;e++){let r=n[e];if(r.ns!==null)continue;let i=toPropertyName(r.localName);i!==null&&t.push(i)}return t}function setNamed(e,t,n){for(let e=0;e<t.length-1;e++){let n=t.charCodeAt(e+1);if(t.charCodeAt(e)===45&&n>=97&&n<=122)throw new DOMException(`'${t}' is not a valid property name.`,`SyntaxError`)}let r=toAttributeName(t);if(!isValidAttributeLocalName(r))throw new DOMException(`'${r}' is not a valid attribute name.`,`InvalidCharacterError`);setAttribute(e,r,n)}function deleteNamed(e,t){let n=findAttributeByNamespace(e,null,toAttributeName(t));n!==null&&removeAttributeRecord(e,n)}const $o=Symbol(`DOMStringMap owner`),es={get(e,t,n){if(typeof t==`string`){let n=getNamed(e[$o],t);if(n!==void 0)return n}else if(t===$o)return;return Reflect.get(e,t,n)},set(e,t,n,r){return typeof t==`string`?(setNamed(e[$o],t,String(n)),!0):t!==$o&&Reflect.set(e,t,n,r)},has(e,t){return typeof t==`string`&&getNamed(e[$o],t)!==void 0||t!==$o&&Reflect.has(e,t)},deleteProperty(e,t){return typeof t==`string`?(deleteNamed(e[$o],t),!0):t===$o||Reflect.deleteProperty(e,t)},ownKeys(e){let t=supportedNames(e[$o]);for(let n of Reflect.ownKeys(e))n!==$o&&!t.includes(n)&&t.push(n);return t},getOwnPropertyDescriptor(e,t){if(typeof t==`string`){let n=getNamed(e[$o],t);if(n!==void 0)return{value:n,writable:!0,enumerable:!0,configurable:!0}}else if(t===$o)return;return Reflect.getOwnPropertyDescriptor(e,t)},defineProperty(e,t,n){return typeof t==`string`?n.get!==void 0||n.set!==void 0?!1:(setNamed(e[$o],t,String(n.value)),!0):t!==$o&&Reflect.defineProperty(e,t,n)}};function createDOMStringMap(e){let t=Object.create(DOMStringMap.prototype);return t[$o]=e,new Proxy(t,es)}var DOMStringMap=class{constructor(e){return createDOMStringMap(e)}};Object.defineProperty(DOMStringMap.prototype,Symbol.toStringTag,{value:`DOMStringMap`,configurable:!0});var Attr=class extends Node{[_r];[er];constructor(e,t,n,r,i,a,o=null){super(2,e);let s=this[z];s.name=t,s.data=n,s.ns=r,s.prefix=i,this[er]=a,this[_r]=o}get namespaceURI(){return this[z].ns}get prefix(){return this[z].prefix}get localName(){return this[z].name}get name(){let e=this[z];return e.prefix===null?e.name:e.prefix+`:`+e.name}get value(){return attrValue(this)}set value(e){setAttrValue(this,String(e))}get ownerElement(){return this[er]}get specified(){return!0}_attach(e,t){this[er]=e,this[_r]=t,this[z].doc=e[z].doc}_detach(){let e=this[_r];e!==null&&(this[z].data=e.value),this[er]=null,this[_r]=null}};function attrNode(e,t){let n=t.attr;return n===null&&(n=new Attr(e.doc,t.localName,t.value,t.ns,t.prefix,e.node,t),t.attr=n),n}function setAttributeNode(e,t){let n=t[er];if(n!==null&&n[z]!==e)throw new DOMException(`The attribute is in use by another element.`,`InUseAttributeError`);let r=t[z],i=findAttributeByNamespace(e,r.ns,r.name);if(i!==null&&i.attr===t)return t;let a=new AttrRecord(r.name,t.value,r.ns,r.prefix);if(a.attr=t,i!==null){let n=attrNode(e,i),r=e.attrs;return r[r.indexOf(i)]=a,t._attach(e.node,a),n._detach(),handleAttributeChanges(e,a,i.value,a.value),n}return t._attach(e.node,a),appendAttribute(e,a),null}function removeAttributeNode(e,t){let n=t[_r],r=e.attrs;if(n===null||r===null||!r.includes(n))throw new DOMException(`The attribute is not an attribute of this element.`,`NotFoundError`);return removeAttributeRecord(e,n),t}let ts=null;const ns=Symbol(`NamedNodeMap.element`),isArrayIndex=e=>/^(?:0|[1-9]\d*)$/.test(e)&&Number(e)<4294967295;function namedAttribute(e,t){let n=e[ns];return n.flags&2&&/[A-Z]/.test(t)?null:findAttributeByName(n,t)}function named(e,t){return typeof t==`string`&&!(t in e)&&!isArrayIndex(t)?namedAttribute(e,t):null}const rs={get(e,t){let n=e[t];if(n!==void 0||typeof t==`symbol`||t in e)return n;let r=isArrayIndex(t)?null:namedAttribute(e,t);return r===null?void 0:attrNode(e[ns],r)},has(e,t){return t in e||named(e,t)!==null},getOwnPropertyDescriptor(e,t){let n=named(e,t);return n===null?t===ns?void 0:Reflect.getOwnPropertyDescriptor(e,t):{value:attrNode(e[ns],n),writable:!1,enumerable:!1,configurable:!0}},ownKeys(e){let t=Reflect.ownKeys(e).filter(e=>e!==ns),n=e[ns].attrs;if(n!==null)for(let r=0;r<n.length;r++){let i=n[r].name;!t.includes(i)&&named(e,i)!==null&&t.push(i)}return t}};function byName(e,t){let n=String(t);return findAttributeByName(e,e.flags&2?asciiLowercase$1(n):n)}var is=class NamedNodeMap{constructor(e){return Object.defineProperty(this,ns,{value:e,configurable:!0}),ts===null&&(ts=indexGetterTable(NamedNodeMap.prototype,(e,t)=>e.item(t)??void 0,16)),new Proxy(this,rs)}get length(){let e=this[ns].attrs,t=e===null?0:e.length;return t>ts.count&&ensureIndexGetters(ts,t),t}item(e){let t=this[ns],n=t.attrs,r=Number(e)>>>0;return n===null||r>=n.length?null:attrNode(t,n[r])}getNamedItem(e){let t=byName(this[ns],e);return t===null?null:attrNode(this[ns],t)}getNamedItemNS(e,t){let n=this[ns],r=findAttributeByNamespace(n,e===``||e===void 0?null:e,String(t));return r===null?null:attrNode(n,r)}setNamedItem(e){return setAttributeNode(this[ns],e)}setNamedItemNS(e){return setAttributeNode(this[ns],e)}removeNamedItem(e){let t=this[ns],n=byName(this[ns],e);if(n===null)throw new DOMException(`No item with name '${e}' was found.`,`NotFoundError`);let r=attrNode(t,n);return removeAttributeRecord(t,n),r}removeNamedItemNS(e,t){let n=this[ns],r=findAttributeByNamespace(n,e===``||e===void 0?null:e,String(t));if(r===null)throw new DOMException(`No item with name '${e}::${t}' was found.`,`NotFoundError`);let i=attrNode(n,r);return removeAttributeRecord(n,r),i}},AttributeIterator=class extends Iterator{#e;#t=0;constructor(e){super(),this.#e=e}next(){let e=this.#e;if(e!==null){let t=e.attrs,n=this.#t;if(t!==null&&n<t.length)return this.#t=n+1,{value:attrNode(e,t[n]),done:!1};this.#e=null}return{value:void 0,done:!0}}};Object.defineProperty(AttributeIterator.prototype,Symbol.toStringTag,{value:`Array Iterator`,configurable:!0});const as=Array.prototype.values,os={values(){let e=this===null||this===void 0?void 0:this[ns];return e===void 0?as.call(this):new AttributeIterator(e)}}.values;Object.defineProperties(is.prototype,{[Symbol.iterator]:{value:os,writable:!0,configurable:!0},[Symbol.toStringTag]:{value:`NamedNodeMap`,configurable:!0}});function isValidElementLocalName(e){let t=e.length;if(t===0)return!1;let n=e.charCodeAt(0);if(n>=97&&n<=122||n>=65&&n<=90){for(let n=1;n<t;n++){let t=e.charCodeAt(n);if(t===32||t===9||t===10||t===12||t===13||t===0||t===47||t===62)return!1}return!0}if(n!==58&&n!==95&&n<128)return!1;for(let n=1;n<t;n++){let t=e.charCodeAt(n);if(!(t>=97&&t<=122||t>=65&&t<=90||t>=48&&t<=57||t===45||t===46||t===58||t===95||t>=128))return!1}return!0}function isValidNamespacePrefix(e){let t=e.length;if(t===0)return!1;for(let n=0;n<t;n++){let t=e.charCodeAt(n);if(t===32||t===9||t===10||t===12||t===13||t===0||t===47||t===62)return!1}return!0}function isValidDoctypeName(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n===32||n===9||n===10||n===12||n===13||n===0||n===62)return!1}return!0}const ss=`A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\u{10000}-\\u{EFFFF}`,cs=RegExp(`^[:${ss}][:${ss}\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`,`u`);function isXMLName(e){return cs.test(e)}function validateAndExtract(e,t,n){e===``&&(e=null);let r=null,i=t,a=t.indexOf(`:`);if(a!==-1&&(r=t.slice(0,a),i=t.slice(a+1),!isValidNamespacePrefix(r)))throw new DOMException(`"${r}" is not a valid namespace prefix.`,`InvalidCharacterError`);if(n===`attribute`?!isValidAttributeLocalName(i):!isValidElementLocalName(i))throw new DOMException(`"${t}" is not a valid qualified name.`,`InvalidCharacterError`);if(r!==null&&e===null)throw new DOMException(`A prefix was given but no namespace was provided.`,`NamespaceError`);if(r===`xml`&&e!==`http://www.w3.org/XML/1998/namespace`)throw new DOMException(`A prefix of "xml" was given but the namespace was not the XML namespace.`,`NamespaceError`);if((t===`xmlns`||r===`xmlns`)&&e!==`http://www.w3.org/2000/xmlns/`)throw new DOMException(`A prefix or qualifiedName of "xmlns" was given but the namespace was not the XMLNS namespace.`,`NamespaceError`);if(e===`http://www.w3.org/2000/xmlns/`&&t!==`xmlns`&&r!==`xmlns`)throw new DOMException(`The XMLNS namespace was given but neither the prefix nor qualifiedName was "xmlns".`,`NamespaceError`);return{namespace:e,prefix:r,localName:i}}let setPoint,setRect;var DOMPointReadOnly=class{#e;#t;#n;#r;static{setPoint=(e,t,n)=>{t===0?e.#e=n:t===1?e.#t=n:t===2?e.#n=n:e.#r=n}}constructor(e=0,t=0,n=0,r=1){this.#e=Number(e),this.#t=Number(t),this.#n=Number(n),this.#r=Number(r)}static fromPoint(e={}){return new this(e.x,e.y,e.z,e.w)}get x(){return this.#e}get y(){return this.#t}get z(){return this.#n}get w(){return this.#r}matrixTransform(e){let t=matrixFromInit(e,`matrixTransform`,`DOMPointReadOnly`),n=this.#e,r=this.#t,i=this.#n,a=this.#r;return new ls(t[0]*n+t[4]*r+t[8]*i+t[12]*a,t[1]*n+t[5]*r+t[9]*i+t[13]*a,t[2]*n+t[6]*r+t[10]*i+t[14]*a,t[3]*n+t[7]*r+t[11]*i+t[15]*a)}toJSON(){return{x:this.#e,y:this.#t,z:this.#n,w:this.#r}}},ls=class DOMPoint extends DOMPointReadOnly{static fromPoint(e={}){return new DOMPoint(e.x,e.y,e.z,e.w)}get x(){return super.x}set x(e){setPoint(this,0,Number(e))}get y(){return super.y}set y(e){setPoint(this,1,Number(e))}get z(){return super.z}set z(e){setPoint(this,2,Number(e))}get w(){return super.w}set w(e){setPoint(this,3,Number(e))}},DOMRectReadOnly=class{#e;#t;#n;#r;static{setRect=(e,t,n)=>{t===0?e.#e=n:t===1?e.#t=n:t===2?e.#n=n:e.#r=n}}constructor(e=0,t=0,n=0,r=0){this.#e=Number(e),this.#t=Number(t),this.#n=Number(n),this.#r=Number(r)}static fromRect(e={}){return new this(e.x,e.y,e.width,e.height)}get x(){return this.#e}get y(){return this.#t}get width(){return this.#n}get height(){return this.#r}get top(){return Math.min(this.#t,this.#t+this.#r)}get right(){return Math.max(this.#e,this.#e+this.#n)}get bottom(){return Math.max(this.#t,this.#t+this.#r)}get left(){return Math.min(this.#e,this.#e+this.#n)}toJSON(){return{x:this.#e,y:this.#t,width:this.#n,height:this.#r,top:this.top,right:this.right,bottom:this.bottom,left:this.left}}},us=class DOMRect extends DOMRectReadOnly{static fromRect(e={}){return new DOMRect(e.x,e.y,e.width,e.height)}get x(){return super.x}set x(e){setRect(this,0,Number(e))}get y(){return super.y}set y(e){setRect(this,1,Number(e))}get width(){return super.width}set width(e){setRect(this,2,Number(e))}get height(){return super.height}set height(e){setRect(this,3,Number(e))}},DOMRectList=class{#e;constructor(e=[]){this.#e=e;for(let t=0;t<e.length;t++)Object.defineProperty(this,t,{value:e[t],enumerable:!0})}get length(){return this.#e.length}item(e){return this.#e[e>>>0]??null}[Symbol.iterator](){return this.#e[Symbol.iterator]()}};const ds=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],fs=Math.PI/180,ps=.5,ms=1.5;let matrixOf,hs=null;function createMatrix(e){return hs=e,new Is}function copyOf(e){let t=matrixOf(e);return createMatrix([t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8],t[9],t[10],t[11],t[12],t[13],t[14],t[15],t[16]])}const gs=[.5,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];function set16(e,t,n,r,i,a,o,s,c,l,u,d,m,h,_,v,y){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e[4]=a,e[5]=o,e[6]=s,e[7]=c,e[8]=l,e[9]=u,e[10]=d,e[11]=m,e[12]=h,e[13]=_,e[14]=v,e[15]=y,e}function multiplyInto(e,t,n){let r=t[0],i=t[1],a=t[2],o=t[3],s=t[4],c=t[5],l=t[6],u=t[7],d=t[8],m=t[9],h=t[10],_=t[11],v=t[12],y=t[13],b=t[14],x=t[15],S=n[0],C=n[1],w=n[2],T=n[3],ee=n[4],E=n[5],D=n[6],te=n[7],O=n[8],k=n[9],ne=n[10],A=n[11],re=n[12],ie=n[13],ae=n[14],oe=n[15];e[0]=r*S+s*C+d*w+v*T- -0,e[1]=i*S+c*C+m*w+y*T- -0,e[2]=a*S+l*C+h*w+b*T- -0,e[3]=o*S+u*C+_*w+x*T- -0,e[4]=r*ee+s*E+d*D+v*te- -0,e[5]=i*ee+c*E+m*D+y*te- -0,e[6]=a*ee+l*E+h*D+b*te- -0,e[7]=o*ee+u*E+_*D+x*te- -0,e[8]=r*O+s*k+d*ne+v*A- -0,e[9]=i*O+c*k+m*ne+y*A- -0,e[10]=a*O+l*k+h*ne+b*A- -0,e[11]=o*O+u*k+_*ne+x*A- -0,e[12]=r*re+s*ie+d*ae+v*oe- -0,e[13]=i*re+c*ie+m*ae+y*oe- -0,e[14]=a*re+l*ie+h*ae+b*oe- -0,e[15]=o*re+u*ie+_*ae+x*oe- -0}function allFinite(e,t,n,r,i,a,o,s,c,l,u,d,m,h,_,v){let y=e+t+n+r+i+a+o+s+c+l+u+d+m+h+_+v;return y-y===0}function translateBy(e,t,n,r){let i=e[0],a=e[1],o=e[2],s=e[3],c=e[4],l=e[5],u=e[6],d=e[7],m=e[8],h=e[9],_=e[10],v=e[11],y=e[12],b=e[13],x=e[14],S=e[15];allFinite(i,a,o,s,c,l,u,d,m,h,_,v,y,b,x,S)?(e[0]=i- -0,e[1]=a- -0,e[2]=o- -0,e[3]=s- -0,e[4]=c- -0,e[5]=l- -0,e[6]=u- -0,e[7]=d- -0,e[8]=m- -0,e[9]=h- -0,e[10]=_- -0,e[11]=v- -0,e[12]=i*t+c*n+m*r+y- -0,e[13]=a*t+l*n+h*r+b- -0,e[14]=o*t+u*n+_*r+x- -0,e[15]=s*t+d*n+v*r+S- -0):multiplyInto(e,e,set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,t,n,r,1))}function scaleBy(e,t,n,r){let i=e[0],a=e[1],o=e[2],s=e[3],c=e[4],l=e[5],u=e[6],d=e[7],m=e[8],h=e[9],_=e[10],v=e[11],y=e[12],b=e[13],x=e[14],S=e[15];allFinite(i,a,o,s,c,l,u,d,m,h,_,v,y,b,x,S)?(e[0]=i*t- -0,e[1]=a*t- -0,e[2]=o*t- -0,e[3]=s*t- -0,e[4]=c*n- -0,e[5]=l*n- -0,e[6]=u*n- -0,e[7]=d*n- -0,e[8]=m*r- -0,e[9]=h*r- -0,e[10]=_*r- -0,e[11]=v*r- -0,e[12]=y- -0,e[13]=b- -0,e[14]=x- -0,e[15]=S- -0):multiplyInto(e,e,set16(gs,t,0,0,0,0,n,0,0,0,0,r,0,0,0,0,1))}function multiplyBy2x2(e,t,n,r,i){let a=e[0],o=e[1],s=e[2],c=e[3],l=e[4],u=e[5],d=e[6],m=e[7],h=e[8],_=e[9],v=e[10],y=e[11],b=e[12],x=e[13],S=e[14],C=e[15];allFinite(a,o,s,c,l,u,d,m,h,_,v,y,b,x,S,C)?(e[0]=a*t+l*n- -0,e[1]=o*t+u*n- -0,e[2]=s*t+d*n- -0,e[3]=c*t+m*n- -0,e[4]=a*r+l*i- -0,e[5]=o*r+u*i- -0,e[6]=s*r+d*i- -0,e[7]=c*r+m*i- -0,e[8]=h- -0,e[9]=_- -0,e[10]=v- -0,e[11]=y- -0,e[12]=b- -0,e[13]=x- -0,e[14]=S- -0,e[15]=C- -0):multiplyInto(e,e,set16(gs,t,n,0,0,r,i,0,0,0,0,1,0,0,0,0,1))}function skewBy(e,t,n){multiplyBy2x2(e,1,Math.tan(n*fs),Math.tan(t*fs),1)}function skewing(e,t){return set16(gs,1,Math.tan(t*fs),0,0,Math.tan(e*fs),1,0,0,0,0,1,0,0,0,0,1)}function rotation(e,t,n,r){let i=r*fs;if(e===0&&t===0){if(n===0)return set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1);let e=n>0?Math.sin(i):-Math.sin(i),t=Math.cos(i);return set16(gs,t,e,0,0,-e,t,0,0,0,0,1,0,0,0,0,1)}if(t===0&&n===0){let t=e>0?Math.sin(i):-Math.sin(i),n=Math.cos(i);return set16(gs,1,0,0,0,0,n,t,0,0,-t,n,0,0,0,0,1)}if(e===0&&n===0){let e=t>0?Math.sin(i):-Math.sin(i),n=Math.cos(i);return set16(gs,n,0,-e,0,0,1,0,0,e,0,n,0,0,0,0,1)}let a=Math.hypot(e,t,n);e/=a,t/=a,n/=a;let o=i/2,s=Math.sin(o)*Math.cos(o),c=Math.sin(o)**2;return set16(gs,1-2*(t*t+n*n)*c,2*(e*t*c+n*s),2*(e*n*c-t*s),0,2*(e*t*c-n*s),1-2*(e*e+n*n)*c,2*(t*n*c+e*s),0,2*(e*n*c+t*s),2*(t*n*c-e*s),1-2*(e*e+t*t)*c,0,0,0,0,1)}function rotateBy(e,t,n,r,i){if(t===0&&n===0&&r!==0){let t=i*fs,n=r>0?Math.sin(t):-Math.sin(t),a=Math.cos(t);multiplyBy2x2(e,a,n,-n,a)}else multiplyInto(e,e,rotation(t,n,r,i))}function rotateEuler(e,t,n,r){rotateBy(e,0,0,1,r),!(t===0&&n===0&&allFinite(e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15]))&&(multiplyInto(e,e,rotation(0,1,0,n)),multiplyInto(e,e,rotation(1,0,0,t)))}function invert(e){let t=e[0],n=e[1],r=e[2],i=e[3],a=e[4],o=e[5],s=e[6],c=e[7],l=e[8],u=e[9],d=e[10],m=e[11],h=e[12],_=e[13],v=e[14],y=e[15],b=t*o-n*a,x=t*s-r*a,S=t*c-i*a,C=n*s-r*o,w=n*c-i*o,T=r*c-i*s,ee=l*_-u*h,E=l*v-d*h,D=l*y-m*h,te=u*v-d*_,O=u*y-m*_,k=d*y-m*v,ne=b*k-x*O+S*te+C*D-w*E+T*ee;if(ne===0||!Number.isFinite(ne))return!1;let A=1/ne;return e[0]=(o*k-s*O+c*te)*A,e[1]=(r*O-n*k-i*te)*A,e[2]=(_*T-v*w+y*C)*A,e[3]=(d*w-u*T-m*C)*A,e[4]=(s*D-a*k-c*E)*A,e[5]=(t*k-r*D+i*E)*A,e[6]=(v*S-h*T-y*x)*A,e[7]=(l*T-d*S+m*x)*A,e[8]=(a*O-o*D+c*ee)*A,e[9]=(n*D-t*O-i*ee)*A,e[10]=(h*w-_*S+y*b)*A,e[11]=(u*S-l*w-m*b)*A,e[12]=(o*E-a*te-s*ee)*A,e[13]=(t*te-n*E+r*ee)*A,e[14]=(_*x-h*C-v*b)*A,e[15]=(l*C-u*x+d*b)*A,!0}function invert2D(e){let t=e[0],n=e[1],r=e[4],i=e[5],a=e[12],o=e[13],s=t*i-n*r;return s===0||!Number.isFinite(s)?!1:(e[0]=i/s,e[1]=-n/s,e[4]=-r/s,e[5]=t/s,e[12]=(r*o-i*a)/s,e[13]=(n*a-t*o)/s,!0)}function sameValueZero(e,t){return e===t||e!==e&&t!==t}const _s=[`a`,`m11`,`b`,`m12`,`c`,`m21`,`d`,`m22`,`e`,`m41`,`f`,`m42`],vs=[0,1,4,5,12,13],ys=[`m13`,`m14`,`m23`,`m24`,`m31`,`m32`,`m33`,`m34`,`m43`,`m44`],bs=[2,3,6,7,8,9,10,11,14,15];function member(e,t){let n=e[t];return n===void 0?void 0:Number(n)}function matrixFromInit(e,t,n){if(e instanceof DOMMatrixReadOnly)return matrixOf(e);let r=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1,ps];if(e==null)return r;if(typeof e!=`object`&&typeof e!=`function`)throw TypeError(`Failed to execute '${t}' on '${n}': The provided value is not of type 'DOMMatrixInit'.`);for(let i=0;i<12;i+=2){let a=member(e,_s[i]),o=member(e,_s[i+1]);if(a!==void 0&&o!==void 0&&!sameValueZero(a,o))throw TypeError(`Failed to execute '${t}' on '${n}': The '${_s[i]}' property should equal the '${_s[i+1]}' property.`);let s=o??a;s!==void 0&&(r[vs[i>>1]]=s)}let i=!1;for(let t=0;t<10;t++){let n=bs[t],a=+(n===10||n===15),o=member(e,ys[t]);r[n]=o??a,o!==void 0&&o!==a&&(i=!0)}let a=e.is2D;if(a===void 0)return i&&(r[16]=ms),r;if(a&&i)throw TypeError(`Failed to execute '${t}' on '${n}': The is2D member is set to true but the input matrix is a 3d matrix.`);return a||(r[16]=ms),r}const xs={px:1,cm:96/2.54,mm:96/25.4,q:96/101.6,in:96,pt:4/3,pc:16},Ss={deg:1,rad:180/Math.PI,grad:.9,turn:360},Cs=Array.prototype[Symbol.iterator],ws=Object.getPrototypeOf(Int8Array.prototype)[Symbol.iterator],Ts=/^([+-]?(?:\d+(?:\.\d+)?|\.\d+)(?:e[+-]?\d+)?)([a-z%]*)$/,Es=/[+-]?(?:\d+(?:\.\d+)?|\.\d+)(?:e[+-]?\d+)?([a-z]+|%)?/y,Ds=/\/\*[\s\S]*?(?:\*\/|$)/g,Os=/[A-Z]+/g,ks=[],As=[],js=[];function argNumber(e){return As[e]===``?ks[e]:null}function argNumberOrPercent(e){let t=As[e];return t===``?ks[e]:t===`%`?ks[e]/100:null}function argLength(e){let t=As[e];return t===``?ks[e]===0&&!js[e]?0:null:t in xs?ks[e]*xs[t]:null}function argAngle(e){let t=As[e];return t===``?ks[e]===0&&!js[e]?0:null:t in Ss?ks[e]*Ss[t]:null}function isCssWhitespace$1(e){return e===32||e===9||e===10||e===13||e===12}__name(isCssWhitespace$1,`isCssWhitespace`);function trimCss(e){let t=0,n=e.length;for(;t<n&&isCssWhitespace$1(e.charCodeAt(t));)t++;for(;n>t&&isCssWhitespace$1(e.charCodeAt(n-1));)n--;return t===0&&n===e.length?e:e.slice(t,n)}const Ms=[``,`px`,`deg`,`%`];let Ns=``,Ps=0,Fs=0;function calcSkipWhitespace(){let e=Ps;for(;Ps<Ns.length&&isCssWhitespace$1(Ns.charCodeAt(Ps));)Ps++;return Ps!==e}function calcValue(){if(Ns.startsWith(`calc(`,Ps))Ps+=5;else if(Ns.charCodeAt(Ps)===40)Ps++;else{Es.lastIndex=Ps;let e=Es.exec(Ns);if(e===null)return null;Ps=Es.lastIndex;let t=e[1],n=Number(t===void 0?e[0]:e[0].slice(0,-t.length));if(t===void 0)Fs=0;else if(t===`%`)Fs=3;else if(t in xs)return Fs=1,n*xs[t];else if(t in Ss)return Fs=2,n*Ss[t];else return null;return n}calcSkipWhitespace();let e=calcSum();return calcSkipWhitespace(),e===null||Ns.charCodeAt(Ps)!==41?null:(Ps++,e)}function calcProduct(){let e=calcValue();if(e===null)return null;let t=Fs;for(;;){let n=Ps;calcSkipWhitespace();let r=Ns.charCodeAt(Ps);if(r!==42&&r!==47)return Ps=n,Fs=t,e;Ps++,calcSkipWhitespace();let i=calcValue();if(i===null)return null;if(r===42){if(t!==0&&Fs!==0)return null;t===0&&(t=Fs),e*=i}else{if(Fs!==0)return null;e/=i}}}function calcSum(){let e=calcProduct();if(e===null)return null;let t=Fs;for(;;){let n=Ps,r=calcSkipWhitespace()?Ns.charCodeAt(Ps):0;if(r!==43&&r!==45||!isCssWhitespace$1(Ns.charCodeAt(Ps+1)))return Ps=n,Fs=t,e;Ps++,calcSkipWhitespace();let i=calcProduct();if(i===null||Fs!==t)return null;e=r===43?e+i:e-i}}function pushCalcArg(e){Ns=e,Ps=0;let t=calcValue();return t===null||Ps!==e.length?!1:(ks.push(t),As.push(Ms[Fs]),js.push(!0),!0)}function parseArgs(e){if(ks.length=0,As.length=0,js.length=0,trimCss(e)===``)return!0;let t=0,n=0;for(let r=0;r<=e.length;r++){let i=r===e.length?44:e.charCodeAt(r);if(i===40)n++;else if(i===41)n--;else if(i===44&&n===0){let n=trimCss(e.slice(t,r));t=r+1;let i=Ts.exec(n);if(i!==null)ks.push(Number(i[1])),As.push(i[2]),js.push(!1);else if(n===`none`)ks.push(NaN),As.push(`none`),js.push(!1);else if(!n.startsWith(`calc(`)||!pushCalcArg(n))return!1}}return!0}function argsAll(e,t){if(ks.length!==t)return null;let n=[];for(let r=0;r<t;r++){let t=e(r);if(t===null)return null;n.push(t)}return n}function parseTransformList(e){let t=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1,ps];if(e===``)return t;let n=e.includes(`/*`)?e.replace(Ds,` `):e;if(n=trimCss(n.replace(Os,e=>e.toLowerCase())),n===`none`)return t;if(n===``)return null;let r=n.length,i=0;for(;i<r;){let e=i;for(let e=n.charCodeAt(i);e>=97&&e<=122||e>=48&&e<=57||e===45;)e=n.charCodeAt(++i);if(i===e||n.charCodeAt(i)!==40)return null;let a=n.slice(e,i),o=++i;for(let e=0;;i++){if(i===r)return null;let t=n.charCodeAt(i);if(t===40)e++;else if(t===41&&e--===0)break}let s=n.slice(o,i++);for(;i<r&&isCssWhitespace$1(n.charCodeAt(i));)i++;if(!parseArgs(s))return null;let c=ks.length,l=null,u=!1;switch(a){case`matrix`:{let e=argsAll(argNumber,6);e!==null&&(l=set16(gs,e[0],e[1],0,0,e[2],e[3],0,0,0,0,1,0,e[4],e[5],0,1));break}case`matrix3d`:{let e=argsAll(argNumber,16);e!==null&&(l=set16(gs,e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15])),u=!0;break}case`translate`:{let e=c===1?argsAll(argLength,1):argsAll(argLength,2);e!==null&&(l=set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,e[0],e[1]??0,0,1));break}case`translatex`:{let e=argsAll(argLength,1);e!==null&&(l=set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,e[0],0,0,1));break}case`translatey`:{let e=argsAll(argLength,1);e!==null&&(l=set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,0,e[0],0,1));break}case`translatez`:{let e=argsAll(argLength,1);e!==null&&(l=set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,0,0,e[0],1)),u=!0;break}case`translate3d`:{let e=argsAll(argLength,3);e!==null&&(l=set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,e[0],e[1],e[2],1)),u=!0;break}case`scale`:{let e=c===1?argsAll(argNumberOrPercent,1):argsAll(argNumberOrPercent,2);e!==null&&(l=set16(gs,e[0],0,0,0,0,e[1]??e[0],0,0,0,0,1,0,0,0,0,1));break}case`scalex`:{let e=argsAll(argNumberOrPercent,1);e!==null&&(l=set16(gs,e[0],0,0,0,0,1,0,0,0,0,1,0,0,0,0,1));break}case`scaley`:{let e=argsAll(argNumberOrPercent,1);e!==null&&(l=set16(gs,1,0,0,0,0,e[0],0,0,0,0,1,0,0,0,0,1));break}case`scalez`:{let e=argsAll(argNumberOrPercent,1);e!==null&&(l=set16(gs,1,0,0,0,0,1,0,0,0,0,e[0],0,0,0,0,1)),u=!0;break}case`scale3d`:{let e=argsAll(argNumberOrPercent,3);e!==null&&(l=set16(gs,e[0],0,0,0,0,e[1],0,0,0,0,e[2],0,0,0,0,1)),u=!0;break}case`rotate`:case`rotatez`:{let e=argsAll(argAngle,1);e!==null&&(l=rotation(0,0,1,e[0])),u=a===`rotatez`;break}case`rotatex`:{let e=argsAll(argAngle,1);e!==null&&(l=rotation(1,0,0,e[0])),u=!0;break}case`rotatey`:{let e=argsAll(argAngle,1);e!==null&&(l=rotation(0,1,0,e[0])),u=!0;break}case`rotate3d`:{let e=argNumber(0),t=argNumber(1),n=argNumber(2),r=c===4?argAngle(3):null;e!==null&&t!==null&&n!==null&&r!==null&&(l=rotation(e,t,n,r)),u=!0;break}case`skew`:{let e=c===1?argsAll(argAngle,1):argsAll(argAngle,2);e!==null&&(l=skewing(e[0],e[1]??0));break}case`skewx`:{let e=argsAll(argAngle,1);e!==null&&(l=skewing(e[0],0));break}case`skewy`:{let e=argsAll(argAngle,1);e!==null&&(l=skewing(0,e[0]));break}case`perspective`:if(c===1&&As[0]===`none`)l=set16(gs,1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1);else{let e=argsAll(argLength,1);e!==null&&e[0]>=0&&(l=set16(gs,1,0,0,0,0,1,0,0,0,0,1,-1/Math.max(e[0],1),0,0,0,1))}u=!0}if(l===null)return null;u&&(t[16]=ms),multiplyInto(t,t,l)}return t}var DOMMatrixReadOnly=class{#e;static{matrixOf=e=>e.#e}constructor(e){if(e===void 0){let e=hs;e===null?this.#e=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1,ps]:(hs=null,this.#e=e)}else if(typeof e==`string`){let t=parseTransformList(e);if(t===null)throw new DOMException(`Failed to construct '${new.target===Is?`DOMMatrix`:`DOMMatrixReadOnly`}': Failed to parse '${e}'.`,`SyntaxError`);this.#e=t}else if(typeof e==`object`&&e&&(Array.isArray(e)||ArrayBuffer.isView(e)||Symbol.iterator in e)){let t=e,n=e[Symbol.iterator];if((t.length!==6&&t.length!==16||!(n===Cs&&Array.isArray(e)||n===ws&&ArrayBuffer.isView(e)))&&(t=Array.from(e,Number)),t.length===6)this.#e=[Number(t[0]),Number(t[1]),0,0,Number(t[2]),Number(t[3]),0,0,0,0,1,0,Number(t[4]),Number(t[5]),0,1,ps];else if(t.length===16)this.#e=[Number(t[0]),Number(t[1]),Number(t[2]),Number(t[3]),Number(t[4]),Number(t[5]),Number(t[6]),Number(t[7]),Number(t[8]),Number(t[9]),Number(t[10]),Number(t[11]),Number(t[12]),Number(t[13]),Number(t[14]),Number(t[15]),ms];else throw TypeError(`Failed to construct '${new.target===Is?`DOMMatrix`:`DOMMatrixReadOnly`}': The sequence must contain 6 elements for a 2D matrix or 16 elements for a 3D matrix.`)}else{let t=String(e),n=parseTransformList(t);if(n===null)throw new DOMException(`Failed to construct '${new.target===Is?`DOMMatrix`:`DOMMatrixReadOnly`}': Failed to parse '${t}'.`,`SyntaxError`);this.#e=n}}static fromMatrix(e){let t=new this,n=matrixFromInit(e,`fromMatrix`,this.name),r=t.#e;for(let e=0;e<17;e++)r[e]=n[e];return t}static fromFloat32Array(e){return fromArray(this,e,`fromFloat32Array`)}static fromFloat64Array(e){return fromArray(this,e,`fromFloat64Array`)}get a(){return this.#e[0]}get b(){return this.#e[1]}get c(){return this.#e[4]}get d(){return this.#e[5]}get e(){return this.#e[12]}get f(){return this.#e[13]}get m11(){return this.#e[0]}get m12(){return this.#e[1]}get m13(){return this.#e[2]}get m14(){return this.#e[3]}get m21(){return this.#e[4]}get m22(){return this.#e[5]}get m23(){return this.#e[6]}get m24(){return this.#e[7]}get m31(){return this.#e[8]}get m32(){return this.#e[9]}get m33(){return this.#e[10]}get m34(){return this.#e[11]}get m41(){return this.#e[12]}get m42(){return this.#e[13]}get m43(){return this.#e[14]}get m44(){return this.#e[15]}get is2D(){return this.#e[16]===ps}get isIdentity(){let e=this.#e;for(let t=0;t<16;t++)if(e[t]!==ds[t])return!1;return!0}translate(e,t,n){return copyOf(this).translateSelf(e,t,n)}scale(e,t,n,r,i,a){return copyOf(this).scaleSelf(e,t,n,r,i,a)}scaleNonUniform(e=1,t=1){return copyOf(this).scaleSelf(e,t,1,0,0,0)}scale3d(e,t,n,r){return copyOf(this).scale3dSelf(e,t,n,r)}rotate(e,t,n){return copyOf(this).rotateSelf(e,t,n)}rotateFromVector(e,t){return copyOf(this).rotateFromVectorSelf(e,t)}rotateAxisAngle(e,t,n,r){return copyOf(this).rotateAxisAngleSelf(e,t,n,r)}skewX(e){return copyOf(this).skewXSelf(e)}skewY(e){return copyOf(this).skewYSelf(e)}multiply(e){let t=copyOf(this),n=matrixFromInit(e,`multiply`,`DOMMatrixReadOnly`),r=matrixOf(t);return multiplyInto(r,r,n),n[16]!==ps&&(r[16]=ms),t}flipX(){let e=copyOf(this);return scaleBy(matrixOf(e),-1,1,1),e}flipY(){let e=copyOf(this);return scaleBy(matrixOf(e),1,-1,1),e}inverse(){return copyOf(this).invertSelf()}transformPoint(e={}){let t=e.x,n=e.y,r=e.z,i=e.w,a=t===void 0?0:Number(t),o=n===void 0?0:Number(n),s=r===void 0?0:Number(r),c=i===void 0?1:Number(i),l=this.#e;return new ls(l[0]*a+l[4]*o+l[8]*s+l[12]*c,l[1]*a+l[5]*o+l[9]*s+l[13]*c,l[2]*a+l[6]*o+l[10]*s+l[14]*c,l[3]*a+l[7]*o+l[11]*s+l[15]*c)}toFloat32Array(){let e=this.#e,t=/* @__PURE__ */ new Float32Array(16);for(let n=0;n<16;n++)t[n]=e[n];return t}toFloat64Array(){let e=this.#e,t=/* @__PURE__ */ new Float64Array(16);for(let n=0;n<16;n++)t[n]=e[n];return t}toJSON(){let e=this.#e;return{a:e[0],b:e[1],c:e[4],d:e[5],e:e[12],f:e[13],m11:e[0],m12:e[1],m13:e[2],m14:e[3],m21:e[4],m22:e[5],m23:e[6],m24:e[7],m31:e[8],m32:e[9],m33:e[10],m34:e[11],m41:e[12],m42:e[13],m43:e[14],m44:e[15],is2D:e[16]===ps,isIdentity:this.isIdentity}}toString(){let e=this.#e;for(let t=0;t<16;t++)if(!Number.isFinite(e[t]))throw new DOMException(`Failed to execute 'toString' on '${this instanceof Is?`DOMMatrix`:`DOMMatrixReadOnly`}': Cannot be serialized with NaN or Infinity values.`,`InvalidStateError`);return e[16]===ps?`matrix(${e[0]}, ${e[1]}, ${e[4]}, ${e[5]}, ${e[12]}, ${e[13]})`:`matrix3d(${e[0]}, ${e[1]}, ${e[2]}, ${e[3]}, ${e[4]}, ${e[5]}, ${e[6]}, ${e[7]}, ${e[8]}, ${e[9]}, ${e[10]}, ${e[11]}, ${e[12]}, ${e[13]}, ${e[14]}, ${e[15]})`}};function fromArray(e,t,n){if(t.length!==6&&t.length!==16)throw TypeError(`Failed to execute '${n}' on '${e.name}': The sequence must contain 6 elements for a 2D matrix or 16 elements for a 3D matrix.`);return new e(t)}var Is=class DOMMatrix extends DOMMatrixReadOnly{static fromMatrix(e){return DOMMatrixReadOnly.fromMatrix.call(DOMMatrix,e)}static fromFloat32Array(e){return fromArray(DOMMatrix,e,`fromFloat32Array`)}static fromFloat64Array(e){return fromArray(DOMMatrix,e,`fromFloat64Array`)}get a(){return matrixOf(this)[0]}set a(e){matrixOf(this)[0]=Number(e)}get b(){return matrixOf(this)[1]}set b(e){matrixOf(this)[1]=Number(e)}get c(){return matrixOf(this)[4]}set c(e){matrixOf(this)[4]=Number(e)}get d(){return matrixOf(this)[5]}set d(e){matrixOf(this)[5]=Number(e)}get e(){return matrixOf(this)[12]}set e(e){matrixOf(this)[12]=Number(e)}get f(){return matrixOf(this)[13]}set f(e){matrixOf(this)[13]=Number(e)}get m11(){return matrixOf(this)[0]}set m11(e){matrixOf(this)[0]=Number(e)}get m12(){return matrixOf(this)[1]}set m12(e){matrixOf(this)[1]=Number(e)}get m13(){return matrixOf(this)[2]}set m13(e){set3D(this,2,e,0)}get m14(){return matrixOf(this)[3]}set m14(e){set3D(this,3,e,0)}get m21(){return matrixOf(this)[4]}set m21(e){matrixOf(this)[4]=Number(e)}get m22(){return matrixOf(this)[5]}set m22(e){matrixOf(this)[5]=Number(e)}get m23(){return matrixOf(this)[6]}set m23(e){set3D(this,6,e,0)}get m24(){return matrixOf(this)[7]}set m24(e){set3D(this,7,e,0)}get m31(){return matrixOf(this)[8]}set m31(e){set3D(this,8,e,0)}get m32(){return matrixOf(this)[9]}set m32(e){set3D(this,9,e,0)}get m33(){return matrixOf(this)[10]}set m33(e){set3D(this,10,e,1)}get m34(){return matrixOf(this)[11]}set m34(e){set3D(this,11,e,0)}get m41(){return matrixOf(this)[12]}set m41(e){matrixOf(this)[12]=Number(e)}get m42(){return matrixOf(this)[13]}set m42(e){matrixOf(this)[13]=Number(e)}get m43(){return matrixOf(this)[14]}set m43(e){set3D(this,14,e,0)}get m44(){return matrixOf(this)[15]}set m44(e){set3D(this,15,e,1)}multiplySelf(e){let t=matrixFromInit(e,`multiplySelf`,`DOMMatrix`),n=matrixOf(this);return multiplyInto(n,n,t),t[16]!==ps&&(n[16]=ms),this}preMultiplySelf(e){let t=matrixFromInit(e,`preMultiplySelf`,`DOMMatrix`),n=matrixOf(this);return multiplyInto(n,t,n),t[16]!==ps&&(n[16]=ms),this}translateSelf(e=0,t=0,n=0){n=Number(n),e=Number(e),t=Number(t);let r=matrixOf(this);return translateBy(r,e,t,n),n!==0&&(r[16]=ms),this}scaleSelf(e=1,t,n=1,r=0,i=0,a=0){e=Number(e),n=Number(n),r=Number(r),i=Number(i),a=Number(a);let o=matrixOf(this);return translateOrigin(o,r,i,a),scaleBy(o,e,t===void 0?e:Number(t),n),translateOrigin(o,-r,-i,-a),n!==1&&(o[16]=ms),this}scale3dSelf(e=1,t=0,n=0,r=0){e=Number(e),t=Number(t),n=Number(n),r=Number(r);let i=matrixOf(this);return translateOrigin(i,t,n,r),scaleBy(i,e,e,e),translateOrigin(i,-t,-n,-r),e!==1&&(i[16]=ms),this}rotateSelf(e=0,t,n){e=Number(e),t===void 0&&n===void 0&&(n=e,e=0,t=0),t=t===void 0?0:Number(t),n=n===void 0?0:Number(n);let r=matrixOf(this);return(e!==0||t!==0)&&(r[16]=ms),rotateEuler(r,e,t,n),this}rotateFromVectorSelf(e=0,t=0){e=Number(e),t=Number(t);let n=e===0&&t===0?0:Math.atan2(t,e)/fs;return rotateBy(matrixOf(this),0,0,1,n),this}rotateAxisAngleSelf(e=0,t=0,n=0,r=0){e=Number(e),t=Number(t),n=Number(n),r=Number(r);let i=matrixOf(this);return rotateBy(i,e,t,n,r),(e!==0||t!==0)&&(i[16]=ms),this}skewXSelf(e=0){return e=Number(e),skewBy(matrixOf(this),e,0),this}skewYSelf(e=0){return e=Number(e),skewBy(matrixOf(this),0,e),this}invertSelf(){let e=matrixOf(this);if(e[16]===ps?!invert2D(e):!invert(e)){for(let t=0;t<16;t++)e[t]=NaN;e[16]=ms}return this}setMatrixValue(e){let t=parseTransformList(String(e));if(t===null)throw new DOMException(`Failed to execute 'setMatrixValue' on 'DOMMatrix': Failed to parse '${String(e)}'.`,`SyntaxError`);let n=matrixOf(this);for(let e=0;e<17;e++)n[e]=t[e];return this}};function translateOrigin(e,t,n,r){(t!==0||n!==0||r!==0)&&(translateBy(e,t,n,r),r!==0&&(e[16]=ms))}function set3D(e,t,n,r){let i=Number(n),a=matrixOf(e);a[t]=i,i!==r&&(a[16]=ms)}exposeMembers(DOMPointReadOnly,ls,DOMRectReadOnly,us,DOMRectList,DOMMatrixReadOnly,Is);const Ls={setMatrixValue:1,fromFloat32Array:1,fromFloat64Array:1,item:1};for(let e of[DOMPointReadOnly,ls,DOMRectReadOnly,us,DOMRectList,DOMMatrixReadOnly,Is])defineInterfaceShape(e,Ls);function isPotentialCustomElementName(e){let t=e.charCodeAt(0);return t>=97&&t<=122&&e.includes(`-`)}var Rs=class Element extends Node{constructor(e,t,n,r){super(1,e);let i=this[z];i.name=t,i.ns=n,i.prefix=r,n===`http://www.w3.org/1999/xhtml`&&(e[Nn]&&(i.flags|=2),i.tag=tagId(t),i.tag===0&&isPotentialCustomElementName(t)&&(i.flags|=128))}get namespaceURI(){return this[z].ns}get prefix(){return this[z].prefix}get localName(){return this[z].name}get tagName(){return htmlUppercasedQualifiedName(this[z])}get id(){return this[z].id}set id(e){setAttributeValue(this[z],`id`,String(e))}get className(){return getAttribute(this[z],`class`)??``}set className(e){setAttributeValue(this[z],`class`,String(e))}get classList(){return this[ut]??=new Qo(this[z],`class`)}set classList(e){this.classList.value=e}get dataset(){return this[Mt]??=createDOMStringMap(this[z])}get part(){let e=zs.get(this);return e===void 0&&zs.set(this,e=new Qo(this[z],`part`)),e}set part(e){this.part.value=e}get attributes(){return this[Je]??=new is(this[z])}get slot(){return attr(this[z],`slot`)??``}set slot(e){setAttributeValue(this[z],`slot`,String(e))}hasAttributes(){let e=this[z].attrs;return e!==null&&e.length!==0}getAttributeNames(){let e=this[z].attrs;return e===null?[]:e.map(e=>e.name)}getAttribute(e){return getAttribute(this[z],String(e))}getAttributeNS(e,t){let n=findAttributeByNamespace(this[z],e===``||e===void 0?null:e,String(t));return n===null?null:n.value}setAttribute(e,t){setAttribute(this[z],String(e),String(t))}setAttributeNS(e,t,n){let{namespace:r,prefix:i,localName:a}=validateAndExtract(e===void 0?null:e,String(t),`attribute`),o=this[z],s=String(n),c=findAttributeByNamespace(o,r,a);c===null?appendAttribute(o,new AttrRecord(a,s,r,i)):changeAttribute(o,c,s)}getAttributeNode(e){let t=this[z],n=String(e),r=findAttributeByName(t,t.flags&2?asciiLowercase$1(n):n);return r===null?null:attrNode(t,r)}getAttributeNodeNS(e,t){let n=this[z],r=findAttributeByNamespace(n,e===``||e===void 0?null:e,String(t));return r===null?null:attrNode(n,r)}setAttributeNode(e){return setAttributeNode(this[z],e)}setAttributeNodeNS(e){return setAttributeNode(this[z],e)}removeAttributeNode(e){return removeAttributeNode(this[z],e)}removeAttribute(e){removeAttribute(this[z],String(e))}removeAttributeNS(e,t){let n=findAttributeByNamespace(this[z],e===``||e===void 0?null:e,String(t));n!==null&&removeAttributeRecord(this[z],n)}toggleAttribute(e,t){let n=this[z],r=String(e);if(!isValidAttributeLocalName(r))throw new DOMException(`"${r}" is not a valid attribute name.`,`InvalidCharacterError`);let i=n.flags&2?asciiLowercase$1(r):r,a=findAttributeByName(n,i);return a===null?t===void 0||t?(appendAttribute(n,new AttrRecord(i,``,null,null)),!0):!1:t===void 0||!t?(removeAttributeRecord(n,a),!1):!0}hasAttribute(e){return getAttribute(this[z],String(e))!==null}hasAttributeNS(e,t){return findAttributeByNamespace(this[z],e===``||e===void 0?null:e,String(t))!==null}matches(e){return matches(this[z],String(e))}webkitMatchesSelector(e){return this.matches(e)}closest(e){let t=closest(this[z],String(e));return t===null?null:t.node}getElementsByTagName(e){return getElementsByTagName(this[z],String(e))}getElementsByTagNameNS(e,t){return getElementsByTagNameNS(this[z],e,String(t))}getElementsByClassName(e){return getElementsByClassName(this[z],String(e))}get innerHTML(){return serializeChildren(this[z])}set innerHTML(e){let t=this[z],n=parseFragment(e===null?``:String(e),t);if(t.tag===Z.template&&t.ns===`http://www.w3.org/1999/xhtml`){let e=this.content;if(e!=null){e._replaceAll(n.node);return}}this._replaceAll(n.node)}getHTML(e){return getHTML(this[z],e)}setHTMLUnsafe(e){setHTMLUnsafe(this[z],String(e))}get outerHTML(){return serializeNode(this[z])}set outerHTML(e){let t=this[z],n=t.parent;if(n===null)return;if(n.type===9)throw new DOMException(`Cannot set outerHTML of the document element.`,`NoModificationAllowedError`);let r=n.type===11?t.doc.createElement(`body`)[z]:n,i=parseFragment(e===null?``:String(e),r);n.node.replaceChild(i.node,this)}insertAdjacentHTML(e,t){let n=asciiLowercase$1(String(e)),r=this[z],i;if(n===`beforebegin`||n===`afterend`){let e=r.parent;if(e===null||e.type===9)throw new DOMException(`The element has no parent.`,`NoModificationAllowedError`);i=e}else if(n===`afterbegin`||n===`beforeend`)i=r;else throw new DOMException(`"${e}" is not a valid position.`,`SyntaxError`);(i.type!==1||i.ns===`http://www.w3.org/1999/xhtml`&&i.name===`html`&&i.flags&2)&&(i=r.doc.createElement(`body`)[z]);let a=parseFragment(String(t),i).node;insertAdjacent(this,n,a)}insertAdjacentElement(e,t){if(!(t instanceof Element))throw TypeError(`Failed to execute 'insertAdjacentElement' on 'Element': parameter 2 is not of type 'Element'.`);return insertAdjacent(this,asciiLowercase$1(String(e)),t)}insertAdjacentText(e,t){insertAdjacent(this,asciiLowercase$1(String(e)),this[z].doc.createTextNode(String(t)))}get shadowRoot(){let e=this[G];return e!=null&&e.mode===`open`?e:null}attachShadow(e){if(typeof e!=`object`||!e)throw TypeError(`Failed to execute 'attachShadow' on 'Element': 1 argument required, but only 0 present.`);let t=e.mode;if(t!==`open`&&t!==`closed`)throw TypeError(`Failed to execute 'attachShadow' on 'Element': The provided value '${String(t)}' is not a valid enum value of type ShadowRootMode.`);let n=e.slotAssignment??`named`;if(n!==`named`&&n!==`manual`)throw TypeError(`Failed to execute 'attachShadow' on 'Element': The provided value '${String(n)}' is not a valid enum value of type SlotAssignmentMode.`);return attachShadowRoot(this,t,!!e.clonable,!!e.serializable,!!e.delegatesFocus,n)}get assignedSlot(){if(Da===0)return null;let e=assignedSlot(this[z]);if(e===null)return null;let t=this[z].parent,n=t===null||!(t.flags&512)?null:t.node[G];return n!=null&&n.mode===`open`?e.node:null}getBoundingClientRect(){return new us}getClientRects(){return new DOMRectList}checkVisibility(e){return!!(this[z].flags&1)}get scrollTop(){return 0}set scrollTop(e){}get scrollLeft(){return 0}set scrollLeft(e){}get scrollWidth(){return 0}get scrollHeight(){return 0}get clientTop(){return 0}get clientLeft(){return 0}get clientWidth(){return 0}get clientHeight(){return 0}scroll(e,t){}scrollTo(e,t){}scrollBy(e,t){}scrollIntoView(e){}_connectedSteps(){}_disconnectedSteps(){}_attributeChangedSteps(e,t,n,r){}_childrenChangedSteps(){}_adoptingSteps(e){}_movingSteps(e,t){}_cloningSteps(e,t){}};installParentNode(Rs),installChildNode(Rs),installNonDocumentTypeChildNode(Rs);function insertAdjacent(e,t,n){switch(t){case`beforebegin`:{let t=e.parentNode;return t===null?null:t.insertBefore(n,e)}case`afterbegin`:return e.insertBefore(n,e.firstChild);case`beforeend`:return e.appendChild(n);case`afterend`:{let t=e.parentNode;return t===null?null:t.insertBefore(n,e.nextSibling)}}throw new DOMException(`"${t}" is not a valid position.`,`SyntaxError`)}const zs=/* @__PURE__ */ new WeakMap,Bs=/* @__PURE__ */ new Set([`article`,`aside`,`blockquote`,`body`,`div`,`footer`,`h1`,`h2`,`h3`,`h4`,`h5`,`h6`,`header`,`main`,`nav`,`p`,`section`,`span`]);let Vs=!1;function attachShadowRoot(e,t,n,r,i,a){let o=e[z];if(o.ns!==`http://www.w3.org/1999/xhtml`)throw new DOMException(`This element does not support attachShadow`,`NotSupportedError`);let s=o.name;if(!(o.flags&128)&&!Bs.has(s))throw new DOMException(`Failed to execute 'attachShadow' on 'Element': This element does not support attachShadow`,`NotSupportedError`);let c=e._shadowDisabled;if(typeof c==`function`&&c.call(e))throw new DOMException(`Failed to execute 'attachShadow' on 'Element': Shadow root cannot be created on a host whose custom element definition disables it.`,`NotSupportedError`);let l=e[G];if(l!=null){if(!l[Nt]||l[qn]!==t)throw new DOMException(`Failed to execute 'attachShadow' on 'Element': Shadow root cannot be created on a host which already hosts a shadow tree.`,`NotSupportedError`);return l._replaceAll(null),l[Nt]=!1,l}let u=new ShadowRoot(o.doc,e,t,i,a,n,r);return e[G]=u,o.flags|=512,_shadowRootAttached(),Vs||(Vs=!0,setAssignedSlotLookup(e=>{let t=assignedSlotForEventPath(e);return t===null?null:t.node})),u}var CollectionEntry=class extends WeakRef{entries;key;constructor(e,t,n){super(e),this.entries=t,this.key=n}};const Hs=/* @__PURE__ */ new WeakMap,Us=new FinalizationRegistry(e=>{e.entries.get(e.key)===e&&e.entries.delete(e.key)});function cachedCollectionFor(e,t){return Hs.get(e)?.get(t)?.deref()}function storeCollection(e,t,n,r){let i=Hs.get(e);i===void 0&&Hs.set(e,i=/* @__PURE__ */ new Map);let a=io._descendants(e,n,r),o=new CollectionEntry(a,i,t);return i.set(t,o),Us.register(a,o),a}const Ws=/* @__PURE__ */ new WeakMap;function cachedCollection(e,t,n,r){let i=Ws.get(e);i===void 0&&Ws.set(e,i=/* @__PURE__ */ new Map);let a=i.get(t);return a===void 0&&i.set(t,a=io._descendants(e,n,r)),a}function getElementsByTagName(e,t){let n=`t`+t,r=cachedCollectionFor(e,n);if(r!==void 0)return r;if(t===`*`)return storeCollection(e,n,!0,null);let i=asciiLowercase$1(t),a=e.doc[Nn],o=t.indexOf(`:`),s=o===-1?null:t.slice(0,o),c=o===-1?t:t.slice(o+1),l=o===-1?null:i.slice(0,o),u=o===-1?i:i.slice(o+1);return storeCollection(e,n,!0,e=>a&&e.ns===`http://www.w3.org/1999/xhtml`?e.name===u&&e.prefix===l:e.name===c&&e.prefix===s)}function getElementsByTagNameNS(e,t,n){let r=t===``||t==null?null:String(t),i=`n`+(r??``)+`\0`+(r===null?`0`:`1`)+n,a=cachedCollectionFor(e,i);return a===void 0?r===`*`&&n===`*`?storeCollection(e,i,!0,null):r===`*`?storeCollection(e,i,!0,e=>e.name===n):n===`*`?storeCollection(e,i,!0,e=>e.ns===r):storeCollection(e,i,!0,e=>e.ns===r&&e.name===n):a}function getElementsByClassName(e,t){let n=e.doc[qn]===`quirks`,r=(n?`q`:`c`)+t,i=cachedCollectionFor(e,r);if(i!==void 0)return i;let a=[];for(let e of splitOnAsciiWhitespace(t))a.includes(e)||a.push(e);if(a.length===0)return cachedCollectionFor(e,`c`)??storeCollection(e,`c`,!0,()=>!1);if(n){let t=a.map(asciiLowercase$1);return storeCollection(e,r,!1,e=>{let n=classTokens(e);outer:for(let e=0;e<t.length;e++){for(let r=0;r<n.length;r++)if(asciiLowercase$1(n[r])===t[e])continue outer;return!1}return!0})}if(a.length===1){let t=a[0];return storeCollection(e,r,!1,e=>{let n=classTokens(e);for(let e=0;e<n.length;e++)if(n[e]===t)return!0;return!1})}return storeCollection(e,r,!1,e=>{let t=classTokens(e);for(let e=0;e<a.length;e++)if(!t.includes(a[e]))return!1;return!0})}const Gs=[`blur`,`error`,`focus`,`load`,`resize`,`scroll`],Ks=[`readystatechange`,`visibilitychange`];var HandlerEntry=class{value;listener;constructor(){this.value=null,this.listener=null}};const qs=/* @__PURE__ */ new WeakMap;function makeProcessingListener(e){return function(t){let n=e.value;if(typeof n!=`function`)return;let r=n,i=t._s,a=i.currentTarget;if(t instanceof ErrorEvent&&i.type===`error`&&isWindow(a)){r.call(a,t.message,t.filename,t.lineno,t.colno,t.error)===!0&&setCanceledFlag(i);return}let o=r.call(a,t);t instanceof BeforeUnloadEvent&&i.type===`beforeunload`?o!=null&&(setCanceledFlag(i),t.returnValue===``&&(t.returnValue=String(o))):o===!1&&setCanceledFlag(i)}}function getEventHandler(e,t){let n=qs.get(e);return n===void 0?null:n.get(t)?.value??null}function setEventHandler(e,t,n){let r=n!==null&&(typeof n==`object`||typeof n==`function`)?n:null,i=qs.get(e);if(r===null){let n=i?.get(t);if(n===void 0)return;n.value=null,n.listener!==null&&(removeEventListener(e,t,n.listener,!1),n.listener=null);return}i===void 0&&qs.set(e,i=/* @__PURE__ */ new Map);let a=i.get(t);a===void 0&&i.set(t,a=new HandlerEntry),a.value=r,a.listener===null&&(a.listener=makeProcessingListener(a),addEventListener(e,t,a.listener,!1))}const Js=/* @__PURE__ */ new Map;function handlerAccessor(e,t){if(t===null){let t=Js.get(e);return t===void 0&&(t={get(){return getEventHandler(this,e)},set(t){setEventHandler(this,e,t)}},Js.set(e,t)),t}return{get(){let n=t(this);return n===null?null:getEventHandler(n,e)},set(n){let r=t(this);r!==null&&setEventHandler(r,e,n)}}}const Ys={webkitanimationend:`webkitAnimationEnd`,webkitanimationiteration:`webkitAnimationIteration`,webkitanimationstart:`webkitAnimationStart`,webkittransitionend:`webkitTransitionEnd`};function addHandler(e,t,n){let{get:r,set:i}=handlerAccessor(Ys[t]??t,n);e[`on`+t]={configurable:!0,enumerable:!0,get:r,set:i}}function bodyWindow(e){let t=e[z];return t===void 0?null:t.doc[Y]}function installEventHandlers(e,t){let n={};if(t===`body`){for(let e of Gs)addHandler(n,e,bodyWindow);for(let e of Ci)addHandler(n,e,bodyWindow)}else{for(let e of Si)addHandler(n,e,null);if(t===`window`)for(let e of Ci)addHandler(n,e,null);if(t===`document`)for(let e of Ks)addHandler(n,e,null)}Object.defineProperties(e,n)}const Xs=Symbol(`already constructed`),Zs=/* @__PURE__ */ new WeakMap,Qs=/* @__PURE__ */ new WeakSet,$s=/* @__PURE__ */ new WeakSet,ec=/* @__PURE__ */ new WeakMap,tc=/* @__PURE__ */ new WeakMap;let nc=0;const rc=/* @__PURE__ */ new Set([`annotation-xml`,`color-profile`,`font-face`,`font-face-src`,`font-face-uri`,`font-face-format`,`font-face-name`,`missing-glyph`]),ic=RegExp(`^[a-z][\\-.0-9_a-z\\u00B7\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u037D\\u037F-\\u1FFF\\u200C\\u200D\\u203F\\u2040\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\u{10000}-\\u{EFFFF}]*$`,`u`);function isValidCustomElementName(e){return e.includes(`-`)&&ic.test(e)&&!rc.has(e)}var CustomElementRegistry=class{[it];[rt];[pi];[Sr];[Y];constructor(e=null){this[it]=/* @__PURE__ */ new Map,this[rt]=/* @__PURE__ */ new Map,this[pi]=/* @__PURE__ */ new Map,this[Sr]=!1,this[Y]=e}define(e,t,n){if(typeof t!=`function`)throw TypeError(`Failed to execute 'define' on 'CustomElementRegistry': parameter 2 is not of type 'Function'.`);if(e=String(e),!isConstructor(t))throw TypeError(`Failed to execute 'define' on 'CustomElementRegistry': The provided value is not a constructor.`);if(!isValidCustomElementName(e))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': "${e}" is not a valid custom element name`,`SyntaxError`);if(this[it].has(e))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': the name "${e}" has already been used with this registry`,`NotSupportedError`);if(this[rt].has(t))throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': this constructor has already been used with this registry`,`NotSupportedError`);let r=e,i=n?.extends;if(i!=null){let e=String(i);if(isValidCustomElementName(e))throw new DOMException(`"${e}" is a valid custom element name and cannot be extended.`,`NotSupportedError`);if(elementClassFor(e,`http://www.w3.org/1999/xhtml`).name===`HTMLUnknownElement`)throw new DOMException(`"${e}" is not a known HTML element and cannot be extended.`,`NotSupportedError`);r=e}if(this[Sr])throw new DOMException(`Failed to execute 'define' on 'CustomElementRegistry': an element definition is already running.`,`NotSupportedError`);this[Sr]=!0;let a=!1,o=!1,s=!1,c=/* @__PURE__ */ new Set,l=null,u=null,d=null,m=null,h=null,_=null,v=null,y=null,b=null;try{let e=t.prototype;if(typeof e!=`object`||!e)throw TypeError(`Failed to execute 'define' on 'CustomElementRegistry': The prototype of the constructor is not an object.`);let n=e,cb=e=>{let t=n[e];if(t===void 0)return null;if(typeof t!=`function`)throw TypeError(`Failed to execute 'define' on 'CustomElementRegistry': The '${e}' callback is not a function.`);return t};if(l=cb(`connectedCallback`),u=cb(`disconnectedCallback`),m=cb(`connectedMoveCallback`),d=cb(`adoptedCallback`),h=cb(`attributeChangedCallback`),h!==null){let e=t.observedAttributes;if(e!==void 0)for(let t of toSequence(e))c.add(String(t))}let r=t.disabledFeatures;if(r!==void 0)for(let e of toSequence(r)){let t=String(e);t===`internals`?o=!0:t===`shadow`&&(s=!0)}a=!!t.formAssociated,a&&(_=cb(`formAssociatedCallback`),v=cb(`formResetCallback`),y=cb(`formDisabledCallback`),b=cb(`formStateRestoreCallback`))}finally{this[Sr]=!1}let x={name:e,localName:r,constructor:t,observedAttributes:c,connectedCallback:l,disconnectedCallback:u,adoptedCallback:d,attributeChangedCallback:h,connectedMoveCallback:m,formAssociatedCallback:_,formResetCallback:v,formDisabledCallback:y,formStateRestoreCallback:b,formAssociated:a,disableInternals:o,disableShadow:s,constructionStack:[],registry:this};this[it].set(e,x),this[rt].set(t,x),ec.set(t,x),nc++,setCEActive();let S=this[Y]?.document;if(S!=null){let e=[];collectCandidates(S[z],x,e);for(let t of e)enqueueUpgrade(t,x);flushReactions()}let C=this[pi].get(e);C!==void 0&&(C.resolve(t),this[pi].delete(e))}get(e){return this[it].get(String(e))?.constructor}getName(e){if(typeof e!=`function`)throw TypeError(`Failed to execute 'getName' on 'CustomElementRegistry': parameter 1 is not of type 'Function'.`);return this[rt].get(e)?.name??null}whenDefined(e){if(e=String(e),!isValidCustomElementName(e))return Promise.reject(new DOMException(`"${e}" is not a valid custom element name`,`SyntaxError`));let t=this[it].get(e);if(t!==void 0)return Promise.resolve(t.constructor);let n=this[pi].get(e);if(n===void 0){let{promise:t,resolve:r}=Promise.withResolvers();n={promise:t,resolve:r},this[pi].set(e,n)}return n.promise}upgrade(e){let t=[];forEachShadowIncludingInclusiveDescendant(e[z],e=>{e.type===1&&t.push(e.node)});for(let e of t)tryToUpgrade(e);flushReactions()}_lookup(e,t,n){if(e!==`http://www.w3.org/1999/xhtml`)return null;let r=this[it].get(t);if(r!==void 0&&r.localName===t)return r;if(n!==null){let e=this[it].get(n);if(e!==void 0&&e.localName===t)return e}return null}};const ac={construct:()=>({})};function isConstructor(e){try{return new new Proxy(e,ac),!0}catch{return!1}}function toSequence(e){if(e===null||typeof e!=`object`&&typeof e!=`function`||typeof e[Symbol.iterator]!=`function`)throw TypeError(`The value provided is not iterable.`);return Array.from(e)}function forEachShadowIncludingInclusiveDescendant(e,t){for(let n=e;n!==null;n=nextInTree(n,e))if(t(n),n.type===1){let e=n.node[G];e!=null&&forEachShadowIncludingInclusiveDescendant(e[z],t)}}function collectCandidates(e,t,n){forEachShadowIncludingInclusiveDescendant(e,e=>{if(e.type!==1||e.ns!==`http://www.w3.org/1999/xhtml`||e.name!==t.localName)return;let r=e.node;(t.localName===t.name||tc.get(r)===t.name)&&n.push(r)})}const oc=/* @__PURE__ */ new WeakMap;function customElementRegistryFor(e){let t=oc.get(e);return t===void 0&&(t=new CustomElementRegistry(e),oc.set(e,t)),t}function lookupDefinition(e,t,n,r){if(nc===0||t!==`http://www.w3.org/1999/xhtml`)return null;let i=e[Y];if(i===null)return null;let a=oc.get(i);return a===void 0?null:a._lookup(t,n,r)}function isDefined(e){return e.flags&1024?!0:e.flags&128?!isValidCustomElementName(e.name):sc===0||!tc.has(e.node)}function definitionOf(e){return Zs.get(e)}function isValueOf(e){return tc.get(e)??null}let sc=0;function setIsValue(e,t){tc.has(e)||sc++,tc.set(e,t),setCEActive()}function isPrecustomizedOrCustom(e){return!!(e[z].flags&1024)||$s.has(e)}let cc=null;function htmlElementConstructorSteps(e){let t;try{t=oc.get(currentWindow())}catch{t=void 0}let n=t?.[rt].get(e)??ec.get(e);if(n===void 0||isBuiltinInterface(e))throw TypeError(`Illegal constructor`);let r=null;for(let t=Object.getPrototypeOf(e);t!==null&&t!==Function.prototype;t=Object.getPrototypeOf(t))if(isBuiltinInterface(t)){r=t;break}if(n.localName===n.name){if(r!==null&&r.name!==`HTMLElement`)throw TypeError(`Illegal constructor: autonomous custom elements must extend HTMLElement`)}else if(r!==null&&!usesInterface(r,n.localName))throw TypeError(`Illegal constructor: the custom element does not extend the interface of its local name`);let i=n.constructionStack;if(i.length===0)return{upgrade:null,doc:cc??n.registry[Y]?.document??currentWindow().document,localName:n.localName,def:n,active:r};let a=i[i.length-1];if(a===Xs)throw TypeError(`Failed to construct custom element: this element was already constructed`);let o=e.prototype;return typeof o==`object`&&o||(o=(r??elementClassFor(`x-x`,`http://www.w3.org/1999/xhtml`)).prototype),Object.setPrototypeOf(a,o),i[i.length-1]=Xs,{upgrade:a,doc:null,localName:``,def:null,active:null}}function usesInterface(e,t){return localNamesForInterface(e).includes(t)?!0:e.name===`HTMLElement`&&elementClassFor(t,`http://www.w3.org/1999/xhtml`).name===`HTMLElement`}function initNewCustomElement(e,t,n){let r=Object.getPrototypeOf(e);r!==null&&Object.getPrototypeOf(r)===null&&Object.hasOwn(r,`isPrototypeOf`)&&r.constructor?.prototype===r&&Object.setPrototypeOf(e,(n??elementClassFor(`x-x`,`http://www.w3.org/1999/xhtml`)).prototype),markCustom(e,t),t.localName!==t.name&&setIsValue(e,t.name)}function markCustom(e,t){let n=e[z];Zs.set(e,t),n.flags|=1028,t.formAssociated&&(n.flags|=16392),t.attributeChangedCallback!==null&&t.observedAttributes.size!==0&&(n.flags|=8),t.adoptedCallback!==null&&(n.flags|=me)}function createElementSync(e,t,n,r,i){if(nc===0&&i===null)return null;let a=lookupDefinition(e,n,t,i);if(a!==null&&a.name!==a.localName){let i=createElementImpl(e,t,n,r),o=i.node;setIsValue(o,a.name),i.flags|=4;try{upgrade(o,a)}catch(e){reportException(e)}return i}if(a!==null){let i=a.constructor,o=cc;cc=e;try{let n=new i;if(typeof n!=`object`||!n||!(n instanceof elementClassFor(`x-x`,`http://www.w3.org/1999/xhtml`)))throw TypeError(`The custom element constructor did not produce an HTMLElement.`);let a=n[z];if(a.attrs!==null&&a.attrs.length!==0)throw new DOMException(`The result must not have attributes`,`NotSupportedError`);if(a.first!==null)throw new DOMException(`The result must not have children`,`NotSupportedError`);if(a.parent!==null)throw new DOMException(`The result must not have a parent`,`NotSupportedError`);if(a.doc!==e)throw new DOMException(`The result must be in the same document`,`NotSupportedError`);if(a.name!==t)throw new DOMException(`The result must have the same localName`,`NotSupportedError`);return a.prefix=r,a}catch(i){return reportException(i),failedElement(e,t,n,r)}finally{cc=o}}let o=createElementImpl(e,t,n,r);return i!==null&&n===`http://www.w3.org/1999/xhtml`&&(setIsValue(o.node,i),o.flags|=4),o}function failedElement(e,t,n,r){let i=new(elementClassFor(`applet`,E))(e,t,n,r),a=i[z];return a.flags&=-5,Qs.add(i),a}function createElementUnsync(e,t,n,r,i){let a=createElementImpl(e,t,n,r);return n===`http://www.w3.org/1999/xhtml`&&initUnsync(a,i),a}function initUnsync(e,t){let n=e.node,r=lookupDefinition(e.doc,E,e.name,t);r===null?t!==null&&(setIsValue(n,t),e.flags|=4):(r.name!==r.localName&&setIsValue(n,r.name),e.flags|=4,enqueueUpgrade(n,r))}function cloneElement(e,t){return createElementUnsync(e,t.name,t.ns,t.prefix,t.ns===`http://www.w3.org/1999/xhtml`?tc.get(t.node)??null:null)}function parserCreated(e){lc=!0;try{initUnsync(e,e.attrs===null?null:attr(e,`is`))}finally{lc=!1}}let lc=!1,uc=[];function releaseDeferred(e){let t=null,n=null;for(let r=0;r<uc.length;r++){let i=uc[r],a=i[z];for(;a.parent!==null;)a=a.parent;!e&&a.type===11&&!(a.flags&32)?(n??=[]).push(i):(t??=[]).push(i)}uc=n??[],t!==null&&(mc=mc.length===0?t:t.concat(mc))}setCustomElementCreate(createElementSync),setShadowHostCustomStateCheck(isPrecustomizedOrCustom),setCustomElementCloneHooks(cloneElement,parserCreated);let dc=null;function setFaceUpgradeHook(e){dc=e}function upgrade(e,t){let n=e[z];if(n.flags&1024||Qs.has(e)||$s.has(e))return;Zs.set(e,t),Qs.add(e);let r=pc.get(e);r===void 0&&pc.set(e,r=[]);let i=n.attrs;if(i!==null&&t.attributeChangedCallback!==null)for(let e=0;e<i.length;e++){let n=i[e];t.observedAttributes.has(n.localName)&&r.push({kind:fc,def:t,fn:t.attributeChangedCallback,args:[n.localName,null,n.value,n.ns]})}n.flags&1&&t.connectedCallback!==null&&r.push({kind:fc,def:t,fn:t.connectedCallback,args:[]}),t.constructionStack.push(e);try{if(t.disableShadow&&e[G]!=null)throw new DOMException(`Failed to upgrade the custom element: its definition disables shadow roots, but it already has one.`,`NotSupportedError`);$s.add(e);let r=t.constructor,i=new r;if(i!==e){if(typeof i!=`object`||!i||i[z]!==n)throw TypeError(`Custom element constructors must call super() first and must not return a different object.`);n.node=e}}catch(t){Zs.delete(e);let n=pc.get(e);throw n!==void 0&&(n.length=0),t}finally{$s.delete(e),t.constructionStack.pop()}Qs.delete(e),markCustom(e,t),t.formAssociated&&(n.doc[tn]++,n.doc[nn]++,n.doc[J]++,dc!==null&&dc(n))}function tryToUpgrade(e){let t=e[z];if(t.flags&1024||Qs.has(e))return;let n=lookupDefinition(t.doc,t.ns,t.name,tc.get(e)??null);n!==null&&enqueueUpgrade(e,n)}const fc=1,pc=/* @__PURE__ */ new WeakMap;let mc=[],hc=!1;function pushReaction(e,t){let n=pc.get(e);n===void 0&&(n=[],pc.set(e,n)),n.push(t),lc?uc.push(e):mc.push(e),setCEReactionsPending(!0),hc||(hc=!0,queueMicrotask(backupFlush))}let gc=0;function outsideCEReactions(e){gc++;try{return e()}finally{gc--}}function backupFlush(){hc=!1,uc.length!==0&&releaseDeferred(!0),flushReactions()}function enqueueUpgrade(e,t){pushReaction(e,{kind:0,def:t,fn:null,args:[]})}function enqueueCallback(e,t,n){let r=Zs.get(e);if(r===void 0)return;let i=r[t];i!==null&&(t!==`attributeChangedCallback`||r.observedAttributes.has(n[0]))&&pushReaction(e,{kind:1,def:r,fn:i,args:n})}function enqueueFormCallback(e,t,n){let r=Zs.get(e);if(r===void 0)return;let i=r[t];i!==null&&pushReaction(e,{kind:1,def:r,fn:i,args:n})}function flushReactions(){if(gc===0){for(uc.length!==0&&releaseDeferred(!1);mc.length!==0;){let e=mc;mc=[];for(let t=0;t<e.length;t++){let n=e[t],r=pc.get(n);for(;r.length!==0;){let e=r.shift();try{e.kind===0?upgrade(n,e.def):e.fn.apply(n,e.args)}catch(e){reportException(e)}}}}setCEReactionsPending(uc.length!==0)}}setCEReactionsFlush(flushReactions);function reportException(e,t=null){reportException$1(e,t)}function ceConnected(e){nc!==0&&(e[z].flags&1024?enqueueCallback(e,`connectedCallback`,[]):tryToUpgrade(e))}function ceDisconnected(e){e[z].flags&1024&&enqueueCallback(e,`disconnectedCallback`,[])}function ceAttributeChanged(e,t,n,r,i){e[z].flags&1024&&enqueueCallback(e,`attributeChangedCallback`,[t,n,r,i])}function ceMoved(e){let t=e[z];if(!(t.flags&1024)||!(t.flags&1))return;let n=Zs.get(e);if(n===void 0)return;if(n.connectedMoveCallback!==null){pushReaction(e,{kind:1,def:n,fn:n.connectedMoveCallback,args:[]});return}let r=n.disconnectedCallback,i=n.connectedCallback;(r!==null||i!==null)&&pushReaction(e,{kind:1,def:n,fn:function(){r!==null&&r.call(this),i!==null&&i.call(this)},args:[]})}function ceAdopted(e,t,n){e[z].flags&1024&&enqueueCallback(e,`adoptedCallback`,[t,n])}function shadowDisabled(e){if(nc===0)return!1;let t=e[z],n=Zs.get(e)??lookupDefinition(t.doc,t.ns,t.name,tc.get(e)??null);return n!=null&&n.disableShadow}const _c=2147483647;function contentAttr(e,t){let n=e.attrs;if(n===null)return null;for(let e=0;e<n.length;e++){let r=n[e];if(r.localName===t&&(r.rare===null||r.rare.ns===null))return r.value}return null}function setContentAttr(e,t,n){setAttributeValue(e,t,n)}function removeContentAttr(e,t){removeAttributeByLocalName(e,t)}function lower(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n>=65&&n<=90)return e.replace(/[A-Z]+/g,e=>e.toLowerCase())}return e}function names(e){let t=[];for(let n of e.split(` `)){if(n===``)continue;let e=n.indexOf(`=`);e===-1?t.push([n,lower(n)]):t.push([n.slice(0,e),n.slice(e+1)])}return t}function defineAccessor(e,t,n,r){Object.defineProperty(e.prototype,t,{get:n,set:r,configurable:!0,enumerable:!0})}function parseInteger(e){let t=e.length,n=0;for(;n<t&&isAsciiWhitespace(e.charCodeAt(n));)n++;if(n===t)return NaN;let r=1,i=e.charCodeAt(n);if(i===45?(r=-1,n++):i===43&&n++,n===t||(i=e.charCodeAt(n),i<48||i>57))return NaN;let a=0;for(;n<t&&(i=e.charCodeAt(n),!(i<48||i>57));)a=a*10+(i-48),n++;return a>0x38d7ea4c68000&&(a=1/0),r*a+0}function parseNonNegativeInteger(e){let t=parseInteger(e);return t>=0?t+0:NaN}function parseFloatingPoint(e){let t=0,n=e.length;for(;t<n&&isAsciiWhitespace(e.charCodeAt(t));)t++;let r=/^[-+]?(?:\d+(?:\.\d+)?|\.\d+)(?:[eE][-+]?\d+)?/.exec(t===0?e:e.slice(t));if(r===null)return NaN;let i=Number(r[0]);return Number.isFinite(i)?i===0?0:i:NaN}function indexSizeError(e){return new DOMException(e,`IndexSizeError`)}function str(e,t){for(let[n,r]of names(t))defineAccessor(e,n,function(){return contentAttr(this[z],r)??``},function(e){setContentAttr(this[z],r,String(e))})}function strNullEmpty(e,t){for(let[n,r]of names(t))defineAccessor(e,n,function(){return contentAttr(this[z],r)??``},function(e){setContentAttr(this[z],r,e===null?``:String(e))})}function nullableStr(e,t){for(let[n,r]of names(t))defineAccessor(e,n,function(){return contentAttr(this[z],r)},function(e){e==null?removeContentAttr(this[z],r):setContentAttr(this[z],r,String(e))})}function bool(e,t){for(let[n,r]of names(t))defineAccessor(e,n,function(){return contentAttr(this[z],r)!==null},function(e){e?setContentAttr(this[z],r,``):removeContentAttr(this[z],r)})}function url(e,t){for(let[n,r]of names(t))defineAccessor(e,n,function(){let e=this[z],t=contentAttr(e,r);return t===null?``:resolveURL(e,t)??t},function(e){setContentAttr(this[z],r,String(e))})}function resolveURL(e,t){let n=e.doc.baseURI,r=URL.parse(t,n);return r===null?null:r.href}function long(e,t,n=0){for(let[r,i]of names(t))defineAccessor(e,r,function(){let e=contentAttr(this[z],i);if(e===null)return n;let t=parseInteger(e);return t>=-2147483648&&t<=_c?t:n},function(e){setContentAttr(this[z],i,String(Number(e)|0))})}function nonNegativeLong(e,t,n=-1){for(let[r,i]of names(t))defineAccessor(e,r,function(){let e=contentAttr(this[z],i);if(e===null)return n;let t=parseNonNegativeInteger(e);return t<=_c?t:n},function(e){let t=Number(e)|0;if(t<0)throw indexSizeError(`The value provided (${t}) is negative.`);setContentAttr(this[z],i,String(t))})}function ulong(e,t,n=0,r=!1){let i=+!!r;for(let[a,o]of names(t))defineAccessor(e,a,function(){let e=contentAttr(this[z],o);if(e===null)return n;let t=parseNonNegativeInteger(e);return t>=i&&t<=_c?t:n},function(e){let t=Number(e)>>>0;if(r&&t===0)throw indexSizeError(`The value provided is 0, which is not a positive number.`);t>_c&&(t=n),setContentAttr(this[z],o,String(t))})}function clampedUlong(e,t,n,r,i,a){defineAccessor(e,t,function(){let e=contentAttr(this[z],n);if(e===null)return r;let t=parseNonNegativeInteger(e);return Number.isNaN(t)?r:t<i?i:t>a?a:t},function(e){let t=Number(e)>>>0;t>_c&&(t=r),setContentAttr(this[z],n,String(t))})}function enumerated(e,t,n){let r=/* @__PURE__ */ new Map;for(let e of n.keywords){let t=e.indexOf(`:`);t===-1?r.set(e,e):r.set(e.slice(0,t),e.slice(t+1))}let i=n.missing===void 0?``:n.missing,a=n.invalid??``,o=n.empty??a,s=i===null;for(let[n,c]of names(t))defineAccessor(e,n,function(){let e=contentAttr(this[z],c);return e===null?i:e===``?r.get(``)??o:r.get(lower(e))??a},function(e){s&&e==null?removeContentAttr(this[z],c):setContentAttr(this[z],c,String(e))})}const vc={keywords:[`anonymous`,`use-credentials`],missing:null,invalid:`anonymous`,empty:`anonymous`},yc={keywords:[`no-referrer`,`no-referrer-when-downgrade`,`same-origin`,`origin`,`strict-origin`,`origin-when-cross-origin`,`strict-origin-when-cross-origin`,`unsafe-url`]},bc={keywords:[`lazy`,`eager`],missing:`eager`,invalid:`eager`},xc={keywords:[`high`,`low`,`auto`],missing:`auto`,invalid:`auto`};function tokenList(e,t,n,r=null){let i=Symbol(t);defineAccessor(e,t,function(){let e=this[i];return e===void 0&&(e=new Qo(this[z],n,r),Object.defineProperty(this,i,{value:e})),e},function(e){setContentAttr(this[z],n,String(e))})}const Sc=2147483647;function readNonNegativeLong(e,t,n){let r=contentAttr(e,t);if(r===null)return n;let i=parseNonNegativeInteger(r);return i<=Sc?i:n}function readPositiveUnsigned(e,t,n){let r=contentAttr(e,t);if(r===null)return n;let i=parseNonNegativeInteger(r);return i>=1&&i<=Sc?i:n}function positiveWithFallback(e,t,n,r){Object.defineProperty(e.prototype,t,{get(){return readPositiveUnsigned(this[z],n,r)},set(e){let t=toUnsignedLong(e);setAttribute(this[z],n,String(t>=1&&t<=Sc?t:r))},enumerable:!0,configurable:!0})}function toUnsignedLong(e){let t=Number(e);return Number.isFinite(t)?Math.trunc(t)>>>0:0}function reflectActionURL(e,t){let n=contentAttr(e,t);if(n===null||n===``)return e.doc.URL;let r=URL.parse(n,e.doc.baseURI);return r===null?n:r.href}function isWS(e){return e===32||e===9||e===10||e===12||e===13}function stripNewlines(e){return e.includes(`
8
- `)||e.includes(`\r`)?e.replace(/[\r\n]/g,``):e}function trimASCII(e){let t=0,n=e.length;for(;t<n&&isWS(e.charCodeAt(t));)t++;for(;n>t&&isWS(e.charCodeAt(n-1));)n--;return t===0&&n===e.length?e:e.slice(t,n)}function stripAndCollapseWS(e){return trimASCII(e).replace(/[\t\n\f\r ]+/g,` `)}function normalizeNewlines(e){return e.indexOf(`\r`)===-1?e:e.replace(/\r\n?/g,`
9
- `)}function fireEvent$1(e,t,n,r,i=!1){let a=new Event(t,{bubbles:n,cancelable:r,composed:i});return setTrusted(a),dispatch(a,e)}__name(fireEvent$1,`fireEvent`);function dispatchTrusted$1(e,t){return setTrusted(t),dispatch(t,e)}__name(dispatchTrusted$1,`dispatchTrusted`);var ComputedNodeList=class extends aa{constructor(){super(null)}_snapshot(){let e=this._root().doc,t=cachedSnapshot(e,this,e[J]);if(t!==void 0)return t;let n=this._compute();return storeSnapshot(e,this,e[J],n),n.length>Cc.count&&ensureIndexGetters(Cc,n.length),n}get length(){return this._snapshot().length}item(e){let t=this._snapshot(),n=e>>>0;return n<t.length?t[n]:null}};const Cc=indexGetterTable(ComputedNodeList.prototype,(e,t)=>{let n=e._snapshot();return t<n.length?n[t]:void 0});var LabelsNodeList=class extends ComputedNodeList{constructor(e){super(),Object.defineProperty(this,F,{value:e})}_root(){return this[F]}_compute(){let e=labelsFor(this[F]),t=Array(e.length);for(let n=0;n<e.length;n++)t[n]=e[n].node;return t}},NameNodeList=class extends ComputedNodeList{constructor(e,t){super(),Object.defineProperty(this,F,{value:e}),Object.defineProperty(this,Jn,{value:t})}_root(){return this[F]}_compute(){let e=this[F],t=this[Jn],n=[];for(let r=firstElementChild(e);r!==null;r=nextElementInTree(r,e))r.ns===`http://www.w3.org/1999/xhtml`&&r.attrs!==null&&attr(r,`name`)===t&&n.push(r.node);return n}},NamedLists=class{refs=/* @__PURE__ */ new Map;collected=new FinalizationRegistry(e=>{this.refs.get(e)?.deref()===void 0&&this.refs.delete(e)})};const wc=/* @__PURE__ */ new WeakMap,Tc=/* @__PURE__ */ new WeakMap,Ec=/* @__PURE__ */ new WeakSet;function namedList(e,t,n){let r=n?Tc:wc,i=r.get(e);i===void 0&&r.set(e,i=new NamedLists);let a=i.refs.get(t)?.deref();return a===void 0&&(a=new RadioNodeList(e,t),n&&Ec.add(a),i.refs.set(t,new WeakRef(a)),i.collected.register(a,t)),a}function namedControl(e,t,n){if(t.length>=32){let r=e.doc;flushBlankedName(r);let i=r[rn];if(t.namesVersion===i){let r=(t.names??=controlsByName(t)).get(n);return r===void 0?null:r??namedList(e,n,!1)}t.namesVersion=i,t.names=null}let r=null;for(let i of t)if(i.id===n||attr(i,`name`)===n){if(r!==null)return namedList(e,n,!1);r=i}return r}function controlsByName(e){let t=/* @__PURE__ */ new Map;for(let n of e){let e=n.id;e!==``&&t.set(e,t.has(e)?null:n);let r=attr(n,`name`);r!==null&&r!==``&&r!==e&&t.set(r,t.has(r)?null:n)}return t}function matchesNamedImage(e,t,n){return e.tag===Z.img&&(e.id===n||attr(e,`name`)===n)&&formOwner(e)===t}function namedImage(e,t){let n=null,r=formOwnerScope(e,!1);for(let i=nextElementInTree(r,r);i!==null;i=nextElementInTree(i,r))if(matchesNamedImage(i,e,t)){if(n!==null)return namedList(e,t,!0);n=i}return n}var RadioNodeList=class extends ComputedNodeList{constructor(e,t){super(),Object.defineProperty(this,en,{value:e}),Object.defineProperty(this,Jn,{value:t})}_root(){return this[en]}_compute(){let e=this[en],t=this[Jn],n=[];if(Ec.has(this)){let r=formOwnerScope(e,!1);for(let i=nextElementInTree(r,r);i!==null;i=nextElementInTree(i,r))matchesNamedImage(i,e,t)&&n.push(i.node);return n}let r=e.node._controls();for(let e=0;e<r.length;e++){let i=r[e];(i.id===t||attr(i,`name`)===t)&&n.push(i.node)}return n}get value(){let e=this._snapshot();for(let t=0;t<e.length;t++){let n=e[t][z];if(n.tag===Z.input&&inputType(n)===16&&e[t].checked)return attr(n,`value`)??`on`}return``}set value(e){let t=String(e),n=this._snapshot();for(let e=0;e<n.length;e++){let r=n[e][z];if(r.tag===Z.input&&inputType(r)===16&&(attr(r,`value`)??`on`)===t){n[e].checked=!0;return}}}};Object.defineProperty(RadioNodeList.prototype,Symbol.toStringTag,{value:`RadioNodeList`,configurable:!0});var HTMLFormControlsCollection=class extends io{constructor(e){super(e,!1,null)}_collect(e){let t=this._s.root.node._controls();for(let n=0;n<t.length;n++)e.push(t[n].node)}namedItem(e){let t=String(e);if(t===``)return null;let n=this._s.root,r=namedControl(n,n.node._controls(),t);return r instanceof RadioNodeList?r:r?.node??null}};Object.defineProperty(HTMLFormControlsCollection.prototype,Symbol.toStringTag,{value:`HTMLFormControlsCollection`,configurable:!0});function createFormControlsCollection(e){return withNamedProperties(new HTMLFormControlsCollection(e))}function scanOptions(e,t){let n=e.first,r=0,i=0;for(;n!==null;){let a=!1;if(n.type===1){let e=n.ns===`http://www.w3.org/1999/xhtml`?n.tag:0;if(e===Z.option){let e=t(n,r++);if(e!==void 0)return e}else a=e===Z.optgroup?i===0:e!==Z.select&&e!==Z.hr&&e!==Z.datalist}if(a&&n.first!==null)n.ns===`http://www.w3.org/1999/xhtml`&&n.tag===Z.optgroup&&i++,n=n.first;else{for(;n!==null&&n.next===null;){if(n=n.parent,n===e||n===null)return;n.ns===`http://www.w3.org/1999/xhtml`&&n.tag===Z.optgroup&&i--}if(n===null)return;n=n.next}}}function listOfOptions(e,t){return scanOptions(e,e=>{t.push(e)}),t}var HTMLOptionsCollection=class extends io{constructor(e){super(e,!1,null,!0)}_collect(e){scanOptions(this._s.root,t=>{e.push(t.node)}),ensureOptionIndexAccessors(e.length+1)}_setIndex(e,t){let n=this._s.root.node,r=this._snapshot();if(t==null){e<r.length&&r[e].remove();return}if(typeof t!=`object`||!(z in t)||t[z].tag!==Z.option)throw TypeError(`Failed to set an indexed property on 'HTMLOptionsCollection': parameter 2 is not of type 'HTMLOptionElement'.`);let i=e-r.length;if(i>0){let e=this._s.root.doc,t=e.createDocumentFragment();for(let n=0;n<i;n++)t.appendChild(e.createElement(`option`));n.appendChild(t)}if(i>=0)n.appendChild(t);else{let n=r[e];n.parentNode.replaceChild(t,n)}}get length(){return this._snapshot().length}set length(e){let t=Number(e)>>>0,n=this._s.root.node,r=this._snapshot(),i=r.length;if(t>i){if(t-i>1e5)return;let e=this._s.root.doc,r=e.createDocumentFragment();for(let n=i;n<t;n++)r.appendChild(e.createElement(`option`));n.appendChild(r)}else if(t<i){let e=r.slice(t);for(let t=0;t<e.length;t++)e[t].remove()}}add(e,t=null){let n=this._s.root.node;if(typeof e!=`object`||!e||!(z in e))throw TypeError(`Failed to execute 'add' on 'HTMLOptionsCollection': parameter 1 is not of type 'HTMLOptionElement or HTMLOptGroupElement'.`);let r=e[z].tag;if(r!==Z.option&&r!==Z.optgroup)throw TypeError(`Failed to execute 'add' on 'HTMLOptionsCollection': parameter 1 is not of type 'HTMLOptionElement or HTMLOptGroupElement'.`);for(let t=this._s.root;t!==null;t=t.parent)if(t===e[z])throw new DOMException(`The new element is an ancestor of the select element.`,`HierarchyRequestError`);let i=null;if(typeof t==`number`)i=this._snapshot()[t]??null;else if(t!=null){i=t;let e=!1;for(let n=t[z].parent;n!==null;n=n.parent)if(n===this._s.root){e=!0;break}if(!e)throw new DOMException(`The node before which the new node is to be inserted is not in this select.`,`NotFoundError`)}e!==i&&(i===null?n:i.parentNode).insertBefore(e,i)}remove(e){let t=this._snapshot(),n=Number(e)|0;t.length===0||n<0||n>=t.length||t[n].remove()}get selectedIndex(){return this._s.root.node.selectedIndex}set selectedIndex(e){this._s.root.node.selectedIndex=e}};let Dc=0;const Oc=[{proto:HTMLOptionsCollection.prototype,coll:e=>e}];function addOptionIndexHost(e,t){Oc.push({proto:e,coll:t}),defineOptionIndices(Oc[Oc.length-1],0,Dc)}function defineOptionIndices(e,t,n){let r=e.coll;for(let i=t;i<n;i++)Object.defineProperty(e.proto,i,{get(){return r(this).item(i)??void 0},set(e){r(this)._setIndex(i,e)},enumerable:!1,configurable:!0})}function ensureOptionIndexAccessors(e){if(e<=Dc)return;let t=Math.max(e,Dc*2,32);for(let e of Oc)defineOptionIndices(e,Dc,t);Dc=t}ensureOptionIndexAccessors(32);var ValidityState=class{constructor(e){defineHidden(this,F,e)}get valueMissing(){return!!(this[F]._validityFlags()&1)}get typeMismatch(){return!!(this[F]._validityFlags()&2)}get patternMismatch(){return!!(this[F]._validityFlags()&4)}get tooLong(){return!!(this[F]._validityFlags()&8)}get tooShort(){return!!(this[F]._validityFlags()&16)}get rangeUnderflow(){return!!(this[F]._validityFlags()&32)}get rangeOverflow(){return!!(this[F]._validityFlags()&64)}get stepMismatch(){return!!(this[F]._validityFlags()&128)}get badInput(){return!!(this[F]._validityFlags()&256)}get customError(){return!!(this[F]._validityFlags()&512)}get valid(){return this[F]._validityFlags()===0}get[Symbol.toStringTag](){return`ValidityState`}};exposeMembers(ValidityState);function isInvalidCandidate(e){return!e._barredFromValidation()&&e._validityFlags()!==0}function checkValidityOf(e){return!isInvalidCandidate(e)||(fireEvent$1(e,`invalid`,!1,!0),!1)}const kc={get willValidate(){return!this._barredFromValidation()},get validity(){let e=this;return e[ci]??=new ValidityState(e)},get validationMessage(){let e=this;if(e._barredFromValidation())return``;let t=e._validityFlags();return t===0?``:t&512?e[kt]??``:builtinMessage(e,t)},checkValidity(){return checkValidityOf(this)},reportValidity(){return checkValidityOf(this)},setCustomValidity(e){this[kt]=normalizeNewlines(String(e))}};function installConstraintValidation(e){for(let t of Reflect.ownKeys(kc))Object.defineProperty(e.prototype,t,Object.getOwnPropertyDescriptor(kc,t))}function builtinMessage(e,t){return e[z].doc[Y]?.[V]?.validationMessages===`browser`?e._validationMessage(t):`Constraints not satisfied`}const Ac=`Please fill out this field.`,jc=`Please enter a valid value.`;function msgEmail(e){let t=e.indexOf(`@`);return t===-1?`Please include an '@' in the email address. '${e}' is missing an '@'.`:t===e.length-1?`Please enter a part following '@'. '${e}' is incomplete.`:t===0?`Please enter a part followed by '@'. '${e}' is incomplete.`:`Please enter an email address.`}function characters(e){return e===1?`1 character`:`${e} characters`}function msgTooLong(e,t){return`Please shorten this text to ${characters(e)} or less (you are currently using ${characters(t)}).`}function msgTooShort(e,t){return`Please lengthen this text to ${characters(e)} or more (you are currently using ${characters(t)}).`}function msgUnderflow(e,t){return t?`Value must be ${e} or later.`:`Value must be greater than or equal to ${e}.`}function msgOverflow(e,t){return t?`Value must be ${e} or earlier.`:`Value must be less than or equal to ${e}.`}function msgStep(e,t){if(e!==null&&t!==null)return`Please enter a valid value. The two nearest valid values are ${e} and ${t}.`;let n=e??t;return n===null?jc:`Please enter a valid value. The nearest valid value is ${n}.`}const Mc=[[`valueMissing`,1],[`typeMismatch`,2],[`patternMismatch`,4],[`tooLong`,8],[`tooShort`,16],[`rangeUnderflow`,32],[`rangeOverflow`,64],[`stepMismatch`,128],[`badInput`,256],[`customError`,512]];var FaceState=class{impl;value;state;flags;message;validity;labels;lastOwner;lastDisabled;constructor(e){this.impl=e,this.value=null,this.state=null,this.flags=0,this.message=``,this.validity=null,this.labels=null,this.lastOwner=null,this.lastDisabled=!1}_validityFlags(){return this.flags}_barredFromValidation(){let e=this.impl;return isActuallyDisabled(e)||attr(e,`readonly`)!==null||hasDatalistAncestor(e)}_validationMessage(e){return this.message}};const Nc=/* @__PURE__ */ new WeakMap;function isFACE(e){return!!(e.flags&he)}function faceState(e){let t=Nc.get(e);return t===void 0&&(t=new FaceState(e),Nc.set(e,t)),t}function validatableOf(e){return isFACE(e)?faceState(e):e.node}function assertFACE(e,t){if(!isFACE(e))throw new DOMException(`Failed to execute '${t}' on 'ElementInternals': The target element is not a form-associated custom element.`,`NotSupportedError`)}function internalsSetFormValue(e,t,n){assertFACE(e,`setFormValue`);let r=faceState(e);r.value=cloneSubmission(t),r.state=n===void 0?r.value:cloneSubmission(n)}function cloneSubmission(e){if(e==null)return null;if(e instanceof FormData){let t=new FormData;for(let[n,r]of e)t.append(n,r);return t}return e instanceof File?e:String(e)}function internalsForm(e){assertFACE(e,`form`);let t=formOwner(e);return t===null?null:t.node}function internalsLabels(e){assertFACE(e,`labels`);let t=faceState(e);return t.labels??=new LabelsNodeList(e)}function internalsSetValidity(e,t,n,r){assertFACE(e,`setValidity`);let i=0;if(t!=null)for(let[e,n]of Mc)t[e]&&(i|=n);if(i!==0&&(n===void 0||String(n)===``))throw TypeError(`Failed to execute 'setValidity' on 'ElementInternals': The second argument should not be empty if one or more flags in the first argument are true.`);if(r!=null){let t=r[z];if(t===void 0||t.type!==1||t.ns!==`http://www.w3.org/1999/xhtml`)throw TypeError(`Failed to execute 'setValidity' on 'ElementInternals': parameter 3 is not of type 'HTMLElement'.`);let n=!1;for(let r=t;r!==null;r=r.parent??r.node[R]?.[z]??null)if(r===e){n=!0;break}if(!n)throw new DOMException(`Failed to execute 'setValidity' on 'ElementInternals': The validation anchor is not a shadow-including descendant of the element.`,`NotFoundError`)}let a=faceState(e);a.flags=i,a.message=i===0?``:String(n).replace(/\r\n?/g,`
10
- `)}function internalsWillValidate(e){return assertFACE(e,`willValidate`),!faceState(e)._barredFromValidation()}function internalsValidity(e){assertFACE(e,`validity`);let t=faceState(e);return t.validity??=new ValidityState(t)}function internalsValidationMessage(e){assertFACE(e,`validationMessage`);let t=faceState(e);return t._barredFromValidation()?``:t.message}function internalsCheckValidity(e,t=`checkValidity`){assertFACE(e,t);let n=faceState(e);return n._barredFromValidation()||n.flags===0?!0:(fireEvent$1(e.node,`invalid`,!1,!0),!1)}function faceEntries(e,t){let n=Nc.get(e)?.value??null;if(n===null)return;if(n instanceof FormData){for(let[e,r]of n)t.push([e,r]);return}let r=attr(e,`name`);r!==null&&r!==``&&t.push([r,n])}function invoke(e,t,n){enqueueFormCallback(e.node,t,n)}function faceReset(e){invoke(e,`formResetCallback`,[])}function flushFaceReactions(){flushReactions()}function faceStateMaybeChanged(e){let t=faceState(e),n=formOwner(e);n!==(t.lastOwner===null?null:t.lastOwner.deref())&&(t.lastOwner=n===null?null:new WeakRef(n),invoke(e,`formAssociatedCallback`,[n===null?null:n.node]));let r=isActuallyDisabled(e);r!==t.lastDisabled&&(t.lastDisabled=r,invoke(e,`formDisabledCallback`,[r]))}setFaceUpgradeHook(faceStateMaybeChanged);function isNewline(e){return e===10||e===13||e===12}function isWhitespace(e){return e===32||e===9||e===10||e===13||e===12}function isDigit(e){return e>=48&&e<=57}function isHexDigit(e){return e>=48&&e<=57||e>=65&&e<=70||e>=97&&e<=102}function hexValue(e){return e<=57?e-48:e<=70?e-65+10:e-97+10}function isNonAsciiIdent(e){return e<183?!1:e===183||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e===8204||e===8205||e===8255||e===8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=55296&&e<=57343||e>=63744&&e<=64975||e>=65008&&e<=65533}function isIdentStart(e){return e>=97&&e<=122||e>=65&&e<=90||e===95||isNonAsciiIdent(e)}function isIdentChar(e){return isIdentStart(e)||isDigit(e)||e===45}function isNonPrintable(e){return e>=0&&e<=8||e===11||e>=14&&e<=31||e===127}var CSSTokenizer=class{src;len;pos;type;start;end;value;num;isInteger;unit;hashId;sign;comments;constructor(e){this.src=e,this.len=e.length,this.pos=0,this.type=0,this.start=0,this.end=0,this.value=``,this.num=0,this.isInteger=!0,this.unit=``,this.hashId=!1,this.sign=``,this.comments=0}reset(e){this.pos=e}code(e){return e<this.len?this.src.charCodeAt(e):-1}validEscape(e){return this.code(e)===92&&!isNewline(this.code(e+1))}startsIdent(e){let t=this.code(e);if(t===45){let t=this.code(e+1);return isIdentStart(t)||t===45||this.validEscape(e+1)}return isIdentStart(t)?!0:this.validEscape(e)}startsNumber(e){let t=this.code(e);if(t===43||t===45){let t=this.code(e+1);return isDigit(t)?!0:t===46&&isDigit(this.code(e+2))}return isDigit(t===46?this.code(e+1):t)}consumeEscape(){let e=this.code(this.pos);if(e===-1)return`�`;if(isHexDigit(e)){let e=0,t=0;for(;t<6&&isHexDigit(this.code(this.pos));)e=e*16+hexValue(this.code(this.pos)),this.pos++,t++;let n=this.code(this.pos);return n===13&&this.code(this.pos+1)===10?this.pos+=2:isWhitespace(n)&&this.pos++,e===0||e>=55296&&e<=57343||e>1114111?`�`:String.fromCodePoint(e)}if(this.pos++,e===0)return`�`;if(e>=55296&&e<=56319){let e=this.code(this.pos);if(e>=56320&&e<=57343)return this.pos++,this.src.slice(this.pos-2,this.pos)}return this.src.slice(this.pos-1,this.pos)}consumeName(){let e=this.pos;for(;this.pos<this.len;){let e=this.src.charCodeAt(this.pos);if(isIdentChar(e)&&e!==0)this.pos++;else break}if(!this.validEscape(this.pos)&&this.code(this.pos)!==0)return this.src.slice(e,this.pos);let t=this.src.slice(e,this.pos);for(;this.pos<this.len;){let e=this.src.charCodeAt(this.pos);if(e===0)t+=`�`,this.pos++;else if(isIdentChar(e))t+=this.src.slice(this.pos,this.pos+1),this.pos++;else if(this.validEscape(this.pos))this.pos++,t+=this.consumeEscape();else break}return t}consumeNumber(){let e=this.pos,t=!0,n=this.code(this.pos);for(this.sign=``,(n===43||n===45)&&(this.sign=n===43?`+`:`-`,this.pos++);isDigit(this.code(this.pos));)this.pos++;if(this.code(this.pos)===46&&isDigit(this.code(this.pos+1)))for(this.pos+=2,t=!1;isDigit(this.code(this.pos));)this.pos++;if(n=this.code(this.pos),n===69||n===101){let e=this.code(this.pos+1);if(isDigit(e))for(this.pos+=2,t=!1;isDigit(this.code(this.pos));)this.pos++;else if((e===43||e===45)&&isDigit(this.code(this.pos+2)))for(this.pos+=3,t=!1;isDigit(this.code(this.pos));)this.pos++}this.num=Number(this.src.slice(e,this.pos)),this.isInteger=t}consumeNumeric(){return this.consumeNumber(),this.startsIdent(this.pos)?(this.unit=this.consumeName(),this.value=this.unit,12):this.code(this.pos)===37?(this.pos++,11):10}consumeString(e){let t=this.pos;for(;this.pos<this.len;){let n=this.src.charCodeAt(this.pos);if(n===e)return this.value=this.src.slice(t,this.pos),this.pos++,5;if(n===92||n===0||isNewline(n))break;this.pos++}let n=this.src.slice(t,this.pos);for(;;){if(this.pos>=this.len)return this.value=n,5;let t=this.src.charCodeAt(this.pos);if(t===e)return this.pos++,this.value=n,5;if(isNewline(t))return this.value=n,6;if(t===92){let e=this.code(this.pos+1);e===-1?this.pos++:isNewline(e)?this.pos+=e===13&&this.code(this.pos+2)===10?3:2:(this.pos++,n+=this.consumeEscape())}else t===0?(n+=`�`,this.pos++):(n+=this.src.slice(this.pos,this.pos+1),this.pos++)}}consumeBadUrl(){for(;this.pos<this.len;){if(this.src.charCodeAt(this.pos)===41){this.pos++;break}this.validEscape(this.pos)?(this.pos++,this.consumeEscape()):this.pos++}return this.value=``,8}consumeUrl(){for(;isWhitespace(this.code(this.pos));)this.pos++;let e=``;for(;;){if(this.pos>=this.len)return this.value=e,7;let t=this.src.charCodeAt(this.pos);if(t===41)return this.pos++,this.value=e,7;if(isWhitespace(t)){for(;isWhitespace(this.code(this.pos));)this.pos++;let t=this.code(this.pos);return t===41?(this.pos++,this.value=e,7):t===-1?(this.value=e,7):this.consumeBadUrl()}if(t===34||t===39||t===40||isNonPrintable(t))return this.pos++,this.consumeBadUrl();if(t===92){if(this.validEscape(this.pos))this.pos++,e+=this.consumeEscape();else return this.consumeBadUrl()}else t===0?(e+=`�`,this.pos++):(e+=this.src.slice(this.pos,this.pos+1),this.pos++)}}consumeIdentLike(){let e=this.consumeName();if(this.value=e,this.code(this.pos)===40){if(this.pos++,e.length===3&&asciiLower3(e)===`url`){let e=this.pos;for(;isWhitespace(this.code(e))&&isWhitespace(this.code(e+1));)e++;let t=this.code(e),n=isWhitespace(t)?this.code(e+1):t;return n===34||n===39?2:this.consumeUrl()}return 2}return 1}skipComments(){for(;this.code(this.pos)===47&&this.code(this.pos+1)===42;){let e=this.src.indexOf(`*/`,this.pos+2);this.pos=e===-1?this.len:e+2,this.comments++}}next(){this.skipComments(),this.start=this.pos,this.value=``;let e=this.consumeToken();return this.type=e,this.end=this.pos,e}consumeToken(){if(this.pos>=this.len)return 0;let e=this.src.charCodeAt(this.pos);if(isWhitespace(e)){for(this.pos++;isWhitespace(this.code(this.pos));)this.pos++;return 13}switch(e){case 34:case 39:return this.pos++,this.consumeString(e);case 35:return isIdentChar(this.code(this.pos+1))||this.validEscape(this.pos+1)?(this.pos++,this.hashId=this.startsIdent(this.pos),this.value=this.consumeName(),4):this.delim();case 40:return this.pos++,21;case 41:return this.pos++,22;case 43:return this.startsNumber(this.pos)?this.consumeNumeric():this.delim();case 44:return this.pos++,18;case 45:return this.startsNumber(this.pos)?this.consumeNumeric():this.code(this.pos+1)===45&&this.code(this.pos+2)===62?(this.pos+=3,15):this.startsIdent(this.pos)?this.consumeIdentLike():this.delim();case 46:return this.startsNumber(this.pos)?this.consumeNumeric():this.delim();case 58:return this.pos++,16;case 59:return this.pos++,17;case 60:return this.code(this.pos+1)===33&&this.code(this.pos+2)===45&&this.code(this.pos+3)===45?(this.pos+=4,14):this.delim();case 64:return this.startsIdent(this.pos+1)?(this.pos++,this.value=this.consumeName(),3):this.delim();case 91:return this.pos++,19;case 92:return this.validEscape(this.pos)?this.consumeIdentLike():this.delim();case 93:return this.pos++,20;case 123:return this.pos++,23;case 125:return this.pos++,24}return isDigit(e)?this.consumeNumeric():isIdentStart(e)||e===0?this.consumeIdentLike():this.delim()}delim(){let e=this.src.charCodeAt(this.pos);if(e>=55296&&e<=56319){let e=this.code(this.pos+1);if(e>=56320&&e<=57343)return this.value=this.src.slice(this.pos,this.pos+2),this.pos+=2,9}return this.value=this.src.slice(this.pos,this.pos+1),this.pos++,9}};function asciiLower3(e){return e.toLowerCase()}var RawDecl=class{name;value;important;constructor(e,t,n){this.name=e,this.value=t,this.important=n}},RawRule=class{kind;name;prelude;hasBlock;decls;leading;rules;lazy;constructor(e,t,n,r){this.kind=e,this.name=t,this.prelude=n,this.hasBlock=r,this.decls=[],this.leading=0,this.rules=[],this.lazy=null}};function rawDecls(e){let t=e.lazy;return t!==null&&(e.lazy=null,e.decls=parseDeclarationList(t),e.leading=e.decls.length),e.decls}function flatBlockEnd(e,t){let n=e.length,r=0;for(let i=t;i<n;i++){let a=e.charCodeAt(i);switch(a){case 125:return r===0?i:-1;case 123:case 64:return-1;case 40:if(i-t>=3&&(e.charCodeAt(i-1)|32)==108&&(e.charCodeAt(i-2)|32)==114&&(e.charCodeAt(i-3)|32)==117){let t=i+1;for(;t<n&&isCssWhitespace(e.charCodeAt(t));)t++;let r=e.charCodeAt(t);if(r!==34&&r!==39){for(;t<n;t++){let n=e.charCodeAt(t);if(n===41)break;if(n<=32||n===34||n===39||n===40||n===92||n===123||n===125)return-1}if(t===n)return-1;i=t;break}}r++;break;case 91:r++;break;case 41:case 93:if(r===0)return-1;r--;break;case 34:case 39:{let t=i+1;for(;t<n;t++){let n=e.charCodeAt(t);if(n===a)break;if(n===10||n===13||n===12||n===92)return-1}if(t===n)return-1;i=t;break}case 47:if(e.charCodeAt(i+1)===42){let t=e.indexOf(`*/`,i+2);if(t===-1)return-1;i=t+1}break;case 92:return-1}}return-1}function isCssWhitespace(e){return e===32||e===10||e===9||e===13||e===12}function closerFor(e){return e===2||e===21?22:e===19?20:e===23?24:0}function stripComments(e){let t=new CSSTokenizer(e),n=``,r=0,i=t.next();for(;i!==0;)t.start!==r&&n!==``&&t.type!==13&&!n.endsWith(` `)&&needsSeparator(n.charCodeAt(n.length-1),e.charCodeAt(t.start))&&(n+=`/**/`),n+=e.slice(t.start,t.end),r=t.end,i=t.next();return n.trim()}function needsSeparator(e,t){return(e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||e===45||e===95||e>=128)&&(t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122||t===45||t===95||t>=128)}function isAsciiCaseInsensitive(e,t){return e.length===t.length&&e.toLowerCase()===t}var CSSParser=class{src;t;peeked;stack;valueStart;valueEnd;importantEnd;important;valueHasBlock;valueOtherCount;lazyBlocks;constructor(e){this.src=e,this.t=new CSSTokenizer(e),this.peeked=!1,this.stack=[],this.valueStart=0,this.valueEnd=0,this.importantEnd=0,this.important=!1,this.valueHasBlock=!1,this.valueOtherCount=0,this.lazyBlocks=!0}advance(){return this.peeked?(this.peeked=!1,this.t.type):this.t.next()}reconsume(){this.peeked=!0}advanceNonWs(){let e=this.advance();for(;e===13;)e=this.advance();return e}mark(){return this.t.start}restore(e){this.t.reset(e),this.peeked=!1}skipBlock(e){let t=this.stack,n=t.length;for(t.push(closerFor(e));t.length>n;){let e=this.t.next();if(e===0)break;e===t[t.length-1]?t.pop():(e===2||e===21||e===19||e===23)&&t.push(closerFor(e))}t.length=n}text(e,t,n){let r=this.src.slice(e,t);return this.t.comments!==n&&r.indexOf(`/*`)!==-1?stripComments(r):r}parseStylesheet(){let e=[];for(;;){let t=this.advance();if(t===0)break;if(t!==13&&t!==14&&t!==15){if(t===3){let t=this.consumeAtRule(!1);t!==null&&e.push(t)}else{this.reconsume();let t=this.consumeQualifiedRule(!1);t!==null&&e.push(t)}}}return e}consumeAtRule(e){let t=this.t.value,n=this.t.comments,r=-1,i=-1;for(;;){let a=this.advance();if(a===17||a===0)return new RawRule(2,t,r===-1?``:this.text(r,i,n),!1);if(a===24){if(e)return this.reconsume(),new RawRule(2,t,r===-1?``:this.text(r,i,n),!1);r===-1&&(r=this.t.start),i=this.t.end}else{if(a===23){let e=new RawRule(2,t,r===-1?``:this.text(r,i,n),!0);return this.consumeBlockContents(e),e}a!==13&&(r===-1&&(r=this.t.start),(a===2||a===21||a===19)&&this.skipBlock(a),i=this.t.end)}}}consumeQualifiedRule(e){let t=this.t.comments,n=-1,r=-1;for(;;){let i=this.advance();if(i===0)return null;if(i===24){if(e)return this.reconsume(),null;n===-1&&(n=this.t.start),r=this.t.end}else{if(i===17&&e)return null;if(i===23){let e=n===-1?``:this.text(n,r,t);if(e.charCodeAt(0)===45&&e.charCodeAt(1)===45&&e.indexOf(`:`)!==-1)return this.skipBlock(23),null;let i=new RawRule(1,``,e,!0),a=this.t.end,o=this.lazyBlocks?flatBlockEnd(this.src,a):-1;return o===-1?this.consumeBlockContents(i):(i.lazy=this.src.slice(a,o),this.restore(o+1)),i}i!==13&&(n===-1&&(n=this.t.start),(i===2||i===21||i===19)&&this.skipBlock(i),r=this.t.end)}}}consumeBlockContents(e){for(;;){let t=this.advance();if(t===0||t===24)return;if(t===13||t===17)continue;if(t===3){let t=this.consumeAtRule(!0);t!==null&&e.rules.push(t);continue}let n=this.mark();if(t===1){let t=this.consumeDeclaration();if(t!==null){e.decls.push(t);let n=e.rules.length;if(n===0)e.leading=e.decls.length;else{let r=e.rules[n-1];r.kind!==3&&(r=new RawRule(3,``,``,!1),e.rules.push(r)),r.decls.push(t),r.leading=r.decls.length}continue}this.restore(n)}else this.reconsume();let r=this.consumeQualifiedRule(!0);r!==null&&e.rules.push(r)}}consumeDeclaration(){let e=this.t.value;if(this.advanceNonWs()!==16)return null;let t=this.t.comments;if(this.scanValue(),this.valueStart===-1)return e.charCodeAt(0)===45&&e.charCodeAt(1)===45?new RawDecl(e,``,this.important):new RawDecl(e,``,!1);let n=this.important?this.importantEnd:this.valueEnd,r=n<=this.valueStart?``:this.text(this.valueStart,n,t).trim();return(e.charCodeAt(0)!==45||e.charCodeAt(1)!==45)&&this.valueHasBlock&&this.valueOtherCount>0?null:new RawDecl(e,r,this.important)}scanValue(){this.valueStart=-1,this.valueEnd=-1,this.importantEnd=-1,this.important=!1,this.valueHasBlock=!1,this.valueOtherCount=0;let e=0,t=0,n=-1,r=-1,i=-1;for(;;){let a=this.advance();if(a===0||a===17)break;if(a===24){this.reconsume();break}if(a===13)continue;this.valueStart===-1&&(this.valueStart=this.t.start);let o=0;a===9&&this.t.value===`!`?o=1:a===1&&isAsciiCaseInsensitive(this.t.value,`important`)&&(o=2),a===23?this.valueHasBlock=!0:this.valueOtherCount++,(a===2||a===21||a===19||a===23)&&this.skipBlock(a),n=r,r=i,i=this.t.end,t=e,e=o}this.valueEnd=i,e===2&&t===1&&(this.important=!0,this.importantEnd=n===-1?this.valueStart:n,this.valueHasBlock&&(this.valueOtherCount-=2))}};function parseStylesheet(e){return new CSSParser(e).parseStylesheet()}function parseRule(e){let t=new CSSParser(e),n=t.advanceNonWs();if(n===0)return null;let r=null;return n===3?r=t.consumeAtRule(!1):(t.reconsume(),r=t.consumeQualifiedRule(!1)),r===null||(n=t.advanceNonWs(),n!==0)?null:r}function parseDeclarationList(e){let t=new CSSParser(e),n=new RawRule(1,``,``,!0);for(t.consumeBlockContents(n);t.t.type!==0;){let e=new RawRule(1,``,``,!0);t.consumeBlockContents(e);for(let t=0;t<e.decls.length;t++)n.decls.push(e.decls[t])}return n.decls}const Pc=[`-webkit-align-content`,0,``,``,`-webkit-align-items`,0,``,``,`-webkit-align-self`,0,``,``,`-webkit-animation`,0,``,`animation-name animation-duration animation-timing-function animation-delay animation-iteration-count animation-direction animation-fill-mode animation-play-state animation-timeline`,`-webkit-animation-delay`,0,``,``,`-webkit-animation-direction`,0,``,``,`-webkit-animation-duration`,0,``,``,`-webkit-animation-fill-mode`,0,``,``,`-webkit-animation-iteration-count`,0,``,``,`-webkit-animation-name`,0,``,``,`-webkit-animation-play-state`,0,``,``,`-webkit-animation-timing-function`,0,``,``,`-webkit-appearance`,0,``,``,`-webkit-backface-visibility`,0,``,``,`-webkit-background-clip`,0,``,``,`-webkit-background-origin`,0,``,``,`-webkit-background-size`,0,``,``,`-webkit-border-bottom-left-radius`,0,``,``,`-webkit-border-bottom-right-radius`,0,``,``,`-webkit-border-radius`,0,``,`border-top-left-radius border-top-right-radius border-bottom-right-radius border-bottom-left-radius`,`-webkit-border-top-left-radius`,0,``,``,`-webkit-border-top-right-radius`,0,``,``,`-webkit-box-align`,0,``,``,`-webkit-box-flex`,0,``,``,`-webkit-box-ordinal-group`,0,``,``,`-webkit-box-orient`,0,``,``,`-webkit-box-pack`,0,``,``,`-webkit-box-shadow`,0,``,`box-shadow-color box-shadow-offset box-shadow-blur box-shadow-spread box-shadow-position`,`-webkit-box-sizing`,0,``,``,`-webkit-filter`,0,``,``,`-webkit-flex`,0,``,`flex-grow flex-shrink flex-basis`,`-webkit-flex-basis`,0,``,``,`-webkit-flex-direction`,0,``,``,`-webkit-flex-flow`,0,``,`flex-direction flex-wrap`,`-webkit-flex-grow`,0,``,``,`-webkit-flex-shrink`,0,``,``,`-webkit-flex-wrap`,0,``,``,`-webkit-justify-content`,0,``,``,`-webkit-line-clamp`,0,`none`,`max-lines block-ellipsis continue`,`-webkit-mask`,0,``,`mask-image mask-position mask-size mask-repeat mask-origin mask-clip mask-composite mask-mode`,`-webkit-mask-box-image`,0,``,`mask-border-source mask-border-slice mask-border-width mask-border-outset mask-border-repeat mask-border-mode`,`-webkit-mask-box-image-outset`,0,``,``,`-webkit-mask-box-image-repeat`,0,``,``,`-webkit-mask-box-image-slice`,0,``,``,`-webkit-mask-box-image-source`,0,``,``,`-webkit-mask-box-image-width`,0,``,``,`-webkit-mask-clip`,0,``,``,`-webkit-mask-composite`,0,``,``,`-webkit-mask-image`,0,``,``,`-webkit-mask-origin`,0,``,``,`-webkit-mask-position`,0,``,``,`-webkit-mask-repeat`,0,``,``,`-webkit-mask-size`,0,``,``,`-webkit-order`,0,``,``,`-webkit-perspective`,0,``,``,`-webkit-perspective-origin`,0,``,``,`-webkit-text-fill-color`,1,`currentcolor`,``,`-webkit-text-size-adjust`,0,``,``,`-webkit-text-stroke`,1,``,`-webkit-text-stroke-width -webkit-text-stroke-color`,`-webkit-text-stroke-color`,1,`currentcolor`,``,`-webkit-text-stroke-width`,1,`0`,``,`-webkit-transform`,0,``,``,`-webkit-transform-origin`,0,``,``,`-webkit-transform-style`,0,``,``,`-webkit-transition`,0,``,`transition-property transition-duration transition-timing-function transition-delay transition-behavior`,`-webkit-transition-delay`,0,``,``,`-webkit-transition-duration`,0,``,``,`-webkit-transition-property`,0,``,``,`-webkit-transition-timing-function`,0,``,``,`-webkit-user-select`,0,``,``,`accent-color`,1,`auto`,``,`align-content`,0,`normal`,``,`align-items`,0,`normal`,``,`align-self`,0,`auto`,``,`alignment-baseline`,0,`baseline`,``,`all`,0,``,``,`anchor-name`,0,`none`,``,`anchor-scope`,0,`none`,``,`animation`,0,``,`animation-name animation-duration animation-timing-function animation-delay animation-iteration-count animation-direction animation-fill-mode animation-play-state animation-timeline`,`animation-composition`,0,`replace`,``,`animation-delay`,0,``,`animation-delay-start animation-delay-end`,`animation-delay-end`,0,`0s`,``,`animation-delay-start`,0,`0s`,``,`animation-direction`,0,`normal`,``,`animation-duration`,0,`auto`,``,`animation-fill-mode`,0,`none`,``,`animation-iteration-count`,0,`1`,``,`animation-name`,0,`none`,``,`animation-play-state`,0,`running`,``,`animation-range`,0,``,`animation-range-start animation-range-end`,`animation-range-center`,0,`normal`,``,`animation-range-end`,0,`normal`,``,`animation-range-start`,0,`normal`,``,`animation-timeline`,0,`auto`,``,`animation-timing-function`,0,`ease`,``,`animation-trigger`,0,`none`,``,`appearance`,0,`none`,``,`aspect-ratio`,0,`auto`,``,`backdrop-filter`,0,`none`,``,`backface-visibility`,0,`visible`,``,`background`,0,``,`background-image background-position background-size background-repeat background-attachment background-origin background-clip background-color`,`background-attachment`,0,`scroll`,``,`background-blend-mode`,0,`normal`,``,`background-clip`,0,`border-box`,``,`background-color`,0,`transparent`,``,`background-image`,0,`none`,``,`background-origin`,0,`padding-box`,``,`background-position`,0,`0% 0%`,`background-position-x background-position-y`,`background-position-block`,0,`0%`,``,`background-position-inline`,0,`0%`,``,`background-position-x`,0,`0%`,``,`background-position-y`,0,`0%`,``,`background-repeat`,0,`repeat`,``,`background-repeat-block`,0,`repeat`,``,`background-repeat-inline`,0,`repeat`,``,`background-repeat-x`,0,`repeat`,``,`background-repeat-y`,0,`repeat`,``,`background-size`,0,`auto`,``,`background-tbd`,0,``,``,`baseline-shift`,0,`0`,``,`baseline-source`,0,`auto`,``,`block-ellipsis`,1,`no-ellipsis`,``,`block-size`,0,`auto`,``,`block-step`,0,``,`block-step-size block-step-insert block-step-align block-step-round`,`block-step-align`,0,`auto`,``,`block-step-insert`,0,`margin-box`,``,`block-step-round`,0,`up`,``,`block-step-size`,0,`none`,``,`bookmark-label`,0,`content(text)`,``,`bookmark-level`,0,`none`,``,`bookmark-state`,0,`open`,``,`border`,0,``,`border-width border-style border-color`,`border-block`,0,``,`border-block-start border-block-end`,`border-block-clip`,0,``,`border-block-start-clip border-block-end-clip`,`border-block-color`,0,``,`border-block-start-color border-block-end-color`,`border-block-end`,0,``,`border-block-end-width border-block-end-style border-block-end-color`,`border-block-end-clip`,0,`none`,``,`border-block-end-color`,0,`currentcolor`,``,`border-block-end-radius`,0,`0`,`border-end-start-radius border-end-end-radius`,`border-block-end-style`,0,`none`,``,`border-block-end-width`,0,`medium`,``,`border-block-start`,0,``,`border-block-start-width border-block-start-style border-block-start-color`,`border-block-start-clip`,0,`none`,``,`border-block-start-color`,0,`currentcolor`,``,`border-block-start-radius`,0,`0`,`border-start-start-radius border-start-end-radius`,`border-block-start-style`,0,`none`,``,`border-block-start-width`,0,`medium`,``,`border-block-style`,0,``,`border-block-start-style border-block-end-style`,`border-block-width`,0,``,`border-block-start-width border-block-end-width`,`border-bottom`,0,``,`border-bottom-width border-bottom-style border-bottom-color`,`border-bottom-clip`,0,`none`,``,`border-bottom-color`,0,`currentcolor`,``,`border-bottom-left-radius`,0,`0`,``,`border-bottom-radius`,0,`0`,`border-bottom-left-radius border-bottom-right-radius`,`border-bottom-right-radius`,0,`0`,``,`border-bottom-style`,0,`none`,``,`border-bottom-width`,0,`medium`,``,`border-boundary`,1,`none`,``,`border-clip`,0,``,`border-top-clip border-right-clip border-bottom-clip border-left-clip`,`border-collapse`,1,`separate`,``,`border-color`,0,``,`border-top-color border-right-color border-bottom-color border-left-color`,`border-end-end-radius`,0,`0`,``,`border-end-start-radius`,0,`0`,``,`border-image`,0,``,`border-image-source border-image-slice border-image-width border-image-outset border-image-repeat`,`border-image-outset`,0,`0`,``,`border-image-repeat`,0,`stretch`,``,`border-image-slice`,0,`100%`,``,`border-image-source`,0,`none`,``,`border-image-width`,0,`1`,``,`border-inline`,0,``,`border-inline-start border-inline-end`,`border-inline-clip`,0,``,`border-inline-start-clip border-inline-end-clip`,`border-inline-color`,0,``,`border-inline-start-color border-inline-end-color`,`border-inline-end`,0,``,`border-inline-end-width border-inline-end-style border-inline-end-color`,`border-inline-end-clip`,0,`none`,``,`border-inline-end-color`,0,`currentcolor`,``,`border-inline-end-radius`,0,`0`,`border-start-end-radius border-end-end-radius`,`border-inline-end-style`,0,`none`,``,`border-inline-end-width`,0,`medium`,``,`border-inline-start`,0,``,`border-inline-start-width border-inline-start-style border-inline-start-color`,`border-inline-start-clip`,0,`none`,``,`border-inline-start-color`,0,`currentcolor`,``,`border-inline-start-radius`,0,`0`,`border-start-start-radius border-end-start-radius`,`border-inline-start-style`,0,`none`,``,`border-inline-start-width`,0,`medium`,``,`border-inline-style`,0,``,`border-inline-start-style border-inline-end-style`,`border-inline-width`,0,``,`border-inline-start-width border-inline-end-width`,`border-left`,0,``,`border-left-width border-left-style border-left-color`,`border-left-clip`,0,`none`,``,`border-left-color`,0,`currentcolor`,``,`border-left-radius`,0,`0`,`border-top-left-radius border-bottom-left-radius`,`border-left-style`,0,`none`,``,`border-left-width`,0,`medium`,``,`border-limit`,0,`all`,``,`border-radius`,0,``,`border-top-left-radius border-top-right-radius border-bottom-right-radius border-bottom-left-radius`,`border-right`,0,``,`border-right-width border-right-style border-right-color`,`border-right-clip`,0,`none`,``,`border-right-color`,0,`currentcolor`,``,`border-right-radius`,0,`0`,`border-top-right-radius border-bottom-right-radius`,`border-right-style`,0,`none`,``,`border-right-width`,0,`medium`,``,`border-shape`,0,`none`,``,`border-spacing`,1,`0px 0px`,``,`border-start-end-radius`,0,`0`,``,`border-start-start-radius`,0,`0`,``,`border-style`,0,``,`border-top-style border-right-style border-bottom-style border-left-style`,`border-top`,0,``,`border-top-width border-top-style border-top-color`,`border-top-clip`,0,`none`,``,`border-top-color`,0,`currentcolor`,``,`border-top-left-radius`,0,`0`,``,`border-top-radius`,0,`0`,`border-top-left-radius border-top-right-radius`,`border-top-right-radius`,0,`0`,``,`border-top-style`,0,`none`,``,`border-top-width`,0,`medium`,``,`border-width`,0,``,`border-top-width border-right-width border-bottom-width border-left-width`,`bottom`,0,`auto`,``,`box-decoration-break`,0,`slice`,``,`box-shadow`,0,`none`,`box-shadow-color box-shadow-offset box-shadow-blur box-shadow-spread box-shadow-position`,`box-shadow-blur`,0,`0`,``,`box-shadow-color`,0,`currentcolor`,``,`box-shadow-offset`,0,`none`,``,`box-shadow-position`,0,`outset`,``,`box-shadow-spread`,0,`0`,``,`box-sizing`,0,`content-box`,``,`box-snap`,1,`none`,``,`break-after`,0,`auto`,``,`break-before`,0,`auto`,``,`break-inside`,0,`auto`,``,`caption-side`,1,`top`,``,`caret`,1,`auto`,`caret-color caret-animation caret-shape`,`caret-animation`,1,`auto`,``,`caret-color`,1,`auto`,``,`caret-shape`,1,`auto`,``,`clear`,0,`none`,``,`clip`,0,`auto`,``,`clip-path`,0,`none`,``,`clip-rule`,1,`nonzero`,``,`color`,1,`CanvasText`,``,`color-adjust`,0,``,`print-color-adjust`,`color-interpolation`,1,`sRGB`,``,`color-interpolation-filters`,1,`linearRGB`,``,`color-scheme`,1,`normal`,``,`column-count`,0,`auto`,``,`column-fill`,0,`balance`,``,`column-gap`,0,`normal`,``,`column-height`,0,`auto`,``,`column-rule`,0,``,`column-rule-width column-rule-style column-rule-color`,`column-rule-break`,0,`normal`,``,`column-rule-color`,0,`currentcolor`,``,`column-rule-inset`,0,``,`column-rule-inset-cap-start column-rule-inset-cap-end column-rule-inset-junction-start column-rule-inset-junction-end`,`column-rule-inset-cap`,0,``,`column-rule-inset-cap-start column-rule-inset-cap-end`,`column-rule-inset-cap-end`,0,`0`,``,`column-rule-inset-cap-start`,0,`0`,``,`column-rule-inset-end`,0,``,`column-rule-inset-cap-end column-rule-inset-junction-end`,`column-rule-inset-junction`,0,``,`column-rule-inset-junction-start column-rule-inset-junction-end`,`column-rule-inset-junction-end`,0,`0`,``,`column-rule-inset-junction-start`,0,`0`,``,`column-rule-inset-start`,0,``,`column-rule-inset-cap-start column-rule-inset-junction-start`,`column-rule-style`,0,`none`,``,`column-rule-visibility-items`,0,`normal`,``,`column-rule-width`,0,`medium`,``,`column-span`,0,`none`,``,`column-width`,0,``,``,`column-wrap`,0,`auto`,``,`columns`,0,``,`column-width column-count column-height`,`contain`,0,`none`,``,`contain-intrinsic-block-size`,0,`none`,``,`contain-intrinsic-height`,0,`none`,``,`contain-intrinsic-inline-size`,0,`none`,``,`contain-intrinsic-size`,0,``,`contain-intrinsic-width contain-intrinsic-height`,`contain-intrinsic-width`,0,`none`,``,`container`,0,``,`container-name container-type`,`container-name`,0,`none`,``,`container-type`,0,`normal`,``,`content`,0,`normal`,``,`content-visibility`,0,`visible`,``,`continue`,0,`auto`,``,`copy-into`,0,`none`,``,`corner`,0,`0`,`border-radius corner-shape`,`corner-block-end`,0,`0`,`border-block-end-radius corner-block-end-shape`,`corner-block-end-shape`,0,``,`corner-end-start-shape corner-end-end-shape`,`corner-block-start`,0,`0`,`border-block-start-radius corner-block-start-shape`,`corner-block-start-shape`,0,``,`corner-start-start-shape corner-start-end-shape`,`corner-bottom`,0,`0`,`border-bottom-radius corner-bottom-shape`,`corner-bottom-left`,0,`0`,`border-bottom-left-radius corner-bottom-left-shape`,`corner-bottom-left-shape`,0,`round`,``,`corner-bottom-right`,0,`0`,`border-bottom-right-radius corner-bottom-right-shape`,`corner-bottom-right-shape`,0,`round`,``,`corner-bottom-shape`,0,``,`corner-bottom-left-shape corner-bottom-right-shape`,`corner-end-end`,0,`0`,`border-end-end-radius corner-end-end-shape`,`corner-end-end-shape`,0,`round`,``,`corner-end-start`,0,`0`,`border-end-start-radius corner-end-start-shape`,`corner-end-start-shape`,0,`round`,``,`corner-inline-end`,0,`0`,`border-inline-end-radius corner-inline-end-shape`,`corner-inline-end-shape`,0,``,`corner-start-end-shape corner-end-end-shape`,`corner-inline-start`,0,`0`,`border-inline-start-radius corner-inline-start-shape`,`corner-inline-start-shape`,0,``,`corner-start-start-shape corner-end-start-shape`,`corner-left`,0,`0`,`border-left-radius corner-left-shape`,`corner-left-shape`,0,``,`corner-top-left-shape corner-bottom-left-shape`,`corner-right`,0,`0`,`border-right-radius corner-right-shape`,`corner-right-shape`,0,``,`corner-top-right-shape corner-bottom-right-shape`,`corner-shape`,0,`round`,`corner-top-left-shape corner-top-right-shape corner-bottom-right-shape corner-bottom-left-shape`,`corner-start-end`,0,`0`,`border-start-end-radius corner-start-end-shape`,`corner-start-end-shape`,0,`round`,``,`corner-start-start`,0,`0`,`border-start-start-radius corner-start-start-shape`,`corner-start-start-shape`,0,`round`,``,`corner-top`,0,`0`,`border-top-radius corner-top-shape`,`corner-top-left`,0,`0`,`border-top-left-radius corner-top-left-shape`,`corner-top-left-shape`,0,`round`,``,`corner-top-right`,0,`0`,`border-top-right-radius corner-top-right-shape`,`corner-top-right-shape`,0,`round`,``,`corner-top-shape`,0,``,`corner-top-left-shape corner-top-right-shape`,`counter-increment`,0,`none`,``,`counter-reset`,0,`none`,``,`counter-set`,0,`none`,``,`cue`,0,``,`cue-before cue-after`,`cue-after`,0,`none`,``,`cue-before`,0,`none`,``,`cursor`,1,`auto`,``,`cx`,0,`0`,``,`cy`,0,`0`,``,`d`,0,`none`,``,`direction`,1,`ltr`,``,`display`,0,`inline`,``,`dominant-baseline`,1,`auto`,``,`dynamic-range-limit`,1,`no-limit`,``,`empty-cells`,1,`show`,``,`event-trigger`,0,`none`,``,`event-trigger-name`,0,`none`,``,`event-trigger-source`,0,`none`,``,`field-sizing`,0,`fixed`,``,`fill`,1,`black`,``,`fill-break`,0,`bounding-box`,``,`fill-color`,1,`currentcolor`,``,`fill-image`,1,`none`,``,`fill-opacity`,1,`1`,``,`fill-origin`,0,`match-parent`,``,`fill-position`,1,`0% 0%`,``,`fill-repeat`,1,`repeat`,``,`fill-rule`,1,`nonzero`,``,`fill-size`,1,`auto`,``,`filter`,0,`none`,``,`flex`,0,`0 1 auto`,`flex-grow flex-shrink flex-basis`,`flex-basis`,0,`auto`,``,`flex-direction`,0,`row`,``,`flex-flow`,0,``,`flex-direction flex-wrap`,`flex-grow`,0,`0`,``,`flex-line-count`,0,`1`,``,`flex-shrink`,0,`1`,``,`flex-wrap`,0,`nowrap`,``,`float`,0,`none`,``,`float-defer`,0,`none`,``,`float-offset`,0,`0`,``,`float-reference`,0,`inline`,``,`flood-color`,0,`black`,``,`flood-opacity`,0,`1`,``,`flow-from`,0,`none`,``,`flow-into`,0,`none`,``,`flow-tolerance`,0,`normal`,``,`font`,1,``,`font-style font-variant font-weight font-stretch font-size line-height font-family`,`font-family`,1,``,``,`font-feature-settings`,1,`normal`,``,`font-kerning`,1,`auto`,``,`font-language-override`,1,`normal`,``,`font-optical-sizing`,1,`auto`,``,`font-palette`,1,`normal`,``,`font-size`,1,`medium`,``,`font-size-adjust`,1,`none`,``,`font-stretch`,0,``,``,`font-style`,1,`normal`,``,`font-synthesis`,1,`weight style small-caps position`,`font-synthesis-weight font-synthesis-style font-synthesis-small-caps`,`font-synthesis-position`,1,`auto`,``,`font-synthesis-small-caps`,1,`auto`,``,`font-synthesis-style`,1,`auto`,``,`font-synthesis-weight`,1,`auto`,``,`font-variant`,1,`normal`,`font-variant-ligatures font-variant-caps font-variant-alternates font-variant-numeric font-variant-east-asian font-variant-position font-variant-emoji`,`font-variant-alternates`,1,`normal`,``,`font-variant-caps`,1,`normal`,``,`font-variant-east-asian`,1,`normal`,``,`font-variant-emoji`,1,`normal`,``,`font-variant-ligatures`,1,`normal`,``,`font-variant-numeric`,1,`normal`,``,`font-variant-position`,1,`normal`,``,`font-variation-settings`,1,`normal`,``,`font-weight`,1,`normal`,``,`font-width`,1,`normal`,``,`footnote-display`,0,`block`,``,`footnote-policy`,0,`auto`,``,`forced-color-adjust`,1,`auto`,``,`frame-sizing`,0,`auto`,``,`gap`,0,``,`row-gap column-gap`,`glyph-orientation-vertical`,0,``,``,`grid`,0,`none`,`grid-template-rows grid-template-columns grid-template-areas grid-auto-rows grid-auto-columns grid-auto-flow`,`grid-area`,0,`auto`,`grid-row-start grid-column-start grid-row-end grid-column-end`,`grid-auto-columns`,0,`auto`,``,`grid-auto-flow`,0,`row`,``,`grid-auto-rows`,0,`auto`,``,`grid-column`,0,`auto`,`grid-column-start grid-column-end`,`grid-column-end`,0,`auto`,``,`grid-column-gap`,0,``,``,`grid-column-start`,0,`auto`,``,`grid-gap`,0,``,`row-gap column-gap`,`grid-row`,0,`auto`,`grid-row-start grid-row-end`,`grid-row-end`,0,`auto`,``,`grid-row-gap`,0,``,``,`grid-row-start`,0,`auto`,``,`grid-template`,0,`none`,`grid-template-rows grid-template-columns grid-template-areas`,`grid-template-areas`,0,`none`,``,`grid-template-columns`,0,`none`,``,`grid-template-rows`,0,`none`,``,`hanging-punctuation`,1,`none`,``,`height`,0,`auto`,``,`hyphenate-character`,1,`auto`,``,`hyphenate-limit-chars`,1,`auto`,``,`hyphenate-limit-last`,1,`none`,``,`hyphenate-limit-lines`,1,`no-limit`,``,`hyphenate-limit-zone`,1,`0`,``,`hyphens`,1,`manual`,``,`image-animation`,1,`normal`,``,`image-orientation`,1,`from-image`,``,`image-rendering`,1,`auto`,``,`image-resolution`,1,`1dppx`,``,`initial-letter`,0,`normal`,``,`initial-letter-align`,1,`alphabetic`,``,`initial-letter-wrap`,1,`none`,``,`inline-size`,0,`auto`,``,`inline-sizing`,1,`normal`,``,`input-security`,0,`auto`,``,`inset`,0,`auto`,`top right bottom left`,`inset-block`,0,`auto`,`inset-block-start inset-block-end`,`inset-block-end`,0,`auto`,``,`inset-block-start`,0,`auto`,``,`inset-inline`,0,`auto`,`inset-inline-start inset-inline-end`,`inset-inline-end`,0,`auto`,``,`inset-inline-start`,0,`auto`,``,`interactivity`,1,`auto`,``,`interest-delay`,0,``,`interest-delay-start interest-delay-end`,`interest-delay-end`,1,`normal`,``,`interest-delay-start`,1,`normal`,``,`interpolate-size`,1,`numeric-only`,``,`isolation`,0,`auto`,``,`justify-content`,0,`normal`,``,`justify-items`,0,`legacy`,``,`justify-self`,0,`auto`,``,`left`,0,`auto`,``,`letter-spacing`,1,`normal`,``,`lighting-color`,0,`white`,``,`line-break`,1,`auto`,``,`line-clamp`,0,`none`,`max-lines block-ellipsis continue`,`line-fit-edge`,1,`leading`,``,`line-grid`,0,`match-parent`,``,`line-height`,1,`normal`,``,`line-height-step`,1,`0`,``,`line-padding`,1,`0`,``,`line-snap`,1,`none`,``,`link-parameters`,0,`none`,``,`list-style`,0,``,`list-style-type list-style-position list-style-image`,`list-style-image`,1,`none`,``,`list-style-position`,1,`outside`,``,`list-style-type`,1,`disc`,``,`margin`,0,`0`,`margin-top margin-right margin-bottom margin-left`,`margin-block`,0,``,`margin-block-start margin-block-end`,`margin-block-end`,0,`0`,``,`margin-block-start`,0,`0`,``,`margin-bottom`,0,`0`,``,`margin-break`,0,`auto`,``,`margin-inline`,0,``,`margin-inline-start margin-inline-end`,`margin-inline-end`,0,`0`,``,`margin-inline-start`,0,`0`,``,`margin-left`,0,`0`,``,`margin-right`,0,`0`,``,`margin-top`,0,`0`,``,`margin-trim`,0,`none`,``,`marker`,1,``,`marker-start marker-mid marker-end`,`marker-end`,1,`none`,``,`marker-mid`,1,`none`,``,`marker-side`,1,`match-self`,``,`marker-start`,1,`none`,``,`mask`,0,``,`mask-image mask-position mask-size mask-repeat mask-origin mask-clip mask-composite mask-mode`,`mask-border`,0,``,`mask-border-source mask-border-slice mask-border-width mask-border-outset mask-border-repeat mask-border-mode`,`mask-border-mode`,0,`alpha`,``,`mask-border-outset`,0,`0`,``,`mask-border-repeat`,0,`stretch`,``,`mask-border-slice`,0,`0`,``,`mask-border-source`,0,`none`,``,`mask-border-width`,0,`auto`,``,`mask-clip`,0,`border-box`,``,`mask-composite`,0,`add`,``,`mask-image`,0,`none`,``,`mask-mode`,0,`match-source`,``,`mask-origin`,0,`border-box`,``,`mask-position`,0,`0% 0%`,``,`mask-repeat`,0,`repeat`,``,`mask-size`,0,`auto`,``,`mask-type`,0,`luminance`,``,`math-depth`,1,`0`,``,`math-shift`,1,`normal`,``,`math-style`,1,`normal`,``,`max-block-size`,0,`none`,``,`max-height`,0,`none`,``,`max-inline-size`,0,`none`,``,`max-lines`,0,`none`,``,`max-size`,0,`none`,`max-width max-height`,`max-width`,0,`none`,``,`min-block-size`,0,`auto`,``,`min-height`,0,`auto`,``,`min-inline-size`,0,`auto`,``,`min-intrinsic-sizing`,0,`legacy`,``,`min-size`,0,`auto`,`min-width min-height`,`min-width`,0,`auto`,``,`mix-blend-mode`,0,`normal`,``,`nav-down`,0,`auto`,``,`nav-left`,0,`auto`,``,`nav-right`,0,`auto`,``,`nav-up`,0,`auto`,``,`object-fit`,0,`fill`,``,`object-position`,0,`50% 50%`,``,`object-view-box`,0,`none`,``,`offset`,0,``,`offset-path offset-distance offset-rotate offset-anchor offset-position`,`offset-anchor`,0,`auto`,``,`offset-distance`,0,`0`,``,`offset-path`,0,`none`,``,`offset-position`,0,`normal`,``,`offset-rotate`,0,`auto`,``,`opacity`,0,`1`,``,`order`,0,`0`,``,`orphans`,1,`2`,``,`outline`,0,``,`outline-width outline-style outline-color`,`outline-color`,0,`auto`,``,`outline-offset`,0,`0`,``,`outline-style`,0,`none`,``,`outline-width`,0,`medium`,``,`overflow`,0,`visible`,`overflow-x overflow-y`,`overflow-anchor`,0,`auto`,``,`overflow-block`,0,`visible`,``,`overflow-clip-margin`,0,`0px`,`overflow-clip-margin-top overflow-clip-margin-right overflow-clip-margin-bottom overflow-clip-margin-left`,`overflow-clip-margin-block`,0,`0px`,`overflow-clip-margin-block-start overflow-clip-margin-block-end`,`overflow-clip-margin-block-end`,0,`0px`,``,`overflow-clip-margin-block-start`,0,`0px`,``,`overflow-clip-margin-bottom`,0,`0px`,``,`overflow-clip-margin-inline`,0,`0px`,`overflow-clip-margin-inline-start overflow-clip-margin-inline-end`,`overflow-clip-margin-inline-end`,0,`0px`,``,`overflow-clip-margin-inline-start`,0,`0px`,``,`overflow-clip-margin-left`,0,`0px`,``,`overflow-clip-margin-right`,0,`0px`,``,`overflow-clip-margin-top`,0,`0px`,``,`overflow-inline`,0,`visible`,``,`overflow-wrap`,1,`normal`,``,`overflow-x`,0,`visible`,``,`overflow-y`,0,`visible`,``,`overlay`,0,`none`,``,`overscroll-behavior`,0,`auto auto`,`overscroll-behavior-x overscroll-behavior-y`,`overscroll-behavior-block`,0,`auto`,``,`overscroll-behavior-inline`,0,`auto`,``,`overscroll-behavior-x`,0,`auto`,``,`overscroll-behavior-y`,0,`auto`,``,`padding`,0,`0`,`padding-top padding-right padding-bottom padding-left`,`padding-block`,0,``,`padding-block-start padding-block-end`,`padding-block-end`,0,`0`,``,`padding-block-start`,0,`0`,``,`padding-bottom`,0,`0`,``,`padding-inline`,0,``,`padding-inline-start padding-inline-end`,`padding-inline-end`,0,`0`,``,`padding-inline-start`,0,`0`,``,`padding-left`,0,`0`,``,`padding-right`,0,`0`,``,`padding-top`,0,`0`,``,`page`,0,`auto`,``,`page-break-after`,0,`auto`,``,`page-break-before`,0,`auto`,``,`page-break-inside`,0,`auto`,``,`paint-order`,1,`normal`,``,`path-length`,0,`none`,``,`pause`,0,``,`pause-before pause-after`,`pause-after`,0,`none`,``,`pause-before`,0,`none`,``,`perspective`,0,`none`,``,`perspective-origin`,0,`50% 50%`,``,`place-content`,0,`normal`,`align-content justify-content`,`place-items`,0,``,`align-items justify-items`,`place-self`,0,`auto`,`align-self justify-self`,`pointer-events`,1,`auto`,``,`pointer-timeline`,0,``,`pointer-timeline-name pointer-timeline-axis`,`pointer-timeline-axis`,0,`block`,``,`pointer-timeline-name`,0,`none`,``,`position`,0,`static`,``,`position-anchor`,0,`normal`,``,`position-area`,0,`none`,``,`position-try`,0,``,`position-try-order position-try-fallbacks`,`position-try-fallbacks`,0,`none`,``,`position-try-order`,0,`normal`,``,`position-visibility`,0,`anchor-visible`,``,`print-color-adjust`,1,`economy`,``,`quotes`,1,`auto`,``,`r`,0,`0`,``,`reading-flow`,0,`normal`,``,`reading-order`,0,`0`,``,`region-fragment`,0,`auto`,``,`resize`,0,`none`,``,`rest`,0,``,`rest-before rest-after`,`rest-after`,0,`none`,``,`rest-before`,0,`none`,``,`right`,0,`auto`,``,`rotate`,0,`none`,``,`row-gap`,0,`normal`,``,`row-rule`,0,``,`row-rule-width row-rule-style row-rule-color`,`row-rule-break`,0,`normal`,``,`row-rule-color`,0,`currentcolor`,``,`row-rule-inset`,0,``,`row-rule-inset-cap-start row-rule-inset-cap-end row-rule-inset-junction-start row-rule-inset-junction-end`,`row-rule-inset-cap`,0,``,`row-rule-inset-cap-start row-rule-inset-cap-end`,`row-rule-inset-cap-end`,0,`0`,``,`row-rule-inset-cap-start`,0,`0`,``,`row-rule-inset-end`,0,``,`row-rule-inset-cap-end row-rule-inset-junction-end`,`row-rule-inset-junction`,0,``,`row-rule-inset-junction-start row-rule-inset-junction-end`,`row-rule-inset-junction-end`,0,`0`,``,`row-rule-inset-junction-start`,0,`0`,``,`row-rule-inset-start`,0,``,`row-rule-inset-cap-start row-rule-inset-junction-start`,`row-rule-style`,0,`none`,``,`row-rule-visibility-items`,0,`normal`,``,`row-rule-width`,0,`medium`,``,`ruby-align`,1,`space-around`,``,`ruby-merge`,1,`separate`,``,`ruby-overhang`,1,`auto`,``,`ruby-position`,1,`alternate`,``,`rule`,0,``,`column-rule row-rule`,`rule-break`,0,``,`column-rule-break row-rule-break`,`rule-color`,0,``,`column-rule-color row-rule-color`,`rule-inset`,0,``,`column-rule-inset row-rule-inset`,`rule-inset-cap`,0,``,`column-rule-inset-cap`,`rule-inset-end`,0,``,`column-rule-inset-end row-rule-inset-end`,`rule-inset-junction`,0,``,`column-rule-inset-junction`,`rule-inset-start`,0,``,`column-rule-inset-start row-rule-inset-start`,`rule-overlap`,0,`row-over-column`,``,`rule-style`,0,``,`column-rule-style row-rule-style`,`rule-visibility-items`,0,``,`column-rule-visibility-items`,`rule-width`,0,``,`column-rule-width row-rule-width`,`rx`,0,`auto`,``,`ry`,0,`auto`,``,`scale`,0,`none`,``,`scroll-axis-lock`,0,`auto`,``,`scroll-behavior`,0,`auto`,``,`scroll-initial-target`,0,`none`,``,`scroll-margin`,0,`0`,`scroll-margin-top scroll-margin-right scroll-margin-bottom scroll-margin-left`,`scroll-margin-block`,0,`0`,`scroll-margin-block-start scroll-margin-block-end`,`scroll-margin-block-end`,0,`0`,``,`scroll-margin-block-start`,0,`0`,``,`scroll-margin-bottom`,0,`0`,``,`scroll-margin-inline`,0,`0`,`scroll-margin-inline-start scroll-margin-inline-end`,`scroll-margin-inline-end`,0,`0`,``,`scroll-margin-inline-start`,0,`0`,``,`scroll-margin-left`,0,`0`,``,`scroll-margin-right`,0,`0`,``,`scroll-margin-top`,0,`0`,``,`scroll-marker-group`,0,`none`,``,`scroll-padding`,0,`auto`,`scroll-padding-top scroll-padding-right scroll-padding-bottom scroll-padding-left`,`scroll-padding-block`,0,`auto`,`scroll-padding-block-start scroll-padding-block-end`,`scroll-padding-block-end`,0,`auto`,``,`scroll-padding-block-start`,0,`auto`,``,`scroll-padding-bottom`,0,`auto`,``,`scroll-padding-inline`,0,`auto`,`scroll-padding-inline-start scroll-padding-inline-end`,`scroll-padding-inline-end`,0,`auto`,``,`scroll-padding-inline-start`,0,`auto`,``,`scroll-padding-left`,0,`auto`,``,`scroll-padding-right`,0,`auto`,``,`scroll-padding-top`,0,`auto`,``,`scroll-snap-align`,0,`none`,``,`scroll-snap-stop`,0,`normal`,``,`scroll-snap-type`,0,`none`,``,`scroll-target-group`,0,`none`,``,`scroll-timeline`,0,``,`scroll-timeline-name scroll-timeline-axis`,`scroll-timeline-axis`,0,`block`,``,`scroll-timeline-name`,0,`none`,``,`scrollbar-color`,1,`auto`,``,`scrollbar-gutter`,0,`auto`,``,`scrollbar-width`,0,`auto`,``,`shape-image-threshold`,0,`0`,``,`shape-inside`,0,`auto`,``,`shape-margin`,0,`0`,``,`shape-outside`,0,`none`,``,`shape-padding`,0,`0`,``,`shape-rendering`,1,`auto`,``,`size`,0,`auto`,`width height`,`slider-orientation`,0,`auto`,``,`spatial-navigation-action`,0,`auto`,``,`spatial-navigation-contain`,0,`auto`,``,`spatial-navigation-function`,0,`normal`,``,`speak`,1,`auto`,``,`speak-as`,1,`normal`,``,`stop-color`,0,``,``,`stop-opacity`,0,``,``,`string-set`,0,`none`,``,`stroke`,1,`none`,``,`stroke-align`,1,`center`,``,`stroke-alignment`,1,`center`,``,`stroke-break`,0,`bounding-box`,``,`stroke-color`,1,`transparent`,``,`stroke-dash-corner`,1,`none`,``,`stroke-dash-justify`,1,`none`,``,`stroke-dashadjust`,1,`none`,``,`stroke-dasharray`,1,`none`,``,`stroke-dashcorner`,1,`none`,``,`stroke-dashoffset`,1,`0`,``,`stroke-image`,1,`none`,``,`stroke-linecap`,1,`butt`,``,`stroke-linejoin`,1,`miter`,``,`stroke-miterlimit`,1,`4`,``,`stroke-opacity`,1,`1`,``,`stroke-origin`,0,`match-parent`,``,`stroke-position`,1,`0% 0%`,``,`stroke-repeat`,1,`repeat`,``,`stroke-size`,1,`auto`,``,`stroke-width`,1,`1px`,``,`tab-size`,1,`8`,``,`table-layout`,0,`auto`,``,`text-align`,1,`start`,`text-align-all text-align-last`,`text-align-all`,1,`start`,``,`text-align-last`,1,`auto`,``,`text-anchor`,1,`start`,``,`text-autospace`,1,`normal`,``,`text-box`,0,`normal`,``,`text-box-edge`,1,`auto`,``,`text-box-trim`,0,`none`,``,`text-combine-upright`,1,`none`,``,`text-decoration`,0,``,`text-decoration-line text-decoration-thickness text-decoration-style text-decoration-color`,`text-decoration-color`,0,`currentcolor`,``,`text-decoration-inset`,0,`0`,``,`text-decoration-line`,0,`none`,``,`text-decoration-skip`,1,``,`text-decoration-skip-self text-decoration-skip-box text-decoration-skip-spaces text-decoration-skip-ink`,`text-decoration-skip-box`,1,`none`,``,`text-decoration-skip-ink`,1,`auto`,``,`text-decoration-skip-self`,0,`auto`,``,`text-decoration-skip-spaces`,1,`start end`,``,`text-decoration-style`,0,`solid`,``,`text-decoration-thickness`,0,`auto`,``,`text-emphasis`,0,``,`text-emphasis-style text-emphasis-color`,`text-emphasis-color`,1,`currentcolor`,``,`text-emphasis-position`,1,`over right`,``,`text-emphasis-skip`,1,`spaces punctuation`,``,`text-emphasis-style`,1,`none`,``,`text-fit`,1,`none`,``,`text-group-align`,0,`none`,``,`text-indent`,1,`0`,``,`text-justify`,1,`auto`,``,`text-orientation`,1,`mixed`,``,`text-overflow`,0,`clip`,``,`text-rendering`,1,`auto`,``,`text-shadow`,1,`none`,``,`text-size-adjust`,1,`auto`,``,`text-spacing`,1,``,`text-spacing-trim text-autospace`,`text-spacing-trim`,1,`normal`,``,`text-transform`,1,`none`,``,`text-underline-offset`,1,`auto`,``,`text-underline-position`,1,`auto`,``,`text-wrap`,0,`wrap`,`text-wrap-mode text-wrap-style`,`text-wrap-mode`,1,`wrap`,``,`text-wrap-style`,1,`auto`,``,`timeline-scope`,0,`none`,``,`timeline-trigger`,0,``,`timeline-trigger-name timeline-trigger-source timeline-trigger-activation-range timeline-trigger-active-range`,`timeline-trigger-activation-range`,0,``,`timeline-trigger-activation-range-start timeline-trigger-activation-range-end`,`timeline-trigger-activation-range-end`,0,`normal`,``,`timeline-trigger-activation-range-start`,0,`normal`,``,`timeline-trigger-active-range`,0,``,`timeline-trigger-active-range-start timeline-trigger-active-range-end`,`timeline-trigger-active-range-end`,0,`auto`,``,`timeline-trigger-active-range-start`,0,`auto`,``,`timeline-trigger-name`,0,`none`,``,`timeline-trigger-source`,0,`auto`,``,`top`,0,`auto`,``,`touch-action`,0,`auto`,``,`transform`,0,`none`,``,`transform-box`,0,`view-box`,``,`transform-origin`,0,`50% 50%`,``,`transform-style`,0,`flat`,``,`transition`,0,``,`transition-property transition-duration transition-timing-function transition-delay transition-behavior`,`transition-behavior`,0,`normal`,``,`transition-delay`,0,`0s`,``,`transition-duration`,0,`0s`,``,`transition-property`,0,`all`,``,`transition-timing-function`,0,`ease`,``,`translate`,0,`none`,``,`trigger-scope`,0,`none`,``,`unicode-bidi`,0,`normal`,``,`user-select`,0,`auto`,``,`vector-effect`,0,`none`,``,`vertical-align`,0,`baseline`,`alignment-baseline baseline-shift baseline-source`,`view-timeline`,0,``,`view-timeline-name view-timeline-axis`,`view-timeline-axis`,0,`block`,``,`view-timeline-inset`,0,`auto`,``,`view-timeline-name`,0,`none`,``,`view-transition-class`,0,`none`,``,`view-transition-group`,0,`normal`,``,`view-transition-name`,0,`none`,``,`view-transition-scope`,0,`none`,``,`visibility`,1,`visible`,``,`voice-balance`,1,`center`,``,`voice-duration`,0,`auto`,``,`voice-family`,1,`implementation-dependent`,``,`voice-pitch`,1,`medium`,``,`voice-range`,1,`medium`,``,`voice-rate`,1,`normal`,``,`voice-stress`,1,`normal`,``,`voice-volume`,1,`medium`,``,`white-space`,0,`normal`,`white-space-collapse text-wrap-mode`,`white-space-collapse`,1,`collapse`,``,`white-space-trim`,0,`none`,``,`widows`,1,`2`,``,`width`,0,`auto`,``,`will-change`,0,`auto`,``,`window-drag`,1,`none`,``,`word-break`,1,`normal`,``,`word-space-transform`,1,`none`,``,`word-spacing`,1,`normal`,``,`word-wrap`,0,``,``,`wrap-after`,0,`auto`,``,`wrap-before`,0,`auto`,``,`wrap-flow`,0,`auto`,``,`wrap-inside`,0,`auto`,``,`wrap-through`,0,`wrap`,``,`writing-mode`,1,`horizontal-tb`,``,`x`,0,`0`,``,`y`,0,`0`,``,`z-index`,0,`auto`,``,`zoom`,0,`1`,``];var PropInfo=class{name;inherited;initial;specLonghands;constructor(e,t,n,r){this.name=e,this.inherited=t,this.initial=n,this.specLonghands=r}};const Fc={color:`rgb(0, 0, 0)`,"background-color":`rgba(0, 0, 0, 0)`,"border-top-color":`currentcolor`,"border-right-color":`currentcolor`,"border-bottom-color":`currentcolor`,"border-left-color":`currentcolor`,"outline-color":`currentcolor`,"border-block-start-color":`currentcolor`,"border-block-end-color":`currentcolor`,"border-inline-start-color":`currentcolor`,"border-inline-end-color":`currentcolor`,"text-decoration-color":`currentcolor`,"column-rule-color":`currentcolor`,"caret-color":`currentcolor`,"text-emphasis-color":`currentcolor`,"-webkit-text-fill-color":`currentcolor`,"-webkit-text-stroke-color":`currentcolor`,"margin-top":`0px`,"margin-right":`0px`,"margin-bottom":`0px`,"margin-left":`0px`,"padding-top":`0px`,"padding-right":`0px`,"padding-bottom":`0px`,"padding-left":`0px`,"border-top-width":`medium`,"border-right-width":`medium`,"border-bottom-width":`medium`,"border-left-width":`medium`,"outline-width":`medium`,"column-rule-width":`medium`,"border-top-left-radius":`0px`,"border-top-right-radius":`0px`,"border-bottom-right-radius":`0px`,"border-bottom-left-radius":`0px`,"font-size":`16px`,"font-weight":`400`,"font-family":`"Times New Roman"`,"font-style":`normal`,"font-variant":`normal`,"line-height":`normal`,"letter-spacing":`normal`,"word-spacing":`0px`,"text-indent":`0px`,"outline-offset":`0px`,"min-width":`auto`,"min-height":`auto`,"max-width":`none`,"max-height":`none`,"flex-basis":`auto`,"flex-grow":`0`,"flex-shrink":`1`,order:`0`,"background-image":`none`,"background-position-x":`0%`,"background-position-y":`0%`,"background-position":`0% 0%`,"background-size":`auto`,"background-repeat":`repeat`,"background-origin":`padding-box`,"background-clip":`border-box`,"background-attachment":`scroll`,"border-image":`none`,"border-spacing":`0px 0px`,"transition-duration":`0s`,"transition-delay":`0s`,"animation-duration":`0s`,"animation-delay":`0s`,"text-align":`start`,opacity:`1`,"z-index":`auto`,"row-gap":`normal`,"column-gap":`normal`,"user-select":`auto`,"-webkit-user-select":`auto`,content:`normal`,quotes:`auto`,"list-style-type":`disc`,"vertical-align":`baseline`,"white-space":`normal`,"text-transform":`none`},Ic=/* @__PURE__ */ new Map([[`-webkit-align-content`,`align-content`],[`-webkit-align-items`,`align-items`],[`-webkit-align-self`,`align-self`],[`-webkit-animation`,`animation`],[`-webkit-animation-delay`,`animation-delay`],[`-webkit-animation-direction`,`animation-direction`],[`-webkit-animation-duration`,`animation-duration`],[`-webkit-animation-fill-mode`,`animation-fill-mode`],[`-webkit-animation-iteration-count`,`animation-iteration-count`],[`-webkit-animation-name`,`animation-name`],[`-webkit-animation-play-state`,`animation-play-state`],[`-webkit-animation-timing-function`,`animation-timing-function`],[`-webkit-appearance`,`appearance`],[`-webkit-backface-visibility`,`backface-visibility`],[`-webkit-background-clip`,`background-clip`],[`-webkit-background-origin`,`background-origin`],[`-webkit-background-size`,`background-size`],[`-webkit-border-bottom-left-radius`,`border-bottom-left-radius`],[`-webkit-border-bottom-right-radius`,`border-bottom-right-radius`],[`-webkit-border-radius`,`border-radius`],[`-webkit-border-top-left-radius`,`border-top-left-radius`],[`-webkit-border-top-right-radius`,`border-top-right-radius`],[`-webkit-box-shadow`,`box-shadow`],[`-webkit-box-sizing`,`box-sizing`],[`-webkit-filter`,`filter`],[`-webkit-flex`,`flex`],[`-webkit-flex-basis`,`flex-basis`],[`-webkit-flex-direction`,`flex-direction`],[`-webkit-flex-flow`,`flex-flow`],[`-webkit-flex-grow`,`flex-grow`],[`-webkit-flex-shrink`,`flex-shrink`],[`-webkit-flex-wrap`,`flex-wrap`],[`-webkit-justify-content`,`justify-content`],[`-webkit-mask`,`mask`],[`-webkit-mask-box-image`,`mask-border`],[`-webkit-mask-box-image-outset`,`mask-border-outset`],[`-webkit-mask-box-image-repeat`,`mask-border-repeat`],[`-webkit-mask-box-image-slice`,`mask-border-slice`],[`-webkit-mask-box-image-source`,`mask-border-source`],[`-webkit-mask-box-image-width`,`mask-border-width`],[`-webkit-mask-clip`,`mask-clip`],[`-webkit-mask-composite`,`mask-composite`],[`-webkit-mask-image`,`mask-image`],[`-webkit-mask-origin`,`mask-origin`],[`-webkit-mask-position`,`mask-position`],[`-webkit-mask-repeat`,`mask-repeat`],[`-webkit-mask-size`,`mask-size`],[`-webkit-order`,`order`],[`-webkit-perspective`,`perspective`],[`-webkit-perspective-origin`,`perspective-origin`],[`-webkit-text-size-adjust`,`text-size-adjust`],[`-webkit-transform`,`transform`],[`-webkit-transform-origin`,`transform-origin`],[`-webkit-transform-style`,`transform-style`],[`-webkit-transition`,`transition`],[`-webkit-transition-delay`,`transition-delay`],[`-webkit-transition-duration`,`transition-duration`],[`-webkit-transition-property`,`transition-property`],[`-webkit-transition-timing-function`,`transition-timing-function`],[`-webkit-user-select`,`user-select`]]);function canonicalPropertyName(e){return e.charCodeAt(0)===45?Ic.get(e)??e:e}const Lc=/* @__PURE__ */ new Map;let Rc=null;function tableOffset(e){let t=0,n=Pc.length/4-1;for(;t<=n;){let r=t+n>>>1,i=Pc[r*4];if(i===e)return r*4;i<e?t=r+1:n=r-1}return-1}function propertyInfo(e){let t=Lc.get(e);if(t!==void 0)return t;let n=tableOffset(e);if(n===-1)return;let r=Pc[n+3];if(t=new PropInfo(e,Pc[n+1]===1,Fc[e]??Pc[n+2],r===``?null:r.split(` `)),t.initial===``&&t.specLonghands===null&&e.startsWith(`-webkit-`)){let n=propertyInfo(e.slice(8));n!==void 0&&(t.inherited=n.inherited,t.initial=n.initial)}return Lc.set(e,t),t}function isSupportedProperty(e){return propertyInfo(e)!==void 0}function isCustomPropertyName(e){return e.length>2&&e.charCodeAt(0)===45&&e.charCodeAt(1)===45}function allPropertyNames(){if(Rc===null){Rc=Array(Pc.length/4);for(let e=0;e<Rc.length;e++)Rc[e]=Pc[e*4]}return Rc}let zc=null;function computedPropertyNames(){if(zc!==null)return zc;zc=[];for(let e=0;e<Pc.length;e+=4){let t=Pc[e];t.charCodeAt(0)!==45&&Pc[e+3]===``&&zc.push(t)}return zc}function cssPropertyToIDLAttribute(e,t){t&&e.charCodeAt(0)===45&&(e=e.slice(1));let n=``,r=!1;for(let t=0;t<e.length;t++){let i=e[t];i===`-`?r=!0:r?(r=!1,n+=i.toUpperCase()):n+=i}return n}const Bc={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},Vc={accentcolor:30207,accentcolortext:16777215,activetext:16711680,buttonborder:7763574,buttonface:15724527,buttontext:0,canvas:16777215,canvastext:0,field:16777215,fieldtext:0,graytext:8421504,highlight:11916799,highlighttext:0,linktext:238,mark:16776960,marktext:0,selecteditem:30207,selecteditemtext:16777215,visitedtext:5577355},Hc=/* @__PURE__ */ new Set([`lab`,`lch`,`oklab`,`oklch`,`color`,`color-mix`,`light-dark`,`device-cmyk`,`contrast-color`]);function isNamedColor(e){return Bc[e]!==void 0||Vc[e]!==void 0||e===`transparent`||e===`currentcolor`}var RGBA=class{r;g;b;a;constructor(e,t,n,r){this.r=e,this.g=t,this.b=n,this.a=r}};function clamp$1(e,t,n){return e<t?t:e>n?n:e}__name(clamp$1,`clamp`);function formatAlpha(e){let t=Math.round(clamp$1(e,0,1)*255),n=Math.round(t/255*100)/100;return Math.round(n*255)!==t&&(n=Math.round(t/255*1e3)/1e3),String(n)}function serializeRGBA(e){let t=Math.round(clamp$1(e.r,0,255)),n=Math.round(clamp$1(e.g,0,255)),r=Math.round(clamp$1(e.b,0,255)),i=clamp$1(e.a,0,1);return i>=1?`rgb(${t}, ${n}, ${r})`:`rgba(${t}, ${n}, ${r}, ${formatAlpha(i)})`}function fromPacked(e,t){return new RGBA(e>>16&255,e>>8&255,e&255,t)}function hexDigit(e){return e>=48&&e<=57?e-48:e>=97&&e<=102?e-87:e>=65&&e<=70?e-55:-1}function parseHex(e){let t=e.length;if(t!==3&&t!==4&&t!==6&&t!==8)return null;let n=[];for(let r=0;r<t;r++){let t=hexDigit(e.charCodeAt(r));if(t===-1)return null;n.push(t)}return t<=4?new RGBA(n[0]*17,n[1]*17,n[2]*17,t===4?n[3]*17/255:1):new RGBA(n[0]*16+n[1],n[2]*16+n[3],n[4]*16+n[5],t===8?(n[6]*16+n[7])/255:1)}function splitArgs(e){let t=e.trim();if(t.indexOf(`,`)!==-1){let e=t.split(`,`).map(e=>e.trim());for(let t of e)if(t===``||/\s/.test(t))return null;return e}let n=t.indexOf(`/`),r=(n===-1?t:t.slice(0,n)).trim().split(/\s+/);if(n!==-1){let e=t.slice(n+1).trim();if(e===``||/\s/.test(e))return null;r.push(e)}return r}const Uc=/^([+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?)(%|deg|grad|rad|turn)?$/i;function parseChannel(e,t){if(e.toLowerCase()===`none`)return 0;let n=Uc.exec(e);if(n===null)return null;let r=Number(n[1]);return n[2]===void 0?r:n[2]===`%`?r/100*t:null}function parseAlpha(e){if(e===void 0)return 1;let t=parseChannel(e,1);return t===null?null:clamp$1(t,0,1)}function parseHue(e){if(e.toLowerCase()===`none`)return 0;let t=Uc.exec(e);if(t===null)return null;let n=Number(t[1]),r=t[2]?.toLowerCase();return r===void 0||r===`deg`?n:r===`grad`?n*360/400:r===`rad`?n*180/Math.PI:r===`turn`?n*360:null}function hslToRgb(e,t,n){e=(e%360+360)%360,t=clamp$1(t,0,1),n=clamp$1(n,0,1);let f=r=>{let i=(r+e/30)%12,a=t*Math.min(n,1-n);return n-a*Math.max(-1,Math.min(i-3,9-i,1))};return[f(0)*255,f(8)*255,f(4)*255]}function hwbToRgb(e,t,n){if(t+n>=1){let e=t/(t+n)*255;return[e,e,e]}let r=hslToRgb(e,1,.5);for(let e=0;e<3;e++)r[e]=r[e]/255*(1-t-n)*255+t*255;return r}function parseColorFunction(e,t){let n=splitArgs(t);if(n===null||n.length!==3&&n.length!==4)return null;if(e===`rgb`||e===`rgba`){let e=parseChannel(n[0],255),t=parseChannel(n[1],255),r=parseChannel(n[2],255),i=parseAlpha(n[3]);return e===null||t===null||r===null||i===null?null:new RGBA(e,t,r,i)}if(e===`hsl`||e===`hsla`||e===`hwb`){let t=parseHue(n[0]),r=parseChannel(n[1],1),i=parseChannel(n[2],1),a=parseAlpha(n[3]);if(t===null||r===null||i===null||a===null)return null;let o=n[1].endsWith(`%`)?r:r/100,s=n[2].endsWith(`%`)?i:i/100,[c,l,u]=e===`hwb`?hwbToRgb(t,o,s):hslToRgb(t,o,s);return new RGBA(c,l,u,a)}return null}function normalizeColor(e){let t=e.trim();if(t===``)return null;if(t.charCodeAt(0)===35){let e=parseHex(t.slice(1));return e===null?null:serializeRGBA(e)}let n=t.indexOf(`(`);if(n===-1){let e=t.toLowerCase();return isNamedColor(e)?e:null}if(!t.endsWith(`)`))return null;let r=t.slice(0,n).toLowerCase(),i=t.slice(n+1,-1);if(Kc.test(i)&&(Wc.has(r)||Gc.has(r)))return normalizeRelativeColor(r,i);if(Hc.has(r))return normalizeOtherColorFunction(r,i,t);let a=parseColorFunction(r,i);return a===null?null:serializeRGBA(a)}const Wc=/* @__PURE__ */ new Set([`rgb`,`rgba`,`hsl`,`hsla`,`hwb`]),Gc=/* @__PURE__ */ new Set([`lab`,`lch`,`oklab`,`oklch`]),Kc=/^\s*from\s/i,qc=/^(calc|min|max|clamp|round|mod|rem|abs|sign|sin|cos|tan|asin|acos|atan|atan2|pow|sqrt|hypot|log|exp)\(/i,Jc={lab:[100,125,125],lch:[100,150,0],oklab:[1,.4,.4],oklch:[1,.4,0]},Yc=/* @__PURE__ */ new Set([`srgb`,`srgb-linear`,`display-p3`,`display-p3-linear`,`a98-rgb`,`prophoto-rgb`,`rec2020`,`xyz`,`xyz-d50`,`xyz-d65`]),Xc=/* @__PURE__ */ new Set([`hsl`,`hwb`,`lch`,`oklch`]),Zc=/* @__PURE__ */ new Set([`srgb`,`srgb-linear`,`display-p3`,`display-p3-linear`,`a98-rgb`,`prophoto-rgb`,`rec2020`,`lab`,`oklab`,`xyz`,`xyz-d50`,`xyz-d65`]),Qc=/* @__PURE__ */ new Set([`shorter`,`longer`,`increasing`,`decreasing`]);function roundSig(e,t){return e===0?`0`:formatNumber(Number(e.toPrecision(t)))}function alphaText(e){if(e.type===1)return e.lower===`none`?`none`:null;let t;if(e.type===10)t=e.num;else if(e.type===11)t=e.num/100;else return null;return t=clamp$1(t,0,1),t===1?``:formatNumber(Math.round(t*1e3)/1e3)}function channelsAndAlpha(e){let t=[],n=null,r=!1;for(let i=0;i<e.length;i++){let a=e[i];if(a.type!==100){if(a.type===18)return null;if(a.type===9){if(a.value!==`/`||r)return null;r=!0}else if(r){if(n!==null)return null;n=a}else t.push(a)}}return r&&n===null?null:[t,n]}function withAlpha(e,t){if(t===null)return e+`)`;let n=alphaText(t);return n===null?null:n===``?e+`)`:e+` / `+n+`)`}function normalizeCanonical(e,t){let n=channelsAndAlpha(t);if(n===null||n[0].length!==3)return null;let[r,i]=n,a=Jc[e],o=e===`lch`||e===`oklch`,s=e===`lab`||e===`lch`?100:1,c=e+`(`;for(let e=0;e<3;e++){let t=r[e],n;if(t.type===1&&t.lower===`none`)n=`none`;else if(o&&e===2){let e;if(t.type===10)e=t.num;else if(t.type===12){let n=parseHue(t.text);if(n===null)return null;e=n}else return null;n=roundSig((e%360+360)%360,6),n===`360`&&(n=`0`)}else{let r;if(t.type===10)r=t.num;else if(t.type===11)r=t.num/100*a[e];else return null;e===0?r=clamp$1(r,0,s):o&&e===1&&r<0&&(r=0),n=roundSig(r,6)}c+=(e===0?``:` `)+n}return withAlpha(c,i)}function normalizeColorFn(e){let t=0;for(;t<e.length&&e[t].type===100;)t++;let n=e[t];if(n===void 0||n.type!==1||!Yc.has(n.lower))return null;let r=channelsAndAlpha(e.slice(t+1));if(r===null||r[0].length!==3)return null;let[i,a]=r,o=`color(`+(n.lower===`xyz`?`xyz-d65`:n.lower);for(let e of i)if(e.type===1&&e.lower===`none`)o+=` none`;else if(e.type===10)o+=` `+roundSig(e.num,5);else if(e.type===11)o+=` `+roundSig(e.num/100,5);else return null;return withAlpha(o,a)}function commaArgs(e){let t=[[]];for(let n of e)n.type===18?t.push([]):n.type!==100&&t[t.length-1].push(n);return t}function colorComponent(e){return e.type===4||e.type===1||e.type===2?normalizeColor(e.text):null}function normalizeColorMix(e){let t=commaArgs(e),n=``,r=0,i=t[0];if(i.length>=1&&i[0].type===1&&i[0].lower===`in`){if(i.length<2||i[1].type!==1)return null;let e=i[1].lower===`xyz`?`xyz-d65`:i[1].lower,t=``;if(Xc.has(e)){if(i.length===4){if(i[2].type!==1||!Qc.has(i[2].lower)||i[3].type!==1||i[3].lower!==`hue`)return null;i[2].lower!==`shorter`&&(t=` `+i[2].lower+` hue`)}else if(i.length!==2)return null}else if(!Zc.has(e)||i.length!==2)return null;(e!==`oklab`||t!==``)&&(n=`in `+e+t+`, `),r=1}let a=t.length-r;if(a<1)return null;let o=[],s=[];for(let e=r;e<t.length;e++){let n=t[e];if(n.length<1||n.length>2)return null;let r=null,i=null;for(let e of n)if(i===null&&e.type===11){if(e.num<0||e.num>100)return null;i=e.num}else if(i===null&&e.type===2&&qc.test(e.text))i=e.lower+e.text.slice(e.lower.length);else if(r!==null||(r=colorComponent(e),r===null))return null;if(r===null)return null;o.push(r),s.push(i)}let c=s.some(e=>typeof e==`string`),l=0,u=0;for(let e of s)typeof e==`number`?l+=e:e===null&&u++;let d=u===0||c?null:Math.max(0,(100-l)/u),m=s.map(e=>typeof e==`number`?e:e===null?d:null),h=m.every(e=>e!==null)&&m.every(e=>Math.abs(e-m[0])<1e-9)&&Math.abs(m[0]-100/a)<1e-9,_=[];for(let e=0;e<a;e++){let t=s[e],n=o[e];h||(typeof t==`string`?n+=` `+t:typeof t==`number`?n+=` `+roundSig(t,6)+`%`:d!==null&&(n+=` `+roundSig(d,6)+`%`)),_.push(n)}return`color-mix(`+n+_.join(`, `)+`)`}function normalizeLightDark(e){let t=commaArgs(e);if(t.length!==2||t[0].length!==1||t[1].length!==1)return null;let n=colorComponent(t[0][0]),r=colorComponent(t[1][0]);return n===null||r===null?null:`light-dark(`+n+`, `+r+`)`}function normalizeRelativeColor(e,t){let n=splitComponents(t);if(n===null)return null;let r=(e===`rgba`?`rgb`:e===`hsla`?`hsl`:e)+`(from`,i=!1;for(let e=0;e<n.length;e++){let t=n[e];if(t.type!==100&&!(e===0||t.type===1&&t.lower===`from`&&!i&&r.endsWith(`(from`))){if(i)r+=` `+(t.type===1?t.lower:t.text);else{let e=colorComponent(t);if(e===null)return null;r+=` `+e,i=!0}}}return i?r+`)`:null}function normalizeOtherColorFunction(e,t,n){let r=splitComponents(t);if(r===null)return null;for(let t of r)if(t.type===2&&qc.test(t.text))return e+n.slice(e.length);switch(e){case`lab`:case`lch`:case`oklab`:case`oklch`:return normalizeCanonical(e,r);case`color`:return normalizeColorFn(r);case`color-mix`:return normalizeColorMix(r);case`light-dark`:return normalizeLightDark(r);default:return e+n.slice(e.length)}}function computeColor(e,t){let n=e.trim(),r=n.toLowerCase();if(r===`currentcolor`)return t;if(r===`transparent`)return`rgba(0, 0, 0, 0)`;let i=Bc[r]??Vc[r];if(i!==void 0)return serializeRGBA(fromPacked(i,1));if(n.charCodeAt(0)===35){let e=parseHex(n.slice(1));return e===null?n:serializeRGBA(e)}let a=n.indexOf(`(`);if(a!==-1&&n.endsWith(`)`)){let e=parseColorFunction(n.slice(0,a).toLowerCase(),n.slice(a+1,-1));if(e!==null)return serializeRGBA(e)}return n}var Comp=class{type;text;lower;num;isInteger;value;constructor(e,t,n,r,i,a){this.type=e,this.text=t,this.lower=n,this.num=r,this.isInteger=i,this.value=a}};function splitComponents(e){let t=new CSSTokenizer(e),n=[],r=[];for(;;){let i=t.next();if(i===0)break;switch(i){case 13:n.length!==0&&n[n.length-1].type!==100&&n.push(new Comp(100,` `,``,0,!0,``));continue;case 6:case 8:case 17:case 22:case 20:case 24:case 23:return null;case 9:if(t.value===`!`)return null;n.push(new Comp(9,t.value,t.value,0,!0,t.value));continue;case 2:case 21:case 19:{let a=t.start,o=i===2?t.value.toLowerCase():``;for(r.length=0,r.push(i===19?20:22);r.length>0;){let e=t.next();if(e===0)break;if(e===6||e===8)return null;if(e===r[r.length-1])r.pop();else if(e===2||e===21)r.push(22);else if(e===19)r.push(20);else if(e===23)r.push(24);else if(e===22||e===20||e===24)return null}let s=e.slice(a,t.end);for(let e=r.length-1;e>=0;e--)s+=r[e]===22?`)`:r[e]===20?`]`:`}`;n.push(new Comp(i,s,o,0,!0,``));continue}default:n.push(new Comp(i,e.slice(t.start,t.end),i===1?t.value.toLowerCase():i===12?t.unit.toLowerCase():``,t.num,t.isInteger,t.value))}}return n.length!==0&&n[n.length-1].type===100&&n.pop(),n}function significant(e){let t=[];for(let n=0;n<e.length;n++)e[n].type!==100&&t.push(e[n]);return t}function formatNumber(e){if(Object.is(e,-0))return`0`;let t=String(e);return t.indexOf(`e`)===-1?t:Math.abs(e)<1e-6?`0`:e.toFixed(0)}const $c=/* @__PURE__ */ new Set(/* @__PURE__ */ `px.em.rem.ex.rex.ch.rch.cap.rcap.ic.ric.lh.rlh.vw.vh.vi.vb.vmin.vmax.svw.svh.svi.svb.svmin.svmax.lvw.lvh.lvi.lvb.lvmin.lvmax.dvw.dvh.dvi.dvb.dvmin.dvmax.cqw.cqh.cqi.cqb.cqmin.cqmax.cm.mm.q.in.pt.pc`.split(`.`)),el=/* @__PURE__ */ new Set([`s`,`ms`]),tl=/* @__PURE__ */ new Set([`deg`,`grad`,`rad`,`turn`]),nl=/* @__PURE__ */ new Set(/* @__PURE__ */ `calc.min.max.clamp.round.mod.rem.sin.cos.tan.asin.acos.atan.atan2.pow.sqrt.hypot.log.exp.abs.sign.env.-webkit-calc.-moz-calc.calc-size.anchor.anchor-size`.split(`.`)),rl=1024;var Grammar=class{types;keywords;fns;max;constructor(e,t,n,r){this.types=e,this.keywords=t,this.fns=n,this.max=r}};const il=new Grammar(2048,/* @__PURE__ */ new Set,/* @__PURE__ */ new Set,1);function grammar(e){let t=0,n=/* @__PURE__ */ new Set,r=/* @__PURE__ */ new Set,i=1;for(let a of e.split(` `)){if(a===``)continue;let e=a.endsWith(`+`)?a.slice(0,-1):a;switch(a.endsWith(`+`)&&e.length===1&&(t|=rl),e){case`L`:t|=1;continue;case`P`:t|=2;continue;case`N`:t|=4;continue;case`I`:t|=8;continue;case`C`:t|=16;continue;case`T`:t|=32;continue;case`A`:t|=64;continue;case`S`:t|=128;continue;case`U`:t|=256;continue}a===`#`?t|=4096:a.startsWith(`*`)?i=Number(a.slice(1)):a.endsWith(`()`)?r.add(a.slice(0,-2)):n.add(a)}return new Grammar(t,n,r,i)}const al=`L+ P+ auto min-content max-content fit-content stretch -webkit-fill-available -moz-available -webkit-min-content -webkit-max-content -webkit-fit-content fit-content()`,ol=`L+ P+ none min-content max-content fit-content stretch -webkit-fill-available -moz-available fit-content()`,sl=`L P auto`,cl=`L P auto`,ll=`L+ P+`,ul=`none hidden dotted dashed solid double groove ridge inset outset`,dl=`L+ thin medium thick`,fl=`L+ P+ *2`,pl=`visible hidden clip scroll auto overlay -webkit-paged-x -webkit-paged-y`,ml={width:al,height:al,"min-width":al,"min-height":al,"inline-size":al,"block-size":al,"min-inline-size":al,"min-block-size":al,"max-width":ol,"max-height":ol,"max-inline-size":ol,"max-block-size":ol,top:sl,right:sl,bottom:sl,left:sl,"inset-block-start":sl,"inset-block-end":sl,"inset-inline-start":sl,"inset-inline-end":sl,"margin-top":cl,"margin-right":cl,"margin-bottom":cl,"margin-left":cl,"margin-block-start":cl,"margin-block-end":cl,"margin-inline-start":cl,"margin-inline-end":cl,"padding-top":ll,"padding-right":ll,"padding-bottom":ll,"padding-left":ll,"padding-block-start":ll,"padding-block-end":ll,"padding-inline-start":ll,"padding-inline-end":ll,"border-top-width":dl,"border-right-width":dl,"border-bottom-width":dl,"border-left-width":dl,"outline-width":dl,"column-rule-width":dl,"border-top-style":ul,"border-right-style":ul,"border-bottom-style":ul,"border-left-style":ul,"outline-style":ul+` auto`,"column-rule-style":ul,"border-block-start-color":`C`,"border-block-end-color":`C`,"border-inline-start-color":`C`,"border-inline-end-color":`C`,"border-top-color":`C`,"border-right-color":`C`,"border-bottom-color":`C`,"border-left-color":`C`,color:`C`,"background-color":`C`,"outline-color":`C auto`,"caret-color":`C auto`,"text-decoration-color":`C`,"column-rule-color":`C`,"accent-color":`C auto`,"flood-color":`C`,"lighting-color":`C`,"stop-color":`C`,"text-emphasis-color":`C`,"-webkit-text-fill-color":`C`,"-webkit-text-stroke-color":`C`,"border-top-left-radius":fl,"border-top-right-radius":fl,"border-bottom-right-radius":fl,"border-bottom-left-radius":fl,opacity:`N P`,"fill-opacity":`N P`,"stroke-opacity":`N P`,"flood-opacity":`N P`,"stop-opacity":`N P`,"z-index":`I auto`,order:`I`,"flex-grow":`N+`,"flex-shrink":`N+`,"flex-basis":`L+ P+ auto content min-content max-content fit-content`,"line-height":`N+ L+ P+ normal`,"font-size":`L+ P+ xx-small x-small small medium large x-large xx-large xxx-large larger smaller math`,"font-weight":`N+ normal bold bolder lighter`,"font-style":`normal italic oblique`,"font-variant":`normal none small-caps all-small-caps petite-caps all-petite-caps unicase titling-caps`,"font-stretch":`P+ normal ultra-condensed extra-condensed condensed semi-condensed semi-expanded expanded extra-expanded ultra-expanded`,visibility:`visible hidden collapse`,"pointer-events":`auto none visiblepainted visiblefill visiblestroke visible painted fill stroke all bounding-box`,position:`static relative absolute fixed sticky -webkit-sticky`,float:`left right none inline-start inline-end`,clear:`none left right both inline-start inline-end`,"box-sizing":`content-box border-box`,"overflow-x":pl,"overflow-y":pl,"overflow-block":pl,"overflow-inline":pl,"text-align":`start end left right center justify match-parent justify-all -webkit-left -webkit-right -webkit-center -moz-left -moz-right -moz-center`,"white-space":`normal pre nowrap pre-wrap break-spaces pre-line`,"user-select":`auto text none contain all`,"-webkit-user-select":`auto text none contain all`,"background-image":`U none # linear-gradient() radial-gradient() conic-gradient() repeating-linear-gradient() repeating-radial-gradient() repeating-conic-gradient() image-set() -webkit-image-set() url() image() cross-fade() element() paint() -webkit-linear-gradient() -webkit-radial-gradient() -webkit-gradient()`,"background-attachment":`# scroll fixed local`,"background-origin":`# border-box padding-box content-box`,"background-clip":`# border-box padding-box content-box text border-area`,"background-repeat":`# repeat-x repeat-y repeat space round no-repeat *2`,"background-size":`# L+ P+ auto cover contain *2`,"list-style-type":`*1`,"text-transform":`none capitalize uppercase lowercase full-width full-size-kana math-auto`,"word-break":`normal keep-all break-all break-word auto-phrase`,"text-overflow":`clip ellipsis`,"vertical-align":`L P baseline sub super text-top text-bottom middle top bottom`,"table-layout":`auto fixed`,"border-collapse":`collapse separate`,"empty-cells":`show hide`,"caption-side":`top bottom`,"list-style-position":`inside outside`,resize:`none both horizontal vertical block inline`,"object-fit":`fill contain cover none scale-down`,isolation:`auto isolate`,"mix-blend-mode":`normal multiply screen overlay darken lighten color-dodge color-burn hard-light soft-light difference exclusion hue saturation color luminosity plus-darker plus-lighter`,"backface-visibility":`visible hidden`,"flex-direction":`row row-reverse column column-reverse`,"flex-wrap":`nowrap wrap wrap-reverse`,"animation-duration":`# T+ auto`,"transition-duration":`# T+`,"animation-delay":`# T`,"transition-delay":`# T`,"animation-iteration-count":`# N+ infinite`,"animation-direction":`# normal reverse alternate alternate-reverse`,"animation-fill-mode":`# none forwards backwards both`,"animation-play-state":`# running paused`,"tab-size":`N+ L+`,"row-gap":`L+ P+ normal`,"column-gap":`L+ P+ normal`,"outline-offset":`L`,"letter-spacing":`L P normal`,"word-spacing":`L P normal`,"text-indent":`L P`,"aspect-ratio":`*1`,inset:`L P auto *4`,cursor:`# U N *3 auto default none context-menu help pointer progress wait cell crosshair text vertical-text alias copy move no-drop not-allowed grab grabbing e-resize n-resize ne-resize nw-resize s-resize se-resize sw-resize w-resize ew-resize ns-resize nesw-resize nwse-resize col-resize row-resize all-scroll zoom-in zoom-out -webkit-grab -webkit-grabbing -webkit-zoom-in -webkit-zoom-out hand`,"unicode-bidi":`normal embed isolate bidi-override isolate-override plaintext`,direction:`ltr rtl`,"writing-mode":`horizontal-tb vertical-rl vertical-lr sideways-rl sideways-lr`,"content-visibility":`visible auto hidden`,"scroll-behavior":`auto smooth`,"touch-action":`*1`,"will-change":`*1`,appearance:`none auto menulist-button textfield base-select button checkbox listbox menulist meter progress-bar push-button radio searchfield slider-horizontal square-button textarea`,"-webkit-appearance":`*1`},hl=/* @__PURE__ */ new Map;function grammarFor(e){let t=hl.get(e);if(t!==void 0)return t;let n=ml[e];return t=n===void 0||n===`*1`?il:grammar(n),hl.set(e,t),t}function isCSSWideKeyword(e){return e===`inherit`||e===`initial`||e===`unset`||e===`revert`||e===`revert-layer`}function normalizeComponent(e,t){let n=t.types,r=!!(n&rl);switch(e.type){case 1:return t.keywords.has(e.lower)?e.lower:n&16?normalizeColor(e.text):null;case 10:return n&8&&e.isInteger&&(!r||e.num>=0)||n&4&&(!r||e.num>=0)?formatNumber(e.num):e.num===0&&n&1?`0px`:null;case 11:return n&2&&(!r||e.num>=0)?formatNumber(e.num)+`%`:null;case 12:return r&&e.num<0?null:n&1&&$c.has(e.lower)||n&32&&el.has(e.lower)||n&64&&tl.has(e.lower)?formatNumber(e.num)+e.lower:null;case 4:return n&16?normalizeColor(e.text):null;case 5:return n&128?serializeString$1(e.value):null;case 7:return n&256?serializeUrl(e.value):null;case 2:{let r=e.lower;if(r===`url`&&n&256){let t=splitComponents(e.text.slice(4,-1));return t!==null&&t.length===1&&t[0].type===5?serializeUrl(t[0].value):e.text}if(n&111&&nl.has(r))return e.text;if(n&16){let t=normalizeColor(e.text);if(t!==null)return t}return t.fns.has(r)?gl.has(r)?normalizeGradient(e):e.text:null}}return null}const gl=/* @__PURE__ */ new Set([`linear-gradient`,`radial-gradient`,`conic-gradient`,`repeating-linear-gradient`,`repeating-radial-gradient`,`repeating-conic-gradient`]);function normalizeGradient(e){let t=e.text.indexOf(`(`),n=splitComponents(e.text.slice(t+1,-1));if(n===null)return null;let r=e.lower,i=r.endsWith(`linear-gradient`),a=r.endsWith(`radial-gradient`),o=r.endsWith(`conic-gradient`),s=[],c=0,l=[],u=!1;for(let e=0;e<=n.length;e++){let t=e<n.length?n[e]:null;if(t===null||t.type===18){if(l.length===0)return null;if(u&&c++,s.length===0&&!u){let e=l.join(` `);i&&e===`to bottom`?l=[]:(a||o)&&(l.length>=2&&l[l.length-2]===`at`&&l[l.length-1]===`center`&&(l.length-=2),a&&(l=l.filter(e=>e!==`ellipse`&&e!==`farthest-corner`))),l.length!==0&&s.push(l.join(` `))}else s.push(l.join(` `));l=[],u=!1;continue}if(t.type===100)continue;let r=null;(t.type===4||t.type===1||t.type===2)&&(r=normalizeColor(t.text),r!==null&&(u=!0)),r===null&&(r=t.type===1?t.lower:t.type===12?formatNumber(t.num)+t.lower:t.type===11?formatNumber(t.num)+`%`:t.type===10?t.num===0&&u?`0px`:formatNumber(t.num):t.type===2?t.lower+t.text.slice(t.lower.length):t.text),l.push(r)}return c<1?null:r+`(`+s.join(`, `)+`)`}function normalizePaint(e){let t=significant(e);if(t.length===2&&(t[0].type===7||t[0].type===2&&t[0].lower===`url`)){let e=t[0].type===7?serializeUrl(t[0].value):normalizeComponent(t[0],xl),n=t[1].type===1&&t[1].lower===`none`?`none`:colorComp(t[1]);return e===null||n===null?null:e+` `+n}if(t.length!==1)return null;let n=t[0];switch(n.type){case 1:return n.lower===`none`||n.lower===`context-fill`||n.lower===`context-stroke`?n.lower:normalizeColor(n.text);case 7:return serializeUrl(n.value);case 4:return normalizeColor(n.text);case 2:return n.lower===`url`?normalizeComponent(n,xl):normalizeColor(n.text)??n.text}return verbatimComps(e)}function normalizeImageLoose(e){let t=significant(e);if(t.length===1){let e=t[0];if(e.type===7)return serializeUrl(e.value);if(e.type===1)return e.lower===`none`?`none`:e.text;if(e.type===2&&gl.has(e.lower))return normalizeGradient(e)??e.text}return verbatimComps(e)}function verbatimComps(e){let t=``;for(let n of e)t+=n.text;return t}const _l=/* @__PURE__ */ new Set([`serif`,`sans-serif`,`cursive`,`fantasy`,`monospace`,`system-ui`,`emoji`,`math`,`fangsong`,`ui-serif`,`ui-sans-serif`,`ui-monospace`,`ui-rounded`]);function plainIdent(e){if(e===``)return!1;let t=0;if(e.charCodeAt(0)===45){if(e.length===1)return!1;if(t=1,e.charCodeAt(1)===45)t=2;else if(!isIdentStart(e.charCodeAt(1)))return!1}else if(!isIdentStart(e.charCodeAt(0)))return!1;for(;t<e.length;t++)if(!isIdentChar(e.charCodeAt(t)))return!1;return!0}function serializeFamilyName(e){let t=e.toLowerCase();return!_l.has(t)&&!isCSSWideKeyword(t)&&t!=="default"&&e.split(` `).every(plainIdent)?e:serializeString$1(e)}function serializeFamilyList(e){let t=[],n=[],r=null;for(let i=0;i<=e.length;i++){let a=i<e.length?e[i]:null;if(a===null||a.type===18){if(r!==null)t.push(serializeFamilyName(r));else if(n.length===0)return null;else if(n.length===1&&_l.has(n[0].toLowerCase()))t.push(n[0].toLowerCase());else if(n.some(excludedFamilyWord))return null;else t.push(serializeFamilyName(n.join(` `)));n=[],r=null}else if(a.type===5){if(r!==null||n.length!==0)return null;r=a.value}else if(a.type===1){if(r!==null)return null;n.push(a.value)}else return null}return t.join(`, `)}function excludedFamilyWord(e){let t=e.toLowerCase();return isCSSWideKeyword(t)||t===`revert-rule`||t==="default"||_l.has(t)}function normalizeFontFamily(e){return serializeFamilyList(significant(e))}function serializeString$1(e){let t=`"`;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t+=r===0?`�`:r>=1&&r<=31||r===127?`\\`+r.toString(16)+` `:r===34||r===92?`\\`+e[n]:e[n]}return t+`"`}__name(serializeString$1,`serializeString`);function serializeUrl(e){return`url(`+serializeString$1(e)+`)`}function containsVar(e){return e.indexOf(`(`)===-1?!1:/var\(/i.test(e)||/env\(/i.test(e)||/attr\(/i.test(e)}function verbatim(e){return e.trim()}const vl=/* @__PURE__ */ new Set([`block`,`inline`,`run-in`]),yl=/* @__PURE__ */ new Set([`flow`,`flow-root`,`table`,`flex`,`grid`,`ruby`,`math`]),bl=/* @__PURE__ */ new Set(/* @__PURE__ */ `none.contents.block.inline.inline-block.flex.inline-flex.grid.inline-grid.flow-root.list-item.table.inline-table.table-row.table-cell.table-column.table-column-group.table-header-group.table-footer-group.table-row-group.table-caption.run-in.ruby.ruby-text.ruby-base.ruby-base-container.ruby-text-container.flow.math.-webkit-box.-webkit-inline-box.-moz-box.-moz-inline-box.inline-list-item.-webkit-flex.-webkit-inline-flex.-ms-flexbox.-ms-inline-flexbox.-ms-grid.-ms-inline-grid`.split(`.`));function normalizeDisplay(e){let t=[];for(let n of e)if(n.type!==100){if(n.type!==1)return null;t.push(n.lower)}if(t.length===1)return bl.has(t[0])?t[0]:null;if(t.length>3)return null;let n=``,r=``,i=!1;for(let e of t)if(vl.has(e)&&n===``)n=e;else if(yl.has(e)&&r===``)r=e;else if(e===`list-item`&&!i)i=!0;else return null;return i&&r!==``&&r!==`flow`&&r!==`flow-root`?null:(n===``&&(n=`block`),r===``&&(r=`flow`),i?(n===`block`?``:n+` `)+(r===`flow-root`?`flow-root `:``)+`list-item`:n===`block`?r===`flow`?`block`:r:n===`inline`?r===`flow`?`inline`:r===`flow-root`?`inline-block`:r===`table`||r===`flex`||r===`grid`?`inline-`+r:`inline `+r:n+(r===`flow`?``:` `+r))}function normalizeContent(e){let t=``;for(let n of e)if(n.type===100)t+=` `;else{if(n.type===18)return null;n.type===5?t+=serializeString$1(n.value):n.type===7?t+=serializeUrl(n.value):n.type===1?t+=isCSSWideKeyword(n.lower)||n.lower===`none`||n.lower===`normal`||n.lower.endsWith(`-quote`)?n.lower:n.text:t+=n.text}return t===``?null:t}const xl=new Grammar(256,/* @__PURE__ */ new Set,/* @__PURE__ */ new Set,1);function normalizeOpacity(e){let t=significant(e);if(t.length!==1)return null;let n=t[0];return n.type===11?formatNumber(n.num/100):normalizeComponent(n,Sl)}const Sl=grammar(`N`),Cl=/* @__PURE__ */ new Set([`opacity`,`fill-opacity`,`stroke-opacity`,`flood-opacity`,`stop-opacity`]);function canonicalComp(e){switch(e.type){case 10:return formatNumber(e.num);case 11:return formatNumber(e.num)+`%`;case 12:return formatNumber(e.num)+e.lower;case 1:return e.lower;case 2:{if(nl.has(e.lower)||e.lower===`var`||e.lower===`env`||e.lower===`attr`)return e.text;let t=splitComponents(e.text.slice(e.text.indexOf(`(`)+1,-1));if(t===null)return e.text;let n=``,r=!1;for(let e of t)e.type===100?r=!0:e.type===18?(n+=`, `,r=!1):(r&&n!==``&&!n.endsWith(`, `)&&(n+=` `),r=!1,n+=canonicalComp(e));return e.lower+`(`+n+`)`}}return e.text}const wl=/* @__PURE__ */ new Set([`linear`,`ease`,`ease-in`,`ease-out`,`ease-in-out`,`step-start`,`step-end`]),Tl=/* @__PURE__ */ new Set([`cubic-bezier`,`steps`,`linear`]);function isZeroTime(e){return e===`0s`||e===`0ms`}function normalizeTransition(e){let t=[],n=[],r=significant(e);for(let e=0;e<=r.length;e++){let i=e<r.length?r[e]:null;if(i!==null&&i.type!==18){n.push(i);continue}if(n.length===0)return null;let a=null,o=null,s=null,c=[];for(let e of n)if(e.type===12&&el.has(e.lower)){if(c.length===2||c.length===0&&e.num<0)return null;c.push(formatNumber(e.num)+e.lower)}else if(e.type===2&&nl.has(e.lower)){if(c.length===2)return null;c.push(e.text)}else if(e.type===1&&wl.has(e.lower)){if(o!==null)return null;o=e.lower}else if(e.type===2&&Tl.has(e.lower)){if(o!==null)return null;o=canonicalComp(e)}else if(e.type===1&&(e.lower===`normal`||e.lower===`allow-discrete`)){if(s!==null)return null;s=e.lower}else if(e.type===1&&!isCSSWideKeyword(e.lower)&&e.lower!=="default"){if(a!==null)return null;a=e.lower===`all`||e.lower===`none`?e.lower:e.value}else return null;if(a===`none`&&r.some(e=>e.type===18))return null;let l=[];a!==null&&a!==`all`&&l.push(a);let u=c[0]??`0s`,d=c[1]??`0s`;isZeroTime(u)&&isZeroTime(d)||l.push(u),o!==null&&o!==`ease`&&l.push(o),isZeroTime(d)||l.push(d),s!==null&&s!==`normal`&&l.push(s),t.push(l.length===0?`all`:l.join(` `)),n=[]}return t.join(`, `)}function lengthComp(e){return e.type===12&&$c.has(e.lower)?formatNumber(e.num)+e.lower:e.type===10&&e.num===0?`0px`:e.type===2&&nl.has(e.lower)?e.text:null}function colorComp(e){return e.type!==1&&e.type!==4&&e.type!==2?null:normalizeColor(e.text)}function normalizeBoxShadow(e){let t=significant(e);if(t.length===1&&t[0].type===1&&t[0].lower===`none`)return`none`;let n=[],r=[];for(let e=0;e<=t.length;e++){let i=e<t.length?t[e]:null;if(i!==null&&i.type!==18){r.push(i);continue}if(r.length===0)return null;let a=null,o=!1,s=[],c=!1;for(let e of r){let t=lengthComp(e);if(t!==null){if(c||s.length===4||s.length===2&&e.type===12&&e.num<0)return null;s.push(t);continue}if(s.length!==0&&(c=!0),e.type===1&&e.lower===`inset`){if(o)return null;o=!0;continue}let n=colorComp(e);if(n===null||a!==null)return null;a=n}if(s.length<2)return null;let l=a===null?``:a+` `;l+=s.join(` `),o&&(l+=` inset`),n.push(l),r=[]}return n.join(`, `)}function normalizeOutline(e){let t=significant(e);if(t.length===0||t.length>3)return null;let n=null,r=null,i=null,a=grammarFor(`outline-width`),o=grammarFor(`outline-style`),s=grammarFor(`outline-color`);for(let e of t){if(e.type===18||e.type===9)return null;let t;if(n===null&&(t=normalizeComponent(e,a))!==null)n=t;else if(r===null&&(t=normalizeComponent(e,o))!==null)r=t;else if(i===null&&(t=normalizeComponent(e,s))!==null)i=t;else return null}let c=[];return n!==null&&c.push(n),r!==null&&c.push(r),i!==null&&c.push(i),c.join(` `)}const El={outline:normalizeOutline,"box-shadow":normalizeBoxShadow,transition:normalizeTransition,opacity:normalizeOpacity,"fill-opacity":normalizeOpacity,"stroke-opacity":normalizeOpacity,"flood-opacity":normalizeOpacity,"stop-opacity":normalizeOpacity,display:normalizeDisplay,"font-family":normalizeFontFamily,content:normalizeContent,fill:normalizePaint,stroke:normalizePaint,"list-style-image":normalizeImageLoose,"border-image-source":normalizeImageLoose,"mask-image":normalizeImageLoose,"-webkit-mask-image":normalizeImageLoose},Dl=/* @__PURE__ */ new Map;function normalizeLonghand(e,t){let n=Dl.get(e);if(n===void 0)Dl.set(e,n=/* @__PURE__ */ new Map);else{let e=n.get(t);if(e!==void 0)return e}let r=fastLonghand(e,t),i=r===void 0?normalizeLonghandValue(e,t):r;return n.size===256&&n.clear(),n.set(t,i),i}function fastLonghand(e,t){let n=t.length;if(n===0)return;let r=t.charCodeAt(0);if(r>=97&&r<=122){for(let e=1;e<n;e++)if(r=t.charCodeAt(e),(r<97||r>122)&&r!==45)return;if(isCSSWideKeyword(t))return t;if(e===`display`)return bl.has(t)?t:void 0;if(El[e]!==void 0)return;let i=grammarFor(e);return i.types===2048||i.keywords.has(t)?t:void 0}let i=r===45,a=+!!i,o=a;for(;a<n&&(r=t.charCodeAt(a))>=48&&r<=57;)a++;let s=a-o;if(s===0||s>1&&t.charCodeAt(o)===48)return;let c=s===1&&t.charCodeAt(o)===48,l=s,u=!0;if(a<n&&t.charCodeAt(a)===46){let e=++a;for(;a<n&&(r=t.charCodeAt(a))>=48&&r<=57;)a++;if(a===e||t.charCodeAt(a-1)===48)return;if(c){let n=0;for(;t.charCodeAt(e+n)===48;)n++;if(n>=6)return}l+=a-e,u=!1}if(l>15||i&&c&&u)return;let d=Cl.has(e);if(El[e]!==void 0&&!d)return;let m=grammarFor(e).types,h=a;if(h<n){if(t.charCodeAt(a)===37)return a+1!==n||d?void 0:m===2048||m&2&&!(i&&m&1024)?t:void 0;for(;a<n&&(r=t.charCodeAt(a))>=97&&r<=122;)a++;if(a!==n)return;if(m===2048)return t;if(i&&m&1024)return;if(n-h===2&&t.charCodeAt(h)===112&&t.charCodeAt(h+1)===120)return m&1?t:void 0;let e=t.slice(h);return m&1&&$c.has(e)||m&32&&el.has(e)||m&64&&tl.has(e)?t:void 0}if(m===2048)return t;if(!(i&&m&1024))return m&8&&u||m&4?t:c&&u&&m&1?`0px`:void 0}function normalizeLonghandValue(e,t){let n=t.trim();if(n===``)return null;let r=splitComponents(n);if(r===null)return null;if(r.length===1&&r[0].type===1&&isCSSWideKeyword(r[0].lower))return r[0].lower;if(containsVar(n))return verbatim(n);let i=El[e];if(i!==void 0)return i(r);let a=grammarFor(e);return a.types===2048?verbatim(n):normalizeComps(r,a)}function normalizeComps(e,t){let n=``,r=0,i=``;for(let a=0;a<e.length;a++){let o=e[a];if(o.type===100)continue;if(o.type===18&&t.types&4096){if(r===0)return null;r=0,i=`, `;continue}if(++r>t.max||o.type===18||o.type===9)return null;let s=normalizeComponent(o,t);if(s===null)return null;n=n===``?s:n+(r===1?i:` `)+s}return r===0?null:n}function normalizeCustom(e){let t=e.trim();return t===``||splitComponents(t)===null&&/[;!]/.test(t)?null:t}const Ol=[`top`,`right`,`bottom`,`left`];function box(e,t){return Ol.map(n=>e+n+t)}const kl=box(`border-`,`-width`),Al=box(`border-`,`-style`),jl=box(`border-`,`-color`),Ml=/* @__PURE__ */ new Map([[`margin`,box(`margin-`,``)],[`padding`,box(`padding-`,``)],[`border-width`,kl],[`border-style`,Al],[`border-color`,jl],[`border-top`,[`border-top-width`,`border-top-style`,`border-top-color`]],[`border-right`,[`border-right-width`,`border-right-style`,`border-right-color`]],[`border-bottom`,[`border-bottom-width`,`border-bottom-style`,`border-bottom-color`]],[`border-left`,[`border-left-width`,`border-left-style`,`border-left-color`]],[`border`,[...kl,...Al,...jl,`border-image`]],[`flex`,[`flex-grow`,`flex-shrink`,`flex-basis`]],[`background`,[`background-image`,`background-position-x`,`background-position-y`,`background-size`,`background-repeat`,`background-origin`,`background-clip`,`background-attachment`,`background-color`]],[`background-position`,[`background-position-x`,`background-position-y`]],[`font`,[`font-style`,`font-variant`,`font-weight`,`font-size`,`line-height`,`font-family`]]]),Nl=/* @__PURE__ */ new Map;for(let[e,t]of Ml)for(let n of t){let t=Nl.get(n);t===void 0&&Nl.set(n,t=[]),t.push(e)}for(let e of Nl.values())e.sort((e,t)=>Ml.get(t).length-Ml.get(e).length);const Pl=/* @__PURE__ */ new Map;{let e=/* @__PURE__ */ new Map;for(let[t,n]of Nl){let r=e.get(n[0]);r===void 0&&e.set(n[0],r=1<<e.size),Pl.set(t,r)}for(let e of Ml.values())for(let t of e)if(Pl.get(t)!==Pl.get(e[0]))throw Error(`shorthand families overlap at ${t}`)}function shorthandFamily(e){return Pl.get(e)??0}function isExpandedShorthand(e){return Ml.has(e)}function longhandsOf(e){return Ml.get(e)}function shorthandsContaining(e){return Nl.get(e)}function items(e){let t=splitComponents(e);if(t===null)return null;let n=[];for(let e of t)e.type!==100&&n.push(e);return n}function expandBox(e,t){let n=items(t);if(n===null||n.length<1||n.length>4)return null;let r=grammarFor(e[0]),i=[];for(let e of n){if(e.type===18||e.type===9)return null;let t=normalizeComponent(e,r);if(t===null)return null;i.push(t)}let a=i[0],o=i[1]??a;return[a,o,i[2]??a,i[3]??o]}const Fl=/* @__PURE__ */ new Set([`none`,`hidden`,`dotted`,`dashed`,`solid`,`double`,`groove`,`ridge`,`inset`,`outset`]);function parseBorderSide(e){let t=items(e);if(t===null||t.length<1||t.length>3)return null;let n=``,r=``,i=``,a=grammarFor(`border-top-width`);for(let e of t){if(e.type===1&&Fl.has(e.lower)){if(r!==``)return null;r=e.lower;continue}let t=normalizeComponent(e,a);if(t!==null){if(n!==``)return null;n=t;continue}let o=normalizeColor(e.text);if(o!==null&&e.type!==10){if(i!==``)return null;i=o}else return null}return[n||`medium`,r||`none`,i||`currentcolor`]}const Il=/* @__PURE__ */ new Set([`auto`,`content`,`min-content`,`max-content`,`fit-content`]);function expandFlex(e){let t=items(e);if(t===null||t.length<1||t.length>3)return null;if(t.length===1&&t[0].type===1){if(t[0].lower===`none`)return[`0`,`0`,`auto`];if(t[0].lower===`auto`)return[`1`,`1`,`auto`]}let n=grammarFor(`flex-basis`),num=e=>e!==void 0&&e.type===10&&e.num>=0?formatNumber(e.num):null,basisOf=e=>e.type===1&&!Il.has(e.lower)?null:normalizeComponent(e,n),r,i=null,a=null,o=0;if((r=num(t[0]))!==null){if(o=1,(i=num(t[1]))!==null&&(o=2),o<t.length){if(a=basisOf(t[o]),a===null)return null;o++}}else{if(a=basisOf(t[0]),a===null)return null;o=1,(r=num(t[1]))!==null&&(o=2,(i=num(t[2]))!==null&&(o=3))}return o===t.length?r===null?[`1`,`1`,a]:[r,i??`1`,a??`0%`]:null}const Ll=/* @__PURE__ */ new Set([`left`,`center`,`right`,`top`,`bottom`]),Rl=/* @__PURE__ */ new Set([`repeat-x`,`repeat-y`,`repeat`,`space`,`round`,`no-repeat`]),zl=/* @__PURE__ */ new Set([`scroll`,`fixed`,`local`]),Bl=/* @__PURE__ */ new Set([`border-box`,`padding-box`,`content-box`]),Vl=/* @__PURE__ */ new Set([`linear-gradient`,`radial-gradient`,`conic-gradient`,`repeating-linear-gradient`,`repeating-radial-gradient`,`repeating-conic-gradient`,`image-set`,`-webkit-image-set`,`image`,`cross-fade`,`element`,`paint`,`-webkit-linear-gradient`,`-webkit-radial-gradient`,`-webkit-gradient`,`-moz-linear-gradient`,`-moz-radial-gradient`]);function isPositionComp(e){return e.type===1?Ll.has(e.lower):normalizeComponent(e,grammarFor(`margin-top`))!==null&&e.type!==1}function positionComp(e){return e.type===1?e.lower:normalizeComponent(e,grammarFor(`margin-top`))}function parsePosition(e){if(e.length<1||e.length>4)return null;let t=e.map(positionComp),isY=e=>e===`top`||e===`bottom`,isX=e=>e===`left`||e===`right`;if(t.length===1)return isY(t[0])?[`center`,t[0]]:[t[0],`center`];if(t.length===2)return isY(t[0])||isX(t[1])?isY(t[1])||isX(t[0])?null:[t[1],t[0]]:[t[0],t[1]];let n,r;return t.length===3?Ll.has(t[1])?(n=t[0],r=t[1]+` `+t[2]):(n=t[0]+` `+t[1],r=t[2]):(n=t[0]+` `+t[1],r=t[2]+` `+t[3]),isY(n.split(` `)[0])?[r,n]:[n,r]}const Hl=[`none`,`0%`,`0%`,`auto`,`repeat`,`padding-box`,`border-box`,`scroll`,`transparent`];function parseBackgroundLayer(e,t){let n=``,r=``,i=``,a=``,o=``,s=``,c=``,l=``,u=``,d=0;for(;d<e.length;){let m=e[d];if(m.type===1&&m.lower===`none`&&n===``)n=`none`,d++;else if(m.type===7||m.type===2&&(m.lower===`url`||Vl.has(m.lower))){if(n!==``)return null;n=m.type===7?serializeUrl(m.value):normalizeComponent(m,grammarFor(`background-image`))??m.text,d++}else if(isPositionComp(m)&&r===``){let t=d;for(;t<e.length&&t-d<4&&isPositionComp(e[t]);)t++;let n=parsePosition(e.slice(d,t));if(n===null)return null;if(r=n[0],i=n[1],d=t,d<e.length&&e[d].type===9&&e[d].value===`/`){d++;let t=grammarFor(`background-size`),n=[];for(;d<e.length&&n.length<2;){let r=normalizeComponent(e[d],t);if(r===null||(n.push(r),d++,r===`cover`||r===`contain`))break}if(n.length===0)return null;a=n.join(` `)}}else if(m.type===1&&Rl.has(m.lower)&&o===``){if(o=m.lower,m.lower!==`repeat-x`&&m.lower!==`repeat-y`&&d+1<e.length){let t=e[d+1];t.type===1&&Rl.has(t.lower)&&t.lower!==`repeat-x`&&t.lower!==`repeat-y`&&(o+=` `+t.lower,d++)}d++}else if(m.type===1&&zl.has(m.lower)&&l===``)l=m.lower,d++;else if(m.type===1&&Bl.has(m.lower)){if(s===``)s=m.lower;else if(c===``)c=m.lower;else return null;d++}else{if(t&&u===``){let e=normalizeColor(m.text);if(e!==null&&m.type!==10){u=e,d++;continue}}return null}}c===``&&s!==``&&(c=s);let m=[n,r,i,a,o,s,c,l,u];for(let e=0;e<m.length;e++)m[e]===``&&(m[e]=Hl[e]);return m}const Ul=/* @__PURE__ */ new Set([`caption`,`icon`,`menu`,`message-box`,`small-caption`,`status-bar`]),Wl=/* @__PURE__ */ new Set([`italic`,`oblique`]),Gl=/* @__PURE__ */ new Set([`small-caps`]),Kl=/* @__PURE__ */ new Set([`bold`,`bolder`,`lighter`]),ql=/* @__PURE__ */ new Set([`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`]);function expandFont(e){let t=items(e);if(t===null||t.length<2||t.length===1&&t[0].type===1&&Ul.has(t[0].lower))return null;let n=``,r=``,i=``,a=0,o=0;for(;a<t.length&&a<4;a++){let e=t[a];if(e.type===1){if(e.lower===`normal`){o++;continue}if(Wl.has(e.lower)&&n===``){n=e.lower;continue}if(Gl.has(e.lower)&&r===``){r=e.lower;continue}if(Kl.has(e.lower)&&i===``){i=e.lower;continue}if(ql.has(e.lower))continue;break}if(e.type===10&&i===``&&e.num>=1&&e.num<=1e3)i=formatNumber(e.num);else break}if(a>=t.length)return null;let s=normalizeComponent(t[a],grammarFor(`font-size`));if(s===null)return null;a++;let c=`normal`;if(a<t.length&&t[a].type===9&&t[a].value===`/`){if(a++,a>=t.length)return null;let e=normalizeComponent(t[a],grammarFor(`line-height`));if(e===null)return null;c=e,a++}if(a>=t.length)return null;let l=serializeFamilyList(t.slice(a));return l===null||o>3?null:[n||`normal`,r||`normal`,i||`normal`,s,c,l]}function expandShorthand(e,t){switch(e){case`margin`:case`padding`:case`border-width`:case`border-style`:case`border-color`:return expandBox(Ml.get(e),t);case`border-top`:case`border-right`:case`border-bottom`:case`border-left`:return parseBorderSide(t);case`border`:{let e=parseBorderSide(t);return e===null?null:[e[0],e[0],e[0],e[0],e[1],e[1],e[1],e[1],e[2],e[2],e[2],e[2],`none`]}case`flex`:return expandFlex(t);case`background-position`:{let e=items(t);if(e===null)return null;for(let t of e)if(!isPositionComp(t))return null;return parsePosition(e)}case`background`:{let e=items(t);if(e===null||e.length===0)return null;let n=0,r=0,i=null;for(let t=0;t<=e.length;t++)if(t===e.length||e[t].type===18){let a=parseBackgroundLayer(e.slice(n,t),t===e.length);if(a===null)return null;i=a,r++,n=t+1}return r>1?Ql:i}case`font`:return expandFont(t)}return null}const Jl=/* @__PURE__ */ new Map([[`outline`,[`outline-color`,`outline-style`,`outline-width`]],[`overflow`,[`overflow-x`,`overflow-y`]],[`gap`,[`row-gap`,`column-gap`]],[`inset`,[`top`,`right`,`bottom`,`left`]],[`list-style`,[`list-style-position`,`list-style-image`,`list-style-type`]],[`flex-flow`,[`flex-direction`,`flex-wrap`]]]);function pendingLonghandsMap(){return new Map([...Ml,...Jl])}function cascadeLonghandsOf(e){return Ml.get(e)??Jl.get(e)}function isCascadeOnlyShorthand(e){return Jl.has(e)}const Yl=/* @__PURE__ */ new Set([`visible`,`hidden`,`clip`,`scroll`,`auto`,`overlay`]),Xl=/* @__PURE__ */ new Set([`row`,`row-reverse`,`column`,`column-reverse`]),Zl=/* @__PURE__ */ new Set([`nowrap`,`wrap`,`wrap-reverse`]);function expandCascadeShorthand(e,t){switch(e){case`outline`:{let e=items(t);if(e===null||e.length<1||e.length>3)return null;let n=``,r=``,i=``,a=grammarFor(`outline-width`);for(let t of e){if(t.type===1&&(Fl.has(t.lower)||t.lower===`auto`)&&t.lower!==`hidden`){if(r!==``)return null;r=t.lower;continue}let e=normalizeComponent(t,a);if(e!==null){if(n!==``)return null;n=e;continue}let o=normalizeColor(t.text);if(o!==null&&t.type!==10){if(i!==``)return null;i=o}else return null}return[i||`currentcolor`,r||`none`,n||`medium`]}case`overflow`:case`flex-flow`:{let n=items(t);if(n===null||n.length<1||n.length>2)return null;for(let e of n)if(e.type!==1)return null;if(e===`overflow`){for(let e of n)if(!Yl.has(e.lower))return null;return[n[0].lower,(n[1]??n[0]).lower]}let r=``,i=``;for(let e of n)if(Xl.has(e.lower)&&r===``)r=e.lower;else if(Zl.has(e.lower)&&i===``)i=e.lower;else return null;return[r||`row`,i||`nowrap`]}case`gap`:{let e=items(t);if(e===null||e.length<1||e.length>2)return null;let n=grammarFor(`row-gap`),r=[];for(let t of e){let e=normalizeComponent(t,n);if(e===null)return null;r.push(e)}return[r[0],r[1]??r[0]]}case`inset`:return expandBox(Jl.get(`inset`),t);case`list-style`:{let e=items(t);if(e===null||e.length<1||e.length>3)return null;let n=``,r=``,i=``,a=0;for(let t of e)if(t.type===1&&(t.lower===`inside`||t.lower===`outside`)&&n===``)n=t.lower;else if(t.type===1&&t.lower===`none`)a++;else if((t.type===7||t.type===2&&Vl.has(t.lower))&&r===``)r=t.type===7?serializeUrl(t.value):t.text;else if((t.type===1||t.type===5||t.type===2&&t.lower===`symbols`)&&i===``)i=t.type===1?t.lower:t.text;else return null;return a>+(r===``)+ +(i===``)?null:(a!==0&&(r===``&&(r=`none`),i===``&&(i=`none`)),[n||`outside`,r||`none`,i||`disc`])}}return null}function serializeCascadeShorthand(e,t){switch(e){case`overflow`:case`gap`:return t[0]===t[1]?t[0]:t[0]+` `+t[1];case`inset`:return serializeBox(t);case`outline`:case`list-style`:case`flex-flow`:return t.join(` `)}return``}const Ql=[];function serializeBox(e){let[t,n,r,i]=e;return i===n?r===t?n===t?t:t+` `+n:t+` `+n+` `+r:t+` `+n+` `+r+` `+i}function serializeSide(e,t,n,r){if(r)return e+` `+t+` `+n;let i=[];return e!==`medium`&&i.push(e),t!==`none`&&i.push(t),n!==`currentcolor`&&i.push(n),i.length===0?e:i.join(` `)}function serializeShorthand(e,t,n){let r=0;for(let e of t)isCSSWideKeyword(e)&&r++;if(r!==0){if(r!==t.length)return``;for(let e of t)if(e!==t[0])return``;return t[0]}switch(e){case`margin`:case`padding`:case`border-width`:case`border-style`:case`border-color`:return serializeBox(t);case`border-top`:case`border-right`:case`border-bottom`:case`border-left`:return serializeSide(t[0],t[1],t[2],n);case`border`:for(let e=0;e<3;e++){let n=e*4;if(t[n]!==t[n+1]||t[n]!==t[n+2]||t[n]!==t[n+3])return``}return t[12]===`none`?serializeSide(t[0],t[4],t[8],n):``;case`flex`:return t[0]+` `+t[1]+` `+t[2];case`background-position`:return t[0]+` `+t[1];case`background`:{if(n)return`${t[8]} ${t[0]} ${t[7]} ${t[4]} ${t[1]} ${t[2]} / ${t[3]} ${t[5]} ${t[6]}`.replace(/\s+/g,` `);let e=[];return t[0]!==`none`&&e.push(t[0]),(t[1]!==`0%`||t[2]!==`0%`||t[3]!==`auto`)&&e.push(t[1]+` `+t[2]+(t[3]===`auto`?``:` / `+t[3])),t[4]!==`repeat`&&e.push(t[4]),t[7]!==`scroll`&&e.push(t[7]),(t[5]!==`padding-box`||t[6]!==`border-box`)&&e.push(t[5]===t[6]?t[5]:t[5]+` `+t[6]),t[8]!==`transparent`&&t[8]!==`rgba(0, 0, 0, 0)`&&e.push(t[8]),e.length===0?`none`:e.join(` `)}case`font`:{let e=[];return t[0]!==`normal`&&e.push(t[0]),t[1]!==`normal`&&e.push(t[1]),t[2]!==`normal`&&!(n&&t[2]===`400`)&&e.push(t[2]),e.push(t[3]+(t[4]===`normal`?``:` / `+t[4])),e.push(t[5]),e.join(` `)}}return``}var DeclBlock=class{names;values;important;dirty;namesSynced;serialized;serializedCount;serializedFamilies;serializedPlain;constructor(){this.names=[],this.values=[],this.important=null,this.dirty=!1,this.namesSynced=0,this.serialized=``,this.serializedCount=0,this.serializedFamilies=0,this.serializedPlain=!0}get length(){return this.names.length}indexOf(e,t=0){let n=this.names;for(let r=t;r<n.length;r++)if(n[r]===e)return r;return-1}isImportant(e){return this.important?.[e]===!0}markImportant(e){(this.important??=Array(e+1))[e]=!0}clear(){this.names.length=0,this.values.length=0,this.important=null,this.namesSynced=0,this.serialized=``,this.serializedCount=0,this.serializedFamilies=0,this.serializedPlain=!0}put(e,t,n){let r=this.indexOf(e);r===-1?(this.names.push(e),this.values.push(t),n&&this.markImportant(this.names.length-1),this.dirty=!0):(this.values[r]!==t||this.isImportant(r)!==n)&&(this.serializedCount===this.names.length&&this.serializedPlain&&shorthandsContaining(e)===void 0?this.spliceSerialized(r,t,n):this.serializedCount=-1,this.values[r]=t,n?this.markImportant(r):this.important!==null&&r<this.important.length&&(this.important[r]=!1),this.dirty=!0)}spliceSerialized(e,t,n){let r=this.names,i=this.values,a=this.important,o=4*e;for(let t=0;t<e;t++)o+=r[t].length+i[t].length;if(a!==null)for(let t=0;t<e;t++)a[t]&&(o+=11);let s=o+r[e].length+i[e].length+(a?.[e]?14:3),c=this.serialized;this.serialized=c.slice(0,o)+serializeDeclaration(r[e],t,n)+c.slice(s)}putParsed(e,t,n){let r=this.indexOf(e);if(r!==-1){if(this.isImportant(r)&&!n)return;this.names.splice(r,1),this.values.splice(r,1),this.important?.splice(r,1),r<this.namesSynced&&(this.namesSynced=r),this.serializedCount=-1}this.names.push(e),this.values.push(t),n&&this.markImportant(this.names.length-1)}removeOne(e){let t=this.indexOf(e);return t!==-1&&(this.names.splice(t,1),this.values.splice(t,1),this.important?.splice(t,1),this.dirty=!0,t<this.namesSynced&&(this.namesSynced=t),this.serializedCount=-1,!0)}setValue(e,t,n,r){if(e=canonicalPropertyName(e),isCustomPropertyName(e)){let i=normalizeCustom(t);return i!==null&&(r?this.putParsed(e,i,n):this.put(e,i,n),!0)}if(isExpandedShorthand(e)){let i=longhandValues(e,t);if(i===null)return!1;let a=longhandsOf(e);if(i===eu){for(let e of a)this.removeOne(e);return this.putOrParsed(e,t.trim(),n,r),!0}this.removeOne(e);for(let e=0;e<a.length;e++)this.putOrParsed(a[e],i[e],n,r);return!0}if(!isSupportedProperty(e))return!1;let i=normalizeLonghand(e,t);return i!==null&&(this.putOrParsed(e,i,n,r),!0)}putOrParsed(e,t,n,r){r?this.putParsed(e,t,n):this.put(e,t,n)}parse(e){this.clear(),e!==``&&this.addRaw(parseDeclarationList(e))}addRaw(e){for(let t=0;t<e.length;t++){let n=e[t],r=isCustomPropertyName(n.name)?n.name:n.name.toLowerCase();this.setValue(r,n.value,n.important,!0)}}remove(e){e=canonicalPropertyName(e);let t=this.removeOne(e),n=longhandsOf(e);if(n!==void 0)for(let e of n)this.removeOne(e)&&(t=!0);return t}getPropertyValue(e){e=canonicalPropertyName(e);let t=this.indexOf(e);if(t!==-1)return this.values[t];let n=longhandsOf(e);if(n===void 0)return``;let r=[],i=-1;for(let e of n){let t=this.indexOf(e);if(t===-1)return``;let n=+!!this.isImportant(t);if(i===-1)i=n;else if(i!==n)return``;r.push(this.values[t])}return serializeShorthand(e,r,!1)}getPropertyPriority(e){if(this.important===null)return``;e=canonicalPropertyName(e);let t=this.indexOf(e);if(t!==-1)return this.isImportant(t)?`important`:``;let n=longhandsOf(e);if(n===void 0)return``;for(let e of n){let t=this.indexOf(e);if(t===-1||!this.isImportant(t))return``}return`important`}serialize(){let e=this.names.length,t=this.serializedCount;return t===e||(t<0||!this.serializeAppended(t))&&(this.serialized=this.serializeAll(0),this.serializedCount=e,this.serializedFamilies=-1,this.serializedPlain=!$l),this.serialized}serializeAppended(e){let t=this.names,n=t.length,r=0;for(let i=e;i<n;i++)r|=shorthandFamily(t[i]);let i=this.serializedFamilies;if(r!==0&&i===-1){i=0;for(let n=0;n<e;n++)i|=shorthandFamily(t[n])}if((r&i)!==0)return!1;let a=this.serializeAll(e);return $l&&(this.serializedPlain=!1),this.serialized=this.serialized===``?a:this.serialized+` `+a,this.serializedCount=n,this.serializedFamilies=i===-1?-1:i|r,!0}serializeAll(e=0){let t=this.names,n=t.length;if($l=!1,n===e)return``;if(n===e+1)return serializeDeclaration(t[e],this.values[e],this.isImportant(e));let r=``,i=null;for(let a=e;a<n;a++){let o=t[a];if(i!==null&&i.has(o))continue;let s=this.isImportant(a),c=shorthandsContaining(o),l=!1;if(c!==void 0)for(let t=0;t<c.length&&!l;t++){let a=c[t],o=longhandsOf(a),u=o.length<=n-e;for(let t=0;t<o.length&&u;t++){let n=this.indexOf(o[t],e);u=n!==-1&&this.isImportant(n)===s&&(i===null||!i.has(o[t]))}if(!u)continue;let d=Array(o.length);for(let t=0;t<o.length;t++)d[t]=this.values[this.indexOf(o[t],e)];let m=serializeShorthand(a,d,!1);if(m!==``){i===null&&(i=/* @__PURE__ */ new Set);for(let e of o)i.add(e);r+=(r===``?``:` `)+serializeDeclaration(a,m,s),l=!0}}l||(r+=(r===``?``:` `)+serializeDeclaration(o,this.values[a],s))}return $l=i!==null,r}};let $l=!1;function serializeDeclaration(e,t,n){return e+`: `+t+(n?` !important;`:`;`)}const eu=Ql,tu=/* @__PURE__ */ new Map;function longhandValues(e,t){let n=tu.get(e);if(n===void 0)tu.set(e,n=/* @__PURE__ */ new Map);else{let e=n.get(t);if(e!==void 0)return e}let r=null,i=t.trim(),a=i===``?null:splitComponents(i);return r=a===null?null:a.length===1&&a[0].type===1&&isCSSWideKeyword(a[0].lower)?Array(longhandsOf(e).length).fill(a[0].lower):containsVar(i)?eu:expandShorthand(e,i),n.size===256&&n.clear(),n.set(t,r),r}function parseDeclBlock(e){let t=new DeclBlock;return t.parse(e),t}var CSSStyleDeclaration=class{[er];[rr];[M];[mr];[ri];[On];constructor(e=null,t=null,n=null){if(nu||installAccessors(),this[er]=e,this[rr]=n,this[M]=t??new DeclBlock,this[mr]=!1,this[ri]=!1,this[On]=0,e!==null){let t=attr(e[z],`style`);t!==null&&t!==``&&this[M].parse(t)}this[M].names.length!==0&&this._syncIndices()}_attributeChanged(e){this[ri]||(this[M].parse(e??``),this._syncIndices())}_changed(){this._syncIndices();let e=this[er];if(e!==null){this[ri]=!0;try{setAttribute(e[z],`style`,this[M].serialize())}finally{this[ri]=!1}}else this[rr]!==null&&this[rr]._declarationsChanged()}_syncIndices(){let e=this[M],t=e.names,n=t.length,r=e.namesSynced;if(r===n&&n===this[On])return;let i=this;for(let e=r;e<n;e++)i[e]=t[e];for(let e=n;e<this[On];e++)delete i[e];this[On]=n,e.namesSynced=n}_checkWritable(){if(this[mr])throw new DOMException(`Failed to execute on 'CSSStyleDeclaration': These styles are computed, and therefore read-only.`,`NoModificationAllowedError`)}get cssText(){return this[mr]?``:this[M].serialize()}set cssText(e){this._checkWritable(),this[M].parse(e===null?``:String(e)),this._changed()}get length(){return this[M].names.length}item(e){return this[M].names[e>>>0]??``}getPropertyValue(e){let t=String(e);return this[M].getPropertyValue(isCustomPropertyName(t)?t:t.toLowerCase())}getPropertyPriority(e){let t=String(e);return this[M].getPropertyPriority(isCustomPropertyName(t)?t:t.toLowerCase())}setProperty(e,t,n=``){this._checkWritable();let r=String(e);isCustomPropertyName(r)||(r=r.toLowerCase());let i=t===null?``:idlString(t);if(i===``){this.removeProperty(r);return}let a=n===null?``:idlString(n),o=!1;if(a!==``){if(a.toLowerCase()!==`important`)return;o=!0}let s=this[M];s.dirty=!1,s.setValue(r,i,o,!1)&&s.dirty&&this._changed()}removeProperty(e){this._checkWritable();let t=String(e);isCustomPropertyName(t)||(t=t.toLowerCase());let n=this[M].getPropertyValue(t);return this[M].remove(t)&&this._changed(),n}get parentRule(){return this[rr]}get cssFloat(){return this.getPropertyValue(`float`)}set cssFloat(e){this._setNamed(`float`,e)}_setNamed(e,t){this[mr]||this.setProperty(e,t===null?``:idlString(t))}*[Symbol.iterator](){let e=this.length;for(let t=0;t<e;t++)yield this.item(t)}get[Symbol.toStringTag](){return`CSSStyleDeclaration`}};let nu=!1;const ru=Object.defineProperty;function installAccessors(){nu=!0;let e=CSSStyleDeclaration.prototype,t=Object.create(null),define=(n,r)=>{n in t||Object.hasOwn(e,n)||ru(t,n,r)},n=allPropertyNames();for(let e=0;e<n.length;e++){let t=n[e],r={get(){return this.getPropertyValue(t)},set(e){this._setNamed(t,e)},enumerable:!0,configurable:!0};define(t,r),t.indexOf(`-`)!==-1&&(define(cssPropertyToIDLAttribute(t,!1),r),t.charCodeAt(0)===45&&define(cssPropertyToIDLAttribute(t,!0),r))}Object.setPrototypeOf(t,Object.getPrototypeOf(e)),Object.setPrototypeOf(e,t)}function idlString(e){if(typeof e==`symbol`)throw TypeError(`Cannot convert a Symbol value to a string`);return String(e)}const iu=[`jsdom-26`,`jsdom-30`,`modern`],au=`jsdom-30`,ou=iu,su=[`jsdom-30`,`modern`],cu=[`modern`],handlers=e=>e.map(e=>`on${e}`),on=(e,t)=>t.map(t=>`${e}.${t}`),lu=handlers([`gotpointercapture`,`lostpointercapture`,`pointercancel`,`pointerdown`,`pointerenter`,`pointerleave`,`pointermove`,`pointerout`,`pointerover`,`pointerrawupdate`,`pointerup`]),uu=handlers([`animationcancel`,`animationend`,`animationiteration`,`animationstart`,`command`,`selectionchange`,`selectstart`,`transitioncancel`,`transitionend`,`transitionrun`,`transitionstart`]),du=[`Document`,`HTMLElement`,`SVGElement`,`MathMLElement`],fu=[{globals:[`PointerEvent`,...lu],members:du.flatMap(e=>on(e,lu)),profiles:su,reason:"jsdom 27 added pointer events. Libraries pick pointer or mouse/touch code paths by detecting `PointerEvent` or `onpointerdown` (React Aria caches the choice at import), so suites written for jsdom 26 break when they exist, and again when they `delete global.PointerEvent` after installing a fake."},{globals:[`matchMedia`,`MediaQueryList`,`MediaQueryListEvent`],profiles:cu,reason:"No jsdom has matchMedia. Suites install their own (mock-match-media only polyfills it when it is missing: React Aria's `setMedia({pointer: 'coarse'})` did nothing with ours present) and components feature-detect it."},{globals:[`ResizeObserver`,`ResizeObserverEntry`,`ResizeObserverSize`],profiles:cu,reason:`No jsdom has ResizeObserver, and libraries detect it to pick their browser path: Base UI's ScrollArea then calls getAnimations(), which nothing implements. Suites written for jsdom install their own (Sentry's MockResizeObserver).`},{members:[`HTMLElement.inert`],profiles:cu,reason:"No jsdom has the `inert` IDL attribute. Libraries that find it mark content outside a modal `inert` instead of `aria-hidden` (React Aria's ariaHideOutside, Radix's hideOthers), which stock Testing Library's queries do not treat as inaccessible. The content attribute makes subtrees inert in every profile."},{globals:[`WebKitCSSMatrix`],profiles:cu,reason:"The geometry spec's legacy alias of DOMMatrix, which no jsdom has. Libraries that find it parse computed `transform` strings with it (Swiper's getTranslate) instead of their string fallback, and our parser throws SyntaxError on values jsdom-era suites never exercised."},{members:on(`Document`,[`elementFromPoint`,`elementsFromPoint`]),profiles:cu,reason:"No jsdom has the Document hit-test methods, and without layout ours find nothing. axe-core's isModalOpen calls `document.elementsFromPoint` once it has found no visible dialog: where the method is missing the check throws and axe reports it as incomplete, where it returns [] the check fails and `aria-hidden-focus` becomes a violation on the content a modal hides (Radix's Dialog and AlertDialog tests with jest-axe)."},{globals:[`visualViewport`],profiles:cu,reason:"Without layout its numbers mislead positioning libraries (Floating UI), which fall back to the document element when it is absent, as under jsdom. `createWindow({ visualViewport })` overrides the profile."},{globals:[`CSS`,`CSSConditionRule`,`CSSContainerRule`,`CSSFontFaceRule`,`CSSGroupingRule`,`CSSKeyframeRule`,`CSSKeyframesRule`,`CSSLayerBlockRule`,`CSSLayerStatementRule`,`CSSNamespaceRule`,`CSSNestedDeclarations`,`CSSPageRule`,`CSSRuleList`,`CSSScopeRule`,`CSSSupportsRule`],members:[`HTMLStyleElement.disabled`],profiles:ou,reason:"CSSOM classes are only reached through style sheets jsdom 26 also parses (its rule objects come from the cssom package). `CSS.escape`/`CSS.supports` behave as the polyfills suites install, which replace ours by assignment."},{globals:[`BeforeUnloadEvent`,`PromiseRejectionEvent`,`TransitionEvent`],members:[`MouseEvent.movementX`,`MouseEvent.movementY`,`CustomElementRegistry.getName`],profiles:ou,reason:`Event classes and members nothing feature-detects; our own dispatch creates these events.`},{globals:[`AnimationEvent`,`ClipboardEvent`,`CommandEvent`,`DragEvent`,`FormDataEvent`,`TextEvent`,`ToggleEvent`,`Touch`,`TouchList`,...uu,`onpagereveal`,`onpageswap`],members:[...[`Document`,`HTMLElement`,`SVGElement`].flatMap(e=>on(e,uu)),...on(`HTMLBodyElement`,[`onpagereveal`,`onpageswap`]),...on(`HTMLFrameSetElement`,[`onpagereveal`,`onpageswap`]),`TouchEvent.getModifierState`,`PopStateEvent.hasUAVisualTransition`,`InputEvent.dataTransfer`],profiles:ou,reason:`Event classes and handler attributes for events our dispatch fires (popover toggle, command, form data, drag, clipboard, animation/transition). Libraries construct or listen for them; none switch code paths on their presence.`},{globals:[`Clipboard`,`ClipboardItem`,`DataTransfer`,`DataTransferItem`,`DataTransferItemList`],members:[`Navigator.clipboard`],profiles:ou,reason:"user-event's `setup()` replaces `navigator.clipboard` with its stub either way, and builds DataTransfer objects for drag/paste whether or not the DOM has the class."},{globals:[`IntersectionObserver`,`IntersectionObserverEntry`],profiles:ou,reason:"Component libraries construct it unconditionally and crash when it is missing; ours never reports entries (no layout), and suites that need entries install a mock by assignment. The entry interface comes with it: libraries check `IntersectionObserverEntry.prototype` before trusting the observer (react-lazy-load-image-component crashed reading it)."},{globals:/* @__PURE__ */ `SVGAElement.SVGCircleElement.SVGClipPathElement.SVGEllipseElement.SVGFilterElement.SVGForeignObjectElement.SVGGeometryElement.SVGGradientElement.SVGImageElement.SVGLineElement.SVGLinearGradientElement.SVGMarkerElement.SVGMaskElement.SVGPathElement.SVGPatternElement.SVGPolygonElement.SVGPolylineElement.SVGRadialGradientElement.SVGRectElement.SVGScriptElement.SVGStopElement.SVGStyleElement.SVGTSpanElement.SVGTextContentElement.SVGTextElement.SVGTextPathElement.SVGTextPositioningElement.SVGUseElement.SVGViewElement.MathMLElement`.split(`.`),members:[`SVGElement.autofocus`,...on(`SVGGraphicsElement`,[`getBBox`,`getCTM`,`getScreenCTM`]),...on(`SVGSVGElement`,[`animationsPaused`,`checkEnclosure`,`checkIntersection`,`createSVGAngle`,`createSVGLength`,`createSVGMatrix`,`createSVGPoint`,`createSVGTransform`,`deselectAll`,`getCurrentTime`,`getEnclosureList`,`getIntersectionList`,`pauseAnimations`,`setCurrentTime`,`unpauseAnimations`])],profiles:ou,reason:`Element classes for markup jsdom creates as plain SVGElement/Element (instanceof checks only), and SVG geometry that returns zeros without layout; suites that need numbers assign their own getBBox.`},{globals:[`DOMMatrix`,`DOMMatrixReadOnly`,`DOMPoint`,`DOMPointReadOnly`,`DOMQuad`,`DOMRectList`],members:[`Range.getBoundingClientRect`,`Range.getClientRects`],profiles:ou,reason:"Geometry values (zeros without layout). Editors call `range.getBoundingClientRect()`, which jsdom lacks; suites mock it by assignment."},{globals:[`CSSPropertyRule`,`CSSStartingStyleRule`,`CustomStateSet`,`DOMStringList`,`MediaError`,`TimeRanges`,`VisualViewport`],members:[...on(`CSSRule`,[`DOCUMENT_RULE`,`REGION_STYLE_RULE`,`VIEWPORT_RULE`]),...on(`CSSRule.static`,[`DOCUMENT_RULE`,`REGION_STYLE_RULE`,`VIEWPORT_RULE`]),`CSSStyleDeclaration.cssFloat`,...on(`ElementInternals`,[`ariaActiveDescendantElement`,`ariaBrailleLabel`,`ariaBrailleRoleDescription`,`ariaControlsElements`,`ariaDescribedByElements`,`ariaDetailsElements`,`ariaErrorMessageElements`,`ariaFlowToElements`,`ariaLabelledByElements`,`ariaOwnsElements`,`checkValidity`,`form`,`reportValidity`,`setFormValue`,`setValidity`,`states`,`validationMessage`,`validity`,`willValidate`])],profiles:ou,reason:`Interfaces reached only through objects that create them (style sheets, form-associated custom elements, media elements).`},{globals:[`cancelIdleCallback`,`requestIdleCallback`,`clientInformation`,`closed`,`crossOriginIsolated`,`isSecureContext`,`opener`,`reportError`],members:[`History.scrollRestoration`,...on(`Screen`,[`availLeft`,`availTop`,`isExtended`]),...on(`Navigator`,[`deviceMemory`,`doNotTrack`,`maxTouchPoints`,`oscpu`,`pdfViewerEnabled`,`registerProtocolHandler`,`sendBeacon`,`unregisterProtocolHandler`,`userActivation`,`vibrate`,`webdriver`])],profiles:ou,reason:`Window and navigator members with browser defaults (no touch points, not a webdriver). Fake timers fake requestIdleCallback like the other timer functions; libraries that fall back to setTimeout without it behave the same.`},{members:[...on(`Document`,[`adoptedStyleSheets`,`alinkColor`,`bgColor`,`designMode`,`domain`,`fgColor`,`linkColor`,`moveBefore`,`scrollingElement`,`vlinkColor`]),`Document.static.parseHTMLUnsafe`,`DocumentFragment.moveBefore`,...on(`Element`,[`ariaActiveDescendantElement`,`ariaBrailleLabel`,`ariaBrailleRoleDescription`,`ariaControlsElements`,`ariaDescribedByElements`,`ariaDetailsElements`,`ariaErrorMessageElements`,`ariaFlowToElements`,`ariaLabelledByElements`,`ariaOwnsElements`,`checkVisibility`,`dataset`,`getHTML`,`moveBefore`,`part`,`scroll`,`scrollBy`,`scrollIntoView`,`scrollTo`,`setHTMLUnsafe`]),...on(`ShadowRoot`,[`adoptedStyleSheets`,`clonable`,`delegatesFocus`,`elementFromPoint`,`elementsFromPoint`,`getHTML`,`serializable`,`setHTMLUnsafe`,`slotAssignment`,`styleSheets`]),...on(`Selection`,[`direction`,`getComposedRanges`,`modify`])],profiles:ou,reason:"DOM members suites written for jsdom stub by assignment when they need them (`Element.prototype.scrollIntoView = vi.fn()`), which replaces ours. `Element.dataset` is on Element (jsdom: on HTMLElement and SVGElement)."},{members:[...on(`HTMLElement`,[`accessKeyLabel`,`autocapitalize`,`autocorrect`,`autofocus`,`contentEditable`,`enterKeyHint`,`hidePopover`,`innerText`,`inputMode`,`isContentEditable`,`outerText`,`popover`,`showPopover`,`spellcheck`,`togglePopover`,`writingSuggestions`]),...on(`HTMLButtonElement`,[`command`,`commandForElement`,`formAction`,`formEnctype`,`formMethod`,`popoverTargetAction`,`popoverTargetElement`]),...on(`HTMLInputElement`,[`formAction`,`formEnctype`,`formMethod`,`height`,`popoverTargetAction`,`popoverTargetElement`,`showPicker`,`width`]),...on(`HTMLDialogElement`,[`close`,`closedBy`,`requestClose`,`returnValue`,`show`,`showModal`]),...on(`HTMLAnchorElement`,[`ping`,`referrerPolicy`]),...on(`HTMLAreaElement`,[`download`,`hreflang`,`ping`,`referrerPolicy`,`type`]),`HTMLDetailsElement.name`,`HTMLEmbedElement.getSVGDocument`,...on(`HTMLFormElement`,[`autocomplete`,`encoding`,`rel`,`relList`]),...on(`HTMLIFrameElement`,[`allow`,`loading`,`referrerPolicy`,`sandbox`]),...on(`HTMLImageElement`,[`decode`,`decoding`,`fetchPriority`,`loading`,`referrerPolicy`,`x`,`y`]),...on(`HTMLLinkElement`,[`as`,`blocking`,`disabled`,`fetchPriority`,`imageSizes`,`imageSrcset`,`integrity`,`referrerPolicy`,`sizes`]),...on(`HTMLMarqueeElement`,[`loop`,`start`,`stop`]),...on(`HTMLMediaElement`,[`disableRemotePlayback`,`error`,`fastSeek`,`getStartDate`,`loading`,`mediaKeys`,`preservesPitch`,`setMediaKeys`,`setSinkId`,`sinkId`,`srcObject`]),`HTMLMetaElement.media`,...on(`HTMLObjectElement`,[`contentWindow`,`getSVGDocument`]),...on(`HTMLScriptElement`,[`async`,`blocking`,`fetchPriority`,`integrity`,`noModule`,`referrerPolicy`]),`HTMLScriptElement.static.supports`,...on(`HTMLSelectElement`,[`autocomplete`,`showPicker`]),`HTMLSlotElement.assign`,...on(`HTMLSourceElement`,[`height`,`width`]),`HTMLStyleElement.blocking`,...on(`HTMLTemplateElement`,[`shadowRootClonable`,`shadowRootDelegatesFocus`,`shadowRootMode`,`shadowRootSerializable`,`shadowRootSlotAssignment`]),`HTMLTrackElement.track`,...on(`HTMLVideoElement`,[`disablePictureInPicture`,`getVideoPlaybackQuality`,`requestPictureInPicture`])],profiles:ou,reason:"Reflected attributes and element behavior we implement (popover, dialog, invoker commands, innerText). Where jsdom lacks a method, suites assign their own (`HTMLDialogElement.prototype.showModal = vi.fn()`), which replaces ours."}];function resolveCompat(e){if(e===void 0)return au;if(iu.includes(e))return e;throw TypeError(`Unknown compat profile ${JSON.stringify(e)}: expected ${iu.map(e=>JSON.stringify(e)).join(`, `)}.`)}const pu=/* @__PURE__ */ new Map;function hiddenGlobals(e){let t=pu.get(e);if(t===void 0){let n=/* @__PURE__ */ new Set;for(let t of fu)if(!(t.globals===void 0||t.profiles.includes(e)))for(let e of t.globals)n.add(e);pu.set(e,t=n)}return t}function compatExposes(e,t){for(let n of fu)if(n.globals?.includes(t)||n.members?.includes(t))return n.profiles.includes(e);return!0}const mu=/* @__PURE__ */ new Map;function deferCompatMember(e,t,n){let r=Object.getOwnPropertyDescriptor(e,n);if(r===void 0)throw Error(`deferCompatMember: ${t}.${n} is not defined`);delete e[n],mu.set(`${t}.${n}`,{owner:e,descriptor:r})}const hu=/* @__PURE__ */ new Map;function deferredCompatMembers(){return mu}let gu=null;function gatedMembers(){if(gu!==null)return gu;gu=[];for(let e of fu)if(e.members!==void 0&&e.profiles.length!==iu.length)for(let t of e.members){let n=t.split(`.`),r=n.length===3&&n[1]===`static`;gu.push({key:t,iface:n[0],member:n[n.length-1],isStatic:r,profiles:e.profiles})}return gu}function installCompatMembers(e,t){let n=[];for(let r of gatedMembers()){let i=t[r.iface];if(i===void 0)continue;let a=r.isStatic?i:i.prototype;if(a===void 0)continue;let o=r.profiles.includes(e),s=Object.hasOwn(a,r.member);if(o&&!s){let e=mu.get(r.key)?.descriptor??hu.get(r.key);if(e===void 0)continue;Object.defineProperty(a,r.member,e),n.push(()=>delete a[r.member])}else if(!o&&s){let e=Object.getOwnPropertyDescriptor(a,r.member);hu.set(r.key,e),delete a[r.member],n.push(()=>Object.defineProperty(a,r.member,e))}}return()=>{for(let e=n.length-1;e>=0;e--)n[e]()}}function fireAnEvent(e,t,n,r,i=!1){let a=n===void 0?new Event(e,r):new n(e,r);return setTrusted(a),dispatch(a,t,i)}function dispatchTrusted(e,t){return setTrusted(e),dispatch(e,t)}function fireSyntheticPointerEvent(e,t,n,r){let i=t[z],a=i===void 0?null:i.doc[Y],o=new PointerEvent(e,{pointerId:-1,...r,bubbles:!0,cancelable:!0,composed:!0,view:a});return n||setTrusted(o),dispatch(o,t)}function fireEvent(e,t,n=!1,r=!1){return fireAnEvent(t,e,void 0,{bubbles:n,cancelable:r})}function fireFocusEvent(e,t,n,r,i){fireAnEvent(t,e,FocusEvent,{bubbles:r,cancelable:!1,composed:!0,relatedTarget:n,view:i,detail:0})}function fireToggleEvent(e,t,n,r,i,a=null){return fireAnEvent(t,e,ToggleEvent,{bubbles:!1,cancelable:i,oldState:n,newState:r,source:a})}function fireSyntheticClick(e){return fireSyntheticPointerEvent(`click`,e,!0)}function elementTaskWindow(e){return(`doc`in e?e:e[z]).doc[Y]??currentWindowOrNull()}function queueElementTask(e,t){let n=elementTaskWindow(e);n===null?setTimeout(t,0):n._task(t,0)}function queueToggleTask(e,t,n,r){let i=t?.delivery.deref(),a,o;t&&i?.cancel?(i.cancel(),i.fire=r,a=i,o=t):(a={fire:r},o={oldState:t?.oldState??n,delivery:new WeakRef(a)});let run=()=>{a.cancel=void 0,a.fire(o.oldState)},s=elementTaskWindow(e);if(s===null){let e=clearTimeout,t=setTimeout(run,0);a.cancel=()=>e(t)}else{let e=s._task(run,0);a.cancel=e===null?void 0:()=>s._cancelTask(e)}return o}var NodeCache=class{roleVersion;role;nameVersion;name;styleVersion;styleSheetVersion;style;computedStyle;ariaNameStyleVersion;ariaHiddenVersion;ariaHiddenStyleVersion;ariaHiddenBits;constructor(){this.roleVersion=-1,this.role=``,this.nameVersion=-1,this.name=``,this.styleVersion=-1,this.styleSheetVersion=-1,this.style=null,this.computedStyle=null,this.ariaNameStyleVersion=-1,this.ariaHiddenVersion=-1,this.ariaHiddenStyleVersion=-1,this.ariaHiddenBits=0}};function nodeCache(e){let t=e.cache;return t===null&&(e.cache=t=new NodeCache),t}function hex(e){return e.toString(16)}function serializeIdentifier(e){let t=``,n=e.length,r=n>0?e.charCodeAt(0):-1;for(let i=0;i<n;i++){let a=e.charCodeAt(i);t+=a===0?`�`:a>=1&&a<=31||a===127||i===0&&a>=48&&a<=57||i===1&&a>=48&&a<=57&&r===45?`\\`+hex(a)+` `:i===0&&a===45&&n===1?`\\-`:a>=128||a===45||a===95||a>=48&&a<=57||a>=65&&a<=90||a>=97&&a<=122?e[i]:`\\`+e[i]}return t}function serializeString(e){let t=`"`;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t+=r===0?`�`:r>=1&&r<=31||r===127?`\\`+hex(r)+` `:r===34||r===92?`\\`+e[n]:e[n]}return t+`"`}function serializeAnPlusB(e,t){if(e===0)return String(t);let n=e===1?`n`:e===-1?`-n`:String(e)+`n`;return t>0?n+=`+`+String(t):t<0&&(n+=String(t)),n}let _u=null;function withNamespaceContext(e,t){let n=_u;_u=e??null;try{return t()}finally{_u=n}}function hasDefaultNamespace(){return _u!==null&&_u.defaultNamespace!==void 0}function serializeNamespace(e){switch(e.nsKind){case 1:return hasDefaultNamespace()?`*|`:``;case 2:return`|`;case 3:return prefixIsDefault(e.nsPrefix)?``:serializeIdentifier(e.nsPrefix)+`|`}return``}function prefixIsDefault(e){if(!hasDefaultNamespace()||_u.namespaces===void 0)return!1;let t=_u.namespaces.get(e);return t!==void 0&&t===_u.defaultNamespace}function attrOp(e){switch(e){case 1:return`=`;case 2:return`~=`;case 3:return`|=`;case 4:return`^=`;case 5:return`$=`;case 6:return`*=`}return``}function joinArgs(e,t,n){let r=``;for(let i=0;i<e.length;i++)i>0&&(r+=t),r+=n?serializeIdentifier(e[i]):e[i];return r}function serializeSimple(e){switch(e.kind){case 1:return serializeNamespace(e)+serializeIdentifier(e.name);case 2:return serializeNamespace(e)+`*`;case 3:return`#`+serializeIdentifier(e.name);case 4:return`.`+serializeIdentifier(e.name);case 5:{let t=`[`;return e.nsKind===1?t+=`*|`:e.nsKind===3&&(t+=serializeIdentifier(e.nsPrefix)+`|`),t+=serializeIdentifier(e.name),e.op!==0&&(t+=attrOp(e.op)+serializeString(e.value),e.caseFlag===1?t+=` i`:e.caseFlag===2&&(t+=` s`)),t+`]`}case 6:{let t=e.pseudo;if(t===5||t===6||t===7||t===8){let t=`:`+e.name+`(`+serializeAnPlusB(e.a,e.b);return e.list!==null&&(t+=` of `+serializeSelectorList(e.list)),t+`)`}if(t===11){let t=`:`+e.name+`(`;for(let n=0;n<e.args.length;n++)n>0&&(t+=`, `),t+=needsString(e.args[n])?serializeString(e.args[n]):serializeIdentifier(e.args[n]);return t+`)`}return t===12||t===13?`:`+e.name+`(`+serializeIdentifier(e.args[0])+`)`:t===88?e.args.length===0?`:heading`:`:heading(`+joinArgs(e.args,`, `,!1)+`)`:e.list===null?`:`+e.name:`:`+e.name+`(`+serializeSelectorList(e.list)+`)`}case 7:return e.list===null?e.pseudo===3||e.args.length!==0?`::`+e.name+`(`+joinArgs(e.args,` `,!0)+`)`:`::`+e.name:`::`+e.name+`(`+serializeSelectorList(e.list)+`)`}return``}function needsString(e){if(e.length===0)return!0;let t=e.charCodeAt(0);return t===42||t>=48&&t<=57}function serializeCompound(e){let t=``,n=e.simples.length;for(let r=0;r<n;r++){let i=e.simples[r];r===0&&n>1&&i.kind===2&&(i.nsKind===1&&!hasDefaultNamespace()||i.nsKind===0||i.nsKind===3&&prefixIsDefault(i.nsPrefix))||(t+=serializeSimple(i))}return t}function combinator(e){switch(e){case 1:return` `;case 2:return` > `;case 3:return` + `;case 4:return` ~ `}return` `}function serializeComplex(e){if(e.invalid)return e.text;let t=``;e.leading!==0&&e.leading!==1&&(t+=combinator(e.leading).slice(1));for(let n=0;n<e.compounds.length;n++)n>0&&(t+=combinator(e.combinators[n-1])),t+=serializeCompound(e.compounds[n]);return t}function serializeSelectorList(e){let t=``;for(let n=0;n<e.items.length;n++)n>0&&(t+=`, `),t+=serializeComplex(e.items[n]);return t}var CompiledSelector=class{text;specificity;keyKind;key;pseudoElement;volatile;h0;h1;h2;h3;direct;[At];[An];constructor(e,t){this.text=e.text,this.specificity=e.specificity;let n=subjectKey(e);this.keyKind=n.kind,this.key=n.value,this.pseudoElement=e.pseudoElement,this.volatile=t.volatile;let r=ancestorHashes(e);this.h0=r.length>0?r[0]:-1,this.h1=r.length>1?r[1]:-1,this.h2=r.length>2?r[2]:-1,this.h3=r.length>3?r[3]:-1,this.direct=!t.usesScope&&t.nthTests.length===0,this[At]=e,this[An]=t}get specificityTuple(){return unpackSpecificity(this.specificity)}};function selectorAttributeNames(e,t){attributeNamesIn(e[At],t)}function compileSelectorList(e,t){let n=new SelectorParser(e).parseSelectorList();if(n===null)return null;let r=[];for(let e=0;e<n.items.length;e++){let i=new CompileInfo;if(t?.namespaces!==void 0){let e=t.namespaces;i.resolve=t=>e.has(t)?e.get(t):void 0}t!==void 0&&`defaultNamespace`in t&&(i.defaultNs=t.defaultNamespace);let a=compileComplex(n.items[e],i);if(i.error!==``)return null;r.push(new CompiledSelector(a,i))}return{text:e,serialized:serializeSelectorList(n),selectors:r}}function isSupportedSelector(e){let t=new SelectorParser(e).parseSelectorList();if(t===null)return!1;for(let e=0;e<t.items.length;e++){let n=new CompileInfo;if(compileComplex(t.items[e],n),n.error!==``||n.forgivingDropped)return!1}return!0}function serializeSelector(e,t){let n=new SelectorParser(e).parseSelectorList();return n===null?null:t===void 0?serializeSelectorList(n):withNamespaceContext(t,()=>serializeSelectorList(n))}function normalizePseudo(e){let t=0;for(;t<e.length&&e.charCodeAt(t)===58;)t++;return t===0?e:e.slice(t)}function matchesSelector(e,t,n,r){let i=n==null||n===``?``:normalizePseudo(n);if(e.pseudoElement!==i)return!1;let a=setScope(r?.scope??null),o=r?.shadowHost===void 0?null:setHostContext(r.shadowHost);try{return r?.shadowHost!==void 0&&r.shadowHost===t?matchFeaturelessHost(e[At],t):matchComplex(e[At],t)}finally{setScope(a),r?.shadowHost!==void 0&&setHostContext(o),e[An].nthTests.length!==0&&resetMemos(e[An])}}function matchesSelectorDirect(e,t,n){return e.pseudoElement===n?e.direct?e[At].fn(t):matchesSelector(e,t,n):!1}const vu={width:1024,height:768,devicePixelRatio:1,mediaType:`screen`};var Tok=class{type;text;lower;num;unit;constructor(e,t,n,r,i){this.type=e,this.text=t,this.lower=n,this.num=r,this.unit=i}};function tokenize(e){let t=new CSSTokenizer(e),n=[];for(;;){let r=t.next();if(r===0)break;let i=r===1||r===2?t.value.toLowerCase():r===9?t.value:``;n.push(new Tok(r,e.slice(t.start,t.end),i,t.num,r===12?t.unit.toLowerCase():``))}return n}var MQNode=class{kind;children;name;op;value;op2;value2;constructor(e){this.kind=e,this.children=[],this.name=``,this.op=``,this.value=null,this.op2=``,this.value2=null}},MediaQuery=class{text;negated;type;condition;invalid;constructor(e,t,n,r,i){this.text=e,this.negated=t,this.type=n,this.condition=r,this.invalid=i}},MQParser=class{toks;i;constructor(e){this.toks=e,this.i=0}ws(){for(;this.i<this.toks.length&&this.toks[this.i].type===13;)this.i++}peek(){return this.ws(),this.i<this.toks.length?this.toks[this.i]:null}ident(e){let t=this.peek();return t!==null&&t.type===1&&t.lower===e&&(this.i++,!0)}atEnd(){return this.peek()===null}condition(e){if(this.ident(`not`)){let e=this.inParens();if(e===null)return null;let t=new MQNode(1);return t.children.push(e),t}let t=this.inParens();if(t===null)return null;let n=this.peek();if(n===null||n.type!==1||n.lower!==`and`&&n.lower!==`or`)return t;let r=n.lower;if(r===`or`&&!e)return null;let i=new MQNode(r===`and`?2:3);for(i.children.push(t);this.ident(r);){let e=this.inParens();if(e===null)return null;i.children.push(e)}let a=this.peek();return a!==null&&a.type===1&&(a.lower===`and`||a.lower===`or`)?null:i}inParens(){let e=this.peek();if(e===null)return null;if(e.type===2)return this.i++,this.skipToClose()?new MQNode(5):null;if(e.type!==21)return null;this.i++;let t=this.i,n=this.peek();if(n!==null&&(n.type===21||n.type===1&&n.lower===`not`||n.type===2)){let e=this.condition(!0);if(e!==null){let t=this.peek();if(t!==null&&t.type===22)return this.i++,e}this.i=t}let r=this.feature();if(r!==null){let e=this.peek();if(e!==null&&e.type===22)return this.i++,r}return this.i=t,this.skipToClose()?new MQNode(5):null}skipToClose(){let e=1;for(;this.i<this.toks.length;){let t=this.toks[this.i++].type;if(t===21||t===2||t===19||t===23)e++;else if((t===22||t===20||t===24)&&(e--,e===0))return!0}return!1}value(){let e=this.peek();if(e===null)return null;if(e.type===10){this.i++;let t=this.i,n=this.peek();if(n!==null&&n.type===9&&n.lower===`/`){this.i++;let t=this.peek();return t!==null&&t.type===10?(this.i++,[e,t]):null}return this.i=t,[e]}return e.type===12||e.type===1||e.type===11?(this.i++,[e]):null}op(){let e=this.peek();if(e===null||e.type!==9)return``;let t=e.lower;return t!==`<`&&t!==`>`&&t!==`=`?``:(this.i++,t!==`=`&&this.i<this.toks.length&&this.toks[this.i].type===9&&this.toks[this.i].lower===`=`?(this.i++,t+`=`):t)}feature(){let e=this.peek();if(e===null)return null;if(e.type===1){let t=this.i;this.i++;let n=new MQNode(4);n.name=e.lower;let r=this.peek();if(r!==null&&r.type===22)return n;if(r!==null&&r.type===16){this.i++;let e=this.value();return e===null?null:(n.op=`:`,n.value=e,n)}let i=this.op();if(i!==``){let e=this.value();return e===null?null:(n.op=i,n.value=e,n)}this.i=t}let t=this.value();if(t===null)return null;let n=this.op();if(n===``)return null;let r=this.peek();if(r===null||r.type!==1)return null;this.i++;let i=new MQNode(4);i.name=r.lower,i.op=flip$1(n),i.value=t;let a=this.op();if(a!==``){if(n[0]!==a[0]||n===`=`||a===`=`)return null;let e=this.value();if(e===null)return null;i.op2=a,i.value2=e}return i}};function flip$1(e){switch(e){case`<`:return`>`;case`<=`:return`>=`;case`>`:return`<`;case`>=`:return`<=`}return e}__name(flip$1,`flip`);const yu=/* @__PURE__ */ new Set([`all`,`screen`,`print`,`speech`,`tty`,`tv`,`projection`,`handheld`,`braille`,`embossed`,`aural`]);function serializeTokens(e){let t=``;for(let n=0;n<e.length;n++){let r=e[n];switch(r.type){case 13:t!==``&&!t.endsWith(` `)&&!t.endsWith(`(`)&&(t+=` `);break;case 1:t+=r.lower;break;case 16:for(t=t.trimEnd()+`: `;n+1<e.length&&e[n+1].type===13;)n++;break;case 22:t=t.trimEnd()+`)`;break;case 10:t+=formatNumber(r.num);break;case 12:t+=formatNumber(r.num)+r.unit;break;case 9:if(r.lower===`/`)for(t=t.trimEnd()+` / `;n+1<e.length&&e[n+1].type===13;)n++;else t+=r.text;break;default:t+=r.text}}return t.trim()}function parseQuery(e){let t=new MQParser(e),n=serializeTokens(e),r=new MediaQuery(`not all`,!1,`all`,null,!0);if(t.atEnd())return r;let i=t.peek();if(i.type===1&&i.lower!==`not`&&i.lower!==`only`&&i.lower!==`and`&&i.lower!==`or`){let e=i.lower;t.i++;let a=null;return t.ident(`and`)&&(a=t.condition(!1),a===null)||!t.atEnd()||e===`layer`?r:new MediaQuery(n,!1,e,a,!1)}if(i.type===1&&(i.lower===`not`||i.lower===`only`)){let e=t.i,a=i.lower;t.i++;let o=t.peek();if(o!==null&&o.type===1&&o.lower!==`and`&&o.lower!==`or`&&o.lower!==`not`&&o.lower!==`only`){t.i++;let e=null;return t.ident(`and`)&&(e=t.condition(!1),e===null)||!t.atEnd()?r:new MediaQuery(n,a===`not`,o.lower,e,!1)}t.i=e}let a=t.condition(!0);return a===null||!t.atEnd()?r:new MediaQuery(n,!1,`all`,a,!1)}const bu=/* @__PURE__ */ new Map;function parseMediaQueryList(e){let t=bu.get(e);if(t!==void 0)return t;let n=tokenize(e),r=[],i=0,a=0,o=!1;for(let e=0;e<=n.length;e++){let t=e<n.length?n[e]:null;if(t!==null&&(t.type===21||t.type===2||t.type===19?a++:(t.type===22||t.type===20)&&a--,t.type!==13&&(o=!0)),t===null||t.type===18&&a===0){let a=n.slice(i,e);(t!==null||o)&&r.push(parseQuery(a)),i=e+1}}return r.length===1&&r[0].invalid&&n.every(e=>e.type===13)&&(r.length=0),bu.size>500&&bu.clear(),bu.set(e,r),r}function serializeMediaQueryList(e){let t=``;for(let n=0;n<e.length;n++)t+=(n===0?``:`, `)+e[n].text;return t}function lengthPx(e){if(e.type===10)return e.num===0?0:null;if(e.type!==12)return null;switch(e.unit){case`px`:return e.num;case`em`:case`rem`:return e.num*16;case`in`:return e.num*96;case`cm`:return e.num*96/2.54;case`mm`:return e.num*96/25.4;case`pt`:return e.num*96/72;case`pc`:return e.num*16;case`q`:return e.num*96/101.6;case`vw`:return null}return null}function resolutionDppx(e){if(e.type!==12)return null;switch(e.unit){case`dppx`:case`x`:return e.num;case`dpi`:return e.num/96;case`dpcm`:return e.num*2.54/96}return null}function compare(e,t,n){let r=1e-9;switch(t){case`:`:case`=`:return Math.abs(e-n)<r;case`<`:return e<n-r;case`<=`:return e<=n+r;case`>`:return e>n+r;case`>=`:return e>=n-r}return!1}const xu={orientation:``,"prefers-color-scheme":`light`,"prefers-reduced-motion":`no-preference`,"prefers-reduced-transparency":`no-preference`,"prefers-reduced-data":`no-preference`,"prefers-contrast":`no-preference`,"forced-colors":`none`,"inverted-colors":`none`,hover:`hover`,"any-hover":`hover`,pointer:`fine`,"any-pointer":`fine`,"display-mode":`browser`,scripting:`enabled`,update:`fast`,"overflow-block":`scroll`,"overflow-inline":`scroll`,"color-gamut":`srgb`,"dynamic-range":`standard`,"video-dynamic-range":`standard`};function evalNode(e,t){switch(e.kind){case 6:return 1;case 5:return-1;case 1:{let n=evalNode(e.children[0],t);return n===-1?-1:1-n}case 2:{let n=1;for(let r of e.children){let e=evalNode(r,t);if(e===0)return 0;e===-1&&(n=-1)}return n}case 3:{let n=0;for(let r of e.children){let e=evalNode(r,t);if(e===1)return 1;e===-1&&(n=-1)}return n}case 4:return evalFeature(e,t)}return-1}function evalFeature(e,t){let n=e.name,r=e.op;if(n.startsWith(`-webkit-`)&&(n=n.slice(8)),r===`:`&&(n.startsWith(`min-`)||n.startsWith(`max-`)))r=n.startsWith(`min-`)?`>=`:`<=`,n=n.slice(4);else if(n.startsWith(`min-`)||n.startsWith(`max-`))return-1;let i=t.features?.[n],a=i===void 0?void 0:String(i),o=null,s=`range`;switch(n){case`width`:case`device-width`:o=t.width;break;case`height`:case`device-height`:o=t.height;break;case`aspect-ratio`:case`device-aspect-ratio`:o=t.height===0?0:t.width/t.height,s=`ratio`;break;case`resolution`:case`device-pixel-ratio`:o=t.devicePixelRatio,s=n===`resolution`?`resolution`:`number`;break;case`color`:o=8,s=`integer`;break;case`color-index`:case`monochrome`:case`grid`:o=0,s=`integer`;break;default:s=`discrete`}if(a!==void 0&&s!==`discrete`){let e=Number(a);Number.isNaN(e)||(o=e)}if(s===`discrete`){if(r!==``&&r!==`:`)return-1;let i=a??xu[n];if(n===`orientation`&&(i=a??(t.height>=t.width?`portrait`:`landscape`)),i===void 0)return-1;if(r===``)return+(i!==`none`&&i!==`no-preference`);let o=e.value;return o.length!==1||o[0].type!==1?0:+(o[0].lower===i)}if(o===null)return-1;if(r===``)return o===0?0:1;let check=(e,t)=>{let n=null;return s===`range`?n=e.length===1?lengthPx(e[0]):null:s===`ratio`?e.length===2?n=e[1].num===0?1/0:e[0].num/e[1].num:e.length===1&&e[0].type===10&&(n=e[0].num):s===`resolution`?n=e.length===1?resolutionDppx(e[0]):null:e.length===1&&e[0].type===10&&(n=e[0].num),n===null?-1:+!!compare(o,t,n)},c=check(e.value,r);return e.value2===null||c!==1?c:check(e.value2,e.op2)}function evaluateMediaQuery$1(e,t){if(e.invalid)return!1;let n=t.mediaType??`screen`,r=e.type===`all`||e.type===n;yu.has(e.type)||(r=!1);let i=r;return i&&e.condition!==null&&(i=evalNode(e.condition,t)===1),e.negated?!i:i}__name(evaluateMediaQuery$1,`evaluateMediaQuery`);function evaluateMediaQueryList$1(e,t){if(e.length===0)return!0;for(let n=0;n<e.length;n++)if(evaluateMediaQuery$1(e[n],t))return!0;return!1}__name(evaluateMediaQueryList$1,`evaluateMediaQueryList`);function matchMediaText(e,t){return evaluateMediaQueryList$1(parseMediaQueryList(e),t)}function splitSelectorList(e){let t=[],n=new CSSTokenizer(e),r=0,i=0;for(;;){let a=n.next();if(a===0)break;a===2||a===21||a===19?r++:a===22||a===20?r--:a===18&&r===0&&(t.push(e.slice(i,n.start).trim()),i=n.end)}return t.push(e.slice(i).trim()),t}function containsNesting(e){if(e.indexOf(`&`)===-1)return!1;let t=new CSSTokenizer(e);for(;;){let e=t.next();if(e===0)return!1;if(e===9&&t.value===`&`)return!0}}function resolveNested(e,t){let n=[],r=t.length===1&&isGluableCompound(t[0])?t[0]:`:is(`+t.join(`, `)+`)`;for(let t of splitSelectorList(e)){if(t===``)continue;let e=t;containsNesting(e)||(e=`& `+e),n.push(replaceNesting(e,r))}return n}function isGluableCompound(e){let t=e.charCodeAt(0);if(t!==46&&t!==35&&t!==91&&t!==58)return!1;let n=new CSSTokenizer(e),r=0;for(;;){let e=n.next();if(e===0)return!0;if(e===2||e===21||e===19)r++;else if(e===22||e===20)r--;else if(r===0&&(e===13||e===18||e===9&&(n.value===`>`||n.value===`+`||n.value===`~`||n.value===`|`)))return!1}}function replaceNesting(e,t){let n=new CSSTokenizer(e),r=``,i=0;for(;;){let a=n.next();if(a===0)break;a===9&&n.value===`&`&&(r+=e.slice(i,n.start)+t,i=n.end)}return r+e.slice(i)}var RootStyles=class{root;owners;ownerNodes;adopted;adoptedView;list;indexed;ref;index;constructor(e){this.root=e,this.owners=[],this.ownerNodes=[],this.adopted=[],this.adoptedView=null,this.list=null,this.indexed=!1,this.ref=null,this.index=null}discardIndex(){let e=this.index?.attributeNames;e instanceof ShadowAttributeNames&&e.release(),this.index=null}hasSheets(){return this.owners.length!==0||this.adopted.length!==0}},RootRefs=class{refs;pruneAt;constructor(){this.refs=/* @__PURE__ */ new Set,this.pruneAt=64}add(e){let t=this.refs;if(t.add(e.ref??=new WeakRef(e)),!(t.size<this.pruneAt)){for(let e of t)e.deref()===void 0&&t.delete(e);this.pruneAt=Math.max(64,t.size*2)}}delete(e){e.ref!==null&&this.refs.delete(e.ref)}},DocCSS=class{doc;main;shadows;shadowAttributeUses=null;envWidth;envHeight;envDpr;authorVersion;authorStyleVersion;authorResult;constructor(e){this.doc=e,this.main=new RootStyles(e[z]),this.shadows=null,this.envWidth=-1,this.envHeight=-1,this.envDpr=-1,this.authorVersion=-1,this.authorStyleVersion=-1,this.authorResult=!1}adoptShadowRoot(e){let t=Su.get(e);if(t===void 0||!t.hasSheets())return;t.discardIndex(),this.shadows?.delete(t),t.indexed=!1;let n=e.doc;if(this.doc[Xr]!==n&&n[Xr]!==this.doc)Reflect.set(t.adopted,`length`,0)||(t.adopted=[],t.adoptedView=null);else for(let e of t.adopted){if(!(e instanceof Tu)||e[Ht]===n)continue;wu??=/* @__PURE__ */ new WeakMap;let r=wu.get(e);r===void 0&&wu.set(e,r=new RootRefs),r.add(t)}for(let e of t.owners)e[Ht]=n;syncShadowRegistration(t),this.doc[Gr]++,n[Gr]++}};function docCSS(e){let t=e[Et];return t===null&&(e[Et]=t=new DocCSS(e)),t}function existingDocCSS(e){return e[Et]}const Su=/* @__PURE__ */ new WeakMap;function rootStylesFor(e,t){let n=e.doc,r=t?docCSS(n):existingDocCSS(n);if(r===null)return null;if(e.type===9)return r.main;let i=Su.get(e)??null;return t&&i===null&&Su.set(e,i=new RootStyles(e)),i}function syncShadowRegistration(e){if(e.root.type===9)return;let t=e.hasSheets();if(e.indexed===t)return;let n=docCSS(e.root.doc);t?(n.shadows??=new RootRefs).add(e):n.shadows?.delete(e),e.indexed=t}const Cu=/* @__PURE__ */ new WeakMap;let wu;function sheetChanged(e){let t=e[Ht];t!==null&&t[Gr]++;let n=wu?.get(e);if(n!==void 0){for(let r of n.refs){let i=r.deref();i===void 0||i.root.doc===t||!i.adopted.includes(e)?n.refs.delete(r):(i.discardIndex(),i.root.doc[Gr]++)}n.refs.size===0&&wu.delete(e)}}function discardSheetRuleIndexes(e){if(!e[_t]){let t=Cu.get(e);t!==void 0&&t.discardIndex();return}let t=e[Ht],n=t===null?null:existingDocCSS(t);if(n!==null&&(n.main.index!==null&&n.main.adopted.includes(e)&&n.main.discardIndex(),n.shadows!==null))for(let t of n.shadows.refs){let r=t.deref();r===void 0?n.shadows.refs.delete(t):r.index!==null&&r.adopted.includes(e)&&r.discardIndex()}}function treeTop(e){let t=e;for(;t.parent!==null;)t=t.parent;return t}function isStyleRoot(e){return e.type===9||!!(e.flags&32)}function syncList(e){e.list?._set(e.owners.slice())}function registerOwnerSheet(e,t){let n=treeTop(e);if(!isStyleRoot(n))return;let r=rootStylesFor(n,!0),i=r.ownerNodes.length;for(;i>0&&compareTreeOrder(r.ownerNodes[i-1],e)>0;)i--;r.ownerNodes.splice(i,0,e),r.owners.splice(i,0,t),Cu.set(t,r),syncShadowRegistration(r),syncList(r),e.doc[Gr]++}function unregisterOwnerSheet(e,t){let n=existingDocCSS(e.doc),r=Cu.get(t);if(n!==null&&r!==void 0){let e=r.owners.indexOf(t);e!==-1&&(r.discardIndex(),r.owners.splice(e,1),r.ownerNodes.splice(e,1),syncList(r)),Cu.delete(t),syncShadowRegistration(r)}t[tr]=null,e.doc[Gr]++}function createOwnerSheet(e,t,n){let r=Tu._forOwner(e.node,t,n,null);return registerOwnerSheet(e,r),r}function createLinkSheet(e,t,n){let r=Tu._forOwner(e.node,``,n,t);return registerOwnerSheet(e,r),r}function removeOwnerSheet(e,t){t instanceof Tu&&unregisterOwnerSheet(e,t)}function styleSheetsOf(e){let t=rootStylesFor(e,!0);return t.list===null&&(t.list=new StyleSheetList,syncList(t)),t.list}var AdoptedSheetChanges=class extends WeakRef{defineProperty(e,t,n){let r=this.deref();if(r===void 0||r.adopted!==e)return Reflect.defineProperty(e,t,n);let i=e.length;if(isSheetIndex(t)){if(`get`in n||`set`in n)return!1;if(!(`value`in n)&&Object.hasOwn(e,t))return Reflect.defineProperty(e,t,n);let a=validateAdoptedSheet(n.value,r.root.doc);return Reflect.defineProperty(e,t,n)?(a[Ht]===null&&(a[Ht]=r.root.doc),adoptedSheetsChanged(r,Number(t)<i),!0):!1}let a=Reflect.defineProperty(e,t,n);return t===`length`&&e.length!==i&&adoptedSheetsChanged(r,e.length<i),a}deleteProperty(e,t){let n=Reflect.deleteProperty(e,t);if(n&&isSheetIndex(t)){let t=this.deref();t!==void 0&&t.adopted===e&&adoptedSheetsChanged(t,!0)}return n}};function adoptedSheetsChanged(e,t){t&&e.discardIndex(),syncShadowRegistration(e),e.root.doc[Gr]++}function isSheetIndex(e){if(typeof e!=`string`)return!1;let t=Number(e)>>>0;return t!==4294967295&&String(t)===e}function adoptedStyleSheetsOf(e){let t=rootStylesFor(e,!0);return t.adoptedView??=new Proxy(t.adopted,new AdoptedSheetChanges(t))}function setAdoptedStyleSheets(e,t){if(typeof t!=`object`||!t||typeof t.length!=`number`)throw TypeError(`Failed to set the 'adoptedStyleSheets' property: The provided value cannot be converted to a sequence.`);let n=Array.from(t);for(let t of n)validateAdoptedSheet(t,e.doc);let r=rootStylesFor(e,!0);r.index!==null&&r.adopted.length!==0&&r.discardIndex(),r.adopted=n,r.adoptedView=null;for(let t of r.adopted)t[Ht]===null&&(t[Ht]=e.doc);e.doc[Gr]++,syncShadowRegistration(r)}function validateAdoptedSheet(e,t){if(!(e instanceof Tu))throw TypeError(`Failed to set the 'adoptedStyleSheets' property: Failed to convert value to 'CSSStyleSheet'.`);if(!e[_t])throw new DOMException(`Failed to set the 'adoptedStyleSheets' property: Can't adopt non-constructed stylesheets.`,`NotAllowedError`);if(e[Ht]!==null&&e[Ht]!==t)throw new DOMException(`Failed to set the 'adoptedStyleSheets' property: Sharing constructed stylesheets in multiple documents is not allowed`,`NotAllowedError`);return e}function supportsDeclaration(e,t){let n=isCustomPropertyName(e)?e:e.toLowerCase();return isCustomPropertyName(n)?t.trim()!==``||!0:new DeclBlock().setValue(n,t,!1,!1)}var Cursor=class{src;t;type;constructor(e){this.src=e,this.t=new CSSTokenizer(e),this.type=0,this.next()}next(){do this.type=this.t.next();while(this.type===13)}block(){let e=this.t.end,t=1,n=e;for(;t>0;){let e=this.t.next();if(e===0)return null;e===21||e===2||e===19?t++:(e===22||e===20)&&(t--,n=this.t.start)}return this.next(),this.src.slice(e,n)}};function condition(e){if(e.type===1&&e.t.value.toLowerCase()===`not`){e.next();let t=inParens(e);return t===-1?-1:1-t}let t=inParens(e);if(t===-1)return-1;if(e.type!==1)return t;let n=e.t.value.toLowerCase();if(n!==`and`&&n!==`or`)return-1;for(;e.type===1&&e.t.value.toLowerCase()===n;){e.next();let r=inParens(e);if(r===-1)return-1;t=n===`and`?t&r:t|r}return e.type===1?-1:t}function inParens(e){if(e.type===2){let t=e.t.value.toLowerCase(),n=e.block();return n===null?-1:t===`selector`?+!!isSupportedSelector(n.trim()):0}if(e.type!==21)return-1;let t=e.block();if(t===null)return-1;let n=new Cursor(t);if(n.type===21||n.type===2||n.type===1&&n.t.value.toLowerCase()===`not`){let e=condition(n);if(e!==-1&&n.type===0)return e}return declaration(t)}function declaration(e){let t=new CSSTokenizer(e),n=t.next();for(;n===13;)n=t.next();if(n!==1)return 0;let r=t.value;for(n=t.next();n===13;)n=t.next();if(n!==16)return 0;let i=e.slice(t.end).trim(),a=/!\s*important\s*$/i.exec(i);return a!==null&&(i=i.slice(0,a.index).trim()),+!!supportsDeclaration(r,i)}function evaluateSupportsCondition(e){let t=new Cursor(e),n=condition(t);return n!==-1&&t.type===0?n===1:declaration(e)===1}var CSSRuleList=class{[U];[On];constructor(e){this[U]=e,this[On]=0,this._sync()}_setRules(e){this[U]=e,this._sync()}_sync(e=0){let t=this,n=this[U];for(let r=e;r<n.length;r++)t[r]=n[r];for(let e=n.length;e<this[On];e++)delete t[e];this[On]=n.length}get length(){return this[U].length}item(e){return this[U][e>>>0]??null}*[Symbol.iterator](){yield*this[U]}get[Symbol.toStringTag](){return`CSSRuleList`}},MediaList=class{[dr];[er];[On];constructor(e,t){this[dr]=e===``?[]:parseMediaQueryList(e),this[er]=t,this[On]=0,this._sync()}_sync(){let e=this,t=this[dr];for(let n=0;n<t.length;n++)e[n]=t[n].text;for(let n=t.length;n<this[On];n++)delete e[n];this[On]=t.length}get mediaText(){return serializeMediaQueryList(this[dr])}set mediaText(e){let t=e===null?``:String(e);this[dr]=t===``?[]:parseMediaQueryList(t).slice(),this._sync(),this[er]?._changed()}get length(){return this[dr].length}item(e){return this[dr][e>>>0]?.text??null}appendMedium(e){let t=parseMediaQueryList(String(e));if(t.length===1){for(let e of this[dr])if(e.text===t[0].text)return;this[dr]=[...this[dr],t[0]],this._sync(),this[er]?._changed()}}deleteMedium(e){if(arguments.length===0)throw TypeError(`Failed to execute 'deleteMedium' on 'MediaList': 1 argument required, but only 0 present.`);let t=parseMediaQueryList(String(e));if(t.length!==1)return;let n=this[dr].length;if(this[dr]=this[dr].filter(e=>e.text!==t[0].text),this[dr].length===n)throw new DOMException(`Failed to execute 'deleteMedium' on 'MediaList': Failed to delete the medium.`,`NotFoundError`);this._sync(),this[er]?._changed()}toString(){return this.mediaText}*[Symbol.iterator](){for(let e of this[dr])yield e.text}get[Symbol.toStringTag](){return`MediaList`}},StyleSheetList=class{[Vr];[On];constructor(){this[Vr]=[],this[On]=0}_set(e){this[Vr]=e;let t=this;for(let n=0;n<e.length;n++)t[n]=e[n];for(let n=e.length;n<this[On];n++)delete t[n];this[On]=e.length}get length(){return this[Vr].length}item(e){return this[Vr][e>>>0]??null}*[Symbol.iterator](){yield*this[Vr]}get[Symbol.toStringTag](){return`StyleSheetList`}},StyleSheet=class{[tr];[Gn];[zt];[Qr];[xn];constructor(e,t,n,r){this[tr]=e,this[Gn]=new MediaList(t,this),this[zt]=!1,this[Qr]=n,this[xn]=r}_changed(){}get type(){return`text/css`}get href(){return this[xn]}get ownerNode(){return this[tr]}get parentStyleSheet(){return null}get title(){let e=this[tr],t=e===null?this[Qr]:e.getAttribute(`title`);return t===``?null:t}get media(){return this[Gn]}set media(e){this[Gn].mediaText=String(e)}get disabled(){return this[zt]}set disabled(e){let t=!!e;t!==this[zt]&&(this[zt]=t,this._changed())}};function syntaxError(e,t,n){return new DOMException(`Failed to execute '${e}' on '${t}': Failed to parse the rule '${n}'.`,`SyntaxError`)}var Tu=class CSSStyleSheet extends StyleSheet{[U];[Rn];[Ht];[_t];[Bt];[nr];[Xn];[Pt];[J];[gr];constructor(e){let t=e?.media;super(null,t===void 0?``:typeof t==`string`?t:t.mediaText,null,null),this[U]=[],this[Rn]=null,this[Ht]=null,this[_t]=!0,this[Bt]=!1,this[nr]=null,this[Xn]=null,this[Pt]=void 0,this[J]=0,this[gr]=0,e?.disabled&&(this[zt]=!0),this[Ht]=currentWindowOrNull()?.document??null,e?.baseURL!==void 0&&(this[xn]=null)}static _forOwner(e,t,n,r){let i=new CSSStyleSheet;return i[_t]=!1,i[tr]=e,i[Ht]=e[z].doc,i[xn]=r,i[Qr]=e.getAttribute(`title`),n!==``&&(i[Gn].mediaText=n),i._setText(t),i}_changed(){this[J]++,this[gr]=this[J],sheetChanged(this)}_inserted(e,t){if(t!==this[U].length-1||!appendableRule(e))return this._changed();this[J]++,sheetChanged(this)}_setText(e){this[U].length!==0&&discardSheetRuleIndexes(this);for(let e of this[U])e[Br]=null;this[U]=[],this[Xn]=null,this[Pt]=void 0;let t=e===``?[]:parseStylesheet(e),n=!1;for(let e of t){let t=e.kind===2?e.name.toLowerCase():``;if(t===`import`&&this[_t]||(t===`import`||t===`namespace`)&&(n&&t===`import`||n&&this[U].some(e=>!(e instanceof CSSImportRule)&&!(e instanceof CSSNamespaceRule)&&!(e instanceof CSSLayerStatementRule))))continue;let r=createRule(e,null,this,!1,!1);r!==null&&(r instanceof CSSImportRule||r instanceof CSSLayerStatementRule||r instanceof CSSNamespaceRule||(n=!0),r[Br]=this,this[U].push(r),r instanceof CSSNamespaceRule&&this._registerNamespace(r))}this[Rn]?._setRules(this[U]),this._changed()}_registerNamespace(e){e[sr]===``?this[Pt]=e[ai]===``?null:e[ai]:(this[Xn]??=/* @__PURE__ */ new Map).set(e[sr],e[ai]===``?null:e[ai])}get parentStyleSheet(){return this[nr]===null?null:this[nr].parentStyleSheet}get ownerRule(){return this[nr]}get cssRules(){return this[Rn]??=new CSSRuleList(this[U])}get rules(){return this.cssRules}insertRule(e,t=0){if(arguments.length===0)throw TypeError(`Failed to execute 'insertRule' on 'CSSStyleSheet': 1 argument required, but only 0 present.`);if(this[Bt])throw new DOMException(`Failed to execute 'insertRule' on 'CSSStyleSheet': Cannot modify a sheet while it is being replaced.`,`NotAllowedError`);let n=String(e),r=t>>>0;if(r>this[U].length)throw new DOMException(`Failed to execute 'insertRule' on 'CSSStyleSheet': The index provided (${r}) is larger than the maximum index (${this[U].length}).`,`IndexSizeError`);let i=parseRule(n);if(i===null||(i.kind===2?i.name.toLowerCase():``)===`import`&&this[_t])throw syntaxError(`insertRule`,`CSSStyleSheet`,n);let a=createRule(i,null,this,!1,!1);if(a===null)throw syntaxError(`insertRule`,`CSSStyleSheet`,n);if(a instanceof CSSImportRule)for(let e=0;e<r;e++){let t=this[U][e];if(!(t instanceof CSSImportRule)&&!(t instanceof CSSLayerStatementRule))throw new DOMException(`Failed to execute 'insertRule' on 'CSSStyleSheet': @import rules must precede all rules except @charset and @layer statements.`,`HierarchyRequestError`)}else if(!(a instanceof CSSNamespaceRule)&&!(a instanceof CSSLayerStatementRule)){for(let e=r;e<this[U].length;e++)if(this[U][e]instanceof CSSImportRule||this[U][e]instanceof CSSNamespaceRule)throw new DOMException(`Failed to execute 'insertRule' on 'CSSStyleSheet': Rules cannot be inserted before @import or @namespace rules.`,`HierarchyRequestError`)}else if(a instanceof CSSNamespaceRule){for(let e of this[U])if(!(e instanceof CSSImportRule)&&!(e instanceof CSSNamespaceRule)&&!(e instanceof CSSLayerStatementRule))throw new DOMException(`Failed to execute 'insertRule' on 'CSSStyleSheet': Failed to insert a @namespace rule after other rules.`,`InvalidStateError`);this._registerNamespace(a)}return a[Br]=this,this[U].splice(r,0,a),this[Rn]?._sync(r),this._inserted(a,r),r}deleteRule(e){if(arguments.length===0)throw TypeError(`Failed to execute 'deleteRule' on 'CSSStyleSheet': 1 argument required, but only 0 present.`);if(this[Bt])throw new DOMException(`Failed to execute 'deleteRule' on 'CSSStyleSheet': Cannot modify a sheet while it is being replaced.`,`NotAllowedError`);let t=e>>>0;if(t>=this[U].length)throw new DOMException(`Failed to execute 'deleteRule' on 'CSSStyleSheet': The index provided (${t}) is larger than the maximum index (${Math.max(0,this[U].length-1)}).`,`IndexSizeError`);let[n]=this[U].splice(t,1);discardSheetRuleIndexes(this),n[Br]=null,this[Rn]?._sync(t),this._changed()}addRule(e=`undefined`,t=`undefined`,n){let r=String(e)+` { `+String(t)+` }`;return String(t)===``&&(r=String(e)+` { }`),this.insertRule(r,n===void 0?this[U].length:n),-1}removeRule(e=0){this.deleteRule(e)}replace(e){if(!this[_t]||this[Bt])return Promise.reject(new DOMException(`Failed to execute 'replace' on 'CSSStyleSheet': Can't call replace on non-constructed CSSStyleSheets.`,`NotAllowedError`));this[Bt]=!0;let t=String(e);return Promise.resolve().then(()=>(this._setText(t),this[Bt]=!1,this))}replaceSync(e){if(!this[_t]||this[Bt])throw new DOMException(`Failed to execute 'replaceSync' on 'CSSStyleSheet': Can't call replaceSync on non-constructed CSSStyleSheets.`,`NotAllowedError`);this._setText(String(e))}get[Symbol.toStringTag](){return`CSSStyleSheet`}},Eu=class CSSRule{[Br];[H];static STYLE_RULE=1;static CHARSET_RULE=2;static IMPORT_RULE=3;static MEDIA_RULE=4;static FONT_FACE_RULE=5;static PAGE_RULE=6;static KEYFRAMES_RULE=7;static KEYFRAME_RULE=8;static MARGIN_RULE=9;static NAMESPACE_RULE=10;static COUNTER_STYLE_RULE=11;static SUPPORTS_RULE=12;static DOCUMENT_RULE=13;static FONT_FEATURE_VALUES_RULE=14;static VIEWPORT_RULE=15;static REGION_STYLE_RULE=16;constructor(){if(new.target===CSSRule)throw TypeError(`Illegal constructor`);this[Br]=null,this[H]=null}get type(){return 0}get cssText(){return``}set cssText(e){}get parentRule(){return this[H]}get parentStyleSheet(){let e=this;for(;e[H]!==null;)e=e[H];return e[Br]}_changed(){this.parentStyleSheet?._changed()}_declarationsChanged(){this._changed()}};for(let[e,t]of Object.entries({STYLE_RULE:1,CHARSET_RULE:2,IMPORT_RULE:3,MEDIA_RULE:4,FONT_FACE_RULE:5,PAGE_RULE:6,KEYFRAMES_RULE:7,KEYFRAME_RULE:8,MARGIN_RULE:9,NAMESPACE_RULE:10,COUNTER_STYLE_RULE:11,SUPPORTS_RULE:12,DOCUMENT_RULE:13,FONT_FEATURE_VALUES_RULE:14,VIEWPORT_RULE:15,REGION_STYLE_RULE:16}))Object.defineProperty(Eu.prototype,e,{value:t,enumerable:!0});function indent(e){return` `+e.replace(/\n/g,`
11
- `)}function blockText(e,t){if(t.length===0)return e+` {
12
- }`;let n=e+` {`;for(let e of t)n+=`
13
- `+indent(e.cssText);return n+`
14
- }`}var CSSGroupingRule=class extends Eu{[U];[Rn];constructor(){super(),this[U]=[],this[Rn]=null}get cssRules(){return this[Rn]??=new CSSRuleList(this[U])}_nestedContext(){for(let e=this;e!==null;e=e[H])if(e instanceof Du)return!0;return!1}insertRule(e,t=0){if(arguments.length===0)throw TypeError(`Failed to execute 'insertRule' on '${this.constructor.name}': 1 argument required, but only 0 present.`);let n=String(e),r=t>>>0;if(r>this[U].length)throw new DOMException(`Failed to execute 'insertRule' on '${this.constructor.name}': The index provided (${r}) is larger than the maximum index (${this[U].length}).`,`IndexSizeError`);let i=parseRule(n);if(i===null)throw syntaxError(`insertRule`,this.constructor.name,n);let a=this._nestedContext(),o=createRule(i,this,this.parentStyleSheet,a,!1);if(o===null||o instanceof CSSImportRule||o instanceof CSSNamespaceRule)throw o instanceof CSSImportRule||o instanceof CSSNamespaceRule?new DOMException(`Failed to execute 'insertRule' on '${this.constructor.name}': '${n}' is not allowed here.`,`HierarchyRequestError`):syntaxError(`insertRule`,this.constructor.name,n);return this[U].splice(r,0,o),this[Rn]?._sync(r),this._changed(),r}deleteRule(e){if(arguments.length===0)throw TypeError(`Failed to execute 'deleteRule' on '${this.constructor.name}': 1 argument required, but only 0 present.`);let t=e>>>0;if(t>=this[U].length)throw new DOMException(`Failed to execute 'deleteRule' on '${this.constructor.name}': The index provided (${t}) is larger than the maximum index (${Math.max(0,this[U].length-1)}).`,`IndexSizeError`);let[n]=this[U].splice(t,1),r=this.parentStyleSheet;r!==null&&discardSheetRuleIndexes(r),n[H]=null,this[Rn]?._sync(t),this._changed()}},Du=class CSSStyleRule extends CSSGroupingRule{[jr];[tt];[nt];[Wr];[mt];[ht];constructor(e,t,n=null){super(),this[jr]=e,this[tt]=t,this[nt]=n,this[Wr]=null,this[mt]=null,this[ht]=``}get type(){return 1}get[M](){let e=this[tt];return e===null&&(this[tt]=e=new DeclBlock,e.addRaw(parseDeclarationList(this[nt])),this[nt]=null),e}_mayDeclare(){let e=this[tt];return e===null?/\S/.test(this[nt]):e.names.length!==0}get selectorText(){return containsNesting(this[jr])?this[jr]:serializeSelector(this[jr],namespaceOptions(this.parentStyleSheet))??this[jr]}set selectorText(e){let t=String(e).trim();isValidSelectorFor(t,this._nestedContextForSelf(),this.parentStyleSheet)&&(this[jr]=t,this[mt]=null,this._changed())}_nestedContextForSelf(){for(let e=this[H];e!==null;e=e[H])if(e instanceof CSSStyleRule)return!0;return!1}get style(){return this[Wr]??=new CSSStyleDeclaration(null,this[M],this)}set style(e){this.style.cssText=String(e)}get cssText(){let e=this[M].serialize();if(this[U].length===0)return e===``?`${this.selectorText} { }`:`${this.selectorText} { ${e} }`;let t=`${this.selectorText} {`;e!==``&&(t+=`
15
- `+e);for(let e of this[U])t+=`
16
- `+indent(e.cssText);return t+`
17
- }`}_resolvedSelectors(){let e=this[H];for(;e!==null&&!(e instanceof CSSStyleRule);)e=e[H];return e===null?containsNesting(this[jr])?resolveNested(this[jr],[`:scope`]):[this[jr]]:resolveNested(this[jr],e._resolvedSelectors())}_compile(){let e=this._resolvedSelectors().join(`, `);return this[mt]!==null&&this[ht]===e||(this[mt]=compileSelectorList(e,namespaceOptions(this.parentStyleSheet)),this[ht]=e),this[mt]}get[Symbol.toStringTag](){return`CSSStyleRule`}},CSSNestedDeclarations=class extends Eu{[M];[Wr];constructor(e){super(),this[M]=e,this[Wr]=null}get type(){return 0}get style(){return this[Wr]??=new CSSStyleDeclaration(null,this[M],this)}get cssText(){return this[M].serialize()}},CSSConditionRule=class extends CSSGroupingRule{get conditionText(){return``}},CSSMediaRule=class extends CSSConditionRule{[Gn];constructor(e){super(),this[Gn]=new MediaList(e,this)}get type(){return 4}get media(){return this[Gn]}set media(e){this[Gn].mediaText=String(e)}get conditionText(){return this[Gn].mediaText}get cssText(){return blockText(`@media `+this[Gn].mediaText,this[U])}},CSSSupportsRule=class extends CSSConditionRule{[gt];[Wn];constructor(e){super(),this[gt]=e,this[Wn]=evaluateSupportsCondition(e)}get type(){return 12}get conditionText(){return this[gt]}get cssText(){return blockText(`@supports `+this[gt],this[U])}},CSSContainerRule=class extends CSSConditionRule{[gt];constructor(e){super(),this[gt]=e}get conditionText(){return this[gt]}get containerName(){let e=/^([^\s(]+)\s/.exec(this[gt]);return e!==null&&e[1].toLowerCase()!==`not`?e[1]:``}get containerQuery(){let e=this.containerName;return e===``?this[gt]:this[gt].slice(e.length).trim()}get cssText(){return blockText(`@container `+this[gt],this[U])}},CSSLayerBlockRule=class extends CSSGroupingRule{[Jn];constructor(e){super(),this[Jn]=e}get name(){return this[Jn]}get cssText(){return blockText(this[Jn]===``?`@layer`:`@layer `+this[Jn],this[U])}},CSSLayerStatementRule=class extends Eu{[Yn];constructor(e){super(),this[Yn]=e}get nameList(){return Object.freeze(this[Yn].slice())}get cssText(){return`@layer `+this[Yn].join(`, `)+`;`}},CSSScopeRule=class extends CSSGroupingRule{[cr];constructor(e){super(),this[cr]=e}get start(){let e=this[cr];return e.charCodeAt(0)===40?parenContents(e,0):null}get end(){let e=this[cr],t=0;if(e.charCodeAt(0)===40){if(t=matchingParen(e,0),t===-1)return null;t++}let n=/^\s*to\s*\(/i.exec(e.slice(t));return n===null?null:parenContents(e,t+n[0].length-1)}get cssText(){return blockText(this[cr]===``?`@scope`:`@scope `+this[cr],this[U])}};function matchingParen(e,t){let n=0;for(let r=t;r<e.length;r++){let t=e.charCodeAt(r);if(t===92)r++;else if(t===34||t===39)for(r++;r<e.length&&e.charCodeAt(r)!==t;r++)e.charCodeAt(r)===92&&r++;else if(t===40)n++;else if(t===41&&--n===0)return r}return-1}function parenContents(e,t){let n=matchingParen(e,t);return n===-1?null:e.slice(t+1,n).trim()}var CSSStartingStyleRule=class extends CSSGroupingRule{get cssText(){return blockText(`@starting-style`,this[U])}},CSSImportRule=class extends Eu{[xn];[Gn];[Ln];[Kr];constructor(e,t,n,r){super(),this[xn]=e,this[Gn]=new MediaList(t,this),this[Ln]=n,this[Kr]=r}get type(){return 3}get href(){return this[xn]}get media(){return this[Gn]}get styleSheet(){return null}get layerName(){return this[Ln]}get supportsText(){return this[Kr]}get cssText(){let e=`@import `+serializeUrl(this[xn]);this[Ln]!==null&&(e+=this[Ln]===``?` layer`:` layer(${this[Ln]})`),this[Kr]!==null&&(e+=` supports(${this[Kr]})`);let t=this[Gn].mediaText;return t!==``&&(e+=` `+t),e+`;`}},CSSNamespaceRule=class extends Eu{[sr];[ai];constructor(e,t){super(),this[sr]=e,this[ai]=t}get type(){return 10}get namespaceURI(){return this[ai]}get prefix(){return this[sr]}get cssText(){return`@namespace `+(this[sr]===``?``:this[sr]+` `)+serializeUrl(this[ai])+`;`}},DescriptorRule=class extends Eu{[M];[Wr];constructor(e){super(),this[M]=e,this[Wr]=null}get style(){return this[Wr]??=new CSSStyleDeclaration(null,this[M],this)}},CSSFontFaceRule=class extends DescriptorRule{get type(){return 5}get cssText(){let e=this[M].serialize();return e===``?`@font-face { }`:`@font-face { ${e} }`}},CSSPageRule=class extends DescriptorRule{[jr];constructor(e,t){super(t),this[jr]=e}get type(){return 6}get selectorText(){return this[jr]}set selectorText(e){this[jr]=String(e).trim()}get cssText(){let e=this[M].serialize(),t=this[jr]===``?`@page`:`@page `+this[jr];return e===``?`${t} { }`:`${t} { ${e} }`}},CSSPropertyRule=class extends Eu{[Jn];[M];constructor(e,t){super(),this[Jn]=e,this[M]=t}get name(){return this[Jn]}get syntax(){return unquote(this[M].getPropertyValue(`syntax`))}get inherits(){return this[M].getPropertyValue(`inherits`).toLowerCase()===`true`}get initialValue(){let e=this[M].indexOf(`initial-value`);return e===-1?null:this[M].values[e]}get cssText(){let e=this[M].serialize();return e===``?`@property ${this[Jn]} { }`:`@property ${this[Jn]} { ${e} }`}};function unquote(e){return e.length>=2&&(e[0]===`"`||e[0]===`'`)?e.slice(1,-1):e}var CSSKeyframeRule=class extends DescriptorRule{[Pn];constructor(e,t){super(t),this[Pn]=e}get type(){return 8}get keyText(){return this[Pn]}set keyText(e){let t=normalizeKeyText(String(e));if(t===null)throw new DOMException(`Failed to set the 'keyText' property on 'CSSKeyframeRule': The key '${e}' is invalid and cannot be parsed`,`SyntaxError`);this[Pn]=t,this._changed()}get cssText(){let e=this[M].serialize();return e===``?`${this[Pn]} { }`:`${this[Pn]} { ${e} }`}},CSSKeyframesRule=class extends Eu{[Jn];[U];[Rn];constructor(e){super(),this[Jn]=e,this[U]=[],this[Rn]=null}get type(){return 7}get name(){return this[Jn]}set name(e){this[Jn]=String(e),this._changed()}get cssRules(){return this[Rn]??=new CSSRuleList(this[U])}get length(){return this[U].length}appendRule(e){let t=parseRule(String(e));if(t===null||t.kind!==1)return;let n=createKeyframe(t);n!==null&&(n[H]=this,this[U].push(n),this[Rn]?._sync(this[U].length-1),this._changed())}deleteRule(e){let t=this._findIndex(String(e));if(t===-1)return;let[n]=this[U].splice(t,1),r=this.parentStyleSheet;r!==null&&discardSheetRuleIndexes(r),n[H]=null,this[Rn]?._sync(t),this._changed()}findRule(e){let t=this._findIndex(String(e));return t===-1?null:this[U][t]}_findIndex(e){let t=normalizeKeyText(e);if(t===null)return-1;for(let e=this[U].length-1;e>=0;e--)if(this[U][e][Pn]===t)return e;return-1}get cssText(){return blockText(`@keyframes `+this[Jn],this[U])}};function namespaceOptions(e){return e!==null&&(e[Xn]!==null||e[Pt]!==void 0)?{namespaces:e[Xn]??void 0,defaultNamespace:e[Pt]}:void 0}function isValidSelectorFor(e,t,n){if(e===``)return!1;let r=namespaceOptions(n);return t?compileSelectorList(resolveNested(e,[`*`]).join(`, `),r)!==null:containsNesting(e)?compileSelectorList(resolveNested(e,[`:scope`]).join(`, `),r)!==null:compileSelectorList(e,r)!==null}function normalizeKeyText(e){let t=e.split(`,`),n=[];for(let e of t){let t=e.trim().toLowerCase();if(t===`from`)n.push(`0%`);else if(t===`to`)n.push(`100%`);else{let e=/^([+]?\d*\.?\d+(?:e[+-]?\d+)?)%$/.exec(t);if(e===null)return null;let r=Number(e[1]);if(r<0||r>100)return null;n.push(String(r)+`%`)}}return n.join(`, `)}function createKeyframe(e){let t=normalizeKeyText(e.prelude);if(t===null)return null;let n=new DeclBlock;return n.addRaw(rawDecls(e)),new CSSKeyframeRule(t,n)}function leadingDecls(e){let t=rawDecls(e);return e.leading===t.length?t:t.slice(0,e.leading)}function nestedDeclarations(e,t){let n=new DeclBlock;n.addRaw(t);let r=new CSSNestedDeclarations(n);return r[H]=e,r}function fillChildren(e,t,n,r){let i=r||e instanceof Du;r&&t.leading!==0&&!(e instanceof Du)&&e[U].push(nestedDeclarations(e,leadingDecls(t)));for(let r of t.rules){if(r.kind===3){i&&e[U].push(nestedDeclarations(e,rawDecls(r)));continue}let t=createRule(r,e,n,i,!1);t===null||t instanceof CSSImportRule||t instanceof CSSNamespaceRule||e[U].push(t)}}function parseImportPrelude(e){let t=splitComponents(e);if(t===null)return null;let n=0;for(;n<t.length&&t[n].type===100;)n++;let r=t[n];if(r===void 0)return null;let i;if(r.type===5||r.type===7)i=r.value;else if(r.type===2&&r.lower===`url`){let e=splitComponents(r.text.slice(4,-1).trim());if(e===null||e.length!==1||e[0].type!==5)return null;i=e[0].value}else return null;n++;let a=null,o=null,s=t.slice(n),c=0,skipWs=()=>{for(;c<s.length&&s[c].type===100;)c++};skipWs(),c<s.length&&s[c].type===1&&s[c].lower===`layer`?(a=``,c++):c<s.length&&s[c].type===2&&s[c].lower===`layer`&&(a=s[c].text.slice(6,-1).trim(),c++),skipWs(),c<s.length&&s[c].type===2&&s[c].lower===`supports`&&(o=s[c].text.slice(9,-1).trim(),c++);let l=``;for(;c<s.length;c++)l+=s[c].text;return{href:i,layer:a,supports:o,media:l.trim()}}function appendableRule(e){if(e instanceof CSSLayerBlockRule||e instanceof CSSLayerStatementRule||e instanceof CSSImportRule||e instanceof CSSNamespaceRule)return!1;if(e instanceof Du||e instanceof CSSMediaRule||e instanceof CSSSupportsRule){let t=e[U];for(let e=0;e<t.length;e++)if(!appendableRule(t[e]))return!1}return!0}function createRule(e,t,n,r,i){let a=null;if(e.kind===1){if(i)return createKeyframe(e);if(!e.hasBlock||!isValidSelectorFor(e.prelude,r,n))return null;let a;if(e.lazy!==null)a=new Du(e.prelude,null,e.lazy);else{let t=new DeclBlock;t.addRaw(leadingDecls(e)),a=new Du(e.prelude,t)}return a[H]=t,fillChildren(a,e,n,!0),a}let o=e.name.toLowerCase(),s=e.prelude;switch(o){case`media`:{if(!e.hasBlock)return null;let i=new CSSMediaRule(s);i[H]=t,fillChildren(i,e,n,r),a=i;break}case`supports`:{if(!e.hasBlock||s===``)return null;let i=new CSSSupportsRule(s);i[H]=t,fillChildren(i,e,n,r),a=i;break}case`container`:{if(!e.hasBlock)return null;let i=new CSSContainerRule(s);i[H]=t,fillChildren(i,e,n,r),a=i;break}case`layer`:{let i=s===``?[]:s.split(`,`).map(e=>e.trim());for(let e of i)if(!/^-?[_a-zA-Z\u0080-￿][-_a-zA-Z0-9\u0080-￿]*(\.-?[_a-zA-Z\u0080-￿][-_a-zA-Z0-9\u0080-￿]*)*$/.test(e))return null;if(e.hasBlock){if(i.length>1)return null;let o=new CSSLayerBlockRule(i[0]??``);o[H]=t,fillChildren(o,e,n,r),a=o}else{if(i.length===0)return null;a=new CSSLayerStatementRule(i)}break}case`scope`:{if(!e.hasBlock)return null;let r=new CSSScopeRule(s);r[H]=t,fillChildren(r,e,n,!0),a=r;break}case`starting-style`:{if(!e.hasBlock)return null;let i=new CSSStartingStyleRule;i[H]=t,fillChildren(i,e,n,r),a=i;break}case`keyframes`:case`-webkit-keyframes`:case`-moz-keyframes`:{if(!e.hasBlock||r)return null;let t=splitComponents(s);if(t===null||t.length!==1||t[0].type!==1&&t[0].type!==5)return null;let n=new CSSKeyframesRule(t[0].type===5?serializeString$1(t[0].value):t[0].text);for(let t of e.rules){if(t.kind!==1)continue;let e=createKeyframe(t);e!==null&&(e[H]=n,n[U].push(e))}a=n;break}case`font-face`:{if(!e.hasBlock||s!==``)return null;let t=new DeclBlock;for(let n of rawDecls(e))t.putParsed(n.name.toLowerCase(),n.value,n.important);a=new CSSFontFaceRule(t);break}case`page`:{if(!e.hasBlock)return null;let t=new DeclBlock;t.addRaw(rawDecls(e)),a=new CSSPageRule(s,t);break}case`property`:{if(!e.hasBlock||!s.startsWith(`--`))return null;let t=new DeclBlock;for(let n of rawDecls(e))t.putParsed(n.name.toLowerCase(),n.value,!1);a=new CSSPropertyRule(s,t);break}case`import`:{if(e.hasBlock||r)return null;let t=parseImportPrelude(s);if(t===null)return null;a=new CSSImportRule(t.href,t.media,t.layer,t.supports);break}case`namespace`:{if(e.hasBlock||r)return null;let t=splitComponents(s);if(t===null)return null;let n=t.filter(e=>e.type!==100),i=``,o=0;if(n.length===2&&n[0].type===1)i=n[0].text,o=1;else if(n.length!==1)return null;let c=n[o],l;if(c.type===5||c.type===7)l=c.value;else if(c.type===2&&c.lower===`url`){let e=splitComponents(c.text.slice(4,-1).trim());if(e===null||e.length!==1||e[0].type!==5)return null;l=e[0].value}else return null;a=new CSSNamespaceRule(i,l);break}default:return null}return a!==null&&(a[H]=t),a}{let e=Object.getOwnPropertyDescriptor(Eu.prototype,`cssText`);for(let t of[Du,CSSNestedDeclarations,CSSMediaRule,CSSSupportsRule,CSSContainerRule,CSSLayerBlockRule,CSSLayerStatementRule,CSSScopeRule,CSSStartingStyleRule,CSSImportRule,CSSNamespaceRule,DescriptorRule,CSSFontFaceRule,CSSPageRule,CSSPropertyRule,CSSKeyframeRule,CSSKeyframesRule]){let n=Object.getOwnPropertyDescriptor(t.prototype,`cssText`);n!==void 0&&n.set===void 0&&Object.defineProperty(t.prototype,"cssText",{...n,set:e.set})}}const Ou={getComputedStyle:null,evaluateMediaQuery:null,createCustomElementRegistry:null,setComputedColorMode:null};var MediaQueryListEvent=class extends Event{media;matches;constructor(e,t={}){super(e,t),this.media=t.media===void 0?``:String(t.media),this.matches=!!t.matches}},MediaQueryList=class extends EventTarget{[Y];[Gn];[Wn];[$n];constructor(e,t){super(),this[Y]=e,this[Gn]=t,this[Wn]=!1,this[$n]=null}get media(){return this[Gn]}get matches(){return evaluateMediaQuery(this[Gn],this[Y])}addListener(e){this.addEventListener(`change`,e)}removeListener(e){this.removeEventListener(`change`,e)}get onchange(){return this[$n]}set onchange(e){this[$n]!==null&&super.removeEventListener(`change`,this[$n]),this[$n]=typeof e==`function`||typeof e==`object`&&e?e:null,this[$n]!==null&&super.addEventListener(`change`,this[$n])}[Bn](){let e=this[Y][Kn];hasListeners(this,`change`)?e.has(this)||(this[Wn]=this.matches,e.add(this)):e.delete(this)}get[Symbol.toStringTag](){return`MediaQueryList`}};function reportMediaQueryChanges(e){for(let t of e[Kn]){let e=t.matches;e!==t[Wn]&&(t[Wn]=e,t.dispatchEvent(new MediaQueryListEvent(`change`,{media:t[Gn],matches:e})))}}function mediaEnvironment(e){return{width:e.innerWidth,height:e.innerHeight,devicePixelRatio:e.devicePixelRatio,mediaType:`screen`,features:e[V].mediaFeatures??null}}function evaluateMediaQuery(e,t){let n=mediaEnvironment(t),r=Ou.evaluateMediaQuery;return r===null?evaluateMediaQueryList(e,n,n.features??void 0):r(e,n)}const ku={"prefers-color-scheme":`light`,"prefers-reduced-motion":`no-preference`,"prefers-reduced-transparency":`no-preference`,"prefers-reduced-data":`no-preference`,"prefers-contrast":`no-preference`,"forced-colors":`none`,"inverted-colors":`none`,hover:`hover`,"any-hover":`hover`,pointer:`fine`,"any-pointer":`fine`,"display-mode":`browser`,scripting:`enabled`,update:`fast`,"color-gamut":`srgb`,"dynamic-range":`standard`,"video-dynamic-range":`standard`,"overflow-block":`scroll`,"overflow-inline":`scroll`,color:8,"color-index":0,monochrome:0,grid:0};function evaluateMediaQueryList(e,t,n){let r=splitTopLevel(String(e).toLowerCase(),`,`);if(r.length===1&&r[0].trim()===``)return!0;for(let e of r)if(evaluateQuery(e.trim(),t,n)===!0)return!0;return!1}function splitTopLevel(e,t){let n=[],r=0,i=0;for(let a=0;a<e.length;a++){let o=e[a];o===`(`?r++:o===`)`?r--:o===t&&r===0&&(n.push(e.slice(i,a)),i=a+1)}return n.push(e.slice(i)),n}function evaluateQuery(e,t,n){if(e===``)return null;if(e[0]===`(`||e.startsWith(`not (`)||e.startsWith(`not(`))return evaluateCondition(e,t,n);let r=/^(?:(not|only)\s+)?([a-z-]+)(?:\s+and\s+([\s\S]+))?$/.exec(e);if(r===null)return null;let[,i,a,o]=r,s=a===`all`||a===t.mediaType;return a!==`all`&&![`screen`,`print`,`speech`,`tv`,`tty`,`projection`,`handheld`,`braille`,`embossed`,`aural`].includes(a)&&(s=!1),o!==void 0&&s&&(s=evaluateCondition(o,t,n)),s===null?null:i===`not`?!s:s}function evaluateCondition(e,t,n){if(e=e.trim(),e.startsWith(`not`)){let r=evaluateInParens(e.slice(3).trim(),t,n);return r===null?null:!r}let r=[],i=[],a=0,o=0;for(let t=0;t<e.length;t++){let n=e[t];if(n===`(`)a++;else if(n===`)`)a--;else if(a===0){let n=e.slice(t),a=/^\s+(and|or)\s+/.exec(n)??(e[t-1]===`)`?/^\s*(and|or)\s*(?=\()/.exec(n):null);a!==null&&(r.push(e.slice(o,t)),i.push(a[1]),t+=a[0].length-1,o=t+1)}}r.push(e.slice(o));let s=evaluateInParens(r[0].trim(),t,n);for(let e=1;e<r.length;e++){let a=evaluateInParens(r[e].trim(),t,n);s=i[e-1]===`and`?s===!1||a===!1?!1:s===null||a===null?null:!0:s===!0||a===!0?!0:s===null||a===null?null:!1}return s}function evaluateInParens(e,t,n){if(e[0]!==`(`||e[e.length-1]!==`)`)return null;let r=e.slice(1,-1).trim();return r[0]===`(`||r.startsWith(`not `)||r.startsWith(`not(`)?evaluateCondition(r,t,n):evaluateFeature(r,t,n)}const Au=/^([^<>=]+?)\s*(<=|>=|<|>|=)\s*([^<>=]+?)(?:\s*(<=|>=|<|>|=)\s*([^<>=]+?))?$/;function evaluateFeature(e,t,n){let r=e.indexOf(`:`);if(r!==-1){let i=e.slice(0,r).trim(),a=e.slice(r+1).trim(),o=`=`;return i.startsWith(`min-`)?(i=i.slice(4),o=`>=`):i.startsWith(`max-`)&&(i=i.slice(4),o=`<=`),compareFeature(i,o,a,t,n)}let i=Au.exec(e);if(i!==null){let[,e,r,a,o,s]=i;if(o===void 0)return isFeatureName(e)?compareFeature(e.trim(),r,a,t,n):compareFeature(a.trim(),flip(r),e,t,n);let c=compareFeature(a.trim(),flip(r),e,t,n),l=compareFeature(a.trim(),o,s,t,n);return c===null||l===null?null:c&&l}let a=featureValue(e.trim(),t,n);return a===void 0?null:a!==0&&a!==`none`&&a!==`no-preference`}function isFeatureName(e){return/^[a-z-]+$/.test(e.trim())}function flip(e){return e===`<`?`>`:e===`>`?`<`:e===`<=`?`>=`:e===`>=`?`<=`:e}function featureValue(e,t,n){if(n!==void 0&&e in n)return n[e];switch(e){case`width`:case`device-width`:return t.width;case`height`:case`device-height`:return t.height;case`aspect-ratio`:case`device-aspect-ratio`:return t.height===0?0:t.width/t.height;case`orientation`:return t.height>=t.width?`portrait`:`landscape`;case`resolution`:case`-webkit-device-pixel-ratio`:case`device-pixel-ratio`:return t.devicePixelRatio;case`-webkit-min-device-pixel-ratio`:case`-webkit-max-device-pixel-ratio`:return t.devicePixelRatio}return ku[e]}function compareFeature(e,t,n,r,i){e===`-webkit-min-device-pixel-ratio`?t=`>=`:e===`-webkit-max-device-pixel-ratio`&&(t=`<=`);let a=featureValue(e,r,i);if(a===void 0)return null;let o=n.trim();if(typeof a==`string`)return t===`=`?a===o:null;let s=parseValue$1(e,o);if(s===null)return null;let c=a-s;switch(t){case`=`:return Math.abs(c)<1e-9;case`<`:return c<-1e-9;case`>`:return c>1e-9;case`<=`:return c<=1e-9;case`>=`:return c>=-1e-9}return null}function parseValue$1(e,t){if(e.endsWith(`aspect-ratio`)){let e=/^([\d.]+)\s*(?:\/\s*([\d.]+))?$/.exec(t);return e===null?null:Number(e[1])/(e[2]===void 0?1:Number(e[2]))}let n=/^(-?[\d.]+(?:e[+-]?\d+)?)([a-z%]*)$/.exec(t);if(n===null)return null;let r=Number(n[1]);if(Number.isNaN(r))return null;switch(n[2]){case``:return r;case`px`:return r;case`em`:case`rem`:return r*16;case`pt`:return r*96/72;case`pc`:return r*16;case`in`:return r*96;case`cm`:return r*96/2.54;case`mm`:return r*96/25.4;case`dppx`:case`x`:return r;case`dpi`:return r/96;case`dpcm`:return r*2.54/96}return null}__name(parseValue$1,`parseValue`);var IndexedRule=class{sel;specificity;sheetIndex;order;layer;block;owner;layerNode;h0;h1;h2;h3;constructor(e,t,n,r,i,a){this.sel=e,this.specificity=e.specificity,this.h0=e.h0,this.h1=e.h1,this.h2=e.h2,this.h3=e.h3,this.sheetIndex=t,this.order=n,this.layer=0,this.block=r,this.owner=a,this.layerNode=i}};function blockOf(e){return e.block??=e.owner[M]}var Bucket=class{rules;hashed;constructor(){this.rules=[],this.hashed=0}push(e){this.rules.push(e),e.h0>=0&&this.hashed++}},RuleBuckets=class{ids;classes;tags;universal;size;quirks;constructor(e){this.ids=/* @__PURE__ */ new Map,this.classes=/* @__PURE__ */ new Map,this.tags=/* @__PURE__ */ new Map,this.universal=new Bucket,this.size=0,this.quirks=e}add(e,t=!1){this.size++;let n=e.sel.keyKind,r=this.quirks&&(n===1||n===2)?asciiLowercase$1(e.sel.key):e.sel.key,i=null;if(n===1?i=this.ids:n===2?i=this.classes:n===3&&(i=this.tags),i===null){t&&(this.universal=copyBucket(this.universal)),this.universal.push(e);return}let a=i.get(r);a===void 0?i.set(r,a=new Bucket):t&&i.set(r,a=copyBucket(a)),a.push(e)}};function copyBucket(e){let t=new Bucket;for(let n=0;n<e.rules.length;n++)t.push(e.rules[n]);return t}var LayerNode=class{name;children;rank;constructor(e){this.name=e,this.children=/* @__PURE__ */ new Map,this.rank=0}},RuleIndex=class{attributeNames=null;main;before;after;volatile;styleVersion;builder;sheets;constructor(e,t=!1){this.main=new RuleBuckets(t),this.before=new RuleBuckets(t),this.after=new RuleBuckets(t),this.volatile=!1,this.styleVersion=e,this.builder=null,this.sheets=[]}},IndexedSheet=class{sheet;version;rules;applied;constructor(e,t){this.sheet=e,this.version=e[J],this.rules=e[U].length,this.applied=t}},IndexBuilder=class{index;env;sheetIndex;order;root;anon;all;extending;noteAttribute;constructor(e,t,n){this.noteAttribute=t=>{ariaOrData(t)&&(e.attributeNames??=n===null?/* @__PURE__ */ new Set:new ShadowAttributeNames(n.shadowAttributeUses??=new ShadowAttributeUses,e)).add(t)},this.index=e,this.env=t,this.sheetIndex=0,this.order=0,this.root=new LayerNode(``),this.anon=0,this.all=[],this.extending=!1}layer(e,t){let n=e;for(let e of t.split(`.`)){let t=n.children.get(e);t===void 0&&n.children.set(e,t=new LayerNode(e)),n=t}return n}sheet(e){return e[zt]||e[Gn][dr].length!==0&&!evaluateMediaQueryList$1(e[Gn][dr],this.env)?!1:(this.rules(e[U],this.root,null),!0)}rules(e,t,n){for(let r=0;r<e.length;r++){let i=e[r];if(i instanceof Du)i._mayDeclare()&&this.add(i._compile(),null,t,i),i[U].length!==0&&this.rules(i[U],t,i);else if(i instanceof CSSNestedDeclarations)n!==null&&this.style(n,i[M],t);else if(i instanceof CSSMediaRule)evaluateMediaQueryList$1(i[Gn][dr],this.env)&&this.rules(i[U],t,n);else if(i instanceof CSSSupportsRule)i[Wn]&&this.rules(i[U],t,n);else if(i instanceof CSSLayerBlockRule){let e=i[Jn]===``?`\0anon`+this.anon++:i[Jn];this.rules(i[U],this.layer(t,e),n)}else if(i instanceof CSSLayerStatementRule)for(let e of i[Yn])this.layer(t,e);else i instanceof CSSGroupingRule}}style(e,t,n){t.names.length!==0&&this.add(e._compile(),t,n)}add(e,t,n,r=null){if(e===null||t!==null&&t.names.length===0)return;let i=this.order++;for(let a of e.selectors){let e=new IndexedRule(a,this.sheetIndex,i,t,n,r);selectorAttributeNames(a,this.noteAttribute),a.volatile&&(this.index.volatile=!0);let o=a.pseudoElement;if(o===``)this.index.main.add(e,this.extending);else if(o===`before`)this.index.before.add(e,this.extending);else if(o===`after`)this.index.after.add(e,this.extending);else continue;this.all.push(e)}}extend(e,t){let n=this.all.length;this.extending=!0;let r=!0;t===0?r=this.sheet(e):this.rules(e[U].slice(t),this.root,null),this.extending=!1;for(let e=n;e<this.all.length;e++)this.all[e].layer=this.all[e].layerNode.rank;return r}finish(){let e=0,visit=t=>{for(let e of t.children.values())visit(e);t.rank=e++};visit(this.root);for(let e of this.all)e.layer=e.layerNode.rank}};function windowEnv(e){let t=e[Y];return t===null?vu:mediaEnvironment(t)}function currentStyleVersion(e){let t=e[Et];if(t===null)return e[Gr];let n=e[Y];if(n!==null){let r=n.innerWidth??1024,i=n.innerHeight??768,a=n.devicePixelRatio??1;(r!==t.envWidth||i!==t.envHeight||a!==t.envDpr)&&(t.envWidth!==-1&&e[Gr]++,t.envWidth=r,t.envHeight=i,t.envDpr=a)}return e[Gr]}function sheetsHaveRules(e){for(let t of e.owners)if(t[U].length!==0)return!0;for(let t of e.adopted)if(t instanceof Tu&&t[U].length!==0)return!0;return!1}function ruleIndexFor(e,t,n){if(!e.hasSheets())return null;let r=e.index,i=t[qn]===`quirks`;if(r!==null&&r.main.quirks===i&&(r.styleVersion===n||extendIndex(r,e,windowEnv(t),n)))return r.main.size+r.before.size+r.after.size===0?null:r;e.discardIndex(),r=new RuleIndex(n,i);let a=new IndexBuilder(r,windowEnv(t),e.root.type===9?null:docCSS(t)),o=treeSheets(e);for(let e=0;e<o.length;e++)a.sheetIndex=e,r.sheets.push(new IndexedSheet(o[e],a.sheet(o[e])));return a.finish(),r.builder=a,e.index=r,r.main.size+r.before.size+r.after.size===0?null:r}function treeSheets(e){let t=e.owners.slice();for(let n of e.adopted)n instanceof Tu&&t.push(n);return t}function extendIndex(e,t,n,r){let i=e.builder;if(i===null||!sameEnvironment(i.env,n))return!1;let a=treeSheets(t),o=e.sheets;if(a.length<o.length)return!1;for(let e=0;e<o.length;e++){let t=o[e],n=t.sheet;if(a[e]!==n||n[gr]>t.version)return!1}for(let e=o.length;e<a.length;e++){let t=a[e][U];for(let e=0;e<t.length;e++)if(!appendableRule(t[e]))return!1}for(let e=0;e<o.length;e++){let t=o[e],n=t.sheet[U];t.applied&&n.length>t.rules&&(i.sheetIndex=e,i.extend(t.sheet,t.rules)),t.version=t.sheet[J],t.rules=n.length}for(let e=o.length;e<a.length;e++)i.sheetIndex=e,o.push(new IndexedSheet(a[e],i.extend(a[e],0)));return e.styleVersion=r,!0}function sameEnvironment(e,t){return e.width===t.width&&e.height===t.height&&e.devicePixelRatio===t.devicePixelRatio&&e.mediaType===t.mediaType&&e.features===t.features}function uaDisplay(e){if(e.ns!==`http://www.w3.org/1999/xhtml`)return e.ns===`http://www.w3.org/2000/svg`&&svgNeverRendered(e)?`none`:e.parent!==null&&e.parent.type===9?`block`:`inline`;if(e.attrs!==null){if(e.tag!==Z.embed){let t=attr(e,`hidden`);if(t!==null&&asciiLowercase$1(t)!==`until-found`)return`none`}if(attr(e,`popover`)!==null&&!Ba[`popover-open`](e)&&(e.tag!==Z.dialog||attr(e,`open`)===null))return`none`}switch(e.tag){case Z.area:case Z.base:case Z.basefont:case Z.datalist:case Z.head:case Z.link:case Z.meta:case Z.noembed:case Z.noframes:case Z.param:case Z.rp:case Z.script:case Z.style:case Z.template:case Z.title:case Z.noscript:return`none`;case Z.dialog:return attr(e,`open`)===null&&!Ba[`popover-open`](e)?`none`:`block`;case Z.html:case Z.body:case Z.address:case Z.blockquote:case Z.center:case Z.div:case Z.figure:case Z.figcaption:case Z.footer:case Z.form:case Z.header:case Z.hr:case Z.legend:case Z.listing:case Z.main:case Z.p:case Z.plaintext:case Z.pre:case Z.search:case Z.xmp:case Z.details:case Z.summary:case Z.dir:case Z.dd:case Z.dl:case Z.dt:case Z.menu:case Z.ol:case Z.ul:case Z.article:case Z.aside:case Z.h1:case Z.h2:case Z.h3:case Z.h4:case Z.h5:case Z.h6:case Z.hgroup:case Z.nav:case Z.section:case Z.fieldset:case Z.optgroup:case Z.option:case Z.frameset:case Z.frame:return`block`;case Z.li:return`list-item`;case Z.table:return`table`;case Z.caption:return`table-caption`;case Z.colgroup:return`table-column-group`;case Z.col:return`table-column`;case Z.thead:return`table-header-group`;case Z.tbody:return`table-row-group`;case Z.tfoot:return`table-footer-group`;case Z.tr:return`table-row`;case Z.td:case Z.th:return`table-cell`;case Z.input:return attr(e,`type`)!==null&&asciiLowercase$1(attr(e,`type`))===`hidden`?`none`:`inline-block`;case Z.button:case Z.select:case Z.textarea:case Z.meter:case Z.progress:case Z.marquee:return`inline-block`;case Z.ruby:return`ruby`;case Z.rt:return`ruby-text`;case Z.slot:return`contents`}return`inline`}const ju=/* @__PURE__ */ new Set([`defs`,`clipPath`,`mask`,`marker`,`desc`,`title`,`metadata`,`pattern`,`linearGradient`,`radialGradient`,`script`,`style`,`symbol`]);function svgNeverRendered(e){return ju.has(e.name)}function uaDisplayImportant(e){if(e.ns===`http://www.w3.org/2000/svg`)return svgNeverRendered(e);if(e.tag===Z.noscript&&e.ns===`http://www.w3.org/1999/xhtml`)return!0;if(e.tag!==Z.input||e.ns!==`http://www.w3.org/1999/xhtml`)return!1;let t=attr(e,`type`);return t!==null&&asciiLowercase$1(t)===`hidden`}function uaRules(){let e=[];for(let t of`
18
- a[href], area[href] { color: rgb(0, 0, 238); text-decoration: underline; cursor: pointer; }
19
- b, strong, th, h1, h2, h3, h4, h5, h6, optgroup { font-weight: bold; }
20
- i, em, cite, var, dfn, address { font-style: italic; }
21
- h1 { font-size: 2em; } h2 { font-size: 1.5em; } h3 { font-size: 1.17em; } h5 { font-size: 0.83em; } h6 { font-size: 0.67em; }
22
- small { font-size: smaller; } big { font-size: larger; }
23
- sub { vertical-align: sub; font-size: smaller; } sup { vertical-align: super; font-size: smaller; }
24
- code, kbd, samp, tt, pre, listing, xmp, plaintext { font-family: monospace; }
25
- pre, listing, xmp, plaintext { white-space: pre; }
26
- textarea { white-space: pre-wrap; }
27
- u, ins { text-decoration: underline; }
28
- s, strike, del { text-decoration: line-through; }
29
- mark { background-color: yellow; color: black; }
30
- center, th, caption { text-align: center; }
31
- table { box-sizing: border-box; border-spacing: 2px; border-collapse: separate; }
32
- button, select, meter, progress { box-sizing: border-box; }
33
- ol { list-style-type: decimal; } ul, menu, dir { list-style-type: disc; }
34
- nobr { white-space: nowrap; }
35
- colgroup[hidden], col[hidden], thead[hidden], tbody[hidden], tfoot[hidden], tr[hidden] { visibility: collapse; }
36
- `.split(`}`)){let n=t.indexOf(`{`);if(n===-1)continue;let r=new DeclBlock;for(let e of t.slice(n+1).split(`;`)){let t=e.indexOf(`:`);t!==-1&&r.put(e.slice(0,t).trim(),e.slice(t+1).trim(),!1)}e.push([t.slice(0,n).trim(),r])}return e}let Mu=null;function uaRuleIndex(){if(Mu!==null)return Mu;Mu=new RuleIndex(0);let e=new IndexBuilder(Mu,vu,null);for(let[t,n]of uaRules())e.add(compileSelectorList(t),n,e.root);return e.finish(),Mu}const Nu=pendingLonghandsMap();var StyleRecord=class{el;pseudo;decls;ua;displayLocked;computed;custom;customDone;display;visibility;pointerEvents;volatile;deps;inheritsVolatile;before;after;root;constructor(e,t){this.el=e,this.pseudo=t,this.decls=null,this.ua=null,this.displayLocked=!1,this.computed=null,this.custom=null,this.customDone=!1,this.display=``,this.visibility=``,this.pointerEvents=``,this.volatile=!1,this.deps=null,this.inheritsVolatile=!1,this.before=null,this.after=null,this.root=null}};const Pu=/* @__PURE__ */ new Map;function inlineBlock(e){if(!(e.flags&64))return null;let t=e.node[Wr];if(t!=null)return t[M];let n=attr(e,`style`);if(n===null||n===``)return null;let r=Pu.get(n);return r===void 0&&(r=parseDeclBlock(n),Pu.size>2e3&&Pu.clear(),Pu.set(n,r)),r}function inheritanceParent(e){let t=e.parent;if(t===null)return null;if(t.type===1)return t;if(t.flags&32){let e=t.node[R];return e?e[z]:null}return null}function rootOf(e){let t=e;for(;t.parent!==null;)t=t.parent;return t.type===9||t.flags&32?rootStylesFor(t,!1):null}function shadowStylesOf(e){let t=e.node[G];return t==null?null:rootStylesFor(t[z],!1)}function hostOf(e){if(e.root.type===9)return null;let t=e.root.node[R];return t?t[z]:null}var Matched=class{rule;context;constructor(e,t){this.rule=e,this.context=t}};let Fu=null,Iu=[],Lu=0;function buildFilter(e){Iu=buildAncestorFilter(e),Fu=e,zu=null}function resetFilter(){Fu=null,zu=null}var Survivors=class{hashes;lists;constructor(e){this.hashes=e,this.lists=/* @__PURE__ */ new WeakMap}};const Ru=/* @__PURE__ */ new WeakMap;let zu=null;function sameHashes(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}function filterSurvivors(e,t,n){Fu!==t&&buildFilter(t);let r=zu;r===null&&(r=Ru.get(n)??null,r!==null&&sameHashes(r.hashes,Iu)||(r=new Survivors(Iu.slice()),Ru.set(n,r)),zu=r);let i=r.lists.get(e);if(i===void 0){i=[];let t=e.rules;for(let e=0;e<t.length;e++){let n=t[e];mayMatchAncestors(n.h0,n.h1,n.h2,n.h3)&&i.push(n)}r.lists.set(e,i)}return i}function testRules(e,t,n,r,i,a,o){if(e===void 0)return;let s=e.rules;i&&e.hashed>=16&&t.parent!==null&&(s=filterSurvivors(e,t,t.parent),i=!1);for(let e=0;e<s.length;e++){let c=s[e];i&&c.h0>=0&&(Fu!==t&&++Lu>2&&buildFilter(t),Fu===t&&!mayMatchAncestors(c.h0,c.h1,c.h2,c.h3))||(r===void 0?matchesSelectorDirect(c.sel,t,n):matchesSelector(c.sel,t,n,r))&&o.push(new Matched(c,a))}}function collect$2(e,t,n,r,i,a){if(e.size===0)return;let o=r===null?void 0:{shadowHost:r},s=e.quirks,c=!s;if(t.id!==``&&e.ids.size!==0&&testRules(e.ids.get(s?asciiLowercase$1(t.id):t.id),t,n,o,c,i,a),e.classes.size!==0&&t.attrs!==null){let r=classTokens(t);for(let l=0;l<r.length;l++)testRules(e.classes.get(s?asciiLowercase$1(r[l]):r[l]),t,n,o,c,i,a)}e.tags.size!==0&&testRules(e.tags.get(asciiLowercase$1(t.name)),t,n,o,c,i,a),testRules(e.universal,t,n,o,c,i,a)}__name(collect$2,`collect`);function bucketsFor(e,t){return t===0?e.main:t===1?e.before:e.after}function applyBlock(e,t,n){let r=t.names,i=t.values;for(let a=0;a<r.length;a++){if(t.isImportant(a)!==n)continue;let o=r[a],s=Nu.get(o);if(s!==void 0){let t=`\0`+o+`\0`+i[a];for(let n=0;n<s.length;n++)e.set(s[n],t);e.set(o,i[a])}else e.set(o,i[a])}}function cascade(e,t,n,r){let i=null,a=!1;if(r.length!==0){i=/* @__PURE__ */ new Map,r.sort(normalOrder);for(let e of r)applyBlock(i,blockOf(e.rule),!1);e.ua=new Map(i)}if(t.length!==0){i??=/* @__PURE__ */ new Map,t.sort(normalOrder);for(let e of t){let t=blockOf(e.rule);applyBlock(i,t,!1),a||=t.important?.includes(!0)===!0}}if(n!==null&&n.names.length!==0&&(i??=/* @__PURE__ */ new Map,applyBlock(i,n,!1)),a){t.sort(importantOrder);for(let e of t)applyBlock(i,blockOf(e.rule),!0)}n!==null&&n.important?.includes(!0)&&applyBlock(i,n,!0),e.decls=i}function normalOrder(e,t){return e.context-t.context||e.rule.layer-t.rule.layer||e.rule.specificity-t.rule.specificity||e.rule.sheetIndex-t.rule.sheetIndex||e.rule.order-t.rule.order}function importantOrder(e,t){return t.context-e.context||t.rule.layer-e.rule.layer||e.rule.specificity-t.rule.specificity||e.rule.sheetIndex-t.rule.sheetIndex||e.rule.order-t.rule.order}function collectAuthor(e,t,n,r,i){let a=e.doc,o=t===0?``:t===1?`before`:`after`;if(n!==null){let s=ruleIndexFor(n,a,r);s!==null&&collect$2(bucketsFor(s,t),e,o,hostOf(n),1,i)}let s=shadowStylesOf(e);if(s!==null){let n=ruleIndexFor(s,a,r);n!==null&&collect$2(bucketsFor(n,t),e,o,e,0,i)}}function layerKey(e){return e.context*1048576+e.rule.layer}let Bu,Vu=0;function winnerIn(e,t,n,r){let i=e.names;for(let a=0;a<i.length;a++){if(e.isImportant(a)!==t)continue;let o=i[a];if(o===n)Bu=e.values[a],Vu=r;else{let t=Nu.get(o);t!==void 0&&t.indexOf(n)!==-1&&(Bu=`\0`+o+`\0`+e.values[a],Vu=r)}}}function effectiveValue(e,t,n){if(n.charCodeAt(0)===0)return isCustomPropertyName(t)?n:resolvePending(e,t,n);if(!isCustomPropertyName(t)&&containsVar(n)){let t=substitute(n,t=>customProps(e)?.get(t)??null);return t===null?null:t.trim()}return n}function revertLayerValue(e,t){let n=e.el,r=[];resetFilter(),Lu=0,collectAuthor(n,e.pseudo,e.root,currentStyleVersion(n.doc),r),resetFilter(),r.sort(normalOrder);let i=r.slice().sort(importantOrder),a=e.pseudo===0?inlineBlock(n):null,o=[];for(;;){Bu=void 0,Vu=0;for(let e=0;e<r.length;e++){let n=layerKey(r[e]);o.indexOf(n)===-1&&winnerIn(blockOf(r[e].rule),!1,t,n)}a!==null&&o.indexOf(-1)===-1&&winnerIn(a,!1,t,-1);for(let e=0;e<i.length;e++){let n=layerKey(i[e]);o.indexOf(n)===-1&&winnerIn(blockOf(i[e].rule),!0,t,n)}a!==null&&o.indexOf(-1)===-1&&winnerIn(a,!0,t,-1);let n=Bu;if(n===void 0)return;let s=effectiveValue(e,t,n);if(s===null||s.toLowerCase()!==`revert-layer`)return n;o.push(Vu)}}function computeRecord(e,t,n){resetFilter(),Lu=0;let r=new StyleRecord(e,t),i=rootOf(e);r.root=i;let a=[],o=beginStateDeps();collectAuthor(e,t,i,n,a);let s=endStateDeps(o);s!==null&&(depsOnAncestors(s,e)?r.deps=s:r.volatile=!0);let c=[];return t===0&&e.ns===`http://www.w3.org/1999/xhtml`&&collect$2(uaRuleIndex().main,e,``,null,0,c),cascade(r,a,t===0?inlineBlock(e):null,c),t===0&&(r.displayLocked=uaDisplayImportant(e),e.attrs!==null&&attr(e,`popover`)!==null&&(r.volatile=!0)),resetFilter(),r}function depsOnAncestors(e,t){let n=e.els;outer:for(let e=0;e<n.length;e++){let r=n[e];for(let e=t;e!==null;e=e.parent)if(e===r)continue outer;return!1}return!0}function reusable(e){if(e.volatile)return!1;if(e.deps===null){if(!e.inheritsVolatile)return!0}else if(!stateDepsHold(e.deps))return!1;return e.computed=null,e.custom=null,e.customDone=!1,e.display=``,e.visibility=``,e.pointerEvents=``,e.before=null,e.after=null,!0}function styleRecord(e){let t=e.doc,n=currentStyleVersion(t),r=nodeCache(e),i=r.style,a=t[J]-t[et];if(i!==null&&r.styleVersion===a&&r.styleSheetVersion===n&&reusable(i))return i;let o=computeRecord(e,0,n);return r.style=o,noteStyleRecordCached(),r.styleVersion=a,r.styleSheetVersion=n,o}function pseudoRecord(e,t){let n=styleRecord(e),r=t===1?n.before:n.after;if(r!==null&&reusable(r))return r;let i=computeRecord(e,t,e.doc[Gr]);return t===1?n.before=i:n.after=i,i}function recordFor(e,t){return t===0?styleRecord(e):pseudoRecord(e,t)}function dependOn(e,t){return(t.volatile||t.deps!==null||t.inheritsVolatile)&&(e.inheritsVolatile=!0),t}function parentRecord(e){if(e.pseudo!==0)return dependOn(e,styleRecord(e.el));let t=inheritanceParent(e.el);return t===null?null:dependOn(e,styleRecord(t))}function customProps(e){if(e.customDone)return e.custom;e.customDone=!0;let t=parentRecord(e),n=t===null?null:customProps(t),r=e.decls,i=null;if(r!==null)for(let e of r.keys())isCustomPropertyName(e)&&(i??=[]).push(e);if(i===null)return e.custom=n,n;let a=n===null?/* @__PURE__ */ new Map:new Map(n);e.custom=a;let o=/* @__PURE__ */ new Map,resolve=t=>{let i=o.get(t);if(i===2)return a.get(t)??null;if(i===1)return null;let s=r.get(t);if(s===void 0)return a.get(t)??null;o.set(t,1);let c=s.toLowerCase();if(c===`revert-layer`){let n=revertLayerValue(e,t);n!==void 0&&(s=n,c=n.toLowerCase())}let l=s;return c===`initial`?l=null:c===`inherit`||c===`unset`||c===`revert`||c===`revert-layer`?l=n?.get(t)??null:containsVar(s)&&(l=substitute(s,e=>r.has(e)?resolve(e):a.get(e)??null)),o.set(t,2),l===null?a.delete(t):a.set(t,l),l};for(let e of i)resolve(e);return a}function substitute(e,t){let n=new CSSTokenizer(e),r=``,i=0;for(;;){let a=n.next();if(a===0)break;if(a!==2)continue;let o=n.value.toLowerCase();if(o!==`var`&&o!==`env`)continue;let s=n.start,c=n.end,l=1,u=-1,d=e.length,m=e.length;for(;l>0;){let e=n.next();if(e===0)break;e===2||e===21||e===19?l++:e===22||e===20?(l--,l===0&&(d=n.start,m=n.end)):e===18&&l===1&&u===-1&&(u=n.start)}let h=e.slice(c,u===-1?d:u).trim(),_=u===-1?null:e.slice(u+1,d).trim(),v=o===`var`?t(h):envValue(h);if(v===null&&_!==null&&(v=containsVar(_)?substitute(_,t):_),v===null)return null;r+=e.slice(i,s)+v,i=m}return r+e.slice(i)}function envValue(e){return e.startsWith(`safe-area-inset-`)||e.startsWith(`keyboard-inset-`)?`0px`:null}const Hu={"xx-small":9,"x-small":10,small:13,medium:16,large:18,"x-large":24,"xx-large":32,"xxx-large":48};function px(e){return formatNumber(Math.round(e*1e4)/1e4)+`px`}function parentPx(e,t,n){let r=parentRecord(e);if(r===null)return n;let i=computedValueOf(r,t),a=parseFloat(i);return Number.isNaN(a)?n:a}function rootFontSize(e){let t=e.el.doc,n=null;for(let e=t[z].first;e!==null;e=e.next)e.type===1&&(n=e);return n===null||n===e.el?16:parseFloat(computedValueOf(dependOn(e,styleRecord(n)),`font-size`))||16}function absLength(e,t,n,r){switch(t){case`px`:return e;case`em`:return e*n;case`rem`:return e*r;case`ex`:return e*n*.5;case`ch`:return e*n*.5;case`in`:return e*96;case`cm`:return e*96/2.54;case`mm`:return e*96/25.4;case`q`:return e*96/101.6;case`pt`:return e*96/72;case`pc`:return e*16}return null}function computeFontSize(e,t){let n=splitComponents(t);if(n===null||n.length!==1)return t;let r=n[0];if(r.type===1){let n=Hu[r.lower];return n===void 0?r.lower===`smaller`?px(parentPx(e,`font-size`,16)/1.2):r.lower===`larger`?px(parentPx(e,`font-size`,16)*1.2):t:px(n)}if(r.type===11)return px(parentPx(e,`font-size`,16)*r.num/100);if(r.type===12){let n=absLength(r.num,r.lower,parentPx(e,`font-size`,16),r.lower===`rem`?rootFontSize(e):16);return n===null?t:px(n)}return t}function computeFontWeight(e,t){switch(t){case`normal`:return`400`;case`bold`:return`700`;case`bolder`:{let t=parentPx(e,`font-weight`,400);return t<350?`400`:t<550?`700`:t<900?`900`:formatNumber(t)}case`lighter`:{let t=parentPx(e,`font-weight`,400);return t<100?formatNumber(t):t<550?`100`:t<750?`400`:`700`}}return t}let Uu=`specified`;function setComputedColorMode(e){Uu=e}const Wu={thin:`1px`,medium:`3px`,thick:`5px`};function borderStyleFor(e){let t=/^(border-(?:top|right|bottom|left)|outline|column-rule)-width$/.exec(e);return t===null?null:t[1]+`-style`}function computeSpecified(e,t,n){if(t===`font-size`)return computeFontSize(e,n);if(t===`font-weight`)return computeFontWeight(e,n);let r=borderStyleFor(t);if(r!==null){let t=computedValueOf(e,r);return t===`none`||t===`hidden`?`0px`:Wu[n]??n}if(grammarFor(t).types&16){if(Uu===`specified`){if(n.toLowerCase()!==`currentcolor`)return n;if(t!==`color`)return computedValueOf(e,`color`);let r=parentRecord(e);return r===null?`rgb(0, 0, 0)`:computedValueOf(r,`color`)}if(t===`color`){if(n.toLowerCase()===`currentcolor`){let t=parentRecord(e);return t===null?`rgb(0, 0, 0)`:computedValueOf(t,`color`)}return computeColor(n,`rgb(0, 0, 0)`)}return computeColor(n,n.toLowerCase().indexOf(`currentcolor`)===-1?``:computedValueOf(e,`color`))}return n}function initialValue(e,t){if(t===`display`)return`inline`;if(t===`content`&&e.pseudo!==0)return`none`;let n=propertyInfo(t);return n===void 0||n.initial===``?``:computeSpecified(e,t,n.initial)}function inheritedValue(e,t){let n=parentRecord(e);return n===null?initialValue(e,t):computedValueOf(n,t)}function resolvePending(e,t,n){let r=n.indexOf(`\0`,1),i=n.slice(1,r),a=n.slice(r+1);if(containsVar(a)&&(a=substitute(a,t=>customProps(e)?.get(t)??null)),a===null)return null;let o=a.trim().toLowerCase();if(isCSSWideKeyword(o))return o;let s=isCascadeOnlyShorthand(i)?expandCascadeShorthand(i,a):expandShorthand(i,a);if(s===null||s===Ql)return null;let c=cascadeLonghandsOf(i).indexOf(t);return c===-1?null:s[c]}function computedValueOf(e,t){if(t===`display`)return computeDisplay(e);if(t===`visibility`)return e.visibility||=cascadedToComputed(e,t,e.decls?.get(t));if(t===`pointer-events`)return e.pointerEvents||=cascadedToComputed(e,t,e.decls?.get(t));if(isCustomPropertyName(t))return customProps(e)?.get(t)??``;let n=e.computed;if(n!==null){let e=n.get(t);if(e!==void 0)return e}let r,i=Nu.get(t);if(i!==void 0){let n=[];for(let t of i)n.push(computedValueOf(e,t));r=n.indexOf(``)===-1?isCascadeOnlyShorthand(t)?serializeCascadeShorthand(t,n):serializeShorthand(t,n,t!==`background`):``}else r=cascadedToComputed(e,t,e.decls?.get(t));return n===null&&(e.computed=n=/* @__PURE__ */ new Map),n.set(t,r),r}function cascadedToComputed(e,t,n){let r=propertyInfo(t),i=r!==void 0&&r.inherited;if(n!==void 0&&n.charCodeAt(0)===0){let r=resolvePending(e,t,n);n=r===null?`unset`:r}else if(n!==void 0&&containsVar(n)){let r=substitute(n,t=>customProps(e)?.get(t)??null);n=r===null||normalizeLonghand(t,r)===null?`unset`:r.trim()}if(n===void 0){if(t===`direction`&&e.pseudo===0){let t=uaDirection(e.el);if(t!==``)return t}return i?inheritedValue(e,t):initialValue(e,t)}switch(n){case`inherit`:return inheritedValue(e,t);case`initial`:return initialValue(e,t);case`unset`:return i?inheritedValue(e,t):initialValue(e,t);case`revert-layer`:{let n=revertLayerValue(e,t);if(n!==void 0)return cascadedToComputed(e,t,n)}case`revert`:{let n=e.ua?.get(t);return n!==void 0&&n!==`revert`&&n!==`revert-layer`?cascadedToComputed(e,t,n):i?inheritedValue(e,t):initialValue(e,t)}}return computeSpecified(e,t,n)}function uaDirection(e){return e.ns!==`http://www.w3.org/1999/xhtml`||attr(e,`dir`)===null&&e.tag!==Z.bdi&&(e.tag!==Z.input||inputTypeName(e)!==`tel`)?``:directionality(e)===2?e.tag===Z.input&&attr(e,`dir`)===null?`ltr`:`rtl`:`ltr`}function substituteDisplay(e,t){let n=substitute(t,t=>customProps(e)?.get(t)??null);return n===null||normalizeLonghand(`display`,n)===null?`unset`:n.trim()}function computeDisplay(e){if(e.display!==``)return e.display;let t;if(e.displayLocked)t=`none`;else{let n=e.decls?.get(`display`);n!==void 0&&containsVar(n)&&(n=substituteDisplay(e,n)),n===`revert-layer`&&(n=revertLayerValue(e,`display`),n!==void 0&&containsVar(n)&&(n=substituteDisplay(e,n)));let r=e.pseudo===0?uaDisplay(e.el):`inline`;t=n===void 0||n===`revert`||n===`revert-layer`?r:n===`inherit`?inheritedValue(e,`display`):n===`initial`||n===`unset`?`inline`:n}if(e.pseudo!==0&&t!==`none`&&t!==`contents`){let n=computeDisplay(dependOn(e,styleRecord(e.el)));(n===`flex`||n===`inline-flex`||n===`grid`||n===`inline-grid`)&&(t=blockify(t))}return e.display=t,t}function blockify(e){switch(e){case`inline`:case`inline-block`:case`run-in`:return`block`;case`inline-flex`:return`flex`;case`inline-grid`:return`grid`;case`inline-table`:return`table`;case`inline-list-item`:return`list-item`}return e.startsWith(`inline `)?e.slice(7):e}function hasAuthorStyles(e){let t=existingDocCSS(e);if(t!==null){let n=currentStyleVersion(e);if(t.authorVersion===e[J]&&t.authorStyleVersion===n)return t.authorResult;let r=sheetsHaveRules(t.main);if(!r&&t.shadows!==null){let e=t.shadows.refs;for(let t of e){let n=t.deref();n===void 0?e.delete(t):sheetsHaveRules(n)&&(r=!0)}}return!r&&inlineStyleCount(e)>0&&(r=hasConnectedInlineStyle(e)),t.authorVersion=e[J],t.authorStyleVersion=n,t.authorResult=r,r}return inlineStyleCount(e)!==0&&hasAuthorStyles(docCSSFor(e))}function docCSSFor(e){return docCSS(e),e}function hasConnectedInlineStyle(e){let t=e[z];for(let e=nextElementInTree(t,t);e!==null;e=nextElementInTree(e,t))if(e.flags&64)return!0;return!1}function sheetsApply(e){let t=e.doc[Et];return t===null?!1:t.main.hasSheets()?!0:t.shadows!==null&&t.shadows.refs.size!==0}function plain$1(e){return!(e.flags&64)&&!sheetsApply(e)}__name(plain$1,`plain`);function computedPosition(e){return plain$1(e)?`static`:computedValueOf(styleRecord(e),`position`)}function computedDisplay(e){return plain$1(e)?uaDisplay(e):computeDisplay(styleRecord(e))}function styledDisplay(e){return plain$1(e)?null:computeDisplay(styleRecord(e))}function isDisplayNone(e){return plain$1(e)?uaDisplay(e)===`none`:computeDisplay(styleRecord(e))===`none`}function boxFacts(e,t){if(!t&&!(e.flags&64))return+(uaDisplay(e)===`none`);let n=styleRecord(e);return+(computeDisplay(n)===`none`)|(computedValueOf(n,`position`)===`static`?0:2)}function sheetsApplyTo(e){return sheetsApply(e)}function isDisplayNoneInclusive(e){for(let t=e;t!==null;t=inheritanceParent(t))if(isDisplayNone(t))return!0;return!1}function inheritedKeyword(e,t,n){if(plain$1(e)){if(inlineStyleCount(e.doc)===0)return n;let t=inheritanceParent(e);for(;t!==null&&plain$1(t);)t=inheritanceParent(t);if(t===null)return n;e=t}return computedValueOf(styleRecord(e),t)}function computedVisibility(e){return inheritedKeyword(e,`visibility`,`visible`)}function isVisibilityHidden(e){let t=computedVisibility(e);return t===`hidden`||t===`collapse`}function pointerEvents(e){return inheritedKeyword(e,`pointer-events`,`auto`)}function pointerEventsNone(e){return pointerEvents(e)===`none`}function pseudoKind(e){if(e==null||e===``)return 0;let t=e.toLowerCase();return t===`::before`||t===`:before`?1:t===`::after`||t===`:after`?2:-1}function computedValue(e,t,n){let r=pseudoKind(n);if(r===-1)return``;let i=isCustomPropertyName(t)?t:canonicalPropertyName(t.toLowerCase());if(r===0){if(i===`display`)return computedDisplay(e);if(i===`visibility`)return computedVisibility(e);if(i===`pointer-events`)return pointerEvents(e)}return computedValueOf(recordFor(e,r),i)}function customPropertyNames(e,t){let n=pseudoKind(t);if(n===-1||plain$1(e))return Gu;let r=customProps(recordFor(e,n));return r===null?Gu:[...r.keys()].sort()}const Gu=[];function pseudoContent(e,t){if(e.doc[Et]===null||!sheetsApply(e))return``;let n=pseudoKind(t);if(n<=0)return``;let r=rootOf(e);if(r===null)return``;let i=ruleIndexFor(r,e.doc,currentStyleVersion(e.doc));return i===null||bucketsFor(i,n).size===0?``:contentText(e,computedValueOf(recordFor(e,n),`content`))}function contentText(e,t){if(t===``||t===`none`||t===`normal`)return``;let n=splitComponents(t);if(n===null)return``;let r=``;for(let t of n)if(t.type!==100){if(t.type===9&&t.value===`/`)break;if(t.type===5)r+=t.value;else if(t.type===2&&t.lower===`attr`){let n=t.text.slice(5,-1).trim().split(/\s|,/)[0];r+=attr(e,n.toLowerCase())??``}}return r}const Ku=new DeclBlock;Object.freeze(Ku.names),Object.freeze(Ku.values),Object.freeze(Ku);var qu=class CSSComputedStyleDeclaration extends CSSStyleDeclaration{[F];[ur];constructor(e,t){super(null,Ku),this[F]=e,this[ur]=t,this[mr]=!0,Ju===null&&(Ju=indexGetterTable(CSSComputedStyleDeclaration.prototype,(e,t)=>e.item(t),computedPropertyNames().length))}get length(){if(this[ur]===Yu)return 0;let e=computedPropertyNames().length+customNames(this[F],this[ur]).length;return Ju!==null&&e>Ju.count&&ensureIndexGetters(Ju,e),e}item(e){if(this[ur]===Yu)return``;let t=computedPropertyNames(),n=e>>>0;return n<t.length?t[n]:customNames(this[F],this[ur])[n-t.length]??``}getPropertyValue(e){return this[ur]===Yu?``:computedValue(this[F],String(e),this[ur])}getPropertyPriority(e){return``}get cssText(){return``}set cssText(e){this._checkWritable()}_syncIndices(){}};let Ju=null;const Yu=`\0invalid`;function customNames(e,t){return customPropertyNames(e,t)}function getComputedStyle(e,t){let n=e[z],r=t==null||t===``?null:String(t);if(r!==null){let e=r.toLowerCase();e.charCodeAt(0)===58?e!==`::before`&&e!==`::after`&&e!==`:before`&&e!==`:after`&&(r=Yu):r=null}if(r===null){let e=nodeCache(n);return e.computedStyle??=new qu(n,null)}return new qu(n,r)}function styleElementUpdated(e,t,n=``){return createOwnerSheet(e,t,n)}function styleElementRemoved(e,t){removeOwnerSheet(e,t)}function isRenderingHidden(e){return isDisplayNoneInclusive(e)}function contentEditableState(e){if(!(e.flags&131072))return-1;let t=contentAttr(e,`contenteditable`);if(t===null)return-1;switch(asciiLowercase$1(t)){case``:case`true`:return 1;case`false`:return 0;case`plaintext-only`:return 2}return-1}const Xu=/* @__PURE__ */ new WeakSet;let Zu=!1;function isDesignModeEnabled(e){return Zu&&Xu.has(e)}function setDesignModeEnabled(e,t){t?(Zu=!0,Xu.add(e)):Xu.delete(e)}function isDesignModeRoot(e,t){return Zu&&t.type===9&&e.ns===`http://www.w3.org/1999/xhtml`&&Xu.has(t.node)}function isEditable(e){if(e.type!==1)return!1;for(let t=e;;){if(t.ns===`http://www.w3.org/1999/xhtml`){let e=contentEditableState(t);if(e===1||e===2)return!0;if(e===0)return!1}let e=t.parent;if(e===null)return!1;if(e.type!==1)return isDesignModeRoot(t,e);t=e}}function isEditingHost(e){if(e.ns!==`http://www.w3.org/1999/xhtml`)return!1;let t=e.parent;if(t!==null&&isDesignModeRoot(e,t))return!0;let n=contentEditableState(e);return n!==1&&n!==2?!1:t===null||t.type!==1||!isEditable(t)}let Qu=null;function setNotImplementedHandler(e){Qu=e}function notImplementedActive(){return Qu!==null}const $u=[`navigation (except hash changes)`,`navigation to another Document`],ed=[`window.getComputedStyle(elt, pseudoElt)`,`Window's getComputedStyle() method: with pseudo-elements`];function stubbedMethod(e,t){return[e===`Window`?`window.${t}`:`${e}.prototype.${t}`,`${e}'s ${t}() method`]}function reportNotImplemented(e,t){if(Qu===null||e===null)return;let n=e[V]?.compat;if(n!==`jsdom-26`&&n!==`jsdom-30`)return;let r=n===`jsdom-26`,i=/* @__PURE__ */ Error(`Not implemented: ${r?t[0]:t[1]}`);i.type=r?`not implemented`:`not-implemented`,Qu(i,n)}const td=stubbedMethod(`HTMLFormElement`,`requestSubmit`),nd={keywords:[`application/x-www-form-urlencoded`,`multipart/form-data`,`text/plain`],missing:``,invalid:`application/x-www-form-urlencoded`},rd={keywords:[`get`,`post`,`dialog`],missing:``,invalid:`get`};function isSubmitButton(e){if(e.tag===Z.button)return buttonType(e)===`submit`;if(e.tag===Z.input){let t=inputType(e);return t===18||t===19}return!1}function buttonType(e){let t=attr(e,`type`);if(t!==null){let e=asciiLowercase$1(t);if(e===`reset`||e===`button`||e===`submit`)return e}return e.attrs!==null&&(attr(e,`commandfor`)!==null||attr(e,`command`)!==null)?`button`:`submit`}function defaultButton(e){let t=formOwnerScope(e,!0);for(let n=t;n!==null;n=nextElementInTree(n,t))if(isSubmitButton(n)&&formOwner(n)===e)return n;return null}function staticallyValidate(e){let t=e.node._controls(),n=[];for(let e=0;e<t.length;e++){let r=t[e];isSubmittable(r)&&isInvalidCandidate(validatableOf(r))&&n.push(r)}if(n.length===0)return null;let r=[];for(let e=0;e<n.length;e++)fireEvent$1(n[e].node,`invalid`,!1,!0)&&r.push(n[e]);return r}function formCheckValidity(e){return staticallyValidate(e)===null}function submitForm(e,t,n){let r=e.node;if(e.flags&1&&!r[vt]){if(!n){if(r[$t])return;r[$t]=!0;try{let n=r._controls();for(let e=0;e<n.length;e++)isSubmittable(n[e])&&setUserValidity(n[e],!0);if(!(t!==e&&attr(t,`formnovalidate`)!==null||attr(e,`novalidate`)!==null)&&staticallyValidate(e)!==null||!dispatchTrusted$1(r,new SubmitEvent(`submit`,{bubbles:!0,cancelable:!0,submitter:t===e?null:t.node})))return}finally{r[$t]=!1}if(!(e.flags&1))return}id!==null&&id(e,t)||n||reportNotImplemented(e.doc[Y],td)}}let id=null;function setDialogSubmission(e){id=e}function resetForm(e){let t=e.node;if(!t[Un]){t[Un]=!0;try{if(fireEvent$1(t,`reset`,!0,!0)){let t=formControls(e,[],!0);for(let e=0;e<t.length;e++){let n=t[e];isFACE(n)?faceReset(n):isResettable(n)&&n.node._reset()}}}finally{t[Un]=!1}}}function blocksImplicitSubmission(e){switch(e){case 1:case 2:case 4:case 3:case 5:case 6:case 7:case 8:case 9:case 10:case 11:case 12:return!0}return!1}function implicitSubmission(e){let t=defaultButton(e);if(t!==null){if(isActuallyDisabled(t))return;syntheticClick(t.node);return}let n=e.node._controls(),r=0;for(let e=0;e<n.length;e++){let t=n[e];t.tag===Z.input&&blocksImplicitSubmission(inputType(t))&&r++}r>1||submitForm(e,e,!1)}function syntheticClick(e){let t=e.click;if(typeof t==`function`){t.call(e);return}let n=new Event(`click`,{bubbles:!0,cancelable:!0,composed:!0});e.dispatchEvent(n)&&e._activationBehavior?.(n)}function textareaWrappingTransformation(e,t){let n=attr(e,`wrap`);if(n===null||asciiLowercase$1(n)!==`hard`)return t;let r=e.node.cols,i=t.split(`
37
- `);for(let e=0;e<i.length;e++){let t=i[e];if(t.length<=r)continue;let n=``;for(;t.length>r;){let e=t.lastIndexOf(` `,r),i=e>0?e+1:r;n+=t.slice(0,i)+`
38
- `,t=t.slice(i)}i[e]=n+t}return i.join(`
39
- `)}const ad=/* @__PURE__ */ new WeakMap;function constructEntryList(e,t,n=null){let r=e.node;if(r[vt])return null;r[vt]=!0;let i=[];try{let r=formControls(e,[],!0);for(let e=0;e<r.length;e++){let n=r[e];if(!isSubmittable(n)||hasDatalistAncestor(n)||isActuallyDisabled(n))continue;let a=n.tag,o=a===Z.input?inputType(n):-1;if((a===Z.button||o===18||o===20||o===21||o===19)&&n!==t)continue;let s=n.node;if((o===15||o===16)&&!s.checked)continue;if(o===19){let e=attr(n,`name`)??``,t=e===``?``:e+`.`,r=ad.get(n);i.push([t+`x`,r===void 0?`0`:String(r.x)],[t+`y`,r===void 0?`0`:String(r.y)]);continue}if(isFACE(n)){faceEntries(n,i);continue}let c=attr(n,`name`);if(c!==null&&c!==``){if(a===Z.select){let e=listOfOptions(n,[]);for(let t=0;t<e.length;t++){let n=e[t],r=n.node;r.selected&&!isActuallyDisabled(n)&&i.push([c,r.value])}}else if(o===15||o===16)i.push([c,attr(n,`value`)??`on`]);else if(o===17){let e=s.files;if(e===null||e.length===0)i.push([c,new File([],``,{type:`application/octet-stream`})]);else for(let t=0;t<e.length;t++)i.push([c,e.item(t)])}else o===0&&c.toLowerCase()===`_charset_`?i.push([c,`UTF-8`]):a===Z.textarea?i.push([c,textareaWrappingTransformation(n,s.value)]):i.push([c,s.value]);if(a===Z.textarea||a===Z.input&&(o===1||o===2||o===0||o===18||o===20||o===3||o===4||o===5||o===6)){let e=attr(n,`dirname`);e!==null&&e!==``&&i.push([e,`ltr`])}}}n!==null&&n(i)}finally{r[vt]=!1}return i}const od=/* @__PURE__ */ new WeakMap;function isShadowIncludingAncestor(e,t){for(let n=t;n!==null;){let t=n.parent;if(t!==null)n=t;else if(n.flags&32){let e=n.node[R];n=e===null?null:e[z]}else return!1;if(n===e)return!0}return!1}function attrAssociated(e,t){let n=od.get(e)?.get(t)?.deref();if(n!==void 0){let t=n[z],r=treeRoot(t);return r===treeRoot(e)||isShadowIncludingAncestor(r,e)?t:null}let r=contentAttr(e,t);return r===null?null:elementByIdInTree(e,r)}function elementReflection(e,t,n){defineAccessor(e,t,function(){let e=attrAssociated(this[z],n);return e===null?null:e.node},function(e){let t=this[z],r=od.get(t);e==null?(r?.delete(n),removeAttribute(t,n)):(r===void 0&&od.set(t,r=/* @__PURE__ */ new Map),setAttribute(t,n,``),r.set(n,new WeakRef(e)))})}function installPopoverInvoker(e){elementReflection(e,`popoverTargetElement`,`popovertarget`),enumerated(e,`popoverTargetAction=popovertargetaction`,{keywords:[`toggle`,`show`,`hide`],missing:`toggle`,invalid:`toggle`})}const sd=[`toggle-popover`,`show-popover`,`hide-popover`,`show-modal`,`close`,`request-close`];function commandState(e){let t=contentAttr(e,`command`);if(t===null)return``;if(t.startsWith(`--`))return t;let n=t.toLowerCase();return sd.includes(n)?n:``}function installCommandInvoker(e){elementReflection(e,`commandForElement`,`commandfor`),defineAccessor(e,`command`,function(){return commandState(this[z])},function(e){setAttribute(this[z],`command`,String(e))})}function isButton(e){if(e.ns!==`http://www.w3.org/1999/xhtml`)return!1;if(e.tag===Z.button)return!0;if(e.tag!==Z.input)return!1;let t=inputType(e);return t===18||t===19||t===20||t===21}function isResetButton(e){return e.tag===Z.input?inputType(e)===20:e.tag===Z.button&&buttonTypeAttrState(e)===`reset`}function popoverTargetElement(e){if(!isButton(e)||isActuallyDisabled(e)||formOwner(e)!==null&&(isSubmitButton(e)||isResetButton(e)))return null;let t=attrAssociated(e,`popovertarget`);return t===null||t.type!==1||popoverState(t)===0?null:t}function popoverTargetAttributeActivation(e,t){let n=popoverTargetElement(e);if(n===null||t!==null&&(t===n||isShadowIncludingAncestor(n,t))&&isShadowIncludingAncestor(e,n))return;let r=(contentAttr(e,`popovertargetaction`)??``).toLowerCase(),i=isPopoverShowing(n);if(!(r===`show`&&i)&&(r!==`hide`||i)){if(i)hidePopover(n,!0,!0,!1,e);else try{showPopover(n,!1,e)}catch{}}}function targetPopover(e){if(e.ns!==`http://www.w3.org/1999/xhtml`||e.tag!==Z.button)return isButton(e)?popoverTargetElement(e):null;if(isActuallyDisabled(e))return null;let t=attrAssociated(e,`commandfor`);if(t===null)return popoverTargetElement(e);if(formOwner(e)!==null&&(isSubmitButton(e)||buttonTypeAttrState(e)!==`button`))return null;let n=commandState(e);return n!==`toggle-popover`&&n!==`hide-popover`&&n!==`show-popover`||popoverState(t)===0?null:t}function buttonTypeAttrState(e){let t=contentAttr(e,`type`)?.toLowerCase();return t===`submit`||t===`reset`||t===`button`?t:`auto`}var CommandEvent=class extends Event{#e;#t;constructor(e,t){requireArgs$1(arguments.length,1,new.target.name),super(e,t);let n=t?.source??null;this.#e=n,this.#t=t?.command===void 0?``:String(t.command)}get source(){let e=this.#e;if(e===null)return null;let t=this.currentTarget;return t===null?e:retarget(e,t)}get command(){return this.#t}};setToStringTag(CommandEvent,1);function isValidCommand(e,t){return e===``?!1:e.startsWith(`--`)?!0:t.type!==1||t.ns!==`http://www.w3.org/1999/xhtml`?!1:e===`toggle-popover`||e===`show-popover`||e===`hide-popover`?!0:t.tag===Z.dialog?e===`close`||e===`request-close`||e===`show-modal`:!1}let cd=null;function setDialogCommandSteps(e){cd=e}function popoverValid(e,t){return popoverState(e)!==0&&isPopoverShowing(e)===t&&(t||!!(e.flags&1))}function buttonInvokerActivation(e,t=null){if(e.tag!==Z.button){e.tag===Z.input&&popoverTargetAttributeActivation(e,t);return}if(isActuallyDisabled(e)||formOwner(e)!==null&&buttonTypeAttrState(e)===`auto`)return;let n=attrAssociated(e,`commandfor`);if(n===null){popoverTargetAttributeActivation(e,t);return}let r=commandState(e);if(!isValidCommand(r,n))return;let i={cancelable:!0,command:r,source:e.node};fireAnEvent(`command`,n.node,CommandEvent,i)&&n.flags&1&&!r.startsWith(`--`)&&(r===`hide-popover`?popoverValid(n,!0)&&hidePopover(n,!0,!0,!1,e):r===`toggle-popover`?popoverValid(n,!1)?showPopover(n,!1,e):popoverValid(n,!0)&&hidePopover(n,!0,!0,!1,e):r===`show-popover`?popoverValid(n,!1)&&showPopover(n,!1,e):n.tag===Z.dialog&&n.ns===`http://www.w3.org/1999/xhtml`&&cd?.(n,e,r))}const ld=/* @__PURE__ */ new WeakMap;function state$3(e){let t=ld.get(e);return t===void 0&&(t={layer:[],modals:[],openDialogs:[],watchers:[],popoverPointerdownTarget:null,dialogPointerdownTarget:null,hintStackParent:null,showingPopover:!1,hidingPopoverNestingCount:0},ld.set(e,t),setPostDispatchHook(postDispatch)),t}__name(state$3,`state`);function styleChanged(e){e[Gr]++}function addToTopLayer(e){styleChanged(e.doc);let t=state$3(e.doc),n=t.layer.indexOf(e);n!==-1&&t.layer.splice(n,1),t.layer.push(e)}function removeFromTopLayer(e){let t=ld.get(e.doc);if(t===void 0)return;let n=t.layer.indexOf(e);n!==-1&&t.layer.splice(n,1);let r=t.modals.indexOf(e);r!==-1&&t.modals.splice(r,1),(n!==-1||r!==-1)&&styleChanged(e.doc)}function isInTopLayer(e){return ld.get(e.doc)?.layer.includes(e)??!1}const ud=/* @__PURE__ */ new WeakMap;function getPreviouslyFocused(e){return ud.get(e)?.deref()??null}function setPreviouslyFocused(e,t){t===null?ud.delete(e):ud.set(e,new WeakRef(t))}function setModal(e,t){if(!t){let t=ld.get(e.doc),n=t===void 0?-1:t.modals.indexOf(e);n!==-1&&(t.modals.splice(n,1),styleChanged(e.doc));return}let n=state$3(e.doc);n.modals.includes(e)||(n.modals.push(e),styleChanged(e.doc))}function matchesModal(e){return ld.get(e.doc)?.modals.includes(e)??!1}function openDialogsList(e){return state$3(e).openDialogs}function inertByModal(e){let t=ld.get(e.doc);if(t===void 0||t.modals.length===0)return!1;let n=null,r=-1;for(let e=t.layer.length-1;e>=0;e--)if(t.modals.includes(t.layer[e])){n=t.layer[e],r=e;break}if(n===null)return!1;for(let i=e;i!==null;i=flatParent(i))if(i===n||t.layer.indexOf(i)>r)return!1;return!0}function flatParent(e){let t=e.parent;if(t!==null){if(t.flags&512&&t.type===1){let t=assignedSlotForEventPath(e);if(t!==null)return t}return t}if(e.flags&32){let t=e.node[R];return t===null?null:t[z]}return null}function isFlatInclusiveAncestor(e,t){for(let n=t;n!==null;n=flatParent(n))if(n===e)return!0;return!1}function isShadowIncludingInclusiveAncestor$2(e,t){for(let n=t;n!==null;){if(n===e)return!0;if(n.parent!==null)n=n.parent;else if(n.flags&32){let e=n.node[R];n=e===null?null:e[z]}else n=null}return!1}__name(isShadowIncludingInclusiveAncestor$2,`isShadowIncludingInclusiveAncestor`);function isFullyActive(e){return e[Y]!=null}function establishCloseWatcher(e,t,n,r){let i={cancelAction:t,closeAction:n,getEnabledState:r,isRunningCancelAction:!1,doc:e};return state$3(e).watchers.push(i),i}function destroyCloseWatcher(e){let t=ld.get(e.doc)?.watchers,n=t===void 0?-1:t.indexOf(e);n!==-1&&t.splice(n,1)}function isActive(e){return ld.get(e.doc)?.watchers.includes(e)??!1}function closeWatcherClose(e){isActive(e)&&e.getEnabledState()&&isFullyActive(e.doc)&&(destroyCloseWatcher(e),e.closeAction())}function requestCloseWatcher(e,t){if(!isActive(e)||!e.getEnabledState()||e.isRunningCancelAction||!isFullyActive(e.doc))return!0;e.isRunningCancelAction=!0;let n;try{n=e.cancelAction(!0)}finally{e.isRunningCancelAction=!1}return n?(closeWatcherClose(e),!0):!1}function processCloseWatchers(e){let t=ld.get(e);return t===void 0||t.watchers.length===0?!1:(requestCloseWatcher(t.watchers[t.watchers.length-1],!0),!0)}function popoverState(e){if(e.ns!==`http://www.w3.org/1999/xhtml`||e.type!==1)return 0;let t=contentAttr(e,`popover`);return t===null?0:popoverKeyword(t)}function popoverKeyword(e){switch(e.toLowerCase()){case``:case`auto`:return 1;case`hint`:return 3}return 2}const dd=/* @__PURE__ */ new WeakMap;function record(e){let t=dd.get(e);return t===void 0&&(t={showing:!1,hiding:!1,openedMode:0,toggleTracker:null,closeWatcher:null},dd.set(e,t)),t}function isPopoverShowing(e){return dd.get(e)?.showing??!1}function matchesPopoverOpen(e){return(dd.get(e)?.showing??!1)&&popoverState(e)!==0}function showingPopoverList(e,t){let n=[],r=ld.get(e);if(r===void 0)return n;for(let e of r.layer){let r=dd.get(e);r!==void 0&&r.showing&&r.openedMode===t&&n.push(e)}return n}function checkPopoverValidity(e,t,n){if(popoverState(e)===0&&e!==gd)throw new DOMException(`Not supported on elements that do not have a valid value for the 'popover' attribute.`,`NotSupportedError`);if(t!==isPopoverShowing(e))return!1;if(!t&&!(e.flags&1)||!t&&!isFullyActive(e.doc)||n!==null&&e.doc!==n||e.tag===Z.dialog&&matchesModal(e))throw new DOMException(`Invalid on popover elements which aren't connected, or are modal dialogs.`,`InvalidStateError`);return!0}function validity(e,t,n,r){try{return checkPopoverValidity(e,t,n)}catch(e){if(r)throw e;return!1}}function queuePopoverToggle(e,t,n,r){let i=record(e),a=queueToggleTask(e,i.toggleTracker,t,t=>{fireToggleEvent(e.node,`toggle`,t,n,!1,r===null?null:r.node),i.toggleTracker===a&&(i.toggleTracker=null)});i.toggleTracker=a}function topmostPopoverAncestor(e,t,n){let r=e.doc,i=showingPopoverList(r,1).concat(showingPopoverList(r,3)),a=lastIndexOfAncestor(i,e),o=t===null?-1:lastIndexOfAncestor(i,t,!0),s=Math.max(a,o);return s===-1?null:i[s]}function lastIndexOfAncestor(e,t,n=!1){for(let r=e.length-1;r>=0;r--){let i=e[r];if(i===t){if(n)return r}else if(isFlatInclusiveAncestor(i,t))return r}return-1}function lastShowingPopover(e,t){let n=ld.get(e)?.layer;if(n===void 0)return null;for(let e=n.length-1;e>=0;e--){let r=n[e],i=dd.get(r);if(i?.showing&&i.openedMode===t)return r}return null}function topmostAutoOrHintPopover(e){return lastShowingPopover(e,3)??lastShowingPopover(e,1)}function hidePopoverStackUntil(e,t,n,r,i){let a=lastShowingPopover(e,n);if(a===null||a===t)return;let o=showingPopoverList(e,n),s=t===null?-1:o.indexOf(t),c=s===-1?0:s+1,l=o.slice(0,c);for(let e=o.length-1;e>=c;e--)hidePopover(o[e],r,i,!1,null);let u=showingPopoverList(e,n);for(let e=u.length-1;e>=0;e--){let t=u[e];l.includes(t)||hidePopover(t,r,!1,!1,null)}}function hidePopoversUntil(e,t,n,r){let i=t!==null&&dd.get(t)?.openedMode===3&&showingPopoverList(e,3).includes(t);hidePopoverStackUntil(e,t,3,n,r),hidePopoverStackUntil(e,i?ld.get(e)?.hintStackParent??null:t,1,n,r)}function showPopover(e,t,n){let r=e.doc,i=state$3(r);if(i.showingPopover||i.hidingPopoverNestingCount!==0){if(t)throw new DOMException(`A popover is already being shown or hidden.`,`InvalidStateError`);return}if(!validity(e,!1,null,t))return;i.showingPopover=!0;let cleanupShowingSteps=()=>{i.showingPopover=!1};if(!fireToggleEvent(e.node,`beforetoggle`,`closed`,`open`,!0,n===null?null:n.node)){cleanupShowingSteps();return}try{if(!checkPopoverValidity(e,!1,r)){cleanupShowingSteps();return}}catch(e){if(cleanupShowingSteps(),t)throw e;return}let a=!1,o=popoverState(e),s=o,c=null,l=record(e);if(o===1||o===3){if(c=topmostPopoverAncestor(e,n,!0),c!==null&&dd.get(c)?.openedMode===3&&s===1&&(s=3),hidePopoverStackUntil(r,c,3,a,!0),s===1&&hidePopoverStackUntil(r,c,1,a,!0),o!==popoverState(e)){if(cleanupShowingSteps(),t)throw new DOMException(`The popover attribute changed while showing the popover.`,`InvalidStateError`);return}try{if(!checkPopoverValidity(e,!1,r)){cleanupShowingSteps();return}}catch(e){if(cleanupShowingSteps(),t)throw e;return}topmostAutoOrHintPopover(r)===null&&(a=!0),l.openedMode=s===1?1:3,l.closeWatcher=establishCloseWatcher(r,()=>!0,()=>hidePopover(e,!0,!0,!1,null),()=>!0)}setPreviouslyFocused(e,null);let u=r[L];addToTopLayer(e),s===3&&c!==null&&dd.get(c)?.openedMode===1&&(i.hintStackParent=c),l.showing=!0,popoverFocusingSteps(e),a&&popoverState(e)!==0&&setPreviouslyFocused(e,u),cleanupShowingSteps(),queuePopoverToggle(e,`closed`,`open`,n)}function hidePopover(e,t,n,r,i){if(!validity(e,!0,null,r))return;let a=e.doc,o=state$3(a),s=record(e),c=s.hiding;s.hiding=!0,c&&(n=!1),o.hidingPopoverNestingCount++;let cleanupSteps=()=>{c||(s.hiding=!1),o.hidingPopoverNestingCount--};try{let r=showingPopoverList(a,1).includes(e),c=showingPopoverList(a,3).includes(e);if((s.openedMode===1||s.openedMode===3)&&(c&&hidePopoverStackUntil(a,e,3,t,n),e===o.hintStackParent&&hidePopoverStackUntil(a,null,3,t,n),r&&hidePopoverStackUntil(a,e,1,t,n),!checkPopoverValidity(e,!0,a))||n&&(fireToggleEvent(e.node,`beforetoggle`,`open`,`closed`,!1,i===null?null:i.node),!checkPopoverValidity(e,!0,a)))return;removeFromTopLayer(e),s.openedMode=0,s.showing=!1,(e===o.hintStackParent||lastShowingPopover(a,3)===null)&&(o.hintStackParent=null),n&&queuePopoverToggle(e,`open`,`closed`,i);let l=getPreviouslyFocused(e);if(l!==null){setPreviouslyFocused(e,null);let n=a[L];t&&n!==null&&isShadowIncludingInclusiveAncestor$2(e,n)&&fd?.(l)}s.closeWatcher!==null&&(destroyCloseWatcher(s.closeWatcher),s.closeWatcher=null)}catch(e){if(r)throw e}finally{cleanupSteps()}}function popoverFocusingSteps(e){if(e.tag===Z.dialog&&e.ns===`http://www.w3.org/1999/xhtml`){md?.(e);return}let t=contentAttr(e,`autofocus`)===null?pd?.(e)??null:e;t!==null&&fd?.(t)}let fd=null,pd=null,md=null,hd=null;function setTopLayerFocusHooks(e,t){fd=e,pd=t}function setTopLayerDialogHooks(e,t){md=e,hd=t}function topLayerRemovingSteps(e){isPopoverShowing(e)&&popoverState(e)!==0?hidePopover(e,!1,!1,!1,null):isPopoverShowing(e)&&forceHidden(e),e.tag!==Z.dialog&&removeFromTopLayer(e)}function forceHidden(e){let t=record(e);t.showing=!1,t.openedMode=0,t.closeWatcher!==null&&(destroyCloseWatcher(t.closeWatcher),t.closeWatcher=null),removeFromTopLayer(e);let n=ld.get(e.doc);n!==void 0&&(e===n.hintStackParent||lastShowingPopover(e.doc,3)===null)&&(n.hintStackParent=null)}let gd=null;function popoverAttributeChanged(e,t,n){if(!isPopoverShowing(e))return;let r=t===null?0:popoverKeyword(t),i=n===null?0:popoverKeyword(n);if(r===i)return;let a=gd;i===0&&(gd=e);try{hidePopover(e,!0,!0,!1,null)}finally{gd=a}isPopoverShowing(e)&&popoverState(e)===0&&forceHidden(e)}function nearestInclusiveOpenPopover(e){for(let t=e;t!==null;t=flatParent(t)){let e=dd.get(t);if(e!==void 0&&e.showing&&(e.openedMode===1||e.openedMode===3))return t}return null}function nearestInclusiveTargetPopover(e){for(let t=e;t!==null;t=flatParent(t)){if(t.type!==1)continue;let e=targetPopover(t);if(e!==null&&isPopoverShowing(e)){let t=popoverState(e);if(t===1||t===3)return e}}return null}function popoverStackPosition(e){if(e===null)return 0;let t=showingPopoverList(e.doc,3),n=showingPopoverList(e.doc,1),r=t.indexOf(e);if(r!==-1)return r+n.length+1;let i=n.indexOf(e);return i===-1?0:i+1}function topmostClickedPopover(e){let t=nearestInclusiveOpenPopover(e),n=nearestInclusiveTargetPopover(e);return t===null||t===n?n:n===null?isInTopLayer(t)?t:null:popoverStackPosition(t)>popoverStackPosition(n)?t:n}function lightDismissOpenPopovers(e,t,n,r){if(topmostAutoOrHintPopover(e)===null)return;let i=topmostClickedPopover(n);matchesLightDismissTarget(t,`popoverPointerdownTarget`,r,i)&&hidePopoversUntil(e,i,!1,!0)}function postDispatch(e,t){let n=e.type;if(n!==`pointerdown`&&n!==`pointerup`&&n!==`keydown`)return;let r=t?.[z];if(r===void 0)return;let i=r.doc,a=ld.get(i);if(a!==void 0){if(n===`keydown`){if(e.key!==`Escape`||e.defaultPrevented||!isFullyActive(i))return;processCloseWatchers(i)}else r.flags&1&&(a.layer.length!==0&&lightDismissOpenPopovers(i,a,r,n),a.openDialogs.length!==0&&hd?.(a,r,n))}}function matchesLightDismissTarget(e,t,n,r){if(n===`pointerdown`)return e[t]=r===null?null:new WeakRef(r),!1;let i=e[t];return e[t]=null,i===null?r===null:i.deref()===r}let _d=null;function setNestedWindowFactory(e){_d=e}const vd=/* @__PURE__ */ new WeakMap;function frameContentWindow(e){return vd.get(e)??null}function frameConnected(e){if(_d===null||vd.has(e))return;let t=e[z].doc[Y];if(t===null||t[pt])return;let n=e[z],r=_d(e,t,attr(n,`src`),attr(n,`srcdoc`));vd.set(e,r),t._task(()=>{vd.get(e)===r&&e.dispatchEvent(new Event(`load`))},0)}function frameDisconnected(e){let t=vd.get(e);t!==void 0&&(vd.delete(e),t.close())}function isCharacterData(e){let t=e.type;return t===3||t===4||t===8||t===7}function isText(e){return e.type===3||e.type===4}function nodeLength(e){switch(e.type){case 10:case 2:return 0;case 3:case 4:case 8:case 7:return e.data.length;default:return e.childCount}}function toNodeImpl(e,t,n=`Range`){if(typeof e!=`object`||!e||!(z in e))throw TypeError(`Failed to execute '${t}' on '${n}': parameter 1 is not of type 'Node'.`);return e[z]}function compareBoundaryPoints(e,t,n,r){if(e===n)return t===r?0:t<r?-1:1;if(e.parent===n.parent)return siblingPrecedes(e,n)?-1:1;let i=0;for(let t=e;t.parent!==null;t=t.parent){if(t.parent===n)return childBeforeOffset(t,r)?-1:1;i++}for(let r=n;r.parent!==null;r=r.parent){if(r.parent===e)return childBeforeOffset(r,t)?1:-1;i--}for(;i>0;i--)e=e.parent;for(;i<0;i++)n=n.parent;for(;e.parent!==n.parent;)e=e.parent,n=n.parent;return siblingPrecedes(e,n)?-1:1}function childBeforeOffset(e,t){let n=e.parent.childCount-t,r=Math.min(t,n),i=e,a=e;for(let e=0;e<r;e++){if(i.prev===null)return!0;if(a.next===null)return!1;i=i.prev,a=a.next}return t>n}function childOfAncestor(e,t){let n=e;for(;n.parent!==t;)n=n.parent;return n}function commonAncestor(e,t){let n=e,r=t;for(;n!==r;){let i=n.parent,a=r.parent;if(i===t)return t;if(a===e)return e;if(i===null||a===null)break;n=i,r=a}if(n===r)return n;for(;n.parent!==null;)n=n.parent,e=e.parent;for(;r.parent!==null;)r=r.parent,t=t.parent;for(;e!==t;)e=e.parent,t=t.parent;return e}var AbstractRange=class{[W];[K];[P];[I];[bn];constructor(e,t,n,r){this[W]=e,this[K]=t,this[P]=n,this[I]=r,this[bn]=null}get startContainer(){return this[W].node}get startOffset(){return this[K]}get endContainer(){return this[P].node}get endOffset(){return this[I]}get collapsed(){return this[W]===this[P]&&this[K]===this[I]}},StaticRange=class extends AbstractRange{constructor(e){if(typeof e!=`object`||!e)throw TypeError(`Failed to construct 'StaticRange': 1 argument required.`);for(let t of[`startContainer`,`startOffset`,`endContainer`,`endOffset`])if(e[t]===void 0)throw TypeError(`Failed to construct 'StaticRange': required member ${t} is undefined.`);let t=toNodeImpl(e.startContainer,`constructor`,`StaticRange`),n=toNodeImpl(e.endContainer,`constructor`,`StaticRange`);if(t.type===10||t.type===2||n.type===10||n.type===2)throw new DOMException(`Failed to construct 'StaticRange': Invalid boundary container.`,`InvalidNodeTypeError`);super(t,Number(e.startOffset)>>>0,n,Number(e.endOffset)>>>0)}};function hasSameRoot(e,t){let n=e[W];return t===n||t===e[P]||t.parent!==null&&t.parent===n.parent||t.doc===n.doc&&treeRoot(t)===treeRoot(n)}var yd=class Range extends AbstractRange{static START_TO_START=0;static START_TO_END=1;static END_TO_END=2;static END_TO_START=3;constructor(e){let t=(e??currentDocument())[z];super(t,0,t,0),registerLiveRange(this)}static _create(e,t,n,r,i){let a=new Range(e);return a[W]=t,a[K]=n,a[P]=r,a[I]=i,refileRange(a),a}_treeRoot(){return treeRoot(this[W])}get commonAncestorContainer(){return commonAncestor(this[W],this[P]).node}_setStart(e,t){if(e.type===10)throw new DOMException(`DocumentType Node can't be used as boundary point.`,`InvalidNodeTypeError`);if(t>nodeLength(e))throw new DOMException(`There is no child at offset ${t}.`,`IndexSizeError`);(!hasSameRoot(this,e)||compareBoundaryPoints(e,t,this[P],this[I])>0)&&(this[P]=e,this[I]=t),this[W]=e,this[K]=t,refileRange(this)}_setEnd(e,t){if(e.type===10)throw new DOMException(`DocumentType Node can't be used as boundary point.`,`InvalidNodeTypeError`);if(t>nodeLength(e))throw new DOMException(`There is no child at offset ${t}.`,`IndexSizeError`);(!hasSameRoot(this,e)||compareBoundaryPoints(e,t,this[W],this[K])<0)&&(this[W]=e,this[K]=t),this[P]=e,this[I]=t,refileRange(this)}setStart(e,t){this._setStart(toNodeImpl(e,`setStart`),Number(t)>>>0)}setEnd(e,t){this._setEnd(toNodeImpl(e,`setEnd`),Number(t)>>>0)}setStartBefore(e){let t=toNodeImpl(e,`setStartBefore`),n=t.parent;if(n===null)throw new DOMException(`The given Node has no parent.`,`InvalidNodeTypeError`);this._setStart(n,indexOf(t))}setStartAfter(e){let t=toNodeImpl(e,`setStartAfter`),n=t.parent;if(n===null)throw new DOMException(`The given Node has no parent.`,`InvalidNodeTypeError`);this._setStart(n,indexOf(t)+1)}setEndBefore(e){let t=toNodeImpl(e,`setEndBefore`),n=t.parent;if(n===null)throw new DOMException(`The given Node has no parent.`,`InvalidNodeTypeError`);this._setEnd(n,indexOf(t))}setEndAfter(e){let t=toNodeImpl(e,`setEndAfter`),n=t.parent;if(n===null)throw new DOMException(`The given Node has no parent.`,`InvalidNodeTypeError`);this._setEnd(n,indexOf(t)+1)}collapse(e=!1){e?(this[P]=this[W],this[I]=this[K]):(this[W]=this[P],this[K]=this[I])}_select(e){let t=e.parent;if(t===null)throw new DOMException(`The given Node has no parent.`,`InvalidNodeTypeError`);let n=indexOf(e);this[W]=t,this[K]=n,this[P]=t,this[I]=n+1,refileRange(this)}selectNode(e){this._select(toNodeImpl(e,`selectNode`))}_selectContents(e){if(e.type===10)throw new DOMException(`DocumentType Node can't be used as boundary point.`,`InvalidNodeTypeError`);this[W]=e,this[K]=0,this[P]=e,this[I]=nodeLength(e),refileRange(this)}selectNodeContents(e){this._selectContents(toNodeImpl(e,`selectNodeContents`))}compareBoundaryPoints(e,t){let n=Number(e)>>>0&65535;if(n>3)throw new DOMException(`The comparison method provided must be one of 'START_TO_START', 'START_TO_END', 'END_TO_END', or 'END_TO_START'.`,`NotSupportedError`);if(!(t instanceof Range))throw TypeError(`Failed to execute 'compareBoundaryPoints' on 'Range': parameter 2 is not of type 'Range'.`);if(!hasSameRoot(this,t[W]))throw new DOMException(`The two Ranges are not in the same tree.`,`WrongDocumentError`);switch(n){case 0:return compareBoundaryPoints(this[W],this[K],t[W],t[K]);case 1:return compareBoundaryPoints(this[P],this[I],t[W],t[K]);case 2:return compareBoundaryPoints(this[P],this[I],t[P],t[I]);default:return compareBoundaryPoints(this[W],this[K],t[P],t[I])}}deleteContents(){if(this.collapsed)return;let e=this[W],t=this[K],n=this[P],r=this[I];if(e===n&&isCharacterData(e)){replaceData(e,t,r-t,``);return}let i=commonAncestor(e,n),a=e===n?snapshotChildren(e,t,r):containedNodes(this,i),o=i===e?t:indexOf(childOfAncestor(e,i))+1;isCharacterData(e)&&replaceData(e,t,e.data.length-t,``);for(let e=0;e<a.length;e++){let t=a[e];t.parent!==null&&remove(t,!1)}isCharacterData(n)&&replaceData(n,0,r,``),this[W]=this[P]=i,this[K]=this[I]=o,markBoundary(i)}extractContents(){return extract(this,this[W],this[K],this[P],this[I]).node}cloneContents(){return cloneContents(this[W],this[K],this[P],this[I]).node}insertNode(e){insertIntoRange(this,toNodeImpl(e,`insertNode`))}surroundContents(e){let t=toNodeImpl(e,`surroundContents`),n=commonAncestor(this[W],this[P]);for(let e=this[W];e!==n;e=e.parent)if(!isText(e))throw new DOMException(`The Range has partially selected a non-Text node.`,`InvalidStateError`);for(let e=this[P];e!==n;e=e.parent)if(!isText(e))throw new DOMException(`The Range has partially selected a non-Text node.`,`InvalidStateError`);let r=t.type;if(r===9||r===10||r===11)throw new DOMException(`The node provided is a Document, DocumentType or DocumentFragment.`,`InvalidNodeTypeError`);let i=extract(this,this[W],this[K],this[P],this[I]);t.first!==null&&replaceAll(null,t),insertIntoRange(this,t),append(i,t),this._select(t)}cloneRange(){return Range._create(this[W].doc,this[W],this[K],this[P],this[I])}detach(){}isPointInRange(e,t){let n=toNodeImpl(e,`isPointInRange`),r=Number(t)>>>0;if(!hasSameRoot(this,n))return!1;if(n.type===10)throw new DOMException(`DocumentType Node can't be used as boundary point.`,`InvalidNodeTypeError`);if(r>nodeLength(n))throw new DOMException(`There is no child at offset ${r}.`,`IndexSizeError`);return compareBoundaryPoints(n,r,this[W],this[K])>=0&&compareBoundaryPoints(n,r,this[P],this[I])<=0}comparePoint(e,t){let n=toNodeImpl(e,`comparePoint`),r=Number(t)>>>0;if(!hasSameRoot(this,n))throw new DOMException(`The node provided and the Range are not in the same tree.`,`WrongDocumentError`);if(n.type===10)throw new DOMException(`DocumentType Node can't be used as boundary point.`,`InvalidNodeTypeError`);if(r>nodeLength(n))throw new DOMException(`There is no child at offset ${r}.`,`IndexSizeError`);return compareBoundaryPoints(n,r,this[W],this[K])<0?-1:+(compareBoundaryPoints(n,r,this[P],this[I])>0)}intersectsNode(e){let t=toNodeImpl(e,`intersectsNode`);return hasSameRoot(this,t)?t.parent===null||compareBoundaryPoints(t,0,this[P],this[I])<=0&&compareBoundaryPoints(t,nodeLength(t),this[W],this[K])>=0:!1}toString(){let e=this[W],t=this[P],n=``;if(e===t){let t=this[K],r=this[I];if(isText(e))return e.data.slice(t,r);if(t===r||isCharacterData(e))return``;let i=r-t;for(let r=childAt(e,t);r!==null&&i>0;r=r.next,i--)for(let e=r;e!==null;e=nextInTree(e,r))isText(e)&&(n+=e.data);return n}isText(e)&&(n+=e.data.slice(this[K]));let r=isCharacterData(t)?t:afterBoundary(t,this[I]);for(let t=afterBoundary(e,this[K]);t!==null&&t!==r;t=nextInTree(t,null))isText(t)&&(n+=t.data);return isText(t)&&(n+=t.data.slice(0,this[I])),n}createContextualFragment(e){if(arguments.length===0)throw TypeError(`Failed to execute 'createContextualFragment' on 'Range': 1 argument required, but only 0 present.`);let t=this[W],n;switch(t.type){case 9:case 11:n=null;break;case 1:n=t;break;default:{let e=t.parent;n=e!==null&&e.type===1?e:null}}return(n===null||n.name===`html`&&n.ns===`http://www.w3.org/1999/xhtml`&&n.flags&2)&&(n=t.doc.createElement(`body`)[z]),parseFragment(String(e),n).node}getClientRects(){return new DOMRectList}getBoundingClientRect(){return new us}};for(let[e,t]of[[`START_TO_START`,0],[`START_TO_END`,1],[`END_TO_END`,2],[`END_TO_START`,3]])Object.defineProperty(yd.prototype,e,{value:t,enumerable:!0});Object.defineProperty(AbstractRange.prototype,Symbol.toStringTag,{value:`AbstractRange`,configurable:!0}),Object.defineProperty(yd.prototype,Symbol.toStringTag,{value:`Range`,configurable:!0}),Object.defineProperty(StaticRange.prototype,Symbol.toStringTag,{value:`StaticRange`,configurable:!0});function afterBoundary(e,t,n=null){if(!isCharacterData(e)){let n=childAt(e,t);if(n!==null)return n}return nextSkippingChildren(e,n)}function containedNodes(e,t){let n=[],r=e[P],i=r===t?childAt(r,e[I]):childOfAncestor(r,t),a=afterBoundary(e[W],e[K],t);for(;a!==null&&a!==i;)n.push(a),a=nextSkippingChildren(a,t);if(r===t)return n;let o=n.length,s=isCharacterData(r)?null:childAt(r,e[I]-1);for(let e=r;;e=e.parent){for(;s!==null;s=s.prev)n.push(s);if(e===i)break;s=e.prev}for(let e=o,t=n.length-1;e<t;e++,t--){let r=n[e];n[e]=n[t],n[t]=r}return n}function rangeContents(e,t,n,r){if(e===n&&e.type!==9&&t<r&&r<e.childCount)return{first:null,last:null,contained:snapshotChildren(e,t,r)};let i=commonAncestor(e,n),a=e===i?null:childOfAncestor(e,i),o=n===i?null:childOfAncestor(n,i),s=[],c=a===null?childAt(i,t):a.next,l=o===null?childAt(i,r):o;for(;c!==null&&c!==l;c=c.next){if(c.type===10)throw new DOMException(`A DocumentType node cannot be extracted.`,`HierarchyRequestError`);s.push(c)}return{first:a,last:o,contained:s}}function cloneWithData(e,t){let n=cloneNode(e,e.doc,!1);return n.data=t,n}function extract(e,t,n,r,i){let a=t.doc.createDocumentFragment()[z];if(t===r&&n===i)return a;if(t===r&&isCharacterData(t))return append(cloneWithData(t,t.data.slice(n,i)),a),replaceData(t,n,i-n,``),a;let{first:o,last:s,contained:c}=rangeContents(t,n,r,i),l=o===null?t:o.parent,u=o===null||e===null?n:indexOf(o)+1;if(o!==null){if(isCharacterData(o))append(cloneWithData(t,t.data.slice(n)),a),replaceData(t,n,t.data.length-n,``);else{let e=cloneNode(o,o.doc,!1);append(e,a),append(extract(null,t,n,o,nodeLength(o)),e)}}for(let e=0;e<c.length;e++)append(c[e],a);if(s!==null){if(isCharacterData(s))append(cloneWithData(r,r.data.slice(0,i)),a),replaceData(r,0,i,``);else{let e=cloneNode(s,s.doc,!1);append(e,a),append(extract(null,s,0,r,i),e)}}return e!==null&&(e[W]=e[P]=l,e[K]=e[I]=u,markBoundary(l)),a}function cloneContents(e,t,n,r){let i=e.doc.createDocumentFragment()[z];if(e===n&&t===r)return i;if(e===n&&isCharacterData(e))return append(cloneWithData(e,e.data.slice(t,r)),i),i;let{first:a,last:o,contained:s}=rangeContents(e,t,n,r);if(a!==null){if(isCharacterData(a))append(cloneWithData(e,e.data.slice(t)),i);else{let n=cloneNode(a,a.doc,!1);append(n,i),append(cloneContents(e,t,a,nodeLength(a)),n)}}for(let e=0;e<s.length;e++)append(cloneNode(s[e],s[e].doc,!0),i);if(o!==null){if(isCharacterData(o))append(cloneWithData(n,n.data.slice(0,r)),i);else{let e=cloneNode(o,o.doc,!1);append(e,i),append(cloneContents(o,0,n,r),e)}}return i}function insertIntoRange(e,t){let n=e[W],r=e[K];if(n.type===7||n.type===8||isText(n)&&n.parent===null||n===t)throw new DOMException(`The Range's start node cannot contain the inserted node.`,`HierarchyRequestError`);let i=isText(n)?n:childAt(n,r),a=i===null?n:i.parent;ensurePreInsertionValidity(t,a,i),isText(n)&&(i=splitText(n,r)),t===i&&(i=i.next),t.parent!==null&&remove(t,!1);let o=i===null?nodeLength(a):indexOf(i);o+=t.type===11?nodeLength(t):1,preInsert(t,a,i),e.collapsed&&(e[P]=a,e[I]=o,markBoundary(a))}const bd=Object.freeze({FILTER_ACCEPT:1,FILTER_REJECT:2,FILTER_SKIP:3,SHOW_ALL:4294967295,SHOW_ELEMENT:1,SHOW_ATTRIBUTE:2,SHOW_TEXT:4,SHOW_CDATA_SECTION:8,SHOW_ENTITY_REFERENCE:16,SHOW_ENTITY:32,SHOW_PROCESSING_INSTRUCTION:64,SHOW_COMMENT:128,SHOW_DOCUMENT:256,SHOW_DOCUMENT_TYPE:512,SHOW_DOCUMENT_FRAGMENT:1024,SHOW_NOTATION:2048});function rootImpl(e,t){if(typeof e!=`object`||!e||!(z in e))throw TypeError(`Failed to execute 'create${t}' on 'Document': parameter 1 is not of type 'Node'.`);return e[z]}var Traverser=class{[xr];[fi];[Qt];[Ge];constructor(e,t,n){this[xr]=e,this[fi]=Number(t)>>>0,this[Qt]=n===void 0?null:n,this[Ge]=!1}get root(){return this[xr].node}get whatToShow(){return this[fi]}get filter(){return this[Qt]}_filterNode(e){if(this[Ge])throw new DOMException(`Recursive node filtering is not allowed.`,`InvalidStateError`);if(!(this[fi]&1<<e.type-1))return 3;let t=this[Qt];if(t===null)return 1;this[Ge]=!0;let n;try{if(typeof t==`function`)n=t.call(void 0,e.node);else{let r=t.acceptNode;if(typeof r!=`function`)throw TypeError(`NodeFilter.acceptNode is not a function.`);n=r.call(t,e.node)}}finally{this[Ge]=!1}return Number(n)>>>0&65535}},NodeIterator=class extends Traverser{[yr];[or];[kn];constructor(e,t=4294967295,n=null){let r=rootImpl(e,`NodeIterator`);super(r,t,n),this[yr]=r,this[or]=!0,this[kn]=null,registerNodeIterator(this)}get referenceNode(){return this[yr].node}get pointerBeforeReferenceNode(){return this[or]}#e(e){let t=this[xr],n={[xr]:t,[yr]:this[yr],[or]:this[or],[kn]:null};this[kn]=n;try{for(;;){let r=n[yr],i=n[or];if(e){if(i)i=!1;else{let e=nextInTree(r,t);if(e===null)return null;r=e}}else if(i){let e=previousInTree(r,t);if(e===null)return null;r=e}else i=!0;if(n[yr]=r,n[or]=i,this._filterNode(r)===1)return this[yr]=n[yr],this[or]=n[or],r.node}}finally{this[kn]=null}}nextNode(){return this.#e(!0)}previousNode(){return this.#e(!1)}detach(){}},TreeWalker=class extends Traverser{[Dt];constructor(e,t=4294967295,n=null){let r=rootImpl(e,`TreeWalker`);super(r,t,n),this[Dt]=r}get currentNode(){return this[Dt].node}set currentNode(e){if(typeof e!=`object`||!e||!(z in e))throw TypeError(`Failed to set the 'currentNode' property on 'TreeWalker': The provided value is not of type 'Node'.`);this[Dt]=e[z]}parentNode(){let e=this[Dt];for(;e!==null&&e!==this[xr];)if(e=e.parent,e!==null&&this._filterNode(e)===1)return this[Dt]=e,e.node;return null}#e(e){let t=e?this[Dt].first:this[Dt].last;for(;t!==null;){let n=this._filterNode(t);if(n===1)return this[Dt]=t,t.node;if(n===3){let n=e?t.first:t.last;if(n!==null){t=n;continue}}for(;t!==null;){let n=e?t.next:t.prev;if(n!==null){t=n;break}let r=t.parent;if(r===null||r===this[xr]||r===this[Dt])return null;t=r}}return null}firstChild(){return this.#e(!0)}lastChild(){return this.#e(!1)}#t(e){let t=this[Dt];if(t===this[xr])return null;for(;;){let n=e?t.next:t.prev;for(;n!==null;){t=n;let r=this._filterNode(t);if(r===1)return this[Dt]=t,t.node;n=e?t.first:t.last,(r===2||n===null)&&(n=e?t.next:t.prev)}let r=t.parent;if(r===null||r===this[xr]||(t=r,this._filterNode(t)===1))return null}}nextSibling(){return this.#t(!0)}previousSibling(){return this.#t(!1)}previousNode(){let e=this[Dt];for(;e!==this[xr];){let t=e.prev;for(;t!==null;){e=t;let n=this._filterNode(e);for(;n!==2&&e.first!==null;)e=e.last,n=this._filterNode(e);if(n===1)return this[Dt]=e,e.node;t=e.prev}let n=e.parent;if(e===this[xr]||n===null)return null;if(e=n,this._filterNode(e)===1)return this[Dt]=e,e.node}return null}nextNode(){let e=this[Dt],t=1;for(;;){for(;t!==2&&e.first!==null;)if(e=e.first,t=this._filterNode(e),t===1)return this[Dt]=e,e.node;let n=null,r=e;for(;r!==null;){if(r===this[xr])return null;if(n=r.next,n!==null){e=n;break}r=r.parent}if(r===null)return null;if(t=this._filterNode(e),t===1)return this[Dt]=e,e.node}}};Object.defineProperty(NodeIterator.prototype,Symbol.toStringTag,{value:`NodeIterator`,configurable:!0}),Object.defineProperty(TreeWalker.prototype,Symbol.toStringTag,{value:`TreeWalker`,configurable:!0});function toImpl(e,t){if(typeof e!=`object`||!e||!(z in e))throw TypeError(`Failed to execute '${t}' on 'Selection': parameter 1 is not of type 'Node'.`);return e[z]}function arity(e,t,n){if(e<t)throw TypeError(`Failed to execute '${n}' on 'Selection': ${t} argument${t===1?``:`s`} required, but only ${e} present.`)}function checkBoundary(e,t){if(e.type===10)throw new DOMException(`DocumentType Node can't be used as boundary point.`,`InvalidNodeTypeError`);if(t>nodeLength(e))throw new DOMException(`There is no child at offset ${t}.`,`IndexSizeError`)}var Selection=class{#e;#t;#n;#r;#i;constructor(e){this.#e=e,this.#t=null,this.#n=!1,this.#r=0,this.#i=!1}#a(e){let t=treeRoot(e);for(;t.flags&32;){let e=t.node[R];if(e===null)return!1;t=treeRoot(e[z])}return t===this.#e[z]}#o(e,t,n,r,i){this.#s(yd._create(this.#e,e,t,n,r),i,!0)}#s(e,t,n=!1){let r=this.#t;r!==null&&r!==e&&this.#n&&retireLiveRange(r),this.#t=e,this.#n=n,this.#r=t,r!==e&&(r===null||e===null||r[W]!==e[W]||r[K]!==e[K]||r[P]!==e[P]||r[I]!==e[I])&&this.#c()}#c(){this.#i||(this.#i=!0,queueUserAgentTask(()=>{this.#i=!1;let e=this.#e.defaultView;e!==null&&e.closed!==!0&&fireAnEvent(`selectionchange`,this.#e)}))}get anchorNode(){let e=this.#t;return e===null?null:(this.#r===2?e[P]:e[W]).node}get anchorOffset(){let e=this.#t;return e===null?0:this.#r===2?e[I]:e[K]}get focusNode(){let e=this.#t;return e===null?null:(this.#r===2?e[W]:e[P]).node}get focusOffset(){let e=this.#t;return e===null?0:this.#r===2?e[K]:e[I]}get isCollapsed(){let e=this.#t;return e===null||e.collapsed}get rangeCount(){return this.#t===null?0:1}get type(){let e=this.#t;return e===null?`None`:e.collapsed?`Caret`:`Range`}get direction(){let e=this.#t;return e===null||e.collapsed||this.#r===0?`none`:this.#r===2?`backward`:`forward`}getRangeAt(e){let t=this.#t;if(Number(e)!==0||t===null)throw new DOMException(`The index provided (${e}) is greater than or equal to the maximum bound (${this.rangeCount}).`,`IndexSizeError`);return this.#n=!1,t}addRange(e){if(arity(arguments.length,1,`addRange`),!(e instanceof yd))throw TypeError(`Failed to execute 'addRange' on 'Selection': parameter 1 is not of type 'Range'.`);e._treeRoot()===this.#e[z]&&this.#t===null&&this.#s(e,1)}removeRange(e){if(arity(arguments.length,1,`removeRange`),!(e instanceof yd))throw TypeError(`Failed to execute 'removeRange' on 'Selection': parameter 1 is not of type 'Range'.`);if(e!==this.#t)throw new DOMException(`The given range isn't in document.`,`NotFoundError`);this.#s(null,0)}removeAllRanges(){this.#s(null,0)}empty(){this.removeAllRanges()}collapse(e,t=0){if(arity(arguments.length,1,`collapse`),e===null){this.removeAllRanges();return}let n=toImpl(e,`collapse`),r=Number(t)>>>0;checkBoundary(n,r),this.#a(n)&&this.#o(n,r,n,r,1)}setPosition(e,t=0){arity(arguments.length,1,`setPosition`),this.collapse(e,t)}collapseToStart(){let e=this.#t;if(e===null)throw new DOMException(`There is no selection to collapse.`,`InvalidStateError`);this.#o(e[W],e[K],e[W],e[K],1)}collapseToEnd(){let e=this.#t;if(e===null)throw new DOMException(`There is no selection to collapse.`,`InvalidStateError`);this.#o(e[P],e[I],e[P],e[I],1)}extend(e,t=0){arity(arguments.length,1,`extend`);let n=toImpl(e,`extend`),r=Number(t)>>>0;if(!this.#a(n))return;let i=this.#t;if(i===null)throw new DOMException(`This Selection object doesn't have any Ranges.`,`InvalidStateError`);checkBoundary(n,r);let a=this.#r===2?i[P]:i[W],o=this.#r===2?i[I]:i[K];a!==n&&treeRoot(a)!==treeRoot(n)?this.#o(n,r,n,r,1):compareBoundaryPoints(a,o,n,r)>0?this.#o(n,r,a,o,2):this.#o(a,o,n,r,1)}setBaseAndExtent(e,t,n,r){arity(arguments.length,4,`setBaseAndExtent`);let i=toImpl(e,`setBaseAndExtent`),a=toImpl(n,`setBaseAndExtent`),o=Number(t)>>>0,s=Number(r)>>>0;if(checkBoundary(i,o),checkBoundary(a,s),!this.#a(i))return;if(i===a||i.parent!==null&&i.parent===a.parent){compareBoundaryPoints(a,s,i,o)<0?this.#o(a,s,i,o,2):this.#o(i,o,a,s,1);return}if(!this.#a(a))return;let c=new yd(this.#e),l=compareBoundaryPoints(a,s,i,o)<0;l?(c._setStart(a,s),c._setEnd(i,o)):(c._setStart(i,o),c._setEnd(a,s)),this.#s(c,l?2:1,!0)}selectAllChildren(e){let t=toImpl(e,`selectAllChildren`);if(t.type===10)throw new DOMException(`DocumentType Node can't be used as boundary point.`,`InvalidNodeTypeError`);this.#a(t)&&this.#o(t,0,t,t.childCount,1)}deleteFromDocument(){this.#t?.deleteContents()}containsNode(e,t=!1){arity(arguments.length,1,`containsNode`);let n=toImpl(e,`containsNode`),r=this.#t;if(r===null||!this.#a(n)||treeRoot(n)!==r._treeRoot())return!1;let i=nodeLength(n);return t?compareBoundaryPoints(r[W],r[K],n,i)<=0&&compareBoundaryPoints(r[P],r[I],n,0)>=0:compareBoundaryPoints(r[W],r[K],n,0)<=0&&compareBoundaryPoints(r[P],r[I],n,i)>=0}getComposedRanges(...e){let t=this.#t;return t===null?[]:[new StaticRange({startContainer:t[W].node,startOffset:t[K],endContainer:t[P].node,endOffset:t[I]})]}modify(e,t,n){}toString(){let e=this.#t;return e===null?``:e.toString()}};Object.defineProperty(Selection.prototype,Symbol.toStringTag,{value:`Selection`,configurable:!0});const xd={__proto__:null,beforeunloadevent:BeforeUnloadEvent,compositionevent:CompositionEvent,customevent:CustomEvent,devicemotionevent:null,deviceorientationevent:null,dragevent:DragEvent,event:Event,events:Event,focusevent:FocusEvent,hashchangeevent:HashChangeEvent,htmlevents:Event,keyboardevent:KeyboardEvent,messageevent:MessageEvent,mouseevent:MouseEvent,mouseevents:MouseEvent,storageevent:StorageEvent,svgevents:Event,textevent:TextEvent,touchevent:TouchEvent,uievent:UIEvent,uievents:UIEvent};function createEvent(e){let t=xd[asciiLowercase$1(String(e))];if(t==null)throw new DOMException(`Failed to execute 'createEvent' on 'Document': The provided event type ('${e}') is invalid.`,`NotSupportedError`);let n=setInternalConstruct(!0),r;try{r=new t(``)}finally{setInternalConstruct(n)}return r._s.flags&=-33,r}var Q=class Document extends Node{constructor(){super(9,null),hideInternals(this),this[z].flags|=1,defineHidden(this,Y,null),defineHidden(this,J,0),defineHidden(this,ei,0),defineHidden(this,Gr,0),defineHidden(this,et,0),defineHidden(this,Tn,/* @__PURE__ */ new Map),defineHidden(this,L,null),defineHidden(this,Nn,!1),defineHidden(this,yt,`application/xml`),defineHidden(this,q,`about:blank`),defineHidden(this,qn,`no-quirks`),defineHidden(this,En,null),defineHidden(this,Et,null),defineHidden(this,hi,null),defineHidden(this,Ar,null),defineHidden(this,pr,null),defineHidden(this,Vt,null),defineHidden(this,ln,null),defineHidden(this,cn,!1),defineHidden(this,tn,0),defineHidden(this,rn,0),defineHidden(this,nn,0),defineHidden(this,an,null),defineHidden(this,sn,``),defineHidden(this,fr,null),defineHidden(this,un,null),defineHidden(this,We,null),defineHidden(this,Ze,null),defineHidden(this,Qe,``),defineHidden(this,$e,-1),defineHidden(this,Xe,``)}static _createHTML(e,t=`about:blank`){let n=new Document;return n[Y]=e,n[Nn]=!0,n[yt]=`text/html`,n[q]=t,n}_idAdd(e){addToElementIndex(this[Tn],e.id,e)}_idRemove(e){removeFromElementIndex(this[Tn],e.id,e)}_idLookup(e){let t=this[Tn].get(e);if(t===void 0)return null;if(!Array.isArray(t))return t;let n=this[z];for(let t=nextElementInTree(n,n);t!==null;t=nextElementInTree(t,n))if(t.id===e)return t;return null}get URL(){return this[q]}get documentURI(){return this[q]}get baseURI(){if(this[$e]===this[J]&&this[Xe]===this[q])return this[Qe];let e=documentBaseURL(this);return this[Qe]=e,this[$e]=this[J],this[Xe]=this[q],e}get compatMode(){return this[qn]===`quirks`?`BackCompat`:`CSS1Compat`}get characterSet(){return`UTF-8`}get charset(){return`UTF-8`}get inputEncoding(){return`UTF-8`}get contentType(){return this[yt]}get defaultView(){return this[Y]}get implementation(){return this[En]??=new DOMImplementation(this)}get doctype(){for(let e=this[z].first;e!==null;e=e.next)if(e.type===10)return e.node;return null}get documentElement(){let e=firstElementChild(this[z]);return e===null?null:e.node}get head(){let e=firstElementChild(this[z]);if(e===null||e.tag!==Z.html)return null;for(let t=e.first;t!==null;t=t.next)if(t.type===1&&t.tag===Z.head)return t.node;return null}get body(){let e=firstElementChild(this[z]);if(e===null||e.tag!==Z.html)return null;for(let t=e.first;t!==null;t=t.next)if(t.type===1&&(t.tag===Z.body||t.tag===Z.frameset))return t.node;return null}set body(e){let t=e==null?null:e[z];if(t===null||t.ns!==`http://www.w3.org/1999/xhtml`||t.tag!==Z.body&&t.tag!==Z.frameset)throw new DOMException(`The new body element must be a 'body' or 'frameset' element.`,`HierarchyRequestError`);let n=this.body;if(e===n)return;if(n!==null){n.parentNode.replaceChild(e,n);return}let r=this.documentElement;if(r===null)throw new DOMException(`The document has no document element.`,`HierarchyRequestError`);r.appendChild(e)}createElement(e,t){let n=String(e);if(!isValidElementLocalName(n))throw new DOMException(`"${n}" is not a valid element name.`,`InvalidCharacterError`);this[Nn]&&(n=asciiLowercase$1(n));let r=this[Nn]||this[yt]===`application/xhtml+xml`?E:null,i=typeof t==`object`&&t&&t.is!==void 0?String(t.is):null;return createElementImplSync(this,n,r,null,i).node}createElementNS(e,t,n){let{namespace:r,prefix:i,localName:a}=validateAndExtract(e===void 0?null:e,String(t),`element`),o=typeof n==`object`&&n&&n.is!==void 0?String(n.is):null;return createElementImplSync(this,a,r,i,o).node}createDocumentFragment(){return new DocumentFragment(this)}createTextNode(e){return new Text(String(e),this)}createCDATASection(e){if(this[Nn])throw new DOMException(`CDATA sections are not supported in HTML documents.`,`NotSupportedError`);if(String(e).includes(`]]>`))throw new DOMException(`Data contains "]]>".`,`InvalidCharacterError`);return new CDATASection(String(e),this)}createComment(e){return new Comment(String(e),this)}createProcessingInstruction(e,t){if(!isXMLName(String(e)))throw new DOMException(`"${e}" is not a valid processing instruction target.`,`InvalidCharacterError`);if(String(t).includes(`?>`))throw new DOMException(`Data contains "?>".`,`InvalidCharacterError`);return new ProcessingInstruction(String(e),String(t),this)}createAttribute(e){let t=String(e);if(!isValidAttributeLocalName(t))throw new DOMException(`"${t}" is not a valid attribute name.`,`InvalidCharacterError`);return this[Nn]&&(t=asciiLowercase$1(t)),new Attr(this,t,``,null,null,null)}createAttributeNS(e,t){let{namespace:n,prefix:r,localName:i}=validateAndExtract(e===void 0?null:e,String(t),`attribute`);return new Attr(this,i,``,n,r,null)}importNode(e,t=!1){if(e[z].type===9||e[z].flags&32)throw new DOMException(`Documents and shadow roots cannot be imported.`,`NotSupportedError`);return cloneNode(e[z],this,t).node}adoptNode(e){if(e[z].type===9)throw new DOMException(`Documents cannot be adopted.`,`NotSupportedError`);if(e[z].flags&32)throw new DOMException(`Shadow roots cannot be adopted.`,`HierarchyRequestError`);return adopt(e[z],this),Xi&&flushCEReactions(),e}getElementsByTagName(e){return getElementsByTagName(this[z],String(e))}getElementsByTagNameNS(e,t){return getElementsByTagNameNS(this[z],e,String(t))}getElementsByClassName(e){return getElementsByClassName(this[z],String(e))}getElementsByName(e){return new NameNodeList(this[z],String(e))}get forms(){return this[un]??=withNamedProperties(cachedCollection(this[z],`forms`,!0,e=>e.tag===Z.form&&e.ns===`http://www.w3.org/1999/xhtml`))}get images(){return cachedCollection(this[z],`images`,!0,e=>e.tag===Z.img&&e.ns===`http://www.w3.org/1999/xhtml`)}get embeds(){return cachedCollection(this[z],`embeds`,!0,e=>e.tag===Z.embed&&e.ns===`http://www.w3.org/1999/xhtml`)}get plugins(){return this.embeds}get scripts(){return cachedCollection(this[z],`scripts`,!0,e=>e.tag===Z.script&&e.ns===`http://www.w3.org/1999/xhtml`)}get links(){return cachedCollection(this[z],`links`,!1,e=>(e.tag===Z.a||e.tag===Z.area)&&e.ns===`http://www.w3.org/1999/xhtml`&&attr(e,`href`)!==null)}get anchors(){return cachedCollection(this[z],`anchors`,!1,e=>e.tag===Z.a&&e.ns===`http://www.w3.org/1999/xhtml`&&attr(e,`name`)!==null)}get applets(){return cachedCollection(this[z],`applets`,!0,()=>!1)}createRange(){return new yd(this)}createTreeWalker(e,t=4294967295,n=null){return new TreeWalker(e,t,n)}createNodeIterator(e,t=4294967295,n=null){return new NodeIterator(e,t,n)}elementFromPoint(e,t){return null}elementsFromPoint(e,t){return[]}getSelection(){return this[Y]===null?null:this[Ar]??=new Selection(this)}open(...e){if(e.length>=3)return this[Y]?.open?.(...e)??null;if(!this[Nn])throw new DOMException(`Only HTML documents can be opened.`,`InvalidStateError`);return this._replaceAll(null),this[hi]=``,this}write(...e){if(!this[Nn])throw new DOMException(`Only HTML documents can be written to.`,`InvalidStateError`);this[hi]===null&&this.open(),this[hi]+=e.map(String).join(``),this._replaceAll(null),parseDocument(this[hi],this)}writeln(...e){this.write(...e,`
40
- `)}close(){if(!this[Nn])throw new DOMException(`Only HTML documents can be closed.`,`InvalidStateError`);this[hi]=null}_cloneDocument(){let e=this instanceof XMLDocument?new XMLDocument:new Document;return e[Ze]=this.baseURI,e[Nn]=this[Nn],e[yt]=this[yt],e[q]=this[q],e[qn]=this[qn],e}createEvent(e){if(arguments.length===0)throw TypeError(`Failed to execute 'createEvent' on 'Document': 1 argument required, but only 0 present.`);return createEvent(e)}_getTheParent(e){return e.type===`load`||this[Y]===null?null:this[Y]}};installParentNode(Q),installNonElementParentNode(Q),installEventHandlers(Q.prototype,`document`);function documentBaseURL(e){let t=e[q],n=e[We]!==null&&(t===`about:blank`||t===`about:srcdoc`)?e[We]:t,r=e[z];for(let e=nextElementInTree(r,r);e!==null;e=nextElementInTree(e,r)){if(e.tag!==Z.base||e.ns!==`http://www.w3.org/1999/xhtml`)continue;let t=attr(e,`href`);if(t===null)continue;let r=URL.parse(t,n);return r===null||r.protocol===`data:`||r.protocol===`javascript:`?n:r.href}return e[Ze]??n}var XMLDocument=class extends Q{};Object.defineProperty(XMLDocument.prototype,Symbol.toStringTag,{value:`XMLDocument`,configurable:!0});var DOMImplementation=class{[Ht];constructor(e){if(!(e instanceof Q))throw TypeError(`Illegal constructor`);this[Ht]=e}createDocumentType(e,t,n){if(!isValidDoctypeName(String(e)))throw new DOMException(`"${e}" is not a valid doctype name.`,`InvalidCharacterError`);return new DocumentType(this[Ht],String(e),String(t),String(n))}createHTMLDocument(e){let t=Q._createHTML(null);t.appendChild(new DocumentType(t,`html`,``,``));let n=t.createElement(`html`);t.appendChild(n);let r=t.createElement(`head`);if(n.appendChild(r),e!==void 0){let n=t.createElement(`title`);n.appendChild(t.createTextNode(String(e))),r.appendChild(n)}return n.appendChild(t.createElement(`body`)),t}createDocument(e,t,n=null){arguments.length<2&&argumentsRequired(`createDocument`,`DOMImplementation`,2,arguments.length);let r=new XMLDocument;return e===`http://www.w3.org/1999/xhtml`?r[yt]=`application/xhtml+xml`:e===`http://www.w3.org/2000/svg`&&(r[yt]=`image/svg+xml`),n!==null&&r.appendChild(n),t!==null&&t!==``&&r.appendChild(r.createElementNS(e,t)),r}hasFeature(){return!0}};let Sd=Object.create(null);function registerDomNamespace(e){Sd=e,tagInterfaces(Sd)}function tagInterfaces(e){for(let t of Object.keys(e)){let n=e[t];if(typeof n!=`function`||!isInterfaceName(t)||n.name!==t)continue;let r=n.prototype;typeof r==`object`&&r&&r.constructor===n&&(Object.hasOwn(r,Symbol.toStringTag)||Object.defineProperty(r,Symbol.toStringTag,{value:t,configurable:!0}))}}let Cd=null;function isInterfaceName(e){let t=e.charCodeAt(0);return t>=65&&t<=90}const wd=/* @__PURE__ */ new Set([`ResizeObserver`,`ResizeObserverEntry`,`ResizeObserverSize`]);function optInInterfaces(){let e=Object.create(null);for(let t of wd)Sd[t]!==void 0&&(e[t]=Sd[t]);return e}function ensureInterfaces(e,t={}){if(Cd!==null)return Cd;let n=Object.create(null),r=Sd;for(let e of Object.keys(r)){if(!isInterfaceName(e)||wd.has(e))continue;let t=r[e];(typeof t==`function`||typeof t==`object`&&t)&&(n[e]=t)}for(let e of Object.keys(t))e in n||(n[e]=t[e]);let i={};for(let t of Object.keys(n))Object.hasOwn(e,t)||(i[t]={value:n[t],writable:!0,configurable:!0,enumerable:!1});let a=Object.create(Object.getPrototypeOf(e));return Object.defineProperties(a,i),Object.setPrototypeOf(e,a),Cd=n,n}function eventInterface(e){return Sd[e]}function domExport(e){return Sd[e]}const Td=[`text/xml`,`application/xml`,`application/xhtml+xml`,`image/svg+xml`];var DOMParser=class{parseFromString(e,t){let n=currentWindowOrNull()?.document.URL??`about:blank`;if(t=String(t),t===`text/html`){let t=Q._createHTML(null,n);return parseDocument(String(e),t),t}if(!Td.includes(t))throw TypeError(`Failed to execute 'parseFromString' on 'DOMParser': The provided value '${t}' is not a valid enum value of type DOMParserSupportedType.`);let r=new Q;return r[yt]=t,r[q]=n,parseXML(String(e),r,t),r}},XMLSerializer=class{serializeToString(e){return serializeXML(e[z],!1)}};function documentParseHTMLUnsafe(e){let t=Q._createHTML(null,`about:blank`);return parseHTMLUnsafe(String(e),t),t}function escape$1(e){let t=String(e),n=t.length,r=``,i=n>0?t.charCodeAt(0):0;for(let e=0;e<n;e++){let a=t.charCodeAt(e);r+=a===0?`�`:a>=1&&a<=31||a===127||e===0&&a>=48&&a<=57||e===1&&a>=48&&a<=57&&i===45?`\\${a.toString(16)} `:e===0&&a===45&&n===1?`\\-`:a>=128||a===45||a===95||a>=48&&a<=57||a>=65&&a<=90||a>=97&&a<=122?t[e]:`\\${t[e]}`}return r}__name(escape$1,`escape`);const Ed={escape:escape$1,supports(e,t){return!1}},Dd=Symbol(`construct`);var DOMStringList=class{#e;constructor(e,t=[]){if(e!==Dd)throw TypeError(`Illegal constructor`);this.#e=t;for(let e=0;e<t.length;e++)Object.defineProperty(this,e,{value:t[e],writable:!1,enumerable:!0,configurable:!0});Object.preventExtensions(this)}get length(){return this.#e.length}item(e){return this.#e[Number(e)>>>0]??null}contains(e){return this.#e.includes(String(e))}*[Symbol.iterator](){yield*this.#e}get[Symbol.toStringTag](){return`DOMStringList`}};function createDOMStringList(e){return new DOMStringList(Dd,e)}const Od=globalThis.AbortSignal,kd=globalThis.AbortController;function enforceRange(e){let t=Number(e);if(!Number.isFinite(t))throw TypeError(`Failed to execute 'timeout' on 'AbortSignal': parameter 1 is not a finite number.`);let n=Math.trunc(t);if(n<0||n>2**53-1)throw TypeError(`Failed to execute 'timeout' on 'AbortSignal': parameter 1 is outside the accepted range.`);return n}const Ad=function AbortSignal(){throw TypeError(`Illegal constructor`)};Object.defineProperty(Ad,"prototype",{value:Od.prototype,writable:!1,enumerable:!1,configurable:!1}),Object.setPrototypeOf(Ad,Od),Object.defineProperty(Ad,"timeout",{value:function timeout(e){let t=enforceRange(e),n=currentWindowOrNull();if(n===null)return Od.timeout(t);let r=new kd;return n.setTimeout(()=>r.abort(new DOMException(`The operation timed out.`,`TimeoutError`)),t),r.signal},writable:!0,enumerable:!0,configurable:!0});function windowOrigin(e){let t=e;for(;t[q].protocol===`about:`&&t[ir]!==null;)t=t[ir];return t[q].origin}function parseURL(e,t){let n=URL.parse(String(t),e[q].href);if(n===null)throw new DOMException(`Failed to execute 'assign' on 'Location': '${t}' is not a valid URL.`,`SyntaxError`);return n}const jd={toString:{value:function toString(){return this[Y][q].href},writable:!1,enumerable:!0,configurable:!1},valueOf:{value:Object.prototype.valueOf,writable:!1,enumerable:!1,configurable:!1},[Symbol.toPrimitive]:{value:void 0,writable:!1,enumerable:!1,configurable:!1}};function inactive(e){return e[Y][pt]}function isSchemeInput(e){let t=e.replace(/[\t\n\r]/g,``)+`:`;return/^[A-Za-z][A-Za-z0-9+\-.]*:/.test(t)}var Location=class{[Y];#e=null;#t=null;constructor(e){this[Y]=e,Object.defineProperties(this,jd)}get href(){return this[Y][q].href}set href(e){inactive(this)||this[Y]._navigate(parseURL(this[Y],e),!1)}get origin(){return this[Y][q].origin}get protocol(){return this[Y][q].protocol}set protocol(e){if(inactive(this))return;let t=String(e);if(!isSchemeInput(t))throw new DOMException(`Failed to set the 'protocol' property on 'Location': '${t}' is an invalid protocol.`,`SyntaxError`);let n=new URL(this[Y][q].href);n.protocol=t,(n.protocol===`http:`||n.protocol===`https:`)&&this[Y]._navigate(n,!1)}get host(){return this[Y][q].host}set host(e){this._set(`host`,e)}get hostname(){return this[Y][q].hostname}set hostname(e){this._set(`hostname`,e)}get port(){return this[Y][q].port}set port(e){this._set(`port`,e)}get pathname(){return this[Y][q].pathname}set pathname(e){this._set(`pathname`,e)}get search(){return this[Y][q].search}set search(e){this._set(`search`,e)}get hash(){return this[Y][q].hash}set hash(e){if(inactive(this))return;let t=this[Y][q],n=t.hash.slice(1),r=String(e);r.startsWith(`#`)&&(r=r.slice(1));let i=new URL(t.href);i.hash=r,r===``&&(i=new URL(i.href+`#`)),i.hash.slice(1)!==n&&this[Y]._navigate(i,!1)}get ancestorOrigins(){if(inactive(this))return this.#t??=createDOMStringList([]);if(this.#e===null){let e=[];for(let t=this[Y][ir];t!==null;t=t[ir])e.push(windowOrigin(t));this.#e=createDOMStringList(e)}return this.#e}assign(e){inactive(this)||this[Y]._navigate(parseURL(this[Y],e),!1)}replace(e){inactive(this)||this[Y]._navigate(parseURL(this[Y],e),!0)}reload(){inactive(this)||reportNotImplemented(this[Y],$u)}_set(e,t){if(inactive(this))return;let n=new URL(this[Y][q].href);n[e]=String(t),this[Y]._navigate(n,!1)}get[Symbol.toStringTag](){return`Location`}};function checkFullyActive(e,t){if(e[Y][pt])throw new DOMException(`Failed to ${t} 'History': May not use a History object associated with a Document that is not fully active`,`SecurityError`)}function withoutFragment(e){let t=e.indexOf(`#`);return t===-1?e:e.slice(0,t)}var History=class{[Y];[Kt];[Dn];[Tr];constructor(e){this[Y]=e,this[Kt]=[{url:e[q].href,state:null}],this[Dn]=0,this[Tr]=`auto`}get length(){return checkFullyActive(this,`read the 'length' property from`),this[Kt].length}get state(){return checkFullyActive(this,`read the 'state' property from`),this[Kt][this[Dn]].state}get scrollRestoration(){return checkFullyActive(this,`read the 'scrollRestoration' property from`),this[Tr]}set scrollRestoration(e){checkFullyActive(this,`set the 'scrollRestoration' property on`),(e===`auto`||e===`manual`)&&(this[Tr]=e)}go(e=0){checkFullyActive(this,`execute 'go' on`);let t=Math.trunc(Number(e))||0;t!==0&&this[Y]._task(()=>{let e=this[Dn]+t;e<0||e>=this[Kt].length||this._traverseTo(e)},0)}back(){checkFullyActive(this,`execute 'back' on`),this.go(-1)}forward(){checkFullyActive(this,`execute 'forward' on`),this.go(1)}pushState(e,t,n){this._sharedPushReplaceState(e,n,!1,`pushState`)}replaceState(e,t,n){this._sharedPushReplaceState(e,n,!0,`replaceState`)}_sharedPushReplaceState(e,t,n,r){let i=this[Y];checkFullyActive(this,`execute '${r}' on`);let a=e==null?null:structuredClone(e),o=i[q];if(t!=null&&t!==``){let e=URL.parse(String(t),i[q].href);if(e===null)throw new DOMException(`Failed to execute '${r}' on 'History': A history state object with URL '${String(t)}' cannot be created.`,`SecurityError`);if(!canHaveURLRewritten(i[q],e))throw new DOMException(`Failed to execute '${r}' on 'History': A history state object with URL '${e.href}' cannot be created in a document with origin '${i[q].origin}' and URL '${i[q].href}'.`,`SecurityError`);o=e}let s={url:o.href,state:a};n?this[Kt][this[Dn]]=s:(this[Kt].length=this[Dn]+1,this[Kt].push(s),this[Dn]++),i._setURL(o)}_navigate(e,t){let n=this[Y],r=n[q].href,i=e.href;e.protocol!==`javascript:`&&withoutFragment(r)!==withoutFragment(i)&&reportNotImplemented(n,$u),i===r&&(t=!0);let a={url:i,state:null};if(t?this[Kt][this[Dn]]=a:(this[Kt].length=this[Dn]+1,this[Kt].push(a),this[Dn]++),n._setURL(e),(e.hash!==``||i.endsWith(`#`))&&withoutFragment(r)===withoutFragment(i)){let e=eventInterface(`PopStateEvent`);n.dispatchEvent(new e(`popstate`,{state:null})),r!==i&&this._queueHashChange(r,i)}}_traverseTo(e){let t=this[Y],n=t[q].href;this[Dn]=e;let r=this[Kt][e];r.url!==n&&t._setURL(new URL(r.url));let i=eventInterface(`PopStateEvent`);t.dispatchEvent(new i(`popstate`,{state:r.state})),n!==r.url&&withoutFragment(n)===withoutFragment(r.url)&&this._queueHashChange(n,r.url)}_queueHashChange(e,t){let n=this[Y];n._task(()=>{let r=eventInterface(`HashChangeEvent`);n.dispatchEvent(new r(`hashchange`,{oldURL:e,newURL:t}))},0)}get[Symbol.toStringTag](){return`History`}};function canHaveURLRewritten(e,t){return e.protocol!==t.protocol||e.username!==t.username||e.password!==t.password||e.host!==t.host?!1:t.protocol===`http:`||t.protocol===`https:`?!0:t.protocol===`file:`?e.pathname===t.pathname:withoutFragment(e.href).split(`?`)[0]===withoutFragment(t.href).split(`?`)[0]}var ClipboardItem=class{[B];[lr];constructor(e,t={}){if(typeof e!=`object`||!e||Object.keys(e).length===0)throw TypeError(`Failed to construct 'ClipboardItem': Empty dictionary argument`);this[B]=new Map(Object.entries(e)),this[lr]=t.presentationStyle??`unspecified`}get types(){return Object.freeze([...this[B].keys()])}get presentationStyle(){return this[lr]}async getType(e){if(!this[B].has(e))throw new DOMException(`Failed to execute 'getType' on 'ClipboardItem': The type was not found`,`NotFoundError`);let t=await this[B].get(e);return typeof t==`string`?new Blob([t],{type:e}):t}static supports(e){return e===`text/plain`||e===`text/html`||e===`image/png`||e.startsWith(`web `)}},Clipboard=class extends EventTarget{[jt];constructor(){super(),this[jt]=[]}async read(){return this[jt].slice()}async readText(){for(let e of this[jt])if(e[B].has(`text/plain`))return(await e.getType(`text/plain`)).text();return``}async write(e){this[jt]=Array.from(e)}async writeText(e){this[jt]=[new ClipboardItem({"text/plain":String(e)})]}};let Md=0;var Navigator=class{[Y];[dt];[oi];constructor(e){this[Y]=e,this[dt]=null,this[oi]=null}get appCodeName(){return`Mozilla`}get appName(){return`Netscape`}get appVersion(){return this.userAgent.replace(/^Mozilla\//,``)}get platform(){return this[Y][V].platform}get product(){return`Gecko`}get productSub(){return`20030107`}get userAgent(){return this[Y][V].userAgent}get vendor(){return`Apple Computer, Inc.`}get vendorSub(){return``}get oscpu(){}get language(){return this[Y][V].languages[0]??`en-US`}get languages(){return this[Y][V].languages}get onLine(){return!0}get cookieEnabled(){return!0}get hardwareConcurrency(){return Md||=i()}get pdfViewerEnabled(){return!1}get plugins(){return[]}get mimeTypes(){return[]}javaEnabled(){return!1}get maxTouchPoints(){return 0}get webdriver(){return!1}get doNotTrack(){return null}get deviceMemory(){return 8}get clipboard(){return this[dt]??=new Clipboard}set clipboard(e){Object.defineProperty(this,"clipboard",{value:e,writable:!0,enumerable:!0,configurable:!0})}get userActivation(){return this[oi]??={hasBeenActive:!1,isActive:!1}}sendBeacon(e,t){return!0}vibrate(e){return!0}registerProtocolHandler(){}unregisterProtocolHandler(){}get[Symbol.toStringTag](){return`Navigator`}},Screen=class extends EventTarget{[Y];constructor(e){super(),this[Y]=e}get width(){return this[Y][V].screenWidth}get height(){return this[Y][V].screenHeight}get availWidth(){return this[Y][V].screenWidth}get availHeight(){return this[Y][V].screenHeight}get availLeft(){return 0}get availTop(){return 0}get colorDepth(){return 24}get pixelDepth(){return 24}get isExtended(){return!1}},VisualViewport=class extends EventTarget{[Y];constructor(e){super(),this[Y]=e}get offsetLeft(){return 0}get offsetTop(){return 0}get pageLeft(){return this[Y].scrollX}get pageTop(){return this[Y].scrollY}get width(){return this[Y].innerWidth}get height(){return this[Y].innerHeight}get scale(){return 1}},StorageShed=class{areas=/* @__PURE__ */ new Map;windows=/* @__PURE__ */ new Set;collected=new FinalizationRegistry(e=>this.windows.delete(e))},StoragePeer=class extends WeakRef{shed;constructor(e,t=new StorageShed){super(e),this.shed=t,t.windows.add(this),t.collected.register(e,this,this)}leave(){this.shed.windows.delete(this),this.shed.collected.unregister(this)}};const Nd=Symbol(`storage`),Pd=Symbol(`construct`);var StorageArea=class extends Map{codeUnits=0};function state$2(e){return e[Nd]}__name(state$2,`state`);function visible(e,t){return!(t in e)&&state$2(e).map.has(t)}const Fd={get(e,t,n){return typeof t==`string`&&!(t in e)?state$2(e).map.get(t):Reflect.get(e,t,n)},set(e,t,n,r){return typeof t==`string`&&r===Id.get(e)?typeof n==`function`&&t in e?Reflect.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0}):(e.setItem(t,n),!0):Reflect.set(e,t,n,r)},has(e,t){return typeof t==`string`&&state$2(e).map.has(t)?!0:Reflect.has(e,t)},deleteProperty(e,t){return typeof t==`string`&&visible(e,t)?(e.removeItem(t),!0):Reflect.deleteProperty(e,t)},ownKeys(e){let t=[];for(let n of state$2(e).map.keys())n in e||t.push(n);for(let n of Reflect.ownKeys(e))t.push(n);return t},getOwnPropertyDescriptor(e,t){if(typeof t==`string`&&!(t in e)){let n=state$2(e).map.get(t);if(n!==void 0)return{value:n,writable:!0,enumerable:!0,configurable:!0}}return Reflect.getOwnPropertyDescriptor(e,t)},defineProperty(e,t,n){return typeof t==`string`&&!Object.hasOwn(e,t)&&`value`in n&&typeof n.value!=`function`?(e.setItem(t,n.value),!0):Reflect.defineProperty(e,t,n)}},Id=/* @__PURE__ */ new WeakMap;function requireArgs(e,t,n){if(e<t)throw TypeError(`Failed to execute '${n}' on 'Storage': ${t} argument${t===1?``:`s`} required, but only ${e} present.`)}var Storage=class{constructor(e,t,n,r){if(e!==Pd)throw TypeError(`Illegal constructor`);let i={map:r,window:t,type:n};Object.defineProperty(this,Nd,{value:i,writable:!1,enumerable:!1,configurable:!1});let a=new Proxy(this,Fd);return Id.set(this,a),a}get length(){return state$2(this).map.size}key(e){requireArgs(arguments.length,1,`key`);let t=Number(e)>>>0,n=state$2(this).map;if(t>=n.size)return null;let r=0;for(let e of n.keys())if(r++===t)return e;return null}getItem(e){return requireArgs(arguments.length,1,`getItem`),state$2(this).map.get(String(e))??null}setItem(e,t){requireArgs(arguments.length,2,`setItem`);let n=state$2(this),r=String(e),i=String(t),a=n.map.get(r);if(a===i)return;let o=n.map.codeUnits-(a===void 0?0:r.length+a.length)+r.length+i.length;if(o>5e6){let e=`Failed to execute 'setItem' on 'Storage': Setting the value of '${r}' exceeded the quota.`,t=globalThis.QuotaExceededError;throw t===void 0?new DOMException(e,`QuotaExceededError`):new t(e)}n.map.set(r,i),n.map.codeUnits=o,broadcast(n,r,a??null,i)}removeItem(e){requireArgs(arguments.length,1,`removeItem`);let t=state$2(this),n=String(e),r=t.map.get(n);r!==void 0&&(t.map.delete(n),t.map.codeUnits-=n.length+r.length,broadcast(t,n,r,null))}clear(){let e=state$2(this);e.map.size!==0&&(e.map.clear(),e.map.codeUnits=0,broadcast(e,null,null,null))}get[Symbol.toStringTag](){return`Storage`}};function topWindow(e){let t=e;for(;t[ir]!==null;)t=t[ir];return t}function broadcast(e,t,n,r){let i=e.window,a=i._storageShed;if(a.windows.size<2)return;let o=windowOrigin(i),s=i[q].href,c=e.type===`session`?topWindow(i):null;for(let l of a.windows){let a=l.deref();if(a===void 0||a===i||a[pt]||windowOrigin(a)!==o||c!==null&&topWindow(a)!==c)continue;let u=e.type===`local`;a._task(()=>{let e=eventInterface(`StorageEvent`),i=u?a.localStorage:a.sessionStorage;a.dispatchEvent(new e(`storage`,{key:t,oldValue:n,newValue:r,url:s,storageArea:i}))},0)}}function createLocalStorage(e){let t=e._storageShed,n=windowOrigin(e),r=t.areas.get(n);return r===void 0&&t.areas.set(n,r=new StorageArea),new Storage(Pd,e,`local`,r)}const Ld=/* @__PURE__ */ new WeakMap;function createSessionStorage(e){let t=topWindow(e),n=Ld.get(t);n===void 0&&Ld.set(t,n=/* @__PURE__ */ new Map);let r=windowOrigin(e),i=n.get(r);return i===void 0&&n.set(r,i=new StorageArea),new Storage(Pd,e,`session`,i)}function defaultPath(e){let t=e.pathname;if(!t.startsWith(`/`))return`/`;let n=t.lastIndexOf(`/`);return n===0?`/`:t.slice(0,n)}function pathMatches(e,t){return e===t?!0:e.startsWith(t)?t.endsWith(`/`)||e[t.length]===`/`:!1}function domainMatches(e,t){return e===t||e.endsWith(`.`+t)&&!/^[\d.]+$/.test(e)&&!e.startsWith(`[`)}function cookieDomainMatches(e,t){return e.hostOnly?t===e.domain:domainMatches(t,e.domain)}var CookieJar=class{[Tt];constructor(){this[Tt]=[]}set(e,t,n=Date.now()){let r=String(e).split(`;`),i=r[0],a=i.indexOf(`=`),o=(a===-1?``:i.slice(0,a)).trim(),s=(a===-1?i:i.slice(a+1)).trim();if(o===``&&s===``)return;let c=defaultPath(t),l=1/0,u=!1,d=!1,m=``;for(let e=1;e<r.length;e++){let i=r[e],a=i.indexOf(`=`),o=(a===-1?i:i.slice(0,a)).trim().toLowerCase(),s=a===-1?``:i.slice(a+1).trim();switch(o){case`max-age`:{if(!/^-?\d+$/.test(s))break;let e=Number(s);l=e<=0?-1/0:n+e*1e3,u=!0;break}case`expires`:{if(u)break;let e=Date.parse(s);Number.isNaN(e)||(l=e);break}case`domain`:if(s===``)break;m=(s.startsWith(`.`)?s.slice(1):s).toLowerCase();break;case`path`:c=s.startsWith(`/`)?s:defaultPath(t);break;case`secure`:d=!0;break;case`httponly`:return}}if(d&&t.protocol!==`https:`&&t.hostname!==`localhost`)return;let h=t.hostname.toLowerCase();if(m!==``&&!domainMatches(h,m))return;let _=m===``,v=_?h:m,y=this[Tt].findIndex(e=>e.name===o&&e.domain===v&&e.path===c);if(l<=n){y!==-1&&this[Tt].splice(y,1);return}let b={name:o,value:s,domain:v,hostOnly:_,path:c,expires:l,secure:d};y===-1?this[Tt].push(b):this[Tt][y]=b}get(e,t=Date.now()){let n=``,r=e.hostname.toLowerCase(),i=[];for(let n=this[Tt].length-1;n>=0;n--){let a=this[Tt][n];a.expires<=t?this[Tt].splice(n,1):a.secure&&e.protocol!==`https:`&&e.hostname!==`localhost`||cookieDomainMatches(a,r)&&pathMatches(e.pathname,a.path)&&i.push(a)}i.reverse(),i.sort((e,t)=>t.path.length-e.path.length);for(let e of i)n!==``&&(n+=`; `),n+=e.name===``?e.value:`${e.name}=${e.value}`;return n}};function windowOf$1(e){return e[Y]}__name(windowOf$1,`windowOf`);const Rd={cookie:{get(){let e=windowOf$1(this);return e===null?``:e._cookieStore.get(e[q])},set(e){let t=windowOf$1(this);t!==null&&t._cookieStore.set(String(e),t[q])}},referrer:{get(){return windowOf$1(this)?.[V].referrer??``}},currentScript:{get(){return null}},readyState:{get(){return`complete`}},visibilityState:{get(){return`visible`}},hidden:{get(){return!1}},location:{get(){return windowOf$1(this)?.location??null},set(e){let t=windowOf$1(this);t!==null&&(t.location.href=e)}},lastModified:{get(){let e=/* @__PURE__ */ new Date,p=e=>String(e).padStart(2,`0`);return`${p(e.getMonth()+1)}/${p(e.getDate())}/${e.getFullYear()} ${p(e.getHours())}:${p(e.getMinutes())}:${p(e.getSeconds())}`}},domain:{get(){return windowOf$1(this)?.[q].hostname??``},set(){}},designMode:{get(){return isDesignModeEnabled(this)?`on`:`off`},set(e){let t=asciiLowercase$1(String(e));t===`on`?setDesignModeEnabled(this,!0):t===`off`&&setDesignModeEnabled(this,!1)}}},zd=Q.prototype;for(let e of Object.keys(Rd))e in zd||Object.defineProperty(zd,e,{...Rd[e],enumerable:!0,configurable:!0});Object.hasOwn(Q,`parseHTMLUnsafe`)||Object.defineProperty(Q,"parseHTMLUnsafe",{value:documentParseHTMLUnsafe,writable:!0,enumerable:!0,configurable:!0});let Bd;var TimerList=class{timers=/* @__PURE__ */ new Set;collected=new FinalizationRegistry(e=>this.timers.delete(e));other=null};function pendingTimer(e,t){let timer=function(...e){let t=timer.callback;if(t!==null)return Reflect.apply(t,this,e)};return timer.callback=e,timer.clear=t,timer.handle=void 0,timer}function clearTimers(e){let t=e[Zr];if(t!==null){e[Zr]=null;for(let e of t.timers){let t=e.deref();t!==void 0&&(t.callback=null,clearHandle(t.clear,t.handle),t.clear=null,t.handle=void 0)}if(t.timers.clear(),t.other!==null){for(let[e,n]of t.other)clearHandle(n,e);t.other.clear()}}}function clearHandle(e,t){try{e(t)}catch{}}function timerTimeout(e){let t=e|0;return t<0?0:t}function startTimer(e,t,n,r,i,a){let o=timerTimeout(i);if(e[pt])return 0;let s=t[n?`setInterval`:`setTimeout`],c=t[n?`clearInterval`:`clearTimeout`];return schedule$1(e,s,c,r,o,a)}function schedule$1(e,t,n,r,i,a){if(Bd?.get(t)===e)return t(r,i,...a);if(typeof r!=`function`){let o=t(r,i,...a);if(e[pt])return clearHandle(n,o),o;let s=e[Zr]??=new TimerList;return(s.other??=/* @__PURE__ */ new Map).set(o,n),o}let o=pendingTimer(r,n),s=a.length===0?t(o,i):t(o,i,...a);if(e[pt])return o.callback=null,clearHandle(n,s),s;o.handle=s;let c=e[Zr]??=new TimerList,l=new WeakRef(o);return c.timers.add(l),c.collected.register(o,l),s}__name(schedule$1,`schedule`);function wrapTimer(e,t,n){let r=n?`setInterval`:`setTimeout`,i=t[r],a=t[n?`clearInterval`:`clearTimeout`],o={[r](t,n,...r){let o=timerTimeout(n);return e[pt]?0:schedule$1(e,i,a,t,o,r)}}[r];for(let e of Object.getOwnPropertySymbols(i))Object.defineProperty(o,e,Object.getOwnPropertyDescriptor(i,e));return(Bd??=/* @__PURE__ */ new WeakMap).set(o,e),o}function trackGlobalTimers(e,t){let n=[];for(let r of[!1,!0]){let i=r?`setInterval`:`setTimeout`;typeof t[i]==`function`&&typeof t[r?`clearInterval`:`clearTimeout`]==`function`&&(n.push([i,Object.getOwnPropertyDescriptor(t,i)]),Object.defineProperty(t,i,{value:wrapTimer(e,t,r),writable:!0,enumerable:!0,configurable:!0}))}return function restore(){for(let[e,r]of n)r===void 0?delete t[e]:Object.defineProperty(t,e,r);n.length=0}}let Vd=!1;function enableLayout(){Vd=!0}const Hd=Object.freeze([`en-US`,`en`]);let Ud=!1;const Wd=/* @__PURE__ */ new WeakMap;function receiver(e,t){return e!=null&&e[pt]!==void 0?e:otherReceiver(e,t)}function otherReceiver(e,t){let n=e==null?currentWindowOrNull():typeof e==`object`||typeof e==`function`?Wd.get(e):void 0;if(n==null)throw TypeError(`Failed to execute '${t}' on 'Window': Illegal invocation`);return n}const Gd=[V,q,Hn,yn,Zn,wr,ui,Vn,Nr,zr,Ot,wt,Kn,Yr,Zr,dn,Cr,mn,hn,pn,Cn,wn,Mn,jn,Lt,Er,Dr,pt,R,ir,fn,_n,ct];var Window=class extends EventTarget{document;name;status;opener;constructor(e={},t){super();for(let e=0;e<Gd.length;e++)Object.defineProperty(this,Gd[e],{value:void 0,writable:!0,configurable:!0,enumerable:!1});Ud||preparePrototype();let n=new URL(e.url??`http://localhost/`),r=Q._createHTML(this,n.href);this.document=r,this.name=``,this.status=``,this.opener=null;let i=e.width??1024,a=e.height??768;this[V]={userAgent:e.userAgent??`Mozilla/5.0 (linux) AppleWebKit/537.36 (KHTML, like Gecko) ctrl-dom/0.0.0`,platform:e.platform??``,languages:e.languages??Hd,referrer:e.referrer??``,screenWidth:e.screenWidth??i,screenHeight:e.screenHeight??a,mediaFeatures:e.mediaFeatures,validationMessages:e.validationMessages===`browser`?`browser`:`jsdom`,compat:resolveCompat(e.compat),layout:e.layout===`lite`?`lite`:`none`},e.layout===`lite`&&enableLayout(),this[q]=n,this[Hn]=null,this[yn]=null,this[Zn]=null,this[wr]=null,this[ui]=null,this[Vn]=null,this[Nr]=null;let o=t?.parent??e.shareStorageWith;if(this[zr]=o===void 0?null:new StoragePeer(this,o._storageShed),this[Ot]=null,this[wt]=null,this[Kn]=/* @__PURE__ */ new Set,this[Yr]=null,this[Zr]=null,this[dn]=null,this[Cr]=null,this[mn]=null,this[hn]=-1,this[pn]=0,this[Cn]=null,this[wn]=0,this[Mn]=i,this[jn]=a,this[Lt]=e.devicePixelRatio??1,this[Er]=0,this[Dr]=0,this[pt]=!1,this[R]=globalThis,this[ir]=null,this[fn]=null,this[ct]=null,this[_n]=null,(e.visualViewport??compatExposes(this[V].compat,`visualViewport`))&&Object.defineProperty(this,"visualViewport",{get:visualViewportGetter,enumerable:!0,configurable:!0}),t!==void 0){if(this[ir]=t.parent,this[fn]=t.frameElement,this[R]=t.parent[R],(t.parent[ct]??=/* @__PURE__ */ new Set).add(this),t.srcdoc!==null)parseDocument(t.srcdoc,r);else{let e=r.createElement(`html`);e.appendChild(r.createElement(`head`)),e.appendChild(r.createElement(`body`)),r.appendChild(e)}}else{if(Ou.setComputedColorMode?.(e.cssComputedColors??`specified`),setCurrentWindow(this),e.html!==void 0)parseDocument(e.html,r);else{r.appendChild(new DocumentType(r,`html`,``,``));let e=r.createElement(`html`);e.appendChild(r.createElement(`head`)),e.appendChild(r.createElement(`body`)),r.appendChild(e)}hideInternals(this)}}get window(){return this}get self(){return this}get frames(){return this}get parent(){let e=this[ir];return e===null?this:e[_n]??e}get top(){let e=this[ir];if(e===null)return this;for(;e[ir]!==null;)e=e[ir];return e[_n]??e}get length(){return 0}get frameElement(){return this[fn]}get closed(){return this[pt]}get origin(){return windowOrigin(this)}get isSecureContext(){let{protocol:e,hostname:t}=this[q];return e===`https:`||e===`wss:`||e===`file:`||t===`localhost`||t.endsWith(`.localhost`)||/^127\.\d+\.\d+\.\d+$/.test(t)||t===`[::1]`}get crossOriginIsolated(){return!1}get event(){return getCurrentEvent()}get location(){return this[Hn]??=new Location(this)}set location(e){this.location.href=e}get history(){return this[yn]??=new History(this)}get navigator(){return this[Zn]??=new Navigator(this)}get clientInformation(){return this.navigator}get screen(){return this[wr]??=new Screen(this)}get localStorage(){return this[Vn]??=createLocalStorage(this)}get sessionStorage(){return this[Nr]??=createSessionStorage(this)}get customElements(){if(this[Ot]===null){let e=Ou.createCustomElementRegistry;if(e!==null)this[Ot]=e(this);else return}return this[Ot]}get _storageShed(){return(this[zr]??=new StoragePeer(this)).shed}get _cookieStore(){return this[wt]??=new CookieJar}get innerWidth(){return this[Mn]}set innerWidth(e){this[Mn]=e,this[Kn].size!==0&&reportMediaQueryChanges(this)}get innerHeight(){return this[jn]}set innerHeight(e){this[jn]=e,this[Kn].size!==0&&reportMediaQueryChanges(this)}get outerWidth(){return this[Mn]}get outerHeight(){return this[jn]}get devicePixelRatio(){return this[Lt]}set devicePixelRatio(e){this[Lt]=e,this[Kn].size!==0&&reportMediaQueryChanges(this)}get screenX(){return 0}get screenY(){return 0}get screenLeft(){return 0}get screenTop(){return 0}get scrollX(){return this[Er]}set scrollX(e){this[Er]=e}get scrollY(){return this[Dr]}set scrollY(e){this[Dr]=e}get pageXOffset(){return this[Er]}set pageXOffset(e){this[Er]=e}get pageYOffset(){return this[Dr]}set pageYOffset(e){this[Dr]=e}scroll(e,t){let n=receiver(this,`scroll`);reportNotImplemented(n,qd.scroll),scrollWindow(n,e,t)}scrollTo(e,t){let n=receiver(this,`scrollTo`);reportNotImplemented(n,qd.scrollTo),scrollWindow(n,e,t)}scrollBy(e,t){let n=receiver(this,`scrollBy`);reportNotImplemented(n,qd.scrollBy),typeof e==`object`&&e?scrollWindow(n,{left:n[Er]+(Number(e.left)||0),top:n[Dr]+(Number(e.top)||0)}):scrollWindow(n,n[Er]+(Number(e)||0),n[Dr]+(Number(t)||0))}resizeTo(e,t){let n=receiver(this,`resizeTo`);reportNotImplemented(n,qd.resizeTo),resizeWindow(n,Number(e),Number(t))}resizeBy(e,t){let n=receiver(this,`resizeBy`);reportNotImplemented(n,qd.resizeBy),resizeWindow(n,n[Mn]+Number(e),n[jn]+Number(t))}moveTo(e,t){reportNotImplemented(receiver(this,`moveTo`),qd.moveTo)}moveBy(e,t){reportNotImplemented(receiver(this,`moveBy`),qd.moveBy)}getComputedStyle(e,t){if(typeof e!=`object`||!e||!(z in e)||e[z].type!==1)throw TypeError(`Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.`);t!=null&&String(t)!==``&&reportNotImplemented(receiver(this,`getComputedStyle`),ed);let n=Ou.getComputedStyle??domExport(`getComputedStyle`)??null;return n===null?new CSSStyleDeclaration(e):n(e,t,receiver(this,`getComputedStyle`))}matchMedia(e){if(arguments.length===0)throw TypeError(`Failed to execute 'matchMedia' on 'Window': 1 argument required, but only 0 present.`);return new MediaQueryList(receiver(this,`matchMedia`),String(e).trim())}getSelection(){let e=receiver(this,`getSelection`).document;return typeof e.getSelection==`function`?e.getSelection():null}requestAnimationFrame(e){if(typeof e!=`function`)throw TypeError(`Failed to execute 'requestAnimationFrame' on 'Window': The callback provided as parameter 1 is not a function.`);let t=receiver(this,`requestAnimationFrame`),n=++t[pn];(t[dn]??=/* @__PURE__ */ new Map).set(n,e);let r=frameTimers(t),i=t[mn];return(i===null||i.scheduledWith!==r.setTimeout)&&(i!==null&&t._cancelTask(i),t[mn]=t._schedule(r,runAnimationFrame,nextFrameDelay(t))),n}cancelAnimationFrame(e){let t=receiver(this,`cancelAnimationFrame`);t[dn]?.delete(e),t[Cr]?.delete(e)}requestIdleCallback(e,t){if(typeof e!=`function`)throw TypeError(`Failed to execute 'requestIdleCallback' on 'Window': The callback provided as parameter 1 is not a function.`);let n=receiver(this,`requestIdleCallback`),r=++n[wn],i=n[Cn]??=/* @__PURE__ */ new Map,a=n._task(()=>{i.delete(r);let t=Date.now()+50;e({didTimeout:!1,timeRemaining:()=>Math.max(0,t-Date.now())})},1);return a!==null&&i.set(r,a),r}cancelIdleCallback(e){let t=receiver(this,`cancelIdleCallback`),n=t[Cn]?.get(e);n!==void 0&&(t[Cn].delete(e),t._cancelTask(n))}setTimeout(e,t,...n){let r=receiver(this,`setTimeout`);return startTimer(r,r._timerHost(),!1,e,t,n)}setInterval(e,t,...n){let r=receiver(this,`setInterval`);return startTimer(r,r._timerHost(),!0,e,t,n)}_timerHost(){let e=this[R];return typeof e.setTimeout==`function`?e:globalThis}_task(e,t){return this._schedule(this._timerHost(),e,t)}_schedule(e,t,n){if(this[pt])return null;let r=this[Yr]??=/* @__PURE__ */ new Set,i={handle:void 0,clear:e.clearTimeout,scheduledWith:e.setTimeout};return i.handle=e.setTimeout(()=>{r.delete(i),t.call(this)},n),r.add(i),i}_closeable(e){if(this[pt])return null;let t={handle:void 0,clear:e,scheduledWith:null};return(this[Yr]??=/* @__PURE__ */ new Set).add(t),t}_releaseCloseable(e){this[Yr]?.delete(e)}_cancelTask(e){this[Yr]?.delete(e)&&e.clear(e.handle)}postMessage(e,t,n){let r=receiver(this,`postMessage`),i=typeof t==`object`&&t?t.targetOrigin??`/`:t??`/`;if(i=String(i),i===`/`)i=r.origin;else if(i!==`*`){let e=URL.parse(i);if(e===null)throw new DOMException(`Failed to execute 'postMessage' on 'Window': Invalid target origin '${i}' in a call to 'postMessage'.`,`SyntaxError`);i=e.origin}if(i!==`*`&&i!==r.origin)return;let a=Array.isArray(n)?n:typeof t==`object`&&t?t.transfer:void 0,o,s;if(a===void 0||a.length===0)o=structuredClone(e);else{let t=structuredClone({message:e,transferred:a},{transfer:a});o=t.message;let n=globalThis.MessagePort;s=n===void 0?[]:t.transferred.filter(e=>e instanceof n)}let c=r.origin;r._task(function(){let e=eventInterface(`MessageEvent`);this.dispatchEvent(new e(`message`,{data:o,origin:c,source:this,ports:s}))},0)}reportError(e){reportException$1(e,receiver(this,`reportError`))}alert(e){reportNotImplemented(receiver(this,`alert`),qd.alert)}confirm(e){return reportNotImplemented(receiver(this,`confirm`),qd.confirm),!1}prompt(e,t){return reportNotImplemented(receiver(this,`prompt`),qd.prompt),null}print(){reportNotImplemented(receiver(this,`print`),qd.print)}open(e,t,n){return reportNotImplemented(receiver(this,`open`),qd.open),null}stop(){}focus(){reportNotImplemented(receiver(this,`focus`),qd.focus)}blur(){reportNotImplemented(receiver(this,`blur`),qd.blur)}captureEvents(){}releaseEvents(){}close(){if(this==null||this[pt]===void 0)return receiver(this,`close`).close();if(this[pt])return;this[pt]=!0,clearTimers(this);let e=this[Yr];if(e!==null){for(let t of e)t.clear(t.handle);e.clear()}if(this[dn]=null,this[Cr]=null,this[mn]=null,this[Cn]=null,this[Kn].clear(),this[zr]?.leave(),this[ct]!==null){for(let e of this[ct])e.close();this[ct]=null}this[ir]?.[ct]?.delete(this),currentWindowOrNull()===this&&setCurrentWindow(null)}_navigate(e,t){this.history._navigate(e,t)}_setURL(e){this[q]=e,this.document[q]=e.href}_getTheParent(e){return null}get[Symbol.toStringTag](){return`Window`}};function visualViewportGetter(){return this[ui]??=new VisualViewport(this)}let Kd=null;function setRenderingUpdateHook(e){Kd=e}function nextFrameDelay(e){if(!clockSkipping()||e[Cr]!==null)return 16;let t=e[hn];return t!==-1&&(e[R].performance??performance).now()-t<1?16:1}function frameTimers(e){return clockSkipping()&&e[R]!==globalThis?Ve:globalThis}function runAnimationFrame(){this[mn]=null,Kd!==null&&Kd(this.document);let e=this[dn];if(e===null)return;this[dn]=null,this[Cr]=e;let t=(this[R].performance??performance).now();this[hn]=t;for(let[n,r]of e)if(e.has(n))try{r.call(this,t)}catch(e){reportException$1(e,this)}this[Cr]=null}const qd={alert:stubbedMethod(`Window`,`alert`),blur:stubbedMethod(`Window`,`blur`),confirm:stubbedMethod(`Window`,`confirm`),focus:stubbedMethod(`Window`,`focus`),moveBy:stubbedMethod(`Window`,`moveBy`),moveTo:stubbedMethod(`Window`,`moveTo`),open:stubbedMethod(`Window`,`open`),print:stubbedMethod(`Window`,`print`),prompt:stubbedMethod(`Window`,`prompt`),resizeBy:stubbedMethod(`Window`,`resizeBy`),resizeTo:stubbedMethod(`Window`,`resizeTo`),scroll:stubbedMethod(`Window`,`scroll`),scrollBy:stubbedMethod(`Window`,`scrollBy`),scrollTo:stubbedMethod(`Window`,`scrollTo`)};function scrollWindow(e,t,n){typeof t==`object`&&t?(t.left!==void 0&&(e[Er]=normalizeScroll(t.left)),t.top!==void 0&&(e[Dr]=normalizeScroll(t.top))):t!==void 0&&(e[Er]=normalizeScroll(t),e[Dr]=normalizeScroll(n??0))}function resizeWindow(e,t,n){e[Mn]=t,e[jn]=n,e[Kn].size!==0&&reportMediaQueryChanges(e),e.dispatchEvent(new Event(`resize`))}function normalizeScroll(e){let t=Number(e);return Number.isFinite(t)?Math.max(0,t):0}const Jd=/* @__PURE__ */ `clearTimeout.clearInterval.queueMicrotask.structuredClone.atob.btoa.crypto.performance.console.URL.URLSearchParams.URLPattern.AbortController.Blob.File.TextEncoder.TextDecoder.TextEncoderStream.TextDecoderStream.ReadableStream.ReadableStreamDefaultReader.ReadableByteStreamController.WritableStream.WritableStreamDefaultWriter.TransformStream.ByteLengthQueuingStrategy.CountQueuingStrategy.CompressionStream.DecompressionStream.Headers.FormData.BroadcastChannel.MessageChannel.MessagePort.WebSocket.DOMException.QuotaExceededError.Crypto.CryptoKey.SubtleCrypto.PerformanceEntry.PerformanceMark.PerformanceMeasure.PerformanceObserver.PerformanceObserverEntryList.PerformanceResourceTiming.WebAssembly.Intl`.split(`.`);installEventHandlers(Window.prototype,`window`);const Yd=Object.freeze({visible:!0});for(let e of[`locationbar`,`menubar`,`personalbar`,`scrollbars`,`statusbar`,`toolbar`])Object.defineProperty(Window.prototype,e,{get:()=>Yd,enumerable:!0,configurable:!0});function preparePrototype(){Ud=!0;let e=Window.prototype;ensureInterfaces(e,{CSS:Ed,DOMStringList,AbortSignal:Ad});let t={};for(let n of Jd)n in e||(t[n]={get(){return this[R][n]??globalThis[n]},set(e){Object.defineProperty(this,n,{value:e,writable:!0,enumerable:!0,configurable:!0})},enumerable:!1,configurable:!0});Object.defineProperties(e,t)}function windowInterfaces(){return Ud||preparePrototype(),ensureInterfaces(Window.prototype,{CSS:Ed,DOMStringList,AbortSignal:Ad})}function createWindow(e){return new Window(e)}function createNestedWindow(e,t,n,r){let i=`about:blank`;r===null?n!==null&&n!==``&&(i=URL.parse(n,t.document.baseURI)?.href??`about:blank`):i=`about:srcdoc`;let a=new Window({url:i,width:t[Mn],height:t[jn],devicePixelRatio:t[Lt],userAgent:t[V].userAgent,layout:t[V].layout},{parent:t,frameElement:e,srcdoc:r});return(i===`about:blank`||i===`about:srcdoc`)&&(a.document[We]=t.document.baseURI),a}setNestedWindowFactory(createNestedWindow);function tabIndexValue(e){if(!(e.flags&8192))return NaN;let t=contentAttr(e,`tabindex`);if(t===null)return NaN;let n=parseInteger(t);return n>=-2147483648&&n<=2147483647?n:NaN}function isSummaryForParentDetails(e){let t=e.parent;if(t===null||t.tag!==Z.details||t.ns!==`http://www.w3.org/1999/xhtml`)return!1;for(let n=t.first;n!==null;n=n.next)if(n.type===1&&n.tag===Z.summary&&n.ns===`http://www.w3.org/1999/xhtml`)return n===e;return!1}function focusableByDefault(e){if(e.ns===`http://www.w3.org/1999/xhtml`){switch(e.tag){case Z.a:case Z.area:return contentAttr(e,`href`)!==null;case Z.button:case Z.select:case Z.textarea:case Z.iframe:case Z.frame:return!0;case Z.input:return contentAttr(e,`type`)?.toLowerCase()!==`hidden`;case Z.summary:return isSummaryForParentDetails(e);case Z.audio:case Z.video:return contentAttr(e,`controls`)!==null}return isEditingHost(e)}return e.ns===`http://www.w3.org/2000/svg`&&e.name===`a`&&(contentAttr(e,`href`)!==null||hasXlinkHref(e))}function hasXlinkHref(e){let t=e.attrs;if(t===null)return!1;for(let e=0;e<t.length;e++)if(t[e].localName===`href`&&t[e].ns===`http://www.w3.org/1999/xlink`)return!0;return!1}function defaultTabIndex(e){if(e.ns===`http://www.w3.org/1999/xhtml`){switch(e.tag){case Z.a:case Z.area:case Z.button:case Z.frame:case Z.iframe:case Z.input:case Z.object:case Z.select:case Z.textarea:return 0;case Z.summary:return isSummaryForParentDetails(e)?0:-1}return-1}return e.ns===`http://www.w3.org/2000/svg`&&e.name===`a`?0:-1}function isInert(e){for(let t=e;t!==null;t=parentOrHost(t))if(t.flags&262144&&t.type===1&&contentAttr(t,`inert`)!==null)return!0;return inertByModal(e)}function parentOrHost(e){let t=e.parent;if(t!==null)return t;if(e.flags&32){let t=e.node[R];return t===null?null:t[z]}return null}function hasTabIndexFocusFlag(e){return Number.isNaN(tabIndexValue(e))?focusableByDefault(e):e.ns===`http://www.w3.org/1999/xhtml`||e.ns===`http://www.w3.org/2000/svg`||e.ns===`http://www.w3.org/1998/Math/MathML`}function isFocusable(e){return e.type!==1||!(e.flags&1)||!hasTabIndexFocusFlag(e)||isActuallyDisabled(e)||isInert(e)?!1:!isRenderingHidden(e)}function isSequentiallyFocusable(e){if(!isFocusable(e))return!1;let t=tabIndexValue(e);return Number.isNaN(t)||t>=0}function shadowRootOf(e){return e.node[G]??null}function getFocusableArea(e){let t=shadowRootOf(e);if(t===null||!t.delegatesFocus)return null;let n=e.doc[L];return n!==null&&isShadowIncludingInclusiveAncestor$1(e,n)?n:focusDelegate(e)}function focusDelegate(e){let t=shadowRootOf(e);if(t!==null&&!t.delegatesFocus)return null;let n=t===null?e:t[z],r=autofocusDelegate(n);if(r!==null)return r;let i=e.tag===Z.dialog&&e.ns===`http://www.w3.org/1999/xhtml`;for(let e=n.first;e!==null;e=nextInTree(e,n)){if(e.type!==1)continue;let t;if(t=i&&isSequentiallyFocusable(e)||!i&&isFocusable(e)?e:getFocusableArea(e),t!==null)return t}return null}let Xd=!0;function focusElement(e,t){let n=e;if(n.tag===Z.dialog&&n.ns===`http://www.w3.org/1999/xhtml`&&!isFocusable(n)){if(!(n.flags&1)||isInert(n)||isRenderingHidden(n))return!1}else if(isFocusable(n)){let e=shadowRootOf(n);if(e!==null&&e.delegatesFocus){let e=n.doc[L];if(e!==null&&isShadowIncludingInclusiveAncestor$1(n,e))return!0;let t=focusDelegate(n);if(t===null)return!1;n=t}}else{if(!(n.flags&1))return!1;let e=getFocusableArea(n);if(e===null)return!1;n=e}let r=n.doc;focusContainerChain(r);let i=r[L];return i===n||(Xd=t?.focusVisible??!wasPointerFocus(n),runFocusUpdate(r,i,n),r[L]===n)}function containerOf(e){let t=e[Y]?.[fn]??null;return t===null?null:t[z]}function nestedDocument(e){return e.tag!==Z.iframe&&e.tag!==Z.frame?null:frameContentWindow(e.node)?.document??null}function focusContainerChain(e){let t=containerOf(e);if(t===null||!(t.flags&1))return;let n=t.doc;focusContainerChain(n),n[L]!==t&&runFocusUpdate(n,n[L],t,!1)}function blurElement(e){let t=e.doc,n=t[L];n!==null&&(n===e||isShadowIncludingInclusiveAncestor$1(e,n))&&runFocusUpdate(t,n,null)}function runFocusUpdate(e,t,n,r=!0){let i=e[Y];if(t!==null){let r=nestedDocument(t);r!==null&&r[L]!==null&&runFocusUpdate(r,r[L],null),e[L]=null;let a=t.node,o=n===null?null:n.node;if(fireFocusEvent(a,`blur`,o,!1,i),fireFocusEvent(a,`focusout`,o,!0,i),e[L]!==null)return}if(n===null||!(n.flags&1)||(e[L]=n,!r))return;let a=n.node,o=t===null?null:t.node;fireFocusEvent(a,`focus`,o,!1,i),e[L]===n&&fireFocusEvent(a,`focusin`,o,!0,i)}function isShadowIncludingInclusiveAncestor$1(e,t){for(let n=t;n!==null;n=parentOrHost(n))if(n===e)return!0;return!1}__name(isShadowIncludingInclusiveAncestor$1,`isShadowIncludingInclusiveAncestor`);let Zd=!1;function wasPointerFocus(e){return Zd?(Zd=!1,!(e.tag===Z.textarea||e.tag===Z.input||isEditingHost(e))):!1}function activeElement(e){let t=e.doc,n=t[L];if(e.type===11){for(;n!==null;){let t=treeRoot(n);if(t===e)return n.node;if(!(t.flags&32))return null;n=parentOrHost(t)}return null}if(n===null)return t.body??t.documentElement;for(;;){let e=treeRoot(n);if(!(e.flags&32))break;let t=parentOrHost(e);if(t===null)break;n=t}return n.node}function documentHasFocus(e){return e[L]!==null}function matchesFocus(e){let t=e.doc[L];if(t===null)return!1;if(t===e)return!0;if(shadowRootOf(e)===null)return!1;for(let n=t;n!==null;){let t=treeRoot(n);if(!(t.flags&32))return!1;if(n=parentOrHost(t),n===e)return!0}return!1}function matchesFocusWithin(e){let t=e.doc[L];return t!==null&&isShadowIncludingInclusiveAncestor$1(e,t)}function matchesFocusVisible(e){return e.doc[L]===e&&Xd}function autofocusDelegate(e){for(let t=e.first;t!==null;t=nextInTree(t,e)){if(t.type!==1||contentAttr(t,`autofocus`)===null)continue;let e=isFocusable(t)?t:getFocusableArea(t);if(e!==null)return e}return null}function focusFixup(e){let t=e[L];t===null||isFocusable(t)||t.tag===Z.dialog&&t.ns===`http://www.w3.org/1999/xhtml`&&t.flags&1&&!isInert(t)&&!isRenderingHidden(t)||runFocusUpdate(e,t,null)}setRenderingUpdateHook(focusFixup),setTopLayerFocusHooks(e=>{focusElement(e)},autofocusDelegate);function isReplaced$1(e){if(e.ns!==`http://www.w3.org/1999/xhtml`)return!1;switch(e.tag){case Z.img:case Z.canvas:case Z.video:case Z.audio:case Z.iframe:case Z.object:case Z.embed:case Z.input:case Z.textarea:case Z.meter:case Z.progress:case Z.frame:return!0}return!1}__name(isReplaced$1,`isReplaced`);function svgRendersContent(e){switch(e.name){case`svg`:case`g`:case`a`:case`switch`:case`text`:case`tspan`:case`textPath`:case`foreignObject`:return!0}return!1}function svgRendersText(e){let t=e.name;return t===`text`||t===`tspan`||t===`textPath`||t===`a`}function kindOf$1(e){switch(e){case`none`:return 0;case`inline`:case`contents`:case`ruby`:case`ruby-base`:case`ruby-text`:case`ruby-base-container`:case`ruby-text-container`:case`table-column`:case`table-column-group`:return 1;case`inline-block`:case`inline-flex`:case`inline-grid`:case`inline-table`:case`inline-flow-root`:case`inline list-item`:return 5;case`table-cell`:return 3;case`table-row`:return 4}return 2}__name(kindOf$1,`kindOf`);function isFlexOrGrid(e){return e===`flex`||e===`grid`||e===`inline-flex`||e===`inline-grid`}function boxKind(e,t){let n=kindOf$1(computedDisplay(e));if(n===0)return 0;if(e.ns===`http://www.w3.org/2000/svg`)return+!!svgRendersContent(e);if(e.ns!==`http://www.w3.org/1999/xhtml`)return n;if(t&&(n===1||n===5)){let t=e.parent;if(t!==null&&t.type===1&&isFlexOrGrid(computedDisplay(t)))n=2;else if(computedValue(e,`float`)!==`none`)n=2;else{let t=computedValue(e,`position`);(t===`absolute`||t===`fixed`)&&(n=2)}}return n}function isBeingRendered(e){if(!(e.flags&1))return!1;for(let t=e;t!==null&&t.type===1;t=t.parent){if(computedDisplay(t)===`none`)return!1;let e=t.parent;if(e!==null&&e.tag===Z.details&&e.ns===`http://www.w3.org/1999/xhtml`&&contentAttr(e,`open`)===null&&!(t.tag===Z.summary&&isFirstSummary(t)))return!1}return!0}function isFirstSummary(e){for(let t=e.parent.first;t!==null;t=t.next)if(t.type===1&&t.tag===Z.summary)return t===e;return!1}function whiteSpaceMode(e,t){if(t){let t=computedValue(e,`white-space`);return t===`pre-line`?1:t===`pre`||t===`pre-wrap`||t===`break-spaces`||t.startsWith(`preserve`)?2:0}for(let t=e;t!==null&&t.type===1;t=t.parent){if(t.ns!==`http://www.w3.org/1999/xhtml`)continue;let e=t.tag;if(e===Z.pre||e===Z.listing||e===Z.xmp||e===Z.plaintext||e===Z.textarea)return 2}return 0}function languageOf(e){for(let t=e;t!==null&&t.type===1;t=t.parent){let e=contentAttr(t,`lang`);if(e!==null)return e===``?void 0:e}}function upper(e,t){try{return e.toLocaleUpperCase(t)}catch{return e.toUpperCase()}}function transform(e,t){let n=computedValue(t,`text-transform`);if(n===``||n===`none`)return e;if(n.includes(`uppercase`))return upper(e,languageOf(t));if(n.includes(`lowercase`)){let n=languageOf(t);try{return e.toLocaleLowerCase(n)}catch{return e.toLowerCase()}}if(n.includes(`capitalize`)){let n=languageOf(t);return e.replace(/(^|[\s\-(["'])(\p{L})/gu,(e,t,r)=>t+upper(r,n))}return e}var Builder=class{parts=[];breaks=0;lastSpace=!0;trimmable=!1;styled;constructor(e){this.styled=e}text(e,t){if(e!==``){if(t===0){if(e=e.replace(/[ \t\n\f\r]+/g,` `),this.lastSpace&&e.charCodeAt(0)===32&&(e=e.slice(1)),e===``)return}else if(t===1){if(e=e.replace(/\r\n?/g,`
41
- `).replace(/[ \t\f]+/g,` `).replace(/ ?\n ?/g,`
42
- `),this.lastSpace&&e.charCodeAt(0)===32&&(e=e.slice(1)),e===``)return}else e=e.replace(/\r\n?/g,`
43
- `);this.flushBreaks(),this.parts.push(e),this.lastSpace=t!==2&&e.charCodeAt(e.length-1)===32,this.trimmable=this.lastSpace}}raw(e){this.trimTrailingSpace(),this.flushBreaks(),this.parts.push(e),this.lastSpace=!0,this.trimmable=!1}lineBreak(e){this.trimTrailingSpace(),e>this.breaks&&(this.breaks=e),this.lastSpace=!0}atomicStart(){return this.lastSpace=!0,this.parts.length}atomicEnd(e){this.parts.length>e&&this.trimTrailingSpace(),this.lastSpace=!1,this.trimmable=!1}flushBreaks(){this.breaks!==0&&(this.parts.length!==0&&this.parts.push(`
44
- `.repeat(this.breaks)),this.breaks=0)}trimTrailingSpace(){let e=this.parts,t=e.length-1;if(t>=0&&this.trimmable&&e[t].endsWith(` `)){let n=e[t].slice(0,-1);n===``?e.pop():e[t]=n}this.trimmable=!1}result(){return this.trimTrailingSpace(),this.parts.join(``)}};function isTableInternal(e){let t=computedDisplay(e);return t===`table`||t===`inline-table`||t===`table-row`||t===`table-row-group`||t===`table-header-group`||t===`table-footer-group`}function isWhitespaceOnly(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n!==32&&n!==9&&n!==10&&n!==12&&n!==13)return!1}return!0}function textRendered(e,t){if(e.ns===`http://www.w3.org/2000/svg`&&!svgRendersText(e))return!1;if(t){let t=computedVisibility(e);if(t===`hidden`||t===`collapse`)return!1}return!0}function collect$1(e,t){if(e.type===3||e.type===4){let n=e.parent;if(n===null||n.type!==1){t.text(e.data,0);return}if(!textRendered(n,t.styled)||isTableInternal(n)&&isWhitespaceOnly(e.data))return;t.text(t.styled?transform(e.data,n):e.data,whiteSpaceMode(n,t.styled));return}if(e.type!==1)return;let n=boxKind(e,t.styled);if(n===0)return;let r=e.ns===E;if(r&&e.tag===Z.br){t.raw(`
45
- `);return}if(r&&e.tag===Z.select){collectOptions(e,t);return}if(isReplaced$1(e)){n===2?t.lineBreak(1):t.atomicEnd(t.atomicStart());return}if(r&&e.tag===Z.details&&contentAttr(e,`open`)===null){t.lineBreak(1);for(let n=e.first;n!==null;n=n.next)if(n.type===1&&n.tag===Z.summary){collect$1(n,t);break}t.lineBreak(1);return}let i=r&&e.tag===Z.p;if(n===5){i&&t.lineBreak(2);let n=t.atomicStart();for(let n=e.first;n!==null;n=n.next)collect$1(n,t);t.atomicEnd(n),i&&t.lineBreak(2)}else{i?t.lineBreak(2):n===2&&t.lineBreak(1);for(let n=e.first;n!==null;n=n.next)collect$1(n,t);n===3?isLastOfKind(e,3,t.styled)||t.raw(` `):n===4&&(isLastRow(e,t.styled)||t.raw(`
46
- `)),i?t.lineBreak(2):n===2&&t.lineBreak(1)}}__name(collect$1,`collect`);function collectOptions(e,t){for(let n=e.first;n!==null;)n.type===1&&n.ns===`http://www.w3.org/1999/xhtml`&&n.tag===Z.option?(collect$1(n,t),n=nextSkippingChildren(n,e)):(n.type===1&&n.ns===`http://www.w3.org/1999/xhtml`&&n.tag===Z.optgroup&&t.lineBreak(1),n=nextInTree(n,e))}function isLastOfKind(e,t,n){for(let r=e.next;r!==null;r=r.next)if(r.type===1&&boxKind(r,n)===t)return!1;return!0}function isLastRow(e,t){let n=e.parent;for(;n!==null&&n.type===1&&computedDisplay(n)!==`table`&&computedDisplay(n)!==`inline-table`;)n=n.parent;if(n===null||n.type!==1)return isLastOfKind(e,4,t);let r=null;for(let e=n.first;e!==null;e=nextInTree(e,n))e.type===1&&boxKind(e,t)===4&&(r=e);return r===e}function descendantText(e){let t=``;for(let n=e.first;n!==null;n=nextInTree(n,e))(n.type===3||n.type===4)&&(t+=n.data);return t}function getInnerText(e){if(!isBeingRendered(e))return descendantText(e);if(isReplaced$1(e))return``;let t=new Builder(hasAuthorStyles(e.doc));if(e.ns===`http://www.w3.org/1999/xhtml`&&e.tag===Z.select)collectOptions(e,t);else for(let n=e.first;n!==null;n=n.next)collect$1(n,t);return t.result()}function renderedTextFragment(e,t){let n=t.doc,r=n.createDocumentFragment(),i=e.split(/\r\n|\r|\n/);for(let e=0;e<i.length;e++)e>0&&r.appendChild(n.createElement(`br`)),i[e]!==``&&r.appendChild(n.createTextNode(i[e]));return r}const Qd=`role ariaAtomic=aria-atomic ariaAutoComplete=aria-autocomplete ariaBrailleLabel=aria-braillelabel ariaBrailleRoleDescription=aria-brailleroledescription ariaBusy=aria-busy ariaChecked=aria-checked ariaColCount=aria-colcount ariaColIndex=aria-colindex ariaColIndexText=aria-colindextext ariaColSpan=aria-colspan ariaCurrent=aria-current ariaDescription=aria-description ariaDisabled=aria-disabled ariaExpanded=aria-expanded ariaHasPopup=aria-haspopup ariaHidden=aria-hidden ariaInvalid=aria-invalid ariaKeyShortcuts=aria-keyshortcuts ariaLabel=aria-label ariaLevel=aria-level ariaLive=aria-live ariaModal=aria-modal ariaMultiLine=aria-multiline ariaMultiSelectable=aria-multiselectable ariaOrientation=aria-orientation ariaPlaceholder=aria-placeholder ariaPosInSet=aria-posinset ariaPressed=aria-pressed ariaReadOnly=aria-readonly ariaRelevant=aria-relevant ariaRequired=aria-required ariaRoleDescription=aria-roledescription ariaRowCount=aria-rowcount ariaRowIndex=aria-rowindex ariaRowIndexText=aria-rowindextext ariaRowSpan=aria-rowspan ariaSelected=aria-selected ariaSetSize=aria-setsize ariaSort=aria-sort ariaValueMax=aria-valuemax ariaValueMin=aria-valuemin ariaValueNow=aria-valuenow ariaValueText=aria-valuetext`,$d=[[`ariaActiveDescendantElement`,`aria-activedescendant`]],ef=[[`ariaControlsElements`,`aria-controls`],[`ariaDescribedByElements`,`aria-describedby`],[`ariaDetailsElements`,`aria-details`],[`ariaErrorMessageElements`,`aria-errormessage`],[`ariaFlowToElements`,`aria-flowto`],[`ariaLabelledByElements`,`aria-labelledby`],[`ariaOwnsElements`,`aria-owns`]],tf=/* @__PURE__ */ new WeakMap,nf=/* @__PURE__ */ new WeakMap;function findRecord(e,t){let n=e.attrs;if(n===null)return null;for(let e=0;e<n.length;e++){let r=n[e];if(r.localName===t&&(r.rare===null||r.rare.ns===null))return r}return null}function liveExplicit(e,t){let n=tf.get(e);if(n===void 0)return null;let r=n.get(t);return r===void 0?null:findRecord(e,t)===r.record&&r.record.value===``?r:(n.delete(t),null)}function setExplicit(e,t,n){setAttribute(e,t,``);let r=tf.get(e);r===void 0&&tf.set(e,r=/* @__PURE__ */ new Map),r.set(t,{record:findRecord(e,t),elements:n,cached:null})}function clearExplicit(e,t){tf.get(e)?.delete(t),removeAttribute(e,t)}function shadowIncludingParent(e){return e.parent===null?isShadowRootImpl(e)?e.node[R]?.[z]??null:null:e.parent}function isValidReference(e,t){let n=t;for(;n.parent!==null;)n=n.parent;if(n===t)return!1;for(let t=shadowIncludingParent(e);t!==null;t=shadowIncludingParent(t))if(t===n)return!0;return!1}function firstById(e,t){if(t===``)return null;let n=e;for(;n.parent!==null;)n=n.parent;if(n.type===9)return n.node._idLookup(t);if(n.type===1&&n.id===t)return n;for(let e=nextElementInTree(n,n);e!==null;e=nextElementInTree(e,n))if(e.id===t)return e;return null}function attrAssociatedElement(e,t){let n=liveExplicit(e,t);if(n!==null){let t=n.elements[0]?.deref()??null;return t!==null&&isValidReference(e,t)?t:null}let r=findRecord(e,t)?.value;return r===void 0?null:firstById(e,r)}function attrAssociatedElements(e,t){let n=liveExplicit(e,t),r=[];if(n!==null){for(let t of n.elements){let n=t.deref();n!==void 0&&isValidReference(e,n)&&r.push(n)}return r}let i=findRecord(e,t)?.value;if(i===void 0)return null;for(let t of splitOnAsciiWhitespace(i)){let n=firstById(e,t);n!==null&&r.push(n)}return r}function hasExplicitAttrElements(e,t){return liveExplicit(e,t)!==null}function sameContents(e,t){if(e.length!==t.length)return!1;for(let n=0;n<t.length;n++)if(e[n]!==t[n].node)return!1;return!0}function toElement(e,t){if(!(e instanceof Rs))throw TypeError(`Failed to set the '${t}' property on 'Element': Failed to convert value to 'Element'.`);return e[z]}for(let[e,t]of $d)defineAccessor(Rs,e,function(){return attrAssociatedElement(this[z],t)?.node??null},function(n){n==null?clearExplicit(this[z],t):setExplicit(this[z],t,[new WeakRef(toElement(n,e))])});for(let[e,t]of ef)defineAccessor(Rs,e,function(){let e=this[z],n=attrAssociatedElements(e,t);if(n===null)return null;let r=liveExplicit(e,t),i=(r===null?nf.get(e)?.get(t):r.cached)?.deref();if(i!==void 0&&sameContents(i,n))return i;let a=Object.freeze(n.map(e=>e.node)),o=new WeakRef(a);if(r!==null)r.cached=o;else{let n=nf.get(e);n===void 0&&nf.set(e,n=/* @__PURE__ */ new Map),n.set(t,o)}return a},function(n){let r=this[z];if(n==null){clearExplicit(r,t);return}if(typeof n!=`object`||typeof n[Symbol.iterator]!=`function`)throw TypeError(`Failed to set the '${e}' property on 'Element': The provided value cannot be converted to a sequence.`);let i=[];for(let t of n)i.push(new WeakRef(toElement(t,e)));setExplicit(r,t,i)});nullableStr(Rs,Qd);const rf=/* @__PURE__ */ new WeakSet;var HTMLElement=class extends Rs{constructor(e,t,n,r){if(e!==void 0){super(e,t,n,r),this[z].flags&128&&(this[z].flags|=4);return}let i=htmlElementConstructorSteps(new.target);if(i.upgrade!==null)return i.upgrade;super(i.doc,i.localName,E,null),initNewCustomElement(this,i.def,i.active)}_connectedSteps(){let e=this[z];(e.flags&128||isValueOf(this)!==null)&&ceConnected(this),e.flags&16384&&faceStateMaybeChanged(e)}_disconnectedSteps(){let e=this[z];(isPopoverShowing(e)||isInTopLayer(e))&&topLayerRemovingSteps(e),definitionOf(this)!==void 0&&ceDisconnected(this),clearParserAssociation(e),e.flags&16384&&faceStateMaybeChanged(e)}_adoptingSteps(e){ceAdopted(this,e,this[z].doc)}_movingSteps(e,t){definitionOf(this)!==void 0&&ceMoved(this)}_shadowDisabled(){return shadowDisabled(this)}_parserAssociateForm(e){parserAssociateForm(this[z],e[z])}_attributeChangedSteps(e,t,n,r){e===`popover`&&r===null&&popoverAttributeChanged(this[z],t,n),definitionOf(this)!==void 0&&ceAttributeChanged(this,e,t,n,r),this[z].flags&16384&&r===null&&(e===`form`||e===`disabled`)&&faceStateMaybeChanged(this[z])}get style(){return this[Wr]??=new CSSStyleDeclaration(this)}set style(e){this.style.cssText=String(e)}get translate(){for(let e=this[z];e!==null&&e.type===1;e=e.parent){let t=contentAttr(e,`translate`);if(t===null)continue;let n=asciiLowercase$1(t);if(n===``||n===`yes`)return!0;if(n===`no`)return!1}return!0}set translate(e){setAttribute(this[z],`translate`,e?`yes`:`no`)}get hidden(){return contentAttr(this[z],`hidden`)!==null}set hidden(e){typeof e==`string`&&asciiLowercase$1(e)===`until-found`?setAttribute(this[z],`hidden`,`until-found`):e===!1||e===``||e==null||e===0||Number.isNaN(e)?removeAttribute(this[z],`hidden`):setAttribute(this[z],`hidden`,``)}get accessKeyLabel(){let e=contentAttr(this[z],`accesskey`);if(e===null)return``;let t=e.replace(/^[\t\n\f\r ]+|[\t\n\f\r ]+$/g,``);return t===``||t.length>2||t.length===2&&t.codePointAt(0)<=65535?``:`Alt+Shift+`+t.toUpperCase()}get draggable(){let e=contentAttr(this[z],`draggable`);if(e!==null){let t=asciiLowercase$1(e);if(t===`true`)return!0;if(t===`false`)return!1}let t=this[z];return t.tag===Z.img||t.tag===Z.a&&contentAttr(t,`href`)!==null}set draggable(e){setAttribute(this[z],`draggable`,e?`true`:`false`)}get spellcheck(){for(let e=this[z];e!==null&&e.type===1;e=e.parent){let t=contentAttr(e,`spellcheck`);if(t===null)continue;let n=asciiLowercase$1(t);if(n===``||n===`true`)return!0;if(n===`false`)return!1}return!0}set spellcheck(e){setAttribute(this[z],`spellcheck`,e?`true`:`false`)}get autocorrect(){return usedAutocorrection(this[z])}set autocorrect(e){setAttribute(this[z],`autocorrect`,e?`on`:`off`)}get contentEditable(){let e=this[z];if(!(e.flags&131072))return`inherit`;let t=contentAttr(e,`contenteditable`);if(t===null)return`inherit`;let n=asciiLowercase$1(t);return n===``||n===`true`?`true`:n===`false`?`false`:n===`plaintext-only`?`plaintext-only`:`inherit`}set contentEditable(e){let t=asciiLowercase$1(String(e));if(t===`inherit`)removeAttribute(this[z],`contenteditable`);else if(t===`true`||t===`false`||t===`plaintext-only`)setAttribute(this[z],`contenteditable`,t);else throw new DOMException(`Failed to set the 'contentEditable' property on 'HTMLElement': The value provided ('${e}') is not one of 'true', 'false', 'plaintext-only', or 'inherit'.`,`SyntaxError`)}get isContentEditable(){return isEditable(this[z])}get innerText(){return getInnerText(this[z])}set innerText(e){let t=e===null?``:String(e);this._replaceAll(t===``?null:renderedTextFragment(t,this[z]))}get outerText(){return getInnerText(this[z])}set outerText(e){let t=this.parentNode;if(t===null)throw new DOMException(`The element has no parent.`,`NoModificationAllowedError`);let n=this.previousSibling,r=this.nextSibling,i=renderedTextFragment(e===null?``:String(e),this[z]);i.hasChildNodes()||i.appendChild(this[z].doc.createTextNode(``)),t.replaceChild(i,this),r!==null&&r.nodeType===3&&mergeWithPrevious(r),n!==null&&n.nodeType===3&&n.nextSibling!==null&&mergeWithPrevious(n.nextSibling)}click(){if(!isActuallyDisabled(this[z])&&!rf.has(this)){rf.add(this);try{fireSyntheticClick(this)}finally{rf.delete(this)}}}showPopover(e){let t=this[z];t.flags|=12,showPopover(t,!0,popoverSource(e))}hidePopover(){hidePopover(this[z],!0,!0,!0,null)}togglePopover(e){let t=null,n=null;typeof e==`boolean`?t=e:typeof e==`object`&&e?(e.force!==void 0&&(t=!!e.force),n=popoverSource(e)):e!=null&&(t=!!e);let r=this[z];r.flags|=12;let i=isPopoverShowing(r);return i&&t!==!0?hidePopover(r,!0,!0,!0,null):t===null||t?showPopover(r,!0,n):checkPopoverValidity(r,i,null),isPopoverShowing(r)}attachInternals(){if(isValueOf(this)!==null)throw new DOMException(`Unable to attach ElementInternals to a customized built-in element.`,`NotSupportedError`);let e=definitionOf(this);if(e===void 0)throw new DOMException(`Unable to attach ElementInternals to non-custom elements.`,`NotSupportedError`);if(e.disableInternals)throw new DOMException(`ElementInternals is disabled by disabledFeature static field.`,`NotSupportedError`);if(af.has(this))throw new DOMException(`ElementInternals for the specified element was already attached.`,`NotSupportedError`);let t=new ElementInternals(this);return af.set(this,t),t}get offsetParent(){return null}get offsetTop(){return 0}get offsetLeft(){return 0}get offsetWidth(){return 0}get offsetHeight(){return 0}};function inheritsAutocapitalizeAndAutocorrect(e){if(e.ns!==`http://www.w3.org/1999/xhtml`)return!1;let t=e.tag;return t===Z.button||t===Z.fieldset||t===Z.input||t===Z.output||t===Z.select||t===Z.textarea}function autocapitalizeState(e){let t=contentAttr(e,`autocapitalize`);if(t===null)return``;switch(asciiLowercase$1(t)){case``:return``;case`off`:case`none`:return`none`;case`on`:case`sentences`:return`sentences`;case`words`:return`words`;case`characters`:return`characters`}return`sentences`}function ownAutocapitalizationHint(e){let t=autocapitalizeState(e);if(t!==``)return t;if(inheritsAutocapitalizeAndAutocorrect(e)){let t=formOwner(e);if(t!==null)return ownAutocapitalizationHint(t)}return``}function autocorrectState(e){let t=contentAttr(e,`autocorrect`);return t===null?-1:asciiLowercase$1(t)===`off`?0:1}function usedAutocorrection(e){if(e.ns===`http://www.w3.org/1999/xhtml`&&e.tag===Z.input){let t=inputType(e);if(t===4||t===5||t===6)return!1}let t=autocorrectState(e);if(t!==-1)return t===1;if(inheritsAutocapitalizeAndAutocorrect(e)){let t=formOwner(e);if(t!==null)return autocorrectState(t)!==0}return!0}function computedWritingSuggestions(e){for(let t=e;t!==null&&t.type===1;t=t.parent){let e=contentAttr(t,`writingsuggestions`);if(e!==null)return asciiLowercase$1(e)!==`false`}return!0}function mergeWithPrevious(e){let t=e.previousSibling;t!==null&&t.nodeType===3&&(t.data+=e.data,e.remove())}str(HTMLElement,`title lang accessKey=accesskey`),bool(HTMLElement,`inert`),deferCompatMember(HTMLElement.prototype,`HTMLElement`,`inert`),enumerated(HTMLElement,`dir`,{keywords:[`ltr`,`rtl`,`auto`]}),defineAccessor(HTMLElement,`autocapitalize`,function(){return ownAutocapitalizationHint(this[z])},function(e){setAttribute(this[z],`autocapitalize`,String(e))}),defineAccessor(HTMLElement,`writingSuggestions`,function(){return computedWritingSuggestions(this[z])?`true`:`false`},function(e){setAttribute(this[z],`writingsuggestions`,String(e))}),enumerated(HTMLElement,`enterKeyHint=enterkeyhint`,{keywords:[`enter`,`done`,`go`,`next`,`previous`,`search`,`send`]}),enumerated(HTMLElement,`inputMode=inputmode`,{keywords:[`none`,`text`,`tel`,`url`,`email`,`numeric`,`decimal`,`search`]}),enumerated(HTMLElement,`popover`,{keywords:[`auto`,`manual`,`hint`],missing:null,invalid:`manual`,empty:`auto`});const af=/* @__PURE__ */ new WeakMap;function customStatesOf(e){return af.get(e)?.[Ur]??null}var ElementInternals=class{[Jr];[Ur];[li];constructor(e){if(!(e instanceof HTMLElement)||af.has(e))throw TypeError(`Illegal constructor`);this[Jr]=e,this[Ur]=null,this[li]=null}get shadowRoot(){let e=this[Jr][G];return e==null||!e[Ye]?null:e}get states(){return this[Ur]??=new CustomStateSet}get form(){return internalsForm(this[Jr][z])}get labels(){return internalsLabels(this[Jr][z])}get willValidate(){return internalsWillValidate(this[Jr][z])}get validity(){return internalsValidity(this[Jr][z])}get validationMessage(){return internalsValidationMessage(this[Jr][z])}setFormValue(e,t){internalsSetFormValue(this[Jr][z],e,t),this[li]=e}setValidity(e,t,n){internalsSetValidity(this[Jr][z],e,t,n)}checkValidity(){return internalsCheckValidity(this[Jr][z])}reportValidity(){return internalsCheckValidity(this[Jr][z],`reportValidity`)}};const of=/* @__PURE__ */ new WeakMap;for(let e of Qd.split(` `)){let t=e.indexOf(`=`),n=t===-1?e:e.slice(0,t),r=t===-1?e:e.slice(t+1);Object.defineProperty(ElementInternals.prototype,n,{get(){return of.get(this)?.get(r)??null},set(e){let t=of.get(this);e==null?t?.delete(r):(t===void 0&&of.set(this,t=/* @__PURE__ */ new Map),t.set(r,String(e)))},configurable:!0,enumerable:!0})}const sf=/* @__PURE__ */ new WeakMap;for(let[e,t]of[[`ariaActiveDescendantElement`,!1],[`ariaControlsElements`,!0],[`ariaDescribedByElements`,!0],[`ariaDetailsElements`,!0],[`ariaErrorMessageElements`,!0],[`ariaFlowToElements`,!0],[`ariaLabelledByElements`,!0],[`ariaOwnsElements`,!0]]){let toElement=t=>{if(!(t instanceof Rs))throw TypeError(`Failed to set the '${e}' property on 'ElementInternals': Failed to convert value to 'Element'.`);return t};Object.defineProperty(ElementInternals.prototype,e,{get(){let n=sf.get(this)?.get(e);if(n===void 0)return null;if(!t)return n.refs[0]?.deref()??null;let r=n.cached?.deref();if(r!==void 0)return r;let i=[];for(let e of n.refs){let t=e.deref();t!==void 0&&i.push(t)}let a=Object.freeze(i);return n.cached=new WeakRef(a),a},set(n){let r=sf.get(this);if(n==null){r?.delete(e);return}let i;if(!t)i=[new WeakRef(toElement(n))];else{if(typeof n!=`object`||typeof n[Symbol.iterator]!=`function`)throw TypeError(`Failed to set the '${e}' property on 'ElementInternals': The provided value cannot be converted to a sequence.`);i=[];for(let e of n)i.push(new WeakRef(toElement(e)))}r===void 0&&sf.set(this,r=/* @__PURE__ */ new Map),r.set(e,{refs:i,cached:null})},configurable:!0,enumerable:!0})}var CustomStateSet=class extends Set{};const cf=Symbol(`nonce`);function installHTMLOrSVGElement(e){installEventHandlers(e.prototype,`element`),defineAccessor(e,`nonce`,function(){let e=this[cf],t=contentAttr(this[z],`nonce`);return e!==void 0&&e[1]===t?e[0]:t??``},function(e){Object.defineProperty(this,cf,{value:[String(e),contentAttr(this[z],`nonce`)],writable:!0,configurable:!0})}),bool(e,`autofocus`),defineAccessor(e,`tabIndex`,function(){let e=tabIndexValue(this[z]);return Number.isNaN(e)?defaultTabIndex(this[z]):e},function(e){setAttribute(this[z],`tabindex`,String(Number(e)|0))}),Object.defineProperty(e.prototype,"focus",{value:function focus(e){focusElement(this[z],e)},writable:!0,configurable:!0,enumerable:!0}),Object.defineProperty(e.prototype,"blur",{value:function blur(){blurElement(this[z])},writable:!0,configurable:!0,enumerable:!0})}installHTMLOrSVGElement(HTMLElement);for(let e of[Q,ShadowRoot])Object.hasOwn(e.prototype,`activeElement`)||defineAccessor(e,`activeElement`,function(){return activeElement(this[z])});Object.hasOwn(Q.prototype,`hasFocus`)||Object.defineProperty(Q.prototype,"hasFocus",{value:function hasFocus(){return documentHasFocus(this)},writable:!0,configurable:!0,enumerable:!0});function popoverSource(e){if(typeof e!=`object`||!e)return null;let t=e.source;if(t===void 0)return null;if(!(t instanceof HTMLElement))throw TypeError(`Failed to read the 'source' property from the options: The provided value is not of type 'HTMLElement'.`);return t[z]}const lf=class HTMLCollection$1 extends io{static{__name(this,`HTMLCollection`)}constructor(e,t){super(e,!1,null,!0),Object.defineProperty(this,Zt,{value:t})}_collect(e){this[Zt](this._s.root,e)}};function fnCollection(e,t){return new lf(e,t)}function sameObject(e,t,n){let r=e[t];return r===void 0&&(r=n(),Object.defineProperty(e,t,{value:r})),r}var HTMLHtmlElement=class extends HTMLElement{};str(HTMLHtmlElement,`version`);var HTMLHeadElement=class extends HTMLElement{},HTMLBaseElement=class extends HTMLElement{get href(){let e=this[z],t=contentAttr(e,`href`)??``,n=URL.parse(t,e.doc.URL);return n===null?t:n.href}set href(e){setAttribute(this[z],`href`,String(e))}};str(HTMLBaseElement,`target`);var HTMLMetaElement=class extends HTMLElement{};str(HTMLMetaElement,`name httpEquiv=http-equiv content media scheme`);var HTMLBodyElement=class extends HTMLElement{};installEventHandlers(HTMLBodyElement.prototype,`body`),strNullEmpty(HTMLBodyElement,`text link vLink=vlink aLink=alink bgColor=bgcolor`),str(HTMLBodyElement,`background`);var HTMLHeadingElement=class extends HTMLElement{};str(HTMLHeadingElement,`align`);var HTMLParagraphElement=class extends HTMLElement{};str(HTMLParagraphElement,`align`);var HTMLHRElement=class extends HTMLElement{};str(HTMLHRElement,`align color size width`),bool(HTMLHRElement,`noShade=noshade`);var HTMLPreElement=class extends HTMLElement{};long(HTMLPreElement,`width`);var HTMLQuoteElement=class extends HTMLElement{};url(HTMLQuoteElement,`cite`);var HTMLOListElement=class extends HTMLElement{};bool(HTMLOListElement,`reversed compact`),long(HTMLOListElement,`start`,1),str(HTMLOListElement,`type`);var HTMLUListElement=class extends HTMLElement{};bool(HTMLUListElement,`compact`),str(HTMLUListElement,`type`);var HTMLMenuElement=class extends HTMLElement{};bool(HTMLMenuElement,`compact`);var HTMLLIElement=class extends HTMLElement{};long(HTMLLIElement,`value`),str(HTMLLIElement,`type`);var HTMLDListElement=class extends HTMLElement{};bool(HTMLDListElement,`compact`);var HTMLDivElement=class extends HTMLElement{};str(HTMLDivElement,`align`);var HTMLDataElement=class extends HTMLElement{};str(HTMLDataElement,`value`);var HTMLTimeElement=class extends HTMLElement{};str(HTMLTimeElement,`dateTime=datetime`);var HTMLSpanElement=class extends HTMLElement{},HTMLBRElement=class extends HTMLElement{};str(HTMLBRElement,`clear`);var HTMLModElement=class extends HTMLElement{};url(HTMLModElement,`cite`),str(HTMLModElement,`dateTime=datetime`);var HTMLPictureElement=class extends HTMLElement{},HTMLSourceElement=class extends HTMLElement{};url(HTMLSourceElement,`src`),str(HTMLSourceElement,`type srcset sizes media`),ulong(HTMLSourceElement,`width height`);var HTMLImageElement=class extends HTMLElement{get complete(){let e=this[z];if(contentAttr(e,`srcset`)!==null)return!1;let t=contentAttr(e,`src`);return t===null||t===``}get naturalWidth(){return 0}get naturalHeight(){return 0}get currentSrc(){return this.src}get x(){return 0}get y(){return 0}get width(){return dimension(this[z],`width`)}set width(e){setAttribute(this[z],`width`,String(clampUlong(e)))}get height(){return dimension(this[z],`height`)}set height(e){setAttribute(this[z],`height`,String(clampUlong(e)))}decode(){return Promise.resolve()}};str(HTMLImageElement,`alt srcset sizes useMap=usemap name align`),strNullEmpty(HTMLImageElement,`border`),url(HTMLImageElement,`src longDesc=longdesc lowsrc`),enumerated(HTMLImageElement,`crossOrigin=crossorigin`,vc),bool(HTMLImageElement,`isMap=ismap`),ulong(HTMLImageElement,`hspace vspace`),enumerated(HTMLImageElement,`referrerPolicy=referrerpolicy`,yc),enumerated(HTMLImageElement,`decoding`,{keywords:[`sync`,`async`,`auto`],missing:`auto`,invalid:`auto`}),enumerated(HTMLImageElement,`loading`,bc),enumerated(HTMLImageElement,`fetchPriority=fetchpriority`,xc);function clampUlong(e){let t=Number(e)>>>0;return t>2147483647?0:t}function dimension(e,t){let n=contentAttr(e,t);if(n===null)return 0;let r=Number.parseInt(n,10);return Number.isFinite(r)&&r>=0?r:0}const uf=function Image(e,t){if(new.target===void 0)throw TypeError(`Failed to construct 'Image': Please use the 'new' operator.`);let n=currentDocument().createElementNS(E,`img`);return e!==void 0&&setAttribute(n[z],`width`,String(Number(e)>>>0)),t!==void 0&&setAttribute(n[z],`height`,String(Number(t)>>>0)),n};uf.prototype=HTMLImageElement.prototype;var HTMLIFrameElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=4}_connectedSteps(){super._connectedSteps(),frameConnected(this)}_disconnectedSteps(){super._disconnectedSteps(),frameDisconnected(this)}get contentDocument(){return frameContentWindow(this)?.document??null}get contentWindow(){return frameContentWindow(this)}getSVGDocument(){return null}};url(HTMLIFrameElement,`src longDesc=longdesc`),str(HTMLIFrameElement,`srcdoc name allow width height align scrolling frameBorder=frameborder`),strNullEmpty(HTMLIFrameElement,`marginHeight=marginheight marginWidth=marginwidth`),tokenList(HTMLIFrameElement,`sandbox`,`sandbox`,[`allow-downloads`,`allow-forms`,`allow-modals`,`allow-orientation-lock`,`allow-pointer-lock`,`allow-popups`,`allow-popups-to-escape-sandbox`,`allow-presentation`,`allow-same-origin`,`allow-scripts`,`allow-top-navigation`,`allow-top-navigation-by-user-activation`,`allow-top-navigation-to-custom-protocols`]),bool(HTMLIFrameElement,`allowFullscreen=allowfullscreen`),enumerated(HTMLIFrameElement,`referrerPolicy=referrerpolicy`,yc),enumerated(HTMLIFrameElement,`loading`,bc);var HTMLEmbedElement=class extends HTMLElement{getSVGDocument(){return null}};url(HTMLEmbedElement,`src`),str(HTMLEmbedElement,`type width height align name`);var HTMLObjectElement=class extends HTMLElement{get contentDocument(){return null}get contentWindow(){return null}getSVGDocument(){return null}get form(){let e=formOwner(this[z]);return e===null?null:e.node}_barredFromValidation(){return!0}_validityFlags(){return this[kt]?512:0}_validationMessage(e){return this[kt]??``}};installConstraintValidation(HTMLObjectElement),url(HTMLObjectElement,`data codeBase=codebase`),str(HTMLObjectElement,`type name useMap=usemap width height align archive code standby codeType=codetype`),strNullEmpty(HTMLObjectElement,`border`),bool(HTMLObjectElement,`declare`),ulong(HTMLObjectElement,`hspace vspace`);var HTMLParamElement=class extends HTMLElement{};str(HTMLParamElement,`name value type valueType=valuetype`);var HTMLTrackElement=class extends HTMLElement{static NONE=0;static LOADING=1;static LOADED=2;static ERROR=3;get readyState(){return 0}get track(){return null}};defineConstants(HTMLTrackElement,{NONE:0,LOADING:1,LOADED:2,ERROR:3}),enumerated(HTMLTrackElement,`kind`,{keywords:[`subtitles`,`captions`,`descriptions`,`chapters`,`metadata`],missing:`subtitles`,invalid:`metadata`}),url(HTMLTrackElement,`src`),str(HTMLTrackElement,`srclang label`),bool(HTMLTrackElement,`default`);var HTMLMapElement=class extends HTMLElement{get areas(){return sameObject(this,df,()=>fnCollection(this[z],(e,t)=>{for(let n=nextElementInTree(e,e);n!==null;n=nextElementInTree(n,e))n.tag===Z.area&&n.ns===`http://www.w3.org/1999/xhtml`&&t.push(n.node)}))}};const df=Symbol(`areas`);str(HTMLMapElement,`name`);var HTMLCanvasElement=class extends HTMLElement{getContext(e,t){return null}toDataURL(e,t){return`data:,`}toBlob(e){queueElementTask(this,()=>e(null))}};ulong(HTMLCanvasElement,`width`,300),ulong(HTMLCanvasElement,`height`,150);function childOfType(e,t){for(let n=e.first;n!==null;n=n.next)if(n.type===1&&n.tag===t&&n.ns===`http://www.w3.org/1999/xhtml`)return n;return null}function hierarchyError(e){return new DOMException(e,`HierarchyRequestError`)}function indexError(e){return new DOMException(`The index provided (${e}) is outside the valid range.`,`IndexSizeError`)}const ff=Symbol(`rows`),pf=Symbol(`tBodies`),mf=Symbol(`cells`);function fillTableRows(e,t){for(let n=e.first;n!==null;n=n.next)n.type===1&&n.tag===Z.thead&&n.ns===`http://www.w3.org/1999/xhtml`&&pushRows(n,t);for(let n=e.first;n!==null;n=n.next)n.type===1&&n.ns===`http://www.w3.org/1999/xhtml`&&(n.tag===Z.tr?t.push(n.node):n.tag===Z.tbody&&pushRows(n,t));for(let n=e.first;n!==null;n=n.next)n.type===1&&n.tag===Z.tfoot&&n.ns===`http://www.w3.org/1999/xhtml`&&pushRows(n,t)}function pushRows(e,t){for(let n=e.first;n!==null;n=n.next)n.type===1&&n.tag===Z.tr&&n.ns===`http://www.w3.org/1999/xhtml`&&t.push(n.node)}var HTMLTableElement=class extends HTMLElement{get caption(){let e=childOfType(this[z],Z.caption);return e===null?null:e.node}set caption(e){let t=childOfType(this[z],Z.caption);t!==null&&this.removeChild(t.node),e!==null&&this.insertBefore(e,this.firstChild)}createCaption(){let e=childOfType(this[z],Z.caption);if(e!==null)return e.node;let t=this[z].doc.createElement(`caption`);return this.insertBefore(t,this.firstChild),t}deleteCaption(){let e=childOfType(this[z],Z.caption);e!==null&&this.removeChild(e.node)}get tHead(){let e=childOfType(this[z],Z.thead);return e===null?null:e.node}set tHead(e){if(e!==null&&e[z].tag!==Z.thead)throw hierarchyError(`Not a thead element.`);let t=childOfType(this[z],Z.thead);t!==null&&this.removeChild(t.node),e!==null&&this.insertBefore(e,this._afterCaptionAndColgroups())}createTHead(){let e=childOfType(this[z],Z.thead);if(e!==null)return e.node;let t=this[z].doc.createElement(`thead`);return this.insertBefore(t,this._afterCaptionAndColgroups()),t}deleteTHead(){let e=childOfType(this[z],Z.thead);e!==null&&this.removeChild(e.node)}get tFoot(){let e=childOfType(this[z],Z.tfoot);return e===null?null:e.node}set tFoot(e){if(e!==null&&e[z].tag!==Z.tfoot)throw hierarchyError(`Not a tfoot element.`);let t=childOfType(this[z],Z.tfoot);t!==null&&this.removeChild(t.node),e!==null&&this.appendChild(e)}createTFoot(){let e=childOfType(this[z],Z.tfoot);return e===null?this.appendChild(this[z].doc.createElement(`tfoot`)):e.node}deleteTFoot(){let e=childOfType(this[z],Z.tfoot);e!==null&&this.removeChild(e.node)}get tBodies(){return sameObject(this,pf,()=>fnCollection(this[z],(e,t)=>{for(let n=e.first;n!==null;n=n.next)n.type===1&&n.tag===Z.tbody&&n.ns===`http://www.w3.org/1999/xhtml`&&t.push(n.node)}))}createTBody(){let e=this[z].doc.createElement(`tbody`),t=null;for(let e=this[z].first;e!==null;e=e.next)e.type===1&&e.tag===Z.tbody&&e.ns===`http://www.w3.org/1999/xhtml`&&(t=e);return this.insertBefore(e,t===null||t.next===null?null:t.next.node),e}get rows(){return sameObject(this,ff,()=>fnCollection(this[z],fillTableRows))}insertRow(e=-1){e=Number(e)|0;let t=this.rows,n=t.length;if(e<-1||e>n)throw indexError(e);let r=this[z].doc,i=r.createElement(`tr`);if(n===0&&childOfType(this[z],Z.tbody)===null)this.appendChild(r.createElement(`tbody`)).appendChild(i);else if(n===0){let e=null;for(let t=this[z].first;t!==null;t=t.next)t.type===1&&t.tag===Z.tbody&&t.ns===`http://www.w3.org/1999/xhtml`&&(e=t.node);e.appendChild(i)}else if(e===-1||e===n)t.item(n-1).parentNode.appendChild(i);else{let n=t.item(e);n.parentNode.insertBefore(i,n)}return i}deleteRow(e){e=Number(e)|0;let t=this.rows,n=t.length;if(e===-1){if(n===0)return;e=n-1}if(e<0||e>=n)throw indexError(e);t.item(e).remove()}_afterCaptionAndColgroups(){for(let e=this[z].first;e!==null;e=e.next)if(e.type===1&&(e.tag!==Z.caption&&e.tag!==Z.colgroup||e.ns!==`http://www.w3.org/1999/xhtml`))return e.node;return null}};str(HTMLTableElement,`align border frame rules summary width`),strNullEmpty(HTMLTableElement,`bgColor=bgcolor cellPadding=cellpadding cellSpacing=cellspacing`);var HTMLTableCaptionElement=class extends HTMLElement{};str(HTMLTableCaptionElement,`align`);var HTMLTableColElement=class extends HTMLElement{};clampedUlong(HTMLTableColElement,`span`,`span`,1,1,1e3),str(HTMLTableColElement,`align ch=char chOff=charoff vAlign=valign width`);var HTMLTableSectionElement=class extends HTMLElement{get rows(){return sameObject(this,ff,()=>fnCollection(this[z],pushRows))}insertRow(e=-1){e=Number(e)|0;let t=this.rows,n=t.length;if(e<-1||e>n)throw indexError(e);let r=this[z].doc.createElement(`tr`);return e===-1||e===n?this.appendChild(r):this.insertBefore(r,t.item(e)),r}deleteRow(e){e=Number(e)|0;let t=this.rows,n=t.length;if(e===-1){if(n===0)return;e=n-1}if(e<0||e>=n)throw indexError(e);t.item(e).remove()}};str(HTMLTableSectionElement,`align ch=char chOff=charoff vAlign=valign`);var HTMLTableRowElement=class extends HTMLElement{get rowIndex(){let e=this[z].parent;if(e===null)return-1;let t=null;if(e.tag===Z.table&&e.ns===`http://www.w3.org/1999/xhtml`?t=e:(e.tag===Z.thead||e.tag===Z.tbody||e.tag===Z.tfoot)&&e.ns===`http://www.w3.org/1999/xhtml`&&e.parent!==null&&e.parent.tag===Z.table&&(t=e.parent),t===null)return-1;let n=[];return fillTableRows(t,n),n.indexOf(this)}get sectionRowIndex(){let e=this[z].parent;if(e===null)return-1;let t=[];return e.tag===Z.table?fillTableRows(e,t):pushRows(e,t),t.indexOf(this)}get cells(){return sameObject(this,mf,()=>fnCollection(this[z],(e,t)=>{for(let n=e.first;n!==null;n=n.next)n.type===1&&(n.tag===Z.td||n.tag===Z.th)&&n.ns===`http://www.w3.org/1999/xhtml`&&t.push(n.node)}))}insertCell(e=-1){e=Number(e)|0;let t=this.cells,n=t.length;if(e<-1||e>n)throw indexError(e);let r=this[z].doc.createElement(`td`);return e===-1||e===n?this.appendChild(r):this.insertBefore(r,t.item(e)),r}deleteCell(e){e=Number(e)|0;let t=this.cells,n=t.length;if(e===-1){if(n===0)return;e=n-1}if(e<0||e>=n)throw indexError(e);t.item(e).remove()}};str(HTMLTableRowElement,`align ch=char chOff=charoff vAlign=valign`),strNullEmpty(HTMLTableRowElement,`bgColor=bgcolor`);var HTMLTableCellElement=class extends HTMLElement{get cellIndex(){let e=this[z].parent;if(e===null||e.tag!==Z.tr)return-1;let t=0;for(let n=e.first;n!==null;n=n.next){if(n===this[z])return t;n.type===1&&(n.tag===Z.td||n.tag===Z.th)&&n.ns===`http://www.w3.org/1999/xhtml`&&t++}return-1}};clampedUlong(HTMLTableCellElement,`colSpan`,`colspan`,1,1,1e3),clampedUlong(HTMLTableCellElement,`rowSpan`,`rowspan`,1,0,65534),str(HTMLTableCellElement,`headers abbr axis align ch=char chOff=charoff vAlign=valign width height`),strNullEmpty(HTMLTableCellElement,`bgColor=bgcolor`),enumerated(HTMLTableCellElement,`scope`,{keywords:[`row`,`col`,`rowgroup`,`colgroup`]}),bool(HTMLTableCellElement,`noWrap=nowrap`);var HTMLDirectoryElement=class extends HTMLElement{};bool(HTMLDirectoryElement,`compact`);var HTMLFontElement=class extends HTMLElement{};strNullEmpty(HTMLFontElement,`color`),str(HTMLFontElement,`face size`);var HTMLFrameSetElement=class extends HTMLElement{};installEventHandlers(HTMLFrameSetElement.prototype,`body`),str(HTMLFrameSetElement,`cols rows`);var HTMLFrameElement=class extends HTMLElement{get contentDocument(){return null}get contentWindow(){return null}};str(HTMLFrameElement,`name scrolling frameBorder=frameborder`),strNullEmpty(HTMLFrameElement,`marginHeight=marginheight marginWidth=marginwidth`),url(HTMLFrameElement,`src longDesc=longdesc`),bool(HTMLFrameElement,`noResize=noresize`);var HTMLMarqueeElement=class extends HTMLElement{start(){}stop(){}};str(HTMLMarqueeElement,`behavior bgColor=bgcolor direction height width`),ulong(HTMLMarqueeElement,`hspace vspace`),long(HTMLMarqueeElement,`loop`,-1),ulong(HTMLMarqueeElement,`scrollAmount=scrollamount`,6),ulong(HTMLMarqueeElement,`scrollDelay=scrolldelay`,85),bool(HTMLMarqueeElement,`trueSpeed=truespeed`);var HTMLUnknownElement=class extends HTMLElement{};function linkURL(e){let t=contentAttr(e,`href`);return t===null?null:URL.parse(t,e.doc.baseURI)}function updateHref(e,t){setAttribute(e,`href`,t.href)}const hf=[`noreferrer`,`noopener`,`opener`];function installHyperlinkUtils(e){let t=e.prototype,define=(e,n,r)=>{Object.defineProperty(t,e,{get(){let e=this[z];return n(linkURL(e),e)},set:r?function(e){let t=this[z],n=linkURL(t);n!==null&&r(n,String(e))&&updateHref(t,n)}:void 0,configurable:!0,enumerable:!0})};Object.defineProperty(t,"href",{get(){let e=this[z],t=contentAttr(e,`href`);if(t===null)return``;let n=URL.parse(t,e.doc.baseURI);return n===null?t:n.href},set(e){setAttribute(this[z],`href`,String(e))},configurable:!0,enumerable:!0}),Object.defineProperty(t,"toString",{value:function toString(){return this.href},writable:!0,configurable:!0,enumerable:!0}),define(`origin`,e=>e===null?``:e.origin),define(`protocol`,e=>e===null?`:`:e.protocol,(e,t)=>(e.protocol=t+`:`,!0)),define(`username`,e=>e===null?``:e.username,(e,t)=>e.host===``||e.protocol===`file:`?!1:(e.username=t,!0)),define(`password`,e=>e===null?``:e.password,(e,t)=>e.host===``||e.protocol===`file:`?!1:(e.password=t,!0)),define(`host`,e=>e===null?``:e.host,(e,t)=>(e.host=t,!0)),define(`hostname`,e=>e===null?``:e.hostname,(e,t)=>(e.hostname=t,!0)),define(`port`,e=>e===null?``:e.port,(e,t)=>(e.port=t,!0)),define(`pathname`,e=>e===null?``:e.pathname,(e,t)=>(e.pathname=t,!0)),define(`search`,e=>e===null?``:e.search,(e,t)=>(e.search=t,!0)),define(`hash`,e=>e===null?``:e.hash,(e,t)=>(e.hash=t,!0))}function followHyperlink(e){let t=e[z],n=linkURL(t);if(n===null)return;let r=t.doc[Y];if(r===null||r.location===void 0)return;let i=contentAttr(t,`target`);if(i!==null&&i!==``&&i.toLowerCase()!==`_self`||contentAttr(t,`download`)!==null)return;let a=URL.parse(t.doc.URL);if(a===null)return;let o=new URL(n.href);if(o.hash=``,a.hash=``,o.href===a.href&&n.href.indexOf(`#`)!==-1)try{r.location.hash=n.hash}catch{}}function reportFollowedHyperlink(e){if(!notImplementedActive()||e.name!==`a`&&!(e.flags&1))return;let t=e.doc[Y];if(t===null)return;let n=contentAttr(e,`target`);if(n===null){let t=querySelector(e.doc[z],`base[target]`);n=t===null?``:contentAttr(t,`target`)??``}let r=n.toLowerCase(),i=null;if(r===``||r===`_self`)i=t;else if(r===`_parent`)i=t[ir]??t;else if(r===`_top`)for(i=t;i[ir]!==null;)i=i[ir];if(i===null)return;let a=linkURL(e);if(a===null||a.protocol===`javascript:`)return;let o=i;t._task(()=>{let e=new URL(o[q].href),t=new URL(a.href);e.hash=``,t.hash=``,e.href!==t.href&&reportNotImplemented(o,$u)},0)}var HTMLAnchorElement=class extends HTMLElement{get text(){let e=this[z],t=``;for(let n=e.first;n!==null;n=nextInTree(n,e))(n.type===3||n.type===4)&&(t+=n.data);return t}set text(e){this.textContent=e}get _hasActivationBehavior(){return contentAttr(this[z],`href`)!==null}_activationBehavior(e){contentAttr(this[z],`href`)!==null&&(followHyperlink(this),reportFollowedHyperlink(this[z]))}};installHyperlinkUtils(HTMLAnchorElement),str(HTMLAnchorElement,`target download ping rel hreflang type coords charset name rev shape`),tokenList(HTMLAnchorElement,`relList`,`rel`,hf),enumerated(HTMLAnchorElement,`referrerPolicy=referrerpolicy`,yc);var HTMLAreaElement=class extends HTMLElement{get _hasActivationBehavior(){return contentAttr(this[z],`href`)!==null}_activationBehavior(e){contentAttr(this[z],`href`)!==null&&(followHyperlink(this),reportFollowedHyperlink(this[z]))}};installHyperlinkUtils(HTMLAreaElement),str(HTMLAreaElement,`alt coords shape target download ping rel hreflang type`),tokenList(HTMLAreaElement,`relList`,`rel`,hf),enumerated(HTMLAreaElement,`referrerPolicy=referrerpolicy`,yc),bool(HTMLAreaElement,`noHref=nohref`);const gf={load:stubbedMethod(`HTMLMediaElement`,`load`),play:stubbedMethod(`HTMLMediaElement`,`play`),pause:stubbedMethod(`HTMLMediaElement`,`pause`),addTextTrack:stubbedMethod(`HTMLMediaElement`,`addTextTrack`)},windowOf=e=>e[z].doc[Y];var MediaState=class{paused=!0;currentTime=0;volume=1;muted=null;playbackRate=1;defaultPlaybackRate=1;ended=!1;seeking=!1;preservesPitch=!0;srcObject=null};const _f=Symbol(`media`);function state$1(e){let t=e[_f];return t===void 0&&(t=new MediaState,Object.defineProperty(e,_f,{value:t})),t}__name(state$1,`state`);var TimeRanges=class{get length(){return 0}start(e){throw new DOMException(`The index provided (${e}) is greater than or equal to the maximum bound (0).`,`IndexSizeError`)}end(e){throw new DOMException(`The index provided (${e}) is greater than or equal to the maximum bound (0).`,`IndexSizeError`)}},MediaError=class{static MEDIA_ERR_ABORTED=1;static MEDIA_ERR_NETWORK=2;static MEDIA_ERR_DECODE=3;static MEDIA_ERR_SRC_NOT_SUPPORTED=4};defineConstants(MediaError,{MEDIA_ERR_ABORTED:1,MEDIA_ERR_NETWORK:2,MEDIA_ERR_DECODE:3,MEDIA_ERR_SRC_NOT_SUPPORTED:4});var HTMLMediaElement=class extends HTMLElement{static NETWORK_EMPTY=0;static NETWORK_IDLE=1;static NETWORK_LOADING=2;static NETWORK_NO_SOURCE=3;static HAVE_NOTHING=0;static HAVE_METADATA=1;static HAVE_CURRENT_DATA=2;static HAVE_FUTURE_DATA=3;static HAVE_ENOUGH_DATA=4;get error(){return null}get currentSrc(){return this.src}get srcObject(){return state$1(this).srcObject}set srcObject(e){state$1(this).srcObject=e}get networkState(){return 0}get buffered(){return new TimeRanges}get readyState(){return 0}get seeking(){return state$1(this).seeking}get currentTime(){return state$1(this).currentTime}set currentTime(e){let t=Number(e);if(!Number.isFinite(t))throw TypeError(`The provided double value is non-finite.`);state$1(this).currentTime=t}fastSeek(e){this.currentTime=e}get duration(){return NaN}getStartDate(){return/* @__PURE__ */ new Date(NaN)}get paused(){return state$1(this).paused}get defaultPlaybackRate(){return state$1(this).defaultPlaybackRate}set defaultPlaybackRate(e){state$1(this).defaultPlaybackRate=Number(e),fireEvent(this,`ratechange`)}get playbackRate(){return state$1(this).playbackRate}set playbackRate(e){state$1(this).playbackRate=Number(e),fireEvent(this,`ratechange`)}get preservesPitch(){return state$1(this).preservesPitch}set preservesPitch(e){state$1(this).preservesPitch=!!e}get played(){return new TimeRanges}get seekable(){return new TimeRanges}get ended(){return state$1(this).ended}get volume(){return state$1(this).volume}set volume(e){let t=Number(e);if(!Number.isFinite(t))throw TypeError(`The provided double value is non-finite.`);if(t<0||t>1)throw new DOMException(`The volume provided (${t}) is outside the range [0, 1].`,`IndexSizeError`);let n=state$1(this);n.volume!==t&&(n.volume=t,fireEvent(this,`volumechange`))}get muted(){return state$1(this).muted??contentAttr(this[z],`muted`)!==null}set muted(e){let t=state$1(this),n=!!e;this.muted===n?t.muted=n:(t.muted=n,fireEvent(this,`volumechange`))}canPlayType(e){return``}load(){reportNotImplemented(windowOf(this),gf.load);let e=state$1(this),t=!e.paused;e.currentTime=0,e.ended=!1,t&&(e.paused=!0,queueElementTask(this,()=>fireEvent(this,`pause`))),queueElementTask(this,()=>fireEvent(this,`emptied`))}play(){reportNotImplemented(windowOf(this),gf.play);let e=state$1(this);return e.paused&&(e.paused=!1,e.ended=!1,queueElementTask(this,()=>{fireEvent(this,`play`),fireEvent(this,`playing`)})),Promise.resolve()}pause(){reportNotImplemented(windowOf(this),gf.pause);let e=state$1(this);e.paused||(e.paused=!0,queueElementTask(this,()=>{fireEvent(this,`timeupdate`),fireEvent(this,`pause`)}))}get textTracks(){return[]}get audioTracks(){return[]}get videoTracks(){return[]}addTextTrack(){throw reportNotImplemented(windowOf(this),gf.addTextTrack),new DOMException(`Text tracks are not supported.`,`NotSupportedError`)}setMediaKeys(){return Promise.resolve()}get mediaKeys(){return null}setSinkId(){return Promise.resolve()}get sinkId(){return``}};defineConstants(HTMLMediaElement,{NETWORK_EMPTY:0,NETWORK_IDLE:1,NETWORK_LOADING:2,NETWORK_NO_SOURCE:3,HAVE_NOTHING:0,HAVE_METADATA:1,HAVE_CURRENT_DATA:2,HAVE_FUTURE_DATA:3,HAVE_ENOUGH_DATA:4}),url(HTMLMediaElement,`src`),enumerated(HTMLMediaElement,`crossOrigin=crossorigin`,vc),enumerated(HTMLMediaElement,`preload`,{keywords:[`none`,`metadata`,`auto`],missing:`metadata`,invalid:`metadata`,empty:`auto`}),enumerated(HTMLMediaElement,`loading`,bc),bool(HTMLMediaElement,`autoplay loop controls defaultMuted=muted disableRemotePlayback=disableremoteplayback`);var HTMLAudioElement=class extends HTMLMediaElement{},HTMLVideoElement=class extends HTMLMediaElement{get videoWidth(){return 0}get videoHeight(){return 0}getVideoPlaybackQuality(){return{creationTime:performance.now(),droppedVideoFrames:0,totalVideoFrames:0}}requestPictureInPicture(){return Promise.reject(new DOMException(`Picture-in-Picture is not supported.`,`NotSupportedError`))}};ulong(HTMLVideoElement,`width height`),url(HTMLVideoElement,`poster`),bool(HTMLVideoElement,`playsInline=playsinline disablePictureInPicture=disablepictureinpicture`);const vf=function Audio(e){if(new.target===void 0)throw TypeError(`Failed to construct 'Audio': Please use the 'new' operator.`);let t=currentDocument().createElementNS(E,`audio`);return setAttribute(t[z],`preload`,`auto`),e!==void 0&&setAttribute(t[z],`src`,String(e)),t};vf.prototype=HTMLAudioElement.prototype;const yf=/* @__PURE__ */ new WeakMap;function queueDetailsToggle(e,t,n){let r=queueToggleTask(e,yf.get(e),t,t=>{yf.delete(e),fireToggleEvent(e.node,`toggle`,t,n,!1)});yf.set(e,r)}function nameGroupOthers(e,t,n){let r=treeRoot(e);for(let i=r.first;i!==null;i=nextInTree(i,r))i!==e&&i.type===1&&i.tag===Z.details&&i.ns===`http://www.w3.org/1999/xhtml`&&contentAttr(i,`name`)===t&&n.push(i);return n}var HTMLDetailsElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=12}_attributeChangedSteps(e,t,n,r){if(super._attributeChangedSteps(e,t,n,r),r!==null)return;let i=this[z];if(e===`name`)ensureClosingGiven(i);else if(e===`open`){if(t===null&&n!==null){queueDetailsToggle(i,`closed`,`open`);let e=contentAttr(i,`name`);if(e!==null&&e!==``)for(let t of nameGroupOthers(i,e,[]))contentAttr(t,`open`)!==null&&removeAttribute(t,`open`)}else t!==null&&n===null&&queueDetailsToggle(i,`open`,`closed`)}}_connectedSteps(){super._connectedSteps(),ensureClosingGiven(this[z])}};function ensureClosingGiven(e){if(contentAttr(e,`open`)===null)return;let t=contentAttr(e,`name`);if(t!==null&&t!==``){for(let n of nameGroupOthers(e,t,[]))if(contentAttr(n,`open`)!==null){removeAttribute(e,`open`);return}}}bool(HTMLDetailsElement,`open`),str(HTMLDetailsElement,`name`);const bf=HTMLElement,xf=class HTMLElement extends bf{get _hasActivationBehavior(){return isSummaryForParentDetails(this[z])}_activationBehavior(e){let t=this[z];if(!isSummaryForParentDetails(t))return;let n=e?.target?.[z];if(n!==void 0&&inInteractiveContent(n,t))return;let r=t.parent;outsideCEReactions(()=>{contentAttr(r,`open`)===null?setAttribute(r,`open`,``):removeAttribute(r,`open`)})}};function inInteractiveContent(e,t){for(let n=e;n!==null&&n!==t;n=n.parent)if(n.type===1){if(n.ns===`http://www.w3.org/2000/svg`){if(n.name===`a`&&(contentAttr(n,`href`)!==null||n.attrs?.some(e=>e.localName===`href`)))return!0}else if(n.ns===`http://www.w3.org/1999/xhtml`)switch(n.tag){case Z.a:if(contentAttr(n,`href`)!==null)return!0;break;case Z.audio:case Z.video:if(contentAttr(n,`controls`)!==null)return!0;break;case Z.img:if(contentAttr(n,`usemap`)!==null)return!0;break;case Z.input:if(contentAttr(n,`type`)?.toLowerCase()!==`hidden`)return!0;break;case Z.button:case Z.details:case Z.embed:case Z.iframe:case Z.label:case Z.select:case Z.textarea:return!0}}return!1}const Sf=/* @__PURE__ */ new WeakMap;function dialogRecord(e){let t=Sf.get(e);return t===void 0&&(t={returnValue:``,toggleTracker:null,closeWatcher:null,requestCloseReturnValue:null,requestCloseSource:null,enableCloseWatcherForRequestClose:!1},Sf.set(e,t)),t}function nodeOf(e){return e===null?null:e.node}function queueDialogToggle(e,t,n,r){let i=dialogRecord(e),a=queueToggleTask(e,i.toggleTracker,t,t=>{fireToggleEvent(e.node,`toggle`,t,n,!1,nodeOf(r)),i.toggleTracker===a&&(i.toggleTracker=null)});i.toggleTracker=a}function computedClosedBy(e){let t=contentAttr(e,`closedby`)?.toLowerCase();return t===`any`||t===`closerequest`||t===`none`?t:matchesModal(e)?`closerequest`:`none`}var HTMLDialogElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=12}get returnValue(){return Sf.get(this[z])?.returnValue??``}set returnValue(e){dialogRecord(this[z]).returnValue=String(e)}get closedBy(){return computedClosedBy(this[z])}set closedBy(e){setAttribute(this[z],`closedby`,String(e))}show(){let e=this[z];if(contentAttr(e,`open`)!==null){if(!matchesModal(e))return;throw new DOMException(`The dialog is already open as a modal dialog.`,`InvalidStateError`)}if(!fireToggleEvent(this,`beforetoggle`,`closed`,`open`,!0)||contentAttr(e,`open`)!==null)return;queueDialogToggle(e,`closed`,`open`,null),setAttribute(e,`open`,``),setPreviouslyFocused(e,e.doc[L]);let t=e.doc;hidePopoversUntil(t,topmostPopoverAncestor(e,null,!1),!1,!0),dialogFocusingSteps(e)}showModal(){showModalDialog(this[z],null)}close(e){closeDialog(this[z],e===void 0?null:String(e),null)}requestClose(e){requestCloseDialog(this[z],e===void 0?null:String(e),null)}_attributeChangedSteps(e,t,n,r){if(super._attributeChangedSteps(e,t,n,r),r!==null||e!==`open`)return;let i=this[z];n===null&&t!==null&&dialogCleanupSteps(i),isFullyActive(i.doc)&&i.flags&1&&n!==null&&t===null&&dialogSetupSteps(i)}_connectedSteps(){super._connectedSteps();let e=this[z];isFullyActive(e.doc)&&contentAttr(e,`open`)!==null&&e.flags&1&&dialogSetupSteps(e)}_disconnectedSteps(){super._disconnectedSteps();let e=this[z];contentAttr(e,`open`)!==null&&dialogCleanupSteps(e),removeFromTopLayer(e),setModal(e,!1)}};bool(HTMLDialogElement,`open`);function showModalDialog(e,t){let n=e.node;if(contentAttr(e,`open`)!==null){if(matchesModal(e))return;throw new DOMException(`The dialog is already open as a non-modal dialog.`,`InvalidStateError`)}if(!isFullyActive(e.doc))throw new DOMException(`The dialog's document is not fully active.`,`InvalidStateError`);if(!(e.flags&1))throw new DOMException(`The dialog is not connected.`,`InvalidStateError`);if(isPopoverShowing(e))throw new DOMException(`The dialog is already open as a popover.`,`InvalidStateError`);if(!fireToggleEvent(n,`beforetoggle`,`closed`,`open`,!0,nodeOf(t))||contentAttr(e,`open`)!==null||!(e.flags&1)||isPopoverShowing(e))return;queueDialogToggle(e,`closed`,`open`,t),setAttribute(e,`open`,``),setModal(e,!0);let r=e.doc,i=r[L];isInTopLayer(e)||addToTopLayer(e),i!==null&&isInert(i)&&blurElement(i),setPreviouslyFocused(e,i),hidePopoversUntil(r,topmostPopoverAncestor(e,null,!1),!1,!0),dialogFocusingSteps(e)}function closeDialog(e,t,n){let r=e.node;if(contentAttr(e,`open`)===null||(fireToggleEvent(r,`beforetoggle`,`open`,`closed`,!1,nodeOf(n)),contentAttr(e,`open`)===null))return;queueDialogToggle(e,`open`,`closed`,n),removeAttribute(e,`open`);let i=matchesModal(e);i&&removeFromTopLayer(e),setModal(e,!1);let a=dialogRecord(e);t!==null&&(a.returnValue=t),a.requestCloseReturnValue=null,a.requestCloseSource=null;let o=getPreviouslyFocused(e);if(o!==null){setPreviouslyFocused(e,null);let t=e.doc[L];(t!==null&&isShadowIncludingInclusiveAncestor(e,t)||i)&&focusElement(o,{preventScroll:!0})}queueElementTask(r,()=>fireEvent(r,`close`))}function requestCloseDialog(e,t,n){if(contentAttr(e,`open`)===null||!(e.flags&1)||!isFullyActive(e.doc))return;let r=dialogRecord(e);if(r.closeWatcher!==null){r.enableCloseWatcherForRequestClose=!0,r.requestCloseReturnValue=t,r.requestCloseSource=n;try{requestCloseWatcher(r.closeWatcher,!1)}finally{r.enableCloseWatcherForRequestClose=!1}}}function dialogSetupSteps(e){let t=openDialogsList(e.doc);if(t.includes(e))return;t.push(e);let n=dialogRecord(e);n.closeWatcher===null&&(n.closeWatcher=establishCloseWatcher(e.doc,t=>fireEvent(e.node,`cancel`,!1,t),()=>closeDialog(e,n.requestCloseReturnValue,n.requestCloseSource),()=>n.enableCloseWatcherForRequestClose||computedClosedBy(e)!==`none`))}function dialogCleanupSteps(e){let t=openDialogsList(e.doc),n=t.indexOf(e);n!==-1&&t.splice(n,1);let r=Sf.get(e);r!==void 0&&r.closeWatcher!==null&&(destroyCloseWatcher(r.closeWatcher),r.closeWatcher=null)}function dialogFocusingSteps(e){let t=null;contentAttr(e,`autofocus`)!==null&&(t=e),t===null&&(t=focusDelegate(e)),t===null&&(t=e),focusElement(t)}function submitFormToDialog(e,t){let n=t===e?null:contentAttr(t,`formmethod`);if(n===null&&(n=contentAttr(e,`method`)),n?.toLowerCase()!==`dialog`)return!1;let r=e.parent;for(;r!==null&&(r.type!==1||r.tag!==Z.dialog||r.ns!==`http://www.w3.org/1999/xhtml`);)r=r.parent;if(r===null)return!0;let i;if(t===e)i=``;else if(t.tag===Z.input&&contentAttr(t,`type`)?.toLowerCase()===`image`){let e=ad.get(t);i=e===void 0?`0,0`:`${e.x},${e.y}`}else i=contentAttr(t,`value`);return closeDialog(r,i,null),!0}function dialogCommandSteps(e,t,n){if(isPopoverShowing(e))return;let r=contentAttr(e,`open`)!==null,i=contentAttr(t,`value`);if(n===`close`&&r)closeDialog(e,i,t);else if(n===`request-close`&&r)requestCloseDialog(e,i,t);else if(n===`show-modal`&&!r)try{showModalDialog(e,t)}catch{}}function nearestClickedDialog(e){for(let t=e;t!==null;t=flatParent(t))if(t.tag===Z.dialog&&t.ns===`http://www.w3.org/1999/xhtml`&&contentAttr(t,`open`)!==null)return t;return null}function lightDismissOpenDialogs(e,t,n){let r=e.openDialogs;if(r.length===0)return;let i=nearestClickedDialog(t);if(!matchesLightDismissTarget(e,`dialogPointerdownTarget`,n,i))return;let a=r[r.length-1];if(i===a||computedClosedBy(a)!==`any`)return;let o=Sf.get(a);o?.closeWatcher&&requestCloseWatcher(o.closeWatcher,!1)}function isShadowIncludingInclusiveAncestor(e,t){for(let n=t;n!==null;){if(n===e)return!0;if(n.parent!==null)n=n.parent;else if(n.flags&32){let e=n.node[R];n=e===null?null:e[z]}else n=null}return!1}setTopLayerDialogHooks(dialogFocusingSteps,lightDismissOpenDialogs),setDialogCommandSteps(dialogCommandSteps),setDialogSubmission(submitFormToDialog);function templateContentsOwner(e){let t=e[Xr];if(t!==void 0)return t;let n=e[Nn]?Q._createHTML(null):new Q;return e[Nn]||(n[yt]=e[yt]),defineHidden(n,Xr,n),defineHidden(e,Xr,n),n}const Cf=Symbol(`content`);var HTMLTemplateElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=me}get content(){let e=this[Cf];return e===void 0&&(e=new DocumentFragment(templateContentsOwner(this[z].doc)),e[R]=this,Object.defineProperty(this,Cf,{value:e,writable:!0})),e}_cloningSteps(e,t){if(super._cloningSteps(e,t),!t)return;let n=this[Cf];if(n===void 0||n[z].first===null)return;let r=e.content,i=r[z].doc;for(let e=n[z].first;e!==null;e=e.next)appendDetached(cloneNode(e,i,!0),r[z])}_adoptingSteps(e){super._adoptingSteps(e);let t=this[Cf];t!==void 0&&templateContentsOwner(this[z].doc).adoptNode(t)}};enumerated(HTMLTemplateElement,`shadowRootMode=shadowrootmode`,{keywords:[`open`,`closed`]}),enumerated(HTMLTemplateElement,`shadowRootSlotAssignment=shadowrootslotassignment`,{keywords:[`named`,`manual`],missing:`named`,invalid:`named`}),bool(HTMLTemplateElement,`shadowRootDelegatesFocus=shadowrootdelegatesfocus shadowRootClonable=shadowrootclonable shadowRootSerializable=shadowrootserializable`);var HTMLSlotElement=class extends HTMLElement{assignedNodes(e){return assignedNodes(this[z],!!e?.flatten).map(e=>e.node)}assignedElements(e){return assignedElements(this[z],!!e?.flatten).map(e=>e.node)}assign(...e){let t=[];for(let n of e){let e=n?.[z];if(e===void 0||e.type!==1&&e.type!==3)throw TypeError(`Failed to execute 'assign' on 'HTMLSlotElement': parameter is not of type '(Element or Text)'.`);t.push(e)}assignManually(this[z],t)}};str(HTMLSlotElement,`name`);const wf={createSheet:null,removeSheet:null,createLinkSheet:null},Tf=Symbol(`sheet`);function getSheet(e){return e[Tf]??null}function setSheet(e,t){Object.defineProperty(e,Tf,{value:t,writable:!0,configurable:!0})}function childTextContent(e){let t=``;for(let n=e.first;n!==null;n=n.next)(n.type===3||n.type===4)&&(t+=n.data);return t}function removeAssociatedSheet(e){let t=getSheet(e);t!==null&&(setSheet(e,null),wf.removeSheet?.(e[z],t))}function updateStyleBlock(e){let t=e[z];if(removeAssociatedSheet(e),!(t.flags&1))return;let n=contentAttr(t,`type`);if(n!==null&&n!==``&&n.toLowerCase()!==`text/css`)return;let r=wf.createSheet;r===null?t.doc[Gr]++:setSheet(e,r(t,childTextContent(t),contentAttr(t,`media`)??``))}var HTMLStyleElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=28}_connectedSteps(){super._connectedSteps(),updateStyleBlock(this)}_disconnectedSteps(){super._disconnectedSteps(),updateStyleBlock(this)}_childrenChangedSteps(){updateStyleBlock(this)}_attributeChangedSteps(e,t,n,r){super._attributeChangedSteps(e,t,n,r),r===null&&(e===`type`||e===`media`)&&updateStyleBlock(this)}get sheet(){return getSheet(this)}get disabled(){let e=getSheet(this);return e!==null&&e.disabled===!0}set disabled(e){let t=getSheet(this);t!==null&&(t.disabled=!!e)}};str(HTMLStyleElement,`media type`),tokenList(HTMLStyleElement,`blocking`,`blocking`,[`render`]);function isStylesheetLink(e){let t=contentAttr(e,`rel`);return t!==null&&/(?:^|[\t\n\f\r ])stylesheet(?:$|[\t\n\f\r ])/i.test(t)&&!/(?:^|[\t\n\f\r ])alternate(?:$|[\t\n\f\r ])/i.test(t)}function updateLinkSheet(e){let t=e[z];if(removeAssociatedSheet(e),!(t.flags&1)||!isStylesheetLink(t)||contentAttr(t,`disabled`)!==null)return;let n=wf.createLinkSheet;if(n===null)return;let r=contentAttr(t,`href`);if(r===null||r===``)return;let i=n(t,e.href,contentAttr(t,`media`)??``);i!==null&&setSheet(e,i)}var HTMLLinkElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=12}_connectedSteps(){super._connectedSteps(),updateLinkSheet(this)}_disconnectedSteps(){super._disconnectedSteps(),removeAssociatedSheet(this)}_attributeChangedSteps(e,t,n,r){super._attributeChangedSteps(e,t,n,r),r===null&&(e===`rel`||e===`href`||e===`media`||e===`disabled`||e===`type`)&&updateLinkSheet(this)}get sheet(){return getSheet(this)}};url(HTMLLinkElement,`href`),enumerated(HTMLLinkElement,`crossOrigin=crossorigin`,vc),str(HTMLLinkElement,`rel media integrity hreflang type imageSrcset=imagesrcset imageSizes=imagesizes charset rev target`),enumerated(HTMLLinkElement,`as`,{keywords:[`fetch`,`audio`,`audioworklet`,`document`,`embed`,`font`,`frame`,`iframe`,`image`,`json`,`manifest`,`object`,`paintworklet`,`report`,`script`,`serviceworker`,`sharedworker`,`style`,`track`,`video`,`webidentity`,`worker`,`xslt`]}),tokenList(HTMLLinkElement,`relList`,`rel`,[`alternate`,`dns-prefetch`,`expect`,`icon`,`manifest`,`modulepreload`,`next`,`pingback`,`preconnect`,`prefetch`,`preload`,`search`,`stylesheet`]),tokenList(HTMLLinkElement,`sizes`,`sizes`),tokenList(HTMLLinkElement,`blocking`,`blocking`,[`render`]),enumerated(HTMLLinkElement,`referrerPolicy=referrerpolicy`,yc),enumerated(HTMLLinkElement,`fetchPriority=fetchpriority`,xc),bool(HTMLLinkElement,`disabled`);const Ef=Symbol(`nonBlocking`);var HTMLScriptElement=class extends HTMLElement{static supports(e){let t=String(e);return t===`classic`||t===`module`||t===`importmap`||t===`speculationrules`}get text(){return childTextContent(this[z])}set text(e){this.textContent=String(e)}get async(){return(this[Ef]??!0)||contentAttr(this[z],`async`)!==null}set async(e){Object.defineProperty(this,Ef,{value:!1,writable:!0,configurable:!0}),e?this.setAttribute(`async`,``):this.removeAttribute(`async`)}};url(HTMLScriptElement,`src`),str(HTMLScriptElement,`type charset event htmlFor=for integrity`),bool(HTMLScriptElement,`noModule=nomodule defer`),enumerated(HTMLScriptElement,`crossOrigin=crossorigin`,vc),enumerated(HTMLScriptElement,`referrerPolicy=referrerpolicy`,yc),enumerated(HTMLScriptElement,`fetchPriority=fetchpriority`,xc),tokenList(HTMLScriptElement,`blocking`,`blocking`,[`render`]);var HTMLTitleElement=class extends HTMLElement{get text(){return childTextContent(this[z])}set text(e){this.textContent=String(e)}};function stripAndCollapse(e){return e.replace(/[\t\n\f\r ]+/g,` `).replace(/^ | $/g,``)}function titleElement(e){let t=e[z];for(let e=nextElementInTree(t,t);e!==null;e=nextElementInTree(e,t))if(e.tag===Z.title&&e.ns===`http://www.w3.org/1999/xhtml`)return e;return null}function svgTitle(e){for(let t=e.first;t!==null;t=t.next)if(t.type===1&&t.ns===`http://www.w3.org/2000/svg`&&t.name===`title`)return t;return null}function getDocumentTitle(e){let t=firstElementChild(e[z]),n;if(t!==null&&t.ns===`http://www.w3.org/2000/svg`&&t.name===`svg`){let e=svgTitle(t);n=e===null?``:childTextContent(e)}else{let t=titleElement(e);n=t===null?``:childTextContent(t)}return stripAndCollapse(n)}function setDocumentTitle(e,t){let n=firstElementChild(e[z]);if(n===null)return;if(n.ns===`http://www.w3.org/2000/svg`&&n.name===`svg`){let r=svgTitle(n);r===null&&(r=e.createElementNS(D,`title`)[z],n.node.insertBefore(r.node,n.first===null?null:n.first.node)),r.node.textContent=t;return}if(n.ns!==`http://www.w3.org/1999/xhtml`)return;let r=titleElement(e);if(r===null){let t=e.head;if(t===null)return;r=t.appendChild(e.createElement(`title`))[z]}r.node.textContent=t}Object.hasOwn(Q.prototype,`title`)||Object.defineProperty(Q.prototype,"title",{get(){return getDocumentTitle(this)},set(e){setDocumentTitle(this,String(e))},configurable:!0,enumerable:!0}),Object.hasOwn(Q.prototype,`dir`)||Object.defineProperty(Q.prototype,"dir",{get(){let e=firstElementChild(this[z]);if(e===null||e.tag!==Z.html||e.ns!==`http://www.w3.org/1999/xhtml`)return``;let t=contentAttr(e,`dir`);if(t===null)return``;let n=t.toLowerCase();return n===`ltr`||n===`rtl`||n===`auto`?n:``},set(e){let t=firstElementChild(this[z]);t!==null&&t.tag===Z.html&&t.ns===`http://www.w3.org/1999/xhtml`&&t.node.setAttribute(`dir`,String(e))},configurable:!0,enumerable:!0});for(let[e,t]of[[`fgColor`,`text`],[`linkColor`,`link`],[`vlinkColor`,`vlink`],[`alinkColor`,`alink`],[`bgColor`,`bgcolor`]])Object.hasOwn(Q.prototype,e)||Object.defineProperty(Q.prototype,e,{get(){let e=this.body;return e===null||e[z].tag!==Z.body?``:contentAttr(e[z],t)??``},set(e){let n=this.body;n!==null&&n[z].tag===Z.body&&n.setAttribute(t,e===null?``:String(e))},configurable:!0,enumerable:!0});var SVGNumber=class{#e=0;get value(){return this.#e}set value(e){let t=Number(e);if(!Number.isFinite(t))throw TypeError(`Failed to set the 'value' property on 'SVGNumber': The provided float value is non-finite.`);this.#e=Math.fround(t)}};const Df=`[ \\t\\n\\r\\f]`,Of=`[+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?`,kf=`(?:${Df}*,${Df}*|${Df}+)`,Af=RegExp(`^${Df}*(${Of})${kf}(${Of})${kf}(${Of})${kf}(${Of})${Df}*$`);function parseViewBox(e,t){let n=Af.exec(contentAttr(e[z],t)??``);if(n!==null){let e=Number(n[3]),t=Number(n[4]);if(e>=0&&t>=0)return[Number(n[1]),Number(n[2]),e,t]}return[0,0,0,0]}function writeViewBox(e,t,n,r){let i=parseViewBox(e,t);i[n]=Number(r),setAttribute(e[z],t,`${i[0]} ${i[1]} ${i[2]} ${i[3]}`)}var ReflectedRect=class extends us{#e;#t;constructor(e,t){super(),this.#e=e,this.#t=t}get x(){return parseViewBox(this.#e,this.#t)[0]}set x(e){writeViewBox(this.#e,this.#t,0,e)}get y(){return parseViewBox(this.#e,this.#t)[1]}set y(e){writeViewBox(this.#e,this.#t,1,e)}get width(){return parseViewBox(this.#e,this.#t)[2]}set width(e){writeViewBox(this.#e,this.#t,2,e)}get height(){return parseViewBox(this.#e,this.#t)[3]}set height(e){writeViewBox(this.#e,this.#t,3,e)}get top(){let e=parseViewBox(this.#e,this.#t);return Math.min(e[1],e[1]+e[3])}get right(){let e=parseViewBox(this.#e,this.#t);return Math.max(e[0],e[0]+e[2])}get bottom(){let e=parseViewBox(this.#e,this.#t);return Math.max(e[1],e[1]+e[3])}get left(){let e=parseViewBox(this.#e,this.#t);return Math.min(e[0],e[0]+e[2])}toJSON(){return new DOMRectReadOnly(this.x,this.y,this.width,this.height).toJSON()}},ReflectedRectReadOnly=class extends DOMRectReadOnly{#e;#t;constructor(e,t){super(),this.#e=e,this.#t=t}get x(){return parseViewBox(this.#e,this.#t)[0]}get y(){return parseViewBox(this.#e,this.#t)[1]}get width(){return parseViewBox(this.#e,this.#t)[2]}get height(){return parseViewBox(this.#e,this.#t)[3]}get top(){let e=parseViewBox(this.#e,this.#t);return Math.min(e[1],e[1]+e[3])}get right(){let e=parseViewBox(this.#e,this.#t);return Math.max(e[0],e[0]+e[2])}get bottom(){let e=parseViewBox(this.#e,this.#t);return Math.max(e[1],e[1]+e[3])}get left(){let e=parseViewBox(this.#e,this.#t);return Math.min(e[0],e[0]+e[2])}toJSON(){return new DOMRectReadOnly(this.x,this.y,this.width,this.height).toJSON()}};exposeMembers(ReflectedRect,ReflectedRectReadOnly),Object.defineProperty(ReflectedRect.prototype,"constructor",{value:us,configurable:!0,writable:!0}),Object.defineProperty(ReflectedRectReadOnly.prototype,"constructor",{value:DOMRectReadOnly,configurable:!0,writable:!0});var SVGAnimatedRect=class{#e;#t;#n=null;#r=null;constructor(e,t){this.#e=e,this.#t=t}get baseVal(){return this.#n??=new ReflectedRect(this.#e,this.#t)}get animVal(){return this.#r??=new ReflectedRectReadOnly(this.#e,this.#t)}};const jf=[`unknown`,`none`,`xMinYMin`,`xMidYMin`,`xMaxYMin`,`xMinYMid`,`xMidYMid`,`xMaxYMid`,`xMinYMax`,`xMidYMax`,`xMaxYMax`],Mf=[`unknown`,`meet`,`slice`],Nf=/^(none|x(?:Min|Mid|Max)Y(?:Min|Mid|Max))(?: +(meet|slice))?$/;function parsePreserveAspectRatio(e){let t=Nf.exec(contentAttr(e[z],`preserveAspectRatio`)??``);return t===null?[`xMidYMid`,`meet`]:[t[1],t[2]??`meet`]}var SVGPreserveAspectRatio=class{#e;#t;constructor(e,t){this.#e=e,this.#t=t}get align(){return jf.indexOf(parsePreserveAspectRatio(this.#e)[0])}set align(e){this.#n(jf,e,0,`Invalid alignment`)}get meetOrSlice(){return Mf.indexOf(parsePreserveAspectRatio(this.#e)[1])}set meetOrSlice(e){this.#n(Mf,e,1,`Invalid meet-or-slice value`)}#n(e,t,n,r){if(this.#t)throw new DOMException(`Attempting to modify a read-only SVGPreserveAspectRatio`,`NoModificationAllowedError`);let i=e[Number(t)&65535];if(i===void 0||i===`unknown`)throw TypeError(r);let a=parsePreserveAspectRatio(this.#e);a[n]=i,setAttribute(this.#e[z],`preserveAspectRatio`,`${a[0]} ${a[1]}`)}};defineConstants(SVGPreserveAspectRatio,{SVG_PRESERVEASPECTRATIO_UNKNOWN:0,SVG_PRESERVEASPECTRATIO_NONE:1,SVG_PRESERVEASPECTRATIO_XMINYMIN:2,SVG_PRESERVEASPECTRATIO_XMIDYMIN:3,SVG_PRESERVEASPECTRATIO_XMAXYMIN:4,SVG_PRESERVEASPECTRATIO_XMINYMID:5,SVG_PRESERVEASPECTRATIO_XMIDYMID:6,SVG_PRESERVEASPECTRATIO_XMAXYMID:7,SVG_PRESERVEASPECTRATIO_XMINYMAX:8,SVG_PRESERVEASPECTRATIO_XMIDYMAX:9,SVG_PRESERVEASPECTRATIO_XMAXYMAX:10,SVG_MEETORSLICE_UNKNOWN:0,SVG_MEETORSLICE_MEET:1,SVG_MEETORSLICE_SLICE:2});var SVGAnimatedPreserveAspectRatio=class{#e;#t=null;#n=null;constructor(e){this.#e=e}get baseVal(){return this.#t??=new SVGPreserveAspectRatio(this.#e,!1)}get animVal(){return this.#n??=new SVGPreserveAspectRatio(this.#e,!0)}};const Pf=Symbol(`viewBox`),Ff=Symbol(`preserveAspectRatio`);function installFitToViewBox(e){Object.defineProperty(e.prototype,"viewBox",{get(){let e=this[Pf];return e===void 0&&(e=new SVGAnimatedRect(this,`viewBox`),Object.defineProperty(this,Pf,{value:e})),e},configurable:!0,enumerable:!0}),Object.defineProperty(e.prototype,"preserveAspectRatio",{get(){let e=this[Ff];return e===void 0&&(e=new SVGAnimatedPreserveAspectRatio(this),Object.defineProperty(this,Ff,{value:e})),e},configurable:!0,enumerable:!0})}exposeMembers(SVGNumber,SVGAnimatedRect,SVGPreserveAspectRatio,SVGAnimatedPreserveAspectRatio);for(let e of[SVGNumber,SVGAnimatedRect,SVGPreserveAspectRatio,SVGAnimatedPreserveAspectRatio])defineInterfaceShape(e);var SVGAnimatedString=class{[F];[qe];constructor(e,t){this[F]=e,this[qe]=t}get baseVal(){let e=this[F][z];return this[qe]===`href`?contentAttr(e,`href`)??xlinkHref(e)??``:contentAttr(e,this[qe])??``}set baseVal(e){setAttribute(this[F][z],this[qe],String(e))}get animVal(){return this.baseVal}};function xlinkHref(e){let t=e.attrs;if(t===null)return null;for(let e=0;e<t.length;e++)if(t[e].localName===`href`&&t[e].ns===`http://www.w3.org/1999/xlink`)return t[e].value;return null}const If=Symbol(`className`),Lf=Symbol(`href`);var SVGElement=class extends Rs{get style(){return this[Wr]??=new CSSStyleDeclaration(this)}set style(e){this.style.cssText=String(e)}get className(){let e=this[If];return e===void 0&&(e=new SVGAnimatedString(this,`class`),Object.defineProperty(this,If,{value:e})),e}set className(e){}get ownerSVGElement(){for(let e=this[z].parent;e!==null&&e.type===1;e=e.parent)if(e.ns===`http://www.w3.org/2000/svg`&&e.name===`svg`)return e.node;return null}get viewportElement(){return this.ownerSVGElement}};installHTMLOrSVGElement(SVGElement);function installURIReference(e){Object.defineProperty(e.prototype,"href",{get(){let e=this[Lf];return e===void 0&&(e=new SVGAnimatedString(this,`href`),Object.defineProperty(this,Lf,{value:e})),e},configurable:!0,enumerable:!0})}var SVGGraphicsElement=class extends SVGElement{getBBox(){return new us}getCTM(){return new Is}getScreenCTM(){return new Is}},SVGGeometryElement=class extends SVGGraphicsElement{isPointInFill(){return!1}isPointInStroke(){return!1}getTotalLength(){return 0}getPointAtLength(){return new ls}},SVGSVGElement=class extends SVGGraphicsElement{createSVGNumber(){return new SVGNumber}createSVGLength(){return{unitType:0,value:0,valueInSpecifiedUnits:0,valueAsString:`0`}}createSVGAngle(){return{unitType:0,value:0,valueInSpecifiedUnits:0,valueAsString:`0`}}createSVGPoint(){return new ls}createSVGMatrix(){return new Is}createSVGRect(){return new us}createSVGTransform(){return{type:0,matrix:new Is,angle:0}}getIntersectionList(){return[]}getEnclosureList(){return[]}checkIntersection(){return!1}checkEnclosure(){return!1}deselectAll(){}suspendRedraw(){return 0}unsuspendRedraw(){}unsuspendRedrawAll(){}forceRedraw(){}pauseAnimations(){}unpauseAnimations(){}animationsPaused(){return!1}getCurrentTime(){return 0}setCurrentTime(){}getElementById(e){let t=this[z];for(let n=t.first;n!==null;n=nextEl(n,t))if(n.type===1&&n.id===String(e))return n.node;return null}};installFitToViewBox(SVGSVGElement);function nextEl(e,t){if(e.first!==null)return e.first;for(let n=e;n!==null&&n!==t;n=n.parent)if(n.next!==null)return n.next;return null}var SVGGElement=class extends SVGGraphicsElement{},SVGDefsElement=class extends SVGGraphicsElement{},SVGDescElement=class extends SVGElement{},SVGMetadataElement=class extends SVGElement{},SVGTitleElement=class extends SVGElement{},SVGSymbolElement=class extends SVGGraphicsElement{};installFitToViewBox(SVGSymbolElement);var SVGUseElement=class extends SVGGraphicsElement{};installURIReference(SVGUseElement);var SVGSwitchElement=class extends SVGGraphicsElement{},SVGImageElement=class extends SVGGraphicsElement{};installURIReference(SVGImageElement);var SVGForeignObjectElement=class extends SVGGraphicsElement{},SVGAElement=class extends SVGGraphicsElement{};installURIReference(SVGAElement);var SVGPathElement=class extends SVGGeometryElement{},SVGRectElement=class extends SVGGeometryElement{},SVGCircleElement=class extends SVGGeometryElement{},SVGEllipseElement=class extends SVGGeometryElement{},SVGLineElement=class extends SVGGeometryElement{},SVGPolylineElement=class extends SVGGeometryElement{},SVGPolygonElement=class extends SVGGeometryElement{},SVGTextContentElement=class extends SVGGraphicsElement{getNumberOfChars(){return(this.textContent??``).length}getComputedTextLength(){return 0}getSubStringLength(){return 0}},SVGTextPositioningElement=class extends SVGTextContentElement{},SVGTextElement=class extends SVGTextPositioningElement{},SVGTSpanElement=class extends SVGTextPositioningElement{},SVGTextPathElement=class extends SVGTextContentElement{};installURIReference(SVGTextPathElement);var SVGMarkerElement=class extends SVGElement{};installFitToViewBox(SVGMarkerElement);var SVGClipPathElement=class extends SVGElement{},SVGMaskElement=class extends SVGElement{},SVGPatternElement=class extends SVGElement{};installFitToViewBox(SVGPatternElement),installURIReference(SVGPatternElement);var SVGGradientElement=class extends SVGElement{};installURIReference(SVGGradientElement);var SVGLinearGradientElement=class extends SVGGradientElement{},SVGRadialGradientElement=class extends SVGGradientElement{},SVGStopElement=class extends SVGElement{},SVGStyleElement=class extends SVGElement{},SVGScriptElement=class extends SVGElement{};installURIReference(SVGScriptElement);var SVGViewElement=class extends SVGElement{};installFitToViewBox(SVGViewElement);var SVGFilterElement=class extends SVGElement{};const Rf=/* @__PURE__ */ new Map([[`svg`,SVGSVGElement],[`g`,SVGGElement],[`defs`,SVGDefsElement],[`desc`,SVGDescElement],[`metadata`,SVGMetadataElement],[`title`,SVGTitleElement],[`symbol`,SVGSymbolElement],[`use`,SVGUseElement],[`switch`,SVGSwitchElement],[`image`,SVGImageElement],[`foreignObject`,SVGForeignObjectElement],[`a`,SVGAElement],[`path`,SVGPathElement],[`rect`,SVGRectElement],[`circle`,SVGCircleElement],[`ellipse`,SVGEllipseElement],[`line`,SVGLineElement],[`polyline`,SVGPolylineElement],[`polygon`,SVGPolygonElement],[`text`,SVGTextElement],[`tspan`,SVGTSpanElement],[`textPath`,SVGTextPathElement],[`marker`,SVGMarkerElement],[`clipPath`,SVGClipPathElement],[`mask`,SVGMaskElement],[`pattern`,SVGPatternElement],[`linearGradient`,SVGLinearGradientElement],[`radialGradient`,SVGRadialGradientElement],[`stop`,SVGStopElement],[`style`,SVGStyleElement],[`script`,SVGScriptElement],[`view`,SVGViewElement],[`filter`,SVGFilterElement]]);var MathMLElement=class extends Rs{get style(){return this[Wr]??=new CSSStyleDeclaration(this)}set style(e){this.style.cssText=String(e)}};installHTMLOrSVGElement(MathMLElement);const zf=/* @__PURE__ */ new Map([[`off`,0],[`on`,1],[`webauthn`,4]]);for(let e of/* @__PURE__ */ `name.honorific-prefix.given-name.additional-name.family-name.honorific-suffix.nickname.organization-title.username.new-password.current-password.one-time-code.organization.street-address.address-line1.address-line2.address-line3.address-level4.address-level3.address-level2.address-level1.country.country-name.postal-code.cc-name.cc-given-name.cc-additional-name.cc-family-name.cc-number.cc-exp.cc-exp-month.cc-exp-year.cc-csc.cc-type.transaction-currency.transaction-amount.language.bday.bday-day.bday-month.bday-year.sex.url.photo`.split(`.`))zf.set(e,2);for(let e of[`tel`,`tel-country-code`,`tel-national`,`tel-area-code`,`tel-local`,`tel-local-prefix`,`tel-local-suffix`,`tel-extension`,`email`,`impp`])zf.set(e,3);const Bf=[1,1,3,4,5];function idlExposedAutofillValue(e){let t=attr(e,`autocomplete`);if(t===null)return``;let n=splitOnAsciiWhitespace(t);if(n.length===0)return``;let r=n.length-1,i=asciiLowercase$1(n[r]),a=zf.get(i);if(a===void 0||n.length>Bf[a])return``;if(a===0||a===1)return e.tag===Z.input&&inputType(e)===0?``:i;let o=i;if(a===4){if(r===0)return o;r--;let e=asciiLowercase$1(n[r]);if(a=zf.get(e),a!==2&&a!==3||r>Bf[a]-1)return``;o=e+` `+o}if(r===0)return o;r--;let s=asciiLowercase$1(n[r]);if(a===3&&(s===`home`||s===`work`||s===`mobile`||s===`fax`||s===`pager`)){if(o=s+` `+o,r===0)return o;r--,s=asciiLowercase$1(n[r])}if(s===`shipping`||s===`billing`){if(o=s+` `+o,r===0)return o;r--,s=asciiLowercase$1(n[r])}return r!==0||!s.startsWith(`section-`)?``:s+` `+o}function installAutocomplete(e){Object.defineProperty(e.prototype,"autocomplete",{get(){return idlExposedAutofillValue(this[z])},set(e){setAttribute(this[z],`autocomplete`,String(e))},enumerable:!0,configurable:!0})}const Vf=/^-?(?:\d+|\d*\.\d+)(?:[eE][-+]?\d+)?$/;function parseFloatStrict(e){if(!Vf.test(e))return NaN;let t=Number(e);return Number.isFinite(t)?t:NaN}function parseFloatLenient(e){let t=/^[\t\n\f\r ]*([-+]?(?:\d+(?:\.\d+)?|\.\d+)(?:[eE][-+]?\d+)?)/.exec(e);if(t===null)return NaN;let n=Number(t[1]);return Number.isFinite(n)?n===0?0:n:NaN}function serializeFloat(e){return String(e===0?0:e)}function isLeapYear(e){return e%400==0||e%4==0&&e%100!=0}const Hf=[31,28,31,30,31,30,31,31,30,31,30,31];function daysInMonth(e,t){return e===2&&isLeapYear(t)?29:Hf[e-1]}function utcMs(e,t=1,n=1,r=0,i=0,a=0,o=0){if(e>99||e<0)return Date.UTC(e,t-1,n,r,i,a,o);let s=/* @__PURE__ */ new Date(0);return s.setUTCFullYear(e,t-1,n),s.setUTCHours(r,i,a,o),s.getTime()}const Uf=/^(\d{4,})-(\d{2})$/,Wf=/^(\d{4,})-(\d{2})-(\d{2})$/,Gf=/^(\d{2}):(\d{2})(?::(\d{2})(?:\.(\d{1,3}))?)?$/,Kf=/^(\d{4,})-W(\d{2})$/;function isValidDateString(e){let t=Wf.exec(e);if(t===null)return!1;let n=Number(t[1]),r=Number(t[2]),i=Number(t[3]);return n>0&&r>=1&&r<=12&&i>=1&&i<=daysInMonth(r,n)}function isValidMonthString(e){let t=Uf.exec(e);if(t===null)return!1;let n=Number(t[2]);return Number(t[1])>0&&n>=1&&n<=12}function isValidWeekString(e){let t=Kf.exec(e);if(t===null)return!1;let n=Number(t[1]),r=Number(t[2]);return n>0&&r>=1&&r<=lastWeekNumber(n)}function normalizeLocalDateTime(e){let t=e.indexOf(`T`);if(t===-1&&(t=e.indexOf(` `)),t===-1)return``;let n=e.slice(0,t);if(!isValidDateString(n))return``;let r=parseTime(e.slice(t+1));return Number.isNaN(r)?``:n+`T`+serializeTime(r)}function parseMonth(e){let t=Uf.exec(e);if(t===null)return NaN;let n=Number(t[1]),r=Number(t[2]);return n<=0||r<1||r>12?NaN:(n-1970)*12+(r-1)}function parseDate(e){let t=Wf.exec(e);if(t===null)return NaN;let n=Number(t[1]),r=Number(t[2]),i=Number(t[3]);return n<=0||r<1||r>12||i<1||i>daysInMonth(r,n)?NaN:utcMs(n,r,i)}function parseTime(e){let t=Gf.exec(e);if(t===null)return NaN;let n=Number(t[1]),r=Number(t[2]),i=t[3]===void 0?0:Number(t[3]),a=t[4]===void 0?0:Number(t[4].padEnd(3,`0`));return n>23||r>59||i>59?NaN:((n*60+r)*60+i)*1e3+a}function parseLocalDateTime(e){let t=e.indexOf(`T`);if(t===-1&&(t=e.indexOf(` `)),t===-1)return NaN;let n=parseDate(e.slice(0,t));if(Number.isNaN(n))return NaN;let r=parseTime(e.slice(t+1));return Number.isNaN(r)?NaN:n+r}function lastWeekNumber(e){let t=new Date(utcMs(e)).getUTCDay();return t===4||isLeapYear(e)&&t===3?53:52}function parseWeek(e){let t=Kf.exec(e);if(t===null)return NaN;let n=Number(t[1]),r=Number(t[2]);if(n<=0||r<1||r>lastWeekNumber(n))return NaN;let i=utcMs(n),a=(new Date(i).getUTCDay()+6)%7;return(a<=3?i-a*864e5:i+(7-a)*864e5)+(r-1)*7*864e5}function pad(e,t){return String(e).padStart(t,`0`)}function serializeDate(e){let t=new Date(e);return`${pad(t.getUTCFullYear(),4)}-${pad(t.getUTCMonth()+1,2)}-${pad(t.getUTCDate(),2)}`}function serializeMonth(e){let t=1970+Math.floor(e/12),n=(e%12+12)%12;return`${pad(t,4)}-${pad(n+1,2)}`}function serializeTime(e){let t=(e%864e5+864e5)%864e5,n=Math.floor(t/36e5),r=Math.floor(t/6e4)%60,i=Math.floor(t/1e3)%60,a=Math.round(t%1e3),o=`${pad(n,2)}:${pad(r,2)}`;return(i!==0||a!==0)&&(o+=`:`+pad(i,2),a!==0&&(o+=`.`+pad(a,3).replace(/0+$/,``))),o}function serializeLocalDateTime(e){let t=Math.floor(e/864e5)*864e5;return serializeDate(t)+`T`+serializeTime(e-t)}function serializeWeek(e){let t=(new Date(e).getUTCDay()+6)%7,n=new Date(e+(3-t)*864e5),r=n.getUTCFullYear(),i=utcMs(r),a=Math.floor((n.getTime()-i)/864e5/7)+1;return`${pad(r,4)}-W${pad(a,2)}`}function isValidSimpleColor(e){return/^#[0-9a-fA-F]{6}$/.test(e)}const qf=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;function isValidEmail(e){return qf.test(e)}function isValidAbsoluteURL(e){return URL.canParse(e)}const Jf=Symbol(`FileList`);var FileList=class{constructor(e,t){if(e!==Jf)throw TypeError(`Illegal constructor`);let n=t??[];for(let e=0;e<n.length;e++)Object.defineProperty(this,e,{value:n[e],enumerable:!0,configurable:!1,writable:!1});Object.defineProperty(this,"length",{value:n.length,enumerable:!1,configurable:!1,writable:!1})}item(e){let t=Number(e)>>>0;return t<this.length?this[t]:null}*[Symbol.iterator](){for(let e=0;e<this.length;e++)yield this[e]}get[Symbol.toStringTag](){return`FileList`}};function createFileList(e){return new FileList(Jf,e)}var ControlState=class{value;dirtyValue;checked;checkedSet;dirtyChecked;indeterminate;files;selStart;selEnd;selDir;userEdited;badInput;uiValue;tracker;rawText;apiText;constructor(){this.value=``,this.dirtyValue=!1,this.checked=!1,this.checkedSet=!1,this.dirtyChecked=!1,this.indeterminate=!1,this.files=null,this.selStart=0,this.selEnd=0,this.selDir=`none`,this.userEdited=!1,this.badInput=!1,this.uiValue=null,this.tracker=null,this.rawText=null,this.apiText=``}};function toFileList(e){if(e instanceof FileList)return e;if(typeof e==`object`&&e&&typeof e.length==`number`){let t=e,n=[];for(let e=0;e<t.length;e++)n.push(t[e]);return createFileList(n)}throw TypeError(`Failed to set the 'files' property on 'HTMLInputElement': The provided value is not of type 'FileList'.`)}function sanitizeValue(e,t,n){switch(e){case 1:case 2:case 3:case 6:return stripNewlines(t);case 4:return trimASCII(stripNewlines(t));case 5:{if(attr(n,`multiple`)===null||t.indexOf(`,`)===-1)return trimASCII(stripNewlines(t));let e=t.split(`,`);for(let t=0;t<e.length;t++)e[t]=trimASCII(stripNewlines(e[t]));return e.join(`,`)}case 12:return Number.isNaN(parseFloatStrict(t))?``:t;case 13:return sanitizeRange(t,n);case 7:return isValidDateString(t)?t:``;case 8:return isValidMonthString(t)?t:``;case 9:return isValidWeekString(t)?t:``;case 10:return Number.isNaN(parseTime(t))?``:t;case 11:return normalizeLocalDateTime(t);case 14:return isValidSimpleColor(t)?t.toLowerCase():`#000000`}return t}function sanitizeRange(e,t){let n=rangeMin(t),r=rangeMax(t);r<n&&(r=n);let i=parseFloatStrict(e),a=Number.isNaN(i)?n+(r-n)/2:i;a<n&&(a=n),a>r&&(a=r);let o=allowedStep(13,t);if(!Number.isNaN(o)){let e=stepBase(13,t),n=(a-e)/o,i=Math.round(n);if(!isIntegral(n)){let t=roundForStep(e+i*o,o,e);t>r&&(t=roundForStep(e+Math.floor((r-e)/o)*o,o,e)),a=t}}return a===i?e:serializeFloat(a)}function rangeMin(e){let t=attr(e,`min`),n=t===null?NaN:parseFloatLenient(t);return Number.isNaN(n)?0:n}function rangeMax(e){let t=attr(e,`max`),n=t===null?NaN:parseFloatLenient(t);return Number.isNaN(n)?100:n}function stringToNumber(e,t){switch(e){case 12:case 13:return parseFloatStrict(t);case 7:return parseDate(t);case 8:return parseMonth(t);case 9:return parseWeek(t);case 10:return parseTime(t);case 11:return parseLocalDateTime(t)}return NaN}function numberToString(e,t){switch(e){case 12:case 13:return serializeFloat(t);case 7:return serializeDate(t);case 8:return serializeMonth(t);case 9:return serializeWeek(t);case 10:return serializeTime(t);case 11:return serializeLocalDateTime(t)}return``}function attrToNumber(e,t){return t===null?NaN:e===12||e===13?parseFloatLenient(t):stringToNumber(e,t)}function defaultStep(e){return e===10||e===11?60:1}function stepScale(e){switch(e){case 7:return 864e5;case 9:return 6048e5;case 10:case 11:return 1e3}return 1}function allowedStep(e,t){let n=attr(t,`step`);if(n!==null){if(n.toLowerCase()===`any`)return NaN;let t=parseFloatLenient(n);if(!Number.isNaN(t)&&t>0)return(e===7||e===8||e===9)&&(t=Math.max(1,Math.round(t))),t*stepScale(e)}return defaultStep(e)*stepScale(e)}function stepBase(e,t){let n=attrToNumber(e,attr(t,`min`));return!Number.isNaN(n)||(n=attrToNumber(e,attr(t,`value`)),!Number.isNaN(n))?n:e===9?-2592e5:0}function minimum(e,t){return e===13?rangeMin(t):attrToNumber(e,attr(t,`min`))}function maximum(e,t){if(e===13){let e=rangeMin(t),n=rangeMax(t);return n<e?e:n}return attrToNumber(e,attr(t,`max`))}function isStepAligned(e,t,n){let r=(e-t)/n;if(Math.abs(r)<1e6)return isIntegral(r);let i=toDecimal(e),a=toDecimal(t),o=toDecimal(n);if(i===null||a===null||o===null)return isIntegral(r);let s=Math.min(i.exp,a.exp,o.exp),scale=e=>e.digits*10n**BigInt(e.exp-s),c=scale(o);return c===0n||(scale(i)-scale(a))%c===0n}function toDecimal(e){if(!Number.isFinite(e))return null;let t=/^(-?)(\d+)(?:\.(\d+))?(?:e([+-]\d+))?$/.exec(String(e));if(t===null)return null;let n=t[3]??``,r=(t[4]===void 0?0:Number(t[4]))-n.length;if(r<-400||r>400)return null;let i=BigInt(t[2]+n);return{digits:t[1]===`-`?-i:i,exp:r}}function isIntegral(e){return Math.abs(e-Math.round(e))<1e-9*Math.max(1,Math.abs(e))}function decimals(e){let t=String(e),n=t.indexOf(`e-`);if(n!==-1)return Number(t.slice(n+2))+(t.indexOf(`.`)===-1?0:n-t.indexOf(`.`)-1);let r=t.indexOf(`.`);return r===-1?0:t.length-r-1}function roundForStep(e,t,n){let r=Math.min(15,Math.max(decimals(t),decimals(n))),i=Number(e.toFixed(r));return i===0?0:i}var HTMLInputElement=class extends HTMLElement{[N];constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=12,this[N]=new ControlState}get type(){return xa[inputType(this[z])]}set type(e){setAttribute(this[z],`type`,String(e))}_currentValue(e){return this[N].dirtyValue?this[N].value:sanitizeValue(e,attr(this[z],`value`)??``,this[z])}get value(){let e=this[z],t=inputType(e);switch(valueMode(t)){case 0:return this._currentValue(t);case 1:return attr(e,`value`)??``;case 2:return attr(e,`value`)??`on`}let n=this[N].files;return n===null||n.length===0?``:`C:\\fakepath\\`+n.item(0).name}set value(e){let t=e===null?``:String(e),n=this[z],r=inputType(n);switch(valueMode(r)){case 0:this._setValueFromAPI(r,t);return;case 1:case 2:setAttribute(n,`value`,t);return}if(t!==``)throw new DOMException(`Failed to set the 'value' property on 'HTMLInputElement': This input element accepts a filename, which may only be programmatically set to the empty string.`,`InvalidStateError`);this[N].files=null}_setValueFromAPI(e,t){let n=this._currentValue(e);if(this[z].doc[J]++,this[N].value=sanitizeValue(e,t,this[z]),this[N].dirtyValue=!0,this[N].userEdited=!1,this[N].badInput=!1,this[N].uiValue=null,this[N].value!==n){let e=this[N].value.length;this[N].selStart=e,this[N].selEnd=e,this[N].selDir=`none`}}_checkedness(){return this[N].checkedSet?this[N].checked:attr(this[z],`checked`)!==null}_setCheckedness(e,t){return this[z].doc[J]++,this[N].checked=e,this[N].checkedSet=!0,t&&(this[N].dirtyChecked=!0),e&&inputType(this[z])===16?uncheckOtherRadios(this[z]):null}get checked(){return this._checkedness()}set checked(e){this._setCheckedness(!!e,!0)}get indeterminate(){return this[N].indeterminate}set indeterminate(e){this[z].doc[J]++,this[N].indeterminate=!!e}get files(){return inputType(this[z])===17?this[N].files??=createFileList([]):null}set files(e){inputType(this[z])===17&&e!=null&&(this[N].files=toFileList(e))}get valueAsNumber(){let e=inputType(this[z]);return isNumericType(e)?stringToNumber(e,this._currentValue(e)):NaN}set valueAsNumber(e){let t=Number(e);if(!Number.isFinite(t)&&!Number.isNaN(t))throw TypeError(`Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The value provided is infinite.`);let n=inputType(this[z]);if(!isNumericType(n))throw new DOMException(`Failed to set the 'valueAsNumber' property on 'HTMLInputElement': This input element does not support Number values.`,`InvalidStateError`);this._setValueFromAPI(n,Number.isNaN(t)?``:numberToString(n,t))}get valueAsDate(){let e=inputType(this[z]);if(e!==7&&e!==8&&e!==9&&e!==10)return null;let t=stringToNumber(e,this._currentValue(e));return Number.isNaN(t)?null:e===8?new Date(utcMs(1970+Math.floor(t/12),(t%12+12)%12+1)):new Date(t)}set valueAsDate(e){let t=inputType(this[z]);if(t!==7&&t!==8&&t!==9&&t!==10)throw new DOMException(`Failed to set the 'valueAsDate' property on 'HTMLInputElement': This input element does not support Date values.`,`InvalidStateError`);if(e===null){this._setValueFromAPI(t,``);return}let n;try{n=Date.prototype.getTime.call(e)}catch{throw TypeError(`Failed to set the 'valueAsDate' property on 'HTMLInputElement': The provided value is not a Date.`)}if(Number.isNaN(n)){this._setValueFromAPI(t,``);return}let r=n;if(t===8){let e=new Date(n);r=(e.getUTCFullYear()-1970)*12+e.getUTCMonth()}this._setValueFromAPI(t,numberToString(t,r))}stepUp(e=1){this._stepUpOrDown(Number(e)|0,!0)}stepDown(e=1){this._stepUpOrDown(Number(e)|0,!1)}_stepUpOrDown(e,t){let n=this[z],r=inputType(n),i=t?`stepUp`:`stepDown`;if(!isNumericType(r))throw new DOMException(`Failed to execute '${i}' on 'HTMLInputElement': This form element is not steppable.`,`InvalidStateError`);let a=allowedStep(r,n);if(Number.isNaN(a))throw new DOMException(`Failed to execute '${i}' on 'HTMLInputElement': This form element does not have an allowed value step.`,`InvalidStateError`);let o=minimum(r,n),s=maximum(r,n);if(!Number.isNaN(o)&&!Number.isNaN(s)&&o>s)return;let c=stepBase(r,n);if(!Number.isNaN(o)&&!Number.isNaN(s)&&c+Math.ceil((o-c)/a-1e-9)*a>s+1e-9)return;let l=stringToNumber(r,this._currentValue(r)),u=!Number.isNaN(l);u||(l=0);let d=l,m=(l-c)/a;isIntegral(m)?l+=(t?e:-e)*a:l=c+(t?Math.ceil(m):Math.floor(m))*a,l=roundForStep(l,a,c),!Number.isNaN(o)&&l<o?l=roundForStep(c+Math.ceil((o-c)/a-1e-9)*a,a,c):!Number.isNaN(s)&&l>s&&(l=roundForStep(c+Math.floor((s-c)/a+1e-9)*a,a,c)),!(u&&(t&&l<d||!t&&l>d))&&this._setValueFromAPI(r,numberToString(r,l))}_selectionLength(){return this.value.length}_assertSelectable(e){if(!supportsSelectionType(inputType(this[z])))throw new DOMException(`Failed to ${e.endsWith(`)`)?`execute`:`set`} '${e.replace(`()`,``)}' on 'HTMLInputElement': The input element's type ('${this.type}') does not support selection.`,`InvalidStateError`)}get selectionStart(){return supportsSelectionType(inputType(this[z]))?Math.min(this[N].selStart,this._selectionLength()):null}set selectionStart(e){this._assertSelectable(`selectionStart`);let t=toUnsignedLong(e),n=Math.max(t,this.selectionEnd);setSelection(this,t,n,this[N].selDir)}get selectionEnd(){return supportsSelectionType(inputType(this[z]))?Math.min(this[N].selEnd,this._selectionLength()):null}set selectionEnd(e){this._assertSelectable(`selectionEnd`),setSelection(this,this.selectionStart,toUnsignedLong(e),this[N].selDir)}get selectionDirection(){return supportsSelectionType(inputType(this[z]))?this[N].selDir:null}set selectionDirection(e){this._assertSelectable(`selectionDirection`),setSelection(this,this.selectionStart,this.selectionEnd,String(e))}setSelectionRange(e,t,n){this._assertSelectable(`setSelectionRange()`),setSelection(this,toUnsignedLong(e),toUnsignedLong(t),n===void 0?`none`:String(n))}select(){selectApplies(inputType(this[z]))&&setSelection(this,0,this._selectionLength(),`none`)}setRangeText(e,t,n,r){if(arguments.length===0)throw TypeError(`Failed to execute 'setRangeText' on 'HTMLInputElement': 1 argument required, but only 0 present.`);this._assertSelectable(`setRangeText()`);let i=rangeText(this.value,this[N].selStart,this[N].selEnd,String(e),t,n,r,arguments.length),a=inputType(this[z]);this[z].doc[J]++,this[N].value=sanitizeValue(a,i.value,this[z]),this[N].dirtyValue=!0,this[N].uiValue=null,setSelection(this,i.start,i.end,`none`)}get height(){return dimensionAttr(this[z],`height`)}set height(e){let t=toUnsignedLong(e);setAttribute(this[z],`height`,String(t<=2147483647?t:0))}get width(){return dimensionAttr(this[z],`width`)}set width(e){let t=toUnsignedLong(e);setAttribute(this[z],`width`,String(t<=2147483647?t:0))}get formAction(){return reflectActionURL(this[z],`formaction`)}set formAction(e){setAttribute(this[z],`formaction`,String(e))}get list(){let e=this[z];if(!listApplies(inputType(e)))return null;let t=attr(e,`list`);if(t===null)return null;let n=elementByIdInTree(e,t);return n!==null&&n.tag===Z.datalist?n.node:null}get form(){let e=formOwner(this[z]);return e===null?null:e.node}get labels(){return inputType(this[z])===0?null:this[In]??=new LabelsNodeList(this[z])}showPicker(){if(!this._isMutable())throw new DOMException(`Failed to execute 'showPicker' on 'HTMLInputElement': HTMLInputElement::showPicker() cannot be used on immutable controls.`,`InvalidStateError`)}_isMutable(){let e=this[z];return!isActuallyDisabled(e)&&!(readonlyApplies(inputType(e))&&attr(e,`readonly`)!==null)}_barredFromValidation(){let e=this[z],t=inputType(e);return t===0||t===20||t===21||readonlyApplies(t)&&attr(e,`readonly`)!==null?!0:isActuallyDisabled(e)||hasDatalistAncestor(e)}_validityFlags(){let e=this[z],t=inputType(e),n=this[kt]?512:0,r=valueMode(t);if(requiredApplies(t)&&attr(e,`required`)!==null?t===15?this._checkedness()||(n|=1):t===16?radioGroupMissing(e)&&(n|=1):t===17?(this[N].files===null||this[N].files.length===0)&&(n|=1):r===0&&this._isMutable()&&this._currentValue(t)===``&&(n|=1):t===16&&radioGroupMissing(e)&&(n|=1),r!==0)return n;let i=this._currentValue(t);if(this[N].badInput&&(n|=256),i===``)return n;if(t===5){if(attr(e,`multiple`)!==null){let e=i.split(`,`);for(let t=0;t<e.length;t++)if(!isValidEmail(e[t])){n|=2;break}}else isValidEmail(i)||(n|=2)}else t===4&&!isValidAbsoluteURL(i)&&(n|=2);if(lengthApplies(t)){let r=attr(e,`pattern`);if(r!==null){let a=compilePattern(r);if(a!==null){if(t===5&&attr(e,`multiple`)!==null){let e=i.split(`,`);for(let t=0;t<e.length;t++)if(!a.test(e[t])){n|=4;break}}else a.test(i)||(n|=4)}}if(this[N].userEdited){let t=readNonNegativeLong(e,`maxlength`,-1);t!==-1&&i.length>t&&(n|=8);let r=readNonNegativeLong(e,`minlength`,-1);r!==-1&&i.length<r&&(n|=16)}}if(isNumericType(t)){let r=stringToNumber(t,i);if(!Number.isNaN(r)){let i=minimum(t,e),a=maximum(t,e);t===10&&!Number.isNaN(i)&&!Number.isNaN(a)&&i>a?r<i&&r>a&&(n|=96):(!Number.isNaN(i)&&r<i&&(n|=32),!Number.isNaN(a)&&r>a&&(n|=64));let o=allowedStep(t,e);!Number.isNaN(o)&&!isStepAligned(r,stepBase(t,e),o)&&(n|=128)}}return n}_validationMessage(e){let t=this[z],n=inputType(t);if(e&1)return n===15?`Please check this box if you want to proceed.`:n===16?`Please select one of these options.`:n===17?`Please select a file.`:Ac;if(e&256)return n===12?`Please enter a number.`:jc;let r=this._currentValue(n);if(e&2)return n===5?msgEmail(r):`Please enter a URL.`;if(e&4)return`Please match the requested format.`;if(e&8)return msgTooLong(this.maxLength,r.length);if(e&16)return msgTooShort(this.minLength,r.length);let i=n!==12&&n!==13;if(e&32)return msgUnderflow(numberToString(n,minimum(n,t)),i);if(e&64)return msgOverflow(numberToString(n,maximum(n,t)),i);if(e&128){let e=stringToNumber(n,r),i=allowedStep(n,t),a=stepBase(n,t),o=roundForStep(a+Math.floor((e-a)/i)*i,i,a),s=roundForStep(o+i,i,a),c=minimum(n,t),l=maximum(n,t);return msgStep(!Number.isNaN(c)&&o<c?null:numberToString(n,o),!Number.isNaN(l)&&s>l?null:numberToString(n,s))}return this[kt]??``}_reset(){this[si]&&(this[si]=!1),this[N].dirtyValue=!1,this[N].dirtyChecked=!1,this[N].userEdited=!1,this[N].badInput=!1,this[N].uiValue=null,this[N].value=``,this[N].files=null,this._setCheckedness(attr(this[z],`checked`)!==null,!1)}_attributeChangedSteps(e,t,n,r){if(super._attributeChangedSteps(e,t,n,r),r===null)switch(e){case`type`:{let e=inputTypeFromAttr(t),r=inputTypeFromAttr(n);if(e!==r){let t=this[z];if(t.flags&1){let n=attr(t,`name`);reindexRadio(t,radioKey(e,n),radioKey(r,n))}this._typeChange(e,r)}break}case`checked`:this[N].dirtyChecked||this._setCheckedness(n!==null,!1);break;case`name`:{let e=this[z];if(e.flags&1){let r=inputType(e);reindexRadio(e,radioKey(r,t),radioKey(r,n))}}case`form`:inputType(this[z])===16&&this._checkedness()&&uncheckOtherRadios(this[z]);break;case`multiple`:this[N].dirtyValue&&inputType(this[z])===5&&(this[N].value=sanitizeValue(5,this[N].value,this[z]))}}_typeChange(e,t){let n=this[z];(e===19||t===19)&&n.doc[tn]++,(e===0||t===0)&&n.doc[nn]++;let r=valueMode(e),i=valueMode(t);if(r===0&&(i===1||i===2)){let t=this[N].dirtyValue?this[N].value:sanitizeValue(e,attr(n,`value`)??``,n);this[N].dirtyValue=!1,t!==``&&setAttribute(n,`value`,t)}else(r!==0&&i===0||r!==3&&i===3)&&(this[N].dirtyValue=!1,this[N].value=``);r===3&&i!==3&&(this[N].files=null),t===16&&this._checkedness()&&uncheckOtherRadios(n),i===0&&this[N].dirtyValue&&(this[N].value=sanitizeValue(t,this[N].value,n)),this[N].uiValue=null,this[N].badInput=!1,!supportsSelectionType(e)&&supportsSelectionType(t)&&(this[N].selStart=0,this[N].selEnd=0,this[N].selDir=`none`)}_connectedSteps(){super._connectedSteps();let e=this[z],t=inputType(e);t===16&&(reindexRadio(e,null,radioKey(t,attr(e,`name`))),this._checkedness()&&radioInserted(e))}_disconnectedSteps(){super._disconnectedSteps();let e=this[z];reindexRadio(e,radioKey(inputType(e),attr(e,`name`)),null)}_cloningSteps(e){let t=e;t[N].value=this[N].value,t[N].dirtyValue=this[N].dirtyValue,t[N].checked=this._checkedness(),t[N].checkedSet=!0,t[N].dirtyChecked=this[N].dirtyChecked,t[N].indeterminate=this[N].indeterminate}get _hasActivationBehavior(){switch(inputType(this[z])){case 15:case 16:case 18:case 19:case 20:case 21:case 17:case 14:return!0}return!1}_legacyPreActivationBehavior(){let e=this[z],t=inputType(e);if(t===15){let e=this._checkedness(),t=this[N].indeterminate;return this._setCheckedness(!e,!0),this[N].indeterminate=!1,{checked:e,indeterminate:t,previousRadio:null}}if(t===16){let t=this._checkedness(),n=this._setCheckedness(!0,!0);return{checked:t,indeterminate:!1,previousRadio:t?e:n}}}_legacyCanceledActivationBehavior(e){if(e===void 0)return;let t=this[z],n=inputType(t);if(t.doc[J]++,n===15)this[N].checked=e.checked,this[N].checkedSet=!0,this[N].indeterminate=e.indeterminate;else if(n===16){let n=e.previousRadio;n!==null&&n!==t&&inSameRadioGroup(t,n)?n.node._setCheckedness(!0,!1):n!==t&&(this[N].checked=!1,this[N].checkedSet=!0)}}_activationBehavior(e,t){let n=this[z],r=inputType(n);if(r===15||r===16){if(!(n.flags&1)||r===16&&t?.checked)return;fireEvent$1(this,`input`,!0,!1,!0),fireEvent$1(this,`change`,!0,!1)}else if(this._isMutable()){if(r===18||r===19){if(r===19){let t=e;t!==null&&typeof t.offsetX==`number`&&typeof t.offsetY==`number`?ad.set(n,{x:t.offsetX,y:t.offsetY}):ad.delete(n)}let t=formOwner(n);t!==null&&submitForm(t,n,!1)}else if(r===20){let e=formOwner(n);e!==null&&n.flags&1&&resetForm(e)}popoverTargetAttributeActivation(n,e?.target?.[z]??null)}}};installConstraintValidation(HTMLInputElement),str(HTMLInputElement,`accept alt dirName=dirname formTarget=formtarget max min name pattern placeholder step useMap=usemap align defaultValue=value`),bool(HTMLInputElement,`disabled formNoValidate=formnovalidate multiple readOnly=readonly required defaultChecked=checked`),url(HTMLInputElement,`src`),ulong(HTMLInputElement,`size`,20,!0),nonNegativeLong(HTMLInputElement,`maxLength=maxlength minLength=minlength`,-1),enumerated(HTMLInputElement,`formEnctype=formenctype`,nd),enumerated(HTMLInputElement,`formMethod=formmethod`,rd);function dimensionAttr(e,t){return inputType(e)===19?readNonNegativeLong(e,t,0):0}function selectApplies(e){return e>=1&&e<=12||e===14||e===17}const Yf=/* @__PURE__ */ new Map;function compilePattern(e){let t=Yf.get(e);if(t!==void 0)return t;try{new RegExp(e,`v`),t=RegExp(`^(?:`+e+`)$`,`v`)}catch{t=null}return Yf.size>256&&Yf.clear(),Yf.set(e,t),t}function setSelection(e,t,n,r){let i=e._selectionLength();n>i&&(n=i),t>n&&(t=n);let a=r===`forward`||r===`backward`?r:`none`,o=t!==Math.min(e[N].selStart,i)||n!==Math.min(e[N].selEnd,i)||a!==e[N].selDir;if(e[N].selStart=t,e[N].selEnd=n,e[N].selDir=a,o){let t=e;queueElementTask(t,()=>fireEvent$1(t,`select`,!0,!1))}}function rangeText(e,t,n,r,i,a,o,s){let c=e.length;t=Math.min(t,c),n=Math.min(n,c);let l,u;if(s<2?(l=t,u=n):(l=toUnsignedLong(i),u=toUnsignedLong(a)),l>u)throw new DOMException(`Failed to execute 'setRangeText': The provided start value (${l}) is larger than the provided end value (${u}).`,`IndexSizeError`);l>c&&(l=c),u>c&&(u=c);let d=o===void 0?`preserve`:String(o);if(d!==`select`&&d!==`start`&&d!==`end`&&d!==`preserve`)throw TypeError(`Failed to execute 'setRangeText': The provided value '${d}' is not a valid enum value of type SelectionMode.`);let m=e.slice(0,l)+r+e.slice(u),h=l+r.length,_=t,v=n;switch(d){case`select`:_=l,v=h;break;case`start`:_=v=l;break;case`end`:_=v=h;break;default:{let e=r.length-(u-l);_>u?_+=e:_>l&&(_=l),v>u?v+=e:v>l&&(v=h)}}return{value:m,start:_,end:v}}function inSameRadioGroup(e,t){if(t.tag!==Z.input||inputType(t)!==16)return!1;let n=attr(e,`name`);return n===null||n===``||attr(t,`name`)!==n||treeRoot(e)!==treeRoot(t)?!1:formOwner(e)===formOwner(t)}function radioKey(e,t){return e===16&&t!==null&&t!==``?t:null}function reindexRadio(e,t,n){t!==n&&(t!==null&&radioIndexRemove(e.doc[fr],t,e),n!==null&&radioIndexAdd(e.doc[fr]??=/* @__PURE__ */ new Map,n,e))}function radioInserted(e){let t=connectingRoot(),n=!1;t!==null&&t!==e&&forEachInRadioGroup(e,e=>(n=isInclusiveAncestor(t,e)&&e.node._checkedness(),n)),n?uncheck(e):uncheckOtherRadios(e)}function uncheck(e){let t=e.node;if(t[N].checkedSet&&!t[N].checked)return!1;let n=t._checkedness();return e.doc[J]++,t[N].checked=!1,t[N].checkedSet=!0,n}function forEachInRadioGroup(e,t){let n=attr(e,`name`);if(n===null||n===``)return;let r=formOwner(e);if(e.flags&1){let i=e.doc[fr]?.get(n);if(i===void 0)return;let a=r===null?treeRoot(e):null;for(let n of i)if(!(n===e||formOwner(n)!==r||a!==null&&treeRoot(n)!==a)&&t(n))return;return}let i=r===null?treeRoot(e):formOwnerScope(r,!0);for(let a=i.type===1?i:nextElementInTree(i,i);a!==null;a=nextElementInTree(a,i))if(a!==e&&a.tag===Z.input&&attr(a,`name`)===n&&inputType(a)===16&&formOwner(a)===r&&t(a))return}function uncheckOtherRadios(e){let t=null;return forEachInRadioGroup(e,e=>(uncheck(e)&&t===null&&(t=e),!1)),t}function checkedRadioInGroup(e){if(e.node._checkedness())return e;let t=null;return forEachInRadioGroup(e,e=>e.node._checkedness()?(t=e,!0):!1),t}function radioGroupMissing(e){if(e.node._checkedness())return!1;let t=attr(e,`name`);if(t===null||t===``)return!1;let n=attr(e,`required`)!==null,r=!1;return forEachInRadioGroup(e,e=>e.node._checkedness()?(r=!0,!0):(attr(e,`required`)!==null&&(n=!0),!1)),n&&!r}function radioGroupHasNoChecked(e){return checkedRadioInGroup(e)===null}installAutocomplete(HTMLInputElement);function normalized(e,t){if(t===e.rawText)return e.apiText;let n=normalizeNewlines(t);return e.rawText=t,e.apiText=n,n}var HTMLTextAreaElement=class extends HTMLElement{[N];constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=16,this[N]=new ControlState}get type(){return`textarea`}get defaultValue(){let e=``;for(let t=this[z].first;t!==null;t=t.next)(t.type===3||t.type===4)&&(e+=t.data);return e}set defaultValue(e){this.textContent=String(e)}_apiValue(){let e=this[N];return e.dirtyValue?e.value:normalized(e,this.defaultValue)}get value(){return this._apiValue()}set value(e){let t=this._apiValue(),n=e===null?``:normalized(this[N],String(e));this[z].doc[J]++,this[N].value=n,this[N].dirtyValue=!0,this[N].userEdited=!1,n!==t&&(this[N].selStart=n.length,this[N].selEnd=n.length,this[N].selDir=`none`)}get textLength(){return this._apiValue().length}get form(){let e=formOwner(this[z]);return e===null?null:e.node}get labels(){return this[In]??=new LabelsNodeList(this[z])}_selectionLength(){return this._apiValue().length}get selectionStart(){return Math.min(this[N].selStart,this._selectionLength())}set selectionStart(e){let t=toUnsignedLong(e);setSelection(this,t,Math.max(t,this.selectionEnd),this[N].selDir)}get selectionEnd(){return Math.min(this[N].selEnd,this._selectionLength())}set selectionEnd(e){setSelection(this,this.selectionStart,toUnsignedLong(e),this[N].selDir)}get selectionDirection(){return this[N].selDir}set selectionDirection(e){setSelection(this,this.selectionStart,this.selectionEnd,String(e))}setSelectionRange(e,t,n){setSelection(this,toUnsignedLong(e),toUnsignedLong(t),n===void 0?`none`:String(n))}select(){setSelection(this,0,this._selectionLength(),`none`)}setRangeText(e,t,n,r){if(arguments.length===0)throw TypeError(`Failed to execute 'setRangeText' on 'HTMLTextAreaElement': 1 argument required, but only 0 present.`);let i=rangeText(this._apiValue(),this[N].selStart,this[N].selEnd,String(e),t,n,r,arguments.length);this[z].doc[J]++,this[N].value=normalizeNewlines(i.value),this[N].dirtyValue=!0,setSelection(this,i.start,i.end,`none`)}_isMutable(){return!isActuallyDisabled(this[z])&&contentAttr(this[z],`readonly`)===null}_barredFromValidation(){let e=this[z];return contentAttr(e,`readonly`)!==null||isActuallyDisabled(e)||hasDatalistAncestor(e)}_validityFlags(){let e=this[z],t=this[kt]?512:0,n=this._apiValue();if(contentAttr(e,`required`)!==null&&this._isMutable()&&n===``&&(t|=1),this[N].userEdited&&n!==``){let r=readNonNegativeLong(e,`maxlength`,-1);r!==-1&&n.length>r&&(t|=8);let i=readNonNegativeLong(e,`minlength`,-1);i!==-1&&n.length<i&&(t|=16)}return t}_validationMessage(e){if(e&1)return Ac;let t=this._apiValue().length;return e&8?msgTooLong(this.maxLength,t):e&16?msgTooShort(this.minLength,t):this[kt]??``}_reset(){this[si]&&(this[si]=!1),this[N].dirtyValue=!1,this[N].userEdited=!1,this[N].value=``}_childrenChangedSteps(){if(this[N].dirtyValue)return;let e=this._selectionLength();this[N].selStart>e&&(this[N].selStart=e),this[N].selEnd>e&&(this[N].selEnd=e)}_cloningSteps(e){let t=e;t[N].value=this[N].value,t[N].dirtyValue=this[N].dirtyValue}};installConstraintValidation(HTMLTextAreaElement),str(HTMLTextAreaElement,`dirName=dirname name placeholder wrap`),bool(HTMLTextAreaElement,`disabled readOnly=readonly required`),nonNegativeLong(HTMLTextAreaElement,`maxLength=maxlength minLength=minlength`,-1),positiveWithFallback(HTMLTextAreaElement,`cols`,`cols`,20),positiveWithFallback(HTMLTextAreaElement,`rows`,`rows`,2),installAutocomplete(HTMLTextAreaElement);const Xf={epoch:0};function optionSelect(e){let t=!1;for(let n=e.parent;n!==null;n=n.parent){if(n.type!==1||n.ns!==`http://www.w3.org/1999/xhtml`)continue;let e=n.tag;if(e===Z.select)return n;if(e===Z.datalist||e===Z.hr||e===Z.option)return null;if(e===Z.optgroup){if(t)return null;t=!0}}return null}var HTMLOptionElement=class extends HTMLElement{[kr];[Rt];constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=8,this[Rt]=!1}_selectednessNow(){if(this[kr]!==void 0)return this[kr];let e=optionSelect(this[z]);return e===null?contentAttr(this[z],`selected`)!==null:(e.node._ensureSettled(),this[kr]??=contentAttr(this[z],`selected`)!==null)}_setSelectedness(e){this[kr]!==e&&(this[z].doc[J]++,Xf.epoch++,this[kr]=e)}get selected(){return this._selectednessNow()}set selected(e){this._setSelectedness(!!e),this[Rt]=!0;let t=optionSelect(this[z]);t!==null&&t.node._selectednessSettingAlgorithm(e?this[z]:void 0)}get text(){let e=this[z],t=``;for(let n=e.first;n!==null;)n.tag===Z.script||n.ns===`http://www.w3.org/2000/svg`&&n.name===`script`?n=nextSkippingChildren(n,e):((n.type===3||n.type===4)&&(t+=n.data),n=nextInTree(n,e));return stripAndCollapseWS(t)}set text(e){this.textContent=String(e)}get value(){return contentAttr(this[z],`value`)??this.text}set value(e){this.setAttribute(`value`,String(e))}get label(){let e=contentAttr(this[z],`label`);return e===null?this.text:e}set label(e){this.setAttribute(`label`,String(e))}get index(){let e=optionSelect(this[z]);return e===null?0:scanOptions(e,(e,t)=>e===this[z]?t:void 0)??0}get form(){let e=optionSelect(this[z]);return e===null?null:e.node.form}_attributeChangedSteps(e,t,n,r){if(super._attributeChangedSteps(e,t,n,r),r!==null)return;if(e===`disabled`){t===null!=(n===null)&&resetOwnerSelect(this[z]);return}if(e!==`selected`||this[Rt])return;this._setSelectedness(n!==null);let i=optionSelect(this[z]);i!==null&&i.node._selectednessSettingAlgorithm(n===null?void 0:this[z])}_cloningSteps(e){let t=e;t[kr]=this._selectednessNow(),t[Rt]=this[Rt]}};bool(HTMLOptionElement,`defaultSelected=selected disabled`);const Zf=function Option(e,t,n,r){if(new.target===void 0)throw TypeError(`Failed to construct 'Option': Please use the 'new' operator, this DOM object constructor cannot be called as a function.`);let i=currentDocument(),a=i.createElement(`option`);return e!==void 0&&e!==``&&a.appendChild(i.createTextNode(String(e))),t!==void 0&&a.setAttribute(`value`,String(t)),n&&a.setAttribute(`selected`,``),a._setSelectedness(!!r),a};Zf.prototype=HTMLOptionElement.prototype;function resetOwnerSelect(e){let t=optionSelect(e);t!==null&&t.node[Pr]&&t.node._selectednessSettingAlgorithm()}var HTMLOptGroupElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=24}_attributeChangedSteps(e,t,n,r){super._attributeChangedSteps(e,t,n,r),r===null&&e===`disabled`&&t===null!=(n===null)&&resetOwnerSelect(this[z])}_childrenChangedSteps(){let e=this[z].parent;e!==null&&e.tag===Z.select&&e.node._selectednessSettingAlgorithm()}};bool(HTMLOptGroupElement,`disabled`),str(HTMLOptGroupElement,`label`);function opt(e){return e.node}function firstSelectedOption(e){return scanOptions(e,e=>opt(e)._selectednessNow()?e:void 0)}function settleFlatOptions(e,t){let n=!1;for(let r=e.first;r!==null;r=r.next)if(r.type===1){if(r.tag!==Z.option)return!1;if(t!==void 0)r!==t&&opt(r)._setSelectedness(!1);else if(opt(r)._selectednessNow()){if(n)return!1;n=!0}}return t!==void 0||n}function onlyOptions(e){for(let t=e.first;t!==null;t=t.next)if(t.tag!==Z.option||t.ns!==`http://www.w3.org/1999/xhtml`)return!1;return!0}var SelectedOptionsCollection=class extends io{_collect(e){scanOptions(this._s.root,t=>{opt(t)._selectednessNow()&&e.push(t.node)})}};Object.defineProperty(SelectedOptionsCollection.prototype,"constructor",{value:io,writable:!0,configurable:!0});var HTMLSelectElement=class extends HTMLElement{[V];[Or];[Pr];[ii];[Fr];[Ir];[Lr];[Rr];constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=28,this[V]=null,this[Or]=null,this[Pr]=!1,this[ii]=!1,this[Fr]=null,this[Ir]=0,this[Lr]=!0,this[Rr]=-1}_ensureSettled(){this[Pr]||this._selectednessSettingAlgorithm()}_cloningSteps(e){e[Pr]=this[Pr]}_connectedSteps(){super._connectedSteps(),this._ensureSettled()}get type(){return contentAttr(this[z],`multiple`)===null?`select-one`:`select-multiple`}_displaySize(){let e=contentAttr(this[z],`size`);if(e!==null){let t=parseNonNegativeInteger(e);if(!Number.isNaN(t))return t}return contentAttr(this[z],`multiple`)===null?1:4}_isSingle(){return contentAttr(this[z],`multiple`)===null}get options(){return this[V]??=new HTMLOptionsCollection(this[z])}get length(){let e=0;return scanOptions(this[z],()=>{e++}),e}set length(e){this.options.length=e}item(e){return this.options.item(e)}namedItem(e){return this.options.namedItem(e)}add(e,t=null){this.options.add(e,t)}remove(e){arguments.length===0?super.remove():this.options.remove(e)}get selectedOptions(){return this[Or]??=new SelectedOptionsCollection(this[z],!1,null)}get selectedIndex(){return scanOptions(this[z],(e,t)=>opt(e)._selectednessNow()?t:void 0)??-1}set selectedIndex(e){let t=Number(e)|0;scanOptions(this[z],(e,n)=>{let r=n===t;opt(e)._setSelectedness(r),r&&(opt(e)[Rt]=!0)}),this._updateSelectedContent()}get value(){let e=firstSelectedOption(this[z]);return e===void 0?``:opt(e).value}set value(e){let t=String(e),n=listOfOptions(this[z],[]),r=!1;for(let e=0;e<n.length;e++){let i=opt(n[e]);!r&&i.value===t?(i._setSelectedness(!0),i[Rt]=!0,r=!0):i._setSelectedness(!1)}this._updateSelectedContent()}get form(){let e=formOwner(this[z]);return e===null?null:e.node}get labels(){return this[In]??=new LabelsNodeList(this[z])}showPicker(){if(isActuallyDisabled(this[z]))throw new DOMException(`Failed to execute 'showPicker' on 'HTMLSelectElement': HTMLSelectElement::showPicker() cannot be used on immutable controls.`,`InvalidStateError`)}_deselectOthers(e){this._isSingle()&&scanOptions(this[z],t=>{t!==e&&opt(t)._setSelectedness(!1)})}_selectednessSettingAlgorithm(e){if(this[Pr]=!0,this._isSingle()){if(e!==void 0||this._displaySize()===1){if(settleFlatOptions(this[z],e))return;e===void 0?this._runSelectedness():this._deselectOthers(e)}this._updateSelectedContent()}}_runSelectedness(){let e;scanOptions(this[z],t=>{let n=opt(t);n._selectednessNow()&&(e?._setSelectedness(!1),e=n)}),e===void 0&&scanOptions(this[z],e=>isActuallyDisabled(e)?void 0:opt(e))?._setSelectedness(!0)}_enabledSelectedContent(){let e=this[z];if(contentAttr(e,`multiple`)!==null)return null;for(let t=e.first;t!==null;)if(t.type!==1||t.tag===Z.option||t.tag!==Z.selectedcontent)t=t.tag===Z.option?nextSkippingChildren(t,e):nextInTree(t,e);else{for(let n=t.parent;n!==null&&n!==e;n=n.parent)if(n.tag===Z.select)return null;return t}return null}_updateSelectedContent(){if(this[ii])return;let e=this._enabledSelectedContent();if(e!==null){this[ii]=!0;try{let t=firstSelectedOption(this[z]),n=e.node;if(t===void 0){n.replaceChildren();return}let r=this[z].doc.createDocumentFragment();for(let e=t.first;e!==null;e=e.next)r.appendChild(e.node.cloneNode(!0));n.replaceChildren(r)}finally{this[ii]=!1}}}_reset(){this[si]&&(this[si]=!1),this[Pr]=!0;let e=listOfOptions(this[z],[]);for(let t=0;t<e.length;t++){let n=opt(e[t]);n[Rt]=!1,n._setSelectedness(contentAttr(e[t],`selected`)!==null)}this._selectednessSettingAlgorithm()}_childrenChangedSteps(){let e=this[z],t=e.last,n=this[Lr]&&e.childCount===this[Ir]+1&&t!==null&&t.prev===this[Fr]&&t.tag===Z.option&&t.ns===`http://www.w3.org/1999/xhtml`;if(this[Fr]=t,this[Ir]=e.childCount,!n)this[Lr]=onlyOptions(e);else if(this[Rr]===Xf.epoch&&this._isSingle()&&this._displaySize()===1&&!opt(t)._selectednessNow())return;this._selectednessSettingAlgorithm(),this[Rr]=this[Lr]&&this._isSingle()&&this._displaySize()===1&&firstSelectedOption(e)!==void 0?Xf.epoch:-1}_attributeChangedSteps(e,t,n,r){super._attributeChangedSteps(e,t,n,r),r===null&&(e===`multiple`||e===`size`)&&this._selectednessSettingAlgorithm()}_barredFromValidation(){return isActuallyDisabled(this[z])||hasDatalistAncestor(this[z])}_isPlaceholderLabelOption(e){return e.parent===this[z]&&this._isSingle()&&this._displaySize()===1&&opt(e).value===``}_validityFlags(){let e=this[kt]?512:0;return contentAttr(this[z],`required`)!==null&&(scanOptions(this[z],(e,t)=>{if(opt(e)._selectednessNow()&&(t!==0||!this._isPlaceholderLabelOption(e)))return!0})||(e|=1)),e}_validationMessage(e){return e&1?`Please select an item in the list.`:this[kt]??``}};installConstraintValidation(HTMLSelectElement),str(HTMLSelectElement,`name`),addOptionIndexHost(HTMLSelectElement.prototype,e=>e.options),bool(HTMLSelectElement,`disabled multiple required`),ulong(HTMLSelectElement,`size`,0),installAutocomplete(HTMLSelectElement);var HTMLButtonElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r)}get type(){return buttonType(this[z])}set type(e){this.setAttribute(`type`,String(e))}get form(){let e=formOwner(this[z]);return e===null?null:e.node}get labels(){return this[In]??=new LabelsNodeList(this[z])}get formAction(){return reflectActionURL(this[z],`formaction`)}set formAction(e){this.setAttribute(`formaction`,String(e))}_barredFromValidation(){let e=this[z];return buttonType(e)!==`submit`||isActuallyDisabled(e)||hasDatalistAncestor(e)}_validityFlags(){return this[kt]?512:0}_validationMessage(e){return this[kt]??``}get _hasActivationBehavior(){return!0}_activationBehavior(e){let t=this[z];if(isActuallyDisabled(t))return;let n=formOwner(t);if(n!==null&&t.flags&1)switch(buttonType(t)){case`submit`:submitForm(n,t,!1);return;case`reset`:resetForm(n);return}buttonInvokerActivation(t,e?.target?.[z]??null)}};installConstraintValidation(HTMLButtonElement),str(HTMLButtonElement,`formTarget=formtarget name value`),bool(HTMLButtonElement,`disabled formNoValidate=formnovalidate`),enumerated(HTMLButtonElement,`formEnctype=formenctype`,nd),enumerated(HTMLButtonElement,`formMethod=formmethod`,rd);function isInteractiveContent(e){switch(e.tag){case Z.a:return contentAttr(e,`href`)!==null;case Z.audio:case Z.video:return contentAttr(e,`controls`)!==null;case Z.img:return contentAttr(e,`usemap`)!==null;case Z.input:return inputType(e)!==0;case Z.button:case Z.details:case Z.embed:case Z.iframe:case Z.label:case Z.select:case Z.textarea:return!0}return!1}var HTMLLabelElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r),this[z].flags|=12}_connectedSteps(){super._connectedSteps();let e=this[z],t=attr(e,`for`);t!==null&&addToElementIndex(e.doc[ln]??=/* @__PURE__ */ new Map,t,e)}_disconnectedSteps(){super._disconnectedSteps();let e=this[z],t=attr(e,`for`);t!==null&&removeFromElementIndex(e.doc[ln],t,e)}_attributeChangedSteps(e,t,n,r){super._attributeChangedSteps(e,t,n,r);let i=this[z];e===`for`&&r===null&&t!==n&&(i.doc[nn]++,i.flags&1&&(t!==null&&removeFromElementIndex(i.doc[ln],t,i),n!==null&&addToElementIndex(i.doc[ln]??=/* @__PURE__ */ new Map,n,i)))}get control(){let e=labeledControl(this[z]);return e===null?null:e.node}get form(){let e=labeledControl(this[z]);if(e===null||e.tag===Z.meter||e.tag===Z.progress)return null;let t=formOwner(e);return t===null?null:t.node}get _hasActivationBehavior(){return!0}_activationBehavior(e){let t=this[z],n=labeledControl(t);if(n===null)return;let r=e===null?null:e.target?.[z]??null;if(r!==null&&r!==t){for(let e=r;e!==null&&e!==t;e=e.parent)if(e===n||e.type===1&&isInteractiveContent(e))return}isActuallyDisabled(n)||syntheticClick(n.node)}};str(HTMLLabelElement,`htmlFor=for`);var HTMLFieldSetElement=class extends HTMLElement{[Gt];constructor(e,t,n,r){super(e,t,n,r),this[Gt]=null}get type(){return`fieldset`}get form(){let e=formOwner(this[z]);return e===null?null:e.node}get elements(){return this[Gt]??=io._descendants(this[z],!1,isListed)}_barredFromValidation(){return!0}_validityFlags(){return this[kt]?512:0}_validationMessage(e){return this[kt]??``}};installConstraintValidation(HTMLFieldSetElement),bool(HTMLFieldSetElement,`disabled`),str(HTMLFieldSetElement,`name`);var HTMLLegendElement=class extends HTMLElement{get form(){let e=this[z].parent;if(e===null||e.tag!==Z.fieldset)return null;let t=formOwner(e);return t===null?null:t.node}};str(HTMLLegendElement,`align`);var HTMLOutputElement=class extends HTMLElement{[Ft];constructor(e,t,n,r){super(e,t,n,r),this[Ft]=null}get type(){return`output`}get form(){let e=formOwner(this[z]);return e===null?null:e.node}get labels(){return this[In]??=new LabelsNodeList(this[z])}get defaultValue(){return this[Ft]??descendantTextContent(this[z])}set defaultValue(e){this[Ft]===null?this.textContent=String(e):this[Ft]=String(e)}get value(){return descendantTextContent(this[z])}set value(e){this[Ft]=this.defaultValue,this.textContent=String(e)}_reset(){this.textContent=this.defaultValue,this[Ft]=null}_barredFromValidation(){return!0}_validityFlags(){return this[kt]?512:0}_validationMessage(e){return this[kt]??``}};installConstraintValidation(HTMLOutputElement),str(HTMLOutputElement,`name`),tokenList(HTMLOutputElement,`htmlFor`,`for`);function attrFloat(e,t){let n=contentAttr(e[z],t);return n===null?NaN:parseFloatingPoint(n)}function setFloat(e,t,n){let r=Number(n);if(!Number.isFinite(r))throw TypeError(`Failed to set the '${t}' property: The provided double value is non-finite.`);e.setAttribute(t,serializeFloat(r))}var HTMLProgressElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r)}get max(){let e=attrFloat(this,`max`);return Number.isNaN(e)||e<=0?1:e}set max(e){let t=Number(e);if(!Number.isFinite(t))throw TypeError(`Failed to set the 'max' property on 'HTMLProgressElement': The provided double value is non-finite.`);t>0&&this.setAttribute(`max`,serializeFloat(t))}get value(){let e=attrFloat(this,`value`);return Number.isNaN(e)||e<0?0:Math.min(e,this.max)}set value(e){setFloat(this,`value`,e)}get position(){return contentAttr(this[z],`value`)===null?-1:this.value/this.max}get labels(){return this[In]??=new LabelsNodeList(this[z])}},HTMLMeterElement=class extends HTMLElement{constructor(e,t,n,r){super(e,t,n,r)}get min(){let e=attrFloat(this,`min`);return Number.isNaN(e)?0:e}set min(e){setFloat(this,`min`,e)}get max(){let e=this.min,t=attrFloat(this,`max`);return Math.max(Number.isNaN(t)?1:t,e)}set max(e){setFloat(this,`max`,e)}get value(){let e=this.min,t=this.max,n=attrFloat(this,`value`),r=Number.isNaN(n)?0:n;return r<e?e:r>t?t:r}set value(e){setFloat(this,`value`,e)}get low(){let e=this.min,t=this.max,n=attrFloat(this,`low`),r=Number.isNaN(n)?e:n;return r<e?e:r>t?t:r}set low(e){setFloat(this,`low`,e)}get high(){let e=this.low,t=this.max,n=attrFloat(this,`high`),r=Number.isNaN(n)?t:n;return r<e?e:r>t?t:r}set high(e){setFloat(this,`high`,e)}get optimum(){let e=this.min,t=this.max,n=attrFloat(this,`optimum`),r=Number.isNaN(n)?e+(t-e)/2:n;return r<e?e:r>t?t:r}set optimum(e){setFloat(this,`optimum`,e)}get labels(){return this[In]??=new LabelsNodeList(this[z])}};function isOption(e){return e.tag===Z.option}var HTMLDataListElement=class extends HTMLElement{[V];constructor(e,t,n,r){super(e,t,n,r),this[V]=null}get options(){return this[V]??=io._descendants(this[z],!0,isOption)}};const Qf=stubbedMethod(`HTMLFormElement`,`submit`),$f={keywords:[`application/x-www-form-urlencoded`,`multipart/form-data`,`text/plain`],missing:`application/x-www-form-urlencoded`,invalid:`application/x-www-form-urlencoded`},ep={keywords:[`get`,`post`,`dialog`],missing:`get`,invalid:`get`},tp={keywords:[`on`,`off`],missing:`on`,invalid:`on`};var HTMLFormElement=class extends HTMLElement{[Gt];[$t];[Un];[vt];[ar];constructor(e,t,n,r){super(e,t,n,r),this[Gt]=null,this[$t]=!1,this[Un]=!1,this[vt]=!1,this[ar]=null;let i=new Proxy(this,np);return this[z].node=i,i}_namedProperty(e){if(e===``)return;let t=this[z],n=this._controls(),r=namedControl(t,n,e)??(n.hasImage?namedImage(t,e):null);return r===null?this[ar]?.get(e)?.deref()?.node:r instanceof RadioNodeList?r:(rememberName(this,e,r),r.node)}_controls(){let e=this[z],t=e.doc,n=t[ei]+t[tn],r=cachedSnapshot(t,e,n);if(r!==void 0)return r;let i=formControls(e,[],!1);return storeSnapshot(t,e,n,i),i}get elements(){return this[Gt]??=createFormControlsCollection(this[z])}get length(){return this._controls().length}get action(){return reflectActionURL(this[z],`action`)}set action(e){this.setAttribute(`action`,String(e))}get encoding(){return this.enctype}set encoding(e){this.enctype=e}submit(){reportNotImplemented(this[z].doc[Y],Qf),submitForm(this[z],this[z],!0)}requestSubmit(e=null){let t=this[z];if(e!=null){let n=e[z];if(n===void 0||!isSubmitButton(n))throw TypeError(`Failed to execute 'requestSubmit' on 'HTMLFormElement': The specified element is not a submit button.`);if(e.form!==this)throw new DOMException(`Failed to execute 'requestSubmit' on 'HTMLFormElement': The specified element is not owned by this form element.`,`NotFoundError`);t=n}submitForm(this[z],t,!1)}reset(){resetForm(this[z]),flushFaceReactions()}checkValidity(){return formCheckValidity(this[z])}reportValidity(){return formCheckValidity(this[z])}};str(HTMLFormElement,`acceptCharset=accept-charset name rel target`),bool(HTMLFormElement,`noValidate=novalidate`),enumerated(HTMLFormElement,`enctype`,$f),enumerated(HTMLFormElement,`method`,ep),enumerated(HTMLFormElement,`autocomplete`,tp),tokenList(HTMLFormElement,`relList`,`rel`,[`noopener`,`noreferrer`,`opener`]);function indexedOrNamedValue(e,t){let n=arrayIndex(t);return n===-1?e._namedProperty(t):e._controls()[n]?.node}function arrayIndex(e){let t=e.charCodeAt(0);if(t<48||t>57)return-1;let n=Number(e);return Number.isInteger(n)&&String(n)===e?n:-1}const np={get(e,t,n){if(t===z)return e[z];if(typeof t==`symbol`)return e[t];let r=arrayIndex(t);if(r!==-1){let i=e._controls();return r<i.length?i[r].node:Reflect.get(e,t,n)}let i=Reflect.get(e,t,n);if(i!==void 0)return i;let a=e._namedProperty(t);return a===void 0||t in e?void 0:a},has(e,t){return t in e||typeof t==`string`&&indexedOrNamedValue(e,t)!==void 0},getOwnPropertyDescriptor(e,t){if(typeof t==`string`&&!(t in e)){let n=indexedOrNamedValue(e,t);if(n!==void 0)return{value:n,writable:!1,enumerable:arrayIndex(t)!==-1,configurable:!0}}return Reflect.getOwnPropertyDescriptor(e,t)},set(e,t,n,r){if(typeof t==`symbol`)return Reflect.set(e,t,n,r);if(r!==e[z].node)return!(t in e)&&indexedOrNamedValue(e,t)!==void 0?!1:Reflect.set(e,t,n,r);let i=Reflect.getOwnPropertyDescriptor(e,t);return i===void 0?t in e?Reflect.set(e,t,n,r):arrayIndex(t)!==-1||e._namedProperty(t)!==void 0?!1:Reflect.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0}):i.writable===!0?(e[t]=n,!0):i.set===void 0&&i.get===void 0?!1:Reflect.set(e,t,n,r)},defineProperty(e,t,n){return typeof t==`string`&&(arrayIndex(t)!==-1||!(t in e)&&e._namedProperty(t)!==void 0)?!1:Reflect.defineProperty(e,t,n)},deleteProperty(e,t){return typeof t==`string`&&!(t in e)&&indexedOrNamedValue(e,t)!==void 0?!1:Reflect.deleteProperty(e,t)},ownKeys(e){let t=e._controls(),n=e[ar],r=Reflect.ownKeys(e);if(t.length===0&&n===null)return r;let i=[],a=/* @__PURE__ */ new Set;for(let e=0;e<t.length;e++){i.push(String(e));let n=t[e];n.id!==``&&a.add(n.id);let r=contentAttr(n,`name`);r!==null&&r!==``&&a.add(r)}if(n!==null)for(let[e,t]of n)!a.has(e)&&t.deref()!==void 0&&a.add(e);for(let n of a){let r=arrayIndex(n);(r===-1||r>=t.length)&&!(n in e)&&i.push(n)}for(let e of r)i.push(e);return i}},rp=/* @__PURE__ */ new Map;function recordHostOriginal(e,t){rp.has(e)||rp.set(e,t)}const ip=/* @__PURE__ */ new WeakSet;let ap=null;function hostFormData(){let e=rp.get(`FormData`);if(e!==void 0)return e;let t=globalThis.FormData;return t===FormData$1?void 0:t}function nodeFormData(){if(ap!==null)return ap;let e=hostFormData();if(e===void 0)throw TypeError(`FormData is not available in this Node.js runtime.`);return ap=e,Object.setPrototypeOf(FormData$1.prototype,ap.prototype),Object.setPrototypeOf(FormData$1,ap),ap}var FormData$1=class{static{__name(this,`FormData`)}constructor(e,t=null){let n=Reflect.construct(nodeFormData(),[],new.target);if(e===void 0)return n;let r=e?.[z];if(r===void 0||r.tag!==Z.form)throw TypeError(`Failed to construct 'FormData': parameter 1 is not of type 'HTMLFormElement'.`);let i=null;if(t!=null){let e=t[z];if(e===void 0||!isSubmitButton(e))throw TypeError(`Failed to construct 'FormData': The specified element is not a submit button.`);if(formOwner(e)!==r)throw new DOMException(`Failed to construct 'FormData': The specified element is not owned by this form element.`,`NotFoundError`);i=e}if(constructEntryList(r,i,t=>{for(let e=0;e<t.length;e++){let[r,i]=t[e];n.append(r,i)}dispatchTrusted$1(e,new FormDataEvent(`formdata`,{bubbles:!0,cancelable:!1,formData:n}))})===null)throw new DOMException(`Failed to construct 'FormData': The form is already constructing its entry list.`,`InvalidStateError`);return n}};for(let e of[`append`,`delete`,`get`,`getAll`,`has`,`set`,`entries`,`keys`,`values`,`forEach`])Object.defineProperty(FormData$1.prototype,e,{value:{[e](...t){return nodeFormData().prototype[e].apply(this,t)}}[e],writable:!0,configurable:!0});Object.defineProperty(FormData$1.prototype,Symbol.iterator,{value:function entries(){return nodeFormData().prototype.entries.call(this)},writable:!0,configurable:!0}),Object.defineProperty(FormData$1.prototype,Symbol.toStringTag,{value:`FormData`,configurable:!0});const op=/* @__PURE__ */ new Map([[`input`,HTMLInputElement],[`textarea`,HTMLTextAreaElement],[`select`,HTMLSelectElement],[`option`,HTMLOptionElement],[`optgroup`,HTMLOptGroupElement],[`button`,HTMLButtonElement],[`label`,HTMLLabelElement],[`fieldset`,HTMLFieldSetElement],[`legend`,HTMLLegendElement],[`output`,HTMLOutputElement],[`progress`,HTMLProgressElement],[`meter`,HTMLMeterElement],[`datalist`,HTMLDataListElement],[`form`,HTMLFormElement]]),sp=/* @__PURE__ */ new Map([[`a`,HTMLAnchorElement],[`area`,HTMLAreaElement],[`audio`,HTMLAudioElement],[`base`,HTMLBaseElement],[`blockquote`,HTMLQuoteElement],[`q`,HTMLQuoteElement],[`body`,HTMLBodyElement],[`br`,HTMLBRElement],[`canvas`,HTMLCanvasElement],[`caption`,HTMLTableCaptionElement],[`col`,HTMLTableColElement],[`colgroup`,HTMLTableColElement],[`data`,HTMLDataElement],[`del`,HTMLModElement],[`ins`,HTMLModElement],[`details`,HTMLDetailsElement],[`dialog`,HTMLDialogElement],[`div`,HTMLDivElement],[`dl`,HTMLDListElement],[`embed`,HTMLEmbedElement],[`h1`,HTMLHeadingElement],[`h2`,HTMLHeadingElement],[`h3`,HTMLHeadingElement],[`h4`,HTMLHeadingElement],[`h5`,HTMLHeadingElement],[`h6`,HTMLHeadingElement],[`head`,HTMLHeadElement],[`hr`,HTMLHRElement],[`html`,HTMLHtmlElement],[`iframe`,HTMLIFrameElement],[`img`,HTMLImageElement],[`li`,HTMLLIElement],[`link`,HTMLLinkElement],[`map`,HTMLMapElement],[`menu`,HTMLMenuElement],[`meta`,HTMLMetaElement],[`object`,HTMLObjectElement],[`ol`,HTMLOListElement],[`p`,HTMLParagraphElement],[`param`,HTMLParamElement],[`picture`,HTMLPictureElement],[`pre`,HTMLPreElement],[`listing`,HTMLPreElement],[`xmp`,HTMLPreElement],[`script`,HTMLScriptElement],[`slot`,HTMLSlotElement],[`source`,HTMLSourceElement],[`span`,HTMLSpanElement],[`style`,HTMLStyleElement],[`table`,HTMLTableElement],[`tbody`,HTMLTableSectionElement],[`thead`,HTMLTableSectionElement],[`tfoot`,HTMLTableSectionElement],[`td`,HTMLTableCellElement],[`th`,HTMLTableCellElement],[`template`,HTMLTemplateElement],[`time`,HTMLTimeElement],[`title`,HTMLTitleElement],[`tr`,HTMLTableRowElement],[`track`,HTMLTrackElement],[`ul`,HTMLUListElement],[`video`,HTMLVideoElement],[`dir`,HTMLDirectoryElement],[`font`,HTMLFontElement],[`frame`,HTMLFrameElement],[`frameset`,HTMLFrameSetElement],[`marquee`,HTMLMarqueeElement],[`summary`,xf]]);for(let e of/* @__PURE__ */ `abbr.address.article.aside.b.bdi.bdo.cite.code.dd.dfn.dt.em.figcaption.figure.footer.header.hgroup.i.kbd.main.mark.nav.noscript.rp.rt.ruby.s.samp.search.section.small.strong.sub.sup.u.var.wbr.acronym.basefont.big.center.nobr.noembed.noframes.plaintext.rb.rtc.strike.tt.selectedcontent`.split(`.`))sp.set(e,HTMLElement);for(let[e,t]of op)sp.set(e,t);installPopoverInvoker(sp.get(`button`)),installPopoverInvoker(sp.get(`input`)),installCommandInvoker(sp.get(`button`));function elementClassFor(e,t){if(t===`http://www.w3.org/1999/xhtml`){let t=sp.get(e);return t===void 0?e.includes(`-`)&&isValidCustomElementName(e)?HTMLElement:HTMLUnknownElement:t}return t===`http://www.w3.org/2000/svg`?Rf.get(e)??SVGElement:t===`http://www.w3.org/1998/Math/MathML`?MathMLElement:Rs}setElementClassLookup(elementClassFor);let cp=null;function isBuiltinInterface(e){if(cp===null){cp=/* @__PURE__ */ new Set([HTMLElement,HTMLUnknownElement,HTMLMediaElement]);for(let e of sp.values())cp.add(e)}return cp.has(e)}function localNamesForInterface(e){let t=[];for(let[n,r]of sp)r===e&&t.push(n);return t}Ou.createCustomElementRegistry=e=>customElementRegistryFor(e);function setClassString(e){let t=e.prototype;Object.hasOwn(t,Symbol.toStringTag)||Object.defineProperty(t,Symbol.toStringTag,{value:e.name,configurable:!0})}for(let e of[HTMLElement,HTMLUnknownElement,HTMLMediaElement,SVGElement,MathMLElement,...sp.values(),...Rf.values()])(e.name!==`HTMLElement`||e===HTMLElement)&&setClassString(e);for(let e of[SVGGraphicsElement,SVGGeometryElement,SVGTextContentElement,SVGTextPositioningElement,SVGGradientElement])setClassString(e);const lp=[`createTask`,`timeStamp`];function inspectorActive(){if(process.execArgv.some(e=>e.startsWith(`--inspect`))||process.env.NODE_OPTIONS?.includes(`--inspect`))return!0;let e=process.moduleLoadList;return e!==void 0&&e.includes(`NativeModule inspector`)&&process.getBuiltinModule(`node:inspector`).url()!==void 0}function hideDevtoolsConsole(e){if(e===void 0)return null;let t=null;for(let n of lp){let r=Object.getOwnPropertyDescriptor(e,n);if(r!==void 0&&r.configurable){if(t===null&&inspectorActive())return null;(t??=[]).push([n,r]),delete e[n]}}if(t===null)return null;let n=t;return()=>{for(let[t,r]of n)Object.hasOwn(e,t)||Object.defineProperty(e,t,r)}}const up=/* @__PURE__ */ new WeakMap;function keyWarningGetter(){return up.get(this)?.call(this)}keyWarningGetter.isReactWarning=!0;const dp={get:keyWarningGetter,configurable:!0};function keyDescriptor(e,t){let n=t.get;return n===void 0||n.isReactWarning!==!0||n===keyWarningGetter||t.set!==void 0||t.configurable!==!0||t.enumerable!==void 0?t:(up.set(e,n),dp)}const fp={get(){return this[N].tracker.get.call(this)},set(e){this[N].tracker.set.call(this,e)},configurable:!0};function trackerDescriptor(e,t){let{get:n,set:r}=t;if(typeof n!=`function`||typeof r!=`function`)return t;let i=e[N];if(i===void 0)return t;if(n===fp.get||r===fp.set){let e=i.tracker;return{...t,get:n===fp.get?e.get:n,set:r===fp.set?e.set:r}}return i.tracker!==null||t.configurable!==!0||t.enumerable!==void 0?t:(i.tracker=t,fp)}function sharedAccessor(e,t,n){return t!==`key`&&t!==`value`&&t!==`checked`||typeof n!=`object`||!n?n:t===`key`?keyDescriptor(e,n):trackerDescriptor(e,n)}const pp=/* @__PURE__ */ new WeakMap;function shareAccessors(e){let t=pp.get(e);if(t===void 0){let n=Object.getOwnPropertyDescriptor(e,`defineProperty`),r=e.defineProperty,i={defineProperty(e,t,n){return r(e,t,sharedAccessor(e,t,n))}}.defineProperty;Object.defineProperty(e,"defineProperty",{...n,value:i}),pp.set(e,t={count:0,original:n,wrapper:i})}t.count++;let n=!1;return()=>{n||(n=!0,--t.count===0&&(pp.delete(e),e.defineProperty===t.wrapper&&Object.defineProperty(e,"defineProperty",t.original)))}}function unsharedDefineProperty(e){let t=pp.get(e);return t!==void 0&&e.defineProperty===t.wrapper?t.original.value:e.defineProperty}const mp=[`window`,`self`,`frames`,`parent`,`top`],hp=/* @__PURE__ */ `addEventListener.removeEventListener.dispatchEvent.getComputedStyle.matchMedia.requestAnimationFrame.cancelAnimationFrame.requestIdleCallback.cancelIdleCallback.getSelection.scroll.scrollTo.scrollBy.resizeTo.resizeBy.moveTo.moveBy.alert.confirm.prompt.print.open.close.stop.focus.blur.postMessage.reportError.captureEvents.releaseEvents`.split(`.`),gp=new Set(Jd);let _p=null;function windowAttributes(){if(_p!==null)return _p;let e=windowInterfaces(),t=/* @__PURE__ */ new Set([...mp,...hp,`document`,`constructor`]),n=[];for(let r=Window.prototype;r!==null&&r!==Object.prototype;r=Object.getPrototypeOf(r))for(let i of Object.getOwnPropertyNames(r))t.has(i)||gp.has(i)||i in e||i.startsWith(`_`)||Object.getOwnPropertyDescriptor(r,i).get!==void 0&&(t.add(i),n.push(i));return n.push(`name`,`status`,`opener`),_p=n}function hasSetter(e,t){for(let n=e;n!==null;n=Object.getPrototypeOf(n)){let e=Object.getOwnPropertyDescriptor(n,t);if(e!==void 0)return e.set!==void 0||e.writable===!0}return!1}function installGlobals(e,t=globalThis){let n=/* @__PURE__ */ new Map,r=currentWindowOrNull(),define=(e,r)=>{let i=Object.getOwnPropertyDescriptor(t,e);(i===void 0||i.configurable)&&(n.has(e)||n.set(e,i),i!==void 0&&`value`in i&&t===globalThis&&recordHostOriginal(e,i.value),Object.defineProperty(t,e,r))};for(let e of mp)define(e,{value:t,writable:!0,enumerable:!0,configurable:!0});define(`document`,{value:e.document,writable:!0,enumerable:!0,configurable:!0});let i=e[V].compat,a=hiddenGlobals(i),o=windowInterfaces();for(let e in o)a.has(e)||define(e,{value:o[e],writable:!0,enumerable:!1,configurable:!0});let s=optInInterfaces();for(let e in s)a.has(e)||define(e,{value:s[e],writable:!0,enumerable:!1,configurable:!0});let c=installCompatMembers(i,o),l=e;for(let t of hp){if(a.has(t))continue;let n=l[t].bind(e);ip.add(n),define(t,{value:n,writable:!0,enumerable:!0,configurable:!0})}let u=windowAttributes(),d=Object.hasOwn(e,`visualViewport`)?[...u,`visualViewport`]:u;for(let n of d)(!a.has(n)||Object.hasOwn(e,n))&&define(n,{get(){return e[n]},set:hasSetter(e,n)?t=>{e[n]=t}:e=>{Object.defineProperty(t,n,{value:e,writable:!0,enumerable:!0,configurable:!0})},enumerable:!0,configurable:!0});let m=e.document;Object.defineProperty(m,"defaultView",{get:()=>t,enumerable:!0,configurable:!0});let h=t.Object,_=h===void 0?null:shareAccessors(h),v=hideDevtoolsConsole(t.console);setCurrentWindow(e);let y=e[R];e[R]=t;let b=e[_n];e[_n]=t;let x=Wd.get(t);Wd.set(t,e);let S=!0;return function uninstall(){if(S){S=!1,delete m.defaultView;for(let[e,r]of n)r===void 0?delete t[e]:Object.defineProperty(t,e,r);n.clear(),c(),_?.(),v?.(),e[R]=y,e[_n]=b,Wd.get(t)===e&&(x===void 0?Wd.delete(t):Wd.set(t,x)),currentWindowOrNull()===e&&setCurrentWindow(r)}}}var XhrState=class{window;state;send;sync;method;url;headers;timeout;withCredentials;upload;uploadComplete;uploadListener;uploadTotal;responseType;overrideMime;error;status;statusText;responseURL;responseHeaders;chunks;received;bytesCache;textCache;object;generation;request;timer;startedAt;closeTask;constructor(e,t){this.window=e,this.state=0,this.send=!1,this.sync=!1,this.method=`GET`,this.url=null,this.headers=/* @__PURE__ */ new Map,this.timeout=0,this.withCredentials=!1,this.upload=t,this.uploadComplete=!1,this.uploadListener=!1,this.uploadTotal=0,this.responseType=``,this.overrideMime=null,this.error=!0,this.status=0,this.statusText=``,this.responseURL=``,this.responseHeaders=[],this.chunks=[],this.received=0,this.bytesCache=null,this.textCache=null,this.object=void 0,this.generation=0,this.request=null,this.timer=null,this.startedAt=0,this.closeTask=null}},vp=class XMLHttpRequestEventTarget extends EventTarget{constructor(){if(new.target===XMLHttpRequestEventTarget)throw TypeError(`Illegal constructor`);super()}};const yp=Symbol(`upload`);var XMLHttpRequestUpload=class extends vp{constructor(e){if(e!==yp)throw TypeError(`Illegal constructor`);super()}};function defineHandlers(e,t){for(let n of t)Object.defineProperty(e,`on${n}`,{get(){return getEventHandler(this,n)},set(e){setEventHandler(this,n,e)},enumerable:!0,configurable:!0})}defineHandlers(vp.prototype,[`loadstart`,`progress`,`abort`,`error`,`load`,`timeout`,`loadend`]);function fireProgress(e,t,n,r,i=r>0){fireAnEvent(t,e,eventInterface(`ProgressEvent`),{loaded:n,total:r,lengthComputable:i})}function fireReadyStateChange(e){fireAnEvent(`readystatechange`,e,Event)}const state=e=>{let t=e?.[_i];if(t===void 0)throw TypeError(`Illegal invocation`);return t},invalidState=(e,t)=>new DOMException(`Failed to ${e} 'XMLHttpRequest': ${t}`,`InvalidStateError`);var XMLHttpRequest=class extends vp{static UNSENT=0;static OPENED=1;static HEADERS_RECEIVED=2;static LOADING=3;static DONE=4;[_i];constructor(){super(),this[_i]=new XhrState(currentWindowOrNull(),new XMLHttpRequestUpload(yp))}get readyState(){return state(this).state}open(e,t,n,r,i){let a=state(this);if(arguments.length<2)throw TypeError(`Failed to execute 'open' on 'XMLHttpRequest': 2 arguments required, but only ${arguments.length} present.`);if(a.window!==null&&a.window[pt])throw invalidState(`execute 'open' on`,`The document is not fully active.`);if(e=String(e),!bp.test(e))throw new DOMException(`Failed to execute 'open' on 'XMLHttpRequest': '${e}' is not a valid HTTP method.`,`SyntaxError`);let o=e.toUpperCase();if(o===`CONNECT`||o===`TRACE`||o===`TRACK`)throw new DOMException(`Failed to execute 'open' on 'XMLHttpRequest': '${e}' HTTP method is unsupported.`,`SecurityError`);xp.has(o)&&(e=o);let s=URL.parse(String(t),a.window?.document.baseURI??void 0);if(s===null)throw new DOMException(`Failed to execute 'open' on 'XMLHttpRequest': Invalid URL`,`SyntaxError`);let c=arguments.length<3||!!n;if(s.host!==``&&(r!=null&&(s.username=String(r)),i!=null&&(s.password=String(i))),!c&&(a.timeout!==0||a.responseType!==``))throw new DOMException(`Failed to execute 'open' on 'XMLHttpRequest': Synchronous requests from a document must not set a timeout or responseType.`,`InvalidAccessError`);terminate(a),a.send=!1,a.uploadListener=!1,a.method=e,a.url=s,a.sync=!c,a.headers.clear(),setNetworkError(a),a.state!==1&&(a.state=1,fireReadyStateChange(this))}setRequestHeader(e,t){let n=state(this);if(arguments.length<2)throw TypeError(`Failed to execute 'setRequestHeader' on 'XMLHttpRequest': 2 arguments required, but only ${arguments.length} present.`);if(n.state!==1||n.send)throw invalidState(`execute 'setRequestHeader' on`,`The object's state must be OPENED.`);if(e=String(e),t=String(t).replace(/^[\t\n\r ]+|[\t\n\r ]+$/g,``),!bp.test(e))throw new DOMException(`Failed to execute 'setRequestHeader' on 'XMLHttpRequest': '${e}' is not a valid HTTP header field name.`,`SyntaxError`);if(/[\0\r\n]/.test(t))throw new DOMException(`Failed to execute 'setRequestHeader' on 'XMLHttpRequest': '${t}' is not a valid HTTP header field value.`,`SyntaxError`);let r=e.toLowerCase();if(Cp.has(r)||r.startsWith(`proxy-`)||r.startsWith(`sec-`))return;let i=n.headers.get(r);n.headers.set(r,i===void 0?[e,t]:[i[0],`${i[1]}, ${t}`])}get timeout(){return state(this).timeout}set timeout(e){let t=state(this);if(t.sync&&t.state!==0)throw new DOMException(`Failed to set the 'timeout' property on 'XMLHttpRequest': Timeouts cannot be set for synchronous requests made from a document.`,`InvalidAccessError`);t.timeout=Number(e)>>>0,t.send&&t.request!==null&&scheduleTimeout(this,t)}get withCredentials(){return state(this).withCredentials}set withCredentials(e){let t=state(this);if(t.state!==0&&t.state!==1||t.send)throw invalidState(`set the 'withCredentials' property on`,`The value may only be set if the object's state is UNSENT or OPENED.`);t.withCredentials=!!e}get upload(){return state(this).upload}send(e){let t=state(this);if(t.state!==1||t.send)throw invalidState(`execute 'send' on`,`The object's state must be OPENED.`);if(t.window!==null&&t.window[pt])throw invalidState(`execute 'send' on`,`The document is not fully active.`);if(t.sync)throw new DOMException(`Failed to execute 'send' on 'XMLHttpRequest': Synchronous XMLHttpRequest is not supported by @ctrl/dom (docs/deviations.md).`,`NotSupportedError`);let n=null;if(e!=null&&t.method!==`GET`&&t.method!==`HEAD`){n=extractBody(e);let r=t.headers.get(`content-type`);r===void 0?n.type!==null&&t.headers.set(`content-type`,[`Content-Type`,n.type]):(typeof e==`string`||e instanceof Q)&&(r[1]=r[1].replace(/;\s*charset=("[^"]*"|[^;]*)/i,e=>/utf-8/i.test(e)?e:`;charset=UTF-8`))}t.uploadListener=hasAnyListener(t.upload),t.uploadTotal=n?.length??0,t.uploadComplete=t.uploadTotal===0,t.send=!0,fireProgress(this,`loadstart`,0,0),!t.uploadComplete&&t.uploadListener&&fireProgress(t.upload,`loadstart`,0,t.uploadTotal),t.state===1&&t.send&&start(this,t,n)}abort(){let e=state(this);terminate(e),(e.state===1&&e.send||e.state===2||e.state===3)&&requestErrorSteps(this,e,`abort`),e.state===4&&(e.state=0,setNetworkError(e))}get responseURL(){return state(this).responseURL}get status(){return state(this).status}get statusText(){return state(this).statusText}getResponseHeader(e){let t=state(this),n=String(e).toLowerCase();if(n===`set-cookie`||n===`set-cookie2`)return null;let r=null;for(let[e,i]of t.responseHeaders)e===n&&(r=r===null?i:`${r}, ${i}`);return r}getAllResponseHeaders(){let e=state(this),t=/* @__PURE__ */ new Map;for(let[n,r]of e.responseHeaders){if(n===`set-cookie`||n===`set-cookie2`)continue;let e=t.get(n);t.set(n,e===void 0?r:`${e}, ${r}`)}let n=[...t.keys()].sort((e,t)=>{let n=e.toUpperCase(),r=t.toUpperCase();return n<r?-1:+(n>r)}),r=``;for(let e of n)r+=`${e}: ${t.get(e)}\r\n`;return r}overrideMimeType(e){let t=state(this);if(t.state===3||t.state===4)throw invalidState(`execute 'overrideMimeType' on`,`MimeType cannot be overridden when the state is LOADING or DONE.`);t.overrideMime=parseMime(String(e))===null?`application/octet-stream`:String(e)}get responseType(){return state(this).responseType}set responseType(e){let t=state(this);if(e=String(e),Sp.has(e)){if(t.state===3||t.state===4)throw invalidState(`set the 'responseType' property on`,`The response type cannot be set if the object's state is LOADING or DONE.`);if(t.sync&&t.state!==0)throw new DOMException(`Failed to set the 'responseType' property on 'XMLHttpRequest': The response type cannot be changed for synchronous requests made from a document.`,`InvalidAccessError`);t.responseType=e}}get response(){let e=state(this),t=e.responseType;if(t===``||t===`text`)return e.state===3||e.state===4?text(e):``;if(e.state!==4)return null;if(e.object!==void 0)return e.object;let n=null;return e.error||(t===`arraybuffer`?n=new Uint8Array(bytes(e)).buffer:t===`blob`?n=new Blob([bytes(e)],{type:finalMime(e)?.serialized??``}):t===`document`?n=documentResponse(e):t===`json`&&(n=jsonResponse(e))),e.object=n,n}get responseText(){let e=state(this);if(e.responseType!==``&&e.responseType!==`text`)throw invalidState(`read the 'responseText' property from`,`The value is only accessible if the object's 'responseType' is '' or 'text' (was '${e.responseType}').`);return e.state===3||e.state===4?text(e):``}get responseXML(){let e=state(this);if(e.responseType!==``&&e.responseType!==`document`)throw invalidState(`read the 'responseXML' property from`,`The value is only accessible if the object's 'responseType' is '' or 'document' (was '${e.responseType}').`);return e.state!==4||e.error?null:(e.object===void 0&&(e.object=documentResponse(e)),e.object)}};defineHandlers(XMLHttpRequest.prototype,[`readystatechange`]);for(let[e,t]of[[`UNSENT`,0],[`OPENED`,1],[`HEADERS_RECEIVED`,2],[`LOADING`,3],[`DONE`,4]])Object.defineProperty(XMLHttpRequest.prototype,e,{value:t,enumerable:!0});const bp=/^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/,xp=/* @__PURE__ */ new Set([`DELETE`,`GET`,`HEAD`,`OPTIONS`,`POST`,`PUT`]),Sp=/* @__PURE__ */ new Set([``,`arraybuffer`,`blob`,`document`,`json`,`text`]),Cp=/* @__PURE__ */ new Set([`accept-charset`,`accept-encoding`,`access-control-request-headers`,`access-control-request-method`,`connection`,`content-length`,`cookie`,`cookie2`,`date`,`dnt`,`expect`,`host`,`keep-alive`,`origin`,`referer`,`set-cookie`,`te`,`trailer`,`transfer-encoding`,`upgrade`,`via`]),wp=[`content-encoding`,`content-language`,`content-location`,`content-type`];function terminate(e){e.generation++,e.request!==null&&(e.request.destroy(),e.request=null),e.timer!==null&&(e.window?._cancelTask(e.timer),e.timer=null),e.closeTask!==null&&(e.window?._releaseCloseable(e.closeTask),e.closeTask=null)}function setNetworkError(e){e.error=!0,e.status=0,e.statusText=``,e.responseURL=``,e.responseHeaders=[],e.chunks=[],e.received=0,e.bytesCache=null,e.textCache=null,e.object=void 0}function requestErrorSteps(e,t,n){t.state=4,t.send=!1,setNetworkError(t),fireReadyStateChange(e),t.uploadComplete||(t.uploadComplete=!0,t.uploadListener&&(fireProgress(t.upload,n,0,0),fireProgress(t.upload,`loadend`,0,0))),fireProgress(e,n,0,0),fireProgress(e,`loadend`,0,0)}function scheduleTimeout(e,t){if(t.timer!==null&&(t.window?._cancelTask(t.timer),t.timer=null),t.timeout===0||t.window===null)return;let n=t.generation,r=Math.max(0,t.timeout-(Date.now()-t.startedAt));t.timer=t.window._task(()=>{t.timer=null,t.generation===n&&(terminate(t),requestErrorSteps(e,t,`timeout`))},r)}function start(e,t,n){let r=t.generation;t.startedAt=Date.now(),t.closeTask=t.window?._closeable(()=>terminate(t))??null,scheduleTimeout(e,t);let go=n=>{t.generation===r&&dispatchRequest(e,t,r,t.url,t.method,n,new Map(t.headers),0)};n===null?go(null):n.bytes instanceof Uint8Array?go(n.bytes):n.bytes.then(go,()=>t.generation===r&&networkError(e,t))}function networkError(e,t){terminate(t),requestErrorSteps(e,t,`error`)}function sameOrigin(e,t){return e.origin!==`null`&&e.origin===URL.parse(t)?.origin}function dispatchRequest(e,t,n,r,i,a,o,s){if(r.protocol===`data:`)return void queueMicrotask(()=>t.generation===n&&respondFromData(e,t,n,r));if(r.protocol===`blob:`)return void respondFromBlob(e,t,n,r);if(r.protocol!==`http:`&&r.protocol!==`https:`)return void queueMicrotask(()=>t.generation===n&&networkError(e,t));let c=t.window,l=c?.document.URL??`about:blank`,u=sameOrigin(r,l)||t.withCredentials,d={};for(let[e,t]of o.values())d[e]=t;let has=e=>o.has(e);has(`user-agent`)||(d[`User-Agent`]=c?.navigator.userAgent??``),has(`accept`)||(d.Accept=`*/*`),has(`accept-language`)||(d[`Accept-Language`]=`en`),d[`Accept-Encoding`]=`gzip, deflate`;let m=URL.parse(l);if(m!==null&&(m.protocol===`http:`||m.protocol===`https:`)&&(m.hash=``,m.username=``,m.password=``,d.Referer=m.origin===r.origin?m.href:`${m.origin}/`,m.origin!==r.origin&&(d.Origin=m.origin)),u&&c!==null){let e=c._cookieStore.get(r);e!==``&&(d.Cookie=e)}let h=new URL(r);(h.username!==``||h.password!==``)&&(has(`authorization`)||(d.Authorization=`Basic ${Buffer.from(`${decodeURIComponent(h.username)}:${decodeURIComponent(h.password)}`).toString(`base64`)}`),h.username=``,h.password=``),h.hash=``,a!==null&&(d[`Content-Length`]=String(a.byteLength));let _=process.getBuiltinModule(h.protocol===`https:`?`node:https`:`node:http`),v;try{v=_.request(h,{method:i,headers:d})}catch{queueMicrotask(()=>t.generation===n&&networkError(e,t));return}t.request=v,v.on(`error`,()=>{t.generation===n&&networkError(e,t)}),v.on(`response`,l=>{if(t.generation!==n){l.resume();return}let d=l.statusCode??0,m=l.headers[`set-cookie`];if(u&&c!==null&&m!==void 0)for(let e of m)c._cookieStore.set(e,r);let h=l.headers.location;if((d===301||d===302||d===303||d===307||d===308)&&h!==void 0){l.resume();let c=URL.parse(h,r);if(c===null||s>=20)return networkError(e,t);let u=i,m=a,_=new Map(o);if((d===301||d===302)&&i===`POST`||d===303&&i!==`GET`&&i!==`HEAD`){u=`GET`,m=null;for(let e of wp)_.delete(e)}c.origin!==r.origin&&_.delete(`authorization`),dispatchRequest(e,t,n,c,u,m,_,s+1);return}let _=[];for(let e=0;e<l.rawHeaders.length;e+=2)_.push([l.rawHeaders[e].toLowerCase(),l.rawHeaders[e+1]]);let v=String(l.headers[`content-encoding`]??``).trim().toLowerCase(),y=process.getBuiltinModule(`node:zlib`),b=v===`gzip`||v===`x-gzip`?y.createGunzip():v===`deflate`?y.createInflate():v===`br`?y.createBrotliDecompress():null,x=Number(l.headers[`content-length`]??0)||0;processResponse(e,t,n,r,d,l.statusMessage??``,_,b===null?l:l.pipe(b),b===null?x:0)}),a===null?v.end():v.end(a)}function processResponse(e,t,n,r,i,a,o,s,c){if(!t.uploadComplete&&(t.uploadComplete=!0,t.uploadListener&&(fireProgress(t.upload,`progress`,t.uploadTotal,t.uploadTotal),fireProgress(t.upload,`load`,t.uploadTotal,t.uploadTotal),fireProgress(t.upload,`loadend`,t.uploadTotal,t.uploadTotal),t.generation!==n)))return;let l=new URL(r);if(l.hash=``,t.error=!1,t.status=i,t.statusText=a,t.responseURL=l.href,t.responseHeaders=o,t.state=2,fireReadyStateChange(e),t.generation!==n)return;let u=-1,end=()=>{t.generation===n&&(terminate(t),u!==t.received&&fireProgress(e,`progress`,t.received,c,c>0),t.send=!1,t.state=4,fireReadyStateChange(e),fireProgress(e,`load`,t.received,c,c>0),fireProgress(e,`loadend`,t.received,c,c>0))};if(s===null)return end();s.on(`data`,r=>{t.generation===n&&(t.chunks.push(r),t.received+=r.length,t.bytesCache=null,t.textCache=null,t.state===2&&(t.state=3),fireReadyStateChange(e),t.generation===n&&(u=t.received,fireProgress(e,`progress`,t.received,c,c>0)))}),s.on(`end`,end),s.on(`error`,()=>{t.generation===n&&networkError(e,t)})}function respondFromData(e,t,n,r){let i=r.href.slice(5),a=i.indexOf(`,`);if(a===-1)return networkError(e,t);let o=i.slice(0,a).trim(),s,c=decodeURIComponentBytes(i.slice(a+1).replace(/#.*$/,``)),l=/;\s*base64\s*$/i;if(l.test(o)){o=o.replace(l,``);let n=c.toString(`latin1`).replace(/[\t\n\f\r ]/g,``);if(!/^[A-Za-z0-9+/]*={0,2}$/.test(n)||n.replace(/=+$/,``).length%4==1)return networkError(e,t);s=Buffer.from(n,`base64`)}else s=c;o.startsWith(`;`)&&(o=`text/plain${o}`),processResponse(e,t,n,r,200,`OK`,[[`content-type`,parseMime(o)?.serialized??`text/plain;charset=US-ASCII`]],bufferStream(s),s.length)}function respondFromBlob(e,t,n,r){let i=process.getBuiltinModule(`node:buffer`).resolveObjectURL(r.href);if(i===void 0||t.method!==`GET`)return void queueMicrotask(()=>t.generation===n&&networkError(e,t));i.arrayBuffer().then(a=>{if(t.generation!==n)return;let o=[[`content-length`,String(i.size)]];i.type!==``&&o.push([`content-type`,i.type]),processResponse(e,t,n,r,200,`OK`,o,bufferStream(Buffer.from(a)),i.size)},()=>t.generation===n&&networkError(e,t))}function bufferStream(e){if(e.length===0)return null;let t={},n={on(e,r){return t[e]=r,n}};return queueMicrotask(()=>{t.data?.(e),t.end?.()}),n}function decodeURIComponentBytes(e){let t=[];for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);if(r===37&&/^[0-9A-Fa-f]{2}$/.test(e.slice(n+1,n+3)))t.push(Number.parseInt(e.slice(n+1,n+3),16)),n+=2;else if(r<128)t.push(r);else for(let r of Buffer.from(e[n]))t.push(r)}return Buffer.from(t)}const tag=e=>Object.prototype.toString.call(e);function extractBody(e){if(e instanceof Q){let t=e[z],n=e[Nn],r=Buffer.from(n?serializeChildren(t):serializeXML(t,!1));return{bytes:r,type:n?`text/html;charset=UTF-8`:`application/xml;charset=UTF-8`,length:r.length}}if(e instanceof Blob)return{bytes:e.arrayBuffer().then(e=>new Uint8Array(e)),type:e.type===``?null:e.type,length:e.size};if(ArrayBuffer.isView(e)){let t=new Uint8Array(e.buffer,e.byteOffset,e.byteLength).slice();return{bytes:t,type:null,length:t.length}}if(tag(e)===`[object ArrayBuffer]`||tag(e)===`[object SharedArrayBuffer]`){let t=new Uint8Array(e.slice(0));return{bytes:t,type:null,length:t.length}}if(tag(e)===`[object FormData]`)return multipart(e);if(tag(e)===`[object URLSearchParams]`){let t=Buffer.from(String(e));return{bytes:t,type:`application/x-www-form-urlencoded;charset=UTF-8`,length:t.length}}let t=Buffer.from(String(e).toWellFormed());return{bytes:t,type:`text/plain;charset=UTF-8`,length:t.length}}function multipart(e){let t=`----ctrl-dom-${crypto.randomUUID().replaceAll(`-`,``)}`,escape=e=>e.replaceAll(`
47
- `,`%0A`).replaceAll(`\r`,`%0D`).replaceAll(`"`,`%22`),n=[],r=0,i=!1;for(let[a,o]of e){let e=escape(a.toWellFormed().replace(/\r(?!\n)|(?<!\r)\n/g,`\r
48
- `));if(typeof o==`string`){let i=o.toWellFormed().replace(/\r(?!\n)|(?<!\r)\n/g,`\r
49
- `),a=Buffer.from(`--${t}\r\nContent-Disposition: form-data; name="${e}"\r\n\r\n${i}\r\n`);n.push(a),r+=a.length}else{let a=o,s=Buffer.from(`--${t}\r\nContent-Disposition: form-data; name="${e}"; filename="${escape(a.name??`blob`)}"\r\nContent-Type: ${a.type||`application/octet-stream`}\r\n\r\n`);n.push(s,a.arrayBuffer().then(e=>new Uint8Array(e)),Buffer.from(`\r
50
- `)),r+=s.length+a.size+2,i=!0}}let a=Buffer.from(`--${t}--\r\n`);n.push(a),r+=a.length;let o=`multipart/form-data; boundary=${t}`;return i?{bytes:Promise.all(n).then(e=>Buffer.concat(e)),type:o,length:r}:{bytes:Buffer.concat(n),type:o,length:r}}function parseMime(e){let t=e.indexOf(`;`),n=(t===-1?e:e.slice(0,t)).trim().toLowerCase(),r=n.indexOf(`/`);if(r<=0||r===n.length-1||!bp.test(n.slice(0,r))||!bp.test(n.slice(r+1)))return null;let i=null;if(t!==-1){let n=/(?:^|;)\s*charset\s*=\s*("([^"]*)"|[^;]*)/i.exec(e.slice(t));n!==null&&(i=(n[2]??n[1]).trim()||null)}return{essence:n,charset:i,serialized:e.trim()}}function finalMime(e){if(e.overrideMime!==null)return parseMime(e.overrideMime);let t=null;for(let[n,r]of e.responseHeaders)n===`content-type`&&(t=r);return(t===null?null:parseMime(t))??parseMime(`text/xml`)}function bytes(e){return e.bytesCache??=e.chunks.length===1?e.chunks[0]:Buffer.concat(e.chunks)}function decode(e,t){e[0]===239&&e[1]===187&&e[2]===191?t=`utf-8`:e[0]===254&&e[1]===255?t=`utf-16be`:e[0]===255&&e[1]===254&&(t=`utf-16le`);try{return new TextDecoder(t??`utf-8`).decode(e)}catch{return new TextDecoder(`utf-8`).decode(e)}}function text(e){if(e.error)return``;if(e.textCache!==null)return e.textCache;let t=decode(bytes(e),finalMime(e)?.charset??null);return e.state===4&&(e.textCache=t),t}function jsonResponse(e){let t=bytes(e);if(t.length===0)return null;try{return JSON.parse(decode(t,`utf-8`))}catch{return null}}const isXMLMime=e=>e===`text/xml`||e===`application/xml`||e.endsWith(`+xml`);function documentResponse(e){if(e.error)return null;let t=finalMime(e);if(t===null)return null;let n=t.essence===`text/html`;if(!n&&!isXMLMime(t.essence)||n&&e.responseType===``)return null;let r=decode(bytes(e),t.charset);if(n){let t=Q._createHTML(null,e.responseURL);return parseDocument(r,t),t}let i=new Q;i[yt]=t.essence,i[q]=e.responseURL,parseXML(r,i,t.essence);let a=i.documentElement;return a!==null&&a.localName===`parsererror`&&a.namespaceURI===`http://www.mozilla.org/newlayout/xml/parsererror.xml`?null:i}function finishRead(e){let t=e[gn];t.reader=null,t.source=null,e[gn]=null,e[hr]=2}var FileReader=class extends EventTarget{static EMPTY=0;static LOADING=1;static DONE=2;[hr];[br];[qt];[gn];constructor(){super(),this[hr]=0,this[br]=null,this[qt]=null,this[gn]=null}get readyState(){return this[hr]}get result(){return this[br]}get error(){return this[qt]}readAsArrayBuffer(e){this._read(e,`ArrayBuffer`)}readAsBinaryString(e){this._read(e,`BinaryString`)}readAsText(e,t){this._read(e,`Text`,t)}readAsDataURL(e){this._read(e,`DataURL`)}abort(){this[hr]===0||this[hr]===2?this[br]=null:(finishRead(this),this[br]=null,this._fire(`abort`),this[hr]!==1&&this._fire(`loadend`))}_read(e,t,n){if(!(e instanceof Blob))throw TypeError(`Failed to execute 'readAs${t}' on 'FileReader': parameter 1 is not of type 'Blob'.`);if(this[hr]===1)throw new DOMException(`Failed to execute 'readAs`+t+`' on 'FileReader': The object is already busy reading Blobs.`,`InvalidStateError`);this[hr]=1,this[br]=null,this[qt]=null;let r={reader:this,source:t===`DataURL`?e:null};this[gn]=r,queueMicrotask(()=>r.reader?._fire(`loadstart`)),e.arrayBuffer().then(e=>{let i=r.reader;if(i===null)return;let a=e.byteLength;if(i._fire(`progress`,a,a),r.reader===null)return;let o=r.source;finishRead(i),i[br]=packageData(e,t,o?.type??``,n),i._fire(`load`,a,a),i[hr]!==1&&i._fire(`loadend`,a,a)},e=>{let t=r.reader;t!==null&&(finishRead(t),t[qt]=e instanceof DOMException?e:new DOMException(String(e),`NotReadableError`),t._fire(`error`),t[hr]!==1&&t._fire(`loadend`))})}_fire(e,t=0,n=0){let r=eventInterface(`ProgressEvent`);this.dispatchEvent(new r(e,{lengthComputable:n>0,loaded:t,total:n}))}};for(let e of[`loadstart`,`progress`,`load`,`abort`,`error`,`loadend`])Object.defineProperty(FileReader.prototype,`on${e}`,{get(){return getEventHandler(this,e)},set(t){setEventHandler(this,e,t)},enumerable:!0,configurable:!0});for(let[e,t]of[[`EMPTY`,0],[`LOADING`,1],[`DONE`,2]])Object.defineProperty(FileReader.prototype,e,{value:t,enumerable:!0});function packageData(e,t,n,r){switch(t){case`ArrayBuffer`:return e;case`BinaryString`:return Buffer.from(e).toString(`latin1`);case`Text`:{let t;try{t=new TextDecoder(r)}catch{t=new TextDecoder}return t.decode(e)}case`DataURL`:return`data:${n||`application/octet-stream`};base64,${Buffer.from(e).toString(`base64`)}`}}const Tp={observe:null,unobserve:null,disconnect:null};var ResizeObserver=class{[ot];constructor(e){if(typeof e!=`function`)throw TypeError(`Failed to construct 'ResizeObserver': parameter 1 is not of type 'ResizeObserverCallback'.`);this[ot]=e}observe(e,t){if(typeof e!=`object`||!e)throw TypeError(`Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element'.`);let n=t?.box,r=n===void 0?`content-box`:String(n);Vd&&Tp.observe?.(this,e,r)}unobserve(e){Vd&&Tp.unobserve?.(this,e)}disconnect(){Vd&&Tp.disconnect?.(this)}get[Symbol.toStringTag](){return`ResizeObserver`}},IntersectionObserver=class{root;rootMargin;scrollMargin;thresholds;constructor(e,t={}){if(typeof e!=`function`)throw TypeError(`Failed to construct 'IntersectionObserver': parameter 1 is not of type 'IntersectionObserverCallback'.`);this.root=t.root??null,this.rootMargin=normalizeMargin(t.rootMargin??`0px`),this.scrollMargin=normalizeMargin(t.scrollMargin??`0px`);let n=t.threshold??0,r=(Array.isArray(n)?n:[n]).map(Number);for(let e of r)if(!(e>=0&&e<=1))throw RangeError(`Failed to construct 'IntersectionObserver': Threshold values must be numbers between 0 and 1`);this.thresholds=Object.freeze(r.sort((e,t)=>e-t))}observe(e){}unobserve(e){}disconnect(){}takeRecords(){return[]}get[Symbol.toStringTag](){return`IntersectionObserver`}},IntersectionObserverEntry=class{#e;#t;#n;#r;#i;#a;#o;constructor(e){let t=`Failed to construct 'IntersectionObserverEntry'`;if(typeof e!=`object`||!e)throw TypeError(`${t}: 1 argument required, but only 0 present.`);let required=n=>{let r=e[n];if(r===void 0)throw TypeError(`${t}: Failed to read the '${n}' property from 'IntersectionObserverEntryInit': Required member is undefined.`);return r};this.#n=DOMRectReadOnly.fromRect(required(`boundingClientRect`)),this.#a=Number(required(`intersectionRatio`)),this.#r=DOMRectReadOnly.fromRect(required(`intersectionRect`)),this.#i=!!required(`isIntersecting`);let n=required(`rootBounds`);this.#t=n===null?null:DOMRectReadOnly.fromRect(n);let r=required(`target`);if(typeof r!=`object`||r.nodeType!==1)throw TypeError(`${t}: Failed to read the 'target' property from 'IntersectionObserverEntryInit': Failed to convert value to 'Element'.`);this.#o=r,this.#e=Number(required(`time`))}get time(){return this.#e}get rootBounds(){return this.#t}get boundingClientRect(){return this.#n}get intersectionRect(){return this.#r}get isIntersecting(){return this.#i}get intersectionRatio(){return this.#a}get target(){return this.#o}};exposeMembers(IntersectionObserverEntry),defineInterfaceShape(IntersectionObserverEntry,{constructor:1});function normalizeMargin(e){let t=String(e).trim().split(/\s+/).filter(Boolean);t.length===0&&t.push(`0px`);for(let e of t)if(!/^-?(\d+|\d*\.\d+)(px|%)$/.test(e)&&e!==`0`)throw new DOMException(`Failed to construct 'IntersectionObserver': rootMargin must be specified in pixels or percent.`,`SyntaxError`);let[n,r=n,i=n,a=r]=t.map(e=>e===`0`?`0px`:e);return`${n} ${r} ${i} ${a}`}var Box=class{x;y;vx;vy;w;h;mt;mr;mb;ml;bt;br;bb;bl;pt;pr;pb;pl;idx;end;gen;flags;constructor(){this.x=0,this.y=0,this.vx=0,this.vy=0,this.w=0,this.h=0,this.mt=0,this.mr=0,this.mb=0,this.ml=0,this.bt=0,this.br=0,this.bb=0,this.bl=0,this.pt=0,this.pr=0,this.pb=0,this.pl=0,this.idx=0,this.end=0,this.gen=0,this.flags=0}},LayoutState=class{version;styleVersion;vw;vh;gen;list;constructor(){this.version=-1,this.styleVersion=-1,this.vw=-1,this.vh=-1,this.gen=0,this.list=[]}};const Ep=/* @__PURE__ */ new WeakMap,Dp=/* @__PURE__ */ new WeakMap,createLayoutState=()=>new LayoutState;let Op=null;function setRelayoutListener(e){Op=e}function layoutOn(e){if(!Vd)return!1;let t=e[Y];return t!==null&&t[V].layout===`lite`}function ensure(e){let t=derivedCache(e,LayoutState,createLayoutState),n=currentStyleVersion(e),r=e[Y],i=r[Mn],a=r[jn];return t.version===e[J]&&t.styleVersion===n&&t.vw===i&&t.vh===a||(run(t,e,i,a),t.version=e[J],t.styleVersion=n,t.vw=i,t.vh=a,Op?.(e)),t}function boxOf(e){if(!Vd||!(e.flags&1))return null;let t=e.doc;if(!layoutOn(t))return null;let n=ensure(t),r=Ep.get(e);return r!==void 0&&r.gen===n.gen?r:null}let kp=0;const Ap=[];let jp=Ap,Mp=!1,Np=16,Pp=1024,Fp=768,Ip=0;var PendingAbs=class{el;sx;sy;fs;lh;fixed;constructor(e,t,n,r,i,a){this.el=e,this.sx=t,this.sy=n,this.fs=r,this.lh=i,this.fixed=a}};const Lp=[],Rp=[];function run(e,t,n,r){e.gen=++kp,e.list.length=0,Pp=n,Fp=r;let i=null;for(let e=t[z].first;e!==null;e=e.next)e.type===1&&(i=e);if(i!==null){jp=e.list;try{Mp=hasAuthorStyles(t),Np=16,Np=fontSize(i,16);let e=computedDisplay(i);for(e!==`none`&&e!==`contents`&&layoutBox(i,0,0,n,r,16,`normal`,NaN,NaN,!1,8),flushPending(0,0,0,n,r,!0);Rp.length!==0;){let e=Rp.splice(0);for(let t=0;t<e.length;t++)layoutAbs(e[t],0,0,n,r)}}finally{for(Bp=null,jp=Ap,Vp=``;Xp>0;)Yp[--Xp].length=0;Lp.length=0,Rp.length=0}}}function plain(e){return!Mp&&!(e.flags&64)}var Style=class{gen;position;transform;borderBox;scroller;mt;mr;mb;ml;bt;br;bb;bl;pt;pr;pb;pl;width;height;minW;maxW;minH;maxH;top;right;bottom;left;flexDir;grow;shrink;basis;alignSelf;alignItems;justify;rowGap;colGap;fs;lh;constructor(){this.gen=-1,this.position=`static`,this.transform=`none`,this.borderBox=!1,this.scroller=!1,this.mt=this.mr=this.mb=this.ml=`0px`,this.bt=this.br=this.bb=this.bl=`0px`,this.pt=this.pr=this.pb=this.pl=`0px`,this.width=this.height=this.minW=this.minH=`auto`,this.maxW=this.maxH=`none`,this.top=this.right=this.bottom=this.left=`auto`,this.flexDir=`row`,this.grow=0,this.shrink=1,this.basis=`auto`,this.alignSelf=`auto`,this.alignItems=`normal`,this.justify=`normal`,this.rowGap=this.colGap=`normal`,this.fs=NaN,this.lh=``}};const zp=new Style;function sty(e){if(plain(e)&&!hasUAFontSize(e))return zp;let t=Dp.get(e);return t===void 0&&Dp.set(e,t=new Style),t.gen!==kp&&fillStyle(e,t),t}let Bp=null;function g(e,t){let n=Bp.decls;return n===null||!n.has(e)?t:computedValueOf(Bp,e)}function gBorder(e,t){let n=Bp.decls;return n===null||!n.has(e)&&!n.has(t)?`0px`:computedValueOf(Bp,e)}function fillStyle(e,t){t.gen=kp,Bp=styleRecord(e),t.position=g(`position`,`static`),t.transform=g(`transform`,`none`),t.borderBox=g(`box-sizing`,`content-box`)===`border-box`;let n=g(`overflow-x`,`visible`),r=g(`overflow-y`,`visible`);t.scroller=n!==`visible`&&n!==`clip`&&n!==``||r!==`visible`&&r!==`clip`&&r!==``,t.mt=g(`margin-top`,`0px`),t.mr=g(`margin-right`,`0px`),t.mb=g(`margin-bottom`,`0px`),t.ml=g(`margin-left`,`0px`),t.bt=gBorder(`border-top-width`,`border-top-style`),t.br=gBorder(`border-right-width`,`border-right-style`),t.bb=gBorder(`border-bottom-width`,`border-bottom-style`),t.bl=gBorder(`border-left-width`,`border-left-style`),t.pt=g(`padding-top`,`0px`),t.pr=g(`padding-right`,`0px`),t.pb=g(`padding-bottom`,`0px`),t.pl=g(`padding-left`,`0px`),t.width=g(`width`,`auto`),t.height=g(`height`,`auto`),t.minW=g(`min-width`,`auto`),t.maxW=g(`max-width`,`none`),t.minH=g(`min-height`,`auto`),t.maxH=g(`max-height`,`none`),t.top=g(`top`,`auto`),t.right=g(`right`,`auto`),t.bottom=g(`bottom`,`auto`),t.left=g(`left`,`auto`),t.flexDir=g(`flex-direction`,`row`),t.grow=Number(g(`flex-grow`,`0`))||0;let i=Number(g(`flex-shrink`,`1`));t.shrink=Number.isFinite(i)?i:1,t.basis=g(`flex-basis`,`auto`),t.alignSelf=g(`align-self`,`auto`),t.alignItems=g(`align-items`,`normal`),t.justify=g(`justify-content`,`normal`),t.rowGap=g(`row-gap`,`normal`),t.colGap=g(`column-gap`,`normal`);let a=parseFloat(computedValueOf(Bp,`font-size`));t.fs=Number.isFinite(a)?a:NaN,t.lh=computedValueOf(Bp,`line-height`)}function hasUAFontSize(e){if(e.ns!==`http://www.w3.org/1999/xhtml`)return!1;switch(e.tag){case Z.h1:case Z.h2:case Z.h3:case Z.h5:case Z.h6:case Z.small:case Z.big:case Z.sub:case Z.sup:return!0}return!1}function fontSize(e,t){let n=sty(e).fs;return Number.isNaN(n)?t:n}function lineHeightPx(e,t){if(e===`normal`||e===``)return t*6/5;let n=Number(e);if(Number.isFinite(n))return n*t;let r=length(e,t,t);return Number.isNaN(r)?t*1.2:r}function lineHeightOf(e,t){let n=sty(e).lh;return n===``?t:n}function length(e,t,n){let r=e.length;if(r===0)return NaN;if(r>2&&e.charCodeAt(r-1)===120&&e.charCodeAt(r-2)===112){let t=Number(e.slice(0,-2));if(Number.isFinite(t))return t}if(e===`0`)return 0;if(e===`auto`||e===`none`||e===`normal`)return NaN;Vp=e,Hp=0,Up=t,Wp=n;let i=parseSum();return skipWs(),Hp===e.length?i:NaN}let Vp=``,Hp=0,Up=NaN,Wp=16;function skipWs(){for(;Hp<Vp.length&&Vp.charCodeAt(Hp)<=32;)Hp++}function parseSum(){let e=parseProduct();for(;;){skipWs();let t=Vp[Hp];if(t!==`+`&&t!==`-`)return e;Hp++;let n=parseProduct();e=t===`+`?e+n:e-n}}function parseProduct(){let e=parseValue();for(;;){skipWs();let t=Vp[Hp];if(t!==`*`&&t!==`/`)return e;Hp++;let n=parseValue();e=t===`*`?e*n:e/n}}const Gp=/[+-]?(?:\d+\.?\d*|\.\d+)(?:e[+-]?\d+)?/iy,Kp=/[a-z]+|%/iy;function parseValue(){skipWs();let e=Vp;if(e[Hp]===`(`){Hp++;let t=parseSum();return skipWs(),e[Hp]===`)`?(Hp++,t):NaN}let t=e.slice(Hp,Hp+6).toLowerCase();for(let n of qp)if(t.startsWith(n)){Hp+=n.length;let t=[parseSum()];for(skipWs();e[Hp]===`,`;)Hp++,t.push(parseSum()),skipWs();return e[Hp]===`)`?(Hp++,n===`calc(`?t.length===1?t[0]:NaN:n===`min(`?Math.min(...t):n===`max(`?Math.max(...t):t.length===3?Math.max(t[0],Math.min(t[1],t[2])):NaN):NaN}Gp.lastIndex=Hp;let n=Gp.exec(e);if(n===null)return NaN;Hp+=n[0].length;let r=Number(n[0]);Kp.lastIndex=Hp;let i=Kp.exec(e);return i===null?r:(Hp+=i[0].length,unitPx(r,i[0].toLowerCase()))}const qp=[`calc(`,`min(`,`max(`,`clamp(`];function unitPx(e,t){switch(t){case`px`:return e;case`%`:return e*Up/100;case`em`:return e*Wp;case`rem`:return e*Np;case`ex`:case`ch`:return e*Wp*.5;case`lh`:return e*Wp*1.2;case`vw`:case`svw`:case`lvw`:case`dvw`:return e*Pp/100;case`vh`:case`svh`:case`lvh`:case`dvh`:return e*Fp/100;case`vmin`:return e*Math.min(Pp,Fp)/100;case`vmax`:return e*Math.max(Pp,Fp)/100;case`in`:return e*96;case`cm`:return e*96/2.54;case`mm`:return e*96/25.4;case`q`:return e*96/101.6;case`pt`:return e*96/72;case`pc`:return e*16}return NaN}function lenOr0(e,t,n){let r=length(e,t,n);return Number.isNaN(r)?0:r}function edges(e,t,n,r){let i=sty(e);i===zp?(t.mt=t.mr=t.mb=t.ml=0,t.bt=t.br=t.bb=t.bl=0,t.pt=t.pr=t.pb=t.pl=0):(t.mt=lenOr0(i.mt,n,r),t.mr=lenOr0(i.mr,n,r),t.mb=lenOr0(i.mb,n,r),t.ml=lenOr0(i.ml,n,r),t.bt=lenOr0(i.bt,n,r),t.br=lenOr0(i.br,n,r),t.bb=lenOr0(i.bb,n,r),t.bl=lenOr0(i.bl,n,r),t.pt=Math.max(0,lenOr0(i.pt,n,r)),t.pr=Math.max(0,lenOr0(i.pr,n,r)),t.pb=Math.max(0,lenOr0(i.pb,n,r)),t.pl=Math.max(0,lenOr0(i.pl,n,r)))}function borderBox(e){return sty(e).borderBox}function toContent(e,t,n){return Math.max(0,borderBox(t)?e-n:e)}function clampSize(e,t,n,r,i,a,o){if(n===`auto`&&r===`none`)return t;let s=length(r,i,a);Number.isNaN(s)||(t=Math.min(t,toContent(s,e,o)));let c=length(n,i,a);return Number.isNaN(c)||(t=Math.max(t,toContent(c,e,o))),t}function isReplaced(e){if(e.ns===`http://www.w3.org/2000/svg`)return e.name===`svg`;if(e.ns!==`http://www.w3.org/1999/xhtml`)return!1;switch(e.tag){case Z.img:case Z.canvas:case Z.video:case Z.iframe:case Z.embed:case Z.object:case Z.audio:case Z.input:case Z.textarea:case Z.select:return!0}return!1}function intAttr(e,t,n){let r=attr(e,t);if(r===null)return n;let i=parseFloat(r);return Number.isFinite(i)&&i>=0?i:n}let Jp=0;function intrinsicW(e,t,n){if(e.ns===`http://www.w3.org/2000/svg`)return Jp=intAttr(e,`height`,150),intAttr(e,`width`,300);switch(e.tag){case Z.img:return Jp=intAttr(e,`height`,0),intAttr(e,`width`,0);case Z.audio:return Jp=54,300;case Z.input:{let r=asciiLowercase$1(attr(e,`type`)??`text`);return r===`checkbox`||r===`radio`?(Jp=13,13):(Jp=n,r===`submit`||r===`reset`||r===`button`?textWidth(attr(e,`value`)??(r===`submit`?`Submit`:r===`reset`?`Reset`:``),t):intAttr(e,`size`,20)*t*.5)}case Z.textarea:return Jp=intAttr(e,`rows`,2)*n,intAttr(e,`cols`,20)*t*.5;case Z.select:{Jp=(attr(e,`multiple`)!==null||intAttr(e,`size`,1)>1?intAttr(e,`size`,4):1)*n;let r=0;for(let n=e.first;n!==null;n=n.next)n.type===1&&(r=Math.max(r,textWidth(textContent(n),t)));return r+20}}return Jp=intAttr(e,`height`,150),intAttr(e,`width`,300)}function textContent(e){let t=``;for(let n=e.first;n!==null;n=n.next)n.type===3||n.type===4?t+=n.data:n.type===1&&(t+=textContent(n));return t}function textWidth(e,t){let n=0,r=!0;for(let t=0;t<e.length;t++){let i=e.charCodeAt(t);i===32||i===9||i===10||i===13||i===12?r||=(n++,!0):(n++,r=!1)}return r&&n>0&&n--,n*t*.5}function isBlank(e){for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n!==32&&n!==9&&n!==10&&n!==13&&n!==12)return!1}return!0}function kindOf(e,t){switch(t){case`none`:return 0;case`inline`:return isReplaced(e)?3:hasBlockChild(e)?1:2;case`inline-block`:case`inline-flex`:case`inline-grid`:case`inline-table`:case`inline flow-root`:case`inline flex`:case`inline grid`:return 3}return isReplaced(e)&&t!==`block`?3:1}function hasBlockChild(e){for(let t=e.first;t!==null;t=t.next){if(t.type!==1)continue;let e=computedDisplay(t);if(e===`contents`?hasBlockChild(t):e!==`none`&&e!==`inline`&&kindOf(t,e)===1)return!0}return!1}function isFlex(e){return e===`flex`||e===`inline-flex`||e===`inline flex`||e===`block flex`}const Yp=[];let Xp=0;function collect(e,t){let n=e;if(e.flags&512){let t=e.node[G];t!=null&&(n=t[z])}for(let e=n.first;e!==null;e=e.next)collectNode(e,t)}function collectNode(e,t){if(e.type===3||e.type===4)t.push(e);else if(e.type===1){if(e.ns===`http://www.w3.org/1999/xhtml`&&e.tag===Z.slot&&e.parent!==null&&isInShadowTree(e)){if(computedDisplay(e)!==`contents`){t.push(e);return}let n=findFlattenedSlottables(e);for(let e=0;e<n.length;e++)collectNode(n[e],t);return}computedDisplay(e)===`contents`?collect(e,t):t.push(e)}}function isInShadowTree(e){let t=e;for(;t.parent!==null;)t=t.parent;return!!(t.flags&32)}function children(e){let t=Yp[Xp]??(Yp[Xp]=[]);return Xp++,t.length=0,collect(e,t),t}function releaseChildren(e){e.length=0,Xp--}function newBox(e,t){let n=Ep.get(e);return n===void 0&&Ep.set(e,n=new Box),n.gen=kp,n.idx=jp.length,n.end=n.idx+1,n.flags=t,jp.push(n),n}function shift(e,t,n,r){if(t===0&&n===0)return;let i=jp;for(let a=e.idx;a<e.end;a++){let e=i[a];e.vx+=t,e.vy+=n,r||(e.x+=t,e.y+=n)}}function translation(e,t,n,r){Zp=0,Qp=0;let i=/(translate3d|translatex|translatey|translate|matrix)\(([^)]*)\)/gi;for(let a=i.exec(e);a!==null;a=i.exec(e)){let e=a[1].toLowerCase(),i=a[2].split(`,`).map(e=>e.trim());e===`matrix`?i.length===6&&(Zp+=Number(i[4])||0,Qp+=Number(i[5])||0):e===`translatex`?Zp+=lenOr0(i[0],t,r):e===`translatey`?Qp+=lenOr0(i[0],n,r):(Zp+=lenOr0(i[0],t,r),i.length>1&&(Qp+=lenOr0(i[1],n,r)))}}let Zp=0,Qp=0;function layoutBox(e,t,n,r,i,a,o,s,c,l,u){let d=newBox(e,u),m=computedDisplay(e),h=fontSize(e,a),_=lineHeightOf(e,o),v=lineHeightPx(_,h),y=plain(e)?`static`:sty(e).position,b=plain(e)?`none`:sty(e).transform;edges(e,d,r,h);let x=d.pl+d.pr+d.bl+d.br,S=d.pt+d.pb+d.bt+d.bb,C=isReplaced(e),w,T=plain(e)?NaN:length(sty(e).width,r,h),ee=!1;if(Number.isNaN(s)?Number.isNaN(T)?C?w=replacedWidth(e,h,v,i):l?(w=Math.min(maxContent(e,a)-x,r-d.ml-d.mr-x),ee=!0):(w=r-d.ml-d.mr-x,ee=!0):w=toContent(T,e,x):w=Math.max(0,s-x),Number.isNaN(s)&&(w=clampSize(e,Math.max(0,w),sty(e).minW,sty(e).maxW,r,h,x)),!ee&&Number.isNaN(s)&&!l&&!plain(e)){let t=sty(e).ml===`auto`,n=sty(e).mr===`auto`,i=r-w-x-d.ml-d.mr;t&&n?d.ml+=Math.max(0,i/2):t&&(d.ml+=Math.max(0,i))}d.x=d.vx=t+d.ml,d.y=d.vy=n+d.mt,d.w=w+x;let E=plain(e)?NaN:length(sty(e).height,i,h),D=NaN;Number.isNaN(c)?Number.isNaN(E)?C&&(D=replacedHeight(e,h,v,w)):D=clampSize(e,toContent(E,e,S),sty(e).minH,sty(e).maxH,i,h,S):D=Math.max(0,c-S);let te=y!==`static`||b!==`none`||!!(u&8),O=Lp.length,k=d.x+d.bl+d.pl,ne=d.y+d.bt+d.pt,A=0;C||(A=isFlex(m)?layoutFlex(e,k,ne,w,D,h,_,v,!1):m===`table-row`?layoutFlex(e,k,ne,w,D,h,_,v,!0):flow(e,k,ne,w,D,h,_,v));let re=Number.isNaN(D)?clampSize(e,A,sty(e).minH,sty(e).maxH,i,h,S):D;if(Number.isNaN(re)&&(re=0),d.h=re+S,sty(e).scroller&&(d.flags|=1),u&8&&(d.flags|=1),te&&!(u&8)&&flushPending(O,d.x+d.bl,d.y+d.bt,d.w-d.bl-d.br,d.h-d.bt-d.bb,!1),d.end=jp.length,y===`relative`){let t=length(sty(e).left,r,h),n=length(sty(e).top,i,h);shift(d,Number.isNaN(t)?-lenOr0(sty(e).right,r,h):t,Number.isNaN(n)?-lenOr0(sty(e).bottom,i,h):n,!1)}return b!==`none`&&(translation(b,d.w,d.h,h),shift(d,Zp,Qp,!0)),Ip=d.w+d.ml+d.mr,d.h+d.mt+d.mb}function replacedWidth(e,t,n,r){let i=intrinsicW(e,t,n),a=Jp;if(i>0&&a>0&&!plain(e)){let n=length(sty(e).height,r,t);if(!Number.isNaN(n)&&(e.tag===Z.img||e.tag===Z.canvas||e.tag===Z.video||e.ns===`http://www.w3.org/2000/svg`))return n*i/a}return i}function replacedHeight(e,t,n,r){let i=intrinsicW(e,t,n),a=Jp;return i>0&&a>0&&r!==i&&(e.tag===Z.img||e.tag===Z.canvas||e.tag===Z.video||e.ns===`http://www.w3.org/2000/svg`)?r*a/i:a}function deferAbs(e,t,n,r,i,a){Lp.push(new PendingAbs(e,n,r,i,a,t===`fixed`))}function flushPending(e,t,n,r,i,a){if(Lp.length<=e)return;let o=Lp.splice(e);for(let e=0;e<o.length;e++){let s=o[e];s.fixed&&!a?Rp.push(s):s.fixed?layoutAbs(s,0,0,Pp,Fp):layoutAbs(s,t,n,r,i)}}function layoutAbs(e,t,n,r,i){let a=e.el,o=fontSize(a,e.fs);edges(a,$,r,o);let s=$.pl+$.pr+$.bl+$.br,c=$.pt+$.pb+$.bt+$.bb,l=$.ml+$.mr,u=$.mt+$.mb,d=length(sty(a).left,r,o),m=length(sty(a).right,r,o),h=length(sty(a).top,i,o),_=length(sty(a).bottom,i,o),v=length(sty(a).width,r,o),y=length(sty(a).height,i,o),b=NaN;Number.isNaN(v)&&!isReplaced(a)&&(b=!Number.isNaN(d)&&!Number.isNaN(m)?Math.max(s,r-d-m-l):Math.max(s,Math.min(maxContent(a,e.fs),r-(Number.isNaN(d)?0:d)-l)));let x=NaN;Number.isNaN(y)&&!Number.isNaN(h)&&!Number.isNaN(_)&&(x=Math.max(c,i-h-_-u));let S=Number.isNaN(d)?e.sx:t+d,C=Number.isNaN(h)?e.sy:n+h,w=e.fixed?18:0;layoutBox(a,S,C,r,i,e.fs,e.lh,b,x,!1,w);let T=Ep.get(a),ee=0,E=0;if(Number.isNaN(d)&&!Number.isNaN(m)&&(ee=t+r-m-T.mr-T.w-T.x),Number.isNaN(h)&&!Number.isNaN(_)&&(E=n+i-_-T.mb-T.h-T.y),shift(T,ee,E,!1),e.fixed)for(let e=T.idx;e<T.end;e++)jp[e].flags|=2}const $=new Box;function flow(e,t,n,r,i,a,o,s){let c=children(e),l=0,u=!1,d=t,m=0;for(let e=0;e<c.length;e++){let h=c[e];if(h.type!==1){if(isBlank(h.data))continue;u||(u=!0,d=t,m=s),d+=textWidth(h.data,a);continue}let _=kindOf(h,computedDisplay(h));if(_===0)continue;let v=plain(h)?`static`:sty(h).position;if(v===`absolute`||v===`fixed`)deferAbs(h,v,u?d:t,n+l,a,o);else if(h.ns===`http://www.w3.org/1999/xhtml`&&h.tag===Z.br){u||(m=s);let e=newBox(h,4);e.x=e.vx=d,e.y=e.vy=n+l,e.w=0,e.h=m,e.mt=e.mr=e.mb=e.ml=e.bt=e.br=e.bb=e.bl=e.pt=e.pr=e.pb=e.pl=0,l+=m,u=!1,m=0}else if(_===1)u&&(l+=m,u=!1,m=0),l+=layoutBox(h,t,n+l,r,i,a,o,NaN,NaN,!1,0);else if(u||(u=!0,d=t,m=s),_===3){let e=layoutBox(h,d,n+l,r,i,a,o,NaN,NaN,!0,0);d+=Ip,e>m&&(m=e)}else{let e=layoutInline(h,d,n+l,r,a,o);d+=Ip,e>m&&(m=e)}}return u&&(l+=m),releaseChildren(c),l}function layoutInline(e,t,n,r,i,a){let o=newBox(e,4),s=fontSize(e,i),c=lineHeightOf(e,a),l=lineHeightPx(c,s);edges(e,o,r,s),o.x=o.vx=t+o.ml,o.y=o.vy=n;let u=l,d=o.x+o.bl+o.pl,m=children(e);for(let e=0;e<m.length;e++){let t=m[e];if(t.type!==1){d+=textWidth(t.data,s);continue}let i=kindOf(t,computedDisplay(t));if(i===0)continue;let a=plain(t)?`static`:sty(t).position;if(a===`absolute`||a===`fixed`){deferAbs(t,a,d,n,s,c);continue}let o=i===2?layoutInline(t,d,n,r,s,c):layoutBox(t,d,n,r,NaN,s,c,NaN,NaN,!0,0);d+=Ip,o>u&&(u=o)}if(releaseChildren(m),o.w=d+o.pr+o.br-o.x,o.h=u+o.pt+o.pb+o.bt+o.bb,o.end=jp.length,(plain(e)?`static`:sty(e).position)===`relative`){let t=length(sty(e).left,r,s),n=length(sty(e).top,NaN,s);shift(o,Number.isNaN(t)?0:t,Number.isNaN(n)?0:n,!1)}return Ip=o.w+o.ml+o.mr,u}var FlexItem=class{el;text;grow;shrink;main;m0;m1;cross;autoCross;align;constructor(){this.el=null,this.text=``,this.grow=0,this.shrink=1,this.main=0,this.m0=0,this.m1=0,this.cross=0,this.autoCross=!0,this.align=`stretch`}};function layoutFlex(e,t,n,r,i,a,o,s,c){let l=c||plain(e)?`row`:sty(e).flexDir,u=l===`column`||l===`column-reverse`,d=l===`row-reverse`||l===`column-reverse`,m=c||plain(e)?`normal`:u?sty(e).rowGap:sty(e).colGap,h=Math.max(0,lenOr0(m,u?i:r,a)),_=c||plain(e)?`normal`:sty(e).alignItems,v=c||plain(e)?`normal`:sty(e).justify,y=children(e),b=[];for(let e=0;e<y.length;e++){let l=y[e];if(l.type!==1){if(isBlank(l.data))continue;let e=new FlexItem;e.text=l.data,e.main=u?s:textWidth(l.data,a),e.cross=u?textWidth(l.data,a):s,e.shrink=0,b.push(e);continue}if(computedDisplay(l)===`none`)continue;let d=plain(l)?`static`:sty(l).position;if(d===`absolute`||d===`fixed`){deferAbs(l,d,t,n,a,o);continue}let m=new FlexItem;m.el=l;let h=fontSize(l,a);edges(l,$,r,h);let v=$.pl+$.pr+$.bl+$.br,x=$.pt+$.pb+$.bt+$.bb;m.m0=u?$.mt:$.ml,m.m1=u?$.mb:$.mr;let S=plain(l);if(c)m.grow=1,m.shrink=1,m.main=0;else{m.grow=S?0:sty(l).grow,m.shrink=sty(l).shrink;let e=S?`auto`:sty(l).basis,t=u?i:r,n=u?x:v,a=e===`auto`||e===`content`?NaN:length(e,t,h);if(!Number.isNaN(a))a=toContent(a,l,n)+n;else{let e=S?NaN:length(u?sty(l).height:sty(l).width,t,h);Number.isNaN(e)||(a=toContent(e,l,n)+n)}m.main=a}let C=S?`auto`:sty(l).alignSelf;m.align=C===`auto`||C===`normal`?_===`normal`?`stretch`:_:C,m.autoCross=(S?`auto`:u?sty(l).width:sty(l).height)===`auto`&&!isReplaced(l),b.push(m)}releaseChildren(y);let x=jp.length,S=Lp.length,C=u?r:i,w=u?n:t;for(let e=0;e<b.length;e++){let s=b[e];if(s.el===null){w+=s.main+h;continue}let c=u&&s.autoCross&&s.align===`stretch`?r-crossMargins(s.el,r,a,!0):NaN;if(u){let e=layoutBox(s.el,t,w,r,i,a,o,c,s.main,Number.isNaN(c),0),n=Ep.get(s.el);Number.isNaN(s.main)&&(s.main=n.h),s.cross=Ip,w+=e+h}else{let e=s.autoCross&&s.align===`stretch`&&!Number.isNaN(i)?i-crossMargins(s.el,r,a,!1):NaN;layoutBox(s.el,w,n,r,i,a,o,s.main,e,Number.isNaN(s.main),0);let t=Ep.get(s.el);Number.isNaN(s.main)&&(s.main=t.w),s.cross=t.h+t.mt+t.mb,w+=Ip+h}}let T=u?i:r,ee=h*Math.max(0,b.length-1),E=0,D=0;for(let e=0;e<b.length;e++){let t=b[e];ee+=t.main+t.m0+t.m1,E+=t.grow,D+=t.shrink*t.main}let te=!1,O=Number.isNaN(T)?0:T-ee;if(O>0&&E>0){for(let e=0;e<b.length;e++){let t=b[e];t.grow>0&&(t.main+=O*t.grow/E,te=!0)}O=0}else if(O<0&&D>0){for(let e=0;e<b.length;e++){let t=b[e];t.shrink>0&&t.main>0&&(t.main=Math.max(0,t.main+O*t.shrink*t.main/D),te=!0)}O=0}let k=C;if(Number.isNaN(k)){k=0;for(let e=0;e<b.length;e++)b[e].cross>k&&(k=b[e].cross)}if(!u&&Number.isNaN(i))for(let e=0;e<b.length;e++){let t=b[e];t.el!==null&&t.autoCross&&t.align===`stretch`&&t.cross<k&&(te=!0)}let ne=0,A=h;if(O>0&&b.length>0){switch(v){case`center`:ne=O/2;break;case`flex-end`:case`end`:ne=O;break;case`space-between`:A+=b.length>1?O/(b.length-1):0;break;case`space-around`:ne=O/b.length/2,A+=O/b.length;break;case`space-evenly`:ne=O/(b.length+1),A+=O/(b.length+1)}d&&(v===`normal`||v===`flex-start`||v===`start`)&&(ne=O)}te&&(jp.length=x,Lp.length=S),w=(u?n:t)+ne;let re=0,ie=d?b.slice().reverse():b;for(let e=0;e<ie.length;e++){let s=ie[e];if(s.el===null){w+=s.main+A,re+=s.main+A;continue}let c=Ep.get(s.el);if(u){let e=s.autoCross&&s.align===`stretch`?r-crossMargins(s.el,r,a,!0):NaN;te?layoutBox(s.el,t,w,r,i,a,o,e,s.main,Number.isNaN(e),0):shift(c,0,w+c.mt-c.y,!1),shift(c,crossOffset(s.align,r,c.w+c.ml+c.mr),0,!1),w+=c.h+c.mt+c.mb+A,re+=c.h+c.mt+c.mb+A}else{let e=s.autoCross&&s.align===`stretch`?k-crossMargins(s.el,r,a,!1):NaN;te?layoutBox(s.el,w,n,s.main,i,a,o,s.main,e,!1,0):shift(c,w+c.ml-c.x,0,!1),shift(c,0,crossOffset(s.align,k,c.h+c.mt+c.mb),!1),w+=c.w+c.ml+c.mr+A}}return u?Number.isNaN(i)?Math.max(0,re-A):i:k}function crossMargins(e,t,n,r){return edges(e,$,t,fontSize(e,n)),r?$.ml+$.mr:$.mt+$.mb}function crossOffset(e,t,n){if(Number.isNaN(t))return 0;switch(e){case`center`:return(t-n)/2;case`flex-end`:case`end`:case`self-end`:return t-n}return 0}function maxContent(e,t){let n=fontSize(e,t);edges(e,$,NaN,n);let r=$.pl+$.pr+$.bl+$.br;if(isReplaced(e))return intrinsicW(e,n,lineHeightPx(lineHeightOf(e,`normal`),n))+r;if(!plain(e)){let t=length(sty(e).width,NaN,n);if(!Number.isNaN(t))return toContent(t,e,r)+r}let i=isFlex(computedDisplay(e))&&(plain(e)||!sty(e).flexDir.startsWith(`column`)),a=i&&!plain(e)?Math.max(0,lenOr0(sty(e).colGap,NaN,n)):0,o=children(e),s=0,c=0,l=0;for(let e=0;e<o.length;e++){let t=o[e];if(t.type!==1){c+=textWidth(t.data,n);continue}let r=kindOf(t,computedDisplay(t));if(r===0)continue;if(!plain(t)){let e=sty(t).position;if(e===`absolute`||e===`fixed`)continue}if(t.ns===`http://www.w3.org/1999/xhtml`&&t.tag===Z.br){s=Math.max(s,c),c=0;continue}let u=maxContent(t,n);edges(t,$,NaN,fontSize(t,n));let d=u+$.ml+$.mr;i?(c+=d+(l>0?a:0),l++):r===1?(s=Math.max(s,c,d),c=0):c+=d}return releaseChildren(o),Math.max(s,c)+r}function viewport(e){return e.doc[Y]}function scrollExtent(e,t,n){let r=peekDerivedCache(e.doc,LayoutState).list,i=t.vx+t.bl,a=t.vy+t.bt,o=0;for(let e=t.idx+1;e<t.end;e++){let s=r[e];if(s.flags&16&&!(t.flags&8)){e=s.end-1;continue}let c=n?s.vy+s.h+s.mb-a:s.vx+s.w+s.mr-i;c>o&&(o=c),s.flags&1&&(e=s.end-1)}return Math.round((o+(n?t.pb:t.pr))*64)/64}function clientWidthOf(e,t){return e.flags&4?0:e.flags&8?viewport(t)[Mn]:e.w-e.bl-e.br}function clientHeightOf(e,t){return e.flags&4?0:e.flags&8?viewport(t)[jn]:e.h-e.bt-e.bb}function knownBox(e){let t=peekDerivedCache(e.doc,LayoutState);if(t===void 0)return null;let n=Ep.get(e);return n!==void 0&&n.gen===t.gen?n:null}var ResizeObserverSize=class{inlineSize;blockSize;constructor(e,t){this.inlineSize=e,this.blockSize=t}get[Symbol.toStringTag](){return`ResizeObserverSize`}},ResizeObserverEntry=class{target;contentRect;borderBoxSize;contentBoxSize;devicePixelContentBoxSize;constructor(e,t,n,r,i,a){this.target=e,this.contentRect=new DOMRectReadOnly(i,a,n.inlineSize,n.blockSize),this.borderBoxSize=Object.freeze([t]),this.contentBoxSize=Object.freeze([n]),this.devicePixelContentBoxSize=Object.freeze([r])}get[Symbol.toStringTag](){return`ResizeObserverEntry`}},ObservedTargets=class extends Set{observer;constructor(e){super(),this.observer=new WeakRef(e)}},Observation=class extends WeakRef{box;lastInline=-1;lastBlock=-1;targets;documentObservers;constructor(e,t,n,r){super(e),this.box=t,this.targets=n,this.documentObservers=r}};const $p=/* @__PURE__ */ new WeakMap,em=/* @__PURE__ */ new WeakMap,tm=/* @__PURE__ */ new WeakMap,nm=new FinalizationRegistry(forgetObservation),rm=/* @__PURE__ */ new Set;let im=!1,am=0;const om=globalThis.queueMicrotask.bind(globalThis);function schedule(e){rm.add(e),!im&&(im=!0,om(runChecks))}function observe(e,t,n){let r=t[z];if(r===void 0)return;let i=r.doc;if(!layoutOn(i))return;let a=$p.get(t);a===void 0&&$p.set(t,a=/* @__PURE__ */ new Map);let o=em.get(e);o===void 0&&em.set(e,o=new ObservedTargets(e));let s=tm.get(i);s===void 0&&tm.set(i,s=/* @__PURE__ */ new Map);let c=a.get(e);if(c!==void 0&&c.documentObservers===s)c.box=n,c.lastInline=c.lastBlock=-1,o.delete(c),o.add(c);else{let r=new Observation(t,n,o,s);o.add(r),a.set(e,r),s.set(o,(s.get(o)??0)+1),nm.register(t,r,r),c!==void 0&&(nm.unregister(c),forgetObservation(c))}am=0,schedule(i)}function forgetObservation(e){let t=e.targets;t.delete(e);let n=e.documentObservers,r=n.get(t);r===1?n.delete(t):n.set(t,r-1)}function unobserve(e,t){let n=$p.get(t);if(n===void 0)return;let r=n.get(e);r!==void 0&&(n.delete(e),n.size===0&&$p.delete(t),nm.unregister(r),forgetObservation(r))}function disconnect(e){let t=em.get(e);if(t!==void 0){for(let n of t){let t=n.deref();t===void 0?(nm.unregister(n),forgetObservation(n)):unobserve(e,t)}em.delete(e)}}function changedEntry(e,t){let n=t[z],r=boxOf(n),i=r?.w??0,a=r?.h??0,o=r===null?0:Math.max(0,r.w-r.bl-r.br-r.pl-r.pr),s=r===null?0:Math.max(0,r.h-r.bt-r.bb-r.pt-r.pb),c=r===null?1:n.doc[Y][Lt],l=Math.round(o*c),u=Math.round(s*c),d=o,m=s;return e.box===`border-box`?(d=i,m=a):e.box===`device-pixel-content-box`&&(d=l,m=u),d===e.lastInline&&m===e.lastBlock?null:(e.lastInline=d,e.lastBlock=m,new ResizeObserverEntry(t,new ResizeObserverSize(i,a),new ResizeObserverSize(o,s),new ResizeObserverSize(l,u),r?.pl??0,r?.pt??0))}function runChecks(){im=!1;let e=[...rm];rm.clear();let t=!1;for(let n of e){let e=tm.get(n);if(e!==void 0)for(let n of Array.from(e.keys())){let e=n.observer.deref();if(e===void 0)continue;let r=[];for(let e of n){let t=e.deref();if(t===void 0)continue;let n=changedEntry(e,t);n!==null&&r.push(n)}if(r.length!==0){t=!0;try{e[ot].call(e,r,e)}catch(e){reportException$1(e,r[0].target)}}}}t?am++:am=0}Tp.observe=observe,Tp.unobserve=unobserve,Tp.disconnect=disconnect,setRelayoutListener(e=>{am<32&&tm.get(e)?.size&&schedule(e)});function dictionary(e,t,n){if(e==null)return null;if(typeof e!=`object`&&typeof e!=`function`)throw TypeError(`Failed to ${t}: The provided value is not of type '${n}'.`);return e}function number(e,t){return e===void 0?t:Number(e)}function pointFromInit(e,t){let n=dictionary(e,t,`DOMPointInit`);if(n===null)return new ls;let r=number(n.w,1);return new ls(number(n.x,0),number(n.y,0),number(n.z,0),r)}let sm=null,cm=null,lm=null,um=null;function quadOf(e,t,n,r){return sm=e,cm=t,lm=n,um=r,new dm}var dm=class DOMQuad{#e;#t;#n;#r;constructor(e,t,n,r){let i=sm;if(i!==null){this.#e=i,this.#t=cm,this.#n=lm,this.#r=um,sm=cm=lm=um=null;return}let a=`construct 'DOMQuad'`;this.#e=pointFromInit(e,a),this.#t=pointFromInit(t,a),this.#n=pointFromInit(n,a),this.#r=pointFromInit(r,a)}static fromRect(e){let t=dictionary(e,`execute 'fromRect' on 'DOMQuad'`,`DOMRectInit`),n=t===null?0:number(t.height,0),r=t===null?0:number(t.width,0),i=t===null?0:number(t.x,0),a=t===null?0:number(t.y,0);return quadOf(new ls(i,a,0,1),new ls(i+r,a,0,1),new ls(i+r,a+n,0,1),new ls(i,a+n,0,1))}static fromQuad(e){let t=`execute 'fromQuad' on 'DOMQuad'`,n=dictionary(e,t,`DOMQuadInit`);return n===null?new DOMQuad:quadOf(pointFromInit(n.p1,t),pointFromInit(n.p2,t),pointFromInit(n.p3,t),pointFromInit(n.p4,t))}get p1(){return this.#e}get p2(){return this.#t}get p3(){return this.#n}get p4(){return this.#r}getBounds(){let e=this.#e,t=this.#t,n=this.#n,r=this.#r,i=Math.min(e.x,t.x,n.x,r.x),a=Math.min(e.y,t.y,n.y,r.y),o=Math.max(e.x,t.x,n.x,r.x),s=Math.max(e.y,t.y,n.y,r.y);return new us(i,a,o-i,s-a)}toJSON(){return{p1:this.#e.toJSON(),p2:this.#t.toJSON(),p3:this.#n.toJSON(),p4:this.#r.toJSON()}}};exposeMembers(dm),defineInterfaceShape(dm);const fm=/* @__PURE__ */ new Set([`none`,`copy`,`link`,`move`]),pm=/* @__PURE__ */ new Set([`none`,`copy`,`copyLink`,`copyMove`,`link`,`linkMove`,`move`,`all`,`uninitialized`]);function asciiLowercase(e){return e.replace(/[A-Z]/g,e=>e.toLowerCase())}let mm=!1;var DataTransferItem=class{constructor(){if(!mm)throw TypeError(`Illegal constructor`);defineHidden(this,Fn,``),defineHidden(this,ti,``),defineHidden(this,jt,``),defineHidden(this,Yt,null)}get kind(){return this[Fn]}get type(){return this[ti]}getAsString(e){if(e==null||this[Fn]!==`string`)return;let t=this[jt];queueMicrotask(()=>e(t))}getAsFile(){return this[Fn]===`file`?this[Yt]:null}webkitGetAsEntry(){return null}};Object.defineProperty(DataTransferItem.prototype,Symbol.toStringTag,{value:`DataTransferItem`,configurable:!0});function makeItem(e,t,n,r){mm=!0;try{let i=new DataTransferItem;return i[Fn]=e,i[ti]=t,i[jt]=n,i[Yt]=r,i}finally{mm=!1}}function disableItem(e){e[Fn]=``,e[ti]=``,e[jt]=``,e[Yt]=null}var DataTransferItemList=class{constructor(){if(!mm)throw TypeError(`Illegal constructor`);defineHidden(this,B,[]),defineHidden(this,er,null)}get length(){return this[B].length}add(e,t){let n;if(typeof e==`string`||t!==void 0){if(arguments.length<2)throw TypeError(`Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'.`);let r=asciiLowercase(String(t));for(let e of this[B])if(e[Fn]===`string`&&e[ti]===r)throw new DOMException(`Failed to execute 'add' on 'DataTransferItemList': An item already exists for type '${r}'.`,`NotSupportedError`);n=makeItem(`string`,r,String(e),null)}else{if(typeof File>`u`||!(e instanceof File))throw TypeError(`Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'.`);n=makeItem(`file`,asciiLowercase(e.type),``,e)}let r=this[B].length;return this[B].push(n),this._changed(r,r),n}remove(e){let t=e>>>0;if(t>=this[B].length)return;let[n]=this[B].splice(t,1);disableItem(n),this._changed(t,this[B].length+1)}clear(){let e=this[B].length;for(let e of this[B])disableItem(e);this[B].length=0,this._changed(0,e)}[Symbol.iterator](){return this[B][Symbol.iterator]()}_changed(e,t){let n=this[B];for(let t=e;t<n.length;t++)Object.defineProperty(this,t,{value:n[t],enumerable:!0,configurable:!0,writable:!1});for(let e=n.length;e<t;e++)delete this[e];let r=this[er]?.deref();r!==void 0&&(r[ni]=null,r[Xt]=null)}};Object.defineProperty(DataTransferItemList.prototype,Symbol.toStringTag,{value:`DataTransferItemList`,configurable:!0});function makeList(){mm=!0;try{return new DataTransferItemList}finally{mm=!1}}function normalizeFormat(e){let t=asciiLowercase(String(e));return t===`text`?{type:`text/plain`,url:!1}:t===`url`?{type:`text/uri-list`,url:!0}:{type:t,url:!1}}var DataTransfer=class{constructor(){defineHidden(this,Ut,`none`),defineHidden(this,Wt,`uninitialized`),defineHidden(this,B,makeList()),defineHidden(this,ni,null),defineHidden(this,Xt,null)}get dropEffect(){return this[Ut]}set dropEffect(e){let t=String(e);fm.has(t)&&(this[Ut]=t)}get effectAllowed(){return this[Wt]}set effectAllowed(e){let t=String(e);pm.has(t)&&(this[Wt]=t)}get items(){return this[B]}setDragImage(e,t,n){}get types(){if(this[ni]!==null)return this[ni];this[B][er]??=new WeakRef(this);let e=[],t=!1;for(let n of this[B][B])n[Fn]===`string`?e.push(n[ti]):n[Fn]===`file`&&(t=!0);return t&&e.push(`Files`),this[ni]=Object.freeze(e)}getData(e){let{type:t,url:n}=normalizeFormat(e);for(let e of this[B][B])if(e[Fn]===`string`&&e[ti]===t){if(!n)return e[jt];for(let t of e[jt].split(/\r?\n/))if(t!==``&&!t.startsWith(`#`))return t;return``}return``}setData(e,t){let{type:n}=normalizeFormat(e),r=makeItem(`string`,n,String(t),null),i=this[B][B],a=i.length,o=0;for(;o<a;o++)if(i[o][Fn]===`string`&&i[o][ti]===n){disableItem(i[o]),i.splice(o,1);break}i.push(r),this[B]._changed(o,a)}clearData(e){let t=this[B][B],n=e===void 0?null:normalizeFormat(e).type,r=t.length,i=r,a=0;for(let e=0;e<r;e++){let r=t[e];r[Fn]===`string`&&(n===null||r[ti]===n)?(a===e&&(i=e),disableItem(r)):(a!==e&&(t[a]=r),a++)}t.length=a,this[B]._changed(i,r)}get files(){if(this[Xt]!==null)return this[Xt];this[B][er]??=new WeakRef(this);let e=[];for(let t of this[B][B])t[Fn]===`file`&&t[Yt]!==null&&e.push(t[Yt]);return this[Xt]=createFileList(e)}};Object.defineProperty(DataTransfer.prototype,Symbol.toStringTag,{value:`DataTransfer`,configurable:!0}),exposeMembers(DataTransfer,DataTransferItemList,DataTransferItem);let hm=0;var MutationObserver=class{[Sn];[ot];[vr];[Qn];[$r];constructor(e){if(typeof e!=`function`)throw TypeError(`Failed to construct 'MutationObserver': parameter 1 is not of type 'Function'.`);this[Sn]=hm++,this[ot]=e,this[vr]=[],this[Qn]=/* @__PURE__ */ new Set,this[$r]=null}observe(e,t={}){if(typeof e!=`object`||!e||!(z in e))throw TypeError(`Failed to execute 'observe' on 'MutationObserver': parameter 1 is not of type 'Node'.`);let n=t.attributes,r=t.characterData;if((t.attributeOldValue!==void 0||t.attributeFilter!==void 0)&&n===void 0&&(n=!0),t.characterDataOldValue!==void 0&&r===void 0&&(r=!0),!t.childList&&!n&&!r)throw TypeError(`Failed to execute 'observe' on 'MutationObserver': The options object must set at least one of 'attributes', 'characterData', or 'childList' to true.`);if(t.attributeOldValue&&!n)throw TypeError(`Failed to execute 'observe' on 'MutationObserver': The options object may only set 'attributeOldValue' to true when 'attributes' is true or not present.`);if(t.attributeFilter!==void 0&&!n)throw TypeError(`Failed to execute 'observe' on 'MutationObserver': The options object may only set 'attributeFilter' when 'attributes' is true or not present.`);if(t.characterDataOldValue&&!r)throw TypeError(`Failed to execute 'observe' on 'MutationObserver': The options object may only set 'characterDataOldValue' to true when 'characterData' is true or not present.`);let i=new NormalizedOptions(t,!!n,!!r),a=e[z],o=registeredObserverList(a);if(o!==null)for(let e=0;e<o.length;e++){let t=o[e];if(t.observer===this&&t.source===null){removeTransientRegistrations(this,t),t.updateOptions(i);return}}addRegistration(a,new RegisteredObserver(a,this,i,null))}disconnect(){for(let e of this[Qn])removeRegistration(e);this[$r]=null,this[vr]=[],dropPending(this)}takeRecords(){let e=this[vr];return this[vr]=[],e}};Object.defineProperty(MutationObserver.prototype,Symbol.toStringTag,{value:`MutationObserver`,configurable:!0});function isDisabled(e){return isActuallyDisabled(e)}function isEnabled(e){switch(e.tag){case Z.button:case Z.input:case Z.select:case Z.textarea:case Z.optgroup:case Z.option:case Z.fieldset:return!isActuallyDisabled(e)}return!1}function isMutable(e){switch(e.tag){case Z.input:return!isActuallyDisabled(e)&&!(readonlyApplies(inputType(e))&&contentAttr(e,`readonly`)!==null);case Z.textarea:return!isActuallyDisabled(e)&&contentAttr(e,`readonly`)===null;case Z.select:case Z.button:return!isActuallyDisabled(e)}return!1}function isReadWrite(e){return e.tag===Z.input?readonlyApplies(inputType(e))&&isMutable(e):e.tag===Z.textarea?isMutable(e):isEditable(e)}function isReadOnly(e){return!isReadWrite(e)}function hasReadonlyAttribute(e){return e.tag===Z.input?readonlyApplies(inputType(e))&&contentAttr(e,`readonly`)!==null:e.tag===Z.textarea&&contentAttr(e,`readonly`)!==null}function isRequired(e){switch(e.tag){case Z.input:return requiredApplies(inputType(e))&&contentAttr(e,`required`)!==null;case Z.select:case Z.textarea:return contentAttr(e,`required`)!==null}return!1}function isOptional(e){return(e.tag===Z.input||e.tag===Z.select||e.tag===Z.textarea)&&!isRequired(e)}function validatable(e){if(isFACE(e))return validatableOf(e);switch(e.tag){case Z.input:case Z.select:case Z.textarea:case Z.button:case Z.output:case Z.fieldset:return e.node}return null}function candidateState(e){let t=validatable(e);return t===null||t._barredFromValidation()?0:t._validityFlags()===0?1:2}function hasInvalidControl(e){if(e.tag===Z.form){let t=formControls(e,[],!0);for(let e=0;e<t.length;e++)if(candidateState(t[e])===2)return!0;return!1}for(let t=nextElementInTree(e,e);t!==null;t=nextElementInTree(t,e))if(candidateState(t)===2)return!0;return!1}function isValid(e){return e.tag===Z.form||e.tag===Z.fieldset?!hasInvalidControl(e):candidateState(e)===1}function isInvalid(e){return e.tag===Z.form||e.tag===Z.fieldset?hasInvalidControl(e):candidateState(e)===2}function isUserValid(e){return hasUserValidity(e)&&candidateState(e)===1}function isUserInvalid(e){return hasUserValidity(e)&&candidateState(e)===2}function hasRangeLimitations(e){if(e.tag!==Z.input)return!1;let t=inputType(e);return isNumericType(t)?t===13||contentAttr(e,`min`)!==null||contentAttr(e,`max`)!==null:!1}function isInRange(e){if(!hasRangeLimitations(e))return!1;let t=e.node;return!t._barredFromValidation()&&!(t._validityFlags()&96)}function isOutOfRange(e){if(!hasRangeLimitations(e))return!1;let t=e.node;return!t._barredFromValidation()&&!!(t._validityFlags()&96)}function isChecked(e){if(e.tag===Z.input){let t=inputType(e);return(t===15||t===16)&&e.node._checkedness()}return e.tag===Z.option&&e.node._selectednessNow()}function isIndeterminate(e){if(e.tag===Z.input){let t=inputType(e);return t===15?e.node[N].indeterminate:t===16&&radioGroupHasNoChecked(e)}return e.tag===Z.progress&&contentAttr(e,`value`)===null}function isDefault(e){switch(e.tag){case Z.input:{let t=inputType(e);return t===15||t===16?contentAttr(e,`checked`)!==null:isDefaultButton(e)}case Z.button:return isDefaultButton(e);case Z.option:return contentAttr(e,`selected`)!==null}return!1}function isDefaultButton(e){if(!isSubmitButton(e))return!1;let t=e.node.form;return t!==null&&defaultButton(t[z])===e}function isPlaceholderShown(e){return e.tag===Z.input?!placeholderApplies(inputType(e))||contentAttr(e,`placeholder`)===null?!1:e.node.value===``:e.tag===Z.textarea&&contentAttr(e,`placeholder`)!==null&&e.node.value===``}function isAutofilled(e){return!1}function isTextControl(e){if(e.tag===Z.textarea)return!0;if(e.tag!==Z.input)return!1;let t=inputType(e);return t!==0&&t<=12}function controlValue(e){switch(e.tag){case Z.input:case Z.textarea:case Z.select:case Z.option:case Z.button:case Z.output:return e.node.value}return``}function inputChecked(e){return e.tag===Z.input&&e.node._checkedness()}function inputIndeterminate(e){return e.tag===Z.input&&e.node[N].indeterminate}function optionSelected(e){return e.tag===Z.option&&e.node._selectednessNow()}Object.assign(Ba,{focus:matchesFocus,"focus-within":matchesFocusWithin,"focus-visible":matchesFocusVisible,defined:isDefined,checked:isChecked,indeterminate:isIndeterminate,default:isDefault,disabled:isDisabled,enabled:isEnabled,required:isRequired,optional:isOptional,"read-only":isReadOnly,"read-write":isReadWrite,"placeholder-shown":isPlaceholderShown,valid:isValid,invalid:isInvalid,"user-valid":isUserValid,"user-invalid":isUserInvalid,"in-range":isInRange,"out-of-range":isOutOfRange,autofill:isAutofilled,"-webkit-autofill":isAutofilled,"popover-open":matchesPopoverOpen,modal:matchesModal}),za.of=e=>customStatesOf(e.node),clearSelectorCaches();function checkVisibility(e,t){if(!(e.flags&1))return!1;for(let t=e;t!==null;t=inheritanceParent(t))if(isDisplayNone(t))return!1;if(computedValue(e,`display`)===`contents`)return!1;for(let t=inheritanceParent(e);t!==null;t=inheritanceParent(t))if(computedValue(t,`content-visibility`)===`hidden`)return!1;let n=t??{};if(n.checkOpacity||n.opacityProperty)for(let t=e;t!==null;t=inheritanceParent(t)){let e=computedValue(t,`opacity`);if(e!==``&&parseFloat(e)===0)return!1}return!n.checkVisibilityCSS&&!n.visibilityProperty||computedVisibility(e)===`visible`}var ScrollOffsets=class{top;left;constructor(){this.top=0,this.left=0}};const gm=/* @__PURE__ */ new WeakMap;function clamp(e){let t=Number(e);return Number.isFinite(t)&&t>0?t:0}function slot(e){let t=gm.get(e);return t===void 0&&gm.set(e,t=new ScrollOffsets),t}function getScrollTop(e){return Vd&&layoutOn(e.doc)?layoutScroll(e,!0):gm.get(e)?.top??0}function getScrollLeft(e){return Vd&&layoutOn(e.doc)?layoutScroll(e,!1):gm.get(e)?.left??0}function setScrollTop(e,t){Vd&&layoutOn(e.doc)?setLayoutScroll(e,!0,t):slot(e).top=clamp(t)}function setScrollLeft(e,t){Vd&&layoutOn(e.doc)?setLayoutScroll(e,!1,t):slot(e).left=clamp(t)}function scrollElement(e,t,n,r,i){let a,o;if(i>=2)a=Number(n),o=Number(r);else if(typeof n==`object`&&n){let e=n;e.left!==void 0&&(a=Number(e.left)),e.top!==void 0&&(o=Number(e.top))}else if(i===0||n===void 0)return;if(Vd&&layoutOn(e.doc)){let n=boxOf(e);if(n===null)return;let r=layoutScroll(e,!0),i=layoutScroll(e,!1),s=slot(e);s.top=r,s.left=i,a!==void 0&&!Number.isNaN(a)&&(s.left=Math.min(clamp(t?i+a:a),maxScroll(e,n,!1))),o!==void 0&&!Number.isNaN(o)&&(s.top=Math.min(clamp(t?r+o:o),maxScroll(e,n,!0))),(s.top!==r||s.left!==i)&&fireAnEvent(`scroll`,e.node);return}let s=slot(e);a!==void 0&&!Number.isNaN(a)&&(s.left=clamp(t?s.left+a:a)),o!==void 0&&!Number.isNaN(o)&&(s.top=clamp(t?s.top+o:o))}function isBody(e){if(e.tag!==Z.body||e.ns!==`http://www.w3.org/1999/xhtml`)return!1;let t=e.parent;return t!==null&&t.tag===Z.html&&t.parent!==null&&t.parent.type===9}function offsetParent(e){if(!(e.flags&1))return null;let t=e.parent;if(t===null||t.type===9||isBody(e))return null;let n=sheetsApplyTo(e),r=boxFacts(e,n);if(r&1)return null;let i=!(r&2);if(!i&&computedPosition(e)===`fixed`)return null;let a=null;for(let t=inheritanceParent(e);t!==null;t=inheritanceParent(t)){let e=boxFacts(t,n);if(e&1)return null;a===null&&(e&2||isBody(t)||i&&t.ns===`http://www.w3.org/1999/xhtml`&&(t.tag===Z.td||t.tag===Z.th||t.tag===Z.table))&&(a=t)}return a}function scrollSize(e,t,n){if(t.flags&4)return 0;let r=n?clientHeightOf(t,e):clientWidthOf(t,e);return Math.max(r,scrollExtent(e,t,n))}function maxScroll(e,t,n){return Math.max(0,scrollSize(e,t,n)-(n?clientHeightOf(t,e):clientWidthOf(t,e)))}function layoutScroll(e,t){let n=gm.get(e);if(n===void 0)return 0;let r=t?n.top:n.left;if(r===0)return 0;let i=boxOf(e);return i===null?0:Math.min(r,maxScroll(e,i,t))}function setLayoutScroll(e,t,n){let r=boxOf(e);if(r===null)return;let i=Number(n);Number.isFinite(i)||(i=0),i=Math.min(Math.max(0,i),maxScroll(e,r,t));let a=layoutScroll(e,t),o=slot(e);t?o.top=i:o.left=i,i!==a&&fireAnEvent(`scroll`,e.node)}let _m=0,vm=0;function rectOrigin(e,t){let n=t.vx,r=t.vy;if(!(t.flags&16))for(let t=inheritanceParent(e);t!==null;t=inheritanceParent(t)){let e=knownBox(t);if(e!==null&&((e.flags&9)==1&&(n-=layoutScroll(t,!1),r-=layoutScroll(t,!0)),e.flags&16))break}if(!(t.flags&2)){let t=viewport(e);n-=t[Er],r-=t[Dr]}_m=n,vm=r}function boundingClientRect(e){if(!Vd)return new us;let t=boxOf(e);return t===null?new us:(rectOrigin(e,t),new us(_m,vm,t.w,t.h))}function clientRects(e){if(!Vd)return new DOMRectList;let t=boxOf(e);return t===null?new DOMRectList:(rectOrigin(e,t),new DOMRectList([new us(_m,vm,t.w,t.h)]))}const ym={ClientTop:0,ClientLeft:1,ClientWidth:2,ClientHeight:3,ScrollWidth:4,ScrollHeight:5};function elementMetric(e,t){if(!Vd)return 0;let n=boxOf(e);if(n===null)return 0;switch(t){case ym.ClientTop:return n.flags&4?0:Math.round(n.bt);case ym.ClientLeft:return n.flags&4?0:Math.round(n.bl);case ym.ClientWidth:return Math.round(clientWidthOf(n,e));case ym.ClientHeight:return Math.round(clientHeightOf(n,e));case ym.ScrollWidth:return Math.round(scrollSize(e,n,!1));case ym.ScrollHeight:return Math.round(scrollSize(e,n,!0))}return 0}const bm={Top:0,Left:1,Width:2,Height:3};function offsetMetric(e,t){if(!Vd)return 0;let n=boxOf(e);if(n===null)return 0;if(t===bm.Width)return Math.round(n.w);if(t===bm.Height)return Math.round(n.h);let r=offsetParent(e),i=r===null||isBody(r)?null:boxOf(r);return t===bm.Top?Math.round(i===null?n.y:n.y-i.y-i.bt):Math.round(i===null?n.x:n.x-i.x-i.bl)}function scrollElementIntoView(e,t){if(!Vd||boxOf(e)===null)return;let n=`start`,r=`nearest`;if(t===!1)n=`end`;else if(typeof t==`object`&&t){let e=t;e.block!==void 0&&(n=String(e.block)),e.inline!==void 0&&(r=String(e.inline))}for(let t=inheritanceParent(e);t!==null;t=inheritanceParent(t)){let i=boxOf(t);if(i===null||(i.flags&9)!=1)continue;let a=boxOf(e);rectOrigin(e,a);let o=_m,s=vm;rectOrigin(t,i);let c=alignDelta(n,s-vm-i.bt,a.h,clientHeightOf(i,t)),l=alignDelta(r,o-_m-i.bl,a.w,clientWidthOf(i,t));c!==0&&setLayoutScroll(t,!0,layoutScroll(t,!0)+c),l!==0&&setLayoutScroll(t,!1,layoutScroll(t,!1)+l)}}function alignDelta(e,t,n,r){switch(e){case`start`:return t;case`end`:return t+n-r;case`center`:return t+n/2-r/2}let i=t+n;return t<0&&i>r?0:t<0&&n<=r||i>r&&n>r?t:i>r&&n<=r||t<0&&n>r?i-r:0}function installHTMLElementView(e){let t=e.prototype;Object.defineProperty(t,"offsetParent",{get(){let e=offsetParent(this[z]);return e===null?null:e.node},enumerable:!0,configurable:!0});let n=[[`offsetTop`,function offsetTop(){return Vd?offsetMetric(this[z],bm.Top):0}],[`offsetLeft`,function offsetLeft(){return Vd?offsetMetric(this[z],bm.Left):0}],[`offsetWidth`,function offsetWidth(){return Vd?offsetMetric(this[z],bm.Width):0}],[`offsetHeight`,function offsetHeight(){return Vd?offsetMetric(this[z],bm.Height):0}]];for(let[e,r]of n)Object.defineProperty(r,"name",{value:`get ${e}`}),Object.defineProperty(t,e,{get:r,enumerable:!0,configurable:!0})}function installElementView(e){let t=e.prototype,def=(e,n)=>{Object.defineProperty(t,e,{configurable:!0,enumerable:!0,...n})};def(`checkVisibility`,{writable:!0,value:function checkVisibilityMethod(e){return checkVisibility(this[z],e)}}),def(`getBoundingClientRect`,{writable:!0,value:function getBoundingClientRect(){return boundingClientRect(this[z])}}),def(`getClientRects`,{writable:!0,value:function getClientRects(){return clientRects(this[z])}}),def(`scrollIntoView`,{writable:!0,value:function scrollIntoView(e){Vd&&scrollElementIntoView(this[z],e)}});let n=[[`clientTop`,ym.ClientTop],[`clientLeft`,ym.ClientLeft],[`clientWidth`,ym.ClientWidth],[`clientHeight`,ym.ClientHeight],[`scrollWidth`,ym.ScrollWidth],[`scrollHeight`,ym.ScrollHeight]];for(let[e,t]of n){let get=function(){return Vd?elementMetric(this[z],t):0};Object.defineProperty(get,"name",{value:`get ${e}`}),def(e,{get})}def(`scrollTop`,{get(){return getScrollTop(this[z])},set(e){setScrollTop(this[z],e)}}),def(`scrollLeft`,{get(){return getScrollLeft(this[z])},set(e){setScrollLeft(this[z],e)}});for(let[e,t]of[[`scroll`,!1],[`scrollTo`,!1],[`scrollBy`,!0]])def(e,{writable:!0,value:function(e,n){scrollElement(this[z],t,e,n,arguments.length)}})}function escape(e){if(arguments.length===0)throw TypeError(`Failed to execute 'escape' on 'CSS': 1 argument required, but only 0 present.`);let t=String(e),n=t.length,r=t.charCodeAt(0),i=0;for(;i<n;i++){let e=t.charCodeAt(i);if(e>=48&&e<=57&&(i===0||i===1&&r===45)||e===45&&n===1||!(e>=128||e===45||e===95||e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122))break}if(i===n)return t;let a=t.slice(0,i);for(let e=i;e<n;e++){let i=t.charCodeAt(e);a+=i===0?`�`:i>=1&&i<=31||i===127||e===0&&i>=48&&i<=57||e===1&&i>=48&&i<=57&&r===45?`\\`+i.toString(16)+` `:e===0&&i===45&&n===1?`\\-`:i>=128||i===45||i===95||i>=48&&i<=57||i>=65&&i<=90||i>=97&&i<=122?t[e]:`\\`+t[e]}return a}function supports(e,t){if(arguments.length===0)throw TypeError(`Failed to execute 'supports' on 'CSS': 1 argument required, but only 0 present.`);return arguments.length>=2?supportsDeclaration(String(e),String(t)):evaluateSupportsCondition(String(e))}const xm=/* @__PURE__ */ new Set;function registerProperty(e){if(typeof e!=`object`||!e||typeof e.name!=`string`)throw TypeError(`Failed to execute 'registerProperty' on 'CSS': required member name is undefined.`);if(!e.name.startsWith(`--`))throw new DOMException(`Failed to execute 'registerProperty' on 'CSS': Custom property names must start with '--'.`,`SyntaxError`);if(xm.has(e.name))throw new DOMException(`Failed to execute 'registerProperty' on 'CSS': The name provided has already been registered.`,`InvalidModificationError`);xm.add(e.name)}const Sm={escape,supports,registerProperty};Object.defineProperty(Sm,Symbol.toStringTag,{value:`CSS`,writable:!1,enumerable:!1,configurable:!0}),wf.createSheet=createOwnerSheet,wf.removeSheet=removeOwnerSheet,wf.createLinkSheet=createLinkSheet,Ou.getComputedStyle=(e,t)=>getComputedStyle(e,t),Ou.evaluateMediaQuery=(e,t)=>matchMediaText(e,t),Ou.setComputedColorMode=setComputedColorMode,installElementView(Rs),installHTMLElementView(HTMLElement),Object.hasOwn(Q.prototype,`scrollingElement`)||Object.defineProperty(Q.prototype,"scrollingElement",{get(){return this.compatMode===`BackCompat`?this.body:this.documentElement},enumerable:!0,configurable:!0});for(let e of[Q,ShadowRoot]){let t=e.prototype;Object.hasOwn(t,`styleSheets`)||Object.defineProperty(t,"styleSheets",{get(){return styleSheetsOf(this[z])},enumerable:!0,configurable:!0}),Object.hasOwn(t,`adoptedStyleSheets`)||Object.defineProperty(t,"adoptedStyleSheets",{get(){return adoptedStyleSheetsOf(this[z])},set(e){setAdoptedStyleSheets(this[z],e)},enumerable:!0,configurable:!0})}registerDomNamespace(/* @__PURE__ */ __exportAll({AbstractRange:()=>AbstractRange,AnimationEvent:()=>AnimationEvent,Attr:()=>Attr,Audio:()=>vf,BeforeUnloadEvent:()=>BeforeUnloadEvent,CDATASection:()=>CDATASection,CSS:()=>Sm,CSSConditionRule:()=>CSSConditionRule,CSSContainerRule:()=>CSSContainerRule,CSSFontFaceRule:()=>CSSFontFaceRule,CSSGroupingRule:()=>CSSGroupingRule,CSSImportRule:()=>CSSImportRule,CSSKeyframeRule:()=>CSSKeyframeRule,CSSKeyframesRule:()=>CSSKeyframesRule,CSSLayerBlockRule:()=>CSSLayerBlockRule,CSSLayerStatementRule:()=>CSSLayerStatementRule,CSSMediaRule:()=>CSSMediaRule,CSSNamespaceRule:()=>CSSNamespaceRule,CSSNestedDeclarations:()=>CSSNestedDeclarations,CSSPageRule:()=>CSSPageRule,CSSPropertyRule:()=>CSSPropertyRule,CSSRule:()=>Eu,CSSRuleList:()=>CSSRuleList,CSSScopeRule:()=>CSSScopeRule,CSSStartingStyleRule:()=>CSSStartingStyleRule,CSSStyleDeclaration:()=>CSSStyleDeclaration,CSSStyleRule:()=>Du,CSSStyleSheet:()=>Tu,CSSSupportsRule:()=>CSSSupportsRule,CharacterData:()=>CharacterData,Clipboard:()=>Clipboard,ClipboardEvent:()=>ClipboardEvent,ClipboardItem:()=>ClipboardItem,CloseEvent:()=>CloseEvent,CommandEvent:()=>CommandEvent,Comment:()=>Comment,CompositionEvent:()=>CompositionEvent,CustomElementRegistry:()=>CustomElementRegistry,CustomEvent:()=>CustomEvent,CustomStateSet:()=>CustomStateSet,DOMImplementation:()=>DOMImplementation,DOMMatrix:()=>Is,DOMMatrixReadOnly:()=>DOMMatrixReadOnly,DOMParser:()=>DOMParser,DOMPoint:()=>ls,DOMPointReadOnly:()=>DOMPointReadOnly,DOMQuad:()=>dm,DOMRect:()=>us,DOMRectList:()=>DOMRectList,DOMRectReadOnly:()=>DOMRectReadOnly,DOMStringMap:()=>DOMStringMap,DOMTokenList:()=>Qo,DataTransfer:()=>DataTransfer,DataTransferItem:()=>DataTransferItem,DataTransferItemList:()=>DataTransferItemList,Document:()=>Q,DocumentFragment:()=>DocumentFragment,DocumentType:()=>DocumentType,DragEvent:()=>DragEvent,Element:()=>Rs,ElementInternals:()=>ElementInternals,ErrorEvent:()=>ErrorEvent,Event:()=>Event,EventTarget:()=>EventTarget,FileList:()=>FileList,FileReader:()=>FileReader,FocusEvent:()=>FocusEvent,FormData:()=>FormData$1,FormDataEvent:()=>FormDataEvent,HTMLAnchorElement:()=>HTMLAnchorElement,HTMLAreaElement:()=>HTMLAreaElement,HTMLAudioElement:()=>HTMLAudioElement,HTMLBRElement:()=>HTMLBRElement,HTMLBaseElement:()=>HTMLBaseElement,HTMLBodyElement:()=>HTMLBodyElement,HTMLButtonElement:()=>HTMLButtonElement,HTMLCanvasElement:()=>HTMLCanvasElement,HTMLCollection:()=>io,HTMLDListElement:()=>HTMLDListElement,HTMLDataElement:()=>HTMLDataElement,HTMLDataListElement:()=>HTMLDataListElement,HTMLDetailsElement:()=>HTMLDetailsElement,HTMLDialogElement:()=>HTMLDialogElement,HTMLDirectoryElement:()=>HTMLDirectoryElement,HTMLDivElement:()=>HTMLDivElement,HTMLDocument:()=>Q,HTMLElement:()=>HTMLElement,HTMLEmbedElement:()=>HTMLEmbedElement,HTMLFieldSetElement:()=>HTMLFieldSetElement,HTMLFontElement:()=>HTMLFontElement,HTMLFormControlsCollection:()=>HTMLFormControlsCollection,HTMLFormElement:()=>HTMLFormElement,HTMLFrameElement:()=>HTMLFrameElement,HTMLFrameSetElement:()=>HTMLFrameSetElement,HTMLHRElement:()=>HTMLHRElement,HTMLHeadElement:()=>HTMLHeadElement,HTMLHeadingElement:()=>HTMLHeadingElement,HTMLHtmlElement:()=>HTMLHtmlElement,HTMLIFrameElement:()=>HTMLIFrameElement,HTMLImageElement:()=>HTMLImageElement,HTMLInputElement:()=>HTMLInputElement,HTMLLIElement:()=>HTMLLIElement,HTMLLabelElement:()=>HTMLLabelElement,HTMLLegendElement:()=>HTMLLegendElement,HTMLLinkElement:()=>HTMLLinkElement,HTMLMapElement:()=>HTMLMapElement,HTMLMarqueeElement:()=>HTMLMarqueeElement,HTMLMediaElement:()=>HTMLMediaElement,HTMLMenuElement:()=>HTMLMenuElement,HTMLMetaElement:()=>HTMLMetaElement,HTMLMeterElement:()=>HTMLMeterElement,HTMLModElement:()=>HTMLModElement,HTMLOListElement:()=>HTMLOListElement,HTMLObjectElement:()=>HTMLObjectElement,HTMLOptGroupElement:()=>HTMLOptGroupElement,HTMLOptionElement:()=>HTMLOptionElement,HTMLOptionsCollection:()=>HTMLOptionsCollection,HTMLOutputElement:()=>HTMLOutputElement,HTMLParagraphElement:()=>HTMLParagraphElement,HTMLParamElement:()=>HTMLParamElement,HTMLPictureElement:()=>HTMLPictureElement,HTMLPreElement:()=>HTMLPreElement,HTMLProgressElement:()=>HTMLProgressElement,HTMLQuoteElement:()=>HTMLQuoteElement,HTMLScriptElement:()=>HTMLScriptElement,HTMLSelectElement:()=>HTMLSelectElement,HTMLSlotElement:()=>HTMLSlotElement,HTMLSourceElement:()=>HTMLSourceElement,HTMLSpanElement:()=>HTMLSpanElement,HTMLStyleElement:()=>HTMLStyleElement,HTMLTableCaptionElement:()=>HTMLTableCaptionElement,HTMLTableCellElement:()=>HTMLTableCellElement,HTMLTableColElement:()=>HTMLTableColElement,HTMLTableElement:()=>HTMLTableElement,HTMLTableRowElement:()=>HTMLTableRowElement,HTMLTableSectionElement:()=>HTMLTableSectionElement,HTMLTemplateElement:()=>HTMLTemplateElement,HTMLTextAreaElement:()=>HTMLTextAreaElement,HTMLTimeElement:()=>HTMLTimeElement,HTMLTitleElement:()=>HTMLTitleElement,HTMLTrackElement:()=>HTMLTrackElement,HTMLUListElement:()=>HTMLUListElement,HTMLUnknownElement:()=>HTMLUnknownElement,HTMLVideoElement:()=>HTMLVideoElement,HashChangeEvent:()=>HashChangeEvent,History:()=>History,Image:()=>uf,InputEvent:()=>InputEvent,IntersectionObserver:()=>IntersectionObserver,IntersectionObserverEntry:()=>IntersectionObserverEntry,KeyboardEvent:()=>KeyboardEvent,Location:()=>Location,MathMLElement:()=>MathMLElement,MediaError:()=>MediaError,MediaList:()=>MediaList,MediaQueryList:()=>MediaQueryList,MediaQueryListEvent:()=>MediaQueryListEvent,MessageEvent:()=>MessageEvent,MouseEvent:()=>MouseEvent,MutationObserver:()=>MutationObserver,MutationRecord:()=>sa,NamedNodeMap:()=>is,Navigator:()=>Navigator,Node:()=>Node,NodeFilter:()=>bd,NodeIterator:()=>NodeIterator,NodeList:()=>aa,Option:()=>Zf,PageTransitionEvent:()=>PageTransitionEvent,PointerEvent:()=>PointerEvent,PopStateEvent:()=>PopStateEvent,ProcessingInstruction:()=>ProcessingInstruction,ProgressEvent:()=>ProgressEvent,PromiseRejectionEvent:()=>PromiseRejectionEvent,RadioNodeList:()=>RadioNodeList,Range:()=>yd,ResizeObserver:()=>ResizeObserver,ResizeObserverEntry:()=>ResizeObserverEntry,ResizeObserverSize:()=>ResizeObserverSize,SVGAElement:()=>SVGAElement,SVGAnimatedPreserveAspectRatio:()=>SVGAnimatedPreserveAspectRatio,SVGAnimatedRect:()=>SVGAnimatedRect,SVGAnimatedString:()=>SVGAnimatedString,SVGCircleElement:()=>SVGCircleElement,SVGClipPathElement:()=>SVGClipPathElement,SVGDefsElement:()=>SVGDefsElement,SVGDescElement:()=>SVGDescElement,SVGElement:()=>SVGElement,SVGEllipseElement:()=>SVGEllipseElement,SVGFilterElement:()=>SVGFilterElement,SVGForeignObjectElement:()=>SVGForeignObjectElement,SVGGElement:()=>SVGGElement,SVGGeometryElement:()=>SVGGeometryElement,SVGGradientElement:()=>SVGGradientElement,SVGGraphicsElement:()=>SVGGraphicsElement,SVGImageElement:()=>SVGImageElement,SVGLineElement:()=>SVGLineElement,SVGLinearGradientElement:()=>SVGLinearGradientElement,SVGMarkerElement:()=>SVGMarkerElement,SVGMaskElement:()=>SVGMaskElement,SVGMetadataElement:()=>SVGMetadataElement,SVGNumber:()=>SVGNumber,SVGPathElement:()=>SVGPathElement,SVGPatternElement:()=>SVGPatternElement,SVGPolygonElement:()=>SVGPolygonElement,SVGPolylineElement:()=>SVGPolylineElement,SVGPreserveAspectRatio:()=>SVGPreserveAspectRatio,SVGRadialGradientElement:()=>SVGRadialGradientElement,SVGRect:()=>us,SVGRectElement:()=>SVGRectElement,SVGSVGElement:()=>SVGSVGElement,SVGScriptElement:()=>SVGScriptElement,SVGStopElement:()=>SVGStopElement,SVGStyleElement:()=>SVGStyleElement,SVGSwitchElement:()=>SVGSwitchElement,SVGSymbolElement:()=>SVGSymbolElement,SVGTSpanElement:()=>SVGTSpanElement,SVGTextContentElement:()=>SVGTextContentElement,SVGTextElement:()=>SVGTextElement,SVGTextPathElement:()=>SVGTextPathElement,SVGTextPositioningElement:()=>SVGTextPositioningElement,SVGTitleElement:()=>SVGTitleElement,SVGUseElement:()=>SVGUseElement,SVGViewElement:()=>SVGViewElement,Screen:()=>Screen,Selection:()=>Selection,ShadowRoot:()=>ShadowRoot,StaticRange:()=>StaticRange,Storage:()=>Storage,StorageEvent:()=>StorageEvent,StyleSheet:()=>StyleSheet,StyleSheetList:()=>StyleSheetList,SubmitEvent:()=>SubmitEvent,Text:()=>Text,TextEvent:()=>TextEvent,TimeRanges:()=>TimeRanges,ToggleEvent:()=>ToggleEvent,Touch:()=>Touch,TouchEvent:()=>TouchEvent,TouchList:()=>zi,TransitionEvent:()=>TransitionEvent,TreeWalker:()=>TreeWalker,UIEvent:()=>UIEvent,ValidityState:()=>ValidityState,VisualViewport:()=>VisualViewport,WebKitCSSMatrix:()=>Is,WheelEvent:()=>WheelEvent,Window:()=>Window,XMLDocument:()=>XMLDocument,XMLHttpRequest:()=>XMLHttpRequest,XMLHttpRequestEventTarget:()=>vp,XMLHttpRequestUpload:()=>XMLHttpRequestUpload,XMLSerializer:()=>XMLSerializer,createWindow:()=>createWindow,currentDocument:()=>currentDocument,currentWindow:()=>currentWindow,currentWindowOrNull:()=>currentWindowOrNull,getComputedStyle:()=>getComputedStyle,installGlobals:()=>installGlobals,setCurrentWindow:()=>setCurrentWindow}));export{HTMLOptGroupElement as $,io as $a,kt as $c,gi as $d,Ce as $f,fu as $i,kn as $l,HTMLTableSectionElement as $n,isInclusiveAncestor as $o,hasAuthorStyles as $r,tagId as $s,HTMLLinkElement as $t,br as $u,ResizeObserverSize as A,us as Aa,ct as Ac,Xr as Ad,o as Af,CSSScopeRule as Ai,cn as Al,HTMLHtmlElement as An,formOwner as Ao,Selection as Ar,PageTransitionEvent as As,SVGPatternElement as At,Lr as Au,unsharedDefineProperty as B,DOMStringMap as Ba,_t as Bc,q as Bd,ie as Bf,createOwnerSheet as Bi,vn as Bl,HTMLObjectElement as Bn,inputTypeFromAttr as Bo,constructEntryList as Br,DragEvent as Bs,SVGSymbolElement as Bt,sr as Bu,optionSelected as C,getElementsByClassName as Ca,tt as Cc,Ur as Cd,T as Cf,CSSMediaRule as Ci,Xt as Cl,HTMLEmbedElement as Cn,getAttribute as Co,Location as Cr,BeforeUnloadEvent as Cs,SVGImageElement as Ct,Yn as Cu,DataTransferItemList as D,DOMMatrixReadOnly as Da,at as Dc,qr as Dd,ee as Df,CSSPropertyRule as Di,L as Dl,HTMLHRElement as Dn,removeAttribute as Do,Q as Dr,FormDataEvent as Ds,SVGMaskElement as Dt,$n as Du,DataTransferItem as E,Is as Ea,it as Ec,Kr as Ed,C as Ef,CSSPageRule as Ei,$t as El,HTMLFrameSetElement as En,prefixFlag as Eo,DOMImplementation as Er,ErrorEvent as Es,SVGMarkerElement as Et,Qn as Eu,XMLHttpRequest as F,isValidNamespacePrefix as Fa,pt as Fc,ti as Fd,ae as Ff,MediaList as Fi,pn as Fl,HTMLMarqueeElement as Fn,isSubmittable as Fo,yd as Fr,SubmitEvent as Fs,SVGSVGElement as Ft,H as Fu,HTMLMeterElement as G,parseFragment as Ga,bt as Gc,J as Gd,xe as Gf,unregisterOwnerSheet as Gi,Sn as Gl,HTMLQuoteElement as Gn,notifyMutationObservers as Go,isEditable as Gr,PointerEvent as Gs,SVGTextPositioningElement as Gt,fr as Gu,ip as H,ShadowRoot as Ha,yt as Hc,si as Hd,le as Hf,removeOwnerSheet as Hi,bn as Hl,HTMLParamElement as Hn,isTextualType as Ho,implicitSubmission as Hr,InputEvent as Hs,SVGTextContentElement as Ht,lr as Hu,vp as I,validateAndExtract as Ia,St as Ic,ni as Id,fe as If,StyleSheet as Ii,mn as Il,HTMLMenuElement as In,labeledControl as Io,StaticRange as Ir,ToggleEvent as Is,SVGScriptElement as It,rr as Iu,HTMLFieldSetElement as J,CDATASection as Ja,wt as Jc,fi as Jd,re as Jf,NodeCache as Ji,Tn as Jl,HTMLTableCaptionElement as Jn,ensureIndexGetters as Jo,getComputedStyle as Jr,TouchEvent as Js,SVGViewElement as Jt,hr as Ju,HTMLOutputElement as K,DocumentType as Ka,xt as Kc,ui as Kd,de as Kf,matchMediaText as Ki,Cn as Kl,HTMLSourceElement as Kn,sa as Ko,styleElementRemoved as Kr,TextEvent as Ks,SVGTitleElement as Kt,pr as Ku,XMLHttpRequestUpload as L,is as La,mt as Lc,ri as Ld,oe as Lf,StyleSheetList as Li,hn as Ll,HTMLMetaElement as Ln,labelsFor as Lo,compareBoundaryPoints as Lr,TransitionEvent as Ls,SVGStopElement as Lt,ir as Lu,IntersectionObserverEntry as M,DOMRectReadOnly as Ma,ut as Mc,Qr as Md,u as Mf,Du as Mi,un as Ml,HTMLImageElement as Mn,isLabelable as Mo,NodeIterator as Mr,ProgressEvent as Ms,SVGPolylineElement as Mt,er as Mu,ResizeObserver as N,isValidDoctypeName as Na,dt as Nc,$r as Nd,me as Nf,Tu as Ni,dn as Nl,HTMLLIElement as Nn,isListed as No,TreeWalker as Nr,PromiseRejectionEvent as Ns,SVGRadialGradientElement as Nt,tr as Nu,dm as O,ls as Oa,ot as Oc,Jr as Od,S as Of,Eu as Oi,ln as Ol,HTMLHeadElement as On,setAttribute as Oo,XMLDocument as Or,HashChangeEvent as Os,SVGMetadataElement as Ot,V as Ou,FileReader as P,isValidElementLocalName as Pa,ft as Pc,ei as Pd,ge as Pf,CSSSupportsRule as Pi,fn as Pl,HTMLMapElement as Pn,isResettable as Po,AbstractRange as Pr,StorageEvent as Ps,SVGRectElement as Pt,nr as Pu,HTMLSelectElement as Q,Text as Qa,Ot as Qc,hi as Qd,Ee as Qf,fireSyntheticPointerEvent as Qi,On as Ql,HTMLTableRowElement as Qn,indexOf as Qo,currentStyleVersion as Qr,Z as Qs,SVGPreserveAspectRatio as Qt,yr as Qu,installGlobals as R,attrNode as Ra,ht as Rc,ii as Rd,ue as Rf,adoptedStyleSheetsOf as Ri,gn as Rl,HTMLModElement as Rn,xa as Ro,nodeLength as Rr,ClipboardEvent as Rs,SVGStyleElement as Rt,ar as Ru,isValid as S,attachShadowRoot as Sa,M as Sc,K as Sd,_ as Sf,CSSLayerStatementRule as Si,Yt as Sl,HTMLDivElement as Sn,classTokens as So,History as Sr,AnimationEvent as Ss,SVGGraphicsElement as St,sn as Su,DataTransfer as T,getElementsByTagNameNS as Ta,rt as Tc,Gr as Td,x as Tf,CSSNestedDeclarations as Ti,Qt as Tl,HTMLFrameElement as Tn,isAsciiWhitespace as To,XMLSerializer as Tr,CustomEvent as Ts,SVGLinearGradientElement as Tt,Zn as Tu,HTMLFormElement as U,serializeChildren as Ua,N as Uc,ci as Ud,_e as Uf,setAdoptedStyleSheets as Ui,R as Ul,HTMLPictureElement as Un,supportsSelectionType as Uo,isSubmitButton as Ur,KeyboardEvent as Us,SVGTextElement as Ut,ur as Uu,FormData$1 as V,Qo as Va,vt as Vc,oi as Vd,ye as Vf,registerOwnerSheet as Vi,yn as Vl,HTMLParagraphElement as Vn,isNumericType as Vo,defaultButton as Vr,FocusEvent as Vs,SVGTSpanElement as Vt,cr as Vu,HTMLDataListElement as W,serializeNode as Wa,rn as Wc,li as Wd,he as Wf,styleSheetsOf as Wi,xn as Wl,HTMLPreElement as Wn,valueMode as Wo,setNotImplementedHandler as Wr,MouseEvent as Ws,SVGTextPathElement as Wt,dr as Wu,HTMLLabelElement as X,Comment as Xa,Et as Xc,mi as Xd,pe as Xf,dispatchTrusted as Xi,En as Xl,HTMLTableColElement as Xn,childAt as Xo,computedValue as Xr,UIEvent as Xs,SVGAnimatedRect as Xt,_r as Xu,HTMLLegendElement as Y,CharacterData as Ya,Tt as Yc,pi as Yd,be as Yf,nodeCache as Yi,z as Yl,HTMLTableCellElement as Yn,indexGetterTable as Yo,computedDisplay as Yr,zi as Ys,SVGAnimatedPreserveAspectRatio as Yt,gr as Yu,HTMLButtonElement as Z,ProcessingInstruction as Za,Dt as Zc,Y as Zd,De as Zf,fireAnEvent as Zi,Dn as Zl,HTMLTableElement as Zn,firstElementChild as Zo,computedVisibility as Zr,WheelEvent as Zs,SVGNumber as Zt,vr as Zu,isPlaceholderShown as _,CustomElementRegistry as _a,Xe as _c,G as _d,virtualPerformance as _f,CSSGroupingRule as _i,Gt as _l,HTMLBodyElement as _n,findFlattenedSlottables as _o,Screen as _r,setUncaughtExceptionHandler as _s,SVGFilterElement as _t,Gn as _u,inputIndeterminate as a,resolveCompat as aa,Si as ac,wr as ad,canSkipZeroDelayWait as af,pseudoContent as ai,Ft as al,HTMLDetailsElement as an,querySelector as ao,E as ap,CustomStateSet as ar,previousElementSibling as as,sanitizeValue as at,Pn as au,isRequired as b,setEventHandler as ba,$e as bc,Vr as bd,h as bf,CSSKeyframesRule as bi,qt as bl,HTMLDataElement as bn,asciiLowercase$1 as bo,ClipboardItem as br,currentWindowOrNull as bs,SVGGeometryElement as bt,Jn as bu,isDefault as c,parseDeclBlock as ca,EventState as cc,Dr as cd,clockSkipped as cf,uaDisplay as ci,Lt as cl,HTMLAudioElement as cn,peekDerivedCache as co,m as cp,attrAssociatedElement as cr,AttrRecord as cs,MathMLElement as ct,nn as cu,isInRange as d,ValidityState as da,We as dc,Ar as dd,installClock as df,mediaEnvironment as di,Bt as dl,MediaError as dn,replaceData as do,O as dp,Window as dr,dispatch as ds,SVGCircleElement as dt,Bn as du,iu as ea,tagName as ec,xr as ed,_i as ef,isDisplayNone as ei,At as el,HTMLScriptElement as en,ensureCollectionIndexGetters as eo,we as ep,HTMLTimeElement as er,lastElementChild as es,HTMLOptionElement as et,An as eu,isIndeterminate as f,HTMLFormControlsCollection as fa,Ge as fc,Rr as fd,isClockTimer as ff,MediaQueryListEvent as fi,Ht as fl,TimeRanges as fn,splitText as fo,ne as fp,createWindow as fr,getCurrentEvent as fs,SVGClipPathElement as ft,zn as fu,isOutOfRange as g,normalizeNewlines as ga,Ye as gc,Pr as gd,virtualDate as gf,CSSFontFaceRule as gi,F as gl,HTMLBaseElement as gn,assignedSlot as go,Storage as gr,reportException$1 as gs,SVGEllipseElement as gt,Wn as gu,isOptional as h,listOfOptions as ha,Je as hc,Nr as hd,skipZeroDelayWait as hf,CSSContainerRule as hi,Wt as hl,HTMLBRElement as hn,assignedNodes as ho,trackGlobalTimers as hr,setAssignedSlotLookup as hs,SVGElement as ht,Un as hu,inputChecked as i,hiddenGlobals as ia,reusableElement as ic,W as id,VirtualTimeout as if,pointerEventsNone as ii,Pt as il,HTMLTemplateElement as in,matches as io,ve as ip,uf as ir,nextSkippingChildren as is,HTMLInputElement as it,B as iu,IntersectionObserver as j,DOMRectList as ja,lt as jc,Zr as jd,d as jf,CSSStartingStyleRule as ji,tn as jl,HTMLIFrameElement as jn,isActuallyDisabled as jo,bd as jr,PopStateEvent as js,SVGPolygonElement as jt,Fr as ju,ResizeObserverEntry as k,DOMPointReadOnly as ka,st as kc,Yr as kd,v as kf,CSSRuleList as ki,en as kl,HTMLHeadingElement as kn,splitOnAsciiWhitespace as ko,createEvent as kr,MessageEvent as ks,SVGPathElement as kt,Ir as ku,isDisabled as l,faceState as la,setTrusted as lc,Or as ld,clockStats as lf,MediaQueryList as li,Rt as ll,HTMLMediaElement as ln,Node as lo,D as lp,attrAssociatedElements as lr,NodeImpl as ls,SVGAElement as lt,Ln as lu,isMutable as m,RadioNodeList as ma,qe as mc,Mr as md,skipIdleTime as mf,CSSConditionRule as mi,P as ml,HTMLAreaElement as mn,assignedElements as mo,__name as mp,clearTimers as mr,retarget as ms,SVGDescElement as mt,Hn as mu,controlValue as n,compatExposes as na,listenerCount as nc,Sr as nd,yi as nf,isVisibilityHidden as ni,Mt as nl,HTMLTitleElement as nn,closest as no,Se as np,HTMLUListElement as nr,nextElementSibling as ns,optionSelect as nt,Mn as nu,isAutofilled as o,CSSStyleDeclaration as oa,Ci as oc,Tr as od,clearActiveClockTimers as of,setComputedColorMode as oi,It as ol,HTMLDialogElement as on,querySelectorAll as oo,te as op,ElementInternals as or,previousInTree as os,FileList as ot,Fn as ou,isInvalid as p,HTMLOptionsCollection as pa,Ke as pc,jr as pd,loopTurn as pf,Ou as pi,Ut as pl,HTMLAnchorElement as pn,assignManually as po,k as pp,windowInterfaces as pr,nodeGetTheParent as ps,SVGDefsElement as pt,Vn as pu,HTMLProgressElement as q,DocumentFragment as qa,Ct as qc,di as qd,ce as qf,parseMediaQueryList as qi,wn as ql,HTMLSpanElement as qn,aa as qo,styleElementUpdated as qr,Touch as qs,SVGUseElement as qt,mr as qu,hasReadonlyAttribute as r,deferredCompatMembers as ra,removeAllEventListeners as rc,Cr as rd,VirtualClock as rf,pointerEvents as ri,Nt as rl,HTMLSlotElement as rn,indexedDescendantById as ro,se as rp,HTMLUnknownElement as rr,nextInTree as rs,HTMLTextAreaElement as rt,Nn as ru,isChecked as s,DeclBlock as sa,Event as sc,Er as sd,clockNow as sf,styledDisplay as si,Vt as sl,vf as sn,derivedCache as so,b as sp,HTMLElement as sr,treeRoot as ss,createFileList as st,In as su,Sm as t,au as ta,hasListeners as tc,U as td,vi as tf,isDisplayNoneInclusive as ti,jt as tl,HTMLStyleElement as tn,withNamedProperties as to,Te as tp,HTMLTrackElement as tr,nextElementInTree as ts,Zf as tt,jn as tu,isEnabled as u,isFACE as ua,Ue as uc,kr as ud,foreignImmediatesPending as uf,evaluateMediaQueryList as ui,zt as ul,HTMLVideoElement as un,inspectNode as uo,c as up,hasExplicitAttrElements as ur,EventTarget as us,SVGAnimatedString as ut,Rn as uu,isReadOnly as v,getEventHandler as va,Ze as vc,zr as vd,s as vf,CSSImportRule as vi,Kt as vl,HTMLCanvasElement as vn,findSlot as vo,VisualViewport as vr,currentDocument as vs,SVGForeignObjectElement as vt,Kn as vu,MutationObserver as w,getElementsByTagName as wa,nt as wc,Wr as wd,w as wf,CSSNamespaceRule as wi,Zt as wl,HTMLFontElement as wn,hasAttr as wo,DOMParser as wr,CloseEvent as ws,SVGLineElement as wt,Xn as wu,isTextControl as x,Rs as xa,et as xc,Hr as xd,y as xf,CSSLayerBlockRule as xi,Jt as xl,HTMLDirectoryElement as xn,attr as xo,Navigator as xr,setCurrentWindow as xs,SVGGradientElement as xt,an as xu,isReadWrite as y,installEventHandlers as ya,Qe as yc,Br as yd,l as yf,CSSKeyframeRule as yi,I as yl,HTMLDListElement as yn,ariaAttr as yo,Clipboard as yr,currentWindow as ys,SVGGElement as yt,qn as yu,sharedAccessor as z,Attr as za,gt as zc,ai as zd,A as zf,createLinkSheet as zi,_n as zl,HTMLOListElement as zn,inputType as zo,CommandEvent as zr,CompositionEvent as zs,SVGSwitchElement as zt,or as zu};