@stacksjs/ts-css 0.3.28 → 0.3.29

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.
package/dist/bin/cssx.js CHANGED
@@ -88,7 +88,7 @@ Received ${r}, cleaning up...`),e)try{await e()}catch(n){console.error("Error du
88
88
  `)),this.enableDidYouMean){let t=[];for(let n of this.commands){if(n.displayName)t.push(n.displayName);if(n.aliasNames)t.push(...n.aliasNames)}let r=Ki(e,t);if(r.length>0)console.log(vt.yellow("Did you mean one of these?")),r.forEach((n)=>console.log(` ${vt.dim("\u2022")} ${this.name} ${n}`)),console.log("")}console.log(vt.dim("Run"),`${this.name} --help`,vt.dim("to see all available commands")),Ie.exit(1)}async parse(e=Vi,t={}){let{run:r=!0,exitOnError:n=!1}=t;if(n)try{return await this.parse(e,{run:r})}catch(a){throw this.handleUsageError(a),a}if(this.rawArgs=e,!this.name)this.name=e[1]?Lc(e[1]):"cli";let i=!0,o=e.slice(2),s=o[0];if(s&&!s.startsWith("-")){for(let a of this.commands)if(a.isMatched(s)){let c=this.mri(o,a);i=!1;let u={...c,args:c.args.slice(1)};this.setParsedInfo(u,a,s),this.emit(`command:${s}`,a);break}if(i){let a=o[1];if(a&&!a.startsWith("-")){let c=`${s}:${a}`;for(let u of this.commands)if(u.isMatched(c)){let f=this.mri(o,u);i=!1;let d={...f,args:f.args.slice(2)};this.setParsedInfo(d,u,c),this.emit(`command:${c}`,u);break}}}}if(i){for(let a of this.commands)if(a.name===""){i=!1;let c=this.mri(o,a);this.setParsedInfo(c,a),this.emit("command:!",a);break}}if(i){let a=this.mri(e.slice(2));this.setParsedInfo(a)}if(this.options.verbose)this.isVerbose=!0;if(this.options.quiet)this.isQuiet=!0;if(this.options.debug)this.isDebug=!0;if(this.options.noInteraction||this.options.interaction===!1)this.isNoInteraction=!0;if(this.options.env)this.environment=String(this.options.env);if(this.options.dryRun)this.isDryRun=!0;if(this.options.force)this.isForce=!0;if(this.options.noEmoji||this.options.emoji===!1)this.useEmoji=!1;if(this.options.theme)this.theme=String(this.options.theme);if(this.options.noCache||this.options.cache===!1)this.isNoCache=!0;if(this.options.help&&this.showHelpOnExit)this.outputHelp(),r=!1,this.unsetMatchedCommand();if(this.options.version&&this.showVersionOnExit&&this.matchedCommandName==null)this.outputVersion(),r=!1,this.unsetMatchedCommand();let l={args:this.args,options:this.options};if(r)await this.runMatchedCommand();if(!this.matchedCommand&&this.args[0]){if(this.emit("command:*"),!(this.listenerCount("command:*")>0))this.showCommandNotFound(this.args[0])}return l}mri(e,t){let r=[...this.globalCommand.options,...t?t.options:[]],n=Ic(r),i=[],o=e.indexOf("--");if(o>-1)i=e.slice(o+1),e=e.slice(0,o);let s=Dc(e,n),l={_:s._};for(let d of Object.keys(s))if(d!=="_")l[$t(d)]=s[d];let a=l._,c={"--":i},u=t&&t.config.ignoreOptionDefaultValue?t.config.ignoreOptionDefaultValue:this.globalCommand.config.ignoreOptionDefaultValue,f=Object.create(null);for(let d of r){if(!u&&d.config.default!==void 0)for(let h of d.names)c[h]=d.config.default;if(Array.isArray(d.config.type)){if(f[d.name]===void 0)f[d.name]={shouldTransform:!0,transformFunction:d.config.type[0]}}}for(let d of Object.keys(l))if(d!=="_"){let h=d.split(".");Pc(c,h,l[d]),_c(c,f)}for(let d of r){if(!d.variadic)continue;for(let h of d.names){let g=c[h];if(g===void 0||Array.isArray(g))continue;if(d.config.default!==void 0&&g===d.config.default)continue;c[h]=[g]}}return{args:a,options:c}}async run(e=Vi){return this.parse(e,{run:!0,exitOnError:!0})}handleUsageError(e){if(!Mc(e)||e.isUsageError===!1)return;let t=e.message||"command-line error",r=this.name?`${this.name}: `:"",n=/--help/.test(t)?"":e.usage?`
89
89
  Usage: ${e.usage}`:`
90
90
  Run \`${this.name??"cli"} --help\` for usage.`;Ie.stderr.write(`${r}${t}${n}
91
- `),Ie.exit(e.exitCode??2)}async runMatchedCommand(){let{args:e,options:t,matchedCommand:r}=this;if(!r||!r.commandAction)return;r.checkUnknownOptions(),r.checkOptionValue(),r.checkRequiredArgs();let n=[];r.args.forEach((l,a)=>{if(l.variadic)n.push(e.slice(a));else n.push(e[a])}),n.push(t);let i={command:r,args:n,options:t};for(let l of r.beforeHooks)await l(i);let o,s=async()=>{let l=r.commandAction.apply(this,n);if(l instanceof Promise)o=await l;else o=l;return o};if(r.middleware.length>0){let l=0,a=async()=>{if(l<r.middleware.length){let c=r.middleware[l++];await c({...i,next:a})}else await s()};await a()}else await s();for(let l of r.afterHooks)await l(i);return o}removeSignalHandlers(){if(!this.signalHandlersSet)return this;return Ie.removeAllListeners("SIGINT"),Ie.removeAllListeners("SIGTERM"),this.signalHandlersSet=!1,this}destroy(){this.removeSignalHandlers(),this.commands=[],this.rawArgs=[],this.args=[],this.options={},this.matchedCommand=void 0,this.matchedCommandName=void 0,this.removeAllListeners()}}class Hi{cache;enabled;cleanupInterval=null;hits=0;misses=0;constructor(){this.cache=new Map,this.enabled=!0,this.startCleanupInterval()}startCleanupInterval(){if(this.cleanupInterval)return;this.cleanupInterval=setInterval(()=>{this.cleanup()},30000),this.cleanupInterval.unref()}stopCleanup(){if(this.cleanupInterval)clearInterval(this.cleanupInterval),this.cleanupInterval=null}isEnabled(){return this.enabled}get(e){if(!this.enabled){this.misses++;return}let t=this.cache.get(e);if(!t){this.misses++;return}if(Date.now()-t.timestamp>t.ttl){this.cache.delete(e),this.misses++;return}return this.hits++,t.value}set(e,t,r=5000){if(!this.enabled)return;this.cache.set(e,{value:t,timestamp:Date.now(),ttl:r})}has(e){if(!this.enabled)return!1;let t=this.cache.get(e);if(!t)return!1;if(Date.now()-t.timestamp>t.ttl)return this.cache.delete(e),!1;return!0}delete(e){this.cache.delete(e)}clear(){this.cache.clear()}disable(){this.enabled=!1,this.clear()}enable(){this.enabled=!0}stats(){return{size:this.cache.size,enabled:this.enabled,hits:this.hits,misses:this.misses}}resetStats(){this.hits=0,this.misses=0}keys(){return Array.from(this.cache.keys())}cleanup(){let e=Date.now();for(let[t,r]of this.cache.entries())if(e-r.timestamp>r.ttl)this.cache.delete(t)}destroy(){this.stopCleanup(),this.clear(),this.resetStats()}}var Kx=new Hi;function Kc(){if("FORCE_COLOR"in wt.env)return wt.env.FORCE_COLOR!=="0";if("NO_COLOR"in wt.env||wt.env.TERM==="dumb")return!1;if(wt.platform==="win32")return!0;return Wi.isatty(1)&&Wi.isatty(2)}var qi=Kc();function M(e,t){if(!qi)return(r)=>r;return(r)=>e+r+t}var Gc=M("\x1B[0m","\x1B[0m"),Hc=M("\x1B[31m","\x1B[39m"),qc=M("\x1B[32m","\x1B[39m"),Yc=M("\x1B[33m","\x1B[39m"),Jc=M("\x1B[34m","\x1B[39m"),Xc=M("\x1B[35m","\x1B[39m"),Zc=M("\x1B[36m","\x1B[39m"),Qc=M("\x1B[37m","\x1B[39m"),eu=M("\x1B[90m","\x1B[39m"),tu=M("\x1B[1m","\x1B[22m"),ru=M("\x1B[3m","\x1B[23m"),nu=M("\x1B[4m","\x1B[24m"),iu=M("\x1B[2m","\x1B[22m"),ou=M("\x1B[7m","\x1B[27m"),su=M("\x1B[8m","\x1B[28m"),au=M("\x1B[9m","\x1B[29m"),lu=M("\x1B[41m","\x1B[49m"),cu=M("\x1B[42m","\x1B[49m"),uu=M("\x1B[43m","\x1B[49m"),fu=M("\x1B[44m","\x1B[49m"),du=M("\x1B[45m","\x1B[49m"),hu=M("\x1B[46m","\x1B[49m"),gu=M("\x1B[47m","\x1B[49m"),mu=qi,pu={reset:Gc,red:Hc,green:qc,yellow:Yc,blue:Jc,magenta:Xc,cyan:Zc,white:Qc,gray:eu,bold:tu,italic:ru,underline:nu,dim:iu,inverse:ou,hidden:su,strikethrough:au,bgRed:lu,bgGreen:cu,bgYellow:uu,bgBlue:fu,bgMagenta:du,bgCyan:hu,bgWhite:gu,isColorSupported:mu},yu=pu,xu=["up","down","left","right","space","enter","cancel"],Xx={actions:new Set(xu),aliases:new Map([["k","up"],["j","down"],["h","left"],["l","right"],["\x03","cancel"],["escape","cancel"]]),messages:{cancel:"Canceled",error:"Something went wrong"}};var Zx=bu.platform.startsWith("win"),Qx=Symbol("clapp:cancel");var vu=Fc();var _=(e,t)=>vu?e:t,ev=_("\u25C6","*"),tv=_("\u25A0","x"),rv=_("\u25B2","x"),nv=_("\u25C7","o"),iv=_("\u250C","T"),wu=_("\u2502","|"),ov=_("\u2514","\u2014"),sv=_("\u25CF",">"),av=_("\u25CB"," "),lv=_("\u25FB","[\u2022]"),cv=_("\u25FC","[+]"),uv=_("\u25FB","[ ]"),fv=_("\u25AA","\u2022"),dv=_("\u2500","-"),hv=_("\u256E","+"),gv=_("\u251C","+"),mv=_("\u256F","+"),pv=_("\u25CF","\u2022"),yv=_("\u25C6","*"),bv=_("\u25B2","!"),xv=_("\u25A0","x");var vv={light:_("\u2500","-"),heavy:_("\u2501","="),block:_("\u2588","#")};function $u(){return`${yu.gray(wu)} `}var wv=$u();class Yi{configPath;config=null;events=[];retryCount=0;maxRetries=3;retryDelayMs=1000;constructor(){let e=zi.homedir(),t=rn.join(e,".config","clapp");this.configPath=rn.join(t,"telemetry.json")}async isEnabled(){if(Ue.env.DO_NOT_TRACK==="1"||Ue.env.DO_NOT_TRACK==="true")return!1;if(Ue.env.NO_TELEMETRY==="1"||Ue.env.NO_TELEMETRY==="true")return!1;return(await this.loadConfig()).enabled}async enable(){let e=await this.loadConfig();if(e.enabled=!0,!e.userId)e.userId=this.generateUserId();await this.saveConfig(e)}async disable(){let e=await this.loadConfig();e.enabled=!1,await this.saveConfig(e)}async track(e,t){if(!await this.isEnabled())return;let n={event:e,...t,timestamp:Date.now(),platform:zi.platform(),nodeVersion:Ue.version};if(this.events.push(n),this.events.length>=10)await this.send()}async trackCommand(e,t){await this.track("command",{command:e,duration:t})}async trackError(e,t){await this.track("error",{error:e,command:t})}async send(){if(!await this.isEnabled()||this.events.length===0)return!0;try{this.events=[],this.retryCount=0;let t=await this.loadConfig();return t.lastSent=Date.now(),await this.saveConfig(t),!0}catch{if(this.retryCount<this.maxRetries){this.retryCount++;let t=this.retryDelayMs*2**(this.retryCount-1);return await this.sleep(t),this.send()}return this.events=[],this.retryCount=0,!1}}async flush(){if(this.events.length===0)return!0;return this.send()}sleep(e){return new Promise((t)=>setTimeout(t,e))}async status(){let e=await this.loadConfig();return{enabled:e.enabled,doNotTrack:Ue.env.DO_NOT_TRACK==="1"||Ue.env.DO_NOT_TRACK==="true",eventsQueued:this.events.length,lastSent:e.lastSent}}async loadConfig(){if(this.config)return this.config;try{if(Cu(this.configPath)){let e=await tn.readFile(this.configPath,"utf-8");return this.config=JSON.parse(e),this.config}}catch{}return this.config={enabled:!1},this.config}async saveConfig(e){this.config=e;try{let t=rn.dirname(this.configPath);await tn.mkdir(t,{recursive:!0}),await tn.writeFile(this.configPath,JSON.stringify(e,null,2),"utf-8")}catch{}}generateUserId(){let e=Math.random().toString(36).substring(2,15),t=Date.now().toString(36);return`${e}-${t}`}}var Av=new Yi;var cn="0.3.28";function be(e){return{prev:null,next:null,data:e}}class le{head=null;tail=null;cursors=[];allocateCursor(e,t){let r={prev:e,next:t};return this.cursors.push(r),r}releaseCursor(){this.cursors.pop()}updateCursors(e,t,r,n){for(let i of this.cursors){if(i.prev===e)i.prev=t;if(i.next===r)i.next=n}}static createItem(e){return be(e)}createItem(e){return be(e)}get isEmpty(){return this.head===null}get first(){return this.head?.data??null}get last(){return this.tail?.data??null}*[Symbol.iterator](){for(let e=this.head;e!=null;e=e.next)yield e.data}fromArray(e){let t=null;this.head=null;for(let r of e){let n=be(r);if(n.prev=t,t)t.next=n;else this.head=n;t=n}return this.tail=t,this}toArray(){let e=[];for(let t=this.head;t!=null;t=t.next)e.push(t.data);return e}toJSON(){return this.toArray()}forEach(e,t){let r=this.allocateCursor(null,this.head);while(r.next!==null){let n=r.next;r.prev=n,r.next=n.next,e.call(t,n.data,n,this)}this.releaseCursor()}forEachRight(e,t){let r=this.allocateCursor(this.tail,null);while(r.prev!==null){let n=r.prev;r.next=n,r.prev=n.prev,e.call(t,n.data,n,this)}this.releaseCursor()}reduce(e,t){let r=t,n=0;for(let i=this.head;i!=null;i=i.next)r=e(r,i.data,n++,this);return r}some(e){let t=0;for(let r=this.head;r!=null;r=r.next)if(e(r.data,t++,this))return!0;return!1}map(e){let t=new le,r=null,n=0;for(let i=this.head;i!=null;i=i.next){let o=be(e(i.data,n++,this));if(o.prev=r,r)r.next=o;else t.head=o;r=o}return t.tail=r,t}filter(e){let t=new le,r=null,n=0;for(let i=this.head;i!=null;i=i.next)if(e(i.data,n++,this)){let o=be(i.data);if(o.prev=r,r)r.next=o;else t.head=o;r=o}return t.tail=r,t}clear(){let e=this.head;while(e){let t=e.next;e.prev=null,e.next=null,e=t}this.head=null,this.tail=null}copy(){let e=new le,t=null;for(let r=this.head;r!=null;r=r.next){let n=be(r.data);if(n.prev=t,t)t.next=n;else e.head=n;t=n}return e.tail=t,e}prepend(e){return this.insert(e,this.head)}prependData(e){return this.insert(be(e),this.head)}append(e){return this.insert(e,null)}appendData(e){return this.insert(be(e),null)}insert(e,t=null){if(t!=null)if(this.updateCursors(t.prev,e,t,e),t.prev===null){if(this.head!==t)throw Error("before doesn't belong to list");this.head=e,t.prev=e,e.next=t,this.updateCursors(null,e,null,null)}else t.prev.next=e,e.prev=t.prev,t.prev=e,e.next=t;else if(this.updateCursors(this.tail,e,null,e),this.tail!==null)this.tail.next=e,e.prev=this.tail,this.tail=e;else this.head=e,this.tail=e;return this}insertData(e,t=null){return this.insert(be(e),t)}remove(e){if(this.updateCursors(e,e.prev,e,e.next),e.prev!==null)e.prev.next=e.next;else if(this.head===e)this.head=e.next;else throw Error("item doesn't belong to list");if(e.next!==null)e.next.prev=e.prev;else if(this.tail===e)this.tail=e.prev;else throw Error("item doesn't belong to list");return e.prev=null,e.next=null,e}push(e){this.insert(be(e),null)}pop(){if(this.tail===null)return null;return this.remove(this.tail)}unshift(e){this.prependData(e)}shift(){if(this.head===null)return null;return this.remove(this.head)}prependList(e){return this.insertList(e,this.head)}appendList(e){return this.insertList(e,null)}insertList(e,t=null){if(e.head===null)return this;if(t!==null){if(this.updateCursors(t.prev,e.tail,t,e.head),t.prev!==null)t.prev.next=e.head,e.head.prev=t.prev;else this.head=e.head;t.prev=e.tail,e.tail.next=t}else{if(this.updateCursors(this.tail,e.tail,null,e.head),this.tail!==null)this.tail.next=e.head,e.head.prev=this.tail;else this.head=e.head;this.tail=e.tail}return e.head=null,e.tail=null,this}replace(e,t){if(t instanceof le)this.insertList(t,e),this.remove(e);else this.insert(t,e),this.remove(e)}}function Q(e){switch(e.type){case"StyleSheet":return oe(e.children,"");case"Rule":return`${Q(e.prelude)}{${Q(e.block)}}`;case"Block":return ku(e.children);case"Atrule":{let t=`@${e.name}`;if(e.prelude){let r=Q(e.prelude);if(r)t+=` ${r}`}if(e.block)t+=`{${Q(e.block)}}`;else t+=";";return t}case"AtrulePrelude":return oe(e.children,"");case"SelectorList":return oe(e.children,",");case"Selector":return oe(e.children,"");case"TypeSelector":return e.name;case"IdSelector":return`#${e.name}`;case"ClassSelector":return`.${e.name}`;case"NestingSelector":return"&";case"AttributeSelector":{let t=`[${e.name.name}`;if(e.matcher&&e.value)if(t+=e.matcher,e.value.type==="String")t+=`"${un(e.value.value)}"`;else t+=e.value.name;if(e.flags)t+=` ${e.flags}`;return t+="]",t}case"PseudoClassSelector":return e.children?`:${e.name}(${oe(e.children,"")})`:`:${e.name}`;case"PseudoElementSelector":return e.children?`::${e.name}(${oe(e.children,"")})`:`::${e.name}`;case"Combinator":return e.name===" "?" ":e.name;case"Declaration":return`${e.property}:${Q(e.value)}${e.important?"!important":""}`;case"DeclarationList":return oe(e.children,";");case"Value":return oe(e.children,"");case"Identifier":return e.name;case"Number":return e.value;case"Percentage":return`${e.value}%`;case"Dimension":return e.value+e.unit;case"String":return`"${un(e.value)}"`;case"Url":return/[\s"'()\\\u0000-\u001F\u007F]/.test(e.value)?`url("${un(e.value)}")`:`url(${e.value})`;case"Hash":return`#${e.name}`;case"Operator":return e.value;case"Function":return`${e.name}(${oe(e.children,"")})`;case"Parentheses":return`(${oe(e.children,"")})`;case"Brackets":return`[${oe(e.children,"")}]`;case"Raw":return e.value;case"Comment":return e.value.startsWith("!")?`/*${e.value}*/`:"";case"WhiteSpace":return" ";case"CDO":return"<!--";case"CDC":return"-->";case"AnPlusB":{let t=e.a??"",r=e.b??"";if(t&&r){let n=Number(r);return`${t==="1"?"":t==="-1"?"-":t}n${n>=0?`+${r}`:r}`}if(t)return`${t==="1"?"":t==="-1"?"-":t}n`;return r}case"Ratio":return`${e.left.value}/${e.right.value}`;case"UnicodeRange":return e.value;case"Nth":return e.selector?`${Q(e.nth)} of ${Q(e.selector)}`:Q(e.nth);case"MediaQueryList":return oe(e.children,",");case"MediaQuery":return oe(e.children,"");case"MediaFeature":{let t=`(${e.name}`;if(e.value)t+=`:${Q(e.value)}`;return t+=")",t}}return""}function oe(e,t){let r="",n=!0,i=null,o=e.head;while(o!=null){let s=o.data;if(s.type==="WhiteSpace"){let a=o.next?o.next.data:null;if(Ji(i)||Ji(a)){o=o.next;continue}}let l=Q(s);if(!l){o=o.next;continue}if(!n&&t&&!Au(i))r+=t;n=!1,r+=l,i=s,o=o.next}return r}function ku(e){let t="",r=null,n=e.head;while(n!=null){let i=n.data,o=Q(i);if(!o){n=n.next;continue}if(r&&Su(r,i))t+=";";t+=o,r=i,n=n.next}return t}function Su(e,t){return e.type==="Declaration"&&t.type!=="Comment"}function Ji(e){if(!e||e.type!=="Operator")return!1;let t=e.value;return t===":"||t===","||t==="/"}function Au(e){if(!e)return!1;return e.type==="Operator"||e.type==="Combinator"}function un(e){let t="";for(let r=0;r<e.length;r++){let n=e.charCodeAt(r);if(n===92)t+="\\\\";else if(n===34)t+="\\\"";else if(n<32||n===127){let i=n.toString(16),o=r+1<e.length?e.charCodeAt(r+1):-1,s=o===32||o===9||o===10||o===12||o===13||o>=48&&o<=57||o>=65&&o<=70||o>=97&&o<=102;t+=`\\${i}${s?" ":""}`}else t+=e[r]}return t}var We=(()=>{let e=new Uint8Array(128);for(let t=0;t<128;t++){let r=0;if(t===32||t===9||t===10||t===12||t===13)r|=1;if(t>=48&&t<=57)r|=2;if(t>=48&&t<=57||t>=65&&t<=70||t>=97&&t<=102)r|=4;if(t>=65&&t<=90||t>=97&&t<=122||t===95)r|=8;if(t===10||t===12||t===13)r|=16;e[t]=r}return e})();function fe(e){return e<128&&(We[e]&2)!==0}function Rt(e){return e<128&&(We[e]&4)!==0}function Xi(e){return e>=128||e<128&&(We[e]&8)!==0}function Eu(e){return e===45||e>=128||e<128&&(We[e]&10)!==0}function Tu(e){return e>=0&&e<=8||e===11||e>=14&&e<=31||e===127}function dn(e){return e<128&&(We[e]&16)!==0}function Re(e){return e<128&&(We[e]&1)!==0}function Ve(e,t){if(e!==92)return!1;if(dn(t))return!1;return!0}function fn(e,t,r){if(e===45)return Xi(t)||t===45||Ve(t,r);if(Xi(e))return!0;if(e===92)return Ve(e,t);return!1}function Nu(e,t,r){if(e===43||e===45){if(fe(t))return!0;if(t===46&&fe(r))return!0;return!1}if(e===46)return fe(t);return fe(e)}class Bt{source;offset=0;types;starts;ends;count=0;_tokens=null;_lineStarts=null;constructor(e){this.source=e;let t=Math.max(64,Math.ceil(e.length/3));this.types=new Uint8Array(t),this.starts=new Uint32Array(t),this.ends=new Uint32Array(t),this.tokenize()}get lineStarts(){if(this._lineStarts==null)this._lineStarts=Ou(this.source);return this._lineStarts}get tokens(){if(this._tokens!=null)return this._tokens;let e=Array.from({length:this.count});for(let t=0;t<this.count;t++)e[t]={type:this.types[t],start:this.starts[t],end:this.ends[t]};return this._tokens=e,e}addToken(e,t,r){if(this.count>=this.types.length)this.grow();this.types[this.count]=e,this.starts[this.count]=t,this.ends[this.count]=r,this.count++}grow(){let t=this.types.length*2,r=new Uint8Array(t);r.set(this.types),this.types=r;let n=new Uint32Array(t);n.set(this.starts),this.starts=n;let i=new Uint32Array(t);i.set(this.ends),this.ends=i}tokenize(){let e=this.source,t=0,r=e.length;while(t<r){let n=e.charCodeAt(t);if(n===47&&e.charCodeAt(t+1)===42){let s=t;t+=2;while(t<r&&!(e.charCodeAt(t)===42&&e.charCodeAt(t+1)===47))t++;t=t<r?t+2:r,this.addToken(25,s,t);continue}if(Re(n)){let s=t;while(t<r&&Re(e.charCodeAt(t)))t++;this.addToken(13,s,t);continue}if(n===34||n===39){t=this.consumeString(n,t);continue}if(n===35){if(t+1<r&&(Eu(e.charCodeAt(t+1))||Ve(e.charCodeAt(t+1),e.charCodeAt(t+2)))){let s=t;t++,t=this.consumeName(t),this.addToken(4,s,t);continue}this.addToken(9,t,t+1),t++;continue}switch(n){case 40:this.addToken(21,t,t+1),t++;continue;case 41:this.addToken(22,t,t+1),t++;continue;case 91:this.addToken(19,t,t+1),t++;continue;case 93:this.addToken(20,t,t+1),t++;continue;case 123:this.addToken(23,t,t+1),t++;continue;case 125:this.addToken(24,t,t+1),t++;continue;case 44:this.addToken(18,t,t+1),t++;continue;case 58:this.addToken(16,t,t+1),t++;continue;case 59:this.addToken(17,t,t+1),t++;continue}if(n===60&&e.startsWith("!--",t+1)){this.addToken(14,t,t+4),t+=4;continue}if(n===45&&e.startsWith("->",t+1)){this.addToken(15,t,t+3),t+=3;continue}if(n===64){let s=e.charCodeAt(t+1),l=e.charCodeAt(t+2),a=e.charCodeAt(t+3);if(fn(s,l,a)){let c=t;t++,t=this.consumeName(t),this.addToken(3,c,t);continue}this.addToken(9,t,t+1),t++;continue}let i=e.charCodeAt(t+1),o=e.charCodeAt(t+2);if(Nu(n,i,o)){t=this.consumeNumeric(t);continue}if(fn(n,i,o)){t=this.consumeIdentLike(t);continue}if(n===92){if(Ve(n,i)){t=this.consumeIdentLike(t);continue}this.addToken(9,t,t+1),t++;continue}this.addToken(9,t,t+1),t++}this.addToken(0,r,r)}consumeString(e,t){let r=this.source,n=r.length,i=t+1;while(i<n){let o=r.charCodeAt(i);if(o===e)return i++,this.addToken(5,t,i),i;if(dn(o))return this.addToken(6,t,i),i;if(o===92){let s=r.charCodeAt(i+1);if(dn(s)){i+=2;continue}if(i+1<n){i=this.consumeEscapeSkip(i+1);continue}}i++}return this.addToken(5,t,i),i}consumeEscapeSkip(e){let t=this.source;if(e>=t.length)return e;let r=t.charCodeAt(e);if(Rt(r)){let n=1;e++;while(n<6&&e<t.length&&Rt(t.charCodeAt(e)))e++,n++;if(e<t.length&&Re(t.charCodeAt(e)))e++;return e}return e+1}consumeName(e){let t=this.source,r=t.length,n=e;while(n<r){let i=t.charCodeAt(n);if(i<128&&(We[i]&10)!==0){n++;continue}if(i===45){n++;continue}if(i>=128){n++;continue}if(i===92&&Ve(i,t.charCodeAt(n+1))){n=this.consumeEscapeSkip(n+1);continue}break}return n}consumeNumber(e){let t=this.source,r=e;if(t.charCodeAt(r)===43||t.charCodeAt(r)===45)r++;while(r<t.length&&fe(t.charCodeAt(r)))r++;if(t.charCodeAt(r)===46&&fe(t.charCodeAt(r+1))){r+=2;while(r<t.length&&fe(t.charCodeAt(r)))r++}let n=t.charCodeAt(r);if(n===69||n===101){let i=t.charCodeAt(r+1),o=t.charCodeAt(r+2);if(fe(i)){r+=2;while(r<t.length&&fe(t.charCodeAt(r)))r++}else if((i===43||i===45)&&fe(o)){r+=3;while(r<t.length&&fe(t.charCodeAt(r)))r++}}return r}consumeNumeric(e){let t=this.source,r=this.consumeNumber(e),n=t.charCodeAt(r),i=t.charCodeAt(r+1),o=t.charCodeAt(r+2);if(fn(n,i,o)){let s=this.consumeName(r);return this.addToken(12,e,s),s}if(n===37)return this.addToken(11,e,r+1),r+1;return this.addToken(10,e,r),r}consumeIdentLike(e){let t=this.source,r=this.consumeName(e),n=t.charCodeAt(r);if(n===40&&r-e===3){let i=t.charCodeAt(e)|32,o=t.charCodeAt(e+1)|32,s=t.charCodeAt(e+2)|32;if(i===117&&o===114&&s===108){let l=r+1;while(l<t.length&&Re(t.charCodeAt(l)))l++;let a=t.charCodeAt(l);if(a===34||a===39)return this.addToken(2,e,r+1),r+1;return this.consumeUrl(e,r)}}if(n===40)return this.addToken(2,e,r+1),r+1;return this.addToken(1,e,r),r}consumeUrl(e,t){let r=this.source,n=r.length,i=t+1;while(i<n&&Re(r.charCodeAt(i)))i++;while(i<n){let o=r.charCodeAt(i);if(o===41)return i++,this.addToken(7,e,i),i;if(Re(o)){let s=i;while(i<n&&Re(r.charCodeAt(i)))i++;if(i>=n)return this.addToken(7,e,i),i;if(r.charCodeAt(i)===41)return i++,this.addToken(7,e,i),i;return this.consumeBadUrl(e,s)}if(o===34||o===39||o===40||Tu(o))return this.consumeBadUrl(e,i);if(o===92){if(Ve(o,r.charCodeAt(i+1))){i=this.consumeEscapeSkip(i+1);continue}return this.consumeBadUrl(e,i)}i++}return this.addToken(7,e,i),i}consumeBadUrl(e,t){let r=this.source,n=t;while(n<r.length){let i=r.charCodeAt(n);if(i===41){n++;break}if(i===92&&Ve(i,r.charCodeAt(n+1))){n=this.consumeEscapeSkip(n+1);continue}n++}return this.addToken(8,e,n),n}locate(e){let t=this.lineStarts,r=0,n=t.length-1;while(r<n){let o=r+n+1>>1;if(t[o]<=e)r=o;else n=o-1}let i=t[r];return{line:r+1,column:e-i+1}}}function Ou(e){let t=[0],r=e.length;for(let n=0;n<r;n++){let i=e.charCodeAt(n);if(i===10)t.push(n+1);else if(i===13){if(e.charCodeAt(n+1)!==10)t.push(n+1)}}return t}function hn(e,t,r){for(let n=t;n<r;n++)if(e.charCodeAt(n)===92)return Iu(e,t,r,n);return e.slice(t,r)}function Iu(e,t,r,n){let i=e.slice(t,n),o=n;while(o<r){if(e.charCodeAt(o)!==92){i+=e[o],o++;continue}if(o+1>=r){o++;continue}let l=e.charCodeAt(o+1);if(l===10){o+=2;continue}if(l===13){o+=e.charCodeAt(o+2)===10?3:2;continue}if(Rt(l)){let a=o+1,c="";while(c.length<6&&a<r&&Rt(e.charCodeAt(a)))c+=e[a],a++;let u=Number.parseInt(c,16);if(a<r&&Re(e.charCodeAt(a)))a++;i+=u===0||u>=55296&&u<=57343||u>1114111?String.fromCodePoint(65533):String.fromCodePoint(u),o=a;continue}i+=e[o+1],o+=2}return i}function gn(e,t,r){for(let n=t;n<r;n++)if(e.charCodeAt(n)===92)return Pu(e,t,r,n);return e.slice(t,r)}function Pu(e,t,r,n){let i=e.slice(t,n),o=n;while(o<r){if(e.charCodeAt(o)!==92){i+=e[o],o++;continue}let l=o+1,a="";while(a.length<6&&l<r&&Rt(e.charCodeAt(l)))a+=e[l],l++;if(a.length>0){let c=Number.parseInt(a,16);if(l<r&&Re(e.charCodeAt(l)))l++;i+=c===0||c>=55296&&c<=57343||c>1114111?String.fromCodePoint(65533):String.fromCodePoint(c),o=l;continue}if(l<r){i+=e[l],o=l+1;continue}i+=String.fromCodePoint(65533),o=l}return i}function io(e,t){let r=new Bt(e);return{source:e,types:r.types,starts:r.starts,ends:r.ends,count:r.count,end:r.count,pos:0,positions:t.positions??!1,filename:t.filename,parseValue:t.parseValue??!0,parseAtrulePrelude:t.parseAtrulePrelude??!0,parseCustomProperty:t.parseCustomProperty??!1,parseRulePrelude:t.parseRulePrelude??!0,onParseError:t.onParseError,tokenizer:r}}function x(e){return e.pos<e.end?e.types[e.pos]:0}function w(e){let t=e.pos;if(t>=e.end)return{type:0,start:e.starts[t]??e.source.length,end:e.ends[t]??e.source.length};return{type:e.types[t],start:e.starts[t],end:e.ends[t]}}function C(e){let t=e.pos++;if(t>=e.end)return{type:0,start:e.starts[t]??e.source.length,end:e.ends[t]??e.source.length};return{type:e.types[t],start:e.starts[t],end:e.ends[t]}}function xe(e,t){return e.source.slice(t.start,t.end)}function de(e){let{types:t,end:r}=e;while(e.pos<r){let n=t[e.pos];if(n===13||n===25)e.pos++;else break}}function Zi(e){let{types:t,end:r}=e;while(e.pos<r&&t[e.pos]===13)e.pos++}function k(e,t,r){if(!e.positions)return null;let n=e.tokenizer.locate(t.start),i=e.tokenizer.locate(r.end);return{source:e.filename??"<unknown>",start:{offset:t.start,line:n.line,column:n.column},end:{offset:r.end,line:i.line,column:i.column}}}function oo(e){if(!e.positions)return null;let t=w(e),r=e.tokenizer.locate(t.start);return{source:e.filename??"<unknown>",start:{offset:t.start,line:r.line,column:r.column},end:{offset:t.start,line:r.line,column:r.column}}}function Ut(e,t,r,n){return{type:"Raw",value:e,loc:k(n,t,r)}}function te(){return new le}function mn(e,t,r,n){if(e.onParseError){let{line:i,column:o}=e.tokenizer.locate(r.start),s=SyntaxError(`${e.filename??"<input>"}:${i}:${o}: ${t}`);s.line=i,s.column=o,s.offset=r.start,e.onParseError(s,n)}return n}function Wt(e,t={}){let r=io(e,t);switch(t.context??"stylesheet"){case"stylesheet":return to(r);case"atrule":return zt(r)??Qi(r);case"atrulePrelude":return Fu(r);case"mediaQuery":case"mediaQueryList":return eo(r);case"rule":return yn(r);case"selectorList":return vn(r);case"selector":return co(r);case"block":return bn(r);case"declarationList":return Bu(r);case"declaration":return xn(r)??Qi(r);case"value":return Uu(r);case"raw":return eo(r);default:return to(r)}}function Qi(e){return{type:"StyleSheet",children:te(),loc:oo(e)}}function eo(e){let t=w(e),r=t;while(x(e)!==0)r=C(e);return{type:"Raw",value:e.source.slice(t.start,r.end),loc:k(e,t,r)}}function to(e){let t=w(e),r=te(),{types:n,end:i}=e;while(e.pos<i){let l=n[e.pos];if(l===13){e.pos++;continue}if(l===25){let u={type:25,start:e.starts[e.pos],end:e.ends[e.pos]},f=pn(e,u);e.pos++,r.appendData(f);continue}if(l===0)break;if(l===14||l===15){e.pos++;continue}if(l===3){let u=zt(e);if(u)r.appendData(u);continue}if(l===24){e.pos++;continue}let a=e.pos,c=yn(e);if(r.appendData(c),e.pos===a)e.pos++}let o=e.end-1,s=o>=0?{type:e.types[o],start:e.starts[o],end:e.ends[o]}:{type:0,start:0,end:0};return{type:"StyleSheet",children:r,loc:k(e,t,s)}}function pn(e,t){return{type:"Comment",value:e.source.slice(t.start+2,t.end-2),loc:k(e,t,t)}}function zt(e){let t=w(e);if(t.type!==3)return null;e.pos++;let r=Vt(e.source,t.start+1,t.end);de(e);let n=e.pos,i=w(e),{types:o,end:s}=e,l=n,a=n;while(l<s){let f=o[l];if(f===0||f===17||f===23)break;if(f!==13&&f!==25)a=l+1;l++}let c=null;if(a>n){let f=e.starts[n],d=e.ends[a-1],h={type:o[a-1],start:e.starts[a-1],end:d},g=e.source.slice(f,d).trim();if(g.length>0)if(e.parseAtrulePrelude)try{let m=e.end;e.end=a,e.pos=n;let p=te();while(x(e)!==0){let y=ze(e);if(y)p.appendData(y)}if(ao(p),e.end=m,e.pos=l,p.isEmpty)c=Ut(g,i,h,e);else c={type:"AtrulePrelude",children:p,loc:null}}catch(m){let p=Ut(g,i,h,e);mn(e,`Failed to parse @${r} prelude: ${m.message}`,i,p),c=p,e.pos=l}else c=Ut(g,i,h,e),e.pos=l;else e.pos=l}else e.pos=l;let u=null;if(x(e)===17)C(e);else if(x(e)===23)u=bn(e,Mu.has(r));return{type:"Atrule",name:r,prelude:c,block:u,loc:k(e,t,w(e))}}var Lu=new Set(["is","not","where","has","matches","-moz-any","-webkit-any"]),Mu=new Set(["media","supports","document","layer","container","scope","starting-style","-moz-document","keyframes","-webkit-keyframes","-moz-keyframes","-o-keyframes"]);function Fu(e){let t=w(e),r=te();while(x(e)!==0){if(w(e).type===13){e.pos++;continue}let i=ze(e);if(i)r.appendData(i)}return{type:"AtrulePrelude",children:r,loc:k(e,t,w(e))}}function yn(e){let t=w(e),r;if(e.parseRulePrelude)r=vn(e);else{let i=w(e),o=i;while(x(e)!==0&&x(e)!==23)o=C(e);let s=e.source.slice(i.start,o.end).trim();r=Ut(s,i,o,e)}let n=bn(e,!0);return{type:"Rule",prelude:r,block:n,loc:k(e,t,w(e))}}function bn(e,t=!1){let r=w(e);if(x(e)!==23)return{type:"Block",children:te(),loc:oo(e)};e.pos++;let n=te(),{types:i,end:o}=e;while(e.pos<o){let s=i[e.pos];if(s===24||s===0)break;if(s===13){e.pos++;continue}if(s===25){let a={type:25,start:e.starts[e.pos],end:e.ends[e.pos]};e.pos++,n.appendData(pn(e,a));continue}if(s===3){let a=zt(e);if(a)n.appendData(a);continue}if(t&&ju(e,Du)){let a=yn(e);n.appendData(a);continue}let l=xn(e);if(l)n.appendData(l);if(e.pos<o&&i[e.pos]===17)e.pos++}if(x(e)===24)e.pos++;return{type:"Block",children:n,loc:k(e,r,w(e))}}function ju(e,t){let r=e.pos,n=t(e);return e.pos=r,n}function Du(e){let{types:t,end:r}=e;while(e.pos<r){let n=t[e.pos];if(n===23)return!0;if(n===17||n===24||n===0)return!1;e.pos++}return!1}function Bu(e){let t=w(e),r=te();while(x(e)!==0&&x(e)!==24){let n=w(e);if(n.type===13){e.pos++;continue}if(n.type===25){r.appendData(pn(e,C(e)));continue}if(n.type===17){e.pos++;continue}if(n.type===3){let o=zt(e);if(o)r.appendData(o);continue}let i=xn(e);if(i)r.appendData(i);if(x(e)===17)C(e)}return{type:"DeclarationList",children:r,loc:k(e,t,w(e))}}function xn(e){de(e);let t=w(e);if(t.type!==1&&t.type!==4&&!(t.type===9&&e.source[t.start]==="*"&&e.source[t.start+1]===" "))if(t.type===9&&e.source[t.start]==="*")e.pos++;else{mn(e,"Expected property name",t,{type:"Raw",value:"",loc:null});let{types:S,end:j}=e;while(e.pos<j){let K=S[e.pos];if(K===0||K===17||K===24)break;e.pos++}return null}let r=e.starts[e.pos],n=e.ends[e.pos];e.pos++;let i=e.source.slice(r,n);if(Zi(e),x(e)!==16){mn(e,`Expected ':' after property "${i}"`,w(e),{type:"Raw",value:"",loc:null});let{types:S,end:j}=e;while(e.pos<j){let K=S[e.pos];if(K===0||K===17||K===24)break;e.pos++}return null}e.pos++,Zi(e);let{types:o,starts:s,end:l,pos:a}=e,c=a,u=a,f=-1,d=-1;while(c<l){let S=o[c];if(S===0||S===17||S===24)break;if(S===9&&e.source.charCodeAt(s[c])===33){let j=c+1;while(j<l&&o[j]===13)j++;if(j<l&&o[j]===1){let K=s[j];if(e.ends[j]-K===9&&(e.source.charCodeAt(K)|32)===105&&(e.source.charCodeAt(K+1)|32)===109&&(e.source.charCodeAt(K+2)|32)===112&&(e.source.charCodeAt(K+3)|32)===111&&(e.source.charCodeAt(K+4)|32)===114&&(e.source.charCodeAt(K+5)|32)===116&&(e.source.charCodeAt(K+6)|32)===97&&(e.source.charCodeAt(K+7)|32)===110&&(e.source.charCodeAt(K+8)|32)===116){d=c,f=j,c=j+1;continue}}}if(S!==13&&S!==25)u=c+1;c++}let h=u,g=f>=0?{type:1,start:s[f],end:e.ends[f]}:null,m=i.startsWith("--"),p,y=s[a],b=h>a?e.ends[h-1]:y,v={type:o[a],start:y,end:e.ends[a]},R=h>a?{type:o[h-1],start:s[h-1],end:b}:v;if(m&&!e.parseCustomProperty||!e.parseValue)p={type:"Raw",value:e.source.slice(y,b).trim(),loc:k(e,v,R)};else if(h===a)p={type:"Value",children:te(),loc:k(e,v,R)};else{let S=e.end;e.end=h,e.pos=a,p=so(e),e.end=S}return e.pos=c,{type:"Declaration",property:i,important:g?!0:!1,value:p,loc:k(e,t,w(e))}}function Uu(e){return so(e)}function so(e){let t=w(e),r=te();while(x(e)!==0&&x(e)!==17&&x(e)!==24&&x(e)!==22&&x(e)!==20){let n=ze(e);if(n)r.appendData(n)}return lo(r),{type:"Value",children:r,loc:k(e,t,w(e))}}function ao(e){for(let t of e)if("children"in t&&t.children instanceof le)ao(t.children);lo(e)}function lo(e){let t=e.head;while(t){if(t.data.type==="Number"){let r=t.next;while(r&&r.data.type==="WhiteSpace")r=r.next;if(r&&r.data.type==="Operator"&&r.data.value==="/"){let n=r.next;while(n&&n.data.type==="WhiteSpace")n=n.next;if(n&&n.data.type==="Number"){let i={type:"Ratio",left:t.data,right:n.data,loc:null},o=t.next;while(o&&o!==n.next){let s=o.next;e.remove(o),o=s}e.replace(t,e.createItem(i)),t=e.head;continue}}}t=t.next}}function ze(e){let t=e.pos;if(t>=e.end)return null;let r=e.types[t],n=e.starts[t],i=e.ends[t],o=e.source;switch(r){case 13:return e.pos++,e.positions?{type:"WhiteSpace",value:" ",loc:ee(e,n,i)}:{type:"WhiteSpace",value:" ",loc:null};case 25:return e.pos++,{type:"Comment",value:o.slice(n+2,i-2),loc:e.positions?ee(e,n,i):null};case 10:return e.pos++,{type:"Number",value:o.slice(n,i),loc:e.positions?ee(e,n,i):null};case 11:return e.pos++,{type:"Percentage",value:o.slice(n,i-1),loc:e.positions?ee(e,n,i):null};case 12:{e.pos++;let s=n,l=o.charCodeAt(s);if(l===43||l===45)s++;let a=!1;while(s<i){let u=o.charCodeAt(s);if(u>=48&&u<=57){s++;continue}if(u===46&&!a){a=!0,s++;continue}break}let c=o.charCodeAt(s);if(c===69||c===101){let u=s+1,f=o.charCodeAt(u);if(f===43||f===45)u++;let d=!1;while(u<i){let h=o.charCodeAt(u);if(h>=48&&h<=57){u++,d=!0;continue}break}if(d)s=u}return{type:"Dimension",value:o.slice(n,s),unit:o.slice(s,i),loc:e.positions?ee(e,n,i):null}}case 1:return e.pos++,{type:"Identifier",name:gn(o,n,i),loc:e.positions?ee(e,n,i):null};case 5:{e.pos++;let s=n+1,a=i-n>=2&&o.charCodeAt(i-1)===o.charCodeAt(n)?i-1:i;return{type:"String",value:hn(o,s,a),loc:e.positions?ee(e,n,i):null}}case 7:{e.pos++;let s=n+4;while(s<i&&ro(o.charCodeAt(s)))s++;let l=i;if(l>s&&o.charCodeAt(l-1)===41)l--;while(l>s&&ro(o.charCodeAt(l-1)))l--;let a;if(l-s>=2){let c=o.charCodeAt(s),u=o.charCodeAt(l-1);if((c===34||c===39)&&c===u)a=o.slice(s+1,l-1);else a=o.slice(s,l)}else a=o.slice(s,l);return{type:"Url",value:a,loc:e.positions?ee(e,n,i):null}}case 4:return e.pos++,{type:"Hash",name:o.slice(n+1,i),loc:e.positions?ee(e,n,i):null};case 2:return Wu(e);case 21:return zu(e);case 18:return e.pos++,{type:"Operator",value:",",loc:e.positions?ee(e,n,i):null};case 16:return e.pos++,{type:"Operator",value:":",loc:e.positions?ee(e,n,i):null};case 9:{e.pos++;let s=o.charCodeAt(n),l=o[n];if(Vu(s))return{type:"Operator",value:l,loc:e.positions?ee(e,n,i):null};return{type:"Identifier",name:l,loc:e.positions?ee(e,n,i):null}}case 19:{e.pos++;let s=te();while(x(e)!==0&&x(e)!==20){let a=ze(e);if(a)s.appendData(a)}let l=e.pos<e.end?e.ends[e.pos]:i;if(x(e)===20)e.pos++;return{type:"Brackets",children:s,loc:e.positions?ee(e,n,l):null}}case 3:case 23:case 24:case 22:case 20:case 17:case 0:case 14:case 15:case 6:case 8:return e.pos++,{type:"Raw",value:o.slice(n,i),loc:e.positions?ee(e,n,i):null}}return e.pos++,null}function ro(e){return e===32||e===9||e===10||e===12||e===13}function Vu(e){return e===47||e===43||e===45||e===42||e===61||e===62||e===60||e===126||e===124||e===36||e===94||e===33||e===38}function Vt(e,t,r){for(let n=t;n<r;n++){let i=e.charCodeAt(n);if(i>=65&&i<=90)return e.slice(t,r).toLowerCase()}return e.slice(t,r)}function ee(e,t,r){let n=e.tokenizer.locate(t),i=e.tokenizer.locate(r);return{source:e.filename??"<unknown>",start:{offset:t,line:n.line,column:n.column},end:{offset:r,line:i.line,column:i.column}}}function Wu(e){let t=C(e),r=Vt(e.source,t.start,t.end-1),n=te();while(x(e)!==0&&x(e)!==22){let i=ze(e);if(i)n.appendData(i)}if(x(e)===22)C(e);if(r==="url"){for(let i=n.head;i!=null;i=i.next)if(i.data.type==="String")return{type:"Url",value:i.data.value,loc:k(e,t,w(e))}}return{type:"Function",name:r,children:n,loc:k(e,t,w(e))}}function zu(e){let t=C(e),r=te();while(x(e)!==0&&x(e)!==22){let n=ze(e);if(n)r.appendData(n)}if(x(e)===22)C(e);return{type:"Parentheses",children:r,loc:k(e,t,w(e))}}function vn(e){let t=w(e),r=te();while(x(e)!==0){if(de(e),x(e)===0||x(e)===23)break;let n=co(e);if(n.children.head!==null)r.appendData(n);if(de(e),x(e)===18){C(e);continue}break}return{type:"SelectorList",children:r,loc:k(e,t,w(e))}}function co(e){let t=w(e),r=te(),n=!0;while(x(e)!==0&&x(e)!==18&&x(e)!==23){let i=w(e);if(i.type===13){if(C(e),!n&&x(e)!==0&&x(e)!==18&&x(e)!==23&&!no(e)&&!Ku(e)){let s={type:"Combinator",name:" ",loc:k(e,i,i)};r.appendData(s),n=!0}continue}if(i.type===9&&e.source.charCodeAt(i.start)===124&&e.types[e.pos+1]===9&&e.source.charCodeAt(e.starts[e.pos+1])===124){let s=w(e);C(e);let l=C(e),a={type:"Combinator",name:"||",loc:k(e,s,l)};r.appendData(a),n=!0,de(e);continue}if(no(e)){let s=C(e),a={type:"Combinator",name:e.source[s.start],loc:k(e,s,s)};r.appendData(a),n=!0,de(e);continue}let o=Gu(e);if(!o)break;r.appendData(o),n=!1}while(r.tail&&r.tail.data.type==="Combinator")r.remove(r.tail);return{type:"Selector",children:r,loc:k(e,t,w(e))}}function no(e){let t=w(e);if(t.type!==9)return!1;let r=e.source[t.start];return r===">"||r==="+"||r==="~"}function Ku(e){if(e.types[e.pos]!==9)return!1;if(e.source.charCodeAt(e.starts[e.pos])!==124)return!1;if(e.types[e.pos+1]!==9)return!1;return e.source.charCodeAt(e.starts[e.pos+1])===124}function Gu(e){let t=w(e);switch(t.type){case 1:{if(C(e),x(e)===9&&e.source[w(e).start]==="|"&&e.source[w(e).start+1]!=="="&&!(e.types[e.pos+1]===9&&e.source.charCodeAt(e.starts[e.pos+1])===124)){if(C(e),x(e)===1){let n=C(e);return{type:"TypeSelector",name:`${xe(e,t)}|${xe(e,n)}`,loc:k(e,t,n)}}if(x(e)===9&&e.source[w(e).start]==="*"){let n=C(e);return{type:"TypeSelector",name:`${xe(e,t)}|*`,loc:k(e,t,n)}}}return{type:"TypeSelector",name:xe(e,t),loc:k(e,t,t)}}case 11:return C(e),{type:"TypeSelector",name:xe(e,t),loc:k(e,t,t)};case 10:return C(e),{type:"TypeSelector",name:xe(e,t),loc:k(e,t,t)};case 9:{let r=e.source[t.start];if(r==="*")return C(e),{type:"TypeSelector",name:"*",loc:k(e,t,t)};if(r==="."){if(C(e),x(e)===1){let n=C(e);return{type:"ClassSelector",name:xe(e,n),loc:k(e,t,n)}}return null}if(r==="&")return C(e),{type:"NestingSelector",loc:k(e,t,t)};return C(e),null}case 4:return C(e),{type:"IdSelector",name:e.source.slice(t.start+1,t.end),loc:k(e,t,t)};case 16:{C(e);let r=x(e)===16;if(r)C(e);return Hu(e,r,t)}case 19:return qu(e)}return null}function Hu(e,t,r){let n=w(e);if(n.type===1){C(e);let i=Vt(e.source,n.start,n.end);return t?{type:"PseudoElementSelector",name:i,children:null,loc:k(e,r,n)}:{type:"PseudoClassSelector",name:i,children:null,loc:k(e,r,n)}}if(n.type===2){C(e);let i=Vt(e.source,n.start,n.end-1),o=te();if(!t&&Lu.has(i)){let a=w(e),c=a,u=1;while(x(e)!==0&&u>0){if(x(e)===21||x(e)===2)u++;else if(x(e)===22){if(u--,u===0)break}c=C(e)}if(x(e)===22)C(e);let f=e.source.slice(a.start,c.end).trim();if(f.length>0){let d=io(f,{positions:!1}),h=vn(d);o.appendData(h)}}else{while(x(e)!==0&&x(e)!==22){let a=ze(e);if(a)o.appendData(a)}if(x(e)===22)C(e)}if(t)return{type:"PseudoElementSelector",name:i,children:o,loc:k(e,r,w(e))};return{type:"PseudoClassSelector",name:i,children:o,loc:k(e,r,w(e))}}return null}function qu(e){let t=C(e);de(e);let r=w(e);if(r.type!==1)return null;C(e);let n={type:"Identifier",name:xe(e,r),loc:k(e,r,r)};de(e);let i=null,o=null,s=null,l=w(e);if(l.type===9){let c=e.source[l.start],u=e.source[l.start+1];if(c==="=")i="=",C(e);else if((c==="~"||c==="|"||c==="^"||c==="$"||c==="*")&&u==="="){C(e);let h=w(e);if(h.type===9&&e.source[h.start]==="=")C(e),i=`${c}=`}de(e);let f=w(e);if(f.type===5){C(e);let h=f.end-f.start>=2&&e.source.charCodeAt(f.end-1)===e.source.charCodeAt(f.start);o={type:"String",value:hn(e.source,f.start+1,h?f.end-1:f.end),loc:k(e,f,f)}}else if(f.type===1)C(e),o={type:"Identifier",name:xe(e,f),loc:k(e,f,f)};de(e);let d=w(e);if(d.type===1)C(e),s=xe(e,d)}de(e);let a=w(e);if(x(e)===20)a=C(e);return{type:"AttributeSelector",name:n,matcher:i,value:o,flags:s,loc:k(e,t,a)}}var uo=Symbol("walkSkip"),U=Symbol("walkStop");function Yu(e){return{root:e,stylesheet:null,atrule:null,atrulePrelude:null,rule:null,selector:null,block:null,declaration:null,function:null}}function Ju(e,t){let r=Yu(e),n=typeof t==="function"?t:t.enter,i=typeof t==="function"?null:t.leave??null,o=typeof t==="function"?null:t.visit??null,s=typeof t==="function"?!1:t.reverse??!1;function l(a,c,u){let f=null,d;switch(a.type){case"StyleSheet":f="stylesheet",d=r.stylesheet,r.stylesheet=a;break;case"Atrule":f="atrule",d=r.atrule,r.atrule=a;break;case"AtrulePrelude":f="atrulePrelude",d=r.atrulePrelude,r.atrulePrelude=a;break;case"Rule":f="rule",d=r.rule,r.rule=a;break;case"Selector":f="selector",d=r.selector,r.selector=a;break;case"Block":f="block",d=r.block,r.block=a;break;case"Declaration":f="declaration",d=r.declaration,r.declaration=a;break;case"Function":f="function",d=r.function,r.function=a;break}let h;if((o===null||o===a.type)&&n){let g=n.call(r,a,c,u);if(g===uo){if(f)r[f]=d;return}if(g===U){if(f)r[f]=d;return U}}if(h=Xu(a,s,l),h===U){if(f)r[f]=d;return U}if((o===null||o===a.type)&&i){if(i.call(r,a,c,u)===U){if(f)r[f]=d;return U}}if(f)r[f]=d;return}return l(e,null,null)}var Ke=Object.assign(Ju,{skip:uo,stop:U});function Xu(e,t,r){if("children"in e&&e.children instanceof le)return Zu(e.children,t,r);if(e.type==="Rule"){if(r(e.prelude,null,null)===U)return U;if(r(e.block,null,null)===U)return U;return}if(e.type==="Atrule"){if(e.prelude){if(r(e.prelude,null,null)===U)return U}if(e.block){if(r(e.block,null,null)===U)return U}return}if(e.type==="Declaration")return r(e.value,null,null);if(e.type==="AttributeSelector"){if(r(e.name,null,null)===U)return U;if(e.value)return r(e.value,null,null);return}return}function Zu(e,t,r){let n;if(t)e.forEachRight((i,o,s)=>{if(n)return;if(r(i,o,s)===U)n=U});else e.forEach((i,o,s)=>{if(n)return;if(r(i,o,s)===U)n=U});return n}function et(e,t={}){let r=t.exclamation??!1,n=!1;Ke(e,(i,o,s)=>{if(i.type!=="Comment")return;let l=i.value.startsWith("!");if(r===!0&&l)return;if(r==="first-exclamation"&&l&&!n){n=!0;return}if(o&&s)s.remove(o)})}function Kt(e){Ke(e,(t)=>{if(t.type!=="Block"&&t.type!=="DeclarationList")return;if(!("children"in t)||!t.children)return;let r=t.children,n=r.head;if(n==null||n.next==null)return;let i=0;for(let l=n;l!=null;l=l.next)if(l.data.type==="Declaration"){if(i++,i>=2)break}if(i<2)return;let o=new Map,s=[];for(let l=n;l!=null;l=l.next){let a=l.data;if(a.type!=="Declaration")continue;let c=a.property,u=o.get(c);if(u){let f=!!u.decl.important,d=!!a.important;if(d||f===d)s.push(u.item),o.set(c,{item:l,decl:a});else s.push(l)}else o.set(c,{item:l,decl:a})}for(let l of s)r.remove(l)})}var Qu={black:"#000",fuchsia:"#f0f",white:"#fff",red:"#f00",cyan:"#0ff",blue:"#00f",yellow:"#ff0",magenta:"#f0f",lime:"#0f0",silver:"#c0c0c0",gray:"#808080",maroon:"#800000",olive:"#808000",green:"#008000",purple:"#800080",teal:"#008080",navy:"#000080"},ef={"#f00":"red","#ff0000":"red","#000080":"navy","#008080":"teal"};function $n(e){if(!e.startsWith("#"))return e;let t=e.slice(1);if(t.length===6){if(t[0]===t[1]&&t[2]===t[3]&&t[4]===t[5])return`#${t[0]}${t[2]}${t[4]}`}if(t.length===8){if(t[0]===t[1]&&t[2]===t[3]&&t[4]===t[5]&&t[6]===t[7])return`#${t[0]}${t[2]}${t[4]}${t[6]}`}return e}function fo(e){let t=e.toLowerCase();return Qu[t]??null}function ho(e){let t=e.toLowerCase();return ef[t]??null}function tf(e,t,r){let n=(e<<16|t<<8|r).toString(16).padStart(6,"0");return $n(`#${n}`)}var rf=/^rgba?\(\s*([+-]?\d*\.?\d+%?)\s*[,\s]\s*([+-]?\d*\.?\d+%?)\s*[,\s]\s*([+-]?\d*\.?\d+%?)\s*(?:[,/]\s*([+-]?\d*\.?\d+%?)\s*)?\)$/;function go(e){let t=rf.exec(e.trim());if(!t)return e;let r=wn(t[1]),n=wn(t[2]),i=wn(t[3]);if(t[4]!==void 0&&!nf(t[4]))return e;return tf(r,n,i)}function nf(e){if(e.endsWith("%"))return Number.parseFloat(e)>=100;return Number.parseFloat(e)>=1}function wn(e){if(e.endsWith("%"))return Math.max(0,Math.min(255,Math.round(Number.parseFloat(e)*2.55)));return Math.max(0,Math.min(255,Math.round(Number.parseFloat(e))))}var of=new Set(["px","pt","pc","in","cm","mm","q","em","rem","ex","ch","cap","ic","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"]);function Gt(e){if(e.charCodeAt(0)===43)e=e.slice(1);if(e.includes(".")){let t=e.replace(/(\.\d*?)0+($|[eE])/,"$1$2");t=t.replace(/\.($|[eE])/,"$1"),e=t}if(e.startsWith("0.")&&e.length>2)e=e.slice(1);else if(e.startsWith("-0.")&&e.length>3)e=`-${e.slice(2)}`;if(e==="-0"||e==="-.0"||e==="-0.0")e="0";return e}function mo(e,t){let r=Gt(e);if((r==="0"||r==="-0")&&of.has(t.toLowerCase()))return{value:"0",unit:""};return{value:r,unit:t}}function po(e){return Gt(e)}function yo(e,t){let r=Number.parseFloat(e);if(!Number.isFinite(r))return e;let n=t<0?0:t;return r.toFixed(n)}var bo=new Set(["color","background","background-color","border","border-color","border-top","border-top-color","border-right","border-right-color","border-bottom","border-bottom-color","border-left","border-left-color","border-block","border-block-color","border-block-start-color","border-block-end-color","border-inline","border-inline-color","border-inline-start-color","border-inline-end-color","outline","outline-color","caret-color","fill","stroke","flood-color","lighting-color","stop-color","column-rule","column-rule-color","text-decoration","text-decoration-color","text-emphasis","text-emphasis-color","text-shadow","box-shadow","accent-color","scrollbar-color"]);function xo(e){if(!e||e.type!=="Operator")return!1;let t=e.value;return t===":"||t===","||t==="/"}function sf(e){let t=e.children;if(!t)return;while(t.head&&t.head.data.type==="WhiteSpace")t.remove(t.head);while(t.tail&&t.tail.data.type==="WhiteSpace")t.remove(t.tail);let r=t.head;while(r){let n=r.next;if(r.data.type==="WhiteSpace"){let i=r.prev&&xo(r.prev.data),o=n&&xo(n.data);if(i||o)t.remove(r)}r=n}}function af(e){return e?.property.toLowerCase()==="unicode-range"}function Cn(e,t={}){let r=t.floatPrecision??null,n=r===null?null:(i)=>yo(i,r);Ke(e,{enter(i,o,s){if((i.type==="Number"||i.type==="Percentage"||i.type==="Dimension")&&af(this.declaration))return;switch(i.type){case"Number":{let l=n?n(i.value):i.value;i.value=Gt(l);return}case"Percentage":{let l=n?n(i.value):i.value;i.value=po(l);return}case"Dimension":{let l=n?n(i.value):i.value,a=mo(l,i.unit);i.value=a.value,i.unit=a.unit;return}case"Hash":{let l=$n(`#${i.name}`).slice(1);if(i.name=l,o&&s&&this.declaration&&bo.has(this.declaration.property.toLowerCase())){let a=ho(`#${l}`);if(a&&a.length<l.length+1){let c={type:"Identifier",name:a,loc:i.loc};s.replace(o,s.createItem(c))}}return}case"Identifier":{if(!o||!s||!this.declaration)return;if(!bo.has(this.declaration.property.toLowerCase()))return;let l=fo(i.name);if(l&&l.length<i.name.length){let a={type:"Hash",name:l.slice(1),loc:i.loc};s.replace(o,s.createItem(a))}return}case"Url":return;case"Function":{let l=i.name.toLowerCase();if((l==="rgb"||l==="rgba")&&o&&s)i.__rgbReplaceCandidate=!0}}},leave(i,o,s){if(i.type==="Parentheses"||i.type==="Function"||i.type==="Value")sf(i);if(i.type==="Function"&&i.__rgbReplaceCandidate&&o&&s){let l=Q(i),a=go(l);if(a!==l&&a.startsWith("#")){let c={type:"Hash",name:a.slice(1),loc:i.loc};s.replace(o,s.createItem(c))}}}})}function lf(e,t={}){let r=Wt(e,{context:"stylesheet"});return vo(r,t)}function Rn(e,t={}){let r=Wt(e,{context:"declarationList"});return vo(r,t)}function vo(e,t){if(t.comments===!1)et(e,{exclamation:!1});else if(t.comments==="first-exclamation")et(e,{exclamation:"first-exclamation"});else et(e,{exclamation:!0});return Cn(e,{floatPrecision:t.floatPrecision??null}),Kt(e),{css:Q(e),ast:e}}function Le(e,t,r){if(e.size>=1e4){let n=e.keys().next().value;if(n!==void 0)e.delete(n)}return e.set(t,r),r}var wo=new Map,_e=new Map;var kn={col:"col",row:"row",jc:"justify",ji:"justify-items",js:"justify-self",ai:"items",ac:"content",as:"self",wrap:"wrap",nowrap:"nowrap",c:"center",s:"start",e:"end",sb:"between",sa:"around",se:"evenly",st:"stretch",thin:"thin",extralight:"extralight",light:"light",normal:"normal",medium:"medium",semibold:"semibold",bold:"bold",extrabold:"extrabold",black:"black",t:"top",r:"right",b:"bottom",l:"left"},ff=/[%#()]/,df=/^\d+(?:\.\d+)?(?:px|rem|em|vh|vw|dvh|dvw|svh|svw|lvh|lvw|ch|ex|lh|cap|ic|rlh|vi|vb|vmin|vmax|cqw|cqh|cqi|cqb|cqmin|cqmax|cm|mm|in|pt|pc|Q)$/,Eo=["calc","min","max","clamp","mod","rem","sin","cos","tan","asin","acos","atan","atan2","pow","sqrt","hypot","log","exp","round"],hf=new Set(Eo);function se(e){return ff.test(e)||df.test(e)}function $o(e){if(!Eo.some((o)=>e.includes(`${o}(`)))return e;let t="",r=[],n=null,i=null;for(let o=0;o<e.length;o++){let s=e.charCodeAt(o);if(s>=48&&s<=57)n=o;else if(n!==null&&(s===37||s>=97&&s<=122||s>=65&&s<=90))n=o;else i=n,n=null;if(s===40){t+=e[o];let a=o;for(let u=o-1;u>=0;u--){let f=e.charCodeAt(u);if(f>=48&&f<=57||f>=97&&f<=122)a=u;else break}let c=e.slice(a,o);if(hf.has(c))r.unshift(!0);else if(r[0]&&c==="")r.unshift(!0);else r.unshift(!1);continue}if(s===41){t+=e[o],r.shift();continue}if(s===44&&r[0]){t+=", ";continue}if(s===32&&r[0]&&t.charCodeAt(t.length-1)===32)continue;if((s===43||s===45||s===42||s===47)&&r[0]){let a=t.trimEnd(),c=a.charCodeAt(a.length-1),u=a.charCodeAt(a.length-2),f=e.charCodeAt(o+1),d=c===43||c===45||c===42||c===47,h=f===43||f===45||f===42||f===47;if((c===101||c===69)&&u>=48&&u<=57)t+=e[o];else if(d||c===40||c===44)t+=e[o];else if(e.charCodeAt(o-1)===32)t+=`${e[o]} `;else if(c>=48&&c<=57||f>=48&&f<=57||c===41||f===40||h||i!==null&&i===o-1)t+=` ${e[o]} `;else t+=e[o];continue}t+=e[o]}return t}function Ht(e){if(!e.includes("_"))return $o(e);let t="",r=0;while(r<e.length){let n=e[r];if(n==="\\"&&e[r+1]==="_"){t+="_",r+=2;continue}if(n==="u"&&e.slice(r,r+4)==="url("){let i=r,o=1;r+=4;while(r<e.length&&o>0){if(e[r]==="(")o++;else if(e[r]===")")o--;r++}t+=e.slice(i,r);continue}t+=n==="_"?" ":n,r++}return $o(t)}function Co(e,t){if(t.length!==2)return null;let[r,n]=t;if(r!=="min"&&r!=="max")return null;return[se(n)?`${r}-${e}-[${n}]`:`${r}-${e}-${n}`]}var gf={flex:{expand:(e,t)=>{let r=t[e]||e;if(["col","row","col-reverse","row-reverse","wrap","nowrap","wrap-reverse"].includes(r))return`flex-${r}`;let n=e.match(/^(jc|ji|js|ai|ac|as)-(.+)$/);if(n){let i=t[n[1]]||n[1],o=t[n[2]]||n[2];return`${i}-${o}`}if(/^\d+$/.test(r)||["grow","shrink","auto","initial","none"].includes(r))return`flex-${r}`;return null}},grid:{expand:(e,t)=>{let r=t[e]||e;if(e.startsWith("cols-")||e.startsWith("rows-"))return`grid-${e}`;if(e.startsWith("flow-"))return`grid-${e}`;if(e.startsWith("gap-"))return e;return null}},text:{expand:(e,t)=>{let r=t[e]||e;if(se(r))return`text-[${r}]`;if(/^\d{3}$/.test(r))return{"100":"font-thin","200":"font-extralight","300":"font-light","400":"font-normal","500":"font-medium","600":"font-semibold","700":"font-bold","800":"font-extrabold","900":"font-black"}[r]||`font-[${r}]`;if(/^[a-z-]+$/i.test(r)&&!["xs","sm","base","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl","8xl","9xl"].includes(r)){if(["white","black","inherit","current","transparent"].includes(r.toLowerCase()))return`text-${r}`;if(["red","blue","green","yellow","purple","pink","gray","slate","zinc","neutral","stone","orange","amber","lime","emerald","teal","cyan","sky","indigo","violet","fuchsia","rose"].includes(r.toLowerCase()))return`text-${r}-500`;return`font-[${r}]`}return`text-${r}`}},font:{expand:(e,t)=>{let r=t[e]||e,n=["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],i=["sans","serif","mono"];if(n.includes(r)||i.includes(r))return`font-${r}`;if(/^\d{3}$/.test(r))return{"100":"font-thin","200":"font-extralight","300":"font-light","400":"font-normal","500":"font-medium","600":"font-semibold","700":"font-bold","800":"font-extrabold","900":"font-black"}[r]||`font-[${r}]`;return`font-[${r}]`}},bg:{expand:(e,t)=>`bg-${t[e]||e}`},w:{expand:(e,t)=>{let r=t[e]||e;if(se(r))return`w-[${r}]`;return`w-${r}`},multiValue:(e)=>Co("w",e)},h:{expand:(e,t)=>{let r=t[e]||e;if(se(r))return`h-[${r}]`;return`h-${r}`},multiValue:(e)=>Co("h",e)},p:{expand:(e)=>`p-${e}`},px:{expand:(e)=>`px-${e}`},py:{expand:(e)=>`py-${e}`},pt:{expand:(e)=>`pt-${e}`},pr:{expand:(e)=>`pr-${e}`},pb:{expand:(e)=>`pb-${e}`},pl:{expand:(e)=>`pl-${e}`},m:{expand:(e)=>`m-${e}`},mx:{expand:(e)=>`mx-${e}`},my:{expand:(e)=>`my-${e}`},mt:{expand:(e)=>`mt-${e}`},mr:{expand:(e)=>`mr-${e}`},mb:{expand:(e)=>`mb-${e}`},ml:{expand:(e)=>`ml-${e}`},scroll:{expand:(e)=>{if(["x","y"].includes(e))return null;if(["auto","hidden","scroll","visible"].includes(e))return`overflow-${e}`;return null},multiValue:(e)=>{if(e.length===2){let[t,r]=e;if(["x","y"].includes(t)&&["auto","hidden","scroll","visible"].includes(r))return[`overflow-${t}-${r}`]}return null}},overflow:{expand:(e)=>`overflow-${e}`,multiValue:(e)=>{if(e.length===2){let[t,r]=e;if(["x","y"].includes(t))return[`overflow-${t}-${r}`]}return null}},border:{expand:(e)=>`border-${e}`},rounded:{expand:(e)=>`rounded-${e}`},shadow:{expand:(e)=>`shadow-${e}`},gap:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-"))return`gap-${e}`;return`gap-${e}`}},space:{expand:(e)=>`space-${e}`},opacity:{expand:(e)=>`opacity-${e}`},z:{expand:(e)=>`z-${e}`},inset:{expand:(e,t)=>{let r=t[e]||e;if(r.startsWith("x-")||r.startsWith("y-"))return`inset-${r}`;if(se(r))return`inset-[${r}]`;return`inset-${r}`}},top:{expand:(e)=>se(e)?`top-[${e}]`:`top-${e}`},right:{expand:(e)=>se(e)?`right-[${e}]`:`right-${e}`},bottom:{expand:(e)=>se(e)?`bottom-[${e}]`:`bottom-${e}`},left:{expand:(e)=>se(e)?`left-[${e}]`:`left-${e}`},duration:{expand:(e)=>`duration-${e}`},delay:{expand:(e)=>`delay-${e}`},ease:{expand:(e)=>`ease-${e}`},transition:{expand:(e)=>{if(["all","none","colors","opacity","shadow","transform"].includes(e))return`transition-${e}`;if(/^\d+$/.test(e))return`duration-${e}`;if(["linear","in","out","in-out","ease-linear","ease-in","ease-out","ease-in-out"].includes(e))return e.startsWith("ease-")?e:`ease-${e}`;return`transition-${e}`}},translate:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-")||e.startsWith("z-"))return`translate-${e}`;return`translate-${e}`}},rotate:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-")||e.startsWith("z-"))return`rotate-${e}`;return`rotate-${e}`}},scale:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-")||e.startsWith("z-"))return`scale-${e}`;return`scale-${e}`}},skew:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-"))return`skew-${e}`;return`skew-${e}`}},origin:{expand:(e)=>`origin-${e}`},cursor:{expand:(e)=>`cursor-${e}`},select:{expand:(e)=>`select-${e}`},resize:{expand:(e)=>`resize-${e}`},appearance:{expand:(e)=>`appearance-${e}`},pointer:{expand:(e)=>`pointer-events-${e}`},outline:{expand:(e)=>`outline-${e}`},ring:{expand:(e)=>`ring-${e}`},blur:{expand:(e)=>`blur-${e}`},brightness:{expand:(e)=>`brightness-${e}`},contrast:{expand:(e)=>`contrast-${e}`},grayscale:{expand:(e)=>`grayscale-${e}`},saturate:{expand:(e)=>`saturate-${e}`},sepia:{expand:(e)=>`sepia-${e}`},backdrop:{expand:(e)=>`backdrop-${e}`},aspect:{expand:(e)=>`aspect-${e}`},columns:{expand:(e)=>`columns-${e}`},break:{expand:(e)=>`break-${e}`},object:{expand:(e)=>`object-${e}`},overscroll:{expand:(e)=>`overscroll-${e}`},place:{expand:(e)=>`place-${e}`},items:{expand:(e)=>`items-${e}`},justify:{expand:(e)=>`justify-${e}`},content:{expand:(e)=>`content-${e}`},self:{expand:(e)=>`self-${e}`},order:{expand:(e)=>`order-${e}`},col:{expand:(e)=>`col-${e}`},row:{expand:(e)=>`row-${e}`},tracking:{expand:(e)=>`tracking-${e}`},leading:{expand:(e)=>`leading-${e}`},list:{expand:(e)=>`list-${e}`},decoration:{expand:(e)=>`decoration-${e}`},underline:{expand:(e)=>`underline-${e}`},accent:{expand:(e)=>`accent-${e}`},caret:{expand:(e)=>`caret-${e}`},"scroll-m":{expand:(e)=>`scroll-m-${e}`},"scroll-p":{expand:(e)=>`scroll-p-${e}`},snap:{expand:(e)=>`snap-${e}`},touch:{expand:(e)=>`touch-${e}`},will:{expand:(e)=>`will-change-${e}`},fill:{expand:(e)=>`fill-${e}`},stroke:{expand:(e)=>`stroke-${e}`},sr:{expand:(e)=>`sr-${e}`},invert:{expand:(e)=>`invert-${e}`},"hue-rotate":{expand:(e)=>se(e)?`hue-rotate-[${e}]`:`hue-rotate-${e}`},"drop-shadow":{expand:(e)=>`drop-shadow-${e}`},"backdrop-invert":{expand:(e)=>`backdrop-invert-${e}`},"backdrop-hue-rotate":{expand:(e)=>se(e)?`backdrop-hue-rotate-[${e}]`:`backdrop-hue-rotate-${e}`},animate:{expand:(e)=>`animate-${e}`},"forced-colors":{expand:(e)=>`forced-colors-${e}`}},kt=new Set(["sm","md","lg","xl","2xl","hover","focus","active","visited","disabled","enabled","focus-within","focus-visible","group-hover","group-focus","peer-hover","peer-focus","*","**","dark","first","last","odd","even","only","first-of-type","last-of-type","only-of-type","checked","indeterminate","default","required","valid","invalid","in-range","out-of-range","placeholder-shown","autofill","read-only","user-valid","user-invalid","inert","empty","before","after","selection","marker","file","first-letter","first-line","backdrop","details-content","print","motion-safe","motion-reduce","pointer-none","pointer-coarse","pointer-fine","any-pointer-none","any-pointer-coarse","any-pointer-fine","inverted-colors","noscript","starting","contrast-more","contrast-less","rtl","ltr","portrait","landscape","@sm","@md","@lg","@xl","@2xl"]),Ro=new WeakMap,ko=new WeakMap;function mf(e){if(!e)return kn;let t=Ro.get(e);if(!t)t=e.aliases?{...kn,...e.aliases}:kn,Ro.set(e,t);return t}function pf(e){if(!e?.aliases)return"";let t=ko.get(e);if(t===void 0)t=JSON.stringify(e.aliases),ko.set(e,t);return t}function St(e){let t=[],r="",n=0;for(let i=0;i<e.length;i++){let o=e[i];if(o==="[")n++;else if(o==="]")n--;if(o===":"&&n===0)t.push(r),r="";else r+=o}return t.push(r),t}function yf(e,t){let r=`${e}:${t?.colonSyntax}:${pf(t)}`,n=_e.get(r);if(n)return n;let i=mf(t);if(t?.colonSyntax===!0){let m=e.match(/^([a-z][a-z0-9-]*):([^[\]:]+)$/i);if(m){let[,p,y]=m;if(!kt.has(p)){if(se(y)){let v=[`${p}-[${y}]`];return Le(_e,r,v),v}let b=y.startsWith("-")?[`-${p}-${y.slice(1)}`]:[`${p}-${y}`];return Le(_e,r,b),b}}}let o="",s=e,l=!1;if(s.startsWith("-"))l=!0,s=s.slice(1);let a=s.match(/^((?:[a-z@][a-z0-9-]*:)+)(.+)$/i);if(a){if(a[1].slice(0,-1).split(":").every((y)=>kt.has(y)))o=a[1],s=a[2]}let c=s.match(/^([a-z][a-z0-9-]*)\[([^\]]*)\]$/i);if(!c||s.includes("-[")){let m=[e];return Le(_e,r,m),m}let[,u,f]=c,d=f.split(/\s+/).filter(Boolean);if(d.length===0)return Le(_e,r,[]),[];let h=gf[u.toLowerCase()];if(h?.multiValue){let m=h.multiValue(d,i);if(m){let p=m.map((y)=>`${o}${l?"-":""}${y}`);return Le(_e,r,p),p}}if(!h){let m=[];for(let p of d){let y=p.match(/^([a-z@][a-z0-9-]*):(.+)$/i),b="",v=p;if(y&&kt.has(y[1]))b=`${y[1]}:`,v=y[2];let R="";if(v.startsWith("-"))R="-",v=v.slice(1);let S="";if(v.endsWith("!"))S="!",v=v.slice(0,-1);let j=l?"-":"";if(se(v))m.push(`${o}${b}${S}${j}${R}${u}-[${v}]`);else m.push(`${o}${b}${S}${j}${R}${u}-${v}`)}return Le(_e,r,m),m}let g=[];for(let m of d){let p=m.match(/^([a-z@][a-z0-9-]*):(.+)$/i),y="",b=m;if(p&&kt.has(p[1]))y=`${p[1]}:`,b=p[2];let v="";if(b.startsWith("-"))v="-",b=b.slice(1);let R="";if(b.endsWith("!"))R="!",b=b.slice(0,-1);let S=h.expand(b,i);if(S){let j=l?"-":"";g.push(`${o}${y}${R}${j}${v}${S}`)}}return Le(_e,r,g),g}function bf(e,t){let r=new Set;if(!t?.enabled)return r;let n=t.prefix??"tc-",i=["class","className","style","id","name","type","value","href","src","alt","title","role","for","action","method","target","rel","placeholder","disabled","checked","selected","readonly","required","maxlength","minlength","pattern","autocomplete","autofocus","tabindex","contenteditable","draggable","spellcheck","lang","dir","hidden","slot","part","is","key","ref"],o=t.ignoreAttributes||i,s=(c)=>{let u=c.includes(":")?c.split(":").pop():c;for(let f of o)if(f.endsWith("*")){if(u.startsWith(f.slice(0,-1)))return!0}else if(u===f)return!0;if(u.startsWith("on"))return!0;if(u.startsWith("data-")||u.startsWith("aria-"))return!0;return!1},l=/<([a-z][a-z0-9-]*)\s([^>]*)>/gi,a;while((a=l.exec(e))!==null){let c=a[2],u=/([a-z][a-z0-9-:]*)(?:=["']([^"']*)["'])?(?=\s|$|\/?>)/gi,f;while((f=u.exec(c))!==null){let d=f[1],h=f[2];if(n){if(!d.startsWith(n))continue;d=d.slice(n.length)}if(s(d))continue;let g="",m=d,p=d.match(/^((?:[a-z@][a-z0-9-]*:)+)([a-z][a-z0-9-]*)$/i);if(p){if(p[1].slice(0,-1).split(":").every((v)=>kt.has(v)))g=p[1],m=p[2]}if(h!==void 0){let y=h.split(/\s+/).filter(Boolean);for(let b of y){let v=`${g}${m}-${b}`;if(So(v.replace(/^(?:[a-z@][a-z0-9-]*:)+/gi,"")))r.add(v)}}else{let y=`${g}${m}`;if(So(m))r.add(y)}}}return r}function So(e){if(!e||e.length===0)return!1;return/^[a-z][a-z0-9-/]*(?:-\[[^\]]+\])?$/i.test(e)}function Sn(e){let t=wo.get(e);if(t)return t;let r=Cf(e);return r.base=$f(r),Le(wo,e,r),r}var xf=new Set(["bg","text","border","ring","placeholder","divide","accent","caret","fill","stroke","outline","decoration","shadow","ring-offset","from","via","to"]),vf=/^(.+?)\/(\d+|\[\d*\.?\d+\])$/,wf=/^(\d+)\/(\d+)$/;function Ao(e){let t=!1;for(let r=0;r<e.length;r++){let n=e.charCodeAt(r);if(n===45){if(!t||r+1>=e.length)return;return[e.slice(0,r),e.slice(r+1)]}if(n>=97&&n<=122){t=!0;continue}return}return}function $f(e){let t=e.raw;for(let r of e.variants)if(t.startsWith(`${r}:`))t=t.slice(r.length+1);if(e.important){if(t.charCodeAt(0)===33)t=t.slice(1);else if(t.charCodeAt(t.length-1)===33)t=t.slice(0,-1)}return t}function Cf(e){let t=!1,r=e;if(e.startsWith("!"))t=!0,r=e.slice(1);else if(e.endsWith("!")&&e.length>1)t=!0,r=e.slice(0,-1);{let h=St(r),g=h[h.length-1],m=!1;if(g.charCodeAt(0)===33&&g.length>1)m=!0,g=g.slice(1);let p=g.match(/^\[([a-z-]+):(.+)\]$/);if(p)return{raw:e,variants:h.slice(0,-1),utility:p[1],value:Ht(p[2]),important:t||m,arbitrary:!0}}let n=r.match(/^((?:[a-z-]+:)*)(-?[a-z-]+?)-\[([^\]]+)\]\/\[([^\]]+)\]$/);if(n){let[,h,g,m,p]=n,y=h?h.split(":").filter(Boolean):[],b=g.startsWith("-"),v=b?g.slice(1):g,R=Ht(m);if(b)R=R.startsWith("-")?R:`-${R}`;return{raw:e,variants:y,utility:v,value:`${R}/${p}`,important:t,arbitrary:!0,modifierArbitrary:!0}}let i=r.match(/^((?:[a-z-]+:)*)(-?[a-z-]+?)-\[(.+)\]$/);if(i){let h=i[1],g=h?h.split(":").filter(Boolean):[],m=i[2],p=m.startsWith("-");if(p)m=m.slice(1);let y=Ht(i[3]),b,v=y.match(/^(color|length|size|bg-size|url|number|percentage|position|line-width|absolute-size|relative-size|image|angle|time|flex|string|family-name):(.*)/i);if(v)b=v[1].toLowerCase(),y=v[2];if(p)y=y.startsWith("-")?y:`-${y}`;return{raw:e,variants:g,utility:m,value:y,important:t,arbitrary:!0,typeHint:b}}let o=St(r),s=o[o.length-1],l=o.slice(0,-1);if(s.startsWith("!")&&s.length>1)t=!0,s=s.slice(1);else if(s.endsWith("!")&&s.length>1)t=!0,s=s.slice(0,-1);if(l.length>0)r=`${l.join(":")}:${s}`;else r=s;if(["inline-block","inline-flex","inline-grid","flex-row","flex-row-reverse","flex-col","flex-col-reverse","flex-wrap","flex-wrap-reverse","flex-nowrap","flex-1","flex-auto","flex-initial","flex-none","flex-grow","flex-shrink"].includes(s))return{raw:e,variants:l,utility:s,value:void 0,important:t,arbitrary:!1};let c=s.match(/^([a-z-]+?)-\[(.+?)\]$/);if(c){let h=Ht(c[2]),g,m=h.match(/^(color|length|size|bg-size|url|number|percentage|position|line-width|absolute-size|relative-size|image|angle|time|flex|string|family-name):(.*)/i);if(m)g=m[1].toLowerCase(),h=m[2];return{raw:e,variants:l,utility:c[1],value:h,important:t,arbitrary:!0,typeHint:g}}let u=["inset-x","inset-y","border-t","border-r","border-b","border-l","border-x","border-y","border-s","border-e","grid-cols","grid-rows","grid-flow","auto-cols","auto-rows","col-span","row-span","col-start","col-end","row-start","row-end","translate-x","translate-y","translate-z","scale-x","scale-y","scale-z","rotate-x","rotate-y","rotate-z","skew-x","skew-y","scroll-m","scroll-mx","scroll-my","scroll-mt","scroll-mr","scroll-mb","scroll-ml","scroll-p","scroll-px","scroll-py","scroll-pt","scroll-pr","scroll-pb","scroll-pl","gap-x","gap-y","overflow-x","overflow-y","min-w","max-w","min-h","max-h","space-x","space-y","ring-offset","underline-offset","outline-offset","backdrop-blur","backdrop-brightness","backdrop-contrast","backdrop-grayscale","backdrop-invert","backdrop-saturate","backdrop-sepia","hue-rotate","drop-shadow","mask-clip","flex-grow","flex-shrink","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","perspective-origin","justify-self","form-input","form-textarea","form-select","form-multiselect","form-checkbox","form-radio","mix-blend","bg-blend","line-clamp","border-spacing","border-spacing-x","border-spacing-y","rounded-s","rounded-e","rounded-ss","rounded-se","rounded-es","rounded-ee","rounded-t","rounded-r","rounded-b","rounded-l","rounded-tl","rounded-tr","rounded-bl","rounded-br","border-opacity","ring-opacity","stroke-dasharray","stroke-dashoffset","animate-iteration","animate-duration","animate-delay","text-emphasis-color","text-emphasis","text-shadow","word-spacing","column-gap","column-rule","font-stretch","list-image"];if(s==="divide-x"||s==="divide-y")return{raw:e,variants:l,utility:s,value:void 0,important:t,arbitrary:!1};let f=s.match(/^(divide-[xy])-(.+)$/);if(f)return{raw:e,variants:l,utility:f[1],value:f[2],important:t,arbitrary:!1};for(let h of u)if(s.startsWith(`${h}-`))return{raw:e,variants:l,utility:h,value:s.slice(h.length+1),important:t,arbitrary:!1};if(s.startsWith("-")){let h=s.slice(1);for(let m of u)if(h.startsWith(`${m}-`))return{raw:e,variants:l,utility:m,value:`-${h.slice(m.length+1)}`,important:t,arbitrary:!1};let g=Ao(h);if(g)return{raw:e,variants:l,utility:g[0],value:`-${g[1]}`,important:t,arbitrary:!1};return{raw:e,variants:l,utility:h,value:void 0,important:t,arbitrary:!1}}let d=Ao(s);if(d){let[h,g]=d,m=g.match(vf);if(m&&xf.has(h))return{raw:e,variants:l,utility:h,value:`${m[1]}/${m[2]}`,important:t,arbitrary:!1};let p=g.match(wf);if(p)return{raw:e,variants:l,utility:h,value:`${p[1]}/${p[2]}`,important:t,arbitrary:!1};return{raw:e,variants:l,utility:h,value:g,important:t,arbitrary:!1}}return{raw:e,variants:l,utility:s,value:void 0,important:t,arbitrary:!1}}function Rf(e){return/^\[[a-z-]+:[^\]]+\]$/i.test(e)}function kf(e){if(!e)return!1;if(e==="*"||e==="**")return!0;if(e.startsWith("[")&&e.endsWith("]"))return e.length>2;return/^(?:@[a-z0-9]|[a-z]|\d+[a-z])[a-z0-9.-]*(?:\[[^\]]+\])?(?:\/[\w-]+)?$/i.test(e)}function Sf(e,t){let r=e;if(r.startsWith("!"))r=r.slice(1);if(r.endsWith("!"))r=r.slice(0,-1);if(!r)return!1;if(Rf(r))return!0;if(t?.enabled&&/^[a-z]+\[[^\]]+\]$/i.test(r))return!0;return/^[-@]?[a-z][a-z0-9.-]*(?:-\[[^\]]+\])?(?:\/(?:[\w.]+|[\w-]+|\[[^\]]+\]))?$/i.test(r)}function To(e,t){if(!e||e.length===0)return!1;if(t?.colonSyntax&&/^[a-z]+:[^[\]:]+$/i.test(e))return!0;let r=e;if(r.startsWith("!"))r=r.slice(1);if(r.endsWith("!"))r=r.slice(0,-1);if(!r)return!1;let n=St(r);for(let i=0;i<n.length-1;i++)if(!kf(n[i]))return!1;return Sf(n[n.length-1],t)}function Yt(e){let t=[],r="",n=0;for(let i of e)if(i==="[")n++,r+=i;else if(i==="]")n--,r+=i;else if(/\s/.test(i)&&n===0){if(r)t.push(r),r=""}else r+=i;if(r)t.push(r);return t}function Jt(e,t){let r=new Set,n=[/class(?:Name)?=["']([^"']+)["']/g,/class(?:Name)?=\{["']([^"']+)["']\}/g,/class(?:Name)?=\{`([^`]+)`\}/g];for(let o of n){let s;while((s=o.exec(e))!==null){let l=s[1],a=l.match(/["']([^"']+)["']/g);if(a)for(let f of a){let d=f.replace(/["']/g,""),h=Yt(d);for(let g of h)qt(r,g,t)}let c=l.replace(/["'`]/g," ").replace(/\$\{[^}]+\}/g," "),u=Yt(c).filter((f)=>To(f,t?.bracketSyntax));for(let f of u)qt(r,f,t)}}let i=[/class(?:Name|:list)?=\{([^{}]*(?:\{[^{}]*\}[^{}]*)*)\}/g,/:class="([^"]*)"/g,/:class='([^']*)'/g,/\bx-class="([^"]*)"/g,/\bx-class='([^']*)'/g];for(let o of i){let s;while((s=o.exec(e))!==null){let l=s[1].match(/["'`]([^"'`]*)["'`]/g);if(l)for(let a of l){let c=a.replace(/["'`]/g,"").replace(/\$\{[^}]+\}/g," ");for(let u of Yt(c))qt(r,u,t)}}}if(t?.codeStrings?.enabled!==!1)for(let o of No(e,t?.bracketSyntax))qt(r,o,t);if(t?.attributify?.enabled){let o=bf(e,t.attributify);for(let s of o)r.add(s)}return r}function Af(e,t){if(!/[-:/[]/.test(e))return!1;if(e.startsWith("-")&&!/^-[a-z]/i.test(e))return!1;return To(e,t)}function No(e,t){let r=new Set,n=e.length,i=0,o=/[<>]/g,s=o.exec(e),l=-1,a=-1,c="";while(i<n){let u=e[i];if(u==="/"&&e[i+1]==="/"){let p=e.indexOf(`
91
+ `),Ie.exit(e.exitCode??2)}async runMatchedCommand(){let{args:e,options:t,matchedCommand:r}=this;if(!r||!r.commandAction)return;r.checkUnknownOptions(),r.checkOptionValue(),r.checkRequiredArgs();let n=[];r.args.forEach((l,a)=>{if(l.variadic)n.push(e.slice(a));else n.push(e[a])}),n.push(t);let i={command:r,args:n,options:t};for(let l of r.beforeHooks)await l(i);let o,s=async()=>{let l=r.commandAction.apply(this,n);if(l instanceof Promise)o=await l;else o=l;return o};if(r.middleware.length>0){let l=0,a=async()=>{if(l<r.middleware.length){let c=r.middleware[l++];await c({...i,next:a})}else await s()};await a()}else await s();for(let l of r.afterHooks)await l(i);return o}removeSignalHandlers(){if(!this.signalHandlersSet)return this;return Ie.removeAllListeners("SIGINT"),Ie.removeAllListeners("SIGTERM"),this.signalHandlersSet=!1,this}destroy(){this.removeSignalHandlers(),this.commands=[],this.rawArgs=[],this.args=[],this.options={},this.matchedCommand=void 0,this.matchedCommandName=void 0,this.removeAllListeners()}}class Hi{cache;enabled;cleanupInterval=null;hits=0;misses=0;constructor(){this.cache=new Map,this.enabled=!0,this.startCleanupInterval()}startCleanupInterval(){if(this.cleanupInterval)return;this.cleanupInterval=setInterval(()=>{this.cleanup()},30000),this.cleanupInterval.unref()}stopCleanup(){if(this.cleanupInterval)clearInterval(this.cleanupInterval),this.cleanupInterval=null}isEnabled(){return this.enabled}get(e){if(!this.enabled){this.misses++;return}let t=this.cache.get(e);if(!t){this.misses++;return}if(Date.now()-t.timestamp>t.ttl){this.cache.delete(e),this.misses++;return}return this.hits++,t.value}set(e,t,r=5000){if(!this.enabled)return;this.cache.set(e,{value:t,timestamp:Date.now(),ttl:r})}has(e){if(!this.enabled)return!1;let t=this.cache.get(e);if(!t)return!1;if(Date.now()-t.timestamp>t.ttl)return this.cache.delete(e),!1;return!0}delete(e){this.cache.delete(e)}clear(){this.cache.clear()}disable(){this.enabled=!1,this.clear()}enable(){this.enabled=!0}stats(){return{size:this.cache.size,enabled:this.enabled,hits:this.hits,misses:this.misses}}resetStats(){this.hits=0,this.misses=0}keys(){return Array.from(this.cache.keys())}cleanup(){let e=Date.now();for(let[t,r]of this.cache.entries())if(e-r.timestamp>r.ttl)this.cache.delete(t)}destroy(){this.stopCleanup(),this.clear(),this.resetStats()}}var Kx=new Hi;function Kc(){if("FORCE_COLOR"in wt.env)return wt.env.FORCE_COLOR!=="0";if("NO_COLOR"in wt.env||wt.env.TERM==="dumb")return!1;if(wt.platform==="win32")return!0;return Wi.isatty(1)&&Wi.isatty(2)}var qi=Kc();function M(e,t){if(!qi)return(r)=>r;return(r)=>e+r+t}var Gc=M("\x1B[0m","\x1B[0m"),Hc=M("\x1B[31m","\x1B[39m"),qc=M("\x1B[32m","\x1B[39m"),Yc=M("\x1B[33m","\x1B[39m"),Jc=M("\x1B[34m","\x1B[39m"),Xc=M("\x1B[35m","\x1B[39m"),Zc=M("\x1B[36m","\x1B[39m"),Qc=M("\x1B[37m","\x1B[39m"),eu=M("\x1B[90m","\x1B[39m"),tu=M("\x1B[1m","\x1B[22m"),ru=M("\x1B[3m","\x1B[23m"),nu=M("\x1B[4m","\x1B[24m"),iu=M("\x1B[2m","\x1B[22m"),ou=M("\x1B[7m","\x1B[27m"),su=M("\x1B[8m","\x1B[28m"),au=M("\x1B[9m","\x1B[29m"),lu=M("\x1B[41m","\x1B[49m"),cu=M("\x1B[42m","\x1B[49m"),uu=M("\x1B[43m","\x1B[49m"),fu=M("\x1B[44m","\x1B[49m"),du=M("\x1B[45m","\x1B[49m"),hu=M("\x1B[46m","\x1B[49m"),gu=M("\x1B[47m","\x1B[49m"),mu=qi,pu={reset:Gc,red:Hc,green:qc,yellow:Yc,blue:Jc,magenta:Xc,cyan:Zc,white:Qc,gray:eu,bold:tu,italic:ru,underline:nu,dim:iu,inverse:ou,hidden:su,strikethrough:au,bgRed:lu,bgGreen:cu,bgYellow:uu,bgBlue:fu,bgMagenta:du,bgCyan:hu,bgWhite:gu,isColorSupported:mu},yu=pu,xu=["up","down","left","right","space","enter","cancel"],Xx={actions:new Set(xu),aliases:new Map([["k","up"],["j","down"],["h","left"],["l","right"],["\x03","cancel"],["escape","cancel"]]),messages:{cancel:"Canceled",error:"Something went wrong"}};var Zx=bu.platform.startsWith("win"),Qx=Symbol("clapp:cancel");var vu=Fc();var _=(e,t)=>vu?e:t,ev=_("\u25C6","*"),tv=_("\u25A0","x"),rv=_("\u25B2","x"),nv=_("\u25C7","o"),iv=_("\u250C","T"),wu=_("\u2502","|"),ov=_("\u2514","\u2014"),sv=_("\u25CF",">"),av=_("\u25CB"," "),lv=_("\u25FB","[\u2022]"),cv=_("\u25FC","[+]"),uv=_("\u25FB","[ ]"),fv=_("\u25AA","\u2022"),dv=_("\u2500","-"),hv=_("\u256E","+"),gv=_("\u251C","+"),mv=_("\u256F","+"),pv=_("\u25CF","\u2022"),yv=_("\u25C6","*"),bv=_("\u25B2","!"),xv=_("\u25A0","x");var vv={light:_("\u2500","-"),heavy:_("\u2501","="),block:_("\u2588","#")};function $u(){return`${yu.gray(wu)} `}var wv=$u();class Yi{configPath;config=null;events=[];retryCount=0;maxRetries=3;retryDelayMs=1000;constructor(){let e=zi.homedir(),t=rn.join(e,".config","clapp");this.configPath=rn.join(t,"telemetry.json")}async isEnabled(){if(Ue.env.DO_NOT_TRACK==="1"||Ue.env.DO_NOT_TRACK==="true")return!1;if(Ue.env.NO_TELEMETRY==="1"||Ue.env.NO_TELEMETRY==="true")return!1;return(await this.loadConfig()).enabled}async enable(){let e=await this.loadConfig();if(e.enabled=!0,!e.userId)e.userId=this.generateUserId();await this.saveConfig(e)}async disable(){let e=await this.loadConfig();e.enabled=!1,await this.saveConfig(e)}async track(e,t){if(!await this.isEnabled())return;let n={event:e,...t,timestamp:Date.now(),platform:zi.platform(),nodeVersion:Ue.version};if(this.events.push(n),this.events.length>=10)await this.send()}async trackCommand(e,t){await this.track("command",{command:e,duration:t})}async trackError(e,t){await this.track("error",{error:e,command:t})}async send(){if(!await this.isEnabled()||this.events.length===0)return!0;try{this.events=[],this.retryCount=0;let t=await this.loadConfig();return t.lastSent=Date.now(),await this.saveConfig(t),!0}catch{if(this.retryCount<this.maxRetries){this.retryCount++;let t=this.retryDelayMs*2**(this.retryCount-1);return await this.sleep(t),this.send()}return this.events=[],this.retryCount=0,!1}}async flush(){if(this.events.length===0)return!0;return this.send()}sleep(e){return new Promise((t)=>setTimeout(t,e))}async status(){let e=await this.loadConfig();return{enabled:e.enabled,doNotTrack:Ue.env.DO_NOT_TRACK==="1"||Ue.env.DO_NOT_TRACK==="true",eventsQueued:this.events.length,lastSent:e.lastSent}}async loadConfig(){if(this.config)return this.config;try{if(Cu(this.configPath)){let e=await tn.readFile(this.configPath,"utf-8");return this.config=JSON.parse(e),this.config}}catch{}return this.config={enabled:!1},this.config}async saveConfig(e){this.config=e;try{let t=rn.dirname(this.configPath);await tn.mkdir(t,{recursive:!0}),await tn.writeFile(this.configPath,JSON.stringify(e,null,2),"utf-8")}catch{}}generateUserId(){let e=Math.random().toString(36).substring(2,15),t=Date.now().toString(36);return`${e}-${t}`}}var Av=new Yi;var cn="0.3.29";function be(e){return{prev:null,next:null,data:e}}class le{head=null;tail=null;cursors=[];allocateCursor(e,t){let r={prev:e,next:t};return this.cursors.push(r),r}releaseCursor(){this.cursors.pop()}updateCursors(e,t,r,n){for(let i of this.cursors){if(i.prev===e)i.prev=t;if(i.next===r)i.next=n}}static createItem(e){return be(e)}createItem(e){return be(e)}get isEmpty(){return this.head===null}get first(){return this.head?.data??null}get last(){return this.tail?.data??null}*[Symbol.iterator](){for(let e=this.head;e!=null;e=e.next)yield e.data}fromArray(e){let t=null;this.head=null;for(let r of e){let n=be(r);if(n.prev=t,t)t.next=n;else this.head=n;t=n}return this.tail=t,this}toArray(){let e=[];for(let t=this.head;t!=null;t=t.next)e.push(t.data);return e}toJSON(){return this.toArray()}forEach(e,t){let r=this.allocateCursor(null,this.head);while(r.next!==null){let n=r.next;r.prev=n,r.next=n.next,e.call(t,n.data,n,this)}this.releaseCursor()}forEachRight(e,t){let r=this.allocateCursor(this.tail,null);while(r.prev!==null){let n=r.prev;r.next=n,r.prev=n.prev,e.call(t,n.data,n,this)}this.releaseCursor()}reduce(e,t){let r=t,n=0;for(let i=this.head;i!=null;i=i.next)r=e(r,i.data,n++,this);return r}some(e){let t=0;for(let r=this.head;r!=null;r=r.next)if(e(r.data,t++,this))return!0;return!1}map(e){let t=new le,r=null,n=0;for(let i=this.head;i!=null;i=i.next){let o=be(e(i.data,n++,this));if(o.prev=r,r)r.next=o;else t.head=o;r=o}return t.tail=r,t}filter(e){let t=new le,r=null,n=0;for(let i=this.head;i!=null;i=i.next)if(e(i.data,n++,this)){let o=be(i.data);if(o.prev=r,r)r.next=o;else t.head=o;r=o}return t.tail=r,t}clear(){let e=this.head;while(e){let t=e.next;e.prev=null,e.next=null,e=t}this.head=null,this.tail=null}copy(){let e=new le,t=null;for(let r=this.head;r!=null;r=r.next){let n=be(r.data);if(n.prev=t,t)t.next=n;else e.head=n;t=n}return e.tail=t,e}prepend(e){return this.insert(e,this.head)}prependData(e){return this.insert(be(e),this.head)}append(e){return this.insert(e,null)}appendData(e){return this.insert(be(e),null)}insert(e,t=null){if(t!=null)if(this.updateCursors(t.prev,e,t,e),t.prev===null){if(this.head!==t)throw Error("before doesn't belong to list");this.head=e,t.prev=e,e.next=t,this.updateCursors(null,e,null,null)}else t.prev.next=e,e.prev=t.prev,t.prev=e,e.next=t;else if(this.updateCursors(this.tail,e,null,e),this.tail!==null)this.tail.next=e,e.prev=this.tail,this.tail=e;else this.head=e,this.tail=e;return this}insertData(e,t=null){return this.insert(be(e),t)}remove(e){if(this.updateCursors(e,e.prev,e,e.next),e.prev!==null)e.prev.next=e.next;else if(this.head===e)this.head=e.next;else throw Error("item doesn't belong to list");if(e.next!==null)e.next.prev=e.prev;else if(this.tail===e)this.tail=e.prev;else throw Error("item doesn't belong to list");return e.prev=null,e.next=null,e}push(e){this.insert(be(e),null)}pop(){if(this.tail===null)return null;return this.remove(this.tail)}unshift(e){this.prependData(e)}shift(){if(this.head===null)return null;return this.remove(this.head)}prependList(e){return this.insertList(e,this.head)}appendList(e){return this.insertList(e,null)}insertList(e,t=null){if(e.head===null)return this;if(t!==null){if(this.updateCursors(t.prev,e.tail,t,e.head),t.prev!==null)t.prev.next=e.head,e.head.prev=t.prev;else this.head=e.head;t.prev=e.tail,e.tail.next=t}else{if(this.updateCursors(this.tail,e.tail,null,e.head),this.tail!==null)this.tail.next=e.head,e.head.prev=this.tail;else this.head=e.head;this.tail=e.tail}return e.head=null,e.tail=null,this}replace(e,t){if(t instanceof le)this.insertList(t,e),this.remove(e);else this.insert(t,e),this.remove(e)}}function Q(e){switch(e.type){case"StyleSheet":return oe(e.children,"");case"Rule":return`${Q(e.prelude)}{${Q(e.block)}}`;case"Block":return ku(e.children);case"Atrule":{let t=`@${e.name}`;if(e.prelude){let r=Q(e.prelude);if(r)t+=` ${r}`}if(e.block)t+=`{${Q(e.block)}}`;else t+=";";return t}case"AtrulePrelude":return oe(e.children,"");case"SelectorList":return oe(e.children,",");case"Selector":return oe(e.children,"");case"TypeSelector":return e.name;case"IdSelector":return`#${e.name}`;case"ClassSelector":return`.${e.name}`;case"NestingSelector":return"&";case"AttributeSelector":{let t=`[${e.name.name}`;if(e.matcher&&e.value)if(t+=e.matcher,e.value.type==="String")t+=`"${un(e.value.value)}"`;else t+=e.value.name;if(e.flags)t+=` ${e.flags}`;return t+="]",t}case"PseudoClassSelector":return e.children?`:${e.name}(${oe(e.children,"")})`:`:${e.name}`;case"PseudoElementSelector":return e.children?`::${e.name}(${oe(e.children,"")})`:`::${e.name}`;case"Combinator":return e.name===" "?" ":e.name;case"Declaration":return`${e.property}:${Q(e.value)}${e.important?"!important":""}`;case"DeclarationList":return oe(e.children,";");case"Value":return oe(e.children,"");case"Identifier":return e.name;case"Number":return e.value;case"Percentage":return`${e.value}%`;case"Dimension":return e.value+e.unit;case"String":return`"${un(e.value)}"`;case"Url":return/[\s"'()\\\u0000-\u001F\u007F]/.test(e.value)?`url("${un(e.value)}")`:`url(${e.value})`;case"Hash":return`#${e.name}`;case"Operator":return e.value;case"Function":return`${e.name}(${oe(e.children,"")})`;case"Parentheses":return`(${oe(e.children,"")})`;case"Brackets":return`[${oe(e.children,"")}]`;case"Raw":return e.value;case"Comment":return e.value.startsWith("!")?`/*${e.value}*/`:"";case"WhiteSpace":return" ";case"CDO":return"<!--";case"CDC":return"-->";case"AnPlusB":{let t=e.a??"",r=e.b??"";if(t&&r){let n=Number(r);return`${t==="1"?"":t==="-1"?"-":t}n${n>=0?`+${r}`:r}`}if(t)return`${t==="1"?"":t==="-1"?"-":t}n`;return r}case"Ratio":return`${e.left.value}/${e.right.value}`;case"UnicodeRange":return e.value;case"Nth":return e.selector?`${Q(e.nth)} of ${Q(e.selector)}`:Q(e.nth);case"MediaQueryList":return oe(e.children,",");case"MediaQuery":return oe(e.children,"");case"MediaFeature":{let t=`(${e.name}`;if(e.value)t+=`:${Q(e.value)}`;return t+=")",t}}return""}function oe(e,t){let r="",n=!0,i=null,o=e.head;while(o!=null){let s=o.data;if(s.type==="WhiteSpace"){let a=o.next?o.next.data:null;if(Ji(i)||Ji(a)){o=o.next;continue}}let l=Q(s);if(!l){o=o.next;continue}if(!n&&t&&!Au(i))r+=t;n=!1,r+=l,i=s,o=o.next}return r}function ku(e){let t="",r=null,n=e.head;while(n!=null){let i=n.data,o=Q(i);if(!o){n=n.next;continue}if(r&&Su(r,i))t+=";";t+=o,r=i,n=n.next}return t}function Su(e,t){return e.type==="Declaration"&&t.type!=="Comment"}function Ji(e){if(!e||e.type!=="Operator")return!1;let t=e.value;return t===":"||t===","||t==="/"}function Au(e){if(!e)return!1;return e.type==="Operator"||e.type==="Combinator"}function un(e){let t="";for(let r=0;r<e.length;r++){let n=e.charCodeAt(r);if(n===92)t+="\\\\";else if(n===34)t+="\\\"";else if(n<32||n===127){let i=n.toString(16),o=r+1<e.length?e.charCodeAt(r+1):-1,s=o===32||o===9||o===10||o===12||o===13||o>=48&&o<=57||o>=65&&o<=70||o>=97&&o<=102;t+=`\\${i}${s?" ":""}`}else t+=e[r]}return t}var We=(()=>{let e=new Uint8Array(128);for(let t=0;t<128;t++){let r=0;if(t===32||t===9||t===10||t===12||t===13)r|=1;if(t>=48&&t<=57)r|=2;if(t>=48&&t<=57||t>=65&&t<=70||t>=97&&t<=102)r|=4;if(t>=65&&t<=90||t>=97&&t<=122||t===95)r|=8;if(t===10||t===12||t===13)r|=16;e[t]=r}return e})();function fe(e){return e<128&&(We[e]&2)!==0}function Rt(e){return e<128&&(We[e]&4)!==0}function Xi(e){return e>=128||e<128&&(We[e]&8)!==0}function Eu(e){return e===45||e>=128||e<128&&(We[e]&10)!==0}function Tu(e){return e>=0&&e<=8||e===11||e>=14&&e<=31||e===127}function dn(e){return e<128&&(We[e]&16)!==0}function Re(e){return e<128&&(We[e]&1)!==0}function Ve(e,t){if(e!==92)return!1;if(dn(t))return!1;return!0}function fn(e,t,r){if(e===45)return Xi(t)||t===45||Ve(t,r);if(Xi(e))return!0;if(e===92)return Ve(e,t);return!1}function Nu(e,t,r){if(e===43||e===45){if(fe(t))return!0;if(t===46&&fe(r))return!0;return!1}if(e===46)return fe(t);return fe(e)}class Bt{source;offset=0;types;starts;ends;count=0;_tokens=null;_lineStarts=null;constructor(e){this.source=e;let t=Math.max(64,Math.ceil(e.length/3));this.types=new Uint8Array(t),this.starts=new Uint32Array(t),this.ends=new Uint32Array(t),this.tokenize()}get lineStarts(){if(this._lineStarts==null)this._lineStarts=Ou(this.source);return this._lineStarts}get tokens(){if(this._tokens!=null)return this._tokens;let e=Array.from({length:this.count});for(let t=0;t<this.count;t++)e[t]={type:this.types[t],start:this.starts[t],end:this.ends[t]};return this._tokens=e,e}addToken(e,t,r){if(this.count>=this.types.length)this.grow();this.types[this.count]=e,this.starts[this.count]=t,this.ends[this.count]=r,this.count++}grow(){let t=this.types.length*2,r=new Uint8Array(t);r.set(this.types),this.types=r;let n=new Uint32Array(t);n.set(this.starts),this.starts=n;let i=new Uint32Array(t);i.set(this.ends),this.ends=i}tokenize(){let e=this.source,t=0,r=e.length;while(t<r){let n=e.charCodeAt(t);if(n===47&&e.charCodeAt(t+1)===42){let s=t;t+=2;while(t<r&&!(e.charCodeAt(t)===42&&e.charCodeAt(t+1)===47))t++;t=t<r?t+2:r,this.addToken(25,s,t);continue}if(Re(n)){let s=t;while(t<r&&Re(e.charCodeAt(t)))t++;this.addToken(13,s,t);continue}if(n===34||n===39){t=this.consumeString(n,t);continue}if(n===35){if(t+1<r&&(Eu(e.charCodeAt(t+1))||Ve(e.charCodeAt(t+1),e.charCodeAt(t+2)))){let s=t;t++,t=this.consumeName(t),this.addToken(4,s,t);continue}this.addToken(9,t,t+1),t++;continue}switch(n){case 40:this.addToken(21,t,t+1),t++;continue;case 41:this.addToken(22,t,t+1),t++;continue;case 91:this.addToken(19,t,t+1),t++;continue;case 93:this.addToken(20,t,t+1),t++;continue;case 123:this.addToken(23,t,t+1),t++;continue;case 125:this.addToken(24,t,t+1),t++;continue;case 44:this.addToken(18,t,t+1),t++;continue;case 58:this.addToken(16,t,t+1),t++;continue;case 59:this.addToken(17,t,t+1),t++;continue}if(n===60&&e.startsWith("!--",t+1)){this.addToken(14,t,t+4),t+=4;continue}if(n===45&&e.startsWith("->",t+1)){this.addToken(15,t,t+3),t+=3;continue}if(n===64){let s=e.charCodeAt(t+1),l=e.charCodeAt(t+2),a=e.charCodeAt(t+3);if(fn(s,l,a)){let c=t;t++,t=this.consumeName(t),this.addToken(3,c,t);continue}this.addToken(9,t,t+1),t++;continue}let i=e.charCodeAt(t+1),o=e.charCodeAt(t+2);if(Nu(n,i,o)){t=this.consumeNumeric(t);continue}if(fn(n,i,o)){t=this.consumeIdentLike(t);continue}if(n===92){if(Ve(n,i)){t=this.consumeIdentLike(t);continue}this.addToken(9,t,t+1),t++;continue}this.addToken(9,t,t+1),t++}this.addToken(0,r,r)}consumeString(e,t){let r=this.source,n=r.length,i=t+1;while(i<n){let o=r.charCodeAt(i);if(o===e)return i++,this.addToken(5,t,i),i;if(dn(o))return this.addToken(6,t,i),i;if(o===92){let s=r.charCodeAt(i+1);if(dn(s)){i+=2;continue}if(i+1<n){i=this.consumeEscapeSkip(i+1);continue}}i++}return this.addToken(5,t,i),i}consumeEscapeSkip(e){let t=this.source;if(e>=t.length)return e;let r=t.charCodeAt(e);if(Rt(r)){let n=1;e++;while(n<6&&e<t.length&&Rt(t.charCodeAt(e)))e++,n++;if(e<t.length&&Re(t.charCodeAt(e)))e++;return e}return e+1}consumeName(e){let t=this.source,r=t.length,n=e;while(n<r){let i=t.charCodeAt(n);if(i<128&&(We[i]&10)!==0){n++;continue}if(i===45){n++;continue}if(i>=128){n++;continue}if(i===92&&Ve(i,t.charCodeAt(n+1))){n=this.consumeEscapeSkip(n+1);continue}break}return n}consumeNumber(e){let t=this.source,r=e;if(t.charCodeAt(r)===43||t.charCodeAt(r)===45)r++;while(r<t.length&&fe(t.charCodeAt(r)))r++;if(t.charCodeAt(r)===46&&fe(t.charCodeAt(r+1))){r+=2;while(r<t.length&&fe(t.charCodeAt(r)))r++}let n=t.charCodeAt(r);if(n===69||n===101){let i=t.charCodeAt(r+1),o=t.charCodeAt(r+2);if(fe(i)){r+=2;while(r<t.length&&fe(t.charCodeAt(r)))r++}else if((i===43||i===45)&&fe(o)){r+=3;while(r<t.length&&fe(t.charCodeAt(r)))r++}}return r}consumeNumeric(e){let t=this.source,r=this.consumeNumber(e),n=t.charCodeAt(r),i=t.charCodeAt(r+1),o=t.charCodeAt(r+2);if(fn(n,i,o)){let s=this.consumeName(r);return this.addToken(12,e,s),s}if(n===37)return this.addToken(11,e,r+1),r+1;return this.addToken(10,e,r),r}consumeIdentLike(e){let t=this.source,r=this.consumeName(e),n=t.charCodeAt(r);if(n===40&&r-e===3){let i=t.charCodeAt(e)|32,o=t.charCodeAt(e+1)|32,s=t.charCodeAt(e+2)|32;if(i===117&&o===114&&s===108){let l=r+1;while(l<t.length&&Re(t.charCodeAt(l)))l++;let a=t.charCodeAt(l);if(a===34||a===39)return this.addToken(2,e,r+1),r+1;return this.consumeUrl(e,r)}}if(n===40)return this.addToken(2,e,r+1),r+1;return this.addToken(1,e,r),r}consumeUrl(e,t){let r=this.source,n=r.length,i=t+1;while(i<n&&Re(r.charCodeAt(i)))i++;while(i<n){let o=r.charCodeAt(i);if(o===41)return i++,this.addToken(7,e,i),i;if(Re(o)){let s=i;while(i<n&&Re(r.charCodeAt(i)))i++;if(i>=n)return this.addToken(7,e,i),i;if(r.charCodeAt(i)===41)return i++,this.addToken(7,e,i),i;return this.consumeBadUrl(e,s)}if(o===34||o===39||o===40||Tu(o))return this.consumeBadUrl(e,i);if(o===92){if(Ve(o,r.charCodeAt(i+1))){i=this.consumeEscapeSkip(i+1);continue}return this.consumeBadUrl(e,i)}i++}return this.addToken(7,e,i),i}consumeBadUrl(e,t){let r=this.source,n=t;while(n<r.length){let i=r.charCodeAt(n);if(i===41){n++;break}if(i===92&&Ve(i,r.charCodeAt(n+1))){n=this.consumeEscapeSkip(n+1);continue}n++}return this.addToken(8,e,n),n}locate(e){let t=this.lineStarts,r=0,n=t.length-1;while(r<n){let o=r+n+1>>1;if(t[o]<=e)r=o;else n=o-1}let i=t[r];return{line:r+1,column:e-i+1}}}function Ou(e){let t=[0],r=e.length;for(let n=0;n<r;n++){let i=e.charCodeAt(n);if(i===10)t.push(n+1);else if(i===13){if(e.charCodeAt(n+1)!==10)t.push(n+1)}}return t}function hn(e,t,r){for(let n=t;n<r;n++)if(e.charCodeAt(n)===92)return Iu(e,t,r,n);return e.slice(t,r)}function Iu(e,t,r,n){let i=e.slice(t,n),o=n;while(o<r){if(e.charCodeAt(o)!==92){i+=e[o],o++;continue}if(o+1>=r){o++;continue}let l=e.charCodeAt(o+1);if(l===10){o+=2;continue}if(l===13){o+=e.charCodeAt(o+2)===10?3:2;continue}if(Rt(l)){let a=o+1,c="";while(c.length<6&&a<r&&Rt(e.charCodeAt(a)))c+=e[a],a++;let u=Number.parseInt(c,16);if(a<r&&Re(e.charCodeAt(a)))a++;i+=u===0||u>=55296&&u<=57343||u>1114111?String.fromCodePoint(65533):String.fromCodePoint(u),o=a;continue}i+=e[o+1],o+=2}return i}function gn(e,t,r){for(let n=t;n<r;n++)if(e.charCodeAt(n)===92)return Pu(e,t,r,n);return e.slice(t,r)}function Pu(e,t,r,n){let i=e.slice(t,n),o=n;while(o<r){if(e.charCodeAt(o)!==92){i+=e[o],o++;continue}let l=o+1,a="";while(a.length<6&&l<r&&Rt(e.charCodeAt(l)))a+=e[l],l++;if(a.length>0){let c=Number.parseInt(a,16);if(l<r&&Re(e.charCodeAt(l)))l++;i+=c===0||c>=55296&&c<=57343||c>1114111?String.fromCodePoint(65533):String.fromCodePoint(c),o=l;continue}if(l<r){i+=e[l],o=l+1;continue}i+=String.fromCodePoint(65533),o=l}return i}function io(e,t){let r=new Bt(e);return{source:e,types:r.types,starts:r.starts,ends:r.ends,count:r.count,end:r.count,pos:0,positions:t.positions??!1,filename:t.filename,parseValue:t.parseValue??!0,parseAtrulePrelude:t.parseAtrulePrelude??!0,parseCustomProperty:t.parseCustomProperty??!1,parseRulePrelude:t.parseRulePrelude??!0,onParseError:t.onParseError,tokenizer:r}}function x(e){return e.pos<e.end?e.types[e.pos]:0}function w(e){let t=e.pos;if(t>=e.end)return{type:0,start:e.starts[t]??e.source.length,end:e.ends[t]??e.source.length};return{type:e.types[t],start:e.starts[t],end:e.ends[t]}}function C(e){let t=e.pos++;if(t>=e.end)return{type:0,start:e.starts[t]??e.source.length,end:e.ends[t]??e.source.length};return{type:e.types[t],start:e.starts[t],end:e.ends[t]}}function xe(e,t){return e.source.slice(t.start,t.end)}function de(e){let{types:t,end:r}=e;while(e.pos<r){let n=t[e.pos];if(n===13||n===25)e.pos++;else break}}function Zi(e){let{types:t,end:r}=e;while(e.pos<r&&t[e.pos]===13)e.pos++}function k(e,t,r){if(!e.positions)return null;let n=e.tokenizer.locate(t.start),i=e.tokenizer.locate(r.end);return{source:e.filename??"<unknown>",start:{offset:t.start,line:n.line,column:n.column},end:{offset:r.end,line:i.line,column:i.column}}}function oo(e){if(!e.positions)return null;let t=w(e),r=e.tokenizer.locate(t.start);return{source:e.filename??"<unknown>",start:{offset:t.start,line:r.line,column:r.column},end:{offset:t.start,line:r.line,column:r.column}}}function Ut(e,t,r,n){return{type:"Raw",value:e,loc:k(n,t,r)}}function te(){return new le}function mn(e,t,r,n){if(e.onParseError){let{line:i,column:o}=e.tokenizer.locate(r.start),s=SyntaxError(`${e.filename??"<input>"}:${i}:${o}: ${t}`);s.line=i,s.column=o,s.offset=r.start,e.onParseError(s,n)}return n}function Wt(e,t={}){let r=io(e,t);switch(t.context??"stylesheet"){case"stylesheet":return to(r);case"atrule":return zt(r)??Qi(r);case"atrulePrelude":return Fu(r);case"mediaQuery":case"mediaQueryList":return eo(r);case"rule":return yn(r);case"selectorList":return vn(r);case"selector":return co(r);case"block":return bn(r);case"declarationList":return Bu(r);case"declaration":return xn(r)??Qi(r);case"value":return Uu(r);case"raw":return eo(r);default:return to(r)}}function Qi(e){return{type:"StyleSheet",children:te(),loc:oo(e)}}function eo(e){let t=w(e),r=t;while(x(e)!==0)r=C(e);return{type:"Raw",value:e.source.slice(t.start,r.end),loc:k(e,t,r)}}function to(e){let t=w(e),r=te(),{types:n,end:i}=e;while(e.pos<i){let l=n[e.pos];if(l===13){e.pos++;continue}if(l===25){let u={type:25,start:e.starts[e.pos],end:e.ends[e.pos]},f=pn(e,u);e.pos++,r.appendData(f);continue}if(l===0)break;if(l===14||l===15){e.pos++;continue}if(l===3){let u=zt(e);if(u)r.appendData(u);continue}if(l===24){e.pos++;continue}let a=e.pos,c=yn(e);if(r.appendData(c),e.pos===a)e.pos++}let o=e.end-1,s=o>=0?{type:e.types[o],start:e.starts[o],end:e.ends[o]}:{type:0,start:0,end:0};return{type:"StyleSheet",children:r,loc:k(e,t,s)}}function pn(e,t){return{type:"Comment",value:e.source.slice(t.start+2,t.end-2),loc:k(e,t,t)}}function zt(e){let t=w(e);if(t.type!==3)return null;e.pos++;let r=Vt(e.source,t.start+1,t.end);de(e);let n=e.pos,i=w(e),{types:o,end:s}=e,l=n,a=n;while(l<s){let f=o[l];if(f===0||f===17||f===23)break;if(f!==13&&f!==25)a=l+1;l++}let c=null;if(a>n){let f=e.starts[n],d=e.ends[a-1],h={type:o[a-1],start:e.starts[a-1],end:d},g=e.source.slice(f,d).trim();if(g.length>0)if(e.parseAtrulePrelude)try{let m=e.end;e.end=a,e.pos=n;let p=te();while(x(e)!==0){let y=ze(e);if(y)p.appendData(y)}if(ao(p),e.end=m,e.pos=l,p.isEmpty)c=Ut(g,i,h,e);else c={type:"AtrulePrelude",children:p,loc:null}}catch(m){let p=Ut(g,i,h,e);mn(e,`Failed to parse @${r} prelude: ${m.message}`,i,p),c=p,e.pos=l}else c=Ut(g,i,h,e),e.pos=l;else e.pos=l}else e.pos=l;let u=null;if(x(e)===17)C(e);else if(x(e)===23)u=bn(e,Mu.has(r));return{type:"Atrule",name:r,prelude:c,block:u,loc:k(e,t,w(e))}}var Lu=new Set(["is","not","where","has","matches","-moz-any","-webkit-any"]),Mu=new Set(["media","supports","document","layer","container","scope","starting-style","-moz-document","keyframes","-webkit-keyframes","-moz-keyframes","-o-keyframes"]);function Fu(e){let t=w(e),r=te();while(x(e)!==0){if(w(e).type===13){e.pos++;continue}let i=ze(e);if(i)r.appendData(i)}return{type:"AtrulePrelude",children:r,loc:k(e,t,w(e))}}function yn(e){let t=w(e),r;if(e.parseRulePrelude)r=vn(e);else{let i=w(e),o=i;while(x(e)!==0&&x(e)!==23)o=C(e);let s=e.source.slice(i.start,o.end).trim();r=Ut(s,i,o,e)}let n=bn(e,!0);return{type:"Rule",prelude:r,block:n,loc:k(e,t,w(e))}}function bn(e,t=!1){let r=w(e);if(x(e)!==23)return{type:"Block",children:te(),loc:oo(e)};e.pos++;let n=te(),{types:i,end:o}=e;while(e.pos<o){let s=i[e.pos];if(s===24||s===0)break;if(s===13){e.pos++;continue}if(s===25){let a={type:25,start:e.starts[e.pos],end:e.ends[e.pos]};e.pos++,n.appendData(pn(e,a));continue}if(s===3){let a=zt(e);if(a)n.appendData(a);continue}if(t&&ju(e,Du)){let a=yn(e);n.appendData(a);continue}let l=xn(e);if(l)n.appendData(l);if(e.pos<o&&i[e.pos]===17)e.pos++}if(x(e)===24)e.pos++;return{type:"Block",children:n,loc:k(e,r,w(e))}}function ju(e,t){let r=e.pos,n=t(e);return e.pos=r,n}function Du(e){let{types:t,end:r}=e;while(e.pos<r){let n=t[e.pos];if(n===23)return!0;if(n===17||n===24||n===0)return!1;e.pos++}return!1}function Bu(e){let t=w(e),r=te();while(x(e)!==0&&x(e)!==24){let n=w(e);if(n.type===13){e.pos++;continue}if(n.type===25){r.appendData(pn(e,C(e)));continue}if(n.type===17){e.pos++;continue}if(n.type===3){let o=zt(e);if(o)r.appendData(o);continue}let i=xn(e);if(i)r.appendData(i);if(x(e)===17)C(e)}return{type:"DeclarationList",children:r,loc:k(e,t,w(e))}}function xn(e){de(e);let t=w(e);if(t.type!==1&&t.type!==4&&!(t.type===9&&e.source[t.start]==="*"&&e.source[t.start+1]===" "))if(t.type===9&&e.source[t.start]==="*")e.pos++;else{mn(e,"Expected property name",t,{type:"Raw",value:"",loc:null});let{types:S,end:j}=e;while(e.pos<j){let K=S[e.pos];if(K===0||K===17||K===24)break;e.pos++}return null}let r=e.starts[e.pos],n=e.ends[e.pos];e.pos++;let i=e.source.slice(r,n);if(Zi(e),x(e)!==16){mn(e,`Expected ':' after property "${i}"`,w(e),{type:"Raw",value:"",loc:null});let{types:S,end:j}=e;while(e.pos<j){let K=S[e.pos];if(K===0||K===17||K===24)break;e.pos++}return null}e.pos++,Zi(e);let{types:o,starts:s,end:l,pos:a}=e,c=a,u=a,f=-1,d=-1;while(c<l){let S=o[c];if(S===0||S===17||S===24)break;if(S===9&&e.source.charCodeAt(s[c])===33){let j=c+1;while(j<l&&o[j]===13)j++;if(j<l&&o[j]===1){let K=s[j];if(e.ends[j]-K===9&&(e.source.charCodeAt(K)|32)===105&&(e.source.charCodeAt(K+1)|32)===109&&(e.source.charCodeAt(K+2)|32)===112&&(e.source.charCodeAt(K+3)|32)===111&&(e.source.charCodeAt(K+4)|32)===114&&(e.source.charCodeAt(K+5)|32)===116&&(e.source.charCodeAt(K+6)|32)===97&&(e.source.charCodeAt(K+7)|32)===110&&(e.source.charCodeAt(K+8)|32)===116){d=c,f=j,c=j+1;continue}}}if(S!==13&&S!==25)u=c+1;c++}let h=u,g=f>=0?{type:1,start:s[f],end:e.ends[f]}:null,m=i.startsWith("--"),p,y=s[a],b=h>a?e.ends[h-1]:y,v={type:o[a],start:y,end:e.ends[a]},R=h>a?{type:o[h-1],start:s[h-1],end:b}:v;if(m&&!e.parseCustomProperty||!e.parseValue)p={type:"Raw",value:e.source.slice(y,b).trim(),loc:k(e,v,R)};else if(h===a)p={type:"Value",children:te(),loc:k(e,v,R)};else{let S=e.end;e.end=h,e.pos=a,p=so(e),e.end=S}return e.pos=c,{type:"Declaration",property:i,important:g?!0:!1,value:p,loc:k(e,t,w(e))}}function Uu(e){return so(e)}function so(e){let t=w(e),r=te();while(x(e)!==0&&x(e)!==17&&x(e)!==24&&x(e)!==22&&x(e)!==20){let n=ze(e);if(n)r.appendData(n)}return lo(r),{type:"Value",children:r,loc:k(e,t,w(e))}}function ao(e){for(let t of e)if("children"in t&&t.children instanceof le)ao(t.children);lo(e)}function lo(e){let t=e.head;while(t){if(t.data.type==="Number"){let r=t.next;while(r&&r.data.type==="WhiteSpace")r=r.next;if(r&&r.data.type==="Operator"&&r.data.value==="/"){let n=r.next;while(n&&n.data.type==="WhiteSpace")n=n.next;if(n&&n.data.type==="Number"){let i={type:"Ratio",left:t.data,right:n.data,loc:null},o=t.next;while(o&&o!==n.next){let s=o.next;e.remove(o),o=s}e.replace(t,e.createItem(i)),t=e.head;continue}}}t=t.next}}function ze(e){let t=e.pos;if(t>=e.end)return null;let r=e.types[t],n=e.starts[t],i=e.ends[t],o=e.source;switch(r){case 13:return e.pos++,e.positions?{type:"WhiteSpace",value:" ",loc:ee(e,n,i)}:{type:"WhiteSpace",value:" ",loc:null};case 25:return e.pos++,{type:"Comment",value:o.slice(n+2,i-2),loc:e.positions?ee(e,n,i):null};case 10:return e.pos++,{type:"Number",value:o.slice(n,i),loc:e.positions?ee(e,n,i):null};case 11:return e.pos++,{type:"Percentage",value:o.slice(n,i-1),loc:e.positions?ee(e,n,i):null};case 12:{e.pos++;let s=n,l=o.charCodeAt(s);if(l===43||l===45)s++;let a=!1;while(s<i){let u=o.charCodeAt(s);if(u>=48&&u<=57){s++;continue}if(u===46&&!a){a=!0,s++;continue}break}let c=o.charCodeAt(s);if(c===69||c===101){let u=s+1,f=o.charCodeAt(u);if(f===43||f===45)u++;let d=!1;while(u<i){let h=o.charCodeAt(u);if(h>=48&&h<=57){u++,d=!0;continue}break}if(d)s=u}return{type:"Dimension",value:o.slice(n,s),unit:o.slice(s,i),loc:e.positions?ee(e,n,i):null}}case 1:return e.pos++,{type:"Identifier",name:gn(o,n,i),loc:e.positions?ee(e,n,i):null};case 5:{e.pos++;let s=n+1,a=i-n>=2&&o.charCodeAt(i-1)===o.charCodeAt(n)?i-1:i;return{type:"String",value:hn(o,s,a),loc:e.positions?ee(e,n,i):null}}case 7:{e.pos++;let s=n+4;while(s<i&&ro(o.charCodeAt(s)))s++;let l=i;if(l>s&&o.charCodeAt(l-1)===41)l--;while(l>s&&ro(o.charCodeAt(l-1)))l--;let a;if(l-s>=2){let c=o.charCodeAt(s),u=o.charCodeAt(l-1);if((c===34||c===39)&&c===u)a=o.slice(s+1,l-1);else a=o.slice(s,l)}else a=o.slice(s,l);return{type:"Url",value:a,loc:e.positions?ee(e,n,i):null}}case 4:return e.pos++,{type:"Hash",name:o.slice(n+1,i),loc:e.positions?ee(e,n,i):null};case 2:return Wu(e);case 21:return zu(e);case 18:return e.pos++,{type:"Operator",value:",",loc:e.positions?ee(e,n,i):null};case 16:return e.pos++,{type:"Operator",value:":",loc:e.positions?ee(e,n,i):null};case 9:{e.pos++;let s=o.charCodeAt(n),l=o[n];if(Vu(s))return{type:"Operator",value:l,loc:e.positions?ee(e,n,i):null};return{type:"Identifier",name:l,loc:e.positions?ee(e,n,i):null}}case 19:{e.pos++;let s=te();while(x(e)!==0&&x(e)!==20){let a=ze(e);if(a)s.appendData(a)}let l=e.pos<e.end?e.ends[e.pos]:i;if(x(e)===20)e.pos++;return{type:"Brackets",children:s,loc:e.positions?ee(e,n,l):null}}case 3:case 23:case 24:case 22:case 20:case 17:case 0:case 14:case 15:case 6:case 8:return e.pos++,{type:"Raw",value:o.slice(n,i),loc:e.positions?ee(e,n,i):null}}return e.pos++,null}function ro(e){return e===32||e===9||e===10||e===12||e===13}function Vu(e){return e===47||e===43||e===45||e===42||e===61||e===62||e===60||e===126||e===124||e===36||e===94||e===33||e===38}function Vt(e,t,r){for(let n=t;n<r;n++){let i=e.charCodeAt(n);if(i>=65&&i<=90)return e.slice(t,r).toLowerCase()}return e.slice(t,r)}function ee(e,t,r){let n=e.tokenizer.locate(t),i=e.tokenizer.locate(r);return{source:e.filename??"<unknown>",start:{offset:t,line:n.line,column:n.column},end:{offset:r,line:i.line,column:i.column}}}function Wu(e){let t=C(e),r=Vt(e.source,t.start,t.end-1),n=te();while(x(e)!==0&&x(e)!==22){let i=ze(e);if(i)n.appendData(i)}if(x(e)===22)C(e);if(r==="url"){for(let i=n.head;i!=null;i=i.next)if(i.data.type==="String")return{type:"Url",value:i.data.value,loc:k(e,t,w(e))}}return{type:"Function",name:r,children:n,loc:k(e,t,w(e))}}function zu(e){let t=C(e),r=te();while(x(e)!==0&&x(e)!==22){let n=ze(e);if(n)r.appendData(n)}if(x(e)===22)C(e);return{type:"Parentheses",children:r,loc:k(e,t,w(e))}}function vn(e){let t=w(e),r=te();while(x(e)!==0){if(de(e),x(e)===0||x(e)===23)break;let n=co(e);if(n.children.head!==null)r.appendData(n);if(de(e),x(e)===18){C(e);continue}break}return{type:"SelectorList",children:r,loc:k(e,t,w(e))}}function co(e){let t=w(e),r=te(),n=!0;while(x(e)!==0&&x(e)!==18&&x(e)!==23){let i=w(e);if(i.type===13){if(C(e),!n&&x(e)!==0&&x(e)!==18&&x(e)!==23&&!no(e)&&!Ku(e)){let s={type:"Combinator",name:" ",loc:k(e,i,i)};r.appendData(s),n=!0}continue}if(i.type===9&&e.source.charCodeAt(i.start)===124&&e.types[e.pos+1]===9&&e.source.charCodeAt(e.starts[e.pos+1])===124){let s=w(e);C(e);let l=C(e),a={type:"Combinator",name:"||",loc:k(e,s,l)};r.appendData(a),n=!0,de(e);continue}if(no(e)){let s=C(e),a={type:"Combinator",name:e.source[s.start],loc:k(e,s,s)};r.appendData(a),n=!0,de(e);continue}let o=Gu(e);if(!o)break;r.appendData(o),n=!1}while(r.tail&&r.tail.data.type==="Combinator")r.remove(r.tail);return{type:"Selector",children:r,loc:k(e,t,w(e))}}function no(e){let t=w(e);if(t.type!==9)return!1;let r=e.source[t.start];return r===">"||r==="+"||r==="~"}function Ku(e){if(e.types[e.pos]!==9)return!1;if(e.source.charCodeAt(e.starts[e.pos])!==124)return!1;if(e.types[e.pos+1]!==9)return!1;return e.source.charCodeAt(e.starts[e.pos+1])===124}function Gu(e){let t=w(e);switch(t.type){case 1:{if(C(e),x(e)===9&&e.source[w(e).start]==="|"&&e.source[w(e).start+1]!=="="&&!(e.types[e.pos+1]===9&&e.source.charCodeAt(e.starts[e.pos+1])===124)){if(C(e),x(e)===1){let n=C(e);return{type:"TypeSelector",name:`${xe(e,t)}|${xe(e,n)}`,loc:k(e,t,n)}}if(x(e)===9&&e.source[w(e).start]==="*"){let n=C(e);return{type:"TypeSelector",name:`${xe(e,t)}|*`,loc:k(e,t,n)}}}return{type:"TypeSelector",name:xe(e,t),loc:k(e,t,t)}}case 11:return C(e),{type:"TypeSelector",name:xe(e,t),loc:k(e,t,t)};case 10:return C(e),{type:"TypeSelector",name:xe(e,t),loc:k(e,t,t)};case 9:{let r=e.source[t.start];if(r==="*")return C(e),{type:"TypeSelector",name:"*",loc:k(e,t,t)};if(r==="."){if(C(e),x(e)===1){let n=C(e);return{type:"ClassSelector",name:xe(e,n),loc:k(e,t,n)}}return null}if(r==="&")return C(e),{type:"NestingSelector",loc:k(e,t,t)};return C(e),null}case 4:return C(e),{type:"IdSelector",name:e.source.slice(t.start+1,t.end),loc:k(e,t,t)};case 16:{C(e);let r=x(e)===16;if(r)C(e);return Hu(e,r,t)}case 19:return qu(e)}return null}function Hu(e,t,r){let n=w(e);if(n.type===1){C(e);let i=Vt(e.source,n.start,n.end);return t?{type:"PseudoElementSelector",name:i,children:null,loc:k(e,r,n)}:{type:"PseudoClassSelector",name:i,children:null,loc:k(e,r,n)}}if(n.type===2){C(e);let i=Vt(e.source,n.start,n.end-1),o=te();if(!t&&Lu.has(i)){let a=w(e),c=a,u=1;while(x(e)!==0&&u>0){if(x(e)===21||x(e)===2)u++;else if(x(e)===22){if(u--,u===0)break}c=C(e)}if(x(e)===22)C(e);let f=e.source.slice(a.start,c.end).trim();if(f.length>0){let d=io(f,{positions:!1}),h=vn(d);o.appendData(h)}}else{while(x(e)!==0&&x(e)!==22){let a=ze(e);if(a)o.appendData(a)}if(x(e)===22)C(e)}if(t)return{type:"PseudoElementSelector",name:i,children:o,loc:k(e,r,w(e))};return{type:"PseudoClassSelector",name:i,children:o,loc:k(e,r,w(e))}}return null}function qu(e){let t=C(e);de(e);let r=w(e);if(r.type!==1)return null;C(e);let n={type:"Identifier",name:xe(e,r),loc:k(e,r,r)};de(e);let i=null,o=null,s=null,l=w(e);if(l.type===9){let c=e.source[l.start],u=e.source[l.start+1];if(c==="=")i="=",C(e);else if((c==="~"||c==="|"||c==="^"||c==="$"||c==="*")&&u==="="){C(e);let h=w(e);if(h.type===9&&e.source[h.start]==="=")C(e),i=`${c}=`}de(e);let f=w(e);if(f.type===5){C(e);let h=f.end-f.start>=2&&e.source.charCodeAt(f.end-1)===e.source.charCodeAt(f.start);o={type:"String",value:hn(e.source,f.start+1,h?f.end-1:f.end),loc:k(e,f,f)}}else if(f.type===1)C(e),o={type:"Identifier",name:xe(e,f),loc:k(e,f,f)};de(e);let d=w(e);if(d.type===1)C(e),s=xe(e,d)}de(e);let a=w(e);if(x(e)===20)a=C(e);return{type:"AttributeSelector",name:n,matcher:i,value:o,flags:s,loc:k(e,t,a)}}var uo=Symbol("walkSkip"),U=Symbol("walkStop");function Yu(e){return{root:e,stylesheet:null,atrule:null,atrulePrelude:null,rule:null,selector:null,block:null,declaration:null,function:null}}function Ju(e,t){let r=Yu(e),n=typeof t==="function"?t:t.enter,i=typeof t==="function"?null:t.leave??null,o=typeof t==="function"?null:t.visit??null,s=typeof t==="function"?!1:t.reverse??!1;function l(a,c,u){let f=null,d;switch(a.type){case"StyleSheet":f="stylesheet",d=r.stylesheet,r.stylesheet=a;break;case"Atrule":f="atrule",d=r.atrule,r.atrule=a;break;case"AtrulePrelude":f="atrulePrelude",d=r.atrulePrelude,r.atrulePrelude=a;break;case"Rule":f="rule",d=r.rule,r.rule=a;break;case"Selector":f="selector",d=r.selector,r.selector=a;break;case"Block":f="block",d=r.block,r.block=a;break;case"Declaration":f="declaration",d=r.declaration,r.declaration=a;break;case"Function":f="function",d=r.function,r.function=a;break}let h;if((o===null||o===a.type)&&n){let g=n.call(r,a,c,u);if(g===uo){if(f)r[f]=d;return}if(g===U){if(f)r[f]=d;return U}}if(h=Xu(a,s,l),h===U){if(f)r[f]=d;return U}if((o===null||o===a.type)&&i){if(i.call(r,a,c,u)===U){if(f)r[f]=d;return U}}if(f)r[f]=d;return}return l(e,null,null)}var Ke=Object.assign(Ju,{skip:uo,stop:U});function Xu(e,t,r){if("children"in e&&e.children instanceof le)return Zu(e.children,t,r);if(e.type==="Rule"){if(r(e.prelude,null,null)===U)return U;if(r(e.block,null,null)===U)return U;return}if(e.type==="Atrule"){if(e.prelude){if(r(e.prelude,null,null)===U)return U}if(e.block){if(r(e.block,null,null)===U)return U}return}if(e.type==="Declaration")return r(e.value,null,null);if(e.type==="AttributeSelector"){if(r(e.name,null,null)===U)return U;if(e.value)return r(e.value,null,null);return}return}function Zu(e,t,r){let n;if(t)e.forEachRight((i,o,s)=>{if(n)return;if(r(i,o,s)===U)n=U});else e.forEach((i,o,s)=>{if(n)return;if(r(i,o,s)===U)n=U});return n}function et(e,t={}){let r=t.exclamation??!1,n=!1;Ke(e,(i,o,s)=>{if(i.type!=="Comment")return;let l=i.value.startsWith("!");if(r===!0&&l)return;if(r==="first-exclamation"&&l&&!n){n=!0;return}if(o&&s)s.remove(o)})}function Kt(e){Ke(e,(t)=>{if(t.type!=="Block"&&t.type!=="DeclarationList")return;if(!("children"in t)||!t.children)return;let r=t.children,n=r.head;if(n==null||n.next==null)return;let i=0;for(let l=n;l!=null;l=l.next)if(l.data.type==="Declaration"){if(i++,i>=2)break}if(i<2)return;let o=new Map,s=[];for(let l=n;l!=null;l=l.next){let a=l.data;if(a.type!=="Declaration")continue;let c=a.property,u=o.get(c);if(u){let f=!!u.decl.important,d=!!a.important;if(d||f===d)s.push(u.item),o.set(c,{item:l,decl:a});else s.push(l)}else o.set(c,{item:l,decl:a})}for(let l of s)r.remove(l)})}var Qu={black:"#000",fuchsia:"#f0f",white:"#fff",red:"#f00",cyan:"#0ff",blue:"#00f",yellow:"#ff0",magenta:"#f0f",lime:"#0f0",silver:"#c0c0c0",gray:"#808080",maroon:"#800000",olive:"#808000",green:"#008000",purple:"#800080",teal:"#008080",navy:"#000080"},ef={"#f00":"red","#ff0000":"red","#000080":"navy","#008080":"teal"};function $n(e){if(!e.startsWith("#"))return e;let t=e.slice(1);if(t.length===6){if(t[0]===t[1]&&t[2]===t[3]&&t[4]===t[5])return`#${t[0]}${t[2]}${t[4]}`}if(t.length===8){if(t[0]===t[1]&&t[2]===t[3]&&t[4]===t[5]&&t[6]===t[7])return`#${t[0]}${t[2]}${t[4]}${t[6]}`}return e}function fo(e){let t=e.toLowerCase();return Qu[t]??null}function ho(e){let t=e.toLowerCase();return ef[t]??null}function tf(e,t,r){let n=(e<<16|t<<8|r).toString(16).padStart(6,"0");return $n(`#${n}`)}var rf=/^rgba?\(\s*([+-]?\d*\.?\d+%?)\s*[,\s]\s*([+-]?\d*\.?\d+%?)\s*[,\s]\s*([+-]?\d*\.?\d+%?)\s*(?:[,/]\s*([+-]?\d*\.?\d+%?)\s*)?\)$/;function go(e){let t=rf.exec(e.trim());if(!t)return e;let r=wn(t[1]),n=wn(t[2]),i=wn(t[3]);if(t[4]!==void 0&&!nf(t[4]))return e;return tf(r,n,i)}function nf(e){if(e.endsWith("%"))return Number.parseFloat(e)>=100;return Number.parseFloat(e)>=1}function wn(e){if(e.endsWith("%"))return Math.max(0,Math.min(255,Math.round(Number.parseFloat(e)*2.55)));return Math.max(0,Math.min(255,Math.round(Number.parseFloat(e))))}var of=new Set(["px","pt","pc","in","cm","mm","q","em","rem","ex","ch","cap","ic","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"]);function Gt(e){if(e.charCodeAt(0)===43)e=e.slice(1);if(e.includes(".")){let t=e.replace(/(\.\d*?)0+($|[eE])/,"$1$2");t=t.replace(/\.($|[eE])/,"$1"),e=t}if(e.startsWith("0.")&&e.length>2)e=e.slice(1);else if(e.startsWith("-0.")&&e.length>3)e=`-${e.slice(2)}`;if(e==="-0"||e==="-.0"||e==="-0.0")e="0";return e}function mo(e,t){let r=Gt(e);if((r==="0"||r==="-0")&&of.has(t.toLowerCase()))return{value:"0",unit:""};return{value:r,unit:t}}function po(e){return Gt(e)}function yo(e,t){let r=Number.parseFloat(e);if(!Number.isFinite(r))return e;let n=t<0?0:t;return r.toFixed(n)}var bo=new Set(["color","background","background-color","border","border-color","border-top","border-top-color","border-right","border-right-color","border-bottom","border-bottom-color","border-left","border-left-color","border-block","border-block-color","border-block-start-color","border-block-end-color","border-inline","border-inline-color","border-inline-start-color","border-inline-end-color","outline","outline-color","caret-color","fill","stroke","flood-color","lighting-color","stop-color","column-rule","column-rule-color","text-decoration","text-decoration-color","text-emphasis","text-emphasis-color","text-shadow","box-shadow","accent-color","scrollbar-color"]);function xo(e){if(!e||e.type!=="Operator")return!1;let t=e.value;return t===":"||t===","||t==="/"}function sf(e){let t=e.children;if(!t)return;while(t.head&&t.head.data.type==="WhiteSpace")t.remove(t.head);while(t.tail&&t.tail.data.type==="WhiteSpace")t.remove(t.tail);let r=t.head;while(r){let n=r.next;if(r.data.type==="WhiteSpace"){let i=r.prev&&xo(r.prev.data),o=n&&xo(n.data);if(i||o)t.remove(r)}r=n}}function af(e){return e?.property.toLowerCase()==="unicode-range"}function Cn(e,t={}){let r=t.floatPrecision??null,n=r===null?null:(i)=>yo(i,r);Ke(e,{enter(i,o,s){if((i.type==="Number"||i.type==="Percentage"||i.type==="Dimension")&&af(this.declaration))return;switch(i.type){case"Number":{let l=n?n(i.value):i.value;i.value=Gt(l);return}case"Percentage":{let l=n?n(i.value):i.value;i.value=po(l);return}case"Dimension":{let l=n?n(i.value):i.value,a=mo(l,i.unit);i.value=a.value,i.unit=a.unit;return}case"Hash":{let l=$n(`#${i.name}`).slice(1);if(i.name=l,o&&s&&this.declaration&&bo.has(this.declaration.property.toLowerCase())){let a=ho(`#${l}`);if(a&&a.length<l.length+1){let c={type:"Identifier",name:a,loc:i.loc};s.replace(o,s.createItem(c))}}return}case"Identifier":{if(!o||!s||!this.declaration)return;if(!bo.has(this.declaration.property.toLowerCase()))return;let l=fo(i.name);if(l&&l.length<i.name.length){let a={type:"Hash",name:l.slice(1),loc:i.loc};s.replace(o,s.createItem(a))}return}case"Url":return;case"Function":{let l=i.name.toLowerCase();if((l==="rgb"||l==="rgba")&&o&&s)i.__rgbReplaceCandidate=!0}}},leave(i,o,s){if(i.type==="Parentheses"||i.type==="Function"||i.type==="Value")sf(i);if(i.type==="Function"&&i.__rgbReplaceCandidate&&o&&s){let l=Q(i),a=go(l);if(a!==l&&a.startsWith("#")){let c={type:"Hash",name:a.slice(1),loc:i.loc};s.replace(o,s.createItem(c))}}}})}function lf(e,t={}){let r=Wt(e,{context:"stylesheet"});return vo(r,t)}function Rn(e,t={}){let r=Wt(e,{context:"declarationList"});return vo(r,t)}function vo(e,t){if(t.comments===!1)et(e,{exclamation:!1});else if(t.comments==="first-exclamation")et(e,{exclamation:"first-exclamation"});else et(e,{exclamation:!0});return Cn(e,{floatPrecision:t.floatPrecision??null}),Kt(e),{css:Q(e),ast:e}}function Le(e,t,r){if(e.size>=1e4){let n=e.keys().next().value;if(n!==void 0)e.delete(n)}return e.set(t,r),r}var wo=new Map,_e=new Map;var kn={col:"col",row:"row",jc:"justify",ji:"justify-items",js:"justify-self",ai:"items",ac:"content",as:"self",wrap:"wrap",nowrap:"nowrap",c:"center",s:"start",e:"end",sb:"between",sa:"around",se:"evenly",st:"stretch",thin:"thin",extralight:"extralight",light:"light",normal:"normal",medium:"medium",semibold:"semibold",bold:"bold",extrabold:"extrabold",black:"black",t:"top",r:"right",b:"bottom",l:"left"},ff=/[%#()]/,df=/^\d+(?:\.\d+)?(?:px|rem|em|vh|vw|dvh|dvw|svh|svw|lvh|lvw|ch|ex|lh|cap|ic|rlh|vi|vb|vmin|vmax|cqw|cqh|cqi|cqb|cqmin|cqmax|cm|mm|in|pt|pc|Q)$/,Eo=["calc","min","max","clamp","mod","rem","sin","cos","tan","asin","acos","atan","atan2","pow","sqrt","hypot","log","exp","round"],hf=new Set(Eo);function se(e){return ff.test(e)||df.test(e)}function $o(e){if(!Eo.some((o)=>e.includes(`${o}(`)))return e;let t="",r=[],n=null,i=null;for(let o=0;o<e.length;o++){let s=e.charCodeAt(o);if(s>=48&&s<=57)n=o;else if(n!==null&&(s===37||s>=97&&s<=122||s>=65&&s<=90))n=o;else i=n,n=null;if(s===40){t+=e[o];let a=o;for(let u=o-1;u>=0;u--){let f=e.charCodeAt(u);if(f>=48&&f<=57||f>=97&&f<=122)a=u;else break}let c=e.slice(a,o);if(hf.has(c))r.unshift(!0);else if(r[0]&&c==="")r.unshift(!0);else r.unshift(!1);continue}if(s===41){t+=e[o],r.shift();continue}if(s===44&&r[0]){t+=", ";continue}if(s===32&&r[0]&&t.charCodeAt(t.length-1)===32)continue;if((s===43||s===45||s===42||s===47)&&r[0]){let a=t.trimEnd(),c=a.charCodeAt(a.length-1),u=a.charCodeAt(a.length-2),f=e.charCodeAt(o+1),d=c===43||c===45||c===42||c===47,h=f===43||f===45||f===42||f===47;if((c===101||c===69)&&u>=48&&u<=57)t+=e[o];else if(d||c===40||c===44)t+=e[o];else if(e.charCodeAt(o-1)===32)t+=`${e[o]} `;else if(c>=48&&c<=57||f>=48&&f<=57||c===41||f===40||h||i!==null&&i===o-1)t+=` ${e[o]} `;else t+=e[o];continue}t+=e[o]}return t}function Ht(e){if(!e.includes("_"))return $o(e);let t="",r=0;while(r<e.length){let n=e[r];if(n==="\\"&&e[r+1]==="_"){t+="_",r+=2;continue}if(n==="u"&&e.slice(r,r+4)==="url("){let i=r,o=1;r+=4;while(r<e.length&&o>0){if(e[r]==="(")o++;else if(e[r]===")")o--;r++}t+=e.slice(i,r);continue}t+=n==="_"?" ":n,r++}return $o(t)}function Co(e,t){if(t.length!==2)return null;let[r,n]=t;if(r!=="min"&&r!=="max")return null;return[se(n)?`${r}-${e}-[${n}]`:`${r}-${e}-${n}`]}var gf={flex:{expand:(e,t)=>{let r=t[e]||e;if(["col","row","col-reverse","row-reverse","wrap","nowrap","wrap-reverse"].includes(r))return`flex-${r}`;let n=e.match(/^(jc|ji|js|ai|ac|as)-(.+)$/);if(n){let i=t[n[1]]||n[1],o=t[n[2]]||n[2];return`${i}-${o}`}if(/^\d+$/.test(r)||["grow","shrink","auto","initial","none"].includes(r))return`flex-${r}`;return null}},grid:{expand:(e,t)=>{let r=t[e]||e;if(e.startsWith("cols-")||e.startsWith("rows-"))return`grid-${e}`;if(e.startsWith("flow-"))return`grid-${e}`;if(e.startsWith("gap-"))return e;return null}},text:{expand:(e,t)=>{let r=t[e]||e;if(se(r))return`text-[${r}]`;if(/^\d{3}$/.test(r))return{"100":"font-thin","200":"font-extralight","300":"font-light","400":"font-normal","500":"font-medium","600":"font-semibold","700":"font-bold","800":"font-extrabold","900":"font-black"}[r]||`font-[${r}]`;if(/^[a-z-]+$/i.test(r)&&!["xs","sm","base","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl","8xl","9xl"].includes(r)){if(["white","black","inherit","current","transparent"].includes(r.toLowerCase()))return`text-${r}`;if(["red","blue","green","yellow","purple","pink","gray","slate","zinc","neutral","stone","orange","amber","lime","emerald","teal","cyan","sky","indigo","violet","fuchsia","rose"].includes(r.toLowerCase()))return`text-${r}-500`;return`font-[${r}]`}return`text-${r}`}},font:{expand:(e,t)=>{let r=t[e]||e,n=["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],i=["sans","serif","mono"];if(n.includes(r)||i.includes(r))return`font-${r}`;if(/^\d{3}$/.test(r))return{"100":"font-thin","200":"font-extralight","300":"font-light","400":"font-normal","500":"font-medium","600":"font-semibold","700":"font-bold","800":"font-extrabold","900":"font-black"}[r]||`font-[${r}]`;return`font-[${r}]`}},bg:{expand:(e,t)=>`bg-${t[e]||e}`},w:{expand:(e,t)=>{let r=t[e]||e;if(se(r))return`w-[${r}]`;return`w-${r}`},multiValue:(e)=>Co("w",e)},h:{expand:(e,t)=>{let r=t[e]||e;if(se(r))return`h-[${r}]`;return`h-${r}`},multiValue:(e)=>Co("h",e)},p:{expand:(e)=>`p-${e}`},px:{expand:(e)=>`px-${e}`},py:{expand:(e)=>`py-${e}`},pt:{expand:(e)=>`pt-${e}`},pr:{expand:(e)=>`pr-${e}`},pb:{expand:(e)=>`pb-${e}`},pl:{expand:(e)=>`pl-${e}`},m:{expand:(e)=>`m-${e}`},mx:{expand:(e)=>`mx-${e}`},my:{expand:(e)=>`my-${e}`},mt:{expand:(e)=>`mt-${e}`},mr:{expand:(e)=>`mr-${e}`},mb:{expand:(e)=>`mb-${e}`},ml:{expand:(e)=>`ml-${e}`},scroll:{expand:(e)=>{if(["x","y"].includes(e))return null;if(["auto","hidden","scroll","visible"].includes(e))return`overflow-${e}`;return null},multiValue:(e)=>{if(e.length===2){let[t,r]=e;if(["x","y"].includes(t)&&["auto","hidden","scroll","visible"].includes(r))return[`overflow-${t}-${r}`]}return null}},overflow:{expand:(e)=>`overflow-${e}`,multiValue:(e)=>{if(e.length===2){let[t,r]=e;if(["x","y"].includes(t))return[`overflow-${t}-${r}`]}return null}},border:{expand:(e)=>`border-${e}`},rounded:{expand:(e)=>`rounded-${e}`},shadow:{expand:(e)=>`shadow-${e}`},gap:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-"))return`gap-${e}`;return`gap-${e}`}},space:{expand:(e)=>`space-${e}`},opacity:{expand:(e)=>`opacity-${e}`},z:{expand:(e)=>`z-${e}`},inset:{expand:(e,t)=>{let r=t[e]||e;if(r.startsWith("x-")||r.startsWith("y-"))return`inset-${r}`;if(se(r))return`inset-[${r}]`;return`inset-${r}`}},top:{expand:(e)=>se(e)?`top-[${e}]`:`top-${e}`},right:{expand:(e)=>se(e)?`right-[${e}]`:`right-${e}`},bottom:{expand:(e)=>se(e)?`bottom-[${e}]`:`bottom-${e}`},left:{expand:(e)=>se(e)?`left-[${e}]`:`left-${e}`},duration:{expand:(e)=>`duration-${e}`},delay:{expand:(e)=>`delay-${e}`},ease:{expand:(e)=>`ease-${e}`},transition:{expand:(e)=>{if(["all","none","colors","opacity","shadow","transform"].includes(e))return`transition-${e}`;if(/^\d+$/.test(e))return`duration-${e}`;if(["linear","in","out","in-out","ease-linear","ease-in","ease-out","ease-in-out"].includes(e))return e.startsWith("ease-")?e:`ease-${e}`;return`transition-${e}`}},translate:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-")||e.startsWith("z-"))return`translate-${e}`;return`translate-${e}`}},rotate:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-")||e.startsWith("z-"))return`rotate-${e}`;return`rotate-${e}`}},scale:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-")||e.startsWith("z-"))return`scale-${e}`;return`scale-${e}`}},skew:{expand:(e)=>{if(e.startsWith("x-")||e.startsWith("y-"))return`skew-${e}`;return`skew-${e}`}},origin:{expand:(e)=>`origin-${e}`},cursor:{expand:(e)=>`cursor-${e}`},select:{expand:(e)=>`select-${e}`},resize:{expand:(e)=>`resize-${e}`},appearance:{expand:(e)=>`appearance-${e}`},pointer:{expand:(e)=>`pointer-events-${e}`},outline:{expand:(e)=>`outline-${e}`},ring:{expand:(e)=>`ring-${e}`},blur:{expand:(e)=>`blur-${e}`},brightness:{expand:(e)=>`brightness-${e}`},contrast:{expand:(e)=>`contrast-${e}`},grayscale:{expand:(e)=>`grayscale-${e}`},saturate:{expand:(e)=>`saturate-${e}`},sepia:{expand:(e)=>`sepia-${e}`},backdrop:{expand:(e)=>`backdrop-${e}`},aspect:{expand:(e)=>`aspect-${e}`},columns:{expand:(e)=>`columns-${e}`},break:{expand:(e)=>`break-${e}`},object:{expand:(e)=>`object-${e}`},overscroll:{expand:(e)=>`overscroll-${e}`},place:{expand:(e)=>`place-${e}`},items:{expand:(e)=>`items-${e}`},justify:{expand:(e)=>`justify-${e}`},content:{expand:(e)=>`content-${e}`},self:{expand:(e)=>`self-${e}`},order:{expand:(e)=>`order-${e}`},col:{expand:(e)=>`col-${e}`},row:{expand:(e)=>`row-${e}`},tracking:{expand:(e)=>`tracking-${e}`},leading:{expand:(e)=>`leading-${e}`},list:{expand:(e)=>`list-${e}`},decoration:{expand:(e)=>`decoration-${e}`},underline:{expand:(e)=>`underline-${e}`},accent:{expand:(e)=>`accent-${e}`},caret:{expand:(e)=>`caret-${e}`},"scroll-m":{expand:(e)=>`scroll-m-${e}`},"scroll-p":{expand:(e)=>`scroll-p-${e}`},snap:{expand:(e)=>`snap-${e}`},touch:{expand:(e)=>`touch-${e}`},will:{expand:(e)=>`will-change-${e}`},fill:{expand:(e)=>`fill-${e}`},stroke:{expand:(e)=>`stroke-${e}`},sr:{expand:(e)=>`sr-${e}`},invert:{expand:(e)=>`invert-${e}`},"hue-rotate":{expand:(e)=>se(e)?`hue-rotate-[${e}]`:`hue-rotate-${e}`},"drop-shadow":{expand:(e)=>`drop-shadow-${e}`},"backdrop-invert":{expand:(e)=>`backdrop-invert-${e}`},"backdrop-hue-rotate":{expand:(e)=>se(e)?`backdrop-hue-rotate-[${e}]`:`backdrop-hue-rotate-${e}`},animate:{expand:(e)=>`animate-${e}`},"forced-colors":{expand:(e)=>`forced-colors-${e}`}},kt=new Set(["sm","md","lg","xl","2xl","hover","focus","active","visited","disabled","enabled","focus-within","focus-visible","group-hover","group-focus","peer-hover","peer-focus","*","**","dark","first","last","odd","even","only","first-of-type","last-of-type","only-of-type","checked","indeterminate","default","required","valid","invalid","in-range","out-of-range","placeholder-shown","autofill","read-only","user-valid","user-invalid","inert","empty","before","after","selection","marker","file","first-letter","first-line","backdrop","details-content","print","motion-safe","motion-reduce","pointer-none","pointer-coarse","pointer-fine","any-pointer-none","any-pointer-coarse","any-pointer-fine","inverted-colors","noscript","starting","contrast-more","contrast-less","rtl","ltr","portrait","landscape","@sm","@md","@lg","@xl","@2xl"]),Ro=new WeakMap,ko=new WeakMap;function mf(e){if(!e)return kn;let t=Ro.get(e);if(!t)t=e.aliases?{...kn,...e.aliases}:kn,Ro.set(e,t);return t}function pf(e){if(!e?.aliases)return"";let t=ko.get(e);if(t===void 0)t=JSON.stringify(e.aliases),ko.set(e,t);return t}function St(e){let t=[],r="",n=0;for(let i=0;i<e.length;i++){let o=e[i];if(o==="[")n++;else if(o==="]")n--;if(o===":"&&n===0)t.push(r),r="";else r+=o}return t.push(r),t}function yf(e,t){let r=`${e}:${t?.colonSyntax}:${pf(t)}`,n=_e.get(r);if(n)return n;let i=mf(t);if(t?.colonSyntax===!0){let m=e.match(/^([a-z][a-z0-9-]*):([^[\]:]+)$/i);if(m){let[,p,y]=m;if(!kt.has(p)){if(se(y)){let v=[`${p}-[${y}]`];return Le(_e,r,v),v}let b=y.startsWith("-")?[`-${p}-${y.slice(1)}`]:[`${p}-${y}`];return Le(_e,r,b),b}}}let o="",s=e,l=!1;if(s.startsWith("-"))l=!0,s=s.slice(1);let a=s.match(/^((?:[a-z@][a-z0-9-]*:)+)(.+)$/i);if(a){if(a[1].slice(0,-1).split(":").every((y)=>kt.has(y)))o=a[1],s=a[2]}let c=s.match(/^([a-z][a-z0-9-]*)\[([^\]]*)\]$/i);if(!c||s.includes("-[")){let m=[e];return Le(_e,r,m),m}let[,u,f]=c,d=f.split(/\s+/).filter(Boolean);if(d.length===0)return Le(_e,r,[]),[];let h=gf[u.toLowerCase()];if(h?.multiValue){let m=h.multiValue(d,i);if(m){let p=m.map((y)=>`${o}${l?"-":""}${y}`);return Le(_e,r,p),p}}if(!h){let m=[];for(let p of d){let y=p.match(/^([a-z@][a-z0-9-]*):(.+)$/i),b="",v=p;if(y&&kt.has(y[1]))b=`${y[1]}:`,v=y[2];let R="";if(v.startsWith("-"))R="-",v=v.slice(1);let S="";if(v.endsWith("!"))S="!",v=v.slice(0,-1);let j=l?"-":"";if(se(v))m.push(`${o}${b}${S}${j}${R}${u}-[${v}]`);else m.push(`${o}${b}${S}${j}${R}${u}-${v}`)}return Le(_e,r,m),m}let g=[];for(let m of d){let p=m.match(/^([a-z@][a-z0-9-]*):(.+)$/i),y="",b=m;if(p&&kt.has(p[1]))y=`${p[1]}:`,b=p[2];let v="";if(b.startsWith("-"))v="-",b=b.slice(1);let R="";if(b.endsWith("!"))R="!",b=b.slice(0,-1);let S=h.expand(b,i);if(S){let j=l?"-":"";g.push(`${o}${y}${R}${j}${v}${S}`)}}return Le(_e,r,g),g}function bf(e,t){let r=new Set;if(!t?.enabled)return r;let n=t.prefix??"tc-",i=["class","className","style","id","name","type","value","href","src","alt","title","role","for","action","method","target","rel","placeholder","disabled","checked","selected","readonly","required","maxlength","minlength","pattern","autocomplete","autofocus","tabindex","contenteditable","draggable","spellcheck","lang","dir","hidden","slot","part","is","key","ref"],o=t.ignoreAttributes||i,s=(c)=>{let u=c.includes(":")?c.split(":").pop():c;for(let f of o)if(f.endsWith("*")){if(u.startsWith(f.slice(0,-1)))return!0}else if(u===f)return!0;if(u.startsWith("on"))return!0;if(u.startsWith("data-")||u.startsWith("aria-"))return!0;return!1},l=/<([a-z][a-z0-9-]*)\s([^>]*)>/gi,a;while((a=l.exec(e))!==null){let c=a[2],u=/([a-z][a-z0-9-:]*)(?:=["']([^"']*)["'])?(?=\s|$|\/?>)/gi,f;while((f=u.exec(c))!==null){let d=f[1],h=f[2];if(n){if(!d.startsWith(n))continue;d=d.slice(n.length)}if(s(d))continue;let g="",m=d,p=d.match(/^((?:[a-z@][a-z0-9-]*:)+)([a-z][a-z0-9-]*)$/i);if(p){if(p[1].slice(0,-1).split(":").every((v)=>kt.has(v)))g=p[1],m=p[2]}if(h!==void 0){let y=h.split(/\s+/).filter(Boolean);for(let b of y){let v=`${g}${m}-${b}`;if(So(v.replace(/^(?:[a-z@][a-z0-9-]*:)+/gi,"")))r.add(v)}}else{let y=`${g}${m}`;if(So(m))r.add(y)}}}return r}function So(e){if(!e||e.length===0)return!1;return/^[a-z][a-z0-9-/]*(?:-\[[^\]]+\])?$/i.test(e)}function Sn(e){let t=wo.get(e);if(t)return t;let r=Cf(e);return r.base=$f(r),Le(wo,e,r),r}var xf=new Set(["bg","text","border","ring","placeholder","divide","accent","caret","fill","stroke","outline","decoration","shadow","ring-offset","from","via","to"]),vf=/^(.+?)\/(\d+|\[\d*\.?\d+\])$/,wf=/^(\d+)\/(\d+)$/;function Ao(e){let t=!1;for(let r=0;r<e.length;r++){let n=e.charCodeAt(r);if(n===45){if(!t||r+1>=e.length)return;return[e.slice(0,r),e.slice(r+1)]}if(n>=97&&n<=122){t=!0;continue}return}return}function $f(e){let t=e.raw;for(let r of e.variants)if(t.startsWith(`${r}:`))t=t.slice(r.length+1);if(e.important){if(t.charCodeAt(0)===33)t=t.slice(1);else if(t.charCodeAt(t.length-1)===33)t=t.slice(0,-1)}return t}function Cf(e){let t=!1,r=e;if(e.startsWith("!"))t=!0,r=e.slice(1);else if(e.endsWith("!")&&e.length>1)t=!0,r=e.slice(0,-1);{let h=St(r),g=h[h.length-1],m=!1;if(g.charCodeAt(0)===33&&g.length>1)m=!0,g=g.slice(1);let p=g.match(/^\[([a-z-]+):(.+)\]$/);if(p)return{raw:e,variants:h.slice(0,-1),utility:p[1],value:Ht(p[2]),important:t||m,arbitrary:!0}}let n=r.match(/^((?:[a-z-]+:)*)(-?[a-z-]+?)-\[([^\]]+)\]\/\[([^\]]+)\]$/);if(n){let[,h,g,m,p]=n,y=h?h.split(":").filter(Boolean):[],b=g.startsWith("-"),v=b?g.slice(1):g,R=Ht(m);if(b)R=R.startsWith("-")?R:`-${R}`;return{raw:e,variants:y,utility:v,value:`${R}/${p}`,important:t,arbitrary:!0,modifierArbitrary:!0}}let i=r.match(/^((?:[a-z-]+:)*)(-?[a-z-]+?)-\[(.+)\]$/);if(i){let h=i[1],g=h?h.split(":").filter(Boolean):[],m=i[2],p=m.startsWith("-");if(p)m=m.slice(1);let y=Ht(i[3]),b,v=y.match(/^(color|length|size|bg-size|url|number|percentage|position|line-width|absolute-size|relative-size|image|angle|time|flex|string|family-name):(.*)/i);if(v)b=v[1].toLowerCase(),y=v[2];if(p)y=y.startsWith("-")?y:`-${y}`;return{raw:e,variants:g,utility:m,value:y,important:t,arbitrary:!0,typeHint:b}}let o=St(r),s=o[o.length-1],l=o.slice(0,-1);if(s.startsWith("!")&&s.length>1)t=!0,s=s.slice(1);else if(s.endsWith("!")&&s.length>1)t=!0,s=s.slice(0,-1);if(l.length>0)r=`${l.join(":")}:${s}`;else r=s;if(["inline-block","inline-flex","inline-grid","flex-row","flex-row-reverse","flex-col","flex-col-reverse","flex-wrap","flex-wrap-reverse","flex-nowrap","flex-1","flex-auto","flex-initial","flex-none","flex-grow","flex-shrink"].includes(s))return{raw:e,variants:l,utility:s,value:void 0,important:t,arbitrary:!1};let c=s.match(/^([a-z-]+?)-\[(.+?)\]$/);if(c){let h=Ht(c[2]),g,m=h.match(/^(color|length|size|bg-size|url|number|percentage|position|line-width|absolute-size|relative-size|image|angle|time|flex|string|family-name):(.*)/i);if(m)g=m[1].toLowerCase(),h=m[2];return{raw:e,variants:l,utility:c[1],value:h,important:t,arbitrary:!0,typeHint:g}}let u=["inset-x","inset-y","border-t","border-r","border-b","border-l","border-x","border-y","border-s","border-e","grid-cols","grid-rows","grid-flow","auto-cols","auto-rows","col-span","row-span","col-start","col-end","row-start","row-end","translate-x","translate-y","translate-z","scale-x","scale-y","scale-z","rotate-x","rotate-y","rotate-z","skew-x","skew-y","scroll-m","scroll-mx","scroll-my","scroll-mt","scroll-mr","scroll-mb","scroll-ml","scroll-p","scroll-px","scroll-py","scroll-pt","scroll-pr","scroll-pb","scroll-pl","gap-x","gap-y","overflow-x","overflow-y","min-w","max-w","min-h","max-h","space-x","space-y","ring-offset","underline-offset","outline-offset","backdrop-blur","backdrop-brightness","backdrop-contrast","backdrop-grayscale","backdrop-invert","backdrop-saturate","backdrop-sepia","hue-rotate","drop-shadow","mask-clip","flex-grow","flex-shrink","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","perspective-origin","justify-self","form-input","form-textarea","form-select","form-multiselect","form-checkbox","form-radio","mix-blend","bg-blend","line-clamp","border-spacing","border-spacing-x","border-spacing-y","rounded-s","rounded-e","rounded-ss","rounded-se","rounded-es","rounded-ee","rounded-t","rounded-r","rounded-b","rounded-l","rounded-tl","rounded-tr","rounded-bl","rounded-br","border-opacity","ring-opacity","stroke-dasharray","stroke-dashoffset","animate-iteration","animate-duration","animate-delay","text-emphasis-color","text-emphasis","text-shadow","word-spacing","column-gap","column-rule","font-stretch","list-image"];if(s==="divide-x"||s==="divide-y")return{raw:e,variants:l,utility:s,value:void 0,important:t,arbitrary:!1};let f=s.match(/^(divide-[xy])-(.+)$/);if(f)return{raw:e,variants:l,utility:f[1],value:f[2],important:t,arbitrary:!1};for(let h of u)if(s.startsWith(`${h}-`))return{raw:e,variants:l,utility:h,value:s.slice(h.length+1),important:t,arbitrary:!1};if(s.startsWith("-")){let h=s.slice(1);for(let m of u)if(h.startsWith(`${m}-`))return{raw:e,variants:l,utility:m,value:`-${h.slice(m.length+1)}`,important:t,arbitrary:!1};let g=Ao(h);if(g)return{raw:e,variants:l,utility:g[0],value:`-${g[1]}`,important:t,arbitrary:!1};return{raw:e,variants:l,utility:h,value:void 0,important:t,arbitrary:!1}}let d=Ao(s);if(d){let[h,g]=d,m=g.match(vf);if(m&&xf.has(h))return{raw:e,variants:l,utility:h,value:`${m[1]}/${m[2]}`,important:t,arbitrary:!1};let p=g.match(wf);if(p)return{raw:e,variants:l,utility:h,value:`${p[1]}/${p[2]}`,important:t,arbitrary:!1};return{raw:e,variants:l,utility:h,value:g,important:t,arbitrary:!1}}return{raw:e,variants:l,utility:s,value:void 0,important:t,arbitrary:!1}}function Rf(e){return/^\[[a-z-]+:[^\]]+\]$/i.test(e)}function kf(e){if(!e)return!1;if(e==="*"||e==="**")return!0;if(e.startsWith("[")&&e.endsWith("]"))return e.length>2;return/^(?:@[a-z0-9]|[a-z]|\d+[a-z])[a-z0-9.-]*(?:\[[^\]]+\])?(?:\/[\w-]+)?$/i.test(e)}function Sf(e,t){let r=e;if(r.startsWith("!"))r=r.slice(1);if(r.endsWith("!"))r=r.slice(0,-1);if(!r)return!1;if(Rf(r))return!0;if(t?.enabled&&/^[a-z]+\[[^\]]+\]$/i.test(r))return!0;return/^[-@]?[a-z][a-z0-9.-]*(?:-\[[^\]]+\])?(?:\/(?:[\w.]+|[\w-]+|\[[^\]]+\]))?$/i.test(r)}function To(e,t){if(!e||e.length===0)return!1;if(t?.colonSyntax&&/^[a-z]+:[^[\]:]+$/i.test(e))return!0;let r=e;if(r.startsWith("!"))r=r.slice(1);if(r.endsWith("!"))r=r.slice(0,-1);if(!r)return!1;let n=St(r);for(let i=0;i<n.length-1;i++)if(!kf(n[i]))return!1;return Sf(n[n.length-1],t)}function Yt(e){let t=[],r="",n=0;for(let i of e)if(i==="[")n++,r+=i;else if(i==="]")n--,r+=i;else if(/\s/.test(i)&&n===0){if(r)t.push(r),r=""}else r+=i;if(r)t.push(r);return t}function Jt(e,t){let r=new Set,n=[/class(?:Name)?=["']([^"']+)["']/g,/class(?:Name)?=\{["']([^"']+)["']\}/g,/class(?:Name)?=\{`([^`]+)`\}/g];for(let o of n){let s;while((s=o.exec(e))!==null){let l=s[1],a=l.match(/["']([^"']+)["']/g);if(a)for(let f of a){let d=f.replace(/["']/g,""),h=Yt(d);for(let g of h)qt(r,g,t)}let c=l.replace(/["'`]/g," ").replace(/\$\{[^}]+\}/g," "),u=Yt(c).filter((f)=>To(f,t?.bracketSyntax));for(let f of u)qt(r,f,t)}}let i=[/class(?:Name|:list)?=\{([^{}]*(?:\{[^{}]*\}[^{}]*)*)\}/g,/:class="([^"]*)"/g,/:class='([^']*)'/g,/\bx-class="([^"]*)"/g,/\bx-class='([^']*)'/g];for(let o of i){let s;while((s=o.exec(e))!==null){let l=s[1].match(/["'`]([^"'`]*)["'`]/g);if(l)for(let a of l){let c=a.replace(/["'`]/g,"").replace(/\$\{[^}]+\}/g," ");for(let u of Yt(c))qt(r,u,t)}}}if(t?.codeStrings?.enabled!==!1)for(let o of No(e,t?.bracketSyntax))qt(r,o,t);if(t?.attributify?.enabled){let o=bf(e,t.attributify);for(let s of o)r.add(s)}return r}function Af(e,t){if(!/[-:/[]/.test(e))return!1;if(e.startsWith("-")&&!/^-[a-z]/i.test(e))return!1;return To(e,t)}function No(e,t){let r=new Set,n=e.length,i=0,o=/[<>]/g,s=o.exec(e),l=-1,a=-1,c="";while(i<n){let u=e[i];if(u==="/"&&e[i+1]==="/"){let p=e.indexOf(`
92
92
  `,i);i=p===-1?n:p;continue}if(u==="/"&&e[i+1]==="*"){let p=e.indexOf("*/",i+2);i=p===-1?n:p+2;continue}if(u==="/"&&(!/[\w$)\]]/.test(c)||Tf(e,i))){let p=Nf(e,i);if(p!==-1){i=p,c=")";continue}}if(u!=='"'&&u!=="'"&&u!=="`"){if(!/\s/.test(u))c=u;i++;continue}c=")";while(s&&s.index<i){if(s[0]==="<")l=s.index;else a=s.index;s=o.exec(e)}let f=If(e,i,l,a),d=u==="`",h=i+1,g="",m=!1;while(h<n){let p=e[h];if(p==="\\"){g+=e[h+1]??"",h+=2;continue}if(p===u){m=!0,h++;break}if(!d&&p===`
