i-f&&(this.process(n,0),f=0);for(let h=f;hd.length)throw new Error("_sha2: outputLen bigger than state");for(let h=0;h e&t^~e&r,X4=(e,t,r)=>e&t^e&r^t&r,e3=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),Ht=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),$t=new Uint32Array(64),zi=class extends qi{constructor(){super(64,32,8,!1),this.A=Ht[0]|0,this.B=Ht[1]|0,this.C=Ht[2]|0,this.D=Ht[3]|0,this.E=Ht[4]|0,this.F=Ht[5]|0,this.G=Ht[6]|0,this.H=Ht[7]|0}get(){let{A:t,B:r,C:n,D:i,E:a,F:f,G:b,H:o}=this;return[t,r,n,i,a,f,b,o]}set(t,r,n,i,a,f,b,o){this.A=t|0,this.B=r|0,this.C=n|0,this.D=i|0,this.E=a|0,this.F=f|0,this.G=b|0,this.H=o|0}process(t,r){for(let h=0;h<16;h++,r+=4)$t[h]=t.getUint32(r,!1);for(let h=16;h<64;h++){let u=$t[h-15],c=$t[h-2],s=_t(u,7)^_t(u,18)^u>>>3,l=_t(c,17)^_t(c,19)^c>>>10;$t[h]=l+$t[h-7]+s+$t[h-16]|0}let{A:n,B:i,C:a,D:f,E:b,F:o,G:p,H:d}=this;for(let h=0;h<64;h++){let u=_t(b,6)^_t(b,11)^_t(b,25),c=d+u+J4(b,o,p)+e3[h]+$t[h]|0,l=(_t(n,2)^_t(n,13)^_t(n,22))+X4(n,i,a)|0;d=p,p=o,o=b,b=f+c|0,f=a,a=i,i=n,n=c+l|0}n=n+this.A|0,i=i+this.B|0,a=a+this.C|0,f=f+this.D|0,b=b+this.E|0,o=o+this.F|0,p=p+this.G|0,d=d+this.H|0,this.set(n,i,a,f,b,o,p,d)}roundClean(){$t.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}},t3=z4(()=>new zi),Vi={},Il;function n3(){return Il||(Il=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.bytes=e.stringToBytes=e.str=e.bytesToString=e.hex=e.utf8=e.bech32m=e.bech32=e.base58check=e.base58xmr=e.base58xrp=e.base58flickr=e.base58=e.base64url=e.base64=e.base32crockford=e.base32hex=e.base32=e.base16=e.utils=e.assertNumber=void 0;function t(A){if(!Number.isSafeInteger(A))throw new Error(`Wrong integer: ${A}`)}e.assertNumber=t;function r(...A){let T=(I,L)=>H=>I(L(H)),N=Array.from(A).reverse().reduce((I,L)=>I?T(I,L.encode):L.encode,void 0),x=A.reduce((I,L)=>I?T(I,L.decode):L.decode,void 0);return{encode:N,decode:x}}function n(A){return{encode:T=>{if(!Array.isArray(T)||T.length&&typeof T[0]!="number")throw new Error("alphabet.encode input should be an array of numbers");return T.map(N=>{if(t(N),N<0||N>=A.length)throw new Error(`Digit index outside alphabet: ${N} (alphabet: ${A.length})`);return A[N]})},decode:T=>{if(!Array.isArray(T)||T.length&&typeof T[0]!="string")throw new Error("alphabet.decode input should be array of strings");return T.map(N=>{if(typeof N!="string")throw new Error(`alphabet.decode: not string element=${N}`);let x=A.indexOf(N);if(x===-1)throw new Error(`Unknown letter: "${N}". Allowed: ${A}`);return x})}}}function i(A=""){if(typeof A!="string")throw new Error("join separator should be string");return{encode:T=>{if(!Array.isArray(T)||T.length&&typeof T[0]!="string")throw new Error("join.encode input should be array of strings");for(let N of T)if(typeof N!="string")throw new Error(`join.encode: non-string input=${N}`);return T.join(A)},decode:T=>{if(typeof T!="string")throw new Error("join.decode input should be string");return T.split(A)}}}function a(A,T="="){if(t(A),typeof T!="string")throw new Error("padding chr should be string");return{encode(N){if(!Array.isArray(N)||N.length&&typeof N[0]!="string")throw new Error("padding.encode input should be array of strings");for(let x of N)if(typeof x!="string")throw new Error(`padding.encode: non-string input=${x}`);for(;N.length*A%8;)N.push(T);return N},decode(N){if(!Array.isArray(N)||N.length&&typeof N[0]!="string")throw new Error("padding.encode input should be array of strings");for(let I of N)if(typeof I!="string")throw new Error(`padding.decode: non-string input=${I}`);let x=N.length;if(x*A%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;x>0&&N[x-1]===T;x--)if(!((x-1)*A%8))throw new Error("Invalid padding: string has too much padding");return N.slice(0,x)}}}function f(A){if(typeof A!="function")throw new Error("normalize fn should be function");return{encode:T=>T,decode:T=>A(T)}}function b(A,T,N){if(T<2)throw new Error(`convertRadix: wrong from=${T}, base cannot be less than 2`);if(N<2)throw new Error(`convertRadix: wrong to=${N}, base cannot be less than 2`);if(!Array.isArray(A))throw new Error("convertRadix: data should be array");if(!A.length)return[];let x=0,I=[],L=Array.from(A);for(L.forEach(H=>{if(t(H),H<0||H>=T)throw new Error(`Wrong integer: ${H}`)});;){let H=0,Z=!0;for(let K=x;KT?o(T,A%T):A,p=(A,T)=>A+(T-o(A,T));function d(A,T,N,x){if(!Array.isArray(A))throw new Error("convertRadix2: data should be array");if(T<=0||T>32)throw new Error(`convertRadix2: wrong from=${T}`);if(N<=0||N>32)throw new Error(`convertRadix2: wrong to=${N}`);if(p(T,N)>32)throw new Error(`convertRadix2: carry overflow from=${T} to=${N} carryBits=${p(T,N)}`);let I=0,L=0,H=2**N-1,Z=[];for(let K of A){if(t(K),K>=2**T)throw new Error(`convertRadix2: invalid data word=${K} from=${T}`);if(I=I<32)throw new Error(`convertRadix2: carry overflow pos=${L} from=${T}`);for(L+=T;L>=N;L-=N)Z.push((I>>L-N&H)>>>0);I&=2**L-1}if(I=I<=T)throw new Error("Excess padding");if(!x&&I)throw new Error(`Non-zero padding: ${I}`);return x&&L>0&&Z.push(I>>>0),Z}function h(A){return t(A),{encode:T=>{if(!(T instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return b(Array.from(T),2**8,A)},decode:T=>{if(!Array.isArray(T)||T.length&&typeof T[0]!="number")throw new Error("radix.decode input should be array of strings");return Uint8Array.from(b(T,A,2**8))}}}function u(A,T=!1){if(t(A),A<=0||A>32)throw new Error("radix2: bits should be in (0..32]");if(p(8,A)>32||p(A,8)>32)throw new Error("radix2: carry overflow");return{encode:N=>{if(!(N instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return d(Array.from(N),8,A,!T)},decode:N=>{if(!Array.isArray(N)||N.length&&typeof N[0]!="number")throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(d(N,A,8,T))}}}function c(A){if(typeof A!="function")throw new Error("unsafeWrapper fn should be function");return function(...T){try{return A.apply(null,T)}catch{}}}function s(A,T){if(t(A),typeof T!="function")throw new Error("checksum fn should be function");return{encode(N){if(!(N instanceof Uint8Array))throw new Error("checksum.encode: input should be Uint8Array");let x=T(N).slice(0,A),I=new Uint8Array(N.length+A);return I.set(N),I.set(x,N.length),I},decode(N){if(!(N instanceof Uint8Array))throw new Error("checksum.decode: input should be Uint8Array");let x=N.slice(0,-A),I=T(x).slice(0,A),L=N.slice(-A);for(let H=0;HA.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1"))),e.base64=r(u(6),n("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),a(6),i("")),e.base64url=r(u(6),n("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),a(6),i(""));let l=A=>r(h(58),n(A),i(""));e.base58=l("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),e.base58flickr=l("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),e.base58xrp=l("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz");let g=[0,2,3,5,6,7,9,10,11];e.base58xmr={encode(A){let T="";for(let N=0;N r(s(4,T=>A(A(T))),e.base58);e.base58check=w;let y=r(n("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),i("")),v=[996825010,642813549,513874426,1027748829,705979059];function m(A){let T=A>>25,N=(A&33554431)<<5;for(let x=0;x>x&1)===1&&(N^=v[x]);return N}function C(A,T,N=1){let x=A.length,I=1;for(let L=0;L126)throw new Error(`Invalid prefix (${A})`);I=m(I)^H>>5}I=m(I);for(let L=0;LV)throw new TypeError(`Length ${z} exceeds limit ${V}`);return B=B.toLowerCase(),`${B}1${y.encode(G)}${C(B,G,T)}`}function Z(B,G=90){if(typeof B!="string")throw new Error(`bech32.decode input should be string, not ${typeof B}`);if(B.length<8||G!==!1&&B.length>G)throw new TypeError(`Wrong string length: ${B.length} (${B}). Expected (8..${G})`);let V=B.toLowerCase();if(B!==V&&B!==B.toUpperCase())throw new Error("String must be lowercase or uppercase");B=V;let z=B.lastIndexOf("1");if(z===0||z===-1)throw new Error('Letter "1" must be present between prefix and data only');let U=B.slice(0,z),F=B.slice(z+1);if(F.length<6)throw new Error("Data must be at least 6 characters long");let D=y.decode(F).slice(0,-6),k=C(U,D,T);if(!F.endsWith(k))throw new Error(`Invalid checksum in ${B}: expected "${k}"`);return{prefix:U,words:D}}let K=c(Z);function P(B){let{prefix:G,words:V}=Z(B,!1);return{prefix:G,words:V,bytes:x(V)}}return{encode:H,decode:Z,decodeToBytes:P,decodeUnsafe:K,fromWords:x,fromWordsUnsafe:L,toWords:I}}e.bech32=E("bech32"),e.bech32m=E("bech32m"),e.utf8={encode:A=>new TextDecoder().decode(A),decode:A=>new TextEncoder().encode(A)},e.hex=r(u(4),n("0123456789abcdef"),i(""),f(A=>{if(typeof A!="string"||A.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof A} with length ${A.length}`);return A.toLowerCase()}));let O={utf8:e.utf8,hex:e.hex,base16:e.base16,base32:e.base32,base64:e.base64,base64url:e.base64url,base58:e.base58,base58xmr:e.base58xmr},_=`Invalid encoding type. Available types: ${Object.keys(O).join(", ")}`,S=(A,T)=>{if(typeof A!="string"||!O.hasOwnProperty(A))throw new TypeError(_);if(!(T instanceof Uint8Array))throw new TypeError("bytesToString() expects Uint8Array");return O[A].encode(T)};e.bytesToString=S,e.str=e.bytesToString;let R=(A,T)=>{if(!O.hasOwnProperty(A))throw new TypeError(_);if(typeof T!="string")throw new TypeError("stringToBytes() expects string");return O[A].decode(T)};e.stringToBytes=R,e.bytes=e.stringToBytes})(Vi)),Vi}var Zi,Pl;function r3(){if(Pl)return Zi;Pl=1;let{bech32:e,hex:t,utf8:r}=n3(),n={bech32:"bc",pubKeyHash:0,scriptHash:5,validWitnessVersions:[0]},i={bech32:"tb",pubKeyHash:111,scriptHash:196,validWitnessVersions:[0]},a={bech32:"tbs",pubKeyHash:111,scriptHash:196,validWitnessVersions:[0]},f={bech32:"bcrt",pubKeyHash:111,scriptHash:196,validWitnessVersions:[0]},b={bech32:"sb",pubKeyHash:63,scriptHash:123,validWitnessVersions:[0]},o=["option_data_loss_protect","initial_routing_sync","option_upfront_shutdown_script","gossip_queries","var_onion_optin","gossip_queries_ex","option_static_remotekey","payment_secret","basic_mpp","option_support_large_channel"],p={m:BigInt(1e3),u:BigInt(1e6),n:BigInt(1e9),p:BigInt(1e12)},d=BigInt("2100000000000000000"),h=BigInt(1e11),u={payment_hash:1,payment_secret:16,description:13,payee:19,description_hash:23,expiry:6,min_final_cltv_expiry:24,fallback_address:9,route_hint:3,feature_bits:5,metadata:27},c={};for(let C=0,E=Object.keys(u);Ct.encode(e.fromWordsUnsafe(C)),16:C=>t.encode(e.fromWordsUnsafe(C)),13:C=>r.encode(e.fromWordsUnsafe(C)),19:C=>t.encode(e.fromWordsUnsafe(C)),23:C=>t.encode(e.fromWordsUnsafe(C)),27:C=>t.encode(e.fromWordsUnsafe(C)),6:g,24:g,3:w,5:y};function l(C){return E=>({tagCode:parseInt(C),words:e.encode("unknown",E,Number.MAX_SAFE_INTEGER)})}function g(C){return C.reverse().reduce((E,O,_)=>E+O*Math.pow(32,_),0)}function w(C){let E=[],O,_,S,R,A,T=e.fromWordsUnsafe(C);for(;T.length>0;)O=t.encode(T.slice(0,33)),_=t.encode(T.slice(33,41)),S=parseInt(t.encode(T.slice(41,45)),16),R=parseInt(t.encode(T.slice(45,49)),16),A=parseInt(t.encode(T.slice(49,51)),16),T=T.slice(51),E.push({pubkey:O,short_channel_id:_,fee_base_msat:S,fee_proportional_millionths:R,cltv_expiry_delta:A});return E}function y(C){let E=C.slice().reverse().map(S=>[!!(S&1),!!(S&2),!!(S&4),!!(S&8),!!(S&16)]).reduce((S,R)=>S.concat(R),[]);for(;E.length{let A;E[R*2]?A="required":E[R*2+1]?A="supported":A="unsupported",O[S]=A});let _=E.slice(o.length*2);return O.extra_bits={start_bit:o.length*2,bits:_,has_required:_.reduce((S,R,A)=>A%2!==0?S||!1:S||R,!1)},O}function v(C,E){let O,_;if(C.slice(-1).match(/^[munp]$/))O=C.slice(-1),_=C.slice(0,-1);else{if(C.slice(-1).match(/^[^munp0-9]$/))throw new Error("Not a valid multiplier for the amount");_=C}if(!_.match(/^\d+$/))throw new Error("Not a valid human readable amount");let S=BigInt(_),R=O?S*h/p[O]:S*h;if(O==="p"&&S%BigInt(10)!==BigInt(0)||R>d)throw new Error("Amount is outside of valid range");return E?R.toString():R}function m(C,E){if(typeof C!="string")throw new Error("Lightning Payment Request must be string");if(C.slice(0,2).toLowerCase()!=="ln")throw new Error("Not a proper lightning payment request");let O=[],_=e.decode(C,Number.MAX_SAFE_INTEGER);C=C.toLowerCase();let S=_.prefix,R=_.words,A=C.slice(S.length+1),T=R.slice(-104);R=R.slice(0,-104);let N=S.match(/^ln(\S+?)(\d*)([a-zA-Z]?)$/);if(N&&!N[2]&&(N=S.match(/^ln(\S+)$/)),!N)throw new Error("Not a proper lightning payment request");O.push({name:"lightning_network",letters:"ln"});let x=N[1],I;if(E){if(E.bech32===void 0||E.pubKeyHash===void 0||E.scriptHash===void 0||!Array.isArray(E.validWitnessVersions))throw new Error("Invalid network");I=E}else switch(x){case n.bech32:I=n;break;case i.bech32:I=i;break;case a.bech32:I=a;break;case f.bech32:I=f;break;case b.bech32:I=b;break}if(!I||I.bech32!==x)throw new Error("Unknown coin bech32 prefix");O.push({name:"coin_network",letters:x,value:I});let L=N[2],H;if(L){let U=N[3];H=v(L+U,!0),O.push({name:"amount",letters:N[2]+N[3],value:H})}else H=null;O.push({name:"separator",letters:"1"});let Z=g(R.slice(0,7));R=R.slice(7),O.push({name:"timestamp",letters:A.slice(0,7),value:Z}),A=A.slice(7);let K,P,B,G;for(;R.length>0;){let U=R[0].toString();K=c[U]||"unknown_tag",P=s[U]||l(U),R=R.slice(1),B=g(R.slice(0,2)),R=R.slice(2),G=R.slice(0,B),R=R.slice(B),O.push({name:K,tag:A[0],letters:A.slice(0,3+B),value:P(G)}),A=A.slice(3+B)}O.push({name:"signature",letters:A.slice(0,104),value:t.encode(e.fromWordsUnsafe(T))}),A=A.slice(104),O.push({name:"checksum",letters:A});let V={paymentRequest:C,sections:O,get expiry(){let U=O.find(F=>F.name==="expiry");if(U)return z("timestamp")+U.value},get route_hints(){return O.filter(U=>U.name==="route_hint").map(U=>U.value)}};for(let U in u)U!=="route_hint"&&Object.defineProperty(V,U,{get(){return z(U)}});return V;function z(U){let F=O.find(D=>D.name===U);return F?F.value:void 0}}return Zi={decode:m,hrpToMillisat:v},Zi}var o3=r3(),i3=e=>Uint8Array.from(e.match(/.{1,2}/g).map(t=>parseInt(t,16))),s3=e=>{if(!e)return null;try{let t=o3.decode(e);if(!t||!t.sections)return null;let r=t.sections.find(s=>s.name==="payment_hash");if(r?.name!=="payment_hash"||!r.value)return null;let n=r.value,i=0,a=0,f="0",b=t.sections.find(s=>s.name==="amount");b?.name==="amount"&&b.value&&(f=b.value,a=parseInt(b.value),i=parseInt(b.value)/1e3);let o=t.sections.find(s=>s.name==="timestamp");if(o?.name!=="timestamp"||!o.value)return null;let p=o.value,d,h=t.sections.find(s=>s.name==="expiry");h?.name==="expiry"&&(d=h.value);let u=t.sections.find(s=>s.name==="description"),c=u?.name==="description"?u?.value:void 0;return{paymentHash:n,satoshi:i,millisatoshi:a,amountRaw:f,timestamp:p,expiry:d,description:c}}catch{return null}};function a3(e,t){try{if(!/^[0-9a-fA-F]{64}$/.test(e)||!/^[0-9a-fA-F]{64}$/.test(t))return!1;let r=Y4(t3(i3(e)));return t===r}catch{return!1}}var ro=class{constructor(t){if(this.paymentRequest=t.pr,!this.paymentRequest)throw new Error("Invalid payment request");let r=s3(this.paymentRequest);if(!r)throw new Error("Failed to decode payment request");this.paymentHash=r.paymentHash,this.satoshi=r.satoshi,this.millisatoshi=r.millisatoshi,this.amountRaw=r.amountRaw,this.timestamp=r.timestamp,this.expiry=r.expiry,this.createdDate=new Date(this.timestamp*1e3),this.expiryDate=this.expiry?new Date((this.timestamp+this.expiry)*1e3):void 0,this.description=r.description??null,this.verify=t.verify??null,this.preimage=t.preimage??null,this.successAction=t.successAction??null}async isPaid(){if(this.preimage)return this.validatePreimage(this.preimage);if(this.verify)return await this.verifyPayment();throw new Error("Could not verify payment")}validatePreimage(t){return!t||!this.paymentHash?!1:a3(t,this.paymentHash)}async verifyPayment(){try{if(!this.verify)throw new Error("LNURL verify not available");let t=await fetch(this.verify);if(!t.ok)throw new Error(`Verification request failed: ${t.status} ${t.statusText}`);let r=await t.json();return r.preimage&&(this.preimage=r.preimage),r.settled}catch(t){return console.error("Failed to check LNURL-verify",t),!1}}hasExpired(){let{expiryDate:t}=this;return t?t.getTime(){let t="https://getalby.com/api/rates/"+e.toLowerCase()+".json",r=await fetch(t);if(!r.ok)throw new Error(`Failed to fetch rate: ${r.status} ${r.statusText}`);return(await r.json()).rate_float/c3},Ul=async({satoshi:e,currency:t})=>{let r=await l3(t);return Number(e)*r};var To=ba(Fl(),1),Pn=class{constructor(t){this._config=t}async unload(){}},u3=e=>{let t=[];for(let r=0,n=atob(e.replace(/[ \r\n]+$/,""));rba(jl(),1))).default;return Ve=new e,Ve}catch(e){throw console.error(e),new Error("LNC is not available")}}var Hl="ONLY CONNECT TO TRUSTED WEBSITES",_s=class{constructor(t){this.lnc=t}enable(){return Promise.resolve()}async getInfo(){let t=await Ve.lnd.lightning.getInfo();return{methods:["enable","getBalance","getInfo","sendPayment"],version:"1.0",node:{alias:t.alias,pubkey:t.identityPubkey,color:t.color},supports:["lightning"]}}makeInvoice(t){throw new Error("Method not implemented.")}async sendPayment(t){let r=await Ve.lnd.lightning.sendPaymentSync({paymentRequest:t});if(r.paymentError)throw new Error(r.paymentError);if(!r.paymentPreimage)throw new Error("No preimage in response");if(typeof r.paymentPreimage!="string")throw new Error("expected preimage as string");return{preimage:u3(r.paymentPreimage)}}async getBalance(){var t;let r=await Ve.lnd.lightning.channelBalance();return{balance:parseInt(((t=r.localBalance)==null?void 0:t.sat)||"0")}}keysend(t){throw new Error("Method not implemented.")}lnurl(t){throw new Error("Method not implemented.")}lookupInvoice(t){throw new Error("Method not implemented.")}signMessage(t){throw new Error("Method not implemented.")}verifyMessage(t,r){throw new Error("Method not implemented.")}},Cs=class{constructor(t,r){this._instanceUrl=t,this._adminKey=r}enable(){return Promise.resolve()}async getInfo(){return{node:{alias:(await this.requestLnbits("GET","/api/v1/wallet")).name,pubkey:""},methods:["getInfo","getBalance","sendPayment"],version:"1.0",supports:["lightning"]}}async makeInvoice(t){return{paymentRequest:(await this.requestLnbits("POST","/api/v1/payments",{amount:t.amount||t.defaultAmount||+t,memo:t.defaultMemo,out:!1})).payment_request}}async sendPayment(t){let r=await this.requestLnbits("POST","/api/v1/payments",{bolt11:t,out:!0}),n=await this.requestLnbits("GET",`/api/v1/payments/${r.payment_hash}`);if(!n.preimage)throw new Error("No preimage");return{preimage:n.preimage}}async getBalance(){let t=await this.requestLnbits("GET","/api/v1/wallet");return{balance:Math.floor(t.balance/1e3)}}keysend(t){throw new Error("Method not implemented.")}lnurl(t){throw new Error("Method not implemented.")}lookupInvoice(t){throw new Error("Method not implemented.")}signMessage(t){throw new Error("Method not implemented.")}verifyMessage(t,r){throw new Error("Method not implemented.")}async requestLnbits(t,r,n){let i=null,a=new Headers;if(a.append("Accept","application/json"),a.append("Content-Type","application/json"),a.append("X-Api-Key",this._adminKey),t==="POST")i=JSON.stringify(n);else if(n!==void 0)throw new Error("TODO: support args in GET");let f=await fetch(this._instanceUrl+r+"",{method:t,headers:a,body:i});if(!f.ok){let b=await f.json();throw console.error("errBody",b),new Error(b.detail)}return await f.json()}};function Ct(){return Ct=Object.assign?Object.assign.bind():function(e){for(var t=1;t{setTimeout(r,100)})}catch(t){throw console.error(t),Ve.disconnect(),Ve.credentials.clear(),t}return e}async unload(){Ve.disconnect(),Ve.credentials.clear(),await super.unload()}}},As={showBalance:!0,appName:"Bitcoin Connect",persistConnection:!0},ne=xl((e,t)=>({route:"/start",routeHistory:[],modalOpen:!1,currency:void 0,connected:!1,connecting:!1,error:void 0,alias:void 0,balance:void 0,connectorName:void 0,invoice:void 0,provider:void 0,connector:void 0,connectorConfig:void 0,bitcoinConnectConfig:As,info:void 0,connectNWC:r=>t().connect({connectorName:"NWC",connectorType:"nwc.generic",nwcUrl:r}),connect:async(r,n={redirectTo:"/connected"})=>{e({connecting:!0,error:void 0});try{let i=new h3[r.connectorType](r),a=await i.init(),f;await a.enable();try{f=await a.getInfo()}catch{console.error("Failed to request wallet info")}if(!t().connecting)return;e({connectorConfig:r,connector:i,connected:!0,connecting:!1,info:f,provider:a,connectorName:r.connectorName,route:n.redirectTo});let{bitcoinConnectConfig:b}=t();b.persistConnection!==!1&&window.localStorage.setItem("bc:config",JSON.stringify(r))}catch(i){console.error(i),e({error:i.toString(),connecting:!1}),t().disconnect()}},disconnect:()=>{var r;(r=t().connector)==null||r.unload(),e({connectorConfig:void 0,connector:void 0,connected:!1,connecting:!1,connectorName:void 0,provider:void 0,modalOpen:!1}),window.localStorage.removeItem("bc:config")},pushRoute:r=>{t().route!==r&&e({route:r,routeHistory:[...t().routeHistory,t().route]})},popRoute(){let r=t().routeHistory,n=r.pop()||"/start";e({route:n,routeHistory:r})},clearRouteHistory(){e({route:"/start",routeHistory:[]})},setModalOpen:r=>{e({modalOpen:r})},setBitcoinConnectConfig:r=>{e({bitcoinConnectConfig:Ct({},As,r)});let n=t();n.bitcoinConnectConfig.autoConnect===!1||n.connected||n.connecting||(function(){try{let{hash:i}=window.location;if(i){let a=i.indexOf("?"),f=i.slice(a>0?a:1),b=new URLSearchParams(f),o=b.get("nwc");if(o&&o.startsWith("nostr+walletconnect://")){let{searchParams:p}=new URL(o);p.get("relay")&&p.get("secret")&&(b.delete("nwc"),window.location.hash=i.slice(0,a>0?a+1:1)+b.toString(),ne.getState().connectNWC(o))}}}catch(i){console.error(i)}})()},setError:r=>{e({error:r})},setCurrency:r=>{r?window.localStorage.setItem("bc:currency",r):window.localStorage.removeItem("bc:currency"),e({currency:r})},supports:r=>{let{info:n,provider:i}=t();return!(n==null||!n.methods)&&n.methods.indexOf(r)>-1&&!(i==null||!i.getBalance)}}));function ee(e,t,r,n){var i,a=arguments.length,f=a<3?t:n===null?n=Object.getOwnPropertyDescriptor(t,r):n;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")f=Reflect.decorate(e,t,r,n);else for(var b=e.length-1;b>=0;b--)(i=e[b])&&(f=(a<3?i(f):a>3?i(t,r,f):i(t,r))||f);return a>3&&f&&Object.defineProperty(t,r,f),f}globalThis.window&&((function(){let e=window.localStorage.getItem("bc:config");if(e){let r=JSON.parse(e);ne.getState().connect(r,{redirectTo:"/start"})}let t=window.localStorage.getItem("bc:currency");t&&ne.getState().setCurrency(t)})(),window.addEventListener("webln:enabled",()=>{ne.getState().connecting||ne.getState().connect({connectorName:"Extension",connectorType:"extension.generic"},{redirectTo:"/start"})})),typeof SuppressedError=="function"&&SuppressedError;var po=globalThis,Xs=po.ShadowRoot&&(po.ShadyCSS===void 0||po.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,Sh=Symbol(),$l=new WeakMap,Ss=class{constructor(t,r,n){if(this._$cssResult$=!0,n!==Sh)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=r}get styleSheet(){let t=this.o,r=this.t;if(Xs&&t===void 0){let n=r!==void 0&&r.length===1;n&&(t=$l.get(r)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),n&&$l.set(r,t))}return t}toString(){return this.cssText}},Gl=Xs?e=>e:e=>e instanceof CSSStyleSheet?(t=>{let r="";for(let n of t.cssRules)r+=n.cssText;return(n=>new Ss(typeof n=="string"?n:n+"",void 0,Sh))(r)})(e):e,{is:f3,defineProperty:d3,getOwnPropertyDescriptor:p3,getOwnPropertyNames:y3,getOwnPropertySymbols:g3,getPrototypeOf:b3}=Object,Qt=globalThis,Wl=Qt.trustedTypes,w3=Wl?Wl.emptyScript:"",m3=Qt.reactiveElementPolyfillSupport,or=(e,t)=>e,bo={toAttribute(e,t){switch(t){case Boolean:e=e?w3:null;break;case Object:case Array:e=e==null?e:JSON.stringify(e)}return e},fromAttribute(e,t){let r=e;switch(t){case Boolean:r=e!==null;break;case Number:r=e===null?null:Number(e);break;case Object:case Array:try{r=JSON.parse(e)}catch{r=null}}return r}},ea=(e,t)=>!f3(e,t),Kl={attribute:!0,type:String,converter:bo,reflect:!1,useDefault:!1,hasChanged:ea};Symbol.metadata??(Symbol.metadata=Symbol("metadata")),Qt.litPropertyMetadata??(Qt.litPropertyMetadata=new WeakMap);var hn=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??(this.l=[])).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,r=Kl){if(r.state&&(r.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((r=Object.create(r)).wrapped=!0),this.elementProperties.set(t,r),!r.noAccessor){let n=Symbol(),i=this.getPropertyDescriptor(t,n,r);i!==void 0&&d3(this.prototype,t,i)}}static getPropertyDescriptor(t,r,n){let{get:i,set:a}=p3(this.prototype,t)??{get(){return this[r]},set(f){this[r]=f}};return{get:i,set(f){let b=i?.call(this);a?.call(this,f),this.requestUpdate(t,b,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??Kl}static _$Ei(){if(this.hasOwnProperty(or("elementProperties")))return;let t=b3(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(or("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(or("properties"))){let r=this.properties,n=[...y3(r),...g3(r)];for(let i of n)this.createProperty(i,r[i])}let t=this[Symbol.metadata];if(t!==null){let r=litPropertyMetadata.get(t);if(r!==void 0)for(let[n,i]of r)this.elementProperties.set(n,i)}this._$Eh=new Map;for(let[r,n]of this.elementProperties){let i=this._$Eu(r,n);i!==void 0&&this._$Eh.set(i,r)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let r=[];if(Array.isArray(t)){let n=new Set(t.flat(1/0).reverse());for(let i of n)r.unshift(Gl(i))}else t!==void 0&&r.push(Gl(t));return r}static _$Eu(t,r){let n=r.attribute;return n===!1?void 0:typeof n=="string"?n:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??(this._$EO=new Set)).add(t),this.renderRoot!==void 0&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){let t=new Map,r=this.constructor.elementProperties;for(let n of r.keys())this.hasOwnProperty(n)&&(t.set(n,this[n]),delete this[n]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((r,n)=>{if(Xs)r.adoptedStyleSheets=n.map(i=>i instanceof CSSStyleSheet?i:i.styleSheet);else for(let i of n){let a=document.createElement("style"),f=po.litNonce;f!==void 0&&a.setAttribute("nonce",f),a.textContent=i.cssText,r.appendChild(a)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,r,n){this._$AK(t,n)}_$ET(t,r){let n=this.constructor.elementProperties.get(t),i=this.constructor._$Eu(t,n);if(i!==void 0&&n.reflect===!0){let a=(n.converter?.toAttribute!==void 0?n.converter:bo).toAttribute(r,n.type);this._$Em=t,a==null?this.removeAttribute(i):this.setAttribute(i,a),this._$Em=null}}_$AK(t,r){let n=this.constructor,i=n._$Eh.get(t);if(i!==void 0&&this._$Em!==i){let a=n.getPropertyOptions(i),f=typeof a.converter=="function"?{fromAttribute:a.converter}:a.converter?.fromAttribute!==void 0?a.converter:bo;this._$Em=i,this[i]=f.fromAttribute(r,a.type)??this._$Ej?.get(i)??null,this._$Em=null}}requestUpdate(t,r,n){if(t!==void 0){let i=this.constructor,a=this[t];if(n??(n=i.getPropertyOptions(t)),!((n.hasChanged??ea)(a,r)||n.useDefault&&n.reflect&&a===this._$Ej?.get(t)&&!this.hasAttribute(i._$Eu(t,n))))return;this.C(t,r,n)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(t,r,{useDefault:n,reflect:i,wrapped:a},f){n&&!(this._$Ej??(this._$Ej=new Map)).has(t)&&(this._$Ej.set(t,f??r??this[t]),a!==!0||f!==void 0)||(this._$AL.has(t)||(this.hasUpdated||n||(r=void 0),this._$AL.set(t,r)),i===!0&&this._$Em!==t&&(this._$Eq??(this._$Eq=new Set)).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(r){Promise.reject(r)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??(this.renderRoot=this.createRenderRoot()),this._$Ep){for(let[i,a]of this._$Ep)this[i]=a;this._$Ep=void 0}let n=this.constructor.elementProperties;if(n.size>0)for(let[i,a]of n){let{wrapped:f}=a,b=this[i];f!==!0||this._$AL.has(i)||b===void 0||this.C(i,void 0,a,b)}}let t=!1,r=this._$AL;try{t=this.shouldUpdate(r),t?(this.willUpdate(r),this._$EO?.forEach(n=>n.hostUpdate?.()),this.update(r)):this._$EM()}catch(n){throw t=!1,this._$EM(),n}t&&this._$AE(r)}willUpdate(t){}_$AE(t){this._$EO?.forEach(r=>r.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&(this._$Eq=this._$Eq.forEach(r=>this._$ET(r,this[r]))),this._$EM()}updated(t){}firstUpdated(t){}};hn.elementStyles=[],hn.shadowRootOptions={mode:"open"},hn[or("elementProperties")]=new Map,hn[or("finalized")]=new Map,m3?.({ReactiveElement:hn}),(Qt.reactiveElementVersions??(Qt.reactiveElementVersions=[])).push("2.1.0");var ir=globalThis,wo=ir.trustedTypes,Vl=wo?wo.createPolicy("lit-html",{createHTML:e=>e}):void 0,Zl="$lit$",Kt=`lit$${Math.random().toFixed(9).slice(2)}$`,Th="?"+Kt,v3=`<${Th}>`,yn=document,mo=()=>yn.createComment(""),ur=e=>e===null||typeof e!="object"&&typeof e!="function",Ts=Array.isArray,Ji=`[
+\f\r]`,Jn=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Yl=/-->/g,ql=/>/g,an=RegExp(`>|${Ji}(?:([^\\s"'>=/]+)(${Ji}*=${Ji}*(?:[^
+\f\r"'\`<>=]|("|')|))|$)`,"g"),zl=/'/g,Ql=/"/g,Jl=/^(?:script|style|textarea|title)$/i,hr=Symbol.for("lit-noChange"),He=Symbol.for("lit-nothing"),Xl=new WeakMap,dn=yn.createTreeWalker(yn,129);function Oh(e,t){if(!Ts(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return Vl!==void 0?Vl.createHTML(t):t}var fr=class e{constructor({strings:t,_$litType$:r},n){let i;this.parts=[];let a=0,f=0,b=t.length-1,o=this.parts,[p,d]=((h,u)=>{let c=h.length-1,s=[],l,g=u===2?"":u===3?"":"",w=Jn;for(let y=0;y"?(w=l??Jn,E=-1):C[1]===void 0?E=-2:(E=w.lastIndex-C[2].length,m=C[1],w=C[3]===void 0?an:C[3]==='"'?Ql:zl):w===Ql||w===zl?w=an:w===Yl||w===ql?w=Jn:(w=an,l=void 0);let _=w===an&&h[y+1].startsWith("/>")?" ":"";g+=w===Jn?v+v3:E>=0?(s.push(m),v.slice(0,E)+Zl+v.slice(E)+Kt+_):v+Kt+(E===-2?y:_)}return[Oh(h,g+(h[c]||">")+(u===2?" ":u===3?"":"")),s]})(t,r);if(this.el=e.createElement(p,n),dn.currentNode=this.el.content,r===2||r===3){let h=this.el.content.firstChild;h.replaceWith(...h.childNodes)}for(;(i=dn.nextNode())!==null&&o.length0){i.textContent=wo?wo.emptyScript:"";for(let c=0;cTs(n)||typeof n?.[Symbol.iterator]=="function")(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==He&&ur(this._$AH)?this._$AA.nextSibling.data=t:this.T(yn.createTextNode(t)),this._$AH=t}$(t){let{values:r,_$litType$:n}=t,i=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=fr.createElement(Oh(n.h,n.h[0]),this.options)),n);if(this._$AH?._$AD===i)this._$AH.p(r);else{let a=new Os(i,this),f=a.u(this.options);a.p(r),this.T(f),this._$AH=a}}_$AC(t){let r=Xl.get(t.strings);return r===void 0&&Xl.set(t.strings,r=new fr(t)),r}k(t){Ts(this._$AH)||(this._$AH=[],this._$AR());let r=this._$AH,n,i=0;for(let a of t)i===r.length?r.push(n=new e(this.O(mo()),this.O(mo()),this,this.options)):n=r[i],n._$AI(a),i++;i2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=He}_$AI(t,r=this,n,i){let a=this.strings,f=!1;if(a===void 0)t=kn(this,t,r,0),f=!ur(t)||t!==this._$AH&&t!==hr,f&&(this._$AH=t);else{let b=t,o,p;for(t=a[0],o=0;o{let r=e.length===1?e[0]:t.reduce((n,i,a)=>n+(f=>{if(f._$cssResult$===!0)return f.cssText;if(typeof f=="number")return f;throw Error("Value passed to 'css' function must be a 'css' function result: "+f+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(i)+e[a+1],e[0]);return new Eo(r,e,na)},t1=ta?e=>e:e=>e instanceof CSSStyleSheet?(t=>{let r="";for(let n of t.cssRules)r+=n.cssText;return(n=>new Eo(typeof n=="string"?n:n+"",void 0,na))(r)})(e):e,{is:_3,defineProperty:C3,getOwnPropertyDescriptor:A3,getOwnPropertyNames:S3,getOwnPropertySymbols:T3,getPrototypeOf:O3}=Object,Jt=globalThis,n1=Jt.trustedTypes,N3=n1?n1.emptyScript:"",x3=Jt.reactiveElementPolyfillSupport,sr=(e,t)=>e,Ps={toAttribute(e,t){switch(t){case Boolean:e=e?N3:null;break;case Object:case Array:e=e==null?e:JSON.stringify(e)}return e},fromAttribute(e,t){let r=e;switch(t){case Boolean:r=e!==null;break;case Number:r=e===null?null:Number(e);break;case Object:case Array:try{r=JSON.parse(e)}catch{r=null}}return r}},Nh=(e,t)=>!_3(e,t),r1={attribute:!0,type:String,converter:Ps,reflect:!1,useDefault:!1,hasChanged:Nh};Symbol.metadata??(Symbol.metadata=Symbol("metadata")),Jt.litPropertyMetadata??(Jt.litPropertyMetadata=new WeakMap);var Zt=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??(this.l=[])).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,r=r1){if(r.state&&(r.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((r=Object.create(r)).wrapped=!0),this.elementProperties.set(t,r),!r.noAccessor){let n=Symbol(),i=this.getPropertyDescriptor(t,n,r);i!==void 0&&C3(this.prototype,t,i)}}static getPropertyDescriptor(t,r,n){let{get:i,set:a}=A3(this.prototype,t)??{get(){return this[r]},set(f){this[r]=f}};return{get:i,set(f){let b=i?.call(this);a?.call(this,f),this.requestUpdate(t,b,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??r1}static _$Ei(){if(this.hasOwnProperty(sr("elementProperties")))return;let t=O3(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(sr("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(sr("properties"))){let r=this.properties,n=[...S3(r),...T3(r)];for(let i of n)this.createProperty(i,r[i])}let t=this[Symbol.metadata];if(t!==null){let r=litPropertyMetadata.get(t);if(r!==void 0)for(let[n,i]of r)this.elementProperties.set(n,i)}this._$Eh=new Map;for(let[r,n]of this.elementProperties){let i=this._$Eu(r,n);i!==void 0&&this._$Eh.set(i,r)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){let r=[];if(Array.isArray(t)){let n=new Set(t.flat(1/0).reverse());for(let i of n)r.unshift(t1(i))}else t!==void 0&&r.push(t1(t));return r}static _$Eu(t,r){let n=r.attribute;return n===!1?void 0:typeof n=="string"?n:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??(this._$EO=new Set)).add(t),this.renderRoot!==void 0&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){let t=new Map,r=this.constructor.elementProperties;for(let n of r.keys())this.hasOwnProperty(n)&&(t.set(n,this[n]),delete this[n]);t.size>0&&(this._$Ep=t)}createRenderRoot(){let t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((r,n)=>{if(ta)r.adoptedStyleSheets=n.map(i=>i instanceof CSSStyleSheet?i:i.styleSheet);else for(let i of n){let a=document.createElement("style"),f=yo.litNonce;f!==void 0&&a.setAttribute("nonce",f),a.textContent=i.cssText,r.appendChild(a)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,r,n){this._$AK(t,n)}_$ET(t,r){let n=this.constructor.elementProperties.get(t),i=this.constructor._$Eu(t,n);if(i!==void 0&&n.reflect===!0){let a=(n.converter?.toAttribute!==void 0?n.converter:Ps).toAttribute(r,n.type);this._$Em=t,a==null?this.removeAttribute(i):this.setAttribute(i,a),this._$Em=null}}_$AK(t,r){let n=this.constructor,i=n._$Eh.get(t);if(i!==void 0&&this._$Em!==i){let a=n.getPropertyOptions(i),f=typeof a.converter=="function"?{fromAttribute:a.converter}:a.converter?.fromAttribute!==void 0?a.converter:Ps;this._$Em=i,this[i]=f.fromAttribute(r,a.type)??this._$Ej?.get(i)??null,this._$Em=null}}requestUpdate(t,r,n){if(t!==void 0){let i=this.constructor,a=this[t];if(n??(n=i.getPropertyOptions(t)),!((n.hasChanged??Nh)(a,r)||n.useDefault&&n.reflect&&a===this._$Ej?.get(t)&&!this.hasAttribute(i._$Eu(t,n))))return;this.C(t,r,n)}this.isUpdatePending===!1&&(this._$ES=this._$EP())}C(t,r,{useDefault:n,reflect:i,wrapped:a},f){n&&!(this._$Ej??(this._$Ej=new Map)).has(t)&&(this._$Ej.set(t,f??r??this[t]),a!==!0||f!==void 0)||(this._$AL.has(t)||(this.hasUpdated||n||(r=void 0),this._$AL.set(t,r)),i===!0&&this._$Em!==t&&(this._$Eq??(this._$Eq=new Set)).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(r){Promise.reject(r)}let t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??(this.renderRoot=this.createRenderRoot()),this._$Ep){for(let[i,a]of this._$Ep)this[i]=a;this._$Ep=void 0}let n=this.constructor.elementProperties;if(n.size>0)for(let[i,a]of n){let{wrapped:f}=a,b=this[i];f!==!0||this._$AL.has(i)||b===void 0||this.C(i,void 0,a,b)}}let t=!1,r=this._$AL;try{t=this.shouldUpdate(r),t?(this.willUpdate(r),this._$EO?.forEach(n=>n.hostUpdate?.()),this.update(r)):this._$EM()}catch(n){throw t=!1,this._$EM(),n}t&&this._$AE(r)}willUpdate(t){}_$AE(t){this._$EO?.forEach(r=>r.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&(this._$Eq=this._$Eq.forEach(r=>this._$ET(r,this[r]))),this._$EM()}updated(t){}firstUpdated(t){}};Zt.elementStyles=[],Zt.shadowRootOptions={mode:"open"},Zt[sr("elementProperties")]=new Map,Zt[sr("finalized")]=new Map,x3?.({ReactiveElement:Zt}),(Jt.reactiveElementVersions??(Jt.reactiveElementVersions=[])).push("2.1.0");var ar=globalThis,_o=ar.trustedTypes,o1=_o?_o.createPolicy("lit-html",{createHTML:e=>e}):void 0,xh="$lit$",Yt=`lit$${Math.random().toFixed(9).slice(2)}$`,Rh="?"+Yt,R3=`<${Rh}>`,gn=document,dr=()=>gn.createComment(""),pr=e=>e===null||typeof e!="object"&&typeof e!="function",ks=Array.isArray,Xi=`[
+\f\r]`,Xn=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,i1=/-->/g,s1=/>/g,cn=RegExp(`>|${Xi}(?:([^\\s"'>=/]+)(${Xi}*=${Xi}*(?:[^
+\f\r"'\`<>=]|("|')|))|$)`,"g"),a1=/'/g,c1=/"/g,Ih=/^(?:script|style|textarea|title)$/i,Ph=e=>(t,...r)=>({_$litType$:e,strings:t,values:r}),X=Ph(1),Ee=Ph(2),Un=Symbol.for("lit-noChange"),$e=Symbol.for("lit-nothing"),l1=new WeakMap,pn=gn.createTreeWalker(gn,129);function kh(e,t){if(!ks(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return o1!==void 0?o1.createHTML(t):t}var I3=(e,t)=>{let r=e.length-1,n=[],i,a=t===2?"":t===3?"":"",f=Xn;for(let b=0;b"?(f=i??Xn,h=-1):d[1]===void 0?h=-2:(h=f.lastIndex-d[2].length,p=d[1],f=d[3]===void 0?cn:d[3]==='"'?c1:a1):f===c1||f===a1?f=cn:f===i1||f===s1?f=Xn:(f=cn,i=void 0);let c=f===cn&&e[b+1].startsWith("/>")?" ":"";a+=f===Xn?o+R3:h>=0?(n.push(p),o.slice(0,h)+xh+o.slice(h)+Yt+c):o+Yt+(h===-2?b:c)}return[kh(e,a+(e[r]||">")+(t===2?" ":t===3?"":"")),n]},yr=class e{constructor({strings:t,_$litType$:r},n){let i;this.parts=[];let a=0,f=0,b=t.length-1,o=this.parts,[p,d]=I3(t,r);if(this.el=e.createElement(p,n),pn.currentNode=this.el.content,r===2||r===3){let h=this.el.content.firstChild;h.replaceWith(...h.childNodes)}for(;(i=pn.nextNode())!==null&&o.length0){i.textContent=_o?_o.emptyScript:"";for(let c=0;cks(n)||typeof n?.[Symbol.iterator]=="function")(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==$e&&pr(this._$AH)?this._$AA.nextSibling.data=t:this.T(gn.createTextNode(t)),this._$AH=t}$(t){let{values:r,_$litType$:n}=t,i=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=yr.createElement(kh(n.h,n.h[0]),this.options)),n);if(this._$AH?._$AD===i)this._$AH.p(r);else{let a=new Ls(i,this),f=a.u(this.options);a.p(r),this.T(f),this._$AH=a}}_$AC(t){let r=l1.get(t.strings);return r===void 0&&l1.set(t.strings,r=new yr(t)),r}k(t){ks(this._$AH)||(this._$AH=[],this._$AR());let r=this._$AH,n,i=0;for(let a of t)i===r.length?r.push(n=new e(this.O(dr()),this.O(dr()),this,this.options)):n=r[i],n._$AI(a),i++;i2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=$e}_$AI(t,r=this,n,i){let a=this.strings,f=!1;if(a===void 0)t=Mn(this,t,r,0),f=!pr(t)||t!==this._$AH&&t!==Un,f&&(this._$AH=t);else{let b=t,o,p;for(t=a[0],o=0;o{let f=a?.renderBefore??i,b=f._$litPart$;if(b===void 0){let o=a?.renderBefore??null;f._$litPart$=b=new gr(i.insertBefore(dr(),o),o,void 0,a??{})}return b._$AI(n),b})(r,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return Un}};Xt._$litElement$=!0,Xt.finalized=!0,cr.litElementHydrateSupport?.({LitElement:Xt});var k3=cr.litElementPolyfillSupport;k3?.({LitElement:Xt}),(cr.litElementVersions??(cr.litElementVersions=[])).push("4.2.0");var pe=e=>(t,r)=>{r!==void 0?r.addInitializer(()=>{customElements.define(e,t)}):customElements.define(e,t)},L3={attribute:!0,type:String,converter:bo,reflect:!1,hasChanged:ea},U3=(e=L3,t,r)=>{let{kind:n,metadata:i}=r,a=globalThis.litPropertyMetadata.get(i);if(a===void 0&&globalThis.litPropertyMetadata.set(i,a=new Map),n==="setter"&&((e=Object.create(e)).wrapped=!0),a.set(r.name,e),n==="accessor"){let{name:f}=r;return{set(b){let o=t.get.call(this);t.set.call(this,b),this.requestUpdate(f,o,e)},init(b){return b!==void 0&&this.C(f,void 0,e,b),b}}}if(n==="setter"){let{name:f}=r;return function(b){let o=this[f];t.call(this,b),this.requestUpdate(f,o,e)}}throw Error("Unsupported decorator location: "+n)};function Ue(e){return(t,r)=>typeof r=="object"?U3(e,t,r):((n,i,a)=>{let f=i.hasOwnProperty(a);return i.constructor.createProperty(a,n),f?Object.getOwnPropertyDescriptor(i,a):void 0})(e,t,r)}function ge(e){return Ue({...e,state:!0,attribute:!1})}var u1,h1,br=class extends Xt{updated(t){var r;if(super.updated(t),globalThis.document&&globalThis.document.documentElement.classList.contains("dark")&&(r=this.shadowRoot)!=null&&(r=r.children)!=null&&r.length)for(let n of this.shadowRoot.children)n.classList.contains("dark")||n.classList.add("dark")}_getBrandColorLuminance(){if(!globalThis.window)return 0;let t=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,r=window.getComputedStyle(this).getPropertyValue(t?"--bc-color-brand-dark":"--bc-color-brand")||window.getComputedStyle(this).getPropertyValue("--bc-color-brand")||"#196CE7";if(!r.match(/^#[0-9A-F]{6}$/i)){let n=document.createElement("div");n.style.color=r,n.style.display="none",document.body.appendChild(n),r=window.getComputedStyle(n).color,n.remove()}return(function(n){if(n.startsWith("#"))return n=n.slice(1),(.299*parseInt(n.slice(0,2),16)+.587*parseInt(n.slice(2,4),16)+.114*parseInt(n.slice(4,6),16))/255;if(n.startsWith("rgb")||n.startsWith("rgba")){let i=n.match(/\d+(\.\d+)?/g);return(.299*parseFloat(i[0])+.587*parseFloat(i[1])+.114*parseFloat(i[2]))/255}throw new Error("Unsupported luminance: "+n)})(r)}};br.styles=[Oo(u1||(u1=(e=>e)`
+ :host {
+ // global css reset in shadow DOM
+ all: initial;
+ font-variant-numeric: slashed-zero;
+ }
+ // TODO: move to individual components - only needed by a couple of icons
+ .hover-animation:hover .hover-right-up {
+ transform: translateX(2px) translateY(-2px);
+ transition: all 0.3s;
+ }
+ .hover-animation:hover .hover-right {
+ transform: translateX(3px);
+ transition: all 0.3s;
+ }
+ `))];var ye=class extends br{constructor(){super(),this._modalOpen=!1,this._connected=!1,this._connecting=!1,this._connectorName=void 0,this._appName=void 0,this._appIcon=void 0,this._filters=void 0,this._error=void 0,this._connected=ne.getState().connected,this._connecting=ne.getState().connecting,this._connectorName=ne.getState().connectorName,this._appName=ne.getState().bitcoinConnectConfig.appName,this._appIcon=ne.getState().bitcoinConnectConfig.appIcon,this._filters=ne.getState().bitcoinConnectConfig.filters,this._error=ne.getState().error,this._route=ne.getState().route,this._modalOpen=ne.getState().modalOpen,ne.subscribe(t=>{this._connected=t.connected,this._connecting=t.connecting,this._connectorName=t.connectorName,this._appName=t.bitcoinConnectConfig.appName,this._appIcon=t.bitcoinConnectConfig.appIcon,this._filters=t.bitcoinConnectConfig.filters,this._error=t.error,this._route=t.route,this._modalOpen=t.modalOpen})}};ee([ge()],ye.prototype,"_modalOpen",void 0),ee([ge()],ye.prototype,"_connected",void 0),ee([ge()],ye.prototype,"_connecting",void 0),ee([ge()],ye.prototype,"_connectorName",void 0),ee([ge()],ye.prototype,"_appName",void 0),ee([ge()],ye.prototype,"_appIcon",void 0),ee([ge()],ye.prototype,"_filters",void 0),ee([ge()],ye.prototype,"_error",void 0),ee([ge()],ye.prototype,"_route",void 0);var lr=Ee(h1||(h1=(e=>e)`
+
+
+ `));function ra(e){return[...e.v,(e.i?"!":"")+e.n].join(":")}function M3(e,t=","){return e.map(ra).join(t)}var Lh=typeof CSS<"u"&&CSS.escape||(e=>e.replace(/[!"'`*+.,;:\\/<=>?@#$%&^|~()[\]{}]/g,"\\$&").replace(/^\d/,"\\3$& "));function Co(e){for(var t=9,r=e.length;r--;)t=Math.imul(t^e.charCodeAt(r),1597334677);return"#"+((t^t>>>9)>>>0).toString(36)}function oa(e,t="@media "){return t+Re(e).map(r=>(typeof r=="string"&&(r={min:r}),r.raw||Object.keys(r).map(n=>`(${n}-width:${r[n]})`).join(" and "))).join(",")}function Re(e=[]){return Array.isArray(e)?e:e==null?[]:[e]}function f1(e){return e}function Fs(){}var Me={d:0,b:134217728,c:268435456,a:671088640,u:805306368,o:939524096};function Uh(e){return e.match(/[-=:;]/g)?.length||0}function js(e){return Math.min(/(?:^|width[^\d]+)(\d+(?:.\d+)?)(p)?/.test(e)?Math.max(0,29.63*(+RegExp.$1/(RegExp.$2?15:1))**.137-43):0,15)<<22|Math.min(Uh(e),15)<<18}var D3=["rst-c","st-ch","h-chi","y-lin","nk","sited","ecked","pty","ad-on","cus-w","ver","cus","cus-v","tive","sable","tiona","quire"];function ia({n:e,i:t,v:r=[]},n,i,a){e&&(e=ra({n:e,i:t,v:r})),a=[...Re(a)];for(let f of r){let b=n.theme("screens",f);for(let o of Re(b&&oa(b)||n.v(f)))a.push(o),i|=b?67108864|js(o):f=="dark"?1073741824:o[0]=="@"?js(o):1<<~(/:([a-z-]+)/.test(o)&&~D3.indexOf(RegExp.$1.slice(2,7))||-18)}return{n:e,p:i,r:a,i:t}}var Mh=new Map;function Hs(e){if(e.d){let t=[],r=es(e.r.reduce((n,i)=>i[0]=="@"?(t.push(i),n):i?es(n,a=>es(i,f=>{let b=/(:merge\(.+?\))(:[a-z-]+|\\[.+])/.exec(f);if(b){let o=a.indexOf(b[1]);return~o?a.slice(0,o)+b[0]+a.slice(o+b[1].length):ts(a,f)}return ts(f,a)})):n,"&"),n=>ts(n,e.n?"."+Lh(e.n):""));return r&&t.push(r.replace(/:merge\((.+?)\)/g,"$1")),t.reduceRight((n,i)=>i+"{"+n+"}",e.d)}}function es(e,t){return e.replace(/ *((?:\(.+?\)|\[.+?\]|[^,])+) *(,|$)/g,(r,n,i)=>t(n)+i)}function ts(e,t){return e.replace(/&/g,t)}var d1=new Intl.Collator("en",{numeric:!0});function Dh(e,t){for(var r=0,n=e.length;r>1;0>=Bh(e[i],t)?r=i+1:n=i}return n}function Bh(e,t){let r=e.p&Me.o;return r!=(t.p&Me.o)||r!=Me.b&&r!=Me.o?e.p-t.p||e.o-t.o||d1.compare(p1(e.n),p1(t.n))||d1.compare(y1(e.n),y1(t.n)):0}function p1(e){return(e||"").split(/:/).pop().split("/").pop()||"\0"}function y1(e){return(e||"").replace(/\W/g,t=>String.fromCharCode(127+t.charCodeAt(0)))+"\0"}function ns(e,t){return Math.round(parseInt(e,16)*t)}function qt(e,t={}){if(typeof e=="function")return e(t);let{opacityValue:r="1",opacityVariable:n}=t,i=n?`var(${n})`:r;if(e.includes(""))return e.replace("",i);if(e[0]=="#"&&(e.length==4||e.length==7)){let a=(e.length-1)/3,f=[17,1,.062272][a-1];return`rgba(${[ns(e.substr(1,a),f),ns(e.substr(1+a,a),f),ns(e.substr(1+2*a,a),f),i]})`}return i=="1"?e:i=="0"?"#0000":e.replace(/^(rgb|hsl)(\([^)]+)\)$/,`$1a$2,${i})`)}function Fh(e,t,r,n,i=[]){return(function a(f,{n:b,p:o,r:p=[],i:d},h){let u=[],c="",s=0,l=0;for(let y in f||{}){var g,w;let v=f[y];if(y[0]=="@"){if(!v)continue;if(y[1]=="a"){u.push(...aa(b,o,So(""+v),h,o,p,d,!0));continue}if(y[1]=="l"){for(let m of Re(v))u.push(...a(m,{n:b,p:(g=Me[y[7]],o&~Me.o|g),r:y[7]=="d"?[]:p,i:d},h));continue}if(y[1]=="i"){u.push(...Re(v).map(m=>({p:-1,o:0,r:[],d:y+" "+m})));continue}if(y[1]=="k"){u.push({p:Me.d,o:0,r:[y],d:a(v,{p:Me.d},h).map(Hs).join("")});continue}if(y[1]=="f"){u.push(...Re(v).map(m=>({p:Me.d,o:0,r:[y],d:a(m,{p:Me.d},h).map(Hs).join("")})));continue}}if(typeof v!="object"||Array.isArray(v))y=="label"&&v?b=v+Co(JSON.stringify([o,d,f])):(v||v===0)&&(y=y.replace(/[A-Z]/g,m=>"-"+m.toLowerCase()),l+=1,s=Math.max(s,(w=y)[0]=="-"?0:Uh(w)+(/^(?:(border-(?!w|c|sty)|[tlbr].{2,4}m?$|c.{7,8}$)|([fl].{5}l|g.{8}$|pl))/.test(w)?+!!RegExp.$1||-!!RegExp.$2:0)+1),c+=(c?";":"")+Re(v).map(m=>h.s(y,sa(""+m,h.theme)+(d?" !important":""))).join(";"));else if(y[0]=="@"||y.includes("&")){let m=o;y[0]=="@"&&(y=y.replace(/\bscreen\(([^)]+)\)/g,(C,E)=>{let O=h.theme("screens",E);return O?(m|=67108864,oa(O,"")):C}),m|=js(y)),u.push(...a(v,{n:b,p:m,r:[...p,y],i:d},h))}else u.push(...a(v,{p:o,r:[...p,y]},h))}return u.unshift({n:b,p:o,o:Math.max(0,15-l)+1.5*Math.min(s||15,15),r:p,d:c}),u.sort(Bh)})(e,ia(t,r,n,i),r)}function sa(e,t){return e.replace(/theme\((["'`])?(.+?)\1(?:\s*,\s*(["'`])?(.+?)\3)?\)/g,(r,n,i,a,f="")=>{let b=t(i,f);return typeof b=="function"&&/color|fill|stroke/i.test(i)?qt(b):""+Re(b).filter(o=>Object(o)!==o)})}function jh(e,t){let r,n=[];for(let i of e)i.d&&i.n?r?.p==i.p&&""+r.r==""+i.r?(r.c=[r.c,i.c].filter(Boolean).join(" "),r.d=r.d+";"+i.d):n.push(r={...i,n:i.n&&t}):n.push({...i,n:i.n&&t});return n}function Ao(e,t,r=Me.u,n,i){let a=[];for(let f of e)for(let b of(function(o,p,d,h,u){let c=(function(s,l){let g=Mh.get(s.n);return g?g(s,l):l.r(s.n,s.v[0]=="dark")})(o={...o,i:o.i||u},p);return c?typeof c=="string"?({r:h,p:d}=ia(o,p,d,h),jh(Ao(So(c),p,d,h,o.i),o.n)):Array.isArray(c)?c.map(s=>{var l,g;return{o:0,...s,r:[...Re(h),...Re(s.r)],p:(l=d,g=s.p??d,l&~Me.o|g)}}):Fh(c,o,p,d,h):[{c:ra(o),p:0,o:0,r:[]}]})(f,t,r,n,i))a.splice(Dh(a,b),0,b);return a}function aa(e,t,r,n,i,a,f,b){return jh((b?r.flatMap(o=>Ao([o],n,i,a,f)):Ao(r,n,i,a,f)).map(o=>o.p&Me.o&&(o.n||t==Me.b)?{...o,p:o.p&~Me.o|t,o:0}:o),e)}function B3(e,t,r,n){return Mh.set(e,(i,a)=>{let{n:f,p:b,r:o,i:p}=ia(i,a,t);return r&&aa(f,t,r,a,b,o,p,n)}),e}function rs(e,t,r){if(e[e.length-1]!="("){let n=[],i=!1,a=!1,f="";for(let b of e)if(b!="("&&!/[~@]$/.test(b)){if(b[0]=="!"&&(b=b.slice(1),i=!i),b.endsWith(":")){n[b=="dark:"?"unshift":"push"](b.slice(0,-1));continue}b[0]=="-"&&(b=b.slice(1),a=!a),b.endsWith("-")&&(b=b.slice(0,-1)),b&&b!="&"&&(f+=(f&&"-")+b)}f&&(a&&(f="-"+f),t[0].push({n:f,v:n.filter(F3),i}))}}function F3(e,t,r){return r.indexOf(e)==t}var g1=new Map;function So(e){let t=g1.get(e);if(!t){let r=[],n=[[]],i=0,a=0,f=null,b=0,o=(p,d=0)=>{i!=b&&(r.push(e.slice(i,b+d)),p&&rs(r,n)),i=b+1};for(;b1?h.slice(0,-1)+Co(JSON.stringify([h,u])):h+"("+M3(u)+")",Me.a,u,/@$/.test(h))],n)}d=r.lastIndexOf("(",d-1)}r.length=d+1}else/[~@]/.test(p)&&e[b+1]=="("&&n.unshift([]);else f=e[b+1]=="*"?/^\*\//:/^[\r\n]/}o(!0),g1.set(e,t=n[0])}return t}function re(e,t,r){return[e,$s(t,r)]}function $s(e,t){return typeof e=="function"?e:typeof e=="string"&&/^[\w-]+$/.test(e)?(r,n)=>({[e]:t?t(r,n):Gs(r,1)}):r=>e||{[r[1]]:Gs(r,2)}}function Gs(e,t,r=e.slice(t).find(Boolean)||e.$$||e.input){return e.input[0]=="-"?`calc(${r} * -1)`:r}function oe(e,t,r,n){return[e,j3(t,r,n)]}function j3(e,t,r){let n=typeof t=="string"?(i,a)=>({[t]:r?r(i,a):i._}):t||(({1:i,_:a},f,b)=>({[i||b]:a}));return(i,a)=>{let f=Hh(e||i[1]),b=a.theme(f,i.$$)??zt(i.$$,f,a);if(b!=null)return i._=Gs(i,0,b),n(i,a,f)}}function Fe(e,t={},r){return[e,H3(t,r)]}function H3(e={},t){return(r,n)=>{let{section:i=Hh(r[0]).replace("-","")+"Color"}=e,[a,f]=(r.$$.match(/^(\[[^\]]+]|[^/]+?)(?:\/(.+))?$/)||[]).slice(1);if(!a)return;let b=n.theme(i,a)||zt(a,i,n);if(!b||typeof b=="object")return;let{opacityVariable:o=`--tw-${r[0].replace(/-$/,"")}-opacity`,opacitySection:p=i.replace("Color","Opacity"),property:d=i,selector:h}=e,u=n.theme(p,f||"DEFAULT")||f&&zt(f,p,n),c=t||(({_:l})=>{let g=go(d,l);return h?{[h]:g}:g});r._={value:qt(b,{opacityVariable:o||void 0,opacityValue:u||void 0}),color:l=>qt(b,l),opacityVariable:o||void 0,opacityValue:u||void 0};let s=c(r,n);if(!r.dark){let l=n.d(i,a,b);l&&l!==b&&(r._={value:qt(l,{opacityVariable:o||void 0,opacityValue:u||"1"}),color:g=>qt(l,g),opacityVariable:o||void 0,opacityValue:u||void 0},s={"&":s,[n.v("dark")]:c(r,n)})}return s}}function go(e,t){let r={};return typeof t=="string"?r[e]=t:(t.opacityVariable&&t.value.includes(t.opacityVariable)&&(r[t.opacityVariable]=t.opacityValue||"1"),r[e]=t.value),r}function zt(e,t,r){if(e[0]=="["&&e.slice(-1)=="]"){if(e=wr(sa(e.slice(1,-1),r.theme)),!t)return e;if(!(/color|fill|stroke/i.test(t)&&!/^color:/.test(e)&&!/^(#|((hsl|rgb)a?|hwb|lab|lch|color)\(|[a-z]+$)/.test(e)||/image/i.test(t)&&!/^image:/.test(e)&&!/^[a-z-]+\(/.test(e)||/weight/i.test(t)&&!/^(number|any):/.test(e)&&!/^\d+$/.test(e)||/position/i.test(t)&&/^(length|size):/.test(e)))return e.replace(/^[a-z-]+:/,"")}}function Hh(e){return e.replace(/-./g,t=>t[1].toUpperCase())}function wr(e){return e.includes("url(")?e.replace(/(.*?)(url\(.*?\))(.*?)/g,(t,r="",n,i="")=>wr(r)+n+wr(i)):e.replace(/(^|[^\\])_+/g,(t,r)=>r+" ".repeat(t.length-r.length)).replace(/\\_/g,"_").replace(/(calc|min|max|clamp)\(.+\)/g,t=>t.replace(/(-?\d*\.?\d(?!\b-.+[,)](?![^+\-/*])\D)(?:%|[a-z]+)?|\))([+\-/*])/g,"$1 $2 "))}function b1({presets:e=[],...t}){let r={darkMode:void 0,darkColor:void 0,preflight:t.preflight!==!1&&[],theme:{},variants:Re(t.variants),rules:Re(t.rules),ignorelist:Re(t.ignorelist),hash:void 0,stringify:(n,i)=>n+":"+i,finalize:[]};for(let n of Re([...e,{darkMode:t.darkMode,darkColor:t.darkColor,preflight:t.preflight!==!1&&Re(t.preflight),theme:t.theme,hash:t.hash,stringify:t.stringify,finalize:t.finalize}])){let{preflight:i,darkMode:a=r.darkMode,darkColor:f=r.darkColor,theme:b,variants:o,rules:p,ignorelist:d,hash:h=r.hash,stringify:u=r.stringify,finalize:c}=typeof n=="function"?n(r):n;r={preflight:r.preflight!==!1&&i!==!1&&[...r.preflight,...Re(i)],darkMode:a,darkColor:f,theme:{...r.theme,...b,extend:{...r.theme.extend,...b?.extend}},variants:[...r.variants,...Re(o)],rules:[...r.rules,...Re(p)],ignorelist:[...r.ignorelist,...Re(d)],hash:h,stringify:u,finalize:[...r.finalize,...Re(c)]}}return r}function w1(e,t,r,n,i,a){for(let f of t){let b=r.get(f);b||r.set(f,b=n(f));let o=b(e,i,a);if(o)return o}}function $3(e){var t;return Ws(e[0],typeof(t=e[1])=="function"?t:()=>t)}function G3(e){return Array.isArray(e)?Ws(e[0],$s(e[1],e[2])):Ws(e,$s(void 0,void 0))}function Ws(e,t){return $h(e,(r,n,i,a)=>{let f=n.exec(r);if(f)return f.$$=r.slice(f[0].length),f.dark=a,t(f,i)})}function $h(e,t){let r=Re(e).map(W3);return(n,i,a)=>{for(let f of r){let b=t(n,f,i,a);if(b)return b}}}function W3(e){return typeof e=="string"?RegExp("^"+e+(e.includes("$")||e.slice(-1)=="-"?"":"$")):e}function os(e){let t=e?.cssRules?e:(e&&typeof e!="string"?e:(function(r){let n=document.querySelector(r||'style[data-twind=""]');return n&&n.tagName=="STYLE"||(n=document.createElement("style"),document.head.prepend(n)),n.dataset.twind="claimed",n})(e)).sheet;return{target:t,snapshot(){let r=Array.from(t.cssRules,n=>n.cssText);return()=>{this.clear(),r.forEach(this.insert)}},clear(){for(let r=t.cssRules.length;r--;)t.deleteRule(r)},destroy(){t.ownerNode?.remove()},insert(r,n){try{t.insertRule(r,n)}catch{t.insertRule(":root{}",n)}},resume:Fs}}var Ks={screens:{sm:"640px",md:"768px",lg:"1024px",xl:"1280px","2xl":"1536px"},columns:{auto:"auto","3xs":"16rem","2xs":"18rem",xs:"20rem",sm:"24rem",md:"28rem",lg:"32rem",xl:"36rem","2xl":"42rem","3xl":"48rem","4xl":"56rem","5xl":"64rem","6xl":"72rem","7xl":"80rem"},spacing:{px:"1px",0:"0px",...rt(4,"rem",4,.5,.5),...rt(12,"rem",4,5),14:"3.5rem",...rt(64,"rem",4,16,4),72:"18rem",80:"20rem",96:"24rem"},durations:{75:"75ms",100:"100ms",150:"150ms",200:"200ms",300:"300ms",500:"500ms",700:"700ms",1e3:"1000ms"},animation:{none:"none",spin:"spin 1s linear infinite",ping:"ping 1s cubic-bezier(0,0,0.2,1) infinite",pulse:"pulse 2s cubic-bezier(0.4,0,0.6,1) infinite",bounce:"bounce 1s infinite"},aspectRatio:{auto:"auto",square:"1/1",video:"16/9"},backdropBlur:be("blur"),backdropBrightness:be("brightness"),backdropContrast:be("contrast"),backdropGrayscale:be("grayscale"),backdropHueRotate:be("hueRotate"),backdropInvert:be("invert"),backdropOpacity:be("opacity"),backdropSaturate:be("saturate"),backdropSepia:be("sepia"),backgroundColor:be("colors"),backgroundImage:{none:"none"},backgroundOpacity:be("opacity"),backgroundSize:{auto:"auto",cover:"cover",contain:"contain"},blur:{none:"none",0:"0",sm:"4px",DEFAULT:"8px",md:"12px",lg:"16px",xl:"24px","2xl":"40px","3xl":"64px"},brightness:{...rt(200,"",100,0,50),...rt(110,"",100,90,5),75:"0.75",125:"1.25"},borderColor:({theme:e})=>({DEFAULT:e("colors.gray.200","currentColor"),...e("colors")}),borderOpacity:be("opacity"),borderRadius:{none:"0px",sm:"0.125rem",DEFAULT:"0.25rem",md:"0.375rem",lg:"0.5rem",xl:"0.75rem","2xl":"1rem","3xl":"1.5rem","1/2":"50%",full:"9999px"},borderSpacing:be("spacing"),borderWidth:{DEFAULT:"1px",...ht(8,"px")},boxShadow:{sm:"0 1px 2px 0 rgba(0,0,0,0.05)",DEFAULT:"0 1px 3px 0 rgba(0,0,0,0.1), 0 1px 2px -1px rgba(0,0,0,0.1)",md:"0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.1)",lg:"0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1)",xl:"0 20px 25px -5px rgba(0,0,0,0.1), 0 8px 10px -6px rgba(0,0,0,0.1)","2xl":"0 25px 50px -12px rgba(0,0,0,0.25)",inner:"inset 0 2px 4px 0 rgba(0,0,0,0.05)",none:"0 0 #0000"},boxShadowColor:be("colors"),caretColor:be("colors"),accentColor:({theme:e})=>({auto:"auto",...e("colors")}),contrast:{...rt(200,"",100,0,50),75:"0.75",125:"1.25"},content:{none:"none"},divideColor:be("borderColor"),divideOpacity:be("borderOpacity"),divideWidth:be("borderWidth"),dropShadow:{sm:"0 1px 1px rgba(0,0,0,0.05)",DEFAULT:["0 1px 2px rgba(0,0,0,0.1)","0 1px 1px rgba(0,0,0,0.06)"],md:["0 4px 3px rgba(0,0,0,0.07)","0 2px 2px rgba(0,0,0,0.06)"],lg:["0 10px 8px rgba(0,0,0,0.04)","0 4px 3px rgba(0,0,0,0.1)"],xl:["0 20px 13px rgba(0,0,0,0.03)","0 8px 5px rgba(0,0,0,0.08)"],"2xl":"0 25px 25px rgba(0,0,0,0.15)",none:"0 0 #0000"},fill:({theme:e})=>({...e("colors"),none:"none"}),grayscale:{DEFAULT:"100%",0:"0"},hueRotate:{0:"0deg",15:"15deg",30:"30deg",60:"60deg",90:"90deg",180:"180deg"},invert:{DEFAULT:"100%",0:"0"},flex:{1:"1 1 0%",auto:"1 1 auto",initial:"0 1 auto",none:"none"},flexBasis:({theme:e})=>({...e("spacing"),...er(2,6),...er(12,12),auto:"auto",full:"100%"}),flexGrow:{DEFAULT:1,0:0},flexShrink:{DEFAULT:1,0:0},fontFamily:{sans:'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"'.split(","),serif:'ui-serif,Georgia,Cambria,"Times New Roman",Times,serif'.split(","),mono:'ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace'.split(",")},fontSize:{xs:["0.75rem","1rem"],sm:["0.875rem","1.25rem"],base:["1rem","1.5rem"],lg:["1.125rem","1.75rem"],xl:["1.25rem","1.75rem"],"2xl":["1.5rem","2rem"],"3xl":["1.875rem","2.25rem"],"4xl":["2.25rem","2.5rem"],"5xl":["3rem","1"],"6xl":["3.75rem","1"],"7xl":["4.5rem","1"],"8xl":["6rem","1"],"9xl":["8rem","1"]},fontWeight:{thin:"100",extralight:"200",light:"300",normal:"400",medium:"500",semibold:"600",bold:"700",extrabold:"800",black:"900"},gap:be("spacing"),gradientColorStops:be("colors"),gridAutoColumns:{auto:"auto",min:"min-content",max:"max-content",fr:"minmax(0,1fr)"},gridAutoRows:{auto:"auto",min:"min-content",max:"max-content",fr:"minmax(0,1fr)"},gridColumn:{auto:"auto","span-full":"1 / -1"},gridRow:{auto:"auto","span-full":"1 / -1"},gridTemplateColumns:{none:"none"},gridTemplateRows:{none:"none"},height:({theme:e})=>({...e("spacing"),...er(2,6),min:"min-content",max:"max-content",fit:"fit-content",auto:"auto",full:"100%",screen:"100vh"}),inset:({theme:e})=>({...e("spacing"),...er(2,4),auto:"auto",full:"100%"}),keyframes:{spin:{from:{transform:"rotate(0deg)"},to:{transform:"rotate(360deg)"}},ping:{"0%":{transform:"scale(1)",opacity:"1"},"75%,100%":{transform:"scale(2)",opacity:"0"}},pulse:{"0%,100%":{opacity:"1"},"50%":{opacity:".5"}},bounce:{"0%, 100%":{transform:"translateY(-25%)",animationTimingFunction:"cubic-bezier(0.8,0,1,1)"},"50%":{transform:"none",animationTimingFunction:"cubic-bezier(0,0,0.2,1)"}}},letterSpacing:{tighter:"-0.05em",tight:"-0.025em",normal:"0em",wide:"0.025em",wider:"0.05em",widest:"0.1em"},lineHeight:{...rt(10,"rem",4,3),none:"1",tight:"1.25",snug:"1.375",normal:"1.5",relaxed:"1.625",loose:"2"},margin:({theme:e})=>({auto:"auto",...e("spacing")}),maxHeight:({theme:e})=>({full:"100%",min:"min-content",max:"max-content",fit:"fit-content",screen:"100vh",...e("spacing")}),maxWidth:({theme:e,breakpoints:t})=>({...t(e("screens")),none:"none",0:"0rem",xs:"20rem",sm:"24rem",md:"28rem",lg:"32rem",xl:"36rem","2xl":"42rem","3xl":"48rem","4xl":"56rem","5xl":"64rem","6xl":"72rem","7xl":"80rem",full:"100%",min:"min-content",max:"max-content",fit:"fit-content",prose:"65ch"}),minHeight:{0:"0px",full:"100%",min:"min-content",max:"max-content",fit:"fit-content",screen:"100vh"},minWidth:{0:"0px",full:"100%",min:"min-content",max:"max-content",fit:"fit-content"},opacity:{...rt(100,"",100,0,10),5:"0.05",25:"0.25",75:"0.75",95:"0.95"},order:{first:"-9999",last:"9999",none:"0"},padding:be("spacing"),placeholderColor:be("colors"),placeholderOpacity:be("opacity"),outlineColor:be("colors"),outlineOffset:ht(8,"px"),outlineWidth:ht(8,"px"),ringColor:({theme:e})=>({...e("colors"),DEFAULT:"#3b82f6"}),ringOffsetColor:be("colors"),ringOffsetWidth:ht(8,"px"),ringOpacity:({theme:e})=>({...e("opacity"),DEFAULT:"0.5"}),ringWidth:{DEFAULT:"3px",...ht(8,"px")},rotate:{...ht(2,"deg"),...ht(12,"deg",3),...ht(180,"deg",45)},saturate:rt(200,"",100,0,50),scale:{...rt(150,"",100,0,50),...rt(110,"",100,90,5),75:"0.75",125:"1.25"},scrollMargin:be("spacing"),scrollPadding:be("spacing"),sepia:{0:"0",DEFAULT:"100%"},skew:{...ht(2,"deg"),...ht(12,"deg",3)},space:be("spacing"),stroke:({theme:e})=>({...e("colors"),none:"none"}),strokeWidth:rt(2),textColor:be("colors"),textDecorationColor:be("colors"),textDecorationThickness:{"from-font":"from-font",auto:"auto",...ht(8,"px")},textUnderlineOffset:{auto:"auto",...ht(8,"px")},textIndent:be("spacing"),textOpacity:be("opacity"),transitionDuration:({theme:e})=>({...e("durations"),DEFAULT:"150ms"}),transitionDelay:be("durations"),transitionProperty:{none:"none",all:"all",DEFAULT:"color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter",colors:"color,background-color,border-color,text-decoration-color,fill,stroke",opacity:"opacity",shadow:"box-shadow",transform:"transform"},transitionTimingFunction:{DEFAULT:"cubic-bezier(0.4,0,0.2,1)",linear:"linear",in:"cubic-bezier(0.4,0,1,1)",out:"cubic-bezier(0,0,0.2,1)","in-out":"cubic-bezier(0.4,0,0.2,1)"},translate:({theme:e})=>({...e("spacing"),...er(2,4),full:"100%"}),width:({theme:e})=>({min:"min-content",max:"max-content",fit:"fit-content",screen:"100vw",...e("flexBasis")}),willChange:{scroll:"scroll-position"},zIndex:{...rt(50,"",1,0,10),auto:"auto"}};function er(e,t){let r={};do for(var n=1;nt(e)}var K3={"*,::before,::after":{boxSizing:"border-box",borderWidth:"0",borderStyle:"solid",borderColor:"theme(borderColor.DEFAULT, currentColor)"},"::before,::after":{"--tw-content":"''"},html:{lineHeight:1.5,WebkitTextSizeAdjust:"100%",MozTabSize:"4",tabSize:4,fontFamily:`theme(fontFamily.sans, ${Ks.fontFamily.sans})`,fontFeatureSettings:"theme(fontFamily.sans[1].fontFeatureSettings, normal)"},body:{margin:"0",lineHeight:"inherit"},hr:{height:"0",color:"inherit",borderTopWidth:"1px"},"abbr:where([title])":{textDecoration:"underline dotted"},"h1,h2,h3,h4,h5,h6":{fontSize:"inherit",fontWeight:"inherit"},a:{color:"inherit",textDecoration:"inherit"},"b,strong":{fontWeight:"bolder"},"code,kbd,samp,pre":{fontFamily:`theme(fontFamily.mono, ${Ks.fontFamily.mono})`,fontFeatureSettings:"theme(fontFamily.mono[1].fontFeatureSettings, normal)",fontSize:"1em"},small:{fontSize:"80%"},"sub,sup":{fontSize:"75%",lineHeight:0,position:"relative",verticalAlign:"baseline"},sub:{bottom:"-0.25em"},sup:{top:"-0.5em"},table:{textIndent:"0",borderColor:"inherit",borderCollapse:"collapse"},"button,input,optgroup,select,textarea":{fontFamily:"inherit",fontSize:"100%",lineHeight:"inherit",color:"inherit",margin:"0",padding:"0"},"button,select":{textTransform:"none"},"button,[type='button'],[type='reset'],[type='submit']":{WebkitAppearance:"button",backgroundColor:"transparent",backgroundImage:"none"},":-moz-focusring":{outline:"auto"},":-moz-ui-invalid":{boxShadow:"none"},progress:{verticalAlign:"baseline"},"::-webkit-inner-spin-button,::-webkit-outer-spin-button":{height:"auto"},"[type='search']":{WebkitAppearance:"textfield",outlineOffset:"-2px"},"::-webkit-search-decoration":{WebkitAppearance:"none"},"::-webkit-file-upload-button":{WebkitAppearance:"button",font:"inherit"},summary:{display:"list-item"},"blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre":{margin:"0"},fieldset:{margin:"0",padding:"0"},legend:{padding:"0"},"ol,ul,menu":{listStyle:"none",margin:"0",padding:"0"},textarea:{resize:"vertical"},"input::placeholder,textarea::placeholder":{opacity:1,color:"theme(colors.gray.400, #9ca3af)"},'button,[role="button"]':{cursor:"pointer"},":disabled":{cursor:"default"},"img,svg,video,canvas,audio,iframe,embed,object":{display:"block",verticalAlign:"middle"},"img,video":{maxWidth:"100%",height:"auto"},"[hidden]":{display:"none"}},V3=[re("\\[([-\\w]+):(.+)]",({1:e,2:t},r)=>({"@layer overrides":{"&":{[e]:zt(`[${t}]`,"",r)}}})),re("(group|peer)([~/][^-[]+)?",({input:e},{h:t})=>[{c:t(e)}]),oe("aspect-","aspectRatio"),re("container",(e,{theme:t})=>{let{screens:r=t("screens"),center:n,padding:i}=t("container"),a={width:"100%",marginRight:n&&"auto",marginLeft:n&&"auto",...f("xs")};for(let b in r){let o=r[b];typeof o=="string"&&(a[oa(o)]={"&":{maxWidth:o,...f(b)}})}return a;function f(b){let o=i&&(typeof i=="string"?i:i[b]||i.DEFAULT);if(o)return{paddingRight:o,paddingLeft:o}}}),oe("content-","content",({_:e})=>({"--tw-content":e,content:"var(--tw-content)"})),re("(?:box-)?decoration-(slice|clone)","boxDecorationBreak"),re("box-(border|content)","boxSizing",({1:e})=>e+"-box"),re("hidden",{display:"none"}),re("table-(auto|fixed)","tableLayout"),re(["(block|flex|table|grid|inline|contents|flow-root|list-item)","(inline-(block|flex|table|grid))","(table-(caption|cell|column|row|(column|row|footer|header)-group))"],"display"),"(float)-(left|right|none)","(clear)-(left|right|none|both)","(overflow(?:-[xy])?)-(auto|hidden|clip|visible|scroll)","(isolation)-(auto)",re("isolate","isolation"),re("object-(contain|cover|fill|none|scale-down)","objectFit"),oe("object-","objectPosition"),re("object-(top|bottom|center|(left|right)(-(top|bottom))?)","objectPosition",oo),re("overscroll(-[xy])?-(auto|contain|none)",({1:e="",2:t})=>({["overscroll-behavior"+e]:t})),re("(static|fixed|absolute|relative|sticky)","position"),oe("-?inset(-[xy])?(?:$|-)","inset",({1:e,_:t})=>({top:e!="-x"&&t,right:e!="-y"&&t,bottom:e!="-x"&&t,left:e!="-y"&&t})),oe("-?(top|bottom|left|right)(?:$|-)","inset"),re("(visible|collapse)","visibility"),re("invisible",{visibility:"hidden"}),oe("-?z-","zIndex"),re("flex-((row|col)(-reverse)?)","flexDirection",m1),re("flex-(wrap|wrap-reverse|nowrap)","flexWrap"),oe("(flex-(?:grow|shrink))(?:$|-)"),oe("(flex)-"),oe("grow(?:$|-)","flexGrow"),oe("shrink(?:$|-)","flexShrink"),oe("basis-","flexBasis"),oe("-?(order)-"),"-?(order)-(\\d+)",oe("grid-cols-","gridTemplateColumns"),re("grid-cols-(\\d+)","gridTemplateColumns",C1),oe("col-","gridColumn"),re("col-(span)-(\\d+)","gridColumn",_1),oe("col-start-","gridColumnStart"),re("col-start-(auto|\\d+)","gridColumnStart"),oe("col-end-","gridColumnEnd"),re("col-end-(auto|\\d+)","gridColumnEnd"),oe("grid-rows-","gridTemplateRows"),re("grid-rows-(\\d+)","gridTemplateRows",C1),oe("row-","gridRow"),re("row-(span)-(\\d+)","gridRow",_1),oe("row-start-","gridRowStart"),re("row-start-(auto|\\d+)","gridRowStart"),oe("row-end-","gridRowEnd"),re("row-end-(auto|\\d+)","gridRowEnd"),re("grid-flow-((row|col)(-dense)?)","gridAutoFlow",e=>oo(m1(e))),re("grid-flow-(dense)","gridAutoFlow"),oe("auto-cols-","gridAutoColumns"),oe("auto-rows-","gridAutoRows"),oe("gap-x(?:$|-)","gap","columnGap"),oe("gap-y(?:$|-)","gap","rowGap"),oe("gap(?:$|-)","gap"),"(justify-(?:items|self))-",re("justify-","justifyContent",v1),re("(content|items|self)-",e=>({["align-"+e[1]]:v1(e)})),re("(place-(content|items|self))-",({1:e,$$:t})=>({[e]:("wun".includes(t[3])?"space-":"")+t})),oe("p([xytrbl])?(?:$|-)","padding",xn("padding")),oe("-?m([xytrbl])?(?:$|-)","margin",xn("margin")),oe("-?space-(x|y)(?:$|-)","space",({1:e,_:t})=>({"&>:not([hidden])~:not([hidden])":{[`--tw-space-${e}-reverse`]:"0",["margin-"+{y:"top",x:"left"}[e]]:`calc(${t} * calc(1 - var(--tw-space-${e}-reverse)))`,["margin-"+{y:"bottom",x:"right"}[e]]:`calc(${t} * var(--tw-space-${e}-reverse))`}})),re("space-(x|y)-reverse",({1:e})=>({"&>:not([hidden])~:not([hidden])":{[`--tw-space-${e}-reverse`]:"1"}})),oe("w-","width"),oe("min-w-","minWidth"),oe("max-w-","maxWidth"),oe("h-","height"),oe("min-h-","minHeight"),oe("max-h-","maxHeight"),oe("font-","fontWeight"),oe("font-","fontFamily",({_:e})=>typeof(e=Re(e))[1]=="string"?{fontFamily:gt(e)}:{fontFamily:gt(e[0]),...e[1]}),re("antialiased",{WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale"}),re("subpixel-antialiased",{WebkitFontSmoothing:"auto",MozOsxFontSmoothing:"auto"}),re("italic","fontStyle"),re("not-italic",{fontStyle:"normal"}),re("(ordinal|slashed-zero|(normal|lining|oldstyle|proportional|tabular)-nums|(diagonal|stacked)-fractions)",({1:e,2:t="",3:r})=>t=="normal"?{fontVariantNumeric:"normal"}:{["--tw-"+(r?"numeric-fraction":"pt".includes(t[0])?"numeric-spacing":t?"numeric-figure":e)]:e,fontVariantNumeric:"var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)",...Vt({"--tw-ordinal":"var(--tw-empty,/*!*/ /*!*/)","--tw-slashed-zero":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-figure":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-spacing":"var(--tw-empty,/*!*/ /*!*/)","--tw-numeric-fraction":"var(--tw-empty,/*!*/ /*!*/)"})}),oe("tracking-","letterSpacing"),oe("leading-","lineHeight"),re("list-(inside|outside)","listStylePosition"),oe("list-","listStyleType"),re("list-","listStyleType"),oe("placeholder-opacity-","placeholderOpacity",({_:e})=>({"&::placeholder":{"--tw-placeholder-opacity":e}})),Fe("placeholder-",{property:"color",selector:"&::placeholder"}),re("text-(left|center|right|justify|start|end)","textAlign"),re("text-(ellipsis|clip)","textOverflow"),oe("text-opacity-","textOpacity","--tw-text-opacity"),Fe("text-",{property:"color"}),oe("text-","fontSize",({_:e})=>typeof e=="string"?{fontSize:e}:{fontSize:e[0],...typeof e[1]=="string"?{lineHeight:e[1]}:e[1]}),oe("indent-","textIndent"),re("(overline|underline|line-through)","textDecorationLine"),re("no-underline",{textDecorationLine:"none"}),oe("underline-offset-","textUnderlineOffset"),Fe("decoration-",{section:"textDecorationColor",opacityVariable:!1,opacitySection:"opacity"}),oe("decoration-","textDecorationThickness"),re("decoration-","textDecorationStyle"),re("(uppercase|lowercase|capitalize)","textTransform"),re("normal-case",{textTransform:"none"}),re("truncate",{overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"}),re("align-","verticalAlign"),re("whitespace-","whiteSpace"),re("break-normal",{wordBreak:"normal",overflowWrap:"normal"}),re("break-words",{overflowWrap:"break-word"}),re("break-all",{wordBreak:"break-all"}),re("break-keep",{wordBreak:"keep-all"}),Fe("caret-",{opacityVariable:!1,opacitySection:"opacity"}),Fe("accent-",{opacityVariable:!1,opacitySection:"opacity"}),re("bg-gradient-to-([trbl]|[tb][rl])","backgroundImage",({1:e})=>`linear-gradient(to ${fn(e," ")},var(--tw-gradient-stops))`),Fe("from-",{section:"gradientColorStops",opacityVariable:!1,opacitySection:"opacity"},({_:e})=>({"--tw-gradient-from":e.value,"--tw-gradient-to":e.color({opacityValue:"0"}),"--tw-gradient-stops":"var(--tw-gradient-from),var(--tw-gradient-to)"})),Fe("via-",{section:"gradientColorStops",opacityVariable:!1,opacitySection:"opacity"},({_:e})=>({"--tw-gradient-to":e.color({opacityValue:"0"}),"--tw-gradient-stops":`var(--tw-gradient-from),${e.value},var(--tw-gradient-to)`})),Fe("to-",{section:"gradientColorStops",property:"--tw-gradient-to",opacityVariable:!1,opacitySection:"opacity"}),re("bg-(fixed|local|scroll)","backgroundAttachment"),re("bg-origin-(border|padding|content)","backgroundOrigin",({1:e})=>e+"-box"),re(["bg-(no-repeat|repeat(-[xy])?)","bg-repeat-(round|space)"],"backgroundRepeat"),re("bg-blend-","backgroundBlendMode"),re("bg-clip-(border|padding|content|text)","backgroundClip",({1:e})=>e+(e=="text"?"":"-box")),oe("bg-opacity-","backgroundOpacity","--tw-bg-opacity"),Fe("bg-",{section:"backgroundColor"}),oe("bg-","backgroundImage"),oe("bg-","backgroundPosition"),re("bg-(top|bottom|center|(left|right)(-(top|bottom))?)","backgroundPosition",oo),oe("bg-","backgroundSize"),oe("rounded(?:$|-)","borderRadius"),oe("rounded-([trbl]|[tb][rl])(?:$|-)","borderRadius",({1:e,_:t})=>{let r={t:["tl","tr"],r:["tr","br"],b:["bl","br"],l:["bl","tl"]}[e]||[e,e];return{[`border-${fn(r[0])}-radius`]:t,[`border-${fn(r[1])}-radius`]:t}}),re("border-(collapse|separate)","borderCollapse"),oe("border-opacity(?:$|-)","borderOpacity","--tw-border-opacity"),re("border-(solid|dashed|dotted|double|none)","borderStyle"),oe("border-spacing(-[xy])?(?:$|-)","borderSpacing",({1:e,_:t})=>({...Vt({"--tw-border-spacing-x":"0","--tw-border-spacing-y":"0"}),["--tw-border-spacing"+(e||"-x")]:t,["--tw-border-spacing"+(e||"-y")]:t,"border-spacing":"var(--tw-border-spacing-x) var(--tw-border-spacing-y)"})),Fe("border-([xytrbl])-",{section:"borderColor"},xn("border","Color")),Fe("border-"),oe("border-([xytrbl])(?:$|-)","borderWidth",xn("border","Width")),oe("border(?:$|-)","borderWidth"),oe("divide-opacity(?:$|-)","divideOpacity",({_:e})=>({"&>:not([hidden])~:not([hidden])":{"--tw-divide-opacity":e}})),re("divide-(solid|dashed|dotted|double|none)",({1:e})=>({"&>:not([hidden])~:not([hidden])":{borderStyle:e}})),re("divide-([xy]-reverse)",({1:e})=>({"&>:not([hidden])~:not([hidden])":{["--tw-divide-"+e]:"1"}})),oe("divide-([xy])(?:$|-)","divideWidth",({1:e,_:t})=>{let r={x:"lr",y:"tb"}[e];return{"&>:not([hidden])~:not([hidden])":{[`--tw-divide-${e}-reverse`]:"0",[`border-${fn(r[0])}Width`]:`calc(${t} * calc(1 - var(--tw-divide-${e}-reverse)))`,[`border-${fn(r[1])}Width`]:`calc(${t} * var(--tw-divide-${e}-reverse))`}}}),Fe("divide-",{property:"borderColor",selector:"&>:not([hidden])~:not([hidden])"}),oe("ring-opacity(?:$|-)","ringOpacity","--tw-ring-opacity"),Fe("ring-offset-",{property:"--tw-ring-offset-color",opacityVariable:!1}),oe("ring-offset(?:$|-)","ringOffsetWidth","--tw-ring-offset-width"),re("ring-inset",{"--tw-ring-inset":"inset"}),Fe("ring-",{property:"--tw-ring-color"}),oe("ring(?:$|-)","ringWidth",({_:e},{theme:t})=>({...Vt({"--tw-ring-offset-shadow":"0 0 #0000","--tw-ring-shadow":"0 0 #0000","--tw-shadow":"0 0 #0000","--tw-shadow-colored":"0 0 #0000","&":{"--tw-ring-inset":"var(--tw-empty,/*!*/ /*!*/)","--tw-ring-offset-width":t("ringOffsetWidth","","0px"),"--tw-ring-offset-color":qt(t("ringOffsetColor","","#fff")),"--tw-ring-color":qt(t("ringColor","","#93c5fd"),{opacityVariable:"--tw-ring-opacity"}),"--tw-ring-opacity":t("ringOpacity","","0.5")}}),"--tw-ring-offset-shadow":"var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)","--tw-ring-shadow":`var(--tw-ring-inset) 0 0 0 calc(${e} + var(--tw-ring-offset-width)) var(--tw-ring-color)`,boxShadow:"var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)"})),Fe("shadow-",{section:"boxShadowColor",opacityVariable:!1,opacitySection:"opacity"},({_:e})=>({"--tw-shadow-color":e.value,"--tw-shadow":"var(--tw-shadow-colored)"})),oe("shadow(?:$|-)","boxShadow",({_:e})=>({...Vt({"--tw-ring-offset-shadow":"0 0 #0000","--tw-ring-shadow":"0 0 #0000","--tw-shadow":"0 0 #0000","--tw-shadow-colored":"0 0 #0000"}),"--tw-shadow":gt(e),"--tw-shadow-colored":gt(e).replace(/([^,]\s+)(?:#[a-f\d]+|(?:(?:hsl|rgb)a?|hwb|lab|lch|color|var)\(.+?\)|[a-z]+)(,|$)/g,"$1var(--tw-shadow-color)$2"),boxShadow:"var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)"})),oe("(opacity)-"),re("mix-blend-","mixBlendMode"),...E1(),...E1("backdrop-"),oe("transition(?:$|-)","transitionProperty",(e,{theme:t})=>({transitionProperty:gt(e),transitionTimingFunction:e._=="none"?void 0:gt(t("transitionTimingFunction","")),transitionDuration:e._=="none"?void 0:gt(t("transitionDuration",""))})),oe("duration(?:$|-)","transitionDuration","transitionDuration",gt),oe("ease(?:$|-)","transitionTimingFunction","transitionTimingFunction",gt),oe("delay(?:$|-)","transitionDelay","transitionDelay",gt),oe("animate(?:$|-)","animation",(e,{theme:t,h:r,e:n})=>{let i=gt(e),a=i.split(" "),f=t("keyframes",a[0]);return f?{["@keyframes "+(a[0]=n(r(a[0])))]:f,animation:a.join(" ")}:{animation:i}}),"(transform)-(none)",re("transform",Vs),re("transform-(cpu|gpu)",({1:e})=>({"--tw-transform":Gh(e=="gpu")})),oe("scale(-[xy])?-","scale",({1:e,_:t})=>({["--tw-scale"+(e||"-x")]:t,["--tw-scale"+(e||"-y")]:t,...Vs()})),oe("-?(rotate)-","rotate",is),oe("-?(translate-[xy])-","translate",is),oe("-?(skew-[xy])-","skew",is),re("origin-(center|((top|bottom)(-(left|right))?)|left|right)","transformOrigin",oo),"(appearance)-",oe("(columns)-"),"(columns)-(\\d+)","(break-(?:before|after|inside))-",oe("(cursor)-"),"(cursor)-",re("snap-(none)","scroll-snap-type"),re("snap-(x|y|both)",({1:e})=>({...Vt({"--tw-scroll-snap-strictness":"proximity"}),"scroll-snap-type":e+" var(--tw-scroll-snap-strictness)"})),re("snap-(mandatory|proximity)","--tw-scroll-snap-strictness"),re("snap-(?:(start|end|center)|align-(none))","scroll-snap-align"),re("snap-(normal|always)","scroll-snap-stop"),re("scroll-(auto|smooth)","scroll-behavior"),oe("scroll-p([xytrbl])?(?:$|-)","padding",xn("scroll-padding")),oe("-?scroll-m([xytrbl])?(?:$|-)","scroll-margin",xn("scroll-margin")),re("touch-(auto|none|manipulation)","touch-action"),re("touch-(pinch-zoom|pan-(?:(x|left|right)|(y|up|down)))",({1:e,2:t,3:r})=>({...Vt({"--tw-pan-x":"var(--tw-empty,/*!*/ /*!*/)","--tw-pan-y":"var(--tw-empty,/*!*/ /*!*/)","--tw-pinch-zoom":"var(--tw-empty,/*!*/ /*!*/)","--tw-touch-action":"var(--tw-pan-x) var(--tw-pan-y) var(--tw-pinch-zoom)"}),[`--tw-${t?"pan-x":r?"pan-y":e}`]:e,"touch-action":"var(--tw-touch-action)"})),re("outline-none",{outline:"2px solid transparent","outline-offset":"2px"}),re("outline",{outlineStyle:"solid"}),re("outline-(dashed|dotted|double)","outlineStyle"),oe("-?(outline-offset)-"),Fe("outline-",{opacityVariable:!1,opacitySection:"opacity"}),oe("outline-","outlineWidth"),"(pointer-events)-",oe("(will-change)-"),"(will-change)-",["resize(?:-(none|x|y))?","resize",({1:e})=>({x:"horizontal",y:"vertical"})[e]||e||"both"],re("select-(none|text|all|auto)","userSelect"),Fe("fill-",{section:"fill",opacityVariable:!1,opacitySection:"opacity"}),Fe("stroke-",{section:"stroke",opacityVariable:!1,opacitySection:"opacity"}),oe("stroke-","strokeWidth"),re("sr-only",{position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",whiteSpace:"nowrap",clip:"rect(0,0,0,0)",borderWidth:"0"}),re("not-sr-only",{position:"static",width:"auto",height:"auto",padding:"0",margin:"0",overflow:"visible",whiteSpace:"normal",clip:"auto"})];function oo(e){return(typeof e=="string"?e:e[1]).replace(/-/g," ").trim()}function m1(e){return(typeof e=="string"?e:e[1]).replace("col","column")}function fn(e,t="-"){let r=[];for(let n of e)r.push({t:"top",r:"right",b:"bottom",l:"left"}[n]);return r.join(t)}function gt(e){return e&&""+(e._||e)}function v1({$$:e}){return({r:"flex-","":"flex-",w:"space-",u:"space-",n:"space-"}[e[3]||""]||"")+e}function xn(e,t=""){return({1:r,_:n})=>{let i={x:"lr",y:"tb"}[r]||r+r;return i?{...go(e+"-"+fn(i[0])+t,n),...go(e+"-"+fn(i[1])+t,n)}:go(e+t,n)}}function E1(e=""){let t=["blur","brightness","contrast","grayscale","hue-rotate","invert",e&&"opacity","saturate","sepia",!e&&"drop-shadow"].filter(Boolean),r={};for(let n of t)r[`--tw-${e}${n}`]="var(--tw-empty,/*!*/ /*!*/)";return r={...Vt(r),[`${e}filter`]:t.map(n=>`var(--tw-${e}${n})`).join(" ")},[`(${e}filter)-(none)`,re(`${e}filter`,r),...t.map(n=>oe(`${n[0]=="h"?"-?":""}(${e}${n})(?:$|-)`,n,({1:i,_:a})=>({[`--tw-${i}`]:Re(a).map(f=>`${n}(${f})`).join(" "),...r})))]}function is({1:e,_:t}){return{["--tw-"+e]:t,...Vs()}}function Vs(){return{...Vt({"--tw-translate-x":"0","--tw-translate-y":"0","--tw-rotate":"0","--tw-skew-x":"0","--tw-skew-y":"0","--tw-scale-x":"1","--tw-scale-y":"1","--tw-transform":Gh()}),transform:"var(--tw-transform)"}}function Gh(e){return[e?"translate3d(var(--tw-translate-x),var(--tw-translate-y),0)":"translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y))","rotate(var(--tw-rotate))","skewX(var(--tw-skew-x))","skewY(var(--tw-skew-y))","scaleX(var(--tw-scale-x))","scaleY(var(--tw-scale-y))"].join(" ")}function _1({1:e,2:t}){return`${e} ${t} / ${e} ${t}`}function C1({1:e}){return`repeat(${e},minmax(0,1fr))`}function Vt(e){return{"@layer defaults":{"*,::before,::after":e,"::backdrop":e}}}var Z3=[["sticky","@supports ((position: -webkit-sticky) or (position:sticky))"],["motion-reduce","@media (prefers-reduced-motion:reduce)"],["motion-safe","@media (prefers-reduced-motion:no-preference)"],["print","@media print"],["(portrait|landscape)",({1:e})=>`@media (orientation:${e})`],["contrast-(more|less)",({1:e})=>`@media (prefers-contrast:${e})`],["(first-(letter|line)|placeholder|backdrop|before|after)",({1:e})=>`&::${e}`],["(marker|selection)",({1:e})=>`& *::${e},&::${e}`],["file","&::file-selector-button"],["(first|last|only)",({1:e})=>`&:${e}-child`],["even","&:nth-child(2n)"],["odd","&:nth-child(odd)"],["open","&[open]"],["(aria|data)-",({1:e,$$:t},r)=>t&&`&[${e}-${r.theme(e,t)||zt(t,"",r)||`${t}="true"`}]`],["((group|peer)(~[^-[]+)?)(-\\[(.+)]|[-[].+?)(\\/.+)?",({2:e,3:t="",4:r,5:n="",6:i=t},{e:a,h:f,v:b})=>{let o=wr(n)||(r[0]=="["?r:b(r.slice(1)));return`${(o.includes("&")?o:"&"+o).replace(/&/g,`:merge(.${a(f(e+i))})`)}${e[0]=="p"?"~":" "}&`}],["(ltr|rtl)",({1:e})=>`[dir="${e}"] &`],["supports-",({$$:e},t)=>{if(e&&(e=t.theme("supports",e)||zt(e,"",t)),e)return e.includes(":")||(e+=":var(--tw)"),/^\w*\s*\(/.test(e)||(e=`(${e})`),`@supports ${e.replace(/\b(and|or|not)\b/g," $1 ").trim()}`}],["max-",({$$:e},t)=>{if(e&&(e=t.theme("screens",e)||zt(e,"",t)),typeof e=="string")return`@media not all and (min-width:${e})`}],["min-",({$$:e},t)=>(e&&(e=zt(e,"",t)),e&&`@media (min-width:${e})`)],[/^\[(.+)]$/,({1:e})=>/[&@]/.test(e)&&wr(e).replace(/[}]+$/,"").split("{")]],Y3={__proto__:null,slate:{50:"#f8fafc",100:"#f1f5f9",200:"#e2e8f0",300:"#cbd5e1",400:"#94a3b8",500:"#64748b",600:"#475569",700:"#334155",800:"#1e293b",900:"#0f172a"},gray:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#1f2937",900:"#111827"},zinc:{50:"#fafafa",100:"#f4f4f5",200:"#e4e4e7",300:"#d4d4d8",400:"#a1a1aa",500:"#71717a",600:"#52525b",700:"#3f3f46",800:"#27272a",900:"#18181b"},neutral:{50:"#fafafa",100:"#f5f5f5",200:"#e5e5e5",300:"#d4d4d4",400:"#a3a3a3",500:"#737373",600:"#525252",700:"#404040",800:"#262626",900:"#171717"},stone:{50:"#fafaf9",100:"#f5f5f4",200:"#e7e5e4",300:"#d6d3d1",400:"#a8a29e",500:"#78716c",600:"#57534e",700:"#44403c",800:"#292524",900:"#1c1917"},red:{50:"#fef2f2",100:"#fee2e2",200:"#fecaca",300:"#fca5a5",400:"#f87171",500:"#ef4444",600:"#dc2626",700:"#b91c1c",800:"#991b1b",900:"#7f1d1d"},orange:{50:"#fff7ed",100:"#ffedd5",200:"#fed7aa",300:"#fdba74",400:"#fb923c",500:"#f97316",600:"#ea580c",700:"#c2410c",800:"#9a3412",900:"#7c2d12"},amber:{50:"#fffbeb",100:"#fef3c7",200:"#fde68a",300:"#fcd34d",400:"#fbbf24",500:"#f59e0b",600:"#d97706",700:"#b45309",800:"#92400e",900:"#78350f"},yellow:{50:"#fefce8",100:"#fef9c3",200:"#fef08a",300:"#fde047",400:"#facc15",500:"#eab308",600:"#ca8a04",700:"#a16207",800:"#854d0e",900:"#713f12"},lime:{50:"#f7fee7",100:"#ecfccb",200:"#d9f99d",300:"#bef264",400:"#a3e635",500:"#84cc16",600:"#65a30d",700:"#4d7c0f",800:"#3f6212",900:"#365314"},green:{50:"#f0fdf4",100:"#dcfce7",200:"#bbf7d0",300:"#86efac",400:"#4ade80",500:"#22c55e",600:"#16a34a",700:"#15803d",800:"#166534",900:"#14532d"},emerald:{50:"#ecfdf5",100:"#d1fae5",200:"#a7f3d0",300:"#6ee7b7",400:"#34d399",500:"#10b981",600:"#059669",700:"#047857",800:"#065f46",900:"#064e3b"},teal:{50:"#f0fdfa",100:"#ccfbf1",200:"#99f6e4",300:"#5eead4",400:"#2dd4bf",500:"#14b8a6",600:"#0d9488",700:"#0f766e",800:"#115e59",900:"#134e4a"},cyan:{50:"#ecfeff",100:"#cffafe",200:"#a5f3fc",300:"#67e8f9",400:"#22d3ee",500:"#06b6d4",600:"#0891b2",700:"#0e7490",800:"#155e75",900:"#164e63"},sky:{50:"#f0f9ff",100:"#e0f2fe",200:"#bae6fd",300:"#7dd3fc",400:"#38bdf8",500:"#0ea5e9",600:"#0284c7",700:"#0369a1",800:"#075985",900:"#0c4a6e"},blue:{50:"#eff6ff",100:"#dbeafe",200:"#bfdbfe",300:"#93c5fd",400:"#60a5fa",500:"#3b82f6",600:"#2563eb",700:"#1d4ed8",800:"#1e40af",900:"#1e3a8a"},indigo:{50:"#eef2ff",100:"#e0e7ff",200:"#c7d2fe",300:"#a5b4fc",400:"#818cf8",500:"#6366f1",600:"#4f46e5",700:"#4338ca",800:"#3730a3",900:"#312e81"},violet:{50:"#f5f3ff",100:"#ede9fe",200:"#ddd6fe",300:"#c4b5fd",400:"#a78bfa",500:"#8b5cf6",600:"#7c3aed",700:"#6d28d9",800:"#5b21b6",900:"#4c1d95"},purple:{50:"#faf5ff",100:"#f3e8ff",200:"#e9d5ff",300:"#d8b4fe",400:"#c084fc",500:"#a855f7",600:"#9333ea",700:"#7e22ce",800:"#6b21a8",900:"#581c87"},fuchsia:{50:"#fdf4ff",100:"#fae8ff",200:"#f5d0fe",300:"#f0abfc",400:"#e879f9",500:"#d946ef",600:"#c026d3",700:"#a21caf",800:"#86198f",900:"#701a75"},pink:{50:"#fdf2f8",100:"#fce7f3",200:"#fbcfe8",300:"#f9a8d4",400:"#f472b6",500:"#ec4899",600:"#db2777",700:"#be185d",800:"#9d174d",900:"#831843"},rose:{50:"#fff1f2",100:"#ffe4e6",200:"#fecdd3",300:"#fda4af",400:"#fb7185",500:"#f43f5e",600:"#e11d48",700:"#be123c",800:"#9f1239",900:"#881337"}};function q3({disablePreflight:e}={}){return(function({colors:t,disablePreflight:r}={}){return{preflight:r?void 0:K3,theme:{...Ks,colors:{inherit:"inherit",current:"currentColor",transparent:"transparent",black:"#000",white:"#fff",...t}},variants:Z3,rules:V3,finalize:n=>n.n&&n.d&&n.r.some(i=>/^&::(before|after)$/.test(i))&&!/(^|;)content:/.test(n.d)?{...n,d:"content:var(--tw-content);"+n.d}:n}})({colors:Y3,disablePreflight:e})}var z3=typeof ShadowRoot<"u"&&(typeof ShadyCSS>"u"||ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype;function ss(e){return e.shadowRoot||e.attachShadow({mode:"open"})}var as={"brand-light":"var(--bc-color-brand, #196CE7)","brand-dark":"var(--bc-color-brand-dark, var(--bc-color-brand, #3994FF))","brand-button-text-light":"var(--bc-color-brand-button-text)","brand-button-text-dark":"var(--bc-color-brand-button-text-dark, var(--bc-color-brand-button-text))","brand-mixed-light":"color-mix(in srgb, var(--bc-color-brand, #196CE7) var(--bc-brand-mix, 100%), black)","brand-mixed-dark":"color-mix(in srgb, var(--bc-color-brand-dark, var(--bc-color-brand, #3994FF)) var(--bc-brand-mix, 100%), white)","foreground-light":"#000","foreground-dark":"#fff","background-light":"#fff","background-dark":"#000","neutral-primary-light":"#262626","neutral-primary-dark":"#E4E4E4","neutral-secondary-light":"#525252","neutral-secondary-dark":"#A2A2A2","neutral-tertiary-light":"#A2A2A2","neutral-tertiary-dark":"#525252"},Q3={"glass-light":"linear-gradient(180deg, rgba(211, 211, 211, 0.20) 0%, rgba(255, 255, 255, 0.20) 50%);","glass-dark":"linear-gradient(180deg, rgba(211, 211, 211, 0.10) 0%, rgba(0, 0, 0, 0.20) 50%)"},Ce=()=>globalThis.window?(function(e,t=!0){let r=(function(){if(z3)try{let o=os(new CSSStyleSheet);return o.connect=p=>{let d=ss(p);d.adoptedStyleSheets=[...d.adoptedStyleSheets,o.target]},o.disconnect=Fs,o}catch{}let a=document.createElement("style");a.media="not all",document.head.prepend(a);let f=[os(a)],b=new WeakMap;return{get target(){return f[0].target},snapshot(){let o=f.map(p=>p.snapshot());return()=>o.forEach(p=>p())},clear(){f.forEach(o=>o.clear())},destroy(){f.forEach(o=>o.destroy())},insert(o,p,d){f[0].insert(o,p,d);let h=this.target.cssRules[p];f.forEach((u,c)=>c&&u.target.insertRule(h.cssText,p))},resume:(o,p)=>f[0].resume(o,p),connect(o){let p=document.createElement("style");ss(o).appendChild(p);let d=os(p),{cssRules:h}=this.target;for(let u=0;u=0&&f.splice(p,1)}}})(),n=(function(a,f){let b=b1(a),o=(function({theme:c,darkMode:s,darkColor:l=Fs,variants:g,rules:w,hash:y,stringify:v,ignorelist:m,finalize:C}){let E=new Map,O=new Map,_=new Map,S=new Map,R=$h(m,(N,x)=>x.test(N));g.push(["dark",Array.isArray(s)||s=="class"?`${Re(s)[1]||".dark"} &`:typeof s=="string"&&s!="media"?s:"@media (prefers-color-scheme:dark)"]);let A=typeof y=="function"?N=>y(N,Co):y?Co:f1;A!==f1&&C.push(N=>({...N,n:N.n&&A(N.n),d:N.d?.replace(/--(tw(?:-[\w-]+)?)\b/g,(x,I)=>"--"+A(I).replace("#",""))}));let T={theme:(function({extend:N={},...x}){let I={},L={get colors(){return H("colors")},theme:H,negative:()=>({}),breakpoints(K){let P={};for(let B in K)typeof K[B]=="string"&&(P["screen-"+B]=K[B]);return P}};return H;function H(K,P,B,G){if(K){if({1:K,2:G}=/^(\S+?)(?:\s*\/\s*([^/]+))?$/.exec(K)||[,K],/[.[]/.test(K)){let F=[];K.replace(/\[([^\]]+)\]|([^.[]+)/g,(D,k,j=k)=>F.push(j)),K=F.shift(),B=P,P=F.join("-")}let z=I[K]||Object.assign(Object.assign(I[K]={},Z(x,K)),Z(N,K));if(P==null)return z;P||(P="DEFAULT");let U=z[P]??P.split("-").reduce((F,D)=>F?.[D],z)??B;return G?qt(U,{opacityValue:sa(G,H)}):U}let V={};for(let z of[...Object.keys(x),...Object.keys(N)])V[z]=H(z);return V}function Z(K,P){let B=K[P];return typeof B=="function"&&(B=B(L)),B&&/color|fill|stroke/i.test(P)?(function G(V,z=[]){let U={};for(let F in V){let D=V[F],k=[...z,F];U[k.join("-")]=D,F=="DEFAULT"&&(k=z,U[z.join("-")]=D),typeof D=="object"&&Object.assign(U,G(D,k))}return U})(B):B}})(c),e:Lh,h:A,s:(N,x)=>v(N,x,T),d:(N,x,I)=>l(N,x,T,I),v:N=>(E.has(N)||E.set(N,w1(N,g,O,$3,T)||"&:"+N),E.get(N)),r(N,x){let I=JSON.stringify([N,x]);return _.has(I)||_.set(I,!R(N,T)&&w1(N,w,S,G3,T,x)),_.get(I)},f:N=>C.reduce((x,I)=>I(x,T),N)};return T})(b),p=new Map,d=[],h=new Set;function u(c){let s=o.f(c),l=Hs(s);if(l&&!h.has(l)){h.add(l);let g=Dh(d,c);f.insert(l,g,c),d.splice(g,0,c)}return s.n}return f.resume(c=>p.set(c,c),(c,s)=>{f.insert(c,d.length,s),d.push(s),h.add(c)}),Object.defineProperties(function(c){if(!p.size)for(let l of Re(b.preflight))typeof l=="function"&&(l=l(o)),l&&(typeof l=="string"?aa("",Me.b,So(l),o,Me.b,[],!1,!0):Fh(l,{},o,Me.b)).forEach(u);let s=p.get(c=""+c);if(!s){let l=new Set;for(let g of Ao(So(c),o))l.add(g.c).add(u(g));s=[...l].filter(Boolean).join(" "),p.set(c,s).set(s,s)}return s},Object.getOwnPropertyDescriptors({get target(){return f.target},theme:o.theme,config:b,snapshot(){let c=f.snapshot(),s=new Set(h),l=new Map(p),g=[...d];return()=>{c(),h=s,p=l,d=g}},clear(){f.clear(),h=new Set,p=new Map,d=[]},destroy(){this.clear(),f.destroy()}}))})({...e,hash:e.hash??t},r),i=(function(a){let f=new MutationObserver(b);return{observe(p){f.observe(p,{attributeFilter:["class"],subtree:!0,childList:!0}),o(p),b([{target:p,type:""}])},disconnect(){f.disconnect()}};function b(p){for(let{type:d,target:h}of p)if(d[0]=="a")o(h);else for(let u of h.querySelectorAll("[class]"))o(u);f.takeRecords()}function o(p){let d,h=p.getAttribute?.("class");h&&(function(u,c){return u!=c&&""+u.split(" ").sort()!=""+c.split(" ").sort()})(h,d=a(h))&&p.setAttribute("class",d)}})(n);return function(a){return class extends a{connectedCallback(){super.connectedCallback?.(),r.connect(this),i.observe(ss(this))}disconnectedCallback(){r.disconnect(this),super.disconnectedCallback?.()}constructor(...f){super(...f),this.tw=n}}}})(b1({darkMode:globalThis.bcDarkMode,theme:{fontFamily:{sans:["Inter","sans-serif"],mono:["Roboto Mono","monospace"]},extend:{borderColor:Ct({},as),backgroundColor:Ct({},as),textColor:Ct({},as),backgroundImage:Ct({},Q3),animation:{darken:"darken 0.2s ease-out forwards","fade-in":"fade-in 0.2s ease-out forwards","slide-up":"slideUp 0.3s ease-out forwards"},keyframes:{darken:{"0%":{opacity:0},"100%":{opacity:.5}},lighten:{"0%":{opacity:.5},"100%":{opacity:0}},"fade-in":{"0%":{opacity:0},"100%":{opacity:1}},"fade-out":{"0%":{opacity:1},"100%":{opacity:0}},slideUp:{from:{transform:"translateY(100%)"},to:{transform:"translateY(0)"}}}}},presets:[q3({})],hash:!1})):J3;function J3(e){return e}var qe="transition-all hover:brightness-90 dark:hover:brightness-110 active:scale-95 cursor-pointer",Zs="hover-animation",Pe="text-brand-mixed-light dark:text-brand-mixed-dark",It="text-foreground-light dark:text-foreground-dark",mr="text-neutral-primary-light dark:text-neutral-primary-dark",de="text-neutral-secondary-light dark:text-neutral-secondary-dark",At="text-neutral-tertiary-light dark:text-neutral-tertiary-dark",bn="border-neutral-secondary-light dark:border-neutral-secondary-dark",ca="border-neutral-tertiary-light dark:border-neutral-tertiary-dark",A1,S1,T1,Ys=e=>e;function Wh(){return X(A1||(A1=Ys`
`),ca)}function X3(e){ne.getState().connected&&e(ne.getState().provider);let t=ne.subscribe(async(r,n)=>{if(r.connected&&!n.connected){if(!r.provider)throw new Error("No provider available");e(r.provider)}});return()=>{t()}}function e5(e){let t=ne.subscribe(async(r,n)=>{!r.connected&&n.connected&&e()});return()=>{t()}}function t5(e){let t=ne.subscribe(async(r,n)=>{!r.modalOpen&&n.modalOpen&&e()});return()=>{t()}}function n5(){return console.warn("Bitcoin Connect: isConnected is deprecated and will be removed in the next major version"),ne.getState().connected}function r5(e={}){ne.getState().setBitcoinConnectConfig(e)}function Kh(){let e=document.createElement("bc-modal"),t=document.createElement("bc-connect");t.setAttribute("closable","closable"),e.appendChild(t),document.body.appendChild(e),ne.getState().setModalOpen(!0)}function o5({invoice:e,paymentMethods:t,onPaid:r,onCancelled:n}){if(document.querySelector("bc-modal"))throw new Error("bc-modal already in DOM");let i=document.createElement("bc-modal"),a=document.createElement("bc-payment");a.setAttribute("closable","closable"),a.setAttribute("invoice",e),t&&a.setAttribute("payment-methods",t),i.appendChild(a);let f=!1,b=p=>{f=!0,r?.(p.detail)};window.addEventListener("bc:onpaid",b);let o=t5(()=>{o(),window.removeEventListener("bc:onpaid",b),f||n==null||n()});return document.body.appendChild(i),ne.getState().setModalOpen(!0),{setPaid:p=>{a.setAttribute("paid","paid"),a.dispatchEvent(new CustomEvent("bc:onpaid",{bubbles:!0,composed:!0,detail:p}))}}}function No(){let e=document.querySelector("bc-modal");e&&document.body.removeChild(e),ne.getState().setModalOpen(!1),ne.getState().clearRouteHistory(),ne.getState().setError(void 0)}function i5(){ne.getState().disconnect()}function s5(){return ne.getState().connectorConfig}var O1,a5=e=>e,Rn=class extends Ce()(ye){constructor(){super(),this._loading=!1,this._loadBalance(),window.addEventListener("bc:balancerefresh",()=>{this._loadBalance()}),this._selectedCurrency=ne.getState().currency,ne.subscribe((e,t)=>{this._selectedCurrency=e.currency,e.currency!==t.currency&&this._convertBalance(),e.connected!==t.connected&&e.connected&&this._loadBalance()})}render(){return X(O1||(O1=a5`
+ ${0} `),Pe,this._balance||"Loading...")}async _convertBalance(){if(this._loading||this._balanceSats===void 0)return;let e=this._selectedCurrency||"sats";if(e==="BTC")this._balance=(this._balanceSats/1e8).toLocaleString(void 0,{minimumFractionDigits:8,useGrouping:!0})+" BTC";else if(e!=="sats"){try{this._loading=!0;let t=await Ul({satoshi:this._balanceSats,currency:e}),r=parseFloat(t.toFixed(2));this._balance=new Intl.NumberFormat(void 0,{style:"currency",currency:e}).format(r)}catch(t){console.error(t)}this._loading=!1}else this._balance=this._balanceSats.toLocaleString(void 0,{useGrouping:!0})+" sats"}_loadBalance(){var e=this;(async function(){try{let t=ne.getState().provider;if(t==null||!t.getBalance)return;let r=await t.getBalance();r&&(e._balanceSats=r.balance,e._convertBalance())}catch(t){e._balance="\u26A0\uFE0F",console.error(t)}})()}};ee([ge()],Rn.prototype,"_balance",void 0),ee([ge()],Rn.prototype,"_balanceSats",void 0),ee([ge()],Rn.prototype,"_loading",void 0),ee([ge()],Rn.prototype,"_selectedCurrency",void 0),Rn=ee([pe("bc-balance")],Rn);var N1,c5=e=>e,wn=e=>Ee(N1||(N1=c5`
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ `),e||"w-7 h-7"),x1,R1,I1,P1,k1,L1,U1,M1,ln=e=>e,io=class extends Ce()(ye){constructor(){super(),this.title="Connect Wallet",this._showBalance=void 0,this._showBalance=ne.getState().bitcoinConnectConfig.showBalance&&ne.getState().supports("getBalance"),ne.subscribe(e=>{this._showBalance=e.bitcoinConnectConfig.showBalance&&e.supports("getBalance")})}render(){let e=this._connecting||!this._connected&&this._modalOpen;return X(x1||(x1=ln`
+
+
+ ${0}
+
+ ${0}
+
+ ${0}
+
+
+ ${0}
+
+
`),qe,this._onClick,this._connected?"bg-glass-light dark:bg-glass-dark":"",this._connected?Wh():"",e?X(R1||(R1=ln` ${0} `),wn("w-11 h-11 -mr-2 mr-1 -ml-2.5")):this._connected?null:X(I1||(I1=ln`${0} `),lr),e?X(P1||(P1=ln`Connecting...`)):this._connected?X(k1||(k1=ln`Connected`)):X(L1||(L1=ln`${0}`),this.title),this._connected&&this._showBalance?X(U1||(U1=ln` `)):null)}_onClick(){Kh()}};ee([Ue()],io.prototype,"title",void 0),ee([ge()],io.prototype,"_showBalance",void 0),io=ee([pe("bc-button")],io);var l5=Ee(M1||(M1=(e=>e)`
+
+
+
+`)),D1,B1,F1,j1,H1,$1,In=e=>e,Gt=class extends Ce()(ye){constructor(){super(...arguments),this.title="Pay Now",this.paymentMethods="all",this._waitingForInvoice=!1,this._paid=!1}updated(e){var t;super.updated(e),e.has("invoice")&&this.invoice&&this._waitingForInvoice&&this._launchModal(),e.has("invoice")&&!this.invoice&&(this._waitingForInvoice=!1,this._paid=!1),e.has("preimage")&&this.preimage&&((t=this._setPaid)==null||t.call(this,{preimage:this.preimage}))}render(){let e=!this._paid&&(this._waitingForInvoice||this._modalOpen);return X(D1||(D1=In`
+
+ ${0}
+
+ ${0}
+
+
+
`),this._onClick,e?X(B1||(B1=In`${0}`),wn("w-11 h-11 -mr-2 -ml-2.5 ")):this._paid?X(F1||(F1=In`${0} `),l5):X(j1||(j1=In`${0} `),lr),e?X(H1||(H1=In`Loading...`)):X($1||($1=In`${0}`),this._paid?"Paid":this.title))}_onClick(){this._paid||(this._waitingForInvoice=!0,this.invoice&&this._launchModal())}_launchModal(){if(this._waitingForInvoice=!1,!this.invoice)throw new Error("No invoice available");let{setPaid:e}=o5({onPaid:()=>{this._paid=!0},invoice:this.invoice,paymentMethods:this.paymentMethods});this._setPaid=e}};ee([Ue()],Gt.prototype,"title",void 0),ee([Ue()],Gt.prototype,"invoice",void 0),ee([Ue({type:String,attribute:"payment-methods"})],Gt.prototype,"paymentMethods",void 0),ee([Ue({})],Gt.prototype,"preimage",void 0),ee([ge()],Gt.prototype,"_waitingForInvoice",void 0),ee([ge()],Gt.prototype,"_paid",void 0),Gt=ee([pe("bc-pay-button")],Gt);var G1,W1,u5=e=>e,tr=class extends Ce()(br){constructor(){super(...arguments),this.variant="secondary",this.ghost=!1,this.block=!1}render(){let e=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,t=window.getComputedStyle(this).getPropertyValue(e?"--bc-color-brand-button-text-dark":"--bc-color-brand-button-text")||window.getComputedStyle(this).getPropertyValue("--bc-color-brand-button-text");return X(G1||(G1=u5`
+ ${0}
+
+
+
+
+
+ `),this.ghost?"":"shadow",qe,this.variant==="primary"?"bg-brand-light dark:bg-brand-dark":"",this.variant==="primary"?t?"text-brand-button-text-light dark:text-brand-button-text-dark":this._getBrandColorLuminance()>.5?"text-black":"text-white":this.variant==="secondary"?`${Pe}`:`${At}`,this.ghost?null:this.variant==="primary"?Wh():this.variant==="secondary"?X(S1||(S1=Ys`
`),"border-brand-mixed-light dark:border-brand-mixed-dark"):X(T1||(T1=Ys`
`),ca),this.block?"w-full":"")}};ee([Ue()],tr.prototype,"variant",void 0),ee([Ue({type:Boolean})],tr.prototype,"ghost",void 0),ee([Ue({type:Boolean})],tr.prototype,"block",void 0),tr=ee([pe("bci-button")],tr);var h5=Ee(W1||(W1=(e=>e)`
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+`)),K1,f5=e=>e,st=class extends Ce()(ye){constructor(t,r,n,i){super(),this._connectorType=t,this._title=r,this._background=n,this._icon=i}render(){return X(K1||(K1=f5`
+
+ ${0}
+
+
+ ${0}
+
+ `),qe,this._title,this._onClick,this._background,this._icon,de,this._title)}_connect(t){ne.getState().connect(Ct({},t,{connectorName:this._title,connectorType:this._connectorType}))}},V1,Z1=class extends st{constructor(){super("extension.generic","Browser Extensions","#F4F4F4",h5)}_onClick(){this._connect({})}};Z1=ee([pe("bc-extension-connector")],Z1);var Vh=Ee(V1||(V1=(e=>e)`
+
+
+
+ `)),Zh="Alby Hub",Y1,q1=class extends st{constructor(){super("nwc.albyhub",Zh,"#000000",Vh)}async _onClick(){ne.getState().pushRoute("/alby-hub")}};q1=ee([pe("bc-alby-hub-connector")],q1);var d5=Ee(Y1||(Y1=(e=>e)`
+
+
+
+
+
+
+
+
+
+
+
+
+ `)),la="NWC",z1,Q1=class extends st{constructor(){super("nwc.generic",la,"#ffffff",d5)}async _onClick(){ne.getState().pushRoute("/nwc")}};Q1=ee([pe("bc-nwc-connector")],Q1);var p5=Ee(z1||(z1=(e=>e)` `)),J1,X1=class extends st{constructor(){super("lnc","Lightning Node Connect","#101727",p5)}async _onClick(){let e=window.prompt("Enter pairing phrase");if(!e)return;let t=await Ah();if(!t)throw new Error("LNC not supported");t.credentials.pairingPhrase=e,this._connect({})}};X1=ee([pe("bc-lnc-connector")],X1);var Yh=Ee(J1||(J1=(e=>e)`
+
+
+ `)),qs="LNbits",eu=class extends st{constructor(){super("lnbits",qs,"#673ab7",Yh)}async _onClick(){ne.getState().pushRoute("/lnbits")}};eu=ee([pe("bc-lnbits-connector")],eu);var zs="LNbits NWC Plugin",tu,nu=class extends st{constructor(){super("lnbits",zs,"#673ab7",Yh)}async _onClick(){ne.getState().pushRoute("/lnbits-nwc")}};nu=ee([pe("bc-lnbits-nwc-connector")],nu);var y5=Ee(tu||(tu=(e=>e)`
+
+
+
+
+
+
+
+
+
+`)),g5="LN Link",ru,ou=class extends st{constructor(){super("nwc.generic",g5,"#ffffff",y5)}async _onClick(){ne.getState().pushRoute("/lnfi")}};ou=ee([pe("bc-lnfi-nwc-connector")],ou);var b5=Ee(ru||(ru=(e=>e)` `)),w5="Coinos",iu,su=class extends st{constructor(){super("nwc.coinos",w5,"#ffffff",b5)}async _onClick(){try{var e;let t=ne.getState().bitcoinConnectConfig.providerConfig,r=await jt.fromAuthorizationUrl("https://coinos.io/apps/new",Ct({},(t==null||(e=t.nwc)==null?void 0:e.authorizationUrlOptions)||{},{name:this._appName}));r.close(),await ne.getState().connect({nwcUrl:r.nostrWalletConnectUrl,connectorName:"Coinos",connectorType:"nwc.coinos"})}catch(t){console.error(t),alert(""+t)}}};su=ee([pe("bc-coinos-connector")],su);var m5=Ee(iu||(iu=(e=>e)` `)),v5="Flash Wallet",au,cu=class extends st{constructor(){super("nwc.flash",v5,"#000000",m5)}async _onClick(){ne.getState().pushRoute("/flash-wallet")}};cu=ee([pe("bc-flash-connector")],cu);var E5=Ee(au||(au=(e=>e)`
+
+
+
+
+
+
+
+
+`)),Qs="Rizful",lu=class extends st{constructor(){super("nwc.rizful",Qs,"#000000",E5)}async _onClick(){ne.getState().pushRoute("/rizful")}};lu=ee([pe("bc-rizful-connector")],lu);var uu,hu,fu,du,pu,yu,gu,bu,wu,mu,vu,Eu,_u,Cu,ot=e=>e,cs=class extends Ce()(ye){constructor(){super(...arguments),this._showAll=!1}render(){let e=[];return e.push({order:0,result:X(uu||(uu=ot` `))}),e.push({order:0,result:X(hu||(hu=ot` `))}),e.push({order:0,result:X(fu||(fu=ot` `))}),e.push({order:0,result:X(du||(du=ot` `))}),this._filters&&this._filters.indexOf("nwc")>-1&&e.push({order:0,result:X(pu||(pu=ot` `))}),e.push({order:0,result:X(yu||(yu=ot` `))}),e.push({order:0,result:X(gu||(gu=ot` `))}),e.push({order:10,result:X(bu||(bu=ot` `))}),this._filters&&this._filters.indexOf("nwc")!==-1||(window.webln&&e.push({order:0,result:X(wu||(wu=ot` `))}),e.push({order:7,result:X(mu||(mu=ot` `))}),e.push({order:9,result:X(vu||(vu=ot` `))})),e.sort((t,r)=>t.order-r.order),X(Eu||(Eu=ot`
+
+ `),this._showAll?"max-h-96 overflow-y-auto":"",(this._showAll?e:e.slice(0,9)).map(t=>t.result),!this._showAll&&e.length>9?X(_u||(_u=ot`
+
+ show all (${0})
+
+
`),qe,de,e.length,this._toggleShowAll,e.length):null)}_toggleShowAll(){this._showAll=!0}};ee([ge()],cs.prototype,"_showAll",void 0),cs=ee([pe("bc-connector-list")],cs);var _5=Ee(Cu||(Cu=(e=>e)`
+
+
+
+ `)),Au,Su,Tu=e=>e;function ua(e){return X(Au||(Au=Tu`
+ ${0}
+
+
+ ${0}
+ Disconnect
+
+
`),e?X(Su||(Su=Tu`Connected through
+ ${0} `),de,e):null,C5,Zs,_5,At)}function C5(){ne.getState().setModalOpen(!1),setTimeout(()=>{ne.getState().disconnect()},200)}var Ou=e=>String.fromCodePoint(...e.split("").map(t=>127397+t.toUpperCase().charCodeAt(0))),Nu,ls,xu,Ru,Iu,Pu,so=e=>e,ao=(ls=class extends(Nu=Ce()(ye)){constructor(){super(),this._isSwitchingCurrency=!1,this._selectedCurrency=ne.getState().currency,ne.subscribe(e=>{this._selectedCurrency=e.currency})}render(){if(!this._isSwitchingCurrency)return X(xu||(xu=so`
+
+
+
+
`),qe,this._selectedCurrency||"sats",this._showSelectVisibility);let e=(()=>{let r=[{name:"SATS",value:"sats",flag:"\u20BF"},{name:"BTC",value:"BTC",flag:"\u20BF"},{name:"USD",value:"USD",flag:Ou("US")},{name:"EUR",value:"EUR",flag:"\u{1F1EA}\u{1F1FA}"}];return r.push(...Object.entries({JP:"JPY",CN:"CNY",GB:"GBP",CH:"CHF",IN:"INR",AE:"AED",AF:"AFN",AL:"ALL",DZ:"DZD",AO:"AOA",AR:"ARS",AM:"AMD",AW:"AWG",AU:"AUD",AZ:"AZN",BS:"BSD",BH:"BHD",BD:"BDT",BB:"BBD",BY:"BYN",BZ:"BZD",BM:"BMD",BT:"BTN",BO:"BOB",BA:"BAM",BW:"BWP",BR:"BRL",BN:"BND",BG:"BGN",BI:"BIF",CV:"CVE",KH:"KHR",CA:"CAD",KY:"KYD",CF:"XAF",CL:"CLP",CO:"COU",KM:"KMF",CD:"CDF",CR:"CRC",CU:"CUC",CW:"ANG",CZ:"CZK",DK:"DKK",DJ:"DJF",DM:"XCD",DO:"DOP",EG:"EGP",ER:"ERN",ET:"ETB",FJ:"FJD",PF:"XPF",GM:"GMD",GE:"GEL",GH:"GHS",GI:"GIP",GT:"GTQ",GN:"GNF",GY:"GYD",HN:"HNL",HK:"HKD",HU:"HUF",IS:"ISK",ID:"IDR",IR:"XDR",IQ:"IQD",IL:"ILS",JM:"JMD",JO:"JOD",KZ:"KZT",KE:"KES",KR:"KRW",KW:"KWD",KG:"KGS",LA:"LAK",LB:"LBP",LR:"LRD",LY:"LYD",MO:"MOP",MG:"MGA",MW:"MWK",MY:"MYR",MV:"MVR",MR:"MRU",MU:"MUR",MX:"MXN",MD:"MDL",MN:"MNT",MA:"MAD",MZ:"MZN",MM:"MMK",NP:"NPR",NZ:"NZD",NI:"NIO",NE:"XOF",NG:"NGN",MK:"MKD",NO:"NOK",OM:"OMR",PK:"PKR",PG:"PGK",PY:"PYG",PE:"PEN",PH:"PHP",PL:"PLN",QA:"QAR",RO:"RON",RU:"RUB",RW:"RWF",SH:"SHP",WS:"WST",ST:"STN",SA:"SAR",RS:"RSD",SC:"SCR",SL:"SLL",SG:"SGD",SB:"SBD",SO:"SOS",ZA:"ZAR",SS:"SSP",LK:"LKR",SD:"SDG",SR:"SRD",SE:"SEK",SY:"SYP",TW:"TWD",TJ:"TJS",TZ:"TZS",TH:"THB",TO:"TOP",TT:"TTD",TN:"TND",TR:"TRY",TM:"TMT",UG:"UGX",UA:"UAH",UY:"UYU",UZ:"UZS",VU:"VUV",VN:"VND",YE:"YER",ZM:"ZMW",ZW:"ZWL"}).map(([n,i])=>({name:n,value:i,flag:Ou(n)}))),r})(),t=this._selectedCurrency||"sats";return X(Ru||(Ru=so`
+ ${0}
+
`),e.map(r=>X(Iu||(Iu=so`
+
+ ${0} ${0}
+
+ `),t===r.value?"bg-blue-500 text-white":"",r.value,t===r.value,()=>this._selectCurrency(r.value),r.flag,r.value)))}_showSelectVisibility(){this._isSwitchingCurrency=!0}_selectCurrency(e){ne.getState().setCurrency(e),this._isSwitchingCurrency=!1}},ls.styles=[...Nu.styles,Oo(Pu||(Pu=so`
+ .currencies-list {
+ mask-image: linear-gradient(
+ to bottom,
+ black calc(100% - 96px),
+ transparent 100%
+ );
+ }
+ /* width */
+ ::-webkit-scrollbar {
+ width: 6px;
+ height: 18px;
+ }
+
+ /* Track */
+ ::-webkit-scrollbar-track {
+ background: #66666666;
+ }
+
+ /* Handle */
+ ::-webkit-scrollbar-thumb {
+ background: #888;
+ }
+
+ /* Handle on hover */
+ ::-webkit-scrollbar-thumb:hover {
+ background: #555;
+ }
+ `))],ls);ee([ge()],ao.prototype,"_isSwitchingCurrency",void 0),ee([ge()],ao.prototype,"_selectedCurrency",void 0),ao=ee([pe("bc-currency-switcher")],ao);var ku,Lu,Uu,Mu,Du,Bu,nr=e=>e,us=class extends Ce()(ye){constructor(){super(),this._showBalance=void 0,this._showBalance=ne.getState().bitcoinConnectConfig.showBalance&&ne.getState().supports("getBalance"),ne.subscribe(e=>{this._showBalance=e.bitcoinConnectConfig.showBalance&&e.supports("getBalance")})}render(){return X(ku||(ku=nr`
+ ${0}
+
`),this._connected?X(Lu||(Lu=nr`
+ ${0}
+ ${0}
+ `),X(this._showBalance?Uu||(Uu=nr`Balance
+
+
+ `):Mu||(Mu=nr` Wallet Connected `),de),ua(this._connectorName)):X(Du||(Du=nr`
+
+ How would you like to
+ connect${0}?
+
+
+
+
+
+
+ Don't have a bitcoin lightning wallet?
+
+ Get one here
+
+
+
+ `),mr,this._appName&&this._appName!==As.appName?`
+to ${this._appName}`:"",mr,qe,Pe,()=>ne.getState().pushRoute("/new-wallet")))}};ee([ge()],us.prototype,"_showBalance",void 0),us=ee([pe("bc-start")],us);var A5=Ee(Bu||(Bu=(e=>e)`
+
+
+`)),Fu,ju,S5=e=>e,hs=class extends Ce()(ye){constructor(){super(...arguments),this._goBack=()=>{ne.getState().popRoute(),ne.getState().setError(void 0)}}render(){return X(Fu||(Fu=S5`
+
+
+ ${0}
+
+
+
+ ${0}
+
+
`),qe,At,this._goBack,A5,mr,this.heading)}};ee([Ue()],hs.prototype,"heading",void 0),hs=ee([pe("bc-navbar")],hs);var Hu=Ee(ju||(ju=(e=>e)`
+
+
+ `)),$u,Gu,Wu,Ku=e=>e;function qh(e){let t=`border-t ${ca} ${e?"w-24":"w-full"}`;return X($u||($u=Ku`
+
+ ${0}
+
`),t,e?X(Gu||(Gu=Ku`
+ ${0}
+
+ `),At,e,t):null)}var T5=Ee(Wu||(Wu=(e=>e)`
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+`)),Vu,O5=e=>e,Zu=class extends Ce()(ye){render(){return X(Vu||(Vu=O5`
+
+
+
+
+ How does it work?
+
+
+ Bitcoin Connect is a way to connect to your lightning wallet from
+ any browser.
+
+
+
+ 💾 Your connection is saved in local storage, so next time you
+ visit the site will connect automatically.
+
+
+ 💸 Make sure to set budgets and permissions for sites you do not
+ trust.
+
+
+
+
+
+ ${0}
+
+ Made with love by
+ ${0}
+
+
+
`),Pe,de,de,Zs,Pe,Hu,Zs,Pe,Hu,qh(),At,It,T5)}};Zu=ee([pe("bc-help")],Zu);var Yu,qu,N5=e=>e,ds=class extends Ce()(ye){constructor(){super(...arguments),this._nwcUrl=""}render(){return X(Yu||(Yu=N5``),de,this._nwcUrl,this.nwcUrlChanged,bn,It,this.onConnect)}nwcUrlChanged(e){this._nwcUrl=e.target.value}async onConnect(){this._nwcUrl?await ne.getState().connect({nwcUrl:this._nwcUrl,connectorName:la,connectorType:"nwc.generic"}):ne.getState().setError("Please enter a URL")}};ee([ge()],ds.prototype,"_nwcUrl",void 0),ds=ee([pe("bc-nwc")],ds);var x5=Ee(qu||(qu=(e=>e)`
+
+ `)),zu,R5=Ee(zu||(zu=(e=>e)` `)),Qu,I5=Ee(Qu||(Qu=(e=>e)` `)),Ju,Xu,P5=e=>e,e0=class extends Ce()(ye){render(){return X(Ju||(Ju=P5`
+
+
+
+
+ Choose how to connect
+
+
+
+ ${0}
+ Alby Cloud
+
+
+
+ ${0}
+ Alby Go
+
+
+
+ ${0}
+ Connection Secret
+
+
+
+
`),"Connect "+Zh,de,this.onClickAlbyCloud,x5,Pe,this.onClickAlbyGo,I5,Pe,this.onClickConnectionSecret,R5,Pe)}async onClickAlbyCloud(){try{var e;let t=ne.getState().bitcoinConnectConfig.providerConfig,r=await jt.fromAuthorizationUrl("https://my.albyhub.com/apps/new",Ct({},(t==null||(e=t.nwc)==null?void 0:e.authorizationUrlOptions)||{},{name:this._appName}));r.close(),await ne.getState().connect({nwcUrl:r.nostrWalletConnectUrl,connectorName:"Alby Hub",connectorType:"nwc.albyhub"})}catch(t){console.error(t),alert(""+t)}}async onClickConnectionSecret(){ne.getState().pushRoute("/nwc")}async onClickAlbyGo(){ne.getState().pushRoute("/alby-go")}};e0=ee([pe("bc-alby-hub")],e0);var ha=Ee(Xu||(Xu=(e=>e)`
+
+
+ `)),t0,fa=Ee(t0||(t0=(e=>e)`
+
+ `)),n0,r0,o0=e=>e,co=class extends Ce()(ye){constructor(){super(),this._hasCopiedAuthString=!1,this.initAlbyGo()}disconnectedCallback(){var e;super.disconnectedCallback(),(e=this._unsub)==null||e.call(this)}render(){return X(n0||(n0=o0`
+
+
+
+
+ Scan with your camera, QR code scanner app, or from Alby Go -> Send
+
+
+
+ ${0}
+
Waiting for connection
+
+
+ ${0}
+
+
+ ${0}
+ ${0}
+
+
+
+
+