@voxket-ai/events-sdk 1.0.17 → 1.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/events-sdk.js +32 -26
- package/dist/events-sdk.umd.cjs +1 -1
- package/package.json +1 -1
package/dist/events-sdk.js
CHANGED
|
@@ -1988,6 +1988,11 @@ var st = ({ apiClient: e, storage: t, logger: n, primaryColor: r, isDark: i = !1
|
|
|
1988
1988
|
let s = (F?.review_submission?.editable_fields || []).find((e) => e.id === r), l = s?.current_file?.id;
|
|
1989
1989
|
Fe(r), S(null), w(null);
|
|
1990
1990
|
try {
|
|
1991
|
+
if (l) try {
|
|
1992
|
+
await e.deleteFile(l, a);
|
|
1993
|
+
} catch (e) {
|
|
1994
|
+
n.error("Could not delete replaced submission file", e);
|
|
1995
|
+
}
|
|
1991
1996
|
let t = await e.uploadFile(i, a, null, s?.label), c = t?.data?.asset_id || t?.asset_id;
|
|
1992
1997
|
if (!c) throw Error("Upload response missing asset_id");
|
|
1993
1998
|
ke((e) => ({
|
|
@@ -1997,7 +2002,7 @@ var st = ({ apiClient: e, storage: t, logger: n, primaryColor: r, isDark: i = !1
|
|
|
1997
2002
|
fieldId: r,
|
|
1998
2003
|
assetId: c,
|
|
1999
2004
|
response: t
|
|
2000
|
-
})
|
|
2005
|
+
});
|
|
2001
2006
|
} catch (e) {
|
|
2002
2007
|
n.error("Submission file upload failed", e);
|
|
2003
2008
|
let t = e.message || "File upload failed. Please try again.";
|
|
@@ -2016,29 +2021,30 @@ var st = ({ apiClient: e, storage: t, logger: n, primaryColor: r, isDark: i = !1
|
|
|
2016
2021
|
return;
|
|
2017
2022
|
}
|
|
2018
2023
|
let a = (Z[r] || "").trim();
|
|
2019
|
-
if (
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
[
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2024
|
+
if (a) {
|
|
2025
|
+
Fe(r), S(null), w(null);
|
|
2026
|
+
try {
|
|
2027
|
+
let t = await e.portalUpdateSubmission(i, { [r]: { text: a } }), n = t?.data || t;
|
|
2028
|
+
me((e) => ({
|
|
2029
|
+
...e,
|
|
2030
|
+
review_submission: n
|
|
2031
|
+
}));
|
|
2032
|
+
let s = (n?.editable_fields || []).find((e) => e.id === r)?.current_file?.id;
|
|
2033
|
+
s && ke((e) => ({
|
|
2034
|
+
...e,
|
|
2035
|
+
[r]: String(s)
|
|
2036
|
+
})), w("Text answer saved!"), o?.("portal_submission_text_saved", { fieldId: r });
|
|
2037
|
+
} catch (e) {
|
|
2038
|
+
n.error("Submission text answer failed", e);
|
|
2039
|
+
let t = e.message || "Could not save your answer. Please try again.";
|
|
2040
|
+
S(t), c?.({
|
|
2041
|
+
type: "submission_text_error",
|
|
2042
|
+
message: t,
|
|
2043
|
+
error: e
|
|
2044
|
+
});
|
|
2045
|
+
} finally {
|
|
2046
|
+
Fe(null);
|
|
2047
|
+
}
|
|
2042
2048
|
}
|
|
2043
2049
|
}, st = async (r) => {
|
|
2044
2050
|
r.preventDefault();
|
|
@@ -3296,7 +3302,7 @@ var ut = (e) => {
|
|
|
3296
3302
|
let a = { ...t.custom_data || {} };
|
|
3297
3303
|
for (let [e, r] of Object.entries(t)) if (!n.has(e)) {
|
|
3298
3304
|
let t = at(e, i.get(e)?.label);
|
|
3299
|
-
a[t] = r
|
|
3305
|
+
a[t] = r;
|
|
3300
3306
|
}
|
|
3301
3307
|
let o = {
|
|
3302
3308
|
xref_id: K.getXrefId(),
|
|
@@ -3361,7 +3367,7 @@ var ut = (e) => {
|
|
|
3361
3367
|
let o = { ...t.custom_data || {} };
|
|
3362
3368
|
for (let [e, n] of Object.entries(t)) if (!r.has(e)) {
|
|
3363
3369
|
let t = at(e, a.get(e)?.label);
|
|
3364
|
-
o[t] = n
|
|
3370
|
+
o[t] = n;
|
|
3365
3371
|
}
|
|
3366
3372
|
let s = {
|
|
3367
3373
|
xref_id: n,
|
package/dist/events-sdk.umd.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
(function(e,t){typeof exports==`object`&&typeof module<`u`?t(exports,require("react-dom/client"),require("react"),require("react/jsx-runtime"),require("react-dom")):typeof define==`function`&&define.amd?define([`exports`,`react-dom/client`,`react`,`react/jsx-runtime`,`react-dom`],t):(e=typeof globalThis<`u`?globalThis:e||self,t(e.VoxketEventsSdk={},e.ReactDOM,e.React,e.ReactJSXRuntime,e.ReactDOM))})(this,function(e,t,n,r,i){Object.defineProperty(e,Symbol.toStringTag,{value:`Module`});var a=Object.create,o=Object.defineProperty,s=Object.getOwnPropertyDescriptor,c=Object.getOwnPropertyNames,l=Object.getPrototypeOf,u=Object.prototype.hasOwnProperty,d=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=c(t),a=0,l=i.length,d;a<l;a++)d=i[a],!u.call(e,d)&&d!==n&&o(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(r=s(t,d))||r.enumerable});return e};n=((e,t,n)=>(n=e==null?{}:a(l(e)),d(t||!e||!e.__esModule||!u.call(e,`default`)?o(n,`default`,{value:e,enumerable:!0}):n,e)))(n,1);var f=class{isDebug;constructor(e){this.isDebug=e??(window.location.hostname===`localhost`||window.location.hostname===`127.0.0.1`)}log(e,...t){if(!this.isDebug)return;let n=this.getCallerInfo();console.log(`%c[Widget-Log] ${n}`,`color: #0bd649; font-weight: bold;`,e,...t)}warn(e,...t){if(!this.isDebug)return;let n=this.getCallerInfo();console.warn(`%c[Widget-Warn] ${n}`,`color: #f59e0b; font-weight: bold;`,e,...t)}error(e,...t){if(!this.isDebug)return;let n=this.getCallerInfo();console.error(`%c[Widget-Error] ${n}`,`color: #ff0000; font-weight: bold;`,e,...t)}getCallerInfo(){let e=(Error().stack?.split(`
|
|
2
|
-
`)[3]||``).match(/(?:at\s+.*?\s+\()?(?:.*?\/([^/]+?)):(\d+):\d+\)?$/);return e?`[${e[1]}:${e[2]}]`:``}},p=class{baseUrl;slug;logger;timeoutMs;constructor(e,t,n,r=12e4){this.baseUrl=e,this.slug=t,this.logger=n,this.timeoutMs=r}async fetchApi(e,t={}){let n=`${this.baseUrl}${e}`;this.logger.log(`API Call: ${t.method||`GET`} ${n} (timeout: ${this.timeoutMs/1e3}s)`);let r=new AbortController,i=setTimeout(()=>r.abort(),this.timeoutMs);t.signal&&t.signal.addEventListener(`abort`,()=>r.abort());try{let e=await fetch(n,{...t,signal:r.signal,headers:{"Content-Type":`application/json`,...t.headers}});clearTimeout(i);let a=null;try{a=await e.json()}catch{}if(!e.ok){let e=`API Error`;if(a){if(typeof a.message==`string`)e=a.message;else if(typeof a.detail==`string`)e=a.detail;else if(typeof a.error==`string`)e=a.error;else if(typeof a==`object`){let t=Object.values(a)[0];Array.isArray(t)&&typeof t[0]==`string`?e=t[0]:typeof t==`string`&&(e=t)}}throw Error(e)}return a}catch(t){if(clearTimeout(i),t?.name===`AbortError`){let t=Error(`Request timed out after ${this.timeoutMs/1e3} seconds`);throw this.logger.error(`API Request timed out for ${e}`,t),t}throw this.logger.error(`API Request failed for ${e}`,t),t}}async getFormSchema(){return this.fetchApi(`/api/public/events/${this.slug}/form-schema/`)}async submitRegistration(e){return this.fetchApi(`/api/public/events/${this.slug}/register/`,{method:`POST`,body:JSON.stringify(e)})}async trackProgress(e){return this.fetchApi(`/api/public/events/${this.slug}/track/`,{method:`POST`,body:JSON.stringify(e)})}async getDraft(e){return this.fetchApi(`/api/public/events/${this.slug}/track/?xref=${encodeURIComponent(e)}`)}async getDraftByEmail(e){try{return await this.fetchApi(`/api/public/events/${this.slug}/track/?email=${encodeURIComponent(e)}`)}catch(t){try{return await this.fetchApi(`/api/public/events/${this.slug}/track/?xref=${encodeURIComponent(e)}`)}catch{throw t}}}async getReviewFormSchema(){return this.fetchApi(`/api/public/events/${this.slug}/review/form-schema/`)}async submitReview(e){return this.fetchApi(`/api/public/events/${this.slug}/review/submit/`,{method:`POST`,body:JSON.stringify(e)})}async trackReviewProgress(e){return this.fetchApi(`/api/public/events/${this.slug}/review/track/`,{method:`POST`,body:JSON.stringify(e)})}async getReviewDraft(e){return this.fetchApi(`/api/public/events/${this.slug}/review/track/?xref=${encodeURIComponent(e)}`)}async getReviewDraftByEmail(e){return this.fetchApi(`/api/public/events/${this.slug}/review/track/?email=${encodeURIComponent(e)}`)}async portalLogin(e){return this.fetchApi(`/api/portal/${this.slug}/login/`,{method:`POST`,body:JSON.stringify(e)})}async portalRequestPasswordReset(e){return this.fetchApi(`/api/portal/${this.slug}/password-reset/`,{method:`POST`,body:JSON.stringify({identifier:e})})}async portalConfirmPasswordReset(e){return this.fetchApi(`/api/portal/${this.slug}/password-reset/`,{method:`POST`,body:JSON.stringify(e)})}async portalGetProfile(e){return this.fetchApi(`/api/portal/${this.slug}/me/`,{method:`GET`,headers:{Authorization:`Bearer ${e}`}})}async uploadFile(e,t,n,r){let i=new FormData;return i.append(`file`,e),r&&i.append(`label`,r),!t&&n&&i.append(`email`,n),this.postAsset(i,t)}async submitTextAnswer(e,t,n,r){let i=new FormData;return i.append(`text`,e),r&&i.append(`label`,r),!t&&n&&i.append(`email`,n),this.postAsset(i,t)}async postAsset(e,t){let n=t||null,r={};n&&(r.Authorization=`Bearer ${n}`);let i=`${this.baseUrl}/api/portal/${this.slug}/me/upload/`;this.logger.log(`API Call: POST ${i} (upload)`);let a=new AbortController,o=setTimeout(()=>a.abort(),this.timeoutMs);try{let t=await fetch(i,{method:`POST`,signal:a.signal,headers:r,body:e});clearTimeout(o);let n=null;try{n=await t.json()}catch{}if(t.ok)return n;let s=n?.message||n?.error||n?.detail||`File upload failed`;throw Error(s)}catch(e){throw clearTimeout(o),e?.name===`AbortError`?Error(`File upload timed out after ${this.timeoutMs/1e3} seconds`):e}}async deleteFile(e,t){let n=encodeURIComponent(String(e).trim()),r=t||null,i={};r&&(i.Authorization=`Bearer ${r}`);let a=[`/api/portal/${this.slug}/me/upload/${n}/`,`/api/portal/${this.slug}/me/upload/${n}`],o=null;for(let e=0;e<a.length;e++){let t=a[e];this.logger.log(`API Call: DELETE ${t}`);try{return await this.fetchApi(t,{method:`DELETE`,headers:i})}catch(t){if(o=t,(t?.message?.includes(`404`)||t?.message?.includes(`405`))&&e<a.length-1)continue;throw t}}throw o}async portalUploadFile(e,t){return this.uploadFile(t,e)}async portalDeleteFile(e,t){return this.deleteFile(t,e)}async portalUpdateProfile(e,t){let n=`${this.baseUrl}/api/portal/${this.slug}/me/`;this.logger.log(`API Call: PATCH ${n}`);let r=new AbortController,i=setTimeout(()=>r.abort(),this.timeoutMs);try{let a=await fetch(n,{method:`PATCH`,signal:r.signal,headers:{"Content-Type":`application/json`,Authorization:`Bearer ${e}`},body:JSON.stringify(t)});a.status===405&&(a=await fetch(n,{method:`PUT`,signal:r.signal,headers:{"Content-Type":`application/json`,Authorization:`Bearer ${e}`},body:JSON.stringify(t)})),clearTimeout(i);let o=null;try{o=await a.json()}catch{}if(!a.ok){let e=o?.message||o?.error||o?.detail||`Failed to update profile`;throw Error(e)}return o}catch(e){throw clearTimeout(i),e?.name===`AbortError`?Error(`Profile update timed out after ${this.timeoutMs/1e3} seconds`):e}}async portalUpdateSubmission(e,t){let n=`${this.baseUrl}/api/portal/${this.slug}/me/submission/`;this.logger.log(`API Call: PATCH ${n}`);let r=new AbortController,i=setTimeout(()=>r.abort(),this.timeoutMs);try{let a=await fetch(n,{method:`PATCH`,signal:r.signal,headers:{"Content-Type":`application/json`,Authorization:`Bearer ${e}`},body:JSON.stringify(t)});clearTimeout(i);let o=null;try{o=await a.json()}catch{}if(!a.ok){let e=o?.message||o?.error||o?.detail||`Failed to update submission`;throw Error(e)}return o}catch(e){throw clearTimeout(i),e?.name===`AbortError`?Error(`Submission update timed out after ${this.timeoutMs/1e3} seconds`):e}}},m=class{prefix;constructor(e){this.prefix=`voxket_${e}_`}generateId(){return typeof crypto<`u`&&typeof crypto.randomUUID==`function`?crypto.randomUUID():`xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx`.replace(/[xy]/g,e=>{let t=Math.random()*16|0;return(e===`x`?t:t&3|8).toString(16)})}getXrefId(){let e=`${this.prefix}xref_id`,t=localStorage.getItem(e);return t||(t=this.generateId(),localStorage.setItem(e,t)),t}updateXrefId(){let e=`${this.prefix}xref_id`,t=this.generateId();return localStorage.setItem(e,t),t}clearXrefId(){let e=`${this.prefix}xref_id`;localStorage.removeItem(e)}setToken(e){localStorage.setItem(`${this.prefix}token`,e)}getToken(){return localStorage.getItem(`${this.prefix}token`)}clearToken(){localStorage.removeItem(`${this.prefix}token`)}},h=e=>e?.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase();function g(e,t,n=[]){if(t==null)throw Error(`[lucide]: iconNode is required when icon name is used`);return{name:h(e),size:24,node:t,...n.length>0?{aliases:n}:{}}}var _=e=>{let t=``,n=!1;for(let r of e){if(r===`-`||r===`_`||r<=` `){n=t.length>0;continue}t.length===0?t+=r.toLowerCase():t+=n?r.toUpperCase():r,n=!1}return t},v=e=>{let t=_(e);return t.charAt(0).toUpperCase()+t.slice(1)},y=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),b={xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":2,"stroke-linecap":`round`,"stroke-linejoin":`round`};function x(e){return e!=null}function S(e,t={}){let n=t.attributeNames??{},r=e=>n[e]??e,i=e.size??e.width??b.width,a=e.size??e.height??b.height,o=e.aliases?.filter(e=>typeof e==`string`&&e.trim()!==``).map(e=>`lucide-${e}`)??[],s=[...e.name?[`lucide-${e.name}`]:[],...o],c=t.className?.split(` `).filter(Boolean)??[],l=t.includeDefaultClasses===!1?y(...c):y(`lucide`,...s,...c),u=t.absoluteStrokeWidth?Number(t.strokeWidth??b[`stroke-width`])*Number(e.size??e.width??b.width)/Number(t.size??t.width??b.width):t.strokeWidth??b[`stroke-width`];return[`svg`,{...Object.entries(b).reduce((e,[t,n])=>(e[r(t)]=n,e),{}),...`color`in t&&t.color&&{[r(`stroke`)]:t.color},...`size`in t&&x(t.size)&&{[r(`width`)]:t.size,[r(`height`)]:t.size},...`width`in t&&x(t.width)&&{[r(`width`)]:t.width},...`height`in t&&x(t.height)&&{[r(`height`)]:t.height},[r(`stroke-width`)]:u,...l&&{[r(`class`)]:l},[r(`viewBox`)]:`0 0 ${i} ${a}`,...t.hasA11yProp===!1?{[r(`aria-hidden`)]:`true`}:{},...`attributes`in t&&t.attributes},e.node.map(e=>{let[n,i,a]=e,o=t.nonScalingStroke?{[r(`vector-effect`)]:`non-scaling-stroke`,...i}:i;return a?[n,o,a]:[n,o]})]}function C(e,t={}){return S(e,{...t,attributeNames:{...t.attributeNames,class:`className`,"stroke-width":`strokeWidth`,"stroke-linecap":`strokeLinecap`,"stroke-linejoin":`strokeLinejoin`,"vector-effect":`vectorEffect`}})}var w=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},ee=(0,n.createContext)({}),te=()=>(0,n.useContext)(ee),T=(0,n.forwardRef)(({color:e,size:t,width:r,height:i,strokeWidth:a,absoluteStrokeWidth:o,nonScalingStroke:s,className:c=``,children:l,iconNode:u=[],icon:d={node:u,aliases:[],size:24},...f},p)=>{let{size:m=24,strokeWidth:h=2,absoluteStrokeWidth:g=!1,nonScalingStroke:_=!1,color:v=`currentColor`,className:b=``}=te()??{},x=!!l||w(f),[S,ee,T=[]]=C(d,{color:e??v,width:r??t??m,height:i??t??m,strokeWidth:a??h,absoluteStrokeWidth:o??g,nonScalingStroke:s??_,className:y(b,c),hasA11yProp:x,attributes:f});return(0,n.createElement)(S,{ref:p,...ee},[...T.map(([e,t])=>(0,n.createElement)(e,t)),...Array.isArray(l)?l:[l]])});function E(e,t=[],r=[]){let i=typeof e==`string`?g(e,t,r):e,a=(0,n.forwardRef)(({className:e,...t},r)=>(0,n.createElement)(T,{ref:r,icon:i,className:e,...t}));return i.name&&(a.displayName=v(i.name)),a}var D={name:`arrow-left`,size:24,node:[[`path`,{d:`m12 19-7-7 7-7`,key:`1l729n`}],[`path`,{d:`M19 12H5`,key:`x3x0zl`}]]};D.node;var ne=E(D),re={name:`arrow-right`,size:24,node:[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`m12 5 7 7-7 7`,key:`xquz4c`}]]};re.node;var ie=E(re),O={name:`briefcase`,size:24,node:[[`path`,{d:`M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16`,key:`jecpp`}],[`rect`,{width:`20`,height:`14`,x:`2`,y:`6`,rx:`2`,key:`i6l2r4`}]]};O.node;var ae=E(O),k={name:`building-complex`,size:24,node:[[`path`,{d:`M10 12h4`,key:`a56b0p`}],[`path`,{d:`M10 8h4`,key:`1sr2af`}],[`path`,{d:`M14 21v-3a2 2 0 0 0-4 0v3`,key:`1rgiei`}],[`path`,{d:`M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2`,key:`secmi2`}],[`path`,{d:`M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16`,key:`16ra0t`}]],aliases:[`building-2`]};k.node;var oe=E(k),A={name:`check`,size:24,node:[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]};A.node;var se=E(A),ce={name:`chevron-down`,size:24,node:[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]};ce.node;var le=E(ce),j={name:`circle-alert`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`line`,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,key:`1pkeuh`}],[`line`,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,key:`4dfq90`}]],aliases:[`alert-circle`]};j.node;var ue=E(j),de={name:`circle-check-big`,size:24,node:[[`path`,{d:`M21.801 10A10 10 0 1 1 17 3.335`,key:`yps3ct`}],[`path`,{d:`m9 11 3 3L22 4`,key:`1pflzl`}]],aliases:[`check-circle`]};de.node;var M=E(de),N={name:`clipboard-list`,size:24,node:[[`rect`,{width:`8`,height:`4`,x:`8`,y:`2`,rx:`1`,ry:`1`,key:`tgr4d6`}],[`path`,{d:`M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2`,key:`116196`}],[`path`,{d:`M12 11h4`,key:`1jrz19`}],[`path`,{d:`M12 16h4`,key:`n85exb`}],[`path`,{d:`M8 11h.01`,key:`1dfujw`}],[`path`,{d:`M8 16h.01`,key:`18s6g9`}]]};N.node;var P=E(N),F={name:`clock`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6l4 2`,key:`mmk7yg`}]]};F.node;var fe=E(F),I={name:`copy`,size:24,node:[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]};I.node;var pe=E(I),L={name:`credit-card`,size:24,node:[[`rect`,{width:`20`,height:`14`,x:`2`,y:`5`,rx:`2`,key:`ynyp8z`}],[`line`,{x1:`2`,x2:`22`,y1:`10`,y2:`10`,key:`1b3vmo`}],[`path`,{d:`M6 14h2`,key:`mk7k0u`}]]};L.node;var me=E(L),he={name:`download`,size:24,node:[[`path`,{d:`M12 15V3`,key:`m9g1x1`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}],[`path`,{d:`m7 10 5 5 5-5`,key:`brsn70`}]]};he.node;var ge=E(he),R={name:`external-link`,size:24,node:[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]};R.node;var _e=E(R),z={name:`file-text`,size:24,node:[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 9H8`,key:`b1mrlr`}],[`path`,{d:`M16 13H8`,key:`t4e002`}],[`path`,{d:`M16 17H8`,key:`z1uh3a`}]]};z.node;var ve=E(z),B={name:`folder-open`,size:24,node:[[`path`,{d:`m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2`,key:`usdka0`}]]};B.node;var V=E(B),H={name:`graduation-cap`,size:24,node:[[`path`,{d:`M21.42 10.922a1 1 0 0 0-.019-1.838L12.83 5.18a2 2 0 0 0-1.66 0L2.6 9.08a1 1 0 0 0 0 1.832l8.57 3.908a2 2 0 0 0 1.66 0z`,key:`j76jl0`}],[`path`,{d:`M22 10v6`,key:`1lu8f3`}],[`path`,{d:`M6 12.5V16a6 3 0 0 0 12 0v-3.5`,key:`1r8lef`}]]};H.node;var U=E(H),ye={name:`id-card`,size:24,node:[[`path`,{d:`M13 19a4 4 0 00-8 0`,key:`cugzd5`}],[`path`,{d:`M16 10h2`,key:`8sgtl7`}],[`path`,{d:`M16 14h2`,key:`epxaof`}],[`circle`,{cx:`9`,cy:`12`,r:`3`,key:`u3jwor`}],[`rect`,{x:`2`,y:`5`,width:`20`,height:`14`,rx:`2`,key:`qneu4z`}]]};ye.node;var be=E(ye),W={name:`info`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 16v-4`,key:`1dtifu`}],[`path`,{d:`M12 8h.01`,key:`e9boi3`}]]};W.node;var G=E(W),K={name:`key-round`,size:24,node:[[`path`,{d:`M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z`,key:`1s6t7t`}],[`circle`,{cx:`16.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`w0ekpg`}]]};K.node;var xe=E(K),q={name:`key`,size:24,node:[[`path`,{d:`m2 21 9.6-9.6`,key:`9l79m3`}],[`path`,{d:`m7.5 15.5 2.3 2.3a1 1 0 0 1 0 1.4l-2.1 2.1a1 1 0 0 1-1.4 0L4 19`,key:`fw8biw`}],[`circle`,{cx:`15.5`,cy:`7.5`,r:`5.5`,key:`4wxmhb`}]]};q.node;var J=E(q),Se={name:`lock`,size:24,node:[[`rect`,{width:`18`,height:`11`,x:`3`,y:`11`,rx:`2`,ry:`2`,key:`1w4ew1`}],[`path`,{d:`M7 11V7a5 5 0 0 1 10 0v4`,key:`fwvmzm`}]]};Se.node;var Ce=E(Se),we={name:`log-in`,size:24,node:[[`path`,{d:`m10 17 5-5-5-5`,key:`1bsop3`}],[`path`,{d:`M15 12H3`,key:`6jk70r`}],[`path`,{d:`M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4`,key:`u53s6r`}]]};we.node;var Te=E(we),Y={name:`log-out`,size:24,node:[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]};Y.node;var Ee=E(Y),De={name:`mail`,size:24,node:[[`path`,{d:`m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7`,key:`132q7q`}],[`rect`,{x:`2`,y:`4`,width:`20`,height:`16`,rx:`2`,key:`izxlao`}]]};De.node;var Oe=E(De),ke={name:`map-pin`,size:24,node:[[`path`,{d:`M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0`,key:`1r0f0z`}],[`circle`,{cx:`12`,cy:`10`,r:`3`,key:`ilqhr7`}]]};ke.node;var Ae=E(ke),X={name:`maximize-2`,size:24,node:[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`m21 3-7 7`,key:`1l2asr`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M9 21H3v-6`,key:`wtvkvv`}]]};X.node;var je=E(X),Z={name:`minimize-2`,size:24,node:[[`path`,{d:`m14 10 7-7`,key:`oa77jy`}],[`path`,{d:`M20 10h-6V4`,key:`mjg0md`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M4 14h6v6`,key:`rmj7iw`}]]};Z.node;var Me=E(Z),Ne={name:`move`,size:24,node:[[`path`,{d:`M12 2v20`,key:`t6zp3m`}],[`path`,{d:`m15 19-3 3-3-3`,key:`11eu04`}],[`path`,{d:`m19 9 3 3-3 3`,key:`1mg7y2`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}],[`path`,{d:`m5 9-3 3 3 3`,key:`j64kie`}],[`path`,{d:`m9 5 3-3 3 3`,key:`l8vdw6`}]]};Ne.node;var Pe=E(Ne),Fe={name:`package-check`,size:24,node:[[`path`,{d:`M12 22V12`,key:`d0xqtd`}],[`path`,{d:`m16 17 2 2 4-4`,key:`uh5qu3`}],[`path`,{d:`M21 11.127V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.729l7 4a2 2 0 0 0 2 .001l1.32-.753`,key:`kpkbpo`}],[`path`,{d:`M3.29 7 12 12l8.71-5`,key:`19ckod`}],[`path`,{d:`m7.5 4.27 8.997 5.148`,key:`9yrvtv`}]]};Fe.node;var Ie=E(Fe),Le={name:`phone`,size:24,node:[[`path`,{d:`M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384`,key:`9njp5v`}]]};Le.node;var Re=E(Le),ze={name:`receipt`,size:24,node:[[`path`,{d:`M12 17V7`,key:`pyj7ub`}],[`path`,{d:`M16 8h-6a2 2 0 0 0 0 4h4a2 2 0 0 1 0 4H8`,key:`1elt7d`}],[`path`,{d:`M4 3a1 1 0 0 1 1-1 1.3 1.3 0 0 1 .7.2l.933.6a1.3 1.3 0 0 0 1.4 0l.934-.6a1.3 1.3 0 0 1 1.4 0l.933.6a1.3 1.3 0 0 0 1.4 0l.933-.6a1.3 1.3 0 0 1 1.4 0l.934.6a1.3 1.3 0 0 0 1.4 0l.933-.6A1.3 1.3 0 0 1 19 2a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1 1.3 1.3 0 0 1-.7-.2l-.933-.6a1.3 1.3 0 0 0-1.4 0l-.934.6a1.3 1.3 0 0 1-1.4 0l-.933-.6a1.3 1.3 0 0 0-1.4 0l-.933.6a1.3 1.3 0 0 1-1.4 0l-.934-.6a1.3 1.3 0 0 0-1.4 0l-.933.6a1.3 1.3 0 0 1-.7.2 1 1 0 0 1-1-1z`,key:`ycz6yz`}]]};ze.node;var Be=E(ze),Ve={name:`search`,size:24,node:[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]};Ve.node;var He=E(Ve),Ue={name:`sparkles`,size:24,node:[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]],aliases:[`stars`]};Ue.node;var We=E(Ue),Ge={name:`ticket`,size:24,node:[[`path`,{d:`M2 9a3 3 0 0 1 0 6v2a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-2a3 3 0 0 1 0-6V7a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2Z`,key:`qn84l0`}],[`path`,{d:`M13 5v2`,key:`dyzc3o`}],[`path`,{d:`M13 17v2`,key:`1ont0d`}],[`path`,{d:`M13 11v2`,key:`1wjjxi`}]]};Ge.node;var Ke=E(Ge),qe={name:`trash`,size:24,node:[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]],aliases:[`trash-2`]};qe.node;var Je=E(qe),Ye={name:`upload`,size:24,node:[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]};Ye.node;var Xe=E(Ye),Ze={name:`user`,size:24,node:[[`path`,{d:`M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2`,key:`975kel`}],[`circle`,{cx:`12`,cy:`7`,r:`4`,key:`17ys0d`}]]};Ze.node;var Qe=E(Ze),$e={name:`x`,size:24,node:[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]};$e.node;var et=E($e),Q={fontFamily:`var(--vx-font-heading)`},tt=({schema:e,onSubmit:t,onBack:i,theme:a,displayMode:o,isExpanded:s,onToggleExpand:c,onClose:l,onChange:u,initialValues:d,isDark:f=!1,apiClient:p,storage:m,onError:h,onEvent:g,backgroundStyle:_,ticketType:v,showReviewFields:y=!1})=>{let[b,x]=(0,n.useState)(d||{}),[S,C]=(0,n.useState)(null),[w,ee]=(0,n.useState)(null),[te,T]=(0,n.useState)({}),[E,D]=(0,n.useState)({}),[re,O]=(0,n.useState)(null),[ae,k]=(0,n.useState)(null),[oe,A]=(0,n.useState)({}),[ce,j]=(0,n.useState)({}),[ue,de]=(0,n.useState)({}),M=a?.primaryColor||`#c026d3`;(0,n.useEffect)(()=>{if(d&&Object.keys(d).length>0){x(e=>({...d,...e}));let t={},n={};(e?.fields||[]).forEach(e=>{if(e.type===`file`){let r=d[e.id];r&&(String(r).startsWith(`http://`)||String(r).startsWith(`https://`)?n[e.id]=String(r):t[e.id]=String(r))}}),Object.keys(t).length>0&&T(e=>({...t,...e})),Object.keys(n).length>0&&D(e=>({...n,...e}))}},[d,e]);let N=(e,t)=>{x(n=>{let r={...n,[e]:t};return u?.(r),r})},P=async(t,n)=>{if(!p)return;C(t),O(null),k(null);let r=m?.getToken?.()||null,i=te[t],a=(e?.fields||[]).find(e=>e.id===t);try{let e=await p.uploadFile(n,r,r?null:I(),a?.label),o=e?.data?.asset_id||e?.asset_id,s=e?.data?.serve_url||e?.serve_url;if(!o&&!s)throw Error(`Upload response missing asset_id`);let c=String(o||s),l=String(s||``);if(T(e=>({...e,[t]:c})),l&&D(e=>({...e,[t]:l})),x(e=>{let n={...e,[t]:c};return u?.(n),n}),g?.(`file_uploaded`,{fieldId:t,assetId:c,serveUrl:l}),i&&i!==c)try{await p.deleteFile(i,r),g?.(`file_deleted`,{fieldId:t,assetId:i})}catch(e){console.warn(`[DynamicForm] Could not delete old file`,e)}}catch(e){let n=e?.message||`File upload failed. Please try again.`;O(n),k(t),h?.({type:`file_upload_error`,message:n,error:e})}finally{C(null)}},F=async e=>{if(!p)return;let t=m?.getToken?.()||null,n=te[e]||b[e];ee(e),O(null),k(null);try{n&&(await p.deleteFile(n,t),g?.(`file_deleted`,{fieldId:e,assetId:n})),T(t=>{let n={...t};return delete n[e],n}),D(t=>{let n={...t};return delete n[e],n}),de(t=>{let n={...t};return delete n[e],n}),j(t=>{let n={...t};return delete n[e],n}),x(t=>{let n={...t,[e]:``};return u?.(n),n})}catch(t){let n=t?.message||`Failed to delete file. Please try again.`;O(n),k(e),h?.({type:`file_delete_error`,message:n,error:t})}finally{ee(null)}},fe=async(t,n)=>{if(!p||!n.trim())return;C(t),O(null),k(null);let r=m?.getToken?.()||null,i=te[t],a=(e?.fields||[]).find(e=>e.id===t);try{let e=await p.submitTextAnswer(n.trim(),r,r?null:I(),a?.label),o=e?.data?.asset_id||e?.asset_id;if(!o)throw Error(`Submission response missing asset_id`);let s=String(o);if(T(e=>({...e,[t]:s})),D(e=>{let n={...e};return delete n[t],n}),de(e=>({...e,[t]:n.trim()})),x(e=>{let n={...e,[t]:s};return u?.(n),n}),g?.(`file_uploaded`,{fieldId:t,assetId:s,isText:!0}),i&&i!==s)try{await p.deleteFile(i,r),g?.(`file_deleted`,{fieldId:t,assetId:i})}catch(e){console.warn(`[DynamicForm] Could not delete old file`,e)}}catch(e){let n=e?.message||`Could not submit your answer. Please try again.`;O(n),k(t),h?.({type:`file_upload_error`,message:n,error:e})}finally{C(null)}},I=()=>{let t=(e?.fields||[]).find(e=>e.type===`email`||(e.label||e.id||``).toLowerCase().includes(`email`));return String(t&&b[t.id]||b.email||``).trim()},pe=e?.fields||[],L=e=>{if(e.description)return e.description;if(e.helperText)return e.helperText;let t=(e.label||e.id||``).toLowerCase(),n=e.type;return n===`email`||t.includes(`email`)||t.includes(`mail`)?`Please enter a valid email address. Your abstract acknowledgement, review updates, and final communication will be sent to this mailbox.`:n===`phone`||t.includes(`phone`)||t.includes(`mobile`)||t.includes(`contact`)?`Please enter a valid mobile number for SMS confirmations and important notifications.`:t.includes(`council`)||t.includes(`registration no`)||t.includes(`mci`)?`Enter your State Medical Council or National Medical Commission registration number.`:n===`file`||t.includes(`file`)||t.includes(`upload`)||t.includes(`bonafide`)||t.includes(`abstract`)?`Upload your document (PDF, JPG, PNG up to 10MB) for registration review and verification.`:t.includes(`salutation`)||t.includes(`title`)?`Choose your professional title or academic prefix.`:null},me=e=>{let t=E[e.id]||(b[e.id]&&String(b[e.id]).startsWith(`http`)?b[e.id]:``),n=ue[e.id],i=oe[e.id]||`file`,a=S===e.id||w===e.id,o=ce[e.id]||``,s=o.trim()?o.trim().split(/\s+/).length:0,c=!!e.word_limit&&s>e.word_limit;return(0,r.jsx)(`div`,{className:`space-y-2 mt-2`,children:(0,r.jsxs)(`div`,{part:`upload`,className:`p-4 sm:p-5 rounded-2xl border border-dashed transition-all ${f?`bg-zinc-850/80 border-zinc-700 hover:border-zinc-600`:`bg-slate-50 border-slate-300 hover:border-[color-mix(in_srgb,var(--vx-accent)_45%,transparent)]`}`,children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-3 flex-wrap`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,r.jsx)(`div`,{className:`w-10 h-10 rounded-xl flex items-center justify-center shrink-0 border`,style:{backgroundColor:f?`rgba(255,255,255,0.06)`:`color-mix(in srgb, ${M} 10%, white)`,borderColor:f?`rgba(255,255,255,0.12)`:`color-mix(in srgb, ${M} 25%, white)`,color:M},children:(0,r.jsx)(V,{size:18})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`p`,{className:`text-xs font-bold ${f?`text-zinc-200`:`text-gray-900`}`,children:e.label}),(0,r.jsx)(`p`,{className:`text-2xs font-medium ${f?`text-zinc-400`:`text-gray-500`}`,children:t?`Document attached successfully`:n?`Text submitted successfully`:i===`file`?`Click to choose or upload your document (PDF, JPG, PNG)`:`Enter your text below`})]})]}),(0,r.jsx)(`button`,{type:`button`,disabled:a,onClick:()=>A(t=>({...t,[e.id]:i===`file`?`text`:`file`})),className:`flex items-center gap-1 text-2xs font-semibold px-2.5 py-1 rounded-lg border cursor-pointer transition-colors hover:opacity-80 disabled:opacity-50 shrink-0`,style:{color:M,borderColor:`color-mix(in srgb, ${M} 35%, transparent)`},children:i===`file`?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(ve,{size:11}),` Send text only`]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(Xe,{size:11}),` Send file`]})})]}),i===`file`?(0,r.jsxs)(`div`,{className:`flex items-center gap-2 flex-wrap mt-3`,children:[(0,r.jsxs)(`label`,{className:`cursor-pointer relative`,children:[(0,r.jsx)(`input`,{type:`file`,className:`hidden`,style:{display:`none`},tabIndex:-1,disabled:a,onChange:t=>{let n=t.target.files?.[0];n&&P(e.id,n),t.target.value=``}}),(0,r.jsxs)(`div`,{className:`flex items-center gap-1.5 py-2 px-3.5 rounded-xl text-xs font-semibold border transition-all shadow-2xs ${f?`border-zinc-700 hover:border-zinc-600 text-zinc-200 bg-zinc-800 hover:bg-zinc-750`:`border-slate-200 hover:border-slate-300 text-slate-700 bg-white hover:bg-slate-50`}`,children:[(0,r.jsx)(Xe,{size:14,style:{color:M}}),(0,r.jsx)(`span`,{children:S===e.id?`Uploading...`:t?`Replace File`:`Choose File`})]})]}),t&&typeof t==`string`&&t.trim()!==``&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`button`,{type:`button`,onClick:()=>window.open(t,`_blank`,`noopener,noreferrer`),className:`flex items-center gap-1.5 py-2 px-3.5 rounded-xl text-xs font-semibold text-white shadow-xs transition-opacity hover:opacity-90 shrink-0 cursor-pointer`,style:{backgroundColor:M},title:`Open file in new tab`,children:[(0,r.jsx)(ve,{size:13}),(0,r.jsx)(`span`,{children:`View`}),(0,r.jsx)(_e,{size:11})]}),(0,r.jsxs)(`button`,{type:`button`,disabled:w===e.id||S===e.id,onClick:()=>F(e.id),className:`flex items-center gap-1 py-2 px-3 rounded-xl text-xs font-semibold border transition-colors cursor-pointer ${f?`border-red-900/60 bg-red-950/50 text-red-400 hover:bg-red-900/60`:`border-red-200 bg-red-50 text-red-600 hover:bg-red-100`}`,title:`Delete uploaded file`,children:[(0,r.jsx)(Je,{size:13}),(0,r.jsx)(`span`,{children:w===e.id?`Deleting...`:`Delete`})]})]})]}):(0,r.jsxs)(`div`,{className:`mt-3 pt-3 border-t space-y-2 ${f?`border-zinc-800`:`border-slate-200`}`,children:[(0,r.jsx)(`textarea`,{part:`input textarea`,rows:3,disabled:a||!!n,value:n??o,onChange:t=>j(n=>({...n,[e.id]:t.target.value})),placeholder:`Enter your answer...`,className:`w-full px-3 py-2 text-sm rounded-xl border focus:outline-none transition-all disabled:opacity-70 ${f?`bg-zinc-900 border-zinc-700 text-white placeholder-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`}),(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-2`,children:[e.word_limit?(0,r.jsxs)(`span`,{className:`text-2xs font-medium ${c?`text-red-500`:f?`text-zinc-500`:`text-gray-500`}`,children:[s,`/`,e.word_limit,` words`]}):(0,r.jsx)(`span`,{}),n?(0,r.jsxs)(`button`,{type:`button`,disabled:a,onClick:()=>F(e.id),className:`flex items-center gap-1 py-2 px-3 rounded-xl text-xs font-semibold border transition-colors cursor-pointer ${f?`border-red-900/60 bg-red-950/50 text-red-400 hover:bg-red-900/60`:`border-red-200 bg-red-50 text-red-600 hover:bg-red-100`}`,children:[(0,r.jsx)(Je,{size:13}),(0,r.jsx)(`span`,{children:w===e.id?`Clearing...`:`Clear & Re-enter`})]}):(0,r.jsxs)(`button`,{type:`button`,disabled:a||!o.trim(),onClick:()=>fe(e.id,o),style:{backgroundColor:M},className:`flex items-center gap-1.5 px-4 py-2 rounded-xl text-xs font-bold text-white shadow-sm hover:opacity-90 transition-all cursor-pointer disabled:opacity-50`,children:[(0,r.jsx)(Xe,{size:13}),(0,r.jsx)(`span`,{children:S===e.id?`Submitting...`:`Submit Text`})]})]})]}),t&&(0,r.jsxs)(`div`,{className:`mt-2.5 pt-2 border-t text-2xs truncate flex items-center gap-1.5 ${f?`border-zinc-800 text-zinc-300`:`border-gray-200 text-gray-700 font-medium`}`,children:[(0,r.jsx)(se,{size:12,className:`text-emerald-500 shrink-0`}),(0,r.jsxs)(`span`,{className:`truncate`,children:[`Attached: `,t]})]}),re&&ae===e.id&&(0,r.jsx)(`div`,{className:`text-xs text-red-500 mt-2 font-medium`,children:re})]})})},he=e=>{if(!e)return null;let t=b[e.id]??``,n=L(e),i=e.type===`email`||(e.label||``).toLowerCase().includes(`email`),a=(e.label||``).toLowerCase().includes(`name`),o=`vx-field-${e.id}`,s=`w-full px-4 py-3 text-[15px] font-medium rounded-xl border transition-all focus:outline-none ${f?`bg-zinc-900 border-zinc-700 text-white placeholder:text-zinc-500 hover:border-zinc-600 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_20%,transparent)]`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 hover:border-slate-300 shadow-[0_1px_2px_rgba(15,23,42,0.04)] focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`;return(0,r.jsxs)(`div`,{part:`field`,className:`px-5 sm:px-8 py-5 sm:py-6`,children:[(0,r.jsx)(`div`,{className:`flex items-center justify-between gap-2 mb-1`,children:(0,r.jsxs)(`label`,{part:`field-label`,htmlFor:o,className:`block text-sm font-semibold ${f?`text-zinc-100`:`text-slate-900`}`,children:[e.label,e.required&&(0,r.jsx)(`span`,{className:`text-red-500 font-semibold ml-0.5`,children:`*`})]})}),n&&(0,r.jsx)(`p`,{part:`field-description`,className:`text-xs leading-relaxed mb-3 ${f?`text-zinc-400`:`text-slate-500`}`,children:n}),!n&&(0,r.jsx)(`div`,{className:`h-1.5`}),e.type===`select`?(0,r.jsxs)(`div`,{className:`relative`,children:[(0,r.jsxs)(`select`,{part:`input select`,id:o,required:e.required,value:t,onChange:t=>N(e.id,t.target.value),className:`${s} pr-10 appearance-none cursor-pointer`,children:[(0,r.jsx)(`option`,{value:``,className:f?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:e.placeholder||`Select ${e.label}...`}),(e.options||[]).map(e=>(0,r.jsx)(`option`,{value:e,className:f?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:e},e))]}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 right-0 flex items-center pr-3.5 pointer-events-none ${f?`text-zinc-400`:`text-slate-400`}`,children:(0,r.jsx)(le,{size:16})})]}):e.type===`file`?me(e):(0,r.jsx)(`input`,{part:`input`,id:o,type:e.type===`phone`?`tel`:e.type===`email`?`email`:e.type===`number`?`number`:`text`,required:e.required,value:t,placeholder:e.placeholder||(i?`Enter your email address`:a?`Your full name`:`Enter your ${e.label.toLowerCase()}`),onChange:t=>N(e.id,t.target.value),className:s})]},e.id)},ge=e=>{e.preventDefault();for(let e of pe)if(e.type===`file`&&e.required&&!b[e.id]){O(`Please upload ${e.label||`a file`}`),k(e.id);return}t(b)},R=v?.type||v?.name||v?.label||(y?`Abstract Submission Form`:`Registration Form`),z=v?Number(v.price)>0?[v.currency,Number(v.price).toLocaleString()].filter(Boolean).join(` `):`Free`:null;return(0,r.jsxs)(`div`,{part:`form-page`,className:`w-full flex-1 flex flex-col relative ${f?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`}`,style:_,children:[(0,r.jsx)(`div`,{part:`form-header`,className:`sticky top-0 z-30 px-4 sm:px-6 py-3 border-b backdrop-blur-xl transition-colors ${f?`bg-zinc-900/85 border-zinc-800`:`bg-white/85 border-slate-200/80`}`,children:(0,r.jsxs)(`div`,{className:`max-w-3xl mx-auto flex items-center justify-between gap-3`,children:[(0,r.jsxs)(`button`,{part:`button button-secondary back-button`,type:`button`,onClick:i,className:`inline-flex items-center gap-2 text-sm font-semibold rounded-full pl-2.5 pr-4 py-2 border transition-colors cursor-pointer ${f?`bg-zinc-800 border-zinc-700 hover:bg-zinc-700 text-zinc-200`:`bg-white border-slate-200 hover:bg-slate-50 text-slate-700 shadow-[0_1px_2px_rgba(15,23,42,0.04)]`}`,children:[(0,r.jsx)(ne,{size:16}),(0,r.jsx)(`span`,{children:`All forms`})]}),(0,r.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[v&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`span`,{part:`form-type-name`,title:R,className:`hidden sm:inline-block truncate max-w-[16rem] text-xs font-semibold px-3 py-1.5 rounded-full ${f?`bg-zinc-800 text-zinc-200`:`bg-slate-100 text-slate-700`}`,children:R}),!y&&(0,r.jsx)(`span`,{part:`form-type-price`,className:`shrink-0 text-xs font-bold px-3 py-1.5 rounded-full tabular-nums`,style:{backgroundColor:`color-mix(in srgb, ${M} 12%, transparent)`,color:M},children:z})]}),o===`popup`&&(0,r.jsxs)(`div`,{className:`flex items-center gap-1.5 ml-2 border-l pl-2 ${f?`border-zinc-700`:`border-slate-200`}`,children:[(0,r.jsx)(`button`,{onClick:c,className:`p-1.5 opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,title:s?`Minimize`:`Expand`,children:s?(0,r.jsx)(Me,{size:16}):(0,r.jsx)(je,{size:16})}),(0,r.jsx)(`button`,{onClick:l,className:`p-1.5 opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:(0,r.jsx)(et,{size:18})})]})]})]})}),(0,r.jsx)(`div`,{className:`w-full flex-1 overflow-y-auto`,children:(0,r.jsxs)(`form`,{part:`form`,onSubmit:ge,className:`max-w-3xl mx-auto w-full px-4 sm:px-6 py-8 sm:py-10 space-y-5`,children:[(0,r.jsxs)(`div`,{part:`form-intro`,className:`px-1`,children:[(0,r.jsx)(`p`,{className:`text-xs font-semibold uppercase tracking-wider`,style:{color:M},children:y?`Abstract submission`:`Registration form`}),(0,r.jsx)(`h2`,{part:`form-title`,className:`mt-1.5 text-2xl sm:text-3xl font-bold tracking-tight ${f?`text-white`:`text-slate-900`}`,style:Q,children:R})]}),d&&Object.keys(d).length>0&&(0,r.jsxs)(`div`,{className:`text-sm px-4 py-3 rounded-2xl flex items-center gap-2.5 ${f?`bg-emerald-950/50 text-emerald-300 ring-1 ring-inset ring-emerald-900`:`bg-emerald-50 text-emerald-800 ring-1 ring-inset ring-emerald-200/80`}`,children:[(0,r.jsx)(se,{size:16,className:`shrink-0`}),(0,r.jsx)(`span`,{className:`font-medium`,children:`We restored your previously saved progress.`})]}),(0,r.jsxs)(`div`,{part:`notice`,className:`rounded-2xl p-4 flex items-start gap-3`,style:{backgroundColor:`color-mix(in srgb, ${M} ${f?14:7}%, transparent)`,boxShadow:`inset 0 0 0 1px color-mix(in srgb, ${M} 20%, transparent)`},children:[(0,r.jsx)(`div`,{className:`shrink-0 mt-0.5`,style:{color:M},children:(0,r.jsx)(G,{size:18})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{part:`notice-title`,className:`text-xs font-bold uppercase tracking-wider`,style:{color:M},children:`Before you submit`}),(0,r.jsxs)(`p`,{className:`text-sm mt-0.5 leading-relaxed ${f?`text-zinc-300`:`text-slate-600`}`,children:[`Ensure you are a registered delegate. Fields marked `,(0,r.jsx)(`span`,{className:`text-red-500 font-semibold`,children:`*`}),` are required.`]})]})]}),(0,r.jsx)(`div`,{part:`form-card`,className:`rounded-3xl border overflow-hidden divide-y ${f?`bg-zinc-900 border-zinc-800 divide-zinc-800`:`bg-white border-slate-200/80 divide-slate-100 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_-16px_rgba(15,23,42,0.12)]`}`,children:pe.map(e=>he(e))}),(0,r.jsxs)(`div`,{className:`pt-2 pb-10`,children:[(0,r.jsxs)(`button`,{part:`button button-primary submit-button`,type:`submit`,disabled:S!==null||w!==null,style:{background:`linear-gradient(135deg, ${M}, color-mix(in srgb, ${M} 80%, black))`,boxShadow:`0 12px 28px -12px color-mix(in srgb, ${M} 70%, transparent)`},className:`group w-full h-14 px-8 text-base font-semibold text-white rounded-2xl hover:brightness-110 active:scale-[0.99] transition-all cursor-pointer flex items-center justify-center gap-2.5 disabled:opacity-50 disabled:cursor-not-allowed`,children:[(0,r.jsx)(`span`,{children:y?`Submit Abstract`:`Complete Registration`}),(0,r.jsx)(ie,{size:18,className:`transition-transform group-hover:translate-x-0.5`})]}),(0,r.jsx)(`p`,{className:`mt-3 text-center text-xs ${f?`text-zinc-500`:`text-slate-400`}`,children:`Please review your details before submitting.`})]})]})})]})};function nt(e,t){if(!e)return``;if(/^field_\d+/i.test(e)&&t&&typeof t==`string`){let e=t.trim().toLowerCase().replace(/[^a-z0-9]+/g,`_`).replace(/^_+|_+$/g,``);if(e)return e}return e}function rt(e,t=``){if(e&&typeof e==`string`){let t=e.trim().toLowerCase().replace(/[^a-z0-9]+/g,`_`).replace(/^_+|_+$/g,``);if(t)return t}return nt(t,e)||t}var it=({apiClient:e,storage:t,logger:i,primaryColor:a,isDark:o=!1,isWidgetPage:s=!1,onEvent:c,onError:l})=>{let[u,d]=(0,n.useState)(()=>t.getToken()?`profile`:`login`),[f,p]=(0,n.useState)(!1),[m,h]=(0,n.useState)(!1),[g,_]=(0,n.useState)(null),[v,y]=(0,n.useState)(null),[b,x]=(0,n.useState)(null),[S,C]=(0,n.useState)(``),[w,ee]=(0,n.useState)(``),[te,T]=(0,n.useState)(``),[E,D]=(0,n.useState)(``),[re,O]=(0,n.useState)(``),[k,A]=(0,n.useState)(``),[ce,j]=(0,n.useState)(``),[de,N]=(0,n.useState)(!1),[P,F]=(0,n.useState)(null),[fe,I]=(0,n.useState)({}),[pe,L]=(0,n.useState)([]),[he,R]=(0,n.useState)({}),[z,B]=(0,n.useState)(null),[H,ye]=(0,n.useState)(null),[W,G]=(0,n.useState)(null),[K,q]=(0,n.useState)(!1),[Se,we]=(0,n.useState)(!1),[Y,De]=(0,n.useState)({}),[ke,X]=(0,n.useState)(!1),[je,Z]=(0,n.useState)(null),[Me,Ne]=(0,n.useState)({}),[Pe,Fe]=(0,n.useState)({});(0,n.useEffect)(()=>{let e=t.getToken();e&&Le(e)},[]);let Le=async n=>{p(!0),y(null);try{let r=await e.portalGetProfile(n),a=r?.data||r||{};F(a);let o=a.registration||{},s=o.custom_data||{},l=o.email||a.email||``,u=null;if(l)try{let t=await e.getDraftByEmail(l);u=t?.data||t,i.log(`Portal resume draft data loaded by email:`,u)}catch(e){i.log(`No draft found for email in portal`,e)}else{let n=t.getXrefId();if(n)try{let t=await e.getDraft(n);u=t?.data||t}catch{}}let f=u?.custom_data||{};o.name?T(o.name):u?.name?T(u.name):a.name&&T(a.name);let p=0,m={},h=[...a.editable_fields||[]];F({...a,editable_fields:h});let g={};o.asset_id&&(g.asset_id=String(o.asset_id)),o.photo_id&&(g.photo_id=String(o.photo_id)),s.asset_id&&(g.asset_id=String(s.asset_id)),s.photo_id&&(g.photo_id=String(s.photo_id)),a.asset_id&&(g.asset_id=String(a.asset_id)),h.forEach(e=>{if(e.type===`file`){let t=o[`${e.id}_asset_id`]||s[`${e.id}_asset_id`]||o.asset_id||s.asset_id||a.asset_id;t&&(g[e.id]=String(t))}}),R(e=>({...g,...e}));let _=o.asset_id||o.photo_id||s.asset_id||s.photo_id||a.asset_id;_&&B(String(_)),h.length>0?h.forEach(e=>{let t=e.label||e.name||e.id,n=nt(e.id,e.label),r=rt(e.label,e.id),i=``;if(t&&o[t]!==void 0&&o[t]!==null&&o[t]!==``?i=o[t]:o[r]!==void 0&&o[r]!==null&&o[r]!==``?i=o[r]:o[n]!==void 0&&o[n]!==null&&o[n]!==``?i=o[n]:o[e.id]!==void 0&&o[e.id]!==null&&o[e.id]!==``?i=o[e.id]:t&&s[t]!==void 0&&s[t]!==null&&s[t]!==``?i=s[t]:s[r]!==void 0&&s[r]!==null&&s[r]!==``?i=s[r]:s[n]!==void 0&&s[n]!==null&&s[n]!==``?i=s[n]:s[e.id]!==void 0&&s[e.id]!==null&&s[e.id]!==``&&(i=s[e.id]),u){let t=u[n]??u[e.id]??f[n]??f[e.id]??(e.id===`salutation`?u.salutation||u.title:void 0)??(e.id===`name`?u.name||u.fullName||u.full_name:void 0)??(e.id===`email`?u.email:void 0)??(e.id===`phone`?u.phone||u.mobile||u.phoneNumber:void 0);t!=null&&t!==``&&(i=t,p++)}m[e.id]=i}):Object.entries(a).forEach(([e,t])=>{e.toLowerCase()!==`token`&&(m[e]=t)}),I(m),p>0&&q(!0);let v=(a.addons?.items||[]).filter(e=>e.purchased).map(e=>e.name);u?.selected_items&&Array.isArray(u.selected_items)&&u.selected_items.forEach(e=>{let t=typeof e==`string`?e:e?.name;t&&!v.includes(t)&&v.push(t)}),L(v),d(`profile`),c?.(`attendee_profile_loaded`,{profile:a,draft:u})}catch(e){i.error(`Failed to load profile`,e),t.clearToken(),d(`login`)}finally{p(!1)}},ze=async n=>{if(n.preventDefault(),!S.trim()||!w){y(`Please enter both your identifier and password.`);return}p(!0),y(null),x(null);try{let n=await e.portalLogin({identifier:S.trim(),password:w}),r=n?.data?.token||n?.token;if(!r)throw Error(n?.message||`No authentication token received.`);(n?.data?.name||n?.name)&&T(n.data?.name||n.name),t.setToken(r),c?.(`attendee_logged_in`,{identifier:S,response:n}),await Le(r)}catch(e){i.error(`Login failed`,e);let t=e.message||`Login failed. Please check your credentials.`;y(t),l?.({type:`login_error`,message:t,error:e})}finally{p(!1)}},Ve=async t=>{t.preventDefault();let n=(E||S).trim();if(!n){y(`Please enter your registration number or email to receive a code.`);return}N(!0),y(null),x(null);try{await e.portalRequestPasswordReset(n),x(`A verification code has been sent to your registered email.`),c?.(`password_reset_code_requested`,{identifier:n}),d(`reset`)}catch(e){i.error(`Failed to send reset code`,e);let t=e.message||`Failed to send code. Please verify your identifier.`;y(t),l?.({type:`portal_error`,message:t,error:e})}finally{N(!1)}},He=async n=>{n.preventDefault();let r=(E||S).trim();if(!r){y(`Please enter your registration number or email.`);return}if(!re.trim()){y(`Please enter the verification code sent to your email.`);return}if(!k){y(`Please enter a new password.`);return}if(k!==ce){y(`New password and confirm password do not match.`);return}p(!0),y(null),x(null);try{let n=await e.portalConfirmPasswordReset({identifier:r,code:re.trim(),new_password:k}),i=n?.data?.token||n?.token;(n?.data?.name||n?.name)&&T(n.data?.name||n.name),c?.(`password_reset_success`,{identifier:r,response:n}),i?(t.setToken(i),O(``),A(``),j(``),await Le(i)):(C(r),ee(``),O(``),A(``),j(``),d(`login`),x(`Password updated successfully! Please login with your new password.`))}catch(e){i.error(`Password reset failed`,e);let t=e.message||`Failed to update password. Please check the code.`;y(t),l?.({type:`portal_error`,message:t,error:e})}finally{p(!1)}},Ue=()=>{t.clearToken(),F(null),I({}),L([]),R({}),B(null),G(null),T(``),ee(``),d(`login`),x(`Logged out successfully.`),c?.(`attendee_logged_out`,{})},Ge=async(n,r)=>{let a=t.getToken();if(!a){y(`Session expired. Please log in again.`);return}_(n),y(null),x(null);try{let t=await e.uploadFile(r,a),i=t?.data?.serve_url||t?.serve_url||``,o=t?.data?.asset_id||t?.asset_id;if(!o&&!i)throw Error(`Upload response missing asset_id`);i&&I(e=>({...e,[n]:i})),o&&(R(e=>({...e,[n]:String(o)})),B(String(o))),x(`File "${r.name}" uploaded successfully!`),c?.(`portal_file_uploaded`,{fieldId:n,serveUrl:i,assetId:o,response:t})}catch(e){i.error(`File upload failed`,e);let t=e.message||`File upload failed. Please try again.`;y(t),l?.({type:`file_upload_error`,message:t,error:e})}finally{_(null)}},qe=async n=>{let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}let a=fe[n],o=(a&&typeof a==`object`?a.id:null)||he[n]||z;ye(n),y(null),x(null);try{o&&(i.log(`Deleting asset ${o} for field ${n}...`),await e.portalDeleteFile(r,o),i.log(`Asset ${o} deleted successfully.`),c?.(`portal_file_deleted`,{assetId:o,fieldId:n})),I(e=>({...e,[n]:``})),R(e=>{let t={...e};return delete t[n],t}),z===o&&B(null),x(`File removed successfully.`)}catch(e){i.error(`Failed to delete file`,e);let t=e.message||`Failed to delete file. Please try again.`;y(t),l?.({type:`file_delete_error`,message:t,error:e})}finally{ye(null)}},Ye=(e,t)=>{t||L(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e])},Ze=async n=>{n.preventDefault();let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}h(!0),y(null),x(null);try{let t=P?.editable_fields||[],n={...P?.registration?.custom_data||{}},i={};t.forEach(e=>{let t=fe[e.id],r=e.label||e.name||e.id,a=rt(e.label,e.id),o=nt(e.id,e.label);e.type===`file`?(delete n[r],delete n[a],delete n[o],delete n[e.id]):e.builtin?(i[o]=t,o!==e.id&&(i[e.id]=t)):(n[o]=t,i[o]=t,o!==e.id&&(n[e.id]=t,i[e.id]=t))}),i.custom_data=n,i.addons=pe;let a=await e.portalUpdateProfile(r,i);c?.(`attendee_profile_updated`,{payload:i,response:a});let o=a?.data?.addon_checkout?.payment_url||a?.addon_checkout?.payment_url||a?.data?.payment_url||a?.payment_url;if(o&&typeof o==`string`&&o.trim()!==``){G(o),x(`Add-ons updated! Opening payment page in a new tab...`),c?.(`addon_payment_opened`,{payment_url:o}),window.open(o,`_blank`,`noopener,noreferrer`),await Le(r);return}x(`Profile updated successfully!`),await Le(r)}catch(e){i.error(`Failed to update profile`,e);let t=e.message||`Failed to update profile. Please try again.`;y(t),l?.({type:`profile_update_error`,message:t,error:e})}finally{h(!1)}},$e=()=>{let e=P?.review_submission;if(!e)return;let t=e.custom_data||{},n={},r={};(e.editable_fields||[]).forEach(i=>{i.id===`name`?n[i.id]=e.name||``:i.id===`phone`?n[i.id]=e.phone||``:i.id===`registration_type`?n[i.id]=e.registration_type||``:n[i.id]=t[i.id]??``,i.type===`file`&&(r[i.id]=i.current_file?.text||``)}),De(n),Fe(r),Ne({}),we(!0)},et=e=>{if(Me[e.id])return Me[e.id];let t=e.current_file;return t&&!t.serve_url&&t.text?`text`:`file`},tt=async(n,r)=>{let a=t.getToken();if(!a){y(`Session expired. Please log in again.`);return}let o=(P?.review_submission?.editable_fields||[]).find(e=>e.id===n),s=o?.current_file?.id;Z(n),y(null),x(null);try{let t=await e.uploadFile(r,a,null,o?.label),l=t?.data?.asset_id||t?.asset_id;if(!l)throw Error(`Upload response missing asset_id`);De(e=>({...e,[n]:String(l)})),x(`File "${r.name}" uploaded successfully!`),c?.(`portal_submission_file_uploaded`,{fieldId:n,assetId:l,response:t}),s&&s!==String(l)&&e.deleteFile(s,a).catch(e=>i.error(`Could not delete replaced submission file`,e))}catch(e){i.error(`Submission file upload failed`,e);let t=e.message||`File upload failed. Please try again.`;y(t),l?.({type:`file_upload_error`,message:t,error:e})}finally{Z(null)}},it=async n=>{let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}let a=(Pe[n]||``).trim();if(!a)return;let o=(P?.review_submission?.editable_fields||[]).find(e=>e.id===n),s=o?.current_file?.id;Z(n),y(null),x(null);try{let t=await e.submitTextAnswer(a,r,null,o?.label),l=t?.data?.asset_id||t?.asset_id;if(!l)throw Error(`Submission response missing asset_id`);De(e=>({...e,[n]:String(l)})),x(`Text answer saved!`),c?.(`portal_submission_text_saved`,{fieldId:n,assetId:l}),s&&s!==String(l)&&e.deleteFile(s,r).catch(e=>i.error(`Could not delete replaced submission answer`,e))}catch(e){i.error(`Submission text answer failed`,e);let t=e.message||`Could not save your answer. Please try again.`;y(t),l?.({type:`submission_text_error`,message:t,error:e})}finally{Z(null)}},at=async n=>{n.preventDefault();let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}X(!0),y(null),x(null);try{let t=await e.portalUpdateSubmission(r,Y),n=t?.data||t;F(e=>({...e,review_submission:n})),we(!1),x(`Your submission was updated successfully!`),c?.(`attendee_submission_updated`,{payload:Y,response:t})}catch(e){i.error(`Failed to update submission`,e);let t=e.message||`Failed to update submission. Please try again.`;y(t),l?.({type:`submission_update_error`,message:t,error:e})}finally{X(!1)}},ot=()=>(0,r.jsxs)(`div`,{className:`absolute inset-0 pointer-events-none overflow-hidden z-0 select-none`,children:[(0,r.jsx)(`div`,{className:`absolute inset-0 pointer-events-none`,style:{background:o?`linear-gradient(180deg, rgba(9,9,11,0.5) 0%, rgba(9,9,11,0.7) 100%)`:`linear-gradient(180deg, rgba(255,255,255,0.08) 0%, rgba(248,250,252,0.2) 100%)`}}),(0,r.jsx)(`div`,{className:`absolute -top-16 -right-16 w-72 h-72 rounded-full blur-3xl pointer-events-none transition-all duration-700`,style:{background:`radial-gradient(circle, color-mix(in srgb, ${a} 16%, transparent) 0%, color-mix(in srgb, ${a} 3%, transparent) 60%, transparent 80%)`}}),(0,r.jsx)(`div`,{className:`absolute top-1/3 -left-20 w-80 h-80 rounded-full blur-3xl pointer-events-none transition-all duration-700`,style:{background:`radial-gradient(circle, color-mix(in srgb, ${a} 12%, transparent) 0%, color-mix(in srgb, ${a} 2%, transparent) 55%, transparent 75%)`}}),(0,r.jsx)(`div`,{className:`absolute -bottom-10 right-1/4 w-64 h-64 rounded-full blur-3xl pointer-events-none transition-all duration-700`,style:{background:`radial-gradient(circle, color-mix(in srgb, ${a} 9%, transparent) 0%, transparent 70%)`}}),!o&&(0,r.jsx)(`div`,{className:`absolute inset-0 opacity-[0.03]`,style:{backgroundImage:`radial-gradient(${a} 1px, transparent 1px)`,backgroundSize:`16px 16px`}})]}),st=e=>{let t=(e.label||e.id||``).toLowerCase(),n=e.type;return n===`email`||t.includes(`email`)||t.includes(`mail`)?(0,r.jsx)(Oe,{size:13,className:`shrink-0`,style:{color:a}}):n===`phone`||t.includes(`phone`)||t.includes(`mobile`)||t.includes(`contact`)?(0,r.jsx)(Re,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`salutation`)||t.includes(`title`)||t.includes(`prefix`)?(0,r.jsx)(We,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`name`)||t.includes(`attendee`)?(0,r.jsx)(Qe,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`designat`)||t.includes(`role`)||t.includes(`position`)||t.includes(`profession`)?(0,r.jsx)(ae,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`specialis`)||t.includes(`specializ`)||t.includes(`department`)||t.includes(`degree`)?(0,r.jsx)(U,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`organi`)||t.includes(`institute`)||t.includes(`hospital`)||t.includes(`company`)||t.includes(`college`)?(0,r.jsx)(oe,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`city`)||t.includes(`state`)||t.includes(`country`)||t.includes(`address`)?(0,r.jsx)(Ae,{size:13,className:`shrink-0`,style:{color:a}}):n===`file`?(0,r.jsx)(V,{size:13,className:`shrink-0`,style:{color:a}}):(0,r.jsx)(ve,{size:13,className:`shrink-0`,style:{color:a}})},ct=(e,t=`w-full`,n=[])=>{if(!e)return null;let i=n.includes(e.id)||n.includes(nt(e.id,e.label)),a=fe[e.id]??``,s=`vx-profile-${e.id}`,c=`w-full h-11 px-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${i?o?`bg-zinc-800/60 text-zinc-500 border-zinc-800 cursor-not-allowed`:`bg-slate-50 text-slate-500 border-slate-200 cursor-not-allowed`:o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500 hover:border-zinc-600 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_20%,transparent)]`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 hover:border-slate-300 shadow-[0_1px_2px_rgba(15,23,42,0.04)] focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`;return(0,r.jsxs)(`div`,{className:`${t} px-2 mb-4`,children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-2 mb-1.5`,children:[(0,r.jsxs)(`label`,{part:`field-label`,htmlFor:s,className:`flex items-center gap-1.5 text-[13px] font-semibold ${o?`text-zinc-200`:`text-slate-800`}`,children:[(0,r.jsx)(`span`,{className:o?`text-zinc-500`:`text-slate-400`,children:st(e)}),(0,r.jsx)(`span`,{children:e.label}),e.required&&(0,r.jsx)(`span`,{className:`text-red-500 font-semibold`,children:`*`})]}),i?(0,r.jsxs)(`span`,{className:`flex items-center gap-1 text-[10px] font-semibold px-2 py-0.5 rounded-full ${o?`text-zinc-400 bg-zinc-800`:`text-slate-500 bg-slate-100`}`,children:[(0,r.jsx)(Ce,{size:10}),` Locked`]}):null]}),e.type===`select`?(0,r.jsxs)(`div`,{className:`relative`,children:[(0,r.jsxs)(`select`,{part:`input select`,id:s,disabled:i,value:a,onChange:t=>I({...fe,[e.id]:t.target.value}),className:`${c} pr-9 appearance-none cursor-pointer flex items-center`,children:[(0,r.jsxs)(`option`,{value:``,className:o?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:[`Select `,e.label,`...`]}),(e.options||[]).map(e=>(0,r.jsx)(`option`,{value:e,className:o?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:e},e))]}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 right-0 flex items-center pr-3 pointer-events-none ${o?`text-zinc-400`:`text-slate-400`}`,children:(0,r.jsx)(le,{size:15})})]}):e.type===`file`?lt(e,i,a):(0,r.jsx)(`input`,{part:`input`,id:s,type:e.type===`phone`?`tel`:e.type===`email`?`email`:`text`,disabled:i,value:a,placeholder:e.placeholder||`Enter ${e.label.toLowerCase()}`,onChange:t=>I({...fe,[e.id]:t.target.value}),className:c})]},e.id)},lt=(e,t,n)=>{let i=g===e.id,s=e.label||e.name||e.id,c=typeof n==`string`?n:n?.serve_url||n?.url||``,l=typeof n==`string`?n:n?.file_name||c;return(0,r.jsx)(`div`,{className:`space-y-2`,children:(0,r.jsxs)(`div`,{part:`upload`,className:`p-4 rounded-2xl border border-dashed transition-all ${o?`bg-zinc-950/60 border-zinc-700 hover:border-zinc-600`:`bg-slate-50 border-slate-300 hover:border-[color-mix(in_srgb,var(--vx-accent)_45%,transparent)]`}`,children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-3 flex-wrap`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2.5`,children:[(0,r.jsx)(`div`,{className:`w-8 h-8 rounded-lg flex items-center justify-center shrink-0 border`,style:{backgroundColor:o?`rgba(255,255,255,0.06)`:`color-mix(in srgb, ${a} 8%, white)`,borderColor:o?`rgba(255,255,255,0.12)`:`color-mix(in srgb, ${a} 20%, white)`,color:a},children:(0,r.jsx)(V,{size:16})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`p`,{className:`text-xs font-bold ${o?`text-zinc-200`:`text-gray-900`}`,children:s}),(0,r.jsx)(`p`,{className:`text-2xs font-medium ${o?`text-zinc-400`:`text-gray-500`}`,children:n?`Document attached`:`Choose a file to upload`})]})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-2`,children:c.trim()!==``&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`a`,{href:c,target:`_blank`,rel:`noopener noreferrer`,className:`flex items-center gap-1.5 py-1.5 px-3 rounded-lg text-xs font-semibold text-white shadow-xs transition-opacity hover:opacity-90 shrink-0`,style:{backgroundColor:a},title:`Open file in new tab`,children:[(0,r.jsx)(ve,{size:13}),(0,r.jsx)(`span`,{children:`View`}),(0,r.jsx)(_e,{size:11})]}),!t&&(0,r.jsxs)(`button`,{type:`button`,disabled:H===e.id||i,onClick:()=>qe(e.id),className:`flex items-center gap-1 py-1.5 px-2.5 rounded-lg text-xs font-semibold border backdrop-blur-sm transition-colors cursor-pointer ${o?`border-red-900/60 bg-red-950/50 text-red-400 hover:bg-red-900/60`:`border-red-200 bg-red-50/80 text-red-600 hover:bg-red-100`}`,title:`Remove file`,children:[(0,r.jsx)(Je,{size:13}),(0,r.jsx)(`span`,{children:H===e.id?`Deleting...`:`Delete`})]})]})})]}),n&&(0,r.jsxs)(`div`,{className:`mt-2 pt-2 border-t text-2xs truncate flex items-center gap-1.5 ${o?`border-zinc-800 text-zinc-300`:`border-gray-200 text-gray-700 font-medium`}`,children:[(0,r.jsx)(se,{size:12,className:`text-emerald-500 shrink-0`}),(0,r.jsxs)(`span`,{className:`truncate`,children:[`Attached: `,l]})]}),!t&&(0,r.jsx)(`div`,{className:`mt-3 pt-3 border-t ${o?`border-zinc-800`:`border-slate-200`}`,children:(0,r.jsxs)(`label`,{className:`cursor-pointer relative`,children:[(0,r.jsx)(`input`,{type:`file`,className:`hidden`,style:{display:`none`},tabIndex:-1,disabled:i,onChange:t=>{let n=t.target.files?.[0];n&&Ge(e.id,n),t.target.value=``}}),(0,r.jsxs)(`div`,{className:`inline-flex items-center gap-1.5 py-1.5 px-3 rounded-lg text-xs font-semibold border transition-all shadow-2xs ${o?`border-zinc-700 hover:border-zinc-600 text-zinc-200 bg-zinc-800 hover:bg-zinc-750`:`border-gray-300 hover:border-gray-400 text-gray-800 bg-white hover:bg-gray-50`}`,children:[(0,r.jsx)(Xe,{size:13,style:{color:a}}),(0,r.jsx)(`span`,{children:i?`Uploading...`:n?`Replace File`:`Choose File`})]})]})})]})})};if(u===`profile`&&!P){let e=`vx-skeleton rounded-full`,t=`rounded-3xl border p-5 sm:p-6 ${o?`bg-zinc-900 border-zinc-800`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_-16px_rgba(15,23,42,0.12)]`}`;return(0,r.jsxs)(`div`,{role:`status`,"aria-live":`polite`,"aria-busy":`true`,className:`flex flex-col ${s?`w-full flex-1`:`h-full overflow-hidden min-h-0`} relative bg-transparent ${o?`text-white`:`text-slate-900`}`,children:[(0,r.jsx)(`span`,{className:`sr-only`,children:`Loading your profile…`}),ot(),(0,r.jsxs)(`div`,{className:`max-w-3xl mx-auto w-full px-4 sm:px-6 ${s?`py-8 sm:py-10`:`py-5`} space-y-5 relative z-10`,children:[(0,r.jsxs)(`div`,{className:t,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-4`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-12 h-12 sm:w-14 sm:h-14 rounded-2xl shrink-0`}),(0,r.jsxs)(`div`,{className:`flex-1 space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-5 w-48 max-w-full`}),(0,r.jsx)(`div`,{className:`${e} h-3 w-64 max-w-full`})]})]}),(0,r.jsx)(`div`,{className:`mt-5 pt-5 border-t grid grid-cols-2 sm:grid-cols-3 gap-4 ${o?`border-zinc-800`:`border-slate-100`}`,children:[0,1,2].map(t=>(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-2.5 w-20`}),(0,r.jsx)(`div`,{className:`${e} h-4 w-28`})]},t))})]}),(0,r.jsxs)(`div`,{className:t,children:[(0,r.jsx)(`div`,{className:`${e} h-4 w-32`}),(0,r.jsx)(`div`,{className:`mt-6 grid gap-4 md:grid-cols-2`,children:[0,1,2,3].map(t=>(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-3 w-24`}),(0,r.jsx)(`div`,{className:`vx-skeleton h-11 w-full rounded-xl`})]},t))})]})]})]})}if(u===`profile`){let e=P?.registration||{},t=P?.editable_fields||[],n=P?.locked_fields||[],i=Array.isArray(P?.payment)?P.payment:P?.payment?[P.payment]:[],c=i.filter(e=>e.state!==`not_required`),l=i[0],u=P?.addons?.items||[],d=P?.badge||null,f=P?.review_submission||null,p=te||`Attendee`,h=p.split(/\s+/).filter(Boolean).slice(0,2).map(e=>e[0]?.toUpperCase()).join(``)||`A`,_=`rounded-3xl border p-5 sm:p-6 ${o?`bg-zinc-900 border-zinc-800 text-white`:`bg-white border-slate-200/80 text-slate-900 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_-16px_rgba(15,23,42,0.12)]`}`,y=o?`text-zinc-400`:`text-slate-500`,x=`text-base font-semibold tracking-tight ${o?`text-white`:`text-slate-900`}`,S=[{label:`Registration no.`,value:e.registration_number||`N/A`,mono:!0},{label:`Ticket type`,value:e.registration_type||`N/A`},...l&&l.state!==`not_required`?[{label:`Payment`,value:`${l.state}${l.amount?` · ${[l.currency,l.amount].filter(Boolean).join(` `)}`:``}`,capitalize:!0}]:[]];return(0,r.jsxs)(`div`,{className:`flex flex-col ${s?`w-full flex-1`:`h-full overflow-hidden min-h-0`} relative bg-transparent ${o?`text-white`:`text-slate-900`}`,style:s?void 0:{overflow:`clip`},onScroll:s?void 0:e=>{e.currentTarget.scrollTop!==0&&(e.currentTarget.scrollTop=0),e.currentTarget.scrollLeft!==0&&(e.currentTarget.scrollLeft=0)},children:[ot(),(0,r.jsx)(`div`,{className:`${s?`w-full flex-1`:`flex-1 overflow-y-auto min-h-0 overscroll-contain`} relative z-10`,children:(0,r.jsxs)(`div`,{className:`max-w-3xl mx-auto w-full px-4 sm:px-6 ${s?`py-8 sm:py-10`:`py-5`} space-y-5`,children:[(0,r.jsxs)(`div`,{part:`portal-card profile-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 sm:gap-4 min-w-0`,children:[(0,r.jsx)(`div`,{className:`w-12 h-12 sm:w-14 sm:h-14 rounded-2xl flex items-center justify-center shrink-0 text-base sm:text-lg font-bold text-white`,style:{background:`linear-gradient(135deg, ${a}, color-mix(in srgb, ${a} 75%, black))`},"aria-hidden":`true`,children:h}),(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2 flex-wrap`,children:[(0,r.jsx)(`h3`,{part:`portal-title`,style:Q,className:`text-lg sm:text-xl font-bold tracking-tight break-words ${o?`text-white`:`text-slate-900`}`,children:p}),e.status&&(0,r.jsx)(`span`,{className:`px-2.5 py-0.5 rounded-full text-[11px] font-semibold capitalize ${o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`}`,children:e.status})]}),(0,r.jsx)(`p`,{className:`text-[13px] mt-0.5 ${y}`,children:`Manage your registration and details`})]})]}),(0,r.jsxs)(`button`,{part:`button button-secondary logout-button`,onClick:Ue,className:`shrink-0 inline-flex items-center justify-center gap-1.5 h-9 w-9 sm:w-auto sm:px-3.5 text-[13px] font-semibold rounded-full border transition-colors cursor-pointer ${o?`text-zinc-300 border-zinc-700 hover:bg-zinc-800 hover:text-red-300`:`text-slate-600 border-slate-200 bg-white hover:bg-red-50 hover:text-red-600 hover:border-red-200`}`,title:`Logout`,"aria-label":`Logout`,children:[(0,r.jsx)(Ee,{size:14}),(0,r.jsx)(`span`,{className:`hidden sm:inline`,children:`Logout`})]})]}),(0,r.jsx)(`dl`,{className:`mt-5 pt-5 border-t grid grid-cols-2 ${S.length===3?`sm:grid-cols-3`:`sm:grid-cols-2`} gap-4 ${o?`border-zinc-800`:`border-slate-100`}`,children:S.map(e=>(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsx)(`dt`,{className:`text-[11px] font-semibold uppercase tracking-wider ${o?`text-zinc-500`:`text-slate-400`}`,children:e.label}),(0,r.jsx)(`dd`,{className:`mt-1 text-sm font-semibold break-words ${e.mono?`font-mono`:``} ${e.capitalize?`capitalize`:``} ${o?`text-white`:`text-slate-900`}`,children:e.value})]},e.label))})]}),(0,r.jsxs)(`form`,{onSubmit:Ze,className:`space-y-5`,children:[t.length===0?(0,r.jsx)(`div`,{className:`${_} text-center text-sm ${y}`,children:`No editable fields configured.`}):(0,r.jsxs)(`div`,{part:`portal-card details-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-start justify-between gap-3 mb-5`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Your details`}),(0,r.jsx)(`p`,{className:`text-[13px] mt-0.5 ${y}`,children:`Keep your information up to date.`})]}),K&&(0,r.jsxs)(`span`,{className:`inline-flex items-center gap-1 text-[11px] font-semibold px-2.5 py-1 rounded-full shrink-0 ${o?`bg-emerald-950/60 text-emerald-300`:`bg-emerald-50 text-emerald-700`}`,children:[(0,r.jsx)(se,{size:11}),` Draft restored`]})]}),(0,r.jsx)(`div`,{className:`flex flex-wrap -mx-2 -mb-4`,children:t.map(e=>ct(e,e.type===`file`||e.width===`full`?`w-full`:`w-full md:w-1/2`,n))})]}),u.length>0&&(0,r.jsxs)(`div`,{part:`portal-card addons-card`,className:_,children:[(0,r.jsx)(`div`,{className:`flex items-start justify-between gap-3 mb-4`,children:(0,r.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(Ke,{size:17})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Add-ons`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:`Select items to add to your registration`})]})]})}),(0,r.jsx)(`div`,{className:`space-y-2`,children:u.map(e=>{let t=!!e.purchased,n=pe.includes(e.name);return(0,r.jsxs)(`label`,{className:`p-3.5 rounded-2xl border flex items-center gap-3 transition-all ${t?o?`bg-zinc-950/60 border-zinc-800 cursor-default`:`bg-slate-50 border-slate-200 cursor-default`:n?`cursor-pointer`:o?`border-zinc-800 bg-zinc-900 hover:border-zinc-700 cursor-pointer`:`border-slate-200 bg-white hover:border-slate-300 cursor-pointer`}`,style:n&&!t?{borderColor:a,backgroundColor:`color-mix(in srgb, ${a} ${o?16:6}%, transparent)`}:void 0,children:[(0,r.jsx)(`input`,{type:`checkbox`,checked:n,disabled:t,onChange:()=>Ye(e.name,t),className:`w-4 h-4 rounded cursor-pointer shrink-0 disabled:cursor-default`,style:{accentColor:a}}),(0,r.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`div`,{className:`text-sm font-semibold leading-snug ${o?`text-white`:`text-slate-900`}`,children:e.name}),(0,r.jsxs)(`div`,{className:`text-[13px] font-semibold mt-0.5 tabular-nums`,style:{color:a},children:[e.currency,` `,Number(e.price).toLocaleString()]})]}),t&&(0,r.jsxs)(`span`,{className:`px-2.5 py-1 rounded-full text-[11px] font-semibold flex items-center gap-1 shrink-0 ${o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`}`,children:[(0,r.jsx)(se,{size:12}),` Purchased`]})]},e.name)})})]}),(0,r.jsx)(`div`,{className:`pt-1 pb-6`,children:(0,r.jsx)(`button`,{part:`button button-primary submit-button`,type:`submit`,disabled:m||g!==null,style:{background:`linear-gradient(135deg, ${a}, color-mix(in srgb, ${a} 80%, black))`,boxShadow:`0 10px 24px -12px color-mix(in srgb, ${a} 70%, transparent)`},className:`w-full h-12 px-4 text-white text-sm font-semibold rounded-xl hover:brightness-110 active:scale-[0.99] transition-all flex items-center justify-center gap-2 cursor-pointer disabled:opacity-60 disabled:cursor-not-allowed`,children:m?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`svg`,{className:`animate-spin h-4 w-4 text-white`,fill:`none`,viewBox:`0 0 24 24`,"aria-hidden":`true`,children:[(0,r.jsx)(`circle`,{className:`opacity-25`,cx:`12`,cy:`12`,r:`10`,stroke:`currentColor`,strokeWidth:`4`}),(0,r.jsx)(`path`,{className:`opacity-75`,fill:`currentColor`,d:`M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z`})]}),(0,r.jsx)(`span`,{children:`Saving...`})]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(Ie,{size:16}),(0,r.jsx)(`span`,{children:`Save changes`})]})})})]}),d&&(0,r.jsxs)(`div`,{part:`portal-card badge-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 mb-4`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(be,{size:17})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Your badge`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:`View or download your event badge.`})]})]}),(0,r.jsx)(`div`,{className:`rounded-2xl border overflow-hidden ${o?`border-zinc-800 bg-zinc-950/60`:`border-slate-200 bg-slate-50`}`,children:(0,r.jsx)(`img`,{src:d,alt:`Your event badge`,className:`w-full max-h-96 object-contain`})}),(0,r.jsxs)(`div`,{className:`mt-4 flex flex-wrap gap-2.5`,children:[(0,r.jsxs)(`a`,{href:d,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold border transition-colors ${o?`text-zinc-200 border-zinc-700 hover:bg-zinc-800`:`text-slate-700 border-slate-200 bg-white hover:bg-slate-50`}`,children:[(0,r.jsx)(_e,{size:13}),(0,r.jsx)(`span`,{children:`View badge`})]}),(0,r.jsxs)(`a`,{href:d,download:!0,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white`,style:{backgroundColor:a},children:[(0,r.jsx)(ge,{size:13}),(0,r.jsx)(`span`,{children:`Download badge`})]})]})]}),c.length>0&&(0,r.jsxs)(`div`,{part:`portal-card payments-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 mb-4`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(Be,{size:17})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Payments`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:`Every order on your registration, with receipts.`})]})]}),(0,r.jsx)(`div`,{className:`space-y-2`,children:c.map((e,t)=>{let n=e.state===`paid`;return(0,r.jsxs)(`div`,{className:`p-3.5 rounded-2xl border flex items-center gap-3 ${o?`border-zinc-800 bg-zinc-950/60`:`border-slate-200 bg-slate-50`}`,children:[(0,r.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`div`,{className:`text-sm font-semibold leading-snug truncate ${o?`text-white`:`text-slate-900`}`,children:e.order_number||`Registration fee`}),e.amount&&(0,r.jsx)(`div`,{className:`text-[13px] font-semibold mt-0.5 tabular-nums`,style:{color:a},children:[e.currency,Number(e.amount).toLocaleString()].filter(Boolean).join(` `)})]}),(0,r.jsx)(`span`,{className:`px-2.5 py-1 rounded-full text-[11px] font-semibold capitalize shrink-0 ${n?o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`:o?`bg-amber-950/60 text-amber-300`:`bg-amber-50 text-amber-700`}`,children:e.state}),e.receipt_url&&(0,r.jsxs)(`a`,{href:e.receipt_url,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1 text-[12.5px] font-semibold hover:underline underline-offset-4 shrink-0`,style:{color:a},children:[(0,r.jsx)(`span`,{children:`Receipt`}),(0,r.jsx)(_e,{size:11})]})]},e.order_number||t)})})]}),f&&(0,r.jsxs)(`div`,{part:`portal-card submission-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 mb-4`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(ve,{size:17})}),(0,r.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Your submission`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:f.registration_type_label||`Abstract submission`})]}),(0,r.jsx)(`span`,{className:`px-2.5 py-1 rounded-full text-[11px] font-semibold capitalize shrink-0 ${f.verdict===`accepted`?o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`:f.verdict===`rejected`?o?`bg-red-950/60 text-red-300`:`bg-red-50 text-red-700`:o?`bg-amber-950/60 text-amber-300`:`bg-amber-50 text-amber-700`}`,children:f.verdict})]}),(0,r.jsxs)(`dl`,{className:`grid grid-cols-2 gap-4`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`dt`,{className:`text-[11px] font-semibold uppercase tracking-wider ${o?`text-zinc-500`:`text-slate-400`}`,children:`Submission no.`}),(0,r.jsx)(`dd`,{className:`mt-1 text-sm font-semibold font-mono ${o?`text-white`:`text-slate-900`}`,children:f.submission_number||`N/A`})]}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`dt`,{className:`text-[11px] font-semibold uppercase tracking-wider ${o?`text-zinc-500`:`text-slate-400`}`,children:`Status`}),(0,r.jsx)(`dd`,{className:`mt-1 text-sm font-semibold capitalize ${o?`text-white`:`text-slate-900`}`,children:f.status})]})]}),Se?(0,r.jsxs)(`form`,{onSubmit:at,className:`mt-4 pt-4 border-t space-y-3.5 ${o?`border-zinc-800`:`border-slate-100`}`,children:[(f.editable_fields||[]).map(e=>(0,r.jsxs)(`div`,{children:[(0,r.jsxs)(`label`,{className:`block text-[13px] font-semibold mb-1.5 ${o?`text-zinc-200`:`text-slate-800`}`,children:[e.label,e.required&&(0,r.jsx)(`span`,{className:`text-red-500`,children:` *`})]}),e.type===`file`?(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`button`,{type:`button`,disabled:je===e.id,onClick:()=>Ne(t=>({...t,[e.id]:et(e)===`file`?`text`:`file`})),className:`mb-1.5 text-[12px] font-semibold underline disabled:opacity-50 ${o?`text-zinc-400`:`text-slate-500`}`,children:et(e)===`file`?`Send text instead`:`Send file instead`}),et(e)===`file`?(0,r.jsxs)(`div`,{children:[e.current_file?.serve_url&&(0,r.jsx)(`a`,{href:e.current_file.serve_url,target:`_blank`,rel:`noopener noreferrer`,className:`block mb-2 text-[12.5px] font-medium underline ${o?`text-zinc-300`:`text-slate-600`}`,children:`View current file`}),(0,r.jsx)(`input`,{type:`file`,disabled:je===e.id,onChange:t=>{let n=t.target.files?.[0];n&&tt(e.id,n)},className:`w-full text-[13px] ${y}`}),je===e.id&&(0,r.jsx)(`p`,{className:`mt-1 text-[12.5px] ${y}`,children:`Uploading…`})]}):(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`textarea`,{rows:4,disabled:je===e.id,value:Pe[e.id]??``,placeholder:`Enter your answer...`,onChange:t=>Fe({...Pe,[e.id]:t.target.value}),className:`w-full px-3.5 py-2.5 text-sm font-medium rounded-xl border transition-all focus:outline-none resize-y ${o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400`}`}),(0,r.jsx)(`button`,{type:`button`,disabled:je===e.id||!(Pe[e.id]||``).trim(),onClick:()=>it(e.id),className:`mt-1.5 inline-flex items-center h-8 px-3.5 rounded-full text-[12.5px] font-semibold text-white disabled:opacity-50 cursor-pointer`,style:{backgroundColor:a},children:je===e.id?`Saving…`:`Save text answer`})]})]}):e.id===`registration_type`?(0,r.jsxs)(`select`,{value:Y[e.id]??``,onChange:t=>De({...Y,[e.id]:t.target.value}),className:`w-full h-11 px-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${o?`bg-zinc-950 border-zinc-700 text-white`:`bg-white border-slate-200 text-slate-900`}`,children:[(0,r.jsxs)(`option`,{value:``,children:[`Select `,e.label,`...`]}),(f.registration_types||[]).map(e=>(0,r.jsx)(`option`,{value:e.id,children:e.label},e.id))]}):e.type===`select`?(0,r.jsxs)(`select`,{value:Y[e.id]??``,onChange:t=>De({...Y,[e.id]:t.target.value}),className:`w-full h-11 px-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${o?`bg-zinc-950 border-zinc-700 text-white`:`bg-white border-slate-200 text-slate-900`}`,children:[(0,r.jsxs)(`option`,{value:``,children:[`Select `,e.label,`...`]}),(e.options||[]).map(e=>(0,r.jsx)(`option`,{value:e,children:e},e))]}):(0,r.jsx)(`textarea`,{rows:e.id===`name`||e.id===`phone`?1:4,value:Y[e.id]??``,placeholder:e.placeholder||`Enter ${e.label.toLowerCase()}`,onChange:t=>De({...Y,[e.id]:t.target.value}),className:`w-full px-3.5 py-2.5 text-sm font-medium rounded-xl border transition-all focus:outline-none resize-y ${o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400`}`})]},e.id)),(0,r.jsxs)(`div`,{className:`flex items-center gap-2.5 pt-1`,children:[(0,r.jsx)(`button`,{type:`submit`,disabled:ke,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white shrink-0 cursor-pointer disabled:opacity-60`,style:{backgroundColor:a},children:ke?`Saving...`:`Save changes`}),(0,r.jsx)(`button`,{type:`button`,disabled:ke,onClick:()=>we(!1),className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold border transition-colors cursor-pointer ${o?`text-zinc-300 border-zinc-700 hover:bg-zinc-800`:`text-slate-600 border-slate-200 bg-white hover:bg-slate-50`}`,children:`Cancel`})]})]}):(0,r.jsxs)(`div`,{className:`mt-4 pt-4 border-t flex items-center justify-between gap-3 flex-wrap ${o?`border-zinc-800`:`border-slate-100`}`,children:[(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:f.editable?`You can still edit your answers until a reviewer picks this up.`:`This submission has been assigned to a reviewer and can no longer be edited.`}),f.editable&&(0,r.jsx)(`button`,{type:`button`,onClick:$e,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white shrink-0 cursor-pointer`,style:{backgroundColor:a},children:`Edit submission`})]})]}),W&&(0,r.jsxs)(`div`,{className:`p-4 rounded-2xl flex flex-wrap items-center justify-between gap-3 text-sm`,style:{backgroundColor:`color-mix(in srgb, ${a} ${o?14:7}%, transparent)`,boxShadow:`inset 0 0 0 1px color-mix(in srgb, ${a} 22%, transparent)`},children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2.5 ${o?`text-zinc-200`:`text-slate-700`}`,children:[(0,r.jsx)(me,{size:17,className:`shrink-0`,style:{color:a}}),(0,r.jsx)(`span`,{children:`Payment page opened in a new tab. If it didn't open:`})]}),(0,r.jsxs)(`a`,{href:W,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white shrink-0`,style:{backgroundColor:a},children:[(0,r.jsx)(`span`,{children:`Complete payment`}),(0,r.jsx)(_e,{size:12})]})]}),v&&(0,r.jsxs)(`div`,{role:`alert`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-red-950/50 text-red-300 ring-1 ring-inset ring-red-900`:`bg-red-50 text-red-700 ring-1 ring-inset ring-red-200/80`}`,children:[(0,r.jsx)(ue,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:v})]}),b&&(0,r.jsxs)(`div`,{role:`status`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-emerald-950/50 text-emerald-300 ring-1 ring-inset ring-emerald-900`:`bg-emerald-50 text-emerald-700 ring-1 ring-inset ring-emerald-200/80`}`,children:[(0,r.jsx)(M,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:b})]})]})})]})}let ut=`w-full h-11 pl-10 pr-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500 hover:border-zinc-600 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_20%,transparent)]`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 hover:border-slate-300 shadow-[0_1px_2px_rgba(15,23,42,0.04)] focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`,dt=(0,r.jsxs)(`svg`,{className:`animate-spin h-4 w-4 text-white`,fill:`none`,viewBox:`0 0 24 24`,"aria-hidden":`true`,children:[(0,r.jsx)(`circle`,{className:`opacity-25`,cx:`12`,cy:`12`,r:`10`,stroke:`currentColor`,strokeWidth:`4`}),(0,r.jsx)(`path`,{className:`opacity-75`,fill:`currentColor`,d:`M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z`})]}),ft=e=>{d(e),y(null),x(null)},$=({id:e,label:t,icon:n,type:i=`text`,value:a,onChange:s,placeholder:c,autoComplete:l,aside:u})=>(0,r.jsxs)(`div`,{children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-2 mb-1.5`,children:[(0,r.jsx)(`label`,{part:`field-label`,htmlFor:e,className:`block text-[13px] font-semibold ${o?`text-zinc-200`:`text-slate-800`}`,children:t}),u]}),(0,r.jsxs)(`div`,{className:`relative`,children:[(0,r.jsx)(`div`,{className:`absolute inset-y-0 left-0 pl-3.5 flex items-center pointer-events-none ${o?`text-zinc-500`:`text-slate-400`}`,children:(0,r.jsx)(n,{size:16})}),(0,r.jsx)(`input`,{part:`input`,id:e,type:i,required:!0,value:a,autoComplete:l,onChange:e=>s(e.target.value),placeholder:c,className:ut})]})]}),pt=()=>(0,r.jsxs)(r.Fragment,{children:[v&&(0,r.jsxs)(`div`,{role:`alert`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-red-950/50 text-red-300 ring-1 ring-inset ring-red-900`:`bg-red-50 text-red-700 ring-1 ring-inset ring-red-200/80`}`,children:[(0,r.jsx)(ue,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:v})]}),b&&(0,r.jsxs)(`div`,{role:`status`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-emerald-950/50 text-emerald-300 ring-1 ring-inset ring-emerald-900`:`bg-emerald-50 text-emerald-700 ring-1 ring-inset ring-emerald-200/80`}`,children:[(0,r.jsx)(M,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:b})]})]}),mt=(e,t,n)=>(0,r.jsx)(`button`,{part:`button button-primary submit-button`,type:`submit`,disabled:e,style:{background:`linear-gradient(135deg, ${a}, color-mix(in srgb, ${a} 80%, black))`,boxShadow:`0 10px 24px -12px color-mix(in srgb, ${a} 70%, transparent)`},className:`group w-full h-11 px-4 text-white text-sm font-semibold rounded-xl hover:brightness-110 active:scale-[0.99] transition-all flex items-center justify-center gap-2 cursor-pointer disabled:opacity-60 disabled:cursor-not-allowed`,children:e?(0,r.jsxs)(r.Fragment,{children:[dt,(0,r.jsx)(`span`,{children:n})]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`span`,{children:t}),(0,r.jsx)(ie,{size:16,className:`transition-transform group-hover:translate-x-0.5`})]})}),ht=({icon:e,title:t,subtitle:n,onBack:i,children:c})=>(0,r.jsxs)(`div`,{className:`flex flex-col ${s?`w-full flex-1`:`h-full overflow-y-auto`} relative bg-transparent ${o?`text-white`:`text-slate-900`}`,children:[ot(),(0,r.jsxs)(`div`,{className:`px-4 sm:px-6 ${s?`py-8 sm:py-10`:`py-5`} flex-1 max-w-[400px] mx-auto w-full flex flex-col justify-center relative z-10`,children:[i&&(0,r.jsxs)(`button`,{part:`button button-link back-button`,type:`button`,onClick:i,className:`self-start inline-flex items-center gap-1.5 mb-4 text-sm font-semibold transition-colors cursor-pointer ${o?`text-zinc-400 hover:text-white`:`text-slate-500 hover:text-slate-900`}`,children:[(0,r.jsx)(ne,{size:16}),(0,r.jsx)(`span`,{children:`Back to login`})]}),(0,r.jsxs)(`div`,{part:`portal-card`,className:`p-6 sm:p-7 rounded-3xl border space-y-5 ${o?`bg-zinc-900 border-zinc-800 shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_24px_48px_-24px_rgba(15,23,42,0.18)]`}`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`div`,{className:`w-10 h-10 rounded-xl flex items-center justify-center mb-4`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(e,{size:19})}),(0,r.jsx)(`h3`,{part:`portal-title`,style:Q,className:`text-xl font-bold tracking-tight ${o?`text-white`:`text-slate-900`}`,children:t}),(0,r.jsx)(`p`,{className:`text-[13px] mt-1 leading-relaxed ${o?`text-zinc-400`:`text-slate-500`}`,children:n})]}),pt(),c]})]})]}),gt=`font-semibold hover:underline underline-offset-4 cursor-pointer`;return ht(u===`request_code`?{icon:Oe,title:`Get verification code`,subtitle:`We will email a verification code to your registered address.`,onBack:()=>ft(`login`),children:(0,r.jsxs)(`form`,{onSubmit:Ve,className:`space-y-4`,children:[$({id:`vx-portal-code-identifier`,label:`Registration number or email`,icon:Oe,value:E||S,onChange:e=>{D(e),C(e)},placeholder:`e.g. attendee@example.com or REG12345`,autoComplete:`username`}),mt(de,`Send verification code`,`Sending code...`),(0,r.jsxs)(`p`,{className:`text-center text-[13px] ${o?`text-zinc-400`:`text-slate-500`}`,children:[`Already have a code?`,` `,(0,r.jsx)(`button`,{type:`button`,onClick:()=>ft(`reset`),className:gt,style:{color:a},children:`Set your password`})]})]})}:u===`reset`?{icon:xe,title:`Set your password`,subtitle:`Enter the code from your email and choose a new password.`,onBack:()=>ft(`login`),children:(0,r.jsxs)(`form`,{onSubmit:He,className:`space-y-4`,children:[$({id:`vx-portal-reset-identifier`,label:`Registration number or email`,icon:Oe,value:E||S,onChange:e=>{D(e),C(e)},placeholder:`e.g. attendee@example.com or REG12345`,autoComplete:`username`}),$({id:`vx-portal-reset-code`,label:`Verification code`,icon:J,value:re,onChange:O,placeholder:`Enter code from email`,autoComplete:`one-time-code`,aside:(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(E||S),ft(`request_code`)},className:`text-xs font-semibold hover:underline underline-offset-4 cursor-pointer`,style:{color:a},children:`Get code on email`})}),$({id:`vx-portal-reset-password`,label:`New password`,icon:Ce,type:`password`,value:k,onChange:A,placeholder:`Enter new password`,autoComplete:`new-password`}),$({id:`vx-portal-reset-confirm`,label:`Confirm password`,icon:Ce,type:`password`,value:ce,onChange:j,placeholder:`Re-enter new password`,autoComplete:`new-password`}),mt(f,`Set new password`,`Updating password...`)]})}:{icon:Te,title:`Attendee login`,subtitle:`Sign in with your email or registration number.`,children:(0,r.jsxs)(`form`,{onSubmit:ze,className:`space-y-4`,children:[$({id:`vx-portal-login-identifier`,label:`Email or registration number`,icon:Oe,value:S,onChange:C,placeholder:`Enter email or registration number`,autoComplete:`username`}),$({id:`vx-portal-login-password`,label:`Password`,icon:Ce,type:`password`,value:w,onChange:ee,placeholder:`Enter password`,autoComplete:`current-password`,aside:(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(S),ft(`reset`)},className:`text-xs font-semibold hover:underline underline-offset-4 cursor-pointer`,style:{color:a},children:`Forgot password?`})}),mt(f,`Login`,`Logging in...`),(0,r.jsxs)(`p`,{className:`pt-4 border-t text-center text-[13px] ${o?`border-zinc-800 text-zinc-400`:`border-slate-100 text-slate-500`}`,children:[`First time here?`,` `,(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(S),ft(`request_code`)},className:gt,style:{color:a},children:`Get code`}),` `,`or`,` `,(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(S),ft(`reset`)},className:gt,style:{color:a},children:`generate password`})]})]})})};function at(e,t,n){if(!e)return;let r=t?`rgba(9,9,11,0.88)`:`rgba(248,250,252,0.88)`;return{backgroundImage:`linear-gradient(${r}, ${r}), url(${e})`,backgroundSize:`cover`,backgroundPosition:`center`,backgroundRepeat:`no-repeat`,backgroundAttachment:n?`fixed`:`scroll`}}function ot(e){if(!e)return`bottom-right`;switch(e){case`bottom-left`:case`left-bottom`:return`bottom-left`;case`top-right`:case`right-top`:return`top-right`;case`top-left`:case`left-top`:return`top-left`;default:return`bottom-right`}}var st=e=>{switch(e){case`bottom-left`:return{bottom:`20px`,left:`20px`,top:`auto`,right:`auto`};case`top-right`:return{top:`20px`,right:`20px`,bottom:`auto`,left:`auto`};case`top-left`:return{top:`20px`,left:`20px`,bottom:`auto`,right:`auto`};default:return{bottom:`20px`,right:`20px`,top:`auto`,left:`auto`}}},ct=e=>{switch(e){case`bottom-left`:return`bottom-5 left-5`;case`top-right`:return`top-5 right-5`;case`top-left`:return`top-5 left-5`;default:return`bottom-5 right-5`}},lt=({config:e})=>{let[t,i]=(0,n.useState)(`registration`),[a,o]=(0,n.useState)(!1);(0,n.useEffect)(()=>{t===`attendee`&&o(!0)},[t]);let[s]=(0,n.useState)(()=>typeof window<`u`?new URLSearchParams(window.location.search).get(`rn`):null),[c,l]=(0,n.useState)(e.displayMode!==`popup`||!!s),[u,d]=(0,n.useState)(!1),[h,g]=(0,n.useState)([]),[_,v]=(0,n.useState)(``),[y,b]=(0,n.useState)(null),[x,S]=(0,n.useState)(null),C=(0,n.useMemo)(()=>x&&{fields:x.fields.filter(e=>e.id!==`registration_type`)},[x]),[w,ee]=(0,n.useState)(!0),[te,T]=(0,n.useState)(``),[E,D]=(0,n.useState)(null),[ne,re]=(0,n.useState)(!!s),[O,ae]=(0,n.useState)(null),[k,oe]=(0,n.useState)(null),[A,ce]=(0,n.useState)(s),[le,j]=(0,n.useState)(!1),[ue,de]=(0,n.useState)(()=>ot(e.position)),[M,N]=(0,n.useState)(null),[F,I]=(0,n.useState)(null),[L,me]=(0,n.useState)(!1),[he,ge]=(0,n.useState)(!1),R=(0,n.useRef)(null),z=(0,n.useRef)(null),B=(0,n.useRef)(!1);(0,n.useEffect)(()=>{e.position&&de(ot(e.position))},[e.position]);let V=e.themeMode===`dark`||e.theme?.mode===`dark`,H=e.theme?.primaryColor||`#2563eb`,U=!!e.isAbstract,ye=e.headerBannerImage,be=e.backgroundImage,W=(0,n.useMemo)(()=>new f(e.debug),[e.debug]),G=(0,n.useMemo)(()=>new p(e.baseUrl,e.eventSlug,W,e.timeoutMs??12e4),[e.baseUrl,e.eventSlug,W,e.timeoutMs]),K=(0,n.useMemo)(()=>new m(e.eventSlug),[e.eventSlug]),xe=(0,n.useRef)(e.displayMode),q=(0,n.useRef)(null),[J,Se]=(0,n.useState)(null);(0,n.useEffect)(()=>{K.getXrefId()},[K]),(0,n.useEffect)(()=>{if(!c)return;let t=K.getXrefId();t&&(U?G.getReviewDraft(t):G.getDraft(t)).then(t=>{let n=t?.data||t;n&&n.registration_type&&(Se(n),e.onEvent?.(`draft_loaded`,n))}).catch(e=>{W.log(`No draft found for this session`,e)})},[c,G,K,W,U]);let Ce=(0,n.useMemo)(()=>{if(!J||!y||String(J.registration_type)!==String(y.id))return{};let e={...J.custom_data||{}};if(J.salutation&&(e.salutation=J.salutation,e.title=J.salutation),J.name){e.name=J.name,e.full_name=J.name,e.fullName=J.name;let t=J.name.trim().split(/\s+/);t.length>0&&!e.first_name&&(e.first_name=t[0]),t.length>1&&!e.last_name&&(e.last_name=t.slice(1).join(` `))}return J.email&&(e.email=J.email),J.phone&&(e.phone=J.phone,e.mobile=J.phone,e.phoneNumber=J.phone),((U?x?.fields:y?.form_schema?.fields)||[]).forEach(t=>{let n=nt(t.id,t.label);e[t.id]===void 0&&e[n]!==void 0&&(e[t.id]=e[n])}),e},[J,y,U,x]);(0,n.useEffect)(()=>()=>{q.current&&clearTimeout(q.current)},[]);let we=(0,n.useCallback)(t=>{q.current&&clearTimeout(q.current),q.current=setTimeout(async()=>{if(!Object.values(t).some(e=>e!==``&&e!=null))return;let n=new Set([`salutation`,`title`,`name`,`fullName`,`full_name`,`firstName`,`lastName`,`email`,`phone`,`mobile`,`phoneNumber`,`selected_items`,`custom_data`]),r=(U?x?.fields:y?.form_schema?.fields)||[],i=new Map;r.forEach(e=>i.set(e.id,e));let a={...t.custom_data||{}};for(let[e,r]of Object.entries(t))if(!n.has(e)){let t=nt(e,i.get(e)?.label);a[t]=r,t!==e&&(a[e]=r)}let o={xref_id:K.getXrefId(),salutation:t.salutation||t.title||``,name:t.name||t.fullName||t.full_name||[t.firstName,t.lastName].filter(Boolean).join(` `)||``,email:t.email||``,phone:t.phone||t.mobile||t.phoneNumber||``,registration_type:y?.id,custom_data:a,selected_items:t.selected_items||[]};try{U?await G.trackReviewProgress(o):await G.trackProgress(o),e.onEvent?.(`draft_saved`,o)}catch(e){W.error(`Failed to save draft progress`,e)}},600)},[K,G,y,e,W,U,x]);(0,n.useEffect)(()=>{xe.current!==e.displayMode&&(xe.current=e.displayMode,l(e.displayMode!==`popup`),d(!1))},[e.displayMode]),(0,n.useEffect)(()=>{(U?G.getReviewFormSchema():G.getFormSchema()).then(t=>{g(t?.data?.types||[]),U&&S({fields:t?.data?.fields||[]}),(t?.data?.event_name||t?.data?.title||t?.data?.name)&&v(t.data.event_name||t.data.title||t.data.name),e.onEvent?.(`form_loaded`,t?.data)}).catch(t=>{W.error(`Failed to load schema`,t),g([]);let n={type:`schema_load`,message:t?.message||`Failed to load event schema`,error:t};e.onEvent?.(`error`,n),e.onError?.(n)}).finally(()=>ee(!1))},[G,U]);let Y=async t=>{q.current&&clearTimeout(q.current),ee(!0),ae(null);let n=K.getXrefId(),r=new Set([`salutation`,`title`,`name`,`fullName`,`full_name`,`firstName`,`lastName`,`email`,`phone`,`mobile`,`phoneNumber`,`registration_type`,`selected_items`,`custom_data`,`xref_id`]),i=(U?x?.fields:y?.form_schema?.fields)||[],a=new Map;i.forEach(e=>a.set(e.id,e));let o={...t.custom_data||{}};for(let[e,n]of Object.entries(t))if(!r.has(e)){let t=nt(e,a.get(e)?.label);o[t]=n,t!==e&&(o[e]=n)}let s={xref_id:n,salutation:t.salutation||t.title||``,name:t.name||t.fullName||t.full_name||[t.firstName,t.lastName].filter(Boolean).join(` `)||``,email:t.email||``,phone:t.phone||t.mobile||t.phoneNumber||``,registration_type:y.id,custom_data:o,selected_items:t.selected_items||[]};try{let t=U?await G.submitReview(s):await G.submitRegistration(s);K.updateXrefId(),Se(null);let n=U?null:t?.data?.payment_url||t?.payment_url||null;oe(n);let r=t?.data?.submission_number||t?.submission_number||t?.data?.registration_number||t?.registration_number||t?.data?.registration?.registration_number||t?.registration?.registration_number||null;ce(r?String(r):null),j(!1),n&&typeof n==`string`&&n.trim()!==``&&window.open(n,`_blank`,`noopener,noreferrer`),re(!0);let i={registrationType:y.id,payload:s,response:t,paymentUrl:n};e.onEvent?.(`submitted`,i),e.onRegister?.(i),e.onRegistered?.(i)}catch(t){W.error(`Submission failed`,t);let n=t?.message||(U?`Submission failed. Please check your information and try again.`:`Registration failed. Please check your information and try again.`),r={type:`submit_error`,message:n,error:t};e.onEvent?.(`error`,r),e.onError?.(r),ae(n)}finally{ee(!1)}},Ee=()=>{if(re(!1),ae(null),oe(null),ce(null),j(!1),b(null),Se(null),typeof window<`u`&&new URLSearchParams(window.location.search).has(`rn`)){let e=new URL(window.location.href);e.searchParams.delete(`rn`),window.history.replaceState(window.history.state,``,e.toString())}},De=(0,n.useCallback)(e=>{if(e.stopPropagation(),e.button!==0||!R.current)return;let t=R.current.getBoundingClientRect();z.current={startX:e.clientX,startY:e.clientY,rect:t,corner:ue},B.current=!1,me(!0)},[ue]);(0,n.useEffect)(()=>{if(!L)return;let t=e=>{if(!z.current)return;let t=e.clientX-z.current.startX,n=e.clientY-z.current.startY;B.current||Math.hypot(t,n)>5&&(B.current=!0),B.current&&N({x:t,y:n})},n=t=>{if(!z.current){me(!1),N(null),B.current=!1;return}let{rect:n,startX:r,startY:i}=z.current,a=t.clientX-r,o=t.clientY-i,s=B.current;if(z.current=null,me(!1),setTimeout(()=>{B.current=!1},100),!s){N(null);return}let c=n.left+a,l=n.top+o,u=c+n.width/2,d=l+n.height/2,f=typeof window<`u`?window.innerWidth:1024,p=typeof window<`u`?window.innerHeight:768,m=u>=f/2,h=d>=p/2,g=h?m?`bottom-right`:`bottom-left`:m?`top-right`:`top-left`,_=m?f-n.width-20:20,v=h?p-n.height-20:20,y=c-_,b=l-v;I({transform:`translate3d(${y}px, ${b}px, 0)`,transition:`none`}),N(null),de(g),e.onEvent?.(`position_changed`,{position:g}),requestAnimationFrame(()=>{requestAnimationFrame(()=>{I({transform:`translate3d(0, 0, 0)`,transition:`transform 0.35s cubic-bezier(0.16, 1, 0.3, 1)`}),setTimeout(()=>{I(null)},360)})})};return window.addEventListener(`pointermove`,t),window.addEventListener(`pointerup`,n),window.addEventListener(`pointercancel`,n),()=>{window.removeEventListener(`pointermove`,t),window.removeEventListener(`pointerup`,n),window.removeEventListener(`pointercancel`,n)}},[L,e]);let Oe=async()=>{if(A){try{await navigator.clipboard.writeText(A)}catch{let e=document.createElement(`textarea`);e.value=A,document.body.appendChild(e),e.select(),document.execCommand(`copy`),document.body.removeChild(e)}j(!0),setTimeout(()=>j(!1),2e3)}},ke=()=>A?(0,r.jsxs)(`div`,{className:`w-full max-w-xs mb-6`,children:[(0,r.jsx)(`p`,{className:`text-2xs font-bold uppercase tracking-wider mb-1.5 ${V?`text-zinc-400`:`text-gray-500`}`,children:U?`Submission Number`:`Registration Number`}),(0,r.jsxs)(`div`,{part:`registration-number`,className:`flex items-center gap-2 pl-4 pr-1.5 py-1.5 rounded-xl border ${V?`bg-zinc-900 border-zinc-700`:`bg-gray-50 border-gray-200`}`,children:[(0,r.jsx)(`span`,{className:`flex-1 text-left font-mono font-bold text-base select-all break-all`,children:A}),(0,r.jsxs)(`button`,{part:`copy-button`,type:`button`,onClick:Oe,className:`flex items-center gap-1 px-3 py-1.5 rounded-lg text-xs font-bold text-white shrink-0 cursor-pointer hover:opacity-90 transition-opacity`,style:{backgroundColor:H},title:`Copy registration number`,children:[le?(0,r.jsx)(se,{size:13}):(0,r.jsx)(pe,{size:13}),(0,r.jsx)(`span`,{children:le?`Copied`:`Copy`})]})]})]}):null;if(!c&&e.displayMode===`popup`){let e={...st(ue),...M?{transform:`translate3d(${M.x}px, ${M.y}px, 0) scale(1.05)`,transition:`none`,userSelect:`none`}:F?{transform:F.transform,transition:F.transition}:{transition:`all 0.3s cubic-bezier(0.16, 1, 0.3, 1)`}},t=he||L;return(0,r.jsxs)(`div`,{ref:R,onMouseEnter:()=>ge(!0),onMouseLeave:()=>ge(!1),className:`fixed ${ct(ue)} z-50 select-none group`,style:e,children:[(0,r.jsx)(`div`,{onPointerDown:De,className:`absolute -top-1.5 -left-1.5 w-7 h-7 rounded-full bg-slate-900 text-white shadow-lg border-2 border-white flex items-center justify-center cursor-grab active:cursor-grabbing hover:bg-black hover:scale-110 active:scale-95 transition-all duration-200 z-10 touch-none ${t?`opacity-100 scale-100 pointer-events-auto`:`opacity-0 scale-75 pointer-events-none group-hover:opacity-100 group-hover:scale-100 group-hover:pointer-events-auto`}`,title:`Hold and drag to change position`,children:(0,r.jsx)(Pe,{size:13,className:`pointer-events-none text-white`})}),(0,r.jsx)(`button`,{part:`launcher`,type:`button`,onClick:e=>{e.stopPropagation(),!L&&l(!0)},className:`w-16 h-16 rounded-full text-white shadow-xl flex items-center justify-center cursor-pointer hover:scale-105 active:scale-95 transition-transform`,style:{backgroundColor:H},title:`Click to open registration`,children:(0,r.jsx)(`span`,{className:`font-bold text-sm tracking-wide pointer-events-none`,children:`Join`})})]})}let Ae=e.displayMode===`fullscreen`||e.displayMode===`popup`&&u,X=e.displayMode===`widget`,Z=at(be,V,X),Ne=`${V?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`} flex flex-col transition-all duration-300 ease-in-out `,Fe=e.theme?.fontFamily,Ie=!Fe||Fe===`inherit`?{}:{fontFamily:`var(--vx-font-family, ${Fe})`};Ie[`--vx-accent`]=H,Ae?Ne+=`fixed inset-0 z-[9999] rounded-none overflow-hidden `:e.displayMode===`popup`?(Ne+=`fixed ${ct(ue)} z-50 rounded-xl shadow-2xl border ${V?`border-zinc-800`:`border-gray-200`} overflow-hidden `,Ie.width=e.width||`400px`,Ie.height=e.height||`700px`,Ie.maxHeight=`90vh`,Ie.maxWidth=`calc(100vw - 32px)`,Object.assign(Ie,st(ue))):(Ne+=`relative w-full min-h-screen border-none shadow-none rounded-none `,Ie.width=`100%`,Ie.minHeight=`100vh`);let Le=U?`Abstract Submission`:t===`registration`?_||`Registration`:`Attendee Portal`,Re=te.trim().toLowerCase(),ze=Re?h.filter(e=>[e.type,e.name,e.category,e.description,e.currency,e.price,e.tax_info,...Array.isArray(e.perks)?e.perks:[]].filter(e=>e!=null&&e!==``).join(` `).toLowerCase().includes(Re)):h,Be=`max-w-2xl mx-auto w-full rounded-3xl border overflow-hidden ${V?`bg-zinc-900 border-zinc-800 shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_24px_48px_-24px_rgba(15,23,42,0.16)]`}`,Ve=()=>{if(h.length===0)return null;let e=h.find(e=>String(e.id)===E)||(h.length===1?h[0]:null),t=e?e.type||e.name||e.label:``;return(0,r.jsxs)(`div`,{part:`category-panel`,className:Be,children:[(0,r.jsxs)(`div`,{className:`px-5 sm:px-7 pt-6 sm:pt-7 pb-5 flex items-center gap-3.5`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:(0,r.jsx)(ve,{size:20})}),(0,r.jsx)(`div`,{className:`min-w-0`,children:(0,r.jsx)(`h3`,{part:`list-title`,className:`text-lg sm:text-xl font-semibold tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:`Choose a submission category`})})]}),(0,r.jsx)(`div`,{role:`radiogroup`,"aria-label":`Submission category`,className:`border-t divide-y ${V?`border-zinc-800 divide-zinc-800`:`border-slate-100 divide-slate-100`}`,children:h.map(t=>{let n=t.type||t.name||t.label,i=!!e&&String(e.id)===String(t.id);return(0,r.jsxs)(`button`,{part:i?`category category-active`:`category`,type:`button`,role:`radio`,"aria-checked":i,onClick:()=>D(String(t.id)),className:`group w-full flex items-center gap-4 px-5 sm:px-7 py-4 text-left transition-colors cursor-pointer outline-none focus-visible:bg-[color-mix(in_srgb,var(--vx-accent)_8%,transparent)] ${i?``:V?`hover:bg-zinc-800/60`:`hover:bg-slate-50`}`,style:i?{backgroundColor:`color-mix(in srgb, ${H} ${V?14:6}%, transparent)`}:void 0,children:[(0,r.jsx)(`span`,{"aria-hidden":`true`,className:`w-5 h-5 rounded-full border-2 flex items-center justify-center shrink-0 transition-colors ${i?``:V?`border-zinc-600`:`border-slate-300`}`,style:i?{borderColor:H}:void 0,children:i&&(0,r.jsx)(`span`,{className:`w-2.5 h-2.5 rounded-full`,style:{backgroundColor:H}})}),(0,r.jsxs)(`span`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`span`,{className:`block text-[15px] font-semibold leading-snug ${V?`text-white`:`text-slate-900`}`,children:n}),t.description&&(0,r.jsx)(`span`,{className:`block text-[13px] mt-0.5 line-clamp-1 ${V?`text-zinc-400`:`text-slate-500`}`,children:t.description})]}),t.category&&(0,r.jsx)(`span`,{className:`hidden sm:inline-block text-[10px] font-semibold uppercase tracking-wider px-2.5 py-1 rounded-full shrink-0 ${V?`bg-zinc-800 text-zinc-300`:`bg-slate-100 text-slate-600`}`,children:t.category}),(0,r.jsx)(ie,{size:16,className:`shrink-0 transition-all ${i?`translate-x-0.5`:`${V?`text-zinc-600`:`text-slate-300`} group-hover:translate-x-0.5`}`,style:i?{color:H}:void 0})]},t.id)})}),(0,r.jsxs)(`div`,{className:`px-5 sm:px-7 py-5 border-t flex flex-col-reverse sm:flex-row sm:items-center sm:justify-between gap-3 ${V?`border-zinc-800`:`border-slate-100`}`,children:[(0,r.jsx)(`p`,{className:`text-[13px] truncate ${V?`text-zinc-400`:`text-slate-500`}`,children:e?(0,r.jsxs)(r.Fragment,{children:[`Selected: `,(0,r.jsx)(`span`,{className:`font-semibold ${V?`text-zinc-200`:`text-slate-700`}`,children:t})]}):`Select a category to continue`}),(0,r.jsxs)(`button`,{part:`button button-primary continue-button`,type:`button`,disabled:!e,onClick:()=>e&&b(e),style:{background:`linear-gradient(135deg, ${H}, color-mix(in srgb, ${H} 80%, black))`,boxShadow:e?`0 10px 24px -12px color-mix(in srgb, ${H} 70%, transparent)`:void 0},className:`group shrink-0 inline-flex items-center justify-center gap-2 h-11 px-5 rounded-xl text-sm font-semibold text-white transition-all hover:brightness-110 active:scale-[0.99] cursor-pointer disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:brightness-100`,children:[(0,r.jsx)(`span`,{children:`Continue to submission`}),(0,r.jsx)(ie,{size:16,className:`transition-transform group-hover:translate-x-0.5`})]})]})]})},Ue=e=>(0,r.jsxs)(`div`,{part:`category-panel`,className:Be,children:[(0,r.jsxs)(`div`,{className:`px-5 sm:px-7 pt-6 sm:pt-7 pb-5 flex items-center gap-3.5`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-11 h-11 rounded-xl`}),(0,r.jsx)(`div`,{className:`${e} h-4 w-56`})]}),(0,r.jsx)(`div`,{className:`border-t divide-y ${V?`border-zinc-800 divide-zinc-800`:`border-slate-100 divide-slate-100`}`,children:[0,1,2].map(t=>(0,r.jsxs)(`div`,{className:`flex items-center gap-4 px-5 sm:px-7 py-4`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-5 h-5 rounded-full`,style:{animationDelay:`${t*90}ms`}}),(0,r.jsxs)(`div`,{className:`flex-1 space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-3.5 w-1/2`,style:{animationDelay:`${t*90}ms`}}),(0,r.jsx)(`div`,{className:`${e} h-3 w-3/4`,style:{animationDelay:`${t*90}ms`}})]})]},t))}),(0,r.jsx)(`div`,{className:`px-5 sm:px-7 py-5 border-t flex justify-end ${V?`border-zinc-800`:`border-slate-100`}`,children:(0,r.jsx)(`div`,{className:`${e} h-11 w-52`})})]}),Ge=()=>{let e=`vx-skeleton rounded-full`,t=X?6:3;return(0,r.jsxs)(`div`,{part:`page`,role:`status`,"aria-live":`polite`,"aria-busy":`true`,className:`flex flex-col ${X?`w-full flex-1`:`h-full min-h-0`} ${V?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`}`,children:[(0,r.jsx)(`span`,{className:`sr-only`,children:`Loading form types…`}),(0,r.jsx)(`div`,{part:`header`,className:`relative overflow-hidden z-10 shrink-0 text-white`,style:{background:`linear-gradient(135deg, ${H} 0%, color-mix(in srgb, ${H} 76%, black) 100%)`},children:(0,r.jsxs)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-5 sm:py-6 flex items-center gap-3.5`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-2xl bg-white/15 ring-1 ring-inset ring-white/30 shrink-0`}),(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-5 w-48`}),(0,r.jsx)(`div`,{className:`${e} h-3 w-64 max-w-[60vw]`})]})]})}),!U&&(0,r.jsx)(`div`,{part:`tabs`,className:`shrink-0 border-b ${V?`border-zinc-800 bg-zinc-900`:`border-slate-200 bg-white`}`,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-3`,children:(0,r.jsxs)(`div`,{className:`grid grid-cols-2 gap-1 p-1 rounded-xl max-w-md ${V?`bg-zinc-800`:`bg-slate-100`}`,children:[(0,r.jsx)(`div`,{className:`h-9 rounded-lg ${V?`bg-zinc-950`:`bg-white shadow-sm`}`}),(0,r.jsx)(`div`,{className:`h-9`})]})})}),(0,r.jsx)(`div`,{part:`list`,className:`${X?`w-full flex-1`:`overflow-hidden flex-1 min-h-0`} relative ${V?`bg-zinc-950`:`bg-slate-50`}`,style:Z,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-6 sm:py-8 space-y-5`,children:U?Ue(e):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`div`,{part:`search`,className:`flex flex-col sm:flex-row sm:items-end sm:justify-between gap-3`,children:[(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-4 w-56`}),(0,r.jsx)(`div`,{className:`${e} h-3 w-28`})]}),(0,r.jsx)(`div`,{className:`h-10 w-full sm:w-72 rounded-xl border ${V?`bg-zinc-900 border-zinc-800`:`bg-white border-slate-200`}`})]}),(0,r.jsx)(`div`,{part:`card-grid`,className:X?`grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5`:`space-y-3`,children:Array.from({length:t},(t,n)=>{let i={animationDelay:`${n*90}ms`};return(0,r.jsxs)(`div`,{part:`card`,className:`rounded-2xl border p-5 sm:p-6 flex flex-col ${V?`bg-zinc-900 border-zinc-800`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04)]`}`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-11 h-11 rounded-xl`,style:i}),(0,r.jsx)(`div`,{className:`${e} mt-5 h-5 w-3/5`,style:i}),(0,r.jsx)(`div`,{className:`${e} mt-3 h-3 w-4/5`,style:i}),(0,r.jsxs)(`div`,{className:`mt-6 pt-5 border-t border-dashed flex items-end justify-between gap-3 ${V?`border-zinc-800`:`border-slate-200`}`,children:[(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-2.5 w-20`,style:i}),(0,r.jsx)(`div`,{className:`${e} h-6 w-28`,style:i})]}),(0,r.jsx)(`div`,{className:`${e} h-10 w-28`,style:i})]})]},n)})})]})})})]})},qe=()=>{let e=!!y,t=U?ve:Ke,n=e?U?`Submitting your abstract`:`Submitting your registration`:`Loading your registration`,i=y?y.type||y.name||y.label:``,a=!U&&y&&y.price!==void 0&&y.price!==null&&y.price!==``?Number(y.price)>0?[y.currency,Number(y.price).toLocaleString()].filter(Boolean).join(` `):`Free`:``;return(0,r.jsx)(`div`,{part:`screen screen-submitting`,role:`status`,"aria-live":`polite`,"aria-busy":`true`,className:`flex-1 flex items-center justify-center px-4 py-16 ${X?`min-h-[70vh]`:`h-full`} ${V?`bg-zinc-950`:`bg-slate-50`}`,style:Z,children:(0,r.jsxs)(`div`,{part:`portal-card`,className:`w-full max-w-sm rounded-3xl border p-8 text-center ${V?`bg-zinc-900 border-zinc-800 shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_24px_48px_-24px_rgba(15,23,42,0.18)]`}`,children:[(0,r.jsxs)(`div`,{className:`relative mx-auto w-16 h-16`,children:[(0,r.jsx)(`div`,{className:`absolute inset-0 rounded-full`,style:{boxShadow:`inset 0 0 0 4px color-mix(in srgb, ${H} 14%, transparent)`}}),(0,r.jsx)(`div`,{className:`absolute inset-0 rounded-full motion-safe:animate-spin`,style:{background:`conic-gradient(from 0deg, transparent 0deg, ${H} 300deg, transparent 360deg)`,mask:`radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 4px))`,WebkitMask:`radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 4px))`}}),(0,r.jsx)(`div`,{className:`absolute inset-[10px] rounded-full flex items-center justify-center`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:(0,r.jsx)(t,{size:20})})]}),(0,r.jsx)(`h3`,{part:`screen-title`,className:`mt-6 text-xl font-bold tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:n}),(0,r.jsx)(`p`,{part:`screen-message`,className:`mt-1.5 text-[13px] leading-relaxed text-balance ${V?`text-zinc-400`:`text-slate-500`}`,children:`This usually takes a few seconds. Please keep this page open.`}),i&&(0,r.jsxs)(`div`,{className:`mt-5 inline-flex max-w-full items-center gap-2 rounded-full px-3 py-1.5 text-xs font-semibold ${V?`bg-zinc-800 text-zinc-200`:`bg-slate-100 text-slate-700`}`,children:[(0,r.jsx)(`span`,{className:`truncate`,children:i}),a&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`span`,{"aria-hidden":`true`,className:V?`text-zinc-600`:`text-slate-300`,children:`•`}),(0,r.jsx)(`span`,{className:`shrink-0 tabular-nums`,style:{color:H},children:a})]})]}),(0,r.jsx)(`div`,{className:`mt-6 h-1 w-full overflow-hidden rounded-full ${V?`bg-zinc-800`:`bg-slate-100`}`,children:(0,r.jsx)(`div`,{className:`vx-progress-bar h-full w-2/5 rounded-full`,style:{backgroundColor:H}})})]})})};return(0,r.jsx)(`div`,{part:`widget`,className:Ne,style:{...Ie,overflow:X?`visible`:`clip`},onScroll:e=>{X||(e.currentTarget.scrollTop!==0&&(e.currentTarget.scrollTop=0),e.currentTarget.scrollLeft!==0&&(e.currentTarget.scrollLeft=0))},children:w&&!y&&!ne?Ge():w?qe():ne?k?(0,r.jsxs)(`div`,{part:`screen screen-payment`,className:`flex flex-col h-full relative overflow-y-auto ${V?`bg-black text-white`:`bg-white text-gray-900`}`,children:[(0,r.jsxs)(`div`,{part:`screen-header`,className:`p-4 shadow-sm flex justify-between items-center z-10`,style:{backgroundColor:H,color:`white`},children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h2`,{part:`screen-header-title`,className:`text-xl font-bold`,style:Q,children:`Complete Payment`}),(0,r.jsx)(`p`,{className:`text-xs opacity-90 mt-0.5`,children:`Registration Submitted`})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-3`,children:e.displayMode===`popup`&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`button`,{onClick:()=>d(!u),title:u?`Minimize`:`Expand`,className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:u?(0,r.jsx)(Me,{size:18}):(0,r.jsx)(je,{size:18})}),(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:(0,r.jsx)(et,{size:24})})]})})]}),(0,r.jsxs)(`div`,{className:`flex-1 flex flex-col items-center justify-center p-6 text-center`,children:[(0,r.jsx)(`div`,{className:`w-16 h-16 rounded-full flex items-center justify-center mb-4 text-2xl shadow-md`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:`💳`}),(0,r.jsx)(`h3`,{part:`screen-title`,className:`text-2xl font-bold mb-2 ${V?`text-white`:`text-gray-900`}`,style:Q,children:`Done Your Payment First`}),(0,r.jsx)(`p`,{part:`screen-message`,className:`text-sm mb-6 max-w-xs leading-relaxed ${V?`text-zinc-300`:`text-gray-600`}`,children:`Please complete your payment in the new tab to confirm your booking and finalize your registration.`}),ke(),(0,r.jsxs)(`div`,{className:`w-full max-w-xs space-y-3`,children:[(0,r.jsxs)(`a`,{part:`button button-primary`,href:k,target:`_blank`,rel:`noopener noreferrer`,className:`flex items-center justify-center gap-2 font-bold px-5 py-3 rounded-lg transition-opacity hover:opacity-90 text-white shadow-md w-full`,style:{backgroundColor:H},children:[(0,r.jsx)(`span`,{children:`Open Payment Page`}),(0,r.jsx)(_e,{size:16})]}),(0,r.jsx)(`button`,{part:`button button-link`,onClick:Ee,className:`w-full py-2.5 px-4 text-sm font-semibold transition-colors cursor-pointer ${V?`text-zinc-400 hover:text-white`:`text-gray-500 hover:text-gray-900`}`,children:`Register Another Person`})]})]})]}):(0,r.jsxs)(`div`,{part:`screen screen-success`,className:`flex flex-col h-full items-center justify-center p-8 text-center relative ${V?`bg-black text-white`:`bg-white text-gray-900`}`,children:[e.displayMode===`popup`&&(0,r.jsx)(`div`,{className:`absolute top-4 right-4 flex items-center gap-2`,children:(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`cursor-pointer ${V?`text-zinc-400 hover:text-white`:`text-gray-400 hover:text-gray-900`}`,children:(0,r.jsx)(et,{size:24})})}),(0,r.jsx)(`div`,{className:`w-20 h-20 rounded-full flex items-center justify-center mb-6 text-4xl shadow-md`,style:{backgroundColor:H,color:`white`},children:`✓`}),(0,r.jsx)(`h2`,{part:`screen-title`,className:`text-3xl font-bold mb-3 ${V?`text-white`:`text-gray-900`}`,style:Q,children:U?`Abstract Submitted Successfully`:`Thank You!`}),(0,r.jsx)(`p`,{part:`screen-message`,className:`mb-6 ${V?`text-zinc-300`:`text-gray-600`}`,children:U?`Your reference submission number is below.`:`Your registration has been successfully received.`}),ke(),(0,r.jsx)(`button`,{part:`button button-primary`,onClick:Ee,style:{backgroundColor:H},className:`text-white font-bold py-3 px-8 rounded-md hover:opacity-90 transition-opacity shadow-md cursor-pointer`,children:`Back`})]}):O?(0,r.jsxs)(`div`,{part:`screen screen-error`,className:`flex flex-col h-full relative overflow-y-auto ${V?`bg-black text-white`:`bg-white text-gray-900`}`,children:[(0,r.jsxs)(`div`,{part:`screen-header`,className:`p-4 shadow-sm flex justify-between items-center z-10 bg-red-600 text-white`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h2`,{part:`screen-header-title`,className:`text-xl font-bold`,style:Q,children:U?`Submission Failed`:`Registration Failed`}),(0,r.jsx)(`p`,{className:`text-xs opacity-90 mt-0.5`,children:`Please try again`})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-3`,children:e.displayMode===`popup`&&(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:(0,r.jsx)(et,{size:24})})})]}),(0,r.jsxs)(`div`,{className:`flex-1 flex flex-col items-center justify-center p-6 text-center`,children:[(0,r.jsx)(`div`,{className:`w-16 h-16 rounded-full flex items-center justify-center mb-4 text-2xl shadow-md border ${V?`bg-red-950/60 text-red-400 border-red-900`:`bg-red-50 text-red-600 border-red-200`}`,children:`✕`}),(0,r.jsx)(`h3`,{part:`screen-title`,className:`text-2xl font-bold mb-2 ${V?`text-white`:`text-gray-900`}`,style:Q,children:`Submission Error`}),(0,r.jsx)(`p`,{part:`screen-message`,className:`text-sm mb-6 max-w-xs leading-relaxed ${V?`text-zinc-300`:`text-gray-600`}`,children:O}),(0,r.jsxs)(`div`,{className:`w-full max-w-xs space-y-3`,children:[(0,r.jsx)(`button`,{part:`button button-primary`,onClick:()=>ae(null),style:{backgroundColor:H},className:`flex items-center justify-center gap-2 font-bold px-5 py-3 rounded-lg transition-opacity hover:opacity-90 text-white shadow-md w-full cursor-pointer`,children:(0,r.jsx)(`span`,{children:`Try Again`})}),(0,r.jsx)(`button`,{part:`button button-link`,onClick:()=>{ae(null),b(null)},className:`w-full py-2.5 px-4 text-sm font-semibold transition-colors cursor-pointer ${V?`text-zinc-400 hover:text-white`:`text-gray-500 hover:text-gray-900`}`,children:U?`Choose Another Category`:`Choose Another Ticket`})]})]})]}):y?(0,r.jsx)(tt,{schema:U?C:y.form_schema,ticketType:y,theme:e.theme,displayMode:e.displayMode,backgroundStyle:Z,isExpanded:u,onToggleExpand:()=>d(!u),onClose:()=>l(!1),onSubmit:Y,onChange:we,initialValues:Ce,isDark:V,apiClient:G,storage:K,onError:e.onError,onEvent:e.onEvent,showReviewFields:U,onBack:()=>{q.current&&clearTimeout(q.current),b(null)}}):(0,r.jsxs)(`div`,{part:`page`,className:`flex flex-col ${X?`w-full flex-1`:`h-full min-h-0`} ${V?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`}`,children:[(0,r.jsxs)(`div`,{part:`header`,className:`relative overflow-hidden z-10 shrink-0 text-white`,style:{backgroundColor:H,background:`linear-gradient(135deg, ${H} 0%, color-mix(in srgb, ${H} 76%, black) 100%)`},children:[(0,r.jsx)(`div`,{"aria-hidden":`true`,className:`pointer-events-none absolute inset-0 opacity-[0.14]`,style:{backgroundImage:`radial-gradient(circle, rgba(255,255,255,0.9) 1px, transparent 1px)`,backgroundSize:`18px 18px`,maskImage:`linear-gradient(to right, transparent, black 30%, black 70%, transparent)`}}),(0,r.jsx)(`div`,{"aria-hidden":`true`,className:`pointer-events-none absolute -top-24 -right-10 h-64 w-64 rounded-full bg-white/15 blur-3xl`}),ye&&(0,r.jsxs)(`div`,{className:`absolute inset-y-0 right-0 flex max-w-[65%] pointer-events-none select-none`,children:[(0,r.jsx)(`img`,{src:ye,alt:``,"aria-hidden":`true`,className:`h-full w-auto object-cover object-right`}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 left-0 w-2/5`,style:{background:`linear-gradient(to right, color-mix(in srgb, ${H} 80%, black) 0%, transparent 100%)`}})]}),(0,r.jsxs)(`div`,{className:`relative z-[1] max-w-6xl mx-auto w-full px-4 sm:px-6 py-5 sm:py-6 flex justify-between items-center gap-3 min-w-0`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3.5 min-w-0`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-2xl bg-white/15 ring-1 ring-inset ring-white/30 flex items-center justify-center shrink-0 shadow-[inset_0_1px_0_rgba(255,255,255,0.25)]`,children:(0,r.jsx)(We,{size:20,className:`text-white`})}),(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[(0,r.jsx)(`h2`,{part:`header-title`,className:`text-lg sm:text-2xl font-bold tracking-tight leading-tight break-words`,style:Q,children:Le}),(0,r.jsxs)(`span`,{className:`hidden sm:inline-flex shrink-0 items-center gap-1.5 text-[10px] font-semibold px-2 py-0.5 rounded-full bg-white/15 ring-1 ring-inset ring-white/25 uppercase tracking-wider`,children:[(0,r.jsx)(`span`,{className:`h-1.5 w-1.5 rounded-full bg-emerald-300`}),`Official Portal`]})]}),(0,r.jsx)(`p`,{part:`header-subtitle`,className:`text-xs sm:text-sm text-white/80 mt-0.5`,children:U?`Select a category below to submit your abstract`:t===`registration`?`Select a registration type below to begin your application`:`Registration & Profile Management`})]})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-3`,children:e.displayMode===`popup`&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`button`,{onClick:()=>d(!u),title:u?`Minimize`:`Expand`,className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer p-1`,children:u?(0,r.jsx)(Me,{size:18}):(0,r.jsx)(je,{size:18})}),(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer p-1`,children:(0,r.jsx)(et,{size:22})})]})})]})]}),!U&&(0,r.jsx)(`div`,{part:`tabs`,className:`shrink-0 border-b ${V?`border-zinc-800 bg-zinc-900`:`border-slate-200 bg-white`}`,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-3`,children:(0,r.jsx)(`div`,{role:`tablist`,className:`grid grid-cols-2 gap-1 p-1 rounded-xl max-w-md ${V?`bg-zinc-800`:`bg-slate-100`}`,children:[{key:`registration`,label:`Registration Forms`,Icon:P},{key:`attendee`,label:`Attendee Login`,Icon:Te}].map(({key:e,label:n,Icon:a})=>{let o=t===e;return(0,r.jsxs)(`button`,{part:o?`tab tab-active`:`tab`,role:`tab`,"aria-selected":o,type:`button`,onClick:()=>i(e),className:`inline-flex items-center justify-center gap-1.5 sm:gap-2 py-2 px-2 sm:px-3 text-[13px] sm:text-sm font-semibold rounded-lg transition-all cursor-pointer ${o?V?`bg-zinc-950 shadow-sm`:`bg-white shadow-sm ring-1 ring-slate-200/70`:V?`text-zinc-400 hover:text-zinc-200`:`text-slate-500 hover:text-slate-800`}`,style:o?{color:H}:void 0,children:[(0,r.jsx)(a,{size:15,className:`hidden sm:block shrink-0`}),(0,r.jsx)(`span`,{className:`truncate`,children:n})]},e)})})})}),(U||t===`registration`)&&(0,r.jsx)(`div`,{part:`list`,className:`${X?`w-full flex-1`:`overflow-y-auto flex-1 min-h-0 overscroll-contain`} relative ${V?`bg-zinc-950`:`bg-slate-50`}`,style:Z,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-6 sm:py-8 space-y-5`,children:U?Ve():(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`div`,{part:`search`,className:`flex flex-col sm:flex-row sm:items-end sm:justify-between gap-3`,children:[(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsx)(`h3`,{part:`list-title`,className:`text-base sm:text-lg font-semibold tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:U?`Choose a submission category`:`Choose your registration type`}),h.length>0&&(0,r.jsx)(`p`,{part:`list-count`,className:`text-xs mt-0.5 ${V?`text-zinc-400`:`text-slate-500`}`,children:Re?`${ze.length} of ${h.length} options`:`${h.length} ${h.length===1?`option`:`options`} available`})]}),(0,r.jsxs)(`div`,{className:`relative w-full sm:w-72`,children:[(0,r.jsx)(`input`,{part:`input search-input`,type:`text`,value:te,onChange:e=>T(e.target.value),placeholder:U?`Search categories…`:`Search registration types…`,"aria-label":`Search`,className:`w-full h-10 pl-9 pr-8 text-sm rounded-xl border transition-all focus:outline-none focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)] ${V?`bg-zinc-900 border-zinc-700 text-white placeholder:text-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 shadow-[0_1px_2px_rgba(15,23,42,0.04)]`}`}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 left-3 flex items-center pointer-events-none ${V?`text-zinc-500`:`text-slate-400`}`,children:(0,r.jsx)(He,{size:15,className:`block`})}),te&&(0,r.jsx)(`button`,{type:`button`,onClick:()=>T(``),"aria-label":`Clear search`,className:`absolute inset-y-0 right-2.5 flex items-center cursor-pointer ${V?`text-zinc-500 hover:text-zinc-300`:`text-slate-400 hover:text-slate-600`}`,children:(0,r.jsx)(et,{size:14})})]})]}),h.length===0?null:ze.length===0?(0,r.jsxs)(`div`,{part:`empty-state`,className:`flex flex-col items-center text-center py-16 px-6 rounded-3xl border border-dashed ${V?`bg-zinc-900/60 border-zinc-800 text-zinc-400`:`bg-white/70 border-slate-300 text-slate-500`}`,children:[(0,r.jsx)(`div`,{className:`w-12 h-12 rounded-2xl flex items-center justify-center mb-4 ${V?`bg-zinc-800`:`bg-slate-100`}`,children:(0,r.jsx)(He,{size:20})}),(0,r.jsxs)(`p`,{className:`text-base font-semibold ${V?`text-white`:`text-slate-900`}`,children:[`No matches for “`,te.trim(),`”`]}),(0,r.jsx)(`p`,{className:`text-sm mt-1`,children:`Try a different search term.`}),(0,r.jsx)(`button`,{part:`button button-secondary`,onClick:()=>T(``),className:`mt-5 px-4 py-2 rounded-full text-sm font-semibold border cursor-pointer transition-colors ${V?`border-zinc-700 text-zinc-200 hover:bg-zinc-800`:`border-slate-200 bg-white text-slate-700 hover:bg-slate-50`}`,children:`Clear search`})]}):(0,r.jsx)(`div`,{part:`card-grid`,className:X?`grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5`:`space-y-3`,children:ze.map(e=>{let t=e.type||e.name||e.label,n=e.price!==void 0&&e.price!==null&&e.price!==``,i=n&&(Number(e.price)===0||String(e.price).toLowerCase()===`free`),a=Array.isArray(e.perks)?e.perks:[],o=U?ve:Ke;return(0,r.jsxs)(`div`,{part:`card`,role:`button`,tabIndex:0,"aria-label":`Select ${t}`,onClick:()=>b(e),onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),b(e))},className:`group relative flex flex-col rounded-2xl border p-5 sm:p-6 cursor-pointer transition-all duration-300 hover:-translate-y-1 outline-none focus-visible:ring-4 focus-visible:ring-[color-mix(in_srgb,var(--vx-accent)_25%,transparent)] hover:border-[color-mix(in_srgb,var(--vx-accent)_35%,transparent)] ${V?`bg-zinc-900 border-zinc-800 hover:shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04)] hover:shadow-[0_24px_48px_-24px_color-mix(in_srgb,var(--vx-accent)_45%,transparent)]`}`,children:[(0,r.jsx)(`span`,{"aria-hidden":`true`,className:`pointer-events-none absolute inset-x-8 top-0 h-[3px] rounded-b-full opacity-0 transition-opacity duration-300 group-hover:opacity-100`,style:{background:`linear-gradient(90deg, transparent, ${H}, transparent)`}}),(0,r.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-xl flex items-center justify-center shrink-0 transition-transform duration-300 group-hover:scale-105`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:(0,r.jsx)(o,{size:20})}),(e.category||e.seats_left)&&(0,r.jsxs)(`div`,{className:`flex flex-wrap justify-end items-center gap-1.5`,children:[e.category&&(0,r.jsx)(`span`,{part:`card-category`,className:`text-[10px] font-semibold uppercase tracking-wider px-2.5 py-1 rounded-full ${V?`bg-zinc-800 text-zinc-300`:`bg-slate-100 text-slate-600`}`,children:e.category}),e.seats_left&&(0,r.jsxs)(`span`,{part:`card-seats`,className:`text-[10px] font-semibold px-2.5 py-1 rounded-full flex items-center gap-1 ${V?`bg-amber-950/60 text-amber-300`:`bg-amber-50 text-amber-700`}`,children:[(0,r.jsx)(fe,{size:10}),(0,r.jsx)(`span`,{children:e.seats_left})]})]})]}),(0,r.jsx)(`h3`,{part:`card-title`,className:`mt-4 text-lg font-semibold leading-snug tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:t}),e.description&&(0,r.jsx)(`p`,{part:`card-description`,className:`mt-1.5 text-sm leading-relaxed line-clamp-2 ${V?`text-zinc-400`:`text-slate-500`}`,children:e.description}),a.length>0&&(0,r.jsx)(`ul`,{part:`card-perks`,className:`mt-4 space-y-2`,children:a.map((e,t)=>(0,r.jsxs)(`li`,{className:`flex items-start gap-2 text-sm`,children:[(0,r.jsx)(`span`,{className:`mt-0.5 w-4 h-4 rounded-full flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${H} 14%, transparent)`,color:H},children:(0,r.jsx)(se,{size:10,strokeWidth:3})}),(0,r.jsx)(`span`,{className:V?`text-zinc-300`:`text-slate-600`,children:e})]},t))}),(0,r.jsx)(`div`,{className:`flex-1`}),(0,r.jsxs)(`div`,{className:`mt-6 pt-5 border-t border-dashed flex items-end justify-between gap-3 ${V?`border-zinc-800`:`border-slate-200`}`,children:[(0,r.jsx)(`div`,{className:`min-w-0`,children:n&&!U?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`p`,{className:`text-[10px] font-semibold uppercase tracking-wider ${V?`text-zinc-500`:`text-slate-400`}`,children:`Registration fee`}),(0,r.jsx)(`p`,{part:`card-price`,className:`text-2xl font-bold tracking-tight tabular-nums leading-tight`,style:{color:H},children:i?`Free`:[e.currency,Number(e.price).toLocaleString()].filter(Boolean).join(` `)}),e.tax_info&&(0,r.jsx)(`p`,{part:`card-tax`,className:`text-[11px] mt-0.5 ${V?`text-zinc-500`:`text-slate-400`}`,children:e.tax_info})]}):null}),(0,r.jsxs)(`span`,{part:`button button-primary card-button`,className:`inline-flex shrink-0 items-center gap-2 h-10 pl-4 pr-1.5 rounded-full text-sm font-semibold text-white transition-shadow duration-300 group-hover:shadow-[0_8px_20px_-6px_color-mix(in_srgb,var(--vx-accent)_70%,transparent)]`,style:{backgroundColor:H},children:[U?`Submit`:`Register`,(0,r.jsx)(`span`,{className:`w-7 h-7 rounded-full bg-white/20 flex items-center justify-center transition-transform duration-300 group-hover:translate-x-0.5`,children:(0,r.jsx)(ie,{size:14})})]})]})]},e.id)})})]})})}),!U&&(a||t===`attendee`)&&(0,r.jsx)(`div`,{part:`portal`,className:`${t===`attendee`?`flex`:`hidden`} flex-col ${X?`w-full flex-1`:`flex-1 overflow-hidden min-h-0`}`,style:{...X?{}:{overflow:`clip`},...Z},onScroll:X?void 0:e=>{e.currentTarget.scrollTop!==0&&(e.currentTarget.scrollTop=0),e.currentTarget.scrollLeft!==0&&(e.currentTarget.scrollLeft=0)},children:(0,r.jsx)(it,{apiClient:G,storage:K,logger:W,primaryColor:H,isDark:V,isWidgetPage:X,onEvent:e.onEvent,onError:e.onError})})]})})},ut=`/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
|
|
2
|
+
`)[3]||``).match(/(?:at\s+.*?\s+\()?(?:.*?\/([^/]+?)):(\d+):\d+\)?$/);return e?`[${e[1]}:${e[2]}]`:``}},p=class{baseUrl;slug;logger;timeoutMs;constructor(e,t,n,r=12e4){this.baseUrl=e,this.slug=t,this.logger=n,this.timeoutMs=r}async fetchApi(e,t={}){let n=`${this.baseUrl}${e}`;this.logger.log(`API Call: ${t.method||`GET`} ${n} (timeout: ${this.timeoutMs/1e3}s)`);let r=new AbortController,i=setTimeout(()=>r.abort(),this.timeoutMs);t.signal&&t.signal.addEventListener(`abort`,()=>r.abort());try{let e=await fetch(n,{...t,signal:r.signal,headers:{"Content-Type":`application/json`,...t.headers}});clearTimeout(i);let a=null;try{a=await e.json()}catch{}if(!e.ok){let e=`API Error`;if(a){if(typeof a.message==`string`)e=a.message;else if(typeof a.detail==`string`)e=a.detail;else if(typeof a.error==`string`)e=a.error;else if(typeof a==`object`){let t=Object.values(a)[0];Array.isArray(t)&&typeof t[0]==`string`?e=t[0]:typeof t==`string`&&(e=t)}}throw Error(e)}return a}catch(t){if(clearTimeout(i),t?.name===`AbortError`){let t=Error(`Request timed out after ${this.timeoutMs/1e3} seconds`);throw this.logger.error(`API Request timed out for ${e}`,t),t}throw this.logger.error(`API Request failed for ${e}`,t),t}}async getFormSchema(){return this.fetchApi(`/api/public/events/${this.slug}/form-schema/`)}async submitRegistration(e){return this.fetchApi(`/api/public/events/${this.slug}/register/`,{method:`POST`,body:JSON.stringify(e)})}async trackProgress(e){return this.fetchApi(`/api/public/events/${this.slug}/track/`,{method:`POST`,body:JSON.stringify(e)})}async getDraft(e){return this.fetchApi(`/api/public/events/${this.slug}/track/?xref=${encodeURIComponent(e)}`)}async getDraftByEmail(e){try{return await this.fetchApi(`/api/public/events/${this.slug}/track/?email=${encodeURIComponent(e)}`)}catch(t){try{return await this.fetchApi(`/api/public/events/${this.slug}/track/?xref=${encodeURIComponent(e)}`)}catch{throw t}}}async getReviewFormSchema(){return this.fetchApi(`/api/public/events/${this.slug}/review/form-schema/`)}async submitReview(e){return this.fetchApi(`/api/public/events/${this.slug}/review/submit/`,{method:`POST`,body:JSON.stringify(e)})}async trackReviewProgress(e){return this.fetchApi(`/api/public/events/${this.slug}/review/track/`,{method:`POST`,body:JSON.stringify(e)})}async getReviewDraft(e){return this.fetchApi(`/api/public/events/${this.slug}/review/track/?xref=${encodeURIComponent(e)}`)}async getReviewDraftByEmail(e){return this.fetchApi(`/api/public/events/${this.slug}/review/track/?email=${encodeURIComponent(e)}`)}async portalLogin(e){return this.fetchApi(`/api/portal/${this.slug}/login/`,{method:`POST`,body:JSON.stringify(e)})}async portalRequestPasswordReset(e){return this.fetchApi(`/api/portal/${this.slug}/password-reset/`,{method:`POST`,body:JSON.stringify({identifier:e})})}async portalConfirmPasswordReset(e){return this.fetchApi(`/api/portal/${this.slug}/password-reset/`,{method:`POST`,body:JSON.stringify(e)})}async portalGetProfile(e){return this.fetchApi(`/api/portal/${this.slug}/me/`,{method:`GET`,headers:{Authorization:`Bearer ${e}`}})}async uploadFile(e,t,n,r){let i=new FormData;return i.append(`file`,e),r&&i.append(`label`,r),!t&&n&&i.append(`email`,n),this.postAsset(i,t)}async submitTextAnswer(e,t,n,r){let i=new FormData;return i.append(`text`,e),r&&i.append(`label`,r),!t&&n&&i.append(`email`,n),this.postAsset(i,t)}async postAsset(e,t){let n=t||null,r={};n&&(r.Authorization=`Bearer ${n}`);let i=`${this.baseUrl}/api/portal/${this.slug}/me/upload/`;this.logger.log(`API Call: POST ${i} (upload)`);let a=new AbortController,o=setTimeout(()=>a.abort(),this.timeoutMs);try{let t=await fetch(i,{method:`POST`,signal:a.signal,headers:r,body:e});clearTimeout(o);let n=null;try{n=await t.json()}catch{}if(t.ok)return n;let s=n?.message||n?.error||n?.detail||`File upload failed`;throw Error(s)}catch(e){throw clearTimeout(o),e?.name===`AbortError`?Error(`File upload timed out after ${this.timeoutMs/1e3} seconds`):e}}async deleteFile(e,t){let n=encodeURIComponent(String(e).trim()),r=t||null,i={};r&&(i.Authorization=`Bearer ${r}`);let a=[`/api/portal/${this.slug}/me/upload/${n}/`,`/api/portal/${this.slug}/me/upload/${n}`],o=null;for(let e=0;e<a.length;e++){let t=a[e];this.logger.log(`API Call: DELETE ${t}`);try{return await this.fetchApi(t,{method:`DELETE`,headers:i})}catch(t){if(o=t,(t?.message?.includes(`404`)||t?.message?.includes(`405`))&&e<a.length-1)continue;throw t}}throw o}async portalUploadFile(e,t){return this.uploadFile(t,e)}async portalDeleteFile(e,t){return this.deleteFile(t,e)}async portalUpdateProfile(e,t){let n=`${this.baseUrl}/api/portal/${this.slug}/me/`;this.logger.log(`API Call: PATCH ${n}`);let r=new AbortController,i=setTimeout(()=>r.abort(),this.timeoutMs);try{let a=await fetch(n,{method:`PATCH`,signal:r.signal,headers:{"Content-Type":`application/json`,Authorization:`Bearer ${e}`},body:JSON.stringify(t)});a.status===405&&(a=await fetch(n,{method:`PUT`,signal:r.signal,headers:{"Content-Type":`application/json`,Authorization:`Bearer ${e}`},body:JSON.stringify(t)})),clearTimeout(i);let o=null;try{o=await a.json()}catch{}if(!a.ok){let e=o?.message||o?.error||o?.detail||`Failed to update profile`;throw Error(e)}return o}catch(e){throw clearTimeout(i),e?.name===`AbortError`?Error(`Profile update timed out after ${this.timeoutMs/1e3} seconds`):e}}async portalUpdateSubmission(e,t){let n=`${this.baseUrl}/api/portal/${this.slug}/me/submission/`;this.logger.log(`API Call: PATCH ${n}`);let r=new AbortController,i=setTimeout(()=>r.abort(),this.timeoutMs);try{let a=await fetch(n,{method:`PATCH`,signal:r.signal,headers:{"Content-Type":`application/json`,Authorization:`Bearer ${e}`},body:JSON.stringify(t)});clearTimeout(i);let o=null;try{o=await a.json()}catch{}if(!a.ok){let e=o?.message||o?.error||o?.detail||`Failed to update submission`;throw Error(e)}return o}catch(e){throw clearTimeout(i),e?.name===`AbortError`?Error(`Submission update timed out after ${this.timeoutMs/1e3} seconds`):e}}},m=class{prefix;constructor(e){this.prefix=`voxket_${e}_`}generateId(){return typeof crypto<`u`&&typeof crypto.randomUUID==`function`?crypto.randomUUID():`xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx`.replace(/[xy]/g,e=>{let t=Math.random()*16|0;return(e===`x`?t:t&3|8).toString(16)})}getXrefId(){let e=`${this.prefix}xref_id`,t=localStorage.getItem(e);return t||(t=this.generateId(),localStorage.setItem(e,t)),t}updateXrefId(){let e=`${this.prefix}xref_id`,t=this.generateId();return localStorage.setItem(e,t),t}clearXrefId(){let e=`${this.prefix}xref_id`;localStorage.removeItem(e)}setToken(e){localStorage.setItem(`${this.prefix}token`,e)}getToken(){return localStorage.getItem(`${this.prefix}token`)}clearToken(){localStorage.removeItem(`${this.prefix}token`)}},h=e=>e?.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase();function g(e,t,n=[]){if(t==null)throw Error(`[lucide]: iconNode is required when icon name is used`);return{name:h(e),size:24,node:t,...n.length>0?{aliases:n}:{}}}var _=e=>{let t=``,n=!1;for(let r of e){if(r===`-`||r===`_`||r<=` `){n=t.length>0;continue}t.length===0?t+=r.toLowerCase():t+=n?r.toUpperCase():r,n=!1}return t},v=e=>{let t=_(e);return t.charAt(0).toUpperCase()+t.slice(1)},y=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),b={xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":2,"stroke-linecap":`round`,"stroke-linejoin":`round`};function x(e){return e!=null}function S(e,t={}){let n=t.attributeNames??{},r=e=>n[e]??e,i=e.size??e.width??b.width,a=e.size??e.height??b.height,o=e.aliases?.filter(e=>typeof e==`string`&&e.trim()!==``).map(e=>`lucide-${e}`)??[],s=[...e.name?[`lucide-${e.name}`]:[],...o],c=t.className?.split(` `).filter(Boolean)??[],l=t.includeDefaultClasses===!1?y(...c):y(`lucide`,...s,...c),u=t.absoluteStrokeWidth?Number(t.strokeWidth??b[`stroke-width`])*Number(e.size??e.width??b.width)/Number(t.size??t.width??b.width):t.strokeWidth??b[`stroke-width`];return[`svg`,{...Object.entries(b).reduce((e,[t,n])=>(e[r(t)]=n,e),{}),...`color`in t&&t.color&&{[r(`stroke`)]:t.color},...`size`in t&&x(t.size)&&{[r(`width`)]:t.size,[r(`height`)]:t.size},...`width`in t&&x(t.width)&&{[r(`width`)]:t.width},...`height`in t&&x(t.height)&&{[r(`height`)]:t.height},[r(`stroke-width`)]:u,...l&&{[r(`class`)]:l},[r(`viewBox`)]:`0 0 ${i} ${a}`,...t.hasA11yProp===!1?{[r(`aria-hidden`)]:`true`}:{},...`attributes`in t&&t.attributes},e.node.map(e=>{let[n,i,a]=e,o=t.nonScalingStroke?{[r(`vector-effect`)]:`non-scaling-stroke`,...i}:i;return a?[n,o,a]:[n,o]})]}function C(e,t={}){return S(e,{...t,attributeNames:{...t.attributeNames,class:`className`,"stroke-width":`strokeWidth`,"stroke-linecap":`strokeLinecap`,"stroke-linejoin":`strokeLinejoin`,"vector-effect":`vectorEffect`}})}var w=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},ee=(0,n.createContext)({}),te=()=>(0,n.useContext)(ee),T=(0,n.forwardRef)(({color:e,size:t,width:r,height:i,strokeWidth:a,absoluteStrokeWidth:o,nonScalingStroke:s,className:c=``,children:l,iconNode:u=[],icon:d={node:u,aliases:[],size:24},...f},p)=>{let{size:m=24,strokeWidth:h=2,absoluteStrokeWidth:g=!1,nonScalingStroke:_=!1,color:v=`currentColor`,className:b=``}=te()??{},x=!!l||w(f),[S,ee,T=[]]=C(d,{color:e??v,width:r??t??m,height:i??t??m,strokeWidth:a??h,absoluteStrokeWidth:o??g,nonScalingStroke:s??_,className:y(b,c),hasA11yProp:x,attributes:f});return(0,n.createElement)(S,{ref:p,...ee},[...T.map(([e,t])=>(0,n.createElement)(e,t)),...Array.isArray(l)?l:[l]])});function E(e,t=[],r=[]){let i=typeof e==`string`?g(e,t,r):e,a=(0,n.forwardRef)(({className:e,...t},r)=>(0,n.createElement)(T,{ref:r,icon:i,className:e,...t}));return i.name&&(a.displayName=v(i.name)),a}var D={name:`arrow-left`,size:24,node:[[`path`,{d:`m12 19-7-7 7-7`,key:`1l729n`}],[`path`,{d:`M19 12H5`,key:`x3x0zl`}]]};D.node;var ne=E(D),re={name:`arrow-right`,size:24,node:[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`m12 5 7 7-7 7`,key:`xquz4c`}]]};re.node;var ie=E(re),O={name:`briefcase`,size:24,node:[[`path`,{d:`M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16`,key:`jecpp`}],[`rect`,{width:`20`,height:`14`,x:`2`,y:`6`,rx:`2`,key:`i6l2r4`}]]};O.node;var ae=E(O),k={name:`building-complex`,size:24,node:[[`path`,{d:`M10 12h4`,key:`a56b0p`}],[`path`,{d:`M10 8h4`,key:`1sr2af`}],[`path`,{d:`M14 21v-3a2 2 0 0 0-4 0v3`,key:`1rgiei`}],[`path`,{d:`M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2`,key:`secmi2`}],[`path`,{d:`M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16`,key:`16ra0t`}]],aliases:[`building-2`]};k.node;var oe=E(k),A={name:`check`,size:24,node:[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]};A.node;var se=E(A),ce={name:`chevron-down`,size:24,node:[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]};ce.node;var le=E(ce),j={name:`circle-alert`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`line`,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,key:`1pkeuh`}],[`line`,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,key:`4dfq90`}]],aliases:[`alert-circle`]};j.node;var ue=E(j),de={name:`circle-check-big`,size:24,node:[[`path`,{d:`M21.801 10A10 10 0 1 1 17 3.335`,key:`yps3ct`}],[`path`,{d:`m9 11 3 3L22 4`,key:`1pflzl`}]],aliases:[`check-circle`]};de.node;var M=E(de),N={name:`clipboard-list`,size:24,node:[[`rect`,{width:`8`,height:`4`,x:`8`,y:`2`,rx:`1`,ry:`1`,key:`tgr4d6`}],[`path`,{d:`M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2`,key:`116196`}],[`path`,{d:`M12 11h4`,key:`1jrz19`}],[`path`,{d:`M12 16h4`,key:`n85exb`}],[`path`,{d:`M8 11h.01`,key:`1dfujw`}],[`path`,{d:`M8 16h.01`,key:`18s6g9`}]]};N.node;var P=E(N),F={name:`clock`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6l4 2`,key:`mmk7yg`}]]};F.node;var fe=E(F),I={name:`copy`,size:24,node:[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]};I.node;var pe=E(I),L={name:`credit-card`,size:24,node:[[`rect`,{width:`20`,height:`14`,x:`2`,y:`5`,rx:`2`,key:`ynyp8z`}],[`line`,{x1:`2`,x2:`22`,y1:`10`,y2:`10`,key:`1b3vmo`}],[`path`,{d:`M6 14h2`,key:`mk7k0u`}]]};L.node;var me=E(L),he={name:`download`,size:24,node:[[`path`,{d:`M12 15V3`,key:`m9g1x1`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}],[`path`,{d:`m7 10 5 5 5-5`,key:`brsn70`}]]};he.node;var ge=E(he),R={name:`external-link`,size:24,node:[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]};R.node;var _e=E(R),z={name:`file-text`,size:24,node:[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 9H8`,key:`b1mrlr`}],[`path`,{d:`M16 13H8`,key:`t4e002`}],[`path`,{d:`M16 17H8`,key:`z1uh3a`}]]};z.node;var ve=E(z),B={name:`folder-open`,size:24,node:[[`path`,{d:`m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2`,key:`usdka0`}]]};B.node;var V=E(B),H={name:`graduation-cap`,size:24,node:[[`path`,{d:`M21.42 10.922a1 1 0 0 0-.019-1.838L12.83 5.18a2 2 0 0 0-1.66 0L2.6 9.08a1 1 0 0 0 0 1.832l8.57 3.908a2 2 0 0 0 1.66 0z`,key:`j76jl0`}],[`path`,{d:`M22 10v6`,key:`1lu8f3`}],[`path`,{d:`M6 12.5V16a6 3 0 0 0 12 0v-3.5`,key:`1r8lef`}]]};H.node;var U=E(H),ye={name:`id-card`,size:24,node:[[`path`,{d:`M13 19a4 4 0 00-8 0`,key:`cugzd5`}],[`path`,{d:`M16 10h2`,key:`8sgtl7`}],[`path`,{d:`M16 14h2`,key:`epxaof`}],[`circle`,{cx:`9`,cy:`12`,r:`3`,key:`u3jwor`}],[`rect`,{x:`2`,y:`5`,width:`20`,height:`14`,rx:`2`,key:`qneu4z`}]]};ye.node;var be=E(ye),W={name:`info`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 16v-4`,key:`1dtifu`}],[`path`,{d:`M12 8h.01`,key:`e9boi3`}]]};W.node;var G=E(W),K={name:`key-round`,size:24,node:[[`path`,{d:`M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z`,key:`1s6t7t`}],[`circle`,{cx:`16.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`w0ekpg`}]]};K.node;var xe=E(K),q={name:`key`,size:24,node:[[`path`,{d:`m2 21 9.6-9.6`,key:`9l79m3`}],[`path`,{d:`m7.5 15.5 2.3 2.3a1 1 0 0 1 0 1.4l-2.1 2.1a1 1 0 0 1-1.4 0L4 19`,key:`fw8biw`}],[`circle`,{cx:`15.5`,cy:`7.5`,r:`5.5`,key:`4wxmhb`}]]};q.node;var J=E(q),Se={name:`lock`,size:24,node:[[`rect`,{width:`18`,height:`11`,x:`3`,y:`11`,rx:`2`,ry:`2`,key:`1w4ew1`}],[`path`,{d:`M7 11V7a5 5 0 0 1 10 0v4`,key:`fwvmzm`}]]};Se.node;var Ce=E(Se),we={name:`log-in`,size:24,node:[[`path`,{d:`m10 17 5-5-5-5`,key:`1bsop3`}],[`path`,{d:`M15 12H3`,key:`6jk70r`}],[`path`,{d:`M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4`,key:`u53s6r`}]]};we.node;var Te=E(we),Y={name:`log-out`,size:24,node:[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]};Y.node;var Ee=E(Y),De={name:`mail`,size:24,node:[[`path`,{d:`m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7`,key:`132q7q`}],[`rect`,{x:`2`,y:`4`,width:`20`,height:`16`,rx:`2`,key:`izxlao`}]]};De.node;var Oe=E(De),ke={name:`map-pin`,size:24,node:[[`path`,{d:`M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0`,key:`1r0f0z`}],[`circle`,{cx:`12`,cy:`10`,r:`3`,key:`ilqhr7`}]]};ke.node;var Ae=E(ke),X={name:`maximize-2`,size:24,node:[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`m21 3-7 7`,key:`1l2asr`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M9 21H3v-6`,key:`wtvkvv`}]]};X.node;var je=E(X),Z={name:`minimize-2`,size:24,node:[[`path`,{d:`m14 10 7-7`,key:`oa77jy`}],[`path`,{d:`M20 10h-6V4`,key:`mjg0md`}],[`path`,{d:`m3 21 7-7`,key:`tjx5ai`}],[`path`,{d:`M4 14h6v6`,key:`rmj7iw`}]]};Z.node;var Me=E(Z),Ne={name:`move`,size:24,node:[[`path`,{d:`M12 2v20`,key:`t6zp3m`}],[`path`,{d:`m15 19-3 3-3-3`,key:`11eu04`}],[`path`,{d:`m19 9 3 3-3 3`,key:`1mg7y2`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}],[`path`,{d:`m5 9-3 3 3 3`,key:`j64kie`}],[`path`,{d:`m9 5 3-3 3 3`,key:`l8vdw6`}]]};Ne.node;var Pe=E(Ne),Fe={name:`package-check`,size:24,node:[[`path`,{d:`M12 22V12`,key:`d0xqtd`}],[`path`,{d:`m16 17 2 2 4-4`,key:`uh5qu3`}],[`path`,{d:`M21 11.127V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.729l7 4a2 2 0 0 0 2 .001l1.32-.753`,key:`kpkbpo`}],[`path`,{d:`M3.29 7 12 12l8.71-5`,key:`19ckod`}],[`path`,{d:`m7.5 4.27 8.997 5.148`,key:`9yrvtv`}]]};Fe.node;var Ie=E(Fe),Le={name:`phone`,size:24,node:[[`path`,{d:`M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384`,key:`9njp5v`}]]};Le.node;var Re=E(Le),ze={name:`receipt`,size:24,node:[[`path`,{d:`M12 17V7`,key:`pyj7ub`}],[`path`,{d:`M16 8h-6a2 2 0 0 0 0 4h4a2 2 0 0 1 0 4H8`,key:`1elt7d`}],[`path`,{d:`M4 3a1 1 0 0 1 1-1 1.3 1.3 0 0 1 .7.2l.933.6a1.3 1.3 0 0 0 1.4 0l.934-.6a1.3 1.3 0 0 1 1.4 0l.933.6a1.3 1.3 0 0 0 1.4 0l.933-.6a1.3 1.3 0 0 1 1.4 0l.934.6a1.3 1.3 0 0 0 1.4 0l.933-.6A1.3 1.3 0 0 1 19 2a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1 1.3 1.3 0 0 1-.7-.2l-.933-.6a1.3 1.3 0 0 0-1.4 0l-.934.6a1.3 1.3 0 0 1-1.4 0l-.933-.6a1.3 1.3 0 0 0-1.4 0l-.933.6a1.3 1.3 0 0 1-1.4 0l-.934-.6a1.3 1.3 0 0 0-1.4 0l-.933.6a1.3 1.3 0 0 1-.7.2 1 1 0 0 1-1-1z`,key:`ycz6yz`}]]};ze.node;var Be=E(ze),Ve={name:`search`,size:24,node:[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]};Ve.node;var He=E(Ve),Ue={name:`sparkles`,size:24,node:[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]],aliases:[`stars`]};Ue.node;var We=E(Ue),Ge={name:`ticket`,size:24,node:[[`path`,{d:`M2 9a3 3 0 0 1 0 6v2a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-2a3 3 0 0 1 0-6V7a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2Z`,key:`qn84l0`}],[`path`,{d:`M13 5v2`,key:`dyzc3o`}],[`path`,{d:`M13 17v2`,key:`1ont0d`}],[`path`,{d:`M13 11v2`,key:`1wjjxi`}]]};Ge.node;var Ke=E(Ge),qe={name:`trash`,size:24,node:[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]],aliases:[`trash-2`]};qe.node;var Je=E(qe),Ye={name:`upload`,size:24,node:[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]};Ye.node;var Xe=E(Ye),Ze={name:`user`,size:24,node:[[`path`,{d:`M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2`,key:`975kel`}],[`circle`,{cx:`12`,cy:`7`,r:`4`,key:`17ys0d`}]]};Ze.node;var Qe=E(Ze),$e={name:`x`,size:24,node:[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]};$e.node;var et=E($e),Q={fontFamily:`var(--vx-font-heading)`},tt=({schema:e,onSubmit:t,onBack:i,theme:a,displayMode:o,isExpanded:s,onToggleExpand:c,onClose:l,onChange:u,initialValues:d,isDark:f=!1,apiClient:p,storage:m,onError:h,onEvent:g,backgroundStyle:_,ticketType:v,showReviewFields:y=!1})=>{let[b,x]=(0,n.useState)(d||{}),[S,C]=(0,n.useState)(null),[w,ee]=(0,n.useState)(null),[te,T]=(0,n.useState)({}),[E,D]=(0,n.useState)({}),[re,O]=(0,n.useState)(null),[ae,k]=(0,n.useState)(null),[oe,A]=(0,n.useState)({}),[ce,j]=(0,n.useState)({}),[ue,de]=(0,n.useState)({}),M=a?.primaryColor||`#c026d3`;(0,n.useEffect)(()=>{if(d&&Object.keys(d).length>0){x(e=>({...d,...e}));let t={},n={};(e?.fields||[]).forEach(e=>{if(e.type===`file`){let r=d[e.id];r&&(String(r).startsWith(`http://`)||String(r).startsWith(`https://`)?n[e.id]=String(r):t[e.id]=String(r))}}),Object.keys(t).length>0&&T(e=>({...t,...e})),Object.keys(n).length>0&&D(e=>({...n,...e}))}},[d,e]);let N=(e,t)=>{x(n=>{let r={...n,[e]:t};return u?.(r),r})},P=async(t,n)=>{if(!p)return;C(t),O(null),k(null);let r=m?.getToken?.()||null,i=te[t],a=(e?.fields||[]).find(e=>e.id===t);try{let e=await p.uploadFile(n,r,r?null:I(),a?.label),o=e?.data?.asset_id||e?.asset_id,s=e?.data?.serve_url||e?.serve_url;if(!o&&!s)throw Error(`Upload response missing asset_id`);let c=String(o||s),l=String(s||``);if(T(e=>({...e,[t]:c})),l&&D(e=>({...e,[t]:l})),x(e=>{let n={...e,[t]:c};return u?.(n),n}),g?.(`file_uploaded`,{fieldId:t,assetId:c,serveUrl:l}),i&&i!==c)try{await p.deleteFile(i,r),g?.(`file_deleted`,{fieldId:t,assetId:i})}catch(e){console.warn(`[DynamicForm] Could not delete old file`,e)}}catch(e){let n=e?.message||`File upload failed. Please try again.`;O(n),k(t),h?.({type:`file_upload_error`,message:n,error:e})}finally{C(null)}},F=async e=>{if(!p)return;let t=m?.getToken?.()||null,n=te[e]||b[e];ee(e),O(null),k(null);try{n&&(await p.deleteFile(n,t),g?.(`file_deleted`,{fieldId:e,assetId:n})),T(t=>{let n={...t};return delete n[e],n}),D(t=>{let n={...t};return delete n[e],n}),de(t=>{let n={...t};return delete n[e],n}),j(t=>{let n={...t};return delete n[e],n}),x(t=>{let n={...t,[e]:``};return u?.(n),n})}catch(t){let n=t?.message||`Failed to delete file. Please try again.`;O(n),k(e),h?.({type:`file_delete_error`,message:n,error:t})}finally{ee(null)}},fe=async(t,n)=>{if(!p||!n.trim())return;C(t),O(null),k(null);let r=m?.getToken?.()||null,i=te[t],a=(e?.fields||[]).find(e=>e.id===t);try{let e=await p.submitTextAnswer(n.trim(),r,r?null:I(),a?.label),o=e?.data?.asset_id||e?.asset_id;if(!o)throw Error(`Submission response missing asset_id`);let s=String(o);if(T(e=>({...e,[t]:s})),D(e=>{let n={...e};return delete n[t],n}),de(e=>({...e,[t]:n.trim()})),x(e=>{let n={...e,[t]:s};return u?.(n),n}),g?.(`file_uploaded`,{fieldId:t,assetId:s,isText:!0}),i&&i!==s)try{await p.deleteFile(i,r),g?.(`file_deleted`,{fieldId:t,assetId:i})}catch(e){console.warn(`[DynamicForm] Could not delete old file`,e)}}catch(e){let n=e?.message||`Could not submit your answer. Please try again.`;O(n),k(t),h?.({type:`file_upload_error`,message:n,error:e})}finally{C(null)}},I=()=>{let t=(e?.fields||[]).find(e=>e.type===`email`||(e.label||e.id||``).toLowerCase().includes(`email`));return String(t&&b[t.id]||b.email||``).trim()},pe=e?.fields||[],L=e=>{if(e.description)return e.description;if(e.helperText)return e.helperText;let t=(e.label||e.id||``).toLowerCase(),n=e.type;return n===`email`||t.includes(`email`)||t.includes(`mail`)?`Please enter a valid email address. Your abstract acknowledgement, review updates, and final communication will be sent to this mailbox.`:n===`phone`||t.includes(`phone`)||t.includes(`mobile`)||t.includes(`contact`)?`Please enter a valid mobile number for SMS confirmations and important notifications.`:t.includes(`council`)||t.includes(`registration no`)||t.includes(`mci`)?`Enter your State Medical Council or National Medical Commission registration number.`:n===`file`||t.includes(`file`)||t.includes(`upload`)||t.includes(`bonafide`)||t.includes(`abstract`)?`Upload your document (PDF, JPG, PNG up to 10MB) for registration review and verification.`:t.includes(`salutation`)||t.includes(`title`)?`Choose your professional title or academic prefix.`:null},me=e=>{let t=E[e.id]||(b[e.id]&&String(b[e.id]).startsWith(`http`)?b[e.id]:``),n=ue[e.id],i=oe[e.id]||`file`,a=S===e.id||w===e.id,o=ce[e.id]||``,s=o.trim()?o.trim().split(/\s+/).length:0,c=!!e.word_limit&&s>e.word_limit;return(0,r.jsx)(`div`,{className:`space-y-2 mt-2`,children:(0,r.jsxs)(`div`,{part:`upload`,className:`p-4 sm:p-5 rounded-2xl border border-dashed transition-all ${f?`bg-zinc-850/80 border-zinc-700 hover:border-zinc-600`:`bg-slate-50 border-slate-300 hover:border-[color-mix(in_srgb,var(--vx-accent)_45%,transparent)]`}`,children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-3 flex-wrap`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,r.jsx)(`div`,{className:`w-10 h-10 rounded-xl flex items-center justify-center shrink-0 border`,style:{backgroundColor:f?`rgba(255,255,255,0.06)`:`color-mix(in srgb, ${M} 10%, white)`,borderColor:f?`rgba(255,255,255,0.12)`:`color-mix(in srgb, ${M} 25%, white)`,color:M},children:(0,r.jsx)(V,{size:18})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`p`,{className:`text-xs font-bold ${f?`text-zinc-200`:`text-gray-900`}`,children:e.label}),(0,r.jsx)(`p`,{className:`text-2xs font-medium ${f?`text-zinc-400`:`text-gray-500`}`,children:t?`Document attached successfully`:n?`Text submitted successfully`:i===`file`?`Click to choose or upload your document (PDF, JPG, PNG)`:`Enter your text below`})]})]}),(0,r.jsx)(`button`,{type:`button`,disabled:a,onClick:()=>A(t=>({...t,[e.id]:i===`file`?`text`:`file`})),className:`flex items-center gap-1 text-2xs font-semibold px-2.5 py-1 rounded-lg border cursor-pointer transition-colors hover:opacity-80 disabled:opacity-50 shrink-0`,style:{color:M,borderColor:`color-mix(in srgb, ${M} 35%, transparent)`},children:i===`file`?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(ve,{size:11}),` Send text only`]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(Xe,{size:11}),` Send file`]})})]}),i===`file`?(0,r.jsxs)(`div`,{className:`flex items-center gap-2 flex-wrap mt-3`,children:[(0,r.jsxs)(`label`,{className:`cursor-pointer relative`,children:[(0,r.jsx)(`input`,{type:`file`,className:`hidden`,style:{display:`none`},tabIndex:-1,disabled:a,onChange:t=>{let n=t.target.files?.[0];n&&P(e.id,n),t.target.value=``}}),(0,r.jsxs)(`div`,{className:`flex items-center gap-1.5 py-2 px-3.5 rounded-xl text-xs font-semibold border transition-all shadow-2xs ${f?`border-zinc-700 hover:border-zinc-600 text-zinc-200 bg-zinc-800 hover:bg-zinc-750`:`border-slate-200 hover:border-slate-300 text-slate-700 bg-white hover:bg-slate-50`}`,children:[(0,r.jsx)(Xe,{size:14,style:{color:M}}),(0,r.jsx)(`span`,{children:S===e.id?`Uploading...`:t?`Replace File`:`Choose File`})]})]}),t&&typeof t==`string`&&t.trim()!==``&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`button`,{type:`button`,onClick:()=>window.open(t,`_blank`,`noopener,noreferrer`),className:`flex items-center gap-1.5 py-2 px-3.5 rounded-xl text-xs font-semibold text-white shadow-xs transition-opacity hover:opacity-90 shrink-0 cursor-pointer`,style:{backgroundColor:M},title:`Open file in new tab`,children:[(0,r.jsx)(ve,{size:13}),(0,r.jsx)(`span`,{children:`View`}),(0,r.jsx)(_e,{size:11})]}),(0,r.jsxs)(`button`,{type:`button`,disabled:w===e.id||S===e.id,onClick:()=>F(e.id),className:`flex items-center gap-1 py-2 px-3 rounded-xl text-xs font-semibold border transition-colors cursor-pointer ${f?`border-red-900/60 bg-red-950/50 text-red-400 hover:bg-red-900/60`:`border-red-200 bg-red-50 text-red-600 hover:bg-red-100`}`,title:`Delete uploaded file`,children:[(0,r.jsx)(Je,{size:13}),(0,r.jsx)(`span`,{children:w===e.id?`Deleting...`:`Delete`})]})]})]}):(0,r.jsxs)(`div`,{className:`mt-3 pt-3 border-t space-y-2 ${f?`border-zinc-800`:`border-slate-200`}`,children:[(0,r.jsx)(`textarea`,{part:`input textarea`,rows:3,disabled:a||!!n,value:n??o,onChange:t=>j(n=>({...n,[e.id]:t.target.value})),placeholder:`Enter your answer...`,className:`w-full px-3 py-2 text-sm rounded-xl border focus:outline-none transition-all disabled:opacity-70 ${f?`bg-zinc-900 border-zinc-700 text-white placeholder-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`}),(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-2`,children:[e.word_limit?(0,r.jsxs)(`span`,{className:`text-2xs font-medium ${c?`text-red-500`:f?`text-zinc-500`:`text-gray-500`}`,children:[s,`/`,e.word_limit,` words`]}):(0,r.jsx)(`span`,{}),n?(0,r.jsxs)(`button`,{type:`button`,disabled:a,onClick:()=>F(e.id),className:`flex items-center gap-1 py-2 px-3 rounded-xl text-xs font-semibold border transition-colors cursor-pointer ${f?`border-red-900/60 bg-red-950/50 text-red-400 hover:bg-red-900/60`:`border-red-200 bg-red-50 text-red-600 hover:bg-red-100`}`,children:[(0,r.jsx)(Je,{size:13}),(0,r.jsx)(`span`,{children:w===e.id?`Clearing...`:`Clear & Re-enter`})]}):(0,r.jsxs)(`button`,{type:`button`,disabled:a||!o.trim(),onClick:()=>fe(e.id,o),style:{backgroundColor:M},className:`flex items-center gap-1.5 px-4 py-2 rounded-xl text-xs font-bold text-white shadow-sm hover:opacity-90 transition-all cursor-pointer disabled:opacity-50`,children:[(0,r.jsx)(Xe,{size:13}),(0,r.jsx)(`span`,{children:S===e.id?`Submitting...`:`Submit Text`})]})]})]}),t&&(0,r.jsxs)(`div`,{className:`mt-2.5 pt-2 border-t text-2xs truncate flex items-center gap-1.5 ${f?`border-zinc-800 text-zinc-300`:`border-gray-200 text-gray-700 font-medium`}`,children:[(0,r.jsx)(se,{size:12,className:`text-emerald-500 shrink-0`}),(0,r.jsxs)(`span`,{className:`truncate`,children:[`Attached: `,t]})]}),re&&ae===e.id&&(0,r.jsx)(`div`,{className:`text-xs text-red-500 mt-2 font-medium`,children:re})]})})},he=e=>{if(!e)return null;let t=b[e.id]??``,n=L(e),i=e.type===`email`||(e.label||``).toLowerCase().includes(`email`),a=(e.label||``).toLowerCase().includes(`name`),o=`vx-field-${e.id}`,s=`w-full px-4 py-3 text-[15px] font-medium rounded-xl border transition-all focus:outline-none ${f?`bg-zinc-900 border-zinc-700 text-white placeholder:text-zinc-500 hover:border-zinc-600 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_20%,transparent)]`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 hover:border-slate-300 shadow-[0_1px_2px_rgba(15,23,42,0.04)] focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`;return(0,r.jsxs)(`div`,{part:`field`,className:`px-5 sm:px-8 py-5 sm:py-6`,children:[(0,r.jsx)(`div`,{className:`flex items-center justify-between gap-2 mb-1`,children:(0,r.jsxs)(`label`,{part:`field-label`,htmlFor:o,className:`block text-sm font-semibold ${f?`text-zinc-100`:`text-slate-900`}`,children:[e.label,e.required&&(0,r.jsx)(`span`,{className:`text-red-500 font-semibold ml-0.5`,children:`*`})]})}),n&&(0,r.jsx)(`p`,{part:`field-description`,className:`text-xs leading-relaxed mb-3 ${f?`text-zinc-400`:`text-slate-500`}`,children:n}),!n&&(0,r.jsx)(`div`,{className:`h-1.5`}),e.type===`select`?(0,r.jsxs)(`div`,{className:`relative`,children:[(0,r.jsxs)(`select`,{part:`input select`,id:o,required:e.required,value:t,onChange:t=>N(e.id,t.target.value),className:`${s} pr-10 appearance-none cursor-pointer`,children:[(0,r.jsx)(`option`,{value:``,className:f?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:e.placeholder||`Select ${e.label}...`}),(e.options||[]).map(e=>(0,r.jsx)(`option`,{value:e,className:f?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:e},e))]}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 right-0 flex items-center pr-3.5 pointer-events-none ${f?`text-zinc-400`:`text-slate-400`}`,children:(0,r.jsx)(le,{size:16})})]}):e.type===`file`?me(e):(0,r.jsx)(`input`,{part:`input`,id:o,type:e.type===`phone`?`tel`:e.type===`email`?`email`:e.type===`number`?`number`:`text`,required:e.required,value:t,placeholder:e.placeholder||(i?`Enter your email address`:a?`Your full name`:`Enter your ${e.label.toLowerCase()}`),onChange:t=>N(e.id,t.target.value),className:s})]},e.id)},ge=e=>{e.preventDefault();for(let e of pe)if(e.type===`file`&&e.required&&!b[e.id]){O(`Please upload ${e.label||`a file`}`),k(e.id);return}t(b)},R=v?.type||v?.name||v?.label||(y?`Abstract Submission Form`:`Registration Form`),z=v?Number(v.price)>0?[v.currency,Number(v.price).toLocaleString()].filter(Boolean).join(` `):`Free`:null;return(0,r.jsxs)(`div`,{part:`form-page`,className:`w-full flex-1 flex flex-col relative ${f?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`}`,style:_,children:[(0,r.jsx)(`div`,{part:`form-header`,className:`sticky top-0 z-30 px-4 sm:px-6 py-3 border-b backdrop-blur-xl transition-colors ${f?`bg-zinc-900/85 border-zinc-800`:`bg-white/85 border-slate-200/80`}`,children:(0,r.jsxs)(`div`,{className:`max-w-3xl mx-auto flex items-center justify-between gap-3`,children:[(0,r.jsxs)(`button`,{part:`button button-secondary back-button`,type:`button`,onClick:i,className:`inline-flex items-center gap-2 text-sm font-semibold rounded-full pl-2.5 pr-4 py-2 border transition-colors cursor-pointer ${f?`bg-zinc-800 border-zinc-700 hover:bg-zinc-700 text-zinc-200`:`bg-white border-slate-200 hover:bg-slate-50 text-slate-700 shadow-[0_1px_2px_rgba(15,23,42,0.04)]`}`,children:[(0,r.jsx)(ne,{size:16}),(0,r.jsx)(`span`,{children:`All forms`})]}),(0,r.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[v&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`span`,{part:`form-type-name`,title:R,className:`hidden sm:inline-block truncate max-w-[16rem] text-xs font-semibold px-3 py-1.5 rounded-full ${f?`bg-zinc-800 text-zinc-200`:`bg-slate-100 text-slate-700`}`,children:R}),!y&&(0,r.jsx)(`span`,{part:`form-type-price`,className:`shrink-0 text-xs font-bold px-3 py-1.5 rounded-full tabular-nums`,style:{backgroundColor:`color-mix(in srgb, ${M} 12%, transparent)`,color:M},children:z})]}),o===`popup`&&(0,r.jsxs)(`div`,{className:`flex items-center gap-1.5 ml-2 border-l pl-2 ${f?`border-zinc-700`:`border-slate-200`}`,children:[(0,r.jsx)(`button`,{onClick:c,className:`p-1.5 opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,title:s?`Minimize`:`Expand`,children:s?(0,r.jsx)(Me,{size:16}):(0,r.jsx)(je,{size:16})}),(0,r.jsx)(`button`,{onClick:l,className:`p-1.5 opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:(0,r.jsx)(et,{size:18})})]})]})]})}),(0,r.jsx)(`div`,{className:`w-full flex-1 overflow-y-auto`,children:(0,r.jsxs)(`form`,{part:`form`,onSubmit:ge,className:`max-w-3xl mx-auto w-full px-4 sm:px-6 py-8 sm:py-10 space-y-5`,children:[(0,r.jsxs)(`div`,{part:`form-intro`,className:`px-1`,children:[(0,r.jsx)(`p`,{className:`text-xs font-semibold uppercase tracking-wider`,style:{color:M},children:y?`Abstract submission`:`Registration form`}),(0,r.jsx)(`h2`,{part:`form-title`,className:`mt-1.5 text-2xl sm:text-3xl font-bold tracking-tight ${f?`text-white`:`text-slate-900`}`,style:Q,children:R})]}),d&&Object.keys(d).length>0&&(0,r.jsxs)(`div`,{className:`text-sm px-4 py-3 rounded-2xl flex items-center gap-2.5 ${f?`bg-emerald-950/50 text-emerald-300 ring-1 ring-inset ring-emerald-900`:`bg-emerald-50 text-emerald-800 ring-1 ring-inset ring-emerald-200/80`}`,children:[(0,r.jsx)(se,{size:16,className:`shrink-0`}),(0,r.jsx)(`span`,{className:`font-medium`,children:`We restored your previously saved progress.`})]}),(0,r.jsxs)(`div`,{part:`notice`,className:`rounded-2xl p-4 flex items-start gap-3`,style:{backgroundColor:`color-mix(in srgb, ${M} ${f?14:7}%, transparent)`,boxShadow:`inset 0 0 0 1px color-mix(in srgb, ${M} 20%, transparent)`},children:[(0,r.jsx)(`div`,{className:`shrink-0 mt-0.5`,style:{color:M},children:(0,r.jsx)(G,{size:18})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{part:`notice-title`,className:`text-xs font-bold uppercase tracking-wider`,style:{color:M},children:`Before you submit`}),(0,r.jsxs)(`p`,{className:`text-sm mt-0.5 leading-relaxed ${f?`text-zinc-300`:`text-slate-600`}`,children:[`Ensure you are a registered delegate. Fields marked `,(0,r.jsx)(`span`,{className:`text-red-500 font-semibold`,children:`*`}),` are required.`]})]})]}),(0,r.jsx)(`div`,{part:`form-card`,className:`rounded-3xl border overflow-hidden divide-y ${f?`bg-zinc-900 border-zinc-800 divide-zinc-800`:`bg-white border-slate-200/80 divide-slate-100 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_-16px_rgba(15,23,42,0.12)]`}`,children:pe.map(e=>he(e))}),(0,r.jsxs)(`div`,{className:`pt-2 pb-10`,children:[(0,r.jsxs)(`button`,{part:`button button-primary submit-button`,type:`submit`,disabled:S!==null||w!==null,style:{background:`linear-gradient(135deg, ${M}, color-mix(in srgb, ${M} 80%, black))`,boxShadow:`0 12px 28px -12px color-mix(in srgb, ${M} 70%, transparent)`},className:`group w-full h-14 px-8 text-base font-semibold text-white rounded-2xl hover:brightness-110 active:scale-[0.99] transition-all cursor-pointer flex items-center justify-center gap-2.5 disabled:opacity-50 disabled:cursor-not-allowed`,children:[(0,r.jsx)(`span`,{children:y?`Submit Abstract`:`Complete Registration`}),(0,r.jsx)(ie,{size:18,className:`transition-transform group-hover:translate-x-0.5`})]}),(0,r.jsx)(`p`,{className:`mt-3 text-center text-xs ${f?`text-zinc-500`:`text-slate-400`}`,children:`Please review your details before submitting.`})]})]})})]})};function nt(e,t){if(!e)return``;if(/^field_\d+/i.test(e)&&t&&typeof t==`string`){let e=t.trim().toLowerCase().replace(/[^a-z0-9]+/g,`_`).replace(/^_+|_+$/g,``);if(e)return e}return e}function rt(e,t=``){if(e&&typeof e==`string`){let t=e.trim().toLowerCase().replace(/[^a-z0-9]+/g,`_`).replace(/^_+|_+$/g,``);if(t)return t}return nt(t,e)||t}var it=({apiClient:e,storage:t,logger:i,primaryColor:a,isDark:o=!1,isWidgetPage:s=!1,onEvent:c,onError:l})=>{let[u,d]=(0,n.useState)(()=>t.getToken()?`profile`:`login`),[f,p]=(0,n.useState)(!1),[m,h]=(0,n.useState)(!1),[g,_]=(0,n.useState)(null),[v,y]=(0,n.useState)(null),[b,x]=(0,n.useState)(null),[S,C]=(0,n.useState)(``),[w,ee]=(0,n.useState)(``),[te,T]=(0,n.useState)(``),[E,D]=(0,n.useState)(``),[re,O]=(0,n.useState)(``),[k,A]=(0,n.useState)(``),[ce,j]=(0,n.useState)(``),[de,N]=(0,n.useState)(!1),[P,F]=(0,n.useState)(null),[fe,I]=(0,n.useState)({}),[pe,L]=(0,n.useState)([]),[he,R]=(0,n.useState)({}),[z,B]=(0,n.useState)(null),[H,ye]=(0,n.useState)(null),[W,G]=(0,n.useState)(null),[K,q]=(0,n.useState)(!1),[Se,we]=(0,n.useState)(!1),[Y,De]=(0,n.useState)({}),[ke,X]=(0,n.useState)(!1),[je,Z]=(0,n.useState)(null),[Me,Ne]=(0,n.useState)({}),[Pe,Fe]=(0,n.useState)({});(0,n.useEffect)(()=>{let e=t.getToken();e&&Le(e)},[]);let Le=async n=>{p(!0),y(null);try{let r=await e.portalGetProfile(n),a=r?.data||r||{};F(a);let o=a.registration||{},s=o.custom_data||{},l=o.email||a.email||``,u=null;if(l)try{let t=await e.getDraftByEmail(l);u=t?.data||t,i.log(`Portal resume draft data loaded by email:`,u)}catch(e){i.log(`No draft found for email in portal`,e)}else{let n=t.getXrefId();if(n)try{let t=await e.getDraft(n);u=t?.data||t}catch{}}let f=u?.custom_data||{};o.name?T(o.name):u?.name?T(u.name):a.name&&T(a.name);let p=0,m={},h=[...a.editable_fields||[]];F({...a,editable_fields:h});let g={};o.asset_id&&(g.asset_id=String(o.asset_id)),o.photo_id&&(g.photo_id=String(o.photo_id)),s.asset_id&&(g.asset_id=String(s.asset_id)),s.photo_id&&(g.photo_id=String(s.photo_id)),a.asset_id&&(g.asset_id=String(a.asset_id)),h.forEach(e=>{if(e.type===`file`){let t=o[`${e.id}_asset_id`]||s[`${e.id}_asset_id`]||o.asset_id||s.asset_id||a.asset_id;t&&(g[e.id]=String(t))}}),R(e=>({...g,...e}));let _=o.asset_id||o.photo_id||s.asset_id||s.photo_id||a.asset_id;_&&B(String(_)),h.length>0?h.forEach(e=>{let t=e.label||e.name||e.id,n=nt(e.id,e.label),r=rt(e.label,e.id),i=``;if(t&&o[t]!==void 0&&o[t]!==null&&o[t]!==``?i=o[t]:o[r]!==void 0&&o[r]!==null&&o[r]!==``?i=o[r]:o[n]!==void 0&&o[n]!==null&&o[n]!==``?i=o[n]:o[e.id]!==void 0&&o[e.id]!==null&&o[e.id]!==``?i=o[e.id]:t&&s[t]!==void 0&&s[t]!==null&&s[t]!==``?i=s[t]:s[r]!==void 0&&s[r]!==null&&s[r]!==``?i=s[r]:s[n]!==void 0&&s[n]!==null&&s[n]!==``?i=s[n]:s[e.id]!==void 0&&s[e.id]!==null&&s[e.id]!==``&&(i=s[e.id]),u){let t=u[n]??u[e.id]??f[n]??f[e.id]??(e.id===`salutation`?u.salutation||u.title:void 0)??(e.id===`name`?u.name||u.fullName||u.full_name:void 0)??(e.id===`email`?u.email:void 0)??(e.id===`phone`?u.phone||u.mobile||u.phoneNumber:void 0);t!=null&&t!==``&&(i=t,p++)}m[e.id]=i}):Object.entries(a).forEach(([e,t])=>{e.toLowerCase()!==`token`&&(m[e]=t)}),I(m),p>0&&q(!0);let v=(a.addons?.items||[]).filter(e=>e.purchased).map(e=>e.name);u?.selected_items&&Array.isArray(u.selected_items)&&u.selected_items.forEach(e=>{let t=typeof e==`string`?e:e?.name;t&&!v.includes(t)&&v.push(t)}),L(v),d(`profile`),c?.(`attendee_profile_loaded`,{profile:a,draft:u})}catch(e){i.error(`Failed to load profile`,e),t.clearToken(),d(`login`)}finally{p(!1)}},ze=async n=>{if(n.preventDefault(),!S.trim()||!w){y(`Please enter both your identifier and password.`);return}p(!0),y(null),x(null);try{let n=await e.portalLogin({identifier:S.trim(),password:w}),r=n?.data?.token||n?.token;if(!r)throw Error(n?.message||`No authentication token received.`);(n?.data?.name||n?.name)&&T(n.data?.name||n.name),t.setToken(r),c?.(`attendee_logged_in`,{identifier:S,response:n}),await Le(r)}catch(e){i.error(`Login failed`,e);let t=e.message||`Login failed. Please check your credentials.`;y(t),l?.({type:`login_error`,message:t,error:e})}finally{p(!1)}},Ve=async t=>{t.preventDefault();let n=(E||S).trim();if(!n){y(`Please enter your registration number or email to receive a code.`);return}N(!0),y(null),x(null);try{await e.portalRequestPasswordReset(n),x(`A verification code has been sent to your registered email.`),c?.(`password_reset_code_requested`,{identifier:n}),d(`reset`)}catch(e){i.error(`Failed to send reset code`,e);let t=e.message||`Failed to send code. Please verify your identifier.`;y(t),l?.({type:`portal_error`,message:t,error:e})}finally{N(!1)}},He=async n=>{n.preventDefault();let r=(E||S).trim();if(!r){y(`Please enter your registration number or email.`);return}if(!re.trim()){y(`Please enter the verification code sent to your email.`);return}if(!k){y(`Please enter a new password.`);return}if(k!==ce){y(`New password and confirm password do not match.`);return}p(!0),y(null),x(null);try{let n=await e.portalConfirmPasswordReset({identifier:r,code:re.trim(),new_password:k}),i=n?.data?.token||n?.token;(n?.data?.name||n?.name)&&T(n.data?.name||n.name),c?.(`password_reset_success`,{identifier:r,response:n}),i?(t.setToken(i),O(``),A(``),j(``),await Le(i)):(C(r),ee(``),O(``),A(``),j(``),d(`login`),x(`Password updated successfully! Please login with your new password.`))}catch(e){i.error(`Password reset failed`,e);let t=e.message||`Failed to update password. Please check the code.`;y(t),l?.({type:`portal_error`,message:t,error:e})}finally{p(!1)}},Ue=()=>{t.clearToken(),F(null),I({}),L([]),R({}),B(null),G(null),T(``),ee(``),d(`login`),x(`Logged out successfully.`),c?.(`attendee_logged_out`,{})},Ge=async(n,r)=>{let a=t.getToken();if(!a){y(`Session expired. Please log in again.`);return}_(n),y(null),x(null);try{let t=await e.uploadFile(r,a),i=t?.data?.serve_url||t?.serve_url||``,o=t?.data?.asset_id||t?.asset_id;if(!o&&!i)throw Error(`Upload response missing asset_id`);i&&I(e=>({...e,[n]:i})),o&&(R(e=>({...e,[n]:String(o)})),B(String(o))),x(`File "${r.name}" uploaded successfully!`),c?.(`portal_file_uploaded`,{fieldId:n,serveUrl:i,assetId:o,response:t})}catch(e){i.error(`File upload failed`,e);let t=e.message||`File upload failed. Please try again.`;y(t),l?.({type:`file_upload_error`,message:t,error:e})}finally{_(null)}},qe=async n=>{let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}let a=fe[n],o=(a&&typeof a==`object`?a.id:null)||he[n]||z;ye(n),y(null),x(null);try{o&&(i.log(`Deleting asset ${o} for field ${n}...`),await e.portalDeleteFile(r,o),i.log(`Asset ${o} deleted successfully.`),c?.(`portal_file_deleted`,{assetId:o,fieldId:n})),I(e=>({...e,[n]:``})),R(e=>{let t={...e};return delete t[n],t}),z===o&&B(null),x(`File removed successfully.`)}catch(e){i.error(`Failed to delete file`,e);let t=e.message||`Failed to delete file. Please try again.`;y(t),l?.({type:`file_delete_error`,message:t,error:e})}finally{ye(null)}},Ye=(e,t)=>{t||L(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e])},Ze=async n=>{n.preventDefault();let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}h(!0),y(null),x(null);try{let t=P?.editable_fields||[],n={...P?.registration?.custom_data||{}},i={};t.forEach(e=>{let t=fe[e.id],r=e.label||e.name||e.id,a=rt(e.label,e.id),o=nt(e.id,e.label);e.type===`file`?(delete n[r],delete n[a],delete n[o],delete n[e.id]):e.builtin?(i[o]=t,o!==e.id&&(i[e.id]=t)):(n[o]=t,i[o]=t,o!==e.id&&(n[e.id]=t,i[e.id]=t))}),i.custom_data=n,i.addons=pe;let a=await e.portalUpdateProfile(r,i);c?.(`attendee_profile_updated`,{payload:i,response:a});let o=a?.data?.addon_checkout?.payment_url||a?.addon_checkout?.payment_url||a?.data?.payment_url||a?.payment_url;if(o&&typeof o==`string`&&o.trim()!==``){G(o),x(`Add-ons updated! Opening payment page in a new tab...`),c?.(`addon_payment_opened`,{payment_url:o}),window.open(o,`_blank`,`noopener,noreferrer`),await Le(r);return}x(`Profile updated successfully!`),await Le(r)}catch(e){i.error(`Failed to update profile`,e);let t=e.message||`Failed to update profile. Please try again.`;y(t),l?.({type:`profile_update_error`,message:t,error:e})}finally{h(!1)}},$e=()=>{let e=P?.review_submission;if(!e)return;let t=e.custom_data||{},n={},r={};(e.editable_fields||[]).forEach(i=>{i.id===`name`?n[i.id]=e.name||``:i.id===`phone`?n[i.id]=e.phone||``:i.id===`registration_type`?n[i.id]=e.registration_type||``:n[i.id]=t[i.id]??``,i.type===`file`&&(r[i.id]=i.current_file?.text||``)}),De(n),Fe(r),Ne({}),we(!0)},et=e=>{if(Me[e.id])return Me[e.id];let t=e.current_file;return t&&!t.serve_url&&t.text?`text`:`file`},tt=async(n,r)=>{let a=t.getToken();if(!a){y(`Session expired. Please log in again.`);return}let o=(P?.review_submission?.editable_fields||[]).find(e=>e.id===n),s=o?.current_file?.id;Z(n),y(null),x(null);try{if(s)try{await e.deleteFile(s,a)}catch(e){i.error(`Could not delete replaced submission file`,e)}let t=await e.uploadFile(r,a,null,o?.label),l=t?.data?.asset_id||t?.asset_id;if(!l)throw Error(`Upload response missing asset_id`);De(e=>({...e,[n]:String(l)})),x(`File "${r.name}" uploaded successfully!`),c?.(`portal_submission_file_uploaded`,{fieldId:n,assetId:l,response:t})}catch(e){i.error(`Submission file upload failed`,e);let t=e.message||`File upload failed. Please try again.`;y(t),l?.({type:`file_upload_error`,message:t,error:e})}finally{Z(null)}},it=async n=>{let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}let a=(Pe[n]||``).trim();if(a){Z(n),y(null),x(null);try{let t=await e.portalUpdateSubmission(r,{[n]:{text:a}}),i=t?.data||t;F(e=>({...e,review_submission:i}));let o=(i?.editable_fields||[]).find(e=>e.id===n)?.current_file?.id;o&&De(e=>({...e,[n]:String(o)})),x(`Text answer saved!`),c?.(`portal_submission_text_saved`,{fieldId:n})}catch(e){i.error(`Submission text answer failed`,e);let t=e.message||`Could not save your answer. Please try again.`;y(t),l?.({type:`submission_text_error`,message:t,error:e})}finally{Z(null)}}},at=async n=>{n.preventDefault();let r=t.getToken();if(!r){y(`Session expired. Please log in again.`);return}X(!0),y(null),x(null);try{let t=await e.portalUpdateSubmission(r,Y),n=t?.data||t;F(e=>({...e,review_submission:n})),we(!1),x(`Your submission was updated successfully!`),c?.(`attendee_submission_updated`,{payload:Y,response:t})}catch(e){i.error(`Failed to update submission`,e);let t=e.message||`Failed to update submission. Please try again.`;y(t),l?.({type:`submission_update_error`,message:t,error:e})}finally{X(!1)}},ot=()=>(0,r.jsxs)(`div`,{className:`absolute inset-0 pointer-events-none overflow-hidden z-0 select-none`,children:[(0,r.jsx)(`div`,{className:`absolute inset-0 pointer-events-none`,style:{background:o?`linear-gradient(180deg, rgba(9,9,11,0.5) 0%, rgba(9,9,11,0.7) 100%)`:`linear-gradient(180deg, rgba(255,255,255,0.08) 0%, rgba(248,250,252,0.2) 100%)`}}),(0,r.jsx)(`div`,{className:`absolute -top-16 -right-16 w-72 h-72 rounded-full blur-3xl pointer-events-none transition-all duration-700`,style:{background:`radial-gradient(circle, color-mix(in srgb, ${a} 16%, transparent) 0%, color-mix(in srgb, ${a} 3%, transparent) 60%, transparent 80%)`}}),(0,r.jsx)(`div`,{className:`absolute top-1/3 -left-20 w-80 h-80 rounded-full blur-3xl pointer-events-none transition-all duration-700`,style:{background:`radial-gradient(circle, color-mix(in srgb, ${a} 12%, transparent) 0%, color-mix(in srgb, ${a} 2%, transparent) 55%, transparent 75%)`}}),(0,r.jsx)(`div`,{className:`absolute -bottom-10 right-1/4 w-64 h-64 rounded-full blur-3xl pointer-events-none transition-all duration-700`,style:{background:`radial-gradient(circle, color-mix(in srgb, ${a} 9%, transparent) 0%, transparent 70%)`}}),!o&&(0,r.jsx)(`div`,{className:`absolute inset-0 opacity-[0.03]`,style:{backgroundImage:`radial-gradient(${a} 1px, transparent 1px)`,backgroundSize:`16px 16px`}})]}),st=e=>{let t=(e.label||e.id||``).toLowerCase(),n=e.type;return n===`email`||t.includes(`email`)||t.includes(`mail`)?(0,r.jsx)(Oe,{size:13,className:`shrink-0`,style:{color:a}}):n===`phone`||t.includes(`phone`)||t.includes(`mobile`)||t.includes(`contact`)?(0,r.jsx)(Re,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`salutation`)||t.includes(`title`)||t.includes(`prefix`)?(0,r.jsx)(We,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`name`)||t.includes(`attendee`)?(0,r.jsx)(Qe,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`designat`)||t.includes(`role`)||t.includes(`position`)||t.includes(`profession`)?(0,r.jsx)(ae,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`specialis`)||t.includes(`specializ`)||t.includes(`department`)||t.includes(`degree`)?(0,r.jsx)(U,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`organi`)||t.includes(`institute`)||t.includes(`hospital`)||t.includes(`company`)||t.includes(`college`)?(0,r.jsx)(oe,{size:13,className:`shrink-0`,style:{color:a}}):t.includes(`city`)||t.includes(`state`)||t.includes(`country`)||t.includes(`address`)?(0,r.jsx)(Ae,{size:13,className:`shrink-0`,style:{color:a}}):n===`file`?(0,r.jsx)(V,{size:13,className:`shrink-0`,style:{color:a}}):(0,r.jsx)(ve,{size:13,className:`shrink-0`,style:{color:a}})},ct=(e,t=`w-full`,n=[])=>{if(!e)return null;let i=n.includes(e.id)||n.includes(nt(e.id,e.label)),a=fe[e.id]??``,s=`vx-profile-${e.id}`,c=`w-full h-11 px-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${i?o?`bg-zinc-800/60 text-zinc-500 border-zinc-800 cursor-not-allowed`:`bg-slate-50 text-slate-500 border-slate-200 cursor-not-allowed`:o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500 hover:border-zinc-600 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_20%,transparent)]`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 hover:border-slate-300 shadow-[0_1px_2px_rgba(15,23,42,0.04)] focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`;return(0,r.jsxs)(`div`,{className:`${t} px-2 mb-4`,children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-2 mb-1.5`,children:[(0,r.jsxs)(`label`,{part:`field-label`,htmlFor:s,className:`flex items-center gap-1.5 text-[13px] font-semibold ${o?`text-zinc-200`:`text-slate-800`}`,children:[(0,r.jsx)(`span`,{className:o?`text-zinc-500`:`text-slate-400`,children:st(e)}),(0,r.jsx)(`span`,{children:e.label}),e.required&&(0,r.jsx)(`span`,{className:`text-red-500 font-semibold`,children:`*`})]}),i?(0,r.jsxs)(`span`,{className:`flex items-center gap-1 text-[10px] font-semibold px-2 py-0.5 rounded-full ${o?`text-zinc-400 bg-zinc-800`:`text-slate-500 bg-slate-100`}`,children:[(0,r.jsx)(Ce,{size:10}),` Locked`]}):null]}),e.type===`select`?(0,r.jsxs)(`div`,{className:`relative`,children:[(0,r.jsxs)(`select`,{part:`input select`,id:s,disabled:i,value:a,onChange:t=>I({...fe,[e.id]:t.target.value}),className:`${c} pr-9 appearance-none cursor-pointer flex items-center`,children:[(0,r.jsxs)(`option`,{value:``,className:o?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:[`Select `,e.label,`...`]}),(e.options||[]).map(e=>(0,r.jsx)(`option`,{value:e,className:o?`bg-zinc-900 text-white`:`bg-white text-slate-900`,children:e},e))]}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 right-0 flex items-center pr-3 pointer-events-none ${o?`text-zinc-400`:`text-slate-400`}`,children:(0,r.jsx)(le,{size:15})})]}):e.type===`file`?lt(e,i,a):(0,r.jsx)(`input`,{part:`input`,id:s,type:e.type===`phone`?`tel`:e.type===`email`?`email`:`text`,disabled:i,value:a,placeholder:e.placeholder||`Enter ${e.label.toLowerCase()}`,onChange:t=>I({...fe,[e.id]:t.target.value}),className:c})]},e.id)},lt=(e,t,n)=>{let i=g===e.id,s=e.label||e.name||e.id,c=typeof n==`string`?n:n?.serve_url||n?.url||``,l=typeof n==`string`?n:n?.file_name||c;return(0,r.jsx)(`div`,{className:`space-y-2`,children:(0,r.jsxs)(`div`,{part:`upload`,className:`p-4 rounded-2xl border border-dashed transition-all ${o?`bg-zinc-950/60 border-zinc-700 hover:border-zinc-600`:`bg-slate-50 border-slate-300 hover:border-[color-mix(in_srgb,var(--vx-accent)_45%,transparent)]`}`,children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-3 flex-wrap`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2.5`,children:[(0,r.jsx)(`div`,{className:`w-8 h-8 rounded-lg flex items-center justify-center shrink-0 border`,style:{backgroundColor:o?`rgba(255,255,255,0.06)`:`color-mix(in srgb, ${a} 8%, white)`,borderColor:o?`rgba(255,255,255,0.12)`:`color-mix(in srgb, ${a} 20%, white)`,color:a},children:(0,r.jsx)(V,{size:16})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`p`,{className:`text-xs font-bold ${o?`text-zinc-200`:`text-gray-900`}`,children:s}),(0,r.jsx)(`p`,{className:`text-2xs font-medium ${o?`text-zinc-400`:`text-gray-500`}`,children:n?`Document attached`:`Choose a file to upload`})]})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-2`,children:c.trim()!==``&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`a`,{href:c,target:`_blank`,rel:`noopener noreferrer`,className:`flex items-center gap-1.5 py-1.5 px-3 rounded-lg text-xs font-semibold text-white shadow-xs transition-opacity hover:opacity-90 shrink-0`,style:{backgroundColor:a},title:`Open file in new tab`,children:[(0,r.jsx)(ve,{size:13}),(0,r.jsx)(`span`,{children:`View`}),(0,r.jsx)(_e,{size:11})]}),!t&&(0,r.jsxs)(`button`,{type:`button`,disabled:H===e.id||i,onClick:()=>qe(e.id),className:`flex items-center gap-1 py-1.5 px-2.5 rounded-lg text-xs font-semibold border backdrop-blur-sm transition-colors cursor-pointer ${o?`border-red-900/60 bg-red-950/50 text-red-400 hover:bg-red-900/60`:`border-red-200 bg-red-50/80 text-red-600 hover:bg-red-100`}`,title:`Remove file`,children:[(0,r.jsx)(Je,{size:13}),(0,r.jsx)(`span`,{children:H===e.id?`Deleting...`:`Delete`})]})]})})]}),n&&(0,r.jsxs)(`div`,{className:`mt-2 pt-2 border-t text-2xs truncate flex items-center gap-1.5 ${o?`border-zinc-800 text-zinc-300`:`border-gray-200 text-gray-700 font-medium`}`,children:[(0,r.jsx)(se,{size:12,className:`text-emerald-500 shrink-0`}),(0,r.jsxs)(`span`,{className:`truncate`,children:[`Attached: `,l]})]}),!t&&(0,r.jsx)(`div`,{className:`mt-3 pt-3 border-t ${o?`border-zinc-800`:`border-slate-200`}`,children:(0,r.jsxs)(`label`,{className:`cursor-pointer relative`,children:[(0,r.jsx)(`input`,{type:`file`,className:`hidden`,style:{display:`none`},tabIndex:-1,disabled:i,onChange:t=>{let n=t.target.files?.[0];n&&Ge(e.id,n),t.target.value=``}}),(0,r.jsxs)(`div`,{className:`inline-flex items-center gap-1.5 py-1.5 px-3 rounded-lg text-xs font-semibold border transition-all shadow-2xs ${o?`border-zinc-700 hover:border-zinc-600 text-zinc-200 bg-zinc-800 hover:bg-zinc-750`:`border-gray-300 hover:border-gray-400 text-gray-800 bg-white hover:bg-gray-50`}`,children:[(0,r.jsx)(Xe,{size:13,style:{color:a}}),(0,r.jsx)(`span`,{children:i?`Uploading...`:n?`Replace File`:`Choose File`})]})]})})]})})};if(u===`profile`&&!P){let e=`vx-skeleton rounded-full`,t=`rounded-3xl border p-5 sm:p-6 ${o?`bg-zinc-900 border-zinc-800`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_-16px_rgba(15,23,42,0.12)]`}`;return(0,r.jsxs)(`div`,{role:`status`,"aria-live":`polite`,"aria-busy":`true`,className:`flex flex-col ${s?`w-full flex-1`:`h-full overflow-hidden min-h-0`} relative bg-transparent ${o?`text-white`:`text-slate-900`}`,children:[(0,r.jsx)(`span`,{className:`sr-only`,children:`Loading your profile…`}),ot(),(0,r.jsxs)(`div`,{className:`max-w-3xl mx-auto w-full px-4 sm:px-6 ${s?`py-8 sm:py-10`:`py-5`} space-y-5 relative z-10`,children:[(0,r.jsxs)(`div`,{className:t,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-4`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-12 h-12 sm:w-14 sm:h-14 rounded-2xl shrink-0`}),(0,r.jsxs)(`div`,{className:`flex-1 space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-5 w-48 max-w-full`}),(0,r.jsx)(`div`,{className:`${e} h-3 w-64 max-w-full`})]})]}),(0,r.jsx)(`div`,{className:`mt-5 pt-5 border-t grid grid-cols-2 sm:grid-cols-3 gap-4 ${o?`border-zinc-800`:`border-slate-100`}`,children:[0,1,2].map(t=>(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-2.5 w-20`}),(0,r.jsx)(`div`,{className:`${e} h-4 w-28`})]},t))})]}),(0,r.jsxs)(`div`,{className:t,children:[(0,r.jsx)(`div`,{className:`${e} h-4 w-32`}),(0,r.jsx)(`div`,{className:`mt-6 grid gap-4 md:grid-cols-2`,children:[0,1,2,3].map(t=>(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-3 w-24`}),(0,r.jsx)(`div`,{className:`vx-skeleton h-11 w-full rounded-xl`})]},t))})]})]})]})}if(u===`profile`){let e=P?.registration||{},t=P?.editable_fields||[],n=P?.locked_fields||[],i=Array.isArray(P?.payment)?P.payment:P?.payment?[P.payment]:[],c=i.filter(e=>e.state!==`not_required`),l=i[0],u=P?.addons?.items||[],d=P?.badge||null,f=P?.review_submission||null,p=te||`Attendee`,h=p.split(/\s+/).filter(Boolean).slice(0,2).map(e=>e[0]?.toUpperCase()).join(``)||`A`,_=`rounded-3xl border p-5 sm:p-6 ${o?`bg-zinc-900 border-zinc-800 text-white`:`bg-white border-slate-200/80 text-slate-900 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_-16px_rgba(15,23,42,0.12)]`}`,y=o?`text-zinc-400`:`text-slate-500`,x=`text-base font-semibold tracking-tight ${o?`text-white`:`text-slate-900`}`,S=[{label:`Registration no.`,value:e.registration_number||`N/A`,mono:!0},{label:`Ticket type`,value:e.registration_type||`N/A`},...l&&l.state!==`not_required`?[{label:`Payment`,value:`${l.state}${l.amount?` · ${[l.currency,l.amount].filter(Boolean).join(` `)}`:``}`,capitalize:!0}]:[]];return(0,r.jsxs)(`div`,{className:`flex flex-col ${s?`w-full flex-1`:`h-full overflow-hidden min-h-0`} relative bg-transparent ${o?`text-white`:`text-slate-900`}`,style:s?void 0:{overflow:`clip`},onScroll:s?void 0:e=>{e.currentTarget.scrollTop!==0&&(e.currentTarget.scrollTop=0),e.currentTarget.scrollLeft!==0&&(e.currentTarget.scrollLeft=0)},children:[ot(),(0,r.jsx)(`div`,{className:`${s?`w-full flex-1`:`flex-1 overflow-y-auto min-h-0 overscroll-contain`} relative z-10`,children:(0,r.jsxs)(`div`,{className:`max-w-3xl mx-auto w-full px-4 sm:px-6 ${s?`py-8 sm:py-10`:`py-5`} space-y-5`,children:[(0,r.jsxs)(`div`,{part:`portal-card profile-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 sm:gap-4 min-w-0`,children:[(0,r.jsx)(`div`,{className:`w-12 h-12 sm:w-14 sm:h-14 rounded-2xl flex items-center justify-center shrink-0 text-base sm:text-lg font-bold text-white`,style:{background:`linear-gradient(135deg, ${a}, color-mix(in srgb, ${a} 75%, black))`},"aria-hidden":`true`,children:h}),(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2 flex-wrap`,children:[(0,r.jsx)(`h3`,{part:`portal-title`,style:Q,className:`text-lg sm:text-xl font-bold tracking-tight break-words ${o?`text-white`:`text-slate-900`}`,children:p}),e.status&&(0,r.jsx)(`span`,{className:`px-2.5 py-0.5 rounded-full text-[11px] font-semibold capitalize ${o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`}`,children:e.status})]}),(0,r.jsx)(`p`,{className:`text-[13px] mt-0.5 ${y}`,children:`Manage your registration and details`})]})]}),(0,r.jsxs)(`button`,{part:`button button-secondary logout-button`,onClick:Ue,className:`shrink-0 inline-flex items-center justify-center gap-1.5 h-9 w-9 sm:w-auto sm:px-3.5 text-[13px] font-semibold rounded-full border transition-colors cursor-pointer ${o?`text-zinc-300 border-zinc-700 hover:bg-zinc-800 hover:text-red-300`:`text-slate-600 border-slate-200 bg-white hover:bg-red-50 hover:text-red-600 hover:border-red-200`}`,title:`Logout`,"aria-label":`Logout`,children:[(0,r.jsx)(Ee,{size:14}),(0,r.jsx)(`span`,{className:`hidden sm:inline`,children:`Logout`})]})]}),(0,r.jsx)(`dl`,{className:`mt-5 pt-5 border-t grid grid-cols-2 ${S.length===3?`sm:grid-cols-3`:`sm:grid-cols-2`} gap-4 ${o?`border-zinc-800`:`border-slate-100`}`,children:S.map(e=>(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsx)(`dt`,{className:`text-[11px] font-semibold uppercase tracking-wider ${o?`text-zinc-500`:`text-slate-400`}`,children:e.label}),(0,r.jsx)(`dd`,{className:`mt-1 text-sm font-semibold break-words ${e.mono?`font-mono`:``} ${e.capitalize?`capitalize`:``} ${o?`text-white`:`text-slate-900`}`,children:e.value})]},e.label))})]}),(0,r.jsxs)(`form`,{onSubmit:Ze,className:`space-y-5`,children:[t.length===0?(0,r.jsx)(`div`,{className:`${_} text-center text-sm ${y}`,children:`No editable fields configured.`}):(0,r.jsxs)(`div`,{part:`portal-card details-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-start justify-between gap-3 mb-5`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Your details`}),(0,r.jsx)(`p`,{className:`text-[13px] mt-0.5 ${y}`,children:`Keep your information up to date.`})]}),K&&(0,r.jsxs)(`span`,{className:`inline-flex items-center gap-1 text-[11px] font-semibold px-2.5 py-1 rounded-full shrink-0 ${o?`bg-emerald-950/60 text-emerald-300`:`bg-emerald-50 text-emerald-700`}`,children:[(0,r.jsx)(se,{size:11}),` Draft restored`]})]}),(0,r.jsx)(`div`,{className:`flex flex-wrap -mx-2 -mb-4`,children:t.map(e=>ct(e,e.type===`file`||e.width===`full`?`w-full`:`w-full md:w-1/2`,n))})]}),u.length>0&&(0,r.jsxs)(`div`,{part:`portal-card addons-card`,className:_,children:[(0,r.jsx)(`div`,{className:`flex items-start justify-between gap-3 mb-4`,children:(0,r.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(Ke,{size:17})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Add-ons`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:`Select items to add to your registration`})]})]})}),(0,r.jsx)(`div`,{className:`space-y-2`,children:u.map(e=>{let t=!!e.purchased,n=pe.includes(e.name);return(0,r.jsxs)(`label`,{className:`p-3.5 rounded-2xl border flex items-center gap-3 transition-all ${t?o?`bg-zinc-950/60 border-zinc-800 cursor-default`:`bg-slate-50 border-slate-200 cursor-default`:n?`cursor-pointer`:o?`border-zinc-800 bg-zinc-900 hover:border-zinc-700 cursor-pointer`:`border-slate-200 bg-white hover:border-slate-300 cursor-pointer`}`,style:n&&!t?{borderColor:a,backgroundColor:`color-mix(in srgb, ${a} ${o?16:6}%, transparent)`}:void 0,children:[(0,r.jsx)(`input`,{type:`checkbox`,checked:n,disabled:t,onChange:()=>Ye(e.name,t),className:`w-4 h-4 rounded cursor-pointer shrink-0 disabled:cursor-default`,style:{accentColor:a}}),(0,r.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`div`,{className:`text-sm font-semibold leading-snug ${o?`text-white`:`text-slate-900`}`,children:e.name}),(0,r.jsxs)(`div`,{className:`text-[13px] font-semibold mt-0.5 tabular-nums`,style:{color:a},children:[e.currency,` `,Number(e.price).toLocaleString()]})]}),t&&(0,r.jsxs)(`span`,{className:`px-2.5 py-1 rounded-full text-[11px] font-semibold flex items-center gap-1 shrink-0 ${o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`}`,children:[(0,r.jsx)(se,{size:12}),` Purchased`]})]},e.name)})})]}),(0,r.jsx)(`div`,{className:`pt-1 pb-6`,children:(0,r.jsx)(`button`,{part:`button button-primary submit-button`,type:`submit`,disabled:m||g!==null,style:{background:`linear-gradient(135deg, ${a}, color-mix(in srgb, ${a} 80%, black))`,boxShadow:`0 10px 24px -12px color-mix(in srgb, ${a} 70%, transparent)`},className:`w-full h-12 px-4 text-white text-sm font-semibold rounded-xl hover:brightness-110 active:scale-[0.99] transition-all flex items-center justify-center gap-2 cursor-pointer disabled:opacity-60 disabled:cursor-not-allowed`,children:m?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`svg`,{className:`animate-spin h-4 w-4 text-white`,fill:`none`,viewBox:`0 0 24 24`,"aria-hidden":`true`,children:[(0,r.jsx)(`circle`,{className:`opacity-25`,cx:`12`,cy:`12`,r:`10`,stroke:`currentColor`,strokeWidth:`4`}),(0,r.jsx)(`path`,{className:`opacity-75`,fill:`currentColor`,d:`M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z`})]}),(0,r.jsx)(`span`,{children:`Saving...`})]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(Ie,{size:16}),(0,r.jsx)(`span`,{children:`Save changes`})]})})})]}),d&&(0,r.jsxs)(`div`,{part:`portal-card badge-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 mb-4`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(be,{size:17})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Your badge`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:`View or download your event badge.`})]})]}),(0,r.jsx)(`div`,{className:`rounded-2xl border overflow-hidden ${o?`border-zinc-800 bg-zinc-950/60`:`border-slate-200 bg-slate-50`}`,children:(0,r.jsx)(`img`,{src:d,alt:`Your event badge`,className:`w-full max-h-96 object-contain`})}),(0,r.jsxs)(`div`,{className:`mt-4 flex flex-wrap gap-2.5`,children:[(0,r.jsxs)(`a`,{href:d,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold border transition-colors ${o?`text-zinc-200 border-zinc-700 hover:bg-zinc-800`:`text-slate-700 border-slate-200 bg-white hover:bg-slate-50`}`,children:[(0,r.jsx)(_e,{size:13}),(0,r.jsx)(`span`,{children:`View badge`})]}),(0,r.jsxs)(`a`,{href:d,download:!0,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white`,style:{backgroundColor:a},children:[(0,r.jsx)(ge,{size:13}),(0,r.jsx)(`span`,{children:`Download badge`})]})]})]}),c.length>0&&(0,r.jsxs)(`div`,{part:`portal-card payments-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 mb-4`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(Be,{size:17})}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Payments`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:`Every order on your registration, with receipts.`})]})]}),(0,r.jsx)(`div`,{className:`space-y-2`,children:c.map((e,t)=>{let n=e.state===`paid`;return(0,r.jsxs)(`div`,{className:`p-3.5 rounded-2xl border flex items-center gap-3 ${o?`border-zinc-800 bg-zinc-950/60`:`border-slate-200 bg-slate-50`}`,children:[(0,r.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`div`,{className:`text-sm font-semibold leading-snug truncate ${o?`text-white`:`text-slate-900`}`,children:e.order_number||`Registration fee`}),e.amount&&(0,r.jsx)(`div`,{className:`text-[13px] font-semibold mt-0.5 tabular-nums`,style:{color:a},children:[e.currency,Number(e.amount).toLocaleString()].filter(Boolean).join(` `)})]}),(0,r.jsx)(`span`,{className:`px-2.5 py-1 rounded-full text-[11px] font-semibold capitalize shrink-0 ${n?o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`:o?`bg-amber-950/60 text-amber-300`:`bg-amber-50 text-amber-700`}`,children:e.state}),e.receipt_url&&(0,r.jsxs)(`a`,{href:e.receipt_url,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1 text-[12.5px] font-semibold hover:underline underline-offset-4 shrink-0`,style:{color:a},children:[(0,r.jsx)(`span`,{children:`Receipt`}),(0,r.jsx)(_e,{size:11})]})]},e.order_number||t)})})]}),f&&(0,r.jsxs)(`div`,{part:`portal-card submission-card`,className:_,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3 mb-4`,children:[(0,r.jsx)(`div`,{className:`w-9 h-9 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(ve,{size:17})}),(0,r.jsxs)(`div`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`h4`,{className:x,style:Q,children:`Your submission`}),(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:f.registration_type_label||`Abstract submission`})]}),(0,r.jsx)(`span`,{className:`px-2.5 py-1 rounded-full text-[11px] font-semibold capitalize shrink-0 ${f.verdict===`accepted`?o?`bg-emerald-950/70 text-emerald-300`:`bg-emerald-50 text-emerald-700`:f.verdict===`rejected`?o?`bg-red-950/60 text-red-300`:`bg-red-50 text-red-700`:o?`bg-amber-950/60 text-amber-300`:`bg-amber-50 text-amber-700`}`,children:f.verdict})]}),(0,r.jsxs)(`dl`,{className:`grid grid-cols-2 gap-4`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`dt`,{className:`text-[11px] font-semibold uppercase tracking-wider ${o?`text-zinc-500`:`text-slate-400`}`,children:`Submission no.`}),(0,r.jsx)(`dd`,{className:`mt-1 text-sm font-semibold font-mono ${o?`text-white`:`text-slate-900`}`,children:f.submission_number||`N/A`})]}),(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`dt`,{className:`text-[11px] font-semibold uppercase tracking-wider ${o?`text-zinc-500`:`text-slate-400`}`,children:`Status`}),(0,r.jsx)(`dd`,{className:`mt-1 text-sm font-semibold capitalize ${o?`text-white`:`text-slate-900`}`,children:f.status})]})]}),Se?(0,r.jsxs)(`form`,{onSubmit:at,className:`mt-4 pt-4 border-t space-y-3.5 ${o?`border-zinc-800`:`border-slate-100`}`,children:[(f.editable_fields||[]).map(e=>(0,r.jsxs)(`div`,{children:[(0,r.jsxs)(`label`,{className:`block text-[13px] font-semibold mb-1.5 ${o?`text-zinc-200`:`text-slate-800`}`,children:[e.label,e.required&&(0,r.jsx)(`span`,{className:`text-red-500`,children:` *`})]}),e.type===`file`?(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`button`,{type:`button`,disabled:je===e.id,onClick:()=>Ne(t=>({...t,[e.id]:et(e)===`file`?`text`:`file`})),className:`mb-1.5 text-[12px] font-semibold underline disabled:opacity-50 ${o?`text-zinc-400`:`text-slate-500`}`,children:et(e)===`file`?`Send text instead`:`Send file instead`}),et(e)===`file`?(0,r.jsxs)(`div`,{children:[e.current_file?.serve_url&&(0,r.jsx)(`a`,{href:e.current_file.serve_url,target:`_blank`,rel:`noopener noreferrer`,className:`block mb-2 text-[12.5px] font-medium underline ${o?`text-zinc-300`:`text-slate-600`}`,children:`View current file`}),(0,r.jsx)(`input`,{type:`file`,disabled:je===e.id,onChange:t=>{let n=t.target.files?.[0];n&&tt(e.id,n)},className:`w-full text-[13px] ${y}`}),je===e.id&&(0,r.jsx)(`p`,{className:`mt-1 text-[12.5px] ${y}`,children:`Uploading…`})]}):(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`textarea`,{rows:4,disabled:je===e.id,value:Pe[e.id]??``,placeholder:`Enter your answer...`,onChange:t=>Fe({...Pe,[e.id]:t.target.value}),className:`w-full px-3.5 py-2.5 text-sm font-medium rounded-xl border transition-all focus:outline-none resize-y ${o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400`}`}),(0,r.jsx)(`button`,{type:`button`,disabled:je===e.id||!(Pe[e.id]||``).trim(),onClick:()=>it(e.id),className:`mt-1.5 inline-flex items-center h-8 px-3.5 rounded-full text-[12.5px] font-semibold text-white disabled:opacity-50 cursor-pointer`,style:{backgroundColor:a},children:je===e.id?`Saving…`:`Save text answer`})]})]}):e.id===`registration_type`?(0,r.jsxs)(`select`,{value:Y[e.id]??``,onChange:t=>De({...Y,[e.id]:t.target.value}),className:`w-full h-11 px-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${o?`bg-zinc-950 border-zinc-700 text-white`:`bg-white border-slate-200 text-slate-900`}`,children:[(0,r.jsxs)(`option`,{value:``,children:[`Select `,e.label,`...`]}),(f.registration_types||[]).map(e=>(0,r.jsx)(`option`,{value:e.id,children:e.label},e.id))]}):e.type===`select`?(0,r.jsxs)(`select`,{value:Y[e.id]??``,onChange:t=>De({...Y,[e.id]:t.target.value}),className:`w-full h-11 px-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${o?`bg-zinc-950 border-zinc-700 text-white`:`bg-white border-slate-200 text-slate-900`}`,children:[(0,r.jsxs)(`option`,{value:``,children:[`Select `,e.label,`...`]}),(e.options||[]).map(e=>(0,r.jsx)(`option`,{value:e,children:e},e))]}):(0,r.jsx)(`textarea`,{rows:e.id===`name`||e.id===`phone`?1:4,value:Y[e.id]??``,placeholder:e.placeholder||`Enter ${e.label.toLowerCase()}`,onChange:t=>De({...Y,[e.id]:t.target.value}),className:`w-full px-3.5 py-2.5 text-sm font-medium rounded-xl border transition-all focus:outline-none resize-y ${o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400`}`})]},e.id)),(0,r.jsxs)(`div`,{className:`flex items-center gap-2.5 pt-1`,children:[(0,r.jsx)(`button`,{type:`submit`,disabled:ke,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white shrink-0 cursor-pointer disabled:opacity-60`,style:{backgroundColor:a},children:ke?`Saving...`:`Save changes`}),(0,r.jsx)(`button`,{type:`button`,disabled:ke,onClick:()=>we(!1),className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold border transition-colors cursor-pointer ${o?`text-zinc-300 border-zinc-700 hover:bg-zinc-800`:`text-slate-600 border-slate-200 bg-white hover:bg-slate-50`}`,children:`Cancel`})]})]}):(0,r.jsxs)(`div`,{className:`mt-4 pt-4 border-t flex items-center justify-between gap-3 flex-wrap ${o?`border-zinc-800`:`border-slate-100`}`,children:[(0,r.jsx)(`p`,{className:`text-[13px] ${y}`,children:f.editable?`You can still edit your answers until a reviewer picks this up.`:`This submission has been assigned to a reviewer and can no longer be edited.`}),f.editable&&(0,r.jsx)(`button`,{type:`button`,onClick:$e,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white shrink-0 cursor-pointer`,style:{backgroundColor:a},children:`Edit submission`})]})]}),W&&(0,r.jsxs)(`div`,{className:`p-4 rounded-2xl flex flex-wrap items-center justify-between gap-3 text-sm`,style:{backgroundColor:`color-mix(in srgb, ${a} ${o?14:7}%, transparent)`,boxShadow:`inset 0 0 0 1px color-mix(in srgb, ${a} 22%, transparent)`},children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2.5 ${o?`text-zinc-200`:`text-slate-700`}`,children:[(0,r.jsx)(me,{size:17,className:`shrink-0`,style:{color:a}}),(0,r.jsx)(`span`,{children:`Payment page opened in a new tab. If it didn't open:`})]}),(0,r.jsxs)(`a`,{href:W,target:`_blank`,rel:`noopener noreferrer`,className:`inline-flex items-center gap-1.5 h-9 px-4 rounded-full text-[13px] font-semibold text-white shrink-0`,style:{backgroundColor:a},children:[(0,r.jsx)(`span`,{children:`Complete payment`}),(0,r.jsx)(_e,{size:12})]})]}),v&&(0,r.jsxs)(`div`,{role:`alert`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-red-950/50 text-red-300 ring-1 ring-inset ring-red-900`:`bg-red-50 text-red-700 ring-1 ring-inset ring-red-200/80`}`,children:[(0,r.jsx)(ue,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:v})]}),b&&(0,r.jsxs)(`div`,{role:`status`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-emerald-950/50 text-emerald-300 ring-1 ring-inset ring-emerald-900`:`bg-emerald-50 text-emerald-700 ring-1 ring-inset ring-emerald-200/80`}`,children:[(0,r.jsx)(M,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:b})]})]})})]})}let ut=`w-full h-11 pl-10 pr-3.5 text-sm font-medium rounded-xl border transition-all focus:outline-none ${o?`bg-zinc-950 border-zinc-700 text-white placeholder:text-zinc-500 hover:border-zinc-600 focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_20%,transparent)]`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 hover:border-slate-300 shadow-[0_1px_2px_rgba(15,23,42,0.04)] focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)]`}`,dt=(0,r.jsxs)(`svg`,{className:`animate-spin h-4 w-4 text-white`,fill:`none`,viewBox:`0 0 24 24`,"aria-hidden":`true`,children:[(0,r.jsx)(`circle`,{className:`opacity-25`,cx:`12`,cy:`12`,r:`10`,stroke:`currentColor`,strokeWidth:`4`}),(0,r.jsx)(`path`,{className:`opacity-75`,fill:`currentColor`,d:`M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z`})]}),ft=e=>{d(e),y(null),x(null)},$=({id:e,label:t,icon:n,type:i=`text`,value:a,onChange:s,placeholder:c,autoComplete:l,aside:u})=>(0,r.jsxs)(`div`,{children:[(0,r.jsxs)(`div`,{className:`flex items-center justify-between gap-2 mb-1.5`,children:[(0,r.jsx)(`label`,{part:`field-label`,htmlFor:e,className:`block text-[13px] font-semibold ${o?`text-zinc-200`:`text-slate-800`}`,children:t}),u]}),(0,r.jsxs)(`div`,{className:`relative`,children:[(0,r.jsx)(`div`,{className:`absolute inset-y-0 left-0 pl-3.5 flex items-center pointer-events-none ${o?`text-zinc-500`:`text-slate-400`}`,children:(0,r.jsx)(n,{size:16})}),(0,r.jsx)(`input`,{part:`input`,id:e,type:i,required:!0,value:a,autoComplete:l,onChange:e=>s(e.target.value),placeholder:c,className:ut})]})]}),pt=()=>(0,r.jsxs)(r.Fragment,{children:[v&&(0,r.jsxs)(`div`,{role:`alert`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-red-950/50 text-red-300 ring-1 ring-inset ring-red-900`:`bg-red-50 text-red-700 ring-1 ring-inset ring-red-200/80`}`,children:[(0,r.jsx)(ue,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:v})]}),b&&(0,r.jsxs)(`div`,{role:`status`,className:`p-3.5 rounded-xl flex items-start gap-2.5 text-sm ${o?`bg-emerald-950/50 text-emerald-300 ring-1 ring-inset ring-emerald-900`:`bg-emerald-50 text-emerald-700 ring-1 ring-inset ring-emerald-200/80`}`,children:[(0,r.jsx)(M,{size:17,className:`shrink-0 mt-0.5`}),(0,r.jsx)(`span`,{children:b})]})]}),mt=(e,t,n)=>(0,r.jsx)(`button`,{part:`button button-primary submit-button`,type:`submit`,disabled:e,style:{background:`linear-gradient(135deg, ${a}, color-mix(in srgb, ${a} 80%, black))`,boxShadow:`0 10px 24px -12px color-mix(in srgb, ${a} 70%, transparent)`},className:`group w-full h-11 px-4 text-white text-sm font-semibold rounded-xl hover:brightness-110 active:scale-[0.99] transition-all flex items-center justify-center gap-2 cursor-pointer disabled:opacity-60 disabled:cursor-not-allowed`,children:e?(0,r.jsxs)(r.Fragment,{children:[dt,(0,r.jsx)(`span`,{children:n})]}):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`span`,{children:t}),(0,r.jsx)(ie,{size:16,className:`transition-transform group-hover:translate-x-0.5`})]})}),ht=({icon:e,title:t,subtitle:n,onBack:i,children:c})=>(0,r.jsxs)(`div`,{className:`flex flex-col ${s?`w-full flex-1`:`h-full overflow-y-auto`} relative bg-transparent ${o?`text-white`:`text-slate-900`}`,children:[ot(),(0,r.jsxs)(`div`,{className:`px-4 sm:px-6 ${s?`py-8 sm:py-10`:`py-5`} flex-1 max-w-[400px] mx-auto w-full flex flex-col justify-center relative z-10`,children:[i&&(0,r.jsxs)(`button`,{part:`button button-link back-button`,type:`button`,onClick:i,className:`self-start inline-flex items-center gap-1.5 mb-4 text-sm font-semibold transition-colors cursor-pointer ${o?`text-zinc-400 hover:text-white`:`text-slate-500 hover:text-slate-900`}`,children:[(0,r.jsx)(ne,{size:16}),(0,r.jsx)(`span`,{children:`Back to login`})]}),(0,r.jsxs)(`div`,{part:`portal-card`,className:`p-6 sm:p-7 rounded-3xl border space-y-5 ${o?`bg-zinc-900 border-zinc-800 shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_24px_48px_-24px_rgba(15,23,42,0.18)]`}`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`div`,{className:`w-10 h-10 rounded-xl flex items-center justify-center mb-4`,style:{backgroundColor:`color-mix(in srgb, ${a} 12%, transparent)`,color:a},children:(0,r.jsx)(e,{size:19})}),(0,r.jsx)(`h3`,{part:`portal-title`,style:Q,className:`text-xl font-bold tracking-tight ${o?`text-white`:`text-slate-900`}`,children:t}),(0,r.jsx)(`p`,{className:`text-[13px] mt-1 leading-relaxed ${o?`text-zinc-400`:`text-slate-500`}`,children:n})]}),pt(),c]})]})]}),gt=`font-semibold hover:underline underline-offset-4 cursor-pointer`;return ht(u===`request_code`?{icon:Oe,title:`Get verification code`,subtitle:`We will email a verification code to your registered address.`,onBack:()=>ft(`login`),children:(0,r.jsxs)(`form`,{onSubmit:Ve,className:`space-y-4`,children:[$({id:`vx-portal-code-identifier`,label:`Registration number or email`,icon:Oe,value:E||S,onChange:e=>{D(e),C(e)},placeholder:`e.g. attendee@example.com or REG12345`,autoComplete:`username`}),mt(de,`Send verification code`,`Sending code...`),(0,r.jsxs)(`p`,{className:`text-center text-[13px] ${o?`text-zinc-400`:`text-slate-500`}`,children:[`Already have a code?`,` `,(0,r.jsx)(`button`,{type:`button`,onClick:()=>ft(`reset`),className:gt,style:{color:a},children:`Set your password`})]})]})}:u===`reset`?{icon:xe,title:`Set your password`,subtitle:`Enter the code from your email and choose a new password.`,onBack:()=>ft(`login`),children:(0,r.jsxs)(`form`,{onSubmit:He,className:`space-y-4`,children:[$({id:`vx-portal-reset-identifier`,label:`Registration number or email`,icon:Oe,value:E||S,onChange:e=>{D(e),C(e)},placeholder:`e.g. attendee@example.com or REG12345`,autoComplete:`username`}),$({id:`vx-portal-reset-code`,label:`Verification code`,icon:J,value:re,onChange:O,placeholder:`Enter code from email`,autoComplete:`one-time-code`,aside:(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(E||S),ft(`request_code`)},className:`text-xs font-semibold hover:underline underline-offset-4 cursor-pointer`,style:{color:a},children:`Get code on email`})}),$({id:`vx-portal-reset-password`,label:`New password`,icon:Ce,type:`password`,value:k,onChange:A,placeholder:`Enter new password`,autoComplete:`new-password`}),$({id:`vx-portal-reset-confirm`,label:`Confirm password`,icon:Ce,type:`password`,value:ce,onChange:j,placeholder:`Re-enter new password`,autoComplete:`new-password`}),mt(f,`Set new password`,`Updating password...`)]})}:{icon:Te,title:`Attendee login`,subtitle:`Sign in with your email or registration number.`,children:(0,r.jsxs)(`form`,{onSubmit:ze,className:`space-y-4`,children:[$({id:`vx-portal-login-identifier`,label:`Email or registration number`,icon:Oe,value:S,onChange:C,placeholder:`Enter email or registration number`,autoComplete:`username`}),$({id:`vx-portal-login-password`,label:`Password`,icon:Ce,type:`password`,value:w,onChange:ee,placeholder:`Enter password`,autoComplete:`current-password`,aside:(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(S),ft(`reset`)},className:`text-xs font-semibold hover:underline underline-offset-4 cursor-pointer`,style:{color:a},children:`Forgot password?`})}),mt(f,`Login`,`Logging in...`),(0,r.jsxs)(`p`,{className:`pt-4 border-t text-center text-[13px] ${o?`border-zinc-800 text-zinc-400`:`border-slate-100 text-slate-500`}`,children:[`First time here?`,` `,(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(S),ft(`request_code`)},className:gt,style:{color:a},children:`Get code`}),` `,`or`,` `,(0,r.jsx)(`button`,{type:`button`,onClick:()=>{D(S),ft(`reset`)},className:gt,style:{color:a},children:`generate password`})]})]})})};function at(e,t,n){if(!e)return;let r=t?`rgba(9,9,11,0.88)`:`rgba(248,250,252,0.88)`;return{backgroundImage:`linear-gradient(${r}, ${r}), url(${e})`,backgroundSize:`cover`,backgroundPosition:`center`,backgroundRepeat:`no-repeat`,backgroundAttachment:n?`fixed`:`scroll`}}function ot(e){if(!e)return`bottom-right`;switch(e){case`bottom-left`:case`left-bottom`:return`bottom-left`;case`top-right`:case`right-top`:return`top-right`;case`top-left`:case`left-top`:return`top-left`;default:return`bottom-right`}}var st=e=>{switch(e){case`bottom-left`:return{bottom:`20px`,left:`20px`,top:`auto`,right:`auto`};case`top-right`:return{top:`20px`,right:`20px`,bottom:`auto`,left:`auto`};case`top-left`:return{top:`20px`,left:`20px`,bottom:`auto`,right:`auto`};default:return{bottom:`20px`,right:`20px`,top:`auto`,left:`auto`}}},ct=e=>{switch(e){case`bottom-left`:return`bottom-5 left-5`;case`top-right`:return`top-5 right-5`;case`top-left`:return`top-5 left-5`;default:return`bottom-5 right-5`}},lt=({config:e})=>{let[t,i]=(0,n.useState)(`registration`),[a,o]=(0,n.useState)(!1);(0,n.useEffect)(()=>{t===`attendee`&&o(!0)},[t]);let[s]=(0,n.useState)(()=>typeof window<`u`?new URLSearchParams(window.location.search).get(`rn`):null),[c,l]=(0,n.useState)(e.displayMode!==`popup`||!!s),[u,d]=(0,n.useState)(!1),[h,g]=(0,n.useState)([]),[_,v]=(0,n.useState)(``),[y,b]=(0,n.useState)(null),[x,S]=(0,n.useState)(null),C=(0,n.useMemo)(()=>x&&{fields:x.fields.filter(e=>e.id!==`registration_type`)},[x]),[w,ee]=(0,n.useState)(!0),[te,T]=(0,n.useState)(``),[E,D]=(0,n.useState)(null),[ne,re]=(0,n.useState)(!!s),[O,ae]=(0,n.useState)(null),[k,oe]=(0,n.useState)(null),[A,ce]=(0,n.useState)(s),[le,j]=(0,n.useState)(!1),[ue,de]=(0,n.useState)(()=>ot(e.position)),[M,N]=(0,n.useState)(null),[F,I]=(0,n.useState)(null),[L,me]=(0,n.useState)(!1),[he,ge]=(0,n.useState)(!1),R=(0,n.useRef)(null),z=(0,n.useRef)(null),B=(0,n.useRef)(!1);(0,n.useEffect)(()=>{e.position&&de(ot(e.position))},[e.position]);let V=e.themeMode===`dark`||e.theme?.mode===`dark`,H=e.theme?.primaryColor||`#2563eb`,U=!!e.isAbstract,ye=e.headerBannerImage,be=e.backgroundImage,W=(0,n.useMemo)(()=>new f(e.debug),[e.debug]),G=(0,n.useMemo)(()=>new p(e.baseUrl,e.eventSlug,W,e.timeoutMs??12e4),[e.baseUrl,e.eventSlug,W,e.timeoutMs]),K=(0,n.useMemo)(()=>new m(e.eventSlug),[e.eventSlug]),xe=(0,n.useRef)(e.displayMode),q=(0,n.useRef)(null),[J,Se]=(0,n.useState)(null);(0,n.useEffect)(()=>{K.getXrefId()},[K]),(0,n.useEffect)(()=>{if(!c)return;let t=K.getXrefId();t&&(U?G.getReviewDraft(t):G.getDraft(t)).then(t=>{let n=t?.data||t;n&&n.registration_type&&(Se(n),e.onEvent?.(`draft_loaded`,n))}).catch(e=>{W.log(`No draft found for this session`,e)})},[c,G,K,W,U]);let Ce=(0,n.useMemo)(()=>{if(!J||!y||String(J.registration_type)!==String(y.id))return{};let e={...J.custom_data||{}};if(J.salutation&&(e.salutation=J.salutation,e.title=J.salutation),J.name){e.name=J.name,e.full_name=J.name,e.fullName=J.name;let t=J.name.trim().split(/\s+/);t.length>0&&!e.first_name&&(e.first_name=t[0]),t.length>1&&!e.last_name&&(e.last_name=t.slice(1).join(` `))}return J.email&&(e.email=J.email),J.phone&&(e.phone=J.phone,e.mobile=J.phone,e.phoneNumber=J.phone),((U?x?.fields:y?.form_schema?.fields)||[]).forEach(t=>{let n=nt(t.id,t.label);e[t.id]===void 0&&e[n]!==void 0&&(e[t.id]=e[n])}),e},[J,y,U,x]);(0,n.useEffect)(()=>()=>{q.current&&clearTimeout(q.current)},[]);let we=(0,n.useCallback)(t=>{q.current&&clearTimeout(q.current),q.current=setTimeout(async()=>{if(!Object.values(t).some(e=>e!==``&&e!=null))return;let n=new Set([`salutation`,`title`,`name`,`fullName`,`full_name`,`firstName`,`lastName`,`email`,`phone`,`mobile`,`phoneNumber`,`selected_items`,`custom_data`]),r=(U?x?.fields:y?.form_schema?.fields)||[],i=new Map;r.forEach(e=>i.set(e.id,e));let a={...t.custom_data||{}};for(let[e,r]of Object.entries(t))if(!n.has(e)){let t=nt(e,i.get(e)?.label);a[t]=r}let o={xref_id:K.getXrefId(),salutation:t.salutation||t.title||``,name:t.name||t.fullName||t.full_name||[t.firstName,t.lastName].filter(Boolean).join(` `)||``,email:t.email||``,phone:t.phone||t.mobile||t.phoneNumber||``,registration_type:y?.id,custom_data:a,selected_items:t.selected_items||[]};try{U?await G.trackReviewProgress(o):await G.trackProgress(o),e.onEvent?.(`draft_saved`,o)}catch(e){W.error(`Failed to save draft progress`,e)}},600)},[K,G,y,e,W,U,x]);(0,n.useEffect)(()=>{xe.current!==e.displayMode&&(xe.current=e.displayMode,l(e.displayMode!==`popup`),d(!1))},[e.displayMode]),(0,n.useEffect)(()=>{(U?G.getReviewFormSchema():G.getFormSchema()).then(t=>{g(t?.data?.types||[]),U&&S({fields:t?.data?.fields||[]}),(t?.data?.event_name||t?.data?.title||t?.data?.name)&&v(t.data.event_name||t.data.title||t.data.name),e.onEvent?.(`form_loaded`,t?.data)}).catch(t=>{W.error(`Failed to load schema`,t),g([]);let n={type:`schema_load`,message:t?.message||`Failed to load event schema`,error:t};e.onEvent?.(`error`,n),e.onError?.(n)}).finally(()=>ee(!1))},[G,U]);let Y=async t=>{q.current&&clearTimeout(q.current),ee(!0),ae(null);let n=K.getXrefId(),r=new Set([`salutation`,`title`,`name`,`fullName`,`full_name`,`firstName`,`lastName`,`email`,`phone`,`mobile`,`phoneNumber`,`registration_type`,`selected_items`,`custom_data`,`xref_id`]),i=(U?x?.fields:y?.form_schema?.fields)||[],a=new Map;i.forEach(e=>a.set(e.id,e));let o={...t.custom_data||{}};for(let[e,n]of Object.entries(t))if(!r.has(e)){let t=nt(e,a.get(e)?.label);o[t]=n}let s={xref_id:n,salutation:t.salutation||t.title||``,name:t.name||t.fullName||t.full_name||[t.firstName,t.lastName].filter(Boolean).join(` `)||``,email:t.email||``,phone:t.phone||t.mobile||t.phoneNumber||``,registration_type:y.id,custom_data:o,selected_items:t.selected_items||[]};try{let t=U?await G.submitReview(s):await G.submitRegistration(s);K.updateXrefId(),Se(null);let n=U?null:t?.data?.payment_url||t?.payment_url||null;oe(n);let r=t?.data?.submission_number||t?.submission_number||t?.data?.registration_number||t?.registration_number||t?.data?.registration?.registration_number||t?.registration?.registration_number||null;ce(r?String(r):null),j(!1),n&&typeof n==`string`&&n.trim()!==``&&window.open(n,`_blank`,`noopener,noreferrer`),re(!0);let i={registrationType:y.id,payload:s,response:t,paymentUrl:n};e.onEvent?.(`submitted`,i),e.onRegister?.(i),e.onRegistered?.(i)}catch(t){W.error(`Submission failed`,t);let n=t?.message||(U?`Submission failed. Please check your information and try again.`:`Registration failed. Please check your information and try again.`),r={type:`submit_error`,message:n,error:t};e.onEvent?.(`error`,r),e.onError?.(r),ae(n)}finally{ee(!1)}},Ee=()=>{if(re(!1),ae(null),oe(null),ce(null),j(!1),b(null),Se(null),typeof window<`u`&&new URLSearchParams(window.location.search).has(`rn`)){let e=new URL(window.location.href);e.searchParams.delete(`rn`),window.history.replaceState(window.history.state,``,e.toString())}},De=(0,n.useCallback)(e=>{if(e.stopPropagation(),e.button!==0||!R.current)return;let t=R.current.getBoundingClientRect();z.current={startX:e.clientX,startY:e.clientY,rect:t,corner:ue},B.current=!1,me(!0)},[ue]);(0,n.useEffect)(()=>{if(!L)return;let t=e=>{if(!z.current)return;let t=e.clientX-z.current.startX,n=e.clientY-z.current.startY;B.current||Math.hypot(t,n)>5&&(B.current=!0),B.current&&N({x:t,y:n})},n=t=>{if(!z.current){me(!1),N(null),B.current=!1;return}let{rect:n,startX:r,startY:i}=z.current,a=t.clientX-r,o=t.clientY-i,s=B.current;if(z.current=null,me(!1),setTimeout(()=>{B.current=!1},100),!s){N(null);return}let c=n.left+a,l=n.top+o,u=c+n.width/2,d=l+n.height/2,f=typeof window<`u`?window.innerWidth:1024,p=typeof window<`u`?window.innerHeight:768,m=u>=f/2,h=d>=p/2,g=h?m?`bottom-right`:`bottom-left`:m?`top-right`:`top-left`,_=m?f-n.width-20:20,v=h?p-n.height-20:20,y=c-_,b=l-v;I({transform:`translate3d(${y}px, ${b}px, 0)`,transition:`none`}),N(null),de(g),e.onEvent?.(`position_changed`,{position:g}),requestAnimationFrame(()=>{requestAnimationFrame(()=>{I({transform:`translate3d(0, 0, 0)`,transition:`transform 0.35s cubic-bezier(0.16, 1, 0.3, 1)`}),setTimeout(()=>{I(null)},360)})})};return window.addEventListener(`pointermove`,t),window.addEventListener(`pointerup`,n),window.addEventListener(`pointercancel`,n),()=>{window.removeEventListener(`pointermove`,t),window.removeEventListener(`pointerup`,n),window.removeEventListener(`pointercancel`,n)}},[L,e]);let Oe=async()=>{if(A){try{await navigator.clipboard.writeText(A)}catch{let e=document.createElement(`textarea`);e.value=A,document.body.appendChild(e),e.select(),document.execCommand(`copy`),document.body.removeChild(e)}j(!0),setTimeout(()=>j(!1),2e3)}},ke=()=>A?(0,r.jsxs)(`div`,{className:`w-full max-w-xs mb-6`,children:[(0,r.jsx)(`p`,{className:`text-2xs font-bold uppercase tracking-wider mb-1.5 ${V?`text-zinc-400`:`text-gray-500`}`,children:U?`Submission Number`:`Registration Number`}),(0,r.jsxs)(`div`,{part:`registration-number`,className:`flex items-center gap-2 pl-4 pr-1.5 py-1.5 rounded-xl border ${V?`bg-zinc-900 border-zinc-700`:`bg-gray-50 border-gray-200`}`,children:[(0,r.jsx)(`span`,{className:`flex-1 text-left font-mono font-bold text-base select-all break-all`,children:A}),(0,r.jsxs)(`button`,{part:`copy-button`,type:`button`,onClick:Oe,className:`flex items-center gap-1 px-3 py-1.5 rounded-lg text-xs font-bold text-white shrink-0 cursor-pointer hover:opacity-90 transition-opacity`,style:{backgroundColor:H},title:`Copy registration number`,children:[le?(0,r.jsx)(se,{size:13}):(0,r.jsx)(pe,{size:13}),(0,r.jsx)(`span`,{children:le?`Copied`:`Copy`})]})]})]}):null;if(!c&&e.displayMode===`popup`){let e={...st(ue),...M?{transform:`translate3d(${M.x}px, ${M.y}px, 0) scale(1.05)`,transition:`none`,userSelect:`none`}:F?{transform:F.transform,transition:F.transition}:{transition:`all 0.3s cubic-bezier(0.16, 1, 0.3, 1)`}},t=he||L;return(0,r.jsxs)(`div`,{ref:R,onMouseEnter:()=>ge(!0),onMouseLeave:()=>ge(!1),className:`fixed ${ct(ue)} z-50 select-none group`,style:e,children:[(0,r.jsx)(`div`,{onPointerDown:De,className:`absolute -top-1.5 -left-1.5 w-7 h-7 rounded-full bg-slate-900 text-white shadow-lg border-2 border-white flex items-center justify-center cursor-grab active:cursor-grabbing hover:bg-black hover:scale-110 active:scale-95 transition-all duration-200 z-10 touch-none ${t?`opacity-100 scale-100 pointer-events-auto`:`opacity-0 scale-75 pointer-events-none group-hover:opacity-100 group-hover:scale-100 group-hover:pointer-events-auto`}`,title:`Hold and drag to change position`,children:(0,r.jsx)(Pe,{size:13,className:`pointer-events-none text-white`})}),(0,r.jsx)(`button`,{part:`launcher`,type:`button`,onClick:e=>{e.stopPropagation(),!L&&l(!0)},className:`w-16 h-16 rounded-full text-white shadow-xl flex items-center justify-center cursor-pointer hover:scale-105 active:scale-95 transition-transform`,style:{backgroundColor:H},title:`Click to open registration`,children:(0,r.jsx)(`span`,{className:`font-bold text-sm tracking-wide pointer-events-none`,children:`Join`})})]})}let Ae=e.displayMode===`fullscreen`||e.displayMode===`popup`&&u,X=e.displayMode===`widget`,Z=at(be,V,X),Ne=`${V?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`} flex flex-col transition-all duration-300 ease-in-out `,Fe=e.theme?.fontFamily,Ie=!Fe||Fe===`inherit`?{}:{fontFamily:`var(--vx-font-family, ${Fe})`};Ie[`--vx-accent`]=H,Ae?Ne+=`fixed inset-0 z-[9999] rounded-none overflow-hidden `:e.displayMode===`popup`?(Ne+=`fixed ${ct(ue)} z-50 rounded-xl shadow-2xl border ${V?`border-zinc-800`:`border-gray-200`} overflow-hidden `,Ie.width=e.width||`400px`,Ie.height=e.height||`700px`,Ie.maxHeight=`90vh`,Ie.maxWidth=`calc(100vw - 32px)`,Object.assign(Ie,st(ue))):(Ne+=`relative w-full min-h-screen border-none shadow-none rounded-none `,Ie.width=`100%`,Ie.minHeight=`100vh`);let Le=U?`Abstract Submission`:t===`registration`?_||`Registration`:`Attendee Portal`,Re=te.trim().toLowerCase(),ze=Re?h.filter(e=>[e.type,e.name,e.category,e.description,e.currency,e.price,e.tax_info,...Array.isArray(e.perks)?e.perks:[]].filter(e=>e!=null&&e!==``).join(` `).toLowerCase().includes(Re)):h,Be=`max-w-2xl mx-auto w-full rounded-3xl border overflow-hidden ${V?`bg-zinc-900 border-zinc-800 shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_24px_48px_-24px_rgba(15,23,42,0.16)]`}`,Ve=()=>{if(h.length===0)return null;let e=h.find(e=>String(e.id)===E)||(h.length===1?h[0]:null),t=e?e.type||e.name||e.label:``;return(0,r.jsxs)(`div`,{part:`category-panel`,className:Be,children:[(0,r.jsxs)(`div`,{className:`px-5 sm:px-7 pt-6 sm:pt-7 pb-5 flex items-center gap-3.5`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-xl flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:(0,r.jsx)(ve,{size:20})}),(0,r.jsx)(`div`,{className:`min-w-0`,children:(0,r.jsx)(`h3`,{part:`list-title`,className:`text-lg sm:text-xl font-semibold tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:`Choose a submission category`})})]}),(0,r.jsx)(`div`,{role:`radiogroup`,"aria-label":`Submission category`,className:`border-t divide-y ${V?`border-zinc-800 divide-zinc-800`:`border-slate-100 divide-slate-100`}`,children:h.map(t=>{let n=t.type||t.name||t.label,i=!!e&&String(e.id)===String(t.id);return(0,r.jsxs)(`button`,{part:i?`category category-active`:`category`,type:`button`,role:`radio`,"aria-checked":i,onClick:()=>D(String(t.id)),className:`group w-full flex items-center gap-4 px-5 sm:px-7 py-4 text-left transition-colors cursor-pointer outline-none focus-visible:bg-[color-mix(in_srgb,var(--vx-accent)_8%,transparent)] ${i?``:V?`hover:bg-zinc-800/60`:`hover:bg-slate-50`}`,style:i?{backgroundColor:`color-mix(in srgb, ${H} ${V?14:6}%, transparent)`}:void 0,children:[(0,r.jsx)(`span`,{"aria-hidden":`true`,className:`w-5 h-5 rounded-full border-2 flex items-center justify-center shrink-0 transition-colors ${i?``:V?`border-zinc-600`:`border-slate-300`}`,style:i?{borderColor:H}:void 0,children:i&&(0,r.jsx)(`span`,{className:`w-2.5 h-2.5 rounded-full`,style:{backgroundColor:H}})}),(0,r.jsxs)(`span`,{className:`flex-1 min-w-0`,children:[(0,r.jsx)(`span`,{className:`block text-[15px] font-semibold leading-snug ${V?`text-white`:`text-slate-900`}`,children:n}),t.description&&(0,r.jsx)(`span`,{className:`block text-[13px] mt-0.5 line-clamp-1 ${V?`text-zinc-400`:`text-slate-500`}`,children:t.description})]}),t.category&&(0,r.jsx)(`span`,{className:`hidden sm:inline-block text-[10px] font-semibold uppercase tracking-wider px-2.5 py-1 rounded-full shrink-0 ${V?`bg-zinc-800 text-zinc-300`:`bg-slate-100 text-slate-600`}`,children:t.category}),(0,r.jsx)(ie,{size:16,className:`shrink-0 transition-all ${i?`translate-x-0.5`:`${V?`text-zinc-600`:`text-slate-300`} group-hover:translate-x-0.5`}`,style:i?{color:H}:void 0})]},t.id)})}),(0,r.jsxs)(`div`,{className:`px-5 sm:px-7 py-5 border-t flex flex-col-reverse sm:flex-row sm:items-center sm:justify-between gap-3 ${V?`border-zinc-800`:`border-slate-100`}`,children:[(0,r.jsx)(`p`,{className:`text-[13px] truncate ${V?`text-zinc-400`:`text-slate-500`}`,children:e?(0,r.jsxs)(r.Fragment,{children:[`Selected: `,(0,r.jsx)(`span`,{className:`font-semibold ${V?`text-zinc-200`:`text-slate-700`}`,children:t})]}):`Select a category to continue`}),(0,r.jsxs)(`button`,{part:`button button-primary continue-button`,type:`button`,disabled:!e,onClick:()=>e&&b(e),style:{background:`linear-gradient(135deg, ${H}, color-mix(in srgb, ${H} 80%, black))`,boxShadow:e?`0 10px 24px -12px color-mix(in srgb, ${H} 70%, transparent)`:void 0},className:`group shrink-0 inline-flex items-center justify-center gap-2 h-11 px-5 rounded-xl text-sm font-semibold text-white transition-all hover:brightness-110 active:scale-[0.99] cursor-pointer disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:brightness-100`,children:[(0,r.jsx)(`span`,{children:`Continue to submission`}),(0,r.jsx)(ie,{size:16,className:`transition-transform group-hover:translate-x-0.5`})]})]})]})},Ue=e=>(0,r.jsxs)(`div`,{part:`category-panel`,className:Be,children:[(0,r.jsxs)(`div`,{className:`px-5 sm:px-7 pt-6 sm:pt-7 pb-5 flex items-center gap-3.5`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-11 h-11 rounded-xl`}),(0,r.jsx)(`div`,{className:`${e} h-4 w-56`})]}),(0,r.jsx)(`div`,{className:`border-t divide-y ${V?`border-zinc-800 divide-zinc-800`:`border-slate-100 divide-slate-100`}`,children:[0,1,2].map(t=>(0,r.jsxs)(`div`,{className:`flex items-center gap-4 px-5 sm:px-7 py-4`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-5 h-5 rounded-full`,style:{animationDelay:`${t*90}ms`}}),(0,r.jsxs)(`div`,{className:`flex-1 space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-3.5 w-1/2`,style:{animationDelay:`${t*90}ms`}}),(0,r.jsx)(`div`,{className:`${e} h-3 w-3/4`,style:{animationDelay:`${t*90}ms`}})]})]},t))}),(0,r.jsx)(`div`,{className:`px-5 sm:px-7 py-5 border-t flex justify-end ${V?`border-zinc-800`:`border-slate-100`}`,children:(0,r.jsx)(`div`,{className:`${e} h-11 w-52`})})]}),Ge=()=>{let e=`vx-skeleton rounded-full`,t=X?6:3;return(0,r.jsxs)(`div`,{part:`page`,role:`status`,"aria-live":`polite`,"aria-busy":`true`,className:`flex flex-col ${X?`w-full flex-1`:`h-full min-h-0`} ${V?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`}`,children:[(0,r.jsx)(`span`,{className:`sr-only`,children:`Loading form types…`}),(0,r.jsx)(`div`,{part:`header`,className:`relative overflow-hidden z-10 shrink-0 text-white`,style:{background:`linear-gradient(135deg, ${H} 0%, color-mix(in srgb, ${H} 76%, black) 100%)`},children:(0,r.jsxs)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-5 sm:py-6 flex items-center gap-3.5`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-2xl bg-white/15 ring-1 ring-inset ring-white/30 shrink-0`}),(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-5 w-48`}),(0,r.jsx)(`div`,{className:`${e} h-3 w-64 max-w-[60vw]`})]})]})}),!U&&(0,r.jsx)(`div`,{part:`tabs`,className:`shrink-0 border-b ${V?`border-zinc-800 bg-zinc-900`:`border-slate-200 bg-white`}`,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-3`,children:(0,r.jsxs)(`div`,{className:`grid grid-cols-2 gap-1 p-1 rounded-xl max-w-md ${V?`bg-zinc-800`:`bg-slate-100`}`,children:[(0,r.jsx)(`div`,{className:`h-9 rounded-lg ${V?`bg-zinc-950`:`bg-white shadow-sm`}`}),(0,r.jsx)(`div`,{className:`h-9`})]})})}),(0,r.jsx)(`div`,{part:`list`,className:`${X?`w-full flex-1`:`overflow-hidden flex-1 min-h-0`} relative ${V?`bg-zinc-950`:`bg-slate-50`}`,style:Z,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-6 sm:py-8 space-y-5`,children:U?Ue(e):(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`div`,{part:`search`,className:`flex flex-col sm:flex-row sm:items-end sm:justify-between gap-3`,children:[(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-4 w-56`}),(0,r.jsx)(`div`,{className:`${e} h-3 w-28`})]}),(0,r.jsx)(`div`,{className:`h-10 w-full sm:w-72 rounded-xl border ${V?`bg-zinc-900 border-zinc-800`:`bg-white border-slate-200`}`})]}),(0,r.jsx)(`div`,{part:`card-grid`,className:X?`grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5`:`space-y-3`,children:Array.from({length:t},(t,n)=>{let i={animationDelay:`${n*90}ms`};return(0,r.jsxs)(`div`,{part:`card`,className:`rounded-2xl border p-5 sm:p-6 flex flex-col ${V?`bg-zinc-900 border-zinc-800`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04)]`}`,children:[(0,r.jsx)(`div`,{className:`vx-skeleton w-11 h-11 rounded-xl`,style:i}),(0,r.jsx)(`div`,{className:`${e} mt-5 h-5 w-3/5`,style:i}),(0,r.jsx)(`div`,{className:`${e} mt-3 h-3 w-4/5`,style:i}),(0,r.jsxs)(`div`,{className:`mt-6 pt-5 border-t border-dashed flex items-end justify-between gap-3 ${V?`border-zinc-800`:`border-slate-200`}`,children:[(0,r.jsxs)(`div`,{className:`space-y-2`,children:[(0,r.jsx)(`div`,{className:`${e} h-2.5 w-20`,style:i}),(0,r.jsx)(`div`,{className:`${e} h-6 w-28`,style:i})]}),(0,r.jsx)(`div`,{className:`${e} h-10 w-28`,style:i})]})]},n)})})]})})})]})},qe=()=>{let e=!!y,t=U?ve:Ke,n=e?U?`Submitting your abstract`:`Submitting your registration`:`Loading your registration`,i=y?y.type||y.name||y.label:``,a=!U&&y&&y.price!==void 0&&y.price!==null&&y.price!==``?Number(y.price)>0?[y.currency,Number(y.price).toLocaleString()].filter(Boolean).join(` `):`Free`:``;return(0,r.jsx)(`div`,{part:`screen screen-submitting`,role:`status`,"aria-live":`polite`,"aria-busy":`true`,className:`flex-1 flex items-center justify-center px-4 py-16 ${X?`min-h-[70vh]`:`h-full`} ${V?`bg-zinc-950`:`bg-slate-50`}`,style:Z,children:(0,r.jsxs)(`div`,{part:`portal-card`,className:`w-full max-w-sm rounded-3xl border p-8 text-center ${V?`bg-zinc-900 border-zinc-800 shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04),0_24px_48px_-24px_rgba(15,23,42,0.18)]`}`,children:[(0,r.jsxs)(`div`,{className:`relative mx-auto w-16 h-16`,children:[(0,r.jsx)(`div`,{className:`absolute inset-0 rounded-full`,style:{boxShadow:`inset 0 0 0 4px color-mix(in srgb, ${H} 14%, transparent)`}}),(0,r.jsx)(`div`,{className:`absolute inset-0 rounded-full motion-safe:animate-spin`,style:{background:`conic-gradient(from 0deg, transparent 0deg, ${H} 300deg, transparent 360deg)`,mask:`radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 4px))`,WebkitMask:`radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 4px))`}}),(0,r.jsx)(`div`,{className:`absolute inset-[10px] rounded-full flex items-center justify-center`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:(0,r.jsx)(t,{size:20})})]}),(0,r.jsx)(`h3`,{part:`screen-title`,className:`mt-6 text-xl font-bold tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:n}),(0,r.jsx)(`p`,{part:`screen-message`,className:`mt-1.5 text-[13px] leading-relaxed text-balance ${V?`text-zinc-400`:`text-slate-500`}`,children:`This usually takes a few seconds. Please keep this page open.`}),i&&(0,r.jsxs)(`div`,{className:`mt-5 inline-flex max-w-full items-center gap-2 rounded-full px-3 py-1.5 text-xs font-semibold ${V?`bg-zinc-800 text-zinc-200`:`bg-slate-100 text-slate-700`}`,children:[(0,r.jsx)(`span`,{className:`truncate`,children:i}),a&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`span`,{"aria-hidden":`true`,className:V?`text-zinc-600`:`text-slate-300`,children:`•`}),(0,r.jsx)(`span`,{className:`shrink-0 tabular-nums`,style:{color:H},children:a})]})]}),(0,r.jsx)(`div`,{className:`mt-6 h-1 w-full overflow-hidden rounded-full ${V?`bg-zinc-800`:`bg-slate-100`}`,children:(0,r.jsx)(`div`,{className:`vx-progress-bar h-full w-2/5 rounded-full`,style:{backgroundColor:H}})})]})})};return(0,r.jsx)(`div`,{part:`widget`,className:Ne,style:{...Ie,overflow:X?`visible`:`clip`},onScroll:e=>{X||(e.currentTarget.scrollTop!==0&&(e.currentTarget.scrollTop=0),e.currentTarget.scrollLeft!==0&&(e.currentTarget.scrollLeft=0))},children:w&&!y&&!ne?Ge():w?qe():ne?k?(0,r.jsxs)(`div`,{part:`screen screen-payment`,className:`flex flex-col h-full relative overflow-y-auto ${V?`bg-black text-white`:`bg-white text-gray-900`}`,children:[(0,r.jsxs)(`div`,{part:`screen-header`,className:`p-4 shadow-sm flex justify-between items-center z-10`,style:{backgroundColor:H,color:`white`},children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h2`,{part:`screen-header-title`,className:`text-xl font-bold`,style:Q,children:`Complete Payment`}),(0,r.jsx)(`p`,{className:`text-xs opacity-90 mt-0.5`,children:`Registration Submitted`})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-3`,children:e.displayMode===`popup`&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`button`,{onClick:()=>d(!u),title:u?`Minimize`:`Expand`,className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:u?(0,r.jsx)(Me,{size:18}):(0,r.jsx)(je,{size:18})}),(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:(0,r.jsx)(et,{size:24})})]})})]}),(0,r.jsxs)(`div`,{className:`flex-1 flex flex-col items-center justify-center p-6 text-center`,children:[(0,r.jsx)(`div`,{className:`w-16 h-16 rounded-full flex items-center justify-center mb-4 text-2xl shadow-md`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:`💳`}),(0,r.jsx)(`h3`,{part:`screen-title`,className:`text-2xl font-bold mb-2 ${V?`text-white`:`text-gray-900`}`,style:Q,children:`Done Your Payment First`}),(0,r.jsx)(`p`,{part:`screen-message`,className:`text-sm mb-6 max-w-xs leading-relaxed ${V?`text-zinc-300`:`text-gray-600`}`,children:`Please complete your payment in the new tab to confirm your booking and finalize your registration.`}),ke(),(0,r.jsxs)(`div`,{className:`w-full max-w-xs space-y-3`,children:[(0,r.jsxs)(`a`,{part:`button button-primary`,href:k,target:`_blank`,rel:`noopener noreferrer`,className:`flex items-center justify-center gap-2 font-bold px-5 py-3 rounded-lg transition-opacity hover:opacity-90 text-white shadow-md w-full`,style:{backgroundColor:H},children:[(0,r.jsx)(`span`,{children:`Open Payment Page`}),(0,r.jsx)(_e,{size:16})]}),(0,r.jsx)(`button`,{part:`button button-link`,onClick:Ee,className:`w-full py-2.5 px-4 text-sm font-semibold transition-colors cursor-pointer ${V?`text-zinc-400 hover:text-white`:`text-gray-500 hover:text-gray-900`}`,children:`Register Another Person`})]})]})]}):(0,r.jsxs)(`div`,{part:`screen screen-success`,className:`flex flex-col h-full items-center justify-center p-8 text-center relative ${V?`bg-black text-white`:`bg-white text-gray-900`}`,children:[e.displayMode===`popup`&&(0,r.jsx)(`div`,{className:`absolute top-4 right-4 flex items-center gap-2`,children:(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`cursor-pointer ${V?`text-zinc-400 hover:text-white`:`text-gray-400 hover:text-gray-900`}`,children:(0,r.jsx)(et,{size:24})})}),(0,r.jsx)(`div`,{className:`w-20 h-20 rounded-full flex items-center justify-center mb-6 text-4xl shadow-md`,style:{backgroundColor:H,color:`white`},children:`✓`}),(0,r.jsx)(`h2`,{part:`screen-title`,className:`text-3xl font-bold mb-3 ${V?`text-white`:`text-gray-900`}`,style:Q,children:U?`Abstract Submitted Successfully`:`Thank You!`}),(0,r.jsx)(`p`,{part:`screen-message`,className:`mb-6 ${V?`text-zinc-300`:`text-gray-600`}`,children:U?`Your reference submission number is below.`:`Your registration has been successfully received.`}),ke(),(0,r.jsx)(`button`,{part:`button button-primary`,onClick:Ee,style:{backgroundColor:H},className:`text-white font-bold py-3 px-8 rounded-md hover:opacity-90 transition-opacity shadow-md cursor-pointer`,children:`Back`})]}):O?(0,r.jsxs)(`div`,{part:`screen screen-error`,className:`flex flex-col h-full relative overflow-y-auto ${V?`bg-black text-white`:`bg-white text-gray-900`}`,children:[(0,r.jsxs)(`div`,{part:`screen-header`,className:`p-4 shadow-sm flex justify-between items-center z-10 bg-red-600 text-white`,children:[(0,r.jsxs)(`div`,{children:[(0,r.jsx)(`h2`,{part:`screen-header-title`,className:`text-xl font-bold`,style:Q,children:U?`Submission Failed`:`Registration Failed`}),(0,r.jsx)(`p`,{className:`text-xs opacity-90 mt-0.5`,children:`Please try again`})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-3`,children:e.displayMode===`popup`&&(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer`,children:(0,r.jsx)(et,{size:24})})})]}),(0,r.jsxs)(`div`,{className:`flex-1 flex flex-col items-center justify-center p-6 text-center`,children:[(0,r.jsx)(`div`,{className:`w-16 h-16 rounded-full flex items-center justify-center mb-4 text-2xl shadow-md border ${V?`bg-red-950/60 text-red-400 border-red-900`:`bg-red-50 text-red-600 border-red-200`}`,children:`✕`}),(0,r.jsx)(`h3`,{part:`screen-title`,className:`text-2xl font-bold mb-2 ${V?`text-white`:`text-gray-900`}`,style:Q,children:`Submission Error`}),(0,r.jsx)(`p`,{part:`screen-message`,className:`text-sm mb-6 max-w-xs leading-relaxed ${V?`text-zinc-300`:`text-gray-600`}`,children:O}),(0,r.jsxs)(`div`,{className:`w-full max-w-xs space-y-3`,children:[(0,r.jsx)(`button`,{part:`button button-primary`,onClick:()=>ae(null),style:{backgroundColor:H},className:`flex items-center justify-center gap-2 font-bold px-5 py-3 rounded-lg transition-opacity hover:opacity-90 text-white shadow-md w-full cursor-pointer`,children:(0,r.jsx)(`span`,{children:`Try Again`})}),(0,r.jsx)(`button`,{part:`button button-link`,onClick:()=>{ae(null),b(null)},className:`w-full py-2.5 px-4 text-sm font-semibold transition-colors cursor-pointer ${V?`text-zinc-400 hover:text-white`:`text-gray-500 hover:text-gray-900`}`,children:U?`Choose Another Category`:`Choose Another Ticket`})]})]})]}):y?(0,r.jsx)(tt,{schema:U?C:y.form_schema,ticketType:y,theme:e.theme,displayMode:e.displayMode,backgroundStyle:Z,isExpanded:u,onToggleExpand:()=>d(!u),onClose:()=>l(!1),onSubmit:Y,onChange:we,initialValues:Ce,isDark:V,apiClient:G,storage:K,onError:e.onError,onEvent:e.onEvent,showReviewFields:U,onBack:()=>{q.current&&clearTimeout(q.current),b(null)}}):(0,r.jsxs)(`div`,{part:`page`,className:`flex flex-col ${X?`w-full flex-1`:`h-full min-h-0`} ${V?`bg-zinc-950 text-white`:`bg-slate-50 text-slate-900`}`,children:[(0,r.jsxs)(`div`,{part:`header`,className:`relative overflow-hidden z-10 shrink-0 text-white`,style:{backgroundColor:H,background:`linear-gradient(135deg, ${H} 0%, color-mix(in srgb, ${H} 76%, black) 100%)`},children:[(0,r.jsx)(`div`,{"aria-hidden":`true`,className:`pointer-events-none absolute inset-0 opacity-[0.14]`,style:{backgroundImage:`radial-gradient(circle, rgba(255,255,255,0.9) 1px, transparent 1px)`,backgroundSize:`18px 18px`,maskImage:`linear-gradient(to right, transparent, black 30%, black 70%, transparent)`}}),(0,r.jsx)(`div`,{"aria-hidden":`true`,className:`pointer-events-none absolute -top-24 -right-10 h-64 w-64 rounded-full bg-white/15 blur-3xl`}),ye&&(0,r.jsxs)(`div`,{className:`absolute inset-y-0 right-0 flex max-w-[65%] pointer-events-none select-none`,children:[(0,r.jsx)(`img`,{src:ye,alt:``,"aria-hidden":`true`,className:`h-full w-auto object-cover object-right`}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 left-0 w-2/5`,style:{background:`linear-gradient(to right, color-mix(in srgb, ${H} 80%, black) 0%, transparent 100%)`}})]}),(0,r.jsxs)(`div`,{className:`relative z-[1] max-w-6xl mx-auto w-full px-4 sm:px-6 py-5 sm:py-6 flex justify-between items-center gap-3 min-w-0`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-3.5 min-w-0`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-2xl bg-white/15 ring-1 ring-inset ring-white/30 flex items-center justify-center shrink-0 shadow-[inset_0_1px_0_rgba(255,255,255,0.25)]`,children:(0,r.jsx)(We,{size:20,className:`text-white`})}),(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsxs)(`div`,{className:`flex items-center gap-2 min-w-0`,children:[(0,r.jsx)(`h2`,{part:`header-title`,className:`text-lg sm:text-2xl font-bold tracking-tight leading-tight break-words`,style:Q,children:Le}),(0,r.jsxs)(`span`,{className:`hidden sm:inline-flex shrink-0 items-center gap-1.5 text-[10px] font-semibold px-2 py-0.5 rounded-full bg-white/15 ring-1 ring-inset ring-white/25 uppercase tracking-wider`,children:[(0,r.jsx)(`span`,{className:`h-1.5 w-1.5 rounded-full bg-emerald-300`}),`Official Portal`]})]}),(0,r.jsx)(`p`,{part:`header-subtitle`,className:`text-xs sm:text-sm text-white/80 mt-0.5`,children:U?`Select a category below to submit your abstract`:t===`registration`?`Select a registration type below to begin your application`:`Registration & Profile Management`})]})]}),(0,r.jsx)(`div`,{className:`flex items-center gap-3`,children:e.displayMode===`popup`&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`button`,{onClick:()=>d(!u),title:u?`Minimize`:`Expand`,className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer p-1`,children:u?(0,r.jsx)(Me,{size:18}):(0,r.jsx)(je,{size:18})}),(0,r.jsx)(`button`,{onClick:()=>l(!1),className:`opacity-80 hover:opacity-100 transition-opacity cursor-pointer p-1`,children:(0,r.jsx)(et,{size:22})})]})})]})]}),!U&&(0,r.jsx)(`div`,{part:`tabs`,className:`shrink-0 border-b ${V?`border-zinc-800 bg-zinc-900`:`border-slate-200 bg-white`}`,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-3`,children:(0,r.jsx)(`div`,{role:`tablist`,className:`grid grid-cols-2 gap-1 p-1 rounded-xl max-w-md ${V?`bg-zinc-800`:`bg-slate-100`}`,children:[{key:`registration`,label:`Registration Forms`,Icon:P},{key:`attendee`,label:`Attendee Login`,Icon:Te}].map(({key:e,label:n,Icon:a})=>{let o=t===e;return(0,r.jsxs)(`button`,{part:o?`tab tab-active`:`tab`,role:`tab`,"aria-selected":o,type:`button`,onClick:()=>i(e),className:`inline-flex items-center justify-center gap-1.5 sm:gap-2 py-2 px-2 sm:px-3 text-[13px] sm:text-sm font-semibold rounded-lg transition-all cursor-pointer ${o?V?`bg-zinc-950 shadow-sm`:`bg-white shadow-sm ring-1 ring-slate-200/70`:V?`text-zinc-400 hover:text-zinc-200`:`text-slate-500 hover:text-slate-800`}`,style:o?{color:H}:void 0,children:[(0,r.jsx)(a,{size:15,className:`hidden sm:block shrink-0`}),(0,r.jsx)(`span`,{className:`truncate`,children:n})]},e)})})})}),(U||t===`registration`)&&(0,r.jsx)(`div`,{part:`list`,className:`${X?`w-full flex-1`:`overflow-y-auto flex-1 min-h-0 overscroll-contain`} relative ${V?`bg-zinc-950`:`bg-slate-50`}`,style:Z,children:(0,r.jsx)(`div`,{className:`max-w-6xl mx-auto w-full px-4 sm:px-6 py-6 sm:py-8 space-y-5`,children:U?Ve():(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(`div`,{part:`search`,className:`flex flex-col sm:flex-row sm:items-end sm:justify-between gap-3`,children:[(0,r.jsxs)(`div`,{className:`min-w-0`,children:[(0,r.jsx)(`h3`,{part:`list-title`,className:`text-base sm:text-lg font-semibold tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:U?`Choose a submission category`:`Choose your registration type`}),h.length>0&&(0,r.jsx)(`p`,{part:`list-count`,className:`text-xs mt-0.5 ${V?`text-zinc-400`:`text-slate-500`}`,children:Re?`${ze.length} of ${h.length} options`:`${h.length} ${h.length===1?`option`:`options`} available`})]}),(0,r.jsxs)(`div`,{className:`relative w-full sm:w-72`,children:[(0,r.jsx)(`input`,{part:`input search-input`,type:`text`,value:te,onChange:e=>T(e.target.value),placeholder:U?`Search categories…`:`Search registration types…`,"aria-label":`Search`,className:`w-full h-10 pl-9 pr-8 text-sm rounded-xl border transition-all focus:outline-none focus:border-(--vx-accent) focus:ring-4 focus:ring-[color-mix(in_srgb,var(--vx-accent)_15%,transparent)] ${V?`bg-zinc-900 border-zinc-700 text-white placeholder:text-zinc-500`:`bg-white border-slate-200 text-slate-900 placeholder:text-slate-400 shadow-[0_1px_2px_rgba(15,23,42,0.04)]`}`}),(0,r.jsx)(`div`,{className:`absolute inset-y-0 left-3 flex items-center pointer-events-none ${V?`text-zinc-500`:`text-slate-400`}`,children:(0,r.jsx)(He,{size:15,className:`block`})}),te&&(0,r.jsx)(`button`,{type:`button`,onClick:()=>T(``),"aria-label":`Clear search`,className:`absolute inset-y-0 right-2.5 flex items-center cursor-pointer ${V?`text-zinc-500 hover:text-zinc-300`:`text-slate-400 hover:text-slate-600`}`,children:(0,r.jsx)(et,{size:14})})]})]}),h.length===0?null:ze.length===0?(0,r.jsxs)(`div`,{part:`empty-state`,className:`flex flex-col items-center text-center py-16 px-6 rounded-3xl border border-dashed ${V?`bg-zinc-900/60 border-zinc-800 text-zinc-400`:`bg-white/70 border-slate-300 text-slate-500`}`,children:[(0,r.jsx)(`div`,{className:`w-12 h-12 rounded-2xl flex items-center justify-center mb-4 ${V?`bg-zinc-800`:`bg-slate-100`}`,children:(0,r.jsx)(He,{size:20})}),(0,r.jsxs)(`p`,{className:`text-base font-semibold ${V?`text-white`:`text-slate-900`}`,children:[`No matches for “`,te.trim(),`”`]}),(0,r.jsx)(`p`,{className:`text-sm mt-1`,children:`Try a different search term.`}),(0,r.jsx)(`button`,{part:`button button-secondary`,onClick:()=>T(``),className:`mt-5 px-4 py-2 rounded-full text-sm font-semibold border cursor-pointer transition-colors ${V?`border-zinc-700 text-zinc-200 hover:bg-zinc-800`:`border-slate-200 bg-white text-slate-700 hover:bg-slate-50`}`,children:`Clear search`})]}):(0,r.jsx)(`div`,{part:`card-grid`,className:X?`grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5`:`space-y-3`,children:ze.map(e=>{let t=e.type||e.name||e.label,n=e.price!==void 0&&e.price!==null&&e.price!==``,i=n&&(Number(e.price)===0||String(e.price).toLowerCase()===`free`),a=Array.isArray(e.perks)?e.perks:[],o=U?ve:Ke;return(0,r.jsxs)(`div`,{part:`card`,role:`button`,tabIndex:0,"aria-label":`Select ${t}`,onClick:()=>b(e),onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),b(e))},className:`group relative flex flex-col rounded-2xl border p-5 sm:p-6 cursor-pointer transition-all duration-300 hover:-translate-y-1 outline-none focus-visible:ring-4 focus-visible:ring-[color-mix(in_srgb,var(--vx-accent)_25%,transparent)] hover:border-[color-mix(in_srgb,var(--vx-accent)_35%,transparent)] ${V?`bg-zinc-900 border-zinc-800 hover:shadow-[0_24px_48px_-24px_rgba(0,0,0,0.8)]`:`bg-white border-slate-200/80 shadow-[0_1px_2px_rgba(15,23,42,0.04)] hover:shadow-[0_24px_48px_-24px_color-mix(in_srgb,var(--vx-accent)_45%,transparent)]`}`,children:[(0,r.jsx)(`span`,{"aria-hidden":`true`,className:`pointer-events-none absolute inset-x-8 top-0 h-[3px] rounded-b-full opacity-0 transition-opacity duration-300 group-hover:opacity-100`,style:{background:`linear-gradient(90deg, transparent, ${H}, transparent)`}}),(0,r.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,r.jsx)(`div`,{className:`w-11 h-11 rounded-xl flex items-center justify-center shrink-0 transition-transform duration-300 group-hover:scale-105`,style:{backgroundColor:`color-mix(in srgb, ${H} 12%, transparent)`,color:H},children:(0,r.jsx)(o,{size:20})}),(e.category||e.seats_left)&&(0,r.jsxs)(`div`,{className:`flex flex-wrap justify-end items-center gap-1.5`,children:[e.category&&(0,r.jsx)(`span`,{part:`card-category`,className:`text-[10px] font-semibold uppercase tracking-wider px-2.5 py-1 rounded-full ${V?`bg-zinc-800 text-zinc-300`:`bg-slate-100 text-slate-600`}`,children:e.category}),e.seats_left&&(0,r.jsxs)(`span`,{part:`card-seats`,className:`text-[10px] font-semibold px-2.5 py-1 rounded-full flex items-center gap-1 ${V?`bg-amber-950/60 text-amber-300`:`bg-amber-50 text-amber-700`}`,children:[(0,r.jsx)(fe,{size:10}),(0,r.jsx)(`span`,{children:e.seats_left})]})]})]}),(0,r.jsx)(`h3`,{part:`card-title`,className:`mt-4 text-lg font-semibold leading-snug tracking-tight ${V?`text-white`:`text-slate-900`}`,style:Q,children:t}),e.description&&(0,r.jsx)(`p`,{part:`card-description`,className:`mt-1.5 text-sm leading-relaxed line-clamp-2 ${V?`text-zinc-400`:`text-slate-500`}`,children:e.description}),a.length>0&&(0,r.jsx)(`ul`,{part:`card-perks`,className:`mt-4 space-y-2`,children:a.map((e,t)=>(0,r.jsxs)(`li`,{className:`flex items-start gap-2 text-sm`,children:[(0,r.jsx)(`span`,{className:`mt-0.5 w-4 h-4 rounded-full flex items-center justify-center shrink-0`,style:{backgroundColor:`color-mix(in srgb, ${H} 14%, transparent)`,color:H},children:(0,r.jsx)(se,{size:10,strokeWidth:3})}),(0,r.jsx)(`span`,{className:V?`text-zinc-300`:`text-slate-600`,children:e})]},t))}),(0,r.jsx)(`div`,{className:`flex-1`}),(0,r.jsxs)(`div`,{className:`mt-6 pt-5 border-t border-dashed flex items-end justify-between gap-3 ${V?`border-zinc-800`:`border-slate-200`}`,children:[(0,r.jsx)(`div`,{className:`min-w-0`,children:n&&!U?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(`p`,{className:`text-[10px] font-semibold uppercase tracking-wider ${V?`text-zinc-500`:`text-slate-400`}`,children:`Registration fee`}),(0,r.jsx)(`p`,{part:`card-price`,className:`text-2xl font-bold tracking-tight tabular-nums leading-tight`,style:{color:H},children:i?`Free`:[e.currency,Number(e.price).toLocaleString()].filter(Boolean).join(` `)}),e.tax_info&&(0,r.jsx)(`p`,{part:`card-tax`,className:`text-[11px] mt-0.5 ${V?`text-zinc-500`:`text-slate-400`}`,children:e.tax_info})]}):null}),(0,r.jsxs)(`span`,{part:`button button-primary card-button`,className:`inline-flex shrink-0 items-center gap-2 h-10 pl-4 pr-1.5 rounded-full text-sm font-semibold text-white transition-shadow duration-300 group-hover:shadow-[0_8px_20px_-6px_color-mix(in_srgb,var(--vx-accent)_70%,transparent)]`,style:{backgroundColor:H},children:[U?`Submit`:`Register`,(0,r.jsx)(`span`,{className:`w-7 h-7 rounded-full bg-white/20 flex items-center justify-center transition-transform duration-300 group-hover:translate-x-0.5`,children:(0,r.jsx)(ie,{size:14})})]})]})]},e.id)})})]})})}),!U&&(a||t===`attendee`)&&(0,r.jsx)(`div`,{part:`portal`,className:`${t===`attendee`?`flex`:`hidden`} flex-col ${X?`w-full flex-1`:`flex-1 overflow-hidden min-h-0`}`,style:{...X?{}:{overflow:`clip`},...Z},onScroll:X?void 0:e=>{e.currentTarget.scrollTop!==0&&(e.currentTarget.scrollTop=0),e.currentTarget.scrollLeft!==0&&(e.currentTarget.scrollLeft=0)},children:(0,r.jsx)(it,{apiClient:G,storage:K,logger:W,primaryColor:H,isDark:V,isWidgetPage:X,onEvent:e.onEvent,onError:e.onError})})]})})},ut=`/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
|
|
3
3
|
@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-divide-y-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}}}@layer theme{:root,:host{--font-sans:-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";--font-mono:ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--color-red-50:oklch(97.1% .013 17.38);--color-red-100:oklch(93.6% .032 17.717);--color-red-200:oklch(88.5% .062 18.334);--color-red-300:oklch(80.8% .114 19.571);--color-red-400:oklch(70.4% .191 22.216);--color-red-500:oklch(63.7% .237 25.331);--color-red-600:oklch(57.7% .245 27.325);--color-red-700:oklch(50.5% .213 27.518);--color-red-900:oklch(39.6% .141 25.723);--color-red-950:oklch(25.8% .092 26.042);--color-amber-50:oklch(98.7% .022 95.277);--color-amber-300:oklch(87.9% .169 91.605);--color-amber-500:oklch(76.9% .188 70.08);--color-amber-700:oklch(55.5% .163 48.998);--color-amber-950:oklch(27.9% .077 45.635);--color-emerald-50:oklch(97.9% .021 166.113);--color-emerald-200:oklch(90.5% .093 164.15);--color-emerald-300:oklch(84.5% .143 164.978);--color-emerald-500:oklch(69.6% .17 162.48);--color-emerald-700:oklch(50.8% .118 165.612);--color-emerald-800:oklch(43.2% .095 166.913);--color-emerald-900:oklch(37.8% .077 168.94);--color-emerald-950:oklch(26.2% .051 172.552);--color-indigo-400:oklch(67.3% .182 276.935);--color-fuchsia-100:oklch(95.2% .037 318.852);--color-fuchsia-200:oklch(90.3% .076 319.62);--color-fuchsia-300:oklch(83.3% .145 321.434);--color-fuchsia-500:oklch(66.7% .295 322.15);--color-fuchsia-600:oklch(59.1% .293 322.896);--color-fuchsia-700:oklch(51.8% .253 323.949);--color-fuchsia-800:oklch(45.2% .211 324.591);--color-fuchsia-950:oklch(29.3% .136 325.661);--color-pink-100:oklch(94.8% .028 342.258);--color-slate-50:oklch(98.4% .003 247.858);--color-slate-100:oklch(96.8% .007 247.896);--color-slate-200:oklch(92.9% .013 255.508);--color-slate-300:oklch(86.9% .022 252.894);--color-slate-400:oklch(70.4% .04 256.788);--color-slate-500:oklch(55.4% .046 257.417);--color-slate-600:oklch(44.6% .043 257.281);--color-slate-700:oklch(37.2% .044 257.287);--color-slate-800:oklch(27.9% .041 260.031);--color-slate-900:oklch(20.8% .042 265.755);--color-gray-50:oklch(98.5% .002 247.839);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-200:oklch(92.8% .006 264.531);--color-gray-300:oklch(87.2% .01 258.338);--color-gray-400:oklch(70.7% .022 261.325);--color-gray-500:oklch(55.1% .027 264.364);--color-gray-600:oklch(44.6% .03 256.802);--color-gray-700:oklch(37.3% .034 259.733);--color-gray-800:oklch(27.8% .033 256.848);--color-gray-900:oklch(21% .034 264.665);--color-zinc-100:oklch(96.7% .001 286.375);--color-zinc-200:oklch(92% .004 286.32);--color-zinc-300:oklch(87.1% .006 286.286);--color-zinc-400:oklch(70.5% .015 286.067);--color-zinc-500:oklch(55.2% .016 285.938);--color-zinc-600:oklch(44.2% .017 285.786);--color-zinc-700:oklch(37% .013 285.805);--color-zinc-800:oklch(27.4% .006 286.033);--color-zinc-900:oklch(21% .006 285.885);--color-zinc-950:oklch(14.1% .005 285.823);--color-black:#000;--color-white:#fff;--spacing:.25rem;--container-xs:20rem;--container-sm:24rem;--container-md:28rem;--container-2xl:42rem;--container-3xl:48rem;--container-4xl:56rem;--container-6xl:72rem;--container-7xl:80rem;--text-xs:.75rem;--text-xs--line-height:calc(1 / .75);--text-sm:.875rem;--text-sm--line-height:calc(1.25 / .875);--text-base:1rem;--text-base--line-height:calc(1.5 / 1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75 / 1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75 / 1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2 / 1.5);--text-3xl:1.875rem;--text-3xl--line-height:calc(2.25 / 1.875);--text-4xl:2.25rem;--text-4xl--line-height:calc(2.5 / 2.25);--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--font-weight-extrabold:800;--font-weight-black:900;--tracking-tight:-.025em;--tracking-wide:.025em;--tracking-wider:.05em;--leading-tight:1.25;--leading-snug:1.375;--leading-relaxed:1.625;--radius-md:.375rem;--radius-lg:.5rem;--radius-xl:.75rem;--radius-2xl:1rem;--radius-3xl:1.5rem;--ease-in-out:cubic-bezier(.4, 0, .2, 1);--animate-spin:spin 1s linear infinite;--blur-sm:8px;--blur-md:12px;--blur-xl:24px;--blur-3xl:64px;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring:where(:not(iframe)){outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab, currentcolor 50%, transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.sticky{position:sticky}.inset-0{inset:0}.inset-\\[10px\\]{inset:10px}.inset-x-8{inset-inline:calc(var(--spacing) * 8)}.inset-y-0{inset-block:0}.-top-1\\.5{top:calc(var(--spacing) * -1.5)}.-top-16{top:calc(var(--spacing) * -16)}.-top-24{top:calc(var(--spacing) * -24)}.top-0{top:0}.top-1\\/2{top:50%}.top-1\\/3{top:33.3333%}.top-4{top:calc(var(--spacing) * 4)}.top-5{top:calc(var(--spacing) * 5)}.top-18{top:calc(var(--spacing) * 18)}.-right-10{right:calc(var(--spacing) * -10)}.-right-16{right:calc(var(--spacing) * -16)}.right-0{right:0}.right-1\\/4{right:25%}.right-2\\.5{right:calc(var(--spacing) * 2.5)}.right-4{right:calc(var(--spacing) * 4)}.right-5{right:calc(var(--spacing) * 5)}.-bottom-10{bottom:calc(var(--spacing) * -10)}.bottom-5{bottom:calc(var(--spacing) * 5)}.-left-1\\.5{left:calc(var(--spacing) * -1.5)}.-left-20{left:calc(var(--spacing) * -20)}.left-0{left:0}.left-2\\.5{left:calc(var(--spacing) * 2.5)}.left-3{left:calc(var(--spacing) * 3)}.left-5{left:calc(var(--spacing) * 5)}.z-0{z-index:0}.z-10{z-index:10}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.z-\\[1\\]{z-index:1}.z-\\[9999\\]{z-index:9999}.container{width:100%}@media (width>=40rem){.container{max-width:40rem}}@media (width>=48rem){.container{max-width:48rem}}@media (width>=64rem){.container{max-width:64rem}}@media (width>=80rem){.container{max-width:80rem}}@media (width>=96rem){.container{max-width:96rem}}.-mx-2{margin-inline:calc(var(--spacing) * -2)}.mx-auto{margin-inline:auto}.mt-0\\.5{margin-top:calc(var(--spacing) * .5)}.mt-1{margin-top:var(--spacing)}.mt-1\\.5{margin-top:calc(var(--spacing) * 1.5)}.mt-2{margin-top:calc(var(--spacing) * 2)}.mt-2\\.5{margin-top:calc(var(--spacing) * 2.5)}.mt-3{margin-top:calc(var(--spacing) * 3)}.mt-4{margin-top:calc(var(--spacing) * 4)}.mt-5{margin-top:calc(var(--spacing) * 5)}.mt-6{margin-top:calc(var(--spacing) * 6)}.mt-8{margin-top:calc(var(--spacing) * 8)}.-mb-4{margin-bottom:calc(var(--spacing) * -4)}.mb-1{margin-bottom:var(--spacing)}.mb-1\\.5{margin-bottom:calc(var(--spacing) * 1.5)}.mb-2{margin-bottom:calc(var(--spacing) * 2)}.mb-3{margin-bottom:calc(var(--spacing) * 3)}.mb-4{margin-bottom:calc(var(--spacing) * 4)}.mb-5{margin-bottom:calc(var(--spacing) * 5)}.mb-6{margin-bottom:calc(var(--spacing) * 6)}.ml-0\\.5{margin-left:calc(var(--spacing) * .5)}.ml-1{margin-left:var(--spacing)}.ml-2{margin-left:calc(var(--spacing) * 2)}.line-clamp-1{-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-2{-webkit-line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.block{display:block}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.h-1{height:var(--spacing)}.h-1\\.5{height:calc(var(--spacing) * 1.5)}.h-2\\.5{height:calc(var(--spacing) * 2.5)}.h-3{height:calc(var(--spacing) * 3)}.h-3\\.5{height:calc(var(--spacing) * 3.5)}.h-4{height:calc(var(--spacing) * 4)}.h-5{height:calc(var(--spacing) * 5)}.h-6{height:calc(var(--spacing) * 6)}.h-7{height:calc(var(--spacing) * 7)}.h-8{height:calc(var(--spacing) * 8)}.h-9{height:calc(var(--spacing) * 9)}.h-10{height:calc(var(--spacing) * 10)}.h-11{height:calc(var(--spacing) * 11)}.h-12{height:calc(var(--spacing) * 12)}.h-14{height:calc(var(--spacing) * 14)}.h-16{height:calc(var(--spacing) * 16)}.h-20{height:calc(var(--spacing) * 20)}.h-64{height:calc(var(--spacing) * 64)}.h-72{height:calc(var(--spacing) * 72)}.h-80{height:calc(var(--spacing) * 80)}.h-\\[3px\\]{height:3px}.h-full{height:100%}.max-h-96{max-height:calc(var(--spacing) * 96)}.min-h-0{min-height:0}.min-h-\\[70vh\\]{min-height:70vh}.min-h-screen{min-height:100vh}.w-1\\.5{width:calc(var(--spacing) * 1.5)}.w-1\\/2{width:50%}.w-2\\.5{width:calc(var(--spacing) * 2.5)}.w-2\\/5{width:40%}.w-3\\.5{width:calc(var(--spacing) * 3.5)}.w-3\\/4{width:75%}.w-3\\/5{width:60%}.w-4{width:calc(var(--spacing) * 4)}.w-4\\/5{width:80%}.w-5{width:calc(var(--spacing) * 5)}.w-7{width:calc(var(--spacing) * 7)}.w-8{width:calc(var(--spacing) * 8)}.w-9{width:calc(var(--spacing) * 9)}.w-10{width:calc(var(--spacing) * 10)}.w-11{width:calc(var(--spacing) * 11)}.w-12{width:calc(var(--spacing) * 12)}.w-16{width:calc(var(--spacing) * 16)}.w-20{width:calc(var(--spacing) * 20)}.w-24{width:calc(var(--spacing) * 24)}.w-28{width:calc(var(--spacing) * 28)}.w-32{width:calc(var(--spacing) * 32)}.w-48{width:calc(var(--spacing) * 48)}.w-52{width:calc(var(--spacing) * 52)}.w-56{width:calc(var(--spacing) * 56)}.w-64{width:calc(var(--spacing) * 64)}.w-72{width:calc(var(--spacing) * 72)}.w-80{width:calc(var(--spacing) * 80)}.w-auto{width:auto}.w-full{width:100%}.max-w-2xl{max-width:var(--container-2xl)}.max-w-3xl{max-width:var(--container-3xl)}.max-w-4xl{max-width:var(--container-4xl)}.max-w-6xl{max-width:var(--container-6xl)}.max-w-7xl{max-width:var(--container-7xl)}.max-w-\\[16rem\\]{max-width:16rem}.max-w-\\[60vw\\]{max-width:60vw}.max-w-\\[65\\%\\]{max-width:65%}.max-w-\\[400px\\]{max-width:400px}.max-w-full{max-width:100%}.max-w-md{max-width:var(--container-md)}.max-w-sm{max-width:var(--container-sm)}.max-w-xs{max-width:var(--container-xs)}.min-w-0{min-width:0}.flex-1{flex:1}.shrink-0{flex-shrink:0}.translate-x-0\\.5{--tw-translate-x:calc(var(--spacing) * .5);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-y-1\\/2{--tw-translate-y:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.scale-75{--tw-scale-x:75%;--tw-scale-y:75%;--tw-scale-z:75%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}.transform{transform:var(--tw-rotate-x,) var(--tw-rotate-y,) var(--tw-rotate-z,) var(--tw-skew-x,) var(--tw-skew-y,)}.animate-spin{animation:var(--animate-spin)}.cursor-default{cursor:default}.cursor-grab{cursor:grab}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.touch-none{touch-action:none}.resize-y{resize:vertical}.appearance-none{appearance:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.gap-1{gap:var(--spacing)}.gap-1\\.5{gap:calc(var(--spacing) * 1.5)}.gap-2{gap:calc(var(--spacing) * 2)}.gap-2\\.5{gap:calc(var(--spacing) * 2.5)}.gap-3{gap:calc(var(--spacing) * 3)}.gap-3\\.5{gap:calc(var(--spacing) * 3.5)}.gap-4{gap:calc(var(--spacing) * 4)}.gap-5{gap:calc(var(--spacing) * 5)}.gap-6{gap:calc(var(--spacing) * 6)}:where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3\\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 3.5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 3.5) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 5) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 5) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-6>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 6) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 6) * calc(1 - var(--tw-space-y-reverse)))}:where(.divide-y>:not(:last-child)){--tw-divide-y-reverse:0;border-bottom-style:var(--tw-border-style);border-top-style:var(--tw-border-style);border-top-width:calc(1px * var(--tw-divide-y-reverse));border-bottom-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)))}:where(.divide-slate-100>:not(:last-child)){border-color:var(--color-slate-100)}:where(.divide-zinc-800>:not(:last-child)){border-color:var(--color-zinc-800)}.self-start{align-self:flex-start}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overscroll-contain{overscroll-behavior:contain}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:var(--radius-2xl)}.rounded-3xl{border-radius:var(--radius-3xl)}.rounded-full{border-radius:2147483647px}.rounded-lg{border-radius:var(--radius-lg)}.rounded-md{border-radius:var(--radius-md)}.rounded-none{border-radius:0}.rounded-xl{border-radius:var(--radius-xl)}.rounded-b-full{border-bottom-right-radius:2147483647px;border-bottom-left-radius:2147483647px}.border{border-style:var(--tw-border-style);border-width:1px}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.border-dashed{--tw-border-style:dashed;border-style:dashed}.border-none{--tw-border-style:none;border-style:none}.border-emerald-700{border-color:var(--color-emerald-700)}.border-fuchsia-200{border-color:var(--color-fuchsia-200)}.border-fuchsia-500{border-color:var(--color-fuchsia-500)}.border-fuchsia-600{border-color:var(--color-fuchsia-600)}.border-gray-200{border-color:var(--color-gray-200)}.border-gray-200\\/80{border-color:#e5e7ebcc}@supports (color:color-mix(in lab, red, red)){.border-gray-200\\/80{border-color:color-mix(in oklab, var(--color-gray-200) 80%, transparent)}}.border-gray-300{border-color:var(--color-gray-300)}.border-gray-900{border-color:var(--color-gray-900)}.border-pink-100{border-color:var(--color-pink-100)}.border-pink-100\\/90{border-color:#fce7f3e6}@supports (color:color-mix(in lab, red, red)){.border-pink-100\\/90{border-color:color-mix(in oklab, var(--color-pink-100) 90%, transparent)}}.border-red-200{border-color:var(--color-red-200)}.border-red-700{border-color:var(--color-red-700)}.border-red-900{border-color:var(--color-red-900)}.border-red-900\\/60{border-color:#82181a99}@supports (color:color-mix(in lab, red, red)){.border-red-900\\/60{border-color:color-mix(in oklab, var(--color-red-900) 60%, transparent)}}.border-slate-100{border-color:var(--color-slate-100)}.border-slate-200{border-color:var(--color-slate-200)}.border-slate-200\\/80{border-color:#e2e8f0cc}@supports (color:color-mix(in lab, red, red)){.border-slate-200\\/80{border-color:color-mix(in oklab, var(--color-slate-200) 80%, transparent)}}.border-slate-300{border-color:var(--color-slate-300)}.border-transparent{border-color:#0000}.border-white{border-color:var(--color-white)}.border-zinc-600{border-color:var(--color-zinc-600)}.border-zinc-700{border-color:var(--color-zinc-700)}.border-zinc-800{border-color:var(--color-zinc-800)}.bg-\\[\\#fbf7f9\\]{background-color:#fbf7f9}.bg-amber-50{background-color:var(--color-amber-50)}.bg-amber-950\\/60{background-color:#46190199}@supports (color:color-mix(in lab, red, red)){.bg-amber-950\\/60{background-color:color-mix(in oklab, var(--color-amber-950) 60%, transparent)}}.bg-black{background-color:var(--color-black)}.bg-emerald-50{background-color:var(--color-emerald-50)}.bg-emerald-300{background-color:var(--color-emerald-300)}.bg-emerald-950\\/50{background-color:#002c2280}@supports (color:color-mix(in lab, red, red)){.bg-emerald-950\\/50{background-color:color-mix(in oklab, var(--color-emerald-950) 50%, transparent)}}.bg-emerald-950\\/60{background-color:#002c2299}@supports (color:color-mix(in lab, red, red)){.bg-emerald-950\\/60{background-color:color-mix(in oklab, var(--color-emerald-950) 60%, transparent)}}.bg-emerald-950\\/70{background-color:#002c22b3}@supports (color:color-mix(in lab, red, red)){.bg-emerald-950\\/70{background-color:color-mix(in oklab, var(--color-emerald-950) 70%, transparent)}}.bg-emerald-950\\/95{background-color:#002c22f2}@supports (color:color-mix(in lab, red, red)){.bg-emerald-950\\/95{background-color:color-mix(in oklab, var(--color-emerald-950) 95%, transparent)}}.bg-fuchsia-100{background-color:var(--color-fuchsia-100)}.bg-fuchsia-600{background-color:var(--color-fuchsia-600)}.bg-gray-50{background-color:var(--color-gray-50)}.bg-gray-50\\/80{background-color:#f9fafbcc}@supports (color:color-mix(in lab, red, red)){.bg-gray-50\\/80{background-color:color-mix(in oklab, var(--color-gray-50) 80%, transparent)}}.bg-gray-100{background-color:var(--color-gray-100)}.bg-gray-900{background-color:var(--color-gray-900)}.bg-red-50{background-color:var(--color-red-50)}.bg-red-50\\/80{background-color:#fef2f2cc}@supports (color:color-mix(in lab, red, red)){.bg-red-50\\/80{background-color:color-mix(in oklab, var(--color-red-50) 80%, transparent)}}.bg-red-600{background-color:var(--color-red-600)}.bg-red-950\\/50{background-color:#46080980}@supports (color:color-mix(in lab, red, red)){.bg-red-950\\/50{background-color:color-mix(in oklab, var(--color-red-950) 50%, transparent)}}.bg-red-950\\/60{background-color:#46080999}@supports (color:color-mix(in lab, red, red)){.bg-red-950\\/60{background-color:color-mix(in oklab, var(--color-red-950) 60%, transparent)}}.bg-red-950\\/95{background-color:#460809f2}@supports (color:color-mix(in lab, red, red)){.bg-red-950\\/95{background-color:color-mix(in oklab, var(--color-red-950) 95%, transparent)}}.bg-slate-50{background-color:var(--color-slate-50)}.bg-slate-100{background-color:var(--color-slate-100)}.bg-slate-900{background-color:var(--color-slate-900)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-white\\/15{background-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.bg-white\\/15{background-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.bg-white\\/20{background-color:#fff3}@supports (color:color-mix(in lab, red, red)){.bg-white\\/20{background-color:color-mix(in oklab, var(--color-white) 20%, transparent)}}.bg-white\\/70{background-color:#ffffffb3}@supports (color:color-mix(in lab, red, red)){.bg-white\\/70{background-color:color-mix(in oklab, var(--color-white) 70%, transparent)}}.bg-white\\/85{background-color:#ffffffd9}@supports (color:color-mix(in lab, red, red)){.bg-white\\/85{background-color:color-mix(in oklab, var(--color-white) 85%, transparent)}}.bg-white\\/95{background-color:#fffffff2}@supports (color:color-mix(in lab, red, red)){.bg-white\\/95{background-color:color-mix(in oklab, var(--color-white) 95%, transparent)}}.bg-zinc-800{background-color:var(--color-zinc-800)}.bg-zinc-800\\/60{background-color:#27272a99}@supports (color:color-mix(in lab, red, red)){.bg-zinc-800\\/60{background-color:color-mix(in oklab, var(--color-zinc-800) 60%, transparent)}}.bg-zinc-900{background-color:var(--color-zinc-900)}.bg-zinc-900\\/60{background-color:#18181b99}@supports (color:color-mix(in lab, red, red)){.bg-zinc-900\\/60{background-color:color-mix(in oklab, var(--color-zinc-900) 60%, transparent)}}.bg-zinc-900\\/85{background-color:#18181bd9}@supports (color:color-mix(in lab, red, red)){.bg-zinc-900\\/85{background-color:color-mix(in oklab, var(--color-zinc-900) 85%, transparent)}}.bg-zinc-900\\/90{background-color:#18181be6}@supports (color:color-mix(in lab, red, red)){.bg-zinc-900\\/90{background-color:color-mix(in oklab, var(--color-zinc-900) 90%, transparent)}}.bg-zinc-900\\/95{background-color:#18181bf2}@supports (color:color-mix(in lab, red, red)){.bg-zinc-900\\/95{background-color:color-mix(in oklab, var(--color-zinc-900) 95%, transparent)}}.bg-zinc-950{background-color:var(--color-zinc-950)}.bg-zinc-950\\/60{background-color:#09090b99}@supports (color:color-mix(in lab, red, red)){.bg-zinc-950\\/60{background-color:color-mix(in oklab, var(--color-zinc-950) 60%, transparent)}}.object-contain{object-fit:contain}.object-cover{object-fit:cover}.object-right{object-position:right}.p-1{padding:var(--spacing)}.p-1\\.5{padding:calc(var(--spacing) * 1.5)}.p-2{padding:calc(var(--spacing) * 2)}.p-2\\.5{padding:calc(var(--spacing) * 2.5)}.p-3\\.5{padding:calc(var(--spacing) * 3.5)}.p-4{padding:calc(var(--spacing) * 4)}.p-5{padding:calc(var(--spacing) * 5)}.p-6{padding:calc(var(--spacing) * 6)}.p-8{padding:calc(var(--spacing) * 8)}.px-1{padding-inline:var(--spacing)}.px-2{padding-inline:calc(var(--spacing) * 2)}.px-2\\.5{padding-inline:calc(var(--spacing) * 2.5)}.px-3{padding-inline:calc(var(--spacing) * 3)}.px-3\\.5{padding-inline:calc(var(--spacing) * 3.5)}.px-4{padding-inline:calc(var(--spacing) * 4)}.px-5{padding-inline:calc(var(--spacing) * 5)}.px-6{padding-inline:calc(var(--spacing) * 6)}.px-8{padding-inline:calc(var(--spacing) * 8)}.py-0\\.5{padding-block:calc(var(--spacing) * .5)}.py-1{padding-block:var(--spacing)}.py-1\\.5{padding-block:calc(var(--spacing) * 1.5)}.py-2{padding-block:calc(var(--spacing) * 2)}.py-2\\.5{padding-block:calc(var(--spacing) * 2.5)}.py-3{padding-block:calc(var(--spacing) * 3)}.py-4{padding-block:calc(var(--spacing) * 4)}.py-5{padding-block:calc(var(--spacing) * 5)}.py-6{padding-block:calc(var(--spacing) * 6)}.py-8{padding-block:calc(var(--spacing) * 8)}.py-16{padding-block:calc(var(--spacing) * 16)}.pt-1{padding-top:var(--spacing)}.pt-2{padding-top:calc(var(--spacing) * 2)}.pt-3{padding-top:calc(var(--spacing) * 3)}.pt-4{padding-top:calc(var(--spacing) * 4)}.pt-5{padding-top:calc(var(--spacing) * 5)}.pt-6{padding-top:calc(var(--spacing) * 6)}.pr-1\\.5{padding-right:calc(var(--spacing) * 1.5)}.pr-2\\.5{padding-right:calc(var(--spacing) * 2.5)}.pr-3{padding-right:calc(var(--spacing) * 3)}.pr-3\\.5{padding-right:calc(var(--spacing) * 3.5)}.pr-4{padding-right:calc(var(--spacing) * 4)}.pr-8{padding-right:calc(var(--spacing) * 8)}.pr-9{padding-right:calc(var(--spacing) * 9)}.pr-10{padding-right:calc(var(--spacing) * 10)}.pb-3{padding-bottom:calc(var(--spacing) * 3)}.pb-5{padding-bottom:calc(var(--spacing) * 5)}.pb-6{padding-bottom:calc(var(--spacing) * 6)}.pb-10{padding-bottom:calc(var(--spacing) * 10)}.pl-2{padding-left:calc(var(--spacing) * 2)}.pl-2\\.5{padding-left:calc(var(--spacing) * 2.5)}.pl-3\\.5{padding-left:calc(var(--spacing) * 3.5)}.pl-4{padding-left:calc(var(--spacing) * 4)}.pl-8{padding-left:calc(var(--spacing) * 8)}.pl-9{padding-left:calc(var(--spacing) * 9)}.pl-10{padding-left:calc(var(--spacing) * 10)}.text-center{text-align:center}.text-left{text-align:left}.font-mono{font-family:var(--font-mono)}.font-sans{font-family:var(--font-sans)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\\[10px\\]{font-size:10px}.text-\\[11px\\]{font-size:11px}.text-\\[12\\.5px\\]{font-size:12.5px}.text-\\[12px\\]{font-size:12px}.text-\\[13px\\]{font-size:13px}.text-\\[15px\\]{font-size:15px}.leading-relaxed{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.leading-tight{--tw-leading:var(--leading-tight);line-height:var(--leading-tight)}.font-black{--tw-font-weight:var(--font-weight-black);font-weight:var(--font-weight-black)}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.font-extrabold{--tw-font-weight:var(--font-weight-extrabold);font-weight:var(--font-weight-extrabold)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-tight{--tw-tracking:var(--tracking-tight);letter-spacing:var(--tracking-tight)}.tracking-wide{--tw-tracking:var(--tracking-wide);letter-spacing:var(--tracking-wide)}.tracking-wider{--tw-tracking:var(--tracking-wider);letter-spacing:var(--tracking-wider)}.text-balance{text-wrap:balance}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.text-amber-300{color:var(--color-amber-300)}.text-amber-500{color:var(--color-amber-500)}.text-amber-700{color:var(--color-amber-700)}.text-emerald-300{color:var(--color-emerald-300)}.text-emerald-500{color:var(--color-emerald-500)}.text-emerald-700{color:var(--color-emerald-700)}.text-emerald-800{color:var(--color-emerald-800)}.text-fuchsia-600{color:var(--color-fuchsia-600)}.text-fuchsia-700{color:var(--color-fuchsia-700)}.text-gray-400{color:var(--color-gray-400)}.text-gray-500{color:var(--color-gray-500)}.text-gray-600{color:var(--color-gray-600)}.text-gray-700{color:var(--color-gray-700)}.text-gray-800{color:var(--color-gray-800)}.text-gray-900{color:var(--color-gray-900)}.text-indigo-400{color:var(--color-indigo-400)}.text-red-300{color:var(--color-red-300)}.text-red-400{color:var(--color-red-400)}.text-red-500{color:var(--color-red-500)}.text-red-600{color:var(--color-red-600)}.text-red-700{color:var(--color-red-700)}.text-slate-300{color:var(--color-slate-300)}.text-slate-400{color:var(--color-slate-400)}.text-slate-500{color:var(--color-slate-500)}.text-slate-600{color:var(--color-slate-600)}.text-slate-700{color:var(--color-slate-700)}.text-slate-800{color:var(--color-slate-800)}.text-slate-900{color:var(--color-slate-900)}.text-white{color:var(--color-white)}.text-white\\/60{color:#fff9}@supports (color:color-mix(in lab, red, red)){.text-white\\/60{color:color-mix(in oklab, var(--color-white) 60%, transparent)}}.text-white\\/80{color:#fffc}@supports (color:color-mix(in lab, red, red)){.text-white\\/80{color:color-mix(in oklab, var(--color-white) 80%, transparent)}}.text-zinc-100{color:var(--color-zinc-100)}.text-zinc-200{color:var(--color-zinc-200)}.text-zinc-300{color:var(--color-zinc-300)}.text-zinc-400{color:var(--color-zinc-400)}.text-zinc-500{color:var(--color-zinc-500)}.text-zinc-600{color:var(--color-zinc-600)}.capitalize{text-transform:capitalize}.lowercase{text-transform:lowercase}.uppercase{text-transform:uppercase}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,) var(--tw-slashed-zero,) var(--tw-numeric-figure,) var(--tw-numeric-spacing,) var(--tw-numeric-fraction,)}.underline{text-decoration-line:underline}.underline-offset-4{text-underline-offset:4px}.placeholder-zinc-500::placeholder{color:var(--color-zinc-500)}.opacity-0{opacity:0}.opacity-25{opacity:.25}.opacity-60{opacity:.6}.opacity-75{opacity:.75}.opacity-80{opacity:.8}.opacity-90{opacity:.9}.opacity-100{opacity:1}.opacity-\\[0\\.03\\]{opacity:.03}.opacity-\\[0\\.14\\]{opacity:.14}.shadow-2xl{--tw-shadow:0 25px 50px -12px var(--tw-shadow-color,#00000040);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-2xs{--tw-shadow:0 1px var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_1px_2px_rgba\\(15\\,23\\,42\\,0\\.04\\)\\,0_12px_32px_-16px_rgba\\(15\\,23\\,42\\,0\\.12\\)\\]{--tw-shadow:0 1px 2px var(--tw-shadow-color,#0f172a0a), 0 12px 32px -16px var(--tw-shadow-color,#0f172a1f);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_1px_2px_rgba\\(15\\,23\\,42\\,0\\.04\\)\\,0_24px_48px_-24px_rgba\\(15\\,23\\,42\\,0\\.16\\)\\]{--tw-shadow:0 1px 2px var(--tw-shadow-color,#0f172a0a), 0 24px 48px -24px var(--tw-shadow-color,#0f172a29);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_1px_2px_rgba\\(15\\,23\\,42\\,0\\.04\\)\\,0_24px_48px_-24px_rgba\\(15\\,23\\,42\\,0\\.18\\)\\]{--tw-shadow:0 1px 2px var(--tw-shadow-color,#0f172a0a), 0 24px 48px -24px var(--tw-shadow-color,#0f172a2e);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_1px_2px_rgba\\(15\\,23\\,42\\,0\\.04\\)\\]{--tw-shadow:0 1px 2px var(--tw-shadow-color,#0f172a0a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_24px_48px_-24px_rgba\\(0\\,0\\,0\\,0\\.8\\)\\]{--tw-shadow:0 24px 48px -24px var(--tw-shadow-color,#000c);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[inset_0_1px_0_rgba\\(255\\,255\\,255\\,0\\.25\\)\\]{--tw-shadow:inset 0 1px 0 var(--tw-shadow-color,#ffffff40);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a), 0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-md{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a), 0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-none{--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a), 0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-xs{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring-1{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring-emerald-200\\/80{--tw-ring-color:#a4f4cfcc}@supports (color:color-mix(in lab, red, red)){.ring-emerald-200\\/80{--tw-ring-color:color-mix(in oklab, var(--color-emerald-200) 80%, transparent)}}.ring-emerald-900{--tw-ring-color:var(--color-emerald-900)}.ring-red-200\\/80{--tw-ring-color:#ffcacacc}@supports (color:color-mix(in lab, red, red)){.ring-red-200\\/80{--tw-ring-color:color-mix(in oklab, var(--color-red-200) 80%, transparent)}}.ring-red-900{--tw-ring-color:var(--color-red-900)}.ring-slate-200\\/70{--tw-ring-color:#e2e8f0b3}@supports (color:color-mix(in lab, red, red)){.ring-slate-200\\/70{--tw-ring-color:color-mix(in oklab, var(--color-slate-200) 70%, transparent)}}.ring-white\\/25{--tw-ring-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.ring-white\\/25{--tw-ring-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}.ring-white\\/30{--tw-ring-color:#ffffff4d}@supports (color:color-mix(in lab, red, red)){.ring-white\\/30{--tw-ring-color:color-mix(in oklab, var(--color-white) 30%, transparent)}}.blur-3xl{--tw-blur:blur(var(--blur-3xl));filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.contrast-200{--tw-contrast:contrast(200%);filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.invert{--tw-invert:invert(100%);filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}.backdrop-blur-md{--tw-backdrop-blur:blur(var(--blur-md));-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}.backdrop-blur-sm{--tw-backdrop-blur:blur(var(--blur-sm));-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}.backdrop-blur-xl{--tw-backdrop-blur:blur(var(--blur-xl));-webkit-backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,) var(--tw-backdrop-brightness,) var(--tw-backdrop-contrast,) var(--tw-backdrop-grayscale,) var(--tw-backdrop-hue-rotate,) var(--tw-backdrop-invert,) var(--tw-backdrop-opacity,) var(--tw-backdrop-saturate,) var(--tw-backdrop-sepia,)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-shadow{transition-property:box-shadow;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-200{--tw-duration:.2s;transition-duration:.2s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.duration-700{--tw-duration:.7s;transition-duration:.7s}.ease-in-out{--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}.outline-none{--tw-outline-style:none;outline-style:none}.select-all{-webkit-user-select:all;user-select:all}.select-none{-webkit-user-select:none;user-select:none}.ring-inset{--tw-ring-inset:inset}@media (hover:hover){.group-hover\\:pointer-events-auto:is(:where(.group):hover *){pointer-events:auto}.group-hover\\:translate-x-0\\.5:is(:where(.group):hover *){--tw-translate-x:calc(var(--spacing) * .5);translate:var(--tw-translate-x) var(--tw-translate-y)}.group-hover\\:scale-100:is(:where(.group):hover *){--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}.group-hover\\:scale-105:is(:where(.group):hover *){--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x) var(--tw-scale-y)}.group-hover\\:opacity-100:is(:where(.group):hover *){opacity:1}.group-hover\\:shadow-\\[0_8px_20px_-6px_color-mix\\(in_srgb\\,var\\(--vx-accent\\)_70\\%\\,transparent\\)\\]:is(:where(.group):hover *){--tw-shadow:0 8px 20px -6px var(--tw-shadow-color,var(--vx-accent))}@supports (color:color-mix(in lab, red, red)){.group-hover\\:shadow-\\[0_8px_20px_-6px_color-mix\\(in_srgb\\,var\\(--vx-accent\\)_70\\%\\,transparent\\)\\]:is(:where(.group):hover *){--tw-shadow:0 8px 20px -6px var(--tw-shadow-color,color-mix(in srgb,var(--vx-accent) 70%,transparent))}}.group-hover\\:shadow-\\[0_8px_20px_-6px_color-mix\\(in_srgb\\,var\\(--vx-accent\\)_70\\%\\,transparent\\)\\]:is(:where(.group):hover *){box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}}.placeholder\\:text-slate-400::placeholder{color:var(--color-slate-400)}.placeholder\\:text-zinc-500::placeholder{color:var(--color-zinc-500)}@media (hover:hover){.hover\\:-translate-y-1:hover{--tw-translate-y:calc(var(--spacing) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.hover\\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x) var(--tw-scale-y)}.hover\\:scale-110:hover{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x) var(--tw-scale-y)}.hover\\:border-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_35\\%\\,transparent\\)\\]:hover{border-color:var(--vx-accent)}@supports (color:color-mix(in lab, red, red)){.hover\\:border-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_35\\%\\,transparent\\)\\]:hover{border-color:color-mix(in srgb,var(--vx-accent) 35%,transparent)}}.hover\\:border-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_45\\%\\,transparent\\)\\]:hover{border-color:var(--vx-accent)}@supports (color:color-mix(in lab, red, red)){.hover\\:border-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_45\\%\\,transparent\\)\\]:hover{border-color:color-mix(in srgb,var(--vx-accent) 45%,transparent)}}.hover\\:border-gray-400:hover{border-color:var(--color-gray-400)}.hover\\:border-red-200:hover{border-color:var(--color-red-200)}.hover\\:border-slate-300:hover{border-color:var(--color-slate-300)}.hover\\:border-zinc-600:hover{border-color:var(--color-zinc-600)}.hover\\:border-zinc-700:hover{border-color:var(--color-zinc-700)}.hover\\:bg-black:hover{background-color:var(--color-black)}.hover\\:bg-gray-50:hover{background-color:var(--color-gray-50)}.hover\\:bg-gray-100:hover{background-color:var(--color-gray-100)}.hover\\:bg-gray-200:hover{background-color:var(--color-gray-200)}.hover\\:bg-red-50:hover{background-color:var(--color-red-50)}.hover\\:bg-red-100:hover{background-color:var(--color-red-100)}.hover\\:bg-red-900\\/60:hover{background-color:#82181a99}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-red-900\\/60:hover{background-color:color-mix(in oklab, var(--color-red-900) 60%, transparent)}}.hover\\:bg-slate-50:hover{background-color:var(--color-slate-50)}.hover\\:bg-white\\/50:hover{background-color:#ffffff80}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/50:hover{background-color:color-mix(in oklab, var(--color-white) 50%, transparent)}}.hover\\:bg-zinc-700:hover{background-color:var(--color-zinc-700)}.hover\\:bg-zinc-800:hover{background-color:var(--color-zinc-800)}.hover\\:bg-zinc-800\\/60:hover{background-color:#27272a99}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-zinc-800\\/60:hover{background-color:color-mix(in oklab, var(--color-zinc-800) 60%, transparent)}}.hover\\:text-gray-900:hover{color:var(--color-gray-900)}.hover\\:text-red-300:hover{color:var(--color-red-300)}.hover\\:text-red-500:hover{color:var(--color-red-500)}.hover\\:text-red-600:hover{color:var(--color-red-600)}.hover\\:text-slate-600:hover{color:var(--color-slate-600)}.hover\\:text-slate-800:hover{color:var(--color-slate-800)}.hover\\:text-slate-900:hover{color:var(--color-slate-900)}.hover\\:text-white:hover{color:var(--color-white)}.hover\\:text-zinc-200:hover{color:var(--color-zinc-200)}.hover\\:text-zinc-300:hover{color:var(--color-zinc-300)}.hover\\:underline:hover{text-decoration-line:underline}.hover\\:opacity-80:hover{opacity:.8}.hover\\:opacity-90:hover{opacity:.9}.hover\\:opacity-100:hover{opacity:1}.hover\\:shadow-\\[0_24px_48px_-24px_color-mix\\(in_srgb\\,var\\(--vx-accent\\)_45\\%\\,transparent\\)\\]:hover{--tw-shadow:0 24px 48px -24px var(--tw-shadow-color,var(--vx-accent))}@supports (color:color-mix(in lab, red, red)){.hover\\:shadow-\\[0_24px_48px_-24px_color-mix\\(in_srgb\\,var\\(--vx-accent\\)_45\\%\\,transparent\\)\\]:hover{--tw-shadow:0 24px 48px -24px var(--tw-shadow-color,color-mix(in srgb,var(--vx-accent) 45%,transparent))}}.hover\\:shadow-\\[0_24px_48px_-24px_color-mix\\(in_srgb\\,var\\(--vx-accent\\)_45\\%\\,transparent\\)\\]:hover{box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.hover\\:shadow-\\[0_24px_48px_-24px_rgba\\(0\\,0\\,0\\,0\\.8\\)\\]:hover{--tw-shadow:0 24px 48px -24px var(--tw-shadow-color,#000c);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.hover\\:brightness-110:hover{--tw-brightness:brightness(110%);filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}}.focus\\:border-\\(--vx-accent\\):focus{border-color:var(--vx-accent)}.focus\\:ring-4:focus{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.focus\\:ring-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_15\\%\\,transparent\\)\\]:focus{--tw-ring-color:var(--vx-accent)}@supports (color:color-mix(in lab, red, red)){.focus\\:ring-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_15\\%\\,transparent\\)\\]:focus{--tw-ring-color:color-mix(in srgb,var(--vx-accent) 15%,transparent)}}.focus\\:ring-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_20\\%\\,transparent\\)\\]:focus{--tw-ring-color:var(--vx-accent)}@supports (color:color-mix(in lab, red, red)){.focus\\:ring-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_20\\%\\,transparent\\)\\]:focus{--tw-ring-color:color-mix(in srgb,var(--vx-accent) 20%,transparent)}}.focus\\:outline-none:focus{--tw-outline-style:none;outline-style:none}.focus-visible\\:bg-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_8\\%\\,transparent\\)\\]:focus-visible{background-color:var(--vx-accent)}@supports (color:color-mix(in lab, red, red)){.focus-visible\\:bg-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_8\\%\\,transparent\\)\\]:focus-visible{background-color:color-mix(in srgb,var(--vx-accent) 8%,transparent)}}.focus-visible\\:ring-4:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.focus-visible\\:ring-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_25\\%\\,transparent\\)\\]:focus-visible{--tw-ring-color:var(--vx-accent)}@supports (color:color-mix(in lab, red, red)){.focus-visible\\:ring-\\[color-mix\\(in_srgb\\,var\\(--vx-accent\\)_25\\%\\,transparent\\)\\]:focus-visible{--tw-ring-color:color-mix(in srgb,var(--vx-accent) 25%,transparent)}}.active\\:scale-95:active{--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x) var(--tw-scale-y)}.active\\:scale-\\[0\\.99\\]:active{scale:.99}.active\\:cursor-grabbing:active{cursor:grabbing}.disabled\\:cursor-default:disabled{cursor:default}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opacity-40:disabled{opacity:.4}.disabled\\:opacity-50:disabled{opacity:.5}.disabled\\:opacity-60:disabled{opacity:.6}.disabled\\:opacity-70:disabled{opacity:.7}@media (hover:hover){.disabled\\:hover\\:brightness-100:disabled:hover{--tw-brightness:brightness(100%);filter:var(--tw-blur,) var(--tw-brightness,) var(--tw-contrast,) var(--tw-grayscale,) var(--tw-hue-rotate,) var(--tw-invert,) var(--tw-saturate,) var(--tw-sepia,) var(--tw-drop-shadow,)}}@media (prefers-reduced-motion:no-preference){.motion-safe\\:animate-spin{animation:var(--animate-spin)}}@media (width>=40rem){.sm\\:block{display:block}.sm\\:inline{display:inline}.sm\\:inline-block{display:inline-block}.sm\\:inline-flex{display:inline-flex}.sm\\:h-14{height:calc(var(--spacing) * 14)}.sm\\:w-14{width:calc(var(--spacing) * 14)}.sm\\:w-72{width:calc(var(--spacing) * 72)}.sm\\:w-auto{width:auto}.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.sm\\:flex-row{flex-direction:row}.sm\\:items-center{align-items:center}.sm\\:items-end{align-items:flex-end}.sm\\:justify-between{justify-content:space-between}.sm\\:gap-2{gap:calc(var(--spacing) * 2)}.sm\\:gap-4{gap:calc(var(--spacing) * 4)}.sm\\:p-5{padding:calc(var(--spacing) * 5)}.sm\\:p-6{padding:calc(var(--spacing) * 6)}.sm\\:p-7{padding:calc(var(--spacing) * 7)}.sm\\:px-3{padding-inline:calc(var(--spacing) * 3)}.sm\\:px-3\\.5{padding-inline:calc(var(--spacing) * 3.5)}.sm\\:px-6{padding-inline:calc(var(--spacing) * 6)}.sm\\:px-7{padding-inline:calc(var(--spacing) * 7)}.sm\\:px-8{padding-inline:calc(var(--spacing) * 8)}.sm\\:py-6{padding-block:calc(var(--spacing) * 6)}.sm\\:py-8{padding-block:calc(var(--spacing) * 8)}.sm\\:py-10{padding-block:calc(var(--spacing) * 10)}.sm\\:pt-7{padding-top:calc(var(--spacing) * 7)}.sm\\:text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.sm\\:text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.sm\\:text-4xl{font-size:var(--text-4xl);line-height:var(--tw-leading,var(--text-4xl--line-height))}.sm\\:text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.sm\\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.sm\\:text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}}@media (width>=48rem){.md\\:block{display:block}.md\\:w-1\\/2{width:50%}.md\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (width>=64rem){.lg\\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}@media (prefers-color-scheme:dark){.dark\\:border-fuchsia-800{border-color:var(--color-fuchsia-800)}.dark\\:border-zinc-700{border-color:var(--color-zinc-700)}.dark\\:border-zinc-800{border-color:var(--color-zinc-800)}.dark\\:bg-fuchsia-950\\/80{background-color:#4b004fcc}@supports (color:color-mix(in lab, red, red)){.dark\\:bg-fuchsia-950\\/80{background-color:color-mix(in oklab, var(--color-fuchsia-950) 80%, transparent)}}.dark\\:bg-white{background-color:var(--color-white)}.dark\\:bg-zinc-800{background-color:var(--color-zinc-800)}.dark\\:bg-zinc-900{background-color:var(--color-zinc-900)}.dark\\:text-fuchsia-300{color:var(--color-fuchsia-300)}.dark\\:text-gray-900{color:var(--color-gray-900)}.dark\\:text-white{color:var(--color-white)}.dark\\:text-zinc-200{color:var(--color-zinc-200)}.dark\\:text-zinc-300{color:var(--color-zinc-300)}.dark\\:text-zinc-400{color:var(--color-zinc-400)}@media (hover:hover){.dark\\:hover\\:bg-zinc-800:hover{background-color:var(--color-zinc-800)}.dark\\:hover\\:bg-zinc-900\\/50:hover{background-color:#18181b80}@supports (color:color-mix(in lab, red, red)){.dark\\:hover\\:bg-zinc-900\\/50:hover{background-color:color-mix(in oklab, var(--color-zinc-900) 50%, transparent)}}.dark\\:hover\\:text-white:hover{color:var(--color-white)}}}}:host{all:initial;font-family:inherit}.vx-skeleton{background-image:linear-gradient(90deg,currentColor 0% 50%,currentColor 100%)}@supports (color:color-mix(in lab, red, red)){.vx-skeleton{background-image:linear-gradient(90deg, color-mix(in srgb, currentColor 7%, transparent) 0%, color-mix(in srgb, currentColor 14%, transparent) 50%, color-mix(in srgb, currentColor 7%, transparent) 100%)}}.vx-skeleton{background-size:200% 100%;animation:1.4s ease-in-out infinite vx-skeleton-sweep}@keyframes vx-skeleton-sweep{0%{background-position:100% 0}to{background-position:-100% 0}}.vx-progress-bar{animation:1.3s ease-in-out infinite vx-progress-slide}@keyframes vx-progress-slide{0%{transform:translate(-100%)}to{transform:translate(250%)}}@media (prefers-reduced-motion:reduce){.vx-skeleton,.vx-progress-bar{animation:none}}@supports (appearance:base-select){select[part~=select]{appearance:base-select}select[part~=select]::picker(select){appearance:base-select}select[part~=select]::picker-icon{display:none}select[part~=select]::picker(select){border:1px solid;margin-block:6px;padding:6px}@supports (color:color-mix(in lab, red, red)){select[part~=select]::picker(select){border:1px solid color-mix(in srgb, currentColor 12%, transparent)}}select[part~=select]::picker(select){background-color:inherit;color:inherit;opacity:0;max-height:min(320px,60vh);transition:opacity .15s ease, translate .15s ease, display .15s allow-discrete, overlay .15s allow-discrete;border-radius:14px;translate:0 -4px;box-shadow:0 18px 40px -12px #0f172a38,0 4px 12px -4px #0f172a14}select[part~=select]:open::picker(select){opacity:1;translate:0}@starting-style{select[part~=select]:open::picker(select){opacity:0;translate:0 -4px}}select[part~=select] option{color:inherit;cursor:pointer;background-color:#0000;border-radius:10px;align-items:center;gap:8px;padding:10px 12px;font-size:14px;font-weight:500;display:flex}select[part~=select] option:hover,select[part~=select] option:focus-visible{background-color:var(--vx-accent,#2563eb)}@supports (color:color-mix(in lab, red, red)){select[part~=select] option:hover,select[part~=select] option:focus-visible{background-color:color-mix(in srgb, var(--vx-accent,#2563eb) 8%, transparent)}}select[part~=select] option:hover,select[part~=select] option:focus-visible{outline:none}select[part~=select] option:checked{background-color:var(--vx-accent,#2563eb)}@supports (color:color-mix(in lab, red, red)){select[part~=select] option:checked{background-color:color-mix(in srgb, var(--vx-accent,#2563eb) 12%, transparent)}}select[part~=select] option:checked{color:var(--vx-accent,#2563eb);font-weight:600}select[part~=select] option::checkmark{color:var(--vx-accent,#2563eb);order:1;margin-inline-start:auto}select[part~=select] option[value=""],select[part~=select] option[value=""]:checked{color:currentColor;background-color:#0000}@supports (color:color-mix(in lab, red, red)){select[part~=select] option[value=""],select[part~=select] option[value=""]:checked{color:color-mix(in srgb, currentColor 55%, transparent)}}select[part~=select] option[value=""],select[part~=select] option[value=""]:checked{font-weight:500}select[part~=select] option[value=""]::checkmark{display:none}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-divide-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-backdrop-blur{syntax:"*";inherits:false}@property --tw-backdrop-brightness{syntax:"*";inherits:false}@property --tw-backdrop-contrast{syntax:"*";inherits:false}@property --tw-backdrop-grayscale{syntax:"*";inherits:false}@property --tw-backdrop-hue-rotate{syntax:"*";inherits:false}@property --tw-backdrop-invert{syntax:"*";inherits:false}@property --tw-backdrop-opacity{syntax:"*";inherits:false}@property --tw-backdrop-saturate{syntax:"*";inherits:false}@property --tw-backdrop-sepia{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@keyframes spin{to{transform:rotate(360deg)}}`,dt=`-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, sans-serif`,ft=({children:e,useShadow:t=!0,inheritFont:a=!1})=>{let o=(0,n.useRef)(null),[s,c]=(0,n.useState)(null);return(0,n.useLayoutEffect)(()=>{if(typeof document>`u`||!o.current||!t)return;let e=o.current.shadowRoot,n=null;if(e)n=e.querySelector(`.voxket-widget-root`);else{o.current.setAttribute(`data-voxket-shadow-host`,``),o.current.style.cssText=`width: 100%; min-height: 100%; display: block; position: relative;`,e=o.current.attachShadow({mode:`open`});let t=document.createElement(`style`);t.innerText=`:host, *, *::before, *::after, ::backdrop {
|
|
4
4
|
--tw-translate-x: 0; --tw-translate-y: 0; --tw-rotate-x: initial;
|
|
5
5
|
--tw-rotate-y: initial; --tw-rotate-z: initial; --tw-skew-x: initial;
|