93
93
  `)break;if(d&&p==="$"&&e[h+1]==="{"){let y=1;h+=2;let b=h;while(h<n&&y>0){if(e[h]==="{")y++;else if(e[h]==="}")y--;h++}for(let v of No(e.slice(b,h-1),t))r.add(v);g+=" ";continue}g+=p,h++}if(m){if(f){for(let p of g.match(Of)??[])r.add(p);i=h;continue}for(let p of Yt(g))if(Af(p,t))r.add(p);i=h}else i++}return r}var Ef=new Set(["return","typeof","case","in","of","delete","void","throw","new","else","do","yield","await","instanceof"]);function Tf(e,t){let r=t;while(r>0&&/\s/.test(e[r-1]))r--;let n=r;while(n>0&&/[\w$]/.test(e[n-1]))n--;if(n===r||!Ef.has(e.slice(n,r)))return!1;let i=n;while(i>0&&/\s/.test(e[i-1]))i--;return e[i-1]!=="."}function Nf(e,t){let r=!1;for(let n=t+1;n<e.length;n++){let i=e[n];if(i===`
94
94
  `)return-1;if(i==="\\"){n++;continue}if(i==="[")r=!0;else if(i==="]")r=!1;else if(i==="/"&&!r){let o=n+1;while(o<e.length&&/[a-z]/i.test(e[o]))o++;return o}}return-1}var Of=/(?<![\w-])i-[a-z0-9]+(?:-[a-z0-9]+)+(?![\w-])/gi;function If(e,t,r,n){if(r<=n)return!1;let i=e[r+1];if(!i||!/[A-Za-z!/]/.test(i))return!1;let o=t-1;while(o>r&&/\s/.test(e[o]))o--;if(e[o]==="=")return!0;if(e[o]==="{"){o--;while(o>r&&/\s/.test(e[o]))o--;return e[o]==="="}return!1}function qt(e,t,r){if(r?.bracketSyntax?.enabled){let n=/^[a-z]+\[[^\]]+\]$/i.test(t),i=r.bracketSyntax.colonSyntax&&/^[a-z]+:[^[\]]+$/i.test(t);if(n||i){let o=yf(t,r.bracketSyntax);for(let s of o)e.add(s);return}}e.add(t)}var Xt={getCSS:()=>`