@master/css-runtime 2.0.0-rc.69 → 2.0.0-rc.70

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- !function(){var e,t,r,i,o,a,s,l,n,c,h,u,p,d,m,f,y,g,v,b,k,x,S,N,w,R,$,E,_,A,O,T,C,L,I,G,j,M,U,V,z,D,P,B,Y,X,q,F,K,Z,H,W,Q,J,ee,et,er,ei,eo,ea,es,el,en,ec,eh,eu,ep,ed,em,ef,ey,eg,ev,eb,ek,ex,eS,eN,ew,eR,e$,eE,e_,eA,eO,eT,eC,eL,eI,eG,ej,eM,eU,eV,ez,eD,eP,eB,eY,eX,eq,eF,eK,eZ,eH,eW,eQ,eJ,e0,e1,e2,e5,e9={},e3={};function e4(){return t?e:(t=1,e={all:"media(all)",print:"media(print)",screen:"media(screen)",speech:"media(speech)",landscape:"media(orientation:landscape)",portrait:"media(orientation:portrait)",motion:"media(prefers-reduced-motion:no-preference)","reduce-motion":"media(prefers-reduced-motion:reduce)",base:"layer(base)",preset:"layer(preset)",start:"starting-style",w:"width",h:"height"})}function e6(){return i?r:(i=1,r={":first":":first-child",":last":":last-child",":nth-last":":nth-last-child",":even":":nth-child(2n)",":odd":":nth-child(odd)",":nth":":nth-child",":only":":only-child",":rtl":":dir(rtl)",":ltr":":dir(ltr)","::scrollbar":"::-webkit-scrollbar","::scrollbar-button":"::-webkit-scrollbar-button","::scrollbar-thumb":"::-webkit-scrollbar-thumb","::scrollbar-track":"::-webkit-scrollbar-track","::scrollbar-track-piece":"::-webkit-scrollbar-track-piece","::scrollbar-corner":"::-webkit-scrollbar-corner","::slider-thumb":"::-webkit-slider-thumb","::slider-runnable-track":"::-webkit-slider-runnable-track","::resizer":"::-webkit-resizer","::progress":"::-webkit-progress"})}function e7(){return a?o:(a=1,o={container:{"container-type":"inline-size"},square:{"aspect-ratio":"1/1"},video:{"aspect-ratio":"16/9"},rounded:{"border-radius":"1e9em"},round:{"border-radius":"50%","aspect-ratio":"1/1"},hidden:{display:"none"},block:{display:"block"},table:{display:"table"},flex:{display:"flex"},grid:{display:"grid"},contents:{display:"contents"},inline:{display:"inline"},"inline-block":{display:"inline-block"},"inline-flex":{display:"inline-flex"},"inline-grid":{display:"inline-grid"},"inline-table":{display:"inline-table"},"table-cell":{display:"table-cell"},"table-caption":{display:"table-caption"},"flow-root":{display:"flow-root"},"list-item":{display:"list-item"},"table-row":{display:"table-row"},"table-column":{display:"table-column"},"table-row-group":{display:"table-row-group"},"table-column-group":{display:"table-column-group"},"table-header-group":{display:"table-header-group"},"table-footer-group":{display:"table-footer-group"},italic:{"font-style":"italic"},oblique:{"font-style":"oblique"},isolate:{isolation:"isolate"},overflow:{overflow:"visible"},untouchable:{"pointer-events":"none"},static:{position:"static"},fixed:{position:"fixed"},abs:{position:"absolute"},rel:{position:"relative"},sticky:{position:"sticky"},uppercase:{"text-transform":"uppercase"},lowercase:{"text-transform":"lowercase"},capitalize:{"text-transform":"capitalize"},visible:{visibility:"visible"},invisible:{visibility:"hidden"},"justify-normal":{"justify-content":"normal"},"justify-left":{"justify-content":"left"},"justify-center":{"justify-content":"center"},"justify-right":{"justify-content":"right"},"justify-stretch":{"justify-content":"stretch"},"justify-start":{"justify-content":"start"},"justify-end":{"justify-content":"end"},"justify-flex-start":{"justify-content":"flex-start"},"justify-flex-end":{"justify-content":"flex-end"},"justify-around":{"justify-content":"space-around"},"justify-between":{"justify-content":"space-between"},"justify-evenly":{"justify-content":"space-evenly"},"content-normal":{"align-content":"normal"},"content-baseline":{"align-content":"baseline"},"content-center":{"align-content":"center"},"content-stretch":{"align-content":"stretch"},"content-start":{"align-content":"start"},"content-end":{"align-content":"end"},"content-flex-start":{"align-content":"flex-start"},"content-flex-end":{"align-content":"flex-end"},"content-around":{"align-content":"space-around"},"content-between":{"align-content":"space-between"},"content-evenly":{"align-content":"space-evenly"},"items-normal":{"align-items":"normal"},"items-baseline":{"align-items":"baseline"},"items-center":{"align-items":"center"},"items-stretch":{"align-items":"stretch"},"items-start":{"align-items":"start"},"items-end":{"align-items":"end"},"items-flex-start":{"align-items":"flex-start"},"items-flex-end":{"align-items":"flex-end"},"items-self-start":{"align-items":"self-start"},"items-self-end":{"align-items":"self-end"},"self-auto":{"align-self":"auto"},"self-normal":{"align-self":"normal"},"self-baseline":{"align-self":"baseline"},"self-center":{"align-self":"center"},"self-stretch":{"align-self":"stretch"},"self-start":{"align-self":"start"},"self-end":{"align-self":"end"},"self-flex-start":{"align-self":"flex-start"},"self-flex-end":{"align-self":"flex-end"},"self-self-start":{"align-self":"self-start"},"self-self-end":{"align-self":"self-end"},"self-anchor-center":{"align-self":"anchor-center"},vw:{width:"100vw"},vh:{height:"100vh"},"box-border":{"box-sizing":"border-box"},"box-content":{"box-sizing":"content-box"},"transform-content":{"transform-box":"content-box"},"transform-border":{"transform-box":"border-box"},"transform-fill":{"transform-box":"fill-box"},"transform-stroke":{"transform-box":"stroke-box"},"transform-view":{"transform-box":"view-box"},"bg-clip-content":{"background-clip":"content-box"},"bg-clip-padding":{"background-clip":"padding-box"},"bg-clip-border":{"background-clip":"border-box"},"bg-clip-text":{"background-clip":"text"},"bg-origin-content":{"background-origin":"content-box"},"bg-origin-padding":{"background-origin":"padding-box"},"bg-origin-border":{"background-origin":"border-box"},"shape-none":{"shape-outside":"none"},"shape-margin":{"shape-outside":"margin-box"},"shape-content":{"shape-outside":"content-box"},"shape-border":{"shape-outside":"border-box"},"shape-padding":{"shape-outside":"padding-box"},"clip-none":{"clip-path":"none"},"clip-margin":{"clip-path":"margin-box"},"clip-content":{"clip-path":"content-box"},"clip-border":{"clip-path":"border-box"},"clip-padding":{"clip-path":"padding-box"},"clip-fill":{"clip-path":"fill-box"},"clip-stroke":{"clip-path":"stroke-box"},"clip-view":{"clip-path":"view-box"},"flex-row":{"flex-direction":"row"},"flex-row-reverse":{"flex-direction":"row-reverse"},"flex-col":{"flex-direction":"column"},"flex-col-reverse":{"flex-direction":"column-reverse"},"max-vw":{"max-width":"100vw"},"max-vh":{"max-height":"100vh"},"min-vw":{"min-width":"100vw"},"min-vh":{"min-height":"100vh"},full:{width:"100%",height:"100%"},top:{top:0},left:{left:0},right:{right:0},bottom:{bottom:0},center:{left:0,right:0,"margin-left":"auto","margin-right":"auto"},middle:{top:0,bottom:0,"margin-top":"auto","margin-bottom":"auto"},"break-spaces":{"white-space":"break-spaces"},"break-word":{"word-break":"break-word"},"wrap-break-word":{"overflow-wrap":"break-word"},"wrap-anywhere":{"overflow-wrap":"anywhere"},"wrap-normal":{"overflow-wrap":"normal"},"gradient-text":{"-webkit-text-fill-color":"transparent","background-clip":"text"},fit:{width:"fit-content",height:"fit-content"},"font-antialiased":{"-webkit-font-smoothing":"antialiased","-moz-osx-font-smoothing":"grayscale"},"font-subpixel-antialiased":{"-webkit-font-smoothing":"auto","-moz-osx-font-smoothing":"auto"},"sr-only":{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0,0,0,0)","white-space":"nowrap","border-width":"0"}})}function e8(){return l?s:(l=1,s={fade:{"0%":{opacity:0},to:{opacity:1}},flash:{"0%,50%,to":{opacity:1},"25%,75%":{opacity:0}},float:{"0%":{transform:"none"},"50%":{transform:"translateY(-1.25rem)"},to:{transform:"none"}},heart:{"0%":{transform:"scale(1)"},"14%":{transform:"scale(1.3)"},"28%":{transform:"scale(1)"},"42%":{transform:"scale(1.3)"},"70%":{transform:"scale(1)"}},jump:{"0%,to":{transform:"translateY(-25%)","animation-timing-function":"cubic-bezier(.8,0,1,1)"},"50%":{transform:"translateY(0)","animation-timing-function":"cubic-bezier(0,0,.2,1)"}},ping:{"75%,to":{transform:"scale(2)",opacity:0}},pulse:{"0%":{transform:"none"},"50%":{transform:"scale(1.05)"},to:{transform:"none"}},rotate:{"0%":{transform:"rotate(-360deg)"},to:{transform:"none"}},shake:{"0%":{transform:"none"},"6.5%":{transform:"translateX(-6px) rotateY(-9deg)"},"18.5%":{transform:"translateX(5px) rotateY(7deg)"},"31.5%":{transform:"translateX(-3px) rotateY(-5deg)"},"43.5%":{transform:"translateX(2px) rotateY(3deg)"},"50%":{transform:"none"}},zoom:{"0%":{transform:"scale(0)"},to:{transform:"none"}}})}var te=function(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if("function"==typeof t){var r=function e(){var r=!1;try{r=this instanceof e}catch{}return r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(t){var i=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,i.get?i:{enumerable:!0,get:function(){return e[t]}})}),r}(Object.freeze({__proto__:null,default:{stone:{0:"oklch(99% 0.0033 72)",5:"oklch(94.9% 0.0066 72)",10:"oklch(90.8% 0.0172 72)",20:"oklch(82.6% 0.0287 72)",30:"oklch(74.4% 0.04 72)",40:"oklch(66.2% 0.044 72)",50:"oklch(58% 0.045 72)",60:"oklch(49.8% 0.033 72)",70:"oklch(41.6% 0.0275 72)",80:"oklch(33.4% 0.022 72)",90:"oklch(25.2% 0.0105 72)",95:"oklch(21.1% 0.0079 72)",100:"oklch(17% 0.0053 72)"},gray:{0:"oklch(98.48% 0 none)",5:"oklch(96.5% 0 none)",10:"oklch(90% 0 none)",20:"oklch(82% 0 none)",30:"oklch(73.5% 0 none)",40:"oklch(65% 0 none)",50:"oklch(55.2% 0 none)",60:"oklch(48% 0 none)",70:"oklch(39.5% 0 none)",80:"oklch(31% 0 none)",90:"oklch(23.5% 0 none)",95:"oklch(18.5% 0 none)",100:"oklch(14.5% 0 none)"},grey:{0:"oklch(98.38% 0.0033 249.7)",5:"oklch(95.52% 0.0099 270)",10:"oklch(90% 0.014 272)",20:"oklch(82% 0.02 272)",30:"oklch(73.5% 0.027 272)",40:"oklch(65% 0.032 273)",50:"oklch(55.2% 0.035 273)",60:"oklch(48% 0.032 273)",70:"oklch(39.5% 0.027 273)",80:"oklch(31% 0.022 273)",90:"oklch(23.5% 0.016 273)",95:"oklch(18.5% 0.012 273)",100:"oklch(14.5% 0.009 273)"},slate:{0:"oklch(98.07% 0.0092 257.1)",5:"oklch(96.15% 0.0181 267.3)",10:"oklch(90.16% 0.0352 268.2)",20:"oklch(82.16% 0.045 268.2)",30:"oklch(74.16% 0.069 268.2)",40:"oklch(63.99% 0.0804 266.1)",50:"oklch(55.43% 0.0949 263.4)",60:"oklch(45.03% 0.0817 265.9)",70:"oklch(39% 0.0702 263.9)",80:"oklch(32.14% 0.0604 264.8)",90:"oklch(27.33% 0.0536 264.8)",95:"oklch(21.5% 0.0573 267.4)",100:"oklch(17.5% 0.0688 267.4)"},brown:{0:"oklch(97% 0.0161 47.15)",5:"oklch(95.48% 0.0229 34.84)",10:"oklch(88.65% 0.0606 33.36)",20:"oklch(81.37% 0.1065 33.59)",30:"oklch(74.39% 0.12 32.5)",40:"oklch(67.62% 0.12 32.5)",50:"oklch(61.9% 0.12 32.5)",60:"oklch(55.58% 0.12 32.5)",70:"oklch(49.11% 0.12 32.5)",80:"oklch(42.07% 0.12 32.5)",90:"oklch(35.11% 0.12 32.5)",95:"oklch(24.7% 0.0958 31.18)",100:"oklch(21.21% 0.0822 31.17)"},orange:{0:"oklch(96.76% 0.0337 84.59)",5:"oklch(94.78% 0.0521 82.97)",10:"oklch(89.94% 0.0852 75.65)",20:"oklch(82.86% 0.1343 69.21)",30:"oklch(75.09% 0.179 58.39)",40:"oklch(71.4% 0.1941 48.13)",50:"oklch(66.61% 0.2247 36.66)",60:"oklch(61.68% 0.2388 31.22)",70:"oklch(53.53% 0.2196 29.23)",80:"oklch(46.33% 0.1901 29.23)",90:"oklch(36.63% 0.1503 29.23)",95:"oklch(25.4% 0.1042 29.23)",100:"oklch(21.44% 0.088 29.23)"},amber:{0:"oklch(97.5% 0.051 98.98)",5:"oklch(96.24% 0.0716 98.08)",10:"oklch(93.46% 0.1082 95.78)",20:"oklch(88.25% 0.1592 91.33)",30:"oklch(86% 0.1633 86.92)",40:"oklch(83.04% 0.1701 81.13)",50:"oklch(79.4% 0.1709 71.06)",60:"oklch(73.31% 0.1784 56.52)",70:"oklch(63.23% 0.1757 46.71)",80:"oklch(53.09% 0.1677 39.66)",90:"oklch(42.68% 0.138 38.58)",95:"oklch(29.27% 0.0971 37.42)",100:"oklch(23.94% 0.0818 36.09)"},yellow:{0:"oklch(98.86% 0.0591 107.4)",5:"oklch(98.27% 0.0948 108)",10:"oklch(97.31% 0.1645 109.1)",20:"oklch(95.82% 0.207 108.4)",30:"oklch(93.51% 0.1981 104.7)",40:"oklch(91.5% 0.1909 101.1)",50:"oklch(87.52% 0.1796 94.59)",60:"oklch(82.02% 0.169 82.09)",70:"oklch(72.04% 0.1592 66.98)",80:"oklch(64.84% 0.1477 63.12)",90:"oklch(52.17% 0.1199 62.19)",95:"oklch(33.35% 0.083 54.56)",100:"oklch(26.22% 0.0646 55.44)"},lime:{0:"oklch(98.05% 0.0665 116)",5:"oklch(96.62% 0.1 121.2)",10:"oklch(95.06% 0.1566 121.5)",20:"oklch(92.45% 0.2251 126)",30:"oklch(87.79% 0.2261 126.9)",40:"oklch(82.22% 0.225 131.1)",50:"oklch(74.39% 0.2131 133.9)",60:"oklch(66.45% 0.195 135.3)",70:"oklch(58.7% 0.1769 136.7)",80:"oklch(51.46% 0.1612 138.7)",90:"oklch(44.54% 0.1437 140.1)",95:"oklch(29.84% 0.097 140.4)",100:"oklch(25.83% 0.0851 141.1)"},green:{0:"oklch(97% 0.0508 145.7)",5:"oklch(94.95% 0.0888 145.5)",10:"oklch(92.05% 0.1473 145.7)",20:"oklch(89.18% 0.2191 143.8)",30:"oklch(84.3% 0.24 143.9)",40:"oklch(77.68% 0.25 144.1)",50:"oklch(72.41% 0.2464 142.5)",60:"oklch(67.52% 0.2298 142.5)",70:"oklch(58.66% 0.1996 142.5)",80:"oklch(51.96% 0.1768 142.5)",90:"oklch(44.03% 0.1498 142.5)",95:"oklch(30.17% 0.1027 142.5)",100:"oklch(26.35% 0.0897 142.5)"},beryl:{0:"oklch(96.57% 0.05 163.7)",5:"oklch(94.71% 0.0792 163.5)",10:"oklch(91.87% 0.128 162.2)",20:"oklch(90.33% 0.1569 161.2)",30:"oklch(86.43% 0.2104 155.8)",40:"oklch(82.49% 0.1978 156.6)",50:"oklch(76.89% 0.1885 155.4)",60:"oklch(69.77% 0.1794 153.1)",70:"oklch(60.74% 0.1602 151.9)",80:"oklch(54.36% 0.1421 152.3)",90:"oklch(46.09% 0.1213 152)",95:"oklch(30.39% 0.0888 147.6)",100:"oklch(26.71% 0.0855 144.4)"},teal:{0:"oklch(97.24% 0.0384 179.8)",5:"oklch(94.3% 0.0826 180.5)",10:"oklch(92.33% 0.1148 181.5)",20:"oklch(91.3% 0.1327 183.1)",30:"oklch(90.52% 0.1472 184.8)",40:"oklch(89.99% 0.1577 186.3)",50:"oklch(86.13% 0.1485 190.5)",60:"oklch(79.38% 0.1355 194.8)",70:"oklch(67.86% 0.1154 199.2)",80:"oklch(60.62% 0.1033 203.7)",90:"oklch(52.19% 0.0898 208.3)",95:"oklch(31.94% 0.0584 220.7)",100:"oklch(28.34% 0.0534 224.3)"},cyan:{0:"oklch(97.47% 0.0367 196.6)",5:"oklch(95.05% 0.0748 196)",10:"oklch(92.28% 0.1122 196.9)",20:"oklch(89.98% 0.1264 200.1)",30:"oklch(87.28% 0.1376 204.3)",40:"oklch(84.82% 0.1408 209.5)",50:"oklch(81.54% 0.1453 216.7)",60:"oklch(77.57% 0.1494 226.7)",70:"oklch(70.27% 0.1509 235.9)",80:"oklch(63.25% 0.1493 241.7)",90:"oklch(52.16% 0.1354 246.4)",95:"oklch(35.21% 0.0976 249.2)",100:"oklch(30.27% 0.0847 249.6)"},sky:{0:"oklch(97.39% 0.0232 209.4)",5:"oklch(94.65% 0.0448 212.1)",10:"oklch(90.51% 0.0725 216.5)",20:"oklch(86.58% 0.0902 224)",30:"oklch(77.94% 0.1431 228.4)",40:"oklch(72.24% 0.1626 239)",50:"oklch(67.09% 0.1828 248.5)",60:"oklch(62.09% 0.2077 255.4)",70:"oklch(55.12% 0.2483 261.6)",80:"oklch(49.98% 0.2769 263.8)",90:"oklch(40.76% 0.2499 264.2)",95:"oklch(28.37% 0.1946 265.1)",100:"oklch(25.85% 0.1768 265.4)"},blue:{0:"oklch(97.5% 0.0175 219.7)",5:"oklch(93.53% 0.0381 231.3)",10:"oklch(90.01% 0.0564 236.1)",20:"oklch(81.69% 0.0975 246.5)",30:"oklch(72.87% 0.1468 249.3)",40:"oklch(64.31% 0.1921 258.5)",50:"oklch(58.22% 0.2279 263.9)",60:"oklch(51.83% 0.2687 266.1)",70:"oklch(46.26% 0.3057 266.7)",80:"oklch(42.89% 0.2907 266.3)",90:"oklch(39.4% 0.2629 268)",95:"oklch(28.64% 0.1893 269)",100:"oklch(25.46% 0.168 269.2)"},indigo:{0:"oklch(97.1% 0.0138 257.2)",5:"oklch(94.11% 0.0285 279.6)",10:"oklch(87.83% 0.0595 274.4)",20:"oklch(77.74% 0.1153 280.2)",30:"oklch(70.2% 0.1611 282.9)",40:"oklch(61.3% 0.218 284)",50:"oklch(56.78% 0.2478 284.1)",60:"oklch(50.06% 0.2906 282)",70:"oklch(48.74% 0.2963 279.3)",80:"oklch(48.25% 0.2976 277.4)",90:"oklch(41.46% 0.2571 276.7)",95:"oklch(29.36% 0.1799 278.3)",100:"oklch(25.28% 0.1551 278.1)"},violet:{0:"oklch(97.96% 0.0166 322.8)",5:"oklch(94.02% 0.0333 299.5)",10:"oklch(88.69% 0.0648 300.1)",20:"oklch(80.47% 0.113 297.7)",30:"oklch(71.63% 0.1722 298.7)",40:"oklch(62.1% 0.237 297.8)",50:"oklch(56.23% 0.2803 297.8)",60:"oklch(52.55% 0.293 292.4)",70:"oklch(51.12% 0.2931 287.9)",80:"oklch(48.43% 0.2798 286.7)",90:"oklch(40.64% 0.2331 287.9)",95:"oklch(28.51% 0.1631 288.3)",100:"oklch(24.44% 0.1403 287.8)"},purple:{0:"oklch(97.07% 0.0259 325.8)",5:"oklch(94.28% 0.0394 314.4)",10:"oklch(89.13% 0.0771 314.7)",20:"oklch(81.4% 0.1318 312.8)",30:"oklch(72.72% 0.2007 312.8)",40:"oklch(63.36% 0.2677 310)",50:"oklch(58.21% 0.2988 307.2)",60:"oklch(55.59% 0.2952 301)",70:"oklch(54.45% 0.294 297.9)",80:"oklch(48.76% 0.264 297.5)",90:"oklch(39.15% 0.2105 298.7)",95:"oklch(27.95% 0.1488 300.5)",100:"oklch(24.3% 0.128 302.4)"},fuchsia:{0:"oklch(97.07% 0.0259 325.8)",5:"oklch(94.57% 0.0472 324.9)",10:"oklch(89.9% 0.0935 326.3)",20:"oklch(81.84% 0.1554 322)",30:"oklch(74.78% 0.2085 319.1)",40:"oklch(67.61% 0.25 316.5)",50:"oklch(62.91% 0.25 316.7)",60:"oklch(58.72% 0.25 311.8)",70:"oklch(53.61% 0.25 312.8)",80:"oklch(47.9% 0.2382 313.2)",90:"oklch(38.62% 0.1895 315.8)",95:"oklch(27.75% 0.1357 316.4)",100:"oklch(23.7% 0.1162 315.9)"},pink:{0:"oklch(97.07% 0.0259 325.8)",5:"oklch(94.74% 0.0465 326.5)",10:"oklch(88.85% 0.0902 332.8)",20:"oklch(81.57% 0.1379 341.6)",30:"oklch(74.68% 0.2018 342.5)",40:"oklch(69.18% 0.2455 347.6)",50:"oklch(65.84% 0.25 350.7)",60:"oklch(63.54% 0.25 359.2)",70:"oklch(58.95% 0.2377 2.647)",80:"oklch(53% 0.2126 6.362)",90:"oklch(43.66% 0.1748 8.099)",95:"oklch(31.48% 0.1261 7.759)",100:"oklch(27.42% 0.1098 8.521)"},crimson:{0:"oklch(97.07% 0.0259 325.8)",5:"oklch(94.2% 0.0332 353.2)",10:"oklch(88.09% 0.0677 1.012)",20:"oklch(80.33% 0.1184 4.549)",30:"oklch(72.9% 0.1774 4.449)",40:"oklch(66.41% 0.2325 8.311)",50:"oklch(63.55% 0.25 15.3)",60:"oklch(62.66% 0.25 21.21)",70:"oklch(58.59% 0.2383 26.22)",80:"oklch(53.32% 0.2169 26.29)",90:"oklch(44.03% 0.1783 24.44)",95:"oklch(31.73% 0.1287 25.13)",100:"oklch(27.68% 0.1126 26.19)"},red:{0:"oklch(96.63% 0.0166 17.2)",5:"oklch(94.05% 0.0299 17.02)",10:"oklch(87.16% 0.0687 17.78)",20:"oklch(79.39% 0.119 18.78)",30:"oklch(72.94% 0.1679 17.49)",40:"oklch(64.7% 0.2399 19.91)",50:"oklch(62.82% 0.25 28.59)",60:"oklch(60.94% 0.2501 29.23)",70:"oklch(57.58% 0.2363 29.23)",80:"oklch(53.09% 0.2178 29.23)",90:"oklch(44.45% 0.1824 29.23)",95:"oklch(32.59% 0.1337 29.23)",100:"oklch(28.54% 0.1171 29.23)"}}}));function tt(){return c?n:(c=1,n={full:"100%",fit:"fit-content",max:"max-content",min:"min-content","font-family":{sans:'"Inter", $font-family-sans-fallback',serif:"$font-family-serif-fallback",mono:"$font-family-mono-fallback","sans-fallback":"ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji'","serif-fallback":"ui-serif, Georgia, Cambria, 'Times New Roman', Times, serif","mono-fallback":"ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace"},"letter-spacing":{tightest:"-0.072em",tighter:"-0.04em",tight:"-0.02em",normal:"0",wide:"0.02em",wider:"0.04em",widest:"0.12em"},"line-height":{xs:1.2,sm:1.4,md:1.6,lg:1.8,xl:2},"font-weight":{thin:100,extralight:200,light:300,regular:400,medium:500,semibold:600,bold:700,extrabold:800,heavy:900},"font-size":{"3xs":8,"2xs":10,xs:12,sm:14,md:16,lg:18,xl:20,"2xl":24,"3xl":32,"4xl":36,"5xl":40,"6xl":48,"7xl":60,"8xl":72,"9xl":96,"10xl":128},"border-radius":{xs:2,sm:4,md:6,lg:8,xl:12,"2xl":16,"3xl":24,"4xl":32},order:{first:-999999,last:999999},spacing:{"4xs":2,"3xs":4,"2xs":6,xs:8,sm:12,md:16,lg:24,xl:32,"2xl":48,"3xl":64,"4xl":96,"5xl":128},color:{current:"currentColor",white:"oklch(100% 0 none)",black:"oklch(0% 0 none)",...te}})}function tr(){if(u)return h;u=1;var e,t=((e=t||{})[e.Utility=-4]="Utility",e[e.NativeShorthand=-3]="NativeShorthand",e[e.Shorthand=-2]="Shorthand",e[e.Native=-1]="Native",e[e.Normal=0]="Normal",e);return h=t}var ti={};function to(){return p||(p=1,ti.ANIMATION_SIGN="@",ti.AT_COMPARABLE_FEATURES=["width","height","resolution"],ti.AT_COMPARISON_OPERATORS=[">=","<=",">","<","="],ti.AT_IDENTIFIERS=["container","starting-style","supports","media","layer"],ti.AT_LOGICAL_OPERATORS={"&":"and","!":"not",not:"not",and:"and",or:"or",only:"only",",":"or"},ti.AT_SIGN="@",ti.BASE_UNIT_REGEX=/^([+-]?(?:\d+(?:\.?\d+)?|\.\d+))x$/m,ti.BORDER_STYLE_VALUES=["none","auto","hidden","dotted","dashed","solid","double","groove","ridge","inset","outset"],ti.CLASS_ATTRIBUTES=["class","className"],ti.CLASS_DECLARATIONS=["components"],ti.CLASS_FUNCTIONS=["clsx","cva","ctl","cv","class","classnames","classVariant","styled(?:\\s+)?(?:\\.\\w+)?","classList(?:\\s+)?\\.(?:add|remove|toggle|replace)"],ti.COLOR_VALUE_REGEX=/(?:#|(?:color|color-contrast|color-mix|hwb|lab|lch|oklab|oklch|rgb|rgba|hsl|hsla|light-dark)\(.*\)|(?:\$colors)(?![a-zA-Z0-9-]))/,ti.COMPARISION_OPERATORS=[">=","<=",">","<","="],ti.DELIMITER_SIGN="|",ti.IMAGE_VALUE_REGEX=/(?:url|linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient|conic-gradient)\(.*\)/,ti.NUMBER_VALUE_REGEX=/(?:[\d.]|(?:max|min|calc|clamp)\([^|]*\))/,ti.QUERY_COMPARISON_OPERATORS=[">","<","="],ti.QUERY_LOGICAL_OPERATORS=["&"],ti.SELECTOR_COMBINATORS=["_",">","+","~"],ti.SELECTOR_SIGNS=[":","_",">","+","~"],ti.SEPARATOR_SIGN=",",ti.SEPARATOR_SIGNS=[",","|"],ti.TRANSITION_SIGN="~",ti.UNIT_REGEX=/^([+-.]?\d+(?:\.?\d+)?)(%|cm|mm|q|in|pt|pc|px|em|rem|ex|rex|cap|rcap|ch|rch|ic|ric|lh|rlh|vw|svw|lvw|dvw|vh|svh|lvh|dvh|vi|svi|lvi|dvi|vb|svb|lvb|dvb|vmin|svmin|lvmin|dvmin|vmax|svmax|lvmax|dvmax|cqw|cqh|cqi|cqb|cqmin|cqmax|deg|grad|rad|turn|s|ms|hz|khz|dpi|dpcm|dppx|x|fr|db|st)?$/,ti.VALUE_DELIMITERS={"(":")","'":"'",'"':'"',"{":"}"},ti.VALUE_UNITS=["%","cm","mm","q","in","pt","pc","px","em","rem","ex","rex","cap","rcap","ch","rch","ic","ric","lh","rlh","vw","svw","lvw","dvw","vh","svh","lvh","dvh","vi","svi","lvi","dvi","vb","svb","lvb","dvb","vmin","svmin","lvmin","dvmin","vmax","svmax","lvmax","dvmax","cqw","cqh","cqi","cqb","cqmin","cqmax","deg","grad","rad","turn","s","ms","hz","khz","dpi","dpcm","dppx","x","fr","db","st"],ti.__UNSORTED__="__UNSORTED__"),ti}function ta(){if(m)return d;m=1;var e=tr(),t=to();return d={"font-size":{aliasGroups:["font","f"],kind:"number",unit:"rem",type:e.Native},"font-weight":{aliasGroups:["font","f"],values:["bolder"],type:e.Native},"font-family":{aliasGroups:["font","f"],type:e.Native},"font-smooth":{type:e.Native},"font-style":{aliasGroups:["font","f"],values:["normal","italic","oblique"],type:e.Native,unit:"deg"},"font-variant-numeric":{aliasGroups:["font","f"],values:["ordinal","slashed-zero","lining-nums","oldstyle-nums","proportional-nums","tabular-nums","diagonal-fractions","stacked-fractions"],type:e.Native},"font-variant":{aliasGroups:["font","f"],type:e.NativeShorthand},font:{subkey:"f",type:e.NativeShorthand,namespaces:["font-family","font-variant","font-weight","font-size","font-style"]},"font-feature-settings":{key:"font-feature",type:e.Native},color:{key:"fg",type:e.Native,namespaces:["color.text"]},"margin-left":{key:"ml",type:e.Native,unit:"rem",namespaces:["spacing"]},"margin-right":{key:"mr",type:e.Native,unit:"rem",namespaces:["spacing"]},"margin-top":{key:"mt",type:e.Native,unit:"rem",namespaces:["spacing"]},"margin-bottom":{key:"mb",type:e.Native,unit:"rem",namespaces:["spacing"]},"margin-x":{key:"mx",subkey:"margin-x",unit:"rem",type:e.Shorthand,declarations:["margin-left","margin-right"],namespaces:["spacing"]},"margin-y":{key:"my",unit:"rem",type:e.Shorthand,declarations:["margin-top","margin-bottom"],namespaces:["spacing"]},margin:{key:"m",unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},"margin-inline-start":{key:"mis",type:e.Native,unit:"rem",namespaces:["spacing"]},"margin-inline-end":{key:"mie",type:e.Native,unit:"rem",namespaces:["spacing"]},"margin-inline":{key:"mi",unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},"padding-left":{key:"pl",type:e.Native,unit:"rem",namespaces:["spacing"]},"padding-right":{key:"pr",type:e.Native,unit:"rem",namespaces:["spacing"]},"padding-top":{key:"pt",type:e.Native,unit:"rem",namespaces:["spacing"]},"padding-bottom":{key:"pb",type:e.Native,unit:"rem",namespaces:["spacing"]},"padding-x":{key:"px",unit:"rem",type:e.Shorthand,declarations:["padding-left","padding-right"],namespaces:["spacing"]},"padding-y":{key:"py",unit:"rem",type:e.Shorthand,declarations:["padding-top","padding-bottom"],namespaces:["spacing"]},padding:{key:"p",unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},"padding-inline-start":{key:"pis",type:e.Native,unit:"rem",namespaces:["spacing"]},"padding-inline-end":{key:"pie",type:e.Native,unit:"rem",namespaces:["spacing"]},"padding-inline":{key:"pi",unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},"flex-basis":{aliasGroups:["flex"],unit:"rem",type:e.Native},"flex-wrap":{aliasGroups:["flex"],values:["wrap","nowrap","wrap-reverse"],type:e.Native},"flex-grow":{aliasGroups:["flex"],type:e.Native},"flex-shrink":{aliasGroups:["flex"],type:e.Native},"flex-direction":{aliasGroups:["flex"],values:["row","row-reverse","column","column-reverse"],type:e.Native},flex:{type:e.NativeShorthand},display:{key:"d",type:e.Native},width:{key:"w",unit:"rem",type:e.Native},height:{key:"h",unit:"rem",type:e.Native},"min-width":{key:"min-w",unit:"rem",type:e.Native},"min-height":{key:"min-h",unit:"rem",type:e.Native},size:{type:e.Shorthand,unit:"rem",declarer:["pair",["width","height"]]},"min-size":{key:"min",type:e.Shorthand,unit:"rem",declarer:["pair",["min-width","min-height"]]},"max-size":{key:"max",type:e.Shorthand,unit:"rem",declarer:["pair",["max-width","max-height"]]},"box-sizing":{aliasGroups:["box"],type:e.Native},"box-decoration-break":{key:"box-decoration",type:e.Native,declarations:["-webkit-box-decoration-break","box-decoration-break"]},container:{type:e.NativeShorthand},"container-name":{type:e.Native},"container-type":{type:e.Native,aliasGroups:["container"],values:["size","inline-size","scroll-state"]},contain:{type:e.Native},content:{type:e.Native},"counter-increment":{type:e.Native},"counter-reset":{type:e.Native},"letter-spacing":{key:"tracking",subkey:"ls",type:e.Native,unit:"em"},"line-height":{key:"leading",subkey:"line-h",type:e.Native},"object-fit":{aliasGroups:["object","obj"],values:["contain","cover","fill","scale-down"],type:e.Native},"object-position":{aliasGroups:["object","obj"],values:["top","bottom","right","left","center"],type:e.Native},"text-align":{aliasGroups:["text","t"],values:["justify","center","left","right","start","end"],type:e.Native},"text-decoration-color":{aliasGroups:["text-decoration"],kind:"color",type:e.Native,namespaces:["color","color.text"]},"text-decoration-style":{aliasGroups:["text-decoration"],values:["solid","double","dotted","dashed","wavy"],type:e.Native},"text-decoration-thickness":{aliasGroups:["text-decoration"],values:["from-font"],kind:"number",type:e.Native,unit:"em"},"text-decoration-line":{aliasGroups:["text-decoration"],values:["underline","overline","line-through"],type:e.Native},"text-decoration":{aliasGroups:["text","t"],values:["underline","overline","line-through"],unit:"rem",type:e.NativeShorthand,namespaces:["color","color.text"],declarations:["-webkit-text-decoration","text-decoration"]},"text-underline-offset":{aliasGroups:["text-underline"],unit:"rem",type:e.Native,namespaces:["spacing"]},"text-underline-position":{aliasGroups:["text-underline"],values:["front-font","under","left","right"],type:e.Native},"text-overflow":{aliasGroups:["text","t"],values:["ellipsis","clip"],type:e.Native},"text-orientation":{aliasGroups:["text","t"],values:["mixed","upright","sideways-right","sideways","use-glyph-orientation"],type:e.Native},"text-transform":{aliasGroups:["text","t"],values:["uppercase","lowercase","capitalize"],type:e.Native},"text-rendering":{aliasGroups:["text","t"],values:["optimizeSpeed","optimizeLegibility","geometricPrecision"],type:e.Native},"text-wrap":{aliasGroups:["text","t"],values:["wrap","nowrap","balance","pretty"],type:e.NativeShorthand},"text-indent":{unit:"rem",type:e.Native},"vertical-align":{key:"v",subkey:"vertical",type:e.Native},columns:{key:"cols",type:e.NativeShorthand},"overflow-wrap":{type:e.Native},"white-space":{type:e.Native},top:{type:e.Native,unit:"rem",namespaces:["spacing"]},bottom:{type:e.Native,unit:"rem",namespaces:["spacing"]},left:{type:e.Native,unit:"rem",namespaces:["spacing"]},right:{type:e.Native,unit:"rem",namespaces:["spacing"]},inset:{unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},"max-height":{key:"max-h",unit:"rem",type:e.Native},"max-width":{key:"max-w",unit:"rem",type:e.Native},opacity:{type:e.Native},visibility:{type:e.Native},clear:{type:e.Native},float:{type:e.Native},isolation:{type:e.Native},"overflow-x":{type:e.Native},"overflow-y":{type:e.Native},overflow:{type:e.NativeShorthand},"overscroll-behavior-x":{type:e.Native},"overscroll-behavior-y":{type:e.Native},"overscroll-behavior":{type:e.NativeShorthand},"z-index":{key:"z",type:e.Native},position:{type:e.Native},cursor:{type:e.Native},"pointer-events":{type:e.Native},resize:{type:e.Native},"touch-action":{type:e.Native},"word-break":{type:e.Native},"word-spacing":{type:e.Native,unit:"em"},hyphens:{type:e.Native},"user-drag":{type:e.Native,declarations:["-webkit-user-drag","user-drag"]},"user-select":{type:e.Native,declarations:["-webkit-user-select","user-select"]},"text-shadow":{unit:"rem",type:e.Native,namespaces:["color"]},"text-size":{aliasGroups:["text","t"],kind:"number",unit:"rem",declarations:{"font-size":void 0,"line-height":["max(1.8em - max(0rem, ",void 0," - 1rem) * 1.12",", ",void 0,")"],"letter-spacing":["clamp(-0.072em, calc((",void 0," - 1rem) * -0.048), 0em)"]},type:e.Shorthand,namespaces:["font-size"]},"text-fill-color":{aliasGroups:["text","t"],kind:"color",type:e.Native,namespaces:["color","color.text"],declarations:["-webkit-text-fill-color"]},"text-stroke-width":{aliasGroups:["text-stroke"],values:["thin","medium","thick"],kind:"number",unit:"rem",type:e.Native,declarations:["-webkit-text-stroke-width"]},"text-stroke-color":{aliasGroups:["text-stroke"],kind:"color",type:e.Native,declarations:["-webkit-text-stroke-color"],namespaces:["color"]},"text-stroke":{unit:"rem",type:e.Native,declarations:["-webkit-text-stroke"]},"text-truncate":{subkey:"lines",declarations:{display:"-webkit-box","-webkit-box-orient":"vertical","-webkit-line-clamp":void 0,overflow:"hidden","overflow-wrap":"break-word","text-overflow":"ellipsis"},type:e.Shorthand},"box-shadow":{key:"shadow",subkey:"s",unit:"rem",type:e.Native,namespaces:["color"]},"table-layout":{type:e.Native},"transform-box":{aliasGroups:["transform"],type:e.Native},"transform-style":{aliasGroups:["transform"],values:["flat","preserve-3d"],type:e.Native},"transform-origin":{aliasGroups:["transform"],values:["top","bottom","right","left","center"],kind:"number",unit:"px",type:e.Native},transform:{type:e.Native,namespaces:["spacing"]},"translate()":{declarations:["transform"],unit:"rem",namespaces:["spacing"]},"translateX()":{declarations:["transform"],unit:"rem",namespaces:["spacing"]},"translateY()":{declarations:["transform"],unit:"rem",namespaces:["spacing"]},"translateZ()":{declarations:["transform"],unit:"rem",namespaces:["spacing"]},"translate3d()":{declarations:["transform"],unit:"rem",namespaces:["spacing"]},"scale()":{declarations:["transform"]},"scaleX()":{declarations:["transform"]},"scaleY()":{declarations:["transform"]},"scaleZ()":{declarations:["transform"]},"scale3d()":{declarations:["transform"]},"rotate()":{declarations:["transform"]},"rotateX()":{declarations:["transform"]},"rotateY()":{declarations:["transform"]},"rotateZ()":{declarations:["transform"]},"rotate3d()":{declarations:["transform"]},"perspective()":{declarations:["transform"]},"matrix()":{declarations:["transform"]},"matrix3d()":{declarations:["transform"]},"transition-property":{key:"~property",type:e.Native},"transition-timing-function":{key:"~easing",type:e.Native},"transition-duration":{key:"~duration",type:e.Native,unit:"ms"},"transition-delay":{key:"~delay",type:e.Native,unit:"ms"},transition:{sign:"~",type:e.NativeShorthand},"animation-delay":{key:"@delay",type:e.Native,unit:"ms"},"animation-direction":{key:"@direction",type:e.Native},"animation-duration":{key:"@duration",type:e.Native,unit:"ms"},"animation-fill-mode":{key:"@fill",type:e.Native},"animation-iteration-count":{key:"@iteration",type:e.Native},"animation-name":{key:"@name",type:e.Native,includeAnimations:!0},"animation-play-state":{key:"@play",type:e.Native},"animation-timing-function":{key:"@easing",type:e.Native},animation:{sign:"@",type:e.NativeShorthand,includeAnimations:!0},"border-collapse":{aliasGroups:["b","border"],values:["collapse","separate"],type:e.Native},"border-spacing":{unit:"rem",type:e.Native,namespaces:["spacing"]},"border-top-color":{aliasGroups:["bt","border-top"],kind:"color",type:e.Native,namespaces:["color","color.line"]},"border-bottom-color":{aliasGroups:["bb","border-bottom"],kind:"color",type:e.Native,namespaces:["color","color.line"]},"border-left-color":{aliasGroups:["bl","border-left"],kind:"color",type:e.Native,namespaces:["color","color.line"]},"border-right-color":{aliasGroups:["br","border-right"],kind:"color",type:e.Native,namespaces:["color","color.line"]},"border-x-color":{aliasGroups:["bx","border-x"],kind:"color",type:e.Shorthand,namespaces:["color","color.line"],declarations:["border-left-color","border-right-color"]},"border-y-color":{aliasGroups:["by","border-y"],kind:"color",type:e.Shorthand,namespaces:["color","color.line"],declarations:["border-top-color","border-bottom-color"]},"border-color":{aliasGroups:["b","border"],kind:"color",type:e.NativeShorthand,namespaces:["color","color.line"]},"border-top-left-radius":{key:"rtl",unit:"rem",type:e.Native,namespaces:["border-radius"]},"border-top-right-radius":{key:"rtr",unit:"rem",type:e.Native,namespaces:["border-radius"]},"border-bottom-left-radius":{key:"rbl",unit:"rem",type:e.Native,namespaces:["border-radius"]},"border-bottom-right-radius":{key:"rbr",unit:"rem",type:e.Native,namespaces:["border-radius"]},"border-top-radius":{key:"rt",unit:"rem",type:e.Shorthand,declarations:["border-top-left-radius","border-top-right-radius"],namespaces:["border-radius"]},"border-bottom-radius":{key:"rb",unit:"rem",type:e.Shorthand,declarations:["border-bottom-left-radius","border-bottom-right-radius"],namespaces:["border-radius"]},"border-left-radius":{key:"rl",unit:"rem",type:e.Shorthand,declarations:["border-top-left-radius","border-bottom-left-radius"],namespaces:["border-radius"]},"border-right-radius":{key:"rr",unit:"rem",type:e.Shorthand,declarations:["border-top-right-radius","border-bottom-right-radius"],namespaces:["border-radius"]},"border-radius":{key:"r",unit:"rem",type:e.NativeShorthand},"border-top-style":{aliasGroups:["bt","border-top"],values:t.BORDER_STYLE_VALUES,type:e.Native},"border-bottom-style":{aliasGroups:["bb","border-bottom"],values:t.BORDER_STYLE_VALUES,type:e.Native},"border-left-style":{aliasGroups:["bl","border-left"],values:t.BORDER_STYLE_VALUES,type:e.Native},"border-right-style":{aliasGroups:["br","border-right"],values:t.BORDER_STYLE_VALUES,type:e.Native},"border-x-style":{aliasGroups:["bx","border-x"],values:t.BORDER_STYLE_VALUES,type:e.Shorthand,declarations:["border-left-style","border-right-style"]},"border-y-style":{aliasGroups:["by","border-y"],values:t.BORDER_STYLE_VALUES,type:e.Shorthand,declarations:["border-top-style","border-bottom-style"]},"border-style":{aliasGroups:["b","border"],values:t.BORDER_STYLE_VALUES,type:e.NativeShorthand},"border-top-width":{aliasGroups:["bt","border-top"],kind:"number",unit:"rem",type:e.Native},"border-bottom-width":{aliasGroups:["bb","border-bottom"],kind:"number",unit:"rem",type:e.Native},"border-left-width":{aliasGroups:["bl","border-left"],kind:"number",unit:"rem",type:e.Native},"border-right-width":{aliasGroups:["br","border-right"],kind:"number",unit:"rem",type:e.Native},"border-x-width":{aliasGroups:["bx","border-x"],kind:"number",unit:"rem",type:e.Shorthand,declarations:["border-left-width","border-right-width"]},"border-y-width":{aliasGroups:["by","border-y"],kind:"number",unit:"rem",type:e.Shorthand,declarations:["border-top-width","border-bottom-width"]},"border-width":{aliasGroups:["b","border"],kind:"number",unit:"rem",type:e.NativeShorthand},"border-image-repeat":{aliasGroups:["border-image"],values:["stretch","repeat","round","space"],type:e.Native},"border-image-slice":{aliasGroups:["border-image"],type:e.Native},"border-image-source":{aliasGroups:["border-image"],kind:"image",type:e.Native},"border-image-width":{aliasGroups:["border-image"],values:["auto"],kind:"number",unit:"rem",type:e.Native},"border-image-outset":{aliasGroups:["border-image"],kind:"number",unit:"rem",type:e.Native},"border-image":{type:e.NativeShorthand},"border-top":{key:"bt",type:e.NativeShorthand,unit:"rem",transformer:"auto-fill-solid",namespaces:["color","color.line"]},"border-bottom":{key:"bb",type:e.NativeShorthand,unit:"rem",transformer:"auto-fill-solid",namespaces:["color","color.line"]},"border-left":{key:"bl",type:e.NativeShorthand,unit:"rem",transformer:"auto-fill-solid",namespaces:["color","color.line"]},"border-right":{key:"br",type:e.NativeShorthand,unit:"rem",transformer:"auto-fill-solid",namespaces:["color","color.line"]},"border-x":{key:"bx",unit:"rem",type:e.Shorthand,transformer:"auto-fill-solid",namespaces:["color","color.line"],declarations:["border-left","border-right"]},"border-y":{key:"by",unit:"rem",type:e.Shorthand,transformer:"auto-fill-solid",namespaces:["color","color.line"],declarations:["border-top","border-bottom"]},border:{key:"b",unit:"rem",type:e.NativeShorthand,transformer:"auto-fill-solid",namespaces:["color","color.line"]},"background-attachment":{aliasGroups:["bg"],values:["fixed","local","scroll"],type:e.Native},"background-blend-mode":{key:"bg-blend",type:e.Native},"background-color":{aliasGroups:["bg"],kind:"color",type:e.Native,namespaces:["color"]},"background-clip":{key:"bg-clip",type:e.Native},"background-origin":{key:"bg-origin",type:e.Native},"background-position":{aliasGroups:["bg"],values:["top","bottom","right","left","center"],type:e.Native,unit:"px"},"background-repeat":{aliasGroups:["bg"],values:["space","round","repeat","no-repeat","repeat-x","repeat-y"],type:e.Native},"background-size":{aliasGroups:["bg"],values:["auto","cover","contain"],kind:"number",unit:"rem",type:e.Native},"background-image":{aliasGroups:["bg"],kind:"image",type:e.Native,namespaces:["color"]},background:{key:"bg",type:e.NativeShorthand,namespaces:["color"]},"gradient()":{declarations:{"background-image":["linear-",void 0]},namespaces:["color"]},"mix-blend-mode":{key:"blend",type:e.Native},"backdrop-filter":{key:"bd",type:e.Native,declarations:["-webkit-backdrop-filter","backdrop-filter"],namespaces:["color"]},filter:{type:e.Native,namespaces:["color"]},"blur()":{declarations:["filter"]},"brightness()":{declarations:["filter"]},"contrast()":{declarations:["filter"]},"drop-shadow()":{declarations:["filter"],namespaces:["color"]},"grayscale()":{declarations:["filter"]},"hue-rotate()":{declarations:["filter"]},"invert()":{declarations:["filter"]},"opacity()":{declarations:["filter"]},"saturate()":{declarations:["filter"]},"sepia()":{declarations:["filter"]},fill:{type:e.Native,namespaces:["color"]},"stroke-dasharray":{type:e.Native},"stroke-dashoffset":{type:e.Native,namespaces:["spacing"]},"stroke-width":{aliasGroups:["stroke"],kind:"number",type:e.Native},stroke:{type:e.Native,namespaces:["color"]},x:{type:e.Native,namespaces:["spacing"]},y:{type:e.Native,namespaces:["spacing"]},cx:{type:e.Native,namespaces:["spacing"]},cy:{type:e.Native,namespaces:["spacing"]},rx:{type:e.Native},ry:{type:e.Native},"grid-column-start":{key:"grid-col-start",type:e.Native},"grid-column-end":{key:"grid-col-end",type:e.Native},"grid-column-span":{key:"grid-col-span",type:e.Shorthand,declarations:{"grid-column":["span ",void 0,"/span ",void 0]}},"grid-column":{key:"grid-col",type:e.NativeShorthand},"grid-columns":{key:"grid-cols",declarations:{display:"grid","grid-template-columns":["repeat(",void 0,",minmax(0,1fr))"]},type:e.Shorthand},"grid-row-start":{type:e.Native},"grid-row-end":{type:e.Native},"grid-row-span":{type:e.Shorthand,declarations:{"grid-row":["span ",void 0,"/span ",void 0]}},"grid-row":{type:e.NativeShorthand},"grid-rows":{declarations:{display:"grid","grid-auto-flow":"column","grid-template-rows":["repeat(",void 0,",minmax(0,1fr))"]},type:e.Shorthand},"grid-auto-columns":{key:"grid-auto-cols",type:e.Native},"grid-auto-flow":{key:"grid-flow",type:e.Native},"grid-auto-rows":{type:e.Native},"grid-template-areas":{type:e.Native},"grid-template-columns":{key:"grid-template-cols",type:e.Native,unit:"rem"},"grid-template-rows":{type:e.Native,unit:"rem"},"grid-template":{type:e.NativeShorthand},"grid-area":{type:e.NativeShorthand},grid:{type:e.NativeShorthand},"column-gap":{key:"gap-x",unit:"rem",type:e.Native,namespaces:["spacing"]},"row-gap":{key:"gap-y",unit:"rem",type:e.Native,namespaces:["spacing"]},gap:{unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},order:{key:"o",type:e.Native},"break-inside":{type:e.Native},"break-before":{type:e.Native},"break-after":{type:e.Native},"aspect-ratio":{key:"aspect",type:e.Native},"column-span":{key:"col-span",type:e.Native},"align-content":{subkey:"ac",type:e.Native},"align-items":{subkey:"ai",type:e.Native},"align-self":{subkey:"as",type:e.Native},"justify-content":{subkey:"jc",type:e.Native},"justify-items":{subkey:"ji",type:e.Native},"justify-self":{subkey:"js",type:e.Native},"place-content":{type:e.NativeShorthand},"place-items":{type:e.NativeShorthand},"place-self":{type:e.NativeShorthand},"list-style-position":{aliasGroups:["list-style"],values:["inside","outside"],type:e.Native},"list-style-type":{aliasGroups:["list-style"],values:["disc","decimal"],type:e.Native},"list-style-image":{aliasGroups:["list-style"],kind:"image",type:e.Native},"list-style":{type:e.NativeShorthand},"outline-color":{aliasGroups:["outline"],kind:"color",type:e.Native,namespaces:["color","color.line"]},"outline-offset":{unit:"rem",type:e.Native,namespaces:["spacing"]},"outline-style":{aliasGroups:["outline"],values:t.BORDER_STYLE_VALUES,type:e.Native},"outline-width":{aliasGroups:["outline"],values:["medium","thick","thin"],kind:"number",unit:"rem",type:e.Native},outline:{unit:"rem",type:e.NativeShorthand,namespaces:["outline-width","outline-style","outline-offset","outline-color","color.line","color"],transformer:"auto-fill-solid"},"accent-color":{key:"accent",type:e.Native,namespaces:["color"]},appearance:{type:e.Native},"caret-color":{key:"caret",type:e.Native,namespaces:["color","color.text"]},"scroll-behavior":{type:e.Native},"scroll-margin-left":{key:"scroll-ml",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-margin-right":{key:"scroll-mr",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-margin-top":{key:"scroll-mt",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-margin-bottom":{key:"scroll-mb",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-margin-x":{key:"scroll-mx",unit:"rem",type:e.Shorthand,declarations:["scroll-margin-left","scroll-margin-right"],namespaces:["spacing"]},"scroll-margin-y":{key:"scroll-my",unit:"rem",type:e.Shorthand,declarations:["scroll-margin-top","scroll-margin-bottom"],namespaces:["spacing"]},"scroll-margin":{key:"scroll-m",unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},"scroll-padding-left":{key:"scroll-pl",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-padding-right":{key:"scroll-pr",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-padding-top":{key:"scroll-pt",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-padding-bottom":{key:"scroll-pb",type:e.Native,unit:"rem",namespaces:["spacing"]},"scroll-padding-x":{key:"scroll-px",unit:"rem",type:e.Shorthand,declarations:["scroll-padding-left","scroll-padding-right"],namespaces:["spacing"]},"scroll-padding-y":{key:"scroll-py",unit:"rem",type:e.Shorthand,declarations:["scroll-padding-top","scroll-padding-bottom"],namespaces:["spacing"]},"scroll-padding":{key:"scroll-p",unit:"rem",type:e.NativeShorthand,namespaces:["spacing"]},"scroll-snap-align":{aliasGroups:["scroll-snap"],values:["start","end","center"],type:e.Native},"scroll-snap-stop":{aliasGroups:["scroll-snap"],values:["normal","always"],type:e.Native},"scroll-snap-type":{aliasGroups:["scroll-snap"],values:["x","y","block","inline","both"],type:e.Native},"will-change":{type:e.Native},"writing-mode":{key:"writing",type:e.Native},direction:{type:e.Native},"shape-outside":{key:"shape",type:e.Native},"shape-margin":{kind:"number",unit:"rem",type:e.Native,namespaces:["spacing"]},"shape-image-threshold":{type:e.Native},"clip-path":{key:"clip",type:e.Native},quotes:{type:e.Native},"mask-image":{type:e.Native,declarations:["-webkit-mask-image","mask-image"]},group:{matcher:"^\\{.+?\\}",type:e.Shorthand,declarer:"core.group"},variable:{matcher:"^\\$[\\w-]+:",type:e.Shorthand,declarer:"core.variable"}}}function ts(){return y?f:(y=1,f={light:{color:{ground:"$color-grey-0",base:"$color-white",invert:"$color-black",stone:{"":"$color-stone-30",active:"$color-stone-40",text:"$color-stone-90"},gray:{"":"$color-gray-30",active:"$color-gray-40",text:"$color-gray-90"},grey:{"":"$color-grey-30",active:"$color-grey-40",text:"$color-grey-90"},slate:{"":"$color-slate-30",active:"$color-slate-40",text:"$color-slate-90"},brown:{"":"$color-brown-40",active:"$color-brown-50",text:"$color-brown-90"},orange:{"":"$color-orange-40",active:"$color-orange-50",text:"$color-orange-90"},amber:{"":"$color-amber-40",active:"$color-amber-50",text:"$color-amber-90"},yellow:{"":"$color-yellow-40",active:"$color-yellow-50",text:"$color-yellow-90"},lime:{"":"$color-lime-40",active:"$color-lime-50",text:"$color-lime-90"},green:{"":"$color-green-40",active:"$color-green-50",text:"$color-green-90"},beryl:{"":"$color-beryl-40",active:"$color-beryl-50",text:"$color-beryl-90"},teal:{"":"$color-teal-40",active:"$color-teal-50",text:"$color-teal-90"},cyan:{"":"$color-cyan-40",active:"$color-cyan-50",text:"$color-cyan-90"},sky:{"":"$color-sky-60",active:"$color-sky-70",text:"$color-white"},blue:{"":"$color-blue-60",active:"$color-blue-70",text:"$color-white"},indigo:{"":"$color-indigo-60",active:"$color-indigo-70",text:"$color-white"},violet:{"":"$color-violet-60",active:"$color-violet-70",text:"$color-white"},purple:{"":"$color-purple-60",active:"$color-purple-70",text:"$color-white"},fuchsia:{"":"$color-fuchsia-60",active:"$color-fuchsia-70",text:"$color-white"},pink:{"":"$color-pink-60",active:"$color-pink-70",text:"$color-white"},crimson:{"":"$color-crimson-60",active:"$color-crimson-70",text:"$color-white"},red:{"":"$color-red-60",active:"$color-red-70",text:"$color-white"},line:{neutral:"$color-grey-60",light:"oklch(0% 0 none / 0.12)",lighter:"oklch(0% 0 none / 0.09)",lightest:"oklch(0% 0 none / 0.06)"},text:{invert:"$color-white",strong:"$color-grey-100",neutral:"$color-grey-70",lightest:"$color-grey-30",lighter:"$color-grey-40",light:"$color-grey-50",stone:"$color-stone-60",gray:"$color-gray-60",grey:"$color-grey-60",slate:"$color-slate-60",brown:"$color-brown-60",orange:"$color-orange-60",amber:"$color-amber-60",yellow:"$color-yellow-70",lime:"$color-lime-70",green:"$color-green-70",beryl:"$color-beryl-70",teal:"$color-teal-70",cyan:"$color-cyan-70",sky:"$color-sky-70",blue:"$color-blue-60",indigo:"$color-indigo-60",violet:"$color-violet-60",purple:"$color-purple-60",fuchsia:"$color-fuchsia-60",pink:"$color-pink-60",crimson:"$color-crimson-60",red:"$color-red-60"}}},dark:{color:{ground:"$color-gray-100",base:"$color-gray-95",invert:"$color-white",stone:{"":"$color-stone-40",active:"$color-stone-30",text:"$color-stone-95"},gray:{"":"$color-gray-40",active:"$color-gray-30",text:"$color-gray-95"},grey:{"":"$color-grey-40",active:"$color-grey-30",text:"$color-grey-95"},slate:{"":"$color-slate-40",active:"$color-slate-30",text:"$color-slate-95"},brown:{"":"$color-brown-50",active:"$color-brown-40",text:"$color-brown-95"},orange:{"":"$color-orange-50",active:"$color-orange-40",text:"$color-orange-95"},amber:{"":"$color-amber-50",active:"$color-amber-30",text:"$color-amber-95"},yellow:{"":"$color-yellow-50",active:"$color-yellow-30",text:"$color-yellow-95"},lime:{"":"$color-lime-50",active:"$color-lime-30",text:"$color-lime-95"},green:{"":"$color-green-50",active:"$color-green-30",text:"$color-green-95"},beryl:{"":"$color-beryl-50",active:"$color-beryl-30",text:"$color-beryl-95"},teal:{"":"$color-teal-50",active:"$color-teal-30",text:"$color-teal-95"},cyan:{"":"$color-cyan-50",active:"$color-cyan-30",text:"$color-cyan-95"},sky:{"":"$color-sky-50",active:"$color-sky-40",text:"$color-white"},blue:{"":"$color-blue-50",active:"$color-blue-40",text:"$color-white"},indigo:{"":"$color-indigo-50",active:"$color-indigo-40",text:"$color-white"},violet:{"":"$color-violet-50",active:"$color-violet-40",text:"$color-white"},purple:{"":"$color-purple-50",active:"$color-purple-40",text:"$color-white"},fuchsia:{"":"$color-fuchsia-50",active:"$color-fuchsia-40",text:"$color-white"},pink:{"":"$color-pink-50",active:"$color-pink-40",text:"$color-white"},crimson:{"":"$color-crimson-50",active:"$color-crimson-40",text:"$color-white"},red:{"":"$color-red-50",active:"$color-red-40",text:"$color-white"},line:{neutral:"$color-gray-30",light:"oklch(100% 0 none / 0.12)",lighter:"oklch(100% 0 none / 0.09)",lightest:"oklch(100% 0 none / 0.06)"},text:{invert:"$color-black",strong:"$color-white",neutral:"$color-gray-30",lightest:"$color-gray-60",lighter:"$color-gray-50",light:"$color-gray-40",stone:"$color-stone-30",gray:"$color-gray-30",grey:"$color-grey-30",slate:"$color-slate-30",brown:"$color-brown-30",orange:"$color-orange-30",amber:"$color-amber-40",yellow:"$color-yellow-40",lime:"$color-lime-40",green:"$color-green-40",beryl:"$color-beryl-40",teal:"$color-teal-40",cyan:"$color-cyan-40",sky:"$color-sky-30",blue:"$color-blue-30",indigo:"$color-indigo-30",violet:"$color-violet-30",purple:"$color-purple-30",fuchsia:"$color-fuchsia-30",pink:"$color-pink-30",crimson:"$color-crimson-30",red:"$color-red-30"}}}})}function tl(){return v?g:(v=1,g={translate:{unit:"rem"},translateX:{unit:"rem"},translateY:{unit:"rem"},translateZ:{unit:"rem"},translate3d:{unit:"rem"},perspective:{unit:"rem"},skew:{unit:"deg"},skewX:{unit:"deg"},skewY:{unit:"deg"},skewZ:{unit:"deg"},skew3d:{unit:"deg"},rotate:{unit:"deg"},rotateX:{unit:"deg"},rotateY:{unit:"deg"},rotateZ:{unit:"deg"},rotate3d:{unit:"deg"},blur:{unit:"rem"},"drop-shadow":{unit:"rem"},"hue-rotate":{unit:"deg"},rgb:{unit:""},rgba:{unit:""},hsl:{unit:""},hsla:{unit:""},color:{unit:""},"color-contrast":{unit:""},"color-mix":{unit:""},hwb:{unit:""},lab:{unit:""},lch:{unit:""},oklab:{unit:""},oklch:{unit:""},"light-dark":{unit:""},clamp:{unit:""},repeat:{unit:""},"linear-gradient":{},"radial-gradient":{},"conic-gradient":{},"repeating-linear-gradient":{},"repeating-radial-gradient":{},"repeating-conic-gradient":{},matrix:{unit:""},matrix3d:{unit:""},scale:{unit:""},scale3d:{unit:""},scaleX:{unit:""},scaleY:{unit:""},scaleZ:{unit:""},$:{transformer:"core.variable"},calc:{transformer:"core.calc"}})}function tn(){return k?b:(k=1,b={"4xs":360,"3xs":480,"2xs":600,xs:768,sm:834,md:1024,lg:1280,xl:1440,"2xl":1600,"3xl":1920,"4xl":2560})}function tc(){if(x)return e3;x=1;var e=e4(),t=e6(),r=e7(),i=e8(),o=tt(),a=ta(),s=ts(),l=tl(),n=tn();return e3.at=e,e3.selectors=t,e3.utilities=r,e3.animations=i,e3.variables=o,e3.rules=a,e3.modes=s,e3.functions=l,e3.screens=n,e3.config={at:e,selectors:t,utilities:r,rules:a,functions:l,animations:i,variables:o,modes:s,screens:n,scope:"",rootSize:16,baseUnit:4,important:!1,defaultMode:"light",modeTrigger:"media"},e3}var th={};function tu(){return N?S:(N=1,S=function(e){let t;if("undefined"!=typeof CSS)return CSS.escape(e);if(0==arguments.length)throw TypeError("`CSS.escape` requires an argument.");let r=String(e),i=r.length,o=-1,a="",s=r.charCodeAt(0);if(1==i&&45==s)return"\\"+r;for(;++o<i;){if(0==(t=r.charCodeAt(o))){a+="�";continue}if(t>=1&&t<=31||127==t||0==o&&t>=48&&t<=57||1==o&&t>=48&&t<=57&&45==s){a+="\\"+t.toString(16)+" ";continue}if(t>=128||45==t||95==t||t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122){a+=r.charAt(o);continue}a+="\\"+r.charAt(o)}return a})}function tp(){if(R)return w;R=1;var e=to();return w=function(t,r="",i=1){if("number"==typeof t)return{unit:r,type:"number",value:"rem"===r||"em"===r?t/i:t};let o=t.match(e.UNIT_REGEX);if(o){let e=parseFloat(o[1]),a=o[2]||"";return a||"rem"!==r&&"em"!==r||(e/=i,a=r),{token:t,value:e,unit:a||r,type:"number"}}return{token:t,value:t,type:"string"}}}function td(){return E?$:(E=1,$=function(e,t="(",r=")"){let i=[],o=null,a=null;for(let s=0;s<e.length;s++){let l=e[s],n=e[s-1];if("\\"===l){s++;continue}if(('"'===l||"'"===l)&&"\\"!==n){a===l?a=null:a||(a=l);continue}if(!a){if(e.startsWith(t,s))i.push({start:s}),s+=t.length-1;else if(e.startsWith(r,s)){let a=i.pop();a&&(o={start:a.start,end:s,pre:e.slice(i.length>0?i[i.length-1].start+t.length:0,a.start),body:e.slice(a.start+t.length,s),post:e.slice(s+r.length)}),s+=r.length-1}}}return o})}function tm(){if(L)return C;L=1;var e=to(),t=td(),r=tp(),i=A?_:(A=1,_=function(e,t,r){let i="",o=!1,a=!1;for(let s=0;s<e.length;s++){let l=e[s],n=e[s-1];"'"!==l||"\\"===n||a?'"'!==l||"\\"===n||o||(a=!a):o=!o,l!==t||o||a?i+=l:i+=r}return i}),o=T?O:(T=1,O=function(e,t){let r=[],i="",o=!1,a=!1;for(let s=0;s<e.length;s++){let l=e[s],n=e[s-1];"'"!==l||a||"\\"===n?'"'!==l||o||"\\"===n||(a=!a):o=!o,l!==t||o||a?i+=l:(r.push(i.trim()),i="")}return i&&r.push(i.trim()),r});return C=function(a,s,l=!0){let n,c,h=a=>{let u=[],p=t(a);if(p){if(p.pre&&u.push(...h(p.pre)),p.body)if("supports"===n)u.push({type:"group",children:[{type:"string",value:i(p.body,"|"," ")}]});else{let e=h(p.body);e.length>1?u.push({type:"group",children:h(p.body)}):u.push(...e)}p.post&&u.push(...h(p.post))}else u.push(...(t=>{let i=[...t.matchAll(/([a-zA-Z0-9-:%|]+|[&|!|,|>|<|=][=]?)/g)].map(e=>e[0]),a=[],h=e=>{let t=a[a.length-1];"number"!==e.type||e.name||(t?.type==="comparison"?(e.operator=t.value,e.raw&&t.raw&&(e.raw=t.raw+e.raw),a.pop(),t=a[a.length-1],t?.type==="string"?(e.name=t.value,e.raw&&t.raw&&(e.raw=t.raw+e.raw),a.pop()):e.name="width"):(e.name="width",e.operator=">=")),a.push(e)};return i.forEach(t=>{if(e.AT_COMPARISON_OPERATORS.includes(t)){let e={type:"comparison",value:t};l&&(e.raw=t),a.push(e);return}if(t in e.AT_LOGICAL_OPERATORS){let r={type:"logical",value:e.AT_LOGICAL_OPERATORS[t]};l&&(r.raw=t),a.push(r);return}let i=s.atRules.get(t);if(!n&&!c){if(c=t,e.AT_IDENTIFIERS.includes(c)){n=c;return}n=i?i.id:e.AT_COMPARABLE_FEATURES.includes(c)?"media":c.charAt(0).match(/[a-zA-Z-]/)?"container":"media"}let u={type:"string"};if(l&&(u.raw=t),i)return void(1===i.nodes.length?h({...i.nodes[0],raw:t}):i.nodes.length&&h({raw:t,children:i.nodes}));{let[e,i]=o(t,":");if(i?(u.name=e,u.value=i):u.value=e,"container"===n||"media"===n){let{token:e,...t}=r(u.value,"rem",s.config.rootSize);Object.assign(u,t)}h(u)}}),a})(a));return u};return{nodes:h(a),id:n||"media"}}}function tf(){return G?I:(G=1,I=function(e){let t=r=>r.map(e=>{let r="";if("children"in e){let i=t(e.children);r="group"===e.type?"("+i+")":i}else{let t="number"===e.type?String(e.value)+(e.unit||""):e.value;r="name"in e?"operator"in e?`(${e.name}${e.operator}${t})`:`(${e.name}:${t})`:t}return r}).filter(Boolean).join("layer"===e.id?".":" "),r=t(e.nodes);return"@"+e.id+(r?" "+r:"")})}function ty(){if(M)return j;M=1;var e=to(),t=td();let r=RegExp(`(?:[a-zA-Z0-9-]+)|([${e.SELECTOR_COMBINATORS.join("")}#.:,*])|(a-zA-Z0-9-)`,"g");return j=function(i,o,a=!0){let s=t=>{let i=[],s="",l=0;for(let n of t.matchAll(r)){let r,c=n[0];if(l+=c.length,":"===c||"."===c||"#"===c){s+=c;continue}let h=c,u=o.selectors.get(s+c);if(u){let e=u[u.length-1];i.push(1===u.length&&e.type?{...e,raw:s+c}:{children:u,raw:s+c}),s="";continue}if(e.SELECTOR_COMBINATORS.includes(c)){if(r="combinator","_"===c){let e=t[l];"_"!==t[l-c.length-1]&&"_"!==e&&(h=" ")}}else","===c?r="separator":"*"===c?r="universal":":"===s?r="pseudo-class":"::"===s?r="pseudo-element":"."===s?r="class":"#"===s&&(r="id");i.push({value:h,...a&&{raw:s+c},...r&&{type:r}}),s=""}return i},l=(e,r=[])=>{let i=t(e);if(i){let e,{pre:t,body:o,post:a}=i;if(o){let r=t.lastIndexOf(":");-1!==r&&(e=t.slice(r),t=t.slice(0,r))}if(t&&r.push(...l(t)),o){let t=l(o);if(e){let i=s(e)[0];t.length&&(i.children=t),r.push(i)}else r.push(...t)}return a&&r.push(...l(a)),r}let o=t(e,"[","]");if(o){let{pre:e,body:t,post:i}=o;return e&&r.push(...l(e)),r.push({value:t,type:"attribute",...a&&{raw:`[${t}]`}}),i&&r.push(...l(i)),r}return s(e)};return l(i)}}function tg(){if(V)return U;V=1;var e=to();let t={class:".","pseudo-class":":","pseudo-element":"::",attribute:"",combinator:"",id:"#"};return U=function(r,i=""){let o=e=>{if("attribute"===e.type)return`[${e.value}]`;if("combinator"===e.type)return e.value;let r=e.type&&t[e.type]||"",i=e.value?r+e.value:"";if("children"in e&&e.children?.length){let t=e.children.map(o).join("");return e.value?i+`(${t})`:i+t}return i},a="",s="",l=[];if(r.flatMap(e=>!("value"in e)&&"children"in e&&e.children?.length?e.children:e).forEach(e=>{","===e.value?(l.push(s),s=""):"of"===e.value&&"children"in e?a+=e.children.map(o).join(""):s+=o(e)}),s&&l.push(s),a){let t=a.charAt(a.length-1);e.SELECTOR_COMBINATORS.includes(t)||" "===t||(a+=" ")}return l.length?l.map(e=>a+i+e).join(","):a+i}}var tv={};function tb(){if(z)return tv;z=1,Object.defineProperty(tv,"__esModule",{value:!0});let e={hover:1,focus:2,active:3,disabled:4},t={">=":"<","<=":">",">":"<=","<":">="};return tv.calcRulePriority=function(r){let i=[],o=e=>{for(let[r,o]of(function(e){let r=new Map,i=(e,o=!1)=>{(e??[]).forEach((e,a,s)=>{let l=s[a-1];if("operator"in e){let i=r.get(e.name)??{},a=e.operator;switch(o&&(a=t[a]),l?.type==="logical"&&"not"===l.value&&(a=t[a]),a){case">":i.min=e.value+.02;break;case">=":i.min=e.value;break;case"<":i.max=e.value-.02;break;case"<=":i.max=e.value}r.set(e.name,i)}"children"in e&&Array.isArray(e.children)&&i(e.children,l?.type==="logical"&&"not"===l.value)})};return i(e),r})(e).entries()){let e=o.max??Number.MAX_SAFE_INTEGER,t=o.min??0;i.push([r,t,e])}};return r.atRules?.media&&o(r.atRules.media),r.atRules?.container&&o(r.atRules.container),i.sort(([e],[t])=>e.localeCompare(t,void 0,{numeric:!0})),{features:i,selector:function t(r=[]){let i=0;for(let o of r)"value"in o&&"string"==typeof o.value&&(i+=e[o.value]??0),"children"in o&&Array.isArray(o.children)&&(i+=t(o.children));return i}(r.selectorNodes??[])}},tv.default=function(e,t){let r=e=>{let t=e.selectorNodes?.length,r=!!e.atRules,i=!!e.mode;return r?3:i?2:+!!t},i=r(e),o=r(t);if(i!==o)return i-o;let a=function(e,t){let r=Math.max(e.length,t.length);for(let i=0;i<r;i++){let r=e[i],o=t[i];if(!r)return -1;if(!o)return 1;let[a,s,l]=r,[n,c,h]=o,u=a.localeCompare(n,void 0,{numeric:!0});if(0!==u)return u;let p=l-s,d=h-c;if(p!==d)return d-p;if(s!==c)return c-s;if(l!==h)return h-l}return 0}(e.priority.features||[],t.priority.features||[]);if(0!==a)return a;let s=e.priority.selector-t.priority.selector;if(0!==s)return s;let l=e.type-t.type;return 0!==l?l:e.key.localeCompare(t.key,void 0,{numeric:!0})},tv}function tk(){if(ea)return th;ea=1;var e=tu(),t=tr(),r=to(),i=tp(),o=tm(),a=tf(),s=ty(),l=tg(),n=tb(),c=function(){if(K)return F;K=1;var e=function(){if(P)return D;P=1;var e=tu(),t=to();return D=function(r){let i={},o=e=>{let t=e.indexOf(":");-1!==t&&(i[e.slice(0,t)]=e.slice(t+1))},a=t=>{var r=t.text;let i=r.slice(e(t.name).length).match(/\{(.*)\}/)?.[1].split(";");if(i)for(let e of i)o(e);if(t.animationNames)for(let e of(this.animationNames||(this.animationNames=new Set),t.animationNames))this.animationNames.add(e);if(t.variableNames)if(this.variableNames)for(let e of t.variableNames)this.variableNames.add(e);else this.variableNames=new Set(t.variableNames)},s=[],l="",n=()=>{l&&(s.push(l.replace(/ /g,"|")),l="")},c=1;for(let e of(!function e(i){for(;c<r.length;c++){let o=r[c];if(!i){if(";"===o){n();continue}if("}"===o)break}if(l+=o,i===o){if("'"===i||'"'===i){let e=0;for(let t=l.length-2;"\\"===l[t];t--)e++;if(e%2)continue}break}o in t.VALUE_DELIMITERS&&"'"!==i&&'"'!==i&&(c++,e(t.VALUE_DELIMITERS[o]))}}(""),n(),s)){let t=this.css.generate(e,this.mode);if(t.length)for(let e of t)a(e);else o(e)}return i}}(),t=Y?B:(Y=1,B=function(e){return{["--"+this.keyToken.slice(1,-1)]:e}});return F={pair:q?X:(q=1,X=function(e,t,r){let[i,o]=r,a=t.length;return{[i]:t[0].text,[o]:1===a?t[0].text:t[2].text}}),"core.group":e,"core.variable":t}}(),h=Q?W:(Q=1,W={"auto-fill-solid":function(){if(H)return Z;H=1;var e=to();return Z=function(t){if(t.length<2)return t;let r=!1,i=!1;for(let o of t)("string"===o.type&&e.BORDER_STYLE_VALUES.includes(o.value)||"variable"===o.type&&e.BORDER_STYLE_VALUES.includes(String(o.variable?.value)))&&(r=!0),"function"===o.type&&"var"===o.name&&(i=!0);return r||i||t.push({type:"separator",value:" ",token:"|"},{type:"string",value:"solid",token:"solid"}),t}}()}),u=eo?ei:(eo=1,ei={"core.calc":function(){if(ee)return J;ee=1;var e=tl(),t=to();return J=function(r,i){let o=[],a=0,s=(i,l,n,c,h)=>{let u,p=o!==i,d=[],m=!1,f=!1,y=!1,g=!1,v="",b=(e,o="",s="")=>{if(!1===u&&" "!==e&&this.definition.unit&&(u=void 0,g||k()),v){if(!h){let e=t.BASE_UNIT_REGEX.exec(v);e&&(v=(e[1]*(this.css.config.baseUnit??1)).toString())}if(m||n)i.push({type:"string",value:v,token:v});else{let e={...this.parseValue(v),token:v};if(!f&&isNaN(+v)&&"number"===e.type&&(f=!0),g)isNaN(+v)?"number"===e.type?(i.push(e),y=!0):i.push(e):i.push({type:"number",value:+v,token:v});else if(p){let e={type:"string",value:v,token:v};d.push(e),i.push(e)}else i.push(e)}v=""}e&&(("+"===e||"-"===e)&&x(),o&&" "===r[a-1]&&(o=""),s&&" "===r[a+1]&&(s=""),l?i.push({type:"separator",value:e,text:e,token:e}):i.push({type:"separator",value:e,text:o+e+s,token:e})),m=!1},k=()=>{("rem"===this.definition.unit||"em"===this.definition.unit)&&i.push({type:"separator",value:"/",text:" / ",token:"/"},{type:"number",value:this.css.config.rootSize,token:String(this.css.config.rootSize)}),i.push({type:"separator",value:"*",text:" * ",token:"*"},{type:"number",value:1,unit:this.definition.unit,token:this.definition.unit})},x=()=>{!g||y||c||p&&!f||k(),g=!1,y=!1};for(;a<r.length;a++){let t=r[a];if("("===t){let r=/^([+-])/.exec(v);r&&i.push({type:"string",value:r[1],token:r[1]});let o=r?v.slice(1):v,l={type:"function",name:o,symbol:t,children:[],bypassTransform:"calc"===o,token:v};i.push(l),v="",a++;let n="$"===o||"var"===o;if(!(u=s(l.children,""!==o&&"calc"!==o&&(n||Object.prototype.hasOwnProperty.call(e,o)),m||n||g&&y,g,n)||"var"===o)&&"$"===o){let e=this.css.variables.get(l.children[0].value)?.type;u=!e||"string"===e}u&&(f=!0,y=!0)}else if(")"===t){if(b(""),f)for(let e of d)Object.assign(e,this.parseValue(e.value));return f}else if(","===t)b(t,""," ");else if(" "===t)b(t);else{let e=r[a-1];switch(t){case"+":case"-":v||")"===e?b(t," "," "):v+=t;break;case"*":this.definition.unit&&(g=!0),b(t," "," ");break;case"/":this.definition.unit&&(g=!0),b(t," "," "),m=!0;break;default:v+=t}}}b(""),x()};return s(o,!1,!1,!1,!1),"calc("+this.resolveValue(o,this.definition.unit,i,!0)+")"}}(),"core.variable":er?et:(er=1,et=function(e){let t,r,i=e.indexOf(",");return -1!==i?(t=e.slice(0,i),r=e.slice(i+1)):t=e,[{type:"variable",name:t,fallback:r,token:e}]})});class p{name;css;registeredSyntax;fixedClass;native;atRules;priority;type=t.Normal;declarations;layer;valid=!0;animationNames;variableNames;constructor(e,r,i,a,l){let u,p;this.name=e,this.css=r,this.registeredSyntax=i,this.fixedClass=a,this.mode=l,this.layer=r.generalLayer,Object.assign(this,i);let{id:d,definition:m}=i,{declarer:f,transformer:y,type:g,unit:v,sign:b}=m;if(this.type=g,this.type===t.Utility)u=e.slice(d.length-1);else{let t;if(b&&e.startsWith(b))t=e.slice(1);else if(d.endsWith("()"))t=e;else if("group"===d)t=e;else{let r=e.indexOf(":");this.keyToken=e.slice(0,r+1),t=e.slice(r+1)}this.valueComponents=[];let r=this.parseValues(this.valueComponents,0,t,v,"",void 0,!1,m.includeAnimations?Array.from(this.css.animations.keys()):[]);this.valueToken=t.slice(0,r),u=t.slice(r)}"!"===u[0]&&(this.important=!0,u=u.slice(1)),this.stateToken=u;let k=u.split("@"),x=k[0];x&&(this.selectorNodes=s(x,r));for(let e=1;e<k.length;e++){let t=k[e];if(r.config.modes?.[t]){this.mode=t;continue}this.atToken=(this.atToken||"")+"@"+t;let i=o(t,r),a=this.atRules?.[i.id];a?a.push(...i.nodes):this.atRules={...this.atRules,[i.id]:i.nodes}}if(this.mode&&"media"===r.config.modeTrigger){let e={name:"prefers-color-scheme",value:this.mode};this.atRules?.media?this.atRules.media.push(e):this.atRules={media:[e]}}if(this.fixedClass)this.layer=r.componentsLayer;else{let e=this.atRules?.layer?.length===1&&this.atRules.layer[0];e&&("base"===e.value?(this.layer=r.baseLayer,this.atRules.layer=void 0):"preset"===e.value&&(this.layer=r.presetLayer,this.atRules.layer=void 0))}if(this.valueComponents){if(y)if("string"==typeof y){let e=h[y];this.valueComponents=e.call(this,this.valueComponents)}else{let[e,t]=y,r=h[e];this.valueComponents=r.call(this,this.valueComponents,t)}if(p=this.resolveValue(this.valueComponents,v,[],!1),m.declarations){let e={};if(Array.isArray(m.declarations))for(let t of m.declarations)e[t]=p;else for(let t in m.declarations){let r=m.declarations[t];e[t]=void 0===r?p:Array.isArray(r)?r.map(e=>void 0===e?p:e).join(""):r}this.declarations=e}else if(f)if("string"==typeof f){let e=c[f];this.declarations=e.call(this,p,this.valueComponents)}else{let[e,t]=f,r=c[e];this.declarations=r.call(this,p,this.valueComponents,t)}else d&&(this.declarations={[d]:p})}else this.declarations=m.declarations;if(Object.entries(this.declarations??{}).length){for(let e in this.declarations)if(this.css.animations&&("animation"===e||"animation-name"===e)){let t=this.declarations[e];if(!t)continue;for(let e of t.split(" "))if(this.css.animations.has(e)){this.animationNames?this.animationNames.add(e):this.animationNames=new Set([e]);continue}}this.priority=n.calcRulePriority(this)}else this.valid=!1}get text(){if(!this.valid)return"";let e=[];for(let t in this.declarations){let r=this.declarations[t],i=t+":"+String(r);e.push(i+((this.important||this.css.config.important)&&!i.endsWith("!important")?"!important":""))}let t=this.selectorText+"{"+e.join(";")+"}";return void 0!==this.atRules&&r.AT_IDENTIFIERS.forEach(e=>{let r=this.atRules?.[e];r&&(t=a({id:e,nodes:r})+"{"+t+"}")}),t}get selectorText(){let t="";if(this.css.config.scope&&(t=this.css.config.scope+" "+t),this.mode){let e=this.css.getModeSelector(this.mode);e&&(t=e+" "+t)}let r=t+"."+e(this.fixedClass??this.name);return this.selectorNodes?l(this.selectorNodes,r):r}resolveValue=(e,t,i,o)=>{let{functions:a}=this.css.config,s="";for(let l of e)switch(l.type){case"function":let e=a&&a[l.name],n=e?.transformer;if(n&&!l.bypassTransform){let r,a=this.resolveValue(l.children,e.unit??t,i,o||"calc"===l.name);if("string"==typeof n)r=u[n].call(this,a,i);else{let[e,t]=n;r=u[e].call(this,a,i,t)}s+=l.token=l.text="string"==typeof r?r:this.resolveValue(r,e?.unit??t,i,o)}else s+=l.token=l.text=l.name+l.symbol+this.resolveValue(l.children,e?.unit??t,i,o)+r.VALUE_DELIMITERS[l.symbol];break;case"variable":let c=this.css.variables.get(l.name);if(c){let e=(e,t)=>{if(c.modes)if(this.mode){let t=c.modes[this.mode]??c;t?.value&&e(t)}else this.variableNames?this.variableNames.add(l.name):this.variableNames=new Set([l.name]),t();else e(c)};switch(c.type){case"string":e(e=>{let r=[];this.parseValues(r,0,e.value,t,"",void 0,o,[...i,l.name]),s+=l.text=this.resolveValue(r,t,[...i,l.name],o)},()=>{s+=l.text=`var(--${l.name})`});break;case"number":e(e=>{if(o)s+=l.text=String(e.value);else{let r=this.parseValue(e.value,t);s+=l.text=r.value+(r.unit??"")}},()=>{s+=l.text=t?`calc(var(--${l.name}) / 16 * 1rem)`:`var(--${l.name})`});break;case"color":let r=l.alpha;e(e=>{(r=(r||1)*(e.alpha||1))<1?s+=l.text=`${e.space}(${e.value}/${r})`:s+=l.text=`${e.space}(${e.value})`},()=>{void 0!==r?s+=l.text=`color-mix(in oklab,var(--${l.name}) ${100*Number(r)}%,transparent)`:s+=l.text=`var(--${l.name})`})}}else s+=l.text=`var(--${l.name}${l.fallback?","+l.fallback:""})`;break;case"separator":s+=l.text?l.text:l.text=l.value;break;case"number":s+=l.text=l.value+(l.unit||"");break;default:s+=l.text=l.value}return s};parseValues=(e,t,i,o,a,s,l=!1,n=[])=>{let c=void 0===s,h=!c&&(s.endsWith("$")||s.endsWith("var")),u="'"===a||'"'===a,p=[","];this.definition.separators?.length&&p.push(...this.definition.separators);let d="",m=()=>{if(d){let t=!1;if(!h||e.length){let r=(r,i)=>{let o=this.css.variables.get(r),a=this.variables?.get(r)||o;if(a){let o=a.name??r;if(!n.includes(o)){t=!0;let r={type:"variable",name:o,variable:this.css.variables.get(o),token:d};i&&(r.alpha=Number(i)),e.push(r)}}};if(/^\$[a-zA-Z0-9-]+(?:\/[^\/]+)?$/.test(d)){let[e,t]=d.slice(1).split("/");r(e,t)}else if(r(d),!t){let[e,t]=d.split("/");r(e,t)}}if(!t){if(!h){let e=r.BASE_UNIT_REGEX.exec(d);e&&(d=String(e[1]*(this.css.config.baseUnit??1)))}if(l)e.push({type:"string",value:d,token:d});else{let t=this.parseValue(d,o);e.push({...t,token:d})}}d=""}};for(;t<i.length;t++){let n=i[t];if(n===a){if(u){let e=0;for(let t=d.length-1;"\\"===d[t];t--)e++;if(e%2){d+=n;continue}m()}else m();return t}if(!u&&n in r.VALUE_DELIMITERS){let a=d,c={type:"function",name:a,symbol:n,children:[],token:""};e.push(c),d="";let h="("===n?this.css.config.functions?.[a]:void 0;t=this.parseValues(c.children,++t,i,h?.unit??o,r.VALUE_DELIMITERS[n],a||s||"",l||"calc"===a)}else if("|"!==n&&" "!==n||"}"===a||u&&"path"!==s){if(!u){if("."===n)if(isNaN(+i[t+1])){if(c)break}else"-"===i[t-1]&&(d+="0");else if(p.includes(n)){m(),e.push({type:"separator",value:n,text:(","===n?"":" ")+n+(","===n?"":" "),token:n});continue}else if(c&&("#"===n&&(d||e.length&&"separator"!==e[e.length-1].type)||["!","*",">","+","~",":","[","@","_"].includes(n)))break}d+=n}else m(),e.push({type:"separator",value:" ",token:n})}return m(),t};parseValue(e,t=this.definition.unit){let r=i(e,t,this.css.config.rootSize);if(this.definition.unit&&"string"===r.type&&/^\d+\/\d+$/.test(r.value)){let[t,i]=r.value.split("/").map(Number);return{token:e,value:t/i*100,unit:"%",type:"number"}}return r}get key(){return(this.fixedClass?this.fixedClass+" ":"")+this.name}}return th.SyntaxRule=p,th}function tx(){return eu?eh:(eu=1,eh=function e(t,r=[],i={}){for(let[o,a]of Object.entries(t)){let t=[...r,o].filter(Boolean),s=t.join("-");a&&"object"==typeof a&&!Array.isArray(a)?e(a,t,i):i[s]=Array.isArray(a)?a.join(","):a}return i})}function tS(){return ed?ep:(ed=1,ep=function e(t,r=[],i={}){for(let[o,a]of Object.entries(t)){let t=o||r[0]||"",s=[...r,o].filter(Boolean),l=s.join("-"),n=s.slice(0,-1).join("."),c=s[0],h=a&&"object"==typeof a&&!Array.isArray(a);h&&1===Object.keys(a).length&&""in a?i[l]={name:l,key:t,value:a[""],group:s.length>1?n:void 0,namespace:s.length>1?c:void 0}:h?e(a,s,i):i[l]={name:l,key:t,value:Array.isArray(a)?a.join(","):a,group:s.length>1?n:void 0,namespace:s.length>1?c:void 0}}return i})}function tN(){if(ef)return em;ef=1;var e=ec?en:(ec=1,en=function e(...t){let r={};for(let i of t)if("object"==typeof i&&null!==i)for(let t of Reflect.ownKeys(i)){let o=i[t],a=r[t];o!==r&&(Array.isArray(o)?r[t]=o.map(t=>Array.isArray(t)?[...t]:"object"==typeof t&&null!==t?e({},t):t):"object"==typeof o&&null!==o?r[t]="object"!=typeof a||null===a||Array.isArray(a)?e({},o):e(a,o):r[t]=o)}return r}),t=tx(),r=tS();return em=function(...i){let o=(e,t=[])=>{if(!e)return t;if(e.extends?.length)for(let r of e.extends)o("config"in r?r.config:r,t);let r={...e};return delete r.extends,t.push(r),t},a=i.reduce((e,t)=>o(t,e),[]),s={__extended:!0};for(let{variables:i,modes:o,components:l,animations:n,at:c,rules:h,utilities:u,selectors:p,functions:d,...m}of a){let a="__extended"in m;if(a&&delete m.__extended,i){s.variables??={};let e=a?{...i}:r(i,[],{});Object.assign(s.variables,e)}if(o)for(let[e,t]of(s.modes??={},Object.entries(o))){let i=a?{...t}:r(t,[],{});s.modes[e]={...s.modes[e],...i}}if(l){s.components??={};let e=a?{...l}:t(l);Object.assign(s.components,e)}if(c){s.at??={};let e=a?{...c}:t(c);Object.assign(s.at,e)}n&&(s.animations??={},Object.assign(s.animations,n)),h&&(s.rules??={},Object.assign(s.rules,h)),u&&(s.utilities??={},Object.assign(s.utilities,u)),p&&(s.selectors??={},Object.assign(s.selectors,p)),d&&(s.functions??={},Object.assign(s.functions,d)),s=e({},s,m)}return s}}var tw={};function tR(){return ey||(ey=1,tw.Rule=class{name;text;native;constructor(e,t){this.name=e,this.text=t}get key(){return this.name}}),tw}function t$(){if(ev)return eg;ev=1;class e{name;css;rules=[];tokenCounts=new Map;constructor(e,t){this.name=e,this.css=t}attach(){this.css.rules.push(this)}detach(){this.css.rules.splice(this.css.rules.indexOf(this),1)}insert(e,t=this.rules.length){if(!this.rules.find(({key:t})=>t===e.key))return this.rules.splice(t,0,e),this.css.rules.includes(this)||this.attach(),t}delete(e){let t=this.rules.findIndex(t=>t.key===e);if(-1===t)return;let r=this.rules[t];return this.rules.splice(t,1),0===this.rules.length&&this.detach(),r}reset(){this.rules.length=0;let e=this.css.rules.indexOf(this);-1!==e&&this.css.rules.splice(e,1),this.tokenCounts.clear()}get text(){let e=this.rules.map(({text:e})=>e).join("");return e?"@layer "+this.name+"{"+e+"}":""}}return eg=e}function tE(){return ek?eb:(ek=1,eb=class{name;keyframes;css;native;constructor(e,t,r){this.name=e,this.keyframes=t,this.css=r}get key(){return this.name}get text(){return`@keyframes ${this.name}{`+Object.entries(this.keyframes).reduce((e,[t,r])=>{let i=Object.entries(r).map(([e,t])=>`${e}:${t}`).join(";");return e+`${t}{${i}}`},"")+"}"}})}var t_={};function tA(){if(ex)return t_;ex=1,Object.defineProperty(t_,"__esModule",{value:!0});class e{rule;variable;css;mode;native;isDefaultMode=!1;constructor(e,t,r,i){this.rule=e,this.variable=t,this.css=r,this.mode=i}get selectorText(){let e=this.isDefaultMode;if(!this.mode)return":root";switch(this.css.config.modeTrigger){case"host":return`:host(.${this.mode})${e?",:host":""}`;case"class":return`.${this.mode}${e?",:root":""}`;default:return":root"}}get text(){let e="";switch(this.rule.variable.type){case"color":{let t=this.variable;e=(t.alpha??1)<1?`${t.space}(${t.value}/${t.alpha})`:`${t.space}(${t.value})`;break}case"number":e=String(this.variable.value);break;case"string":e=this.variable.value}let t=`${this.selectorText}{--${this.rule.name}:${e}}`;return"media"===this.css.config.modeTrigger&&this.mode&&(t=`@media (prefers-color-scheme:${this.mode}){${t}}`),t}}return t_.VariableRuleNode=e,t_.default=class{name;variable;css;nodes=[];constructor(t,r,i){this.name=t,this.variable=r,this.css=i;let o=void 0!==r.value;if(o&&this.nodes.push(new e(this,r,i)),r.modes&&this.css.config.modeTrigger)for(let t in r.modes){let a=new e(this,r.modes[t],i,t),s=!o&&this.css.config.defaultMode===t;a.isDefaultMode=s,s?this.nodes.unshift(a):this.nodes.push(a)}}get key(){return this.name}get text(){return this.nodes.map(({text:e})=>e).join("")}},t_}function tO(){if(eN)return eS;eN=1;var e=tE(),t=tb(),r=tA();return eS=function(i){return class extends i{rules=[];insert(e){if(this.rules.includes(e)||!e.valid)return;let r=this.rules.length;for(let i=0;i<this.rules.length;i++){let o=this.rules[i];if(0>t.default(e,o)){r=i;break}}return super.insert(e,r),this.insertVariables(e),this.insertAnimations(e),r}delete(e){let t=super.delete(e);if(!t)return;let r=(e,t)=>{let r=t.tokenCounts.get(e)??0;r<=1?(t.delete(e),t.tokenCounts.delete(e)):t.tokenCounts.set(e,r-1)};return t.variableNames?.forEach(e=>{r(e,this.css.themeLayer)}),t.animationNames?.forEach(e=>{r(e,this.css.animationsNonLayer)}),t}insertVariables(e){e.variableNames?.forEach(e=>{if(this.css.themeLayer.rules.find(({name:t})=>t===e)){let t=this.css.themeLayer.tokenCounts.get(e)||0;this.css.themeLayer.tokenCounts.set(e,t+1)}else{let t=this.css.variables.get(e);if(!t)return;let i=new r.default(e,t,this.css);this.css.themeLayer.insert(i),this.css.themeLayer.tokenCounts.set(e,1)}})}insertAnimations(t){t.animationNames?.forEach(t=>{if(this.css.animationsNonLayer.rules.find(({name:e})=>e===t)){let e=this.css.animationsNonLayer.tokenCounts.get(t)||0;this.css.animationsNonLayer.tokenCounts.set(t,e+1)}else{let r=this.css.animations.get(t);if(!r)return;let i=new e(t,r,this.css);this.css.animationsNonLayer.insert(i),this.css.animationsNonLayer.tokenCounts.set(t,1)}})}}}}function tT(){return eR?ew:(eR=1,ew=tO()(t$()))}function tC(){if(eA)return e_;eA=1;var e=eE?e$:(eE=1,e$=function(e,t){for(let r=0;r<e.length;r++)if(e[r]===t)return r;return -1});class t{css;rules=[];tokenCounts=new Map;constructor(e){this.css=e}insert(e){if(this.rules.includes(e))return;let t=this.css.style?.sheet;if(t)try{let r=t.insertRule(e.text,t.cssRules.length);e.native=t.cssRules[r]}catch(e){console.error(e)}this.rules.push(e),this.css.rules.push(e)}delete(t){let r=this.rules.find(e=>e.name===t);if(!r)return;let i=this.css.style?.sheet;if(i){let t=e(i.cssRules,r.native);-1!==t&&i.deleteRule(t)}return this.rules.splice(this.rules.indexOf(r),1),this.css.rules.splice(this.css.rules.indexOf(r),1),r}get text(){return this.rules.map(({text:e})=>e).join("")}reset(){for(let e of this.rules){let t=this.css.rules.indexOf(e);-1!==t&&this.css.rules.splice(t,1)}this.rules.length=0,this.tokenCounts.clear()}}return e_=t}function tL(){if(eL)return eC;eL=1;var e=tk(),t=el?es:(el=1,es=function(e){let t,r,i,o;return e.startsWith("#")&&(e=e.slice(1)),3===e.length||4===e.length?(t=parseInt(e[0]+e[0],16),r=parseInt(e[1]+e[1],16),i=parseInt(e[2]+e[2],16),o=4===e.length?Math.round(parseInt(e[3]+e[3],16)/255*100)/100:1):(6===e.length||8===e.length)&&(t=parseInt(e.slice(0,2),16),r=parseInt(e.slice(2,4),16),i=parseInt(e.slice(4,6),16),o=8===e.length?Math.round(parseInt(e.slice(6,8),16)/255*100)/100:1),[t,r,i,o]}),r=tN(),i=tR(),o=tr(),a=t$(),s=tT(),l=tC(),n=eT?eO:(eT=1,eO=function(e){globalThis.MasterCSS||(globalThis.MasterCSS=e)}),c=tm(),h=tp(),u=ty();class p{customConfig;baseConfig;definedRules=[];config;layerStatementRule=new i.Rule("layer-statement","@layer base,theme,preset,components,general;");rules=[this.layerStatementRule];classRules=new Map;animationsNonLayer=new l(this);baseLayer=new s("base",this);themeLayer=new a("theme",this);presetLayer=new s("preset",this);componentsLayer=new s("components",this);generalLayer=new s("general",this);components=new Map;selectors=new Map;variables=new Map;modes=[];atRules=new Map;animations=new Map;constructor(e,t){this.customConfig=e,this.baseConfig=t,this.resolve(e)}get text(){return this.rules.sort((e,t)=>{let r=["layer-statement","base","theme","preset","components","general"];return(-1===r.indexOf(e.name)?1/0:r.indexOf(e.name))-(-1===r.indexOf(t.name)?1/0:r.indexOf(t.name))}).map(({text:e})=>e).join("")}resolve(e){e?this.customConfig=e:e=this.customConfig,this.config=this.baseConfig?r(this.baseConfig,e):r(e),this.resolveVariables(),this.resolveAnimations(),this.resolveSelectors(),this.resolveAtRules(),this.resolveRules(),this.resolveComponents()}resolveAnimations(){let{animations:e}=this.config;if(e)for(let t in e){let r={};this.animations.set(t,r);let i=e[t];for(let e in i){let t=r[e]={},o=i[e];for(let e in o)t[e]=o[e]}}}resolveRules(){let{rules:e,utilities:t}=this.config;if(!e&&!t)return;let r=[];if(t)for(let e in t){let i=t[e];r.push([e,{declarations:i,type:o.Utility}])}e&&r.push(...Object.entries(e));let i=r.length;r.sort((e,t)=>{if(e[1].type!==t[1].type)return(t[1].type||0)-(e[1].type||0);if(e[1].kind!==t[1].kind){if(!e[1].kind)return 1;if(!t[1].kind)return -1;let r=["color","number","image"],i=r.indexOf(e[1].kind),o=r.indexOf(t[1].kind);if(i!==o)return i-o}return t[0].localeCompare(e[0],void 0,{numeric:!0})}).forEach(([e,t],r)=>{let a={id:e,keys:[],matchers:{},order:i-1-r,definition:t};t.unit??="",t.separators??=[","],this.definedRules.push(a);let{matcher:s,type:l,subkey:n,aliasGroups:c,values:h,kind:u,sign:p,key:d,namespaces:m}=t,f=[],y=d,g=e=>{let t=e.replace(/\./g,"-");this.variables.forEach(r=>{if(r.namespace===e||r.group===e){let e=r.name;(e.startsWith("-"+t)||e.startsWith(t))&&(e=e.slice(t.length+1)),a.variables?a.variables.set(e,r):a.variables=new Map([[e,r]])}})};if(g(e),m&&m.forEach(g),e.endsWith("()")){y||(t.key=y=e);let r=e.slice(0,-2);s=RegExp(`^${r}\\(`)}else(l===o.NativeShorthand||l===o.Native)&&(y||(t.key=y=e),f.push(e));if(p)a.matchers.arbitrary=RegExp(`^${p}[^!*>+~:[@_]+\\|`);else if(s)a.matchers.arbitrary=new RegExp(s);else if(y||n?(y&&!f.includes(y)&&f.push(y),n&&f.push(n),l===o.Shorthand&&f.push(e)):f.push(e),c?.length){let e=c.length>1?`(?:${c.join("|")})`:c[0],t=Array.from(a.variables?.keys()||[]),r=h?h.map(e=>`${e}(?:\\b|_)`):[];switch(u){case"color":r.push("(?:#|(?:color|color-contrast|color-mix|hwb|lab|lch|oklab|oklch|rgb|rgba|hsl|hsla|light-dark)\\(.*\\)|(?:currentColor|transparent)(?![a-zA-Z0-9-]))");break;case"number":r.push("(?:[\\d.]|(?:max|min|calc|clamp)\\([^|]*\\))");break;case"image":r.push("(?:url|linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient|conic-gradient)\\(.*\\)")}r?.length&&(a.matchers.value=RegExp(`^${e}:(?:${r.join("|")})[^|]*?(?:@|$)`)),t.length&&(a.matchers.variable=RegExp(`^${e}:(?:${t.join("|")})(?![a-zA-Z0-9-])[^|]*?(?:@|$)`))}l===o.Utility&&(a.id="."+e,a.matchers.arbitrary=RegExp("^"+e.replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&")+"(?=!|\\*|>|\\+|~|:|\\[|@|_|\\.|$)","m")),f.length&&(a.keys=f,a.matchers.key=RegExp(`^${f.length>1?`(${f.join("|")})`:f[0]}:.`))})}resolveComponents(){let{components:e={}}=this.config,t=Object.keys(e),r=(i,o=[])=>{let a=this.components.get(i);if(a)return void o.push(...a);let s=e[i];if(s){for(let e of s.replace(/(?:\n\s*)+/g," ").trim().split(" "))t.includes(e)?r(e,o):o.push(e);this.components.set(i,[...o])}};for(let e of t)r(e)}resolveSelectors(){let{selectors:e}=this.config;if(e)for(let t in e){let r=u(e[t],this,!1);this.selectors.set(t,r)}}resolveAtRules(){let{at:e,screens:t}=this.config;if(t)for(let e in t){let r=t[e],i=this.parseValue(r);this.atRules.set(e,{id:"media",nodes:[i]})}if(e)for(let t in e){let r=e[t];if("number"==typeof r){let e=this.parseValue(r);this.atRules.set(t,{id:"media",nodes:[e]})}else{let e=c(r,this,!1);this.atRules.set(t,e)}}}resolveVariables(){let{variables:e,screens:r,modes:i}=this.config,o=new Map,a=(e,r)=>{let i=(e,t,r)=>{if(r){let i=this.variables.get(e),o={value:t.value};if("alpha"in t&&(o.alpha=t.alpha),"space"in t&&(o.space=t.space),i){if(t.type&&t.type!==i.type)return;i.modes||(i.modes={}),i.modes[r]=o}else{let i={name:t.name,key:t.key,type:t.type,modes:{[r]:o}};t.namespace&&(i.namespace=t.namespace),t.group&&(i.group=t.group),this.variables.set(e,i)}}else this.variables.set(e,t)};if("number"==typeof e.value)i(e.name,{...e,type:"number"},r),i("-"+e.name,{...e,type:"number",name:"-"+e.name,key:"-"+e.key,value:-1*e.value},r);else if("string"==typeof e.value){let a=/^\$\((.*?)\)(?: ?\/ ?(.+?))?$|^\$([a-zA-Z0-9-]+)(?: ?\/ ?(.+?))?$/.exec(e.value);if(a){let t=a[1]??a[3],s=a[2]??a[4],l=o.get(e.name);l||o.set(e.name,l={}),l[r]=()=>{if(delete l[r],!t)return;let a=o.get(t);if(a)for(let e of Object.keys(a))a[e]?.();let n=this.variables.get(t);if(n){let t;if(s){let e=Number(s)*(n.alpha||1);e<1&&(t=e)}let o={...e,type:n.type,value:n.value};if("color"===n.type&&(void 0!==t&&(o.alpha=t),n.space&&(o.space=n.space)),i(o.name,o,r),n.modes)for(let e in n.modes){let t=n.modes[e];i(o.name,t,e)}}}}else{let o=/^#([a-f0-9]{3,4}|[a-f0-9]{6}|[a-f0-9]{8})$/i.exec(e.value);if(o){let[a,s,l,n]=t(o[1]),c={...e,type:"color",value:`${a} ${s} ${l}`,space:"rgb"};void 0!==n&&n<1&&(c.alpha=n),i(c.name,c,r);return}let a=/^(color|color-contrast|color-mix|hwb|lab|lch|oklab|oklch|rgb|hsl|light-dark)\((.+)\)$/i.exec(e.value);if(a){let t,[,o,s]=a;o=o.toLowerCase();let l=s.replace(/\s*\/\s*/g,"/").replace(/\s*,\s*/g," ").replace(/\s+/g," ").trim(),n=/^(.+?)\/([^\s]+)$/.exec(l),c=n?n[1].trim():l;t=n?Number(n[2]):void 0;let h={...e,type:"color",value:c,space:o};void 0!==t&&(h.alpha=t),i(h.name,h,r);return}i(e.name,{...e,type:"string"},r)}}};if(e)for(let t in e)a(e[t]);if(i)for(let e in i){let t=i[e];if(t)for(let r in t)a(t[r],e)}if(o.forEach(e=>{for(let t of Object.keys(e))e[t]?.()}),r)for(let e in r){let t=r[e],i="screen-"+e;this.variables.set(i,{name:i,key:e,namespace:"screen",group:"screen",type:"number",value:t}),this.variables.set("-"+i,{name:"-"+i,key:"-"+e,namespace:"screen",group:"screen",type:"number",value:-1*t})}}parseValue(e,t="rem"){return h(e,t,this.config.rootSize)}match(e){for(let t of this.definedRules)if(t.matchers.variable?.test(e))return t;for(let t of this.definedRules)if(t.matchers.value?.test(e))return t;for(let t of this.definedRules)if(t.matchers.key?.test(e))return t;for(let t of this.definedRules)if(t.matchers.arbitrary?.test(e))return t}generate(e,t){let r=[],i=this.components.get(e);if(i)i.forEach(i=>{let o=this.create(i,e,t);o&&o.valid?r.push(o):console.error(`Invalid class "${i}" found in ${e} component.`)});else{let i=e.indexOf("@");if(-1!==i){let o=e.slice(0,i),a=this.components.get(o);if(a){let o=e.slice(i);a.forEach(i=>{let a=this.create(i+o,e,t);a&&a.valid&&r.push(a)})}}let o=this.create(e,void 0,t);o&&o.valid&&r.push(o)}return r}create(t,r,i){let o=this.generalLayer.rules.find(({key:e})=>e===(r?r+" ":"")+t);if(o)return o;let a=this.match(t);if(a)return new e.SyntaxRule(t,this,a,r,i)}createFromSelectorText(e){let t=e.split(" "),r=/[.#\[!\*>+~:,\s]/;for(let e=0;e<t.length;e++){let i=t[e],o=this.getModeSelector(i);if((0!==e||i!==o)&&(0!==e&&1!==e||i!==this.config.scope)&&i.startsWith(".")){let e=i.slice(1),t="",o=0;for(;o<e.length;){let i=e[o],a=e[o+1];if("\\"===i&&a){t+=a,o+=2;continue}if(r.test(i))break;t+=i,o++}let a=this.generate(t);if(a.length)return a}}}refresh(e){return this.reset(),this.resolve(e),this}reset(){return this.animations=new Map,this.variables=new Map,this.atRules=new Map,this.selectors=new Map,this.components=new Map,this.classRules=new Map,this.definedRules.length=0,this.baseLayer.reset(),this.themeLayer.reset(),this.presetLayer.reset(),this.componentsLayer.reset(),this.generalLayer.reset(),this.animationsNonLayer.reset(),this}destroy(){return this.reset(),this}add(...e){for(let t of e){if(this.classRules.get(t))continue;let e=this.generate(t);e.length&&(e.forEach(e=>e.layer.insert(e)),this.classRules.set(t,e))}return this}remove(...e){for(let t of e){let e=this.classRules.get(t);e&&(e.forEach(e=>e.layer.delete(e.key)),this.classRules.delete(t))}}getModeSelector(e){switch(this.config.modeTrigger){case"class":return"."+e;case"host":return":host(."+e+")"}}}return n(p),eC=p}function tI(){if(eG)return eI;eG=1;var e=tc(),t=tL();return eI=function(r){return new t(r,e.config)}}function tG(){if(eV)return eU;eV=1;var e=to();return eU=function(t,r){return e.AT_IDENTIFIERS.every(e=>(function e(t,r){if(t.length!==r.length)return!1;let i=Array(r.length).fill(!1);for(let o of t){let t=r.findIndex((t,r)=>!i[r]&&o.type===t.type&&o.value===t.value&&o.unit===t.unit&&o.name===t.name&&o.operator===t.operator&&e(o.children??[],t.children??[]));if(-1===t)return!1;i[t]=!0}return!0})(t?.[e]??[],r?.[e]??[]))}}function tj(){if(eD)return ez;function e(e,r){if(e.type!==r.type||e.value!==r.value)return!1;let i=e.children??[],o=r.children??[];return i.length===o.length&&t(i,o)}function t(t,r){if(t.length!==r.length)return!1;let i=new Set(r);for(let r of t){let t=!1;for(let o of i)if(e(r,o)){i.delete(o),t=!0;break}if(!t)return!1}return!0}function r(e){let t=[],r=[];for(let i of e)"combinator"===i.type?(r.length>0&&(t.push(r),r=[]),t.push(i)):r.push(i);return r.length>0&&t.push(r),t}return eD=1,ez=function(i=[],o=[]){let a=r(i),s=r(o);if(a.length!==s.length)return!1;for(let r=0;r<a.length;r++){let i=a[r],o=s[r];if(Array.isArray(i)&&Array.isArray(o)){if(!t(i,o))return!1}else if(Array.isArray(i)||Array.isArray(o))return!1;else if(!e(i,o))return!1}return!0}}var tM=function(){if(e2)return e9;e2=1,Object.defineProperty(e9,"__esModule",{value:!0});var e=tc(),t=to(),r=tL(),i=tk(),o=tR(),a=t$(),s=tT(),l=tC(),n=tr(),c=tA(),h=tE(),u=tI(),p=tO(),d=tN(),m=function(){if(eM)return ej;eM=1;var e=tr(),t=tI(),r=tb(),i=to();return ej=function(o,a=t()){let s=[],l=[];for(let e of o)e.includes(i.__UNSORTED__)?l.push(e):s.push(e);a.add(...s);let n=new Set,c=[...a.componentsLayer.rules.filter(e=>!e.fixedClass||!n.has(e.fixedClass)&&(n.add(e.fixedClass),!0)),...a.generalLayer.rules,...a.baseLayer.rules,...a.presetLayer.rules],h=new Set(a.baseLayer.rules),u=new Set(a.presetLayer.rules),p=c.map(t=>({rule:t,sortKey:[h.has(t)?4:u.has(t)?5:t.atRules?3:t.mode?2:+!!t.selectorNodes?.length,t.fixedClass?0:t.type===e.Utility?1:2]})).sort((e,t)=>{for(let r=0;r<e.sortKey.length;r++)if(e.sortKey[r]!==t.sortKey[r])return e.sortKey[r]-t.sortKey[r];return e.rule.fixedClass&&t.rule.fixedClass?e.rule.fixedClass.localeCompare(t.rule.fixedClass,void 0,{numeric:!0}):r.default(e.rule,t.rule)}).map(e=>e.rule.fixedClass||e.rule.name);return a.remove(...s),[...p,...[...s.filter(e=>-1===p.indexOf(e)),...l].sort((e,t)=>e.localeCompare(t,void 0,{numeric:!0}))]}}(),f=tG(),y=tj(),g=function(){if(eB)return eP;eB=1;var e=tj(),t=tG();return eP=function(r,i){return r.mode===i.mode&&e(r.selectorNodes,i.selectorNodes)&&t(r.atRules,i.atRules)}}(),v=eX?eY:(eX=1,eY=function(e={},t={}){return Object.keys(e).length===Object.keys(t).length&&Object.keys(e).every(e=>e in t)}),b=function(){if(eF)return eq;eF=1;var e=tI();return eq=function(t,r=e()){let i="";return r.add(...t),i=r.text,r.remove(...t),i}}(),k=function(){if(eZ)return eK;eZ=1;var e=ta();return eK=function(t){return Object.hasOwnProperty.call(e,t)}}(),x=td(),S=tp(),N=tm(),w=tf(),R=ty(),$=tg(),E=eW?eH:(eW=1,eH=function(e){if(1!==e.length)return;let t=e[0];if("number"===t.type)return t}),_=tb(),A=tx(),O=tS(),T=eJ?eQ:(eJ=1,eQ=function(e){let t={};for(let r of Object.values(e)){let{group:e,key:i,value:o}=r,a=e?e.split("."):[],s=t;for(let e of a)e in s?("object"!=typeof s[e]||null===s[e])&&(s[e]={"":s[e]}):s[e]={},s=s[e];s[i]=o}return t}),C=e1?e0:(e1=1,e0=function(e){let{variables:t={},modes:r={},...i}=e,o=Object.keys(r),a=new Set;for(let e of o)for(let t in r[e])a.add(t);let s={...t},l={};for(let e of a){let i,a=!0;for(let t=0;t<o.length;t++){let s=o[t],l=r[s]?.[e];if(!l){a=!1;break}if(0===t)i=l;else if(JSON.stringify(l.value)!==JSON.stringify(i.value)){a=!1;break}}let n=t[e],c=n&&JSON.stringify(n.value)===JSON.stringify(i?.value);if(a&&(!n||c))i&&(s[e]=i);else for(let t of o){l[t]||(l[t]={});let i=r[t]?.[e];i&&(l[t][e]=i)}}return{...i,variables:Object.keys(s).length>0?s:void 0,modes:Object.keys(l).length>0?l:void 0}}),L=e4(),I=e6(),G=e7(),j=ta(),M=tl(),U=e8(),V=tt(),z=ts(),D=tn();return e9.config=e.config,e9.ANIMATION_SIGN=t.ANIMATION_SIGN,e9.AT_COMPARABLE_FEATURES=t.AT_COMPARABLE_FEATURES,e9.AT_COMPARISON_OPERATORS=t.AT_COMPARISON_OPERATORS,e9.AT_IDENTIFIERS=t.AT_IDENTIFIERS,e9.AT_LOGICAL_OPERATORS=t.AT_LOGICAL_OPERATORS,e9.AT_SIGN=t.AT_SIGN,e9.BASE_UNIT_REGEX=t.BASE_UNIT_REGEX,e9.BORDER_STYLE_VALUES=t.BORDER_STYLE_VALUES,e9.CLASS_ATTRIBUTES=t.CLASS_ATTRIBUTES,e9.CLASS_DECLARATIONS=t.CLASS_DECLARATIONS,e9.CLASS_FUNCTIONS=t.CLASS_FUNCTIONS,e9.COLOR_VALUE_REGEX=t.COLOR_VALUE_REGEX,e9.COMPARISION_OPERATORS=t.COMPARISION_OPERATORS,e9.DELIMITER_SIGN=t.DELIMITER_SIGN,e9.IMAGE_VALUE_REGEX=t.IMAGE_VALUE_REGEX,e9.NUMBER_VALUE_REGEX=t.NUMBER_VALUE_REGEX,e9.QUERY_COMPARISON_OPERATORS=t.QUERY_COMPARISON_OPERATORS,e9.QUERY_LOGICAL_OPERATORS=t.QUERY_LOGICAL_OPERATORS,e9.SELECTOR_COMBINATORS=t.SELECTOR_COMBINATORS,e9.SELECTOR_SIGNS=t.SELECTOR_SIGNS,e9.SEPARATOR_SIGN=t.SEPARATOR_SIGN,e9.SEPARATOR_SIGNS=t.SEPARATOR_SIGNS,e9.TRANSITION_SIGN=t.TRANSITION_SIGN,e9.UNIT_REGEX=t.UNIT_REGEX,e9.VALUE_DELIMITERS=t.VALUE_DELIMITERS,e9.VALUE_UNITS=t.VALUE_UNITS,e9.__UNSORTED__=t.__UNSORTED__,e9.MasterCSS=r,e9.default=r,e9.SyntaxRule=i.SyntaxRule,e9.Rule=o.Rule,e9.Layer=a,e9.SyntaxLayer=s,e9.NonLayer=l,e9.SyntaxRuleType=n,e9.VariableRule=c.default,e9.AnimationRule=h,e9.createCSS=u,e9.withSyntaxLayer=p,e9.extendConfig=d,e9.sortReadableClasses=m,e9.equalAtRules=f,e9.equalSelectors=y,e9.equalVariants=g,e9.equalDeclarations=v,e9.generateCSS=b,e9.isCoreRule=k,e9.parsePair=x,e9.parseValue=S,e9.parseAt=N,e9.generateAt=w,e9.parseSelector=R,e9.generateSelector=$,e9.getSingleAtNumberRuleNode=E,e9.compareRulePriority=_.default,e9.flattenObject=A,e9.flattenMetaObject=O,e9.nestMetaObject=T,e9.minifyExtendedConfig=C,e9.at=L,e9.selectors=I,e9.utilities=G,e9.rules=j,e9.functions=M,e9.animations=U,e9.variables=V,e9.modes=z,e9.screens=D,e9}(),tU={},tV=function(){if(e5)return tU;e5=1,Object.defineProperty(tU,"__esModule",{value:!0});let e={listeners:new Map,on(e,t){this.listeners.has(e)||this.listeners.set(e,new Set),this.listeners.get(e)?.add(t)},off(e,t){this.listeners.get(e)?.delete(t)},emit(e,...t){this.listeners.get(e)?.forEach(e=>e(...t))}};return tU.default=e,tU.devToolsHook=e,tU.installHook=function(t=globalThis){let r=t.__MASTER_CSS_DEVTOOLS_HOOK__;return r||(t.__MASTER_CSS_DEVTOOLS_HOOK__=e)},tU}();function tz(e,t){for(let r=0;r<e.length;r++)if(e[r]===t)return r;return -1}let tD=class extends tM.Layer{name;cssRuntime;rules=[];tokenCounts=new Map;native=null;constructor(e,t){super(e,t),this.name=e,this.cssRuntime=t}attach(){super.attach();let e=this.cssRuntime.style?.sheet;if(e&&!this.native?.parentStyleSheet){let t=e.insertRule(this.text,e.cssRules.length);this.native=e.cssRules.item(t)}}insert(e,t=this.rules.length){let r=super.insert(e,t);if(void 0===r||!this.native)return;let i=(t,i)=>{if(1===this.rules.length)return this.native.cssRules.item(i);try{let e=this.native.insertRule(t,i);return this.native.cssRules.item(e)}catch(t){console.error(t,e),this.rules.splice(r,1);return}};if("nodes"in e){let t=r;e.nodes.forEach(e=>{e.native=i(e.text,t),e.native&&t++})}else e.native=i(e.text,r);return r}detach(){super.detach();let e=this.cssRuntime.style?.sheet;if(e&&this.native?.parentStyleSheet){let t=tz(e.cssRules,this.native);-1!==t&&e.deleteRule(t)}}delete(e){let t=super.delete(e);if(!t||!this.native)return;let r=e=>{if(!e)return;let t=tz(this.native.cssRules,e);if(-1!==t)try{this.native.deleteRule(t)}catch(t){console.error(t,e)}};return"nodes"in t?t.nodes.forEach(e=>r(e.native)):r(t.native),t}reset(){super.reset();let e=this.cssRuntime.style?.sheet;if(this.native&&e){let t=tz(e.cssRules,this.native);-1!==t&&e.deleteRule(t),this.native=null}}},tP=tM.withSyntaxLayer(tD);class tB extends tM.MasterCSS{root;customConfig;baseConfig;static instances=new WeakMap;host;container;baseLayer=new tP("base",this);themeLayer=new tD("theme",this);presetLayer=new tP("preset",this);componentsLayer=new tP("components",this);generalLayer=new tP("general",this);classCounts=new Map;observer;progressive=!1;observing=!1;constructor(e=document,t=tM.config,r){super(t,r),this.root=e,this.customConfig=t,this.baseConfig=r;let i=e?.constructor.name;"HTMLDocument"===i||"Document"===i?(this.root.defaultView.globalThis.cssRuntime=this,this.container=this.root.head,this.host=this.root.documentElement):(this.container=this.root,this.host=this.root.host),globalThis.CSSRuntime.instances.set(this.root,this),__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:created",{cssRuntime:this})}observe(){if(this.observing)return this;if(this.root.styleSheets)for(let e of this.root.styleSheets){let{ownerNode:t}=e;if(t instanceof HTMLStyleElement&&"master"===t.id){this.style=t,this.style.sheet?.cssRules.length&&(this.progressive=!0);break}}let e=new WeakMap,t=new Set,r=e=>{let r=this.classCounts.get(e)||0;r||t.add(e),this.classCounts.set(e,r+1)};if(this.root.querySelectorAll("[class]").forEach(t=>{let i=t.classList;i&&t.classList.forEach(r),e.set(t,new Set(i))}),this.progressive){let e=this.hydrate(this.style.sheet.cssRules);for(let r of t)e.allSyntaxRules.find(e=>(e.fixedClass||e.name)===r)||this.add(r)}else this.style=document.createElement("style"),this.style.id="master",this.style.setAttribute("blocking","render"),this.container.append(this.style),this.style.sheet.insertRule(this.layerStatementRule.text),this.layerStatementRule.native=this.style.sheet.cssRules.item(0),t.forEach(e=>this.add(e));return this.observer=new MutationObserver(t=>{let r=new Map,i=new Map,o=new Set,a=new WeakSet,s=(e,t)=>r.set(e,(r.get(e)||0)+t),l=t=>{let r=new Set(e.get(t)||[]),i=new Set(t.classList);for(let e of i)r.has(e)||s(e,1);for(let e of r)i.has(e)||s(e,-1);e.set(t,i)},n=t=>{for(let r of e.get(t)||[])s(r,-1);e.delete(t)};for(let e of t)if("childList"===e.type){for(let t of e.addedNodes)t instanceof Element&&t.isConnected&&i.set(t,(i.get(t)||0)+1);for(let t of e.removedNodes)t instanceof Element&&!t.isConnected&&i.set(t,(i.get(t)||0)-1)}else"attributes"===e.type&&"class"===e.attributeName&&o.add(e.target);let c=(e,t,r)=>{if(r.has(e))i.delete(e);else for(let i of(r.add(e),t(e),e.children))c(i,t,r)};for(let[e,t]of i)t>0?c(e,l,a):t<0&&!e.isConnected&&c(e,n,a);for(let e of o)a.has(e)||l(e);for(let[e,t]of r){let r=this.classCounts.get(e)||0,i=r+t;i>0?(this.classCounts.set(e,i),0===r&&this.add(e)):(this.classCounts.delete(e),this.remove(e))}globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:mutated",{records:t,classCounts:r,cssRuntime:this})}),this.observer.observe(this.root,{childList:!0,attributes:!0,attributeFilter:["class"],attributeOldValue:!0,subtree:!0}),this.progressive||this.host.removeAttribute("hidden"),this.observing=!0,globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:observed",{cssRuntime:this}),this}hydrate(e){let t=[],r=new CSSStyleSheet,i={allSyntaxRules:[]};for(let i=0;i<e.length;i++){let o=e[i];if("CSSLayerBlockRule"===o.constructor.name)if("theme"===o.name){let e;this.themeLayer.native=o;let t=new Map;for(let e of o.cssRules)t.set(e.cssText.trim(),e);for(let i of o.cssRules){if(!t.has(i.cssText))continue;let o=("CSSMediaRule"===i.constructor.name?i.cssRules[0]:i).style[0].slice(2),a=this.variables.get(o);a&&(e=new tM.VariableRule(o,a,this),this.themeLayer.rules.push(e),this.themeLayer.tokenCounts.set(e.name,0),e.nodes.forEach(e=>{let i=r.insertRule(e.text),o=r.cssRules.item(i);if(o){let r=o.cssText.trim(),i=t.get(r);if(i){e.native=i,t.delete(r);return}}}))}this.themeLayer.rules.length&&this.rules.push(this.themeLayer)}else t.push(o);else if("CSSLayerStatementRule"===o.constructor.name)this.layerStatementRule.native=o;else if("CSSKeyframesRule"===o.constructor.name){let e=this.animations.get(o.name);if(!e)continue;let t=new tM.AnimationRule(o.name,e,this);t.native=o,this.animationsNonLayer.rules.push(t),this.rules.push(t),this.animationsNonLayer.tokenCounts.set(t.name,0)}}for(let e of t){let t;switch(e.name){case"base":t=this.baseLayer;break;case"preset":t=this.presetLayer;break;case"components":t=this.componentsLayer;break;case"general":t=this.generalLayer;break;default:console.error(`Cannot recognize the layer \`${e.name}\`. (https://rc.css.master.co/messages/hydration-errors)`);continue}t.native=e;let o=new Map;for(let t of e.cssRules)o.set(t.cssText.trim(),t);for(let a of e.cssRules){if(!o.has(a.cssText))continue;let e=this.getSelectorText(a);if(!e){console.error(`Cannot get the selector text from \`${a.cssText}\`. (${t.name}) (https://rc.css.master.co/messages/hydration-errors)`);continue}let s=this.createFromSelectorText(e);if(s)for(let e of s){t.rules.push(e),t.insertVariables(e),t.insertAnimations(e),i.allSyntaxRules.push(e);try{let i=r.insertRule(e.text),a=r.cssRules.item(i);if(a){let t=a.cssText.trim(),r=o.get(t);if(r){e.native=r,o.delete(t);continue}}console.error(`Cannot retrieve CSS rule for \`${e.text}\`. (${t.name}) (https://rc.css.master.co/messages/hydration-errors)`)}catch(e){}}else console.error(`Cannot recognize \`${a.cssText}\`. (${t.name}) (https://rc.css.master.co/messages/hydration-errors)`)}t.rules.length&&this.rules.push(t)}return globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:hydrated",{cssRuntime:this,result:i}),i}getSelectorText(e){return e instanceof CSSStyleRule?e.selectorText:e instanceof CSSGroupingRule?this.getSelectorText(e.cssRules.item(0)):void 0}disconnect(){if(this.observing)return this.observer&&(this.observer.disconnect(),this.observer=void 0),this.observing=!1,this.reset(),this.classCounts.clear(),this.progressive||(this.style?.remove(),this.style=null),globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:disconnected",{cssRuntime:this}),this}refresh(e=this.customConfig){if(!this.observing||!this.style.sheet)return this;for(let e=1;e<=this.style.sheet.cssRules.length-1;e++)this.style.sheet.deleteRule(e);return super.refresh(e),this.classCounts.forEach((e,t)=>{this.add(t)}),globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:refreshed",{cssRuntime:this,customConfig:e}),this}destroy(){return this.disconnect(),globalThis.CSSRuntime.instances.delete(this.root),globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:destroyed",{cssRuntime:this}),this}}function tY(e,t=document,r=!0){let i=globalThis.CSSRuntime.instances.get(t);return i||(i=new tB(t,e,tM.config),r&&i.observe()),i}globalThis.CSSRuntime||(globalThis.CSSRuntime=tB),tV.installHook();let tX=window.masterCSSConfigs,tq=window.masterCSSConfig;if(tq){let e=[];tX&&e.push(...tX),tq.extends&&e.push(...tq.extends),tY({...tq,extends:e})}else tX?tY({extends:tX}):tY()}();
1
+ !function(){let e={"(":")","'":"'",'"':'"',"{":"}"},t=/^([+-]?(?:\d+(?:\.?\d+)?|\.\d+))x$/m,i=["_",">","+","~"],s=RegExp("^([+-.]?\\d+(?:\\.?\\d+)?)(%|cm|mm|q|in|pt|pc|px|em|rem|ex|rex|cap|rcap|ch|rch|ic|ric|lh|rlh|vw|svw|lvw|dvw|vh|svh|lvh|dvh|vi|svi|lvi|dvi|vb|svb|lvb|dvb|vmin|svmin|lvmin|dvmin|vmax|svmax|lvmax|dvmax|cqw|cqh|cqi|cqb|cqmin|cqmax|deg|grad|rad|turn|s|ms|hz|khz|dpi|dpcm|dppx|x|fr|db|st)?$"),r=new Set(["!","*",">","+","~",":","[","@","_","."]),a=[">=","<=",">","<","="],n={"&":"and","!":"not",not:"not",and:"and",or:"or",only:"only",",":"or"},l=["container","starting-style","supports","media","layer"],o=["width","height","resolution"],h={w:"width",h:"height"};function c(e,t="",i=1){if("number"==typeof e)return{unit:t,type:"number",value:"rem"===t||"em"===t?e/i:e};let r=e.match(s);if(r){let s=parseFloat(r[1]),a=r[2]||"";return a||"rem"!==t&&"em"!==t||(s/=i,a=t),{token:e,value:s,unit:a||t,type:"number"}}return{token:e,value:e,type:"string"}}function u(e,t="(",i=")"){let s=[],r=null,a=null;for(let n=0;n<e.length;n++){let l=e[n],o=e[n-1];if("\\"===l){n++;continue}if(('"'===l||"'"===l)&&"\\"!==o){a===l?a=null:a||(a=l);continue}if(!a){if(e.startsWith(t,n))s.push({start:n}),n+=t.length-1;else if(e.startsWith(i,n)){let a=s.pop();a&&(r={start:a.start,end:n,pre:e.slice(s.length>0?s[s.length-1].start+t.length:0,a.start),body:e.slice(a.start+t.length,n),post:e.slice(n+i.length)}),n+=i.length-1}}}return r}function f(e){return o.includes(h[e]||e)}function d(e,t,i=!0){let s,r,o=e=>{let d=[],m=u(e);if(m){if(m.pre&&d.push(...o(m.pre)),m.body)if("supports"===s)d.push({type:"group",children:[{type:"string",value:function(e){let t="",i=!1,s=!1;for(let r=0;r<e.length;r++){let a=e[r],n=e[r-1];"'"!==a||"\\"===n||s?'"'!==a||"\\"===n||i||(s=!s):i=!i,"|"!==a||i||s?t+=a:t+=" "}return t}(m.body)}]});else{let e=o(m.body);e.length>1?d.push({type:"group",children:o(m.body)}):d.push(...e)}m.post&&d.push(...o(m.post))}else{let o,u,m;d.push(...(o=[...e.matchAll(/([a-zA-Z0-9-:%|]+|[&|!|,|>|<|=][=]?)/g)].map(e=>e[0]),u=[],m=e=>{let t=u[u.length-1];if("number"===e.type&&!e.name)if(t?.type==="comparison")if(e.operator=t.value,e.raw&&t.raw&&(e.raw=t.raw+e.raw),u.pop(),t=u[u.length-1],t?.type==="string"){var i;e.name=h[i=t.value]||i,e.raw&&t.raw&&(e.raw=t.raw+e.raw),u.pop()}else e.name="width";else e.name="width",e.operator=">=";u.push(e)},o.forEach((e,d)=>{var p;if(a.includes(e)){let t={type:"comparison",value:e};i&&(t.raw=e),u.push(t);return}if(e in n){let t={type:"logical",value:n[e]};i&&(t.raw=e),u.push(t);return}let y="container"===s?t.containerAtRules.get(e)||(t.breakpointAtRules.has(e)?void 0:t.atRules.get(e)):t.atRules.get(e);if(!s&&!r){if(p=r=e,l.includes(p)){s=r;return}s=y?y.id:f(r)?"media":r.charAt(0).match(/[a-zA-Z-]/)?"container":"media"}let g={type:"string"};if(i&&(g.raw=e),y)return void(1===y.nodes.length?m({...y.nodes[0],raw:e}):y.nodes.length&&m({raw:e,children:y.nodes}));{let[r,n]=function(e){let t=[],i="",s=!1,r=!1;for(let a=0;a<e.length;a++){let n=e[a],l=e[a-1];"'"!==n||r||"\\"===l?'"'!==n||s||"\\"===l||(r=!r):s=!s,":"!==n||s||r?i+=n:(t.push(i.trim()),i="")}return i&&t.push(i.trim()),t}(e);if(n?(g.name=h[r]||r,g.value=n):g.value=h[r]||r,"container"===s||"media"===s){let s=String(g.value);if(!n&&f(s))return void(a.includes(o[d+1])?m(g):m({type:"boolean",name:s,...i&&{raw:e}}));{let{token:e,...i}=c(g.value,"rem",t.settings.rootSize);Object.assign(g,i)}}m(g)}}),u))}return d};return{nodes:o(e),id:s||"media"}}let m=RegExp(`(?:[a-zA-Z0-9-]+)|([${i.join("")}#.:,*])|(a-zA-Z0-9-)`,"g"),p=new Set(["before","after","first-letter","first-line"]);function y(e,t,s=!0){let r=e=>{let r=[],a="",n=0;for(let l of e.matchAll(m)){let o,h=l[0];if(n+=h.length,":"===h||"."===h||"#"===h){a+=h;continue}let c=h,u=t.selectors.get(a+h);if(u){let e=u[u.length-1];r.push(1===u.length&&e.type?{...e,raw:a+h}:{children:u,raw:a+h}),a="";continue}if(i.includes(h)){if(o="combinator","_"===h){let t=e[n];"_"!==e[n-h.length-1]&&"_"!==t&&(c=" ")}}else","===h?o="separator":"*"===h?o="universal":":"===a?o=p.has(h)?"pseudo-element":"pseudo-class":"::"===a?o="pseudo-element":"."===a?o="class":"#"===a&&(o="id");r.push({value:c,...s&&{raw:a+h},...o&&{type:o}}),a=""}return r},a=(e,t=[])=>{let i=u(e);if(i){let e,{pre:s,body:n,post:l}=i;if(n){let t=s.lastIndexOf(":");if(-1!==t){let i=t;for(;i>0&&":"===s[i-1];)i--;e=s.slice(i),s=s.slice(0,i)}}if(s&&t.push(...a(s)),n){let i=a(n);if(e){let s=r(e)[0];i.length&&(s.children=i),t.push(s)}else t.push(...i)}return l&&t.push(...a(l)),t}let n=u(e,"[","]");if(n){let{pre:e,body:i,post:r}=n;return e&&t.push(...a(e)),t.push({value:i,type:"attribute",...s&&{raw:`[${i}]`}}),r&&t.push(...a(r)),t}return r(e)};return a(e)}let g={class:".","pseudo-class":":","pseudo-element":"::",attribute:"",combinator:"",id:"#"};function v(e,t=""){let s=e=>{if("attribute"===e.type)return`[${e.value}]`;if("combinator"===e.type)return e.value;let t=e.type&&g[e.type]||"",i=e.value?t+e.value:"";if("children"in e&&e.children?.length){let t=e.children.map(s).join("");return e.value?i+`(${t})`:i+t}return i},r="",a="",n=[];if(e.flatMap(e=>!("value"in e)&&"children"in e&&e.children?.length?e.children:e).forEach(e=>{","===e.value?(n.push(a),a=""):"of"===e.value&&"children"in e?r+=e.children.map(s).join(""):a+=s(e)}),a&&n.push(a),r){let e=r.charAt(r.length-1);i.includes(e)||" "===e||(r+=" ")}return n.length?n.map(e=>r+t+e).join(","):r+t}var b=new Intl.Collator(void 0,{numeric:!0}).compare;let k={hover:1,focus:2,"focus-visible":2,active:3,disabled:4},x={">=":"<","<=":">",">":"<=","<":">="};function R(e){if("number"==typeof e.sortTier)return e.sortTier;let t=e.selectorNodes?.length,i=!!e.atRules,s=!!e.mode;return i?3:s?2:+!!t}function M(e,t){let i=R(e),s=R(t);if(i!==s)return i-s;let r=function(e,t){let i=Math.max(e.length,t.length);for(let s=0;s<i;s++){let i=e[s],r=t[s];if(!i)return -1;if(!r)return 1;let[a,n,l]=i,[o,h,c]=r,u=b(a,o);if(0!==u)return u;let f=l-n,d=c-h;if(f!==d)return d-f;if(n!==h)return h-n;if(l!==c)return c-l}return 0}(e.priority.features||[],t.priority.features||[]);if(0!==r)return r;let a=e.priority.selector-t.priority.selector;if(0!==a)return a;let n=e.type-t.type;return 0!==n?n:b(e.key,t.key)}let w=/var\(\s*--([_a-zA-Z0-9-]+)\b/g;function S(e,t,i){let s=`var(--${e}${i?","+i:""})`;return void 0!==t?N(s,t):s}function N(e,t){return`color-mix(in oklab,${e} ${100*Number(t)}%,transparent)`}function A(e,t){let i="",s="";for(let r=0;r<e.length;){let a=e[r];if(s){if(i+=a,"\\"===a){i+=e[r+1]||"",r+=2;continue}a===s&&(s=""),r++;continue}if('"'===a||"'"===a){s=a,i+=a,r++;continue}if(e.startsWith("var(",r)){let s=r+4;for(;" "===e[s];)s++;if("--"!==e.slice(s,s+2)){i+=a,r++;continue}let n=s+=2;for(;/[_a-zA-Z0-9-]/.test(e[s]||"");)s++;let l=e.slice(n,s);if(!l){i+=a,r++;continue}let o=1,h="",c=-1;for(let t=s;t<e.length;t++){let i=e[t];if(h){if("\\"===i){t++;continue}i===h&&(h="");continue}if('"'===i||"'"===i){h=i;continue}if("("===i){o++;continue}if(")"===i&&0==--o){c=t;break}}if(-1===c){i+=e.slice(r);break}let u=e.slice(r,c+1);i+=t(l,u)??u,r=c+1;continue}i+=a,r++}return i}function T(e){if("number"==typeof e)return{value:String(e),dependencies:new Set};let t="",i=!1,s=!1,r=new Set;for(let a=0;a<e.length;a++){let n=e[a],l=e[a-1];if("'"===n&&"\\"!==l&&!s){i=!i,t+=n;continue}if('"'===n&&"\\"!==l&&!i){s=!s,t+=n;continue}if(!i&&!s){if("|"===n){t+=" ";continue}if("$"===n){let i=function(e,t){if("("===e[t+1]){let i=t+2,s="";for(;i<e.length&&")"!==e[i];i++)s+=e[i];return s?{name:s,end:i+1}:void 0}let i=t+1,s="";for(;i<e.length;i++){let t=e[i];if(!/[a-zA-Z0-9-]/.test(t))break;s+=t}return s?{name:s,end:i}:void 0}(e,a);if(i){let s=function(e,t){let i=t;for(;" "===e[i];)i++;if("/"!==e[i])return;for(i++;" "===e[i];)i++;let s=i;for(;i<e.length&&!/[\s,);|]/.test(e[i]);i++);let r=e.slice(s,i);return r?{alpha:Number(r),end:i}:void 0}(e,i.end);r.add(i.name),t+=S(i.name,s?.alpha),a=(s?.end??i.end)-1;continue}}}t+=n}for(let e of function(e){let t=new Set;for(let i of e.matchAll(w))t.add(i[1]);return t}(t))r.add(e);return{value:t,dependencies:r}}function C(e,t){let i=new Set;for(let s in e){let r=e[s];if(r)for(let e of String(r).matchAll(w)){let s=t.get(e[1]);s&&!s.inline&&i.add(e[1])}}return i.size?i:void 0}function U(e,t){let i=new Set;if(void 0===e)return i;let s=new Set(t);if(!s.size)return i;for(let t of T(e).value.split(/[\s,]+/))s.has(t)&&i.add(t);return i}function L(e,t){if(!e.startsWith(t))return!1;let i=e[t.length];return void 0===i||"!"===i||"*"===i||">"===i||"+"===i||"~"===i||":"===i||"["===i||"@"===i||"_"===i||"."===i}let E=new Set(["animation","animation-name"]);function O(e,t,i){let s=e*t/i;return String(Object.is(s,-0)?0:s).replace(/^(-?)0\./,"$1.")+"rem"}function z(e,t){return t&&"&"!==t?t.replace(/&/g,e||"&"):e}function D(e){if(!e)return;let t={};for(let i of l){let s=e[i];s?.length&&(t[i]=[...s])}return t}function $(e,t){let i=D(e)||{};return i[t.id]=[...i[t.id]||[],...t.nodes],i}function V(e,t,i,s){let r=D(e.atRules);for(let e of t.atRuleNodes||[])r=$(r,e);if(!t.atRuleNodes?.length)for(let e of t.atRules||[])r=$(r,d(e,i));if(t.selectorNodes?.length&&!t.selector)return{...e,key:e.key+s,selectorNodes:t.selectorNodes,...r?{atRules:r}:{},...t.layer||e.layer?{layer:t.layer||e.layer}:{},valid:!1!==e.valid&&!(e.layer&&t.layer&&e.layer!==t.layer)};let a=t.layer||e.layer;return{...e,key:e.key+s,selectorTemplate:z(e.selectorTemplate,t.selector),...r?{atRules:r}:{},...a?{layer:a}:{},valid:!1!==e.valid&&!(e.layer&&t.layer&&e.layer!==t.layer)}}function _(e,t){let i=0,s="";for(let r=t;r<e.length;r++){let t=e[r];if(s){"\\"===t?r++:t===s&&(s="");continue}if('"'===t||"'"===t){s=t;continue}if("("===t&&i++,")"===t&&0==--i)return r}return -1}class j{name;css;registeredUtility;fixedClass;native;nodes;atRules;priority;type=0;declarations;declarationRules;layer;layerName;explicitLayerName;valid=!0;animationNames;variableNames;branchIndex;branchCount=1;selectorTemplate;variantBranchKey;invalidValueSyntax=!1;constructor(e,t,i,s,r,a=0){let n;this.name=e,this.css=t,this.registeredUtility=i,this.fixedClass=s,this.branchIndex=a,this.mode=r,this.layerName=i.layer||"utilities";let{name:l,key:o,layer:h,atRules:c,...u}=i;Object.assign(this,u);let{id:f,type:d}=i;this.type=d;let m="",p=function(e,t){for(let i of t.matchers)if("static"===i.type&&L(e,i.name))return{length:i.name.length}}(e,i);if(p)m=e.slice(p.length);else{let t,s=function(e,t){for(let i of t.matchers){let t=function(e,t){if("pattern"===t.type)for(let i of t.values){let s=t.prefix+i;if(L(e,s))return{value:i,length:s.length}}}(e,i);if(t)return t}}(e,i);if(s)t=s.value,m=e.slice(s.length),this.keyToken=e.slice(0,s.length-s.value.length);else if(f.endsWith("()"))t=e;else if("group"===f)t=e;else{let i=e.indexOf(":");this.keyToken=e.slice(0,i+1),t=e.slice(i+1)}this.valueComponents=[];let r=this.parseValues(this.valueComponents,0,t,"","",void 0,!1,!function(e){let t=e.emit;switch(t.type){case"declarations":return t.declarations.some(e=>E.has(e));case"property":return E.has(t.property);case"template":return Object.keys(t.declarations).some(e=>E.has(e));case"static":return t.rules.some(e=>Object.keys(e.declarations).some(e=>E.has(e)));default:return!1}}(i)?[]:Array.from(this.css.animations.keys()));if(this.invalidValueSyntax){this.valid=!1;return}this.valueToken=t.slice(0,r),s?r!==t.length&&(m=t.slice(r)+m):m=t.slice(r)}"!"===m[0]&&(this.important=!0,m=m.slice(1)),this.stateToken=m;let y=this.resolveStateBranches(m);this.branchCount=y.length;let g=y[a];if(!g){this.valid=!1;return}if(g.mode&&(this.mode=g.mode),g.selectorNodes?.length&&(this.selectorNodes=g.selectorNodes),g.selectorTemplate&&(this.selectorTemplate=g.selectorTemplate),g.atRules&&(this.atRules=g.atRules),!1===g.valid&&(this.valid=!1),this.variantBranchKey=g.key,this.mode&&"media"===t.settings.modeTrigger){let e={name:"prefers-color-scheme",value:this.mode};this.atRules?.media?this.atRules.media.push(e):this.atRules={media:[e]}}this.atRules?.layer&&this.atRules.layer.length>1&&(this.valid=!1),g.layer&&(this.explicitLayerName&&this.explicitLayerName!==g.layer&&(this.valid=!1),this.layerName=g.layer,this.explicitLayerName=g.layer);let v=this.atRules?.layer?.length===1&&this.atRules.layer[0];if(v){let e=String(v.value);("base"===e||"defaults"===e||"components"===e||"utilities"===e)&&(this.layerName=e,this.explicitLayerName=e,this.atRules.layer=void 0)}if(this.layer=t.getUtilityLayer(this.layerName),this.valueComponents){if(n=this.resolveValue(this.valueComponents,"",[],!1),this.invalidValueSyntax){this.valid=!1;return}let e=this.emitDynamicDeclarationRules(n);if(e)this.declarations=e[0]?.declarations,(e.length>1||e.some(({atRules:e,selector:t})=>e?.length||t))&&(this.declarationRules=e);else{let e=this.emitDynamicDeclarations(n);this.declarations=e,e&&i.atRules?.length&&(this.declarationRules=[{declarations:e,atRules:i.atRules}])}}else{let e="static"===i.emit.type?i.emit.rules.map(({declarations:e,atRules:t,selector:i})=>({declarations:e,atRules:t,selector:i})):[];this.declarations=e[0]?.declarations,(e.length>1||e.some(({atRules:e,selector:t})=>e?.length||t))&&(this.declarationRules=e)}let R=this.declarationRules||(this.declarations?[{declarations:this.declarations}]:[]);if(R.some(({declarations:e})=>Object.entries(e??{}).length)){let e,t;for(let{declarations:e}of R){let t=C(e,this.css.variables);if(t)for(let e of t)this.variableNames?this.variableNames.add(e):this.variableNames=new Set([e]);let i=function(e,t){let i=new Set;for(let s in e){let r=e[s];for(let e of function(e,t,i){let s=new Set;if("animation"!==e&&"animation-name"!==e)return s;let r=new Set(i.animationNames);if(!r.size)return s;for(let e of U(t,r))s.add(e);for(let e of i.variableNames||[])!function e(t,i,s,r,a=new Set){if(!(!i||a.has(i.name))){for(let e of(a.add(i.name),U(i.value,s)))t.add(e);for(let e of Object.values(i.modes||{}))for(let i of U(e.value,s))t.add(i);i.dependencies?.forEach(i=>{e(t,r?.get(i),s,r,a)})}}(s,i.variables?.get(e),r,i.variables);return s}(s,r,t))i.add(e)}return i.size?i:void 0}(e,{animationNames:this.css.animations.keys(),variables:this.css.variables,variableNames:t});if(i)for(let e of i)this.animationNames?this.animationNames.add(e):this.animationNames=new Set([e])}this.priority=(e=[],t=t=>{let i,s;for(let[r,a]of(i=new Map,(s=(e,t=!1)=>{(e??[]).forEach((e,r,a)=>{let n=a[r-1];if("operator"in e){let s=i.get(e.name)??{},r=e.operator;switch(t&&(r=x[r]),n?.type==="logical"&&"not"===n.value&&(r=x[r]),r){case">":s.min=e.value+.02;break;case">=":s.min=e.value;break;case"<":s.max=e.value-.02;break;case"<=":s.max=e.value}i.set(e.name,s)}"children"in e&&Array.isArray(e.children)&&s(e.children,n?.type==="logical"&&"not"===n.value)})})(t),i).entries()){let t=a.max??Number.MAX_SAFE_INTEGER,i=a.min??0;e.push([r,i,t])}},this.atRules?.media&&t(this.atRules.media),this.atRules?.container&&t(this.atRules.container),e.sort(([e],[t])=>b(e,t)),{features:e,selector:function e(t=[]){let i=0;for(let s of t)"value"in s&&"string"==typeof s.value&&(i+=k[s.value]??0),"children"in s&&Array.isArray(s.children)&&(i+=e(s.children));return i}(this.selectorNodes??[])}),R.length>1&&(this.nodes=R.map(({declarations:e,atRules:t,selector:i})=>new I(this,e,t,i)))}else this.valid=!1}resolveVariableAlias(e){let t=this.variables?.get(e)||this.css.variables.get(e);if(t)return{name:t.name??e,variable:t};if("-"!==e[0])return;let i=e.slice(1),s=this.variables?.get(i)||this.css.variables.get(i);if(s?.type==="number")return{name:s.name??i,variable:s,negative:!0}}resolveDynamicDeclarationValue(e,t){return null===e?t:Array.isArray(e)?e.map(e=>null===e?t:e).join(""):e}resolveDynamicDeclarations(e,t){let i={};for(let s in e)i[s]=this.resolveDynamicDeclarationValue(e[s],t);return i}emitDynamicDeclarationRules(e){let t=this.registeredUtility.emit;if("static"===t.type)return t.rules.map(({declarations:t,atRules:i,selector:s})=>({declarations:this.resolveDynamicDeclarations(t,e),atRules:i,selector:s}))}emitDynamicDeclarations(e){let t=this.registeredUtility.emit;switch(t.type){case"declarations":{let i={};for(let s of t.declarations)i[s]=e;return i}case"template":{let i={};for(let s in t.declarations){let r=t.declarations[s];i[s]=null==r?e:Array.isArray(r)?r.map(t=>null==t?e:t).join(""):r}return i}case"group":return this.emitGroupDeclarations(e);case"property":return{[t.property]:e};case"static":return}}emitGroupDeclarations(t){let i={},s=e=>{let t=e.indexOf(":");-1!==t&&(i[e.slice(0,t)]=e.slice(t+1).replace(/\|/g," "))},r=e=>{let t=e.declarations;for(let s in t){let r=String(t[s]);("important"in e&&e.important||e.css.settings.important)&&!r.endsWith("!important")&&(r+="!important"),i[s]=r}if(e.animationNames)for(let t of(this.animationNames||(this.animationNames=new Set),e.animationNames))this.animationNames.add(t);if(e.variableNames)if(this.variableNames)for(let t of e.variableNames)this.variableNames.add(t);else this.variableNames=new Set(e.variableNames)},a=[],n="",l=()=>{n&&(a.push(n.replace(/ /g,"|")),n="")},o=1;for(let i of(!function i(s){for(;o<t.length;o++){let r=t[o];if(!s){if(";"===r){l();continue}if("}"===r)break}if(n+=r,s===r){if("'"===s||'"'===s){let e=0;for(let t=n.length-2;"\\"===n[t];t--)e++;if(e%2)continue}break}r in e&&"'"!==s&&'"'!==s&&(o++,i(e[r]))}}(""),l(),a)){let e=this.css.generate(i,this.mode);if(e.length)for(let t of e)r(t);else s(i)}return i}resolveStateBranches(e){let[t="",...i]=e.split("@"),s=[{key:""}];for(let e of(s=this.applySelectorTokenBranches(s,t),i)){if(this.css.modes.includes(e)){s=s.map(t=>({...t,mode:e,key:t.key+"@"+e}));continue}this.atToken=(this.atToken||"")+"@"+e;let t=`@${e}`,i=this.css.resolveVariant(t);if(i){s=s.flatMap(e=>i.map((i,s)=>V(e,i,this.css,`${t}#${s}`)));continue}let r=d(e,this.css);s=s.map(t=>({...t,key:t.key+"@"+e,atRules:$(t.atRules,r)}))}return s.length?s:[{key:""}]}applySelectorTokenBranches(e,t){if(!t)return e;let i=[...this.css.variants.keys()].filter(e=>e.startsWith(":")).sort((e,t)=>t.length-e.length),s=0,r="",a=()=>{if(!r)return;let t=v(y(r,this.css),"&");e=e.map(e=>({...e,key:e.key+r,selectorTemplate:z(e.selectorTemplate,t),selectorNodes:y(e.selectorTemplate?z(e.selectorTemplate,t)?.replace(/&/g,"")||"":r,this.css)})),r=""};for(;s<t.length;){if("("===t[s]){let e=_(t,s);if(-1!==e){r+=t.slice(s,e+1),s=e+1;continue}}let n=i.find(e=>{if(!t.startsWith(e,s))return!1;let i=t[s+e.length];return void 0===i||"("===i||!/[-_a-zA-Z0-9]/.test(i)});if(!n||!(/^:{1,2}[-_a-zA-Z][-_a-zA-Z0-9]*$/.test(n)||/^@[-_a-zA-Z][-_a-zA-Z0-9]*$/.test(n))){r+=t[s++];continue}let l=this.css.resolveVariant(n);if(!l){r+=t[s++];continue}a();let o="";if("("===t[s+=n.length]){let e=_(t,s);-1!==e&&(o=t.slice(s,e+1),s=e+1)}e=e.flatMap(e=>l.map((t,i)=>{let s=t.selector&&o?t.selector+o:t.selector,r=V(e,{...t,...s?{selector:s}:{}},this.css,`${n}#${i}${o}`),a=r.selectorTemplate;return{...r,...a?{selectorNodes:y(a.replace(/&/g,""),this.css)}:{}}}))}return a(),e}get text(){return this.valid?this.nodes?this.nodes.map(({text:e})=>e).join(""):this.declarationRules?this.declarationRules.map(({declarations:e,atRules:t,selector:i})=>this.createRuleText(e,t,i)).join(""):this.createRuleText(this.declarations):""}createRuleText(e,t,i){let s=[];for(let t in e){let i=e[t],r=t+":"+String(i);s.push(r+((this.important||this.css.settings.important)&&!r.endsWith("!important")?"!important":""))}let r=this.createSelectorText(i)+"{"+s.join(";")+"}";void 0!==this.atRules&&l.forEach(e=>{let t=this.atRules?.[e];if(t){var i;let s,a;i={id:e,nodes:t},a=(s=e=>e.map(e=>{let t="";if("children"in e){let i=s(e.children);t="group"===e.type?"("+i+")":i}else{if("boolean"===e.type)return`(${e.name})`;let i="number"===e.type?String(e.value)+(e.unit||""):e.value;t="name"in e?"operator"in e?`(${e.name}${e.operator}${i})`:`(${e.name}:${i})`:i}return t}).filter(Boolean).join("layer"===i.id?".":" "))(i.nodes),r="@"+i.id+(a?" "+a:"")+"{"+r+"}"}});var a=r;if(!t?.length)return a;for(let e=t.length-1;e>=0;e--){let i=t[e]?.trim();i&&(a=`${i}{${a}}`)}return a}get selectorText(){return this.createSelectorText()}createSelectorText(e){let t="";if(this.css.settings.scope&&(t=this.css.settings.scope+" "+t),this.mode){let e=this.css.getModeSelector(this.mode);e&&(t=e+" "+t)}let i=t+"."+function(e){let t;if("u">typeof CSS)return CSS.escape(e);if(0==arguments.length)throw TypeError("`CSS.escape` requires an argument.");let i=String(e),s=i.length,r=-1,a="",n=i.charCodeAt(0);if(1==s&&45==n)return"\\"+i;for(;++r<s;){if(0==(t=i.charCodeAt(r))){a+="�";continue}if(t>=1&&t<=31||127==t||0==r&&t>=48&&t<=57||1==r&&t>=48&&t<=57&&45==n){a+="\\"+t.toString(16)+" ";continue}if(t>=128||45==t||95==t||t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122){a+=i.charAt(r);continue}a+="\\"+i.charAt(r)}return a}(this.fixedClass??this.name),s=this.selectorTemplate?i:this.selectorNodes?v(this.selectorNodes,i):i;return this.selectorTemplate&&(s=this.selectorTemplate.replace(/&/g,s)),e?e.replace(/&/g,s):s}resolveValue=(t,i,s,r)=>{let a="",n=e=>{this.variableNames?this.variableNames.add(e):this.variableNames=new Set([e])},l=e=>{let t=this.parseValue(e,i);return"number"===t.type?String(t.value)+(t.unit||""):t.value},o=(e,t=[])=>{let i=t.indexOf(e.name);if(-1!==i)throw Error(`Circular inline variable reference: ${[...t.slice(i),e.name].join(" -> ")}`);if(void 0===e.value)return S(e.name);let a=[...t,e.name];return A("number"!==e.type||"number"!=typeof e.value||r?T(e.value).value:l(e.value),e=>{let t=this.css.variables.get(e);if(t){if(t.inline)return o(t,a);s.includes(e)||n(e)}})},h=e=>`calc(${e} * -1)`;for(let l of t)switch(l.type){case"function":if("$"===l.name){this.invalidValueSyntax=!0;break}l.bypassTransform||"calc"!==l.name?l.bypassTransform||"clamp"!==l.name?a+=l.token=l.text=l.name+l.symbol+this.resolveValue(l.children,i,s,r)+e[l.symbol]:a+=l.token=l.text=this.resolveMathFunction(this.stringifyValueComponents(l.children),s,{name:"clamp",wrapArguments:!0}):a+=l.token=l.text=this.resolveMathFunction(this.stringifyValueComponents(l.children),s);break;case"variable":let t=this.resolveVariableAlias(l.name),c=t?.variable,u=t?.name??l.name,f=l.negative||t?.negative,d=()=>{if(!l.fallback)return;let e=[];return this.parseValues(e,0,l.fallback,i,"",void 0,r,s),this.resolveValue(e,i,s,r)},m=e=>{if(e?.type==="number"&&void 0===l.alpha){if(f)return r?h(S(e.name)):function(e,t=16){let i=S(e.name);return`calc(${i} * -1)`}(e,this.css.settings.rootSize);if(!r)return function(e,t=16){return S(e.name)}(e,this.css.settings.rootSize)}return S(u,l.alpha,d())};if(c?.inline){let e=o(c);a+=l.text=void 0===l.alpha?f?h(e):e:N(e,l.alpha)}else c?(n(u),a+=l.text=m(c)):a+=l.text=m();break;case"separator":a+=l.text?l.text:l.text=l.value;break;case"number":a+=l.text=l.value+(l.unit||"");break;default:a+=l.text=l.value}return a};stringifyValueComponents(t){let i="";for(let s of t)switch(s.type){case"function":i+=s.name+s.symbol+this.stringifyValueComponents(s.children)+e[s.symbol];break;case"separator":i+=s.value;break;case"variable":i+=s.token||"$"+s.name;break;case"number":i+=s.token||String(s.value)+(s.unit||"");break;default:i+=s.token||s.value}return i}resolveMathFunction(e,i,s){let r=s?.name??"calc",a=[],n=0,l=(i,s,r,o,h)=>{let c,u=a!==i,f=[],d=!1,m=!1,p=!1,y=!1,g="",v=(a,l="",o="")=>{if(!1===c,g){if(!h){let e=t.exec(g);e&&(g=O(+e[1],this.css.settings.baseUnit??1,this.css.settings.rootSize))}if(d||r)i.push({type:"string",value:g,token:g});else{let e={...this.parseValue(g),token:g};if(!m&&isNaN(+g)&&"number"===e.type&&(m=!0),y)isNaN(+g)?"number"===e.type?(i.push(e),p=!0):i.push(e):i.push({type:"number",value:+g,token:g});else if(u){let e={type:"string",value:g,token:g};f.push(e),i.push(e)}else i.push(e)}g=""}a&&(("+"===a||"-"===a)&&b(),l&&" "===e[n-1]&&(l=""),o&&" "===e[n+1]&&(o=""),s?i.push({type:"separator",value:a,text:a,token:a}):i.push({type:"separator",value:a,text:l+a+o,token:a})),d=!1},b=()=>{!y||p||o||u&&!m||i.push({type:"separator",value:"*",text:" * ",token:"*"},{type:"number",value:1,unit:"",token:""}),y=!1,p=!1};for(;n<e.length;n++){let t=e[n];if("("===t){let e=/^([+-])/.exec(g);e&&i.push({type:"string",value:e[1],token:e[1]});let s=e?g.slice(1):g,r={type:"function",name:s,symbol:t,children:[],bypassTransform:"calc"===s,token:g};i.push(r),g="",n++,"$"===s&&(this.invalidValueSyntax=!0);let a="var"===s;(c=l(r.children,a,d||a||y&&p,y,a)||"var"===s)&&(m=!0,p=!0)}else if(")"===t){if(v(""),m)for(let e of f)Object.assign(e,this.parseValue(e.value));return m}else if(","===t)v(t,""," ");else if(" "===t)v(t);else{let i=e[n-1];switch(t){case"+":case"-":g||")"===i?v(t," "," "):g+=t;break;case"*":v(t," "," ");break;case"/":v(t," "," "),d=!0;break;default:g+=t}}}v(""),b()};l(a,!1,!1,!1,!1);let o=this.resolveValue(a,"",i,!0);return s?.wrapArguments&&(o=(function(e){let t=[],i=0,s=0;for(let r=0;r<e.length;r++){let a=e[r];"("===a?i++:")"===a?i--:","===a&&0===i&&(t.push(e.slice(s,r),a),s=r+1)}return t.push(e.slice(s)),t})(o).map(e=>{if(","===e)return e;let t=e.trim();if(!t||/^(?:calc|clamp|min|max|var)\(/.test(t)||!function(e){let t=0;for(let i=0;i<e.length;i++){let s=e[i];if("("===s)t++;else if(")"===s)t--;else if(0===t&&("+"===s||"-"===s||"*"===s||"/"===s)){let t=i-1;for(;" "===e[t];)t--;let r=e[t];if(("+"===s||"-"===s)&&(!r||"("===r||","===r||" "===r))continue;return!0}}return!1}(t))return e;let i=e.match(/^\s*/)[0],s=e.match(/\s*$/)[0];return`${i}calc(${t})${s}`}).join("")),r+"("+o+")"}parseValues=(i,s,r,a,n,l,o=!1,h=[])=>{let c=void 0===l,u=!c&&l.endsWith("var"),f="'"===n||'"'===n,d=[","];this.registeredUtility.separators?.length&&d.push(...this.registeredUtility.separators);let m="",p=()=>{if(m){let e=!1;if(!u||i.length){let t=(e,t,s=m,r)=>{let a={type:"variable",name:e,variable:this.css.variables.get(e),token:s};t&&(a.alpha=Number(t)),r&&(a.negative=!0),i.push(a)},s=(i,s)=>{let r=this.resolveVariableAlias(i);if(r&&(!r.negative||void 0===s)){let{name:i,negative:a}=r;h.includes(i)||(e=!0,t(i,s,m,a))}};if(/^\$[a-zA-Z0-9-]+(?:\/[^\/]+)?$/.test(m)){let[i,r]=m.slice(1).split("/");s(i,r),e||h.includes(i)||(e=!0,t(i,r))}else if(s(m),!e){let[e,t]=m.split("/");s(e,t)}}if(!e){if(!u){let e=t.exec(m);e&&(m=O(+e[1],this.css.settings.baseUnit??1,this.css.settings.rootSize))}if(o)i.push({type:"string",value:m,token:m});else{let e=this.parseValue(m,a);i.push({...e,token:m})}}m=""}};for(;s<r.length;s++){let t=r[s];if(t===n){if(f){let e=0;for(let t=m.length-1;"\\"===m[t];t--)e++;if(e%2){m+=t;continue}p()}else p();return s}if(!f&&t in e){let n=m;if("("===t&&"$"===n)return this.invalidValueSyntax=!0,r.length;let h={type:"function",name:n,symbol:t,children:[],token:""};i.push(h),m="",s=this.parseValues(h.children,++s,r,a,e[t],n||l||"",o||"calc"===n)}else if("|"!==t&&" "!==t||"}"===n||f&&"path"!==l){if(!f){if("."===t)if(isNaN(+r[s+1])){if(c)break}else"-"===r[s-1]&&(m+="0");else if(d.includes(t)){p(),i.push({type:"separator",value:t,text:(","===t?"":" ")+t+(","===t?"":" "),token:t});continue}else if(c&&("#"===t&&(m||i.length&&"separator"!==i[i.length-1].type)||["!","*",">","+","~",":","[","@","_"].includes(t)))break}m+=t}else p(),i.push({type:"separator",value:" ",token:t})}return p(),s};parseValue(e,t=""){return c(e,t,this.css.settings.rootSize)}get key(){return(this.fixedClass?this.fixedClass+" ":"")+this.name+(this.variantBranchKey?"\0"+this.variantBranchKey:"")}}class I{rule;declarations;atRules;selector;native;constructor(e,t,i,s){this.rule=e,this.declarations=t,this.atRules=i,this.selector=s}get text(){return this.rule.createRuleText(this.declarations,this.atRules,this.selector)}}let B=new WeakMap;function H(e){let t=B.get(e);return t||(t=new Map,B.set(e,t)),t}function G(e){let t=H(e);if(t.size!==e.rules.length)for(let i of(t.clear(),e.rules))t.set(i.key,i);return t}class W{name;css;rules=[];tokenCounts=new Map;constructor(e,t){this.name=e,this.css=t}attach(){this.css.rules.push(this)}detach(){this.css.rules.splice(this.css.rules.indexOf(this),1)}get(e){return G(this).get(e)}insert(e,t=this.rules.length){let i=G(this);if(!i.has(e.key))return this.rules.splice(t,0,e),i.set(e.key,e),this.css.rules.includes(this)||this.attach(),t}delete(e){let t=G(this),i=t.get(e);if(!i)return;let s=this.rules.indexOf(i);if(-1!==s)return this.rules.splice(s,1),t.delete(e),0===this.rules.length&&this.detach(),i}reset(){this.rules.length=0;let e=this.css.rules.indexOf(this);-1!==e&&this.css.rules.splice(e,1),this.tokenCounts.clear(),H(this).clear()}get text(){let e=this.rules.map(({text:e})=>e).join("");return e?"@layer "+this.name+"{"+e+"}":""}}class F extends W{name;css;rules=[];constructor(e,t){super(e,t),this.name=e,this.css=t}getBucketRank(e){if(e.mediaText)return 2;let t=e.selectorText.split(",").map(e=>e.trim());return t.includes(":root")||t.includes(":host")?0:1}compareBuckets(e,t){return this.getBucketRank(e)-this.getBucketRank(t)||e.order-t.order}shouldInsertBucketBefore(e,t){return this.getBucketRank(e)<this.getBucketRank(t)}getBuckets(){let e=new Map;for(let t of this.rules)for(let i of t.nodes){let t=i.mediaText+"\n"+i.selectorText,s=e.get(t);s||(s={mediaText:i.mediaText,selectorText:i.selectorText,order:e.size,nodes:[]},e.set(t,s)),s.nodes.push(i)}return Array.from(e.values()).sort((e,t)=>this.compareBuckets(e,t))}getBucketText(e){let t=`${e.selectorText}{${e.nodes.map(({declarationText:e})=>e).join(";")}}`;return e.mediaText?`${e.mediaText}{${t}}`:t}get text(){let e=this.getBuckets().map(e=>this.getBucketText(e)).join("");return e?"@layer "+this.name+"{"+e+"}":""}}class K{name;keyframes;css;native;variableNames;constructor(e,t,i){for(let s of(this.name=e,this.keyframes=t,this.css=i,Object.values(t))){let e=C(s,i.variables);if(e)for(let t of e)this.variableNames?this.variableNames.add(t):this.variableNames=new Set([t])}}get key(){return this.name}get text(){return`@keyframes ${this.name}{`+Object.entries(this.keyframes).reduce((e,[t,i])=>{let s=Object.entries(i).map(([e,t])=>`${e}:${t}`).join(";");return e+`${t}{${s}}`},"")+"}"}}class P{name;variable;css;nodes=[];constructor(e,t,i){this.name=e,this.variable=t,this.css=i;let s=void 0!==t.value;if(s&&this.nodes.push(new Z(this,t,i)),t.modes&&this.css.settings.modeTrigger)for(let e in t.modes){let r=new Z(this,t.modes[e],i,e),a=!s&&"none"!==this.css.settings.defaultMode&&this.css.settings.defaultMode===e;r.isDefaultMode=a,a?this.nodes.unshift(r):this.nodes.push(r)}}get key(){return this.name}get text(){return this.nodes.map(({text:e})=>e).join("")}}class Z{rule;variable;css;mode;native;isDefaultMode=!1;constructor(e,t,i,s){this.rule=e,this.variable=t,this.css=i,this.mode=s}get selectorText(){let e=this.isDefaultMode;if(!this.mode)return":root";switch(this.css.settings.modeTrigger){case"host":return`:host(.${this.mode})${e?",:host":""}`;case"class":return`.${this.mode}${e?",:root":""}`;default:return":root"}}get declarationName(){return`--${this.rule.name}`}get declarationValue(){let e=(t,i)=>A(T(t).value,t=>{let s=this.css.variables.get(t);if(!s?.inline||void 0===s.value)return;let r=i.indexOf(t);if(-1!==r)throw Error(`Circular inline variable reference: ${[...i.slice(r),t].join(" -> ")}`);return e(s.value,[...i,t])});return e(this.variable.value,[this.rule.name])}get declarationText(){return`${this.declarationName}:${this.declarationValue}`}get mediaText(){return"media"===this.css.settings.modeTrigger&&this.mode?`@media (prefers-color-scheme:${this.mode})`:""}get text(){let e=`${this.selectorText}{${this.declarationText}}`;return"media"===this.css.settings.modeTrigger&&this.mode&&(e=`@media (prefers-color-scheme:${this.mode}){${e}}`),e}}class q extends W{rules=[];insert(e){if(this.get(e.key)||"valid"in e&&!e.valid)return;let t=this.rules.length;e instanceof j&&(t=function(e,t){let i=0,s=e.length;for(;i<s;){let n=i+s>>1,l=e[n];if(!(l instanceof j)){var r=e,a=t;for(let e=0;e<r.length;e++){let t=r[e];if(t instanceof j&&0>M(a,t))return e}return r.length}0>M(t,l)?s=n:i=n+1}return i}(this.rules,e));let i=super.insert(e,t);if(void 0!==i)return this.insertVariables(e),this.insertAnimations(e),i}delete(e){let t=super.delete(e);if(!t)return;let i=(e,t,s=new Set)=>{if(s.has(e))return;s.add(e);let r=t.tokenCounts.get(e)??0,a=t===this.css.themeLayer?this.css.variables.get(e):void 0;if(r<=1){let r=t.delete(e);return t.tokenCounts.delete(e),a?.dependencies?.forEach(e=>i(e,t,s)),r}t.tokenCounts.set(e,r-1),a?.dependencies?.forEach(e=>i(e,t,s))};return"variableNames"in t&&t.variableNames?.forEach(e=>{i(e,this.css.themeLayer)}),"animationNames"in t&&t.animationNames?.forEach(e=>{let t=i(e,this.css.animationsNonLayer),s=t&&"variableNames"in t?t.variableNames:void 0;s&&s.forEach(e=>{i(e,this.css.themeLayer)})}),t}insertVariables(e){if(!("variableNames"in e))return;let t=(e,i=new Set)=>{if(i.has(e))return;i.add(e);let s=this.css.variables.get(e);if(s&&!s.inline){if(this.css.themeLayer.rules.find(({name:t})=>t===e)||this.css.isEmittedGlobalsVariable(e)){let t=this.css.themeLayer.tokenCounts.get(e)||0;this.css.themeLayer.tokenCounts.set(e,t+1)}else{let t=new P(e,s,this.css);this.css.themeLayer.insert(t),this.css.themeLayer.tokenCounts.set(e,1)}s.dependencies?.forEach(e=>t(e,i))}};e.variableNames?.forEach(e=>t(e))}insertAnimations(e){"animationNames"in e&&e.animationNames?.forEach(e=>{if(this.css.animationsNonLayer.rules.find(({name:t})=>t===e)||this.css.isEmittedGlobalsAnimation(e)){let t=this.css.animationsNonLayer.tokenCounts.get(e)||0;this.css.animationsNonLayer.tokenCounts.set(e,t+1)}else{let t=this.css.animations.get(e);if(!t)return;let i=new K(e,t,this.css);this.css.animationsNonLayer.insert(i),this.css.animationsNonLayer.tokenCounts.set(e,1),this.insertVariables(i)}})}}class J{css;rules=[];tokenCounts=new Map;constructor(e){this.css=e}insert(e){if(this.rules.includes(e))return;let t=this.css.style?.sheet;if(t)try{let i=t.insertRule(e.text,t.cssRules.length);e.native=t.cssRules[i]}catch(e){console.error(e)}this.rules.push(e),this.css.rules.push(e)}delete(e){let t=this.rules.find(t=>t.name===e);if(!t)return;let i=this.css.style?.sheet;if(i){let e=function(e,t){for(let i=0;i<e.length;i++)if(e[i]===t)return i;return -1}(i.cssRules,t.native);-1!==e&&i.deleteRule(e)}return this.rules.splice(this.rules.indexOf(t),1),this.css.rules.splice(this.css.rules.indexOf(t),1),t}get text(){return this.rules.map(({text:e})=>e).join("")}reset(){for(let e of this.rules){let t=this.css.rules.indexOf(e);-1!==t&&this.css.rules.splice(t,1)}this.rules.length=0,this.tokenCounts.clear()}}let X=new Set(["all","animation","animation-range","background","background-position","background-repeat","border","border-block","border-block-color","border-block-end","border-block-start","border-block-style","border-block-width","border-bottom","border-color","border-image","border-inline","border-inline-color","border-inline-end","border-inline-start","border-inline-style","border-inline-width","border-left","border-radius","border-right","border-style","border-top","border-width","column-rule","columns","contain-intrinsic-size","container","flex","flex-flow","font","font-synthesis","font-variant","gap","grid","grid-area","grid-column","grid-row","grid-template","inset","inset-block","inset-inline","line-clamp","list-style","margin","margin-block","margin-inline","mask","mask-border","mask-position","mask-repeat","offset","outline","overflow","overscroll-behavior","padding","padding-block","padding-inline","place-content","place-items","place-self","scroll-margin","scroll-margin-block","scroll-margin-inline","scroll-padding","scroll-padding-block","scroll-padding-inline","scroll-timeline","text-decoration","text-emphasis","text-wrap","transition","view-timeline","white-space"]),Q=Object.freeze({fg:"color",bg:"background","gap-x":"column-gap","gap-y":"row-gap","grid-col":"grid-column","grid-col-end":"grid-column-end","grid-col-start":"grid-column-start",b:"border",bb:"border-bottom",bl:"border-left",br:"border-right",bt:"border-top",bx:"border-inline",by:"border-block",h:"height",ix:"inset-inline",ixe:"inset-inline-end",ixs:"inset-inline-start",iy:"inset-block",iye:"inset-block-end",iys:"inset-block-start",leading:"line-height",m:"margin",max:"max-size","max-h":"max-height","max-size-x":"max-inline-size","max-size-y":"max-block-size","max-w":"max-width",mb:"margin-bottom",min:"min-size","min-h":"min-height","min-size-x":"min-inline-size","min-size-y":"min-block-size","min-w":"min-width",ml:"margin-left",mr:"margin-right",mt:"margin-top",mx:"margin-inline",mxe:"margin-inline-end",mxs:"margin-inline-start",my:"margin-block",mye:"margin-block-end",mys:"margin-block-start",p:"padding",pb:"padding-bottom",pl:"padding-left",pr:"padding-right",pt:"padding-top",px:"padding-inline",pxe:"padding-inline-end",pxs:"padding-inline-start",py:"padding-block",pye:"padding-block-end",pys:"padding-block-start",r:"border-radius",rbl:"border-bottom-left-radius",rbr:"border-bottom-right-radius",rtl:"border-top-left-radius",rtr:"border-top-right-radius","scroll-m":"scroll-margin","scroll-mb":"scroll-margin-bottom","scroll-ml":"scroll-margin-left","scroll-mr":"scroll-margin-right","scroll-mt":"scroll-margin-top","scroll-mx":"scroll-margin-inline","scroll-mxe":"scroll-margin-inline-end","scroll-mxs":"scroll-margin-inline-start","scroll-my":"scroll-margin-block","scroll-mye":"scroll-margin-block-end","scroll-mys":"scroll-margin-block-start","scroll-p":"scroll-padding","scroll-pb":"scroll-padding-bottom","scroll-pl":"scroll-padding-left","scroll-pr":"scroll-padding-right","scroll-pt":"scroll-padding-top","scroll-px":"scroll-padding-inline","scroll-pxe":"scroll-padding-inline-end","scroll-pxs":"scroll-padding-inline-start","scroll-py":"scroll-padding-block","scroll-pye":"scroll-padding-block-end","scroll-pys":"scroll-padding-block-start",shadow:"box-shadow","size-x":"inline-size","size-y":"block-size","line-clamp":"-webkit-line-clamp","text-fill-color":"-webkit-text-fill-color","text-stroke-color":"-webkit-text-stroke-color","text-stroke-width":"-webkit-text-stroke-width",tracking:"letter-spacing",w:"width",z:"z-index"});function Y(e,t=!1){return`${t?"=":"~"}${e}`}function ee(e){return Object.freeze(e.properties),Object.freeze(e.variableAliasRefs),Object.freeze(e)}Object.freeze(["animate","breakpoint","color","color-line","color-text","container","content","duration","easing","font","font-family","font-feature","font-size","font-weight","leading","order","radius","shadow","spacing","tracking"]);let et=Object.freeze(["background-position","bottom","border-spacing","column-gap","gap","inset","inset-block","inset-block-end","inset-block-start","inset-inline","inset-inline-end","inset-inline-start","left","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","mask-position","object-position","outline-offset","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","perspective","perspective-origin","right","row-gap","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","shape-margin","text-indent","text-underline-offset","top","translate","transform-origin","word-spacing"]),ei=Object.freeze(["cx","cy","stroke-dashoffset","x","y"]),es=Object.freeze(["background-size","block-size","contain-intrinsic-block-size","contain-intrinsic-inline-size","flex-basis","height","inline-size","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mask-size","width"]),er=Object.freeze(["border-bottom-left-radius","border-bottom-right-radius","border-end-end-radius","border-end-start-radius","border-radius","border-start-end-radius","border-start-start-radius","border-top-left-radius","border-top-right-radius"]),ea=Object.freeze(["border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-start","border-block-start-color","border-bottom","border-bottom-color","border-color","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-start","border-inline-start-color","border-left","border-left-color","border-right","border-right-color","border-top","border-top-color","outline","outline-color"]),en=Object.freeze([ee({properties:et,variableAliasRefs:[Y("spacing")]}),ee({properties:ei,variableAliasRefs:[Y("spacing")]}),ee({properties:es,variableAliasRefs:[Y("container")]}),ee({properties:er,variableAliasRefs:[Y("radius")]}),ee({properties:ea,variableAliasRefs:[Y("color-line"),Y("color")]}),ee({properties:Object.freeze(["accent-color","background-color","fill","filter"]),variableAliasRefs:[Y("color")]}),ee({properties:Object.freeze(["caret-color"]),variableAliasRefs:[Y("color-text"),Y("color")]}),ee({properties:Object.freeze(["stroke"]),variableAliasRefs:[Y("color-line"),Y("color")]}),ee({properties:Object.freeze(["color"]),variableAliasRefs:[Y("color",!0),Y("color-text"),Y("color")]}),ee({properties:Object.freeze(["-webkit-text-fill-color","text-decoration-color"]),variableAliasRefs:[Y("color-text"),Y("color")]}),ee({properties:Object.freeze(["-webkit-text-stroke-color"]),variableAliasRefs:[Y("color")]}),ee({properties:Object.freeze(["text-shadow"]),variableAliasRefs:[Y("color")]}),ee({properties:Object.freeze(["box-shadow"]),variableAliasRefs:[Y("shadow"),Y("color")]}),ee({properties:Object.freeze(["animation-delay","animation-duration","transition-delay","transition-duration"]),variableAliasRefs:[Y("duration")]}),ee({properties:Object.freeze(["animation-timing-function","transition-timing-function"]),variableAliasRefs:[Y("easing")]}),ee({properties:Object.freeze(["animation","transition"]),variableAliasRefs:[Y("duration"),Y("easing")]}),ee({properties:Object.freeze(["content"]),variableAliasRefs:[Y("content",!0)]}),ee({properties:Object.freeze(["font-feature-settings"]),variableAliasRefs:[Y("font-feature",!0)]}),ee({properties:Object.freeze(["font-family"]),variableAliasRefs:[Y("font-family",!0)]}),ee({properties:Object.freeze(["font-size"]),variableAliasRefs:[Y("font-size",!0)]}),ee({properties:Object.freeze(["font-weight"]),variableAliasRefs:[Y("font-weight",!0)]}),ee({properties:Object.freeze(["letter-spacing"]),variableAliasRefs:[Y("tracking")]}),ee({properties:Object.freeze(["line-height"]),variableAliasRefs:[Y("leading")]}),ee({properties:Object.freeze(["order"]),variableAliasRefs:[Y("order",!0)]})]),el={rootSize:16,baseUnit:4,defaultMode:"light",modeTrigger:"media",modes:["light","dark"]},eo=new WeakMap;function eh(e,t){for(let i of t)e.includes(i)||e.push(i)}function ec(e){return"property"===e.emit.type&&e.id===e.emit.property&&e.name===e.emit.property&&!e.variableAliasRefs?.length&&!e.variableAliases?.length&&!e.kind&&!e.atRules?.length}function eu(e){for(let t=0;t<e.length;t++)if(r.has(e[t]))return!1;return!0}function ef(e,t,i){let s=e.get(t);s?s.includes(i)||s.push(i):e.set(t,[i])}function ed(e,t){let i=new Map;for(let s of e)for(let e of s.matchers)if(e.type===t)for(let t of e.keys)ef(i,t,s);return i}function em(e){let t=new Map;if(!e)return t;for(let[i,s]of Object.entries(e))t.set(i,{id:s.id,nodes:s.nodes});return t}function ep(e,t,i,s=0,r=1){let a={...e,name:e.name||e.id,order:e.order??r-s-1,layer:e.layer||"utilities",matchers:e.matchers.map(e=>({...e}))},n=[...e.variableAliases||[],...(e.variableAliasRefs||[]).flatMap(i)];if(n.length)for(let[e,i]of(a.variables=new Map,n)){if(a.variables.has(e))continue;let s=t.get(i);s&&a.variables.set(e,s)}let l=a.keys?[...a.keys]:[],o=a.aliasGroups?[...a.aliasGroups]:[];for(let e of a.matchers)"key"===e.type?eh(l,e.keys):("variable"===e.type||"value"===e.type)&&eh(o,e.keys);return l.length&&!a.keys&&(a.keys=l),o.length&&!a.aliasGroups&&(a.aliasGroups=o),a.key||(a.key=l[0]||o[0]),a}function ey(e,t){e.includes(t)||e.push(t)}let eg={id:"group",name:"group",type:-1,order:0,emit:{type:"group"},matchers:[]};function ev(e){return void 0===e||!/[a-zA-Z0-9-]/.test(e)}function eb(e,t){for(let i of t){let t=i+":";if(e.startsWith(t)&&e.length>t.length)return e.slice(t.length)}}function ek(e,t){if(!e.startsWith(t))return!1;let i=e[t.length];return void 0===i||"!"===i||"*"===i||">"===i||"+"===i||"~"===i||":"===i||"["===i||"@"===i||"_"===i||"."===i}function ex(e){return/^-{0,2}([_a-zA-Z][-_a-zA-Z0-9]*)\(/.exec(e)?.[1]}function eR(e){let t=ex(e);return"calc"===t||"clamp"===t||"min"===t||"max"===t}function eM(e){let t=ex(e);return!!t&&("url"===t||"element"===t||"paint"===t||"cross-fade"===t||t.endsWith("-gradient")||t.includes("image"))}function ew(e,t){return"variable"!==t.type&&"value"!==t.type||"multiple"===t.segments||!function(e){let t=0,i="";for(let s=0;s<e.length;s++){let r=e[s];if(i){"\\"===r?s++:r===i&&(i="");continue}if('"'===r||"'"===r){i=r;continue}if("("===r||"["===r||"{"===r){t++;continue}if(")"===r||"]"===r||"}"===r){t>0&&t--;continue}if("|"===r&&0===t)return!0}return!1}(e)}function eS(e){if("{"===e[0])return;let t=e.indexOf(":");if(!(t<=0))return e.slice(0,t)}function eN(e){for(let t=0;t<e.length;t++)if(r.has(e[t]))return t?e.slice(0,t):e;return e}class eA{options;definedUtilities=[];variableMatcherUtilities=[];valueMatcherUtilities=[];keyMatcherUtilities=[];patternMatcherUtilities=[];arbitraryMatcherUtilities=[];variableMatcherIndex=new Map;valueMatcherIndex=new Map;keyMatcherIndex=new Map;patternMatcherIndex;arbitraryStaticMatcherIndex;settings;rules=[];classUtilities=new Map;animationsNonLayer=new J(this);baseLayer=new q("base",this);themeLayer=new F("theme",this);defaultsLayer=new q("defaults",this);componentsLayer=new q("components",this);utilitiesLayer=new q("utilities",this);selectors=new Map;variables=new Map;modes=[];atRules=new Map;variants=new Map;breakpointAtRules=new Map;containerAtRules=new Map;animations=new Map;staticVariableTokens=new Set;staticAnimationTokens=new Set;emittedGlobals={variables:{},animations:{}};nativeDeclarationFastPathBlockedProperties=new Set;nativeDeclarationMatches=new Map;nativeDeclarationUtilities=new Map;nativeValueNamespaceUtilities=new Map;keyAliases=new Map;manifest;static create(e){let{manifest:t,emittedGlobals:i,...s}=e;return new this(t,i,s)}constructor(e,t,i={}){this.options=i,this.loadManifest(e),this.registerEmittedGlobals(t),new.target===eA&&this.insertStaticResources()}get text(){return this.rules.sort((e,t)=>{let i=["theme","base","defaults","components","utilities"];return(-1===i.indexOf(e.name)?1/0:i.indexOf(e.name))-(-1===i.indexOf(t.name)?1/0:i.indexOf(t.name))}).map(({text:e})=>e).join("")}getUtilityLayer(e="utilities"){switch(e){case"base":return this.baseLayer;case"defaults":return this.defaultsLayer;case"components":return this.componentsLayer;case"utilities":return this.utilitiesLayer;default:throw Error(`Unsupported utility layer: ${e}`)}}getUtilityLayers(){return[this.baseLayer,this.defaultsLayer,this.componentsLayer,this.utilitiesLayer]}loadManifest(e){var t;let i=function(e){let t=eo.get(e);if(t)return t;let i=function(e){let t;if(!e||1!==e.version)throw TypeError("Unsupported MasterCSSManifest version. Expected version 1.");if(Array.isArray(e.variables))throw TypeError("Unsupported MasterCSSManifest variables format. Expected namespace-grouped variables.");if("utilityBuckets"in e)throw TypeError("Unsupported MasterCSSManifest utilityBuckets field. Matcher indexes are engine-derived.");let i={...el,...e.settings||{},modes:e.settings?.modes?[...e.settings.modes]:[...el.modes]},s=function(e){let t=new Map;for(let i of function(e){let t=[];for(let[i,s]of Object.entries(e||{}))for(let e of s){let s=e.type||("number"==typeof e.value?"number":"string");t.push({...e,name:e.name||(i?`${i}${e.key?"-"+e.key:""}`:e.key),...i?{namespace:i}:{},type:s})}return t}(e.variables))i.name&&i.type&&!1!==i.value&&t.set(i.name,{name:i.name,key:i.key,type:i.type,...i.namespace?{namespace:i.namespace}:{},...void 0!==i.value?{value:Array.isArray(i.value)?i.value.join(","):i.value}:{},...i.numeric?{numeric:{...i.numeric}}:{},...i.modes?{modes:{...i.modes}}:{},...i.dependencies?.length?{dependencies:new Set(i.dependencies)}:{},...i.inline?{inline:!0}:{},...i.static?{static:!0}:{}});return t}(e),r=function(e){let t=new Map;if(!e.animations)return t;for(let i in e.animations){let s={};t.set(i,s);let r=e.animations[i];for(let e in r){let t=s[e]={},i=r[e];for(let e in i)t[e]=i[e]}}return t}(e),{selectors:a,variants:n}=function(e){let t=new Map;if(e.selectors)for(let[i,s]of Object.entries(e.selectors))t.set(i,s);let i=new Map;for(let t of e.variants||[])i.set(t.token,t.branches.map(e=>({...e,...e.selectorNodes?.length?{selectorNodes:e.selectorNodes}:{},...e.atRules?.length?{atRules:[...e.atRules]}:{},...e.atRuleNodes?.length?{atRuleNodes:e.atRuleNodes.map(e=>({id:e.id,nodes:e.nodes}))}:{}})));return{selectors:t,variants:i}}(e),l=(t=new Map,e=>{let i=t.get(e);if(i)return i;let r="="===e[0]||"~"===e[0]?e.slice(1):"",a=[],n=new Set;if(r)for(let e of s.values()){let t=function(e,t){let i=e.startsWith("-"),s=i?e.slice(1):e;if(s!==t&&!s.startsWith(t+"-"))return;let r=s===t?"":s.slice(t.length+1);return i?"-"+r:r}(e.name,r);void 0===t||n.has(t)||(n.add(t),a.push([t,e.name]))}return t.set(e,a),a}),o=function(e,t){let i=new Map;for(let s of en)if(s.properties?.length&&s.variableAliasRefs?.length)for(let r of s.properties){if(!r||i.has(r))continue;let a=ep(function(e,t){return{id:e,name:e,type:X.has(e)?-1:0,order:0,variableAliasRefs:[...t.variableAliasRefs],emit:{type:"property",property:e},matchers:[{type:"key",keys:[e]}]}}(r,s),e,t);i.set(r,a)}return i}(s,l),h=function(e,t,i){let s=[],r=[],a=[],n=[],l=[],o=[],h=new Set,c=e.utilities||[];for(let e=0;e<c.length;e++){let y=ep(c[e],t,i,e,c.length);!function(e,t){let i=ec(t);for(let s of t.matchers)if("key"===s.type||"value"===s.type||"variable"===s.type)for(let r of s.keys)i&&r===t.emit.property||e.add(r)}(h,y),s.push(y);var u=r,f=a,d=n,m=l,p=o;for(let e of y.matchers)switch(e.type){case"variable":(y.variableAliases?.length||y.variableAliasRefs?.length)&&ey(u,y);break;case"value":y.kind&&ey(f,y);break;case"key":ey(d,y);break;case"pattern":ey(m,y);break;default:ey(p,y)}}return{definedUtilities:s,variableMatcherUtilities:r,valueMatcherUtilities:a,keyMatcherUtilities:n,patternMatcherUtilities:l,arbitraryMatcherUtilities:o,variableMatcherIndex:ed(r,"variable"),valueMatcherIndex:ed(a,"value"),keyMatcherIndex:ed(n,"key"),patternMatcherIndex:l.every(e=>e.matchers.every(e=>"pattern"!==e.type||e.values.every(t=>eu(e.prefix+t))))?function(e){let t=new Map;for(let i of e)for(let e of i.matchers)if("pattern"===e.type)for(let s of e.values){let r=e.prefix+s;eu(r)&&ef(t,r,i)}return t}(l):void 0,arbitraryStaticMatcherIndex:o.every(e=>e.matchers.length&&e.matchers.every(e=>"static"===e.type&&eu(e.name)))?function(e){let t=new Map;for(let i of e)for(let e of i.matchers)"static"===e.type&&eu(e.name)&&ef(t,e.name,i);return t}(o):void 0,nativeDeclarationFastPathBlockedProperties:h}}(e,s,l);return{manifest:e,settings:i,definedUtilities:h.definedUtilities,variableMatcherUtilities:h.variableMatcherUtilities,valueMatcherUtilities:h.valueMatcherUtilities,keyMatcherUtilities:h.keyMatcherUtilities,patternMatcherUtilities:h.patternMatcherUtilities,arbitraryMatcherUtilities:h.arbitraryMatcherUtilities,variableMatcherIndex:h.variableMatcherIndex,valueMatcherIndex:h.valueMatcherIndex,keyMatcherIndex:h.keyMatcherIndex,patternMatcherIndex:h.patternMatcherIndex,arbitraryStaticMatcherIndex:h.arbitraryStaticMatcherIndex,selectors:a,variables:s,modes:[...i.modes],atRules:em(e.atRules),variants:n,breakpointAtRules:em(e.breakpointAtRules),containerAtRules:em(e.containerAtRules),animations:r,nativeDeclarationFastPathBlockedProperties:h.nativeDeclarationFastPathBlockedProperties,nativeValueNamespaceUtilities:o,keyAliases:function(){let e=new Map;for(let[t,i]of Object.entries(Q))t&&i&&t!==i&&e.set(t,i);return e}()}}(e);return eo.set(e,i),i}(e);this.manifest=i.manifest,this.settings={...t=i.settings,modes:[...t.modes]},this.definedUtilities=i.definedUtilities,this.variableMatcherUtilities=i.variableMatcherUtilities,this.valueMatcherUtilities=i.valueMatcherUtilities,this.keyMatcherUtilities=i.keyMatcherUtilities,this.patternMatcherUtilities=i.patternMatcherUtilities,this.arbitraryMatcherUtilities=i.arbitraryMatcherUtilities,this.variableMatcherIndex=i.variableMatcherIndex,this.valueMatcherIndex=i.valueMatcherIndex,this.keyMatcherIndex=i.keyMatcherIndex,this.patternMatcherIndex=i.patternMatcherIndex,this.arbitraryStaticMatcherIndex=i.arbitraryStaticMatcherIndex,this.selectors=i.selectors,this.variables=i.variables,this.modes=[...i.modes],this.atRules=i.atRules,this.variants=i.variants,this.breakpointAtRules=i.breakpointAtRules,this.containerAtRules=i.containerAtRules,this.animations=i.animations,this.nativeDeclarationFastPathBlockedProperties=i.nativeDeclarationFastPathBlockedProperties,this.nativeValueNamespaceUtilities=i.nativeValueNamespaceUtilities,this.keyAliases=i.keyAliases}applyEmittedGlobalsCounts(e){for(let[t,i]of Object.entries(e.variables||{}))i&&this.themeLayer.tokenCounts.set(t,(this.themeLayer.tokenCounts.get(t)||0)+i);for(let[t,i]of Object.entries(e.animations||{}))i&&this.animationsNonLayer.tokenCounts.set(t,(this.animationsNonLayer.tokenCounts.get(t)||0)+i)}registerEmittedGlobals(e){if(e){for(let[t,i]of Object.entries(e.variables||{}))i&&(this.emittedGlobals.variables[t]=(this.emittedGlobals.variables[t]||0)+i);for(let[t,i]of Object.entries(e.animations||{}))i&&(this.emittedGlobals.animations[t]=(this.emittedGlobals.animations[t]||0)+i);this.applyEmittedGlobalsCounts(e)}}isEmittedGlobalsVariable(e){return!!this.emittedGlobals.variables[e]}isEmittedGlobalsAnimation(e){return!!this.emittedGlobals.animations[e]}insertStaticVariable(e,t=new Set){if(t.has(e))return;t.add(e);let i=this.variables.get(e);if(i&&!i.inline){if(!this.staticVariableTokens.has(e)){if(!this.isEmittedGlobalsVariable(e)){this.themeLayer.get(e)||this.themeLayer.insert(new P(e,i,this));let t=this.themeLayer.tokenCounts.get(e)||0;this.themeLayer.tokenCounts.set(e,t+1)}this.staticVariableTokens.add(e)}i.dependencies?.forEach(e=>this.insertStaticVariable(e,t))}}insertStaticAnimation(e){if(this.staticAnimationTokens.has(e))return;let t=this.animations.get(e);if(!t)return;let i=this.animationsNonLayer.rules.find(t=>t.name===e);if(this.isEmittedGlobalsAnimation(e))i||(i=new K(e,t,this));else{i||(i=new K(e,t,this),this.animationsNonLayer.insert(i));let s=this.animationsNonLayer.tokenCounts.get(e)||0;this.animationsNonLayer.tokenCounts.set(e,s+1)}this.staticAnimationTokens.add(e),i.variableNames?.forEach(e=>this.insertStaticVariable(e))}insertStaticResources(){for(let[e,t]of this.variables)t.static&&this.insertStaticVariable(e);for(let e of this.animations.keys())this.manifest.animationOptions?.[e]?.static&&this.insertStaticAnimation(e);return this}resolveVariant(e){return this.variants.get(e)}parseValue(e,t=""){return c(e,t,this.settings.rootSize)}matchesMatcher(e,t,i){switch(i.type){case"static":return ek(e,i.name);case"key":return void 0!==eb(e,i.keys);case"variable":{let s=eb(e,i.keys);if(void 0===s||!t.variables?.size||!ew(s,i))return!1;for(let[e,i]of t.variables){if(s.startsWith(e)&&ev(s[e.length]))return!0;let t="-"+e;if("-"!==e[0]&&"number"===i.type&&s.startsWith(t)&&ev(s[t.length]))return!0}return!1}case"value":{let s=eb(e,i.keys);if(void 0===s||!ew(s,i))return!1;switch(t.kind){case"color":return"#"===s[0]||!!ex(s)&&!eR(s)&&!eM(s)||s.startsWith("currentColor")&&ev(s[12])||s.startsWith("transparent")&&ev(s[11]);case"number":return/[\d.]/.test(s[0])||eR(s);case"image":return eM(s);default:return!1}}case"pattern":return i.values.some(t=>ek(e,i.prefix+t))}}matchesUtility(e,t,i){return t.matchers.some(s=>(!i||s.type===i)&&this.matchesMatcher(e,t,s))}matchesExactUtilityDefinition(e,t){return t.matchers.some(t=>"static"===t.type&&ek(e,t.name))}hasClassKey(e){let t=eS(e);return!!(t&&!t.startsWith("--"))}isGroupClassName(e){return"{"===e[0]&&e.includes("}")}getClassKeyAlias(e){let t=eS(e);if(!t||t.startsWith("--"))return;let i=this.keyAliases.get(t);if(i)return{canonicalKey:i,indexOfColon:t.length,key:t}}canonicalizeClassName(e,t){let i=this.getClassKeyAlias(e);return i?{className:i.canonicalKey+e.slice(i.indexOfColon),fixedClass:t}:{className:e,fixedClass:t}}matchResolvedClassName(e){let t=eS(e);for(let i of t&&this.variableMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"variable"))return i;for(let i of t&&this.valueMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"value"))return i;for(let i of t&&this.keyMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"key"))return i;if(this.arbitraryStaticMatcherIndex){for(let t of this.arbitraryStaticMatcherIndex.get(eN(e))||[])if(this.matchesUtility(e,t))return t}else for(let t of this.arbitraryMatcherUtilities)if(this.matchesUtility(e,t))return t;if(this.patternMatcherIndex){for(let t of this.patternMatcherIndex.get(eN(e))||[])if(this.matchesUtility(e,t,"pattern"))return t}else for(let t of this.patternMatcherUtilities)if(this.matchesUtility(e,t,"pattern"))return t}createGroupUtility(e,t,i,s=0){if(this.isGroupClassName(e))return this.createRuleWithDefinition(e,eg,t,i,s)}createAllGroupUtilities(e,t,i){let s=this.createGroupUtility(e,t,i);if(!s?.valid)return[];let r=[s];for(let a=1;a<s.branchCount;a++){let s=this.createGroupUtility(e,t,i,a);s?.valid&&r.push(s)}return r}matchRawManagedClassName(e){let t=eS(e);if(t){for(let i of this.variableMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"variable"))return i;for(let i of this.valueMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"value"))return i;for(let i of this.keyMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"key"))return i;if(this.patternMatcherIndex){for(let t of this.patternMatcherIndex.get(eN(e))||[])if(this.matchesUtility(e,t,"pattern"))return t}else for(let t of this.patternMatcherUtilities)if(this.matchesUtility(e,t,"pattern"))return t}}match(e){if(this.isGroupClassName(e))return eg;if(this.hasClassKey(e)){let t=this.matchRawManagedClassName(e);if(t)return t}return this.matchResolvedClassName(this.canonicalizeClassName(e).className)}matchAllResolvedClassName(e){let t=eS(e);for(let i of t&&this.variableMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"variable"))return[i];for(let i of t&&this.valueMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"value"))return[i];for(let i of t&&this.keyMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"key"))return[i];let i=[];if(this.arbitraryStaticMatcherIndex)for(let t of this.arbitraryStaticMatcherIndex.get(eN(e))||[])this.matchesUtility(e,t)&&i.push(t);else for(let t of this.arbitraryMatcherUtilities)if(this.matchesUtility(e,t)){if(t.matchers.some(e=>"static"===e.type)){i.push(t);continue}return[t]}if(i.length)return i;if(this.patternMatcherIndex){for(let t of this.patternMatcherIndex.get(eN(e))||[])if(this.matchesUtility(e,t,"pattern"))return[t]}else for(let t of this.patternMatcherUtilities)if(this.matchesUtility(e,t,"pattern"))return[t];return[]}matchAllRawManagedClassName(e){let t=eS(e);if(!t)return[];for(let i of this.variableMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"variable"))return[i];for(let i of this.valueMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"value"))return[i];for(let i of this.keyMatcherIndex.get(t)||[])if(this.matchesUtility(e,i,"key"))return[i];if(this.patternMatcherIndex){for(let t of this.patternMatcherIndex.get(eN(e))||[])if(this.matchesUtility(e,t,"pattern"))return[t]}else for(let t of this.patternMatcherUtilities)if(this.matchesUtility(e,t,"pattern"))return[t];return[]}matchAll(e){if(this.isGroupClassName(e))return[eg];if(this.hasClassKey(e)){let t=this.matchAllRawManagedClassName(e);if(t.length)return t}return this.matchAllResolvedClassName(this.canonicalizeClassName(e).className)}parseNativeDeclarationProperty(e){let t=e.indexOf(":");if(t<=0)return;let i=e.slice(0,t);if(/^(?:--[-_a-zA-Z0-9]+|-?[_a-zA-Z][-_a-zA-Z0-9]*)$/.test(i))return i}getNativeDeclarationUtility(e){let t=this.nativeDeclarationUtilities.get(e);if(t)return t;let i={id:e,name:e,type:X.has(e)?-1:0,order:0,emit:{type:"property",property:e},matchers:[{type:"key",keys:[e]}]};return this.nativeDeclarationUtilities.set(e,i),i}matchNativeDeclaration(e){if(e.property.startsWith("--"))return!0;let t=this.options.nativeDeclarationMatcher;if(!t)return!1;let i=e.property+"\0"+e.value,s=this.nativeDeclarationMatches.get(i);if(void 0!==s)return s;let r=t(e);return this.nativeDeclarationMatches.set(i,r),r}isNativeDeclarationUtility(e){let t=Object.entries(e.declarations||{});if(1!==t.length)return!1;let[[i,s]]=t;return this.matchNativeDeclaration({property:i,value:String(s)})}shouldValidateNativeDeclarationUtility(e){return!!this.options.nativeDeclarationMatcher&&ec(e)&&e.matchers.every(e=>"key"===e.type)}createNativeDeclarationFallback(e,t,i,s=e){if(!this.options.nativeDeclarationMatcher)return[];let r=this.parseNativeDeclarationProperty(e);if(!r)return[];let a=this.getNativeDeclarationUtility(r),n=this.createRuleWithDefinition(s,a,t,i);if(!n?.valid||!this.isNativeDeclarationUtility(n))return[];let l=[n];for(let e=1;e<n.branchCount;e++){let r=this.createRuleWithDefinition(s,a,t,i,e);r?.valid&&this.isNativeDeclarationUtility(r)&&l.push(r)}return l}createNativeValueNamespaceFallback(e,t,i,s=e){let r=this.parseNativeDeclarationProperty(e);if(!r)return[];let a=this.nativeValueNamespaceUtilities.get(r);if(!a)return[];let n=this.createRuleWithDefinition(s,a,t,i);if(!n?.valid||this.options.nativeDeclarationMatcher&&!this.isNativeDeclarationUtility(n))return[];let l=[n];for(let e=1;e<n.branchCount;e++){let r=this.createRuleWithDefinition(s,a,t,i,e);r?.valid&&(!this.options.nativeDeclarationMatcher||this.isNativeDeclarationUtility(r))&&l.push(r)}return l}createNativeValueNamespaceFastPath(e,t,i,s=e){let r=this.parseNativeDeclarationProperty(e);return!r||this.nativeDeclarationFastPathBlockedProperties.has(r)?[]:this.createNativeValueNamespaceFallback(e,t,i,s)}createNativeDeclarationFastPath(e,t,i,s=e){let r=this.parseNativeDeclarationProperty(e);return!r||!r.startsWith("--")&&this.nativeDeclarationFastPathBlockedProperties.has(r)?[]:this.createNativeDeclarationFallback(e,t,i,s)}generate(e,t){return this.createRules(e,void 0,t)}createRule(e,t,i){let s=this.createGroupUtility(e,t,i);if(s)return s;let r=e;if(this.hasClassKey(e)){let s=this.matchRawManagedClassName(e);if(s){let e=this.createRuleWithDefinition(r,s,t,i);if(e?.valid)return e}}let a=this.canonicalizeClassName(e,t);e=a.className,t=a.fixedClass;let n=this.createNativeValueNamespaceFastPath(e,t,i,r);if(n.length)return n[0];let l=this.createNativeDeclarationFastPath(e,t,i,r);if(l.length)return l[0];let o=this.matchResolvedClassName(e);if(o&&this.matchesExactUtilityDefinition(e,o)){let s=this.createNativeValueNamespaceFallback(e,t,i,r);if(s.length)return s[0];let a=this.createNativeDeclarationFallback(e,t,i,r);if(a.length)return a[0]}return o?this.createRuleWithDefinition(r,o,t,i):this.createNativeValueNamespaceFallback(e,t,i,r)[0]||this.createNativeDeclarationFallback(e,t,i,r)[0]}createRules(e,t,i){let s=this.createAllGroupUtilities(e,t,i);if(s.length)return s;let r=e;if(this.hasClassKey(e)){let s=this.matchAllRawManagedClassName(e),a=[];for(let e of s){let s=this.createRuleWithDefinition(r,e,t,i);if(s&&s.valid){a.push(s);for(let n=1;n<s.branchCount;n++){let s=this.createRuleWithDefinition(r,e,t,i,n);s?.valid&&a.push(s)}}}if(a.length)return a}let a=this.canonicalizeClassName(e,t);e=a.className,t=a.fixedClass;let n=this.createNativeValueNamespaceFastPath(e,t,i,r);if(n.length)return n;let l=this.createNativeDeclarationFastPath(e,t,i,r);if(l.length)return l;let o=this.matchAllResolvedClassName(e);if(o.length&&o.every(t=>this.matchesExactUtilityDefinition(e,t))){let s=this.createNativeValueNamespaceFallback(e,t,i,r);if(s.length)return s;let a=this.createNativeDeclarationFallback(e,t,i,r);if(a.length)return a}let h=[];for(let e of o){let s=this.createRuleWithDefinition(r,e,t,i);if(s&&s.valid){h.push(s);for(let a=1;a<s.branchCount;a++){let s=this.createRuleWithDefinition(r,e,t,i,a);s?.valid&&h.push(s)}}}if(h.length)return h;let c=this.createNativeValueNamespaceFallback(e,t,i,r);return c.length?c:this.createNativeDeclarationFallback(e,t,i,r)}createRuleWithDefinition(e,t,i,s,r=0){let a=new j(e,this,t,i,s,r);if(!(a.valid&&this.shouldValidateNativeDeclarationUtility(t))||this.isNativeDeclarationUtility(a)){for(let e of this.getUtilityLayers()){let i=e.get(a.key),s=i instanceof j&&i.registeredUtility===t?i:void 0;if(s)return s}return a}}createRulesFromSelectorText(e,t){let i=e.split(" "),s=/[.#\[!\*>+~:,\s]/;for(let e=0;e<i.length;e++){let r=i[e],a=this.getModeSelector(r);if((0!==e||r!==a)&&(0!==e&&1!==e||r!==this.settings.scope)&&r.startsWith(".")){let e=r.slice(1),i="",a=0;for(;a<e.length;){let t=e[a],r=e[a+1];if("\\"===t&&r){i+=r,a+=2;continue}if(s.test(t))break;i+=t,a++}let n=this.generate(i).filter(e=>!t||e.layerName===t);if(n.length)return n}}}refresh(e=this.manifest){return this.reset(),this.loadManifest(e),this.applyEmittedGlobalsCounts(this.emittedGlobals),this.insertStaticResources(),this}reset(){return this.classUtilities.clear(),this.staticVariableTokens.clear(),this.staticAnimationTokens.clear(),this.baseLayer.reset(),this.themeLayer.reset(),this.defaultsLayer.reset(),this.componentsLayer.reset(),this.utilitiesLayer.reset(),this.animationsNonLayer.reset(),this}destroy(){return this.reset(),this}add(...e){for(let t of e){if(this.classUtilities.get(t))continue;let e=this.generate(t);e.length&&(e.forEach(e=>e.layer.insert(e)),this.classUtilities.set(t,e))}return this}remove(...e){for(let t of e){let e=this.classUtilities.get(t);e&&(e.forEach(e=>e.layer.delete(e.key)),this.classUtilities.delete(t))}}getModeSelector(e){switch(this.settings.modeTrigger){case"class":return"."+e;case"host":return":host(."+e+")"}}}let eT="master-css",eC={listeners:new Map,on(e,t){this.listeners.has(e)||this.listeners.set(e,new Set),this.listeners.get(e)?.add(t)},off(e,t){this.listeners.get(e)?.delete(t)},emit(e,...t){this.listeners.get(e)?.forEach(e=>e(...t))}};function eU(e,t){for(let i=0;i<e.length;i++)if(e[i]===t)return i;return -1}function eL(e){let t=e.nodes;return Array.isArray(t)?t:void 0}class eE extends W{name;cssRuntime;rules=[];tokenCounts=new Map;native=null;constructor(e,t){super(e,t),this.name=e,this.cssRuntime=t}attach(){super.attach();let e=this.cssRuntime.style?.sheet;if(e&&!this.native?.parentStyleSheet){let t=e.insertRule(this.text,e.cssRules.length);this.native=e.cssRules.item(t)}}insert(e,t=this.rules.length){let i=!!this.native?.parentStyleSheet,s=0===this.rules.length,r=super.insert(e,t);if(void 0===r||!this.native)return;let a=this.getNativeInsertIndex(r),n=!i&&s,l=(t,i)=>{if(n)return this.native.cssRules.item(i);try{let e=this.native.insertRule(t,i);return this.native.cssRules.item(e)}catch(t){console.error(t,e),this.rules.splice(r,1);return}},o=eL(e);if(o){let e=a;o.forEach(t=>{t.native=l(t.text,e),t.native&&e++})}else e.native=l(e.text,a);return r}getNativeInsertIndex(e){let t=0;for(let i=0;i<e;i++){let e=this.rules[i];t+=eL(e)?.length??1}return t}detach(){super.detach();let e=this.cssRuntime.style?.sheet;if(e&&this.native?.parentStyleSheet){let t=eU(e.cssRules,this.native);-1!==t&&e.deleteRule(t)}}delete(e){let t=super.delete(e);if(!t||!this.native)return;let i=e=>{if(!e)return;let t=eU(this.native.cssRules,e);if(-1!==t)try{this.native.deleteRule(t)}catch(t){console.error(t,e)}},s=eL(t);return s?s.forEach(e=>i(e.native)):i(t.native),t}reset(){super.reset();let e=this.cssRuntime.style?.sheet;if(this.native&&e){let t=eU(e.cssRules,this.native);-1!==t&&e.deleteRule(t),this.native=null}}}class eO extends eE{rules=[];insert(e){if(this.get(e.key)||"valid"in e&&!e.valid)return;let t=this.rules.length;"priority"in e&&(t=function(e,t){let i=0,s=e.length;for(;i<s;){let r=i+s>>1,a=e[r];if(!("priority"in a)){for(let i=0;i<e.length;i++){let s=e[i];if("priority"in s&&0>M(t,s))return i}return e.length}0>M(t,a)?s=r:i=r+1}return i}(this.rules,e));let i=super.insert(e,t);if(void 0!==i)return this.insertVariables(e),this.insertAnimations(e),i}delete(e){let t=super.delete(e);if(!t)return;let i=(e,t,s=new Set)=>{if(s.has(e))return;s.add(e);let r=t.tokenCounts.get(e)??0,a=t===this.css.themeLayer?this.css.variables.get(e):void 0;if(r<=1){let r=t.delete(e);return t.tokenCounts.delete(e),a?.dependencies?.forEach(e=>i(e,t,s)),r}t.tokenCounts.set(e,r-1),a?.dependencies?.forEach(e=>i(e,t,s))};return"variableNames"in t&&t.variableNames?.forEach(e=>{i(e,this.css.themeLayer)}),"animationNames"in t&&t.animationNames?.forEach(e=>{let t=i(e,this.css.animationsNonLayer),s=t&&"variableNames"in t?t.variableNames:void 0;s&&s.forEach(e=>{i(e,this.css.themeLayer)})}),t}insertVariables(e){if(!("variableNames"in e))return;let t=(e,i=new Set)=>{if(i.has(e))return;i.add(e);let s=this.css.variables.get(e);if(s&&!s.inline){if(this.css.themeLayer.rules.find(({name:t})=>t===e)||this.css.isEmittedGlobalsVariable(e)){let t=this.css.themeLayer.tokenCounts.get(e)||0;this.css.themeLayer.tokenCounts.set(e,t+1)}else{let t=new P(e,s,this.css);this.css.themeLayer.insert(t),this.css.themeLayer.tokenCounts.set(e,1)}s.dependencies?.forEach(e=>t(e,i))}};e.variableNames?.forEach(e=>t(e))}insertAnimations(e){"animationNames"in e&&e.animationNames?.forEach(e=>{let t=this.css.animationsNonLayer.rules.find(({name:t})=>t===e);if(t||this.css.isEmittedGlobalsAnimation(e)){let i=this.css.animationsNonLayer.tokenCounts.get(e)||0;this.css.animationsNonLayer.tokenCounts.set(e,i+1),t&&this.insertVariables(t)}else{let t=this.css.animations.get(e);if(!t)return;let i=new K(e,t,this.css);this.css.animationsNonLayer.insert(i),this.css.animationsNonLayer.tokenCounts.set(e,1),this.insertVariables(i)}})}}let ez=class extends F{name;cssRuntime;native=null;nativeBuckets=new Map;constructor(e,t){super(e,t),this.name=e,this.cssRuntime=t}attach(){super.attach();let e=this.cssRuntime.style?.sheet;if(e&&!this.native?.parentStyleSheet){let t=e.insertRule(this.text,e.cssRules.length);this.native=e.cssRules.item(t),this.syncNativeBuckets()}}getBucketKey(e,t){return e.replace(/\s*:\s*/g,":").replace(/\s+/g," ").trim()+"\n"+t.replace(/\s*,\s*/g,",").replace(/\s+/g," ").trim()}getStyleRule(e){return e instanceof CSSStyleRule?e:e instanceof CSSGroupingRule?e.cssRules.item(0):void 0}syncNativeBuckets(){if(this.nativeBuckets.clear(),this.native)for(let e of this.native.cssRules){let t=this.getStyleRule(e);if(!t)continue;let i=e instanceof CSSMediaRule?e.conditionText:"",s=i?`@media ${i}`:"",r=this.getBucketKey(s,t.selectorText);this.nativeBuckets.set(r,{key:r,mediaText:s,selectorText:t.selectorText,nativeRule:e,styleRule:t})}}ensureNativeBucket(e,t){if(!this.native)return;let i=this.getBucketKey(e,t),s=this.nativeBuckets.get(i);if(s)return s;let r=e?`${e}{${t}{}}`:`${t}{}`,a=this.native.insertRule(r,this.getNativeBucketInsertIndex(e,t)),n=this.native.cssRules.item(a);if(!n)return;let l=this.getStyleRule(n);if(!l)return;let o={key:i,mediaText:e,selectorText:t,nativeRule:n,styleRule:l};return this.nativeBuckets.set(i,o),o}getNativeBucketInsertIndex(e,t){if(!this.native)return 0;let i={mediaText:e,selectorText:t};for(let e=0;e<this.native.cssRules.length;e++){let t=this.native.cssRules.item(e);if(!t)continue;let s=this.getStyleRule(t);if(!s)continue;let r=t instanceof CSSMediaRule?`@media ${t.conditionText}`:"";if(this.shouldInsertBucketBefore(i,{mediaText:r,selectorText:s.selectorText}))return e}return this.native.cssRules.length}insert(e,t=this.rules.length){let i=0===this.rules.length,s=super.insert(e,t);if(void 0===s||!this.native||i)return s;for(let t of e.nodes){let e=this.ensureNativeBucket(t.mediaText,t.selectorText);e?.styleRule.style.setProperty(t.declarationName,t.declarationValue),t.native=e?.styleRule}return s}delete(e){let t=this.rules.find(t=>t.key===e),i=super.delete(e);if(!t||!i||!this.native)return i;for(let e of t.nodes){let t=this.getBucketKey(e.mediaText,e.selectorText),i=this.nativeBuckets.get(t);if(i&&(i.styleRule.style.removeProperty(e.declarationName),0===i.styleRule.style.length)){let e=eU(this.native.cssRules,i.nativeRule);-1!==e&&this.native.deleteRule(e),this.nativeBuckets.delete(t)}}return i}detach(){super.detach();let e=this.cssRuntime.style?.sheet;if(e&&this.native?.parentStyleSheet){let t=eU(e.cssRules,this.native);-1!==t&&e.deleteRule(t)}this.native=null,this.nativeBuckets.clear()}reset(){super.reset();let e=this.cssRuntime.style?.sheet;if(this.native&&e){let t=eU(e.cssRules,this.native);-1!==t&&e.deleteRule(t)}this.native=null,this.nativeBuckets.clear()}};function eD(e,t,i){let s=(e.get(t)||0)+i;s?e.set(t,s):e.delete(t)}function e$(e,t,i){let s=[e];for(;s.length;){let e=s.pop();if(!t.has(e)){t.add(e),i(e);for(let t=e.lastElementChild;t;t=t.previousElementSibling)s.push(t)}}}class eV{snapshots=new WeakMap;reset(){this.snapshots=new WeakMap}collectConnected(e,t){this.reset();let i=new Set;for(let s of e.querySelectorAll("[class]")){let e=this.snapshotElement(s);if(e)for(let s of e){let e=t.get(s)||0;e||i.add(s),t.set(s,e+1)}}return i}collectMutations(e){let t=new Map,i=new Map,s=new Set,r=new WeakSet,a=(e,t)=>{let s=(i.get(e)||0)+t;s?i.set(e,s):i.delete(e)};for(let t of e)if("childList"===t.type){for(let e of t.addedNodes)e instanceof Element&&e.isConnected&&a(e,1);for(let e of t.removedNodes)e instanceof Element&&!e.isConnected&&a(e,-1)}else if("attributes"===t.type&&"class"===t.attributeName){let e=t.target;e instanceof Element&&s.add(e)}for(let[e,s]of i)s>0?e$(e,r,e=>this.diffElement(e,t)):s<0&&!e.isConnected&&e$(e,r,e=>this.removeElement(e,t));for(let e of s)r.has(e)||this.diffElement(e,t);return t}snapshotElement(e){let t=e.classList;if(!t.length)return void this.snapshots.delete(e);let i=new Set;for(let e=0;e<t.length;e++)i.add(t.item(e));return this.snapshots.set(e,i),i}diffElement(e,t){let i,s=this.snapshots.get(e),r=e.classList;for(let e=0;e<r.length;e++){let a=r.item(e);s?.has(a)||eD(t,a,1),(i??=new Set).add(a)}if(s)for(let e of s)i?.has(e)||eD(t,e,-1);i?this.snapshots.set(e,i):this.snapshots.delete(e)}removeElement(e,t){let i=this.snapshots.get(e);if(i){for(let e of i)eD(t,e,-1);this.snapshots.delete(e)}}}function e_(e){let t=new Set;for(let i of e.matchAll(/var\(\s*--([_a-zA-Z0-9-]+)/g))t.add(i[1]);return t}class ej{text;native;constructor(e){this.text=e}}let eI=class{ir;layer;native;name;key;layerName;type;sortTier;priority;text;valid=!0;fixedClass;nodes;variableNames;animationNames;selectorText;constructor(e,t){this.ir=e,this.layer=t,this.name=e.className,this.key=e.key,this.layerName=e.layer,this.type=e.type,this.sortTier=e.sortTier,this.priority=e.priority,this.text=e.text,this.selectorText=e.selectorText,e.nodes?.length&&(this.nodes=e.nodes.map(e=>new ej(e.text)));let i=e_(e.text);e.nodes?.forEach(e=>{e_(e.text).forEach(e=>i.add(e))}),e.variableNames?.forEach(e=>i.add(e)),i.size&&(this.variableNames=i),e.animationNames?.length&&(this.animationNames=new Set(e.animationNames))}},eB=new Map,eH=({property:e,value:t})=>{if(e.startsWith("--"))return!0;let i=e+"\0"+t,s=eB.get(i);if(void 0!==s)return s;let r=!!globalThis.CSS?.supports(e,t);return eB.set(i,r),r},eG=`style#${eT}`;function eW(e){let t=e?.constructor.name;return"HTMLDocument"===t||"Document"===t}function eF(e,t){return eW(e)?e.getElementById(t):"querySelector"in e?e.querySelector(`#${t}`):void 0}function eK(e){try{let t=JSON.parse(e);return t?.version===1&&Array.isArray(t.rules)?t:void 0}catch(e){}}function eP(e){let t=eF(e,"master-css-hydration-manifest"),i=t?.textContent?.trim();if(i)return eK(i)}function eZ(e){let t=eF(e,eT),i=globalThis.HTMLStyleElement;return i&&t instanceof i?t.getAttribute("data-master-css-hydration-manifest"):void 0}class eq extends eA{root;hydrationManifest;static instances=new WeakMap;host;container;baseLayer=new eO("base",this);themeLayer=new ez("theme",this);defaultsLayer=new eO("defaults",this);componentsLayer=new eO("components",this);utilitiesLayer=new eO("utilities",this);classCounts=new Map;classTracker=new eV;hydrationFailureReason;observer;progressive=!1;observing=!1;static create(e){let{manifest:t,root:i=document,emittedGlobals:s,hydrationManifest:r}=e,a=void 0===r?eP(i):r,n=globalThis.MasterCSSRuntime.instances.get(i);return n?(n.registerEmittedGlobals(s),void 0!==a&&n.setHydrationManifest(a),n):new eq(i,t,s,a).register()}constructor(e=document,t,i,s){super(t,i,{nativeDeclarationMatcher:eH}),this.root=e,this.hydrationManifest=s,eW(e)?(this.container=e.head,this.host=e.documentElement):(this.container=this.root,this.host=this.root.host),this.applyEmittedGlobalsCounts({variables:this.emittedGlobals.variables})}register(){let e=globalThis.MasterCSSRuntime.instances.get(this.root)===this;return globalThis.MasterCSSRuntime.instances.set(this.root,this),eW(this.root)&&(this.root.defaultView.globalThis.masterCSSRuntime=this),e||__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:created",{cssRuntime:this}),this}unregister(){return globalThis.MasterCSSRuntime.instances.delete(this.root),eW(this.root)&&this.root.defaultView.globalThis.masterCSSRuntime===this&&(this.root.defaultView.globalThis.masterCSSRuntime=void 0),this}setHydrationManifest(e){return this.hydrationManifest=e,this}needsHydrationManifest(){return void 0===this.hydrationManifest&&!!eZ(this.root)}async loadHydrationManifest(){let e=eP(this.root);if(e)return this.setHydrationManifest(e),this;let t=eZ(this.root);if(!t)return this;try{let e=await fetch(t,{credentials:"same-origin"});if(!e.ok)return this;this.setHydrationManifest(eK(await e.text()))}catch(e){}return this}createRuntimeStyle(){let e="createElement"in this.root?this.root:this.root.ownerDocument;this.style=e.createElement("style"),this.style.id=eT,this.style.setAttribute("blocking","render"),this.container.append(this.style)}warnHydrationFallback(e){console.warn(`Master CSS progressive hydration requires a matching hydration manifest. ${e} Rebuilding ${eG} with the runtime.`)}useRuntimeStyle(e,t){t&&this.warnHydrationFallback(t),this.style?.remove(),this.style=null,this.progressive=!1,this.createRuntimeStyle(),this.insertStaticResources(),e.forEach(e=>this.add(e))}detectRuntimeStyle(){if(this.root.styleSheets)for(let e of this.root.styleSheets){let{ownerNode:t}=e;if(t instanceof HTMLStyleElement&&t.id===eT){this.style=t,this.progressive=!0;break}}}collectConnectedClasses(){return this.classTracker.collectConnected(this.root,this.classCounts)}hydrateRuntimeStyle(e){let t=this.style?.sheet&&this.hydrate(this.style.sheet.cssRules);if(t){let i=new Set(t.allUtilities.map(({fixedClass:e,name:t})=>e||t));for(let t of e)i.has(t)||this.add(t)}else this.useRuntimeStyle(e,this.hydrationFailureReason||`Cannot read ${eG} CSS rules.`)}renderRuntimeStyle(e){this.createRuntimeStyle(),this.insertStaticResources(),e.forEach(e=>this.add(e))}handleMutationRecords(e){let t=this.classTracker.collectMutations(e),i=[],s=[];for(let[e,r]of t){let t=this.classCounts.get(e)||0,a=t+r;a>0?(this.classCounts.set(e,a),0===t&&i.push(e)):(this.classCounts.delete(e),s.push(e))}i.length&&this.add(...i),s.length&&this.remove(...s),globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:mutated",{records:e,classCounts:t,cssRuntime:this})}startMutationObserver(){this.observer=new MutationObserver(e=>this.handleMutationRecords(e)),this.observer.observe(this.root,{childList:!0,attributes:!0,attributeFilter:["class"],subtree:!0})}revealHostIfNeeded(){this.progressive||this.host.removeAttribute("hidden")}observe(){if(this.observing)return this;this.detectRuntimeStyle();let e=this.collectConnectedClasses();return this.progressive?this.hydrateRuntimeStyle(e):this.renderRuntimeStyle(e),this.startMutationObserver(),this.revealHostIfNeeded(),this.observing=!0,globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:observed",{cssRuntime:this}),this}failHydration(e){this.hydrationFailureReason=e}getHydrationManifestLayerRules(){let e=new Map;if(!this.hydrationManifest?.rules?.length)return e;for(let t of this.hydrationManifest.rules){let i=e.get(t.layer);i?i.push(t):e.set(t.layer,[t])}return e}registerHydratedClassRule(e,t){let i=this.classUtilities,s=i.get(e);s?s.push(t):i.set(e,[t])}getUtilityLayerByName(e){switch(e){case"base":return this.baseLayer;case"defaults":return this.defaultsLayer;case"components":return this.componentsLayer;case"utilities":return this.utilitiesLayer}}collectHydrationManifestVariableNames(){let e=new Set,t=e=>{for(let t of e.matchAll(/var\(\s*--([_a-zA-Z0-9-]+)/g))i(t[1])},i=(t,s=new Set)=>{if(s.has(t))return;s.add(t);let r=this.variables.get(t);r&&(e.add(t),r.dependencies?.forEach(e=>i(e,s)))};for(let e of this.hydrationManifest?.rules||[])e.variableNames?.forEach(e=>i(e)),t(e.text),e.nodes?.forEach(e=>t(e.text)),e.animationNames?.forEach(e=>{let t=this.animations.get(e);if(!t)return;let s=new K(e,t,this);s.variableNames?.forEach(e=>i(e))});for(let[e,t]of this.variables)t.static&&i(e);return e}collectHydrationManifestAnimationNames(){let e=new Set;for(let t of this.hydrationManifest?.rules||[])t.animationNames?.forEach(t=>e.add(t));for(let t of this.animations.keys())this.manifest.animationOptions?.[t]?.static&&e.add(t);return e}nativeThemeLayerHasOnlyEmittedGlobalsVariables(e){if(!e)return!1;let t=!1;for(let i of e.cssRules){let e=this.themeLayer.getStyleRule(i);if(!e)return!1;for(let i=0;i<e.style.length;i++){let s=e.style.item(i);if(!s.startsWith("--")||(t=!0,!this.isEmittedGlobalsVariable(s.slice(2))))return!1}}return t}getVariableRuleBuckets(e){let t=new Map;for(let i of e)for(let e of i.nodes){let i=this.themeLayer.getBucketKey(e.mediaText,e.selectorText),s=t.get(i);s||(s={mediaText:e.mediaText,selectorText:e.selectorText,nodes:[]},t.set(i,s)),s.nodes.push(e)}return Array.from(t.values())}getNativeThemeRuleBucketKey(e){let t=this.themeLayer.getStyleRule(e);if(!t)return;let i=e instanceof CSSMediaRule?`@media ${e.conditionText}`:"";return{key:this.themeLayer.getBucketKey(i,t.selectorText),styleRule:t}}hydrateHydrationManifestVariables(e){let t=[...this.collectHydrationManifestVariableNames()].filter(e=>!this.isEmittedGlobalsVariable(e)).map(e=>{let t=this.variables.get(e);return t&&!t.inline?new P(e,t,this):void 0}).filter(e=>!!e),i=this.getVariableRuleBuckets(t),s=e?.cssRules.length||0;if(i.length!==s)return!t.length&&this.nativeThemeLayerHasOnlyEmittedGlobalsVariables(e);if(!t.length)return!0;if(!e)return!1;this.themeLayer.native=e;let r=new Map;for(let t of e.cssRules){let e=this.getNativeThemeRuleBucketKey(t);if(!e||r.has(e.key))return!1;r.set(e.key,e.styleRule)}for(let e of i){let t=r.get(this.themeLayer.getBucketKey(e.mediaText,e.selectorText));if(!t)return!1;for(let i of e.nodes)i.native=t}return this.themeLayer.rules.push(...t),this.themeLayer.syncNativeBuckets(),this.themeLayer.rules.length&&!this.rules.includes(this.themeLayer)&&this.rules.push(this.themeLayer),!0}hydrateHydrationManifestAnimations(e){let t=this.collectHydrationManifestAnimationNames(),i=new Set;for(let s of t){if(this.isEmittedGlobalsAnimation(s)){e.has(s)&&i.add(s);continue}let t=this.animations.get(s);if(!t)continue;let r=e.get(s);if(!r)return!1;let a=new K(s,t,this);a.native=r,this.animationsNonLayer.rules.push(a),this.rules.push(a),i.add(s)}for(let t of e.keys())if(!i.has(t))return!1;return!0}hydrateHydrationManifestLayer(e,t,i,s){if(i.reduce((e,t)=>e+(t.nodes?.length||1),0)!==t.cssRules.length)return!1;e.native=t;let r=0;for(let a of i){let i=new eI(a,e),n=i.nodes;if(n?.length)for(let e of n)e.native=t.cssRules.item(r++)||void 0;else i.native=t.cssRules.item(r++)||void 0;e.rules.push(i),e.insertVariables(i),e.insertAnimations(i),this.registerHydratedClassRule(a.className,i),s.allUtilities.push(i)}return e.rules.length&&!this.rules.includes(e)&&this.rules.push(e),!0}hydrate(e){let t;if(this.hydrationFailureReason=void 0,this.hydrationManifest?.version!==1||!Array.isArray(this.hydrationManifest.rules))return this.failHydration("Missing or invalid hydration manifest.");if(!this.hydrationManifest.rules.length)return this.failHydration(`Hydration manifest has no generated rules for ${eG}.`);let i={allUtilities:[]},s=this.getHydrationManifestLayerRules(),r=new Map,a=new Map;for(let i=0;i<e.length;i++){let s=e[i];if("CSSLayerBlockRule"===s.constructor.name){if("theme"===s.name){if(t)return this.failHydration(`Duplicate theme layer in ${eG}.`);t=s;continue}let e=this.getUtilityLayerByName(s.name);if(!e)return this.failHydration(`Unknown layer \`${s.name}\` in ${eG}.`);if(r.has(e.name))return this.failHydration(`Duplicate layer \`${s.name}\` in ${eG}.`);r.set(e.name,s)}else{if("CSSKeyframesRule"!==s.constructor.name)return this.failHydration(`Unknown top-level rule \`${s.cssText}\` in ${eG}.`);a.set(s.name,s)}}for(let[e,t]of s){let i=r.get(e);if(!i)return this.failHydration(`Missing layer \`${e}\` in ${eG}.`);if(t.reduce((e,t)=>e+(t.nodes?.length||1),0)!==i.cssRules.length)return this.failHydration(`Layer \`${e}\` does not match the hydration manifest.`)}for(let[e,t]of r)if(!s.has(e)&&t.cssRules.length)return this.failHydration(`Layer \`${e}\` has no hydration manifest rules.`);if(!this.hydrateHydrationManifestVariables(t))return this.failHydration("Theme layer does not match the hydration manifest.");if(!this.hydrateHydrationManifestAnimations(a))return this.failHydration("Keyframes do not match the hydration manifest.");for(let[e,t]of r){let r=s.get(e);if(!r?.length)continue;let a=this.getUtilityLayerByName(e);this.hydrateHydrationManifestLayer(a,t,r,i)}return globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:hydrated",{cssRuntime:this,result:i}),i}disconnect(){if(this.observing)return this.observer&&(this.observer.disconnect(),this.observer=void 0),this.observing=!1,this.reset(),this.loadManifest(this.manifest),this.classCounts.clear(),this.classTracker.reset(),this.progressive||(this.style?.remove(),this.style=null),globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:disconnected",{cssRuntime:this}),this}refresh(e=this.manifest){if(!this.observing||!this.style.sheet)return this;let t=this.style.sheet.cssRules;for(let e=t.length-1;e>=0;e--)this.style.sheet.deleteRule(e);return super.refresh(e),this.classCounts.forEach((e,t)=>{this.add(t)}),globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:refreshed",{cssRuntime:this,manifest:e}),this}destroy(){return this.disconnect(),this.unregister(),globalThis.__MASTER_CSS_DEVTOOLS_HOOK__?.emit("runtime:destroyed",{cssRuntime:this}),this}}async function eJ(e){let t,i=((t=new URL(e)).search="",t.hash="",t.pathname.endsWith("/")?t.pathname+="default-manifest.json":t.pathname.endsWith(".js")?t.pathname=t.pathname.replace(/\/[^/]*$/,"/default-manifest.json"):t.pathname+="/default-manifest.json",t),s=await fetch(i,{credentials:"same-origin"});if(!s.ok)throw Error(`Cannot load Master CSS default manifest from ${i.href}.`);return await s.json()}globalThis.MasterCSSRuntime||(globalThis.MasterCSSRuntime=eq),function(e=globalThis){e.__MASTER_CSS_DEVTOOLS_HOOK__||(e.__MASTER_CSS_DEVTOOLS_HOOK__=eC)}();let eX=document.currentScript;eX?.src?eJ(eX.src).then(e=>{let t=eq.create({manifest:e});if(t.needsHydrationManifest())return t.loadHydrationManifest().then(()=>t.observe());t.observe()}).catch(e=>console.error(e)):console.error("Cannot resolve the Master CSS runtime script URL.")}();
package/dist/index.d.ts CHANGED
@@ -1,5 +1,10 @@
1
1
  export { default as CSSRuntime, default } from './core';
2
- export { default as initCSSRuntime } from './init';
3
- export { default as RuntimeSyntaxLayer } from './syntax-layer';
2
+ export type { CSSRuntimeCreateOptions } from './core';
3
+ export { default as cssRuntime } from './css-runtime';
4
+ export { default as RuntimeUtilityLayer } from './utility-layer';
4
5
  export type * from './types';
5
- export * from './syntax-layer';
6
+ export type { CSSRuntimeDecoratorOptions, CSSRuntimeOptions } from './css-runtime';
7
+ export type { MasterCSSEmittedGlobals } from '@master/css-engine';
8
+ export type { MasterCSSManifest } from '@master/css-schema/manifest';
9
+ export type { MasterCSSGeneratedRuleIR, MasterCSSHydrationManifest } from '@master/css-schema/hydration-manifest';
10
+ export * from './utility-layer';